From b7ed1bcb20820a1773db260d38edc035c9f72ddd Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 15 May 2011 00:48:05 +0000 Subject: [PATCH 0001/2394] forgot tokenizer... --- ext/tokenizer/tokenizer_data.c | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index e4c6478af6393..224e52be21f3f 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -136,14 +136,6 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_DOUBLE_ARROW", T_DOUBLE_ARROW, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_LIST", T_LIST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_ARRAY", T_ARRAY, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_BOOL_HINT", T_BOOL_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_STRING_HINT", T_STRING_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_INT_HINT", T_INT_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_DOUBLE_HINT", T_DOUBLE_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_RESOURCE_HINT", T_RESOURCE_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_OBJECT_HINT", T_OBJECT_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_SCALAR_HINT", T_SCALAR_HINT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_NUMERIC_HINT", T_NUMERIC_HINT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CLASS_C", T_CLASS_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_METHOD_C", T_METHOD_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_FUNC_C", T_FUNC_C, CONST_CS | CONST_PERSISTENT); @@ -278,14 +270,6 @@ char *get_token_type_name(int token_type) case T_DOUBLE_ARROW: return "T_DOUBLE_ARROW"; case T_LIST: return "T_LIST"; case T_ARRAY: return "T_ARRAY"; - case T_BOOL_HINT: return "T_BOOL_HINT"; - case T_STRING_HINT: return "T_STRING_HINT"; - case T_INT_HINT: return "T_INT_HINT"; - case T_DOUBLE_HINT: return "T_DOUBLE_HINT"; - case T_RESOURCE_HINT: return "T_RESOURCE_HINT"; - case T_OBJECT_HINT: return "T_OBJECT_HINT"; - case T_SCALAR_HINT: return "T_SCALAR_HINT"; - case T_NUMERIC_HINT: return "T_NUMERIC_HINT"; case T_CLASS_C: return "T_CLASS_C"; case T_METHOD_C: return "T_METHOD_C"; case T_FUNC_C: return "T_FUNC_C"; From a8df376b918d4520f1d4ee51c6c6d659c492e0c6 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 15 May 2011 01:52:07 +0000 Subject: [PATCH 0002/2394] We can't really predict what will happen on an unknown host lookup since bogus ISPs like Comcast and many others try to "help" by resolving everything to their own search page. --- ext/standard/tests/network/gethostbynamel_error.phpt | 6 ------ 1 file changed, 6 deletions(-) diff --git a/ext/standard/tests/network/gethostbynamel_error.phpt b/ext/standard/tests/network/gethostbynamel_error.phpt index 4a13bf021f333..ab2abb7b769f0 100644 --- a/ext/standard/tests/network/gethostbynamel_error.phpt +++ b/ext/standard/tests/network/gethostbynamel_error.phpt @@ -20,10 +20,6 @@ $hostname = 'string_val'; $extra_arg = 10; var_dump( gethostbynamel($hostname, $extra_arg) ); -echo "\n-- Testing gethostbynamel() with an unknown host --\n"; -$hostname = 'unknownhost_zzz_xxx_yyy.'; -var_dump( gethostbynamel($hostname) ); - echo "Done"; ?> --EXPECTF-- @@ -39,6 +35,4 @@ NULL Warning: gethostbynamel() expects exactly 1 parameter, 2 given in %s on line %d NULL --- Testing gethostbynamel() with an unknown host -- -bool(false) Done From 08792f6f9bbf1e3cb905fc4719a37952b115dd10 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 15 May 2011 05:03:29 +0000 Subject: [PATCH 0003/2394] Cache the pdo include path --- acinclude.m4 | 10 +++++----- ext/pdo_dblib/config.m4 | 10 +++++----- ext/pdo_firebird/config.m4 | 2 +- ext/pdo_mysql/config.m4 | 10 +++++----- ext/pdo_oci/config.m4 | 10 +++++----- ext/pdo_odbc/config.m4 | 10 +++++----- ext/pdo_pgsql/config.m4 | 10 +++++----- ext/pdo_sqlite/config.m4 | 12 ++++++------ 8 files changed, 37 insertions(+), 37 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 56823bf69c161..c08334b887a90 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2760,17 +2760,17 @@ dnl dnl PHP_CHECK_PDO_INCLUDES([found [, not-found]]) dnl AC_DEFUN([PHP_CHECK_PDO_INCLUDES],[ - AC_CACHE_CHECK([for PDO includes], pdo_inc_path, [ + AC_CACHE_CHECK([for PDO includes], pdo_cv_inc_path, [ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext fi ]) - if test -n "$pdo_inc_path"; then + if test -n "$pdo_cv_inc_path"; then ifelse([$1],[],:,[$1]) else ifelse([$2],[],[AC_MSG_ERROR([Cannot find php_pdo_driver.h.])],[$2]) diff --git a/ext/pdo_dblib/config.m4 b/ext/pdo_dblib/config.m4 index 3410ba9c6b8f3..ba8244c721444 100644 --- a/ext/pdo_dblib/config.m4 +++ b/ext/pdo_dblib/config.m4 @@ -59,19 +59,19 @@ if test "$PHP_PDO_DBLIB" != "no"; then ],[ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext else AC_MSG_ERROR([Cannot find php_pdo_driver.h.]) fi - AC_MSG_RESULT($pdo_inc_path) + AC_MSG_RESULT($pdo_cv_inc_path) ]) PDO_DBLIB_DEFS="-DPDO_DBLIB_FLAVOUR=\\\"freetds\\\"" - PHP_NEW_EXTENSION(pdo_dblib, pdo_dblib.c dblib_driver.c dblib_stmt.c, $ext_shared,,-I$pdo_inc_path $PDO_DBLIB_DEFS) + PHP_NEW_EXTENSION(pdo_dblib, pdo_dblib.c dblib_driver.c dblib_stmt.c, $ext_shared,,-I$pdo_cv_inc_path $PDO_DBLIB_DEFS) AC_CHECK_LIB(dnet_stub, dnet_addr, [ PHP_ADD_LIBRARY_WITH_PATH(dnet_stub,,PDO_DBLIB_SHARED_LIBADD) AC_DEFINE(HAVE_LIBDNET_STUB,1,[ ]) diff --git a/ext/pdo_firebird/config.m4 b/ext/pdo_firebird/config.m4 index 94704d3adb192..7b6f669a50497 100644 --- a/ext/pdo_firebird/config.m4 +++ b/ext/pdo_firebird/config.m4 @@ -50,7 +50,7 @@ if test "$PHP_PDO_FIREBIRD" != "no"; then PHP_ADD_LIBRARY_WITH_PATH($FIREBIRD_LIBNAME, $FIREBIRD_LIBDIR, PDO_FIREBIRD_SHARED_LIBADD) PHP_ADD_INCLUDE($FIREBIRD_INCDIR) AC_DEFINE(HAVE_PDO_FIREBIRD,1,[ ]) - PHP_NEW_EXTENSION(pdo_firebird, pdo_firebird.c firebird_driver.c firebird_statement.c, $ext_shared,,-I$pdo_inc_path) + PHP_NEW_EXTENSION(pdo_firebird, pdo_firebird.c firebird_driver.c firebird_statement.c, $ext_shared,,-I$pdo_cv_inc_path) PHP_SUBST(PDO_FIREBIRD_SHARED_LIBADD) PHP_ADD_EXTENSION_DEP(pdo_firebird, pdo) fi diff --git a/ext/pdo_mysql/config.m4 b/ext/pdo_mysql/config.m4 index 7b6db8cdb1b51..88742d2c8c379 100755 --- a/ext/pdo_mysql/config.m4 +++ b/ext/pdo_mysql/config.m4 @@ -136,15 +136,15 @@ if test "$PHP_PDO_MYSQL" != "no"; then ],[ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext else AC_MSG_ERROR([Cannot find php_pdo_driver.h.]) fi - AC_MSG_RESULT($pdo_inc_path) + AC_MSG_RESULT($pdo_cv_inc_path) ]) if test -n "$PDO_MYSQL_CONFIG"; then @@ -153,7 +153,7 @@ if test "$PHP_PDO_MYSQL" != "no"; then fi dnl fix after renaming to pdo_mysql - PHP_NEW_EXTENSION(pdo_mysql, pdo_mysql.c mysql_driver.c mysql_statement.c, $ext_shared,,-I$pdo_inc_path -I) + PHP_NEW_EXTENSION(pdo_mysql, pdo_mysql.c mysql_driver.c mysql_statement.c, $ext_shared,,-I$pdo_cv_inc_path -I) ifdef([PHP_ADD_EXTENSION_DEP], [ PHP_ADD_EXTENSION_DEP(pdo_mysql, pdo) diff --git a/ext/pdo_oci/config.m4 b/ext/pdo_oci/config.m4 index 214297073bc30..309bde8a5fa7a 100755 --- a/ext/pdo_oci/config.m4 +++ b/ext/pdo_oci/config.m4 @@ -214,18 +214,18 @@ You need to tell me where to find your Oracle Instant Client SDK, or set ORACLE_ ],[ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext else AC_MSG_ERROR([Cannot find php_pdo_driver.h.]) fi - AC_MSG_RESULT($pdo_inc_path) + AC_MSG_RESULT($pdo_cv_inc_path) ]) - PHP_NEW_EXTENSION(pdo_oci, pdo_oci.c oci_driver.c oci_statement.c, $ext_shared,,-I$pdo_inc_path) + PHP_NEW_EXTENSION(pdo_oci, pdo_oci.c oci_driver.c oci_statement.c, $ext_shared,,-I$pdo_cv_inc_path) PHP_SUBST_OLD(PDO_OCI_SHARED_LIBADD) PHP_SUBST_OLD(PDO_OCI_DIR) diff --git a/ext/pdo_odbc/config.m4 b/ext/pdo_odbc/config.m4 index 36e506bd2c4f6..b70dc9d539616 100755 --- a/ext/pdo_odbc/config.m4 +++ b/ext/pdo_odbc/config.m4 @@ -47,15 +47,15 @@ if test "$PHP_PDO_ODBC" != "no"; then ],[ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext else AC_MSG_ERROR([Cannot find php_pdo_driver.h.]) fi - AC_MSG_RESULT($pdo_inc_path) + AC_MSG_RESULT($pdo_cv_inc_path) ]) AC_MSG_CHECKING([for selected PDO ODBC flavour]) @@ -165,7 +165,7 @@ functions required for PDO support. AC_MSG_ERROR([Your ODBC library does not exist or there was an error. Check config.log for more information]) ], $PDO_ODBC_LDFLAGS) - PHP_NEW_EXTENSION(pdo_odbc, pdo_odbc.c odbc_driver.c odbc_stmt.c, $ext_shared,,-I$pdo_inc_path $PDO_ODBC_INCLUDE) + PHP_NEW_EXTENSION(pdo_odbc, pdo_odbc.c odbc_driver.c odbc_stmt.c, $ext_shared,,-I$pdo_cv_inc_path $PDO_ODBC_INCLUDE) PHP_SUBST(PDO_ODBC_SHARED_LIBADD) ifdef([PHP_ADD_EXTENSION_DEP], [ diff --git a/ext/pdo_pgsql/config.m4 b/ext/pdo_pgsql/config.m4 index 95d59a1b4a3bb..f9254a8fd9234 100644 --- a/ext/pdo_pgsql/config.m4 +++ b/ext/pdo_pgsql/config.m4 @@ -110,18 +110,18 @@ if test "$PHP_PDO_PGSQL" != "no"; then ],[ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext else AC_MSG_ERROR([Cannot find php_pdo_driver.h.]) fi - AC_MSG_RESULT($pdo_inc_path) + AC_MSG_RESULT($pdo_cv_inc_path) ]) - PHP_NEW_EXTENSION(pdo_pgsql, pdo_pgsql.c pgsql_driver.c pgsql_statement.c, $ext_shared,,-I$pdo_inc_path $PDO_PGSQL_CFLAGS) + PHP_NEW_EXTENSION(pdo_pgsql, pdo_pgsql.c pgsql_driver.c pgsql_statement.c, $ext_shared,,-I$pdo_cv_inc_path $PDO_PGSQL_CFLAGS) ifdef([PHP_ADD_EXTENSION_DEP], [ PHP_ADD_EXTENSION_DEP(pdo_pgsql, pdo) diff --git a/ext/pdo_sqlite/config.m4 b/ext/pdo_sqlite/config.m4 index 4e6dd2cb12c4d..b2b70a5038962 100644 --- a/ext/pdo_sqlite/config.m4 +++ b/ext/pdo_sqlite/config.m4 @@ -19,15 +19,15 @@ if test "$PHP_PDO_SQLITE" != "no"; then ],[ AC_MSG_CHECKING([for PDO includes]) if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$abs_srcdir/ext + pdo_cv_inc_path=$abs_srcdir/ext elif test -f $prefix/include/php/ext/pdo/php_pdo_driver.h; then - pdo_inc_path=$prefix/include/php/ext + pdo_cv_inc_path=$prefix/include/php/ext else AC_MSG_ERROR([Cannot find php_pdo_driver.h.]) fi - AC_MSG_RESULT($pdo_inc_path) + AC_MSG_RESULT($pdo_cv_inc_path) ]) php_pdo_sqlite_sources_core="pdo_sqlite.c sqlite_driver.c sqlite_statement.c" @@ -70,7 +70,7 @@ if test "$PHP_PDO_SQLITE" != "no"; then ]) PHP_SUBST(PDO_SQLITE_SHARED_LIBADD) - PHP_NEW_EXTENSION(pdo_sqlite, $php_pdo_sqlite_sources_core, $ext_shared,,-I$pdo_inc_path) + PHP_NEW_EXTENSION(pdo_sqlite, $php_pdo_sqlite_sources_core, $ext_shared,,-I$pdo_cv_inc_path) else # use bundled libs if test "$enable_maintainer_zts" = "yes"; then @@ -92,7 +92,7 @@ if test "$PHP_PDO_SQLITE" != "no"; then PHP_NEW_EXTENSION(pdo_sqlite, $php_pdo_sqlite_sources_core, - $ext_shared,,-DPDO_SQLITE_BUNDLED=1 $other_flags $threadsafe_flags -I$pdo_inc_path) + $ext_shared,,-DPDO_SQLITE_BUNDLED=1 $other_flags $threadsafe_flags -I$pdo_cv_inc_path) PHP_SUBST(PDO_SQLITE_SHARED_LIBADD) PHP_ADD_EXTENSION_DEP(pdo_sqlite, sqlite3) From 438cc7f2013308cebe90d10fff696a0915cc1885 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 15 May 2011 06:09:21 +0000 Subject: [PATCH 0004/2394] Drop support for autoconf < 2.60 in trunk and the new PHP_5_4 branch. autoconf >= 2.60 should finally be working now. --- build/buildcheck.sh | 16 ++++---------- configure.in | 50 ++---------------------------------------- ext/standard/config.m4 | 4 ---- scripts/php-config.in | 1 + scripts/phpize.in | 1 + scripts/phpize.m4 | 5 ++--- 6 files changed, 10 insertions(+), 67 deletions(-) diff --git a/build/buildcheck.sh b/build/buildcheck.sh index 4d76bf24d4163..2815e3e0e6118 100755 --- a/build/buildcheck.sh +++ b/build/buildcheck.sh @@ -28,32 +28,24 @@ if test -z "$PHP_AUTOCONF"; then PHP_AUTOCONF='autoconf' fi -# autoconf 2.13 or newer +# autoconf 2.60 or newer ac_version=`$PHP_AUTOCONF --version 2>/dev/null|head -n 1|sed -e 's/^[^0-9]*//' -e 's/[a-z]* *$//'` if test -z "$ac_version"; then echo "buildconf: autoconf not found." -echo " You need autoconf version 2.13 or newer installed" +echo " You need autoconf version 2.60 or newer installed" echo " to build PHP from SVN." exit 1 fi IFS=.; set $ac_version; IFS=' ' -if test "$1" = "2" -a "$2" -lt "13" || test "$1" -lt "2"; then +if test "$1" = "2" -a "$2" -lt "60" || test "$1" -lt "2"; then echo "buildconf: autoconf version $ac_version found." -echo " You need autoconf version 2.13 or newer installed" +echo " You need autoconf version 2.60 or newer installed" echo " to build PHP from SVN." exit 1 else echo "buildconf: autoconf version $ac_version (ok)" fi -if test "$1" = "2" && test "$2" -ge "50"; then - echo "buildconf: Your version of autoconf likely contains buggy cache code." - echo " Running vcsclean for you." - echo " To avoid this, install autoconf-2.13." - ./vcsclean - stamp= -fi - test -n "$stamp" && touch $stamp exit 0 diff --git a/configure.in b/configure.in index b0c0c6565441b..a641a1d2f2e9f 100644 --- a/configure.in +++ b/configure.in @@ -1,28 +1,6 @@ ## $Id$ -*- autoconf -*- dnl ## Process this file with autoconf to produce a configure script. -divert(1) - -dnl ## Diversion 1 is the autoconf + automake setup phase. We also -dnl ## set the PHP version, deal with platform-specific compile -dnl ## options and check for the basic compile tools. - -dnl ## Diversion 2 is the initial checking of OS features, programs, -dnl ## libraries and so on. - -dnl ## In diversion 3 we check for compile-time options to the PHP -dnl ## core and how to deal with different system dependencies. -dnl ## This includes whether debugging or short tags are enabled -dnl ## and the default behaviour of php.ini options. -dnl ## This is also where an SAPI interface is selected (choosing between -dnl ## Apache module, CGI etc.) - -dnl ## In diversion 4 we check user-configurable general settings. - -dnl ## In diversion 5 we check which extensions should be compiled. -dnl ## All of these are normally in the extension directories. -dnl ## Diversion 5 is the last one. Here we generate files and clean up. - dnl include Zend specific macro definitions first dnl ------------------------------------------------------------------------- sinclude(Zend/acinclude.m4) @@ -30,8 +8,9 @@ sinclude(Zend/acinclude.m4) dnl Basic autoconf + automake initialization, generation of config.nice. dnl ------------------------------------------------------------------------- -AC_PREREQ(2.13) +AC_PREREQ(2.60) AC_INIT(README.SVN-RULES) +AC_PRESERVE_HELP_ORDER PHP_CONFIG_NICE(config.nice) @@ -289,15 +268,6 @@ sinclude(Zend/Zend.m4) sinclude(TSRM/threads.m4) sinclude(TSRM/tsrm.m4) - -divert(2) - -dnl ## Diversion 2 is where we set PHP-specific options and come up -dnl ## with reasonable default values for them. We check for pthreads here -dnl ## because the information is needed by the SAPI configuration. -dnl ## This is also where an SAPI interface is selected (choosing between -dnl ## Apache module, CGI etc.) - dnl . dnl ------------------------------------------------------------------------- @@ -343,13 +313,6 @@ if test "$enable_maintainer_zts" = "yes"; then PTHREADS_FLAGS fi -divert(3) - -dnl ## In diversion 3 we check for compile-time options to the PHP -dnl ## core and how to deal with different system dependencies. -dnl ## This includes whether debugging or short tags are enabled -dnl ## and the default behaviour of php.ini options. - dnl Starting system checks. dnl ------------------------------------------------------------------------- @@ -689,10 +652,6 @@ if test "x$php_crypt_r" = "x1"; then PHP_CRYPT_R_STYLE fi -divert(4) - -dnl ## In diversion 4 we check user-configurable general settings. - dnl General settings. dnl ------------------------------------------------------------------------- PHP_CONFIGURE_PART(General settings) @@ -927,11 +886,6 @@ else AC_MSG_RESULT([using system default]) fi -divert(5) - -dnl ## In diversion 5 we check which extensions should be compiled. -dnl ## All of these are normally in the extension directories. - dnl Extension configuration. dnl ------------------------------------------------------------------------- diff --git a/ext/standard/config.m4 b/ext/standard/config.m4 index e28c351b5b9c2..c33ae1e05c897 100644 --- a/ext/standard/config.m4 +++ b/ext/standard/config.m4 @@ -1,7 +1,5 @@ dnl $Id$ -*- autoconf -*- -divert(3)dnl - dnl dnl Check if flush should be called explicitly after buffered io dnl @@ -342,8 +340,6 @@ dnl AC_CHECK_FUNCS(getcwd getwd asinh acosh atanh log1p hypot glob strfmon nice fpclass isinf isnan mempcpy strpncpy) AC_FUNC_FNMATCH -divert(5)dnl - dnl dnl Check if there is a support means of creating a new process dnl and defining which handles it receives diff --git a/scripts/php-config.in b/scripts/php-config.in index 13c25f29040bc..d6c62ccf39339 100644 --- a/scripts/php-config.in +++ b/scripts/php-config.in @@ -2,6 +2,7 @@ SED="@SED@" prefix="@prefix@" +datarootdir="@datarootdir@" exec_prefix="@exec_prefix@" version="@PHP_VERSION@" vernum="@PHP_VERSION_ID@" diff --git a/scripts/phpize.in b/scripts/phpize.in index 40ccc77b1f048..43cd8d30ffed7 100644 --- a/scripts/phpize.in +++ b/scripts/phpize.in @@ -2,6 +2,7 @@ # Variable declaration prefix='@prefix@' +datarootdir='@datarootdir@' exec_prefix="`eval echo @exec_prefix@`" phpdir="`eval echo @libdir@`/build" includedir="`eval echo @includedir@`/php" diff --git a/scripts/phpize.m4 b/scripts/phpize.m4 index e3a30a50c5c0a..7faf6231da07f 100644 --- a/scripts/phpize.m4 +++ b/scripts/phpize.m4 @@ -1,9 +1,8 @@ dnl This file becomes configure.in for self-contained extensions. -divert(1) - -AC_PREREQ(2.13) +AC_PREREQ(2.60) AC_INIT(config.m4) +AC_PRESERVE_HELP_ORDER PHP_CONFIG_NICE(config.nice) From cc8ecca0b36647302a7036a0db62b088b8a3508f Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 16 May 2011 00:14:47 +0000 Subject: [PATCH 0005/2394] Get rid of autoconf warnings --- TSRM/acconfig.h | 1 - TSRM/build.mk | 2 +- TSRM/configure.in | 4 ++ Zend/acconfig.h | 127 --------------------------------------------- Zend/build.mk | 2 +- Zend/configure.in | 99 +++++++++++++++++++++++++++++++++++ acconfig.h.in | 1 - build/build.mk | 1 - build/build2.mk | 8 +-- configure.in | 103 +++++++++++++++++++++++++++++++++++- main/php_version.h | 8 +-- 11 files changed, 211 insertions(+), 145 deletions(-) delete mode 100644 TSRM/acconfig.h delete mode 100644 Zend/acconfig.h delete mode 100644 acconfig.h.in diff --git a/TSRM/acconfig.h b/TSRM/acconfig.h deleted file mode 100644 index 2b94cf35e711d..0000000000000 --- a/TSRM/acconfig.h +++ /dev/null @@ -1 +0,0 @@ -#undef PTHREADS diff --git a/TSRM/build.mk b/TSRM/build.mk index aac1a8b982ae5..f5756af72cdcc 100644 --- a/TSRM/build.mk +++ b/TSRM/build.mk @@ -33,7 +33,7 @@ $(makefile_in_files): $(makefile_am_files) aclocal.m4: configure.in acinclude.m4 aclocal -$(config_h_in): configure.in acconfig.h +$(config_h_in): configure.in # explicitly remove target since autoheader does not seem to work # correctly otherwise (timestamps are not updated) @rm -f $@ diff --git a/TSRM/configure.in b/TSRM/configure.in index acfdd00b3531f..6f10f5ab135cf 100644 --- a/TSRM/configure.in +++ b/TSRM/configure.in @@ -7,6 +7,10 @@ AC_INIT(TSRM.c) AM_INIT_AUTOMAKE(TSRM, 1.0, nodefine) AM_CONFIG_HEADER(tsrm_config.h) +AH_TOP([ +#undef PTHREADS +]) + sinclude(tsrm.m4) TSRM_BASIC_CHECKS diff --git a/Zend/acconfig.h b/Zend/acconfig.h deleted file mode 100644 index 60f0186d95362..0000000000000 --- a/Zend/acconfig.h +++ /dev/null @@ -1,127 +0,0 @@ -/* - +----------------------------------------------------------------------+ - | Zend Engine | - +----------------------------------------------------------------------+ - | Copyright (c) 1998-2011 Zend Technologies Ltd. (http://www.zend.com) | - +----------------------------------------------------------------------+ - | This source file is subject to version 2.00 of the Zend license, | - | that is bundled with this package in the file LICENSE, and is | - | available through the world-wide-web at the following url: | - | http://www.zend.com/license/2_00.txt. | - | If you did not receive a copy of the Zend license and are unable to | - | obtain it through the world-wide-web, please send a note to | - | license@zend.com so we can mail you a copy immediately. | - +----------------------------------------------------------------------+ - | Authors: Andi Gutmans | - | Zeev Suraski | - +----------------------------------------------------------------------+ -*/ - -/* $Id$ */ - -#if defined(__GNUC__) && __GNUC__ >= 4 -# define ZEND_API __attribute__ ((visibility("default"))) -# define ZEND_DLEXPORT __attribute__ ((visibility("default"))) -#else -# define ZEND_API -# define ZEND_DLEXPORT -#endif - -#define ZEND_DLIMPORT - -@TOP@ - -#undef uint -#undef ulong - -/* Define if you want to enable memory limit support */ -#define MEMORY_LIMIT 0 - -@BOTTOM@ - -#ifndef ZEND_ACCONFIG_H_NO_C_PROTOS - -#ifdef HAVE_STDLIB_H -# include -#endif - -#ifdef HAVE_SYS_TYPES_H -# include -#endif - -#ifdef HAVE_SYS_SELECT_H -#include -#endif - -#ifdef HAVE_IEEEFP_H -# include -#endif - -#ifdef HAVE_STRING_H -# include -#else -# include -#endif - -#if ZEND_BROKEN_SPRINTF -int zend_sprintf(char *buffer, const char *format, ...); -#else -# define zend_sprintf sprintf -#endif - -#include - -/* To enable the is_nan, is_infinite and is_finite PHP functions */ -#ifdef NETWARE - #define HAVE_ISNAN 1 - #define HAVE_ISINF 1 - #define HAVE_ISFINITE 1 -#endif - -#ifndef zend_isnan -#ifdef HAVE_ISNAN -#define zend_isnan(a) isnan(a) -#elif defined(HAVE_FPCLASS) -#define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN)) -#else -#define zend_isnan(a) 0 -#endif -#endif - -#ifdef HAVE_ISINF -#define zend_isinf(a) isinf(a) -#elif defined(INFINITY) -/* Might not work, but is required by ISO C99 */ -#define zend_isinf(a) (((a)==INFINITY)?1:0) -#elif defined(HAVE_FPCLASS) -#define zend_isinf(a) ((fpclass(a) == FP_PINF) || (fpclass(a) == FP_NINF)) -#else -#define zend_isinf(a) 0 -#endif - -#ifdef HAVE_FINITE -#define zend_finite(a) finite(a) -#elif defined(HAVE_ISFINITE) || defined(isfinite) -#define zend_finite(a) isfinite(a) -#elif defined(fpclassify) -#define zend_finite(a) ((fpclassify((a))!=FP_INFINITE&&fpclassify((a))!=FP_NAN)?1:0) -#else -#define zend_finite(a) (zend_isnan(a) ? 0 : zend_isinf(a) ? 0 : 1) -#endif - -#endif /* ifndef ZEND_ACCONFIG_H_NO_C_PROTOS */ - -#ifdef NETWARE -#ifdef USE_WINSOCK -#/*This detection against winsock is of no use*/ undef HAVE_SOCKLEN_T -#/*This detection against winsock is of no use*/ undef HAVE_SYS_SOCKET_H -#endif -#endif - -/* - * Local variables: - * tab-width: 4 - * c-basic-offset: 4 - * indent-tabs-mode: t - * End: - */ diff --git a/Zend/build.mk b/Zend/build.mk index 6105ff12c474e..3c83a6fe825df 100644 --- a/Zend/build.mk +++ b/Zend/build.mk @@ -33,7 +33,7 @@ $(makefile_in_files): $(makefile_am_files) aclocal.m4: configure.in acinclude.m4 aclocal -$(config_h_in): configure.in acconfig.h +$(config_h_in): configure.in # explicitly remove target since autoheader does not seem to work # correctly otherwise (timestamps are not updated) @rm -f $@ diff --git a/Zend/configure.in b/Zend/configure.in index f53d8af6e57d9..2f24abc7e32cf 100644 --- a/Zend/configure.in +++ b/Zend/configure.in @@ -11,6 +11,105 @@ AM_PROG_CC_STDC ZEND_VERSION=$VERSION AC_ZEND_C_BIGENDIAN +AH_TOP([ +#if defined(__GNUC__) && __GNUC__ >= 4 +# define ZEND_API __attribute__ ((visibility("default"))) +# define ZEND_DLEXPORT __attribute__ ((visibility("default"))) +#else +# define ZEND_API +# define ZEND_DLEXPORT +#endif + +#define ZEND_DLIMPORT + +#undef uint +#undef ulong + +/* Define if you want to enable memory limit support */ +#define MEMORY_LIMIT 0 +]) + +AH_BOTTOM([ +#ifndef ZEND_ACCONFIG_H_NO_C_PROTOS + +#ifdef HAVE_STDLIB_H +# include +#endif + +#ifdef HAVE_SYS_TYPES_H +# include +#endif + +#ifdef HAVE_SYS_SELECT_H +#include +#endif + +#ifdef HAVE_IEEEFP_H +# include +#endif + +#ifdef HAVE_STRING_H +# include +#else +# include +#endif + +#if ZEND_BROKEN_SPRINTF +int zend_sprintf(char *buffer, const char *format, ...); +#else +# define zend_sprintf sprintf +#endif + +#include + +/* To enable the is_nan, is_infinite and is_finite PHP functions */ +#ifdef NETWARE + #define HAVE_ISNAN 1 + #define HAVE_ISINF 1 + #define HAVE_ISFINITE 1 +#endif + +#ifndef zend_isnan +#ifdef HAVE_ISNAN +#define zend_isnan(a) isnan(a) +#elif defined(HAVE_FPCLASS) +#define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN)) +#else +#define zend_isnan(a) 0 +#endif +#endif + +#ifdef HAVE_ISINF +#define zend_isinf(a) isinf(a) +#elif defined(INFINITY) +/* Might not work, but is required by ISO C99 */ +#define zend_isinf(a) (((a)==INFINITY)?1:0) +#elif defined(HAVE_FPCLASS) +#define zend_isinf(a) ((fpclass(a) == FP_PINF) || (fpclass(a) == FP_NINF)) +#else +#define zend_isinf(a) 0 +#endif + +#ifdef HAVE_FINITE +#define zend_finite(a) finite(a) +#elif defined(HAVE_ISFINITE) || defined(isfinite) +#define zend_finite(a) isfinite(a) +#elif defined(fpclassify) +#define zend_finite(a) ((fpclassify((a))!=FP_INFINITE&&fpclassify((a))!=FP_NAN)?1:0) +#else +#define zend_finite(a) (zend_isnan(a) ? 0 : zend_isinf(a) ? 0 : 1) +#endif + +#endif /* ifndef ZEND_ACCONFIG_H_NO_C_PROTOS */ + +#ifdef NETWARE +#ifdef USE_WINSOCK +#/*This detection against winsock is of no use*/ undef HAVE_SOCKLEN_T +#/*This detection against winsock is of no use*/ undef HAVE_SYS_SOCKET_H +#endif +#endif +]) + dnl We want this one before the checks, so the checks can modify CFLAGS. test -z "$CFLAGS" && auto_cflags=1 diff --git a/acconfig.h.in b/acconfig.h.in deleted file mode 100644 index f87979c2fdb02..0000000000000 --- a/acconfig.h.in +++ /dev/null @@ -1 +0,0 @@ -/* Leave this file alone */ diff --git a/build/build.mk b/build/build.mk index 5aebae1a1af1d..61d6033fc17e6 100644 --- a/build/build.mk +++ b/build/build.mk @@ -32,7 +32,6 @@ all: $(STAMP) $(ALWAYS) generated_lists: @echo makefile_am_files = Zend/Makefile.am TSRM/Makefile.am > $@ - @echo config_h_files = Zend/acconfig.h TSRM/acconfig.h >> $@ @echo config_m4_files = Zend/Zend.m4 TSRM/tsrm.m4 TSRM/threads.m4 \ Zend/acinclude.m4 ext/*/config*.m4 sapi/*/config.m4 >> $@ diff --git a/build/build2.mk b/build/build2.mk index 30ee6b1a8042d..be103fc322880 100644 --- a/build/build2.mk +++ b/build/build2.mk @@ -25,8 +25,6 @@ LT_TARGETS = ltmain.sh config.guess config.sub config_h_in = main/php_config.h.in -acconfig_h_SOURCES = acconfig.h.in $(config_h_files) - targets = $(TOUCH_FILES) configure $(config_h_in) PHP_AUTOCONF ?= 'autoconf' @@ -36,11 +34,7 @@ SUPPRESS_WARNINGS ?= 2>&1 | (egrep -v '(AC_TRY_RUN called without default to all all: $(targets) -acconfig.h: $(acconfig_h_SOURCES) - @echo rebuilding $@ - cat $(acconfig_h_SOURCES) > $@ - -$(config_h_in): configure acconfig.h +$(config_h_in): configure # explicitly remove target since autoheader does not seem to work # correctly otherwise (timestamps are not updated) @echo rebuilding $@ diff --git a/configure.in b/configure.in index a641a1d2f2e9f..d881f37f9d6fb 100644 --- a/configure.in +++ b/configure.in @@ -17,10 +17,109 @@ PHP_CONFIG_NICE(config.nice) PHP_CANONICAL_HOST_TARGET AC_CONFIG_HEADER(main/php_config.h) +AH_TOP([ +#if defined(__GNUC__) && __GNUC__ >= 4 +# define ZEND_API __attribute__ ((visibility("default"))) +# define ZEND_DLEXPORT __attribute__ ((visibility("default"))) +#else +# define ZEND_API +# define ZEND_DLEXPORT +#endif + +#define ZEND_DLIMPORT + +#undef uint +#undef ulong + +/* Define if you want to enable memory limit support */ +#define MEMORY_LIMIT 0 +]) +AH_BOTTOM([ +#ifndef ZEND_ACCONFIG_H_NO_C_PROTOS + +#ifdef HAVE_STDLIB_H +# include +#endif + +#ifdef HAVE_SYS_TYPES_H +# include +#endif + +#ifdef HAVE_SYS_SELECT_H +#include +#endif + +#ifdef HAVE_IEEEFP_H +# include +#endif + +#ifdef HAVE_STRING_H +# include +#else +# include +#endif + +#if ZEND_BROKEN_SPRINTF +int zend_sprintf(char *buffer, const char *format, ...); +#else +# define zend_sprintf sprintf +#endif + +#include + +/* To enable the is_nan, is_infinite and is_finite PHP functions */ +#ifdef NETWARE + #define HAVE_ISNAN 1 + #define HAVE_ISINF 1 + #define HAVE_ISFINITE 1 +#endif + +#ifndef zend_isnan +#ifdef HAVE_ISNAN +#define zend_isnan(a) isnan(a) +#elif defined(HAVE_FPCLASS) +#define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN)) +#else +#define zend_isnan(a) 0 +#endif +#endif + +#ifdef HAVE_ISINF +#define zend_isinf(a) isinf(a) +#elif defined(INFINITY) +/* Might not work, but is required by ISO C99 */ +#define zend_isinf(a) (((a)==INFINITY)?1:0) +#elif defined(HAVE_FPCLASS) +#define zend_isinf(a) ((fpclass(a) == FP_PINF) || (fpclass(a) == FP_NINF)) +#else +#define zend_isinf(a) 0 +#endif + +#ifdef HAVE_FINITE +#define zend_finite(a) finite(a) +#elif defined(HAVE_ISFINITE) || defined(isfinite) +#define zend_finite(a) isfinite(a) +#elif defined(fpclassify) +#define zend_finite(a) ((fpclassify((a))!=FP_INFINITE&&fpclassify((a))!=FP_NAN)?1:0) +#else +#define zend_finite(a) (zend_isnan(a) ? 0 : zend_isinf(a) ? 0 : 1) +#endif + +#endif /* ifndef ZEND_ACCONFIG_H_NO_C_PROTOS */ + +#ifdef NETWARE +#ifdef USE_WINSOCK +#/*This detection against winsock is of no use*/ undef HAVE_SOCKLEN_T +#/*This detection against winsock is of no use*/ undef HAVE_SYS_SOCKET_H +#endif +#endif + +#undef PTHREADS +]) PHP_MAJOR_VERSION=5 -PHP_MINOR_VERSION=3 -PHP_RELEASE_VERSION=99 +PHP_MINOR_VERSION=5 +PHP_RELEASE_VERSION=0 PHP_EXTRA_VERSION="-dev" PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION" PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION` diff --git a/main/php_version.h b/main/php_version.h index bfa499ac7f1da..1995834e03426 100644 --- a/main/php_version.h +++ b/main/php_version.h @@ -1,8 +1,8 @@ /* automatically generated by configure */ /* edit configure.in to change version number */ #define PHP_MAJOR_VERSION 5 -#define PHP_MINOR_VERSION 3 -#define PHP_RELEASE_VERSION 99 +#define PHP_MINOR_VERSION 5 +#define PHP_RELEASE_VERSION 0 #define PHP_EXTRA_VERSION "-dev" -#define PHP_VERSION "5.3.99-dev" -#define PHP_VERSION_ID 50399 +#define PHP_VERSION "5.5.0-dev" +#define PHP_VERSION_ID 50500 From 898e3095f14731c22f92b5863fdaa2cac5380ba8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Mon, 16 May 2011 10:15:28 +0000 Subject: [PATCH 0006/2394] - Move the access behind the check. # I can't find an unsafe call, but let's play safe --- ext/mysqlnd/mysqlnd_net.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index 42a97bf1153b4..6821c5f205632 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -905,11 +905,11 @@ mysqlnd_net_init(zend_bool persistent TSRMLS_DC) PHPAPI void mysqlnd_net_free(MYSQLND_NET * const net TSRMLS_DC) { - zend_bool pers = net->persistent; - DBG_ENTER("mysqlnd_net_free"); if (net) { + zend_bool pers = net->persistent; + net->m.free_contents(net TSRMLS_CC); if (net->cmd_buffer.buffer) { DBG_INF("Freeing cmd buffer"); From 0179c5a0e604f4b2181740fd1a0d6ed1f2a887f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Mon, 16 May 2011 15:37:39 +0000 Subject: [PATCH 0007/2394] - Fix Bug #53782 (foreach throws irrelevant exception) --- ext/pdo_mysql/mysql_statement.c | 6 ++++- ext/pdo_mysql/tests/bug53782.phpt | 40 +++++++++++++++++++++++++++++++ 2 files changed, 45 insertions(+), 1 deletion(-) create mode 100644 ext/pdo_mysql/tests/bug53782.phpt diff --git a/ext/pdo_mysql/mysql_statement.c b/ext/pdo_mysql/mysql_statement.c index 375e49393086e..6adba96168a36 100755 --- a/ext/pdo_mysql/mysql_statement.c +++ b/ext/pdo_mysql/mysql_statement.c @@ -640,7 +640,11 @@ static int pdo_mysql_stmt_fetch(pdo_stmt_t *stmt, #endif /* PDO_USE_MYSQLND */ if ((S->current_data = mysql_fetch_row(S->result)) == NULL) { - if (mysql_errno(S->H->server)) { +#if PDO_USE_MYSQLND + if (S->result->unbuf && !S->result->unbuf->eof_reached && mysql_errno(S->H->server)) { +#else + if (!S->result->eof && mysql_errno(S->H->server)) { +#endif pdo_mysql_error_stmt(stmt); } PDO_DBG_RETURN(0); diff --git a/ext/pdo_mysql/tests/bug53782.phpt b/ext/pdo_mysql/tests/bug53782.phpt new file mode 100644 index 0000000000000..4f81cceef2616 --- /dev/null +++ b/ext/pdo_mysql/tests/bug53782.phpt @@ -0,0 +1,40 @@ +--TEST-- +PDO MySQL Bug #53782 (foreach throws irrelevant exception) +--SKIPIF-- + +--FILE-- +setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); + +$res = $conn->query('SELECT 0'); + +try { + $conn->query('ERROR'); +} catch (PDOException $e) { + echo "Caught: ".$e->getMessage()."\n"; +} + +foreach ($res as $k => $v) { + echo "Value: $v[0]\n"; +} + +echo "DONE"; +?> +--CLEAN-- + +--EXPECTF-- +Caught: SQLSTATE[42000]: %s +Value: 0 +DONE From e0df4e3dba7c4ab92442b9e82c1de01fdbaa3cce Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 16 May 2011 15:52:31 +0000 Subject: [PATCH 0008/2394] Fix a couple of warnings. Use %zu to printf a time_t and get_request_time actually returns a double, not a time_t. --- main/SAPI.h | 2 +- sapi/apache2handler/sapi_apache2.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/main/SAPI.h b/main/SAPI.h index 3966b2d5aa708..aca4179430fa3 100644 --- a/main/SAPI.h +++ b/main/SAPI.h @@ -241,7 +241,7 @@ struct _sapi_module_struct { void (*register_server_variables)(zval *track_vars_array TSRMLS_DC); void (*log_message)(char *message TSRMLS_DC); - time_t (*get_request_time)(TSRMLS_D); + double (*get_request_time)(TSRMLS_D); void (*terminate_process)(TSRMLS_D); char *php_ini_path_override; diff --git a/sapi/apache2handler/sapi_apache2.c b/sapi/apache2handler/sapi_apache2.c index 0d1cad063076c..48eea2b6fb45e 100644 --- a/sapi/apache2handler/sapi_apache2.c +++ b/sapi/apache2handler/sapi_apache2.c @@ -670,7 +670,7 @@ zend_first_try { } apr_table_set(r->notes, "mod_php_memory_usage", - apr_psprintf(ctx->r->pool, "%u", zend_memory_peak_usage(1 TSRMLS_CC))); + apr_psprintf(ctx->r->pool, "%zu", zend_memory_peak_usage(1 TSRMLS_CC))); } } zend_end_try(); From 22b689a3f9c0babc1b6f29bdfd4722cf74d2ff6e Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 16 May 2011 16:58:02 +0000 Subject: [PATCH 0009/2394] Add php_ignore_value() macro to suppress unused return value warnings from gcc. There are times when we really don't care about the return value and this will cleanly tell gcc. --- ext/session/mod_files.c | 2 +- ext/soap/php_sdl.c | 2 +- main/main.c | 10 +++++----- main/php.h | 5 +++++ 4 files changed, 12 insertions(+), 7 deletions(-) diff --git a/ext/session/mod_files.c b/ext/session/mod_files.c index 0627414b7a9b3..c3c35093c3558 100644 --- a/ext/session/mod_files.c +++ b/ext/session/mod_files.c @@ -390,7 +390,7 @@ PS_WRITE_FUNC(files) /* Truncate file if the amount of new data is smaller than the existing data set. */ if (vallen < (int)data->st_size) { - ftruncate(data->fd, 0); + php_ignore_value(ftruncate(data->fd, 0)); } #if defined(HAVE_PWRITE) diff --git a/ext/soap/php_sdl.c b/ext/soap/php_sdl.c index 580990ba51005..f1c4b7109e669 100644 --- a/ext/soap/php_sdl.c +++ b/ext/soap/php_sdl.c @@ -2339,7 +2339,7 @@ static void add_sdl_to_cache(const char *fn, const char *uri, time_t t, sdlPtr s } } - write(f, buf.c, buf.len); + php_ignore_value(write(f, buf.c, buf.len)); close(f); smart_str_free(&buf); zend_hash_destroy(&tmp_functions); diff --git a/main/main.c b/main/main.c index b8f89badad726..9a068dfbaef39 100644 --- a/main/main.c +++ b/main/main.c @@ -561,7 +561,7 @@ PHPAPI void php_log_err(char *log_message TSRMLS_DC) #ifdef PHP_WIN32 php_flock(fd, 2); #endif - write(fd, tmp, len); + php_ignore_value(write(fd, tmp, len)); efree(tmp); efree(error_time_str); close(fd); @@ -2301,7 +2301,7 @@ PHPAPI int php_execute_script(zend_file_handle *primary_file TSRMLS_DC) /* this looks nasty to me */ old_cwd_fd = open(".", 0); #else - VCWD_GETCWD(old_cwd, OLD_CWD_SIZE-1); + php_ignore_value(VCWD_GETCWD(old_cwd, OLD_CWD_SIZE-1)); #endif VCWD_CHDIR_FILE(primary_file->filename); } @@ -2360,7 +2360,7 @@ PHPAPI int php_execute_script(zend_file_handle *primary_file TSRMLS_DC) } #else if (old_cwd[0] != '\0') { - VCWD_CHDIR(old_cwd); + php_ignore_value(VCWD_CHDIR(old_cwd)); } free_alloca(old_cwd, use_heap); #endif @@ -2390,14 +2390,14 @@ PHPAPI int php_execute_simple_script(zend_file_handle *primary_file, zval **ret PG(during_request_startup) = 0; if (primary_file->filename && !(SG(options) & SAPI_OPTION_NO_CHDIR)) { - VCWD_GETCWD(old_cwd, OLD_CWD_SIZE-1); + php_ignore_value(VCWD_GETCWD(old_cwd, OLD_CWD_SIZE-1)); VCWD_CHDIR_FILE(primary_file->filename); } zend_execute_scripts(ZEND_REQUIRE TSRMLS_CC, ret, 1, primary_file); } zend_end_try(); if (old_cwd[0] != '\0') { - VCWD_CHDIR(old_cwd); + php_ignore_value(VCWD_CHDIR(old_cwd)); } free_alloca(old_cwd, use_heap); diff --git a/main/php.h b/main/php.h index d338462eaef1f..278d6390fbb34 100644 --- a/main/php.h +++ b/main/php.h @@ -259,6 +259,11 @@ END_EXTERN_C() # endif #endif +#if defined(__GNUC__) && __GNUC__ >= 4 +# define php_ignore_value(x) (({ __typeof__ (x) __x = (x); (void) __x; })) +#else +# define php_ignore_value(x) ((void) (x)) +#endif /* global variables */ #if !defined(PHP_WIN32) From 575ea1ef0b16e672d168bbcb8a4bdbc5006c4d4b Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 16 May 2011 17:22:41 +0000 Subject: [PATCH 0010/2394] Suppress a dozen unused return value warnings in places where the return value is really not useful to us. --- Zend/zend_language_scanner.l | 4 ++-- ext/standard/exec.c | 2 +- ext/standard/file.c | 12 ++++++------ ext/standard/proc_open.c | 2 +- ext/standard/string.c | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 1e7f92d285a46..36ba3b2f8bc81 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1614,9 +1614,9 @@ NEWLINE ("\r"|"\n"|"\r\n") if (strcmp(dirname, ".") == 0) { dirname = erealloc(dirname, MAXPATHLEN); #if HAVE_GETCWD - VCWD_GETCWD(dirname, MAXPATHLEN); + php_ignore_value(VCWD_GETCWD(dirname, MAXPATHLEN)); #elif HAVE_GETWD - VCWD_GETWD(dirname); + php_ignore_value(VCWD_GETWD(dirname)); #endif } diff --git a/ext/standard/exec.c b/ext/standard/exec.c index 11b7c2c5e6d0e..890f73726bc20 100644 --- a/ext/standard/exec.c +++ b/ext/standard/exec.c @@ -484,7 +484,7 @@ PHP_FUNCTION(proc_nice) } errno = 0; - nice(pri); + php_ignore_value(nice(pri)); if (errno) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Only a super user may attempt to increase the priority of a process"); RETURN_FALSE; diff --git a/ext/standard/file.c b/ext/standard/file.c index c6b585c2c7567..527f12df61e82 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -1808,7 +1808,7 @@ static const char *php_fgetcsv_lookup_trailing_spaces(const char *ptr, size_t le case -2: case -1: inc_len = 1; - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); break; case 0: goto quit_loop; @@ -2072,7 +2072,7 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char zend_bool first_field = 1; /* initialize internal state */ - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); /* Now into new section that parses buf for delimiter/enclosure fields */ @@ -2105,7 +2105,7 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char case -2: case -1: inc_len = 1; - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); break; case 0: goto quit_loop_1; @@ -2199,7 +2199,7 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char case -2: case -1: - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); /* break is omitted intentionally */ case 1: /* we need to determine if the enclosure is @@ -2267,7 +2267,7 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char case -2: case -1: inc_len = 1; - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); /* break is omitted intentionally */ case 1: if (*bptr == delimiter) { @@ -2298,7 +2298,7 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char case -2: case -1: inc_len = 1; - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); /* break is omitted intentionally */ case 1: if (*bptr == delimiter) { diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index 8240bed205357..9544cc03da64f 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -843,7 +843,7 @@ PHP_FUNCTION(proc_open) #endif if (cwd) { - chdir(cwd); + php_ignore_value(chdir(cwd)); } if (env.envarray) { diff --git a/ext/standard/string.c b/ext/standard/string.c index 7dde105247741..7cd986c51e7a8 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -1354,7 +1354,7 @@ PHPAPI void php_basename(char *s, size_t len, char *suffix, size_t sufflen, char case -2: case -1: inc_len = 1; - php_mblen(NULL, 0); + php_ignore_value(php_mblen(NULL, 0)); break; case 0: goto quit_loop; From c5152b886b7454f77131bcef35752f80a20b02bb Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 16 May 2011 17:26:10 +0000 Subject: [PATCH 0011/2394] oops, can't use that macro here --- Zend/zend_language_scanner.l | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 36ba3b2f8bc81..1e7f92d285a46 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1614,9 +1614,9 @@ NEWLINE ("\r"|"\n"|"\r\n") if (strcmp(dirname, ".") == 0) { dirname = erealloc(dirname, MAXPATHLEN); #if HAVE_GETCWD - php_ignore_value(VCWD_GETCWD(dirname, MAXPATHLEN)); + VCWD_GETCWD(dirname, MAXPATHLEN); #elif HAVE_GETWD - php_ignore_value(VCWD_GETWD(dirname)); + VCWD_GETWD(dirname); #endif } From bb5faa6eca93048b1c7505f63173aa79ae5dc7dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Mon, 16 May 2011 19:46:32 +0000 Subject: [PATCH 0012/2394] - Fix possible memory leak # Found by parfait - http://labs.oracle.com/projects/parfait/ --- TSRM/tsrm_virtual_cwd.c | 1 + 1 file changed, 1 insertion(+) diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index d533245c612d2..b88bae90a83cc 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -1067,6 +1067,7 @@ static int tsrm_realpath_r(char *path, int start, int len, int *ll, time_t *t, i } if (is_dir && !directory) { /* not a directory */ + tsrm_free_alloca(tmp, use_heap); return -1; } } From 9f3f4eb8e8ca9ccc70af5257637ade6dc703dafe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Mon, 16 May 2011 21:29:45 +0000 Subject: [PATCH 0013/2394] - Fix a few more memleaks found by parfait --- ext/date/lib/parse_tz.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/date/lib/parse_tz.c b/ext/date/lib/parse_tz.c index 99ef7a88c0704..b8d8448c9407f 100644 --- a/ext/date/lib/parse_tz.c +++ b/ext/date/lib/parse_tz.c @@ -100,6 +100,7 @@ static void read_transistions(const unsigned char **tzf, timelib_tzinfo *tz) cbuffer = (unsigned char*) malloc(tz->timecnt * sizeof(unsigned char)); if (!cbuffer) { + free(buffer); return; } memcpy(cbuffer, *tzf, sizeof(unsigned char) * tz->timecnt); @@ -125,6 +126,7 @@ static void read_types(const unsigned char **tzf, timelib_tzinfo *tz) tz->type = (ttinfo*) malloc(tz->typecnt * sizeof(struct ttinfo)); if (!tz->type) { + free(buffer); return; } @@ -153,6 +155,7 @@ static void read_types(const unsigned char **tzf, timelib_tzinfo *tz) tz->leap_times = (tlinfo*) malloc(tz->leapcnt * sizeof(tlinfo)); if (!tz->leap_times) { + free(leap_buffer); return; } for (i = 0; i < tz->leapcnt; i++) { From 103ded60c0243d73f86ac82d62ec81d8dd9e3778 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Mon, 16 May 2011 22:24:41 +0000 Subject: [PATCH 0014/2394] - Handle error if tempfile can't be opened, found by parfait --- ext/phar/zip.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/phar/zip.c b/ext/phar/zip.c index fa3642f5c73ff..a8ac63aeb2a1b 100644 --- a/ext/phar/zip.c +++ b/ext/phar/zip.c @@ -411,6 +411,9 @@ int phar_parse_zipfile(php_stream *fp, char *fname, int fname_len, char *alias, now = php_stream_tell(fp); pefree(entry.filename, entry.is_persistent); sigfile = php_stream_fopen_tmpfile(); + if (!sigfile) { + PHAR_ZIP_FAIL("couldn't open temporary file"); + } php_stream_seek(fp, 0, SEEK_SET); /* copy file contents + local headers and zip comment, if any, to be hashed for signature */ From 3295e36bffbed00fc7a176a31d7363e9595466b4 Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Mon, 16 May 2011 23:28:46 +0000 Subject: [PATCH 0015/2394] removing XFAIL as #39863 has already been fixed --- ext/standard/tests/file/bug39863.phpt | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/standard/tests/file/bug39863.phpt b/ext/standard/tests/file/bug39863.phpt index 520a464123018..6913655ee45bc 100644 --- a/ext/standard/tests/file/bug39863.phpt +++ b/ext/standard/tests/file/bug39863.phpt @@ -16,8 +16,6 @@ else { ?> ===DONE=== ---XFAIL-- -Needs bug #39863 fixed --EXPECT-- PASS ===DONE=== From 0f214e5c2c8c63d40596cb853c35c94e5d139e4e Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Mon, 16 May 2011 23:31:14 +0000 Subject: [PATCH 0016/2394] adding the serialize_precision=100 for the tests, credits to Mats Lindh for reporting it --- ext/standard/tests/serialize/001.phpt | 2 ++ .../serialize/serialization_arrays_001.phpt | 2 ++ .../serialize/serialization_objects_001.phpt | Bin 2403 -> 2435 bytes .../serialize/serialization_objects_002.phpt | Bin 7211 -> 7244 bytes .../serialize/serialization_objects_003.phpt | 4 +++- 5 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ext/standard/tests/serialize/001.phpt b/ext/standard/tests/serialize/001.phpt index 21a2d6c5347a5..600c9b706d941 100644 --- a/ext/standard/tests/serialize/001.phpt +++ b/ext/standard/tests/serialize/001.phpt @@ -1,5 +1,7 @@ --TEST-- serialize()/unserialize()/var_dump() +--INI-- +serialize_precision=100 --FILE-- eq+1}Cjb^U1DF5+ diff --git a/ext/standard/tests/serialize/serialization_objects_002.phpt b/ext/standard/tests/serialize/serialization_objects_002.phpt index 95c2dfb68196a480f0c926894f0fb048d09c4e85..fbd9e261206e0be1212683d299f2ea488a6fc105 100644 GIT binary patch delta 42 xcmZ2&amHeTkF2Mkr>-tnacWU!VoqjNYJ5RaYI0_AW`3Tnp@G3h&qvaXTmVaA4(I>? delta 10 RcmX?OvD#vS&&Hhl(f}Km1ls@r diff --git a/ext/standard/tests/serialize/serialization_objects_003.phpt b/ext/standard/tests/serialize/serialization_objects_003.phpt index c20590b797804..2313ffab88372 100644 --- a/ext/standard/tests/serialize/serialization_objects_003.phpt +++ b/ext/standard/tests/serialize/serialization_objects_003.phpt @@ -1,5 +1,7 @@ --TEST-- Test serialize() & unserialize() functions: objects (abstract classes) +--INI-- +serialize_precision=100 --FILE-- Date: Mon, 16 May 2011 23:33:05 +0000 Subject: [PATCH 0017/2394] fix the test with the removal of the unnecessary newline --- ext/standard/tests/network/gethostbynamel_error.phpt | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/standard/tests/network/gethostbynamel_error.phpt b/ext/standard/tests/network/gethostbynamel_error.phpt index ab2abb7b769f0..7aa00e537e7f4 100644 --- a/ext/standard/tests/network/gethostbynamel_error.phpt +++ b/ext/standard/tests/network/gethostbynamel_error.phpt @@ -19,7 +19,6 @@ echo "\n-- Testing gethostbynamel() function with more than expected no. of argu $hostname = 'string_val'; $extra_arg = 10; var_dump( gethostbynamel($hostname, $extra_arg) ); - echo "Done"; ?> --EXPECTF-- @@ -34,5 +33,4 @@ NULL Warning: gethostbynamel() expects exactly 1 parameter, 2 given in %s on line %d NULL - Done From 4be65b439172962335e0c581203bf7851eafe96e Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Mon, 16 May 2011 23:35:23 +0000 Subject: [PATCH 0018/2394] set the timezone to UTC as suggested by Alexey Shein, and adding an SKIPIF as this test was originaly intended to be windows only --- ext/date/tests/DateInterval_format_a.phpt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ext/date/tests/DateInterval_format_a.phpt b/ext/date/tests/DateInterval_format_a.phpt index f82a2f6f6deeb..d095db56b36bb 100644 --- a/ext/date/tests/DateInterval_format_a.phpt +++ b/ext/date/tests/DateInterval_format_a.phpt @@ -3,8 +3,13 @@ DateInterval::format(), %a --CREDITS-- Daniel Convissor # TestFest 2010 BKTK +--INI-- +date.timezone=UTC --SKIPIF-- - + --XFAIL-- Windows VC6 libs' floor()/ceil() choke on floats --FILE-- From 0016dffc7b39032e149f3286ca5cc2f0d7180c94 Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Mon, 16 May 2011 23:39:16 +0000 Subject: [PATCH 0019/2394] adding an XFAIL, as we have an open bug for this test --- ext/date/tests/bug51994.phpt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/date/tests/bug51994.phpt b/ext/date/tests/bug51994.phpt index e136c8f2b6fa9..fb0fe46d892ad 100644 --- a/ext/date/tests/bug51994.phpt +++ b/ext/date/tests/bug51994.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #51994 (date_parse_from_format is parsing invalid date using 'yz' format) +--XFAIL-- +Bug #51994 isn't fixed yet --FILE-- 03.06.2010 @@ -35,4 +37,4 @@ array(12) { } ["is_localtime"]=> bool(false) -} \ No newline at end of file +} From be6170c30d6c476c452935457b6c66ca878e147a Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Mon, 16 May 2011 23:43:12 +0000 Subject: [PATCH 0020/2394] adding an XFAIL, as we have an open bug for this test --- ext/date/tests/bug51819.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/date/tests/bug51819.phpt b/ext/date/tests/bug51819.phpt index 1ee7c324f6246..bef8b76271cac 100644 --- a/ext/date/tests/bug51819.phpt +++ b/ext/date/tests/bug51819.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #51819 (Case discrepancy in timezone names cause Uncaught exception and fatal error) +--XFAIL-- +Bug #51819 isn't fixed yet --FILE-- Date: Tue, 17 May 2011 00:16:57 +0000 Subject: [PATCH 0021/2394] - Move the field access behind the check # Only called from one place where the connection is checked, but # playing safe, again (parfait) --- ext/mysqlnd/mysqlnd_wireprotocol.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c index 795e0cd410f62..ff354eec3d964 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.c +++ b/ext/mysqlnd/mysqlnd_wireprotocol.c @@ -2380,11 +2380,10 @@ mysqlnd_protocol_init(zend_bool persistent TSRMLS_DC) PHPAPI void mysqlnd_protocol_free(MYSQLND_PROTOCOL * const protocol TSRMLS_DC) { - zend_bool pers = protocol->persistent; - DBG_ENTER("mysqlnd_protocol_free"); if (protocol) { + zend_bool pers = protocol->persistent; mnd_pefree(protocol, pers); } DBG_VOID_RETURN; From 6c2f42b544485da1cc6e2b28bf93608068a587cc Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 17 May 2011 09:44:11 +0000 Subject: [PATCH 0022/2394] exchange a "trap" with an error --- ext/mysqlnd/mysqlnd_result.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd_result.c b/ext/mysqlnd/mysqlnd_result.c index 30368f4346f2f..f1c633278860a 100644 --- a/ext/mysqlnd/mysqlnd_result.c +++ b/ext/mysqlnd/mysqlnd_result.c @@ -1546,7 +1546,7 @@ MYSQLND_METHOD(mysqlnd_res, fetch_row_c)(MYSQLND_RES * result TSRMLS_DC) } else if (result->m.fetch_row == result->m.fetch_row_normal_unbuffered) { DBG_RETURN(mysqlnd_fetch_row_unbuffered_c(result TSRMLS_CC)); } else { - *((int*)NULL) = 1; + php_error_docref(NULL TSRMLS_CC, E_ERROR, "result->m.fetch_row has invalid value. Report to the developers"); } } DBG_RETURN(ret); From 7ee407eb3780bb96df0629fef4d9c5f8f9fe9b5c Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 17 May 2011 10:39:18 +0000 Subject: [PATCH 0023/2394] - WS --- Zend/zend_compile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 7c992b9cf7861..5c6778f6ca5ca 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2256,7 +2256,7 @@ void zend_resolve_goto_label(zend_op_array *op_array, zend_op *opline, int pass2 CG(in_compilation) = 1; CG(active_op_array) = op_array; CG(zend_lineno) = opline->lineno; - zend_error(E_COMPILE_ERROR, "'goto' to undefined label '%s'", Z_STRVAL_P(label)); + zend_error(E_COMPILE_ERROR, "'goto' to undefined label '%s'", Z_STRVAL_P(label)); } else { /* Label is not defined. Delay to pass 2. */ INC_BPC(op_array); From 13338a8f60eecd72e8f87a1d124423c84f4066ae Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 17 May 2011 12:27:21 +0000 Subject: [PATCH 0024/2394] Fixed crash on recursive error handler invocation --- ext/soap/soap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/soap/soap.c b/ext/soap/soap.c index 0001e3c349808..07a3ee77219a5 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -2094,7 +2094,7 @@ static void soap_error_handler(int error_num, const char *error_filename, const _old_http_response_code = SG(sapi_headers).http_response_code; _old_http_status_line = SG(sapi_headers).http_status_line; - if (!SOAP_GLOBAL(use_soap_error_handler)) { + if (!SOAP_GLOBAL(use_soap_error_handler) || !EG(objects_store).object_buckets) { call_old_error_handler(error_num, error_filename, error_lineno, format, args); return; } From 47db582a34d57fb033c8757dd1ca7d2bbf7e9893 Mon Sep 17 00:00:00 2001 From: Andrew Curioso Date: Tue, 17 May 2011 13:50:48 +0000 Subject: [PATCH 0025/2394] Use iterator when necessary to get the full properties hash - consistent with count (see test: ext/simplexml/tests/034.phpt) --- UPGRADING | 4 ++++ ext/simplexml/simplexml.c | 36 ++++++++++++++++++++++++++++--- ext/simplexml/tests/034.phpt | 6 +++--- ext/simplexml/tests/bug51615.phpt | 4 +++- 4 files changed, 43 insertions(+), 7 deletions(-) diff --git a/UPGRADING b/UPGRADING index c08016d4794c3..0d849a15e5a0f 100755 --- a/UPGRADING +++ b/UPGRADING @@ -170,6 +170,10 @@ UPGRADE NOTES - PHP X.Y - fclose() closes streams with resource refcount > 1; it doesn't merely decrement the resource refcount. - socket_set_options() and socket_get_options() now support multicast options. +- Arrays cast from SimpleXMLElement now always contain all nodes instead of + just the first matching node. +- All SimpleXMLElement children are now always printed when using var_dump(), + var_export(), and print_r(). =================================== 5. Changes made to existing methods diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index f9504fe58dc2c..98dbc0c13ebcb 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -1069,6 +1069,10 @@ static HashTable * sxe_get_prop_hash(zval *object, int is_debug TSRMLS_DC) /* {{ xmlAttrPtr attr; int namelen; int test; + char use_iter; + zval *iter_data; + + use_iter = 0; sxe = php_sxe_fetch_object(object TSRMLS_CC); @@ -1122,6 +1126,7 @@ static HashTable * sxe_get_prop_hash(zval *object, int is_debug TSRMLS_DC) /* {{ GET_NODE(sxe, node); node = php_sxe_get_first_node(sxe, node TSRMLS_CC); + if (node && sxe->iter.type != SXE_ITER_ATTRLIST) { if (node->type == XML_ATTRIBUTE_NODE) { MAKE_STD_ZVAL(value); @@ -1129,7 +1134,17 @@ static HashTable * sxe_get_prop_hash(zval *object, int is_debug TSRMLS_DC) /* {{ zend_hash_next_index_insert(rv, &value, sizeof(zval *), NULL); node = NULL; } else if (sxe->iter.type != SXE_ITER_CHILD) { - node = node->children; + + if ( !node->children || !node->parent || node->children->next || node->children->children || node->parent->children == node->parent->last ) { + node = node->children; + } else { + iter_data = sxe->iter.data; + sxe->iter.data = NULL; + + node = php_sxe_reset_iterator(sxe, 0 TSRMLS_CC); + + use_iter = 1; + } } while (node) { @@ -1161,10 +1176,25 @@ static HashTable * sxe_get_prop_hash(zval *object, int is_debug TSRMLS_DC) /* {{ _get_base_node_value(sxe, node, &value, sxe->iter.nsprefix, sxe->iter.isprefix TSRMLS_CC); - sxe_properties_add(rv, name, namelen, value TSRMLS_CC); + if ( use_iter ) { + zend_hash_next_index_insert(rv, &value, sizeof(zval *), NULL); + } else { + sxe_properties_add(rv, name, namelen, value TSRMLS_CC); + } next_iter: - node = node->next; + if ( use_iter ) { + node = php_sxe_iterator_fetch(sxe, node->next, 0 TSRMLS_CC); + } else { + node = node->next; + } + } + } + + if ( use_iter ) { + if (sxe->iter.data) { + zval_ptr_dtor(&sxe->iter.data); } + sxe->iter.data = iter_data; } return rv; diff --git a/ext/simplexml/tests/034.phpt b/ext/simplexml/tests/034.phpt index 1f3a854fdecde..8610f70367700 100755 --- a/ext/simplexml/tests/034.phpt +++ b/ext/simplexml/tests/034.phpt @@ -1,7 +1,7 @@ --TEST-- -SimpleXML: array casting bug ---XFAIL-- -Does anyone know why? +SimpleXML: cast to array +--FAIL-- +Length of cast array does not match expected length --SKIPIF-- --FILE-- diff --git a/ext/simplexml/tests/bug51615.phpt b/ext/simplexml/tests/bug51615.phpt index 75f6769ff7c1b..e0229943131f3 100644 --- a/ext/simplexml/tests/bug51615.phpt +++ b/ext/simplexml/tests/bug51615.phpt @@ -20,7 +20,7 @@ foreach ($html->body->span as $obj) { Warning: DOMDocument::loadHTML(): error parsing attribute name in Entity, line: 1 in %s on line %d Warning: DOMDocument::loadHTML(): error parsing attribute name in Entity, line: 1 in %s on line %d -object(SimpleXMLElement)#%d (2) { +object(SimpleXMLElement)#%d (3) { ["@attributes"]=> array(2) { ["title"]=> @@ -30,6 +30,8 @@ object(SimpleXMLElement)#%d (2) { } [0]=> string(1) "x" + [1]=> + string(1) "x" } string(0) "" string(0) "" From e5c1c4222091e73c101a70bf5ee820d4a4878fe0 Mon Sep 17 00:00:00 2001 From: Jeraimee Hughes Date: Tue, 17 May 2011 15:06:48 +0000 Subject: [PATCH 0026/2394] Fix for failing test. --- tests/security/open_basedir_readlink.phpt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/security/open_basedir_readlink.phpt b/tests/security/open_basedir_readlink.phpt index a632dce243d0a..fe16d08542229 100644 --- a/tests/security/open_basedir_readlink.phpt +++ b/tests/security/open_basedir_readlink.phpt @@ -69,8 +69,6 @@ bool(false) Warning: readlink(): open_basedir restriction in effect. File(%s/test/ok/symlink.txt) is not within the allowed path(s): (.) in %s on line %d bool(false) - -Warning: unlink(): open_basedir restriction in effect. File(%s/test/ok/symlink.txt) is not within the allowed path(s): (.) in %s on line %d -bool(false) +bool(true) *** Finished testing open_basedir configuration [readlink] *** From daecb2c0f4c3b96c10654042cc4e6fa9c38532fd Mon Sep 17 00:00:00 2001 From: Jeraimee Hughes Date: Tue, 17 May 2011 15:08:15 +0000 Subject: [PATCH 0027/2394] Fixes for broken tests. --- ext/mcrypt/tests/bug46010.phpt | 2 ++ tests/security/open_basedir_linkinfo.phpt | 4 +--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/mcrypt/tests/bug46010.phpt b/ext/mcrypt/tests/bug46010.phpt index bacfb59759187..ddb691e362d5f 100644 --- a/ext/mcrypt/tests/bug46010.phpt +++ b/ext/mcrypt/tests/bug46010.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #46010 (warnings incorrectly generated for iv in ecb mode) +--SKIPIF-- + --FILE-- Date: Tue, 17 May 2011 22:24:44 +0000 Subject: [PATCH 0028/2394] ZEND_THREAD_SAFE and ZEND_DEBUG_BUILD are not meant to be case insensitive --- Zend/zend_constants.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_constants.c b/Zend/zend_constants.c index 2a42083a837e7..b6957957208d1 100644 --- a/Zend/zend_constants.c +++ b/Zend/zend_constants.c @@ -141,7 +141,7 @@ void zend_register_standard_constants(TSRMLS_D) c.value.type = IS_NULL; zend_register_constant(&c TSRMLS_CC); - c.flags = CONST_PERSISTENT; + c.flags = CONST_PERSISTENT | CONST_CS; c.name = zend_strndup(ZEND_STRL("ZEND_THREAD_SAFE")); c.name_len = sizeof("ZEND_THREAD_SAFE"); From f0b306af39208929c151a6dcfd6b2b374d091bf1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 18 May 2011 10:21:28 +0000 Subject: [PATCH 0029/2394] - Keep the old arginfo for now # This change we would E_RECOVERABLE instead of E_WARNING # and needs some more review, as well fixing ~80 tests --- ext/mysqli/mysqli_fe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c index bbc1ff3982f44..6d80c5507c75a 100644 --- a/ext/mysqli/mysqli_fe.c +++ b/ext/mysqli/mysqli_fe.c @@ -33,7 +33,7 @@ #include "mysqli_fe.h" #include "mysqli_priv.h" -#if PHP_VERSION_ID >= 50400 +#ifdef MYSQLI_USE_FULL_TYPED_ARGINFO_0 #define MYSQLI_ZEND_ARG_OBJ_INFO_LINK() ZEND_ARG_OBJ_INFO(0, link, mysqli, 0) #define MYSQLI_ZEND_ARG_OBJ_INFO_RESULT() ZEND_ARG_OBJ_INFO(0, result, mysqli_result, 0) #define MYSQLI_ZEND_ARG_OBJ_INFO_STMT() ZEND_ARG_OBJ_INFO(0, stmt, mysqli_stmt, 0) From 5d6b3ca113c1c643f44efeaa6109aab0eba00cc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 18 May 2011 11:49:49 +0000 Subject: [PATCH 0030/2394] - handle out of memory --- ext/mysql/php_mysql.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index ddd8d22ee2a03..df9dac549b99d 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -830,6 +830,9 @@ static void php_mysql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) } /* create the link */ mysql = (php_mysql_conn *) malloc(sizeof(php_mysql_conn)); + if (!mysql) { + php_error_docref(NULL TSRMLS_CC, E_ERROR, "Out of memory while allocating memory for a persistent link"); + } mysql->active_result_id = 0; #ifdef CLIENT_MULTI_STATEMENTS mysql->multi_query = client_flags & CLIENT_MULTI_STATEMENTS? 1:0; From 0fc3380db774308c68b138b689bf4617d649c257 Mon Sep 17 00:00:00 2001 From: Jeraimee Hughes Date: Wed, 18 May 2011 20:07:11 +0000 Subject: [PATCH 0031/2394] Fixed failing test. --- Zend/tests/constants_005.phpt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Zend/tests/constants_005.phpt b/Zend/tests/constants_005.phpt index 097be97e14761..6fe598a986a9d 100755 --- a/Zend/tests/constants_005.phpt +++ b/Zend/tests/constants_005.phpt @@ -7,5 +7,6 @@ define("ZEND_THREAD_safe", 123); var_dump(ZEND_THREAD_safe); ?> --EXPECTF-- -bool(%s) +Notice: Use of undefined constant ZEND_THREAD_safe - assumed 'ZEND_THREAD_safe' in %s on line %d +string(16) "ZEND_THREAD_safe" int(123) From a7c5be302ed69c6fad9a1aa867a4a90b60701be4 Mon Sep 17 00:00:00 2001 From: Jeraimee Hughes Date: Wed, 18 May 2011 20:52:30 +0000 Subject: [PATCH 0032/2394] Fixed failing test (mismatch of tzoffset) --- ext/date/tests/bug33532.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/date/tests/bug33532.phpt b/ext/date/tests/bug33532.phpt index 286ceb4cec018..d778d8b5cee5b 100644 --- a/ext/date/tests/bug33532.phpt +++ b/ext/date/tests/bug33532.phpt @@ -29,10 +29,10 @@ print "datestr " . date ("H:i:s A F j Y T", $tStamp) . "\n"; TZ has NOT been set Should strftime==datestr? Strftime seems to assume GMT tStamp. input 10:00:00 AM July 1 2005 -strftime 10:00:00 AM July 1 2005 UTC +0000 +strftime 10:00:00 AM July 1 2005 UTC -0500 datestr 10:00:00 AM July 1 2005 UTC Setting TZ input 10:00:00 AM July 1 2005 -strftime 10:00:00 AM July 1 2005 EST +1000 +strftime 10:00:00 AM July 1 2005 EST -0500 datestr 10:00:00 AM July 1 2005 EST From 9350fb415bc63537cd6f35c3910425e9526fee58 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Thu, 19 May 2011 05:43:48 +0000 Subject: [PATCH 0033/2394] Revert part of the fix for #53339 On OSX we need ssl AND crypto The patch that was applied didn't even match what was in the bug --- acinclude.m4 | 1 + 1 file changed, 1 insertion(+) diff --git a/acinclude.m4 b/acinclude.m4 index c08334b887a90..bf9a4493247b4 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2412,6 +2412,7 @@ AC_DEFUN([PHP_SETUP_OPENSSL],[ -L$OPENSSL_LIBDIR ]) LIBS=$old_LIBS + PHP_ADD_LIBRARY(ssl,,$1) PHP_ADD_LIBRARY(crypto,,$1) PHP_ADD_LIBPATH($OPENSSL_LIBDIR, $1) From 1920f5a690c26b179da9d7fa184fff942b8fb6bf Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 19 May 2011 13:36:29 +0000 Subject: [PATCH 0034/2394] - initial import, will add all libs later --- win32/build/libs_version.txt | 1 + 1 file changed, 1 insertion(+) create mode 100644 win32/build/libs_version.txt diff --git a/win32/build/libs_version.txt b/win32/build/libs_version.txt new file mode 100644 index 0000000000000..8221e190ba84d --- /dev/null +++ b/win32/build/libs_version.txt @@ -0,0 +1 @@ +libcurl-7.21.6 From a9a7f53636569c612770891f483f0e88ea647b48 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Thu, 19 May 2011 16:26:29 +0000 Subject: [PATCH 0035/2394] Decouple "value.str.val = yytext; /* no copying - intentional */ - zendlval->value.str.len = yyleng; - zendlval->type = IS_STRING; - BEGIN(ST_IN_SCRIPTING); - return T_OPEN_TAG_WITH_ECHO; - } else { - goto inline_char_handler; - } + zendlval->value.str.val = yytext; /* no copying - intentional */ + zendlval->value.str.len = yyleng; + zendlval->type = IS_STRING; + BEGIN(ST_IN_SCRIPTING); + return T_OPEN_TAG_WITH_ECHO; } From 81eaa0c7fd4b9da355448f271ab6ad6edc564c62 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Thu, 19 May 2011 17:41:21 +0000 Subject: [PATCH 0036/2394] Tidy up ldap paging code and rename the API as discussed in #42060 --- ext/ldap/ldap.c | 43 ++++++++++--------- ...dap_control_paged_results_variation1.phpt} | 4 +- ...dap_control_paged_results_variation2.phpt} | 4 +- ...dap_control_paged_results_variation3.phpt} | 8 ++-- 4 files changed, 30 insertions(+), 29 deletions(-) rename ext/ldap/tests/{ldap_ctrl_paged_results_variation1.phpt => ldap_control_paged_results_variation1.phpt} (90%) rename ext/ldap/tests/{ldap_ctrl_paged_results_variation2.phpt => ldap_control_paged_results_variation2.phpt} (90%) rename ext/ldap/tests/{ldap_ctrl_paged_results_variation3.phpt => ldap_control_paged_results_variation3.phpt} (86%) diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c index e71f0db5b23f0..0ecb5ddf75bf7 100644 --- a/ext/ldap/ldap.c +++ b/ext/ldap/ldap.c @@ -2186,13 +2186,15 @@ PHP_FUNCTION(ldap_8859_to_t61) #endif #ifdef LDAP_CONTROL_PAGEDRESULTS -/* {{{ proto bool ldap_ctrl_paged_results(resource link, int pagesize [, bool iscritical [, string cookie]]) +/* {{{ proto bool ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) Inject paged results control*/ -PHP_FUNCTION(ldap_ctrl_paged_results) +PHP_FUNCTION(ldap_control_paged_result) { long pagesize; zend_bool iscritical; - zval *link, *cookie; + zval *link; + char *cookie = NULL; + int cookie_len = 0; struct berval lcookie = { 0, NULL }; ldap_linkdata *ld; LDAP *ldap; @@ -2200,11 +2202,11 @@ PHP_FUNCTION(ldap_ctrl_paged_results) LDAPControl ctrl, *ctrlsp[2]; int rc, myargcount = ZEND_NUM_ARGS(); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl|bz", &link, &pagesize, &iscritical, &cookie) != SUCCESS) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl|bs", &link, &pagesize, &iscritical, &cookie, &cookie_len) != SUCCESS) { return; } - if (Z_TYPE_PP(&link) == IS_NULL) { + if (Z_TYPE_P(link) == IS_NULL) { ldap = NULL; } else { ZEND_FETCH_RESOURCE(ld, ldap_linkdata *, &link, -1, "ldap link", le_link); @@ -2221,9 +2223,8 @@ PHP_FUNCTION(ldap_ctrl_paged_results) switch (myargcount) { case 4: - convert_to_string_ex(&cookie); - lcookie.bv_val = Z_STRVAL_PP(&cookie); - lcookie.bv_len = Z_STRLEN_PP(&cookie); + lcookie.bv_val = cookie; + lcookie.bv_len = cookie_len; /* fallthru */ case 3: ctrl.ldctl_iscritical = (int)iscritical; @@ -2232,13 +2233,13 @@ PHP_FUNCTION(ldap_ctrl_paged_results) if (ber_printf(ber, "{iO}", (int)pagesize, &lcookie) == LBER_ERROR) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to BER printf paged results control"); - RETVAL_BOOL(0); + RETVAL_FALSE; goto lcpr_error_out; } rc = ber_flatten2(ber, &ctrl.ldctl_value, 0); if (rc == LBER_ERROR) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to BER encode paged results control"); - RETVAL_BOOL(0); + RETVAL_FALSE; goto lcpr_error_out; } @@ -2252,16 +2253,16 @@ PHP_FUNCTION(ldap_ctrl_paged_results) rc = ldap_set_option(ldap, LDAP_OPT_SERVER_CONTROLS, ctrlsp); if (rc != LDAP_SUCCESS) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to set paged results control: %s (%d)", ldap_err2string(rc), rc); - RETVAL_BOOL(0); + RETVAL_FALSE; goto lcpr_error_out; } - RETVAL_BOOL(1); + RETVAL_TRUE; } else { /* return a PHP control object */ array_init(return_value); add_assoc_string(return_value, "oid", ctrl.ldctl_oid, 1); - if ( ctrl.ldctl_value.bv_len ) { + if (ctrl.ldctl_value.bv_len) { add_assoc_stringl(return_value, "value", ctrl.ldctl_value.bv_val, ctrl.ldctl_value.bv_len, 1); } if (ctrl.ldctl_iscritical) { @@ -2270,16 +2271,16 @@ PHP_FUNCTION(ldap_ctrl_paged_results) } lcpr_error_out: - if (ber != NULL) { + if (ber != NULL) { ber_free(ber, 1); } return; } /* }}} */ -/* {{{ proto bool ldap_ctrl_paged_results_resp(resource link, resource result [, string cookie [, int estimated]]) +/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string cookie [, int estimated]]) Extract paged results control response */ -PHP_FUNCTION(ldap_ctrl_paged_results_resp) +PHP_FUNCTION(ldap_control_paged_result_response) { zval *link, *result, *cookie, *estimated; struct berval lcookie; @@ -2357,8 +2358,8 @@ PHP_FUNCTION(ldap_ctrl_paged_results_resp) zval_dtor(estimated); ZVAL_LONG(estimated, lestimated); } + zval_dtor(cookie); - if (lcookie.bv_len == 0) { ZVAL_EMPTY_STRING(cookie); } else { @@ -2551,14 +2552,14 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_ldap_sort, 0, 0, 3) ZEND_END_ARG_INFO() #ifdef LDAP_CONTROL_PAGEDRESULTS -ZEND_BEGIN_ARG_INFO_EX(arginfo_ldap_ctrl_paged_results, 0, 0, 2) +ZEND_BEGIN_ARG_INFO_EX(arginfo_ldap_control_paged_result, 0, 0, 2) ZEND_ARG_INFO(0, link) ZEND_ARG_INFO(0, pagesize) ZEND_ARG_INFO(0, iscritical) ZEND_ARG_INFO(0, cookie) ZEND_END_ARG_INFO(); -ZEND_BEGIN_ARG_INFO_EX(arginfo_ldap_ctrl_paged_results_resp, 0, 0, 2) +ZEND_BEGIN_ARG_INFO_EX(arginfo_ldap_control_paged_result_response, 0, 0, 2) ZEND_ARG_INFO(0, link) ZEND_ARG_INFO(0, result) ZEND_ARG_INFO(1, cookie) @@ -2709,8 +2710,8 @@ const zend_function_entry ldap_functions[] = { #endif #ifdef LDAP_CONTROL_PAGEDRESULTS - PHP_FE(ldap_ctrl_paged_results, arginfo_ldap_ctrl_paged_results) - PHP_FE(ldap_ctrl_paged_results_resp, arginfo_ldap_ctrl_paged_results_resp) + PHP_FE(ldap_control_paged_result, arginfo_ldap_control_paged_result) + PHP_FE(ldap_control_paged_result_response, arginfo_ldap_control_paged_result_response) #endif {NULL, NULL, NULL} }; diff --git a/ext/ldap/tests/ldap_ctrl_paged_results_variation1.phpt b/ext/ldap/tests/ldap_control_paged_results_variation1.phpt similarity index 90% rename from ext/ldap/tests/ldap_ctrl_paged_results_variation1.phpt rename to ext/ldap/tests/ldap_control_paged_results_variation1.phpt index 88879d974cdd8..7220666099254 100644 --- a/ext/ldap/tests/ldap_ctrl_paged_results_variation1.phpt +++ b/ext/ldap/tests/ldap_control_paged_results_variation1.phpt @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_ctrl_paged_results() test (fetching the first page) +ldap_ldap_control_paged_results() test (fetching the first page) --CREDITS-- Jean-Sebastien Hedde --SKIPIF-- @@ -17,7 +17,7 @@ insert_dummy_data($link); $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; var_dump( - ldap_ctrl_paged_results($link, 1), + ldap_control_paged_results($link, 1), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); diff --git a/ext/ldap/tests/ldap_ctrl_paged_results_variation2.phpt b/ext/ldap/tests/ldap_control_paged_results_variation2.phpt similarity index 90% rename from ext/ldap/tests/ldap_ctrl_paged_results_variation2.phpt rename to ext/ldap/tests/ldap_control_paged_results_variation2.phpt index 7be5a2c2f7511..7cc6d9fc92ed3 100644 --- a/ext/ldap/tests/ldap_ctrl_paged_results_variation2.phpt +++ b/ext/ldap/tests/ldap_control_paged_results_variation2.phpt @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_ctrl_paged_results() test (fetching the first page with a pagesize=2) +ldap_ldap_control_paged_results() test (fetching the first page with a pagesize=2) --CREDITS-- Jean-Sebastien Hedde --SKIPIF-- @@ -17,7 +17,7 @@ insert_dummy_data($link); $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; var_dump( - ldap_ctrl_paged_results($link, 2), + ldap_control_paged_results($link, 2), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); diff --git a/ext/ldap/tests/ldap_ctrl_paged_results_variation3.phpt b/ext/ldap/tests/ldap_control_paged_results_variation3.phpt similarity index 86% rename from ext/ldap/tests/ldap_ctrl_paged_results_variation3.phpt rename to ext/ldap/tests/ldap_control_paged_results_variation3.phpt index 3134c2badb7fc..b5f3a7218b36c 100644 --- a/ext/ldap/tests/ldap_ctrl_paged_results_variation3.phpt +++ b/ext/ldap/tests/ldap_control_paged_results_variation3.phpt @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_ctrl_paged_results() test (fetching the first page then the next final page) +ldap_ldap_control_paged_results() test (fetching the first page then the next final page) --CREDITS-- Jean-Sebastien Hedde --SKIPIF-- @@ -18,11 +18,11 @@ $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; $cookie = ''; var_dump( - ldap_ctrl_paged_results($link, 2, true, $cookie), + ldap_control_paged_results($link, 2, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result), - ldap_ctrl_paged_results_resp($link, $result, $cookie), - ldap_ctrl_paged_results($link, 20, true, $cookie), + ldap_control_paged_results_response($link, $result, $cookie), + ldap_control_paged_results($link, 20, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); From ef2357ce486be9df8ed48dc2efa71fada3696a77 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Thu, 19 May 2011 23:09:58 +0000 Subject: [PATCH 0037/2394] Fix bug 54866 --- TSRM/tsrm_virtual_cwd.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index b88bae90a83cc..ca9809b104d5b 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -617,7 +617,13 @@ CWD_API void realpath_cache_del(const char *path, int path_len TSRMLS_DC) /* {{{ memcmp(path, (*bucket)->path, path_len) == 0) { realpath_cache_bucket *r = *bucket; *bucket = (*bucket)->next; - CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + + /* if the pointers match then only subtract the length of the path */ + if(r->path == r->realpath) + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; + else + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + free(r); return; } else { @@ -692,7 +698,13 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p if (CWDG(realpath_cache_ttl) && (*bucket)->expires < t) { realpath_cache_bucket *r = *bucket; *bucket = (*bucket)->next; - CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + + /* if the pointers match then only subtract the length of the path */ + if(r->path == r->realpath) + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; + else + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + free(r); } else if (key == (*bucket)->key && path_len == (*bucket)->path_len && memcmp(path, (*bucket)->path, path_len) == 0) { From cac66ef3769686a98db7bd43c1c87db49d3bdb66 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Thu, 19 May 2011 23:18:55 +0000 Subject: [PATCH 0038/2394] Fix CS --- TSRM/tsrm_virtual_cwd.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index ca9809b104d5b..1ceaad7b15b6b 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -619,10 +619,11 @@ CWD_API void realpath_cache_del(const char *path, int path_len TSRMLS_DC) /* {{{ *bucket = (*bucket)->next; /* if the pointers match then only subtract the length of the path */ - if(r->path == r->realpath) - CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; - else - CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + if(r->path == r->realpath) { + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; + } else { + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + } free(r); return; @@ -700,11 +701,12 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p *bucket = (*bucket)->next; /* if the pointers match then only subtract the length of the path */ - if(r->path == r->realpath) - CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; - else - CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; - + if(r->path == r->realpath) { + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; + } else { + CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; + } + free(r); } else if (key == (*bucket)->key && path_len == (*bucket)->path_len && memcmp(path, (*bucket)->path, path_len) == 0) { From 180146d49b2030551e98749678747ec8388e1fab Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 19 May 2011 23:20:47 +0000 Subject: [PATCH 0039/2394] - Fixed bug #54804 (__halt_compiler and imported namespaces) (Pierrick) --- Zend/tests/bug54804.inc | 3 +++ Zend/tests/bug54804.phpt | 11 +++++++++++ Zend/zend_compile.c | 4 ++++ 3 files changed, 18 insertions(+) create mode 100644 Zend/tests/bug54804.inc create mode 100644 Zend/tests/bug54804.phpt diff --git a/Zend/tests/bug54804.inc b/Zend/tests/bug54804.inc new file mode 100644 index 0000000000000..74b7a1681d582 --- /dev/null +++ b/Zend/tests/bug54804.inc @@ -0,0 +1,3 @@ + +--EXPECT-- +DONE diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 5c6778f6ca5ca..a3f38d572c9c1 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -5020,6 +5020,10 @@ void zend_do_halt_compiler_register(TSRMLS_D) /* {{{ */ zend_mangle_property_name(&name, &len, haltoff, sizeof(haltoff) - 1, cfilename, clen, 0); zend_register_long_constant(name, len+1, zend_get_scanned_file_offset(TSRMLS_C), CONST_CS, 0 TSRMLS_CC); pefree(name, 0); + + if (CG(in_namespace)) { + zend_do_end_namespace(TSRMLS_C); + } } /* }}} */ From 9e7ae3b2d0e942b816e3836025456544d6288ac3 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Fri, 20 May 2011 18:56:13 +0000 Subject: [PATCH 0040/2394] Allow management of your own padding in openssl_encrypt/decrypt. For using mcrypt / openssl interchangeabley managing your own padding is the only solution. --- ext/openssl/openssl.c | 29 +++++++++++++------- ext/openssl/php_openssl.h | 3 ++ ext/openssl/tests/011.phpt | 15 ++++++---- ext/openssl/tests/bug54060.phpt | 2 +- ext/openssl/tests/bug54061.phpt | 4 +-- ext/openssl/tests/openssl_decrypt_error.phpt | 2 +- 6 files changed, 36 insertions(+), 19 deletions(-) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 784049f626e95..4377d2b52e039 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -350,7 +350,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_openssl_encrypt, 0, 0, 3) ZEND_ARG_INFO(0, data) ZEND_ARG_INFO(0, method) ZEND_ARG_INFO(0, password) - ZEND_ARG_INFO(0, raw_output) + ZEND_ARG_INFO(0, options) ZEND_ARG_INFO(0, iv) ZEND_END_ARG_INFO() @@ -358,7 +358,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_openssl_decrypt, 0, 0, 3) ZEND_ARG_INFO(0, data) ZEND_ARG_INFO(0, method) ZEND_ARG_INFO(0, password) - ZEND_ARG_INFO(0, raw_input) + ZEND_ARG_INFO(0, options) ZEND_ARG_INFO(0, iv) ZEND_END_ARG_INFO() @@ -1089,6 +1089,9 @@ PHP_MINIT_FUNCTION(openssl) REGISTER_LONG_CONSTANT("OPENSSL_KEYTYPE_EC", OPENSSL_KEYTYPE_EC, CONST_CS|CONST_PERSISTENT); #endif + REGISTER_LONG_CONSTANT("OPENSSL_RAW_DATA", OPENSSL_RAW_DATA, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("OPENSSL_ZERO_PADDING", OPENSSL_ZERO_PADDING, CONST_CS|CONST_PERSISTENT); + #if OPENSSL_VERSION_NUMBER >= 0x0090806fL && !defined(OPENSSL_NO_TLSEXT) /* SNI support included in OpenSSL >= 0.9.8j */ REGISTER_LONG_CONSTANT("OPENSSL_TLSEXT_SERVER_NAME", 1, CONST_CS|CONST_PERSISTENT); @@ -4679,11 +4682,11 @@ static zend_bool php_openssl_validate_iv(char **piv, int *piv_len, int iv_requir } -/* {{{ proto string openssl_encrypt(string data, string method, string password [, bool raw_output=false [, string $iv='']]) +/* {{{ proto string openssl_encrypt(string data, string method, string password [, long options=0 [, string $iv='']]) Encrypts given data with given method and key, returns raw or base64 encoded string */ PHP_FUNCTION(openssl_encrypt) { - zend_bool raw_output = 0; + long options = 0; char *data, *method, *password, *iv = ""; int data_len, method_len, password_len, iv_len = 0, max_iv_len; const EVP_CIPHER *cipher_type; @@ -4692,7 +4695,7 @@ PHP_FUNCTION(openssl_encrypt) unsigned char *outbuf, *key; zend_bool free_iv; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|bs", &data, &data_len, &method, &method_len, &password, &password_len, &raw_output, &iv, &iv_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|ls", &data, &data_len, &method, &method_len, &password, &password_len, &options, &iv, &iv_len) == FAILURE) { return; } cipher_type = EVP_get_cipherbyname(method); @@ -4720,11 +4723,14 @@ PHP_FUNCTION(openssl_encrypt) outbuf = emalloc(outlen + 1); EVP_EncryptInit(&cipher_ctx, cipher_type, key, (unsigned char *)iv); + if (options & OPENSSL_ZERO_PADDING) { + EVP_CIPHER_CTX_set_padding(&cipher_ctx, 0); + } EVP_EncryptUpdate(&cipher_ctx, outbuf, &i, (unsigned char *)data, data_len); outlen = i; if (EVP_EncryptFinal(&cipher_ctx, (unsigned char *)outbuf + i, &i)) { outlen += i; - if (raw_output) { + if (options & OPENSSL_RAW_DATA) { outbuf[outlen] = '\0'; RETVAL_STRINGL((char *)outbuf, outlen, 0); } else { @@ -4749,11 +4755,11 @@ PHP_FUNCTION(openssl_encrypt) } /* }}} */ -/* {{{ proto string openssl_decrypt(string data, string method, string password [, bool raw_input=false [, string $iv = '']]) +/* {{{ proto string openssl_decrypt(string data, string method, string password [, long options=0 [, string $iv = '']]) Takes raw or base64 encoded string and dectupt it using given method and key */ PHP_FUNCTION(openssl_decrypt) { - zend_bool raw_input = 0; + long options = 0; char *data, *method, *password, *iv = ""; int data_len, method_len, password_len, iv_len = 0; const EVP_CIPHER *cipher_type; @@ -4764,7 +4770,7 @@ PHP_FUNCTION(openssl_decrypt) char *base64_str = NULL; zend_bool free_iv; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|bs", &data, &data_len, &method, &method_len, &password, &password_len, &raw_input, &iv, &iv_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|ls", &data, &data_len, &method, &method_len, &password, &password_len, &options, &iv, &iv_len) == FAILURE) { return; } @@ -4779,7 +4785,7 @@ PHP_FUNCTION(openssl_decrypt) RETURN_FALSE; } - if (!raw_input) { + if (!(options & OPENSSL_RAW_DATA)) { base64_str = (char*)php_base64_decode((unsigned char*)data, data_len, &base64_str_len); data_len = base64_str_len; data = base64_str; @@ -4800,6 +4806,9 @@ PHP_FUNCTION(openssl_decrypt) outbuf = emalloc(outlen + 1); EVP_DecryptInit(&cipher_ctx, cipher_type, key, (unsigned char *)iv); + if (options & OPENSSL_ZERO_PADDING) { + EVP_CIPHER_CTX_set_padding(&cipher_ctx, 0); + } EVP_DecryptUpdate(&cipher_ctx, outbuf, &i, (unsigned char *)data, data_len); outlen = i; if (EVP_DecryptFinal(&cipher_ctx, (unsigned char *)outbuf + i, &i)) { diff --git a/ext/openssl/php_openssl.h b/ext/openssl/php_openssl.h index dc53eb12826b6..3b3d1e61a96c0 100644 --- a/ext/openssl/php_openssl.h +++ b/ext/openssl/php_openssl.h @@ -26,6 +26,9 @@ extern zend_module_entry openssl_module_entry; #define phpext_openssl_ptr &openssl_module_entry +#define OPENSSL_RAW_DATA 1 +#define OPENSSL_ZERO_PADDING 2 + php_stream_transport_factory_func php_openssl_ssl_socket_factory; PHP_MINIT_FUNCTION(openssl); diff --git a/ext/openssl/tests/011.phpt b/ext/openssl/tests/011.phpt index fdcc5e296a364..118e952a5107e 100644 --- a/ext/openssl/tests/011.phpt +++ b/ext/openssl/tests/011.phpt @@ -13,14 +13,19 @@ $iv = ''; srand(time() + ((microtime(true) * 1000000) % 1000000)); while(strlen($iv) < $ivlen) $iv .= chr(rand(0,255)); -$encrypted = openssl_encrypt($data, $method, $password, false, $iv); -$output = openssl_decrypt($encrypted, $method, $password, false, $iv); +$encrypted = openssl_encrypt($data, $method, $password, 0, $iv); +$output = openssl_decrypt($encrypted, $method, $password, 0, $iv); var_dump($output); -$encrypted = openssl_encrypt($data, $method, $password, true, $iv); -$output = openssl_decrypt($encrypted, $method, $password, true, $iv); +$encrypted = openssl_encrypt($data, $method, $password, OPENSSL_RAW_DATA, $iv); +$output = openssl_decrypt($encrypted, $method, $password, OPENSSL_RAW_DATA, $iv); var_dump($output); +// if we want to manage our own padding +$padded_data = $data . str_repeat(' ', 16 - (strlen($data) % 16)); +$encrypted = openssl_encrypt($padded_data, $method, $password, OPENSSL_RAW_DATA|OPENSSL_ZERO_PADDING, $iv); +$output = openssl_decrypt($encrypted, $method, $password, OPENSSL_RAW_DATA|OPENSSL_ZERO_PADDING, $iv); +var_dump(rtrim($output)); ?> --EXPECT-- string(45) "openssl_encrypt() and openssl_decrypt() tests" string(45) "openssl_encrypt() and openssl_decrypt() tests" - +string(45) "openssl_encrypt() and openssl_decrypt() tests" diff --git a/ext/openssl/tests/bug54060.phpt b/ext/openssl/tests/bug54060.phpt index fe8ca94a5fe59..88f1f944df9cc 100644 --- a/ext/openssl/tests/bug54060.phpt +++ b/ext/openssl/tests/bug54060.phpt @@ -10,7 +10,7 @@ r7-89437 r892374 r894372 r894 7289r7 f frwerfh i iurf iuryw uyrfouiwy ruy 972439 8478942 yrhfjkdhls"; $pass = "r23498rui324hjbnkj"; -openssl_encrypt($data, 'des3', $pass, false, '1qazxsw2'); +openssl_encrypt($data, 'des3', $pass, 0, '1qazxsw2'); echo "Done"; ?> --EXPECT-- diff --git a/ext/openssl/tests/bug54061.phpt b/ext/openssl/tests/bug54061.phpt index cef3944119112..f1d2e24a28975 100644 --- a/ext/openssl/tests/bug54061.phpt +++ b/ext/openssl/tests/bug54061.phpt @@ -9,8 +9,8 @@ r7-89437 r892374 r894372 r894 7289r7 f frwerfh i iurf iuryw uyrfouiwy ruy 972439 8478942 yrhfjkdhls"; $pass = "r23498rui324hjbnkj"; -$cr = openssl_encrypt($data, 'des3', $pass, false, '1qazxsw2'); -$dcr = openssl_decrypt($cr, 'des3', $pass, false, '1qazxsw2'); +$cr = openssl_encrypt($data, 'des3', $pass, 0, '1qazxsw2'); +$dcr = openssl_decrypt($cr, 'des3', $pass, 0, '1qazxsw2'); echo "Done"; ?> --EXPECT-- diff --git a/ext/openssl/tests/openssl_decrypt_error.phpt b/ext/openssl/tests/openssl_decrypt_error.phpt index 233fa0c5bdf7b..40debbd04f2d3 100644 --- a/ext/openssl/tests/openssl_decrypt_error.phpt +++ b/ext/openssl/tests/openssl_decrypt_error.phpt @@ -12,7 +12,7 @@ $iv = str_repeat("\0", openssl_cipher_iv_length($method)); $encrypted = openssl_encrypt($data, $method, $password); var_dump($encrypted); /* Not passing $iv should be the same as all-NULL iv, but with a warning */ -var_dump(openssl_encrypt($data, $method, $password, false, $iv)); +var_dump(openssl_encrypt($data, $method, $password, 0, $iv)); var_dump(openssl_decrypt($encrypted, $method, $wrong)); var_dump(openssl_decrypt($encrypted, $wrong, $password)); var_dump(openssl_decrypt($wrong, $method, $password)); From ac6edb41ecb219fa399b9295b457de5c9833b7be Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 20 May 2011 21:24:51 +0000 Subject: [PATCH 0041/2394] - Fixed bug #54895 (Fix compiling with older gcc version without need for membar_producer macro) patch by: mhei at heimpold dot de --- ext/standard/php_crypt_r.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index 15db3d9b036aa..cd3746258cd4d 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -94,7 +94,7 @@ void _crypt_extended_init_r(void) if (!initialized) { #ifdef PHP_WIN32 InterlockedIncrement(&initialized); -#elif (defined(__GNUC__) && (__GNUC__ >= 4 && __GNUC_MINOR__ >= 2)) +#elif (defined(__GNUC__) && (__GNUC__ >= 4 && __GNUC_MINOR__ >= 1)) __sync_fetch_and_add(&initialized, 1); #elif defined(HAVE_ATOMIC_H) /* Solaris 10 defines atomic API within */ membar_producer(); From cebe2a21396c5c23220314b3785231003209c1e5 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sat, 21 May 2011 19:48:37 +0000 Subject: [PATCH 0042/2394] Increase the overly conservative pcre backtrack limit from 100000 to 1000000 --- ext/pcre/php_pcre.c | 2 +- ext/standard/tests/general_functions/ini_get_all.phpt | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index a9d6ad0ff2acf..cc96fafe87793 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -115,7 +115,7 @@ static PHP_GSHUTDOWN_FUNCTION(pcre) /* {{{ */ /* }}} */ PHP_INI_BEGIN() - STD_PHP_INI_ENTRY("pcre.backtrack_limit", "100000", PHP_INI_ALL, OnUpdateLong, backtrack_limit, zend_pcre_globals, pcre_globals) + STD_PHP_INI_ENTRY("pcre.backtrack_limit", "1000000", PHP_INI_ALL, OnUpdateLong, backtrack_limit, zend_pcre_globals, pcre_globals) STD_PHP_INI_ENTRY("pcre.recursion_limit", "100000", PHP_INI_ALL, OnUpdateLong, recursion_limit, zend_pcre_globals, pcre_globals) PHP_INI_END() diff --git a/ext/standard/tests/general_functions/ini_get_all.phpt b/ext/standard/tests/general_functions/ini_get_all.phpt index a13b0a4751bcf..7b3572c0bbc1f 100644 --- a/ext/standard/tests/general_functions/ini_get_all.phpt +++ b/ext/standard/tests/general_functions/ini_get_all.phpt @@ -1,7 +1,7 @@ --TEST-- ini_get_all() tests --INI-- -pcre.backtrack_limit=100000 +pcre.backtrack_limit=1000000 pcre.recursion_limit=100000 --SKIPIF-- @@ -34,9 +34,9 @@ array(2) { ["pcre.backtrack_limit"]=> array(3) { ["global_value"]=> - string(6) "100000" + string(6) "1000000" ["local_value"]=> - string(6) "100000" + string(6) "1000000" ["access"]=> int(7) } @@ -52,7 +52,7 @@ array(2) { } array(2) { ["pcre.backtrack_limit"]=> - string(6) "100000" + string(6) "1000000" ["pcre.recursion_limit"]=> string(6) "100000" } From 584f1c438105ff520d43488e7173418f8af7fbec Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 22 May 2011 19:06:21 +0000 Subject: [PATCH 0043/2394] - Fixed bug #54269 (Short exception message buffer causes crash) --- ext/interbase/php_ibase_includes.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/interbase/php_ibase_includes.h b/ext/interbase/php_ibase_includes.h index ec37d211e21ae..a5cd9d794e69e 100755 --- a/ext/interbase/php_ibase_includes.h +++ b/ext/interbase/php_ibase_includes.h @@ -51,7 +51,7 @@ extern int le_link, le_plink, le_trans; #define LE_PLINK "Firebird/InterBase persistent link" #define LE_TRANS "Firebird/InterBase transaction" -#define IBASE_MSGSIZE 256 +#define IBASE_MSGSIZE 512 #define MAX_ERRMSG (IBASE_MSGSIZE*2) #define IB_DEF_DATE_FMT "%Y-%m-%d" From 184f80ff668737dbb181421feec577a18858118d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 23 May 2011 01:47:06 +0000 Subject: [PATCH 0044/2394] - Fixed bug #54529 (SAPI crashes on apache_config.c:197) patch by: hebergement at riastudio dot fr --- sapi/apache2handler/apache_config.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/sapi/apache2handler/apache_config.c b/sapi/apache2handler/apache_config.c index e48e23b13583e..37a2195ab93b0 100644 --- a/sapi/apache2handler/apache_config.c +++ b/sapi/apache2handler/apache_config.c @@ -192,11 +192,12 @@ void apply_config(void *dummy) zend_hash_get_current_key_ex(&d->config, &str, &str_len, NULL, 0, NULL) == HASH_KEY_IS_STRING; zend_hash_move_forward(&d->config)) { - zend_hash_get_current_data(&d->config, (void **) &data); - phpapdebug((stderr, "APPLYING (%s)(%s)\n", str, data->value)); - if (zend_alter_ini_entry(str, str_len, data->value, data->value_len, data->status, data->htaccess?PHP_INI_STAGE_HTACCESS:PHP_INI_STAGE_ACTIVATE) == FAILURE) { - phpapdebug((stderr, "..FAILED\n")); - } + if (zend_hash_get_current_data(&d->config, (void **) &data) == SUCCESS) { + phpapdebug((stderr, "APPLYING (%s)(%s)\n", str, data->value)); + if (zend_alter_ini_entry(str, str_len, data->value, data->value_len, data->status, data->htaccess?PHP_INI_STAGE_HTACCESS:PHP_INI_STAGE_ACTIVATE) == FAILURE) { + phpapdebug((stderr, "..FAILED\n")); + } + } } } From 9b8acf87a6a2df032e3155de384695ce4f9d32fe Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 23 May 2011 07:06:04 +0000 Subject: [PATCH 0045/2394] fix some failing tests --- ext/standard/tests/file/005_variation2.phpt | 6 ------ ext/standard/tests/file/umask_variation3.phpt | 6 +++--- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/ext/standard/tests/file/005_variation2.phpt b/ext/standard/tests/file/005_variation2.phpt index d70ce1251e61a..51919dba60e49 100644 --- a/ext/standard/tests/file/005_variation2.phpt +++ b/ext/standard/tests/file/005_variation2.phpt @@ -71,14 +71,8 @@ echo "Done"; *** Testing fileattime(), filemtime(), filectime() & touch() : usage variations *** *** testing touch *** - -Warning: touch(): Unable to create file because %s in %s on line %d bool(false) - -Warning: touch(): Unable to create file because %s in %s on line %d bool(false) - -Warning: touch(): Unable to create file because %s in %s on line %d bool(false) bool(true) bool(true) diff --git a/ext/standard/tests/file/umask_variation3.phpt b/ext/standard/tests/file/umask_variation3.phpt index 1483dc430e590..c666c328df72b 100644 --- a/ext/standard/tests/file/umask_variation3.phpt +++ b/ext/standard/tests/file/umask_variation3.phpt @@ -11,9 +11,9 @@ if (substr(PHP_OS, 0, 3) == 'WIN') { --FILE-- $value) { echo "\n--$key--\n"; umask(0); var_dump(umask($value)); - var_dump( umask()); + var_dump( umask() & 0777); }; ?> From b7eb3c1c5a858e98985adc2335df9b4a021ade51 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 23 May 2011 08:05:44 +0000 Subject: [PATCH 0046/2394] Arithmetic speedup. Inlined most probable code-paths for arithmetic operations directly into executor. --- NEWS | 2 + Zend/zend_multiply.h | 12 + Zend/zend_operators.c | 3 - Zend/zend_operators.h | 416 +++++++++++++++++++++++++++++++++ Zend/zend_vm_def.h | 46 ++-- Zend/zend_vm_execute.h | 512 ++++++++++++++++++----------------------- 6 files changed, 675 insertions(+), 316 deletions(-) diff --git a/NEWS b/NEWS index 47d0f9d6742e5..972d0e7503e11 100644 --- a/NEWS +++ b/NEWS @@ -80,6 +80,8 @@ PHP NEWS opcode operands into a separate literal table. (Dmitry) - Improved Zend Engine, performance tweaks and optimizations: (Dmitry) + . Inlined most probable code-paths for arithmetic operations directly into + executor . Eliminated unnecessary iterations during request startup/shutdown. . Changed $GLOBALS into a JIT autoglobal, so it's initialized only if used. (this may affect opcode caches!) diff --git a/Zend/zend_multiply.h b/Zend/zend_multiply.h index 45eba053e3fe1..35b293fad1f77 100644 --- a/Zend/zend_multiply.h +++ b/Zend/zend_multiply.h @@ -31,6 +31,18 @@ else (lval) = __tmpvar; \ } while (0) +#elif defined(__x86_64__) && defined(__GNUC__) + +#define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ + long __tmpvar; \ + __asm__ ("imulq %3,%0\n" \ + "adcq $0,%1" \ + : "=r"(__tmpvar),"=r"(usedval) \ + : "0"(a), "r"(b), "1"(0)); \ + if (usedval) (dval) = (double) (a) * (double) (b); \ + else (lval) = __tmpvar; \ +} while (0) + #elif SIZEOF_LONG == 4 && defined(HAVE_ZEND_LONG64) #define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index 187d9f2308e1d..2f4905324c157 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -27,13 +27,10 @@ #include "zend_globals.h" #include "zend_list.h" #include "zend_API.h" -#include "zend_multiply.h" #include "zend_strtod.h" #include "zend_exceptions.h" #include "zend_closures.h" -#define LONG_SIGN_MASK (1L << (8*sizeof(long)-1)) - #if ZEND_USE_TOLOWER_L #include static _locale_t current_locale = NULL; diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 50b7b514e2ead..6987409f16433 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -31,11 +31,14 @@ #endif #include "zend_strtod.h" +#include "zend_multiply.h" #if 0&&HAVE_BCMATH #include "ext/bcmath/libbcmath/src/bcmath.h" #endif +#define LONG_SIGN_MASK (1L << (8*sizeof(long)-1)) + BEGIN_EXTERN_C() ZEND_API int add_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); ZEND_API int sub_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); @@ -448,6 +451,419 @@ ZEND_API void zend_update_current_locale(void); #define zend_update_current_locale() #endif +#define offsetof(t,f) \ + ((int)(&((t*)0)->f)) + +static zend_always_inline int fast_increment_function(zval *op1) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { +#if defined(__GNUC__) && defined(__i386__) + __asm__( + "incl (%0)\n\t" + "jno 0f\n\t" + "movl $0x0, (%0)\n\t" + "movl $0x41e00000, 0x4(%0)\n\t" + "movb $0x2,0xc(%0)\n" + "0:" + : + : "r"(op1)); +#elif defined(__GNUC__) && defined(__x86_64__) + __asm__( + "incq (%0)\n\t" + "jno 0f\n\t" + "movl $0x0, (%0)\n\t" + "movl $0x43e00000, 0x4(%0)\n\t" + "movb $0x2,0x14(%0)\n" + "0:" + : + : "r"(op1)); +#else + if (UNEXPECTED(Z_LVAL_P(op1) == LONG_MAX)) { + /* switch to double */ + Z_DVAL_P(op1) = (double)LONG_MAX + 1.0; + Z_TYPE_P(op1) = IS_DOUBLE; + } else { + Z_LVAL_P(op1)++; + } +#endif + return SUCCESS; + } + return increment_function(op1); +} + +static zend_always_inline int fast_decrement_function(zval *op1) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { +#if defined(__GNUC__) && defined(__i386__) + __asm__( + "decl (%0)\n\t" + "jno 0f\n\t" + "movl $0x00200000, (%0)\n\t" + "movl $0xc1e00000, 0x4(%0)\n\t" + "movb $0x2,0xc(%0)\n" + "0:" + : + : "r"(op1)); +#elif defined(__GNUC__) && defined(__x86_64__) + __asm__( + "decq (%0)\n\t" + "jno 0f\n\t" + "movl $0x00000000, (%0)\n\t" + "movl $0xc3e00000, 0x4(%0)\n\t" + "movb $0x2,0x14(%0)\n" + "0:" + : + : "r"(op1)); +#else + if (UNEXPECTED(Z_LVAL_P(op1) == LONG_MIN)) { + /* switch to double */ + Z_DVAL_P(op1) = (double)LONG_MIN - 1.0; + Z_TYPE_P(op1) = IS_DOUBLE; + } else { + Z_LVAL_P(op1)--; + } +#endif + return SUCCESS; + } + return decrement_function(op1); +} + +static zend_always_inline int fast_add_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { +#if defined(__GNUC__) && defined(__i386__) + __asm__( + "movl (%1), %%eax\n\t" + "addl (%2), %%eax\n\t" + "jo 0f\n\t" + "movl %%eax, (%0)\n\t" + "movb $0x1,0xc(%0)\n\t" + "jmp 1f\n" + "0:\n\t" + "fildl (%1)\n\t" + "fildl (%2)\n\t" + "faddp %%st, %%st(1)\n\t" + "movb $0x2,0xc(%0)\n\t" + "fstpl (%0)\n" + "1:" + : + : "r"(result), + "r"(op1), + "r"(op2) + : "eax"); +#elif defined(__GNUC__) && defined(__x86_64__) + __asm__( + "movq (%1), %%rax\n\t" + "addq (%2), %%rax\n\t" + "jo 0f\n\t" + "movq %%rax, (%0)\n\t" + "movb $0x1,0x14(%0)\n\t" + "jmp 1f\n" + "0:\n\t" + "fildq (%1)\n\t" + "fildq (%2)\n\t" + "faddp %%st, %%st(1)\n\t" + "movb $0x2,0x14(%0)\n\t" + "fstpl (%0)\n" + "1:" + : + : "r"(result), + "r"(op1), + "r"(op2) + : "rax"); +#else + Z_LVAL_P(result) = Z_LVAL_P(op1) + Z_LVAL_P(op2); + + if (UNEXPECTED((Z_LVAL_P(op1) & LONG_SIGN_MASK) == (Z_LVAL_P(op2) & LONG_SIGN_MASK) + && (Z_LVAL_P(op1) & LONG_SIGN_MASK) != (Z_LVAL_P(result) & LONG_SIGN_MASK))) { + Z_DVAL_P(result) = (double) Z_LVAL_P(op1) + (double) Z_LVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + } else { + Z_TYPE_P(result) = IS_LONG; + } +#endif + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + Z_DVAL_P(result) = ((double)Z_LVAL_P(op1)) + Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + Z_DVAL_P(result) = Z_DVAL_P(op1) + Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + Z_DVAL_P(result) = Z_DVAL_P(op1) + ((double)Z_LVAL_P(op2)); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } + return add_function(result, op1, op2 TSRMLS_CC); +} + +static zend_always_inline int fast_sub_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { +#if defined(__GNUC__) && defined(__i386__) + __asm__( + "movl (%1), %%eax\n\t" + "subl (%2), %%eax\n\t" + "jo 0f\n\t" + "movl %%eax, (%0)\n\t" + "movb $0x1,0xc(%0)\n\t" + "jmp 1f\n" + "0:\n\t" + "fildl (%2)\n\t" + "fildl (%1)\n\t" + "fsubp %%st, %%st(1)\n\t" + "movb $0x2,0xc(%0)\n\t" + "fstpl (%0)\n" + "1:" + : + : "r"(result), + "r"(op1), + "r"(op2) + : "eax"); +#elif defined(__GNUC__) && defined(__x86_64__) + __asm__( + "movq (%1), %%rax\n\t" + "subq (%2), %%rax\n\t" + "jo 0f\n\t" + "movq %%rax, (%0)\n\t" + "movb $0x1,0x14(%0)\n\t" + "jmp 1f\n" + "0:\n\t" + "fildq (%2)\n\t" + "fildq (%1)\n\t" + "fsubp %%st, %%st(1)\n\t" + "movb $0x2,0x14(%0)\n\t" + "fstpl (%0)\n" + "1:" + : + : "r"(result), + "r"(op1), + "r"(op2) + : "rax"); +#else + Z_LVAL_P(result) = Z_LVAL_P(op1) - Z_LVAL_P(op2); + + if (UNEXPECTED((Z_LVAL_P(op1) & LONG_SIGN_MASK) != (Z_LVAL_P(op2) & LONG_SIGN_MASK) + && (Z_LVAL_P(op1) & LONG_SIGN_MASK) != (Z_LVAL_P(result) & LONG_SIGN_MASK))) { + Z_DVAL_P(result) = (double) Z_LVAL_P(op1) + (double) Z_LVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + } else { + Z_TYPE_P(result) = IS_LONG; + } +#endif + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + Z_DVAL_P(result) = ((double)Z_LVAL_P(op1)) - Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + Z_DVAL_P(result) = Z_DVAL_P(op1) - Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + Z_DVAL_P(result) = Z_DVAL_P(op1) - ((double)Z_LVAL_P(op2)); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } + return sub_function(result, op1, op2 TSRMLS_CC); +} + +static zend_always_inline int fast_mul_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + long overflow; + + ZEND_SIGNED_MULTIPLY_LONG(Z_LVAL_P(op1), Z_LVAL_P(op2), Z_LVAL_P(result), Z_DVAL_P(result), overflow); + Z_TYPE_P(result) = overflow ? IS_DOUBLE : IS_LONG; + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + Z_DVAL_P(result) = ((double)Z_LVAL_P(op1)) * Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + Z_DVAL_P(result) = Z_DVAL_P(op1) * Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + Z_DVAL_P(result) = Z_DVAL_P(op1) * ((double)Z_LVAL_P(op2)); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } + return mul_function(result, op1, op2 TSRMLS_CC); +} + +static zend_always_inline int fast_div_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG) && 0) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + if (UNEXPECTED(Z_LVAL_P(op2) == 0)) { + zend_error(E_WARNING, "Division by zero"); + Z_LVAL_P(result) = 0; + Z_TYPE_P(result) = IS_BOOL; + return FAILURE; + } else if (UNEXPECTED(Z_LVAL_P(op2) == -1 && Z_LVAL_P(op1) == LONG_MIN)) { + /* Prevent overflow error/crash */ + Z_DVAL_P(result) = (double) LONG_MIN / -1; + Z_TYPE_P(result) = IS_DOUBLE; + } else if (EXPECTED(Z_LVAL_P(op1) % Z_LVAL_P(op2) == 0)) { + /* integer */ + Z_LVAL_P(result) = Z_LVAL_P(op1) / Z_LVAL_P(op2); + Z_TYPE_P(result) = IS_LONG; + } else { + Z_DVAL_P(result) = ((double) Z_LVAL_P(op1)) / ((double)Z_LVAL_P(op2)); + Z_TYPE_P(result) = IS_DOUBLE; + } + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + if (UNEXPECTED(Z_DVAL_P(op2) == 0)) { + zend_error(E_WARNING, "Division by zero"); + Z_LVAL_P(result) = 0; + Z_TYPE_P(result) = IS_BOOL; + return FAILURE; + } + Z_DVAL_P(result) = ((double)Z_LVAL_P(op1)) / Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE) && 0) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + if (UNEXPECTED(Z_DVAL_P(op2) == 0)) { + zend_error(E_WARNING, "Division by zero"); + Z_LVAL_P(result) = 0; + Z_TYPE_P(result) = IS_BOOL; + return FAILURE; + } + Z_DVAL_P(result) = Z_DVAL_P(op1) / Z_DVAL_P(op2); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + if (UNEXPECTED(Z_LVAL_P(op2) == 0)) { + zend_error(E_WARNING, "Division by zero"); + Z_LVAL_P(result) = 0; + Z_TYPE_P(result) = IS_BOOL; + return FAILURE; + } + Z_DVAL_P(result) = Z_DVAL_P(op1) / ((double)Z_LVAL_P(op2)); + Z_TYPE_P(result) = IS_DOUBLE; + return SUCCESS; + } + } + return div_function(result, op1, op2 TSRMLS_CC); +} + +static zend_always_inline int fast_mod_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + if (UNEXPECTED(Z_LVAL_P(op2) == 0)) { + zend_error(E_WARNING, "Division by zero"); + Z_LVAL_P(result) = 0; + Z_TYPE_P(result) = IS_BOOL; + return FAILURE; + } else if (UNEXPECTED(Z_LVAL_P(op2) == -1)) { + /* Prevent overflow error/crash if op1==LONG_MIN */ + Z_LVAL_P(result) = 0; + Z_TYPE_P(result) = IS_LONG; + return SUCCESS; + } + Z_LVAL_P(result) = Z_LVAL_P(op1) % Z_LVAL_P(op2); + Z_TYPE_P(result) = IS_LONG; + return SUCCESS; + } + } + return mod_function(result, op1, op2 TSRMLS_CC); +} + +static zend_always_inline int fast_equal_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_LVAL_P(op1) == Z_LVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return ((double)Z_LVAL_P(op1)) == Z_DVAL_P(op2); + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return Z_DVAL_P(op1) == Z_DVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_DVAL_P(op1) == ((double)Z_LVAL_P(op2)); + } + } + compare_function(result, op1, op2 TSRMLS_CC); + return Z_LVAL_P(result) == 0; +} + +static zend_always_inline int fast_not_equal_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_LVAL_P(op1) != Z_LVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return ((double)Z_LVAL_P(op1)) != Z_DVAL_P(op2); + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return Z_DVAL_P(op1) != Z_DVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_DVAL_P(op1) != ((double)Z_LVAL_P(op2)); + } + } + compare_function(result, op1, op2 TSRMLS_CC); + return Z_LVAL_P(result) != 0; +} + +static zend_always_inline int fast_is_smaller_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_LVAL_P(op1) < Z_LVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return ((double)Z_LVAL_P(op1)) < Z_DVAL_P(op2); + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return Z_DVAL_P(op1) < Z_DVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_DVAL_P(op1) < ((double)Z_LVAL_P(op2)); + } + } + compare_function(result, op1, op2 TSRMLS_CC); + return Z_LVAL_P(result) < 0; +} + +static zend_always_inline int fast_is_smaller_or_equal_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) +{ + if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_LVAL_P(op1) <= Z_LVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return ((double)Z_LVAL_P(op1)) <= Z_DVAL_P(op2); + } + } else if (EXPECTED(Z_TYPE_P(op1) == IS_DOUBLE)) { + if (EXPECTED(Z_TYPE_P(op2) == IS_DOUBLE)) { + return Z_DVAL_P(op1) <= Z_DVAL_P(op2); + } else if (EXPECTED(Z_TYPE_P(op2) == IS_LONG)) { + return Z_DVAL_P(op1) <= ((double)Z_LVAL_P(op2)); + } + } + compare_function(result, op1, op2 TSRMLS_CC); + return Z_LVAL_P(result) <= 0; +} + #endif /* diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 13daae19fe64c..a76352799a06f 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -31,7 +31,7 @@ ZEND_VM_HANDLER(1, ZEND_ADD, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zend_free_op free_op1, free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, GET_OP1_ZVAL_PTR(BP_VAR_R), GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); FREE_OP1(); @@ -46,7 +46,7 @@ ZEND_VM_HANDLER(2, ZEND_SUB, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zend_free_op free_op1, free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, GET_OP1_ZVAL_PTR(BP_VAR_R), GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); FREE_OP1(); @@ -61,7 +61,7 @@ ZEND_VM_HANDLER(3, ZEND_MUL, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, GET_OP1_ZVAL_PTR(BP_VAR_R), GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); FREE_OP1(); @@ -76,7 +76,7 @@ ZEND_VM_HANDLER(4, ZEND_DIV, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zend_free_op free_op1, free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, GET_OP1_ZVAL_PTR(BP_VAR_R), GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); FREE_OP1(); @@ -91,7 +91,7 @@ ZEND_VM_HANDLER(5, ZEND_MOD, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, GET_OP1_ZVAL_PTR(BP_VAR_R), GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); FREE_OP1(); @@ -184,10 +184,9 @@ ZEND_VM_HANDLER(17, ZEND_IS_EQUAL, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, GET_OP1_ZVAL_PTR(BP_VAR_R), - GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC)); FREE_OP1(); FREE_OP2(); CHECK_EXCEPTION(); @@ -201,10 +200,9 @@ ZEND_VM_HANDLER(18, ZEND_IS_NOT_EQUAL, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, GET_OP1_ZVAL_PTR(BP_VAR_R), - GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC)); FREE_OP1(); FREE_OP2(); CHECK_EXCEPTION(); @@ -218,10 +216,9 @@ ZEND_VM_HANDLER(19, ZEND_IS_SMALLER, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, GET_OP1_ZVAL_PTR(BP_VAR_R), - GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC)); FREE_OP1(); FREE_OP2(); CHECK_EXCEPTION(); @@ -235,10 +232,9 @@ ZEND_VM_HANDLER(20, ZEND_IS_SMALLER_OR_EQUAL, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, GET_OP1_ZVAL_PTR(BP_VAR_R), - GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + GET_OP2_ZVAL_PTR(BP_VAR_R) TSRMLS_CC)); FREE_OP1(); FREE_OP2(); CHECK_EXCEPTION(); @@ -824,11 +820,11 @@ ZEND_VM_HANDLER(34, ZEND_PRE_INC, VAR|CV, ANY) /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - increment_function(val); + fast_increment_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - increment_function(*var_ptr); + fast_increment_function(*var_ptr); } if (RETURN_VALUE_USED(opline)) { @@ -871,11 +867,11 @@ ZEND_VM_HANDLER(35, ZEND_PRE_DEC, VAR|CV, ANY) /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - decrement_function(val); + fast_decrement_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - decrement_function(*var_ptr); + fast_decrement_function(*var_ptr); } if (RETURN_VALUE_USED(opline)) { @@ -919,11 +915,11 @@ ZEND_VM_HANDLER(36, ZEND_POST_INC, VAR|CV, ANY) /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - increment_function(val); + fast_increment_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - increment_function(*var_ptr); + fast_increment_function(*var_ptr); } FREE_OP1_VAR_PTR(); @@ -962,11 +958,11 @@ ZEND_VM_HANDLER(37, ZEND_POST_DEC, VAR|CV, ANY) /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - decrement_function(val); + fast_decrement_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - decrement_function(*var_ptr); + fast_decrement_function(*var_ptr); } FREE_OP1_VAR_PTR(); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index c990da6b6ba4c..899aa572bd724 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -2614,7 +2614,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, opline->op2.zv TSRMLS_CC); @@ -2629,7 +2629,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, opline->op2.zv TSRMLS_CC); @@ -2644,7 +2644,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, opline->op2.zv TSRMLS_CC); @@ -2659,7 +2659,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, opline->op2.zv TSRMLS_CC); @@ -2674,7 +2674,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, opline->op2.zv TSRMLS_CC); @@ -2767,10 +2767,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -2784,10 +2783,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -2801,10 +2799,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_H zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -2818,10 +2815,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -3582,7 +3578,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -3597,7 +3593,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -3612,7 +3608,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -3627,7 +3623,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -3642,7 +3638,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -3735,10 +3731,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -3752,10 +3747,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_H zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -3769,10 +3763,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -3786,10 +3779,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_O zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4093,7 +4085,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -4108,7 +4100,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -4123,7 +4115,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -4138,7 +4130,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -4153,7 +4145,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -4246,10 +4238,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -4263,10 +4254,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_H zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -4280,10 +4270,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -4297,10 +4286,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_O zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5441,7 +5429,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -5456,7 +5444,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -5471,7 +5459,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -5486,7 +5474,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -5501,7 +5489,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -5594,10 +5582,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -5611,10 +5598,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HA zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -5628,10 +5614,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -5645,10 +5630,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OP zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -6934,7 +6918,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -6949,7 +6933,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -6964,7 +6948,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -6979,7 +6963,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -6994,7 +6978,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -7087,10 +7071,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -7104,10 +7087,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_H zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -7121,10 +7103,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -7138,10 +7119,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_O zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -7773,7 +7753,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -7788,7 +7768,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -7803,7 +7783,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -7818,7 +7798,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -7833,7 +7813,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -7926,10 +7906,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -7943,10 +7922,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -7960,10 +7938,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -7977,10 +7954,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPC zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -8286,7 +8262,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -8301,7 +8277,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -8316,7 +8292,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -8331,7 +8307,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -8346,7 +8322,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -8439,10 +8415,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -8456,10 +8431,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -8473,10 +8447,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -8490,10 +8463,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPC zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -9505,7 +9477,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -9520,7 +9492,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -9535,7 +9507,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -9550,7 +9522,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -9565,7 +9537,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); @@ -9658,10 +9630,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -9675,10 +9646,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HAND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -9692,10 +9662,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -9709,10 +9678,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCO zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -10065,11 +10033,11 @@ static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - increment_function(val); + fast_increment_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - increment_function(*var_ptr); + fast_increment_function(*var_ptr); } if (RETURN_VALUE_USED(opline)) { @@ -10112,11 +10080,11 @@ static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - decrement_function(val); + fast_decrement_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - decrement_function(*var_ptr); + fast_decrement_function(*var_ptr); } if (RETURN_VALUE_USED(opline)) { @@ -10160,11 +10128,11 @@ static int ZEND_FASTCALL ZEND_POST_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - increment_function(val); + fast_increment_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - increment_function(*var_ptr); + fast_increment_function(*var_ptr); } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -10203,11 +10171,11 @@ static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - decrement_function(val); + fast_decrement_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - decrement_function(*var_ptr); + fast_decrement_function(*var_ptr); } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -11343,7 +11311,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -11358,7 +11326,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -11373,7 +11341,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -11388,7 +11356,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -11403,7 +11371,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR zend_free_op free_op1; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -11496,10 +11464,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -11513,10 +11480,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -11530,10 +11496,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -11547,10 +11512,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_O zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -13636,7 +13600,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -13651,7 +13615,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -13666,7 +13630,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -13681,7 +13645,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -13696,7 +13660,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -13789,10 +13753,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -13806,10 +13769,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -13823,10 +13785,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -13840,10 +13801,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPC zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -15539,7 +15499,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15554,7 +15514,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15569,7 +15529,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15584,7 +15544,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15599,7 +15559,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_free_op free_op1, free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15692,10 +15652,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -15709,10 +15668,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -15726,10 +15684,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -15743,10 +15700,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPC zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18759,7 +18715,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -18774,7 +18730,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -18789,7 +18745,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -18804,7 +18760,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -18819,7 +18775,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -18912,10 +18868,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -18929,10 +18884,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -18946,10 +18900,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -18963,10 +18916,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCO zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -25774,11 +25726,11 @@ static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - increment_function(val); + fast_increment_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - increment_function(*var_ptr); + fast_increment_function(*var_ptr); } if (RETURN_VALUE_USED(opline)) { @@ -25820,11 +25772,11 @@ static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - decrement_function(val); + fast_decrement_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - decrement_function(*var_ptr); + fast_decrement_function(*var_ptr); } if (RETURN_VALUE_USED(opline)) { @@ -25867,11 +25819,11 @@ static int ZEND_FASTCALL ZEND_POST_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - increment_function(val); + fast_increment_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - increment_function(*var_ptr); + fast_increment_function(*var_ptr); } CHECK_EXCEPTION(); @@ -25909,11 +25861,11 @@ static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* proxy object */ zval *val = Z_OBJ_HANDLER_PP(var_ptr, get)(*var_ptr TSRMLS_CC); Z_ADDREF_P(val); - decrement_function(val); + fast_decrement_function(val); Z_OBJ_HANDLER_PP(var_ptr, set)(var_ptr, val TSRMLS_CC); zval_ptr_dtor(&val); } else { - decrement_function(*var_ptr); + fast_decrement_function(*var_ptr); } CHECK_EXCEPTION(); @@ -26876,7 +26828,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -26891,7 +26843,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -26906,7 +26858,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -26921,7 +26873,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -26936,7 +26888,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -27029,10 +26981,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -27046,10 +26997,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -27063,10 +27013,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -27080,10 +27029,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OP zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - opline->op2.zv TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + opline->op2.zv TSRMLS_CC)); CHECK_EXCEPTION(); @@ -28952,7 +28900,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -28967,7 +28915,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -28982,7 +28930,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -28997,7 +28945,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -29012,7 +28960,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -29105,10 +29053,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -29122,10 +29069,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -29139,10 +29085,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -29156,10 +29101,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCO zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -30729,7 +30673,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -30744,7 +30688,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -30759,7 +30703,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -30774,7 +30718,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -30789,7 +30733,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op2; SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); @@ -30882,10 +30826,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -30899,10 +30842,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -30916,10 +30858,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -30933,10 +30874,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCO zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -33686,7 +33626,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - add_function(&EX_T(opline->result.var).tmp_var, + fast_add_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -33701,7 +33641,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - sub_function(&EX_T(opline->result.var).tmp_var, + fast_sub_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -33716,7 +33656,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - mul_function(&EX_T(opline->result.var).tmp_var, + fast_mul_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -33731,7 +33671,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - div_function(&EX_T(opline->result.var).tmp_var, + fast_div_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -33746,7 +33686,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - mod_function(&EX_T(opline->result.var).tmp_var, + fast_mod_function(&EX_T(opline->result.var).tmp_var, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); @@ -33839,10 +33779,9 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_A zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) == 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -33856,10 +33795,9 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_not_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) != 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -33873,10 +33811,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) < 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -33890,10 +33827,9 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCOD zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - compare_function(result, + ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); - ZVAL_BOOL(result, (Z_LVAL_P(result) <= 0)); + _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); From 327a87fdd9e7946d31d9f3176e8f3dac5449e7a3 Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Mon, 23 May 2011 10:42:00 +0000 Subject: [PATCH 0047/2394] Fix Bug #54727, a re-incarnation of #26862 --- ext/standard/url_scanner_ex.c | 4 ++-- ext/standard/url_scanner_ex.re | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/standard/url_scanner_ex.c b/ext/standard/url_scanner_ex.c index 0618138f15e11..f9c017ff93b77 100644 --- a/ext/standard/url_scanner_ex.c +++ b/ext/standard/url_scanner_ex.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon May 31 11:07:50 2010 */ +/* Generated by re2c 0.13.5 on Mon May 23 12:29:55 2011 */ #line 1 "ext/standard/url_scanner_ex.re" /* +----------------------------------------------------------------------+ @@ -1012,7 +1012,7 @@ static void php_url_scanner_output_handler(char *output, uint output_len, char * ctx->result.len = 0; smart_str_free(&ctx->buf); } else { - *handled_output = NULL; + *handled_output = estrndup(output, *handled_output_len = output_len); } } else { *handled_output = NULL; diff --git a/ext/standard/url_scanner_ex.re b/ext/standard/url_scanner_ex.re index 5cc16c7ece071..7994925b1c080 100644 --- a/ext/standard/url_scanner_ex.re +++ b/ext/standard/url_scanner_ex.re @@ -450,7 +450,7 @@ static void php_url_scanner_output_handler(char *output, uint output_len, char * ctx->result.len = 0; smart_str_free(&ctx->buf); } else { - *handled_output = NULL; + *handled_output = estrndup(output, *handled_output_len = output_len); } } else { *handled_output = NULL; From 331a30997a361f40197249e25d0d2f3ed862cb24 Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Mon, 23 May 2011 23:51:28 +0000 Subject: [PATCH 0048/2394] Fixed test for decoupled - <%= 'so should this' %> + --EXPECTF-- - - <%= 'so should this' %> @@ -34,4 +31,6 @@ $a = 'This gets echoed twice'; +Notice: Undefined variable: b in %s on line %d + Notice: Undefined variable: b in %s on line %d From 89f893a95e8dcfff71f48d98ea87c5e1a6a88b32 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 24 May 2011 00:05:50 +0000 Subject: [PATCH 0049/2394] - Fixed stack buffer overflow in socket_connect(). Found by: Mateusz Kocielski, Marek Kroemeke and Filip Palian --- ext/sockets/sockets.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 0c6f292f38739..1651ca9db4982 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -1540,6 +1540,11 @@ PHP_FUNCTION(socket_connect) break; case AF_UNIX: + if (addr_len >= sizeof(s_un.sun_path)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Path too long", php_sock->type); + RETURN_FALSE; + } + memset(&s_un, 0, sizeof(struct sockaddr_un)); s_un.sun_family = AF_UNIX; From 52f40f07e6391577383a79e6e3f7943ab5858a24 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 24 May 2011 00:10:00 +0000 Subject: [PATCH 0050/2394] - Fix the fix # Arghh, copy and paste error :( --- ext/sockets/sockets.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 1651ca9db4982..2af92005b8270 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -1541,7 +1541,7 @@ PHP_FUNCTION(socket_connect) case AF_UNIX: if (addr_len >= sizeof(s_un.sun_path)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Path too long", php_sock->type); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Path too long"); RETURN_FALSE; } From 7da89df2671b02529f0e485e0e0105312c057904 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 24 May 2011 08:27:36 +0000 Subject: [PATCH 0051/2394] Fixed comilation on x86_64 --- ext/standard/math.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/math.c b/ext/standard/math.c index 135b87eb5694c..a4df5a5aa6d27 100644 --- a/ext/standard/math.c +++ b/ext/standard/math.c @@ -608,7 +608,7 @@ PHP_FUNCTION(pow) /* calculate pow(long,long) in O(log exp) operations, bail if overflow */ while (i >= 1) { - int overflow; + long overflow; double dval = 0.0; if (i % 2) { From 079f2a226c491d81f5fea522dec6170a0675cc01 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 24 May 2011 10:47:35 +0000 Subject: [PATCH 0052/2394] - fix tests, keep EOL as unix style as the str len is used in expect From c689dd9d59a98c1c5442002470524bc0955a7a6b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 24 May 2011 13:48:04 +0000 Subject: [PATCH 0053/2394] - Fix #54721, different Hashes on Windows, BSD and Linux on wrong Salt size --- ext/standard/php_crypt_r.c | 2 +- ext/standard/tests/strings/bug54721.phpt | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 ext/standard/tests/strings/bug54721.phpt diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index cd3746258cd4d..2d71710cfddae 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -197,7 +197,7 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) { goto _destroyCtx1; } - dwHashLen = pwl + sl + pwl; + dwHashLen = 16; CryptGetHashParam(ctx1, HP_HASHVAL, final, &dwHashLen, 0); /* MD5(pw,salt,pw). Valid. */ diff --git a/ext/standard/tests/strings/bug54721.phpt b/ext/standard/tests/strings/bug54721.phpt new file mode 100644 index 0000000000000..3851df1542307 --- /dev/null +++ b/ext/standard/tests/strings/bug54721.phpt @@ -0,0 +1,20 @@ +--TEST-- +Bug #54721 (Different Hashes on Windows, BSD and Linux on wrong Salt size) +--FILE-- + +--EXPECT-- +$1$dW0.is5.$I0iqTYHPzkP4YnRgnXxZW0 +$1$dW0.is5.$KaspRpPQ9U7Xb5Vv5c.WE/ +$1$dW0.is5.$X9G1x/Ep8zYQSrU4/lKUg. +$1$dW0.is5.$wE5Rz/HxPtDMfqil6kK980 +$1$dW0.is5.$2E4/ZDY1vr73HqLl1bLs9. +$1$dW0.is5.$lvGhphTQwqgKxWhWwYERr1 +$1$dW0.is5.$XzsWcLSBj2BvhOKH0xdpZ0 From b28294acc24256d123c65dd3a358145e52260e62 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 24 May 2011 22:24:06 +0000 Subject: [PATCH 0054/2394] - Fixed bug #54912 (filter/logical_filters.c:685:32: warning: use of logical || with constant op) Initial patch by: crrodriguez at opensuse dot org --- ext/filter/logical_filters.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index 59af952c12cac..8dc98fdd1ad54 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -682,7 +682,7 @@ void php_filter_validate_ip(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ RETURN_VALIDATION_FAILED } - if (flags & (FILTER_FLAG_IPV4 || FILTER_FLAG_IPV6)) { + if (flags & (FILTER_FLAG_IPV4 | FILTER_FLAG_IPV6)) { /* Both formats are cool */ } else if ((flags & FILTER_FLAG_IPV4) && mode == FORMAT_IPV6) { RETURN_VALIDATION_FAILED From f020659d9d7e334752780c144e2243d7b3d05d16 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 24 May 2011 22:34:07 +0000 Subject: [PATCH 0055/2394] - Fix logic, it must check for both flags (as says the comment in the code) (bug #54912) --- ext/filter/logical_filters.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index 8dc98fdd1ad54..d080d9ad2b92a 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -682,7 +682,7 @@ void php_filter_validate_ip(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ RETURN_VALIDATION_FAILED } - if (flags & (FILTER_FLAG_IPV4 | FILTER_FLAG_IPV6)) { + if ((flags & FILTER_FLAG_IPV4) && (flags & FILTER_FLAG_IPV6)) { /* Both formats are cool */ } else if ((flags & FILTER_FLAG_IPV4) && mode == FORMAT_IPV6) { RETURN_VALIDATION_FAILED From bc499c40781dc3342f869d7bb89f8958a5bcadbf Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Tue, 24 May 2011 23:27:49 +0000 Subject: [PATCH 0056/2394] Updated test. touch() emits E_WARNING for bogus values. Updated 5.3 test to look the same. --- ext/standard/tests/file/005_variation2.phpt | 22 ++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/ext/standard/tests/file/005_variation2.phpt b/ext/standard/tests/file/005_variation2.phpt index 51919dba60e49..d14a9bddd78ed 100644 --- a/ext/standard/tests/file/005_variation2.phpt +++ b/ext/standard/tests/file/005_variation2.phpt @@ -49,11 +49,17 @@ function stat_fn( $filename ) { echo "*** Testing fileattime(), filemtime(), filectime() & touch() : usage variations ***\n"; echo "\n*** testing touch ***\n"; -var_dump(touch(NULL)); -var_dump(touch(false)); -var_dump(touch('')); -var_dump(touch(' ')); -var_dump(touch('|')); +$a = touch(NULL); +$b = touch(false); +$c = touch(''); +$d = touch(' '); +$e = touch('|'); + +var_dump($a); +var_dump($b); +var_dump($c); +var_dump($d); +var_dump($e); echo "\n*** testing file info ***"; stat_fn(NULL); @@ -71,6 +77,12 @@ echo "Done"; *** Testing fileattime(), filemtime(), filectime() & touch() : usage variations *** *** testing touch *** + +Warning: touch(): Unable to create file because No such file or directory in %s on line %d + +Warning: touch(): Unable to create file because No such file or directory in %s on line %d + +Warning: touch(): Unable to create file because No such file or directory in %s on line %d bool(false) bool(false) bool(false) From b26fec954a8c8ded20128a10bb0d9c622ec83dbb Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Tue, 24 May 2011 23:49:04 +0000 Subject: [PATCH 0057/2394] Fixed test --- Zend/tests/constants_005.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/constants_005.phpt b/Zend/tests/constants_005.phpt index 6fe598a986a9d..d2a205b78440a 100755 --- a/Zend/tests/constants_005.phpt +++ b/Zend/tests/constants_005.phpt @@ -1,5 +1,5 @@ --TEST-- -Persistent case insensetive and user defined constants +Persistent case insensitive and user defined constants --FILE-- Date: Tue, 24 May 2011 23:49:26 +0000 Subject: [PATCH 0058/2394] - Fixed bug #50363 (Invalid parsing in convert.quoted-printable-decode filter) Patch by: slusarz at curecanti dot org --- ext/standard/filters.c | 10 +++------- ext/standard/tests/filters/bug50363.phpt | 17 +++++++++++++++++ 2 files changed, 20 insertions(+), 7 deletions(-) create mode 100644 ext/standard/tests/filters/bug50363.phpt diff --git a/ext/standard/filters.c b/ext/standard/filters.c index 2685405347bf7..2f1e3dc706812 100644 --- a/ext/standard/filters.c +++ b/ext/standard/filters.c @@ -1050,20 +1050,16 @@ static php_conv_err_t php_conv_qprint_decode_convert(php_conv_qprint_decode *ins } } /* break is missing intentionally */ - case 2: { - unsigned int nbl; - + case 2: { if (icnt <= 0) { goto out; } - nbl = (*ps >= 'A' ? *ps - 0x37 : *ps - 0x30); - if (nbl > 15) { + if (!isxdigit((int) *ps)) { err = PHP_CONV_ERR_INVALID_SEQ; goto out; } - next_char = (next_char << 4) | nbl; - + next_char = (next_char << 4) | (*ps >= 'A' ? *ps - 0x37 : *ps - 0x30); scan_stat++; ps++, icnt--; if (scan_stat != 3) { diff --git a/ext/standard/tests/filters/bug50363.phpt b/ext/standard/tests/filters/bug50363.phpt new file mode 100644 index 0000000000000..3395edebc46a9 --- /dev/null +++ b/ext/standard/tests/filters/bug50363.phpt @@ -0,0 +1,17 @@ +--TEST-- +Bug #50363 (Invalid parsing in convert.quoted-printable-decode filter) +--FILE-- + +--EXPECTF-- +Sauvegarderéussi(e) não NÃO +Sauvegarderéussi(e) não NÃO From 0183514cfb09a8912da748ee79da870f03825227 Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Wed, 25 May 2011 00:02:05 +0000 Subject: [PATCH 0059/2394] Fixed test, as per r311323 --- ext/standard/tests/general_functions/ini_get_all.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/standard/tests/general_functions/ini_get_all.phpt b/ext/standard/tests/general_functions/ini_get_all.phpt index 7b3572c0bbc1f..60cd38a72391a 100644 --- a/ext/standard/tests/general_functions/ini_get_all.phpt +++ b/ext/standard/tests/general_functions/ini_get_all.phpt @@ -34,9 +34,9 @@ array(2) { ["pcre.backtrack_limit"]=> array(3) { ["global_value"]=> - string(6) "1000000" + string(7) "1000000" ["local_value"]=> - string(6) "1000000" + string(7) "1000000" ["access"]=> int(7) } @@ -52,7 +52,7 @@ array(2) { } array(2) { ["pcre.backtrack_limit"]=> - string(6) "1000000" + string(7) "1000000" ["pcre.recursion_limit"]=> string(6) "100000" } From f9088156f4983c82b89729257066171229d95f03 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 25 May 2011 21:03:55 +0000 Subject: [PATCH 0060/2394] implement streams metadata API per RFC --- ext/standard/filestat.c | 200 +++++++++++--- ext/standard/tests/file/userstreams_007.phpt | 49 ++++ main/php_streams.h | 11 + main/streams/plain_wrapper.c | 94 ++++++- main/streams/userspace.c | 270 +++++++++++++------ 5 files changed, 498 insertions(+), 126 deletions(-) create mode 100644 ext/standard/tests/file/userstreams_007.phpt diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 85a6d16ecac98..6ae7cdad3bf34 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -386,21 +386,8 @@ PHP_FUNCTION(disk_free_space) /* }}} */ #if !defined(WINDOWS) && !defined(NETWARE) -static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ +PHPAPI int php_get_gid_by_name(const char *name, gid_t *gid TSRMLS_DC) { - char *filename; - int filename_len; - zval *group; - gid_t gid; - int ret; - - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/", &filename, &filename_len, &group) == FAILURE) { - RETURN_FALSE; - } - - if (Z_TYPE_P(group) == IS_LONG) { - gid = (gid_t)Z_LVAL_P(group); - } else if (Z_TYPE_P(group) == IS_STRING) { #if defined(ZTS) && defined(HAVE_GETGRNAM_R) && defined(_SC_GETGR_R_SIZE_MAX) struct group gr; struct group *retgrptr; @@ -408,26 +395,73 @@ static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ char *grbuf; if (grbuflen < 1) { - RETURN_FALSE; + return FAILURE; } grbuf = emalloc(grbuflen); - if (getgrnam_r(Z_STRVAL_P(group), &gr, grbuf, grbuflen, &retgrptr) != 0 || retgrptr == NULL) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find gid for %s", Z_STRVAL_P(group)); + if (getgrnam_r(name, &gr, grbuf, grbuflen, &retgrptr) != 0 || retgrptr == NULL) { efree(grbuf); - RETURN_FALSE; + return FAILURE; } efree(grbuf); - gid = gr.gr_gid; + *gid = gr.gr_gid; #else - struct group *gr = getgrnam(Z_STRVAL_P(group)); + struct group *gr = getgrnam(name); if (!gr) { + return FAILURE; + } + *gid = gr->gr_gid; +#endif + return SUCCESS; +} + +static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ +{ + char *filename; + int filename_len; + zval *group; + gid_t gid; + int ret; + php_stream_wrapper *wrapper; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/", &filename, &filename_len, &group) == FAILURE) { + RETURN_FALSE; + } + + wrapper = php_stream_locate_url_wrapper(filename, NULL, 0 TSRMLS_CC); + if(wrapper != &php_plain_files_wrapper || strncasecmp("file://", filename, 7) == 0) { + if(wrapper && wrapper->wops->stream_metadata) { + int option; + void *value; + if (Z_TYPE_P(group) == IS_LONG) { + option = PHP_STREAM_META_GROUP; + value = &Z_LVAL_P(group); + } else if (Z_TYPE_P(group) == IS_STRING) { + option = PHP_STREAM_META_GROUP_NAME; + value = Z_STRVAL_P(group); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "parameter 2 should be string or integer, %s given", zend_zval_type_name(group)); + RETURN_FALSE; + } + if(wrapper->wops->stream_metadata(wrapper, filename, option, value, NULL TSRMLS_CC)) { + RETURN_TRUE; + } else { + RETURN_FALSE; + } + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can not call chgrp() for a non-standard stream"); + RETURN_FALSE; + } + } + + if (Z_TYPE_P(group) == IS_LONG) { + gid = (gid_t)Z_LVAL_P(group); + } else if (Z_TYPE_P(group) == IS_STRING) { + if(php_get_gid_by_name(Z_STRVAL_P(group), &gid TSRMLS_CC) != SUCCESS) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find gid for %s", Z_STRVAL_P(group)); RETURN_FALSE; } - gid = gr->gr_gid; -#endif } else { php_error_docref(NULL TSRMLS_CC, E_WARNING, "parameter 2 should be string or integer, %s given", zend_zval_type_name(group)); RETURN_FALSE; @@ -483,21 +517,8 @@ PHP_FUNCTION(lchgrp) #endif /* !NETWARE */ #if !defined(WINDOWS) && !defined(NETWARE) -static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ +PHPAPI uid_t php_get_uid_by_name(const char *name, uid_t *uid TSRMLS_DC) { - char *filename; - int filename_len; - zval *user; - uid_t uid; - int ret; - - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/", &filename, &filename_len, &user) == FAILURE) { - return; - } - - if (Z_TYPE_P(user) == IS_LONG) { - uid = (uid_t)Z_LVAL_P(user); - } else if (Z_TYPE_P(user) == IS_STRING) { #if defined(ZTS) && defined(_SC_GETPW_R_SIZE_MAX) && defined(HAVE_GETPWNAM_R) struct passwd pw; struct passwd *retpwptr = NULL; @@ -509,22 +530,69 @@ static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ } pwbuf = emalloc(pwbuflen); - if (getpwnam_r(Z_STRVAL_P(user), &pw, pwbuf, pwbuflen, &retpwptr) != 0 || retpwptr == NULL) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find uid for %s", Z_STRVAL_P(user)); + if (getpwnam_r(name, &pw, pwbuf, pwbuflen, &retpwptr) != 0 || retpwptr == NULL) { efree(pwbuf); - RETURN_FALSE; + return FAILURE; } efree(pwbuf); - uid = pw.pw_uid; + *uid = pw.pw_uid; #else - struct passwd *pw = getpwnam(Z_STRVAL_P(user)); + struct passwd *pw = getpwnam(name); if (!pw) { + return FAILURE; + } + *uid = pw->pw_uid; +#endif + return SUCCESS; +} + +static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ +{ + char *filename; + int filename_len; + zval *user; + uid_t uid; + int ret; + php_stream_wrapper *wrapper; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/", &filename, &filename_len, &user) == FAILURE) { + return; + } + + wrapper = php_stream_locate_url_wrapper(filename, NULL, 0 TSRMLS_CC); + if(wrapper != &php_plain_files_wrapper || strncasecmp("file://", filename, 7) == 0) { + if(wrapper && wrapper->wops->stream_metadata) { + int option; + void *value; + if (Z_TYPE_P(user) == IS_LONG) { + option = PHP_STREAM_META_OWNER; + value = &Z_LVAL_P(user); + } else if (Z_TYPE_P(user) == IS_STRING) { + option = PHP_STREAM_META_OWNER_NAME; + value = Z_STRVAL_P(user); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "parameter 2 should be string or integer, %s given", zend_zval_type_name(user)); + RETURN_FALSE; + } + if(wrapper->wops->stream_metadata(wrapper, filename, option, value, NULL TSRMLS_CC)) { + RETURN_TRUE; + } else { + RETURN_FALSE; + } + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can not call chown() for a non-standard stream"); + RETURN_FALSE; + } + } + + if (Z_TYPE_P(user) == IS_LONG) { + uid = (uid_t)Z_LVAL_P(user); + } else if (Z_TYPE_P(user) == IS_STRING) { + if(php_get_uid_by_name(Z_STRVAL_P(user), &uid TSRMLS_CC) != SUCCESS) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find uid for %s", Z_STRVAL_P(user)); RETURN_FALSE; } - uid = pw->pw_uid; -#endif } else { php_error_docref(NULL TSRMLS_CC, E_WARNING, "parameter 2 should be string or integer, %s given", zend_zval_type_name(user)); RETURN_FALSE; @@ -589,11 +657,28 @@ PHP_FUNCTION(chmod) long mode; int ret; mode_t imode; + php_stream_wrapper *wrapper; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl", &filename, &filename_len, &mode) == FAILURE) { return; } + wrapper = php_stream_locate_url_wrapper(filename, NULL, 0 TSRMLS_CC); + if(wrapper != &php_plain_files_wrapper || strncasecmp("file://", filename, 7) == 0) { + if(wrapper && wrapper->wops->stream_metadata) { + int option; + void *value; + if(wrapper->wops->stream_metadata(wrapper, filename, PHP_STREAM_META_ACCESS, &mode, NULL TSRMLS_CC)) { + RETURN_TRUE; + } else { + RETURN_FALSE; + } + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can not call chmod() for a non-standard stream"); + RETURN_FALSE; + } + } + /* Check the basedir */ if (php_check_open_basedir(filename TSRMLS_CC)) { RETURN_FALSE; @@ -622,11 +707,16 @@ PHP_FUNCTION(touch) FILE *file; struct utimbuf newtimebuf; struct utimbuf *newtime = &newtimebuf; + php_stream_wrapper *wrapper; if (zend_parse_parameters(argc TSRMLS_CC, "s|ll", &filename, &filename_len, &filetime, &fileatime) == FAILURE) { return; } + if (!filename_len) { + RETURN_FALSE; + } + switch (argc) { case 1: #ifdef HAVE_UTIME_NULL @@ -647,6 +737,30 @@ PHP_FUNCTION(touch) WRONG_PARAM_COUNT; } + wrapper = php_stream_locate_url_wrapper(filename, NULL, 0 TSRMLS_CC); + if(wrapper != &php_plain_files_wrapper || strncasecmp("file://", filename, 7) == 0) { + if(wrapper && wrapper->wops->stream_metadata) { + if(wrapper->wops->stream_metadata(wrapper, filename, PHP_STREAM_META_TOUCH, newtime, NULL TSRMLS_CC)) { + RETURN_TRUE; + } else { + RETURN_FALSE; + } + } else { + php_stream *stream; + if(argc > 1) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can not call touch() for a non-standard stream"); + RETURN_FALSE; + } + stream = php_stream_open_wrapper_ex(filename, "c", REPORT_ERRORS, NULL, NULL); + if(stream != NULL) { + php_stream_pclose(stream); + RETURN_TRUE; + } else { + RETURN_FALSE; + } + } + } + /* Check the basedir */ if (php_check_open_basedir(filename TSRMLS_CC)) { RETURN_FALSE; diff --git a/ext/standard/tests/file/userstreams_007.phpt b/ext/standard/tests/file/userstreams_007.phpt new file mode 100644 index 0000000000000..3f66f1802be47 --- /dev/null +++ b/ext/standard/tests/file/userstreams_007.phpt @@ -0,0 +1,49 @@ +--TEST-- +User-space streams: test metadata option +--FILE-- + +#if HAVE_UTIME +# ifdef PHP_WIN32 +# include +# else +# include +# endif +#endif + static int le_protocols; struct php_user_stream_wrapper { @@ -43,6 +51,7 @@ static int user_wrapper_unlink(php_stream_wrapper *wrapper, char *url, int optio static int user_wrapper_rename(php_stream_wrapper *wrapper, char *url_from, char *url_to, int options, php_stream_context *context TSRMLS_DC); static int user_wrapper_mkdir(php_stream_wrapper *wrapper, char *url, int mode, int options, php_stream_context *context TSRMLS_DC); static int user_wrapper_rmdir(php_stream_wrapper *wrapper, char *url, int options, php_stream_context *context TSRMLS_DC); +static int user_wrapper_metadata(php_stream_wrapper *wrapper, char *url, int option, void *value, php_stream_context *context TSRMLS_DC); static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filename, char *mode, int options, char **opened_path, php_stream_context *context STREAMS_DC TSRMLS_DC); @@ -56,7 +65,8 @@ static php_stream_wrapper_ops user_stream_wops = { user_wrapper_unlink, user_wrapper_rename, user_wrapper_mkdir, - user_wrapper_rmdir + user_wrapper_rmdir, + user_wrapper_metadata }; @@ -99,6 +109,12 @@ PHP_MINIT_FUNCTION(user_streams) REGISTER_LONG_CONSTANT("STREAM_CAST_AS_STREAM", PHP_STREAM_AS_STDIO, CONST_CS|CONST_PERSISTENT); REGISTER_LONG_CONSTANT("STREAM_CAST_FOR_SELECT", PHP_STREAM_AS_FD_FOR_SELECT, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("STREAM_META_TOUCH", PHP_STREAM_META_TOUCH, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("STREAM_META_OWNER", PHP_STREAM_META_OWNER, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("STREAM_META_OWNER_NAME", PHP_STREAM_META_OWNER_NAME, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("STREAM_META_GROUP", PHP_STREAM_META_GROUP, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("STREAM_META_GROUP_NAME", PHP_STREAM_META_GROUP_NAME, CONST_CS|CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("STREAM_META_ACCESS", PHP_STREAM_META_ACCESS, CONST_CS|CONST_PERSISTENT); return SUCCESS; } @@ -131,35 +147,36 @@ typedef struct _php_userstream_data php_userstream_data_t; #define USERSTREAM_CAST "stream_cast" #define USERSTREAM_SET_OPTION "stream_set_option" #define USERSTREAM_TRUNCATE "stream_truncate" +#define USERSTREAM_METADATA "stream_metadata" /* {{{ class should have methods like these: - + function stream_open($path, $mode, $options, &$opened_path) { return true/false; } - + function stream_read($count) { return false on error; else return string; } - + function stream_write($data) { return false on error; else return count written; } - + function stream_close() { } - + function stream_flush() { return true/false; } - + function stream_seek($offset, $whence) { return true/false; @@ -261,7 +278,7 @@ typedef struct _php_userstream_data php_userstream_data_t; { return true / false; } - + }}} **/ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filename, char *mode, int options, char **opened_path, php_stream_context *context STREAMS_DC TSRMLS_DC) @@ -269,7 +286,7 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena struct php_user_stream_wrapper *uwrap = (struct php_user_stream_wrapper*)wrapper->abstract; php_userstream_data_t *us; zval *zfilename, *zmode, *zopened, *zoptions, *zretval = NULL, *zfuncname; - zval **args[4]; + zval **args[4]; int call_result; php_stream *stream = NULL; zend_bool old_in_user_include; @@ -280,32 +297,32 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena return NULL; } FG(user_stream_current_filename) = filename; - + /* if the user stream was registered as local and we are in include context, we add allow_url_include restrictions to allow_url_fopen ones */ /* we need only is_url == 0 here since if is_url == 1 and remote wrappers were restricted we wouldn't get here */ old_in_user_include = PG(in_user_include); - if(uwrap->wrapper.is_url == 0 && + if(uwrap->wrapper.is_url == 0 && (options & STREAM_OPEN_FOR_INCLUDE) && !PG(allow_url_include)) { PG(in_user_include) = 1; } us = emalloc(sizeof(*us)); - us->wrapper = uwrap; + us->wrapper = uwrap; /* create an instance of our class */ ALLOC_ZVAL(us->object); object_init_ex(us->object, uwrap->ce); Z_SET_REFCOUNT_P(us->object, 1); Z_SET_ISREF_P(us->object); - + if (uwrap->ce->constructor) { zend_fcall_info fci; zend_fcall_info_cache fcc; zval *retval_ptr; - + fci.size = sizeof(fci); fci.function_table = &uwrap->ce->function_table; fci.function_name = NULL; @@ -315,7 +332,7 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena fci.param_count = 0; fci.params = NULL; fci.no_separation = 1; - + fcc.initialized = 1; fcc.function_handler = uwrap->ce->constructor; fcc.calling_scope = EG(scope); @@ -343,7 +360,7 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena } else { add_property_null(us->object, "context"); } - + /* call it's stream_open method - set up params first */ MAKE_STD_ZVAL(zfilename); ZVAL_STRING(zfilename, filename, 1); @@ -365,14 +382,14 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_OPEN, 1); - + call_result = call_user_function_ex(NULL, &us->object, zfuncname, &zretval, 4, args, 0, NULL TSRMLS_CC); - + if (call_result == SUCCESS && zretval != NULL && zval_is_true(zretval)) { /* the stream is now open! */ stream = php_stream_alloc_rel(&php_stream_userspace_ops, us, 0, mode); @@ -389,7 +406,7 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "\"%s::" USERSTREAM_OPEN "\" call failed", us->wrapper->classname); } - + /* destroy everything else */ if (stream == NULL) { zval_ptr_dtor(&us->object); @@ -397,7 +414,7 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena } if (zretval) zval_ptr_dtor(&zretval); - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zopened); zval_ptr_dtor(&zoptions); @@ -405,7 +422,7 @@ static php_stream *user_wrapper_opener(php_stream_wrapper *wrapper, char *filena zval_ptr_dtor(&zfilename); FG(user_stream_current_filename) = NULL; - + PG(in_user_include) = old_in_user_include; return stream; } @@ -416,7 +433,7 @@ static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filen struct php_user_stream_wrapper *uwrap = (struct php_user_stream_wrapper*)wrapper->abstract; php_userstream_data_t *us; zval *zfilename, *zoptions, *zretval = NULL, *zfuncname; - zval **args[2]; + zval **args[2]; int call_result; php_stream *stream = NULL; @@ -426,9 +443,9 @@ static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filen return NULL; } FG(user_stream_current_filename) = filename; - + us = emalloc(sizeof(*us)); - us->wrapper = uwrap; + us->wrapper = uwrap; /* create an instance of our class */ ALLOC_ZVAL(us->object); @@ -442,7 +459,7 @@ static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filen } else { add_property_null(us->object, "context"); } - + /* call it's dir_open method - set up params first */ MAKE_STD_ZVAL(zfilename); ZVAL_STRING(zfilename, filename, 1); @@ -454,14 +471,14 @@ static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filen MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_DIR_OPEN, 1); - + call_result = call_user_function_ex(NULL, &us->object, zfuncname, &zretval, 2, args, 0, NULL TSRMLS_CC); - + if (call_result == SUCCESS && zretval != NULL && zval_is_true(zretval)) { /* the stream is now open! */ stream = php_stream_alloc_rel(&php_stream_userspace_dir_ops, us, 0, mode); @@ -473,7 +490,7 @@ static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filen php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "\"%s::" USERSTREAM_DIR_OPEN "\" call failed", us->wrapper->classname); } - + /* destroy everything else */ if (stream == NULL) { zval_ptr_dtor(&us->object); @@ -481,13 +498,13 @@ static php_stream *user_wrapper_opendir(php_stream_wrapper *wrapper, char *filen } if (zretval) zval_ptr_dtor(&zretval); - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zoptions); zval_ptr_dtor(&zfilename); FG(user_stream_current_filename) = NULL; - + return stream; } @@ -501,11 +518,11 @@ PHP_FUNCTION(stream_wrapper_register) struct php_user_stream_wrapper * uwrap; int rsrc_id; long flags = 0; - + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|l", &protocol, &protocol_len, &classname, &classname_len, &flags) == FAILURE) { RETURN_FALSE; } - + uwrap = (struct php_user_stream_wrapper *)ecalloc(1, sizeof(*uwrap)); uwrap->protoname = estrndup(protocol, protocol_len); uwrap->classname = estrndup(classname, classname_len); @@ -591,7 +608,7 @@ PHP_FUNCTION(stream_wrapper_restore) if (php_register_url_stream_wrapper_volatile(protocol, wrapper TSRMLS_CC) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to restore original %s:// wrapper", protocol); RETURN_FALSE; - } + } RETURN_TRUE; } @@ -639,10 +656,10 @@ static size_t php_userstreamop_write(php_stream *stream, const char *buf, size_t (long)(didwrite - count), (long)didwrite, (long)count); didwrite = count; } - + if (retval) zval_ptr_dtor(&retval); - + return didwrite; } @@ -727,9 +744,9 @@ static int php_userstreamop_close(php_stream *stream, int close_handle TSRMLS_DC php_userstream_data_t *us = (php_userstream_data_t *)stream->abstract; assert(us != NULL); - + ZVAL_STRINGL(&func_name, USERSTREAM_CLOSE, sizeof(USERSTREAM_CLOSE)-1, 0); - + call_user_function_ex(NULL, &us->object, &func_name, @@ -738,11 +755,11 @@ static int php_userstreamop_close(php_stream *stream, int close_handle TSRMLS_DC if (retval) zval_ptr_dtor(&retval); - + zval_ptr_dtor(&us->object); efree(us); - + return 0; } @@ -756,7 +773,7 @@ static int php_userstreamop_flush(php_stream *stream TSRMLS_DC) assert(us != NULL); ZVAL_STRINGL(&func_name, USERSTREAM_FLUSH, sizeof(USERSTREAM_FLUSH)-1, 0); - + call_result = call_user_function_ex(NULL, &us->object, &func_name, @@ -767,10 +784,10 @@ static int php_userstreamop_flush(php_stream *stream TSRMLS_DC) call_result = 0; else call_result = -1; - + if (retval) zval_ptr_dtor(&retval); - + return call_result; } @@ -809,10 +826,10 @@ static int php_userstreamop_seek(php_stream *stream, off_t offset, int whence, o /* stream_seek is not implemented, so disable seeks for this stream */ stream->flags |= PHP_STREAM_FLAG_NO_SEEK; /* there should be no retval to clean up */ - - if (retval) + + if (retval) zval_ptr_dtor(&retval); - + return -1; } else if (call_result == SUCCESS && retval != NULL && zval_is_true(retval)) { ret = 0; @@ -895,8 +912,8 @@ static int statbuf_from_array(zval *array, php_stream_statbuf *ssb TSRMLS_DC) STAT_PROP_ENTRY(blocks); #endif -#undef STAT_PROP_ENTRY -#undef STAT_PROP_ENTRY_EX +#undef STAT_PROP_ENTRY +#undef STAT_PROP_ENTRY_EX return SUCCESS; } @@ -926,9 +943,9 @@ static int php_userstreamop_stat(php_stream *stream, php_stream_statbuf *ssb TSR } } - if (retval) + if (retval) zval_ptr_dtor(&retval); - + return ret; } @@ -976,34 +993,34 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value } args[0] = &zvalue; - + /* TODO wouldblock */ ZVAL_STRINGL(&func_name, USERSTREAM_LOCK, sizeof(USERSTREAM_LOCK)-1, 0); - + call_result = call_user_function_ex(NULL, &us->object, &func_name, &retval, 1, args, 0, NULL TSRMLS_CC); - + if (call_result == SUCCESS && retval != NULL && Z_TYPE_P(retval) == IS_BOOL) { ret = !Z_LVAL_P(retval); } else if (call_result == FAILURE) { - if (value == 0) { + if (value == 0) { /* lock support test (TODO: more check) */ ret = PHP_STREAM_OPTION_RETURN_OK; } else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s::" USERSTREAM_LOCK " is not implemented!", + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s::" USERSTREAM_LOCK " is not implemented!", us->wrapper->classname); ret = PHP_STREAM_OPTION_RETURN_ERR; } } break; - + case PHP_STREAM_OPTION_TRUNCATE_API: ZVAL_STRINGL(&func_name, USERSTREAM_TRUNCATE, sizeof(USERSTREAM_TRUNCATE)-1, 0); - + switch (value) { case PHP_STREAM_TRUNCATE_SUPPORTED: if (zend_is_callable_ex(&func_name, us->object, IS_CALLABLE_CHECK_SILENT, @@ -1012,7 +1029,7 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value else ret = PHP_STREAM_OPTION_RETURN_ERR; break; - + case PHP_STREAM_TRUNCATE_SET_SIZE: { ptrdiff_t new_size = *(ptrdiff_t*) ptrparam; if (new_size >= 0 && new_size <= (ptrdiff_t)LONG_MAX) { @@ -1045,14 +1062,14 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value } } break; - + case PHP_STREAM_OPTION_READ_BUFFER: case PHP_STREAM_OPTION_WRITE_BUFFER: case PHP_STREAM_OPTION_READ_TIMEOUT: case PHP_STREAM_OPTION_BLOCKING: { zval *zoption = NULL; zval *zptrparam = NULL; - + ZVAL_STRINGL(&func_name, USERSTREAM_SET_OPTION, sizeof(USERSTREAM_SET_OPTION)-1, 0); ALLOC_INIT_ZVAL(zoption); @@ -1093,7 +1110,7 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value &func_name, &retval, 3, args, 0, NULL TSRMLS_CC); - + if (call_result == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s::" USERSTREAM_SET_OPTION " is not implemented!", us->wrapper->classname); @@ -1119,7 +1136,7 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value if (retval) { zval_ptr_dtor(&retval); } - + if (zvalue) { zval_ptr_dtor(&zvalue); @@ -1158,7 +1175,7 @@ static int user_wrapper_unlink(php_stream_wrapper *wrapper, char *url, int optio MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_UNLINK, 1); - + call_result = call_user_function_ex(NULL, &object, zfuncname, @@ -1176,7 +1193,7 @@ static int user_wrapper_unlink(php_stream_wrapper *wrapper, char *url, int optio zval_ptr_dtor(&object); if (zretval) zval_ptr_dtor(&zretval); - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zfilename); @@ -1216,7 +1233,7 @@ static int user_wrapper_rename(php_stream_wrapper *wrapper, char *url_from, char MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_RENAME, 1); - + call_result = call_user_function_ex(NULL, &object, zfuncname, @@ -1234,7 +1251,7 @@ static int user_wrapper_rename(php_stream_wrapper *wrapper, char *url_from, char zval_ptr_dtor(&object); if (zretval) zval_ptr_dtor(&zretval); - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zold_name); zval_ptr_dtor(&znew_name); @@ -1279,7 +1296,7 @@ static int user_wrapper_mkdir(php_stream_wrapper *wrapper, char *url, int mode, MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_MKDIR, 1); - + call_result = call_user_function_ex(NULL, &object, zfuncname, @@ -1298,7 +1315,7 @@ static int user_wrapper_mkdir(php_stream_wrapper *wrapper, char *url, int mode, if (zretval) { zval_ptr_dtor(&zretval); } - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zfilename); zval_ptr_dtor(&zmode); @@ -1340,7 +1357,7 @@ static int user_wrapper_rmdir(php_stream_wrapper *wrapper, char *url, int option MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_RMDIR, 1); - + call_result = call_user_function_ex(NULL, &object, zfuncname, @@ -1359,7 +1376,7 @@ static int user_wrapper_rmdir(php_stream_wrapper *wrapper, char *url, int option if (zretval) { zval_ptr_dtor(&zretval); } - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zfilename); zval_ptr_dtor(&zoptions); @@ -1367,11 +1384,100 @@ static int user_wrapper_rmdir(php_stream_wrapper *wrapper, char *url, int option return ret; } +static int user_wrapper_metadata(php_stream_wrapper *wrapper, char *url, int option, void *value, php_stream_context *context TSRMLS_DC) +{ + struct php_user_stream_wrapper *uwrap = (struct php_user_stream_wrapper*)wrapper->abstract; + zval *zfilename, *zoption, *zvalue, *zfuncname, *zretval; + zval **args[3]; + int call_result; + zval *object; + int ret = 0; + + MAKE_STD_ZVAL(zvalue); + switch(option) { + case PHP_STREAM_META_TOUCH: + array_init(zvalue); + if(value) { + struct utimbuf *newtime = (struct utimbuf *)value; + add_index_long(zvalue, 0, newtime->modtime); + add_index_long(zvalue, 1, newtime->actime); + } + break; + case PHP_STREAM_META_GROUP: + case PHP_STREAM_META_OWNER: + case PHP_STREAM_META_ACCESS: + ZVAL_LONG(zvalue, *(long *)value); + break; + case PHP_STREAM_META_GROUP_NAME: + case PHP_STREAM_META_OWNER_NAME: + ZVAL_STRING(zvalue, value, 1); + break; + default: + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown option %d for " USERSTREAM_METADATA, option); + zval_ptr_dtor(&zvalue); + return ret; + } + + /* create an instance of our class */ + ALLOC_ZVAL(object); + object_init_ex(object, uwrap->ce); + Z_SET_REFCOUNT_P(object, 1); + Z_SET_ISREF_P(object); + + if (context) { + add_property_resource(object, "context", context->rsrc_id); + zend_list_addref(context->rsrc_id); + } else { + add_property_null(object, "context"); + } + + /* call the mkdir method */ + MAKE_STD_ZVAL(zfilename); + ZVAL_STRING(zfilename, url, 1); + args[0] = &zfilename; + + MAKE_STD_ZVAL(zoption); + ZVAL_LONG(zoption, option); + args[1] = &zoption; + + args[2] = &zvalue; + + MAKE_STD_ZVAL(zfuncname); + ZVAL_STRING(zfuncname, USERSTREAM_METADATA, 1); + + call_result = call_user_function_ex(NULL, + &object, + zfuncname, + &zretval, + 3, args, + 0, NULL TSRMLS_CC); + + if (call_result == SUCCESS && zretval && Z_TYPE_P(zretval) == IS_BOOL) { + ret = Z_LVAL_P(zretval); + } else if (call_result == FAILURE) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s::" USERSTREAM_METADATA " is not implemented!", uwrap->classname); + } + + /* clean up */ + zval_ptr_dtor(&object); + if (zretval) { + zval_ptr_dtor(&zretval); + } + + zval_ptr_dtor(&zfuncname); + zval_ptr_dtor(&zfilename); + zval_ptr_dtor(&zoption); + zval_ptr_dtor(&zvalue); + + return ret; +} + + static int user_wrapper_stat_url(php_stream_wrapper *wrapper, char *url, int flags, php_stream_statbuf *ssb, php_stream_context *context TSRMLS_DC) { struct php_user_stream_wrapper *uwrap = (struct php_user_stream_wrapper*)wrapper->abstract; zval *zfilename, *zfuncname, *zretval, *zflags; - zval **args[2]; + zval **args[2]; int call_result; zval *object; int ret = -1; @@ -1400,14 +1506,14 @@ static int user_wrapper_stat_url(php_stream_wrapper *wrapper, char *url, int fla MAKE_STD_ZVAL(zfuncname); ZVAL_STRING(zfuncname, USERSTREAM_STATURL, 1); - + call_result = call_user_function_ex(NULL, &object, zfuncname, &zretval, 2, args, 0, NULL TSRMLS_CC); - + if (call_result == SUCCESS && zretval != NULL && Z_TYPE_P(zretval) == IS_ARRAY) { /* We got the info we needed */ if (SUCCESS == statbuf_from_array(zretval, ssb TSRMLS_CC)) @@ -1418,16 +1524,16 @@ static int user_wrapper_stat_url(php_stream_wrapper *wrapper, char *url, int fla uwrap->classname); } } - + /* clean up */ zval_ptr_dtor(&object); if (zretval) zval_ptr_dtor(&zretval); - + zval_ptr_dtor(&zfuncname); zval_ptr_dtor(&zfilename); zval_ptr_dtor(&zflags); - + return ret; } @@ -1477,9 +1583,9 @@ static int php_userstreamop_closedir(php_stream *stream, int close_handle TSRMLS php_userstream_data_t *us = (php_userstream_data_t *)stream->abstract; assert(us != NULL); - + ZVAL_STRINGL(&func_name, USERSTREAM_DIR_CLOSE, sizeof(USERSTREAM_DIR_CLOSE)-1, 0); - + call_user_function_ex(NULL, &us->object, &func_name, @@ -1488,11 +1594,11 @@ static int php_userstreamop_closedir(php_stream *stream, int close_handle TSRMLS if (retval) zval_ptr_dtor(&retval); - + zval_ptr_dtor(&us->object); efree(us); - + return 0; } @@ -1503,7 +1609,7 @@ static int php_userstreamop_rewinddir(php_stream *stream, off_t offset, int when php_userstream_data_t *us = (php_userstream_data_t *)stream->abstract; ZVAL_STRINGL(&func_name, USERSTREAM_DIR_REWIND, sizeof(USERSTREAM_DIR_REWIND)-1, 0); - + call_user_function_ex(NULL, &us->object, &func_name, @@ -1512,7 +1618,7 @@ static int php_userstreamop_rewinddir(php_stream *stream, off_t offset, int when if (retval) zval_ptr_dtor(&retval); - + return 0; } @@ -1587,7 +1693,7 @@ php_stream_ops php_stream_userspace_ops = { "user-space", php_userstreamop_seek, php_userstreamop_cast, - php_userstreamop_stat, + php_userstreamop_stat, php_userstreamop_set_option, }; From 565d0063ebcd12531a2b6da4fcee19efe984fa14 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Wed, 25 May 2011 22:23:48 +0000 Subject: [PATCH 0061/2394] - Fixed ZTS build and removed unused vars --- ext/standard/filestat.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 6ae7cdad3bf34..34b6468146388 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -526,7 +526,7 @@ PHPAPI uid_t php_get_uid_by_name(const char *name, uid_t *uid TSRMLS_DC) char *pwbuf; if (pwbuflen < 1) { - RETURN_FALSE; + return FAILURE; } pwbuf = emalloc(pwbuflen); @@ -666,8 +666,6 @@ PHP_FUNCTION(chmod) wrapper = php_stream_locate_url_wrapper(filename, NULL, 0 TSRMLS_CC); if(wrapper != &php_plain_files_wrapper || strncasecmp("file://", filename, 7) == 0) { if(wrapper && wrapper->wops->stream_metadata) { - int option; - void *value; if(wrapper->wops->stream_metadata(wrapper, filename, PHP_STREAM_META_ACCESS, &mode, NULL TSRMLS_CC)) { RETURN_TRUE; } else { From 2c9136a25e3e0e279193a95d4bcca23a289232e1 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 26 May 2011 14:37:13 +0000 Subject: [PATCH 0062/2394] -fix bug 54935, php_win_err can lead to crash --- ext/standard/dl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/dl.c b/ext/standard/dl.c index 9099edfafd79f..b59cf58567483 100644 --- a/ext/standard/dl.c +++ b/ext/standard/dl.c @@ -145,7 +145,7 @@ PHPAPI int php_load_extension(char *filename, int type, int start_now TSRMLS_DC) if (!handle) { #if PHP_WIN32 char *err = GET_DL_ERROR(); - if (err) { + if (err && (*err != "")) { php_error_docref(NULL TSRMLS_CC, error_type, "Unable to load dynamic library '%s' - %s", libpath, err); LocalFree(err); } else { From c5e56ff90c1051bf6a8765fcf7b627b28b2459f5 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Thu, 26 May 2011 18:17:43 +0000 Subject: [PATCH 0063/2394] Fixed bug #54924 (assert.* is not being reset upon request shutdown). --- ext/standard/assert.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/ext/standard/assert.c b/ext/standard/assert.c index a42f678ec5781..9fd11049280d1 100644 --- a/ext/standard/assert.c +++ b/ext/standard/assert.c @@ -253,8 +253,8 @@ PHP_FUNCTION(assert_options) case ASSERT_ACTIVE: oldint = ASSERTG(active); if (ac == 2) { - convert_to_long_ex(value); - ASSERTG(active) = Z_LVAL_PP(value); + convert_to_string_ex(value); + zend_alter_ini_entry_ex("assert.active", sizeof("assert.active"), Z_STRVAL_PP(value), Z_STRLEN_PP(value), PHP_INI_USER, PHP_INI_STAGE_RUNTIME, 0 TSRMLS_CC); } RETURN_LONG(oldint); break; @@ -262,8 +262,8 @@ PHP_FUNCTION(assert_options) case ASSERT_BAIL: oldint = ASSERTG(bail); if (ac == 2) { - convert_to_long_ex(value); - ASSERTG(bail) = Z_LVAL_PP(value); + convert_to_string_ex(value); + zend_alter_ini_entry_ex("assert.bail", sizeof("assert.bail"), Z_STRVAL_PP(value), Z_STRLEN_PP(value), PHP_INI_USER, PHP_INI_STAGE_RUNTIME, 0 TSRMLS_CC); } RETURN_LONG(oldint); break; @@ -271,8 +271,8 @@ PHP_FUNCTION(assert_options) case ASSERT_QUIET_EVAL: oldint = ASSERTG(quiet_eval); if (ac == 2) { - convert_to_long_ex(value); - ASSERTG(quiet_eval) = Z_LVAL_PP(value); + convert_to_string_ex(value); + zend_alter_ini_entry_ex("assert.quiet_eval", sizeof("assert.quiet_eval"), Z_STRVAL_PP(value), Z_STRLEN_PP(value), PHP_INI_USER, PHP_INI_STAGE_RUNTIME, 0 TSRMLS_CC); } RETURN_LONG(oldint); break; @@ -280,8 +280,8 @@ PHP_FUNCTION(assert_options) case ASSERT_WARNING: oldint = ASSERTG(warning); if (ac == 2) { - convert_to_long_ex(value); - ASSERTG(warning) = Z_LVAL_PP(value); + convert_to_string_ex(value); + zend_alter_ini_entry_ex("assert.warning", sizeof("assert.warning"), Z_STRVAL_PP(value), Z_STRLEN_PP(value), PHP_INI_USER, PHP_INI_STAGE_RUNTIME, 0 TSRMLS_CC); } RETURN_LONG(oldint); break; From 3dcb2569199097c76c5d80118fe3c6acf1fa47a5 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 27 May 2011 23:31:30 +0000 Subject: [PATCH 0064/2394] - Fixed bug #54934 (Unresolved symbol strtoull in HP-UX 11.11) --- ext/fileinfo/libmagic/apprentice.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ext/fileinfo/libmagic/apprentice.c b/ext/fileinfo/libmagic/apprentice.c index 53fa8d5a1448e..eb1562e461422 100644 --- a/ext/fileinfo/libmagic/apprentice.c +++ b/ext/fileinfo/libmagic/apprentice.c @@ -41,6 +41,14 @@ FILE_RCSID("@(#)$File: apprentice.c,v 1.151 2009/03/18 15:19:23 christos Exp $") #include "patchlevel.h" #include +#if defined(__hpux) && !defined(HAVE_STRTOULL) +#if SIZEOF_LONG == 8 +# define strtoull strtoul +#else +# define strtoull __strtoull +#endif +#endif + #ifdef PHP_WIN32 #include "win32/unistd.h" #if _MSC_VER <= 1300 From 3ec51648ad440f915b2918e82f1859da168e0439 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Sun, 29 May 2011 09:23:08 +0000 Subject: [PATCH 0065/2394] Fixed bug #54137 (file_get_contents POST request sends additional line break). --- ext/standard/http_fopen_wrapper.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index 43a4ad2d34c13..7a918d9c8368d 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -628,7 +628,6 @@ php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper, char *path, } php_stream_write(stream, "\r\n", sizeof("\r\n")-1); php_stream_write(stream, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval)); - php_stream_write(stream, "\r\n\r\n", sizeof("\r\n\r\n")-1); } else { php_stream_write(stream, "\r\n", sizeof("\r\n")-1); } From 57674f784fa3f0de227a6a8ee717519574b54e17 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Sun, 29 May 2011 10:23:06 +0000 Subject: [PATCH 0066/2394] Fixed bug #53848 (fgetcsv() ignores spaces at beginnings of fields). --- ext/standard/file.c | 30 ++++++++------------------- ext/standard/tests/file/bug53848.phpt | 25 ++++++++++++++++++++++ 2 files changed, 34 insertions(+), 21 deletions(-) create mode 100644 ext/standard/tests/file/bug53848.phpt diff --git a/ext/standard/file.c b/ext/standard/file.c index 527f12df61e82..3e45461f7c270 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -2098,29 +2098,17 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char tptr = temp; - /* 1. Strip any leading space */ - for (;;) { - inc_len = (bptr < limit ? (*bptr == '\0' ? 1: php_mblen(bptr, limit - bptr)): 0); - switch (inc_len) { - case -2: - case -1: - inc_len = 1; - php_ignore_value(php_mblen(NULL, 0)); - break; - case 0: - goto quit_loop_1; - case 1: - if (!isspace((int)*(unsigned char *)bptr) || *bptr == delimiter) { - goto quit_loop_1; - } - break; - default: - goto quit_loop_1; + inc_len = (bptr < limit ? (*bptr == '\0' ? 1: php_mblen(bptr, limit - bptr)): 0); + if (inc_len == 1) { + char *tmp = bptr; + while (isspace((int)*(unsigned char *)tmp)) { + tmp++; + } + if (*tmp == enclosure) { + bptr = tmp; } - bptr += inc_len; - } + } - quit_loop_1: if (first_field && bptr == line_end) { add_next_index_null(return_value); break; diff --git a/ext/standard/tests/file/bug53848.phpt b/ext/standard/tests/file/bug53848.phpt new file mode 100644 index 0000000000000..016d59d0cae67 --- /dev/null +++ b/ext/standard/tests/file/bug53848.phpt @@ -0,0 +1,25 @@ +--TEST-- +Bug #53848 (fgetcsv removes leading spaces from fields) +--FILE-- + +--EXPECT-- +array(2) { + [0]=> + string(1) "a" + [1]=> + string(1) "b" +} +array(2) { + [0]=> + string(3) " c" + [1]=> + string(3) " d" +} From ca9033995713108d607c92f7db7ede3330fa996b Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 29 May 2011 11:39:49 +0000 Subject: [PATCH 0067/2394] Fixed bug #54601 (Removing the doctype node segfaults) --- ext/dom/tests/bug54601.phpt | 30 ++++++++++++++++++++++++++++++ ext/libxml/libxml.c | 2 +- 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 ext/dom/tests/bug54601.phpt diff --git a/ext/dom/tests/bug54601.phpt b/ext/dom/tests/bug54601.phpt new file mode 100644 index 0000000000000..8a2da2dee20f0 --- /dev/null +++ b/ext/dom/tests/bug54601.phpt @@ -0,0 +1,30 @@ +--TEST-- +Segfault when removing the Doctype node +--SKIPIF-- + +--FILE-- + +footext'> +bartext'> +]> +&foo;&bar; +XML; + +$doc = new DOMDocument(); +$doc->loadXML($xml, LIBXML_NOENT); +$n = $doc->doctype; +$doc->removeChild($n); +var_dump($n); +print $doc->saveXML(); +?> +===DONE=== + +--EXPECTF-- +object(DOMDocumentType)#%d (0) { +} + +footextbartext +===DONE=== diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index 222ff98bf2421..e19075cd263a4 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -224,6 +224,7 @@ static void php_libxml_node_free_list(xmlNodePtr node TSRMLS_DC) switch (node->type) { /* Skip property freeing for the following types */ case XML_NOTATION_NODE: + case XML_ENTITY_DECL: break; case XML_ENTITY_REF_NODE: php_libxml_node_free_list((xmlNodePtr) node->properties TSRMLS_CC); @@ -235,7 +236,6 @@ static void php_libxml_node_free_list(xmlNodePtr node TSRMLS_DC) case XML_ATTRIBUTE_DECL: case XML_DTD_NODE: case XML_DOCUMENT_TYPE_NODE: - case XML_ENTITY_DECL: case XML_NAMESPACE_DECL: case XML_TEXT_NODE: php_libxml_node_free_list(node->children TSRMLS_CC); From 73c1488fec205da2d9a7db7c07e652342ffaeab1 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 29 May 2011 12:29:19 +0000 Subject: [PATCH 0068/2394] Fixed bug #54946 (stream_get_contents infinite loop) --- ext/standard/tests/streams/bug54946.phpt | 40 ++++++++++++++++++++++++ main/streams/streams.c | 3 ++ 2 files changed, 43 insertions(+) create mode 100644 ext/standard/tests/streams/bug54946.phpt diff --git a/ext/standard/tests/streams/bug54946.phpt b/ext/standard/tests/streams/bug54946.phpt new file mode 100644 index 0000000000000..b3fa73df5ce23 --- /dev/null +++ b/ext/standard/tests/streams/bug54946.phpt @@ -0,0 +1,40 @@ +--TEST-- +Bug#54946 stream_get_contents infinite loop +--FILE-- + +===DONE=== +--EXPECT-- +string(0) "" +string(0) "" +string(0) "" +===DONE=== + diff --git a/main/streams/streams.c b/main/streams/streams.c index 4a227e8f02d82..1017f221241cc 100755 --- a/main/streams/streams.c +++ b/main/streams/streams.c @@ -1362,6 +1362,9 @@ PHPAPI size_t _php_stream_copy_to_mem(php_stream *src, char **buf, size_t maxlen ptr = *buf = pemalloc_rel_orig(maxlen + 1, persistent); while ((len < maxlen) && !php_stream_eof(src)) { ret = php_stream_read(src, ptr, maxlen - len); + if (!ret) { + break; + } len += ret; ptr += ret; } From 7acafb506a652cc08728e8fdab73c1e06d4bf006 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 30 May 2011 15:57:50 +0000 Subject: [PATCH 0069/2394] Fixed bug #52496 (Zero exit code on option parsing failure). --- sapi/cli/php_cli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 68267c45c553b..f90bd061f6d6d 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -813,7 +813,7 @@ int main(int argc, char *argv[]) request_started = 1; php_cli_usage(argv[0]); php_output_end_all(TSRMLS_C); - exit_status=0; + exit_status = (c == '?' && argc > 1 && !strchr(argv[1], c)); goto out; case 'i': /* php info & quit */ From b8b9fe17543d45d8863f31463ed9ca18cde24408 Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Mon, 30 May 2011 23:26:33 +0000 Subject: [PATCH 0070/2394] Updated qa-release.php notes as per the new qa-release.php syntax --- README.RELEASE_PROCESS | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/README.RELEASE_PROCESS b/README.RELEASE_PROCESS index 2ae5898b6bb53..8576d062c4a45 100644 --- a/README.RELEASE_PROCESS +++ b/README.RELEASE_PROCESS @@ -104,16 +104,14 @@ Derick) run the following commands for you: ``sudo -u ezmlm ezmlm-sub ~ezmlm/primary-qa-tester/mod moderator-email-address`` -3. Update the MD5 sums in ``web/qa/trunk/include/rc-md5sums.txt`` (no empty lines, ordered by filename, odler version number first, .bz2 before .gz). +3. Update ``web/qa/trunk/include/release-qa.php`` with the appropriate information. + See the documentation within release-qa.php for more information, but all releases + and RCs are configured here. Only $QA_RELEASES needs to be edited. -4. Update in ``web/qa/trunk/include/release-qa.php`` constants with the new RC and -commit this. + Example: When rolling an RC, set the 'rc' with appropriate information for the + given version. - a. ``$BUILD_TEST_RELEASES`` = array("4.4.7RC1", "5.2.2RC1") - - b. ``$CURRENT_QA_RELEASE_4`` = "4.4.7RC1" (``$CURRENT_QA_RELEASE_5`` for PHP5) - - c. ``$RELEASE_PROCESS`` = array(4 => true, 5 => true) + Note: Remember to update the MD5 checksum information. 1. Update in ``web/php-bugs/trunk/include/php_versions.php`` to include the new RC and commit. @@ -247,13 +245,11 @@ number, and remove the RC from there. 11. Update ``qaweb/include/release-qa.php`` - a. Update the $BUILD_TEST_RELEASES array with the release name - - b. Update $RELEASE_PROCESS array (set to false) - - I. For PHP4: Set $CURRENT_QA_RELEASE_4 to false + - Update $QA_RELEASES with the appropriate information, which means bumping + the version number to an upcoming version. - II. For PHP5: Set $CURRENT_QA_RELEASE_5 to false + Example: If PHP 5.3.7 is being released, then PHP 5.3.8 is the next QA version, + so replace 5.3.7 with 5.3.8 within $QA_RELEASES. Re-releasing the same version (or -pl) -------------------------------------- From d0ba3e188155188944090e0659716f75ab6dda1d Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 31 May 2011 08:26:53 +0000 Subject: [PATCH 0071/2394] Fixed bug #54957 (Memleak in alloc_globals_ctor) --- Zend/zend_alloc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 4509a2b5f2c38..108309c1d7097 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -1602,6 +1602,9 @@ ZEND_API void zend_mm_shutdown(zend_mm_heap *heap, int full_shutdown, int silent int internal; if (!heap->use_zend_alloc) { + if (full_shutdown) { + free(heap); + } return; } From 4bc1fb265b7816a5ff0a44098ed9f2397296666b Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 31 May 2011 08:59:32 +0000 Subject: [PATCH 0072/2394] Removed unnecessary rinit/rshutdown --- ext/pdo_pgsql/pdo_pgsql.c | 22 ++-------------------- ext/pdo_pgsql/php_pdo_pgsql.h | 2 -- 2 files changed, 2 insertions(+), 22 deletions(-) diff --git a/ext/pdo_pgsql/pdo_pgsql.c b/ext/pdo_pgsql/pdo_pgsql.c index bdc6c31e359ba..805d752afc517 100644 --- a/ext/pdo_pgsql/pdo_pgsql.c +++ b/ext/pdo_pgsql/pdo_pgsql.c @@ -67,8 +67,8 @@ zend_module_entry pdo_pgsql_module_entry = { pdo_pgsql_functions, PHP_MINIT(pdo_pgsql), PHP_MSHUTDOWN(pdo_pgsql), - PHP_RINIT(pdo_pgsql), - PHP_RSHUTDOWN(pdo_pgsql), + NULL, + NULL, PHP_MINFO(pdo_pgsql), "1.0.2", STANDARD_MODULE_PROPERTIES @@ -106,24 +106,6 @@ PHP_MSHUTDOWN_FUNCTION(pdo_pgsql) } /* }}} */ -/* {{{ PHP_RINIT_FUNCTION - */ -PHP_RINIT_FUNCTION(pdo_pgsql) -{ - /* php_pdo_register_driver(&pdo_pgsql_driver); */ - return SUCCESS; -} -/* }}} */ - -/* {{{ PHP_MSHUTDOWN_FUNCTION - */ -PHP_RSHUTDOWN_FUNCTION(pdo_pgsql) -{ - /* php_pdo_unregister_driver(&pdo_pgsql_driver); */ - return SUCCESS; -} -/* }}} */ - /* {{{ PHP_MINFO_FUNCTION */ PHP_MINFO_FUNCTION(pdo_pgsql) diff --git a/ext/pdo_pgsql/php_pdo_pgsql.h b/ext/pdo_pgsql/php_pdo_pgsql.h index 4dd4a7c986886..f3fa759534dbe 100644 --- a/ext/pdo_pgsql/php_pdo_pgsql.h +++ b/ext/pdo_pgsql/php_pdo_pgsql.h @@ -32,8 +32,6 @@ extern zend_module_entry pdo_pgsql_module_entry; PHP_MINIT_FUNCTION(pdo_pgsql); PHP_MSHUTDOWN_FUNCTION(pdo_pgsql); -PHP_RINIT_FUNCTION(pdo_pgsql); -PHP_RSHUTDOWN_FUNCTION(pdo_pgsql); PHP_MINFO_FUNCTION(pdo_pgsql); #endif /* PHP_PDO_PGSQL_H */ From d9ba7820d47e224dc516803363542dd32d81a47e Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 31 May 2011 09:20:51 +0000 Subject: [PATCH 0073/2394] Fixed bug #54910 (Crash when calling call_user_func with unknown function name) --- Zend/tests/bug54910.phpt | 28 ++++++++++++++++++++++++++++ Zend/zend_API.c | 5 +++++ 2 files changed, 33 insertions(+) create mode 100644 Zend/tests/bug54910.phpt diff --git a/Zend/tests/bug54910.phpt b/Zend/tests/bug54910.phpt new file mode 100644 index 0000000000000..8808cd0609b42 --- /dev/null +++ b/Zend/tests/bug54910.phpt @@ -0,0 +1,28 @@ +--TEST-- +Bug #54910 (Crash when calling call_user_func with unknown function name) +--FILE-- +get(); + } + die("No such method - '$method'\n"); + } + + protected function get() { + $class = get_class($this); + $call = array($class, 'noSuchMethod'); + + if (is_callable($call)) { + call_user_func($call); + } + } +} + +class B extends A {} + +$input = new B(); +echo $input->getEmail(); +--EXPECT-- +No such method - 'noSuchMethod' diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 2b87648e30376..d6933cf402fe2 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -2773,6 +2773,11 @@ static int zend_is_callable_check_func(int check_flags, zval *callable, zend_fca if (fcc->function_handler) { retval = 1; call_via_handler = (fcc->function_handler->common.fn_flags & ZEND_ACC_CALL_VIA_HANDLER) != 0; + if (call_via_handler && !fcc->object_ptr && EG(This) && + Z_OBJ_HT_P(EG(This))->get_class_entry && + instanceof_function(Z_OBJCE_P(EG(This)), fcc->calling_scope TSRMLS_CC)) { + fcc->object_ptr = EG(This); + } } } } From 33701b76aed553084e466d824b6b204030390733 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 31 May 2011 10:35:07 +0000 Subject: [PATCH 0074/2394] fix macros --- ext/mysqlnd/mysqlnd_priv.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_priv.h b/ext/mysqlnd/mysqlnd_priv.h index b76984bf478f5..49ec127800634 100644 --- a/ext/mysqlnd/mysqlnd_priv.h +++ b/ext/mysqlnd/mysqlnd_priv.h @@ -114,7 +114,7 @@ if ((message)) { \ (buf) = mnd_pestrndup((message), (len), (persistent)); \ } else { \ - buf = NULL; \ + (buf) = NULL; \ } \ (buf_len) = (len); \ } @@ -131,22 +131,22 @@ #define SET_EMPTY_ERROR(error_info) \ { \ - error_info.error_no = 0; \ - error_info.error[0] = '\0'; \ - strlcpy(error_info.sqlstate, "00000", sizeof(error_info.sqlstate)); \ + (error_info).error_no = 0; \ + (error_info).error[0] = '\0'; \ + strlcpy((error_info).sqlstate, "00000", sizeof((error_info).sqlstate)); \ } #define SET_CLIENT_ERROR(error_info, a, b, c) \ { \ - error_info.error_no = (a); \ - strlcpy(error_info.sqlstate, (b), sizeof(error_info.sqlstate)); \ - strlcpy(error_info.error, (c), sizeof(error_info.error)); \ + (error_info).error_no = (a); \ + strlcpy((error_info).sqlstate, (b), sizeof((error_info).sqlstate)); \ + strlcpy((error_info).error, (c), sizeof((error_info).error)); \ } -#define SET_OOM_ERROR(error_info) SET_CLIENT_ERROR(error_info, CR_OUT_OF_MEMORY, UNKNOWN_SQLSTATE, mysqlnd_out_of_memory) +#define SET_OOM_ERROR(error_info) SET_CLIENT_ERROR((error_info), CR_OUT_OF_MEMORY, UNKNOWN_SQLSTATE, mysqlnd_out_of_memory) -#define SET_STMT_ERROR(stmt, a, b, c) SET_CLIENT_ERROR(stmt->error_info, a, b, c) +#define SET_STMT_ERROR(stmt, a, b, c) SET_CLIENT_ERROR((stmt)->error_info, a, b, c) #ifdef ZTS @@ -154,7 +154,7 @@ #define CONN_SET_STATE(c, s) (c)->m->set_state((c), (s) TSRMLS_CC) #else #define CONN_GET_STATE(c) ((c)->state) -#define CONN_SET_STATE(c, s) ((c)->state = s) +#define CONN_SET_STATE(c, s) ((c)->state = (s)) #endif From a44a8af3a05aa286a98f0241a84346258af91c3d Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Tue, 31 May 2011 12:45:00 +0000 Subject: [PATCH 0075/2394] Removed test since there's no more safe_mode in PHP >= 5.4. --- ext/curl/tests/curl_setopt_basic001.phpt | 35 ------------------------ 1 file changed, 35 deletions(-) delete mode 100644 ext/curl/tests/curl_setopt_basic001.phpt diff --git a/ext/curl/tests/curl_setopt_basic001.phpt b/ext/curl/tests/curl_setopt_basic001.phpt deleted file mode 100644 index 7b7ab0c5769d6..0000000000000 --- a/ext/curl/tests/curl_setopt_basic001.phpt +++ /dev/null @@ -1,35 +0,0 @@ ---TEST-- -curl_setopt basic tests. ---CREDITS-- -Paul Sohier -#phptestfest utrecht ---INI-- -safe_mode=On ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0 -*** Testing curl_setopt with CURLOPT_FOLLOWLOCATION in safemode - -Warning: curl_setopt(): CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set in %s on line %d -bool(false) - From a2566cb6847a6b3945f8ef34c1ca64a62d4b0718 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Tue, 31 May 2011 12:57:40 +0000 Subject: [PATCH 0076/2394] Fixed notice breaking the test. --- ext/curl/tests/bug48207.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/curl/tests/bug48207.phpt b/ext/curl/tests/bug48207.phpt index b6caa618c1f6f..6ac16f5ea831f 100644 --- a/ext/curl/tests/bug48207.phpt +++ b/ext/curl/tests/bug48207.phpt @@ -18,7 +18,7 @@ $host = getenv('PHP_CURL_HTTP_REMOTE_SERVER'); if(!empty($host)) { // Use the set Environment variable - $url = "$host/get.php"; + $url = "$host/get.php?test=1"; } else { From b730fde67fb214597f3231be1c67d012f88987cf Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 31 May 2011 20:42:44 +0000 Subject: [PATCH 0077/2394] reuse code --- ext/mysqlnd/mysqlnd.c | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 61943aa5ffb1b..a927018dd188e 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -996,25 +996,18 @@ PHPAPI MYSQLND * mysqlnd_connect(MYSQLND * conn, static enum_func_status MYSQLND_METHOD(mysqlnd_conn, query)(MYSQLND * conn, const char * query, unsigned int query_len TSRMLS_DC) { - enum_func_status ret; + enum_func_status ret = FAIL; DBG_ENTER("mysqlnd_conn::query"); DBG_INF_FMT("conn=%llu query=%s", conn->thread_id, query); - if (PASS != conn->m->simple_command(conn, COM_QUERY, (zend_uchar *) query, query_len, - PROT_LAST /* we will handle the OK packet*/, - FALSE, FALSE TSRMLS_CC)) { - DBG_RETURN(FAIL); - } - CONN_SET_STATE(conn, CONN_QUERY_SENT); - /* - Here read the result set. We don't do it in simple_command because it need - information from the ok packet. We will fetch it ourselves. - */ - ret = conn->m->query_read_result_set_header(conn, NULL TSRMLS_CC); - if (ret == PASS && conn->last_query_type == QUERY_UPSERT && conn->upsert_status.affected_rows) { - MYSQLND_INC_CONN_STATISTIC_W_VALUE(conn->stats, STAT_ROWS_AFFECTED_NORMAL, conn->upsert_status.affected_rows); + if (PASS == conn->m->send_query(conn, query, query_len TSRMLS_CC) && + PASS == conn->m->reap_query(conn TSRMLS_CC)) + { + ret = PASS; + if (conn->last_query_type == QUERY_UPSERT && conn->upsert_status.affected_rows) { + MYSQLND_INC_CONN_STATISTIC_W_VALUE(conn->stats, STAT_ROWS_AFFECTED_NORMAL, conn->upsert_status.affected_rows); + } } - DBG_RETURN(ret); } /* }}} */ @@ -1031,7 +1024,9 @@ MYSQLND_METHOD(mysqlnd_conn, send_query)(MYSQLND * conn, const char * query, uns ret = conn->m->simple_command(conn, COM_QUERY, (zend_uchar *) query, query_len, PROT_LAST /* we will handle the OK packet*/, FALSE, FALSE TSRMLS_CC); - CONN_SET_STATE(conn, CONN_QUERY_SENT); + if (PASS == ret) { + CONN_SET_STATE(conn, CONN_QUERY_SENT); + } DBG_RETURN(ret); } /* }}} */ From 5c29ef1d8ae06fef384a2fa1bcd771f0b7a245df Mon Sep 17 00:00:00 2001 From: Rafael Machado Dohms Date: Tue, 31 May 2011 21:10:01 +0000 Subject: [PATCH 0078/2394] Adding testcases to validate imageloadfont input parameter validation, tests were developed at #tek11 testfest --- ext/gd/tests/imageloadfont_error1.phpt | 15 +++++++++++++++ ext/gd/tests/imageloadfont_error2.phpt | 15 +++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 ext/gd/tests/imageloadfont_error1.phpt create mode 100644 ext/gd/tests/imageloadfont_error2.phpt diff --git a/ext/gd/tests/imageloadfont_error1.phpt b/ext/gd/tests/imageloadfont_error1.phpt new file mode 100644 index 0000000000000..16d1a3c3a6756 --- /dev/null +++ b/ext/gd/tests/imageloadfont_error1.phpt @@ -0,0 +1,15 @@ +--TEST-- +Testing that imageloadfont() breaks on non-string first parameter +--CREDITS-- +Neveo Harrison #testfest #tek11 +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +Warning: imageloadfont() expects parameter 1 to be string, array given in %s on line %d +NULL \ No newline at end of file diff --git a/ext/gd/tests/imageloadfont_error2.phpt b/ext/gd/tests/imageloadfont_error2.phpt new file mode 100644 index 0000000000000..459cb71f5f5cd --- /dev/null +++ b/ext/gd/tests/imageloadfont_error2.phpt @@ -0,0 +1,15 @@ +--TEST-- +Testing that imageloadfont() breaks on invalid file passed as first argument +--CREDITS-- +Austin Drouare #testfest #tek11 +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +Warning: imageloadfont(\src\invalidfile.font): failed to open stream: No such file or directory in %s on line %d +bool(false) From 850db4b315eb56d261098a6f42df6a8375cbd937 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 1 Jun 2011 09:44:38 +0000 Subject: [PATCH 0079/2394] Fixed bug #54484 (Empty string in json_decode doesn't reset json_last_error()). --- ext/json/json.c | 2 ++ ext/json/tests/bug54484.phpt | 25 +++++++++++++++++++++++++ 2 files changed, 27 insertions(+) create mode 100644 ext/json/tests/bug54484.phpt diff --git a/ext/json/json.c b/ext/json/json.c index db3fad9871090..7231e647c3afd 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -703,6 +703,8 @@ static PHP_FUNCTION(json_decode) return; } + JSON_G(error_code) = 0; + if (!str_len) { RETURN_NULL(); } diff --git a/ext/json/tests/bug54484.phpt b/ext/json/tests/bug54484.phpt new file mode 100644 index 0000000000000..d698ab5416420 --- /dev/null +++ b/ext/json/tests/bug54484.phpt @@ -0,0 +1,25 @@ +--TEST-- +Bug #54484 (Empty string in json_decode doesn't reset json_last_error) +--SKIPIF-- + +--FILE-- + +--EXPECT-- +int(0) +int(0) +int(4) +int(0) From 8083c1ab893e62e5b99b48308bb44e65c25dd03c Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 1 Jun 2011 13:23:25 +0000 Subject: [PATCH 0080/2394] Fixed bug #52104 (bindColumn creates Warning regardless of ATTR_ERRMODE settings). --- ext/pdo/pdo_stmt.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c index 6caf8d6b885a2..4a86da967b5d8 100755 --- a/ext/pdo/pdo_stmt.c +++ b/ext/pdo/pdo_stmt.c @@ -349,7 +349,10 @@ static int really_register_bound_param(struct pdo_bound_param_data *param, pdo_s /* if you prepare and then execute passing an array of params keyed by names, * then this will trigger, and we don't want that */ if (param->paramno == -1) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Did not found column name '%s' in the defined columns; it will not be bound", param->name); + char *tmp; + spprintf(&tmp, 0, "Did not find column name '%s' in the defined columns; it will not be bound", param->name); + pdo_raise_impl_error(stmt->dbh, stmt, "HY000", tmp TSRMLS_CC); + efree(tmp); } } From ccd3633b5c8c19cbab0712c03c65ff183680cab0 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 1 Jun 2011 16:26:21 +0000 Subject: [PATCH 0081/2394] Implemented FR #54561 (Expose ICU Version & ICU Data Version info). --- ext/intl/php_intl.c | 4 ++++ ext/intl/tests/intl_icu_version_constant.phpt | 10 ++++++++++ 2 files changed, 14 insertions(+) create mode 100644 ext/intl/tests/intl_icu_version_constant.phpt diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index ab5640486ddfc..fa328cc5afd31 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -590,6 +590,10 @@ PHP_MINIT_FUNCTION( intl ) REGISTER_INI_ENTRIES(); REGISTER_LONG_CONSTANT("INTL_MAX_LOCALE_LEN", INTL_MAX_LOCALE_LEN, CONST_CS); + REGISTER_STRING_CONSTANT("INTL_ICU_VERSION", U_ICU_VERSION, CONST_PERSISTENT | CONST_CS); +#ifdef U_ICU_DATA_VERSION + REGISTER_STRING_CONSTANT("INTL_ICU_DATA_VERSION", U_ICU_DATA_VERSION, CONST_PERSISTENT | CONST_CS); +#endif /* Register 'Collator' PHP class */ collator_register_Collator_class( TSRMLS_C ); diff --git a/ext/intl/tests/intl_icu_version_constant.phpt b/ext/intl/tests/intl_icu_version_constant.phpt new file mode 100644 index 0000000000000..13160693c22bb --- /dev/null +++ b/ext/intl/tests/intl_icu_version_constant.phpt @@ -0,0 +1,10 @@ +--TEST-- +INTL_ICU_VERSION constant +--SKIPIF-- + +--FILE-- + +--EXPECT-- +bool(true) From be20efc476683eb46b90c1ec4375acadb278d8db Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 1 Jun 2011 16:59:23 +0000 Subject: [PATCH 0082/2394] More tests --- ext/intl/tests/intl_icu_data_version_constant.phpt | 10 ++++++++++ ext/intl/tests/resourcebundle_internal.phpt | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 ext/intl/tests/intl_icu_data_version_constant.phpt diff --git a/ext/intl/tests/intl_icu_data_version_constant.phpt b/ext/intl/tests/intl_icu_data_version_constant.phpt new file mode 100644 index 0000000000000..ad0121858686b --- /dev/null +++ b/ext/intl/tests/intl_icu_data_version_constant.phpt @@ -0,0 +1,10 @@ +--TEST-- +INTL_ICU_DATA_VERSION constant +--SKIPIF-- + +--FILE-- + +--EXPECT-- +bool(true) diff --git a/ext/intl/tests/resourcebundle_internal.phpt b/ext/intl/tests/resourcebundle_internal.phpt index 7aefd854cec1a..fe90081e79b8a 100644 --- a/ext/intl/tests/resourcebundle_internal.phpt +++ b/ext/intl/tests/resourcebundle_internal.phpt @@ -1,7 +1,7 @@ --TEST-- Test ResourceBundle::__construct() with internal ICU bundles --SKIPIF-- - + --FILE-- Date: Thu, 2 Jun 2011 00:40:27 +0000 Subject: [PATCH 0083/2394] - Fixed bug #54970 (SplFixedArray::setSize() isn't resizing) --- ext/spl/spl_fixedarray.c | 7 +++++++ ext/spl/tests/bug54970.phpt | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 ext/spl/tests/bug54970.phpt diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c index fc282b4075612..34cb69cccdef0 100644 --- a/ext/spl/spl_fixedarray.c +++ b/ext/spl/spl_fixedarray.c @@ -154,6 +154,8 @@ static HashTable* spl_fixedarray_object_get_properties(zval *obj TSRMLS_DC) /* { int i = 0; if (intern->array) { + int j = zend_hash_num_elements(ht); + for (i = 0; i < intern->array->size; i++) { if (intern->array->elements[i]) { zend_hash_index_update(ht, i, (void *)&intern->array->elements[i], sizeof(zval *), NULL); @@ -166,6 +168,11 @@ static HashTable* spl_fixedarray_object_get_properties(zval *obj TSRMLS_DC) /* { Z_ADDREF_P(EG(uninitialized_zval_ptr)); } } + if (j > intern->array->size) { + for (i = intern->array->size; i < j; ++i) { + zend_hash_index_del(ht, i); + } + } } return ht; diff --git a/ext/spl/tests/bug54970.phpt b/ext/spl/tests/bug54970.phpt new file mode 100644 index 0000000000000..62b1eedb5b2fd --- /dev/null +++ b/ext/spl/tests/bug54970.phpt @@ -0,0 +1,33 @@ +--TEST-- +Bug #54970 (SplFixedArray::setSize() isn't resizing) +--FILE-- +setSize(3); +$fa[2] = '!'; +var_dump($fa); +$fa->setSize(2); +var_dump($fa); +var_dump($fa->getSize()); + + +?> +--EXPECTF-- +object(SplFixedArray)#%d (3) { + [0]=> + string(5) "Hello" + [1]=> + string(5) "World" + [2]=> + string(1) "!" +} +object(SplFixedArray)#%d (2) { + [0]=> + string(5) "Hello" + [1]=> + string(5) "World" +} +int(2) From e87534b01715d8da78f96f72f6127de67664b2a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Thu, 2 Jun 2011 08:46:40 +0000 Subject: [PATCH 0084/2394] - Fixed double registering of browscap ini directive. See bug #54896. --- ext/standard/browscap.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/ext/standard/browscap.c b/ext/standard/browscap.c index dc2c4f8392b99..282d9619aec9f 100644 --- a/ext/standard/browscap.c +++ b/ext/standard/browscap.c @@ -330,16 +330,10 @@ PHP_INI_MH(OnChangeBrowscap) } /* }}} */ -PHP_INI_BEGIN() - PHP_INI_ENTRY("browscap", NULL, PHP_INI_SYSTEM, OnChangeBrowscap) -PHP_INI_END() - PHP_MINIT_FUNCTION(browscap) /* {{{ */ { char *browscap = INI_STR("browscap"); - REGISTER_INI_ENTRIES(); - if (browscap && browscap[0]) { if (browscap_read_file(browscap, &global_bdata, 1 TSRMLS_CC) == FAILURE) { return FAILURE; From 939875133a2c389d621a9999a8ede3ddbc9b6637 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Thu, 2 Jun 2011 21:16:50 +0000 Subject: [PATCH 0085/2394] Zend Signal Handling (see RFC: https://wiki.php.net/rfc/zendsignals) This needs to go into 5.4 as well, but will wait for Pierre to review win32 situation # Patch by Lucas Nealan, Arnaud Le Blanc, Brian Shire & Ilia Alshanetsky --- TSRM/TSRM.c | 16 + TSRM/TSRM.h | 7 + TSRM/tsrm.m4 | 2 + Zend/Makefile.am | 2 +- Zend/Zend.m4 | 14 + Zend/zend.c | 8 + Zend/zend.h | 11 + Zend/zend_alloc.c | 61 ++- Zend/zend_execute_API.c | 28 +- Zend/zend_hash.c | 18 + Zend/zend_signal.c | 414 ++++++++++++++++++ Zend/zend_signal.h | 104 +++++ configure.in | 2 +- ext/pcntl/php_signal.c | 6 + ext/standard/info.c | 6 + .../tests/general_functions/phpinfo.phpt | 1 + main/SAPI.c | 4 + main/main.c | 29 +- 18 files changed, 701 insertions(+), 32 deletions(-) create mode 100644 Zend/zend_signal.c create mode 100644 Zend/zend_signal.h diff --git a/TSRM/TSRM.c b/TSRM/TSRM.c index 41368a4987d13..efdea5c880a9e 100644 --- a/TSRM/TSRM.c +++ b/TSRM/TSRM.c @@ -710,6 +710,22 @@ TSRM_API int tsrm_mutex_unlock(MUTEX_T mutexp) #endif } +/* + Changes the signal mask of the calling thread +*/ +#ifdef HAVE_SIGPROCMASK +TSRM_API int tsrm_sigmask(int how, const sigset_t *set, sigset_t *oldset) +{ + TSRM_ERROR((TSRM_ERROR_LEVEL_INFO, "Changed sigmask in thread: %ld", tsrm_thread_id())); + /* TODO: add support for other APIs */ +#ifdef PTHREADS + return pthread_sigmask(how, set, oldset); +#else + return sigprocmask(how, set, oldset); +#endif +} +#endif + TSRM_API void *tsrm_set_new_thread_begin_handler(tsrm_thread_begin_func_t new_thread_begin_handler) { diff --git a/TSRM/TSRM.h b/TSRM/TSRM.h index d3d6f9b2d7991..b232429d4d89e 100644 --- a/TSRM/TSRM.h +++ b/TSRM/TSRM.h @@ -90,6 +90,10 @@ typedef struct { # define MUTEX_T beos_ben * #endif +#ifdef HAVE_SIGNAL_H +#include +#endif + typedef void (*ts_allocate_ctor)(void *, void ***); typedef void (*ts_allocate_dtor)(void *, void ***); @@ -138,6 +142,9 @@ TSRM_API MUTEX_T tsrm_mutex_alloc(void); TSRM_API void tsrm_mutex_free(MUTEX_T mutexp); TSRM_API int tsrm_mutex_lock(MUTEX_T mutexp); TSRM_API int tsrm_mutex_unlock(MUTEX_T mutexp); +#ifdef HAVE_SIGPROCMASK +TSRM_API int tsrm_sigmask(int how, const sigset_t *set, sigset_t *oldset); +#endif TSRM_API void *tsrm_set_new_thread_begin_handler(tsrm_thread_begin_func_t new_thread_begin_handler); TSRM_API void *tsrm_set_new_thread_end_handler(tsrm_thread_end_func_t new_thread_end_handler); diff --git a/TSRM/tsrm.m4 b/TSRM/tsrm.m4 index 85e6a83a83317..b53a4bb805fff 100644 --- a/TSRM/tsrm.m4 +++ b/TSRM/tsrm.m4 @@ -30,6 +30,8 @@ AC_REQUIRE([AC_PROG_RANLIB])dnl AC_CHECK_HEADERS(stdarg.h) +AC_CHECK_FUNCS(sigprocmask) + ]) diff --git a/Zend/Makefile.am b/Zend/Makefile.am index 04b51081bfb5b..5ec4590fefe19 100644 --- a/Zend/Makefile.am +++ b/Zend/Makefile.am @@ -17,7 +17,7 @@ libZend_la_SOURCES=\ zend_objects_API.c zend_ts_hash.c zend_stream.c \ zend_default_classes.c \ zend_iterators.c zend_interfaces.c zend_exceptions.c \ - zend_strtod.c zend_closures.c zend_float.c zend_string.c + zend_strtod.c zend_closures.c zend_float.c zend_string.c zend_signal.c libZend_la_LDFLAGS = libZend_la_LIBADD = @ZEND_EXTRA_LIBS@ diff --git a/Zend/Zend.m4 b/Zend/Zend.m4 index ececf783b5c56..67b9ba09d76bb 100644 --- a/Zend/Zend.m4 +++ b/Zend/Zend.m4 @@ -392,8 +392,22 @@ int main() AC_CHECK_FUNCS(mremap) + +AC_CHECK_FUNC(sigaction, [ + ZEND_SIGNALS=yes + AC_DEFINE(ZEND_SIGNALS, 1, [Use zend signal handling]) + AC_DEFINE(HAVE_SIGACTION, 1, [Whether sigaction() is available]) +], [ + ZEND_SIGNALS=no ]) +if test "$ZEND_SIGNALS" = "yes"; then + CFLAGS="$CFLAGS -DZEND_SIGNALS" +fi +AC_MSG_CHECKING(whether to enable zend signal handling) +AC_MSG_RESULT($ZEND_SIGNALS) + +]) AC_DEFUN([LIBZEND_CPLUSPLUS_CHECKS],[ diff --git a/Zend/zend.c b/Zend/zend.c index 07bdf98a5649e..fbffcc38d2653 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -108,6 +108,9 @@ ZEND_INI_BEGIN() STD_ZEND_INI_BOOLEAN("zend.multibyte", "0", ZEND_INI_PERDIR, OnUpdateBool, multibyte, zend_compiler_globals, compiler_globals) ZEND_INI_ENTRY("zend.script_encoding", NULL, ZEND_INI_ALL, OnUpdateScriptEncoding) STD_ZEND_INI_BOOLEAN("zend.detect_unicode", "1", ZEND_INI_ALL, OnUpdateBool, detect_unicode, zend_compiler_globals, compiler_globals) +#ifdef ZEND_SIGNALS + STD_ZEND_INI_BOOLEAN("zend.signal_check", "0", ZEND_INI_SYSTEM, OnUpdateBool, check, zend_signal_globals_t, zend_signal_globals) +#endif ZEND_INI_END() @@ -659,8 +662,10 @@ int zend_startup(zend_utility_functions *utility_functions, char **extensions TS } zend_stream_open_function = utility_functions->stream_open_function; zend_message_dispatcher_p = utility_functions->message_handler; +#ifndef ZEND_SIGNALS zend_block_interruptions = utility_functions->block_interruptions; zend_unblock_interruptions = utility_functions->unblock_interruptions; +#endif zend_get_configuration_directive_p = utility_functions->get_configuration_directive; zend_ticks_function = utility_functions->ticks_function; zend_on_timeout = utility_functions->on_timeout; @@ -791,6 +796,9 @@ void zend_post_startup(TSRMLS_D) /* {{{ */ void zend_shutdown(TSRMLS_D) /* {{{ */ { +#ifdef ZEND_SIGNALS + zend_signal_shutdown(TSRMLS_C); +#endif #ifdef ZEND_WIN32 zend_shutdown_timeout_thread(); #endif diff --git a/Zend/zend.h b/Zend/zend.h index a80526c0eb8c9..7305b4b281303 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -531,8 +531,10 @@ typedef struct _zend_utility_functions { int (*write_function)(const char *str, uint str_length); FILE *(*fopen_function)(const char *filename, char **opened_path TSRMLS_DC); void (*message_handler)(long message, void *data TSRMLS_DC); +#ifndef ZEND_SIGNALS void (*block_interruptions)(void); void (*unblock_interruptions)(void); +#endif int (*get_configuration_directive)(const char *name, uint name_length, zval *contents); void (*ticks_function)(int ticks); void (*on_timeout)(int seconds TSRMLS_DC); @@ -678,8 +680,10 @@ BEGIN_EXTERN_C() extern ZEND_API int (*zend_printf)(const char *format, ...) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 1, 2); extern ZEND_API zend_write_func_t zend_write; extern ZEND_API FILE *(*zend_fopen)(const char *filename, char **opened_path TSRMLS_DC); +#ifndef ZEND_SIGNALS extern ZEND_API void (*zend_block_interruptions)(void); extern ZEND_API void (*zend_unblock_interruptions)(void); +#endif extern ZEND_API void (*zend_ticks_function)(int ticks); extern ZEND_API void (*zend_error_cb)(int type, const char *error_filename, const uint error_lineno, const char *format, va_list args) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 4, 0); extern void (*zend_on_timeout)(int seconds TSRMLS_DC); @@ -702,8 +706,15 @@ END_EXTERN_C() #define ZEND_UV(name) (zend_uv.name) +#ifndef ZEND_SIGNALS #define HANDLE_BLOCK_INTERRUPTIONS() if (zend_block_interruptions) { zend_block_interruptions(); } #define HANDLE_UNBLOCK_INTERRUPTIONS() if (zend_unblock_interruptions) { zend_unblock_interruptions(); } +#else +#include "zend_signal.h" + +#define HANDLE_BLOCK_INTERRUPTIONS() SIGG(depth)++; +#define HANDLE_UNBLOCK_INTERRUPTIONS() if (UNEXPECTED((--SIGG(depth))==SIGG(blocked))) { zend_signal_handler_unblock(TSRMLS_C); } +#endif BEGIN_EXTERN_C() ZEND_API void zend_message_dispatcher(long message, void *data TSRMLS_DC); diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 108309c1d7097..48d6cb8e32da0 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -1882,6 +1882,11 @@ static void *_zend_mm_alloc_int(zend_mm_heap *heap, size_t size ZEND_FILE_LINE_D size_t segment_size; zend_mm_segment *segment; int keep_rest = 0; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif + + HANDLE_BLOCK_INTERRUPTIONS(); if (EXPECTED(ZEND_MM_SMALL_SIZE(true_size))) { size_t index = ZEND_MM_BUCKET_INDEX(true_size); @@ -1902,6 +1907,7 @@ static void *_zend_mm_alloc_int(zend_mm_heap *heap, size_t size ZEND_FILE_LINE_D heap->cached -= true_size; ZEND_MM_CHECK_MAGIC(best_fit, MEM_BLOCK_CACHED); ZEND_MM_SET_DEBUG_INFO(best_fit, size, 1, 0); + HANDLE_UNBLOCK_INTERRUPTIONS(); return ZEND_MM_DATA_OF(best_fit); } #if ZEND_MM_CACHE_STAT @@ -1955,8 +1961,6 @@ static void *_zend_mm_alloc_int(zend_mm_heap *heap, size_t size ZEND_FILE_LINE_D segment_size = heap->block_size; } - HANDLE_BLOCK_INTERRUPTIONS(); - if (segment_size < true_size || heap->real_size + segment_size > heap->limit) { /* Memory limit overflow */ @@ -1978,8 +1982,8 @@ static void *_zend_mm_alloc_int(zend_mm_heap *heap, size_t size ZEND_FILE_LINE_D #if ZEND_MM_CACHE zend_mm_free_cache(heap); #endif - HANDLE_UNBLOCK_INTERRUPTIONS(); out_of_memory: + HANDLE_UNBLOCK_INTERRUPTIONS(); #if ZEND_DEBUG zend_mm_safe_error(heap, "Out of memory (allocated %ld) at %s:%d (tried to allocate %lu bytes)", heap->real_size, __zend_filename, __zend_lineno, size); #else @@ -2007,7 +2011,6 @@ static void *_zend_mm_alloc_int(zend_mm_heap *heap, size_t size ZEND_FILE_LINE_D } else { zend_mm_finished_searching_for_block: /* remove from free list */ - HANDLE_BLOCK_INTERRUPTIONS(); ZEND_MM_CHECK_MAGIC(best_fit, MEM_BLOCK_FREED); ZEND_MM_CHECK_COOKIE(best_fit); ZEND_MM_CHECK_BLOCK_LINKAGE(best_fit); @@ -2055,11 +2058,15 @@ static void _zend_mm_free_int(zend_mm_heap *heap, void *p ZEND_FILE_LINE_DC ZEND zend_mm_block *mm_block; zend_mm_block *next_block; size_t size; - +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif if (!ZEND_MM_VALID_PTR(p)) { return; } + HANDLE_BLOCK_INTERRUPTIONS(); + mm_block = ZEND_MM_HEADER_OF(p); size = ZEND_MM_BLOCK_SIZE(mm_block); ZEND_MM_CHECK_PROTECTION(mm_block); @@ -2082,12 +2089,11 @@ static void _zend_mm_free_int(zend_mm_heap *heap, void *p ZEND_FILE_LINE_DC ZEND heap->cache_stat[index].max_count = heap->cache_stat[index].count; } #endif + HANDLE_UNBLOCK_INTERRUPTIONS(); return; } #endif - HANDLE_BLOCK_INTERRUPTIONS(); - heap->size -= size; next_block = ZEND_MM_BLOCK_AT(mm_block, size); @@ -2117,10 +2123,14 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ size_t true_size; size_t orig_size; void *ptr; + TSRMLS_FETCH(); if (UNEXPECTED(!p) || !ZEND_MM_VALID_PTR(p)) { return _zend_mm_alloc_int(heap, size ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC); } + + HANDLE_BLOCK_INTERRUPTIONS(); + mm_block = ZEND_MM_HEADER_OF(p); true_size = ZEND_MM_TRUE_SIZE(size); orig_size = ZEND_MM_BLOCK_SIZE(mm_block); @@ -2136,7 +2146,6 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ if (remaining_size >= ZEND_MM_ALIGNED_MIN_HEADER_SIZE) { zend_mm_free_block *new_free_block; - HANDLE_BLOCK_INTERRUPTIONS(); next_block = ZEND_MM_BLOCK_AT(mm_block, orig_size); if (ZEND_MM_IS_FREE_BLOCK(next_block)) { remaining_size += ZEND_MM_FREE_BLOCK_SIZE(next_block); @@ -2152,9 +2161,9 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ /* add the new free block to the free list */ zend_mm_add_to_free_list(heap, new_free_block); heap->size += (true_size - orig_size); - HANDLE_UNBLOCK_INTERRUPTIONS(); } ZEND_MM_SET_DEBUG_INFO(mm_block, size, 0, 0); + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } @@ -2197,6 +2206,7 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ } #endif + HANDLE_UNBLOCK_INTERRUPTIONS(); return ptr; } } @@ -2211,7 +2221,6 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ size_t block_size = orig_size + ZEND_MM_FREE_BLOCK_SIZE(next_block); size_t remaining_size = block_size - true_size; - HANDLE_BLOCK_INTERRUPTIONS(); zend_mm_remove_from_free_list(heap, (zend_mm_free_block *) next_block); if (remaining_size < ZEND_MM_ALIGNED_MIN_HEADER_SIZE) { @@ -2242,7 +2251,6 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ return p; } else if (ZEND_MM_IS_FIRST_BLOCK(mm_block) && ZEND_MM_IS_GUARD_BLOCK(ZEND_MM_BLOCK_AT(next_block, ZEND_MM_FREE_BLOCK_SIZE(next_block)))) { - HANDLE_BLOCK_INTERRUPTIONS(); zend_mm_remove_from_free_list(heap, (zend_mm_free_block *) next_block); goto realloc_segment; } @@ -2253,7 +2261,6 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ size_t block_size; size_t remaining_size; - HANDLE_BLOCK_INTERRUPTIONS(); realloc_segment: /* segment size, size of block and size of guard block */ if (true_size > heap->block_size - (ZEND_MM_ALIGNED_SEGMENT_SIZE + ZEND_MM_ALIGNED_HEADER_SIZE)) { @@ -2286,8 +2293,8 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ #if ZEND_MM_CACHE zend_mm_free_cache(heap); #endif - HANDLE_UNBLOCK_INTERRUPTIONS(); out_of_memory: + HANDLE_UNBLOCK_INTERRUPTIONS(); #if ZEND_DEBUG zend_mm_safe_error(heap, "Out of memory (allocated %ld) at %s:%d (tried to allocate %ld bytes)", heap->real_size, __zend_filename, __zend_lineno, size); #else @@ -2351,6 +2358,7 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ memcpy(ptr, p, orig_size - ZEND_MM_ALIGNED_HEADER_SIZE); #endif _zend_mm_free_int(heap, p ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC); + HANDLE_UNBLOCK_INTERRUPTIONS(); return ptr; } @@ -2539,12 +2547,18 @@ ZEND_API void *_safe_realloc(void *ptr, size_t nmemb, size_t size, size_t offset ZEND_API void *_ecalloc(size_t nmemb, size_t size ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) { void *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif + HANDLE_BLOCK_INTERRUPTIONS(); p = _safe_emalloc(nmemb, size, 0 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC); if (UNEXPECTED(p == NULL)) { + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } memset(p, 0, size * nmemb); + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } @@ -2552,26 +2566,40 @@ ZEND_API char *_estrdup(const char *s ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) { int length; char *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif + + HANDLE_BLOCK_INTERRUPTIONS(); length = strlen(s)+1; p = (char *) _emalloc(length ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC); if (UNEXPECTED(p == NULL)) { + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } memcpy(p, s, length); + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } ZEND_API char *_estrndup(const char *s, uint length ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) { char *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif + + HANDLE_BLOCK_INTERRUPTIONS(); p = (char *) _emalloc(length+1 ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC); if (UNEXPECTED(p == NULL)) { + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } memcpy(p, s, length); p[length] = 0; + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } @@ -2579,15 +2607,22 @@ ZEND_API char *_estrndup(const char *s, uint length ZEND_FILE_LINE_DC ZEND_FILE_ ZEND_API char *zend_strndup(const char *s, uint length) { char *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif + + HANDLE_BLOCK_INTERRUPTIONS(); p = (char *) malloc(length+1); if (UNEXPECTED(p == NULL)) { + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } if (length) { memcpy(p, s, length); } p[length] = 0; + HANDLE_UNBLOCK_INTERRUPTIONS(); return p; } diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index e15344a4f0c37..f7594d9be1b92 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -1469,7 +1469,7 @@ void zend_set_timeout(long seconds, int reset_signals) /* {{{ */ # ifdef HAVE_SETITIMER { struct itimerval t_r; /* timeout requested */ - sigset_t sigset; + int signo; if(seconds) { t_r.it_value.tv_sec = seconds; @@ -1478,25 +1478,27 @@ void zend_set_timeout(long seconds, int reset_signals) /* {{{ */ # ifdef __CYGWIN__ setitimer(ITIMER_REAL, &t_r, NULL); } - if(reset_signals) { - signal(SIGALRM, zend_timeout); - sigemptyset(&sigset); - sigaddset(&sigset, SIGALRM); - } + signo = SIGALRM; # else setitimer(ITIMER_PROF, &t_r, NULL); } - if(reset_signals) { - signal(SIGPROF, zend_timeout); - sigemptyset(&sigset); - sigaddset(&sigset, SIGPROF); - } + signo = SIGPROF; # endif - if(reset_signals) { + + if (reset_signals) { +# ifdef ZEND_SIGNALS + zend_signal(signo, zend_timeout TSRMLS_CC); +# else + sigset_t sigset; + + signal(signo, zend_timeout); + sigemptyset(&sigset); + sigaddset(&sigset, signo); sigprocmask(SIG_UNBLOCK, &sigset, NULL); +# endif } } -# endif +# endif /* HAVE_SETITIMER */ #endif } /* }}} */ diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index 73c45a286cce8..cadeaa4daecb9 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -197,6 +197,9 @@ ZEND_API int _zend_hash_add_or_update(HashTable *ht, const char *arKey, uint nKe ulong h; uint nIndex; Bucket *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif IS_CONSISTENT(ht); @@ -276,6 +279,9 @@ ZEND_API int _zend_hash_quick_add_or_update(HashTable *ht, const char *arKey, ui { uint nIndex; Bucket *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif IS_CONSISTENT(ht); @@ -431,6 +437,9 @@ ZEND_API int _zend_hash_index_update_or_next_insert(HashTable *ht, ulong h, void static int zend_hash_do_resize(HashTable *ht) { Bucket **t; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif IS_CONSISTENT(ht); @@ -475,6 +484,9 @@ ZEND_API int zend_hash_del_key_or_index(HashTable *ht, const char *arKey, uint n { uint nIndex; Bucket *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif IS_CONSISTENT(ht); @@ -595,6 +607,9 @@ ZEND_API void zend_hash_clean(HashTable *ht) static Bucket *zend_hash_apply_deleter(HashTable *ht, Bucket *p) { Bucket *retval; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif HANDLE_BLOCK_INTERRUPTIONS(); if (p->pLast) { @@ -1194,6 +1209,9 @@ ZEND_API int zend_hash_get_current_data_ex(HashTable *ht, void **pData, HashPosi ZEND_API int zend_hash_update_current_key_ex(HashTable *ht, int key_type, const char *str_index, uint str_length, ulong num_index, int mode, HashPosition *pos) { Bucket *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif p = pos ? (*pos) : ht->pInternalPointer; diff --git a/Zend/zend_signal.c b/Zend/zend_signal.c new file mode 100644 index 0000000000000..dd7cca7cdd365 --- /dev/null +++ b/Zend/zend_signal.c @@ -0,0 +1,414 @@ +/* + +----------------------------------------------------------------------+ + | Zend Signal Handling | + +----------------------------------------------------------------------+ + | Copyright (c) 2008 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Lucas Nealan | + | Arnaud Le Blanc | + +----------------------------------------------------------------------+ + + This software was contributed to PHP by Facebook Inc. in 2008. + + Future revisions and derivatives of this source code must acknowledge + Facebook Inc. as the original contributor of this module by leaving + this note intact in the source code. + + All other licensing and usage conditions are those of the PHP Group. +*/ + + /* $Id$ */ + +#define _GNU_SOURCE +#include + +#include "zend.h" +#include "zend_globals.h" + +#ifdef HAVE_SIGNAL_H +#include +#endif + +#ifdef HAVE_UNISTD_H +#include +#endif + +#ifdef ZEND_SIGNALS + +#include "zend_signal.h" + +#ifdef ZTS +ZEND_API int zend_signal_globals_id; +#else +zend_signal_globals_t zend_signal_globals; +#endif + +static void zend_signal_handler(int signo, siginfo_t *siginfo, void *context TSRMLS_DC); +static int zend_signal_register(int signo, void (*handler)(int, siginfo_t*, void*) TSRMLS_DC); + +#ifdef __CYGWIN__ +#define TIMEOUT_SIG SIGALRM +#else +#define TIMEOUT_SIG SIGPROF +#endif + +static int zend_sigs[] = { TIMEOUT_SIG, SIGHUP, SIGINT, SIGQUIT, SIGTERM, SIGUSR1, SIGUSR2 }; + +#define SA_FLAGS_MASK ~(SA_NODEFER | SA_RESETHAND) + +/* True globals, written only at process startup */ +static zend_signal_entry_t global_orig_handlers[NSIG]; +static sigset_t global_sigmask; + +/* {{{ zend_signal_handler_defer + * Blocks signals if in critical section */ +void zend_signal_handler_defer(int signo, siginfo_t *siginfo, void *context) +{ + int errno_save = errno; + zend_signal_queue_t *queue, *qtmp; + TSRMLS_FETCH(); + + if (SIGG(active)) { + if (SIGG(depth) == 0) { /* try to handle signal */ + if (SIGG(blocked) != -1) { /* inverse */ + SIGG(blocked) = -1; /* signal is not blocked */ + } + if (SIGG(running) == 0) { + SIGG(running) = 1; + zend_signal_handler(signo, siginfo, context TSRMLS_CC); + + queue = SIGG(phead); + SIGG(phead) = NULL; + + while (queue) { + zend_signal_handler(queue->zend_signal.signo, queue->zend_signal.siginfo, queue->zend_signal.context TSRMLS_CC); + qtmp = queue->next; + queue->next = SIGG(pavail); + queue->zend_signal.signo = 0; + SIGG(pavail) = queue; + queue = qtmp; + } + SIGG(running) = 0; + } + } else { /* delay signal handling */ + SIGG(blocked) = 0; /* signal is blocked */ + + if ((queue = SIGG(pavail))) { /* if none available it's simply forgotton */ + SIGG(pavail) = queue->next; + queue->zend_signal.signo = signo; + queue->zend_signal.siginfo = siginfo; + queue->zend_signal.context = context; + queue->next = NULL; + + if (SIGG(phead) && SIGG(ptail)) { + SIGG(ptail)->next = queue; + } else { + SIGG(phead) = queue; + } + SIGG(ptail) = queue; + } +#if ZEND_DEBUG + else { /* this may not be safe to do, but could work and be useful */ + zend_output_debug_string(0, "zend_signal: not enough queue storage, lost signal (%d)", signo); + } +#endif + } + } else { + /* need to just run handler if we're inactive and getting a signal */ + zend_signal_handler(signo, siginfo, context TSRMLS_CC); + } + + errno = errno_save; +} /* }}} */ + +/* {{{ zend_signal_handler_unblock + * Handle deferred signal from HANDLE_UNBLOCK_ALARMS */ +void zend_signal_handler_unblock(TSRMLS_D) +{ + zend_signal_queue_t *queue; + zend_signal_t zend_signal; + + if (SIGG(active)) { + SIGNAL_BEGIN_CRITICAL(); /* procmask to protect handler_defer as if it were called by the kernel */ + queue = SIGG(phead); + SIGG(phead) = queue->next; + zend_signal = queue->zend_signal; + queue->next = SIGG(pavail); + queue->zend_signal.signo = 0; + SIGG(pavail) = queue; + + zend_signal_handler_defer(zend_signal.signo, zend_signal.siginfo, zend_signal.context); + SIGNAL_END_CRITICAL(); + } +} +/* }}} */ + +/* {{{ zend_signal_handler + * Call the previously registered handler for a signal + */ +static void zend_signal_handler(int signo, siginfo_t *siginfo, void *context TSRMLS_DC) +{ + int errno_save = errno; + struct sigaction sa = {{0}}; + sigset_t sigset; + zend_signal_entry_t p_sig = SIGG(handlers)[signo-1]; + + if (p_sig.handler == SIG_DFL) { /* raise default handler */ + if (sigaction(signo, NULL, &sa) == 0) { + sa.sa_handler = SIG_DFL; + sigemptyset(&sa.sa_mask); + + sigemptyset(&sigset); + sigaddset(&sigset, signo); + + if (sigaction(signo, &sa, NULL) == 0) { + /* throw away any blocked signals */ + sigprocmask(SIG_UNBLOCK, &sigset, NULL); + raise(signo); + } + } + } else if (p_sig.handler != SIG_IGN) { /* ignore SIG_IGN */ + if (p_sig.flags & SA_SIGINFO) { + if (p_sig.flags & SA_RESETHAND) { + SIGG(handlers)[signo-1].flags = 0; + SIGG(handlers)[signo-1].handler = SIG_DFL; + } + (*(void (*)(int, siginfo_t*, void*))p_sig.handler)(signo, siginfo, context); + } else { + (*(void (*)(int))p_sig.handler)(signo); + } + } + + errno = errno_save; +} /* }}} */ + +/* {{{ zend_sigaction + * Register a signal handler that will be deferred in critical sections */ +ZEND_API int zend_sigaction(int signo, const struct sigaction *act, struct sigaction *oldact TSRMLS_DC) +{ + struct sigaction sa = {{0}}; + sigset_t sigset; + + if (oldact != NULL) { + oldact->sa_flags = SIGG(handlers)[signo-1].flags; + oldact->sa_handler = (void *) SIGG(handlers)[signo-1].handler; + oldact->sa_mask = global_sigmask; + } + if (act != NULL) { + SIGG(handlers)[signo-1].flags = act->sa_flags; + if (act->sa_flags & SA_SIGINFO) { + SIGG(handlers)[signo-1].handler = (void *) act->sa_sigaction; + } else { + SIGG(handlers)[signo-1].handler = (void *) act->sa_handler; + } + + sa.sa_flags = SA_SIGINFO | (act->sa_flags & SA_FLAGS_MASK); + sa.sa_sigaction = zend_signal_handler_defer; + sa.sa_mask = global_sigmask; + + if (sigaction(signo, &sa, NULL) < 0) { + zend_error(E_ERROR, "Error installing signal handler for %d", signo); + } + + /* unsure this signal is not blocked */ + sigemptyset(&sigset); + sigaddset(&sigset, signo); + zend_sigprocmask(SIG_UNBLOCK, &sigset, NULL); + } + + return SUCCESS; +} +/* }}} */ + +/* {{{ zend_signal + * Register a signal handler that will be deferred in critical sections */ +ZEND_API int zend_signal(int signo, void (*handler)(int) TSRMLS_DC) +{ + struct sigaction sa = {{0}}; + + sa.sa_flags = 0; + sa.sa_handler = handler; + sa.sa_mask = global_sigmask; + + return zend_sigaction(signo, &sa, NULL TSRMLS_CC); +} +/* }}} */ + +/* {{{ zend_signal_register + * Set a handler for a signal we want to defer. + * Previously set handler must have been saved before. + */ +static int zend_signal_register(int signo, void (*handler)(int, siginfo_t*, void*) TSRMLS_DC) +{ + struct sigaction sa = {{0}}; + + if (sigaction(signo, NULL, &sa) == 0) { + if ((sa.sa_flags & SA_SIGINFO) && sa.sa_sigaction == handler) { + return FAILURE; + } + + SIGG(handlers)[signo-1].flags = sa.sa_flags; + if (sa.sa_flags & SA_SIGINFO) { + SIGG(handlers)[signo-1].handler = (void *)sa.sa_sigaction; + } else { + SIGG(handlers)[signo-1].handler = (void *)sa.sa_handler; + } + + sa.sa_flags = SA_SIGINFO; /* we'll use a siginfo handler */ + sa.sa_sigaction = handler; + sa.sa_mask = global_sigmask; + + if (sigaction(signo, &sa, NULL) < 0) { + zend_error(E_ERROR, "Error installing signal handler for %d", signo); + } + + return SUCCESS; + } + return FAILURE; +} /* }}} */ + +/* {{{ zend_signal_activate + * Install our signal handlers, per request */ +void zend_signal_activate(TSRMLS_D) +{ + int x; + + memcpy(&SIGG(handlers), &global_orig_handlers, sizeof(global_orig_handlers)); + + for (x=0; x < sizeof(zend_sigs) / sizeof(*zend_sigs); x++) { + zend_signal_register(zend_sigs[x], zend_signal_handler_defer TSRMLS_CC); + } + + SIGG(active) = 1; + SIGG(depth) = 0; +} /* }}} */ + +/* {{{ zend_signal_deactivate + * */ +void zend_signal_deactivate(TSRMLS_D) +{ + int x; + struct sigaction sa = {{0}}; + + if (SIGG(check)) { + if (SIGG(depth) != 0) { + zend_error(E_CORE_WARNING, "zend_signal: shutdown with non-zero blocking depth (%d)", SIGG(depth)); + } + /* did anyone steal our installed handler */ + for (x=0; x < sizeof(zend_sigs) / sizeof(*zend_sigs); x++) { + sigaction(zend_sigs[x], NULL, &sa); + if (sa.sa_sigaction != zend_signal_handler_defer) { + zend_error(E_CORE_WARNING, "zend_signal: handler was replaced for signal (%d) after startup", zend_sigs[x]); + } + } + } + + SIGNAL_BEGIN_CRITICAL(); + SIGG(active) = 0; + SIGG(running) = 0; + SIGG(blocked) = -1; + SIGG(depth) = 0; + SIGNAL_END_CRITICAL(); +} +/* }}} */ + +static void zend_signal_globals_ctor(zend_signal_globals_t *zend_signal_globals TSRMLS_DC) +{ + size_t x; + + memset(zend_signal_globals, 0, sizeof(*zend_signal_globals)); + zend_signal_globals->blocked = -1; + + for (x = 0; x < sizeof(zend_signal_globals->pstorage) / sizeof(*zend_signal_globals->pstorage); ++x) { + zend_signal_queue_t *queue = &zend_signal_globals->pstorage[x]; + queue->zend_signal.signo = 0; + queue->next = zend_signal_globals->pavail; + zend_signal_globals->pavail = queue; + } +} + +static void zend_signal_globals_dtor(zend_signal_globals_t *zend_signal_globals TSRMLS_DC) +{ + zend_signal_globals->blocked = -1; +} + +/* {{{ zend_signal_startup + * alloc zend signal globals */ +void zend_signal_startup() +{ + int signo; + struct sigaction sa = {{0}}; + +#ifdef ZTS + ts_allocate_id(&zend_signal_globals_id, sizeof(zend_signal_globals_t), (ts_allocate_ctor) zend_signal_globals_ctor, (ts_allocate_dtor) zend_signal_globals_dtor); +#else + zend_signal_globals_ctor(&zend_signal_globals); +#endif + + /* Used to block signals during execution of signal handlers */ + sigfillset(&global_sigmask); + sigdelset(&global_sigmask, SIGILL); + sigdelset(&global_sigmask, SIGABRT); + sigdelset(&global_sigmask, SIGFPE); + sigdelset(&global_sigmask, SIGKILL); + sigdelset(&global_sigmask, SIGSEGV); + sigdelset(&global_sigmask, SIGCONT); + sigdelset(&global_sigmask, SIGSTOP); + sigdelset(&global_sigmask, SIGTSTP); + sigdelset(&global_sigmask, SIGTTIN); + sigdelset(&global_sigmask, SIGTTOU); +#ifdef SIGBUS + sigdelset(&global_sigmask, SIGBUS); +#endif +#ifdef SIGSYS + sigdelset(&global_sigmask, SIGSYS); +#endif +#ifdef SIGTRAP + sigdelset(&global_sigmask, SIGTRAP); +#endif + + /* Save previously registered signal handlers into orig_handlers */ + memset(&global_orig_handlers, 0, sizeof(global_orig_handlers)); + for (signo = 1; signo <= NSIG; ++signo) { + if (sigaction(signo, NULL, &sa) == 0) { + global_orig_handlers[signo-1].flags = sa.sa_flags; + if (sa.sa_flags & SA_SIGINFO) { + global_orig_handlers[signo-1].handler = (void *) sa.sa_sigaction; + } else { + global_orig_handlers[signo-1].handler = (void *) sa.sa_handler; + } + } + } +} +/* }}} */ + +/* {{{ zend_signal_shutdown + * called by zend_shutdown */ +void zend_signal_shutdown(TSRMLS_D) +{ +#ifndef ZTS + zend_signal_globals_dtor(&zend_signal_globals); +#endif +} +/* }}} */ + + +#endif /* ZEND_SIGNALS */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * indent-tabs-mode: t + * End: + * vim600: fdm=marker + * vim: noet sw=4 ts=4 + */ diff --git a/Zend/zend_signal.h b/Zend/zend_signal.h new file mode 100644 index 0000000000000..bc101320911b5 --- /dev/null +++ b/Zend/zend_signal.h @@ -0,0 +1,104 @@ +/* + +----------------------------------------------------------------------+ + | Zend Signal Handling | + +----------------------------------------------------------------------+ + | Copyright (c) 2008 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Lucas Nealan | + | Arnaud Le Blanc | + +----------------------------------------------------------------------+ + + */ + +/* $Id$ */ + +#ifndef ZEND_SIGNAL_H +#define ZEND_SIGNAL_H + +#ifdef HAVE_SIGNAL_H +#include +#endif + +#ifndef NSIG +#define NSIG 65 +#endif + +#ifndef ZEND_SIGNAL_QUEUE_SIZE +#define ZEND_SIGNAL_QUEUE_SIZE 32 +#endif + +/* Signal structs */ +typedef struct _zend_signal_entry_t { + int flags; /* sigaction style flags */ + void* handler; /* signal handler or context */ +} zend_signal_entry_t; + +typedef struct _zend_signal_t { + int signo; + siginfo_t *siginfo; + void* context; +} zend_signal_t; + +typedef struct _zend_signal_queue_t { + zend_signal_t zend_signal; + struct _zend_signal_queue_t *next; +} zend_signal_queue_t; + +/* Signal Globals */ +typedef struct _zend_signal_globals_t { + int depth; + int blocked; /* 0==TRUE, -1==FALSE */ + int running; /* in signal handler execution */ + int active; /* internal signal handling is enabled */ + int initialized; /* memory initialized */ + zend_bool check; /* check for replaced handlers on shutdown */ + zend_signal_entry_t handlers[NSIG]; + zend_signal_queue_t pstorage[ZEND_SIGNAL_QUEUE_SIZE], *phead, *ptail, *pavail; /* pending queue */ +} zend_signal_globals_t; + +#ifdef ZTS +# define SIGG(v) TSRMG(zend_signal_globals_id, zend_signal_globals_t *, v) +BEGIN_EXTERN_C() +ZEND_API extern int zend_signal_globals_id; +END_EXTERN_C() +#else /* ZTS */ +# define SIGG(v) (zend_signal_globals.v) +extern ZEND_API zend_signal_globals_t zend_signal_globals; +#endif /* not ZTS */ + +# define SIGNAL_BEGIN_CRITICAL() sigset_t oldmask; \ + zend_sigprocmask(SIG_BLOCK, &global_sigmask, &oldmask); +# define SIGNAL_END_CRITICAL() zend_sigprocmask(SIG_SETMASK, &oldmask, NULL); + +void zend_signal_handler_defer(int signo, siginfo_t *siginfo, void *context); +void zend_signal_handler_unblock(); +void zend_signal_activate(TSRMLS_D); +void zend_signal_deactivate(TSRMLS_D); +void zend_signal_startup(); +void zend_signal_shutdown(TSRMLS_D); +ZEND_API int zend_signal(int signo, void (*handler)(int) TSRMLS_DC); +ZEND_API int zend_sigaction(int signo, const struct sigaction *act, struct sigaction *oldact TSRMLS_DC); + +#ifdef ZTS +#define zend_sigprocmask(signo, set, oldset) tsrm_sigmask((signo), (set), (oldset)) +#else +#define zend_sigprocmask(signo, set, oldset) sigprocmask((signo), (set), (oldset)) +#endif + +#endif /* ZEND_SIGNAL_H */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * indent-tabs-mode: t + * End: + */ diff --git a/configure.in b/configure.in index d881f37f9d6fb..a905cede231af 100644 --- a/configure.in +++ b/configure.in @@ -1473,7 +1473,7 @@ PHP_ADD_SOURCES(Zend, \ zend_list.c zend_indent.c zend_builtin_functions.c zend_sprintf.c \ zend_ini.c zend_qsort.c zend_multibyte.c zend_ts_hash.c zend_stream.c \ zend_iterators.c zend_interfaces.c zend_exceptions.c zend_strtod.c zend_gc.c \ - zend_closures.c zend_float.c zend_string.c) + zend_closures.c zend_float.c zend_string.c zend_signal.c) if test -r "$abs_srcdir/Zend/zend_objects.c"; then PHP_ADD_SOURCES(Zend, zend_objects.c zend_object_handlers.c zend_objects_API.c zend_default_classes.c) diff --git a/ext/pcntl/php_signal.c b/ext/pcntl/php_signal.c index 00ab6b425f0a8..298572875941f 100644 --- a/ext/pcntl/php_signal.c +++ b/ext/pcntl/php_signal.c @@ -41,8 +41,14 @@ Sigfunc *php_signal4(int signo, Sigfunc *func, int restart, int mask_all) act.sa_flags |= SA_RESTART; /* SVR4, 4.3+BSD */ #endif } +#ifdef ZEND_SIGNALS + if (zend_sigaction(signo, &act, &oact) < 0) +#else if (sigaction(signo, &act, &oact) < 0) +#endif + { return SIG_ERR; + } return oact.sa_handler; } diff --git a/ext/standard/info.c b/ext/standard/info.c index 18a1e947dadb7..2bee7e9803838 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -747,6 +747,12 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) php_info_print_table_row(2, "Thread Safety", "disabled" ); #endif +#ifdef ZEND_SIGNALS + php_info_print_table_row(2, "Zend Signal Handling", "enabled" ); +#else + php_info_print_table_row(2, "Zend Signal Handling", "disabled" ); +#endif + php_info_print_table_row(2, "Zend Memory Manager", is_zend_mm(TSRMLS_C) ? "enabled" : "disabled" ); { diff --git a/ext/standard/tests/general_functions/phpinfo.phpt b/ext/standard/tests/general_functions/phpinfo.phpt index 1e2494ccb93fa..df6aef832e5b8 100644 --- a/ext/standard/tests/general_functions/phpinfo.phpt +++ b/ext/standard/tests/general_functions/phpinfo.phpt @@ -35,6 +35,7 @@ PHP Extension Build => API%s Debug Build => %s Thread Safety => %s Zend Memory Manager => %s +Zend Signal Handling => %s Zend Multibyte Support => %s IPv6 Support => %s DTrace Support => %s diff --git a/main/SAPI.c b/main/SAPI.c index 250b796562ee9..a0d58805fbcd3 100644 --- a/main/SAPI.c +++ b/main/SAPI.c @@ -75,6 +75,10 @@ SAPI_API sapi_module_struct sapi_module; SAPI_API void sapi_startup(sapi_module_struct *sf) { +#ifdef ZEND_SIGNALS + zend_signal_startup(); +#endif + sf->ini_entries = NULL; sapi_module = *sf; diff --git a/main/main.c b/main/main.c index 9a068dfbaef39..7f944239ad16b 100644 --- a/main/main.c +++ b/main/main.c @@ -1371,8 +1371,12 @@ void php_on_timeout(int seconds TSRMLS_DC) */ static void sigchld_handler(int apar) { + int errno_save = errno; + while (waitpid(-1, NULL, WNOHANG) > 0); signal(SIGCHLD, sigchld_handler); + + errno = errno_save; } /* }}} */ #endif @@ -1441,6 +1445,10 @@ int php_request_startup(TSRMLS_D) zend_activate(TSRMLS_C); sapi_activate(TSRMLS_C); +#ifdef ZEND_SIGNALS + zend_signal_activate(TSRMLS_C); +#endif + if (PG(max_input_time) == -1) { zend_set_timeout(EG(timeout_seconds), 1); } else { @@ -1564,6 +1572,10 @@ void php_request_shutdown_for_hook(void *dummy) php_free_shutdown_functions(TSRMLS_C); } + zend_try { + zend_unset_timeout(TSRMLS_C); + } zend_end_try(); + zend_try { int i; @@ -1590,9 +1602,11 @@ void php_request_shutdown_for_hook(void *dummy) zend_interned_strings_restore(TSRMLS_C); +#ifdef ZEND_SIGNALS zend_try { - zend_unset_timeout(TSRMLS_C); + zend_signal_deactivate(TSRMLS_C); } zend_end_try(); +#endif } /* }}} */ @@ -1647,13 +1661,18 @@ void php_request_shutdown(void *dummy) sapi_send_headers(TSRMLS_C); } zend_end_try(); - /* 5. Call all extensions RSHUTDOWN functions */ + /* 5. Reset max_execution_time (no longer executing php code after response sent) */ + zend_try { + zend_unset_timeout(TSRMLS_C); + } zend_end_try(); + + /* 6. Call all extensions RSHUTDOWN functions */ if (PG(modules_activated)) { zend_deactivate_modules(TSRMLS_C); php_free_shutdown_functions(TSRMLS_C); } - /* 6. Destroy super-globals */ + /* 7. Destroy super-globals */ zend_try { int i; @@ -1664,7 +1683,7 @@ void php_request_shutdown(void *dummy) } } zend_end_try(); - /* 6.5 free last error information */ + /* 7.5 free last error information */ if (PG(last_error_message)) { free(PG(last_error_message)); PG(last_error_message) = NULL; @@ -1889,8 +1908,10 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod zuf.write_function = php_output_wrapper; zuf.fopen_function = php_fopen_wrapper_for_zend; zuf.message_handler = php_message_handler_for_zend; +#ifndef ZEND_SIGNALS zuf.block_interruptions = sapi_module.block_interruptions; zuf.unblock_interruptions = sapi_module.unblock_interruptions; +#endif zuf.get_configuration_directive = php_get_configuration_directive_for_zend; zuf.ticks_function = php_run_ticks; zuf.on_timeout = php_on_timeout; From d66e7291cdb2b44846d8cc6020647f0efd715b4e Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Thu, 2 Jun 2011 21:38:54 +0000 Subject: [PATCH 0086/2394] Missing ifdef related to the previous patch --- Zend/zend_alloc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 48d6cb8e32da0..2d8d26a99fbc4 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -2123,8 +2123,9 @@ static void *_zend_mm_realloc_int(zend_mm_heap *heap, void *p, size_t size ZEND_ size_t true_size; size_t orig_size; void *ptr; +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); - +#endif if (UNEXPECTED(!p) || !ZEND_MM_VALID_PTR(p)) { return _zend_mm_alloc_int(heap, size ZEND_FILE_LINE_RELAY_CC ZEND_FILE_LINE_ORIG_RELAY_CC); } From 5ca0f699211a0adbc58bd2feb582fecada232bda Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 2 Jun 2011 22:54:14 +0000 Subject: [PATCH 0087/2394] - Fix ZTS build --- Zend/zend_hash.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index cadeaa4daecb9..ec08f89bed716 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -368,6 +368,9 @@ ZEND_API int _zend_hash_index_update_or_next_insert(HashTable *ht, ulong h, void { uint nIndex; Bucket *p; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif IS_CONSISTENT(ht); CHECK_INIT(ht); From 398c0b9dadbb4e110525567864e6e92168372bc7 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Fri, 3 Jun 2011 00:12:22 +0000 Subject: [PATCH 0088/2394] Added fabled hex2bin() function --- ext/standard/basic_functions.c | 5 +++ ext/standard/php_string.h | 1 + ext/standard/string.c | 62 ++++++++++++++++++++++++++++++++++ 3 files changed, 68 insertions(+) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 9d2e656a6a92e..b56f85caee5a2 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -2142,6 +2142,10 @@ ZEND_BEGIN_ARG_INFO(arginfo_bin2hex, 0) ZEND_ARG_INFO(0, data) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_hex2bin, 0) + ZEND_ARG_INFO(0, data) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_strspn, 0, 0, 2) ZEND_ARG_INFO(0, str) ZEND_ARG_INFO(0, mask) @@ -2682,6 +2686,7 @@ ZEND_END_ARG_INFO() const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(constant, arginfo_constant) PHP_FE(bin2hex, arginfo_bin2hex) + PHP_FE(hex2bin, arginfo_hex2bin) PHP_FE(sleep, arginfo_sleep) PHP_FE(usleep, arginfo_usleep) #if HAVE_NANOSLEEP diff --git a/ext/standard/php_string.h b/ext/standard/php_string.h index 71271cc6d92ca..23c703336abaa 100644 --- a/ext/standard/php_string.h +++ b/ext/standard/php_string.h @@ -78,6 +78,7 @@ PHP_FUNCTION(chunk_split); PHP_FUNCTION(parse_str); PHP_FUNCTION(str_getcsv); PHP_FUNCTION(bin2hex); +PHP_FUNCTION(hex2bin); PHP_FUNCTION(similar_text); PHP_FUNCTION(strip_tags); PHP_FUNCTION(str_repeat); diff --git a/ext/standard/string.c b/ext/standard/string.c index 7cd986c51e7a8..44c5cd3b0062c 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -146,6 +146,46 @@ static char *php_bin2hex(const unsigned char *old, const size_t oldlen, size_t * } /* }}} */ +/* {{{ php_hex2bin + */ +static char *php_hex2bin(const unsigned char *old, const size_t oldlen, size_t *newlen) +{ + size_t target_length = oldlen >> 1; + register unsigned char *str = (unsigned char *)safe_emalloc(target_length, sizeof(char), 1); + size_t i, j; + for (i = j = 0; i < target_length; i++) { + char c = old[j++]; + if (c >= '0' && c <= '9') { + str[i] = (c - '0') << 4; + } else if (c >= 'a' && c <= 'f') { + str[i] = (c - 'a' + 10) << 4; + } else if (c >= 'A' && c <= 'F') { + str[i] = (c - 'A' + 10) << 4; + } else { + efree(str); + return NULL; + } + c = old[j++]; + if (c >= '0' && c <= '9') { + str[i] |= c - '0'; + } else if (c >= 'a' && c <= 'f') { + str[i] |= c - 'a' + 10; + } else if (c >= 'A' && c <= 'F') { + str[i] |= c - 'A' + 10; + } else { + efree(str); + return NULL; + } + } + str[target_length] = '\0'; + + if (newlen) + *newlen = target_length; + + return (char *)str; +} +/* }}} */ + #ifdef HAVE_LOCALECONV /* {{{ localeconv_r * glibc's localeconv is not reentrant, so lets make it so ... sorta */ @@ -214,6 +254,28 @@ PHP_FUNCTION(bin2hex) } /* }}} */ +/* {{{ proto string hex2bin(string data) + Converts the hex representation of data to binary */ +PHP_FUNCTION(hex2bin) +{ + char *result, *data; + size_t newlen; + int datalen; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &data, &datalen) == FAILURE) { + return; + } + + result = php_hex2bin((unsigned char *)data, datalen, &newlen); + + if (!result) { + RETURN_FALSE; + } + + RETURN_STRINGL(result, newlen, 0); +} +/* }}} */ + static void php_spn_common_handler(INTERNAL_FUNCTION_PARAMETERS, int behavior) /* {{{ */ { char *s11, *s22; From 0aaedef71d0cf3bbce5d211ce2845faf92dc78be Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 3 Jun 2011 00:35:22 +0000 Subject: [PATCH 0089/2394] - Fix crash in pcntl --- ext/pcntl/php_signal.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/pcntl/php_signal.c b/ext/pcntl/php_signal.c index 298572875941f..2e5ce953168a4 100644 --- a/ext/pcntl/php_signal.c +++ b/ext/pcntl/php_signal.c @@ -18,6 +18,7 @@ /* $Id$ */ +#include "TSRM.h" #include "php_signal.h" /* php_signal using sigaction is derrived from Advanced Programing @@ -25,6 +26,9 @@ Sigfunc *php_signal4(int signo, Sigfunc *func, int restart, int mask_all) { struct sigaction act,oact; +#ifdef ZEND_SIGNALS + TSRMLS_FETCH(); +#endif act.sa_handler = func; if (mask_all) { sigfillset(&act.sa_mask); @@ -42,7 +46,7 @@ Sigfunc *php_signal4(int signo, Sigfunc *func, int restart, int mask_all) #endif } #ifdef ZEND_SIGNALS - if (zend_sigaction(signo, &act, &oact) < 0) + if (zend_sigaction(signo, &act, &oact TSRMLS_CC) < 0) #else if (sigaction(signo, &act, &oact) < 0) #endif From 974c3b49818ef161ef213599c72afccff9f40867 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Fri, 3 Jun 2011 00:42:07 +0000 Subject: [PATCH 0090/2394] Fix Bug #54918 - Crash when there is a failure to read the browscap file --- ext/standard/browscap.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ext/standard/browscap.c b/ext/standard/browscap.c index 282d9619aec9f..a2bcb131cd5e4 100644 --- a/ext/standard/browscap.c +++ b/ext/standard/browscap.c @@ -333,19 +333,19 @@ PHP_INI_MH(OnChangeBrowscap) PHP_MINIT_FUNCTION(browscap) /* {{{ */ { char *browscap = INI_STR("browscap"); - - if (browscap && browscap[0]) { - if (browscap_read_file(browscap, &global_bdata, 1 TSRMLS_CC) == FAILURE) { - return FAILURE; - } - } - + #ifdef ZTS ts_allocate_id(&browscap_globals_id, sizeof(browser_data), browscap_globals_ctor, NULL); #endif /* ctor call not really needed for non-ZTS */ + if (browscap && browscap[0]) { + if (browscap_read_file(browscap, &global_bdata, 1 TSRMLS_CC) == FAILURE) { + return FAILURE; + } + } + return SUCCESS; } /* }}} */ From d7c9c5af926dc74ba0780e38b942bacc949d7cf5 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Fri, 3 Jun 2011 01:09:32 +0000 Subject: [PATCH 0091/2394] scalar types cleanup --- Zend/zend.h | 4 - Zend/zend_API.c | 5 - Zend/zend_API.h | 2 +- Zend/zend_compile.c | 43 +- Zend/zend_language_parser.y | 8 +- Zend/zend_language_scanner.c | 2999 ++++++++++++++--------------- Zend/zend_language_scanner.l | 4 - Zend/zend_language_scanner_defs.h | 2 +- Zend/zend_variables.c | 1 - 9 files changed, 1480 insertions(+), 1588 deletions(-) diff --git a/Zend/zend.h b/Zend/zend.h index 7305b4b281303..8caa382326e9a 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -575,10 +575,6 @@ typedef int (*zend_write_func_t)(const char *str, uint str_length); #define IS_RESOURCE 7 #define IS_CONSTANT 8 #define IS_CONSTANT_ARRAY 9 -/* used for type-hinting only */ -#define IS_CLASS 10 -#define IS_SCALAR 11 -#define IS_NUMERIC 12 /* Ugly hack to support constants as static array indices */ #define IS_CONSTANT_TYPE_MASK 0x00f diff --git a/Zend/zend_API.c b/Zend/zend_API.c index d6933cf402fe2..ff7d8dfd66e53 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -205,10 +205,6 @@ ZEND_API char *zend_get_type_by_const(int type) /* {{{ */ switch(type) { case IS_BOOL: return "boolean"; - case IS_SCALAR: - return "scalar"; - case IS_NUMERIC: - return "numeric"; case IS_LONG: return "integer"; case IS_DOUBLE: @@ -216,7 +212,6 @@ ZEND_API char *zend_get_type_by_const(int type) /* {{{ */ case IS_STRING: return "string"; case IS_OBJECT: - case IS_CLASS: return "object"; case IS_RESOURCE: return "resource"; diff --git a/Zend/zend_API.h b/Zend/zend_API.h index 94d7b5fa1127d..f75ce5038b379 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -98,7 +98,7 @@ typedef struct _zend_fcall_info_cache { #define ZEND_ARG_INFO(pass_by_ref, name) { #name, sizeof(#name)-1, NULL, 0, 0, 0, pass_by_ref}, #define ZEND_ARG_PASS_INFO(pass_by_ref) { NULL, 0, NULL, 0, 0, 0, pass_by_ref}, -#define ZEND_ARG_OBJ_INFO(pass_by_ref, name, classname, allow_null) { #name, sizeof(#name)-1, #classname, sizeof(#classname)-1, IS_CLASS, allow_null, pass_by_ref}, +#define ZEND_ARG_OBJ_INFO(pass_by_ref, name, classname, allow_null) { #name, sizeof(#name)-1, #classname, sizeof(#classname)-1, IS_OBJECT, allow_null, pass_by_ref}, #define ZEND_ARG_ARRAY_INFO(pass_by_ref, name, allow_null) { #name, sizeof(#name)-1, NULL, 0, IS_ARRAY, allow_null, pass_by_ref}, #define ZEND_ARG_TYPE_INFO(pass_by_ref, name, type_hint, allow_null) { #name, sizeof(#name)-1, NULL, 0, type_hint, allow_null, pass_by_ref}, #define ZEND_BEGIN_ARG_INFO_EX(name, pass_rest_by_reference, return_reference, required_num_args) \ diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index a3f38d572c9c1..1cad70f77a205 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -1847,10 +1847,9 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con if (class_type->op_type != IS_UNUSED) { cur_arg_info->allow_null = 0; - cur_arg_info->type_hint = class_type->u.constant.type; - switch (class_type->u.constant.type) { - case IS_CLASS: + if (class_type->u.constant.type != IS_NULL) { + cur_arg_info->type_hint = IS_OBJECT; if (ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_type->u.constant), Z_STRLEN(class_type->u.constant))) { zend_resolve_class_name(class_type, &opline->extended_value, 1 TSRMLS_CC); } @@ -1864,9 +1863,8 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con zend_error(E_COMPILE_ERROR, "Default value for parameters with a class type hint can only be NULL"); } } - break; - - case IS_ARRAY: + } else { + cur_arg_info->type_hint = IS_ARRAY; if (op == ZEND_RECV_INIT) { if (Z_TYPE(initialization->u.constant) == IS_NULL || (Z_TYPE(initialization->u.constant) == IS_CONSTANT && !strcasecmp(Z_STRVAL(initialization->u.constant), "NULL"))) { cur_arg_info->allow_null = 1; @@ -1874,39 +1872,6 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con zend_error(E_COMPILE_ERROR, "Default value for parameters with array type hint can only be an array or NULL"); } } - break; - - /* scalar type hinting */ - case IS_SCALAR: - if (op == ZEND_RECV_INIT && Z_TYPE(initialization->u.constant) != IS_ARRAY && Z_TYPE(initialization->u.constant) != IS_CONSTANT_ARRAY) { - break; - } - /* fall through */ - - /* scalar type hinting */ - case IS_NUMERIC: - if (op == ZEND_RECV_INIT && (Z_TYPE(initialization->u.constant) == IS_LONG || Z_TYPE(initialization->u.constant) == IS_DOUBLE)) { - break; - } - /* fall through */ - - case IS_BOOL: - case IS_STRING: - case IS_LONG: - case IS_DOUBLE: - case IS_RESOURCE: - case IS_OBJECT: - if (op == ZEND_RECV_INIT) { - if (Z_TYPE(initialization->u.constant) != class_type->u.constant.type && Z_TYPE(initialization->u.constant) != IS_NULL && (Z_TYPE(initialization->u.constant) & IS_CONSTANT_TYPE_MASK) != IS_CONSTANT) { - zend_error(E_COMPILE_ERROR, "Default value for parameters with %s type hint can only be %s or NULL", zend_get_type_by_const(class_type->u.constant.type), zend_get_type_by_const(class_type->u.constant.type)); - } else if (Z_TYPE(initialization->u.constant) == IS_NULL) { - cur_arg_info->allow_null = 1; - } - } - break; - - default: - zend_error(E_COMPILE_ERROR, "Unknown type hint"); } } } diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index a42b153e67b5f..e0a956bc23e61 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -69,7 +69,7 @@ %left '*' '/' '%' %right '!' %nonassoc T_INSTANCEOF -%right '~' T_INC T_DEC T_INT_CAST T_NUMERIC_CAST T_SCALAR_CAST T_DOUBLE_CAST T_STRING_CAST T_ARRAY_CAST T_OBJECT_CAST T_BOOL_CAST T_UNSET_CAST '@' +%right '~' T_INC T_DEC T_INT_CAST T_DOUBLE_CAST T_STRING_CAST T_ARRAY_CAST T_OBJECT_CAST T_BOOL_CAST T_UNSET_CAST '@' %right '[' %nonassoc T_NEW T_CLONE %token T_EXIT @@ -466,8 +466,8 @@ non_empty_parameter_list: optional_class_type: /* empty */ { $$.op_type = IS_UNUSED; } - | T_ARRAY { $$ = $1; $$.op_type = IS_CONST; Z_TYPE($$.u.constant)=IS_ARRAY; } - | fully_qualified_class_name { $$ = $1; $$.op_type = IS_CONST; Z_TYPE($$.u.constant)=IS_CLASS; } + | T_ARRAY { $$.op_type = IS_CONST; Z_TYPE($$.u.constant)=IS_NULL; } + | fully_qualified_class_name { $$ = $1; } ; @@ -700,8 +700,6 @@ expr_without_variable: | T_ARRAY_CAST expr { zend_do_cast(&$$, &$2, IS_ARRAY TSRMLS_CC); } | T_OBJECT_CAST expr { zend_do_cast(&$$, &$2, IS_OBJECT TSRMLS_CC); } | T_BOOL_CAST expr { zend_do_cast(&$$, &$2, IS_BOOL TSRMLS_CC); } - | T_SCALAR_CAST expr { zend_do_cast(&$$, &$2, IS_SCALAR TSRMLS_CC); } - | T_NUMERIC_CAST expr { zend_do_cast(&$$, &$2, IS_NUMERIC TSRMLS_CC); } | T_UNSET_CAST expr { zend_do_cast(&$$, &$2, IS_NULL TSRMLS_CC); } | T_EXIT exit_expr { zend_do_exit(&$$, &$2 TSRMLS_CC); } | '@' { zend_do_begin_silence(&$1 TSRMLS_CC); } expr { zend_do_end_silence(&$1 TSRMLS_CC); $$ = $3; } diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 5db41d7eede59..73c5f8207f4a0 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun May 8 16:20:00 2011 */ +/* Generated by re2c 0.13.5 on Thu Jun 2 18:02:57 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1081,7 +1081,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1718 "Zend/zend_language_scanner.l" +#line 1710 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1159,7 +1159,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1706 "Zend/zend_language_scanner.l" +#line 1698 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1178,7 +1178,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1683 "Zend/zend_language_scanner.l" +#line 1675 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1376,7 +1376,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1639 "Zend/zend_language_scanner.l" +#line 1635 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1420,7 +1420,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1657 "Zend/zend_language_scanner.l" +#line 1653 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1438,19 +1438,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1670 "Zend/zend_language_scanner.l" +#line 1666 "Zend/zend_language_scanner.l" { - if (CG(short_tags)) { - zendlval->value.str.val = yytext; /* no copying - intentional */ - zendlval->value.str.len = yyleng; - zendlval->type = IS_STRING; - BEGIN(ST_IN_SCRIPTING); - return T_OPEN_TAG_WITH_ECHO; - } else { - goto inline_char_handler; - } + zendlval->value.str.val = yytext; /* no copying - intentional */ + zendlval->value.str.len = yyleng; + zendlval->type = IS_STRING; + BEGIN(ST_IN_SCRIPTING); + return T_OPEN_TAG_WITH_ECHO; } -#line 1454 "Zend/zend_language_scanner.c" +#line 1450 "Zend/zend_language_scanner.c" yy47: YYDEBUG(47, *YYCURSOR); yych = *++YYCURSOR; @@ -1477,7 +1473,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1696 "Zend/zend_language_scanner.l" +#line 1688 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1486,7 +1482,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_IN_SCRIPTING); return T_OPEN_TAG; } -#line 1490 "Zend/zend_language_scanner.c" +#line 1486 "Zend/zend_language_scanner.c" yy52: YYDEBUG(52, *YYCURSOR); ++YYCURSOR; @@ -1557,7 +1553,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2169 "Zend/zend_language_scanner.l" +#line 2161 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1598,7 +1594,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_scan_escape_string(zendlval, yytext, yyleng, '`' TSRMLS_CC); return T_ENCAPSED_AND_WHITESPACE; } -#line 1602 "Zend/zend_language_scanner.c" +#line 1598 "Zend/zend_language_scanner.c" yy57: YYDEBUG(57, *YYCURSOR); yych = *++YYCURSOR; @@ -1609,12 +1605,12 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2113 "Zend/zend_language_scanner.l" +#line 2105 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; } -#line 1618 "Zend/zend_language_scanner.c" +#line 1614 "Zend/zend_language_scanner.c" yy60: YYDEBUG(60, *YYCURSOR); yych = *++YYCURSOR; @@ -1624,14 +1620,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2100 "Zend/zend_language_scanner.l" +#line 2092 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); yyless(1); return T_CURLY_OPEN; } -#line 1635 "Zend/zend_language_scanner.c" +#line 1631 "Zend/zend_language_scanner.c" yy63: YYDEBUG(63, *YYCURSOR); yyaccept = 0; @@ -1647,24 +1643,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1800 "Zend/zend_language_scanner.l" +#line 1792 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1657 "Zend/zend_language_scanner.c" +#line 1653 "Zend/zend_language_scanner.c" yy66: YYDEBUG(66, *YYCURSOR); ++YYCURSOR; YYDEBUG(67, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1432 "Zend/zend_language_scanner.l" +#line 1428 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; } -#line 1668 "Zend/zend_language_scanner.c" +#line 1664 "Zend/zend_language_scanner.c" yy68: YYDEBUG(68, *YYCURSOR); yych = *++YYCURSOR; @@ -1678,7 +1674,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1784 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1686,7 +1682,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1690 "Zend/zend_language_scanner.c" +#line 1686 "Zend/zend_language_scanner.c" yy72: YYDEBUG(72, *YYCURSOR); yych = *++YYCURSOR; @@ -1704,7 +1700,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1782 "Zend/zend_language_scanner.l" +#line 1774 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1712,7 +1708,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1716 "Zend/zend_language_scanner.c" +#line 1712 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_DOUBLE_QUOTES: @@ -1780,7 +1776,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2119 "Zend/zend_language_scanner.l" +#line 2111 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1829,7 +1825,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_scan_escape_string(zendlval, yytext, yyleng, '"' TSRMLS_CC); return T_ENCAPSED_AND_WHITESPACE; } -#line 1833 "Zend/zend_language_scanner.c" +#line 1829 "Zend/zend_language_scanner.c" yy79: YYDEBUG(79, *YYCURSOR); yych = *++YYCURSOR; @@ -1840,12 +1836,12 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2108 "Zend/zend_language_scanner.l" +#line 2100 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; } -#line 1849 "Zend/zend_language_scanner.c" +#line 1845 "Zend/zend_language_scanner.c" yy82: YYDEBUG(82, *YYCURSOR); yych = *++YYCURSOR; @@ -1855,14 +1851,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2100 "Zend/zend_language_scanner.l" +#line 2092 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); yyless(1); return T_CURLY_OPEN; } -#line 1866 "Zend/zend_language_scanner.c" +#line 1862 "Zend/zend_language_scanner.c" yy85: YYDEBUG(85, *YYCURSOR); yyaccept = 0; @@ -1878,24 +1874,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1800 "Zend/zend_language_scanner.l" +#line 1792 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1888 "Zend/zend_language_scanner.c" +#line 1884 "Zend/zend_language_scanner.c" yy88: YYDEBUG(88, *YYCURSOR); ++YYCURSOR; YYDEBUG(89, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1432 "Zend/zend_language_scanner.l" +#line 1428 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; } -#line 1899 "Zend/zend_language_scanner.c" +#line 1895 "Zend/zend_language_scanner.c" yy90: YYDEBUG(90, *YYCURSOR); yych = *++YYCURSOR; @@ -1909,7 +1905,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1784 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1917,7 +1913,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1921 "Zend/zend_language_scanner.c" +#line 1917 "Zend/zend_language_scanner.c" yy94: YYDEBUG(94, *YYCURSOR); yych = *++YYCURSOR; @@ -1935,7 +1931,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1782 "Zend/zend_language_scanner.l" +#line 1774 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1943,7 +1939,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1947 "Zend/zend_language_scanner.c" +#line 1943 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_END_HEREDOC: @@ -1954,7 +1950,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2087 "Zend/zend_language_scanner.l" +#line 2079 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -1966,7 +1962,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_IN_SCRIPTING); return T_END_HEREDOC; } -#line 1970 "Zend/zend_language_scanner.c" +#line 1966 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_HEREDOC: { @@ -2028,7 +2024,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2211 "Zend/zend_language_scanner.l" +#line 2203 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2099,7 +2095,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_scan_escape_string(zendlval, yytext, yyleng - newline, 0 TSRMLS_CC); return T_ENCAPSED_AND_WHITESPACE; } -#line 2103 "Zend/zend_language_scanner.c" +#line 2099 "Zend/zend_language_scanner.c" yy105: YYDEBUG(105, *YYCURSOR); yych = *++YYCURSOR; @@ -2114,14 +2110,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2100 "Zend/zend_language_scanner.l" +#line 2092 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); yyless(1); return T_CURLY_OPEN; } -#line 2125 "Zend/zend_language_scanner.c" +#line 2121 "Zend/zend_language_scanner.c" yy109: YYDEBUG(109, *YYCURSOR); yyaccept = 0; @@ -2137,24 +2133,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1800 "Zend/zend_language_scanner.l" +#line 1792 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 2147 "Zend/zend_language_scanner.c" +#line 2143 "Zend/zend_language_scanner.c" yy112: YYDEBUG(112, *YYCURSOR); ++YYCURSOR; YYDEBUG(113, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1432 "Zend/zend_language_scanner.l" +#line 1428 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; } -#line 2158 "Zend/zend_language_scanner.c" +#line 2154 "Zend/zend_language_scanner.c" yy114: YYDEBUG(114, *YYCURSOR); yych = *++YYCURSOR; @@ -2168,7 +2164,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1784 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2176,7 +2172,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 2180 "Zend/zend_language_scanner.c" +#line 2176 "Zend/zend_language_scanner.c" yy118: YYDEBUG(118, *YYCURSOR); yych = *++YYCURSOR; @@ -2194,7 +2190,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1782 "Zend/zend_language_scanner.l" +#line 1774 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2202,7 +2198,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 2206 "Zend/zend_language_scanner.c" +#line 2202 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_IN_SCRIPTING: @@ -2367,48 +2363,48 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(-1, yych); switch ((yych = *YYCURSOR)) { case 'C': - case 'c': goto yy715; + case 'c': goto yy707; case 'L': - case 'l': goto yy716; + case 'l': goto yy708; case 'M': - case 'm': goto yy717; + case 'm': goto yy709; case 'N': - case 'n': goto yy718; + case 'n': goto yy710; case 'V': - case 'v': goto yy719; + case 'v': goto yy711; case 'X': - case 'x': goto yy720; + case 'x': goto yy712; default: goto yy186; } yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1823 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 2393 "Zend/zend_language_scanner.c" +#line 2389 "Zend/zend_language_scanner.c" yy125: YYDEBUG(125, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'H') { - if (yych == 'E') goto yy697; + if (yych == 'E') goto yy689; goto yy186; } else { - if (yych <= 'I') goto yy698; + if (yych <= 'I') goto yy690; if (yych <= 'N') goto yy186; - goto yy699; + goto yy691; } } else { if (yych <= 'h') { - if (yych == 'e') goto yy697; + if (yych == 'e') goto yy689; goto yy186; } else { - if (yych <= 'i') goto yy698; - if (yych == 'o') goto yy699; + if (yych <= 'i') goto yy690; + if (yych == 'o') goto yy691; goto yy186; } } @@ -2417,20 +2413,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'U') { if (yych <= 'N') { - if (yych == 'I') goto yy676; + if (yych == 'I') goto yy668; goto yy186; } else { - if (yych <= 'O') goto yy677; + if (yych <= 'O') goto yy669; if (yych <= 'T') goto yy186; - goto yy678; + goto yy670; } } else { if (yych <= 'n') { - if (yych == 'i') goto yy676; + if (yych == 'i') goto yy668; goto yy186; } else { - if (yych <= 'o') goto yy677; - if (yych == 'u') goto yy678; + if (yych <= 'o') goto yy669; + if (yych == 'u') goto yy670; goto yy186; } } @@ -2439,42 +2435,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'K') { - if (yych == 'A') goto yy648; + if (yych == 'A') goto yy640; goto yy186; } else { - if (yych <= 'L') goto yy649; + if (yych <= 'L') goto yy641; if (yych <= 'N') goto yy186; - goto yy650; + goto yy642; } } else { if (yych <= 'k') { - if (yych == 'a') goto yy648; + if (yych == 'a') goto yy640; goto yy186; } else { - if (yych <= 'l') goto yy649; - if (yych == 'o') goto yy650; + if (yych <= 'l') goto yy641; + if (yych == 'o') goto yy642; goto yy186; } } yy128: YYDEBUG(128, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy630; - if (yych == 'e') goto yy630; + if (yych == 'E') goto yy622; + if (yych == 'e') goto yy622; goto yy186; yy129: YYDEBUG(129, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'R') { - if (yych == 'H') goto yy618; + if (yych == 'H') goto yy610; if (yych <= 'Q') goto yy186; - goto yy619; + goto yy611; } else { if (yych <= 'h') { if (yych <= 'g') goto yy186; - goto yy618; + goto yy610; } else { - if (yych == 'r') goto yy619; + if (yych == 'r') goto yy611; goto yy186; } } @@ -2483,53 +2479,53 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'S') { if (yych <= 'L') { - if (yych == 'F') goto yy565; + if (yych == 'F') goto yy557; goto yy186; } else { - if (yych <= 'M') goto yy567; - if (yych <= 'N') goto yy568; + if (yych <= 'M') goto yy559; + if (yych <= 'N') goto yy560; if (yych <= 'R') goto yy186; - goto yy569; + goto yy561; } } else { if (yych <= 'm') { - if (yych == 'f') goto yy565; + if (yych == 'f') goto yy557; if (yych <= 'l') goto yy186; - goto yy567; + goto yy559; } else { - if (yych <= 'n') goto yy568; - if (yych == 's') goto yy569; + if (yych <= 'n') goto yy560; + if (yych == 's') goto yy561; goto yy186; } } yy131: YYDEBUG(131, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy560; - if (yych == 'h') goto yy560; + if (yych == 'H') goto yy552; + if (yych == 'h') goto yy552; goto yy186; yy132: YYDEBUG(132, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'S') { if (yych <= 'M') { - if (yych == 'B') goto yy542; + if (yych == 'B') goto yy534; goto yy186; } else { - if (yych <= 'N') goto yy543; + if (yych <= 'N') goto yy535; if (yych <= 'Q') goto yy186; - if (yych <= 'R') goto yy544; - goto yy545; + if (yych <= 'R') goto yy536; + goto yy537; } } else { if (yych <= 'n') { - if (yych == 'b') goto yy542; + if (yych == 'b') goto yy534; if (yych <= 'm') goto yy186; - goto yy543; + goto yy535; } else { if (yych <= 'q') goto yy186; - if (yych <= 'r') goto yy544; - if (yych <= 's') goto yy545; + if (yych <= 'r') goto yy536; + if (yych <= 's') goto yy537; goto yy186; } } @@ -2537,15 +2533,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(133, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'W') { - if (yych == 'T') goto yy530; + if (yych == 'T') goto yy522; if (yych <= 'V') goto yy186; - goto yy531; + goto yy523; } else { if (yych <= 't') { if (yych <= 's') goto yy186; - goto yy530; + goto yy522; } else { - if (yych == 'w') goto yy531; + if (yych == 'w') goto yy523; goto yy186; } } @@ -2556,18 +2552,18 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (yych <= ';') { if (yych <= '"') { if (yych <= '!') goto yy186; - goto yy522; + goto yy514; } else { - if (yych == '\'') goto yy523; + if (yych == '\'') goto yy515; goto yy186; } } else { if (yych <= 'R') { - if (yych <= '<') goto yy521; + if (yych <= '<') goto yy513; if (yych <= 'Q') goto yy186; - goto yy524; + goto yy516; } else { - if (yych == 'r') goto yy524; + if (yych == 'r') goto yy516; goto yy186; } } @@ -2575,15 +2571,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(135, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'L') goto yy511; + if (yych == 'L') goto yy503; if (yych <= 'N') goto yy186; - goto yy512; + goto yy504; } else { if (yych <= 'l') { if (yych <= 'k') goto yy186; - goto yy511; + goto yy503; } else { - if (yych == 'o') goto yy512; + if (yych == 'o') goto yy504; goto yy186; } } @@ -2591,15 +2587,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(136, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'U') { - if (yych == 'R') goto yy487; + if (yych == 'R') goto yy479; if (yych <= 'T') goto yy186; - goto yy488; + goto yy480; } else { if (yych <= 'r') { if (yych <= 'q') goto yy186; - goto yy487; + goto yy479; } else { - if (yych == 'u') goto yy488; + if (yych == 'u') goto yy480; goto yy186; } } @@ -2607,24 +2603,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(137, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '<') { - if (yych == '-') goto yy483; + if (yych == '-') goto yy475; } else { - if (yych <= '=') goto yy481; - if (yych <= '>') goto yy485; + if (yych <= '=') goto yy473; + if (yych <= '>') goto yy477; } yy138: YYDEBUG(138, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1421 "Zend/zend_language_scanner.l" +#line 1417 "Zend/zend_language_scanner.l" { return yytext[0]; } -#line 2623 "Zend/zend_language_scanner.c" +#line 2619 "Zend/zend_language_scanner.c" yy139: YYDEBUG(139, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy480; + goto yy472; yy140: YYDEBUG(140, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); @@ -2636,11 +2632,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 2640 "Zend/zend_language_scanner.c" +#line 2636 "Zend/zend_language_scanner.c" yy141: YYDEBUG(141, *YYCURSOR); yych = *++YYCURSOR; - if (yych == ':') goto yy477; + if (yych == ':') goto yy469; goto yy138; yy142: YYDEBUG(142, *YYCURSOR); @@ -2651,28 +2647,28 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_NS_SEPARATOR; } -#line 2655 "Zend/zend_language_scanner.c" +#line 2651 "Zend/zend_language_scanner.c" yy144: YYDEBUG(144, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'E') { - if (yych == 'A') goto yy465; + if (yych == 'A') goto yy457; if (yych <= 'D') goto yy186; - goto yy466; + goto yy458; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy465; + goto yy457; } else { - if (yych == 'e') goto yy466; + if (yych == 'e') goto yy458; goto yy186; } } yy145: YYDEBUG(145, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy462; - if (yych == 'a') goto yy462; + if (yych == 'A') goto yy454; + if (yych == 'a') goto yy454; goto yy186; yy146: YYDEBUG(146, *YYCURSOR); @@ -2879,18 +2875,18 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(168, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1426 "Zend/zend_language_scanner.l" +#line 1422 "Zend/zend_language_scanner.l" { yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return '{'; } -#line 2888 "Zend/zend_language_scanner.c" +#line 2884 "Zend/zend_language_scanner.c" yy169: YYDEBUG(169, *YYCURSOR); ++YYCURSOR; YYDEBUG(170, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1438 "Zend/zend_language_scanner.l" +#line 1434 "Zend/zend_language_scanner.l" { RESET_DOC_COMMENT(); if (!zend_stack_is_empty(&SCNG(state_stack))) { @@ -2898,7 +2894,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return '}'; } -#line 2902 "Zend/zend_language_scanner.c" +#line 2898 "Zend/zend_language_scanner.c" yy171: YYDEBUG(171, *YYCURSOR); yyaccept = 2; @@ -2921,7 +2917,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy172: YYDEBUG(172, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1464 "Zend/zend_language_scanner.l" +#line 1460 "Zend/zend_language_scanner.l" { if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */ zendlval->value.lval = strtol(yytext, NULL, 0); @@ -2942,7 +2938,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_LONG; return T_LNUMBER; } -#line 2946 "Zend/zend_language_scanner.c" +#line 2942 "Zend/zend_language_scanner.c" yy173: YYDEBUG(173, *YYCURSOR); yyaccept = 2; @@ -2970,7 +2966,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1830 "Zend/zend_language_scanner.l" +#line 1822 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3004,14 +3000,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_COMMENT; } -#line 3008 "Zend/zend_language_scanner.c" +#line 3004 "Zend/zend_language_scanner.c" yy177: YYDEBUG(177, *YYCURSOR); ++YYCURSOR; yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1921 "Zend/zend_language_scanner.l" +#line 1913 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3079,14 +3075,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_CONSTANT_ENCAPSED_STRING; } -#line 3083 "Zend/zend_language_scanner.c" +#line 3079 "Zend/zend_language_scanner.c" yy179: YYDEBUG(179, *YYCURSOR); ++YYCURSOR; yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1990 "Zend/zend_language_scanner.l" +#line 1982 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3127,24 +3123,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_DOUBLE_QUOTES); return '"'; } -#line 3131 "Zend/zend_language_scanner.c" +#line 3127 "Zend/zend_language_scanner.c" yy181: YYDEBUG(181, *YYCURSOR); ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2081 "Zend/zend_language_scanner.l" +#line 2073 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; } -#line 3142 "Zend/zend_language_scanner.c" +#line 3138 "Zend/zend_language_scanner.c" yy183: YYDEBUG(183, *YYCURSOR); ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2339 "Zend/zend_language_scanner.l" +#line 2331 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3153,7 +3149,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 3157 "Zend/zend_language_scanner.c" +#line 3153 "Zend/zend_language_scanner.c" yy185: YYDEBUG(185, *YYCURSOR); ++YYCURSOR; @@ -3180,13 +3176,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy189: YYDEBUG(189, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1525 "Zend/zend_language_scanner.l" +#line 1521 "Zend/zend_language_scanner.l" { zendlval->value.dval = zend_strtod(yytext, NULL); zendlval->type = IS_DOUBLE; return T_DNUMBER; } -#line 3190 "Zend/zend_language_scanner.c" +#line 3186 "Zend/zend_language_scanner.c" yy190: YYDEBUG(190, *YYCURSOR); yyaccept = 2; @@ -3271,7 +3267,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(200, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1485 "Zend/zend_language_scanner.l" +#line 1481 "Zend/zend_language_scanner.l" { char *hex = yytext + 2; /* Skip "0x" */ int len = yyleng - 2; @@ -3292,7 +3288,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_DNUMBER; } } -#line 3296 "Zend/zend_language_scanner.c" +#line 3292 "Zend/zend_language_scanner.c" yy201: YYDEBUG(201, *YYCURSOR); ++YYCURSOR; @@ -3301,7 +3297,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy202: YYDEBUG(202, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1898 "Zend/zend_language_scanner.l" +#line 1890 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3309,7 +3305,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(INITIAL); return T_CLOSE_TAG; /* implicit ';' at php-end tag */ } -#line 3313 "Zend/zend_language_scanner.c" +#line 3309 "Zend/zend_language_scanner.c" yy203: YYDEBUG(203, *YYCURSOR); yych = *++YYCURSOR; @@ -3343,13 +3339,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy207: YYDEBUG(207, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1800 "Zend/zend_language_scanner.l" +#line 1792 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 3353 "Zend/zend_language_scanner.c" +#line 3349 "Zend/zend_language_scanner.c" yy208: YYDEBUG(208, *YYCURSOR); yych = *++YYCURSOR; @@ -3363,11 +3359,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(210, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1409 "Zend/zend_language_scanner.l" +#line 1405 "Zend/zend_language_scanner.l" { return T_LOGICAL_XOR; } -#line 3371 "Zend/zend_language_scanner.c" +#line 3367 "Zend/zend_language_scanner.c" yy211: YYDEBUG(211, *YYCURSOR); ++YYCURSOR; @@ -3376,61 +3372,61 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(212, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1401 "Zend/zend_language_scanner.l" +#line 1397 "Zend/zend_language_scanner.l" { return T_LOGICAL_OR; } -#line 3384 "Zend/zend_language_scanner.c" +#line 3380 "Zend/zend_language_scanner.c" yy213: YYDEBUG(213, *YYCURSOR); ++YYCURSOR; YYDEBUG(214, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1389 "Zend/zend_language_scanner.l" +#line 1385 "Zend/zend_language_scanner.l" { return T_XOR_EQUAL; } -#line 3394 "Zend/zend_language_scanner.c" +#line 3390 "Zend/zend_language_scanner.c" yy215: YYDEBUG(215, *YYCURSOR); ++YYCURSOR; YYDEBUG(216, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1393 "Zend/zend_language_scanner.l" +#line 1389 "Zend/zend_language_scanner.l" { return T_BOOLEAN_OR; } -#line 3404 "Zend/zend_language_scanner.c" +#line 3400 "Zend/zend_language_scanner.c" yy217: YYDEBUG(217, *YYCURSOR); ++YYCURSOR; YYDEBUG(218, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1385 "Zend/zend_language_scanner.l" +#line 1381 "Zend/zend_language_scanner.l" { return T_OR_EQUAL; } -#line 3414 "Zend/zend_language_scanner.c" +#line 3410 "Zend/zend_language_scanner.c" yy219: YYDEBUG(219, *YYCURSOR); ++YYCURSOR; YYDEBUG(220, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1397 "Zend/zend_language_scanner.l" +#line 1393 "Zend/zend_language_scanner.l" { return T_BOOLEAN_AND; } -#line 3424 "Zend/zend_language_scanner.c" +#line 3420 "Zend/zend_language_scanner.c" yy221: YYDEBUG(221, *YYCURSOR); ++YYCURSOR; YYDEBUG(222, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1381 "Zend/zend_language_scanner.l" +#line 1377 "Zend/zend_language_scanner.l" { return T_AND_EQUAL; } -#line 3434 "Zend/zend_language_scanner.c" +#line 3430 "Zend/zend_language_scanner.c" yy223: YYDEBUG(223, *YYCURSOR); ++YYCURSOR; @@ -3439,7 +3435,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy224: YYDEBUG(224, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1907 "Zend/zend_language_scanner.l" +#line 1899 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3452,17 +3448,17 @@ int lex_scan(zval *zendlval TSRMLS_DC) return yytext[0]; } } -#line 3456 "Zend/zend_language_scanner.c" +#line 3452 "Zend/zend_language_scanner.c" yy225: YYDEBUG(225, *YYCURSOR); ++YYCURSOR; YYDEBUG(226, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1369 "Zend/zend_language_scanner.l" +#line 1365 "Zend/zend_language_scanner.l" { return T_MOD_EQUAL; } -#line 3466 "Zend/zend_language_scanner.c" +#line 3462 "Zend/zend_language_scanner.c" yy227: YYDEBUG(227, *YYCURSOR); yych = *++YYCURSOR; @@ -3493,11 +3489,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(232, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1365 "Zend/zend_language_scanner.l" +#line 1361 "Zend/zend_language_scanner.l" { return T_CONCAT_EQUAL; } -#line 3501 "Zend/zend_language_scanner.c" +#line 3497 "Zend/zend_language_scanner.c" yy233: YYDEBUG(233, *YYCURSOR); yyaccept = 4; @@ -3506,7 +3502,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy234: YYDEBUG(234, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1864 "Zend/zend_language_scanner.l" +#line 1856 "Zend/zend_language_scanner.l" { int doc_com; @@ -3540,7 +3536,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_COMMENT; } -#line 3544 "Zend/zend_language_scanner.c" +#line 3540 "Zend/zend_language_scanner.c" yy235: YYDEBUG(235, *YYCURSOR); yych = *++YYCURSOR; @@ -3550,11 +3546,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(237, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1361 "Zend/zend_language_scanner.l" +#line 1357 "Zend/zend_language_scanner.l" { return T_DIV_EQUAL; } -#line 3558 "Zend/zend_language_scanner.c" +#line 3554 "Zend/zend_language_scanner.c" yy238: YYDEBUG(238, *YYCURSOR); yych = *++YYCURSOR; @@ -3577,42 +3573,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(242, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1357 "Zend/zend_language_scanner.l" +#line 1353 "Zend/zend_language_scanner.l" { return T_MUL_EQUAL; } -#line 3585 "Zend/zend_language_scanner.c" +#line 3581 "Zend/zend_language_scanner.c" yy243: YYDEBUG(243, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) == '=') goto yy247; YYDEBUG(244, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1417 "Zend/zend_language_scanner.l" +#line 1413 "Zend/zend_language_scanner.l" { return T_SR; } -#line 3596 "Zend/zend_language_scanner.c" +#line 3592 "Zend/zend_language_scanner.c" yy245: YYDEBUG(245, *YYCURSOR); ++YYCURSOR; YYDEBUG(246, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1345 "Zend/zend_language_scanner.l" +#line 1341 "Zend/zend_language_scanner.l" { return T_IS_GREATER_OR_EQUAL; } -#line 3606 "Zend/zend_language_scanner.c" +#line 3602 "Zend/zend_language_scanner.c" yy247: YYDEBUG(247, *YYCURSOR); ++YYCURSOR; YYDEBUG(248, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1377 "Zend/zend_language_scanner.l" +#line 1373 "Zend/zend_language_scanner.l" { return T_SR_EQUAL; } -#line 3616 "Zend/zend_language_scanner.c" +#line 3612 "Zend/zend_language_scanner.c" yy249: YYDEBUG(249, *YYCURSOR); yyaccept = 5; @@ -3623,11 +3619,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy250: YYDEBUG(250, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1413 "Zend/zend_language_scanner.l" +#line 1409 "Zend/zend_language_scanner.l" { return T_SL; } -#line 3631 "Zend/zend_language_scanner.c" +#line 3627 "Zend/zend_language_scanner.c" yy251: YYDEBUG(251, *YYCURSOR); yych = *++YYCURSOR; @@ -3639,22 +3635,22 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(253, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1341 "Zend/zend_language_scanner.l" +#line 1337 "Zend/zend_language_scanner.l" { return T_IS_SMALLER_OR_EQUAL; } -#line 3647 "Zend/zend_language_scanner.c" +#line 3643 "Zend/zend_language_scanner.c" yy254: YYDEBUG(254, *YYCURSOR); ++YYCURSOR; yy255: YYDEBUG(255, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1337 "Zend/zend_language_scanner.l" +#line 1333 "Zend/zend_language_scanner.l" { return T_IS_NOT_EQUAL; } -#line 3658 "Zend/zend_language_scanner.c" +#line 3654 "Zend/zend_language_scanner.c" yy256: YYDEBUG(256, *YYCURSOR); yych = *++YYCURSOR; @@ -3705,11 +3701,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(264, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1373 "Zend/zend_language_scanner.l" +#line 1369 "Zend/zend_language_scanner.l" { return T_SL_EQUAL; } -#line 3713 "Zend/zend_language_scanner.c" +#line 3709 "Zend/zend_language_scanner.c" yy265: YYDEBUG(265, *YYCURSOR); ++YYCURSOR; @@ -3814,7 +3810,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy275: YYDEBUG(275, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2032 "Zend/zend_language_scanner.l" +#line 2024 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -3862,7 +3858,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_START_HEREDOC; } -#line 3866 "Zend/zend_language_scanner.c" +#line 3862 "Zend/zend_language_scanner.c" yy276: YYDEBUG(276, *YYCURSOR); yych = *++YYCURSOR; @@ -3902,31 +3898,31 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(281, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1329 "Zend/zend_language_scanner.l" +#line 1325 "Zend/zend_language_scanner.l" { return T_IS_NOT_IDENTICAL; } -#line 3910 "Zend/zend_language_scanner.c" +#line 3906 "Zend/zend_language_scanner.c" yy282: YYDEBUG(282, *YYCURSOR); ++YYCURSOR; YYDEBUG(283, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1349 "Zend/zend_language_scanner.l" +#line 1345 "Zend/zend_language_scanner.l" { return T_PLUS_EQUAL; } -#line 3920 "Zend/zend_language_scanner.c" +#line 3916 "Zend/zend_language_scanner.c" yy284: YYDEBUG(284, *YYCURSOR); ++YYCURSOR; YYDEBUG(285, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1317 "Zend/zend_language_scanner.l" +#line 1313 "Zend/zend_language_scanner.l" { return T_INC; } -#line 3930 "Zend/zend_language_scanner.c" +#line 3926 "Zend/zend_language_scanner.c" yy286: YYDEBUG(286, *YYCURSOR); yych = *++YYCURSOR; @@ -3945,42 +3941,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(289, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1309 "Zend/zend_language_scanner.l" +#line 1305 "Zend/zend_language_scanner.l" { return T_LIST; } -#line 3953 "Zend/zend_language_scanner.c" +#line 3949 "Zend/zend_language_scanner.c" yy290: YYDEBUG(290, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) == '=') goto yy294; YYDEBUG(291, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1333 "Zend/zend_language_scanner.l" +#line 1329 "Zend/zend_language_scanner.l" { return T_IS_EQUAL; } -#line 3964 "Zend/zend_language_scanner.c" +#line 3960 "Zend/zend_language_scanner.c" yy292: YYDEBUG(292, *YYCURSOR); ++YYCURSOR; YYDEBUG(293, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1305 "Zend/zend_language_scanner.l" +#line 1301 "Zend/zend_language_scanner.l" { return T_DOUBLE_ARROW; } -#line 3974 "Zend/zend_language_scanner.c" +#line 3970 "Zend/zend_language_scanner.c" yy294: YYDEBUG(294, *YYCURSOR); ++YYCURSOR; YYDEBUG(295, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1325 "Zend/zend_language_scanner.l" +#line 1321 "Zend/zend_language_scanner.l" { return T_IS_IDENTICAL; } -#line 3984 "Zend/zend_language_scanner.c" +#line 3980 "Zend/zend_language_scanner.c" yy296: YYDEBUG(296, *YYCURSOR); yych = *++YYCURSOR; @@ -4102,7 +4098,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(314, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1629 "Zend/zend_language_scanner.l" +#line 1625 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4112,7 +4108,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NS_C; } -#line 4116 "Zend/zend_language_scanner.c" +#line 4112 "Zend/zend_language_scanner.c" yy315: YYDEBUG(315, *YYCURSOR); yych = *++YYCURSOR; @@ -4132,7 +4128,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(319, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1602 "Zend/zend_language_scanner.l" +#line 1598 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4159,7 +4155,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_DIR; } -#line 4163 "Zend/zend_language_scanner.c" +#line 4159 "Zend/zend_language_scanner.c" yy320: YYDEBUG(320, *YYCURSOR); yych = *++YYCURSOR; @@ -4184,13 +4180,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(325, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1584 "Zend/zend_language_scanner.l" +#line 1580 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; return T_LINE; } -#line 4194 "Zend/zend_language_scanner.c" +#line 4190 "Zend/zend_language_scanner.c" yy326: YYDEBUG(326, *YYCURSOR); yych = *++YYCURSOR; @@ -4225,7 +4221,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(333, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1563 "Zend/zend_language_scanner.l" +#line 1559 "Zend/zend_language_scanner.l" { char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4246,7 +4242,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_METHOD_C; } -#line 4250 "Zend/zend_language_scanner.c" +#line 4246 "Zend/zend_language_scanner.c" yy334: YYDEBUG(334, *YYCURSOR); yych = *++YYCURSOR; @@ -4297,7 +4293,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(344, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1547 "Zend/zend_language_scanner.l" +#line 1543 "Zend/zend_language_scanner.l" { char *func_name = NULL; @@ -4313,7 +4309,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FUNC_C; } -#line 4317 "Zend/zend_language_scanner.c" +#line 4313 "Zend/zend_language_scanner.c" yy345: YYDEBUG(345, *YYCURSOR); yych = *++YYCURSOR; @@ -4333,7 +4329,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(349, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1590 "Zend/zend_language_scanner.l" +#line 1586 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4345,7 +4341,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FILE; } -#line 4349 "Zend/zend_language_scanner.c" +#line 4345 "Zend/zend_language_scanner.c" yy350: YYDEBUG(350, *YYCURSOR); yych = *++YYCURSOR; @@ -4375,7 +4371,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(356, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1531 "Zend/zend_language_scanner.l" +#line 1527 "Zend/zend_language_scanner.l" { char *class_name = NULL; @@ -4391,7 +4387,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_CLASS_C; } -#line 4395 "Zend/zend_language_scanner.c" +#line 4391 "Zend/zend_language_scanner.c" yy357: YYDEBUG(357, *YYCURSOR); yych = *++YYCURSOR; @@ -4453,11 +4449,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(369, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1273 "Zend/zend_language_scanner.l" +#line 1269 "Zend/zend_language_scanner.l" { return T_HALT_COMPILER; } -#line 4461 "Zend/zend_language_scanner.c" +#line 4457 "Zend/zend_language_scanner.c" yy370: YYDEBUG(370, *YYCURSOR); yych = *++YYCURSOR; @@ -4477,11 +4473,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(373, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1253 "Zend/zend_language_scanner.l" +#line 1249 "Zend/zend_language_scanner.l" { return T_USE; } -#line 4485 "Zend/zend_language_scanner.c" +#line 4481 "Zend/zend_language_scanner.c" yy374: YYDEBUG(374, *YYCURSOR); yych = *++YYCURSOR; @@ -4500,11 +4496,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(377, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1301 "Zend/zend_language_scanner.l" +#line 1297 "Zend/zend_language_scanner.l" { return T_UNSET; } -#line 4508 "Zend/zend_language_scanner.c" +#line 4504 "Zend/zend_language_scanner.c" yy378: YYDEBUG(378, *YYCURSOR); ++YYCURSOR; @@ -4582,53 +4578,43 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy380: YYDEBUG(380, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy455; - if (yych == 'n') goto yy455; + if (yych == 'N') goto yy447; + if (yych == 'n') goto yy447; goto yy193; yy381: YYDEBUG(381, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'I') goto yy442; + if (yych == 'I') goto yy434; if (yych <= 'N') goto yy193; - goto yy443; + goto yy435; } else { if (yych <= 'i') { if (yych <= 'h') goto yy193; - goto yy442; + goto yy434; } else { - if (yych == 'o') goto yy443; + if (yych == 'o') goto yy435; goto yy193; } } yy382: YYDEBUG(382, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy434; - if (yych == 'b') goto yy434; + if (yych == 'B') goto yy426; + if (yych == 'b') goto yy426; goto yy193; yy383: YYDEBUG(383, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy427; - if (yych == 'r') goto yy427; + if (yych == 'R') goto yy419; + if (yych == 'r') goto yy419; goto yy193; yy384: YYDEBUG(384, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych == 'C') goto yy412; - if (yych <= 'S') goto yy193; - goto yy411; - } else { - if (yych <= 'c') { - if (yych <= 'b') goto yy193; - goto yy412; - } else { - if (yych == 't') goto yy411; - goto yy193; - } - } + if (yych == 'T') goto yy411; + if (yych == 't') goto yy411; + goto yy193; yy385: YYDEBUG(385, *YYCURSOR); yych = *++YYCURSOR; @@ -4690,7 +4676,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INT_CAST; } -#line 4694 "Zend/zend_language_scanner.c" +#line 4680 "Zend/zend_language_scanner.c" yy396: YYDEBUG(396, *YYCURSOR); yych = *++YYCURSOR; @@ -4738,7 +4724,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_DOUBLE_CAST; } -#line 4742 "Zend/zend_language_scanner.c" +#line 4728 "Zend/zend_language_scanner.c" yy405: YYDEBUG(405, *YYCURSOR); yych = *++YYCURSOR; @@ -4774,103 +4760,102 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy411: YYDEBUG(411, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy420; - if (yych == 'r') goto yy420; - goto yy193; + if (yych == 'R') goto yy412; + if (yych != 'r') goto yy193; yy412: YYDEBUG(412, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy413; - if (yych != 'a') goto yy193; + if (yych == 'I') goto yy413; + if (yych != 'i') goto yy193; yy413: YYDEBUG(413, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy414; - if (yych != 'l') goto yy193; + if (yych == 'N') goto yy414; + if (yych != 'n') goto yy193; yy414: YYDEBUG(414, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy415; - if (yych != 'a') goto yy193; + if (yych == 'G') goto yy415; + if (yych != 'g') goto yy193; yy415: YYDEBUG(415, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'R') goto yy416; - if (yych != 'r') goto yy193; -yy416: - YYDEBUG(416, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(417, *YYCURSOR); + YYDEBUG(416, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy416; + if (yych == '\t') goto yy415; goto yy193; } else { - if (yych <= ' ') goto yy416; + if (yych <= ' ') goto yy415; if (yych != ')') goto yy193; } - YYDEBUG(418, *YYCURSOR); + YYDEBUG(417, *YYCURSOR); ++YYCURSOR; - YYDEBUG(419, *YYCURSOR); + YYDEBUG(418, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1209 "Zend/zend_language_scanner.l" +#line 1205 "Zend/zend_language_scanner.l" { - return T_SCALAR_CAST; + return T_STRING_CAST; } -#line 4822 "Zend/zend_language_scanner.c" +#line 4802 "Zend/zend_language_scanner.c" +yy419: + YYDEBUG(419, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy420; + if (yych != 'r') goto yy193; yy420: YYDEBUG(420, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy421; - if (yych != 'i') goto yy193; + if (yych == 'A') goto yy421; + if (yych != 'a') goto yy193; yy421: YYDEBUG(421, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy422; - if (yych != 'n') goto yy193; + if (yych == 'Y') goto yy422; + if (yych != 'y') goto yy193; yy422: YYDEBUG(422, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'G') goto yy423; - if (yych != 'g') goto yy193; -yy423: - YYDEBUG(423, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(424, *YYCURSOR); + YYDEBUG(423, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy423; + if (yych == '\t') goto yy422; goto yy193; } else { - if (yych <= ' ') goto yy423; + if (yych <= ' ') goto yy422; if (yych != ')') goto yy193; } - YYDEBUG(425, *YYCURSOR); + YYDEBUG(424, *YYCURSOR); ++YYCURSOR; - YYDEBUG(426, *YYCURSOR); + YYDEBUG(425, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1205 "Zend/zend_language_scanner.l" +#line 1209 "Zend/zend_language_scanner.l" { - return T_STRING_CAST; + return T_ARRAY_CAST; } -#line 4859 "Zend/zend_language_scanner.c" +#line 4839 "Zend/zend_language_scanner.c" +yy426: + YYDEBUG(426, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'J') goto yy427; + if (yych != 'j') goto yy193; yy427: YYDEBUG(427, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy428; - if (yych != 'r') goto yy193; + if (yych == 'E') goto yy428; + if (yych != 'e') goto yy193; yy428: YYDEBUG(428, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy429; - if (yych != 'a') goto yy193; + if (yych == 'C') goto yy429; + if (yych != 'c') goto yy193; yy429: YYDEBUG(429, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy430; - if (yych != 'y') goto yy193; + if (yych == 'T') goto yy430; + if (yych != 't') goto yy193; yy430: YYDEBUG(430, *YYCURSOR); ++YYCURSOR; @@ -4890,34 +4875,37 @@ int lex_scan(zval *zendlval TSRMLS_DC) yyleng = YYCURSOR - SCNG(yy_text); #line 1213 "Zend/zend_language_scanner.l" { - return T_ARRAY_CAST; + return T_OBJECT_CAST; } -#line 4896 "Zend/zend_language_scanner.c" +#line 4881 "Zend/zend_language_scanner.c" yy434: YYDEBUG(434, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'J') goto yy435; - if (yych != 'j') goto yy193; + if (yych == 'N') goto yy444; + if (yych == 'n') goto yy444; + goto yy193; yy435: YYDEBUG(435, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy436; - if (yych != 'e') goto yy193; + if (yych == 'O') goto yy436; + if (yych != 'o') goto yy193; yy436: YYDEBUG(436, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy437; - if (yych != 'c') goto yy193; + if (yych == 'L') goto yy437; + if (yych != 'l') goto yy193; yy437: YYDEBUG(437, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy438; - if (yych != 't') goto yy193; + if (yych == 'E') goto yy442; + if (yych == 'e') goto yy442; + goto yy439; yy438: YYDEBUG(438, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; +yy439: YYDEBUG(439, *YYCURSOR); if (yych <= 0x1F) { if (yych == '\t') goto yy438; @@ -4932,2112 +4920,2067 @@ int lex_scan(zval *zendlval TSRMLS_DC) yyleng = YYCURSOR - SCNG(yy_text); #line 1217 "Zend/zend_language_scanner.l" { - return T_OBJECT_CAST; + return T_BOOL_CAST; } -#line 4938 "Zend/zend_language_scanner.c" +#line 4926 "Zend/zend_language_scanner.c" yy442: YYDEBUG(442, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy452; - if (yych == 'n') goto yy452; - goto yy193; + if (yych == 'A') goto yy443; + if (yych != 'a') goto yy193; yy443: YYDEBUG(443, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy444; - if (yych != 'o') goto yy193; + if (yych == 'N') goto yy438; + if (yych == 'n') goto yy438; + goto yy193; yy444: YYDEBUG(444, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy445; - if (yych != 'l') goto yy193; + if (yych == 'A') goto yy445; + if (yych != 'a') goto yy193; yy445: YYDEBUG(445, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy450; - if (yych == 'e') goto yy450; - goto yy447; + if (yych == 'R') goto yy446; + if (yych != 'r') goto yy193; yy446: YYDEBUG(446, *YYCURSOR); - ++YYCURSOR; - YYFILL(1); - yych = *YYCURSOR; -yy447: - YYDEBUG(447, *YYCURSOR); - if (yych <= 0x1F) { - if (yych == '\t') goto yy446; - goto yy193; - } else { - if (yych <= ' ') goto yy446; - if (yych != ')') goto yy193; - } - YYDEBUG(448, *YYCURSOR); - ++YYCURSOR; - YYDEBUG(449, *YYCURSOR); - yyleng = YYCURSOR - SCNG(yy_text); -#line 1221 "Zend/zend_language_scanner.l" - { - return T_BOOL_CAST; -} -#line 4983 "Zend/zend_language_scanner.c" -yy450: - YYDEBUG(450, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'A') goto yy451; - if (yych != 'a') goto yy193; -yy451: - YYDEBUG(451, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'N') goto yy446; - if (yych == 'n') goto yy446; - goto yy193; -yy452: - YYDEBUG(452, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'A') goto yy453; - if (yych != 'a') goto yy193; -yy453: - YYDEBUG(453, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy454; - if (yych != 'r') goto yy193; -yy454: - YYDEBUG(454, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'Y') goto yy423; - if (yych == 'y') goto yy423; + if (yych == 'Y') goto yy415; + if (yych == 'y') goto yy415; goto yy193; -yy455: - YYDEBUG(455, *YYCURSOR); +yy447: + YYDEBUG(447, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy456; + if (yych == 'S') goto yy448; if (yych != 's') goto yy193; -yy456: - YYDEBUG(456, *YYCURSOR); +yy448: + YYDEBUG(448, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy457; + if (yych == 'E') goto yy449; if (yych != 'e') goto yy193; -yy457: - YYDEBUG(457, *YYCURSOR); +yy449: + YYDEBUG(449, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy458; + if (yych == 'T') goto yy450; if (yych != 't') goto yy193; -yy458: - YYDEBUG(458, *YYCURSOR); +yy450: + YYDEBUG(450, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(459, *YYCURSOR); + YYDEBUG(451, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy458; + if (yych == '\t') goto yy450; goto yy193; } else { - if (yych <= ' ') goto yy458; + if (yych <= ' ') goto yy450; if (yych != ')') goto yy193; } - YYDEBUG(460, *YYCURSOR); + YYDEBUG(452, *YYCURSOR); ++YYCURSOR; - YYDEBUG(461, *YYCURSOR); + YYDEBUG(453, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1225 "Zend/zend_language_scanner.l" +#line 1221 "Zend/zend_language_scanner.l" { return T_UNSET_CAST; } -#line 5047 "Zend/zend_language_scanner.c" -yy462: - YYDEBUG(462, *YYCURSOR); +#line 4990 "Zend/zend_language_scanner.c" +yy454: + YYDEBUG(454, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy463; + if (yych == 'R') goto yy455; if (yych != 'r') goto yy186; -yy463: - YYDEBUG(463, *YYCURSOR); +yy455: + YYDEBUG(455, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(464, *YYCURSOR); + YYDEBUG(456, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1193 "Zend/zend_language_scanner.l" { return T_VAR; } -#line 5065 "Zend/zend_language_scanner.c" -yy465: - YYDEBUG(465, *YYCURSOR); +#line 5008 "Zend/zend_language_scanner.c" +yy457: + YYDEBUG(457, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy469; - if (yych == 'm') goto yy469; + if (yych == 'M') goto yy461; + if (yych == 'm') goto yy461; goto yy186; -yy466: - YYDEBUG(466, *YYCURSOR); +yy458: + YYDEBUG(458, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy467; + if (yych == 'W') goto yy459; if (yych != 'w') goto yy186; -yy467: - YYDEBUG(467, *YYCURSOR); +yy459: + YYDEBUG(459, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(468, *YYCURSOR); + YYDEBUG(460, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1185 "Zend/zend_language_scanner.l" { return T_NEW; } -#line 5089 "Zend/zend_language_scanner.c" -yy469: - YYDEBUG(469, *YYCURSOR); +#line 5032 "Zend/zend_language_scanner.c" +yy461: + YYDEBUG(461, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy470; + if (yych == 'E') goto yy462; if (yych != 'e') goto yy186; -yy470: - YYDEBUG(470, *YYCURSOR); +yy462: + YYDEBUG(462, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy471; + if (yych == 'S') goto yy463; if (yych != 's') goto yy186; -yy471: - YYDEBUG(471, *YYCURSOR); +yy463: + YYDEBUG(463, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy472; + if (yych == 'P') goto yy464; if (yych != 'p') goto yy186; -yy472: - YYDEBUG(472, *YYCURSOR); +yy464: + YYDEBUG(464, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy473; + if (yych == 'A') goto yy465; if (yych != 'a') goto yy186; -yy473: - YYDEBUG(473, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'C') goto yy474; +yy465: + YYDEBUG(465, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy466; if (yych != 'c') goto yy186; -yy474: - YYDEBUG(474, *YYCURSOR); +yy466: + YYDEBUG(466, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy475; + if (yych == 'E') goto yy467; if (yych != 'e') goto yy186; -yy475: - YYDEBUG(475, *YYCURSOR); +yy467: + YYDEBUG(467, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(476, *YYCURSOR); + YYDEBUG(468, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1249 "Zend/zend_language_scanner.l" +#line 1245 "Zend/zend_language_scanner.l" { return T_NAMESPACE; } -#line 5132 "Zend/zend_language_scanner.c" -yy477: - YYDEBUG(477, *YYCURSOR); +#line 5075 "Zend/zend_language_scanner.c" +yy469: + YYDEBUG(469, *YYCURSOR); ++YYCURSOR; - YYDEBUG(478, *YYCURSOR); + YYDEBUG(470, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1177 "Zend/zend_language_scanner.l" { return T_PAAMAYIM_NEKUDOTAYIM; } -#line 5142 "Zend/zend_language_scanner.c" -yy479: - YYDEBUG(479, *YYCURSOR); +#line 5085 "Zend/zend_language_scanner.c" +yy471: + YYDEBUG(471, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy480: - YYDEBUG(480, *YYCURSOR); +yy472: + YYDEBUG(472, *YYCURSOR); if (yych <= '\f') { if (yych <= 0x08) goto yy140; - if (yych <= '\n') goto yy479; + if (yych <= '\n') goto yy471; goto yy140; } else { - if (yych <= '\r') goto yy479; - if (yych == ' ') goto yy479; + if (yych <= '\r') goto yy471; + if (yych == ' ') goto yy471; goto yy140; } -yy481: - YYDEBUG(481, *YYCURSOR); +yy473: + YYDEBUG(473, *YYCURSOR); ++YYCURSOR; - YYDEBUG(482, *YYCURSOR); + YYDEBUG(474, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1353 "Zend/zend_language_scanner.l" +#line 1349 "Zend/zend_language_scanner.l" { return T_MINUS_EQUAL; } -#line 5168 "Zend/zend_language_scanner.c" -yy483: - YYDEBUG(483, *YYCURSOR); +#line 5111 "Zend/zend_language_scanner.c" +yy475: + YYDEBUG(475, *YYCURSOR); ++YYCURSOR; - YYDEBUG(484, *YYCURSOR); + YYDEBUG(476, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1321 "Zend/zend_language_scanner.l" +#line 1317 "Zend/zend_language_scanner.l" { return T_DEC; } -#line 5178 "Zend/zend_language_scanner.c" -yy485: - YYDEBUG(485, *YYCURSOR); +#line 5121 "Zend/zend_language_scanner.c" +yy477: + YYDEBUG(477, *YYCURSOR); ++YYCURSOR; - YYDEBUG(486, *YYCURSOR); + YYDEBUG(478, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1147 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); return T_OBJECT_OPERATOR; } -#line 5189 "Zend/zend_language_scanner.c" -yy487: - YYDEBUG(487, *YYCURSOR); +#line 5132 "Zend/zend_language_scanner.c" +yy479: + YYDEBUG(479, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'I') goto yy494; + if (yych == 'I') goto yy486; if (yych <= 'N') goto yy186; - goto yy495; + goto yy487; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; - goto yy494; + goto yy486; } else { - if (yych == 'o') goto yy495; + if (yych == 'o') goto yy487; goto yy186; } } -yy488: - YYDEBUG(488, *YYCURSOR); +yy480: + YYDEBUG(480, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy489; + if (yych == 'B') goto yy481; if (yych != 'b') goto yy186; -yy489: - YYDEBUG(489, *YYCURSOR); +yy481: + YYDEBUG(481, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy490; + if (yych == 'L') goto yy482; if (yych != 'l') goto yy186; -yy490: - YYDEBUG(490, *YYCURSOR); +yy482: + YYDEBUG(482, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy491; + if (yych == 'I') goto yy483; if (yych != 'i') goto yy186; -yy491: - YYDEBUG(491, *YYCURSOR); +yy483: + YYDEBUG(483, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy492; + if (yych == 'C') goto yy484; if (yych != 'c') goto yy186; -yy492: - YYDEBUG(492, *YYCURSOR); +yy484: + YYDEBUG(484, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(493, *YYCURSOR); + YYDEBUG(485, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1297 "Zend/zend_language_scanner.l" +#line 1293 "Zend/zend_language_scanner.l" { return T_PUBLIC; } -#line 5238 "Zend/zend_language_scanner.c" -yy494: - YYDEBUG(494, *YYCURSOR); +#line 5181 "Zend/zend_language_scanner.c" +yy486: + YYDEBUG(486, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'V') { - if (yych == 'N') goto yy503; + if (yych == 'N') goto yy495; if (yych <= 'U') goto yy186; - goto yy504; + goto yy496; } else { if (yych <= 'n') { if (yych <= 'm') goto yy186; - goto yy503; + goto yy495; } else { - if (yych == 'v') goto yy504; + if (yych == 'v') goto yy496; goto yy186; } } -yy495: - YYDEBUG(495, *YYCURSOR); +yy487: + YYDEBUG(487, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy496; + if (yych == 'T') goto yy488; if (yych != 't') goto yy186; -yy496: - YYDEBUG(496, *YYCURSOR); +yy488: + YYDEBUG(488, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy497; + if (yych == 'E') goto yy489; if (yych != 'e') goto yy186; -yy497: - YYDEBUG(497, *YYCURSOR); +yy489: + YYDEBUG(489, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy498; + if (yych == 'C') goto yy490; if (yych != 'c') goto yy186; -yy498: - YYDEBUG(498, *YYCURSOR); +yy490: + YYDEBUG(490, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy499; + if (yych == 'T') goto yy491; if (yych != 't') goto yy186; -yy499: - YYDEBUG(499, *YYCURSOR); +yy491: + YYDEBUG(491, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy500; + if (yych == 'E') goto yy492; if (yych != 'e') goto yy186; -yy500: - YYDEBUG(500, *YYCURSOR); +yy492: + YYDEBUG(492, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy501; + if (yych == 'D') goto yy493; if (yych != 'd') goto yy186; -yy501: - YYDEBUG(501, *YYCURSOR); +yy493: + YYDEBUG(493, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(502, *YYCURSOR); + YYDEBUG(494, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1293 "Zend/zend_language_scanner.l" +#line 1289 "Zend/zend_language_scanner.l" { return T_PROTECTED; } -#line 5297 "Zend/zend_language_scanner.c" -yy503: - YYDEBUG(503, *YYCURSOR); +#line 5240 "Zend/zend_language_scanner.c" +yy495: + YYDEBUG(495, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy509; - if (yych == 't') goto yy509; + if (yych == 'T') goto yy501; + if (yych == 't') goto yy501; goto yy186; -yy504: - YYDEBUG(504, *YYCURSOR); +yy496: + YYDEBUG(496, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy505; + if (yych == 'A') goto yy497; if (yych != 'a') goto yy186; -yy505: - YYDEBUG(505, *YYCURSOR); +yy497: + YYDEBUG(497, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy506; + if (yych == 'T') goto yy498; if (yych != 't') goto yy186; -yy506: - YYDEBUG(506, *YYCURSOR); +yy498: + YYDEBUG(498, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy507; + if (yych == 'E') goto yy499; if (yych != 'e') goto yy186; -yy507: - YYDEBUG(507, *YYCURSOR); +yy499: + YYDEBUG(499, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(508, *YYCURSOR); + YYDEBUG(500, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1289 "Zend/zend_language_scanner.l" +#line 1285 "Zend/zend_language_scanner.l" { return T_PRIVATE; } -#line 5331 "Zend/zend_language_scanner.c" -yy509: - YYDEBUG(509, *YYCURSOR); +#line 5274 "Zend/zend_language_scanner.c" +yy501: + YYDEBUG(501, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(510, *YYCURSOR); + YYDEBUG(502, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1123 "Zend/zend_language_scanner.l" { return T_PRINT; } -#line 5344 "Zend/zend_language_scanner.c" -yy511: - YYDEBUG(511, *YYCURSOR); +#line 5287 "Zend/zend_language_scanner.c" +yy503: + YYDEBUG(503, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy516; - if (yych == 'o') goto yy516; + if (yych == 'O') goto yy508; + if (yych == 'o') goto yy508; goto yy186; -yy512: - YYDEBUG(512, *YYCURSOR); +yy504: + YYDEBUG(504, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy513; + if (yych == 'T') goto yy505; if (yych != 't') goto yy186; -yy513: - YYDEBUG(513, *YYCURSOR); +yy505: + YYDEBUG(505, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy514; + if (yych == 'O') goto yy506; if (yych != 'o') goto yy186; -yy514: - YYDEBUG(514, *YYCURSOR); +yy506: + YYDEBUG(506, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(515, *YYCURSOR); + YYDEBUG(507, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1115 "Zend/zend_language_scanner.l" { return T_GOTO; } -#line 5373 "Zend/zend_language_scanner.c" -yy516: - YYDEBUG(516, *YYCURSOR); +#line 5316 "Zend/zend_language_scanner.c" +yy508: + YYDEBUG(508, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy517; + if (yych == 'B') goto yy509; if (yych != 'b') goto yy186; -yy517: - YYDEBUG(517, *YYCURSOR); +yy509: + YYDEBUG(509, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy518; + if (yych == 'A') goto yy510; if (yych != 'a') goto yy186; -yy518: - YYDEBUG(518, *YYCURSOR); +yy510: + YYDEBUG(510, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy519; + if (yych == 'L') goto yy511; if (yych != 'l') goto yy186; -yy519: - YYDEBUG(519, *YYCURSOR); +yy511: + YYDEBUG(511, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(520, *YYCURSOR); + YYDEBUG(512, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1261 "Zend/zend_language_scanner.l" +#line 1257 "Zend/zend_language_scanner.l" { return T_GLOBAL; } -#line 5401 "Zend/zend_language_scanner.c" -yy521: - YYDEBUG(521, *YYCURSOR); +#line 5344 "Zend/zend_language_scanner.c" +yy513: + YYDEBUG(513, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '<') goto yy529; + if (yych == '<') goto yy521; goto yy193; -yy522: - YYDEBUG(522, *YYCURSOR); +yy514: + YYDEBUG(514, *YYCURSOR); yych = *++YYCURSOR; goto yy180; -yy523: - YYDEBUG(523, *YYCURSOR); +yy515: + YYDEBUG(515, *YYCURSOR); yych = *++YYCURSOR; goto yy178; -yy524: - YYDEBUG(524, *YYCURSOR); +yy516: + YYDEBUG(516, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy525; + if (yych == 'E') goto yy517; if (yych != 'e') goto yy186; -yy525: - YYDEBUG(525, *YYCURSOR); +yy517: + YYDEBUG(517, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy526; + if (yych == 'A') goto yy518; if (yych != 'a') goto yy186; -yy526: - YYDEBUG(526, *YYCURSOR); +yy518: + YYDEBUG(518, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'K') goto yy527; + if (yych == 'K') goto yy519; if (yych != 'k') goto yy186; -yy527: - YYDEBUG(527, *YYCURSOR); +yy519: + YYDEBUG(519, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(528, *YYCURSOR); + YYDEBUG(520, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1107 "Zend/zend_language_scanner.l" { return T_BREAK; } -#line 5442 "Zend/zend_language_scanner.c" -yy529: - YYDEBUG(529, *YYCURSOR); +#line 5385 "Zend/zend_language_scanner.c" +yy521: + YYDEBUG(521, *YYCURSOR); yych = *++YYCURSOR; if (yych == '<') goto yy265; goto yy193; -yy530: - YYDEBUG(530, *YYCURSOR); +yy522: + YYDEBUG(522, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy537; - if (yych == 'a') goto yy537; + if (yych == 'A') goto yy529; + if (yych == 'a') goto yy529; goto yy186; -yy531: - YYDEBUG(531, *YYCURSOR); +yy523: + YYDEBUG(523, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy532; + if (yych == 'I') goto yy524; if (yych != 'i') goto yy186; -yy532: - YYDEBUG(532, *YYCURSOR); +yy524: + YYDEBUG(524, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy533; + if (yych == 'T') goto yy525; if (yych != 't') goto yy186; -yy533: - YYDEBUG(533, *YYCURSOR); +yy525: + YYDEBUG(525, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy534; + if (yych == 'C') goto yy526; if (yych != 'c') goto yy186; -yy534: - YYDEBUG(534, *YYCURSOR); +yy526: + YYDEBUG(526, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy535; + if (yych == 'H') goto yy527; if (yych != 'h') goto yy186; -yy535: - YYDEBUG(535, *YYCURSOR); +yy527: + YYDEBUG(527, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(536, *YYCURSOR); + YYDEBUG(528, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1091 "Zend/zend_language_scanner.l" { return T_SWITCH; } -#line 5486 "Zend/zend_language_scanner.c" -yy537: - YYDEBUG(537, *YYCURSOR); +#line 5429 "Zend/zend_language_scanner.c" +yy529: + YYDEBUG(529, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy538; + if (yych == 'T') goto yy530; if (yych != 't') goto yy186; -yy538: - YYDEBUG(538, *YYCURSOR); +yy530: + YYDEBUG(530, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy539; + if (yych == 'I') goto yy531; if (yych != 'i') goto yy186; -yy539: - YYDEBUG(539, *YYCURSOR); +yy531: + YYDEBUG(531, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy540; + if (yych == 'C') goto yy532; if (yych != 'c') goto yy186; -yy540: - YYDEBUG(540, *YYCURSOR); +yy532: + YYDEBUG(532, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(541, *YYCURSOR); + YYDEBUG(533, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1277 "Zend/zend_language_scanner.l" +#line 1273 "Zend/zend_language_scanner.l" { return T_STATIC; } -#line 5514 "Zend/zend_language_scanner.c" -yy542: - YYDEBUG(542, *YYCURSOR); +#line 5457 "Zend/zend_language_scanner.c" +yy534: + YYDEBUG(534, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy553; - if (yych == 's') goto yy553; + if (yych == 'S') goto yy545; + if (yych == 's') goto yy545; goto yy186; -yy543: - YYDEBUG(543, *YYCURSOR); +yy535: + YYDEBUG(535, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy551; - if (yych == 'd') goto yy551; + if (yych == 'D') goto yy543; + if (yych == 'd') goto yy543; goto yy186; -yy544: - YYDEBUG(544, *YYCURSOR); +yy536: + YYDEBUG(536, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy547; - if (yych == 'r') goto yy547; + if (yych == 'R') goto yy539; + if (yych == 'r') goto yy539; goto yy186; -yy545: - YYDEBUG(545, *YYCURSOR); +yy537: + YYDEBUG(537, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(546, *YYCURSOR); + YYDEBUG(538, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1087 "Zend/zend_language_scanner.l" { return T_AS; } -#line 5545 "Zend/zend_language_scanner.c" -yy547: - YYDEBUG(547, *YYCURSOR); +#line 5488 "Zend/zend_language_scanner.c" +yy539: + YYDEBUG(539, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy548; + if (yych == 'A') goto yy540; if (yych != 'a') goto yy186; -yy548: - YYDEBUG(548, *YYCURSOR); +yy540: + YYDEBUG(540, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy549; + if (yych == 'Y') goto yy541; if (yych != 'y') goto yy186; -yy549: - YYDEBUG(549, *YYCURSOR); +yy541: + YYDEBUG(541, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(550, *YYCURSOR); + YYDEBUG(542, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1313 "Zend/zend_language_scanner.l" +#line 1309 "Zend/zend_language_scanner.l" { return T_ARRAY; } -#line 5568 "Zend/zend_language_scanner.c" -yy551: - YYDEBUG(551, *YYCURSOR); +#line 5511 "Zend/zend_language_scanner.c" +yy543: + YYDEBUG(543, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(552, *YYCURSOR); + YYDEBUG(544, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1405 "Zend/zend_language_scanner.l" +#line 1401 "Zend/zend_language_scanner.l" { return T_LOGICAL_AND; } -#line 5581 "Zend/zend_language_scanner.c" -yy553: - YYDEBUG(553, *YYCURSOR); +#line 5524 "Zend/zend_language_scanner.c" +yy545: + YYDEBUG(545, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy554; + if (yych == 'T') goto yy546; if (yych != 't') goto yy186; -yy554: - YYDEBUG(554, *YYCURSOR); +yy546: + YYDEBUG(546, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy555; + if (yych == 'R') goto yy547; if (yych != 'r') goto yy186; -yy555: - YYDEBUG(555, *YYCURSOR); +yy547: + YYDEBUG(547, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy556; + if (yych == 'A') goto yy548; if (yych != 'a') goto yy186; -yy556: - YYDEBUG(556, *YYCURSOR); +yy548: + YYDEBUG(548, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy557; + if (yych == 'C') goto yy549; if (yych != 'c') goto yy186; -yy557: - YYDEBUG(557, *YYCURSOR); +yy549: + YYDEBUG(549, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy558; + if (yych == 'T') goto yy550; if (yych != 't') goto yy186; -yy558: - YYDEBUG(558, *YYCURSOR); +yy550: + YYDEBUG(550, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(559, *YYCURSOR); + YYDEBUG(551, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1281 "Zend/zend_language_scanner.l" +#line 1277 "Zend/zend_language_scanner.l" { return T_ABSTRACT; } -#line 5619 "Zend/zend_language_scanner.c" -yy560: - YYDEBUG(560, *YYCURSOR); +#line 5562 "Zend/zend_language_scanner.c" +yy552: + YYDEBUG(552, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy561; + if (yych == 'I') goto yy553; if (yych != 'i') goto yy186; -yy561: - YYDEBUG(561, *YYCURSOR); +yy553: + YYDEBUG(553, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy562; + if (yych == 'L') goto yy554; if (yych != 'l') goto yy186; -yy562: - YYDEBUG(562, *YYCURSOR); +yy554: + YYDEBUG(554, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy563; + if (yych == 'E') goto yy555; if (yych != 'e') goto yy186; -yy563: - YYDEBUG(563, *YYCURSOR); +yy555: + YYDEBUG(555, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(564, *YYCURSOR); + YYDEBUG(556, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1047 "Zend/zend_language_scanner.l" { return T_WHILE; } -#line 5647 "Zend/zend_language_scanner.c" -yy565: - YYDEBUG(565, *YYCURSOR); +#line 5590 "Zend/zend_language_scanner.c" +yy557: + YYDEBUG(557, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(566, *YYCURSOR); + YYDEBUG(558, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1031 "Zend/zend_language_scanner.l" { return T_IF; } -#line 5660 "Zend/zend_language_scanner.c" -yy567: - YYDEBUG(567, *YYCURSOR); +#line 5603 "Zend/zend_language_scanner.c" +yy559: + YYDEBUG(559, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy609; - if (yych == 'p') goto yy609; + if (yych == 'P') goto yy601; + if (yych == 'p') goto yy601; goto yy186; -yy568: - YYDEBUG(568, *YYCURSOR); +yy560: + YYDEBUG(560, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'C') { if (yych <= 'B') goto yy186; - goto yy576; + goto yy568; } else { if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy574; - goto yy575; + if (yych <= 'S') goto yy566; + goto yy567; } } else { if (yych <= 'r') { - if (yych == 'c') goto yy576; + if (yych == 'c') goto yy568; goto yy186; } else { - if (yych <= 's') goto yy574; - if (yych <= 't') goto yy575; + if (yych <= 's') goto yy566; + if (yych <= 't') goto yy567; goto yy186; } } -yy569: - YYDEBUG(569, *YYCURSOR); +yy561: + YYDEBUG(561, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy570; + if (yych == 'S') goto yy562; if (yych != 's') goto yy186; -yy570: - YYDEBUG(570, *YYCURSOR); +yy562: + YYDEBUG(562, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy571; + if (yych == 'E') goto yy563; if (yych != 'e') goto yy186; -yy571: - YYDEBUG(571, *YYCURSOR); +yy563: + YYDEBUG(563, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy572; + if (yych == 'T') goto yy564; if (yych != 't') goto yy186; -yy572: - YYDEBUG(572, *YYCURSOR); +yy564: + YYDEBUG(564, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(573, *YYCURSOR); + YYDEBUG(565, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1265 "Zend/zend_language_scanner.l" +#line 1261 "Zend/zend_language_scanner.l" { return T_ISSET; } -#line 5716 "Zend/zend_language_scanner.c" -yy574: - YYDEBUG(574, *YYCURSOR); +#line 5659 "Zend/zend_language_scanner.c" +yy566: + YYDEBUG(566, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy595; - if (yych == 't') goto yy595; + if (yych == 'T') goto yy587; + if (yych == 't') goto yy587; goto yy186; -yy575: - YYDEBUG(575, *YYCURSOR); +yy567: + YYDEBUG(567, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy588; - if (yych == 'e') goto yy588; + if (yych == 'E') goto yy580; + if (yych == 'e') goto yy580; goto yy186; -yy576: - YYDEBUG(576, *YYCURSOR); +yy568: + YYDEBUG(568, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy577; + if (yych == 'L') goto yy569; if (yych != 'l') goto yy186; -yy577: - YYDEBUG(577, *YYCURSOR); +yy569: + YYDEBUG(569, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy578; + if (yych == 'U') goto yy570; if (yych != 'u') goto yy186; -yy578: - YYDEBUG(578, *YYCURSOR); +yy570: + YYDEBUG(570, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy579; + if (yych == 'D') goto yy571; if (yych != 'd') goto yy186; -yy579: - YYDEBUG(579, *YYCURSOR); +yy571: + YYDEBUG(571, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy580; + if (yych == 'E') goto yy572; if (yych != 'e') goto yy186; -yy580: - YYDEBUG(580, *YYCURSOR); +yy572: + YYDEBUG(572, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '9') { if (yych >= '0') goto yy185; } else { - if (yych <= '@') goto yy581; + if (yych <= '@') goto yy573; if (yych <= 'Z') goto yy185; } } else { if (yych <= '`') { - if (yych <= '_') goto yy582; + if (yych <= '_') goto yy574; } else { if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy581: - YYDEBUG(581, *YYCURSOR); +yy573: + YYDEBUG(573, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1233 "Zend/zend_language_scanner.l" +#line 1229 "Zend/zend_language_scanner.l" { return T_INCLUDE; } -#line 5774 "Zend/zend_language_scanner.c" -yy582: - YYDEBUG(582, *YYCURSOR); +#line 5717 "Zend/zend_language_scanner.c" +yy574: + YYDEBUG(574, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy583; + if (yych == 'O') goto yy575; if (yych != 'o') goto yy186; -yy583: - YYDEBUG(583, *YYCURSOR); +yy575: + YYDEBUG(575, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy584; + if (yych == 'N') goto yy576; if (yych != 'n') goto yy186; -yy584: - YYDEBUG(584, *YYCURSOR); +yy576: + YYDEBUG(576, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy585; + if (yych == 'C') goto yy577; if (yych != 'c') goto yy186; -yy585: - YYDEBUG(585, *YYCURSOR); +yy577: + YYDEBUG(577, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy586; + if (yych == 'E') goto yy578; if (yych != 'e') goto yy186; -yy586: - YYDEBUG(586, *YYCURSOR); +yy578: + YYDEBUG(578, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(587, *YYCURSOR); + YYDEBUG(579, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1237 "Zend/zend_language_scanner.l" +#line 1233 "Zend/zend_language_scanner.l" { return T_INCLUDE_ONCE; } -#line 5807 "Zend/zend_language_scanner.c" -yy588: - YYDEBUG(588, *YYCURSOR); +#line 5750 "Zend/zend_language_scanner.c" +yy580: + YYDEBUG(580, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy589; + if (yych == 'R') goto yy581; if (yych != 'r') goto yy186; -yy589: - YYDEBUG(589, *YYCURSOR); +yy581: + YYDEBUG(581, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy590; + if (yych == 'F') goto yy582; if (yych != 'f') goto yy186; -yy590: - YYDEBUG(590, *YYCURSOR); +yy582: + YYDEBUG(582, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy591; + if (yych == 'A') goto yy583; if (yych != 'a') goto yy186; -yy591: - YYDEBUG(591, *YYCURSOR); +yy583: + YYDEBUG(583, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy592; + if (yych == 'C') goto yy584; if (yych != 'c') goto yy186; -yy592: - YYDEBUG(592, *YYCURSOR); +yy584: + YYDEBUG(584, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy593; + if (yych == 'E') goto yy585; if (yych != 'e') goto yy186; -yy593: - YYDEBUG(593, *YYCURSOR); +yy585: + YYDEBUG(585, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(594, *YYCURSOR); + YYDEBUG(586, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1131 "Zend/zend_language_scanner.l" { return T_INTERFACE; } -#line 5845 "Zend/zend_language_scanner.c" -yy595: - YYDEBUG(595, *YYCURSOR); +#line 5788 "Zend/zend_language_scanner.c" +yy587: + YYDEBUG(587, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'E') { - if (yych == 'A') goto yy596; + if (yych == 'A') goto yy588; if (yych <= 'D') goto yy186; - goto yy597; + goto yy589; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; } else { - if (yych == 'e') goto yy597; + if (yych == 'e') goto yy589; goto yy186; } } -yy596: - YYDEBUG(596, *YYCURSOR); +yy588: + YYDEBUG(588, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy603; - if (yych == 'n') goto yy603; + if (yych == 'N') goto yy595; + if (yych == 'n') goto yy595; goto yy186; -yy597: - YYDEBUG(597, *YYCURSOR); +yy589: + YYDEBUG(589, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy598; + if (yych == 'A') goto yy590; if (yych != 'a') goto yy186; -yy598: - YYDEBUG(598, *YYCURSOR); +yy590: + YYDEBUG(590, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy599; + if (yych == 'D') goto yy591; if (yych != 'd') goto yy186; -yy599: - YYDEBUG(599, *YYCURSOR); +yy591: + YYDEBUG(591, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy600; + if (yych == 'O') goto yy592; if (yych != 'o') goto yy186; -yy600: - YYDEBUG(600, *YYCURSOR); +yy592: + YYDEBUG(592, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy601; + if (yych == 'F') goto yy593; if (yych != 'f') goto yy186; -yy601: - YYDEBUG(601, *YYCURSOR); +yy593: + YYDEBUG(593, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(602, *YYCURSOR); + YYDEBUG(594, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1257 "Zend/zend_language_scanner.l" +#line 1253 "Zend/zend_language_scanner.l" { return T_INSTEADOF; } -#line 5899 "Zend/zend_language_scanner.c" -yy603: - YYDEBUG(603, *YYCURSOR); +#line 5842 "Zend/zend_language_scanner.c" +yy595: + YYDEBUG(595, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy604; + if (yych == 'C') goto yy596; if (yych != 'c') goto yy186; -yy604: - YYDEBUG(604, *YYCURSOR); +yy596: + YYDEBUG(596, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy605; + if (yych == 'E') goto yy597; if (yych != 'e') goto yy186; -yy605: - YYDEBUG(605, *YYCURSOR); +yy597: + YYDEBUG(597, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy606; + if (yych == 'O') goto yy598; if (yych != 'o') goto yy186; -yy606: - YYDEBUG(606, *YYCURSOR); +yy598: + YYDEBUG(598, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy607; + if (yych == 'F') goto yy599; if (yych != 'f') goto yy186; -yy607: - YYDEBUG(607, *YYCURSOR); +yy599: + YYDEBUG(599, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(608, *YYCURSOR); + YYDEBUG(600, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1083 "Zend/zend_language_scanner.l" { return T_INSTANCEOF; } -#line 5932 "Zend/zend_language_scanner.c" -yy609: - YYDEBUG(609, *YYCURSOR); +#line 5875 "Zend/zend_language_scanner.c" +yy601: + YYDEBUG(601, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy610; + if (yych == 'L') goto yy602; if (yych != 'l') goto yy186; -yy610: - YYDEBUG(610, *YYCURSOR); +yy602: + YYDEBUG(602, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy611; + if (yych == 'E') goto yy603; if (yych != 'e') goto yy186; -yy611: - YYDEBUG(611, *YYCURSOR); +yy603: + YYDEBUG(603, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy612; + if (yych == 'M') goto yy604; if (yych != 'm') goto yy186; -yy612: - YYDEBUG(612, *YYCURSOR); +yy604: + YYDEBUG(604, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy613; + if (yych == 'E') goto yy605; if (yych != 'e') goto yy186; -yy613: - YYDEBUG(613, *YYCURSOR); +yy605: + YYDEBUG(605, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy614; + if (yych == 'N') goto yy606; if (yych != 'n') goto yy186; -yy614: - YYDEBUG(614, *YYCURSOR); +yy606: + YYDEBUG(606, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy615; + if (yych == 'T') goto yy607; if (yych != 't') goto yy186; -yy615: - YYDEBUG(615, *YYCURSOR); +yy607: + YYDEBUG(607, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy616; + if (yych == 'S') goto yy608; if (yych != 's') goto yy186; -yy616: - YYDEBUG(616, *YYCURSOR); +yy608: + YYDEBUG(608, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(617, *YYCURSOR); + YYDEBUG(609, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1143 "Zend/zend_language_scanner.l" { return T_IMPLEMENTS; } -#line 5980 "Zend/zend_language_scanner.c" -yy618: - YYDEBUG(618, *YYCURSOR); +#line 5923 "Zend/zend_language_scanner.c" +yy610: + YYDEBUG(610, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy626; - if (yych == 'r') goto yy626; + if (yych == 'R') goto yy618; + if (yych == 'r') goto yy618; goto yy186; -yy619: - YYDEBUG(619, *YYCURSOR); +yy611: + YYDEBUG(611, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'Y') { - if (yych == 'A') goto yy622; + if (yych == 'A') goto yy614; if (yych <= 'X') goto yy186; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy622; + goto yy614; } else { if (yych != 'y') goto yy186; } } - YYDEBUG(620, *YYCURSOR); + YYDEBUG(612, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(621, *YYCURSOR); + YYDEBUG(613, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1019 "Zend/zend_language_scanner.l" { return T_TRY; } -#line 6012 "Zend/zend_language_scanner.c" -yy622: - YYDEBUG(622, *YYCURSOR); +#line 5955 "Zend/zend_language_scanner.c" +yy614: + YYDEBUG(614, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy623; + if (yych == 'I') goto yy615; if (yych != 'i') goto yy186; -yy623: - YYDEBUG(623, *YYCURSOR); +yy615: + YYDEBUG(615, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy624; + if (yych == 'T') goto yy616; if (yych != 't') goto yy186; -yy624: - YYDEBUG(624, *YYCURSOR); +yy616: + YYDEBUG(616, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(625, *YYCURSOR); + YYDEBUG(617, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1135 "Zend/zend_language_scanner.l" { return T_TRAIT; } -#line 6035 "Zend/zend_language_scanner.c" -yy626: - YYDEBUG(626, *YYCURSOR); +#line 5978 "Zend/zend_language_scanner.c" +yy618: + YYDEBUG(618, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy627; + if (yych == 'O') goto yy619; if (yych != 'o') goto yy186; -yy627: - YYDEBUG(627, *YYCURSOR); +yy619: + YYDEBUG(619, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy628; + if (yych == 'W') goto yy620; if (yych != 'w') goto yy186; -yy628: - YYDEBUG(628, *YYCURSOR); +yy620: + YYDEBUG(620, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(629, *YYCURSOR); + YYDEBUG(621, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1027 "Zend/zend_language_scanner.l" { return T_THROW; } -#line 6058 "Zend/zend_language_scanner.c" -yy630: - YYDEBUG(630, *YYCURSOR); +#line 6001 "Zend/zend_language_scanner.c" +yy622: + YYDEBUG(622, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'Q') goto yy632; + if (yych == 'Q') goto yy624; if (yych <= 'S') goto yy186; } else { if (yych <= 'q') { if (yych <= 'p') goto yy186; - goto yy632; + goto yy624; } else { if (yych != 't') goto yy186; } } - YYDEBUG(631, *YYCURSOR); + YYDEBUG(623, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy644; - if (yych == 'u') goto yy644; + if (yych == 'U') goto yy636; + if (yych == 'u') goto yy636; goto yy186; -yy632: - YYDEBUG(632, *YYCURSOR); +yy624: + YYDEBUG(624, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy633; + if (yych == 'U') goto yy625; if (yych != 'u') goto yy186; -yy633: - YYDEBUG(633, *YYCURSOR); +yy625: + YYDEBUG(625, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy634; + if (yych == 'I') goto yy626; if (yych != 'i') goto yy186; -yy634: - YYDEBUG(634, *YYCURSOR); +yy626: + YYDEBUG(626, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy635; + if (yych == 'R') goto yy627; if (yych != 'r') goto yy186; -yy635: - YYDEBUG(635, *YYCURSOR); +yy627: + YYDEBUG(627, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy636; + if (yych == 'E') goto yy628; if (yych != 'e') goto yy186; -yy636: - YYDEBUG(636, *YYCURSOR); +yy628: + YYDEBUG(628, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '9') { if (yych >= '0') goto yy185; } else { - if (yych <= '@') goto yy637; + if (yych <= '@') goto yy629; if (yych <= 'Z') goto yy185; } } else { if (yych <= '`') { - if (yych <= '_') goto yy638; + if (yych <= '_') goto yy630; } else { if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy637: - YYDEBUG(637, *YYCURSOR); +yy629: + YYDEBUG(629, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1241 "Zend/zend_language_scanner.l" +#line 1237 "Zend/zend_language_scanner.l" { return T_REQUIRE; } -#line 6123 "Zend/zend_language_scanner.c" -yy638: - YYDEBUG(638, *YYCURSOR); +#line 6066 "Zend/zend_language_scanner.c" +yy630: + YYDEBUG(630, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy639; + if (yych == 'O') goto yy631; if (yych != 'o') goto yy186; -yy639: - YYDEBUG(639, *YYCURSOR); +yy631: + YYDEBUG(631, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy640; + if (yych == 'N') goto yy632; if (yych != 'n') goto yy186; -yy640: - YYDEBUG(640, *YYCURSOR); +yy632: + YYDEBUG(632, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy641; + if (yych == 'C') goto yy633; if (yych != 'c') goto yy186; -yy641: - YYDEBUG(641, *YYCURSOR); +yy633: + YYDEBUG(633, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy642; + if (yych == 'E') goto yy634; if (yych != 'e') goto yy186; -yy642: - YYDEBUG(642, *YYCURSOR); +yy634: + YYDEBUG(634, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(643, *YYCURSOR); + YYDEBUG(635, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1245 "Zend/zend_language_scanner.l" +#line 1241 "Zend/zend_language_scanner.l" { return T_REQUIRE_ONCE; } -#line 6156 "Zend/zend_language_scanner.c" -yy644: - YYDEBUG(644, *YYCURSOR); +#line 6099 "Zend/zend_language_scanner.c" +yy636: + YYDEBUG(636, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy645; + if (yych == 'R') goto yy637; if (yych != 'r') goto yy186; -yy645: - YYDEBUG(645, *YYCURSOR); +yy637: + YYDEBUG(637, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy646; + if (yych == 'N') goto yy638; if (yych != 'n') goto yy186; -yy646: - YYDEBUG(646, *YYCURSOR); +yy638: + YYDEBUG(638, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(647, *YYCURSOR); + YYDEBUG(639, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1015 "Zend/zend_language_scanner.l" { return T_RETURN; } -#line 6179 "Zend/zend_language_scanner.c" -yy648: - YYDEBUG(648, *YYCURSOR); +#line 6122 "Zend/zend_language_scanner.c" +yy640: + YYDEBUG(640, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy670; - goto yy669; + if (yych <= 'S') goto yy662; + goto yy661; } else { if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy670; - if (yych <= 't') goto yy669; + if (yych <= 's') goto yy662; + if (yych <= 't') goto yy661; goto yy186; } -yy649: - YYDEBUG(649, *YYCURSOR); +yy641: + YYDEBUG(641, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'A') goto yy661; + if (yych == 'A') goto yy653; if (yych <= 'N') goto yy186; - goto yy662; + goto yy654; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy661; + goto yy653; } else { - if (yych == 'o') goto yy662; + if (yych == 'o') goto yy654; goto yy186; } } -yy650: - YYDEBUG(650, *YYCURSOR); +yy642: + YYDEBUG(642, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy651; + if (yych == 'N') goto yy643; if (yych != 'n') goto yy186; -yy651: - YYDEBUG(651, *YYCURSOR); +yy643: + YYDEBUG(643, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'R') goto yy186; - if (yych >= 'T') goto yy653; + if (yych >= 'T') goto yy645; } else { if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy652; - if (yych <= 't') goto yy653; + if (yych <= 's') goto yy644; + if (yych <= 't') goto yy645; goto yy186; } -yy652: - YYDEBUG(652, *YYCURSOR); +yy644: + YYDEBUG(644, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy659; - if (yych == 't') goto yy659; + if (yych == 'T') goto yy651; + if (yych == 't') goto yy651; goto yy186; -yy653: - YYDEBUG(653, *YYCURSOR); +yy645: + YYDEBUG(645, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy654; + if (yych == 'I') goto yy646; if (yych != 'i') goto yy186; -yy654: - YYDEBUG(654, *YYCURSOR); +yy646: + YYDEBUG(646, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy655; + if (yych == 'N') goto yy647; if (yych != 'n') goto yy186; -yy655: - YYDEBUG(655, *YYCURSOR); +yy647: + YYDEBUG(647, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy656; + if (yych == 'U') goto yy648; if (yych != 'u') goto yy186; -yy656: - YYDEBUG(656, *YYCURSOR); +yy648: + YYDEBUG(648, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy657; + if (yych == 'E') goto yy649; if (yych != 'e') goto yy186; -yy657: - YYDEBUG(657, *YYCURSOR); +yy649: + YYDEBUG(649, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(658, *YYCURSOR); + YYDEBUG(650, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1111 "Zend/zend_language_scanner.l" { return T_CONTINUE; } -#line 6264 "Zend/zend_language_scanner.c" -yy659: - YYDEBUG(659, *YYCURSOR); +#line 6207 "Zend/zend_language_scanner.c" +yy651: + YYDEBUG(651, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(660, *YYCURSOR); + YYDEBUG(652, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1011 "Zend/zend_language_scanner.l" { return T_CONST; } -#line 6277 "Zend/zend_language_scanner.c" -yy661: - YYDEBUG(661, *YYCURSOR); +#line 6220 "Zend/zend_language_scanner.c" +yy653: + YYDEBUG(653, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy666; - if (yych == 's') goto yy666; + if (yych == 'S') goto yy658; + if (yych == 's') goto yy658; goto yy186; -yy662: - YYDEBUG(662, *YYCURSOR); +yy654: + YYDEBUG(654, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy663; + if (yych == 'N') goto yy655; if (yych != 'n') goto yy186; -yy663: - YYDEBUG(663, *YYCURSOR); +yy655: + YYDEBUG(655, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy664; + if (yych == 'E') goto yy656; if (yych != 'e') goto yy186; -yy664: - YYDEBUG(664, *YYCURSOR); +yy656: + YYDEBUG(656, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(665, *YYCURSOR); + YYDEBUG(657, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1189 "Zend/zend_language_scanner.l" { return T_CLONE; } -#line 6306 "Zend/zend_language_scanner.c" -yy666: - YYDEBUG(666, *YYCURSOR); +#line 6249 "Zend/zend_language_scanner.c" +yy658: + YYDEBUG(658, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy667; + if (yych == 'S') goto yy659; if (yych != 's') goto yy186; -yy667: - YYDEBUG(667, *YYCURSOR); +yy659: + YYDEBUG(659, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(668, *YYCURSOR); + YYDEBUG(660, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1127 "Zend/zend_language_scanner.l" { return T_CLASS; } -#line 6324 "Zend/zend_language_scanner.c" -yy669: - YYDEBUG(669, *YYCURSOR); +#line 6267 "Zend/zend_language_scanner.c" +yy661: + YYDEBUG(661, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy673; - if (yych == 'c') goto yy673; + if (yych == 'C') goto yy665; + if (yych == 'c') goto yy665; goto yy186; -yy670: - YYDEBUG(670, *YYCURSOR); +yy662: + YYDEBUG(662, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy671; + if (yych == 'E') goto yy663; if (yych != 'e') goto yy186; -yy671: - YYDEBUG(671, *YYCURSOR); +yy663: + YYDEBUG(663, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(672, *YYCURSOR); + YYDEBUG(664, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1099 "Zend/zend_language_scanner.l" { return T_CASE; } -#line 6348 "Zend/zend_language_scanner.c" -yy673: - YYDEBUG(673, *YYCURSOR); +#line 6291 "Zend/zend_language_scanner.c" +yy665: + YYDEBUG(665, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy674; + if (yych == 'H') goto yy666; if (yych != 'h') goto yy186; -yy674: - YYDEBUG(674, *YYCURSOR); +yy666: + YYDEBUG(666, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(675, *YYCURSOR); + YYDEBUG(667, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1023 "Zend/zend_language_scanner.l" { return T_CATCH; } -#line 6366 "Zend/zend_language_scanner.c" -yy676: - YYDEBUG(676, *YYCURSOR); +#line 6309 "Zend/zend_language_scanner.c" +yy668: + YYDEBUG(668, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy693; - if (yych == 'n') goto yy693; + if (yych == 'N') goto yy685; + if (yych == 'n') goto yy685; goto yy186; -yy677: - YYDEBUG(677, *YYCURSOR); +yy669: + YYDEBUG(669, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy686; - if (yych == 'r') goto yy686; + if (yych == 'R') goto yy678; + if (yych == 'r') goto yy678; goto yy186; -yy678: - YYDEBUG(678, *YYCURSOR); +yy670: + YYDEBUG(670, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy679; + if (yych == 'N') goto yy671; if (yych != 'n') goto yy186; -yy679: - YYDEBUG(679, *YYCURSOR); +yy671: + YYDEBUG(671, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy680; + if (yych == 'C') goto yy672; if (yych != 'c') goto yy186; -yy680: - YYDEBUG(680, *YYCURSOR); +yy672: + YYDEBUG(672, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy681; + if (yych == 'T') goto yy673; if (yych != 't') goto yy186; -yy681: - YYDEBUG(681, *YYCURSOR); +yy673: + YYDEBUG(673, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy682; + if (yych == 'I') goto yy674; if (yych != 'i') goto yy186; -yy682: - YYDEBUG(682, *YYCURSOR); +yy674: + YYDEBUG(674, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy683; + if (yych == 'O') goto yy675; if (yych != 'o') goto yy186; -yy683: - YYDEBUG(683, *YYCURSOR); +yy675: + YYDEBUG(675, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy684; + if (yych == 'N') goto yy676; if (yych != 'n') goto yy186; -yy684: - YYDEBUG(684, *YYCURSOR); +yy676: + YYDEBUG(676, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(685, *YYCURSOR); + YYDEBUG(677, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1007 "Zend/zend_language_scanner.l" { return T_FUNCTION; } -#line 6421 "Zend/zend_language_scanner.c" -yy686: - YYDEBUG(686, *YYCURSOR); +#line 6364 "Zend/zend_language_scanner.c" +yy678: + YYDEBUG(678, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy687; + if (yych <= '/') goto yy679; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy688; + if (yych == 'E') goto yy680; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy688; + if (yych <= 'e') goto yy680; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy687: - YYDEBUG(687, *YYCURSOR); +yy679: + YYDEBUG(679, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1059 "Zend/zend_language_scanner.l" { return T_FOR; } -#line 6449 "Zend/zend_language_scanner.c" -yy688: - YYDEBUG(688, *YYCURSOR); +#line 6392 "Zend/zend_language_scanner.c" +yy680: + YYDEBUG(680, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy689; + if (yych == 'A') goto yy681; if (yych != 'a') goto yy186; -yy689: - YYDEBUG(689, *YYCURSOR); +yy681: + YYDEBUG(681, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy690; + if (yych == 'C') goto yy682; if (yych != 'c') goto yy186; -yy690: - YYDEBUG(690, *YYCURSOR); +yy682: + YYDEBUG(682, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy691; + if (yych == 'H') goto yy683; if (yych != 'h') goto yy186; -yy691: - YYDEBUG(691, *YYCURSOR); +yy683: + YYDEBUG(683, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(692, *YYCURSOR); + YYDEBUG(684, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1067 "Zend/zend_language_scanner.l" { return T_FOREACH; } -#line 6477 "Zend/zend_language_scanner.c" -yy693: - YYDEBUG(693, *YYCURSOR); +#line 6420 "Zend/zend_language_scanner.c" +yy685: + YYDEBUG(685, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy694; + if (yych == 'A') goto yy686; if (yych != 'a') goto yy186; -yy694: - YYDEBUG(694, *YYCURSOR); +yy686: + YYDEBUG(686, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy695; + if (yych == 'L') goto yy687; if (yych != 'l') goto yy186; -yy695: - YYDEBUG(695, *YYCURSOR); +yy687: + YYDEBUG(687, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(696, *YYCURSOR); + YYDEBUG(688, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1285 "Zend/zend_language_scanner.l" +#line 1281 "Zend/zend_language_scanner.l" { return T_FINAL; } -#line 6500 "Zend/zend_language_scanner.c" -yy697: - YYDEBUG(697, *YYCURSOR); +#line 6443 "Zend/zend_language_scanner.c" +yy689: + YYDEBUG(689, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'F') { - if (yych == 'C') goto yy703; + if (yych == 'C') goto yy695; if (yych <= 'E') goto yy186; - goto yy704; + goto yy696; } else { if (yych <= 'c') { if (yych <= 'b') goto yy186; - goto yy703; + goto yy695; } else { - if (yych == 'f') goto yy704; + if (yych == 'f') goto yy696; goto yy186; } } -yy698: - YYDEBUG(698, *YYCURSOR); +yy690: + YYDEBUG(690, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy701; - if (yych == 'e') goto yy701; + if (yych == 'E') goto yy693; + if (yych == 'e') goto yy693; goto yy186; -yy699: - YYDEBUG(699, *YYCURSOR); +yy691: + YYDEBUG(691, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(700, *YYCURSOR); + YYDEBUG(692, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1055 "Zend/zend_language_scanner.l" { return T_DO; } -#line 6535 "Zend/zend_language_scanner.c" -yy701: - YYDEBUG(701, *YYCURSOR); +#line 6478 "Zend/zend_language_scanner.c" +yy693: + YYDEBUG(693, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(702, *YYCURSOR); + YYDEBUG(694, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1003 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6548 "Zend/zend_language_scanner.c" -yy703: - YYDEBUG(703, *YYCURSOR); +#line 6491 "Zend/zend_language_scanner.c" +yy695: + YYDEBUG(695, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy710; - if (yych == 'l') goto yy710; + if (yych == 'L') goto yy702; + if (yych == 'l') goto yy702; goto yy186; -yy704: - YYDEBUG(704, *YYCURSOR); +yy696: + YYDEBUG(696, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy705; + if (yych == 'A') goto yy697; if (yych != 'a') goto yy186; -yy705: - YYDEBUG(705, *YYCURSOR); +yy697: + YYDEBUG(697, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy706; + if (yych == 'U') goto yy698; if (yych != 'u') goto yy186; -yy706: - YYDEBUG(706, *YYCURSOR); +yy698: + YYDEBUG(698, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy707; + if (yych == 'L') goto yy699; if (yych != 'l') goto yy186; -yy707: - YYDEBUG(707, *YYCURSOR); +yy699: + YYDEBUG(699, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy708; + if (yych == 'T') goto yy700; if (yych != 't') goto yy186; -yy708: - YYDEBUG(708, *YYCURSOR); +yy700: + YYDEBUG(700, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(709, *YYCURSOR); + YYDEBUG(701, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1103 "Zend/zend_language_scanner.l" { return T_DEFAULT; } -#line 6587 "Zend/zend_language_scanner.c" -yy710: - YYDEBUG(710, *YYCURSOR); +#line 6530 "Zend/zend_language_scanner.c" +yy702: + YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy711; + if (yych == 'A') goto yy703; if (yych != 'a') goto yy186; -yy711: - YYDEBUG(711, *YYCURSOR); +yy703: + YYDEBUG(703, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy712; + if (yych == 'R') goto yy704; if (yych != 'r') goto yy186; -yy712: - YYDEBUG(712, *YYCURSOR); +yy704: + YYDEBUG(704, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy713; + if (yych == 'E') goto yy705; if (yych != 'e') goto yy186; -yy713: - YYDEBUG(713, *YYCURSOR); +yy705: + YYDEBUG(705, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(714, *YYCURSOR); + YYDEBUG(706, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1075 "Zend/zend_language_scanner.l" { return T_DECLARE; } -#line 6615 "Zend/zend_language_scanner.c" -yy715: - YYDEBUG(715, *YYCURSOR); +#line 6558 "Zend/zend_language_scanner.c" +yy707: + YYDEBUG(707, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy777; - if (yych == 'h') goto yy777; + if (yych == 'H') goto yy769; + if (yych == 'h') goto yy769; goto yy186; -yy716: - YYDEBUG(716, *YYCURSOR); +yy708: + YYDEBUG(708, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy771; - if (yych == 's') goto yy771; + if (yych == 'S') goto yy763; + if (yych == 's') goto yy763; goto yy186; -yy717: - YYDEBUG(717, *YYCURSOR); +yy709: + YYDEBUG(709, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy767; - if (yych == 'p') goto yy767; + if (yych == 'P') goto yy759; + if (yych == 'p') goto yy759; goto yy186; -yy718: - YYDEBUG(718, *YYCURSOR); +yy710: + YYDEBUG(710, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy733; - if (yych == 'd') goto yy733; + if (yych == 'D') goto yy725; + if (yych == 'd') goto yy725; goto yy186; -yy719: - YYDEBUG(719, *YYCURSOR); +yy711: + YYDEBUG(711, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy730; - if (yych == 'a') goto yy730; + if (yych == 'A') goto yy722; + if (yych == 'a') goto yy722; goto yy186; -yy720: - YYDEBUG(720, *YYCURSOR); +yy712: + YYDEBUG(712, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'I') goto yy721; + if (yych == 'I') goto yy713; if (yych <= 'S') goto yy186; - goto yy722; + goto yy714; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; } else { - if (yych == 't') goto yy722; + if (yych == 't') goto yy714; goto yy186; } } -yy721: - YYDEBUG(721, *YYCURSOR); +yy713: + YYDEBUG(713, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy728; - if (yych == 't') goto yy728; + if (yych == 'T') goto yy720; + if (yych == 't') goto yy720; goto yy186; -yy722: - YYDEBUG(722, *YYCURSOR); +yy714: + YYDEBUG(714, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy723; + if (yych == 'E') goto yy715; if (yych != 'e') goto yy186; -yy723: - YYDEBUG(723, *YYCURSOR); +yy715: + YYDEBUG(715, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy724; + if (yych == 'N') goto yy716; if (yych != 'n') goto yy186; -yy724: - YYDEBUG(724, *YYCURSOR); +yy716: + YYDEBUG(716, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy725; + if (yych == 'D') goto yy717; if (yych != 'd') goto yy186; -yy725: - YYDEBUG(725, *YYCURSOR); +yy717: + YYDEBUG(717, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy726; + if (yych == 'S') goto yy718; if (yych != 's') goto yy186; -yy726: - YYDEBUG(726, *YYCURSOR); +yy718: + YYDEBUG(718, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(727, *YYCURSOR); + YYDEBUG(719, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1139 "Zend/zend_language_scanner.l" { return T_EXTENDS; } -#line 6699 "Zend/zend_language_scanner.c" -yy728: - YYDEBUG(728, *YYCURSOR); +#line 6642 "Zend/zend_language_scanner.c" +yy720: + YYDEBUG(720, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(729, *YYCURSOR); + YYDEBUG(721, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 999 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6712 "Zend/zend_language_scanner.c" -yy730: - YYDEBUG(730, *YYCURSOR); +#line 6655 "Zend/zend_language_scanner.c" +yy722: + YYDEBUG(722, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy731; + if (yych == 'L') goto yy723; if (yych != 'l') goto yy186; -yy731: - YYDEBUG(731, *YYCURSOR); +yy723: + YYDEBUG(723, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(732, *YYCURSOR); + YYDEBUG(724, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1229 "Zend/zend_language_scanner.l" +#line 1225 "Zend/zend_language_scanner.l" { return T_EVAL; } -#line 6730 "Zend/zend_language_scanner.c" -yy733: - YYDEBUG(733, *YYCURSOR); +#line 6673 "Zend/zend_language_scanner.c" +yy725: + YYDEBUG(725, *YYCURSOR); yych = *++YYCURSOR; YYDEBUG(-1, yych); switch (yych) { case 'D': - case 'd': goto yy734; + case 'd': goto yy726; case 'F': - case 'f': goto yy735; + case 'f': goto yy727; case 'I': - case 'i': goto yy736; + case 'i': goto yy728; case 'S': - case 's': goto yy737; + case 's': goto yy729; case 'W': - case 'w': goto yy738; + case 'w': goto yy730; default: goto yy186; } -yy734: - YYDEBUG(734, *YYCURSOR); +yy726: + YYDEBUG(726, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy760; - if (yych == 'e') goto yy760; + if (yych == 'E') goto yy752; + if (yych == 'e') goto yy752; goto yy186; -yy735: - YYDEBUG(735, *YYCURSOR); +yy727: + YYDEBUG(727, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy752; - if (yych == 'o') goto yy752; + if (yych == 'O') goto yy744; + if (yych == 'o') goto yy744; goto yy186; -yy736: - YYDEBUG(736, *YYCURSOR); +yy728: + YYDEBUG(728, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy750; - if (yych == 'f') goto yy750; + if (yych == 'F') goto yy742; + if (yych == 'f') goto yy742; goto yy186; -yy737: - YYDEBUG(737, *YYCURSOR); +yy729: + YYDEBUG(729, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy744; - if (yych == 'w') goto yy744; + if (yych == 'W') goto yy736; + if (yych == 'w') goto yy736; goto yy186; -yy738: - YYDEBUG(738, *YYCURSOR); +yy730: + YYDEBUG(730, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy739; + if (yych == 'H') goto yy731; if (yych != 'h') goto yy186; -yy739: - YYDEBUG(739, *YYCURSOR); +yy731: + YYDEBUG(731, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy740; + if (yych == 'I') goto yy732; if (yych != 'i') goto yy186; -yy740: - YYDEBUG(740, *YYCURSOR); +yy732: + YYDEBUG(732, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy741; + if (yych == 'L') goto yy733; if (yych != 'l') goto yy186; -yy741: - YYDEBUG(741, *YYCURSOR); +yy733: + YYDEBUG(733, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy742; + if (yych == 'E') goto yy734; if (yych != 'e') goto yy186; -yy742: - YYDEBUG(742, *YYCURSOR); +yy734: + YYDEBUG(734, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(743, *YYCURSOR); + YYDEBUG(735, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1051 "Zend/zend_language_scanner.l" { return T_ENDWHILE; } -#line 6804 "Zend/zend_language_scanner.c" -yy744: - YYDEBUG(744, *YYCURSOR); +#line 6747 "Zend/zend_language_scanner.c" +yy736: + YYDEBUG(736, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy745; + if (yych == 'I') goto yy737; if (yych != 'i') goto yy186; -yy745: - YYDEBUG(745, *YYCURSOR); +yy737: + YYDEBUG(737, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy746; + if (yych == 'T') goto yy738; if (yych != 't') goto yy186; -yy746: - YYDEBUG(746, *YYCURSOR); +yy738: + YYDEBUG(738, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy747; + if (yych == 'C') goto yy739; if (yych != 'c') goto yy186; -yy747: - YYDEBUG(747, *YYCURSOR); +yy739: + YYDEBUG(739, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy748; + if (yych == 'H') goto yy740; if (yych != 'h') goto yy186; -yy748: - YYDEBUG(748, *YYCURSOR); +yy740: + YYDEBUG(740, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(749, *YYCURSOR); + YYDEBUG(741, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1095 "Zend/zend_language_scanner.l" { return T_ENDSWITCH; } -#line 6837 "Zend/zend_language_scanner.c" -yy750: - YYDEBUG(750, *YYCURSOR); +#line 6780 "Zend/zend_language_scanner.c" +yy742: + YYDEBUG(742, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(751, *YYCURSOR); + YYDEBUG(743, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1039 "Zend/zend_language_scanner.l" { return T_ENDIF; } -#line 6850 "Zend/zend_language_scanner.c" -yy752: - YYDEBUG(752, *YYCURSOR); +#line 6793 "Zend/zend_language_scanner.c" +yy744: + YYDEBUG(744, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy753; + if (yych == 'R') goto yy745; if (yych != 'r') goto yy186; -yy753: - YYDEBUG(753, *YYCURSOR); +yy745: + YYDEBUG(745, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy754; + if (yych <= '/') goto yy746; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy755; + if (yych == 'E') goto yy747; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy755; + if (yych <= 'e') goto yy747; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy754: - YYDEBUG(754, *YYCURSOR); +yy746: + YYDEBUG(746, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1063 "Zend/zend_language_scanner.l" { return T_ENDFOR; } -#line 6883 "Zend/zend_language_scanner.c" -yy755: - YYDEBUG(755, *YYCURSOR); +#line 6826 "Zend/zend_language_scanner.c" +yy747: + YYDEBUG(747, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy756; + if (yych == 'A') goto yy748; if (yych != 'a') goto yy186; -yy756: - YYDEBUG(756, *YYCURSOR); +yy748: + YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy757; + if (yych == 'C') goto yy749; if (yych != 'c') goto yy186; -yy757: - YYDEBUG(757, *YYCURSOR); +yy749: + YYDEBUG(749, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy758; + if (yych == 'H') goto yy750; if (yych != 'h') goto yy186; -yy758: - YYDEBUG(758, *YYCURSOR); +yy750: + YYDEBUG(750, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(759, *YYCURSOR); + YYDEBUG(751, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1071 "Zend/zend_language_scanner.l" { return T_ENDFOREACH; } -#line 6911 "Zend/zend_language_scanner.c" -yy760: - YYDEBUG(760, *YYCURSOR); +#line 6854 "Zend/zend_language_scanner.c" +yy752: + YYDEBUG(752, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy761; + if (yych == 'C') goto yy753; if (yych != 'c') goto yy186; -yy761: - YYDEBUG(761, *YYCURSOR); +yy753: + YYDEBUG(753, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy762; + if (yych == 'L') goto yy754; if (yych != 'l') goto yy186; -yy762: - YYDEBUG(762, *YYCURSOR); +yy754: + YYDEBUG(754, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy763; + if (yych == 'A') goto yy755; if (yych != 'a') goto yy186; -yy763: - YYDEBUG(763, *YYCURSOR); +yy755: + YYDEBUG(755, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy764; + if (yych == 'R') goto yy756; if (yych != 'r') goto yy186; -yy764: - YYDEBUG(764, *YYCURSOR); +yy756: + YYDEBUG(756, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy765; + if (yych == 'E') goto yy757; if (yych != 'e') goto yy186; -yy765: - YYDEBUG(765, *YYCURSOR); +yy757: + YYDEBUG(757, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(766, *YYCURSOR); + YYDEBUG(758, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1079 "Zend/zend_language_scanner.l" { return T_ENDDECLARE; } -#line 6949 "Zend/zend_language_scanner.c" -yy767: - YYDEBUG(767, *YYCURSOR); +#line 6892 "Zend/zend_language_scanner.c" +yy759: + YYDEBUG(759, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy768; + if (yych == 'T') goto yy760; if (yych != 't') goto yy186; -yy768: - YYDEBUG(768, *YYCURSOR); +yy760: + YYDEBUG(760, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy769; + if (yych == 'Y') goto yy761; if (yych != 'y') goto yy186; -yy769: - YYDEBUG(769, *YYCURSOR); +yy761: + YYDEBUG(761, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(770, *YYCURSOR); + YYDEBUG(762, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1269 "Zend/zend_language_scanner.l" +#line 1265 "Zend/zend_language_scanner.l" { return T_EMPTY; } -#line 6972 "Zend/zend_language_scanner.c" -yy771: - YYDEBUG(771, *YYCURSOR); +#line 6915 "Zend/zend_language_scanner.c" +yy763: + YYDEBUG(763, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy772; + if (yych == 'E') goto yy764; if (yych != 'e') goto yy186; -yy772: - YYDEBUG(772, *YYCURSOR); +yy764: + YYDEBUG(764, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy773; + if (yych <= '/') goto yy765; if (yych <= '9') goto yy185; } else { - if (yych == 'I') goto yy774; + if (yych == 'I') goto yy766; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'h') { if (yych != '`') goto yy185; } else { - if (yych <= 'i') goto yy774; + if (yych <= 'i') goto yy766; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy773: - YYDEBUG(773, *YYCURSOR); +yy765: + YYDEBUG(765, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1043 "Zend/zend_language_scanner.l" { return T_ELSE; } -#line 7005 "Zend/zend_language_scanner.c" -yy774: - YYDEBUG(774, *YYCURSOR); +#line 6948 "Zend/zend_language_scanner.c" +yy766: + YYDEBUG(766, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy775; + if (yych == 'F') goto yy767; if (yych != 'f') goto yy186; -yy775: - YYDEBUG(775, *YYCURSOR); +yy767: + YYDEBUG(767, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(776, *YYCURSOR); + YYDEBUG(768, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1035 "Zend/zend_language_scanner.l" { return T_ELSEIF; } -#line 7023 "Zend/zend_language_scanner.c" -yy777: - YYDEBUG(777, *YYCURSOR); +#line 6966 "Zend/zend_language_scanner.c" +yy769: + YYDEBUG(769, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy778; + if (yych == 'O') goto yy770; if (yych != 'o') goto yy186; -yy778: - YYDEBUG(778, *YYCURSOR); +yy770: + YYDEBUG(770, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 8) { goto yy185; } - YYDEBUG(779, *YYCURSOR); + YYDEBUG(771, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1119 "Zend/zend_language_scanner.l" { return T_ECHO; } -#line 7041 "Zend/zend_language_scanner.c" +#line 6984 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7076,39 +7019,39 @@ int lex_scan(zval *zendlval TSRMLS_DC) 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, }; - YYDEBUG(780, *YYCURSOR); + YYDEBUG(772, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '-') { if (yych <= '\r') { - if (yych <= 0x08) goto yy788; - if (yych <= '\n') goto yy782; - if (yych <= '\f') goto yy788; + if (yych <= 0x08) goto yy780; + if (yych <= '\n') goto yy774; + if (yych <= '\f') goto yy780; } else { - if (yych == ' ') goto yy782; - if (yych <= ',') goto yy788; - goto yy784; + if (yych == ' ') goto yy774; + if (yych <= ',') goto yy780; + goto yy776; } } else { if (yych <= '_') { - if (yych <= '@') goto yy788; - if (yych <= 'Z') goto yy786; - if (yych <= '^') goto yy788; - goto yy786; + if (yych <= '@') goto yy780; + if (yych <= 'Z') goto yy778; + if (yych <= '^') goto yy780; + goto yy778; } else { - if (yych <= '`') goto yy788; - if (yych <= 'z') goto yy786; - if (yych <= '~') goto yy788; - goto yy786; + if (yych <= '`') goto yy780; + if (yych <= 'z') goto yy778; + if (yych <= '~') goto yy780; + goto yy778; } } -yy782: - YYDEBUG(782, *YYCURSOR); +yy774: + YYDEBUG(774, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy794; -yy783: - YYDEBUG(783, *YYCURSOR); + goto yy786; +yy775: + YYDEBUG(775, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1152 "Zend/zend_language_scanner.l" { @@ -7118,13 +7061,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7122 "Zend/zend_language_scanner.c" -yy784: - YYDEBUG(784, *YYCURSOR); +#line 7065 "Zend/zend_language_scanner.c" +yy776: + YYDEBUG(776, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '>') goto yy791; -yy785: - YYDEBUG(785, *YYCURSOR); + if ((yych = *YYCURSOR) == '>') goto yy783; +yy777: + YYDEBUG(777, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1171 "Zend/zend_language_scanner.l" { @@ -7132,14 +7075,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_pop_state(TSRMLS_C); goto restart; } -#line 7136 "Zend/zend_language_scanner.c" -yy786: - YYDEBUG(786, *YYCURSOR); +#line 7079 "Zend/zend_language_scanner.c" +yy778: + YYDEBUG(778, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy790; -yy787: - YYDEBUG(787, *YYCURSOR); + goto yy782; +yy779: + YYDEBUG(779, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1164 "Zend/zend_language_scanner.l" { @@ -7148,43 +7091,43 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_STRING; } -#line 7152 "Zend/zend_language_scanner.c" -yy788: - YYDEBUG(788, *YYCURSOR); +#line 7095 "Zend/zend_language_scanner.c" +yy780: + YYDEBUG(780, *YYCURSOR); yych = *++YYCURSOR; - goto yy785; -yy789: - YYDEBUG(789, *YYCURSOR); + goto yy777; +yy781: + YYDEBUG(781, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy790: - YYDEBUG(790, *YYCURSOR); +yy782: + YYDEBUG(782, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy789; + goto yy781; } - goto yy787; -yy791: - YYDEBUG(791, *YYCURSOR); + goto yy779; +yy783: + YYDEBUG(783, *YYCURSOR); ++YYCURSOR; - YYDEBUG(792, *YYCURSOR); + YYDEBUG(784, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1160 "Zend/zend_language_scanner.l" { return T_OBJECT_OPERATOR; } -#line 7177 "Zend/zend_language_scanner.c" -yy793: - YYDEBUG(793, *YYCURSOR); +#line 7120 "Zend/zend_language_scanner.c" +yy785: + YYDEBUG(785, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy794: - YYDEBUG(794, *YYCURSOR); +yy786: + YYDEBUG(786, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy793; + goto yy785; } - goto yy783; + goto yy775; } /* *********************************** */ yyc_ST_LOOKING_FOR_VARNAME: @@ -7223,27 +7166,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; - YYDEBUG(795, *YYCURSOR); + YYDEBUG(787, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '_') { - if (yych <= '@') goto yy799; - if (yych <= 'Z') goto yy797; - if (yych <= '^') goto yy799; + if (yych <= '@') goto yy791; + if (yych <= 'Z') goto yy789; + if (yych <= '^') goto yy791; } else { - if (yych <= '`') goto yy799; - if (yych <= 'z') goto yy797; - if (yych <= '~') goto yy799; + if (yych <= '`') goto yy791; + if (yych <= 'z') goto yy789; + if (yych <= '~') goto yy791; } -yy797: - YYDEBUG(797, *YYCURSOR); +yy789: + YYDEBUG(789, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy802; -yy798: - YYDEBUG(798, *YYCURSOR); + goto yy794; +yy790: + YYDEBUG(790, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1447 "Zend/zend_language_scanner.l" +#line 1443 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -7251,42 +7194,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7255 "Zend/zend_language_scanner.c" -yy799: - YYDEBUG(799, *YYCURSOR); +#line 7198 "Zend/zend_language_scanner.c" +yy791: + YYDEBUG(791, *YYCURSOR); ++YYCURSOR; - YYDEBUG(800, *YYCURSOR); + YYDEBUG(792, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1456 "Zend/zend_language_scanner.l" +#line 1452 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7268 "Zend/zend_language_scanner.c" -yy801: - YYDEBUG(801, *YYCURSOR); +#line 7211 "Zend/zend_language_scanner.c" +yy793: + YYDEBUG(793, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy802: - YYDEBUG(802, *YYCURSOR); +yy794: + YYDEBUG(794, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy801; + goto yy793; } - goto yy798; + goto yy790; } /* *********************************** */ yyc_ST_NOWDOC: - YYDEBUG(803, *YYCURSOR); + YYDEBUG(795, *YYCURSOR); YYFILL(1); yych = *YYCURSOR; - YYDEBUG(805, *YYCURSOR); + YYDEBUG(797, *YYCURSOR); ++YYCURSOR; - YYDEBUG(806, *YYCURSOR); + YYDEBUG(798, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2283 "Zend/zend_language_scanner.l" +#line 2275 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7341,7 +7284,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7345 "Zend/zend_language_scanner.c" +#line 7288 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7379,69 +7322,69 @@ int lex_scan(zval *zendlval TSRMLS_DC) 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, }; - YYDEBUG(807, *YYCURSOR); + YYDEBUG(799, *YYCURSOR); YYFILL(3); yych = *YYCURSOR; if (yych <= '/') { if (yych <= ' ') { if (yych <= '\f') { - if (yych <= 0x08) goto yy821; - if (yych <= '\n') goto yy817; - goto yy821; + if (yych <= 0x08) goto yy813; + if (yych <= '\n') goto yy809; + goto yy813; } else { - if (yych <= '\r') goto yy817; - if (yych <= 0x1F) goto yy821; - goto yy817; + if (yych <= '\r') goto yy809; + if (yych <= 0x1F) goto yy813; + goto yy809; } } else { if (yych <= '$') { - if (yych <= '"') goto yy816; - if (yych <= '#') goto yy817; - goto yy812; + if (yych <= '"') goto yy808; + if (yych <= '#') goto yy809; + goto yy804; } else { - if (yych == '\'') goto yy817; - goto yy816; + if (yych == '\'') goto yy809; + goto yy808; } } } else { if (yych <= '\\') { if (yych <= '@') { - if (yych <= '0') goto yy809; - if (yych <= '9') goto yy811; - goto yy816; + if (yych <= '0') goto yy801; + if (yych <= '9') goto yy803; + goto yy808; } else { - if (yych <= 'Z') goto yy819; - if (yych <= '[') goto yy816; - goto yy817; + if (yych <= 'Z') goto yy811; + if (yych <= '[') goto yy808; + goto yy809; } } else { if (yych <= '_') { - if (yych <= ']') goto yy814; - if (yych <= '^') goto yy816; - goto yy819; + if (yych <= ']') goto yy806; + if (yych <= '^') goto yy808; + goto yy811; } else { - if (yych <= '`') goto yy816; - if (yych <= 'z') goto yy819; - if (yych <= '~') goto yy816; - goto yy819; + if (yych <= '`') goto yy808; + if (yych <= 'z') goto yy811; + if (yych <= '~') goto yy808; + goto yy811; } } } -yy809: - YYDEBUG(809, *YYCURSOR); +yy801: + YYDEBUG(801, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 'W') { - if (yych <= '/') goto yy810; - if (yych <= '9') goto yy832; + if (yych <= '/') goto yy802; + if (yych <= '9') goto yy824; } else { - if (yych <= 'X') goto yy830; - if (yych == 'x') goto yy830; + if (yych <= 'X') goto yy822; + if (yych == 'x') goto yy822; } -yy810: - YYDEBUG(810, *YYCURSOR); +yy802: + YYDEBUG(802, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1506 "Zend/zend_language_scanner.l" +#line 1502 "Zend/zend_language_scanner.l" { /* Offset could be treated as a long */ if (yyleng < MAX_LENGTH_OF_LONG - 1 || (yyleng == MAX_LENGTH_OF_LONG - 1 && strcmp(yytext, long_min_digits) < 0)) { zendlval->value.lval = strtol(yytext, NULL, 10); @@ -7453,81 +7396,81 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7457 "Zend/zend_language_scanner.c" -yy811: - YYDEBUG(811, *YYCURSOR); +#line 7400 "Zend/zend_language_scanner.c" +yy803: + YYDEBUG(803, *YYCURSOR); yych = *++YYCURSOR; - goto yy829; -yy812: - YYDEBUG(812, *YYCURSOR); + goto yy821; +yy804: + YYDEBUG(804, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '_') { - if (yych <= '@') goto yy813; - if (yych <= 'Z') goto yy825; - if (yych >= '_') goto yy825; + if (yych <= '@') goto yy805; + if (yych <= 'Z') goto yy817; + if (yych >= '_') goto yy817; } else { - if (yych <= '`') goto yy813; - if (yych <= 'z') goto yy825; - if (yych >= 0x7F) goto yy825; + if (yych <= '`') goto yy805; + if (yych <= 'z') goto yy817; + if (yych >= 0x7F) goto yy817; } -yy813: - YYDEBUG(813, *YYCURSOR); +yy805: + YYDEBUG(805, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1811 "Zend/zend_language_scanner.l" +#line 1803 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7482 "Zend/zend_language_scanner.c" -yy814: - YYDEBUG(814, *YYCURSOR); +#line 7425 "Zend/zend_language_scanner.c" +yy806: + YYDEBUG(806, *YYCURSOR); ++YYCURSOR; - YYDEBUG(815, *YYCURSOR); + YYDEBUG(807, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1806 "Zend/zend_language_scanner.l" +#line 1798 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7493 "Zend/zend_language_scanner.c" -yy816: - YYDEBUG(816, *YYCURSOR); +#line 7436 "Zend/zend_language_scanner.c" +yy808: + YYDEBUG(808, *YYCURSOR); yych = *++YYCURSOR; - goto yy813; -yy817: - YYDEBUG(817, *YYCURSOR); + goto yy805; +yy809: + YYDEBUG(809, *YYCURSOR); ++YYCURSOR; - YYDEBUG(818, *YYCURSOR); + YYDEBUG(810, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1816 "Zend/zend_language_scanner.l" +#line 1808 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7510 "Zend/zend_language_scanner.c" -yy819: - YYDEBUG(819, *YYCURSOR); +#line 7453 "Zend/zend_language_scanner.c" +yy811: + YYDEBUG(811, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy824; -yy820: - YYDEBUG(820, *YYCURSOR); + goto yy816; +yy812: + YYDEBUG(812, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1823 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7525 "Zend/zend_language_scanner.c" -yy821: - YYDEBUG(821, *YYCURSOR); +#line 7468 "Zend/zend_language_scanner.c" +yy813: + YYDEBUG(813, *YYCURSOR); ++YYCURSOR; - YYDEBUG(822, *YYCURSOR); + YYDEBUG(814, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2339 "Zend/zend_language_scanner.l" +#line 2331 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7536,100 +7479,100 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7540 "Zend/zend_language_scanner.c" -yy823: - YYDEBUG(823, *YYCURSOR); +#line 7483 "Zend/zend_language_scanner.c" +yy815: + YYDEBUG(815, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy824: - YYDEBUG(824, *YYCURSOR); +yy816: + YYDEBUG(816, *YYCURSOR); if (yybm[0+yych] & 32) { - goto yy823; + goto yy815; } - goto yy820; -yy825: - YYDEBUG(825, *YYCURSOR); + goto yy812; +yy817: + YYDEBUG(817, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(826, *YYCURSOR); + YYDEBUG(818, *YYCURSOR); if (yych <= '^') { if (yych <= '9') { - if (yych >= '0') goto yy825; + if (yych >= '0') goto yy817; } else { - if (yych <= '@') goto yy827; - if (yych <= 'Z') goto yy825; + if (yych <= '@') goto yy819; + if (yych <= 'Z') goto yy817; } } else { if (yych <= '`') { - if (yych <= '_') goto yy825; + if (yych <= '_') goto yy817; } else { - if (yych <= 'z') goto yy825; - if (yych >= 0x7F) goto yy825; + if (yych <= 'z') goto yy817; + if (yych >= 0x7F) goto yy817; } } -yy827: - YYDEBUG(827, *YYCURSOR); +yy819: + YYDEBUG(819, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1800 "Zend/zend_language_scanner.l" +#line 1792 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7582 "Zend/zend_language_scanner.c" -yy828: - YYDEBUG(828, *YYCURSOR); +#line 7525 "Zend/zend_language_scanner.c" +yy820: + YYDEBUG(820, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy829: - YYDEBUG(829, *YYCURSOR); +yy821: + YYDEBUG(821, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy828; + goto yy820; } - goto yy810; -yy830: - YYDEBUG(830, *YYCURSOR); + goto yy802; +yy822: + YYDEBUG(822, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 128) { - goto yy835; + goto yy827; } - YYDEBUG(831, *YYCURSOR); + YYDEBUG(823, *YYCURSOR); YYCURSOR = YYMARKER; - goto yy810; -yy832: - YYDEBUG(832, *YYCURSOR); + goto yy802; +yy824: + YYDEBUG(824, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(833, *YYCURSOR); - if (yych <= '/') goto yy834; - if (yych <= '9') goto yy832; -yy834: - YYDEBUG(834, *YYCURSOR); + YYDEBUG(825, *YYCURSOR); + if (yych <= '/') goto yy826; + if (yych <= '9') goto yy824; +yy826: + YYDEBUG(826, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1518 "Zend/zend_language_scanner.l" +#line 1514 "Zend/zend_language_scanner.l" { /* Offset must be treated as a string */ zendlval->value.str.val = (char *)estrndup(yytext, yyleng); zendlval->value.str.len = yyleng; zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7621 "Zend/zend_language_scanner.c" -yy835: - YYDEBUG(835, *YYCURSOR); +#line 7564 "Zend/zend_language_scanner.c" +yy827: + YYDEBUG(827, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(836, *YYCURSOR); + YYDEBUG(828, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy835; + goto yy827; } - goto yy834; + goto yy826; } } -#line 2348 "Zend/zend_language_scanner.l" +#line 2340 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index d504e11071eac..cd329c61f942c 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1206,10 +1206,6 @@ NEWLINE ("\r"|"\n"|"\r\n") return T_STRING_CAST; } -"("{TABS_AND_SPACES}"scalar"{TABS_AND_SPACES}")" { - return T_SCALAR_CAST; -} - "("{TABS_AND_SPACES}"array"{TABS_AND_SPACES}")" { return T_ARRAY_CAST; } diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 8ad31d30b71f2..6f3efea38856a 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun May 8 16:20:00 2011 */ +/* Generated by re2c 0.13.5 on Thu Jun 2 18:02:57 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_variables.c b/Zend/zend_variables.c index 5e500ea635fab..3740f473a2d84 100644 --- a/Zend/zend_variables.c +++ b/Zend/zend_variables.c @@ -32,7 +32,6 @@ ZEND_API void _zval_dtor_func(zval *zvalue ZEND_FILE_LINE_DC) switch (Z_TYPE_P(zvalue) & IS_CONSTANT_TYPE_MASK) { case IS_STRING: case IS_CONSTANT: - case IS_CLASS: CHECK_ZVAL_STRING_REL(zvalue); STR_FREE_REL(zvalue->value.str.val); break; From aa29bd5d738132164dc25f02731eb9199ed40fb1 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Fri, 3 Jun 2011 01:16:01 +0000 Subject: [PATCH 0092/2394] and clean the tokenizer too --- ext/tokenizer/tokenizer_data.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index 224e52be21f3f..12d8b0a584b81 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -66,8 +66,6 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_ARRAY_CAST", T_ARRAY_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_STRING_CAST", T_STRING_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_DOUBLE_CAST", T_DOUBLE_CAST, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_SCALAR_CAST", T_SCALAR_CAST, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_NUMERIC_CAST", T_NUMERIC_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_INT_CAST", T_INT_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_DEC", T_DEC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_INC", T_INC, CONST_CS | CONST_PERSISTENT); @@ -200,8 +198,6 @@ char *get_token_type_name(int token_type) case T_ARRAY_CAST: return "T_ARRAY_CAST"; case T_STRING_CAST: return "T_STRING_CAST"; case T_DOUBLE_CAST: return "T_DOUBLE_CAST"; - case T_SCALAR_CAST: return "T_SCALAR_CAST"; - case T_NUMERIC_CAST: return "T_NUMERIC_CAST"; case T_INT_CAST: return "T_INT_CAST"; case T_DEC: return "T_DEC"; case T_INC: return "T_INC"; From 14e330556cd4c73282bb9f619dae9b60fb037865 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Fri, 3 Jun 2011 01:44:37 +0000 Subject: [PATCH 0093/2394] Further fix for #54918 - We attach a bunch of submodules loading to the basic MINIT, but if an error occurs during their MINIT we still call the MSHUTDOWN() Other possible fix is that we should halt execution entirely when this happens but this feels a little drastic. Committing to trunk for now --- ext/standard/basic_functions.c | 112 +++++++++++++++++++++------------ 1 file changed, 71 insertions(+), 41 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index b56f85caee5a2..4e9d38c54a51f 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -133,6 +133,8 @@ typedef struct _user_tick_function_entry { static void user_shutdown_function_dtor(php_shutdown_function_entry *shutdown_function_entry); static void user_tick_function_dtor(user_tick_function_entry *tick_function_entry); +static HashTable basic_submodules; + #undef sprintf /* {{{ arginfo */ @@ -3516,6 +3518,31 @@ PHPAPI double php_get_inf(void) /* {{{ */ } /* }}} */ +#define BASIC_MINIT_SUBMODULE(module) \ + if (PHP_MINIT(module)(INIT_FUNC_ARGS_PASSTHRU) == SUCCESS) {\ + zend_hash_add_empty_element(&basic_submodules, #module, strlen(#module)); \ + } + +#define BASIC_RINIT_SUBMODULE(module) \ + if (zend_hash_exists(&basic_submodules, #module, strlen(#module))) { \ + PHP_RINIT(module)(INIT_FUNC_ARGS_PASSTHRU); \ + } + +#define BASIC_MINFO_SUBMODULE(module) \ + if (zend_hash_exists(&basic_submodules, #module, strlen(#module))) { \ + PHP_MINFO(module)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); \ + } + +#define BASIC_RSHUTDOWN_SUBMODULE(module) \ + if (zend_hash_exists(&basic_submodules, #module, strlen(#module))) { \ + PHP_RSHUTDOWN(module)(SHUTDOWN_FUNC_ARGS_PASSTHRU); \ + } + +#define BASIC_MSHUTDOWN_SUBMODULE(module) \ + if (zend_hash_exists(&basic_submodules, #module, strlen(#module))) { \ + PHP_MSHUTDOWN(module)(SHUTDOWN_FUNC_ARGS_PASSTHRU); \ + } + PHP_MINIT_FUNCTION(basic) /* {{{ */ { #ifdef ZTS @@ -3530,6 +3557,8 @@ PHP_MINIT_FUNCTION(basic) /* {{{ */ #endif #endif + zend_hash_init(&basic_submodules, 0, NULL, NULL, 1); + BG(incomplete_class) = incomplete_class_entry = php_create_incomplete_class(TSRMLS_C); REGISTER_LONG_CONSTANT("CONNECTION_ABORTED", PHP_CONNECTION_ABORTED, CONST_CS | CONST_PERSISTENT); @@ -3589,39 +3618,39 @@ PHP_MINIT_FUNCTION(basic) /* {{{ */ register_html_constants(INIT_FUNC_ARGS_PASSTHRU); register_string_constants(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(file)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(pack)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(browscap)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(standard_filters)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(user_filters)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(file) + BASIC_MINIT_SUBMODULE(pack) + BASIC_MINIT_SUBMODULE(browscap) + BASIC_MINIT_SUBMODULE(standard_filters) + BASIC_MINIT_SUBMODULE(user_filters) #if defined(HAVE_LOCALECONV) && defined(ZTS) - PHP_MINIT(localeconv)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(localeconv) #endif #if defined(HAVE_NL_LANGINFO) - PHP_MINIT(nl_langinfo)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(nl_langinfo) #endif #if HAVE_CRYPT - PHP_MINIT(crypt)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(crypt) #endif - PHP_MINIT(lcg)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(lcg) - PHP_MINIT(dir)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(dir) #ifdef HAVE_SYSLOG_H - PHP_MINIT(syslog)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(syslog) #endif - PHP_MINIT(array)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(assert)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(url_scanner_ex)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(array) + BASIC_MINIT_SUBMODULE(assert) + BASIC_MINIT_SUBMODULE(url_scanner_ex) #ifdef PHP_CAN_SUPPORT_PROC_OPEN - PHP_MINIT(proc_open)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(proc_open) #endif - PHP_MINIT(user_streams)(INIT_FUNC_ARGS_PASSTHRU); - PHP_MINIT(imagetypes)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(user_streams) + BASIC_MINIT_SUBMODULE(imagetypes) php_register_url_stream_wrapper("php", &php_stream_php_wrapper TSRMLS_CC); php_register_url_stream_wrapper("file", &php_plain_files_wrapper TSRMLS_CC); @@ -3636,7 +3665,7 @@ PHP_MINIT_FUNCTION(basic) /* {{{ */ #if defined(PHP_WIN32) || (HAVE_DNS_SEARCH_FUNC && !(defined(__BEOS__) || defined(NETWARE))) # if defined(PHP_WIN32) || HAVE_FULL_DNS_FUNCS - PHP_MINIT(dns)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_MINIT_SUBMODULE(dns) # endif #endif @@ -3667,19 +3696,20 @@ PHP_MSHUTDOWN_FUNCTION(basic) /* {{{ */ php_unregister_url_stream_wrapper("ftp" TSRMLS_CC); #endif - PHP_MSHUTDOWN(browscap)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_MSHUTDOWN(array)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_MSHUTDOWN(assert)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_MSHUTDOWN(url_scanner_ex)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_MSHUTDOWN(file)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_MSHUTDOWN(standard_filters)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_MSHUTDOWN_SUBMODULE(browscap) + BASIC_MSHUTDOWN_SUBMODULE(array) + BASIC_MSHUTDOWN_SUBMODULE(assert) + BASIC_MSHUTDOWN_SUBMODULE(url_scanner_ex) + BASIC_MSHUTDOWN_SUBMODULE(file) + BASIC_MSHUTDOWN_SUBMODULE(standard_filters) #if defined(HAVE_LOCALECONV) && defined(ZTS) - PHP_MSHUTDOWN(localeconv)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_MSHUTDOWN_SUBMODULE(localeconv) #endif #if HAVE_CRYPT - PHP_MSHUTDOWN(crypt)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_MSHUTDOWN_SUBMODULE(crypt) #endif + zend_hash_destroy(&basic_submodules); return SUCCESS; } /* }}} */ @@ -3706,12 +3736,12 @@ PHP_RINIT_FUNCTION(basic) /* {{{ */ #endif BG(user_shutdown_function_names) = NULL; - PHP_RINIT(filestat)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_RINIT_SUBMODULE(filestat) #ifdef HAVE_SYSLOG_H - PHP_RINIT(syslog)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_RINIT_SUBMODULE(syslog) #endif - PHP_RINIT(dir)(INIT_FUNC_ARGS_PASSTHRU); - PHP_RINIT(url_scanner_ex)(INIT_FUNC_ARGS_PASSTHRU); + BASIC_RINIT_SUBMODULE(dir) + BASIC_RINIT_SUBMODULE(url_scanner_ex) /* Setup default context */ FG(default_context) = NULL; @@ -3754,17 +3784,17 @@ PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ /* FG(stream_wrappers) and FG(stream_filters) are destroyed * during php_request_shutdown() */ - PHP_RSHUTDOWN(filestat)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_RSHUTDOWN_SUBMODULE(filestat) #ifdef HAVE_SYSLOG_H #ifdef PHP_WIN32 - PHP_RSHUTDOWN(syslog)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_RSHUTDOWN_SUBMODULE(syslog)(SHUTDOWN_FUNC_ARGS_PASSTHRU); #endif #endif - PHP_RSHUTDOWN(assert)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_RSHUTDOWN(url_scanner_ex)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_RSHUTDOWN(streams)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_RSHUTDOWN_SUBMODULE(assert) + BASIC_RSHUTDOWN_SUBMODULE(url_scanner_ex) + BASIC_RSHUTDOWN_SUBMODULE(streams) #ifdef PHP_WIN32 - PHP_RSHUTDOWN(win32_core_globals)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_RSHUTDOWN_SUBMODULE(win32_core_globals) #endif if (BG(user_tick_functions)) { @@ -3773,8 +3803,8 @@ PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ BG(user_tick_functions) = NULL; } - PHP_RSHUTDOWN(user_filters)(SHUTDOWN_FUNC_ARGS_PASSTHRU); - PHP_RSHUTDOWN(browscap)(SHUTDOWN_FUNC_ARGS_PASSTHRU); + BASIC_RSHUTDOWN_SUBMODULE(user_filters) + BASIC_RSHUTDOWN_SUBMODULE(browscap) BG(page_uid) = -1; BG(page_gid) = -1; @@ -3785,10 +3815,10 @@ PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ PHP_MINFO_FUNCTION(basic) /* {{{ */ { php_info_print_table_start(); - PHP_MINFO(dl)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); - PHP_MINFO(mail)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); + BASIC_MINFO_SUBMODULE(dl) + BASIC_MINFO_SUBMODULE(mail) php_info_print_table_end(); - PHP_MINFO(assert)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); + BASIC_MINFO_SUBMODULE(assert) } /* }}} */ From 52e353e9732b00d41111c1d2c488401df0c1ad96 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Fri, 3 Jun 2011 07:00:38 +0000 Subject: [PATCH 0094/2394] Compiler warning fix --- ext/pcntl/php_signal.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/pcntl/php_signal.c b/ext/pcntl/php_signal.c index 2e5ce953168a4..86e5936fade4f 100644 --- a/ext/pcntl/php_signal.c +++ b/ext/pcntl/php_signal.c @@ -20,6 +20,8 @@ #include "TSRM.h" #include "php_signal.h" +#include "Zend/zend.h" +#include "Zend/zend_signal.h" /* php_signal using sigaction is derrived from Advanced Programing * in the Unix Environment by W. Richard Stevens p 298. */ From 2b22017e8f130804e9f70759ae79fa128c5b360c Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Fri, 3 Jun 2011 17:12:59 +0000 Subject: [PATCH 0095/2394] Add tests for broken function arguments --- Zend/tests/function_arguments_001.phpt | 9 +++++++++ Zend/tests/function_arguments_002.phpt | 9 +++++++++ 2 files changed, 18 insertions(+) create mode 100644 Zend/tests/function_arguments_001.phpt create mode 100644 Zend/tests/function_arguments_002.phpt diff --git a/Zend/tests/function_arguments_001.phpt b/Zend/tests/function_arguments_001.phpt new file mode 100644 index 0000000000000..e50635026910d --- /dev/null +++ b/Zend/tests/function_arguments_001.phpt @@ -0,0 +1,9 @@ +--TEST-- +Argument parsing error #001 +--FILE-- + +--EXPECTF-- +Parse error: syntax error, unexpected T_STRING, expecting ')' in %sfunction_arguments.php on line %d + diff --git a/Zend/tests/function_arguments_002.phpt b/Zend/tests/function_arguments_002.phpt new file mode 100644 index 0000000000000..79dd31f3379ca --- /dev/null +++ b/Zend/tests/function_arguments_002.phpt @@ -0,0 +1,9 @@ +--TEST-- +Argument parsing error #002 +--FILE-- + +--EXPECTF-- +Parse error: syntax error, unexpected '/', expecting ')' in %sfunction_arguments_002.php on line %d + From 2dce38f5987c3f013a36cfcfcd534ac18652d4aa Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Fri, 3 Jun 2011 17:18:46 +0000 Subject: [PATCH 0096/2394] Fixed crash and improved signal validation --- ext/pcntl/pcntl.c | 10 ++++++++-- ext/pcntl/tests/pcntl_signal.phpt | 6 ++---- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index d07b9ea047b0e..d2a9130230f9d 100755 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -849,6 +849,11 @@ PHP_FUNCTION(pcntl_signal) return; } + if (signo < 1 || signo > 32) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid signal"); + RETURN_FALSE; + } + if (!PCNTL_G(spares)) { /* since calling malloc() from within a signal handler is not portable, * pre-allocate a few records for recording signals */ @@ -863,9 +868,10 @@ PHP_FUNCTION(pcntl_signal) } /* Special long value case for SIG_DFL and SIG_IGN */ - if (Z_TYPE_P(handle)==IS_LONG) { - if (Z_LVAL_P(handle)!= (long) SIG_DFL && Z_LVAL_P(handle) != (long) SIG_IGN) { + if (Z_TYPE_P(handle) == IS_LONG) { + if (Z_LVAL_P(handle) != (long) SIG_DFL && Z_LVAL_P(handle) != (long) SIG_IGN) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid value for handle argument specified"); + RETURN_FALSE; } if (php_signal(signo, (Sigfunc *) Z_LVAL_P(handle), (int) restart_syscalls) == SIG_ERR) { PCNTL_G(last_error) = errno; diff --git a/ext/pcntl/tests/pcntl_signal.phpt b/ext/pcntl/tests/pcntl_signal.phpt index 977f26fbcc2f5..efd4bba953e00 100644 --- a/ext/pcntl/tests/pcntl_signal.phpt +++ b/ext/pcntl/tests/pcntl_signal.phpt @@ -28,12 +28,10 @@ Warning: pcntl_signal() expects at least 2 parameters, 0 given in %s NULL bool(true) -Warning: pcntl_signal(): Invalid value for handle argument specified in %s - -Warning: pcntl_signal(): Error assigning signal %s +Warning: pcntl_signal(): Invalid signal %s bool(false) -Warning: pcntl_signal(): Error assigning signal %s +Warning: pcntl_signal(): Invalid signal %s bool(false) Warning: pcntl_signal(): not callable is not a callable function name error in %s From df6e8da2a8ac88e86128600a635105192e659856 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Fri, 3 Jun 2011 17:38:37 +0000 Subject: [PATCH 0097/2394] Fix tests #Note to self; do not rename tests just before committing --- Zend/tests/function_arguments_001.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/function_arguments_001.phpt b/Zend/tests/function_arguments_001.phpt index e50635026910d..bf0cd4a206d28 100644 --- a/Zend/tests/function_arguments_001.phpt +++ b/Zend/tests/function_arguments_001.phpt @@ -5,5 +5,5 @@ Argument parsing error #001 function foo($arg1 string) {} ?> --EXPECTF-- -Parse error: syntax error, unexpected T_STRING, expecting ')' in %sfunction_arguments.php on line %d +Parse error: syntax error, unexpected T_STRING, expecting ')' in %sfunction_arguments_001.php on line %d From 53b6c0c8ebc54e1273674d93ee0f5e1438956e3a Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Fri, 3 Jun 2011 18:14:36 +0000 Subject: [PATCH 0098/2394] Show ICU Data version inside phpinfo() --- ext/intl/php_intl.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index fa328cc5afd31..25d93980ef90f 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -711,6 +711,9 @@ PHP_MINFO_FUNCTION( intl ) php_info_print_table_header( 2, "Internationalization support", "enabled" ); php_info_print_table_row( 2, "version", INTL_MODULE_VERSION ); php_info_print_table_row( 2, "ICU version", U_ICU_VERSION ); +#ifdef U_ICU_DATA_VERSION + php_info_print_table_row( 2, "ICU Data version", U_ICU_DATA_VERSION ); +#endif php_info_print_table_end(); /* For the default locale php.ini setting */ From b86161982bf1ee5555e5d7c0ad4b5eed656befcc Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 4 Jun 2011 22:54:40 +0000 Subject: [PATCH 0099/2394] - Fixed bug #54929 (Parse error with single quote in sql comment) --- ext/pdo/pdo_sql_parser.c | 229 ++++++++++++++++++++++-------- ext/pdo/pdo_sql_parser.re | 4 +- ext/pdo_mysql/tests/bug54929.phpt | 74 ++++++++++ 3 files changed, 245 insertions(+), 62 deletions(-) create mode 100644 ext/pdo_mysql/tests/bug54929.phpt diff --git a/ext/pdo/pdo_sql_parser.c b/ext/pdo/pdo_sql_parser.c index 7a30a3178a233..47e28d36f0ea4 100644 --- a/ext/pdo/pdo_sql_parser.c +++ b/ext/pdo/pdo_sql_parser.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.6.dev on Thu Nov 13 14:47:06 2008 */ +/* Generated by re2c 0.13.5 on Sat Jun 4 18:42:25 2011 */ #line 1 "ext/pdo/pdo_sql_parser.re" /* +----------------------------------------------------------------------+ @@ -30,7 +30,7 @@ #define PDO_PARSER_EOI 4 #define RET(i) {s->cur = cursor; return i; } -#define SKIP_ONE(i) {s->cur = s->tok + 1; return 1; } +#define SKIP_ONE(i) {s->cur = s->tok + 1; return i; } #define YYCTYPE unsigned char #define YYCURSOR cursor @@ -47,35 +47,40 @@ static int scan(Scanner *s) char *cursor = s->cur; s->tok = cursor; - #line 55 "ext/pdo/pdo_sql_parser.re" + #line 56 "ext/pdo/pdo_sql_parser.re" #line 55 "ext/pdo/pdo_sql_parser.c" { YYCTYPE yych; + unsigned int yyaccept = 0; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; switch (yych) { - case 0x00: goto yy11; + case 0x00: goto yy13; case '"': goto yy2; case '\'': goto yy4; + case '-': goto yy10; + case '/': goto yy8; case ':': goto yy5; case '?': goto yy6; - default: goto yy8; + default: goto yy11; } yy2: + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych >= 0x01) goto yy26; + if (yych >= 0x01) goto yy43; yy3: -#line 63 "ext/pdo/pdo_sql_parser.re" +#line 64 "ext/pdo/pdo_sql_parser.re" { SKIP_ONE(PDO_PARSER_TEXT); } -#line 75 "ext/pdo/pdo_sql_parser.c" +#line 79 "ext/pdo/pdo_sql_parser.c" yy4: + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 0x00) goto yy3; - goto yy20; + goto yy37; yy5: yych = *++YYCURSOR; switch (yych) { @@ -141,57 +146,156 @@ static int scan(Scanner *s) case 'w': case 'x': case 'y': - case 'z': goto yy16; + case 'z': goto yy33; case ':': - case '?': goto yy13; + case '?': goto yy30; default: goto yy3; } yy6: ++YYCURSOR; switch ((yych = *YYCURSOR)) { case ':': - case '?': goto yy13; + case '?': goto yy30; default: goto yy7; } yy7: -#line 62 "ext/pdo/pdo_sql_parser.re" +#line 63 "ext/pdo/pdo_sql_parser.re" { RET(PDO_PARSER_BIND_POS); } -#line 160 "ext/pdo/pdo_sql_parser.c" +#line 165 "ext/pdo/pdo_sql_parser.c" yy8: + ++YYCURSOR; + switch ((yych = *YYCURSOR)) { + case '*': goto yy20; + default: goto yy12; + } +yy9: +#line 66 "ext/pdo/pdo_sql_parser.re" + { RET(PDO_PARSER_TEXT); } +#line 175 "ext/pdo/pdo_sql_parser.c" +yy10: + yych = *++YYCURSOR; + switch (yych) { + case '-': goto yy15; + default: goto yy12; + } +yy11: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; +yy12: switch (yych) { case 0x00: case '"': case '\'': case ':': - case '?': goto yy10; - default: goto yy8; + case '?': goto yy9; + default: goto yy11; } -yy10: -#line 64 "ext/pdo/pdo_sql_parser.re" - { RET(PDO_PARSER_TEXT); } -#line 176 "ext/pdo/pdo_sql_parser.c" -yy11: +yy13: ++YYCURSOR; -#line 65 "ext/pdo/pdo_sql_parser.re" +#line 67 "ext/pdo/pdo_sql_parser.re" { RET(PDO_PARSER_EOI); } -#line 181 "ext/pdo/pdo_sql_parser.c" -yy13: +#line 199 "ext/pdo/pdo_sql_parser.c" +yy15: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; switch (yych) { + case 0x00: + case '"': + case '\'': case ':': - case '?': goto yy13; + case '?': goto yy18; + case '\n': + case '\r': goto yy11; default: goto yy15; } -yy15: -#line 60 "ext/pdo/pdo_sql_parser.re" +yy17: +#line 65 "ext/pdo/pdo_sql_parser.re" + { RET(PDO_PARSER_TEXT); } +#line 217 "ext/pdo/pdo_sql_parser.c" +yy18: + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + switch (yych) { + case '\n': + case '\r': goto yy17; + default: goto yy18; + } +yy20: + yyaccept = 1; + YYMARKER = ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + switch (yych) { + case 0x00: + case '"': + case '\'': + case ':': + case '?': goto yy22; + case '*': goto yy24; + default: goto yy20; + } +yy22: + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + switch (yych) { + case '*': goto yy27; + default: goto yy22; + } +yy24: + yyaccept = 1; + YYMARKER = ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); + yych = *YYCURSOR; + switch (yych) { + case 0x00: + case '"': + case '\'': + case ':': + case '?': goto yy22; + case '*': goto yy24; + case '/': goto yy26; + default: goto yy20; + } +yy26: + yych = *++YYCURSOR; + switch (yych) { + case 0x00: + case '"': + case '\'': + case ':': + case '?': goto yy17; + default: goto yy11; + } +yy27: + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + switch (yych) { + case '*': goto yy27; + case '/': goto yy29; + default: goto yy22; + } +yy29: + yych = *++YYCURSOR; + goto yy17; +yy30: + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + switch (yych) { + case ':': + case '?': goto yy30; + default: goto yy32; + } +yy32: +#line 61 "ext/pdo/pdo_sql_parser.re" { RET(PDO_PARSER_TEXT); } -#line 194 "ext/pdo/pdo_sql_parser.c" -yy16: +#line 298 "ext/pdo/pdo_sql_parser.c" +yy33: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; @@ -258,62 +362,65 @@ static int scan(Scanner *s) case 'w': case 'x': case 'y': - case 'z': goto yy16; - default: goto yy18; + case 'z': goto yy33; + default: goto yy35; } -yy18: -#line 61 "ext/pdo/pdo_sql_parser.re" +yy35: +#line 62 "ext/pdo/pdo_sql_parser.re" { RET(PDO_PARSER_BIND); } -#line 268 "ext/pdo/pdo_sql_parser.c" -yy19: +#line 372 "ext/pdo/pdo_sql_parser.c" +yy36: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; -yy20: +yy37: switch (yych) { - case 0x00: goto yy21; - case '\'': goto yy23; - case '\\': goto yy22; - default: goto yy19; + case 0x00: goto yy38; + case '\'': goto yy40; + case '\\': goto yy39; + default: goto yy36; } -yy21: +yy38: YYCURSOR = YYMARKER; - goto yy3; -yy22: + switch (yyaccept) { + case 0: goto yy3; + case 1: goto yy9; + } +yy39: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - if (yych <= 0x00) goto yy21; - goto yy19; -yy23: + if (yych <= 0x00) goto yy38; + goto yy36; +yy40: ++YYCURSOR; -#line 59 "ext/pdo/pdo_sql_parser.re" +#line 60 "ext/pdo/pdo_sql_parser.re" { RET(PDO_PARSER_TEXT); } -#line 293 "ext/pdo/pdo_sql_parser.c" -yy25: +#line 400 "ext/pdo/pdo_sql_parser.c" +yy42: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; -yy26: +yy43: switch (yych) { - case 0x00: goto yy21; - case '"': goto yy28; - case '\\': goto yy27; - default: goto yy25; + case 0x00: goto yy38; + case '"': goto yy45; + case '\\': goto yy44; + default: goto yy42; } -yy27: +yy44: ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - if (yych <= 0x00) goto yy21; - goto yy25; -yy28: + if (yych <= 0x00) goto yy38; + goto yy42; +yy45: ++YYCURSOR; -#line 58 "ext/pdo/pdo_sql_parser.re" +#line 59 "ext/pdo/pdo_sql_parser.re" { RET(PDO_PARSER_TEXT); } -#line 315 "ext/pdo/pdo_sql_parser.c" +#line 422 "ext/pdo/pdo_sql_parser.c" } -#line 66 "ext/pdo/pdo_sql_parser.re" +#line 68 "ext/pdo/pdo_sql_parser.re" } diff --git a/ext/pdo/pdo_sql_parser.re b/ext/pdo/pdo_sql_parser.re index a9956db87fe9a..bb7af3575d324 100644 --- a/ext/pdo/pdo_sql_parser.re +++ b/ext/pdo/pdo_sql_parser.re @@ -28,7 +28,7 @@ #define PDO_PARSER_EOI 4 #define RET(i) {s->cur = cursor; return i; } -#define SKIP_ONE(i) {s->cur = s->tok + 1; return 1; } +#define SKIP_ONE(i) {s->cur = s->tok + 1; return i; } #define YYCTYPE unsigned char #define YYCURSOR cursor @@ -48,6 +48,7 @@ static int scan(Scanner *s) /*!re2c BINDCHR = [:][a-zA-Z0-9_]+; QUESTION = [?]; + COMMENTS = ("/*"([^*]+|[*]+[^/*])*[*]*"*/"|"--"[^\r\n]*); SPECIALS = [:?"']; MULTICHAR = [:?]; EOF = [\000]; @@ -61,6 +62,7 @@ static int scan(Scanner *s) BINDCHR { RET(PDO_PARSER_BIND); } QUESTION { RET(PDO_PARSER_BIND_POS); } SPECIALS { SKIP_ONE(PDO_PARSER_TEXT); } + COMMENTS { RET(PDO_PARSER_TEXT); } (ANYNOEOF\SPECIALS)+ { RET(PDO_PARSER_TEXT); } EOF { RET(PDO_PARSER_EOI); } */ diff --git a/ext/pdo_mysql/tests/bug54929.phpt b/ext/pdo_mysql/tests/bug54929.phpt new file mode 100644 index 0000000000000..29fb44182b167 --- /dev/null +++ b/ext/pdo_mysql/tests/bug54929.phpt @@ -0,0 +1,74 @@ +--TEST-- +Bug #54929 (Parse error with single quote in sql comment (pdo-mysql)) +--SKIPIF-- + +--FILE-- +prepare($query); + + if (!$stmt->execute(array("foo"))) { + var_dump($stmt->errorInfo()); + } else{ + var_dump($stmt->fetch(PDO::FETCH_ASSOC)); + } +} + +testQuery("/* ' */ select ? as f1 /* ' */"); +testQuery("/* '-- */ select ? as f1 /* *' */"); +testQuery("/* ' */ select ? as f1 --';"); +testQuery("/* ' */ select ? as f1 -- 'a;"); +testQuery("/*'**/ select ? as f1 /* ' */"); +testQuery("/*'***/ select ? as f1 /* ' */"); +testQuery("/*'**a ***b / **** +****** +**/ select ? as f1 /* ' */"); + +?> +--EXPECTF-- +array(1) { + ["f1"]=> + string(3) "foo" +} +array(1) { + ["f1"]=> + string(3) "foo" +} + +Warning: PDOStatement::execute(): SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '--'' at line 1 in %s on line %d +array(3) { + [0]=> + string(5) "42000" + [1]=> + int(1064) + [2]=> + string(149) "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '--'' at line 1" +} +array(1) { + ["f1"]=> + string(3) "foo" +} +array(1) { + ["f1"]=> + string(3) "foo" +} +array(1) { + ["f1"]=> + string(3) "foo" +} +array(1) { + ["f1"]=> + string(3) "foo" +} From 379c32bd417f9077a962d4a60a89e2a375ef22a9 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 5 Jun 2011 01:15:10 +0000 Subject: [PATCH 0100/2394] - Fixed wrong sigaction() call passing signal number 65 (invalid) --- Zend/zend_signal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_signal.c b/Zend/zend_signal.c index dd7cca7cdd365..8fe8ebc515ca6 100644 --- a/Zend/zend_signal.c +++ b/Zend/zend_signal.c @@ -377,7 +377,7 @@ void zend_signal_startup() /* Save previously registered signal handlers into orig_handlers */ memset(&global_orig_handlers, 0, sizeof(global_orig_handlers)); - for (signo = 1; signo <= NSIG; ++signo) { + for (signo = 1; signo < NSIG; ++signo) { if (sigaction(signo, NULL, &sa) == 0) { global_orig_handlers[signo-1].flags = sa.sa_flags; if (sa.sa_flags & SA_SIGINFO) { From a2124382ac000e5a598998d97706149d96609c4d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 5 Jun 2011 01:38:12 +0000 Subject: [PATCH 0101/2394] - Possible fix for bug #54609 (Certain implementation(s) of SplFixedArray cause hard crash) --- ext/spl/spl_fixedarray.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c index 34cb69cccdef0..89c4130bdf6ae 100644 --- a/ext/spl/spl_fixedarray.c +++ b/ext/spl/spl_fixedarray.c @@ -153,7 +153,7 @@ static HashTable* spl_fixedarray_object_get_properties(zval *obj TSRMLS_DC) /* { HashTable *ht = zend_std_get_properties(obj TSRMLS_CC); int i = 0; - if (intern->array) { + if (intern->array && !GC_G(gc_active)) { int j = zend_hash_num_elements(ht); for (i = 0; i < intern->array->size; i++) { @@ -161,9 +161,6 @@ static HashTable* spl_fixedarray_object_get_properties(zval *obj TSRMLS_DC) /* { zend_hash_index_update(ht, i, (void *)&intern->array->elements[i], sizeof(zval *), NULL); Z_ADDREF_P(intern->array->elements[i]); } else { - if (GC_G(gc_active)) { - return NULL; - } zend_hash_index_update(ht, i, (void *)&EG(uninitialized_zval_ptr), sizeof(zval *), NULL); Z_ADDREF_P(EG(uninitialized_zval_ptr)); } From ad14faa7dd88ff6d735a14247676e54c8f76ffff Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Sun, 5 Jun 2011 06:57:13 +0000 Subject: [PATCH 0102/2394] Updated the note maintainers credits --- ext/standard/credits.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/credits.c b/ext/standard/credits.c index af5fe416c5528..0aa7a31b6e3dc 100644 --- a/ext/standard/credits.c +++ b/ext/standard/credits.c @@ -96,7 +96,7 @@ PHPAPI void php_print_credits(int flag TSRMLS_DC) /* {{{ */ php_info_print_table_colspan_header(2, "PHP Documentation"); CREDIT_LINE("Authors", "Mehdi Achour, Friedhelm Betz, Antony Dovgal, Nuno Lopes, Hannes Magnusson, Georg Richter, Damien Seguy, Jakub Vrana"); CREDIT_LINE("Editor", "Philip Olson"); - CREDIT_LINE("User Note Maintainers", "Friedhelm Betz, Etienne Kneuss, Nuno Lopes, Hannes Magnusson, Felipe Pena, Maciek Sokolewicz, Daniel P. Brown"); + CREDIT_LINE("User Note Maintainers", "Daniel P. Brown, Thiago Henrique Pojda"); CREDIT_LINE("Other Contributors", "Previously active authors, editors and other contributors are listed in the manual."); php_info_print_table_end(); } From 6ff402e280ffbd7b1b2df437b141ddd5a98621a7 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 08:56:52 +0000 Subject: [PATCH 0103/2394] This isn't less then 5.4.. but these still fail though. --- ext/date/tests/DateTime_diff_add_sub-fall-type2-type2.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-fall-type2-type3.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-fall-type3-type2.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-fall-type3-type3.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-spring-type2-type2.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-spring-type2-type3.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-spring-type3-type2.phpt | 2 -- ext/date/tests/DateTime_diff_add_sub-spring-type3-type3.phpt | 2 -- 8 files changed, 16 deletions(-) diff --git a/ext/date/tests/DateTime_diff_add_sub-fall-type2-type2.phpt b/ext/date/tests/DateTime_diff_add_sub-fall-type2-type2.phpt index 71f6d5f88d34a..f8a2598bb985c 100644 --- a/ext/date/tests/DateTime_diff_add_sub-fall-type2-type2.phpt +++ b/ext/date/tests/DateTime_diff_add_sub-fall-type2-type2.phpt @@ -2,8 +2,6 @@ DateTime::diff() add() sub() -- fall type2 type2 --CREDITS-- Daniel Convissor ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- ---XFAIL-- -PHP < 5.4 has bugs --FILE-- Date: Sun, 5 Jun 2011 08:59:24 +0000 Subject: [PATCH 0104/2394] This method doesn't seem to be very useful without scalar types, so reverting it too --- ext/reflection/php_reflection.c | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 8eb7af24b590f..1df797b664df2 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -2378,26 +2378,6 @@ ZEND_METHOD(reflection_parameter, isArray) } /* }}} */ -/* {{{ proto public string ReflectionParameter::getTypeHint() - Returns what type hint is defined for this parameter */ -ZEND_METHOD(reflection_parameter, getTypeHint) -{ - reflection_object *intern; - parameter_reference *param; - - if (zend_parse_parameters_none() == FAILURE) { - return; - } - GET_REFLECTION_OBJECT_PTR(param); - - if (!param->arg_info->type_hint) { - RETURN_FALSE; - } - - RETURN_STRING(zend_get_type_by_const(param->arg_info->type_hint), 1); -} -/* }}} */ - /* {{{ proto public bool ReflectionParameter::allowsNull() Returns whether NULL is allowed as this parameters's value */ ZEND_METHOD(reflection_parameter, allowsNull) @@ -5837,7 +5817,6 @@ static const zend_function_entry reflection_parameter_functions[] = { ZEND_ME(reflection_parameter, getDeclaringClass, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, getClass, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, isArray, arginfo_reflection__void, 0) - ZEND_ME(reflection_parameter, getTypeHint, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, allowsNull, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, getPosition, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, isOptional, arginfo_reflection__void, 0) From 00be22241879879a9d30e27355dc9aef752d7d81 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 09:35:49 +0000 Subject: [PATCH 0105/2394] Fix tests when running without mbstring --- Zend/tests/declare_001.phpt | 10 ++++++++-- Zend/tests/declare_002.phpt | 3 +++ Zend/tests/declare_003.phpt | 23 +++++++++++++++++++++++ Zend/tests/declare_004.phpt | 27 +++++++++++++++++++++++++++ 4 files changed, 61 insertions(+), 2 deletions(-) create mode 100644 Zend/tests/declare_003.phpt create mode 100644 Zend/tests/declare_004.phpt diff --git a/Zend/tests/declare_001.phpt b/Zend/tests/declare_001.phpt index 007c01cdf04e1..d67209ee4dfa8 100644 --- a/Zend/tests/declare_001.phpt +++ b/Zend/tests/declare_001.phpt @@ -1,5 +1,11 @@ --TEST-- Testing declare statement with several type values +--SKIPIF-- + --INI-- zend.multibyte=1 --FILE-- @@ -17,8 +23,8 @@ print 'DONE'; --EXPECTF-- Warning: Unsupported encoding [1] in %sdeclare_001.php on line %d -Warning: Unsupported encoding [1.1231312321313E+18] in %sdeclare_001.php on line %d +Warning: Unsupported encoding [1123131232131312321] in %sdeclare_001.php on line %d Warning: Unsupported encoding [] in %sdeclare_001.php on line %d -Fatal error: Cannot use constants as encoding in %sdeclare_001.php on line %d \ No newline at end of file +Fatal error: Cannot use constants as encoding in %sdeclare_001.php on line %d diff --git a/Zend/tests/declare_002.phpt b/Zend/tests/declare_002.phpt index 1babdf338b81e..19844556f1791 100644 --- a/Zend/tests/declare_002.phpt +++ b/Zend/tests/declare_002.phpt @@ -5,6 +5,9 @@ Testing declare statement with several type values if (!ini_get("zend.multibyte")) { die("skip Requires zend.multibyte=1"); } +if (!extension_loaded("mbstring")) { + die("skip Requires ext/mbstring"); +} ?> --FILE-- +--EXPECTF-- +Warning: Unsupported encoding [1] in %sdeclare_003.php on line %d + +Warning: Unsupported encoding [1123131232131312321] in %sdeclare_003.php on line %d + +Warning: Unsupported encoding [] in %sdeclare_003.php on line %d + +Fatal error: Cannot use constants as encoding in %sdeclare_003.php on line %d diff --git a/Zend/tests/declare_004.phpt b/Zend/tests/declare_004.phpt new file mode 100644 index 0000000000000..a2ba51ac9c4da --- /dev/null +++ b/Zend/tests/declare_004.phpt @@ -0,0 +1,27 @@ +--TEST-- +Testing declare statement with several type values +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +Warning: Unsupported encoding [%d] in %sdeclare_004.php on line 3 + +Warning: Unsupported encoding [%f] in %sdeclare_004.php on line 4 + +Warning: Unsupported encoding [] in %sdeclare_004.php on line 5 + +Fatal error: Cannot use constants as encoding in %sdeclare_004.php on line 6 From 9f7b09a265633c29ca60f08a8174c18933d5439b Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 09:42:10 +0000 Subject: [PATCH 0106/2394] touch() no longer attempts to create files on empty strings --- ext/standard/tests/file/005_variation2.phpt | 6 ------ 1 file changed, 6 deletions(-) diff --git a/ext/standard/tests/file/005_variation2.phpt b/ext/standard/tests/file/005_variation2.phpt index d14a9bddd78ed..6d4ca5e83d10a 100644 --- a/ext/standard/tests/file/005_variation2.phpt +++ b/ext/standard/tests/file/005_variation2.phpt @@ -77,12 +77,6 @@ echo "Done"; *** Testing fileattime(), filemtime(), filectime() & touch() : usage variations *** *** testing touch *** - -Warning: touch(): Unable to create file because No such file or directory in %s on line %d - -Warning: touch(): Unable to create file because No such file or directory in %s on line %d - -Warning: touch(): Unable to create file because No such file or directory in %s on line %d bool(false) bool(false) bool(false) From bf3cd0675d0960a0568cad0b59e1d35c325eae0c Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 11:31:18 +0000 Subject: [PATCH 0107/2394] No need to fetch external files and endless amount of DTDs for this test --- ext/dom/examples/note.dtd | 4 ++-- .../DOMDocument_validate_on_parse_variation.phpt | 11 ++++------- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/ext/dom/examples/note.dtd b/ext/dom/examples/note.dtd index 4016eb58111cd..c2d558eee4eb5 100644 --- a/ext/dom/examples/note.dtd +++ b/ext/dom/examples/note.dtd @@ -1,6 +1,6 @@ - + - \ No newline at end of file + diff --git a/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt b/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt index 2395b0134433a..403e01aa76bfb 100644 --- a/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt +++ b/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt @@ -6,17 +6,14 @@ Hans Zaunere --SKIPIF-- --FILE-- resolveExternals = TRUE; @@ -27,7 +24,7 @@ $dom->loadXML($XMLStringGood); echo "No Error Report Above\n"; $BogusElement = $dom->createElement('NYPHP','DOMinatrix'); -$Body = $dom->getElementsByTagName('body')->item(0); +$Body = $dom->getElementsByTagName('from')->item(0); $Body->appendChild($BogusElement); $XMLStringBad = $dom->saveXML(); @@ -44,6 +41,6 @@ validateOnParse set to TRUE: Warning: DOMDocument::loadXML(): No declaration for element NYPHP in Entity, line: %d in %s on line %d -Warning: DOMDocument::loadXML(): Element body content does not follow the DTD, expecting (p | h1 | h2 | h3 | h4 | h5 | h6 | div | ul | ol | dl | pre | hr | blockquote | address | fieldset | table | form | noscript | ins | del | script)*, got (div div div div div NYPHP) in Entity, line: %d in %s on line %d +Warning: DOMDocument::loadXML(): Element from was declared #PCDATA but contains non text nodes in Entity, line: %d in %s on line %d Error Report Above From c1a96c16d06dd4e818a1c2b9c052df6705088ada Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 12:07:11 +0000 Subject: [PATCH 0108/2394] Make sure we are writing more data then the block size --- ext/standard/tests/file/lstat_stat_variation7.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/file/lstat_stat_variation7.phpt b/ext/standard/tests/file/lstat_stat_variation7.phpt index f950c8fe6bfcb..2296193c91ca8 100644 --- a/ext/standard/tests/file/lstat_stat_variation7.phpt +++ b/ext/standard/tests/file/lstat_stat_variation7.phpt @@ -29,7 +29,7 @@ echo "*** Testing stat() on file after data is written in it ***\n"; $fh = fopen($file_name,"w"); $old_stat = stat($file_name); clearstatcache(); -fwrite($fh, (binary)"Hello World"); +fwrite($fh, str_repeat((binary)"Hello World", $old_stat['blksize'])); $new_stat = stat($file_name); // compare self stats From d4f6e7d93777f704adffbc41f6a4e821cf46c00e Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 12:08:14 +0000 Subject: [PATCH 0109/2394] When you write to a symlink - you access the file itself, not the symlink, so we need to compare the atime to the orignal file --- ext/standard/tests/file/lstat_stat_variation6.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/file/lstat_stat_variation6.phpt b/ext/standard/tests/file/lstat_stat_variation6.phpt index b7913e0b34f14..8704c6d7c607c 100755 --- a/ext/standard/tests/file/lstat_stat_variation6.phpt +++ b/ext/standard/tests/file/lstat_stat_variation6.phpt @@ -47,7 +47,7 @@ clearstatcache(); var_dump( touch($link_name) ); -$new_stat = lstat($link_name); +$new_stat = stat($file_name); // compare self stats var_dump( compare_self_stat($old_stat) ); From 938d066d49c892296c82ef024b6f7884f1b23385 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Sun, 5 Jun 2011 13:30:01 +0000 Subject: [PATCH 0110/2394] Fixed bug#51819 (Case discrepancy in timezone names cause Uncaught exception and fatal error) --- ext/date/lib/parse_date.c | 215 +++++++++++++++++++---------------- ext/date/lib/parse_date.re | 19 ++++ ext/date/tests/bug51819.phpt | 5 +- 3 files changed, 138 insertions(+), 101 deletions(-) diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index da682ebcc2212..1771b0d9c8de7 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon Mar 28 05:04:54 2011 */ +/* Generated by re2c 0.13.5 on Sun Jun 5 15:23:24 2011 */ #line 1 "ext/date/lib/parse_date.re" /* +----------------------------------------------------------------------+ @@ -721,6 +721,25 @@ const static timelib_tz_lookup_table* zone_search(const char *word, long gmtoffs return first_found_elem; } + for (tp = timelib_timezone_lookup; tp->name; tp++) { + if (tp->full_tz_name && strcasecmp(word, tp->full_tz_name) == 0) { + if (!first_found) { + first_found = 1; + first_found_elem = tp; + if (gmtoffset == -1) { + return tp; + } + } + if (tp->gmtoffset == gmtoffset) { + return tp; + } + } + } + if (first_found) { + return first_found_elem; + } + + /* Still didn't find anything, let's find the zone solely based on * offset/isdst then */ for (fmp = timelib_timezone_fallbackmap; fmp->name; fmp++) { @@ -844,11 +863,11 @@ static int scan(Scanner *s) std: s->tok = cursor; s->len = 0; -#line 970 "ext/date/lib/parse_date.re" +#line 989 "ext/date/lib/parse_date.re" -#line 852 "ext/date/lib/parse_date.c" +#line 871 "ext/date/lib/parse_date.c" { YYCTYPE yych; unsigned int yyaccept = 0; @@ -968,7 +987,7 @@ static int scan(Scanner *s) } yy2: YYDEBUG(2, *YYCURSOR); -#line 1055 "ext/date/lib/parse_date.re" +#line 1074 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("firstdayof | lastdayof"); TIMELIB_INIT; @@ -984,7 +1003,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_LF_DAY_OF_MONTH; } -#line 988 "ext/date/lib/parse_date.c" +#line 1007 "ext/date/lib/parse_date.c" yy3: YYDEBUG(3, *YYCURSOR); ++YYCURSOR; @@ -1007,7 +1026,7 @@ static int scan(Scanner *s) } yy4: YYDEBUG(4, *YYCURSOR); -#line 1637 "ext/date/lib/parse_date.re" +#line 1656 "ext/date/lib/parse_date.re" { int tz_not_found; DEBUG_OUTPUT("tzcorrection | tz"); @@ -1020,7 +1039,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIMEZONE; } -#line 1024 "ext/date/lib/parse_date.c" +#line 1043 "ext/date/lib/parse_date.c" yy5: YYDEBUG(5, *YYCURSOR); yych = *++YYCURSOR; @@ -1331,12 +1350,12 @@ static int scan(Scanner *s) if (yych <= '9') goto yy1385; yy13: YYDEBUG(13, *YYCURSOR); -#line 1732 "ext/date/lib/parse_date.re" +#line 1751 "ext/date/lib/parse_date.re" { add_error(s, "Unexpected character"); goto std; } -#line 1340 "ext/date/lib/parse_date.c" +#line 1359 "ext/date/lib/parse_date.c" yy14: YYDEBUG(14, *YYCURSOR); yych = *++YYCURSOR; @@ -2393,11 +2412,11 @@ static int scan(Scanner *s) if (yych <= '9') goto yy55; yy50: YYDEBUG(50, *YYCURSOR); -#line 1721 "ext/date/lib/parse_date.re" +#line 1740 "ext/date/lib/parse_date.re" { goto std; } -#line 2401 "ext/date/lib/parse_date.c" +#line 2420 "ext/date/lib/parse_date.c" yy51: YYDEBUG(51, *YYCURSOR); yych = *++YYCURSOR; @@ -2406,12 +2425,12 @@ static int scan(Scanner *s) YYDEBUG(52, *YYCURSOR); ++YYCURSOR; YYDEBUG(53, *YYCURSOR); -#line 1726 "ext/date/lib/parse_date.re" +#line 1745 "ext/date/lib/parse_date.re" { s->pos = cursor; s->line++; goto std; } -#line 2415 "ext/date/lib/parse_date.c" +#line 2434 "ext/date/lib/parse_date.c" yy54: YYDEBUG(54, *YYCURSOR); yych = *++YYCURSOR; @@ -2798,7 +2817,7 @@ static int scan(Scanner *s) if (yych == 's') goto yy74; yy73: YYDEBUG(73, *YYCURSOR); -#line 1705 "ext/date/lib/parse_date.re" +#line 1724 "ext/date/lib/parse_date.re" { timelib_ull i; DEBUG_OUTPUT("relative"); @@ -2813,7 +2832,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 2817 "ext/date/lib/parse_date.c" +#line 2836 "ext/date/lib/parse_date.c" yy74: YYDEBUG(74, *YYCURSOR); yych = *++YYCURSOR; @@ -3575,7 +3594,7 @@ static int scan(Scanner *s) } yy167: YYDEBUG(167, *YYCURSOR); -#line 1568 "ext/date/lib/parse_date.re" +#line 1587 "ext/date/lib/parse_date.re" { const timelib_relunit* relunit; DEBUG_OUTPUT("daytext"); @@ -3592,7 +3611,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_WEEKDAY; } -#line 3596 "ext/date/lib/parse_date.c" +#line 3615 "ext/date/lib/parse_date.c" yy168: YYDEBUG(168, *YYCURSOR); yych = *++YYCURSOR; @@ -4112,7 +4131,7 @@ static int scan(Scanner *s) } yy194: YYDEBUG(194, *YYCURSOR); -#line 1627 "ext/date/lib/parse_date.re" +#line 1646 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("monthtext"); TIMELIB_INIT; @@ -4121,7 +4140,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 4125 "ext/date/lib/parse_date.c" +#line 4144 "ext/date/lib/parse_date.c" yy195: YYDEBUG(195, *YYCURSOR); ++YYCURSOR; @@ -4172,7 +4191,7 @@ static int scan(Scanner *s) } yy199: YYDEBUG(199, *YYCURSOR); -#line 1377 "ext/date/lib/parse_date.re" +#line 1396 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datetextual | datenoyear"); TIMELIB_INIT; @@ -4184,7 +4203,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 4188 "ext/date/lib/parse_date.c" +#line 4207 "ext/date/lib/parse_date.c" yy200: YYDEBUG(200, *YYCURSOR); yyaccept = 6; @@ -4453,7 +4472,7 @@ static int scan(Scanner *s) } yy223: YYDEBUG(223, *YYCURSOR); -#line 1675 "ext/date/lib/parse_date.re" +#line 1694 "ext/date/lib/parse_date.re" { int tz_not_found; DEBUG_OUTPUT("dateshortwithtimeshort | dateshortwithtimelong | dateshortwithtimelongtz"); @@ -4482,7 +4501,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_SHORTDATE_WITH_TIME; } -#line 4486 "ext/date/lib/parse_date.c" +#line 4505 "ext/date/lib/parse_date.c" yy224: YYDEBUG(224, *YYCURSOR); yyaccept = 7; @@ -5180,7 +5199,7 @@ static int scan(Scanner *s) YYDEBUG(278, *YYCURSOR); ++YYCURSOR; YYDEBUG(279, *YYCURSOR); -#line 1651 "ext/date/lib/parse_date.re" +#line 1670 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("dateshortwithtimeshort12 | dateshortwithtimelong12"); TIMELIB_INIT; @@ -5203,7 +5222,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_SHORTDATE_WITH_TIME; } -#line 5207 "ext/date/lib/parse_date.c" +#line 5226 "ext/date/lib/parse_date.c" yy280: YYDEBUG(280, *YYCURSOR); yych = *++YYCURSOR; @@ -5381,7 +5400,7 @@ static int scan(Scanner *s) ++YYCURSOR; yy295: YYDEBUG(295, *YYCURSOR); -#line 1351 "ext/date/lib/parse_date.re" +#line 1370 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenoday"); TIMELIB_INIT; @@ -5393,7 +5412,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_NO_DAY; } -#line 5397 "ext/date/lib/parse_date.c" +#line 5416 "ext/date/lib/parse_date.c" yy296: YYDEBUG(296, *YYCURSOR); yych = *++YYCURSOR; @@ -6613,7 +6632,7 @@ static int scan(Scanner *s) if (yych <= '9') goto yy365; yy364: YYDEBUG(364, *YYCURSOR); -#line 1491 "ext/date/lib/parse_date.re" +#line 1510 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pgtextshort"); TIMELIB_INIT; @@ -6625,7 +6644,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_PG_TEXT; } -#line 6629 "ext/date/lib/parse_date.c" +#line 6648 "ext/date/lib/parse_date.c" yy365: YYDEBUG(365, *YYCURSOR); yych = *++YYCURSOR; @@ -7263,7 +7282,7 @@ static int scan(Scanner *s) } yy393: YYDEBUG(393, *YYCURSOR); -#line 1547 "ext/date/lib/parse_date.re" +#line 1566 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("ago"); TIMELIB_INIT; @@ -7283,7 +7302,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_AGO; } -#line 7287 "ext/date/lib/parse_date.c" +#line 7306 "ext/date/lib/parse_date.c" yy394: YYDEBUG(394, *YYCURSOR); yyaccept = 5; @@ -9033,7 +9052,7 @@ static int scan(Scanner *s) ++YYCURSOR; yy455: YYDEBUG(455, *YYCURSOR); -#line 1261 "ext/date/lib/parse_date.re" +#line 1280 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("iso8601date4 | iso8601date2 | iso8601dateslash | dateslash"); TIMELIB_INIT; @@ -9044,7 +9063,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 9048 "ext/date/lib/parse_date.c" +#line 9067 "ext/date/lib/parse_date.c" yy456: YYDEBUG(456, *YYCURSOR); yyaccept = 0; @@ -9604,7 +9623,7 @@ static int scan(Scanner *s) } yy476: YYDEBUG(476, *YYCURSOR); -#line 1390 "ext/date/lib/parse_date.re" +#line 1409 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenoyearrev"); TIMELIB_INIT; @@ -9615,7 +9634,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 9619 "ext/date/lib/parse_date.c" +#line 9638 "ext/date/lib/parse_date.c" yy477: YYDEBUG(477, *YYCURSOR); yyaccept = 10; @@ -9756,7 +9775,7 @@ static int scan(Scanner *s) YYDEBUG(488, *YYCURSOR); ++YYCURSOR; YYDEBUG(489, *YYCURSOR); -#line 1117 "ext/date/lib/parse_date.re" +#line 1136 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("timetiny12 | timeshort12 | timelong12"); TIMELIB_INIT; @@ -9772,7 +9791,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIME12; } -#line 9776 "ext/date/lib/parse_date.c" +#line 9795 "ext/date/lib/parse_date.c" yy490: YYDEBUG(490, *YYCURSOR); yyaccept = 11; @@ -9785,7 +9804,7 @@ static int scan(Scanner *s) } yy491: YYDEBUG(491, *YYCURSOR); -#line 1154 "ext/date/lib/parse_date.re" +#line 1173 "ext/date/lib/parse_date.re" { int tz_not_found; DEBUG_OUTPUT("timeshort24 | timelong24 | iso8601long"); @@ -9810,7 +9829,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIME24_WITH_ZONE; } -#line 9814 "ext/date/lib/parse_date.c" +#line 9833 "ext/date/lib/parse_date.c" yy492: YYDEBUG(492, *YYCURSOR); yyaccept = 11; @@ -10120,7 +10139,7 @@ static int scan(Scanner *s) YYDEBUG(523, *YYCURSOR); ++YYCURSOR; YYDEBUG(524, *YYCURSOR); -#line 1134 "ext/date/lib/parse_date.re" +#line 1153 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("mssqltime"); TIMELIB_INIT; @@ -10139,7 +10158,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIME24_WITH_ZONE; } -#line 10143 "ext/date/lib/parse_date.c" +#line 10162 "ext/date/lib/parse_date.c" yy525: YYDEBUG(525, *YYCURSOR); yyaccept = 11; @@ -10245,7 +10264,7 @@ static int scan(Scanner *s) if (yych <= '9') goto yy541; yy535: YYDEBUG(535, *YYCURSOR); -#line 1312 "ext/date/lib/parse_date.re" +#line 1331 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datefull"); TIMELIB_INIT; @@ -10258,7 +10277,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_FULL; } -#line 10262 "ext/date/lib/parse_date.c" +#line 10281 "ext/date/lib/parse_date.c" yy536: YYDEBUG(536, *YYCURSOR); yych = *++YYCURSOR; @@ -10995,7 +11014,7 @@ static int scan(Scanner *s) YYDEBUG(606, *YYCURSOR); ++YYCURSOR; YYDEBUG(607, *YYCURSOR); -#line 1326 "ext/date/lib/parse_date.re" +#line 1345 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pointed date YYYY"); TIMELIB_INIT; @@ -11006,7 +11025,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_FULL_POINTED; } -#line 11010 "ext/date/lib/parse_date.c" +#line 11029 "ext/date/lib/parse_date.c" yy608: YYDEBUG(608, *YYCURSOR); yyaccept = 11; @@ -11042,7 +11061,7 @@ static int scan(Scanner *s) if (yych <= '9') goto yy605; yy612: YYDEBUG(612, *YYCURSOR); -#line 1338 "ext/date/lib/parse_date.re" +#line 1357 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pointed date YY"); TIMELIB_INIT; @@ -11054,7 +11073,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_FULL_POINTED; } -#line 11058 "ext/date/lib/parse_date.c" +#line 11077 "ext/date/lib/parse_date.c" yy613: YYDEBUG(613, *YYCURSOR); yyaccept = 11; @@ -11695,7 +11714,7 @@ static int scan(Scanner *s) } yy657: YYDEBUG(657, *YYCURSOR); -#line 1299 "ext/date/lib/parse_date.re" +#line 1318 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("gnudateshort"); TIMELIB_INIT; @@ -11707,7 +11726,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 11711 "ext/date/lib/parse_date.c" +#line 11730 "ext/date/lib/parse_date.c" yy658: YYDEBUG(658, *YYCURSOR); yyaccept = 13; @@ -11813,7 +11832,7 @@ static int scan(Scanner *s) } yy667: YYDEBUG(667, *YYCURSOR); -#line 1246 "ext/date/lib/parse_date.re" +#line 1265 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("americanshort | american"); TIMELIB_INIT; @@ -11827,7 +11846,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_AMERICAN; } -#line 11831 "ext/date/lib/parse_date.c" +#line 11850 "ext/date/lib/parse_date.c" yy668: YYDEBUG(668, *YYCURSOR); yyaccept = 14; @@ -12060,7 +12079,7 @@ static int scan(Scanner *s) if (yych <= ':') goto yy704; yy701: YYDEBUG(701, *YYCURSOR); -#line 1517 "ext/date/lib/parse_date.re" +#line 1536 "ext/date/lib/parse_date.re" { int tz_not_found; DEBUG_OUTPUT("clf"); @@ -12080,7 +12099,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_CLF; } -#line 12084 "ext/date/lib/parse_date.c" +#line 12103 "ext/date/lib/parse_date.c" yy702: YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; @@ -12632,7 +12651,7 @@ static int scan(Scanner *s) } yy764: YYDEBUG(764, *YYCURSOR); -#line 1273 "ext/date/lib/parse_date.re" +#line 1292 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("iso8601date2"); TIMELIB_INIT; @@ -12644,7 +12663,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 12648 "ext/date/lib/parse_date.c" +#line 12667 "ext/date/lib/parse_date.c" yy765: YYDEBUG(765, *YYCURSOR); yych = *++YYCURSOR; @@ -12683,7 +12702,7 @@ static int scan(Scanner *s) YYDEBUG(771, *YYCURSOR); ++YYCURSOR; YYDEBUG(772, *YYCURSOR); -#line 1504 "ext/date/lib/parse_date.re" +#line 1523 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pgtextreverse"); TIMELIB_INIT; @@ -12695,7 +12714,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_PG_TEXT; } -#line 12699 "ext/date/lib/parse_date.c" +#line 12718 "ext/date/lib/parse_date.c" yy773: YYDEBUG(773, *YYCURSOR); yych = *++YYCURSOR; @@ -12833,7 +12852,7 @@ static int scan(Scanner *s) } yy784: YYDEBUG(784, *YYCURSOR); -#line 1538 "ext/date/lib/parse_date.re" +#line 1557 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("year4"); TIMELIB_INIT; @@ -12841,7 +12860,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_CLF; } -#line 12845 "ext/date/lib/parse_date.c" +#line 12864 "ext/date/lib/parse_date.c" yy785: YYDEBUG(785, *YYCURSOR); yych = *++YYCURSOR; @@ -12992,7 +13011,7 @@ static int scan(Scanner *s) } yy794: YYDEBUG(794, *YYCURSOR); -#line 1364 "ext/date/lib/parse_date.re" +#line 1383 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenodayrev"); TIMELIB_INIT; @@ -13004,7 +13023,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_NO_DAY; } -#line 13008 "ext/date/lib/parse_date.c" +#line 13027 "ext/date/lib/parse_date.c" yy795: YYDEBUG(795, *YYCURSOR); yych = *++YYCURSOR; @@ -13219,7 +13238,7 @@ static int scan(Scanner *s) if (yych <= '7') goto yy817; yy815: YYDEBUG(815, *YYCURSOR); -#line 1472 "ext/date/lib/parse_date.re" +#line 1491 "ext/date/lib/parse_date.re" { timelib_sll w, d; DEBUG_OUTPUT("isoweek"); @@ -13237,7 +13256,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_WEEK; } -#line 13241 "ext/date/lib/parse_date.c" +#line 13260 "ext/date/lib/parse_date.c" yy816: YYDEBUG(816, *YYCURSOR); yych = *++YYCURSOR; @@ -13247,7 +13266,7 @@ static int scan(Scanner *s) YYDEBUG(817, *YYCURSOR); ++YYCURSOR; YYDEBUG(818, *YYCURSOR); -#line 1453 "ext/date/lib/parse_date.re" +#line 1472 "ext/date/lib/parse_date.re" { timelib_sll w, d; DEBUG_OUTPUT("isoweekday"); @@ -13265,7 +13284,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_WEEK; } -#line 13269 "ext/date/lib/parse_date.c" +#line 13288 "ext/date/lib/parse_date.c" yy819: YYDEBUG(819, *YYCURSOR); yych = *++YYCURSOR; @@ -13329,7 +13348,7 @@ static int scan(Scanner *s) } yy822: YYDEBUG(822, *YYCURSOR); -#line 1440 "ext/date/lib/parse_date.re" +#line 1459 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pgydotd"); TIMELIB_INIT; @@ -13341,7 +13360,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_PG_YEARDAY; } -#line 13345 "ext/date/lib/parse_date.c" +#line 13364 "ext/date/lib/parse_date.c" yy823: YYDEBUG(823, *YYCURSOR); yych = *++YYCURSOR; @@ -13444,7 +13463,7 @@ static int scan(Scanner *s) ++YYCURSOR; yy843: YYDEBUG(843, *YYCURSOR); -#line 1414 "ext/date/lib/parse_date.re" +#line 1433 "ext/date/lib/parse_date.re" { int tz_not_found; DEBUG_OUTPUT("xmlrpc | xmlrpcnocolon | soap | wddx | exif"); @@ -13469,7 +13488,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_XMLRPC_SOAP; } -#line 13473 "ext/date/lib/parse_date.c" +#line 13492 "ext/date/lib/parse_date.c" yy844: YYDEBUG(844, *YYCURSOR); yych = *++YYCURSOR; @@ -13731,7 +13750,7 @@ static int scan(Scanner *s) } yy849: YYDEBUG(849, *YYCURSOR); -#line 1402 "ext/date/lib/parse_date.re" +#line 1421 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenocolon"); TIMELIB_INIT; @@ -13742,7 +13761,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_NOCOLON; } -#line 13746 "ext/date/lib/parse_date.c" +#line 13765 "ext/date/lib/parse_date.c" yy850: YYDEBUG(850, *YYCURSOR); yych = *++YYCURSOR; @@ -14662,7 +14681,7 @@ static int scan(Scanner *s) if (yych <= '9') goto yy996; yy974: YYDEBUG(974, *YYCURSOR); -#line 1286 "ext/date/lib/parse_date.re" +#line 1305 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("gnudateshorter"); TIMELIB_INIT; @@ -14674,7 +14693,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 14678 "ext/date/lib/parse_date.c" +#line 14697 "ext/date/lib/parse_date.c" yy975: YYDEBUG(975, *YYCURSOR); yyaccept = 22; @@ -15683,7 +15702,7 @@ static int scan(Scanner *s) } yy1068: YYDEBUG(1068, *YYCURSOR); -#line 1180 "ext/date/lib/parse_date.re" +#line 1199 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("gnunocolon"); TIMELIB_INIT; @@ -15705,7 +15724,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_GNU_NOCOLON; } -#line 15709 "ext/date/lib/parse_date.c" +#line 15728 "ext/date/lib/parse_date.c" yy1069: YYDEBUG(1069, *YYCURSOR); yych = *++YYCURSOR; @@ -15797,7 +15816,7 @@ static int scan(Scanner *s) } yy1076: YYDEBUG(1076, *YYCURSOR); -#line 1226 "ext/date/lib/parse_date.re" +#line 1245 "ext/date/lib/parse_date.re" { int tz_not_found; DEBUG_OUTPUT("iso8601nocolon"); @@ -15816,7 +15835,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_NOCOLON; } -#line 15820 "ext/date/lib/parse_date.c" +#line 15839 "ext/date/lib/parse_date.c" yy1077: YYDEBUG(1077, *YYCURSOR); yyaccept = 25; @@ -16714,7 +16733,7 @@ static int scan(Scanner *s) } yy1118: YYDEBUG(1118, *YYCURSOR); -#line 1610 "ext/date/lib/parse_date.re" +#line 1629 "ext/date/lib/parse_date.re" { timelib_sll i; int behavior = 0; @@ -16730,7 +16749,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 16734 "ext/date/lib/parse_date.c" +#line 16753 "ext/date/lib/parse_date.c" yy1119: YYDEBUG(1119, *YYCURSOR); ++YYCURSOR; @@ -16781,7 +16800,7 @@ static int scan(Scanner *s) YYDEBUG(1126, *YYCURSOR); ++YYCURSOR; YYDEBUG(1127, *YYCURSOR); -#line 1095 "ext/date/lib/parse_date.re" +#line 1114 "ext/date/lib/parse_date.re" { timelib_sll i; int behavior = 0; @@ -16802,7 +16821,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_WEEK_DAY_OF_MONTH; } -#line 16806 "ext/date/lib/parse_date.c" +#line 16825 "ext/date/lib/parse_date.c" yy1128: YYDEBUG(1128, *YYCURSOR); yyaccept = 26; @@ -16910,7 +16929,7 @@ static int scan(Scanner *s) } yy1142: YYDEBUG(1142, *YYCURSOR); -#line 1586 "ext/date/lib/parse_date.re" +#line 1605 "ext/date/lib/parse_date.re" { timelib_sll i; int behavior = 0; @@ -16933,7 +16952,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 16937 "ext/date/lib/parse_date.c" +#line 16956 "ext/date/lib/parse_date.c" yy1143: YYDEBUG(1143, *YYCURSOR); yych = *++YYCURSOR; @@ -19610,7 +19629,7 @@ static int scan(Scanner *s) goto yy1298; yy1295: YYDEBUG(1295, *YYCURSOR); -#line 1072 "ext/date/lib/parse_date.re" +#line 1091 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("backof | frontof"); TIMELIB_INIT; @@ -19632,7 +19651,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_LF_DAY_OF_MONTH; } -#line 19636 "ext/date/lib/parse_date.c" +#line 19655 "ext/date/lib/parse_date.c" yy1296: YYDEBUG(1296, *YYCURSOR); yyaccept = 28; @@ -21323,7 +21342,7 @@ static int scan(Scanner *s) if (yych <= '9') goto yy1385; yy1387: YYDEBUG(1387, *YYCURSOR); -#line 1030 "ext/date/lib/parse_date.re" +#line 1049 "ext/date/lib/parse_date.re" { timelib_ull i; @@ -21347,7 +21366,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 21351 "ext/date/lib/parse_date.c" +#line 21370 "ext/date/lib/parse_date.c" yy1388: YYDEBUG(1388, *YYCURSOR); yych = *++YYCURSOR; @@ -21783,7 +21802,7 @@ static int scan(Scanner *s) ++YYCURSOR; yy1417: YYDEBUG(1417, *YYCURSOR); -#line 1018 "ext/date/lib/parse_date.re" +#line 1037 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("tomorrow"); TIMELIB_INIT; @@ -21794,7 +21813,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 21798 "ext/date/lib/parse_date.c" +#line 21817 "ext/date/lib/parse_date.c" yy1418: YYDEBUG(1418, *YYCURSOR); yych = *++YYCURSOR; @@ -21829,7 +21848,7 @@ static int scan(Scanner *s) } yy1420: YYDEBUG(1420, *YYCURSOR); -#line 1008 "ext/date/lib/parse_date.re" +#line 1027 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("midnight | today"); TIMELIB_INIT; @@ -21838,7 +21857,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 21842 "ext/date/lib/parse_date.c" +#line 21861 "ext/date/lib/parse_date.c" yy1421: YYDEBUG(1421, *YYCURSOR); yych = *++YYCURSOR; @@ -23850,7 +23869,7 @@ static int scan(Scanner *s) } yy1500: YYDEBUG(1500, *YYCURSOR); -#line 987 "ext/date/lib/parse_date.re" +#line 1006 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("now"); TIMELIB_INIT; @@ -23858,7 +23877,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 23862 "ext/date/lib/parse_date.c" +#line 23881 "ext/date/lib/parse_date.c" yy1501: YYDEBUG(1501, *YYCURSOR); yych = *++YYCURSOR; @@ -23997,7 +24016,7 @@ static int scan(Scanner *s) } yy1508: YYDEBUG(1508, *YYCURSOR); -#line 996 "ext/date/lib/parse_date.re" +#line 1015 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("noon"); TIMELIB_INIT; @@ -24008,7 +24027,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 24012 "ext/date/lib/parse_date.c" +#line 24031 "ext/date/lib/parse_date.c" yy1509: YYDEBUG(1509, *YYCURSOR); yyaccept = 0; @@ -24541,7 +24560,7 @@ static int scan(Scanner *s) ++YYCURSOR; yy1531: YYDEBUG(1531, *YYCURSOR); -#line 975 "ext/date/lib/parse_date.re" +#line 994 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("yesterday"); TIMELIB_INIT; @@ -24552,7 +24571,7 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 24556 "ext/date/lib/parse_date.c" +#line 24575 "ext/date/lib/parse_date.c" yy1532: YYDEBUG(1532, *YYCURSOR); yyaccept = 0; @@ -24725,7 +24744,7 @@ static int scan(Scanner *s) goto yy1531; } } -#line 1736 "ext/date/lib/parse_date.re" +#line 1755 "ext/date/lib/parse_date.re" } diff --git a/ext/date/lib/parse_date.re b/ext/date/lib/parse_date.re index 4a7e7b38936f9..1d571179fa29e 100644 --- a/ext/date/lib/parse_date.re +++ b/ext/date/lib/parse_date.re @@ -719,6 +719,25 @@ const static timelib_tz_lookup_table* zone_search(const char *word, long gmtoffs return first_found_elem; } + for (tp = timelib_timezone_lookup; tp->name; tp++) { + if (tp->full_tz_name && strcasecmp(word, tp->full_tz_name) == 0) { + if (!first_found) { + first_found = 1; + first_found_elem = tp; + if (gmtoffset == -1) { + return tp; + } + } + if (tp->gmtoffset == gmtoffset) { + return tp; + } + } + } + if (first_found) { + return first_found_elem; + } + + /* Still didn't find anything, let's find the zone solely based on * offset/isdst then */ for (fmp = timelib_timezone_fallbackmap; fmp->name; fmp++) { diff --git a/ext/date/tests/bug51819.phpt b/ext/date/tests/bug51819.phpt index bef8b76271cac..37cab2055e9b3 100644 --- a/ext/date/tests/bug51819.phpt +++ b/ext/date/tests/bug51819.phpt @@ -1,7 +1,5 @@ --TEST-- Bug #51819 (Case discrepancy in timezone names cause Uncaught exception and fatal error) ---XFAIL-- -Bug #51819 isn't fixed yet --FILE-- getMessage()); + print_r(DateTime::getLastErrors()); } } var_dump('this should be the only output'); ?> --EXPECTF-- -string(30) "this should be the only output" \ No newline at end of file +string(30) "this should be the only output" From 61bbd095244d87824b18dedee396d03b96f11475 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 5 Jun 2011 17:02:46 +0000 Subject: [PATCH 0111/2394] - Fixed crash in fastcgi (related to zend signals changes) --- sapi/cgi/cgi_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index a26d009c90aa9..01c417bef267f 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -1744,7 +1744,7 @@ int main(int argc, char *argv[]) int max_requests = 500; int requests = 0; - int fastcgi = fcgi_is_fastcgi(); + int fastcgi; char *bindpath = NULL; int fcgi_fd = 0; fcgi_request *request = NULL; @@ -1786,6 +1786,7 @@ int main(int argc, char *argv[]) #endif sapi_startup(&cgi_sapi_module); + fastcgi = fcgi_is_fastcgi(); cgi_sapi_module.php_ini_path_override = NULL; #ifdef PHP_WIN32 From 6b85eb58b27a60cfc4d78ad0a85afeda373132c5 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Sun, 5 Jun 2011 21:57:01 +0000 Subject: [PATCH 0112/2394] Fixed bug #51997 (SEEK_CUR with 0 value, returns a warning). --- ext/bz2/tests/bug51997.phpt | 24 ++++++++++++++++++++++++ main/streams/streams.c | 2 +- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 ext/bz2/tests/bug51997.phpt diff --git a/ext/bz2/tests/bug51997.phpt b/ext/bz2/tests/bug51997.phpt new file mode 100644 index 0000000000000..fea5398947733 --- /dev/null +++ b/ext/bz2/tests/bug51997.phpt @@ -0,0 +1,24 @@ +--TEST-- +Bug #51997 (SEEK_CUR with 0 value, returns a warning) +--SKIPIF-- + +--FILE-- + 0) { + if (whence == SEEK_CUR && offset >= 0) { char tmp[1024]; size_t didread; while(offset > 0) { From 4737910b69eba83b5ba6dd2d43f88a7bd3461ccf Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 6 Jun 2011 21:28:16 +0000 Subject: [PATCH 0113/2394] - Added new parameter parsing option (p - for valid path (string without null byte in the middle)) # The tests will be fixed in the next commits --- Zend/zend_API.c | 11 +- Zend/zend_API.h | 3 + Zend/zend_language_scanner.c | 2 +- Zend/zend_language_scanner_defs.h | 2 +- Zend/zend_vm_def.h | 96 +++---- Zend/zend_vm_execute.h | 384 +++++++++++++++------------- ext/bz2/bz2.c | 6 +- ext/com_dotnet/com_persist.c | 4 +- ext/dom/document.c | 4 +- ext/enchant/enchant.c | 2 +- ext/exif/exif.c | 4 +- ext/fileinfo/fileinfo.c | 2 +- ext/ftp/php_ftp.c | 14 +- ext/gd/gd.c | 4 +- ext/gd/gd_ctx.c | 2 +- ext/hash/hash.c | 3 + ext/hash/hash_md.c | 2 +- ext/hash/hash_sha.c | 2 +- ext/imap/php_imap.c | 2 +- ext/oci8/oci8_interface.c | 18 +- ext/odbc/php_odbc.c | 4 + ext/openssl/openssl.c | 16 +- ext/pdo_pgsql/pgsql_driver.c | 4 +- ext/pgsql/pgsql.c | 16 +- ext/phar/func_interceptors.c | 14 +- ext/posix/posix.c | 6 +- ext/pspell/pspell.c | 6 +- ext/readline/readline.c | 4 +- ext/simplexml/simplexml.c | 4 +- ext/snmp/snmp.c | 2 +- ext/spl/spl_directory.c | 2 +- ext/sqlite3/sqlite3.c | 2 +- ext/standard/basic_functions.c | 6 +- ext/standard/dir.c | 6 +- ext/standard/file.c | 10 +- ext/standard/filestat.c | 16 +- ext/standard/ftok.c | 2 +- ext/standard/iptc.c | 2 +- ext/standard/link.c | 6 +- ext/standard/link_win32.c | 6 +- ext/standard/md5.c | 2 +- ext/standard/sha1.c | 2 +- ext/tidy/tidy.c | 8 +- ext/xmlreader/php_xmlreader.c | 6 +- ext/xsl/xsltprocessor.c | 4 +- ext/zip/php_zip.c | 18 +- ext/zlib/zlib.c | 2 +- main/fopen_wrappers.c | 2 +- sapi/apache/php_apache.c | 2 +- sapi/apache2filter/php_functions.c | 4 +- sapi/apache2handler/php_functions.c | 4 +- 51 files changed, 402 insertions(+), 353 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index ff7d8dfd66e53..cd5e52f20d5a1 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -406,6 +406,7 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha } break; + case 'p': case 's': { char **p = va_arg(*va, char **); @@ -432,17 +433,23 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha } *p = Z_STRVAL_PP(arg); *pl = Z_STRLEN_PP(arg); + if (c == 'p' && CHECK_ZVAL_NULL_PATH(*arg)) { + return "valid path"; + } break; case IS_OBJECT: if (parse_arg_object_to_string(arg, p, pl, IS_STRING TSRMLS_CC) == SUCCESS) { + if (c == 'p' && CHECK_ZVAL_NULL_PATH(*arg)) { + return "valid path"; + } break; } case IS_ARRAY: case IS_RESOURCE: default: - return "string"; + return c == 's' ? "string" : "valid path"; } } break; @@ -708,7 +715,7 @@ static int zend_parse_va_args(int num_args, const char *type_spec, va_list *va, case 'z': case 'Z': case 'C': case 'h': case 'f': case 'A': - case 'H': + case 'H': case 'p': max_num_args++; break; diff --git a/Zend/zend_API.h b/Zend/zend_API.h index f75ce5038b379..db040f6be46fd 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -526,6 +526,9 @@ END_EXTERN_C() #define CHECK_ZVAL_STRING_REL(z) #endif +#define CHECK_ZVAL_NULL_PATH(p) (Z_STRLEN_P(p) != strlen(Z_STRVAL_P(p))) +#define CHECK_NULL_PATH(p, l) (strlen(p) != l) + #define ZVAL_RESOURCE(z, l) do { \ zval *__z = (z); \ Z_LVAL_P(__z) = l; \ diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 73c5f8207f4a0..96d775e1d3071 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Thu Jun 2 18:02:57 2011 */ +/* Generated by re2c 0.13.5 on Sun Jun 5 21:39:30 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 6f3efea38856a..f0bd4af35b922 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Thu Jun 2 18:02:57 2011 */ +/* Generated by re2c 0.13.5 on Sun Jun 5 21:39:30 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index a76352799a06f..c25b7a7a7471e 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -3637,58 +3637,66 @@ ZEND_VM_HANDLER(73, ZEND_INCLUDE_OR_EVAL, CONST|TMP|VAR|CV, ANY) inc_filename = &tmp_inc_filename; } - switch (opline->extended_value) { - case ZEND_INCLUDE_ONCE: - case ZEND_REQUIRE_ONCE: { - zend_file_handle file_handle; - char *resolved_path; - - resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); - if (resolved_path) { - failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); - } else { - resolved_path = Z_STRVAL_P(inc_filename); - } + if (opline->extended_value != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) { + if (opline->extended_value == ZEND_INCLUDE_ONCE || opline->extended_value == ZEND_INCLUDE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } + } else { + switch (opline->extended_value) { + case ZEND_INCLUDE_ONCE: + case ZEND_REQUIRE_ONCE: { + zend_file_handle file_handle; + char *resolved_path; + + resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); + if (resolved_path) { + failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); + } else { + resolved_path = Z_STRVAL_P(inc_filename); + } - if (failure_retval) { - /* do nothing, file already included */ - } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + if (failure_retval) { + /* do nothing, file already included */ + } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { - if (!file_handle.opened_path) { - file_handle.opened_path = estrdup(resolved_path); - } + if (!file_handle.opened_path) { + file_handle.opened_path = estrdup(resolved_path); + } - if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { - new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); - zend_destroy_file_handle(&file_handle TSRMLS_CC); + if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { + new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); + zend_destroy_file_handle(&file_handle TSRMLS_CC); + } else { + zend_file_handle_dtor(&file_handle TSRMLS_CC); + failure_retval=1; + } } else { - zend_file_handle_dtor(&file_handle TSRMLS_CC); - failure_retval=1; + if (opline->extended_value == ZEND_INCLUDE_ONCE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } } - } else { - if (opline->extended_value == ZEND_INCLUDE_ONCE) { - zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); - } else { - zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + if (resolved_path != Z_STRVAL_P(inc_filename)) { + efree(resolved_path); } } - if (resolved_path != Z_STRVAL_P(inc_filename)) { - efree(resolved_path); - } - } - break; - case ZEND_INCLUDE: - case ZEND_REQUIRE: - new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); - break; - case ZEND_EVAL: { - char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); + break; + case ZEND_INCLUDE: + case ZEND_REQUIRE: + new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); + break; + case ZEND_EVAL: { + char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); - new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); - efree(eval_desc); - } - break; - EMPTY_SWITCH_DEFAULT_CASE() + new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); + efree(eval_desc); + } + break; + EMPTY_SWITCH_DEFAULT_CASE() + } } if (inc_filename==&tmp_inc_filename) { zval_dtor(&tmp_inc_filename); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 899aa572bd724..63db4987d679f 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -2285,58 +2285,66 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HA inc_filename = &tmp_inc_filename; } - switch (opline->extended_value) { - case ZEND_INCLUDE_ONCE: - case ZEND_REQUIRE_ONCE: { - zend_file_handle file_handle; - char *resolved_path; - - resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); - if (resolved_path) { - failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); - } else { - resolved_path = Z_STRVAL_P(inc_filename); - } - - if (failure_retval) { - /* do nothing, file already included */ - } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + if (opline->extended_value != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) { + if (opline->extended_value == ZEND_INCLUDE_ONCE || opline->extended_value == ZEND_INCLUDE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } + } else { + switch (opline->extended_value) { + case ZEND_INCLUDE_ONCE: + case ZEND_REQUIRE_ONCE: { + zend_file_handle file_handle; + char *resolved_path; - if (!file_handle.opened_path) { - file_handle.opened_path = estrdup(resolved_path); + resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); + if (resolved_path) { + failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); + } else { + resolved_path = Z_STRVAL_P(inc_filename); } - if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { - new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); - zend_destroy_file_handle(&file_handle TSRMLS_CC); + if (failure_retval) { + /* do nothing, file already included */ + } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + + if (!file_handle.opened_path) { + file_handle.opened_path = estrdup(resolved_path); + } + + if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { + new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); + zend_destroy_file_handle(&file_handle TSRMLS_CC); + } else { + zend_file_handle_dtor(&file_handle TSRMLS_CC); + failure_retval=1; + } } else { - zend_file_handle_dtor(&file_handle TSRMLS_CC); - failure_retval=1; + if (opline->extended_value == ZEND_INCLUDE_ONCE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } } - } else { - if (opline->extended_value == ZEND_INCLUDE_ONCE) { - zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); - } else { - zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + if (resolved_path != Z_STRVAL_P(inc_filename)) { + efree(resolved_path); } } - if (resolved_path != Z_STRVAL_P(inc_filename)) { - efree(resolved_path); - } - } - break; - case ZEND_INCLUDE: - case ZEND_REQUIRE: - new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); - break; - case ZEND_EVAL: { - char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); + break; + case ZEND_INCLUDE: + case ZEND_REQUIRE: + new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); + break; + case ZEND_EVAL: { + char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); - new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); - efree(eval_desc); - } - break; - EMPTY_SWITCH_DEFAULT_CASE() + new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); + efree(eval_desc); + } + break; + EMPTY_SWITCH_DEFAULT_CASE() + } } if (inc_filename==&tmp_inc_filename) { zval_dtor(&tmp_inc_filename); @@ -6538,58 +6546,66 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND inc_filename = &tmp_inc_filename; } - switch (opline->extended_value) { - case ZEND_INCLUDE_ONCE: - case ZEND_REQUIRE_ONCE: { - zend_file_handle file_handle; - char *resolved_path; - - resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); - if (resolved_path) { - failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); - } else { - resolved_path = Z_STRVAL_P(inc_filename); - } - - if (failure_retval) { - /* do nothing, file already included */ - } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + if (opline->extended_value != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) { + if (opline->extended_value == ZEND_INCLUDE_ONCE || opline->extended_value == ZEND_INCLUDE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } + } else { + switch (opline->extended_value) { + case ZEND_INCLUDE_ONCE: + case ZEND_REQUIRE_ONCE: { + zend_file_handle file_handle; + char *resolved_path; - if (!file_handle.opened_path) { - file_handle.opened_path = estrdup(resolved_path); + resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); + if (resolved_path) { + failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); + } else { + resolved_path = Z_STRVAL_P(inc_filename); } - if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { - new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); - zend_destroy_file_handle(&file_handle TSRMLS_CC); + if (failure_retval) { + /* do nothing, file already included */ + } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + + if (!file_handle.opened_path) { + file_handle.opened_path = estrdup(resolved_path); + } + + if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { + new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); + zend_destroy_file_handle(&file_handle TSRMLS_CC); + } else { + zend_file_handle_dtor(&file_handle TSRMLS_CC); + failure_retval=1; + } } else { - zend_file_handle_dtor(&file_handle TSRMLS_CC); - failure_retval=1; + if (opline->extended_value == ZEND_INCLUDE_ONCE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } } - } else { - if (opline->extended_value == ZEND_INCLUDE_ONCE) { - zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); - } else { - zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + if (resolved_path != Z_STRVAL_P(inc_filename)) { + efree(resolved_path); } } - if (resolved_path != Z_STRVAL_P(inc_filename)) { - efree(resolved_path); - } - } - break; - case ZEND_INCLUDE: - case ZEND_REQUIRE: - new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); - break; - case ZEND_EVAL: { - char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); + break; + case ZEND_INCLUDE: + case ZEND_REQUIRE: + new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); + break; + case ZEND_EVAL: { + char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); - new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); - efree(eval_desc); - } - break; - EMPTY_SWITCH_DEFAULT_CASE() + new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); + efree(eval_desc); + } + break; + EMPTY_SWITCH_DEFAULT_CASE() + } } if (inc_filename==&tmp_inc_filename) { zval_dtor(&tmp_inc_filename); @@ -10817,58 +10833,66 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND inc_filename = &tmp_inc_filename; } - switch (opline->extended_value) { - case ZEND_INCLUDE_ONCE: - case ZEND_REQUIRE_ONCE: { - zend_file_handle file_handle; - char *resolved_path; - - resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); - if (resolved_path) { - failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); - } else { - resolved_path = Z_STRVAL_P(inc_filename); - } - - if (failure_retval) { - /* do nothing, file already included */ - } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + if (opline->extended_value != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) { + if (opline->extended_value == ZEND_INCLUDE_ONCE || opline->extended_value == ZEND_INCLUDE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } + } else { + switch (opline->extended_value) { + case ZEND_INCLUDE_ONCE: + case ZEND_REQUIRE_ONCE: { + zend_file_handle file_handle; + char *resolved_path; - if (!file_handle.opened_path) { - file_handle.opened_path = estrdup(resolved_path); + resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); + if (resolved_path) { + failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); + } else { + resolved_path = Z_STRVAL_P(inc_filename); } - if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { - new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); - zend_destroy_file_handle(&file_handle TSRMLS_CC); + if (failure_retval) { + /* do nothing, file already included */ + } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + + if (!file_handle.opened_path) { + file_handle.opened_path = estrdup(resolved_path); + } + + if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { + new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); + zend_destroy_file_handle(&file_handle TSRMLS_CC); + } else { + zend_file_handle_dtor(&file_handle TSRMLS_CC); + failure_retval=1; + } } else { - zend_file_handle_dtor(&file_handle TSRMLS_CC); - failure_retval=1; + if (opline->extended_value == ZEND_INCLUDE_ONCE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } } - } else { - if (opline->extended_value == ZEND_INCLUDE_ONCE) { - zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); - } else { - zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + if (resolved_path != Z_STRVAL_P(inc_filename)) { + efree(resolved_path); } } - if (resolved_path != Z_STRVAL_P(inc_filename)) { - efree(resolved_path); - } - } - break; - case ZEND_INCLUDE: - case ZEND_REQUIRE: - new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); - break; - case ZEND_EVAL: { - char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); + break; + case ZEND_INCLUDE: + case ZEND_REQUIRE: + new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); + break; + case ZEND_EVAL: { + char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); - new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); - efree(eval_desc); - } - break; - EMPTY_SWITCH_DEFAULT_CASE() + new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); + efree(eval_desc); + } + break; + EMPTY_SWITCH_DEFAULT_CASE() + } } if (inc_filename==&tmp_inc_filename) { zval_dtor(&tmp_inc_filename); @@ -26478,58 +26502,66 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL inc_filename = &tmp_inc_filename; } - switch (opline->extended_value) { - case ZEND_INCLUDE_ONCE: - case ZEND_REQUIRE_ONCE: { - zend_file_handle file_handle; - char *resolved_path; - - resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); - if (resolved_path) { - failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); - } else { - resolved_path = Z_STRVAL_P(inc_filename); - } - - if (failure_retval) { - /* do nothing, file already included */ - } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + if (opline->extended_value != ZEND_EVAL && strlen(Z_STRVAL_P(inc_filename)) != Z_STRLEN_P(inc_filename)) { + if (opline->extended_value == ZEND_INCLUDE_ONCE || opline->extended_value == ZEND_INCLUDE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } + } else { + switch (opline->extended_value) { + case ZEND_INCLUDE_ONCE: + case ZEND_REQUIRE_ONCE: { + zend_file_handle file_handle; + char *resolved_path; - if (!file_handle.opened_path) { - file_handle.opened_path = estrdup(resolved_path); + resolved_path = zend_resolve_path(Z_STRVAL_P(inc_filename), Z_STRLEN_P(inc_filename) TSRMLS_CC); + if (resolved_path) { + failure_retval = zend_hash_exists(&EG(included_files), resolved_path, strlen(resolved_path)+1); + } else { + resolved_path = Z_STRVAL_P(inc_filename); } - if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { - new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); - zend_destroy_file_handle(&file_handle TSRMLS_CC); + if (failure_retval) { + /* do nothing, file already included */ + } else if (SUCCESS == zend_stream_open(resolved_path, &file_handle TSRMLS_CC)) { + + if (!file_handle.opened_path) { + file_handle.opened_path = estrdup(resolved_path); + } + + if (zend_hash_add_empty_element(&EG(included_files), file_handle.opened_path, strlen(file_handle.opened_path)+1)==SUCCESS) { + new_op_array = zend_compile_file(&file_handle, (opline->extended_value==ZEND_INCLUDE_ONCE?ZEND_INCLUDE:ZEND_REQUIRE) TSRMLS_CC); + zend_destroy_file_handle(&file_handle TSRMLS_CC); + } else { + zend_file_handle_dtor(&file_handle TSRMLS_CC); + failure_retval=1; + } } else { - zend_file_handle_dtor(&file_handle TSRMLS_CC); - failure_retval=1; + if (opline->extended_value == ZEND_INCLUDE_ONCE) { + zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } else { + zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + } } - } else { - if (opline->extended_value == ZEND_INCLUDE_ONCE) { - zend_message_dispatcher(ZMSG_FAILED_INCLUDE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); - } else { - zend_message_dispatcher(ZMSG_FAILED_REQUIRE_FOPEN, Z_STRVAL_P(inc_filename) TSRMLS_CC); + if (resolved_path != Z_STRVAL_P(inc_filename)) { + efree(resolved_path); } } - if (resolved_path != Z_STRVAL_P(inc_filename)) { - efree(resolved_path); - } - } - break; - case ZEND_INCLUDE: - case ZEND_REQUIRE: - new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); - break; - case ZEND_EVAL: { - char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); + break; + case ZEND_INCLUDE: + case ZEND_REQUIRE: + new_op_array = compile_filename(opline->extended_value, inc_filename TSRMLS_CC); + break; + case ZEND_EVAL: { + char *eval_desc = zend_make_compiled_string_description("eval()'d code" TSRMLS_CC); - new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); - efree(eval_desc); - } - break; - EMPTY_SWITCH_DEFAULT_CASE() + new_op_array = zend_compile_string(inc_filename, eval_desc TSRMLS_CC); + efree(eval_desc); + } + break; + EMPTY_SWITCH_DEFAULT_CASE() + } } if (inc_filename==&tmp_inc_filename) { zval_dtor(&tmp_inc_filename); diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c index dafe4b25abaf9..1e3c7b7617e3b 100644 --- a/ext/bz2/bz2.c +++ b/ext/bz2/bz2.c @@ -385,12 +385,14 @@ static PHP_FUNCTION(bzopen) /* If it's not a resource its a string containing the filename to open */ if (Z_TYPE_PP(file) == IS_STRING) { - convert_to_string_ex(file); - if (Z_STRLEN_PP(file) == 0) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "filename cannot be empty"); RETURN_FALSE; } + + if (CHECK_ZVAL_NULL_PATH(*file)) { + RETURN_FALSE; + } stream = php_stream_bz2open(NULL, Z_STRVAL_PP(file), diff --git a/ext/com_dotnet/com_persist.c b/ext/com_dotnet/com_persist.c index 56611987b296a..c72bf622a417f 100755 --- a/ext/com_dotnet/com_persist.c +++ b/ext/com_dotnet/com_persist.c @@ -379,7 +379,7 @@ CPH_METHOD(SaveToFile) res = get_persist_file(helper); if (helper->ipf) { - if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!|b", + if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p!|b", &filename, &filename_len, &remember)) { php_com_throw_exception(E_INVALIDARG, "Invalid arguments" TSRMLS_CC); return; @@ -443,7 +443,7 @@ CPH_METHOD(LoadFromFile) res = get_persist_file(helper); if (helper->ipf) { - if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", + if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &filename, &filename_len, &flags)) { php_com_throw_exception(E_INVALIDARG, "Invalid arguments" TSRMLS_CC); return; diff --git a/ext/dom/document.c b/ext/dom/document.c index 6499b55f64d90..e01e2c34d6687 100644 --- a/ext/dom/document.c +++ b/ext/dom/document.c @@ -1979,7 +1979,7 @@ static void _dom_document_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type int is_valid; char resolved_path[MAXPATHLEN + 1]; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &source, &source_len) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Op", &id, dom_document_class_entry, &source, &source_len) == FAILURE) { return; } @@ -2068,7 +2068,7 @@ static void _dom_document_relaxNG_validate(INTERNAL_FUNCTION_PARAMETERS, int typ int is_valid; char resolved_path[MAXPATHLEN + 1]; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &source, &source_len) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Op", &id, dom_document_class_entry, &source, &source_len) == FAILURE) { return; } diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c index bfac6f57c5f04..81404db53aab1 100755 --- a/ext/enchant/enchant.c +++ b/ext/enchant/enchant.c @@ -587,7 +587,7 @@ PHP_FUNCTION(enchant_broker_request_pwl_dict) int pwllen; int pos; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &broker, &pwl, &pwllen) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rp", &broker, &pwl, &pwllen) == FAILURE) { RETURN_FALSE; } diff --git a/ext/exif/exif.c b/ext/exif/exif.c index 04abb953b1fb1..f5e837484581a 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -3938,7 +3938,7 @@ PHP_FUNCTION(exif_read_data) image_info_type ImageInfo; char tmp[64], *sections_str, *s; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|sbb", &p_name, &p_name_len, &p_sections_needed, &p_sections_needed_len, &sub_arrays, &read_thumbnail) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|sbb", &p_name, &p_name_len, &p_sections_needed, &p_sections_needed_len, &sub_arrays, &read_thumbnail) == FAILURE) { return; } @@ -4119,7 +4119,7 @@ PHP_FUNCTION(exif_thumbnail) WRONG_PARAM_COUNT; } - if (zend_parse_parameters(arg_c TSRMLS_CC, "s|z/z/z/", &p_name, &p_name_len, &p_width, &p_height, &p_imagetype) == FAILURE) { + if (zend_parse_parameters(arg_c TSRMLS_CC, "p|z/z/z/", &p_name, &p_name_len, &p_width, &p_height, &p_imagetype) == FAILURE) { return; } diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c index e5d28e88cec7d..613c043771ef7 100644 --- a/ext/fileinfo/fileinfo.c +++ b/ext/fileinfo/fileinfo.c @@ -286,7 +286,7 @@ PHP_FUNCTION(finfo_open) FILEINFO_DECLARE_INIT_OBJECT(object) char resolved_path[MAXPATHLEN]; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ls", &options, &file, &file_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|lp", &options, &file, &file_len) == FAILURE) { RETURN_FALSE; } diff --git a/ext/ftp/php_ftp.c b/ext/ftp/php_ftp.c index e62243e949c40..6c44733fedfc7 100644 --- a/ext/ftp/php_ftp.c +++ b/ext/ftp/php_ftp.c @@ -607,7 +607,7 @@ PHP_FUNCTION(ftp_chmod) int filename_len; long mode; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rls", &z_ftp, &mode, &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rlp", &z_ftp, &mode, &filename, &filename_len) == FAILURE) { RETURN_FALSE; } @@ -660,7 +660,7 @@ PHP_FUNCTION(ftp_nlist) char **nlist, **ptr, *dir; int dir_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_ftp, &dir, &dir_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rp", &z_ftp, &dir, &dir_len) == FAILURE) { return; } @@ -857,7 +857,7 @@ PHP_FUNCTION(ftp_get) int local_len, remote_len; long mode, resumepos=0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rssl|l", &z_ftp, &local, &local_len, &remote, &remote_len, &mode, &resumepos) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rppl|l", &z_ftp, &local, &local_len, &remote, &remote_len, &mode, &resumepos) == FAILURE) { return; } @@ -1124,7 +1124,7 @@ PHP_FUNCTION(ftp_put) long mode, startpos=0; php_stream *instream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rssl|l", &z_ftp, &remote, &remote_len, &local, &local_len, &mode, &startpos) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rppl|l", &z_ftp, &remote, &remote_len, &local, &local_len, &mode, &startpos) == FAILURE) { return; } @@ -1177,7 +1177,7 @@ PHP_FUNCTION(ftp_nb_put) long mode, startpos=0; php_stream *instream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rssl|l", &z_ftp, &remote, &remote_len, &local, &local_len, &mode, &startpos) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rppl|l", &z_ftp, &remote, &remote_len, &local, &local_len, &mode, &startpos) == FAILURE) { return; } @@ -1233,7 +1233,7 @@ PHP_FUNCTION(ftp_size) char *file; int file_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_ftp, &file, &file_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rp", &z_ftp, &file, &file_len) == FAILURE) { return; } @@ -1253,7 +1253,7 @@ PHP_FUNCTION(ftp_mdtm) char *file; int file_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_ftp, &file, &file_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rp", &z_ftp, &file, &file_len) == FAILURE) { return; } diff --git a/ext/gd/gd.c b/ext/gd/gd.c index 38abecdd3aafe..1fe321773c5ef 100644 --- a/ext/gd/gd.c +++ b/ext/gd/gd.c @@ -2673,7 +2673,7 @@ static void _php_image_output(INTERNAL_FUNCTION_PARAMETERS, int image_type, char /* When called from imagewbmp() the quality parameter stands for the foreground color. Default: black. */ /* The quality parameter for gd2 stands for chunk size */ - if (zend_parse_parameters(argc TSRMLS_CC, "r|sll", &imgind, &file, &file_len, &quality, &type) == FAILURE) { + if (zend_parse_parameters(argc TSRMLS_CC, "r|pll", &imgind, &file, &file_len, &quality, &type) == FAILURE) { return; } @@ -4592,7 +4592,7 @@ static void _php_image_convert(INTERNAL_FUNCTION_PARAMETERS, int image_type ) long ignore_warning; #endif - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sslll", &f_org, &f_org_len, &f_dest, &f_dest_len, &height, &width, &threshold) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pplll", &f_org, &f_org_len, &f_dest, &f_dest_len, &height, &width, &threshold) == FAILURE) { return; } diff --git a/ext/gd/gd_ctx.c b/ext/gd/gd_ctx.c index 15319c1a78239..6ee174db7447d 100644 --- a/ext/gd/gd_ctx.c +++ b/ext/gd/gd_ctx.c @@ -93,7 +93,7 @@ static void _php_image_output_ctx(INTERNAL_FUNCTION_PARAMETERS, int image_type, * from imagey(). */ if (image_type == PHP_GDIMG_TYPE_XBM) { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs!|ll", &imgind, &file, &file_len, &quality, &basefilter) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rp!|ll", &imgind, &file, &file_len, &quality, &basefilter) == FAILURE) { return; } } else { diff --git a/ext/hash/hash.c b/ext/hash/hash.c index e994e9e157666..1c2d4241c40d8 100644 --- a/ext/hash/hash.c +++ b/ext/hash/hash.c @@ -141,6 +141,9 @@ static void php_hash_do_hash(INTERNAL_FUNCTION_PARAMETERS, int isfilename, zend_ RETURN_FALSE; } if (isfilename) { + if (CHECK_NULL_PATH(data, data_len)) { + RETURN_FALSE; + } stream = php_stream_open_wrapper_ex(data, "rb", REPORT_ERRORS, NULL, DEFAULT_CONTEXT); if (!stream) { /* Stream will report errors opening file */ diff --git a/ext/hash/hash_md.c b/ext/hash/hash_md.c index 6d9f0518b9bda..4e7ca282041ba 100644 --- a/ext/hash/hash_md.c +++ b/ext/hash/hash_md.c @@ -144,7 +144,7 @@ PHP_NAMED_FUNCTION(php_if_md5_file) int n; php_stream *stream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &arg, &arg_len, &raw_output) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &arg, &arg_len, &raw_output) == FAILURE) { return; } diff --git a/ext/hash/hash_sha.c b/ext/hash/hash_sha.c index 991d7db404ddc..6e58c444dccec 100644 --- a/ext/hash/hash_sha.c +++ b/ext/hash/hash_sha.c @@ -128,7 +128,7 @@ PHP_FUNCTION(sha1_file) int n; php_stream *stream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &arg, &arg_len, &raw_output) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &arg, &arg_len, &raw_output) == FAILURE) { return; } diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index 819ef51b6d323..34fae16763353 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -1153,7 +1153,7 @@ static void php_imap_do_open(INTERNAL_FUNCTION_PARAMETERS, int persistent) zval *params = NULL; int argc = ZEND_NUM_ARGS(); - if (zend_parse_parameters(argc TSRMLS_CC, "sss|lla", &mailbox, &mailbox_len, &user, &user_len, + if (zend_parse_parameters(argc TSRMLS_CC, "pss|lla", &mailbox, &mailbox_len, &user, &user_len, &passwd, &passwd_len, &flags, &retries, ¶ms) == FAILURE) { return; } diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c index 699eccb4a2e63..b1d454e61220a 100644 --- a/ext/oci8/oci8_interface.c +++ b/ext/oci8/oci8_interface.c @@ -233,21 +233,16 @@ PHP_FUNCTION(oci_lob_import) int filename_len; if (getThis()) { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } } else { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Os", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Op", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len) == FAILURE) { return; } } - if (strlen(filename) != filename_len) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Filename cannot contain null bytes"); - RETURN_FALSE; - } - if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property"); RETURN_FALSE; @@ -872,7 +867,7 @@ PHP_FUNCTION(oci_lob_export) ub4 lob_length; if (getThis()) { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|ll", &filename, &filename_len, &start, &length) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|ll", &filename, &filename_len, &start, &length) == FAILURE) { return; } @@ -886,7 +881,7 @@ PHP_FUNCTION(oci_lob_export) } } else { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Os|ll", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len, &start, &length) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Op|ll", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len, &start, &length) == FAILURE) { return; } @@ -900,11 +895,6 @@ PHP_FUNCTION(oci_lob_export) } } - if (strlen(filename) != filename_len) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Filename cannot contain null bytes"); - RETURN_FALSE; - } - if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property"); RETURN_FALSE; diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c index a036d3b7a725d..5275a35b451db 100644 --- a/ext/odbc/php_odbc.c +++ b/ext/odbc/php_odbc.c @@ -1317,6 +1317,10 @@ PHP_FUNCTION(odbc_execute) if (Z_STRLEN_PP(tmp) > 2 && Z_STRVAL_PP(tmp)[0] == '\'' && Z_STRVAL_PP(tmp)[Z_STRLEN_PP(tmp) - 1] == '\'') { + + if (CHECK_ZVAL_NULL_PATH(*tmp)) { + RETURN_FALSE; + } filename = estrndup(&Z_STRVAL_PP(tmp)[1], Z_STRLEN_PP(tmp) - 2); filename[strlen(filename)] = '\0'; diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 4377d2b52e039..0c61b5a254a0a 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -1259,7 +1259,7 @@ PHP_FUNCTION(openssl_x509_export_to_file) char * filename; int filename_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zs|b", &zcert, &filename, &filename_len, ¬ext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zp|b", &zcert, &filename, &filename_len, ¬ext) == FAILURE) { return; } RETVAL_FALSE; @@ -1808,7 +1808,7 @@ PHP_FUNCTION(openssl_pkcs12_export_to_file) zval ** item; STACK_OF(X509) *ca = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zszs|a", &zcert, &filename, &filename_len, &zpkey, &pass, &pass_len, &args) == FAILURE) + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zpzs|a", &zcert, &filename, &filename_len, &zpkey, &pass, &pass_len, &args) == FAILURE) return; RETVAL_FALSE; @@ -2255,7 +2255,7 @@ PHP_FUNCTION(openssl_csr_export_to_file) BIO * bio_out; long csr_resource; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|b", &zcsr, &filename, &filename_len, ¬ext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rp|b", &zcsr, &filename, &filename_len, ¬ext) == FAILURE) { return; } RETVAL_FALSE; @@ -3039,7 +3039,7 @@ PHP_FUNCTION(openssl_pkey_export_to_file) BIO * bio_out = NULL; const EVP_CIPHER * cipher; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zs|s!a!", &zpkey, &filename, &filename_len, &passphrase, &passphrase_len, &args) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zṕ|s!a!", &zpkey, &filename, &filename_len, &passphrase, &passphrase_len, &args) == FAILURE) { return; } RETVAL_FALSE; @@ -3327,7 +3327,7 @@ PHP_FUNCTION(openssl_pkcs7_verify) RETVAL_LONG(-1); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|sass", &filename, &filename_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pl|papp", &filename, &filename_len, &flags, &signersfilename, &signersfilename_len, &cainfo, &extracerts, &extracerts_len, &datafilename, &datafilename_len) == FAILURE) { return; @@ -3440,7 +3440,7 @@ PHP_FUNCTION(openssl_pkcs7_encrypt) RETVAL_FALSE; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ssZa!|ll", &infilename, &infilename_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ppZa!|ll", &infilename, &infilename_len, &outfilename, &outfilename_len, &zrecipcerts, &zheaders, &flags, &cipherid) == FAILURE) return; @@ -3576,7 +3576,7 @@ PHP_FUNCTION(openssl_pkcs7_sign) char * outfilename; int outfilename_len; char * extracertsfilename = NULL; int extracertsfilename_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ssZZa!|ls", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ppZZa!|lp", &infilename, &infilename_len, &outfilename, &outfilename_len, &zcert, &zprivkey, &zheaders, &flags, &extracertsfilename, &extracertsfilename_len) == FAILURE) { @@ -3680,7 +3680,7 @@ PHP_FUNCTION(openssl_pkcs7_decrypt) char * infilename; int infilename_len; char * outfilename; int outfilename_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ssZ|Z", &infilename, &infilename_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ppZ|Z", &infilename, &infilename_len, &outfilename, &outfilename_len, &recipcert, &recipkey) == FAILURE) { return; } diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c index 72f811eb3a3e8..45f05fa2c7656 100644 --- a/ext/pdo_pgsql/pgsql_driver.c +++ b/ext/pdo_pgsql/pgsql_driver.c @@ -628,7 +628,7 @@ static PHP_METHOD(PDO, pgsqlCopyFromFile) ExecStatusType status; php_stream *stream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|sss", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sp|sss", &table_name, &table_name_len, &filename, &filename_len, &pg_delim, &pg_delim_len, &pg_null_as, &pg_null_as_len, &pg_fields, &pg_fields_len) == FAILURE) { return; @@ -722,7 +722,7 @@ static PHP_METHOD(PDO, pgsqlCopyToFile) php_stream *stream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|sss", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sp|sss", &table_name, &table_name_len, &filename, &filename_len, &pg_delim, &pg_delim_len, &pg_null_as, &pg_null_as_len, &pg_fields, &pg_fields_len) == FAILURE) { return; diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c index d321ec4883486..9ab1a071e6ae6 100644 --- a/ext/pgsql/pgsql.c +++ b/ext/pgsql/pgsql.c @@ -3322,17 +3322,17 @@ PHP_FUNCTION(pg_lo_import) Oid returned_oid; if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "rs|z", &pgsql_link, &file_in, &name_len, &oid) == SUCCESS) { + "rp|z", &pgsql_link, &file_in, &name_len, &oid) == SUCCESS) { ; } else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "s|z", &file_in, &name_len, &oid) == SUCCESS) { + "p|z", &file_in, &name_len, &oid) == SUCCESS) { id = PGG(default_link); CHECK_DEFAULT_LINK(id); } /* old calling convention, deprecated since PHP 4.2 */ else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "sr", &file_in, &name_len, &pgsql_link ) == SUCCESS) { + "pr", &file_in, &name_len, &pgsql_link ) == SUCCESS) { php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Old API is used"); } else { @@ -3412,7 +3412,7 @@ PHP_FUNCTION(pg_lo_export) /* allow string to handle large OID value correctly */ if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "rls", &pgsql_link, &oid_long, &file_out, &name_len) == SUCCESS) { + "rlp", &pgsql_link, &oid_long, &file_out, &name_len) == SUCCESS) { if (oid_long <= InvalidOid) { php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Invalid OID specified"); RETURN_FALSE; @@ -3429,7 +3429,7 @@ PHP_FUNCTION(pg_lo_export) } } else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "ls", &oid_long, &file_out, &name_len) == SUCCESS) { + "lp", &oid_long, &file_out, &name_len) == SUCCESS) { if (oid_long <= InvalidOid) { php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Invalid OID specified"); RETURN_FALSE; @@ -3439,7 +3439,7 @@ PHP_FUNCTION(pg_lo_export) CHECK_DEFAULT_LINK(id); } else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "ss", &oid_string, &oid_strlen, &file_out, &name_len) == SUCCESS) { + "sp", &oid_string, &oid_strlen, &file_out, &name_len) == SUCCESS) { oid = (Oid)strtoul(oid_string, &end_ptr, 10); if ((oid_string+oid_strlen) != end_ptr) { /* wrong integer format */ @@ -3450,7 +3450,7 @@ PHP_FUNCTION(pg_lo_export) CHECK_DEFAULT_LINK(id); } else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "ssr", &oid_string, &oid_strlen, &file_out, &name_len, &pgsql_link) == SUCCESS) { + "spr", &oid_string, &oid_strlen, &file_out, &name_len, &pgsql_link) == SUCCESS) { oid = (Oid)strtoul(oid_string, &end_ptr, 10); if ((oid_string+oid_strlen) != end_ptr) { /* wrong integer format */ @@ -3459,7 +3459,7 @@ PHP_FUNCTION(pg_lo_export) } } else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, argc TSRMLS_CC, - "lsr", &oid_long, &file_out, &name_len, &pgsql_link) == SUCCESS) { + "lpr", &oid_long, &file_out, &name_len, &pgsql_link) == SUCCESS) { php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Old API is used"); if (oid_long <= InvalidOid) { php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Invalid OID specified"); diff --git a/ext/phar/func_interceptors.c b/ext/phar/func_interceptors.c index 353bc47072b82..1b3f0f461b809 100644 --- a/ext/phar/func_interceptors.c +++ b/ext/phar/func_interceptors.c @@ -38,7 +38,7 @@ PHAR_FUNC(phar_opendir) /* {{{ */ goto skip_phar; } - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|z", &filename, &filename_len, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|z", &filename, &filename_len, &zcontext) == FAILURE) { return; } @@ -113,7 +113,7 @@ PHAR_FUNC(phar_file_get_contents) /* {{{ */ } /* Parse arguments */ - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "s|br!ll", &filename, &filename_len, &use_include_path, &zcontext, &offset, &maxlen) == FAILURE) { + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "p|br!ll", &filename, &filename_len, &use_include_path, &zcontext, &offset, &maxlen) == FAILURE) { goto skip_phar; } @@ -244,7 +244,7 @@ PHAR_FUNC(phar_readfile) /* {{{ */ && !cached_phars.arBuckets) { goto skip_phar; } - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "s|br!", &filename, &filename_len, &use_include_path, &zcontext) == FAILURE) { + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "p|br!", &filename, &filename_len, &use_include_path, &zcontext) == FAILURE) { goto skip_phar; } if (use_include_path || (!IS_ABSOLUTE_PATH(filename, filename_len) && !strstr(filename, "://"))) { @@ -340,7 +340,7 @@ PHAR_FUNC(phar_fopen) /* {{{ */ /* no need to check, include_path not even specified in fopen/ no active phars */ goto skip_phar; } - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "ss|br", &filename, &filename_len, &mode, &mode_len, &use_include_path, &zcontext) == FAILURE) { + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "ps|br", &filename, &filename_len, &mode, &mode_len, &use_include_path, &zcontext) == FAILURE) { goto skip_phar; } if (use_include_path || (!IS_ABSOLUTE_PATH(filename, filename_len) && !strstr(filename, "://"))) { @@ -813,7 +813,7 @@ void fname(INTERNAL_FUNCTION_PARAMETERS) { \ char *filename; \ int filename_len; \ \ - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { \ + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { \ return; \ } \ \ @@ -905,7 +905,7 @@ PHAR_FUNC(phar_is_file) /* {{{ */ && !cached_phars.arBuckets) { goto skip_phar; } - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { goto skip_phar; } if (!IS_ABSOLUTE_PATH(filename, filename_len) && !strstr(filename, "://")) { @@ -972,7 +972,7 @@ PHAR_FUNC(phar_is_link) /* {{{ */ && !cached_phars.arBuckets) { goto skip_phar; } - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { goto skip_phar; } if (!IS_ABSOLUTE_PATH(filename, filename_len) && !strstr(filename, "://")) { diff --git a/ext/posix/posix.c b/ext/posix/posix.c index 3ac1dc4dfdcf4..580911afa651e 100644 --- a/ext/posix/posix.c +++ b/ext/posix/posix.c @@ -838,7 +838,7 @@ PHP_FUNCTION(posix_mkfifo) long mode; int result; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl", &path, &path_len, &mode) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pl", &path, &path_len, &mode) == FAILURE) { RETURN_FALSE; } @@ -871,7 +871,7 @@ PHP_FUNCTION(posix_mknod) php_dev = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|ll", &path, &path_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pl|ll", &path, &path_len, &mode, &major, &minor) == FAILURE) { RETURN_FALSE; } @@ -951,7 +951,7 @@ PHP_FUNCTION(posix_access) int filename_len, ret; char *filename, *path; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &filename, &filename_len, &mode) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &filename, &filename_len, &mode) == FAILURE) { RETURN_FALSE; } diff --git a/ext/pspell/pspell.c b/ext/pspell/pspell.c index fe6c95bb41efd..abdded3fd21f9 100644 --- a/ext/pspell/pspell.c +++ b/ext/pspell/pspell.c @@ -374,7 +374,7 @@ static PHP_FUNCTION(pspell_new_personal) PspellManager *manager; PspellConfig *config; - if (zend_parse_parameters(argc TSRMLS_CC, "ss|sssl", &personal, &personal_len, &language, &language_len, + if (zend_parse_parameters(argc TSRMLS_CC, "ps|sssl", &personal, &personal_len, &language, &language_len, &spelling, &spelling_len, &jargon, &jargon_len, &encoding, &encoding_len, &mode) == FAILURE) { return; } @@ -825,7 +825,7 @@ static void pspell_config_path(INTERNAL_FUNCTION_PARAMETERS, char *option) int value_len; PspellConfig *config; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &conf, &value, &value_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lp", &conf, &value, &value_len) == FAILURE) { return; } @@ -874,7 +874,7 @@ static PHP_FUNCTION(pspell_config_repl) int repl_len; PspellConfig *config; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &conf, &repl, &repl_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lp", &conf, &repl, &repl_len) == FAILURE) { return; } diff --git a/ext/readline/readline.c b/ext/readline/readline.c index c47491c199e0c..d199cdf51758e 100644 --- a/ext/readline/readline.c +++ b/ext/readline/readline.c @@ -378,7 +378,7 @@ PHP_FUNCTION(readline_read_history) char *arg = NULL; int arg_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s", &arg, &arg_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|p", &arg, &arg_len) == FAILURE) { return; } @@ -398,7 +398,7 @@ PHP_FUNCTION(readline_write_history) char *arg = NULL; int arg_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s", &arg, &arg_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|p", &arg, &arg_len) == FAILURE) { return; } diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index 98dbc0c13ebcb..1d74853cd9c83 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -1365,7 +1365,7 @@ SXE_METHOD(asXML) } if (ZEND_NUM_ARGS() == 1) { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { RETURN_FALSE; } @@ -2148,7 +2148,7 @@ PHP_FUNCTION(simplexml_load_file) zend_class_entry *ce= sxe_class_entry; zend_bool isprefix = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|C!lsb", &filename, &filename_len, &ce, &options, &ns, &ns_len, &isprefix) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|C!lsb", &filename, &filename_len, &ce, &options, &ns, &ns_len, &isprefix) == FAILURE) { return; } diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index d9a2a032310c3..e99d5090e5d89 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -1682,7 +1682,7 @@ PHP_FUNCTION(snmp_read_mib) char *filename; int filename_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { RETURN_FALSE; } diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 4cb3aece625d8..f1eaffe479ef7 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -2238,7 +2238,7 @@ SPL_METHOD(SplFileObject, __construct) intern->u.file.open_mode = NULL; intern->u.file.open_mode_len = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|sbr", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|sbr", &intern->file_name, &intern->file_name_len, &intern->u.file.open_mode, &intern->u.file.open_mode_len, &use_include_path, &intern->u.file.zcontext) == FAILURE) { diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c index d54eb7c567811..9c922414b877b 100644 --- a/ext/sqlite3/sqlite3.c +++ b/ext/sqlite3/sqlite3.c @@ -103,7 +103,7 @@ PHP_METHOD(sqlite3, open) db_obj = (php_sqlite3_db_object *)zend_object_store_get_object(object TSRMLS_CC); zend_replace_error_handling(EH_THROW, NULL, &error_handling TSRMLS_CC); - if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|ls", &filename, &filename_len, &flags, &encryption_key, &encryption_key_len)) { + if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|ls", &filename, &filename_len, &flags, &encryption_key, &encryption_key_len)) { zend_restore_error_handling(&error_handling TSRMLS_CC); return; } diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 4e9d38c54a51f..8211383235cb2 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -5123,7 +5123,7 @@ PHP_FUNCTION(highlight_file) zend_syntax_highlighter_ini syntax_highlighter_ini; zend_bool i = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &filename, &filename_len, &i) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &filename, &filename_len, &i) == FAILURE) { RETURN_FALSE; } @@ -5164,7 +5164,7 @@ PHP_FUNCTION(php_strip_whitespace) zend_lex_state original_lex_state; zend_file_handle file_handle = {0}; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { RETURN_FALSE; } @@ -5894,7 +5894,7 @@ PHP_FUNCTION(parse_ini_file) zend_file_handle fh; zend_ini_parser_cb_t ini_parser_cb; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|bl", &filename, &filename_len, &process_sections, &scanner_mode) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|bl", &filename, &filename_len, &process_sections, &scanner_mode) == FAILURE) { RETURN_FALSE; } diff --git a/ext/standard/dir.c b/ext/standard/dir.c index 284553beaf078..746cd8e238ba0 100644 --- a/ext/standard/dir.c +++ b/ext/standard/dir.c @@ -325,7 +325,7 @@ PHP_FUNCTION(chdir) char *str; int ret, str_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &str, &str_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &str, &str_len) == FAILURE) { RETURN_FALSE; } @@ -436,7 +436,7 @@ PHP_FUNCTION(glob) int ret; zend_bool basedir_limit = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &pattern, &pattern_len, &flags) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &pattern, &pattern_len, &flags) == FAILURE) { return; } @@ -554,7 +554,7 @@ PHP_FUNCTION(scandir) zval *zcontext = NULL; php_stream_context *context = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|lr", &dirn, &dirn_len, &flags, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|lr", &dirn, &dirn_len, &flags, &zcontext) == FAILURE) { return; } diff --git a/ext/standard/file.c b/ext/standard/file.c index 3e45461f7c270..6bb1ad0518b7e 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -831,7 +831,7 @@ PHP_FUNCTION(tempnam) char *p; int fd; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &dir, &dir_len, &prefix, &prefix_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ps", &dir, &dir_len, &prefix, &prefix_len) == FAILURE) { return; } @@ -885,7 +885,7 @@ PHP_NAMED_FUNCTION(php_if_fopen) php_stream *stream; php_stream_context *context = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|br", &filename, &filename_len, &mode, &mode_len, &use_include_path, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ps|br", &filename, &filename_len, &mode, &mode_len, &use_include_path, &zcontext) == FAILURE) { RETURN_FALSE; } @@ -939,7 +939,7 @@ PHP_FUNCTION(popen) php_stream *stream; char *posix_mode; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &command, &command_len, &mode, &mode_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ps", &command, &command_len, &mode, &mode_len) == FAILURE) { return; } @@ -1636,7 +1636,7 @@ PHP_FUNCTION(copy) zval *zcontext = NULL; php_stream_context *context; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|r", &source, &source_len, &target, &target_len, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pp|r", &source, &source_len, &target, &target_len, &zcontext) == FAILURE) { return; } @@ -2331,7 +2331,7 @@ PHP_FUNCTION(realpath) int filename_len; char resolved_path_buff[MAXPATHLEN]; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 34b6468146388..5c4c5d465ed8d 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -235,7 +235,7 @@ PHP_FUNCTION(disk_total_space) char *path; int path_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &path, &path_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &path, &path_len) == FAILURE) { return; } @@ -370,7 +370,7 @@ PHP_FUNCTION(disk_free_space) char *path; int path_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &path, &path_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &path, &path_len) == FAILURE) { return; } @@ -425,7 +425,7 @@ static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ int ret; php_stream_wrapper *wrapper; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/", &filename, &filename_len, &group) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pz/", &filename, &filename_len, &group) == FAILURE) { RETURN_FALSE; } @@ -556,7 +556,7 @@ static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ int ret; php_stream_wrapper *wrapper; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/", &filename, &filename_len, &user) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pz/", &filename, &filename_len, &user) == FAILURE) { return; } @@ -659,7 +659,7 @@ PHP_FUNCTION(chmod) mode_t imode; php_stream_wrapper *wrapper; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl", &filename, &filename_len, &mode) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pl", &filename, &filename_len, &mode) == FAILURE) { return; } @@ -707,7 +707,7 @@ PHP_FUNCTION(touch) struct utimbuf *newtime = &newtimebuf; php_stream_wrapper *wrapper; - if (zend_parse_parameters(argc TSRMLS_CC, "s|ll", &filename, &filename_len, &filetime, &fileatime) == FAILURE) { + if (zend_parse_parameters(argc TSRMLS_CC, "p|ll", &filename, &filename_len, &filetime, &fileatime) == FAILURE) { return; } @@ -817,7 +817,7 @@ PHP_FUNCTION(clearstatcache) char *filename = NULL; int filename_len = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|bs", &clear_realpath_cache, &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|bp", &clear_realpath_cache, &filename, &filename_len) == FAILURE) { return; } @@ -1068,7 +1068,7 @@ void name(INTERNAL_FUNCTION_PARAMETERS) { \ char *filename; \ int filename_len; \ \ - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { \ + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { \ return; \ } \ \ diff --git a/ext/standard/ftok.c b/ext/standard/ftok.c index 809a1e078ac65..8486eb12c7f81 100644 --- a/ext/standard/ftok.c +++ b/ext/standard/ftok.c @@ -35,7 +35,7 @@ PHP_FUNCTION(ftok) int pathname_len, proj_len; key_t k; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &pathname, &pathname_len, &proj, &proj_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ps", &pathname, &pathname_len, &proj, &proj_len) == FAILURE) { return; } diff --git a/ext/standard/iptc.c b/ext/standard/iptc.c index 6da54ccc17897..4cac5e092132f 100644 --- a/ext/standard/iptc.c +++ b/ext/standard/iptc.c @@ -187,7 +187,7 @@ PHP_FUNCTION(iptcembed) struct stat sb; zend_bool written = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|l", &iptcdata, &iptcdata_len, &jpeg_file, &jpeg_file_len, &spool) != SUCCESS) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sp|l", &iptcdata, &iptcdata_len, &jpeg_file, &jpeg_file_len, &spool) != SUCCESS) { return; } diff --git a/ext/standard/link.c b/ext/standard/link.c index 6c0e1cf15d496..f6d474009df4c 100644 --- a/ext/standard/link.c +++ b/ext/standard/link.c @@ -89,7 +89,7 @@ PHP_FUNCTION(linkinfo) struct stat sb; int ret; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &link, &link_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &link, &link_len) == FAILURE) { return; } @@ -115,7 +115,7 @@ PHP_FUNCTION(symlink) char dirname[MAXPATHLEN]; size_t len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pp", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) { return; } @@ -171,7 +171,7 @@ PHP_FUNCTION(link) char source_p[MAXPATHLEN]; char dest_p[MAXPATHLEN]; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pp", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) { return; } diff --git a/ext/standard/link_win32.c b/ext/standard/link_win32.c index c5357c7e18253..d7589bbb7b720 100644 --- a/ext/standard/link_win32.c +++ b/ext/standard/link_win32.c @@ -66,7 +66,7 @@ PHP_FUNCTION(readlink) int link_len; char target[MAXPATHLEN]; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &link, &link_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &link, &link_len) == FAILURE) { return; } @@ -90,7 +90,7 @@ PHP_FUNCTION(linkinfo) struct stat sb; int ret; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &link, &link_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &link, &link_len) == FAILURE) { return; } @@ -133,7 +133,7 @@ PHP_FUNCTION(symlink) RETURN_FALSE; } - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pp", &topath, &topath_len, &frompath, &frompath_len) == FAILURE) { return; } diff --git a/ext/standard/md5.c b/ext/standard/md5.c index 36e49ce44c1a5..0c35577768519 100644 --- a/ext/standard/md5.c +++ b/ext/standard/md5.c @@ -85,7 +85,7 @@ PHP_NAMED_FUNCTION(php_if_md5_file) int n; php_stream *stream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &arg, &arg_len, &raw_output) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &arg, &arg_len, &raw_output) == FAILURE) { return; } diff --git a/ext/standard/sha1.c b/ext/standard/sha1.c index 3b552de789265..2c7cd3e3e04bc 100644 --- a/ext/standard/sha1.c +++ b/ext/standard/sha1.c @@ -75,7 +75,7 @@ PHP_FUNCTION(sha1_file) int n; php_stream *stream; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &arg, &arg_len, &raw_output) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &arg, &arg_len, &raw_output) == FAILURE) { return; } diff --git a/ext/tidy/tidy.c b/ext/tidy/tidy.c index f51f0b4579938..cf8e29056919f 100644 --- a/ext/tidy/tidy.c +++ b/ext/tidy/tidy.c @@ -558,7 +558,7 @@ static void php_tidy_quick_repair(INTERNAL_FUNCTION_PARAMETERS, zend_bool is_fil TidyBuffer *errbuf; zval **config = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|Zsb", &arg1, &arg1_len, &config, &enc, &enc_len, &use_include_path) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|Zsb", &arg1, &arg1_len, &config, &enc, &enc_len, &use_include_path) == FAILURE) { RETURN_FALSE; } @@ -1272,7 +1272,7 @@ static PHP_FUNCTION(tidy_parse_file) PHPTidyObj *obj; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|Zsb", &inputfile, &input_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|Zsb", &inputfile, &input_len, &options, &enc, &enc_len, &use_include_path) == FAILURE) { RETURN_FALSE; } @@ -1586,7 +1586,7 @@ static TIDY_DOC_METHOD(__construct) PHPTidyObj *obj; TIDY_SET_CONTEXT; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|sZsb", &inputfile, &input_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|pZsb", &inputfile, &input_len, &options, &enc, &enc_len, &use_include_path) == FAILURE) { RETURN_FALSE; } @@ -1620,7 +1620,7 @@ static TIDY_DOC_METHOD(parseFile) obj = (PHPTidyObj *)zend_object_store_get_object(object TSRMLS_CC); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|Zsb", &inputfile, &input_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|Zsb", &inputfile, &input_len, &options, &enc, &enc_len, &use_include_path) == FAILURE) { RETURN_FALSE; } diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c index b9f6348c04a95..83d8f5ca8da23 100644 --- a/ext/xmlreader/php_xmlreader.c +++ b/ext/xmlreader/php_xmlreader.c @@ -495,7 +495,7 @@ static void php_xmlreader_set_relaxng_schema(INTERNAL_FUNCTION_PARAMETERS, int t xmlRelaxNGPtr schema = NULL; char *source; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!", &source, &source_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p!", &source, &source_len) == FAILURE) { return; } @@ -872,7 +872,7 @@ PHP_METHOD(xmlreader, open) char resolved_path[MAXPATHLEN + 1]; xmlTextReaderPtr reader = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s!l", &source, &source_len, &encoding, &encoding_len, &options) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|s!l", &source, &source_len, &encoding, &encoding_len, &options) == FAILURE) { return; } @@ -958,7 +958,7 @@ PHP_METHOD(xmlreader, setSchema) xmlreader_object *intern; char *source; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!", &source, &source_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p!", &source, &source_len) == FAILURE) { return; } diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 2ac2c4bbe1506..8cb341516700a 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -634,7 +634,7 @@ PHP_FUNCTION(xsl_xsltprocessor_transform_to_uri) intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); sheetp = (xsltStylesheetPtr) intern->ptr; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "os", &docp, &uri, &uri_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "op", &docp, &uri, &uri_len) == FAILURE) { RETURN_FALSE; } @@ -840,7 +840,7 @@ PHP_FUNCTION(xsl_xsltprocessor_set_profiling) int filename_len; DOM_GET_THIS(id); - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "s!", &filename, &filename_len) == SUCCESS) { + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "p!", &filename, &filename_len) == SUCCESS) { intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); if (intern->profiling) { efree(intern->profiling); diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index 56abd80beb5a8..3aa3988e8e1dc 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -1211,7 +1211,7 @@ static PHP_NAMED_FUNCTION(zif_zip_open) zip_rsrc *rsrc_int; int err = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } @@ -1495,7 +1495,7 @@ static ZIPARCHIVE_METHOD(open) zval *this = getThis(); ze_zip_object *ze_obj = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &filename, &filename_len, &flags) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &filename, &filename_len, &flags) == FAILURE) { return; } @@ -1664,12 +1664,12 @@ static void php_zip_add_from_pattern(INTERNAL_FUNCTION_PARAMETERS, int type) /* ZIP_FROM_OBJECT(intern, this); /* 1 == glob, 2==pcre */ if (type == 1) { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|la", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|la", &pattern, &pattern_len, &flags, &options) == FAILURE) { return; } } else { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|sa", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|sa", &pattern, &pattern_len, &path, &path_len, &options) == FAILURE) { return; } @@ -1783,7 +1783,7 @@ static ZIPARCHIVE_METHOD(addFile) ZIP_FROM_OBJECT(intern, this); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|sll", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|sll", &filename, &filename_len, &entry_name, &entry_name_len, &offset_start, &offset_len) == FAILURE) { return; } @@ -1882,7 +1882,7 @@ static ZIPARCHIVE_METHOD(statName) ZIP_FROM_OBJECT(intern, this); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &name, &name_len, &flags) == FAILURE) { return; } @@ -1938,7 +1938,7 @@ static ZIPARCHIVE_METHOD(locateName) ZIP_FROM_OBJECT(intern, this); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &name, &name_len, &flags) == FAILURE) { return; } @@ -2518,7 +2518,7 @@ static void php_zip_get_from(INTERNAL_FUNCTION_PARAMETERS, int type) /* {{{ */ ZIP_FROM_OBJECT(intern, this); if (type == 1) { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|ll", &filename, &filename_len, &len, &flags) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|ll", &filename, &filename_len, &len, &flags) == FAILURE) { return; } PHP_ZIP_STAT_PATH(intern, filename, filename_len, flags, sb); @@ -2594,7 +2594,7 @@ static ZIPARCHIVE_METHOD(getStream) ZIP_FROM_OBJECT(intern, this); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 8a14f3b78f011..08450a3aa33af 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -431,7 +431,7 @@ static PHP_FUNCTION(gzfile) long use_include_path = 0; php_stream *stream; - if (SUCCESS != zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &filename, &filename_len, &use_include_path)) { + if (SUCCESS != zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|l", &filename, &filename_len, &use_include_path)) { return; } diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c index 4ec3e5ee7af83..812d591767b21 100644 --- a/main/fopen_wrappers.c +++ b/main/fopen_wrappers.c @@ -477,7 +477,7 @@ PHPAPI char *php_resolve_path(const char *filename, int filename_length, const c char *actual_path; php_stream_wrapper *wrapper; - if (!filename) { + if (!filename || CHECK_NULL_PATH(filename, filename_length)) { return NULL; } diff --git a/sapi/apache/php_apache.c b/sapi/apache/php_apache.c index 58f1c1a5bc597..d2159e9789b8a 100644 --- a/sapi/apache/php_apache.c +++ b/sapi/apache/php_apache.c @@ -350,7 +350,7 @@ PHP_FUNCTION(virtual) int filename_len; request_rec *rr = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } diff --git a/sapi/apache2filter/php_functions.c b/sapi/apache2filter/php_functions.c index 68beefc8f11c4..0d0a294bed990 100644 --- a/sapi/apache2filter/php_functions.c +++ b/sapi/apache2filter/php_functions.c @@ -63,7 +63,7 @@ PHP_FUNCTION(virtual) int filename_len; request_rec *rr; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } @@ -101,7 +101,7 @@ PHP_FUNCTION(apache_lookup_uri) char *filename; int filename_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } diff --git a/sapi/apache2handler/php_functions.c b/sapi/apache2handler/php_functions.c index dbad4995d0e04..65f913a217bcb 100644 --- a/sapi/apache2handler/php_functions.c +++ b/sapi/apache2handler/php_functions.c @@ -75,7 +75,7 @@ PHP_FUNCTION(virtual) int filename_len; request_rec *rr; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } @@ -121,7 +121,7 @@ PHP_FUNCTION(apache_lookup_uri) char *filename; int filename_len; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { return; } From be3889456be0bc848c53c71521a42ecef8a08478 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 6 Jun 2011 21:42:05 +0000 Subject: [PATCH 0114/2394] - Added indirect method call through array variable (FR Bug #47160) --- Zend/tests/fr47160.phpt | 150 ++++++++++++++++++++++++ Zend/zend_vm_def.h | 61 ++++++++++ Zend/zend_vm_execute.h | 244 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 455 insertions(+) create mode 100644 Zend/tests/fr47160.phpt diff --git a/Zend/tests/fr47160.phpt b/Zend/tests/fr47160.phpt new file mode 100644 index 0000000000000..809e1f1603607 --- /dev/null +++ b/Zend/tests/fr47160.phpt @@ -0,0 +1,150 @@ +--TEST-- +Calling method from array +--FILE-- + +--EXPECTF-- +Strict Standards: Non-static method Hello::world() should not be called statically in %s on line %d +Hello, you + +Notice: Undefined variable: this in %s on line %d +NULL + +Strict Standards: call_user_func() expects parameter 1 to be a valid callback, non-static method Hello::world() should not be called statically in %s on line %d +Hello, you + +Notice: Undefined variable: this in %s on line %d +NULL +----- +Hello, again +object(Hello)#1 (0) { +} +Hello, again +object(Hello)#1 (0) { +} +----- +Hello, there +object(Hello)#2 (0) { +} +Hello, there +object(Hello)#2 (0) { +} +----- +Hello, devs +object(Hello)#4 (0) { +} +Hello, devs +object(Hello)#4 (0) { +} +----- +Magic::__call called (foo)! +Magic::__call called (foo)! +----- +Magic2::__callStatic called (foo)! +Magic2::__callStatic called (foo)! +----- +Magic3::__callStatic called (foo)! +Magic3::__callStatic called (foo)! +----- +Magic3::__call called (foo)! +Magic3::__call called (foo)! +----- +Hello, you +NULL +Hello, you +NULL diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index c25b7a7a7471e..77d208ce53268 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2382,6 +2382,67 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); + } else if (OP2_TYPE != IS_CONST && + EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && + zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { + zend_class_entry *ce; + zval **method = NULL; + zval **obj = NULL; + + zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); + zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); + + if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { + zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); + } + + if (Z_TYPE_PP(method) != IS_STRING) { + zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); + } + + if (Z_TYPE_PP(obj) == IS_STRING) { + ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); + if (UNEXPECTED(ce == NULL)) { + zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_PP(obj)); + } + EX(called_scope) = ce; + EX(object) = NULL; + + if (ce->get_static_method) { + EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + } else { + EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + } + } else { + EX(object) = *obj; + ce = EX(called_scope) = Z_OBJCE_PP(obj); + + EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + } + + if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { + EX(object) = NULL; + } else { + if (!PZVAL_IS_REF(EX(object))) { + Z_ADDREF_P(EX(object)); /* For $this pointer */ + } else { + zval *this_ptr; + ALLOC_ZVAL(this_ptr); + INIT_PZVAL_COPY(this_ptr, EX(object)); + zval_copy_ctor(this_ptr); + EX(object) = this_ptr; + } + } + } + + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); + } + FREE_OP2(); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 63db4987d679f..fd726eb880a72 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1244,6 +1244,67 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE } else { } + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); + } else if (IS_CONST != IS_CONST && + EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && + zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { + zend_class_entry *ce; + zval **method = NULL; + zval **obj = NULL; + + zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); + zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); + + if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { + zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); + } + + if (Z_TYPE_PP(method) != IS_STRING) { + zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); + } + + if (Z_TYPE_PP(obj) == IS_STRING) { + ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); + if (UNEXPECTED(ce == NULL)) { + zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_PP(obj)); + } + EX(called_scope) = ce; + EX(object) = NULL; + + if (ce->get_static_method) { + EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + } else { + EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + } + } else { + EX(object) = *obj; + ce = EX(called_scope) = Z_OBJCE_PP(obj); + + EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + } + + if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { + EX(object) = NULL; + } else { + if (!PZVAL_IS_REF(EX(object))) { + Z_ADDREF_P(EX(object)); /* For $this pointer */ + } else { + zval *this_ptr; + ALLOC_ZVAL(this_ptr); + INIT_PZVAL_COPY(this_ptr, EX(object)); + zval_copy_ctor(this_ptr); + EX(object) = this_ptr; + } + } + } + + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); + } + CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { @@ -1486,6 +1547,67 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); + } else if (IS_TMP_VAR != IS_CONST && + EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && + zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { + zend_class_entry *ce; + zval **method = NULL; + zval **obj = NULL; + + zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); + zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); + + if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { + zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); + } + + if (Z_TYPE_PP(method) != IS_STRING) { + zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); + } + + if (Z_TYPE_PP(obj) == IS_STRING) { + ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); + if (UNEXPECTED(ce == NULL)) { + zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_PP(obj)); + } + EX(called_scope) = ce; + EX(object) = NULL; + + if (ce->get_static_method) { + EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + } else { + EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + } + } else { + EX(object) = *obj; + ce = EX(called_scope) = Z_OBJCE_PP(obj); + + EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + } + + if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { + EX(object) = NULL; + } else { + if (!PZVAL_IS_REF(EX(object))) { + Z_ADDREF_P(EX(object)); /* For $this pointer */ + } else { + zval *this_ptr; + ALLOC_ZVAL(this_ptr); + INIT_PZVAL_COPY(this_ptr, EX(object)); + zval_copy_ctor(this_ptr); + EX(object) = this_ptr; + } + } + } + + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); + } + zval_dtor(free_op2.var); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); } @@ -1588,6 +1710,67 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); + } else if (IS_VAR != IS_CONST && + EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && + zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { + zend_class_entry *ce; + zval **method = NULL; + zval **obj = NULL; + + zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); + zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); + + if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { + zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); + } + + if (Z_TYPE_PP(method) != IS_STRING) { + zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); + } + + if (Z_TYPE_PP(obj) == IS_STRING) { + ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); + if (UNEXPECTED(ce == NULL)) { + zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_PP(obj)); + } + EX(called_scope) = ce; + EX(object) = NULL; + + if (ce->get_static_method) { + EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + } else { + EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + } + } else { + EX(object) = *obj; + ce = EX(called_scope) = Z_OBJCE_PP(obj); + + EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + } + + if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { + EX(object) = NULL; + } else { + if (!PZVAL_IS_REF(EX(object))) { + Z_ADDREF_P(EX(object)); /* For $this pointer */ + } else { + zval *this_ptr; + ALLOC_ZVAL(this_ptr); + INIT_PZVAL_COPY(this_ptr, EX(object)); + zval_copy_ctor(this_ptr); + EX(object) = this_ptr; + } + } + } + + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); + } + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); } @@ -1721,6 +1904,67 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA } else { } + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); + } else if (IS_CV != IS_CONST && + EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && + zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { + zend_class_entry *ce; + zval **method = NULL; + zval **obj = NULL; + + zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); + zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); + + if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { + zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); + } + + if (Z_TYPE_PP(method) != IS_STRING) { + zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); + } + + if (Z_TYPE_PP(obj) == IS_STRING) { + ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); + if (UNEXPECTED(ce == NULL)) { + zend_error_noreturn(E_ERROR, "Class '%s' not found", Z_STRVAL_PP(obj)); + } + EX(called_scope) = ce; + EX(object) = NULL; + + if (ce->get_static_method) { + EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + } else { + EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + } + } else { + EX(object) = *obj; + ce = EX(called_scope) = Z_OBJCE_PP(obj); + + EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + } + + if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { + EX(object) = NULL; + } else { + if (!PZVAL_IS_REF(EX(object))) { + Z_ADDREF_P(EX(object)); /* For $this pointer */ + } else { + zval *this_ptr; + ALLOC_ZVAL(this_ptr); + INIT_PZVAL_COPY(this_ptr, EX(object)); + zval_copy_ctor(this_ptr); + EX(object) = this_ptr; + } + } + } + + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); + } + CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { From 8da563ed9adbbaa529574fe1d4709dbe3cf1c108 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 6 Jun 2011 22:36:54 +0000 Subject: [PATCH 0115/2394] - Test fixes --- ext/standard/tests/dir/chdir_variation1.phpt | 4 +-- .../tests/dir/scandir_variation1.phpt | 4 +-- ext/standard/tests/file/007_error.phpt | 4 +-- ext/standard/tests/file/bug39863.phpt | 3 +- ext/standard/tests/file/chmod_variation3.phpt | 10 +++--- .../tests/file/disk_free_space_variation.phpt | 32 ++++++++++++++----- .../file/disk_total_space_variation.phpt | 18 ++++++++--- .../tests/file/filegroup_variation2.phpt | 2 +- .../tests/file/filegroup_variation3.phpt | 8 +++-- .../tests/file/fileinode_variation2.phpt | 2 +- .../tests/file/fileinode_variation3.phpt | 8 +++-- .../tests/file/fileowner_variation2.phpt | 2 +- .../tests/file/fileowner_variation3.phpt | 8 +++-- .../tests/file/fileperms_variation2.phpt | 2 +- .../tests/file/fileperms_variation3.phpt | 8 +++-- 15 files changed, 78 insertions(+), 37 deletions(-) diff --git a/ext/standard/tests/dir/chdir_variation1.phpt b/ext/standard/tests/dir/chdir_variation1.phpt index a7cf857f7fb3a..8b4d4b90e2d92 100644 --- a/ext/standard/tests/dir/chdir_variation1.phpt +++ b/ext/standard/tests/dir/chdir_variation1.phpt @@ -201,7 +201,7 @@ bool(false) -- Iteration 18 -- -Warning: chdir() expects parameter 1 to be string, array given in %s on line %d +Warning: chdir() expects parameter 1 to be valid path, array given in %s on line %d bool(false) -- Iteration 19 -- @@ -230,6 +230,6 @@ bool(false) -- Iteration 25 -- -Warning: chdir() expects parameter 1 to be string, resource given in %s on line %d +Warning: chdir() expects parameter 1 to be valid path, resource given in %s on line %d bool(false) ===DONE=== diff --git a/ext/standard/tests/dir/scandir_variation1.phpt b/ext/standard/tests/dir/scandir_variation1.phpt index 84b3565f7e063..34aa72dacda2f 100644 --- a/ext/standard/tests/dir/scandir_variation1.phpt +++ b/ext/standard/tests/dir/scandir_variation1.phpt @@ -205,7 +205,7 @@ bool(false) -- Iteration 18 -- -Warning: scandir() expects parameter 1 to be string, array given in %s on line %d +Warning: scandir() expects parameter 1 to be valid path, array given in %s on line %d NULL -- Iteration 19 -- @@ -248,6 +248,6 @@ bool(false) -- Iteration 25 -- -Warning: scandir() expects parameter 1 to be string, resource given in %s on line %d +Warning: scandir() expects parameter 1 to be valid path, resource given in %s on line %d NULL ===DONE=== diff --git a/ext/standard/tests/file/007_error.phpt b/ext/standard/tests/file/007_error.phpt index 78a9d4ac330b8..671a6c17334d0 100644 --- a/ext/standard/tests/file/007_error.phpt +++ b/ext/standard/tests/file/007_error.phpt @@ -145,7 +145,7 @@ Warning: feof() expects parameter 1 to be resource, boolean given in %s on line bool(false) -- Iteration 5 -- -Warning: fopen() expects parameter 1 to be string, array given in %s on line %d +Warning: fopen() expects parameter 1 to be valid path, array given in %s on line %d bool(false) Warning: fclose() expects parameter 1 to be resource, array given in %s on line %d @@ -155,7 +155,7 @@ Warning: feof() expects parameter 1 to be resource, array given in %s on line %d bool(false) -- Iteration 6 -- -Warning: fopen() expects parameter 1 to be string, object given in %s on line %d +Warning: fopen() expects parameter 1 to be valid path, object given in %s on line %d bool(false) Warning: fclose() expects parameter 1 to be resource, object given in %s on line %d diff --git a/ext/standard/tests/file/bug39863.phpt b/ext/standard/tests/file/bug39863.phpt index 6913655ee45bc..edbb90de07d15 100644 --- a/ext/standard/tests/file/bug39863.phpt +++ b/ext/standard/tests/file/bug39863.phpt @@ -16,7 +16,8 @@ else { ?> ===DONE=== ---EXPECT-- +--EXPECTF-- +Warning: file_exists() expects parameter 1 to be valid path, string given in %s on line %d PASS ===DONE=== diff --git a/ext/standard/tests/file/chmod_variation3.phpt b/ext/standard/tests/file/chmod_variation3.phpt index df18ccf986c23..89f20f4a64891 100644 --- a/ext/standard/tests/file/chmod_variation3.phpt +++ b/ext/standard/tests/file/chmod_variation3.phpt @@ -143,19 +143,19 @@ Error: 2 - chmod(): No such file or directory, %s(%d) bool(false) --empty array-- -Error: 2 - chmod() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - chmod() expects parameter 1 to be valid path, array given, %s(%d) NULL --int indexed array-- -Error: 2 - chmod() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - chmod() expects parameter 1 to be valid path, array given, %s(%d) NULL --associative array-- -Error: 2 - chmod() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - chmod() expects parameter 1 to be valid path, array given, %s(%d) NULL --nested arrays-- -Error: 2 - chmod() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - chmod() expects parameter 1 to be valid path, array given, %s(%d) NULL --uppercase NULL-- @@ -195,7 +195,7 @@ Error: 2 - chmod(): No such file or directory, %s(%d) bool(false) --instance of classWithoutToString-- -Error: 2 - chmod() expects parameter 1 to be string, object given, %s(%d) +Error: 2 - chmod() expects parameter 1 to be valid path, object given, %s(%d) NULL --undefined var-- diff --git a/ext/standard/tests/file/disk_free_space_variation.phpt b/ext/standard/tests/file/disk_free_space_variation.phpt index c1809986fd860..debc84b14eff3 100644 --- a/ext/standard/tests/file/disk_free_space_variation.phpt +++ b/ext/standard/tests/file/disk_free_space_variation.phpt @@ -105,19 +105,35 @@ float(%d) float(%d) -- Iteration 9 -- -float(%d) -float(%d) + +Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 10 -- -float(%d) -float(%d) + +Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 11 -- -float(%d) -float(%d) + +Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 12 -- -float(%d) -float(%d) + +Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +NULL --- Done --- diff --git a/ext/standard/tests/file/disk_total_space_variation.phpt b/ext/standard/tests/file/disk_total_space_variation.phpt index c03ba594bdfaa..4cf4110f56b71 100644 --- a/ext/standard/tests/file/disk_total_space_variation.phpt +++ b/ext/standard/tests/file/disk_total_space_variation.phpt @@ -99,17 +99,25 @@ float(%d) float(%d) -- Iteration 9 -- -float(%d) + +Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 10 -- -float(%d) + +Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 11 -- -float(%d) + +Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 12 -- -float(%d) + +Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Testing with Binary Input *** -float(%d) +float(64246190080) --- Done --- diff --git a/ext/standard/tests/file/filegroup_variation2.phpt b/ext/standard/tests/file/filegroup_variation2.phpt index d5b7b1bac8372..98d84765c42ab 100644 --- a/ext/standard/tests/file/filegroup_variation2.phpt +++ b/ext/standard/tests/file/filegroup_variation2.phpt @@ -58,7 +58,7 @@ bool(false) bool(false) bool(false) -Warning: filegroup() expects parameter 1 to be string, resource given in %s on line %d +Warning: filegroup() expects parameter 1 to be valid path, resource given in %s on line %d NULL Warning: filegroup(): stat failed for 1234 in %s on line %d diff --git a/ext/standard/tests/file/filegroup_variation3.phpt b/ext/standard/tests/file/filegroup_variation3.phpt index dd875a082b700..b61f8984d54b1 100644 --- a/ext/standard/tests/file/filegroup_variation3.phpt +++ b/ext/standard/tests/file/filegroup_variation3.phpt @@ -74,8 +74,12 @@ bool(false) Warning: filegroup(): stat failed for %s/filegroup_variation3/filegroup*.tmp in %s on line %d bool(false) - Iteration 7 - -int(%d) + +Warning: filegroup() expects parameter 1 to be valid path, string given in %s on line %d +NULL - Iteration 8 - -int(%d) + +Warning: filegroup() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Done *** diff --git a/ext/standard/tests/file/fileinode_variation2.phpt b/ext/standard/tests/file/fileinode_variation2.phpt index 7d71ef4ab2e6a..eb0fc96010df4 100644 --- a/ext/standard/tests/file/fileinode_variation2.phpt +++ b/ext/standard/tests/file/fileinode_variation2.phpt @@ -59,7 +59,7 @@ bool(false) bool(false) bool(false) -Warning: fileinode() expects parameter 1 to be string, resource given in %s on line %d +Warning: fileinode() expects parameter 1 to be valid path, resource given in %s on line %d NULL Warning: fileinode(): stat failed for 1234 in %s on line %d diff --git a/ext/standard/tests/file/fileinode_variation3.phpt b/ext/standard/tests/file/fileinode_variation3.phpt index c81b573246af8..ab8afd601d193 100644 --- a/ext/standard/tests/file/fileinode_variation3.phpt +++ b/ext/standard/tests/file/fileinode_variation3.phpt @@ -75,8 +75,12 @@ bool(false) Warning: fileinode(): stat failed for %s/fileinode_variation3/fileinode*.tmp in %s on line %d bool(false) - Iteration 7 - -int(%d) + +Warning: fileinode() expects parameter 1 to be valid path, string given in %s on line %d +NULL - Iteration 8 - -int(%d) + +Warning: fileinode() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Done *** diff --git a/ext/standard/tests/file/fileowner_variation2.phpt b/ext/standard/tests/file/fileowner_variation2.phpt index 07eb6ec8b6f66..b904b6b366d0a 100644 --- a/ext/standard/tests/file/fileowner_variation2.phpt +++ b/ext/standard/tests/file/fileowner_variation2.phpt @@ -59,7 +59,7 @@ bool(false) bool(false) bool(false) -Warning: fileowner() expects parameter 1 to be string, resource given in %s on line %d +Warning: fileowner() expects parameter 1 to be valid path, resource given in %s on line %d NULL Warning: fileowner(): stat failed for 1234 in %s on line %d diff --git a/ext/standard/tests/file/fileowner_variation3.phpt b/ext/standard/tests/file/fileowner_variation3.phpt index 2a322b6dbc58f..e46d82c1afe51 100644 --- a/ext/standard/tests/file/fileowner_variation3.phpt +++ b/ext/standard/tests/file/fileowner_variation3.phpt @@ -75,8 +75,12 @@ bool(false) Warning: fileowner(): stat failed for %s/fileowner_variation3/fileowner*.tmp in %s on line %d bool(false) - Iteration 7 - -int(%d) + +Warning: fileowner() expects parameter 1 to be valid path, string given in %s on line %d +NULL - Iteration 8 - -int(%d) + +Warning: fileowner() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Done *** diff --git a/ext/standard/tests/file/fileperms_variation2.phpt b/ext/standard/tests/file/fileperms_variation2.phpt index ad809a1559ee5..a7cfdb6b22112 100644 --- a/ext/standard/tests/file/fileperms_variation2.phpt +++ b/ext/standard/tests/file/fileperms_variation2.phpt @@ -58,7 +58,7 @@ bool(false) bool(false) bool(false) -Warning: fileperms() expects parameter 1 to be string, resource given in %s on line %d +Warning: fileperms() expects parameter 1 to be valid path, resource given in %s on line %d NULL Warning: fileperms(): stat failed for 1234 in %s on line %d diff --git a/ext/standard/tests/file/fileperms_variation3.phpt b/ext/standard/tests/file/fileperms_variation3.phpt index 38101e363c5ac..9c59cf7cdbc95 100644 --- a/ext/standard/tests/file/fileperms_variation3.phpt +++ b/ext/standard/tests/file/fileperms_variation3.phpt @@ -74,8 +74,12 @@ bool(false) Warning: fileperms(): stat failed for %s/fileperms_variation3/fileperms*.tmp in %s on line %d bool(false) - Iteration 7 - -int(%d) + +Warning: fileperms() expects parameter 1 to be valid path, string given in %s on line %d +NULL - Iteration 8 - -int(%d) + +Warning: fileperms() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Done *** From 370febcd37a648b325918da2889c7c3f7d1c8754 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 7 Jun 2011 01:40:54 +0000 Subject: [PATCH 0116/2394] Fixed test 008 --- ext/simplexml/simplexml.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index 1d74853cd9c83..2ec0ca4ab8ae1 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -1294,9 +1294,8 @@ SXE_METHOD(xpath) result = retval->nodesetval; - array_init(return_value); - if (result != NULL) { + array_init(return_value); for (i = 0; i < result->nodeNr; ++i) { nodeptr = result->nodeTab[i]; if (nodeptr->type == XML_TEXT_NODE || nodeptr->type == XML_ELEMENT_NODE || nodeptr->type == XML_ATTRIBUTE_NODE) { @@ -1317,6 +1316,8 @@ SXE_METHOD(xpath) add_next_index_zval(return_value, value); } } + } else { + RETVAL_FALSE; } xmlXPathFreeObject(retval); From 33a8442c5d83b4a60da432b9a55cd4292712479c Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 7 Jun 2011 01:58:56 +0000 Subject: [PATCH 0117/2394] - Fix memory leak caused by RSHUTDOWN not being called by MINIT dependency --- ext/standard/basic_functions.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 8211383235cb2..df2d56f4911d5 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -3736,7 +3736,7 @@ PHP_RINIT_FUNCTION(basic) /* {{{ */ #endif BG(user_shutdown_function_names) = NULL; - BASIC_RINIT_SUBMODULE(filestat) + PHP_RINIT(filestat)(INIT_FUNC_ARGS_PASSTHRU); #ifdef HAVE_SYSLOG_H BASIC_RINIT_SUBMODULE(syslog) #endif @@ -3784,7 +3784,7 @@ PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ /* FG(stream_wrappers) and FG(stream_filters) are destroyed * during php_request_shutdown() */ - BASIC_RSHUTDOWN_SUBMODULE(filestat) + PHP_RSHUTDOWN(filestat)(SHUTDOWN_FUNC_ARGS_PASSTHRU); #ifdef HAVE_SYSLOG_H #ifdef PHP_WIN32 BASIC_RSHUTDOWN_SUBMODULE(syslog)(SHUTDOWN_FUNC_ARGS_PASSTHRU); From ac86bf82b47af6ecdad3c211730cc200b8eab49d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 7 Jun 2011 02:29:03 +0000 Subject: [PATCH 0118/2394] - Test fixes --- ext/standard/tests/file/glob_variation.phpt | 37 +++++++++++-------- .../tests/file/is_dir_variation3.phpt | 2 +- .../tests/file/is_dir_variation4.phpt | 8 +++- .../tests/file/is_executable_variation1.phpt | 8 +++- .../tests/file/is_executable_variation3.phpt | 2 +- ext/standard/tests/file/is_file_error.phpt | 2 +- .../tests/file/is_file_variation3.phpt | 2 +- .../tests/file/is_file_variation4.phpt | 8 +++- .../tests/file/is_readable_variation1.phpt | 12 ++++-- .../tests/file/is_readable_variation3.phpt | 2 +- .../tests/file/is_writable_variation1.phpt | 26 +++++++++---- .../tests/file/is_writable_variation3.phpt | 4 +- ext/standard/tests/file/lchown_error.phpt | 4 +- ext/standard/tests/file/lstat_stat_error.phpt | 4 +- .../tests/file/parse_ini_file_variation4.phpt | 10 ++--- .../tests/file/tempnam_variation7.phpt | 16 ++++---- 16 files changed, 92 insertions(+), 55 deletions(-) diff --git a/ext/standard/tests/file/glob_variation.phpt b/ext/standard/tests/file/glob_variation.phpt index 52c0dc8e47ae7..01a955dc14fe4 100755 --- a/ext/standard/tests/file/glob_variation.phpt +++ b/ext/standard/tests/file/glob_variation.phpt @@ -325,20 +325,24 @@ array(0) { } -- Iteration 8 -- -array(0) { -} -array(0) { -} -array(0) { -} -array(1) { - [0]=> - string(%d) "%s/glob_variation/WONDER5" -} -array(0) { -} -array(0) { -} + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 9 -- array(0) { @@ -441,8 +445,9 @@ array(1) { array(0) { } -- Iteration 8 -- -array(0) { -} + +Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 9 -- array(0) { } diff --git a/ext/standard/tests/file/is_dir_variation3.phpt b/ext/standard/tests/file/is_dir_variation3.phpt index 2df297843b83e..579c70a01be34 100644 --- a/ext/standard/tests/file/is_dir_variation3.phpt +++ b/ext/standard/tests/file/is_dir_variation3.phpt @@ -42,7 +42,7 @@ bool(false) bool(false) bool(false) -Warning: is_dir() expects parameter 1 to be string, resource given in %s on line %d +Warning: is_dir() expects parameter 1 to be valid path, resource given in %s on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/is_dir_variation4.phpt b/ext/standard/tests/file/is_dir_variation4.phpt index a68fe0b005a74..0867d1b605a30 100644 --- a/ext/standard/tests/file/is_dir_variation4.phpt +++ b/ext/standard/tests/file/is_dir_variation4.phpt @@ -77,9 +77,13 @@ bool(true) bool(false) -- Iteration 9 -- -bool(true) + +Warning: is_dir() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 10 -- -bool(true) + +Warning: is_dir() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Done *** diff --git a/ext/standard/tests/file/is_executable_variation1.phpt b/ext/standard/tests/file/is_executable_variation1.phpt index 9969911ee1416..2e579ccff64a7 100644 --- a/ext/standard/tests/file/is_executable_variation1.phpt +++ b/ext/standard/tests/file/is_executable_variation1.phpt @@ -76,9 +76,13 @@ bool(false) -- Iteration 5 -- bool(false) -- Iteration 6 -- -bool(true) + +Warning: is_executable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 7 -- -bool(true) + +Warning: is_executable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 8 -- bool(false) -- Iteration 9 -- diff --git a/ext/standard/tests/file/is_executable_variation3.phpt b/ext/standard/tests/file/is_executable_variation3.phpt index 634ce1f40c6a5..0a1f3823b9311 100644 --- a/ext/standard/tests/file/is_executable_variation3.phpt +++ b/ext/standard/tests/file/is_executable_variation3.phpt @@ -62,7 +62,7 @@ bool(false) bool(false) bool(false) -Warning: is_executable() expects parameter 1 to be string, array given in %s on line %d +Warning: is_executable() expects parameter 1 to be valid path, array given in %s on line %d NULL bool(false) Done diff --git a/ext/standard/tests/file/is_file_error.phpt b/ext/standard/tests/file/is_file_error.phpt index 711d761763a26..6c481f0fdb131 100644 --- a/ext/standard/tests/file/is_file_error.phpt +++ b/ext/standard/tests/file/is_file_error.phpt @@ -45,7 +45,7 @@ Warning: is_file() expects exactly 1 parameter, 2 given in %s on line %d NULL bool(false) -Warning: is_file() expects parameter 1 to be string, resource given in %s on line %d +Warning: is_file() expects parameter 1 to be valid path, resource given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/is_file_variation3.phpt b/ext/standard/tests/file/is_file_variation3.phpt index 917fa5acc8cdf..e11c862ea3d91 100644 --- a/ext/standard/tests/file/is_file_variation3.phpt +++ b/ext/standard/tests/file/is_file_variation3.phpt @@ -51,7 +51,7 @@ bool(false) bool(false) bool(false) -Warning: is_file() expects parameter 1 to be string, resource given in %s on line %d +Warning: is_file() expects parameter 1 to be valid path, resource given in %s on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/is_file_variation4.phpt b/ext/standard/tests/file/is_file_variation4.phpt index 55aeedfaada50..11ca5d5558493 100644 --- a/ext/standard/tests/file/is_file_variation4.phpt +++ b/ext/standard/tests/file/is_file_variation4.phpt @@ -67,8 +67,12 @@ bool(false) - Iteration 6 - bool(false) - Iteration 7 - -bool(true) + +Warning: is_file() expects parameter 1 to be valid path, string given in %s on line %d +NULL - Iteration 8 - -bool(true) + +Warning: is_file() expects parameter 1 to be valid path, string given in %s on line %d +NULL *** Done *** diff --git a/ext/standard/tests/file/is_readable_variation1.phpt b/ext/standard/tests/file/is_readable_variation1.phpt index a1310327b8b3d..e9f168a8e1cc1 100644 --- a/ext/standard/tests/file/is_readable_variation1.phpt +++ b/ext/standard/tests/file/is_readable_variation1.phpt @@ -87,11 +87,17 @@ bool(false) -- Iteration 6 -- bool(false) -- Iteration 7 -- -bool(true) + +Warning: is_readable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 8 -- -bool(true) + +Warning: is_readable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 9 -- -bool(true) + +Warning: is_readable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 10 -- bool(true) -- Iteration 11 -- diff --git a/ext/standard/tests/file/is_readable_variation3.phpt b/ext/standard/tests/file/is_readable_variation3.phpt index dde47cc3b5cd7..782c4bc07eedd 100644 --- a/ext/standard/tests/file/is_readable_variation3.phpt +++ b/ext/standard/tests/file/is_readable_variation3.phpt @@ -61,7 +61,7 @@ bool(false) bool(false) bool(false) -Warning: is_readable() expects parameter 1 to be string, array given in %s on line %d +Warning: is_readable() expects parameter 1 to be valid path, array given in %s on line %d NULL bool(false) Done diff --git a/ext/standard/tests/file/is_writable_variation1.phpt b/ext/standard/tests/file/is_writable_variation1.phpt index bf3e7e117199f..524684dea8132 100644 --- a/ext/standard/tests/file/is_writable_variation1.phpt +++ b/ext/standard/tests/file/is_writable_variation1.phpt @@ -96,18 +96,30 @@ bool(false) bool(false) bool(false) -- Iteration 7 -- -bool(true) -bool(true) + +Warning: is_writable() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: is_writeable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 8 -- -bool(true) -bool(true) + +Warning: is_writable() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: is_writeable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 9 -- -bool(true) -bool(true) + +Warning: is_writable() expects parameter 1 to be valid path, string given in %s on line %d +NULL + +Warning: is_writeable() expects parameter 1 to be valid path, string given in %s on line %d +NULL -- Iteration 10 -- bool(true) bool(true) -- Iteration 11 -- bool(true) bool(true) -Done \ No newline at end of file +Done diff --git a/ext/standard/tests/file/is_writable_variation3.phpt b/ext/standard/tests/file/is_writable_variation3.phpt index 4c5bfa9082d34..25aa9c0433f5f 100644 --- a/ext/standard/tests/file/is_writable_variation3.phpt +++ b/ext/standard/tests/file/is_writable_variation3.phpt @@ -67,10 +67,10 @@ bool(false) bool(false) bool(false) -Warning: is_writable() expects parameter 1 to be string, array given in %s on line %d +Warning: is_writable() expects parameter 1 to be valid path, array given in %s on line %d NULL -Warning: is_writeable() expects parameter 1 to be string, array given in %s on line %d +Warning: is_writeable() expects parameter 1 to be valid path, array given in %s on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/lchown_error.phpt b/ext/standard/tests/file/lchown_error.phpt index 1e0356569c2a6..72f105218370a 100644 --- a/ext/standard/tests/file/lchown_error.phpt +++ b/ext/standard/tests/file/lchown_error.phpt @@ -67,10 +67,10 @@ bool(true) Warning: lchown(): No such file or directory in %s on line %d bool(false) -Warning: lchown() expects parameter 1 to be string, object given in %s on line %d +Warning: lchown() expects parameter 1 to be valid path, object given in %s on line %d bool(true) -Warning: lchown() expects parameter 1 to be string, array given in %s on line %d +Warning: lchown() expects parameter 1 to be valid path, array given in %s on line %d bool(true) Warning: lchown(): Operation not permitted in %s on line %d diff --git a/ext/standard/tests/file/lstat_stat_error.phpt b/ext/standard/tests/file/lstat_stat_error.phpt index 2a220084a4765..d7ee41f9aeb71 100644 --- a/ext/standard/tests/file/lstat_stat_error.phpt +++ b/ext/standard/tests/file/lstat_stat_error.phpt @@ -51,7 +51,7 @@ bool(false) Warning: lstat(): Lstat failed for 22 in %s on line %d bool(false) -Warning: lstat() expects parameter 1 to be string, array given in %s on line %d +Warning: lstat() expects parameter 1 to be valid path, array given in %s on line %d NULL *** Testing stat() for error conditions *** @@ -74,6 +74,6 @@ bool(false) Warning: stat(): stat failed for 22 in %s on line %d bool(false) -Warning: stat() expects parameter 1 to be string, array given in %s on line %d +Warning: stat() expects parameter 1 to be valid path, array given in %s on line %d NULL Done diff --git a/ext/standard/tests/file/parse_ini_file_variation4.phpt b/ext/standard/tests/file/parse_ini_file_variation4.phpt index 46d45af48e9a2..d8ce01dbce592 100644 --- a/ext/standard/tests/file/parse_ini_file_variation4.phpt +++ b/ext/standard/tests/file/parse_ini_file_variation4.phpt @@ -145,19 +145,19 @@ Error: 2 - parse_ini_file(0.5): failed to open stream: No such file or directory bool(false) --empty array-- -Error: 2 - parse_ini_file() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - parse_ini_file() expects parameter 1 to be valid path, array given, %s(%d) bool(false) --int indexed array-- -Error: 2 - parse_ini_file() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - parse_ini_file() expects parameter 1 to be valid path, array given, %s(%d) bool(false) --associative array-- -Error: 2 - parse_ini_file() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - parse_ini_file() expects parameter 1 to be valid path, array given, %s(%d) bool(false) --nested arrays-- -Error: 2 - parse_ini_file() expects parameter 1 to be string, array given, %s(%d) +Error: 2 - parse_ini_file() expects parameter 1 to be valid path, array given, %s(%d) bool(false) --uppercase NULL-- @@ -197,7 +197,7 @@ Error: 2 - parse_ini_file(Class A object): failed to open stream: No such file o bool(false) --instance of classWithoutToString-- -Error: 2 - parse_ini_file() expects parameter 1 to be string, object given, %s(%d) +Error: 2 - parse_ini_file() expects parameter 1 to be valid path, object given, %s(%d) bool(false) --undefined var-- diff --git a/ext/standard/tests/file/tempnam_variation7.phpt b/ext/standard/tests/file/tempnam_variation7.phpt index 18d074d28d491..e76e1f0c6aaf4 100644 --- a/ext/standard/tests/file/tempnam_variation7.phpt +++ b/ext/standard/tests/file/tempnam_variation7.phpt @@ -94,21 +94,23 @@ File name is => %s%etempnam_variation3.tmp%s File permissions are => 100600 File created in => temp dir -- Iteration 6 -- -File name is => %s%etempnam_variation3.tmp%s -File permissions are => 100600 -File created in => temp dir + +Warning: tempnam() expects parameter 1 to be valid path, string given in %s on line %d +-- File is not created -- + +Warning: unlink(): Invalid argument in %s on line %d -- Iteration 7 -- -Warning: tempnam() expects parameter 1 to be string, array given in %s on line %d +Warning: tempnam() expects parameter 1 to be valid path, array given in %s on line %d -- File is not created -- -Warning: unlink(): %s in %s on line %d +Warning: unlink(): Invalid argument in %s on line %d -- Iteration 8 -- -File name is => %s%etempnam_variation3.tmp%s +File name is => /tmp/tempnam_variation3.tmp%s File permissions are => 100600 File created in => temp dir -- Iteration 9 -- -File name is => %s%etempnam_variation3.tmp%s +File name is => /tmp/tempnam_variation3.tmp%s File permissions are => 100600 File created in => temp dir From 0a4ec6980618e71b9c5039243ff69d2b8e42663c Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Tue, 7 Jun 2011 20:58:08 +0000 Subject: [PATCH 0119/2394] Update tests to match Felipe's null byte arg parsing change --- ext/oci8/tests/null_byte_1.phpt | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/ext/oci8/tests/null_byte_1.phpt b/ext/oci8/tests/null_byte_1.phpt index 1439bd5d66272..6b1529038a3ee 100644 --- a/ext/oci8/tests/null_byte_1.phpt +++ b/ext/oci8/tests/null_byte_1.phpt @@ -1,5 +1,5 @@ --TEST-- -Protect against null bytes in LOB filenames (http://news.php.net/php.internals/50202) +Protect against null bytes in LOB filenames --SKIPIF-- --INI-- @@ -8,6 +8,10 @@ error_reporting = E_WARNING --FILE-- Date: Tue, 7 Jun 2011 22:22:01 +0000 Subject: [PATCH 0120/2394] - Added 'p' type specifier --- README.PARAMETER_PARSING_API | 1 + 1 file changed, 1 insertion(+) diff --git a/README.PARAMETER_PARSING_API b/README.PARAMETER_PARSING_API index 8d297670c6573..927e48188cc93 100644 --- a/README.PARAMETER_PARSING_API +++ b/README.PARAMETER_PARSING_API @@ -51,6 +51,7 @@ Type specifiers L - long, limits out-of-range numbers to LONG_MAX/LONG_MIN (long) o - object of any type (zval*) O - object of specific type given by class entry (zval*, zend_class_entry) + p - valid path (string without null bytes in the middle) and its length (char*, int) r - resource (zval*) s - string (with possible null bytes) and its length (char*, int) z - the actual zval (zval*) From bf07dcd506f4a8b7e1bf4601e1c75a20dca106f4 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 7 Jun 2011 22:58:38 +0000 Subject: [PATCH 0121/2394] - Fixed bug #55007 (compiler fail after previous fail) --- Zend/tests/bug55007.phpt | 23 +++++++++++++++++++++++ Zend/zend.c | 1 + 2 files changed, 24 insertions(+) create mode 100644 Zend/tests/bug55007.phpt diff --git a/Zend/tests/bug55007.phpt b/Zend/tests/bug55007.phpt new file mode 100644 index 0000000000000..12fbf120a88d4 --- /dev/null +++ b/Zend/tests/bug55007.phpt @@ -0,0 +1,23 @@ +--TEST-- +Bug #55007 (compiler fail after previous fail) +--FILE-- + +--EXPECTF-- +Fatal error: Cannot use [] for reading in %s(%d) : eval()'d code on line %d +My error handler runs. diff --git a/Zend/zend.c b/Zend/zend.c index fbffcc38d2653..1ad2baf06623a 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -857,6 +857,7 @@ ZEND_API void _zend_bailout(char *filename, uint lineno) /* {{{ */ exit(-1); } CG(unclean_shutdown) = 1; + CG(active_class_entry) = NULL; CG(in_compilation) = EG(in_execution) = 0; EG(current_execute_data) = NULL; LONGJMP(*EG(bailout), FAILURE); From c287e682f2826bdf927adfac7e7cccf83108f17a Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Tue, 7 Jun 2011 23:53:02 +0000 Subject: [PATCH 0122/2394] Sync OCI8 branches. Allow 'pecl install' to work on both PHP 5.3 & 5.4 --- ext/oci8/oci8.c | 27 +++++++++++++++++ ext/oci8/oci8_interface.c | 63 +++++++++++++++++++++++++++++++++++---- ext/oci8/oci8_lob.c | 5 ++++ ext/oci8/php_oci8.h | 2 +- 4 files changed, 90 insertions(+), 7 deletions(-) diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index 3d4c4de32654c..6e8edf21c8ae9 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -1754,6 +1754,13 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char php_error_docref(NULL TSRMLS_CC, E_WARNING, "Privileged connect is disabled. Enable oci8.privileged_connect to be able to connect as SYSOPER or SYSDBA"); return NULL; } +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || (PHP_MAJOR_VERSION < 5) + /* Safe mode has been removed in PHP 5.4 */ + if (PG(safe_mode)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Privileged connect is disabled in Safe Mode"); + return NULL; + } +#endif } } @@ -1915,7 +1922,11 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char memcmp(tmp->hash_key, hashed_details.c, hashed_details.len) == 0 && zend_list_addref(connection->rsrc_id) == SUCCESS) { /* do nothing */ } else { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) connection->rsrc_id = zend_list_insert(connection, le_pconnection TSRMLS_CC); +#else + connection->rsrc_id = zend_list_insert(connection, le_pconnection); +#endif /* Persistent connections: For old close semantics we artificially * bump up the refcount to prevent the non-persistent destructor * from getting called until request shutdown. The refcount is @@ -2059,7 +2070,11 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char new_le.ptr = connection; new_le.type = le_pconnection; connection->used_this_request = 1; +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) connection->rsrc_id = zend_list_insert(connection, le_pconnection TSRMLS_CC); +#else + connection->rsrc_id = zend_list_insert(connection, le_pconnection); +#endif /* Persistent connections: For old close semantics we artificially bump up the refcount to * prevent the non-persistent destructor from getting called until request shutdown. The @@ -2072,13 +2087,21 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char OCI_G(num_persistent)++; OCI_G(num_links)++; } else if (!exclusive) { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) connection->rsrc_id = zend_list_insert(connection, le_connection TSRMLS_CC); +#else + connection->rsrc_id = zend_list_insert(connection, le_connection); +#endif new_le.ptr = (void *)connection->rsrc_id; new_le.type = le_index_ptr; zend_hash_update(&EG(regular_list), connection->hash_key, strlen(connection->hash_key)+1, (void *)&new_le, sizeof(zend_rsrc_list_entry), NULL); OCI_G(num_links)++; } else { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) connection->rsrc_id = zend_list_insert(connection, le_connection TSRMLS_CC); +#else + connection->rsrc_id = zend_list_insert(connection, le_connection); +#endif OCI_G(num_links)++; } @@ -2771,7 +2794,11 @@ static php_oci_spool *php_oci_get_spool(char *username, int username_len, char * } spool_le.ptr = session_pool; spool_le.type = le_psessionpool; +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) zend_list_insert(session_pool, le_psessionpool TSRMLS_CC); +#else + zend_list_insert(session_pool, le_psessionpool); +#endif zend_hash_update(&EG(persistent_list), session_pool->spool_hash_key, strlen(session_pool->spool_hash_key)+1,(void *)&spool_le, sizeof(zend_rsrc_list_entry),NULL); } else if (spool_out_le->type == le_psessionpool && strlen(((php_oci_spool *)(spool_out_le->ptr))->spool_hash_key) == spool_hashed_details.len && diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c index b1d454e61220a..954604bf2b2c7 100644 --- a/ext/oci8/oci8_interface.c +++ b/ext/oci8/oci8_interface.c @@ -233,21 +233,37 @@ PHP_FUNCTION(oci_lob_import) int filename_len; if (getThis()) { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { +#else + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { +#endif return; } } else { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Op", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len) == FAILURE) { +#else + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Os", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len) == FAILURE) { +#endif return; } } +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || (PHP_MAJOR_VERSION < 5) + /* The "p" parsing parameter handles this case in PHP 5.4+ */ + if (strlen(filename) != filename_len) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Filename cannot contain null bytes"); + RETURN_FALSE; + } +#endif + if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property"); RETURN_FALSE; } - + PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor); if (php_oci_lob_import(descriptor, filename TSRMLS_CC)) { @@ -636,12 +652,12 @@ PHP_FUNCTION(oci_lob_erase) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ll", &offset, &length) == FAILURE) { return; } - + if (ZEND_NUM_ARGS() > 0 && offset < 0) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset must be greater than or equal to 0"); RETURN_FALSE; } - + if (ZEND_NUM_ARGS() > 1 && length < 0) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length must be greater than or equal to 0"); RETURN_FALSE; @@ -651,7 +667,7 @@ PHP_FUNCTION(oci_lob_erase) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O|ll", &z_descriptor, oci_lob_class_entry_ptr, &offset, &length) == FAILURE) { return; } - + if (ZEND_NUM_ARGS() > 1 && offset < 0) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset must be greater than or equal to 0"); RETURN_FALSE; @@ -662,14 +678,14 @@ PHP_FUNCTION(oci_lob_erase) RETURN_FALSE; } } - + if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property"); RETURN_FALSE; } PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor); - + if (php_oci_lob_erase(descriptor, offset, length, &bytes_erased TSRMLS_CC)) { RETURN_FALSE; } @@ -867,7 +883,11 @@ PHP_FUNCTION(oci_lob_export) ub4 lob_length; if (getThis()) { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|ll", &filename, &filename_len, &start, &length) == FAILURE) { +#else + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|ll", &filename, &filename_len, &start, &length) == FAILURE) { +#endif return; } @@ -881,7 +901,11 @@ PHP_FUNCTION(oci_lob_export) } } else { +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Op|ll", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len, &start, &length) == FAILURE) { +#else + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Os|ll", &z_descriptor, oci_lob_class_entry_ptr, &filename, &filename_len, &start, &length) == FAILURE) { +#endif return; } @@ -895,6 +919,14 @@ PHP_FUNCTION(oci_lob_export) } } +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || (PHP_MAJOR_VERSION < 5) + /* The "p" parsing parameter handles this case in PHP 5.4+ */ + if (strlen(filename) != filename_len) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Filename cannot contain null bytes"); + RETURN_FALSE; + } +#endif + if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property"); RETURN_FALSE; @@ -919,11 +951,22 @@ PHP_FUNCTION(oci_lob_export) RETURN_FALSE; } +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || (PHP_MAJOR_VERSION < 5) + /* Safe mode has been removed in PHP 5.4 */ + if (PG(safe_mode) && (!php_checkuid(filename, NULL, CHECKUID_CHECK_FILE_AND_DIR))) { + RETURN_FALSE; + } +#endif + if (php_check_open_basedir(filename TSRMLS_CC)) { RETURN_FALSE; } +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) stream = php_stream_open_wrapper_ex(filename, "w", REPORT_ERRORS, NULL, NULL); +#else + stream = php_stream_open_wrapper_ex(filename, "w", ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL, NULL); +#endif block_length = PHP_OCI_LOB_BUFFER_SIZE; if (block_length > length) { @@ -1867,6 +1910,14 @@ PHP_FUNCTION(oci_password_change) int user_len, pass_old_len, pass_new_len, dbname_len; php_oci_connection *connection; +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || (PHP_MAJOR_VERSION < 5) + /* Safe mode has been removed in PHP 5.4 */ + if (PG(safe_mode)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "is disabled in Safe Mode"); + RETURN_FALSE; + } +#endif + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "rsss", &z_connection, &user, &user_len, &pass_old, &pass_old_len, &pass_new, &pass_new_len) == SUCCESS) { PHP_OCI_ZVAL_TO_CONNECTION(z_connection, connection); diff --git a/ext/oci8/oci8_lob.c b/ext/oci8/oci8_lob.c index 795f7afbe62e5..0169583347dbe 100644 --- a/ext/oci8/oci8_lob.c +++ b/ext/oci8/oci8_lob.c @@ -724,7 +724,12 @@ int php_oci_lob_import (php_oci_descriptor *descriptor, char *filename TSRMLS_DC char buf[8192]; ub4 offset = 1; +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5) + /* Safe mode has been removed in PHP 5.4 */ if (php_check_open_basedir(filename TSRMLS_CC)) { +#else + if ((PG(safe_mode) && (!php_checkuid(filename, NULL, CHECKUID_CHECK_FILE_AND_DIR))) || php_check_open_basedir(filename TSRMLS_CC)) { +#endif return 1; } diff --git a/ext/oci8/php_oci8.h b/ext/oci8/php_oci8.h index 068fad3c92687..bcb12a7bd86ed 100644 --- a/ext/oci8/php_oci8.h +++ b/ext/oci8/php_oci8.h @@ -46,7 +46,7 @@ */ #undef PHP_OCI8_VERSION #endif -#define PHP_OCI8_VERSION "1.4.5" +#define PHP_OCI8_VERSION "1.4.6-dev" extern zend_module_entry oci8_module_entry; #define phpext_oci8_ptr &oci8_module_entry From 2b72c6e7dffca1c3d4ec33e33ac24512cf1dc2d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 8 Jun 2011 00:23:02 +0000 Subject: [PATCH 0123/2394] - Fixed bug #54992: Stream not closed and error not returned when SSL CN_match fails. --- ext/openssl/tests/bug54992-ca.pem | 42 +++++++++++++++++++++++++++ ext/openssl/tests/bug54992.pem | 47 +++++++++++++++++++++++++++++++ ext/openssl/tests/bug54992.phpt | 44 +++++++++++++++++++++++++++++ ext/openssl/xp_ssl.c | 1 + 4 files changed, 134 insertions(+) create mode 100644 ext/openssl/tests/bug54992-ca.pem create mode 100644 ext/openssl/tests/bug54992.pem create mode 100644 ext/openssl/tests/bug54992.phpt diff --git a/ext/openssl/tests/bug54992-ca.pem b/ext/openssl/tests/bug54992-ca.pem new file mode 100644 index 0000000000000..0fdbb2f90eecf --- /dev/null +++ b/ext/openssl/tests/bug54992-ca.pem @@ -0,0 +1,42 @@ +-----BEGIN CERTIFICATE----- +MIIHZzCCBU+gAwIBAgIBATANBgkqhkiG9w0BAQQFADCByzEpMCcGA1UEAxMgQ2F0 +YXBocmFjdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkxCzAJBgNVBAYTAlBUMQ8wDQYD +VQQHEwZMaXNib2ExETAPBgNVBAgTCFBvcnR1Z2FsMSkwJwYDVQQKEyBDYXRhcGhy +YWN0IENlcnRpZmljYXRlIEF1dGhvcml0eTEcMBoGA1UECxMTQ2VydGlmaWNhdGUg +U2lnbmluZzEkMCIGCSqGSIb3DQEJARYVQ2F0YXBocmFjdEBuZXRjYWJvLnB0MB4X +DTAzMTIwNTAwMTExOVoXDTE4MTIwMTAwMTExOVowgcsxKTAnBgNVBAMTIENhdGFw +aHJhY3QgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MQswCQYDVQQGEwJQVDEPMA0GA1UE +BxMGTGlzYm9hMREwDwYDVQQIEwhQb3J0dWdhbDEpMCcGA1UEChMgQ2F0YXBocmFj +dCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkxHDAaBgNVBAsTE0NlcnRpZmljYXRlIFNp +Z25pbmcxJDAiBgkqhkiG9w0BCQEWFUNhdGFwaHJhY3RAbmV0Y2Fiby5wdDCCAiIw +DQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBANg+noZuxtWdxmZjxanJGEpzmDYu +Uko9OHdmhVr3UU+z04a9JFT7aH5wuwrnpadNy1u9CqrSHVWFEtSmOMOH8QYzIy4C +qCjFPSJR5UQjxpxTZeXaTvfhKI9n0LMSqc7I68HkP5MF64N3Z2cRdYvM4U6R5ERD +Xw2LiRpii/+J2cezgi/Nw3vS4hZlWDWMkttfBd0HKSwxxN7OlPcjyzoTVhQgSISV +Zvd3kwENTWD7s3EnnPRtMiW8Vzcjd8eSTCSjuGBG/8NnI44amLo7gSWocCJ2os69 +CJgiqMpp0tLT8cJm0mQUBk0o9gBS7l1GPpgq5fwWG+DmoLIHrKjxpuI5v2DW23gx +yimXSyiD1GX0JLlTqZ+klM7Mv7ptnigRXA8F5f4GbVzBlGM1L1EERd8orsSmzPEA +S6puHdlNzjcx00glp1UoAs6+tV39eW/fjiP493biPcar0pNO8QWfRSqPsgy6/qKN +m7x2DoSdTbRgCalBMp57xYCUHIETZvlewGKnQD1Tj9FlbzvOnH6r52gj5U/5r3pn +E4DshILn/qtdRwd/2Dwx/KSyBJznU7Yu0vEeMwQioZ6YFH1FnC4229lHYCN6ByVw +UE7OMH7n0A8SUN8flxr2X7MmWpQsMrgVfrAjufmFwUaeIRq9X3wihDYw0MYP0brU +x5ONmY+VA93gLdStAgMBAAGjggFSMIIBTjASBgNVHRMBAf8ECDAGAQH/AgEBMB0G +A1UdDgQWBBQj+82/Y4YWpR8kIi0obJULkqmBwTCB+AYDVR0jBIHwMIHtgBQj+82/ +Y4YWpR8kIi0obJULkqmBwaGB0aSBzjCByzEpMCcGA1UEAxMgQ2F0YXBocmFjdCBD +ZXJ0aWZpY2F0ZSBBdXRob3JpdHkxCzAJBgNVBAYTAlBUMQ8wDQYDVQQHEwZMaXNi +b2ExETAPBgNVBAgTCFBvcnR1Z2FsMSkwJwYDVQQKEyBDYXRhcGhyYWN0IENlcnRp +ZmljYXRlIEF1dGhvcml0eTEcMBoGA1UECxMTQ2VydGlmaWNhdGUgU2lnbmluZzEk +MCIGCSqGSIb3DQEJARYVQ2F0YXBocmFjdEBuZXRjYWJvLnB0ggEBMAsGA1UdDwQE +AwIBBjARBglghkgBhvhCAQEEBAMCAAcwDQYJKoZIhvcNAQEEBQADggIBAKN6pRY1 +8GwQx378ukmw4pzvODlee5IKSPRT92hfLKNGNUAMu2LFo+bjItpilhSvR4aklRvh +5RBoVE8ejEdZXsz0HobMUUcL9IemaRwBCWHPii7Y3zX2J1FUiS/KmWhrYvw5hb1P +P83f/kxdWhxD+MbwuGc2I/6WgfsRyzevQsxdJgElQvNGkOXsC56pEXm2ChVoLbZL +sZX0zPa5ZzXByQGwXl9eqOkV7fdNKulJPcLPOs/y1cAfcxXrDYHpqBGf9nb14p3C +NaWXFhvq9Khk/QiWKSO4QarPlYS4H0Sl6tp7zBaE+dZHAjci2mSTraUf7q61kqoJ +g/ZA3qupd1rR67NzN+6x/TJmIq0G3GUxnDNNqNAHvS4YJx8g4Ji0F3Qoz3CgKnc4 +HsneYQ/LCLq2pDjsffnLI88MBGbfHZDjdj2nowwX76W/6PPutD5IR/kOmHEaX1TJ +/Ff99bVV4HwNF3GPwmKPmHpw3hB9A/xG9aiQRcYs0reXoYeQ+8nyCGmu41LweFyV +1WVwWJ/MHgdtzJZHdPjeXKMWQzOx3AS3TCc31oi4IEo4NgNigcuvl0qgUcwDRXBI +HZm4f7npm7xiES8BSoq5PIVCj8EXJd4b7Gk6dHGJGO+APaw3kYKqfqg5+AN1e4a5 +x3onNvWhjcwDGgcs/xAfVJIUucEqpC5h0pZq +-----END CERTIFICATE----- diff --git a/ext/openssl/tests/bug54992.pem b/ext/openssl/tests/bug54992.pem new file mode 100644 index 0000000000000..0675450a3d747 --- /dev/null +++ b/ext/openssl/tests/bug54992.pem @@ -0,0 +1,47 @@ +-----BEGIN CERTIFICATE----- +MIIFizCCA3OgAwIBAgIBGTANBgkqhkiG9w0BAQUFADCByzEpMCcGA1UEAxMgQ2F0 +YXBocmFjdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkxCzAJBgNVBAYTAlBUMQ8wDQYD +VQQHEwZMaXNib2ExETAPBgNVBAgTCFBvcnR1Z2FsMSkwJwYDVQQKEyBDYXRhcGhy +YWN0IENlcnRpZmljYXRlIEF1dGhvcml0eTEcMBoGA1UECxMTQ2VydGlmaWNhdGUg +U2lnbmluZzEkMCIGCSqGSIb3DQEJARYVQ2F0YXBocmFjdEBuZXRjYWJvLnB0MB4X +DTExMDYwNzIzNTIwM1oXDTE4MTIwMTAwMTExOVowWjEXMBUGA1UEAxMOYnVnNTQ5 +OTIubG9jYWwxCzAJBgNVBAYTAlBUMQ8wDQYDVQQHEwZMaXNib2ExDzANBgNVBAgT +Bkxpc2JvYTEQMA4GA1UEChMHcGhwLm5ldDCBnzANBgkqhkiG9w0BAQEFAAOBjQAw +gYkCgYEAtUAVQKTgpUPgtFOJ3w3kDJETS45tWeT96kUg1NeYLKW+jNbFhxPoPJv7 +XhfemCaqh2tbq1cdYW906Wp1L+eNQvdTYA2IQG4EQBUlmfyIakOIMsN/RizVkF09 +vlNQwTpaMpqTv7wB8vvwbxb9jbC2ZhQUBEg6PIn18dSstbM9FZ0CAwEAAaOCAWww +ggFoMAwGA1UdEwEB/wQCMAAwHQYDVR0OBBYEFCysG9r7vXtfHa38AUZeCM6tgH9c +MIH4BgNVHSMEgfAwge2AFCP7zb9jhhalHyQiLShslQuSqYHBoYHRpIHOMIHLMSkw +JwYDVQQDEyBDYXRhcGhyYWN0IENlcnRpZmljYXRlIEF1dGhvcml0eTELMAkGA1UE +BhMCUFQxDzANBgNVBAcTBkxpc2JvYTERMA8GA1UECBMIUG9ydHVnYWwxKTAnBgNV +BAoTIENhdGFwaHJhY3QgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MRwwGgYDVQQLExND +ZXJ0aWZpY2F0ZSBTaWduaW5nMSQwIgYJKoZIhvcNAQkBFhVDYXRhcGhyYWN0QG5l +dGNhYm8ucHSCAQEwCwYDVR0PBAQDAgXgMBEGCWCGSAGG+EIBAQQEAwIGQDAeBglg +hkgBhvhCAQ0EERYPeGNhIGNlcnRpZmljYXRlMA0GCSqGSIb3DQEBBQUAA4ICAQAT +M7Id7nBSvaDXuStLunfeV0WPAh3DkKWCxw9YK0MjK7E/K5xEiYaWWbz9zuHEcKrN +MuflSdYVPXTqvD6mHLFNptOgzG6YMOO+rAAEYB5HZ/PYTO6UWAdSLlS96DpA4SS3 +Qwmrc0eXe1p4U8noEN+N3+rAbetjOuvnLG/cpoQGcA8Mws84B/elzjRne5C8N1rF +Tvdb3bqIqvP1thuPfyh/uIKSQb5ZusHvj7ZBkEs+zQLBRnCcDK4ETXFM0TcKSPar +d11tve/91BqqemwlA+ntVrVTgi/pnw4wuWxa3GOVmeEeWgtv3063wZ3lGv/72PCh +gSjxoCoVLaLPTbC/iG2a5+ca2HcF0TjfJqYNCgosgRGlm5IunvuIv+g5jLcZcDSO +hMw+HzyF8GlDF166YRRb9nUL6AtBisdEw6uQW1vQFRRQS4SGMoArSBw2EBqd7Kvf +ruCMcrkudC8vbWQHMETEvhAXdAjgsIxLeGCPh0/8mtES1Lnr0TWIrM9evPJkKACj +f6CyIASkIDZKFf5JwuUh02qvuNLr/QRELfI1NnA1aTYMQQWWOVCBffu4ce+NPdtl +Uh1vRwWAWI0Zjszw3kUk2vHLbSXeD3bU7gP3IFa1X8XsXBW2SH+BfpNWHUilHj1I +bX+zqjfaRWDJuZqB9y6iTCu8DfBtbMiTUGcI/Rs9wQ== +-----END CERTIFICATE----- +-----BEGIN RSA PRIVATE KEY----- +MIICXgIBAAKBgQC1QBVApOClQ+C0U4nfDeQMkRNLjm1Z5P3qRSDU15gspb6M1sWH +E+g8m/teF96YJqqHa1urVx1hb3TpanUv541C91NgDYhAbgRAFSWZ/IhqQ4gyw39G +LNWQXT2+U1DBOloympO/vAHy+/BvFv2NsLZmFBQESDo8ifXx1Ky1sz0VnQIDAQAB +AoGBALUEnHUkdgv4P7o5WJACAomedqPWSlYmgoVvpvuLmrq0ihuFAGAIvL+TlTgD +JNfWfiejTDlSVtCSDTR1kzZVztitfXDxRkWEjGtFjMhk/DJkql3w10SUtcqCiWqw +/XknyPHZ7A+w7Fu5KRO2LoSIze2ZLKvCfP/M/pLR2fTKGTHtAkEA2NreT1GUnvzj +u1lb2J0nTZbSQHvEkfpEej9akl0Bc5UkskenEsiXE3cJYA1TbEGSqYCmt23x3Rd2 +FYxm6MwV6wJBANX34ZuUOllsS0FJPbkEAps3M4s59daQSFiEkQc5XjPgVB0xVV7s +OEBlGkM3eqcCUOMnMI8L9wfBk49sELZCeJcCQQC/y/TL2q/EXo9c6I/faj+U1Exp +VA5rvhpKtTX6NeBOxh6Kv+z5JAja4nGcTqz2FpkM6giKO+erUFDUhjWOuNK5AkEA +xkmHnCRLxp8jRodXWeQrfigz7ixydLsVMGL5+9XgRPb5PGyBjwwePR70raH2Wls9 +FqU0zPvrnBZ6Zwlgm2cSVQJAPLYA51Z9piajbTuggpioQ5qbUEDkJjmYHbm8eJnK +h5NW/EtCk4SBxAc+8ElPrvJjtZyOPWfm4vZF5sDKtC3Fkg== +-----END RSA PRIVATE KEY----- diff --git a/ext/openssl/tests/bug54992.phpt b/ext/openssl/tests/bug54992.phpt new file mode 100644 index 0000000000000..d3a06310eb121 --- /dev/null +++ b/ext/openssl/tests/bug54992.phpt @@ -0,0 +1,44 @@ +--TEST-- +Bug #54992: Stream not closed and error not returned when SSL CN_match fails +--SKIPIF-- + array( + 'verify_peer' => true, + 'cafile' => 'bug54992-ca.pem', + 'CN_match' => 'buga_buga', + ) + ) + ); + var_dump(stream_socket_client("ssl://127.0.0.1:64321", $errno, $errstr, 1, + STREAM_CLIENT_CONNECT, $contextC)); +} else { + @pcntl_wait($status); + @stream_socket_accept($server, 1); +} +--EXPECTF-- +Warning: stream_socket_client(): Peer certificate CN=`bug54992.local' did not match expected CN=`buga_buga' in %s on line %d + +Warning: stream_socket_client(): Failed to enable crypto in %s on line %d + +Warning: stream_socket_client(): unable to connect to ssl://127.0.0.1:64321 (Unknown error) in %s on line %d +bool(false) + + diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c index e825e791e63c7..4de8825e3dbe8 100644 --- a/ext/openssl/xp_ssl.c +++ b/ext/openssl/xp_ssl.c @@ -515,6 +515,7 @@ static inline int php_openssl_enable_crypto(php_stream *stream, if (FAILURE == php_openssl_apply_verification_policy(sslsock->ssl_handle, peer_cert, stream TSRMLS_CC)) { SSL_shutdown(sslsock->ssl_handle); + n = -1; } else { sslsock->ssl_active = 1; From 547ab485214d860551d20c2d8333f6bfbc85e54b Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Wed, 8 Jun 2011 00:53:55 +0000 Subject: [PATCH 0124/2394] s/valid path/a valid path/ --- Zend/zend_API.c | 4 ++-- ext/oci8/tests/null_byte_1.phpt | 4 ++-- ext/standard/tests/file/bug39863.phpt | 2 +- .../tests/file/disk_free_space_variation.phpt | 16 ++++++++-------- .../tests/file/disk_total_space_variation.phpt | 8 ++++---- .../tests/file/filegroup_variation3.phpt | 4 ++-- .../tests/file/fileinode_variation3.phpt | 4 ++-- .../tests/file/fileowner_variation3.phpt | 4 ++-- .../tests/file/fileperms_variation3.phpt | 4 ++-- ext/standard/tests/file/glob_variation.phpt | 14 +++++++------- ext/standard/tests/file/is_dir_variation4.phpt | 4 ++-- .../tests/file/is_executable_variation1.phpt | 4 ++-- ext/standard/tests/file/is_file_variation4.phpt | 4 ++-- .../tests/file/is_readable_variation1.phpt | 6 +++--- .../tests/file/is_writable_variation1.phpt | 12 ++++++------ ext/standard/tests/file/tempnam_variation7.phpt | 4 ++-- 16 files changed, 49 insertions(+), 49 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index cd5e52f20d5a1..3ae6088786a72 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -434,14 +434,14 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha *p = Z_STRVAL_PP(arg); *pl = Z_STRLEN_PP(arg); if (c == 'p' && CHECK_ZVAL_NULL_PATH(*arg)) { - return "valid path"; + return "a valid path"; } break; case IS_OBJECT: if (parse_arg_object_to_string(arg, p, pl, IS_STRING TSRMLS_CC) == SUCCESS) { if (c == 'p' && CHECK_ZVAL_NULL_PATH(*arg)) { - return "valid path"; + return "a valid path"; } break; } diff --git a/ext/oci8/tests/null_byte_1.phpt b/ext/oci8/tests/null_byte_1.phpt index 6b1529038a3ee..6898049bd96e2 100644 --- a/ext/oci8/tests/null_byte_1.phpt +++ b/ext/oci8/tests/null_byte_1.phpt @@ -33,10 +33,10 @@ var_dump($r); --EXPECTF-- Test 1: Import -Warning: OCI-Lob::savefile() expects parameter 1 to be valid path, string given in %snull_byte_1.php on line %d +Warning: OCI-Lob::savefile() expects parameter 1 to be a valid path, string given in %snull_byte_1.php on line %d NULL Test 2: Export -Warning: OCI-Lob::export() expects parameter 1 to be valid path, string given in %snull_byte_1.php on line %d +Warning: OCI-Lob::export() expects parameter 1 to be a valid path, string given in %snull_byte_1.php on line %d NULL ===DONE=== diff --git a/ext/standard/tests/file/bug39863.phpt b/ext/standard/tests/file/bug39863.phpt index edbb90de07d15..5e26b5a6361f1 100644 --- a/ext/standard/tests/file/bug39863.phpt +++ b/ext/standard/tests/file/bug39863.phpt @@ -17,7 +17,7 @@ else { ===DONE=== --EXPECTF-- -Warning: file_exists() expects parameter 1 to be valid path, string given in %s on line %d +Warning: file_exists() expects parameter 1 to be a valid path, string given in %s on line %d PASS ===DONE=== diff --git a/ext/standard/tests/file/disk_free_space_variation.phpt b/ext/standard/tests/file/disk_free_space_variation.phpt index debc84b14eff3..adb1acaf82904 100644 --- a/ext/standard/tests/file/disk_free_space_variation.phpt +++ b/ext/standard/tests/file/disk_free_space_variation.phpt @@ -106,34 +106,34 @@ float(%d) -- Iteration 9 -- -Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_free_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +Warning: diskfreespace() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 10 -- -Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_free_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +Warning: diskfreespace() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 11 -- -Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_free_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +Warning: diskfreespace() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 12 -- -Warning: disk_free_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_free_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: diskfreespace() expects parameter 1 to be valid path, string given in %s on line %d +Warning: diskfreespace() expects parameter 1 to be a valid path, string given in %s on line %d NULL --- Done --- diff --git a/ext/standard/tests/file/disk_total_space_variation.phpt b/ext/standard/tests/file/disk_total_space_variation.phpt index 4cf4110f56b71..78f1932e3a816 100644 --- a/ext/standard/tests/file/disk_total_space_variation.phpt +++ b/ext/standard/tests/file/disk_total_space_variation.phpt @@ -100,22 +100,22 @@ float(%d) -- Iteration 9 -- -Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_total_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 10 -- -Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_total_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 11 -- -Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_total_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 12 -- -Warning: disk_total_space() expects parameter 1 to be valid path, string given in %s on line %d +Warning: disk_total_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Testing with Binary Input *** float(64246190080) diff --git a/ext/standard/tests/file/filegroup_variation3.phpt b/ext/standard/tests/file/filegroup_variation3.phpt index b61f8984d54b1..b275944f782dd 100644 --- a/ext/standard/tests/file/filegroup_variation3.phpt +++ b/ext/standard/tests/file/filegroup_variation3.phpt @@ -75,11 +75,11 @@ Warning: filegroup(): stat failed for %s/filegroup_variation3/filegroup*.tmp in bool(false) - Iteration 7 - -Warning: filegroup() expects parameter 1 to be valid path, string given in %s on line %d +Warning: filegroup() expects parameter 1 to be a valid path, string given in %s on line %d NULL - Iteration 8 - -Warning: filegroup() expects parameter 1 to be valid path, string given in %s on line %d +Warning: filegroup() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/fileinode_variation3.phpt b/ext/standard/tests/file/fileinode_variation3.phpt index ab8afd601d193..6cb95ecf34eac 100644 --- a/ext/standard/tests/file/fileinode_variation3.phpt +++ b/ext/standard/tests/file/fileinode_variation3.phpt @@ -76,11 +76,11 @@ Warning: fileinode(): stat failed for %s/fileinode_variation3/fileinode*.tmp in bool(false) - Iteration 7 - -Warning: fileinode() expects parameter 1 to be valid path, string given in %s on line %d +Warning: fileinode() expects parameter 1 to be a valid path, string given in %s on line %d NULL - Iteration 8 - -Warning: fileinode() expects parameter 1 to be valid path, string given in %s on line %d +Warning: fileinode() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/fileowner_variation3.phpt b/ext/standard/tests/file/fileowner_variation3.phpt index e46d82c1afe51..6f91c31d1132b 100644 --- a/ext/standard/tests/file/fileowner_variation3.phpt +++ b/ext/standard/tests/file/fileowner_variation3.phpt @@ -76,11 +76,11 @@ Warning: fileowner(): stat failed for %s/fileowner_variation3/fileowner*.tmp in bool(false) - Iteration 7 - -Warning: fileowner() expects parameter 1 to be valid path, string given in %s on line %d +Warning: fileowner() expects parameter 1 to be a valid path, string given in %s on line %d NULL - Iteration 8 - -Warning: fileowner() expects parameter 1 to be valid path, string given in %s on line %d +Warning: fileowner() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/fileperms_variation3.phpt b/ext/standard/tests/file/fileperms_variation3.phpt index 9c59cf7cdbc95..575fe11a2f0c1 100644 --- a/ext/standard/tests/file/fileperms_variation3.phpt +++ b/ext/standard/tests/file/fileperms_variation3.phpt @@ -75,11 +75,11 @@ Warning: fileperms(): stat failed for %s/fileperms_variation3/fileperms*.tmp in bool(false) - Iteration 7 - -Warning: fileperms() expects parameter 1 to be valid path, string given in %s on line %d +Warning: fileperms() expects parameter 1 to be a valid path, string given in %s on line %d NULL - Iteration 8 - -Warning: fileperms() expects parameter 1 to be valid path, string given in %s on line %d +Warning: fileperms() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/glob_variation.phpt b/ext/standard/tests/file/glob_variation.phpt index 01a955dc14fe4..00fd6ff3ed4bb 100755 --- a/ext/standard/tests/file/glob_variation.phpt +++ b/ext/standard/tests/file/glob_variation.phpt @@ -326,22 +326,22 @@ array(0) { -- Iteration 8 -- -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 9 -- @@ -446,7 +446,7 @@ array(0) { } -- Iteration 8 -- -Warning: glob() expects parameter 1 to be valid path, string given in %s on line %d +Warning: glob() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 9 -- array(0) { diff --git a/ext/standard/tests/file/is_dir_variation4.phpt b/ext/standard/tests/file/is_dir_variation4.phpt index 0867d1b605a30..5c0be485c56aa 100644 --- a/ext/standard/tests/file/is_dir_variation4.phpt +++ b/ext/standard/tests/file/is_dir_variation4.phpt @@ -78,12 +78,12 @@ bool(false) -- Iteration 9 -- -Warning: is_dir() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_dir() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 10 -- -Warning: is_dir() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_dir() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/is_executable_variation1.phpt b/ext/standard/tests/file/is_executable_variation1.phpt index 2e579ccff64a7..231f1bff3fb02 100644 --- a/ext/standard/tests/file/is_executable_variation1.phpt +++ b/ext/standard/tests/file/is_executable_variation1.phpt @@ -77,11 +77,11 @@ bool(false) bool(false) -- Iteration 6 -- -Warning: is_executable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_executable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 7 -- -Warning: is_executable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_executable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 8 -- bool(false) diff --git a/ext/standard/tests/file/is_file_variation4.phpt b/ext/standard/tests/file/is_file_variation4.phpt index 11ca5d5558493..b927446b7ca37 100644 --- a/ext/standard/tests/file/is_file_variation4.phpt +++ b/ext/standard/tests/file/is_file_variation4.phpt @@ -68,11 +68,11 @@ bool(false) bool(false) - Iteration 7 - -Warning: is_file() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_file() expects parameter 1 to be a valid path, string given in %s on line %d NULL - Iteration 8 - -Warning: is_file() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_file() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Done *** diff --git a/ext/standard/tests/file/is_readable_variation1.phpt b/ext/standard/tests/file/is_readable_variation1.phpt index e9f168a8e1cc1..5becac00a2447 100644 --- a/ext/standard/tests/file/is_readable_variation1.phpt +++ b/ext/standard/tests/file/is_readable_variation1.phpt @@ -88,15 +88,15 @@ bool(false) bool(false) -- Iteration 7 -- -Warning: is_readable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_readable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 8 -- -Warning: is_readable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_readable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 9 -- -Warning: is_readable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_readable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 10 -- bool(true) diff --git a/ext/standard/tests/file/is_writable_variation1.phpt b/ext/standard/tests/file/is_writable_variation1.phpt index 524684dea8132..718c7fb8e9673 100644 --- a/ext/standard/tests/file/is_writable_variation1.phpt +++ b/ext/standard/tests/file/is_writable_variation1.phpt @@ -97,24 +97,24 @@ bool(false) bool(false) -- Iteration 7 -- -Warning: is_writable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_writable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: is_writeable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_writeable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 8 -- -Warning: is_writable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_writable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: is_writeable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_writeable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 9 -- -Warning: is_writable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_writable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -Warning: is_writeable() expects parameter 1 to be valid path, string given in %s on line %d +Warning: is_writeable() expects parameter 1 to be a valid path, string given in %s on line %d NULL -- Iteration 10 -- bool(true) diff --git a/ext/standard/tests/file/tempnam_variation7.phpt b/ext/standard/tests/file/tempnam_variation7.phpt index e76e1f0c6aaf4..dd823d47a22d3 100644 --- a/ext/standard/tests/file/tempnam_variation7.phpt +++ b/ext/standard/tests/file/tempnam_variation7.phpt @@ -95,13 +95,13 @@ File permissions are => 100600 File created in => temp dir -- Iteration 6 -- -Warning: tempnam() expects parameter 1 to be valid path, string given in %s on line %d +Warning: tempnam() expects parameter 1 to be a valid path, string given in %s on line %d -- File is not created -- Warning: unlink(): Invalid argument in %s on line %d -- Iteration 7 -- -Warning: tempnam() expects parameter 1 to be valid path, array given in %s on line %d +Warning: tempnam() expects parameter 1 to be a valid path, array given in %s on line %d -- File is not created -- Warning: unlink(): Invalid argument in %s on line %d From 2e235022e9ff618e66adb7352c15f489d05eac60 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Wed, 8 Jun 2011 01:25:35 +0000 Subject: [PATCH 0125/2394] Relax autoconf support from 2.60 to 2.59. This is the version available on Centos/RHEL/Oracle Linux 5.6 --- build/buildcheck.sh | 8 ++++---- configure.in | 4 ++-- scripts/phpize.m4 | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build/buildcheck.sh b/build/buildcheck.sh index 2815e3e0e6118..8754e3a292aec 100755 --- a/build/buildcheck.sh +++ b/build/buildcheck.sh @@ -28,18 +28,18 @@ if test -z "$PHP_AUTOCONF"; then PHP_AUTOCONF='autoconf' fi -# autoconf 2.60 or newer +# autoconf 2.59 or newer ac_version=`$PHP_AUTOCONF --version 2>/dev/null|head -n 1|sed -e 's/^[^0-9]*//' -e 's/[a-z]* *$//'` if test -z "$ac_version"; then echo "buildconf: autoconf not found." -echo " You need autoconf version 2.60 or newer installed" +echo " You need autoconf version 2.59 or newer installed" echo " to build PHP from SVN." exit 1 fi IFS=.; set $ac_version; IFS=' ' -if test "$1" = "2" -a "$2" -lt "60" || test "$1" -lt "2"; then +if test "$1" = "2" -a "$2" -lt "59" || test "$1" -lt "2"; then echo "buildconf: autoconf version $ac_version found." -echo " You need autoconf version 2.60 or newer installed" +echo " You need autoconf version 2.59 or newer installed" echo " to build PHP from SVN." exit 1 else diff --git a/configure.in b/configure.in index a905cede231af..0b0eb200ae19e 100644 --- a/configure.in +++ b/configure.in @@ -8,9 +8,9 @@ sinclude(Zend/acinclude.m4) dnl Basic autoconf + automake initialization, generation of config.nice. dnl ------------------------------------------------------------------------- -AC_PREREQ(2.60) +AC_PREREQ(2.59) AC_INIT(README.SVN-RULES) -AC_PRESERVE_HELP_ORDER +ifdef([AC_PRESERVE_HELP_ORDER], [AC_PRESERVE_HELP_ORDER], []) PHP_CONFIG_NICE(config.nice) diff --git a/scripts/phpize.m4 b/scripts/phpize.m4 index 7faf6231da07f..d745ca744381e 100644 --- a/scripts/phpize.m4 +++ b/scripts/phpize.m4 @@ -1,8 +1,8 @@ dnl This file becomes configure.in for self-contained extensions. -AC_PREREQ(2.60) +AC_PREREQ(2.59) AC_INIT(config.m4) -AC_PRESERVE_HELP_ORDER +ifdef([AC_PRESERVE_HELP_ORDER], [AC_PRESERVE_HELP_ORDER], []) PHP_CONFIG_NICE(config.nice) From d42683cbd2dbbb56481f8c2a35dded02da0a8725 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 8 Jun 2011 02:03:14 +0000 Subject: [PATCH 0126/2394] Fixed test to account for smaller default floating point # precision --- .../serialization_miscTypes_001.phpt | Bin 7686 -> 7587 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/standard/tests/serialize/serialization_miscTypes_001.phpt b/ext/standard/tests/serialize/serialization_miscTypes_001.phpt index 276913524b852b789f3fda9e072c5fbf1099ee8d..d939274a01068656796adfccc1bf31d07967f5fa 100644 GIT binary patch delta 23 fcmZp(S!}%_m7mdQay!5B=9B!-m^NP$GT{aQXwnFc delta 124 zcmWlR%LxKO5Cy@jhXE51+ywgfy8E%FqgS&KJR5=u2%D2}I9qkD`mE3E_ckutQK1uK zrKLo>WzbxR5?90fK9;kh+9*h3N<%^cF&eWA+iUy|i)eUB@8uj)3?57^k#Gj~+4eZa F@edZm9A*Fj From 9c98b189505b849bba107b1cff38958bc8e58313 Mon Sep 17 00:00:00 2001 From: Timm Friebe Date: Wed, 8 Jun 2011 08:14:49 +0000 Subject: [PATCH 0127/2394] - Changed output to be more verbose as to what libraries are used - Changed check for 64-bit vs 32-bit build environment to check sizeof(int) instead of assuming that if libsybct64.so exists, it must be 64-bit # Bug #53540: Correct Sybase 15.0 libraries not found by configure --- ext/sybase_ct/config.m4 | 31 +++++++++++++++++++++++++++---- 1 file changed, 27 insertions(+), 4 deletions(-) diff --git a/ext/sybase_ct/config.m4 b/ext/sybase_ct/config.m4 index 2c8fe7519ebd5..81df1f3126f2e 100644 --- a/ext/sybase_ct/config.m4 +++ b/ext/sybase_ct/config.m4 @@ -15,7 +15,7 @@ if test "$PHP_SYBASE_CT" != "no"; then AC_DEFINE(HAVE_SYBASE_CT,1,[ ]) PHP_NEW_EXTENSION(sybase_ct, php_sybase_ct.c, $ext_shared) PHP_SUBST(SYBASE_CT_SHARED_LIBADD) - + if test "$PHP_SYBASE_CT" = "yes"; then SYBASE_CT_INCDIR=/home/sybase/include SYBASE_CT_LIBDIR=/home/sybase/lib @@ -24,17 +24,37 @@ if test "$PHP_SYBASE_CT" != "no"; then SYBASE_CT_LIBDIR=$PHP_SYBASE_CT/lib fi + dnl Determine whether we're building 64 or 32 bit... + AC_CHECK_SIZEOF(long int, 4) + AC_MSG_CHECKING([checking if we're on a 64-bit platform]) + if test "$ac_cv_sizeof_long_int" = "4"; then + AC_MSG_RESULT([no]) + PHP_SYBASE_64=no + else + AC_MSG_RESULT([yes]) + PHP_SYBASE_64=yes + fi + + + AC_MSG_CHECKING([Checking for ctpublic.h]) if test -f $SYBASE_CT_INCDIR/ctpublic.h; then + AC_MSG_RESULT([found in $SYBASE_CT_INCDIR]) PHP_ADD_INCLUDE($SYBASE_CT_INCDIR) else AC_MSG_ERROR([ctpublic.h missing!]) fi - + + AC_MSG_CHECKING([Checking Sybase libdir]) + AC_MSG_RESULT([Have $SYBASE_CT_LIBDIR]) + + AC_MSG_CHECKING([Checking for Sybase platform libraries]) + PHP_ADD_LIBPATH($SYBASE_CT_LIBDIR, SYBASE_CT_SHARED_LIBADD) if test -f $SYBASE_CT_INCDIR/tds.h || test -f $SYBASE_CT_INCDIR/tds_sysdep_public.h; then PHP_ADD_LIBRARY(ct,, SYBASE_CT_SHARED_LIBADD) SYBASE_CT_LIBS="-L$SYBASE_CT_LIBDIR -lct" - elif test -f $SYBASE_CT_INCDIR/libsybct64.so; then + AC_MSG_RESULT([FreeTDS: $SYBASE_CT_LIBS]) + elif test -f $SYBASE_CT_LIBDIR/libsybct64.so && test $PHP_SYBASE_64 = "yes"; then PHP_ADD_LIBRARY(sybcs64,, SYBASE_CT_SHARED_LIBADD) PHP_ADD_LIBRARY(sybct64,, SYBASE_CT_SHARED_LIBADD) PHP_ADD_LIBRARY(sybcomn64,, SYBASE_CT_SHARED_LIBADD) @@ -46,6 +66,7 @@ if test "$PHP_SYBASE_CT" != "no"; then *) CFLAGS="${CFLAGS} -DSYB_LP64" ;; # esac SYBASE_CT_LIBS="-L$SYBASE_CT_LIBDIR -lsybcs64 -lsybct64 -lsybcomn64 -lsybintl64" + AC_MSG_RESULT([Sybase64: $SYBASE_CT_LIBS]) PHP_CHECK_LIBRARY(sybtcl64, netg_errstr, [ PHP_ADD_LIBRARY(sybtcl64,,SYBASE_CT_SHARED_LIBADD) @@ -57,13 +78,14 @@ if test "$PHP_SYBASE_CT" != "no"; then PHP_CHECK_LIBRARY(insck64, insck__getVdate, [PHP_ADD_LIBRARY(insck64,, SYBASE_CT_SHARED_LIBADD)],[],[-L$SYBASE_CT_LIBDIR]) PHP_CHECK_LIBRARY(insck64, bsd_tcp, [PHP_ADD_LIBRARY(insck64,, SYBASE_CT_SHARED_LIBADD)],[],[-L$SYBASE_CT_LIBDIR]) - elif test -f $SYBASE_CT_INCDIR/libsybct.so; then + elif test -f $SYBASE_CT_LIBDIR/libsybct.so; then PHP_ADD_LIBRARY(sybcs,, SYBASE_CT_SHARED_LIBADD) PHP_ADD_LIBRARY(sybct,, SYBASE_CT_SHARED_LIBADD) PHP_ADD_LIBRARY(sybcomn,, SYBASE_CT_SHARED_LIBADD) PHP_ADD_LIBRARY(sybintl,, SYBASE_CT_SHARED_LIBADD) SYBASE_CT_LIBS="-L$SYBASE_CT_LIBDIR -lsybcs -lsybct -lsybcomn -lsybintl" + AC_MSG_RESULT([Sybase32 syb-prefix: $SYBASE_CT_LIBS]) PHP_CHECK_LIBRARY(sybtcl, netg_errstr, [ PHP_ADD_LIBRARY(sybtcl,,SYBASE_CT_SHARED_LIBADD) @@ -82,6 +104,7 @@ if test "$PHP_SYBASE_CT" != "no"; then PHP_ADD_LIBRARY(intl,, SYBASE_CT_SHARED_LIBADD) SYBASE_CT_LIBS="-L$SYBASE_CT_LIBDIR -lcs -lct -lcomn -lintl" + AC_MSG_RESULT([Sybase32 default: $SYBASE_CT_LIBS]) PHP_CHECK_LIBRARY(tcl, netg_errstr, [ PHP_ADD_LIBRARY(tcl,,SYBASE_CT_SHARED_LIBADD) From 8d2fe9fcb9f7c5baba1628e0bd6e6b9bd64a4cf2 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 8 Jun 2011 23:30:02 +0000 Subject: [PATCH 0128/2394] Fixed test --- ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt b/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt index 403e01aa76bfb..a02da0f0fde72 100644 --- a/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt +++ b/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt @@ -39,6 +39,10 @@ validateOnParse set to FALSE: No Error Report Above validateOnParse set to TRUE: +Warning: DOMDocument::loadXML(): Entity 'nbsp' not defined in Entity, line: %d in %s on line %d + +Warning: DOMDocument::loadXML(): Entity 'copy' not defined in Entity, line: %d in %s on line %d + Warning: DOMDocument::loadXML(): No declaration for element NYPHP in Entity, line: %d in %s on line %d Warning: DOMDocument::loadXML(): Element from was declared #PCDATA but contains non text nodes in Entity, line: %d in %s on line %d From 8f4d49796449a78ab34775d354f435bf75d37204 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 9 Jun 2011 00:23:43 +0000 Subject: [PATCH 0129/2394] - Missing fixes for grammar fix 's/valid path/a valid path/' --- Zend/zend_API.c | 2 +- ext/phar/tests/fopen_edgecases2.phpt | 2 +- ext/phar/tests/opendir_edgecases.phpt | 4 ++-- ext/standard/tests/dir/chdir_variation1.phpt | 4 ++-- ext/standard/tests/dir/scandir_variation1.phpt | 4 ++-- ext/standard/tests/file/007_error.phpt | 4 ++-- ext/standard/tests/file/chmod_variation3.phpt | 10 +++++----- ext/standard/tests/file/filegroup_variation2.phpt | 2 +- ext/standard/tests/file/fileinode_variation2.phpt | 2 +- ext/standard/tests/file/fileowner_variation2.phpt | 2 +- ext/standard/tests/file/fileperms_variation2.phpt | 2 +- ext/standard/tests/file/is_dir_variation3.phpt | 2 +- ext/standard/tests/file/is_executable_variation3.phpt | 2 +- ext/standard/tests/file/is_file_error.phpt | 2 +- ext/standard/tests/file/is_file_variation3.phpt | 2 +- ext/standard/tests/file/is_readable_variation3.phpt | 2 +- ext/standard/tests/file/is_writable_variation3.phpt | 4 ++-- ext/standard/tests/file/lchown_error.phpt | 4 ++-- ext/standard/tests/file/lstat_stat_error.phpt | 4 ++-- ext/standard/tests/file/parse_ini_file_variation4.phpt | 10 +++++----- 20 files changed, 35 insertions(+), 35 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 3ae6088786a72..28ac9e9364586 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -449,7 +449,7 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha case IS_ARRAY: case IS_RESOURCE: default: - return c == 's' ? "string" : "valid path"; + return c == 's' ? "string" : "a valid path"; } } break; diff --git a/ext/phar/tests/fopen_edgecases2.phpt b/ext/phar/tests/fopen_edgecases2.phpt index 6c5ac7b455fd9..872aa289bc94c 100644 --- a/ext/phar/tests/fopen_edgecases2.phpt +++ b/ext/phar/tests/fopen_edgecases2.phpt @@ -36,7 +36,7 @@ include $pname . '/foo/hi'; --EXPECTF-- -Warning: fopen() expects parameter 1 to be string, array given in %sfopen_edgecases2.php on line %d +Warning: fopen() expects parameter 1 to be a valid path, array given in %sfopen_edgecases2.php on line %d blah test diff --git a/ext/phar/tests/opendir_edgecases.phpt b/ext/phar/tests/opendir_edgecases.phpt index c0f5ebc067e04..be899df81b7a6 100644 --- a/ext/phar/tests/opendir_edgecases.phpt +++ b/ext/phar/tests/opendir_edgecases.phpt @@ -52,10 +52,10 @@ include $pname . '/foo'; Date: Thu, 9 Jun 2011 06:49:31 +0000 Subject: [PATCH 0130/2394] Removed 'b' string prefix as unneeded from some tests. --- ext/curl/tests/curl_basic_011.phpt | 3 +-- ext/curl/tests/curl_basic_012.phpt | 3 +-- ext/curl/tests/curl_basic_013.phpt | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/ext/curl/tests/curl_basic_011.phpt b/ext/curl/tests/curl_basic_011.phpt index dfdc8f9e04b11..d67fb22878161 100644 --- a/ext/curl/tests/curl_basic_011.phpt +++ b/ext/curl/tests/curl_basic_011.phpt @@ -3,7 +3,7 @@ Test curl_opt() function with COOKIE --CREDITS-- TestFest 2009 - AFUP - Xavier Gorse --SKIPIF-- - + --FILE-- *** Testing curl with cookie *** string(3) "bar" ===DONE=== - \ No newline at end of file diff --git a/ext/curl/tests/curl_basic_012.phpt b/ext/curl/tests/curl_basic_012.phpt index e4706fad46122..2cfa7b38ed4be 100644 --- a/ext/curl/tests/curl_basic_012.phpt +++ b/ext/curl/tests/curl_basic_012.phpt @@ -3,7 +3,7 @@ Test curl_opt() function with CURLOPT_HTTP_VERSION/CURL_HTTP_VERSION_1_0 --CREDITS-- TestFest 2009 - AFUP - Xavier Gorse --SKIPIF-- - + --FILE-- *** Testing curl with HTTP/1.0 *** string(8) "HTTP/1.0" ===DONE=== - \ No newline at end of file diff --git a/ext/curl/tests/curl_basic_013.phpt b/ext/curl/tests/curl_basic_013.phpt index c49d187be3117..bc396e11e79e4 100644 --- a/ext/curl/tests/curl_basic_013.phpt +++ b/ext/curl/tests/curl_basic_013.phpt @@ -3,7 +3,7 @@ Test curl_opt() function with CURLOPT_HTTP_VERSION/CURL_HTTP_VERSION_1_1 --CREDITS-- TestFest 2009 - AFUP - Xavier Gorse --SKIPIF-- - + --FILE-- *** Testing curl with HTTP/1.1 *** string(8) "HTTP/1.1" ===DONE=== - \ No newline at end of file From 0214bbed253d8222db6745ac4f4bb114b82edad7 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Thu, 9 Jun 2011 07:16:13 +0000 Subject: [PATCH 0131/2394] Updated (currently failing) test for bug48203 with curl_stderr and added also curl_multi_exec variant of this test. --- ext/curl/tests/bug48203.phpt | 68 +++++++++-- ext/curl/tests/bug48203_multi.phpt | 106 ++++++++++++++++++ .../curl_file_deleted_before_curl_close.phpt | 37 ++++++ 3 files changed, 200 insertions(+), 11 deletions(-) create mode 100644 ext/curl/tests/bug48203_multi.phpt create mode 100644 ext/curl/tests/curl_file_deleted_before_curl_close.phpt diff --git a/ext/curl/tests/bug48203.phpt b/ext/curl/tests/bug48203.phpt index 84fcf83a069b6..448ecbbc955c7 100644 --- a/ext/curl/tests/bug48203.phpt +++ b/ext/curl/tests/bug48203.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #48203 (Crash when CURLOPT_STDERR is set to regular file) +Bug #48203 (Crash when file pointers passed to curl are closed before calling curl_exec) --SKIPIF-- --CLEAN-- ---EXPECT-- -Ok +--EXPECTF-- +Warning: curl_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_exec(): CURLOPT_STDERR handle is incorrect in %s on line %d +* About to connect() %a +* Closing connection #%d +Ok for CURLOPT_STDERR + +Warning: curl_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_exec(): CURLOPT_WRITEHEADER handle is incorrect in %s on line %d +Ok for CURLOPT_WRITEHEADER + +Warning: curl_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_exec(): CURLOPT_FILE handle is incorrect in %s on line %d +%a +Ok for CURLOPT_FILE + +Warning: curl_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_exec(): CURLOPT_INFILE handle is incorrect in %s on line %d +Ok for CURLOPT_INFILE diff --git a/ext/curl/tests/bug48203_multi.phpt b/ext/curl/tests/bug48203_multi.phpt new file mode 100644 index 0000000000000..0be5135948671 --- /dev/null +++ b/ext/curl/tests/bug48203_multi.phpt @@ -0,0 +1,106 @@ +--TEST-- +Variation of bug #48203 with curl_multi_exec (Crash when file pointers passed to curl are closed before calling curl_multi_exec) +--SKIPIF-- + +--FILE-- + 1, + $curl_option => $fp, + CURLOPT_URL => getenv("PHP_CURL_HTTP_REMOTE_SERVER") + ); + + // we also need to set CURLOPT_VERBOSE to test CURLOPT_STDERR properly + if (CURLOPT_STDERR == $curl_option) { + $options[CURLOPT_VERBOSE] = 1; + } + + if (CURLOPT_INFILE == $curl_option) { + $options[CURLOPT_UPLOAD] = 1; + } + + curl_setopt_array($ch1, $options); + curl_setopt_array($ch2, $options); + + fclose($fp); // <-- premature close of $fp caused a crash! + + $mh = curl_multi_init(); + + curl_multi_add_handle($mh, $ch1); + curl_multi_add_handle($mh, $ch2); + + $active = 0; + do { + curl_multi_exec($mh, $active); + } while ($active > 0); + + curl_multi_remove_handle($mh, $ch1); + curl_multi_remove_handle($mh, $ch2); + curl_multi_close($mh); + + echo "Ok for $description\n"; +} + +$options_to_check = array( + "CURLOPT_STDERR", "CURLOPT_WRITEHEADER", "CURLOPT_FILE", "CURLOPT_INFILE" +); + +foreach($options_to_check as $option) { + checkForClosedFilePointer(constant($option), $option); +} + +?> +--CLEAN-- + +--EXPECTF-- +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_STDERR handle is incorrect in %s on line %d + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_STDERR handle is incorrect in %s on line %d +%a +Ok for CURLOPT_STDERR + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_WRITEHEADER handle is incorrect in %s on line %d + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_WRITEHEADER handle is incorrect in %s on line %d +%AOk for CURLOPT_WRITEHEADER + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_FILE handle is incorrect in %s on line %d + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_FILE handle is incorrect in %s on line %d +%a +Ok for CURLOPT_FILE + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_INFILE handle is incorrect in %s on line %d + +Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d + +Warning: curl_multi_exec(): CURLOPT_INFILE handle is incorrect in %s on line %d +Ok for CURLOPT_INFILE diff --git a/ext/curl/tests/curl_file_deleted_before_curl_close.phpt b/ext/curl/tests/curl_file_deleted_before_curl_close.phpt new file mode 100644 index 0000000000000..680ae547ce7c3 --- /dev/null +++ b/ext/curl/tests/curl_file_deleted_before_curl_close.phpt @@ -0,0 +1,37 @@ +--TEST-- +Memory corruption error if fp of just created file is closed before curl_close. +--CREDITS-- +Alexey Shein +--SKIPIF-- + +--FILE-- + +--CLEAN-- + +--EXPECTF-- +Closed correctly From 59b06399ad61d9ca7f190b541108248d375eabf1 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Thu, 9 Jun 2011 07:44:10 +0000 Subject: [PATCH 0132/2394] Fixed session test breakage due to serialize precision issue. --- ext/session/tests/session_encode_basic.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/session/tests/session_encode_basic.phpt b/ext/session/tests/session_encode_basic.phpt index f74bddd9ca150..b087f7441404f 100644 --- a/ext/session/tests/session_encode_basic.phpt +++ b/ext/session/tests/session_encode_basic.phpt @@ -120,7 +120,7 @@ string(13) "data|d:-10.5;" string(20) "data|d:123456789000;" -- Iteration 8 -- -string(86) "data|d:1.2345678899999999145113427164344339914681114578343112953007221221923828125E-9;" +string(29) "data|d:1.2345678899999999E-9;" -- Iteration 9 -- string(11) "data|d:0.5;" From fb014c0f6da777572d409d3c383799a41c0e935a Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Thu, 9 Jun 2011 08:18:49 +0000 Subject: [PATCH 0133/2394] Skip reason is now printed if session.save_path is not writable. --- ext/session/tests/skipif.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/session/tests/skipif.inc b/ext/session/tests/skipif.inc index 6e3eae0862c42..e63f963c5c5d1 100644 --- a/ext/session/tests/skipif.inc +++ b/ext/session/tests/skipif.inc @@ -18,7 +18,7 @@ if ($save_path) { $save_path = substr($save_path, ++$p); } if (!@is_writable($save_path)) { - die("skip\n"); + die("skip session.save_path $save_path is not writable\n"); } } } From f1d7b4d3c6e018a3e8efb81e2503f0e7c7890365 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Thu, 9 Jun 2011 08:24:12 +0000 Subject: [PATCH 0134/2394] Changed session.save_path to /tmp to make test run. --- ext/session/tests/bug32330.phpt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/session/tests/bug32330.phpt b/ext/session/tests/bug32330.phpt index c0d3370e01412..98d442ae5c9c5 100644 --- a/ext/session/tests/bug32330.phpt +++ b/ext/session/tests/bug32330.phpt @@ -6,7 +6,7 @@ Bug #32330 (session_destroy, "Failed to initialize storage module", custom sessi session.use_trans_sid=0 session.use_cookies=1 session.name=sid -session.save_path=/ +session.save_path=/tmp session.gc_probability=1 session.gc_divisor=1 --FILE-- @@ -68,17 +68,17 @@ $_SESSION['E'] = 'F'; ?> --EXPECTF-- -open: path = /, name = sid +open: path = /tmp, name = sid read: id = %s gc: maxlifetime = %d write: id = %s, data = A|s:1:"B"; close -open: path = /, name = sid +open: path = /tmp, name = sid read: id = %s gc: maxlifetime = %d destroy: id = %s close -open: path = /, name = sid +open: path = /tmp, name = sid read: id = %s gc: maxlifetime = %d write: id = %s, data = E|s:1:"F"; From 024439c66ec13ec2f5829d9163db885758e1ba23 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Thu, 9 Jun 2011 08:54:47 +0000 Subject: [PATCH 0135/2394] Removed tests checking old/removed functionality (session_register/session_unregister/session_is_registered/register_globals) --- ext/session/tests/007.phpt | 62 --- .../tests/session_is_registered_basic.phpt | 318 --------------- .../session_is_registered_variation1.phpt | 109 ------ .../session_is_registered_variation2.phpt | 75 ---- .../session_is_registered_variation3.phpt | 72 ---- ext/session/tests/session_register_basic.phpt | 364 ------------------ .../tests/session_register_variation1.phpt | 159 -------- .../tests/session_register_variation2.phpt | 43 --- .../tests/session_register_variation3.phpt | 46 --- .../tests/session_register_variation4.phpt | 47 --- .../tests/session_unregister_basic.phpt | 225 ----------- .../tests/session_unregister_variation1.phpt | 159 -------- .../tests/session_unregister_variation2.phpt | 47 --- .../tests/session_unregister_variation3.phpt | 48 --- 14 files changed, 1774 deletions(-) delete mode 100644 ext/session/tests/007.phpt delete mode 100644 ext/session/tests/session_is_registered_basic.phpt delete mode 100644 ext/session/tests/session_is_registered_variation1.phpt delete mode 100644 ext/session/tests/session_is_registered_variation2.phpt delete mode 100644 ext/session/tests/session_is_registered_variation3.phpt delete mode 100644 ext/session/tests/session_register_basic.phpt delete mode 100644 ext/session/tests/session_register_variation1.phpt delete mode 100644 ext/session/tests/session_register_variation2.phpt delete mode 100644 ext/session/tests/session_register_variation3.phpt delete mode 100644 ext/session/tests/session_register_variation4.phpt delete mode 100644 ext/session/tests/session_unregister_basic.phpt delete mode 100644 ext/session/tests/session_unregister_variation1.phpt delete mode 100644 ext/session/tests/session_unregister_variation2.phpt delete mode 100644 ext/session/tests/session_unregister_variation3.phpt diff --git a/ext/session/tests/007.phpt b/ext/session/tests/007.phpt deleted file mode 100644 index 70560067b54d3..0000000000000 --- a/ext/session/tests/007.phpt +++ /dev/null @@ -1,62 +0,0 @@ ---TEST-- -bug compatibility: unset($c) with enabled register_globals ---SKIPIF-- - ---INI-- -session.use_cookies=0 -session.cache_limiter= -session.serialize_handler=php -session.save_handler=files -precision=14 ---FILE-- - ---EXPECTF-- -Deprecated: Directive 'register_globals' is deprecated in PHP 5.3 and greater in Unknown on line 0 - -Deprecated: Function session_register() is deprecated in %s on line %d -float(3.14) -array(1) { - ["c"]=> - &float(3.14) -} -float(3.14) -array(1) { - ["c"]=> - &float(3.14) -} diff --git a/ext/session/tests/session_is_registered_basic.phpt b/ext/session/tests/session_is_registered_basic.phpt deleted file mode 100644 index dec39e5d8285a..0000000000000 --- a/ext/session/tests/session_is_registered_basic.phpt +++ /dev/null @@ -1,318 +0,0 @@ ---TEST-- -Test session_unregister() function : basic functionality ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_is_registered() : basic functionality *** - --- Iteration 1 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 2 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 3 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 4 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 5 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 6 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 7 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 8 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 9 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 10 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 11 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 12 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 13 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 14 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 15 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 16 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 17 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 18 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 19 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 20 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 21 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 22 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 23 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - --- Iteration 24 -- -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d - -Warning: session_is_registered() expects parameter 1 to be string, resource given in %s on line %d -NULL -array(0) { -} -bool(true) -Done diff --git a/ext/session/tests/session_is_registered_variation1.phpt b/ext/session/tests/session_is_registered_variation1.phpt deleted file mode 100644 index 19a8c1974bab5..0000000000000 --- a/ext/session/tests/session_is_registered_variation1.phpt +++ /dev/null @@ -1,109 +0,0 @@ ---TEST-- -Test session_unregister() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_is_registered() : variation *** -bool(true) -array(0) { -} - -Deprecated: Function session_is_registered() is deprecated in %s on line %d - -Warning: session_is_registered() expects parameter 1 to be string, array given in %s on line %d -NULL -array(0) { -} -bool(true) -array(0) { -} -Done diff --git a/ext/session/tests/session_is_registered_variation2.phpt b/ext/session/tests/session_is_registered_variation2.phpt deleted file mode 100644 index 61c9e276366d8..0000000000000 --- a/ext/session/tests/session_is_registered_variation2.phpt +++ /dev/null @@ -1,75 +0,0 @@ ---TEST-- -Test session_unregister() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_is_registered() : variation *** - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(true) -array(1) { - ["foo"]=> - string(12) "Hello World!" -} - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(true) - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -Done diff --git a/ext/session/tests/session_is_registered_variation3.phpt b/ext/session/tests/session_is_registered_variation3.phpt deleted file mode 100644 index 396c7f709306b..0000000000000 --- a/ext/session/tests/session_is_registered_variation3.phpt +++ /dev/null @@ -1,72 +0,0 @@ ---TEST-- -Test session_unregister() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_is_registered() : variation *** - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(1) { - ["foo"]=> - &string(12) "Hello World!" -} - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(true) - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -bool(true) - -Deprecated: Function session_is_registered() is deprecated in %s on line %d -bool(false) -array(0) { -} -Done diff --git a/ext/session/tests/session_register_basic.phpt b/ext/session/tests/session_register_basic.phpt deleted file mode 100644 index 70da518073250..0000000000000 --- a/ext/session/tests/session_register_basic.phpt +++ /dev/null @@ -1,364 +0,0 @@ ---TEST-- -Test session_register() function : basic functionality ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_register() : basic functionality *** - --- Iteration 1 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["0"]=> - NULL -} -bool(true) - --- Iteration 2 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["1"]=> - NULL -} -bool(true) - --- Iteration 3 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["12345"]=> - NULL -} -bool(true) - --- Iteration 4 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["-2345"]=> - NULL -} -bool(true) - --- Iteration 5 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["10.5"]=> - NULL -} -bool(true) - --- Iteration 6 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["-10.5"]=> - NULL -} -bool(true) - --- Iteration 7 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["123456789000"]=> - NULL -} -bool(true) - --- Iteration 8 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["1.23456789E-9"]=> - NULL -} -bool(true) - --- Iteration 9 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["0.5"]=> - NULL -} -bool(true) - --- Iteration 10 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 11 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 12 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["1"]=> - NULL -} -bool(true) - --- Iteration 13 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 14 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["1"]=> - NULL -} -bool(true) - --- Iteration 15 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 16 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 17 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 18 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["Nothing"]=> - NULL -} -bool(true) - --- Iteration 19 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["Nothing"]=> - NULL -} -bool(true) - --- Iteration 20 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["Hello World!"]=> - NULL -} -bool(true) - --- Iteration 21 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["Hello World!"]=> - NULL -} -bool(true) - --- Iteration 22 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 23 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - [""]=> - NULL -} -bool(true) - --- Iteration 24 -- -bool(true) - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["Resource id #%d"]=> - NULL -} -bool(true) -Done diff --git a/ext/session/tests/session_register_variation1.phpt b/ext/session/tests/session_register_variation1.phpt deleted file mode 100644 index 367c88449bb91..0000000000000 --- a/ext/session/tests/session_register_variation1.phpt +++ /dev/null @@ -1,159 +0,0 @@ ---TEST-- -Test session_register() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_register() : variation *** -bool(true) -array(0) { -} - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(13) { - ["0"]=> - NULL - ["1"]=> - NULL - ["12345"]=> - NULL - ["-2345"]=> - NULL - ["10.5"]=> - NULL - ["-10.5"]=> - NULL - ["123456789000"]=> - NULL - ["1.23456789E-9"]=> - NULL - ["0.5"]=> - NULL - [""]=> - NULL - ["Nothing"]=> - NULL - ["Hello World!"]=> - NULL - ["Resource id #%d"]=> - NULL -} -bool(true) -array(13) { - ["0"]=> - NULL - ["1"]=> - NULL - ["12345"]=> - NULL - ["-2345"]=> - NULL - ["10.5"]=> - NULL - ["-10.5"]=> - NULL - ["123456789000"]=> - NULL - ["1.23456789E-9"]=> - NULL - ["0.5"]=> - NULL - [""]=> - NULL - ["Nothing"]=> - NULL - ["Hello World!"]=> - NULL - ["Resource id #%d"]=> - NULL -} -Done diff --git a/ext/session/tests/session_register_variation2.phpt b/ext/session/tests/session_register_variation2.phpt deleted file mode 100644 index 50eac60db029e..0000000000000 --- a/ext/session/tests/session_register_variation2.phpt +++ /dev/null @@ -1,43 +0,0 @@ ---TEST-- -Test session_register() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_register() : variation *** -bool(true) -array(0) { -} - -Deprecated: Function session_register() is deprecated in %s on line %d - -Warning: session_register() expects at least 1 parameter, 0 given in %s on line %d -NULL -array(0) { -} -bool(true) -array(0) { -} -Done diff --git a/ext/session/tests/session_register_variation3.phpt b/ext/session/tests/session_register_variation3.phpt deleted file mode 100644 index 3e7b912580a54..0000000000000 --- a/ext/session/tests/session_register_variation3.phpt +++ /dev/null @@ -1,46 +0,0 @@ ---TEST-- -Test session_register() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_register() : variation *** -bool(true) -array(0) { -} - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["blah"]=> - NULL -} -bool(true) -array(1) { - ["blah"]=> - NULL -} -Done diff --git a/ext/session/tests/session_register_variation4.phpt b/ext/session/tests/session_register_variation4.phpt deleted file mode 100644 index 04892bb7ddc3c..0000000000000 --- a/ext/session/tests/session_register_variation4.phpt +++ /dev/null @@ -1,47 +0,0 @@ ---TEST-- -Test session_register() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_register() : variation *** -bool(true) -array(0) { -} - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(1) { - ["foo"]=> - NULL -} -bool(true) -array(1) { - ["foo"]=> - NULL -} -Done diff --git a/ext/session/tests/session_unregister_basic.phpt b/ext/session/tests/session_unregister_basic.phpt deleted file mode 100644 index 39a16d0812fa9..0000000000000 --- a/ext/session/tests/session_unregister_basic.phpt +++ /dev/null @@ -1,225 +0,0 @@ ---TEST-- -Test session_unregister() function : basic functionality ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_unregister() : basic functionality *** -bool(true) - --- Iteration 1 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 2 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 3 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 4 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 5 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 6 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 7 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 8 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 9 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 10 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 11 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 12 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 13 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 14 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 15 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 16 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 17 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 18 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 19 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 20 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 21 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 22 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 23 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) - --- Iteration 24 -- - -Deprecated: Function session_unregister() is deprecated in %s on line %d - -Warning: session_unregister() expects parameter 1 to be string, resource given in %s on line %d -NULL -bool(true) -Done diff --git a/ext/session/tests/session_unregister_variation1.phpt b/ext/session/tests/session_unregister_variation1.phpt deleted file mode 100644 index 95275dcecd152..0000000000000 --- a/ext/session/tests/session_unregister_variation1.phpt +++ /dev/null @@ -1,159 +0,0 @@ ---TEST-- -Test session_unregister() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_unregister() : variation *** -bool(true) -array(0) { -} - -Deprecated: Function session_register() is deprecated in %s on line %d -bool(true) -array(13) { - ["0"]=> - NULL - ["1"]=> - NULL - ["12345"]=> - NULL - ["-2345"]=> - NULL - ["10.5"]=> - NULL - ["-10.5"]=> - NULL - ["123456789000"]=> - NULL - ["1.23456789E-9"]=> - NULL - ["0.5"]=> - NULL - [""]=> - NULL - ["Nothing"]=> - NULL - ["Hello World!"]=> - NULL - ["Resource id #%d"]=> - NULL -} -bool(true) -array(13) { - ["0"]=> - NULL - ["1"]=> - NULL - ["12345"]=> - NULL - ["-2345"]=> - NULL - ["10.5"]=> - NULL - ["-10.5"]=> - NULL - ["123456789000"]=> - NULL - ["1.23456789E-9"]=> - NULL - ["0.5"]=> - NULL - [""]=> - NULL - ["Nothing"]=> - NULL - ["Hello World!"]=> - NULL - ["Resource id #%d"]=> - NULL -} -Done diff --git a/ext/session/tests/session_unregister_variation2.phpt b/ext/session/tests/session_unregister_variation2.phpt deleted file mode 100644 index 25cfefce315b9..0000000000000 --- a/ext/session/tests/session_unregister_variation2.phpt +++ /dev/null @@ -1,47 +0,0 @@ ---TEST-- -Test session_unregister() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_unregister() : variation *** -bool(true) -array(0) { -} -array(1) { - ["foo"]=> - string(12) "Hello World!" -} - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) -array(0) { -} -bool(true) -array(0) { -} -Done diff --git a/ext/session/tests/session_unregister_variation3.phpt b/ext/session/tests/session_unregister_variation3.phpt deleted file mode 100644 index 5a8aa4818bfd2..0000000000000 --- a/ext/session/tests/session_unregister_variation3.phpt +++ /dev/null @@ -1,48 +0,0 @@ ---TEST-- -Test session_unregister() function : variation ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -*** Testing session_unregister() : variation *** -bool(true) -array(0) { -} -array(1) { - ["foo"]=> - &string(12) "Hello World!" -} - -Deprecated: Function session_unregister() is deprecated in %s on line %d -bool(true) -array(0) { -} -bool(true) -array(0) { -} -Done From 7c46410876dca6efe1b58c2ffad16114e24b67a3 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 9 Jun 2011 22:45:35 +0000 Subject: [PATCH 0136/2394] - Fixed bug #54347 (reflection_extension does not lowercase module function name) patch by: laruence at yahoo dot com dot cn --- ext/reflection/php_reflection.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 1df797b664df2..57f8f48c30deb 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -1111,13 +1111,18 @@ static void _extension_string(string *str, zend_module_entry *module, char *inde /* Is there a better way of doing this? */ while (func->fname) { - if (zend_hash_find(EG(function_table), func->fname, strlen(func->fname) + 1, (void**) &fptr) == FAILURE) { + int fname_len = strlen(func->fname); + char *lc_name = zend_str_tolower_dup(func->fname, fname_len); + + if (zend_hash_find(EG(function_table), lc_name, fname_len + 1, (void**) &fptr) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Internal error: Cannot find extension function %s in global function table", func->fname); func++; + efree(lc_name); continue; } _function_string(str, fptr, NULL, " " TSRMLS_CC); + efree(lc_name); func++; } string_printf(str, "%s }\n", indent); From c49d06051045c277ae4e9487067d20c2b22dca7a Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Fri, 10 Jun 2011 11:46:35 +0000 Subject: [PATCH 0137/2394] Fix Apache1 build --- sapi/apache/mod_php5.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sapi/apache/mod_php5.c b/sapi/apache/mod_php5.c index 97d86a0e4ad20..16f7756d678a5 100644 --- a/sapi/apache/mod_php5.c +++ b/sapi/apache/mod_php5.c @@ -499,6 +499,7 @@ static sapi_module_struct apache_sapi_module = { NULL, /* treat data */ NULL, /* exe location */ 0, /* ini ignore */ + 0, /* ini ignore cwd */ sapi_apache_get_fd, sapi_apache_force_http_10, sapi_apache_get_target_uid, From 16b744d2d4d9dd66edb4248cfc30b70eea85809a Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Fri, 10 Jun 2011 17:38:07 +0000 Subject: [PATCH 0138/2394] Add oci_client_version() returning the runtime Oracle client library version - predominantly useful for the test suite --- ext/oci8/oci8.c | 36 ++++++++++++++++++++++++++++ ext/oci8/oci8_interface.c | 11 +++++++++ ext/oci8/php_oci8_int.h | 1 + ext/oci8/tests/clientversion.phpt | 20 ++++++++++++++++ ext/oci8/tests/clientversion_92.phpt | 20 ++++++++++++++++ 5 files changed, 88 insertions(+) create mode 100644 ext/oci8/tests/clientversion.phpt create mode 100644 ext/oci8/tests/clientversion_92.phpt diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index 6e8edf21c8ae9..e1b0077c68f9c 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -447,6 +447,9 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_oci_result, 0, 0, 2) ZEND_ARG_INFO(0, column_number_or_name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_oci_client_version, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_oci_server_version, 0, 0, 1) ZEND_ARG_INFO(0, connection_resource) ZEND_END_ARG_INFO() @@ -681,6 +684,7 @@ static unsigned char arginfo_oci_bind_array_by_name[] = { 3, BYREF_NONE, BYREF_N #define arginfo_oci_password_change NULL #define arginfo_oci_new_cursor NULL #define arginfo_oci_result NULL +#define arginfo_oci_client_version NULL #define arginfo_oci_server_version NULL #define arginfo_oci_statement_type NULL #define arginfo_oci_num_rows NULL @@ -761,6 +765,7 @@ PHP_FUNCTION(oci_num_fields); PHP_FUNCTION(oci_parse); PHP_FUNCTION(oci_new_cursor); PHP_FUNCTION(oci_result); +PHP_FUNCTION(oci_client_version); PHP_FUNCTION(oci_server_version); PHP_FUNCTION(oci_statement_type); PHP_FUNCTION(oci_num_rows); @@ -836,6 +841,7 @@ zend_function_entry php_oci_functions[] = { PHP_FE(oci_parse, arginfo_oci_parse) PHP_FE(oci_new_cursor, arginfo_oci_new_cursor) PHP_FE(oci_result, arginfo_oci_result) + PHP_FE(oci_client_version, arginfo_oci_client_version) PHP_FE(oci_server_version, arginfo_oci_server_version) PHP_FE(oci_statement_type, arginfo_oci_statement_type) PHP_FE(oci_num_rows, arginfo_oci_num_rows) @@ -1295,6 +1301,7 @@ PHP_RSHUTDOWN_FUNCTION(oci) PHP_MINFO_FUNCTION(oci) { char buf[32]; + char *ver; php_info_print_table_start(); php_info_print_table_row(2, "OCI8 Support", "enabled"); @@ -1306,6 +1313,11 @@ PHP_MINFO_FUNCTION(oci) snprintf(buf, sizeof(buf), "%ld", OCI_G(num_links)); php_info_print_table_row(2, "Active Connections", buf); +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) + php_oci_client_get_version(&ver TSRMLS_DC); + php_info_print_table_row(2, "Oracle Run-time Client Library Version", ver); + efree(ver); +#endif #if defined(OCI_MAJOR_VERSION) && defined(OCI_MINOR_VERSION) snprintf(buf, sizeof(buf), "%d.%d", OCI_MAJOR_VERSION, OCI_MINOR_VERSION); #elif defined(PHP_OCI8_ORACLE_VERSION) @@ -2384,6 +2396,30 @@ int php_oci_password_change(php_oci_connection *connection, char *user, int user return 0; } /* }}} */ + +/* {{{ php_oci_client_get_version() + * + * Get Oracle client library version + */ +void php_oci_client_get_version(char **version TSRMLS_DC) +{ + char version_buff[256]; + sword major_version = 0; + sword minor_version = 0; + sword update_num = 0; + sword patch_num = 0; + sword port_update_num = 0; + +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) /* OCIClientVersion only available 10.2 onwards */ + PHP_OCI_CALL(OCIClientVersion, (&major_version, &minor_version, &update_num, &patch_num, &port_update_num)); + snprintf(version_buff, sizeof(version_buff), "%d.%d.%d.%d.%d", major_version, minor_version, update_num, patch_num, port_update_num); +#else + memcpy(version_buff, "Unknown", sizeof("Unknown")); +#endif + *version = estrdup(version_buff); +} /* }}} */ + + /* {{{ php_oci_server_get_version() * * Get Oracle server version diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c index 954604bf2b2c7..21ef7eae959be 100644 --- a/ext/oci8/oci8_interface.c +++ b/ext/oci8/oci8_interface.c @@ -2002,6 +2002,17 @@ PHP_FUNCTION(oci_result) } /* }}} */ +/* {{{ proto string oci_client_version() + Return a string containing runtime client library version information */ +PHP_FUNCTION(oci_client_version) +{ + char *version = NULL; + + php_oci_client_get_version(&version TSRMLS_CC); + RETURN_STRING(version, 0); +} +/* }}} */ + /* {{{ proto string oci_server_version(resource connection) Return a string containing server version information */ PHP_FUNCTION(oci_server_version) diff --git a/ext/oci8/php_oci8_int.h b/ext/oci8/php_oci8_int.h index e65d2734c1ff8..ba45260673f35 100644 --- a/ext/oci8/php_oci8_int.h +++ b/ext/oci8/php_oci8_int.h @@ -385,6 +385,7 @@ int php_oci_connection_commit(php_oci_connection * TSRMLS_DC); int php_oci_connection_release(php_oci_connection *connection TSRMLS_DC); int php_oci_password_change(php_oci_connection *, char *, int, char *, int, char *, int TSRMLS_DC); +void php_oci_client_get_version(char ** TSRMLS_DC); int php_oci_server_get_version(php_oci_connection *, char ** TSRMLS_DC); void php_oci_fetch_row(INTERNAL_FUNCTION_PARAMETERS, int, int); diff --git a/ext/oci8/tests/clientversion.phpt b/ext/oci8/tests/clientversion.phpt new file mode 100644 index 0000000000000..db70b5affcea4 --- /dev/null +++ b/ext/oci8/tests/clientversion.phpt @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +%d.%d.%d.%d.%d +===DONE=== diff --git a/ext/oci8/tests/clientversion_92.phpt b/ext/oci8/tests/clientversion_92.phpt new file mode 100644 index 0000000000000..d4b92cd35436c --- /dev/null +++ b/ext/oci8/tests/clientversion_92.phpt @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() for Oracle 9.2 client libraries +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +Unknown +===DONE=== From 1c35a1926b8bf61c5e00b12d237b90d412a54daf Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Fri, 10 Jun 2011 19:16:35 +0000 Subject: [PATCH 0139/2394] Add new OCI8 tests. Refactor skipifs. Sync 5.3/5.4/trunk branches --- ext/oci8/tests/array_bind_001.phpt | 2 +- ext/oci8/tests/array_bind_002.phpt | 2 +- ext/oci8/tests/array_bind_003.phpt | 5 +- ext/oci8/tests/array_bind_004.phpt | 5 +- ext/oci8/tests/array_bind_005.phpt | 5 +- ext/oci8/tests/array_bind_006.phpt | 5 +- ext/oci8/tests/array_bind_007.phpt | 2 +- ext/oci8/tests/array_bind_008.phpt | 11 +- ext/oci8/tests/array_bind_010.phpt | 2 +- ext/oci8/tests/array_bind_011.phpt | 2 +- ext/oci8/tests/array_bind_012.phpt | 2 +- ext/oci8/tests/array_bind_014.phpt | 5 +- ext/oci8/tests/array_bind_date.phpt | 5 +- ext/oci8/tests/array_bind_date1.phpt | 5 +- ext/oci8/tests/array_bind_float.phpt | 5 +- ext/oci8/tests/array_bind_float1.phpt | 5 +- ext/oci8/tests/array_bind_int.phpt | 5 +- ext/oci8/tests/array_bind_int1.phpt | 5 +- ext/oci8/tests/array_bind_str.phpt | 7 +- ext/oci8/tests/array_bind_str1.phpt | 7 +- ext/oci8/tests/b47243_1.phpt | 5 +- ext/oci8/tests/b47243_2.phpt | 5 +- ext/oci8/tests/b47243_3.phpt | 5 +- ext/oci8/tests/bind_char_1.phpt | 28 +- ext/oci8/tests/bind_char_1_11gR1.phpt | 12 +- ext/oci8/tests/bind_char_2.phpt | 28 +- ext/oci8/tests/bind_char_2_11gR1.phpt | 12 +- ext/oci8/tests/bind_char_3.phpt | 32 +- ext/oci8/tests/bind_char_3_11gR1.phpt | 14 +- ext/oci8/tests/bind_char_4.phpt | 30 +- ext/oci8/tests/bind_char_4_11gR1.phpt | 14 +- ext/oci8/tests/bind_long.phpt | 32 +- ext/oci8/tests/bind_long_raw.phpt | 5 +- ext/oci8/tests/bind_misccoltypes.phpt | 369 +++++++++ ext/oci8/tests/bind_misccoltypes_errs.phpt | 169 ++++ ext/oci8/tests/bind_number.phpt | 220 +++++ ext/oci8/tests/bind_query.phpt | 78 ++ ext/oci8/tests/bind_raw.phpt | 5 +- ext/oci8/tests/bind_rowid.phpt | 16 +- ext/oci8/tests/bind_sqltafc.phpt | 208 +++++ ext/oci8/tests/bind_sqltchr_1.phpt | 228 ++++++ ext/oci8/tests/bind_sqltchr_2.phpt | 50 ++ ext/oci8/tests/bind_sqltint.phpt | 227 ++++++ ext/oci8/tests/bind_sqltnum.phpt | 278 +++++++ ext/oci8/tests/bind_unsupported_1.phpt | 58 ++ ext/oci8/tests/bind_unsupported_2.phpt | 39 + ext/oci8/tests/bind_unsupported_3.phpt | 45 ++ ext/oci8/tests/bug26133.phpt | 25 +- ext/oci8/tests/bug27303_1.phpt | 46 +- ext/oci8/tests/bug27303_1_11gR1.phpt | 32 +- ext/oci8/tests/bug27303_2.phpt | 44 +- ext/oci8/tests/bug27303_2_11gR1.phpt | 28 +- ext/oci8/tests/bug27303_4.phpt | 16 +- ext/oci8/tests/bug32325.phpt | 23 +- ext/oci8/tests/bug35973.phpt | 5 +- ext/oci8/tests/bug36010.phpt | 5 +- ext/oci8/tests/bug36096.phpt | 4 +- ext/oci8/tests/bug36403.phpt | 34 +- ext/oci8/tests/bug37220.phpt | 15 +- ext/oci8/tests/bug37581.phpt | 5 +- ext/oci8/tests/bug38173.phpt | 5 +- ext/oci8/tests/bug40078.phpt | 5 +- ext/oci8/tests/bug40415.phpt | 5 +- ext/oci8/tests/bug41069.phpt | 20 +- ext/oci8/tests/bug42134.phpt | 5 +- ext/oci8/tests/bug42173.phpt | 5 +- ext/oci8/tests/bug42496_1.phpt | 18 +- ext/oci8/tests/bug42496_2.phpt | 18 +- ext/oci8/tests/bug42841.phpt | 157 ++-- ext/oci8/tests/bug43492.phpt | 17 +- ext/oci8/tests/bug43492_2.phpt | 17 +- ext/oci8/tests/bug43497.phpt | 12 +- ext/oci8/tests/bug43497_92.phpt | 14 +- ext/oci8/tests/bug44008.phpt | 19 +- ext/oci8/tests/bug44113.phpt | 16 +- ext/oci8/tests/bug44206.phpt | 5 +- ext/oci8/tests/bug45458.phpt | 14 +- ext/oci8/tests/bug46994.phpt | 15 +- ext/oci8/tests/bug47189.phpt | 11 +- ext/oci8/tests/bug47281.phpt | 28 +- ext/oci8/tests/bug47281_tt.phpt | 59 ++ ext/oci8/tests/bug51253.phpt | 5 +- ext/oci8/tests/bug51291_1.phpt | 394 +++++++++ ext/oci8/tests/bug51291_2.phpt | 56 ++ ext/oci8/tests/coll_001.phpt | 5 +- ext/oci8/tests/coll_002.phpt | 5 +- ext/oci8/tests/coll_002_func.phpt | 5 +- ext/oci8/tests/coll_003.phpt | 5 +- ext/oci8/tests/coll_003_func.phpt | 5 +- ext/oci8/tests/coll_004.phpt | 5 +- ext/oci8/tests/coll_004_func.phpt | 5 +- ext/oci8/tests/coll_005.phpt | 5 +- ext/oci8/tests/coll_006.phpt | 5 +- ext/oci8/tests/coll_006_func.phpt | 5 +- ext/oci8/tests/coll_007.phpt | 5 +- ext/oci8/tests/coll_008.phpt | 5 +- ext/oci8/tests/coll_009.phpt | 5 +- ext/oci8/tests/coll_009_func.phpt | 5 +- ext/oci8/tests/coll_010.phpt | 5 +- ext/oci8/tests/coll_010_func.phpt | 5 +- ext/oci8/tests/coll_011.phpt | 5 +- ext/oci8/tests/coll_011_func.phpt | 5 +- ext/oci8/tests/coll_012.phpt | 5 +- ext/oci8/tests/coll_012_func.phpt | 5 +- ext/oci8/tests/coll_013.phpt | 5 +- ext/oci8/tests/coll_013_func.phpt | 5 +- ext/oci8/tests/coll_014.phpt | 5 +- ext/oci8/tests/coll_014_func.phpt | 5 +- ext/oci8/tests/coll_015.phpt | 5 +- ext/oci8/tests/coll_015_func.phpt | 5 +- ext/oci8/tests/coll_016.phpt | 5 +- ext/oci8/tests/coll_016_func.phpt | 5 +- ext/oci8/tests/coll_017.phpt | 5 +- ext/oci8/tests/coll_017_func.phpt | 5 +- ext/oci8/tests/coll_018.phpt | 5 +- ext/oci8/tests/coll_019.phpt | 8 +- ext/oci8/tests/commit_001.phpt | 5 +- ext/oci8/tests/commit_002.phpt | 28 +- ext/oci8/tests/commit_old.phpt | 5 +- ext/oci8/tests/conn_attr_1.phpt | 21 +- ext/oci8/tests/conn_attr_2.phpt | 24 +- ext/oci8/tests/conn_attr_3.phpt | 23 +- ext/oci8/tests/conn_attr_4.phpt | 27 +- ext/oci8/tests/conn_attr_5.phpt | 23 +- ext/oci8/tests/connect.inc | 5 +- ext/oci8/tests/connect_scope1.phpt | 10 +- ext/oci8/tests/connect_scope2.phpt | 10 +- ext/oci8/tests/connect_scope_try1.phpt | 12 +- ext/oci8/tests/connect_scope_try2.phpt | 12 +- ext/oci8/tests/connect_scope_try3.phpt | 12 +- ext/oci8/tests/connect_scope_try4.phpt | 12 +- ext/oci8/tests/connect_scope_try5.phpt | 12 +- ext/oci8/tests/connect_scope_try6.phpt | 12 +- .../tests/connect_without_oracle_home_11.phpt | 5 +- .../connect_without_oracle_home_old.phpt | 5 +- .../connect_without_oracle_home_old_11.phpt | 5 +- ext/oci8/tests/create_table.inc | 20 +- ext/oci8/tests/cursor_bind.phpt | 70 +- ext/oci8/tests/cursor_bind_err.phpt | 28 +- ext/oci8/tests/cursors.phpt | 5 +- ext/oci8/tests/cursors_old.phpt | 28 +- ext/oci8/tests/dbmsoutput.phpt | 750 ++++++++++++++++++ ext/oci8/tests/default_prefetch.phpt | 24 +- ext/oci8/tests/default_prefetch0.phpt | 53 ++ ext/oci8/tests/default_prefetch1.phpt | 23 +- ext/oci8/tests/default_prefetch2.phpt | 23 +- ext/oci8/tests/define.phpt | 18 +- ext/oci8/tests/define0.phpt | 61 ++ ext/oci8/tests/define1.phpt | 18 +- ext/oci8/tests/define2.phpt | 19 +- ext/oci8/tests/define3.phpt | 17 +- ext/oci8/tests/define4.phpt | 18 +- ext/oci8/tests/define5.phpt | 18 +- ext/oci8/tests/define6.phpt | 138 ++++ ext/oci8/tests/define_old.phpt | 19 +- ext/oci8/tests/descriptors.phpt | 5 +- ext/oci8/tests/details.inc | 109 ++- ext/oci8/tests/drcp_connect1.phpt | 22 +- ext/oci8/tests/drcp_functions.inc | 2 +- ext/oci8/tests/drcp_privileged.phpt | 17 +- ext/oci8/tests/driver_name.phpt | 18 +- ext/oci8/tests/dupcolnames.phpt | 102 +++ ext/oci8/tests/edition_1.phpt | 28 +- ext/oci8/tests/edition_2.phpt | 17 +- ext/oci8/tests/error.phpt | 15 +- ext/oci8/tests/error1.phpt | 4 +- ext/oci8/tests/error2.phpt | 10 +- ext/oci8/tests/error_bind.phpt | 2 +- ext/oci8/tests/error_old.phpt | 13 +- ext/oci8/tests/error_parse.phpt | 16 +- ext/oci8/tests/exec_fetch.phpt | 4 +- ext/oci8/tests/fetch.phpt | 24 +- ext/oci8/tests/fetch_all.phpt | 18 +- ext/oci8/tests/fetch_all1.phpt | 94 +++ ext/oci8/tests/fetch_all2.phpt | 5 +- ext/oci8/tests/fetch_all3.phpt | 27 +- ext/oci8/tests/fetch_all4.phpt | 23 +- ext/oci8/tests/fetch_all5.phpt | 21 +- ext/oci8/tests/fetch_array.phpt | 70 +- ext/oci8/tests/fetch_assoc.phpt | 59 +- ext/oci8/tests/fetch_into.phpt | 25 +- ext/oci8/tests/fetch_into1.phpt | 5 +- ext/oci8/tests/fetch_into2.phpt | 5 +- ext/oci8/tests/fetch_object.phpt | 52 +- ext/oci8/tests/fetch_object_1.phpt | 123 +++ ext/oci8/tests/fetch_object_2.phpt | 82 +- ext/oci8/tests/fetch_row.phpt | 23 +- ext/oci8/tests/field_funcs.phpt | 5 +- ext/oci8/tests/field_funcs0.phpt | 108 +++ ext/oci8/tests/field_funcs1.phpt | 39 +- ext/oci8/tests/field_funcs3.phpt | 99 +++ ext/oci8/tests/field_funcs_old.phpt | 5 +- ext/oci8/tests/lob_001.phpt | Bin 1305 -> 2152 bytes ext/oci8/tests/lob_002.phpt | 43 +- ext/oci8/tests/lob_003.phpt | Bin 1628 -> 1698 bytes ext/oci8/tests/lob_004.phpt | 5 +- ext/oci8/tests/lob_005.phpt | 5 +- ext/oci8/tests/lob_006.phpt | Bin 1694 -> 1766 bytes ext/oci8/tests/lob_007.phpt | 5 +- ext/oci8/tests/lob_008.phpt | 5 +- ext/oci8/tests/lob_009.phpt | 5 +- ext/oci8/tests/lob_010.phpt | 5 +- ext/oci8/tests/lob_011.phpt | 5 +- ext/oci8/tests/lob_012.phpt | 5 +- ext/oci8/tests/lob_013.phpt | 5 +- ext/oci8/tests/lob_014.phpt | 5 +- ext/oci8/tests/lob_015.phpt | 7 +- ext/oci8/tests/lob_016.phpt | 5 +- ext/oci8/tests/lob_017.phpt | 5 +- ext/oci8/tests/lob_018.phpt | 70 +- ext/oci8/tests/lob_019.phpt | Bin 1548 -> 1618 bytes ext/oci8/tests/lob_020.phpt | Bin 3076 -> 3146 bytes ext/oci8/tests/lob_021.phpt | 5 +- ext/oci8/tests/lob_022.phpt | 5 +- ext/oci8/tests/lob_023.phpt | 5 +- ext/oci8/tests/lob_024.phpt | 5 +- ext/oci8/tests/lob_025.phpt | 5 +- ext/oci8/tests/lob_026.phpt | 5 +- ext/oci8/tests/lob_027.phpt | 5 +- ext/oci8/tests/lob_028.phpt | 5 +- ext/oci8/tests/lob_029.phpt | 15 +- ext/oci8/tests/lob_030.phpt | 5 +- ext/oci8/tests/lob_031.phpt | 5 +- ext/oci8/tests/lob_032.phpt | 5 +- ext/oci8/tests/lob_033.phpt | 5 +- ext/oci8/tests/lob_034.phpt | 5 +- ext/oci8/tests/lob_035.phpt | 5 +- ext/oci8/tests/lob_036.phpt | 5 +- ext/oci8/tests/lob_037.phpt | 5 +- ext/oci8/tests/lob_038.phpt | 5 +- ext/oci8/tests/lob_039.phpt | 5 +- ext/oci8/tests/lob_040.phpt | 5 +- ext/oci8/tests/lob_041.phpt | 17 +- ext/oci8/tests/lob_042.phpt | 5 +- ext/oci8/tests/lob_043.phpt | 26 +- ext/oci8/tests/lob_044.phpt | 73 ++ ext/oci8/tests/lob_aliases.phpt | 5 +- ext/oci8/tests/lob_null.phpt | 5 +- ext/oci8/tests/lob_temp.phpt | 5 +- ext/oci8/tests/lob_temp1.phpt | 5 +- ext/oci8/tests/null_byte_2.phpt | 27 +- ext/oci8/tests/null_byte_3.phpt | 42 + ext/oci8/tests/num.phpt | 23 +- ext/oci8/tests/oci_execute_segfault.phpt | 5 +- ext/oci8/tests/password.phpt | 41 +- ext/oci8/tests/password_2.phpt | 40 +- ext/oci8/tests/password_new.phpt | 17 +- ext/oci8/tests/password_old.phpt | 19 +- ext/oci8/tests/pecl_bug10194.phpt | 5 +- ext/oci8/tests/pecl_bug10194_blob.phpt | 20 +- ext/oci8/tests/pecl_bug10194_blob_64.phpt | 3 +- ext/oci8/tests/pecl_bug16035.phpt | 5 +- ext/oci8/tests/pecl_bug16842.phpt | 29 +- ext/oci8/tests/pecl_bug8816.phpt | 5 +- ext/oci8/tests/prefetch.phpt | 23 +- ext/oci8/tests/prefetch_old.phpt | 23 +- ext/oci8/tests/refcur_prefetch_1.phpt | 143 ++-- ext/oci8/tests/refcur_prefetch_2.phpt | 171 +--- ext/oci8/tests/refcur_prefetch_3.phpt | 40 +- ext/oci8/tests/refcur_prefetch_4.phpt | 176 ++++ ext/oci8/tests/select_null.phpt | 4 +- ext/oci8/tests/serverversion.phpt | 4 +- ext/oci8/tests/skipif.inc | 18 +- ext/oci8/tests/statement_cache.phpt | 11 +- ext/oci8/tests/xmltype_01.phpt | 26 +- ext/oci8/tests/xmltype_02.phpt | 113 ++- 266 files changed, 5940 insertions(+), 2107 deletions(-) create mode 100644 ext/oci8/tests/bind_misccoltypes.phpt create mode 100644 ext/oci8/tests/bind_misccoltypes_errs.phpt create mode 100644 ext/oci8/tests/bind_number.phpt create mode 100644 ext/oci8/tests/bind_query.phpt create mode 100644 ext/oci8/tests/bind_sqltafc.phpt create mode 100644 ext/oci8/tests/bind_sqltchr_1.phpt create mode 100644 ext/oci8/tests/bind_sqltchr_2.phpt create mode 100644 ext/oci8/tests/bind_sqltint.phpt create mode 100644 ext/oci8/tests/bind_sqltnum.phpt create mode 100644 ext/oci8/tests/bind_unsupported_1.phpt create mode 100644 ext/oci8/tests/bind_unsupported_2.phpt create mode 100644 ext/oci8/tests/bind_unsupported_3.phpt create mode 100644 ext/oci8/tests/bug47281_tt.phpt create mode 100644 ext/oci8/tests/bug51291_1.phpt create mode 100644 ext/oci8/tests/bug51291_2.phpt create mode 100644 ext/oci8/tests/dbmsoutput.phpt create mode 100644 ext/oci8/tests/default_prefetch0.phpt create mode 100644 ext/oci8/tests/define0.phpt create mode 100644 ext/oci8/tests/define6.phpt create mode 100644 ext/oci8/tests/dupcolnames.phpt create mode 100644 ext/oci8/tests/fetch_all1.phpt create mode 100644 ext/oci8/tests/fetch_object_1.phpt create mode 100644 ext/oci8/tests/field_funcs0.phpt create mode 100644 ext/oci8/tests/field_funcs3.phpt create mode 100644 ext/oci8/tests/lob_044.phpt create mode 100644 ext/oci8/tests/null_byte_3.phpt create mode 100644 ext/oci8/tests/refcur_prefetch_4.phpt diff --git a/ext/oci8/tests/array_bind_001.phpt b/ext/oci8/tests/array_bind_001.phpt index 1310325ad44b7..6a3746c2d53cf 100644 --- a/ext/oci8/tests/array_bind_001.phpt +++ b/ext/oci8/tests/array_bind_001.phpt @@ -61,7 +61,7 @@ echo "Done\n"; --EXPECTF-- Warning: oci_bind_array_by_name(): OCI-21560: argument 3 is null, invalid, or out of range in %s on line %d -Warning: oci_execute(): ORA-01008: not all variables bound in %s on line %d +Warning: oci_execute(): ORA-%r(01008|57000)%r: %s in %s on line %d array(1) { [0]=> string(0) "" diff --git a/ext/oci8/tests/array_bind_002.phpt b/ext/oci8/tests/array_bind_002.phpt index 4c76df42f92d5..82b57dc731133 100644 --- a/ext/oci8/tests/array_bind_002.phpt +++ b/ext/oci8/tests/array_bind_002.phpt @@ -61,7 +61,7 @@ echo "Done\n"; --EXPECTF-- Warning: oci_bind_array_by_name(): Maximum array length must be greater than zero in %s on line %d -Warning: oci_execute(): ORA-01008: not all variables bound in %s on line %d +Warning: oci_execute(): ORA-%r(01008|57000)%r: %s in %s on line %d array(5) { [0]=> string(9) "06-DEC-05" diff --git a/ext/oci8/tests/array_bind_003.phpt b/ext/oci8/tests/array_bind_003.phpt index 497e46e49600c..94bce02e31dee 100644 --- a/ext/oci8/tests/array_bind_003.phpt +++ b/ext/oci8/tests/array_bind_003.phpt @@ -1,7 +1,10 @@ --TEST-- oci_bind_array_by_name() and invalid values 3 --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- int(1) diff --git a/ext/oci8/tests/array_bind_008.phpt b/ext/oci8/tests/array_bind_008.phpt index c44304c11cf95..df2c35ccb298d 100644 --- a/ext/oci8/tests/array_bind_008.phpt +++ b/ext/oci8/tests/array_bind_008.phpt @@ -1,7 +1,10 @@ --TEST-- oci_bind_array_by_name() and invalid values 8 --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- --EXPECTF-- Warning: oci_execute(): ORA-06550: line %d, column %d: -PLS-00418: array bind type must match PL/SQL table row type -ORA-06550: line %d, column %d: -PL/SQL: Statement ignored in %s on line %d +PLS-00418: %s +ORA-06550: %s +PL/SQL: %s array(5) { [0]=> string(1) "1" diff --git a/ext/oci8/tests/array_bind_010.phpt b/ext/oci8/tests/array_bind_010.phpt index a77ed913ea678..ede82c97fce9b 100644 --- a/ext/oci8/tests/array_bind_010.phpt +++ b/ext/oci8/tests/array_bind_010.phpt @@ -7,7 +7,7 @@ oci_bind_array_by_name() and invalid values 8 require dirname(__FILE__).'/connect.inc'; -$statement = oci_parse($c, 'SELECT user FROM v$session'); +$statement = oci_parse($c, 'SELECT user FROM all_objects'); $array = Array(1,2,3,4,5); diff --git a/ext/oci8/tests/array_bind_011.phpt b/ext/oci8/tests/array_bind_011.phpt index e8e00a8091aa4..9f43d1ac9c341 100644 --- a/ext/oci8/tests/array_bind_011.phpt +++ b/ext/oci8/tests/array_bind_011.phpt @@ -61,7 +61,7 @@ echo "Done\n"; --EXPECTF-- Warning: oci_bind_array_by_name(): You must provide max length value for empty arrays in %s on line %d -Warning: oci_execute(): ORA-01008: not all variables bound in %s on line %d +Warning: oci_execute(): ORA-%r(01008|57000)%r: %s in %s on line %d array(0) { } Done diff --git a/ext/oci8/tests/array_bind_012.phpt b/ext/oci8/tests/array_bind_012.phpt index 2208f0b3b94ee..38e1701a4b86c 100644 --- a/ext/oci8/tests/array_bind_012.phpt +++ b/ext/oci8/tests/array_bind_012.phpt @@ -7,7 +7,7 @@ oci_bind_array_by_name(), SQLT_CHR, default max_length and empty array require dirname(__FILE__).'/connect.inc'; -$statement = oci_parse($c, 'SELECT user FROM v$session'); +$statement = oci_parse($c, 'SELECT user FROM all_objects'); $array = array(); diff --git a/ext/oci8/tests/array_bind_014.phpt b/ext/oci8/tests/array_bind_014.phpt index bd9fdf1335657..9ab023635944d 100644 --- a/ext/oci8/tests/array_bind_014.phpt +++ b/ext/oci8/tests/array_bind_014.phpt @@ -1,7 +1,10 @@ --TEST-- oci_bind_array_by_name() and NUMBERs --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- @@ -33,10 +25,7 @@ $stmtarray = array( "insert into bind_char_tab values (3, NULL, 'abc ')" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -206,12 +195,7 @@ $stmtarray = array( "drop table bind_char_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_1_11gR1.phpt b/ext/oci8/tests/bind_char_1_11gR1.phpt index 60b7142ff12cc..55973a61b681c 100644 --- a/ext/oci8/tests/bind_char_1_11gR1.phpt +++ b/ext/oci8/tests/bind_char_1_11gR1.phpt @@ -27,10 +27,7 @@ $stmtarray = array( "insert into bind_char_tab values (3, NULL, 'abc ')" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -200,12 +197,7 @@ $stmtarray = array( "drop table bind_char_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_2.phpt b/ext/oci8/tests/bind_char_2.phpt index fa2e547dbe300..da34230dc77e4 100644 --- a/ext/oci8/tests/bind_char_2.phpt +++ b/ext/oci8/tests/bind_char_2.phpt @@ -4,18 +4,10 @@ SELECT oci_bind_by_name with SQLT_AFC aka CHAR and dates 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- @@ -32,10 +24,7 @@ $stmtarray = array( "insert into bind_char_tab values (1, '2008-04-20')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -95,12 +84,7 @@ $stmtarray = array( "drop table bind_char_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_2_11gR1.phpt b/ext/oci8/tests/bind_char_2_11gR1.phpt index 68a872fc46d8f..357a716e6dc2b 100644 --- a/ext/oci8/tests/bind_char_2_11gR1.phpt +++ b/ext/oci8/tests/bind_char_2_11gR1.phpt @@ -24,10 +24,7 @@ $stmtarray = array( "insert into bind_char_tab values (1, '2008-04-20')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -87,12 +84,7 @@ $stmtarray = array( "drop table bind_char_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_3.phpt b/ext/oci8/tests/bind_char_3.phpt index 052981aceae21..8ae5096273a4d 100644 --- a/ext/oci8/tests/bind_char_3.phpt +++ b/ext/oci8/tests/bind_char_3.phpt @@ -4,18 +4,10 @@ PL/SQL oci_bind_by_name with SQLT_AFC aka CHAR to CHAR parameter 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- @@ -28,11 +20,8 @@ require(dirname(__FILE__).'/connect.inc'); $stmtarray = array( "create or replace function bind_char_3_fn(p1 char) return char as begin return p1; end;", ); - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} + +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -243,18 +232,11 @@ function do_e($s) // Cleanup -//require(dirname(__FILE__).'/drop_table.inc'); - $stmtarray = array( "drop function bind_char_3_fn" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_3_11gR1.phpt b/ext/oci8/tests/bind_char_3_11gR1.phpt index aaa5371195da8..1e7da47edcc09 100644 --- a/ext/oci8/tests/bind_char_3_11gR1.phpt +++ b/ext/oci8/tests/bind_char_3_11gR1.phpt @@ -21,10 +21,7 @@ $stmtarray = array( "create or replace function bind_char_3_fn(p1 char) return char as begin return p1; end;", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -235,18 +232,11 @@ function do_e($s) // Cleanup -//require(dirname(__FILE__).'/drop_table.inc'); - $stmtarray = array( "drop function bind_char_3_fn" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_4.phpt b/ext/oci8/tests/bind_char_4.phpt index fd38d902cc84b..30e4c3be608e5 100644 --- a/ext/oci8/tests/bind_char_4.phpt +++ b/ext/oci8/tests/bind_char_4.phpt @@ -4,18 +4,10 @@ PL/SQL oci_bind_by_name with SQLT_AFC aka CHAR to VARCHAR2 parameter 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- @@ -31,10 +23,7 @@ $stmtarray = array( "create or replace function bind_char_3_fn(p1 varchar2) return varchar2 as begin return p1; end;", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -245,18 +234,11 @@ function do_e($s) // Cleanup -//require(dirname(__FILE__).'/drop_table.inc'); - $stmtarray = array( "drop function bind_char_3_fn" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_char_4_11gR1.phpt b/ext/oci8/tests/bind_char_4_11gR1.phpt index c4f7968e14963..87b7daba88896 100644 --- a/ext/oci8/tests/bind_char_4_11gR1.phpt +++ b/ext/oci8/tests/bind_char_4_11gR1.phpt @@ -23,10 +23,7 @@ $stmtarray = array( "create or replace function bind_char_3_fn(p1 varchar2) return varchar2 as begin return p1; end;", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -237,18 +234,11 @@ function do_e($s) // Cleanup -//require(dirname(__FILE__).'/drop_table.inc'); - $stmtarray = array( "drop function bind_char_3_fn" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bind_long.phpt b/ext/oci8/tests/bind_long.phpt index ba6bd4d044375..40c579992d690 100644 --- a/ext/oci8/tests/bind_long.phpt +++ b/ext/oci8/tests/bind_long.phpt @@ -1,7 +1,10 @@ --TEST-- bind LONG field --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- --EXPECT-- +Test 1 string(32) "5c7c34abf7ea51936785062dbfcaeddc" int(394) +Test 2 - test multi chunk fetch +string(32) "ee2e98b977341cfb8e037066e5fcb909" +int(236400) Done diff --git a/ext/oci8/tests/bind_long_raw.phpt b/ext/oci8/tests/bind_long_raw.phpt index 2a9962eace9c1..e48bbd33eebd3 100644 --- a/ext/oci8/tests/bind_long_raw.phpt +++ b/ext/oci8/tests/bind_long_raw.phpt @@ -1,7 +1,10 @@ --TEST-- bind LONG RAW field --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +if (preg_match('/^1[012]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); +} +?> +--FILE-- + +===DONE=== + +--EXPECTF-- +TEST86 insert all ORATYPE values + +TEST87 SELECT all values using DEFINEs +ID is 86 +CHAR_T is C +CHAR_T10 is char10 +VARCHAR2_T10 is varchar210 +NUMBER_T is -123.456 +NUMBER_T92 is 789.35 +NUMBER_T6 is 123456 +DATE_T is 29-MAR-10 +TIMESTAMP_T is 29-MAR-10 01.09.15.000000 PM +FLOAT_T is 12345678901234567890123456789012345679 +BINARY_FLOAT_T is 1.23456784E+037 +BINARY_DOUBLE_T is 1.2345678901234568E+037 +DECIMAL_T is 86 +INTEGER_T is 86 +NCHAR_T is nchar10 +NVARCHAR2_T10 is nvarchar2x +VARCHAR_T10 is varchar + +TEST52 insert numbers +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(1) "3" + } +} + +TEST53 insert numbers +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(4) "8.67" + } +} + +TEST54 insert numbers +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(4) "4.67" + } +} + +TEST55 insert numbers +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(4) "7.67" + } +} + +TEST56 insert numbers +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(5) "-5.67" + } +} + +TEST58 insert a VARCHAR2 +array(1) { + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + string(4) "Hood" + } +} + +TEST59 insert a VARCHAR2 +array(1) { + ["CHAR_T10"]=> + array(1) { + [0]=> + string(10) "Hood " + } +} + +TEST60 insert a date +array(1) { + ["DATE_T"]=> + array(1) { + [0]=> + string(9) "09-APR-10" + } +} +===DONE=== diff --git a/ext/oci8/tests/bind_misccoltypes_errs.phpt b/ext/oci8/tests/bind_misccoltypes_errs.phpt new file mode 100644 index 0000000000000..20401fb8ea5e1 --- /dev/null +++ b/ext/oci8/tests/bind_misccoltypes_errs.phpt @@ -0,0 +1,169 @@ +--TEST-- +Bind miscellaneous column types and generating errors +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 insert numbers + +Warning: oci_execute(): ORA-01438: %s in %sbind_misccoltypes_errs.php on line %d +array(1) { + ["NUMBER_T6"]=> + array(0) { + } +} + +Test 2 insert numbers + +Warning: oci_execute(): ORA-01722: %s in %sbind_misccoltypes_errs.php on line %d +array(1) { + ["NUMBER_T6"]=> + array(0) { + } +} + +Test 3 - too long CHAR + +Warning: oci_execute(): ORA-12899: %r(%s "%s"."BIND_MISCCOLTYPES_ERRS_TAB"."CHAR_T" \(%s: 2, %s: 1\)|String data right truncation)%r in %sbind_misccoltypes_errs.php on line %d + +Test 4 - too long VARCHAR2 + +Warning: oci_execute(): ORA-12899: %r(%s "%s"."BIND_MISCCOLTYPES_ERRS_TAB"."VARCHAR2_T10" \(%s: 11, %s: 10\)|%s data right truncation)%r in %sbind_misccoltypes_errs.php on line %d + +Test 5 - invalid number + +Warning: oci_execute(): ORA-01722: %s in %sbind_misccoltypes_errs.php on line %d + +Test 6 - insert a VARCHAR2 with SQLT_BIN + +Warning: oci_execute(): ORA-12899: %r(%s "%s"."BIND_MISCCOLTYPES_ERRS_TAB"."VARCHAR2_T10" \(%s: 12, %s: 10\)|String data right truncation)%r in %sbind_misccoltypes_errs.php on line %d +array(1) { + ["VARCHAR2_T10"]=> + array(0) { + } +} + +Test 7 - insert a VARCHAR2 with SQLT_LBI + +Warning: oci_execute(): ORA-12899: %r(%s "%s"."BIND_MISCCOLTYPES_ERRS_TAB"."VARCHAR2_T10" \(%s: 12, %s: 10\)|String data right truncation)%r in %sbind_misccoltypes_errs.php on line %d +array(1) { + ["VARCHAR2_T10"]=> + array(0) { + } +} +===DONE=== diff --git a/ext/oci8/tests/bind_number.phpt b/ext/oci8/tests/bind_number.phpt new file mode 100644 index 0000000000000..6412b5f82e784 --- /dev/null +++ b/ext/oci8/tests/bind_number.phpt @@ -0,0 +1,220 @@ +--TEST-- +Bind with NUMBER column variants +--SKIPIF-- + +--INI-- +precision = 14 +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - invalid number + +Warning: oci_execute(): ORA-01722: %s in %sbind_number.php on line %d +array(1) { + ["NUMBER_T6"]=> + array(0) { + } +} + +TEST66 insert a float +array(1) { + ["FLOAT_T"]=> + array(1) { + [0]=> + string(7) "123.456" + } +} + +TEST67 insert a binary float +array(1) { + ["BINARY_FLOAT_T"]=> + array(1) { + [0]=> + string(%r15|8%r) "%r(5.67455994E\+002|567.4560)%r" + } +} + +TEST69 insert a binary double +array(1) { + ["BINARY_DOUBLE_T"]=> + array(1) { + [0]=> + string(%r23|16%r) "%r(5.6745600000000002E\+002|567.456000000000)%r" + } +} + +TEST71 insert a decimal +array(1) { + ["DECIMAL_T"]=> + array(1) { + [0]=> + string(3) "124" + } +} + +TEST72 insert a decimal +array(1) { + ["DECIMAL_T"]=> + array(1) { + [0]=> + string(1) "0" + } +} + +TEST73 insert a double +array(1) { + ["BINARY_DOUBLE_T"]=> + array(1) { + [0]=> + string(%r12|16%r) "%r(4.83589E\+002|483.589000000000)%r" + } +} + +TEST75 insert a INTEGER +array(1) { + ["INTEGER_T"]=> + array(1) { + [0]=> + string(3) "589" + } +} + +TEST76 insert a INTEGER +array(1) { + ["INTEGER_T"]=> + array(1) { + [0]=> + string(2) "42" + } +} +===DONE=== + + diff --git a/ext/oci8/tests/bind_query.phpt b/ext/oci8/tests/bind_query.phpt new file mode 100644 index 0000000000000..e4edc93299cfe --- /dev/null +++ b/ext/oci8/tests/bind_query.phpt @@ -0,0 +1,78 @@ +--TEST-- +Bind with various WHERE conditions +--SKIPIF-- + +--FILE-- + :v order by ename'); +oci_bind_by_name( $s, ":v", $v); +oci_define_by_name($s, "ENAME", $ename, 20); +oci_execute($s); +while (oci_fetch($s)) { + var_dump($ename); +} + + +echo "Test 3\n"; + +$s = oci_parse($c, 'select ename from bind_query_tab where sal > :v order by ename'); +oci_bind_by_name( $s, ":v", $v); +$v = 2000; +oci_define_by_name($s, "ENAME", $ename, 20); +oci_execute($s); +while (oci_fetch($s)) { + var_dump($ename); +} + + +// Clean up + +$stmtarray = array( + "drop table bind_query_tab" +); + +oci8_test_sql_execute($c, $stmtarray); + +?> +===DONE=== + +--EXPECTF-- +Test 1 +array(1) { + [0]=> + string(6) "MILLER" +} +Test 2 +string(4) "FORD" +string(6) "MILLER" +Test 3 +string(4) "FORD" +===DONE=== diff --git a/ext/oci8/tests/bind_raw.phpt b/ext/oci8/tests/bind_raw.phpt index c9087e552b62e..c2e8e08768a50 100644 --- a/ext/oci8/tests/bind_raw.phpt +++ b/ext/oci8/tests/bind_raw.phpt @@ -1,7 +1,10 @@ --TEST-- bind RAW field --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 0 - base table creation without binds +array(5) { + ["ID"]=> + array(1) { + [0]=> + string(1) "0" + } + ["CHAR_T"]=> + array(1) { + [0]=> + string(1) "a" + } + ["CHAR_T10"]=> + array(1) { + [0]=> + string(10) "abcd " + } + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + string(6) "efghij" + } + ["NUMBER_T"]=> + array(1) { + [0]=> + string(3) "1.1" + } +} + +Test 1 - successful insert +array(5) { + ["ID"]=> + array(1) { + [0]=> + string(1) "1" + } + ["CHAR_T"]=> + array(1) { + [0]=> + string(1) "H" + } + ["CHAR_T10"]=> + array(1) { + [0]=> + string(10) "AAAAAAAAAA" + } + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + string(10) "BBBBBBBBBB" + } + ["NUMBER_T"]=> + array(1) { + [0]=> + string(6) "123.45" + } +} + +Test 2 - Empty Strings +array(5) { + ["ID"]=> + array(1) { + [0]=> + string(1) "5" + } + ["CHAR_T"]=> + array(1) { + [0]=> + NULL + } + ["CHAR_T10"]=> + array(1) { + [0]=> + NULL + } + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + NULL + } + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} + +Test 3 - NULLs +array(5) { + ["ID"]=> + array(1) { + [0]=> + string(1) "6" + } + ["CHAR_T"]=> + array(1) { + [0]=> + NULL + } + ["CHAR_T10"]=> + array(1) { + [0]=> + NULL + } + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + NULL + } + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} +===DONE=== diff --git a/ext/oci8/tests/bind_sqltchr_1.phpt b/ext/oci8/tests/bind_sqltchr_1.phpt new file mode 100644 index 0000000000000..aabf9bda5c587 --- /dev/null +++ b/ext/oci8/tests/bind_sqltchr_1.phpt @@ -0,0 +1,228 @@ +--TEST-- +Bind with SQLT_CHR +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +TEST241 bind SQLT_CHR +array(1) { + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + string(7) "Hood241" + } +} + +TEST242 insert numbers SQLT_CHR +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(2) "42" + } +} + +TEST243 insert numbers, SQLT_CHR +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(5) "42.69" + } +} + +TEST244 insert numbers with SQLT_CHR +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(1) "0" + } +} + +TEST245 insert numbers with SQLT_CHR +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(3) "-23" + } +} + +TEST246 insert numbers +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(3) "-23" + } +} + +TEST247 insert numbers with SQLT_CHR +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(2) "23" + } +} + +TEST248 insert numbers with SQLT_CHR +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(6) "123.56" + } +} + +TEST249 insert numbers with SQLT_CHR +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(6) "123.56" + } +} + +TEST250 insert numbers with SQLT_CHR +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + NULL + } +} +===DONE=== diff --git a/ext/oci8/tests/bind_sqltchr_2.phpt b/ext/oci8/tests/bind_sqltchr_2.phpt new file mode 100644 index 0000000000000..47d08d2bc37a9 --- /dev/null +++ b/ext/oci8/tests/bind_sqltchr_2.phpt @@ -0,0 +1,50 @@ +--TEST-- +PL/SQL bind with SQLT_CHR +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - PL/SQL IN and OUT variables +string(22) "Cat got your keyboard?" +string(22) "CAT GOT YOUR KEYBOARD?" +===DONE=== diff --git a/ext/oci8/tests/bind_sqltint.phpt b/ext/oci8/tests/bind_sqltint.phpt new file mode 100644 index 0000000000000..f01791d3b1641 --- /dev/null +++ b/ext/oci8/tests/bind_sqltint.phpt @@ -0,0 +1,227 @@ +--TEST-- +Bind with SQLT_INT +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +TEST141 wrong bind type SQLT_INT +array(1) { + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + string(1) "0" + } +} + +TEST142 insert numbers SQLT_INT +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(2) "42" + } +} + +TEST143 insert numbers, SQLT_INT +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(2) "42" + } +} + +TEST144 insert numbers with SQLT_INT +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(1) "0" + } +} + +TEST145 insert numbers with SQLT_INT +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(3) "-23" + } +} + +TEST146 insert numbers +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(3) "-23" + } +} + +TEST147 insert numbers with SQLT_INT +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(2) "23" + } +} + +TEST148 insert numbers with SQLT_INT +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(3) "123" + } +} + +TEST149 insert numbers with SQLT_INT +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(3) "123" + } +} + +TEST150 insert numbers with SQLT_INT +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(1) "0" + } +} +===DONE=== diff --git a/ext/oci8/tests/bind_sqltnum.phpt b/ext/oci8/tests/bind_sqltnum.phpt new file mode 100644 index 0000000000000..d3828b73eea95 --- /dev/null +++ b/ext/oci8/tests/bind_sqltnum.phpt @@ -0,0 +1,278 @@ +--TEST-- +Bind with SQLT_NUM +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - baseline test +array(2) { + ["ID"]=> + array(1) { + [0]=> + string(3) "100" + } + ["VARCHAR2_T10"]=> + array(1) { + [0]=> + string(4) "Hood" + } +} +Test 2 - SQLT_NUM to a VARCHAR2 column + +Warning: oci_execute(): ORA-12899: %s (%s: 40, %s: 10) in %sbind_sqltnum.php on line %d +string(%d) "ORA-12899: %s" + +TEST41 wrong bind type SQLT_NUM + +Warning: oci_execute(): ORA-12899: %s "%s"."BIND_SQLTNUM_TAB"."VARCHAR2_T10" (%s: 40, %s: 10) in %sbind_sqltnum.php on line %d + +TEST42 insert numbers SQLT_NUM +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} + +TEST43 insert numbers SQLT_NUM +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} + +TEST44 +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + string(127) "-000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + } +} + +TEST45 +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} + +TEST46 insert numbers +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} + +TEST47 +array(1) { + ["NUMBER_T"]=> + array(1) { + [0]=> + NULL + } +} + +TEST48 +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(1) "0" + } +} + +TEST49 +array(1) { + ["NUMBER_T92"]=> + array(1) { + [0]=> + string(1) "0" + } +} + +TEST50 + +Warning: oci_execute(): ORA-01438: %s in %sbind_sqltnum.php on line %d +array(1) { + ["NUMBER_T92"]=> + array(0) { + } +} +===DONE=== diff --git a/ext/oci8/tests/bind_unsupported_1.phpt b/ext/oci8/tests/bind_unsupported_1.phpt new file mode 100644 index 0000000000000..544b446788e5f --- /dev/null +++ b/ext/oci8/tests/bind_unsupported_1.phpt @@ -0,0 +1,58 @@ +--TEST-- +Bind with various unsupported bind types +--SKIPIF-- + +--FILE-- + SQLT_AVC, + "SQLT_STR" => SQLT_STR, + "SQLT_VCS" => SQLT_VCS, + "SQLT_AVC" => SQLT_AVC, + "SQLT_STR" => SQLT_STR, + "SQLT_LVC" => SQLT_LVC, + "SQLT_FLT" => SQLT_FLT, + "SQLT_UIN" => SQLT_UIN, + "SQLT_ODT" => SQLT_ODT, +); + +foreach ($types as $t => $v) { + + echo "Test - $t\n"; + + $s = oci_parse($c, "select * from dual where dummy = :c1"); + $c1 = "Doug"; + oci_bind_by_name($s, ":c1", $c1, -1, $v); +} + +?> +===DONE=== + +--EXPECTF-- +Test - SQLT_AVC + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 97 in %sbind_unsupported_1.php on line %d +Test - SQLT_STR + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 5 in %sbind_unsupported_1.php on line %d +Test - SQLT_VCS + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 9 in %sbind_unsupported_1.php on line %d +Test - SQLT_LVC + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 94 in %sbind_unsupported_1.php on line %d +Test - SQLT_FLT + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 4 in %sbind_unsupported_1.php on line %d +Test - SQLT_UIN + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 68 in %sbind_unsupported_1.php on line %d +Test - SQLT_ODT + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 156 in %sbind_unsupported_1.php on line %d +===DONE=== diff --git a/ext/oci8/tests/bind_unsupported_2.phpt b/ext/oci8/tests/bind_unsupported_2.phpt new file mode 100644 index 0000000000000..d3e5375df6c4a --- /dev/null +++ b/ext/oci8/tests/bind_unsupported_2.phpt @@ -0,0 +1,39 @@ +--TEST-- +Bind with various unsupported 10g+ bind types +--SKIPIF-- + +--FILE-- + SQLT_BDOUBLE, + "SQLT_BFLOAT" => SQLT_BFLOAT, +); + +foreach ($types as $t => $v) { + + echo "Test - $t\n"; + + $s = oci_parse($c, "select * from dual where dummy = :c1"); + $c1 = "Doug"; + oci_bind_by_name($s, ":c1", $c1, -1, $v); +} + +?> +===DONE=== + +--EXPECTF-- +Test - SQLT_BDOUBLE + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 22 in %sbind_unsupported_2.php on line %d +Test - SQLT_BFLOAT + +Warning: oci_bind_by_name(): Unknown or unsupported datatype given: 21 in %sbind_unsupported_2.php on line %d +===DONE=== diff --git a/ext/oci8/tests/bind_unsupported_3.phpt b/ext/oci8/tests/bind_unsupported_3.phpt new file mode 100644 index 0000000000000..5c9dec3729538 --- /dev/null +++ b/ext/oci8/tests/bind_unsupported_3.phpt @@ -0,0 +1,45 @@ +--TEST-- +Bind with various bind types not supported by TimesTen +--SKIPIF-- + false, 'timesten' => true); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- + SQLT_CLOB, + "SQLT_BLOB" => SQLT_BLOB, + "OCI_B_CLOB" => OCI_B_CLOB, + "OCI_B_BLOB" => OCI_B_BLOB, +); + +foreach ($types as $t => $v) { + + echo "Test - $t\n"; + + $s = oci_parse($c, "select * from dual where dummy = :c1"); + $c1 = "Doug"; + oci_bind_by_name($s, ":c1", $c1, -1, $v); +} + +?> +===DONE=== + +--EXPECTF-- +Test - SQLT_CLOB + +Warning: oci_bind_by_name(): Unable to find descriptor property in %sbind_unsupported_3.php on line %d +Test - SQLT_BLOB + +Warning: oci_bind_by_name(): Unable to find descriptor property in %sbind_unsupported_3.php on line %d +Test - OCI_B_CLOB + +Warning: oci_bind_by_name(): Unable to find descriptor property in %sbind_unsupported_3.php on line %d +Test - OCI_B_BLOB + +Warning: oci_bind_by_name(): Unable to find descriptor property in %sbind_unsupported_3.php on line %d +===DONE=== diff --git a/ext/oci8/tests/bug26133.phpt b/ext/oci8/tests/bug26133.phpt index 2463e70c767aa..59f8a17f38d56 100644 --- a/ext/oci8/tests/bug26133.phpt +++ b/ext/oci8/tests/bug26133.phpt @@ -14,27 +14,11 @@ $stmtarray = array( "create table bug26133_tab (id number, value number)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test -$ora_sql = "INSERT INTO bug26133_tab (id, value) VALUES ('1','1') RETURNING ROWID INTO :v_rowid "; +$ora_sql = "INSERT INTO bug26133_tab (id, value) VALUES (1,'1') RETURNING ROWID INTO :v_rowid "; $statement = OCIParse($c,$ora_sql); $rowid = OCINewDescriptor($c,OCI_D_ROWID); @@ -51,10 +35,7 @@ $stmtarray = array( "drop table bug26133_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/bug27303_1.phpt b/ext/oci8/tests/bug27303_1.phpt index 6d491966a7ab9..c4550244aa1a2 100644 --- a/ext/oci8/tests/bug27303_1.phpt +++ b/ext/oci8/tests/bug27303_1.phpt @@ -4,35 +4,25 @@ Bug #27303 (OCIBindByName binds numeric PHP values as characters) 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- diff --git a/ext/oci8/tests/bug27303_1_11gR1.phpt b/ext/oci8/tests/bug27303_1_11gR1.phpt index fe5c17c3ee43d..20097613f4a4e 100644 --- a/ext/oci8/tests/bug27303_1_11gR1.phpt +++ b/ext/oci8/tests/bug27303_1_11gR1.phpt @@ -13,18 +13,16 @@ if ($sv !== 1) { --FILE-- diff --git a/ext/oci8/tests/bug27303_2.phpt b/ext/oci8/tests/bug27303_2.phpt index 3d0c0877036b9..d7df23ba24ab9 100644 --- a/ext/oci8/tests/bug27303_2.phpt +++ b/ext/oci8/tests/bug27303_2.phpt @@ -4,18 +4,10 @@ Bug #27303 (OCIBindByName binds numeric PHP values as characters) 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- @@ -23,16 +15,14 @@ if ($sv !== 1) { require dirname(__FILE__).'/connect.inc'; -$create_st = array(); -$create_st[] = "drop sequence myseq"; -$create_st[] = "drop table mytab"; -$create_st[] = "create sequence myseq"; -$create_st[] = "create table mytab (mydata varchar2(20), seqcol number)"; +$stmtarray = array( + "drop sequence myseq", + "drop table mytab", + "create sequence myseq", + "create table mytab (mydata varchar2(20), seqcol number)" +); -foreach ($create_st as $statement) { - $stmt = oci_parse($c, $statement); - oci_execute($stmt); -} +oci8_test_sql_execute($c, $stmtarray); define('MYLIMIT', 200); define('INITMYBV', 11); @@ -54,14 +44,12 @@ for ($i = 1; $i < MYLIMIT; $i++) { OCICommit($c); -$drop_st = array(); -$drop_st[] = "drop sequence myseq"; -$drop_st[] = "drop table mytab"; +$stmtarray = array( + "drop sequence myseq", + "drop table mytab" +); -foreach ($create_st as $statement) { - $stmt = oci_parse($c, $statement); - oci_execute($stmt); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/bug27303_2_11gR1.phpt b/ext/oci8/tests/bug27303_2_11gR1.phpt index e1daef0537e8c..c2b5c433c4501 100644 --- a/ext/oci8/tests/bug27303_2_11gR1.phpt +++ b/ext/oci8/tests/bug27303_2_11gR1.phpt @@ -15,16 +15,14 @@ if ($sv !== 1) { require dirname(__FILE__).'/connect.inc'; -$create_st = array(); -$create_st[] = "drop sequence myseq"; -$create_st[] = "drop table mytab"; -$create_st[] = "create sequence myseq"; -$create_st[] = "create table mytab (mydata varchar2(20), seqcol number)"; +$stmtarray = array( + "drop sequence myseq", + "drop table mytab", + "create sequence myseq", + "create table mytab (mydata varchar2(20), seqcol number)" +); -foreach ($create_st as $statement) { - $stmt = oci_parse($c, $statement); - oci_execute($stmt); -} +oci8_test_sql_execute($c, $stmtarray); define('MYLIMIT', 200); define('INITMYBV', 11); @@ -46,14 +44,12 @@ for ($i = 1; $i < MYLIMIT; $i++) { OCICommit($c); -$drop_st = array(); -$drop_st[] = "drop sequence myseq"; -$drop_st[] = "drop table mytab"; +$stmtarray = array( + "drop sequence myseq", + "drop table mytab" +); -foreach ($create_st as $statement) { - $stmt = oci_parse($c, $statement); - oci_execute($stmt); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/bug27303_4.phpt b/ext/oci8/tests/bug27303_4.phpt index 20dec54dacf88..86b1a8ba5edea 100644 --- a/ext/oci8/tests/bug27303_4.phpt +++ b/ext/oci8/tests/bug27303_4.phpt @@ -4,18 +4,10 @@ Bug #27303 (OCIBindByName binds numeric PHP values as characters) 1[1]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } +if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10gR2 or 11gR2 databases"); +} else if (preg_match('/^11\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> --FILE-- diff --git a/ext/oci8/tests/bug32325.phpt b/ext/oci8/tests/bug32325.phpt index 257c6977b8e63..854e5c15909ae 100644 --- a/ext/oci8/tests/bug32325.phpt +++ b/ext/oci8/tests/bug32325.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #32325 (Cannot retrieve collection using OCI8) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- diff --git a/ext/oci8/tests/bug35973.phpt b/ext/oci8/tests/bug35973.phpt index 81e1e58ba25d7..3f4299ea29e2b 100644 --- a/ext/oci8/tests/bug35973.phpt +++ b/ext/oci8/tests/bug35973.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #35973 (Error ORA-24806 occurs when trying to fetch a NCLOB field) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- ---EXPECT-- +--EXPECTF-- bool(false) bool(false) -string(5) "'ABC'" +string(%r[53]%r) "%r('ABC'|EXP)%r" string(4) "CHAR" Done diff --git a/ext/oci8/tests/bug36403.phpt b/ext/oci8/tests/bug36403.phpt index 68c5f7b0a1756..53dae694ec8bf 100644 --- a/ext/oci8/tests/bug36403.phpt +++ b/ext/oci8/tests/bug36403.phpt @@ -1,7 +1,12 @@ --TEST-- Bug #36403 (oci_execute no longer supports OCI_DESCRIBE_ONLY) --SKIPIF-- - + --FILE-- ===DONE=== @@ -72,5 +56,5 @@ COL2 C1 Test 2 -Warning: oci_fetch_array(): ORA-24338: %sbug36403.php on line %d +Warning: oci_fetch_array(): ORA-%r(24338|01002)%r: %sbug36403.php on line %d ===DONE=== diff --git a/ext/oci8/tests/bug37220.phpt b/ext/oci8/tests/bug37220.phpt index 6743165b709b5..8d59644b8eada 100644 --- a/ext/oci8/tests/bug37220.phpt +++ b/ext/oci8/tests/bug37220.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #37220 (LOB Type mismatch when using windows & oci8.dll) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- '))" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Now let's update the row where myId = 1234 and change the tag // 'THETAG' to 'MYTAG' (mycolumn is an XMLTYPE datatype and @@ -54,10 +54,7 @@ $stmtarray = array( "drop table bug37220_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bug37581.phpt b/ext/oci8/tests/bug37581.phpt index ec86c51959524..1c00f68d31a9a 100644 --- a/ext/oci8/tests/bug37581.phpt +++ b/ext/oci8/tests/bug37581.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #37581 (oci_bind_array_by_name clobbers input array when using SQLT_AFC, AVC) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); if (empty($dbase)) die ("skip requires network connection alias for DB link loopback"); if ($test_drcp) die("skip DRCP does not support shared database links"); ?> @@ -50,12 +50,9 @@ $stmtarray = array( "insert into bug41069_tab (c1, c2, c3, c4, c5, c6, c7, c9, c10, c12, c15) values (113, 'aaaaaaa', 'bbbbbbbbbb', 'cccccc', 'e', 'f', 'dddd', '12/04/2006', '12/04/2006', 2224, 'zzzzzzz')" - ); +); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Tests @@ -79,14 +76,9 @@ $c = oci_new_connect($user, $password, $dbase); $stmtarray = array( "drop database link bug41069_dblink", "drop table bug41069_tab" - ); - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +); -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bug42134.phpt b/ext/oci8/tests/bug42134.phpt index 2b0e3707d62cf..10b7ef160d257 100644 --- a/ext/oci8/tests/bug42134.phpt +++ b/ext/oci8/tests/bug42134.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #42134 (Collection error for invalid collection name) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); +?> --FILE-- --EXPECTF-- diff --git a/ext/oci8/tests/bug42496_2.phpt b/ext/oci8/tests/bug42496_2.phpt index e2800bbd8a637..8c4b79141598f 100644 --- a/ext/oci8/tests/bug42496_2.phpt +++ b/ext/oci8/tests/bug42496_2.phpt @@ -1,7 +1,11 @@ --TEST-- Bug #42496 (LOB fetch leaks cursors, eventually failing with ORA-1000 maximum open cursors reached) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); +?> --FILE-- --EXPECTF-- diff --git a/ext/oci8/tests/bug42841.phpt b/ext/oci8/tests/bug42841.phpt index 921c8149dd82e..a86d1ca847849 100644 --- a/ext/oci8/tests/bug42841.phpt +++ b/ext/oci8/tests/bug42841.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #42841 (REF CURSOR and oci_new_cursor PHP crash) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --INI-- oci8.statement_cache_size=20 --FILE-- @@ -15,97 +18,94 @@ $c = oci_connect($user, $password, $dbase); // Initialization $stmtarray = array( - "create or replace procedure bug42841_proc(out_1 out sys_refcursor) is + "create or replace procedure bug42841_proc(out_1 out sys_refcursor) is begin - open out_1 for select 11 from dual union all select 12 from dual union all select 13 from dual; + open out_1 for select 11 from dual union all select 12 from dual union all select 13 from dual; end bug42841_proc;", - "create or replace package bug43449_pkg is - type cursortype is ref Cursor; - function testcursor return cursortype; - end bug43449_pkg;", - - "create or replace package body bug43449_pkg is - function testcursor return cursortype is - retCursor cursorType; - begin - Open retCursor For 'select * from dual'; - return retCursor; - end; - end bug43449_pkg;" + "create or replace package bug43449_pkg is + type cursortype is ref Cursor; + function testcursor return cursortype; + end bug43449_pkg;", + + "create or replace package body bug43449_pkg is + function testcursor return cursortype is + retCursor cursorType; + begin + Open retCursor For 'select * from dual'; + return retCursor; + end; + end bug43449_pkg;" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Main code function do_bug42841($c) { - echo "First attempt\n"; - - $sql = "BEGIN bug42841_proc(:cursor); END;"; - $stmt = oci_parse($c, $sql); - $cursor = oci_new_cursor($c); - oci_bind_by_name($stmt, ":cursor", $cursor, -1, OCI_B_CURSOR); - - oci_execute($stmt, OCI_DEFAULT); - oci_execute($cursor); - - while($row = oci_fetch_array($cursor, OCI_ASSOC + OCI_RETURN_LOBS)) { - $data1[] = $row; - } - - oci_free_statement($stmt); - oci_free_statement($cursor); - var_dump($data1); - - echo "Second attempt\n"; - - $sql = "BEGIN bug42841_proc(:cursor); END;"; - $stmt = oci_parse($c, $sql); - $cursor = oci_new_cursor($c); - oci_bind_by_name($stmt, ":cursor", $cursor, -1, OCI_B_CURSOR); - - oci_execute($stmt, OCI_DEFAULT); - oci_execute($cursor); - - while($row = oci_fetch_array($cursor, OCI_ASSOC + OCI_RETURN_LOBS)) { - $data2[] = $row; - } - - oci_free_statement($stmt); - oci_free_statement($cursor); - var_dump($data2); + echo "First attempt\n"; + + $sql = "BEGIN bug42841_proc(:cursor); END;"; + $stmt = oci_parse($c, $sql); + $cursor = oci_new_cursor($c); + oci_bind_by_name($stmt, ":cursor", $cursor, -1, OCI_B_CURSOR); + + oci_execute($stmt, OCI_DEFAULT); + oci_execute($cursor); + + while($row = oci_fetch_array($cursor, OCI_ASSOC + OCI_RETURN_LOBS)) { + $data1[] = $row; + } + + oci_free_statement($stmt); + oci_free_statement($cursor); + var_dump($data1); + + echo "Second attempt\n"; + + $sql = "BEGIN bug42841_proc(:cursor); END;"; + $stmt = oci_parse($c, $sql); + $cursor = oci_new_cursor($c); + oci_bind_by_name($stmt, ":cursor", $cursor, -1, OCI_B_CURSOR); + + oci_execute($stmt, OCI_DEFAULT); + oci_execute($cursor); + + while($row = oci_fetch_array($cursor, OCI_ASSOC + OCI_RETURN_LOBS)) { + $data2[] = $row; + } + + oci_free_statement($stmt); + oci_free_statement($cursor); + var_dump($data2); } function do_bug43449($c) { - for ($i = 0; $i < 2; $i++) { - var_dump(bug43449_getCur($c)); - } + for ($i = 0; $i < 2; $i++) { + var_dump(bug43449_getCur($c)); + } } function bug43449_getCur($c) -{ - $cur = oci_new_cursor($c); - $stmt = oci_parse($c, 'begin :cur := bug43449_pkg.testcursor; end;'); - oci_bind_by_name($stmt, ':cur', $cur, -1, OCI_B_CURSOR); - oci_execute($stmt, OCI_DEFAULT); - oci_execute($cur, OCI_DEFAULT); - - $ret = array(); - - while (ocifetchinto($cur, $row, OCI_ASSOC)) { - $ret[] = $row; - } - - oci_free_statement($cur); - oci_free_statement($stmt); - return $ret; +{ + $cur = oci_new_cursor($c); + $stmt = oci_parse($c, 'begin :cur := bug43449_pkg.testcursor; end;'); + oci_bind_by_name($stmt, ':cur', $cur, -1, OCI_B_CURSOR); + oci_execute($stmt, OCI_DEFAULT); + oci_execute($cur, OCI_DEFAULT); + + $ret = array(); + + while (ocifetchinto($cur, $row, OCI_ASSOC)) { + $ret[] = $row; + } + + oci_free_statement($cur); + oci_free_statement($stmt); + return $ret; } echo "Test bug 42841: Procedure with OUT cursor parameter\n"; @@ -119,14 +119,11 @@ do_bug43449($c); // Cleanup $stmtarray = array( - "drop procedure bug42841_proc", - "drop package bug43449_pkg" + "drop procedure bug42841_proc", + "drop package bug43449_pkg" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bug43492.phpt b/ext/oci8/tests/bug43492.phpt index d28aabfcedcf6..e84fa42556ce7 100644 --- a/ext/oci8/tests/bug43492.phpt +++ b/ext/oci8/tests/bug43492.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #43492 (Nested cursor leaks) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- --EXPECT-- diff --git a/ext/oci8/tests/bug43492_2.phpt b/ext/oci8/tests/bug43492_2.phpt index fcf96e984edd8..61511cf6d2f45 100644 --- a/ext/oci8/tests/bug43492_2.phpt +++ b/ext/oci8/tests/bug43492_2.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #43492 (Nested cursor leaks after related bug #44206 fixed) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- --EXPECT-- diff --git a/ext/oci8/tests/bug43497.phpt b/ext/oci8/tests/bug43497.phpt index 1ea46b40d7b07..600fb047bf801 100644 --- a/ext/oci8/tests/bug43497.phpt +++ b/ext/oci8/tests/bug43497.phpt @@ -2,13 +2,11 @@ Bug #43497 (OCI8 XML/getClobVal aka temporary LOBs leak UGA memory) --SKIPIF-- 9/', $phpinfo); -if ($ov === 1) { - die ("skip expected output only valid for Oracle clients from 10g onwards"); +$target_dbs = array('oracledb' => true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); +if (preg_match('/^1[01]\./', oci_client_version()) != 1) { + die("skip expected output only valid with Oracle 10g or greater version of client"); } ?> --FILE-- diff --git a/ext/oci8/tests/bug43497_92.phpt b/ext/oci8/tests/bug43497_92.phpt index e2cb1ce4860af..932a863d7a156 100644 --- a/ext/oci8/tests/bug43497_92.phpt +++ b/ext/oci8/tests/bug43497_92.phpt @@ -1,14 +1,12 @@ --TEST-- Bug #43497 (OCI8 XML/getClobVal aka temporary LOBs leak UGA memory) --SKIPIF-- - 9.2/', $phpinfo); -if ($ov !== 1) { - die ("skip expected output only valid for Oracle 9.2 clients"); + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); +if (preg_match('/Unknown/', oci_client_version()) != 1) { + die("skip expected output only valid with Oracle 9gR2 clients"); } ?> --FILE-- diff --git a/ext/oci8/tests/bug44008.phpt b/ext/oci8/tests/bug44008.phpt index fd10b26b8b013..faacdc625401c 100644 --- a/ext/oci8/tests/bug44008.phpt +++ b/ext/oci8/tests/bug44008.phpt @@ -1,7 +1,10 @@ --TEST-- -Bug #44008 (Incorrect usage of OCI-Lob->close doesn't crash PHP) +Bug #44008 (Incorrect usage of OCI-Lob->close crashes PHP) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); ?> --FILE-- @@ -17,10 +17,7 @@ $stmtarray = array( "create or replace type bug44113_list_t as table of number" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test // The test can take some time to complete and can exceed PHP's test @@ -41,12 +38,7 @@ $stmtarray = array( "drop type bug44113_list_t" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/bug44206.phpt b/ext/oci8/tests/bug44206.phpt index e5771e4182c5c..63805bf6e3a01 100644 --- a/ext/oci8/tests/bug44206.phpt +++ b/ext/oci8/tests/bug44206.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #44206 (Test if selecting ref cursors leads to ORA-1000 maximum open cursors reached) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- array(2) { - ["a"]=> + ["A"]=> string(1) "X" [20]=> string(1) "X" } } array(2) { - ["a"]=> + ["A"]=> string(1) "X" [20]=> string(1) "X" @@ -60,7 +60,7 @@ string(1) "X" string(1) "X" Test 2 array(2) { - ["a"]=> + ["A"]=> array(1) { [0]=> string(1) "X" diff --git a/ext/oci8/tests/bug46994.phpt b/ext/oci8/tests/bug46994.phpt index 0504952f69eb5..604b57f262d72 100644 --- a/ext/oci8/tests/bug46994.phpt +++ b/ext/oci8/tests/bug46994.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #46994 (CLOB size does not update when using CLOB IN OUT param in stored procedure) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs: different error handling for this undefined behavior +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- --EXPECTF-- +Test 1 array(1) { [0]=> array(1) { @@ -34,6 +42,7 @@ array(1) { } array(0) { } +Test 2 array(1) { [0]=> array(1) { diff --git a/ext/oci8/tests/bug47281.phpt b/ext/oci8/tests/bug47281.phpt index 710246738eaf5..6b94bdef2102e 100644 --- a/ext/oci8/tests/bug47281.phpt +++ b/ext/oci8/tests/bug47281.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #47281 ($php_errormsg is limited in size of characters) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --ENV-- NLS_LANG=.AL32UTF8 --FILE-- @@ -19,21 +22,7 @@ $stmtarray = array( end;" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - , 2289 // sequence does not exist - , 4080 // trigger does not exist - , 38802 // edition does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -54,13 +43,10 @@ echo $php_errormsg. "\n"; // Clean up $stmtarray = array( - "drop procedure bug47281_sp" + "drop procedure bug47281_sp" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); ?> ===DONE=== diff --git a/ext/oci8/tests/bug47281_tt.phpt b/ext/oci8/tests/bug47281_tt.phpt new file mode 100644 index 0000000000000..4b4e92ede650d --- /dev/null +++ b/ext/oci8/tests/bug47281_tt.phpt @@ -0,0 +1,59 @@ +--TEST-- +Bug #47281 ($php_errormsg is limited in size of characters) +--SKIPIF-- + false, 'timesten' => true); // test runs on these DBs: shorter message length in TimesTen +require(dirname(__FILE__).'/skipif.inc'); +?> +--ENV-- +NLS_LANG=.AL32UTF8 +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 +ORA-57000: TT8507: ORA-20000: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa +Test 2 +oci_execute(): ORA-57000: TT8507: ORA-20000: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa +===DONE=== diff --git a/ext/oci8/tests/bug51253.phpt b/ext/oci8/tests/bug51253.phpt index fea3333ccf176..a97272f65f423 100644 --- a/ext/oci8/tests/bug51253.phpt +++ b/ext/oci8/tests/bug51253.phpt @@ -1,7 +1,10 @@ --TEST-- Bug #51253 (oci_bind_array_by_name() array references) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - Parse +array(4) { + ["code"]=> + int(1756) + ["message"]=> + string(48) "ORA-01756: %s" + ["offset"]=> + int(0) + ["sqltext"]=> + string(0) "" +} +2nd call +array(4) { + ["code"]=> + int(1756) + ["message"]=> + string(48) "ORA-01756: %s" + ["offset"]=> + int(0) + ["sqltext"]=> + string(0) "" +} + +Test 2 - Parse + +Warning: oci_error() expects parameter 1 to be resource, boolean given in %sbug51291_1.php on line %d +bool(false) +array(4) { + ["code"]=> + int(1756) + ["message"]=> + string(48) "ORA-01756: %s" + ["offset"]=> + int(0) + ["sqltext"]=> + string(0) "" +} +NULL +2nd call + +Warning: oci_error() expects parameter 1 to be resource, boolean given in %sbug51291_1.php on line %d +bool(false) +array(4) { + ["code"]=> + int(1756) + ["message"]=> + string(48) "ORA-01756: %s" + ["offset"]=> + int(0) + ["sqltext"]=> + string(0) "" +} +NULL + +Test 3 - Execute +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +2nd call +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} + +Test 4 - Execute - consecutive oci_error calls of different kinds +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +2nd call +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} + +Test 5 - Execute - after oci_rollback +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +Rollback status is true +2nd call after oci_rollback +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} + +Test 6 - Execute - after successful 2nd query with new handle +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +Execute status is true +2nd call after successful execute +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +bool(false) + +Test 7 - Execute - after successful 2nd query with same handle +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +Execute status is true +2nd call after successful execute +bool(false) +bool(false) +bool(false) + +Test 8 - Execute - after unsuccessful 2nd query with new handle +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} + +Warning: oci_execute(): ORA-00904: %sREALLYNOTHERE%s in %sbug51291_1.php on line %d +Execute status is false +2nd call after unsuccessful execute +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904%sREALLYNOTHERE%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(30) "select reallynothere from dual" +} + +Test 9 - Execute - after unsuccessful 2nd query with same handle +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904:%sDOESNOTEXIST%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(29) "select doesnotexist from dual" +} + +Warning: oci_execute(): ORA-00904: %sREALLYNOTHERE%s in %sbug51291_1.php on line %d +Execute status is false +2nd call after unsuccessful execute +bool(false) +bool(false) +array(4) { + ["code"]=> + int(904) + ["message"]=> + string(%d) "ORA-00904%sREALLYNOTHERE%s" + ["offset"]=> + int(%d) + ["sqltext"]=> + string(30) "select reallynothere from dual" +} +===DONE=== diff --git a/ext/oci8/tests/bug51291_2.phpt b/ext/oci8/tests/bug51291_2.phpt new file mode 100644 index 0000000000000..d5dbf6f82b5b9 --- /dev/null +++ b/ext/oci8/tests/bug51291_2.phpt @@ -0,0 +1,56 @@ +--TEST-- +Bug #51291 (oci_error() doesn't report last error when called two times) +--SKIPIF-- + true, 'timesten' => false); // test runs on these DBs: different error messages from TimesTen +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - Execute - after successful 2nd query with same statement +bool(false) +bool(false) +array(4) { + ["code"]=> + int(6510) + ["message"]=> + string(72) "ORA-06510: PL/SQL: %s +ORA-06512: %s" + ["offset"]=> + int(0) + ["sqltext"]=> + string(64) "declare e exception; begin if :bv = 1 then raise e; end if; end;" +} +Execute status is true +2nd call after successful execute +bool(false) +bool(false) +bool(false) +===DONE=== diff --git a/ext/oci8/tests/coll_001.phpt b/ext/oci8/tests/coll_001.phpt index 57d3cf1b4793d..625d71a2950d7 100644 --- a/ext/oci8/tests/coll_001.phpt +++ b/ext/oci8/tests/coll_001.phpt @@ -1,7 +1,10 @@ --TEST-- oci_new_collection() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +$target_dbs = array('oracledb' => true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- 0 ) deferrable initially deferred)" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - , 2289 // sequence does not exist - , 4080 // trigger does not exist - , 38802 // edition does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -68,12 +57,7 @@ $stmtarray = array( "drop table commit_002_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); ?> ===DONE=== diff --git a/ext/oci8/tests/commit_old.phpt b/ext/oci8/tests/commit_old.phpt index 196e0650cc125..012fc0237207a 100644 --- a/ext/oci8/tests/commit_old.phpt +++ b/ext/oci8/tests/commit_old.phpt @@ -1,7 +1,10 @@ --TEST-- ocicommit()/ocirollback() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); + if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); if ($test_drcp) die("skip output might vary with DRCP"); -$sv = oci_server_version($c); -$sv = preg_match('/Release 1[012]\./', $sv, $matches); -if ($sv == 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 1[012]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 10g or greater client "); - } -} -else { - die ("skip test expected to work only with Oracle 10g or greater server"); +if (preg_match('/Release 1[01]\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10g or greater database server"); +} else if (preg_match('/^1[01]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); } ?> diff --git a/ext/oci8/tests/conn_attr_2.phpt b/ext/oci8/tests/conn_attr_2.phpt index 4765d5eb7b870..1072503529d38 100644 --- a/ext/oci8/tests/conn_attr_2.phpt +++ b/ext/oci8/tests/conn_attr_2.phpt @@ -1,25 +1,19 @@ --TEST-- Set and get of connection attributes across persistent connections and sysdba connection. --SKIPIF-- - true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); + if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); if ($test_drcp) die("skip output might vary with DRCP"); -$sv = oci_server_version($c); -$sv = preg_match('/Release 1[012]\./', $sv, $matches); -if ($sv == 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 1[012]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 10g or greater version of client"); - } -} -else { - die ("skip test expected to work only with Oracle 10g or greater version of server"); +if (preg_match('/Release 1[01]\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10g or greater database server"); +} else if (preg_match('/^1[01]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); } + ?> --INI-- oci8.privileged_connect = On diff --git a/ext/oci8/tests/conn_attr_3.phpt b/ext/oci8/tests/conn_attr_3.phpt index 8b6d92123027a..be8d3306de129 100644 --- a/ext/oci8/tests/conn_attr_3.phpt +++ b/ext/oci8/tests/conn_attr_3.phpt @@ -1,24 +1,17 @@ --TEST-- Set and get of connection attributes with oci_close(). --SKIPIF-- - true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); + if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); if ($test_drcp) die("skip output might vary with DRCP"); -$sv = oci_server_version($c); -$sv = preg_match('/Release 1[012]\./', $sv, $matches); -if ($sv == 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 1[012]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 10g or greater version of client"); - } -} -else { - die ("skip test expected to work only with Oracle 10g or greater version of server"); +if (preg_match('/Release 1[01]\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10g or greater database server"); +} else if (preg_match('/^1[01]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); } ?> --FILE-- diff --git a/ext/oci8/tests/conn_attr_4.phpt b/ext/oci8/tests/conn_attr_4.phpt index 9f55f532635d1..b1a22858a8626 100644 --- a/ext/oci8/tests/conn_attr_4.phpt +++ b/ext/oci8/tests/conn_attr_4.phpt @@ -1,29 +1,25 @@ --TEST-- Set and get of connection attributes with errors. --SKIPIF-- - true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); + if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); if ($test_drcp) die("skip output might vary with DRCP"); if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); -$sv = oci_server_version($c); -$sv = preg_match('/Release 1[012]\./', $sv, $matches); -if ($sv == 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 1[012]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 10g or greater version of client"); - } -} -else { - die ("skip test expected to work only with Oracle 10g or greater version of server"); +if (preg_match('/Release (11\.2|12)\./', oci_server_version($c), $matches) !== 1) { + // Bug fixed in 11.2 prevents client_info being rest + die("skip expected output only valid when using Oracle 11gR2 or greater database server"); +} else if (preg_match('/^1[01]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); } ?> --FILE-- 64 !!!!!this is a very huge string with a length > 64 !!!!!this is a very huge string with a length > 64 !!!!!this is a very huge string with a length > 64 !!!!!'); diff --git a/ext/oci8/tests/conn_attr_5.phpt b/ext/oci8/tests/conn_attr_5.phpt index 9f6b6c7247987..d694ec06a5bdc 100644 --- a/ext/oci8/tests/conn_attr_5.phpt +++ b/ext/oci8/tests/conn_attr_5.phpt @@ -1,24 +1,17 @@ --TEST-- Set and get connection attributes with scope end. --SKIPIF-- - true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); + if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); if ($test_drcp) die("skip output might vary with DRCP"); -$sv = oci_server_version($c); -$sv = preg_match('/Release 1[012]\./', $sv, $matches); -if ($sv == 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 1[012]\./', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 10g or greater version of client"); - } -} -else { - die ("skip test expected to work only with Oracle 10g or greater version of server"); +if (preg_match('/Release 1[01]\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10g or greater database server"); +} else if (preg_match('/^1[01]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); } ?> --FILE-- diff --git a/ext/oci8/tests/connect.inc b/ext/oci8/tests/connect.inc index 5e340cf6fad38..06d1348568603 100644 --- a/ext/oci8/tests/connect.inc +++ b/ext/oci8/tests/connect.inc @@ -10,9 +10,8 @@ else { } if (!$c) { - echo "connect.inc: Failed to connect as '$user' to '$dbase'\n"; - $e = oci_error(); - echo $e['message']."\n"; + $m = oci_error(); + trigger_error("connect.inc: Failed to connect as '$user' to '$dbase': ". $m['message'], E_USER_ERROR); } ?> diff --git a/ext/oci8/tests/connect_scope1.phpt b/ext/oci8/tests/connect_scope1.phpt index d6d16f17eecbb..d265d1da9f108 100644 --- a/ext/oci8/tests/connect_scope1.phpt +++ b/ext/oci8/tests/connect_scope1.phpt @@ -19,10 +19,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -66,10 +63,7 @@ $stmtarray = array( "drop table connect_scope1_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/connect_scope2.phpt b/ext/oci8/tests/connect_scope2.phpt index 7017493f5a062..7d05c114118c3 100644 --- a/ext/oci8/tests/connect_scope2.phpt +++ b/ext/oci8/tests/connect_scope2.phpt @@ -19,10 +19,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -66,10 +63,7 @@ $stmtarray = array( "drop table connect_scope2_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/connect_scope_try1.phpt b/ext/oci8/tests/connect_scope_try1.phpt index a881ea6eadf8d..7f26d4334d085 100644 --- a/ext/oci8/tests/connect_scope_try1.phpt +++ b/ext/oci8/tests/connect_scope_try1.phpt @@ -21,10 +21,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -73,17 +70,14 @@ $stmtarray = array( "drop table scope_try1_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; ?> --EXPECTF-- Test 1 -Caught Exception: oci_execute(): ORA-00984: %s +Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s resource(%d) of type (oci8 connection) array(1) { ["C1"]=> diff --git a/ext/oci8/tests/connect_scope_try2.phpt b/ext/oci8/tests/connect_scope_try2.phpt index 9e6b5ce2e0656..94adb85e93863 100644 --- a/ext/oci8/tests/connect_scope_try2.phpt +++ b/ext/oci8/tests/connect_scope_try2.phpt @@ -21,10 +21,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -73,17 +70,14 @@ $stmtarray = array( "drop table scope_try2_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; ?> --EXPECTF-- Test 1 -Caught Exception: oci_execute(): ORA-00984: %s +Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s resource(%d) of type (oci8 connection) array(1) { ["C1"]=> diff --git a/ext/oci8/tests/connect_scope_try3.phpt b/ext/oci8/tests/connect_scope_try3.phpt index 1cd44b0218bfe..e7891a1073399 100644 --- a/ext/oci8/tests/connect_scope_try3.phpt +++ b/ext/oci8/tests/connect_scope_try3.phpt @@ -21,10 +21,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -73,17 +70,14 @@ $stmtarray = array( "drop table scope_try3_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; ?> --EXPECTF-- Test 1 -Caught Exception: oci_execute(): ORA-00984: %s +Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s resource(%d) of type (oci8 connection) array(1) { ["C1"]=> diff --git a/ext/oci8/tests/connect_scope_try4.phpt b/ext/oci8/tests/connect_scope_try4.phpt index 9b4cd1f278ac7..40369c67ba3f4 100644 --- a/ext/oci8/tests/connect_scope_try4.phpt +++ b/ext/oci8/tests/connect_scope_try4.phpt @@ -21,10 +21,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -73,17 +70,14 @@ $stmtarray = array( "drop table scope_try4_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; ?> --EXPECTF-- Test 1 -Caught Exception: oci_execute(): ORA-00984: %s +Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s resource(%d) of type (oci8 connection) array(1) { ["C1"]=> diff --git a/ext/oci8/tests/connect_scope_try5.phpt b/ext/oci8/tests/connect_scope_try5.phpt index 121fb33dc5f92..3afc87b915686 100644 --- a/ext/oci8/tests/connect_scope_try5.phpt +++ b/ext/oci8/tests/connect_scope_try5.phpt @@ -21,10 +21,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -73,17 +70,14 @@ $stmtarray = array( "drop table scope_try5_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; ?> --EXPECTF-- Test 1 -Caught Exception: oci_execute(): ORA-00984: %s +Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s resource(%d) of type (oci8 persistent connection) array(1) { ["C1"]=> diff --git a/ext/oci8/tests/connect_scope_try6.phpt b/ext/oci8/tests/connect_scope_try6.phpt index 3347543ab85b9..d7b4edfdbe3b7 100644 --- a/ext/oci8/tests/connect_scope_try6.phpt +++ b/ext/oci8/tests/connect_scope_try6.phpt @@ -21,10 +21,7 @@ if (!empty($dbase)) else $c1 = oci_new_connect($user,$password); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - @oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); // Run Test @@ -73,17 +70,14 @@ $stmtarray = array( "drop table scope_try6_tab" ); -foreach ($stmtarray as $stmt) { - $s1 = oci_parse($c1, $stmt); - oci_execute($s1); -} +oci8_test_sql_execute($c1, $stmtarray); echo "Done\n"; ?> --EXPECTF-- Test 1 -Caught Exception: oci_execute(): ORA-00984: %s +Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s resource(%d) of type (oci8 persistent connection) array(1) { ["C1"]=> diff --git a/ext/oci8/tests/connect_without_oracle_home_11.phpt b/ext/oci8/tests/connect_without_oracle_home_11.phpt index be99a8bd6e402..1620803dbb738 100644 --- a/ext/oci8/tests/connect_without_oracle_home_11.phpt +++ b/ext/oci8/tests/connect_without_oracle_home_11.phpt @@ -10,9 +10,8 @@ $ov = preg_match('/Compile-time ORACLE_HOME/', $phpinfo); if ($ov != 1) { die ("skip Test only valid when OCI8 is built with an ORACLE_HOME"); } -$iv = preg_match('/Oracle .*Version => (11\.2|12)/', $phpinfo); -if ($iv != 1) { - die ("skip tests a feature that works only with Oracle 11gR2 or greater version of client"); +if (preg_match('/^11\.2|12\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } ?> --ENV-- diff --git a/ext/oci8/tests/connect_without_oracle_home_old.phpt b/ext/oci8/tests/connect_without_oracle_home_old.phpt index 602d55ff8fb4f..5a731337af13c 100644 --- a/ext/oci8/tests/connect_without_oracle_home_old.phpt +++ b/ext/oci8/tests/connect_without_oracle_home_old.phpt @@ -10,9 +10,8 @@ $ov = preg_match('/Compile-time ORACLE_HOME/', $phpinfo); if ($ov !== 1) { die ("skip Test only valid when OCI8 is built with an ORACLE_HOME"); } -$iv = preg_match('/Oracle .*Version => (10\.2)/', $phpinfo); -if ($iv != 1) { - die ("skip tests a feature that works only with Oracle 10gR2"); +if (preg_match('/^10\.2\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10gR2 client libraries"); } ?> --ENV-- diff --git a/ext/oci8/tests/connect_without_oracle_home_old_11.phpt b/ext/oci8/tests/connect_without_oracle_home_old_11.phpt index 9bb42e75a425a..c7cfecf396119 100644 --- a/ext/oci8/tests/connect_without_oracle_home_old_11.phpt +++ b/ext/oci8/tests/connect_without_oracle_home_old_11.phpt @@ -10,9 +10,8 @@ $ov = preg_match('/Compile-time ORACLE_HOME/', $phpinfo); if ($ov !== 1) { die ("skip Test only valid when OCI8 is built with an ORACLE_HOME"); } -$iv = preg_match('/Oracle .*Version => (11\.2|12)/', $phpinfo); -if ($iv != 1) { - die ("skip tests a feature that works only with Oracle 11gR2 or greater version of client"); +if (preg_match('/^11\.2|12\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } ?> --ENV-- diff --git a/ext/oci8/tests/create_table.inc b/ext/oci8/tests/create_table.inc index afd1fceb9b9f0..7335980682ead 100644 --- a/ext/oci8/tests/create_table.inc +++ b/ext/oci8/tests/create_table.inc @@ -1,11 +1,13 @@ diff --git a/ext/oci8/tests/cursor_bind.phpt b/ext/oci8/tests/cursor_bind.phpt index c2ce15cb38ad2..740402e7e0fe7 100644 --- a/ext/oci8/tests/cursor_bind.phpt +++ b/ext/oci8/tests/cursor_bind.phpt @@ -1,54 +1,34 @@ --TEST-- bind and fetch cursor from a statement --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- ---EXPECT-- +===DONE=== + +--EXPECT-- array(2) { [0]=> string(1) "1" @@ -96,4 +76,4 @@ array(2) { string(1) "1" } bool(false) -Done +===DONE=== diff --git a/ext/oci8/tests/cursor_bind_err.phpt b/ext/oci8/tests/cursor_bind_err.phpt index 33bd04b6d22db..197aad1d197ce 100644 --- a/ext/oci8/tests/cursor_bind_err.phpt +++ b/ext/oci8/tests/cursor_bind_err.phpt @@ -1,7 +1,10 @@ --TEST-- binding a cursor (with errors) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- += $orignumlines) { + oci_bind_array_by_name($s, ":lines", $lines, $numlines, 255, SQLT_CHR); + oci_execute($s); + if ($numlines == 0) { + break; + } + $res = array_merge($res, array_slice($lines, 0, $numlines)); + unset($lines); + } + return $res; +} + +function getdbmsoutput_pl($c) +{ + $s = oci_parse($c, "select * from table(mydofetch())"); + oci_execute($s); + $res = false; + while ($row = oci_fetch_array($s, OCI_NUM)) { + $res[] = $row[0]; + } + return $res; +} + +echo "Test 1\n"; + +setserveroutputon($c); // Turn output buffering on + +$s = oci_parse($c, 'call dbmsoutput_proc()'); +oci_execute($s); +var_dump(getdbmsoutput_do($c)); + +echo "Test 2\n"; + +createoutput($c, 'test 2'); +var_dump(getdbmsoutput_do($c)); + +echo "Test 3\n"; + +createoutput($c, 'test 3'); +var_dump(getdbmsoutput_do2($c)); + +echo "Test 4\n"; + +createoutput($c, 'test 4'); +var_dump(getdbmsoutput_pl($c)); + +// Clean up + +$stmtarray = array( + "drop procedure dbmsoutput_proc" +); + +oci8_test_sql_execute($c, $stmtarray); + +?> +===DONE=== + +--EXPECTF-- +Test 1 +array(1) { + [0]=> + string(12) "Hello World!" +} +Test 2 +array(100) { + [0]=> + string(52) "0 test 2 Hello, world! Lots and lots and ... of text" + [1]=> + string(52) "1 test 2 Hello, world! Lots and lots and ... of text" + [2]=> + string(52) "2 test 2 Hello, world! Lots and lots and ... of text" + [3]=> + string(52) "3 test 2 Hello, world! Lots and lots and ... of text" + [4]=> + string(52) "4 test 2 Hello, world! Lots and lots and ... of text" + [5]=> + string(52) "5 test 2 Hello, world! Lots and lots and ... of text" + [6]=> + string(52) "6 test 2 Hello, world! Lots and lots and ... of text" + [7]=> + string(52) "7 test 2 Hello, world! Lots and lots and ... of text" + [8]=> + string(52) "8 test 2 Hello, world! Lots and lots and ... of text" + [9]=> + string(52) "9 test 2 Hello, world! Lots and lots and ... of text" + [10]=> + string(53) "10 test 2 Hello, world! Lots and lots and ... of text" + [11]=> + string(53) "11 test 2 Hello, world! Lots and lots and ... of text" + [12]=> + string(53) "12 test 2 Hello, world! Lots and lots and ... of text" + [13]=> + string(53) "13 test 2 Hello, world! Lots and lots and ... of text" + [14]=> + string(53) "14 test 2 Hello, world! Lots and lots and ... of text" + [15]=> + string(53) "15 test 2 Hello, world! Lots and lots and ... of text" + [16]=> + string(53) "16 test 2 Hello, world! Lots and lots and ... of text" + [17]=> + string(53) "17 test 2 Hello, world! Lots and lots and ... of text" + [18]=> + string(53) "18 test 2 Hello, world! Lots and lots and ... of text" + [19]=> + string(53) "19 test 2 Hello, world! Lots and lots and ... of text" + [20]=> + string(53) "20 test 2 Hello, world! Lots and lots and ... of text" + [21]=> + string(53) "21 test 2 Hello, world! Lots and lots and ... of text" + [22]=> + string(53) "22 test 2 Hello, world! Lots and lots and ... of text" + [23]=> + string(53) "23 test 2 Hello, world! Lots and lots and ... of text" + [24]=> + string(53) "24 test 2 Hello, world! Lots and lots and ... of text" + [25]=> + string(53) "25 test 2 Hello, world! Lots and lots and ... of text" + [26]=> + string(53) "26 test 2 Hello, world! Lots and lots and ... of text" + [27]=> + string(53) "27 test 2 Hello, world! Lots and lots and ... of text" + [28]=> + string(53) "28 test 2 Hello, world! Lots and lots and ... of text" + [29]=> + string(53) "29 test 2 Hello, world! Lots and lots and ... of text" + [30]=> + string(53) "30 test 2 Hello, world! Lots and lots and ... of text" + [31]=> + string(53) "31 test 2 Hello, world! Lots and lots and ... of text" + [32]=> + string(53) "32 test 2 Hello, world! Lots and lots and ... of text" + [33]=> + string(53) "33 test 2 Hello, world! Lots and lots and ... of text" + [34]=> + string(53) "34 test 2 Hello, world! Lots and lots and ... of text" + [35]=> + string(53) "35 test 2 Hello, world! Lots and lots and ... of text" + [36]=> + string(53) "36 test 2 Hello, world! Lots and lots and ... of text" + [37]=> + string(53) "37 test 2 Hello, world! Lots and lots and ... of text" + [38]=> + string(53) "38 test 2 Hello, world! Lots and lots and ... of text" + [39]=> + string(53) "39 test 2 Hello, world! Lots and lots and ... of text" + [40]=> + string(53) "40 test 2 Hello, world! Lots and lots and ... of text" + [41]=> + string(53) "41 test 2 Hello, world! Lots and lots and ... of text" + [42]=> + string(53) "42 test 2 Hello, world! Lots and lots and ... of text" + [43]=> + string(53) "43 test 2 Hello, world! Lots and lots and ... of text" + [44]=> + string(53) "44 test 2 Hello, world! Lots and lots and ... of text" + [45]=> + string(53) "45 test 2 Hello, world! Lots and lots and ... of text" + [46]=> + string(53) "46 test 2 Hello, world! Lots and lots and ... of text" + [47]=> + string(53) "47 test 2 Hello, world! Lots and lots and ... of text" + [48]=> + string(53) "48 test 2 Hello, world! Lots and lots and ... of text" + [49]=> + string(53) "49 test 2 Hello, world! Lots and lots and ... of text" + [50]=> + string(53) "50 test 2 Hello, world! Lots and lots and ... of text" + [51]=> + string(53) "51 test 2 Hello, world! Lots and lots and ... of text" + [52]=> + string(53) "52 test 2 Hello, world! Lots and lots and ... of text" + [53]=> + string(53) "53 test 2 Hello, world! Lots and lots and ... of text" + [54]=> + string(53) "54 test 2 Hello, world! Lots and lots and ... of text" + [55]=> + string(53) "55 test 2 Hello, world! Lots and lots and ... of text" + [56]=> + string(53) "56 test 2 Hello, world! Lots and lots and ... of text" + [57]=> + string(53) "57 test 2 Hello, world! Lots and lots and ... of text" + [58]=> + string(53) "58 test 2 Hello, world! Lots and lots and ... of text" + [59]=> + string(53) "59 test 2 Hello, world! Lots and lots and ... of text" + [60]=> + string(53) "60 test 2 Hello, world! Lots and lots and ... of text" + [61]=> + string(53) "61 test 2 Hello, world! Lots and lots and ... of text" + [62]=> + string(53) "62 test 2 Hello, world! Lots and lots and ... of text" + [63]=> + string(53) "63 test 2 Hello, world! Lots and lots and ... of text" + [64]=> + string(53) "64 test 2 Hello, world! Lots and lots and ... of text" + [65]=> + string(53) "65 test 2 Hello, world! Lots and lots and ... of text" + [66]=> + string(53) "66 test 2 Hello, world! Lots and lots and ... of text" + [67]=> + string(53) "67 test 2 Hello, world! Lots and lots and ... of text" + [68]=> + string(53) "68 test 2 Hello, world! Lots and lots and ... of text" + [69]=> + string(53) "69 test 2 Hello, world! Lots and lots and ... of text" + [70]=> + string(53) "70 test 2 Hello, world! Lots and lots and ... of text" + [71]=> + string(53) "71 test 2 Hello, world! Lots and lots and ... of text" + [72]=> + string(53) "72 test 2 Hello, world! Lots and lots and ... of text" + [73]=> + string(53) "73 test 2 Hello, world! Lots and lots and ... of text" + [74]=> + string(53) "74 test 2 Hello, world! Lots and lots and ... of text" + [75]=> + string(53) "75 test 2 Hello, world! Lots and lots and ... of text" + [76]=> + string(53) "76 test 2 Hello, world! Lots and lots and ... of text" + [77]=> + string(53) "77 test 2 Hello, world! Lots and lots and ... of text" + [78]=> + string(53) "78 test 2 Hello, world! Lots and lots and ... of text" + [79]=> + string(53) "79 test 2 Hello, world! Lots and lots and ... of text" + [80]=> + string(53) "80 test 2 Hello, world! Lots and lots and ... of text" + [81]=> + string(53) "81 test 2 Hello, world! Lots and lots and ... of text" + [82]=> + string(53) "82 test 2 Hello, world! Lots and lots and ... of text" + [83]=> + string(53) "83 test 2 Hello, world! Lots and lots and ... of text" + [84]=> + string(53) "84 test 2 Hello, world! Lots and lots and ... of text" + [85]=> + string(53) "85 test 2 Hello, world! Lots and lots and ... of text" + [86]=> + string(53) "86 test 2 Hello, world! Lots and lots and ... of text" + [87]=> + string(53) "87 test 2 Hello, world! Lots and lots and ... of text" + [88]=> + string(53) "88 test 2 Hello, world! Lots and lots and ... of text" + [89]=> + string(53) "89 test 2 Hello, world! Lots and lots and ... of text" + [90]=> + string(53) "90 test 2 Hello, world! Lots and lots and ... of text" + [91]=> + string(53) "91 test 2 Hello, world! Lots and lots and ... of text" + [92]=> + string(53) "92 test 2 Hello, world! Lots and lots and ... of text" + [93]=> + string(53) "93 test 2 Hello, world! Lots and lots and ... of text" + [94]=> + string(53) "94 test 2 Hello, world! Lots and lots and ... of text" + [95]=> + string(53) "95 test 2 Hello, world! Lots and lots and ... of text" + [96]=> + string(53) "96 test 2 Hello, world! Lots and lots and ... of text" + [97]=> + string(53) "97 test 2 Hello, world! Lots and lots and ... of text" + [98]=> + string(53) "98 test 2 Hello, world! Lots and lots and ... of text" + [99]=> + string(53) "99 test 2 Hello, world! Lots and lots and ... of text" +} +Test 3 +array(100) { + [0]=> + string(52) "0 test 3 Hello, world! Lots and lots and ... of text" + [1]=> + string(52) "1 test 3 Hello, world! Lots and lots and ... of text" + [2]=> + string(52) "2 test 3 Hello, world! Lots and lots and ... of text" + [3]=> + string(52) "3 test 3 Hello, world! Lots and lots and ... of text" + [4]=> + string(52) "4 test 3 Hello, world! Lots and lots and ... of text" + [5]=> + string(52) "5 test 3 Hello, world! Lots and lots and ... of text" + [6]=> + string(52) "6 test 3 Hello, world! Lots and lots and ... of text" + [7]=> + string(52) "7 test 3 Hello, world! Lots and lots and ... of text" + [8]=> + string(52) "8 test 3 Hello, world! Lots and lots and ... of text" + [9]=> + string(52) "9 test 3 Hello, world! Lots and lots and ... of text" + [10]=> + string(53) "10 test 3 Hello, world! Lots and lots and ... of text" + [11]=> + string(53) "11 test 3 Hello, world! Lots and lots and ... of text" + [12]=> + string(53) "12 test 3 Hello, world! Lots and lots and ... of text" + [13]=> + string(53) "13 test 3 Hello, world! Lots and lots and ... of text" + [14]=> + string(53) "14 test 3 Hello, world! Lots and lots and ... of text" + [15]=> + string(53) "15 test 3 Hello, world! Lots and lots and ... of text" + [16]=> + string(53) "16 test 3 Hello, world! Lots and lots and ... of text" + [17]=> + string(53) "17 test 3 Hello, world! Lots and lots and ... of text" + [18]=> + string(53) "18 test 3 Hello, world! Lots and lots and ... of text" + [19]=> + string(53) "19 test 3 Hello, world! Lots and lots and ... of text" + [20]=> + string(53) "20 test 3 Hello, world! Lots and lots and ... of text" + [21]=> + string(53) "21 test 3 Hello, world! Lots and lots and ... of text" + [22]=> + string(53) "22 test 3 Hello, world! Lots and lots and ... of text" + [23]=> + string(53) "23 test 3 Hello, world! Lots and lots and ... of text" + [24]=> + string(53) "24 test 3 Hello, world! Lots and lots and ... of text" + [25]=> + string(53) "25 test 3 Hello, world! Lots and lots and ... of text" + [26]=> + string(53) "26 test 3 Hello, world! Lots and lots and ... of text" + [27]=> + string(53) "27 test 3 Hello, world! Lots and lots and ... of text" + [28]=> + string(53) "28 test 3 Hello, world! Lots and lots and ... of text" + [29]=> + string(53) "29 test 3 Hello, world! Lots and lots and ... of text" + [30]=> + string(53) "30 test 3 Hello, world! Lots and lots and ... of text" + [31]=> + string(53) "31 test 3 Hello, world! Lots and lots and ... of text" + [32]=> + string(53) "32 test 3 Hello, world! Lots and lots and ... of text" + [33]=> + string(53) "33 test 3 Hello, world! Lots and lots and ... of text" + [34]=> + string(53) "34 test 3 Hello, world! Lots and lots and ... of text" + [35]=> + string(53) "35 test 3 Hello, world! Lots and lots and ... of text" + [36]=> + string(53) "36 test 3 Hello, world! Lots and lots and ... of text" + [37]=> + string(53) "37 test 3 Hello, world! Lots and lots and ... of text" + [38]=> + string(53) "38 test 3 Hello, world! Lots and lots and ... of text" + [39]=> + string(53) "39 test 3 Hello, world! Lots and lots and ... of text" + [40]=> + string(53) "40 test 3 Hello, world! Lots and lots and ... of text" + [41]=> + string(53) "41 test 3 Hello, world! Lots and lots and ... of text" + [42]=> + string(53) "42 test 3 Hello, world! Lots and lots and ... of text" + [43]=> + string(53) "43 test 3 Hello, world! Lots and lots and ... of text" + [44]=> + string(53) "44 test 3 Hello, world! Lots and lots and ... of text" + [45]=> + string(53) "45 test 3 Hello, world! Lots and lots and ... of text" + [46]=> + string(53) "46 test 3 Hello, world! Lots and lots and ... of text" + [47]=> + string(53) "47 test 3 Hello, world! Lots and lots and ... of text" + [48]=> + string(53) "48 test 3 Hello, world! Lots and lots and ... of text" + [49]=> + string(53) "49 test 3 Hello, world! Lots and lots and ... of text" + [50]=> + string(53) "50 test 3 Hello, world! Lots and lots and ... of text" + [51]=> + string(53) "51 test 3 Hello, world! Lots and lots and ... of text" + [52]=> + string(53) "52 test 3 Hello, world! Lots and lots and ... of text" + [53]=> + string(53) "53 test 3 Hello, world! Lots and lots and ... of text" + [54]=> + string(53) "54 test 3 Hello, world! Lots and lots and ... of text" + [55]=> + string(53) "55 test 3 Hello, world! Lots and lots and ... of text" + [56]=> + string(53) "56 test 3 Hello, world! Lots and lots and ... of text" + [57]=> + string(53) "57 test 3 Hello, world! Lots and lots and ... of text" + [58]=> + string(53) "58 test 3 Hello, world! Lots and lots and ... of text" + [59]=> + string(53) "59 test 3 Hello, world! Lots and lots and ... of text" + [60]=> + string(53) "60 test 3 Hello, world! Lots and lots and ... of text" + [61]=> + string(53) "61 test 3 Hello, world! Lots and lots and ... of text" + [62]=> + string(53) "62 test 3 Hello, world! Lots and lots and ... of text" + [63]=> + string(53) "63 test 3 Hello, world! Lots and lots and ... of text" + [64]=> + string(53) "64 test 3 Hello, world! Lots and lots and ... of text" + [65]=> + string(53) "65 test 3 Hello, world! Lots and lots and ... of text" + [66]=> + string(53) "66 test 3 Hello, world! Lots and lots and ... of text" + [67]=> + string(53) "67 test 3 Hello, world! Lots and lots and ... of text" + [68]=> + string(53) "68 test 3 Hello, world! Lots and lots and ... of text" + [69]=> + string(53) "69 test 3 Hello, world! Lots and lots and ... of text" + [70]=> + string(53) "70 test 3 Hello, world! Lots and lots and ... of text" + [71]=> + string(53) "71 test 3 Hello, world! Lots and lots and ... of text" + [72]=> + string(53) "72 test 3 Hello, world! Lots and lots and ... of text" + [73]=> + string(53) "73 test 3 Hello, world! Lots and lots and ... of text" + [74]=> + string(53) "74 test 3 Hello, world! Lots and lots and ... of text" + [75]=> + string(53) "75 test 3 Hello, world! Lots and lots and ... of text" + [76]=> + string(53) "76 test 3 Hello, world! Lots and lots and ... of text" + [77]=> + string(53) "77 test 3 Hello, world! Lots and lots and ... of text" + [78]=> + string(53) "78 test 3 Hello, world! Lots and lots and ... of text" + [79]=> + string(53) "79 test 3 Hello, world! Lots and lots and ... of text" + [80]=> + string(53) "80 test 3 Hello, world! Lots and lots and ... of text" + [81]=> + string(53) "81 test 3 Hello, world! Lots and lots and ... of text" + [82]=> + string(53) "82 test 3 Hello, world! Lots and lots and ... of text" + [83]=> + string(53) "83 test 3 Hello, world! Lots and lots and ... of text" + [84]=> + string(53) "84 test 3 Hello, world! Lots and lots and ... of text" + [85]=> + string(53) "85 test 3 Hello, world! Lots and lots and ... of text" + [86]=> + string(53) "86 test 3 Hello, world! Lots and lots and ... of text" + [87]=> + string(53) "87 test 3 Hello, world! Lots and lots and ... of text" + [88]=> + string(53) "88 test 3 Hello, world! Lots and lots and ... of text" + [89]=> + string(53) "89 test 3 Hello, world! Lots and lots and ... of text" + [90]=> + string(53) "90 test 3 Hello, world! Lots and lots and ... of text" + [91]=> + string(53) "91 test 3 Hello, world! Lots and lots and ... of text" + [92]=> + string(53) "92 test 3 Hello, world! Lots and lots and ... of text" + [93]=> + string(53) "93 test 3 Hello, world! Lots and lots and ... of text" + [94]=> + string(53) "94 test 3 Hello, world! Lots and lots and ... of text" + [95]=> + string(53) "95 test 3 Hello, world! Lots and lots and ... of text" + [96]=> + string(53) "96 test 3 Hello, world! Lots and lots and ... of text" + [97]=> + string(53) "97 test 3 Hello, world! Lots and lots and ... of text" + [98]=> + string(53) "98 test 3 Hello, world! Lots and lots and ... of text" + [99]=> + string(53) "99 test 3 Hello, world! Lots and lots and ... of text" +} +Test 4 +array(100) { + [0]=> + string(52) "0 test 4 Hello, world! Lots and lots and ... of text" + [1]=> + string(52) "1 test 4 Hello, world! Lots and lots and ... of text" + [2]=> + string(52) "2 test 4 Hello, world! Lots and lots and ... of text" + [3]=> + string(52) "3 test 4 Hello, world! Lots and lots and ... of text" + [4]=> + string(52) "4 test 4 Hello, world! Lots and lots and ... of text" + [5]=> + string(52) "5 test 4 Hello, world! Lots and lots and ... of text" + [6]=> + string(52) "6 test 4 Hello, world! Lots and lots and ... of text" + [7]=> + string(52) "7 test 4 Hello, world! Lots and lots and ... of text" + [8]=> + string(52) "8 test 4 Hello, world! Lots and lots and ... of text" + [9]=> + string(52) "9 test 4 Hello, world! Lots and lots and ... of text" + [10]=> + string(53) "10 test 4 Hello, world! Lots and lots and ... of text" + [11]=> + string(53) "11 test 4 Hello, world! Lots and lots and ... of text" + [12]=> + string(53) "12 test 4 Hello, world! Lots and lots and ... of text" + [13]=> + string(53) "13 test 4 Hello, world! Lots and lots and ... of text" + [14]=> + string(53) "14 test 4 Hello, world! Lots and lots and ... of text" + [15]=> + string(53) "15 test 4 Hello, world! Lots and lots and ... of text" + [16]=> + string(53) "16 test 4 Hello, world! Lots and lots and ... of text" + [17]=> + string(53) "17 test 4 Hello, world! Lots and lots and ... of text" + [18]=> + string(53) "18 test 4 Hello, world! Lots and lots and ... of text" + [19]=> + string(53) "19 test 4 Hello, world! Lots and lots and ... of text" + [20]=> + string(53) "20 test 4 Hello, world! Lots and lots and ... of text" + [21]=> + string(53) "21 test 4 Hello, world! Lots and lots and ... of text" + [22]=> + string(53) "22 test 4 Hello, world! Lots and lots and ... of text" + [23]=> + string(53) "23 test 4 Hello, world! Lots and lots and ... of text" + [24]=> + string(53) "24 test 4 Hello, world! Lots and lots and ... of text" + [25]=> + string(53) "25 test 4 Hello, world! Lots and lots and ... of text" + [26]=> + string(53) "26 test 4 Hello, world! Lots and lots and ... of text" + [27]=> + string(53) "27 test 4 Hello, world! Lots and lots and ... of text" + [28]=> + string(53) "28 test 4 Hello, world! Lots and lots and ... of text" + [29]=> + string(53) "29 test 4 Hello, world! Lots and lots and ... of text" + [30]=> + string(53) "30 test 4 Hello, world! Lots and lots and ... of text" + [31]=> + string(53) "31 test 4 Hello, world! Lots and lots and ... of text" + [32]=> + string(53) "32 test 4 Hello, world! Lots and lots and ... of text" + [33]=> + string(53) "33 test 4 Hello, world! Lots and lots and ... of text" + [34]=> + string(53) "34 test 4 Hello, world! Lots and lots and ... of text" + [35]=> + string(53) "35 test 4 Hello, world! Lots and lots and ... of text" + [36]=> + string(53) "36 test 4 Hello, world! Lots and lots and ... of text" + [37]=> + string(53) "37 test 4 Hello, world! Lots and lots and ... of text" + [38]=> + string(53) "38 test 4 Hello, world! Lots and lots and ... of text" + [39]=> + string(53) "39 test 4 Hello, world! Lots and lots and ... of text" + [40]=> + string(53) "40 test 4 Hello, world! Lots and lots and ... of text" + [41]=> + string(53) "41 test 4 Hello, world! Lots and lots and ... of text" + [42]=> + string(53) "42 test 4 Hello, world! Lots and lots and ... of text" + [43]=> + string(53) "43 test 4 Hello, world! Lots and lots and ... of text" + [44]=> + string(53) "44 test 4 Hello, world! Lots and lots and ... of text" + [45]=> + string(53) "45 test 4 Hello, world! Lots and lots and ... of text" + [46]=> + string(53) "46 test 4 Hello, world! Lots and lots and ... of text" + [47]=> + string(53) "47 test 4 Hello, world! Lots and lots and ... of text" + [48]=> + string(53) "48 test 4 Hello, world! Lots and lots and ... of text" + [49]=> + string(53) "49 test 4 Hello, world! Lots and lots and ... of text" + [50]=> + string(53) "50 test 4 Hello, world! Lots and lots and ... of text" + [51]=> + string(53) "51 test 4 Hello, world! Lots and lots and ... of text" + [52]=> + string(53) "52 test 4 Hello, world! Lots and lots and ... of text" + [53]=> + string(53) "53 test 4 Hello, world! Lots and lots and ... of text" + [54]=> + string(53) "54 test 4 Hello, world! Lots and lots and ... of text" + [55]=> + string(53) "55 test 4 Hello, world! Lots and lots and ... of text" + [56]=> + string(53) "56 test 4 Hello, world! Lots and lots and ... of text" + [57]=> + string(53) "57 test 4 Hello, world! Lots and lots and ... of text" + [58]=> + string(53) "58 test 4 Hello, world! Lots and lots and ... of text" + [59]=> + string(53) "59 test 4 Hello, world! Lots and lots and ... of text" + [60]=> + string(53) "60 test 4 Hello, world! Lots and lots and ... of text" + [61]=> + string(53) "61 test 4 Hello, world! Lots and lots and ... of text" + [62]=> + string(53) "62 test 4 Hello, world! Lots and lots and ... of text" + [63]=> + string(53) "63 test 4 Hello, world! Lots and lots and ... of text" + [64]=> + string(53) "64 test 4 Hello, world! Lots and lots and ... of text" + [65]=> + string(53) "65 test 4 Hello, world! Lots and lots and ... of text" + [66]=> + string(53) "66 test 4 Hello, world! Lots and lots and ... of text" + [67]=> + string(53) "67 test 4 Hello, world! Lots and lots and ... of text" + [68]=> + string(53) "68 test 4 Hello, world! Lots and lots and ... of text" + [69]=> + string(53) "69 test 4 Hello, world! Lots and lots and ... of text" + [70]=> + string(53) "70 test 4 Hello, world! Lots and lots and ... of text" + [71]=> + string(53) "71 test 4 Hello, world! Lots and lots and ... of text" + [72]=> + string(53) "72 test 4 Hello, world! Lots and lots and ... of text" + [73]=> + string(53) "73 test 4 Hello, world! Lots and lots and ... of text" + [74]=> + string(53) "74 test 4 Hello, world! Lots and lots and ... of text" + [75]=> + string(53) "75 test 4 Hello, world! Lots and lots and ... of text" + [76]=> + string(53) "76 test 4 Hello, world! Lots and lots and ... of text" + [77]=> + string(53) "77 test 4 Hello, world! Lots and lots and ... of text" + [78]=> + string(53) "78 test 4 Hello, world! Lots and lots and ... of text" + [79]=> + string(53) "79 test 4 Hello, world! Lots and lots and ... of text" + [80]=> + string(53) "80 test 4 Hello, world! Lots and lots and ... of text" + [81]=> + string(53) "81 test 4 Hello, world! Lots and lots and ... of text" + [82]=> + string(53) "82 test 4 Hello, world! Lots and lots and ... of text" + [83]=> + string(53) "83 test 4 Hello, world! Lots and lots and ... of text" + [84]=> + string(53) "84 test 4 Hello, world! Lots and lots and ... of text" + [85]=> + string(53) "85 test 4 Hello, world! Lots and lots and ... of text" + [86]=> + string(53) "86 test 4 Hello, world! Lots and lots and ... of text" + [87]=> + string(53) "87 test 4 Hello, world! Lots and lots and ... of text" + [88]=> + string(53) "88 test 4 Hello, world! Lots and lots and ... of text" + [89]=> + string(53) "89 test 4 Hello, world! Lots and lots and ... of text" + [90]=> + string(53) "90 test 4 Hello, world! Lots and lots and ... of text" + [91]=> + string(53) "91 test 4 Hello, world! Lots and lots and ... of text" + [92]=> + string(53) "92 test 4 Hello, world! Lots and lots and ... of text" + [93]=> + string(53) "93 test 4 Hello, world! Lots and lots and ... of text" + [94]=> + string(53) "94 test 4 Hello, world! Lots and lots and ... of text" + [95]=> + string(53) "95 test 4 Hello, world! Lots and lots and ... of text" + [96]=> + string(53) "96 test 4 Hello, world! Lots and lots and ... of text" + [97]=> + string(53) "97 test 4 Hello, world! Lots and lots and ... of text" + [98]=> + string(53) "98 test 4 Hello, world! Lots and lots and ... of text" + [99]=> + string(53) "99 test 4 Hello, world! Lots and lots and ... of text" +} +===DONE=== diff --git a/ext/oci8/tests/default_prefetch.phpt b/ext/oci8/tests/default_prefetch.phpt index 47191c8585b51..cc70c6ecb3c7c 100644 --- a/ext/oci8/tests/default_prefetch.phpt +++ b/ext/oci8/tests/default_prefetch.phpt @@ -19,23 +19,7 @@ $stmtarray = array( "insert into default_prefetch_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -59,11 +43,7 @@ $stmtarray = array( "drop table default_prefetch_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/default_prefetch0.phpt b/ext/oci8/tests/default_prefetch0.phpt new file mode 100644 index 0000000000000..cc70c6ecb3c7c --- /dev/null +++ b/ext/oci8/tests/default_prefetch0.phpt @@ -0,0 +1,53 @@ +--TEST-- +oci8.default_prefetch ini option +--SKIPIF-- + +--INI-- +oci8.default_prefetch=20 +--FILE-- + +--EXPECT-- +bool(true) +int(1) +Done diff --git a/ext/oci8/tests/default_prefetch1.phpt b/ext/oci8/tests/default_prefetch1.phpt index bcd66fa38196f..bc788293657db 100644 --- a/ext/oci8/tests/default_prefetch1.phpt +++ b/ext/oci8/tests/default_prefetch1.phpt @@ -19,23 +19,7 @@ $stmtarray = array( "insert into default_prefetch1_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -59,10 +43,7 @@ $stmtarray = array( "drop table default_prefetch1_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/default_prefetch2.phpt b/ext/oci8/tests/default_prefetch2.phpt index 7b3f29f2960c3..d8a76dbb079f4 100644 --- a/ext/oci8/tests/default_prefetch2.phpt +++ b/ext/oci8/tests/default_prefetch2.phpt @@ -19,23 +19,7 @@ $stmtarray = array( "insert into default_prefetch2_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -60,10 +44,7 @@ $stmtarray = array( "drop table default_prefetch2_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/define.phpt b/ext/oci8/tests/define.phpt index d99bc7e1a6e62..c6ce7bd9b3048 100644 --- a/ext/oci8/tests/define.phpt +++ b/ext/oci8/tests/define.phpt @@ -15,18 +15,7 @@ $stmtarray = array( "insert into define_tab (string) values ('some')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run test @@ -49,10 +38,7 @@ $stmtarray = array( "drop table define_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/define0.phpt b/ext/oci8/tests/define0.phpt new file mode 100644 index 0000000000000..f2f06e3152f59 --- /dev/null +++ b/ext/oci8/tests/define0.phpt @@ -0,0 +1,61 @@ +--TEST-- +oci_define_by_name() +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 +string(%d) "some" +Test 2 +string(%d) "some" +===DONE=== diff --git a/ext/oci8/tests/define1.phpt b/ext/oci8/tests/define1.phpt index 341bc9ed83426..6e4b74e3bacb5 100644 --- a/ext/oci8/tests/define1.phpt +++ b/ext/oci8/tests/define1.phpt @@ -15,18 +15,7 @@ $stmtarray = array( "insert into define1_tab (string) values ('some')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run test @@ -52,10 +41,7 @@ $stmtarray = array( "drop table define1_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/define2.phpt b/ext/oci8/tests/define2.phpt index 46e11bf8861b9..c53bebd2e1f83 100644 --- a/ext/oci8/tests/define2.phpt +++ b/ext/oci8/tests/define2.phpt @@ -1,7 +1,10 @@ --TEST-- Test oci_define_by_name types --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- diff --git a/ext/oci8/tests/define3.phpt b/ext/oci8/tests/define3.phpt index 892e8e3809807..77714a92f049f 100644 --- a/ext/oci8/tests/define3.phpt +++ b/ext/oci8/tests/define3.phpt @@ -1,7 +1,10 @@ --TEST-- Test oci_define_by_name() LOB descriptor --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- load()) . "\n"; } -$stmt = oci_parse($c, "drop table phpdefblobtable"); -oci_execute($stmt); +$stmtarray = array( + "drop table phpdefblobtable" +); + +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/define4.phpt b/ext/oci8/tests/define4.phpt index 8d83f73ac3cce..266fd7edd70fe 100644 --- a/ext/oci8/tests/define4.phpt +++ b/ext/oci8/tests/define4.phpt @@ -15,18 +15,7 @@ $stmtarray = array( "insert into define4_tab (value, string) values (1234, 'some')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run test @@ -60,10 +49,7 @@ $stmtarray = array( "drop table define4_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/define5.phpt b/ext/oci8/tests/define5.phpt index 63541ce9dd4ef..68fa01d09aa87 100644 --- a/ext/oci8/tests/define5.phpt +++ b/ext/oci8/tests/define5.phpt @@ -16,18 +16,7 @@ $stmtarray = array( "insert into define5_tab (id, string) values (2, 'thing')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run test @@ -63,10 +52,7 @@ $stmtarray = array( "drop table define5_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/define6.phpt b/ext/oci8/tests/define6.phpt new file mode 100644 index 0000000000000..50e23ecf45bb9 --- /dev/null +++ b/ext/oci8/tests/define6.phpt @@ -0,0 +1,138 @@ +--TEST-- +oci_define_by_name tests with REF CURSORs +--SKIPIF-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - define last +NULL +Test 2 - define last with preset var +string(0) "" +Test 3 - define before cursor execute +string(1) "1" +Test 4 - define before top level execute +string(1) "1" +Test 5 - define before bind +string(1) "1" +Test 6 - fetch on wrong handle + +Warning: oci_fetch_row(): ORA-24374: %s in %sdefine6.php on line %d +===DONE=== diff --git a/ext/oci8/tests/define_old.phpt b/ext/oci8/tests/define_old.phpt index 618f9d5f5713e..f65e6b80809b4 100644 --- a/ext/oci8/tests/define_old.phpt +++ b/ext/oci8/tests/define_old.phpt @@ -15,18 +15,7 @@ $stmtarray = array( "insert into define_old_tab (string) values ('some')", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run test @@ -49,11 +38,7 @@ $stmtarray = array( "drop table define_old_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/descriptors.phpt b/ext/oci8/tests/descriptors.phpt index 8be4f3a06d32e..9193fdddebfaf 100644 --- a/ext/oci8/tests/descriptors.phpt +++ b/ext/oci8/tests/descriptors.phpt @@ -1,7 +1,10 @@ --TEST-- commit connection after destroying the descriptor --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- diff --git a/ext/oci8/tests/drcp_connect1.phpt b/ext/oci8/tests/drcp_connect1.phpt index bf619a4efd0e2..25395dc187b22 100644 --- a/ext/oci8/tests/drcp_connect1.phpt +++ b/ext/oci8/tests/drcp_connect1.phpt @@ -1,7 +1,10 @@ --TEST-- DRCP: oci_connect() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs (Calling PL/SQL from SQL is not supported in TimesTen) +require(dirname(__FILE__).'/skipif.inc'); +?> --INI-- oci8.connection_class=test oci8.old_oci_close_semantics=0 @@ -16,10 +19,12 @@ require dirname(__FILE__)."/drcp_functions.inc"; // To verify this, we change the value of a PL/SQL package variable in one // session and query for this through another connection +echo "Test 1a\n"; var_dump($conn1 = oci_connect($user,$password,$dbase)); // Create the package drcp_create_package($conn1); - + +echo "Test 1b\n"; // OCI_CONNECT echo " This is with OCI_CONNECT.....\n"; drcp_select_packagevar($conn1); // Returns 0 @@ -27,12 +32,14 @@ drcp_set_packagevar($conn1,1000); oci_close($conn1); echo " Connection conn1 closed....\n"; +echo "Test 2\n"; // Second connection should return 0 for the package variable. var_dump($conn2 = oci_connect($user,$password,$dbase)); echo " Select with connection 2 \n"; drcp_select_packagevar($conn2); // Returns 0 drcp_set_packagevar($conn2,100); +echo "Test 3\n"; // Third connection. There is no oci_close() for conn2 hence this should // return the value set by conn2. var_dump($conn3 = oci_connect($user,$password,$dbase)); @@ -43,8 +50,9 @@ drcp_select_packagevar($conn3); // Returns 100 oci_close($conn2); oci_close($conn3); +echo "Test 4\n"; // OCI_PCONNECT -echo "\n This is with oci_pconnect().....\n"; +echo " This is with oci_pconnect().....\n"; var_dump($pconn1 = oci_pconnect($user,$password,$dbase)); drcp_set_packagevar($pconn1,1000); oci_close($pconn1); @@ -53,6 +61,7 @@ echo " Connection pconn1 closed....\n"; // Second connection with oci_pconnect should return the same session hence the // value returned is what is set by pconn1 +echo "Test 5\n"; var_dump($pconn2 = oci_pconnect($user,$password,$dbase)); echo " Select with persistent connection 2 \n"; drcp_select_packagevar($pconn2); // Returns 1000 @@ -62,23 +71,28 @@ echo "Done\n"; ?> --EXPECTF-- +Test 1a resource(%d) of type (oci8 connection) +Test 1b This is with OCI_CONNECT..... The value of the package variable is 0 Package variable value set to 1000 Connection conn1 closed.... +Test 2 resource(%d) of type (oci8 connection) Select with connection 2 The value of the package variable is 0 Package variable value set to 100 +Test 3 resource(%d) of type (oci8 connection) Select with connection 3 The value of the package variable is 100 - +Test 4 This is with oci_pconnect()..... resource(%d) of type (oci8 persistent connection) Package variable value set to 1000 Connection pconn1 closed.... +Test 5 resource(%d) of type (oci8 persistent connection) Select with persistent connection 2 The value of the package variable is 1000 diff --git a/ext/oci8/tests/drcp_functions.inc b/ext/oci8/tests/drcp_functions.inc index 26adb21f35ea6..f6b24446c99c3 100644 --- a/ext/oci8/tests/drcp_functions.inc +++ b/ext/oci8/tests/drcp_functions.inc @@ -14,7 +14,7 @@ function drcp_create_table($conn) $dept_values = array("ACCOUNTS","HR","HR","ADMIN","ACCOUNTS","HR", "ACCOUNTS","HR","ACCOUNTS"); for($i=0; $i<8; $i++) { - $insert = "INSERT INTO DRCPTEST VALUES('".$id_values[$i]."','". $name_values[$i]."','".$dept_values[$i]."')"; + $insert = "INSERT INTO DRCPTEST VALUES(".$id_values[$i].",'". $name_values[$i]."','".$dept_values[$i]."')"; $s = oci_parse($conn, $insert); oci_execute($s); } diff --git a/ext/oci8/tests/drcp_privileged.phpt b/ext/oci8/tests/drcp_privileged.phpt index 9af20625eddc7..45b5ee4bdb642 100644 --- a/ext/oci8/tests/drcp_privileged.phpt +++ b/ext/oci8/tests/drcp_privileged.phpt @@ -5,7 +5,10 @@ DRCP: privileged connect if (!extension_loaded('oci8')) die("skip no oci8 extension"); if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); require(dirname(__FILE__)."/details.inc"); -if (empty($oracle_on_localhost)) die("skip this test is unlikely to work with remote Oracle - unless an Oracle password file has been created"); +if (preg_match('/Compile-time ORACLE_HOME/', $phpinfo) !== 1) { + // Assume building PHP with an ORACLE_HOME means the tested DB is on the same machine as PHP + die("skip this test is unlikely to work with remote Oracle - unless an Oracle password file has been created"); +} ?> --INI-- oci8.privileged_connect=1 @@ -26,22 +29,22 @@ echo "Done\n"; ?> --EXPECTF-- -Warning: oci_connect(): ORA-01031: insufficient privileges in %s on line %d +Warning: oci_connect(): ORA-01031: %s in %s on line %d bool(false) -Warning: oci_connect(): ORA-01031: insufficient privileges in %s on line %d +Warning: oci_connect(): ORA-01031: %s in %s on line %d bool(false) -Warning: oci_new_connect(): ORA-01031: insufficient privileges in %s on line %d +Warning: oci_new_connect(): ORA-01031: %s in %s on line %d bool(false) -Warning: oci_new_connect(): ORA-01031: insufficient privileges in %s on line %d +Warning: oci_new_connect(): ORA-01031: %s in %s on line %d bool(false) -Warning: oci_pconnect(): ORA-01031: insufficient privileges in %s on line %d +Warning: oci_pconnect(): ORA-01031: %s in %s on line %d bool(false) -Warning: oci_pconnect(): ORA-01031: insufficient privileges in %s on line %d +Warning: oci_pconnect(): ORA-01031: %s in %s on line %d bool(false) Done diff --git a/ext/oci8/tests/driver_name.phpt b/ext/oci8/tests/driver_name.phpt index 187d7e18626b4..bf86e66e7b64f 100644 --- a/ext/oci8/tests/driver_name.phpt +++ b/ext/oci8/tests/driver_name.phpt @@ -7,20 +7,10 @@ require(dirname(__FILE__)."/connect.inc"); if (strcasecmp($user, "system") && strcasecmp($user, "sys")) die("skip needs to be run as a DBA user"); if ($test_drcp) die("skip as Output might vary with DRCP"); -$sv = oci_server_version($c); -$sv = preg_match('/Release (11.2|12)/', $sv, $matches); - -if ($sv == 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => (11.2|12)/', $phpinfo); - if ($iv != 1) { - die ("skip test expected to work only with Oracle 11g or greater version of client"); - } -} -else { - die ("skip test expected to work only with Oracle 11g or greater version of server"); +if (preg_match('/Release (11\.2|12)/', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 11gR2 or greater databases"); +} else if (preg_match('/^(11\.2|12\.)/', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> diff --git a/ext/oci8/tests/dupcolnames.phpt b/ext/oci8/tests/dupcolnames.phpt new file mode 100644 index 0000000000000..bf0749717813c --- /dev/null +++ b/ext/oci8/tests/dupcolnames.phpt @@ -0,0 +1,102 @@ +--TEST-- +SELECT tests with duplicate column anmes +--SKIPIF-- + +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1 - OCI_ASSOC +array(3) { + ["C1"]=> + string(1) "1" + ["DUPNAMECOL"]=> + string(5) "jones" + ["C2"]=> + string(1) "2" +} + +Test 2 - OCI_NUM +array(4) { + [0]=> + string(1) "1" + [1]=> + string(5) "chris" + [2]=> + string(1) "2" + [3]=> + string(5) "jones" +} + +Test 3 - OCI_ASSOC+OCI_NUM +array(7) { + [0]=> + string(1) "1" + ["C1"]=> + string(1) "1" + [1]=> + string(5) "chris" + ["DUPNAMECOL"]=> + string(5) "jones" + [2]=> + string(1) "2" + ["C2"]=> + string(1) "2" + [3]=> + string(5) "jones" +} +===DONE=== diff --git a/ext/oci8/tests/edition_1.phpt b/ext/oci8/tests/edition_1.phpt index 9a4b0f3b61ea2..b9c8fd817ef87 100644 --- a/ext/oci8/tests/edition_1.phpt +++ b/ext/oci8/tests/edition_1.phpt @@ -4,26 +4,17 @@ Basic test for setting Oracle 11gR2 "edition" attribute (11\.2|12)/', $phpinfo); - if ($iv != 1) { - die ("skip tests a feature that works only with Oracle 11gR2 or greater version of client"); - } } -else { - die ("skip tests a feature that works only with Oracle 11gR2 or greater version of server"); +if (preg_match('/Release (1[1]\.2|12)\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 11gR2 or greater databases"); +} else if (preg_match('/^(11\.2|12)\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } - ?> --FILE-- (11\.2|12)/', $phpinfo); - if ($iv != 1) { - die ("skip tests a feature that works only with Oracle 11gR2 or greater version of client"); - } -} -else { - die ("skip tests a feature that works only with Oracle 11gR2 or greater version of server"); +if (preg_match('/Release (1[1]\.2|12)\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 11gR2 or greater databases"); +} else if (preg_match('/^(11\.2|12)\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } ?> diff --git a/ext/oci8/tests/error.phpt b/ext/oci8/tests/error.phpt index 743820f901666..7fedd0ddad6dc 100644 --- a/ext/oci8/tests/error.phpt +++ b/ext/oci8/tests/error.phpt @@ -1,17 +1,20 @@ --TEST-- -oci_error() +oci_error() error message for parsing error --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs: different error messages from TimesTen +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- int(900) ["message"]=> - string(32) "ORA-00900: invalid SQL statement" + string(%d) "ORA-00900: %s" ["offset"]=> int(0) ["sqltext"]=> diff --git a/ext/oci8/tests/error1.phpt b/ext/oci8/tests/error1.phpt index 25a3f09e92d36..c6fba2e83bfb3 100644 --- a/ext/oci8/tests/error1.phpt +++ b/ext/oci8/tests/error1.phpt @@ -12,13 +12,13 @@ echo "Done\n"; ?> --EXPECTF-- -Warning: oci_connect(): ORA-12154: TNS:could not resolve %s in %s on line %d +Warning: oci_connect(): ORA-12154: %s in %s on line %d bool(false) array(4) { ["code"]=> int(12154) ["message"]=> - string(%d) "ORA-12154: TNS:could not resolve %s" + string(%d) "ORA-12154: %s" ["offset"]=> int(0) ["sqltext"]=> diff --git a/ext/oci8/tests/error2.phpt b/ext/oci8/tests/error2.phpt index 13ea6cebe299b..12eab61a6a9ea 100644 --- a/ext/oci8/tests/error2.phpt +++ b/ext/oci8/tests/error2.phpt @@ -1,11 +1,15 @@ --TEST-- Exercise error code for SUCCESS_WITH_INFO --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); +?> --FILE-- --EXPECTF-- -ORA-24344: success with compilation error +ORA-24344: %s Done diff --git a/ext/oci8/tests/error_bind.phpt b/ext/oci8/tests/error_bind.phpt index ad66ad59fee73..6ee26ee82501c 100644 --- a/ext/oci8/tests/error_bind.phpt +++ b/ext/oci8/tests/error_bind.phpt @@ -65,6 +65,6 @@ Test 3 - Resource mismatch !! Warning: oci_bind_by_name(): Invalid variable used for bind in %s on line %d -Warning: oci_execute(): ORA-01008: %s on line %d +Warning: oci_execute(): ORA-%r(01008|57000)%r: %s on line %d bool(false) Done diff --git a/ext/oci8/tests/error_old.phpt b/ext/oci8/tests/error_old.phpt index a6889c897a7ad..c6f9cd300d3db 100644 --- a/ext/oci8/tests/error_old.phpt +++ b/ext/oci8/tests/error_old.phpt @@ -1,17 +1,20 @@ --TEST-- ocierror() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs: different error messages from TimesTen +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- int(900) ["message"]=> - string(32) "ORA-00900: invalid SQL statement" + string(%d) "ORA-00900: %s" ["offset"]=> int(0) ["sqltext"]=> diff --git a/ext/oci8/tests/error_parse.phpt b/ext/oci8/tests/error_parse.phpt index 8100e31706491..458df8715a9a2 100644 --- a/ext/oci8/tests/error_parse.phpt +++ b/ext/oci8/tests/error_parse.phpt @@ -104,7 +104,7 @@ array(4) { ["code"]=> int(1756) ["message"]=> - string(48) "ORA-01756: quoted string not properly terminated" + string(48) "ORA-01756: %s" ["offset"]=> int(0) ["sqltext"]=> @@ -115,7 +115,7 @@ array(4) { ["code"]=> int(1756) ["message"]=> - string(48) "ORA-01756: quoted string not properly terminated" + string(48) "ORA-01756: %s" ["offset"]=> int(0) ["sqltext"]=> @@ -126,17 +126,17 @@ array(4) { ["code"]=> int(1756) ["message"]=> - string(48) "ORA-01756: quoted string not properly terminated" + string(48) "ORA-01756: %s" ["offset"]=> int(0) ["sqltext"]=> string(0) "" } No connection: error: bool(false) -Normal connection (take #2): Parse error: ORA-01756: quoted string not properly terminated -New connection (take #2): Parse error: ORA-01756: quoted string not properly terminated -Persistent connection (take #2): Parse error: ORA-01756: quoted string not properly terminated +Normal connection (take #2): Parse error: ORA-01756: %s +New connection (take #2): Parse error: ORA-01756: %s +Persistent connection (take #2): Parse error: ORA-01756: %s Normal connection: New Collection error: OCI-22303: type ""."ABC" not found -New connection (take #3): Parse error: ORA-01756: quoted string not properly terminated -Persistent connection (take #3): Parse error: ORA-01756: quoted string not properly terminated +New connection (take #3): Parse error: ORA-01756: %s +Persistent connection (take #3): Parse error: ORA-01756: %s Done diff --git a/ext/oci8/tests/exec_fetch.phpt b/ext/oci8/tests/exec_fetch.phpt index 83aae69f7dc98..52d515ffc4c6c 100644 --- a/ext/oci8/tests/exec_fetch.phpt +++ b/ext/oci8/tests/exec_fetch.phpt @@ -16,9 +16,9 @@ var_dump(oci_fetch_array($stmt)); echo "Done\n"; ?> --EXPECTF-- -Warning: oci_execute(): ORA-00942: table or view does not exist in %s on line %d +Warning: oci_execute(): ORA-00942: %s in %s on line %d bool(false) -Warning: oci_fetch_array(): ORA-24374: define not done before fetch or execute and fetch in %s on line %d +Warning: oci_fetch_array(): ORA-24374: %s in %s on line %d bool(false) Done diff --git a/ext/oci8/tests/fetch.phpt b/ext/oci8/tests/fetch.phpt index 520632494084a..e48aeefd87b61 100644 --- a/ext/oci8/tests/fetch.phpt +++ b/ext/oci8/tests/fetch.phpt @@ -17,23 +17,7 @@ $stmtarray = array( "insert into fetch_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -58,11 +42,7 @@ $stmtarray = array( "drop table fetch_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/fetch_all.phpt b/ext/oci8/tests/fetch_all.phpt index a007bac830088..4fc41daad482f 100644 --- a/ext/oci8/tests/fetch_all.phpt +++ b/ext/oci8/tests/fetch_all.phpt @@ -17,18 +17,7 @@ $stmtarray = array( "insert into fetch_all_tab (id, value) values (1,1)" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); if (!($s = oci_parse($c, "select * from fetch_all_tab"))) { die("oci_parse(select) failed!\n"); @@ -55,10 +44,7 @@ $stmtarray = array( "drop table fetch_all_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/fetch_all1.phpt b/ext/oci8/tests/fetch_all1.phpt new file mode 100644 index 0000000000000..4fc41daad482f --- /dev/null +++ b/ext/oci8/tests/fetch_all1.phpt @@ -0,0 +1,94 @@ +--TEST-- +oci_fetch_all() +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +int(3) +array(2) { + [%u|b%"ID"]=> + array(3) { + [0]=> + %unicode|string%(1) "1" + [1]=> + %unicode|string%(1) "1" + [2]=> + %unicode|string%(1) "1" + } + [%u|b%"VALUE"]=> + array(3) { + [0]=> + %unicode|string%(1) "1" + [1]=> + %unicode|string%(1) "1" + [2]=> + %unicode|string%(1) "1" + } +} +int(3) +array(2) { + [%u|b%"ID"]=> + array(3) { + [0]=> + %unicode|string%(1) "1" + [1]=> + %unicode|string%(1) "1" + [2]=> + %unicode|string%(1) "1" + } + [%u|b%"VALUE"]=> + array(3) { + [0]=> + %unicode|string%(1) "1" + [1]=> + %unicode|string%(1) "1" + [2]=> + %unicode|string%(1) "1" + } +} +Done diff --git a/ext/oci8/tests/fetch_all2.phpt b/ext/oci8/tests/fetch_all2.phpt index ff44cac70d5f5..483e51573d3ac 100644 --- a/ext/oci8/tests/fetch_all2.phpt +++ b/ext/oci8/tests/fetch_all2.phpt @@ -1,7 +1,10 @@ --TEST-- oci_fetch_all() - 2 --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- diff --git a/ext/oci8/tests/fetch_all4.phpt b/ext/oci8/tests/fetch_all4.phpt index 9b82262e3f806..1d3c9677ee9c6 100644 --- a/ext/oci8/tests/fetch_all4.phpt +++ b/ext/oci8/tests/fetch_all4.phpt @@ -15,21 +15,7 @@ $stmtarray = array( "insert into fetch_all4_tab values (1, 'abc')" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - , 2289 // sequence does not exist - , 4080 // trigger does not exist - , 38802 // edition does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -56,12 +42,7 @@ $stmtarray = array( "drop table fetch_all4_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); ?> ===DONE=== diff --git a/ext/oci8/tests/fetch_all5.phpt b/ext/oci8/tests/fetch_all5.phpt index bb9061a4458d8..a6bb3c3f18a0d 100644 --- a/ext/oci8/tests/fetch_all5.phpt +++ b/ext/oci8/tests/fetch_all5.phpt @@ -17,21 +17,7 @@ $stmtarray = array( "insert into fetch_all5_tab values (3, 'ghi')" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - , 2289 // sequence does not exist - , 4080 // trigger does not exist - , 38802 // edition does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -65,10 +51,7 @@ $stmtarray = array( "drop table fetch_all5_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); oci_close($c); diff --git a/ext/oci8/tests/fetch_array.phpt b/ext/oci8/tests/fetch_array.phpt index e2f32483d58a3..db5c6c554b9be 100644 --- a/ext/oci8/tests/fetch_array.phpt +++ b/ext/oci8/tests/fetch_array.phpt @@ -1,7 +1,10 @@ --TEST-- oci_fetch_array() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- --EXPECT-- +Test 1 array(10) { [0]=> string(1) "1" @@ -143,6 +168,7 @@ array(10) { ["STRING"]=> NULL } +Test 2 array(2) { [0]=> string(1) "1" @@ -161,6 +187,7 @@ array(2) { [1]=> string(1) "1" } +Test 3 array(2) { ["ID"]=> string(1) "1" @@ -179,6 +206,7 @@ array(2) { ["VALUE"]=> string(1) "1" } +Test 4 array(4) { [0]=> string(1) "1" @@ -209,6 +237,7 @@ array(4) { ["VALUE"]=> string(1) "1" } +Test 5 array(4) { [0]=> string(1) "1" @@ -239,6 +268,7 @@ array(4) { ["VALUE"]=> string(1) "1" } +Test 6 array(10) { [0]=> string(1) "1" @@ -305,4 +335,42 @@ array(10) { ["STRING"]=> NULL } +Test 7 +array(5) { + [0]=> + string(1) "1" + [1]=> + string(1) "1" + [2]=> + NULL + [3]=> + NULL + [4]=> + NULL +} +array(5) { + [0]=> + string(1) "1" + [1]=> + string(1) "1" + [2]=> + NULL + [3]=> + NULL + [4]=> + NULL +} +array(5) { + [0]=> + string(1) "1" + [1]=> + string(1) "1" + [2]=> + NULL + [3]=> + NULL + [4]=> + NULL +} Done + diff --git a/ext/oci8/tests/fetch_assoc.phpt b/ext/oci8/tests/fetch_assoc.phpt index 7dacf2e5b257e..5c4c91e1d8aa0 100644 --- a/ext/oci8/tests/fetch_assoc.phpt +++ b/ext/oci8/tests/fetch_assoc.phpt @@ -1,30 +1,23 @@ --TEST-- oci_fetch_assoc() --SKIPIF-- - + --FILE-- --EXPECT-- -array(5) { +array(3) { ["ID"]=> string(1) "1" ["VALUE"]=> string(1) "1" - ["BLOB"]=> - NULL - ["CLOB"]=> - NULL - ["STRING"]=> + ["DUMMY"]=> NULL } -array(5) { +array(3) { ["ID"]=> string(1) "1" ["VALUE"]=> string(1) "1" - ["BLOB"]=> - NULL - ["CLOB"]=> - NULL - ["STRING"]=> + ["DUMMY"]=> NULL } -array(5) { +array(3) { ["ID"]=> string(1) "1" ["VALUE"]=> string(1) "1" - ["BLOB"]=> - NULL - ["CLOB"]=> - NULL - ["STRING"]=> + ["DUMMY"]=> NULL } Done diff --git a/ext/oci8/tests/fetch_into.phpt b/ext/oci8/tests/fetch_into.phpt index 17e06e1cf8c98..45a6a8132ed12 100644 --- a/ext/oci8/tests/fetch_into.phpt +++ b/ext/oci8/tests/fetch_into.phpt @@ -17,23 +17,7 @@ $stmtarray = array( "insert into fetch_into_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -61,11 +45,8 @@ $stmtarray = array( "drop table fetch_into_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - +oci8_test_sql_execute($c, $stmtarray); + echo "Done\n"; ?> --EXPECTF-- diff --git a/ext/oci8/tests/fetch_into1.phpt b/ext/oci8/tests/fetch_into1.phpt index 263590d14014f..8f7a6bdeb860c 100644 --- a/ext/oci8/tests/fetch_into1.phpt +++ b/ext/oci8/tests/fetch_into1.phpt @@ -1,7 +1,10 @@ --TEST-- various ocifetchinto() tests --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- CASESENSITIVE . "\n"; // Clean up $stmtarray = array( - "drop table fetch_object_tab" + "drop table fetch_object_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); ?> ===DONE=== diff --git a/ext/oci8/tests/fetch_object_1.phpt b/ext/oci8/tests/fetch_object_1.phpt new file mode 100644 index 0000000000000..4f14a5ec0415b --- /dev/null +++ b/ext/oci8/tests/fetch_object_1.phpt @@ -0,0 +1,123 @@ +--TEST-- +oci_fetch_object() +--SKIPIF-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- +caseSensitive . "\n"; + echo $row->SECONDCOL . "\n"; + echo $row->ANOTHERCOL . "\n"; +} + +echo "Test 3\n"; + +if (!($s = oci_parse($c, 'select * from fetch_object_tab where rownum < 2 order by "caseSensitive"'))) { + die("oci_parse(select) failed!\n"); +} + +if (!oci_execute($s)) { + die("oci_execute(select) failed!\n"); +} + +$row = oci_fetch_object($s); +echo $row->caseSensitive . "\n"; +echo $row->CASESENSITIVE . "\n"; + +// Clean up + +$stmtarray = array( + "drop table fetch_object_tab" +); + +oci8_test_sql_execute($c, $stmtarray); + +?> +===DONE=== + +--EXPECTF-- +Test 1 +object(stdClass)#%d (3) { + ["caseSensitive"]=> + string(3) "123" + ["SECONDCOL"]=> + string(19) "1st row col2 string" + ["ANOTHERCOL"]=> + string(15) "1 more text " +} +object(stdClass)#%d (3) { + ["caseSensitive"]=> + string(3) "456" + ["SECONDCOL"]=> + string(19) "2nd row col2 string" + ["ANOTHERCOL"]=> + string(15) "2 more text " +} +object(stdClass)#%d (3) { + ["caseSensitive"]=> + string(3) "789" + ["SECONDCOL"]=> + string(19) "3rd row col2 string" + ["ANOTHERCOL"]=> + string(15) "3 more text " +} +Test 2 +123 +1st row col2 string +1 more text +456 +2nd row col2 string +2 more text +789 +3rd row col2 string +3 more text +Test 3 +123 + +Notice: Undefined property: stdClass::$CASESENSITIVE in %sfetch_object_1.php on line %d + +===DONE=== diff --git a/ext/oci8/tests/fetch_object_2.phpt b/ext/oci8/tests/fetch_object_2.phpt index b078ebb1d360c..1814446aa8805 100644 --- a/ext/oci8/tests/fetch_object_2.phpt +++ b/ext/oci8/tests/fetch_object_2.phpt @@ -1,7 +1,10 @@ --TEST-- oci_fetch_object() with CLOB and NULL --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- ===DONE=== @@ -82,37 +68,37 @@ foreach ($stmtarray as $stmt) { --EXPECTF-- Test 1 object(stdClass)#%d (3) { - [%u|b%"COL1"]=> - %unicode|string%(3) "123" - [%u|b%"COL2"]=> + ["COL1"]=> + string(3) "123" + ["COL2"]=> object(OCI-Lob)#%d (1) { - [%u|b%"descriptor"]=> + ["descriptor"]=> resource(%d) of type (oci8 descriptor) } - [%u|b%"COL3"]=> - %unicode|string%(11) "1 more text" + ["COL3"]=> + string(11) "1 more text" } object(stdClass)#%d (3) { - [%u|b%"COL1"]=> - %unicode|string%(3) "456" - [%u|b%"COL2"]=> + ["COL1"]=> + string(3) "456" + ["COL2"]=> object(OCI-Lob)#%d (1) { - [%u|b%"descriptor"]=> + ["descriptor"]=> resource(%d) of type (oci8 descriptor) } - [%u|b%"COL3"]=> + ["COL3"]=> NULL } object(stdClass)#%d (3) { - [%u|b%"COL1"]=> - %unicode|string%(3) "789" - [%u|b%"COL2"]=> + ["COL1"]=> + string(3) "789" + ["COL2"]=> object(OCI-Lob)#%d (1) { - [%u|b%"descriptor"]=> + ["descriptor"]=> resource(%d) of type (oci8 descriptor) } - [%u|b%"COL3"]=> - %unicode|string%(11) "3 more text" + ["COL3"]=> + string(11) "3 more text" } Test 2 123 diff --git a/ext/oci8/tests/fetch_row.phpt b/ext/oci8/tests/fetch_row.phpt index c6084d4fe2980..2b28634ab3f01 100644 --- a/ext/oci8/tests/fetch_row.phpt +++ b/ext/oci8/tests/fetch_row.phpt @@ -17,23 +17,7 @@ $stmtarray = array( "insert into fetch_row_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -54,10 +38,7 @@ $stmtarray = array( "drop table fetch_row_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/field_funcs.phpt b/ext/oci8/tests/field_funcs.phpt index 18143f6f1bc11..92b77187a81a3 100644 --- a/ext/oci8/tests/field_funcs.phpt +++ b/ext/oci8/tests/field_funcs.phpt @@ -1,7 +1,10 @@ --TEST-- oci_field_*() family --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- + $field) { + $num++; + var_dump(oci_field_is_null($s, $num)); + var_dump(oci_field_name($s, $num)); + var_dump(oci_field_type($s, $num)); + var_dump(oci_field_type_raw($s, $num)); + var_dump(oci_field_scale($s, $num)); + var_dump(oci_field_precision($s, $num)); + var_dump(oci_field_size($s, $num)); +} + + +require dirname(__FILE__).'/drop_table.inc'; + +echo "Done\n"; + +?> +--EXPECT-- +array(5) { + [0]=> + string(1) "1" + [1]=> + string(1) "1" + [2]=> + NULL + [3]=> + NULL + [4]=> + NULL +} +bool(false) +string(2) "ID" +string(6) "NUMBER" +int(2) +int(-127) +int(0) +int(22) +bool(false) +string(5) "VALUE" +string(6) "NUMBER" +int(2) +int(-127) +int(0) +int(22) +bool(true) +string(4) "BLOB" +string(4) "BLOB" +int(113) +int(0) +int(0) +int(4000) +bool(true) +string(4) "CLOB" +string(4) "CLOB" +int(112) +int(0) +int(0) +int(4000) +bool(true) +string(6) "STRING" +string(8) "VARCHAR2" +int(1) +int(0) +int(0) +int(10) +Done diff --git a/ext/oci8/tests/field_funcs1.phpt b/ext/oci8/tests/field_funcs1.phpt index 0b4ad76b393d3..c14ee8957e709 100644 --- a/ext/oci8/tests/field_funcs1.phpt +++ b/ext/oci8/tests/field_funcs1.phpt @@ -1,5 +1,5 @@ --TEST-- -oci_field_*() family +oci_field_*() family: error cases --SKIPIF-- --FILE-- @@ -14,40 +14,25 @@ $stmtarray = array( "create table field_funcs1_tab (id number, value number)", "insert into field_funcs1_tab (id, value) values (1,1)", "insert into field_funcs1_tab (id, value) values (1,1)", - "insert into field_funcs1_tab (id, value) values (1,1)", + "insert into field_funcs1_tab (id, value) values (1,1)" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test if (!($s = oci_parse($c, "select * from field_funcs1_tab"))) { - die("oci_parse(select) failed!\n"); + die("oci_parse(select) failed!\n"); } if (!oci_execute($s)) { - die("oci_execute(select) failed!\n"); + die("oci_execute(select) failed!\n"); } $row = oci_fetch_array($s, OCI_NUM + OCI_RETURN_NULLS + OCI_RETURN_LOBS); var_dump($row); +echo "Test 1\n"; var_dump(oci_field_is_null($s, -1)); var_dump(oci_field_name($s, -1)); var_dump(oci_field_type($s, -1)); @@ -56,6 +41,7 @@ var_dump(oci_field_scale($s, -1)); var_dump(oci_field_precision($s, -1)); var_dump(oci_field_size($s, -1)); +echo "Test 2\n"; var_dump(oci_field_is_null($s, "none")); var_dump(oci_field_name($s, "none")); var_dump(oci_field_type($s, "none")); @@ -64,6 +50,7 @@ var_dump(oci_field_scale($s, "none")); var_dump(oci_field_precision($s, "none")); var_dump(oci_field_size($s, "none")); +echo "Test 3\n"; var_dump(oci_field_is_null($c, -1)); var_dump(oci_field_name($c, -1)); var_dump(oci_field_type($c, -1)); @@ -72,6 +59,7 @@ var_dump(oci_field_scale($c, -1)); var_dump(oci_field_precision($c, -1)); var_dump(oci_field_size($c, -1)); +echo "Test 4\n"; var_dump(oci_field_is_null($s, array())); var_dump(oci_field_name($s, array())); var_dump(oci_field_type($s, array())); @@ -89,10 +77,7 @@ $stmtarray = array( "drop table field_funcs1_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; @@ -104,6 +89,7 @@ array(2) { [1]=> %unicode|string%(1) "1" } +Test 1 Warning: oci_field_is_null(): Invalid column index "-1" in %s on line %d bool(false) @@ -125,6 +111,7 @@ bool(false) Warning: oci_field_size(): Invalid column index "-1" in %s on line %d bool(false) +Test 2 Warning: oci_field_is_null(): Invalid column name "none" in %s on line %d bool(false) @@ -146,6 +133,7 @@ bool(false) Warning: oci_field_size(): Invalid column name "none" in %s on line %d bool(false) +Test 3 Warning: oci_field_is_null(): supplied resource is not a valid oci8 statement resource in %s on line %d bool(false) @@ -167,6 +155,7 @@ bool(false) Warning: oci_field_size(): supplied resource is not a valid oci8 statement resource in %s on line %d bool(false) +Test 4 Warning: oci_field_is_null(): Invalid column index "0" in %s on line %d bool(false) diff --git a/ext/oci8/tests/field_funcs3.phpt b/ext/oci8/tests/field_funcs3.phpt new file mode 100644 index 0000000000000..e51949cf21933 --- /dev/null +++ b/ext/oci8/tests/field_funcs3.phpt @@ -0,0 +1,99 @@ +--TEST-- +oci_field_*() family: basic column types +--SKIPIF-- + +--FILE-- + $field) { + $num++; + var_dump(oci_field_is_null($s, $num)); + var_dump(oci_field_name($s, $num)); + var_dump(oci_field_type($s, $num)); + var_dump(oci_field_type_raw($s, $num)); + var_dump(oci_field_scale($s, $num)); + var_dump(oci_field_precision($s, $num)); + var_dump(oci_field_size($s, $num)); +} + +// Clean up + +$stmtarray = array( + "drop table field_funcs3_tab" +); + +oci8_test_sql_execute($c, $stmtarray); + +?> +===DONE=== + +--EXPECTF-- +array(4) { + [0]=> + string(2) "c1" + [1]=> + string(2) "c2" + [2]=> + string(1) "3" + [3]=> + string(1%r[19]%r) "%r(01-JAN-2010|0001-01-20 10:00:00)%r" +} +bool(false) +string(4) "C1_C" +string(4) "CHAR" +int(96) +int(0) +int(0) +int(2) +bool(false) +string(4) "C2_V" +string(8) "VARCHAR2" +int(1) +int(0) +int(0) +int(2) +bool(false) +string(4) "C3_N" +string(6) "NUMBER" +int(2) +int(-127) +int(0) +int(22) +bool(false) +string(4) "C4_D" +string(4) "DATE" +int(12) +int(0) +int(0) +int(7) +===DONE=== diff --git a/ext/oci8/tests/field_funcs_old.phpt b/ext/oci8/tests/field_funcs_old.phpt index e0d24cd7b7cb1..629c5508f1dac 100644 --- a/ext/oci8/tests/field_funcs_old.phpt +++ b/ext/oci8/tests/field_funcs_old.phpt @@ -1,7 +1,10 @@ --TEST-- ocicolumn*() family --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- Y_}+ic6Kl)3SiV|+SmaGtOKEkbInyERgy}Y7X9u$ zijJ*3AX|&QnBUmu9eKa|-|-m7t7N%~<3Qztmn!3zT3C!2q_Tju7AOl7#PRa={O$aN z+dN zTw`kSt`QW^NoUV<#Zas z>Cv3e_-t`HgG|Wcy$s2N{3&{c(h{z#U!7{>j|zn}s4WO-RhQah9nH#6+`CmC-qF`%a@>zTWFNIr;s3vFb)^&!L5`dSkEF zj;QsCr@qlcSBcO?x^1^umZZmBgF*ZljfS3KnIy0I(fQeZj@t;vYEtvw80)ezn>I+B zXs)VCSd#Kq22Zc+eYegAOKNIYsu4V$QNgn{T+k%01(g zJ4;sQXK!3ZmoC4qsLx>eZn5$m8Kn~F7NrK(N_Xq`U-#~FdZ5lxVIK?C>K#|6zd244e!Kg0d33jdl+ zX-T6|jm|N8Trf~;uvayLn^!Mj@5_R3KJYl8Sr|QI*I%8m&hVUh5dX&cEl&e~oyJ>) zp^xk5K{OsRXs6FFyU%t~w79d;7W1Fow}k)xN_I7K@S`Dn5S8p6b=#r$0^V`@)-COK D)ApFt literal 1305 zcmah|Yj4vq6y+=a6_=2yw$zkvLTI9_(;g|RR@$i#gapV+lUo{=+L`TctI+;Cw)@)H zI`Spb^||NV$GK57j0eLgA~MZ+A;mU}FWW5(`*d7ROUNfc z-{74=p>rv0UXo!(E0*K1!Wd*Z(m-G3B?t*F2pep`8gSgSjIDMjUh|RHMB(*3S7=j} zNM=YmcL2^=t@19FLSSlYxkxLGmyrq+gWM$J0#|SnN|kVZUBD3p?d~A%524*1_6R)x z1+`G8Q=BEW(9>{NPAvdBw$oudvc8^lM)3eB&Puc34oTTAY(E~3`rUT-^A4^}S&n80 z#x(#RZ@dx&4MIX~Y~wQ&# zy;F;H4C7p6e7x}e(=C5BSm_2;@PyT9-{+q4(`_=|VLG=ydXNWRAa0$EIzuZ#ZW6__ z`K+X#1vnUa$E&LF+SVrzi zE)0Fo*1xfo1vP4p%g6^td}NXo+J=_h9;`&`OQq%J=s}%<_sOfxx7w*M&>3@8+W!;o IiJJoX3nQ3( + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- flush()); oci_commit($c); -$select_sql = "SELECT blob FROM ".$schema.$table_name.""; +$select_sql = "select b1 from lob_002_tab where id = 1"; $s = oci_parse($c, $select_sql); oci_execute($s); @@ -40,12 +44,17 @@ $row = oci_fetch_array($s, OCI_RETURN_LOBS); var_dump(strlen($row[0])); +// Cleanup -require dirname(__FILE__).'/drop_table.inc'; +$stmtarray = array( + "drop table lob_002_tab" +); -echo "Done\n"; +oci8_test_sql_execute($c, $stmtarray); ?> +===DONE=== + --EXPECTF-- object(OCI-Lob)#%d (1) { ["descriptor"]=> @@ -63,4 +72,4 @@ Warning: OCI-Lob::seek() expects parameter 1 to be long, string given in %slob_0 NULL bool(false) int(40004) -Done +===DONE=== diff --git a/ext/oci8/tests/lob_003.phpt b/ext/oci8/tests/lob_003.phpt index 8a492d16ca9b89dede69c4f8dc5eed4fb1748030..4775444e27911340f56100b7d7606161d6309e9f 100644 GIT binary patch delta 147 zcmW;AF$%&k6adgkkf3+?gOC=aS=>r1hzf#t2xQHP`F%;m4+%3@~xw^-u(omEj6mbb!{D3SN{@1#mG0g#t0r@ph3=Crc tIUyr#H>?P+(Gw<(r{D%mtlb}uJ8RQS8$SDsZ!;gJwN7)jF5wkFlP^9?FpU5J delta 76 zcmZ3)dxvL&iK9Yhnu3O6YDGzEUU6oAUVKh|VoGX?hI)Q-riHqurb0?)s)kZ=c4mP> WUcLfIPyw!1Nz+=v-frXW=d1wZ{2DL- diff --git a/ext/oci8/tests/lob_004.phpt b/ext/oci8/tests/lob_004.phpt index 32de4a0120058..3f583c67a2e00 100644 --- a/ext/oci8/tests/lob_004.phpt +++ b/ext/oci8/tests/lob_004.phpt @@ -1,7 +1,10 @@ --TEST-- oci_lob_seek()/rewind()/append() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- %SFDhqr%;lSTAZrj;#AC4lv-GtS(K_V w@t}xcadu`wW}04RUb4ETHJ81e!o*rhMxc!7#5LU9KoNvmRYuK?&vvi^0B2-19RL6T delta 120 zcmaFHJCApQO^`xnnu3O6YDGzEUU6oAUVKh|VoGX?hI)Q-riHqurb0?)s)kZ=c4mP> zUcLfIPyw!1Nz+=v-i}LG*Ui(%RackG#=anOV diff --git a/ext/oci8/tests/lob_007.phpt b/ext/oci8/tests/lob_007.phpt index 1fe63092c63fe..1ca236ea28a18 100644 --- a/ext/oci8/tests/lob_007.phpt +++ b/ext/oci8/tests/lob_007.phpt @@ -1,7 +1,10 @@ --TEST-- oci_lob_write()/size()/load() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- resource(%d) of type (oci8 descriptor) diff --git a/ext/oci8/tests/lob_016.phpt b/ext/oci8/tests/lob_016.phpt index 642e7195ef4ec..e0f78e6a9f225 100644 --- a/ext/oci8/tests/lob_016.phpt +++ b/ext/oci8/tests/lob_016.phpt @@ -1,7 +1,10 @@ --TEST-- returning multiple lobs --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- save("data"); oci_commit($c); -$init = "INSERT INTO lob_test (mykey, lob_1) VALUES(2, EMPTY_CLOB()) RETURNING lob_1 INTO :mylob"; +$init = "insert into lob_018_tab (mykey, lob_1) values(2, empty_clob()) returning lob_1 into :mylob"; $statement = oci_parse($c, $init); $clob = oci_new_descriptor($c, OCI_D_LOB); oci_bind_by_name($statement, ":mylob", $clob, -1, OCI_B_CLOB); @@ -34,7 +40,18 @@ $clob->save("long data"); oci_commit($c); -$query = 'SELECT * FROM lob_test ORDER BY mykey ASC'; +$query = 'select * from lob_018_tab order by mykey asc'; +$statement = oci_parse ($c, $query); +oci_execute($statement, OCI_DEFAULT); + +while ($row = oci_fetch_array($statement, OCI_ASSOC)) { + $result = $row['LOB_1']->load(); + var_dump($result); +} + +echo "Test 2\n"; + +$query = 'select * from lob_018_tab order by mykey desc'; $statement = oci_parse ($c, $query); oci_execute($statement, OCI_DEFAULT); @@ -43,7 +60,18 @@ while ($row = oci_fetch_array($statement, OCI_ASSOC)) { var_dump($result); } -$query = 'SELECT * FROM lob_test ORDER BY mykey DESC'; +echo "Test 3 - bind with SQLT_CLOB (an alias for OCI_B_CLOB)\n"; + +$init = "insert into lob_018_tab (mykey, lob_1) values(3, empty_clob()) returning lob_1 into :mylob"; +$statement = oci_parse($c, $init); +$clob = oci_new_descriptor($c, OCI_D_LOB); +oci_bind_by_name($statement, ":mylob", $clob, -1, SQLT_CLOB); +oci_execute($statement, OCI_DEFAULT); +$clob->save("more stuff"); + +oci_commit($c); + +$query = 'select * from lob_018_tab where mykey = 3'; $statement = oci_parse ($c, $query); oci_execute($statement, OCI_DEFAULT); @@ -52,16 +80,24 @@ while ($row = oci_fetch_array($statement, OCI_ASSOC)) { var_dump($result); } -$drop = "DROP table lob_test"; -$statement = oci_parse($c, $drop); -@oci_execute($statement); +// Cleanup + +$stmtarray = array( + "drop table lob_018_tab" +); -echo "Done\n"; +oci8_test_sql_execute($c, $stmtarray); ?> +===DONE=== + --EXPECTF-- +Test 1 string(4) "data" string(9) "long data" +Test 2 string(9) "long data" string(4) "data" -Done +Test 3 - bind with SQLT_CLOB (an alias for OCI_B_CLOB) +string(10) "more stuff" +===DONE=== diff --git a/ext/oci8/tests/lob_019.phpt b/ext/oci8/tests/lob_019.phpt index fb9a3c8188b9ea5013543e111b8111f0ec75250f..19c21f4a78d0cb26292e830e523c3ae2a81a98d9 100644 GIT binary patch delta 147 zcmW;AI|{-;5CG6hkdQ-6A?yYudw`G#{y^{!%O;uVVzSYh*}}@k!otFWmaazc2Co=~@*f*Vjl(IPRy*-;@gO+iC3wW1_7uQ)S5FFq$fF(oxcLp?t^(?VTSQz0cYRYR#bJF`F` WFJA#9r~p^1q-m{SZ@2MO12+KRpBdBu diff --git a/ext/oci8/tests/lob_021.phpt b/ext/oci8/tests/lob_021.phpt index 0ae6b377abb7a..b7489271b9f11 100644 --- a/ext/oci8/tests/lob_021.phpt +++ b/ext/oci8/tests/lob_021.phpt @@ -1,7 +1,10 @@ --TEST-- oci_lob_free()/close() --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +ob_start(); +phpinfo(INFO_MODULES); +$phpinfo = ob_get_clean(); +if (preg_match('/Compile-time ORACLE_HOME/', $phpinfo) !== 1) { + // Assume building PHP with an ORACLE_HOME means the tested DB is on the same machine as PHP + die("skip this test won't work with remote Oracle"); +} ?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- read(), LOB->seek() and LOB->tell() with nul bytes in data --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- write() for multiple inserts --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- diff --git a/ext/oci8/tests/lob_042.phpt b/ext/oci8/tests/lob_042.phpt index 25309d6fc0165..264c610455e08 100644 --- a/ext/oci8/tests/lob_042.phpt +++ b/ext/oci8/tests/lob_042.phpt @@ -1,7 +1,10 @@ --TEST-- Check various LOB error messages --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); if ($stress_test !== true) die ('skip Slow test not run when $stress_test is FALSE'); ?> --FILE-- @@ -22,21 +23,7 @@ $stmtarray = array( end;", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - , 2289 // sequence does not exist - , 4080 // trigger does not exist - , 38802 // edition does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -86,10 +73,7 @@ $stmtarray = array( "drop table lob_043_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); oci_close($c); diff --git a/ext/oci8/tests/lob_044.phpt b/ext/oci8/tests/lob_044.phpt new file mode 100644 index 0000000000000..28599cc33b56e --- /dev/null +++ b/ext/oci8/tests/lob_044.phpt @@ -0,0 +1,73 @@ +--TEST-- +oci_lob_truncate() with default parameter value +--SKIPIF-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> +--FILE-- +write("this is a biiiig faaat test string. why are you reading it, I wonder? =)")); +var_dump($blob->seek(0)); +var_dump($blob->read(10000)); +var_dump($blob->truncate()); +var_dump($blob->seek(0)); +var_dump($blob->read(10000)); + +oci_commit($c); + + +// Read it back + +echo "\nTest 2 - read it back\n"; + +$s = oci_parse($c, "SELECT blob FROM lob_044_tab FOR UPDATE"); +oci_execute($s, OCI_DEFAULT); +$row = oci_fetch_array($s); +var_dump($row[0]->read(10000)); + +// Clean up + +$stmtarray = array( + "drop table lob_044_tab" +); + +oci8_test_sql_execute($c, $stmtarray); + +?> +===DONE=== + +--EXPECTF-- +Test 1 - truncate on insert +int(72) +bool(true) +string(72) "this is a biiiig faaat test string. why are you reading it, I wonder? =)" +bool(true) +bool(true) +string(0) "" + +Test 2 - read it back +string(0) "" +===DONE=== diff --git a/ext/oci8/tests/lob_aliases.phpt b/ext/oci8/tests/lob_aliases.phpt index faa59bf12ddde..3ece9a5895879 100644 --- a/ext/oci8/tests/lob_aliases.phpt +++ b/ext/oci8/tests/lob_aliases.phpt @@ -1,7 +1,10 @@ --TEST-- LOB method aliases --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --INI-- display_errors = On error_reporting = E_WARNING @@ -19,11 +22,6 @@ oci_execute($s); oci_fetch_all($s, $res); var_dump($res); -echo "Test 2: Invalid use of a null byte\n"; - -$s = oci_parse($c, "select * from du\0al"); -oci_execute($s); - echo "Test 3: Using a null byte in a bind variable name\n"; $s = oci_parse($c, "select * from dual where :bv = 1"); @@ -31,14 +29,6 @@ $bv = 1; oci_bind_by_name($s, ":bv\0:bv", $bv); oci_execute($s); -echo "Test 4: Using a null byte in a bind variable value causing WHERE clause to fail\n"; - -$s = oci_parse($c, "select * from dual where :bv = 'abc'"); -$bv = 'abc\0abc'; -oci_bind_by_name($s, ":bv", $bv); -oci_execute($s); -oci_fetch_all($s, $res); -var_dump($res); ?> ===DONE=== @@ -52,18 +42,9 @@ array(1) { string(1) "X" } } -Test 2: Invalid use of a null byte - -Warning: oci_execute(): ORA-00942: %s in %snull_byte_2.php on line %d Test 3: Using a null byte in a bind variable name Warning: oci_bind_by_name(): ORA-01036: %s in %snull_byte_2.php on line %d Warning: oci_execute(): ORA-01008: %s in %snull_byte_2.php on line %d -Test 4: Using a null byte in a bind variable value causing WHERE clause to fail -array(1) { - ["DUMMY"]=> - array(0) { - } -} ===DONE=== diff --git a/ext/oci8/tests/null_byte_3.phpt b/ext/oci8/tests/null_byte_3.phpt new file mode 100644 index 0000000000000..73d5c26c0b648 --- /dev/null +++ b/ext/oci8/tests/null_byte_3.phpt @@ -0,0 +1,42 @@ +--TEST-- +Null bytes in SQL statements +--SKIPIF-- + +--INI-- +display_errors = On +error_reporting = E_WARNING +--FILE-- + +===DONE=== + +--EXPECTF-- +Test 1: Invalid use of a null byte + +Warning: oci_execute(): ORA-00942: %s in %snull_byte_3.php on line %d +Test 2: Using a null byte in a bind variable value causing WHERE clause to fail +array(1) { + ["DUMMY"]=> + array(0) { + } +} +===DONE=== diff --git a/ext/oci8/tests/num.phpt b/ext/oci8/tests/num.phpt index e9dc6a8ac2d47..0fe85ccddc744 100644 --- a/ext/oci8/tests/num.phpt +++ b/ext/oci8/tests/num.phpt @@ -14,23 +14,7 @@ $stmtarray = array( "create table num_tab (id number, value number)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -181,10 +165,7 @@ $stmtarray = array( "drop table num_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/oci_execute_segfault.phpt b/ext/oci8/tests/oci_execute_segfault.phpt index 9ba7d770fd3b8..59eb8013e9a08 100644 --- a/ext/oci8/tests/oci_execute_segfault.phpt +++ b/ext/oci8/tests/oci_execute_segfault.phpt @@ -1,7 +1,10 @@ --TEST-- oci_execute() segfault after repeated bind of LOB descriptor --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- +--CLEAN-- + --EXPECTF-- diff --git a/ext/oci8/tests/password_2.phpt b/ext/oci8/tests/password_2.phpt index 71423e717bf62..ceba0bba80d9c 100644 --- a/ext/oci8/tests/password_2.phpt +++ b/ext/oci8/tests/password_2.phpt @@ -11,20 +11,15 @@ if ($test_drcp) die("skip password change not supported in DRCP Mode"); --FILE-- +--CLEAN-- + --EXPECTF-- diff --git a/ext/oci8/tests/password_new.phpt b/ext/oci8/tests/password_new.phpt index ba6baa964b8c5..8041699f925e2 100644 --- a/ext/oci8/tests/password_new.phpt +++ b/ext/oci8/tests/password_new.phpt @@ -2,23 +2,16 @@ oci_password_change() --SKIPIF-- true, 'timesten' => false); // test runs on thes +require(dirname(__FILE__).'/skipif.inc'); if (empty($dbase)) die ("skip requires database connection string be set"); if ($test_drcp) die("skip password change not supported in DRCP Mode"); // This test is known to fail with Oracle 10.2.0.4 client libraries // connecting to Oracle Database 11 (Oracle bug 6277160, fixed 10.2.0.5) -$sv = oci_server_version($c); -$sv = preg_match('/Release (11|12)\./', $sv, $matches); -if ($sv === 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 10/', $phpinfo); - if ($iv === 1) { - die ("skip test known to fail using Oracle 10.2.0.4 client libs connecting to Oracle 11 (6277160)"); - } +if (preg_match('/Release (11|12)\./', oci_server_version($c), $matches) === 1 && + preg_match('/^10\.2\.0\.[1234]/', oci_client_version()) === 1) { + die ("skip test known to fail using Oracle 10.2.0.4 client libs connecting to Oracle 11 (6277160)"); } ?> --FILE-- diff --git a/ext/oci8/tests/password_old.phpt b/ext/oci8/tests/password_old.phpt index abcaeb1e56d3c..3ff726d2b7c40 100644 --- a/ext/oci8/tests/password_old.phpt +++ b/ext/oci8/tests/password_old.phpt @@ -2,24 +2,19 @@ ocipasswordchange() --SKIPIF-- true, 'timesten' => false); // test runs on thes +require(dirname(__FILE__).'/skipif.inc'); if (empty($dbase)) die ("skip requires database connection string be set"); if ($test_drcp) die("skip password change not supported in DRCP Mode"); // This test is known to fail with Oracle 10.2.0.4 client libraries // connecting to Oracle Database 11 (Oracle bug 6277160, fixed 10.2.0.5) -$sv = oci_server_version($c); -$sv = preg_match('/Release (11|12)\./', $sv, $matches); -if ($sv === 1) { - ob_start(); - phpinfo(INFO_MODULES); - $phpinfo = ob_get_clean(); - $iv = preg_match('/Oracle .*Version => 10/', $phpinfo); - if ($iv === 1) { - die ("skip test known to fail using Oracle 10.2.0.4 client libs connecting to Oracle 11 (6277160)"); - } +if (preg_match('/Release (11|12)\./', oci_server_version($c), $matches) === 1 && + preg_match('/^10\.2\.0\.[1234]/', oci_client_version()) === 1) { + die ("skip test known to fail using Oracle 10.2.0.4 client libs connecting to Oracle 11 (6277160)"); } + + ?> --FILE-- + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --INI-- memory_limit=10M --FILE-- diff --git a/ext/oci8/tests/pecl_bug10194_blob.phpt b/ext/oci8/tests/pecl_bug10194_blob.phpt index 4c6aa4f1c9df0..38f6d9ed2f7c7 100644 --- a/ext/oci8/tests/pecl_bug10194_blob.phpt +++ b/ext/oci8/tests/pecl_bug10194_blob.phpt @@ -1,22 +1,22 @@ --TEST-- PECL Bug #10194 (segfault in Instant Client when memory_limit is reached inside the callback) --SKIPIF-- - true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platforms only"); -?> +?> --INI-- memory_limit=3M --FILE-- write($string); + $row['BLOB']->write($string); } oci_commit($c); @@ -48,7 +48,7 @@ require dirname(__FILE__).'/drop_table.inc'; echo "Done\n"; ?> ---EXPECTF-- +--EXPECTF-- Before load() Fatal error: Allowed memory size of %d bytes exhausted%s(tried to allocate %d bytes) in %s on line %d diff --git a/ext/oci8/tests/pecl_bug10194_blob_64.phpt b/ext/oci8/tests/pecl_bug10194_blob_64.phpt index 433d586a4ef8c..9ffc03d320376 100644 --- a/ext/oci8/tests/pecl_bug10194_blob_64.phpt +++ b/ext/oci8/tests/pecl_bug10194_blob_64.phpt @@ -2,7 +2,8 @@ PECL Bug #10194 (segfault in Instant Client when memory_limit is reached inside the callback) --SKIPIF-- true, 'timesten' => false); // test runs on thes +require(dirname(__FILE__).'/skipif.inc'); if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platforms only"); ?> --INI-- diff --git a/ext/oci8/tests/pecl_bug16035.phpt b/ext/oci8/tests/pecl_bug16035.phpt index fc91bc91bcaa6..29ff6439d1c8a 100644 --- a/ext/oci8/tests/pecl_bug16035.phpt +++ b/ext/oci8/tests/pecl_bug16035.phpt @@ -1,5 +1,5 @@ --TEST-- -PECL Bug #16035 (Crash with Oracle 10.2 connecting with a character set but ORACLE_HOME isn't set) +PECL Bug #16035 (Crash with Oracle 10.2 connecting with a character set but ORACLE_HOME is not set) --SKIPIF-- --EXPECTF-- Warning: oci_connect(): OCIEnvNlsCreate() failed. There is something wrong with your system - please check that ORACLE_HOME and %s are set and point to the right directories in %s on line %d + +Warning: oci_connect(): Error while trying to retrieve text for error ORA-01804 + in %specl_bug16035.php on line %d ===DONE=== diff --git a/ext/oci8/tests/pecl_bug16842.phpt b/ext/oci8/tests/pecl_bug16842.phpt index d796d2506e763..dbf7e6bb83c4e 100644 --- a/ext/oci8/tests/pecl_bug16842.phpt +++ b/ext/oci8/tests/pecl_bug16842.phpt @@ -1,7 +1,10 @@ --TEST-- PECL Bug #16842 (NO_DATA_FOUND exception is a warning) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --INI-- error_reporting = E_WARNING --FILE-- @@ -39,15 +42,15 @@ Raises NO_DATA_FOUND Warning: oci_execute(): OCI_NO_DATA in %s on line 11 bool(false) array(4) { - [%u|b%"code"]=> + ["code"]=> int(1403) - [%u|b%"message"]=> - %unicode|string%(45) "ORA-01403: %s + ["message"]=> + string(%d) "ORA-01403: %s ORA-06512: at line 1" - [%u|b%"offset"]=> + ["offset"]=> int(0) - [%u|b%"sqltext"]=> - %unicode|string%(31) "begin raise NO_DATA_FOUND; end;" + ["sqltext"]=> + string(31) "begin raise NO_DATA_FOUND; end;" } Test 2 Raises ZERO_DIVIDE @@ -56,14 +59,14 @@ Warning: oci_execute(): ORA-01476: %s ORA-06512: at line 1 in %s on line 19 bool(false) array(4) { - [%u|b%"code"]=> + ["code"]=> int(1476) - [%u|b%"message"]=> - %unicode|string%(56) "ORA-01476: %s + ["message"]=> + string(%d) "ORA-01476: %s ORA-06512: at line 1" - [%u|b%"offset"]=> + ["offset"]=> int(0) - [%u|b%"sqltext"]=> - %unicode|string%(29) "begin raise ZERO_DIVIDE; end;" + ["sqltext"]=> + string(29) "begin raise ZERO_DIVIDE; end;" } ===DONE=== diff --git a/ext/oci8/tests/pecl_bug8816.phpt b/ext/oci8/tests/pecl_bug8816.phpt index c369711fcf07d..71771b21004b7 100644 --- a/ext/oci8/tests/pecl_bug8816.phpt +++ b/ext/oci8/tests/pecl_bug8816.phpt @@ -1,7 +1,10 @@ --TEST-- PECL Bug #8816 (issue in php_oci_statement_fetch with more than one piecewise column) --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- diff --git a/ext/oci8/tests/prefetch_old.phpt b/ext/oci8/tests/prefetch_old.phpt index c2ac8fe8415e9..ac43771c6be1d 100644 --- a/ext/oci8/tests/prefetch_old.phpt +++ b/ext/oci8/tests/prefetch_old.phpt @@ -15,23 +15,7 @@ $stmtarray = array( "insert into prefetch_old_tab (id, value) values (1,1)", ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if (!in_array($m['code'], array( // ignore expected errors - 942 // table or view does not exist - ))) { - echo $stmt . PHP_EOL . $m['message'] . PHP_EOL; - } - } -} - -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); // Run Test @@ -61,10 +45,7 @@ $stmtarray = array( "drop table prefetch_old_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; ?> diff --git a/ext/oci8/tests/refcur_prefetch_1.phpt b/ext/oci8/tests/refcur_prefetch_1.phpt index c603fdd5bb8e4..ea09fbcd979cf 100644 --- a/ext/oci8/tests/refcur_prefetch_1.phpt +++ b/ext/oci8/tests/refcur_prefetch_1.phpt @@ -4,19 +4,10 @@ Prefetch with REF cursor. Test different values for prefetch with oci_set_prefet (11\.2|12\.)/', $phpinfo); -if ($iv == 1) { - $sv = oci_server_version($c); - $sv = preg_match('/Release 1[012]\./', $sv, $matches); - if ($sv != 1) { - die ("skip expected output only valid when using Oracle 10g or greater server"); - } -} -else { - die ("skip expected output only valid when using Oracle 11.2 or greater client"); +if (preg_match('/Release 1[012]\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10g or greater databases"); +} else if (preg_match('/^(11\.2|12)\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } ?> --FILE-- @@ -45,16 +36,7 @@ $stmtarray = array( end refcurpkg;" ); -foreach($stmtarray as $stmt) { - $s = oci_parse($c,$stmt); - $r = @oci_execute($s); - if (!$r) { - $msg = oci_error($s); - if ($msg['code'] != 942) { - echo $msg['message'],"\n"; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Insert 500 rows into the table. $insert_sql = "INSERT INTO refcurtest (c1, c2) VALUES (:c1,:c2)"; @@ -94,7 +76,7 @@ function fetch_frm_php($c,$cur1,$value) { oci_execute($s1); oci_set_prefetch($cur1,$value); oci_execute($cur1); - echo "Fetch Row from PHP\n"; + echo "Fetch Row from PHP\n"; var_dump(oci_fetch_row($cur1)); } @@ -106,14 +88,14 @@ function fetch_frm_plsql($c,$cur1) { if (!oci_bind_by_name($s2,":curs1",$cur1,-1,SQLT_RSET)) { die("oci_bind_by_name(sql2) failed!\n"); } - if (!oci_bind_by_name($s2,":c1",$c1,SQLT_INT)) { + if (!oci_bind_by_name($s2,":c1",$c1,-1,SQLT_INT)) { die("oci_bind_by_name(sql2) failed!\n"); } - if (!oci_bind_by_name($s2,":c2",$c2,SQLT_AFC)) { + if (!oci_bind_by_name($s2,":c2",$c2,20,SQLT_CHR)) { die("oci_bind_by_name(sql2) failed!\n"); } oci_execute($s2); - echo "Fetch Row from PL/SQL\n"; + echo "Fetch Row from PL/SQL\n"; var_dump($c1); var_dump($c2); } @@ -125,132 +107,125 @@ $stmtarray = array( "drop table refcurtest" ); -foreach($stmtarray as $stmt) { - $s = oci_parse($c,$stmt); - $r = @oci_execute($s); - if (!$r) { - $msg = oci_error($s); - echo $msg['message'],"\n"; - } -} -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); + echo "Done\n"; ?> --EXPECTF-- ----------------------------------------------- Test with Prefetch value set to 0 ----------------------------------------------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "1" -%unicode|string%(%d) "test1" +Fetch Row from PL/SQL +int(1) +string(%d) "test1" ----------------------------------------------- Test with Prefetch value set to 1 ----------------------------------------------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "2" -%unicode|string%(%d) "test2" +Fetch Row from PL/SQL +int(2) +string(%d) "test2" ----------------------------------------------- Test with Prefetch value set to 501 ----------------------------------------------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } Warning: oci_execute(): ORA-01002: %s -ORA-06512: at "SYSTEM.REFCURPKG", line %d +ORA-06512: at "%s.REFCURPKG", line %d ORA-06512: at line %d in %s on line %d -Fetch Row from PL/SQL -NULL +Fetch Row from PL/SQL +int(0) NULL ----------------------------------------------- Test with Prefetch value set to 499 ----------------------------------------------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "500" -%unicode|string%(%d) "test500" +Fetch Row from PL/SQL +int(500) +string(%d) "test500" ----------------------------------------------- Test with Prefetch value set to 250 ----------------------------------------------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "251" -%unicode|string%(%d) "test251" +Fetch Row from PL/SQL +int(251) +string(%d) "test251" ----------------------------------------------- Test with Prefetch value set to 12345 ----------------------------------------------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } Warning: oci_execute(): ORA-01002: %s -ORA-06512: at "SYSTEM.REFCURPKG", line %d +ORA-06512: at "%s.REFCURPKG", line %d ORA-06512: at line %d in %s on line %d -Fetch Row from PL/SQL -NULL +Fetch Row from PL/SQL +int(0) NULL ----------------------------------------------- Test with Prefetch value set to -12345 ----------------------------------------------- Warning: oci_set_prefetch(): Number of rows to be prefetched has to be greater than or equal to 0 in %s on line %d -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "101" -%unicode|string%(%d) "test101" +Fetch Row from PL/SQL +int(101) +string(%d) "test101" ----------------------------------------------- Test with Prefetch value set to -1 ----------------------------------------------- Warning: oci_set_prefetch(): Number of rows to be prefetched has to be greater than or equal to 0 in %s on line %d -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(%d) "0" [1]=> - %unicode|string%(%d) "test0" + string(%d) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "101" -%unicode|string%(%d) "test101" +Fetch Row from PL/SQL +int(101) +string(%d) "test101" Done diff --git a/ext/oci8/tests/refcur_prefetch_2.phpt b/ext/oci8/tests/refcur_prefetch_2.phpt index 78ce051756d7f..8d65251077ea3 100644 --- a/ext/oci8/tests/refcur_prefetch_2.phpt +++ b/ext/oci8/tests/refcur_prefetch_2.phpt @@ -4,19 +4,10 @@ Prefetch with REF cursor. Test No 2 (11\.2|12\.)/', $phpinfo); -if ($iv == 1) { - $sv = oci_server_version($c); - $sv = preg_match('/Release 1[012]\./', $sv, $matches); - if ($sv != 1) { - die ("skip expected output only valid when using Oracle 10g or greater server"); - } -} -else { - die ("skip expected output only valid when using Oracle 11.1 or greater client"); +if (preg_match('/Release 1[012]\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 10g or greater databases"); +} else if (preg_match('/^(11\.2|12)\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } ?> --FILE-- @@ -45,16 +36,7 @@ $stmtarray = array( end refcurpkg;" ); -foreach($stmtarray as $stmt) { - $s = oci_parse($c,$stmt); - $r = @oci_execute($s); - if (!$r) { - $msg = oci_error($s); - if ($msg['code'] != 942) { - echo $msg['message'],"\n"; - } - } -} +oci8_test_sql_execute($c, $stmtarray); // Insert 500 rows into the table. $insert_sql = "INSERT INTO refcurtest (c1, c2) VALUES (:c1,:c2)"; @@ -85,13 +67,13 @@ if (!oci_bind_by_name($s1,":cur1",$cur1,-1,SQLT_RSET)) { $sql2 = "begin refcurpkg.fetch_ref_cur(:curs1,:c1,:c2); end;"; $s2 = oci_parse($c,$sql2); -if (!oci_bind_by_name($s2,":curs1",$cur1,-1,SQLT_RSET)) { +if (!oci_bind_by_name($s2, ":curs1", $cur1, -1, SQLT_RSET)) { die("oci_bind_by_name(sql2) failed!\n"); } -if (!oci_bind_by_name($s2,":c1",$c1,SQLT_INT)) { +if (!oci_bind_by_name($s2, ":c1", $c1, -1, SQLT_INT)) { die("oci_bind_by_name(sql2) failed!\n"); } -if (!oci_bind_by_name($s2,":c2",$c2,SQLT_AFC)) { +if (!oci_bind_by_name($s2, ":c2", $c2, 20, SQLT_CHR)) { die("oci_bind_by_name(sql2) failed!\n"); } @@ -124,7 +106,7 @@ if (!oci_bind_by_name($s1,":cur1",$cur1,-1,SQLT_RSET)) { die("oci_bind_by_name(sql1) failed!\n"); } -echo "Fetch Row from PHP\n"; +echo "Fetch Row from PHP\n"; oci_execute($s1); oci_execute($cur1); var_dump(oci_fetch_row($cur1)); @@ -135,55 +117,10 @@ if (!oci_bind_by_name($s2,":curs1",$cur1,-1,SQLT_RSET)) { die("oci_bind_by_name(sql2) failed!\n"); } oci_execute($s2); -echo "Fetch Row from PL/SQL\n"; -var_dump($c1); -var_dump($c2); - -echo "------Test 3 - Set Prefetch after PL/SQL fetch ----------\n"; -$cur1 = oci_new_cursor($c); -// Fetch from PL/SQL -if (!oci_bind_by_name($s2,":curs1",$cur1,-1,SQLT_RSET)) { - die("oci_bind_by_name(sql2) failed!\n"); -} -oci_execute($s2); -echo "Fetch Row from PL/SQL\n"; -var_dump($c1); -var_dump($c2); - -// Fetch from PHP -echo "Fetch Row from PHP\n"; -if (!oci_bind_by_name($s1,":cur1",$cur1,-1,SQLT_RSET)) { - die("oci_bind_by_name(sql1) failed!\n"); -} -oci_set_prefetch($cur1,5); -oci_execute($s1); -oci_execute($cur1); -var_dump(oci_fetch_row($cur1)); - -echo "------Test 4- Overwrite prefetch-----------\n"; -// Fetch from PHP -$cur1 = oci_new_cursor($c); -if (!oci_bind_by_name($s1,":cur1",$cur1,-1,SQLT_RSET)) { - die("oci_bind_by_name(sql1) failed!\n"); -} -echo "Fetch Row from PHP\n"; -oci_execute($s1); -oci_execute($cur1); -var_dump(oci_fetch_row($cur1)); -oci_set_prefetch($cur1,5); -oci_set_prefetch($cur1,0); -oci_set_prefetch($cur1,100); - -// Fetch from PL/SQL -if (!oci_bind_by_name($s2,":curs1",$cur1,-1,SQLT_RSET)) { - die("oci_bind_by_name(sql2) failed!\n"); -} -oci_execute($s2); -echo "Fetch Row from PL/SQL\n"; +echo "Fetch Row from PL/SQL\n"; var_dump($c1); var_dump($c2); - function print_roundtrips($c) { $sql_stmt = "select value from v\$mystat a,v\$statname c where a.statistic#=c.statistic# and c.name='SQL*Net roundtrips to/from client'"; @@ -201,117 +138,83 @@ $stmtarray = array( "drop table refcurtest" ); -foreach($stmtarray as $stmt) { - $s = oci_parse($c,$stmt); - $r = @oci_execute($s); - if (!$r) { - $msg = oci_error($s); - echo $msg['message'],"\n"; - } -} +oci8_test_sql_execute($c, $stmtarray); -oci_close($c); echo "Done\n"; ?> --EXPECTF-- ------Test 1- Check Roundtrips with prefetch 0 and 5 ----------- array(2) { [0]=> - %unicode|string%(%d) "0" + string(1) "0" [1]=> - %unicode|string%(%d) "test0" + string(5) "test0" } array(2) { [0]=> - %unicode|string%(%d) "1" + string(1) "1" [1]=> - %unicode|string%(%d) "test1" + string(5) "test1" } array(2) { [0]=> - %unicode|string%(%d) "2" + string(1) "2" [1]=> - %unicode|string%(%d) "test2" + string(5) "test2" } array(2) { [0]=> - %unicode|string%(%d) "3" + string(1) "3" [1]=> - %unicode|string%(%d) "test3" + string(5) "test3" } array(2) { [0]=> - %unicode|string%(%d) "4" + string(1) "4" [1]=> - %unicode|string%(%d) "test4" + string(5) "test4" } Number of roundtrips made with prefetch count 0 for 5 rows is 6 array(2) { [0]=> - %unicode|string%(%d) "5" + string(1) "5" [1]=> - %unicode|string%(%d) "test5" + string(5) "test5" } array(2) { [0]=> - %unicode|string%(%d) "6" + string(1) "6" [1]=> - %unicode|string%(%d) "test6" + string(5) "test6" } array(2) { [0]=> - %unicode|string%(%d) "7" + string(1) "7" [1]=> - %unicode|string%(%d) "test7" + string(5) "test7" } array(2) { [0]=> - %unicode|string%(%d) "8" + string(1) "8" [1]=> - %unicode|string%(%d) "test8" + string(5) "test8" } array(2) { [0]=> - %unicode|string%(%d) "9" + string(1) "9" [1]=> - %unicode|string%(%d) "test9" + string(5) "test9" } Number of roundtrips made with prefetch count 5 for 5 rows is 2 ------Test 2 - Set Prefetch before PL/SQL fetch ---------- -Fetch Row from PHP -array(2) { - [0]=> - %unicode|string%(%d) "0" - [1]=> - %unicode|string%(%d) "test0" -} -Fetch Row from PL/SQL -%unicode|string%(%d) "101" -%unicode|string%(%d) "test101" -------Test 3 - Set Prefetch after PL/SQL fetch ---------- - -Warning: oci_execute(): ORA-01001: %s -ORA-06512: at "%s.REFCURPKG", line %d -ORA-06512: at line %d in %s on line %d -Fetch Row from PL/SQL -%unicode|string%(%d) "101" -%unicode|string%(%d) "test101" -Fetch Row from PHP -array(2) { - [0]=> - %unicode|string%(%d) "0" - [1]=> - %unicode|string%(%d) "test0" -} -------Test 4- Overwrite prefetch----------- -Fetch Row from PHP +Fetch Row from PHP array(2) { [0]=> - %unicode|string%(%d) "0" + string(1) "0" [1]=> - %unicode|string%(%d) "test0" + string(5) "test0" } -Fetch Row from PL/SQL -%unicode|string%(%d) "101" -%unicode|string%(%d) "test101" +Fetch Row from PL/SQL +int(101) +string(%d) "test101" Done diff --git a/ext/oci8/tests/refcur_prefetch_3.phpt b/ext/oci8/tests/refcur_prefetch_3.phpt index 0666a96e90938..8c0414042b0fc 100644 --- a/ext/oci8/tests/refcur_prefetch_3.phpt +++ b/ext/oci8/tests/refcur_prefetch_3.phpt @@ -6,19 +6,10 @@ oci8.default_prefetch=5 (11\.2|12\.)/', $phpinfo); -if ($iv == 1) { - $sv = oci_server_version($c); - $sv = preg_match('/Release (11\.2|12\.)/', $sv, $matches); - if ($sv != 1) { - die ("skip expected output only valid when using Oracle 11.2 or greater server"); - } -} -else { - die ("skip expected output only valid when using Oracle 11.2 or greater client"); +if (preg_match('/Release (11\.2|12)\./', oci_server_version($c), $matches) !== 1) { + die("skip expected output only valid when using Oracle 11gR2 or greater databases"); +} else if (preg_match('/^(11\.2|12)\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 11gR2 or greater version of client"); } ?> @@ -32,16 +23,8 @@ $stmtarray = array( "create table nescurtest(c1 varchar2(10))" ); -foreach($stmtarray as $stmt) { - $s = oci_parse($c,$stmt); - $r = @oci_execute($s); - if (!$r) { - $msg = oci_error($s); - if ($msg['code'] !=942) { - echo $msg['message'],"\n"; - } - } -} +oci8_test_sql_execute($c, $stmtarray); + // Insert 500 rows into the table. $insert_sql = "INSERT INTO nescurtest (c1) VALUES (:c1)"; if (!($s = oci_parse($c, $insert_sql))) { @@ -92,15 +75,8 @@ $stmtarray = array( "drop table nescurtest" ); -foreach($stmtarray as $stmt) { - $s = oci_parse($c,$stmt); - $r = @oci_execute($s); - if (!$r) { - $msg = oci_error($s); - echo $msg['message'],"\n"; - } -} -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); + echo "Done\n"; ?> --EXPECTF-- diff --git a/ext/oci8/tests/refcur_prefetch_4.phpt b/ext/oci8/tests/refcur_prefetch_4.phpt new file mode 100644 index 0000000000000..d24398c00e6bf --- /dev/null +++ b/ext/oci8/tests/refcur_prefetch_4.phpt @@ -0,0 +1,176 @@ +--TEST-- +Prefetch with REF cursor. Test No 4 +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +------Test 1 - Set Prefetch after PL/SQL fetch ---------- + +Warning: oci_execute(): ORA-01001: %s +ORA-06512: at "SYSTEM.REFCURPKG", line %d +ORA-06512: at line %d in %s on line %d +Fetch Row from PL/SQL +int(0) +NULL +Fetch Row from PHP +array(2) { + [0]=> + string(1) "0" + [1]=> + string(5) "test0" +} +------Test 2- Overwrite prefetch----------- +Fetch Row from PHP +array(2) { + [0]=> + string(1) "0" + [1]=> + string(5) "test0" +} +Fetch Row from PL/SQL +int(101) +string(%d) "test101" +Done diff --git a/ext/oci8/tests/select_null.phpt b/ext/oci8/tests/select_null.phpt index 87c5b815fd242..450c81a877e0e 100644 --- a/ext/oci8/tests/select_null.phpt +++ b/ext/oci8/tests/select_null.phpt @@ -15,11 +15,11 @@ var_dump(oci_fetch_array($stmt, OCI_RETURN_NULLS)); echo "Done\n"; ?> ---EXPECT-- +--EXPECTF-- array(2) { [0]=> NULL - ["NULL"]=> + ["%r(NULL|EXP)%r"]=> NULL } Done diff --git a/ext/oci8/tests/serverversion.phpt b/ext/oci8/tests/serverversion.phpt index bf32fe4b54b42..6cbb5aaad004f 100644 --- a/ext/oci8/tests/serverversion.phpt +++ b/ext/oci8/tests/serverversion.phpt @@ -25,6 +25,6 @@ echo "Done\n"; ?> --EXPECTF-- resource(%d) of type (oci8 connection) -string(%d) "%s" -string(%d) "%s" +string(%d) "Oracle %s" +string(%d) "Oracle %s" Done diff --git a/ext/oci8/tests/skipif.inc b/ext/oci8/tests/skipif.inc index ed0992c8d9c32..0ae2876e2214b 100644 --- a/ext/oci8/tests/skipif.inc +++ b/ext/oci8/tests/skipif.inc @@ -2,9 +2,17 @@ if (!extension_loaded('oci8')) die("skip oci8 extension is not available\n"); -/* - * Remove or comment this line to run tests - * - * */ -die("skip change default login/password\n"); +// Check the test file is valid for this DB type +require(dirname(__FILE__).'/connect.inc'); +$v = oci_server_version($c); +if (strpos($v, 'Oracle Database') !== false) + $dbtype = 'oracledb'; +else if (strpos($v, 'Oracle TimesTen') !== false) + $dbtype = 'timesten'; +else { + die("skip Unknown database type $v\n"); +} +if (!array_key_exists($dbtype, $target_dbs) || $target_dbs[$dbtype] !== true) + die("skip Test not valid for $v\n"); + ?> diff --git a/ext/oci8/tests/statement_cache.phpt b/ext/oci8/tests/statement_cache.phpt index 19e69d4c21c11..4c48d3f1ddec4 100644 --- a/ext/oci8/tests/statement_cache.phpt +++ b/ext/oci8/tests/statement_cache.phpt @@ -1,10 +1,15 @@ --TEST-- statement cache --SKIPIF-- - + true, 'timesten' => true); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- string(1) "4" - ["1+3"]=> + ["%r(1\+3|EXP)%r"]=> string(1) "4" } array(2) { [0]=> string(1) "4" - ["1+3"]=> + ["%r(1\+3|EXP)%r"]=> string(1) "4" } Done diff --git a/ext/oci8/tests/xmltype_01.phpt b/ext/oci8/tests/xmltype_01.phpt index a9458c83d439d..21aca6cc126b7 100644 --- a/ext/oci8/tests/xmltype_01.phpt +++ b/ext/oci8/tests/xmltype_01.phpt @@ -1,8 +1,10 @@ --TEST-- Basic XMLType test --SKIPIF-- - - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); --FILE-- '))" ); -foreach ($stmts as $q) { - $s = oci_parse($c, $q); - $r = @oci_execute($s); - if (!$r) { - $m = oci_error($s); - if ($m['code'] != 942) { // table or view doesn't exist - echo $m['message'], "\n"; - } - } -} +oci8_test_sql_execute($c, $stmtarray); function do_query($c) { @@ -78,14 +71,11 @@ $data = do_query($c); // Cleanup -$stmts = array( +$stmtarray = array( "drop table xtt", ); -foreach ($stmts as $q) { - $s = oci_parse($c, $q); - @oci_execute($s); -} +oci8_test_sql_execute($c, $stmtarray); echo "Done\n"; diff --git a/ext/oci8/tests/xmltype_02.phpt b/ext/oci8/tests/xmltype_02.phpt index 9b6fa8ad3294d..83b4123067d4d 100644 --- a/ext/oci8/tests/xmltype_02.phpt +++ b/ext/oci8/tests/xmltype_02.phpt @@ -1,7 +1,10 @@ --TEST-- Basic XMLType test #2 --SKIPIF-- - + true, 'timesten' => false); // test runs on these DBs +require(dirname(__FILE__).'/skipif.inc'); +?> --FILE-- free(); // Clean up -//require(dirname(__FILE__).'/drop_table.inc'); - $stmtarray = array( "drop table xmltype_02_tab" ); -foreach ($stmtarray as $stmt) { - $s = oci_parse($c, $stmt); - oci_execute($s); -} - -oci_close($c); +oci8_test_sql_execute($c, $stmtarray); ?> ===DONE=== @@ -130,57 +113,57 @@ Test 1 Insert new XML data using a temporary CLOB array(1) { [0]=> object(OCI-Lob)#%d (1) { - [%u|b%"descriptor"]=> + ["descriptor"]=> resource(%d) of type (oci8 descriptor) } } Test 2 Manipulate the data using SimpleXML object(SimpleXMLElement)#%d (10) { - [%u|b%"WarehouseId"]=> - %unicode|string%(1) "1" - [%u|b%"WarehouseName"]=> - %unicode|string%(16) "Southlake, Texas" - [%u|b%"Building"]=> - %unicode|string%(5) "Owned" - [%u|b%"Area"]=> - %unicode|string%(5) "25000" - [%u|b%"Docks"]=> - %unicode|string%(1) "2" - [%u|b%"DockType"]=> - %unicode|string%(9) "Rear load" - [%u|b%"WaterAccess"]=> - %unicode|string%(4) "true" - [%u|b%"RailAccess"]=> - %unicode|string%(1) "N" - [%u|b%"Parking"]=> - %unicode|string%(6) "Street" - [%u|b%"VClearance"]=> - %unicode|string%(2) "10" + ["WarehouseId"]=> + string(1) "1" + ["WarehouseName"]=> + string(16) "Southlake, Texas" + ["Building"]=> + string(5) "Owned" + ["Area"]=> + string(5) "25000" + ["Docks"]=> + string(1) "2" + ["DockType"]=> + string(9) "Rear load" + ["WaterAccess"]=> + string(4) "true" + ["RailAccess"]=> + string(1) "N" + ["Parking"]=> + string(6) "Street" + ["VClearance"]=> + string(2) "10" } object(SimpleXMLElement)#%d (10) { - [%u|b%"WarehouseId"]=> - %unicode|string%(1) "1" - [%u|b%"WarehouseName"]=> - %unicode|string%(16) "Southlake, Texas" - [%u|b%"Building"]=> - %unicode|string%(5) "Owned" - [%u|b%"Area"]=> - %unicode|string%(5) "25000" - [%u|b%"Docks"]=> - %unicode|string%(1) "1" - [%u|b%"DockType"]=> - %unicode|string%(9) "Rear load" - [%u|b%"WaterAccess"]=> - %unicode|string%(4) "true" - [%u|b%"RailAccess"]=> - %unicode|string%(1) "N" - [%u|b%"Parking"]=> - %unicode|string%(6) "Street" - [%u|b%"VClearance"]=> - %unicode|string%(2) "10" + ["WarehouseId"]=> + string(1) "1" + ["WarehouseName"]=> + string(16) "Southlake, Texas" + ["Building"]=> + string(5) "Owned" + ["Area"]=> + string(5) "25000" + ["Docks"]=> + string(1) "1" + ["DockType"]=> + string(9) "Rear load" + ["WaterAccess"]=> + string(4) "true" + ["RailAccess"]=> + string(1) "N" + ["Parking"]=> + string(6) "Street" + ["VClearance"]=> + string(2) "10" } Test 3: Update changes using a temporary CLOB -%unicode|string%(331) " +string(331) " 1 Southlake, Texas From 4329ae1e26950ff1509d327e296b511f54c637ae Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Fri, 10 Jun 2011 20:01:46 +0000 Subject: [PATCH 0140/2394] Bump OCI8 version to stable in preparation for 5.3.7 RC --- ext/oci8/package.xml | 63 +++++++++++++++++++++++++++++++++++++------- ext/oci8/php_oci8.h | 2 +- 2 files changed, 54 insertions(+), 11 deletions(-) diff --git a/ext/oci8/package.xml b/ext/oci8/package.xml index 5c15108a35d88..0bb6eb532bf34 100644 --- a/ext/oci8/package.xml +++ b/ext/oci8/package.xml @@ -33,12 +33,12 @@ http://pear.php.net/dtd/package-2.0.xsd"> no - 2010-12-09 - + 2011-06-10 + - 1.4.5 - 1.4.5 + 1.4.6 + 1.4.6 stable @@ -46,7 +46,8 @@ http://pear.php.net/dtd/package-2.0.xsd"> PHP - Protect against null bytes in LOB filenames (http://news.php.net/php.internals/50202) + Added oci_client_version() returning the runtime Oracle client library version + Made OCI8 extension buildable with PHP 5.4-development code @@ -87,8 +88,20 @@ http://pear.php.net/dtd/package-2.0.xsd"> + + + + + + + + + + + + @@ -125,8 +138,12 @@ http://pear.php.net/dtd/package-2.0.xsd"> + - + + + + @@ -193,15 +210,19 @@ http://pear.php.net/dtd/package-2.0.xsd"> + + + + @@ -225,6 +246,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> + @@ -239,6 +261,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> + @@ -249,12 +272,15 @@ http://pear.php.net/dtd/package-2.0.xsd"> + + + @@ -302,6 +328,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> + @@ -309,6 +336,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> + @@ -333,6 +361,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> + @@ -366,8 +395,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> 4.3.9 - 6.0.0 - 6.0.0 + 5.4.99 1.4.0b1 @@ -380,6 +408,21 @@ http://pear.php.net/dtd/package-2.0.xsd"> + + + 1.4.5 + 1.4.5 + + + stable + stable + + PHP + + Protect against null bytes in LOB filenames (http://news.php.net/php.internals/50202) + + + 1.4.4 @@ -464,7 +507,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> oci_set_action oci_set_client_info oci_set_client_identifier - + These set values that are visible/used by the database. They are useful for tracing, authentication and auditing. @@ -493,7 +536,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> oci_bind_by_name 7. Bug fixes: - PECL bug #16842 (oci_error returns false when NO_DATA_FOUND is raised) + PECL bug #16842 (oci_error returns false when NO_DATA_FOUND is raised) diff --git a/ext/oci8/php_oci8.h b/ext/oci8/php_oci8.h index bcb12a7bd86ed..427ca59abeeb5 100644 --- a/ext/oci8/php_oci8.h +++ b/ext/oci8/php_oci8.h @@ -46,7 +46,7 @@ */ #undef PHP_OCI8_VERSION #endif -#define PHP_OCI8_VERSION "1.4.6-dev" +#define PHP_OCI8_VERSION "1.4.6" extern zend_module_entry oci8_module_entry; #define phpext_oci8_ptr &oci8_module_entry From ddd88ff93c385e6e986809756160f8f4fa1d608f Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 10 Jun 2011 22:48:36 +0000 Subject: [PATCH 0141/2394] - Fixed bug #55028 (// is abad comment) --- ext/openssl/xp_ssl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c index 4de8825e3dbe8..e4b101ef6adcf 100644 --- a/ext/openssl/xp_ssl.c +++ b/ext/openssl/xp_ssl.c @@ -145,7 +145,7 @@ static int handle_ssl_error(php_stream *stream, int nr_bytes, zend_bool is_init default: do { - // NULL is automatically added + /* NULL is automatically added */ ERR_error_string_n(ecode, esbuf, sizeof(esbuf)); if (ebuf.c) { smart_str_appendc(&ebuf, '\n'); From b8d10158d18d47a637b62bac7416b4f54bdcc01e Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 10 Jun 2011 23:14:15 +0000 Subject: [PATCH 0142/2394] - Drop C++ style comments --- ext/pdo_pgsql/pgsql_driver.c | 4 ++-- ext/spl/spl_observer.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c index 45f05fa2c7656..5d3c081680721 100644 --- a/ext/pdo_pgsql/pgsql_driver.c +++ b/ext/pdo_pgsql/pgsql_driver.c @@ -542,7 +542,7 @@ static PHP_METHOD(PDO, pgsqlCopyFromArray) spprintf(&query, 0, "COPY %s FROM STDIN DELIMITERS E'%c' WITH NULL AS E'%s'", table_name, (pg_delim_len ? *pg_delim : '\t'), (pg_null_as_len ? pg_null_as : "\\\\N")); } - // Obtain db Handle + /* Obtain db Handle */ H = (pdo_pgsql_db_handle *)dbh->driver_data; while ((pgsql_result = PQgetResult(H->server))) { @@ -634,7 +634,7 @@ static PHP_METHOD(PDO, pgsqlCopyFromFile) return; } - // Obtain db Handler + /* Obtain db Handler */ dbh = zend_object_store_get_object(getThis() TSRMLS_CC); PDO_CONSTRUCT_CHECK; diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c index f1a0f3161a91e..2c0c4bcc5c6c2 100755 --- a/ext/spl/spl_observer.c +++ b/ext/spl/spl_observer.c @@ -170,7 +170,7 @@ static void spl_object_storage_free_hash(spl_SplObjectStorage *intern, char *has efree(hash); } else { #if HAVE_PACKED_OBJECT_VALUE - // Nothing to do + /* Nothing to do */ #else efree(hash); #endif From 9c81d0523899c44aad849bd24f2bebde5d8e370c Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Sat, 11 Jun 2011 00:24:26 +0000 Subject: [PATCH 0143/2394] Fix TSRMLS for Windows build --- ext/oci8/oci8.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index e1b0077c68f9c..13713d10ea6af 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -1314,7 +1314,7 @@ PHP_MINFO_FUNCTION(oci) php_info_print_table_row(2, "Active Connections", buf); #if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) - php_oci_client_get_version(&ver TSRMLS_DC); + php_oci_client_get_version(&ver TSRMLS_CC); php_info_print_table_row(2, "Oracle Run-time Client Library Version", ver); efree(ver); #endif From 950a716b1229e540531fe88d654ca7177411df8d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 11 Jun 2011 01:15:14 +0000 Subject: [PATCH 0144/2394] - Possible fix for bug #55022 (memory_limit exhausted when set charset in sybase_connect) --- ext/sybase_ct/php_sybase_ct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index e4a893f5c2f75..6a8a0a4f50675 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -728,7 +728,7 @@ static int php_sybase_do_connect_internal(sybase_link *sybase, char *host, char static void php_sybase_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) { - char *user, *passwd, *host, *charset, *appname; + char *user = NULL, *passwd = NULL, *host = NULL, *charset = NULL, *appname = NULL; char *hashed_details; int hashed_details_length, len; zend_bool new = 0; From d65b6dc0388f636d46c67360828ce5c87da3f2bb Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 11 Jun 2011 15:11:49 +0000 Subject: [PATCH 0145/2394] - Missing fix for bug #54347 --- ext/reflection/php_reflection.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 57f8f48c30deb..850192e84c654 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -5097,16 +5097,21 @@ ZEND_METHOD(reflection_extension, getFunctions) /* Is there a better way of doing this? */ while (func->fname) { - if (zend_hash_find(EG(function_table), func->fname, strlen(func->fname) + 1, (void**) &fptr) == FAILURE) { + int fname_len = strlen(func->fname); + char *lc_name = zend_str_tolower_dup(func->fname, fname_len); + + if (zend_hash_find(EG(function_table), lc_name, fname_len + 1, (void**) &fptr) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Internal error: Cannot find extension function %s in global function table", func->fname); func++; + efree(lc_name); continue; } ALLOC_ZVAL(function); reflection_function_factory(fptr, NULL, function TSRMLS_CC); - add_assoc_zval_ex(return_value, func->fname, strlen(func->fname)+1, function); + add_assoc_zval_ex(return_value, func->fname, fname_len+1, function); func++; + efree(lc_name); } } } From 0cfed19b9d48f56b2f71e24576182c2236bf44d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sat, 11 Jun 2011 20:20:50 +0000 Subject: [PATCH 0146/2394] - Fixed ext/sockets build on Mac OS X (hopefully). - Improvements in the multicast tests. - Very light refactoring in sockets.c. --- ext/sockets/multicast.c | 18 ++++---- ext/sockets/multicast.h | 12 ++++++ ext/sockets/sockets.c | 41 ++++++++++++------- ext/sockets/tests/mcast_helpers.php.inc | 8 ++++ ext/sockets/tests/mcast_ipv4_recv.phpt | 9 +++- ext/sockets/tests/mcast_ipv6_recv.phpt | 11 ++++- .../tests/mcast_ipv6_recv_limited.phpt | 25 ++++++----- 7 files changed, 88 insertions(+), 36 deletions(-) create mode 100644 ext/sockets/tests/mcast_helpers.php.inc diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index 9a1ecd5371f46..49e9c5cf730e9 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -53,11 +53,6 @@ #include "multicast.h" #include "main/php_network.h" -#if defined(MCAST_JOIN_GROUP) && 1 &&\ - (!defined(PHP_WIN32) || (_WIN32_WINNT >= 0x600 && SOCKETS_ENABLE_VISTA_API)) -#define RFC3678_API 1 -#endif - enum source_op { JOIN_SOURCE, @@ -67,10 +62,13 @@ enum source_op { }; static int _php_mcast_join_leave(php_socket *sock, int level, struct sockaddr *group, socklen_t group_len, unsigned int if_index, int join TSRMLS_DC); +#ifdef HAS_MCAST_EXT static int _php_mcast_source_op(php_socket *sock, int level, struct sockaddr *group, socklen_t group_len, struct sockaddr *source, socklen_t source_len, unsigned int if_index, enum source_op sop TSRMLS_DC); -#if RFC3678_API +#endif + +#ifdef RFC3678_API static int _php_source_op_to_rfc3678_op(enum source_op sop); -#else +#elif HAS_MCAST_EXT static const char *_php_source_op_to_string(enum source_op sop); static int _php_source_op_to_ipv4_op(enum source_op sop); #endif @@ -95,6 +93,7 @@ int php_mcast_leave( return _php_mcast_join_leave(sock, level, group, group_len, if_index, 0 TSRMLS_CC); } +#ifdef HAS_MCAST_EXT int php_mcast_join_source( php_socket *sock, int level, @@ -142,6 +141,8 @@ int php_mcast_unblock_source( { return _php_mcast_source_op(sock, level, group, group_len, source, source_len, if_index, UNBLOCK_SOURCE TSRMLS_CC); } +#endif /* HAS_MCAST_EXT */ + static int _php_mcast_join_leave( php_socket *sock, @@ -204,6 +205,7 @@ static int _php_mcast_join_leave( #endif } +#ifdef HAS_MCAST_EXT static int _php_mcast_source_op( php_socket *sock, int level, @@ -318,6 +320,8 @@ static int _php_source_op_to_ipv4_op(enum source_op sop) } #endif +#endif /* HAS_MCAST_EXT */ + #if PHP_WIN32 int php_if_index_to_addr4(unsigned if_index, php_socket *php_sock, struct in_addr *out_addr TSRMLS_DC) { diff --git a/ext/sockets/multicast.h b/ext/sockets/multicast.h index 5b63cf03815cb..0b1a1422e7842 100644 --- a/ext/sockets/multicast.h +++ b/ext/sockets/multicast.h @@ -18,6 +18,16 @@ /* $Id$ */ +#if defined(MCAST_JOIN_GROUP) && \ + (!defined(PHP_WIN32) || (_WIN32_WINNT >= 0x600 && SOCKETS_ENABLE_VISTA_API)) +#define RFC3678_API 1 +/* has block/unblock and source membership, in this case for both IPv4 and IPv6 */ +#define HAS_MCAST_EXT 1 +#elif defined(IP_ADD_SOURCE_MEMBERSHIP) +/* has block/unblock and source membership, but only for IPv4 */ +#define HAS_MCAST_EXT 1 +#endif + int php_if_index_to_addr4( unsigned if_index, php_socket *php_sock, @@ -42,6 +52,7 @@ int php_mcast_leave( socklen_t group_len, unsigned int if_index TSRMLS_DC); +#ifdef HAS_MCAST_EXT int php_mcast_join_source( php_socket *sock, int level, @@ -77,3 +88,4 @@ int php_mcast_unblock_source( struct sockaddr *source, socklen_t source_len, unsigned int if_index TSRMLS_DC); +#endif diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 2af92005b8270..456e89d087545 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -806,21 +806,25 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("PHP_NORMAL_READ", PHP_NORMAL_READ, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PHP_BINARY_READ", PHP_BINARY_READ, CONST_CS | CONST_PERSISTENT); -#ifndef MCAST_JOIN_GROUP +#ifndef RFC3678_API #define MCAST_JOIN_GROUP IP_ADD_MEMBERSHIP #define MCAST_LEAVE_GROUP IP_DROP_MEMBERSHIP +#ifdef HAS_MCAST_EXT #define MCAST_BLOCK_SOURCE IP_BLOCK_SOURCE #define MCAST_UNBLOCK_SOURCE IP_UNBLOCK_SOURCE #define MCAST_JOIN_SOURCE_GROUP IP_ADD_SOURCE_MEMBERSHIP #define MCAST_LEAVE_SOURCE_GROUP IP_DROP_SOURCE_MEMBERSHIP +#endif #endif REGISTER_LONG_CONSTANT("MCAST_JOIN_GROUP", MCAST_JOIN_GROUP, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MCAST_LEAVE_GROUP", MCAST_LEAVE_GROUP, CONST_CS | CONST_PERSISTENT); +#ifdef HAS_MCAST_EXT REGISTER_LONG_CONSTANT("MCAST_BLOCK_SOURCE", MCAST_BLOCK_SOURCE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MCAST_UNBLOCK_SOURCE", MCAST_UNBLOCK_SOURCE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MCAST_JOIN_SOURCE_GROUP", MCAST_JOIN_SOURCE_GROUP, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MCAST_LEAVE_SOURCE_GROUP", MCAST_LEAVE_SOURCE_GROUP, CONST_CS | CONST_PERSISTENT); +#endif REGISTER_LONG_CONSTANT("IP_MULTICAST_IF", IP_MULTICAST_IF, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IP_MULTICAST_TTL", IP_MULTICAST_TTL, CONST_CS | CONST_PERSISTENT); @@ -1485,11 +1489,6 @@ PHP_FUNCTION(socket_connect) { zval *arg1; php_socket *php_sock; - struct sockaddr_in sin; -#if HAVE_IPV6 - struct sockaddr_in6 sin6; -#endif - struct sockaddr_un s_un; char *addr; int retval, addr_len; long port = 0; @@ -1503,7 +1502,9 @@ PHP_FUNCTION(socket_connect) switch(php_sock->type) { #if HAVE_IPV6 - case AF_INET6: + case AF_INET6: { + struct sockaddr_in6 sin6 = {0}; + if (argc != 3) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Socket of type AF_INET6 requires 3 arguments"); RETURN_FALSE; @@ -1520,15 +1521,16 @@ PHP_FUNCTION(socket_connect) retval = connect(php_sock->bsd_socket, (struct sockaddr *)&sin6, sizeof(struct sockaddr_in6)); break; + } #endif - case AF_INET: + case AF_INET: { + struct sockaddr_in sin = {0}; + if (argc != 3) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Socket of type AF_INET requires 3 arguments"); RETURN_FALSE; } - memset(&sin, 0, sizeof(struct sockaddr_in)); - sin.sin_family = AF_INET; sin.sin_port = htons((unsigned short int)port); @@ -1538,19 +1540,22 @@ PHP_FUNCTION(socket_connect) retval = connect(php_sock->bsd_socket, (struct sockaddr *)&sin, sizeof(struct sockaddr_in)); break; + } - case AF_UNIX: + case AF_UNIX: { + struct sockaddr_un s_un = {0}; + if (addr_len >= sizeof(s_un.sun_path)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Path too long"); RETURN_FALSE; } - - memset(&s_un, 0, sizeof(struct sockaddr_un)); s_un.sun_family = AF_UNIX; memcpy(&s_un.sun_path, addr, addr_len); - retval = connect(php_sock->bsd_socket, (struct sockaddr *) &s_un, (socklen_t) XtOffsetOf(struct sockaddr_un, sun_path) + addr_len); + retval = connect(php_sock->bsd_socket, (struct sockaddr *) &s_un, + (socklen_t)(XtOffsetOf(struct sockaddr_un, sun_path) + addr_len)); break; + } default: php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unsupported socket type %d", php_sock->type); @@ -2034,8 +2039,10 @@ static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval * int retval; int (*mcast_req_fun)(php_socket *, int, struct sockaddr *, socklen_t, unsigned TSRMLS_DC); +#ifdef HAS_MCAST_EXT int (*mcast_sreq_fun)(php_socket *, int, struct sockaddr *, socklen_t, struct sockaddr *, socklen_t, unsigned TSRMLS_DC); +#endif switch (optname) { case MCAST_JOIN_GROUP: @@ -2065,6 +2072,7 @@ static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval * break; } +#ifdef HAS_MCAST_EXT case MCAST_BLOCK_SOURCE: mcast_sreq_fun = &php_mcast_block_source; goto mcast_sreq_fun; @@ -2103,6 +2111,7 @@ static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval * glen, (struct sockaddr*)&source, slen, if_index TSRMLS_CC); break; } +#endif default: php_error_docref(NULL TSRMLS_CC, E_WARNING, "unexpected option in php_do_mcast_opt (level %d, option %d). " @@ -2154,11 +2163,13 @@ PHP_FUNCTION(socket_set_option) if (level == IPPROTO_IP) { switch (optname) { case MCAST_JOIN_GROUP: - case MCAST_LEAVE_GROUP: + case MCAST_LEAVE_GROUP: +#ifdef HAS_MCAST_EXT case MCAST_BLOCK_SOURCE: case MCAST_UNBLOCK_SOURCE: case MCAST_JOIN_SOURCE_GROUP: case MCAST_LEAVE_SOURCE_GROUP: +#endif if (php_do_mcast_opt(php_sock, level, optname, arg4 TSRMLS_CC) == FAILURE) { RETURN_FALSE; } else { diff --git a/ext/sockets/tests/mcast_helpers.php.inc b/ext/sockets/tests/mcast_helpers.php.inc new file mode 100644 index 0000000000000..ad65a3f9d62b9 --- /dev/null +++ b/ext/sockets/tests/mcast_helpers.php.inc @@ -0,0 +1,8 @@ + ", $str, "\n"; @@ -146,13 +151,13 @@ if ($i == 8) { } } ---EXPECT-- +--EXPECTF-- creating send socket bound to 127.0.0.1 bool(true) creating unbound socket and hoping the routing table causes an interface other than lo to be used for sending messages to 224.0.0.23 bool(true) creating receive socket -resource(6) of type (Socket) +resource(%d) of type (Socket) bool(true) bool(true) int(14) diff --git a/ext/sockets/tests/mcast_ipv6_recv.phpt b/ext/sockets/tests/mcast_ipv6_recv.phpt index b33306da1d223..38390c025cecc 100644 --- a/ext/sockets/tests/mcast_ipv6_recv.phpt +++ b/ext/sockets/tests/mcast_ipv6_recv.phpt @@ -24,6 +24,10 @@ $r = socket_sendto($s, $m = "testing packet", strlen($m), 0, 'ff01::114', 3000); if ($r === false) { die('skip unable to send multicast packet.'); } + +if (!defined("MCAST_JOIN_SOURCE_GROUP")) + die('skip source operations are unavailable'); + $so = socket_set_option($s, IPPROTO_IPV6, MCAST_LEAVE_GROUP, array( "group" => 'ff01::114', "interface" => 0, @@ -39,6 +43,7 @@ if ($so === false) { --FILE-- ", $str, "\n"; @@ -171,9 +178,9 @@ if ($i == 8) { } --EXPECTF-- creating send socket -resource(4) of type (Socket) +resource(%d) of type (Socket) creating receive socket -resource(5) of type (Socket) +resource(%d) of type (Socket) bool(true) bool(true) int(14) diff --git a/ext/sockets/tests/mcast_ipv6_recv_limited.phpt b/ext/sockets/tests/mcast_ipv6_recv_limited.phpt index 2afea569bc7ca..fda099877d6a9 100644 --- a/ext/sockets/tests/mcast_ipv6_recv_limited.phpt +++ b/ext/sockets/tests/mcast_ipv6_recv_limited.phpt @@ -28,17 +28,20 @@ $so = socket_set_option($s, IPPROTO_IPV6, MCAST_LEAVE_GROUP, array( "group" => 'ff01::114', "interface" => 0, )); -$so = socket_set_option($s, IPPROTO_IPV6, MCAST_JOIN_SOURCE_GROUP, array( - "group" => 'ff01::114', - "interface" => 0, - "source" => '2001::dead:beef', -)); -if ($so !== false) { - die('skip protocol independent multicast API is available.'); +if (defined("MCAST_JOIN_SOURCE_GROUP")) { + $so = socket_set_option($s, IPPROTO_IPV6, MCAST_JOIN_SOURCE_GROUP, array( + "group" => 'ff01::114', + "interface" => 0, + "source" => '2001::dead:beef', + )); + if ($so !== false) { + die('skip protocol independent multicast API is available.'); + } } --FILE-- ", $str, "\n"; @@ -104,9 +109,9 @@ if ($i == 3) { } --EXPECTF-- creating send socket -resource(4) of type (Socket) +resource(%d) of type (Socket) creating receive socket -resource(5) of type (Socket) +resource(%d) of type (Socket) bool(true) bool(true) int(14) From e9a6750cdcc1b4f082b9d35b63d0cfb4204c709d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 12 Jun 2011 00:31:13 +0000 Subject: [PATCH 0147/2394] - Fixed tests --- ext/zlib/tests/gzfile_variation1.phpt | 10 +++++----- ext/zlib/tests/gzfile_variation6.phpt | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/ext/zlib/tests/gzfile_variation1.phpt b/ext/zlib/tests/gzfile_variation1.phpt index b573030f921f5..767abb7e30c01 100644 --- a/ext/zlib/tests/gzfile_variation1.phpt +++ b/ext/zlib/tests/gzfile_variation1.phpt @@ -29,15 +29,15 @@ foreach ( $variation as $var ) { ===DONE=== --EXPECTF-- -Warning: gzfile() expects parameter 1 to be string, array given in %s on line %d +Warning: gzfile() expects parameter 1 to be a valid path, array given in %s on line %d NULL -Warning: gzfile() expects parameter 1 to be string, array given in %s on line %d +Warning: gzfile() expects parameter 1 to be a valid path, array given in %s on line %d NULL -Warning: gzfile() expects parameter 1 to be string, array given in %s on line %d +Warning: gzfile() expects parameter 1 to be a valid path, array given in %s on line %d NULL -Warning: gzfile() expects parameter 1 to be string, array given in %s on line %d +Warning: gzfile() expects parameter 1 to be a valid path, array given in %s on line %d NULL -===DONE=== \ No newline at end of file +===DONE=== diff --git a/ext/zlib/tests/gzfile_variation6.phpt b/ext/zlib/tests/gzfile_variation6.phpt index 174524b3d8bbf..1ce1be6591395 100644 --- a/ext/zlib/tests/gzfile_variation6.phpt +++ b/ext/zlib/tests/gzfile_variation6.phpt @@ -45,5 +45,5 @@ foreach ( $variation as $var ) { --EXPECTF-- Error: 2 - gzfile(Class A object): failed to open stream: No such file or directory, %s(%d) bool(false) -Error: 2 - gzfile() expects parameter 1 to be string, object given, %s(%d) -NULL \ No newline at end of file +Error: 2 - gzfile() expects parameter 1 to be a valid path, object given, %s(%d) +NULL From 89da1ab1e80086094c617633eb5dde5b14f56707 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sun, 12 Jun 2011 00:56:18 +0000 Subject: [PATCH 0148/2394] - Reverted r301991, which is a (partial) fix to bug #52550, addressing an overflow in a signed subtraction. This fixes the overflow without changing the algorithm. --- ext/standard/math.c | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/ext/standard/math.c b/ext/standard/math.c index a4df5a5aa6d27..e4e884c299f44 100644 --- a/ext/standard/math.c +++ b/ext/standard/math.c @@ -13,7 +13,7 @@ | license@php.net so we can mail you a copy immediately. | +----------------------------------------------------------------------+ | Authors: Jim Winstead | - | Stig Sæther Bakken | + | Stig Sæther Bakken | | Zeev Suraski | | PHP 4.0 patches by Thies C. Arntzen | +----------------------------------------------------------------------+ @@ -92,6 +92,18 @@ static inline double php_intpow10(int power) { } /* }}} */ +/* {{{ php_math_is_finite */ +static inline int php_math_is_finite(double value) { +#if defined(PHP_WIN32) + return _finite(value); +#elif defined(isfinite) + return isfinite(value); +#else + return value == value && (value == 0. || value * 2. != value); +#endif +} +/* }}} */ + /* {{{ php_round_helper Actually performs the rounding of a value to integer in a certain mode */ static inline double php_round_helper(double value, int mode) { @@ -129,11 +141,11 @@ PHPAPI double _php_math_round(double value, int places, int mode) { double tmp_value; int precision_places; - if ((precision_places = php_intlog10abs(value)) > 0) { - precision_places = 14 - php_intlog10abs(value); - } else { - precision_places = 14; + if (!php_math_is_finite(value)) { + return value; } + + precision_places = 14 - php_intlog10abs(value); f1 = php_intpow10(abs(places)); From e613aae6206a8c34058882c4e54c6a6e06ca4c26 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 12 Jun 2011 01:43:10 +0000 Subject: [PATCH 0149/2394] - Avoid zend_do_ticks() call for each statement in parsing --- Zend/zend_compile.c | 12 +++++------- Zend/zend_compile.h | 1 + Zend/zend_language_parser.y | 6 +++--- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 1cad70f77a205..2f3fad9ba482d 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6170,14 +6170,12 @@ void zend_do_extended_fcall_end(TSRMLS_D) /* {{{ */ void zend_do_ticks(TSRMLS_D) /* {{{ */ { - if (Z_LVAL(CG(declarables).ticks)) { - zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); + zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); - opline->opcode = ZEND_TICKS; - SET_UNUSED(opline->op1); - SET_UNUSED(opline->op2); - opline->extended_value = Z_LVAL(CG(declarables).ticks); - } + opline->opcode = ZEND_TICKS; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + opline->extended_value = Z_LVAL(CG(declarables).ticks); } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 9aeac1416ce18..8ce7c405f80a9 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -39,6 +39,7 @@ #define INC_BPC(op_array) if (op_array->fn_flags & ZEND_ACC_INTERACTIVE) { (CG(context).backpatch_count++); } #define DEC_BPC(op_array) if (op_array->fn_flags & ZEND_ACC_INTERACTIVE) { (CG(context).backpatch_count--); } #define HANDLE_INTERACTIVE() if (CG(active_op_array)->fn_flags & ZEND_ACC_INTERACTIVE) { execute_new_code(TSRMLS_C); } +#define DO_TICKS() if (Z_LVAL(CG(declarables).ticks)) { zend_do_ticks(TSRMLS_C); } #define RESET_DOC_COMMENT() \ { \ diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index e0a956bc23e61..e3d079c551940 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -213,7 +213,7 @@ inner_statement: statement: - unticked_statement { zend_do_ticks(TSRMLS_C); } + unticked_statement { DO_TICKS(); } | T_STRING ':' { zend_do_label(&$1 TSRMLS_CC); } ; @@ -293,11 +293,11 @@ unset_variable: ; function_declaration_statement: - unticked_function_declaration_statement { zend_do_ticks(TSRMLS_C); } + unticked_function_declaration_statement { DO_TICKS(); } ; class_declaration_statement: - unticked_class_declaration_statement { zend_do_ticks(TSRMLS_C); } + unticked_class_declaration_statement { DO_TICKS(); } ; From 8d4a35f3e94e9b7ad6c4d0d6c097aebee1ac5362 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 12 Jun 2011 02:47:48 +0000 Subject: [PATCH 0150/2394] - Fixed bug #54680 (missing TRACK_VARS_SERVER check) --- ext/standard/basic_functions.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index df2d56f4911d5..ee74bd2959462 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -4226,7 +4226,8 @@ PHP_FUNCTION(getopt) /* Get argv from the global symbol table. We calculate argc ourselves * in order to be on the safe side, even though it is also available * from the symbol table. */ - if ((zend_hash_find(HASH_OF(PG(http_globals)[TRACK_VARS_SERVER]), "argv", sizeof("argv"), (void **) &args) != FAILURE || + if (PG(http_globals)[TRACK_VARS_SERVER] && + (zend_hash_find(HASH_OF(PG(http_globals)[TRACK_VARS_SERVER]), "argv", sizeof("argv"), (void **) &args) != FAILURE || zend_hash_find(&EG(symbol_table), "argv", sizeof("argv"), (void **) &args) != FAILURE) && Z_TYPE_PP(args) == IS_ARRAY ) { int pos = 0; From 12517f51a8ab255086069e10d2dfc950cfb0372b Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 12 Jun 2011 10:07:43 +0000 Subject: [PATCH 0151/2394] fix method names in header --- ext/snmp/php_snmp.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index 387bf974b9a62..f3ca3e258e716 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -82,8 +82,8 @@ PHP_METHOD(SNMP, get); PHP_METHOD(SNMP, getnext); PHP_METHOD(SNMP, walk); PHP_METHOD(SNMP, set); -PHP_METHOD(SNMP, get_errno); -PHP_METHOD(SNMP, get_error); +PHP_METHOD(SNMP, getErrno); +PHP_METHOD(SNMP, getError); typedef struct _php_snmp_object { zend_object zo; From 787cb14c3e6b68c87a8c248825dcb3cde582a68f Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 12 Jun 2011 10:13:30 +0000 Subject: [PATCH 0152/2394] no more method open --- ext/snmp/php_snmp.h | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index f3ca3e258e716..7ba07e005f0e0 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -75,7 +75,6 @@ PHP_FUNCTION(snmp_get_valueretrieval); PHP_FUNCTION(snmp_read_mib); -PHP_METHOD(SNMP, open); PHP_METHOD(SNMP, setSecurity); PHP_METHOD(SNMP, close); PHP_METHOD(SNMP, get); From 0db6d3b16c7fb594942507cd15ae3fd5ed34df8e Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 12 Jun 2011 11:25:20 +0000 Subject: [PATCH 0153/2394] fix typo in comment --- ext/snmp/snmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index e99d5090e5d89..f25fbd62eb504 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -1809,7 +1809,7 @@ PHP_METHOD(snmp, set) php_snmp(INTERNAL_FUNCTION_PARAM_PASSTHRU, SNMP_CMD_SET, (-1)); } -/* {{{ proto bool SNMP::setSecurity(resource session, string sec_level, [ string auth_protocol, string auth_passphrase [, string priv_protocol, string priv_passphrase [, string contextName [, string contextEngineID]]]]) +/* {{{ proto bool SNMP::setSecurity(string sec_level, [ string auth_protocol, string auth_passphrase [, string priv_protocol, string priv_passphrase [, string contextName [, string contextEngineID]]]]) Set SNMPv3 security-related session parameters */ PHP_METHOD(snmp, setSecurity) { From edd80c571dc3cda01cc1248a9d053841488bdf97 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 12 Jun 2011 11:58:49 +0000 Subject: [PATCH 0154/2394] move SNMP VERSION constants into SNMP class itself --- ext/snmp/snmp.c | 8 +++--- ext/snmp/tests/snmp-object-errno-errstr.phpt | 8 +++--- ext/snmp/tests/snmp-object-error.phpt | 10 +++---- ext/snmp/tests/snmp-object-properties.phpt | 2 +- .../tests/snmp-object-setSecurity_error.phpt | 2 +- ext/snmp/tests/snmp-object.phpt | 26 +++++++++---------- 6 files changed, 28 insertions(+), 28 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index f25fbd62eb504..af4d80b8082a0 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -2385,10 +2385,10 @@ PHP_MINIT_FUNCTION(snmp) REGISTER_LONG_CONSTANT("SNMP_INTEGER", ASN_INTEGER, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SNMP_COUNTER64", ASN_COUNTER64, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("SNMP_VERSION_1", SNMP_VERSION_1, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("SNMP_VERSION_2c", SNMP_VERSION_2c, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("SNMP_VERSION_2C", SNMP_VERSION_2c, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("SNMP_VERSION_3", SNMP_VERSION_3, CONST_CS | CONST_PERSISTENT); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_1", (long)SNMP_VERSION_1); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_2c", (long)SNMP_VERSION_2c); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_2C", (long)SNMP_VERSION_2c); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_3", (long)SNMP_VERSION_3); REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_NOERROR", (long)PHP_SNMP_ERRNO_NOERROR); REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_GENERIC", (long)PHP_SNMP_ERRNO_GENERIC); diff --git a/ext/snmp/tests/snmp-object-errno-errstr.phpt b/ext/snmp/tests/snmp-object-errno-errstr.phpt index f46254ed3443e..923fb856e07a3 100644 --- a/ext/snmp/tests/snmp-object-errno-errstr.phpt +++ b/ext/snmp/tests/snmp-object-errno-errstr.phpt @@ -17,27 +17,27 @@ snmp_set_valueretrieval(SNMP_VALUE_PLAIN); snmp_set_oid_output_format(SNMP_OID_OUTPUT_FULL); echo "SNMP::ERRNO_NOERROR\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); var_dump(@$session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getErrno() == SNMP::ERRNO_NOERROR); var_dump($session->getError()); $session->close(); echo "SNMP::ERRNO_TIMEOUT\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, 'timeout_community_432', $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, 'timeout_community_432', $timeout, $retries); $session->valueretrieval = SNMP_VALUE_LIBRARY; var_dump(@$session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getErrno() == SNMP::ERRNO_TIMEOUT); var_dump($session->getError()); $session->close(); echo "SNMP::ERRNO_ERROR_IN_REPLY\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); var_dump(@$session->get('.1.3.6.1.2.1.1.1.110')); var_dump($session->getErrno() == SNMP::ERRNO_ERROR_IN_REPLY); var_dump($session->getError()); $session->close(); echo "SNMP::ERRNO_GENERIC\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, 'somebogususer', $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, 'somebogususer', $timeout, $retries); $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); var_dump(@$session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getErrno() == SNMP::ERRNO_GENERIC); diff --git a/ext/snmp/tests/snmp-object-error.phpt b/ext/snmp/tests/snmp-object-error.phpt index e4fb526d3eee8..00db3a318c5c8 100644 --- a/ext/snmp/tests/snmp-object-error.phpt +++ b/ext/snmp/tests/snmp-object-error.phpt @@ -15,17 +15,17 @@ snmp_set_quick_print(false); snmp_set_valueretrieval(SNMP_VALUE_PLAIN); try { -var_dump(new SNMP(SNMP_VERSION_1, $hostname)); +var_dump(new SNMP(SNMP::VERSION_1, $hostname)); } catch (Exception $e) { print $e->getMessage() . "\n"; } try { -var_dump(new SNMP(SNMP_VERSION_1, $hostname, $community, '')); +var_dump(new SNMP(SNMP::VERSION_1, $hostname, $community, '')); } catch (Exception $e) { print $e->getMessage() . "\n"; } try { -var_dump(new SNMP(SNMP_VERSION_1, $hostname, $community, $timeout, '')); +var_dump(new SNMP(SNMP::VERSION_1, $hostname, $community, $timeout, '')); } catch (Exception $e) { print $e->getMessage() . "\n"; } @@ -36,7 +36,7 @@ var_dump(new SNMP(7, $hostname, $community)); } echo "Open normal session\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, $user_noauth, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $user_noauth, $timeout, $retries); $session->valueretrieval = 67; var_dump($session->valueretrieval); echo "Closing session\n"; @@ -45,7 +45,7 @@ var_dump($session->close()); var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); var_dump($session->walk('.1.3.6.1.2.1.1', FALSE, '')); var_dump($session->walk('.1.3.6.1.2.1.1', FALSE, 0, '')); var_dump($session->get()); diff --git a/ext/snmp/tests/snmp-object-properties.phpt b/ext/snmp/tests/snmp-object-properties.phpt index 0bdf51b46e988..98423670c1ad4 100644 --- a/ext/snmp/tests/snmp-object-properties.phpt +++ b/ext/snmp/tests/snmp-object-properties.phpt @@ -18,7 +18,7 @@ snmp_set_oid_output_format(SNMP_OID_OUTPUT_FULL); echo "Check working\n"; -$session = new SNMP(SNMP_VERSION_1, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_1, $hostname, $community, $timeout, $retries); var_dump($session); $session->max_oids = 40; diff --git a/ext/snmp/tests/snmp-object-setSecurity_error.phpt b/ext/snmp/tests/snmp-object-setSecurity_error.phpt index b5327649c0733..fc3a1b2269ec9 100644 --- a/ext/snmp/tests/snmp-object-setSecurity_error.phpt +++ b/ext/snmp/tests/snmp-object-setSecurity_error.phpt @@ -14,7 +14,7 @@ require_once(dirname(__FILE__).'/snmp_include.inc'); snmp_set_quick_print(false); snmp_set_valueretrieval(SNMP_VALUE_PLAIN); -$session = new SNMP(SNMP_VERSION_3, $hostname, $user_noauth, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $user_noauth, $timeout, $retries); $session->setSecurity('noAuthNoPriv'); #echo "Checking error handling\n"; diff --git a/ext/snmp/tests/snmp-object.phpt b/ext/snmp/tests/snmp-object.phpt index 64db8b870dc44..684391b461e84 100644 --- a/ext/snmp/tests/snmp-object.phpt +++ b/ext/snmp/tests/snmp-object.phpt @@ -17,7 +17,7 @@ snmp_set_valueretrieval(SNMP_VALUE_PLAIN); snmp_set_oid_output_format(SNMP_OID_OUTPUT_FULL); echo "SNMPv1\n"; -$session = new SNMP(SNMP_VERSION_1, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_1, $hostname, $community, $timeout, $retries); $session->valueretrieval = SNMP_VALUE_LIBRARY; var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->get(array('.1.3.6.1.2.1.1.1.0', '.1.3.6.1.2.1.1.3.0'))); @@ -25,13 +25,13 @@ var_dump($session->getnext('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); echo "SNMPv2\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getnext('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); echo "GET with preserving original OID names\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); $orig = array('.1.3.6.1.2.1.1.1.0', '.1.3.6.1.2.1.1.5.0'); $result = $session->get($orig, TRUE); foreach($orig as $oid){ @@ -40,7 +40,7 @@ foreach($orig as $oid){ var_dump($session->close()); echo "WALK multiple on single OID\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); $z = $session->walk('.1.3.6.1.2.1.1'); var_dump(gettype($z)); var_dump(count($z)); @@ -49,7 +49,7 @@ var_dump(array_shift($z)); var_dump($session->close()); echo "WALK multiple on single OID, non_repeaters set to 0\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); $z = $session->walk('.1.3.6.1.2.1.1', 0); var_dump(gettype($z)); var_dump(count($z)); @@ -58,7 +58,7 @@ var_dump(array_shift($z)); var_dump($session->close()); echo "WALK multiple on single OID, non_repeaters set to 0, max_repetitions set to 30\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); $z = $session->walk('.1.3.6.1.2.1.1', 0, 30); var_dump(gettype($z)); var_dump(count($z)); @@ -67,7 +67,7 @@ var_dump(array_shift($z)); var_dump($session->close()); echo "WALK multiple on single OID, max_oids set to 30\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); $session->max_oids = 30; $z = $session->walk('.1.3.6.1.2.1.1'); var_dump(gettype($z)); @@ -77,7 +77,7 @@ var_dump(array_shift($z)); var_dump($session->close()); echo "WALK multiple on single OID with OID suffix as keys\n"; -$session = new SNMP(SNMP_VERSION_2c, $hostname, $community, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); $z = $session->walk('.1.3.6.1.2.1.1', TRUE); var_dump(gettype($z)); var_dump(count($z)); @@ -86,21 +86,21 @@ var_dump(array_shift($z)); var_dump($session->close()); echo "SNMPv3 (default security settings)\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, $user_noauth, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $user_noauth, $timeout, $retries); #$session->setSecurity($user_noauth, 'noAuthNoPriv', '', '', '', '', '', ''); var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getnext('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); echo "SNMPv3 (noAuthNoPriv)\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, $user_noauth, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $user_noauth, $timeout, $retries); $session->setSecurity('noAuthNoPriv'); var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getnext('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); echo "SNMPv3 (authPriv)\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, $rwuser, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getnext('.1.3.6.1.2.1.1.1.0')); @@ -108,7 +108,7 @@ var_dump($session->walk('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); echo "SET single OID\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, $rwuser, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); $oid1 = 'SNMPv2-MIB::sysContact.0'; $oldvalue1 = $session->get($oid1); @@ -123,7 +123,7 @@ var_dump(($session->get($oid1) === $oldvalue1)); var_dump($session->close()); echo "SNMPv3, setting contextEngineID (authPriv)\n"; -$session = new SNMP(SNMP_VERSION_3, $hostname, $rwuser, $timeout, $retries); +$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass, '', 'aeeeff'); var_dump($session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->close()); From b88a5db4dd9e50bdf515e1176250835eba897b2d Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 12 Jun 2011 14:49:10 +0000 Subject: [PATCH 0155/2394] Don't expect a path for tidy_repair_string() and fix the tests --- ext/tidy/tests/019.phpt | 2 +- ext/tidy/tests/022.phpt | 2 +- ext/tidy/tidy.c | 10 ++++++---- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/ext/tidy/tests/019.phpt b/ext/tidy/tests/019.phpt index 91bbc016edb26..5e9c38d75a3be 100644 --- a/ext/tidy/tests/019.phpt +++ b/ext/tidy/tests/019.phpt @@ -38,5 +38,5 @@ Warning: tidy_repair_file(): Filename cannot be empty in %s on line %d Warning: tidy_repair_file(): Filename cannot be empty in %s on line %d -Warning: tidy_repair_file() expects parameter 1 to be string, array given in %s on line %d +Warning: tidy_repair_file() expects parameter 1 to be a valid path, array given in %s on line %d Done diff --git a/ext/tidy/tests/022.phpt b/ext/tidy/tests/022.phpt index 91bbc016edb26..5e9c38d75a3be 100644 --- a/ext/tidy/tests/022.phpt +++ b/ext/tidy/tests/022.phpt @@ -38,5 +38,5 @@ Warning: tidy_repair_file(): Filename cannot be empty in %s on line %d Warning: tidy_repair_file(): Filename cannot be empty in %s on line %d -Warning: tidy_repair_file() expects parameter 1 to be string, array given in %s on line %d +Warning: tidy_repair_file() expects parameter 1 to be a valid path, array given in %s on line %d Done diff --git a/ext/tidy/tidy.c b/ext/tidy/tidy.c index cf8e29056919f..2b859683f3d2d 100644 --- a/ext/tidy/tidy.c +++ b/ext/tidy/tidy.c @@ -558,15 +558,17 @@ static void php_tidy_quick_repair(INTERNAL_FUNCTION_PARAMETERS, zend_bool is_fil TidyBuffer *errbuf; zval **config = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|Zsb", &arg1, &arg1_len, &config, &enc, &enc_len, &use_include_path) == FAILURE) { - RETURN_FALSE; - } - if (is_file) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|Zsb", &arg1, &arg1_len, &config, &enc, &enc_len, &use_include_path) == FAILURE) { + RETURN_FALSE; + } if (!(data = php_tidy_file_to_mem(arg1, use_include_path, &data_len TSRMLS_CC))) { RETURN_FALSE; } } else { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|Zsb", &arg1, &arg1_len, &config, &enc, &enc_len, &use_include_path) == FAILURE) { + RETURN_FALSE; + } data = arg1; data_len = arg1_len; } From 29977191200d8558146d67c3faf2cfd28399663d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 12 Jun 2011 15:15:44 +0000 Subject: [PATCH 0156/2394] - Restore basename in filename on non Windows OS --- ext/mbstring/mbstring.c | 19 +++++++++++++------ main/rfc1867.c | 20 ++++++++++++-------- 2 files changed, 25 insertions(+), 14 deletions(-) diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 0417fafffa270..34644a553bc61 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -1146,7 +1146,7 @@ static char *php_mb_rfc1867_getword_conf(const zend_encoding *encoding, char *st static char *php_mb_rfc1867_basename(const zend_encoding *encoding, char *filename TSRMLS_DC) /* {{{ */ { - char *s, *tmp; + char *s, *s2, *tmp; const size_t filename_len = strlen(filename); /* The \ check should technically be needed for win32 systems only where @@ -1155,11 +1155,18 @@ static char *php_mb_rfc1867_basename(const zend_encoding *encoding, char *filena * the user does basename() they get a bogus file name. Until IE's user base drops * to nill or problem is fixed this code must remain enabled for all systems. */ s = php_mb_safe_strrchr_ex(filename, '\\', filename_len, (const mbfl_encoding *)encoding); - if ((tmp = php_mb_safe_strrchr_ex(filename, '/', filename_len, (const mbfl_encoding *)encoding)) > s) { - s = tmp; - } - if (s) { - return s + 1; + s2 = php_mb_safe_strrchr_ex(filename, '/', filename_len, (const mbfl_encoding *)encoding); + + if (s && s2) { + if (s > s2) { + return ++s; + } else { + return ++s2; + } + } else if (s) { + return ++s; + } else if (s2) { + return ++s2; } else { return filename; } diff --git a/main/rfc1867.c b/main/rfc1867.c index 4decaec39bba2..4467aaff160e8 100644 --- a/main/rfc1867.c +++ b/main/rfc1867.c @@ -555,17 +555,21 @@ static char *php_ap_getword_conf(const zend_encoding *encoding, char *str TSRMLS static char *php_ap_basename(const zend_encoding *encoding, char *path TSRMLS_DC) { char *s = strrchr(path, '\\'); - if (s) { - char *tmp = strrchr(path, '/'); - if (tmp && tmp > s) { - s = tmp + 1; + char *s2 = strrchr(path, '/'); + + if (s && s2) { + if (s > s2) { + ++s; } else { - s++; + s = ++s2; } - } else { - s = path; + return s; + } else if (s) { + return ++s; + } else if (s2) { + return ++s2; } - return s; + return path; } /* From 1dd95849d5d78544b1ab26ad91f51d3425b97ab4 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 12 Jun 2011 17:26:45 +0000 Subject: [PATCH 0157/2394] - Added Bison 2.5 to bison_version_list --- Zend/acinclude.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/acinclude.m4 b/Zend/acinclude.m4 index 0e175467b236c..97d5d647bb200 100644 --- a/Zend/acinclude.m4 +++ b/Zend/acinclude.m4 @@ -4,7 +4,7 @@ dnl This file contains local autoconf functions. AC_DEFUN([LIBZEND_BISON_CHECK],[ # we only support certain bison versions - bison_version_list="1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3 2.4 2.4.1 2.4.2 2.4.3" + bison_version_list="1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3 2.4 2.4.1 2.4.2 2.4.3 2.5" # for standalone build of Zend Engine test -z "$SED" && SED=sed From c30bde0ef55e85bae0269d768e432068904f1127 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 12 Jun 2011 18:38:26 +0000 Subject: [PATCH 0158/2394] These regexes don't fail under the new backtrack limit, so lower it just for the test to check the failure. --- ext/pcre/tests/006.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/pcre/tests/006.phpt b/ext/pcre/tests/006.phpt index d1282bf426e3c..2d39b6ea385e5 100644 --- a/ext/pcre/tests/006.phpt +++ b/ext/pcre/tests/006.phpt @@ -1,5 +1,7 @@ --TEST-- preg_replace() with array of failing regular expressions +--INI-- +pcre.backtrack_limit=100000 --FILE-- Date: Sun, 12 Jun 2011 21:10:31 +0000 Subject: [PATCH 0159/2394] - Fixed bug #54624 (class_alias and type hint) --- Zend/tests/bug54624.phpt | 26 ++++++++++++++++++++++++++ Zend/zend_compile.c | 18 +++++++++++++++--- 2 files changed, 41 insertions(+), 3 deletions(-) create mode 100644 Zend/tests/bug54624.phpt diff --git a/Zend/tests/bug54624.phpt b/Zend/tests/bug54624.phpt new file mode 100644 index 0000000000000..1d0c1ce87c18e --- /dev/null +++ b/Zend/tests/bug54624.phpt @@ -0,0 +1,26 @@ +--TEST-- +Bug #54624 (class_alias and type hint) +--FILE-- + +--EXPECTF-- +DONE diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 2f3fad9ba482d..8cc6eb5ee75f4 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2918,11 +2918,23 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c && strcasecmp(fe->common.arg_info[i].class_name, proto->common.arg_info[i].class_name)!=0) { char *colon; - if (fe->common.type != ZEND_USER_FUNCTION || - strchr(proto->common.arg_info[i].class_name, '\\') != NULL || + if (fe->common.type != ZEND_USER_FUNCTION) { + return 0; + } else if (strchr(proto->common.arg_info[i].class_name, '\\') != NULL || (colon = zend_memrchr(fe->common.arg_info[i].class_name, '\\', fe->common.arg_info[i].class_name_len)) == NULL || strcasecmp(colon+1, proto->common.arg_info[i].class_name) != 0) { - return 0; + zend_class_entry **fe_ce, **proto_ce; + TSRMLS_FETCH(); + int found = zend_lookup_class(fe->common.arg_info[i].class_name, fe->common.arg_info[i].class_name_len, &fe_ce TSRMLS_CC); + int found2 = zend_lookup_class(proto->common.arg_info[i].class_name, proto->common.arg_info[i].class_name_len, &proto_ce TSRMLS_CC); + + /* Check for class alias */ + if (found != SUCCESS || found2 != SUCCESS || + (*fe_ce)->type == ZEND_INTERNAL_CLASS || + (*proto_ce)->type == ZEND_INTERNAL_CLASS || + *fe_ce != *proto_ce) { + return 0; + } } } if (fe->common.arg_info[i].type_hint != proto->common.arg_info[i].type_hint) { From 7229afbd41541937e50979f3ac0c3be5f5d8a61f Mon Sep 17 00:00:00 2001 From: Timm Friebe Date: Mon, 13 Jun 2011 08:43:21 +0000 Subject: [PATCH 0160/2394] - Fix compiler warning about long vs. int in printf() # See bug #55009 # Compare to _server_message_handler() a little below, where this # is done the same way --- ext/sybase_ct/php_sybase_ct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index 6a8a0a4f50675..129f687bd176b 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -388,7 +388,7 @@ static CS_RETCODE CS_PUBLIC _client_message_handler(CS_CONTEXT *context, CS_CONN TSRMLS_FETCH(); if (CS_SEVERITY(errmsg->msgnumber) >= SybCtG(min_client_severity)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Sybase: Client message: %s (severity %d)", errmsg->msgstring, CS_SEVERITY(errmsg->msgnumber)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Sybase: Client message: %s (severity %ld)", errmsg->msgstring, (long)CS_SEVERITY(errmsg->msgnumber)); } STR_FREE(SybCtG(server_message)); SybCtG(server_message) = estrdup(errmsg->msgstring); From 50ade271986e9e181185abf32f24034a0bc0f0d3 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 13 Jun 2011 17:52:23 +0000 Subject: [PATCH 0161/2394] - Fix build on Windows --- Zend/zend_compile.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 8cc6eb5ee75f4..18e7101de2de1 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2870,7 +2870,7 @@ static void do_inherit_method(zend_function *function) /* {{{ */ } /* }}} */ -static zend_bool zend_do_perform_implementation_check(const zend_function *fe, const zend_function *proto) /* {{{ */ +static zend_bool zend_do_perform_implementation_check(const zend_function *fe, const zend_function *proto TSRMLS_DC) /* {{{ */ { zend_uint i; @@ -2924,9 +2924,10 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c (colon = zend_memrchr(fe->common.arg_info[i].class_name, '\\', fe->common.arg_info[i].class_name_len)) == NULL || strcasecmp(colon+1, proto->common.arg_info[i].class_name) != 0) { zend_class_entry **fe_ce, **proto_ce; - TSRMLS_FETCH(); - int found = zend_lookup_class(fe->common.arg_info[i].class_name, fe->common.arg_info[i].class_name_len, &fe_ce TSRMLS_CC); - int found2 = zend_lookup_class(proto->common.arg_info[i].class_name, proto->common.arg_info[i].class_name_len, &proto_ce TSRMLS_CC); + int found, found2; + + found = zend_lookup_class(fe->common.arg_info[i].class_name, fe->common.arg_info[i].class_name_len, &fe_ce TSRMLS_CC); + found2 = zend_lookup_class(proto->common.arg_info[i].class_name, proto->common.arg_info[i].class_name_len, &proto_ce TSRMLS_CC); /* Check for class alias */ if (found != SUCCESS || found2 != SUCCESS || @@ -3017,11 +3018,11 @@ static void do_inheritance_check_on_method(zend_function *child, zend_function * } if (child->common.prototype && (child->common.prototype->common.fn_flags & ZEND_ACC_ABSTRACT)) { - if (!zend_do_perform_implementation_check(child, child->common.prototype)) { + if (!zend_do_perform_implementation_check(child, child->common.prototype TSRMLS_CC)) { zend_error(E_COMPILE_ERROR, "Declaration of %s::%s() must be compatible with that of %s::%s()", ZEND_FN_SCOPE_NAME(child), child->common.function_name, ZEND_FN_SCOPE_NAME(child->common.prototype), child->common.prototype->common.function_name); } } else if (EG(error_reporting) & E_STRICT || EG(user_error_handler)) { /* Check E_STRICT (or custom error handler) before the check so that we save some time */ - if (!zend_do_perform_implementation_check(child, parent)) { + if (!zend_do_perform_implementation_check(child, parent TSRMLS_CC)) { zend_error(E_STRICT, "Declaration of %s::%s() should be compatible with that of %s::%s()", ZEND_FN_SCOPE_NAME(child), child->common.function_name, ZEND_FN_SCOPE_NAME(parent), parent->common.function_name); } } From 60ae440721a20f85c5114bffce1473cd2c418292 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 14 Jun 2011 02:05:37 +0000 Subject: [PATCH 0162/2394] - New tests for new feature --- Zend/tests/indirect_call_array_001.phpt | 11 ++++ Zend/tests/indirect_call_array_002.phpt | 11 ++++ Zend/tests/indirect_call_array_003.phpt | 38 +++++++++++++ Zend/tests/indirect_call_array_004.phpt | 71 +++++++++++++++++++++++++ 4 files changed, 131 insertions(+) create mode 100644 Zend/tests/indirect_call_array_001.phpt create mode 100644 Zend/tests/indirect_call_array_002.phpt create mode 100644 Zend/tests/indirect_call_array_003.phpt create mode 100644 Zend/tests/indirect_call_array_004.phpt diff --git a/Zend/tests/indirect_call_array_001.phpt b/Zend/tests/indirect_call_array_001.phpt new file mode 100644 index 0000000000000..56675b81a5bf3 --- /dev/null +++ b/Zend/tests/indirect_call_array_001.phpt @@ -0,0 +1,11 @@ +--TEST-- +Indirect method call by array - Invalid class name +--FILE-- + +--EXPECTF-- +Fatal error: Class 'a' not found in %s on line %d diff --git a/Zend/tests/indirect_call_array_002.phpt b/Zend/tests/indirect_call_array_002.phpt new file mode 100644 index 0000000000000..013fa559fe78a --- /dev/null +++ b/Zend/tests/indirect_call_array_002.phpt @@ -0,0 +1,11 @@ +--TEST-- +Indirect method call by array - Invalid method name +--FILE-- + +--EXPECTF-- +Fatal error: Call to undefined method stdClass::b() in %s on line %d diff --git a/Zend/tests/indirect_call_array_003.phpt b/Zend/tests/indirect_call_array_003.phpt new file mode 100644 index 0000000000000..498c580c4820c --- /dev/null +++ b/Zend/tests/indirect_call_array_003.phpt @@ -0,0 +1,38 @@ +--TEST-- +Indirect method call by array - Calling __call() and __callStatic() +--FILE-- + +--EXPECTF-- +From foo::__callStatic: +string(3) "abc" + +Notice: Undefined variable: this in %s on line %d +NULL +From foo::__call: +string(3) "abc" +object(foo)#%d (0) { +} + diff --git a/Zend/tests/indirect_call_array_004.phpt b/Zend/tests/indirect_call_array_004.phpt new file mode 100644 index 0000000000000..350f720648d04 --- /dev/null +++ b/Zend/tests/indirect_call_array_004.phpt @@ -0,0 +1,71 @@ +--TEST-- +Indirect method call by array - Testing exception and method magics +--FILE-- +getMessage(), "\n"; +} + +$arr = array('foo', '123'); + +try { + $arr(); +} +catch (Exception $e) { + echo $e->getMessage(), "\n"; +} + + +echo "------\n"; + +$foo = new foo; +$arr = array($foo, 'abc'); + +try { + $arr(); +} +catch (Exception $e) { + echo $e->getMessage(), "\n"; +} + + +$foo = new foo; +$arr = array($foo, '123'); + +try { + $arr(); +} +catch (Exception $e) { + echo $e->getMessage(), "\n"; +} + +?> +--EXPECTF-- +foo +From foo::__callStatic: +123 +------ +foo +From foo::__call: +123 From e39ed9781e8a71b9852f3ca0c35fa1de06325591 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Tue, 14 Jun 2011 17:00:49 +0000 Subject: [PATCH 0163/2394] Upgrade SQLite to 3.7.6.3 --- ext/sqlite3/libsqlite/sqlite3.c | 16 +++++++++++++--- ext/sqlite3/libsqlite/sqlite3.h | 4 ++-- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/ext/sqlite3/libsqlite/sqlite3.c b/ext/sqlite3/libsqlite/sqlite3.c index fa37b0c2e471f..d461dad4a4780 100644 --- a/ext/sqlite3/libsqlite/sqlite3.c +++ b/ext/sqlite3/libsqlite/sqlite3.c @@ -4,7 +4,7 @@ /****************************************************************************** ** This file is an amalgamation of many separate C source files from SQLite -** version 3.7.6.2. By combining all the individual C code files into this +** version 3.7.6.3. By combining all the individual C code files into this ** single large file, the entire code can be compiled as a single translation ** unit. This allows many compilers to do optimizations that would not be ** possible if the files were compiled separately. Performance improvements @@ -654,9 +654,9 @@ extern "C" { ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ -#define SQLITE_VERSION "3.7.6.2" +#define SQLITE_VERSION "3.7.6.3" #define SQLITE_VERSION_NUMBER 3007006 -#define SQLITE_SOURCE_ID "2011-04-17 17:25:17 154ddbc17120be2915eb03edc52af1225eb7cb5e" +#define SQLITE_SOURCE_ID "2011-05-19 13:26:54 ed1da510a239ea767a01dc332b667119fa3c908e" /* ** CAPI3REF: Run-Time Library Version Numbers @@ -42076,11 +42076,21 @@ SQLITE_PRIVATE int sqlite3PagerCommitPhaseOne( }else{ if( pagerUseWal(pPager) ){ PgHdr *pList = sqlite3PcacheDirtyList(pPager->pPCache); + PgHdr *pPageOne = 0; + if( pList==0 ){ + /* Must have at least one page for the WAL commit flag. + ** Ticket [2d1a5c67dfc2363e44f29d9bbd57f] 2011-05-18 */ + rc = sqlite3PagerGet(pPager, 1, &pPageOne); + pList = pPageOne; + pList->pDirty = 0; + } + assert( pList!=0 || rc!=SQLITE_OK ); if( pList ){ rc = pagerWalFrames(pPager, pList, pPager->dbSize, 1, (pPager->fullSync ? pPager->syncFlags : 0) ); } + sqlite3PagerUnref(pPageOne); if( rc==SQLITE_OK ){ sqlite3PcacheCleanAll(pPager->pPCache); } diff --git a/ext/sqlite3/libsqlite/sqlite3.h b/ext/sqlite3/libsqlite/sqlite3.h index 3b7eb94dda8a9..85e916c5e5792 100644 --- a/ext/sqlite3/libsqlite/sqlite3.h +++ b/ext/sqlite3/libsqlite/sqlite3.h @@ -107,9 +107,9 @@ extern "C" { ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ -#define SQLITE_VERSION "3.7.6.2" +#define SQLITE_VERSION "3.7.6.3" #define SQLITE_VERSION_NUMBER 3007006 -#define SQLITE_SOURCE_ID "2011-04-17 17:25:17 154ddbc17120be2915eb03edc52af1225eb7cb5e" +#define SQLITE_SOURCE_ID "2011-05-19 13:26:54 ed1da510a239ea767a01dc332b667119fa3c908e" /* ** CAPI3REF: Run-Time Library Version Numbers From fedc6b2926bc6e7d52b1355234ac7f2e2f7b5826 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Tue, 14 Jun 2011 20:04:18 +0000 Subject: [PATCH 0164/2394] Improve cross version compat --- ext/oci8/tests/null_byte_1.phpt | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ext/oci8/tests/null_byte_1.phpt b/ext/oci8/tests/null_byte_1.phpt index 6898049bd96e2..0869d94123139 100644 --- a/ext/oci8/tests/null_byte_1.phpt +++ b/ext/oci8/tests/null_byte_1.phpt @@ -1,7 +1,12 @@ --TEST-- Protect against null bytes in LOB filenames --SKIPIF-- - + --INI-- display_errors = On error_reporting = E_WARNING @@ -11,7 +16,6 @@ error_reporting = E_WARNING // See http://news.php.net/php.internals/50202 // http://svn.php.net/viewvc?view=revision&revision=311870 - require(dirname(__FILE__).'/connect.inc'); // Run Test From 0b3ca102124f287417124f88b2b2af2f3cccd886 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 15 Jun 2011 23:19:30 +0000 Subject: [PATCH 0165/2394] update the branches list --- README.SVN-RULES | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/README.SVN-RULES b/README.SVN-RULES index 2b3cb8036a5fb..3085489c31478 100644 --- a/README.SVN-RULES +++ b/README.SVN-RULES @@ -43,13 +43,17 @@ Having said that, here are the organizational rules:: Currently we have the following branches in use:: - trunk Will become PHP 6.0. This CVS branch is for active development. + trunk The active development branch. - branches/PHP_5_3 Is used to release the PHP 5.3.x series. It still allows for + branches/PHP_5_4 Is used to release the PHP 5.4.x series. It still allows for larger enhancements. - branches/PHP_5_2 Is used to release the PHP 5.2.x series. Only bugfixes are permitted - on this branch (Consult the releasemaster prior to commit). + branches/PHP_5_3 Is used to release the PHP 5.3.x series. This is current + stable version and is open for bugfixes and small + improvements (check with RMs if in doubt). + + branches/PHP_5_2 Is used to release the PHP 5.2.x series. It is closed for + changes now. branches/PHP_5_1 This branch is closed. From 175f84436c97f8811f807fcb4915a28fee96bab0 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 16 Jun 2011 01:21:01 +0000 Subject: [PATCH 0166/2394] - install extra headers --- ext/session/config.w32 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/session/config.w32 b/ext/session/config.w32 index 27114f11d36b9..531fed1fb6618 100644 --- a/ext/session/config.w32 +++ b/ext/session/config.w32 @@ -6,5 +6,5 @@ ARG_ENABLE("session", "session support", "yes"); if (PHP_SESSION == "yes") { EXTENSION("session", "session.c mod_files.c mod_mm.c mod_user.c", false /* never shared */); AC_DEFINE("HAVE_PHP_SESSION", 1, "Session support"); - PHP_INSTALL_HEADERS("ext/session/", "mod_mm.h"); + PHP_INSTALL_HEADERS("ext/session/", "mod_mm.h php_session.h mod_files.h mod_user.h"); } From 1d357d964c9667ce8bdff4e62f23bf7be3e5bc30 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 16 Jun 2011 01:31:10 +0000 Subject: [PATCH 0167/2394] - init win32 rng context once per process --- main/main.c | 16 ++++++++++++- win32/winutil.c | 60 +++++++++++++++++++++++++++++++++++++++---------- win32/winutil.h | 8 +++++++ 3 files changed, 71 insertions(+), 13 deletions(-) diff --git a/main/main.c b/main/main.c index 7f944239ad16b..f6f6c2f636291 100644 --- a/main/main.c +++ b/main/main.c @@ -1885,11 +1885,21 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod #else php_os=PHP_OS; #endif - + { + char dll_dir[MAX_PATH]; + sprintf(dll_dir, "%s\\%s", module_path, "..\\..\\deps\\bin"); + SetDllDirectory(dll_dir); + } +// GetModuleFileName (NULL, module_path, MAX_PATH); +//__debugbreak(); #ifdef ZTS tsrm_ls = ts_resource(0); #endif +#ifdef PHP_WIN32 + php_win32_init_rng_lock(); +#endif + module_shutdown = 0; module_startup = 1; sapi_initialize_empty_request(TSRMLS_C); @@ -2241,6 +2251,10 @@ void php_module_shutdown(TSRMLS_D) WSACleanup(); #endif +#ifdef PHP_WIN32 + php_win32_free_rng_lock(); +#endif + sapi_flush(TSRMLS_C); zend_shutdown(TSRMLS_C); diff --git a/win32/winutil.c b/win32/winutil.c index 29f1f07cc38b6..b94fcc482ddb2 100644 --- a/win32/winutil.c +++ b/win32/winutil.c @@ -49,30 +49,66 @@ int php_win32_check_trailing_space(const char * path, const int path_len) { } } +HCRYPTPROV hCryptProv; +unsigned int has_crypto_ctx = 0; + +#ifdef ZTS +MUTEX_T php_lock_win32_cryptoctx; +void php_win32_init_rng_lock() +{ + php_lock_win32_cryptoctx = tsrm_mutex_alloc(); +} + +void php_win32_free_rng_lock() +{ + tsrm_mutex_lock(php_lock_win32_cryptoctx); + CryptReleaseContext(hCryptProv, 0); + has_crypto_ctx = 0; + tsrm_mutex_unlock(php_lock_win32_cryptoctx); + tsrm_mutex_free(php_lock_win32_cryptoctx); + +} +#else +#define php_win32_init_rng_lock(); +#define php_win32_free_rng_lock(); +#endif + + + PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{ */ - HCRYPTPROV hCryptProv; - int has_context = 0; + + unsigned int has_contextg = 0; + BOOL ret; size_t i = 0; - if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, 0)) { - /* Could mean that the key container does not exist, let try - again by asking for a new one */ - if (GetLastError() == NTE_BAD_KEYSET) { - if (CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_NEWKEYSET)) { - has_context = 1; - } else { - return FAILURE; + tsrm_mutex_lock(php_lock_win32_cryptoctx); + if (has_crypto_ctx == 0) { + if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_MACHINE_KEYSET)) { + /* Could mean that the key container does not exist, let try + again by asking for a new one */ + if (GetLastError() == NTE_BAD_KEYSET) { + if (CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_NEWKEYSET)) { + has_crypto_ctx = 1; + } else { + has_crypto_ctx = 0; + } } } } + tsrm_mutex_unlock(php_lock_win32_cryptoctx); + + if (has_crypto_ctx == 0) { + return FAILURE; + } ret = CryptGenRandom(hCryptProv, size, buf); - CryptReleaseContext(hCryptProv, 0); + if (ret) { return SUCCESS; + } else { + return FAILURE; } - return FAILURE; } /* }}} */ diff --git a/win32/winutil.h b/win32/winutil.h index 32721692b4e9b..3cf8a5abf27b2 100644 --- a/win32/winutil.h +++ b/win32/winutil.h @@ -21,3 +21,11 @@ PHPAPI char *php_win32_error_to_msg(int error); #define php_win_err() php_win32_error_to_msg(GetLastError()) int php_win32_check_trailing_space(const char * path, const int path_len); PHPAPI php_win32_get_random_bytes(unsigned char *buf, size_t size); + +#ifdef ZTS +void php_win32_init_rng_lock(); +void php_win32_free_rng_lock(); +#else +#define php_win32_init_rng_lock(); +#define php_win32_free_rng_lock(); +#endif From 6940a320aff3832585666c1ff2bd8b5b38ad71a0 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 16 Jun 2011 01:41:34 +0000 Subject: [PATCH 0168/2394] - Removed win debug stuff --- main/main.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/main/main.c b/main/main.c index f6f6c2f636291..9d8167681dd2d 100644 --- a/main/main.c +++ b/main/main.c @@ -1885,13 +1885,7 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod #else php_os=PHP_OS; #endif - { - char dll_dir[MAX_PATH]; - sprintf(dll_dir, "%s\\%s", module_path, "..\\..\\deps\\bin"); - SetDllDirectory(dll_dir); - } -// GetModuleFileName (NULL, module_path, MAX_PATH); -//__debugbreak(); + #ifdef ZTS tsrm_ls = ts_resource(0); #endif From c43276abd6d78a419cd3b3b4f20efe9a133ed603 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 16 Jun 2011 10:20:25 +0000 Subject: [PATCH 0169/2394] - fix nts build --- win32/winutil.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/win32/winutil.c b/win32/winutil.c index b94fcc482ddb2..dae01584a94e2 100644 --- a/win32/winutil.c +++ b/win32/winutil.c @@ -82,7 +82,10 @@ PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{ BOOL ret; size_t i = 0; +#ifdef ZTS tsrm_mutex_lock(php_lock_win32_cryptoctx); +#endif + if (has_crypto_ctx == 0) { if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_MACHINE_KEYSET)) { /* Could mean that the key container does not exist, let try @@ -96,7 +99,10 @@ PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{ } } } + +#ifdef ZTS tsrm_mutex_unlock(php_lock_win32_cryptoctx); +#endif if (has_crypto_ctx == 0) { return FAILURE; From 3c8bd9ebb68fbb6e82dfa8254f1081570aa44913 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 16 Jun 2011 13:06:41 +0000 Subject: [PATCH 0170/2394] - did I not kill that already? (do not use rand_screen, pointless on server and not TS) --- ext/openssl/openssl.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 0c61b5a254a0a..a36a523bff088 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -4920,10 +4920,6 @@ PHP_FUNCTION(openssl_random_pseudo_bytes) buffer = emalloc(buffer_length + 1); -#ifdef WINDOWS - RAND_screen(); -#endif - if ((strong_result = RAND_pseudo_bytes(buffer, buffer_length)) < 0) { efree(buffer); RETURN_FALSE; From a8cc93d54f5d04db81a4aa67abfa7049a526bf93 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 17 Jun 2011 02:00:20 +0000 Subject: [PATCH 0171/2394] - Fixed two "jump or move depends on uninitialised value" --- ext/pdo_firebird/firebird_driver.c | 1 + ext/pdo_firebird/firebird_statement.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/pdo_firebird/firebird_driver.c b/ext/pdo_firebird/firebird_driver.c index c154555637290..d9c61124758ce 100644 --- a/ext/pdo_firebird/firebird_driver.c +++ b/ext/pdo_firebird/firebird_driver.c @@ -232,6 +232,7 @@ static long firebird_handle_doer(pdo_dbh_t *dbh, const char *sql, long sql_len T /* TODO no placeholders in exec() for now */ in_sqlda.version = out_sqlda.version = PDO_FB_SQLDA_VERSION; in_sqlda.sqld = out_sqlda.sqld = 0; + out_sqlda.sqln = 1; /* allocate and prepare statement */ if (!firebird_alloc_prepare_stmt(dbh, sql, sql_len, &out_sqlda, &stmt, 0 TSRMLS_CC)) { diff --git a/ext/pdo_firebird/firebird_statement.c b/ext/pdo_firebird/firebird_statement.c index 3d45f185e75ba..6dcd09c35a76b 100644 --- a/ext/pdo_firebird/firebird_statement.c +++ b/ext/pdo_firebird/firebird_statement.c @@ -191,7 +191,7 @@ static int firebird_stmt_describe(pdo_stmt_t *stmt, int colno TSRMLS_DC) /* {{{ char *cp; /* allocate storage for the column */ - var->sqlind = (void*)emalloc(var->sqllen + 2*sizeof(short)); + var->sqlind = (void*)ecalloc(1, var->sqllen + 2*sizeof(short)); var->sqldata = &((char*)var->sqlind)[sizeof(short)]; colname_len = (S->H->fetch_table_names && var->relname_length) From 57d2f39c54dbbabed57206f264713d515b737fd4 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Fri, 17 Jun 2011 16:38:23 +0000 Subject: [PATCH 0172/2394] - Fixed bug where the DateTime object got changed while using date_diff(). --- ext/date/lib/interval.c | 10 +++++-- ext/date/tests/date_diff1.phpt | 48 ++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+), 2 deletions(-) create mode 100644 ext/date/tests/date_diff1.phpt diff --git a/ext/date/lib/interval.c b/ext/date/lib/interval.c index 6ac07419b4bce..c8200a48c349f 100644 --- a/ext/date/lib/interval.c +++ b/ext/date/lib/interval.c @@ -25,6 +25,7 @@ timelib_rel_time *timelib_diff(timelib_time *one, timelib_time *two) timelib_rel_time *rt; timelib_time *swp; timelib_sll dst_h_corr = 0, dst_m_corr = 0; + timelib_time one_backup, two_backup; rt = timelib_rel_time_ctor(); rt->invert = 0; @@ -45,6 +46,10 @@ timelib_rel_time *timelib_diff(timelib_time *one, timelib_time *two) dst_m_corr = ((two->z - one->z) % 3600) / 60; } + /* Save old TZ info */ + memcpy(&one_backup, one, sizeof(one_backup)); + memcpy(&two_backup, two, sizeof(two_backup)); + timelib_apply_localtime(one, 0); timelib_apply_localtime(two, 0); @@ -58,8 +63,9 @@ timelib_rel_time *timelib_diff(timelib_time *one, timelib_time *two) timelib_do_rel_normalize(rt->invert ? one : two, rt); - timelib_apply_localtime(one, 1); - timelib_apply_localtime(two, 1); + /* Restore old TZ info */ + memcpy(one, &one_backup, sizeof(one_backup)); + memcpy(two, &two_backup, sizeof(two_backup)); return rt; } diff --git a/ext/date/tests/date_diff1.phpt b/ext/date/tests/date_diff1.phpt new file mode 100644 index 0000000000000..cf32fcbf3ba7c --- /dev/null +++ b/ext/date/tests/date_diff1.phpt @@ -0,0 +1,48 @@ +--TEST-- +Test for date_diff with timezone abbreviations. +--INI-- +date.timezone=Europe/London +--FILE-- +diff($end); +var_dump($start); +var_dump($end); +var_dump($int); +?> +--EXPECT-- +object(DateTime)#1 (3) { + ["date"]=> + string(19) "2010-10-04 02:18:48" + ["timezone_type"]=> + int(2) + ["timezone"]=> + string(3) "EDT" +} +object(DateTime)#2 (3) { + ["date"]=> + string(19) "2010-11-06 18:38:28" + ["timezone_type"]=> + int(2) + ["timezone"]=> + string(3) "EDT" +} +object(DateInterval)#3 (8) { + ["y"]=> + int(0) + ["m"]=> + int(1) + ["d"]=> + int(2) + ["h"]=> + int(16) + ["i"]=> + int(19) + ["s"]=> + int(40) + ["invert"]=> + int(0) + ["days"]=> + int(33) +} From b3182fda70c1e0810ebbf6a25af0c1cb63bc89e5 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Fri, 17 Jun 2011 18:18:21 +0000 Subject: [PATCH 0173/2394] expand SNMP section --- NEWS | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/NEWS b/NEWS index 972d0e7503e11..284dd853508f5 100644 --- a/NEWS +++ b/NEWS @@ -206,14 +206,19 @@ PHP NEWS - Improved ZLIB extension: . Re-implemented non-file related functionality. (Mike) -- Improved SNMP extension: - . Added OO API. FR #53594. +- Improved SNMP extension (Boris Lytochkin): + . Added OO API. FR #53594 (php-snmp rewrite). . Sanitized return values of existing functions. Now it returns FALSE on failure. . Allow ~infinite OIDs in GET/GETNEXT/SET queries. Autochunk them to max_oids upon request. . Introducing unit tests for extension with ~full coverage. - . Fixed bugs #44193, #44193, #45893, #46065, #51336, #53862. + . Fixed bugs + . #44193 (snmp v3 noAuthNoPriv doesn't work) + . #45893 (Snmp buffer limited to 2048 char) + . #46065 (snmp_set_quick_print() persists between requests) + . #51336 (snmprealwalk (snmp v1) does not handle end of OID tree correctly) + . #53862 (snmp_set_oid_output_format does not allow returning to default) ## UNSORTED ## From dba594a4e21b8befafed029e010400a816066a97 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Fri, 17 Jun 2011 18:28:34 +0000 Subject: [PATCH 0174/2394] Fix skipif to resolve the common reason this test fails --- ext/phar/tests/bug52013.phpt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ext/phar/tests/bug52013.phpt b/ext/phar/tests/bug52013.phpt index f4635a4660e3c..5ee37e7d4e96f 100644 --- a/ext/phar/tests/bug52013.phpt +++ b/ext/phar/tests/bug52013.phpt @@ -6,7 +6,10 @@ http://bugs.php.net/bug.php?id=52013 --CREDITS-- Frederic Hardy frederic.hardy@mageekbox.net --SKIPIF-- - + --INI-- phar.require_hash=0 phar.readonly=0 From ade2d21f72d33e4f793420aec3446362384db832 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Fri, 17 Jun 2011 23:19:54 +0000 Subject: [PATCH 0175/2394] - added xml format to the status page - clean fpm_status.c code --- sapi/fpm/fpm/fpm_main.c | 28 +--- sapi/fpm/fpm/fpm_status.c | 270 +++++++++++++++++--------------------- sapi/fpm/fpm/fpm_status.h | 3 +- 3 files changed, 120 insertions(+), 181 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 6ec95a1ebdb75..f1bf162d5ae4c 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1831,7 +1831,6 @@ consult the installation file that came with this distribution, or visit \n\ zend_first_try { while (fcgi_accept_request(&request) >= 0) { - char *status_buffer, *status_content_type; request_body_fd = -1; SG(server_context) = (void *) &request; init_request_info(TSRMLS_C); @@ -1854,32 +1853,7 @@ consult the installation file that came with this distribution, or visit \n\ goto fastcgi_request_done; } - if (!strcasecmp(SG(request_info).request_method, "GET") && fpm_status_handle_status(SG(request_info).request_uri, SG(request_info).query_string, &status_buffer, &status_content_type)) { - if (status_buffer) { - if (status_content_type) { - sapi_add_header_ex(status_content_type, strlen(status_content_type), 1, 1 TSRMLS_CC); - } else { - sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); - } - - SG(sapi_headers).http_response_code = 200; - PUTS(status_buffer); - efree(status_buffer); - if (status_content_type) { - efree(status_content_type); - } - } else { - sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); - SG(sapi_headers).http_response_code = 500; - PUTS("Unable to retrieve status\n"); - } - goto fastcgi_request_done; - } - - if (!strcasecmp(SG(request_info).request_method, "GET") && (status_buffer = fpm_status_handle_ping(SG(request_info).request_uri))) { - sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); - SG(sapi_headers).http_response_code = 200; - PUTS(status_buffer); + if (fpm_status_handle_request()) { goto fastcgi_request_done; } diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 40df2bcaeebb0..1a2fd725207a4 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -3,6 +3,7 @@ /* (c) 2009 Jerome Loyet */ #include "php.h" +#include "SAPI.h" #include #include "fpm_config.h" @@ -13,8 +14,8 @@ struct fpm_shm_s *fpm_status_shm = NULL; static char *fpm_status_pool = NULL; static char *fpm_status_uri = NULL; -static char *fpm_status_ping= NULL; -static char *fpm_status_pong= NULL; +static char *fpm_status_ping_uri = NULL; +static char *fpm_status_ping_response = NULL; int fpm_status_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ @@ -40,8 +41,8 @@ int fpm_status_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ zlog(ZLOG_ERROR, "[pool %s] ping is set (%s) but pong is not set.", wp->config->name, wp->config->ping_path); return -1; } - fpm_status_ping = strdup(wp->config->ping_path); - fpm_status_pong = strdup(wp->config->ping_response); + fpm_status_ping_uri = strdup(wp->config->ping_path); + fpm_status_ping_response = strdup(wp->config->ping_response); } } return 0; @@ -159,174 +160,139 @@ void fpm_status_update_activity(struct fpm_shm_s *shm, int idle, int active, int } /* }}} */ -static void fpm_status_handle_status_txt(struct fpm_status_s *status, char **output, char **content_type) /* {{{ */ +int fpm_status_handle_request() /* {{{ */ { - if (!status || !output || !content_type) { - return; + struct fpm_status_s status; + char *buffer, *syntax; + + if (!SG(request_info).request_uri) { + return 0; } - spprintf(output, 0, - "pool: %s\n" - "process manager: %s\n" - "accepted conn: %lu\n" -#if HAVE_FPM_LQ - "listen queue len: %u\n" - "max listen queue len: %d\n" -#endif - "idle processes: %d\n" - "active processes: %d\n" - "total processes: %d\n" - "max children reached: %u\n", - fpm_status_pool, - status->pm == PM_STYLE_STATIC ? "static" : "dynamic", - status->accepted_conn, -#if HAVE_FPM_LQ - status->cur_lq, - status->max_lq, -#endif - status->idle, - status->active, - status->total, - status->max_children_reached); + /* PING */ + if (fpm_status_ping_uri && fpm_status_ping_response && !strcmp(fpm_status_ping_uri, SG(request_info).request_uri)) { + sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + SG(sapi_headers).http_response_code = 200; + PUTS(fpm_status_ping_response); + return 1; + } - spprintf(content_type, 0, "Content-Type: text/plain"); -} -/* }}} */ + /* STATUS */ + if (fpm_status_uri && !strcmp(fpm_status_uri, SG(request_info).request_uri)) { -static void fpm_status_handle_status_html(struct fpm_status_s *status, char **output, char **content_type) /* {{{ */ -{ - if (!status || !output || !content_type) { - return; - } + if (!fpm_status_shm || !fpm_status_shm->mem) { + zlog(ZLOG_ERROR, "[pool %s] unable to find or access status shared memory", fpm_status_pool); + SG(sapi_headers).http_response_code = 500; + sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + PUTS("Internal error. Please review log file for errors."); + return 1; + } + + /* one shot operation */ + status = *(struct fpm_status_s *)fpm_status_shm->mem; - spprintf(output, 0, - "\n" - "\n" - "\n" - "\n" + if (status.idle < 0 || status.active < 0 || status.total < 0) { + zlog(ZLOG_ERROR, "[pool %s] invalid status values", fpm_status_pool); + SG(sapi_headers).http_response_code = 500; + sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + PUTS("Internal error. Please review log file for errors."); + return 1; + } + + /* HTML */ + if (SG(request_info).query_string && strstr(SG(request_info).query_string, "html")) { + sapi_add_header_ex(ZEND_STRL("Content-Type: text/html"), 1, 1 TSRMLS_CC); + syntax = + "
pool%s
process manager%s
accepted conn%lu
\n" + "\n" + "\n" + "\n" #if HAVE_FPM_LQ - "\n" - "\n" + "\n" + "\n" #endif - "\n" - "\n" - "\n" - "\n" - "
pool%s
process manager%s
accepted conn%lu
listen queue len%u
max listen queue len%d
listen queue len%u
max listen queue len%d
idle processes%d
active processes%d
total processes%d
max children reached%u
", - fpm_status_pool, - status->pm == PM_STYLE_STATIC ? "static" : "dynamic", - status->accepted_conn, + "idle processes%d\n" + "active processes%d\n" + "total processes%d\n" + "max children reached%u\n" + ""; + + /* XML */ + } else if (SG(request_info).request_uri && strstr(SG(request_info).query_string, "xml")) { + sapi_add_header_ex(ZEND_STRL("Content-Type: text/xml"), 1, 1 TSRMLS_CC); + syntax = + "\n" + "\n" + "%s\n" + "%s\n" + "%lu\n" #if HAVE_FPM_LQ - status->cur_lq, - status->max_lq, + "%u\n" + "%d\n" #endif - status->idle, - status->active, - status->total, - status->max_children_reached); - - spprintf(content_type, 0, "Content-Type: text/html"); -} -/* }}} */ - -static void fpm_status_handle_status_json(struct fpm_status_s *status, char **output, char **content_type) /* {{{ */ -{ - if (!status || !output || !content_type) { - return; - } - - spprintf(output, 0, - "{" - "\"pool\":\"%s\"," - "\"process manager\":\"%s\"," - "\"accepted conn\":%lu," + "%d\n" + "%d\n" + "%d\n" + "%u\n" + ""; + + /* JSON */ + } else if (SG(request_info).request_uri && strstr(SG(request_info).query_string, "json")) { + sapi_add_header_ex(ZEND_STRL("Content-Type: application/json"), 1, 1 TSRMLS_CC); + + syntax = + "{" + "\"pool\":\"%s\"," + "\"process manager\":\"%s\"," + "\"accepted conn\":%lu," #if HAVE_FPM_LQ - "\"listen queue len\":%u," - "\"max listen queue len\":%d," + "\"listen queue len\":%u," + "\"max listen queue len\":%d," #endif - "\"idle processes\":%d," - "\"active processes\":%d," - "\"total processes\":%d," - "\"max children reached\":%u" - "}", - fpm_status_pool, - status->pm == PM_STYLE_STATIC ? "static" : "dynamic", - status->accepted_conn, + "\"idle processes\":%d," + "\"active processes\":%d," + "\"total processes\":%d," + "\"max children reached\":%u" + "}"; + + /* TEXT */ + } else { + sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + syntax = + "pool: %s\n" + "process manager: %s\n" + "accepted conn: %lu\n" #if HAVE_FPM_LQ - status->cur_lq, - status->max_lq, + "listen queue len: %u\n" + "max listen queue len: %d\n" #endif - status->idle, - status->active, - status->total, - status->max_children_reached); - - spprintf(content_type, 0, "Content-Type: application/json"); -} -/* }}} */ - -/* return 0 if it's not the request page - * return 1 if ouput has been set) - * *output unchanged: error (return 500) - * *output changed: no error (return 200) - */ -int fpm_status_handle_status(char *uri, char *query_string, char **output, char **content_type) /* {{{ */ -{ - struct fpm_status_s status; - - if (!fpm_status_uri || !uri) { - return 0; - } - - /* It's not the status page */ - if (strcmp(fpm_status_uri, uri)) { - return 0; - } - - if (!output || !content_type || !fpm_status_shm) { - return 1; - } - - if (!fpm_status_shm->mem) { - return 1; - } - - /* one shot operation */ - status = *(struct fpm_status_s *)fpm_status_shm->mem; + "idle processes: %d\n" + "active processes: %d\n" + "total processes: %d\n" + "max children reached: %u\n"; + } - if (status.idle < 0 || status.active < 0 || status.total < 0) { - return 1; - } + spprintf(&buffer, 0, syntax, + fpm_status_pool, + status.pm == PM_STYLE_STATIC ? "static" : "dynamic", + status.accepted_conn, +#if HAVE_FPM_LQ + status.cur_lq, + status.max_lq, +#endif + status.idle, + status.active, + status.total, + status.max_children_reached); - if (query_string && strstr(query_string, "html")) { - fpm_status_handle_status_html(&status, output, content_type); - } else if (query_string && strstr(query_string, "json")) { - fpm_status_handle_status_json(&status, output, content_type); - } else { - fpm_status_handle_status_txt(&status, output, content_type); - } + SG(sapi_headers).http_response_code = 200; + PUTS(buffer); + efree(buffer); - if (!*output || !content_type) { - zlog(ZLOG_ERROR, "[pool %s] unable to allocate status ouput buffer", fpm_status_pool); return 1; } - return 1; -} -/* }}} */ - -char *fpm_status_handle_ping(char *uri) /* {{{ */ -{ - if (!fpm_status_ping || !fpm_status_pong || !uri) { - return NULL; - } - - /* It's not the status page */ - if (strcmp(fpm_status_ping, uri)) { - return NULL; - } - - return fpm_status_pong; + return 0; } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_status.h b/sapi/fpm/fpm/fpm_status.h index 00e5af54e713f..b0ef1aa7101af 100644 --- a/sapi/fpm/fpm/fpm_status.h +++ b/sapi/fpm/fpm/fpm_status.h @@ -28,8 +28,7 @@ void fpm_status_increment_accepted_conn(struct fpm_shm_s *shm); void fpm_status_set_pm(struct fpm_shm_s *shm, int pm); void fpm_status_update_max_children_reached(struct fpm_shm_s *shm, unsigned int max_children_reached); void fpm_status_increment_max_children_reached(struct fpm_shm_s *shm); -int fpm_status_handle_status(char *uri, char *query_string, char **output, char **content_type); -char* fpm_status_handle_ping(char *uri); +int fpm_status_handle_request(); extern struct fpm_shm_s *fpm_status_shm; From 35458820adf6a9bc351776701dbf68ccd39d307b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Fri, 17 Jun 2011 23:35:47 +0000 Subject: [PATCH 0176/2394] missing doc in the conf file --- sapi/fpm/php-fpm.conf.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index cb480f538e3d9..c783601c2939c 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -195,11 +195,12 @@ pm.max_children = 50 ; total processes: 100 ; max children reached: 1 ; By default the status page output is formatted as text/plain. Passing either -; 'html' or 'json' as a query string will return the corresponding output +; 'html', 'xml' or 'json' as a query string will return the corresponding output ; syntax. Example: ; http://www.foo.bar/status ; http://www.foo.bar/status?json ; http://www.foo.bar/status?html +; http://www.foo.bar/status?xml ; Note: The value must start with a leading slash (/). The value can be ; anything, but it may not be a good idea to use the .php extension or it ; may conflict with a real PHP file. From 948d42d979720181902b0870f66e07a8c8a581ee Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sat, 18 Jun 2011 02:24:01 +0000 Subject: [PATCH 0177/2394] - fix build --- main/main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/main/main.c b/main/main.c index 9d8167681dd2d..f4a70cb113585 100644 --- a/main/main.c +++ b/main/main.c @@ -32,6 +32,7 @@ #include "win32/time.h" #include "win32/signal.h" #include "win32/php_win32_globals.h" +#include "win32/winutil.h" #include #elif defined(NETWARE) #include From e341a10d64b1899759e3b3300afb4331f0f4506c Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 18 Jun 2011 07:09:11 +0000 Subject: [PATCH 0178/2394] take over mantainership on snmp extension --- EXTENSIONS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/EXTENSIONS b/EXTENSIONS index 2bd721d8e68c3..f9c1c325c2715 100644 --- a/EXTENSIONS +++ b/EXTENSIONS @@ -497,8 +497,8 @@ STATUS: Working SINCE: 4.0.3 ------------------------------------------------------------------------------- EXTENSION: snmp -PRIMARY MAINTAINER: Rasmus Lerdorf , Pierre-Alain Joye -MAINTENANCE: Odd Fixes +PRIMARY MAINTAINER: Boris Lytochkin , Rasmus Lerdorf , Pierre-Alain Joye +MAINTENANCE: Maintained STATUS: Working ------------------------------------------------------------------------------- EXTENSION: sockets From b813d1ff23e5dc634e988e0e0e182ee8ec394669 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 18 Jun 2011 15:33:07 +0000 Subject: [PATCH 0179/2394] Remove timestamp in logs written by children process --- sapi/fpm/fpm/zlog.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/sapi/fpm/fpm/zlog.c b/sapi/fpm/fpm/zlog.c index ddf552b5022ba..fe62fd5ce66dc 100644 --- a/sapi/fpm/fpm/zlog.c +++ b/sapi/fpm/fpm/zlog.c @@ -13,6 +13,7 @@ #include #include "zlog.h" +#include "fpm.h" #define MAX_LINE_LENGTH 1024 @@ -47,7 +48,7 @@ size_t zlog_print_time(struct timeval *tv, char *timebuf, size_t timebuf_len) /* if (zlog_level == ZLOG_DEBUG) { len += snprintf(timebuf + len, timebuf_len - len, ".%06d", (int) tv->tv_usec); } - len += snprintf(timebuf + len, timebuf_len - len, "]"); + len += snprintf(timebuf + len, timebuf_len - len, "] "); return len; } /* }}} */ @@ -78,7 +79,7 @@ void zlog_ex(const char *function, int line, int flags, const char *fmt, ...) /* char buf[MAX_LINE_LENGTH]; const size_t buf_size = MAX_LINE_LENGTH; va_list args; - size_t len; + size_t len = 0; int truncated = 0; int saved_errno; @@ -87,12 +88,14 @@ void zlog_ex(const char *function, int line, int flags, const char *fmt, ...) /* } saved_errno = errno; - gettimeofday(&tv, 0); - len = zlog_print_time(&tv, buf, buf_size); + if (!fpm_globals.is_child) { + gettimeofday(&tv, 0); + len = zlog_print_time(&tv, buf, buf_size); + } if (zlog_level == ZLOG_DEBUG) { - len += snprintf(buf + len, buf_size - len, " %s: pid %d, %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], getpid(), function, line); + len += snprintf(buf + len, buf_size - len, "%s: pid %d, %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], getpid(), function, line); } else { - len += snprintf(buf + len, buf_size - len, " %s: ", level_names[flags & ZLOG_LEVEL_MASK]); + len += snprintf(buf + len, buf_size - len, "%s: ", level_names[flags & ZLOG_LEVEL_MASK]); } if (len > buf_size - 1) { From bf1779e973e95767eada7441d980bf191a40629b Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 18 Jun 2011 15:56:14 +0000 Subject: [PATCH 0180/2394] - Added missing arginfos for void params and void param checks --- ext/pdo/pdo_stmt.c | 21 ++++++------ ext/phar/phar_object.c | 73 ++++++++++++++++++++++-------------------- ext/simplexml/sxe.c | 47 +++++++++++++++++++++++---- ext/soap/soap.c | 5 ++- 4 files changed, 95 insertions(+), 51 deletions(-) diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c index 4a86da967b5d8..86f1543c8a547 100755 --- a/ext/pdo/pdo_stmt.c +++ b/ext/pdo/pdo_stmt.c @@ -38,6 +38,9 @@ #include "php_memory_streams.h" /* {{{ arginfo */ +ZEND_BEGIN_ARG_INFO(arginfo_pdostatement__void, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_pdostatement_execute, 0, 0, 0) ZEND_ARG_INFO(0, bound_input_params) /* array */ ZEND_END_ARG_INFO() @@ -2221,22 +2224,22 @@ const zend_function_entry pdo_dbstmt_functions[] = { PHP_ME(PDOStatement, bindParam, arginfo_pdostatement_bindparam, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, bindColumn, arginfo_pdostatement_bindcolumn, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, bindValue, arginfo_pdostatement_bindvalue, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, rowCount, NULL, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, rowCount, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, fetchColumn, arginfo_pdostatement_fetchcolumn, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, fetchAll, arginfo_pdostatement_fetchall, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, fetchObject, arginfo_pdostatement_fetchobject, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, errorCode, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, errorInfo, NULL, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, errorCode, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, errorInfo, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, setAttribute, arginfo_pdostatement_setattribute, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, getAttribute, arginfo_pdostatement_getattribute, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, columnCount, NULL, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, columnCount, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, getColumnMeta, arginfo_pdostatement_getcolumnmeta, ZEND_ACC_PUBLIC) PHP_ME(PDOStatement, setFetchMode, arginfo_pdostatement_setfetchmode, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, nextRowset, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, closeCursor, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, debugDumpParams, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PDOStatement, __wakeup, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL) - PHP_ME(PDOStatement, __sleep, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL) + PHP_ME(PDOStatement, nextRowset, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, closeCursor, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, debugDumpParams, arginfo_pdostatement__void, ZEND_ACC_PUBLIC) + PHP_ME(PDOStatement, __wakeup, arginfo_pdostatement__void, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL) + PHP_ME(PDOStatement, __sleep, arginfo_pdostatement__void, ZEND_ACC_PUBLIC|ZEND_ACC_FINAL) {NULL, NULL, NULL} }; diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index afe12851b5cdc..dbca2086d64a2 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -5299,6 +5299,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phar_isff, 0, 0, 1) ZEND_ARG_INFO(0, fileformat) ZEND_END_ARG_INFO() +PHAR_ARG_INFO +ZEND_BEGIN_ARG_INFO(arginfo_phar__void, 0) +ZEND_END_ARG_INFO() + + #endif /* HAVE_SPL */ zend_function_entry php_archive_methods[] = { @@ -5306,35 +5311,35 @@ zend_function_entry php_archive_methods[] = { PHP_ME(Phar, __construct, arginfo_phar___construct, ZEND_ACC_PRIVATE) #else PHP_ME(Phar, __construct, arginfo_phar___construct, ZEND_ACC_PUBLIC) - PHP_ME(Phar, __destruct, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, __destruct, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(Phar, addEmptyDir, arginfo_phar_emptydir, ZEND_ACC_PUBLIC) PHP_ME(Phar, addFile, arginfo_phar_addfile, ZEND_ACC_PUBLIC) PHP_ME(Phar, addFromString, arginfo_phar_fromstring, ZEND_ACC_PUBLIC) PHP_ME(Phar, buildFromDirectory, arginfo_phar_fromdir, ZEND_ACC_PUBLIC) PHP_ME(Phar, buildFromIterator, arginfo_phar_build, ZEND_ACC_PUBLIC) PHP_ME(Phar, compressFiles, arginfo_phar_comp, ZEND_ACC_PUBLIC) - PHP_ME(Phar, decompressFiles, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, decompressFiles, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(Phar, compress, arginfo_phar_comps, ZEND_ACC_PUBLIC) PHP_ME(Phar, decompress, arginfo_phar_decomp, ZEND_ACC_PUBLIC) PHP_ME(Phar, convertToExecutable, arginfo_phar_conv, ZEND_ACC_PUBLIC) PHP_ME(Phar, convertToData, arginfo_phar_conv, ZEND_ACC_PUBLIC) PHP_ME(Phar, copy, arginfo_phar_copy, ZEND_ACC_PUBLIC) - PHP_ME(Phar, count, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, count, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(Phar, delete, arginfo_phar_delete, ZEND_ACC_PUBLIC) - PHP_ME(Phar, delMetadata, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, delMetadata, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(Phar, extractTo, arginfo_phar_extract, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getAlias, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getPath, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getMetadata, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getModified, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getSignature, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getStub, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, getVersion, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, hasMetadata, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, isBuffering, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, isCompressed, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getAlias, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getPath, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getMetadata, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getModified, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getSignature, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getStub, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, getVersion, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, hasMetadata, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, isBuffering, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, isCompressed, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(Phar, isFileFormat, arginfo_phar_isff, ZEND_ACC_PUBLIC) - PHP_ME(Phar, isWritable, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, isWritable, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(Phar, offsetExists, arginfo_phar_offsetExists, ZEND_ACC_PUBLIC) PHP_ME(Phar, offsetGet, arginfo_phar_offsetExists, ZEND_ACC_PUBLIC) PHP_ME(Phar, offsetSet, arginfo_phar_offsetSet, ZEND_ACC_PUBLIC) @@ -5344,18 +5349,18 @@ zend_function_entry php_archive_methods[] = { PHP_ME(Phar, setMetadata, arginfo_phar_setMetadata, ZEND_ACC_PUBLIC) PHP_ME(Phar, setSignatureAlgorithm, arginfo_phar_setSigAlgo, ZEND_ACC_PUBLIC) PHP_ME(Phar, setStub, arginfo_phar_setStub, ZEND_ACC_PUBLIC) - PHP_ME(Phar, startBuffering, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phar, stopBuffering, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phar, startBuffering, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(Phar, stopBuffering, arginfo_phar__void, ZEND_ACC_PUBLIC) #endif /* static member functions */ - PHP_ME(Phar, apiVersion, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, canCompress, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, canWrite, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, apiVersion, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, canCompress, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, canWrite, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, createDefaultStub, arginfo_phar_createDS, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, getSupportedCompression,NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, getSupportedSignatures,NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, interceptFileFuncs, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, isValidPharFilename, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, getSupportedCompression,arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, getSupportedSignatures,arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, interceptFileFuncs, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, isValidPharFilename, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, loadPhar, arginfo_phar_loadPhar, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, mapPhar, arginfo_phar_mapPhar, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, running, arginfo_phar_running, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) @@ -5379,19 +5384,19 @@ ZEND_END_ARG_INFO() zend_function_entry php_entry_methods[] = { PHP_ME(PharFileInfo, __construct, arginfo_entry___construct, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, __destruct, NULL, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, __destruct, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(PharFileInfo, chmod, arginfo_entry_chmod, ZEND_ACC_PUBLIC) PHP_ME(PharFileInfo, compress, arginfo_phar_comp, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, decompress, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, delMetadata, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, getCompressedSize, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, getCRC32, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, getContent, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, getMetadata, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, getPharFlags, NULL, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, hasMetadata, NULL, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, decompress, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, delMetadata, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, getCompressedSize, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, getCRC32, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, getContent, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, getMetadata, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, getPharFlags, arginfo_phar__void, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, hasMetadata, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(PharFileInfo, isCompressed, arginfo_phar_compo, ZEND_ACC_PUBLIC) - PHP_ME(PharFileInfo, isCRCChecked, NULL, ZEND_ACC_PUBLIC) + PHP_ME(PharFileInfo, isCRCChecked, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(PharFileInfo, setMetadata, arginfo_phar_setMetadata, ZEND_ACC_PUBLIC) {NULL, NULL, NULL} }; diff --git a/ext/simplexml/sxe.c b/ext/simplexml/sxe.c index e6abf54dc1c09..527c35b655cb2 100755 --- a/ext/simplexml/sxe.c +++ b/ext/simplexml/sxe.c @@ -41,6 +41,10 @@ zend_class_entry *ce_SimpleXMLElement; PHP_METHOD(ce_SimpleXMLIterator, rewind) { php_sxe_iterator iter; + + if (zend_parse_parameters_none() == FAILURE) { + return; + } iter.sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); ce_SimpleXMLElement->iterator_funcs.funcs->rewind((zend_object_iterator*)&iter TSRMLS_CC); @@ -52,6 +56,10 @@ PHP_METHOD(ce_SimpleXMLIterator, rewind) PHP_METHOD(ce_SimpleXMLIterator, valid) { php_sxe_object *sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_BOOL(sxe->iter.data); } @@ -62,6 +70,10 @@ PHP_METHOD(ce_SimpleXMLIterator, valid) PHP_METHOD(ce_SimpleXMLIterator, current) { php_sxe_object *sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (!sxe->iter.data) { return; /* return NULL */ @@ -78,6 +90,10 @@ PHP_METHOD(ce_SimpleXMLIterator, key) xmlNodePtr curnode; php_sxe_object *intern; php_sxe_object *sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (!sxe->iter.data) { RETURN_FALSE; @@ -98,6 +114,10 @@ PHP_METHOD(ce_SimpleXMLIterator, key) PHP_METHOD(ce_SimpleXMLIterator, next) { php_sxe_iterator iter; + + if (zend_parse_parameters_none() == FAILURE) { + return; + } iter.sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); ce_SimpleXMLElement->iterator_funcs.funcs->move_forward((zend_object_iterator*)&iter TSRMLS_CC); @@ -111,6 +131,10 @@ PHP_METHOD(ce_SimpleXMLIterator, hasChildren) php_sxe_object *sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); php_sxe_object *child; xmlNodePtr node; + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (!sxe->iter.data || sxe->iter.type == SXE_ITER_ATTRLIST) { RETURN_FALSE; @@ -133,6 +157,10 @@ PHP_METHOD(ce_SimpleXMLIterator, hasChildren) PHP_METHOD(ce_SimpleXMLIterator, getChildren) { php_sxe_object *sxe = php_sxe_fetch_object(getThis() TSRMLS_CC); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (!sxe->iter.data || sxe->iter.type == SXE_ITER_ATTRLIST) { return; /* return NULL */ @@ -140,14 +168,19 @@ PHP_METHOD(ce_SimpleXMLIterator, getChildren) RETURN_ZVAL(sxe->iter.data, 1, 0); } +/* {{{ arginfo */ +ZEND_BEGIN_ARG_INFO(arginfo_simplexmliterator__void, 0) +ZEND_END_ARG_INFO() +/* }}} */ + static const zend_function_entry funcs_SimpleXMLIterator[] = { - PHP_ME(ce_SimpleXMLIterator, rewind, NULL, ZEND_ACC_PUBLIC) - PHP_ME(ce_SimpleXMLIterator, valid, NULL, ZEND_ACC_PUBLIC) - PHP_ME(ce_SimpleXMLIterator, current, NULL, ZEND_ACC_PUBLIC) - PHP_ME(ce_SimpleXMLIterator, key, NULL, ZEND_ACC_PUBLIC) - PHP_ME(ce_SimpleXMLIterator, next, NULL, ZEND_ACC_PUBLIC) - PHP_ME(ce_SimpleXMLIterator, hasChildren, NULL, ZEND_ACC_PUBLIC) - PHP_ME(ce_SimpleXMLIterator, getChildren, NULL, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, rewind, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, valid, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, current, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, key, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, next, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, hasChildren, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) + PHP_ME(ce_SimpleXMLIterator, getChildren, arginfo_simplexmliterator__void, ZEND_ACC_PUBLIC) {NULL, NULL, NULL} }; /* }}} */ diff --git a/ext/soap/soap.c b/ext/soap/soap.c index 07a3ee77219a5..89e7204157117 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -233,6 +233,9 @@ PHP_METHOD(SoapHeader, SoapHeader); #define SOAP_CTOR(class_name, func_name, arginfo, flags) PHP_ME(class_name, func_name, arginfo, flags) /* {{{ arginfo */ +ZEND_BEGIN_ARG_INFO(arginfo_soap__void, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_soapparam_soapparam, 0, 0, 2) ZEND_ARG_INFO(0, data) ZEND_ARG_INFO(0, name) @@ -379,7 +382,7 @@ static const zend_function_entry soap_functions[] = { static const zend_function_entry soap_fault_functions[] = { SOAP_CTOR(SoapFault, SoapFault, arginfo_soapfault_soapfault, 0) - PHP_ME(SoapFault, __toString, NULL, 0) + PHP_ME(SoapFault, __toString, arginfo_soap__void, 0) {NULL, NULL, NULL} }; From 7236ea5a4606a9b1b7436f4e598ce18d830fe966 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 18 Jun 2011 16:15:15 +0000 Subject: [PATCH 0181/2394] Fixed exit at FPM startup on fpm_resources_prepare --- sapi/fpm/fpm/fpm.c | 8 +++++++- sapi/fpm/fpm/fpm_children.c | 10 +++------- sapi/fpm/fpm/fpm_events.c | 9 ++++++--- sapi/fpm/fpm/fpm_events.h | 2 +- 4 files changed, 17 insertions(+), 12 deletions(-) diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index 0cfaabd414b12..e3fa3e3bd694b 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -90,10 +90,16 @@ int fpm_run(int *max_requests) /* {{{ */ if (!is_parent) { goto run_child; } + + /* handle error */ + if (is_parent == 2) { + fpm_pctl(FPM_PCTL_STATE_TERMINATING, FPM_PCTL_ACTION_SET); + fpm_event_loop(1); + } } /* run event loop forever */ - fpm_event_loop(); + fpm_event_loop(0); run_child: /* only workers reach this point */ diff --git a/sapi/fpm/fpm/fpm_children.c b/sapi/fpm/fpm/fpm_children.c index 499ad08e8f2af..476d5523deac5 100644 --- a/sapi/fpm/fpm/fpm_children.c +++ b/sapi/fpm/fpm/fpm_children.c @@ -350,7 +350,6 @@ static void fpm_parent_resources_use(struct fpm_child_s *child) /* {{{ */ int fpm_children_make(struct fpm_worker_pool_s *wp, int in_event_loop, int nb_to_spawn, int is_debug) /* {{{ */ { - int enough = 0; pid_t pid; struct fpm_child_s *child; int max; @@ -365,12 +364,11 @@ int fpm_children_make(struct fpm_worker_pool_s *wp, int in_event_loop, int nb_to max = wp->config->pm_max_children; } - while (!enough && fpm_pctl_can_spawn_children() && wp->running_children < max) { + while (fpm_pctl_can_spawn_children() && wp->running_children < max) { child = fpm_resources_prepare(wp); if (!child) { - enough = 1; - break; + return 2; } pid = fork(); @@ -385,11 +383,9 @@ int fpm_children_make(struct fpm_worker_pool_s *wp, int in_event_loop, int nb_to case -1 : zlog(ZLOG_SYSERROR, "fork() failed"); - enough = 1; fpm_resources_discard(child); - - break; /* dont try any more on error */ + return 2; default : child->pid = pid; diff --git a/sapi/fpm/fpm/fpm_events.c b/sapi/fpm/fpm/fpm_events.c index 66ff393e2f059..2bb4b94c00d57 100644 --- a/sapi/fpm/fpm/fpm_events.c +++ b/sapi/fpm/fpm/fpm_events.c @@ -235,7 +235,7 @@ int fpm_event_init_main() /* {{{ */ } /* }}} */ -void fpm_event_loop() /* {{{ */ +void fpm_event_loop(int err) /* {{{ */ { static struct fpm_event_s signal_fd_event; @@ -249,9 +249,12 @@ void fpm_event_loop() /* {{{ */ /* add timers */ fpm_pctl_heartbeat(NULL, 0, NULL); - fpm_pctl_perform_idle_server_maintenance_heartbeat(NULL, 0, NULL); - zlog(ZLOG_NOTICE, "ready to handle connections"); + if (!err) { + fpm_pctl_perform_idle_server_maintenance_heartbeat(NULL, 0, NULL); + + zlog(ZLOG_NOTICE, "ready to handle connections"); + } while (1) { struct fpm_event_queue_s *q, *q2; diff --git a/sapi/fpm/fpm/fpm_events.h b/sapi/fpm/fpm/fpm_events.h index bec13ba5e7665..586b24283565f 100644 --- a/sapi/fpm/fpm/fpm_events.h +++ b/sapi/fpm/fpm/fpm_events.h @@ -22,7 +22,7 @@ struct fpm_event_s { short which; /* type of event */ }; -void fpm_event_loop(); +void fpm_event_loop(int err); void fpm_event_fire(struct fpm_event_s *ev); int fpm_event_init_main(); int fpm_event_set(struct fpm_event_s *ev, int fd, int flags, void (*callback)(struct fpm_event_s *, short, void *), void *arg); From 8f0fdbb9e8560a1d990e9e0345274077caf526e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 18 Jun 2011 16:27:48 +0000 Subject: [PATCH 0182/2394] Added master rlimit_files and rlimit_core in the global configuration settings --- sapi/fpm/fpm/fpm_conf.c | 22 +++++++++++++--------- sapi/fpm/fpm/fpm_conf.h | 2 ++ sapi/fpm/fpm/fpm_unix.c | 26 ++++++++++++++++++++++++-- sapi/fpm/php-fpm.conf.in | 9 +++++++++ 4 files changed, 48 insertions(+), 11 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 5d6fe770cd92e..a8e2d60e26ec0 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -63,13 +63,15 @@ static char *ini_include = NULL; #define WPO(field) offsetof(struct fpm_worker_pool_config_s, field) static struct ini_value_parser_s ini_fpm_global_options[] = { - { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, - { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, - { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, - { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, - { "pid", &fpm_conf_set_string, GO(pid_file) }, - { "error_log", &fpm_conf_set_string, GO(error_log) }, + { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, + { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, + { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, + { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, + { "pid", &fpm_conf_set_string, GO(pid_file) }, + { "error_log", &fpm_conf_set_string, GO(error_log) }, { "log_level", &fpm_conf_set_log_level, 0 }, + { "rlimit_files", &fpm_conf_set_integer, GO(rlimit_files) }, + { "rlimit_core", &fpm_conf_set_rlimit_core,GO(rlimit_core) }, { 0, 0, 0 } }; @@ -255,10 +257,10 @@ static char *fpm_conf_set_log_level(zval *value, void **config, intptr_t offset) static char *fpm_conf_set_rlimit_core(zval *value, void **config, intptr_t offset) /* {{{ */ { char *val = Z_STRVAL_P(value); - struct fpm_worker_pool_config_s *c = *config; + int *ptr = (int *) ((char *) *config + offset); if (!strcasecmp(val, "unlimited")) { - c->rlimit_core = -1; + *ptr = -1; } else { int int_value; void *subconf = &int_value; @@ -274,7 +276,7 @@ static char *fpm_conf_set_rlimit_core(zval *value, void **config, intptr_t offse return "must be greater than zero or 'unlimited'"; } - c->rlimit_core = int_value; + *ptr = int_value; } return NULL; @@ -1117,6 +1119,8 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval); zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold); + zlog(ZLOG_NOTICE, "\trlimit_files = %d", fpm_global_config.rlimit_files); + zlog(ZLOG_NOTICE, "\trlimit_core = %d", fpm_global_config.rlimit_core); zlog(ZLOG_NOTICE, " "); for (wp = fpm_worker_all_pools; wp; wp = wp->next) { diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index ac38ee2e9a0c4..64b569006efb4 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -29,6 +29,8 @@ struct fpm_global_config_s { int daemonize; char *pid_file; char *error_log; + int rlimit_files; + int rlimit_core; }; extern struct fpm_global_config_s fpm_global_config; diff --git a/sapi/fpm/fpm/fpm_unix.c b/sapi/fpm/fpm/fpm_unix.c index d63ea4d5b01fc..d29d3879950f0 100644 --- a/sapi/fpm/fpm/fpm_unix.c +++ b/sapi/fpm/fpm/fpm_unix.c @@ -153,7 +153,7 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ r.rlim_max = r.rlim_cur = (rlim_t) wp->config->rlimit_files; if (0 > setrlimit(RLIMIT_NOFILE, &r)) { - zlog(ZLOG_SYSERROR, "[pool %s] setrlimit(RLIMIT_NOFILE, %d) failed (%d)", wp->config->name, wp->config->rlimit_files, errno); + zlog(ZLOG_SYSERROR, "[pool %s] unable to set rlimit_files for this pool. Please check your system limits or decrease rlimit_files. setrlimit(RLIMIT_NOFILE, %d) failed (%d)", wp->config->name, wp->config->rlimit_files, errno); } } @@ -163,7 +163,7 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ r.rlim_max = r.rlim_cur = wp->config->rlimit_core == -1 ? (rlim_t) RLIM_INFINITY : (rlim_t) wp->config->rlimit_core; if (0 > setrlimit(RLIMIT_CORE, &r)) { - zlog(ZLOG_SYSERROR, "[pool %s] setrlimit(RLIMIT_CORE, %d) failed (%d)", wp->config->name, wp->config->rlimit_core, errno); + zlog(ZLOG_SYSERROR, "[pool %s] unable to set rlimit_core for this pool. Please check your system limits or decrease rlimit_core. setrlimit(RLIMIT_CORE, %d) failed (%d)", wp->config->name, wp->config->rlimit_core, errno); } } @@ -220,6 +220,28 @@ int fpm_unix_init_main() /* {{{ */ { struct fpm_worker_pool_s *wp; + if (fpm_global_config.rlimit_files) { + struct rlimit r; + + r.rlim_max = r.rlim_cur = (rlim_t) fpm_global_config.rlimit_files; + + if (0 > setrlimit(RLIMIT_NOFILE, &r)) { + zlog(ZLOG_SYSERROR, "unable to set rlimit_core for this pool. Please check your system limits or decrease rlimit_files. setrlimit(RLIMIT_NOFILE, %d) failed (%d)", fpm_global_config.rlimit_files, errno); + return -1; + } + } + + if (fpm_global_config.rlimit_core) { + struct rlimit r; + + r.rlim_max = r.rlim_cur = fpm_global_config.rlimit_core == -1 ? (rlim_t) RLIM_INFINITY : (rlim_t) fpm_global_config.rlimit_core; + + if (0 > setrlimit(RLIMIT_CORE, &r)) { + zlog(ZLOG_SYSERROR, "unable to set rlimit_core for this pool. Please check your system limits or decrease rlimit_core. setrlimit(RLIMIT_CORE, %d) failed (%d)", fpm_global_config.rlimit_core, errno); + return -1; + } + } + fpm_pagesize = getpagesize(); if (fpm_global_config.daemonize) { switch (fork()) { diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index c783601c2939c..499eafcb6689e 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -57,6 +57,15 @@ ; Send FPM to background. Set to 'no' to keep FPM in foreground for debugging. ; Default Value: yes ;daemonize = yes + +; Set open file descriptor rlimit for the master process. +; Default Value: system defined value +;rlimit_files = 1024 + +; Set max core size rlimit for the master process. +; Possible Values: 'unlimited' or an integer greater or equal to 0 +; Default Value: system defined value +;rlimit_core = 0 ;;;;;;;;;;;;;;;;;;;; ; Pool Definitions ; From 17bf7723786443b29ae26b41372866a02113de27 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 18 Jun 2011 17:41:56 +0000 Subject: [PATCH 0183/2394] - Fixed ZTS build --- sapi/fpm/fpm/fpm_main.c | 2 +- sapi/fpm/fpm/fpm_status.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index f1bf162d5ae4c..9441e810fd97a 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1853,7 +1853,7 @@ consult the installation file that came with this distribution, or visit \n\ goto fastcgi_request_done; } - if (fpm_status_handle_request()) { + if (fpm_status_handle_request(TSRMLS_C)) { goto fastcgi_request_done; } diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 1a2fd725207a4..22ad159478346 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -160,7 +160,7 @@ void fpm_status_update_activity(struct fpm_shm_s *shm, int idle, int active, int } /* }}} */ -int fpm_status_handle_request() /* {{{ */ +int fpm_status_handle_request(TSRMLS_D) /* {{{ */ { struct fpm_status_s status; char *buffer, *syntax; From 8f76adb75071fc637d18e7f57fa08c866785faea Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 18 Jun 2011 17:46:16 +0000 Subject: [PATCH 0184/2394] - Missing change --- sapi/fpm/fpm/fpm_status.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/fpm/fpm/fpm_status.h b/sapi/fpm/fpm/fpm_status.h index b0ef1aa7101af..8f3daf9c72083 100644 --- a/sapi/fpm/fpm/fpm_status.h +++ b/sapi/fpm/fpm/fpm_status.h @@ -28,7 +28,7 @@ void fpm_status_increment_accepted_conn(struct fpm_shm_s *shm); void fpm_status_set_pm(struct fpm_shm_s *shm, int pm); void fpm_status_update_max_children_reached(struct fpm_shm_s *shm, unsigned int max_children_reached); void fpm_status_increment_max_children_reached(struct fpm_shm_s *shm); -int fpm_status_handle_request(); +int fpm_status_handle_request(TSRMLS_D); extern struct fpm_shm_s *fpm_status_shm; From 6ef38daf0e5e788c90a4a48f7afb66c65bd34bef Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 18 Jun 2011 18:11:27 +0000 Subject: [PATCH 0185/2394] - Fixed compiler warning (redefinition of offsetof) --- Zend/zend_operators.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 6987409f16433..7f831f93ffbef 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -451,8 +451,10 @@ ZEND_API void zend_update_current_locale(void); #define zend_update_current_locale() #endif +#ifndef offsetof #define offsetof(t,f) \ ((int)(&((t*)0)->f)) +#endif static zend_always_inline int fast_increment_function(zval *op1) { From 5992c064410510150ebccead3536098b6847fbcd Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 18 Jun 2011 22:48:31 +0000 Subject: [PATCH 0186/2394] - Added missing void param checks, and fix arginfo --- ext/phar/phar_object.c | 124 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 122 insertions(+), 2 deletions(-) diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index dbca2086d64a2..176d660a1cdce 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -1075,6 +1075,9 @@ PHP_METHOD(Phar, mungServer) */ PHP_METHOD(Phar, interceptFileFuncs) { + if (zend_parse_parameters_none() == FAILURE) { + return; + } phar_intercept_functions(TSRMLS_C); } /* }}} */ @@ -1152,6 +1155,9 @@ PHP_METHOD(Phar, loadPhar) * Returns the api version */ PHP_METHOD(Phar, apiVersion) { + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_STRINGL(PHP_PHAR_API_VERSION, sizeof(PHP_PHAR_API_VERSION)-1, 1); } /* }}}*/ @@ -1194,6 +1200,9 @@ PHP_METHOD(Phar, canCompress) * Returns whether phar extension supports writing and creating phars */ PHP_METHOD(Phar, canWrite) { + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_BOOL(!PHAR_G(readonly)); } /* }}} */ @@ -1401,6 +1410,10 @@ PHP_METHOD(Phar, __construct) */ PHP_METHOD(Phar, getSupportedSignatures) { + if (zend_parse_parameters_none() == FAILURE) { + return; + } + array_init(return_value); add_next_index_stringl(return_value, "MD5", 3, 1); @@ -1424,6 +1437,10 @@ PHP_METHOD(Phar, getSupportedSignatures) */ PHP_METHOD(Phar, getSupportedCompression) { + if (zend_parse_parameters_none() == FAILURE) { + return; + } + array_init(return_value); phar_request_initialize(TSRMLS_C); @@ -2087,6 +2104,10 @@ PHP_METHOD(Phar, buildFromIterator) PHP_METHOD(Phar, count) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_LONG(zend_hash_num_elements(&phar_obj->arc.archive->manifest)); } @@ -2710,6 +2731,10 @@ PHP_METHOD(Phar, convertToData) PHP_METHOD(Phar, isCompressed) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (phar_obj->arc.archive->flags & PHAR_FILE_COMPRESSED_GZ) { RETURN_LONG(PHAR_ENT_COMPRESSED_GZ); @@ -2730,6 +2755,10 @@ PHP_METHOD(Phar, isWritable) { php_stream_statbuf ssb; PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (!phar_obj->arc.archive->is_writeable) { RETURN_FALSE; @@ -2804,6 +2833,10 @@ PHP_METHOD(Phar, delete) PHP_METHOD(Phar, getAlias) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (phar_obj->arc.archive->alias && phar_obj->arc.archive->alias != phar_obj->arc.archive->fname) { RETURN_STRINGL(phar_obj->arc.archive->alias, phar_obj->arc.archive->alias_len, 1); @@ -2817,6 +2850,10 @@ PHP_METHOD(Phar, getAlias) PHP_METHOD(Phar, getPath) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_STRINGL(phar_obj->arc.archive->fname, phar_obj->arc.archive->fname_len, 1); } @@ -2929,6 +2966,10 @@ PHP_METHOD(Phar, setAlias) PHP_METHOD(Phar, getVersion) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_STRING(phar_obj->arc.archive->version, 1); } @@ -2940,6 +2981,10 @@ PHP_METHOD(Phar, getVersion) PHP_METHOD(Phar, startBuffering) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } phar_obj->arc.archive->donotflush = 1; } @@ -2951,6 +2996,10 @@ PHP_METHOD(Phar, startBuffering) PHP_METHOD(Phar, isBuffering) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_BOOL(phar_obj->arc.archive->donotflush); } @@ -2964,6 +3013,10 @@ PHP_METHOD(Phar, stopBuffering) char *error; PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, @@ -3195,6 +3248,10 @@ PHP_METHOD(Phar, setSignatureAlgorithm) PHP_METHOD(Phar, getSignature) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (phar_obj->arc.archive->signature) { char *unknown; @@ -3235,6 +3292,10 @@ PHP_METHOD(Phar, getSignature) PHP_METHOD(Phar, getModified) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_BOOL(phar_obj->arc.archive->is_modified); } @@ -3493,6 +3554,10 @@ PHP_METHOD(Phar, decompressFiles) { char *error; PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, @@ -4010,6 +4075,10 @@ PHP_METHOD(Phar, getStub) phar_entry_info *stub; PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (phar_obj->arc.archive->is_tar || phar_obj->arc.archive->is_zip) { @@ -4106,6 +4175,10 @@ PHP_METHOD(Phar, hasMetadata) PHP_METHOD(Phar, getMetadata) { PHAR_ARCHIVE_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (phar_obj->arc.archive->metadata) { if (phar_obj->arc.archive->is_persistent) { @@ -4598,6 +4671,10 @@ PHP_METHOD(PharFileInfo, __destruct) PHP_METHOD(PharFileInfo, getCompressedSize) { PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_LONG(entry_obj->ent.entry->compressed_filesize); } @@ -4636,6 +4713,10 @@ PHP_METHOD(PharFileInfo, isCompressed) PHP_METHOD(PharFileInfo, getCRC32) { PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (entry_obj->ent.entry->is_dir) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, \ @@ -4658,6 +4739,10 @@ PHP_METHOD(PharFileInfo, getCRC32) PHP_METHOD(PharFileInfo, isCRCChecked) { PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_BOOL(entry_obj->ent.entry->is_crc_checked); } @@ -4669,6 +4754,10 @@ PHP_METHOD(PharFileInfo, isCRCChecked) PHP_METHOD(PharFileInfo, getPharFlags) { PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_LONG(entry_obj->ent.entry->flags & ~(PHAR_ENT_PERM_MASK|PHAR_ENT_COMPRESSION_MASK)); } @@ -4743,6 +4832,10 @@ PHP_METHOD(PharFileInfo, chmod) PHP_METHOD(PharFileInfo, hasMetadata) { PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_BOOL(entry_obj->ent.entry->metadata != NULL); } @@ -4754,6 +4847,10 @@ PHP_METHOD(PharFileInfo, hasMetadata) PHP_METHOD(PharFileInfo, getMetadata) { PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (entry_obj->ent.entry->metadata) { if (entry_obj->ent.entry->is_persistent) { @@ -4831,6 +4928,10 @@ PHP_METHOD(PharFileInfo, delMetadata) char *error; PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (PHAR_G(readonly) && !entry_obj->ent.entry->phar->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.readonly"); @@ -4885,6 +4986,10 @@ PHP_METHOD(PharFileInfo, getContent) phar_entry_info *link; PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (entry_obj->ent.entry->is_dir) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, @@ -5059,6 +5164,10 @@ PHP_METHOD(PharFileInfo, decompress) { char *error; PHAR_ENTRY_OBJECT(); + + if (zend_parse_parameters_none() == FAILURE) { + return; + } if (entry_obj->ent.entry->is_dir) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, \ @@ -5143,6 +5252,17 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phar_createDS, 0, 0, 0) ZEND_ARG_INFO(0, webindex) ZEND_END_ARG_INFO() +PHAR_ARG_INFO +ZEND_BEGIN_ARG_INFO_EX(arginfo_phar_cancompress, 0, 0, 0) + ZEND_ARG_INFO(0, method) +ZEND_END_ARG_INFO() + +PHAR_ARG_INFO +ZEND_BEGIN_ARG_INFO_EX(arginfo_phar_isvalidpharfilename, 0, 0, 1) + ZEND_ARG_INFO(0, filename) + ZEND_ARG_INFO(0, executable) +ZEND_END_ARG_INFO() + PHAR_ARG_INFO ZEND_BEGIN_ARG_INFO_EX(arginfo_phar_loadPhar, 0, 0, 1) ZEND_ARG_INFO(0, filename) @@ -5354,13 +5474,13 @@ zend_function_entry php_archive_methods[] = { #endif /* static member functions */ PHP_ME(Phar, apiVersion, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, canCompress, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, canCompress, arginfo_phar_cancompress, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, canWrite, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, createDefaultStub, arginfo_phar_createDS, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, getSupportedCompression,arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, getSupportedSignatures,arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, interceptFileFuncs, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - PHP_ME(Phar, isValidPharFilename, arginfo_phar__void, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) + PHP_ME(Phar, isValidPharFilename, arginfo_phar_isvalidpharfilename, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, loadPhar, arginfo_phar_loadPhar, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, mapPhar, arginfo_phar_mapPhar, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, running, arginfo_phar_running, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) From b0bbfee7e8d9005a02cbc613bbc85288774653dd Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 00:18:17 +0000 Subject: [PATCH 0187/2394] - Fix test --- Zend/tests/declare_003.phpt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Zend/tests/declare_003.phpt b/Zend/tests/declare_003.phpt index 73cc68195b118..2980f7589b73c 100644 --- a/Zend/tests/declare_003.phpt +++ b/Zend/tests/declare_003.phpt @@ -1,12 +1,13 @@ --TEST-- Testing declare statement with several type values --INI-- +precision=15 zend.multibyte=1 --FILE-- Date: Sun, 19 Jun 2011 12:33:49 +0000 Subject: [PATCH 0188/2394] - New tests (code coverage++) --- .../tests/pdo_sqlite_createaggregate_002.phpt | 17 +++++++++++++++++ .../tests/pdo_sqlite_get_attribute.phpt | 15 +++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 ext/pdo_sqlite/tests/pdo_sqlite_createaggregate_002.phpt create mode 100644 ext/pdo_sqlite/tests/pdo_sqlite_get_attribute.phpt diff --git a/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate_002.phpt b/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate_002.phpt new file mode 100644 index 0000000000000..671e4b3454cc2 --- /dev/null +++ b/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate_002.phpt @@ -0,0 +1,17 @@ +--TEST-- +PDO_sqlite: Testing invalid callback for sqliteCreateAggregate() +--SKIPIF-- + +--FILE-- +sqliteCreateAggregate('foo', 'a', ''); +$pdo->sqliteCreateAggregate('foo', 'strlen', ''); + +?> +--EXPECTF-- +Warning: PDO::sqliteCreateAggregate(): function 'a' is not callable in %s on line %d + +Warning: PDO::sqliteCreateAggregate(): function '' is not callable in %s on line %d diff --git a/ext/pdo_sqlite/tests/pdo_sqlite_get_attribute.phpt b/ext/pdo_sqlite/tests/pdo_sqlite_get_attribute.phpt new file mode 100644 index 0000000000000..d6e095d54a937 --- /dev/null +++ b/ext/pdo_sqlite/tests/pdo_sqlite_get_attribute.phpt @@ -0,0 +1,15 @@ +--TEST-- +PDO_sqlite: Testing getAttribute() +--SKIPIF-- + +--FILE-- +getAttribute(PDO::ATTR_SERVER_VERSION)); +var_dump($pdo->getAttribute(PDO::ATTR_CLIENT_VERSION)); + +?> +--EXPECTF-- +string(%d) "%s" +string(%d) "%s" From 744ce6af65e299bc8fad8e3b6f2bdfd95541d586 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 12:58:56 +0000 Subject: [PATCH 0189/2394] - Fix test --- ext/fileinfo/tests/finfo_open_001.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/fileinfo/tests/finfo_open_001.phpt b/ext/fileinfo/tests/finfo_open_001.phpt index 69696ebe332ee..9513b54bad3bb 100644 --- a/ext/fileinfo/tests/finfo_open_001.phpt +++ b/ext/fileinfo/tests/finfo_open_001.phpt @@ -14,7 +14,7 @@ var_dump(finfo_open(FILEINFO_MIME, '/foo/bar/inexistent')); ?> --EXPECTF-- -Warning: finfo_open(): Failed to load magic database at ''. in %s on line %d +Warning: finfo_open() expects parameter 2 to be a valid path, string given in %s on line %d bool(false) resource(%d) of type (file_info) resource(%d) of type (file_info) From e98eafeedf6e2b21a6c5f82cd4764e158659e38c Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 13:20:12 +0000 Subject: [PATCH 0190/2394] - Missing usage of 'p' parameter specifier --- ext/standard/file.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/ext/standard/file.c b/ext/standard/file.c index 6bb1ad0518b7e..6748d326a7aec 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -381,7 +381,7 @@ PHP_FUNCTION(get_meta_tags) memset(&md, 0, sizeof(md)); /* Parse arguments */ - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &filename, &filename_len, &use_include_path) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &filename, &filename_len, &use_include_path) == FAILURE) { return; } @@ -534,7 +534,7 @@ PHP_FUNCTION(file_get_contents) php_stream_context *context = NULL; /* Parse arguments */ - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|br!ll", &filename, &filename_len, &use_include_path, &zcontext, &offset, &maxlen) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|br!ll", &filename, &filename_len, &use_include_path, &zcontext, &offset, &maxlen) == FAILURE) { return; } @@ -590,7 +590,7 @@ PHP_FUNCTION(file_put_contents) php_stream *srcstream = NULL; char mode[3] = "wb"; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz/|lr!", &filename, &filename_len, &data, &flags, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pz/|lr!", &filename, &filename_len, &data, &flags, &zcontext) == FAILURE) { return; } @@ -735,7 +735,7 @@ PHP_FUNCTION(file) php_stream_context *context = NULL; /* Parse arguments */ - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|lr!", &filename, &filename_len, &flags, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|lr!", &filename, &filename_len, &flags, &zcontext) == FAILURE) { return; } if (flags < 0 || flags > (PHP_FILE_USE_INCLUDE_PATH | PHP_FILE_IGNORE_NEW_LINES | PHP_FILE_SKIP_EMPTY_LINES | PHP_FILE_NO_DEFAULT_CONTEXT)) { @@ -1349,7 +1349,7 @@ PHP_FUNCTION(mkdir) zend_bool recursive = 0; php_stream_context *context; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|lbr", &dir, &dir_len, &mode, &recursive, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|lbr", &dir, &dir_len, &mode, &recursive, &zcontext) == FAILURE) { RETURN_FALSE; } @@ -1390,7 +1390,7 @@ PHP_FUNCTION(readfile) php_stream *stream; php_stream_context *context = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|br!", &filename, &filename_len, &use_include_path, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|br!", &filename, &filename_len, &use_include_path, &zcontext) == FAILURE) { RETURN_FALSE; } @@ -1463,7 +1463,7 @@ PHP_FUNCTION(rename) php_stream_wrapper *wrapper; php_stream_context *context; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|r", &old_name, &old_name_len, &new_name, &new_name_len, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pp|r", &old_name, &old_name_len, &new_name, &new_name_len, &zcontext) == FAILURE) { RETURN_FALSE; } @@ -1500,7 +1500,7 @@ PHP_FUNCTION(unlink) zval *zcontext = NULL; php_stream_context *context = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|r", &filename, &filename_len, &zcontext) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|r", &filename, &filename_len, &zcontext) == FAILURE) { RETURN_FALSE; } @@ -2469,7 +2469,7 @@ PHP_FUNCTION(fnmatch) int pattern_len, filename_len; long flags = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|l", &pattern, &pattern_len, &filename, &filename_len, &flags) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pp|l", &pattern, &pattern_len, &filename, &filename_len, &flags) == FAILURE) { return; } From 54d5662919f9490ba19566de952272895a7483ea Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 14:27:33 +0000 Subject: [PATCH 0191/2394] - Added missing void param check in sys_get_temp_dir - Fixed param check of umask() --- ext/standard/file.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/ext/standard/file.c b/ext/standard/file.c index 6748d326a7aec..3fe4ef69ea510 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -1413,7 +1413,10 @@ PHP_FUNCTION(umask) { long arg1 = 0; int oldumask; - int arg_count = ZEND_NUM_ARGS(); + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &arg1) == FAILURE) { + RETURN_FALSE; + } oldumask = umask(077); @@ -1421,12 +1424,9 @@ PHP_FUNCTION(umask) BG(umask) = oldumask; } - if (arg_count == 0) { + if (ZEND_NUM_ARGS() == 0) { umask(oldumask); } else { - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &arg1) == FAILURE) { - RETURN_FALSE; - } umask(arg1); } @@ -2491,6 +2491,9 @@ PHP_FUNCTION(fnmatch) Returns directory path used for temporary files */ PHP_FUNCTION(sys_get_temp_dir) { + if (zend_parse_parameters_none() == FAILURE) { + return; + } RETURN_STRING((char *)php_get_temporary_directory(), 1); } /* }}} */ From 3276cc4f7a7673549a44b7210184f53653f95d72 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 14:50:44 +0000 Subject: [PATCH 0192/2394] - Opss, restore old behavior --- ext/standard/file.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/standard/file.c b/ext/standard/file.c index 3fe4ef69ea510..0d6f7cf5ce496 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -1414,15 +1414,15 @@ PHP_FUNCTION(umask) long arg1 = 0; int oldumask; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &arg1) == FAILURE) { - RETURN_FALSE; - } - oldumask = umask(077); if (BG(umask) == -1) { BG(umask) = oldumask; } + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &arg1) == FAILURE) { + RETURN_FALSE; + } if (ZEND_NUM_ARGS() == 0) { umask(oldumask); From 8f68b4851474d1e69d85ad6c51a6fcf950f5a5de Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 15:43:16 +0000 Subject: [PATCH 0193/2394] - Fix tests --- .../file/file_get_contents_variation8.phpt | 8 +- .../file/file_put_contents_variation8.phpt | Bin 2302 -> 2335 bytes ext/standard/tests/file/file_variation2.phpt | 10 +- ext/standard/tests/file/fnmatch_error.phpt | 6 +- .../tests/file/fnmatch_variation.phpt | 134 +++++++++++++----- .../tests/file/mkdir_rmdir_variation2.phpt | 10 +- .../tests/file/readfile_variation10.phpt | Bin 1786 -> 1819 bytes .../tests/file/rename_variation13.phpt | 12 +- 8 files changed, 126 insertions(+), 54 deletions(-) diff --git a/ext/standard/tests/file/file_get_contents_variation8.phpt b/ext/standard/tests/file/file_get_contents_variation8.phpt index dca75a02ef982..40efe26830478 100644 --- a/ext/standard/tests/file/file_get_contents_variation8.phpt +++ b/ext/standard/tests/file/file_get_contents_variation8.phpt @@ -69,15 +69,15 @@ Warning: file_get_contents( ): failed to open stream: No such file or directory bool(false) -- Iteration 6 -- -Warning: file_get_contents(): Filename cannot be empty in %s on line %d -bool(false) +Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %s on line %d +NULL -- Iteration 7 -- -Warning: file_get_contents() expects parameter 1 to be string, array given in %s on line %d +Warning: file_get_contents() expects parameter 1 to be a valid path, array given in %s on line %d NULL -- Iteration 8 -- -Warning: file_get_contents(/no/such/file/dir): failed to open stream: %s in %s on line %d +Warning: file_get_contents(/no/such/file/dir): failed to open stream: No such file or directory in %s on line %d bool(false) -- Iteration 9 -- diff --git a/ext/standard/tests/file/file_put_contents_variation8.phpt b/ext/standard/tests/file/file_put_contents_variation8.phpt index 1e27e71334165f687b4bf263cfd56e934dbce78d..d4c0bffca17200e84b10feb2183de88a887a2b7f 100644 GIT binary patch delta 58 zcmew-IA3Uk6#L`}?9w8M3T25onJEedi6t323dJQwnR)4xcd#2yj%WAbL6+RSk=>UO E08^|K7XSbN delta 27 jcmbO)^iObu6#L{_HrL5j>^^M8B}JKe>6 --EXPECTF-- *** Testing error conditions for fnmatch() *** -Warning: fnmatch() expects parameter 1 to be string, array given in %s on line %d%d +Warning: fnmatch() expects parameter 1 to be a valid path, array given in %s on line %d NULL -Warning: fnmatch() expects parameter 1 to be string, resource given in %s on line %d%d +Warning: fnmatch() expects parameter 1 to be a valid path, resource given in %s on line %d NULL -Warning: fnmatch() expects parameter 1 to be string, object given in %s on line %d%d +Warning: fnmatch() expects parameter 1 to be a valid path, object given in %s on line %d NULL Warning: fnmatch() expects at least 2 parameters, 1 given in %s on line %d%d diff --git a/ext/standard/tests/file/fnmatch_variation.phpt b/ext/standard/tests/file/fnmatch_variation.phpt index e65bdd0555386..6d28528c1ce92 100644 --- a/ext/standard/tests/file/fnmatch_variation.phpt +++ b/ext/standard/tests/file/fnmatch_variation.phpt @@ -134,7 +134,7 @@ match($null_arr, $null_arr); echo "\n*** Done ***\n"; ?> ---EXPECT-- +--EXPECTF-- *** Testing fnmatch() with file and various patterns *** -- Iteration 0 -- bool(true) @@ -183,9 +183,13 @@ bool(false) -- Iteration 22 -- bool(false) -- Iteration 23 -- -bool(false) + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL -- Iteration 24 -- -bool(false) + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL -- Iteration 25 -- bool(false) -- Iteration 26 -- @@ -259,44 +263,84 @@ bool(true) --- With Strings --- -- Iteration 0 -- bool(true) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(true) -bool(true) -bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(true) -- Iteration 1 -- -bool(true) -bool(true) -bool(true) -bool(false) -bool(false) -bool(true) + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL -- Iteration 2 -- bool(true) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(true) -bool(true) -bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(true) -- Iteration 3 -- -bool(false) -bool(false) -bool(false) -bool(true) -bool(false) -bool(false) + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL -- Iteration 4 -- bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) -bool(false) -bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(true) bool(false) -- Iteration 5 -- bool(true) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(true) -bool(true) -bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(true) @@ -397,42 +441,64 @@ bool(true) bool(true) bool(true) bool(true) -bool(true) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(false) -- Iteration 1 -- bool(true) bool(true) bool(true) -bool(true) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(false) -- Iteration 2 -- bool(true) bool(true) bool(true) -bool(true) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(false) -- Iteration 3 -- -bool(true) -bool(true) -bool(true) -bool(true) -bool(false) -bool(false) + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL + +Warning: fnmatch() expects parameter 1 to be a valid path, string given in %s on line %d +NULL -- Iteration 4 -- bool(false) bool(false) bool(false) -bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(true) bool(false) -- Iteration 5 -- bool(false) bool(false) bool(false) -bool(false) + +Warning: fnmatch() expects parameter 2 to be a valid path, string given in %s on line %d +NULL bool(false) bool(true) diff --git a/ext/standard/tests/file/mkdir_rmdir_variation2.phpt b/ext/standard/tests/file/mkdir_rmdir_variation2.phpt index e7c41c4a9dfd6..14dd361e07e85 100644 --- a/ext/standard/tests/file/mkdir_rmdir_variation2.phpt +++ b/ext/standard/tests/file/mkdir_rmdir_variation2.phpt @@ -64,13 +64,17 @@ Warning: rmdir(%s/mkdir_variation2/): %s on line %d bool(false) *** Testing mkdir() and rmdir() for binary safe functionality *** -bool(true) -bool(true) + +Warning: mkdir() expects parameter 1 to be a valid path, string given in %s on line %d +bool(false) + +Warning: rmdir(%s): No such file or directory in %s on line %d +bool(false) *** Testing mkdir() with miscelleneous input *** bool(true) -Warning: mkdir(): Permission denied in %sfile/mkdir_rmdir_variation2.php on line %d +Warning: mkdir(): Permission denied in %s on line %d bool(false) bool(true) Done diff --git a/ext/standard/tests/file/readfile_variation10.phpt b/ext/standard/tests/file/readfile_variation10.phpt index a48150aee0fcf1240a7f47b7939c317043ae037f..2b48d4eed50172cc83a27e020d7094dd6562685c 100644 GIT binary patch delta 57 zcmeyxJDYFAJl4rySfxc070MEGGE)=^5=%046pBlVGV{_W%dn|TzQ$_FgDg2&l Date: Sun, 19 Jun 2011 16:55:11 +0000 Subject: [PATCH 0194/2394] Split DateTime diff/add/sub tests into separate files to make things easier to see, test and (one hopes) fix. --- ext/date/tests/DateTime_add-dates.phpt | 29 ++ .../tests/DateTime_add-fall-type2-type2.phpt | 51 ++++ .../tests/DateTime_add-fall-type2-type3.phpt | 51 ++++ .../tests/DateTime_add-fall-type3-type2.phpt | 51 ++++ .../tests/DateTime_add-fall-type3-type3.phpt | 51 ++++ ext/date/tests/DateTime_add-february.phpt | 77 +++++ ext/date/tests/DateTime_add-massive.phpt | 15 + .../DateTime_add-spring-type2-type2.phpt | 31 ++ .../DateTime_add-spring-type2-type3.phpt | 31 ++ .../DateTime_add-spring-type3-type2.phpt | 31 ++ .../DateTime_add-spring-type3-type3.phpt | 31 ++ ext/date/tests/DateTime_data-absolute.inc | 24 ++ ext/date/tests/DateTime_data-dates.inc | 64 ++++ ...hpt => DateTime_data-fall-type2-type2.inc} | 45 --- ...hpt => DateTime_data-fall-type2-type3.inc} | 45 --- ...hpt => DateTime_data-fall-type3-type2.inc} | 45 --- ...hpt => DateTime_data-fall-type3-type3.inc} | 45 --- ext/date/tests/DateTime_data-february.inc | 208 +++++++++++++ ...massive.phpt => DateTime_data-massive.inc} | 11 - ...t => DateTime_data-spring-type2-type2.inc} | 25 -- ...t => DateTime_data-spring-type2-type3.inc} | 25 -- ...t => DateTime_data-spring-type3-type2.inc} | 25 -- ...t => DateTime_data-spring-type3-type3.inc} | 25 -- ext/date/tests/DateTime_days-absolute.phpt | 15 + ext/date/tests/DateTime_days-dates.phpt | 29 ++ .../tests/DateTime_days-fall-type2-type2.phpt | 49 +++ .../tests/DateTime_days-fall-type2-type3.phpt | 49 +++ .../tests/DateTime_days-fall-type3-type2.phpt | 49 +++ .../tests/DateTime_days-fall-type3-type3.phpt | 49 +++ ext/date/tests/DateTime_days-february.phpt | 77 +++++ ext/date/tests/DateTime_days-massive.phpt | 15 + .../DateTime_days-spring-type2-type2.phpt | 29 ++ .../DateTime_days-spring-type2-type3.phpt | 29 ++ .../DateTime_days-spring-type3-type2.phpt | 29 ++ .../DateTime_days-spring-type3-type3.phpt | 29 ++ ext/date/tests/DateTime_diff-absolute.phpt | 15 + ext/date/tests/DateTime_diff-dates.phpt | 29 ++ .../tests/DateTime_diff-fall-type2-type2.phpt | 51 ++++ .../tests/DateTime_diff-fall-type2-type3.phpt | 51 ++++ .../tests/DateTime_diff-fall-type3-type2.phpt | 51 ++++ .../tests/DateTime_diff-fall-type3-type3.phpt | 51 ++++ ext/date/tests/DateTime_diff-february.phpt | 77 +++++ ext/date/tests/DateTime_diff-massive.phpt | 15 + .../DateTime_diff-spring-type2-type2.phpt | 31 ++ .../DateTime_diff-spring-type2-type3.phpt | 31 ++ .../DateTime_diff-spring-type3-type2.phpt | 31 ++ .../DateTime_diff-spring-type3-type3.phpt | 31 ++ .../tests/DateTime_diff_add_sub-absolute.phpt | 29 -- .../tests/DateTime_diff_add_sub-dates.phpt | 89 ------ .../tests/DateTime_diff_add_sub-february.phpt | 281 ------------------ ext/date/tests/DateTime_sub-dates.phpt | 29 ++ .../tests/DateTime_sub-fall-type2-type2.phpt | 51 ++++ .../tests/DateTime_sub-fall-type2-type3.phpt | 51 ++++ .../tests/DateTime_sub-fall-type3-type2.phpt | 51 ++++ .../tests/DateTime_sub-fall-type3-type3.phpt | 51 ++++ ext/date/tests/DateTime_sub-february.phpt | 77 +++++ ext/date/tests/DateTime_sub-massive.phpt | 15 + .../DateTime_sub-spring-type2-type2.phpt | 31 ++ .../DateTime_sub-spring-type2-type3.phpt | 31 ++ .../DateTime_sub-spring-type3-type2.phpt | 31 ++ .../DateTime_sub-spring-type3-type3.phpt | 31 ++ 61 files changed, 2106 insertions(+), 690 deletions(-) create mode 100644 ext/date/tests/DateTime_add-dates.phpt create mode 100644 ext/date/tests/DateTime_add-fall-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_add-fall-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_add-fall-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_add-fall-type3-type3.phpt create mode 100644 ext/date/tests/DateTime_add-february.phpt create mode 100644 ext/date/tests/DateTime_add-massive.phpt create mode 100644 ext/date/tests/DateTime_add-spring-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_add-spring-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_add-spring-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_add-spring-type3-type3.phpt create mode 100644 ext/date/tests/DateTime_data-absolute.inc create mode 100644 ext/date/tests/DateTime_data-dates.inc rename ext/date/tests/{DateTime_diff_add_sub-fall-type2-type2.phpt => DateTime_data-fall-type2-type2.inc} (53%) rename ext/date/tests/{DateTime_diff_add_sub-fall-type2-type3.phpt => DateTime_data-fall-type2-type3.inc} (55%) rename ext/date/tests/{DateTime_diff_add_sub-fall-type3-type2.phpt => DateTime_data-fall-type3-type2.inc} (55%) rename ext/date/tests/{DateTime_diff_add_sub-fall-type3-type3.phpt => DateTime_data-fall-type3-type3.inc} (57%) create mode 100644 ext/date/tests/DateTime_data-february.inc rename ext/date/tests/{DateTime_diff_add_sub-massive.phpt => DateTime_data-massive.inc} (55%) rename ext/date/tests/{DateTime_diff_add_sub-spring-type2-type2.phpt => DateTime_data-spring-type2-type2.inc} (53%) rename ext/date/tests/{DateTime_diff_add_sub-spring-type2-type3.phpt => DateTime_data-spring-type2-type3.inc} (53%) rename ext/date/tests/{DateTime_diff_add_sub-spring-type3-type2.phpt => DateTime_data-spring-type3-type2.inc} (53%) rename ext/date/tests/{DateTime_diff_add_sub-spring-type3-type3.phpt => DateTime_data-spring-type3-type3.inc} (52%) create mode 100644 ext/date/tests/DateTime_days-absolute.phpt create mode 100644 ext/date/tests/DateTime_days-dates.phpt create mode 100644 ext/date/tests/DateTime_days-fall-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_days-fall-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_days-fall-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_days-fall-type3-type3.phpt create mode 100644 ext/date/tests/DateTime_days-february.phpt create mode 100644 ext/date/tests/DateTime_days-massive.phpt create mode 100644 ext/date/tests/DateTime_days-spring-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_days-spring-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_days-spring-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_days-spring-type3-type3.phpt create mode 100644 ext/date/tests/DateTime_diff-absolute.phpt create mode 100644 ext/date/tests/DateTime_diff-dates.phpt create mode 100644 ext/date/tests/DateTime_diff-fall-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_diff-fall-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_diff-fall-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_diff-fall-type3-type3.phpt create mode 100644 ext/date/tests/DateTime_diff-february.phpt create mode 100644 ext/date/tests/DateTime_diff-massive.phpt create mode 100644 ext/date/tests/DateTime_diff-spring-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_diff-spring-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_diff-spring-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_diff-spring-type3-type3.phpt delete mode 100644 ext/date/tests/DateTime_diff_add_sub-absolute.phpt delete mode 100644 ext/date/tests/DateTime_diff_add_sub-dates.phpt delete mode 100644 ext/date/tests/DateTime_diff_add_sub-february.phpt create mode 100644 ext/date/tests/DateTime_sub-dates.phpt create mode 100644 ext/date/tests/DateTime_sub-fall-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_sub-fall-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_sub-fall-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_sub-fall-type3-type3.phpt create mode 100644 ext/date/tests/DateTime_sub-february.phpt create mode 100644 ext/date/tests/DateTime_sub-massive.phpt create mode 100644 ext/date/tests/DateTime_sub-spring-type2-type2.phpt create mode 100644 ext/date/tests/DateTime_sub-spring-type2-type3.phpt create mode 100644 ext/date/tests/DateTime_sub-spring-type3-type2.phpt create mode 100644 ext/date/tests/DateTime_sub-spring-type3-type3.phpt diff --git a/ext/date/tests/DateTime_add-dates.phpt b/ext/date/tests/DateTime_add-dates.phpt new file mode 100644 index 0000000000000..48c821ff9d9f0 --- /dev/null +++ b/ext/date/tests/DateTime_add-dates.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::add() -- dates +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test__7: ADD: 2009-01-07 00:00:00 EST + P+0Y0M7DT0H0M0S = **2009-01-14 00:00:00 EST** +test_years_positive__7_by_0_day: ADD: 2000-02-07 00:00:00 EST + P+7Y0M0DT0H0M0S = **2007-02-07 00:00:00 EST** +test_years_positive__7_by_1_day: ADD: 2000-02-07 00:00:00 EST + P+7Y0M1DT0H0M0S = **2007-02-08 00:00:00 EST** +test_years_positive__6_shy_1_day: ADD: 2000-02-07 00:00:00 EST + P+6Y11M30DT0H0M0S = **2007-02-06 00:00:00 EST** +test_years_positive__7_by_1_month: ADD: 2000-02-07 00:00:00 EST + P+7Y1M0DT0H0M0S = **2007-03-07 00:00:00 EST** +test_years_positive__6_shy_1_month: ADD: 2000-02-07 00:00:00 EST + P+6Y11M0DT0H0M0S = **2007-01-07 00:00:00 EST** +test_years_positive__7_by_1_month_split_newyear: ADD: 1999-12-07 00:00:00 EST + P+7Y1M0DT0H0M0S = **2007-01-07 00:00:00 EST** +test_years_positive__6_shy_1_month_split_newyear: ADD: 2000-01-07 00:00:00 EST + P+6Y11M0DT0H0M0S = **2006-12-07 00:00:00 EST** +test_negative__7: ADD: 2009-01-14 00:00:00 EST + P-0Y0M7DT0H0M0S = **2009-01-07 00:00:00 EST** +test_years_negative__7_by_0_day: ADD: 2007-02-07 00:00:00 EST + P-7Y0M0DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_negative__7_by_1_day: ADD: 2007-02-08 00:00:00 EST + P-7Y0M1DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_negative__6_shy_1_day: ADD: 2007-02-06 00:00:00 EST + P-6Y11M28DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_negative__7_by_1_month: ADD: 2007-03-07 00:00:00 EST + P-7Y1M0DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_negative__6_shy_1_month: ADD: 2007-01-07 00:00:00 EST + P-6Y11M0DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_negative__7_by_1_month_split_newyear: ADD: 2007-01-07 00:00:00 EST + P-7Y1M0DT0H0M0S = **1999-12-07 00:00:00 EST** +test_years_negative__6_shy_1_month_split_newyear: ADD: 2006-12-07 00:00:00 EST + P-6Y11M0DT0H0M0S = **2000-01-07 00:00:00 EST** diff --git a/ext/date/tests/DateTime_add-fall-type2-type2.phpt b/ext/date/tests/DateTime_add-fall-type2-type2.phpt new file mode 100644 index 0000000000000..0801a042c902f --- /dev/null +++ b/ext/date/tests/DateTime_add-fall-type2-type2.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::add() -- fall type2 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type2_prev: ADD: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type2_dt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_prev_type2_redodt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_prev_type2_redost: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_prev_type2_st: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_prev_type2_post: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_dt_type2_prev: ADD: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_dt_type2_dt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** +test_time_fall_type2_dt_type2_redodt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_dt_type2_redost: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_dt_type2_st: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_dt_type2_post: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_redodt_type2_prev: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_redodt_type2_dt: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_redodt_type2_redodt: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** +test_time_fall_type2_redodt_type2_redost: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redodt_type2_st: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_redodt_type2_post: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_redost_type2_prev: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_redost_type2_dt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_redost_type2_redodt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redost_type2_redost: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** +test_time_fall_type2_redost_type2_st: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_redost_type2_post: ADD: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_st_type2_prev: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_st_type2_dt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_st_type2_redodt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_st_type2_redost: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_st_type2_st: ADD: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** +test_time_fall_type2_st_type2_post: ADD: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type2_prev: ADD: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_post_type2_dt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_post_type2_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_post_type2_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_post_type2_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_post_type2_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** diff --git a/ext/date/tests/DateTime_add-fall-type2-type3.phpt b/ext/date/tests/DateTime_add-fall-type2-type3.phpt new file mode 100644 index 0000000000000..a342e86c4a94e --- /dev/null +++ b/ext/date/tests/DateTime_add-fall-type2-type3.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::add() -- fall type2 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type3_prev: ADD: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type3_dt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_prev_type3_redodt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_prev_type3_redost: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_prev_type3_st: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_prev_type3_post: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_dt_type3_prev: ADD: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_dt_type3_dt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** +test_time_fall_type2_dt_type3_redodt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_dt_type3_redost: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_dt_type3_st: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_dt_type3_post: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_redodt_type3_prev: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_redodt_type3_dt: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_redodt_type3_redodt: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** +test_time_fall_type2_redodt_type3_redost: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redodt_type3_st: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_redodt_type3_post: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_redost_type3_prev: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_redost_type3_dt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_redost_type3_redodt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redost_type3_redost: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** +test_time_fall_type2_redost_type3_st: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_redost_type3_post: ADD: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_st_type3_prev: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_st_type3_dt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_st_type3_redodt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_st_type3_redost: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_st_type3_st: ADD: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** +test_time_fall_type2_st_type3_post: ADD: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type3_prev: ADD: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_post_type3_dt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_post_type3_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_post_type3_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_post_type3_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_post_type3_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** diff --git a/ext/date/tests/DateTime_add-fall-type3-type2.phpt b/ext/date/tests/DateTime_add-fall-type3-type2.phpt new file mode 100644 index 0000000000000..289e303b16d68 --- /dev/null +++ b/ext/date/tests/DateTime_add-fall-type3-type2.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::add() -- fall type3 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type2_prev: ADD: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type2_dt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_prev_type2_redodt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_prev_type2_redost: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_prev_type2_st: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_prev_type2_post: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_dt_type2_prev: ADD: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_dt_type2_dt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** +test_time_fall_type3_dt_type2_redodt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_dt_type2_redost: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_dt_type2_st: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_dt_type2_post: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_redodt_type2_prev: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_redodt_type2_dt: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_redodt_type2_redodt: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** +test_time_fall_type3_redodt_type2_redost: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redodt_type2_st: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_redodt_type2_post: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_redost_type2_prev: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_redost_type2_dt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_redost_type2_redodt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redost_type2_redost: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** +test_time_fall_type3_redost_type2_st: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_redost_type2_post: ADD: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_st_type2_prev: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_st_type2_dt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_st_type2_redodt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_st_type2_redost: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_st_type2_st: ADD: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** +test_time_fall_type3_st_type2_post: ADD: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type2_prev: ADD: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_post_type2_dt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_post_type2_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_post_type2_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_post_type2_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_post_type2_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** diff --git a/ext/date/tests/DateTime_add-fall-type3-type3.phpt b/ext/date/tests/DateTime_add-fall-type3-type3.phpt new file mode 100644 index 0000000000000..517f4abaf81e5 --- /dev/null +++ b/ext/date/tests/DateTime_add-fall-type3-type3.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::add() -- fall type3 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type3_prev: ADD: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type3_dt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_prev_type3_redodt: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_prev_type3_redost: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_prev_type3_st: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_prev_type3_post: ADD: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_dt_type3_prev: ADD: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_dt_type3_dt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** +test_time_fall_type3_dt_type3_redodt: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_dt_type3_redost: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_dt_type3_st: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_dt_type3_post: ADD: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_redodt_type3_prev: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_redodt_type3_dt: ADD: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_redodt_type3_redodt: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** +test_time_fall_type3_redodt_type3_redost: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redodt_type3_st: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_redodt_type3_post: ADD: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_redost_type3_prev: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_redost_type3_dt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_redost_type3_redodt: ADD: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redost_type3_redost: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** +test_time_fall_type3_redost_type3_st: ADD: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_redost_type3_post: ADD: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_st_type3_prev: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_st_type3_dt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_st_type3_redodt: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_st_type3_redost: ADD: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_st_type3_st: ADD: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** +test_time_fall_type3_st_type3_post: ADD: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type3_prev: ADD: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_post_type3_dt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_post_type3_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_post_type3_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_post_type3_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_post_type3_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** diff --git a/ext/date/tests/DateTime_add-february.phpt b/ext/date/tests/DateTime_add-february.phpt new file mode 100644 index 0000000000000..8e47c0eddf04c --- /dev/null +++ b/ext/date/tests/DateTime_add-february.phpt @@ -0,0 +1,77 @@ +--TEST-- +DateTime::add() -- february +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_bug_49081__1: ADD: 2010-03-01 00:00:00 EST + P+0Y0M30DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081__2: ADD: 2010-03-01 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-04-01 00:00:00 EDT** +test_bug_49081__3: ADD: 2010-03-31 00:00:00 EDT + P+0Y0M1DT0H0M0S = **2010-04-01 00:00:00 EDT** +test_bug_49081__4: ADD: 2010-03-31 00:00:00 EDT + P+0Y0M29DT0H0M0S = **2010-04-29 00:00:00 EDT** +test_bug_49081__5: ADD: 2010-03-31 00:00:00 EDT + P+0Y0M30DT0H0M0S = **2010-04-30 00:00:00 EDT** +test_bug_49081__6: ADD: 2010-03-30 00:00:00 EDT + P+0Y1M0DT0H0M0S = **2010-04-30 00:00:00 EDT** +test_bug_49081__7: ADD: 2010-03-29 00:00:00 EDT + P+0Y1M1DT0H0M0S = **2010-04-30 00:00:00 EDT** +test_bug_49081__8: ADD: 2010-01-01 00:00:00 EST + P+0Y0M28DT0H0M0S = **2010-01-29 00:00:00 EST** +test_bug_49081__9: ADD: 2010-01-01 00:00:00 EST + P+0Y0M29DT0H0M0S = **2010-01-30 00:00:00 EST** +test_bug_49081__10: ADD: 2010-01-01 00:00:00 EST + P+0Y0M30DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__11: ADD: 2010-01-01 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-02-01 00:00:00 EST** +test_bug_49081__12: ADD: 2010-01-31 00:00:00 EST + P+0Y0M1DT0H0M0S = **2010-02-01 00:00:00 EST** +test_bug_49081__13: ADD: 2010-01-31 00:00:00 EST + P+0Y0M27DT0H0M0S = **2010-02-27 00:00:00 EST** +test_bug_49081__14: ADD: 2010-01-31 00:00:00 EST + P+0Y0M28DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__15: ADD: 2010-01-30 00:00:00 EST + P+0Y0M29DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__16: ADD: 2010-01-29 00:00:00 EST + P+0Y0M30DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__17: ADD: 2010-01-28 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__18: ADD: 2010-01-27 00:00:00 EST + P+0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__19: ADD: 2010-01-01 00:00:00 EST + P+0Y2M0DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081__20: ADD: 2010-01-31 00:00:00 EST + P+0Y0M29DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081__21: ADD: 2010-01-31 00:00:00 EST + P+0Y1M24DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081__22: ADD: 2010-01-31 00:00:00 EST + P+0Y1M25DT0H0M0S = **2010-03-28 00:00:00 EDT** +test_bug_49081__23: ADD: 2010-01-31 00:00:00 EST + P+0Y1M26DT0H0M0S = **2010-03-29 00:00:00 EDT** +test_bug_49081__24: ADD: 2010-01-31 00:00:00 EST + P+0Y1M27DT0H0M0S = **2010-03-30 00:00:00 EDT** +test_bug_49081__25: ADD: 2010-01-31 00:00:00 EST + P+0Y2M0DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081__26: ADD: 2010-01-30 00:00:00 EST + P+0Y2M1DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081__27: ADD: 2009-01-01 00:00:00 EST + P+0Y0M30DT0H0M0S = **2009-01-31 00:00:00 EST** +test_bug_49081__28: ADD: 2010-02-28 00:00:00 EST + P+0Y0M27DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081__29: ADD: 2010-02-28 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-03-28 00:00:00 EDT** +test_bug_49081__30: ADD: 2010-02-28 00:00:00 EST + P+0Y1M1DT0H0M0S = **2010-03-29 00:00:00 EDT** +test_bug_49081__31: ADD: 2010-02-27 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081__32: ADD: 2010-02-26 00:00:00 EST + P+0Y1M1DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081_negative__1: ADD: 2010-03-31 00:00:00 EDT + P-0Y0M30DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081_negative__2: ADD: 2010-04-01 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081_negative__3: ADD: 2010-04-01 00:00:00 EDT + P-0Y0M1DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__4: ADD: 2010-04-29 00:00:00 EDT + P-0Y0M29DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__5: ADD: 2010-04-30 00:00:00 EDT + P-0Y0M30DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__6: ADD: 2010-04-30 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-03-30 00:00:00 EDT** +test_bug_49081_negative__7: ADD: 2010-04-30 00:00:00 EDT + P-0Y1M1DT0H0M0S = **2010-03-29 00:00:00 EDT** +test_bug_49081_negative__8: ADD: 2010-01-29 00:00:00 EST + P-0Y0M28DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081_negative__9: ADD: 2010-01-30 00:00:00 EST + P-0Y0M29DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081_negative__10: ADD: 2010-01-31 00:00:00 EST + P-0Y0M30DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081_negative__11: ADD: 2010-02-01 00:00:00 EST + P-0Y1M0DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081_negative__12: ADD: 2010-02-01 00:00:00 EST + P-0Y0M1DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__13: ADD: 2010-02-27 00:00:00 EST + P-0Y0M27DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__14: ADD: 2010-02-28 00:00:00 EST + P-0Y0M28DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__15: ADD: 2010-02-28 00:00:00 EST + P-0Y0M29DT0H0M0S = **2010-01-30 00:00:00 EST** +test_bug_49081_negative__16: ADD: 2010-02-28 00:00:00 EST + P-0Y0M30DT0H0M0S = **2010-01-29 00:00:00 EST** +test_bug_49081_negative__17: ADD: 2010-02-28 00:00:00 EST + P-0Y1M0DT0H0M0S = **2010-01-28 00:00:00 EST** +test_bug_49081_negative__18: ADD: 2010-02-28 00:00:00 EST + P-0Y1M1DT0H0M0S = **2010-01-27 00:00:00 EST** +test_bug_49081_negative__19: ADD: 2010-03-01 00:00:00 EST + P-0Y2M0DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081_negative__20: ADD: 2010-03-01 00:00:00 EST + P-0Y1M1DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__21: ADD: 2010-03-27 00:00:00 EDT + P-0Y1M27DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__22: ADD: 2010-03-28 00:00:00 EDT + P-0Y1M28DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__23: ADD: 2010-03-29 00:00:00 EDT + P-0Y1M29DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__24: ADD: 2010-03-30 00:00:00 EDT + P-0Y1M30DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__25: ADD: 2010-03-31 00:00:00 EDT + P-0Y2M0DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__26: ADD: 2010-03-31 00:00:00 EDT + P-0Y2M1DT0H0M0S = **2010-01-30 00:00:00 EST** +test_bug_49081_negative__27: ADD: 2009-01-31 00:00:00 EST + P-0Y0M30DT0H0M0S = **2009-01-01 00:00:00 EST** +test_bug_49081_negative__28: ADD: 2010-03-27 00:00:00 EDT + P-0Y0M27DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__29: ADD: 2010-03-28 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__30: ADD: 2010-03-29 00:00:00 EDT + P-0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__31: ADD: 2010-03-27 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-02-27 00:00:00 EST** +test_bug_49081_negative__32: ADD: 2010-03-27 00:00:00 EDT + P-0Y1M1DT0H0M0S = **2010-02-26 00:00:00 EST** diff --git a/ext/date/tests/DateTime_add-massive.phpt b/ext/date/tests/DateTime_add-massive.phpt new file mode 100644 index 0000000000000..ca5bef985e7a2 --- /dev/null +++ b/ext/date/tests/DateTime_add-massive.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::add() -- massive +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_massive_positive: ADD: -333333-01-01 16:18:02 EST + P+666666Y0M0DT0H0M0S = **333333-01-01 16:18:02 EST** +test_massive_negative: ADD: 333333-01-01 16:18:02 EST + P-666666Y0M0DT0H0M0S = **-333333-01-01 16:18:02 EST** diff --git a/ext/date/tests/DateTime_add-spring-type2-type2.phpt b/ext/date/tests/DateTime_add-spring-type2-type2.phpt new file mode 100644 index 0000000000000..8cf898138d390 --- /dev/null +++ b/ext/date/tests/DateTime_add-spring-type2-type2.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::add() -- spring type2 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type2_prev: ADD: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_prev_type2_st: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_prev_type2_dt: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_prev_type2_post: ADD: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_st_type2_prev: ADD: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_st_type2_st: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** +test_time_spring_type2_st_type2_dt: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_st_type2_post: ADD: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_dt_type2_prev: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_dt_type2_st: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_dt_type2_dt: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** +test_time_spring_type2_dt_type2_post: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type2_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_post_type2_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_post_type2_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_post_type2_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** diff --git a/ext/date/tests/DateTime_add-spring-type2-type3.phpt b/ext/date/tests/DateTime_add-spring-type2-type3.phpt new file mode 100644 index 0000000000000..45c43597c0047 --- /dev/null +++ b/ext/date/tests/DateTime_add-spring-type2-type3.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::add() -- spring type2 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type3_prev: ADD: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_prev_type3_st: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_prev_type3_dt: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_prev_type3_post: ADD: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_st_type3_prev: ADD: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_st_type3_st: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** +test_time_spring_type2_st_type3_dt: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_st_type3_post: ADD: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_dt_type3_prev: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_dt_type3_st: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_dt_type3_dt: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** +test_time_spring_type2_dt_type3_post: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type3_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_post_type3_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_post_type3_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_post_type3_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** diff --git a/ext/date/tests/DateTime_add-spring-type3-type2.phpt b/ext/date/tests/DateTime_add-spring-type3-type2.phpt new file mode 100644 index 0000000000000..261bf4e0ab11f --- /dev/null +++ b/ext/date/tests/DateTime_add-spring-type3-type2.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::add() -- spring type3 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type2_prev: ADD: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_prev_type2_st: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_prev_type2_dt: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_prev_type2_post: ADD: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_st_type2_prev: ADD: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_st_type2_st: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** +test_time_spring_type3_st_type2_dt: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_st_type2_post: ADD: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_dt_type2_prev: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_dt_type2_st: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_dt_type2_dt: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** +test_time_spring_type3_dt_type2_post: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type2_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_post_type2_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_post_type2_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_post_type2_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** diff --git a/ext/date/tests/DateTime_add-spring-type3-type3.phpt b/ext/date/tests/DateTime_add-spring-type3-type3.phpt new file mode 100644 index 0000000000000..17c371078d04a --- /dev/null +++ b/ext/date/tests/DateTime_add-spring-type3-type3.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::add() -- spring type3 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type3_prev: ADD: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_prev_type3_st: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_prev_type3_dt: ADD: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_prev_type3_post: ADD: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_st_type3_prev: ADD: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_st_type3_st: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** +test_time_spring_type3_st_type3_dt: ADD: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_st_type3_post: ADD: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_dt_type3_prev: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_dt_type3_st: ADD: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_dt_type3_dt: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** +test_time_spring_type3_dt_type3_post: ADD: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type3_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_post_type3_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_post_type3_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_post_type3_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** diff --git a/ext/date/tests/DateTime_data-absolute.inc b/ext/date/tests/DateTime_data-absolute.inc new file mode 100644 index 0000000000000..fa3acb88c0d78 --- /dev/null +++ b/ext/date/tests/DateTime_data-absolute.inc @@ -0,0 +1,24 @@ + ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -203,42 +197,3 @@ echo "test_time_fall_type2_post_type2_post: "; $end = new DateTime('2010-11-08 19:59:59 EST'); // post, zt2 $start = new DateTime('2010-11-08 18:57:55 EST'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_fall_type2_prev_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** | BACK: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** | DAYS: **33** -test_time_fall_type2_prev_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_prev_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_prev_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_prev_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_prev_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** | DAYS: **2** -test_time_fall_type2_dt_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** | BACK: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_dt_type2_dt: FWD: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** | DAYS: **0** -test_time_fall_type2_dt_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_dt_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_dt_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_dt_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_redodt_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_redodt_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_redodt_type2_redodt: FWD: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** | DAYS: **0** -test_time_fall_type2_redodt_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_redodt_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_redodt_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_redost_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_redost_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_redost_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_redost_type2_redost: FWD: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** | DAYS: **0** -test_time_fall_type2_redost_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_redost_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_st_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_st_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_st_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_st_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_st_type2_st: FWD: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** | DAYS: **0** -test_time_fall_type2_st_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_post_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** | DAYS: **2** -test_time_fall_type2_post_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** | DAYS: **1** -test_time_fall_type2_post_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** | DAYS: **1** -test_time_fall_type2_post_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** | DAYS: **1** -test_time_fall_type2_post_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** | DAYS: **1** -test_time_fall_type2_post_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** | BACK: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** | DAYS: **0** diff --git a/ext/date/tests/DateTime_diff_add_sub-fall-type2-type3.phpt b/ext/date/tests/DateTime_data-fall-type2-type3.inc similarity index 55% rename from ext/date/tests/DateTime_diff_add_sub-fall-type2-type3.phpt rename to ext/date/tests/DateTime_data-fall-type2-type3.inc index eec0eec7fadb0..368934c98fc1d 100644 --- a/ext/date/tests/DateTime_diff_add_sub-fall-type2-type3.phpt +++ b/ext/date/tests/DateTime_data-fall-type2-type3.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- fall type2 type3 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -215,42 +209,3 @@ echo "test_time_fall_type2_post_type3_post: "; $end = new DateTime('2010-11-08 19:59:59'); // post, zt3 $start = new DateTime('2010-11-08 18:57:55 EST'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_fall_type2_prev_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** | BACK: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** | DAYS: **33** -test_time_fall_type2_prev_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_prev_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_prev_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_prev_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_prev_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** | DAYS: **2** -test_time_fall_type2_dt_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** | BACK: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_dt_type3_dt: FWD: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** | DAYS: **0** -test_time_fall_type2_dt_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_dt_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_dt_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_dt_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_redodt_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_redodt_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_redodt_type3_redodt: FWD: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** | DAYS: **0** -test_time_fall_type2_redodt_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_redodt_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_redodt_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_redost_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_redost_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_redost_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_redost_type3_redost: FWD: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** | DAYS: **0** -test_time_fall_type2_redost_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type2_redost_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_st_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type2_st_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type2_st_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type2_st_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type2_st_type3_st: FWD: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** | DAYS: **0** -test_time_fall_type2_st_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type2_post_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** | DAYS: **2** -test_time_fall_type2_post_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** | DAYS: **1** -test_time_fall_type2_post_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** | DAYS: **1** -test_time_fall_type2_post_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** | DAYS: **1** -test_time_fall_type2_post_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** | DAYS: **1** -test_time_fall_type2_post_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** | BACK: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** | DAYS: **0** diff --git a/ext/date/tests/DateTime_diff_add_sub-fall-type3-type2.phpt b/ext/date/tests/DateTime_data-fall-type3-type2.inc similarity index 55% rename from ext/date/tests/DateTime_diff_add_sub-fall-type3-type2.phpt rename to ext/date/tests/DateTime_data-fall-type3-type2.inc index 33c1dc179abea..467139bcc469d 100644 --- a/ext/date/tests/DateTime_diff_add_sub-fall-type3-type2.phpt +++ b/ext/date/tests/DateTime_data-fall-type3-type2.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- fall type3 type2 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -217,42 +211,3 @@ echo "test_time_fall_type3_post_type2_post: "; $end = new DateTime('2010-11-08 19:59:59 EST'); // post, zt2 $start = new DateTime('2010-11-08 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_fall_type3_prev_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** | BACK: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** | DAYS: **33** -test_time_fall_type3_prev_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_prev_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_prev_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_prev_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_prev_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** | DAYS: **2** -test_time_fall_type3_dt_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** | BACK: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_dt_type2_dt: FWD: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** | DAYS: **0** -test_time_fall_type3_dt_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_dt_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_dt_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_dt_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_redodt_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_redodt_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_redodt_type2_redodt: FWD: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** | DAYS: **0** -test_time_fall_type3_redodt_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_redodt_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_redodt_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_redost_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_redost_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_redost_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_redost_type2_redost: FWD: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** | DAYS: **0** -test_time_fall_type3_redost_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_redost_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_st_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_st_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_st_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_st_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_st_type2_st: FWD: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** | DAYS: **0** -test_time_fall_type3_st_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_post_type2_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** | DAYS: **2** -test_time_fall_type3_post_type2_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** | DAYS: **1** -test_time_fall_type3_post_type2_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** | DAYS: **1** -test_time_fall_type3_post_type2_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** | DAYS: **1** -test_time_fall_type3_post_type2_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** | DAYS: **1** -test_time_fall_type3_post_type2_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** | BACK: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** | DAYS: **0** diff --git a/ext/date/tests/DateTime_diff_add_sub-fall-type3-type3.phpt b/ext/date/tests/DateTime_data-fall-type3-type3.inc similarity index 57% rename from ext/date/tests/DateTime_diff_add_sub-fall-type3-type3.phpt rename to ext/date/tests/DateTime_data-fall-type3-type3.inc index 06f2a2a9474a2..c8ebd59d60963 100644 --- a/ext/date/tests/DateTime_diff_add_sub-fall-type3-type3.phpt +++ b/ext/date/tests/DateTime_data-fall-type3-type3.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- fall type3 type3 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -227,42 +221,3 @@ echo "test_time_fall_type3_post_type3_post: "; $end = new DateTime('2010-11-08 19:59:59'); // post, zt3 $start = new DateTime('2010-11-08 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_fall_type3_prev_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** | BACK: 2010-10-04 02:18:48 EDT + P+0Y1M2DT16H19M40S = **2010-11-06 18:38:28 EDT** | DAYS: **33** -test_time_fall_type3_prev_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_prev_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_prev_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_prev_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_prev_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** | BACK: 2010-11-06 18:38:28 EDT + P+0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** | DAYS: **2** -test_time_fall_type3_dt_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** | BACK: 2010-11-07 00:10:20 EDT + P-0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_dt_type3_dt: FWD: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT0H5M15S = **2010-11-07 00:15:35 EDT** | DAYS: **0** -test_time_fall_type3_dt_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_dt_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_dt_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_dt_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** | BACK: 2010-11-07 00:10:20 EDT + P+0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_redodt_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_redodt_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** | BACK: 2010-11-07 01:12:33 EDT + P-0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_redodt_type3_redodt: FWD: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT0H3M2S = **2010-11-07 01:15:35 EDT** | DAYS: **0** -test_time_fall_type3_redodt_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_redodt_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_redodt_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** | BACK: 2010-11-07 01:12:33 EDT + P+0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_redost_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_redost_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_redost_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** | BACK: 2010-11-07 01:14:44 EST + P-0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_redost_type3_redost: FWD: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT0H2M10S = **2010-11-07 01:16:54 EST** | DAYS: **0** -test_time_fall_type3_redost_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** | DAYS: **0** -test_time_fall_type3_redost_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** | BACK: 2010-11-07 01:14:44 EST + P+0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_st_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** | DAYS: **0** -test_time_fall_type3_st_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** | DAYS: **0** -test_time_fall_type3_st_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** | DAYS: **0** -test_time_fall_type3_st_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** | BACK: 2010-11-07 03:16:55 EST + P-0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** | DAYS: **0** -test_time_fall_type3_st_type3_st: FWD: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M0DT2H3M1S = **2010-11-07 05:19:56 EST** | DAYS: **0** -test_time_fall_type3_st_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** | BACK: 2010-11-07 03:16:55 EST + P+0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** | DAYS: **1** -test_time_fall_type3_post_type3_prev: FWD: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** | DAYS: **2** -test_time_fall_type3_post_type3_dt: FWD: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** | DAYS: **1** -test_time_fall_type3_post_type3_redodt: FWD: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** | DAYS: **1** -test_time_fall_type3_post_type3_redost: FWD: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** | DAYS: **1** -test_time_fall_type3_post_type3_st: FWD: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** | BACK: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** | DAYS: **1** -test_time_fall_type3_post_type3_post: FWD: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** | BACK: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** | DAYS: **0** diff --git a/ext/date/tests/DateTime_data-february.inc b/ext/date/tests/DateTime_data-february.inc new file mode 100644 index 0000000000000..8c31ef69ac74b --- /dev/null +++ b/ext/date/tests/DateTime_data-february.inc @@ -0,0 +1,208 @@ + ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -38,8 +32,3 @@ $start->setDate(333333, 1, 1); $start->setTime(16, 18, 02); examine_diff($end, $start, 'P-666666Y0M0DT0H0M0S', 243494757); - -?> ---EXPECT-- -test_massive_positive: FWD: 333333-01-01 16:18:02 EST - -333333-01-01 16:18:02 EST = **P+666666Y0M0DT0H0M0S** | BACK: -333333-01-01 16:18:02 EST + P+666666Y0M0DT0H0M0S = **333333-01-01 16:18:02 EST** | DAYS: **243494757** -test_massive_negative: FWD: -333333-01-01 16:18:02 EST - 333333-01-01 16:18:02 EST = **P-666666Y0M0DT0H0M0S** | BACK: 333333-01-01 16:18:02 EST + P-666666Y0M0DT0H0M0S = **-333333-01-01 16:18:02 EST** | DAYS: **243494757** diff --git a/ext/date/tests/DateTime_diff_add_sub-spring-type2-type2.phpt b/ext/date/tests/DateTime_data-spring-type2-type2.inc similarity index 53% rename from ext/date/tests/DateTime_diff_add_sub-spring-type2-type2.phpt rename to ext/date/tests/DateTime_data-spring-type2-type2.inc index 9f9f764031a07..353d701f3eebb 100644 --- a/ext/date/tests/DateTime_diff_add_sub-spring-type2-type2.phpt +++ b/ext/date/tests/DateTime_data-spring-type2-type2.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- spring type2 type2 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -101,22 +95,3 @@ echo "test_time_spring_type2_post_type2_post: "; $end = new DateTime('2010-03-15 19:59:59 EDT'); // post, zt2 $start = new DateTime('2010-03-15 18:57:55 EDT'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_spring_type2_prev_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** | BACK: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** | DAYS: **30** -test_time_spring_type2_prev_type2_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type2_prev_type2_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type2_prev_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** | DAYS: **2** -test_time_spring_type2_st_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** | BACK: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type2_st_type2_st: FWD: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** | DAYS: **0** -test_time_spring_type2_st_type2_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type2_st_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type2_dt_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type2_dt_type2_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type2_dt_type2_dt: FWD: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** | DAYS: **0** -test_time_spring_type2_dt_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type2_post_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** | DAYS: **2** -test_time_spring_type2_post_type2_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** | DAYS: **1** -test_time_spring_type2_post_type2_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** | DAYS: **1** -test_time_spring_type2_post_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** | BACK: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** | DAYS: **0** diff --git a/ext/date/tests/DateTime_diff_add_sub-spring-type2-type3.phpt b/ext/date/tests/DateTime_data-spring-type2-type3.inc similarity index 53% rename from ext/date/tests/DateTime_diff_add_sub-spring-type2-type3.phpt rename to ext/date/tests/DateTime_data-spring-type2-type3.inc index 1a56c112ebafc..11e960620de16 100644 --- a/ext/date/tests/DateTime_diff_add_sub-spring-type2-type3.phpt +++ b/ext/date/tests/DateTime_data-spring-type2-type3.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- spring type2 type3 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -101,22 +95,3 @@ echo "test_time_spring_type2_post_type3_post: "; $end = new DateTime('2010-03-15 19:59:59'); // post, zt3 $start = new DateTime('2010-03-15 18:57:55 EDT'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_spring_type2_prev_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** | BACK: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** | DAYS: **30** -test_time_spring_type2_prev_type3_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type2_prev_type3_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type2_prev_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** | DAYS: **2** -test_time_spring_type2_st_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** | BACK: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type2_st_type3_st: FWD: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** | DAYS: **0** -test_time_spring_type2_st_type3_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type2_st_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type2_dt_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type2_dt_type3_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type2_dt_type3_dt: FWD: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** | DAYS: **0** -test_time_spring_type2_dt_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type2_post_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** | DAYS: **2** -test_time_spring_type2_post_type3_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** | DAYS: **1** -test_time_spring_type2_post_type3_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** | DAYS: **1** -test_time_spring_type2_post_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** | BACK: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** | DAYS: **0** diff --git a/ext/date/tests/DateTime_diff_add_sub-spring-type3-type2.phpt b/ext/date/tests/DateTime_data-spring-type3-type2.inc similarity index 53% rename from ext/date/tests/DateTime_diff_add_sub-spring-type3-type2.phpt rename to ext/date/tests/DateTime_data-spring-type3-type2.inc index 1c4ba592f30cb..7cd2b703688d1 100644 --- a/ext/date/tests/DateTime_diff_add_sub-spring-type3-type2.phpt +++ b/ext/date/tests/DateTime_data-spring-type3-type2.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- spring type3 type2 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -101,22 +95,3 @@ echo "test_time_spring_type3_post_type2_post: "; $end = new DateTime('2010-03-15 19:59:59 EDT'); // post, zt2 $start = new DateTime('2010-03-15 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_spring_type3_prev_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** | BACK: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** | DAYS: **30** -test_time_spring_type3_prev_type2_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type3_prev_type2_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type3_prev_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** | DAYS: **2** -test_time_spring_type3_st_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** | BACK: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type3_st_type2_st: FWD: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** | DAYS: **0** -test_time_spring_type3_st_type2_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type3_st_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type3_dt_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type3_dt_type2_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type3_dt_type2_dt: FWD: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** | DAYS: **0** -test_time_spring_type3_dt_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type3_post_type2_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** | DAYS: **2** -test_time_spring_type3_post_type2_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** | DAYS: **1** -test_time_spring_type3_post_type2_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** | DAYS: **1** -test_time_spring_type3_post_type2_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** | BACK: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** | DAYS: **0** diff --git a/ext/date/tests/DateTime_diff_add_sub-spring-type3-type3.phpt b/ext/date/tests/DateTime_data-spring-type3-type3.inc similarity index 52% rename from ext/date/tests/DateTime_diff_add_sub-spring-type3-type3.phpt rename to ext/date/tests/DateTime_data-spring-type3-type3.inc index 3385efec9c203..5c5d5ffba4479 100644 --- a/ext/date/tests/DateTime_diff_add_sub-spring-type3-type3.phpt +++ b/ext/date/tests/DateTime_data-spring-type3-type3.inc @@ -1,8 +1,3 @@ ---TEST-- -DateTime::diff() add() sub() -- spring type3 type3 ---CREDITS-- -Daniel Convissor ---FILE-- * in a userland package. Please be so kind as to leave them. */ -require 'examine_diff.inc'; date_default_timezone_set('America/New_York'); @@ -101,22 +95,3 @@ echo "test_time_spring_type3_post_type3_post: "; $end = new DateTime('2010-03-15 19:59:59'); // post, zt3 $start = new DateTime('2010-03-15 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); - -?> ---EXPECT-- -test_time_spring_type3_prev_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** | BACK: 2010-02-11 02:18:48 EST + P+0Y1M2DT16H19M40S = **2010-03-13 18:38:28 EST** | DAYS: **30** -test_time_spring_type3_prev_type3_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type3_prev_type3_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type3_prev_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** | BACK: 2010-03-13 18:38:28 EST + P+0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** | DAYS: **2** -test_time_spring_type3_st_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** | BACK: 2010-03-14 00:10:20 EST + P-0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type3_st_type3_st: FWD: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT0H5M15S = **2010-03-14 00:15:35 EST** | DAYS: **0** -test_time_spring_type3_st_type3_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** | DAYS: **0** -test_time_spring_type3_st_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** | BACK: 2010-03-14 00:10:20 EST + P+0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type3_dt_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** | DAYS: **0** -test_time_spring_type3_dt_type3_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** | BACK: 2010-03-14 03:16:55 EDT + P-0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** | DAYS: **0** -test_time_spring_type3_dt_type3_dt: FWD: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M0DT2H3M1S = **2010-03-14 05:19:56 EDT** | DAYS: **0** -test_time_spring_type3_dt_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** | BACK: 2010-03-14 03:16:55 EDT + P+0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** | DAYS: **1** -test_time_spring_type3_post_type3_prev: FWD: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** | DAYS: **2** -test_time_spring_type3_post_type3_st: FWD: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** | DAYS: **1** -test_time_spring_type3_post_type3_dt: FWD: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** | BACK: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** | DAYS: **1** -test_time_spring_type3_post_type3_post: FWD: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** | BACK: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** | DAYS: **0** diff --git a/ext/date/tests/DateTime_days-absolute.phpt b/ext/date/tests/DateTime_days-absolute.phpt new file mode 100644 index 0000000000000..7a150e39a7196 --- /dev/null +++ b/ext/date/tests/DateTime_days-absolute.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::diff() days -- absolute +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_absolute_7: DAYS: **7** +test_absolute_negative_7: DAYS: **7** diff --git a/ext/date/tests/DateTime_days-dates.phpt b/ext/date/tests/DateTime_days-dates.phpt new file mode 100644 index 0000000000000..446d56d78d583 --- /dev/null +++ b/ext/date/tests/DateTime_days-dates.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::diff() days -- dates +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test__7: DAYS: **7** +test_years_positive__7_by_0_day: DAYS: **2557** +test_years_positive__7_by_1_day: DAYS: **2558** +test_years_positive__6_shy_1_day: DAYS: **2556** +test_years_positive__7_by_1_month: DAYS: **2585** +test_years_positive__6_shy_1_month: DAYS: **2526** +test_years_positive__7_by_1_month_split_newyear: DAYS: **2588** +test_years_positive__6_shy_1_month_split_newyear: DAYS: **2526** +test_negative__7: DAYS: **7** +test_years_negative__7_by_0_day: DAYS: **2557** +test_years_negative__7_by_1_day: DAYS: **2558** +test_years_negative__6_shy_1_day: DAYS: **2556** +test_years_negative__7_by_1_month: DAYS: **2585** +test_years_negative__6_shy_1_month: DAYS: **2526** +test_years_negative__7_by_1_month_split_newyear: DAYS: **2588** +test_years_negative__6_shy_1_month_split_newyear: DAYS: **2526** diff --git a/ext/date/tests/DateTime_days-fall-type2-type2.phpt b/ext/date/tests/DateTime_days-fall-type2-type2.phpt new file mode 100644 index 0000000000000..c71d8c2bc4d52 --- /dev/null +++ b/ext/date/tests/DateTime_days-fall-type2-type2.phpt @@ -0,0 +1,49 @@ +--TEST-- +DateTime::diff() days -- fall type2 type2 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type2_prev: DAYS: **33** +test_time_fall_type2_prev_type2_dt: DAYS: **0** +test_time_fall_type2_prev_type2_redodt: DAYS: **0** +test_time_fall_type2_prev_type2_redost: DAYS: **0** +test_time_fall_type2_prev_type2_st: DAYS: **0** +test_time_fall_type2_prev_type2_post: DAYS: **2** +test_time_fall_type2_dt_type2_prev: DAYS: **0** +test_time_fall_type2_dt_type2_dt: DAYS: **0** +test_time_fall_type2_dt_type2_redodt: DAYS: **0** +test_time_fall_type2_dt_type2_redost: DAYS: **0** +test_time_fall_type2_dt_type2_st: DAYS: **0** +test_time_fall_type2_dt_type2_post: DAYS: **1** +test_time_fall_type2_redodt_type2_prev: DAYS: **0** +test_time_fall_type2_redodt_type2_dt: DAYS: **0** +test_time_fall_type2_redodt_type2_redodt: DAYS: **0** +test_time_fall_type2_redodt_type2_redost: DAYS: **0** +test_time_fall_type2_redodt_type2_st: DAYS: **0** +test_time_fall_type2_redodt_type2_post: DAYS: **1** +test_time_fall_type2_redost_type2_prev: DAYS: **0** +test_time_fall_type2_redost_type2_dt: DAYS: **0** +test_time_fall_type2_redost_type2_redodt: DAYS: **0** +test_time_fall_type2_redost_type2_redost: DAYS: **0** +test_time_fall_type2_redost_type2_st: DAYS: **0** +test_time_fall_type2_redost_type2_post: DAYS: **1** +test_time_fall_type2_st_type2_prev: DAYS: **0** +test_time_fall_type2_st_type2_dt: DAYS: **0** +test_time_fall_type2_st_type2_redodt: DAYS: **0** +test_time_fall_type2_st_type2_redost: DAYS: **0** +test_time_fall_type2_st_type2_st: DAYS: **0** +test_time_fall_type2_st_type2_post: DAYS: **1** +test_time_fall_type2_post_type2_prev: DAYS: **2** +test_time_fall_type2_post_type2_dt: DAYS: **1** +test_time_fall_type2_post_type2_redodt: DAYS: **1** +test_time_fall_type2_post_type2_redost: DAYS: **1** +test_time_fall_type2_post_type2_st: DAYS: **1** +test_time_fall_type2_post_type2_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-fall-type2-type3.phpt b/ext/date/tests/DateTime_days-fall-type2-type3.phpt new file mode 100644 index 0000000000000..548c1bfbcafb3 --- /dev/null +++ b/ext/date/tests/DateTime_days-fall-type2-type3.phpt @@ -0,0 +1,49 @@ +--TEST-- +DateTime::diff() days -- fall type2 type3 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type3_prev: DAYS: **33** +test_time_fall_type2_prev_type3_dt: DAYS: **0** +test_time_fall_type2_prev_type3_redodt: DAYS: **0** +test_time_fall_type2_prev_type3_redost: DAYS: **0** +test_time_fall_type2_prev_type3_st: DAYS: **0** +test_time_fall_type2_prev_type3_post: DAYS: **2** +test_time_fall_type2_dt_type3_prev: DAYS: **0** +test_time_fall_type2_dt_type3_dt: DAYS: **0** +test_time_fall_type2_dt_type3_redodt: DAYS: **0** +test_time_fall_type2_dt_type3_redost: DAYS: **0** +test_time_fall_type2_dt_type3_st: DAYS: **0** +test_time_fall_type2_dt_type3_post: DAYS: **1** +test_time_fall_type2_redodt_type3_prev: DAYS: **0** +test_time_fall_type2_redodt_type3_dt: DAYS: **0** +test_time_fall_type2_redodt_type3_redodt: DAYS: **0** +test_time_fall_type2_redodt_type3_redost: DAYS: **0** +test_time_fall_type2_redodt_type3_st: DAYS: **0** +test_time_fall_type2_redodt_type3_post: DAYS: **1** +test_time_fall_type2_redost_type3_prev: DAYS: **0** +test_time_fall_type2_redost_type3_dt: DAYS: **0** +test_time_fall_type2_redost_type3_redodt: DAYS: **0** +test_time_fall_type2_redost_type3_redost: DAYS: **0** +test_time_fall_type2_redost_type3_st: DAYS: **0** +test_time_fall_type2_redost_type3_post: DAYS: **1** +test_time_fall_type2_st_type3_prev: DAYS: **0** +test_time_fall_type2_st_type3_dt: DAYS: **0** +test_time_fall_type2_st_type3_redodt: DAYS: **0** +test_time_fall_type2_st_type3_redost: DAYS: **0** +test_time_fall_type2_st_type3_st: DAYS: **0** +test_time_fall_type2_st_type3_post: DAYS: **1** +test_time_fall_type2_post_type3_prev: DAYS: **2** +test_time_fall_type2_post_type3_dt: DAYS: **1** +test_time_fall_type2_post_type3_redodt: DAYS: **1** +test_time_fall_type2_post_type3_redost: DAYS: **1** +test_time_fall_type2_post_type3_st: DAYS: **1** +test_time_fall_type2_post_type3_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-fall-type3-type2.phpt b/ext/date/tests/DateTime_days-fall-type3-type2.phpt new file mode 100644 index 0000000000000..053a3541e9ab0 --- /dev/null +++ b/ext/date/tests/DateTime_days-fall-type3-type2.phpt @@ -0,0 +1,49 @@ +--TEST-- +DateTime::diff() days -- fall type3 type2 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type2_prev: DAYS: **33** +test_time_fall_type3_prev_type2_dt: DAYS: **0** +test_time_fall_type3_prev_type2_redodt: DAYS: **0** +test_time_fall_type3_prev_type2_redost: DAYS: **0** +test_time_fall_type3_prev_type2_st: DAYS: **0** +test_time_fall_type3_prev_type2_post: DAYS: **2** +test_time_fall_type3_dt_type2_prev: DAYS: **0** +test_time_fall_type3_dt_type2_dt: DAYS: **0** +test_time_fall_type3_dt_type2_redodt: DAYS: **0** +test_time_fall_type3_dt_type2_redost: DAYS: **0** +test_time_fall_type3_dt_type2_st: DAYS: **0** +test_time_fall_type3_dt_type2_post: DAYS: **1** +test_time_fall_type3_redodt_type2_prev: DAYS: **0** +test_time_fall_type3_redodt_type2_dt: DAYS: **0** +test_time_fall_type3_redodt_type2_redodt: DAYS: **0** +test_time_fall_type3_redodt_type2_redost: DAYS: **0** +test_time_fall_type3_redodt_type2_st: DAYS: **0** +test_time_fall_type3_redodt_type2_post: DAYS: **1** +test_time_fall_type3_redost_type2_prev: DAYS: **0** +test_time_fall_type3_redost_type2_dt: DAYS: **0** +test_time_fall_type3_redost_type2_redodt: DAYS: **0** +test_time_fall_type3_redost_type2_redost: DAYS: **0** +test_time_fall_type3_redost_type2_st: DAYS: **0** +test_time_fall_type3_redost_type2_post: DAYS: **1** +test_time_fall_type3_st_type2_prev: DAYS: **0** +test_time_fall_type3_st_type2_dt: DAYS: **0** +test_time_fall_type3_st_type2_redodt: DAYS: **0** +test_time_fall_type3_st_type2_redost: DAYS: **0** +test_time_fall_type3_st_type2_st: DAYS: **0** +test_time_fall_type3_st_type2_post: DAYS: **1** +test_time_fall_type3_post_type2_prev: DAYS: **2** +test_time_fall_type3_post_type2_dt: DAYS: **1** +test_time_fall_type3_post_type2_redodt: DAYS: **1** +test_time_fall_type3_post_type2_redost: DAYS: **1** +test_time_fall_type3_post_type2_st: DAYS: **1** +test_time_fall_type3_post_type2_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-fall-type3-type3.phpt b/ext/date/tests/DateTime_days-fall-type3-type3.phpt new file mode 100644 index 0000000000000..9f80bd68786b1 --- /dev/null +++ b/ext/date/tests/DateTime_days-fall-type3-type3.phpt @@ -0,0 +1,49 @@ +--TEST-- +DateTime::diff() days -- fall type3 type3 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type3_prev: DAYS: **33** +test_time_fall_type3_prev_type3_dt: DAYS: **0** +test_time_fall_type3_prev_type3_redodt: DAYS: **0** +test_time_fall_type3_prev_type3_redost: DAYS: **0** +test_time_fall_type3_prev_type3_st: DAYS: **0** +test_time_fall_type3_prev_type3_post: DAYS: **2** +test_time_fall_type3_dt_type3_prev: DAYS: **0** +test_time_fall_type3_dt_type3_dt: DAYS: **0** +test_time_fall_type3_dt_type3_redodt: DAYS: **0** +test_time_fall_type3_dt_type3_redost: DAYS: **0** +test_time_fall_type3_dt_type3_st: DAYS: **0** +test_time_fall_type3_dt_type3_post: DAYS: **1** +test_time_fall_type3_redodt_type3_prev: DAYS: **0** +test_time_fall_type3_redodt_type3_dt: DAYS: **0** +test_time_fall_type3_redodt_type3_redodt: DAYS: **0** +test_time_fall_type3_redodt_type3_redost: DAYS: **0** +test_time_fall_type3_redodt_type3_st: DAYS: **0** +test_time_fall_type3_redodt_type3_post: DAYS: **1** +test_time_fall_type3_redost_type3_prev: DAYS: **0** +test_time_fall_type3_redost_type3_dt: DAYS: **0** +test_time_fall_type3_redost_type3_redodt: DAYS: **0** +test_time_fall_type3_redost_type3_redost: DAYS: **0** +test_time_fall_type3_redost_type3_st: DAYS: **0** +test_time_fall_type3_redost_type3_post: DAYS: **1** +test_time_fall_type3_st_type3_prev: DAYS: **0** +test_time_fall_type3_st_type3_dt: DAYS: **0** +test_time_fall_type3_st_type3_redodt: DAYS: **0** +test_time_fall_type3_st_type3_redost: DAYS: **0** +test_time_fall_type3_st_type3_st: DAYS: **0** +test_time_fall_type3_st_type3_post: DAYS: **1** +test_time_fall_type3_post_type3_prev: DAYS: **2** +test_time_fall_type3_post_type3_dt: DAYS: **1** +test_time_fall_type3_post_type3_redodt: DAYS: **1** +test_time_fall_type3_post_type3_redost: DAYS: **1** +test_time_fall_type3_post_type3_st: DAYS: **1** +test_time_fall_type3_post_type3_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-february.phpt b/ext/date/tests/DateTime_days-february.phpt new file mode 100644 index 0000000000000..b8107d703d216 --- /dev/null +++ b/ext/date/tests/DateTime_days-february.phpt @@ -0,0 +1,77 @@ +--TEST-- +DateTime::diff() days -- february +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_bug_49081__1: DAYS: **30** +test_bug_49081__2: DAYS: **31** +test_bug_49081__3: DAYS: **1** +test_bug_49081__4: DAYS: **29** +test_bug_49081__5: DAYS: **30** +test_bug_49081__6: DAYS: **31** +test_bug_49081__7: DAYS: **32** +test_bug_49081__8: DAYS: **28** +test_bug_49081__9: DAYS: **29** +test_bug_49081__10: DAYS: **30** +test_bug_49081__11: DAYS: **31** +test_bug_49081__12: DAYS: **1** +test_bug_49081__13: DAYS: **27** +test_bug_49081__14: DAYS: **28** +test_bug_49081__15: DAYS: **29** +test_bug_49081__16: DAYS: **30** +test_bug_49081__17: DAYS: **31** +test_bug_49081__18: DAYS: **32** +test_bug_49081__19: DAYS: **59** +test_bug_49081__20: DAYS: **29** +test_bug_49081__21: DAYS: **55** +test_bug_49081__22: DAYS: **56** +test_bug_49081__23: DAYS: **57** +test_bug_49081__24: DAYS: **58** +test_bug_49081__25: DAYS: **59** +test_bug_49081__26: DAYS: **60** +test_bug_49081__27: DAYS: **30** +test_bug_49081__28: DAYS: **27** +test_bug_49081__29: DAYS: **28** +test_bug_49081__30: DAYS: **29** +test_bug_49081__31: DAYS: **28** +test_bug_49081__32: DAYS: **29** +test_bug_49081_negative__1: DAYS: **30** +test_bug_49081_negative__2: DAYS: **31** +test_bug_49081_negative__3: DAYS: **1** +test_bug_49081_negative__4: DAYS: **29** +test_bug_49081_negative__5: DAYS: **30** +test_bug_49081_negative__6: DAYS: **31** +test_bug_49081_negative__7: DAYS: **32** +test_bug_49081_negative__8: DAYS: **28** +test_bug_49081_negative__9: DAYS: **29** +test_bug_49081_negative__10: DAYS: **30** +test_bug_49081_negative__11: DAYS: **31** +test_bug_49081_negative__12: DAYS: **1** +test_bug_49081_negative__13: DAYS: **27** +test_bug_49081_negative__14: DAYS: **28** +test_bug_49081_negative__15: DAYS: **29** +test_bug_49081_negative__16: DAYS: **30** +test_bug_49081_negative__17: DAYS: **31** +test_bug_49081_negative__18: DAYS: **32** +test_bug_49081_negative__19: DAYS: **59** +test_bug_49081_negative__20: DAYS: **29** +test_bug_49081_negative__21: DAYS: **55** +test_bug_49081_negative__22: DAYS: **56** +test_bug_49081_negative__23: DAYS: **57** +test_bug_49081_negative__24: DAYS: **58** +test_bug_49081_negative__25: DAYS: **59** +test_bug_49081_negative__26: DAYS: **60** +test_bug_49081_negative__27: DAYS: **30** +test_bug_49081_negative__28: DAYS: **27** +test_bug_49081_negative__29: DAYS: **28** +test_bug_49081_negative__30: DAYS: **29** +test_bug_49081_negative__31: DAYS: **28** +test_bug_49081_negative__32: DAYS: **29** diff --git a/ext/date/tests/DateTime_days-massive.phpt b/ext/date/tests/DateTime_days-massive.phpt new file mode 100644 index 0000000000000..de51a665811ee --- /dev/null +++ b/ext/date/tests/DateTime_days-massive.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::diff() days -- massive +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_massive_positive: DAYS: **243494757** +test_massive_negative: DAYS: **243494757** diff --git a/ext/date/tests/DateTime_days-spring-type2-type2.phpt b/ext/date/tests/DateTime_days-spring-type2-type2.phpt new file mode 100644 index 0000000000000..ead12e0e6e909 --- /dev/null +++ b/ext/date/tests/DateTime_days-spring-type2-type2.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::diff() days -- spring type2 type2 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type2_prev: DAYS: **30** +test_time_spring_type2_prev_type2_st: DAYS: **0** +test_time_spring_type2_prev_type2_dt: DAYS: **0** +test_time_spring_type2_prev_type2_post: DAYS: **2** +test_time_spring_type2_st_type2_prev: DAYS: **0** +test_time_spring_type2_st_type2_st: DAYS: **0** +test_time_spring_type2_st_type2_dt: DAYS: **0** +test_time_spring_type2_st_type2_post: DAYS: **1** +test_time_spring_type2_dt_type2_prev: DAYS: **0** +test_time_spring_type2_dt_type2_st: DAYS: **0** +test_time_spring_type2_dt_type2_dt: DAYS: **0** +test_time_spring_type2_dt_type2_post: DAYS: **1** +test_time_spring_type2_post_type2_prev: DAYS: **2** +test_time_spring_type2_post_type2_st: DAYS: **1** +test_time_spring_type2_post_type2_dt: DAYS: **1** +test_time_spring_type2_post_type2_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type2-type3.phpt b/ext/date/tests/DateTime_days-spring-type2-type3.phpt new file mode 100644 index 0000000000000..bed7ac8f469ec --- /dev/null +++ b/ext/date/tests/DateTime_days-spring-type2-type3.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::diff() days -- spring type2 type3 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type3_prev: DAYS: **30** +test_time_spring_type2_prev_type3_st: DAYS: **0** +test_time_spring_type2_prev_type3_dt: DAYS: **0** +test_time_spring_type2_prev_type3_post: DAYS: **2** +test_time_spring_type2_st_type3_prev: DAYS: **0** +test_time_spring_type2_st_type3_st: DAYS: **0** +test_time_spring_type2_st_type3_dt: DAYS: **0** +test_time_spring_type2_st_type3_post: DAYS: **1** +test_time_spring_type2_dt_type3_prev: DAYS: **0** +test_time_spring_type2_dt_type3_st: DAYS: **0** +test_time_spring_type2_dt_type3_dt: DAYS: **0** +test_time_spring_type2_dt_type3_post: DAYS: **1** +test_time_spring_type2_post_type3_prev: DAYS: **2** +test_time_spring_type2_post_type3_st: DAYS: **1** +test_time_spring_type2_post_type3_dt: DAYS: **1** +test_time_spring_type2_post_type3_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type3-type2.phpt b/ext/date/tests/DateTime_days-spring-type3-type2.phpt new file mode 100644 index 0000000000000..782dee567d08a --- /dev/null +++ b/ext/date/tests/DateTime_days-spring-type3-type2.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::diff() days -- spring type3 type2 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type2_prev: DAYS: **30** +test_time_spring_type3_prev_type2_st: DAYS: **0** +test_time_spring_type3_prev_type2_dt: DAYS: **0** +test_time_spring_type3_prev_type2_post: DAYS: **2** +test_time_spring_type3_st_type2_prev: DAYS: **0** +test_time_spring_type3_st_type2_st: DAYS: **0** +test_time_spring_type3_st_type2_dt: DAYS: **0** +test_time_spring_type3_st_type2_post: DAYS: **1** +test_time_spring_type3_dt_type2_prev: DAYS: **0** +test_time_spring_type3_dt_type2_st: DAYS: **0** +test_time_spring_type3_dt_type2_dt: DAYS: **0** +test_time_spring_type3_dt_type2_post: DAYS: **1** +test_time_spring_type3_post_type2_prev: DAYS: **2** +test_time_spring_type3_post_type2_st: DAYS: **1** +test_time_spring_type3_post_type2_dt: DAYS: **1** +test_time_spring_type3_post_type2_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type3-type3.phpt b/ext/date/tests/DateTime_days-spring-type3-type3.phpt new file mode 100644 index 0000000000000..4b8e8c0d9c374 --- /dev/null +++ b/ext/date/tests/DateTime_days-spring-type3-type3.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::diff() days -- spring type3 type3 +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type3_prev: DAYS: **30** +test_time_spring_type3_prev_type3_st: DAYS: **0** +test_time_spring_type3_prev_type3_dt: DAYS: **0** +test_time_spring_type3_prev_type3_post: DAYS: **2** +test_time_spring_type3_st_type3_prev: DAYS: **0** +test_time_spring_type3_st_type3_st: DAYS: **0** +test_time_spring_type3_st_type3_dt: DAYS: **0** +test_time_spring_type3_st_type3_post: DAYS: **1** +test_time_spring_type3_dt_type3_prev: DAYS: **0** +test_time_spring_type3_dt_type3_st: DAYS: **0** +test_time_spring_type3_dt_type3_dt: DAYS: **0** +test_time_spring_type3_dt_type3_post: DAYS: **1** +test_time_spring_type3_post_type3_prev: DAYS: **2** +test_time_spring_type3_post_type3_st: DAYS: **1** +test_time_spring_type3_post_type3_dt: DAYS: **1** +test_time_spring_type3_post_type3_post: DAYS: **0** diff --git a/ext/date/tests/DateTime_diff-absolute.phpt b/ext/date/tests/DateTime_diff-absolute.phpt new file mode 100644 index 0000000000000..5295b3a721d2a --- /dev/null +++ b/ext/date/tests/DateTime_diff-absolute.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::diff() -- absolute +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_absolute_7: DIFF: 2009-01-14 00:00:00 EST - 2009-01-07 00:00:00 EST = **P+0Y0M7DT0H0M0S** +test_absolute_negative_7: DIFF: 2009-01-07 00:00:00 EST - 2009-01-14 00:00:00 EST = **P+0Y0M7DT0H0M0S** diff --git a/ext/date/tests/DateTime_diff-dates.phpt b/ext/date/tests/DateTime_diff-dates.phpt new file mode 100644 index 0000000000000..71c5e1b6c8c55 --- /dev/null +++ b/ext/date/tests/DateTime_diff-dates.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::diff() -- dates +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test__7: DIFF: 2009-01-14 00:00:00 EST - 2009-01-07 00:00:00 EST = **P+0Y0M7DT0H0M0S** +test_years_positive__7_by_0_day: DIFF: 2007-02-07 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+7Y0M0DT0H0M0S** +test_years_positive__7_by_1_day: DIFF: 2007-02-08 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+7Y0M1DT0H0M0S** +test_years_positive__6_shy_1_day: DIFF: 2007-02-06 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+6Y11M30DT0H0M0S** +test_years_positive__7_by_1_month: DIFF: 2007-03-07 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+7Y1M0DT0H0M0S** +test_years_positive__6_shy_1_month: DIFF: 2007-01-07 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+6Y11M0DT0H0M0S** +test_years_positive__7_by_1_month_split_newyear: DIFF: 2007-01-07 00:00:00 EST - 1999-12-07 00:00:00 EST = **P+7Y1M0DT0H0M0S** +test_years_positive__6_shy_1_month_split_newyear: DIFF: 2006-12-07 00:00:00 EST - 2000-01-07 00:00:00 EST = **P+6Y11M0DT0H0M0S** +test_negative__7: DIFF: 2009-01-07 00:00:00 EST - 2009-01-14 00:00:00 EST = **P-0Y0M7DT0H0M0S** +test_years_negative__7_by_0_day: DIFF: 2000-02-07 00:00:00 EST - 2007-02-07 00:00:00 EST = **P-7Y0M0DT0H0M0S** +test_years_negative__7_by_1_day: DIFF: 2000-02-07 00:00:00 EST - 2007-02-08 00:00:00 EST = **P-7Y0M1DT0H0M0S** +test_years_negative__6_shy_1_day: DIFF: 2000-02-07 00:00:00 EST - 2007-02-06 00:00:00 EST = **P-6Y11M28DT0H0M0S** +test_years_negative__7_by_1_month: DIFF: 2000-02-07 00:00:00 EST - 2007-03-07 00:00:00 EST = **P-7Y1M0DT0H0M0S** +test_years_negative__6_shy_1_month: DIFF: 2000-02-07 00:00:00 EST - 2007-01-07 00:00:00 EST = **P-6Y11M0DT0H0M0S** +test_years_negative__7_by_1_month_split_newyear: DIFF: 1999-12-07 00:00:00 EST - 2007-01-07 00:00:00 EST = **P-7Y1M0DT0H0M0S** +test_years_negative__6_shy_1_month_split_newyear: DIFF: 2000-01-07 00:00:00 EST - 2006-12-07 00:00:00 EST = **P-6Y11M0DT0H0M0S** diff --git a/ext/date/tests/DateTime_diff-fall-type2-type2.phpt b/ext/date/tests/DateTime_diff-fall-type2-type2.phpt new file mode 100644 index 0000000000000..276d84892d9b0 --- /dev/null +++ b/ext/date/tests/DateTime_diff-fall-type2-type2.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::diff() -- fall type2 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** +test_time_fall_type2_prev_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** +test_time_fall_type2_prev_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** +test_time_fall_type2_prev_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** +test_time_fall_type2_prev_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** +test_time_fall_type2_prev_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** +test_time_fall_type2_dt_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** +test_time_fall_type2_dt_type2_dt: DIFF: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** +test_time_fall_type2_dt_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** +test_time_fall_type2_dt_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** +test_time_fall_type2_dt_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** +test_time_fall_type2_dt_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** +test_time_fall_type2_redodt_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** +test_time_fall_type2_redodt_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** +test_time_fall_type2_redodt_type2_redodt: DIFF: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** +test_time_fall_type2_redodt_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** +test_time_fall_type2_redodt_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** +test_time_fall_type2_redodt_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** +test_time_fall_type2_redost_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** +test_time_fall_type2_redost_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** +test_time_fall_type2_redost_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** +test_time_fall_type2_redost_type2_redost: DIFF: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** +test_time_fall_type2_redost_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** +test_time_fall_type2_redost_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** +test_time_fall_type2_st_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** +test_time_fall_type2_st_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** +test_time_fall_type2_st_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** +test_time_fall_type2_st_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** +test_time_fall_type2_st_type2_st: DIFF: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** +test_time_fall_type2_st_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** +test_time_fall_type2_post_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** +test_time_fall_type2_post_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** +test_time_fall_type2_post_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** +test_time_fall_type2_post_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** +test_time_fall_type2_post_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** +test_time_fall_type2_post_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-fall-type2-type3.phpt b/ext/date/tests/DateTime_diff-fall-type2-type3.phpt new file mode 100644 index 0000000000000..b06c787d066e0 --- /dev/null +++ b/ext/date/tests/DateTime_diff-fall-type2-type3.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::diff() -- fall type2 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** +test_time_fall_type2_prev_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** +test_time_fall_type2_prev_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** +test_time_fall_type2_prev_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** +test_time_fall_type2_prev_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** +test_time_fall_type2_prev_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** +test_time_fall_type2_dt_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** +test_time_fall_type2_dt_type3_dt: DIFF: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** +test_time_fall_type2_dt_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** +test_time_fall_type2_dt_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** +test_time_fall_type2_dt_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** +test_time_fall_type2_dt_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** +test_time_fall_type2_redodt_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** +test_time_fall_type2_redodt_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** +test_time_fall_type2_redodt_type3_redodt: DIFF: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** +test_time_fall_type2_redodt_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** +test_time_fall_type2_redodt_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** +test_time_fall_type2_redodt_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** +test_time_fall_type2_redost_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** +test_time_fall_type2_redost_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** +test_time_fall_type2_redost_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** +test_time_fall_type2_redost_type3_redost: DIFF: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** +test_time_fall_type2_redost_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** +test_time_fall_type2_redost_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** +test_time_fall_type2_st_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** +test_time_fall_type2_st_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** +test_time_fall_type2_st_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** +test_time_fall_type2_st_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** +test_time_fall_type2_st_type3_st: DIFF: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** +test_time_fall_type2_st_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** +test_time_fall_type2_post_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** +test_time_fall_type2_post_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** +test_time_fall_type2_post_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** +test_time_fall_type2_post_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** +test_time_fall_type2_post_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** +test_time_fall_type2_post_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-fall-type3-type2.phpt b/ext/date/tests/DateTime_diff-fall-type3-type2.phpt new file mode 100644 index 0000000000000..58d72808b833c --- /dev/null +++ b/ext/date/tests/DateTime_diff-fall-type3-type2.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::diff() -- fall type3 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** +test_time_fall_type3_prev_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** +test_time_fall_type3_prev_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** +test_time_fall_type3_prev_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** +test_time_fall_type3_prev_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** +test_time_fall_type3_prev_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** +test_time_fall_type3_dt_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** +test_time_fall_type3_dt_type2_dt: DIFF: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** +test_time_fall_type3_dt_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** +test_time_fall_type3_dt_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** +test_time_fall_type3_dt_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** +test_time_fall_type3_dt_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** +test_time_fall_type3_redodt_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** +test_time_fall_type3_redodt_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** +test_time_fall_type3_redodt_type2_redodt: DIFF: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** +test_time_fall_type3_redodt_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** +test_time_fall_type3_redodt_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** +test_time_fall_type3_redodt_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** +test_time_fall_type3_redost_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** +test_time_fall_type3_redost_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** +test_time_fall_type3_redost_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** +test_time_fall_type3_redost_type2_redost: DIFF: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** +test_time_fall_type3_redost_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** +test_time_fall_type3_redost_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** +test_time_fall_type3_st_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** +test_time_fall_type3_st_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** +test_time_fall_type3_st_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** +test_time_fall_type3_st_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** +test_time_fall_type3_st_type2_st: DIFF: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** +test_time_fall_type3_st_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** +test_time_fall_type3_post_type2_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** +test_time_fall_type3_post_type2_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** +test_time_fall_type3_post_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** +test_time_fall_type3_post_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** +test_time_fall_type3_post_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** +test_time_fall_type3_post_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-fall-type3-type3.phpt b/ext/date/tests/DateTime_diff-fall-type3-type3.phpt new file mode 100644 index 0000000000000..d8313b78fc646 --- /dev/null +++ b/ext/date/tests/DateTime_diff-fall-type3-type3.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::diff() -- fall type3 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-10-04 02:18:48 EDT = **P+0Y1M2DT16H19M40S** +test_time_fall_type3_prev_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT5H31M52S** +test_time_fall_type3_prev_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT6H34M5S** +test_time_fall_type3_prev_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT7H36M16S** +test_time_fall_type3_prev_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M0DT9H38M27S** +test_time_fall_type3_prev_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-06 18:38:28 EDT = **P+0Y0M2DT1H21M31S** +test_time_fall_type3_dt_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 00:10:20 EDT = **P-0Y0M0DT5H31M52S** +test_time_fall_type3_dt_type3_dt: DIFF: 2010-11-07 00:15:35 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT0H5M15S** +test_time_fall_type3_dt_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT1H2M13S** +test_time_fall_type3_dt_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT2H4M24S** +test_time_fall_type3_dt_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M0DT4H6M35S** +test_time_fall_type3_dt_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 00:10:20 EDT = **P+0Y0M1DT20H49M39S** +test_time_fall_type3_redodt_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT6H34M5S** +test_time_fall_type3_redodt_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:12:33 EDT = **P-0Y0M0DT1H2M13S** +test_time_fall_type3_redodt_type3_redodt: DIFF: 2010-11-07 01:15:35 EDT - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT0H3M2S** +test_time_fall_type3_redodt_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT1H2M11S** +test_time_fall_type3_redodt_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M0DT3H4M22S** +test_time_fall_type3_redodt_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:12:33 EDT = **P+0Y0M1DT19H47M26S** +test_time_fall_type3_redost_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT7H36M16S** +test_time_fall_type3_redost_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT2H4M24S** +test_time_fall_type3_redost_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 01:14:44 EST = **P-0Y0M0DT1H2M11S** +test_time_fall_type3_redost_type3_redost: DIFF: 2010-11-07 01:16:54 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT0H2M10S** +test_time_fall_type3_redost_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-07 01:14:44 EST = **P+0Y0M0DT2H2M11S** +test_time_fall_type3_redost_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 01:14:44 EST = **P+0Y0M1DT18H45M15S** +test_time_fall_type3_st_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT9H38M27S** +test_time_fall_type3_st_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT4H6M35S** +test_time_fall_type3_st_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-07 03:16:55 EST = **P-0Y0M0DT3H4M22S** +test_time_fall_type3_st_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-07 03:16:55 EST = **P-0Y0M0DT2H2M11S** +test_time_fall_type3_st_type3_st: DIFF: 2010-11-07 05:19:56 EST - 2010-11-07 03:16:55 EST = **P+0Y0M0DT2H3M1S** +test_time_fall_type3_st_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-07 03:16:55 EST = **P+0Y0M1DT16H43M4S** +test_time_fall_type3_post_type3_prev: DIFF: 2010-11-06 18:38:28 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M2DT1H21M31S** +test_time_fall_type3_post_type3_dt: DIFF: 2010-11-07 00:10:20 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT20H49M39S** +test_time_fall_type3_post_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11-08 19:59:59 EST = **P-0Y0M1DT19H47M26S** +test_time_fall_type3_post_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** +test_time_fall_type3_post_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** +test_time_fall_type3_post_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-february.phpt b/ext/date/tests/DateTime_diff-february.phpt new file mode 100644 index 0000000000000..7705b12e32753 --- /dev/null +++ b/ext/date/tests/DateTime_diff-february.phpt @@ -0,0 +1,77 @@ +--TEST-- +DateTime::diff() -- february +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_bug_49081__1: DIFF: 2010-03-31 00:00:00 EDT - 2010-03-01 00:00:00 EST = **P+0Y0M30DT0H0M0S** +test_bug_49081__2: DIFF: 2010-04-01 00:00:00 EDT - 2010-03-01 00:00:00 EST = **P+0Y1M0DT0H0M0S** +test_bug_49081__3: DIFF: 2010-04-01 00:00:00 EDT - 2010-03-31 00:00:00 EDT = **P+0Y0M1DT0H0M0S** +test_bug_49081__4: DIFF: 2010-04-29 00:00:00 EDT - 2010-03-31 00:00:00 EDT = **P+0Y0M29DT0H0M0S** +test_bug_49081__5: DIFF: 2010-04-30 00:00:00 EDT - 2010-03-31 00:00:00 EDT = **P+0Y0M30DT0H0M0S** +test_bug_49081__6: DIFF: 2010-04-30 00:00:00 EDT - 2010-03-30 00:00:00 EDT = **P+0Y1M0DT0H0M0S** +test_bug_49081__7: DIFF: 2010-04-30 00:00:00 EDT - 2010-03-29 00:00:00 EDT = **P+0Y1M1DT0H0M0S** +test_bug_49081__8: DIFF: 2010-01-29 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y0M28DT0H0M0S** +test_bug_49081__9: DIFF: 2010-01-30 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y0M29DT0H0M0S** +test_bug_49081__10: DIFF: 2010-01-31 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y0M30DT0H0M0S** +test_bug_49081__11: DIFF: 2010-02-01 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y1M0DT0H0M0S** +test_bug_49081__12: DIFF: 2010-02-01 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M1DT0H0M0S** +test_bug_49081__13: DIFF: 2010-02-27 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M27DT0H0M0S** +test_bug_49081__14: DIFF: 2010-02-28 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M28DT0H0M0S** +test_bug_49081__15: DIFF: 2010-02-28 00:00:00 EST - 2010-01-30 00:00:00 EST = **P+0Y0M29DT0H0M0S** +test_bug_49081__16: DIFF: 2010-02-28 00:00:00 EST - 2010-01-29 00:00:00 EST = **P+0Y0M30DT0H0M0S** +test_bug_49081__17: DIFF: 2010-02-28 00:00:00 EST - 2010-01-28 00:00:00 EST = **P+0Y1M0DT0H0M0S** +test_bug_49081__18: DIFF: 2010-02-28 00:00:00 EST - 2010-01-27 00:00:00 EST = **P+0Y1M1DT0H0M0S** +test_bug_49081__19: DIFF: 2010-03-01 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y2M0DT0H0M0S** +test_bug_49081__20: DIFF: 2010-03-01 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M29DT0H0M0S** +test_bug_49081__21: DIFF: 2010-03-27 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M24DT0H0M0S** +test_bug_49081__22: DIFF: 2010-03-28 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M25DT0H0M0S** +test_bug_49081__23: DIFF: 2010-03-29 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M26DT0H0M0S** +test_bug_49081__24: DIFF: 2010-03-30 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M27DT0H0M0S** +test_bug_49081__25: DIFF: 2010-03-31 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y2M0DT0H0M0S** +test_bug_49081__26: DIFF: 2010-03-31 00:00:00 EDT - 2010-01-30 00:00:00 EST = **P+0Y2M1DT0H0M0S** +test_bug_49081__27: DIFF: 2009-01-31 00:00:00 EST - 2009-01-01 00:00:00 EST = **P+0Y0M30DT0H0M0S** +test_bug_49081__28: DIFF: 2010-03-27 00:00:00 EDT - 2010-02-28 00:00:00 EST = **P+0Y0M27DT0H0M0S** +test_bug_49081__29: DIFF: 2010-03-28 00:00:00 EDT - 2010-02-28 00:00:00 EST = **P+0Y1M0DT0H0M0S** +test_bug_49081__30: DIFF: 2010-03-29 00:00:00 EDT - 2010-02-28 00:00:00 EST = **P+0Y1M1DT0H0M0S** +test_bug_49081__31: DIFF: 2010-03-27 00:00:00 EDT - 2010-02-27 00:00:00 EST = **P+0Y1M0DT0H0M0S** +test_bug_49081__32: DIFF: 2010-03-27 00:00:00 EDT - 2010-02-26 00:00:00 EST = **P+0Y1M1DT0H0M0S** +test_bug_49081_negative__1: DIFF: 2010-03-01 00:00:00 EST - 2010-03-31 00:00:00 EDT = **P-0Y0M30DT0H0M0S** +test_bug_49081_negative__2: DIFF: 2010-03-01 00:00:00 EST - 2010-04-01 00:00:00 EDT = **P-0Y1M0DT0H0M0S** +test_bug_49081_negative__3: DIFF: 2010-03-31 00:00:00 EDT - 2010-04-01 00:00:00 EDT = **P-0Y0M1DT0H0M0S** +test_bug_49081_negative__4: DIFF: 2010-03-31 00:00:00 EDT - 2010-04-29 00:00:00 EDT = **P-0Y0M29DT0H0M0S** +test_bug_49081_negative__5: DIFF: 2010-03-31 00:00:00 EDT - 2010-04-30 00:00:00 EDT = **P-0Y0M30DT0H0M0S** +test_bug_49081_negative__6: DIFF: 2010-03-30 00:00:00 EDT - 2010-04-30 00:00:00 EDT = **P-0Y1M0DT0H0M0S** +test_bug_49081_negative__7: DIFF: 2010-03-29 00:00:00 EDT - 2010-04-30 00:00:00 EDT = **P-0Y1M1DT0H0M0S** +test_bug_49081_negative__8: DIFF: 2010-01-01 00:00:00 EST - 2010-01-29 00:00:00 EST = **P-0Y0M28DT0H0M0S** +test_bug_49081_negative__9: DIFF: 2010-01-01 00:00:00 EST - 2010-01-30 00:00:00 EST = **P-0Y0M29DT0H0M0S** +test_bug_49081_negative__10: DIFF: 2010-01-01 00:00:00 EST - 2010-01-31 00:00:00 EST = **P-0Y0M30DT0H0M0S** +test_bug_49081_negative__11: DIFF: 2010-01-01 00:00:00 EST - 2010-02-01 00:00:00 EST = **P-0Y1M0DT0H0M0S** +test_bug_49081_negative__12: DIFF: 2010-01-31 00:00:00 EST - 2010-02-01 00:00:00 EST = **P-0Y0M1DT0H0M0S** +test_bug_49081_negative__13: DIFF: 2010-01-31 00:00:00 EST - 2010-02-27 00:00:00 EST = **P-0Y0M27DT0H0M0S** +test_bug_49081_negative__14: DIFF: 2010-01-31 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y0M28DT0H0M0S** +test_bug_49081_negative__15: DIFF: 2010-01-30 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y0M29DT0H0M0S** +test_bug_49081_negative__16: DIFF: 2010-01-29 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y0M30DT0H0M0S** +test_bug_49081_negative__17: DIFF: 2010-01-28 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y1M0DT0H0M0S** +test_bug_49081_negative__18: DIFF: 2010-01-27 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y1M1DT0H0M0S** +test_bug_49081_negative__19: DIFF: 2010-01-01 00:00:00 EST - 2010-03-01 00:00:00 EST = **P-0Y2M0DT0H0M0S** +test_bug_49081_negative__20: DIFF: 2010-01-31 00:00:00 EST - 2010-03-01 00:00:00 EST = **P-0Y1M1DT0H0M0S** +test_bug_49081_negative__21: DIFF: 2010-01-31 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y1M27DT0H0M0S** +test_bug_49081_negative__22: DIFF: 2010-01-31 00:00:00 EST - 2010-03-28 00:00:00 EDT = **P-0Y1M28DT0H0M0S** +test_bug_49081_negative__23: DIFF: 2010-01-31 00:00:00 EST - 2010-03-29 00:00:00 EDT = **P-0Y1M29DT0H0M0S** +test_bug_49081_negative__24: DIFF: 2010-01-31 00:00:00 EST - 2010-03-30 00:00:00 EDT = **P-0Y1M30DT0H0M0S** +test_bug_49081_negative__25: DIFF: 2010-01-31 00:00:00 EST - 2010-03-31 00:00:00 EDT = **P-0Y2M0DT0H0M0S** +test_bug_49081_negative__26: DIFF: 2010-01-30 00:00:00 EST - 2010-03-31 00:00:00 EDT = **P-0Y2M1DT0H0M0S** +test_bug_49081_negative__27: DIFF: 2009-01-01 00:00:00 EST - 2009-01-31 00:00:00 EST = **P-0Y0M30DT0H0M0S** +test_bug_49081_negative__28: DIFF: 2010-02-28 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y0M27DT0H0M0S** +test_bug_49081_negative__29: DIFF: 2010-02-28 00:00:00 EST - 2010-03-28 00:00:00 EDT = **P-0Y1M0DT0H0M0S** +test_bug_49081_negative__30: DIFF: 2010-02-28 00:00:00 EST - 2010-03-29 00:00:00 EDT = **P-0Y1M1DT0H0M0S** +test_bug_49081_negative__31: DIFF: 2010-02-27 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y1M0DT0H0M0S** +test_bug_49081_negative__32: DIFF: 2010-02-26 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y1M1DT0H0M0S** diff --git a/ext/date/tests/DateTime_diff-massive.phpt b/ext/date/tests/DateTime_diff-massive.phpt new file mode 100644 index 0000000000000..2199f848640a8 --- /dev/null +++ b/ext/date/tests/DateTime_diff-massive.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::diff() -- massive +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_massive_positive: DIFF: 333333-01-01 16:18:02 EST - -333333-01-01 16:18:02 EST = **P+666666Y0M0DT0H0M0S** +test_massive_negative: DIFF: -333333-01-01 16:18:02 EST - 333333-01-01 16:18:02 EST = **P-666666Y0M0DT0H0M0S** diff --git a/ext/date/tests/DateTime_diff-spring-type2-type2.phpt b/ext/date/tests/DateTime_diff-spring-type2-type2.phpt new file mode 100644 index 0000000000000..7e9d5a5e71739 --- /dev/null +++ b/ext/date/tests/DateTime_diff-spring-type2-type2.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::diff() -- spring type2 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** +test_time_spring_type2_prev_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** +test_time_spring_type2_prev_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** +test_time_spring_type2_prev_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** +test_time_spring_type2_st_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** +test_time_spring_type2_st_type2_st: DIFF: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** +test_time_spring_type2_st_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** +test_time_spring_type2_st_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** +test_time_spring_type2_dt_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** +test_time_spring_type2_dt_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** +test_time_spring_type2_dt_type2_dt: DIFF: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** +test_time_spring_type2_dt_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** +test_time_spring_type2_post_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** +test_time_spring_type2_post_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** +test_time_spring_type2_post_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** +test_time_spring_type2_post_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-spring-type2-type3.phpt b/ext/date/tests/DateTime_diff-spring-type2-type3.phpt new file mode 100644 index 0000000000000..0c19782ed76e1 --- /dev/null +++ b/ext/date/tests/DateTime_diff-spring-type2-type3.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::diff() -- spring type2 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** +test_time_spring_type2_prev_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** +test_time_spring_type2_prev_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** +test_time_spring_type2_prev_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** +test_time_spring_type2_st_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** +test_time_spring_type2_st_type3_st: DIFF: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** +test_time_spring_type2_st_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** +test_time_spring_type2_st_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** +test_time_spring_type2_dt_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** +test_time_spring_type2_dt_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** +test_time_spring_type2_dt_type3_dt: DIFF: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** +test_time_spring_type2_dt_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** +test_time_spring_type2_post_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** +test_time_spring_type2_post_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** +test_time_spring_type2_post_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** +test_time_spring_type2_post_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-spring-type3-type2.phpt b/ext/date/tests/DateTime_diff-spring-type3-type2.phpt new file mode 100644 index 0000000000000..f2a31c1780ca6 --- /dev/null +++ b/ext/date/tests/DateTime_diff-spring-type3-type2.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::diff() -- spring type3 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** +test_time_spring_type3_prev_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** +test_time_spring_type3_prev_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** +test_time_spring_type3_prev_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** +test_time_spring_type3_st_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** +test_time_spring_type3_st_type2_st: DIFF: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** +test_time_spring_type3_st_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** +test_time_spring_type3_st_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** +test_time_spring_type3_dt_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** +test_time_spring_type3_dt_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** +test_time_spring_type3_dt_type2_dt: DIFF: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** +test_time_spring_type3_dt_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** +test_time_spring_type3_post_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** +test_time_spring_type3_post_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** +test_time_spring_type3_post_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** +test_time_spring_type3_post_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff-spring-type3-type3.phpt b/ext/date/tests/DateTime_diff-spring-type3-type3.phpt new file mode 100644 index 0000000000000..5f5c3d5b3efc2 --- /dev/null +++ b/ext/date/tests/DateTime_diff-spring-type3-type3.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::diff() -- spring type3 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-02-11 02:18:48 EST = **P+0Y1M2DT16H19M40S** +test_time_spring_type3_prev_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-13 18:38:28 EST = **P+0Y0M0DT5H31M52S** +test_time_spring_type3_prev_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M0DT7H38M27S** +test_time_spring_type3_prev_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-13 18:38:28 EST = **P+0Y0M2DT1H21M31S** +test_time_spring_type3_st_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 00:10:20 EST = **P-0Y0M0DT5H31M52S** +test_time_spring_type3_st_type3_st: DIFF: 2010-03-14 00:15:35 EST - 2010-03-14 00:10:20 EST = **P+0Y0M0DT0H5M15S** +test_time_spring_type3_st_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M0DT2H6M35S** +test_time_spring_type3_st_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 00:10:20 EST = **P+0Y0M1DT18H49M39S** +test_time_spring_type3_dt_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT7H38M27S** +test_time_spring_type3_dt_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-14 03:16:55 EDT = **P-0Y0M0DT2H6M35S** +test_time_spring_type3_dt_type3_dt: DIFF: 2010-03-14 05:19:56 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M0DT2H3M1S** +test_time_spring_type3_dt_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-14 03:16:55 EDT = **P+0Y0M1DT16H43M4S** +test_time_spring_type3_post_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M2DT1H21M31S** +test_time_spring_type3_post_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** +test_time_spring_type3_post_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** +test_time_spring_type3_post_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** diff --git a/ext/date/tests/DateTime_diff_add_sub-absolute.phpt b/ext/date/tests/DateTime_diff_add_sub-absolute.phpt deleted file mode 100644 index c66ba7d2f3701..0000000000000 --- a/ext/date/tests/DateTime_diff_add_sub-absolute.phpt +++ /dev/null @@ -1,29 +0,0 @@ ---TEST-- -DateTime::diff() add() sub() -- absolute ---CREDITS-- -Daniel Convissor ---FILE-- - ---EXPECT-- -test_absolute_7: FWD: 2009-01-14 00:00:00 EST - 2009-01-07 00:00:00 EST = **P+0Y0M7DT0H0M0S** | BACK: 2009-01-07 00:00:00 EST + P+0Y0M7DT0H0M0S = **2009-01-14 00:00:00 EST** | DAYS: **7** -test_absolute_negative_7: FWD: 2009-01-07 00:00:00 EST - 2009-01-14 00:00:00 EST = **P+0Y0M7DT0H0M0S** | BACK: 2009-01-14 00:00:00 EST - P+0Y0M7DT0H0M0S = **2009-01-07 00:00:00 EST** | DAYS: **7** diff --git a/ext/date/tests/DateTime_diff_add_sub-dates.phpt b/ext/date/tests/DateTime_diff_add_sub-dates.phpt deleted file mode 100644 index 23db1a199406c..0000000000000 --- a/ext/date/tests/DateTime_diff_add_sub-dates.phpt +++ /dev/null @@ -1,89 +0,0 @@ ---TEST-- -DateTime::diff() add() sub() -- dates ---CREDITS-- -Daniel Convissor ---FILE-- - ---EXPECT-- -test__7: FWD: 2009-01-14 00:00:00 EST - 2009-01-07 00:00:00 EST = **P+0Y0M7DT0H0M0S** | BACK: 2009-01-07 00:00:00 EST + P+0Y0M7DT0H0M0S = **2009-01-14 00:00:00 EST** | DAYS: **7** -test_years_positive__7_by_0_day: FWD: 2007-02-07 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+7Y0M0DT0H0M0S** | BACK: 2000-02-07 00:00:00 EST + P+7Y0M0DT0H0M0S = **2007-02-07 00:00:00 EST** | DAYS: **2557** -test_years_positive__7_by_1_day: FWD: 2007-02-08 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+7Y0M1DT0H0M0S** | BACK: 2000-02-07 00:00:00 EST + P+7Y0M1DT0H0M0S = **2007-02-08 00:00:00 EST** | DAYS: **2558** -test_years_positive__6_shy_1_day: FWD: 2007-02-06 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+6Y11M30DT0H0M0S** | BACK: 2000-02-07 00:00:00 EST + P+6Y11M30DT0H0M0S = **2007-02-06 00:00:00 EST** | DAYS: **2556** -test_years_positive__7_by_1_month: FWD: 2007-03-07 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+7Y1M0DT0H0M0S** | BACK: 2000-02-07 00:00:00 EST + P+7Y1M0DT0H0M0S = **2007-03-07 00:00:00 EST** | DAYS: **2585** -test_years_positive__6_shy_1_month: FWD: 2007-01-07 00:00:00 EST - 2000-02-07 00:00:00 EST = **P+6Y11M0DT0H0M0S** | BACK: 2000-02-07 00:00:00 EST + P+6Y11M0DT0H0M0S = **2007-01-07 00:00:00 EST** | DAYS: **2526** -test_years_positive__7_by_1_month_split_newyear: FWD: 2007-01-07 00:00:00 EST - 1999-12-07 00:00:00 EST = **P+7Y1M0DT0H0M0S** | BACK: 1999-12-07 00:00:00 EST + P+7Y1M0DT0H0M0S = **2007-01-07 00:00:00 EST** | DAYS: **2588** -test_years_positive__6_shy_1_month_split_newyear: FWD: 2006-12-07 00:00:00 EST - 2000-01-07 00:00:00 EST = **P+6Y11M0DT0H0M0S** | BACK: 2000-01-07 00:00:00 EST + P+6Y11M0DT0H0M0S = **2006-12-07 00:00:00 EST** | DAYS: **2526** -test_negative__7: FWD: 2009-01-07 00:00:00 EST - 2009-01-14 00:00:00 EST = **P-0Y0M7DT0H0M0S** | BACK: 2009-01-14 00:00:00 EST + P-0Y0M7DT0H0M0S = **2009-01-07 00:00:00 EST** | DAYS: **7** -test_years_negative__7_by_0_day: FWD: 2000-02-07 00:00:00 EST - 2007-02-07 00:00:00 EST = **P-7Y0M0DT0H0M0S** | BACK: 2007-02-07 00:00:00 EST + P-7Y0M0DT0H0M0S = **2000-02-07 00:00:00 EST** | DAYS: **2557** -test_years_negative__7_by_1_day: FWD: 2000-02-07 00:00:00 EST - 2007-02-08 00:00:00 EST = **P-7Y0M1DT0H0M0S** | BACK: 2007-02-08 00:00:00 EST + P-7Y0M1DT0H0M0S = **2000-02-07 00:00:00 EST** | DAYS: **2558** -test_years_negative__6_shy_1_day: FWD: 2000-02-07 00:00:00 EST - 2007-02-06 00:00:00 EST = **P-6Y11M28DT0H0M0S** | BACK: 2007-02-06 00:00:00 EST + P-6Y11M28DT0H0M0S = **2000-02-07 00:00:00 EST** | DAYS: **2556** -test_years_negative__7_by_1_month: FWD: 2000-02-07 00:00:00 EST - 2007-03-07 00:00:00 EST = **P-7Y1M0DT0H0M0S** | BACK: 2007-03-07 00:00:00 EST + P-7Y1M0DT0H0M0S = **2000-02-07 00:00:00 EST** | DAYS: **2585** -test_years_negative__6_shy_1_month: FWD: 2000-02-07 00:00:00 EST - 2007-01-07 00:00:00 EST = **P-6Y11M0DT0H0M0S** | BACK: 2007-01-07 00:00:00 EST + P-6Y11M0DT0H0M0S = **2000-02-07 00:00:00 EST** | DAYS: **2526** -test_years_negative__7_by_1_month_split_newyear: FWD: 1999-12-07 00:00:00 EST - 2007-01-07 00:00:00 EST = **P-7Y1M0DT0H0M0S** | BACK: 2007-01-07 00:00:00 EST + P-7Y1M0DT0H0M0S = **1999-12-07 00:00:00 EST** | DAYS: **2588** -test_years_negative__6_shy_1_month_split_newyear: FWD: 2000-01-07 00:00:00 EST - 2006-12-07 00:00:00 EST = **P-6Y11M0DT0H0M0S** | BACK: 2006-12-07 00:00:00 EST + P-6Y11M0DT0H0M0S = **2000-01-07 00:00:00 EST** | DAYS: **2526** diff --git a/ext/date/tests/DateTime_diff_add_sub-february.phpt b/ext/date/tests/DateTime_diff_add_sub-february.phpt deleted file mode 100644 index 388c89f09dc6e..0000000000000 --- a/ext/date/tests/DateTime_diff_add_sub-february.phpt +++ /dev/null @@ -1,281 +0,0 @@ ---TEST-- -DateTime::diff() add() sub() -- february ---CREDITS-- -Daniel Convissor ---FILE-- - ---EXPECT-- -test_bug_49081__1: FWD: 2010-03-31 00:00:00 EDT - 2010-03-01 00:00:00 EST = **P+0Y0M30DT0H0M0S** | BACK: 2010-03-01 00:00:00 EST + P+0Y0M30DT0H0M0S = **2010-03-31 00:00:00 EDT** | DAYS: **30** -test_bug_49081__2: FWD: 2010-04-01 00:00:00 EDT - 2010-03-01 00:00:00 EST = **P+0Y1M0DT0H0M0S** | BACK: 2010-03-01 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-04-01 00:00:00 EDT** | DAYS: **31** -test_bug_49081__3: FWD: 2010-04-01 00:00:00 EDT - 2010-03-31 00:00:00 EDT = **P+0Y0M1DT0H0M0S** | BACK: 2010-03-31 00:00:00 EDT + P+0Y0M1DT0H0M0S = **2010-04-01 00:00:00 EDT** | DAYS: **1** -test_bug_49081__4: FWD: 2010-04-29 00:00:00 EDT - 2010-03-31 00:00:00 EDT = **P+0Y0M29DT0H0M0S** | BACK: 2010-03-31 00:00:00 EDT + P+0Y0M29DT0H0M0S = **2010-04-29 00:00:00 EDT** | DAYS: **29** -test_bug_49081__5: FWD: 2010-04-30 00:00:00 EDT - 2010-03-31 00:00:00 EDT = **P+0Y0M30DT0H0M0S** | BACK: 2010-03-31 00:00:00 EDT + P+0Y0M30DT0H0M0S = **2010-04-30 00:00:00 EDT** | DAYS: **30** -test_bug_49081__6: FWD: 2010-04-30 00:00:00 EDT - 2010-03-30 00:00:00 EDT = **P+0Y1M0DT0H0M0S** | BACK: 2010-03-30 00:00:00 EDT + P+0Y1M0DT0H0M0S = **2010-04-30 00:00:00 EDT** | DAYS: **31** -test_bug_49081__7: FWD: 2010-04-30 00:00:00 EDT - 2010-03-29 00:00:00 EDT = **P+0Y1M1DT0H0M0S** | BACK: 2010-03-29 00:00:00 EDT + P+0Y1M1DT0H0M0S = **2010-04-30 00:00:00 EDT** | DAYS: **32** -test_bug_49081__8: FWD: 2010-01-29 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y0M28DT0H0M0S** | BACK: 2010-01-01 00:00:00 EST + P+0Y0M28DT0H0M0S = **2010-01-29 00:00:00 EST** | DAYS: **28** -test_bug_49081__9: FWD: 2010-01-30 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y0M29DT0H0M0S** | BACK: 2010-01-01 00:00:00 EST + P+0Y0M29DT0H0M0S = **2010-01-30 00:00:00 EST** | DAYS: **29** -test_bug_49081__10: FWD: 2010-01-31 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y0M30DT0H0M0S** | BACK: 2010-01-01 00:00:00 EST + P+0Y0M30DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **30** -test_bug_49081__11: FWD: 2010-02-01 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y1M0DT0H0M0S** | BACK: 2010-01-01 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-02-01 00:00:00 EST** | DAYS: **31** -test_bug_49081__12: FWD: 2010-02-01 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M1DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y0M1DT0H0M0S = **2010-02-01 00:00:00 EST** | DAYS: **1** -test_bug_49081__13: FWD: 2010-02-27 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M27DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y0M27DT0H0M0S = **2010-02-27 00:00:00 EST** | DAYS: **27** -test_bug_49081__14: FWD: 2010-02-28 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M28DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y0M28DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **28** -test_bug_49081__15: FWD: 2010-02-28 00:00:00 EST - 2010-01-30 00:00:00 EST = **P+0Y0M29DT0H0M0S** | BACK: 2010-01-30 00:00:00 EST + P+0Y0M29DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **29** -test_bug_49081__16: FWD: 2010-02-28 00:00:00 EST - 2010-01-29 00:00:00 EST = **P+0Y0M30DT0H0M0S** | BACK: 2010-01-29 00:00:00 EST + P+0Y0M30DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **30** -test_bug_49081__17: FWD: 2010-02-28 00:00:00 EST - 2010-01-28 00:00:00 EST = **P+0Y1M0DT0H0M0S** | BACK: 2010-01-28 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **31** -test_bug_49081__18: FWD: 2010-02-28 00:00:00 EST - 2010-01-27 00:00:00 EST = **P+0Y1M1DT0H0M0S** | BACK: 2010-01-27 00:00:00 EST + P+0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **32** -test_bug_49081__19: FWD: 2010-03-01 00:00:00 EST - 2010-01-01 00:00:00 EST = **P+0Y2M0DT0H0M0S** | BACK: 2010-01-01 00:00:00 EST + P+0Y2M0DT0H0M0S = **2010-03-01 00:00:00 EST** | DAYS: **59** -test_bug_49081__20: FWD: 2010-03-01 00:00:00 EST - 2010-01-31 00:00:00 EST = **P+0Y0M29DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y0M29DT0H0M0S = **2010-03-01 00:00:00 EST** | DAYS: **29** -test_bug_49081__21: FWD: 2010-03-27 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M24DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y1M24DT0H0M0S = **2010-03-27 00:00:00 EDT** | DAYS: **55** -test_bug_49081__22: FWD: 2010-03-28 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M25DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y1M25DT0H0M0S = **2010-03-28 00:00:00 EDT** | DAYS: **56** -test_bug_49081__23: FWD: 2010-03-29 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M26DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y1M26DT0H0M0S = **2010-03-29 00:00:00 EDT** | DAYS: **57** -test_bug_49081__24: FWD: 2010-03-30 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y1M27DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y1M27DT0H0M0S = **2010-03-30 00:00:00 EDT** | DAYS: **58** -test_bug_49081__25: FWD: 2010-03-31 00:00:00 EDT - 2010-01-31 00:00:00 EST = **P+0Y2M0DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P+0Y2M0DT0H0M0S = **2010-03-31 00:00:00 EDT** | DAYS: **59** -test_bug_49081__26: FWD: 2010-03-31 00:00:00 EDT - 2010-01-30 00:00:00 EST = **P+0Y2M1DT0H0M0S** | BACK: 2010-01-30 00:00:00 EST + P+0Y2M1DT0H0M0S = **2010-03-31 00:00:00 EDT** | DAYS: **60** -test_bug_49081__27: FWD: 2009-01-31 00:00:00 EST - 2009-01-01 00:00:00 EST = **P+0Y0M30DT0H0M0S** | BACK: 2009-01-01 00:00:00 EST + P+0Y0M30DT0H0M0S = **2009-01-31 00:00:00 EST** | DAYS: **30** -test_bug_49081__28: FWD: 2010-03-27 00:00:00 EDT - 2010-02-28 00:00:00 EST = **P+0Y0M27DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P+0Y0M27DT0H0M0S = **2010-03-27 00:00:00 EDT** | DAYS: **27** -test_bug_49081__29: FWD: 2010-03-28 00:00:00 EDT - 2010-02-28 00:00:00 EST = **P+0Y1M0DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-03-28 00:00:00 EDT** | DAYS: **28** -test_bug_49081__30: FWD: 2010-03-29 00:00:00 EDT - 2010-02-28 00:00:00 EST = **P+0Y1M1DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P+0Y1M1DT0H0M0S = **2010-03-29 00:00:00 EDT** | DAYS: **29** -test_bug_49081__31: FWD: 2010-03-27 00:00:00 EDT - 2010-02-27 00:00:00 EST = **P+0Y1M0DT0H0M0S** | BACK: 2010-02-27 00:00:00 EST + P+0Y1M0DT0H0M0S = **2010-03-27 00:00:00 EDT** | DAYS: **28** -test_bug_49081__32: FWD: 2010-03-27 00:00:00 EDT - 2010-02-26 00:00:00 EST = **P+0Y1M1DT0H0M0S** | BACK: 2010-02-26 00:00:00 EST + P+0Y1M1DT0H0M0S = **2010-03-27 00:00:00 EDT** | DAYS: **29** -test_bug_49081_negative__1: FWD: 2010-03-01 00:00:00 EST - 2010-03-31 00:00:00 EDT = **P-0Y0M30DT0H0M0S** | BACK: 2010-03-31 00:00:00 EDT + P-0Y0M30DT0H0M0S = **2010-03-01 00:00:00 EST** | DAYS: **30** -test_bug_49081_negative__2: FWD: 2010-03-01 00:00:00 EST - 2010-04-01 00:00:00 EDT = **P-0Y1M0DT0H0M0S** | BACK: 2010-04-01 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-03-01 00:00:00 EST** | DAYS: **31** -test_bug_49081_negative__3: FWD: 2010-03-31 00:00:00 EDT - 2010-04-01 00:00:00 EDT = **P-0Y0M1DT0H0M0S** | BACK: 2010-04-01 00:00:00 EDT + P-0Y0M1DT0H0M0S = **2010-03-31 00:00:00 EDT** | DAYS: **1** -test_bug_49081_negative__4: FWD: 2010-03-31 00:00:00 EDT - 2010-04-29 00:00:00 EDT = **P-0Y0M29DT0H0M0S** | BACK: 2010-04-29 00:00:00 EDT + P-0Y0M29DT0H0M0S = **2010-03-31 00:00:00 EDT** | DAYS: **29** -test_bug_49081_negative__5: FWD: 2010-03-31 00:00:00 EDT - 2010-04-30 00:00:00 EDT = **P-0Y0M30DT0H0M0S** | BACK: 2010-04-30 00:00:00 EDT + P-0Y0M30DT0H0M0S = **2010-03-31 00:00:00 EDT** | DAYS: **30** -test_bug_49081_negative__6: FWD: 2010-03-30 00:00:00 EDT - 2010-04-30 00:00:00 EDT = **P-0Y1M0DT0H0M0S** | BACK: 2010-04-30 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-03-30 00:00:00 EDT** | DAYS: **31** -test_bug_49081_negative__7: FWD: 2010-03-29 00:00:00 EDT - 2010-04-30 00:00:00 EDT = **P-0Y1M1DT0H0M0S** | BACK: 2010-04-30 00:00:00 EDT + P-0Y1M1DT0H0M0S = **2010-03-29 00:00:00 EDT** | DAYS: **32** -test_bug_49081_negative__8: FWD: 2010-01-01 00:00:00 EST - 2010-01-29 00:00:00 EST = **P-0Y0M28DT0H0M0S** | BACK: 2010-01-29 00:00:00 EST + P-0Y0M28DT0H0M0S = **2010-01-01 00:00:00 EST** | DAYS: **28** -test_bug_49081_negative__9: FWD: 2010-01-01 00:00:00 EST - 2010-01-30 00:00:00 EST = **P-0Y0M29DT0H0M0S** | BACK: 2010-01-30 00:00:00 EST + P-0Y0M29DT0H0M0S = **2010-01-01 00:00:00 EST** | DAYS: **29** -test_bug_49081_negative__10: FWD: 2010-01-01 00:00:00 EST - 2010-01-31 00:00:00 EST = **P-0Y0M30DT0H0M0S** | BACK: 2010-01-31 00:00:00 EST + P-0Y0M30DT0H0M0S = **2010-01-01 00:00:00 EST** | DAYS: **30** -test_bug_49081_negative__11: FWD: 2010-01-01 00:00:00 EST - 2010-02-01 00:00:00 EST = **P-0Y1M0DT0H0M0S** | BACK: 2010-02-01 00:00:00 EST + P-0Y1M0DT0H0M0S = **2010-01-01 00:00:00 EST** | DAYS: **31** -test_bug_49081_negative__12: FWD: 2010-01-31 00:00:00 EST - 2010-02-01 00:00:00 EST = **P-0Y0M1DT0H0M0S** | BACK: 2010-02-01 00:00:00 EST + P-0Y0M1DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **1** -test_bug_49081_negative__13: FWD: 2010-01-31 00:00:00 EST - 2010-02-27 00:00:00 EST = **P-0Y0M27DT0H0M0S** | BACK: 2010-02-27 00:00:00 EST + P-0Y0M27DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **27** -test_bug_49081_negative__14: FWD: 2010-01-31 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y0M28DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P-0Y0M28DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **28** -test_bug_49081_negative__15: FWD: 2010-01-30 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y0M29DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P-0Y0M29DT0H0M0S = **2010-01-30 00:00:00 EST** | DAYS: **29** -test_bug_49081_negative__16: FWD: 2010-01-29 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y0M30DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P-0Y0M30DT0H0M0S = **2010-01-29 00:00:00 EST** | DAYS: **30** -test_bug_49081_negative__17: FWD: 2010-01-28 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y1M0DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P-0Y1M0DT0H0M0S = **2010-01-28 00:00:00 EST** | DAYS: **31** -test_bug_49081_negative__18: FWD: 2010-01-27 00:00:00 EST - 2010-02-28 00:00:00 EST = **P-0Y1M1DT0H0M0S** | BACK: 2010-02-28 00:00:00 EST + P-0Y1M1DT0H0M0S = **2010-01-27 00:00:00 EST** | DAYS: **32** -test_bug_49081_negative__19: FWD: 2010-01-01 00:00:00 EST - 2010-03-01 00:00:00 EST = **P-0Y2M0DT0H0M0S** | BACK: 2010-03-01 00:00:00 EST + P-0Y2M0DT0H0M0S = **2010-01-01 00:00:00 EST** | DAYS: **59** -test_bug_49081_negative__20: FWD: 2010-01-31 00:00:00 EST - 2010-03-01 00:00:00 EST = **P-0Y1M1DT0H0M0S** | BACK: 2010-03-01 00:00:00 EST + P-0Y1M1DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **29** -test_bug_49081_negative__21: FWD: 2010-01-31 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y1M27DT0H0M0S** | BACK: 2010-03-27 00:00:00 EDT + P-0Y1M27DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **55** -test_bug_49081_negative__22: FWD: 2010-01-31 00:00:00 EST - 2010-03-28 00:00:00 EDT = **P-0Y1M28DT0H0M0S** | BACK: 2010-03-28 00:00:00 EDT + P-0Y1M28DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **56** -test_bug_49081_negative__23: FWD: 2010-01-31 00:00:00 EST - 2010-03-29 00:00:00 EDT = **P-0Y1M29DT0H0M0S** | BACK: 2010-03-29 00:00:00 EDT + P-0Y1M29DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **57** -test_bug_49081_negative__24: FWD: 2010-01-31 00:00:00 EST - 2010-03-30 00:00:00 EDT = **P-0Y1M30DT0H0M0S** | BACK: 2010-03-30 00:00:00 EDT + P-0Y1M30DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **58** -test_bug_49081_negative__25: FWD: 2010-01-31 00:00:00 EST - 2010-03-31 00:00:00 EDT = **P-0Y2M0DT0H0M0S** | BACK: 2010-03-31 00:00:00 EDT + P-0Y2M0DT0H0M0S = **2010-01-31 00:00:00 EST** | DAYS: **59** -test_bug_49081_negative__26: FWD: 2010-01-30 00:00:00 EST - 2010-03-31 00:00:00 EDT = **P-0Y2M1DT0H0M0S** | BACK: 2010-03-31 00:00:00 EDT + P-0Y2M1DT0H0M0S = **2010-01-30 00:00:00 EST** | DAYS: **60** -test_bug_49081_negative__27: FWD: 2009-01-01 00:00:00 EST - 2009-01-31 00:00:00 EST = **P-0Y0M30DT0H0M0S** | BACK: 2009-01-31 00:00:00 EST + P-0Y0M30DT0H0M0S = **2009-01-01 00:00:00 EST** | DAYS: **30** -test_bug_49081_negative__28: FWD: 2010-02-28 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y0M27DT0H0M0S** | BACK: 2010-03-27 00:00:00 EDT + P-0Y0M27DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **27** -test_bug_49081_negative__29: FWD: 2010-02-28 00:00:00 EST - 2010-03-28 00:00:00 EDT = **P-0Y1M0DT0H0M0S** | BACK: 2010-03-28 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **28** -test_bug_49081_negative__30: FWD: 2010-02-28 00:00:00 EST - 2010-03-29 00:00:00 EDT = **P-0Y1M1DT0H0M0S** | BACK: 2010-03-29 00:00:00 EDT + P-0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** | DAYS: **29** -test_bug_49081_negative__31: FWD: 2010-02-27 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y1M0DT0H0M0S** | BACK: 2010-03-27 00:00:00 EDT + P-0Y1M0DT0H0M0S = **2010-02-27 00:00:00 EST** | DAYS: **28** -test_bug_49081_negative__32: FWD: 2010-02-26 00:00:00 EST - 2010-03-27 00:00:00 EDT = **P-0Y1M1DT0H0M0S** | BACK: 2010-03-27 00:00:00 EDT + P-0Y1M1DT0H0M0S = **2010-02-26 00:00:00 EST** | DAYS: **29** diff --git a/ext/date/tests/DateTime_sub-dates.phpt b/ext/date/tests/DateTime_sub-dates.phpt new file mode 100644 index 0000000000000..36ca25c167ac7 --- /dev/null +++ b/ext/date/tests/DateTime_sub-dates.phpt @@ -0,0 +1,29 @@ +--TEST-- +DateTime::sub() -- dates +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test__7: SUB: 2009-01-14 00:00:00 EST - P+0Y0M7DT0H0M0S = **2009-01-07 00:00:00 EST** +test_years_positive__7_by_0_day: SUB: 2007-02-07 00:00:00 EST - P+7Y0M0DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_positive__7_by_1_day: SUB: 2007-02-08 00:00:00 EST - P+7Y0M1DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_positive__6_shy_1_day: SUB: 2007-02-06 00:00:00 EST - P+6Y11M30DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_positive__7_by_1_month: SUB: 2007-03-07 00:00:00 EST - P+7Y1M0DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_positive__6_shy_1_month: SUB: 2007-01-07 00:00:00 EST - P+6Y11M0DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_positive__7_by_1_month_split_newyear: SUB: 2007-01-07 00:00:00 EST - P+7Y1M0DT0H0M0S = **1999-12-07 00:00:00 EST** +test_years_positive__6_shy_1_month_split_newyear: SUB: 2006-12-07 00:00:00 EST - P+6Y11M0DT0H0M0S = **2000-01-07 00:00:00 EST** +test_negative__7: SUB: 2009-01-07 00:00:00 EST - P-0Y0M7DT0H0M0S = **2009-01-14 00:00:00 EST** +test_years_negative__7_by_0_day: SUB: 2000-02-07 00:00:00 EST - P-7Y0M0DT0H0M0S = **2007-02-07 00:00:00 EST** +test_years_negative__7_by_1_day: SUB: 2000-02-07 00:00:00 EST - P-7Y0M1DT0H0M0S = **2007-02-08 00:00:00 EST** +test_years_negative__6_shy_1_day: SUB: 2000-02-07 00:00:00 EST - P-6Y11M28DT0H0M0S = **2007-02-06 00:00:00 EST** +test_years_negative__7_by_1_month: SUB: 2000-02-07 00:00:00 EST - P-7Y1M0DT0H0M0S = **2007-03-07 00:00:00 EST** +test_years_negative__6_shy_1_month: SUB: 2000-02-07 00:00:00 EST - P-6Y11M0DT0H0M0S = **2007-01-07 00:00:00 EST** +test_years_negative__7_by_1_month_split_newyear: SUB: 1999-12-07 00:00:00 EST - P-7Y1M0DT0H0M0S = **2007-01-07 00:00:00 EST** +test_years_negative__6_shy_1_month_split_newyear: SUB: 2000-01-07 00:00:00 EST - P-6Y11M0DT0H0M0S = **2006-12-07 00:00:00 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type2-type2.phpt b/ext/date/tests/DateTime_sub-fall-type2-type2.phpt new file mode 100644 index 0000000000000..ac1147f78e6c9 --- /dev/null +++ b/ext/date/tests/DateTime_sub-fall-type2-type2.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::sub() -- fall type2 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P+0Y1M2DT16H19M40S = **2010-10-04 02:18:48 EDT** +test_time_fall_type2_prev_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P+0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type2_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_dt_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type2_dt: SUB: 2010-11-07 00:15:35 EDT - P+0Y0M0DT0H5M15S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type2_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_redodt_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type2_redodt: SUB: 2010-11-07 01:15:35 EDT - P+0Y0M0DT0H3M2S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type2_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redost_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type2_redost: SUB: 2010-11-07 01:16:54 EST - P+0Y0M0DT0H2M10S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_st_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type2_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type2_st: SUB: 2010-11-07 05:19:56 EST - P+0Y0M0DT2H3M1S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_post_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type2_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type2_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type2-type3.phpt b/ext/date/tests/DateTime_sub-fall-type2-type3.phpt new file mode 100644 index 0000000000000..f2fad2c9eba7b --- /dev/null +++ b/ext/date/tests/DateTime_sub-fall-type2-type3.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::sub() -- fall type2 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type2_prev_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P+0Y1M2DT16H19M40S = **2010-10-04 02:18:48 EDT** +test_time_fall_type2_prev_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P+0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type3_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_prev_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type2_dt_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type3_dt: SUB: 2010-11-07 00:15:35 EDT - P+0Y0M0DT0H5M15S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type3_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_dt_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type2_redodt_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type3_redodt: SUB: 2010-11-07 01:15:35 EDT - P+0Y0M0DT0H3M2S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type3_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redodt_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type2_redost_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type3_redost: SUB: 2010-11-07 01:16:54 EST - P+0Y0M0DT0H2M10S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_redost_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type2_st_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type3_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type3_st: SUB: 2010-11-07 05:19:56 EST - P+0Y0M0DT2H3M1S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_st_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type2_post_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type3_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type3_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_post_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type3-type2.phpt b/ext/date/tests/DateTime_sub-fall-type3-type2.phpt new file mode 100644 index 0000000000000..10a35c4af2c1d --- /dev/null +++ b/ext/date/tests/DateTime_sub-fall-type3-type2.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::sub() -- fall type3 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P+0Y1M2DT16H19M40S = **2010-10-04 02:18:48 EDT** +test_time_fall_type3_prev_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P+0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type2_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_dt_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type2_dt: SUB: 2010-11-07 00:15:35 EDT - P+0Y0M0DT0H5M15S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type2_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_redodt_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type2_redodt: SUB: 2010-11-07 01:15:35 EDT - P+0Y0M0DT0H3M2S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type2_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redost_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type2_redost: SUB: 2010-11-07 01:16:54 EST - P+0Y0M0DT0H2M10S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type2_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_st_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type2_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type2_st: SUB: 2010-11-07 05:19:56 EST - P+0Y0M0DT2H3M1S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_post_type2_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type2_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type2_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type2_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type3-type3.phpt b/ext/date/tests/DateTime_sub-fall-type3-type3.phpt new file mode 100644 index 0000000000000..518d741bc9417 --- /dev/null +++ b/ext/date/tests/DateTime_sub-fall-type3-type3.phpt @@ -0,0 +1,51 @@ +--TEST-- +DateTime::sub() -- fall type3 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_fall_type3_prev_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P+0Y1M2DT16H19M40S = **2010-10-04 02:18:48 EDT** +test_time_fall_type3_prev_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P+0Y0M0DT5H31M52S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT6H34M5S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type3_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT7H36M16S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT9H38M27S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_prev_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M2DT1H21M31S = **2010-11-06 18:38:28 EDT** +test_time_fall_type3_dt_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT5H31M52S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type3_dt: SUB: 2010-11-07 00:15:35 EDT - P+0Y0M0DT0H5M15S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P+0Y0M0DT1H2M13S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type3_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT2H4M24S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT4H6M35S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_dt_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT20H49M39S = **2010-11-07 00:10:20 EDT** +test_time_fall_type3_redodt_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT6H34M5S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT1H2M13S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type3_redodt: SUB: 2010-11-07 01:15:35 EDT - P+0Y0M0DT0H3M2S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type3_redost: SUB: 2010-11-07 01:14:44 EST - P+0Y0M0DT1H2M11S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT3H4M22S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redodt_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT19H47M26S = **2010-11-07 01:12:33 EDT** +test_time_fall_type3_redost_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT7H36M16S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT2H4M24S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT1H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type3_redost: SUB: 2010-11-07 01:16:54 EST - P+0Y0M0DT0H2M10S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type3_st: SUB: 2010-11-07 03:16:55 EST - P+0Y0M0DT2H2M11S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_redost_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** +test_time_fall_type3_st_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M0DT9H38M27S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M0DT4H6M35S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M0DT3H4M22S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type3_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M0DT2H2M11S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type3_st: SUB: 2010-11-07 05:19:56 EST - P+0Y0M0DT2H3M1S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_st_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** +test_time_fall_type3_post_type3_prev: SUB: 2010-11-06 18:38:28 EDT - P-0Y0M2DT1H21M31S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type3_dt: SUB: 2010-11-07 00:10:20 EDT - P-0Y0M1DT20H49M39S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT19H47M26S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type3_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type3_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_post_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** diff --git a/ext/date/tests/DateTime_sub-february.phpt b/ext/date/tests/DateTime_sub-february.phpt new file mode 100644 index 0000000000000..89cba4bded5bb --- /dev/null +++ b/ext/date/tests/DateTime_sub-february.phpt @@ -0,0 +1,77 @@ +--TEST-- +DateTime::sub() -- february +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_bug_49081__1: SUB: 2010-03-31 00:00:00 EDT - P+0Y0M30DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081__2: SUB: 2010-04-01 00:00:00 EDT - P+0Y1M0DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081__3: SUB: 2010-04-01 00:00:00 EDT - P+0Y0M1DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081__4: SUB: 2010-04-29 00:00:00 EDT - P+0Y0M29DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081__5: SUB: 2010-04-30 00:00:00 EDT - P+0Y0M30DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081__6: SUB: 2010-04-30 00:00:00 EDT - P+0Y1M0DT0H0M0S = **2010-03-30 00:00:00 EDT** +test_bug_49081__7: SUB: 2010-04-30 00:00:00 EDT - P+0Y1M1DT0H0M0S = **2010-03-29 00:00:00 EDT** +test_bug_49081__8: SUB: 2010-01-29 00:00:00 EST - P+0Y0M28DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081__9: SUB: 2010-01-30 00:00:00 EST - P+0Y0M29DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081__10: SUB: 2010-01-31 00:00:00 EST - P+0Y0M30DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081__11: SUB: 2010-02-01 00:00:00 EST - P+0Y1M0DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081__12: SUB: 2010-02-01 00:00:00 EST - P+0Y0M1DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__13: SUB: 2010-02-27 00:00:00 EST - P+0Y0M27DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__14: SUB: 2010-02-28 00:00:00 EST - P+0Y0M28DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__15: SUB: 2010-02-28 00:00:00 EST - P+0Y0M29DT0H0M0S = **2010-01-30 00:00:00 EST** +test_bug_49081__16: SUB: 2010-02-28 00:00:00 EST - P+0Y0M30DT0H0M0S = **2010-01-29 00:00:00 EST** +test_bug_49081__17: SUB: 2010-02-28 00:00:00 EST - P+0Y1M0DT0H0M0S = **2010-01-28 00:00:00 EST** +test_bug_49081__18: SUB: 2010-02-28 00:00:00 EST - P+0Y1M1DT0H0M0S = **2010-01-27 00:00:00 EST** +test_bug_49081__19: SUB: 2010-03-01 00:00:00 EST - P+0Y2M0DT0H0M0S = **2010-01-01 00:00:00 EST** +test_bug_49081__20: SUB: 2010-03-01 00:00:00 EST - P+0Y0M29DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__21: SUB: 2010-03-27 00:00:00 EDT - P+0Y1M24DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__22: SUB: 2010-03-28 00:00:00 EDT - P+0Y1M25DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__23: SUB: 2010-03-29 00:00:00 EDT - P+0Y1M26DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__24: SUB: 2010-03-30 00:00:00 EDT - P+0Y1M27DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__25: SUB: 2010-03-31 00:00:00 EDT - P+0Y2M0DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__26: SUB: 2010-03-31 00:00:00 EDT - P+0Y2M1DT0H0M0S = **2010-01-30 00:00:00 EST** +test_bug_49081__27: SUB: 2009-01-31 00:00:00 EST - P+0Y0M30DT0H0M0S = **2009-01-01 00:00:00 EST** +test_bug_49081__28: SUB: 2010-03-27 00:00:00 EDT - P+0Y0M27DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__29: SUB: 2010-03-28 00:00:00 EDT - P+0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__30: SUB: 2010-03-29 00:00:00 EDT - P+0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081__31: SUB: 2010-03-27 00:00:00 EDT - P+0Y1M0DT0H0M0S = **2010-02-27 00:00:00 EST** +test_bug_49081__32: SUB: 2010-03-27 00:00:00 EDT - P+0Y1M1DT0H0M0S = **2010-02-26 00:00:00 EST** +test_bug_49081_negative__1: SUB: 2010-03-01 00:00:00 EST - P-0Y0M30DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__2: SUB: 2010-03-01 00:00:00 EST - P-0Y1M0DT0H0M0S = **2010-04-01 00:00:00 EDT** +test_bug_49081_negative__3: SUB: 2010-03-31 00:00:00 EDT - P-0Y0M1DT0H0M0S = **2010-04-01 00:00:00 EDT** +test_bug_49081_negative__4: SUB: 2010-03-31 00:00:00 EDT - P-0Y0M29DT0H0M0S = **2010-04-29 00:00:00 EDT** +test_bug_49081_negative__5: SUB: 2010-03-31 00:00:00 EDT - P-0Y0M30DT0H0M0S = **2010-04-30 00:00:00 EDT** +test_bug_49081_negative__6: SUB: 2010-03-30 00:00:00 EDT - P-0Y1M0DT0H0M0S = **2010-04-30 00:00:00 EDT** +test_bug_49081_negative__7: SUB: 2010-03-29 00:00:00 EDT - P-0Y1M1DT0H0M0S = **2010-04-30 00:00:00 EDT** +test_bug_49081_negative__8: SUB: 2010-01-01 00:00:00 EST - P-0Y0M28DT0H0M0S = **2010-01-29 00:00:00 EST** +test_bug_49081_negative__9: SUB: 2010-01-01 00:00:00 EST - P-0Y0M29DT0H0M0S = **2010-01-30 00:00:00 EST** +test_bug_49081_negative__10: SUB: 2010-01-01 00:00:00 EST - P-0Y0M30DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081_negative__11: SUB: 2010-01-01 00:00:00 EST - P-0Y1M0DT0H0M0S = **2010-02-01 00:00:00 EST** +test_bug_49081_negative__12: SUB: 2010-01-31 00:00:00 EST - P-0Y0M1DT0H0M0S = **2010-02-01 00:00:00 EST** +test_bug_49081_negative__13: SUB: 2010-01-31 00:00:00 EST - P-0Y0M27DT0H0M0S = **2010-02-27 00:00:00 EST** +test_bug_49081_negative__14: SUB: 2010-01-31 00:00:00 EST - P-0Y0M28DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__15: SUB: 2010-01-30 00:00:00 EST - P-0Y0M29DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__16: SUB: 2010-01-29 00:00:00 EST - P-0Y0M30DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__17: SUB: 2010-01-28 00:00:00 EST - P-0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__18: SUB: 2010-01-27 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** +test_bug_49081_negative__19: SUB: 2010-01-01 00:00:00 EST - P-0Y2M0DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081_negative__20: SUB: 2010-01-31 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-03-01 00:00:00 EST** +test_bug_49081_negative__21: SUB: 2010-01-31 00:00:00 EST - P-0Y1M27DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081_negative__22: SUB: 2010-01-31 00:00:00 EST - P-0Y1M28DT0H0M0S = **2010-03-28 00:00:00 EDT** +test_bug_49081_negative__23: SUB: 2010-01-31 00:00:00 EST - P-0Y1M29DT0H0M0S = **2010-03-29 00:00:00 EDT** +test_bug_49081_negative__24: SUB: 2010-01-31 00:00:00 EST - P-0Y1M30DT0H0M0S = **2010-03-30 00:00:00 EDT** +test_bug_49081_negative__25: SUB: 2010-01-31 00:00:00 EST - P-0Y2M0DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__26: SUB: 2010-01-30 00:00:00 EST - P-0Y2M1DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__27: SUB: 2009-01-01 00:00:00 EST - P-0Y0M30DT0H0M0S = **2009-01-31 00:00:00 EST** +test_bug_49081_negative__28: SUB: 2010-02-28 00:00:00 EST - P-0Y0M27DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081_negative__29: SUB: 2010-02-28 00:00:00 EST - P-0Y1M0DT0H0M0S = **2010-03-28 00:00:00 EDT** +test_bug_49081_negative__30: SUB: 2010-02-28 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-03-29 00:00:00 EDT** +test_bug_49081_negative__31: SUB: 2010-02-27 00:00:00 EST - P-0Y1M0DT0H0M0S = **2010-03-27 00:00:00 EDT** +test_bug_49081_negative__32: SUB: 2010-02-26 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-03-27 00:00:00 EDT** diff --git a/ext/date/tests/DateTime_sub-massive.phpt b/ext/date/tests/DateTime_sub-massive.phpt new file mode 100644 index 0000000000000..a0520ecdd926b --- /dev/null +++ b/ext/date/tests/DateTime_sub-massive.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::sub() -- massive +--CREDITS-- +Daniel Convissor +--FILE-- + +--EXPECT-- +test_massive_positive: SUB: 333333-01-01 16:18:02 EST - P+666666Y0M0DT0H0M0S = **-333333-01-01 16:18:02 EST** +test_massive_negative: SUB: -333333-01-01 16:18:02 EST - P-666666Y0M0DT0H0M0S = **333333-01-01 16:18:02 EST** diff --git a/ext/date/tests/DateTime_sub-spring-type2-type2.phpt b/ext/date/tests/DateTime_sub-spring-type2-type2.phpt new file mode 100644 index 0000000000000..55eb45c024d2d --- /dev/null +++ b/ext/date/tests/DateTime_sub-spring-type2-type2.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::sub() -- spring type2 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type2_prev: SUB: 2010-03-13 18:38:28 EST - P+0Y1M2DT16H19M40S = **2010-02-11 02:18:48 EST** +test_time_spring_type2_prev_type2_st: SUB: 2010-03-14 00:10:20 EST - P+0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_prev_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_prev_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_st_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_st_type2_st: SUB: 2010-03-14 00:15:35 EST - P+0Y0M0DT0H5M15S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_st_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_st_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_dt_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_dt_type2_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_dt_type2_dt: SUB: 2010-03-14 05:19:56 EDT - P+0Y0M0DT2H3M1S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_dt_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_post_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type2_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** diff --git a/ext/date/tests/DateTime_sub-spring-type2-type3.phpt b/ext/date/tests/DateTime_sub-spring-type2-type3.phpt new file mode 100644 index 0000000000000..f41586cc2fb4b --- /dev/null +++ b/ext/date/tests/DateTime_sub-spring-type2-type3.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::sub() -- spring type2 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type2_prev_type3_prev: SUB: 2010-03-13 18:38:28 EST - P+0Y1M2DT16H19M40S = **2010-02-11 02:18:48 EST** +test_time_spring_type2_prev_type3_st: SUB: 2010-03-14 00:10:20 EST - P+0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_prev_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_prev_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type2_st_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_st_type3_st: SUB: 2010-03-14 00:15:35 EST - P+0Y0M0DT0H5M15S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_st_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_st_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type2_dt_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_dt_type3_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_dt_type3_dt: SUB: 2010-03-14 05:19:56 EDT - P+0Y0M0DT2H3M1S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_dt_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type2_post_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type3_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_post_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** diff --git a/ext/date/tests/DateTime_sub-spring-type3-type2.phpt b/ext/date/tests/DateTime_sub-spring-type3-type2.phpt new file mode 100644 index 0000000000000..234940d351359 --- /dev/null +++ b/ext/date/tests/DateTime_sub-spring-type3-type2.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::sub() -- spring type3 type2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type2_prev: SUB: 2010-03-13 18:38:28 EST - P+0Y1M2DT16H19M40S = **2010-02-11 02:18:48 EST** +test_time_spring_type3_prev_type2_st: SUB: 2010-03-14 00:10:20 EST - P+0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_prev_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_prev_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_st_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_st_type2_st: SUB: 2010-03-14 00:15:35 EST - P+0Y0M0DT0H5M15S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_st_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_st_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_dt_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_dt_type2_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_dt_type2_dt: SUB: 2010-03-14 05:19:56 EDT - P+0Y0M0DT2H3M1S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_dt_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_post_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type2_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** diff --git a/ext/date/tests/DateTime_sub-spring-type3-type3.phpt b/ext/date/tests/DateTime_sub-spring-type3-type3.phpt new file mode 100644 index 0000000000000..73d9e27489c91 --- /dev/null +++ b/ext/date/tests/DateTime_sub-spring-type3-type3.phpt @@ -0,0 +1,31 @@ +--TEST-- +DateTime::sub() -- spring type3 type3 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Various bugs exist +--FILE-- + +--EXPECT-- +test_time_spring_type3_prev_type3_prev: SUB: 2010-03-13 18:38:28 EST - P+0Y1M2DT16H19M40S = **2010-02-11 02:18:48 EST** +test_time_spring_type3_prev_type3_st: SUB: 2010-03-14 00:10:20 EST - P+0Y0M0DT5H31M52S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_prev_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT7H38M27S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_prev_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M2DT1H21M31S = **2010-03-13 18:38:28 EST** +test_time_spring_type3_st_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT5H31M52S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_st_type3_st: SUB: 2010-03-14 00:15:35 EST - P+0Y0M0DT0H5M15S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_st_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P+0Y0M0DT2H6M35S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_st_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** +test_time_spring_type3_dt_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M0DT7H38M27S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_dt_type3_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M0DT2H6M35S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_dt_type3_dt: SUB: 2010-03-14 05:19:56 EDT - P+0Y0M0DT2H3M1S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_dt_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** +test_time_spring_type3_post_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT1H21M31S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type3_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_post_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** From cfd54f2e0f9e61bb3a550c21e22ff47499ecc154 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Sun, 19 Jun 2011 16:59:58 +0000 Subject: [PATCH 0195/2394] Provide test for DateTime::add() issue (for discussion on internals, bugs.php.net is down). --- ext/date/tests/bug.add.zone2.phpt | 33 +++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100755 ext/date/tests/bug.add.zone2.phpt diff --git a/ext/date/tests/bug.add.zone2.phpt b/ext/date/tests/bug.add.zone2.phpt new file mode 100755 index 0000000000000..6b59eb434afb5 --- /dev/null +++ b/ext/date/tests/bug.add.zone2.phpt @@ -0,0 +1,33 @@ +--TEST-- +DateTime::add() mistakenly modifies objects having zone type 2 +--CREDITS-- +Daniel Convissor +--XFAIL-- +Bug exists +--FILE-- +format('Y-m-d H:i:s T') . "\n"; +echo 'Zone Type 2: ' . $date2->format('Y-m-d H:i:s T') . "\n"; + +echo $interval->format('Add %h hours %i minutes') . "\n"; +$date3->add($interval); +$date2->add($interval); + +echo 'Zone Type 3: ' . $date3->format('Y-m-d H:i:s T') . "\n"; +echo 'Zone Type 2: ' . $date2->format('Y-m-d H:i:s T') . "\n"; + +?> +--EXPECT-- +Zone Type 3: 2010-10-04 02:18:48 EDT +Zone Type 2: 2010-10-04 02:18:48 EDT +Add 2 hours 1 minutes +Zone Type 3: 2010-10-04 04:19:48 EDT +Zone Type 2: 2010-10-04 04:19:48 EDT From e09ad36f0031a8a135eca3d04aa222897823d541 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 19 Jun 2011 18:52:58 +0000 Subject: [PATCH 0196/2394] fix test with floats - make it not produce different result on 32 and 64 bit --- Zend/tests/declare_001.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/tests/declare_001.phpt b/Zend/tests/declare_001.phpt index d67209ee4dfa8..21d797880e62e 100644 --- a/Zend/tests/declare_001.phpt +++ b/Zend/tests/declare_001.phpt @@ -12,7 +12,7 @@ zend.multibyte=1 Date: Sun, 19 Jun 2011 18:55:48 +0000 Subject: [PATCH 0197/2394] fix error reporting on missing data - don't produce double errors --- ext/date/lib/parse_date.c | 51195 ++++++++++++++++++++++------------- ext/date/lib/parse_date.re | 4 +- 2 files changed, 32859 insertions(+), 18340 deletions(-) diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index 1771b0d9c8de7..a8ab37970e921 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jun 5 15:23:24 2011 */ +/* Generated by re2c 0.13.5 on Sun Jun 19 11:04:50 2011 */ #line 1 "ext/date/lib/parse_date.re" /* +----------------------------------------------------------------------+ @@ -867,49 +867,13 @@ static int scan(Scanner *s) -#line 871 "ext/date/lib/parse_date.c" +#line 871 "" { YYCTYPE yych; unsigned int yyaccept = 0; - static const unsigned char yybm[] = { - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 100, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 100, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 128, 64, 160, 96, 0, - 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 0, 0, 0, 0, 0, 0, - 0, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 0, 0, 0, 0, 0, - 0, 24, 24, 24, 88, 24, 24, 24, - 88, 24, 24, 24, 24, 24, 88, 24, - 24, 24, 88, 88, 88, 24, 24, 24, - 24, 24, 24, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - }; - YYDEBUG(0, *YYCURSOR); if ((YYLIMIT - YYCURSOR) < 31) YYFILL(31); yych = *YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case 0x00: case '\n': goto yy52; @@ -986,7 +950,6 @@ static int scan(Scanner *s) default: goto yy54; } yy2: - YYDEBUG(2, *YYCURSOR); #line 1074 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("firstdayof | lastdayof"); @@ -1003,29 +966,66 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_LF_DAY_OF_MONTH; } -#line 1007 "ext/date/lib/parse_date.c" +#line 970 "" yy3: - YYDEBUG(3, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= 'E') { - if (yych <= ')') { - if (yych >= ')') goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy1523; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych >= 'a') goto yy146; - } else { - if (yych <= 'e') goto yy1532; - if (yych <= 'z') goto yy146; - } + switch ((yych = *YYCURSOR)) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'E': goto yy1523; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'e': goto yy1532; + default: goto yy4; } yy4: - YYDEBUG(4, *YYCURSOR); #line 1656 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -1039,190 +1039,76 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIMEZONE; } -#line 1043 "ext/date/lib/parse_date.c" +#line 1043 "" yy5: - YYDEBUG(5, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy1523; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy141; - } else { - if (yych <= 'e') goto yy1523; - if (yych <= 'z') goto yy141; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'E': + case 'e': goto yy1523; + default: goto yy4; } yy6: - YYDEBUG(6, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= 'D') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'H') { - if (yych <= 'E') goto yy1494; - goto yy141; - } else { - if (yych <= 'I') goto yy1495; - if (yych <= 'N') goto yy141; - goto yy1493; - } - } - } else { - if (yych <= 'h') { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych == 'e') goto yy1510; - goto yy146; - } - } else { - if (yych <= 'n') { - if (yych <= 'i') goto yy1511; - goto yy146; - } else { - if (yych <= 'o') goto yy1509; - if (yych <= 'z') goto yy146; - goto yy4; - } - } - } -yy7: - YYDEBUG(7, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= 'D') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'H') { - if (yych <= 'E') goto yy1494; - goto yy141; - } else { - if (yych <= 'I') goto yy1495; - if (yych <= 'N') goto yy141; - goto yy1493; - } - } - } else { - if (yych <= 'h') { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych == 'e') goto yy1494; - goto yy141; - } - } else { - if (yych <= 'n') { - if (yych <= 'i') goto yy1495; - goto yy141; - } else { - if (yych <= 'o') goto yy1493; - if (yych <= 'z') goto yy141; - goto yy4; - } - } - } -yy8: - YYDEBUG(8, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1463; - } else { - if (yych == 'I') goto yy1464; - if (yych <= 'N') goto yy141; - goto yy1465; - } - } else { - if (yych <= 'h') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1478; - goto yy146; - } else { - if (yych <= 'n') { - if (yych <= 'i') goto yy1479; - goto yy146; - } else { - if (yych <= 'o') goto yy1480; - if (yych <= 'z') goto yy146; - goto yy4; - } - } - } -yy9: - YYDEBUG(9, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1463; - } else { - if (yych == 'I') goto yy1464; - if (yych <= 'N') goto yy141; - goto yy1465; - } - } else { - if (yych <= 'h') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1463; - goto yy141; - } else { - if (yych <= 'n') { - if (yych <= 'i') goto yy1464; - goto yy141; - } else { - if (yych <= 'o') goto yy1465; - if (yych <= 'z') goto yy141; - goto yy4; - } - } - } -yy10: - YYDEBUG(10, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case ')': goto yy140; - case '0': - case '1': goto yy1393; - case '2': goto yy1394; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1395; case 'A': case 'B': case 'C': case 'D': case 'F': case 'G': - case 'I': + case 'H': case 'J': case 'K': case 'L': @@ -1233,22 +1119,22 @@ static int scan(Scanner *s) case 'R': case 'S': case 'T': + case 'U': case 'V': + case 'W': case 'X': case 'Y': case 'Z': goto yy141; - case 'E': goto yy1388; - case 'H': goto yy1389; - case 'O': goto yy1390; - case 'U': goto yy1391; - case 'W': goto yy1392; + case 'E': goto yy1494; + case 'I': goto yy1495; + case 'O': goto yy1493; case 'a': case 'b': case 'c': case 'd': case 'f': case 'g': - case 'i': + case 'h': case 'j': case 'k': case 'l': @@ -1259,41 +1145,28 @@ static int scan(Scanner *s) case 'r': case 's': case 't': + case 'u': case 'v': + case 'w': case 'x': case 'y': case 'z': goto yy146; - case 'e': goto yy1431; - case 'h': goto yy1432; - case 'o': goto yy1433; - case 'u': goto yy1434; - case 'w': goto yy1435; + case 'e': goto yy1510; + case 'i': goto yy1511; + case 'o': goto yy1509; default: goto yy4; } -yy11: - YYDEBUG(11, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); +yy7: + yych = *++YYCURSOR; switch (yych) { case ')': goto yy140; - case '0': - case '1': goto yy1393; - case '2': goto yy1394; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1395; case 'A': case 'B': case 'C': case 'D': case 'F': case 'G': - case 'I': + case 'H': case 'J': case 'K': case 'L': @@ -1304,7 +1177,9 @@ static int scan(Scanner *s) case 'R': case 'S': case 'T': + case 'U': case 'V': + case 'W': case 'X': case 'Y': case 'Z': @@ -1314,7 +1189,7 @@ static int scan(Scanner *s) case 'd': case 'f': case 'g': - case 'i': + case 'h': case 'j': case 'k': case 'l': @@ -1325,576 +1200,281 @@ static int scan(Scanner *s) case 'r': case 's': case 't': + case 'u': case 'v': + case 'w': case 'x': case 'y': case 'z': goto yy141; case 'E': - case 'e': goto yy1388; - case 'H': - case 'h': goto yy1389; + case 'e': goto yy1494; + case 'I': + case 'i': goto yy1495; case 'O': - case 'o': goto yy1390; - case 'U': - case 'u': goto yy1391; - case 'W': - case 'w': goto yy1392; + case 'o': goto yy1493; default: goto yy4; } -yy12: - YYDEBUG(12, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - if (yych == '-') goto yy1384; - if (yych <= '/') goto yy13; - if (yych <= '9') goto yy1385; -yy13: - YYDEBUG(13, *YYCURSOR); -#line 1751 "ext/date/lib/parse_date.re" - { - add_error(s, "Unexpected character"); - goto std; - } -#line 1359 "ext/date/lib/parse_date.c" -yy14: - YYDEBUG(14, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy1320; - } - } else { - if (yych <= 'N') { - if (yych == 'I') goto yy1321; - goto yy141; - } else { - if (yych <= 'O') goto yy1322; - if (yych <= 'Q') goto yy141; - goto yy1323; - } - } - } else { - if (yych <= 'i') { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy146; - } else { - if (yych <= 'e') goto yy1361; - if (yych <= 'h') goto yy146; - goto yy1362; - } - } else { - if (yych <= 'q') { - if (yych == 'o') goto yy1363; - goto yy146; - } else { - if (yych <= 'r') goto yy1364; - if (yych <= 'z') goto yy146; - goto yy4; - } - } - } -yy15: - YYDEBUG(15, *YYCURSOR); +yy8: yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy1320; - } - } else { - if (yych <= 'N') { - if (yych == 'I') goto yy1321; - goto yy141; - } else { - if (yych <= 'O') goto yy1322; - if (yych <= 'Q') goto yy141; - goto yy1323; - } - } - } else { - if (yych <= 'i') { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy141; - } else { - if (yych <= 'e') goto yy1320; - if (yych <= 'h') goto yy141; - goto yy1321; - } - } else { - if (yych <= 'q') { - if (yych == 'o') goto yy1322; - goto yy141; - } else { - if (yych <= 'r') goto yy1323; - if (yych <= 'z') goto yy141; - goto yy4; - } - } - } -yy16: - YYDEBUG(16, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1307; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych <= 'a') goto yy1317; - if (yych <= 'z') goto yy146; - goto yy4; - } - } -yy17: - YYDEBUG(17, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1307; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych <= 'a') goto yy1307; - if (yych <= 'z') goto yy141; - goto yy4; - } - } -yy18: - YYDEBUG(18, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1287; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych <= 'a') goto yy1304; - if (yych <= 'z') goto yy146; - goto yy4; - } - } -yy19: - YYDEBUG(19, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1287; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych <= 'a') goto yy1287; - if (yych <= 'z') goto yy141; - goto yy4; - } - } -yy20: - YYDEBUG(20, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'A') goto yy1230; - goto yy141; - } - } else { - if (yych <= 'H') { - if (yych <= 'E') goto yy1229; - goto yy141; - } else { - if (yych <= 'I') goto yy1231; - if (yych <= 'T') goto yy141; - goto yy1232; - } - } - } else { - if (yych <= 'e') { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych <= 'a') goto yy1259; - if (yych <= 'd') goto yy146; - goto yy1258; - } - } else { - if (yych <= 't') { - if (yych == 'i') goto yy1260; - goto yy146; - } else { - if (yych <= 'u') goto yy1261; - if (yych <= 'z') goto yy146; - goto yy4; - } - } - } -yy21: - YYDEBUG(21, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'A') goto yy1230; - goto yy141; - } - } else { - if (yych <= 'H') { - if (yych <= 'E') goto yy1229; - goto yy141; - } else { - if (yych <= 'I') goto yy1231; - if (yych <= 'T') goto yy141; - goto yy1232; - } - } - } else { - if (yych <= 'e') { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych <= 'a') goto yy1230; - if (yych <= 'd') goto yy141; - goto yy1229; - } - } else { - if (yych <= 't') { - if (yych == 'i') goto yy1231; - goto yy141; - } else { - if (yych <= 'u') goto yy1232; - if (yych <= 'z') goto yy141; - goto yy4; - } - } - } -yy22: - YYDEBUG(22, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'I') goto yy1199; - if (yych <= 'K') goto yy141; - goto yy1200; - } - } else { - if (yych <= 'i') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'h') goto yy146; - goto yy1217; - } else { - if (yych == 'l') goto yy1218; - if (yych <= 'z') goto yy146; - goto yy4; - } - } -yy23: - YYDEBUG(23, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'I') goto yy1199; - if (yych <= 'K') goto yy141; - goto yy1200; - } - } else { - if (yych <= 'i') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'h') goto yy141; - goto yy1199; - } else { - if (yych == 'l') goto yy1200; - if (yych <= 'z') goto yy141; - goto yy4; - } - } -yy24: - YYDEBUG(24, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy141; - goto yy1098; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy146; - } else { - if (yych <= 'r') goto yy1192; - if (yych <= 'z') goto yy146; - goto yy4; - } - } -yy25: - YYDEBUG(25, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy141; - goto yy1098; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy141; - } else { - if (yych <= 'r') goto yy1098; - if (yych <= 'z') goto yy141; - goto yy4; - } - } -yy26: - YYDEBUG(26, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { - case '\t': goto yy1052; - case ' ': - case 'A': + case ')': goto yy140; + case 'A': goto yy1463; + case 'B': + case 'C': case 'D': + case 'E': case 'F': + case 'G': case 'H': - case 'I': case 'J': + case 'K': + case 'L': case 'M': case 'N': - case 'O': + case 'P': + case 'Q': + case 'R': case 'S': case 'T': + case 'U': case 'V': case 'W': case 'X': case 'Y': - case 'a': + case 'Z': goto yy141; + case 'I': goto yy1464; + case 'O': goto yy1465; + case 'a': goto yy1478; + case 'b': + case 'c': case 'd': + case 'e': case 'f': + case 'g': case 'h': case 'j': + case 'k': + case 'l': case 'm': - case 'o': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': case 'w': - case 'y': goto yy1054; - case '-': goto yy473; - case '.': goto yy1064; - case '/': goto yy472; - case '0': goto yy1097; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1096; - case ':': goto yy1065; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; + case 'x': + case 'y': + case 'z': goto yy146; + case 'i': goto yy1479; + case 'o': goto yy1480; + default: goto yy4; } -yy27: - YYDEBUG(27, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); +yy9: + yych = *++YYCURSOR; switch (yych) { - case '\t': goto yy460; - case ' ': + case ')': goto yy140; case 'A': + case 'a': goto yy1463; + case 'B': + case 'C': case 'D': + case 'E': case 'F': + case 'G': case 'H': - case 'I': case 'J': + case 'K': + case 'L': case 'M': case 'N': - case 'O': case 'P': + case 'Q': + case 'R': case 'S': case 'T': + case 'U': case 'V': case 'W': case 'X': case 'Y': - case 'a': + case 'Z': + case 'b': + case 'c': case 'd': + case 'e': case 'f': + case 'g': case 'h': case 'j': + case 'k': + case 'l': case 'm': - case 'o': + case 'n': case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; + case 'x': + case 'y': + case 'z': goto yy141; + case 'I': + case 'i': goto yy1464; + case 'O': + case 'o': goto yy1465; + default: goto yy4; + } +yy10: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy140; case '0': - case '1': - case '2': goto yy1096; + case '1': goto yy1393; + case '2': goto yy1394; case '3': case '4': case '5': case '6': case '7': case '8': - case '9': goto yy1063; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; - } -yy28: - YYDEBUG(28, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); - switch (yych) { - case '\t': goto yy460; - case ' ': + case '9': goto yy1395; case 'A': + case 'B': + case 'C': case 'D': case 'F': - case 'H': + case 'G': case 'I': case 'J': + case 'K': + case 'L': case 'M': case 'N': - case 'O': case 'P': + case 'Q': + case 'R': case 'S': case 'T': case 'V': - case 'W': case 'X': case 'Y': + case 'Z': goto yy141; + case 'E': goto yy1388; + case 'H': goto yy1389; + case 'O': goto yy1390; + case 'U': goto yy1391; + case 'W': goto yy1392; case 'a': + case 'b': + case 'c': case 'd': case 'f': - case 'h': + case 'g': + case 'i': case 'j': + case 'k': + case 'l': case 'm': - case 'o': + case 'n': case 'p': - case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'x': + case 'y': + case 'z': goto yy146; + case 'e': goto yy1431; + case 'h': goto yy1432; + case 'o': goto yy1433; + case 'u': goto yy1434; + case 'w': goto yy1435; + default: goto yy4; + } +yy11: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy140; case '0': - case '1': - case '2': + case '1': goto yy1393; + case '2': goto yy1394; case '3': - case '4': goto yy1063; + case '4': case '5': case '6': case '7': case '8': - case '9': goto yy1050; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; - } -yy29: - YYDEBUG(29, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); - switch (yych) { - case '\t': goto yy460; - case ' ': + case '9': goto yy1395; case 'A': + case 'B': + case 'C': case 'D': case 'F': - case 'H': + case 'G': case 'I': case 'J': + case 'K': + case 'L': case 'M': case 'N': - case 'O': case 'P': + case 'Q': + case 'R': case 'S': case 'T': case 'V': - case 'W': case 'X': case 'Y': + case 'Z': case 'a': + case 'b': + case 'c': case 'd': case 'f': - case 'h': + case 'g': + case 'i': case 'j': + case 'k': + case 'l': case 'm': - case 'o': + case 'n': case 'p': - case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'x': + case 'y': + case 'z': goto yy141; + case 'E': + case 'e': goto yy1388; + case 'H': + case 'h': goto yy1389; + case 'O': + case 'o': goto yy1390; + case 'U': + case 'u': goto yy1391; + case 'W': + case 'w': goto yy1392; + default: goto yy4; + } +yy12: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '-': goto yy1384; case '0': - case '1': goto yy1050; + case '1': case '2': case '3': case '4': @@ -1902,921 +1482,2265 @@ static int scan(Scanner *s) case '6': case '7': case '8': - case '9': goto yy469; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; + case '9': goto yy1385; default: goto yy13; } -yy30: - YYDEBUG(30, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); +yy13: +#line 1751 "ext/date/lib/parse_date.re" + { + add_error(s, "Unexpected character"); + goto std; + } +#line 1495 "" +yy14: + yych = *++YYCURSOR; switch (yych) { - case '\t': goto yy460; - case ' ': + case ')': goto yy140; case 'A': + case 'B': + case 'C': case 'D': case 'F': + case 'G': case 'H': - case 'I': case 'J': + case 'K': + case 'L': case 'M': case 'N': - case 'O': case 'P': + case 'Q': case 'S': case 'T': + case 'U': case 'V': case 'W': case 'X': case 'Y': + case 'Z': goto yy141; + case 'E': goto yy1320; + case 'I': goto yy1321; + case 'O': goto yy1322; + case 'R': goto yy1323; case 'a': + case 'b': + case 'c': case 'd': case 'f': + case 'g': case 'h': case 'j': + case 'k': + case 'l': case 'm': - case 'o': + case 'n': case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy469; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; - } -yy31: - YYDEBUG(31, *YYCURSOR); - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 4) { - goto yy58; + case 'x': + case 'y': + case 'z': goto yy146; + case 'e': goto yy1361; + case 'i': goto yy1362; + case 'o': goto yy1363; + case 'r': goto yy1364; + default: goto yy4; } - YYDEBUG(-1, yych); +yy15: + yych = *++YYCURSOR; switch (yych) { - case '+': - case '-': goto yy440; - case '0': - case '1': goto yy437; - case '2': goto yy438; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy439; - default: goto yy13; - } -yy32: - YYDEBUG(32, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy4; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy4; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy4; - } else { - if (yych == '/') goto yy4; - goto yy196; - } - } - } else { - if (yych <= 'V') { - if (yych <= 'H') { - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'I') goto yy436; - if (yych <= 'U') goto yy141; - goto yy435; - } - } else { - if (yych <= 'Z') { - if (yych == 'X') goto yy435; - goto yy141; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy146; - goto yy4; - } - } - } -yy33: - YYDEBUG(33, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy4; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy196; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'Z') { - if (yych <= 'I') goto yy432; - goto yy141; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy146; - goto yy4; - } - } + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'E': + case 'e': goto yy1320; + case 'I': + case 'i': goto yy1321; + case 'O': + case 'o': goto yy1322; + case 'R': + case 'r': goto yy1323; + default: goto yy4; } -yy34: - YYDEBUG(34, *YYCURSOR); +yy16: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': goto yy1307; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'a': goto yy1317; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; + } +yy17: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1307; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + default: goto yy4; + } +yy18: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': goto yy1287; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'a': goto yy1304; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; + } +yy19: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1287; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + default: goto yy4; + } +yy20: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': goto yy1230; + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'E': goto yy1229; + case 'I': goto yy1231; + case 'U': goto yy1232; + case 'a': goto yy1259; + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'e': goto yy1258; + case 'i': goto yy1260; + case 'u': goto yy1261; + default: goto yy4; + } +yy21: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1230; + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'E': + case 'e': goto yy1229; + case 'I': + case 'i': goto yy1231; + case 'U': + case 'u': goto yy1232; + default: goto yy4; + } +yy22: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'I': goto yy1199; + case 'L': goto yy1200; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'i': goto yy1217; + case 'l': goto yy1218; + default: goto yy4; + } +yy23: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'I': + case 'i': goto yy1199; + case 'L': + case 'l': goto yy1200; + default: goto yy4; + } +yy24: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'R': goto yy1098; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'r': goto yy1192; + default: goto yy4; + } +yy25: + yych = *++YYCURSOR; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'R': + case 'r': goto yy1098; + default: goto yy4; + } +yy26: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': goto yy1052; + case ' ': + case 'A': + case 'D': + case 'F': + case 'H': + case 'I': + case 'J': + case 'M': + case 'N': + case 'O': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'a': + case 'd': + case 'f': + case 'h': + case 'j': + case 'm': + case 'o': + case 'w': + case 'y': goto yy1054; + case '-': goto yy473; + case '.': goto yy1064; + case '/': goto yy472; + case '0': goto yy1097; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1096; + case ':': goto yy1065; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy27: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': goto yy460; + case ' ': + case 'A': + case 'D': + case 'F': + case 'H': + case 'I': + case 'J': + case 'M': + case 'N': + case 'O': + case 'P': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'a': + case 'd': + case 'f': + case 'h': + case 'j': + case 'm': + case 'o': + case 'p': + case 'w': + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; + case '0': + case '1': + case '2': goto yy1096; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1063; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy28: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': goto yy460; + case ' ': + case 'A': + case 'D': + case 'F': + case 'H': + case 'I': + case 'J': + case 'M': + case 'N': + case 'O': + case 'P': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'a': + case 'd': + case 'f': + case 'h': + case 'j': + case 'm': + case 'o': + case 'p': + case 'w': + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy1063; + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1050; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy29: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': goto yy460; + case ' ': + case 'A': + case 'D': + case 'F': + case 'H': + case 'I': + case 'J': + case 'M': + case 'N': + case 'O': + case 'P': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'a': + case 'd': + case 'f': + case 'h': + case 'j': + case 'm': + case 'o': + case 'p': + case 'w': + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; + case '0': + case '1': goto yy1050; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy469; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy30: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': goto yy460; + case ' ': + case 'A': + case 'D': + case 'F': + case 'H': + case 'I': + case 'J': + case 'M': + case 'N': + case 'O': + case 'P': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'a': + case 'd': + case 'f': + case 'h': + case 'j': + case 'm': + case 'o': + case 'p': + case 'w': + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy469; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy31: + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': goto yy58; + case '+': + case '-': goto yy440; + case '0': + case '1': goto yy437; + case '2': goto yy438; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy439; + default: goto yy13; + } +yy32: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy4; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy196; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'Z') { - if (yych <= 'I') goto yy430; - goto yy141; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy146; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'Y': + case 'Z': goto yy141; + case 'I': goto yy436; + case 'V': + case 'X': goto yy435; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; + } +yy33: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'I': goto yy432; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; + } +yy34: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'I': goto yy430; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; } yy35: - YYDEBUG(35, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'A') goto yy413; - if (yych <= 'T') goto yy141; - goto yy412; - } - } else { - if (yych <= 'a') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy422; - } else { - if (yych == 'u') goto yy421; - if (yych <= 'z') goto yy146; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': goto yy413; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'U': goto yy412; + case 'a': goto yy422; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'u': goto yy421; + default: goto yy4; } yy36: - YYDEBUG(36, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'A') goto yy413; - if (yych <= 'T') goto yy141; - goto yy412; - } - } else { - if (yych <= 'a') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy413; - } else { - if (yych == 'u') goto yy412; - if (yych <= 'z') goto yy141; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy413; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'U': + case 'u': goto yy412; + default: goto yy4; } yy37: - YYDEBUG(37, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'F') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'O') { - if (yych <= 'G') goto yy391; - goto yy141; - } else { - if (yych <= 'P') goto yy390; - if (yych <= 'T') goto yy141; - goto yy389; - } - } - } else { - if (yych <= 'o') { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych == 'g') goto yy403; - goto yy146; - } - } else { - if (yych <= 't') { - if (yych <= 'p') goto yy402; - goto yy146; - } else { - if (yych <= 'u') goto yy401; - if (yych <= 'z') goto yy146; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'G': goto yy391; + case 'P': goto yy390; + case 'U': goto yy389; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'g': goto yy403; + case 'p': goto yy402; + case 'u': goto yy401; + default: goto yy4; } yy38: - YYDEBUG(38, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'F') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'O') { - if (yych <= 'G') goto yy391; - goto yy141; - } else { - if (yych <= 'P') goto yy390; - if (yych <= 'T') goto yy141; - goto yy389; - } - } - } else { - if (yych <= 'o') { - if (yych <= '`') { - if (yych <= 'Z') goto yy141; - goto yy4; - } else { - if (yych == 'g') goto yy391; - goto yy141; - } - } else { - if (yych <= 't') { - if (yych <= 'p') goto yy390; - goto yy141; - } else { - if (yych <= 'u') goto yy389; - if (yych <= 'z') goto yy141; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'G': + case 'g': goto yy391; + case 'P': + case 'p': goto yy390; + case 'U': + case 'u': goto yy389; + default: goto yy4; } yy39: - YYDEBUG(39, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'C') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'B') goto yy141; - goto yy379; - } - } else { - if (yych <= 'b') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy146; - } else { - if (yych <= 'c') goto yy384; - if (yych <= 'z') goto yy146; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'C': goto yy379; + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'c': goto yy384; + default: goto yy4; } yy40: - YYDEBUG(40, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'C') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'B') goto yy141; - goto yy379; - } - } else { - if (yych <= 'b') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy141; - } else { - if (yych <= 'c') goto yy379; - if (yych <= 'z') goto yy141; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'C': + case 'c': goto yy379; + default: goto yy4; } yy41: - YYDEBUG(41, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy192; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy146; - } else { - if (yych <= 'e') goto yy370; - if (yych <= 'z') goto yy146; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'E': goto yy192; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'e': goto yy370; + default: goto yy4; } yy42: - YYDEBUG(42, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy192; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy141; - } else { - if (yych <= 'e') goto yy192; - if (yych <= 'z') goto yy141; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'E': + case 'e': goto yy192; + default: goto yy4; } yy43: - YYDEBUG(43, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy165; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy146; - } else { - if (yych <= 'e') goto yy179; - if (yych <= 'z') goto yy146; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'E': goto yy165; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + case 'e': goto yy179; + default: goto yy4; } yy44: - YYDEBUG(44, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy141; - goto yy165; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - goto yy141; - } else { - if (yych <= 'e') goto yy165; - if (yych <= 'z') goto yy141; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + case 'E': + case 'e': goto yy165; + default: goto yy4; } yy45: - YYDEBUG(45, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy141; - } else { - if (yych <= 'Z') { - if (yych <= 'M') goto yy157; - goto yy141; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy146; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'M': goto yy157; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; } yy46: - YYDEBUG(46, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') goto yy13; - if (yych <= 'Z') goto yy156; - if (yych <= '`') goto yy13; - if (yych <= 'z') goto yy156; - goto yy13; + switch (yych) { + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy156; + default: goto yy13; + } yy47: - YYDEBUG(47, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy146; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy141; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy146; + default: goto yy4; } yy48: - YYDEBUG(48, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy141; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + default: goto yy4; } yy49: - YYDEBUG(49, *YYCURSOR); yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 4) { - goto yy58; + switch (yych) { + case '\t': + case ' ': goto yy58; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy50; } - if (yych <= '/') goto yy50; - if (yych <= '9') goto yy55; yy50: - YYDEBUG(50, *YYCURSOR); #line 1740 "ext/date/lib/parse_date.re" { goto std; } -#line 2420 "ext/date/lib/parse_date.c" +#line 3523 "" yy51: - YYDEBUG(51, *YYCURSOR); yych = *++YYCURSOR; goto yy50; yy52: - YYDEBUG(52, *YYCURSOR); ++YYCURSOR; - YYDEBUG(53, *YYCURSOR); #line 1745 "ext/date/lib/parse_date.re" { s->pos = cursor; s->line++; goto std; } -#line 2434 "ext/date/lib/parse_date.c" +#line 3534 "" yy54: - YYDEBUG(54, *YYCURSOR); yych = *++YYCURSOR; goto yy13; yy55: - YYDEBUG(55, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); yych = *YYCURSOR; - YYDEBUG(56, *YYCURSOR); - if (yybm[0+yych] & 2) { - goto yy55; - } - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy60; - if (yych >= ' ') goto yy60; - } else { - if (yych == 'D') goto yy65; - if (yych >= 'F') goto yy66; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy64; - if (yych >= 'M') goto yy63; - } else { - if (yych <= 'S') { - if (yych >= 'S') goto yy62; - } else { - if (yych <= 'T') goto yy69; - if (yych >= 'W') goto yy68; - } - } - } - } else { - if (yych <= 'l') { - if (yych <= 'd') { - if (yych == 'Y') goto yy67; - if (yych >= 'd') goto yy65; - } else { - if (yych <= 'f') { - if (yych >= 'f') goto yy66; - } else { - if (yych == 'h') goto yy64; - } - } - } else { - if (yych <= 't') { - if (yych <= 'm') goto yy63; - if (yych <= 'r') goto yy57; - if (yych <= 's') goto yy62; - goto yy69; - } else { - if (yych <= 'w') { - if (yych >= 'w') goto yy68; - } else { - if (yych == 'y') goto yy67; - } - } - } + switch (yych) { + case '\t': + case ' ': goto yy60; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + case 'D': + case 'd': goto yy65; + case 'F': + case 'f': goto yy66; + case 'H': + case 'h': goto yy64; + case 'M': + case 'm': goto yy63; + case 'S': + case 's': goto yy62; + case 'T': + case 't': goto yy69; + case 'W': + case 'w': goto yy68; + case 'Y': + case 'y': goto yy67; + default: goto yy57; } yy57: - YYDEBUG(57, *YYCURSOR); YYCURSOR = YYMARKER; - if (yyaccept <= 16) { - if (yyaccept <= 8) { - if (yyaccept <= 4) { - if (yyaccept <= 2) { - if (yyaccept <= 1) { - if (yyaccept <= 0) { - goto yy4; - } else { - goto yy13; - } - } else { - goto yy50; - } - } else { - if (yyaccept <= 3) { - goto yy73; - } else { - goto yy167; - } - } - } else { - if (yyaccept <= 6) { - if (yyaccept <= 5) { - goto yy194; - } else { - goto yy199; - } - } else { - if (yyaccept <= 7) { - goto yy223; - } else { - goto yy295; - } - } - } - } else { - if (yyaccept <= 12) { - if (yyaccept <= 10) { - if (yyaccept <= 9) { - goto yy393; - } else { - goto yy476; - } - } else { - if (yyaccept <= 11) { - goto yy491; - } else { - goto yy612; - } - } - } else { - if (yyaccept <= 14) { - if (yyaccept <= 13) { - goto yy657; - } else { - goto yy667; - } - } else { - if (yyaccept <= 15) { - goto yy764; - } else { - goto yy784; - } - } - } - } - } else { - if (yyaccept <= 25) { - if (yyaccept <= 21) { - if (yyaccept <= 19) { - if (yyaccept <= 18) { - if (yyaccept <= 17) { - goto yy815; - } else { - goto yy822; - } - } else { - goto yy849; - } - } else { - if (yyaccept <= 20) { - goto yy794; - } else { - goto yy455; - } - } - } else { - if (yyaccept <= 23) { - if (yyaccept <= 22) { - goto yy974; - } else { - goto yy843; - } - } else { - if (yyaccept <= 24) { - goto yy1068; - } else { - goto yy1076; - } - } - } - } else { - if (yyaccept <= 29) { - if (yyaccept <= 27) { - if (yyaccept <= 26) { - goto yy1118; - } else { - goto yy1142; - } - } else { - if (yyaccept <= 28) { - goto yy1295; - } else { - goto yy1417; - } - } - } else { - if (yyaccept <= 31) { - if (yyaccept <= 30) { - goto yy1420; - } else { - goto yy1500; - } - } else { - if (yyaccept <= 32) { - goto yy1508; - } else { - goto yy1531; - } - } - } - } + switch (yyaccept) { + case 0: goto yy4; + case 1: goto yy13; + case 2: goto yy50; + case 3: goto yy73; + case 4: goto yy167; + case 5: goto yy194; + case 6: goto yy199; + case 7: goto yy223; + case 8: goto yy295; + case 9: goto yy393; + case 10: goto yy476; + case 11: goto yy491; + case 12: goto yy612; + case 13: goto yy657; + case 14: goto yy667; + case 15: goto yy764; + case 16: goto yy784; + case 17: goto yy815; + case 18: goto yy822; + case 19: goto yy849; + case 20: goto yy794; + case 21: goto yy455; + case 22: goto yy974; + case 23: goto yy843; + case 24: goto yy1068; + case 25: goto yy1076; + case 26: goto yy1118; + case 27: goto yy1142; + case 28: goto yy1295; + case 29: goto yy1417; + case 30: goto yy1420; + case 31: goto yy1500; + case 32: goto yy1508; + case 33: goto yy1531; } yy58: - YYDEBUG(58, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(59, *YYCURSOR); - if (yybm[0+yych] & 4) { - goto yy58; + switch (yych) { + case '\t': + case ' ': goto yy58; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy57; } - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy55; - goto yy57; yy60: - YYDEBUG(60, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); yych = *YYCURSOR; yy61: - YYDEBUG(61, *YYCURSOR); - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy60; - if (yych <= 0x1F) goto yy57; - goto yy60; - } else { - if (yych == 'D') goto yy65; - if (yych <= 'E') goto yy57; - goto yy66; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy64; - if (yych <= 'L') goto yy57; - goto yy63; - } else { - if (yych <= 'S') { - if (yych <= 'R') goto yy57; - } else { - if (yych <= 'T') goto yy69; - if (yych <= 'V') goto yy57; - goto yy68; - } - } - } - } else { - if (yych <= 'l') { - if (yych <= 'd') { - if (yych == 'Y') goto yy67; - if (yych <= 'c') goto yy57; - goto yy65; - } else { - if (yych <= 'f') { - if (yych <= 'e') goto yy57; - goto yy66; - } else { - if (yych == 'h') goto yy64; - goto yy57; - } - } - } else { - if (yych <= 't') { - if (yych <= 'm') goto yy63; - if (yych <= 'r') goto yy57; - if (yych >= 't') goto yy69; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy57; - goto yy68; - } else { - if (yych == 'y') goto yy67; - goto yy57; - } - } - } + switch (yych) { + case '\t': + case ' ': goto yy60; + case 'D': + case 'd': goto yy65; + case 'F': + case 'f': goto yy66; + case 'H': + case 'h': goto yy64; + case 'M': + case 'm': goto yy63; + case 'S': + case 's': goto yy62; + case 'T': + case 't': goto yy69; + case 'W': + case 'w': goto yy68; + case 'Y': + case 'y': goto yy67; + default: goto yy57; } yy62: - YYDEBUG(62, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'D') { - if (yych == 'A') goto yy127; - goto yy57; - } else { - if (yych <= 'E') goto yy128; - if (yych <= 'T') goto yy57; - goto yy126; - } - } else { - if (yych <= 'd') { - if (yych == 'a') goto yy127; - goto yy57; - } else { - if (yych <= 'e') goto yy128; - if (yych == 'u') goto yy126; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy127; + case 'E': + case 'e': goto yy128; + case 'U': + case 'u': goto yy126; + default: goto yy57; } yy63: - YYDEBUG(63, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych == 'I') goto yy118; - if (yych <= 'N') goto yy57; - goto yy117; - } else { - if (yych <= 'i') { - if (yych <= 'h') goto yy57; - goto yy118; - } else { - if (yych == 'o') goto yy117; - goto yy57; - } + switch (yych) { + case 'I': + case 'i': goto yy118; + case 'O': + case 'o': goto yy117; + default: goto yy57; } yy64: - YYDEBUG(64, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy115; - if (yych == 'o') goto yy115; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy115; + default: goto yy57; + } yy65: - YYDEBUG(65, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy114; - if (yych == 'a') goto yy114; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy114; + default: goto yy57; + } yy66: - YYDEBUG(66, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych == 'O') goto yy99; - if (yych <= 'Q') goto yy57; - goto yy98; - } else { - if (yych <= 'o') { - if (yych <= 'n') goto yy57; - goto yy99; - } else { - if (yych == 'r') goto yy98; - goto yy57; - } + switch (yych) { + case 'O': + case 'o': goto yy99; + case 'R': + case 'r': goto yy98; + default: goto yy57; } yy67: - YYDEBUG(67, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy95; - if (yych == 'e') goto yy95; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy95; + default: goto yy57; + } yy68: - YYDEBUG(68, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy83; - if (yych == 'e') goto yy83; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy83; + default: goto yy57; + } yy69: - YYDEBUG(69, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'H') goto yy70; - if (yych <= 'T') goto yy57; - goto yy71; - } else { - if (yych <= 'h') { - if (yych <= 'g') goto yy57; - } else { - if (yych == 'u') goto yy71; - goto yy57; - } + switch (yych) { + case 'H': + case 'h': goto yy70; + case 'U': + case 'u': goto yy71; + default: goto yy57; } yy70: - YYDEBUG(70, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy78; - if (yych == 'u') goto yy78; - goto yy57; + switch (yych) { + case 'U': + case 'u': goto yy78; + default: goto yy57; + } yy71: - YYDEBUG(71, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy72; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy72; + default: goto yy57; + } yy72: - YYDEBUG(72, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'S') goto yy74; - if (yych == 's') goto yy74; + switch (yych) { + case 'S': + case 's': goto yy74; + default: goto yy73; + } yy73: - YYDEBUG(73, *YYCURSOR); #line 1724 "ext/date/lib/parse_date.re" { timelib_ull i; @@ -2832,768 +3756,1557 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 2836 "ext/date/lib/parse_date.c" +#line 3760 "" yy74: - YYDEBUG(74, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy75; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy75; + default: goto yy57; + } yy75: - YYDEBUG(75, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy76; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy76; + default: goto yy57; + } yy76: - YYDEBUG(76, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy77: - YYDEBUG(77, *YYCURSOR); yych = *++YYCURSOR; goto yy73; yy78: - YYDEBUG(78, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'R') goto yy79; - if (yych != 'r') goto yy73; + switch (yych) { + case 'R': + case 'r': goto yy79; + default: goto yy73; + } yy79: - YYDEBUG(79, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy80; - if (yych != 's') goto yy57; + switch (yych) { + case 'S': + case 's': goto yy80; + default: goto yy57; + } yy80: - YYDEBUG(80, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy81; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy81; + default: goto yy57; + } yy81: - YYDEBUG(81, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy82; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy82; + default: goto yy57; + } yy82: - YYDEBUG(82, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych == 'y') goto yy77; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy83: - YYDEBUG(83, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= 'C') goto yy57; - if (yych <= 'D') goto yy85; - } else { - if (yych <= 'c') goto yy57; - if (yych <= 'd') goto yy85; - if (yych >= 'f') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy85; + case 'E': + case 'e': goto yy84; + default: goto yy57; } - YYDEBUG(84, *YYCURSOR); +yy84: yych = *++YYCURSOR; - if (yych == 'K') goto yy91; - if (yych == 'k') goto yy91; - goto yy57; + switch (yych) { + case 'K': + case 'k': goto yy91; + default: goto yy57; + } yy85: - YYDEBUG(85, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'N') goto yy86; - if (yych != 'n') goto yy73; + switch (yych) { + case 'N': + case 'n': goto yy86; + default: goto yy73; + } yy86: - YYDEBUG(86, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy87; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy87; + default: goto yy57; + } yy87: - YYDEBUG(87, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy88; - if (yych != 's') goto yy57; + switch (yych) { + case 'S': + case 's': goto yy88; + default: goto yy57; + } yy88: - YYDEBUG(88, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy89; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy89; + default: goto yy57; + } yy89: - YYDEBUG(89, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy90; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy90; + default: goto yy57; + } yy90: - YYDEBUG(90, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych == 'y') goto yy77; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy91: - YYDEBUG(91, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych == 'D') goto yy92; - if (yych <= 'R') goto yy73; - goto yy77; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy73; - } else { - if (yych == 's') goto yy77; - goto yy73; - } + switch (yych) { + case 'D': + case 'd': goto yy92; + case 'S': + case 's': goto yy77; + default: goto yy73; } yy92: - YYDEBUG(92, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy93; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy93; + default: goto yy57; + } yy93: - YYDEBUG(93, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy94; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy94; + default: goto yy57; + } yy94: - YYDEBUG(94, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy77; - if (yych == 's') goto yy77; - goto yy73; + switch (yych) { + case 'S': + case 's': goto yy77; + default: goto yy73; + } yy95: - YYDEBUG(95, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy96; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy96; + default: goto yy57; + } yy96: - YYDEBUG(96, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy97; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy97; + default: goto yy57; + } yy97: - YYDEBUG(97, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy77; - if (yych == 's') goto yy77; - goto yy73; + switch (yych) { + case 'S': + case 's': goto yy77; + default: goto yy73; + } yy98: - YYDEBUG(98, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy111; - if (yych == 'i') goto yy111; - goto yy57; + switch (yych) { + case 'I': + case 'i': goto yy111; + default: goto yy57; + } yy99: - YYDEBUG(99, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy100; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy100; + default: goto yy57; + } yy100: - YYDEBUG(100, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy101; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy101; + default: goto yy57; + } yy101: - YYDEBUG(101, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'H') goto yy103; - if (yych <= 'M') goto yy57; - } else { - if (yych <= 'h') { - if (yych <= 'g') goto yy57; - goto yy103; - } else { - if (yych != 'n') goto yy57; - } + switch (yych) { + case 'H': + case 'h': goto yy103; + case 'N': + case 'n': goto yy102; + default: goto yy57; } - YYDEBUG(102, *YYCURSOR); +yy102: yych = *++YYCURSOR; - if (yych == 'I') goto yy108; - if (yych == 'i') goto yy108; - goto yy57; + switch (yych) { + case 'I': + case 'i': goto yy108; + default: goto yy57; + } yy103: - YYDEBUG(103, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy104; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy104; + default: goto yy57; + } yy104: - YYDEBUG(104, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy105; - if (yych != 'i') goto yy57; + switch (yych) { + case 'I': + case 'i': goto yy105; + default: goto yy57; + } yy105: - YYDEBUG(105, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy106; - if (yych != 'g') goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy106; + default: goto yy57; + } yy106: - YYDEBUG(106, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy107; - if (yych != 'h') goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy107; + default: goto yy57; + } yy107: - YYDEBUG(107, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy97; - if (yych == 't') goto yy97; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy97; + default: goto yy57; + } yy108: - YYDEBUG(108, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy109; - if (yych != 'g') goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy109; + default: goto yy57; + } yy109: - YYDEBUG(109, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy110; - if (yych != 'h') goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy110; + default: goto yy57; + } yy110: - YYDEBUG(110, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy97; - if (yych == 't') goto yy97; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy97; + default: goto yy57; + } yy111: - YYDEBUG(111, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'D') goto yy112; - if (yych != 'd') goto yy73; + switch (yych) { + case 'D': + case 'd': goto yy112; + default: goto yy73; + } yy112: - YYDEBUG(112, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy113; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy113; + default: goto yy57; + } yy113: - YYDEBUG(113, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych == 'y') goto yy77; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy114: - YYDEBUG(114, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy97; - if (yych == 'y') goto yy97; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy97; + default: goto yy57; + } yy115: - YYDEBUG(115, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy116; - if (yych != 'u') goto yy57; + switch (yych) { + case 'U': + case 'u': goto yy116; + default: goto yy57; + } yy116: - YYDEBUG(116, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy97; - if (yych == 'r') goto yy97; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy97; + default: goto yy57; + } yy117: - YYDEBUG(117, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy122; - if (yych == 'n') goto yy122; - goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy122; + default: goto yy57; + } yy118: - YYDEBUG(118, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy119; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy119; + default: goto yy57; + } yy119: - YYDEBUG(119, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'U') { - if (yych == 'S') goto yy77; - if (yych <= 'T') goto yy73; - } else { - if (yych <= 's') { - if (yych <= 'r') goto yy73; - goto yy77; - } else { - if (yych != 'u') goto yy73; - } + switch (yych) { + case 'S': + case 's': goto yy77; + case 'U': + case 'u': goto yy120; + default: goto yy73; } - YYDEBUG(120, *YYCURSOR); +yy120: yych = *++YYCURSOR; - if (yych == 'T') goto yy121; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy121; + default: goto yy57; + } yy121: - YYDEBUG(121, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy97; - if (yych == 'e') goto yy97; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy97; + default: goto yy57; + } yy122: - YYDEBUG(122, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych == 'D') goto yy123; - if (yych <= 'S') goto yy73; - goto yy124; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy73; - } else { - if (yych == 't') goto yy124; - goto yy73; - } + switch (yych) { + case 'D': + case 'd': goto yy123; + case 'T': + case 't': goto yy124; + default: goto yy73; } yy123: - YYDEBUG(123, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy125; - if (yych == 'a') goto yy125; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy125; + default: goto yy57; + } yy124: - YYDEBUG(124, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy97; - if (yych == 'h') goto yy97; - goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy97; + default: goto yy57; + } yy125: - YYDEBUG(125, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych == 'y') goto yy77; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy126: - YYDEBUG(126, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy137; - if (yych == 'n') goto yy137; - goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy137; + default: goto yy57; + } yy127: - YYDEBUG(127, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy132; - if (yych == 't') goto yy132; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy132; + default: goto yy57; + } yy128: - YYDEBUG(128, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy129; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy129; + default: goto yy57; + } yy129: - YYDEBUG(129, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych == 'O') goto yy130; - if (yych <= 'R') goto yy73; - goto yy77; - } else { - if (yych <= 'o') { - if (yych <= 'n') goto yy73; - } else { - if (yych == 's') goto yy77; - goto yy73; - } + switch (yych) { + case 'O': + case 'o': goto yy130; + case 'S': + case 's': goto yy77; + default: goto yy73; } yy130: - YYDEBUG(130, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy131; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy131; + default: goto yy57; + } yy131: - YYDEBUG(131, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy97; - if (yych == 'd') goto yy97; - goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy97; + default: goto yy57; + } yy132: - YYDEBUG(132, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'U') goto yy133; - if (yych != 'u') goto yy73; + switch (yych) { + case 'U': + case 'u': goto yy133; + default: goto yy73; + } yy133: - YYDEBUG(133, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy134; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy134; + default: goto yy57; + } yy134: - YYDEBUG(134, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy135; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy135; + default: goto yy57; + } yy135: - YYDEBUG(135, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy136; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy136; + default: goto yy57; + } yy136: - YYDEBUG(136, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych == 'y') goto yy77; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy137: - YYDEBUG(137, *YYCURSOR); yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'D') goto yy138; - if (yych != 'd') goto yy73; + switch (yych) { + case 'D': + case 'd': goto yy138; + default: goto yy73; + } yy138: - YYDEBUG(138, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy139; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy139; + default: goto yy57; + } yy139: - YYDEBUG(139, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy77; - if (yych == 'y') goto yy77; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy77; + default: goto yy57; + } yy140: - YYDEBUG(140, *YYCURSOR); yych = *++YYCURSOR; goto yy4; yy141: - YYDEBUG(141, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + default: goto yy4; } yy142: - YYDEBUG(142, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy4; } yy143: - YYDEBUG(143, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy144: - YYDEBUG(144, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy145: - YYDEBUG(145, *YYCURSOR); yych = *++YYCURSOR; - if (yych == ')') goto yy140; - goto yy4; + switch (yych) { + case ')': goto yy140; + default: goto yy4; + } yy146: - YYDEBUG(146, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy4; - if (yych <= 'Z') goto yy142; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + default: goto yy4; } yy147: - YYDEBUG(147, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy4; - if (yych <= 'Z') goto yy143; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy151; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + default: goto yy4; } yy148: - YYDEBUG(148, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - if (yybm[0+yych] & 8) { - goto yy149; + switch (yych) { + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy149; + default: goto yy57; } - goto yy57; yy149: - YYDEBUG(149, *YYCURSOR); yyaccept = 0; YYMARKER = ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(150, *YYCURSOR); - if (yybm[0+yych] & 8) { - goto yy149; - } - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy4; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy4; + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy149; + default: goto yy4; } yy151: - YYDEBUG(151, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy4; - if (yych <= 'Z') goto yy144; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy152: - YYDEBUG(152, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy4; - if (yych <= 'Z') goto yy145; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - if (yych >= '{') goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy153: - YYDEBUG(153, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych <= '/') { - if (yych <= '.') goto yy4; - goto yy148; - } else { - if (yych == '_') goto yy148; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy4; } yy154: - YYDEBUG(154, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy155: - YYDEBUG(155, *YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy57; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy57; + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy57; } yy156: - YYDEBUG(156, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Z') goto yy141; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy141; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy141; + default: goto yy4; } yy157: - YYDEBUG(157, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'Z') { - if (yych >= 'U') goto yy142; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'T': goto yy158; + default: goto yy4; } - YYDEBUG(158, *YYCURSOR); +yy158: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych != '+') goto yy4; - } - } else { - if (yych <= 'Z') { - if (yych <= '-') goto yy159; - if (yych <= '@') goto yy4; - goto yy143; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '+': + case '-': goto yy159; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy4; + } +yy159: + yych = *++YYCURSOR; + switch (yych) { + case '0': + case '1': goto yy160; + case '2': goto yy161; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy162; + default: goto yy57; } -yy159: - YYDEBUG(159, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy160; - if (yych <= '2') goto yy161; - if (yych <= '9') goto yy162; - goto yy57; yy160: - YYDEBUG(160, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy162; - if (yych <= ':') goto yy163; - goto yy4; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy162; + case ':': goto yy163; + default: goto yy4; + } yy161: - YYDEBUG(161, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '5') { - if (yych <= '/') goto yy4; - if (yych >= '5') goto yy164; - } else { - if (yych <= '9') goto yy140; - if (yych <= ':') goto yy163; - goto yy4; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy162; + case '5': goto yy164; + case '6': + case '7': + case '8': + case '9': goto yy140; + case ':': goto yy163; + default: goto yy4; } yy162: - YYDEBUG(162, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy4; - if (yych <= '5') goto yy164; - if (yych <= '9') goto yy140; - if (yych >= ';') goto yy4; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy164; + case '6': + case '7': + case '8': + case '9': goto yy140; + case ':': goto yy163; + default: goto yy4; + } yy163: - YYDEBUG(163, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy4; - if (yych <= '5') goto yy164; - if (yych <= '9') goto yy140; - goto yy4; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy164; + case '6': + case '7': + case '8': + case '9': goto yy140; + default: goto yy4; + } yy164: - YYDEBUG(164, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy140; - goto yy4; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy140; + default: goto yy4; + } yy165: - YYDEBUG(165, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'C') goto yy142; - if (yych >= 'E') goto yy168; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'd') goto yy166; - if (yych <= 'e') goto yy168; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'D': + case 'd': goto yy166; + case 'E': + case 'e': goto yy168; + default: goto yy4; } yy166: - YYDEBUG(166, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= 'N') { - if (yych <= ')') { - if (yych >= ')') goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'M') goto yy143; - goto yy174; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy143; - if (yych >= 'a') goto yy143; - } else { - if (yych <= 'n') goto yy174; - if (yych <= 'z') goto yy143; - } + switch ((yych = *YYCURSOR)) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'N': + case 'n': goto yy174; + default: goto yy167; } yy167: - YYDEBUG(167, *YYCURSOR); #line 1587 "ext/date/lib/parse_date.re" { const timelib_relunit* relunit; @@ -3611,526 +5324,1063 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_WEEKDAY; } -#line 3615 "ext/date/lib/parse_date.c" +#line 5328 "" yy168: - YYDEBUG(168, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'K') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'J') goto yy143; - } - } else { - if (yych <= 'j') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'k') goto yy169; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'K': + case 'k': goto yy169; + default: goto yy4; } yy169: - YYDEBUG(169, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy144; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'd') goto yy170; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'D': + case 'd': goto yy170; + default: goto yy4; } yy170: - YYDEBUG(170, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy145; - goto yy4; - } else { - if (yych <= 'a') goto yy171; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy171; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy171: - YYDEBUG(171, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'X') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Y') goto yy172; - if (yych != 'y') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'Y': + case 'y': goto yy172; + default: goto yy4; } yy172: - YYDEBUG(172, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy173; - if (yych != 's') goto yy167; + switch (yych) { + case 'S': + case 's': goto yy173; + default: goto yy167; + } yy173: - YYDEBUG(173, *YYCURSOR); yych = *++YYCURSOR; goto yy167; yy174: - YYDEBUG(174, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy144; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'e') goto yy175; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'E': + case 'e': goto yy175; + default: goto yy4; } yy175: - YYDEBUG(175, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'R') goto yy145; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 's') goto yy176; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'S': + case 's': goto yy176; + default: goto yy4; } yy176: - YYDEBUG(176, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'D') goto yy177; - if (yych != 'd') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'D': + case 'd': goto yy177; + default: goto yy4; } yy177: - YYDEBUG(177, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy178; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy178; + default: goto yy57; + } yy178: - YYDEBUG(178, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy173; - if (yych == 'y') goto yy173; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy173; + default: goto yy57; + } yy179: - YYDEBUG(179, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych <= '/') { - if (yych <= '.') goto yy4; - goto yy148; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy142; - goto yy166; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'E') goto yy168; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy147; - } else { - if (yych <= 'e') goto yy181; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'D': goto yy166; + case 'E': goto yy168; + case 'a': + case 'b': + case 'c': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'd': goto yy180; + case 'e': goto yy181; + default: goto yy4; } - YYDEBUG(180, *YYCURSOR); +yy180: yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy174; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 'n') goto yy187; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'N': goto yy174; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'n': goto yy187; + default: goto yy167; } yy181: - YYDEBUG(181, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'J') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'K') goto yy169; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'j') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'k') goto yy182; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'K': goto yy169; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'k': goto yy182; + default: goto yy4; } yy182: - YYDEBUG(182, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy170; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'd') goto yy183; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'D': goto yy170; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'd': goto yy183; + default: goto yy4; } yy183: - YYDEBUG(183, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy171; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy184; - if (yych <= 'z') goto yy153; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy171; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': goto yy184; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy184: - YYDEBUG(184, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'Y') goto yy172; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'y') goto yy185; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'Y': goto yy172; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy154; + case 'y': goto yy185; + default: goto yy4; } yy185: - YYDEBUG(185, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy167; - } else { - if (yych <= '/') goto yy148; - if (yych <= 'R') goto yy167; - goto yy173; - } - } else { - if (yych <= '`') { - if (yych == '_') goto yy148; - goto yy167; - } else { - if (yych == 's') goto yy186; - if (yych <= 'z') goto yy154; - goto yy167; - } + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'S': goto yy173; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 's': goto yy186; + default: goto yy167; } yy186: - YYDEBUG(186, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy167; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy167; + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy167; } yy187: - YYDEBUG(187, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy175; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'e') goto yy188; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'E': goto yy175; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'e': goto yy188; + default: goto yy4; } yy188: - YYDEBUG(188, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy176; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 's') goto yy189; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'S': goto yy176; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 's': goto yy189; + default: goto yy4; } yy189: - YYDEBUG(189, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'D') goto yy177; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'd') goto yy190; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'D': goto yy177; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'd': goto yy190; + default: goto yy4; } yy190: - YYDEBUG(190, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy178; - if (yych != 'a') goto yy155; - YYDEBUG(191, *YYCURSOR); + switch (yych) { + case 'A': goto yy178; + case 'a': goto yy191; + default: goto yy155; + } +yy191: yych = *++YYCURSOR; - if (yych == 'Y') goto yy173; - if (yych == 'y') goto yy186; - goto yy155; + switch (yych) { + case 'Y': goto yy173; + case 'y': goto yy186; + default: goto yy155; + } yy192: - YYDEBUG(192, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'C') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'B') goto yy142; - } - } else { - if (yych <= 'b') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'c') goto yy193; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'C': + case 'c': goto yy193; + default: goto yy4; } yy193: - YYDEBUG(193, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych >= '\t') goto yy196; - } else { - if (yych == ' ') goto yy196; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - } else { - if (yych == 'E') goto yy202; - goto yy143; - } - } else { - if (yych <= 'd') { - if (yych >= 'a') goto yy143; - } else { - if (yych <= 'e') goto yy202; - if (yych <= 'z') goto yy143; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'E': + case 'e': goto yy202; + default: goto yy194; } yy194: - YYDEBUG(194, *YYCURSOR); #line 1646 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("monthtext"); @@ -4140,57 +6390,59 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 4144 "ext/date/lib/parse_date.c" +#line 6394 "" yy195: - YYDEBUG(195, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 21) YYFILL(21); yych = *YYCURSOR; yy196: - YYDEBUG(196, *YYCURSOR); - if (yybm[0+yych] & 32) { - goto yy195; - } - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy198; - if (yych <= '3') goto yy200; - if (yych <= '9') goto yy201; - goto yy57; + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy195; + case '0': + case '1': + case '2': goto yy198; + case '3': goto yy200; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy201; + default: goto yy57; + } yy197: - YYDEBUG(197, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy196; - if (yych <= '0') goto yy357; - if (yych <= '2') goto yy358; - if (yych <= '3') goto yy359; - goto yy196; + switch (yych) { + case '0': goto yy357; + case '1': + case '2': goto yy358; + case '3': goto yy359; + default: goto yy196; + } yy198: - YYDEBUG(198, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy298; - goto yy299; - } else { - if (yych <= '2') goto yy355; - if (yych <= '9') goto yy356; - goto yy216; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy212; - if (yych <= 'q') goto yy216; - goto yy213; - } else { - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '0': goto yy298; + case '1': goto yy299; + case '2': goto yy355; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy356; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy199: - YYDEBUG(199, *YYCURSOR); #line 1396 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datetextual | datenoyear"); @@ -4203,275 +6455,398 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 4207 "ext/date/lib/parse_date.c" +#line 6459 "" yy200: - YYDEBUG(200, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy298; - goto yy299; - } else { - if (yych <= '2') goto yy209; - if (yych <= '9') goto yy210; - goto yy216; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy212; - if (yych <= 'q') goto yy216; - goto yy213; - } else { - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '0': goto yy298; + case '1': goto yy299; + case '2': goto yy209; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy210; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy201: - YYDEBUG(201, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy207; - goto yy208; - } else { - if (yych <= '2') goto yy209; - if (yych <= '9') goto yy210; - goto yy216; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy212; - if (yych <= 'q') goto yy216; - goto yy213; - } else { - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '0': goto yy207; + case '1': goto yy208; + case '2': goto yy209; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy210; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy202: - YYDEBUG(202, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'M') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'L') goto yy144; - } - } else { - if (yych <= 'l') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'm') goto yy203; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'M': + case 'm': goto yy203; + default: goto yy4; } yy203: - YYDEBUG(203, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'B') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'A') goto yy145; - } - } else { - if (yych <= 'a') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'b') goto yy204; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'B': + case 'b': goto yy204; + default: goto yy4; } yy204: - YYDEBUG(204, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'E') goto yy205; - if (yych != 'e') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'E': + case 'e': goto yy205; + default: goto yy4; } yy205: - YYDEBUG(205, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy206; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy206; + default: goto yy57; + } yy206: - YYDEBUG(206, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy194; - goto yy196; - } else { - if (yych <= '.') { - if (yych <= ',') goto yy194; - goto yy196; - } else { - if (yych <= '/') goto yy194; - if (yych <= '9') goto yy196; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + default: goto yy194; } yy207: - YYDEBUG(207, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy57; - } else { - if (yych <= '0') goto yy296; - if (yych <= '9') goto yy297; - if (yych <= ':') goto yy221; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': goto yy296; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + default: goto yy57; } yy208: - YYDEBUG(208, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '2') goto yy297; - if (yych <= '9') goto yy296; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': goto yy297; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy296; + default: goto yy57; } yy209: - YYDEBUG(209, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '4') goto yy296; - if (yych <= '9') goto yy293; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy296; + case '5': + case '6': + case '7': + case '8': + case '9': goto yy293; + default: goto yy57; } yy210: - YYDEBUG(210, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '9') goto yy293; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy293; + default: goto yy57; } yy211: - YYDEBUG(211, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); goto yy216; yy212: - YYDEBUG(212, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); goto yy216; yy213: - YYDEBUG(213, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); goto yy216; yy214: - YYDEBUG(214, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); goto yy216; yy215: - YYDEBUG(215, *YYCURSOR); yyaccept = 6; YYMARKER = ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 18) YYFILL(18); yych = *YYCURSOR; yy216: - YYDEBUG(216, *YYCURSOR); - if (yybm[0+yych] & 64) { - goto yy215; - } - if (yych <= '2') { - if (yych <= '/') goto yy199; - if (yych <= '0') goto yy259; - if (yych <= '1') goto yy260; - goto yy261; - } else { - if (yych <= '9') goto yy262; - if (yych != 'T') goto yy199; + switch (yych) { + case '\t': + case ' ': + case ',': + case '.': + case 'd': + case 'h': + case 'n': + case 'r': + case 's': + case 't': goto yy215; + case '0': goto yy259; + case '1': goto yy260; + case '2': goto yy261; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy262; + case 'T': goto yy217; + default: goto yy199; } - YYDEBUG(217, *YYCURSOR); +yy217: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy218; - if (yych <= '2') goto yy219; - if (yych <= '9') goto yy220; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy218; + case '2': goto yy219; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy220; + default: goto yy57; + } yy218: - YYDEBUG(218, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy57; - } else { - if (yych <= '9') goto yy220; - if (yych <= ':') goto yy221; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy220; + default: goto yy57; } yy219: - YYDEBUG(219, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy57; - } else { - if (yych <= '4') goto yy220; - if (yych == ':') goto yy221; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy220; + default: goto yy57; } yy220: - YYDEBUG(220, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '.') goto yy221; - if (yych != ':') goto yy57; + switch (yych) { + case '.': + case ':': goto yy221; + default: goto yy57; + } yy221: - YYDEBUG(221, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy222; - if (yych <= '9') goto yy224; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy222; + case '6': + case '7': + case '8': + case '9': goto yy224; + default: goto yy57; + } yy222: - YYDEBUG(222, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy225; - } else { - if (yych <= '9') goto yy224; - if (yych <= ':') goto yy225; + switch (yych) { + case '.': + case ':': goto yy225; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy224; + default: goto yy223; } yy223: - YYDEBUG(223, *YYCURSOR); #line 1694 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -4501,704 +6876,1797 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_SHORTDATE_WITH_TIME; } -#line 4505 "ext/date/lib/parse_date.c" +#line 6880 "" yy224: - YYDEBUG(224, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy225; - if (yych != ':') goto yy223; + switch (yych) { + case '.': + case ':': goto yy225; + default: goto yy223; + } yy225: - YYDEBUG(225, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy226; - if (yych <= '6') goto yy227; - if (yych <= '9') goto yy228; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy226; + case '6': goto yy227; + case '7': + case '8': + case '9': goto yy228; + default: goto yy57; + } yy226: - YYDEBUG(226, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy223; - if (yych <= '9') goto yy229; - goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy229; + default: goto yy223; + } yy227: - YYDEBUG(227, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '0') goto yy229; - goto yy223; + switch (yych) { + case '0': goto yy229; + default: goto yy223; + } yy228: - YYDEBUG(228, *YYCURSOR); yych = *++YYCURSOR; goto yy223; yy229: - YYDEBUG(229, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '*') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy231; - goto yy223; - } else { - if (yych <= ' ') goto yy231; - if (yych == '(') goto yy231; - goto yy223; - } - } else { - if (yych <= '@') { - if (yych == ',') goto yy223; - if (yych <= '-') goto yy231; - goto yy223; - } else { - if (yych <= 'Z') goto yy231; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy231; - goto yy223; - } + switch (yych) { + case '\t': + case ' ': + case '(': + case '+': + case '-': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy231; + default: goto yy223; } yy230: - YYDEBUG(230, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; yy231: - YYDEBUG(231, *YYCURSOR); - if (yych <= '+') { - if (yych <= ' ') { - if (yych == '\t') goto yy230; - if (yych <= 0x1F) goto yy57; - goto yy230; - } else { - if (yych == '(') goto yy234; - if (yych <= '*') goto yy57; - goto yy233; - } - } else { - if (yych <= 'F') { - if (yych == '-') goto yy233; - if (yych <= '@') goto yy57; - goto yy235; - } else { - if (yych <= 'Z') { - if (yych >= 'H') goto yy235; - } else { - if (yych <= '`') goto yy57; - if (yych <= 'z') goto yy236; - goto yy57; - } - } + switch (yych) { + case '\t': + case ' ': goto yy230; + case '(': goto yy234; + case '+': + case '-': goto yy233; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy235; + case 'G': goto yy232; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy236; + default: goto yy57; } yy232: - YYDEBUG(232, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych == ')') goto yy228; - if (yych <= '@') goto yy223; - goto yy237; - } else { - if (yych <= 'Z') { - if (yych <= 'M') goto yy257; - goto yy237; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy242; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy237; + case 'M': goto yy257; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy242; + default: goto yy223; } yy233: - YYDEBUG(233, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy252; - if (yych <= '2') goto yy253; - if (yych <= '9') goto yy254; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy252; + case '2': goto yy253; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy254; + default: goto yy57; + } yy234: - YYDEBUG(234, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') goto yy57; - if (yych <= 'Z') goto yy236; - if (yych <= '`') goto yy57; - if (yych <= 'z') goto yy236; - goto yy57; + switch (yych) { + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy236; + default: goto yy57; + } yy235: - YYDEBUG(235, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= 'Z') goto yy237; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy242; - goto yy223; + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy237; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy242; + default: goto yy223; } yy236: - YYDEBUG(236, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= 'Z') goto yy237; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy237; + default: goto yy223; } yy237: - YYDEBUG(237, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= 'Z') goto yy238; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy238; + default: goto yy223; } yy238: - YYDEBUG(238, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= 'Z') goto yy239; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy239; + default: goto yy223; } yy239: - YYDEBUG(239, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= 'Z') goto yy240; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy240; + default: goto yy223; } yy240: - YYDEBUG(240, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '@') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= 'Z') goto yy241; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy241; + default: goto yy223; } yy241: - YYDEBUG(241, *YYCURSOR); yych = *++YYCURSOR; - if (yych == ')') goto yy228; - goto yy223; + switch (yych) { + case ')': goto yy228; + default: goto yy223; + } yy242: - YYDEBUG(242, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych == '.') goto yy223; - goto yy244; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy223; - if (yych <= 'Z') goto yy238; - goto yy223; - } else { - if (yych <= '_') goto yy244; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy238; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy243; + default: goto yy223; } yy243: - YYDEBUG(243, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych == '.') goto yy223; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy223; - if (yych <= 'Z') goto yy239; - goto yy223; - } else { - if (yych <= '_') goto yy244; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy247; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy239; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy247; + default: goto yy223; } yy244: - YYDEBUG(244, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - if (yych <= '@') goto yy57; - if (yych <= 'Z') goto yy245; - if (yych <= '`') goto yy57; - if (yych >= '{') goto yy57; + switch (yych) { + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy245; + default: goto yy57; + } yy245: - YYDEBUG(245, *YYCURSOR); yyaccept = 7; YYMARKER = ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(246, *YYCURSOR); - if (yych <= '@') { - if (yych <= '-') { - if (yych <= ',') goto yy223; - goto yy244; - } else { - if (yych == '/') goto yy244; - goto yy223; - } - } else { - if (yych <= '_') { - if (yych <= 'Z') goto yy245; - if (yych <= '^') goto yy223; - goto yy244; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy245; - goto yy223; - } + switch (yych) { + case '-': + case '/': + case '_': goto yy244; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy245; + default: goto yy223; } yy247: - YYDEBUG(247, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych == '.') goto yy223; - goto yy244; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy223; - if (yych <= 'Z') goto yy240; - goto yy223; - } else { - if (yych <= '_') goto yy244; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy240; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy248; + default: goto yy223; } - YYDEBUG(248, *YYCURSOR); +yy248: yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych == '.') goto yy223; - goto yy244; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy223; - if (yych <= 'Z') goto yy241; - goto yy223; - } else { - if (yych <= '_') goto yy244; - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy241; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy249; + default: goto yy223; } - YYDEBUG(249, *YYCURSOR); +yy249: yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy223; - goto yy228; - } else { - if (yych == '-') goto yy244; - goto yy223; - } - } else { - if (yych <= '_') { - if (yych <= '/') goto yy244; - if (yych <= '^') goto yy223; - goto yy244; - } else { - if (yych <= '`') goto yy223; - if (yych >= '{') goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy250; + default: goto yy223; } yy250: - YYDEBUG(250, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(251, *YYCURSOR); - if (yych <= '/') { - if (yych == '-') goto yy244; - if (yych <= '.') goto yy57; - goto yy244; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy57; - goto yy244; - } else { - if (yych <= '`') goto yy57; - if (yych <= 'z') goto yy250; - goto yy57; - } + switch (yych) { + case '-': + case '/': + case '_': goto yy244; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy250; + default: goto yy57; } yy252: - YYDEBUG(252, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy223; - if (yych <= '9') goto yy254; - if (yych <= ':') goto yy255; - goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy254; + case ':': goto yy255; + default: goto yy223; + } yy253: - YYDEBUG(253, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '5') { - if (yych <= '/') goto yy223; - if (yych >= '5') goto yy256; - } else { - if (yych <= '9') goto yy228; - if (yych <= ':') goto yy255; - goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy254; + case '5': goto yy256; + case '6': + case '7': + case '8': + case '9': goto yy228; + case ':': goto yy255; + default: goto yy223; } yy254: - YYDEBUG(254, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy223; - if (yych <= '5') goto yy256; - if (yych <= '9') goto yy228; - if (yych >= ';') goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy256; + case '6': + case '7': + case '8': + case '9': goto yy228; + case ':': goto yy255; + default: goto yy223; + } yy255: - YYDEBUG(255, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy223; - if (yych <= '5') goto yy256; - if (yych <= '9') goto yy228; - goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy256; + case '6': + case '7': + case '8': + case '9': goto yy228; + default: goto yy223; + } yy256: - YYDEBUG(256, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy223; - if (yych <= '9') goto yy228; - goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy228; + default: goto yy223; + } yy257: - YYDEBUG(257, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych == ')') goto yy228; - if (yych <= '@') goto yy223; - goto yy238; - } else { - if (yych <= 'Z') { - if (yych >= 'U') goto yy238; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy238; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy238; + case 'T': goto yy258; + default: goto yy223; } - YYDEBUG(258, *YYCURSOR); +yy258: yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= ')') { - if (yych <= '(') goto yy223; - goto yy228; - } else { - if (yych == '+') goto yy233; - goto yy223; - } - } else { - if (yych <= 'Z') { - if (yych <= '-') goto yy233; - if (yych <= '@') goto yy223; - goto yy239; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy239; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '+': + case '-': goto yy233; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy239; + default: goto yy223; } yy259: - YYDEBUG(259, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy199; - } else { - if (yych <= '0') goto yy291; - if (yych <= '9') goto yy292; - if (yych <= ':') goto yy221; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': goto yy291; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy292; + default: goto yy199; } yy260: - YYDEBUG(260, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy199; - } else { - if (yych <= '2') goto yy292; - if (yych <= '9') goto yy291; - if (yych <= ':') goto yy264; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': goto yy292; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy291; + default: goto yy199; } yy261: - YYDEBUG(261, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy199; - } else { - if (yych <= '4') goto yy291; - if (yych <= '9') goto yy263; - if (yych <= ':') goto yy264; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy291; + case '5': + case '6': + case '7': + case '8': + case '9': goto yy263; + default: goto yy199; } yy262: - YYDEBUG(262, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy199; - } else { - if (yych <= '9') goto yy263; - if (yych <= ':') goto yy264; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy263; + default: goto yy199; } yy263: - YYDEBUG(263, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy199; - if (yych <= '9') goto yy289; - goto yy199; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + default: goto yy199; + } yy264: - YYDEBUG(264, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy265; - if (yych <= '9') goto yy266; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy265; + case '6': + case '7': + case '8': + case '9': goto yy266; + default: goto yy57; + } yy265: - YYDEBUG(265, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy267; - goto yy223; - } else { - if (yych <= '9') goto yy282; - if (yych <= ':') goto yy267; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy267; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy282; + default: goto yy223; } yy266: - YYDEBUG(266, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy267; - if (yych != ':') goto yy223; + switch (yych) { + case '.': + case ':': goto yy267; + default: goto yy223; + } yy267: - YYDEBUG(267, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy268; - if (yych <= '6') goto yy269; - if (yych <= '9') goto yy228; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy268; + case '6': goto yy269; + case '7': + case '8': + case '9': goto yy228; + default: goto yy57; + } yy268: - YYDEBUG(268, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy223; - if (yych <= '9') goto yy270; - goto yy223; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy270; + default: goto yy223; + } yy269: - YYDEBUG(269, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '0') goto yy223; + switch (yych) { + case '0': goto yy270; + default: goto yy223; + } yy270: - YYDEBUG(270, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '*') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy272; - goto yy223; - } else { - if (yych <= ' ') goto yy272; - if (yych == '(') goto yy272; - goto yy223; - } - } else { - if (yych <= '@') { - if (yych == ',') goto yy223; - if (yych <= '-') goto yy272; - goto yy223; - } else { - if (yych <= 'Z') goto yy272; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy272; - goto yy223; - } + switch (yych) { + case '\t': + case ' ': + case '(': + case '+': + case '-': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy272; + default: goto yy223; } yy271: - YYDEBUG(271, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; yy272: - YYDEBUG(272, *YYCURSOR); - if (yych <= '@') { - if (yych <= '\'') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy57; - goto yy271; - } else { - if (yych == ' ') goto yy271; - goto yy57; - } - } else { - if (yych <= '+') { - if (yych <= '(') goto yy234; - if (yych <= '*') goto yy57; - goto yy233; - } else { - if (yych == '-') goto yy233; - goto yy57; - } - } - } else { - if (yych <= 'Z') { - if (yych <= 'G') { - if (yych <= 'A') goto yy273; - if (yych <= 'F') goto yy235; - goto yy232; - } else { - if (yych != 'P') goto yy235; - } - } else { - if (yych <= 'o') { - if (yych <= '`') goto yy57; - if (yych <= 'a') goto yy274; - goto yy236; - } else { - if (yych <= 'p') goto yy274; - if (yych <= 'z') goto yy236; - goto yy57; - } - } + switch (yych) { + case '\t': + case ' ': goto yy271; + case '(': goto yy234; + case '+': + case '-': goto yy233; + case 'A': + case 'P': goto yy273; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy235; + case 'G': goto yy232; + case 'a': + case 'p': goto yy274; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy236; + default: goto yy57; } yy273: - YYDEBUG(273, *YYCURSOR); yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= '.') goto yy275; - if (yych <= '@') goto yy223; - goto yy237; - } - } else { - if (yych <= '`') { - if (yych <= 'M') goto yy276; - if (yych <= 'Z') goto yy237; - goto yy223; - } else { - if (yych == 'm') goto yy281; - if (yych <= 'z') goto yy242; - goto yy223; - } + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy228; + case '.': goto yy275; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy237; + case 'M': goto yy276; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy242; + case 'm': goto yy281; + default: goto yy223; } yy274: - YYDEBUG(274, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= '.') goto yy275; - if (yych <= '@') goto yy223; - goto yy237; - } - } else { - if (yych <= '`') { - if (yych <= 'M') goto yy276; - if (yych <= 'Z') goto yy237; - goto yy223; - } else { - if (yych == 'm') goto yy276; - if (yych <= 'z') goto yy237; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '.': goto yy275; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy237; + case 'M': + case 'm': goto yy276; + default: goto yy223; } yy275: - YYDEBUG(275, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy280; - if (yych == 'm') goto yy280; - goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy280; + default: goto yy57; + } yy276: - YYDEBUG(276, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ')') { - if (yych <= '\t') { - if (yych <= 0x00) goto yy278; - if (yych <= 0x08) goto yy223; - goto yy278; - } else { - if (yych == ' ') goto yy278; - if (yych <= '(') goto yy223; - goto yy228; - } - } else { - if (yych <= '@') { - if (yych != '.') goto yy223; - } else { - if (yych <= 'Z') goto yy238; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy238; - goto yy223; - } + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case ')': goto yy228; + case '.': goto yy277; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy238; + default: goto yy223; } yy277: - YYDEBUG(277, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy278; - if (yych <= 0x08) goto yy57; - } else { - if (yych != ' ') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + default: goto yy57; } yy278: - YYDEBUG(278, *YYCURSOR); ++YYCURSOR; - YYDEBUG(279, *YYCURSOR); #line 1670 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("dateshortwithtimeshort12 | dateshortwithtimelong12"); @@ -5222,184 +8690,213 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_SHORTDATE_WITH_TIME; } -#line 5226 "ext/date/lib/parse_date.c" +#line 8694 "" yy280: - YYDEBUG(280, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy278; - if (yych == '\t') goto yy278; - goto yy57; - } else { - if (yych <= ' ') goto yy278; - if (yych == '.') goto yy277; - goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case '.': goto yy277; + default: goto yy57; } yy281: - YYDEBUG(281, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy278; - if (yych == '\t') goto yy278; - goto yy223; - } else { - if (yych <= '(') { - if (yych <= ' ') goto yy278; - goto yy223; - } else { - if (yych <= ')') goto yy228; - if (yych <= ',') goto yy223; - goto yy244; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '.') goto yy277; - if (yych <= '/') goto yy244; - if (yych <= '@') goto yy223; - goto yy238; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy223; - goto yy244; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy243; - goto yy223; - } - } + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case '.': goto yy277; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy238; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy243; + default: goto yy223; } yy282: - YYDEBUG(282, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy283; - if (yych <= 0x1F) goto yy223; - } else { - if (yych == '.') goto yy267; - if (yych <= '9') goto yy223; - goto yy267; - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy285; - if (yych <= 'O') goto yy223; - goto yy285; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy223; - goto yy285; - } else { - if (yych == 'p') goto yy285; - goto yy223; - } - } + switch (yych) { + case '\t': + case ' ': goto yy283; + case '.': + case ':': goto yy267; + case 'A': + case 'P': + case 'a': + case 'p': goto yy285; + default: goto yy223; } yy283: - YYDEBUG(283, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - YYDEBUG(284, *YYCURSOR); - if (yych <= 'A') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy283; - goto yy57; - } else { - if (yych <= ' ') goto yy283; - if (yych <= '@') goto yy57; - } - } else { - if (yych <= '`') { - if (yych != 'P') goto yy57; - } else { - if (yych <= 'a') goto yy285; - if (yych != 'p') goto yy57; - } + yych = *YYCURSOR; + switch (yych) { + case '\t': + case ' ': goto yy283; + case 'A': + case 'P': + case 'a': + case 'p': goto yy285; + default: goto yy57; } yy285: - YYDEBUG(285, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych != '.') goto yy57; - } else { - if (yych <= 'M') goto yy287; - if (yych == 'm') goto yy287; - goto yy57; + switch (yych) { + case '.': goto yy286; + case 'M': + case 'm': goto yy287; + default: goto yy57; } yy286: - YYDEBUG(286, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy287; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy287; + default: goto yy57; + } yy287: - YYDEBUG(287, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy278; - if (yych == '\t') goto yy278; - goto yy57; - } else { - if (yych <= ' ') goto yy278; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case '.': goto yy288; + default: goto yy57; } yy288: - YYDEBUG(288, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy278; - if (yych <= 0x08) goto yy57; - goto yy278; - } else { - if (yych == ' ') goto yy278; - goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + default: goto yy57; } yy289: - YYDEBUG(289, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy199; - if (yych >= ':') goto yy199; - YYDEBUG(290, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy290; + default: goto yy199; + } +yy290: yych = *++YYCURSOR; goto yy199; yy291: - YYDEBUG(291, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy199; - } else { - if (yych <= '9') goto yy289; - if (yych <= ':') goto yy221; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + default: goto yy199; } yy292: - YYDEBUG(292, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy199; - } else { - if (yych <= '9') goto yy289; - if (yych <= ':') goto yy264; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + default: goto yy199; } yy293: - YYDEBUG(293, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy294; + default: goto yy57; + } yy294: - YYDEBUG(294, *YYCURSOR); ++YYCURSOR; yy295: - YYDEBUG(295, *YYCURSOR); #line 1370 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenoday"); @@ -5412,1226 +8909,1768 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_NO_DAY; } -#line 5416 "ext/date/lib/parse_date.c" +#line 8913 "" yy296: - YYDEBUG(296, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy57; - } else { - if (yych <= '9') goto yy294; - if (yych <= ':') goto yy221; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy294; + default: goto yy57; } yy297: - YYDEBUG(297, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '9') goto yy294; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy294; + default: goto yy57; } yy298: - YYDEBUG(298, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych == '.') goto yy331; - goto yy216; - } else { - if (yych <= '0') goto yy332; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy221; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '.': goto yy331; + case '0': goto yy332; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy221; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy299: - YYDEBUG(299, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych != '.') goto yy216; - } else { - if (yych <= '0') goto yy301; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy264; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '.': goto yy300; + case '0': goto yy301; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy264; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy300: - YYDEBUG(300, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy306; - goto yy307; - } else { - if (yych <= '2') goto yy308; - if (yych <= '5') goto yy309; - if (yych <= '9') goto yy310; - goto yy216; + switch (yych) { + case '0': goto yy306; + case '1': goto yy307; + case '2': goto yy308; + case '3': + case '4': + case '5': goto yy309; + case '6': + case '7': + case '8': + case '9': goto yy310; + default: goto yy216; } yy301: - YYDEBUG(301, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '0') goto yy304; - if (yych <= '9') goto yy305; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': goto yy304; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy305; + default: goto yy57; } yy302: - YYDEBUG(302, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '2') goto yy305; - if (yych <= '9') goto yy304; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': goto yy305; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy304; + default: goto yy57; } yy303: - YYDEBUG(303, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy264; - goto yy57; - } else { - if (yych <= '4') goto yy304; - if (yych <= '9') goto yy294; - if (yych <= ':') goto yy264; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy264; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy304; + case '5': + case '6': + case '7': + case '8': + case '9': goto yy294; + default: goto yy57; } yy304: - YYDEBUG(304, *YYCURSOR); yyaccept = 8; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy221; - if (yych == ':') goto yy221; - goto yy295; + switch (yych) { + case '.': + case ':': goto yy221; + default: goto yy295; + } yy305: - YYDEBUG(305, *YYCURSOR); yyaccept = 8; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy264; - if (yych == ':') goto yy264; - goto yy295; + switch (yych) { + case '.': + case ':': goto yy264; + default: goto yy295; + } yy306: - YYDEBUG(306, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy326; - goto yy199; - } else { - if (yych <= '0') goto yy325; - if (yych <= '9') goto yy330; - if (yych <= ':') goto yy326; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy326; + case '0': goto yy325; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy330; + default: goto yy199; } yy307: - YYDEBUG(307, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy311; - goto yy199; - } else { - if (yych <= '2') goto yy330; - if (yych <= '9') goto yy325; - if (yych <= ':') goto yy311; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy311; + case '0': + case '1': + case '2': goto yy330; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy325; + default: goto yy199; } yy308: - YYDEBUG(308, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy311; - goto yy199; - } else { - if (yych <= '4') goto yy325; - if (yych <= '9') goto yy324; - if (yych <= ':') goto yy311; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy311; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy325; + case '5': + case '6': + case '7': + case '8': + case '9': goto yy324; + default: goto yy199; } yy309: - YYDEBUG(309, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy311; - goto yy199; - } else { - if (yych <= '9') goto yy324; - if (yych <= ':') goto yy311; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy311; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy324; + default: goto yy199; } yy310: - YYDEBUG(310, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych != '.') goto yy199; - } else { - if (yych <= '9') goto yy263; - if (yych >= ';') goto yy199; + switch (yych) { + case '.': + case ':': goto yy311; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy263; + default: goto yy199; } yy311: - YYDEBUG(311, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy312; - if (yych <= '6') goto yy313; - if (yych <= '9') goto yy266; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy312; + case '6': goto yy313; + case '7': + case '8': + case '9': goto yy266; + default: goto yy57; + } yy312: - YYDEBUG(312, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy267; - goto yy223; - } else { - if (yych <= '9') goto yy314; - if (yych <= ':') goto yy267; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy267; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy314; + default: goto yy223; } yy313: - YYDEBUG(313, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy267; - goto yy223; - } else { - if (yych <= '0') goto yy270; - if (yych == ':') goto yy267; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy267; + case '0': goto yy270; + default: goto yy223; } yy314: - YYDEBUG(314, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= ' ') { - if (yych == '\t') goto yy316; - if (yych <= 0x1F) goto yy223; - goto yy316; - } else { - if (yych <= '(') { - if (yych <= '\'') goto yy223; - goto yy316; - } else { - if (yych == '+') goto yy316; - goto yy223; - } - } - } else { - if (yych <= ':') { - if (yych <= '-') goto yy316; - if (yych <= '.') goto yy267; - if (yych <= '9') goto yy223; - goto yy267; - } else { - if (yych <= 'Z') { - if (yych <= '@') goto yy223; - goto yy316; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy316; - goto yy223; - } - } + switch (yych) { + case '\t': + case ' ': + case '(': + case '+': + case '-': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy316; + case '.': + case ':': goto yy267; + default: goto yy223; } yy315: - YYDEBUG(315, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; yy316: - YYDEBUG(316, *YYCURSOR); - if (yych <= '@') { - if (yych <= '\'') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy57; - goto yy315; - } else { - if (yych == ' ') goto yy315; - goto yy57; - } - } else { - if (yych <= '+') { - if (yych <= '(') goto yy234; - if (yych <= '*') goto yy57; - goto yy233; - } else { - if (yych == '-') goto yy233; - goto yy57; - } - } - } else { - if (yych <= 'Z') { - if (yych <= 'G') { - if (yych <= 'A') goto yy317; - if (yych <= 'F') goto yy235; - goto yy232; - } else { - if (yych != 'P') goto yy235; - } - } else { - if (yych <= 'o') { - if (yych <= '`') goto yy57; - if (yych <= 'a') goto yy318; - goto yy236; - } else { - if (yych <= 'p') goto yy318; - if (yych <= 'z') goto yy236; - goto yy57; - } - } + switch (yych) { + case '\t': + case ' ': goto yy315; + case '(': goto yy234; + case '+': + case '-': goto yy233; + case 'A': + case 'P': goto yy317; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy235; + case 'G': goto yy232; + case 'a': + case 'p': goto yy318; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy236; + default: goto yy57; } yy317: - YYDEBUG(317, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= '.') goto yy320; - if (yych <= '@') goto yy223; - goto yy237; - } - } else { - if (yych <= '`') { - if (yych <= 'M') goto yy319; - if (yych <= 'Z') goto yy237; - goto yy223; - } else { - if (yych == 'm') goto yy323; - if (yych <= 'z') goto yy242; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '.': goto yy320; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy237; + case 'M': goto yy319; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy242; + case 'm': goto yy323; + default: goto yy223; } yy318: - YYDEBUG(318, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= '.') goto yy320; - if (yych <= '@') goto yy223; - goto yy237; - } - } else { - if (yych <= '`') { - if (yych <= 'M') goto yy319; - if (yych <= 'Z') goto yy237; - goto yy223; - } else { - if (yych == 'm') goto yy319; - if (yych <= 'z') goto yy237; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '.': goto yy320; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy237; + case 'M': + case 'm': goto yy319; + default: goto yy223; } yy319: - YYDEBUG(319, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ')') { - if (yych <= '\t') { - if (yych <= 0x00) goto yy278; - if (yych <= 0x08) goto yy223; - goto yy278; - } else { - if (yych == ' ') goto yy278; - if (yych <= '(') goto yy223; - goto yy228; - } - } else { - if (yych <= '@') { - if (yych == '.') goto yy322; - goto yy223; - } else { - if (yych <= 'Z') goto yy238; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy238; - goto yy223; - } + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case ')': goto yy228; + case '.': goto yy322; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy238; + default: goto yy223; } yy320: - YYDEBUG(320, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy321; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy321; + default: goto yy57; + } yy321: - YYDEBUG(321, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy278; - if (yych == '\t') goto yy278; - goto yy57; - } else { - if (yych <= ' ') goto yy278; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case '.': goto yy322; + default: goto yy57; } yy322: - YYDEBUG(322, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy278; - if (yych <= 0x08) goto yy57; - goto yy278; - } else { - if (yych == ' ') goto yy278; - goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + default: goto yy57; } yy323: - YYDEBUG(323, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy278; - if (yych == '\t') goto yy278; - goto yy223; - } else { - if (yych <= '(') { - if (yych <= ' ') goto yy278; - goto yy223; - } else { - if (yych <= ')') goto yy228; - if (yych <= ',') goto yy223; - goto yy244; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '.') goto yy322; - if (yych <= '/') goto yy244; - if (yych <= '@') goto yy223; - goto yy238; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy223; - goto yy244; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy243; - goto yy223; - } - } + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case '.': goto yy322; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy238; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy243; + default: goto yy223; } yy324: - YYDEBUG(324, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy283; - if (yych <= 0x1F) goto yy199; - goto yy283; - } else { - if (yych <= '.') { - if (yych <= '-') goto yy199; - goto yy267; - } else { - if (yych <= '/') goto yy199; - if (yych <= '9') goto yy289; - goto yy267; - } - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy285; - if (yych <= 'O') goto yy199; - goto yy285; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy199; - goto yy285; - } else { - if (yych == 'p') goto yy285; - goto yy199; - } - } + switch (yych) { + case '\t': + case ' ': goto yy283; + case '.': + case ':': goto yy267; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + case 'A': + case 'P': + case 'a': + case 'p': goto yy285; + default: goto yy199; } yy325: - YYDEBUG(325, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy283; - if (yych <= 0x1F) goto yy199; - goto yy283; - } else { - if (yych <= '.') { - if (yych <= '-') goto yy199; - } else { - if (yych <= '/') goto yy199; - if (yych <= '9') goto yy289; - } - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy285; - if (yych <= 'O') goto yy199; - goto yy285; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy199; - goto yy285; - } else { - if (yych == 'p') goto yy285; - goto yy199; - } - } + switch (yych) { + case '\t': + case ' ': goto yy283; + case '.': + case ':': goto yy326; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + case 'A': + case 'P': + case 'a': + case 'p': goto yy285; + default: goto yy199; } yy326: - YYDEBUG(326, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy327; - if (yych <= '6') goto yy328; - if (yych <= '9') goto yy224; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy327; + case '6': goto yy328; + case '7': + case '8': + case '9': goto yy224; + default: goto yy57; + } yy327: - YYDEBUG(327, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy225; - goto yy223; - } else { - if (yych <= '9') goto yy329; - if (yych <= ':') goto yy225; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy225; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy329; + default: goto yy223; } yy328: - YYDEBUG(328, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy225; - goto yy223; - } else { - if (yych <= '0') goto yy270; - if (yych == ':') goto yy225; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy225; + case '0': goto yy270; + default: goto yy223; } yy329: - YYDEBUG(329, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= ' ') { - if (yych == '\t') goto yy272; - if (yych <= 0x1F) goto yy223; - goto yy272; - } else { - if (yych <= '(') { - if (yych <= '\'') goto yy223; - goto yy272; - } else { - if (yych == '+') goto yy272; - goto yy223; - } - } - } else { - if (yych <= ':') { - if (yych <= '-') goto yy272; - if (yych <= '.') goto yy225; - if (yych <= '9') goto yy223; - goto yy225; - } else { - if (yych <= 'Z') { - if (yych <= '@') goto yy223; - goto yy272; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy272; - goto yy223; - } - } + switch (yych) { + case '\t': + case ' ': + case '(': + case '+': + case '-': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy272; + case '.': + case ':': goto yy225; + default: goto yy223; } yy330: - YYDEBUG(330, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy283; - if (yych <= 0x1F) goto yy199; - goto yy283; - } else { - if (yych <= '.') { - if (yych <= '-') goto yy199; - goto yy311; - } else { - if (yych <= '/') goto yy199; - if (yych <= '9') goto yy289; - goto yy311; - } - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy285; - if (yych <= 'O') goto yy199; - goto yy285; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy199; - goto yy285; - } else { - if (yych == 'p') goto yy285; - goto yy199; - } - } + switch (yych) { + case '\t': + case ' ': goto yy283; + case '.': + case ':': goto yy311; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + case 'A': + case 'P': + case 'a': + case 'p': goto yy285; + default: goto yy199; } yy331: - YYDEBUG(331, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy333; - goto yy334; - } else { - if (yych <= '2') goto yy335; - if (yych <= '5') goto yy336; - if (yych <= '9') goto yy337; - goto yy216; + switch (yych) { + case '0': goto yy333; + case '1': goto yy334; + case '2': goto yy335; + case '3': + case '4': + case '5': goto yy336; + case '6': + case '7': + case '8': + case '9': goto yy337; + default: goto yy216; } yy332: - YYDEBUG(332, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy221; - goto yy57; - } else { - if (yych <= '0') goto yy304; - if (yych <= '9') goto yy305; - if (yych <= ':') goto yy221; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy221; + case '0': goto yy304; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy305; + default: goto yy57; } yy333: - YYDEBUG(333, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy350; - goto yy199; - } else { - if (yych <= '0') goto yy349; - if (yych <= '9') goto yy354; - if (yych <= ':') goto yy350; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy350; + case '0': goto yy349; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy354; + default: goto yy199; } yy334: - YYDEBUG(334, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy338; - goto yy199; - } else { - if (yych <= '2') goto yy354; - if (yych <= '9') goto yy349; - if (yych <= ':') goto yy338; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy338; + case '0': + case '1': + case '2': goto yy354; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy349; + default: goto yy199; } yy335: - YYDEBUG(335, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy338; - goto yy199; - } else { - if (yych <= '4') goto yy349; - if (yych <= '9') goto yy348; - if (yych <= ':') goto yy338; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy338; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy349; + case '5': + case '6': + case '7': + case '8': + case '9': goto yy348; + default: goto yy199; } yy336: - YYDEBUG(336, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy338; - goto yy199; - } else { - if (yych <= '9') goto yy348; - if (yych <= ':') goto yy338; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy338; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy348; + default: goto yy199; } yy337: - YYDEBUG(337, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych != '.') goto yy199; - } else { - if (yych <= '9') goto yy263; - if (yych >= ';') goto yy199; + switch (yych) { + case '.': + case ':': goto yy338; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy263; + default: goto yy199; } yy338: - YYDEBUG(338, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy339; - if (yych <= '6') goto yy340; - if (yych <= '9') goto yy266; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy339; + case '6': goto yy340; + case '7': + case '8': + case '9': goto yy266; + default: goto yy57; + } yy339: - YYDEBUG(339, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy267; - goto yy223; - } else { - if (yych <= '9') goto yy341; - if (yych <= ':') goto yy267; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy267; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy341; + default: goto yy223; } yy340: - YYDEBUG(340, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy267; - goto yy223; - } else { - if (yych <= '0') goto yy229; - if (yych == ':') goto yy267; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy267; + case '0': goto yy229; + default: goto yy223; } yy341: - YYDEBUG(341, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= ' ') { - if (yych == '\t') goto yy343; - if (yych <= 0x1F) goto yy223; - goto yy343; - } else { - if (yych <= '(') { - if (yych <= '\'') goto yy223; - goto yy343; - } else { - if (yych == '+') goto yy343; - goto yy223; - } - } - } else { - if (yych <= ':') { - if (yych <= '-') goto yy343; - if (yych <= '.') goto yy267; - if (yych <= '9') goto yy223; - goto yy267; - } else { - if (yych <= 'Z') { - if (yych <= '@') goto yy223; - goto yy343; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy343; - goto yy223; - } - } + switch (yych) { + case '\t': + case ' ': + case '(': + case '+': + case '-': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy343; + case '.': + case ':': goto yy267; + default: goto yy223; } yy342: - YYDEBUG(342, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; yy343: - YYDEBUG(343, *YYCURSOR); - if (yych <= '@') { - if (yych <= '\'') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy57; - goto yy342; - } else { - if (yych == ' ') goto yy342; - goto yy57; - } - } else { - if (yych <= '+') { - if (yych <= '(') goto yy234; - if (yych <= '*') goto yy57; - goto yy233; - } else { - if (yych == '-') goto yy233; - goto yy57; - } - } - } else { - if (yych <= 'Z') { - if (yych <= 'G') { - if (yych <= 'A') goto yy344; - if (yych <= 'F') goto yy235; - goto yy232; - } else { - if (yych != 'P') goto yy235; - } - } else { - if (yych <= 'o') { - if (yych <= '`') goto yy57; - if (yych <= 'a') goto yy345; - goto yy236; - } else { - if (yych <= 'p') goto yy345; - if (yych <= 'z') goto yy236; - goto yy57; - } - } + switch (yych) { + case '\t': + case ' ': goto yy342; + case '(': goto yy234; + case '+': + case '-': goto yy233; + case 'A': + case 'P': goto yy344; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy235; + case 'G': goto yy232; + case 'a': + case 'p': goto yy345; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy236; + default: goto yy57; } yy344: - YYDEBUG(344, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= '.') goto yy286; - if (yych <= '@') goto yy223; - goto yy237; - } - } else { - if (yych <= '`') { - if (yych <= 'M') goto yy346; - if (yych <= 'Z') goto yy237; - goto yy223; - } else { - if (yych == 'm') goto yy347; - if (yych <= 'z') goto yy242; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '.': goto yy286; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy237; + case 'M': goto yy346; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy242; + case 'm': goto yy347; + default: goto yy223; } yy345: - YYDEBUG(345, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy228; - goto yy223; - } else { - if (yych <= '.') goto yy286; - if (yych <= '@') goto yy223; - goto yy237; - } - } else { - if (yych <= '`') { - if (yych <= 'M') goto yy346; - if (yych <= 'Z') goto yy237; - goto yy223; - } else { - if (yych == 'm') goto yy346; - if (yych <= 'z') goto yy237; - goto yy223; - } + switch (yych) { + case ')': goto yy228; + case '.': goto yy286; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy237; + case 'M': + case 'm': goto yy346; + default: goto yy223; } yy346: - YYDEBUG(346, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ')') { - if (yych <= '\t') { - if (yych <= 0x00) goto yy278; - if (yych <= 0x08) goto yy223; - goto yy278; - } else { - if (yych == ' ') goto yy278; - if (yych <= '(') goto yy223; - goto yy228; - } - } else { - if (yych <= '@') { - if (yych == '.') goto yy288; - goto yy223; - } else { - if (yych <= 'Z') goto yy238; - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy238; - goto yy223; - } + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case ')': goto yy228; + case '.': goto yy288; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy238; + default: goto yy223; } yy347: - YYDEBUG(347, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy278; - if (yych == '\t') goto yy278; - goto yy223; - } else { - if (yych <= '(') { - if (yych <= ' ') goto yy278; - goto yy223; - } else { - if (yych <= ')') goto yy228; - if (yych <= ',') goto yy223; - goto yy244; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '.') goto yy288; - if (yych <= '/') goto yy244; - if (yych <= '@') goto yy223; - goto yy238; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy223; - goto yy244; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy243; - goto yy223; - } - } + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy278; + case ')': goto yy228; + case '-': + case '/': + case '_': goto yy244; + case '.': goto yy288; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy238; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy243; + default: goto yy223; } yy348: - YYDEBUG(348, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy225; - goto yy199; - } else { - if (yych <= '9') goto yy289; - if (yych <= ':') goto yy225; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy225; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + default: goto yy199; } yy349: - YYDEBUG(349, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych != '.') goto yy199; - } else { - if (yych <= '9') goto yy289; - if (yych >= ';') goto yy199; + switch (yych) { + case '.': + case ':': goto yy350; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + default: goto yy199; } yy350: - YYDEBUG(350, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy351; - if (yych <= '6') goto yy352; - if (yych <= '9') goto yy224; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy351; + case '6': goto yy352; + case '7': + case '8': + case '9': goto yy224; + default: goto yy57; + } yy351: - YYDEBUG(351, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy225; - goto yy223; - } else { - if (yych <= '9') goto yy353; - if (yych <= ':') goto yy225; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy225; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy353; + default: goto yy223; } yy352: - YYDEBUG(352, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy225; - goto yy223; - } else { - if (yych <= '0') goto yy229; - if (yych == ':') goto yy225; - goto yy223; + switch (yych) { + case '.': + case ':': goto yy225; + case '0': goto yy229; + default: goto yy223; } yy353: - YYDEBUG(353, *YYCURSOR); yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= ' ') { - if (yych == '\t') goto yy231; - if (yych <= 0x1F) goto yy223; - goto yy231; - } else { - if (yych <= '(') { - if (yych <= '\'') goto yy223; - goto yy231; - } else { - if (yych == '+') goto yy231; - goto yy223; - } - } - } else { - if (yych <= ':') { - if (yych <= '-') goto yy231; - if (yych <= '.') goto yy225; - if (yych <= '9') goto yy223; - goto yy225; - } else { - if (yych <= 'Z') { - if (yych <= '@') goto yy223; - goto yy231; - } else { - if (yych <= '`') goto yy223; - if (yych <= 'z') goto yy231; - goto yy223; - } - } + switch (yych) { + case '\t': + case ' ': + case '(': + case '+': + case '-': + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy231; + case '.': + case ':': goto yy225; + default: goto yy223; } yy354: - YYDEBUG(354, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy338; - goto yy199; - } else { - if (yych <= '9') goto yy289; - if (yych <= ':') goto yy338; - goto yy199; + switch (yych) { + case '.': + case ':': goto yy338; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy289; + default: goto yy199; } yy355: - YYDEBUG(355, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych == '.') goto yy300; - goto yy216; - } else { - if (yych <= '0') goto yy332; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy264; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '.': goto yy300; + case '0': goto yy332; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy264; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy356: - YYDEBUG(356, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych == '.') goto yy300; - goto yy216; - } else { - if (yych <= '0') goto yy332; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy264; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '.': goto yy300; + case '0': goto yy332; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy264; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy357: - YYDEBUG(357, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy360; - goto yy361; - } else { - if (yych <= '2') goto yy368; - if (yych <= '9') goto yy369; - goto yy216; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy212; - if (yych <= 'q') goto yy216; - goto yy213; - } else { - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '0': goto yy360; + case '1': goto yy361; + case '2': goto yy368; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy369; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy358: - YYDEBUG(358, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych <= '0') goto yy360; - goto yy361; - } else { - if (yych <= '2') goto yy368; - if (yych <= '9') goto yy369; - goto yy216; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy212; - if (yych <= 'q') goto yy216; - goto yy213; - } else { - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '0': goto yy360; + case '1': goto yy361; + case '2': goto yy368; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy369; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy359: - YYDEBUG(359, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy216; - if (yych >= '1') goto yy361; - } else { - if (yych <= '2') goto yy209; - if (yych <= '9') goto yy210; - goto yy216; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy212; - if (yych <= 'q') goto yy216; - goto yy213; - } else { - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '0': goto yy360; + case '1': goto yy361; + case '2': goto yy209; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy210; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy360: - YYDEBUG(360, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych <= ',') goto yy216; - if (yych <= '-') goto yy362; - if (yych <= '.') goto yy331; - goto yy216; - } else { - if (yych <= '0') goto yy332; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy221; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '-': goto yy362; + case '.': goto yy331; + case '0': goto yy332; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy221; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy361: - YYDEBUG(361, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych <= ',') goto yy216; - if (yych <= '-') goto yy362; - if (yych <= '.') goto yy300; - goto yy216; - } else { - if (yych <= '0') goto yy301; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy264; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '-': goto yy362; + case '.': goto yy300; + case '0': goto yy301; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy264; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy362: - YYDEBUG(362, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(363, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy363; + default: goto yy57; + } +yy363: ++YYCURSOR; - if ((yych = *YYCURSOR) <= '/') goto yy364; - if (yych <= '9') goto yy365; + switch ((yych = *YYCURSOR)) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy365; + default: goto yy364; + } yy364: - YYDEBUG(364, *YYCURSOR); #line 1510 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pgtextshort"); @@ -6644,644 +10683,1343 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_PG_TEXT; } -#line 6648 "ext/date/lib/parse_date.c" +#line 10687 "" yy365: - YYDEBUG(365, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy364; - if (yych >= ':') goto yy364; - YYDEBUG(366, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy366; + default: goto yy364; + } +yy366: yych = *++YYCURSOR; - if (yych <= '/') goto yy364; - if (yych >= ':') goto yy364; - YYDEBUG(367, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy367; + default: goto yy364; + } +yy367: yych = *++YYCURSOR; goto yy364; yy368: - YYDEBUG(368, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych <= ',') goto yy216; - if (yych <= '-') goto yy362; - if (yych <= '.') goto yy300; - goto yy216; - } else { - if (yych <= '0') goto yy332; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy264; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '-': goto yy362; + case '.': goto yy300; + case '0': goto yy332; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy264; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy369: - YYDEBUG(369, *YYCURSOR); yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '/') { - if (yych <= ',') goto yy216; - if (yych <= '-') goto yy362; - if (yych <= '.') goto yy300; - goto yy216; - } else { - if (yych <= '0') goto yy332; - if (yych <= '1') goto yy302; - if (yych <= '2') goto yy303; - goto yy297; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy264; - if (yych == 'n') goto yy212; - goto yy216; - } else { - if (yych <= 'r') goto yy213; - if (yych <= 's') goto yy211; - if (yych <= 't') goto yy214; - goto yy216; - } + switch (yych) { + case '-': goto yy362; + case '.': goto yy300; + case '0': goto yy332; + case '1': goto yy302; + case '2': goto yy303; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy297; + case ':': goto yy264; + case 'n': goto yy212; + case 'r': goto yy213; + case 's': goto yy211; + case 't': goto yy214; + default: goto yy216; } yy370: - YYDEBUG(370, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'B') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'C') goto yy193; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'b') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'c') goto yy371; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'C': goto yy193; + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'c': goto yy371; + default: goto yy4; } yy371: - YYDEBUG(371, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'D') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'E') goto yy202; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'd') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'e') goto yy373; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'E': goto yy202; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'e': goto yy373; + default: goto yy194; } yy372: - YYDEBUG(372, *YYCURSOR); yych = *++YYCURSOR; - if (yybm[0+yych] & 8) { - goto yy149; + switch (yych) { + case '0': goto yy357; + case '1': + case '2': goto yy358; + case '3': goto yy359; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy149; + default: goto yy196; } - if (yych <= '/') goto yy196; - if (yych <= '0') goto yy357; - if (yych <= '2') goto yy358; - if (yych <= '3') goto yy359; - goto yy196; yy373: - YYDEBUG(373, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'M') goto yy203; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'l') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'm') goto yy374; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'M': goto yy203; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'm': goto yy374; + default: goto yy4; } yy374: - YYDEBUG(374, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'A') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'B') goto yy204; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'b') goto yy375; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'B': goto yy204; + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'b': goto yy375; + default: goto yy4; } yy375: - YYDEBUG(375, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'E') goto yy205; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'e') goto yy376; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'E': goto yy205; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'e': goto yy376; + default: goto yy4; } yy376: - YYDEBUG(376, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy206; - if (yych != 'r') goto yy155; + switch (yych) { + case 'R': goto yy206; + case 'r': goto yy377; + default: goto yy155; + } yy377: - YYDEBUG(377, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '-') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy194; - } else { - if (yych <= ' ') goto yy196; - if (yych <= ',') goto yy194; - } - } else { - if (yych <= '9') { - if (yych == '/') goto yy148; - goto yy196; - } else { - if (yych == '_') goto yy148; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case '-': goto yy378; + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy194; } yy378: - YYDEBUG(378, *YYCURSOR); yych = *++YYCURSOR; - if (yybm[0+yych] & 8) { - goto yy149; + switch (yych) { + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy149; + default: goto yy196; } - goto yy196; yy379: - YYDEBUG(379, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy142; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 't') goto yy380; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'T': + case 't': goto yy380; + default: goto yy4; } yy380: - YYDEBUG(380, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'O') goto yy143; - } - } else { - if (yych <= 'n') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'o') goto yy381; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'O': + case 'o': goto yy381; + default: goto yy194; } yy381: - YYDEBUG(381, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'B') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'A') goto yy144; - } - } else { - if (yych <= 'a') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'b') goto yy382; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'B': + case 'b': goto yy382; + default: goto yy4; } yy382: - YYDEBUG(382, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy145; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'e') goto yy383; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'E': + case 'e': goto yy383; + default: goto yy4; } yy383: - YYDEBUG(383, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Q') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'R') goto yy206; - if (yych == 'r') goto yy206; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'R': + case 'r': goto yy206; + default: goto yy4; } yy384: - YYDEBUG(384, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy380; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 't') goto yy385; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'T': goto yy380; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 't': goto yy385; + default: goto yy4; } yy385: - YYDEBUG(385, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'N') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'O') goto yy381; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'n') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'o') goto yy386; - if (yych <= 'z') goto yy151; - goto yy194; - } - } - } -yy386: - YYDEBUG(386, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'A') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'B') goto yy382; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'b') goto yy387; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'O': goto yy381; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'o': goto yy386; + default: goto yy194; + } +yy386: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'B': goto yy382; + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'b': goto yy387; + default: goto yy4; } yy387: - YYDEBUG(387, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy383; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'e') goto yy388; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'E': goto yy383; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'e': goto yy388; + default: goto yy4; } yy388: - YYDEBUG(388, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'R') goto yy206; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'r') goto yy377; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'R': goto yy206; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'r': goto yy377; + default: goto yy4; } yy389: - YYDEBUG(389, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'G') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'F') goto yy142; - goto yy397; - } - } else { - if (yych <= 'f') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'g') goto yy397; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'G': + case 'g': goto yy397; + default: goto yy4; } yy390: - YYDEBUG(390, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy142; - goto yy394; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'r') goto yy394; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'R': + case 'r': goto yy394; + default: goto yy4; } yy391: - YYDEBUG(391, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'N') goto yy142; - } - } else { - if (yych <= 'n') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'o') goto yy392; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'O': + case 'o': goto yy392; + default: goto yy4; } yy392: - YYDEBUG(392, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= '@') { - if (yych == ')') goto yy140; - } else { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy393; - if (yych <= 'z') goto yy143; + switch ((yych = *YYCURSOR)) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy393; } yy393: - YYDEBUG(393, *YYCURSOR); #line 1566 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("ago"); @@ -7302,1756 +12040,3067 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_AGO; } -#line 7306 "ext/date/lib/parse_date.c" +#line 12044 "" yy394: - YYDEBUG(394, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'I') goto yy143; - } - } else { - if (yych <= 'h') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'i') goto yy395; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'I': + case 'i': goto yy395; + default: goto yy194; } yy395: - YYDEBUG(395, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'K') goto yy144; - } - } else { - if (yych <= 'k') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'l') goto yy396; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'L': + case 'l': goto yy396; + default: goto yy4; } yy396: - YYDEBUG(396, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy194; - } else { - if (yych <= ' ') goto yy196; - if (yych == ')') goto yy140; - goto yy194; - } - } else { - if (yych <= '@') { - if (yych == '/') goto yy194; - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy194; - if (yych <= 'z') goto yy145; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy194; } yy397: - YYDEBUG(397, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'U') goto yy143; - } - } else { - if (yych <= 't') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'u') goto yy398; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'U': + case 'u': goto yy398; + default: goto yy194; } yy398: - YYDEBUG(398, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'R') goto yy144; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 's') goto yy399; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'S': + case 's': goto yy399; + default: goto yy4; } yy399: - YYDEBUG(399, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy145; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 't') goto yy400; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'T': + case 't': goto yy400; + default: goto yy4; } yy400: - YYDEBUG(400, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '.') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy196; - } else { - if (yych <= '/') goto yy194; - if (yych <= '9') goto yy196; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + default: goto yy194; } yy401: - YYDEBUG(401, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'F') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'G') goto yy397; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'f') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'g') goto yy408; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'G': goto yy397; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'g': goto yy408; + default: goto yy4; } yy402: - YYDEBUG(402, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy394; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'r') goto yy405; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'R': goto yy394; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'r': goto yy405; + default: goto yy4; } yy403: - YYDEBUG(403, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'O') goto yy392; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'n') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'o') goto yy404; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'O': goto yy392; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'o': goto yy404; + default: goto yy4; } yy404: - YYDEBUG(404, *YYCURSOR); yyaccept = 9; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy393; - } else { - if (yych == '.') goto yy393; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy393; - if (yych <= 'Z') goto yy143; - goto yy393; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy393; - if (yych <= 'z') goto yy151; - goto yy393; - } - } -yy405: - YYDEBUG(405, *YYCURSOR); - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'H') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'I') goto yy395; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'h') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'i') goto yy406; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + default: goto yy393; + } +yy405: + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'I': goto yy395; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'i': goto yy406; + default: goto yy194; } yy406: - YYDEBUG(406, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'K') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'L') goto yy396; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'k') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'l') goto yy407; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'L': goto yy396; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'l': goto yy407; + default: goto yy4; } yy407: - YYDEBUG(407, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy194; - goto yy196; - } else { - if (yych <= ')') { - if (yych <= '(') goto yy194; - goto yy140; - } else { - if (yych <= ',') goto yy194; - if (yych <= '-') goto yy378; - goto yy196; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '/') goto yy148; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy194; - goto yy145; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy194; - goto yy148; - } else { - if (yych <= '`') goto yy194; - if (yych <= 'z') goto yy153; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy378; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy194; } yy408: - YYDEBUG(408, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'T') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'U') goto yy398; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 't') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'u') goto yy409; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'U': goto yy398; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'u': goto yy409; + default: goto yy194; } yy409: - YYDEBUG(409, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy399; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 's') goto yy410; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'S': goto yy399; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 's': goto yy410; + default: goto yy4; } yy410: - YYDEBUG(410, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy400; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 't') goto yy411; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'T': goto yy400; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 't': goto yy411; + default: goto yy4; } yy411: - YYDEBUG(411, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= ',') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy194; - } else { - if (yych <= ' ') goto yy196; - if (yych == ')') goto yy140; - goto yy194; - } - } else { - if (yych <= '/') { - if (yych <= '-') goto yy378; - if (yych <= '.') goto yy196; - goto yy148; - } else { - if (yych <= '9') goto yy196; - if (yych == '_') goto yy148; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy378; + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy194; } yy412: - YYDEBUG(412, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'L') goto yy419; - if (yych <= 'M') goto yy142; - goto yy418; - } - } else { - if (yych <= 'l') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'k') goto yy142; - goto yy419; - } else { - if (yych == 'n') goto yy418; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'L': + case 'l': goto yy419; + case 'N': + case 'n': goto yy418; + default: goto yy4; } yy413: - YYDEBUG(413, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy142; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'n') goto yy414; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'N': + case 'n': goto yy414; + default: goto yy4; } yy414: - YYDEBUG(414, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'U') goto yy143; - } - } else { - if (yych <= 't') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'u') goto yy415; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'U': + case 'u': goto yy415; + default: goto yy194; } yy415: - YYDEBUG(415, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy144; - goto yy4; - } else { - if (yych <= 'a') goto yy416; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy416; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy416: - YYDEBUG(416, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy145; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'r') goto yy417; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'R': + case 'r': goto yy417; + default: goto yy4; } yy417: - YYDEBUG(417, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'X') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Y') goto yy206; - if (yych == 'y') goto yy206; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'Y': + case 'y': goto yy206; + default: goto yy4; } yy418: - YYDEBUG(418, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych == 'E') goto yy420; - goto yy143; - } - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'e') goto yy420; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'E': + case 'e': goto yy420; + default: goto yy194; } yy419: - YYDEBUG(419, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'Y') goto yy143; - } - } else { - if (yych <= 'x') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'y') goto yy420; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy143; + case 'Y': + case 'y': goto yy420; + default: goto yy194; } yy420: - YYDEBUG(420, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy194; - } else { - if (yych <= ' ') goto yy196; - if (yych == ')') goto yy140; - goto yy194; - } - } else { - if (yych <= '@') { - if (yych == '/') goto yy194; - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy194; - if (yych <= 'z') goto yy144; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy194; } yy421: - YYDEBUG(421, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych <= '/') goto yy148; - goto yy4; - } else { - if (yych == 'L') goto yy419; - goto yy142; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'N') goto yy418; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'm') { - if (yych == 'l') goto yy428; - goto yy147; - } else { - if (yych <= 'n') goto yy427; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'L': goto yy419; + case 'N': goto yy418; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'l': goto yy428; + case 'n': goto yy427; + default: goto yy4; } yy422: - YYDEBUG(422, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy414; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'n') goto yy423; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'N': goto yy414; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'n': goto yy423; + default: goto yy4; } yy423: - YYDEBUG(423, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'T') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'U') goto yy415; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 't') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'u') goto yy424; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'U': goto yy415; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'u': goto yy424; + default: goto yy194; } yy424: - YYDEBUG(424, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy416; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy425; - if (yych <= 'z') goto yy152; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy416; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': goto yy425; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy425: - YYDEBUG(425, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy417; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'r') goto yy426; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'R': goto yy417; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'r': goto yy426; + default: goto yy4; } yy426: - YYDEBUG(426, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'Y') goto yy206; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'y') goto yy377; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'Y': goto yy206; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy154; + case 'y': goto yy377; + default: goto yy4; } yy427: - YYDEBUG(427, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'D') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'E') goto yy420; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'd') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'e') goto yy429; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'E': goto yy420; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'e': goto yy429; + default: goto yy194; } yy428: - YYDEBUG(428, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'X') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'Y') goto yy420; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'x') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'y') goto yy429; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': goto yy143; + case 'Y': goto yy420; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy151; + case 'y': goto yy429; + default: goto yy194; } yy429: - YYDEBUG(429, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy194; - goto yy196; - } else { - if (yych <= ')') { - if (yych <= '(') goto yy194; - goto yy140; - } else { - if (yych <= ',') goto yy194; - if (yych <= '-') goto yy378; - goto yy196; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '/') goto yy148; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy194; - goto yy144; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy194; - goto yy148; - } else { - if (yych <= '`') goto yy194; - if (yych <= 'z') goto yy152; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy378; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy194; } yy430: - YYDEBUG(430, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy4; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy196; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'Z') { - if (yych >= 'J') goto yy142; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy142; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'I': goto yy431; + default: goto yy4; } yy431: - YYDEBUG(431, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy4; - } else { - if (yych <= ' ') goto yy196; - if (yych == ')') goto yy140; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych == '/') goto yy4; - if (yych <= '9') goto yy196; - goto yy4; - } else { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy4; } yy432: - YYDEBUG(432, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy4; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy196; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'Z') { - if (yych >= 'J') goto yy142; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy142; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'I': goto yy433; + default: goto yy4; } - YYDEBUG(433, *YYCURSOR); +yy433: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy4; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy196; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy4; - goto yy143; - } else { - if (yych <= 'Z') { - if (yych >= 'J') goto yy143; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy143; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'I': goto yy434; + default: goto yy4; } - YYDEBUG(434, *YYCURSOR); +yy434: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy4; - } else { - if (yych <= ' ') goto yy196; - if (yych == ')') goto yy140; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych == '/') goto yy4; - if (yych <= '9') goto yy196; - goto yy4; - } else { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy435: - YYDEBUG(435, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy196; - goto yy4; - } else { - if (yych <= ' ') goto yy196; - if (yych == ')') goto yy140; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych == '/') goto yy4; - if (yych <= '9') goto yy196; - goto yy4; - } else { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + default: goto yy4; } yy436: - YYDEBUG(436, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy4; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy196; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'Z') { - if (yych <= 'I') goto yy431; - goto yy142; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy142; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'I': goto yy431; + default: goto yy4; } yy437: - YYDEBUG(437, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '9') { - if (yych <= '/') goto yy4; - goto yy457; - } else { - if (yych <= ':') goto yy163; - if (yych <= 'C') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy4; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy4; - goto yy61; - } else { - if (yych <= 'R') goto yy4; - if (yych <= 'T') goto yy61; - goto yy4; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy4; - if (yych <= 'Y') goto yy61; - goto yy4; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy4; - } else { - if (yych == 'g') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy457; + case ':': goto yy163; + default: goto yy4; } yy438: - YYDEBUG(438, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '4') { - if (yych <= '/') goto yy4; - goto yy457; - } else { - if (yych <= '5') goto yy442; - if (yych <= '9') goto yy443; - goto yy163; - } - } - } else { - if (yych <= 'G') { - if (yych <= 'D') { - if (yych <= 'C') goto yy4; - goto yy61; - } else { - if (yych == 'F') goto yy61; - goto yy4; - } - } else { - if (yych <= 'L') { - if (yych <= 'H') goto yy61; - goto yy4; - } else { - if (yych <= 'M') goto yy61; - if (yych <= 'R') goto yy4; - goto yy61; - } - } - } - } else { - if (yych <= 'g') { - if (yych <= 'Y') { - if (yych == 'W') goto yy61; - if (yych <= 'X') goto yy4; - goto yy61; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy4; - goto yy61; - } else { - if (yych == 'f') goto yy61; - goto yy4; - } - } - } else { - if (yych <= 't') { - if (yych <= 'l') { - if (yych <= 'h') goto yy61; - goto yy4; - } else { - if (yych <= 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy457; + case '5': goto yy442; + case '6': + case '7': + case '8': + case '9': goto yy443; + case ':': goto yy163; + default: goto yy4; } yy439: - YYDEBUG(439, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= 'C') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '5') { - if (yych <= '/') goto yy4; - goto yy442; - } else { - if (yych <= '9') goto yy443; - if (yych <= ':') goto yy163; - goto yy4; - } - } - } else { - if (yych <= 'G') { - if (yych == 'E') goto yy4; - if (yych <= 'F') goto yy61; - goto yy4; - } else { - if (yych <= 'L') { - if (yych <= 'H') goto yy61; - goto yy4; - } else { - if (yych <= 'M') goto yy61; - if (yych <= 'R') goto yy4; - goto yy61; - } - } - } - } else { - if (yych <= 'g') { - if (yych <= 'Y') { - if (yych == 'W') goto yy61; - if (yych <= 'X') goto yy4; - goto yy61; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy4; - goto yy61; - } else { - if (yych == 'f') goto yy61; - goto yy4; - } - } - } else { - if (yych <= 't') { - if (yych <= 'l') { - if (yych <= 'h') goto yy61; - goto yy4; - } else { - if (yych <= 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy442; + case '6': + case '7': + case '8': + case '9': goto yy443; + case ':': goto yy163; + default: goto yy4; } yy440: - YYDEBUG(440, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(441, *YYCURSOR); - if (yybm[0+yych] & 4) { - goto yy58; - } - if (yych <= ',') { - if (yych == '+') goto yy440; - goto yy57; - } else { - if (yych <= '-') goto yy440; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy55; - goto yy57; + switch (yych) { + case '\t': + case ' ': goto yy58; + case '+': + case '-': goto yy440; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy57; } yy442: - YYDEBUG(442, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy456; - if (yych <= 'C') goto yy4; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy4; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy4; - goto yy61; - } else { - if (yych <= 'R') goto yy4; - if (yych <= 'T') goto yy61; - goto yy4; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy4; - if (yych <= 'Y') goto yy61; - goto yy4; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy4; - } else { - if (yych == 'g') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy456; + default: goto yy4; } yy443: - YYDEBUG(443, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy444; - if (yych <= 'C') goto yy4; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy4; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy4; - goto yy61; - } else { - if (yych <= 'R') goto yy4; - if (yych <= 'T') goto yy61; - goto yy4; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy4; - if (yych <= 'Y') goto yy61; - goto yy4; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy4; - } else { - if (yych == 'g') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy444; + default: goto yy4; } yy444: - YYDEBUG(444, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych >= ':') goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy445; + default: goto yy61; + } yy445: - YYDEBUG(445, *YYCURSOR); yych = *++YYCURSOR; - if (yybm[0+yych] & 2) { - goto yy55; + switch (yych) { + case '-': goto yy446; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy61; } - if (yych != '-') goto yy61; yy446: - YYDEBUG(446, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy447; - if (yych <= '1') goto yy448; - goto yy57; + switch (yych) { + case '0': goto yy447; + case '1': goto yy448; + default: goto yy57; + } yy447: - YYDEBUG(447, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy449; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy449; + default: goto yy57; + } yy448: - YYDEBUG(448, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '3') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': goto yy449; + default: goto yy57; + } yy449: - YYDEBUG(449, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '-') goto yy57; - YYDEBUG(450, *YYCURSOR); + switch (yych) { + case '-': goto yy450; + default: goto yy57; + } +yy450: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy451; - if (yych <= '2') goto yy452; - if (yych <= '3') goto yy453; - goto yy57; + switch (yych) { + case '0': goto yy451; + case '1': + case '2': goto yy452; + case '3': goto yy453; + default: goto yy57; + } yy451: - YYDEBUG(451, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy454; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy454; + default: goto yy57; + } yy452: - YYDEBUG(452, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy454; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy454; + default: goto yy57; + } yy453: - YYDEBUG(453, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '2') goto yy57; + switch (yych) { + case '0': + case '1': goto yy454; + default: goto yy57; + } yy454: - YYDEBUG(454, *YYCURSOR); ++YYCURSOR; yy455: - YYDEBUG(455, *YYCURSOR); #line 1280 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("iso8601date4 | iso8601date2 | iso8601dateslash | dateslash"); @@ -9063,284 +15112,165 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 9067 "ext/date/lib/parse_date.c" +#line 15116 "" yy456: - YYDEBUG(456, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy445; - if (yych <= 'C') goto yy4; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy4; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy4; - goto yy61; - } else { - if (yych <= 'R') goto yy4; - if (yych <= 'T') goto yy61; - goto yy4; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy4; - if (yych <= 'Y') goto yy61; - goto yy4; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy4; - } else { - if (yych == 'g') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy445; + default: goto yy4; } yy457: - YYDEBUG(457, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= 'C') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '5') { - if (yych <= '/') goto yy4; - } else { - if (yych <= '9') goto yy456; - if (yych <= ':') goto yy163; - goto yy4; - } - } - } else { - if (yych <= 'G') { - if (yych == 'E') goto yy4; - if (yych <= 'F') goto yy61; - goto yy4; - } else { - if (yych <= 'L') { - if (yych <= 'H') goto yy61; - goto yy4; - } else { - if (yych <= 'M') goto yy61; - if (yych <= 'R') goto yy4; - goto yy61; - } - } - } - } else { - if (yych <= 'g') { - if (yych <= 'Y') { - if (yych == 'W') goto yy61; - if (yych <= 'X') goto yy4; - goto yy61; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy4; - goto yy61; - } else { - if (yych == 'f') goto yy61; - goto yy4; - } - } - } else { - if (yych <= 't') { - if (yych <= 'l') { - if (yych <= 'h') goto yy61; - goto yy4; - } else { - if (yych <= 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy458; + case '6': + case '7': + case '8': + case '9': goto yy456; + case ':': goto yy163; + default: goto yy4; } - YYDEBUG(458, *YYCURSOR); +yy458: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych <= '/') goto yy4; - if (yych <= '9') goto yy459; - if (yych <= 'C') goto yy4; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy4; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy4; - goto yy61; - } else { - if (yych <= 'R') goto yy4; - if (yych <= 'T') goto yy61; - goto yy4; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy4; - if (yych <= 'Y') goto yy61; - goto yy4; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy4; - } else { - if (yych == 'g') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy459; + default: goto yy4; } yy459: - YYDEBUG(459, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 2) { - goto yy55; - } - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy4; - goto yy61; - } else { - if (yych == '-') goto yy446; - if (yych <= 'C') goto yy4; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy4; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy4; - goto yy61; - } else { - if (yych <= 'R') goto yy4; - if (yych <= 'T') goto yy61; - goto yy4; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy4; - if (yych <= 'Y') goto yy61; - goto yy4; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy4; - } else { - if (yych == 'g') goto yy4; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy4; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy4; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy4; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '-': goto yy446; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy4; } yy460: - YYDEBUG(460, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy462; - if (yych <= '0') goto yy736; - if (yych <= '1') goto yy737; - if (yych <= '9') goto yy738; - goto yy462; + switch (yych) { + case '0': goto yy736; + case '1': goto yy737; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy738; + default: goto yy462; + } yy461: - YYDEBUG(461, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); yych = *YYCURSOR; yy462: - YYDEBUG(462, *YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': goto yy461; @@ -9378,154 +15308,100 @@ static int scan(Scanner *s) default: goto yy57; } yy463: - YYDEBUG(463, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'D') { - if (yych == 'A') goto yy127; - goto yy57; - } else { - if (yych <= 'E') goto yy1049; - if (yych <= 'T') goto yy57; - goto yy126; - } - } else { - if (yych <= 'd') { - if (yych == 'a') goto yy127; - goto yy57; - } else { - if (yych <= 'e') goto yy1049; - if (yych == 'u') goto yy126; - goto yy57; - } - } -yy464: - YYDEBUG(464, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '`') { - if (yych <= 'D') { - if (yych == 'A') goto yy127; - goto yy57; - } else { - if (yych <= 'E') goto yy1049; - if (yych == 'U') goto yy126; - goto yy57; - } - } else { - if (yych <= 'e') { - if (yych <= 'a') goto yy127; - if (yych <= 'd') goto yy57; - goto yy1049; - } else { - if (yych <= 's') goto yy57; - if (yych <= 't') goto yy729; - if (yych <= 'u') goto yy126; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy127; + case 'E': + case 'e': goto yy1049; + case 'U': + case 'u': goto yy126; + default: goto yy57; + } +yy464: + yych = *++YYCURSOR; + switch (yych) { + case 'A': + case 'a': goto yy127; + case 'E': + case 'e': goto yy1049; + case 'U': + case 'u': goto yy126; + case 't': goto yy729; + default: goto yy57; } yy465: - YYDEBUG(465, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= 'H') { - if (yych == 'A') goto yy592; - goto yy57; - } else { - if (yych <= 'I') goto yy118; - if (yych <= 'N') goto yy57; - goto yy117; - } - } else { - if (yych <= 'h') { - if (yych == 'a') goto yy592; - goto yy57; - } else { - if (yych <= 'i') goto yy118; - if (yych == 'o') goto yy117; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy592; + case 'I': + case 'i': goto yy118; + case 'O': + case 'o': goto yy117; + default: goto yy57; } yy466: - YYDEBUG(466, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych == 'A') goto yy114; - if (yych <= 'D') goto yy57; - goto yy579; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy114; - } else { - if (yych == 'e') goto yy579; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy114; + case 'E': + case 'e': goto yy579; + default: goto yy57; } yy467: - YYDEBUG(467, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= 'N') { - if (yych == 'E') goto yy595; - goto yy57; - } else { - if (yych <= 'O') goto yy99; - if (yych <= 'Q') goto yy57; - goto yy98; - } - } else { - if (yych <= 'n') { - if (yych == 'e') goto yy595; - goto yy57; - } else { - if (yych <= 'o') goto yy99; - if (yych == 'r') goto yy98; - goto yy57; - } + switch (yych) { + case 'E': + case 'e': goto yy595; + case 'O': + case 'o': goto yy99; + case 'R': + case 'r': goto yy98; + default: goto yy57; } yy468: - YYDEBUG(468, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'H') goto yy70; - if (yych <= 'T') goto yy57; - goto yy71; - } else { - if (yych <= 'h') { - if (yych <= 'g') goto yy57; - goto yy1048; - } else { - if (yych == 'u') goto yy71; - goto yy57; - } + switch (yych) { + case 'H': goto yy70; + case 'U': + case 'u': goto yy71; + case 'h': goto yy1048; + default: goto yy57; } yy469: - YYDEBUG(469, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy742; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy741; - goto yy61; + switch (yych) { + case '-': goto yy742; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy741; + default: goto yy61; + } yy470: - YYDEBUG(470, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'c') { - if (yych == 'O') goto yy530; - goto yy57; - } else { - if (yych <= 'd') goto yy729; - if (yych == 'o') goto yy530; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy530; + case 'd': goto yy729; + default: goto yy57; } yy471: - YYDEBUG(471, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy729; - goto yy57; + switch (yych) { + case 'd': goto yy729; + default: goto yy57; + } yy472: - YYDEBUG(472, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case '0': case '1': @@ -9556,9 +15432,7 @@ static int scan(Scanner *s) default: goto yy57; } yy473: - YYDEBUG(473, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case '0': goto yy616; case '1': goto yy617; @@ -9589,40 +15463,44 @@ static int scan(Scanner *s) default: goto yy578; } yy474: - YYDEBUG(474, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '1') { - if (yych <= '/') goto yy578; - if (yych <= '0') goto yy568; - goto yy569; - } else { - if (yych <= '5') goto yy570; - if (yych <= '9') goto yy571; - goto yy578; + switch (yych) { + case '0': goto yy568; + case '1': goto yy569; + case '2': + case '3': + case '4': + case '5': goto yy570; + case '6': + case '7': + case '8': + case '9': goto yy571; + default: goto yy578; } yy475: - YYDEBUG(475, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '.') goto yy532; - } - } else { - if (yych <= 'U') { - if (yych <= '9') goto yy534; - if (yych == 'I') goto yy567; - } else { - if (yych == 'W') goto yy476; - if (yych <= 'X') goto yy540; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy567; + case 'V': + case 'X': goto yy540; + default: goto yy476; } yy476: - YYDEBUG(476, *YYCURSOR); #line 1409 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenoyearrev"); @@ -9634,147 +15512,133 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_TEXT; } -#line 9638 "ext/date/lib/parse_date.c" +#line 15516 "" yy477: - YYDEBUG(477, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '9') { - if (yych <= '.') goto yy532; - if (yych <= '/') goto yy476; - goto yy534; - } else { - if (yych == 'I') goto yy565; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy565; + default: goto yy476; } yy478: - YYDEBUG(478, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '9') { - if (yych <= '.') goto yy532; - if (yych <= '/') goto yy476; - goto yy534; - } else { - if (yych == 'I') goto yy564; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy564; + default: goto yy476; } yy479: - YYDEBUG(479, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'A') goto yy557; - if (yych <= 'T') goto yy57; - goto yy556; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy557; - } else { - if (yych == 'u') goto yy556; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy557; + case 'U': + case 'u': goto yy556; + default: goto yy57; } yy480: - YYDEBUG(480, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= 'L') { - if (yych == '.') goto yy485; - goto yy57; - } else { - if (yych <= 'M') goto yy486; - if (yych == 'P') goto yy550; - goto yy57; - } - } else { - if (yych <= 'o') { - if (yych <= 'U') goto yy549; - if (yych == 'm') goto yy486; - goto yy57; - } else { - if (yych <= 'p') goto yy550; - if (yych == 'u') goto yy549; - goto yy57; - } + switch (yych) { + case '.': goto yy485; + case 'M': + case 'm': goto yy486; + case 'P': + case 'p': goto yy550; + case 'U': + case 'u': goto yy549; + default: goto yy57; } yy481: - YYDEBUG(481, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy544; - if (yych == 'c') goto yy544; - goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy544; + default: goto yy57; + } yy482: - YYDEBUG(482, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy530; - if (yych == 'o') goto yy530; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy530; + default: goto yy57; + } yy483: - YYDEBUG(483, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy490; - if (yych <= '9') goto yy492; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy490; + case '6': + case '7': + case '8': + case '9': goto yy492; + default: goto yy57; + } yy484: - YYDEBUG(484, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych != '.') goto yy57; - } else { - if (yych <= 'M') goto yy486; - if (yych == 'm') goto yy486; - goto yy57; + switch (yych) { + case '.': goto yy485; + case 'M': + case 'm': goto yy486; + default: goto yy57; } yy485: - YYDEBUG(485, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy486; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy486; + default: goto yy57; + } yy486: - YYDEBUG(486, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy488; - if (yych == '\t') goto yy488; - goto yy57; - } else { - if (yych <= ' ') goto yy488; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy488; + case '.': goto yy487; + default: goto yy57; } - YYDEBUG(487, *YYCURSOR); +yy487: yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy488; - if (yych <= 0x08) goto yy57; - } else { - if (yych != ' ') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy488; + default: goto yy57; } yy488: - YYDEBUG(488, *YYCURSOR); ++YYCURSOR; - YYDEBUG(489, *YYCURSOR); #line 1136 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("timetiny12 | timeshort12 | timelong12"); @@ -9791,19 +15655,26 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIME12; } -#line 9795 "ext/date/lib/parse_date.c" +#line 15659 "" yy490: - YYDEBUG(490, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy493; - } else { - if (yych <= '9') goto yy507; - if (yych <= ':') goto yy493; + switch (yych) { + case '.': + case ':': goto yy493; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy507; + default: goto yy491; } yy491: - YYDEBUG(491, *YYCURSOR); #line 1173 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -9829,316 +15700,326 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIME24_WITH_ZONE; } -#line 9833 "ext/date/lib/parse_date.c" +#line 15704 "" yy492: - YYDEBUG(492, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy493; - if (yych != ':') goto yy491; + switch (yych) { + case '.': + case ':': goto yy493; + default: goto yy491; + } yy493: - YYDEBUG(493, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy494; - if (yych <= '6') goto yy495; - if (yych <= '9') goto yy496; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy494; + case '6': goto yy495; + case '7': + case '8': + case '9': goto yy496; + default: goto yy57; + } yy494: - YYDEBUG(494, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy500; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy500; + default: goto yy491; + } yy495: - YYDEBUG(495, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych == '0') goto yy500; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': goto yy500; + default: goto yy491; + } yy496: - YYDEBUG(496, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych != '.') goto yy491; + switch (yych) { + case '.': goto yy497; + default: goto yy491; + } yy497: - YYDEBUG(497, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy498; + default: goto yy57; + } yy498: - YYDEBUG(498, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(499, *YYCURSOR); - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy498; - goto yy491; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy498; + default: goto yy491; + } yy500: - YYDEBUG(500, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= 0x1F) { - if (yych != '\t') goto yy491; - } else { - if (yych <= ' ') goto yy501; - if (yych == '.') goto yy497; - goto yy491; - } - } else { - if (yych <= '`') { - if (yych <= 'A') goto yy503; - if (yych == 'P') goto yy503; - goto yy491; - } else { - if (yych <= 'a') goto yy503; - if (yych == 'p') goto yy503; - goto yy491; - } + switch (yych) { + case '\t': + case ' ': goto yy501; + case '.': goto yy497; + case 'A': + case 'P': + case 'a': + case 'p': goto yy503; + default: goto yy491; } yy501: - YYDEBUG(501, *YYCURSOR); ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - YYDEBUG(502, *YYCURSOR); - if (yych <= 'A') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy501; - goto yy57; - } else { - if (yych <= ' ') goto yy501; - if (yych <= '@') goto yy57; - } - } else { - if (yych <= '`') { - if (yych != 'P') goto yy57; - } else { - if (yych <= 'a') goto yy503; - if (yych != 'p') goto yy57; - } + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; + switch (yych) { + case '\t': + case ' ': goto yy501; + case 'A': + case 'P': + case 'a': + case 'p': goto yy503; + default: goto yy57; } yy503: - YYDEBUG(503, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych != '.') goto yy57; - } else { - if (yych <= 'M') goto yy505; - if (yych == 'm') goto yy505; - goto yy57; + switch (yych) { + case '.': goto yy504; + case 'M': + case 'm': goto yy505; + default: goto yy57; } - YYDEBUG(504, *YYCURSOR); +yy504: yych = *++YYCURSOR; - if (yych == 'M') goto yy505; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy505; + default: goto yy57; + } yy505: - YYDEBUG(505, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy488; - if (yych == '\t') goto yy488; - goto yy57; - } else { - if (yych <= ' ') goto yy488; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy488; + case '.': goto yy506; + default: goto yy57; } - YYDEBUG(506, *YYCURSOR); +yy506: yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy488; - if (yych <= 0x08) goto yy57; - goto yy488; - } else { - if (yych == ' ') goto yy488; - goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy488; + default: goto yy57; } yy507: - YYDEBUG(507, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy508; - if (yych <= 0x1F) goto yy491; - } else { - if (yych == '.') goto yy493; - if (yych <= '9') goto yy491; - goto yy511; - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy510; - if (yych <= 'O') goto yy491; - goto yy510; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy491; - goto yy510; - } else { - if (yych == 'p') goto yy510; - goto yy491; - } - } + switch (yych) { + case '\t': + case ' ': goto yy508; + case '.': goto yy493; + case ':': goto yy511; + case 'A': + case 'P': + case 'a': + case 'p': goto yy510; + default: goto yy491; } yy508: - YYDEBUG(508, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; - YYDEBUG(509, *YYCURSOR); - if (yych <= 'A') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy508; - goto yy57; - } else { - if (yych <= ' ') goto yy508; - if (yych <= '@') goto yy57; - } - } else { - if (yych <= '`') { - if (yych != 'P') goto yy57; - } else { - if (yych <= 'a') goto yy510; - if (yych != 'p') goto yy57; - } + switch (yych) { + case '\t': + case ' ': goto yy508; + case 'A': + case 'P': + case 'a': + case 'p': goto yy510; + default: goto yy57; } yy510: - YYDEBUG(510, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych == '.') goto yy527; - goto yy57; - } else { - if (yych <= 'M') goto yy528; - if (yych == 'm') goto yy528; - goto yy57; + switch (yych) { + case '.': goto yy527; + case 'M': + case 'm': goto yy528; + default: goto yy57; } yy511: - YYDEBUG(511, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy512; - if (yych <= '6') goto yy513; - if (yych <= '9') goto yy496; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy512; + case '6': goto yy513; + case '7': + case '8': + case '9': goto yy496; + default: goto yy57; + } yy512: - YYDEBUG(512, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy514; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy514; + default: goto yy491; + } yy513: - YYDEBUG(513, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych != '0') goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': goto yy514; + default: goto yy491; + } yy514: - YYDEBUG(514, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy501; - if (yych <= 0x1F) goto yy491; - goto yy501; - } else { - if (yych == '.') goto yy515; - if (yych <= '9') goto yy491; - goto yy516; - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy503; - if (yych <= 'O') goto yy491; - goto yy503; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy491; - goto yy503; - } else { - if (yych == 'p') goto yy503; - goto yy491; - } - } + switch (yych) { + case '\t': + case ' ': goto yy501; + case '.': goto yy515; + case ':': goto yy516; + case 'A': + case 'P': + case 'a': + case 'p': goto yy503; + default: goto yy491; } yy515: - YYDEBUG(515, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy525; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy525; + default: goto yy57; + } yy516: - YYDEBUG(516, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy517; + default: goto yy57; + } yy517: - YYDEBUG(517, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; - YYDEBUG(518, *YYCURSOR); - if (yych <= 'O') { - if (yych <= '9') { - if (yych <= '/') goto yy57; - goto yy517; - } else { - if (yych != 'A') goto yy57; - } - } else { - if (yych <= 'a') { - if (yych <= 'P') goto yy519; - if (yych <= '`') goto yy57; - } else { - if (yych != 'p') goto yy57; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy517; + case 'A': + case 'P': + case 'a': + case 'p': goto yy519; + default: goto yy57; } yy519: - YYDEBUG(519, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych != '.') goto yy57; - } else { - if (yych <= 'M') goto yy521; - if (yych == 'm') goto yy521; - goto yy57; + switch (yych) { + case '.': goto yy520; + case 'M': + case 'm': goto yy521; + default: goto yy57; } - YYDEBUG(520, *YYCURSOR); +yy520: yych = *++YYCURSOR; - if (yych == 'M') goto yy521; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy521; + default: goto yy57; + } yy521: - YYDEBUG(521, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy523; - if (yych == '\t') goto yy523; - goto yy57; - } else { - if (yych <= ' ') goto yy523; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy523; + case '.': goto yy522; + default: goto yy57; } - YYDEBUG(522, *YYCURSOR); +yy522: yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy523; - if (yych <= 0x08) goto yy57; - } else { - if (yych != ' ') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy523; + default: goto yy57; } yy523: - YYDEBUG(523, *YYCURSOR); ++YYCURSOR; - YYDEBUG(524, *YYCURSOR); #line 1153 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("mssqltime"); @@ -10158,112 +16039,120 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIME24_WITH_ZONE; } -#line 10162 "ext/date/lib/parse_date.c" +#line 16043 "" yy525: - YYDEBUG(525, *YYCURSOR); yyaccept = 11; YYMARKER = ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; - YYDEBUG(526, *YYCURSOR); - if (yych <= 'O') { - if (yych <= '9') { - if (yych <= '/') goto yy491; - goto yy525; - } else { - if (yych == 'A') goto yy519; - goto yy491; - } - } else { - if (yych <= 'a') { - if (yych <= 'P') goto yy519; - if (yych <= '`') goto yy491; - goto yy519; - } else { - if (yych == 'p') goto yy519; - goto yy491; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy525; + case 'A': + case 'P': + case 'a': + case 'p': goto yy519; + default: goto yy491; } yy527: - YYDEBUG(527, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy528; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy528; + default: goto yy57; + } yy528: - YYDEBUG(528, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy488; - if (yych == '\t') goto yy488; - goto yy57; - } else { - if (yych <= ' ') goto yy488; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy488; + case '.': goto yy529; + default: goto yy57; } - YYDEBUG(529, *YYCURSOR); +yy529: yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy488; - if (yych <= 0x08) goto yy57; - goto yy488; - } else { - if (yych == ' ') goto yy488; - goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy488; + default: goto yy57; } yy530: - YYDEBUG(530, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'V') goto yy531; - if (yych != 'v') goto yy57; + switch (yych) { + case 'V': + case 'v': goto yy531; + default: goto yy57; + } yy531: - YYDEBUG(531, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych != '\t') goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy536; - if (yych == 'e') goto yy536; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy536; + default: goto yy476; } yy532: - YYDEBUG(532, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4); yych = *YYCURSOR; yy533: - YYDEBUG(533, *YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy532; - if (yych <= 0x1F) goto yy57; - goto yy532; - } else { - if (yych <= '.') { - if (yych <= ',') goto yy57; - goto yy532; - } else { - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + default: goto yy57; } yy534: - YYDEBUG(534, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= '/') goto yy535; - if (yych <= '9') goto yy541; + switch ((yych = *YYCURSOR)) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy541; + default: goto yy535; + } yy535: - YYDEBUG(535, *YYCURSOR); #line 1331 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datefull"); @@ -10277,473 +16166,512 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_FULL; } -#line 10281 "ext/date/lib/parse_date.c" +#line 16170 "" yy536: - YYDEBUG(536, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy537; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy537; + default: goto yy57; + } yy537: - YYDEBUG(537, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy538; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy538; + default: goto yy57; + } yy538: - YYDEBUG(538, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy539; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy539; + default: goto yy57; + } yy539: - YYDEBUG(539, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy540; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy540; + default: goto yy57; + } yy540: - YYDEBUG(540, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy532; - if (yych <= 0x1F) goto yy476; - goto yy532; - } else { - if (yych <= '.') { - if (yych <= ',') goto yy476; - goto yy532; - } else { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + default: goto yy476; } yy541: - YYDEBUG(541, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy535; - if (yych >= ':') goto yy535; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy542; + default: goto yy535; + } yy542: - YYDEBUG(542, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy535; - if (yych >= ':') goto yy535; - YYDEBUG(543, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy543; + default: goto yy535; + } +yy543: yych = *++YYCURSOR; goto yy535; yy544: - YYDEBUG(544, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy545; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy545; + default: goto yy57; + } yy545: - YYDEBUG(545, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'N') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'O') goto yy546; - if (yych != 'o') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'O': + case 'o': goto yy546; + default: goto yy476; } yy546: - YYDEBUG(546, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy547; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy547; + default: goto yy57; + } yy547: - YYDEBUG(547, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy548; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy548; + default: goto yy57; + } yy548: - YYDEBUG(548, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy540; - if (yych == 'r') goto yy540; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy540; + default: goto yy57; + } yy549: - YYDEBUG(549, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy553; - if (yych == 'g') goto yy553; - goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy553; + default: goto yy57; + } yy550: - YYDEBUG(550, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy551; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy551; + default: goto yy57; + } yy551: - YYDEBUG(551, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'I') goto yy552; - if (yych != 'i') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': + case 'i': goto yy552; + default: goto yy476; } yy552: - YYDEBUG(552, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy540; - if (yych == 'l') goto yy540; - goto yy57; + switch (yych) { + case 'L': + case 'l': goto yy540; + default: goto yy57; + } yy553: - YYDEBUG(553, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'T') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'U') goto yy554; - if (yych != 'u') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'U': + case 'u': goto yy554; + default: goto yy476; } yy554: - YYDEBUG(554, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy555; - if (yych != 's') goto yy57; + switch (yych) { + case 'S': + case 's': goto yy555; + default: goto yy57; + } yy555: - YYDEBUG(555, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy540; - if (yych == 't') goto yy540; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy540; + default: goto yy57; + } yy556: - YYDEBUG(556, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'L') goto yy563; - if (yych <= 'M') goto yy57; - goto yy562; - } else { - if (yych <= 'l') { - if (yych <= 'k') goto yy57; - goto yy563; - } else { - if (yych == 'n') goto yy562; - goto yy57; - } + switch (yych) { + case 'L': + case 'l': goto yy563; + case 'N': + case 'n': goto yy562; + default: goto yy57; } yy557: - YYDEBUG(557, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy558; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy558; + default: goto yy57; + } yy558: - YYDEBUG(558, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'T') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'U') goto yy559; - if (yych != 'u') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'U': + case 'u': goto yy559; + default: goto yy476; } yy559: - YYDEBUG(559, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy560; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy560; + default: goto yy57; + } yy560: - YYDEBUG(560, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy561; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy561; + default: goto yy57; + } yy561: - YYDEBUG(561, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy540; - if (yych == 'y') goto yy540; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy540; + default: goto yy57; + } yy562: - YYDEBUG(562, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy540; - if (yych == 'e') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy540; + default: goto yy476; } yy563: - YYDEBUG(563, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'X') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'Y') goto yy540; - if (yych == 'y') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'Y': + case 'y': goto yy540; + default: goto yy476; } yy564: - YYDEBUG(564, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '9') { - if (yych <= '.') goto yy532; - if (yych <= '/') goto yy476; - goto yy534; - } else { - if (yych == 'I') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy540; + default: goto yy476; } yy565: - YYDEBUG(565, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '9') { - if (yych <= '.') goto yy532; - if (yych <= '/') goto yy476; - goto yy534; - } else { - if (yych != 'I') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy566; + default: goto yy476; } - YYDEBUG(566, *YYCURSOR); +yy566: yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '9') { - if (yych <= '.') goto yy532; - if (yych <= '/') goto yy476; - goto yy534; - } else { - if (yych == 'I') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy540; + default: goto yy476; } yy567: - YYDEBUG(567, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '9') { - if (yych <= '.') goto yy532; - if (yych <= '/') goto yy476; - goto yy534; - } else { - if (yych == 'I') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': goto yy540; + default: goto yy476; } yy568: - YYDEBUG(568, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - goto yy601; - } else { - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy615; - if (yych <= ':') goto yy493; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy601; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy615; + case ':': goto yy493; + default: goto yy491; } yy569: - YYDEBUG(569, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - if (yych <= '.') goto yy601; - goto yy491; - } else { - if (yych <= '2') goto yy615; - if (yych <= '9') goto yy614; - if (yych <= ':') goto yy493; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy601; + case '0': + case '1': + case '2': goto yy615; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy614; + case ':': goto yy493; + default: goto yy491; } yy570: - YYDEBUG(570, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - goto yy601; - } else { - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy614; - if (yych <= ':') goto yy493; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy601; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy614; + case ':': goto yy493; + default: goto yy491; } yy571: - YYDEBUG(571, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - goto yy601; - } else { - if (yych == ':') goto yy493; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy601; + case ':': goto yy493; + default: goto yy491; } yy572: - YYDEBUG(572, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy595; - if (yych == 'e') goto yy595; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy595; + default: goto yy57; + } yy573: - YYDEBUG(573, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy592; - if (yych == 'a') goto yy592; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy592; + default: goto yy57; + } yy574: - YYDEBUG(574, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'P') goto yy550; - if (yych <= 'T') goto yy57; - goto yy549; - } else { - if (yych <= 'p') { - if (yych <= 'o') goto yy57; - goto yy550; - } else { - if (yych == 'u') goto yy549; - goto yy57; - } + switch (yych) { + case 'P': + case 'p': goto yy550; + case 'U': + case 'u': goto yy549; + default: goto yy57; } yy575: - YYDEBUG(575, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy585; - if (yych == 'e') goto yy585; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy585; + default: goto yy57; + } yy576: - YYDEBUG(576, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy579; - if (yych == 'e') goto yy579; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy579; + default: goto yy57; + } yy577: - YYDEBUG(577, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); yych = *YYCURSOR; yy578: - YYDEBUG(578, *YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': @@ -10771,249 +16699,313 @@ static int scan(Scanner *s) default: goto yy57; } yy579: - YYDEBUG(579, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy580; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy580; + default: goto yy57; + } yy580: - YYDEBUG(580, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy581; - if (yych != 'e') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy581; + default: goto yy476; } yy581: - YYDEBUG(581, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy582; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy582; + default: goto yy57; + } yy582: - YYDEBUG(582, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy583; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy583; + default: goto yy57; + } yy583: - YYDEBUG(583, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy584; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy584; + default: goto yy57; + } yy584: - YYDEBUG(584, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy540; - if (yych == 'r') goto yy540; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy540; + default: goto yy57; + } yy585: - YYDEBUG(585, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy586; - if (yych != 'p') goto yy57; + switch (yych) { + case 'P': + case 'p': goto yy586; + default: goto yy57; + } yy586: - YYDEBUG(586, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'S') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'T') goto yy587; - if (yych != 't') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'T': + case 't': goto yy587; + default: goto yy476; } yy587: - YYDEBUG(587, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy588; - if (yych != 'e') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy588; + default: goto yy476; } yy588: - YYDEBUG(588, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy589; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy589; + default: goto yy57; + } yy589: - YYDEBUG(589, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy590; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy590; + default: goto yy57; + } yy590: - YYDEBUG(590, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy591; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy591; + default: goto yy57; + } yy591: - YYDEBUG(591, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy540; - if (yych == 'r') goto yy540; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy540; + default: goto yy57; + } yy592: - YYDEBUG(592, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych == 'R') goto yy593; - if (yych <= 'X') goto yy57; - goto yy540; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy57; - } else { - if (yych == 'y') goto yy540; - goto yy57; - } + switch (yych) { + case 'R': + case 'r': goto yy593; + case 'Y': + case 'y': goto yy540; + default: goto yy57; } yy593: - YYDEBUG(593, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'B') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'C') goto yy594; - if (yych != 'c') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'C': + case 'c': goto yy594; + default: goto yy476; } yy594: - YYDEBUG(594, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy540; - if (yych == 'h') goto yy540; - goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy540; + default: goto yy57; + } yy595: - YYDEBUG(595, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy596; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy596; + default: goto yy57; + } yy596: - YYDEBUG(596, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - goto yy532; - } - } else { - if (yych <= 'Q') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'R') goto yy597; - if (yych != 'r') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy532; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'R': + case 'r': goto yy597; + default: goto yy476; } yy597: - YYDEBUG(597, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy598; - if (yych != 'u') goto yy57; + switch (yych) { + case 'U': + case 'u': goto yy598; + default: goto yy57; + } yy598: - YYDEBUG(598, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy599; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy599; + default: goto yy57; + } yy599: - YYDEBUG(599, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy600; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy600; + default: goto yy57; + } yy600: - YYDEBUG(600, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy540; - if (yych == 'y') goto yy540; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy540; + default: goto yy57; + } yy601: - YYDEBUG(601, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy608; - if (yych <= '6') goto yy609; - if (yych <= '9') goto yy610; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy608; + case '6': goto yy609; + case '7': + case '8': + case '9': goto yy610; + default: goto yy57; + } yy602: - YYDEBUG(602, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(603, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy603; + default: goto yy57; + } +yy603: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy604; + default: goto yy57; + } yy604: - YYDEBUG(604, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy605; + default: goto yy57; + } yy605: - YYDEBUG(605, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(606, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy606; + default: goto yy57; + } +yy606: ++YYCURSOR; - YYDEBUG(607, *YYCURSOR); #line 1345 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pointed date YYYY"); @@ -11025,42 +17017,75 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_FULL_POINTED; } -#line 11029 "ext/date/lib/parse_date.c" +#line 17021 "" yy608: - YYDEBUG(608, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy613; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy613; + default: goto yy491; + } yy609: - YYDEBUG(609, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy497; - goto yy491; - } else { - if (yych <= '0') goto yy613; - if (yych <= '9') goto yy611; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': goto yy613; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy611; + default: goto yy491; } yy610: - YYDEBUG(610, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych >= ':') goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy611; + default: goto yy491; + } yy611: - YYDEBUG(611, *YYCURSOR); yyaccept = 12; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') goto yy612; - if (yych <= '9') goto yy605; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy605; + default: goto yy612; + } yy612: - YYDEBUG(612, *YYCURSOR); #line 1357 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pointed date YY"); @@ -11073,647 +17098,616 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_FULL_POINTED; } -#line 11077 "ext/date/lib/parse_date.c" +#line 17102 "" yy613: - YYDEBUG(613, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= ' ') { - if (yych == '\t') goto yy501; - if (yych <= 0x1F) goto yy491; - goto yy501; - } else { - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - goto yy605; - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy503; - if (yych <= 'O') goto yy491; - goto yy503; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy491; - goto yy503; - } else { - if (yych == 'p') goto yy503; - goto yy491; - } - } + switch (yych) { + case '\t': + case ' ': goto yy501; + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy605; + case 'A': + case 'P': + case 'a': + case 'p': goto yy503; + default: goto yy491; } yy614: - YYDEBUG(614, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy508; - if (yych <= 0x1F) goto yy491; - goto yy508; - } else { - if (yych == '.') goto yy493; - if (yych <= '9') goto yy491; - goto yy493; - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy510; - if (yych <= 'O') goto yy491; - goto yy510; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy491; - goto yy510; - } else { - if (yych == 'p') goto yy510; - goto yy491; - } - } + switch (yych) { + case '\t': + case ' ': goto yy508; + case '.': + case ':': goto yy493; + case 'A': + case 'P': + case 'a': + case 'p': goto yy510; + default: goto yy491; } yy615: - YYDEBUG(615, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ':') { - if (yych <= ' ') { - if (yych == '\t') goto yy508; - if (yych <= 0x1F) goto yy491; - goto yy508; - } else { - if (yych <= '-') { - if (yych <= ',') goto yy491; - goto yy602; - } else { - if (yych <= '.') goto yy601; - if (yych <= '9') goto yy491; - goto yy493; - } - } - } else { - if (yych <= 'P') { - if (yych == 'A') goto yy510; - if (yych <= 'O') goto yy491; - goto yy510; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy491; - goto yy510; - } else { - if (yych == 'p') goto yy510; - goto yy491; - } - } + switch (yych) { + case '\t': + case ' ': goto yy508; + case '-': goto yy602; + case '.': goto yy601; + case ':': goto yy493; + case 'A': + case 'P': + case 'a': + case 'p': goto yy510; + default: goto yy491; } yy616: - YYDEBUG(616, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy655; - goto yy602; - } else { - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy618; - goto yy57; + switch (yych) { + case '-': goto yy655; + case '.': goto yy602; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy618; + default: goto yy57; } yy617: - YYDEBUG(617, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy655; - goto yy602; - } else { - if (yych <= '/') goto yy57; - if (yych >= '3') goto yy57; + switch (yych) { + case '-': goto yy655; + case '.': goto yy602; + case '0': + case '1': + case '2': goto yy618; + default: goto yy57; } yy618: - YYDEBUG(618, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy655; - if (yych <= '.') goto yy602; - goto yy57; + switch (yych) { + case '-': goto yy655; + case '.': goto yy602; + default: goto yy57; + } yy619: - YYDEBUG(619, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'A') goto yy651; - if (yych <= 'T') goto yy57; - goto yy650; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy651; - } else { - if (yych == 'u') goto yy650; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy651; + case 'U': + case 'u': goto yy650; + default: goto yy57; } yy620: - YYDEBUG(620, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy648; - if (yych == 'e') goto yy648; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy648; + default: goto yy57; + } yy621: - YYDEBUG(621, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy645; - if (yych == 'a') goto yy645; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy645; + default: goto yy57; + } yy622: - YYDEBUG(622, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'P') goto yy642; - if (yych <= 'T') goto yy57; - goto yy641; - } else { - if (yych <= 'p') { - if (yych <= 'o') goto yy57; - goto yy642; - } else { - if (yych == 'u') goto yy641; - goto yy57; - } + switch (yych) { + case 'P': + case 'p': goto yy642; + case 'U': + case 'u': goto yy641; + default: goto yy57; } yy623: - YYDEBUG(623, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy638; - if (yych == 'e') goto yy638; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy638; + default: goto yy57; + } yy624: - YYDEBUG(624, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy636; - if (yych == 'c') goto yy636; - goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy636; + default: goto yy57; + } yy625: - YYDEBUG(625, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy634; - if (yych == 'o') goto yy634; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy634; + default: goto yy57; + } yy626: - YYDEBUG(626, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy627; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy627; + default: goto yy57; + } yy627: - YYDEBUG(627, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy628; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy628; + default: goto yy57; + } yy628: - YYDEBUG(628, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych >= '.') goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy581; - if (yych == 'e') goto yy581; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy581; + default: goto yy476; } yy629: - YYDEBUG(629, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy533; - if (yych <= '0') goto yy630; - if (yych <= '2') goto yy631; - if (yych <= '3') goto yy632; - goto yy533; + switch (yych) { + case '0': goto yy630; + case '1': + case '2': goto yy631; + case '3': goto yy632; + default: goto yy533; + } yy630: - YYDEBUG(630, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy535; - if (yych <= '9') goto yy633; - goto yy535; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy633; + default: goto yy535; + } yy631: - YYDEBUG(631, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy535; - if (yych <= '9') goto yy633; - goto yy535; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy633; + default: goto yy535; + } yy632: - YYDEBUG(632, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy535; - if (yych <= '1') goto yy633; - if (yych <= '9') goto yy541; - goto yy535; + switch (yych) { + case '0': + case '1': goto yy633; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy541; + default: goto yy535; + } yy633: - YYDEBUG(633, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy535; - if (yych <= '9') goto yy542; - goto yy535; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy542; + default: goto yy535; + } yy634: - YYDEBUG(634, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'V') goto yy635; - if (yych != 'v') goto yy57; + switch (yych) { + case 'V': + case 'v': goto yy635; + default: goto yy57; + } yy635: - YYDEBUG(635, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy536; - if (yych == 'e') goto yy536; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy536; + default: goto yy476; } yy636: - YYDEBUG(636, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy637; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy637; + default: goto yy57; + } yy637: - YYDEBUG(637, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'N') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'O') goto yy546; - if (yych == 'o') goto yy546; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'O': + case 'o': goto yy546; + default: goto yy476; } yy638: - YYDEBUG(638, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy639; - if (yych != 'p') goto yy57; + switch (yych) { + case 'P': + case 'p': goto yy639; + default: goto yy57; + } yy639: - YYDEBUG(639, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'S') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'T') goto yy640; - if (yych != 't') goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'T': + case 't': goto yy640; + default: goto yy476; } yy640: - YYDEBUG(640, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy588; - if (yych == 'e') goto yy588; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy588; + default: goto yy476; } yy641: - YYDEBUG(641, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy644; - if (yych == 'g') goto yy644; - goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy644; + default: goto yy57; + } yy642: - YYDEBUG(642, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy643; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy643; + default: goto yy57; + } yy643: - YYDEBUG(643, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'H') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'I') goto yy552; - if (yych == 'i') goto yy552; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'I': + case 'i': goto yy552; + default: goto yy476; } yy644: - YYDEBUG(644, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'T') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'U') goto yy554; - if (yych == 'u') goto yy554; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'U': + case 'u': goto yy554; + default: goto yy476; } yy645: - YYDEBUG(645, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych == 'R') goto yy646; - if (yych <= 'X') goto yy57; - goto yy647; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy57; - } else { - if (yych == 'y') goto yy647; - goto yy57; - } + switch (yych) { + case 'R': + case 'r': goto yy646; + case 'Y': + case 'y': goto yy647; + default: goto yy57; } yy646: - YYDEBUG(646, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'B') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'C') goto yy594; - if (yych == 'c') goto yy594; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'C': + case 'c': goto yy594; + default: goto yy476; } yy647: - YYDEBUG(647, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy476; - goto yy532; - } else { - if (yych == ' ') goto yy532; - goto yy476; - } - } else { - if (yych <= '.') { - if (yych <= '-') goto yy629; - goto yy532; - } else { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + default: goto yy476; } yy648: - YYDEBUG(648, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy649; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy649; + default: goto yy57; + } yy649: - YYDEBUG(649, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'Q') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'R') goto yy597; - if (yych == 'r') goto yy597; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'R': + case 'r': goto yy597; + default: goto yy476; } yy650: - YYDEBUG(650, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'L') goto yy654; - if (yych <= 'M') goto yy57; - goto yy653; - } else { - if (yych <= 'l') { - if (yych <= 'k') goto yy57; - goto yy654; - } else { - if (yych == 'n') goto yy653; - goto yy57; - } + switch (yych) { + case 'L': + case 'l': goto yy654; + case 'N': + case 'n': goto yy653; + default: goto yy57; } yy651: - YYDEBUG(651, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy652; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy652; + default: goto yy57; + } yy652: - YYDEBUG(652, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'T') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'U') goto yy559; - if (yych == 'u') goto yy559; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'U': + case 'u': goto yy559; + default: goto yy476; } yy653: - YYDEBUG(653, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'D') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'E') goto yy540; - if (yych == 'e') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'E': + case 'e': goto yy540; + default: goto yy476; } yy654: - YYDEBUG(654, *YYCURSOR); yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy532; - goto yy476; - } else { - if (yych <= ' ') goto yy532; - if (yych <= ',') goto yy476; - if (yych <= '-') goto yy629; - goto yy532; - } - } else { - if (yych <= 'X') { - if (yych <= '/') goto yy476; - if (yych <= '9') goto yy534; - goto yy476; - } else { - if (yych <= 'Y') goto yy540; - if (yych == 'y') goto yy540; - goto yy476; - } + switch (yych) { + case '\t': + case ' ': + case '.': goto yy532; + case '-': goto yy629; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy534; + case 'Y': + case 'y': goto yy540; + default: goto yy476; } yy655: - YYDEBUG(655, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy656; - if (yych <= '3') goto yy658; - if (yych <= '9') goto yy659; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': goto yy656; + case '3': goto yy658; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy659; + default: goto yy57; + } yy656: - YYDEBUG(656, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy665; - if (yych >= 'n') goto yy661; - } else { - if (yych <= 'r') { - if (yych >= 'r') goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy665; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy657: - YYDEBUG(657, *YYCURSOR); #line 1318 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("gnudateshort"); @@ -11726,112 +17720,116 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 11730 "ext/date/lib/parse_date.c" +#line 17724 "" yy658: - YYDEBUG(658, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '1') { - if (yych <= '/') goto yy657; - goto yy665; - } else { - if (yych <= '9') goto yy604; - if (yych <= 'm') goto yy657; - goto yy661; - } - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': goto yy665; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy604; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy659: - YYDEBUG(659, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy604; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy604; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy660: - YYDEBUG(660, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 't') goto yy664; - goto yy57; + switch (yych) { + case 't': goto yy664; + default: goto yy57; + } yy661: - YYDEBUG(661, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy664; - goto yy57; + switch (yych) { + case 'd': goto yy664; + default: goto yy57; + } yy662: - YYDEBUG(662, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy664; - goto yy57; + switch (yych) { + case 'd': goto yy664; + default: goto yy57; + } yy663: - YYDEBUG(663, *YYCURSOR); yych = *++YYCURSOR; - if (yych != 'h') goto yy57; + switch (yych) { + case 'h': goto yy664; + default: goto yy57; + } yy664: - YYDEBUG(664, *YYCURSOR); yych = *++YYCURSOR; goto yy657; yy665: - YYDEBUG(665, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy605; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy605; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy666: - YYDEBUG(666, *YYCURSOR); yyaccept = 14; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') { - if (yych >= '/') goto yy723; - } else { - if (yych <= '9') goto yy669; - if (yych >= 'n') goto yy720; - } - } else { - if (yych <= 'r') { - if (yych >= 'r') goto yy721; - } else { - if (yych <= 's') goto yy719; - if (yych <= 't') goto yy722; - } + switch (yych) { + case '/': goto yy723; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy669; + case 'n': goto yy720; + case 'r': goto yy721; + case 's': goto yy719; + case 't': goto yy722; + default: goto yy667; } yy667: - YYDEBUG(667, *YYCURSOR); #line 1265 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("americanshort | american"); @@ -11846,239 +17844,331 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_AMERICAN; } -#line 11850 "ext/date/lib/parse_date.c" +#line 17848 "" yy668: - YYDEBUG(668, *YYCURSOR); yyaccept = 14; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') { - if (yych <= '.') goto yy667; - goto yy723; - } else { - if (yych <= '1') goto yy669; - if (yych <= 'm') goto yy667; - goto yy720; - } - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy667; - goto yy721; - } else { - if (yych <= 's') goto yy719; - if (yych <= 't') goto yy722; - goto yy667; - } + switch (yych) { + case '/': goto yy723; + case '0': + case '1': goto yy669; + case 'n': goto yy720; + case 'r': goto yy721; + case 's': goto yy719; + case 't': goto yy722; + default: goto yy667; } yy669: - YYDEBUG(669, *YYCURSOR); yyaccept = 14; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych == '/') goto yy723; - if (yych <= 'm') goto yy667; - goto yy720; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy667; - goto yy721; - } else { - if (yych <= 's') goto yy719; - if (yych <= 't') goto yy722; - goto yy667; - } + switch (yych) { + case '/': goto yy723; + case 'n': goto yy720; + case 'r': goto yy721; + case 's': goto yy719; + case 't': goto yy722; + default: goto yy667; } yy670: - YYDEBUG(670, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'A') goto yy718; - if (yych <= 'T') goto yy57; - goto yy717; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy718; - } else { - if (yych == 'u') goto yy717; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy718; + case 'U': + case 'u': goto yy717; + default: goto yy57; } yy671: - YYDEBUG(671, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy716; - if (yych == 'e') goto yy716; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy716; + default: goto yy57; + } yy672: - YYDEBUG(672, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy715; - if (yych == 'a') goto yy715; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy715; + default: goto yy57; + } yy673: - YYDEBUG(673, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'P') goto yy714; - if (yych <= 'T') goto yy57; - goto yy713; - } else { - if (yych <= 'p') { - if (yych <= 'o') goto yy57; - goto yy714; - } else { - if (yych == 'u') goto yy713; - goto yy57; - } + switch (yych) { + case 'P': + case 'p': goto yy714; + case 'U': + case 'u': goto yy713; + default: goto yy57; } yy674: - YYDEBUG(674, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy711; - if (yych == 'e') goto yy711; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy711; + default: goto yy57; + } yy675: - YYDEBUG(675, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy710; - if (yych == 'c') goto yy710; - goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy710; + default: goto yy57; + } yy676: - YYDEBUG(676, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy709; - if (yych == 'o') goto yy709; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy709; + default: goto yy57; + } yy677: - YYDEBUG(677, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy678; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy678; + default: goto yy57; + } yy678: - YYDEBUG(678, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy679; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy679; + default: goto yy57; + } yy679: - YYDEBUG(679, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '/') goto yy57; + switch (yych) { + case '/': goto yy680; + default: goto yy57; + } yy680: - YYDEBUG(680, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(681, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy681; + default: goto yy57; + } +yy681: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(682, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy682; + default: goto yy57; + } +yy682: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(683, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy683; + default: goto yy57; + } +yy683: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(684, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy684; + default: goto yy57; + } +yy684: yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(685, *YYCURSOR); + switch (yych) { + case ':': goto yy685; + default: goto yy57; + } +yy685: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy686; - if (yych <= '2') goto yy687; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy686; + case '2': goto yy687; + default: goto yy57; + } yy686: - YYDEBUG(686, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy688; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy688; + default: goto yy57; + } yy687: - YYDEBUG(687, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '5') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy688; + default: goto yy57; + } yy688: - YYDEBUG(688, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(689, *YYCURSOR); + switch (yych) { + case ':': goto yy689; + default: goto yy57; + } +yy689: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '6') goto yy57; - YYDEBUG(690, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy690; + default: goto yy57; + } +yy690: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(691, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy691; + default: goto yy57; + } +yy691: yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(692, *YYCURSOR); + switch (yych) { + case ':': goto yy692; + default: goto yy57; + } +yy692: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy693; - if (yych <= '6') goto yy694; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy693; + case '6': goto yy694; + default: goto yy57; + } yy693: - YYDEBUG(693, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy695; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy695; + default: goto yy57; + } yy694: - YYDEBUG(694, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '0') goto yy57; + switch (yych) { + case '0': goto yy695; + default: goto yy57; + } yy695: - YYDEBUG(695, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\t') goto yy696; - if (yych != ' ') goto yy57; + switch (yych) { + case '\t': + case ' ': goto yy696; + default: goto yy57; + } yy696: - YYDEBUG(696, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; - YYDEBUG(697, *YYCURSOR); - if (yych <= '*') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy57; - goto yy696; - } else { - if (yych == ' ') goto yy696; - goto yy57; - } - } else { - if (yych <= '-') { - if (yych == ',') goto yy57; - goto yy699; - } else { - if (yych != 'G') goto yy57; - } + switch (yych) { + case '\t': + case ' ': goto yy696; + case '+': + case '-': goto yy699; + case 'G': goto yy698; + default: goto yy57; } - YYDEBUG(698, *YYCURSOR); +yy698: yych = *++YYCURSOR; - if (yych == 'M') goto yy707; - goto yy57; + switch (yych) { + case 'M': goto yy707; + default: goto yy57; + } yy699: - YYDEBUG(699, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy700; - if (yych <= '2') goto yy702; - if (yych <= '9') goto yy703; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy700; + case '2': goto yy702; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy703; + default: goto yy57; + } yy700: - YYDEBUG(700, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= '/') goto yy701; - if (yych <= '9') goto yy703; - if (yych <= ':') goto yy704; + switch ((yych = *YYCURSOR)) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy703; + case ':': goto yy704; + default: goto yy701; + } yy701: - YYDEBUG(701, *YYCURSOR); #line 1536 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -12099,195 +18189,265 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_CLF; } -#line 12103 "ext/date/lib/parse_date.c" +#line 18193 "" yy702: - YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '5') { - if (yych <= '/') goto yy701; - if (yych >= '5') goto yy705; - } else { - if (yych <= '9') goto yy706; - if (yych <= ':') goto yy704; - goto yy701; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy703; + case '5': goto yy705; + case '6': + case '7': + case '8': + case '9': goto yy706; + case ':': goto yy704; + default: goto yy701; } yy703: - YYDEBUG(703, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy701; - if (yych <= '5') goto yy705; - if (yych <= '9') goto yy706; - if (yych >= ';') goto yy701; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy705; + case '6': + case '7': + case '8': + case '9': goto yy706; + case ':': goto yy704; + default: goto yy701; + } yy704: - YYDEBUG(704, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy701; - if (yych <= '5') goto yy705; - if (yych <= '9') goto yy706; - goto yy701; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy705; + case '6': + case '7': + case '8': + case '9': goto yy706; + default: goto yy701; + } yy705: - YYDEBUG(705, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy701; - if (yych >= ':') goto yy701; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy706; + default: goto yy701; + } yy706: - YYDEBUG(706, *YYCURSOR); yych = *++YYCURSOR; goto yy701; yy707: - YYDEBUG(707, *YYCURSOR); yych = *++YYCURSOR; - if (yych != 'T') goto yy57; - YYDEBUG(708, *YYCURSOR); + switch (yych) { + case 'T': goto yy708; + default: goto yy57; + } +yy708: yych = *++YYCURSOR; - if (yych == '+') goto yy699; - if (yych == '-') goto yy699; - goto yy57; + switch (yych) { + case '+': + case '-': goto yy699; + default: goto yy57; + } yy709: - YYDEBUG(709, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'V') goto yy679; - if (yych == 'v') goto yy679; - goto yy57; + switch (yych) { + case 'V': + case 'v': goto yy679; + default: goto yy57; + } yy710: - YYDEBUG(710, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy679; - if (yych == 't') goto yy679; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy679; + default: goto yy57; + } yy711: - YYDEBUG(711, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy712; - if (yych != 'p') goto yy57; + switch (yych) { + case 'P': + case 'p': goto yy712; + default: goto yy57; + } yy712: - YYDEBUG(712, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych == '/') goto yy680; - goto yy57; - } else { - if (yych <= 'T') goto yy679; - if (yych == 't') goto yy679; - goto yy57; + switch (yych) { + case '/': goto yy680; + case 'T': + case 't': goto yy679; + default: goto yy57; } yy713: - YYDEBUG(713, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy679; - if (yych == 'g') goto yy679; - goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy679; + default: goto yy57; + } yy714: - YYDEBUG(714, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy679; - if (yych == 'r') goto yy679; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy679; + default: goto yy57; + } yy715: - YYDEBUG(715, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych == 'R') goto yy679; - if (yych <= 'X') goto yy57; - goto yy679; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy57; - goto yy679; - } else { - if (yych == 'y') goto yy679; - goto yy57; - } + switch (yych) { + case 'R': + case 'Y': + case 'r': + case 'y': goto yy679; + default: goto yy57; } yy716: - YYDEBUG(716, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy679; - if (yych == 'b') goto yy679; - goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy679; + default: goto yy57; + } yy717: - YYDEBUG(717, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'L') goto yy679; - if (yych <= 'M') goto yy57; - goto yy679; - } else { - if (yych <= 'l') { - if (yych <= 'k') goto yy57; - goto yy679; - } else { - if (yych == 'n') goto yy679; - goto yy57; - } + switch (yych) { + case 'L': + case 'N': + case 'l': + case 'n': goto yy679; + default: goto yy57; } yy718: - YYDEBUG(718, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy679; - if (yych == 'n') goto yy679; - goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy679; + default: goto yy57; + } yy719: - YYDEBUG(719, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 't') goto yy728; - goto yy57; + switch (yych) { + case 't': goto yy728; + default: goto yy57; + } yy720: - YYDEBUG(720, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy728; - goto yy57; + switch (yych) { + case 'd': goto yy728; + default: goto yy57; + } yy721: - YYDEBUG(721, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy728; - goto yy57; + switch (yych) { + case 'd': goto yy728; + default: goto yy57; + } yy722: - YYDEBUG(722, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'h') goto yy728; - goto yy57; + switch (yych) { + case 'h': goto yy728; + default: goto yy57; + } yy723: - YYDEBUG(723, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(724, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy724; + default: goto yy57; + } +yy724: yych = *++YYCURSOR; - if (yych <= '/') goto yy667; - if (yych >= ':') goto yy667; - YYDEBUG(725, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy725; + default: goto yy667; + } +yy725: yych = *++YYCURSOR; - if (yych <= '/') goto yy667; - if (yych >= ':') goto yy667; - YYDEBUG(726, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy726; + default: goto yy667; + } +yy726: yych = *++YYCURSOR; - if (yych <= '/') goto yy667; - if (yych >= ':') goto yy667; - YYDEBUG(727, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy727; + default: goto yy667; + } +yy727: yych = *++YYCURSOR; goto yy667; yy728: - YYDEBUG(728, *YYCURSOR); yyaccept = 14; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '/') goto yy723; - goto yy667; + switch (yych) { + case '/': goto yy723; + default: goto yy667; + } yy729: - YYDEBUG(729, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') { - if (yych == '\t') goto yy731; - goto yy578; - } else { - if (yych <= '-') goto yy732; - if (yych <= '.') goto yy731; - if (yych >= '0') goto yy578; + switch (yych) { + case '\t': + case '.': goto yy731; + case '-': goto yy732; + case '/': goto yy730; + default: goto yy578; } yy730: - YYDEBUG(730, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case 'A': case 'a': goto yy673; @@ -12308,92 +18468,151 @@ static int scan(Scanner *s) default: goto yy57; } yy731: - YYDEBUG(731, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy578; - if (yych <= '0') goto yy736; - if (yych <= '1') goto yy737; - if (yych <= '9') goto yy738; - goto yy578; + switch (yych) { + case '0': goto yy736; + case '1': goto yy737; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy738; + default: goto yy578; + } yy732: - YYDEBUG(732, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy578; - if (yych <= '0') goto yy733; - if (yych <= '1') goto yy734; - if (yych <= '9') goto yy735; - goto yy578; + switch (yych) { + case '0': goto yy733; + case '1': goto yy734; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy735; + default: goto yy578; + } yy733: - YYDEBUG(733, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') goto yy57; - if (yych <= '.') goto yy602; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy735; - goto yy57; + switch (yych) { + case '-': + case '.': goto yy602; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy735; + default: goto yy57; + } yy734: - YYDEBUG(734, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') goto yy57; - if (yych <= '.') goto yy602; - if (yych <= '/') goto yy57; - if (yych >= '3') goto yy57; + switch (yych) { + case '-': + case '.': goto yy602; + case '0': + case '1': + case '2': goto yy735; + default: goto yy57; + } yy735: - YYDEBUG(735, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') goto yy57; - if (yych <= '.') goto yy602; - goto yy57; + switch (yych) { + case '-': + case '.': goto yy602; + default: goto yy57; + } yy736: - YYDEBUG(736, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy602; - goto yy739; - } else { - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy738; - goto yy57; + switch (yych) { + case '-': goto yy602; + case '.': goto yy739; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy738; + default: goto yy57; } yy737: - YYDEBUG(737, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy602; - goto yy739; - } else { - if (yych <= '/') goto yy57; - if (yych >= '3') goto yy57; + switch (yych) { + case '-': goto yy602; + case '.': goto yy739; + case '0': + case '1': + case '2': goto yy738; + default: goto yy57; } yy738: - YYDEBUG(738, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy602; - if (yych >= '/') goto yy57; + switch (yych) { + case '-': goto yy602; + case '.': goto yy739; + default: goto yy57; + } yy739: - YYDEBUG(739, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(740, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy740; + default: goto yy57; + } +yy740: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy611; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy611; + default: goto yy57; + } yy741: - YYDEBUG(741, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy785; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy783; - goto yy61; + switch (yych) { + case '-': goto yy785; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy783; + default: goto yy61; + } yy742: - YYDEBUG(742, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case '0': goto yy751; case '1': goto yy752; @@ -12424,233 +18643,237 @@ static int scan(Scanner *s) default: goto yy57; } yy743: - YYDEBUG(743, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'A') goto yy782; - if (yych <= 'T') goto yy57; - goto yy781; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy782; - } else { - if (yych == 'u') goto yy781; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy782; + case 'U': + case 'u': goto yy781; + default: goto yy57; } yy744: - YYDEBUG(744, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy780; - if (yych == 'e') goto yy780; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy780; + default: goto yy57; + } yy745: - YYDEBUG(745, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy779; - if (yych == 'a') goto yy779; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy779; + default: goto yy57; + } yy746: - YYDEBUG(746, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'P') goto yy778; - if (yych <= 'T') goto yy57; - goto yy777; - } else { - if (yych <= 'p') { - if (yych <= 'o') goto yy57; - goto yy778; - } else { - if (yych == 'u') goto yy777; - goto yy57; - } + switch (yych) { + case 'P': + case 'p': goto yy778; + case 'U': + case 'u': goto yy777; + default: goto yy57; } yy747: - YYDEBUG(747, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy775; - if (yych == 'e') goto yy775; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy775; + default: goto yy57; + } yy748: - YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy774; - if (yych == 'c') goto yy774; - goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy774; + default: goto yy57; + } yy749: - YYDEBUG(749, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy773; - if (yych == 'o') goto yy773; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy773; + default: goto yy57; + } yy750: - YYDEBUG(750, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy765; - if (yych == 'e') goto yy765; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy765; + default: goto yy57; + } yy751: - YYDEBUG(751, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy754; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy758; - goto yy57; + switch (yych) { + case '-': goto yy754; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy758; + default: goto yy57; + } yy752: - YYDEBUG(752, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy754; - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy758; - goto yy57; + switch (yych) { + case '-': goto yy754; + case '0': + case '1': + case '2': goto yy758; + default: goto yy57; + } yy753: - YYDEBUG(753, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '-') goto yy57; + switch (yych) { + case '-': goto yy754; + default: goto yy57; + } yy754: - YYDEBUG(754, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy755; - if (yych <= '3') goto yy756; - if (yych <= '9') goto yy757; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': goto yy755; + case '3': goto yy756; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy757; + default: goto yy57; + } yy755: - YYDEBUG(755, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy757; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy757; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy756: - YYDEBUG(756, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '1') goto yy757; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': goto yy757; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy757: - YYDEBUG(757, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'q') { - if (yych == 'n') goto yy661; - goto yy657; - } else { - if (yych <= 'r') goto yy662; - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; + switch (yych) { + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy758: - YYDEBUG(758, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '-') goto yy57; - YYDEBUG(759, *YYCURSOR); + switch (yych) { + case '-': goto yy759; + default: goto yy57; + } +yy759: yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy57; - if (yych >= '1') goto yy761; - } else { - if (yych <= '3') goto yy762; - if (yych <= '9') goto yy757; - goto yy57; + switch (yych) { + case '0': goto yy760; + case '1': + case '2': goto yy761; + case '3': goto yy762; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy757; + default: goto yy57; } - YYDEBUG(760, *YYCURSOR); +yy760: yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy763; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy763; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy761: - YYDEBUG(761, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy763; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy763; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy762: - YYDEBUG(762, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '1') goto yy763; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': goto yy763; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy763: - YYDEBUG(763, *YYCURSOR); yyaccept = 15; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'q') { - if (yych == 'n') goto yy661; - } else { - if (yych <= 'r') goto yy662; - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; + switch (yych) { + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy764; } yy764: - YYDEBUG(764, *YYCURSOR); #line 1292 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("iso8601date2"); @@ -12663,45 +18886,68 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 12667 "ext/date/lib/parse_date.c" +#line 18890 "" yy765: - YYDEBUG(765, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy766; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy766; + default: goto yy57; + } yy766: - YYDEBUG(766, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '-') goto yy57; + switch (yych) { + case '-': goto yy767; + default: goto yy57; + } yy767: - YYDEBUG(767, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy768; - if (yych <= '2') goto yy769; - if (yych <= '3') goto yy770; - goto yy57; + switch (yych) { + case '0': goto yy768; + case '1': + case '2': goto yy769; + case '3': goto yy770; + default: goto yy57; + } yy768: - YYDEBUG(768, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy771; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy771; + default: goto yy57; + } yy769: - YYDEBUG(769, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy771; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy771; + default: goto yy57; + } yy770: - YYDEBUG(770, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '2') goto yy57; + switch (yych) { + case '0': + case '1': goto yy771; + default: goto yy57; + } yy771: - YYDEBUG(771, *YYCURSOR); ++YYCURSOR; - YYDEBUG(772, *YYCURSOR); #line 1523 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pgtextreverse"); @@ -12714,96 +18960,85 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_PG_TEXT; } -#line 12718 "ext/date/lib/parse_date.c" +#line 18964 "" yy773: - YYDEBUG(773, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'V') goto yy766; - if (yych == 'v') goto yy766; - goto yy57; + switch (yych) { + case 'V': + case 'v': goto yy766; + default: goto yy57; + } yy774: - YYDEBUG(774, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy766; - if (yych == 't') goto yy766; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy766; + default: goto yy57; + } yy775: - YYDEBUG(775, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy776; - if (yych != 'p') goto yy57; + switch (yych) { + case 'P': + case 'p': goto yy776; + default: goto yy57; + } yy776: - YYDEBUG(776, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych == '-') goto yy767; - goto yy57; - } else { - if (yych <= 'T') goto yy766; - if (yych == 't') goto yy766; - goto yy57; + switch (yych) { + case '-': goto yy767; + case 'T': + case 't': goto yy766; + default: goto yy57; } yy777: - YYDEBUG(777, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy766; - if (yych == 'g') goto yy766; - goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy766; + default: goto yy57; + } yy778: - YYDEBUG(778, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy766; - if (yych == 'r') goto yy766; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy766; + default: goto yy57; + } yy779: - YYDEBUG(779, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych == 'R') goto yy766; - if (yych <= 'X') goto yy57; - goto yy766; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy57; - goto yy766; - } else { - if (yych == 'y') goto yy766; - goto yy57; - } + switch (yych) { + case 'R': + case 'Y': + case 'r': + case 'y': goto yy766; + default: goto yy57; } yy780: - YYDEBUG(780, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy766; - if (yych == 'b') goto yy766; - goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy766; + default: goto yy57; + } yy781: - YYDEBUG(781, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'L') goto yy766; - if (yych <= 'M') goto yy57; - goto yy766; - } else { - if (yych <= 'l') { - if (yych <= 'k') goto yy57; - goto yy766; - } else { - if (yych == 'n') goto yy766; - goto yy57; - } + switch (yych) { + case 'L': + case 'N': + case 'l': + case 'n': goto yy766; + default: goto yy57; } yy782: - YYDEBUG(782, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy766; - if (yych == 'n') goto yy766; - goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy766; + default: goto yy57; + } yy783: - YYDEBUG(783, *YYCURSOR); yyaccept = 16; yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': @@ -12851,7 +19086,6 @@ static int scan(Scanner *s) default: goto yy784; } yy784: - YYDEBUG(784, *YYCURSOR); #line 1557 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("year4"); @@ -12860,11 +19094,9 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_CLF; } -#line 12864 "ext/date/lib/parse_date.c" +#line 19098 "" yy785: - YYDEBUG(785, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case '0': goto yy786; case '1': goto yy787; @@ -12895,23 +19127,32 @@ static int scan(Scanner *s) default: goto yy57; } yy786: - YYDEBUG(786, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy754; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy753; - goto yy57; + switch (yych) { + case '-': goto yy754; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy753; + default: goto yy57; + } yy787: - YYDEBUG(787, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy754; - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy753; - goto yy57; + switch (yych) { + case '-': goto yy754; + case '0': + case '1': + case '2': goto yy753; + default: goto yy57; + } yy788: - YYDEBUG(788, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case '0': goto yy973; case '1': goto yy975; @@ -12943,21 +19184,25 @@ static int scan(Scanner *s) default: goto yy939; } yy789: - YYDEBUG(789, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy947; - if (yych <= '1') goto yy948; - if (yych <= '9') goto yy949; - goto yy57; + switch (yych) { + case '0': goto yy947; + case '1': goto yy948; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy949; + default: goto yy57; + } yy790: - YYDEBUG(790, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); yych = *YYCURSOR; yy791: - YYDEBUG(791, *YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': goto yy790; @@ -12993,24 +19238,23 @@ static int scan(Scanner *s) default: goto yy57; } yy792: - YYDEBUG(792, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy939; - if (yych <= '0') goto yy931; - if (yych <= '2') goto yy932; - if (yych <= '3') goto yy933; - goto yy939; + switch (yych) { + case '0': goto yy931; + case '1': + case '2': goto yy932; + case '3': goto yy933; + default: goto yy939; + } yy793: - YYDEBUG(793, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= 'U') { - if (yych == 'I') goto yy930; - } else { - if (yych == 'W') goto yy794; - if (yych <= 'X') goto yy884; + switch ((yych = *YYCURSOR)) { + case 'I': goto yy930; + case 'V': + case 'X': goto yy884; + default: goto yy794; } yy794: - YYDEBUG(794, *YYCURSOR); #line 1383 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenodayrev"); @@ -13023,221 +19267,227 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_NO_DAY; } -#line 13027 "ext/date/lib/parse_date.c" +#line 19271 "" yy795: - YYDEBUG(795, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy928; - goto yy794; + switch (yych) { + case 'I': goto yy928; + default: goto yy794; + } yy796: - YYDEBUG(796, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy927; - goto yy794; + switch (yych) { + case 'I': goto yy927; + default: goto yy794; + } yy797: - YYDEBUG(797, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'A') goto yy920; - if (yych <= 'T') goto yy57; - goto yy919; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy920; - } else { - if (yych == 'u') goto yy919; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy920; + case 'U': + case 'u': goto yy919; + default: goto yy57; } yy798: - YYDEBUG(798, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= 'N') { - if (yych == 'E') goto yy913; - goto yy57; - } else { - if (yych <= 'O') goto yy99; - if (yych <= 'Q') goto yy57; - goto yy98; - } - } else { - if (yych <= 'n') { - if (yych == 'e') goto yy913; - goto yy57; - } else { - if (yych <= 'o') goto yy99; - if (yych == 'r') goto yy98; - goto yy57; - } + switch (yych) { + case 'E': + case 'e': goto yy913; + case 'O': + case 'o': goto yy99; + case 'R': + case 'r': goto yy98; + default: goto yy57; } yy799: - YYDEBUG(799, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= 'H') { - if (yych == 'A') goto yy910; - goto yy57; - } else { - if (yych <= 'I') goto yy118; - if (yych <= 'N') goto yy57; - goto yy117; - } - } else { - if (yych <= 'h') { - if (yych == 'a') goto yy910; - goto yy57; - } else { - if (yych <= 'i') goto yy118; - if (yych == 'o') goto yy117; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy910; + case 'I': + case 'i': goto yy118; + case 'O': + case 'o': goto yy117; + default: goto yy57; } yy800: - YYDEBUG(800, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'P') goto yy904; - if (yych <= 'T') goto yy57; - goto yy903; - } else { - if (yych <= 'p') { - if (yych <= 'o') goto yy57; - goto yy904; - } else { - if (yych == 'u') goto yy903; - goto yy57; - } + switch (yych) { + case 'P': + case 'p': goto yy904; + case 'U': + case 'u': goto yy903; + default: goto yy57; } yy801: - YYDEBUG(801, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'D') { - if (yych == 'A') goto yy127; - goto yy57; - } else { - if (yych <= 'E') goto yy896; - if (yych <= 'T') goto yy57; - goto yy126; - } - } else { - if (yych <= 'd') { - if (yych == 'a') goto yy127; - goto yy57; - } else { - if (yych <= 'e') goto yy896; - if (yych == 'u') goto yy126; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy127; + case 'E': + case 'e': goto yy896; + case 'U': + case 'u': goto yy126; + default: goto yy57; } yy802: - YYDEBUG(802, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy891; - if (yych == 'c') goto yy891; - goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy891; + default: goto yy57; + } yy803: - YYDEBUG(803, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy885; - if (yych == 'o') goto yy885; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy885; + default: goto yy57; + } yy804: - YYDEBUG(804, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych == 'A') goto yy114; - if (yych <= 'D') goto yy57; - goto yy878; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy114; - } else { - if (yych == 'e') goto yy878; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy114; + case 'E': + case 'e': goto yy878; + default: goto yy57; } yy805: - YYDEBUG(805, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '0') goto yy875; - if (yych <= '9') goto yy876; - goto yy61; + switch (yych) { + case '0': goto yy875; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy876; + default: goto yy61; + } yy806: - YYDEBUG(806, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '2') goto yy844; - if (yych <= '9') goto yy823; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': goto yy844; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy823; + default: goto yy61; + } yy807: - YYDEBUG(807, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy824; - if (yych <= '1') goto yy825; - goto yy57; + switch (yych) { + case '0': goto yy824; + case '1': goto yy825; + default: goto yy57; + } yy808: - YYDEBUG(808, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy823; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy823; + default: goto yy61; + } yy809: - YYDEBUG(809, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '5') goto yy819; - if (yych <= '6') goto yy820; - if (yych <= '9') goto yy55; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy819; + case '6': goto yy820; + case '7': + case '8': + case '9': goto yy55; + default: goto yy61; + } yy810: - YYDEBUG(810, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '5') { - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy811; - if (yych <= '4') goto yy812; - goto yy813; - } else { - if (yych <= 'E') { - if (yych <= 'D') goto yy57; - goto yy83; - } else { - if (yych == 'e') goto yy83; - goto yy57; - } + switch (yych) { + case '0': goto yy811; + case '1': + case '2': + case '3': + case '4': goto yy812; + case '5': goto yy813; + case 'E': + case 'e': goto yy83; + default: goto yy57; } yy811: - YYDEBUG(811, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '0') goto yy57; - if (yych <= '9') goto yy814; - goto yy57; + switch (yych) { + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy814; + default: goto yy57; + } yy812: - YYDEBUG(812, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy814; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy814; + default: goto yy57; + } yy813: - YYDEBUG(813, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '4') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': goto yy814; + default: goto yy57; + } yy814: - YYDEBUG(814, *YYCURSOR); yyaccept = 17; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '-') goto yy816; - if (yych <= '/') goto yy815; - if (yych <= '7') goto yy817; + switch (yych) { + case '-': goto yy816; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': goto yy817; + default: goto yy815; + } yy815: - YYDEBUG(815, *YYCURSOR); #line 1491 "ext/date/lib/parse_date.re" { timelib_sll w, d; @@ -13256,16 +19506,22 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_WEEK; } -#line 13260 "ext/date/lib/parse_date.c" +#line 19510 "" yy816: - YYDEBUG(816, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '8') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': goto yy817; + default: goto yy57; + } yy817: - YYDEBUG(817, *YYCURSOR); ++YYCURSOR; - YYDEBUG(818, *YYCURSOR); #line 1472 "ext/date/lib/parse_date.re" { timelib_sll w, d; @@ -13284,70 +19540,72 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_WEEK; } -#line 13288 "ext/date/lib/parse_date.c" +#line 19544 "" yy819: - YYDEBUG(819, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy821; - goto yy61; -yy820: - YYDEBUG(820, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '6') goto yy821; - if (yych <= '9') goto yy55; - goto yy61; -yy821: - YYDEBUG(821, *YYCURSOR); - yyaccept = 18; - yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 2) { - goto yy55; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy61; } - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych >= ' ') goto yy61; - } else { - if (yych == 'D') goto yy61; - if (yych >= 'F') goto yy61; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy61; - if (yych >= 'M') goto yy61; - } else { - if (yych <= 'R') goto yy822; - if (yych <= 'T') goto yy61; - if (yych >= 'W') goto yy61; - } - } - } else { - if (yych <= 'h') { - if (yych <= 'd') { - if (yych == 'Y') goto yy61; - if (yych >= 'd') goto yy61; - } else { - if (yych == 'f') goto yy61; - if (yych >= 'h') goto yy61; - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych >= 's') goto yy61; - } else { - if (yych <= 'w') { - if (yych >= 'w') goto yy61; - } else { - if (yych == 'y') goto yy61; - } - } - } +yy820: + yych = *++YYCURSOR; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': goto yy821; + case '7': + case '8': + case '9': goto yy55; + default: goto yy61; + } +yy821: + yyaccept = 18; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy822; } yy822: - YYDEBUG(822, *YYCURSOR); #line 1459 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("pgydotd"); @@ -13360,109 +19618,210 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_PG_YEARDAY; } -#line 13364 "ext/date/lib/parse_date.c" +#line 19622 "" yy823: - YYDEBUG(823, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy821; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy61; + } yy824: - YYDEBUG(824, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy826; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy826; + default: goto yy57; + } yy825: - YYDEBUG(825, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '3') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': goto yy826; + default: goto yy57; + } yy826: - YYDEBUG(826, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(827, *YYCURSOR); + switch (yych) { + case ':': goto yy827; + default: goto yy57; + } +yy827: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy828; - if (yych <= '2') goto yy829; - if (yych <= '3') goto yy830; - goto yy57; + switch (yych) { + case '0': goto yy828; + case '1': + case '2': goto yy829; + case '3': goto yy830; + default: goto yy57; + } yy828: - YYDEBUG(828, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy831; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy831; + default: goto yy57; + } yy829: - YYDEBUG(829, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy831; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy831; + default: goto yy57; + } yy830: - YYDEBUG(830, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '2') goto yy57; + switch (yych) { + case '0': + case '1': goto yy831; + default: goto yy57; + } yy831: - YYDEBUG(831, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ' ') goto yy57; - YYDEBUG(832, *YYCURSOR); + switch (yych) { + case ' ': goto yy832; + default: goto yy57; + } +yy832: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy833; - if (yych <= '2') goto yy834; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy833; + case '2': goto yy834; + default: goto yy57; + } yy833: - YYDEBUG(833, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy835; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy835; + default: goto yy57; + } yy834: - YYDEBUG(834, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '5') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy835; + default: goto yy57; + } yy835: - YYDEBUG(835, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(836, *YYCURSOR); + switch (yych) { + case ':': goto yy836; + default: goto yy57; + } +yy836: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '6') goto yy57; - YYDEBUG(837, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy837; + default: goto yy57; + } +yy837: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(838, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy838; + default: goto yy57; + } +yy838: yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(839, *YYCURSOR); + switch (yych) { + case ':': goto yy839; + default: goto yy57; + } +yy839: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy840; - if (yych <= '6') goto yy841; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy840; + case '6': goto yy841; + default: goto yy57; + } yy840: - YYDEBUG(840, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy842; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy57; + } yy841: - YYDEBUG(841, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '0') goto yy57; + switch (yych) { + case '0': goto yy842; + default: goto yy57; + } yy842: - YYDEBUG(842, *YYCURSOR); ++YYCURSOR; yy843: - YYDEBUG(843, *YYCURSOR); #line 1433 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -13488,268 +19847,159 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_XMLRPC_SOAP; } -#line 13492 "ext/date/lib/parse_date.c" +#line 19851 "" yy844: - YYDEBUG(844, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy61; - if (yych >= '1') goto yy846; - } else { - if (yych <= '3') goto yy847; - if (yych <= '9') goto yy821; - goto yy61; + switch (yych) { + case '0': goto yy845; + case '1': + case '2': goto yy846; + case '3': goto yy847; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy61; } yy845: - YYDEBUG(845, *YYCURSOR); - yyaccept = 18; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy822; - goto yy61; - } else { - if (yych <= '/') goto yy822; - if (yych <= '9') goto yy848; - if (yych <= 'C') goto yy822; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy822; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy822; - goto yy61; - } else { - if (yych <= 'R') goto yy822; - if (yych <= 'T') goto yy61; - goto yy822; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy822; - if (yych <= 'Y') goto yy61; - goto yy822; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy822; - } else { - if (yych == 'g') goto yy822; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy822; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy822; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy822; - } - } - } - } -yy846: - YYDEBUG(846, *YYCURSOR); yyaccept = 18; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy822; - goto yy61; - } else { - if (yych <= '/') goto yy822; - if (yych <= '9') goto yy848; - if (yych <= 'C') goto yy822; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy822; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy822; - goto yy61; - } else { - if (yych <= 'R') goto yy822; - if (yych <= 'T') goto yy61; - goto yy822; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy822; - if (yych <= 'Y') goto yy61; - goto yy822; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy822; - } else { - if (yych == 'g') goto yy822; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy822; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy822; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy822; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy848; + default: goto yy822; + } +yy846: + yyaccept = 18; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy848; + default: goto yy822; } yy847: - YYDEBUG(847, *YYCURSOR); yyaccept = 18; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy822; - goto yy61; - } else { - if (yych <= '1') { - if (yych <= '/') goto yy822; - } else { - if (yych <= '9') goto yy55; - if (yych <= 'C') goto yy822; - goto yy61; - } - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy822; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy822; - goto yy61; - } else { - if (yych <= 'R') goto yy822; - if (yych <= 'T') goto yy61; - goto yy822; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy822; - if (yych <= 'Y') goto yy61; - goto yy822; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy822; - } else { - if (yych == 'g') goto yy822; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy822; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy822; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy822; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': goto yy848; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy822; } yy848: - YYDEBUG(848, *YYCURSOR); yyaccept = 19; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 2) { - goto yy55; - } - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy60; - if (yych >= ' ') goto yy60; - } else { - if (yych == 'D') goto yy65; - if (yych >= 'F') goto yy66; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy64; - if (yych >= 'M') goto yy63; - } else { - if (yych <= 'S') { - if (yych >= 'S') goto yy62; - } else { - if (yych <= 'T') goto yy850; - if (yych >= 'W') goto yy68; - } - } - } - } else { - if (yych <= 'l') { - if (yych <= 'd') { - if (yych == 'Y') goto yy67; - if (yych >= 'd') goto yy65; - } else { - if (yych <= 'f') { - if (yych >= 'f') goto yy66; - } else { - if (yych == 'h') goto yy64; - } - } - } else { - if (yych <= 't') { - if (yych <= 'm') goto yy63; - if (yych <= 'r') goto yy849; - if (yych <= 's') goto yy62; - goto yy851; - } else { - if (yych <= 'w') { - if (yych >= 'w') goto yy68; - } else { - if (yych == 'y') goto yy67; - } - } - } + switch (yych) { + case '\t': + case ' ': goto yy60; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + case 'D': + case 'd': goto yy65; + case 'F': + case 'f': goto yy66; + case 'H': + case 'h': goto yy64; + case 'M': + case 'm': goto yy63; + case 'S': + case 's': goto yy62; + case 'T': goto yy850; + case 'W': + case 'w': goto yy68; + case 'Y': + case 'y': goto yy67; + case 't': goto yy851; + default: goto yy849; } yy849: - YYDEBUG(849, *YYCURSOR); #line 1421 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("datenocolon"); @@ -13761,591 +20011,827 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_DATE_NOCOLON; } -#line 13765 "ext/date/lib/parse_date.c" +#line 20015 "" yy850: - YYDEBUG(850, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= '2') { - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy865; - goto yy866; - } else { - if (yych <= '9') goto yy867; - if (yych <= 'G') goto yy57; - goto yy70; - } - } else { - if (yych <= 'g') { - if (yych == 'U') goto yy71; - goto yy57; - } else { - if (yych <= 'h') goto yy70; - if (yych == 'u') goto yy71; - goto yy57; - } + switch (yych) { + case '0': + case '1': goto yy865; + case '2': goto yy866; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy867; + case 'H': + case 'h': goto yy70; + case 'U': + case 'u': goto yy71; + default: goto yy57; } yy851: - YYDEBUG(851, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= '2') { - if (yych <= '/') goto yy57; - if (yych >= '2') goto yy853; - } else { - if (yych <= '9') goto yy854; - if (yych <= 'G') goto yy57; - goto yy70; - } - } else { - if (yych <= 'g') { - if (yych == 'U') goto yy71; - goto yy57; - } else { - if (yych <= 'h') goto yy70; - if (yych == 'u') goto yy71; - goto yy57; - } + switch (yych) { + case '0': + case '1': goto yy852; + case '2': goto yy853; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy854; + case 'H': + case 'h': goto yy70; + case 'U': + case 'u': goto yy71; + default: goto yy57; } - YYDEBUG(852, *YYCURSOR); +yy852: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy859; - if (yych <= '9') goto yy854; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy859; + case '6': + case '7': + case '8': + case '9': goto yy854; + default: goto yy57; + } yy853: - YYDEBUG(853, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '4') goto yy859; - if (yych <= '5') goto yy855; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy859; + case '5': goto yy855; + default: goto yy57; + } yy854: - YYDEBUG(854, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '6') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy855; + default: goto yy57; + } yy855: - YYDEBUG(855, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy856; + default: goto yy57; + } yy856: - YYDEBUG(856, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy857; - if (yych <= '6') goto yy858; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy857; + case '6': goto yy858; + default: goto yy57; + } yy857: - YYDEBUG(857, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy842; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy57; + } yy858: - YYDEBUG(858, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '0') goto yy842; - goto yy57; + switch (yych) { + case '0': goto yy842; + default: goto yy57; + } yy859: - YYDEBUG(859, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy860; - if (yych <= '9') goto yy856; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy860; + case '6': + case '7': + case '8': + case '9': goto yy856; + default: goto yy57; + } yy860: - YYDEBUG(860, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy861; - if (yych <= '6') goto yy862; - if (yych <= '9') goto yy856; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy861; + case '6': goto yy862; + case '7': + case '8': + case '9': goto yy856; + default: goto yy57; + } yy861: - YYDEBUG(861, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy863; - if (yych <= '6') goto yy864; - if (yych <= '9') goto yy842; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy863; + case '6': goto yy864; + case '7': + case '8': + case '9': goto yy842; + default: goto yy57; + } yy862: - YYDEBUG(862, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy863; - if (yych <= '5') goto yy857; - if (yych <= '6') goto yy858; - goto yy57; + switch (yych) { + case '0': goto yy863; + case '1': + case '2': + case '3': + case '4': + case '5': goto yy857; + case '6': goto yy858; + default: goto yy57; + } yy863: - YYDEBUG(863, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '9') goto yy842; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy843; + } yy864: - YYDEBUG(864, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '0') goto yy842; - goto yy843; + switch (yych) { + case '0': goto yy842; + default: goto yy843; + } yy865: - YYDEBUG(865, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy874; - if (yych <= '9') goto yy867; - if (yych <= ':') goto yy868; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy874; + case '6': + case '7': + case '8': + case '9': goto yy867; + case ':': goto yy868; + default: goto yy57; + } yy866: - YYDEBUG(866, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '5') { - if (yych <= '/') goto yy57; - if (yych <= '4') goto yy874; - goto yy855; - } else { - if (yych == ':') goto yy868; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy874; + case '5': goto yy855; + case ':': goto yy868; + default: goto yy57; } yy867: - YYDEBUG(867, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy855; - if (yych != ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy855; + case ':': goto yy868; + default: goto yy57; + } yy868: - YYDEBUG(868, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= '6') goto yy57; - YYDEBUG(869, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy869; + default: goto yy57; + } +yy869: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(870, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy870; + default: goto yy57; + } +yy870: yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(871, *YYCURSOR); + switch (yych) { + case ':': goto yy871; + default: goto yy57; + } +yy871: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy872; - if (yych <= '6') goto yy873; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy872; + case '6': goto yy873; + default: goto yy57; + } yy872: - YYDEBUG(872, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy842; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy57; + } yy873: - YYDEBUG(873, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '0') goto yy842; - goto yy57; + switch (yych) { + case '0': goto yy842; + default: goto yy57; + } yy874: - YYDEBUG(874, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy860; - if (yych <= '9') goto yy856; - if (yych <= ':') goto yy868; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy860; + case '6': + case '7': + case '8': + case '9': goto yy856; + case ':': goto yy868; + default: goto yy57; + } yy875: - YYDEBUG(875, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy61; - if (yych <= '0') goto yy877; - goto yy846; - } else { - if (yych <= '3') goto yy847; - if (yych <= '9') goto yy821; - goto yy61; + switch (yych) { + case '0': goto yy877; + case '1': + case '2': goto yy846; + case '3': goto yy847; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy61; } yy876: - YYDEBUG(876, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy61; - if (yych <= '0') goto yy845; - goto yy846; - } else { - if (yych <= '3') goto yy847; - if (yych <= '9') goto yy821; - goto yy61; + switch (yych) { + case '0': goto yy845; + case '1': + case '2': goto yy846; + case '3': goto yy847; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy61; } yy877: - YYDEBUG(877, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy848; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy848; + default: goto yy61; + } yy878: - YYDEBUG(878, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy879; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy879; + default: goto yy57; + } yy879: - YYDEBUG(879, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'E') goto yy880; - if (yych != 'e') goto yy794; + switch (yych) { + case 'E': + case 'e': goto yy880; + default: goto yy794; + } yy880: - YYDEBUG(880, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy881; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy881; + default: goto yy57; + } yy881: - YYDEBUG(881, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy882; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy882; + default: goto yy57; + } yy882: - YYDEBUG(882, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy883; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy883; + default: goto yy57; + } yy883: - YYDEBUG(883, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy884; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy884; + default: goto yy57; + } yy884: - YYDEBUG(884, *YYCURSOR); yych = *++YYCURSOR; goto yy794; yy885: - YYDEBUG(885, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'V') goto yy886; - if (yych != 'v') goto yy57; + switch (yych) { + case 'V': + case 'v': goto yy886; + default: goto yy57; + } yy886: - YYDEBUG(886, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'E') goto yy887; - if (yych != 'e') goto yy794; + switch (yych) { + case 'E': + case 'e': goto yy887; + default: goto yy794; + } yy887: - YYDEBUG(887, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy888; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy888; + default: goto yy57; + } yy888: - YYDEBUG(888, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy889; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy889; + default: goto yy57; + } yy889: - YYDEBUG(889, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy890; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy890; + default: goto yy57; + } yy890: - YYDEBUG(890, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy884; - if (yych == 'r') goto yy884; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy884; + default: goto yy57; + } yy891: - YYDEBUG(891, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy892; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy892; + default: goto yy57; + } yy892: - YYDEBUG(892, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'O') goto yy893; - if (yych != 'o') goto yy794; + switch (yych) { + case 'O': + case 'o': goto yy893; + default: goto yy794; + } yy893: - YYDEBUG(893, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy894; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy894; + default: goto yy57; + } yy894: - YYDEBUG(894, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy895; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy895; + default: goto yy57; + } yy895: - YYDEBUG(895, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy884; - if (yych == 'r') goto yy884; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy884; + default: goto yy57; + } yy896: - YYDEBUG(896, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'P') { - if (yych == 'C') goto yy129; - if (yych <= 'O') goto yy57; - } else { - if (yych <= 'c') { - if (yych <= 'b') goto yy57; - goto yy129; - } else { - if (yych != 'p') goto yy57; - } + switch (yych) { + case 'C': + case 'c': goto yy129; + case 'P': + case 'p': goto yy897; + default: goto yy57; } yy897: - YYDEBUG(897, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy898; - if (yych != 't') goto yy794; + switch (yych) { + case 'T': + case 't': goto yy898; + default: goto yy794; + } yy898: - YYDEBUG(898, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'E') goto yy899; - if (yych != 'e') goto yy794; + switch (yych) { + case 'E': + case 'e': goto yy899; + default: goto yy794; + } yy899: - YYDEBUG(899, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy900; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy900; + default: goto yy57; + } yy900: - YYDEBUG(900, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy901; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy901; + default: goto yy57; + } yy901: - YYDEBUG(901, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy902; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy902; + default: goto yy57; + } yy902: - YYDEBUG(902, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy884; - if (yych == 'r') goto yy884; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy884; + default: goto yy57; + } yy903: - YYDEBUG(903, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy907; - if (yych == 'g') goto yy907; - goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy907; + default: goto yy57; + } yy904: - YYDEBUG(904, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy905; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy905; + default: goto yy57; + } yy905: - YYDEBUG(905, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'I') goto yy906; - if (yych != 'i') goto yy794; + switch (yych) { + case 'I': + case 'i': goto yy906; + default: goto yy794; + } yy906: - YYDEBUG(906, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy884; - if (yych == 'l') goto yy884; - goto yy57; + switch (yych) { + case 'L': + case 'l': goto yy884; + default: goto yy57; + } yy907: - YYDEBUG(907, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'U') goto yy908; - if (yych != 'u') goto yy794; + switch (yych) { + case 'U': + case 'u': goto yy908; + default: goto yy794; + } yy908: - YYDEBUG(908, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy909; - if (yych != 's') goto yy57; + switch (yych) { + case 'S': + case 's': goto yy909; + default: goto yy57; + } yy909: - YYDEBUG(909, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy884; - if (yych == 't') goto yy884; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy884; + default: goto yy57; + } yy910: - YYDEBUG(910, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych == 'R') goto yy911; - if (yych <= 'X') goto yy57; - goto yy884; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy57; - } else { - if (yych == 'y') goto yy884; - goto yy57; - } + switch (yych) { + case 'R': + case 'r': goto yy911; + case 'Y': + case 'y': goto yy884; + default: goto yy57; } yy911: - YYDEBUG(911, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'C') goto yy912; - if (yych != 'c') goto yy794; + switch (yych) { + case 'C': + case 'c': goto yy912; + default: goto yy794; + } yy912: - YYDEBUG(912, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy884; - if (yych == 'h') goto yy884; - goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy884; + default: goto yy57; + } yy913: - YYDEBUG(913, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy914; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy914; + default: goto yy57; + } yy914: - YYDEBUG(914, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'R') goto yy915; - if (yych != 'r') goto yy794; + switch (yych) { + case 'R': + case 'r': goto yy915; + default: goto yy794; + } yy915: - YYDEBUG(915, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy916; - if (yych != 'u') goto yy57; + switch (yych) { + case 'U': + case 'u': goto yy916; + default: goto yy57; + } yy916: - YYDEBUG(916, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy917; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy917; + default: goto yy57; + } yy917: - YYDEBUG(917, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy918; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy918; + default: goto yy57; + } yy918: - YYDEBUG(918, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy884; - if (yych == 'y') goto yy884; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy884; + default: goto yy57; + } yy919: - YYDEBUG(919, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'L') goto yy926; - if (yych <= 'M') goto yy57; - goto yy925; - } else { - if (yych <= 'l') { - if (yych <= 'k') goto yy57; - goto yy926; - } else { - if (yych == 'n') goto yy925; - goto yy57; - } + switch (yych) { + case 'L': + case 'l': goto yy926; + case 'N': + case 'n': goto yy925; + default: goto yy57; } yy920: - YYDEBUG(920, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy921; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy921; + default: goto yy57; + } yy921: - YYDEBUG(921, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'U') goto yy922; - if (yych != 'u') goto yy794; + switch (yych) { + case 'U': + case 'u': goto yy922; + default: goto yy794; + } yy922: - YYDEBUG(922, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy923; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy923; + default: goto yy57; + } yy923: - YYDEBUG(923, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy924; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy924; + default: goto yy57; + } yy924: - YYDEBUG(924, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy884; - if (yych == 'y') goto yy884; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy884; + default: goto yy57; + } yy925: - YYDEBUG(925, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy884; - if (yych == 'e') goto yy884; - goto yy794; + switch (yych) { + case 'E': + case 'e': goto yy884; + default: goto yy794; + } yy926: - YYDEBUG(926, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy884; - if (yych == 'y') goto yy884; - goto yy794; + switch (yych) { + case 'Y': + case 'y': goto yy884; + default: goto yy794; + } yy927: - YYDEBUG(927, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy884; - goto yy794; + switch (yych) { + case 'I': goto yy884; + default: goto yy794; + } yy928: - YYDEBUG(928, *YYCURSOR); yych = *++YYCURSOR; - if (yych != 'I') goto yy794; - YYDEBUG(929, *YYCURSOR); + switch (yych) { + case 'I': goto yy929; + default: goto yy794; + } +yy929: yych = *++YYCURSOR; - if (yych == 'I') goto yy884; - goto yy794; + switch (yych) { + case 'I': goto yy884; + default: goto yy794; + } yy930: - YYDEBUG(930, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy884; - goto yy794; + switch (yych) { + case 'I': goto yy884; + default: goto yy794; + } yy931: - YYDEBUG(931, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy946; - if (yych <= '9') goto yy945; - goto yy57; + switch (yych) { + case '0': goto yy946; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy945; + default: goto yy57; + } yy932: - YYDEBUG(932, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy944; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy944; + default: goto yy57; + } yy933: - YYDEBUG(933, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy942; - if (yych <= '6') goto yy941; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy942; + case '6': goto yy941; + default: goto yy57; + } yy934: - YYDEBUG(934, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy913; - if (yych == 'e') goto yy913; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy913; + default: goto yy57; + } yy935: - YYDEBUG(935, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy910; - if (yych == 'a') goto yy910; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy910; + default: goto yy57; + } yy936: - YYDEBUG(936, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy940; - if (yych == 'e') goto yy940; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy940; + default: goto yy57; + } yy937: - YYDEBUG(937, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy878; - if (yych == 'e') goto yy878; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy878; + default: goto yy57; + } yy938: - YYDEBUG(938, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; yy939: - YYDEBUG(939, *YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': @@ -14373,314 +20859,371 @@ static int scan(Scanner *s) default: goto yy57; } yy940: - YYDEBUG(940, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy897; - if (yych == 'p') goto yy897; - goto yy57; + switch (yych) { + case 'P': + case 'p': goto yy897; + default: goto yy57; + } yy941: - YYDEBUG(941, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '6') goto yy943; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': goto yy943; + default: goto yy57; + } yy942: - YYDEBUG(942, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy943; + default: goto yy57; + } yy943: - YYDEBUG(943, *YYCURSOR); yych = *++YYCURSOR; goto yy822; yy944: - YYDEBUG(944, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy943; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy943; + default: goto yy57; + } yy945: - YYDEBUG(945, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy943; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy943; + default: goto yy57; + } yy946: - YYDEBUG(946, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '0') goto yy57; - if (yych <= '9') goto yy943; - goto yy57; + switch (yych) { + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy943; + default: goto yy57; + } yy947: - YYDEBUG(947, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') goto yy57; - if (yych <= '/') goto yy950; - if (yych <= '9') goto yy958; - goto yy57; + switch (yych) { + case '/': goto yy950; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy958; + default: goto yy57; + } yy948: - YYDEBUG(948, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') goto yy57; - if (yych <= '/') goto yy950; - if (yych <= '2') goto yy958; - goto yy57; + switch (yych) { + case '/': goto yy950; + case '0': + case '1': + case '2': goto yy958; + default: goto yy57; + } yy949: - YYDEBUG(949, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '/') goto yy57; + switch (yych) { + case '/': goto yy950; + default: goto yy57; + } yy950: - YYDEBUG(950, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy951; - if (yych <= '3') goto yy952; - if (yych <= '9') goto yy953; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': goto yy951; + case '3': goto yy952; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy953; + default: goto yy57; + } yy951: - YYDEBUG(951, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy455; - if (yych <= '9') goto yy953; - if (yych <= 'm') goto yy455; - goto yy955; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy956; - } else { - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy953; + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy952: - YYDEBUG(952, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy455; - if (yych <= '1') goto yy953; - if (yych <= 'm') goto yy455; - goto yy955; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy956; - } else { - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; - } + switch (yych) { + case '0': + case '1': goto yy953; + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy953: - YYDEBUG(953, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'q') { - if (yych == 'n') goto yy955; - goto yy455; - } else { - if (yych <= 'r') goto yy956; - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; + switch (yych) { + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy954: - YYDEBUG(954, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 't') goto yy454; - goto yy57; + switch (yych) { + case 't': goto yy454; + default: goto yy57; + } yy955: - YYDEBUG(955, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy454; - goto yy57; + switch (yych) { + case 'd': goto yy454; + default: goto yy57; + } yy956: - YYDEBUG(956, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy454; - goto yy57; + switch (yych) { + case 'd': goto yy454; + default: goto yy57; + } yy957: - YYDEBUG(957, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'h') goto yy454; - goto yy57; + switch (yych) { + case 'h': goto yy454; + default: goto yy57; + } yy958: - YYDEBUG(958, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '/') goto yy57; - YYDEBUG(959, *YYCURSOR); + switch (yych) { + case '/': goto yy959; + default: goto yy57; + } +yy959: yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy57; - if (yych >= '1') goto yy961; - } else { - if (yych <= '3') goto yy962; - if (yych <= '9') goto yy953; - goto yy57; + switch (yych) { + case '0': goto yy960; + case '1': + case '2': goto yy961; + case '3': goto yy962; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy953; + default: goto yy57; } - YYDEBUG(960, *YYCURSOR); +yy960: yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy455; - if (yych <= '9') goto yy963; - if (yych <= 'm') goto yy455; - goto yy955; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy956; - } else { - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy963; + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy961: - YYDEBUG(961, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy455; - if (yych <= '9') goto yy963; - if (yych <= 'm') goto yy455; - goto yy955; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy956; - } else { - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy963; + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy962: - YYDEBUG(962, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy455; - if (yych <= '1') goto yy963; - if (yych <= 'm') goto yy455; - goto yy955; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy956; - } else { - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; - } + switch (yych) { + case '0': + case '1': goto yy963; + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy963: - YYDEBUG(963, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych == '/') goto yy454; - if (yych <= 'm') goto yy455; - goto yy955; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy956; - } else { - if (yych <= 's') goto yy954; - if (yych <= 't') goto yy957; - goto yy455; - } + switch (yych) { + case '/': goto yy454; + case 'n': goto yy955; + case 'r': goto yy956; + case 's': goto yy954; + case 't': goto yy957; + default: goto yy455; } yy964: - YYDEBUG(964, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'A') goto yy1044; - if (yych <= 'T') goto yy57; - goto yy1043; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy57; - goto yy1044; - } else { - if (yych == 'u') goto yy1043; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy1044; + case 'U': + case 'u': goto yy1043; + default: goto yy57; } yy965: - YYDEBUG(965, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1041; - if (yych == 'e') goto yy1041; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1041; + default: goto yy57; + } yy966: - YYDEBUG(966, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1038; - if (yych == 'a') goto yy1038; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1038; + default: goto yy57; + } yy967: - YYDEBUG(967, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'P') goto yy1035; - if (yych <= 'T') goto yy57; - goto yy1034; - } else { - if (yych <= 'p') { - if (yych <= 'o') goto yy57; - goto yy1035; - } else { - if (yych == 'u') goto yy1034; - goto yy57; - } + switch (yych) { + case 'P': + case 'p': goto yy1035; + case 'U': + case 'u': goto yy1034; + default: goto yy57; } yy968: - YYDEBUG(968, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1031; - if (yych == 'e') goto yy1031; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1031; + default: goto yy57; + } yy969: - YYDEBUG(969, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy1029; - if (yych == 'c') goto yy1029; - goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy1029; + default: goto yy57; + } yy970: - YYDEBUG(970, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy1027; - if (yych == 'o') goto yy1027; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy1027; + default: goto yy57; + } yy971: - YYDEBUG(971, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1025; - if (yych == 'e') goto yy1025; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1025; + default: goto yy57; + } yy972: - YYDEBUG(972, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '0') goto yy811; - if (yych <= '4') goto yy812; - if (yych <= '5') goto yy813; - goto yy57; + switch (yych) { + case '0': goto yy811; + case '1': + case '2': + case '3': + case '4': goto yy812; + case '5': goto yy813; + default: goto yy57; + } yy973: - YYDEBUG(973, *YYCURSOR); yyaccept = 22; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '-') goto yy977; - if (yych <= '/') goto yy974; - if (yych <= '9') goto yy996; + switch (yych) { + case '-': goto yy977; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy996; + default: goto yy974; + } yy974: - YYDEBUG(974, *YYCURSOR); #line 1305 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("gnudateshorter"); @@ -14693,714 +21236,834 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_DATE; } -#line 14697 "ext/date/lib/parse_date.c" +#line 21240 "" yy975: - YYDEBUG(975, *YYCURSOR); yyaccept = 22; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '-') goto yy977; - if (yych <= '/') goto yy974; - if (yych <= '2') goto yy996; - goto yy974; + switch (yych) { + case '-': goto yy977; + case '0': + case '1': + case '2': goto yy996; + default: goto yy974; + } yy976: - YYDEBUG(976, *YYCURSOR); yyaccept = 22; yych = *(YYMARKER = ++YYCURSOR); - if (yych != '-') goto yy974; + switch (yych) { + case '-': goto yy977; + default: goto yy974; + } yy977: - YYDEBUG(977, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '2') goto yy978; - if (yych <= '3') goto yy979; - if (yych <= '9') goto yy980; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': goto yy978; + case '3': goto yy979; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy980; + default: goto yy57; + } yy978: - YYDEBUG(978, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '9') { - if (yych <= '/') goto yy657; - goto yy980; - } else { - if (yych == 'T') goto yy985; - goto yy657; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy982; - if (yych <= 'q') goto yy657; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy980; + case 'T': goto yy985; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy657; } yy979: - YYDEBUG(979, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy657; - } else { - if (yych == 'T') goto yy985; - goto yy657; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy982; - if (yych <= 'q') goto yy657; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy657; - } + switch (yych) { + case '0': + case '1': goto yy980; + case 'T': goto yy985; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy657; } yy980: - YYDEBUG(980, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych == 'T') goto yy985; - if (yych <= 'm') goto yy657; - goto yy982; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy657; - } + switch (yych) { + case 'T': goto yy985; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy657; } yy981: - YYDEBUG(981, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 't') goto yy995; - goto yy57; + switch (yych) { + case 't': goto yy995; + default: goto yy57; + } yy982: - YYDEBUG(982, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy995; - goto yy57; + switch (yych) { + case 'd': goto yy995; + default: goto yy57; + } yy983: - YYDEBUG(983, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'd') goto yy995; - goto yy57; + switch (yych) { + case 'd': goto yy995; + default: goto yy57; + } yy984: - YYDEBUG(984, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'h') goto yy995; - goto yy57; + switch (yych) { + case 'h': goto yy995; + default: goto yy57; + } yy985: - YYDEBUG(985, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy986; - if (yych <= '2') goto yy987; - if (yych <= '9') goto yy988; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy986; + case '2': goto yy987; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy988; + default: goto yy57; + } yy986: - YYDEBUG(986, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy988; - if (yych <= ':') goto yy989; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy988; + case ':': goto yy989; + default: goto yy57; + } yy987: - YYDEBUG(987, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '4') goto yy988; - if (yych == ':') goto yy989; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy988; + case ':': goto yy989; + default: goto yy57; + } yy988: - YYDEBUG(988, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; + switch (yych) { + case ':': goto yy989; + default: goto yy57; + } yy989: - YYDEBUG(989, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy990; - if (yych <= '9') goto yy991; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy990; + case '6': + case '7': + case '8': + case '9': goto yy991; + default: goto yy57; + } yy990: - YYDEBUG(990, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy991; - if (yych <= ':') goto yy992; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy991; + case ':': goto yy992; + default: goto yy57; + } yy991: - YYDEBUG(991, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; + switch (yych) { + case ':': goto yy992; + default: goto yy57; + } yy992: - YYDEBUG(992, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy993; - if (yych <= '6') goto yy994; - if (yych <= '9') goto yy842; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy993; + case '6': goto yy994; + case '7': + case '8': + case '9': goto yy842; + default: goto yy57; + } yy993: - YYDEBUG(993, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '9') goto yy842; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy843; + } yy994: - YYDEBUG(994, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '0') goto yy842; - goto yy843; + switch (yych) { + case '0': goto yy842; + default: goto yy843; + } yy995: - YYDEBUG(995, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych == 'T') goto yy985; - goto yy657; + switch (yych) { + case 'T': goto yy985; + default: goto yy657; + } yy996: - YYDEBUG(996, *YYCURSOR); yyaccept = 22; yych = *(YYMARKER = ++YYCURSOR); - if (yych != '-') goto yy974; - YYDEBUG(997, *YYCURSOR); + switch (yych) { + case '-': goto yy997; + default: goto yy974; + } +yy997: yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy57; - if (yych >= '1') goto yy999; - } else { - if (yych <= '3') goto yy1000; - if (yych <= '9') goto yy980; - goto yy57; + switch (yych) { + case '0': goto yy998; + case '1': + case '2': goto yy999; + case '3': goto yy1000; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy980; + default: goto yy57; } - YYDEBUG(998, *YYCURSOR); +yy998: yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '9') { - if (yych <= '/') goto yy657; - goto yy1001; - } else { - if (yych == 'T') goto yy985; - goto yy657; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy982; - if (yych <= 'q') goto yy657; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1001; + case 'T': goto yy985; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy657; } yy999: - YYDEBUG(999, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '9') { - if (yych <= '/') goto yy657; - goto yy1001; - } else { - if (yych == 'T') goto yy985; - goto yy657; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy982; - if (yych <= 'q') goto yy657; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1001; + case 'T': goto yy985; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy657; } yy1000: - YYDEBUG(1000, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'm') { - if (yych <= '1') { - if (yych <= '/') goto yy657; - } else { - if (yych == 'T') goto yy985; - goto yy657; - } - } else { - if (yych <= 'r') { - if (yych <= 'n') goto yy982; - if (yych <= 'q') goto yy657; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy657; - } + switch (yych) { + case '0': + case '1': goto yy1001; + case 'T': goto yy985; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy657; } yy1001: - YYDEBUG(1001, *YYCURSOR); yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych == 'T') goto yy1002; - if (yych <= 'm') goto yy455; - goto yy982; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy455; - goto yy983; - } else { - if (yych <= 's') goto yy981; - if (yych <= 't') goto yy984; - goto yy455; - } + switch (yych) { + case 'T': goto yy1002; + case 'n': goto yy982; + case 'r': goto yy983; + case 's': goto yy981; + case 't': goto yy984; + default: goto yy455; } yy1002: - YYDEBUG(1002, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy1003; - if (yych <= '2') goto yy1004; - if (yych <= '9') goto yy988; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy1003; + case '2': goto yy1004; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy988; + default: goto yy57; + } yy1003: - YYDEBUG(1003, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy1005; - if (yych <= ':') goto yy989; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1005; + case ':': goto yy989; + default: goto yy57; + } yy1004: - YYDEBUG(1004, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '4') goto yy1005; - if (yych == ':') goto yy989; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy1005; + case ':': goto yy989; + default: goto yy57; + } yy1005: - YYDEBUG(1005, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(1006, *YYCURSOR); + switch (yych) { + case ':': goto yy1006; + default: goto yy57; + } +yy1006: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy1007; - if (yych <= '9') goto yy991; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1007; + case '6': + case '7': + case '8': + case '9': goto yy991; + default: goto yy57; + } yy1007: - YYDEBUG(1007, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy1008; - if (yych <= ':') goto yy992; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1008; + case ':': goto yy992; + default: goto yy57; + } yy1008: - YYDEBUG(1008, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ':') goto yy57; - YYDEBUG(1009, *YYCURSOR); + switch (yych) { + case ':': goto yy1009; + default: goto yy57; + } +yy1009: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy1010; - if (yych <= '6') goto yy1011; - if (yych <= '9') goto yy842; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1010; + case '6': goto yy1011; + case '7': + case '8': + case '9': goto yy842; + default: goto yy57; + } yy1010: - YYDEBUG(1010, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '9') goto yy1012; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1012; + default: goto yy843; + } yy1011: - YYDEBUG(1011, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '0') goto yy843; + switch (yych) { + case '0': goto yy1012; + default: goto yy843; + } yy1012: - YYDEBUG(1012, *YYCURSOR); yyaccept = 23; yych = *(YYMARKER = ++YYCURSOR); - if (yych != '.') goto yy843; - YYDEBUG(1013, *YYCURSOR); + switch (yych) { + case '.': goto yy1013; + default: goto yy843; + } +yy1013: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1014; + default: goto yy57; + } yy1014: - YYDEBUG(1014, *YYCURSOR); yyaccept = 23; YYMARKER = ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); yych = *YYCURSOR; - YYDEBUG(1015, *YYCURSOR); - if (yych <= '-') { - if (yych == '+') goto yy1017; - if (yych <= ',') goto yy843; - goto yy1017; - } else { - if (yych <= '9') { - if (yych <= '/') goto yy843; - goto yy1014; - } else { - if (yych != 'G') goto yy843; - } + switch (yych) { + case '+': + case '-': goto yy1017; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1014; + case 'G': goto yy1016; + default: goto yy843; } - YYDEBUG(1016, *YYCURSOR); +yy1016: yych = *++YYCURSOR; - if (yych == 'M') goto yy1023; - goto yy57; + switch (yych) { + case 'M': goto yy1023; + default: goto yy57; + } yy1017: - YYDEBUG(1017, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy1018; - if (yych <= '2') goto yy1019; - if (yych <= '9') goto yy1020; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy1018; + case '2': goto yy1019; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1020; + default: goto yy57; + } yy1018: - YYDEBUG(1018, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '9') goto yy1020; - if (yych <= ':') goto yy1021; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1020; + case ':': goto yy1021; + default: goto yy843; + } yy1019: - YYDEBUG(1019, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '5') { - if (yych <= '/') goto yy843; - if (yych >= '5') goto yy1022; - } else { - if (yych <= '9') goto yy842; - if (yych <= ':') goto yy1021; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy1020; + case '5': goto yy1022; + case '6': + case '7': + case '8': + case '9': goto yy842; + case ':': goto yy1021; + default: goto yy843; } yy1020: - YYDEBUG(1020, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '5') goto yy1022; - if (yych <= '9') goto yy842; - if (yych >= ';') goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1022; + case '6': + case '7': + case '8': + case '9': goto yy842; + case ':': goto yy1021; + default: goto yy843; + } yy1021: - YYDEBUG(1021, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '5') goto yy1022; - if (yych <= '9') goto yy842; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1022; + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy843; + } yy1022: - YYDEBUG(1022, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy843; - if (yych <= '9') goto yy842; - goto yy843; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy842; + default: goto yy843; + } yy1023: - YYDEBUG(1023, *YYCURSOR); yych = *++YYCURSOR; - if (yych != 'T') goto yy57; - YYDEBUG(1024, *YYCURSOR); + switch (yych) { + case 'T': goto yy1024; + default: goto yy57; + } +yy1024: yych = *++YYCURSOR; - if (yych == '+') goto yy1017; - if (yych == '-') goto yy1017; - goto yy57; + switch (yych) { + case '+': + case '-': goto yy1017; + default: goto yy57; + } yy1025: - YYDEBUG(1025, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy1026; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy1026; + default: goto yy57; + } yy1026: - YYDEBUG(1026, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'E') goto yy880; - if (yych == 'e') goto yy880; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'E': + case 'e': goto yy880; + default: goto yy794; } yy1027: - YYDEBUG(1027, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'V') goto yy1028; - if (yych != 'v') goto yy57; + switch (yych) { + case 'V': + case 'v': goto yy1028; + default: goto yy57; + } yy1028: - YYDEBUG(1028, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'E') goto yy887; - if (yych == 'e') goto yy887; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'E': + case 'e': goto yy887; + default: goto yy794; } yy1029: - YYDEBUG(1029, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1030; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1030; + default: goto yy57; + } yy1030: - YYDEBUG(1030, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'O') goto yy893; - if (yych == 'o') goto yy893; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'O': + case 'o': goto yy893; + default: goto yy794; } yy1031: - YYDEBUG(1031, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy1032; - if (yych != 'p') goto yy57; + switch (yych) { + case 'P': + case 'p': goto yy1032; + default: goto yy57; + } yy1032: - YYDEBUG(1032, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'T') goto yy1033; - if (yych != 't') goto yy794; + switch (yych) { + case '-': goto yy767; + case 'T': + case 't': goto yy1033; + default: goto yy794; } yy1033: - YYDEBUG(1033, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'E') goto yy899; - if (yych == 'e') goto yy899; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'E': + case 'e': goto yy899; + default: goto yy794; } yy1034: - YYDEBUG(1034, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy1037; - if (yych == 'g') goto yy1037; - goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy1037; + default: goto yy57; + } yy1035: - YYDEBUG(1035, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy1036; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy1036; + default: goto yy57; + } yy1036: - YYDEBUG(1036, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'H') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'I') goto yy906; - if (yych == 'i') goto yy906; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'I': + case 'i': goto yy906; + default: goto yy794; } yy1037: - YYDEBUG(1037, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'U') goto yy908; - if (yych == 'u') goto yy908; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'U': + case 'u': goto yy908; + default: goto yy794; } yy1038: - YYDEBUG(1038, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych == 'R') goto yy1039; - if (yych <= 'X') goto yy57; - goto yy1040; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy57; - } else { - if (yych == 'y') goto yy1040; - goto yy57; - } + switch (yych) { + case 'R': + case 'r': goto yy1039; + case 'Y': + case 'y': goto yy1040; + default: goto yy57; } yy1039: - YYDEBUG(1039, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'B') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'C') goto yy912; - if (yych == 'c') goto yy912; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'C': + case 'c': goto yy912; + default: goto yy794; } yy1040: - YYDEBUG(1040, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '-') goto yy767; - goto yy794; + switch (yych) { + case '-': goto yy767; + default: goto yy794; + } yy1041: - YYDEBUG(1041, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy1042; - if (yych != 'b') goto yy57; + switch (yych) { + case 'B': + case 'b': goto yy1042; + default: goto yy57; + } yy1042: - YYDEBUG(1042, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'R') goto yy915; - if (yych == 'r') goto yy915; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'R': + case 'r': goto yy915; + default: goto yy794; } yy1043: - YYDEBUG(1043, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'L') goto yy1047; - if (yych <= 'M') goto yy57; - goto yy1046; - } else { - if (yych <= 'l') { - if (yych <= 'k') goto yy57; - goto yy1047; - } else { - if (yych == 'n') goto yy1046; - goto yy57; - } + switch (yych) { + case 'L': + case 'l': goto yy1047; + case 'N': + case 'n': goto yy1046; + default: goto yy57; } yy1044: - YYDEBUG(1044, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy1045; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy1045; + default: goto yy57; + } yy1045: - YYDEBUG(1045, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'U') goto yy922; - if (yych == 'u') goto yy922; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'U': + case 'u': goto yy922; + default: goto yy794; } yy1046: - YYDEBUG(1046, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'E') goto yy884; - if (yych == 'e') goto yy884; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'E': + case 'e': goto yy884; + default: goto yy794; } yy1047: - YYDEBUG(1047, *YYCURSOR); yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych == '-') goto yy767; - goto yy794; - } else { - if (yych <= 'Y') goto yy884; - if (yych == 'y') goto yy884; - goto yy794; + switch (yych) { + case '-': goto yy767; + case 'Y': + case 'y': goto yy884; + default: goto yy794; } yy1048: - YYDEBUG(1048, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy578; - goto yy731; - } else { - if (yych <= ',') goto yy578; - if (yych <= '-') goto yy732; - goto yy731; - } - } else { - if (yych <= 'U') { - if (yych <= '/') goto yy730; - if (yych <= 'T') goto yy578; - goto yy78; - } else { - if (yych == 'u') goto yy78; - goto yy578; - } + switch (yych) { + case '\t': + case '.': goto yy731; + case '-': goto yy732; + case '/': goto yy730; + case 'U': + case 'u': goto yy78; + default: goto yy578; } yy1049: - YYDEBUG(1049, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'P') { - if (yych == 'C') goto yy129; - if (yych <= 'O') goto yy57; - goto yy586; - } else { - if (yych <= 'c') { - if (yych <= 'b') goto yy57; - goto yy129; - } else { - if (yych == 'p') goto yy586; - goto yy57; - } + switch (yych) { + case 'C': + case 'c': goto yy129; + case 'P': + case 'p': goto yy586; + default: goto yy57; } yy1050: - YYDEBUG(1050, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '9') { - if (yych <= ',') { - if (yych == '\t') goto yy1052; - goto yy1054; - } else { - if (yych <= '-') goto yy1051; - if (yych <= '.') goto yy731; - if (yych <= '/') goto yy730; - goto yy741; - } - } else { - if (yych <= 'q') { - if (yych == 'n') goto yy470; - goto yy1054; - } else { - if (yych <= 'r') goto yy471; - if (yych <= 's') goto yy464; - if (yych <= 't') goto yy468; - goto yy1054; - } + switch (yych) { + case '\t': goto yy1052; + case '-': goto yy1051; + case '.': goto yy731; + case '/': goto yy730; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy741; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy1054; } yy1051: - YYDEBUG(1051, *YYCURSOR); yych = *++YYCURSOR; - YYDEBUG(-1, yych); switch (yych) { case '0': goto yy1055; case '1': goto yy1056; @@ -15431,21 +22094,25 @@ static int scan(Scanner *s) default: goto yy578; } yy1052: - YYDEBUG(1052, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy1054; - if (yych <= '0') goto yy736; - if (yych <= '1') goto yy737; - if (yych <= '9') goto yy738; - goto yy1054; + switch (yych) { + case '0': goto yy736; + case '1': goto yy737; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy738; + default: goto yy1054; + } yy1053: - YYDEBUG(1053, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); yych = *YYCURSOR; yy1054: - YYDEBUG(1054, *YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': goto yy1053; @@ -15481,179 +22148,207 @@ static int scan(Scanner *s) default: goto yy57; } yy1055: - YYDEBUG(1055, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy655; - goto yy602; - } else { - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy1057; - goto yy57; + switch (yych) { + case '-': goto yy655; + case '.': goto yy602; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1057; + default: goto yy57; } yy1056: - YYDEBUG(1056, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '.') { - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy655; - goto yy602; - } else { - if (yych <= '/') goto yy57; - if (yych >= '3') goto yy57; + switch (yych) { + case '-': goto yy655; + case '.': goto yy602; + case '0': + case '1': + case '2': goto yy1057; + default: goto yy57; } yy1057: - YYDEBUG(1057, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= ',') goto yy57; - if (yych <= '-') goto yy1058; - if (yych <= '.') goto yy602; - goto yy57; + switch (yych) { + case '-': goto yy1058; + case '.': goto yy602; + default: goto yy57; + } yy1058: - YYDEBUG(1058, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '2') { - if (yych <= '/') goto yy57; - if (yych >= '1') goto yy1060; - } else { - if (yych <= '3') goto yy1061; - if (yych <= '9') goto yy659; - goto yy57; + switch (yych) { + case '0': goto yy1059; + case '1': + case '2': goto yy1060; + case '3': goto yy1061; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy659; + default: goto yy57; } - YYDEBUG(1059, *YYCURSOR); +yy1059: yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy1062; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1062; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy1060: - YYDEBUG(1060, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy657; - if (yych <= '9') goto yy1062; - if (yych <= 'm') goto yy657; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1062; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy1061: - YYDEBUG(1061, *YYCURSOR); yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '1') { - if (yych <= '/') goto yy657; - } else { - if (yych <= '9') goto yy604; - if (yych <= 'm') goto yy657; - goto yy661; - } - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy657; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy657; - } + switch (yych) { + case '0': + case '1': goto yy1062; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy604; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy657; } yy1062: - YYDEBUG(1062, *YYCURSOR); yyaccept = 15; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'n') { - if (yych <= '/') goto yy764; - if (yych <= '9') goto yy605; - if (yych <= 'm') goto yy764; - goto yy661; - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy764; - goto yy662; - } else { - if (yych <= 's') goto yy660; - if (yych <= 't') goto yy663; - goto yy764; - } + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy605; + case 'n': goto yy661; + case 'r': goto yy662; + case 's': goto yy660; + case 't': goto yy663; + default: goto yy764; } yy1063: - YYDEBUG(1063, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '9') { - if (yych <= '-') { - if (yych == '\t') goto yy1052; - if (yych <= ',') goto yy1054; - goto yy1051; - } else { - if (yych <= '.') goto yy1064; - if (yych <= '/') goto yy730; - if (yych <= '5') goto yy1066; - goto yy741; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy1065; - if (yych == 'n') goto yy470; - goto yy1054; - } else { - if (yych <= 'r') goto yy471; - if (yych <= 's') goto yy464; - if (yych <= 't') goto yy468; - goto yy1054; - } + switch (yych) { + case '\t': goto yy1052; + case '-': goto yy1051; + case '.': goto yy1064; + case '/': goto yy730; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1066; + case '6': + case '7': + case '8': + case '9': goto yy741; + case ':': goto yy1065; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy1054; } yy1064: - YYDEBUG(1064, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '1') { - if (yych <= '/') goto yy578; - if (yych <= '0') goto yy1088; - goto yy1089; - } else { - if (yych <= '5') goto yy1090; - if (yych <= '9') goto yy1091; - goto yy578; + switch (yych) { + case '0': goto yy1088; + case '1': goto yy1089; + case '2': + case '3': + case '4': + case '5': goto yy1090; + case '6': + case '7': + case '8': + case '9': goto yy1091; + default: goto yy578; } yy1065: - YYDEBUG(1065, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy1083; - if (yych <= '9') goto yy1084; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1083; + case '6': + case '7': + case '8': + case '9': goto yy1084; + default: goto yy57; + } yy1066: - YYDEBUG(1066, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '-') goto yy785; - if (yych <= '/') goto yy61; - if (yych >= ':') goto yy61; - YYDEBUG(1067, *YYCURSOR); + switch (yych) { + case '-': goto yy785; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1067; + default: goto yy61; + } +yy1067: yyaccept = 24; yych = *(YYMARKER = ++YYCURSOR); - YYDEBUG(-1, yych); switch (yych) { case '\t': case ' ': @@ -15701,7 +22396,6 @@ static int scan(Scanner *s) default: goto yy1068; } yy1068: - YYDEBUG(1068, *YYCURSOR); #line 1199 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("gnunocolon"); @@ -15724,98 +22418,132 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_GNU_NOCOLON; } -#line 15728 "ext/date/lib/parse_date.c" +#line 22422 "" yy1069: - YYDEBUG(1069, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '0') goto yy1081; - if (yych <= '9') goto yy1082; - goto yy61; + switch (yych) { + case '0': goto yy1081; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1082; + default: goto yy61; + } yy1070: - YYDEBUG(1070, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '2') goto yy1080; - if (yych <= '9') goto yy1079; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': goto yy1080; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1079; + default: goto yy61; + } yy1071: - YYDEBUG(1071, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy1079; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1079; + default: goto yy61; + } yy1072: - YYDEBUG(1072, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '5') goto yy1077; - if (yych <= '6') goto yy1078; - if (yych <= '9') goto yy1075; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1077; + case '6': goto yy1078; + case '7': + case '8': + case '9': goto yy1075; + default: goto yy61; + } yy1073: - YYDEBUG(1073, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '9') goto yy1075; - goto yy61; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1075; + default: goto yy61; + } yy1074: - YYDEBUG(1074, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy61; - if (yych <= '0') goto yy1075; - if (yych <= '9') goto yy55; - goto yy61; + switch (yych) { + case '0': goto yy1075; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy61; + } yy1075: - YYDEBUG(1075, *YYCURSOR); yyaccept = 25; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 2) { - goto yy55; - } - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych >= ' ') goto yy61; - } else { - if (yych == 'D') goto yy61; - if (yych >= 'F') goto yy61; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy61; - if (yych >= 'M') goto yy61; - } else { - if (yych <= 'R') goto yy1076; - if (yych <= 'T') goto yy61; - if (yych >= 'W') goto yy61; - } - } - } else { - if (yych <= 'h') { - if (yych <= 'd') { - if (yych == 'Y') goto yy61; - if (yych >= 'd') goto yy61; - } else { - if (yych == 'f') goto yy61; - if (yych >= 'h') goto yy61; - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych >= 's') goto yy61; - } else { - if (yych <= 'w') { - if (yych >= 'w') goto yy61; - } else { - if (yych == 'y') goto yy61; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + default: goto yy1076; } yy1076: - YYDEBUG(1076, *YYCURSOR); #line 1245 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -15835,904 +22563,829 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_ISO_NOCOLON; } -#line 15839 "ext/date/lib/parse_date.c" +#line 22567 "" yy1077: - YYDEBUG(1077, *YYCURSOR); yyaccept = 25; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy1076; - goto yy61; - } else { - if (yych <= '/') goto yy1076; - if (yych <= '9') goto yy821; - if (yych <= 'C') goto yy1076; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy1076; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy1076; - goto yy61; - } else { - if (yych <= 'R') goto yy1076; - if (yych <= 'T') goto yy61; - goto yy1076; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy1076; - if (yych <= 'Y') goto yy61; - goto yy1076; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy1076; - } else { - if (yych == 'g') goto yy1076; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy1076; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy1076; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy1076; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy1076; } yy1078: - YYDEBUG(1078, *YYCURSOR); yyaccept = 25; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy1076; - goto yy61; - } else { - if (yych <= '6') { - if (yych <= '/') goto yy1076; - goto yy821; - } else { - if (yych <= '9') goto yy55; - if (yych <= 'C') goto yy1076; - goto yy61; - } - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy1076; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy1076; - goto yy61; - } else { - if (yych <= 'R') goto yy1076; - if (yych <= 'T') goto yy61; - goto yy1076; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy1076; - if (yych <= 'Y') goto yy61; - goto yy1076; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy1076; - } else { - if (yych == 'g') goto yy1076; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy1076; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy1076; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy1076; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': goto yy821; + case '7': + case '8': + case '9': goto yy55; + default: goto yy1076; } yy1079: - YYDEBUG(1079, *YYCURSOR); yyaccept = 25; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= 'D') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy1076; - goto yy61; - } else { - if (yych <= '/') goto yy1076; - if (yych <= '9') goto yy821; - if (yych <= 'C') goto yy1076; - goto yy61; - } - } else { - if (yych <= 'H') { - if (yych == 'F') goto yy61; - if (yych <= 'G') goto yy1076; - goto yy61; - } else { - if (yych <= 'M') { - if (yych <= 'L') goto yy1076; - goto yy61; - } else { - if (yych <= 'R') goto yy1076; - if (yych <= 'T') goto yy61; - goto yy1076; - } - } - } - } else { - if (yych <= 'h') { - if (yych <= 'c') { - if (yych == 'X') goto yy1076; - if (yych <= 'Y') goto yy61; - goto yy1076; - } else { - if (yych <= 'e') { - if (yych <= 'd') goto yy61; - goto yy1076; - } else { - if (yych == 'g') goto yy1076; - goto yy61; - } - } - } else { - if (yych <= 't') { - if (yych == 'm') goto yy61; - if (yych <= 'r') goto yy1076; - goto yy61; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy1076; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy1076; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy1076; } yy1080: - YYDEBUG(1080, *YYCURSOR); - yyaccept = 25; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '9') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy1076; - goto yy61; - } else { - if (yych <= '0') { - if (yych <= '/') goto yy1076; - goto yy845; - } else { - if (yych <= '2') goto yy846; - if (yych <= '3') goto yy847; - goto yy821; - } - } - } else { - if (yych <= 'G') { - if (yych <= 'D') { - if (yych <= 'C') goto yy1076; - goto yy61; - } else { - if (yych == 'F') goto yy61; - goto yy1076; - } - } else { - if (yych <= 'L') { - if (yych <= 'H') goto yy61; - goto yy1076; - } else { - if (yych <= 'M') goto yy61; - if (yych <= 'R') goto yy1076; - goto yy61; - } - } - } - } else { - if (yych <= 'g') { - if (yych <= 'Y') { - if (yych == 'W') goto yy61; - if (yych <= 'X') goto yy1076; - goto yy61; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy1076; - goto yy61; - } else { - if (yych == 'f') goto yy61; - goto yy1076; - } - } - } else { - if (yych <= 't') { - if (yych <= 'l') { - if (yych <= 'h') goto yy61; - goto yy1076; - } else { - if (yych <= 'm') goto yy61; - if (yych <= 'r') goto yy1076; - goto yy61; - } - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy1076; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy1076; - } - } - } - } -yy1081: - YYDEBUG(1081, *YYCURSOR); yyaccept = 25; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '9') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy1076; - goto yy61; - } else { - if (yych <= '0') { - if (yych <= '/') goto yy1076; - goto yy877; - } else { - if (yych <= '2') goto yy846; - if (yych <= '3') goto yy847; - goto yy821; - } - } - } else { - if (yych <= 'G') { - if (yych <= 'D') { - if (yych <= 'C') goto yy1076; - goto yy61; - } else { - if (yych == 'F') goto yy61; - goto yy1076; - } - } else { - if (yych <= 'L') { - if (yych <= 'H') goto yy61; - goto yy1076; - } else { - if (yych <= 'M') goto yy61; - if (yych <= 'R') goto yy1076; - goto yy61; - } - } - } - } else { - if (yych <= 'g') { - if (yych <= 'Y') { - if (yych == 'W') goto yy61; - if (yych <= 'X') goto yy1076; - goto yy61; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy1076; - goto yy61; - } else { - if (yych == 'f') goto yy61; - goto yy1076; - } - } - } else { - if (yych <= 't') { - if (yych <= 'l') { - if (yych <= 'h') goto yy61; - goto yy1076; - } else { - if (yych <= 'm') goto yy61; - if (yych <= 'r') goto yy1076; - goto yy61; - } - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy1076; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy1076; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': goto yy845; + case '1': + case '2': goto yy846; + case '3': goto yy847; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy1076; + } +yy1081: + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': goto yy877; + case '1': + case '2': goto yy846; + case '3': goto yy847; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy1076; } yy1082: - YYDEBUG(1082, *YYCURSOR); yyaccept = 25; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '9') { - if (yych <= ' ') { - if (yych == '\t') goto yy61; - if (yych <= 0x1F) goto yy1076; - goto yy61; - } else { - if (yych <= '0') { - if (yych <= '/') goto yy1076; - goto yy845; - } else { - if (yych <= '2') goto yy846; - if (yych <= '3') goto yy847; - goto yy821; - } - } - } else { - if (yych <= 'G') { - if (yych <= 'D') { - if (yych <= 'C') goto yy1076; - goto yy61; - } else { - if (yych == 'F') goto yy61; - goto yy1076; - } - } else { - if (yych <= 'L') { - if (yych <= 'H') goto yy61; - goto yy1076; - } else { - if (yych <= 'M') goto yy61; - if (yych <= 'R') goto yy1076; - goto yy61; - } - } - } - } else { - if (yych <= 'g') { - if (yych <= 'Y') { - if (yych == 'W') goto yy61; - if (yych <= 'X') goto yy1076; - goto yy61; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy1076; - goto yy61; - } else { - if (yych == 'f') goto yy61; - goto yy1076; - } - } - } else { - if (yych <= 't') { - if (yych <= 'l') { - if (yych <= 'h') goto yy61; - goto yy1076; - } else { - if (yych <= 'm') goto yy61; - if (yych <= 'r') goto yy1076; - goto yy61; - } - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy1076; - goto yy61; - } else { - if (yych == 'y') goto yy61; - goto yy1076; - } - } - } + switch (yych) { + case '\t': + case ' ': + case 'D': + case 'F': + case 'H': + case 'M': + case 'S': + case 'T': + case 'W': + case 'Y': + case 'd': + case 'f': + case 'h': + case 'm': + case 's': + case 't': + case 'w': + case 'y': goto yy61; + case '0': goto yy845; + case '1': + case '2': goto yy846; + case '3': goto yy847; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy821; + default: goto yy1076; } yy1083: - YYDEBUG(1083, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy1085; - goto yy491; - } else { - if (yych <= '9') goto yy1084; - if (yych <= ':') goto yy1085; - goto yy491; + switch (yych) { + case '.': + case ':': goto yy1085; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1084; + default: goto yy491; } yy1084: - YYDEBUG(1084, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy1085; - if (yych != ':') goto yy491; + switch (yych) { + case '.': + case ':': goto yy1085; + default: goto yy491; + } yy1085: - YYDEBUG(1085, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy1086; - if (yych <= '6') goto yy1087; - if (yych <= '9') goto yy496; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1086; + case '6': goto yy1087; + case '7': + case '8': + case '9': goto yy496; + default: goto yy57; + } yy1086: - YYDEBUG(1086, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy496; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy496; + default: goto yy491; + } yy1087: - YYDEBUG(1087, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych == '0') goto yy496; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': goto yy496; + default: goto yy491; + } yy1088: - YYDEBUG(1088, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - goto yy1092; - } else { - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy1091; - if (yych <= ':') goto yy1085; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy1092; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1091; + case ':': goto yy1085; + default: goto yy491; } yy1089: - YYDEBUG(1089, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - if (yych <= '.') goto yy1092; - goto yy491; - } else { - if (yych <= '2') goto yy1091; - if (yych <= '9') goto yy1084; - if (yych <= ':') goto yy1085; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy1092; + case '0': + case '1': + case '2': goto yy1091; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1084; + case ':': goto yy1085; + default: goto yy491; } yy1090: - YYDEBUG(1090, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - goto yy1092; - } else { - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy1084; - if (yych <= ':') goto yy1085; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy1092; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1084; + case ':': goto yy1085; + default: goto yy491; } yy1091: - YYDEBUG(1091, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ',') goto yy491; - if (yych <= '-') goto yy602; - } else { - if (yych == ':') goto yy1085; - goto yy491; + switch (yych) { + case '-': goto yy602; + case '.': goto yy1092; + case ':': goto yy1085; + default: goto yy491; } yy1092: - YYDEBUG(1092, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '5') goto yy1093; - if (yych <= '6') goto yy1094; - if (yych <= '9') goto yy610; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1093; + case '6': goto yy1094; + case '7': + case '8': + case '9': goto yy610; + default: goto yy57; + } yy1093: - YYDEBUG(1093, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy1095; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1095; + default: goto yy491; + } yy1094: - YYDEBUG(1094, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych == '.') goto yy497; - goto yy491; - } else { - if (yych <= '0') goto yy1095; - if (yych <= '9') goto yy611; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': goto yy1095; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy611; + default: goto yy491; } yy1095: - YYDEBUG(1095, *YYCURSOR); yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '.') goto yy497; - if (yych <= '/') goto yy491; - if (yych <= '9') goto yy605; - goto yy491; + switch (yych) { + case '.': goto yy497; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy605; + default: goto yy491; + } yy1096: - YYDEBUG(1096, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '9') { - if (yych <= '-') { - if (yych == '\t') goto yy460; - if (yych <= ',') goto yy462; - goto yy1051; - } else { - if (yych <= '.') goto yy474; - if (yych <= '/') goto yy472; - if (yych <= '5') goto yy1066; - goto yy741; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy483; - if (yych == 'n') goto yy470; - goto yy462; - } else { - if (yych <= 'r') goto yy471; - if (yych <= 's') goto yy464; - if (yych <= 't') goto yy468; - goto yy462; - } + switch (yych) { + case '\t': goto yy460; + case '-': goto yy1051; + case '.': goto yy474; + case '/': goto yy472; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1066; + case '6': + case '7': + case '8': + case '9': goto yy741; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy462; } yy1097: - YYDEBUG(1097, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '9') { - if (yych <= '-') { - if (yych == '\t') goto yy1052; - if (yych <= ',') goto yy1054; - goto yy1051; - } else { - if (yych <= '.') goto yy1064; - if (yych <= '/') goto yy472; - if (yych <= '5') goto yy1066; - goto yy741; - } - } else { - if (yych <= 'q') { - if (yych <= ':') goto yy1065; - if (yych == 'n') goto yy470; - goto yy1054; - } else { - if (yych <= 'r') goto yy471; - if (yych <= 's') goto yy464; - if (yych <= 't') goto yy468; - goto yy1054; - } + switch (yych) { + case '\t': goto yy1052; + case '-': goto yy1051; + case '.': goto yy1064; + case '/': goto yy472; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1066; + case '6': + case '7': + case '8': + case '9': goto yy741; + case ':': goto yy1065; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy1054; } yy1098: - YYDEBUG(1098, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy142; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'e') goto yy1099; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'E': + case 'e': goto yy1099; + default: goto yy4; } yy1099: - YYDEBUG(1099, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'V') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'U') goto yy143; - } - } else { - if (yych <= 'u') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'v') goto yy1100; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'V': + case 'v': goto yy1100; + default: goto yy4; } yy1100: - YYDEBUG(1100, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'I') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'H') goto yy144; - } - } else { - if (yych <= 'h') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'i') goto yy1101; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'I': + case 'i': goto yy1101; + default: goto yy4; } yy1101: - YYDEBUG(1101, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'N') goto yy145; - } - } else { - if (yych <= 'n') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'o') goto yy1102; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'O': + case 'o': goto yy1102; + default: goto yy4; } yy1102: - YYDEBUG(1102, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'U') goto yy1103; - if (yych != 'u') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'U': + case 'u': goto yy1103; + default: goto yy4; } yy1103: - YYDEBUG(1103, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'S') goto yy1104; - if (yych != 's') goto yy57; -yy1104: - YYDEBUG(1104, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\t') goto yy1105; - if (yych != ' ') goto yy57; -yy1105: - YYDEBUG(1105, *YYCURSOR); - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); - yych = *YYCURSOR; -yy1106: - YYDEBUG(1106, *YYCURSOR); - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy1105; - if (yych <= 0x1F) goto yy57; - goto yy1105; - } else { - if (yych == 'D') goto yy1110; - if (yych <= 'E') goto yy57; - goto yy1111; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy1109; - if (yych <= 'L') goto yy57; - goto yy1108; - } else { - if (yych <= 'S') { - if (yych <= 'R') goto yy57; - } else { - if (yych <= 'T') goto yy1114; - if (yych <= 'V') goto yy57; - goto yy1113; - } - } - } - } else { - if (yych <= 'l') { - if (yych <= 'd') { - if (yych == 'Y') goto yy1112; - if (yych <= 'c') goto yy57; - goto yy1110; - } else { - if (yych <= 'f') { - if (yych <= 'e') goto yy57; - goto yy1111; - } else { - if (yych == 'h') goto yy1109; - goto yy57; - } - } - } else { - if (yych <= 't') { - if (yych <= 'm') goto yy1108; - if (yych <= 'r') goto yy57; - if (yych >= 't') goto yy1114; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy57; - goto yy1113; - } else { - if (yych == 'y') goto yy1112; - goto yy57; - } - } - } + switch (yych) { + case 'S': + case 's': goto yy1104; + default: goto yy57; + } +yy1104: + yych = *++YYCURSOR; + switch (yych) { + case '\t': + case ' ': goto yy1105; + default: goto yy57; + } +yy1105: + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); + yych = *YYCURSOR; +yy1106: + switch (yych) { + case '\t': + case ' ': goto yy1105; + case 'D': + case 'd': goto yy1110; + case 'F': + case 'f': goto yy1111; + case 'H': + case 'h': goto yy1109; + case 'M': + case 'm': goto yy1108; + case 'S': + case 's': goto yy1107; + case 'T': + case 't': goto yy1114; + case 'W': + case 'w': goto yy1113; + case 'Y': + case 'y': goto yy1112; + default: goto yy57; } yy1107: - YYDEBUG(1107, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= 'D') { - if (yych == 'A') goto yy1179; - goto yy57; - } else { - if (yych <= 'E') goto yy1180; - if (yych <= 'T') goto yy57; - goto yy1178; - } - } else { - if (yych <= 'd') { - if (yych == 'a') goto yy1179; - goto yy57; - } else { - if (yych <= 'e') goto yy1180; - if (yych == 'u') goto yy1178; - goto yy57; - } + switch (yych) { + case 'A': + case 'a': goto yy1179; + case 'E': + case 'e': goto yy1180; + case 'U': + case 'u': goto yy1178; + default: goto yy57; } yy1108: - YYDEBUG(1108, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych == 'I') goto yy1170; - if (yych <= 'N') goto yy57; - goto yy1169; - } else { - if (yych <= 'i') { - if (yych <= 'h') goto yy57; - goto yy1170; - } else { - if (yych == 'o') goto yy1169; - goto yy57; - } + switch (yych) { + case 'I': + case 'i': goto yy1170; + case 'O': + case 'o': goto yy1169; + default: goto yy57; } yy1109: - YYDEBUG(1109, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy1167; - if (yych == 'o') goto yy1167; - goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy1167; + default: goto yy57; + } yy1110: - YYDEBUG(1110, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1166; - if (yych == 'a') goto yy1166; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1166; + default: goto yy57; + } yy1111: - YYDEBUG(1111, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych == 'O') goto yy1151; - if (yych <= 'Q') goto yy57; - goto yy1150; - } else { - if (yych <= 'o') { - if (yych <= 'n') goto yy57; - goto yy1151; - } else { - if (yych == 'r') goto yy1150; - goto yy57; - } + switch (yych) { + case 'O': + case 'o': goto yy1151; + case 'R': + case 'r': goto yy1150; + default: goto yy57; } yy1112: - YYDEBUG(1112, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1147; - if (yych == 'e') goto yy1147; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1147; + default: goto yy57; + } yy1113: - YYDEBUG(1113, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1133; - if (yych == 'e') goto yy1133; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1133; + default: goto yy57; + } yy1114: - YYDEBUG(1114, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych == 'H') goto yy1115; - if (yych <= 'T') goto yy57; - goto yy1116; - } else { - if (yych <= 'h') { - if (yych <= 'g') goto yy57; - } else { - if (yych == 'u') goto yy1116; - goto yy57; - } + switch (yych) { + case 'H': + case 'h': goto yy1115; + case 'U': + case 'u': goto yy1116; + default: goto yy57; } yy1115: - YYDEBUG(1115, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy1128; - if (yych == 'u') goto yy1128; - goto yy57; + switch (yych) { + case 'U': + case 'u': goto yy1128; + default: goto yy57; + } yy1116: - YYDEBUG(1116, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1117; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1117; + default: goto yy57; + } yy1117: - YYDEBUG(1117, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych >= ' ') goto yy1119; - } else { - if (yych <= 'S') { - if (yych >= 'S') goto yy1121; - } else { - if (yych == 's') goto yy1121; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'S': + case 's': goto yy1121; + default: goto yy1118; } yy1118: - YYDEBUG(1118, *YYCURSOR); #line 1629 "ext/date/lib/parse_date.re" { timelib_sll i; @@ -16749,57 +23402,56 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 16753 "ext/date/lib/parse_date.c" +#line 23406 "" yy1119: - YYDEBUG(1119, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; - YYDEBUG(1120, *YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych <= 0x1F) goto yy57; - goto yy1119; - } else { - if (yych <= 'O') { - if (yych <= 'N') goto yy57; - goto yy1125; - } else { - if (yych == 'o') goto yy1125; - goto yy57; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'O': + case 'o': goto yy1125; + default: goto yy57; } yy1121: - YYDEBUG(1121, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1122; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1122; + default: goto yy57; + } yy1122: - YYDEBUG(1122, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1123; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1123; + default: goto yy57; + } yy1123: - YYDEBUG(1123, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1124: - YYDEBUG(1124, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '\t') goto yy1119; - if (yych == ' ') goto yy1119; - goto yy1118; + switch (yych) { + case '\t': + case ' ': goto yy1119; + default: goto yy1118; + } yy1125: - YYDEBUG(1125, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy1126; - if (yych != 'f') goto yy57; + switch (yych) { + case 'F': + case 'f': goto yy1126; + default: goto yy57; + } yy1126: - YYDEBUG(1126, *YYCURSOR); ++YYCURSOR; - YYDEBUG(1127, *YYCURSOR); #line 1114 "ext/date/lib/parse_date.re" { timelib_sll i; @@ -16821,114 +23473,117 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_WEEK_DAY_OF_MONTH; } -#line 16825 "ext/date/lib/parse_date.c" +#line 23477 "" yy1128: - YYDEBUG(1128, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych <= 0x1F) goto yy1118; - goto yy1119; - } else { - if (yych <= 'R') { - if (yych <= 'Q') goto yy1118; - } else { - if (yych != 'r') goto yy1118; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'R': + case 'r': goto yy1129; + default: goto yy1118; } - YYDEBUG(1129, *YYCURSOR); +yy1129: yych = *++YYCURSOR; - if (yych == 'S') goto yy1130; - if (yych != 's') goto yy57; + switch (yych) { + case 'S': + case 's': goto yy1130; + default: goto yy57; + } yy1130: - YYDEBUG(1130, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1131; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1131; + default: goto yy57; + } yy1131: - YYDEBUG(1131, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1132; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1132; + default: goto yy57; + } yy1132: - YYDEBUG(1132, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych == 'y') goto yy1124; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1133: - YYDEBUG(1133, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= 'C') goto yy57; - if (yych <= 'D') goto yy1135; - } else { - if (yych <= 'c') goto yy57; - if (yych <= 'd') goto yy1135; - if (yych >= 'f') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1135; + case 'E': + case 'e': goto yy1134; + default: goto yy57; } - YYDEBUG(1134, *YYCURSOR); +yy1134: yych = *++YYCURSOR; - if (yych == 'K') goto yy1141; - if (yych == 'k') goto yy1141; - goto yy57; + switch (yych) { + case 'K': + case 'k': goto yy1141; + default: goto yy57; + } yy1135: - YYDEBUG(1135, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych <= 0x1F) goto yy1118; - goto yy1119; - } else { - if (yych <= 'N') { - if (yych <= 'M') goto yy1118; - } else { - if (yych != 'n') goto yy1118; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'N': + case 'n': goto yy1136; + default: goto yy1118; } - YYDEBUG(1136, *YYCURSOR); +yy1136: yych = *++YYCURSOR; - if (yych == 'E') goto yy1137; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1137; + default: goto yy57; + } yy1137: - YYDEBUG(1137, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy1138; - if (yych != 's') goto yy57; + switch (yych) { + case 'S': + case 's': goto yy1138; + default: goto yy57; + } yy1138: - YYDEBUG(1138, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1139; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1139; + default: goto yy57; + } yy1139: - YYDEBUG(1139, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1140; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1140; + default: goto yy57; + } yy1140: - YYDEBUG(1140, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych == 'y') goto yy1124; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1141: - YYDEBUG(1141, *YYCURSOR); yyaccept = 27; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych == 'D') goto yy1144; - if (yych >= 'S') goto yy1143; - } else { - if (yych <= 'd') { - if (yych >= 'd') goto yy1144; - } else { - if (yych == 's') goto yy1143; - } + switch (yych) { + case 'D': + case 'd': goto yy1144; + case 'S': + case 's': goto yy1143; + default: goto yy1142; } yy1142: - YYDEBUG(1142, *YYCURSOR); #line 1605 "ext/date/lib/parse_date.re" { timelib_sll i; @@ -16952,2683 +23607,5020 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 16956 "ext/date/lib/parse_date.c" +#line 23611 "" yy1143: - YYDEBUG(1143, *YYCURSOR); yych = *++YYCURSOR; goto yy1118; yy1144: - YYDEBUG(1144, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1145; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1145; + default: goto yy57; + } yy1145: - YYDEBUG(1145, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1146; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1146; + default: goto yy57; + } yy1146: - YYDEBUG(1146, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy1143; - if (yych == 's') goto yy1143; - goto yy1118; + switch (yych) { + case 'S': + case 's': goto yy1143; + default: goto yy1118; + } yy1147: - YYDEBUG(1147, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1148; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1148; + default: goto yy57; + } yy1148: - YYDEBUG(1148, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy1149; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy1149; + default: goto yy57; + } yy1149: - YYDEBUG(1149, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy1143; - if (yych == 's') goto yy1143; - goto yy1118; + switch (yych) { + case 'S': + case 's': goto yy1143; + default: goto yy1118; + } yy1150: - YYDEBUG(1150, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy1163; - if (yych == 'i') goto yy1163; - goto yy57; + switch (yych) { + case 'I': + case 'i': goto yy1163; + default: goto yy57; + } yy1151: - YYDEBUG(1151, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy1152; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy1152; + default: goto yy57; + } yy1152: - YYDEBUG(1152, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1153; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1153; + default: goto yy57; + } yy1153: - YYDEBUG(1153, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych == 'H') goto yy1155; - if (yych <= 'M') goto yy57; - } else { - if (yych <= 'h') { - if (yych <= 'g') goto yy57; - goto yy1155; - } else { - if (yych != 'n') goto yy57; - } + switch (yych) { + case 'H': + case 'h': goto yy1155; + case 'N': + case 'n': goto yy1154; + default: goto yy57; } - YYDEBUG(1154, *YYCURSOR); +yy1154: yych = *++YYCURSOR; - if (yych == 'I') goto yy1160; - if (yych == 'i') goto yy1160; - goto yy57; + switch (yych) { + case 'I': + case 'i': goto yy1160; + default: goto yy57; + } yy1155: - YYDEBUG(1155, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy1156; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy1156; + default: goto yy57; + } yy1156: - YYDEBUG(1156, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy1157; - if (yych != 'i') goto yy57; + switch (yych) { + case 'I': + case 'i': goto yy1157; + default: goto yy57; + } yy1157: - YYDEBUG(1157, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy1158; - if (yych != 'g') goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy1158; + default: goto yy57; + } yy1158: - YYDEBUG(1158, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy1159; - if (yych != 'h') goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy1159; + default: goto yy57; + } yy1159: - YYDEBUG(1159, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1149; - if (yych == 't') goto yy1149; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1149; + default: goto yy57; + } yy1160: - YYDEBUG(1160, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy1161; - if (yych != 'g') goto yy57; + switch (yych) { + case 'G': + case 'g': goto yy1161; + default: goto yy57; + } yy1161: - YYDEBUG(1161, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy1162; - if (yych != 'h') goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy1162; + default: goto yy57; + } yy1162: - YYDEBUG(1162, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1149; - if (yych == 't') goto yy1149; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1149; + default: goto yy57; + } yy1163: - YYDEBUG(1163, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych <= 0x1F) goto yy1118; - goto yy1119; - } else { - if (yych <= 'D') { - if (yych <= 'C') goto yy1118; - } else { - if (yych != 'd') goto yy1118; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'D': + case 'd': goto yy1164; + default: goto yy1118; } - YYDEBUG(1164, *YYCURSOR); +yy1164: yych = *++YYCURSOR; - if (yych == 'A') goto yy1165; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1165; + default: goto yy57; + } yy1165: - YYDEBUG(1165, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych == 'y') goto yy1124; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1166: - YYDEBUG(1166, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1149; - if (yych == 'y') goto yy1149; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1149; + default: goto yy57; + } yy1167: - YYDEBUG(1167, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy1168; - if (yych != 'u') goto yy57; + switch (yych) { + case 'U': + case 'u': goto yy1168; + default: goto yy57; + } yy1168: - YYDEBUG(1168, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy1149; - if (yych == 'r') goto yy1149; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy1149; + default: goto yy57; + } yy1169: - YYDEBUG(1169, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy1174; - if (yych == 'n') goto yy1174; - goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy1174; + default: goto yy57; + } yy1170: - YYDEBUG(1170, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy1171; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy1171; + default: goto yy57; + } yy1171: - YYDEBUG(1171, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'U') { - if (yych == 'S') goto yy1143; - if (yych <= 'T') goto yy1118; - } else { - if (yych <= 's') { - if (yych <= 'r') goto yy1118; - goto yy1143; - } else { - if (yych != 'u') goto yy1118; - } + switch (yych) { + case 'S': + case 's': goto yy1143; + case 'U': + case 'u': goto yy1172; + default: goto yy1118; } - YYDEBUG(1172, *YYCURSOR); +yy1172: yych = *++YYCURSOR; - if (yych == 'T') goto yy1173; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1173; + default: goto yy57; + } yy1173: - YYDEBUG(1173, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1149; - if (yych == 'e') goto yy1149; - goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1149; + default: goto yy57; + } yy1174: - YYDEBUG(1174, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy1119; - goto yy1118; - } else { - if (yych <= ' ') goto yy1119; - if (yych <= 'C') goto yy1118; - } - } else { - if (yych <= 'c') { - if (yych == 'T') goto yy1176; - goto yy1118; - } else { - if (yych <= 'd') goto yy1175; - if (yych == 't') goto yy1176; - goto yy1118; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'D': + case 'd': goto yy1175; + case 'T': + case 't': goto yy1176; + default: goto yy1118; } yy1175: - YYDEBUG(1175, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1177; - if (yych == 'a') goto yy1177; - goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1177; + default: goto yy57; + } yy1176: - YYDEBUG(1176, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy1149; - if (yych == 'h') goto yy1149; - goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy1149; + default: goto yy57; + } yy1177: - YYDEBUG(1177, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych == 'y') goto yy1124; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1178: - YYDEBUG(1178, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy1189; - if (yych == 'n') goto yy1189; - goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy1189; + default: goto yy57; + } yy1179: - YYDEBUG(1179, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1184; - if (yych == 't') goto yy1184; - goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1184; + default: goto yy57; + } yy1180: - YYDEBUG(1180, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy1181; - if (yych != 'c') goto yy57; + switch (yych) { + case 'C': + case 'c': goto yy1181; + default: goto yy57; + } yy1181: - YYDEBUG(1181, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych == 'O') goto yy1182; - if (yych <= 'R') goto yy1118; - goto yy1143; - } else { - if (yych <= 'o') { - if (yych <= 'n') goto yy1118; - } else { - if (yych == 's') goto yy1143; - goto yy1118; - } + switch (yych) { + case 'O': + case 'o': goto yy1182; + case 'S': + case 's': goto yy1143; + default: goto yy1118; } yy1182: - YYDEBUG(1182, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy1183; - if (yych != 'n') goto yy57; + switch (yych) { + case 'N': + case 'n': goto yy1183; + default: goto yy57; + } yy1183: - YYDEBUG(1183, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1149; - if (yych == 'd') goto yy1149; - goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1149; + default: goto yy57; + } yy1184: - YYDEBUG(1184, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych <= 0x1F) goto yy1118; - goto yy1119; - } else { - if (yych <= 'U') { - if (yych <= 'T') goto yy1118; - } else { - if (yych != 'u') goto yy1118; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'U': + case 'u': goto yy1185; + default: goto yy1118; } - YYDEBUG(1185, *YYCURSOR); +yy1185: yych = *++YYCURSOR; - if (yych == 'R') goto yy1186; - if (yych != 'r') goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy1186; + default: goto yy57; + } yy1186: - YYDEBUG(1186, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1187; - if (yych != 'd') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1187; + default: goto yy57; + } yy1187: - YYDEBUG(1187, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1188; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1188; + default: goto yy57; + } yy1188: - YYDEBUG(1188, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych == 'y') goto yy1124; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1189: - YYDEBUG(1189, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ' ') { - if (yych == '\t') goto yy1119; - if (yych <= 0x1F) goto yy1118; - goto yy1119; - } else { - if (yych <= 'D') { - if (yych <= 'C') goto yy1118; - } else { - if (yych != 'd') goto yy1118; - } + switch (yych) { + case '\t': + case ' ': goto yy1119; + case 'D': + case 'd': goto yy1190; + default: goto yy1118; } - YYDEBUG(1190, *YYCURSOR); +yy1190: yych = *++YYCURSOR; - if (yych == 'A') goto yy1191; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1191; + default: goto yy57; + } yy1191: - YYDEBUG(1191, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1124; - if (yych == 'y') goto yy1124; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1124; + default: goto yy57; + } yy1192: - YYDEBUG(1192, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1099; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'e') goto yy1193; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'E': goto yy1099; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'e': goto yy1193; + default: goto yy4; } yy1193: - YYDEBUG(1193, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'U') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'V') goto yy1100; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'u') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'v') goto yy1194; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'V': goto yy1100; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'v': goto yy1194; + default: goto yy4; } yy1194: - YYDEBUG(1194, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'H') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'I') goto yy1101; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'h') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'i') goto yy1195; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'I': goto yy1101; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'i': goto yy1195; + default: goto yy4; } yy1195: - YYDEBUG(1195, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'O') goto yy1102; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'n') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'o') goto yy1196; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'O': goto yy1102; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'o': goto yy1196; + default: goto yy4; } yy1196: - YYDEBUG(1196, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'U') goto yy1103; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'u') goto yy1197; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'U': goto yy1103; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'u': goto yy1197; + default: goto yy4; } yy1197: - YYDEBUG(1197, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'S') goto yy1104; - if (yych != 's') goto yy155; - YYDEBUG(1198, *YYCURSOR); yych = *++YYCURSOR; - if (yybm[0+yych] & 16) { - goto yy154; + switch (yych) { + case 'S': goto yy1104; + case 's': goto yy1198; + default: goto yy155; } - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy57; - goto yy1105; - } else { - if (yych == ' ') goto yy1105; - goto yy57; - } - } else { - if (yych <= '/') { - if (yych == '.') goto yy57; - goto yy148; - } else { - if (yych == '_') goto yy148; - goto yy57; - } +yy1198: + yych = *++YYCURSOR; + switch (yych) { + case '\t': + case ' ': goto yy1105; + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy57; } yy1199: - YYDEBUG(1199, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'G') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'F') goto yy142; - goto yy1213; - } - } else { - if (yych <= 'f') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'g') goto yy1213; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'G': + case 'g': goto yy1213; + default: goto yy4; } yy1200: - YYDEBUG(1200, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy142; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'e') goto yy1201; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'E': + case 'e': goto yy1201; + default: goto yy4; } yy1201: - YYDEBUG(1201, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'V') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'U') goto yy143; - } - } else { - if (yych <= 'u') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'v') goto yy1202; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'V': + case 'v': goto yy1202; + default: goto yy4; } yy1202: - YYDEBUG(1202, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy144; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'e') goto yy1203; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'E': + case 'e': goto yy1203; + default: goto yy4; } yy1203: - YYDEBUG(1203, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy145; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'n') goto yy1204; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'N': + case 'n': goto yy1204; + default: goto yy4; } yy1204: - YYDEBUG(1204, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'T') goto yy1205; - if (yych != 't') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'T': + case 't': goto yy1205; + default: goto yy4; } yy1205: - YYDEBUG(1205, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy1206; - if (yych != 'h') goto yy57; + switch (yych) { + case 'H': + case 'h': goto yy1206; + default: goto yy57; + } yy1206: - YYDEBUG(1206, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\t') goto yy1207; - if (yych != ' ') goto yy57; + switch (yych) { + case '\t': + case ' ': goto yy1207; + default: goto yy57; + } yy1207: - YYDEBUG(1207, *YYCURSOR); ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); yych = *YYCURSOR; yy1208: - YYDEBUG(1208, *YYCURSOR); - if (yych <= 'W') { - if (yych <= 'F') { - if (yych <= ' ') { - if (yych == '\t') goto yy1207; - if (yych <= 0x1F) goto yy57; - goto yy1207; - } else { - if (yych == 'D') goto yy1110; - if (yych <= 'E') goto yy57; - goto yy1111; - } - } else { - if (yych <= 'M') { - if (yych == 'H') goto yy1109; - if (yych <= 'L') goto yy57; - goto yy1108; - } else { - if (yych <= 'S') { - if (yych <= 'R') goto yy57; - goto yy1107; - } else { - if (yych <= 'T') goto yy1114; - if (yych <= 'V') goto yy57; - } - } - } - } else { - if (yych <= 'l') { - if (yych <= 'd') { - if (yych == 'Y') goto yy1112; - if (yych <= 'c') goto yy57; - goto yy1110; - } else { - if (yych <= 'f') { - if (yych <= 'e') goto yy57; - goto yy1111; - } else { - if (yych == 'h') goto yy1109; - goto yy57; - } - } - } else { - if (yych <= 't') { - if (yych <= 'm') goto yy1108; - if (yych <= 'r') goto yy57; - if (yych <= 's') goto yy1107; - goto yy1114; - } else { - if (yych <= 'w') { - if (yych <= 'v') goto yy57; - } else { - if (yych == 'y') goto yy1112; - goto yy57; - } - } - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case 'D': + case 'd': goto yy1110; + case 'F': + case 'f': goto yy1111; + case 'H': + case 'h': goto yy1109; + case 'M': + case 'm': goto yy1108; + case 'S': + case 's': goto yy1107; + case 'T': + case 't': goto yy1114; + case 'W': + case 'w': goto yy1209; + case 'Y': + case 'y': goto yy1112; + default: goto yy57; } - YYDEBUG(1209, *YYCURSOR); +yy1209: yych = *++YYCURSOR; - if (yych == 'E') goto yy1210; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1210; + default: goto yy57; + } yy1210: - YYDEBUG(1210, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= 'C') goto yy57; - if (yych <= 'D') goto yy1135; - } else { - if (yych <= 'c') goto yy57; - if (yych <= 'd') goto yy1135; - if (yych >= 'f') goto yy57; + switch (yych) { + case 'D': + case 'd': goto yy1135; + case 'E': + case 'e': goto yy1211; + default: goto yy57; } - YYDEBUG(1211, *YYCURSOR); +yy1211: yych = *++YYCURSOR; - if (yych == 'K') goto yy1212; - if (yych != 'k') goto yy57; + switch (yych) { + case 'K': + case 'k': goto yy1212; + default: goto yy57; + } yy1212: - YYDEBUG(1212, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych == 'D') goto yy1144; - if (yych <= 'R') goto yy57; - goto yy1143; - } else { - if (yych <= 'd') { - if (yych <= 'c') goto yy57; - goto yy1144; - } else { - if (yych == 's') goto yy1143; - goto yy57; - } + switch (yych) { + case 'D': + case 'd': goto yy1144; + case 'S': + case 's': goto yy1143; + default: goto yy57; } yy1213: - YYDEBUG(1213, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy143; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'h') goto yy1214; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'H': + case 'h': goto yy1214; + default: goto yy4; } yy1214: - YYDEBUG(1214, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy144; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 't') goto yy1215; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'T': + case 't': goto yy1215; + default: goto yy4; } yy1215: - YYDEBUG(1215, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy1207; - goto yy4; - } else { - if (yych <= ' ') goto yy1207; - if (yych == ')') goto yy140; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych == 'H') goto yy1216; - if (yych <= 'Z') goto yy145; - goto yy4; - } else { - if (yych == 'h') goto yy1216; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'H': + case 'h': goto yy1216; + default: goto yy4; } yy1216: - YYDEBUG(1216, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 0x1F) { - if (yych == '\t') goto yy1207; - goto yy4; - } else { - if (yych <= ' ') goto yy1207; - if (yych == ')') goto yy140; - goto yy4; + switch (yych) { + case '\t': + case ' ': goto yy1207; + case ')': goto yy140; + default: goto yy4; } yy1217: - YYDEBUG(1217, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'F') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'G') goto yy1213; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'f') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'g') goto yy1225; - if (yych <= 'z') goto yy147; - goto yy4; - } - } - } -yy1218: - YYDEBUG(1218, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1201; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'e') goto yy1219; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'G': goto yy1213; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'g': goto yy1225; + default: goto yy4; + } +yy1218: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'E': goto yy1201; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'e': goto yy1219; + default: goto yy4; } yy1219: - YYDEBUG(1219, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'U') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'V') goto yy1202; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'u') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'v') goto yy1220; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'V': goto yy1202; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'v': goto yy1220; + default: goto yy4; } yy1220: - YYDEBUG(1220, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1203; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'e') goto yy1221; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'E': goto yy1203; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'e': goto yy1221; + default: goto yy4; } yy1221: - YYDEBUG(1221, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1204; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'n') goto yy1222; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'N': goto yy1204; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'n': goto yy1222; + default: goto yy4; } yy1222: - YYDEBUG(1222, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'T') goto yy1205; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 't') goto yy1223; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'T': goto yy1205; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 't': goto yy1223; + default: goto yy4; } yy1223: - YYDEBUG(1223, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy1206; - if (yych != 'h') goto yy155; + switch (yych) { + case 'H': goto yy1206; + case 'h': goto yy1224; + default: goto yy155; + } yy1224: - YYDEBUG(1224, *YYCURSOR); yych = *++YYCURSOR; - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= ',') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy57; - goto yy1207; - } else { - if (yych == ' ') goto yy1207; - goto yy57; - } - } else { - if (yych <= '/') { - if (yych == '.') goto yy57; - goto yy148; - } else { - if (yych == '_') goto yy148; - goto yy57; - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy57; } yy1225: - YYDEBUG(1225, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy1214; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'h') goto yy1226; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'H': goto yy1214; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'h': goto yy1226; + default: goto yy4; } yy1226: - YYDEBUG(1226, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1215; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 't') goto yy1227; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'T': goto yy1215; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 't': goto yy1227; + default: goto yy4; } yy1227: - YYDEBUG(1227, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy4; - goto yy1207; - } else { - if (yych == ' ') goto yy1207; - goto yy4; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - goto yy148; - } - } - } else { - if (yych <= '^') { - if (yych <= 'G') { - if (yych <= '@') goto yy4; - goto yy145; - } else { - if (yych <= 'H') goto yy1216; - if (yych <= 'Z') goto yy145; - goto yy4; - } - } else { - if (yych <= 'g') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'h') goto yy1228; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'H': goto yy1216; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'h': goto yy1228; + default: goto yy4; } yy1228: - YYDEBUG(1228, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= ')') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy1207; - goto yy4; - } else { - if (yych <= ' ') goto yy1207; - if (yych <= '(') goto yy4; - goto yy140; - } - } else { - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy4; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy4; } yy1229: - YYDEBUG(1229, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'V') { - if (yych <= 'B') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'O') { - if (yych <= 'C') goto yy1245; - goto yy142; - } else { - if (yych <= 'P') goto yy1247; - if (yych <= 'U') goto yy142; - goto yy1246; - } - } - } else { - if (yych <= 'o') { - if (yych <= '`') { - if (yych <= 'Z') goto yy142; - goto yy4; - } else { - if (yych == 'c') goto yy1245; - goto yy142; - } - } else { - if (yych <= 'u') { - if (yych <= 'p') goto yy1247; - goto yy142; - } else { - if (yych <= 'v') goto yy1246; - if (yych <= 'z') goto yy142; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'C': + case 'c': goto yy1245; + case 'P': + case 'p': goto yy1247; + case 'V': + case 'v': goto yy1246; + default: goto yy4; } yy1230: - YYDEBUG(1230, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy142; - goto yy1240; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 't') goto yy1240; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'T': + case 't': goto yy1240; + default: goto yy4; } yy1231: - YYDEBUG(1231, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'X') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'W') goto yy142; - goto yy1237; - } - } else { - if (yych <= 'w') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'x') goto yy1237; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'y': + case 'z': goto yy142; + case 'X': + case 'x': goto yy1237; + default: goto yy4; } yy1232: - YYDEBUG(1232, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy142; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'n') goto yy1233; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'N': + case 'n': goto yy1233; + default: goto yy4; } yy1233: - YYDEBUG(1233, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy167; - goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'C') goto yy143; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy167; - goto yy143; - } else { - if (yych <= 'd') goto yy1234; - if (yych <= 'z') goto yy143; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'D': + case 'd': goto yy1234; + default: goto yy167; } yy1234: - YYDEBUG(1234, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy144; - goto yy4; - } else { - if (yych <= 'a') goto yy1235; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1235; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy1235: - YYDEBUG(1235, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'X') goto yy145; - } - } else { - if (yych <= 'x') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'y') goto yy1236; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy145; + case 'Y': + case 'y': goto yy1236; + default: goto yy4; } yy1236: - YYDEBUG(1236, *YYCURSOR); yych = *++YYCURSOR; - if (yych == ')') goto yy140; - goto yy167; + switch (yych) { + case ')': goto yy140; + default: goto yy167; + } yy1237: - YYDEBUG(1237, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1238; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1238; + default: goto yy4; } yy1238: - YYDEBUG(1238, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy144; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'h') goto yy1239; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'H': + case 'h': goto yy1239; + default: goto yy4; } yy1239: - YYDEBUG(1239, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy4; - goto yy1207; - } else { - if (yych == ' ') goto yy1207; - goto yy4; - } - } else { - if (yych <= 'Z') { - if (yych <= ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy145; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy1240: - YYDEBUG(1240, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= ')') { - if (yych <= '(') goto yy167; - goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'T') goto yy143; - } - } else { - if (yych <= 't') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy167; - goto yy143; - } else { - if (yych <= 'u') goto yy1241; - if (yych <= 'z') goto yy143; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'U': + case 'u': goto yy1241; + default: goto yy167; } yy1241: - YYDEBUG(1241, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy144; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'r') goto yy1242; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'R': + case 'r': goto yy1242; + default: goto yy4; } yy1242: - YYDEBUG(1242, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy145; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'd') goto yy1243; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'D': + case 'd': goto yy1243; + default: goto yy4; } yy1243: - YYDEBUG(1243, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'A') goto yy1244; - if (yych != 'a') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1244; + default: goto yy4; } yy1244: - YYDEBUG(1244, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy173; - if (yych == 'y') goto yy173; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy173; + default: goto yy57; + } yy1245: - YYDEBUG(1245, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'N') goto yy143; - goto yy1256; - } - } else { - if (yych <= 'n') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'o') goto yy1256; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'O': + case 'o': goto yy1256; + default: goto yy4; } yy1246: - YYDEBUG(1246, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy143; - goto yy1253; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'e') goto yy1253; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'E': + case 'e': goto yy1253; + default: goto yy4; } yy1247: - YYDEBUG(1247, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'T') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 't') goto yy1248; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1248; + default: goto yy194; } yy1248: - YYDEBUG(1248, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'E') goto yy144; - } - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy194; - goto yy144; - } else { - if (yych <= 'e') goto yy1249; - if (yych <= 'z') goto yy144; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'E': + case 'e': goto yy1249; + default: goto yy194; } yy1249: - YYDEBUG(1249, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'M') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'L') goto yy145; - } - } else { - if (yych <= 'l') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'm') goto yy1250; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'M': + case 'm': goto yy1250; + default: goto yy4; } yy1250: - YYDEBUG(1250, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'A') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'B') goto yy1251; - if (yych != 'b') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'B': + case 'b': goto yy1251; + default: goto yy4; } yy1251: - YYDEBUG(1251, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1252; - if (yych != 'e') goto yy57; + switch (yych) { + case 'E': + case 'e': goto yy1252; + default: goto yy57; + } yy1252: - YYDEBUG(1252, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy206; - if (yych == 'r') goto yy206; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy206; + default: goto yy57; + } yy1253: - YYDEBUG(1253, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy144; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'n') goto yy1254; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'N': + case 'n': goto yy1254; + default: goto yy4; } yy1254: - YYDEBUG(1254, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy145; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 't') goto yy1255; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'T': + case 't': goto yy1255; + default: goto yy4; } yy1255: - YYDEBUG(1255, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'H') goto yy1206; - if (yych == 'h') goto yy1206; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'H': + case 'h': goto yy1206; + default: goto yy4; } yy1256: - YYDEBUG(1256, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy144; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'n') goto yy1257; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'N': + case 'n': goto yy1257; + default: goto yy4; } yy1257: - YYDEBUG(1257, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy145; - goto yy1216; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'd') goto yy1216; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'D': + case 'd': goto yy1216; + default: goto yy4; } yy1258: - YYDEBUG(1258, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'U') { - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - goto yy148; - } - } else { - if (yych <= 'C') { - if (yych <= '@') goto yy4; - if (yych <= 'B') goto yy142; - goto yy1245; - } else { - if (yych == 'P') goto yy1247; - goto yy142; - } - } - } else { - if (yych <= 'b') { - if (yych <= '^') { - if (yych <= 'V') goto yy1246; - if (yych <= 'Z') goto yy142; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - goto yy147; - } - } else { - if (yych <= 'p') { - if (yych <= 'c') goto yy1274; - if (yych <= 'o') goto yy147; - goto yy1276; - } else { - if (yych == 'v') goto yy1275; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'C': goto yy1245; + case 'P': goto yy1247; + case 'V': goto yy1246; + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'c': goto yy1274; + case 'p': goto yy1276; + case 'v': goto yy1275; + default: goto yy4; } yy1259: - YYDEBUG(1259, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1240; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 't') goto yy1269; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'T': goto yy1240; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 't': goto yy1269; + default: goto yy4; } yy1260: - YYDEBUG(1260, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'W') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'X') goto yy1237; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'w') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'x') goto yy1266; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'Y': + case 'Z': goto yy142; + case 'X': goto yy1237; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'y': + case 'z': goto yy147; + case 'x': goto yy1266; + default: goto yy4; } yy1261: - YYDEBUG(1261, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1233; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'n') goto yy1262; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'N': goto yy1233; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'n': goto yy1262; + default: goto yy4; } yy1262: - YYDEBUG(1262, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1234; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 'd') goto yy1263; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'D': goto yy1234; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'd': goto yy1263; + default: goto yy167; } yy1263: - YYDEBUG(1263, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1235; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1264; - if (yych <= 'z') goto yy152; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1235; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': goto yy1264; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy1264: - YYDEBUG(1264, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'Y') goto yy1236; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'x') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'y') goto yy1265; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': goto yy145; + case 'Y': goto yy1236; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy153; + case 'y': goto yy1265; + default: goto yy4; } yy1265: - YYDEBUG(1265, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych <= '/') { - if (yych <= '.') goto yy167; - goto yy148; - } else { - if (yych == '_') goto yy148; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy167; } yy1266: - YYDEBUG(1266, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1238; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1267; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1238; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1267; + default: goto yy4; } yy1267: - YYDEBUG(1267, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy1239; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'h') goto yy1268; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'H': goto yy1239; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'h': goto yy1268; + default: goto yy4; } yy1268: - YYDEBUG(1268, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= ' ') { - if (yych == '\t') goto yy1207; - if (yych <= 0x1F) goto yy4; - goto yy1207; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } - } else { - if (yych <= 'Z') { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': goto yy1207; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy1269: - YYDEBUG(1269, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'U') goto yy1241; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 't') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 'u') goto yy1270; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'U': goto yy1241; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'u': goto yy1270; + default: goto yy167; } yy1270: - YYDEBUG(1270, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy1242; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'r') goto yy1271; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'R': goto yy1242; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'r': goto yy1271; + default: goto yy4; } yy1271: - YYDEBUG(1271, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1243; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'd') goto yy1272; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'D': goto yy1243; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'd': goto yy1272; + default: goto yy4; } yy1272: - YYDEBUG(1272, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1244; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1273; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1244; + case 'a': goto yy1273; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy4; } yy1273: - YYDEBUG(1273, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy173; - if (yych == 'y') goto yy186; - goto yy155; + switch (yych) { + case 'Y': goto yy173; + case 'y': goto yy186; + default: goto yy155; + } yy1274: - YYDEBUG(1274, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'O') goto yy1256; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'n') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'o') goto yy1285; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'O': goto yy1256; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'o': goto yy1285; + default: goto yy4; } yy1275: - YYDEBUG(1275, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1253; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'e') goto yy1282; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'E': goto yy1253; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'e': goto yy1282; + default: goto yy4; } yy1276: - YYDEBUG(1276, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'S') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'T') goto yy1248; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 's') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 't') goto yy1277; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1248; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1277; + default: goto yy194; } yy1277: - YYDEBUG(1277, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'D') { - if (yych <= '@') goto yy194; - goto yy144; - } else { - if (yych <= 'E') goto yy1249; - if (yych <= 'Z') goto yy144; - goto yy194; - } - } else { - if (yych <= 'd') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy152; - } else { - if (yych <= 'e') goto yy1278; - if (yych <= 'z') goto yy152; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'E': goto yy1249; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'e': goto yy1278; + default: goto yy194; } yy1278: - YYDEBUG(1278, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'M') goto yy1250; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'l') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'm') goto yy1279; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'M': goto yy1250; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'm': goto yy1279; + default: goto yy4; } yy1279: - YYDEBUG(1279, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'A') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'B') goto yy1251; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'b') goto yy1280; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'B': goto yy1251; + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'b': goto yy1280; + default: goto yy4; } yy1280: - YYDEBUG(1280, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy1252; - if (yych != 'e') goto yy155; - YYDEBUG(1281, *YYCURSOR); + switch (yych) { + case 'E': goto yy1252; + case 'e': goto yy1281; + default: goto yy155; + } +yy1281: yych = *++YYCURSOR; - if (yych == 'R') goto yy206; - if (yych == 'r') goto yy377; - goto yy155; + switch (yych) { + case 'R': goto yy206; + case 'r': goto yy377; + default: goto yy155; + } yy1282: - YYDEBUG(1282, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1254; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'n') goto yy1283; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'N': goto yy1254; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'n': goto yy1283; + default: goto yy4; } yy1283: - YYDEBUG(1283, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1255; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 't') goto yy1284; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'T': goto yy1255; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 't': goto yy1284; + default: goto yy4; } yy1284: - YYDEBUG(1284, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'H') goto yy1206; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'h') goto yy1224; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'H': goto yy1206; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'h': goto yy1224; + default: goto yy4; } yy1285: - YYDEBUG(1285, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1257; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'n') goto yy1286; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'N': goto yy1257; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'n': goto yy1286; + default: goto yy4; } yy1286: - YYDEBUG(1286, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1216; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'd') goto yy1228; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'D': goto yy1216; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'd': goto yy1228; + default: goto yy4; } yy1287: - YYDEBUG(1287, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'C') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'B') goto yy142; - } - } else { - if (yych <= 'b') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'c') goto yy1288; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'C': + case 'c': goto yy1288; + default: goto yy4; } yy1288: - YYDEBUG(1288, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'K') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'J') goto yy143; - } - } else { - if (yych <= 'j') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'k') goto yy1289; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'K': + case 'k': goto yy1289; + default: goto yy4; } yy1289: - YYDEBUG(1289, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ')') { - if (yych == ' ') goto yy1290; - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= 'Z') { - if (yych <= '@') goto yy4; - goto yy144; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ' ': goto yy1290; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy1290: - YYDEBUG(1290, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy1291; - if (yych != 'o') goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy1291; + default: goto yy57; + } yy1291: - YYDEBUG(1291, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy1292; - if (yych != 'f') goto yy57; + switch (yych) { + case 'F': + case 'f': goto yy1292; + default: goto yy57; + } yy1292: - YYDEBUG(1292, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ' ') goto yy57; - YYDEBUG(1293, *YYCURSOR); + switch (yych) { + case ' ': goto yy1293; + default: goto yy57; + } +yy1293: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy1294; - if (yych <= '2') goto yy1296; - if (yych <= '9') goto yy1297; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy1294; + case '2': goto yy1296; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1297; + default: goto yy57; + } yy1294: - YYDEBUG(1294, *YYCURSOR); yyaccept = 28; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') goto yy1298; - if (yych <= '9') goto yy1297; - goto yy1298; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1297; + default: goto yy1298; + } yy1295: - YYDEBUG(1295, *YYCURSOR); #line 1091 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("backof | frontof"); @@ -19651,1697 +28643,3469 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_LF_DAY_OF_MONTH; } -#line 19655 "ext/date/lib/parse_date.c" +#line 28647 "" yy1296: - YYDEBUG(1296, *YYCURSOR); yyaccept = 28; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') goto yy1298; - if (yych >= '5') goto yy1298; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy1297; + default: goto yy1298; + } yy1297: - YYDEBUG(1297, *YYCURSOR); yyaccept = 28; YYMARKER = ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; yy1298: - YYDEBUG(1298, *YYCURSOR); - if (yych <= 'A') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy1297; - goto yy1295; - } else { - if (yych <= ' ') goto yy1297; - if (yych <= '@') goto yy1295; - } - } else { - if (yych <= '`') { - if (yych != 'P') goto yy1295; - } else { - if (yych <= 'a') goto yy1299; - if (yych != 'p') goto yy1295; - } + switch (yych) { + case '\t': + case ' ': goto yy1297; + case 'A': + case 'P': + case 'a': + case 'p': goto yy1299; + default: goto yy1295; } yy1299: - YYDEBUG(1299, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych != '.') goto yy57; - } else { - if (yych <= 'M') goto yy1301; - if (yych == 'm') goto yy1301; - goto yy57; + switch (yych) { + case '.': goto yy1300; + case 'M': + case 'm': goto yy1301; + default: goto yy57; } - YYDEBUG(1300, *YYCURSOR); +yy1300: yych = *++YYCURSOR; - if (yych == 'M') goto yy1301; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy1301; + default: goto yy57; + } yy1301: - YYDEBUG(1301, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy1303; - if (yych == '\t') goto yy1303; - goto yy57; - } else { - if (yych <= ' ') goto yy1303; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy1303; + case '.': goto yy1302; + default: goto yy57; } - YYDEBUG(1302, *YYCURSOR); +yy1302: yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy1303; - if (yych <= 0x08) goto yy57; - } else { - if (yych != ' ') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy1303; + default: goto yy57; } yy1303: - YYDEBUG(1303, *YYCURSOR); yych = *++YYCURSOR; goto yy1295; yy1304: - YYDEBUG(1304, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'B') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'C') goto yy1288; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'b') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'c') goto yy1305; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'C': goto yy1288; + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'c': goto yy1305; + default: goto yy4; } yy1305: - YYDEBUG(1305, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'J') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'K') goto yy1289; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'j') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'k') goto yy1306; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'K': goto yy1289; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'k': goto yy1306; + default: goto yy4; } yy1306: - YYDEBUG(1306, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= '(') { - if (yych == ' ') goto yy1290; - goto yy4; - } else { - if (yych <= ')') goto yy140; - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '^') { - if (yych <= '/') goto yy148; - if (yych <= '@') goto yy4; - if (yych <= 'Z') goto yy144; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy152; - goto yy4; - } + switch (yych) { + case ' ': goto yy1290; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy1307: - YYDEBUG(1307, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'R') goto yy142; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 's') goto yy1308; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'S': + case 's': goto yy1308; + default: goto yy4; } yy1308: - YYDEBUG(1308, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1309; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1309; + default: goto yy4; } yy1309: - YYDEBUG(1309, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy4; - goto yy1105; - } else { - if (yych != ' ') goto yy4; - } - } else { - if (yych <= 'Z') { - if (yych <= ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy144; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case '\t': goto yy1105; + case ' ': goto yy1310; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy1310: - YYDEBUG(1310, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1311; - if (yych != 'd') goto yy1106; + switch (yych) { + case 'D': + case 'd': goto yy1311; + default: goto yy1106; + } yy1311: - YYDEBUG(1311, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1312; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1312; + default: goto yy57; + } yy1312: - YYDEBUG(1312, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1313; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1313; + default: goto yy57; + } yy1313: - YYDEBUG(1313, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych != ' ') goto yy1118; - } else { - if (yych <= 'S') goto yy1143; - if (yych == 's') goto yy1143; - goto yy1118; + switch (yych) { + case ' ': goto yy1314; + case 'S': + case 's': goto yy1143; + default: goto yy1118; } - YYDEBUG(1314, *YYCURSOR); +yy1314: yych = *++YYCURSOR; - if (yych == 'O') goto yy1315; - if (yych != 'o') goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy1315; + default: goto yy57; + } yy1315: - YYDEBUG(1315, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy1316; - if (yych != 'f') goto yy57; + switch (yych) { + case 'F': + case 'f': goto yy1316; + default: goto yy57; + } yy1316: - YYDEBUG(1316, *YYCURSOR); yych = *++YYCURSOR; goto yy2; yy1317: - YYDEBUG(1317, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy1308; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 's') goto yy1318; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'S': goto yy1308; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 's': goto yy1318; + default: goto yy4; } yy1318: - YYDEBUG(1318, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1309; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1319; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1309; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1319; + default: goto yy4; } yy1319: - YYDEBUG(1319, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= ' ') { - if (yych == '\t') goto yy1105; - if (yych <= 0x1F) goto yy4; - goto yy1310; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } - } else { - if (yych <= 'Z') { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case '\t': goto yy1105; + case ' ': goto yy1310; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy1320: - YYDEBUG(1320, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'B') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'A') goto yy142; - goto yy1356; - } - } else { - if (yych <= 'a') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'b') goto yy1356; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'B': + case 'b': goto yy1356; + default: goto yy4; } yy1321: - YYDEBUG(1321, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'F') goto yy1346; - if (yych <= 'Q') goto yy142; - goto yy1345; - } - } else { - if (yych <= 'f') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'e') goto yy142; - goto yy1346; - } else { - if (yych == 'r') goto yy1345; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'F': + case 'f': goto yy1346; + case 'R': + case 'r': goto yy1345; + default: goto yy4; } yy1322: - YYDEBUG(1322, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'T') goto yy142; - goto yy1342; - } - } else { - if (yych <= 't') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'u') goto yy1342; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'U': + case 'u': goto yy1342; + default: goto yy4; } yy1323: - YYDEBUG(1323, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'I') goto yy1325; - if (yych <= 'N') goto yy142; - } - } else { - if (yych <= 'i') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'h') goto yy142; - goto yy1325; - } else { - if (yych == 'o') goto yy1324; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'I': + case 'i': goto yy1325; + case 'O': + case 'o': goto yy1324; + default: goto yy4; } yy1324: - YYDEBUG(1324, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy143; - goto yy1328; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'n') goto yy1328; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'N': + case 'n': goto yy1328; + default: goto yy4; } yy1325: - YYDEBUG(1325, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy167; - goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'C') goto yy143; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy167; - goto yy143; - } else { - if (yych <= 'd') goto yy1326; - if (yych <= 'z') goto yy143; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'D': + case 'd': goto yy1326; + default: goto yy167; } yy1326: - YYDEBUG(1326, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy144; - goto yy4; - } else { - if (yych <= 'a') goto yy1327; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1327; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy1327: - YYDEBUG(1327, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'X') goto yy145; - goto yy1236; - } - } else { - if (yych <= 'x') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'y') goto yy1236; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy145; + case 'Y': + case 'y': goto yy1236; + default: goto yy4; } yy1328: - YYDEBUG(1328, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy144; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 't') goto yy1329; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'T': + case 't': goto yy1329; + default: goto yy4; } yy1329: - YYDEBUG(1329, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ')') { - if (yych == ' ') goto yy1330; - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= 'Z') { - if (yych <= '@') goto yy4; - goto yy145; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ' ': goto yy1330; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy1330: - YYDEBUG(1330, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy1331; - if (yych != 'o') goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy1331; + default: goto yy57; + } yy1331: - YYDEBUG(1331, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy1332; - if (yych != 'f') goto yy57; + switch (yych) { + case 'F': + case 'f': goto yy1332; + default: goto yy57; + } yy1332: - YYDEBUG(1332, *YYCURSOR); yych = *++YYCURSOR; - if (yych != ' ') goto yy57; - YYDEBUG(1333, *YYCURSOR); + switch (yych) { + case ' ': goto yy1333; + default: goto yy57; + } +yy1333: yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '1') goto yy1334; - if (yych <= '2') goto yy1335; - if (yych <= '9') goto yy1336; - goto yy57; + switch (yych) { + case '0': + case '1': goto yy1334; + case '2': goto yy1335; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1336; + default: goto yy57; + } yy1334: - YYDEBUG(1334, *YYCURSOR); yyaccept = 28; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') goto yy1337; - if (yych <= '9') goto yy1336; - goto yy1337; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1336; + default: goto yy1337; + } yy1335: - YYDEBUG(1335, *YYCURSOR); yyaccept = 28; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') goto yy1337; - if (yych >= '5') goto yy1337; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': goto yy1336; + default: goto yy1337; + } yy1336: - YYDEBUG(1336, *YYCURSOR); yyaccept = 28; YYMARKER = ++YYCURSOR; if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; yy1337: - YYDEBUG(1337, *YYCURSOR); - if (yych <= 'A') { - if (yych <= 0x1F) { - if (yych == '\t') goto yy1336; - goto yy1295; - } else { - if (yych <= ' ') goto yy1336; - if (yych <= '@') goto yy1295; - } - } else { - if (yych <= '`') { - if (yych != 'P') goto yy1295; - } else { - if (yych <= 'a') goto yy1338; - if (yych != 'p') goto yy1295; - } + switch (yych) { + case '\t': + case ' ': goto yy1336; + case 'A': + case 'P': + case 'a': + case 'p': goto yy1338; + default: goto yy1295; } yy1338: - YYDEBUG(1338, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych != '.') goto yy57; - } else { - if (yych <= 'M') goto yy1340; - if (yych == 'm') goto yy1340; - goto yy57; + switch (yych) { + case '.': goto yy1339; + case 'M': + case 'm': goto yy1340; + default: goto yy57; } - YYDEBUG(1339, *YYCURSOR); +yy1339: yych = *++YYCURSOR; - if (yych == 'M') goto yy1340; - if (yych != 'm') goto yy57; + switch (yych) { + case 'M': + case 'm': goto yy1340; + default: goto yy57; + } yy1340: - YYDEBUG(1340, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 0x1F) { - if (yych <= 0x00) goto yy1303; - if (yych == '\t') goto yy1303; - goto yy57; - } else { - if (yych <= ' ') goto yy1303; - if (yych != '.') goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy1303; + case '.': goto yy1341; + default: goto yy57; } - YYDEBUG(1341, *YYCURSOR); +yy1341: yych = *++YYCURSOR; - if (yych <= '\t') { - if (yych <= 0x00) goto yy1303; - if (yych <= 0x08) goto yy57; - goto yy1303; - } else { - if (yych == ' ') goto yy1303; - goto yy57; + switch (yych) { + case 0x00: + case '\t': + case ' ': goto yy1303; + default: goto yy57; } yy1342: - YYDEBUG(1342, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy143; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'r') goto yy1343; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'R': + case 'r': goto yy1343; + default: goto yy4; } yy1343: - YYDEBUG(1343, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy144; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 't') goto yy1344; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'T': + case 't': goto yy1344; + default: goto yy4; } yy1344: - YYDEBUG(1344, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy145; - goto yy1216; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'h') goto yy1216; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'H': + case 'h': goto yy1216; + default: goto yy4; } yy1345: - YYDEBUG(1345, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'R') goto yy143; - goto yy1348; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 's') goto yy1348; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'S': + case 's': goto yy1348; + default: goto yy4; } yy1346: - YYDEBUG(1346, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1347; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1347; + default: goto yy4; } yy1347: - YYDEBUG(1347, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy144; - goto yy1239; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'h') goto yy1239; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'H': + case 'h': goto yy1239; + default: goto yy4; } yy1348: - YYDEBUG(1348, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy144; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 't') goto yy1349; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'T': + case 't': goto yy1349; + default: goto yy4; } yy1349: - YYDEBUG(1349, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy4; - goto yy1207; - } else { - if (yych != ' ') goto yy4; - } - } else { - if (yych <= 'Z') { - if (yych <= ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy145; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case '\t': goto yy1207; + case ' ': goto yy1350; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy1350: - YYDEBUG(1350, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy1351; - if (yych != 'd') goto yy1208; + switch (yych) { + case 'D': + case 'd': goto yy1351; + default: goto yy1208; + } yy1351: - YYDEBUG(1351, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1352; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1352; + default: goto yy57; + } yy1352: - YYDEBUG(1352, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1353; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1353; + default: goto yy57; + } yy1353: - YYDEBUG(1353, *YYCURSOR); yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych != ' ') goto yy1118; - } else { - if (yych <= 'S') goto yy1143; - if (yych == 's') goto yy1143; - goto yy1118; + switch (yych) { + case ' ': goto yy1354; + case 'S': + case 's': goto yy1143; + default: goto yy1118; } - YYDEBUG(1354, *YYCURSOR); +yy1354: yych = *++YYCURSOR; - if (yych == 'O') goto yy1355; - if (yych != 'o') goto yy57; + switch (yych) { + case 'O': + case 'o': goto yy1355; + default: goto yy57; + } yy1355: - YYDEBUG(1355, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy1316; - if (yych == 'f') goto yy1316; - goto yy57; + switch (yych) { + case 'F': + case 'f': goto yy1316; + default: goto yy57; + } yy1356: - YYDEBUG(1356, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'R') goto yy143; - } - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'r') goto yy1357; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'R': + case 'r': goto yy1357; + default: goto yy194; } yy1357: - YYDEBUG(1357, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'T') goto yy144; - } - } else { - if (yych <= 't') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'u') goto yy1358; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'U': + case 'u': goto yy1358; + default: goto yy4; } yy1358: - YYDEBUG(1358, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy145; - goto yy4; - } else { - if (yych <= 'a') goto yy1359; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1359; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy1359: - YYDEBUG(1359, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'R') goto yy1360; - if (yych != 'r') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'R': + case 'r': goto yy1360; + default: goto yy4; } yy1360: - YYDEBUG(1360, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy206; - if (yych == 'y') goto yy206; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy206; + default: goto yy57; + } yy1361: - YYDEBUG(1361, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'A') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'B') goto yy1356; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'b') goto yy1379; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'B': goto yy1356; + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'b': goto yy1379; + default: goto yy4; } yy1362: - YYDEBUG(1362, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych <= '/') goto yy148; - goto yy4; - } else { - if (yych == 'F') goto yy1346; - goto yy142; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'R') goto yy1345; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'q') { - if (yych == 'f') goto yy1375; - goto yy147; - } else { - if (yych <= 'r') goto yy1374; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'F': goto yy1346; + case 'R': goto yy1345; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'f': goto yy1375; + case 'r': goto yy1374; + default: goto yy4; } yy1363: - YYDEBUG(1363, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'U') goto yy1342; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 't') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'u') goto yy1371; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'U': goto yy1342; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'u': goto yy1371; + default: goto yy4; } yy1364: - YYDEBUG(1364, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych <= '/') goto yy148; - goto yy4; - } else { - if (yych == 'I') goto yy1325; - goto yy142; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'O') goto yy1324; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'n') { - if (yych == 'i') goto yy1366; - goto yy147; - } else { - if (yych <= 'o') goto yy1365; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'I': goto yy1325; + case 'O': goto yy1324; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'i': goto yy1366; + case 'o': goto yy1365; + default: goto yy4; } yy1365: - YYDEBUG(1365, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1328; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'n') goto yy1369; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'N': goto yy1328; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'n': goto yy1369; + default: goto yy4; } yy1366: - YYDEBUG(1366, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1326; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 'd') goto yy1367; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'D': goto yy1326; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'd': goto yy1367; + default: goto yy167; } yy1367: - YYDEBUG(1367, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1327; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1368; - if (yych <= 'z') goto yy152; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1327; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': goto yy1368; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy1368: - YYDEBUG(1368, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'Y') goto yy1236; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'x') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'y') goto yy1265; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': goto yy145; + case 'Y': goto yy1236; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy153; + case 'y': goto yy1265; + default: goto yy4; } yy1369: - YYDEBUG(1369, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1329; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 't') goto yy1370; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'T': goto yy1329; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 't': goto yy1370; + default: goto yy4; } yy1370: - YYDEBUG(1370, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= '(') { - if (yych == ' ') goto yy1330; - goto yy4; - } else { - if (yych <= ')') goto yy140; - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '^') { - if (yych <= '/') goto yy148; - if (yych <= '@') goto yy4; - if (yych <= 'Z') goto yy145; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy153; - goto yy4; - } + switch (yych) { + case ' ': goto yy1330; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy1371: - YYDEBUG(1371, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy1343; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'r') goto yy1372; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'R': goto yy1343; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'r': goto yy1372; + default: goto yy4; } yy1372: - YYDEBUG(1372, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1344; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 't') goto yy1373; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'T': goto yy1344; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 't': goto yy1373; + default: goto yy4; } yy1373: - YYDEBUG(1373, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy1216; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'h') goto yy1228; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'H': goto yy1216; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'h': goto yy1228; + default: goto yy4; } yy1374: - YYDEBUG(1374, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy1348; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 's') goto yy1377; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'S': goto yy1348; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 's': goto yy1377; + default: goto yy4; } yy1375: - YYDEBUG(1375, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1347; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1376; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1347; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1376; + default: goto yy4; } yy1376: - YYDEBUG(1376, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy1239; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'h') goto yy1268; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'H': goto yy1239; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'h': goto yy1268; + default: goto yy4; } yy1377: - YYDEBUG(1377, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1349; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 't') goto yy1378; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'T': goto yy1349; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 't': goto yy1378; + default: goto yy4; } yy1378: - YYDEBUG(1378, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= ' ') { - if (yych == '\t') goto yy1207; - if (yych <= 0x1F) goto yy4; - goto yy1350; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } - } else { - if (yych <= 'Z') { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case '\t': goto yy1207; + case ' ': goto yy1350; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy1379: - YYDEBUG(1379, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'Q') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'R') goto yy1357; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'q') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'r') goto yy1380; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'R': goto yy1357; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'r': goto yy1380; + default: goto yy194; } yy1380: - YYDEBUG(1380, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'U') goto yy1358; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 't') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'u') goto yy1381; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'U': goto yy1358; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'u': goto yy1381; + default: goto yy4; } yy1381: - YYDEBUG(1381, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1359; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1382; - if (yych <= 'z') goto yy153; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1359; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': goto yy1382; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy1382: - YYDEBUG(1382, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'R') goto yy1360; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'r') goto yy1383; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'R': goto yy1360; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'r': goto yy1383; + default: goto yy4; + } +yy1383: + yych = *++YYCURSOR; + switch (yych) { + case 'Y': goto yy206; + case 'y': goto yy377; + default: goto yy155; + } +yy1384: + yych = *++YYCURSOR; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1385; + default: goto yy57; } -yy1383: - YYDEBUG(1383, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'Y') goto yy206; - if (yych == 'y') goto yy377; - goto yy155; -yy1384: - YYDEBUG(1384, *YYCURSOR); - yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; yy1385: - YYDEBUG(1385, *YYCURSOR); ++YYCURSOR; if (YYLIMIT <= YYCURSOR) YYFILL(1); yych = *YYCURSOR; - YYDEBUG(1386, *YYCURSOR); - if (yych <= '/') goto yy1387; - if (yych <= '9') goto yy1385; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1385; + default: goto yy1387; + } yy1387: - YYDEBUG(1387, *YYCURSOR); #line 1049 "ext/date/lib/parse_date.re" { timelib_ull i; @@ -21366,442 +32130,1014 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 21370 "ext/date/lib/parse_date.c" +#line 32134 "" yy1388: - YYDEBUG(1388, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy142; - goto yy1429; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'n') goto yy1429; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'N': + case 'n': goto yy1429; + default: goto yy4; } yy1389: - YYDEBUG(1389, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'U') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'I') goto yy1421; - if (yych <= 'T') goto yy142; - goto yy1422; - } - } else { - if (yych <= 'i') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'h') goto yy142; - goto yy1421; - } else { - if (yych == 'u') goto yy1422; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'I': + case 'i': goto yy1421; + case 'U': + case 'u': goto yy1422; + default: goto yy4; } yy1390: - YYDEBUG(1390, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'M') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'D') goto yy1410; - if (yych <= 'L') goto yy142; - goto yy1411; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'c') goto yy142; - goto yy1410; - } else { - if (yych == 'm') goto yy1411; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'D': + case 'd': goto yy1410; + case 'M': + case 'm': goto yy1411; + default: goto yy4; } yy1391: - YYDEBUG(1391, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy142; - goto yy1406; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'e') goto yy1406; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'E': + case 'e': goto yy1406; + default: goto yy4; } yy1392: - YYDEBUG(1392, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy142; - goto yy1402; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'e') goto yy1402; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'E': + case 'e': goto yy1402; + default: goto yy4; } yy1393: - YYDEBUG(1393, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy1065; - goto yy57; - } else { - if (yych <= '9') goto yy1396; - if (yych <= ':') goto yy1065; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy1065; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1396; + default: goto yy57; } yy1394: - YYDEBUG(1394, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy1065; - goto yy57; - } else { - if (yych <= '4') goto yy1396; - if (yych == ':') goto yy1065; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy1065; + case '0': + case '1': + case '2': + case '3': + case '4': goto yy1396; + default: goto yy57; } yy1395: - YYDEBUG(1395, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '.') goto yy1065; - if (yych == ':') goto yy1065; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy1065; + default: goto yy57; + } yy1396: - YYDEBUG(1396, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') { - if (yych == '.') goto yy1065; - goto yy57; - } else { - if (yych <= '5') goto yy1397; - if (yych == ':') goto yy1065; - goto yy57; + switch (yych) { + case '.': + case ':': goto yy1065; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1397; + default: goto yy57; } yy1397: - YYDEBUG(1397, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych >= ':') goto yy57; - YYDEBUG(1398, *YYCURSOR); + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1398; + default: goto yy57; + } +yy1398: yyaccept = 24; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') goto yy1068; - if (yych <= '5') goto yy1399; - if (yych <= '6') goto yy1400; - goto yy1068; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': goto yy1399; + case '6': goto yy1400; + default: goto yy1068; + } yy1399: - YYDEBUG(1399, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= '/') goto yy57; - if (yych <= '9') goto yy1401; - goto yy57; + switch (yych) { + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1401; + default: goto yy57; + } yy1400: - YYDEBUG(1400, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '0') goto yy57; + switch (yych) { + case '0': goto yy1401; + default: goto yy57; + } yy1401: - YYDEBUG(1401, *YYCURSOR); yych = *++YYCURSOR; goto yy1076; yy1402: - YYDEBUG(1402, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'L') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'K') goto yy143; - } - } else { - if (yych <= 'k') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'l') goto yy1403; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'L': + case 'l': goto yy1403; + default: goto yy4; } yy1403: - YYDEBUG(1403, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'F') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'E') goto yy144; - } - } else { - if (yych <= 'e') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'f') goto yy1404; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'F': + case 'f': goto yy1404; + default: goto yy4; } yy1404: - YYDEBUG(1404, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy145; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 't') goto yy1405; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'T': + case 't': goto yy1405; + default: goto yy4; } yy1405: - YYDEBUG(1405, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'H') goto yy1206; - if (yych == 'h') goto yy1206; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'H': + case 'h': goto yy1206; + default: goto yy4; } yy1406: - YYDEBUG(1406, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy167; - goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'R') goto yy143; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy167; - goto yy143; - } else { - if (yych <= 's') goto yy1407; - if (yych <= 'z') goto yy143; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'S': + case 's': goto yy1407; + default: goto yy167; } yy1407: - YYDEBUG(1407, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy144; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'd') goto yy1408; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'D': + case 'd': goto yy1408; + default: goto yy4; } yy1408: - YYDEBUG(1408, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy145; - goto yy4; - } else { - if (yych <= 'a') goto yy1409; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1409; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy4; } yy1409: - YYDEBUG(1409, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'X') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Y') goto yy173; - if (yych == 'y') goto yy173; - goto yy4; + switch (yych) { + case ')': goto yy140; + case 'Y': + case 'y': goto yy173; + default: goto yy4; } yy1410: - YYDEBUG(1410, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy1418; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy143; - goto yy4; - } else { - if (yych <= 'a') goto yy1418; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1418; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy4; } yy1411: - YYDEBUG(1411, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'O') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'N') goto yy143; - } - } else { - if (yych <= 'n') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'o') goto yy1412; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'O': + case 'o': goto yy1412; + default: goto yy4; } yy1412: - YYDEBUG(1412, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy144; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'r') goto yy1413; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'R': + case 'r': goto yy1413; + default: goto yy4; } yy1413: - YYDEBUG(1413, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy145; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'r') goto yy1414; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'R': + case 'r': goto yy1414; + default: goto yy4; } yy1414: - YYDEBUG(1414, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'O') goto yy1415; - if (yych != 'o') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'O': + case 'o': goto yy1415; + default: goto yy4; } yy1415: - YYDEBUG(1415, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy1416; - if (yych != 'w') goto yy57; + switch (yych) { + case 'W': + case 'w': goto yy1416; + default: goto yy57; + } yy1416: - YYDEBUG(1416, *YYCURSOR); ++YYCURSOR; yy1417: - YYDEBUG(1417, *YYCURSOR); #line 1037 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("tomorrow"); @@ -21813,41 +33149,124 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 21817 "ext/date/lib/parse_date.c" +#line 33153 "" yy1418: - YYDEBUG(1418, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'X') goto yy144; - } - } else { - if (yych <= 'x') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'y') goto yy1419; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy144; + case 'Y': + case 'y': goto yy1419; + default: goto yy4; } yy1419: - YYDEBUG(1419, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= '@') { - if (yych == ')') goto yy140; - } else { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy1420; - if (yych <= 'z') goto yy145; + switch ((yych = *YYCURSOR)) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + default: goto yy1420; } yy1420: - YYDEBUG(1420, *YYCURSOR); #line 1027 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("midnight | today"); @@ -21857,2018 +33276,4240 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 21861 "ext/date/lib/parse_date.c" +#line 33280 "" yy1421: - YYDEBUG(1421, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'Q') goto yy143; - if (yych <= 'R') goto yy1427; - goto yy1428; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'r') goto yy1427; - if (yych <= 's') goto yy1428; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'R': + case 'r': goto yy1427; + case 'S': + case 's': goto yy1428; + default: goto yy4; } yy1422: - YYDEBUG(1422, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy167; - goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'Q') goto yy143; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy167; - goto yy143; - } else { - if (yych <= 'r') goto yy1423; - if (yych <= 'z') goto yy143; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'R': + case 'r': goto yy1423; + default: goto yy167; } yy1423: - YYDEBUG(1423, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'R') goto yy144; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 's') goto yy1424; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'S': + case 's': goto yy1424; + default: goto yy4; } yy1424: - YYDEBUG(1424, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy145; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'd') goto yy1425; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'D': + case 'd': goto yy1425; + default: goto yy4; } yy1425: - YYDEBUG(1425, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'A') goto yy1426; - if (yych != 'a') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1426; + default: goto yy4; } yy1426: - YYDEBUG(1426, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy173; - if (yych == 'y') goto yy173; - goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy173; + default: goto yy57; + } yy1427: - YYDEBUG(1427, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy144; - goto yy1239; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'd') goto yy1239; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'D': + case 'd': goto yy1239; + default: goto yy4; } yy1428: - YYDEBUG(1428, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy4; - goto yy1105; - } else { - if (yych == ' ') goto yy1105; - goto yy4; - } - } else { - if (yych <= 'Z') { - if (yych <= ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy144; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case '\t': + case ' ': goto yy1105; + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy1429: - YYDEBUG(1429, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1430; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1430; + default: goto yy4; } yy1430: - YYDEBUG(1430, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy144; - goto yy1239; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'h') goto yy1239; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'H': + case 'h': goto yy1239; + default: goto yy4; } yy1431: - YYDEBUG(1431, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1429; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'n') goto yy1461; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'N': goto yy1429; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'n': goto yy1461; + default: goto yy4; } yy1432: - YYDEBUG(1432, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'T') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych <= '/') goto yy148; - goto yy4; - } else { - if (yych == 'I') goto yy1421; - goto yy142; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'U') goto yy1422; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 't') { - if (yych == 'i') goto yy1453; - goto yy147; - } else { - if (yych <= 'u') goto yy1454; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'I': goto yy1421; + case 'U': goto yy1422; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'i': goto yy1453; + case 'u': goto yy1454; + default: goto yy4; } yy1433: - YYDEBUG(1433, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych <= '/') goto yy148; - goto yy4; - } else { - if (yych == 'D') goto yy1410; - goto yy142; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'M') goto yy1411; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'l') { - if (yych == 'd') goto yy1444; - goto yy147; - } else { - if (yych <= 'm') goto yy1445; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'D': goto yy1410; + case 'M': goto yy1411; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'd': goto yy1444; + case 'm': goto yy1445; + default: goto yy4; } yy1434: - YYDEBUG(1434, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1406; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'e') goto yy1440; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'E': goto yy1406; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'e': goto yy1440; + default: goto yy4; } yy1435: - YYDEBUG(1435, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1402; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'e') goto yy1436; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'E': goto yy1402; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'e': goto yy1436; + default: goto yy4; } yy1436: - YYDEBUG(1436, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'K') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'L') goto yy1403; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'k') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'l') goto yy1437; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'L': goto yy1403; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'l': goto yy1437; + default: goto yy4; } yy1437: - YYDEBUG(1437, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'E') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'F') goto yy1404; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'e') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'f') goto yy1438; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'F': goto yy1404; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'f': goto yy1438; + default: goto yy4; } yy1438: - YYDEBUG(1438, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1405; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 't') goto yy1439; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'T': goto yy1405; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 't': goto yy1439; + default: goto yy4; } yy1439: - YYDEBUG(1439, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'H') goto yy1206; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'h') goto yy1224; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'H': goto yy1206; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'h': goto yy1224; + default: goto yy4; } yy1440: - YYDEBUG(1440, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy1407; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 's') goto yy1441; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'S': goto yy1407; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 's': goto yy1441; + default: goto yy167; } yy1441: - YYDEBUG(1441, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1408; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'd') goto yy1442; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'D': goto yy1408; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'd': goto yy1442; + default: goto yy4; } yy1442: - YYDEBUG(1442, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1409; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1443; - if (yych <= 'z') goto yy153; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1409; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': goto yy1443; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy4; } yy1443: - YYDEBUG(1443, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'Y') goto yy173; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'y') goto yy186; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'Y': goto yy173; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy154; + case 'y': goto yy186; + default: goto yy4; } yy1444: - YYDEBUG(1444, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1418; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1451; - if (yych <= 'z') goto yy151; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1418; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'a': goto yy1451; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + default: goto yy4; } yy1445: - YYDEBUG(1445, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'O') goto yy1412; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'n') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'o') goto yy1446; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'O': goto yy1412; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'o': goto yy1446; + default: goto yy4; } yy1446: - YYDEBUG(1446, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy1413; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'r') goto yy1447; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'R': goto yy1413; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'r': goto yy1447; + default: goto yy4; } yy1447: - YYDEBUG(1447, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy1414; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'r') goto yy1448; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'R': goto yy1414; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'r': goto yy1448; + default: goto yy4; } yy1448: - YYDEBUG(1448, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'N') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'O') goto yy1415; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'o') goto yy1449; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'O': goto yy1415; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'o': goto yy1449; + default: goto yy4; } yy1449: - YYDEBUG(1449, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy1416; - if (yych != 'w') goto yy155; - YYDEBUG(1450, *YYCURSOR); + switch (yych) { + case 'W': goto yy1416; + case 'w': goto yy1450; + default: goto yy155; + } +yy1450: yyaccept = 29; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy1417; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy1417; + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy1417; } yy1451: - YYDEBUG(1451, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'Y') goto yy1419; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'x') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'y') goto yy1452; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': goto yy144; + case 'Y': goto yy1419; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy152; + case 'y': goto yy1452; + default: goto yy4; } yy1452: - YYDEBUG(1452, *YYCURSOR); yyaccept = 30; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy1420; - } else { - if (yych == '.') goto yy1420; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy1420; - if (yych <= 'Z') goto yy145; - goto yy1420; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy1420; - if (yych <= 'z') goto yy153; - goto yy1420; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + default: goto yy1420; } yy1453: - YYDEBUG(1453, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych <= '/') { - if (yych <= '.') goto yy4; - goto yy148; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy143; - goto yy1427; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'S') goto yy1428; - goto yy143; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'r') { - if (yych <= 'q') goto yy151; - goto yy1459; - } else { - if (yych <= 's') goto yy1460; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'R': goto yy1427; + case 'S': goto yy1428; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'r': goto yy1459; + case 's': goto yy1460; + default: goto yy4; } yy1454: - YYDEBUG(1454, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy1423; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 'r') goto yy1455; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'R': goto yy1423; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'r': goto yy1455; + default: goto yy167; } yy1455: - YYDEBUG(1455, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy1424; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 's') goto yy1456; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'S': goto yy1424; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 's': goto yy1456; + default: goto yy4; } yy1456: - YYDEBUG(1456, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1425; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'd') goto yy1457; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'D': goto yy1425; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'd': goto yy1457; + default: goto yy4; } yy1457: - YYDEBUG(1457, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1426; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1458; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1426; + case 'a': goto yy1458; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy4; } yy1458: - YYDEBUG(1458, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy173; - if (yych == 'y') goto yy186; - goto yy155; + switch (yych) { + case 'Y': goto yy173; + case 'y': goto yy186; + default: goto yy155; + } yy1459: - YYDEBUG(1459, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1239; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'd') goto yy1268; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'D': goto yy1239; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'd': goto yy1268; + default: goto yy4; } yy1460: - YYDEBUG(1460, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= ' ') { - if (yych == '\t') goto yy1105; - if (yych <= 0x1F) goto yy4; - goto yy1105; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } - } else { - if (yych <= 'Z') { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case '\t': + case ' ': goto yy1105; + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy1461: - YYDEBUG(1461, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1430; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1462; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1430; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1462; + default: goto yy4; } yy1462: - YYDEBUG(1462, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy1239; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'h') goto yy1268; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'H': goto yy1239; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'h': goto yy1268; + default: goto yy4; } yy1463: - YYDEBUG(1463, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych <= '@') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == 'R') goto yy1475; - if (yych <= 'X') goto yy142; - goto yy1476; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'q') goto yy142; - goto yy1475; - } else { - if (yych == 'y') goto yy1476; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy142; + case 'R': + case 'r': goto yy1475; + case 'Y': + case 'y': goto yy1476; + default: goto yy4; } yy1464: - YYDEBUG(1464, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'C') goto yy142; - goto yy1469; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'd') goto yy1469; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'D': + case 'd': goto yy1469; + default: goto yy4; } yy1465: - YYDEBUG(1465, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy142; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'n') goto yy1466; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'N': + case 'n': goto yy1466; + default: goto yy4; } yy1466: - YYDEBUG(1466, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'D') { - if (yych <= ')') { - if (yych <= '(') goto yy167; - goto yy140; - } else { - if (yych <= '@') goto yy167; - if (yych <= 'C') goto yy143; - } - } else { - if (yych <= 'c') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy167; - goto yy143; - } else { - if (yych <= 'd') goto yy1467; - if (yych <= 'z') goto yy143; - goto yy167; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'D': + case 'd': goto yy1467; + default: goto yy167; } yy1467: - YYDEBUG(1467, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'A') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - } else { - if (yych <= '`') { - if (yych <= 'Z') goto yy144; - goto yy4; - } else { - if (yych <= 'a') goto yy1468; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'a': goto yy1468; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy4; } yy1468: - YYDEBUG(1468, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'Y') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'X') goto yy145; - goto yy1236; - } - } else { - if (yych <= 'x') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'y') goto yy1236; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy145; + case 'Y': + case 'y': goto yy1236; + default: goto yy4; } yy1469: - YYDEBUG(1469, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy143; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'n') goto yy1470; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'N': + case 'n': goto yy1470; + default: goto yy4; } yy1470: - YYDEBUG(1470, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'I') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'H') goto yy144; - } - } else { - if (yych <= 'h') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'i') goto yy1471; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'I': + case 'i': goto yy1471; + default: goto yy4; } yy1471: - YYDEBUG(1471, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'G') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'F') goto yy145; - } - } else { - if (yych <= 'f') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'g') goto yy1472; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'G': + case 'g': goto yy1472; + default: goto yy4; } yy1472: - YYDEBUG(1472, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'H') goto yy1473; - if (yych != 'h') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'H': + case 'h': goto yy1473; + default: goto yy4; } yy1473: - YYDEBUG(1473, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1474; - if (yych != 't') goto yy57; + switch (yych) { + case 'T': + case 't': goto yy1474; + default: goto yy57; + } yy1474: - YYDEBUG(1474, *YYCURSOR); yych = *++YYCURSOR; goto yy1420; yy1475: - YYDEBUG(1475, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych == 'C') goto yy1477; - goto yy143; - } - } else { - if (yych <= 'b') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'c') goto yy1477; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'C': + case 'c': goto yy1477; + default: goto yy194; } yy1476: - YYDEBUG(1476, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '-') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy194; - goto yy196; - } else { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy197; - } - } else { - if (yych <= '@') { - if (yych == '/') goto yy194; - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy194; - if (yych <= 'z') goto yy143; - goto yy194; - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy194; } yy1477: - YYDEBUG(1477, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy144; - goto yy396; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'h') goto yy396; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'H': + case 'h': goto yy396; + default: goto yy4; } yy1478: - YYDEBUG(1478, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= '@') { - if (yych <= '/') goto yy148; - goto yy4; - } else { - if (yych == 'R') goto yy1475; - goto yy142; - } - } - } else { - if (yych <= '`') { - if (yych <= 'Z') { - if (yych <= 'Y') goto yy1476; - goto yy142; - } else { - if (yych == '_') goto yy148; - goto yy4; - } - } else { - if (yych <= 'x') { - if (yych == 'r') goto yy1490; - goto yy147; - } else { - if (yych <= 'y') goto yy1491; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': goto yy142; + case 'R': goto yy1475; + case 'Y': goto yy1476; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy147; + case 'r': goto yy1490; + case 'y': goto yy1491; + default: goto yy4; } yy1479: - YYDEBUG(1479, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1469; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'd') goto yy1484; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'D': goto yy1469; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'd': goto yy1484; + default: goto yy4; } yy1480: - YYDEBUG(1480, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1466; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'n') goto yy1481; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'N': goto yy1466; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'n': goto yy1481; + default: goto yy4; } yy1481: - YYDEBUG(1481, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy167; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy167; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'D') goto yy1467; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy167; - goto yy148; - } else { - if (yych <= 'c') { - if (yych <= '`') goto yy167; - goto yy151; - } else { - if (yych <= 'd') goto yy1482; - if (yych <= 'z') goto yy151; - goto yy167; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'D': goto yy1467; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'd': goto yy1482; + default: goto yy167; } yy1482: - YYDEBUG(1482, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '@') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '_') { - if (yych <= 'A') goto yy1468; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= '`') goto yy4; - if (yych <= 'a') goto yy1483; - if (yych <= 'z') goto yy152; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': goto yy1468; + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': goto yy1483; + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy4; } yy1483: - YYDEBUG(1483, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'X') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'Y') goto yy1236; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'x') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'y') goto yy1265; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Z': goto yy145; + case 'Y': goto yy1236; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'z': goto yy153; + case 'y': goto yy1265; + default: goto yy4; } yy1484: - YYDEBUG(1484, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1470; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'n') goto yy1485; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'N': goto yy1470; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'n': goto yy1485; + default: goto yy4; } yy1485: - YYDEBUG(1485, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'H') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'I') goto yy1471; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'h') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'i') goto yy1486; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'I': goto yy1471; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'i': goto yy1486; + default: goto yy4; } yy1486: - YYDEBUG(1486, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'F') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'G') goto yy1472; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'f') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'g') goto yy1487; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'G': goto yy1472; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'g': goto yy1487; + default: goto yy4; } yy1487: - YYDEBUG(1487, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'H') goto yy1473; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'h') goto yy1488; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'H': goto yy1473; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'h': goto yy1488; + default: goto yy4; } yy1488: - YYDEBUG(1488, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy1474; - if (yych != 't') goto yy155; - YYDEBUG(1489, *YYCURSOR); + switch (yych) { + case 'T': goto yy1474; + case 't': goto yy1489; + default: goto yy155; + } +yy1489: yyaccept = 30; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy1420; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy1420; + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy1420; } yy1490: - YYDEBUG(1490, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'B') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'C') goto yy1477; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'b') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'c') goto yy1492; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'C': goto yy1477; + case 'a': + case 'b': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'c': goto yy1492; + default: goto yy194; } yy1491: - YYDEBUG(1491, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '.') { - if (yych <= ' ') { - if (yych == '\t') goto yy196; - if (yych <= 0x1F) goto yy194; - goto yy196; - } else { - if (yych <= ')') { - if (yych <= '(') goto yy194; - goto yy140; - } else { - if (yych <= ',') goto yy194; - if (yych <= '-') goto yy372; - goto yy196; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '/') goto yy148; - if (yych <= '9') goto yy196; - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= '_') { - if (yych <= '^') goto yy194; - goto yy148; - } else { - if (yych <= '`') goto yy194; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + default: goto yy194; } yy1492: - YYDEBUG(1492, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy396; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'h') goto yy407; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'H': goto yy396; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'h': goto yy407; + default: goto yy4; } yy1493: - YYDEBUG(1493, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'W') { - if (yych <= 'N') { - if (yych == ')') goto yy140; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'O') goto yy1501; - if (yych <= 'U') goto yy142; - if (yych <= 'V') goto yy1502; - goto yy1499; - } - } else { - if (yych <= 'o') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - if (yych <= 'n') goto yy142; - goto yy1501; - } else { - if (yych <= 'v') { - if (yych <= 'u') goto yy142; - goto yy1502; - } else { - if (yych <= 'w') goto yy1499; - if (yych <= 'z') goto yy142; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'x': + case 'y': + case 'z': goto yy142; + case 'O': + case 'o': goto yy1501; + case 'V': + case 'v': goto yy1502; + case 'W': + case 'w': goto yy1499; + default: goto yy4; } yy1494: - YYDEBUG(1494, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'X') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'W') goto yy142; - goto yy1498; - } - } else { - if (yych <= 'w') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'x') goto yy1498; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'y': + case 'z': goto yy142; + case 'X': + case 'x': goto yy1498; + default: goto yy4; } yy1495: - YYDEBUG(1495, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy142; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 'n') goto yy1496; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'N': + case 'n': goto yy1496; + default: goto yy4; } yy1496: - YYDEBUG(1496, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1497; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1497; + default: goto yy4; } yy1497: - YYDEBUG(1497, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'H') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'G') goto yy144; - goto yy1239; - } - } else { - if (yych <= 'g') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'h') goto yy1239; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'H': + case 'h': goto yy1239; + default: goto yy4; } yy1498: - YYDEBUG(1498, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - goto yy1428; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1428; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1428; + default: goto yy4; } yy1499: - YYDEBUG(1499, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= '@') { - if (yych == ')') goto yy140; - } else { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy1500; - if (yych <= 'z') goto yy143; + switch ((yych = *YYCURSOR)) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + default: goto yy1500; } yy1500: - YYDEBUG(1500, *YYCURSOR); #line 1006 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("now"); @@ -23877,145 +37518,329 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 23881 "ext/date/lib/parse_date.c" +#line 37522 "" yy1501: - YYDEBUG(1501, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'N') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'M') goto yy143; - goto yy1507; - } - } else { - if (yych <= 'm') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 'n') goto yy1507; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'N': + case 'n': goto yy1507; + default: goto yy4; } yy1502: - YYDEBUG(1502, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= ',') { - if (yych <= ')') goto yy140; - goto yy194; - } else { - if (yych <= '-') goto yy197; - if (yych <= '.') goto yy196; - goto yy194; - } - } - } else { - if (yych <= 'Z') { - if (yych <= '@') { - if (yych <= '9') goto yy196; - goto yy194; - } else { - if (yych != 'E') goto yy143; - } - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy194; - goto yy143; - } else { - if (yych <= 'e') goto yy1503; - if (yych <= 'z') goto yy143; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy197; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'E': + case 'e': goto yy1503; + default: goto yy194; } yy1503: - YYDEBUG(1503, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'M') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'L') goto yy144; - } - } else { - if (yych <= 'l') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'm') goto yy1504; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'M': + case 'm': goto yy1504; + default: goto yy4; } yy1504: - YYDEBUG(1504, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'B') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'A') goto yy145; - } - } else { - if (yych <= 'a') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'b') goto yy1505; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'B': + case 'b': goto yy1505; + default: goto yy4; } yy1505: - YYDEBUG(1505, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'E') goto yy1506; - if (yych != 'e') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'E': + case 'e': goto yy1506; + default: goto yy4; } yy1506: - YYDEBUG(1506, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy206; - if (yych == 'r') goto yy206; - goto yy57; + switch (yych) { + case 'R': + case 'r': goto yy206; + default: goto yy57; + } yy1507: - YYDEBUG(1507, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) <= '@') { - if (yych == ')') goto yy140; - } else { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy1508; - if (yych <= 'z') goto yy144; + switch ((yych = *YYCURSOR)) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + default: goto yy1508; } yy1508: - YYDEBUG(1508, *YYCURSOR); #line 1015 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("noon"); @@ -24023,543 +37848,1070 @@ static int scan(Scanner *s) TIMELIB_UNHAVE_TIME(); TIMELIB_HAVE_TIME(); s->time->h = 12; - - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; - } -#line 24031 "ext/date/lib/parse_date.c" -yy1509: - YYDEBUG(1509, *YYCURSOR); - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'V') { - if (yych <= '.') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych == '-') goto yy148; - goto yy4; - } - } else { - if (yych <= 'N') { - if (yych <= '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } else { - if (yych <= 'O') goto yy1501; - if (yych <= 'U') goto yy142; - goto yy1502; - } - } - } else { - if (yych <= 'n') { - if (yych <= '^') { - if (yych <= 'W') goto yy1499; - if (yych <= 'Z') goto yy142; - goto yy4; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy4; - goto yy147; - } - } else { - if (yych <= 'v') { - if (yych <= 'o') goto yy1516; - if (yych <= 'u') goto yy147; - goto yy1517; - } else { - if (yych <= 'w') goto yy1515; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; + } +#line 37856 "" +yy1509: + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'O': goto yy1501; + case 'V': goto yy1502; + case 'W': goto yy1499; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'x': + case 'y': + case 'z': goto yy147; + case 'o': goto yy1516; + case 'v': goto yy1517; + case 'w': goto yy1515; + default: goto yy4; } yy1510: - YYDEBUG(1510, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'W') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'X') goto yy1498; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'w') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'x') goto yy1514; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'Y': + case 'Z': goto yy142; + case 'X': goto yy1498; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'y': + case 'z': goto yy147; + case 'x': goto yy1514; + default: goto yy4; } yy1511: - YYDEBUG(1511, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1496; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 'n') goto yy1512; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'N': goto yy1496; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 'n': goto yy1512; + default: goto yy4; } yy1512: - YYDEBUG(1512, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1497; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1513; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1497; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1513; + default: goto yy4; } yy1513: - YYDEBUG(1513, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'G') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'H') goto yy1239; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'g') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'h') goto yy1268; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'H': goto yy1239; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'h': goto yy1268; + default: goto yy4; } yy1514: - YYDEBUG(1514, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1428; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1460; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1428; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1460; + default: goto yy4; } yy1515: - YYDEBUG(1515, *YYCURSOR); yyaccept = 31; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy1500; - } else { - if (yych == '.') goto yy1500; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy1500; - if (yych <= 'Z') goto yy143; - goto yy1500; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy1500; - if (yych <= 'z') goto yy151; - goto yy1500; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + default: goto yy1500; } yy1516: - YYDEBUG(1516, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'M') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'N') goto yy1507; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'm') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 'n') goto yy1522; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'N': goto yy1507; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'n': goto yy1522; + default: goto yy4; } yy1517: - YYDEBUG(1517, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '9') { - if (yych <= '(') { - if (yych <= '\t') { - if (yych <= 0x08) goto yy194; - goto yy196; - } else { - if (yych == ' ') goto yy196; - goto yy194; - } - } else { - if (yych <= '-') { - if (yych <= ')') goto yy140; - if (yych <= ',') goto yy194; - goto yy372; - } else { - if (yych == '/') goto yy148; - goto yy196; - } - } - } else { - if (yych <= '^') { - if (yych <= 'D') { - if (yych <= '@') goto yy194; - goto yy143; - } else { - if (yych <= 'E') goto yy1503; - if (yych <= 'Z') goto yy143; - goto yy194; - } - } else { - if (yych <= 'd') { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy194; - goto yy151; - } else { - if (yych <= 'e') goto yy1518; - if (yych <= 'z') goto yy151; - goto yy194; - } - } + switch (yych) { + case '\t': + case ' ': + case '.': + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy196; + case ')': goto yy140; + case '-': goto yy372; + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'E': goto yy1503; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 'e': goto yy1518; + default: goto yy194; } yy1518: - YYDEBUG(1518, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'L') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'M') goto yy1504; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'l') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'm') goto yy1519; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'M': goto yy1504; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'm': goto yy1519; + default: goto yy4; } yy1519: - YYDEBUG(1519, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'A') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'B') goto yy1505; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'a') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'b') goto yy1520; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'B': goto yy1505; + case 'a': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'b': goto yy1520; + default: goto yy4; } yy1520: - YYDEBUG(1520, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'E') goto yy1506; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'e') goto yy1521; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'E': goto yy1506; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'e': goto yy1521; + default: goto yy4; } yy1521: - YYDEBUG(1521, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy206; - if (yych == 'r') goto yy377; - goto yy155; + switch (yych) { + case 'R': goto yy206; + case 'r': goto yy377; + default: goto yy155; + } yy1522: - YYDEBUG(1522, *YYCURSOR); yyaccept = 32; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= '/') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy1508; - } else { - if (yych == '.') goto yy1508; - goto yy148; - } - } else { - if (yych <= '^') { - if (yych <= '@') goto yy1508; - if (yych <= 'Z') goto yy144; - goto yy1508; - } else { - if (yych <= '_') goto yy148; - if (yych <= '`') goto yy1508; - if (yych <= 'z') goto yy152; - goto yy1508; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + default: goto yy1508; } yy1523: - YYDEBUG(1523, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'S') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'R') goto yy142; - } - } else { - if (yych <= 'r') { - if (yych <= 'Z') goto yy142; - if (yych <= '`') goto yy4; - goto yy142; - } else { - if (yych <= 's') goto yy1524; - if (yych <= 'z') goto yy142; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy142; + case 'S': + case 's': goto yy1524; + default: goto yy4; } yy1524: - YYDEBUG(1524, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'S') goto yy143; - } - } else { - if (yych <= 's') { - if (yych <= 'Z') goto yy143; - if (yych <= '`') goto yy4; - goto yy143; - } else { - if (yych <= 't') goto yy1525; - if (yych <= 'z') goto yy143; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy143; + case 'T': + case 't': goto yy1525; + default: goto yy4; } yy1525: - YYDEBUG(1525, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'E') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'D') goto yy144; - } - } else { - if (yych <= 'd') { - if (yych <= 'Z') goto yy144; - if (yych <= '`') goto yy4; - goto yy144; - } else { - if (yych <= 'e') goto yy1526; - if (yych <= 'z') goto yy144; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy144; + case 'E': + case 'e': goto yy1526; + default: goto yy4; } yy1526: - YYDEBUG(1526, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'R') { - if (yych <= ')') { - if (yych <= '(') goto yy4; - goto yy140; - } else { - if (yych <= '@') goto yy4; - if (yych <= 'Q') goto yy145; - } - } else { - if (yych <= 'q') { - if (yych <= 'Z') goto yy145; - if (yych <= '`') goto yy4; - goto yy145; - } else { - if (yych <= 'r') goto yy1527; - if (yych <= 'z') goto yy145; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy145; + case 'R': + case 'r': goto yy1527; + default: goto yy4; } yy1527: - YYDEBUG(1527, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych <= 'D') goto yy1528; - if (yych != 'd') goto yy4; + switch (yych) { + case ')': goto yy140; + case 'D': + case 'd': goto yy1528; + default: goto yy4; } yy1528: - YYDEBUG(1528, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1529; - if (yych != 'a') goto yy57; + switch (yych) { + case 'A': + case 'a': goto yy1529; + default: goto yy57; + } yy1529: - YYDEBUG(1529, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy1530; - if (yych != 'y') goto yy57; + switch (yych) { + case 'Y': + case 'y': goto yy1530; + default: goto yy57; + } yy1530: - YYDEBUG(1530, *YYCURSOR); ++YYCURSOR; yy1531: - YYDEBUG(1531, *YYCURSOR); #line 994 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("yesterday"); @@ -24571,177 +38923,340 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 24575 "ext/date/lib/parse_date.c" +#line 38927 "" yy1532: - YYDEBUG(1532, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'R') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy142; - } - } else { - if (yych <= '_') { - if (yych <= 'S') goto yy1524; - if (yych <= 'Z') goto yy142; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'r') { - if (yych <= '`') goto yy4; - goto yy147; - } else { - if (yych <= 's') goto yy1533; - if (yych <= 'z') goto yy147; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy142; + case 'S': goto yy1524; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy147; + case 's': goto yy1533; + default: goto yy4; } yy1533: - YYDEBUG(1533, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'S') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy143; - } - } else { - if (yych <= '_') { - if (yych <= 'T') goto yy1525; - if (yych <= 'Z') goto yy143; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 's') { - if (yych <= '`') goto yy4; - goto yy151; - } else { - if (yych <= 't') goto yy1534; - if (yych <= 'z') goto yy151; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy143; + case 'T': goto yy1525; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy151; + case 't': goto yy1534; + default: goto yy4; } yy1534: - YYDEBUG(1534, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'D') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy144; - } - } else { - if (yych <= '_') { - if (yych <= 'E') goto yy1526; - if (yych <= 'Z') goto yy144; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'd') { - if (yych <= '`') goto yy4; - goto yy152; - } else { - if (yych <= 'e') goto yy1535; - if (yych <= 'z') goto yy152; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy144; + case 'E': goto yy1526; + case 'a': + case 'b': + case 'c': + case 'd': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy152; + case 'e': goto yy1535; + default: goto yy4; } yy1535: - YYDEBUG(1535, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'Q') { - if (yych <= '-') { - if (yych == ')') goto yy140; - if (yych <= ',') goto yy4; - goto yy148; - } else { - if (yych == '/') goto yy148; - if (yych <= '@') goto yy4; - goto yy145; - } - } else { - if (yych <= '_') { - if (yych <= 'R') goto yy1527; - if (yych <= 'Z') goto yy145; - if (yych <= '^') goto yy4; - goto yy148; - } else { - if (yych <= 'q') { - if (yych <= '`') goto yy4; - goto yy153; - } else { - if (yych <= 'r') goto yy1536; - if (yych <= 'z') goto yy153; - goto yy4; - } - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': goto yy145; + case 'R': goto yy1527; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy153; + case 'r': goto yy1536; + default: goto yy4; } yy1536: - YYDEBUG(1536, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= 'C') { - if (yych <= ',') { - if (yych == ')') goto yy140; - goto yy4; - } else { - if (yych == '.') goto yy4; - if (yych <= '/') goto yy148; - goto yy4; - } - } else { - if (yych <= '`') { - if (yych <= 'D') goto yy1528; - if (yych == '_') goto yy148; - goto yy4; - } else { - if (yych == 'd') goto yy1537; - if (yych <= 'z') goto yy154; - goto yy4; - } + switch (yych) { + case ')': goto yy140; + case '-': + case '/': + case '_': goto yy148; + case 'D': goto yy1528; + case 'a': + case 'b': + case 'c': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + case 'd': goto yy1537; + default: goto yy4; } yy1537: - YYDEBUG(1537, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy1529; - if (yych != 'a') goto yy155; - YYDEBUG(1538, *YYCURSOR); + switch (yych) { + case 'A': goto yy1529; + case 'a': goto yy1538; + default: goto yy155; + } +yy1538: yych = *++YYCURSOR; - if (yych == 'Y') goto yy1530; - if (yych != 'y') goto yy155; - YYDEBUG(1539, *YYCURSOR); + switch (yych) { + case 'Y': goto yy1530; + case 'y': goto yy1539; + default: goto yy155; + } +yy1539: yyaccept = 33; yych = *(YYMARKER = ++YYCURSOR); - if (yybm[0+yych] & 16) { - goto yy154; - } - if (yych <= '.') { - if (yych == '-') goto yy148; - goto yy1531; - } else { - if (yych <= '/') goto yy148; - if (yych == '_') goto yy148; - goto yy1531; + switch (yych) { + case '-': + case '/': + case '_': goto yy148; + case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy154; + default: goto yy1531; } } #line 1755 "ext/date/lib/parse_date.re" @@ -25107,7 +39622,8 @@ timelib_time *timelib_parse_from_format(char *format, char *string, int len, tim } if (*fptr) { /* Trailing | and ! specifiers are valid. */ - while (*fptr) { + int done = 0; + while (*fptr && !done) { switch (*fptr++) { case '!': /* reset all fields to default */ timelib_time_reset_fields(s->time); @@ -25119,6 +39635,7 @@ timelib_time *timelib_parse_from_format(char *format, char *string, int len, tim default: add_pbf_error(s, "Data missing", string, ptr); + done = 1; } } } diff --git a/ext/date/lib/parse_date.re b/ext/date/lib/parse_date.re index 1d571179fa29e..d0ac7afc355fa 100644 --- a/ext/date/lib/parse_date.re +++ b/ext/date/lib/parse_date.re @@ -2114,7 +2114,8 @@ timelib_time *timelib_parse_from_format(char *format, char *string, int len, tim } if (*fptr) { /* Trailing | and ! specifiers are valid. */ - while (*fptr) { + int done = 0; + while (*fptr && !done) { switch (*fptr++) { case '!': /* reset all fields to default */ timelib_time_reset_fields(s->time); @@ -2126,6 +2127,7 @@ timelib_time *timelib_parse_from_format(char *format, char *string, int len, tim default: add_pbf_error(s, "Data missing", string, ptr); + done = 1; } } } From c34b86c454cc16810c5061f17bfb3ea0818e819d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 20:16:08 +0000 Subject: [PATCH 0198/2394] - Removed unnecessary TSRMLS_FETCH --- Zend/zend_compile.c | 1 - 1 file changed, 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 18e7101de2de1..a3effdf475050 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -340,7 +340,6 @@ int zend_add_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC) /* {{{ * } if (Z_TYPE_P(zv) == IS_STRING || Z_TYPE_P(zv) == IS_CONSTANT) { zval *z = (zval*)zv; - TSRMLS_FETCH(); Z_STRVAL_P(z) = zend_new_interned_string(Z_STRVAL_P(zv), Z_STRLEN_P(zv) + 1, 1 TSRMLS_CC); From 142ce5c949bb674a007792f73ffceeb108e9999d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Jun 2011 21:56:09 +0000 Subject: [PATCH 0199/2394] - Minor optimization (avoid to re-hash already computed var name hash) --- Zend/zend_compile.c | 20 +++++++++++--------- Zend/zend_compile.h | 1 + 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index a3effdf475050..dae0acd5eb0fb 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -291,10 +291,10 @@ static zend_uint get_temporary_variable(zend_op_array *op_array) /* {{{ */ } /* }}} */ -static int lookup_cv(zend_op_array *op_array, char* name, int name_len TSRMLS_DC) /* {{{ */ +static int lookup_cv(zend_op_array *op_array, char* name, int name_len, ulong hash TSRMLS_DC) /* {{{ */ { int i = 0; - ulong hash_value = zend_inline_hash_func(name, name_len+1); + ulong hash_value = hash ? hash : zend_inline_hash_func(name, name_len+1); while (i < op_array->last_var) { if (op_array->vars[i].name == name || @@ -642,7 +642,7 @@ void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar (CG(active_op_array)->last == 0 || CG(active_op_array)->opcodes[CG(active_op_array)->last-1].opcode != ZEND_BEGIN_SILENCE)) { result->op_type = IS_CV; - result->u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len TSRMLS_CC); + result->u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len, 0 TSRMLS_CC); varname->u.constant.value.str.val = CG(active_op_array)->vars[result->u.op.var].name; result->EA = 0; return; @@ -882,6 +882,7 @@ static zend_bool opline_is_fetch_this(const zend_op *opline TSRMLS_DC) /* {{{ */ { if ((opline->opcode == ZEND_FETCH_W) && (opline->op1_type == IS_CONST) && (Z_TYPE(CONSTANT(opline->op1.constant)) == IS_STRING) + && (Z_HASH_P(&CONSTANT(opline->op1.constant)) == THIS_HASHVAL) && (Z_STRLEN(CONSTANT(opline->op1.constant)) == (sizeof("this")-1)) && !memcmp(Z_STRVAL(CONSTANT(opline->op1.constant)), "this", sizeof("this"))) { return 1; @@ -1290,7 +1291,7 @@ void zend_do_end_variable_parse(znode *variable, int type, int arg_offset TSRMLS this_var = opline_ptr->result.var; if (CG(active_op_array)->this_var == -1) { - CG(active_op_array)->this_var = lookup_cv(CG(active_op_array), Z_STRVAL(CONSTANT(opline_ptr->op1.constant)), Z_STRLEN(CONSTANT(opline_ptr->op1.constant)) TSRMLS_CC); + CG(active_op_array)->this_var = lookup_cv(CG(active_op_array), Z_STRVAL(CONSTANT(opline_ptr->op1.constant)), Z_STRLEN(CONSTANT(opline_ptr->op1.constant)), Z_HASH_P(&CONSTANT(opline_ptr->op1.constant)) TSRMLS_CC); Z_TYPE(CONSTANT(opline_ptr->op1.constant)) = IS_NULL; } else { zend_del_literal(CG(active_op_array), opline_ptr->op1.constant); @@ -1302,7 +1303,7 @@ void zend_do_end_variable_parse(znode *variable, int type, int arg_offset TSRMLS variable->u.op.var = CG(active_op_array)->this_var; } } else if (CG(active_op_array)->this_var == -1) { - CG(active_op_array)->this_var = lookup_cv(CG(active_op_array), estrndup("this", sizeof("this")-1), sizeof("this")-1 TSRMLS_CC); + CG(active_op_array)->this_var = lookup_cv(CG(active_op_array), estrndup("this", sizeof("this")-1), sizeof("this")-1, THIS_HASHVAL TSRMLS_CC); } } @@ -1810,10 +1811,11 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con zend_error(E_COMPILE_ERROR, "Cannot re-assign auto-global variable %s", Z_STRVAL(varname->u.constant)); } else { var.op_type = IS_CV; - var.u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len TSRMLS_CC); + var.u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len, 0 TSRMLS_CC); varname->u.constant.value.str.val = CG(active_op_array)->vars[var.u.op.var].name; var.EA = 0; - if (Z_STRLEN(varname->u.constant) == sizeof("this")-1 && + if (CG(active_op_array)->vars[var.u.op.var].hash_value == THIS_HASHVAL && + Z_STRLEN(varname->u.constant) == sizeof("this")-1 && !memcmp(Z_STRVAL(varname->u.constant), "this", sizeof("this")-1)) { if (CG(active_op_array)->scope && (CG(active_op_array)->fn_flags & ZEND_ACC_STATIC) == 0) { @@ -2699,7 +2701,7 @@ void zend_do_begin_catch(znode *try_token, znode *class_name, znode *catch_var, opline->op1_type = IS_CONST; opline->op1.constant = zend_add_class_name_literal(CG(active_op_array), &catch_class.u.constant TSRMLS_CC); opline->op2_type = IS_CV; - opline->op2.var = lookup_cv(CG(active_op_array), catch_var->u.constant.value.str.val, catch_var->u.constant.value.str.len TSRMLS_CC); + opline->op2.var = lookup_cv(CG(active_op_array), catch_var->u.constant.value.str.val, catch_var->u.constant.value.str.len, 0 TSRMLS_CC); catch_var->u.constant.value.str.val = CG(active_op_array)->vars[opline->op2.var].name; opline->result.num = 0; /* 1 means it's the last catch in the block */ @@ -5642,7 +5644,7 @@ void zend_do_indirect_references(znode *result, const znode *num_references, zno fetch_simple_variable(result, variable, 1 TSRMLS_CC); /* there is a chance someone is accessing $this */ if (CG(active_op_array)->scope && CG(active_op_array)->this_var == -1) { - CG(active_op_array)->this_var = lookup_cv(CG(active_op_array), estrndup("this", sizeof("this")-1), sizeof("this")-1 TSRMLS_CC); + CG(active_op_array)->this_var = lookup_cv(CG(active_op_array), estrndup("this", sizeof("this")-1), sizeof("this")-1, THIS_HASHVAL TSRMLS_CC); } } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 8ce7c405f80a9..98620d4496707 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -134,6 +134,7 @@ typedef struct _zend_try_catch_element { zend_uint catch_op; /* ketchup! */ } zend_try_catch_element; +#define THIS_HASHVAL 275574653UL /* method flags (types) */ #define ZEND_ACC_STATIC 0x01 From b5e5abb38ab10686d11978e847cf3675bdac56d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 20 Jun 2011 00:03:39 +0000 Subject: [PATCH 0200/2394] Removed pid in debug logs written by chrildren processes --- sapi/fpm/fpm/zlog.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sapi/fpm/fpm/zlog.c b/sapi/fpm/fpm/zlog.c index fe62fd5ce66dc..e45f5c5379598 100644 --- a/sapi/fpm/fpm/zlog.c +++ b/sapi/fpm/fpm/zlog.c @@ -93,7 +93,11 @@ void zlog_ex(const char *function, int line, int flags, const char *fmt, ...) /* len = zlog_print_time(&tv, buf, buf_size); } if (zlog_level == ZLOG_DEBUG) { - len += snprintf(buf + len, buf_size - len, "%s: pid %d, %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], getpid(), function, line); + if (!fpm_globals.is_child) { + len += snprintf(buf + len, buf_size - len, "%s: pid %d, %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], getpid(), function, line); + } else { + len += snprintf(buf + len, buf_size - len, "%s: %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], function, line); + } } else { len += snprintf(buf + len, buf_size - len, "%s: ", level_names[flags & ZLOG_LEVEL_MASK]); } From b26f6cb0f675189ab1678ab21e7b057de4abfbf1 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 20 Jun 2011 01:21:47 +0000 Subject: [PATCH 0201/2394] - Avoid re-hash here too --- Zend/zend_compile.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index dae0acd5eb0fb..a37af8d85ea90 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -633,8 +633,12 @@ void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar zend_llist *fetch_list_ptr; if (varname->op_type == IS_CONST) { + ulong hash = 0; + if (Z_TYPE(varname->u.constant) != IS_STRING) { convert_to_string(&varname->u.constant); + } else if (IS_INTERNED(Z_STRVAL(varname->u.constant))) { + hash = INTERNED_HASH(Z_STRVAL(varname->u.constant)); } if (!zend_is_auto_global(varname->u.constant.value.str.val, varname->u.constant.value.str.len TSRMLS_CC) && !(varname->u.constant.value.str.len == (sizeof("this")-1) && @@ -642,7 +646,7 @@ void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar (CG(active_op_array)->last == 0 || CG(active_op_array)->opcodes[CG(active_op_array)->last-1].opcode != ZEND_BEGIN_SILENCE)) { result->op_type = IS_CV; - result->u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len, 0 TSRMLS_CC); + result->u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len, hash TSRMLS_CC); varname->u.constant.value.str.val = CG(active_op_array)->vars[result->u.op.var].name; result->EA = 0; return; From d188a36547315e1a7d4fef68de5371f4837220f8 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 20 Jun 2011 01:36:23 +0000 Subject: [PATCH 0202/2394] - Simplify function code --- Zend/zend_compile.c | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index a37af8d85ea90..03d4e97c9cee2 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3769,27 +3769,28 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* /* }}} */ static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_trait_precedence **precedences, zend_class_entry *trait) { - size_t i, j; - if (precedences) { - i = 0; - while (precedences[i]) { - if (precedences[i]->exclude_from_classes) { - j = 0; - while (precedences[i]->exclude_from_classes[j]) { - if (precedences[i]->exclude_from_classes[j] == trait) { - zend_uint lcname_len = precedences[i]->trait_method->mname_len; - char* lcname = zend_str_tolower_dup(precedences[i]->trait_method->method_name, - lcname_len); - if (zend_hash_add(exclude_table, lcname, lcname_len, NULL, 0, NULL)==FAILURE) { - zend_error(E_COMPILE_ERROR, "Failed to evaluate a trait precedence (%s). Method of trait %s was defined to be excluded multiple times", precedences[i]->trait_method->method_name, trait->name); - } + size_t i = 0, j; + + if (!precedences) { + return; + } + while (precedences[i]) { + if (precedences[i]->exclude_from_classes) { + j = 0; + while (precedences[i]->exclude_from_classes[j]) { + if (precedences[i]->exclude_from_classes[j] == trait) { + zend_uint lcname_len = precedences[i]->trait_method->mname_len; + char *lcname = zend_str_tolower_dup(precedences[i]->trait_method->method_name, lcname_len); + if (zend_hash_add(exclude_table, lcname, lcname_len, NULL, 0, NULL) == FAILURE) { efree(lcname); + zend_error(E_COMPILE_ERROR, "Failed to evaluate a trait precedence (%s). Method of trait %s was defined to be excluded multiple times", precedences[i]->trait_method->method_name, trait->name); } - j++; + efree(lcname); } + ++j; } - i++; } + ++i; } } From 58d41e5753518f6010e191bd96dd77e0de4e5e04 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 20 Jun 2011 02:04:13 +0000 Subject: [PATCH 0203/2394] - Optimize property finding by zend_hash_quick_find --- Zend/zend_compile.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 03d4e97c9cee2..7842ec8f2ef00 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3851,12 +3851,12 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ free(resulting_table); } -static zend_class_entry* find_first_definition(zend_class_entry *ce, size_t current_trait, char* prop_name, int prop_name_length, zend_class_entry *coliding_ce) /* {{{ */ +static zend_class_entry* find_first_definition(zend_class_entry *ce, size_t current_trait, char* prop_name, int prop_name_length, ulong prop_hash, zend_class_entry *coliding_ce) /* {{{ */ { size_t i; zend_property_info *coliding_prop; for (i = 0; (i < current_trait) && (i < ce->num_traits); i++) { - if (zend_hash_find(&ce->traits[i]->properties_info, prop_name, prop_name_length+1, (void **) &coliding_prop) == SUCCESS) { + if (zend_hash_quick_find(&ce->traits[i]->properties_info, prop_name, prop_name_length+1, prop_hash, (void **) &coliding_prop) == SUCCESS) { return ce->traits[i]; } } @@ -3872,6 +3872,7 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { zval compare_result; char* prop_name; int prop_name_length; + ulong prop_hash; char* class_name_unused; zend_bool prop_found; zend_bool not_compatible; @@ -3894,6 +3895,7 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { /* first get the unmangeld name if necessary, then check whether the property is already there */ if ((property_info->flags & ZEND_ACC_PPP_MASK) == ZEND_ACC_PUBLIC) { + prop_hash = property_info->h; prop_name = property_info->name; prop_name_length = property_info->name_length; prop_found = zend_hash_quick_find(&ce->properties_info, @@ -3904,14 +3906,15 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { zend_unmangle_property_name(property_info->name, property_info->name_length, &class_name_unused, &prop_name); prop_name_length = strlen(prop_name); - prop_found = zend_hash_find(&ce->properties_info, prop_name, prop_name_length+1, (void **) &coliding_prop) == SUCCESS; + prop_hash = zend_get_hash_value(prop_name, prop_name_length + 1); + prop_found = zend_hash_quick_find(&ce->properties_info, prop_name, prop_name_length+1, prop_hash, (void **) &coliding_prop) == SUCCESS; } /* next: check for conflicts with current class */ if (prop_found) { if (coliding_prop->flags & ZEND_ACC_SHADOW) { /* this one is inherited, lets look it up in its own class */ - zend_hash_find(&coliding_prop->ce->properties_info, prop_name, prop_name_length+1, (void **) &coliding_prop); + zend_hash_quick_find(&coliding_prop->ce->properties_info, prop_name, prop_name_length+1, prop_hash, (void **) &coliding_prop); } if ((coliding_prop->flags & ZEND_ACC_PPP_MASK) == (property_info->flags & ZEND_ACC_PPP_MASK)) { /* flags are identical, now the value needs to be checked */ @@ -3921,8 +3924,8 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { ce->traits[i]->default_static_members_table[property_info->offset] TSRMLS_CC) == FAILURE; } else { not_compatible = compare_function(&compare_result, - ce->default_properties_table[coliding_prop->offset], - ce->traits[i]->default_properties_table[property_info->offset] TSRMLS_CC) == FAILURE; + ce->default_properties_table[coliding_prop->offset], + ce->traits[i]->default_properties_table[property_info->offset] TSRMLS_CC) == FAILURE; } } else { /* the flags are not identical, thus, we assume properties are not compatible */ @@ -3932,14 +3935,14 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { if (not_compatible) { zend_error(E_COMPILE_ERROR, "%s and %s define the same property ($%s) in the composition of %s. However, the definition differs and is considered incompatible. Class was composed", - find_first_definition(ce, i, prop_name, prop_name_length, coliding_prop->ce)->name, + find_first_definition(ce, i, prop_name, prop_name_length, prop_hash, coliding_prop->ce)->name, property_info->ce->name, prop_name, ce->name); } else { zend_error(E_STRICT, "%s and %s define the same property ($%s) in the composition of %s. This might be incompatible, to improve maintainability consider using accessor methods in traits instead. Class was composed", - find_first_definition(ce, i, prop_name, prop_name_length, coliding_prop->ce)->name, + find_first_definition(ce, i, prop_name, prop_name_length, prop_hash, coliding_prop->ce)->name, property_info->ce->name, prop_name, ce->name); From 97ec4f2702db973edcab562bdc26c5e4bed511dc Mon Sep 17 00:00:00 2001 From: Patrick Allaert Date: Mon, 20 Jun 2011 07:11:21 +0000 Subject: [PATCH 0204/2394] Changed register_shutdown_function() to reflect that it is using a cb (thx arpad) --- ext/standard/basic_functions.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index ee74bd2959462..f9db33dee878f 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -5062,12 +5062,12 @@ void php_free_shutdown_functions(TSRMLS_D) /* {{{ */ } /* }}} */ -/* {{{ proto void register_shutdown_function(string function_name) U +/* {{{ proto void register_shutdown_function(callback function) U Register a user-level function to be called on request termination */ PHP_FUNCTION(register_shutdown_function) { php_shutdown_function_entry shutdown_function_entry; - char *function_name = NULL; + char *callback_name = NULL; int i; shutdown_function_entry.arg_count = ZEND_NUM_ARGS(); @@ -5084,8 +5084,8 @@ PHP_FUNCTION(register_shutdown_function) } /* Prevent entering of anything but valid callback (syntax check only!) */ - if (!zend_is_callable(shutdown_function_entry.arguments[0], 0, &function_name TSRMLS_CC)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid shutdown callback '%s' passed", function_name); + if (!zend_is_callable(shutdown_function_entry.arguments[0], 0, &callback_name TSRMLS_CC)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid shutdown callback '%s' passed", callback_name); efree(shutdown_function_entry.arguments); RETVAL_FALSE; } else { @@ -5099,8 +5099,8 @@ PHP_FUNCTION(register_shutdown_function) } zend_hash_next_index_insert(BG(user_shutdown_function_names), &shutdown_function_entry, sizeof(php_shutdown_function_entry), NULL); } - if (function_name) { - efree(function_name); + if (callback_name) { + efree(callback_name); } } /* }}} */ From 101c6a3831c9d2f2fb85742b73ab2c31aef3abc9 Mon Sep 17 00:00:00 2001 From: Patrick Allaert Date: Mon, 20 Jun 2011 17:49:19 +0000 Subject: [PATCH 0205/2394] Fixed typo --- Zend/tests/concat_001.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/concat_001.phpt b/Zend/tests/concat_001.phpt index be1297655d967..d7bc525c4f2fd 100644 --- a/Zend/tests/concat_001.phpt +++ b/Zend/tests/concat_001.phpt @@ -1,5 +1,5 @@ --TEST-- -concat difffent types +concat different types --INI-- precision=14 --FILE-- From 7dfef17c541dd6826dda92ddc23cfaca2bb21442 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Mon, 20 Jun 2011 20:27:39 +0000 Subject: [PATCH 0206/2394] - Add built-in web server to CLI SAPI. See the RFC for detail. --- sapi/cli/config.m4 | 2 +- sapi/cli/config.w32 | 3 +- sapi/cli/php_cli.c | 1261 +++++++++++----------- sapi/cli/php_cli_server.c | 2084 ++++++++++++++++++++++++++++++++++++ sapi/cli/php_cli_server.h | 38 + sapi/cli/php_http_parser.c | 1602 +++++++++++++++++++++++++++ sapi/cli/php_http_parser.h | 182 ++++ 7 files changed, 4554 insertions(+), 618 deletions(-) create mode 100644 sapi/cli/php_cli_server.c create mode 100644 sapi/cli/php_cli_server.h create mode 100644 sapi/cli/php_http_parser.c create mode 100644 sapi/cli/php_http_parser.h diff --git a/sapi/cli/config.m4 b/sapi/cli/config.m4 index 68263639d5be5..77fc5e9551ce5 100644 --- a/sapi/cli/config.m4 +++ b/sapi/cli/config.m4 @@ -14,7 +14,7 @@ if test "$PHP_CLI" != "no"; then SAPI_CLI_PATH=sapi/cli/php dnl Select SAPI - PHP_SELECT_SAPI(cli, program, php_cli.c,, '$(SAPI_CLI_PATH)') + PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c,, '$(SAPI_CLI_PATH)') case $host_alias in *aix*) diff --git a/sapi/cli/config.w32 b/sapi/cli/config.w32 index d6eac80f6866b..4d0dad58e84b4 100644 --- a/sapi/cli/config.w32 +++ b/sapi/cli/config.w32 @@ -6,7 +6,8 @@ ARG_ENABLE('crt-debug', 'Enable CRT memory dumps for debugging sent to STDERR', ARG_ENABLE('cli-win32', 'Build console-less CLI version of PHP', 'no'); if (PHP_CLI == "yes") { - SAPI('cli', 'php_cli.c', 'php.exe'); + SAPI('cli', 'php_cli.c php_http_parser.c php_cli_server.c', 'php.exe'); + ADD_FLAG("LIBS_CLI", "ws2_32.lib"); if (PHP_CRT_DEBUG == "yes") { ADD_FLAG("CFLAGS_CLI", "/D PHP_WIN32_DEBUG_HEAP"); } diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index f90bd061f6d6d..250beae2edea3 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -84,6 +84,10 @@ #include "php_getopt.h" +#ifndef PHP_CLI_WIN32_NO_CONSOLE +#include "php_cli_server.h" +#endif + #ifndef PHP_WIN32 # define php_select(m, r, w, e, t) select(m, r, w, e, t) #else @@ -126,10 +130,8 @@ const char HARDCODED_INI[] = "max_execution_time=0\n" "max_input_time=-1\n\0"; -static char *php_optarg = NULL; -static int php_optind = 1; -static const opt_struct OPTIONS[] = { +const opt_struct OPTIONS[] = { {'a', 0, "interactive"}, {'B', 1, "process-begin"}, {'C', 0, "no-chdir"}, /* for compatibility with CGI (do not chdir to script directory) */ @@ -150,6 +152,8 @@ static const opt_struct OPTIONS[] = { {'r', 1, "run"}, {'s', 0, "syntax-highlight"}, {'s', 0, "syntax-highlighting"}, + {'S', 1, "server"}, + {'t', 1, "docroot"}, {'w', 0, "strip"}, {'?', 0, "usage"},/* help alias (both '?' and 'usage') */ {'v', 0, "version"}, @@ -172,7 +176,7 @@ static const opt_struct OPTIONS[] = { static int print_module_info(zend_module_entry *module TSRMLS_DC) /* {{{ */ { - php_printf("%s\n", module->name); + printf("%s\n", module->name); return ZEND_HASH_APPLY_KEEP; } /* }}} */ @@ -202,7 +206,7 @@ static void print_modules(TSRMLS_D) /* {{{ */ static int print_extension_info(zend_extension *ext, void *arg TSRMLS_DC) /* {{{ */ { - php_printf("%s\n", ext->name); + printf("%s\n", ext->name); return ZEND_HASH_APPLY_KEEP; } /* }}} */ @@ -494,50 +498,52 @@ static void php_cli_usage(char *argv0) prog = "php"; } - php_printf( "Usage: %s [options] [-f] [--] [args...]\n" - " %s [options] -r [--] [args...]\n" - " %s [options] [-B ] -R [-E ] [--] [args...]\n" - " %s [options] [-B ] -F [-E ] [--] [args...]\n" - " %s [options] -- [args...]\n" - " %s [options] -a\n" - "\n" + printf( "Usage: %s [options] [-f] [--] [args...]\n" + " %s [options] -r [--] [args...]\n" + " %s [options] [-B ] -R [-E ] [--] [args...]\n" + " %s [options] [-B ] -F [-E ] [--] [args...]\n" + " %s [options] -- [args...]\n" + " %s [options] -a\n" + "\n" #if (HAVE_LIBREADLINE || HAVE_LIBEDIT) && !defined(COMPILE_DL_READLINE) - " -a Run as interactive shell\n" + " -a Run as interactive shell\n" #else - " -a Run interactively\n" + " -a Run interactively\n" #endif " -c | Look for php.ini file in this directory\n" - " -n No php.ini file will be used\n" - " -d foo[=bar] Define INI entry foo with value 'bar'\n" - " -e Generate extended information for debugger/profiler\n" - " -f Parse and execute .\n" - " -h This help\n" - " -i PHP information\n" - " -l Syntax check only (lint)\n" - " -m Show compiled in modules\n" - " -r Run PHP without using script tags \n" + " -n No php.ini file will be used\n" + " -d foo[=bar] Define INI entry foo with value 'bar'\n" + " -e Generate extended information for debugger/profiler\n" + " -f Parse and execute .\n" + " -h This help\n" + " -i PHP information\n" + " -l Syntax check only (lint)\n" + " -m Show compiled in modules\n" + " -r Run PHP without using script tags \n" " -B Run PHP before processing input lines\n" - " -R Run PHP for every input line\n" - " -F Parse and execute for every input line\n" - " -E Run PHP after processing all input lines\n" - " -H Hide any passed arguments from external tools.\n" - " -s Output HTML syntax highlighted source.\n" - " -v Version number\n" - " -w Output source with stripped comments and whitespace.\n" - " -z Load Zend extension .\n" + " -R Run PHP for every input line\n" + " -F Parse and execute for every input line\n" + " -E Run PHP after processing all input lines\n" + " -H Hide any passed arguments from external tools.\n" + " -S : Run with built-in web server.\n" + " -t Specify document root for bult-in web server.\n" + " -s Output HTML syntax highlighted source.\n" + " -v Version number\n" + " -w Output source with stripped comments and whitespace.\n" + " -z Load Zend extension .\n" "\n" - " args... Arguments passed to script. Use -- args when first argument\n" - " starts with - or script is read from stdin\n" + " args... Arguments passed to script. Use -- args when first argument\n" + " starts with - or script is read from stdin\n" "\n" - " --ini Show configuration file names\n" + " --ini Show configuration file names\n" "\n" #if (HAVE_REFLECTION) - " --rf Show information about function .\n" - " --rc Show information about class .\n" - " --re Show information about extension .\n" - " --rz Show information about Zend extension .\n" + " --rf Show information about function .\n" + " --rc Show information about class .\n" + " --re Show information about extension .\n" + " --rz Show information about Zend extension .\n" #endif - " --ri Show configuration for extension .\n" + " --ri Show configuration for extension .\n" "\n" , prog, prog, prog, prog, prog, prog); } @@ -650,689 +656,718 @@ static int cli_seek_file_begin(zend_file_handle *file_handle, char *script_file, } /* }}} */ -/* {{{ main - */ -#ifdef PHP_CLI_WIN32_NO_CONSOLE -int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd) -#else -int main(int argc, char *argv[]) -#endif +static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ { - volatile int exit_status = SUCCESS; int c; zend_file_handle file_handle; -/* temporary locals */ - int behavior=PHP_MODE_STANDARD; + int behavior = PHP_MODE_STANDARD; char *reflection_what = NULL; - int orig_optind=php_optind; - char *orig_optarg=php_optarg; + volatile int request_started = 0; + volatile int exit_status = 0; + char *php_optarg = NULL, *orig_optarg = NULL; + int php_optind = 1, orig_optind = 1; + char *exec_direct=NULL, *exec_run=NULL, *exec_begin=NULL, *exec_end=NULL; char *arg_free=NULL, **arg_excp=&arg_free; char *script_file=NULL; int interactive=0; - volatile int module_started = 0; - volatile int request_started = 0; int lineno = 0; - char *exec_direct=NULL, *exec_run=NULL, *exec_begin=NULL, *exec_end=NULL; const char *param_error=NULL; int hide_argv = 0; -/* end of temporary locals */ -#ifdef ZTS - void ***tsrm_ls; -#endif -#ifdef PHP_CLI_WIN32_NO_CONSOLE - int argc = __argc; - char **argv = __argv; -#endif - int ini_entries_len = 0; - -#if defined(PHP_WIN32) && defined(_DEBUG) && defined(PHP_WIN32_DEBUG_HEAP) - { - int tmp_flag; - _CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE); - _CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR); - _CrtSetReportMode(_CRT_ERROR, _CRTDBG_MODE_FILE); - _CrtSetReportFile(_CRT_ERROR, _CRTDBG_FILE_STDERR); - _CrtSetReportMode(_CRT_ASSERT, _CRTDBG_MODE_FILE); - _CrtSetReportFile(_CRT_ASSERT, _CRTDBG_FILE_STDERR); - tmp_flag = _CrtSetDbgFlag(_CRTDBG_REPORT_FLAG); - tmp_flag |= _CRTDBG_DELAY_FREE_MEM_DF; - tmp_flag |= _CRTDBG_LEAK_CHECK_DF; - _CrtSetDbgFlag(tmp_flag); - } -#endif + CG(in_compilation) = 0; /* not initialized but needed for several options */ + EG(uninitialized_zval_ptr) = NULL; -#ifdef HAVE_SIGNAL_H -#if defined(SIGPIPE) && defined(SIG_IGN) - signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so - that sockets created via fsockopen() - don't kill PHP if the remote site - closes it. in apache|apxs mode apache - does that for us! thies@thieso.net - 20000419 */ -#endif -#endif - - -#ifdef ZTS - tsrm_startup(1, 1, 0, NULL); - tsrm_ls = ts_resource(0); -#endif - - cli_sapi_module.ini_defaults = sapi_cli_ini_defaults; - cli_sapi_module.php_ini_path_override = NULL; - cli_sapi_module.phpinfo_as_text = 1; - cli_sapi_module.php_ini_ignore_cwd = 1; - sapi_startup(&cli_sapi_module); - -#ifdef PHP_WIN32 - _fmode = _O_BINARY; /*sets default for file streams to binary */ - setmode(_fileno(stdin), O_BINARY); /* make the stdio mode be binary */ - setmode(_fileno(stdout), O_BINARY); /* make the stdio mode be binary */ - setmode(_fileno(stderr), O_BINARY); /* make the stdio mode be binary */ -#endif - - ini_entries_len = sizeof(HARDCODED_INI)-2; - cli_sapi_module.ini_entries = malloc(sizeof(HARDCODED_INI)); - memcpy(cli_sapi_module.ini_entries, HARDCODED_INI, sizeof(HARDCODED_INI)); - - while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2))!=-1) { + while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { switch (c) { - case 'c': - if (cli_sapi_module.php_ini_path_override) { - free(cli_sapi_module.php_ini_path_override); - } - cli_sapi_module.php_ini_path_override = strdup(php_optarg); - break; - case 'n': - cli_sapi_module.php_ini_ignore = 1; - break; - case 'd': { - /* define ini entries on command line */ - int len = strlen(php_optarg); - char *val; - if ((val = strchr(php_optarg, '='))) { - val++; - if (!isalnum(*val) && *val != '"' && *val != '\'' && *val != '\0') { - cli_sapi_module.ini_entries = realloc(cli_sapi_module.ini_entries, ini_entries_len + len + sizeof("\"\"\n\0")); - memcpy(cli_sapi_module.ini_entries + ini_entries_len, php_optarg, (val - php_optarg)); - ini_entries_len += (val - php_optarg); - memcpy(cli_sapi_module.ini_entries + ini_entries_len, "\"", 1); - ini_entries_len++; - memcpy(cli_sapi_module.ini_entries + ini_entries_len, val, len - (val - php_optarg)); - ini_entries_len += len - (val - php_optarg); - memcpy(cli_sapi_module.ini_entries + ini_entries_len, "\"\n\0", sizeof("\"\n\0")); - ini_entries_len += sizeof("\n\0\"") - 2; - } else { - cli_sapi_module.ini_entries = realloc(cli_sapi_module.ini_entries, ini_entries_len + len + sizeof("\n\0")); - memcpy(cli_sapi_module.ini_entries + ini_entries_len, php_optarg, len); - memcpy(cli_sapi_module.ini_entries + ini_entries_len + len, "\n\0", sizeof("\n\0")); - ini_entries_len += len + sizeof("\n\0") - 2; - } - } else { - cli_sapi_module.ini_entries = realloc(cli_sapi_module.ini_entries, ini_entries_len + len + sizeof("=1\n\0")); - memcpy(cli_sapi_module.ini_entries + ini_entries_len, php_optarg, len); - memcpy(cli_sapi_module.ini_entries + ini_entries_len + len, "=1\n\0", sizeof("=1\n\0")); - ini_entries_len += len + sizeof("=1\n\0") - 2; - } - break; + case 'i': /* php info & quit */ + if (php_request_startup(TSRMLS_C)==FAILURE) { + goto err; } - } - } - php_optind = orig_optind; - php_optarg = orig_optarg; - - cli_sapi_module.executable_location = argv[0]; - cli_sapi_module.additional_functions = additional_functions; - - /* startup after we get the above ini override se we get things right */ - if (cli_sapi_module.startup(&cli_sapi_module)==FAILURE) { - /* there is no way to see if we must call zend_ini_deactivate() - * since we cannot check if EG(ini_directives) has been initialised - * because the executor's constructor does not set initialize it. - * Apart from that there seems no need for zend_ini_deactivate() yet. - * So we goto out_err.*/ - exit_status = 1; - goto out_err; - } - module_started = 1; - - zend_first_try { - CG(in_compilation) = 0; /* not initialized but needed for several options */ - EG(uninitialized_zval_ptr) = NULL; - - while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { - switch (c) { - - case 'h': /* help & quit */ - case '?': - if (php_request_startup(TSRMLS_C)==FAILURE) { - goto err; - } - request_started = 1; - php_cli_usage(argv[0]); - php_output_end_all(TSRMLS_C); - exit_status = (c == '?' && argc > 1 && !strchr(argv[1], c)); - goto out; - - case 'i': /* php info & quit */ - if (php_request_startup(TSRMLS_C)==FAILURE) { - goto err; - } - request_started = 1; - php_print_info(0xFFFFFFFF TSRMLS_CC); - php_output_end_all(TSRMLS_C); - exit_status=0; - goto out; - - case 'm': /* list compiled in modules */ - if (php_request_startup(TSRMLS_C)==FAILURE) { - goto err; - } - request_started = 1; - php_printf("[PHP Modules]\n"); - print_modules(TSRMLS_C); - php_printf("\n[Zend Modules]\n"); - print_extensions(TSRMLS_C); - php_printf("\n"); - php_output_end_all(TSRMLS_C); - exit_status=0; - goto out; - - case 'v': /* show php version & quit */ - if (php_request_startup(TSRMLS_C) == FAILURE) { - goto err; - } + request_started = 1; + php_print_info(0xFFFFFFFF TSRMLS_CC); + php_output_end_all(TSRMLS_C); + exit_status = (c == '?' && argc > 1 && !strchr(argv[1], c)); + goto out; - request_started = 1; - php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2011 The PHP Group\n%s", - PHP_VERSION, sapi_module.name, __DATE__, __TIME__, + case 'v': /* show php version & quit */ + php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2011 The PHP Group\n%s", + PHP_VERSION, cli_sapi_module.name, __DATE__, __TIME__, #if ZEND_DEBUG && defined(HAVE_GCOV) - "(DEBUG GCOV)", + "(DEBUG GCOV)", #elif ZEND_DEBUG - "(DEBUG)", + "(DEBUG)", #elif defined(HAVE_GCOV) - "(GCOV)", + "(GCOV)", #else - "", + "", #endif - get_zend_version() - ); - php_output_end_all(TSRMLS_C); - exit_status=0; - goto out; + get_zend_version() + ); + goto out; - default: - break; + case 'm': /* list compiled in modules */ + if (php_request_startup(TSRMLS_C)==FAILURE) { + goto err; } - } + request_started = 1; + php_printf("[PHP Modules]\n"); + print_modules(TSRMLS_C); + php_printf("\n[Zend Modules]\n"); + print_extensions(TSRMLS_C); + php_printf("\n"); + php_output_end_all(TSRMLS_C); + exit_status=0; + goto out; - /* Set some CLI defaults */ - SG(options) |= SAPI_OPTION_NO_CHDIR; + default: + break; + } + } - php_optind = orig_optind; - php_optarg = orig_optarg; - while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { - switch (c) { + /* Set some CLI defaults */ + SG(options) |= SAPI_OPTION_NO_CHDIR; - case 'a': /* interactive mode */ - if (!interactive) { - if (behavior != PHP_MODE_STANDARD) { - param_error = param_mode_conflict; - break; - } + php_optind = orig_optind; + php_optarg = orig_optarg; + while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { + switch (c) { - interactive=1; + case 'a': /* interactive mode */ + if (!interactive) { + if (behavior != PHP_MODE_STANDARD) { + param_error = param_mode_conflict; + break; } - break; - case 'C': /* don't chdir to the script directory */ - /* This is default so NOP */ - break; + interactive=1; + } + break; - case 'e': /* enable extended info output */ - CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; - break; + case 'C': /* don't chdir to the script directory */ + /* This is default so NOP */ + break; - case 'F': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_run || script_file) { - param_error = "You can use -R or -F only once.\n"; - break; - } - } else if (behavior != PHP_MODE_STANDARD) { - param_error = param_mode_conflict; + case 'F': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_run || script_file) { + param_error = "You can use -R or -F only once.\n"; break; } - behavior=PHP_MODE_PROCESS_STDIN; - script_file = php_optarg; + } else if (behavior != PHP_MODE_STANDARD) { + param_error = param_mode_conflict; break; + } + behavior=PHP_MODE_PROCESS_STDIN; + script_file = php_optarg; + break; - case 'f': /* parse file */ - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = param_mode_conflict; - break; - } else if (script_file) { - param_error = "You can use -f only once.\n"; - break; - } - script_file = php_optarg; + case 'f': /* parse file */ + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = param_mode_conflict; break; + } else if (script_file) { + param_error = "You can use -f only once.\n"; + break; + } + script_file = php_optarg; + break; - case 'l': /* syntax check mode */ - if (behavior != PHP_MODE_STANDARD) { - break; - } - behavior=PHP_MODE_LINT; + case 'l': /* syntax check mode */ + if (behavior != PHP_MODE_STANDARD) { break; + } + behavior=PHP_MODE_LINT; + break; #if 0 /* not yet operational, see also below ... */ - case '': /* generate indented source mode*/ - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = "Source indenting only works for files.\n"; - break; - } - behavior=PHP_MODE_INDENT; + case '': /* generate indented source mode*/ + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = "Source indenting only works for files.\n"; break; + } + behavior=PHP_MODE_INDENT; + break; #endif - case 'q': /* do not generate HTTP headers */ - /* This is default so NOP */ - break; + case 'q': /* do not generate HTTP headers */ + /* This is default so NOP */ + break; - case 'r': /* run code from command line */ - if (behavior == PHP_MODE_CLI_DIRECT) { - if (exec_direct || script_file) { - param_error = "You can use -r only once.\n"; - break; - } - } else if (behavior != PHP_MODE_STANDARD || interactive) { - param_error = param_mode_conflict; + case 'r': /* run code from command line */ + if (behavior == PHP_MODE_CLI_DIRECT) { + if (exec_direct || script_file) { + param_error = "You can use -r only once.\n"; break; } - behavior=PHP_MODE_CLI_DIRECT; - exec_direct=php_optarg; + } else if (behavior != PHP_MODE_STANDARD || interactive) { + param_error = param_mode_conflict; break; - - case 'R': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_run || script_file) { - param_error = "You can use -R or -F only once.\n"; - break; - } - } else if (behavior != PHP_MODE_STANDARD) { - param_error = param_mode_conflict; + } + behavior=PHP_MODE_CLI_DIRECT; + exec_direct=php_optarg; + break; + + case 'R': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_run || script_file) { + param_error = "You can use -R or -F only once.\n"; break; } - behavior=PHP_MODE_PROCESS_STDIN; - exec_run=php_optarg; + } else if (behavior != PHP_MODE_STANDARD) { + param_error = param_mode_conflict; break; + } + behavior=PHP_MODE_PROCESS_STDIN; + exec_run=php_optarg; + break; - case 'B': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_begin) { - param_error = "You can use -B only once.\n"; - break; - } - } else if (behavior != PHP_MODE_STANDARD || interactive) { - param_error = param_mode_conflict; + case 'B': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_begin) { + param_error = "You can use -B only once.\n"; break; } - behavior=PHP_MODE_PROCESS_STDIN; - exec_begin=php_optarg; + } else if (behavior != PHP_MODE_STANDARD || interactive) { + param_error = param_mode_conflict; break; + } + behavior=PHP_MODE_PROCESS_STDIN; + exec_begin=php_optarg; + break; - case 'E': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_end) { - param_error = "You can use -E only once.\n"; - break; - } - } else if (behavior != PHP_MODE_STANDARD || interactive) { - param_error = param_mode_conflict; + case 'E': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_end) { + param_error = "You can use -E only once.\n"; break; } - behavior=PHP_MODE_PROCESS_STDIN; - exec_end=php_optarg; + } else if (behavior != PHP_MODE_STANDARD || interactive) { + param_error = param_mode_conflict; break; + } + behavior=PHP_MODE_PROCESS_STDIN; + exec_end=php_optarg; + break; - case 's': /* generate highlighted HTML from source */ - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = "Source highlighting only works for files.\n"; - break; - } - behavior=PHP_MODE_HIGHLIGHT; + case 's': /* generate highlighted HTML from source */ + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = "Source highlighting only works for files.\n"; break; + } + behavior=PHP_MODE_HIGHLIGHT; + break; - case 'w': - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = "Source stripping only works for files.\n"; - break; - } - behavior=PHP_MODE_STRIP; + case 'w': + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = "Source stripping only works for files.\n"; break; + } + behavior=PHP_MODE_STRIP; + break; - case 'z': /* load extension file */ - zend_load_extension(php_optarg); - break; - case 'H': - hide_argv = 1; - break; + case 'z': /* load extension file */ + zend_load_extension(php_optarg); + break; + case 'H': + hide_argv = 1; + break; #ifdef HAVE_REFLECTION - case 10: - behavior=PHP_MODE_REFLECTION_FUNCTION; - reflection_what = php_optarg; - break; - case 11: - behavior=PHP_MODE_REFLECTION_CLASS; - reflection_what = php_optarg; - break; - case 12: - behavior=PHP_MODE_REFLECTION_EXTENSION; - reflection_what = php_optarg; - break; - case 13: - behavior=PHP_MODE_REFLECTION_ZEND_EXTENSION; - reflection_what = php_optarg; - break; + case 10: + behavior=PHP_MODE_REFLECTION_FUNCTION; + reflection_what = php_optarg; + break; + case 11: + behavior=PHP_MODE_REFLECTION_CLASS; + reflection_what = php_optarg; + break; + case 12: + behavior=PHP_MODE_REFLECTION_EXTENSION; + reflection_what = php_optarg; + break; + case 13: + behavior=PHP_MODE_REFLECTION_ZEND_EXTENSION; + reflection_what = php_optarg; + break; #endif - case 14: - behavior=PHP_MODE_REFLECTION_EXT_INFO; - reflection_what = php_optarg; - break; - case 15: - behavior = PHP_MODE_SHOW_INI_CONFIG; - break; - default: - break; - } + case 14: + behavior=PHP_MODE_REFLECTION_EXT_INFO; + reflection_what = php_optarg; + break; + case 15: + behavior = PHP_MODE_SHOW_INI_CONFIG; + break; + default: + break; } + } - if (param_error) { - PUTS(param_error); - exit_status=1; - goto err; - } + if (param_error) { + PUTS(param_error); + exit_status=1; + goto err; + } - if (interactive) { + if (interactive) { #if (HAVE_LIBREADLINE || HAVE_LIBEDIT) && !defined(COMPILE_DL_READLINE) - printf("Interactive shell\n\n"); + printf("Interactive shell\n\n"); #else - printf("Interactive mode enabled\n\n"); + printf("Interactive mode enabled\n\n"); #endif - fflush(stdout); - } + fflush(stdout); + } - CG(interactive) = interactive; + CG(interactive) = interactive; - /* only set script_file if not set already and not in direct mode and not at end of parameter list */ - if (argc > php_optind - && !script_file - && behavior!=PHP_MODE_CLI_DIRECT - && behavior!=PHP_MODE_PROCESS_STDIN - && strcmp(argv[php_optind-1],"--")) - { - script_file=argv[php_optind]; - php_optind++; - } - if (script_file) { - if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { - goto err; - } - script_filename = script_file; - } else { - /* We could handle PHP_MODE_PROCESS_STDIN in a different manner */ - /* here but this would make things only more complicated. And it */ - /* is consitent with the way -R works where the stdin file handle*/ - /* is also accessible. */ - file_handle.filename = "-"; - file_handle.handle.fp = stdin; - } - file_handle.type = ZEND_HANDLE_FP; - file_handle.opened_path = NULL; - file_handle.free_filename = 0; - php_self = file_handle.filename; - - /* before registering argv to module exchange the *new* argv[0] */ - /* we can achieve this without allocating more memory */ - SG(request_info).argc=argc-php_optind+1; - arg_excp = argv+php_optind-1; - arg_free = argv[php_optind-1]; - SG(request_info).path_translated = file_handle.filename; - argv[php_optind-1] = file_handle.filename; - SG(request_info).argv=argv+php_optind-1; - - if (php_request_startup(TSRMLS_C)==FAILURE) { - *arg_excp = arg_free; - fclose(file_handle.handle.fp); - PUTS("Could not startup.\n"); + /* only set script_file if not set already and not in direct mode and not at end of parameter list */ + if (argc > php_optind + && !script_file + && behavior!=PHP_MODE_CLI_DIRECT + && behavior!=PHP_MODE_PROCESS_STDIN + && strcmp(argv[php_optind-1],"--")) + { + script_file=argv[php_optind]; + php_optind++; + } + if (script_file) { + if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { goto err; } - request_started = 1; - CG(start_lineno) = lineno; - *arg_excp = arg_free; /* reconstuct argv */ - - if (hide_argv) { - int i; - for (i = 1; i < argc; i++) { - memset(argv[i], 0, strlen(argv[i])); - } + script_filename = script_file; + } else { + /* We could handle PHP_MODE_PROCESS_STDIN in a different manner */ + /* here but this would make things only more complicated. And it */ + /* is consitent with the way -R works where the stdin file handle*/ + /* is also accessible. */ + file_handle.filename = "-"; + file_handle.handle.fp = stdin; + } + file_handle.type = ZEND_HANDLE_FP; + file_handle.opened_path = NULL; + file_handle.free_filename = 0; + php_self = file_handle.filename; + + /* before registering argv to module exchange the *new* argv[0] */ + /* we can achieve this without allocating more memory */ + SG(request_info).argc=argc-php_optind+1; + arg_excp = argv+php_optind-1; + arg_free = argv[php_optind-1]; + SG(request_info).path_translated = file_handle.filename; + argv[php_optind-1] = file_handle.filename; + SG(request_info).argv=argv+php_optind-1; + + if (php_request_startup(TSRMLS_C)==FAILURE) { + *arg_excp = arg_free; + fclose(file_handle.handle.fp); + PUTS("Could not startup.\n"); + goto err; + } + request_started = 1; + CG(start_lineno) = lineno; + *arg_excp = arg_free; /* reconstuct argv */ + + if (hide_argv) { + int i; + for (i = 1; i < argc; i++) { + memset(argv[i], 0, strlen(argv[i])); } + } - zend_is_auto_global("_SERVER", sizeof("_SERVER")-1 TSRMLS_CC); + zend_is_auto_global("_SERVER", sizeof("_SERVER")-1 TSRMLS_CC); - PG(during_request_startup) = 0; - switch (behavior) { - case PHP_MODE_STANDARD: - if (strcmp(file_handle.filename, "-")) { - cli_register_file_handles(TSRMLS_C); - } + PG(during_request_startup) = 0; + switch (behavior) { + case PHP_MODE_STANDARD: + if (strcmp(file_handle.filename, "-")) { + cli_register_file_handles(TSRMLS_C); + } - if (interactive && cli_shell_callbacks.cli_shell_run) { - exit_status = cli_shell_callbacks.cli_shell_run(TSRMLS_C); - } else { - php_execute_script(&file_handle TSRMLS_CC); - exit_status = EG(exit_status); - } + if (interactive && cli_shell_callbacks.cli_shell_run) { + exit_status = cli_shell_callbacks.cli_shell_run(TSRMLS_C); + } else { + php_execute_script(&file_handle TSRMLS_CC); + exit_status = EG(exit_status); + } + break; + case PHP_MODE_LINT: + exit_status = php_lint_script(&file_handle TSRMLS_CC); + if (exit_status==SUCCESS) { + zend_printf("No syntax errors detected in %s\n", file_handle.filename); + } else { + zend_printf("Errors parsing %s\n", file_handle.filename); + } + break; + case PHP_MODE_STRIP: + if (open_file_for_scanning(&file_handle TSRMLS_CC)==SUCCESS) { + zend_strip(TSRMLS_C); + } + goto out; + break; + case PHP_MODE_HIGHLIGHT: + { + zend_syntax_highlighter_ini syntax_highlighter_ini; - break; - case PHP_MODE_LINT: - exit_status = php_lint_script(&file_handle TSRMLS_CC); - if (exit_status==SUCCESS) { - zend_printf("No syntax errors detected in %s\n", file_handle.filename); - } else { - zend_printf("Errors parsing %s\n", file_handle.filename); - } - break; - case PHP_MODE_STRIP: if (open_file_for_scanning(&file_handle TSRMLS_CC)==SUCCESS) { - zend_strip(TSRMLS_C); + php_get_highlight_struct(&syntax_highlighter_ini); + zend_highlight(&syntax_highlighter_ini TSRMLS_CC); } goto out; - break; - case PHP_MODE_HIGHLIGHT: - { - zend_syntax_highlighter_ini syntax_highlighter_ini; - - if (open_file_for_scanning(&file_handle TSRMLS_CC)==SUCCESS) { - php_get_highlight_struct(&syntax_highlighter_ini); - zend_highlight(&syntax_highlighter_ini TSRMLS_CC); - } - goto out; - } - break; + } + break; #if 0 - /* Zeev might want to do something with this one day */ - case PHP_MODE_INDENT: - open_file_for_scanning(&file_handle TSRMLS_CC); - zend_indent(); - zend_file_handle_dtor(file_handle.handle TSRMLS_CC); - goto out; - break; + /* Zeev might want to do something with this one day */ + case PHP_MODE_INDENT: + open_file_for_scanning(&file_handle TSRMLS_CC); + zend_indent(); + zend_file_handle_dtor(file_handle.handle TSRMLS_CC); + goto out; + break; #endif - case PHP_MODE_CLI_DIRECT: + case PHP_MODE_CLI_DIRECT: + cli_register_file_handles(TSRMLS_C); + if (zend_eval_string_ex(exec_direct, NULL, "Command line code", 1 TSRMLS_CC) == FAILURE) { + exit_status=254; + } + break; + + case PHP_MODE_PROCESS_STDIN: + { + char *input; + size_t len, index = 0; + zval *argn, *argi; + cli_register_file_handles(TSRMLS_C); - if (zend_eval_string_ex(exec_direct, NULL, "Command line code", 1 TSRMLS_CC) == FAILURE) { + + if (exec_begin && zend_eval_string_ex(exec_begin, NULL, "Command line begin code", 1 TSRMLS_CC) == FAILURE) { exit_status=254; } - break; - - case PHP_MODE_PROCESS_STDIN: - { - char *input; - size_t len, index = 0; - zval *argn, *argi; - - cli_register_file_handles(TSRMLS_C); - - if (exec_begin && zend_eval_string_ex(exec_begin, NULL, "Command line begin code", 1 TSRMLS_CC) == FAILURE) { - exit_status=254; + ALLOC_ZVAL(argi); + Z_TYPE_P(argi) = IS_LONG; + Z_LVAL_P(argi) = index; + INIT_PZVAL(argi); + zend_hash_update(&EG(symbol_table), "argi", sizeof("argi"), &argi, sizeof(zval *), NULL); + while (exit_status == SUCCESS && (input=php_stream_gets(s_in_process, NULL, 0)) != NULL) { + len = strlen(input); + while (len-- && (input[len]=='\n' || input[len]=='\r')) { + input[len] = '\0'; } - ALLOC_ZVAL(argi); - Z_TYPE_P(argi) = IS_LONG; - Z_LVAL_P(argi) = index; - INIT_PZVAL(argi); - zend_hash_update(&EG(symbol_table), "argi", sizeof("argi"), &argi, sizeof(zval *), NULL); - while (exit_status == SUCCESS && (input=php_stream_gets(s_in_process, NULL, 0)) != NULL) { - len = strlen(input); - while (len-- && (input[len]=='\n' || input[len]=='\r')) { - input[len] = '\0'; + ALLOC_ZVAL(argn); + Z_TYPE_P(argn) = IS_STRING; + Z_STRLEN_P(argn) = ++len; + Z_STRVAL_P(argn) = estrndup(input, len); + INIT_PZVAL(argn); + zend_hash_update(&EG(symbol_table), "argn", sizeof("argn"), &argn, sizeof(zval *), NULL); + Z_LVAL_P(argi) = ++index; + if (exec_run) { + if (zend_eval_string_ex(exec_run, NULL, "Command line run code", 1 TSRMLS_CC) == FAILURE) { + exit_status=254; } - ALLOC_ZVAL(argn); - Z_TYPE_P(argn) = IS_STRING; - Z_STRLEN_P(argn) = ++len; - Z_STRVAL_P(argn) = estrndup(input, len); - INIT_PZVAL(argn); - zend_hash_update(&EG(symbol_table), "argn", sizeof("argn"), &argn, sizeof(zval *), NULL); - Z_LVAL_P(argi) = ++index; - if (exec_run) { - if (zend_eval_string_ex(exec_run, NULL, "Command line run code", 1 TSRMLS_CC) == FAILURE) { - exit_status=254; - } - } else { - if (script_file) { - if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { - exit_status = 1; - } else { - CG(start_lineno) = lineno; - php_execute_script(&file_handle TSRMLS_CC); - exit_status = EG(exit_status); - } + } else { + if (script_file) { + if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { + exit_status = 1; + } else { + CG(start_lineno) = lineno; + php_execute_script(&file_handle TSRMLS_CC); + exit_status = EG(exit_status); } } - efree(input); } - if (exec_end && zend_eval_string_ex(exec_end, NULL, "Command line end code", 1 TSRMLS_CC) == FAILURE) { - exit_status=254; + efree(input); + } + if (exec_end && zend_eval_string_ex(exec_end, NULL, "Command line end code", 1 TSRMLS_CC) == FAILURE) { + exit_status=254; + } + + break; + } +#ifdef HAVE_REFLECTION + case PHP_MODE_REFLECTION_FUNCTION: + case PHP_MODE_REFLECTION_CLASS: + case PHP_MODE_REFLECTION_EXTENSION: + case PHP_MODE_REFLECTION_ZEND_EXTENSION: + { + zend_class_entry *pce = NULL; + zval *arg, *ref; + zend_execute_data execute_data; + + switch (behavior) { + default: + break; + case PHP_MODE_REFLECTION_FUNCTION: + if (strstr(reflection_what, "::")) { + pce = reflection_method_ptr; + } else { + pce = reflection_function_ptr; + } + break; + case PHP_MODE_REFLECTION_CLASS: + pce = reflection_class_ptr; + break; + case PHP_MODE_REFLECTION_EXTENSION: + pce = reflection_extension_ptr; + break; + case PHP_MODE_REFLECTION_ZEND_EXTENSION: + pce = reflection_zend_extension_ptr; + break; + } + + MAKE_STD_ZVAL(arg); + ZVAL_STRING(arg, reflection_what, 1); + ALLOC_ZVAL(ref); + object_init_ex(ref, pce); + INIT_PZVAL(ref); + + memset(&execute_data, 0, sizeof(zend_execute_data)); + EG(current_execute_data) = &execute_data; + EX(function_state).function = pce->constructor; + zend_call_method_with_1_params(&ref, pce, &pce->constructor, "__construct", NULL, arg); + + if (EG(exception)) { + zval *msg = zend_read_property(zend_exception_get_default(TSRMLS_C), EG(exception), "message", sizeof("message")-1, 0 TSRMLS_CC); + zend_printf("Exception: %s\n", Z_STRVAL_P(msg)); + zval_ptr_dtor(&EG(exception)); + EG(exception) = NULL; + } else { + zend_call_method_with_1_params(NULL, reflection_ptr, NULL, "export", NULL, ref); } + zval_ptr_dtor(&ref); + zval_ptr_dtor(&arg); break; } -#ifdef HAVE_REFLECTION - case PHP_MODE_REFLECTION_FUNCTION: - case PHP_MODE_REFLECTION_CLASS: - case PHP_MODE_REFLECTION_EXTENSION: - case PHP_MODE_REFLECTION_ZEND_EXTENSION: - { - zend_class_entry *pce = NULL; - zval *arg, *ref; - zend_execute_data execute_data; - - switch (behavior) { - default: - break; - case PHP_MODE_REFLECTION_FUNCTION: - if (strstr(reflection_what, "::")) { - pce = reflection_method_ptr; - } else { - pce = reflection_function_ptr; - } - break; - case PHP_MODE_REFLECTION_CLASS: - pce = reflection_class_ptr; - break; - case PHP_MODE_REFLECTION_EXTENSION: - pce = reflection_extension_ptr; - break; - case PHP_MODE_REFLECTION_ZEND_EXTENSION: - pce = reflection_zend_extension_ptr; - break; - } - - MAKE_STD_ZVAL(arg); - ZVAL_STRING(arg, reflection_what, 1); - ALLOC_ZVAL(ref); - object_init_ex(ref, pce); - INIT_PZVAL(ref); - - memset(&execute_data, 0, sizeof(zend_execute_data)); - EG(current_execute_data) = &execute_data; - EX(function_state).function = pce->constructor; - zend_call_method_with_1_params(&ref, pce, &pce->constructor, "__construct", NULL, arg); - - if (EG(exception)) { - zval *msg = zend_read_property(zend_exception_get_default(TSRMLS_C), EG(exception), "message", sizeof("message")-1, 0 TSRMLS_CC); - zend_printf("Exception: %s\n", Z_STRVAL_P(msg)); - zval_ptr_dtor(&EG(exception)); - EG(exception) = NULL; +#endif /* reflection */ + case PHP_MODE_REFLECTION_EXT_INFO: + { + int len = strlen(reflection_what); + char *lcname = zend_str_tolower_dup(reflection_what, len); + zend_module_entry *module; + + if (zend_hash_find(&module_registry, lcname, len+1, (void**)&module) == FAILURE) { + if (!strcmp(reflection_what, "main")) { + display_ini_entries(NULL); } else { - zend_call_method_with_1_params(NULL, reflection_ptr, NULL, "export", NULL, ref); + zend_printf("Extension '%s' not present.\n", reflection_what); + exit_status = 1; } - zval_ptr_dtor(&ref); - zval_ptr_dtor(&arg); + } else { + php_info_print_module(module TSRMLS_CC); + } + + efree(lcname); + break; + } + case PHP_MODE_SHOW_INI_CONFIG: + { + zend_printf("Configuration File (php.ini) Path: %s\n", PHP_CONFIG_FILE_PATH); + zend_printf("Loaded Configuration File: %s\n", php_ini_opened_path ? php_ini_opened_path : "(none)"); + zend_printf("Scan for additional .ini files in: %s\n", php_ini_scanned_path ? php_ini_scanned_path : "(none)"); + zend_printf("Additional .ini files parsed: %s\n", php_ini_scanned_files ? php_ini_scanned_files : "(none)"); + break; + } + } - break; +out: + if (exit_status == 0) { + exit_status = EG(exit_status); + } + if (request_started) { + php_request_shutdown((void *) 0); + } + return exit_status; +err: + sapi_deactivate(TSRMLS_C); + zend_ini_deactivate(TSRMLS_C); + exit_status = 1; + goto out; +} +/* }}} */ + +/* {{{ main + */ +#ifdef PHP_CLI_WIN32_NO_CONSOLE +int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd) +#else +int main(int argc, char *argv[]) +#endif +{ +#ifdef ZTS + void ***tsrm_ls; +#endif +#ifdef PHP_CLI_WIN32_NO_CONSOLE + int argc = __argc; + char **argv = __argv; +#endif + int c; + int exit_status = SUCCESS; + int module_started = 0; + char *php_optarg = NULL; + int php_optind = 1; + char *ini_path_override = NULL; + char *ini_entries = NULL; + int ini_entries_len = 0; + int ini_ignore = 0; + sapi_module_struct *sapi_module = &cli_sapi_module; + + cli_sapi_module.additional_functions = additional_functions; + +#if defined(PHP_WIN32) && defined(_DEBUG) && defined(PHP_WIN32_DEBUG_HEAP) + { + int tmp_flag; + _CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE); + _CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR); + _CrtSetReportMode(_CRT_ERROR, _CRTDBG_MODE_FILE); + _CrtSetReportFile(_CRT_ERROR, _CRTDBG_FILE_STDERR); + _CrtSetReportMode(_CRT_ASSERT, _CRTDBG_MODE_FILE); + _CrtSetReportFile(_CRT_ASSERT, _CRTDBG_FILE_STDERR); + tmp_flag = _CrtSetDbgFlag(_CRTDBG_REPORT_FLAG); + tmp_flag |= _CRTDBG_DELAY_FREE_MEM_DF; + tmp_flag |= _CRTDBG_LEAK_CHECK_DF; + + _CrtSetDbgFlag(tmp_flag); + } +#endif + +#ifdef HAVE_SIGNAL_H +#if defined(SIGPIPE) && defined(SIG_IGN) + signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so + that sockets created via fsockopen() + don't kill PHP if the remote site + closes it. in apache|apxs mode apache + does that for us! thies@thieso.net + 20000419 */ +#endif +#endif + + +#ifdef ZTS + tsrm_startup(1, 1, 0, NULL); + tsrm_ls = ts_resource(0); +#endif + +#ifdef PHP_WIN32 + _fmode = _O_BINARY; /*sets default for file streams to binary */ + setmode(_fileno(stdin), O_BINARY); /* make the stdio mode be binary */ + setmode(_fileno(stdout), O_BINARY); /* make the stdio mode be binary */ + setmode(_fileno(stderr), O_BINARY); /* make the stdio mode be binary */ +#endif + + while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2))!=-1) { + switch (c) { + case 'c': + if (ini_path_override) { + free(ini_path_override); } -#endif /* reflection */ - case PHP_MODE_REFLECTION_EXT_INFO: - { - int len = strlen(reflection_what); - char *lcname = zend_str_tolower_dup(reflection_what, len); - zend_module_entry *module; - - if (zend_hash_find(&module_registry, lcname, len+1, (void**)&module) == FAILURE) { - if (!strcmp(reflection_what, "main")) { - display_ini_entries(NULL); - } else { - zend_printf("Extension '%s' not present.\n", reflection_what); - exit_status = 1; - } + ini_path_override = strdup(php_optarg); + break; + case 'n': + ini_ignore = 1; + break; + case 'd': { + /* define ini entries on command line */ + int len = strlen(php_optarg); + char *val; + + if ((val = strchr(php_optarg, '='))) { + val++; + if (!isalnum(*val) && *val != '"' && *val != '\'' && *val != '\0') { + ini_entries = realloc(ini_entries, ini_entries_len + len + sizeof("\"\"\n\0")); + memcpy(ini_entries + ini_entries_len, php_optarg, (val - php_optarg)); + ini_entries_len += (val - php_optarg); + memcpy(ini_entries + ini_entries_len, "\"", 1); + ini_entries_len++; + memcpy(ini_entries + ini_entries_len, val, len - (val - php_optarg)); + ini_entries_len += len - (val - php_optarg); + memcpy(ini_entries + ini_entries_len, "\"\n\0", sizeof("\"\n\0")); + ini_entries_len += sizeof("\n\0\"") - 2; } else { - php_info_print_module(module TSRMLS_CC); + ini_entries = realloc(ini_entries, ini_entries_len + len + sizeof("\n\0")); + memcpy(ini_entries + ini_entries_len, php_optarg, len); + memcpy(ini_entries + ini_entries_len + len, "\n\0", sizeof("\n\0")); + ini_entries_len += len + sizeof("\n\0") - 2; } - - efree(lcname); - break; - } - case PHP_MODE_SHOW_INI_CONFIG: - { - zend_printf("Configuration File (php.ini) Path: %s\n", PHP_CONFIG_FILE_PATH); - zend_printf("Loaded Configuration File: %s\n", php_ini_opened_path ? php_ini_opened_path : "(none)"); - zend_printf("Scan for additional .ini files in: %s\n", php_ini_scanned_path ? php_ini_scanned_path : "(none)"); - zend_printf("Additional .ini files parsed: %s\n", php_ini_scanned_files ? php_ini_scanned_files : "(none)"); - break; + } else { + ini_entries = realloc(ini_entries, ini_entries_len + len + sizeof("=1\n\0")); + memcpy(ini_entries + ini_entries_len, php_optarg, len); + memcpy(ini_entries + ini_entries_len + len, "=1\n\0", sizeof("=1\n\0")); + ini_entries_len += len + sizeof("=1\n\0") - 2; } + break; + } +#ifndef PHP_CLI_WIN32_NO_CONSOLE + case 'S': + sapi_module = &cli_server_sapi_module; + break; +#endif + case 'h': /* help & quit */ + case '?': + php_cli_usage(argv[0]); + goto out; + case 'i': case 'v': case 'm': + sapi_module = &cli_sapi_module; + goto exit_loop; + case 'e': /* enable extended info output */ + CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; + break; } + } +exit_loop: - } zend_end_try(); + sapi_module->ini_defaults = sapi_cli_ini_defaults; + sapi_module->php_ini_path_override = ini_path_override; + sapi_module->phpinfo_as_text = 1; + sapi_module->php_ini_ignore_cwd = 1; + sapi_startup(sapi_module); -out: - if (request_started) { - php_request_shutdown((void *) 0); + sapi_module->php_ini_ignore = ini_ignore; + + sapi_module->executable_location = argv[0]; + + if (sapi_module == &cli_sapi_module) { + if (ini_entries) { + ini_entries = realloc(ini_entries, ini_entries_len + sizeof(HARDCODED_INI)); + memmove(ini_entries, ini_entries + sizeof(HARDCODED_INI) - 2, ini_entries_len + 1); + memcpy(ini_entries, HARDCODED_INI, sizeof(HARDCODED_INI) - 2); + } else { + ini_entries = malloc(sizeof(HARDCODED_INI)); + memcpy(ini_entries, HARDCODED_INI, sizeof(HARDCODED_INI)); + } + ini_entries_len += sizeof(HARDCODED_INI) - 2; } - if (exit_status == 0) { - exit_status = EG(exit_status); + + sapi_module->ini_entries = ini_entries; + + /* startup after we get the above ini override se we get things right */ + if (sapi_module->startup(sapi_module) == FAILURE) { + /* there is no way to see if we must call zend_ini_deactivate() + * since we cannot check if EG(ini_directives) has been initialised + * because the executor's constructor does not set initialize it. + * Apart from that there seems no need for zend_ini_deactivate() yet. + * So we goto out_err.*/ + exit_status = 1; + goto out; } -out_err: - if (cli_sapi_module.php_ini_path_override) { - free(cli_sapi_module.php_ini_path_override); + module_started = 1; + + zend_first_try { +#ifndef PHP_CLI_WIN32_NO_CONSOLE + if (sapi_module == &cli_sapi_module) { +#endif + exit_status = do_cli(argc, argv TSRMLS_CC); +#ifndef PHP_CLI_WIN32_NO_CONSOLE + } else { + exit_status = do_cli_server(argc, argv TSRMLS_CC); + } +#endif + } zend_end_try(); +out: + if (ini_path_override) { + free(ini_path_override); } - if (cli_sapi_module.ini_entries) { - free(cli_sapi_module.ini_entries); + if (ini_entries) { + free(ini_entries); } - if (module_started) { php_module_shutdown(TSRMLS_C); } @@ -1342,12 +1377,6 @@ int main(int argc, char *argv[]) #endif exit(exit_status); - -err: - sapi_deactivate(TSRMLS_C); - zend_ini_deactivate(TSRMLS_C); - exit_status = 1; - goto out_err; } /* }}} */ diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c new file mode 100644 index 0000000000000..e644999f02cdd --- /dev/null +++ b/sapi/cli/php_cli_server.c @@ -0,0 +1,2084 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2011 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Moriyoshi Koizumi | + +----------------------------------------------------------------------+ +*/ + +/* $Id: php_cli.c 306938 2011-01-01 02:17:06Z felipe $ */ + +#include "php_config.h" + +#include +#include +#include + +#ifdef PHP_WIN32 +#include +#include +#include "win32/time.h" +#include "win32/signal.h" +#include "win32/php_registry.h" +#endif + +#ifdef __riscos__ +#include +#endif + + +#if HAVE_TIME_H +#include +#endif +#if HAVE_SYS_TIME_H +#include +#endif +#if HAVE_UNISTD_H +#include +#endif +#if HAVE_SIGNAL_H +#include +#endif +#if HAVE_SETLOCALE +#include +#endif +#if HAVE_DLFCN_H +#include +#endif + +#include "SAPI.h" +#include "php.h" +#include "php_ini.h" +#include "php_main.h" +#include "php_globals.h" +#include "php_variables.h" +#include "zend_hash.h" +#include "zend_modules.h" +#include "fopen_wrappers.h" + +#include "zend_compile.h" +#include "zend_execute.h" +#include "zend_highlight.h" +#include "zend_indent.h" +#include "zend_exceptions.h" + +#include "php_getopt.h" + +#ifndef PHP_WIN32 +# define php_select(m, r, w, e, t) select(m, r, w, e, t) +# define SOCK_EINVAL EINVAL +# define SOCK_EAGAIN EAGAIN +# define SOCK_EINTR EINTR +# define SOCK_EADDRINUSE EADDRINUSE +#else +# include "win32/select.h" +# define SOCK_EINVAL WSAEINVAL +# define SOCK_EAGAIN WSAEWOULDBLOCK +# define SOCK_EINTR WSAEINTR +# define SOCK_EADDRINUSE WSAEADDRINUSE +#endif + +#include "ext/standard/file.h" /* for php_set_sock_blocking() :-( */ +#include "ext/standard/php_smart_str.h" +#include "ext/standard/html.h" +#include "ext/standard/url.h" /* for php_url_decode() */ +#include "ext/standard/php_string.h" /* for php_dirname() */ +#include "ext/standard/info.h" /* for php_info_print_style() */ +#include "php_network.h" + +#include "php_http_parser.h" + +typedef struct php_cli_server_poller { + fd_set rfds, wfds; + struct { + fd_set rfds, wfds; + } active; + php_socket_t max_fd; +} php_cli_server_poller; + +typedef struct php_cli_server_request { + enum php_http_method request_method; + int protocol_version; + char *request_uri; + size_t request_uri_len; + char *vpath; + size_t vpath_len; + char *path_translated; + size_t path_translated_len; + char *path_info; + size_t path_info_len; + char *query_string; + size_t query_string_len; + HashTable headers; + char *content; + size_t content_len; + const char *ext; + size_t ext_len; + struct stat sb; +} php_cli_server_request; + +typedef struct php_cli_server_chunk { + struct php_cli_server_chunk *next; + enum php_cli_server_chunk_type { + PHP_CLI_SERVER_CHUNK_HEAP, + PHP_CLI_SERVER_CHUNK_IMMORTAL + } type; + union { + struct { void *block; char *p; size_t len; } heap; + struct { const char *p; size_t len; } immortal; + } data; +} php_cli_server_chunk; + +typedef struct php_cli_server_buffer { + php_cli_server_chunk *first; + php_cli_server_chunk *last; +} php_cli_server_buffer; + +typedef struct php_cli_server_content_sender { + php_cli_server_buffer buffer; +} php_cli_server_content_sender; + +typedef struct php_cli_server_client { + struct php_cli_server *server; + php_socket_t sock; + struct sockaddr *addr; + socklen_t addr_len; + char *addr_str; + size_t addr_str_len; + php_http_parser parser; + int request_read:1; + char *current_header_name; + size_t current_header_name_len; + int current_header_name_allocated:1; + size_t post_read_offset; + php_cli_server_request request; + int content_sender_initialized:1; + php_cli_server_content_sender content_sender; + php_cli_server_buffer capture_buffer; + int capturing:1; + int file_fd; +} php_cli_server_client; + +typedef struct php_cli_server { + php_socket_t server_sock; + php_cli_server_poller poller; + int is_running; + char *host; + int port; + int address_family; + char *document_root; + size_t document_root_len; + char *router; + size_t router_len; + socklen_t socklen; + HashTable clients; +} php_cli_server; + +typedef struct php_cli_server_http_reponse_status_code_pair { + int code; + const char *str; +} php_cli_server_http_reponse_status_code_pair; + +typedef struct php_cli_server_ext_mime_type_pair { + const char *ext; + const char *mime_type; +} php_cli_server_ext_mime_type_pair; + +static php_cli_server_http_reponse_status_code_pair status_map[] = { + { 100, "Continue" }, + { 101, "Switching Protocols" }, + { 200, "OK" }, + { 201, "Created" }, + { 202, "Accepted" }, + { 203, "Non-Authoritative Information" }, + { 204, "No Content" }, + { 205, "Reset Content" }, + { 206, "Partial Content" }, + { 300, "Multiple Choices" }, + { 301, "Moved Permanently" }, + { 302, "Found" }, + { 303, "See Other" }, + { 304, "Not Modified" }, + { 305, "Use Proxy" }, + { 307, "Temporary Redirect" }, + { 400, "Bad Request" }, + { 401, "Unauthorized" }, + { 402, "Payment Required" }, + { 403, "Forbidden" }, + { 404, "Not Found" }, + { 405, "Method Not Allowed" }, + { 406, "Not Acceptable" }, + { 407, "Proxy Authentication Required" }, + { 408, "Request Timeout" }, + { 409, "Conflict" }, + { 410, "Gone" }, + { 411, "Length Required" }, + { 412, "Precondition Failed" }, + { 413, "Request Entity Too Large" }, + { 414, "Request-URI Too Long" }, + { 415, "Unsupported Media Type" }, + { 416, "Requested Range Not Satisfiable" }, + { 417, "Expectation Failed" }, + { 500, "Internal Server Error" }, + { 501, "Not Implemented" }, + { 502, "Bad Gateway" }, + { 503, "Service Unavailable" }, + { 504, "Gateway Timeout" }, + { 505, "HTTP Version Not Supported" }, +}; + +static php_cli_server_http_reponse_status_code_pair template_map[] = { + { 404, "

%s

The requested resource %s was not found on this server.

" }, + { 500, "

%s

The server is temporality unavaiable.

" } +}; + +static php_cli_server_ext_mime_type_pair mime_type_map[] = { + { "gif", "image/gif" }, + { "png", "image/png" }, + { "jpe", "image/jpeg" }, + { "jpg", "image/jpeg" }, + { "jpeg", "image/jpeg" }, + { "css", "text/css" }, + { "html", "text/html" }, + { "txt", "text/plain" }, + { "js", "text/javascript" }, + { NULL, NULL } +}; + +static size_t php_cli_server_client_send_through(php_cli_server_client *client, const char *str, size_t str_len); +static php_cli_server_chunk *php_cli_server_chunk_heap_new_self_contained(size_t len); +static void php_cli_server_buffer_append(php_cli_server_buffer *buffer, php_cli_server_chunk *chunk); +static void php_cli_server_logf(const char *format TSRMLS_DC, ...); + +static void char_ptr_dtor_p(char **p) /* {{{ */ +{ + pefree(*p, 1); +} /* }}} */ + +static char *get_last_error() /* {{{ */ +{ + return pestrdup(strerror(errno), 1); +} /* }}} */ + +static const char *get_status_string(int code) /* {{{ */ +{ + size_t e = (sizeof(status_map) / sizeof(php_cli_server_http_reponse_status_code_pair)); + size_t s = 0; + + while (e != s) { + size_t c = MIN((e + s + 1) / 2, e - 1); + int d = status_map[c].code; + if (d > code) { + e = c; + } else if (d < code) { + s = c; + } else { + return status_map[c].str; + } + } + return NULL; +} /* }}} */ + +static const char *get_template_string(int code) /* {{{ */ +{ + size_t e = (sizeof(template_map) / sizeof(php_cli_server_http_reponse_status_code_pair)); + size_t s = 0; + + while (e != s) { + size_t c = MIN((e + s + 1) / 2, e - 1); + int d = template_map[c].code; + if (d > code) { + e = c; + } else if (d < code) { + s = c; + } else { + return template_map[c].str; + } + } + return NULL; +} /* }}} */ + +static void append_http_status_line(smart_str *buffer, int protocol_version, int response_code, int persistent) /* {{{ */ +{ + smart_str_appendl_ex(buffer, "HTTP", 4, persistent); + smart_str_appendc_ex(buffer, '/', persistent); + smart_str_append_generic_ex(buffer, protocol_version / 100, persistent, int, _unsigned); + smart_str_appendc_ex(buffer, '.', persistent); + smart_str_append_generic_ex(buffer, protocol_version % 100, persistent, int, _unsigned); + smart_str_appendc_ex(buffer, ' ', persistent); + smart_str_append_generic_ex(buffer, response_code, persistent, int, _unsigned); + smart_str_appendc_ex(buffer, ' ', persistent); + smart_str_appends_ex(buffer, get_status_string(response_code), persistent); + smart_str_appendl_ex(buffer, "\r\n", 2, persistent); +} /* }}} */ + +static void append_essential_headers(smart_str* buffer, php_cli_server_client *client, int persistent) /* {{{ */ +{ + { + char **val; + if (SUCCESS == zend_hash_find(&client->request.headers, "Host", sizeof("Host"), (void**)&val)) { + smart_str_appendl_ex(buffer, "Host", sizeof("Host") - 1, persistent); + smart_str_appendl_ex(buffer, ": ", sizeof(": ") - 1, persistent); + smart_str_appends_ex(buffer, *val, persistent); + smart_str_appendl_ex(buffer, "\r\n", 2, persistent); + } + } + smart_str_appendl_ex(buffer, "Connection: closed\r\n", sizeof("Connection: closed\r\n") - 1, persistent); +} /* }}} */ + +static const char *get_mime_type(const char *ext, size_t ext_len) /* {{{ */ +{ + php_cli_server_ext_mime_type_pair *pair; + for (pair = mime_type_map; pair->ext; pair++) { + size_t len = strlen(pair->ext); + if (len == ext_len && memcmp(pair->ext, ext, len) == 0) { + return pair->mime_type; + } + } + return NULL; +} /* }}} */ + +static int sapi_cli_server_startup(sapi_module_struct *sapi_module) /* {{{ */ +{ + if (php_module_startup(sapi_module, NULL, 0) == FAILURE) { + return FAILURE; + } + + return SUCCESS; +} /* }}} */ + +static int sapi_cli_server_ub_write(const char *str, uint str_length TSRMLS_DC) /* {{{ */ +{ + php_cli_server_client *client = SG(server_context); + if (client->capturing) { + php_cli_server_chunk *chunk = php_cli_server_chunk_heap_new_self_contained(str_length); + if (!chunk) { + zend_bailout(); + } + memmove(chunk->data.heap.p, str, str_length); + php_cli_server_buffer_append(&client->capture_buffer, chunk); + return str_length; + } else { + return php_cli_server_client_send_through(client, str, str_length); + } +} /* }}} */ + +static void sapi_cli_server_flush(void *server_context) /* {{{ */ +{ + php_cli_server_client *client = server_context; + TSRMLS_FETCH(); + + if (!client) { + return; + } + + if (client->sock < 0) { + php_handle_aborted_connection(); + return; + } + + if (!SG(headers_sent)) { + sapi_send_headers(TSRMLS_C); + SG(headers_sent) = 1; + } +} /* }}} */ + +static int sapi_cli_server_send_headers(sapi_headers_struct *sapi_headers TSRMLS_DC) /* {{{ */ +{ + php_cli_server_client *client = SG(server_context); + smart_str buffer = { 0 }; + sapi_header_struct *h; + zend_llist_position pos; + + if (client->capturing || SG(request_info).no_headers) { + return SAPI_HEADER_SENT_SUCCESSFULLY; + } + + if (SG(sapi_headers).http_status_line) { + smart_str_appends(&buffer, SG(sapi_headers).http_status_line); + smart_str_appendl(&buffer, "\r\n", 2); + } else { + append_http_status_line(&buffer, client->request.protocol_version, SG(sapi_headers).http_response_code, 0); + } + + append_essential_headers(&buffer, client, 0); + + h = (sapi_header_struct*)zend_llist_get_first_ex(&sapi_headers->headers, &pos); + while (h) { + if (!h->header_len) { + continue; + } + smart_str_appendl(&buffer, h->header, h->header_len); + smart_str_appendl(&buffer, "\r\n", 2); + h = (sapi_header_struct*)zend_llist_get_next_ex(&sapi_headers->headers, &pos); + } + smart_str_appendl(&buffer, "\r\n", 2); + + php_cli_server_client_send_through(client, buffer.c, buffer.len); + + smart_str_free(&buffer); + return SAPI_HEADER_SENT_SUCCESSFULLY; +} +/* }}} */ + +static char *sapi_cli_server_read_cookies(TSRMLS_D) /* {{{ */ +{ + php_cli_server_client *client = SG(server_context); + char **val; + if (FAILURE == zend_hash_find(&client->request.headers, "Cookie", sizeof("Cookie"), (void**)&val)) { + return NULL; + } + return *val; +} /* }}} */ + +static int sapi_cli_server_read_post(char *buf, uint count_bytes TSRMLS_DC) /* {{{ */ +{ + php_cli_server_client *client = SG(server_context); + if (client->request.content) { + size_t content_len = client->request.content_len; + size_t nbytes_copied = MIN(client->post_read_offset + count_bytes, content_len) - client->post_read_offset; + memmove(buf, client->request.content + client->post_read_offset, nbytes_copied); + client->post_read_offset += nbytes_copied; + return nbytes_copied; + } + return 0; +} /* }}} */ + +static void sapi_cli_server_register_variable(zval *track_vars_array, const char *key, const char *val TSRMLS_DC) /* {{{ */ +{ + char *new_val = (char *)val; + uint new_val_len; + if (sapi_module.input_filter(PARSE_SERVER, (char*)key, &new_val, strlen(val), &new_val_len TSRMLS_CC)) { + php_register_variable_safe((char *)key, new_val, new_val_len, track_vars_array TSRMLS_CC); + } +} /* }}} */ + +static void sapi_cli_server_register_variables(zval *track_vars_array TSRMLS_DC) /* {{{ */ +{ + php_cli_server_client *client = SG(server_context); + sapi_cli_server_register_variable(track_vars_array, "DOCUMENT_ROOT", client->server->document_root TSRMLS_CC); + { + smart_str buf = { 0 }; + smart_str_appends(&buf, client->server->host); + smart_str_appendc(&buf, ':'); + smart_str_append_generic_ex(&buf, client->server->port, 0, int, _unsigned); + smart_str_0(&buf); + sapi_cli_server_register_variable(track_vars_array, "HTTP_HOST", buf.c TSRMLS_CC); + smart_str_free(&buf); + } + { + char **val; + if (SUCCESS == zend_hash_find(&client->request.headers, "Cookie", sizeof("Cookie"), (void**)&val)) { + sapi_cli_server_register_variable(track_vars_array, "HTTP_COOKIE", *val TSRMLS_CC); + } + } + { + char **val; + if (SUCCESS == zend_hash_find(&client->request.headers, "Referer", sizeof("Referer"), (void**)&val)) { + sapi_cli_server_register_variable(track_vars_array, "HTTP_REFERER", *val TSRMLS_CC); + } + } + sapi_cli_server_register_variable(track_vars_array, "REQUEST_URI", client->request.request_uri TSRMLS_CC); + sapi_cli_server_register_variable(track_vars_array, "REQUEST_METHOD", SG(request_info).request_method TSRMLS_CC); + sapi_cli_server_register_variable(track_vars_array, "PHP_SELF", client->request.vpath TSRMLS_CC); + if (SG(request_info).path_translated) { + sapi_cli_server_register_variable(track_vars_array, "SCRIPT_FILENAME", SG(request_info).path_translated TSRMLS_CC); + } + if (client->request.path_info) { + sapi_cli_server_register_variable(track_vars_array, "PATH_INFO", client->request.path_info TSRMLS_CC); + } + if (client->request.query_string) { + sapi_cli_server_register_variable(track_vars_array, "QUERY_STRING", client->request.query_string TSRMLS_CC); + } +} /* }}} */ + +static void sapi_cli_server_log_message(char *msg TSRMLS_DC) /* {{{ */ +{ + struct timeval tv; + struct tm tm; + char buf[52]; + gettimeofday(&tv, NULL); + php_localtime_r(&tv.tv_sec, &tm); + php_asctime_r(&tm, buf); + { + size_t l = strlen(buf); + if (l > 0) { + buf[l - 1] = '\0'; + } else { + memmove(buf, "unknown", sizeof("unknown")); + } + } + fprintf(stderr, "[%s] %s\n", buf, msg); +} /* }}} */ + +/* {{{ sapi_module_struct cli_server_sapi_module + */ +sapi_module_struct cli_server_sapi_module = { + "cli-server", /* name */ + "Built-in HTTP server", /* pretty name */ + + sapi_cli_server_startup, /* startup */ + php_module_shutdown_wrapper, /* shutdown */ + + NULL, /* activate */ + NULL, /* deactivate */ + + sapi_cli_server_ub_write, /* unbuffered write */ + sapi_cli_server_flush, /* flush */ + NULL, /* get uid */ + NULL, /* getenv */ + + php_error, /* error handler */ + + NULL, /* header handler */ + sapi_cli_server_send_headers, /* send headers handler */ + NULL, /* send header handler */ + + sapi_cli_server_read_post, /* read POST data */ + sapi_cli_server_read_cookies, /* read Cookies */ + + sapi_cli_server_register_variables, /* register server variables */ + sapi_cli_server_log_message, /* Log message */ + NULL, /* Get request time */ + NULL, /* Child terminate */ + + STANDARD_SAPI_MODULE_PROPERTIES +}; /* }}} */ + +static int php_cli_server_poller_ctor(php_cli_server_poller *poller) /* {{{ */ +{ + FD_ZERO(&poller->rfds); + FD_ZERO(&poller->wfds); + poller->max_fd = -1; + return SUCCESS; +} /* }}} */ + +static void php_cli_server_poller_add(php_cli_server_poller *poller, int mode, int fd) /* {{{ */ +{ + if (mode & POLLIN) { + PHP_SAFE_FD_SET(fd, &poller->rfds); + } + if (mode & POLLOUT) { + PHP_SAFE_FD_SET(fd, &poller->wfds); + } + if (fd > poller->max_fd) { + poller->max_fd = fd; + } +} /* }}} */ + +static void php_cli_server_poller_remove(php_cli_server_poller *poller, int mode, int fd) /* {{{ */ +{ + if (mode & POLLIN) { + PHP_SAFE_FD_CLR(fd, &poller->rfds); + } + if (mode & POLLOUT) { + PHP_SAFE_FD_CLR(fd, &poller->wfds); + } +#ifndef PHP_WIN32 + if (fd == poller->max_fd) { + while (fd > 0) { + fd--; + if (((unsigned int *)&poller->rfds)[fd / (8 * sizeof(unsigned int))] || ((unsigned int *)&poller->wfds)[fd / (8 * sizeof(unsigned int))]) { + break; + } + fd -= fd % (8 * sizeof(unsigned int)); + } + poller->max_fd = fd; + } +#endif +} /* }}} */ + +static int php_cli_server_poller_poll(php_cli_server_poller *poller, const struct timeval *tv) /* {{{ */ +{ + memmove(&poller->active.rfds, &poller->rfds, sizeof(poller->rfds)); + memmove(&poller->active.wfds, &poller->wfds, sizeof(poller->wfds)); + return php_select(poller->max_fd + 1, &poller->active.rfds, &poller->active.wfds, NULL, (struct timeval *)tv); +} /* }}} */ + +static int php_cli_server_poller_iter_on_active(php_cli_server_poller *poller, void *opaque, int(*callback)(void *, int fd, int events)) /* {{{ */ +{ + int retval = SUCCESS; +#ifdef PHP_WIN32 + struct socket_entry { + SOCKET fd; + int events; + } entries[FD_SETSIZE * 2]; + php_socket_t fd = 0; + size_t i; + struct socket_entry *n = entries, *m; + + for (i = 0; i < poller->active.rfds.fd_count; i++) { + n->events = POLLIN; + n->fd = poller->active.rfds.fd_array[i]; + n++; + } + + m = n; + for (i = 0; i < poller->active.wfds.fd_count; i++) { + struct socket_entry *e; + SOCKET fd = poller->active.wfds.fd_array[i]; + for (e = entries; e < m; e++) { + if (e->fd == fd) { + e->events |= POLLOUT; + } + } + if (e == m) { + assert(n < entries + FD_SETSIZE * 2); + n->events = POLLOUT; + n->fd = fd; + n++; + } + } + + { + struct socket_entry *e = entries; + for (; e < n; e++) { + if (SUCCESS != callback(opaque, e->fd, e->events)) { + retval = FAILURE; + } + } + } + +#else + php_socket_t fd = 0; + const php_socket_t max_fd = poller->max_fd; + const unsigned int *pr = (unsigned int *)&poller->active.rfds, + *pw = (unsigned int *)&poller->active.wfds, + *e = pr + (max_fd + (8 * sizeof(unsigned int)) - 1) / (8 * sizeof(unsigned int)); + unsigned int mask; + while (pr < e && fd <= max_fd) { + for (mask = 1; mask; mask <<= 1, fd++) { + int events = (*pr & mask ? POLLIN: 0) | (*pw & mask ? POLLOUT: 0); + if (events) { + if (SUCCESS != callback(opaque, fd, events)) { + retval = FAILURE; + } + } + } + pr++; + pw++; + } +#endif + return retval; +} /* }}} */ + +static size_t php_cli_server_chunk_size(const php_cli_server_chunk *chunk) /* {{{ */ +{ + switch (chunk->type) { + case PHP_CLI_SERVER_CHUNK_HEAP: + return chunk->data.heap.len; + case PHP_CLI_SERVER_CHUNK_IMMORTAL: + return chunk->data.immortal.len; + } + return 0; +} /* }}} */ + +static void php_cli_server_chunk_dtor(php_cli_server_chunk *chunk) /* {{{ */ +{ + switch (chunk->type) { + case PHP_CLI_SERVER_CHUNK_HEAP: + if (chunk->data.heap.block != chunk) { + pefree(chunk->data.heap.block, 1); + } + break; + case PHP_CLI_SERVER_CHUNK_IMMORTAL: + break; + } +} /* }}} */ + +static void php_cli_server_buffer_dtor(php_cli_server_buffer *buffer) /* {{{ */ +{ + php_cli_server_chunk *chunk, *next; + for (chunk = buffer->first; chunk; chunk = next) { + next = chunk->next; + php_cli_server_chunk_dtor(chunk); + pefree(chunk, 1); + } +} /* }}} */ + +static void php_cli_server_buffer_ctor(php_cli_server_buffer *buffer) /* {{{ */ +{ + buffer->first = NULL; + buffer->last = NULL; +} /* }}} */ + +static void php_cli_server_buffer_append(php_cli_server_buffer *buffer, php_cli_server_chunk *chunk) /* {{{ */ +{ + php_cli_server_chunk *last; + for (last = chunk; last->next; last = last->next); + if (!buffer->last) { + buffer->first = chunk; + } else { + buffer->last->next = chunk; + } + buffer->last = last; +} /* }}} */ + +static void php_cli_server_buffer_prepend(php_cli_server_buffer *buffer, php_cli_server_chunk *chunk) /* {{{ */ +{ + php_cli_server_chunk *last; + for (last = chunk; last->next; last = last->next); + last->next = buffer->first; + if (!buffer->last) { + buffer->last = last; + } + buffer->first = chunk; +} /* }}} */ + +static size_t php_cli_server_buffer_size(const php_cli_server_buffer *buffer) /* {{{ */ +{ + php_cli_server_chunk *chunk; + size_t retval = 0; + for (chunk = buffer->first; chunk; chunk = chunk->next) { + retval += php_cli_server_chunk_size(chunk); + } + return retval; +} /* }}} */ + +static php_cli_server_chunk *php_cli_server_chunk_immortal_new(const char *buf, size_t len) /* {{{ */ +{ + php_cli_server_chunk *chunk = pemalloc(sizeof(php_cli_server_chunk), 1); + if (!chunk) { + return NULL; + } + + chunk->type = PHP_CLI_SERVER_CHUNK_IMMORTAL; + chunk->next = NULL; + chunk->data.immortal.p = buf; + chunk->data.immortal.len = len; + return chunk; +} /* }}} */ + +static php_cli_server_chunk *php_cli_server_chunk_heap_new(char *block, char *buf, size_t len) /* {{{ */ +{ + php_cli_server_chunk *chunk = pemalloc(sizeof(php_cli_server_chunk), 1); + if (!chunk) { + return NULL; + } + + chunk->type = PHP_CLI_SERVER_CHUNK_HEAP; + chunk->next = NULL; + chunk->data.heap.block = block; + chunk->data.heap.p = buf; + chunk->data.heap.len = len; + return chunk; +} /* }}} */ + +static php_cli_server_chunk *php_cli_server_chunk_heap_new_self_contained(size_t len) /* {{{ */ +{ + php_cli_server_chunk *chunk = pemalloc(sizeof(php_cli_server_chunk) + len, 1); + if (!chunk) { + return NULL; + } + + chunk->type = PHP_CLI_SERVER_CHUNK_HEAP; + chunk->next = NULL; + chunk->data.heap.block = chunk; + chunk->data.heap.p = (char *)(chunk + 1); + chunk->data.heap.len = len; + return chunk; +} /* }}} */ + +static void php_cli_server_content_sender_dtor(php_cli_server_content_sender *sender) /* {{{ */ +{ + php_cli_server_buffer_dtor(&sender->buffer); +} /* }}} */ + +static void php_cli_server_content_sender_ctor(php_cli_server_content_sender *sender) /* {{{ */ +{ + php_cli_server_buffer_ctor(&sender->buffer); +} /* }}} */ + +static int php_cli_server_content_sender_send(php_cli_server_content_sender *sender, php_socket_t fd, size_t *nbytes_sent_total) /* {{{ */ +{ + php_cli_server_chunk *chunk, *next; + size_t _nbytes_sent_total = 0; + + for (chunk = sender->buffer.first; chunk; chunk = next) { + ssize_t nbytes_sent; + next = chunk->next; + + switch (chunk->type) { + case PHP_CLI_SERVER_CHUNK_HEAP: + nbytes_sent = send(fd, chunk->data.heap.p, chunk->data.heap.len, 0); + if (nbytes_sent < 0) { + *nbytes_sent_total = _nbytes_sent_total; + return php_socket_errno(); + } else if (nbytes_sent == chunk->data.heap.len) { + php_cli_server_chunk_dtor(chunk); + pefree(chunk, 1); + sender->buffer.first = next; + if (!next) { + sender->buffer.last = NULL; + } + } else { + chunk->data.heap.p += nbytes_sent; + chunk->data.heap.len -= nbytes_sent; + } + _nbytes_sent_total += nbytes_sent; + break; + + case PHP_CLI_SERVER_CHUNK_IMMORTAL: + nbytes_sent = send(fd, chunk->data.immortal.p, chunk->data.immortal.len, 0); + if (nbytes_sent < 0) { + *nbytes_sent_total = _nbytes_sent_total; + return php_socket_errno(); + } else if (nbytes_sent == chunk->data.immortal.len) { + php_cli_server_chunk_dtor(chunk); + pefree(chunk, 1); + sender->buffer.first = next; + if (!next) { + sender->buffer.last = NULL; + } + } else { + chunk->data.immortal.p += nbytes_sent; + chunk->data.immortal.len -= nbytes_sent; + } + _nbytes_sent_total += nbytes_sent; + break; + } + } + *nbytes_sent_total = _nbytes_sent_total; + return 0; +} /* }}} */ + +static int php_cli_server_content_sender_pull(php_cli_server_content_sender *sender, int fd, size_t *nbytes_read) /* {{{ */ +{ + ssize_t _nbytes_read; + php_cli_server_chunk *chunk = php_cli_server_chunk_heap_new_self_contained(131072); + + _nbytes_read = read(fd, chunk->data.heap.p, chunk->data.heap.len); + if (_nbytes_read < 0) { + char *errstr = get_last_error(); + TSRMLS_FETCH(); + php_cli_server_logf("%s" TSRMLS_CC, errstr); + pefree(errstr, 1); + php_cli_server_chunk_dtor(chunk); + pefree(chunk, 1); + return 1; + } + chunk->data.heap.len = _nbytes_read; + php_cli_server_buffer_append(&sender->buffer, chunk); + *nbytes_read = _nbytes_read; + return 0; +} /* }}} */ + +static void php_cli_server_logf(const char *format TSRMLS_DC, ...) /* {{{ */ +{ + char buf[1024]; + va_list ap; +#ifdef ZTS + va_start(ap, tsrm_ls); +#else + va_start(ap, format); +#endif + vsnprintf(buf, sizeof(buf), format, ap); + va_end(ap); + if (sapi_module.log_message) { + sapi_module.log_message(buf TSRMLS_CC); + } +} /* }}} */ + +static int php_network_listen_socket(const char *host, int *port, int socktype, int *af, socklen_t *socklen, char **errstr TSRMLS_DC) /* {{{ */ +{ + int retval = SOCK_ERR; + int err = 0; + struct sockaddr *sa = NULL, **p, **sal; + + int num_addrs = php_network_getaddresses(host, socktype, &sal, errstr TSRMLS_CC); + if (num_addrs == 0) { + return -1; + } + for (p = sal; *p; p++) { + if (sa) { + pefree(sa, 1); + } + + retval = socket((*p)->sa_family, socktype, 0); + if (retval == SOCK_ERR) { + continue; + } + + switch ((*p)->sa_family) { +#if HAVE_GETADDRINFO && HAVE_IPV6 + case AF_INET6: + sa = pemalloc(sizeof(struct sockaddr_in6), 1); + if (!sa) { + closesocket(retval); + retval = SOCK_ERR; + *errstr = NULL; + goto out; + } + *(struct sockaddr_in6 *)sa = *(struct sockaddr_in6 *)*p; + ((struct sockaddr_in6 *)sa)->sin6_port = htons(*port); + *socklen = sizeof(struct sockaddr_in6); + break; +#endif + case AF_INET: + sa = pemalloc(sizeof(struct sockaddr_in), 1); + if (!sa) { + closesocket(retval); + retval = SOCK_ERR; + *errstr = NULL; + goto out; + } + *(struct sockaddr_in *)sa = *(struct sockaddr_in *)*p; + ((struct sockaddr_in *)sa)->sin_port = htons(*port); + *socklen = sizeof(struct sockaddr_in); + break; + default: + /* Unknown family */ + *socklen = 0; + closesocket(retval); + continue; + } + +#ifdef SO_REUSEADDR + { + int val = 1; + setsockopt(retval, SOL_SOCKET, SO_REUSEADDR, (char*)&val, sizeof(val)); + } +#endif + + if (bind(retval, sa, *socklen) == SOCK_CONN_ERR) { + err = php_socket_errno(); + if (err == SOCK_EINVAL || err == SOCK_EADDRINUSE) { + goto out; + } + closesocket(retval); + retval = SOCK_ERR; + continue; + } + err = 0; + + *af = sa->sa_family; + if (*port == 0) { + if (getsockname(retval, sa, socklen)) { + err = php_socket_errno(); + goto out; + } + switch (sa->sa_family) { +#if HAVE_GETADDRINFO && HAVE_IPV6 + case AF_INET6: + *port = ntohs(((struct sockaddr_in6 *)sa)->sin6_port); + break; +#endif + case AF_INET: + *port = ntohs(((struct sockaddr_in *)sa)->sin_port); + break; + } + } + + break; + } + + if (retval == SOCK_ERR) { + goto out; + } + + if (listen(retval, SOMAXCONN)) { + err = php_socket_errno(); + goto out; + } + +out: + if (sa) { + pefree(sa, 1); + } + if (sal) { + php_network_freeaddresses(sal); + } + if (err) { + if (retval >= 0) { + closesocket(retval); + } + if (errstr) { + *errstr = php_socket_strerror(err, NULL, 0); + } + return SOCK_ERR; + } + return retval; +} /* }}} */ + +static int php_cli_server_request_ctor(php_cli_server_request *req) /* {{{ */ +{ + req->protocol_version = 0; + req->request_uri = NULL; + req->request_uri_len = 0; + req->vpath = NULL; + req->vpath_len = 0; + req->path_translated = NULL; + req->path_translated_len = 0; + req->path_info = NULL; + req->path_info_len = 0; + req->query_string = NULL; + req->query_string_len = 0; + zend_hash_init(&req->headers, 0, NULL, (void(*)(void*))char_ptr_dtor_p, 1); + req->content = NULL; + req->content_len = 0; + req->ext = NULL; + req->ext_len = 0; + return SUCCESS; +} /* }}} */ + +static void php_cli_server_request_dtor(php_cli_server_request *req) /* {{{ */ +{ + if (req->request_uri) { + pefree(req->request_uri, 1); + } + if (req->vpath) { + pefree(req->vpath, 1); + } + if (req->path_translated) { + pefree(req->path_translated, 1); + } + if (req->path_info) { + pefree(req->path_info, 1); + } + if (req->query_string) { + pefree(req->query_string, 1); + } + zend_hash_destroy(&req->headers); + if (req->content) { + pefree(req->content, 1); + } +} /* }}} */ + +static void php_cli_server_request_translate_vpath(php_cli_server_request *request, const char *document_root, size_t document_root_len) /* {{{ */ +{ + struct stat sb; + static const char *index_files[] = { "index.html", "index.php", NULL }; + char *buf = safe_pemalloc(1, request->vpath_len, 1 + document_root_len + 1 + sizeof("index.html"), 1); + char *p = buf, *prev_patch = 0, *q, *vpath; + memmove(p, document_root, document_root_len); + p += document_root_len; + vpath = p; + if (request->vpath_len > 0 && request->vpath[0] != '/') { + *p++ = '/'; + } + memmove(p, request->vpath, request->vpath_len); + p += request->vpath_len; + *p = '\0'; + q = p; + while (q > buf) { + if (!stat(buf, &sb)) { + if (sb.st_mode & S_IFDIR) { + const char **file = index_files; + if (p > buf && p[-1] != '/') { + *p++ = '/'; + } + while (*file) { + size_t l = strlen(*file); + memmove(p, *file, l + 1); + if (!stat(buf, &sb) && (sb.st_mode & S_IFREG)) { + p += l; + break; + } + file++; + } + if (!*file) { + pefree(buf, 1); + return; + } + } + break; /* regular file */ + } + while (q > buf && *(--q) != '/'); + if (prev_patch) { + *prev_patch = '/'; + } + *q = '\0'; + prev_patch = q; + } + if (prev_patch) { + *prev_patch = '/'; + request->path_info = pestrndup(prev_patch, p - prev_patch, 1); + request->path_info_len = p - prev_patch; + pefree(request->vpath, 1); + request->vpath = pestrndup(vpath, prev_patch - vpath, 1); + request->vpath_len = prev_patch - vpath; + *prev_patch = '\0'; + request->path_translated = buf; + request->path_translated_len = prev_patch - buf; + } else { + pefree(request->vpath, 1); + request->vpath = pestrndup(vpath, p - vpath, 1); + request->vpath_len = p - vpath; + request->path_translated = buf; + request->path_translated_len = p - buf; + } + request->sb = sb; +} /* }}} */ + +static void normalize_vpath(char **retval, size_t *retval_len, const char *vpath, size_t vpath_len, int persistent) /* {{{ */ +{ + char *decoded_vpath = NULL; + char *decoded_vpath_end; + char *p; + + *retval = NULL; + + decoded_vpath = pestrndup(vpath, vpath_len, persistent); + if (!decoded_vpath) { + return; + } + + decoded_vpath_end = decoded_vpath + php_url_decode(decoded_vpath, vpath_len); + + p = decoded_vpath; + + if (p < decoded_vpath_end && *p == '/') { + char *n = p; + while (n < decoded_vpath_end && *n == '/') n++; + memmove(++p, n, decoded_vpath_end - n); + decoded_vpath_end -= n - p; + } + + while (p < decoded_vpath_end) { + char *n = p; + while (n < decoded_vpath_end && *n != '/') n++; + if (n - p == 2 && p[0] == '.' && p[1] == '.') { + if (p > decoded_vpath) { + --p; + for (;;) { + if (p == decoded_vpath) { + if (*p == '/') { + p++; + } + break; + } + if (*(--p) == '/') { + p++; + break; + } + } + } + while (n < decoded_vpath_end && *n == '/') n++; + memmove(p, n, decoded_vpath_end - n); + decoded_vpath_end -= n - p; + } else if (n - p == 1 && p[0] == '.') { + while (n < decoded_vpath_end && *n == '/') n++; + memmove(p, n, decoded_vpath_end - n); + decoded_vpath_end -= n - p; + } else { + if (n < decoded_vpath_end) { + char *nn = n; + while (nn < decoded_vpath_end && *nn == '/') nn++; + p = n + 1; + memmove(p, nn, decoded_vpath_end - nn); + decoded_vpath_end -= nn - p; + } else { + p = n; + } + } + } + + *decoded_vpath_end = '\0'; + *retval = decoded_vpath; + *retval_len = decoded_vpath_end - decoded_vpath; +} /* }}} */ + +/* {{{ php_cli_server_client_read_request */ +static int php_cli_server_client_read_request_on_message_begin(php_http_parser *parser) +{ + return 0; +} + +static int php_cli_server_client_read_request_on_path(php_http_parser *parser, const char *at, size_t length) +{ + php_cli_server_client *client = parser->data; + { + char *vpath; + size_t vpath_len; + normalize_vpath(&vpath, &vpath_len, at, length, 1); + client->request.vpath = vpath; + client->request.vpath_len = vpath_len; + } + return 0; +} + +static int php_cli_server_client_read_request_on_query_string(php_http_parser *parser, const char *at, size_t length) +{ + php_cli_server_client *client = parser->data; + client->request.query_string = pestrndup(at, length, 1); + client->request.query_string_len = length; + return 0; +} + +static int php_cli_server_client_read_request_on_url(php_http_parser *parser, const char *at, size_t length) +{ + php_cli_server_client *client = parser->data; + client->request.request_method = parser->method; + client->request.request_uri = pestrndup(at, length, 1); + client->request.request_uri_len = length; + return 0; +} + +static int php_cli_server_client_read_request_on_fragment(php_http_parser *parser, const char *at, size_t length) +{ + return 0; +} + +static int php_cli_server_client_read_request_on_header_field(php_http_parser *parser, const char *at, size_t length) +{ + php_cli_server_client *client = parser->data; + if (client->current_header_name_allocated) { + pefree(client->current_header_name, 1); + client->current_header_name_allocated = 0; + } + client->current_header_name = (char *)at; + client->current_header_name_len = length; + return 0; +} + +static int php_cli_server_client_read_request_on_header_value(php_http_parser *parser, const char *at, size_t length) +{ + php_cli_server_client *client = parser->data; + char *value = pestrndup(at, length, 1); + if (!value) { + return 1; + } + { + char *header_name = client->current_header_name; + size_t header_name_len = client->current_header_name_len; + char c = header_name[header_name_len]; + header_name[header_name_len] = '\0'; + zend_hash_add(&client->request.headers, header_name, header_name_len + 1, &value, sizeof(char *), NULL); + header_name[header_name_len] = c; + } + + if (client->current_header_name_allocated) { + pefree(client->current_header_name, 1); + client->current_header_name_allocated = 0; + } + return 0; +} + +static int php_cli_server_client_read_request_on_headers_complete(php_http_parser *parser) +{ + php_cli_server_client *client = parser->data; + if (client->current_header_name_allocated) { + pefree(client->current_header_name, 1); + client->current_header_name_allocated = 0; + } + client->current_header_name = NULL; + return 0; +} + +static int php_cli_server_client_read_request_on_body(php_http_parser *parser, const char *at, size_t length) +{ + php_cli_server_client *client = parser->data; + if (!client->request.content) { + client->request.content = pemalloc(parser->content_length, 1); + client->request.content_len = 0; + } + memmove(client->request.content + client->request.content_len, at, length); + client->request.content_len += length; + return 0; +} + +static int php_cli_server_client_read_request_on_message_complete(php_http_parser *parser) +{ + php_cli_server_client *client = parser->data; + client->request.protocol_version = parser->http_major * 100 + parser->http_minor; + php_cli_server_request_translate_vpath(&client->request, client->server->document_root, client->server->document_root_len); + { + const char *vpath = client->request.vpath, *end = vpath + client->request.vpath_len, *p = end; + client->request.ext = end; + client->request.ext_len = 0; + while (p > vpath) { + --p; + if (*p == '.') { + ++p; + client->request.ext = p; + client->request.ext_len = end - p; + break; + } + } + } + client->request_read = 1; + return 0; +} + +static int php_cli_server_client_read_request(php_cli_server_client *client, char **errstr TSRMLS_DC) +{ + char buf[16384]; + static const php_http_parser_settings settings = { + php_cli_server_client_read_request_on_message_begin, + php_cli_server_client_read_request_on_path, + php_cli_server_client_read_request_on_query_string, + php_cli_server_client_read_request_on_url, + php_cli_server_client_read_request_on_fragment, + php_cli_server_client_read_request_on_header_field, + php_cli_server_client_read_request_on_header_value, + php_cli_server_client_read_request_on_headers_complete, + php_cli_server_client_read_request_on_body, + php_cli_server_client_read_request_on_message_complete + }; + size_t nbytes_consumed; + int nbytes_read; + if (client->request_read) { + return 1; + } + nbytes_read = recv(client->sock, buf, sizeof(buf) - 1, 0); + if (nbytes_read < 0) { + int err = php_socket_errno(); + if (err == SOCK_EAGAIN) { + return 0; + } + *errstr = php_socket_strerror(err, NULL, 0); + return -1; + } else if (nbytes_read == 0) { + *errstr = estrdup("Unexpected EOF"); + return -1; + } + client->parser.data = client; + nbytes_consumed = php_http_parser_execute(&client->parser, &settings, buf, nbytes_read); + if (nbytes_consumed != nbytes_read) { + *errstr = estrdup("Malformed HTTP request"); + return -1; + } + if (client->current_header_name) { + char *header_name = safe_pemalloc(client->current_header_name_len, 1, 1, 1); + memmove(header_name, client->current_header_name, client->current_header_name_len); + client->current_header_name = header_name; + client->current_header_name_allocated = 1; + } + return client->request_read ? 1: 0; +} +/* }}} */ + +static size_t php_cli_server_client_send_through(php_cli_server_client *client, const char *str, size_t str_len) /* }}} */ +{ + struct timeval tv = { 10, 0 }; + ssize_t nbytes_left = str_len; + do { + ssize_t nbytes_sent = send(client->sock, str, str_len, 0); + if (nbytes_sent < 0) { + int err = php_socket_errno(); + if (err == EAGAIN) { + int nfds = php_pollfd_for(client->sock, POLLOUT, &tv); + if (nfds > 0) { + continue; + } else if (nfds < 0) { + /* error */ + php_handle_aborted_connection(); + return nbytes_left; + } else { + /* timeout */ + php_handle_aborted_connection(); + return nbytes_left; + } + } else { + php_handle_aborted_connection(); + return nbytes_left; + } + } + nbytes_left -= nbytes_sent; + } while (nbytes_left > 0); + + return str_len; +} /* }}} */ + +static void php_cli_server_client_populate_request_info(const php_cli_server_client *client, sapi_request_info *request_info) /* {{{ */ +{ + request_info->request_method = php_http_method_str(client->request.request_method); + request_info->proto_num = client->request.protocol_version; + request_info->request_uri = client->request.request_uri; + request_info->path_translated = client->request.path_translated; + request_info->query_string = client->request.query_string; + request_info->post_data = client->request.content; + request_info->content_length = request_info->post_data_length = client->request.content_len; + { + char **val; + if (SUCCESS == zend_hash_find(&client->request.headers, "Content-Type", sizeof("Content-Type"), (void**)&val)) { + request_info->content_type = *val; + } + } +} /* }}} */ + +static void destroy_request_info(sapi_request_info *request_info) /* {{{ */ +{ +} /* }}} */ + +static void php_cli_server_client_begin_capture(php_cli_server_client *client) /* {{{ */ +{ + php_cli_server_buffer_ctor(&client->capture_buffer); + client->capturing = 1; +} /* }}} */ + +static void php_cli_server_client_end_capture(php_cli_server_client *client) /* {{{ */ +{ + client->capturing = 0; + php_cli_server_buffer_dtor(&client->capture_buffer); +} /* }}} */ + +static int php_cli_server_client_ctor(php_cli_server_client *client, php_cli_server *server, int client_sock, struct sockaddr *addr, socklen_t addr_len TSRMLS_DC) /* {{{ */ +{ + client->server = server; + client->sock = client_sock; + client->addr = addr; + client->addr_len = addr_len; + { + char *addr_str = 0; + long addr_str_len = 0; + php_network_populate_name_from_sockaddr(addr, addr_len, &addr_str, &addr_str_len, NULL, 0 TSRMLS_CC); + client->addr_str = pestrndup(addr_str, addr_str_len, 1); + client->addr_str_len = addr_str_len; + efree(addr_str); + } + php_http_parser_init(&client->parser, PHP_HTTP_REQUEST); + client->request_read = 0; + client->current_header_name = NULL; + client->current_header_name_len = 0; + client->current_header_name_allocated = 0; + client->post_read_offset = 0; + if (FAILURE == php_cli_server_request_ctor(&client->request)) { + return FAILURE; + } + client->content_sender_initialized = 0; + client->capturing = 0; + client->file_fd = -1; + return SUCCESS; +} /* }}} */ + +static void php_cli_server_client_dtor(php_cli_server_client *client) /* {{{ */ +{ + php_cli_server_request_dtor(&client->request); + if (client->file_fd >= 0) { + close(client->file_fd); + client->file_fd = -1; + } + pefree(client->addr, 1); + pefree(client->addr_str, 1); + if (client->content_sender_initialized) { + php_cli_server_content_sender_dtor(&client->content_sender); + } + if (client->capturing) { + php_cli_server_buffer_dtor(&client->capture_buffer); + } +} /* }}} */ + +static void php_cli_server_close_connection(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ +#ifdef DEBUG + php_cli_server_logf("%s: Closing" TSRMLS_CC, client->addr_str); +#endif + zend_hash_index_del(&server->clients, client->sock); +} /* }}} */ + +static int php_cli_server_send_error_page(php_cli_server *server, php_cli_server_client *client, int status TSRMLS_DC) /* {{{ */ +{ + char *escaped_request_uri = NULL; + size_t escaped_request_uri_len; + const char *status_string = get_status_string(status); + const char *content_template = get_template_string(status); + assert(status_string && content_template); + + php_cli_server_content_sender_ctor(&client->content_sender); + client->content_sender_initialized = 1; + + escaped_request_uri = php_escape_html_entities_ex((unsigned char *)client->request.request_uri, client->request.request_uri_len, &escaped_request_uri_len, 0, ENT_QUOTES, NULL, 0 TSRMLS_CC); + + { + static const char prologue_template[] = "%d %s"; + php_cli_server_chunk *chunk = php_cli_server_chunk_heap_new_self_contained(strlen(prologue_template) + 3 + strlen(status_string) + 1); + if (!chunk) { + goto fail; + } + snprintf(chunk->data.heap.p, chunk->data.heap.len, prologue_template, status, status_string, escaped_request_uri); + chunk->data.heap.len = strlen(chunk->data.heap.p); + php_cli_server_buffer_append(&client->content_sender.buffer, chunk); + } + { + int err = 0; + sapi_activate_headers_only(TSRMLS_C); + php_cli_server_client_begin_capture(client); + zend_try { + php_info_print_style(TSRMLS_C); + php_cli_server_buffer_append(&client->content_sender.buffer, client->capture_buffer.first); + client->capture_buffer.first = client->capture_buffer.last = NULL; + } zend_catch { + err = 1; + } zend_end_try(); + php_cli_server_client_end_capture(client); + sapi_deactivate(TSRMLS_C); + if (err) { + goto fail; + } + } + { + static const char template[] = ""; + php_cli_server_chunk *chunk = php_cli_server_chunk_immortal_new(template, sizeof(template) - 1); + if (!chunk) { + goto fail; + } + php_cli_server_buffer_append(&client->content_sender.buffer, chunk); + } + { + php_cli_server_chunk *chunk = php_cli_server_chunk_heap_new_self_contained(strlen(content_template) + escaped_request_uri_len + 3 + strlen(status_string) + 1); + if (!chunk) { + goto fail; + } + snprintf(chunk->data.heap.p, chunk->data.heap.len, content_template, status_string, escaped_request_uri); + chunk->data.heap.len = strlen(chunk->data.heap.p); + php_cli_server_buffer_append(&client->content_sender.buffer, chunk); + } + { + static const char epilogue_template[] = ""; + php_cli_server_chunk *chunk = php_cli_server_chunk_immortal_new(epilogue_template, sizeof(epilogue_template) - 1); + if (!chunk) { + goto fail; + } + php_cli_server_buffer_append(&client->content_sender.buffer, chunk); + } + + { + php_cli_server_chunk *chunk; + smart_str buffer = { 0 }; + append_http_status_line(&buffer, client->request.protocol_version, status, 1); + if (!buffer.c) { + /* out of memory */ + goto fail; + } + append_essential_headers(&buffer, client, 1); + smart_str_appends_ex(&buffer, "Content-Type: text/html; charset=UTF-8\r\n", 1); + smart_str_appends_ex(&buffer, "Content-Length: ", 1); + smart_str_append_generic_ex(&buffer, php_cli_server_buffer_size(&client->content_sender.buffer), 1, size_t, _unsigned); + smart_str_appendl_ex(&buffer, "\r\n", 2, 1); + smart_str_appendl_ex(&buffer, "\r\n", 2, 1); + + chunk = php_cli_server_chunk_heap_new(buffer.c, buffer.c, buffer.len); + if (!chunk) { + smart_str_free_ex(&buffer, 1); + goto fail; + } + php_cli_server_buffer_prepend(&client->content_sender.buffer, chunk); + } + + php_cli_server_logf("%s: %s - Sending error page (%d)" TSRMLS_CC, client->addr_str, client->request.request_uri, status); + php_cli_server_poller_add(&server->poller, POLLOUT, client->sock); + efree(escaped_request_uri); + return SUCCESS; + +fail: + efree(escaped_request_uri); + return FAILURE; +} /* }}} */ + +static int php_cli_server_dispatch_script(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ + php_cli_server_client_populate_request_info(client, &SG(request_info)); + { + zval **val; + if (SUCCESS == zend_hash_find(&client->request.headers, "Authorization", sizeof("Authorization"), (void**)&val)) { + php_handle_auth_data(Z_STRVAL_PP(val) TSRMLS_CC); + } + } + SG(sapi_headers).http_response_code = 200; + if (FAILURE == php_request_startup(TSRMLS_C)) { + /* should never be happen */ + destroy_request_info(&SG(request_info)); + return FAILURE; + } + { + zend_file_handle zfd; + zfd.type = ZEND_HANDLE_FILENAME; + zfd.filename = SG(request_info).path_translated; + zfd.handle.fp = NULL; + zfd.free_filename = 0; + zfd.opened_path = NULL; + zend_try { + php_execute_script(&zfd TSRMLS_CC); + } zend_end_try(); + } + + php_request_shutdown(0); + php_cli_server_close_connection(server, client TSRMLS_CC); + destroy_request_info(&SG(request_info)); + return SUCCESS; +} /* }}} */ + +static int php_cli_server_begin_send_static(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ + int fd; + int status = 200; + + fd = client->request.path_translated ? open(client->request.path_translated, O_RDONLY): -1; + if (fd < 0) { + char *errstr = get_last_error(); + if (errstr) { + php_cli_server_logf("%s: %s - %s" TSRMLS_CC, client->addr_str, client->request.request_uri, errstr); + pefree(errstr, 1); + } else { + php_cli_server_logf("%s: %s - ?" TSRMLS_CC, client->addr_str, client->request.request_uri); + } + return php_cli_server_send_error_page(server, client, 404 TSRMLS_CC); + } + + php_cli_server_content_sender_ctor(&client->content_sender); + client->content_sender_initialized = 1; + client->file_fd = fd; + + { + php_cli_server_chunk *chunk; + smart_str buffer = { 0 }; + const char *mime_type = get_mime_type(client->request.ext, client->request.ext_len); + if (!mime_type) { + mime_type = "application/octet-stream"; + } + + append_http_status_line(&buffer, client->request.protocol_version, status, 1); + if (!buffer.c) { + /* out of memory */ + return FAILURE; + } + append_essential_headers(&buffer, client, 1); + smart_str_appendl_ex(&buffer, "Content-Type: ", sizeof("Content-Type: ") - 1, 1); + smart_str_appends_ex(&buffer, mime_type, 1); + if (strncmp(mime_type, "text/", 5) == 0) { + smart_str_appends_ex(&buffer, "; charset=UTF-8", 1); + } + smart_str_appendl_ex(&buffer, "\r\n", 2, 1); + smart_str_appends_ex(&buffer, "Content-Length: ", 1); + smart_str_append_generic_ex(&buffer, client->request.sb.st_size, 1, size_t, _unsigned); + smart_str_appendl_ex(&buffer, "\r\n", 2, 1); + smart_str_appendl_ex(&buffer, "\r\n", 2, 1); + chunk = php_cli_server_chunk_heap_new(buffer.c, buffer.c, buffer.len); + if (!chunk) { + smart_str_free_ex(&buffer, 1); + return FAILURE; + } + php_cli_server_buffer_append(&client->content_sender.buffer, chunk); + } + php_cli_server_poller_add(&server->poller, POLLOUT, client->sock); + return SUCCESS; +} +/* }}} */ + +static int php_cli_server_dispatch_router(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ + int decline = 0; + + if (!server->router) { + return 1; + } + + php_cli_server_client_populate_request_info(client, &SG(request_info)); + { + zval **val; + if (SUCCESS == zend_hash_find(&client->request.headers, "Authorization", sizeof("Authorization"), (void**)&val)) { + php_handle_auth_data(Z_STRVAL_PP(val) TSRMLS_CC); + } + } + SG(sapi_headers).http_response_code = 200; + if (FAILURE == php_request_startup(TSRMLS_C)) { + /* should never be happen */ + destroy_request_info(&SG(request_info)); + return -1; + } + { + zend_file_handle zfd; + zfd.type = ZEND_HANDLE_FILENAME; + zfd.filename = server->router; + zfd.handle.fp = NULL; + zfd.free_filename = 0; + zfd.opened_path = NULL; + zend_try { + zval *retval = NULL; + if (SUCCESS == zend_execute_scripts(ZEND_REQUIRE TSRMLS_CC, &retval, 1, &zfd)) { + if (retval) { + decline = Z_TYPE_P(retval) == IS_BOOL && !Z_LVAL_P(retval); + zval_ptr_dtor(&retval); + } + } else { + decline = 1; + } + } zend_end_try(); + } + + if (decline) { + php_request_shutdown_for_hook(0); + } else { + php_request_shutdown(0); + php_cli_server_close_connection(server, client TSRMLS_CC); + } + destroy_request_info(&SG(request_info)); + + return decline ? 1: 0; +} +/* }}} */ + +static int php_cli_server_dispatch(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ + int status; + + SG(server_context) = client; + status = php_cli_server_dispatch_router(server, client TSRMLS_CC); + + if (status < 0) { + goto fail; + } else if (status > 0) { + if (client->request.ext_len == 3 && memcmp(client->request.ext, "php", 3) == 0 && client->request.path_translated) { + if (SUCCESS != php_cli_server_dispatch_script(server, client TSRMLS_CC) && + SUCCESS != php_cli_server_send_error_page(server, client, 500 TSRMLS_CC)) { + goto fail; + } + } else { + if (SUCCESS != php_cli_server_begin_send_static(server, client TSRMLS_CC)) { + goto fail; + } + } + } + SG(server_context) = 0; + return SUCCESS; +fail: + SG(server_context) = 0; + php_cli_server_close_connection(server, client TSRMLS_CC); + return SUCCESS; +} + +static void php_cli_server_dtor(php_cli_server *server TSRMLS_DC) /* {{{ */ +{ + zend_hash_destroy(&server->clients); + if (server->server_sock >= 0) { + closesocket(server->server_sock); + } + if (server->host) { + pefree(server->host, 1); + } + if (server->document_root) { + pefree(server->document_root, 1); + } + if (server->router) { + pefree(server->router, 1); + } +} /* }}} */ + +static void php_cli_server_client_dtor_wrapper(php_cli_server_client **p) /* {{{ */ +{ + closesocket((*p)->sock); + php_cli_server_poller_remove(&(*p)->server->poller, POLLIN | POLLOUT, (*p)->sock); + php_cli_server_client_dtor(*p); + pefree(*p, 1); +} /* }}} */ + +static int php_cli_server_ctor(php_cli_server *server, const char *addr, const char *document_root, const char *router TSRMLS_DC) /* {{{ */ +{ + int retval = SUCCESS; + char *host = NULL; + char *errstr = NULL; + char *_document_root = NULL; + char *_router = NULL; + int err = 0; + int port = 3000; + php_socket_t server_sock = SOCK_ERR; + + host = pestrdup(addr, 1); + if (!host) { + return FAILURE; + } + + { + char *p = strchr(host, ':'); + if (p) { + *p++ = '\0'; + port = strtol(p, &p, 10); + } + } + + server_sock = php_network_listen_socket(host, &port, SOCK_STREAM, &server->address_family, &server->socklen, &errstr TSRMLS_CC); + if (server_sock == SOCK_ERR) { + php_cli_server_logf("Failed to listen on %s:%d (reason: %s)" TSRMLS_CC, host, port, errstr ? errstr: "?"); + efree(errstr); + retval = FAILURE; + goto out; + } + server->server_sock = server_sock; + + err = php_cli_server_poller_ctor(&server->poller); + if (SUCCESS != err) { + goto out; + } + + php_cli_server_poller_add(&server->poller, POLLIN, server_sock); + + server->host = host; + server->port = port; + + zend_hash_init(&server->clients, 0, NULL, (void(*)(void*))php_cli_server_client_dtor_wrapper, 1); + + { + size_t document_root_len = strlen(document_root); + _document_root = pestrndup(document_root, document_root_len, 1); + if (!_document_root) { + retval = FAILURE; + goto out; + } + server->document_root = _document_root; + server->document_root_len = document_root_len; + } + + if (router) { + size_t router_len = strlen(router); + _router = pestrndup(router, router_len, 1); + if (!_router) { + retval = FAILURE; + goto out; + } + server->router = _router; + server->router_len = router_len; + } else { + server->router = NULL; + server->router_len = 0; + } + + server->is_running = 1; +out: + if (retval != SUCCESS) { + if (host) { + pefree(host, 1); + } + if (_document_root) { + pefree(_document_root, 1); + } + if (_router) { + pefree(_router, 1); + } + if (server_sock >= -1) { + closesocket(server_sock); + } + } + return retval; +} /* }}} */ + +static int php_cli_server_recv_event_read_request(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ + char *errstr = NULL; + int status = php_cli_server_client_read_request(client, &errstr TSRMLS_CC); + if (status < 0) { + php_cli_server_logf("%s: Invalid request (%s)" TSRMLS_CC, client->addr_str, errstr); + efree(errstr); + php_cli_server_close_connection(server, client TSRMLS_CC); + return FAILURE; + } else if (status == 1) { + php_cli_server_logf("%s: %s" TSRMLS_CC, client->addr_str, client->request.request_uri); + php_cli_server_poller_remove(&server->poller, POLLIN, client->sock); + php_cli_server_dispatch(server, client TSRMLS_CC); + } else { + php_cli_server_poller_add(&server->poller, POLLIN, client->sock); + } + + return SUCCESS; +} /* }}} */ + +static int php_cli_server_send_event(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ +{ + if (client->content_sender_initialized) { + if (client->file_fd >= 0 && !client->content_sender.buffer.first) { + size_t nbytes_read; + if (php_cli_server_content_sender_pull(&client->content_sender, client->file_fd, &nbytes_read)) { + php_cli_server_close_connection(server, client TSRMLS_CC); + return FAILURE; + } + if (nbytes_read == 0) { + close(client->file_fd); + client->file_fd = -1; + } + } + { + size_t nbytes_sent; + int err = php_cli_server_content_sender_send(&client->content_sender, client->sock, &nbytes_sent); + if (err && err != SOCK_EAGAIN) { + php_cli_server_close_connection(server, client TSRMLS_CC); + return FAILURE; + } + } + if (!client->content_sender.buffer.first && client->file_fd < 0) { + php_cli_server_close_connection(server, client TSRMLS_CC); + } + } + return SUCCESS; +} +/* }}} */ + +typedef struct php_cli_server_do_event_for_each_fd_callback_params { +#ifdef ZTS + void ***tsrm_ls; +#endif + php_cli_server *server; + int(*rhandler)(php_cli_server*, php_cli_server_client* TSRMLS_DC); + int(*whandler)(php_cli_server*, php_cli_server_client* TSRMLS_DC); +} php_cli_server_do_event_for_each_fd_callback_params; + +static int php_cli_server_do_event_for_each_fd_callback(void *_params, int fd, int event) +{ + php_cli_server_do_event_for_each_fd_callback_params *params = _params; +#ifdef ZTS + void ***tsrm_ls = params->tsrm_ls; +#endif + php_cli_server *server = params->server; + if (server->server_sock == fd) { + php_cli_server_client *client = NULL; + php_socket_t client_sock; + socklen_t socklen = server->socklen; + struct sockaddr *sa = pemalloc(server->socklen, 1); + if (!sa) { + return FAILURE; + } + client_sock = accept(server->server_sock, sa, &socklen); + if (client_sock < 0) { + char *errstr; + errstr = php_socket_strerror(php_socket_errno(), NULL, 0); + php_cli_server_logf("Failed to accept a client (reason: %s)" TSRMLS_CC, errstr); + efree(errstr); + pefree(sa, 1); + return SUCCESS; + } + if (SUCCESS != php_set_sock_blocking(client_sock, 0 TSRMLS_CC)) { + pefree(sa, 1); + closesocket(client_sock); + return SUCCESS; + } + if (!(client = pemalloc(sizeof(php_cli_server_client), 1)) || FAILURE == php_cli_server_client_ctor(client, server, client_sock, sa, socklen TSRMLS_CC)) { + php_cli_server_logf("Failed to create a new request object" TSRMLS_CC); + pefree(sa, 1); + closesocket(client_sock); + return SUCCESS; + } +#ifdef DEBUG + php_cli_server_logf("%s: Accepted" TSRMLS_CC, client->addr_str); +#endif + zend_hash_index_update(&server->clients, client_sock, &client, sizeof(client), NULL); + php_cli_server_recv_event_read_request(server, client TSRMLS_CC); + } else { + php_cli_server_client **client; + if (SUCCESS == zend_hash_index_find(&server->clients, fd, (void **)&client)) { + if (event & POLLIN) { + params->rhandler(server, *client TSRMLS_CC); + } + if (event & POLLOUT) { + params->whandler(server, *client TSRMLS_CC); + } + } + } + return SUCCESS; +} + +static void php_cli_server_do_event_for_each_fd(php_cli_server *server, int(*rhandler)(php_cli_server*, php_cli_server_client* TSRMLS_DC), int(*whandler)(php_cli_server*, php_cli_server_client* TSRMLS_DC) TSRMLS_DC) /* {{{ */ +{ + php_cli_server_do_event_for_each_fd_callback_params params = { +#ifdef ZTS + tsrm_ls, +#endif + server, + rhandler, + whandler + }; + + php_cli_server_poller_iter_on_active(&server->poller, ¶ms, php_cli_server_do_event_for_each_fd_callback); +} /* }}} */ + +static int php_cli_server_do_event_loop(php_cli_server *server TSRMLS_DC) /* {{{ */ +{ + int retval = SUCCESS; + while (server->is_running) { + static const struct timeval tv = { 1, 0 }; + int n = php_cli_server_poller_poll(&server->poller, &tv); + if (n > 0) { + php_cli_server_do_event_for_each_fd(server, + php_cli_server_recv_event_read_request, + php_cli_server_send_event TSRMLS_CC); + } else if (n == 0) { + /* do nothing */ + } else { + int err = php_socket_errno(); + if (err != SOCK_EINTR) { + char *errstr = php_socket_strerror(err, NULL, 0); + php_cli_server_logf("%s" TSRMLS_CC, errstr); + efree(errstr); + retval = FAILURE; + goto out; + } + } + } +out: + return retval; +} /* }}} */ + + +static php_cli_server server; + +static void php_cli_server_sigint_handler(int sig) +{ + server.is_running = 0; +}; + +int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ +{ + char *php_optarg = NULL; + int php_optind = 1; + int c; + const char *server_bind_address = NULL; + extern const opt_struct OPTIONS[]; + const char *document_root = NULL; + const char *router = NULL; + + while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2))!=-1) { + switch (c) { + case 'S': + server_bind_address = php_optarg; + break; + case 't': + document_root = php_optarg; + break; + } + } + + if (document_root) { + struct stat sb; + if (stat(document_root, &sb)) { + fprintf(stderr, "Directory or script %s does not exist.\n", document_root); + return 1; + } + } else { + document_root = "."; + } + + if (argc > php_optind) { + router = argv[php_optind]; + } + + if (FAILURE == php_cli_server_ctor(&server, server_bind_address, document_root, router TSRMLS_CC)) { + return 1; + } + sapi_module.phpinfo_as_text = 0; + + printf("Server is listening on %s:%d in %s ... Press CTRL-C to quit.\n", server.host, server.port, document_root); + +#if defined(HAVE_SIGNAL_H) && defined(SIGINT) + signal(SIGINT, php_cli_server_sigint_handler); +#endif + php_cli_server_do_event_loop(&server TSRMLS_CC); + php_cli_server_dtor(&server TSRMLS_CC); + return 0; +} /* }}} */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/sapi/cli/php_cli_server.h b/sapi/cli/php_cli_server.h new file mode 100644 index 0000000000000..8f9add0e5028c --- /dev/null +++ b/sapi/cli/php_cli_server.h @@ -0,0 +1,38 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2011 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Moriyoshi Koizumi | + +----------------------------------------------------------------------+ +*/ + +/* $Id: php_cli.c 306938 2011-01-01 02:17:06Z felipe $ */ + +#ifndef PHP_CLI_SERVER_H +#define PHP_CLI_SERVER_H + +#include "SAPI.h" + +extern sapi_module_struct cli_server_sapi_module; +extern int do_cli_server(int argc, char **argv TSRMLS_DC); + +#endif /* PHP_CLI_SERVER_H */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/sapi/cli/php_http_parser.c b/sapi/cli/php_http_parser.c new file mode 100644 index 0000000000000..5d5e44e3e551f --- /dev/null +++ b/sapi/cli/php_http_parser.c @@ -0,0 +1,1602 @@ +/* Copyright 2009,2010 Ryan Dahl + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to + * deal in the Software without restriction, including without limitation the + * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + * sell copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + * IN THE SOFTWARE. + */ +#include +#include +#include "php_http_parser.h" + + +#ifndef MIN +# define MIN(a,b) ((a) < (b) ? (a) : (b)) +#endif + + +#define CALLBACK2(FOR) \ +do { \ + if (settings->on_##FOR) { \ + if (0 != settings->on_##FOR(parser)) return (p - data); \ + } \ +} while (0) + + +#define MARK(FOR) \ +do { \ + FOR##_mark = p; \ +} while (0) + +#define CALLBACK_NOCLEAR(FOR) \ +do { \ + if (FOR##_mark) { \ + if (settings->on_##FOR) { \ + if (0 != settings->on_##FOR(parser, \ + FOR##_mark, \ + p - FOR##_mark)) \ + { \ + return (p - data); \ + } \ + } \ + } \ +} while (0) + + +#define CALLBACK(FOR) \ +do { \ + CALLBACK_NOCLEAR(FOR); \ + FOR##_mark = NULL; \ +} while (0) + + +#define PROXY_CONNECTION "proxy-connection" +#define CONNECTION "connection" +#define CONTENT_LENGTH "content-length" +#define TRANSFER_ENCODING "transfer-encoding" +#define UPGRADE "upgrade" +#define CHUNKED "chunked" +#define KEEP_ALIVE "keep-alive" +#define CLOSE "close" + + +static const char *method_strings[] = + { "DELETE" + , "GET" + , "HEAD" + , "POST" + , "PUT" + , "CONNECT" + , "OPTIONS" + , "TRACE" + , "COPY" + , "LOCK" + , "MKCOL" + , "MOVE" + , "PROPFIND" + , "PROPPATCH" + , "UNLOCK" + , "REPORT" + , "MKACTIVITY" + , "CHECKOUT" + , "MERGE" + , "M-SEARCH" + , "NOTIFY" + , "SUBSCRIBE" + , "UNSUBSCRIBE" + }; + + +/* Tokens as defined by rfc 2616. Also lowercases them. + * token = 1* + * separators = "(" | ")" | "<" | ">" | "@" + * | "," | ";" | ":" | "\" | <"> + * | "/" | "[" | "]" | "?" | "=" + * | "{" | "}" | SP | HT + */ +static const char tokens[256] = { +/* 0 nul 1 soh 2 stx 3 etx 4 eot 5 enq 6 ack 7 bel */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 8 bs 9 ht 10 nl 11 vt 12 np 13 cr 14 so 15 si */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 16 dle 17 dc1 18 dc2 19 dc3 20 dc4 21 nak 22 syn 23 etb */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 24 can 25 em 26 sub 27 esc 28 fs 29 gs 30 rs 31 us */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 32 sp 33 ! 34 " 35 # 36 $ 37 % 38 & 39 ' */ + ' ', '!', '"', '#', '$', '%', '&', '\'', +/* 40 ( 41 ) 42 * 43 + 44 , 45 - 46 . 47 / */ + 0, 0, '*', '+', 0, '-', '.', '/', +/* 48 0 49 1 50 2 51 3 52 4 53 5 54 6 55 7 */ + '0', '1', '2', '3', '4', '5', '6', '7', +/* 56 8 57 9 58 : 59 ; 60 < 61 = 62 > 63 ? */ + '8', '9', 0, 0, 0, 0, 0, 0, +/* 64 @ 65 A 66 B 67 C 68 D 69 E 70 F 71 G */ + 0, 'a', 'b', 'c', 'd', 'e', 'f', 'g', +/* 72 H 73 I 74 J 75 K 76 L 77 M 78 N 79 O */ + 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', +/* 80 P 81 Q 82 R 83 S 84 T 85 U 86 V 87 W */ + 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', +/* 88 X 89 Y 90 Z 91 [ 92 \ 93 ] 94 ^ 95 _ */ + 'x', 'y', 'z', 0, 0, 0, '^', '_', +/* 96 ` 97 a 98 b 99 c 100 d 101 e 102 f 103 g */ + '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g', +/* 104 h 105 i 106 j 107 k 108 l 109 m 110 n 111 o */ + 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', +/* 112 p 113 q 114 r 115 s 116 t 117 u 118 v 119 w */ + 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', +/* 120 x 121 y 122 z 123 { 124 | 125 } 126 ~ 127 del */ + 'x', 'y', 'z', 0, '|', '}', '~', 0 }; + + +static const int8_t unhex[256] = + {-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1 + ,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1 + ,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1 + , 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,-1,-1,-1,-1,-1,-1 + ,-1,10,11,12,13,14,15,-1,-1,-1,-1,-1,-1,-1,-1,-1 + ,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1 + ,-1,10,11,12,13,14,15,-1,-1,-1,-1,-1,-1,-1,-1,-1 + ,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1 + }; + + +static const uint8_t normal_url_char[256] = { +/* 0 nul 1 soh 2 stx 3 etx 4 eot 5 enq 6 ack 7 bel */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 8 bs 9 ht 10 nl 11 vt 12 np 13 cr 14 so 15 si */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 16 dle 17 dc1 18 dc2 19 dc3 20 dc4 21 nak 22 syn 23 etb */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 24 can 25 em 26 sub 27 esc 28 fs 29 gs 30 rs 31 us */ + 0, 0, 0, 0, 0, 0, 0, 0, +/* 32 sp 33 ! 34 " 35 # 36 $ 37 % 38 & 39 ' */ + 0, 1, 1, 0, 1, 1, 1, 1, +/* 40 ( 41 ) 42 * 43 + 44 , 45 - 46 . 47 / */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 48 0 49 1 50 2 51 3 52 4 53 5 54 6 55 7 */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 56 8 57 9 58 : 59 ; 60 < 61 = 62 > 63 ? */ + 1, 1, 1, 1, 1, 1, 1, 0, +/* 64 @ 65 A 66 B 67 C 68 D 69 E 70 F 71 G */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 72 H 73 I 74 J 75 K 76 L 77 M 78 N 79 O */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 80 P 81 Q 82 R 83 S 84 T 85 U 86 V 87 W */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 88 X 89 Y 90 Z 91 [ 92 \ 93 ] 94 ^ 95 _ */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 96 ` 97 a 98 b 99 c 100 d 101 e 102 f 103 g */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 104 h 105 i 106 j 107 k 108 l 109 m 110 n 111 o */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 112 p 113 q 114 r 115 s 116 t 117 u 118 v 119 w */ + 1, 1, 1, 1, 1, 1, 1, 1, +/* 120 x 121 y 122 z 123 { 124 | 125 } 126 ~ 127 del */ + 1, 1, 1, 1, 1, 1, 1, 0 }; + + +enum state + { s_dead = 1 /* important that this is > 0 */ + + , s_start_req_or_res + , s_res_or_resp_H + , s_start_res + , s_res_H + , s_res_HT + , s_res_HTT + , s_res_HTTP + , s_res_first_http_major + , s_res_http_major + , s_res_first_http_minor + , s_res_http_minor + , s_res_first_status_code + , s_res_status_code + , s_res_status + , s_res_line_almost_done + + , s_start_req + + , s_req_method + , s_req_spaces_before_url + , s_req_schema + , s_req_schema_slash + , s_req_schema_slash_slash + , s_req_host + , s_req_port + , s_req_path + , s_req_query_string_start + , s_req_query_string + , s_req_fragment_start + , s_req_fragment + , s_req_http_start + , s_req_http_H + , s_req_http_HT + , s_req_http_HTT + , s_req_http_HTTP + , s_req_first_http_major + , s_req_http_major + , s_req_first_http_minor + , s_req_http_minor + , s_req_line_almost_done + + , s_header_field_start + , s_header_field + , s_header_value_start + , s_header_value + + , s_header_almost_done + + , s_headers_almost_done + /* Important: 's_headers_almost_done' must be the last 'header' state. All + * states beyond this must be 'body' states. It is used for overflow + * checking. See the PARSING_HEADER() macro. + */ + , s_chunk_size_start + , s_chunk_size + , s_chunk_size_almost_done + , s_chunk_parameters + , s_chunk_data + , s_chunk_data_almost_done + , s_chunk_data_done + + , s_body_identity + , s_body_identity_eof + }; + + +#define PARSING_HEADER(state) (state <= s_headers_almost_done && 0 == (parser->flags & F_TRAILING)) + + +enum header_states + { h_general = 0 + , h_C + , h_CO + , h_CON + + , h_matching_connection + , h_matching_proxy_connection + , h_matching_content_length + , h_matching_transfer_encoding + , h_matching_upgrade + + , h_connection + , h_content_length + , h_transfer_encoding + , h_upgrade + + , h_matching_transfer_encoding_chunked + , h_matching_connection_keep_alive + , h_matching_connection_close + + , h_transfer_encoding_chunked + , h_connection_keep_alive + , h_connection_close + }; + + +enum flags + { F_CHUNKED = 1 << 0 + , F_CONNECTION_KEEP_ALIVE = 1 << 1 + , F_CONNECTION_CLOSE = 1 << 2 + , F_TRAILING = 1 << 3 + , F_UPGRADE = 1 << 4 + , F_SKIPBODY = 1 << 5 + }; + + +#define CR '\r' +#define LF '\n' +#define LOWER(c) (unsigned char)(c | 0x20) +#define TOKEN(c) tokens[(unsigned char)c] + + +#define start_state (parser->type == PHP_HTTP_REQUEST ? s_start_req : s_start_res) + + +#if HTTP_PARSER_STRICT +# define STRICT_CHECK(cond) if (cond) goto error +# define NEW_MESSAGE() (http_should_keep_alive(parser) ? start_state : s_dead) +#else +# define STRICT_CHECK(cond) +# define NEW_MESSAGE() start_state +#endif + + +size_t php_http_parser_execute (php_http_parser *parser, + const php_http_parser_settings *settings, + const char *data, + size_t len) +{ + char c, ch; + const char *p = data, *pe; + int64_t to_read; + + enum state state = (enum state) parser->state; + enum header_states header_state = (enum header_states) parser->header_state; + uint64_t index = parser->index; + uint64_t nread = parser->nread; + + /* technically we could combine all of these (except for url_mark) into one + variable, saving stack space, but it seems more clear to have them + separated. */ + const char *header_field_mark = 0; + const char *header_value_mark = 0; + const char *fragment_mark = 0; + const char *query_string_mark = 0; + const char *path_mark = 0; + const char *url_mark = 0; + + if (len == 0) { + if (state == s_body_identity_eof) { + CALLBACK2(message_complete); + } + return 0; + } + + if (state == s_header_field) + header_field_mark = data; + if (state == s_header_value) + header_value_mark = data; + if (state == s_req_fragment) + fragment_mark = data; + if (state == s_req_query_string) + query_string_mark = data; + if (state == s_req_path) + path_mark = data; + if (state == s_req_path || state == s_req_schema || state == s_req_schema_slash + || state == s_req_schema_slash_slash || state == s_req_port + || state == s_req_query_string_start || state == s_req_query_string + || state == s_req_host + || state == s_req_fragment_start || state == s_req_fragment) + url_mark = data; + + for (p=data, pe=data+len; p != pe; p++) { + ch = *p; + + if (PARSING_HEADER(state)) { + ++nread; + /* Buffer overflow attack */ + if (nread > PHP_HTTP_MAX_HEADER_SIZE) goto error; + } + + switch (state) { + + case s_dead: + /* this state is used after a 'Connection: close' message + * the parser will error out if it reads another message + */ + goto error; + + case s_start_req_or_res: + { + if (ch == CR || ch == LF) + break; + parser->flags = 0; + parser->content_length = -1; + + CALLBACK2(message_begin); + + if (ch == 'H') + state = s_res_or_resp_H; + else { + parser->type = PHP_HTTP_REQUEST; + goto start_req_method_assign; + } + break; + } + + case s_res_or_resp_H: + if (ch == 'T') { + parser->type = PHP_HTTP_RESPONSE; + state = s_res_HT; + } else { + if (ch != 'E') goto error; + parser->type = PHP_HTTP_REQUEST; + parser->method = PHP_HTTP_HEAD; + index = 2; + state = s_req_method; + } + break; + + case s_start_res: + { + parser->flags = 0; + parser->content_length = -1; + + CALLBACK2(message_begin); + + switch (ch) { + case 'H': + state = s_res_H; + break; + + case CR: + case LF: + break; + + default: + goto error; + } + break; + } + + case s_res_H: + STRICT_CHECK(ch != 'T'); + state = s_res_HT; + break; + + case s_res_HT: + STRICT_CHECK(ch != 'T'); + state = s_res_HTT; + break; + + case s_res_HTT: + STRICT_CHECK(ch != 'P'); + state = s_res_HTTP; + break; + + case s_res_HTTP: + STRICT_CHECK(ch != '/'); + state = s_res_first_http_major; + break; + + case s_res_first_http_major: + if (ch < '1' || ch > '9') goto error; + parser->http_major = ch - '0'; + state = s_res_http_major; + break; + + /* major HTTP version or dot */ + case s_res_http_major: + { + if (ch == '.') { + state = s_res_first_http_minor; + break; + } + + if (ch < '0' || ch > '9') goto error; + + parser->http_major *= 10; + parser->http_major += ch - '0'; + + if (parser->http_major > 999) goto error; + break; + } + + /* first digit of minor HTTP version */ + case s_res_first_http_minor: + if (ch < '0' || ch > '9') goto error; + parser->http_minor = ch - '0'; + state = s_res_http_minor; + break; + + /* minor HTTP version or end of request line */ + case s_res_http_minor: + { + if (ch == ' ') { + state = s_res_first_status_code; + break; + } + + if (ch < '0' || ch > '9') goto error; + + parser->http_minor *= 10; + parser->http_minor += ch - '0'; + + if (parser->http_minor > 999) goto error; + break; + } + + case s_res_first_status_code: + { + if (ch < '0' || ch > '9') { + if (ch == ' ') { + break; + } + goto error; + } + parser->status_code = ch - '0'; + state = s_res_status_code; + break; + } + + case s_res_status_code: + { + if (ch < '0' || ch > '9') { + switch (ch) { + case ' ': + state = s_res_status; + break; + case CR: + state = s_res_line_almost_done; + break; + case LF: + state = s_header_field_start; + break; + default: + goto error; + } + break; + } + + parser->status_code *= 10; + parser->status_code += ch - '0'; + + if (parser->status_code > 999) goto error; + break; + } + + case s_res_status: + /* the human readable status. e.g. "NOT FOUND" + * we are not humans so just ignore this */ + if (ch == CR) { + state = s_res_line_almost_done; + break; + } + + if (ch == LF) { + state = s_header_field_start; + break; + } + break; + + case s_res_line_almost_done: + STRICT_CHECK(ch != LF); + state = s_header_field_start; + break; + + case s_start_req: + { + if (ch == CR || ch == LF) + break; + parser->flags = 0; + parser->content_length = -1; + + CALLBACK2(message_begin); + + if (ch < 'A' || 'Z' < ch) goto error; + + start_req_method_assign: + parser->method = (enum php_http_method) 0; + index = 1; + switch (ch) { + case 'C': parser->method = PHP_HTTP_CONNECT; /* or COPY, CHECKOUT */ break; + case 'D': parser->method = PHP_HTTP_DELETE; break; + case 'G': parser->method = PHP_HTTP_GET; break; + case 'H': parser->method = PHP_HTTP_HEAD; break; + case 'L': parser->method = PHP_HTTP_LOCK; break; + case 'M': parser->method = PHP_HTTP_MKCOL; /* or MOVE, MKACTIVITY, MERGE, M-SEARCH */ break; + case 'N': parser->method = PHP_HTTP_NOTIFY; break; + case 'O': parser->method = PHP_HTTP_OPTIONS; break; + case 'P': parser->method = PHP_HTTP_POST; /* or PROPFIND or PROPPATCH or PUT */ break; + case 'R': parser->method = PHP_HTTP_REPORT; break; + case 'S': parser->method = PHP_HTTP_SUBSCRIBE; break; + case 'T': parser->method = PHP_HTTP_TRACE; break; + case 'U': parser->method = PHP_HTTP_UNLOCK; /* or UNSUBSCRIBE */ break; + default: goto error; + } + state = s_req_method; + break; + } + + case s_req_method: + { + const char *matcher; + if (ch == '\0') + goto error; + + matcher = method_strings[parser->method]; + if (ch == ' ' && matcher[index] == '\0') { + state = s_req_spaces_before_url; + } else if (ch == matcher[index]) { + ; /* nada */ + } else if (parser->method == PHP_HTTP_CONNECT) { + if (index == 1 && ch == 'H') { + parser->method = PHP_HTTP_CHECKOUT; + } else if (index == 2 && ch == 'P') { + parser->method = PHP_HTTP_COPY; + } + } else if (parser->method == PHP_HTTP_MKCOL) { + if (index == 1 && ch == 'O') { + parser->method = PHP_HTTP_MOVE; + } else if (index == 1 && ch == 'E') { + parser->method = PHP_HTTP_MERGE; + } else if (index == 1 && ch == '-') { + parser->method = PHP_HTTP_MSEARCH; + } else if (index == 2 && ch == 'A') { + parser->method = PHP_HTTP_MKACTIVITY; + } + } else if (index == 1 && parser->method == PHP_HTTP_POST && ch == 'R') { + parser->method = PHP_HTTP_PROPFIND; /* or HTTP_PROPPATCH */ + } else if (index == 1 && parser->method == PHP_HTTP_POST && ch == 'U') { + parser->method = PHP_HTTP_PUT; + } else if (index == 2 && parser->method == PHP_HTTP_UNLOCK && ch == 'S') { + parser->method = PHP_HTTP_UNSUBSCRIBE; + } else if (index == 4 && parser->method == PHP_HTTP_PROPFIND && ch == 'P') { + parser->method = PHP_HTTP_PROPPATCH; + } else { + goto error; + } + + ++index; + break; + } + case s_req_spaces_before_url: + { + if (ch == ' ') break; + + if (ch == '/' || ch == '*') { + MARK(url); + MARK(path); + state = s_req_path; + break; + } + + c = LOWER(ch); + + if (c >= 'a' && c <= 'z') { + MARK(url); + state = s_req_schema; + break; + } + + goto error; + } + + case s_req_schema: + { + c = LOWER(ch); + + if (c >= 'a' && c <= 'z') break; + + if (ch == ':') { + state = s_req_schema_slash; + break; + } else if (ch == '.') { + state = s_req_host; + break; + } else if ('0' <= ch && ch <= '9') { + state = s_req_host; + break; + } + + goto error; + } + + case s_req_schema_slash: + STRICT_CHECK(ch != '/'); + state = s_req_schema_slash_slash; + break; + + case s_req_schema_slash_slash: + STRICT_CHECK(ch != '/'); + state = s_req_host; + break; + + case s_req_host: + { + c = LOWER(ch); + if (c >= 'a' && c <= 'z') break; + if ((ch >= '0' && ch <= '9') || ch == '.' || ch == '-') break; + switch (ch) { + case ':': + state = s_req_port; + break; + case '/': + MARK(path); + state = s_req_path; + break; + case ' ': + /* The request line looks like: + * "GET http://foo.bar.com HTTP/1.1" + * That is, there is no path. + */ + CALLBACK(url); + state = s_req_http_start; + break; + default: + goto error; + } + break; + } + + case s_req_port: + { + if (ch >= '0' && ch <= '9') break; + switch (ch) { + case '/': + MARK(path); + state = s_req_path; + break; + case ' ': + /* The request line looks like: + * "GET http://foo.bar.com:1234 HTTP/1.1" + * That is, there is no path. + */ + CALLBACK(url); + state = s_req_http_start; + break; + default: + goto error; + } + break; + } + + case s_req_path: + { + if (normal_url_char[(unsigned char)ch]) break; + + switch (ch) { + case ' ': + CALLBACK(url); + CALLBACK(path); + state = s_req_http_start; + break; + case CR: + CALLBACK(url); + CALLBACK(path); + parser->http_major = 0; + parser->http_minor = 9; + state = s_req_line_almost_done; + break; + case LF: + CALLBACK(url); + CALLBACK(path); + parser->http_major = 0; + parser->http_minor = 9; + state = s_header_field_start; + break; + case '?': + CALLBACK(path); + state = s_req_query_string_start; + break; + case '#': + CALLBACK(path); + state = s_req_fragment_start; + break; + default: + goto error; + } + break; + } + + case s_req_query_string_start: + { + if (normal_url_char[(unsigned char)ch]) { + MARK(query_string); + state = s_req_query_string; + break; + } + + switch (ch) { + case '?': + break; /* XXX ignore extra '?' ... is this right? */ + case ' ': + CALLBACK(url); + state = s_req_http_start; + break; + case CR: + CALLBACK(url); + parser->http_major = 0; + parser->http_minor = 9; + state = s_req_line_almost_done; + break; + case LF: + CALLBACK(url); + parser->http_major = 0; + parser->http_minor = 9; + state = s_header_field_start; + break; + case '#': + state = s_req_fragment_start; + break; + default: + goto error; + } + break; + } + + case s_req_query_string: + { + if (normal_url_char[(unsigned char)ch]) break; + + switch (ch) { + case '?': + /* allow extra '?' in query string */ + break; + case ' ': + CALLBACK(url); + CALLBACK(query_string); + state = s_req_http_start; + break; + case CR: + CALLBACK(url); + CALLBACK(query_string); + parser->http_major = 0; + parser->http_minor = 9; + state = s_req_line_almost_done; + break; + case LF: + CALLBACK(url); + CALLBACK(query_string); + parser->http_major = 0; + parser->http_minor = 9; + state = s_header_field_start; + break; + case '#': + CALLBACK(query_string); + state = s_req_fragment_start; + break; + default: + goto error; + } + break; + } + + case s_req_fragment_start: + { + if (normal_url_char[(unsigned char)ch]) { + MARK(fragment); + state = s_req_fragment; + break; + } + + switch (ch) { + case ' ': + CALLBACK(url); + state = s_req_http_start; + break; + case CR: + CALLBACK(url); + parser->http_major = 0; + parser->http_minor = 9; + state = s_req_line_almost_done; + break; + case LF: + CALLBACK(url); + parser->http_major = 0; + parser->http_minor = 9; + state = s_header_field_start; + break; + case '?': + MARK(fragment); + state = s_req_fragment; + break; + case '#': + break; + default: + goto error; + } + break; + } + + case s_req_fragment: + { + if (normal_url_char[(unsigned char)ch]) break; + + switch (ch) { + case ' ': + CALLBACK(url); + CALLBACK(fragment); + state = s_req_http_start; + break; + case CR: + CALLBACK(url); + CALLBACK(fragment); + parser->http_major = 0; + parser->http_minor = 9; + state = s_req_line_almost_done; + break; + case LF: + CALLBACK(url); + CALLBACK(fragment); + parser->http_major = 0; + parser->http_minor = 9; + state = s_header_field_start; + break; + case '?': + case '#': + break; + default: + goto error; + } + break; + } + + case s_req_http_start: + switch (ch) { + case 'H': + state = s_req_http_H; + break; + case ' ': + break; + default: + goto error; + } + break; + + case s_req_http_H: + STRICT_CHECK(ch != 'T'); + state = s_req_http_HT; + break; + + case s_req_http_HT: + STRICT_CHECK(ch != 'T'); + state = s_req_http_HTT; + break; + + case s_req_http_HTT: + STRICT_CHECK(ch != 'P'); + state = s_req_http_HTTP; + break; + + case s_req_http_HTTP: + STRICT_CHECK(ch != '/'); + state = s_req_first_http_major; + break; + + /* first digit of major HTTP version */ + case s_req_first_http_major: + if (ch < '1' || ch > '9') goto error; + parser->http_major = ch - '0'; + state = s_req_http_major; + break; + + /* major HTTP version or dot */ + case s_req_http_major: + { + if (ch == '.') { + state = s_req_first_http_minor; + break; + } + + if (ch < '0' || ch > '9') goto error; + + parser->http_major *= 10; + parser->http_major += ch - '0'; + + if (parser->http_major > 999) goto error; + break; + } + + /* first digit of minor HTTP version */ + case s_req_first_http_minor: + if (ch < '0' || ch > '9') goto error; + parser->http_minor = ch - '0'; + state = s_req_http_minor; + break; + + /* minor HTTP version or end of request line */ + case s_req_http_minor: + { + if (ch == CR) { + state = s_req_line_almost_done; + break; + } + + if (ch == LF) { + state = s_header_field_start; + break; + } + + /* XXX allow spaces after digit? */ + + if (ch < '0' || ch > '9') goto error; + + parser->http_minor *= 10; + parser->http_minor += ch - '0'; + + if (parser->http_minor > 999) goto error; + break; + } + + /* end of request line */ + case s_req_line_almost_done: + { + if (ch != LF) goto error; + state = s_header_field_start; + break; + } + + case s_header_field_start: + { + if (ch == CR) { + state = s_headers_almost_done; + break; + } + + if (ch == LF) { + /* they might be just sending \n instead of \r\n so this would be + * the second \n to denote the end of headers*/ + state = s_headers_almost_done; + goto headers_almost_done; + } + + c = TOKEN(ch); + + if (!c) goto error; + + MARK(header_field); + + index = 0; + state = s_header_field; + + switch (c) { + case 'c': + header_state = h_C; + break; + + case 'p': + header_state = h_matching_proxy_connection; + break; + + case 't': + header_state = h_matching_transfer_encoding; + break; + + case 'u': + header_state = h_matching_upgrade; + break; + + default: + header_state = h_general; + break; + } + break; + } + + case s_header_field: + { + c = TOKEN(ch); + + if (c) { + switch (header_state) { + case h_general: + break; + + case h_C: + index++; + header_state = (c == 'o' ? h_CO : h_general); + break; + + case h_CO: + index++; + header_state = (c == 'n' ? h_CON : h_general); + break; + + case h_CON: + index++; + switch (c) { + case 'n': + header_state = h_matching_connection; + break; + case 't': + header_state = h_matching_content_length; + break; + default: + header_state = h_general; + break; + } + break; + + /* connection */ + + case h_matching_connection: + index++; + if (index > sizeof(CONNECTION)-1 + || c != CONNECTION[index]) { + header_state = h_general; + } else if (index == sizeof(CONNECTION)-2) { + header_state = h_connection; + } + break; + + /* proxy-connection */ + + case h_matching_proxy_connection: + index++; + if (index > sizeof(PROXY_CONNECTION)-1 + || c != PROXY_CONNECTION[index]) { + header_state = h_general; + } else if (index == sizeof(PROXY_CONNECTION)-2) { + header_state = h_connection; + } + break; + + /* content-length */ + + case h_matching_content_length: + index++; + if (index > sizeof(CONTENT_LENGTH)-1 + || c != CONTENT_LENGTH[index]) { + header_state = h_general; + } else if (index == sizeof(CONTENT_LENGTH)-2) { + header_state = h_content_length; + } + break; + + /* transfer-encoding */ + + case h_matching_transfer_encoding: + index++; + if (index > sizeof(TRANSFER_ENCODING)-1 + || c != TRANSFER_ENCODING[index]) { + header_state = h_general; + } else if (index == sizeof(TRANSFER_ENCODING)-2) { + header_state = h_transfer_encoding; + } + break; + + /* upgrade */ + + case h_matching_upgrade: + index++; + if (index > sizeof(UPGRADE)-1 + || c != UPGRADE[index]) { + header_state = h_general; + } else if (index == sizeof(UPGRADE)-2) { + header_state = h_upgrade; + } + break; + + case h_connection: + case h_content_length: + case h_transfer_encoding: + case h_upgrade: + if (ch != ' ') header_state = h_general; + break; + + default: + assert(0 && "Unknown header_state"); + break; + } + break; + } + + if (ch == ':') { + CALLBACK(header_field); + state = s_header_value_start; + break; + } + + if (ch == CR) { + state = s_header_almost_done; + CALLBACK(header_field); + break; + } + + if (ch == LF) { + CALLBACK(header_field); + state = s_header_field_start; + break; + } + + goto error; + } + + case s_header_value_start: + { + if (ch == ' ') break; + + MARK(header_value); + + state = s_header_value; + index = 0; + + c = LOWER(ch); + + if (ch == CR) { + CALLBACK(header_value); + header_state = h_general; + state = s_header_almost_done; + break; + } + + if (ch == LF) { + CALLBACK(header_value); + state = s_header_field_start; + break; + } + + switch (header_state) { + case h_upgrade: + parser->flags |= F_UPGRADE; + header_state = h_general; + break; + + case h_transfer_encoding: + /* looking for 'Transfer-Encoding: chunked' */ + if ('c' == c) { + header_state = h_matching_transfer_encoding_chunked; + } else { + header_state = h_general; + } + break; + + case h_content_length: + if (ch < '0' || ch > '9') goto error; + parser->content_length = ch - '0'; + break; + + case h_connection: + /* looking for 'Connection: keep-alive' */ + if (c == 'k') { + header_state = h_matching_connection_keep_alive; + /* looking for 'Connection: close' */ + } else if (c == 'c') { + header_state = h_matching_connection_close; + } else { + header_state = h_general; + } + break; + + default: + header_state = h_general; + break; + } + break; + } + + case s_header_value: + { + c = LOWER(ch); + + if (ch == CR) { + CALLBACK(header_value); + state = s_header_almost_done; + break; + } + + if (ch == LF) { + CALLBACK(header_value); + goto header_almost_done; + } + + switch (header_state) { + case h_general: + break; + + case h_connection: + case h_transfer_encoding: + assert(0 && "Shouldn't get here."); + break; + + case h_content_length: + if (ch == ' ') break; + if (ch < '0' || ch > '9') goto error; + parser->content_length *= 10; + parser->content_length += ch - '0'; + break; + + /* Transfer-Encoding: chunked */ + case h_matching_transfer_encoding_chunked: + index++; + if (index > sizeof(CHUNKED)-1 + || c != CHUNKED[index]) { + header_state = h_general; + } else if (index == sizeof(CHUNKED)-2) { + header_state = h_transfer_encoding_chunked; + } + break; + + /* looking for 'Connection: keep-alive' */ + case h_matching_connection_keep_alive: + index++; + if (index > sizeof(KEEP_ALIVE)-1 + || c != KEEP_ALIVE[index]) { + header_state = h_general; + } else if (index == sizeof(KEEP_ALIVE)-2) { + header_state = h_connection_keep_alive; + } + break; + + /* looking for 'Connection: close' */ + case h_matching_connection_close: + index++; + if (index > sizeof(CLOSE)-1 || c != CLOSE[index]) { + header_state = h_general; + } else if (index == sizeof(CLOSE)-2) { + header_state = h_connection_close; + } + break; + + case h_transfer_encoding_chunked: + case h_connection_keep_alive: + case h_connection_close: + if (ch != ' ') header_state = h_general; + break; + + default: + state = s_header_value; + header_state = h_general; + break; + } + break; + } + + case s_header_almost_done: + header_almost_done: + { + STRICT_CHECK(ch != LF); + + state = s_header_field_start; + + switch (header_state) { + case h_connection_keep_alive: + parser->flags |= F_CONNECTION_KEEP_ALIVE; + break; + case h_connection_close: + parser->flags |= F_CONNECTION_CLOSE; + break; + case h_transfer_encoding_chunked: + parser->flags |= F_CHUNKED; + break; + default: + break; + } + break; + } + + case s_headers_almost_done: + headers_almost_done: + { + STRICT_CHECK(ch != LF); + + if (parser->flags & F_TRAILING) { + /* End of a chunked request */ + CALLBACK2(message_complete); + state = NEW_MESSAGE(); + break; + } + + nread = 0; + + if (parser->flags & F_UPGRADE || parser->method == PHP_HTTP_CONNECT) { + parser->upgrade = 1; + } + + /* Here we call the headers_complete callback. This is somewhat + * different than other callbacks because if the user returns 1, we + * will interpret that as saying that this message has no body. This + * is needed for the annoying case of recieving a response to a HEAD + * request. + */ + if (settings->on_headers_complete) { + switch (settings->on_headers_complete(parser)) { + case 0: + break; + + case 1: + parser->flags |= F_SKIPBODY; + break; + + default: + return p - data; /* Error */ + } + } + + /* Exit, the rest of the connect is in a different protocol. */ + if (parser->upgrade) { + CALLBACK2(message_complete); + return (p - data); + } + + if (parser->flags & F_SKIPBODY) { + CALLBACK2(message_complete); + state = NEW_MESSAGE(); + } else if (parser->flags & F_CHUNKED) { + /* chunked encoding - ignore Content-Length header */ + state = s_chunk_size_start; + } else { + if (parser->content_length == 0) { + /* Content-Length header given but zero: Content-Length: 0\r\n */ + CALLBACK2(message_complete); + state = NEW_MESSAGE(); + } else if (parser->content_length > 0) { + /* Content-Length header given and non-zero */ + state = s_body_identity; + } else { + if (parser->type == PHP_HTTP_REQUEST || php_http_should_keep_alive(parser)) { + /* Assume content-length 0 - read the next */ + CALLBACK2(message_complete); + state = NEW_MESSAGE(); + } else { + /* Read body until EOF */ + state = s_body_identity_eof; + } + } + } + + break; + } + + case s_body_identity: + to_read = MIN(pe - p, (int64_t)parser->content_length); + if (to_read > 0) { + if (settings->on_body) settings->on_body(parser, p, to_read); + p += to_read - 1; + parser->content_length -= to_read; + if (parser->content_length == 0) { + CALLBACK2(message_complete); + state = NEW_MESSAGE(); + } + } + break; + + /* read until EOF */ + case s_body_identity_eof: + to_read = pe - p; + if (to_read > 0) { + if (settings->on_body) settings->on_body(parser, p, to_read); + p += to_read - 1; + } + break; + + case s_chunk_size_start: + { + assert(parser->flags & F_CHUNKED); + + c = unhex[(unsigned char)ch]; + if (c == -1) goto error; + parser->content_length = c; + state = s_chunk_size; + break; + } + + case s_chunk_size: + { + assert(parser->flags & F_CHUNKED); + + if (ch == CR) { + state = s_chunk_size_almost_done; + break; + } + + c = unhex[(unsigned char)ch]; + + if (c == -1) { + if (ch == ';' || ch == ' ') { + state = s_chunk_parameters; + break; + } + goto error; + } + + parser->content_length *= 16; + parser->content_length += c; + break; + } + + case s_chunk_parameters: + { + assert(parser->flags & F_CHUNKED); + /* just ignore this shit. TODO check for overflow */ + if (ch == CR) { + state = s_chunk_size_almost_done; + break; + } + break; + } + + case s_chunk_size_almost_done: + { + assert(parser->flags & F_CHUNKED); + STRICT_CHECK(ch != LF); + + if (parser->content_length == 0) { + parser->flags |= F_TRAILING; + state = s_header_field_start; + } else { + state = s_chunk_data; + } + break; + } + + case s_chunk_data: + { + assert(parser->flags & F_CHUNKED); + + to_read = MIN(pe - p, (int64_t)(parser->content_length)); + + if (to_read > 0) { + if (settings->on_body) settings->on_body(parser, p, to_read); + p += to_read - 1; + } + + if (to_read == parser->content_length) { + state = s_chunk_data_almost_done; + } + + parser->content_length -= to_read; + break; + } + + case s_chunk_data_almost_done: + assert(parser->flags & F_CHUNKED); + STRICT_CHECK(ch != CR); + state = s_chunk_data_done; + break; + + case s_chunk_data_done: + assert(parser->flags & F_CHUNKED); + STRICT_CHECK(ch != LF); + state = s_chunk_size_start; + break; + + default: + assert(0 && "unhandled state"); + goto error; + } + } + + CALLBACK_NOCLEAR(header_field); + CALLBACK_NOCLEAR(header_value); + CALLBACK_NOCLEAR(fragment); + CALLBACK_NOCLEAR(query_string); + CALLBACK_NOCLEAR(path); + CALLBACK_NOCLEAR(url); + + parser->state = state; + parser->header_state = header_state; + parser->index = index; + parser->nread = nread; + + return len; + +error: + parser->state = s_dead; + return (p - data); +} + + +int +php_http_should_keep_alive (php_http_parser *parser) +{ + if (parser->http_major > 0 && parser->http_minor > 0) { + /* HTTP/1.1 */ + if (parser->flags & F_CONNECTION_CLOSE) { + return 0; + } else { + return 1; + } + } else { + /* HTTP/1.0 or earlier */ + if (parser->flags & F_CONNECTION_KEEP_ALIVE) { + return 1; + } else { + return 0; + } + } +} + + +const char * php_http_method_str (enum php_http_method m) +{ + return method_strings[m]; +} + + +void +php_http_parser_init (php_http_parser *parser, enum php_http_parser_type t) +{ + parser->type = t; + parser->state = (t == PHP_HTTP_REQUEST ? s_start_req : (t == PHP_HTTP_RESPONSE ? s_start_res : s_start_req_or_res)); + parser->nread = 0; + parser->upgrade = 0; + parser->flags = 0; + parser->method = 0; +} diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h new file mode 100644 index 0000000000000..09ec79acf8f5f --- /dev/null +++ b/sapi/cli/php_http_parser.h @@ -0,0 +1,182 @@ +/* Copyright 2009,2010 Ryan Dahl + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to + * deal in the Software without restriction, including without limitation the + * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + * sell copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + * IN THE SOFTWARE. + */ +/* modified by Moriyoshi Koizumi to make it fit to PHP source tree. */ +#ifndef php_http_parser_h +#define php_http_parser_h +#ifdef __cplusplus +extern "C" { +#endif + + +#include +#if defined(_WIN32) && !defined(__MINGW32__) +typedef __int8 int8_t; +typedef unsigned __int8 uint8_t; +typedef __int16 int16_t; +typedef unsigned __int16 uint16_t; +typedef __int32 int32_t; +typedef unsigned __int32 uint32_t; +typedef __int64 int64_t; +typedef unsigned __int64 uint64_t; + +typedef unsigned int size_t; +typedef int ssize_t; +#else +#include +#endif + +/* Compile with -DPHP_HTTP_PARSER_STRICT=0 to make less checks, but run + * faster + */ +#ifndef PHP_HTTP_PARSER_STRICT +# define PHP_HTTP_PARSER_STRICT 1 +#else +# define PHP_HTTP_PARSER_STRICT 0 +#endif + + +/* Maximium header size allowed */ +#define PHP_HTTP_MAX_HEADER_SIZE (80*1024) + + +typedef struct php_http_parser php_http_parser; +typedef struct php_http_parser_settings php_http_parser_settings; + + +/* Callbacks should return non-zero to indicate an error. The parser will + * then halt execution. + * + * The one exception is on_headers_complete. In a PHP_HTTP_RESPONSE parser + * returning '1' from on_headers_complete will tell the parser that it + * should not expect a body. This is used when receiving a response to a + * HEAD request which may contain 'Content-Length' or 'Transfer-Encoding: + * chunked' headers that indicate the presence of a body. + * + * http_data_cb does not return data chunks. It will be call arbitrarally + * many times for each string. E.G. you might get 10 callbacks for "on_path" + * each providing just a few characters more data. + */ +typedef int (*php_http_data_cb) (php_http_parser*, const char *at, size_t length); +typedef int (*php_http_cb) (php_http_parser*); + + +/* Request Methods */ +enum php_http_method + { PHP_HTTP_DELETE = 0 + , PHP_HTTP_GET + , PHP_HTTP_HEAD + , PHP_HTTP_POST + , PHP_HTTP_PUT + /* pathological */ + , PHP_HTTP_CONNECT + , PHP_HTTP_OPTIONS + , PHP_HTTP_TRACE + /* webdav */ + , PHP_HTTP_COPY + , PHP_HTTP_LOCK + , PHP_HTTP_MKCOL + , PHP_HTTP_MOVE + , PHP_HTTP_PROPFIND + , PHP_HTTP_PROPPATCH + , PHP_HTTP_UNLOCK + /* subversion */ + , PHP_HTTP_REPORT + , PHP_HTTP_MKACTIVITY + , PHP_HTTP_CHECKOUT + , PHP_HTTP_MERGE + /* upnp */ + , PHP_HTTP_MSEARCH + , PHP_HTTP_NOTIFY + , PHP_HTTP_SUBSCRIBE + , PHP_HTTP_UNSUBSCRIBE + }; + + +enum php_http_parser_type { PHP_HTTP_REQUEST, PHP_HTTP_RESPONSE, PHP_HTTP_BOTH }; + + +struct php_http_parser { + /** PRIVATE **/ + unsigned char type : 2; + unsigned char flags : 6; + unsigned char state; + unsigned char header_state; + unsigned char index; + + uint32_t nread; + int64_t content_length; + + /** READ-ONLY **/ + unsigned short http_major; + unsigned short http_minor; + unsigned short status_code; /* responses only */ + unsigned char method; /* requests only */ + + /* 1 = Upgrade header was present and the parser has exited because of that. + * 0 = No upgrade header present. + * Should be checked when http_parser_execute() returns in addition to + * error checking. + */ + char upgrade; + + /** PUBLIC **/ + void *data; /* A pointer to get hook to the "connection" or "socket" object */ +}; + + +struct php_http_parser_settings { + php_http_cb on_message_begin; + php_http_data_cb on_path; + php_http_data_cb on_query_string; + php_http_data_cb on_url; + php_http_data_cb on_fragment; + php_http_data_cb on_header_field; + php_http_data_cb on_header_value; + php_http_cb on_headers_complete; + php_http_data_cb on_body; + php_http_cb on_message_complete; +}; + + +void php_http_parser_init(php_http_parser *parser, enum php_http_parser_type type); + + +size_t php_http_parser_execute(php_http_parser *parser, + const php_http_parser_settings *settings, + const char *data, + size_t len); + + +/* If php_http_should_keep_alive() in the on_headers_complete or + * on_message_complete callback returns true, then this will be should be + * the last message on the connection. + * If you are the server, respond with the "Connection: close" header. + * If you are the client, close the connection. + */ +int php_http_should_keep_alive(php_http_parser *parser); + +/* Returns a string version of the HTTP method. */ +const char *php_http_method_str(enum php_http_method); + +#ifdef __cplusplus +} +#endif +#endif From 891acc30c09cb44f4e5f8398dd715c213c49f2d9 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Mon, 20 Jun 2011 20:30:36 +0000 Subject: [PATCH 0207/2394] - Forgot to commit these. --- main/network.c | 4 ++-- main/php_main.h | 1 + main/php_network.h | 5 +++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/main/network.c b/main/network.c index 0d7a30ca8b712..1e2f81aa12ae2 100644 --- a/main/network.c +++ b/main/network.c @@ -148,7 +148,7 @@ static const char *php_gai_strerror(int code) /* {{{ php_network_freeaddresses */ -static void php_network_freeaddresses(struct sockaddr **sal) +PHPAPI void php_network_freeaddresses(struct sockaddr **sal) { struct sockaddr **sap; @@ -163,7 +163,7 @@ static void php_network_freeaddresses(struct sockaddr **sal) /* {{{ php_network_getaddresses * Returns number of addresses, 0 for none/error */ -static int php_network_getaddresses(const char *host, int socktype, struct sockaddr ***sal, char **error_string TSRMLS_DC) +PHPAPI int php_network_getaddresses(const char *host, int socktype, struct sockaddr ***sal, char **error_string TSRMLS_DC) { struct sockaddr **sap; int n; diff --git a/main/php_main.h b/main/php_main.h index 203963a5d1670..da1aabc8f5854 100644 --- a/main/php_main.h +++ b/main/php_main.h @@ -35,6 +35,7 @@ PHPAPI void php_module_shutdown(TSRMLS_D); PHPAPI void php_module_shutdown_for_exec(void); PHPAPI int php_module_shutdown_wrapper(sapi_module_struct *sapi_globals); PHPAPI int php_request_startup_for_hook(TSRMLS_D); +PHPAPI void php_request_shutdown_for_hook(void *dummy); PHPAPI int php_register_extensions(zend_module_entry **ptr, int count TSRMLS_DC); diff --git a/main/php_network.h b/main/php_network.h index ba501cb96f5e1..a2dddbac0c9d9 100644 --- a/main/php_network.h +++ b/main/php_network.h @@ -194,10 +194,12 @@ PHPAPI void _php_emit_fd_setsize_warning(int max_fd); /* it is safe to FD_SET too many fd's under win32; the macro will simply ignore * descriptors that go beyond the default FD_SETSIZE */ # define PHP_SAFE_FD_SET(fd, set) FD_SET(fd, set) +# define PHP_SAFE_FD_CLR(fd, set) FD_CLR(fd, set) # define PHP_SAFE_FD_ISSET(fd, set) FD_ISSET(fd, set) # define PHP_SAFE_MAX_FD(m, n) do { if (n + 1 >= FD_SETSIZE) { _php_emit_fd_setsize_warning(n); }} while(0) #else # define PHP_SAFE_FD_SET(fd, set) do { if (fd < FD_SETSIZE) FD_SET(fd, set); } while(0) +# define PHP_SAFE_FD_CLR(fd, set) do { if (fd < FD_SETSIZE) FD_CLR(fd, set); } while(0) # define PHP_SAFE_FD_ISSET(fd, set) ((fd < FD_SETSIZE) && FD_ISSET(fd, set)) # define PHP_SAFE_MAX_FD(m, n) do { if (m >= FD_SETSIZE) { _php_emit_fd_setsize_warning(m); m = FD_SETSIZE - 1; }} while(0) #endif @@ -220,6 +222,9 @@ typedef struct { #endif BEGIN_EXTERN_C() +PHPAPI int php_network_getaddresses(const char *host, int socktype, struct sockaddr ***sal, char **error_string TSRMLS_DC); +PHPAPI void php_network_freeaddresses(struct sockaddr **sal); + PHPAPI php_socket_t php_network_connect_socket_to_host(const char *host, unsigned short port, int socktype, int asynchronous, struct timeval *timeout, char **error_string, int *error_code, char *bindto, unsigned short bindport From c6b73c85baded89e5a413c999b64d5fffb11b21e Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 20 Jun 2011 22:59:55 +0000 Subject: [PATCH 0208/2394] - Fix broken code in 64bit --- Zend/zend_compile.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 98620d4496707..332b8cb6f7afb 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -134,7 +134,11 @@ typedef struct _zend_try_catch_element { zend_uint catch_op; /* ketchup! */ } zend_try_catch_element; +#if SIZEOF_LONG == 8 +#define THIS_HASHVAL 210728972157UL +#else #define THIS_HASHVAL 275574653UL +#endif /* method flags (types) */ #define ZEND_ACC_STATIC 0x01 From 7b3350347a3904cf0e79fbf7938df49cb227f02e Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 20 Jun 2011 23:36:25 +0000 Subject: [PATCH 0209/2394] - Fixed hardcoded INI --- sapi/cli/php_cli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 250beae2edea3..3aa88fdf644b0 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -1327,7 +1327,7 @@ int main(int argc, char *argv[]) if (sapi_module == &cli_sapi_module) { if (ini_entries) { ini_entries = realloc(ini_entries, ini_entries_len + sizeof(HARDCODED_INI)); - memmove(ini_entries, ini_entries + sizeof(HARDCODED_INI) - 2, ini_entries_len + 1); + memmove(ini_entries + sizeof(HARDCODED_INI) - 2, ini_entries, ini_entries_len + 1); memcpy(ini_entries, HARDCODED_INI, sizeof(HARDCODED_INI) - 2); } else { ini_entries = malloc(sizeof(HARDCODED_INI)); From 1521c79647beaa7adc8a35cd7f2c77e225b6c344 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 21 Jun 2011 01:47:05 +0000 Subject: [PATCH 0210/2394] - Fix memleak on `php -v' --- sapi/cli/php_cli.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 3aa88fdf644b0..6b8113ad1747f 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -704,6 +704,7 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ #endif get_zend_version() ); + sapi_deactivate(TSRMLS_C); goto out; case 'm': /* list compiled in modules */ From bdb54229519207daa448b1c731628acdd765e531 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 21 Jun 2011 11:43:19 +0000 Subject: [PATCH 0211/2394] - fix build --- sapi/cli/php_cli_server.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index e644999f02cdd..f7b4d8ad5b57a 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -18,8 +18,6 @@ /* $Id: php_cli.c 306938 2011-01-01 02:17:06Z felipe $ */ -#include "php_config.h" - #include #include #include @@ -30,6 +28,8 @@ #include "win32/time.h" #include "win32/signal.h" #include "win32/php_registry.h" +#else +# include "php_config.h" #endif #ifdef __riscos__ From ade71aa42aa24c2f434bdb1b6c3f8729b500eeeb Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Wed, 22 Jun 2011 09:28:14 +0000 Subject: [PATCH 0212/2394] Fixed dom tests. --- ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt | 4 ---- ext/dom/tests/dom004.phpt | 2 +- ext/dom/tests/dom_xinclude.phpt | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt b/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt index a02da0f0fde72..403e01aa76bfb 100644 --- a/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt +++ b/ext/dom/tests/DOMDocument_validate_on_parse_variation.phpt @@ -39,10 +39,6 @@ validateOnParse set to FALSE: No Error Report Above validateOnParse set to TRUE: -Warning: DOMDocument::loadXML(): Entity 'nbsp' not defined in Entity, line: %d in %s on line %d - -Warning: DOMDocument::loadXML(): Entity 'copy' not defined in Entity, line: %d in %s on line %d - Warning: DOMDocument::loadXML(): No declaration for element NYPHP in Entity, line: %d in %s on line %d Warning: DOMDocument::loadXML(): Element from was declared #PCDATA but contains non text nodes in Entity, line: %d in %s on line %d diff --git a/ext/dom/tests/dom004.phpt b/ext/dom/tests/dom004.phpt index 82b7915f6f630..5b65f24ba1082 100644 --- a/ext/dom/tests/dom004.phpt +++ b/ext/dom/tests/dom004.phpt @@ -3,7 +3,7 @@ Test 4: Streams Test --SKIPIF-- --FILE-- --FILE-- Date: Thu, 23 Jun 2011 00:25:54 +0000 Subject: [PATCH 0213/2394] - Fixed crash on startup --- sapi/fpm/fpm/fpm_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 9441e810fd97a..547d9f2079fe2 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1587,8 +1587,6 @@ int main(int argc, char *argv[]) char *fpm_prefix = NULL; int test_conf = 0; - fcgi_init(); - #ifdef HAVE_SIGNAL_H #if defined(SIGPIPE) && defined(SIG_IGN) signal(SIGPIPE, SIG_IGN); /* ignore SIGPIPE in standalone mode so @@ -1605,6 +1603,8 @@ int main(int argc, char *argv[]) tsrm_ls = ts_resource(0); #endif + fcgi_init(); + sapi_startup(&cgi_sapi_module); cgi_sapi_module.php_ini_path_override = NULL; cgi_sapi_module.php_ini_ignore_cwd = 1; From de14ef34423cb732bd63f4c40e35fcde790487d4 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 23 Jun 2011 00:40:31 +0000 Subject: [PATCH 0214/2394] - Fixed crash (take 2) --- sapi/fpm/fpm/fpm_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 547d9f2079fe2..cd87ffc29559e 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1603,11 +1603,11 @@ int main(int argc, char *argv[]) tsrm_ls = ts_resource(0); #endif - fcgi_init(); - sapi_startup(&cgi_sapi_module); cgi_sapi_module.php_ini_path_override = NULL; cgi_sapi_module.php_ini_ignore_cwd = 1; + + fcgi_init(); #ifdef PHP_WIN32 _fmode = _O_BINARY; /* sets default for file streams to binary */ From 8dcfa2f9169e8927c51eda9645416163c9959ef6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Thu, 23 Jun 2011 08:03:52 +0000 Subject: [PATCH 0215/2394] - Added custom access log (also added per request %CPU and memory mesurement) --- sapi/fpm/config.m4 | 30 ++ sapi/fpm/fpm/fastcgi.c | 14 +- sapi/fpm/fpm/fastcgi.h | 2 + sapi/fpm/fpm/fpm.c | 4 +- sapi/fpm/fpm/fpm_children.c | 2 + sapi/fpm/fpm/fpm_conf.c | 40 ++- sapi/fpm/fpm/fpm_conf.h | 2 + sapi/fpm/fpm/fpm_events.c | 18 +- sapi/fpm/fpm/fpm_log.c | 493 +++++++++++++++++++++++++++++++++ sapi/fpm/fpm/fpm_log.h | 14 + sapi/fpm/fpm/fpm_main.c | 4 + sapi/fpm/fpm/fpm_php.c | 12 + sapi/fpm/fpm/fpm_php.h | 2 + sapi/fpm/fpm/fpm_process_ctl.c | 2 +- sapi/fpm/fpm/fpm_process_ctl.h | 1 + sapi/fpm/fpm/fpm_request.c | 37 ++- sapi/fpm/fpm/fpm_request.h | 4 +- sapi/fpm/fpm/fpm_shm_slots.h | 13 + sapi/fpm/fpm/fpm_status.c | 1 + sapi/fpm/fpm/fpm_worker_pool.c | 1 + sapi/fpm/fpm/fpm_worker_pool.h | 1 + sapi/fpm/php-fpm.conf.in | 59 ++++ 22 files changed, 744 insertions(+), 12 deletions(-) create mode 100644 sapi/fpm/fpm/fpm_log.c create mode 100644 sapi/fpm/fpm/fpm_log.h diff --git a/sapi/fpm/config.m4 b/sapi/fpm/config.m4 index bb31d3b9b61c3..751f866bb2955 100644 --- a/sapi/fpm/config.m4 +++ b/sapi/fpm/config.m4 @@ -340,6 +340,33 @@ AC_DEFUN([AC_FPM_LQ], ]) dnl }}} +AC_DEFUN([AC_FPM_SYSCONF], +[ + AC_MSG_CHECKING([for sysconf]) + + AC_TRY_COMPILE([ #include ], [sysconf(_SC_CLK_TCK);], [ + AC_DEFINE([HAVE_SYSCONF], 1, [do we have sysconf?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_TIMES], +[ + AC_MSG_CHECKING([for times]) + + AC_TRY_COMPILE([ #include ], [struct tms t; times(&t);], [ + AC_DEFINE([HAVE_TIMES], 1, [do we have times?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + + AC_MSG_CHECKING(for FPM build) if test "$PHP_FPM" != "no"; then AC_MSG_RESULT($PHP_FPM) @@ -350,6 +377,8 @@ if test "$PHP_FPM" != "no"; then AC_FPM_TRACE AC_FPM_BUILTIN_ATOMIC AC_FPM_LQ + AC_FPM_SYSCONF + AC_FPM_TIMES PHP_ARG_WITH(fpm-user,, [ --with-fpm-user[=USER] Set the user for php-fpm to run as. (default: nobody)], nobody, no) @@ -402,6 +431,7 @@ if test "$PHP_FPM" != "no"; then fpm/fpm_conf.c \ fpm/fpm_env.c \ fpm/fpm_events.c \ + fpm/fpm_log.c \ fpm/fpm_main.c \ fpm/fpm_php.c \ fpm/fpm_php_trace.c \ diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index a1644ed12e7db..00a658721425c 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -149,6 +149,8 @@ static int is_fastcgi = 0; static int in_shutdown = 0; static in_addr_t *allowed_clients = NULL; +static sa_t client_sa; + #ifdef _WIN32 static DWORD WINAPI fcgi_shutdown_thread(LPVOID arg) @@ -833,7 +835,9 @@ int fcgi_accept_request(fcgi_request *req) FCGI_LOCK(req->listen_socket); req->fd = accept(listen_socket, (struct sockaddr *)&sa, &len); FCGI_UNLOCK(req->listen_socket); - if (req->fd >= 0 && allowed_clients) { + + client_sa = sa; + if (sa.sa.sa_family == AF_INET && req->fd >= 0 && allowed_clients) { int n = 0; int allowed = 0; @@ -1118,6 +1122,14 @@ void fcgi_free_mgmt_var_cb(void * ptr) pefree(*var, 1); } +char *fcgi_get_last_client_ip() /* {{{ */ +{ + if (client_sa.sa.sa_family == AF_UNIX) { + return NULL; + } + return inet_ntoa(client_sa.sa_inet.sin_addr); +} +/* }}} */ /* * Local variables: * tab-width: 4 diff --git a/sapi/fpm/fpm/fastcgi.h b/sapi/fpm/fpm/fastcgi.h index 565fd3fb1a5fc..4129def0502a9 100644 --- a/sapi/fpm/fpm/fastcgi.h +++ b/sapi/fpm/fpm/fastcgi.h @@ -135,6 +135,8 @@ int fcgi_flush(fcgi_request *req, int close); void fcgi_set_mgmt_var(const char * name, size_t name_len, const char * value, size_t value_len); void fcgi_free_mgmt_var_cb(void * ptr); +char *fcgi_get_last_client_ip(); + /* * Local variables: * tab-width: 4 diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index e3fa3e3bd694b..f80f943910664 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -19,6 +19,7 @@ #include "fpm_conf.h" #include "fpm_worker_pool.h" #include "fpm_stdio.h" +#include "fpm_log.h" #include "zlog.h" struct fpm_globals_s fpm_globals = { @@ -45,8 +46,9 @@ int fpm_init(int argc, char **argv, char *config, char *prefix, int test_conf) / } fpm_globals.prefix = prefix; - if (0 > fpm_php_init_main() || + if (0 > fpm_php_init_main() || 0 > fpm_stdio_init_main() || + 0 > fpm_log_init_main() || 0 > fpm_conf_init_main(test_conf) || 0 > fpm_unix_init_main() || 0 > fpm_pctl_init_main() || diff --git a/sapi/fpm/fpm/fpm_children.c b/sapi/fpm/fpm/fpm_children.c index 476d5523deac5..d8338725e48c9 100644 --- a/sapi/fpm/fpm/fpm_children.c +++ b/sapi/fpm/fpm/fpm_children.c @@ -27,6 +27,7 @@ #include "fpm_env.h" #include "fpm_shm_slots.h" #include "fpm_status.h" +#include "fpm_log.h" #include "zlog.h" @@ -146,6 +147,7 @@ static void fpm_child_init(struct fpm_worker_pool_s *wp) /* {{{ */ fpm_globals.max_requests = wp->config->pm_max_requests; if (0 > fpm_stdio_init_child(wp) || + 0 > fpm_log_init_child(wp) || 0 > fpm_status_init_child(wp) || 0 > fpm_unix_init_child(wp) || 0 > fpm_signals_init_child() || diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index a8e2d60e26ec0..f82806644fd3c 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -41,6 +41,7 @@ #include "fpm_sockets.h" #include "fpm_shm.h" #include "fpm_status.h" +#include "fpm_log.h" #include "zlog.h" static int fpm_conf_load_ini_file(char *filename TSRMLS_DC); @@ -102,6 +103,8 @@ static struct ini_value_parser_s ini_fpm_pool_options[] = { { "pm.status_path", &fpm_conf_set_string, WPO(pm_status_path) }, { "ping.path", &fpm_conf_set_string, WPO(ping_path) }, { "ping.response", &fpm_conf_set_string, WPO(ping_response) }, + { "access.log", &fpm_conf_set_string, WPO(access_log) }, + { "access.format", &fpm_conf_set_string, WPO(access_format) }, { 0, 0, 0 } }; @@ -414,6 +417,8 @@ int fpm_worker_pool_config_free(struct fpm_worker_pool_config_s *wpc) /* {{{ */ free(wpc->chdir); free(wpc->slowlog); free(wpc->prefix); + free(wpc->access_log); + free(wpc->access_format); return 0; } @@ -663,6 +668,13 @@ static int fpm_conf_process_all_pools() /* {{{ */ /* memset(&fpm_status.last_update, 0, sizeof(fpm_status.last_update)); */ } + if (wp->config->access_log && *wp->config->access_log) { + fpm_evaluate_full_path(&wp->config->access_log, wp, NULL, 0); + if (!wp->config->access_format) { + wp->config->access_format = strdup("%R - %u %t \"%m %r\" %s"); + } + } + if (wp->config->chroot && *wp->config->chroot) { fpm_evaluate_full_path(&wp->config->chroot, wp, NULL, 1); @@ -770,8 +782,10 @@ int fpm_conf_write_pid() /* {{{ */ } /* }}} */ -static int fpm_conf_post_process() /* {{{ */ +static int fpm_conf_post_process(TSRMLS_D) /* {{{ */ { + struct fpm_worker_pool_s *wp; + if (fpm_global_config.pid_file) { fpm_evaluate_full_path(&fpm_global_config.pid_file, NULL, PHP_LOCALSTATEDIR, 0); } @@ -786,7 +800,25 @@ static int fpm_conf_post_process() /* {{{ */ return -1; } - return fpm_conf_process_all_pools(); + if (0 > fpm_log_open(0)) { + return -1; + } + + if (0 > fpm_conf_process_all_pools()) { + return -1; + } + + for (wp = fpm_worker_all_pools; wp; wp = wp->next) { + if (!wp->config->access_log || !*wp->config->access_log) { + continue; + } + if (0 > fpm_log_write(wp->config->access_format TSRMLS_CC)) { + zlog(ZLOG_ERROR, "[pool %s] wrong format for access.format '%s'", wp->config->name, wp->config->access_format); + return -1; + } + } + + return 0; } /* }}} */ @@ -1147,6 +1179,8 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tpm.status_path = %s", STR2STR(wp->config->pm_status_path)); zlog(ZLOG_NOTICE, "\tping.path = %s", STR2STR(wp->config->ping_path)); zlog(ZLOG_NOTICE, "\tping.response = %s", STR2STR(wp->config->ping_response)); + zlog(ZLOG_NOTICE, "\taccess.log = %s", STR2STR(wp->config->access_log)); + zlog(ZLOG_NOTICE, "\taccess.format = %s", STR2STR(wp->config->access_format)); zlog(ZLOG_NOTICE, "\tcatch_workers_output = %s", BOOL2STR(wp->config->catch_workers_output)); zlog(ZLOG_NOTICE, "\trequest_terminate_timeout = %ds", wp->config->request_terminate_timeout); zlog(ZLOG_NOTICE, "\trequest_slowlog_timeout = %ds", wp->config->request_slowlog_timeout); @@ -1212,7 +1246,7 @@ int fpm_conf_init_main(int test_conf) /* {{{ */ return -1; } - if (0 > fpm_conf_post_process()) { + if (0 > fpm_conf_post_process(TSRMLS_C)) { zlog(ZLOG_ERROR, "failed to post process the configuration"); return -1; } diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index 64b569006efb4..d1087641d38e9 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -57,6 +57,8 @@ struct fpm_worker_pool_config_s { int pm_max_spare_servers; char *ping_path; char *ping_response; + char *access_log; + char *access_format; char *listen_address; int listen_backlog; char *listen_owner; diff --git a/sapi/fpm/fpm/fpm_events.c b/sapi/fpm/fpm/fpm_events.c index 2bb4b94c00d57..7ba982bf75c7f 100644 --- a/sapi/fpm/fpm/fpm_events.c +++ b/sapi/fpm/fpm/fpm_events.c @@ -21,6 +21,7 @@ #include "fpm_children.h" #include "zlog.h" #include "fpm_clock.h" +#include "fpm_log.h" #define fpm_event_set_timeout(ev, now) timeradd(&(now), &(ev)->frequency, &(ev)->timeout); @@ -55,8 +56,8 @@ static void fpm_event_cleanup(int which, void *arg) /* {{{ */ static void fpm_got_signal(struct fpm_event_s *ev, short which, void *arg) /* {{{ */ { char c; - int res; - int fd = ev->fd;; + int res, ret; + int fd = ev->fd; do { do { @@ -93,10 +94,19 @@ static void fpm_got_signal(struct fpm_event_s *ev, short which, void *arg) /* {{ case '1' : /* SIGUSR1 */ zlog(ZLOG_DEBUG, "received SIGUSR1"); if (0 == fpm_stdio_open_error_log(1)) { - zlog(ZLOG_NOTICE, "log file re-opened"); + zlog(ZLOG_NOTICE, "error log file re-opened"); } else { - zlog(ZLOG_ERROR, "unable to re-opened log file"); + zlog(ZLOG_ERROR, "unable to re-opened error log file"); } + + ret = fpm_log_open(1); + if (ret == 0) { + zlog(ZLOG_NOTICE, "access log file re-opened"); + } else if (ret == -1) { + zlog(ZLOG_ERROR, "unable to re-opened access log file"); + } + /* else no access log are set */ + break; case '2' : /* SIGUSR2 */ zlog(ZLOG_DEBUG, "received SIGUSR2"); diff --git a/sapi/fpm/fpm/fpm_log.c b/sapi/fpm/fpm/fpm_log.c new file mode 100644 index 0000000000000..243ed867645f4 --- /dev/null +++ b/sapi/fpm/fpm/fpm_log.c @@ -0,0 +1,493 @@ + + /* $Id: fpm_status.c 312262 2011-06-18 17:41:56Z felipe $ */ + /* (c) 2009 Jerome Loyet */ + +#include "php.h" +#include "SAPI.h" +#include +#include +#include + +#ifdef HAVE_TIMES +#include +#endif + +#include "fpm_config.h" +#include "fpm_log.h" +#include "fpm_clock.h" +#include "fpm_process_ctl.h" +#include "fpm_signals.h" +#include "fpm_shm_slots.h" +#include "fastcgi.h" +#include "zlog.h" + +#ifdef MAX_LINE_LENGTH +# define FPM_LOG_BUFFER MAX_LINE_LENGTH +#else +# define FPM_LOG_BUFFER 1024 +#endif + +static char *fpm_log_format = NULL; +static char *fpm_log_pool = NULL; +static int fpm_log_fd = -1; +#ifdef HAVE_TIMES +static float tick; +#endif + +int fpm_log_open(int reopen) /* {{{ */ +{ + struct fpm_worker_pool_s *wp; + int ret = 1; + + int fd; + for (wp = fpm_worker_all_pools; wp; wp = wp->next) { + if (!wp->config->access_log) { + continue; + } + ret = 0; + + fd = open(wp->config->access_log, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); + if (0 > fd) { + zlog(ZLOG_SYSERROR, "open(\"%s\") failed", wp->config->access_log); + return -1; + } + + if (reopen) { + dup2(fd, wp->log_fd); + close(fd); + fd = wp->log_fd; + fpm_pctl_kill_all(SIGQUIT); + } else { + wp->log_fd = fd; + } + + fcntl(fd, F_SETFD, fcntl(fd, F_GETFD) | FD_CLOEXEC); + } + + return ret; +} +/* }}} */ + +int fpm_log_init_main() /* {{{ */ +{ +#ifdef HAVE_TIMES +#if (defined(HAVE_SYSCONF) && defined(_SC_CLK_TCK)) + tick = sysconf(_SC_CLK_TCK); +#else /* _SC_CLK_TCK */ +#ifdef HZ + tick = HZ; +#else /* HZ */ + tick = 100; +#endif /* HZ */ +#endif /* _SC_CLK_TCK */ + zlog(ZLOG_DEBUG, "got clock tick '%.0f'", tick); +#endif /* HAVE_TIMES */ + return 0; +} +/* }}} */ + +/* }}} */ +int fpm_log_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ +{ + if (!wp || !wp->config) { + return -1; + } + + if (wp->config->access_log && *wp->config->access_log) { + if (wp->config->access_format) { + fpm_log_format = strdup(wp->config->access_format); + } + } + + if (wp->config->name) { + fpm_log_pool = strdup(wp->config->name); + } + + if (fpm_log_fd == -1) { + fpm_log_fd = wp->log_fd; + } + + + for (wp = fpm_worker_all_pools; wp; wp = wp->next) { + if (wp->log_fd > -1 && wp->log_fd != fpm_log_fd) { + close(wp->log_fd); + wp->log_fd = -1; + } + } + + return 0; +} +/* }}} */ + +int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ +{ + char *s, *b; + char buffer[FPM_LOG_BUFFER]; + int token, test; + size_t len, len2; +// fcgi_request *request = (fcgi_request*) SG(server_context); + struct fpm_shm_slot_s slot, *slot_p; + struct timeval uptime, now; + char tmp[129]; + char format[129]; + time_t now_epoch; +#ifdef HAVE_TIMES + clock_t tms_total; +#endif + + if (!log_format && (!fpm_log_format || fpm_log_fd == -1)) { + return -1; + } + + if (!log_format) { + log_format = fpm_log_format; + test = 0; + } else { + test = 1; + } + + fpm_clock_get(&now); + now_epoch = time(NULL); + if (!test) { + slot_p = fpm_shm_slots_acquire(0, 0); + if (!slot_p) { + zlog(ZLOG_WARNING, "Unable to acquire shm slot"); + return -1; + } + slot = *slot_p; + fpm_shm_slots_release(slot_p); + + timersub(&now, &slot.accepted, &uptime); + } + + token = 0; + + memset(buffer, '\0', sizeof(buffer)); + b = buffer; + len = 0; + + + s = log_format; + + while (*s != '\0') { + if (len > FPM_LOG_BUFFER) { + zlog(ZLOG_NOTICE, "the log buffer is full (%d). The log request has been truncated.", FPM_LOG_BUFFER); + len = FPM_LOG_BUFFER - 1; + break; + } + + if (!token && *s == '%') { + token = 1; + memset(format, '\0', sizeof(format)); /* reset format */ + s++; + continue; + } + + if (token) { + token = 0; + len2 = 0; + switch (*s) { + + case '%': /* '%' */ + *b = '%'; + len2 = 1; + break; + +#ifdef HAVE_TIMES + case 'C': /* %CPU */ + if (format[0] == '\0' || !strcasecmp(format, "total")) { + if (!test) { + tms_total = + (slot.cpu_finished.tms_utime + slot.cpu_finished.tms_stime + slot.cpu_finished.tms_cutime + slot.cpu_finished.tms_cstime) + - + (slot.cpu_accepted.tms_utime + slot.cpu_accepted.tms_stime + slot.cpu_accepted.tms_cutime + slot.cpu_accepted.tms_cstime) + ; + } + } else if (!strcasecmp(format, "user")) { + if (!test) { + tms_total = (slot.cpu_finished.tms_utime + slot.cpu_finished.tms_cutime) - (slot.cpu_accepted.tms_utime + slot.cpu_accepted.tms_cutime); + } + } else if (!strcasecmp(format, "system")) { + if (!test) { + tms_total = (slot.cpu_finished.tms_stime + slot.cpu_finished.tms_cstime) - (slot.cpu_accepted.tms_stime + slot.cpu_accepted.tms_cstime); + } + } else { + zlog(ZLOG_WARNING, "only 'total', 'user' or 'system' are allowed as a modifier for %%%c ('%s')", *s, format); + return -1; + } + + format[0] = '\0'; + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.2f", tms_total / tick / (slot.cpu_duration.tv_sec + slot.cpu_duration.tv_usec / 1000000.) * 100.); + } + break; +#endif + + case 'd': /* duration µs */ + /* seconds */ + if (format[0] == '\0' || !strcasecmp(format, "seconds")) { + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.3f", uptime.tv_sec + uptime.tv_usec / 1000000.); + } + + /* miliseconds */ + } else if (!strcasecmp(format, "miliseconds") || !strcasecmp(format, "mili")) { + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.3f", uptime.tv_sec * 1000. + uptime.tv_usec / 1000.); + } + + /* microseconds */ + } else if (!strcasecmp(format, "microseconds") || !strcasecmp(format, "micro")) { + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", uptime.tv_sec * 1000000UL + uptime.tv_usec); + } + + } else { + zlog(ZLOG_WARNING, "only 'seconds', 'mili', 'miliseconds', 'micro' or 'microseconds' are allowed as a modifier for %%%c ('%s')", *s, format); + return -1; + } + format[0] = '\0'; + break; + + case 'e': /* fastcgi env */ + if (format[0] == '\0') { + zlog(ZLOG_WARNING, "the name of the environment variable must be set between embraces for %%%c", *s); + return -1; + } + + if (!test) { + char *env = fcgi_getenv((fcgi_request*) SG(server_context), format, strlen(format)); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", env ? env : "-"); + } + format[0] = '\0'; + break; + + case 'f': /* script */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.script_filename && *slot.script_filename ? slot.script_filename : "-"); + } + break; + + case 'l': /* content length */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%zu", slot.content_length); + } + break; + + case 'm': /* method */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.request_method && *slot.request_method ? slot.request_method : "-"); + } + break; + + case 'M': /* memory */ + /* seconds */ + if (format[0] == '\0' || !strcasecmp(format, "bytes")) { + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%zu", slot.memory); + } + + /* kilobytes */ + } else if (!strcasecmp(format, "kilobytes") || !strcasecmp(format, "kilo")) { + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", slot.memory / 1024); + } + + /* megabytes */ + } else if (!strcasecmp(format, "megabytes") || !strcasecmp(format, "mega")) { + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", slot.memory / 1024 / 1024); + } + + } else { + zlog(ZLOG_WARNING, "only 'bytes', 'kilo', 'kilobytes', 'mega' or 'megabytes' are allowed as a modifier for %%%c ('%s')", *s, format); + return -1; + } + format[0] = '\0'; + break; + + case 'n': /* pool name */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", fpm_log_pool ? fpm_log_pool : "-"); + } + break; + + case 'o': /* header output */ + if (format[0] == '\0') { + zlog(ZLOG_WARNING, "the name of the header must be set between embraces for %%%c", *s); + return -1; + } + if (!test) { + sapi_header_struct *h; + zend_llist_position pos; + sapi_headers_struct *sapi_headers = &SG(sapi_headers); + size_t format_len = strlen(format); + + h = (sapi_header_struct*)zend_llist_get_first_ex(&sapi_headers->headers, &pos); + while (h) { + char *header; + if (!h->header_len) { + h = (sapi_header_struct*)zend_llist_get_next_ex(&sapi_headers->headers, &pos); + continue; + } + if (!strstr(h->header, format)) { + h = (sapi_header_struct*)zend_llist_get_next_ex(&sapi_headers->headers, &pos); + continue; + } + + /* test if enought char after the header name + ': ' */ + if (h->header_len <= format_len + 2) { + h = (sapi_header_struct*)zend_llist_get_next_ex(&sapi_headers->headers, &pos); + continue; + } + + if (h->header[format_len] != ':' || h->header[format_len + 1] != ' ') { + h = (sapi_header_struct*)zend_llist_get_next_ex(&sapi_headers->headers, &pos); + continue; + } + + header = h->header + format_len + 2; + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", header && *header ? header : "-"); + + /* found, done */ + break; + } + if (!len2) { + len2 = 1; + *b = '-'; + } + } + format[0] = '\0'; + break; + + case 'p': /* PID */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%ld", (long)getpid()); + } + break; + + case 'P': /* PID */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%ld", (long)getppid()); + } + break; + + case 'q': /* query_string */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.query_string ? slot.query_string : ""); + } + break; + + case 'Q': /* '?' */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.query_string && *slot.query_string ? "?" : ""); + } + break; + + case 'r': /* request URI */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.request_uri ? slot.request_uri : "-"); + } + break; + + case 'R': /* remote IP address */ + if (!test) { + char *tmp = fcgi_get_last_client_ip(); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", tmp ? tmp : "-"); + } + break; + + case 's': /* status */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%d", SG(sapi_headers).http_response_code); + } + break; + + case 'T': + case 't': /* time */ + if (!test) { + time_t *t; + if (*s == 't') { + t = &slot.accepted_epoch; + } else { + t = &now_epoch; + } + if (format[0] == '\0') { + strftime(tmp, sizeof(tmp) - 1, "%d/%b/%Y:%H:%M:%S %z", localtime(t)); + } else { + strftime(tmp, sizeof(tmp) - 1, format, localtime(t)); + } + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", tmp); + } + format[0] = '\0'; + break; + + case 'u': /* remote user */ + if (!test) { + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.auth_user ? slot.auth_user : "-"); + } + break; + + case '{': /* complex var */ + token = 1; + { + char *start; + size_t l; + + start = ++s; + + while (*s != '\0') { + if (*s == '}') { + l = s - start; + + if (l >= sizeof(format) - 1) { + l = sizeof(format) - 1; + } + + memcpy(format, start, l); + format[l] = '\0'; + break; + } + s++; + } + if (s[1] == '\0') { + zlog(ZLOG_WARNING, "missing closing embrace in the access.format"); + return -1; + } + } + break; + + default: + zlog(ZLOG_WARNING, "Invalid token in the access.format (%%%c)", *s); + return -1; + } + + if (*s != '}' && format[0] != '\0') { + zlog(ZLOG_WARNING, "embrace is not allowed for modifier %%%c", *s); + return -1; + } + s++; + if (!test) { + b += len2; + len += len2; + } + continue; + } + + if (!test) { + // push the normal char to the output buffer + *b = *s; + b++; + len++; + } + s++; + } + + if (!test && strlen(buffer) > 0) { + buffer[len] = '\n'; + write(fpm_log_fd, buffer, len + 1); + } + + return 0; +} +/* }}} */ diff --git a/sapi/fpm/fpm/fpm_log.h b/sapi/fpm/fpm/fpm_log.h new file mode 100644 index 0000000000000..74f842646fa02 --- /dev/null +++ b/sapi/fpm/fpm/fpm_log.h @@ -0,0 +1,14 @@ + + /* $Id: fpm_status.h 312263 2011-06-18 17:46:16Z felipe $ */ + /* (c) 2009 Jerome Loyet */ + +#ifndef FPM_LOG_H +#define FPM_LOG_H 1 +#include "fpm_worker_pool.h" + +int fpm_log_init_main(); +int fpm_log_init_child(struct fpm_worker_pool_s *wp); +int fpm_log_write(char *log_format TSRMLS_DC); +int fpm_log_open(int reopen); + +#endif diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index cd87ffc29559e..37c932e5b4810 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -109,6 +109,7 @@ int __riscosify_control = __RISCOSIFY_STRICT_UNIX_SPECS; #include #include #include +#include #ifndef PHP_WIN32 /* XXX this will need to change later when threaded fastcgi is implemented. shane */ @@ -1905,6 +1906,9 @@ consult the installation file that came with this distribution, or visit \n\ } } + fpm_request_end(TSRMLS_C); + fpm_log_write(NULL TSRMLS_CC); + STR_FREE(SG(request_info).path_translated); SG(request_info).path_translated = NULL; diff --git a/sapi/fpm/fpm/fpm_php.c b/sapi/fpm/fpm/fpm_php.c index 384682b7e2227..33b9e410e1fff 100644 --- a/sapi/fpm/fpm/fpm_php.c +++ b/sapi/fpm/fpm/fpm_php.c @@ -172,6 +172,18 @@ char *fpm_php_request_method(TSRMLS_D) /* {{{ */ } /* }}} */ +char *fpm_php_query_string(TSRMLS_D) /* {{{ */ +{ + return SG(request_info).query_string; +} +/* }}} */ + +char *fpm_php_auth_user(TSRMLS_D) /* {{{ */ +{ + return SG(request_info).auth_user; +} +/* }}} */ + size_t fpm_php_content_length(TSRMLS_D) /* {{{ */ { return SG(request_info).content_length; diff --git a/sapi/fpm/fpm/fpm_php.h b/sapi/fpm/fpm/fpm_php.h index 891e83bfce97c..62a47e7fd37b3 100644 --- a/sapi/fpm/fpm/fpm_php.h +++ b/sapi/fpm/fpm/fpm_php.h @@ -37,6 +37,8 @@ int fpm_php_init_child(struct fpm_worker_pool_s *wp); char *fpm_php_script_filename(TSRMLS_D); char *fpm_php_request_uri(TSRMLS_D); char *fpm_php_request_method(TSRMLS_D); +char *fpm_php_query_string(TSRMLS_D); +char *fpm_php_auth_user(TSRMLS_D); size_t fpm_php_content_length(TSRMLS_D); void fpm_php_soft_quit(); int fpm_php_init_main(); diff --git a/sapi/fpm/fpm/fpm_process_ctl.c b/sapi/fpm/fpm/fpm_process_ctl.c index badda1408237b..bd50c46c297f1 100644 --- a/sapi/fpm/fpm/fpm_process_ctl.c +++ b/sapi/fpm/fpm/fpm_process_ctl.c @@ -143,7 +143,7 @@ int fpm_pctl_kill(pid_t pid, int how) /* {{{ */ } /* }}} */ -static void fpm_pctl_kill_all(int signo) /* {{{ */ +void fpm_pctl_kill_all(int signo) /* {{{ */ { struct fpm_worker_pool_s *wp; int alive_children = 0; diff --git a/sapi/fpm/fpm/fpm_process_ctl.h b/sapi/fpm/fpm/fpm_process_ctl.h index 36577097cbddc..6bfcfd8c6beb1 100644 --- a/sapi/fpm/fpm/fpm_process_ctl.h +++ b/sapi/fpm/fpm/fpm_process_ctl.h @@ -19,6 +19,7 @@ struct fpm_child_s; void fpm_pctl(int new_state, int action); int fpm_pctl_can_spawn_children(); int fpm_pctl_kill(pid_t pid, int how); +void fpm_pctl_kill_all(int signo); void fpm_pctl_heartbeat(struct fpm_event_s *ev, short which, void *arg); void fpm_pctl_perform_idle_server_maintenance_heartbeat(struct fpm_event_s *ev, short which, void *arg); int fpm_pctl_child_exited(); diff --git a/sapi/fpm/fpm/fpm_request.c b/sapi/fpm/fpm/fpm_request.c index 6ba9e5170ca6c..492e76275be12 100644 --- a/sapi/fpm/fpm/fpm_request.c +++ b/sapi/fpm/fpm/fpm_request.c @@ -1,6 +1,9 @@ /* $Id: fpm_request.c,v 1.9.2.1 2008/11/15 00:57:24 anight Exp $ */ /* (c) 2007,2008 Andrei Nigmatulin */ +#ifdef HAVE_TIMES +#include +#endif #include "fpm_config.h" @@ -16,6 +19,7 @@ #include "fpm_shm_slots.h" #include "fpm_status.h" #include "fpm_request.h" +#include "fpm_log.h" #include "zlog.h" @@ -42,6 +46,10 @@ void fpm_request_reading_headers() /* {{{ */ slot->request_stage = FPM_REQUEST_READING_HEADERS; fpm_clock_get(&slot->tv); slot->accepted = slot->tv; + slot->accepted_epoch = time(NULL); +#ifdef HAVE_TIMES + times(&slot->cpu_accepted); +#endif fpm_shm_slots_release(slot); fpm_status_increment_accepted_conn(fpm_status_shm); @@ -55,6 +63,8 @@ void fpm_request_info() /* {{{ */ char *request_uri = fpm_php_request_uri(TSRMLS_C); char *request_method = fpm_php_request_method(TSRMLS_C); char *script_filename = fpm_php_script_filename(TSRMLS_C); + char *query_string = fpm_php_query_string(TSRMLS_C); + char *auth_user = fpm_php_auth_user(TSRMLS_C); slot = fpm_shm_slots_acquire(0, 0); slot->request_stage = FPM_REQUEST_INFO; @@ -68,6 +78,14 @@ void fpm_request_info() /* {{{ */ strlcpy(slot->request_method, request_method, sizeof(slot->request_method)); } + if (query_string) { + strlcpy(slot->query_string, query_string, sizeof(slot->query_string)); + } + + if (auth_user) { + strlcpy(slot->auth_user, auth_user, sizeof(slot->auth_user)); + } + slot->content_length = fpm_php_content_length(TSRMLS_C); /* if cgi.fix_pathinfo is set to "1" and script cannot be found (404) @@ -91,6 +109,22 @@ void fpm_request_executing() /* {{{ */ } /* }}} */ +void fpm_request_end(TSRMLS_D) /* {{{ */ +{ + struct fpm_shm_slot_s *slot; + + slot = fpm_shm_slots_acquire(0, 0); + slot->request_stage = FPM_REQUEST_FINISHED; + fpm_clock_get(&slot->tv); +#ifdef HAVE_TIMES + times(&slot->cpu_finished); + timersub(&slot->tv, &slot->accepted, &slot->cpu_duration); +#endif + slot->memory = zend_memory_peak_usage(1 TSRMLS_CC); + fpm_shm_slots_release(slot); +} +/* }}} */ + void fpm_request_finished() /* {{{ */ { struct fpm_shm_slot_s *slot; @@ -99,6 +133,7 @@ void fpm_request_finished() /* {{{ */ slot->request_stage = FPM_REQUEST_FINISHED; fpm_clock_get(&slot->tv); memset(&slot->accepted, 0, sizeof(slot->accepted)); + slot->accepted_epoch = 0; fpm_shm_slots_release(slot); } /* }}} */ @@ -125,7 +160,7 @@ void fpm_request_check_timed_out(struct fpm_child_s *child, struct timeval *now, } #endif - if (slot_c.request_stage > FPM_REQUEST_ACCEPTING && slot_c.request_stage < FPM_REQUEST_FINISHED) { + if (slot_c.request_stage > FPM_REQUEST_ACCEPTING && slot_c.request_stage < FPM_REQUEST_END) { char purified_script_filename[sizeof(slot_c.script_filename)]; struct timeval tv; diff --git a/sapi/fpm/fpm/fpm_request.h b/sapi/fpm/fpm/fpm_request.h index 7bc9bc84270aa..b3014a5f1dcb0 100644 --- a/sapi/fpm/fpm/fpm_request.h +++ b/sapi/fpm/fpm/fpm_request.h @@ -9,7 +9,8 @@ void fpm_request_accepting(); /* hanging in accept() */ void fpm_request_reading_headers(); /* start reading fastcgi request from very first byte */ void fpm_request_info(); /* not a stage really but a point in the php code, where all request params have become known to sapi */ void fpm_request_executing(); /* the script is executing */ -void fpm_request_finished(); /* request processed: script response have been sent to web server */ +void fpm_request_end(TSRMLS_D); /* request ended: script response have been sent to web server */ +void fpm_request_finished(); /* request processed: cleaning current request */ struct fpm_child_s; struct timeval; @@ -22,6 +23,7 @@ enum fpm_request_stage_e { FPM_REQUEST_READING_HEADERS, FPM_REQUEST_INFO, FPM_REQUEST_EXECUTING, + FPM_REQUEST_END, FPM_REQUEST_FINISHED }; diff --git a/sapi/fpm/fpm/fpm_shm_slots.h b/sapi/fpm/fpm/fpm_shm_slots.h index d74f1762292c0..03303848e92a7 100644 --- a/sapi/fpm/fpm/fpm_shm_slots.h +++ b/sapi/fpm/fpm/fpm_shm_slots.h @@ -5,6 +5,10 @@ #ifndef FPM_SHM_SLOTS_H #define FPM_SHM_SLOTS_H 1 +#ifdef HAVE_TIMES +#include +#endif + #include "fpm_atomic.h" #include "fpm_worker_pool.h" #include "fpm_request.h" @@ -18,11 +22,20 @@ struct fpm_shm_slot_s { }; enum fpm_request_stage_e request_stage; struct timeval accepted; + time_t accepted_epoch; struct timeval tv; char request_uri[128]; + char query_string[512]; char request_method[16]; size_t content_length; /* used with POST only */ char script_filename[256]; + char auth_user[32]; +#ifdef HAVE_TIMES + struct tms cpu_accepted; + struct tms cpu_finished; + struct timeval cpu_duration; +#endif + size_t memory; }; struct fpm_shm_slot_ptr_s { diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 22ad159478346..63f15d6e971c7 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -9,6 +9,7 @@ #include "fpm_config.h" #include "fpm_status.h" #include "fpm_clock.h" +#include "fpm_shm_slots.h" #include "zlog.h" struct fpm_shm_s *fpm_status_shm = NULL; diff --git a/sapi/fpm/fpm/fpm_worker_pool.c b/sapi/fpm/fpm/fpm_worker_pool.c index 53e3368fa7643..e799e35026373 100644 --- a/sapi/fpm/fpm/fpm_worker_pool.c +++ b/sapi/fpm/fpm/fpm_worker_pool.c @@ -55,6 +55,7 @@ struct fpm_worker_pool_s *fpm_worker_pool_alloc() /* {{{ */ fpm_array_init(&ret->slots_used, sizeof(struct fpm_shm_slot_ptr_s), 50); fpm_array_init(&ret->slots_free, sizeof(struct fpm_shm_slot_ptr_s), 50); ret->idle_spawn_rate = 1; + ret->log_fd = -1; return ret; } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_worker_pool.h b/sapi/fpm/fpm/fpm_worker_pool.h index 7f240a20c2846..e014255cf148f 100644 --- a/sapi/fpm/fpm/fpm_worker_pool.h +++ b/sapi/fpm/fpm/fpm_worker_pool.h @@ -39,6 +39,7 @@ struct fpm_worker_pool_s { int idle_spawn_rate; int warn_max_children; struct fpm_shm_s *shm_status; + int log_fd; }; struct fpm_worker_pool_s *fpm_worker_pool_alloc(); diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index 499eafcb6689e..c3b0627cd103d 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -232,6 +232,65 @@ pm.max_children = 50 ; response is formatted as text/plain with a 200 response code. ; Default Value: pong ;ping.response = pong + +; The access log file +; Default: not set +;access.log = log/$pool.access.log + +; The access log format. +; The following syntax is allowed +; %%: the '%' character +; %C: %CPU used by the request +; it can accept the following format: +; - %{user}C for user CPU only +; - %{system}C for system CPU only +; - %{total}C for user + system CPU (default) +; %d: time taken to serve the request +; it can accept the following format: +; - %{seconds}d (default) +; - %{miliseconds}d +; - %{mili}d +; - %{microseconds}d +; - %{micro}d +; %e: an environment variable (same as $_ENV or $_SERVER) +; it must be associated with embraces to specify the name of the env +; variable. Some exemples: +; - server specifics like: %{REQUEST_METHOD}e or %{SERVER_PROTOCOL}e +; - HTTP headers like: %{HTTP_HOST}e or %{HTTP_USER_AGENT}e +; %f: script filename +: %l: content-length of the request (for POST request only) +; %m: request method +; %M: peak of memory allocated by PHP +; it can accept the following format: +; - %{bytes}M (default) +; - %{kilobytes}M +; - %{kilo}M +; - %{megabytes}M +; - %{mega}M +; %n: pool name +; %o: ouput header +; it must be associated with embraces to specify the name of the header: +; - %{Content-Type}o +; - %{X-Powered-By}o +; - %{Transfert-Encoding}o +; - .... +; %p: PID of the child that serviced the request +; %P: PID of the parent of the child that serviced the request +; %q: the query string +; %Q: the '?' character if query string exists +; %r: the request URI (without the query string, see %q and %Q) +; %R: remote IP address +; %s: status (response code) +; %t: server time the request was received +; it can accept a strftime(3) format: +; %d/%b/%Y:%H:%M:%S %z (default) +; %T: time the log has been written (the request has finished) +; it can accept a strftime(3) format: +; %d/%b/%Y:%H:%M:%S %z (default) +; %u: remote user +; +; Default: "%R - %u %t \"%m %r\" %s" +;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%" ; The timeout for serving a single request after which the worker process will ; be killed. This option should be used when the 'max_execution_time' ini option From 7f2882cc53492cec56ad5b14a4e860ad95e1f49b Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Thu, 23 Jun 2011 14:12:50 +0000 Subject: [PATCH 0216/2394] Fixed a bug with calculation of REQUEST_TIME in apache2 --- sapi/apache2handler/sapi_apache2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/apache2handler/sapi_apache2.c b/sapi/apache2handler/sapi_apache2.c index 48eea2b6fb45e..a7f250d51251c 100644 --- a/sapi/apache2handler/sapi_apache2.c +++ b/sapi/apache2handler/sapi_apache2.c @@ -338,7 +338,7 @@ static void php_apache_sapi_log_message_ex(char *msg, request_rec *r TSRMLS_DC) static double php_apache_sapi_get_request_time(TSRMLS_D) { php_struct *ctx = SG(server_context); - return apr_time_as_msec(ctx->r->request_time); + return ((double) apr_time_as_msec(ctx->r->request_time)) / 1000.0; } extern zend_module_entry php_apache_module; From cc438880c002ef25015aead4c7191709d5b5dcda Mon Sep 17 00:00:00 2001 From: Nuno Lopes Date: Thu, 23 Jun 2011 15:00:00 +0000 Subject: [PATCH 0217/2394] MFB: properly regen file to fix coverage data --- ext/date/lib/parse_date.c | 59267 ++++++++++++++---------------------- 1 file changed, 22376 insertions(+), 36891 deletions(-) diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index a8ab37970e921..e52cf51c58fc7 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jun 19 11:04:50 2011 */ +/* Generated by re2c 0.13.5 on Thu Jun 23 10:58:11 2011 */ #line 1 "ext/date/lib/parse_date.re" /* +----------------------------------------------------------------------+ @@ -867,13 +867,49 @@ static int scan(Scanner *s) -#line 871 "" +#line 871 "ext/date/lib/parse_date.c" { YYCTYPE yych; unsigned int yyaccept = 0; + static const unsigned char yybm[] = { + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 100, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 100, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 128, 64, 160, 96, 0, + 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 0, 0, 0, 0, 0, 0, + 0, 8, 8, 8, 8, 8, 8, 8, + 8, 8, 8, 8, 8, 8, 8, 8, + 8, 8, 8, 8, 8, 8, 8, 8, + 8, 8, 8, 0, 0, 0, 0, 0, + 0, 24, 24, 24, 88, 24, 24, 24, + 88, 24, 24, 24, 24, 24, 88, 24, + 24, 24, 88, 88, 88, 24, 24, 24, + 24, 24, 24, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, + }; + YYDEBUG(0, *YYCURSOR); if ((YYLIMIT - YYCURSOR) < 31) YYFILL(31); yych = *YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { case 0x00: case '\n': goto yy52; @@ -950,6 +986,7 @@ static int scan(Scanner *s) default: goto yy54; } yy2: + YYDEBUG(2, *YYCURSOR); #line 1074 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("firstdayof | lastdayof"); @@ -966,66 +1003,29 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_LF_DAY_OF_MONTH; } -#line 970 "" +#line 1007 "ext/date/lib/parse_date.c" yy3: + YYDEBUG(3, *YYCURSOR); ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'E': goto yy1523; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'e': goto yy1532; - default: goto yy4; + if ((yych = *YYCURSOR) <= 'E') { + if (yych <= ')') { + if (yych >= ')') goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy1523; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych >= 'a') goto yy146; + } else { + if (yych <= 'e') goto yy1532; + if (yych <= 'z') goto yy146; + } } yy4: + YYDEBUG(4, *YYCURSOR); #line 1656 "ext/date/lib/parse_date.re" { int tz_not_found; @@ -1039,76 +1039,190 @@ static int scan(Scanner *s) TIMELIB_DEINIT; return TIMELIB_TIMEZONE; } -#line 1043 "" +#line 1043 "ext/date/lib/parse_date.c" yy5: + YYDEBUG(5, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'E': - case 'e': goto yy1523; - default: goto yy4; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy1523; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy141; + } else { + if (yych <= 'e') goto yy1523; + if (yych <= 'z') goto yy141; + goto yy4; + } } yy6: + YYDEBUG(6, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= 'D') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'H') { + if (yych <= 'E') goto yy1494; + goto yy141; + } else { + if (yych <= 'I') goto yy1495; + if (yych <= 'N') goto yy141; + goto yy1493; + } + } + } else { + if (yych <= 'h') { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych == 'e') goto yy1510; + goto yy146; + } + } else { + if (yych <= 'n') { + if (yych <= 'i') goto yy1511; + goto yy146; + } else { + if (yych <= 'o') goto yy1509; + if (yych <= 'z') goto yy146; + goto yy4; + } + } + } +yy7: + YYDEBUG(7, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= 'D') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'H') { + if (yych <= 'E') goto yy1494; + goto yy141; + } else { + if (yych <= 'I') goto yy1495; + if (yych <= 'N') goto yy141; + goto yy1493; + } + } + } else { + if (yych <= 'h') { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych == 'e') goto yy1494; + goto yy141; + } + } else { + if (yych <= 'n') { + if (yych <= 'i') goto yy1495; + goto yy141; + } else { + if (yych <= 'o') goto yy1493; + if (yych <= 'z') goto yy141; + goto yy4; + } + } + } +yy8: + YYDEBUG(8, *YYCURSOR); yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1463; + } else { + if (yych == 'I') goto yy1464; + if (yych <= 'N') goto yy141; + goto yy1465; + } + } else { + if (yych <= 'h') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1478; + goto yy146; + } else { + if (yych <= 'n') { + if (yych <= 'i') goto yy1479; + goto yy146; + } else { + if (yych <= 'o') goto yy1480; + if (yych <= 'z') goto yy146; + goto yy4; + } + } + } +yy9: + YYDEBUG(9, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1463; + } else { + if (yych == 'I') goto yy1464; + if (yych <= 'N') goto yy141; + goto yy1465; + } + } else { + if (yych <= 'h') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1463; + goto yy141; + } else { + if (yych <= 'n') { + if (yych <= 'i') goto yy1464; + goto yy141; + } else { + if (yych <= 'o') goto yy1465; + if (yych <= 'z') goto yy141; + goto yy4; + } + } + } +yy10: + YYDEBUG(10, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { case ')': goto yy140; + case '0': + case '1': goto yy1393; + case '2': goto yy1394; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1395; case 'A': case 'B': case 'C': case 'D': case 'F': case 'G': - case 'H': + case 'I': case 'J': case 'K': case 'L': @@ -1119,22 +1233,22 @@ static int scan(Scanner *s) case 'R': case 'S': case 'T': - case 'U': case 'V': - case 'W': case 'X': case 'Y': case 'Z': goto yy141; - case 'E': goto yy1494; - case 'I': goto yy1495; - case 'O': goto yy1493; + case 'E': goto yy1388; + case 'H': goto yy1389; + case 'O': goto yy1390; + case 'U': goto yy1391; + case 'W': goto yy1392; case 'a': case 'b': case 'c': case 'd': case 'f': case 'g': - case 'h': + case 'i': case 'j': case 'k': case 'l': @@ -1145,28 +1259,41 @@ static int scan(Scanner *s) case 'r': case 's': case 't': - case 'u': case 'v': - case 'w': case 'x': case 'y': case 'z': goto yy146; - case 'e': goto yy1510; - case 'i': goto yy1511; - case 'o': goto yy1509; + case 'e': goto yy1431; + case 'h': goto yy1432; + case 'o': goto yy1433; + case 'u': goto yy1434; + case 'w': goto yy1435; default: goto yy4; } -yy7: - yych = *++YYCURSOR; +yy11: + YYDEBUG(11, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { case ')': goto yy140; + case '0': + case '1': goto yy1393; + case '2': goto yy1394; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1395; case 'A': case 'B': case 'C': case 'D': case 'F': case 'G': - case 'H': + case 'I': case 'J': case 'K': case 'L': @@ -1177,9 +1304,7 @@ static int scan(Scanner *s) case 'R': case 'S': case 'T': - case 'U': case 'V': - case 'W': case 'X': case 'Y': case 'Z': @@ -1189,7 +1314,7 @@ static int scan(Scanner *s) case 'd': case 'f': case 'g': - case 'h': + case 'i': case 'j': case 'k': case 'l': @@ -1200,281 +1325,576 @@ static int scan(Scanner *s) case 'r': case 's': case 't': - case 'u': case 'v': - case 'w': case 'x': case 'y': case 'z': goto yy141; case 'E': - case 'e': goto yy1494; - case 'I': - case 'i': goto yy1495; + case 'e': goto yy1388; + case 'H': + case 'h': goto yy1389; case 'O': - case 'o': goto yy1493; + case 'o': goto yy1390; + case 'U': + case 'u': goto yy1391; + case 'W': + case 'w': goto yy1392; default: goto yy4; } -yy8: +yy12: + YYDEBUG(12, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '-') goto yy1384; + if (yych <= '/') goto yy13; + if (yych <= '9') goto yy1385; +yy13: + YYDEBUG(13, *YYCURSOR); +#line 1751 "ext/date/lib/parse_date.re" + { + add_error(s, "Unexpected character"); + goto std; + } +#line 1359 "ext/date/lib/parse_date.c" +yy14: + YYDEBUG(14, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': goto yy1463; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': + if (yych <= 'R') { + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy1320; + } + } else { + if (yych <= 'N') { + if (yych == 'I') goto yy1321; + goto yy141; + } else { + if (yych <= 'O') goto yy1322; + if (yych <= 'Q') goto yy141; + goto yy1323; + } + } + } else { + if (yych <= 'i') { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy146; + } else { + if (yych <= 'e') goto yy1361; + if (yych <= 'h') goto yy146; + goto yy1362; + } + } else { + if (yych <= 'q') { + if (yych == 'o') goto yy1363; + goto yy146; + } else { + if (yych <= 'r') goto yy1364; + if (yych <= 'z') goto yy146; + goto yy4; + } + } + } +yy15: + YYDEBUG(15, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'R') { + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy1320; + } + } else { + if (yych <= 'N') { + if (yych == 'I') goto yy1321; + goto yy141; + } else { + if (yych <= 'O') goto yy1322; + if (yych <= 'Q') goto yy141; + goto yy1323; + } + } + } else { + if (yych <= 'i') { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy141; + } else { + if (yych <= 'e') goto yy1320; + if (yych <= 'h') goto yy141; + goto yy1321; + } + } else { + if (yych <= 'q') { + if (yych == 'o') goto yy1322; + goto yy141; + } else { + if (yych <= 'r') goto yy1323; + if (yych <= 'z') goto yy141; + goto yy4; + } + } + } +yy16: + YYDEBUG(16, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1307; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych <= 'a') goto yy1317; + if (yych <= 'z') goto yy146; + goto yy4; + } + } +yy17: + YYDEBUG(17, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1307; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych <= 'a') goto yy1307; + if (yych <= 'z') goto yy141; + goto yy4; + } + } +yy18: + YYDEBUG(18, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1287; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych <= 'a') goto yy1304; + if (yych <= 'z') goto yy146; + goto yy4; + } + } +yy19: + YYDEBUG(19, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1287; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych <= 'a') goto yy1287; + if (yych <= 'z') goto yy141; + goto yy4; + } + } +yy20: + YYDEBUG(20, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'A') goto yy1230; + goto yy141; + } + } else { + if (yych <= 'H') { + if (yych <= 'E') goto yy1229; + goto yy141; + } else { + if (yych <= 'I') goto yy1231; + if (yych <= 'T') goto yy141; + goto yy1232; + } + } + } else { + if (yych <= 'e') { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych <= 'a') goto yy1259; + if (yych <= 'd') goto yy146; + goto yy1258; + } + } else { + if (yych <= 't') { + if (yych == 'i') goto yy1260; + goto yy146; + } else { + if (yych <= 'u') goto yy1261; + if (yych <= 'z') goto yy146; + goto yy4; + } + } + } +yy21: + YYDEBUG(21, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'A') goto yy1230; + goto yy141; + } + } else { + if (yych <= 'H') { + if (yych <= 'E') goto yy1229; + goto yy141; + } else { + if (yych <= 'I') goto yy1231; + if (yych <= 'T') goto yy141; + goto yy1232; + } + } + } else { + if (yych <= 'e') { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych <= 'a') goto yy1230; + if (yych <= 'd') goto yy141; + goto yy1229; + } + } else { + if (yych <= 't') { + if (yych == 'i') goto yy1231; + goto yy141; + } else { + if (yych <= 'u') goto yy1232; + if (yych <= 'z') goto yy141; + goto yy4; + } + } + } +yy22: + YYDEBUG(22, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'I') goto yy1199; + if (yych <= 'K') goto yy141; + goto yy1200; + } + } else { + if (yych <= 'i') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'h') goto yy146; + goto yy1217; + } else { + if (yych == 'l') goto yy1218; + if (yych <= 'z') goto yy146; + goto yy4; + } + } +yy23: + YYDEBUG(23, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'I') goto yy1199; + if (yych <= 'K') goto yy141; + goto yy1200; + } + } else { + if (yych <= 'i') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'h') goto yy141; + goto yy1199; + } else { + if (yych == 'l') goto yy1200; + if (yych <= 'z') goto yy141; + goto yy4; + } + } +yy24: + YYDEBUG(24, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy141; + goto yy1098; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy146; + } else { + if (yych <= 'r') goto yy1192; + if (yych <= 'z') goto yy146; + goto yy4; + } + } +yy25: + YYDEBUG(25, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy141; + goto yy1098; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy141; + } else { + if (yych <= 'r') goto yy1098; + if (yych <= 'z') goto yy141; + goto yy4; + } + } +yy26: + YYDEBUG(26, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); + switch (yych) { + case '\t': goto yy1052; + case ' ': + case 'A': + case 'D': + case 'F': + case 'H': + case 'I': + case 'J': + case 'M': + case 'N': + case 'O': + case 'S': + case 'T': case 'V': case 'W': case 'X': case 'Y': - case 'Z': goto yy141; - case 'I': goto yy1464; - case 'O': goto yy1465; - case 'a': goto yy1478; - case 'b': - case 'c': + case 'a': case 'd': - case 'e': case 'f': - case 'g': case 'h': case 'j': - case 'k': - case 'l': case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': + case 'o': case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'i': goto yy1479; - case 'o': goto yy1480; - default: goto yy4; + case 'y': goto yy1054; + case '-': goto yy473; + case '.': goto yy1064; + case '/': goto yy472; + case '0': goto yy1097; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy1096; + case ':': goto yy1065; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; } -yy9: - yych = *++YYCURSOR; +yy27: + YYDEBUG(27, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '\t': goto yy460; + case ' ': case 'A': - case 'a': goto yy1463; - case 'B': - case 'C': case 'D': - case 'E': case 'F': - case 'G': case 'H': + case 'I': case 'J': - case 'K': - case 'L': case 'M': case 'N': + case 'O': case 'P': - case 'Q': - case 'R': case 'S': case 'T': - case 'U': case 'V': case 'W': case 'X': case 'Y': - case 'Z': - case 'b': - case 'c': + case 'a': case 'd': - case 'e': case 'f': - case 'g': case 'h': case 'j': - case 'k': - case 'l': case 'm': - case 'n': + case 'o': case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'I': - case 'i': goto yy1464; - case 'O': - case 'o': goto yy1465; - default: goto yy4; - } -yy10: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; case '0': - case '1': goto yy1393; - case '2': goto yy1394; + case '1': + case '2': goto yy1096; case '3': case '4': case '5': case '6': case '7': case '8': - case '9': goto yy1395; + case '9': goto yy1063; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy28: + YYDEBUG(28, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); + switch (yych) { + case '\t': goto yy460; + case ' ': case 'A': - case 'B': - case 'C': case 'D': case 'F': - case 'G': + case 'H': case 'I': case 'J': - case 'K': - case 'L': case 'M': case 'N': + case 'O': case 'P': - case 'Q': - case 'R': case 'S': case 'T': case 'V': + case 'W': case 'X': case 'Y': - case 'Z': goto yy141; - case 'E': goto yy1388; - case 'H': goto yy1389; - case 'O': goto yy1390; - case 'U': goto yy1391; - case 'W': goto yy1392; case 'a': - case 'b': - case 'c': case 'd': case 'f': - case 'g': - case 'i': + case 'h': case 'j': - case 'k': - case 'l': case 'm': - case 'n': + case 'o': case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'x': - case 'y': - case 'z': goto yy146; - case 'e': goto yy1431; - case 'h': goto yy1432; - case 'o': goto yy1433; - case 'u': goto yy1434; - case 'w': goto yy1435; - default: goto yy4; - } -yy11: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; + case 'w': + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; case '0': - case '1': goto yy1393; - case '2': goto yy1394; + case '1': + case '2': case '3': - case '4': + case '4': goto yy1063; case '5': case '6': case '7': case '8': - case '9': goto yy1395; + case '9': goto yy1050; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; + } +yy29: + YYDEBUG(29, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); + switch (yych) { + case '\t': goto yy460; + case ' ': case 'A': - case 'B': - case 'C': case 'D': case 'F': - case 'G': + case 'H': case 'I': case 'J': - case 'K': - case 'L': case 'M': case 'N': + case 'O': case 'P': - case 'Q': - case 'R': case 'S': case 'T': case 'V': + case 'W': case 'X': case 'Y': - case 'Z': case 'a': - case 'b': - case 'c': case 'd': case 'f': - case 'g': - case 'i': + case 'h': case 'j': - case 'k': - case 'l': case 'm': - case 'n': + case 'o': case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'x': - case 'y': - case 'z': goto yy141; - case 'E': - case 'e': goto yy1388; - case 'H': - case 'h': goto yy1389; - case 'O': - case 'o': goto yy1390; - case 'U': - case 'u': goto yy1391; - case 'W': - case 'w': goto yy1392; - default: goto yy4; - } -yy12: - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy1384; + case 'w': + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; case '0': - case '1': + case '1': goto yy1050; case '2': case '3': case '4': @@ -1482,24971 +1902,7666 @@ static int scan(Scanner *s) case '6': case '7': case '8': - case '9': goto yy1385; + case '9': goto yy469; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; default: goto yy13; } -yy13: -#line 1751 "ext/date/lib/parse_date.re" - { - add_error(s, "Unexpected character"); - goto std; - } -#line 1495 "" -yy14: - yych = *++YYCURSOR; +yy30: + YYDEBUG(30, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '\t': goto yy460; + case ' ': case 'A': - case 'B': - case 'C': case 'D': case 'F': - case 'G': case 'H': + case 'I': case 'J': - case 'K': - case 'L': case 'M': case 'N': + case 'O': case 'P': - case 'Q': case 'S': case 'T': - case 'U': case 'V': case 'W': case 'X': case 'Y': - case 'Z': goto yy141; - case 'E': goto yy1320; - case 'I': goto yy1321; - case 'O': goto yy1322; - case 'R': goto yy1323; case 'a': - case 'b': - case 'c': case 'd': case 'f': - case 'g': case 'h': case 'j': - case 'k': - case 'l': case 'm': - case 'n': + case 'o': case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'e': goto yy1361; - case 'i': goto yy1362; - case 'o': goto yy1363; - case 'r': goto yy1364; - default: goto yy4; + case 'y': goto yy462; + case '-': goto yy473; + case '.': goto yy474; + case '/': goto yy472; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy469; + case ':': goto yy483; + case 'n': goto yy470; + case 'r': goto yy471; + case 's': goto yy464; + case 't': goto yy468; + default: goto yy13; } -yy15: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'E': - case 'e': goto yy1320; - case 'I': - case 'i': goto yy1321; - case 'O': - case 'o': goto yy1322; - case 'R': - case 'r': goto yy1323; - default: goto yy4; +yy31: + YYDEBUG(31, *YYCURSOR); + yyaccept = 1; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 4) { + goto yy58; } -yy16: - yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; - case 'A': goto yy1307; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'a': goto yy1317; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; + case '+': + case '-': goto yy440; + case '0': + case '1': goto yy437; + case '2': goto yy438; + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy439; + default: goto yy13; } -yy17: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1307; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - default: goto yy4; +yy32: + YYDEBUG(32, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy4; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy4; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy4; + } else { + if (yych == '/') goto yy4; + goto yy196; + } + } + } else { + if (yych <= 'V') { + if (yych <= 'H') { + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'I') goto yy436; + if (yych <= 'U') goto yy141; + goto yy435; + } + } else { + if (yych <= 'Z') { + if (yych == 'X') goto yy435; + goto yy141; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy146; + goto yy4; + } + } } -yy18: +yy33: + YYDEBUG(33, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy4; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy196; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'Z') { + if (yych <= 'I') goto yy432; + goto yy141; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy146; + goto yy4; + } + } + } +yy34: + YYDEBUG(34, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy4; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy196; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'Z') { + if (yych <= 'I') goto yy430; + goto yy141; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy146; + goto yy4; + } + } + } +yy35: + YYDEBUG(35, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': goto yy1287; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'a': goto yy1304; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; + if (yych <= 'U') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'A') goto yy413; + if (yych <= 'T') goto yy141; + goto yy412; + } + } else { + if (yych <= 'a') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy422; + } else { + if (yych == 'u') goto yy421; + if (yych <= 'z') goto yy146; + goto yy4; + } } -yy19: +yy36: + YYDEBUG(36, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1287; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - default: goto yy4; + if (yych <= 'U') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'A') goto yy413; + if (yych <= 'T') goto yy141; + goto yy412; + } + } else { + if (yych <= 'a') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy413; + } else { + if (yych == 'u') goto yy412; + if (yych <= 'z') goto yy141; + goto yy4; + } } -yy20: +yy37: + YYDEBUG(37, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': goto yy1230; - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'E': goto yy1229; - case 'I': goto yy1231; - case 'U': goto yy1232; - case 'a': goto yy1259; - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'e': goto yy1258; - case 'i': goto yy1260; - case 'u': goto yy1261; - default: goto yy4; + if (yych <= 'U') { + if (yych <= 'F') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'O') { + if (yych <= 'G') goto yy391; + goto yy141; + } else { + if (yych <= 'P') goto yy390; + if (yych <= 'T') goto yy141; + goto yy389; + } + } + } else { + if (yych <= 'o') { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych == 'g') goto yy403; + goto yy146; + } + } else { + if (yych <= 't') { + if (yych <= 'p') goto yy402; + goto yy146; + } else { + if (yych <= 'u') goto yy401; + if (yych <= 'z') goto yy146; + goto yy4; + } + } } -yy21: +yy38: + YYDEBUG(38, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1230; - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'E': - case 'e': goto yy1229; - case 'I': - case 'i': goto yy1231; - case 'U': - case 'u': goto yy1232; - default: goto yy4; + if (yych <= 'U') { + if (yych <= 'F') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'O') { + if (yych <= 'G') goto yy391; + goto yy141; + } else { + if (yych <= 'P') goto yy390; + if (yych <= 'T') goto yy141; + goto yy389; + } + } + } else { + if (yych <= 'o') { + if (yych <= '`') { + if (yych <= 'Z') goto yy141; + goto yy4; + } else { + if (yych == 'g') goto yy391; + goto yy141; + } + } else { + if (yych <= 't') { + if (yych <= 'p') goto yy390; + goto yy141; + } else { + if (yych <= 'u') goto yy389; + if (yych <= 'z') goto yy141; + goto yy4; + } + } } -yy22: +yy39: + YYDEBUG(39, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'I': goto yy1199; - case 'L': goto yy1200; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'i': goto yy1217; - case 'l': goto yy1218; - default: goto yy4; + if (yych <= 'C') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'B') goto yy141; + goto yy379; + } + } else { + if (yych <= 'b') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy146; + } else { + if (yych <= 'c') goto yy384; + if (yych <= 'z') goto yy146; + goto yy4; + } } -yy23: +yy40: + YYDEBUG(40, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'I': - case 'i': goto yy1199; - case 'L': - case 'l': goto yy1200; - default: goto yy4; + if (yych <= 'C') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'B') goto yy141; + goto yy379; + } + } else { + if (yych <= 'b') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy141; + } else { + if (yych <= 'c') goto yy379; + if (yych <= 'z') goto yy141; + goto yy4; + } } -yy24: +yy41: + YYDEBUG(41, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'R': goto yy1098; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'r': goto yy1192; - default: goto yy4; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy192; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy146; + } else { + if (yych <= 'e') goto yy370; + if (yych <= 'z') goto yy146; + goto yy4; + } } -yy25: +yy42: + YYDEBUG(42, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'R': - case 'r': goto yy1098; - default: goto yy4; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy192; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy141; + } else { + if (yych <= 'e') goto yy192; + if (yych <= 'z') goto yy141; + goto yy4; + } } -yy26: - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy1052; - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'o': - case 'w': - case 'y': goto yy1054; - case '-': goto yy473; - case '.': goto yy1064; - case '/': goto yy472; - case '0': goto yy1097; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1096; - case ':': goto yy1065; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; +yy43: + YYDEBUG(43, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy165; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy146; + } else { + if (yych <= 'e') goto yy179; + if (yych <= 'z') goto yy146; + goto yy4; + } } -yy27: - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy460; - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'P': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'o': - case 'p': - case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; - case '0': - case '1': - case '2': goto yy1096; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1063; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; +yy44: + YYDEBUG(44, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy141; + goto yy165; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + goto yy141; + } else { + if (yych <= 'e') goto yy165; + if (yych <= 'z') goto yy141; + goto yy4; + } } -yy28: - yyaccept = 1; +yy45: + YYDEBUG(45, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy141; + } else { + if (yych <= 'Z') { + if (yych <= 'M') goto yy157; + goto yy141; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy146; + goto yy4; + } + } +yy46: + YYDEBUG(46, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') goto yy13; + if (yych <= 'Z') goto yy156; + if (yych <= '`') goto yy13; + if (yych <= 'z') goto yy156; + goto yy13; +yy47: + YYDEBUG(47, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy146; + goto yy4; + } +yy48: + YYDEBUG(48, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy141; + goto yy4; + } +yy49: + YYDEBUG(49, *YYCURSOR); + yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy460; - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'P': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'o': - case 'p': - case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy1063; - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1050; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; - } -yy29: - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy460; - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'P': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'o': - case 'p': - case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; - case '0': - case '1': goto yy1050; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy469; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; - } -yy30: - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy460; - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'P': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'o': - case 'p': - case 'w': - case 'y': goto yy462; - case '-': goto yy473; - case '.': goto yy474; - case '/': goto yy472; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy469; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy13; - } -yy31: - yyaccept = 1; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy58; - case '+': - case '-': goto yy440; - case '0': - case '1': goto yy437; - case '2': goto yy438; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy439; - default: goto yy13; - } -yy32: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'Y': - case 'Z': goto yy141; - case 'I': goto yy436; - case 'V': - case 'X': goto yy435; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; - } -yy33: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'I': goto yy432; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; - } -yy34: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'I': goto yy430; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; - } -yy35: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': goto yy413; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'U': goto yy412; - case 'a': goto yy422; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'u': goto yy421; - default: goto yy4; - } -yy36: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy413; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'U': - case 'u': goto yy412; - default: goto yy4; - } -yy37: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'G': goto yy391; - case 'P': goto yy390; - case 'U': goto yy389; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'g': goto yy403; - case 'p': goto yy402; - case 'u': goto yy401; - default: goto yy4; - } -yy38: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'G': - case 'g': goto yy391; - case 'P': - case 'p': goto yy390; - case 'U': - case 'u': goto yy389; - default: goto yy4; - } -yy39: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'C': goto yy379; - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'c': goto yy384; - default: goto yy4; - } -yy40: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'C': - case 'c': goto yy379; - default: goto yy4; - } -yy41: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'E': goto yy192; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'e': goto yy370; - default: goto yy4; - } -yy42: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'E': - case 'e': goto yy192; - default: goto yy4; - } -yy43: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'E': goto yy165; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - case 'e': goto yy179; - default: goto yy4; - } -yy44: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - case 'E': - case 'e': goto yy165; - default: goto yy4; - } -yy45: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'M': goto yy157; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; - } -yy46: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy156; - default: goto yy13; - } -yy47: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy141; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy146; - default: goto yy4; - } -yy48: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - default: goto yy4; - } -yy49: - yyaccept = 2; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy58; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy50; - } -yy50: -#line 1740 "ext/date/lib/parse_date.re" - { - goto std; - } -#line 3523 "" -yy51: - yych = *++YYCURSOR; - goto yy50; -yy52: - ++YYCURSOR; -#line 1745 "ext/date/lib/parse_date.re" - { - s->pos = cursor; s->line++; - goto std; - } -#line 3534 "" -yy54: - yych = *++YYCURSOR; - goto yy13; -yy55: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy60; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - case 'D': - case 'd': goto yy65; - case 'F': - case 'f': goto yy66; - case 'H': - case 'h': goto yy64; - case 'M': - case 'm': goto yy63; - case 'S': - case 's': goto yy62; - case 'T': - case 't': goto yy69; - case 'W': - case 'w': goto yy68; - case 'Y': - case 'y': goto yy67; - default: goto yy57; - } -yy57: - YYCURSOR = YYMARKER; - switch (yyaccept) { - case 0: goto yy4; - case 1: goto yy13; - case 2: goto yy50; - case 3: goto yy73; - case 4: goto yy167; - case 5: goto yy194; - case 6: goto yy199; - case 7: goto yy223; - case 8: goto yy295; - case 9: goto yy393; - case 10: goto yy476; - case 11: goto yy491; - case 12: goto yy612; - case 13: goto yy657; - case 14: goto yy667; - case 15: goto yy764; - case 16: goto yy784; - case 17: goto yy815; - case 18: goto yy822; - case 19: goto yy849; - case 20: goto yy794; - case 21: goto yy455; - case 22: goto yy974; - case 23: goto yy843; - case 24: goto yy1068; - case 25: goto yy1076; - case 26: goto yy1118; - case 27: goto yy1142; - case 28: goto yy1295; - case 29: goto yy1417; - case 30: goto yy1420; - case 31: goto yy1500; - case 32: goto yy1508; - case 33: goto yy1531; - } -yy58: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy58; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy57; - } -yy60: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); - yych = *YYCURSOR; -yy61: - switch (yych) { - case '\t': - case ' ': goto yy60; - case 'D': - case 'd': goto yy65; - case 'F': - case 'f': goto yy66; - case 'H': - case 'h': goto yy64; - case 'M': - case 'm': goto yy63; - case 'S': - case 's': goto yy62; - case 'T': - case 't': goto yy69; - case 'W': - case 'w': goto yy68; - case 'Y': - case 'y': goto yy67; - default: goto yy57; - } -yy62: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy127; - case 'E': - case 'e': goto yy128; - case 'U': - case 'u': goto yy126; - default: goto yy57; - } -yy63: - yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy118; - case 'O': - case 'o': goto yy117; - default: goto yy57; - } -yy64: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy115; - default: goto yy57; - } -yy65: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy114; - default: goto yy57; - } -yy66: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy99; - case 'R': - case 'r': goto yy98; - default: goto yy57; - } -yy67: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy95; - default: goto yy57; - } -yy68: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy83; - default: goto yy57; - } -yy69: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy70; - case 'U': - case 'u': goto yy71; - default: goto yy57; - } -yy70: - yych = *++YYCURSOR; - switch (yych) { - case 'U': - case 'u': goto yy78; - default: goto yy57; - } -yy71: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy72; - default: goto yy57; - } -yy72: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'S': - case 's': goto yy74; - default: goto yy73; - } -yy73: -#line 1724 "ext/date/lib/parse_date.re" - { - timelib_ull i; - DEBUG_OUTPUT("relative"); - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - - while(*ptr) { - i = timelib_get_unsigned_nr((char **) &ptr, 24); - timelib_eat_spaces((char **) &ptr); - timelib_set_relative((char **) &ptr, i, 1, s); - } - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; - } -#line 3760 "" -yy74: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy75; - default: goto yy57; - } -yy75: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy76; - default: goto yy57; - } -yy76: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy77: - yych = *++YYCURSOR; - goto yy73; -yy78: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'R': - case 'r': goto yy79; - default: goto yy73; - } -yy79: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy80; - default: goto yy57; - } -yy80: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy81; - default: goto yy57; - } -yy81: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy82; - default: goto yy57; - } -yy82: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy83: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy85; - case 'E': - case 'e': goto yy84; - default: goto yy57; - } -yy84: - yych = *++YYCURSOR; - switch (yych) { - case 'K': - case 'k': goto yy91; - default: goto yy57; - } -yy85: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'N': - case 'n': goto yy86; - default: goto yy73; - } -yy86: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy87; - default: goto yy57; - } -yy87: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy88; - default: goto yy57; - } -yy88: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy89; - default: goto yy57; - } -yy89: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy90; - default: goto yy57; - } -yy90: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy91: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'D': - case 'd': goto yy92; - case 'S': - case 's': goto yy77; - default: goto yy73; - } -yy92: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy93; - default: goto yy57; - } -yy93: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy94; - default: goto yy57; - } -yy94: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy77; - default: goto yy73; - } -yy95: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy96; - default: goto yy57; - } -yy96: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy97; - default: goto yy57; - } -yy97: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy77; - default: goto yy73; - } -yy98: - yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy111; - default: goto yy57; - } -yy99: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy100; - default: goto yy57; - } -yy100: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy101; - default: goto yy57; - } -yy101: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy103; - case 'N': - case 'n': goto yy102; - default: goto yy57; - } -yy102: - yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy108; - default: goto yy57; - } -yy103: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy104; - default: goto yy57; - } -yy104: - yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy105; - default: goto yy57; - } -yy105: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy106; - default: goto yy57; - } -yy106: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy107; - default: goto yy57; - } -yy107: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy97; - default: goto yy57; - } -yy108: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy109; - default: goto yy57; - } -yy109: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy110; - default: goto yy57; - } -yy110: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy97; - default: goto yy57; - } -yy111: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'D': - case 'd': goto yy112; - default: goto yy73; - } -yy112: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy113; - default: goto yy57; - } -yy113: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy114: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy97; - default: goto yy57; - } -yy115: - yych = *++YYCURSOR; - switch (yych) { - case 'U': - case 'u': goto yy116; - default: goto yy57; - } -yy116: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy97; - default: goto yy57; - } -yy117: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy122; - default: goto yy57; - } -yy118: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy119; - default: goto yy57; - } -yy119: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'S': - case 's': goto yy77; - case 'U': - case 'u': goto yy120; - default: goto yy73; - } -yy120: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy121; - default: goto yy57; - } -yy121: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy97; - default: goto yy57; - } -yy122: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'D': - case 'd': goto yy123; - case 'T': - case 't': goto yy124; - default: goto yy73; - } -yy123: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy125; - default: goto yy57; - } -yy124: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy97; - default: goto yy57; - } -yy125: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy126: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy137; - default: goto yy57; - } -yy127: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy132; - default: goto yy57; - } -yy128: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy129; - default: goto yy57; - } -yy129: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'O': - case 'o': goto yy130; - case 'S': - case 's': goto yy77; - default: goto yy73; - } -yy130: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy131; - default: goto yy57; - } -yy131: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy97; - default: goto yy57; - } -yy132: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'U': - case 'u': goto yy133; - default: goto yy73; - } -yy133: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy134; - default: goto yy57; - } -yy134: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy135; - default: goto yy57; - } -yy135: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy136; - default: goto yy57; - } -yy136: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy137: - yyaccept = 3; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'D': - case 'd': goto yy138; - default: goto yy73; - } -yy138: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy139; - default: goto yy57; - } -yy139: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy77; - default: goto yy57; - } -yy140: - yych = *++YYCURSOR; - goto yy4; -yy141: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - default: goto yy4; - } -yy142: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy4; - } -yy143: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; - } -yy144: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; - } -yy145: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - default: goto yy4; - } -yy146: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - default: goto yy4; - } -yy147: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - default: goto yy4; - } -yy148: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy149; - default: goto yy57; - } -yy149: - yyaccept = 0; - YYMARKER = ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy149; - default: goto yy4; - } -yy151: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; - } -yy152: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; - } -yy153: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy4; - } -yy154: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; -yy155: - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy57; - } -yy156: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy141; - default: goto yy4; - } -yy157: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'T': goto yy158; - default: goto yy4; - } -yy158: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '+': - case '-': goto yy159; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy4; - } -yy159: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy160; - case '2': goto yy161; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy162; - default: goto yy57; - } -yy160: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy162; - case ':': goto yy163; - default: goto yy4; - } -yy161: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy162; - case '5': goto yy164; - case '6': - case '7': - case '8': - case '9': goto yy140; - case ':': goto yy163; - default: goto yy4; - } -yy162: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy164; - case '6': - case '7': - case '8': - case '9': goto yy140; - case ':': goto yy163; - default: goto yy4; - } -yy163: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy164; - case '6': - case '7': - case '8': - case '9': goto yy140; - default: goto yy4; - } -yy164: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy140; - default: goto yy4; - } -yy165: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'D': - case 'd': goto yy166; - case 'E': - case 'e': goto yy168; - default: goto yy4; - } -yy166: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'N': - case 'n': goto yy174; - default: goto yy167; - } -yy167: -#line 1587 "ext/date/lib/parse_date.re" - { - const timelib_relunit* relunit; - DEBUG_OUTPUT("daytext"); - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - TIMELIB_HAVE_WEEKDAY_RELATIVE(); - TIMELIB_UNHAVE_TIME(); - relunit = timelib_lookup_relunit((char**) &ptr); - s->time->relative.weekday = relunit->multiplier; - if (s->time->relative.weekday_behavior != 2) { - s->time->relative.weekday_behavior = 1; - } - - TIMELIB_DEINIT; - return TIMELIB_WEEKDAY; - } -#line 5328 "" -yy168: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'K': - case 'k': goto yy169; - default: goto yy4; - } -yy169: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'D': - case 'd': goto yy170; - default: goto yy4; - } -yy170: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy171; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; - } -yy171: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'Y': - case 'y': goto yy172; - default: goto yy4; - } -yy172: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy173; - default: goto yy167; - } -yy173: - yych = *++YYCURSOR; - goto yy167; -yy174: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'E': - case 'e': goto yy175; - default: goto yy4; - } -yy175: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'S': - case 's': goto yy176; - default: goto yy4; - } -yy176: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'D': - case 'd': goto yy177; - default: goto yy4; - } -yy177: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy178; - default: goto yy57; - } -yy178: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy173; - default: goto yy57; - } -yy179: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'D': goto yy166; - case 'E': goto yy168; - case 'a': - case 'b': - case 'c': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'd': goto yy180; - case 'e': goto yy181; - default: goto yy4; - } -yy180: - yyaccept = 4; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'N': goto yy174; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'n': goto yy187; - default: goto yy167; - } -yy181: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'K': goto yy169; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'k': goto yy182; - default: goto yy4; - } -yy182: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'D': goto yy170; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'd': goto yy183; - default: goto yy4; - } -yy183: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy171; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': goto yy184; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; - } -yy184: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'Y': goto yy172; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy154; - case 'y': goto yy185; - default: goto yy4; - } -yy185: - yyaccept = 4; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'S': goto yy173; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 's': goto yy186; - default: goto yy167; - } -yy186: - yyaccept = 4; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy167; - } -yy187: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'E': goto yy175; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'e': goto yy188; - default: goto yy4; - } -yy188: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'S': goto yy176; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 's': goto yy189; - default: goto yy4; - } -yy189: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'D': goto yy177; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'd': goto yy190; - default: goto yy4; - } -yy190: - yych = *++YYCURSOR; - switch (yych) { - case 'A': goto yy178; - case 'a': goto yy191; - default: goto yy155; - } -yy191: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': goto yy173; - case 'y': goto yy186; - default: goto yy155; - } -yy192: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'C': - case 'c': goto yy193; - default: goto yy4; - } -yy193: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'E': - case 'e': goto yy202; - default: goto yy194; - } -yy194: -#line 1646 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("monthtext"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_lookup_month((char **) &ptr); - TIMELIB_DEINIT; - return TIMELIB_DATE_TEXT; - } -#line 6394 "" -yy195: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 21) YYFILL(21); - yych = *YYCURSOR; -yy196: - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy195; - case '0': - case '1': - case '2': goto yy198; - case '3': goto yy200; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy201; - default: goto yy57; - } -yy197: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy357; - case '1': - case '2': goto yy358; - case '3': goto yy359; - default: goto yy196; - } -yy198: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy298; - case '1': goto yy299; - case '2': goto yy355; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy356; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy199: -#line 1396 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("datetextual | datenoyear"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_get_month((char **) &ptr); - s->time->d = timelib_get_nr((char **) &ptr, 2); - s->time->y = timelib_get_nr((char **) &ptr, 4); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_DATE_TEXT; - } -#line 6459 "" -yy200: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy298; - case '1': goto yy299; - case '2': goto yy209; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy210; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy201: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy207; - case '1': goto yy208; - case '2': goto yy209; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy210; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy202: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'M': - case 'm': goto yy203; - default: goto yy4; - } -yy203: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'B': - case 'b': goto yy204; - default: goto yy4; - } -yy204: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'E': - case 'e': goto yy205; - default: goto yy4; - } -yy205: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy206; - default: goto yy57; - } -yy206: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - default: goto yy194; - } -yy207: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy221; - case '0': goto yy296; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - default: goto yy57; - } -yy208: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': goto yy297; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy296; - default: goto yy57; - } -yy209: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy296; - case '5': - case '6': - case '7': - case '8': - case '9': goto yy293; - default: goto yy57; - } -yy210: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy293; - default: goto yy57; - } -yy211: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - goto yy216; -yy212: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - goto yy216; -yy213: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - goto yy216; -yy214: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - goto yy216; -yy215: - yyaccept = 6; - YYMARKER = ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 18) YYFILL(18); - yych = *YYCURSOR; -yy216: - switch (yych) { - case '\t': - case ' ': - case ',': - case '.': - case 'd': - case 'h': - case 'n': - case 'r': - case 's': - case 't': goto yy215; - case '0': goto yy259; - case '1': goto yy260; - case '2': goto yy261; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy262; - case 'T': goto yy217; - default: goto yy199; - } -yy217: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy218; - case '2': goto yy219; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy220; - default: goto yy57; - } -yy218: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy221; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy220; - default: goto yy57; - } -yy219: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy221; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy220; - default: goto yy57; - } -yy220: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy221; - default: goto yy57; - } -yy221: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy222; - case '6': - case '7': - case '8': - case '9': goto yy224; - default: goto yy57; - } -yy222: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy224; - default: goto yy223; - } -yy223: -#line 1694 "ext/date/lib/parse_date.re" - { - int tz_not_found; - DEBUG_OUTPUT("dateshortwithtimeshort | dateshortwithtimelong | dateshortwithtimelongtz"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_get_month((char **) &ptr); - s->time->d = timelib_get_nr((char **) &ptr, 2); - - TIMELIB_HAVE_TIME(); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - if (*ptr == ':') { - s->time->s = timelib_get_nr((char **) &ptr, 2); - - if (*ptr == '.') { - s->time->f = timelib_get_frac_nr((char **) &ptr, 8); - } - } - - if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); - if (tz_not_found) { - add_error(s, "The timezone could not be found in the database"); - } - } - TIMELIB_DEINIT; - return TIMELIB_SHORTDATE_WITH_TIME; - } -#line 6880 "" -yy224: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - default: goto yy223; - } -yy225: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy226; - case '6': goto yy227; - case '7': - case '8': - case '9': goto yy228; - default: goto yy57; - } -yy226: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy229; - default: goto yy223; - } -yy227: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy229; - default: goto yy223; - } -yy228: - yych = *++YYCURSOR; - goto yy223; -yy229: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '(': - case '+': - case '-': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy231; - default: goto yy223; - } -yy230: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); - yych = *YYCURSOR; -yy231: - switch (yych) { - case '\t': - case ' ': goto yy230; - case '(': goto yy234; - case '+': - case '-': goto yy233; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy235; - case 'G': goto yy232; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy236; - default: goto yy57; - } -yy232: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy237; - case 'M': goto yy257; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy242; - default: goto yy223; - } -yy233: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy252; - case '2': goto yy253; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy254; - default: goto yy57; - } -yy234: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy236; - default: goto yy57; - } -yy235: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy237; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy242; - default: goto yy223; - } -yy236: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy237; - default: goto yy223; - } -yy237: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy238; - default: goto yy223; - } -yy238: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy239; - default: goto yy223; - } -yy239: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy240; - default: goto yy223; - } -yy240: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy241; - default: goto yy223; - } -yy241: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - default: goto yy223; - } -yy242: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy238; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy243; - default: goto yy223; - } -yy243: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy239; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy247; - default: goto yy223; - } -yy244: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy245; - default: goto yy57; - } -yy245: - yyaccept = 7; - YYMARKER = ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case '-': - case '/': - case '_': goto yy244; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy245; - default: goto yy223; - } -yy247: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy240; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy248; - default: goto yy223; - } -yy248: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy241; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy249; - default: goto yy223; - } -yy249: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy250; - default: goto yy223; - } -yy250: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case '-': - case '/': - case '_': goto yy244; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy250; - default: goto yy57; - } -yy252: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy254; - case ':': goto yy255; - default: goto yy223; - } -yy253: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy254; - case '5': goto yy256; - case '6': - case '7': - case '8': - case '9': goto yy228; - case ':': goto yy255; - default: goto yy223; - } -yy254: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy256; - case '6': - case '7': - case '8': - case '9': goto yy228; - case ':': goto yy255; - default: goto yy223; - } -yy255: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy256; - case '6': - case '7': - case '8': - case '9': goto yy228; - default: goto yy223; - } -yy256: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy228; - default: goto yy223; - } -yy257: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy228; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy238; - case 'T': goto yy258; - default: goto yy223; - } -yy258: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '+': - case '-': goto yy233; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy239; - default: goto yy223; - } -yy259: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy221; - case '0': goto yy291; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy292; - default: goto yy199; - } -yy260: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': goto yy292; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy291; - default: goto yy199; - } -yy261: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy291; - case '5': - case '6': - case '7': - case '8': - case '9': goto yy263; - default: goto yy199; - } -yy262: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy263; - default: goto yy199; - } -yy263: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - default: goto yy199; - } -yy264: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy265; - case '6': - case '7': - case '8': - case '9': goto yy266; - default: goto yy57; - } -yy265: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy267; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy282; - default: goto yy223; - } -yy266: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy267; - default: goto yy223; - } -yy267: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy268; - case '6': goto yy269; - case '7': - case '8': - case '9': goto yy228; - default: goto yy57; - } -yy268: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy270; - default: goto yy223; - } -yy269: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy270; - default: goto yy223; - } -yy270: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '(': - case '+': - case '-': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy272; - default: goto yy223; - } -yy271: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); - yych = *YYCURSOR; -yy272: - switch (yych) { - case '\t': - case ' ': goto yy271; - case '(': goto yy234; - case '+': - case '-': goto yy233; - case 'A': - case 'P': goto yy273; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy235; - case 'G': goto yy232; - case 'a': - case 'p': goto yy274; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy236; - default: goto yy57; - } -yy273: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '.': goto yy275; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy237; - case 'M': goto yy276; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy242; - case 'm': goto yy281; - default: goto yy223; - } -yy274: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '.': goto yy275; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy237; - case 'M': - case 'm': goto yy276; - default: goto yy223; - } -yy275: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy280; - default: goto yy57; - } -yy276: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case ')': goto yy228; - case '.': goto yy277; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy238; - default: goto yy223; - } -yy277: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - default: goto yy57; - } -yy278: - ++YYCURSOR; -#line 1670 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("dateshortwithtimeshort12 | dateshortwithtimelong12"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_get_month((char **) &ptr); - s->time->d = timelib_get_nr((char **) &ptr, 2); - - TIMELIB_HAVE_TIME(); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - if (*ptr == ':' || *ptr == '.') { - s->time->s = timelib_get_nr((char **) &ptr, 2); - - if (*ptr == '.') { - s->time->f = timelib_get_frac_nr((char **) &ptr, 8); - } - } - - s->time->h += timelib_meridian((char **) &ptr, s->time->h); - TIMELIB_DEINIT; - return TIMELIB_SHORTDATE_WITH_TIME; - } -#line 8694 "" -yy280: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case '.': goto yy277; - default: goto yy57; - } -yy281: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case '.': goto yy277; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy238; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy243; - default: goto yy223; - } -yy282: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy283; - case '.': - case ':': goto yy267; - case 'A': - case 'P': - case 'a': - case 'p': goto yy285; - default: goto yy223; - } -yy283: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy283; - case 'A': - case 'P': - case 'a': - case 'p': goto yy285; - default: goto yy57; - } -yy285: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy286; - case 'M': - case 'm': goto yy287; - default: goto yy57; - } -yy286: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy287; - default: goto yy57; - } -yy287: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case '.': goto yy288; - default: goto yy57; - } -yy288: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - default: goto yy57; - } -yy289: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy290; - default: goto yy199; - } -yy290: - yych = *++YYCURSOR; - goto yy199; -yy291: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy221; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - default: goto yy199; - } -yy292: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - default: goto yy199; - } -yy293: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy294; - default: goto yy57; - } -yy294: - ++YYCURSOR; -yy295: -#line 1370 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("datenoday"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_get_month((char **) &ptr); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->d = 1; - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_DATE_NO_DAY; - } -#line 8913 "" -yy296: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy221; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy294; - default: goto yy57; - } -yy297: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy294; - default: goto yy57; - } -yy298: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy331; - case '0': goto yy332; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy221; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy299: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy300; - case '0': goto yy301; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy264; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy300: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy306; - case '1': goto yy307; - case '2': goto yy308; - case '3': - case '4': - case '5': goto yy309; - case '6': - case '7': - case '8': - case '9': goto yy310; - default: goto yy216; - } -yy301: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': goto yy304; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy305; - default: goto yy57; - } -yy302: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': goto yy305; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy304; - default: goto yy57; - } -yy303: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy264; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy304; - case '5': - case '6': - case '7': - case '8': - case '9': goto yy294; - default: goto yy57; - } -yy304: - yyaccept = 8; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy221; - default: goto yy295; - } -yy305: - yyaccept = 8; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy264; - default: goto yy295; - } -yy306: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy326; - case '0': goto yy325; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy330; - default: goto yy199; - } -yy307: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy311; - case '0': - case '1': - case '2': goto yy330; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy325; - default: goto yy199; - } -yy308: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy311; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy325; - case '5': - case '6': - case '7': - case '8': - case '9': goto yy324; - default: goto yy199; - } -yy309: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy311; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy324; - default: goto yy199; - } -yy310: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy311; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy263; - default: goto yy199; - } -yy311: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy312; - case '6': goto yy313; - case '7': - case '8': - case '9': goto yy266; - default: goto yy57; - } -yy312: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy267; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy314; - default: goto yy223; - } -yy313: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy267; - case '0': goto yy270; - default: goto yy223; - } -yy314: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '(': - case '+': - case '-': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy316; - case '.': - case ':': goto yy267; - default: goto yy223; - } -yy315: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); - yych = *YYCURSOR; -yy316: - switch (yych) { - case '\t': - case ' ': goto yy315; - case '(': goto yy234; - case '+': - case '-': goto yy233; - case 'A': - case 'P': goto yy317; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy235; - case 'G': goto yy232; - case 'a': - case 'p': goto yy318; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy236; - default: goto yy57; - } -yy317: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '.': goto yy320; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy237; - case 'M': goto yy319; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy242; - case 'm': goto yy323; - default: goto yy223; - } -yy318: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '.': goto yy320; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy237; - case 'M': - case 'm': goto yy319; - default: goto yy223; - } -yy319: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case ')': goto yy228; - case '.': goto yy322; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy238; - default: goto yy223; - } -yy320: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy321; - default: goto yy57; - } -yy321: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case '.': goto yy322; - default: goto yy57; - } -yy322: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - default: goto yy57; - } -yy323: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case '.': goto yy322; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy238; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy243; - default: goto yy223; - } -yy324: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy283; - case '.': - case ':': goto yy267; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - case 'A': - case 'P': - case 'a': - case 'p': goto yy285; - default: goto yy199; - } -yy325: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy283; - case '.': - case ':': goto yy326; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - case 'A': - case 'P': - case 'a': - case 'p': goto yy285; - default: goto yy199; - } -yy326: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy327; - case '6': goto yy328; - case '7': - case '8': - case '9': goto yy224; - default: goto yy57; - } -yy327: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy329; - default: goto yy223; - } -yy328: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - case '0': goto yy270; - default: goto yy223; - } -yy329: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '(': - case '+': - case '-': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy272; - case '.': - case ':': goto yy225; - default: goto yy223; - } -yy330: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy283; - case '.': - case ':': goto yy311; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - case 'A': - case 'P': - case 'a': - case 'p': goto yy285; - default: goto yy199; - } -yy331: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy333; - case '1': goto yy334; - case '2': goto yy335; - case '3': - case '4': - case '5': goto yy336; - case '6': - case '7': - case '8': - case '9': goto yy337; - default: goto yy216; - } -yy332: - yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy221; - case '0': goto yy304; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy305; - default: goto yy57; - } -yy333: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy350; - case '0': goto yy349; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy354; - default: goto yy199; - } -yy334: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy338; - case '0': - case '1': - case '2': goto yy354; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy349; - default: goto yy199; - } -yy335: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy338; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy349; - case '5': - case '6': - case '7': - case '8': - case '9': goto yy348; - default: goto yy199; - } -yy336: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy338; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy348; - default: goto yy199; - } -yy337: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy338; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy263; - default: goto yy199; - } -yy338: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy339; - case '6': goto yy340; - case '7': - case '8': - case '9': goto yy266; - default: goto yy57; - } -yy339: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy267; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy341; - default: goto yy223; - } -yy340: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy267; - case '0': goto yy229; - default: goto yy223; - } -yy341: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '(': - case '+': - case '-': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy343; - case '.': - case ':': goto yy267; - default: goto yy223; - } -yy342: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); - yych = *YYCURSOR; -yy343: - switch (yych) { - case '\t': - case ' ': goto yy342; - case '(': goto yy234; - case '+': - case '-': goto yy233; - case 'A': - case 'P': goto yy344; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy235; - case 'G': goto yy232; - case 'a': - case 'p': goto yy345; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy236; - default: goto yy57; - } -yy344: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '.': goto yy286; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy237; - case 'M': goto yy346; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy242; - case 'm': goto yy347; - default: goto yy223; - } -yy345: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy228; - case '.': goto yy286; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy237; - case 'M': - case 'm': goto yy346; - default: goto yy223; - } -yy346: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case ')': goto yy228; - case '.': goto yy288; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy238; - default: goto yy223; - } -yy347: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy278; - case ')': goto yy228; - case '-': - case '/': - case '_': goto yy244; - case '.': goto yy288; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy238; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy243; - default: goto yy223; - } -yy348: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - default: goto yy199; - } -yy349: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy350; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - default: goto yy199; - } -yy350: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy351; - case '6': goto yy352; - case '7': - case '8': - case '9': goto yy224; - default: goto yy57; - } -yy351: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy353; - default: goto yy223; - } -yy352: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy225; - case '0': goto yy229; - default: goto yy223; - } -yy353: - yyaccept = 7; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '(': - case '+': - case '-': - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy231; - case '.': - case ':': goto yy225; - default: goto yy223; - } -yy354: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy338; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy289; - default: goto yy199; - } -yy355: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy300; - case '0': goto yy332; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy264; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy356: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy300; - case '0': goto yy332; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy264; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy357: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy360; - case '1': goto yy361; - case '2': goto yy368; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy369; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy358: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy360; - case '1': goto yy361; - case '2': goto yy368; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy369; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy359: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': goto yy360; - case '1': goto yy361; - case '2': goto yy209; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy210; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy360: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy362; - case '.': goto yy331; - case '0': goto yy332; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy221; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy361: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy362; - case '.': goto yy300; - case '0': goto yy301; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy264; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy362: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy363; - default: goto yy57; - } -yy363: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy365; - default: goto yy364; - } -yy364: -#line 1510 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("pgtextshort"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_get_month((char **) &ptr); - s->time->d = timelib_get_nr((char **) &ptr, 2); - s->time->y = timelib_get_nr((char **) &ptr, 4); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_PG_TEXT; - } -#line 10687 "" -yy365: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy366; - default: goto yy364; - } -yy366: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy367; - default: goto yy364; - } -yy367: - yych = *++YYCURSOR; - goto yy364; -yy368: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy362; - case '.': goto yy300; - case '0': goto yy332; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy264; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy369: - yyaccept = 6; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy362; - case '.': goto yy300; - case '0': goto yy332; - case '1': goto yy302; - case '2': goto yy303; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy297; - case ':': goto yy264; - case 'n': goto yy212; - case 'r': goto yy213; - case 's': goto yy211; - case 't': goto yy214; - default: goto yy216; - } -yy370: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'C': goto yy193; - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'c': goto yy371; - default: goto yy4; - } -yy371: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'E': goto yy202; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'e': goto yy373; - default: goto yy194; - } -yy372: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy357; - case '1': - case '2': goto yy358; - case '3': goto yy359; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy149; - default: goto yy196; - } -yy373: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'M': goto yy203; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'm': goto yy374; - default: goto yy4; - } -yy374: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'B': goto yy204; - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'b': goto yy375; - default: goto yy4; - } -yy375: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'E': goto yy205; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'e': goto yy376; - default: goto yy4; - } -yy376: - yych = *++YYCURSOR; - switch (yych) { - case 'R': goto yy206; - case 'r': goto yy377; - default: goto yy155; - } -yy377: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case '-': goto yy378; - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy194; - } -yy378: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy149; - default: goto yy196; - } -yy379: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'T': - case 't': goto yy380; - default: goto yy4; - } -yy380: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'O': - case 'o': goto yy381; - default: goto yy194; - } -yy381: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'B': - case 'b': goto yy382; - default: goto yy4; - } -yy382: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'E': - case 'e': goto yy383; - default: goto yy4; - } -yy383: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'R': - case 'r': goto yy206; - default: goto yy4; - } -yy384: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'T': goto yy380; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 't': goto yy385; - default: goto yy4; - } -yy385: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'O': goto yy381; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'o': goto yy386; - default: goto yy194; - } -yy386: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'B': goto yy382; - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'b': goto yy387; - default: goto yy4; - } -yy387: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'E': goto yy383; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'e': goto yy388; - default: goto yy4; - } -yy388: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'R': goto yy206; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'r': goto yy377; - default: goto yy4; - } -yy389: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'G': - case 'g': goto yy397; - default: goto yy4; - } -yy390: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'R': - case 'r': goto yy394; - default: goto yy4; - } -yy391: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'O': - case 'o': goto yy392; - default: goto yy4; - } -yy392: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy393; - } -yy393: -#line 1566 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("ago"); - TIMELIB_INIT; - s->time->relative.y = 0 - s->time->relative.y; - s->time->relative.m = 0 - s->time->relative.m; - s->time->relative.d = 0 - s->time->relative.d; - s->time->relative.h = 0 - s->time->relative.h; - s->time->relative.i = 0 - s->time->relative.i; - s->time->relative.s = 0 - s->time->relative.s; - s->time->relative.weekday = 0 - s->time->relative.weekday; - if (s->time->relative.weekday == 0) { - s->time->relative.weekday = -7; - } - if (s->time->relative.have_special_relative && s->time->relative.special.type == TIMELIB_SPECIAL_WEEKDAY) { - s->time->relative.special.amount = 0 - s->time->relative.special.amount; - } - TIMELIB_DEINIT; - return TIMELIB_AGO; - } -#line 12044 "" -yy394: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'I': - case 'i': goto yy395; - default: goto yy194; - } -yy395: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'L': - case 'l': goto yy396; - default: goto yy4; - } -yy396: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy194; - } -yy397: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'U': - case 'u': goto yy398; - default: goto yy194; - } -yy398: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'S': - case 's': goto yy399; - default: goto yy4; - } -yy399: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'T': - case 't': goto yy400; - default: goto yy4; - } -yy400: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - default: goto yy194; - } -yy401: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'G': goto yy397; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'g': goto yy408; - default: goto yy4; - } -yy402: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'R': goto yy394; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'r': goto yy405; - default: goto yy4; - } -yy403: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'O': goto yy392; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'o': goto yy404; - default: goto yy4; - } -yy404: - yyaccept = 9; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - default: goto yy393; - } -yy405: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'I': goto yy395; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'i': goto yy406; - default: goto yy194; - } -yy406: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'L': goto yy396; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'l': goto yy407; - default: goto yy4; - } -yy407: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy378; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy194; - } -yy408: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'U': goto yy398; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'u': goto yy409; - default: goto yy194; - } -yy409: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'S': goto yy399; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 's': goto yy410; - default: goto yy4; - } -yy410: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'T': goto yy400; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 't': goto yy411; - default: goto yy4; - } -yy411: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy378; - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy194; - } -yy412: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'L': - case 'l': goto yy419; - case 'N': - case 'n': goto yy418; - default: goto yy4; - } -yy413: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'N': - case 'n': goto yy414; - default: goto yy4; - } -yy414: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'U': - case 'u': goto yy415; - default: goto yy194; - } -yy415: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy416; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; - } -yy416: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'R': - case 'r': goto yy417; - default: goto yy4; - } -yy417: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'Y': - case 'y': goto yy206; - default: goto yy4; - } -yy418: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'E': - case 'e': goto yy420; - default: goto yy194; - } -yy419: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy143; - case 'Y': - case 'y': goto yy420; - default: goto yy194; - } -yy420: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy194; - } -yy421: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'L': goto yy419; - case 'N': goto yy418; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'l': goto yy428; - case 'n': goto yy427; - default: goto yy4; - } -yy422: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'N': goto yy414; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'n': goto yy423; - default: goto yy4; - } -yy423: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'U': goto yy415; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'u': goto yy424; - default: goto yy194; - } -yy424: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy416; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': goto yy425; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; - } -yy425: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'R': goto yy417; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'r': goto yy426; - default: goto yy4; - } -yy426: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'Y': goto yy206; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy154; - case 'y': goto yy377; - default: goto yy4; - } -yy427: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'E': goto yy420; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'e': goto yy429; - default: goto yy194; - } -yy428: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': goto yy143; - case 'Y': goto yy420; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy151; - case 'y': goto yy429; - default: goto yy194; - } -yy429: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy378; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy194; - } -yy430: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'I': goto yy431; - default: goto yy4; - } -yy431: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy4; - } -yy432: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'I': goto yy433; - default: goto yy4; - } -yy433: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'I': goto yy434; - default: goto yy4; - } -yy434: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; - } -yy435: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - default: goto yy4; - } -yy436: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'I': goto yy431; - default: goto yy4; - } -yy437: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy457; - case ':': goto yy163; - default: goto yy4; - } -yy438: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy457; - case '5': goto yy442; - case '6': - case '7': - case '8': - case '9': goto yy443; - case ':': goto yy163; - default: goto yy4; - } -yy439: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy442; - case '6': - case '7': - case '8': - case '9': goto yy443; - case ':': goto yy163; - default: goto yy4; - } -yy440: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy58; - case '+': - case '-': goto yy440; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy57; - } -yy442: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy456; - default: goto yy4; - } -yy443: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy444; - default: goto yy4; - } -yy444: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy445; - default: goto yy61; - } -yy445: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy446; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy61; - } -yy446: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy447; - case '1': goto yy448; - default: goto yy57; - } -yy447: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy449; - default: goto yy57; - } -yy448: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy449; - default: goto yy57; - } -yy449: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy450; - default: goto yy57; - } -yy450: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy451; - case '1': - case '2': goto yy452; - case '3': goto yy453; - default: goto yy57; - } -yy451: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy454; - default: goto yy57; - } -yy452: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy454; - default: goto yy57; - } -yy453: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy454; - default: goto yy57; - } -yy454: - ++YYCURSOR; -yy455: -#line 1280 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("iso8601date4 | iso8601date2 | iso8601dateslash | dateslash"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_unsigned_nr((char **) &ptr, 4); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = timelib_get_nr((char **) &ptr, 2); - TIMELIB_DEINIT; - return TIMELIB_ISO_DATE; - } -#line 15116 "" -yy456: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy445; - default: goto yy4; - } -yy457: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy458; - case '6': - case '7': - case '8': - case '9': goto yy456; - case ':': goto yy163; - default: goto yy4; - } -yy458: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy459; - default: goto yy4; - } -yy459: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '-': goto yy446; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy4; - } -yy460: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy736; - case '1': goto yy737; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy738; - default: goto yy462; - } -yy461: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); - yych = *YYCURSOR; -yy462: - switch (yych) { - case '\t': - case ' ': goto yy461; - case '-': - case '.': goto yy577; - case 'A': - case 'a': goto yy480; - case 'D': - case 'd': goto yy466; - case 'F': - case 'f': goto yy467; - case 'H': - case 'h': goto yy64; - case 'I': goto yy475; - case 'J': - case 'j': goto yy479; - case 'M': - case 'm': goto yy465; - case 'N': - case 'n': goto yy482; - case 'O': - case 'o': goto yy481; - case 'P': - case 'p': goto yy484; - case 'S': - case 's': goto yy463; - case 'T': - case 't': goto yy69; - case 'V': goto yy477; - case 'W': - case 'w': goto yy68; - case 'X': goto yy478; - case 'Y': - case 'y': goto yy67; - default: goto yy57; - } -yy463: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy127; - case 'E': - case 'e': goto yy1049; - case 'U': - case 'u': goto yy126; - default: goto yy57; - } -yy464: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy127; - case 'E': - case 'e': goto yy1049; - case 'U': - case 'u': goto yy126; - case 't': goto yy729; - default: goto yy57; - } -yy465: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy592; - case 'I': - case 'i': goto yy118; - case 'O': - case 'o': goto yy117; - default: goto yy57; - } -yy466: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy114; - case 'E': - case 'e': goto yy579; - default: goto yy57; - } -yy467: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy595; - case 'O': - case 'o': goto yy99; - case 'R': - case 'r': goto yy98; - default: goto yy57; - } -yy468: - yych = *++YYCURSOR; - switch (yych) { - case 'H': goto yy70; - case 'U': - case 'u': goto yy71; - case 'h': goto yy1048; - default: goto yy57; - } -yy469: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy742; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy741; - default: goto yy61; - } -yy470: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy530; - case 'd': goto yy729; - default: goto yy57; - } -yy471: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy729; - default: goto yy57; - } -yy472: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy666; - case '3': goto yy668; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy669; - case 'A': - case 'a': goto yy673; - case 'D': - case 'd': goto yy677; - case 'F': - case 'f': goto yy671; - case 'J': - case 'j': goto yy670; - case 'M': - case 'm': goto yy672; - case 'N': - case 'n': goto yy676; - case 'O': - case 'o': goto yy675; - case 'S': - case 's': goto yy674; - default: goto yy57; - } -yy473: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy616; - case '1': goto yy617; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy618; - case 'A': - case 'a': goto yy622; - case 'D': - case 'd': goto yy626; - case 'F': - case 'f': goto yy620; - case 'J': - case 'j': goto yy619; - case 'M': - case 'm': goto yy621; - case 'N': - case 'n': goto yy625; - case 'O': - case 'o': goto yy624; - case 'S': - case 's': goto yy623; - default: goto yy578; - } -yy474: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy568; - case '1': goto yy569; - case '2': - case '3': - case '4': - case '5': goto yy570; - case '6': - case '7': - case '8': - case '9': goto yy571; - default: goto yy578; - } -yy475: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy567; - case 'V': - case 'X': goto yy540; - default: goto yy476; - } -yy476: -#line 1409 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("datenoyearrev"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->d = timelib_get_nr((char **) &ptr, 2); - timelib_skip_day_suffix((char **) &ptr); - s->time->m = timelib_get_month((char **) &ptr); - TIMELIB_DEINIT; - return TIMELIB_DATE_TEXT; - } -#line 15516 "" -yy477: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy565; - default: goto yy476; - } -yy478: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy564; - default: goto yy476; - } -yy479: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy557; - case 'U': - case 'u': goto yy556; - default: goto yy57; - } -yy480: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy485; - case 'M': - case 'm': goto yy486; - case 'P': - case 'p': goto yy550; - case 'U': - case 'u': goto yy549; - default: goto yy57; - } -yy481: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy544; - default: goto yy57; - } -yy482: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy530; - default: goto yy57; - } -yy483: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy490; - case '6': - case '7': - case '8': - case '9': goto yy492; - default: goto yy57; - } -yy484: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy485; - case 'M': - case 'm': goto yy486; - default: goto yy57; - } -yy485: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy486; - default: goto yy57; - } -yy486: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy488; - case '.': goto yy487; - default: goto yy57; - } -yy487: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy488; - default: goto yy57; - } -yy488: - ++YYCURSOR; -#line 1136 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("timetiny12 | timeshort12 | timelong12"); - TIMELIB_INIT; - TIMELIB_HAVE_TIME(); - s->time->h = timelib_get_nr((char **) &ptr, 2); - if (*ptr == ':' || *ptr == '.') { - s->time->i = timelib_get_nr((char **) &ptr, 2); - if (*ptr == ':' || *ptr == '.') { - s->time->s = timelib_get_nr((char **) &ptr, 2); - } - } - s->time->h += timelib_meridian((char **) &ptr, s->time->h); - TIMELIB_DEINIT; - return TIMELIB_TIME12; - } -#line 15659 "" -yy490: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy493; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy507; - default: goto yy491; - } -yy491: -#line 1173 "ext/date/lib/parse_date.re" - { - int tz_not_found; - DEBUG_OUTPUT("timeshort24 | timelong24 | iso8601long"); - TIMELIB_INIT; - TIMELIB_HAVE_TIME(); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - if (*ptr == ':' || *ptr == '.') { - s->time->s = timelib_get_nr((char **) &ptr, 2); - - if (*ptr == '.') { - s->time->f = timelib_get_frac_nr((char **) &ptr, 8); - } - } - - if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); - if (tz_not_found) { - add_error(s, "The timezone could not be found in the database"); - } - } - TIMELIB_DEINIT; - return TIMELIB_TIME24_WITH_ZONE; - } -#line 15704 "" -yy492: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy493; - default: goto yy491; - } -yy493: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy494; - case '6': goto yy495; - case '7': - case '8': - case '9': goto yy496; - default: goto yy57; - } -yy494: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy500; - default: goto yy491; - } -yy495: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': goto yy500; - default: goto yy491; - } -yy496: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - default: goto yy491; - } -yy497: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy498; - default: goto yy57; - } -yy498: - ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); - yych = *YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy498; - default: goto yy491; - } -yy500: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy501; - case '.': goto yy497; - case 'A': - case 'P': - case 'a': - case 'p': goto yy503; - default: goto yy491; - } -yy501: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy501; - case 'A': - case 'P': - case 'a': - case 'p': goto yy503; - default: goto yy57; - } -yy503: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy504; - case 'M': - case 'm': goto yy505; - default: goto yy57; - } -yy504: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy505; - default: goto yy57; - } -yy505: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy488; - case '.': goto yy506; - default: goto yy57; - } -yy506: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy488; - default: goto yy57; - } -yy507: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy508; - case '.': goto yy493; - case ':': goto yy511; - case 'A': - case 'P': - case 'a': - case 'p': goto yy510; - default: goto yy491; - } -yy508: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy508; - case 'A': - case 'P': - case 'a': - case 'p': goto yy510; - default: goto yy57; - } -yy510: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy527; - case 'M': - case 'm': goto yy528; - default: goto yy57; - } -yy511: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy512; - case '6': goto yy513; - case '7': - case '8': - case '9': goto yy496; - default: goto yy57; - } -yy512: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy514; - default: goto yy491; - } -yy513: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': goto yy514; - default: goto yy491; - } -yy514: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy501; - case '.': goto yy515; - case ':': goto yy516; - case 'A': - case 'P': - case 'a': - case 'p': goto yy503; - default: goto yy491; - } -yy515: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy525; - default: goto yy57; - } -yy516: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy517; - default: goto yy57; - } -yy517: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy517; - case 'A': - case 'P': - case 'a': - case 'p': goto yy519; - default: goto yy57; - } -yy519: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy520; - case 'M': - case 'm': goto yy521; - default: goto yy57; - } -yy520: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy521; - default: goto yy57; - } -yy521: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy523; - case '.': goto yy522; - default: goto yy57; - } -yy522: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy523; - default: goto yy57; - } -yy523: - ++YYCURSOR; -#line 1153 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("mssqltime"); - TIMELIB_INIT; - TIMELIB_HAVE_TIME(); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - if (*ptr == ':' || *ptr == '.') { - s->time->s = timelib_get_nr((char **) &ptr, 2); - - if (*ptr == ':' || *ptr == '.') { - s->time->f = timelib_get_frac_nr((char **) &ptr, 8); - } - } - timelib_eat_spaces((char **) &ptr); - s->time->h += timelib_meridian((char **) &ptr, s->time->h); - TIMELIB_DEINIT; - return TIMELIB_TIME24_WITH_ZONE; - } -#line 16043 "" -yy525: - yyaccept = 11; - YYMARKER = ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy525; - case 'A': - case 'P': - case 'a': - case 'p': goto yy519; - default: goto yy491; - } -yy527: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy528; - default: goto yy57; - } -yy528: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy488; - case '.': goto yy529; - default: goto yy57; - } -yy529: - yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy488; - default: goto yy57; - } -yy530: - yych = *++YYCURSOR; - switch (yych) { - case 'V': - case 'v': goto yy531; - default: goto yy57; - } -yy531: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy536; - default: goto yy476; - } -yy532: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4); - yych = *YYCURSOR; -yy533: - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - default: goto yy57; - } -yy534: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy541; - default: goto yy535; - } -yy535: -#line 1331 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("datefull"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->d = timelib_get_nr((char **) &ptr, 2); - timelib_skip_day_suffix((char **) &ptr); - s->time->m = timelib_get_month((char **) &ptr); - s->time->y = timelib_get_nr((char **) &ptr, 4); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_DATE_FULL; - } -#line 16170 "" -yy536: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy537; - default: goto yy57; - } -yy537: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy538; - default: goto yy57; - } -yy538: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy539; - default: goto yy57; - } -yy539: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy540; - default: goto yy57; - } -yy540: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - default: goto yy476; - } -yy541: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy542; - default: goto yy535; - } -yy542: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy543; - default: goto yy535; - } -yy543: - yych = *++YYCURSOR; - goto yy535; -yy544: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy545; - default: goto yy57; - } -yy545: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'O': - case 'o': goto yy546; - default: goto yy476; - } -yy546: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy547; - default: goto yy57; - } -yy547: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy548; - default: goto yy57; - } -yy548: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy540; - default: goto yy57; - } -yy549: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy553; - default: goto yy57; - } -yy550: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy551; - default: goto yy57; - } -yy551: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': - case 'i': goto yy552; - default: goto yy476; - } -yy552: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'l': goto yy540; - default: goto yy57; - } -yy553: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'U': - case 'u': goto yy554; - default: goto yy476; - } -yy554: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy555; - default: goto yy57; - } -yy555: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy540; - default: goto yy57; - } -yy556: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'l': goto yy563; - case 'N': - case 'n': goto yy562; - default: goto yy57; - } -yy557: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy558; - default: goto yy57; - } -yy558: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'U': - case 'u': goto yy559; - default: goto yy476; - } -yy559: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy560; - default: goto yy57; - } -yy560: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy561; - default: goto yy57; - } -yy561: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy540; - default: goto yy57; - } -yy562: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy540; - default: goto yy476; - } -yy563: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'Y': - case 'y': goto yy540; - default: goto yy476; - } -yy564: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy540; - default: goto yy476; - } -yy565: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy566; - default: goto yy476; - } -yy566: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy540; - default: goto yy476; - } -yy567: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': goto yy540; - default: goto yy476; - } -yy568: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy601; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy615; - case ':': goto yy493; - default: goto yy491; - } -yy569: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy601; - case '0': - case '1': - case '2': goto yy615; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy614; - case ':': goto yy493; - default: goto yy491; - } -yy570: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy601; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy614; - case ':': goto yy493; - default: goto yy491; - } -yy571: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy601; - case ':': goto yy493; - default: goto yy491; - } -yy572: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy595; - default: goto yy57; - } -yy573: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy592; - default: goto yy57; - } -yy574: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy550; - case 'U': - case 'u': goto yy549; - default: goto yy57; - } -yy575: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy585; - default: goto yy57; - } -yy576: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy579; - default: goto yy57; - } -yy577: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); - yych = *YYCURSOR; -yy578: - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy577; - case 'A': - case 'a': goto yy574; - case 'D': - case 'd': goto yy576; - case 'F': - case 'f': goto yy572; - case 'I': goto yy475; - case 'J': - case 'j': goto yy479; - case 'M': - case 'm': goto yy573; - case 'N': - case 'n': goto yy482; - case 'O': - case 'o': goto yy481; - case 'S': - case 's': goto yy575; - case 'V': goto yy477; - case 'X': goto yy478; - default: goto yy57; - } -yy579: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy580; - default: goto yy57; - } -yy580: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy581; - default: goto yy476; - } -yy581: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy582; - default: goto yy57; - } -yy582: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy583; - default: goto yy57; - } -yy583: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy584; - default: goto yy57; - } -yy584: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy540; - default: goto yy57; - } -yy585: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy586; - default: goto yy57; - } -yy586: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'T': - case 't': goto yy587; - default: goto yy476; - } -yy587: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy588; - default: goto yy476; - } -yy588: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy589; - default: goto yy57; - } -yy589: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy590; - default: goto yy57; - } -yy590: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy591; - default: goto yy57; - } -yy591: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy540; - default: goto yy57; - } -yy592: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy593; - case 'Y': - case 'y': goto yy540; - default: goto yy57; - } -yy593: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'C': - case 'c': goto yy594; - default: goto yy476; - } -yy594: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy540; - default: goto yy57; - } -yy595: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy596; - default: goto yy57; - } -yy596: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy532; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'R': - case 'r': goto yy597; - default: goto yy476; - } -yy597: - yych = *++YYCURSOR; - switch (yych) { - case 'U': - case 'u': goto yy598; - default: goto yy57; - } -yy598: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy599; - default: goto yy57; - } -yy599: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy600; - default: goto yy57; - } -yy600: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy540; - default: goto yy57; - } -yy601: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy608; - case '6': goto yy609; - case '7': - case '8': - case '9': goto yy610; - default: goto yy57; - } -yy602: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy603; - default: goto yy57; - } -yy603: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy604; - default: goto yy57; - } -yy604: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy605; - default: goto yy57; - } -yy605: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy606; - default: goto yy57; - } -yy606: - ++YYCURSOR; -#line 1345 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("pointed date YYYY"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->d = timelib_get_nr((char **) &ptr, 2); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->y = timelib_get_nr((char **) &ptr, 4); - TIMELIB_DEINIT; - return TIMELIB_DATE_FULL_POINTED; - } -#line 17021 "" -yy608: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy613; - default: goto yy491; - } -yy609: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': goto yy613; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy611; - default: goto yy491; - } -yy610: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy611; - default: goto yy491; - } -yy611: - yyaccept = 12; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy605; - default: goto yy612; - } -yy612: -#line 1357 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("pointed date YY"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->d = timelib_get_nr((char **) &ptr, 2); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->y = timelib_get_nr((char **) &ptr, 2); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_DATE_FULL_POINTED; - } -#line 17102 "" -yy613: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy501; - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy605; - case 'A': - case 'P': - case 'a': - case 'p': goto yy503; - default: goto yy491; - } -yy614: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy508; - case '.': - case ':': goto yy493; - case 'A': - case 'P': - case 'a': - case 'p': goto yy510; - default: goto yy491; - } -yy615: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy508; - case '-': goto yy602; - case '.': goto yy601; - case ':': goto yy493; - case 'A': - case 'P': - case 'a': - case 'p': goto yy510; - default: goto yy491; - } -yy616: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy655; - case '.': goto yy602; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy618; - default: goto yy57; - } -yy617: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy655; - case '.': goto yy602; - case '0': - case '1': - case '2': goto yy618; - default: goto yy57; - } -yy618: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy655; - case '.': goto yy602; - default: goto yy57; - } -yy619: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy651; - case 'U': - case 'u': goto yy650; - default: goto yy57; - } -yy620: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy648; - default: goto yy57; - } -yy621: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy645; - default: goto yy57; - } -yy622: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy642; - case 'U': - case 'u': goto yy641; - default: goto yy57; - } -yy623: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy638; - default: goto yy57; - } -yy624: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy636; - default: goto yy57; - } -yy625: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy634; - default: goto yy57; - } -yy626: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy627; - default: goto yy57; - } -yy627: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy628; - default: goto yy57; - } -yy628: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy581; - default: goto yy476; - } -yy629: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy630; - case '1': - case '2': goto yy631; - case '3': goto yy632; - default: goto yy533; - } -yy630: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy633; - default: goto yy535; - } -yy631: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy633; - default: goto yy535; - } -yy632: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy633; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy541; - default: goto yy535; - } -yy633: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy542; - default: goto yy535; - } -yy634: - yych = *++YYCURSOR; - switch (yych) { - case 'V': - case 'v': goto yy635; - default: goto yy57; - } -yy635: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy536; - default: goto yy476; - } -yy636: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy637; - default: goto yy57; - } -yy637: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'O': - case 'o': goto yy546; - default: goto yy476; - } -yy638: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy639; - default: goto yy57; - } -yy639: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'T': - case 't': goto yy640; - default: goto yy476; - } -yy640: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy588; - default: goto yy476; - } -yy641: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy644; - default: goto yy57; - } -yy642: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy643; - default: goto yy57; - } -yy643: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'I': - case 'i': goto yy552; - default: goto yy476; - } -yy644: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'U': - case 'u': goto yy554; - default: goto yy476; - } -yy645: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy646; - case 'Y': - case 'y': goto yy647; - default: goto yy57; - } -yy646: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'C': - case 'c': goto yy594; - default: goto yy476; - } -yy647: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - default: goto yy476; - } -yy648: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy649; - default: goto yy57; - } -yy649: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'R': - case 'r': goto yy597; - default: goto yy476; - } -yy650: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'l': goto yy654; - case 'N': - case 'n': goto yy653; - default: goto yy57; - } -yy651: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy652; - default: goto yy57; - } -yy652: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'U': - case 'u': goto yy559; - default: goto yy476; - } -yy653: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'E': - case 'e': goto yy540; - default: goto yy476; - } -yy654: - yyaccept = 10; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': goto yy532; - case '-': goto yy629; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy534; - case 'Y': - case 'y': goto yy540; - default: goto yy476; - } -yy655: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy656; - case '3': goto yy658; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy659; - default: goto yy57; - } -yy656: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy665; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy657: -#line 1318 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("gnudateshort"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = timelib_get_nr((char **) &ptr, 2); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_ISO_DATE; - } -#line 17724 "" -yy658: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy665; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy604; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy659: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy604; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy660: - yych = *++YYCURSOR; - switch (yych) { - case 't': goto yy664; - default: goto yy57; - } -yy661: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy664; - default: goto yy57; - } -yy662: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy664; - default: goto yy57; - } -yy663: - yych = *++YYCURSOR; - switch (yych) { - case 'h': goto yy664; - default: goto yy57; - } -yy664: - yych = *++YYCURSOR; - goto yy657; -yy665: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy605; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy666: - yyaccept = 14; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '/': goto yy723; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy669; - case 'n': goto yy720; - case 'r': goto yy721; - case 's': goto yy719; - case 't': goto yy722; - default: goto yy667; - } -yy667: -#line 1265 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("americanshort | american"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = timelib_get_nr((char **) &ptr, 2); - if (*ptr == '/') { - s->time->y = timelib_get_nr((char **) &ptr, 4); - TIMELIB_PROCESS_YEAR(s->time->y); - } - TIMELIB_DEINIT; - return TIMELIB_AMERICAN; - } -#line 17848 "" -yy668: - yyaccept = 14; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '/': goto yy723; - case '0': - case '1': goto yy669; - case 'n': goto yy720; - case 'r': goto yy721; - case 's': goto yy719; - case 't': goto yy722; - default: goto yy667; - } -yy669: - yyaccept = 14; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '/': goto yy723; - case 'n': goto yy720; - case 'r': goto yy721; - case 's': goto yy719; - case 't': goto yy722; - default: goto yy667; - } -yy670: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy718; - case 'U': - case 'u': goto yy717; - default: goto yy57; - } -yy671: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy716; - default: goto yy57; - } -yy672: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy715; - default: goto yy57; - } -yy673: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy714; - case 'U': - case 'u': goto yy713; - default: goto yy57; - } -yy674: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy711; - default: goto yy57; - } -yy675: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy710; - default: goto yy57; - } -yy676: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy709; - default: goto yy57; - } -yy677: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy678; - default: goto yy57; - } -yy678: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy679; - default: goto yy57; - } -yy679: - yych = *++YYCURSOR; - switch (yych) { - case '/': goto yy680; - default: goto yy57; - } -yy680: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy681; - default: goto yy57; - } -yy681: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy682; - default: goto yy57; - } -yy682: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy683; - default: goto yy57; - } -yy683: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy684; - default: goto yy57; - } -yy684: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy685; - default: goto yy57; - } -yy685: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy686; - case '2': goto yy687; - default: goto yy57; - } -yy686: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy688; - default: goto yy57; - } -yy687: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy688; - default: goto yy57; - } -yy688: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy689; - default: goto yy57; - } -yy689: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy690; - default: goto yy57; - } -yy690: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy691; - default: goto yy57; - } -yy691: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy692; - default: goto yy57; - } -yy692: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy693; - case '6': goto yy694; - default: goto yy57; - } -yy693: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy695; - default: goto yy57; - } -yy694: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy695; - default: goto yy57; - } -yy695: - yych = *++YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy696; - default: goto yy57; - } -yy696: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy696; - case '+': - case '-': goto yy699; - case 'G': goto yy698; - default: goto yy57; - } -yy698: - yych = *++YYCURSOR; - switch (yych) { - case 'M': goto yy707; - default: goto yy57; - } -yy699: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy700; - case '2': goto yy702; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy703; - default: goto yy57; - } -yy700: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy703; - case ':': goto yy704; - default: goto yy701; - } -yy701: -#line 1536 "ext/date/lib/parse_date.re" - { - int tz_not_found; - DEBUG_OUTPUT("clf"); - TIMELIB_INIT; - TIMELIB_HAVE_TIME(); - TIMELIB_HAVE_DATE(); - s->time->d = timelib_get_nr((char **) &ptr, 2); - s->time->m = timelib_get_month((char **) &ptr); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - s->time->s = timelib_get_nr((char **) &ptr, 2); - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); - if (tz_not_found) { - add_error(s, "The timezone could not be found in the database"); - } - TIMELIB_DEINIT; - return TIMELIB_CLF; - } -#line 18193 "" -yy702: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy703; - case '5': goto yy705; - case '6': - case '7': - case '8': - case '9': goto yy706; - case ':': goto yy704; - default: goto yy701; - } -yy703: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy705; - case '6': - case '7': - case '8': - case '9': goto yy706; - case ':': goto yy704; - default: goto yy701; - } -yy704: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy705; - case '6': - case '7': - case '8': - case '9': goto yy706; - default: goto yy701; - } -yy705: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy706; - default: goto yy701; - } -yy706: - yych = *++YYCURSOR; - goto yy701; -yy707: - yych = *++YYCURSOR; - switch (yych) { - case 'T': goto yy708; - default: goto yy57; - } -yy708: - yych = *++YYCURSOR; - switch (yych) { - case '+': - case '-': goto yy699; - default: goto yy57; - } -yy709: - yych = *++YYCURSOR; - switch (yych) { - case 'V': - case 'v': goto yy679; - default: goto yy57; - } -yy710: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy679; - default: goto yy57; - } -yy711: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy712; - default: goto yy57; - } -yy712: - yych = *++YYCURSOR; - switch (yych) { - case '/': goto yy680; - case 'T': - case 't': goto yy679; - default: goto yy57; - } -yy713: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy679; - default: goto yy57; - } -yy714: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy679; - default: goto yy57; - } -yy715: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'Y': - case 'r': - case 'y': goto yy679; - default: goto yy57; - } -yy716: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy679; - default: goto yy57; - } -yy717: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'N': - case 'l': - case 'n': goto yy679; - default: goto yy57; - } -yy718: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy679; - default: goto yy57; - } -yy719: - yych = *++YYCURSOR; - switch (yych) { - case 't': goto yy728; - default: goto yy57; - } -yy720: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy728; - default: goto yy57; - } -yy721: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy728; - default: goto yy57; - } -yy722: - yych = *++YYCURSOR; - switch (yych) { - case 'h': goto yy728; - default: goto yy57; - } -yy723: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy724; - default: goto yy57; - } -yy724: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy725; - default: goto yy667; - } -yy725: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy726; - default: goto yy667; - } -yy726: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy727; - default: goto yy667; - } -yy727: - yych = *++YYCURSOR; - goto yy667; -yy728: - yyaccept = 14; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '/': goto yy723; - default: goto yy667; - } -yy729: - yych = *++YYCURSOR; - switch (yych) { - case '\t': - case '.': goto yy731; - case '-': goto yy732; - case '/': goto yy730; - default: goto yy578; - } -yy730: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy673; - case 'D': - case 'd': goto yy677; - case 'F': - case 'f': goto yy671; - case 'J': - case 'j': goto yy670; - case 'M': - case 'm': goto yy672; - case 'N': - case 'n': goto yy676; - case 'O': - case 'o': goto yy675; - case 'S': - case 's': goto yy674; - default: goto yy57; - } -yy731: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy736; - case '1': goto yy737; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy738; - default: goto yy578; - } -yy732: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy733; - case '1': goto yy734; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy735; - default: goto yy578; - } -yy733: - yych = *++YYCURSOR; - switch (yych) { - case '-': - case '.': goto yy602; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy735; - default: goto yy57; - } -yy734: - yych = *++YYCURSOR; - switch (yych) { - case '-': - case '.': goto yy602; - case '0': - case '1': - case '2': goto yy735; - default: goto yy57; - } -yy735: - yych = *++YYCURSOR; - switch (yych) { - case '-': - case '.': goto yy602; - default: goto yy57; - } -yy736: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy602; - case '.': goto yy739; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy738; - default: goto yy57; - } -yy737: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy602; - case '.': goto yy739; - case '0': - case '1': - case '2': goto yy738; - default: goto yy57; - } -yy738: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy602; - case '.': goto yy739; - default: goto yy57; - } -yy739: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy740; - default: goto yy57; - } -yy740: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy611; - default: goto yy57; - } -yy741: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy785; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy783; - default: goto yy61; - } -yy742: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy751; - case '1': goto yy752; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy753; - case 'A': - case 'a': goto yy746; - case 'D': - case 'd': goto yy750; - case 'F': - case 'f': goto yy744; - case 'J': - case 'j': goto yy743; - case 'M': - case 'm': goto yy745; - case 'N': - case 'n': goto yy749; - case 'O': - case 'o': goto yy748; - case 'S': - case 's': goto yy747; - default: goto yy57; - } -yy743: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy782; - case 'U': - case 'u': goto yy781; - default: goto yy57; - } -yy744: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy780; - default: goto yy57; - } -yy745: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy779; - default: goto yy57; - } -yy746: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy778; - case 'U': - case 'u': goto yy777; - default: goto yy57; - } -yy747: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy775; - default: goto yy57; - } -yy748: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy774; - default: goto yy57; - } -yy749: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy773; - default: goto yy57; - } -yy750: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy765; - default: goto yy57; - } -yy751: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy754; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy758; - default: goto yy57; - } -yy752: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy754; - case '0': - case '1': - case '2': goto yy758; - default: goto yy57; - } -yy753: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy754; - default: goto yy57; - } -yy754: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy755; - case '3': goto yy756; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy757; - default: goto yy57; - } -yy755: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy757; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy756: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy757; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy757: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy758: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy759; - default: goto yy57; - } -yy759: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy760; - case '1': - case '2': goto yy761; - case '3': goto yy762; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy757; - default: goto yy57; - } -yy760: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy763; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy761: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy763; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy762: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy763; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; - } -yy763: - yyaccept = 15; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy764; - } -yy764: -#line 1292 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("iso8601date2"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = timelib_get_nr((char **) &ptr, 2); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_ISO_DATE; - } -#line 18890 "" -yy765: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy766; - default: goto yy57; - } -yy766: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy767; - default: goto yy57; - } -yy767: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy768; - case '1': - case '2': goto yy769; - case '3': goto yy770; - default: goto yy57; - } -yy768: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy771; - default: goto yy57; - } -yy769: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy771; - default: goto yy57; - } -yy770: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy771; - default: goto yy57; - } -yy771: - ++YYCURSOR; -#line 1523 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("pgtextreverse"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_month((char **) &ptr); - s->time->d = timelib_get_nr((char **) &ptr, 2); - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_PG_TEXT; - } -#line 18964 "" -yy773: - yych = *++YYCURSOR; - switch (yych) { - case 'V': - case 'v': goto yy766; - default: goto yy57; - } -yy774: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy766; - default: goto yy57; - } -yy775: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy776; - default: goto yy57; - } -yy776: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy767; - case 'T': - case 't': goto yy766; - default: goto yy57; - } -yy777: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy766; - default: goto yy57; - } -yy778: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy766; - default: goto yy57; - } -yy779: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'Y': - case 'r': - case 'y': goto yy766; - default: goto yy57; - } -yy780: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy766; - default: goto yy57; - } -yy781: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'N': - case 'l': - case 'n': goto yy766; - default: goto yy57; - } -yy782: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy766; - default: goto yy57; - } -yy783: - yyaccept = 16; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'S': - case 'T': - case 'V': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'n': - case 'o': - case 's': - case 't': - case 'w': - case 'y': goto yy791; - case '-': goto yy788; - case '.': goto yy792; - case '/': goto yy789; - case '0': goto yy805; - case '1': goto yy806; - case '2': goto yy808; - case '3': goto yy809; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - case ':': goto yy807; - case 'W': goto yy810; - default: goto yy784; - } -yy784: -#line 1557 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("year4"); - TIMELIB_INIT; - s->time->y = timelib_get_nr((char **) &ptr, 4); - TIMELIB_DEINIT; - return TIMELIB_CLF; - } -#line 19098 "" -yy785: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy786; - case '1': goto yy787; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy753; - case 'A': - case 'a': goto yy746; - case 'D': - case 'd': goto yy750; - case 'F': - case 'f': goto yy744; - case 'J': - case 'j': goto yy743; - case 'M': - case 'm': goto yy745; - case 'N': - case 'n': goto yy749; - case 'O': - case 'o': goto yy748; - case 'S': - case 's': goto yy747; - default: goto yy57; - } -yy786: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy754; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy753; - default: goto yy57; - } -yy787: - yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy754; - case '0': - case '1': - case '2': goto yy753; - default: goto yy57; - } -yy788: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy973; - case '1': goto yy975; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy976; - case 'A': - case 'a': goto yy967; - case 'D': - case 'd': goto yy971; - case 'F': - case 'f': goto yy965; - case 'J': - case 'j': goto yy964; - case 'M': - case 'm': goto yy966; - case 'N': - case 'n': goto yy970; - case 'O': - case 'o': goto yy969; - case 'S': - case 's': goto yy968; - case 'W': goto yy972; - default: goto yy939; - } -yy789: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy947; - case '1': goto yy948; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy949; - default: goto yy57; - } -yy790: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); - yych = *YYCURSOR; -yy791: - switch (yych) { - case '\t': - case ' ': goto yy790; - case '-': - case '.': goto yy938; - case 'A': - case 'a': goto yy800; - case 'D': - case 'd': goto yy804; - case 'F': - case 'f': goto yy798; - case 'H': - case 'h': goto yy64; - case 'I': goto yy793; - case 'J': - case 'j': goto yy797; - case 'M': - case 'm': goto yy799; - case 'N': - case 'n': goto yy803; - case 'O': - case 'o': goto yy802; - case 'S': - case 's': goto yy801; - case 'T': - case 't': goto yy69; - case 'V': goto yy795; - case 'W': - case 'w': goto yy68; - case 'X': goto yy796; - case 'Y': - case 'y': goto yy67; - default: goto yy57; - } -yy792: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy931; - case '1': - case '2': goto yy932; - case '3': goto yy933; - default: goto yy939; - } -yy793: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case 'I': goto yy930; - case 'V': - case 'X': goto yy884; - default: goto yy794; - } -yy794: -#line 1383 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("datenodayrev"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_month((char **) &ptr); - s->time->d = 1; - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_DATE_NO_DAY; - } -#line 19271 "" -yy795: - yych = *++YYCURSOR; - switch (yych) { - case 'I': goto yy928; - default: goto yy794; - } -yy796: - yych = *++YYCURSOR; - switch (yych) { - case 'I': goto yy927; - default: goto yy794; - } -yy797: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy920; - case 'U': - case 'u': goto yy919; - default: goto yy57; - } -yy798: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy913; - case 'O': - case 'o': goto yy99; - case 'R': - case 'r': goto yy98; - default: goto yy57; - } -yy799: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy910; - case 'I': - case 'i': goto yy118; - case 'O': - case 'o': goto yy117; - default: goto yy57; - } -yy800: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy904; - case 'U': - case 'u': goto yy903; - default: goto yy57; - } -yy801: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy127; - case 'E': - case 'e': goto yy896; - case 'U': - case 'u': goto yy126; - default: goto yy57; - } -yy802: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy891; - default: goto yy57; - } -yy803: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy885; - default: goto yy57; - } -yy804: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy114; - case 'E': - case 'e': goto yy878; - default: goto yy57; - } -yy805: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy875; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy876; - default: goto yy61; - } -yy806: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy844; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy823; - default: goto yy61; - } -yy807: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy824; - case '1': goto yy825; - default: goto yy57; - } -yy808: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy823; - default: goto yy61; - } -yy809: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy819; - case '6': goto yy820; - case '7': - case '8': - case '9': goto yy55; - default: goto yy61; - } -yy810: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy811; - case '1': - case '2': - case '3': - case '4': goto yy812; - case '5': goto yy813; - case 'E': - case 'e': goto yy83; - default: goto yy57; - } -yy811: - yych = *++YYCURSOR; - switch (yych) { - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy814; - default: goto yy57; - } -yy812: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy814; - default: goto yy57; - } -yy813: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': goto yy814; - default: goto yy57; - } -yy814: - yyaccept = 17; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy816; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': goto yy817; - default: goto yy815; - } -yy815: -#line 1491 "ext/date/lib/parse_date.re" - { - timelib_sll w, d; - DEBUG_OUTPUT("isoweek"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - TIMELIB_HAVE_RELATIVE(); - - s->time->y = timelib_get_nr((char **) &ptr, 4); - w = timelib_get_nr((char **) &ptr, 2); - d = 1; - s->time->m = 1; - s->time->d = 1; - s->time->relative.d = timelib_daynr_from_weeknr(s->time->y, w, d); - - TIMELIB_DEINIT; - return TIMELIB_ISO_WEEK; - } -#line 19510 "" -yy816: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': goto yy817; - default: goto yy57; - } -yy817: - ++YYCURSOR; -#line 1472 "ext/date/lib/parse_date.re" - { - timelib_sll w, d; - DEBUG_OUTPUT("isoweekday"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - TIMELIB_HAVE_RELATIVE(); - - s->time->y = timelib_get_nr((char **) &ptr, 4); - w = timelib_get_nr((char **) &ptr, 2); - d = timelib_get_nr((char **) &ptr, 1); - s->time->m = 1; - s->time->d = 1; - s->time->relative.d = timelib_daynr_from_weeknr(s->time->y, w, d); - - TIMELIB_DEINIT; - return TIMELIB_ISO_WEEK; - } -#line 19544 "" -yy819: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy61; - } -yy820: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': goto yy821; - case '7': - case '8': - case '9': goto yy55; - default: goto yy61; - } -yy821: - yyaccept = 18; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy822; - } -yy822: -#line 1459 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("pgydotd"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->d = timelib_get_nr((char **) &ptr, 3); - s->time->m = 1; - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_PG_YEARDAY; - } -#line 19622 "" -yy823: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy61; - } -yy824: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy826; - default: goto yy57; - } -yy825: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy826; - default: goto yy57; - } -yy826: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy827; - default: goto yy57; - } -yy827: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy828; - case '1': - case '2': goto yy829; - case '3': goto yy830; - default: goto yy57; - } -yy828: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy831; - default: goto yy57; - } -yy829: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy831; - default: goto yy57; - } -yy830: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy831; - default: goto yy57; - } -yy831: - yych = *++YYCURSOR; - switch (yych) { - case ' ': goto yy832; - default: goto yy57; - } -yy832: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy833; - case '2': goto yy834; - default: goto yy57; - } -yy833: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy835; - default: goto yy57; - } -yy834: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy835; - default: goto yy57; - } -yy835: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy836; - default: goto yy57; - } -yy836: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy837; - default: goto yy57; - } -yy837: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy838; - default: goto yy57; - } -yy838: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy839; - default: goto yy57; - } -yy839: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy840; - case '6': goto yy841; - default: goto yy57; - } -yy840: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy57; - } -yy841: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy842; - default: goto yy57; - } -yy842: - ++YYCURSOR; -yy843: -#line 1433 "ext/date/lib/parse_date.re" - { - int tz_not_found; - DEBUG_OUTPUT("xmlrpc | xmlrpcnocolon | soap | wddx | exif"); - TIMELIB_INIT; - TIMELIB_HAVE_TIME(); - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = timelib_get_nr((char **) &ptr, 2); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - s->time->s = timelib_get_nr((char **) &ptr, 2); - if (*ptr == '.') { - s->time->f = timelib_get_frac_nr((char **) &ptr, 9); - if (*ptr) { /* timezone is optional */ - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); - if (tz_not_found) { - add_error(s, "The timezone could not be found in the database"); - } - } - } - TIMELIB_DEINIT; - return TIMELIB_XMLRPC_SOAP; - } -#line 19851 "" -yy844: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy845; - case '1': - case '2': goto yy846; - case '3': goto yy847; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy61; - } -yy845: - yyaccept = 18; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy848; - default: goto yy822; - } -yy846: - yyaccept = 18; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy848; - default: goto yy822; - } -yy847: - yyaccept = 18; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': goto yy848; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy822; - } -yy848: - yyaccept = 19; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy60; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - case 'D': - case 'd': goto yy65; - case 'F': - case 'f': goto yy66; - case 'H': - case 'h': goto yy64; - case 'M': - case 'm': goto yy63; - case 'S': - case 's': goto yy62; - case 'T': goto yy850; - case 'W': - case 'w': goto yy68; - case 'Y': - case 'y': goto yy67; - case 't': goto yy851; - default: goto yy849; - } -yy849: -#line 1421 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("datenocolon"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = timelib_get_nr((char **) &ptr, 2); - TIMELIB_DEINIT; - return TIMELIB_DATE_NOCOLON; - } -#line 20015 "" -yy850: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy865; - case '2': goto yy866; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy867; - case 'H': - case 'h': goto yy70; - case 'U': - case 'u': goto yy71; - default: goto yy57; - } -yy851: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy852; - case '2': goto yy853; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy854; - case 'H': - case 'h': goto yy70; - case 'U': - case 'u': goto yy71; - default: goto yy57; - } -yy852: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy859; - case '6': - case '7': - case '8': - case '9': goto yy854; - default: goto yy57; - } -yy853: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy859; - case '5': goto yy855; - default: goto yy57; - } -yy854: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy855; - default: goto yy57; - } -yy855: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy856; - default: goto yy57; - } -yy856: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy857; - case '6': goto yy858; - default: goto yy57; - } -yy857: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy57; - } -yy858: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy842; - default: goto yy57; - } -yy859: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy860; - case '6': - case '7': - case '8': - case '9': goto yy856; - default: goto yy57; - } -yy860: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy861; - case '6': goto yy862; - case '7': - case '8': - case '9': goto yy856; - default: goto yy57; - } -yy861: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy863; - case '6': goto yy864; - case '7': - case '8': - case '9': goto yy842; - default: goto yy57; - } -yy862: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy863; - case '1': - case '2': - case '3': - case '4': - case '5': goto yy857; - case '6': goto yy858; - default: goto yy57; - } -yy863: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy843; - } -yy864: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy842; - default: goto yy843; - } -yy865: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy874; - case '6': - case '7': - case '8': - case '9': goto yy867; - case ':': goto yy868; - default: goto yy57; - } -yy866: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy874; - case '5': goto yy855; - case ':': goto yy868; - default: goto yy57; - } -yy867: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy855; - case ':': goto yy868; - default: goto yy57; - } -yy868: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy869; - default: goto yy57; - } -yy869: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy870; - default: goto yy57; - } -yy870: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy871; - default: goto yy57; - } -yy871: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy872; - case '6': goto yy873; - default: goto yy57; - } -yy872: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy57; - } -yy873: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy842; - default: goto yy57; - } -yy874: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy860; - case '6': - case '7': - case '8': - case '9': goto yy856; - case ':': goto yy868; - default: goto yy57; - } -yy875: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy877; - case '1': - case '2': goto yy846; - case '3': goto yy847; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy61; - } -yy876: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy845; - case '1': - case '2': goto yy846; - case '3': goto yy847; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy61; - } -yy877: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy848; - default: goto yy61; - } -yy878: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy879; - default: goto yy57; - } -yy879: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'E': - case 'e': goto yy880; - default: goto yy794; - } -yy880: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy881; - default: goto yy57; - } -yy881: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy882; - default: goto yy57; - } -yy882: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy883; - default: goto yy57; - } -yy883: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy884; - default: goto yy57; - } -yy884: - yych = *++YYCURSOR; - goto yy794; -yy885: - yych = *++YYCURSOR; - switch (yych) { - case 'V': - case 'v': goto yy886; - default: goto yy57; - } -yy886: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'E': - case 'e': goto yy887; - default: goto yy794; - } -yy887: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy888; - default: goto yy57; - } -yy888: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy889; - default: goto yy57; - } -yy889: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy890; - default: goto yy57; - } -yy890: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy884; - default: goto yy57; - } -yy891: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy892; - default: goto yy57; - } -yy892: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'O': - case 'o': goto yy893; - default: goto yy794; - } -yy893: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy894; - default: goto yy57; - } -yy894: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy895; - default: goto yy57; - } -yy895: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy884; - default: goto yy57; - } -yy896: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy129; - case 'P': - case 'p': goto yy897; - default: goto yy57; - } -yy897: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy898; - default: goto yy794; - } -yy898: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'E': - case 'e': goto yy899; - default: goto yy794; - } -yy899: - yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy900; - default: goto yy57; - } -yy900: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy901; - default: goto yy57; - } -yy901: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy902; - default: goto yy57; - } -yy902: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy884; - default: goto yy57; - } -yy903: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy907; - default: goto yy57; - } -yy904: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy905; - default: goto yy57; - } -yy905: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'I': - case 'i': goto yy906; - default: goto yy794; - } -yy906: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'l': goto yy884; - default: goto yy57; - } -yy907: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'U': - case 'u': goto yy908; - default: goto yy794; - } -yy908: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy909; - default: goto yy57; - } -yy909: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy884; - default: goto yy57; - } -yy910: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy911; - case 'Y': - case 'y': goto yy884; - default: goto yy57; - } -yy911: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'C': - case 'c': goto yy912; - default: goto yy794; - } -yy912: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy884; - default: goto yy57; - } -yy913: - yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy914; - default: goto yy57; - } -yy914: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'R': - case 'r': goto yy915; - default: goto yy794; - } -yy915: - yych = *++YYCURSOR; - switch (yych) { - case 'U': - case 'u': goto yy916; - default: goto yy57; - } -yy916: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy917; - default: goto yy57; - } -yy917: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy918; - default: goto yy57; - } -yy918: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy884; - default: goto yy57; - } -yy919: - yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'l': goto yy926; - case 'N': - case 'n': goto yy925; - default: goto yy57; - } -yy920: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy921; - default: goto yy57; - } -yy921: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'U': - case 'u': goto yy922; - default: goto yy794; - } -yy922: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy923; - default: goto yy57; - } -yy923: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy924; - default: goto yy57; - } -yy924: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy884; - default: goto yy57; - } -yy925: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy884; - default: goto yy794; - } -yy926: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy884; - default: goto yy794; - } -yy927: - yych = *++YYCURSOR; - switch (yych) { - case 'I': goto yy884; - default: goto yy794; - } -yy928: - yych = *++YYCURSOR; - switch (yych) { - case 'I': goto yy929; - default: goto yy794; - } -yy929: - yych = *++YYCURSOR; - switch (yych) { - case 'I': goto yy884; - default: goto yy794; - } -yy930: - yych = *++YYCURSOR; - switch (yych) { - case 'I': goto yy884; - default: goto yy794; - } -yy931: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy946; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy945; - default: goto yy57; - } -yy932: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy944; - default: goto yy57; - } -yy933: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy942; - case '6': goto yy941; - default: goto yy57; - } -yy934: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy913; - default: goto yy57; - } -yy935: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy910; - default: goto yy57; - } -yy936: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy940; - default: goto yy57; - } -yy937: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy878; - default: goto yy57; - } -yy938: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); - yych = *YYCURSOR; -yy939: - switch (yych) { - case '\t': - case ' ': - case '-': - case '.': goto yy938; - case 'A': - case 'a': goto yy800; - case 'D': - case 'd': goto yy937; - case 'F': - case 'f': goto yy934; - case 'I': goto yy793; - case 'J': - case 'j': goto yy797; - case 'M': - case 'm': goto yy935; - case 'N': - case 'n': goto yy803; - case 'O': - case 'o': goto yy802; - case 'S': - case 's': goto yy936; - case 'V': goto yy795; - case 'X': goto yy796; - default: goto yy57; - } -yy940: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy897; - default: goto yy57; - } -yy941: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': goto yy943; - default: goto yy57; - } -yy942: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy943; - default: goto yy57; - } -yy943: - yych = *++YYCURSOR; - goto yy822; -yy944: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy943; - default: goto yy57; - } -yy945: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy943; - default: goto yy57; - } -yy946: - yych = *++YYCURSOR; - switch (yych) { - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy943; - default: goto yy57; - } -yy947: - yych = *++YYCURSOR; - switch (yych) { - case '/': goto yy950; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy958; - default: goto yy57; - } -yy948: - yych = *++YYCURSOR; - switch (yych) { - case '/': goto yy950; - case '0': - case '1': - case '2': goto yy958; - default: goto yy57; - } -yy949: - yych = *++YYCURSOR; - switch (yych) { - case '/': goto yy950; - default: goto yy57; - } -yy950: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy951; - case '3': goto yy952; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy953; - default: goto yy57; - } -yy951: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy953; - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy952: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy953; - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy953: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy954: - yych = *++YYCURSOR; - switch (yych) { - case 't': goto yy454; - default: goto yy57; - } -yy955: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy454; - default: goto yy57; - } -yy956: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy454; - default: goto yy57; - } -yy957: - yych = *++YYCURSOR; - switch (yych) { - case 'h': goto yy454; - default: goto yy57; - } -yy958: - yych = *++YYCURSOR; - switch (yych) { - case '/': goto yy959; - default: goto yy57; - } -yy959: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy960; - case '1': - case '2': goto yy961; - case '3': goto yy962; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy953; - default: goto yy57; - } -yy960: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy963; - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy961: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy963; - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy962: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy963; - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy963: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '/': goto yy454; - case 'n': goto yy955; - case 'r': goto yy956; - case 's': goto yy954; - case 't': goto yy957; - default: goto yy455; - } -yy964: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1044; - case 'U': - case 'u': goto yy1043; - default: goto yy57; - } -yy965: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1041; - default: goto yy57; - } -yy966: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1038; - default: goto yy57; - } -yy967: - yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy1035; - case 'U': - case 'u': goto yy1034; - default: goto yy57; - } -yy968: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1031; - default: goto yy57; - } -yy969: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy1029; - default: goto yy57; - } -yy970: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1027; - default: goto yy57; - } -yy971: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1025; - default: goto yy57; - } -yy972: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy811; - case '1': - case '2': - case '3': - case '4': goto yy812; - case '5': goto yy813; - default: goto yy57; - } -yy973: - yyaccept = 22; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy977; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy996; - default: goto yy974; - } -yy974: -#line 1305 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("gnudateshorter"); - TIMELIB_INIT; - TIMELIB_HAVE_DATE(); - s->time->y = timelib_get_nr((char **) &ptr, 4); - s->time->m = timelib_get_nr((char **) &ptr, 2); - s->time->d = 1; - TIMELIB_PROCESS_YEAR(s->time->y); - TIMELIB_DEINIT; - return TIMELIB_ISO_DATE; - } -#line 21240 "" -yy975: - yyaccept = 22; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy977; - case '0': - case '1': - case '2': goto yy996; - default: goto yy974; - } -yy976: - yyaccept = 22; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy977; - default: goto yy974; - } -yy977: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy978; - case '3': goto yy979; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy980; - default: goto yy57; - } -yy978: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy980; - case 'T': goto yy985; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy657; - } -yy979: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy980; - case 'T': goto yy985; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy657; - } -yy980: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'T': goto yy985; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy657; - } -yy981: - yych = *++YYCURSOR; - switch (yych) { - case 't': goto yy995; - default: goto yy57; - } -yy982: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy995; - default: goto yy57; - } -yy983: - yych = *++YYCURSOR; - switch (yych) { - case 'd': goto yy995; - default: goto yy57; - } -yy984: - yych = *++YYCURSOR; - switch (yych) { - case 'h': goto yy995; - default: goto yy57; - } -yy985: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy986; - case '2': goto yy987; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy988; - default: goto yy57; - } -yy986: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy988; - case ':': goto yy989; - default: goto yy57; - } -yy987: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy988; - case ':': goto yy989; - default: goto yy57; - } -yy988: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy989; - default: goto yy57; - } -yy989: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy990; - case '6': - case '7': - case '8': - case '9': goto yy991; - default: goto yy57; - } -yy990: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy991; - case ':': goto yy992; - default: goto yy57; - } -yy991: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy992; - default: goto yy57; - } -yy992: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy993; - case '6': goto yy994; - case '7': - case '8': - case '9': goto yy842; - default: goto yy57; - } -yy993: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy843; - } -yy994: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy842; - default: goto yy843; - } -yy995: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'T': goto yy985; - default: goto yy657; - } -yy996: - yyaccept = 22; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy997; - default: goto yy974; - } -yy997: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy998; - case '1': - case '2': goto yy999; - case '3': goto yy1000; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy980; - default: goto yy57; - } -yy998: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1001; - case 'T': goto yy985; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy657; - } -yy999: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1001; - case 'T': goto yy985; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy657; - } -yy1000: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy1001; - case 'T': goto yy985; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy657; - } -yy1001: - yyaccept = 21; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'T': goto yy1002; - case 'n': goto yy982; - case 'r': goto yy983; - case 's': goto yy981; - case 't': goto yy984; - default: goto yy455; - } -yy1002: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy1003; - case '2': goto yy1004; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy988; - default: goto yy57; - } -yy1003: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1005; - case ':': goto yy989; - default: goto yy57; - } -yy1004: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy1005; - case ':': goto yy989; - default: goto yy57; - } -yy1005: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy1006; - default: goto yy57; - } -yy1006: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1007; - case '6': - case '7': - case '8': - case '9': goto yy991; - default: goto yy57; - } -yy1007: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1008; - case ':': goto yy992; - default: goto yy57; - } -yy1008: - yych = *++YYCURSOR; - switch (yych) { - case ':': goto yy1009; - default: goto yy57; - } -yy1009: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1010; - case '6': goto yy1011; - case '7': - case '8': - case '9': goto yy842; - default: goto yy57; + if (yybm[0+yych] & 4) { + goto yy58; } -yy1010: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1012; - default: goto yy843; + if (yych <= '/') goto yy50; + if (yych <= '9') goto yy55; +yy50: + YYDEBUG(50, *YYCURSOR); +#line 1740 "ext/date/lib/parse_date.re" + { + goto std; } -yy1011: +#line 2420 "ext/date/lib/parse_date.c" +yy51: + YYDEBUG(51, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1012; - default: goto yy843; - } -yy1012: - yyaccept = 23; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy1013; - default: goto yy843; + goto yy50; +yy52: + YYDEBUG(52, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(53, *YYCURSOR); +#line 1745 "ext/date/lib/parse_date.re" + { + s->pos = cursor; s->line++; + goto std; } -yy1013: +#line 2434 "ext/date/lib/parse_date.c" +yy54: + YYDEBUG(54, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1014; - default: goto yy57; - } -yy1014: - yyaccept = 23; - YYMARKER = ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + goto yy13; +yy55: + YYDEBUG(55, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); yych = *YYCURSOR; - switch (yych) { - case '+': - case '-': goto yy1017; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1014; - case 'G': goto yy1016; - default: goto yy843; - } -yy1016: - yych = *++YYCURSOR; - switch (yych) { - case 'M': goto yy1023; - default: goto yy57; + YYDEBUG(56, *YYCURSOR); + if (yybm[0+yych] & 2) { + goto yy55; + } + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy60; + if (yych >= ' ') goto yy60; + } else { + if (yych == 'D') goto yy65; + if (yych >= 'F') goto yy66; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy64; + if (yych >= 'M') goto yy63; + } else { + if (yych <= 'S') { + if (yych >= 'S') goto yy62; + } else { + if (yych <= 'T') goto yy69; + if (yych >= 'W') goto yy68; + } + } + } + } else { + if (yych <= 'l') { + if (yych <= 'd') { + if (yych == 'Y') goto yy67; + if (yych >= 'd') goto yy65; + } else { + if (yych <= 'f') { + if (yych >= 'f') goto yy66; + } else { + if (yych == 'h') goto yy64; + } + } + } else { + if (yych <= 't') { + if (yych <= 'm') goto yy63; + if (yych <= 'r') goto yy57; + if (yych <= 's') goto yy62; + goto yy69; + } else { + if (yych <= 'w') { + if (yych >= 'w') goto yy68; + } else { + if (yych == 'y') goto yy67; + } + } + } } -yy1017: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy1018; - case '2': goto yy1019; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1020; - default: goto yy57; +yy57: + YYDEBUG(57, *YYCURSOR); + YYCURSOR = YYMARKER; + if (yyaccept <= 16) { + if (yyaccept <= 8) { + if (yyaccept <= 4) { + if (yyaccept <= 2) { + if (yyaccept <= 1) { + if (yyaccept <= 0) { + goto yy4; + } else { + goto yy13; + } + } else { + goto yy50; + } + } else { + if (yyaccept <= 3) { + goto yy73; + } else { + goto yy167; + } + } + } else { + if (yyaccept <= 6) { + if (yyaccept <= 5) { + goto yy194; + } else { + goto yy199; + } + } else { + if (yyaccept <= 7) { + goto yy223; + } else { + goto yy295; + } + } + } + } else { + if (yyaccept <= 12) { + if (yyaccept <= 10) { + if (yyaccept <= 9) { + goto yy393; + } else { + goto yy476; + } + } else { + if (yyaccept <= 11) { + goto yy491; + } else { + goto yy612; + } + } + } else { + if (yyaccept <= 14) { + if (yyaccept <= 13) { + goto yy657; + } else { + goto yy667; + } + } else { + if (yyaccept <= 15) { + goto yy764; + } else { + goto yy784; + } + } + } + } + } else { + if (yyaccept <= 25) { + if (yyaccept <= 21) { + if (yyaccept <= 19) { + if (yyaccept <= 18) { + if (yyaccept <= 17) { + goto yy815; + } else { + goto yy822; + } + } else { + goto yy849; + } + } else { + if (yyaccept <= 20) { + goto yy794; + } else { + goto yy455; + } + } + } else { + if (yyaccept <= 23) { + if (yyaccept <= 22) { + goto yy974; + } else { + goto yy843; + } + } else { + if (yyaccept <= 24) { + goto yy1068; + } else { + goto yy1076; + } + } + } + } else { + if (yyaccept <= 29) { + if (yyaccept <= 27) { + if (yyaccept <= 26) { + goto yy1118; + } else { + goto yy1142; + } + } else { + if (yyaccept <= 28) { + goto yy1295; + } else { + goto yy1417; + } + } + } else { + if (yyaccept <= 31) { + if (yyaccept <= 30) { + goto yy1420; + } else { + goto yy1500; + } + } else { + if (yyaccept <= 32) { + goto yy1508; + } else { + goto yy1531; + } + } + } + } } -yy1018: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1020; - case ':': goto yy1021; - default: goto yy843; +yy58: + YYDEBUG(58, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(59, *YYCURSOR); + if (yybm[0+yych] & 4) { + goto yy58; } -yy1019: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy1020; - case '5': goto yy1022; - case '6': - case '7': - case '8': - case '9': goto yy842; - case ':': goto yy1021; - default: goto yy843; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy55; + goto yy57; +yy60: + YYDEBUG(60, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); + yych = *YYCURSOR; +yy61: + YYDEBUG(61, *YYCURSOR); + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy60; + if (yych <= 0x1F) goto yy57; + goto yy60; + } else { + if (yych == 'D') goto yy65; + if (yych <= 'E') goto yy57; + goto yy66; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy64; + if (yych <= 'L') goto yy57; + goto yy63; + } else { + if (yych <= 'S') { + if (yych <= 'R') goto yy57; + } else { + if (yych <= 'T') goto yy69; + if (yych <= 'V') goto yy57; + goto yy68; + } + } + } + } else { + if (yych <= 'l') { + if (yych <= 'd') { + if (yych == 'Y') goto yy67; + if (yych <= 'c') goto yy57; + goto yy65; + } else { + if (yych <= 'f') { + if (yych <= 'e') goto yy57; + goto yy66; + } else { + if (yych == 'h') goto yy64; + goto yy57; + } + } + } else { + if (yych <= 't') { + if (yych <= 'm') goto yy63; + if (yych <= 'r') goto yy57; + if (yych >= 't') goto yy69; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy57; + goto yy68; + } else { + if (yych == 'y') goto yy67; + goto yy57; + } + } + } } -yy1020: +yy62: + YYDEBUG(62, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1022; - case '6': - case '7': - case '8': - case '9': goto yy842; - case ':': goto yy1021; - default: goto yy843; + if (yych <= 'U') { + if (yych <= 'D') { + if (yych == 'A') goto yy127; + goto yy57; + } else { + if (yych <= 'E') goto yy128; + if (yych <= 'T') goto yy57; + goto yy126; + } + } else { + if (yych <= 'd') { + if (yych == 'a') goto yy127; + goto yy57; + } else { + if (yych <= 'e') goto yy128; + if (yych == 'u') goto yy126; + goto yy57; + } } -yy1021: +yy63: + YYDEBUG(63, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1022; - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy843; + if (yych <= 'O') { + if (yych == 'I') goto yy118; + if (yych <= 'N') goto yy57; + goto yy117; + } else { + if (yych <= 'i') { + if (yych <= 'h') goto yy57; + goto yy118; + } else { + if (yych == 'o') goto yy117; + goto yy57; + } } -yy1022: +yy64: + YYDEBUG(64, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy842; - default: goto yy843; - } -yy1023: + if (yych == 'O') goto yy115; + if (yych == 'o') goto yy115; + goto yy57; +yy65: + YYDEBUG(65, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'T': goto yy1024; - default: goto yy57; - } -yy1024: + if (yych == 'A') goto yy114; + if (yych == 'a') goto yy114; + goto yy57; +yy66: + YYDEBUG(66, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '+': - case '-': goto yy1017; - default: goto yy57; + if (yych <= 'R') { + if (yych == 'O') goto yy99; + if (yych <= 'Q') goto yy57; + goto yy98; + } else { + if (yych <= 'o') { + if (yych <= 'n') goto yy57; + goto yy99; + } else { + if (yych == 'r') goto yy98; + goto yy57; + } } -yy1025: +yy67: + YYDEBUG(67, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy1026; - default: goto yy57; - } -yy1026: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'E': - case 'e': goto yy880; - default: goto yy794; - } -yy1027: + if (yych == 'E') goto yy95; + if (yych == 'e') goto yy95; + goto yy57; +yy68: + YYDEBUG(68, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'V': - case 'v': goto yy1028; - default: goto yy57; - } -yy1028: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'E': - case 'e': goto yy887; - default: goto yy794; - } -yy1029: + if (yych == 'E') goto yy83; + if (yych == 'e') goto yy83; + goto yy57; +yy69: + YYDEBUG(69, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1030; - default: goto yy57; - } -yy1030: - yyaccept = 20; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'O': - case 'o': goto yy893; - default: goto yy794; + if (yych <= 'U') { + if (yych == 'H') goto yy70; + if (yych <= 'T') goto yy57; + goto yy71; + } else { + if (yych <= 'h') { + if (yych <= 'g') goto yy57; + } else { + if (yych == 'u') goto yy71; + goto yy57; + } } -yy1031: +yy70: + YYDEBUG(70, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'P': - case 'p': goto yy1032; - default: goto yy57; - } -yy1032: - yyaccept = 20; + if (yych == 'U') goto yy78; + if (yych == 'u') goto yy78; + goto yy57; +yy71: + YYDEBUG(71, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy72; + if (yych != 'e') goto yy57; +yy72: + YYDEBUG(72, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'T': - case 't': goto yy1033; - default: goto yy794; + if (yych == 'S') goto yy74; + if (yych == 's') goto yy74; +yy73: + YYDEBUG(73, *YYCURSOR); +#line 1724 "ext/date/lib/parse_date.re" + { + timelib_ull i; + DEBUG_OUTPUT("relative"); + TIMELIB_INIT; + TIMELIB_HAVE_RELATIVE(); + + while(*ptr) { + i = timelib_get_unsigned_nr((char **) &ptr, 24); + timelib_eat_spaces((char **) &ptr); + timelib_set_relative((char **) &ptr, i, 1, s); + } + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; } -yy1033: - yyaccept = 20; +#line 2836 "ext/date/lib/parse_date.c" +yy74: + YYDEBUG(74, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy75; + if (yych != 'd') goto yy57; +yy75: + YYDEBUG(75, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy76; + if (yych != 'a') goto yy57; +yy76: + YYDEBUG(76, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy77; + if (yych != 'y') goto yy57; +yy77: + YYDEBUG(77, *YYCURSOR); + yych = *++YYCURSOR; + goto yy73; +yy78: + YYDEBUG(78, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'E': - case 'e': goto yy899; - default: goto yy794; - } -yy1034: + if (yych == 'R') goto yy79; + if (yych != 'r') goto yy73; +yy79: + YYDEBUG(79, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy1037; - default: goto yy57; - } -yy1035: + if (yych == 'S') goto yy80; + if (yych != 's') goto yy57; +yy80: + YYDEBUG(80, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy1036; - default: goto yy57; + if (yych == 'D') goto yy81; + if (yych != 'd') goto yy57; +yy81: + YYDEBUG(81, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy82; + if (yych != 'a') goto yy57; +yy82: + YYDEBUG(82, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy77; + if (yych == 'y') goto yy77; + goto yy57; +yy83: + YYDEBUG(83, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= 'C') goto yy57; + if (yych <= 'D') goto yy85; + } else { + if (yych <= 'c') goto yy57; + if (yych <= 'd') goto yy85; + if (yych >= 'f') goto yy57; } -yy1036: - yyaccept = 20; + YYDEBUG(84, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'K') goto yy91; + if (yych == 'k') goto yy91; + goto yy57; +yy85: + YYDEBUG(85, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'I': - case 'i': goto yy906; - default: goto yy794; - } -yy1037: - yyaccept = 20; + if (yych == 'N') goto yy86; + if (yych != 'n') goto yy73; +yy86: + YYDEBUG(86, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy87; + if (yych != 'e') goto yy57; +yy87: + YYDEBUG(87, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy88; + if (yych != 's') goto yy57; +yy88: + YYDEBUG(88, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy89; + if (yych != 'd') goto yy57; +yy89: + YYDEBUG(89, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy90; + if (yych != 'a') goto yy57; +yy90: + YYDEBUG(90, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy77; + if (yych == 'y') goto yy77; + goto yy57; +yy91: + YYDEBUG(91, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'U': - case 'u': goto yy908; - default: goto yy794; + if (yych <= 'S') { + if (yych == 'D') goto yy92; + if (yych <= 'R') goto yy73; + goto yy77; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy73; + } else { + if (yych == 's') goto yy77; + goto yy73; + } } -yy1038: +yy92: + YYDEBUG(92, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy1039; - case 'Y': - case 'y': goto yy1040; - default: goto yy57; + if (yych == 'A') goto yy93; + if (yych != 'a') goto yy57; +yy93: + YYDEBUG(93, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy94; + if (yych != 'y') goto yy57; +yy94: + YYDEBUG(94, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy77; + if (yych == 's') goto yy77; + goto yy73; +yy95: + YYDEBUG(95, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy96; + if (yych != 'a') goto yy57; +yy96: + YYDEBUG(96, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy97; + if (yych != 'r') goto yy57; +yy97: + YYDEBUG(97, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy77; + if (yych == 's') goto yy77; + goto yy73; +yy98: + YYDEBUG(98, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy111; + if (yych == 'i') goto yy111; + goto yy57; +yy99: + YYDEBUG(99, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy100; + if (yych != 'r') goto yy57; +yy100: + YYDEBUG(100, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy101; + if (yych != 't') goto yy57; +yy101: + YYDEBUG(101, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych == 'H') goto yy103; + if (yych <= 'M') goto yy57; + } else { + if (yych <= 'h') { + if (yych <= 'g') goto yy57; + goto yy103; + } else { + if (yych != 'n') goto yy57; + } } -yy1039: - yyaccept = 20; + YYDEBUG(102, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy108; + if (yych == 'i') goto yy108; + goto yy57; +yy103: + YYDEBUG(103, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy104; + if (yych != 'n') goto yy57; +yy104: + YYDEBUG(104, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy105; + if (yych != 'i') goto yy57; +yy105: + YYDEBUG(105, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy106; + if (yych != 'g') goto yy57; +yy106: + YYDEBUG(106, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy107; + if (yych != 'h') goto yy57; +yy107: + YYDEBUG(107, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy97; + if (yych == 't') goto yy97; + goto yy57; +yy108: + YYDEBUG(108, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy109; + if (yych != 'g') goto yy57; +yy109: + YYDEBUG(109, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy110; + if (yych != 'h') goto yy57; +yy110: + YYDEBUG(110, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy97; + if (yych == 't') goto yy97; + goto yy57; +yy111: + YYDEBUG(111, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'C': - case 'c': goto yy912; - default: goto yy794; - } -yy1040: - yyaccept = 20; + if (yych == 'D') goto yy112; + if (yych != 'd') goto yy73; +yy112: + YYDEBUG(112, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy113; + if (yych != 'a') goto yy57; +yy113: + YYDEBUG(113, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy77; + if (yych == 'y') goto yy77; + goto yy57; +yy114: + YYDEBUG(114, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy97; + if (yych == 'y') goto yy97; + goto yy57; +yy115: + YYDEBUG(115, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'U') goto yy116; + if (yych != 'u') goto yy57; +yy116: + YYDEBUG(116, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy97; + if (yych == 'r') goto yy97; + goto yy57; +yy117: + YYDEBUG(117, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy122; + if (yych == 'n') goto yy122; + goto yy57; +yy118: + YYDEBUG(118, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy119; + if (yych != 'n') goto yy57; +yy119: + YYDEBUG(119, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - default: goto yy794; + if (yych <= 'U') { + if (yych == 'S') goto yy77; + if (yych <= 'T') goto yy73; + } else { + if (yych <= 's') { + if (yych <= 'r') goto yy73; + goto yy77; + } else { + if (yych != 'u') goto yy73; + } } -yy1041: + YYDEBUG(120, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'B': - case 'b': goto yy1042; - default: goto yy57; - } -yy1042: - yyaccept = 20; + if (yych == 'T') goto yy121; + if (yych != 't') goto yy57; +yy121: + YYDEBUG(121, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy97; + if (yych == 'e') goto yy97; + goto yy57; +yy122: + YYDEBUG(122, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'R': - case 'r': goto yy915; - default: goto yy794; + if (yych <= 'T') { + if (yych == 'D') goto yy123; + if (yych <= 'S') goto yy73; + goto yy124; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy73; + } else { + if (yych == 't') goto yy124; + goto yy73; + } } -yy1043: +yy123: + YYDEBUG(123, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'L': - case 'l': goto yy1047; - case 'N': - case 'n': goto yy1046; - default: goto yy57; - } -yy1044: + if (yych == 'A') goto yy125; + if (yych == 'a') goto yy125; + goto yy57; +yy124: + YYDEBUG(124, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy1045; - default: goto yy57; - } -yy1045: - yyaccept = 20; + if (yych == 'H') goto yy97; + if (yych == 'h') goto yy97; + goto yy57; +yy125: + YYDEBUG(125, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy77; + if (yych == 'y') goto yy77; + goto yy57; +yy126: + YYDEBUG(126, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy137; + if (yych == 'n') goto yy137; + goto yy57; +yy127: + YYDEBUG(127, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy132; + if (yych == 't') goto yy132; + goto yy57; +yy128: + YYDEBUG(128, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy129; + if (yych != 'c') goto yy57; +yy129: + YYDEBUG(129, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'U': - case 'u': goto yy922; - default: goto yy794; + if (yych <= 'S') { + if (yych == 'O') goto yy130; + if (yych <= 'R') goto yy73; + goto yy77; + } else { + if (yych <= 'o') { + if (yych <= 'n') goto yy73; + } else { + if (yych == 's') goto yy77; + goto yy73; + } } -yy1046: - yyaccept = 20; +yy130: + YYDEBUG(130, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy131; + if (yych != 'n') goto yy57; +yy131: + YYDEBUG(131, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy97; + if (yych == 'd') goto yy97; + goto yy57; +yy132: + YYDEBUG(132, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'E': - case 'e': goto yy884; - default: goto yy794; - } -yy1047: - yyaccept = 20; + if (yych == 'U') goto yy133; + if (yych != 'u') goto yy73; +yy133: + YYDEBUG(133, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy134; + if (yych != 'r') goto yy57; +yy134: + YYDEBUG(134, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy135; + if (yych != 'd') goto yy57; +yy135: + YYDEBUG(135, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy136; + if (yych != 'a') goto yy57; +yy136: + YYDEBUG(136, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy77; + if (yych == 'y') goto yy77; + goto yy57; +yy137: + YYDEBUG(137, *YYCURSOR); + yyaccept = 3; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy767; - case 'Y': - case 'y': goto yy884; - default: goto yy794; - } -yy1048: + if (yych == 'D') goto yy138; + if (yych != 'd') goto yy73; +yy138: + YYDEBUG(138, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '\t': - case '.': goto yy731; - case '-': goto yy732; - case '/': goto yy730; - case 'U': - case 'u': goto yy78; - default: goto yy578; - } -yy1049: + if (yych == 'A') goto yy139; + if (yych != 'a') goto yy57; +yy139: + YYDEBUG(139, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy129; - case 'P': - case 'p': goto yy586; - default: goto yy57; - } -yy1050: + if (yych == 'Y') goto yy77; + if (yych == 'y') goto yy77; + goto yy57; +yy140: + YYDEBUG(140, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '\t': goto yy1052; - case '-': goto yy1051; - case '.': goto yy731; - case '/': goto yy730; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy741; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy1054; - } -yy1051: + goto yy4; +yy141: + YYDEBUG(141, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1055; - case '1': goto yy1056; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy618; - case 'A': - case 'a': goto yy622; - case 'D': - case 'd': goto yy626; - case 'F': - case 'f': goto yy620; - case 'J': - case 'j': goto yy619; - case 'M': - case 'm': goto yy621; - case 'N': - case 'n': goto yy625; - case 'O': - case 'o': goto yy624; - case 'S': - case 's': goto yy623; - default: goto yy578; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; } -yy1052: +yy142: + YYDEBUG(142, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy736; - case '1': goto yy737; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy738; - default: goto yy1054; - } -yy1053: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); - yych = *YYCURSOR; -yy1054: - switch (yych) { - case '\t': - case ' ': goto yy1053; - case '-': - case '.': goto yy577; - case 'A': - case 'a': goto yy574; - case 'D': - case 'd': goto yy466; - case 'F': - case 'f': goto yy467; - case 'H': - case 'h': goto yy64; - case 'I': goto yy475; - case 'J': - case 'j': goto yy479; - case 'M': - case 'm': goto yy465; - case 'N': - case 'n': goto yy482; - case 'O': - case 'o': goto yy481; - case 'S': - case 's': goto yy463; - case 'T': - case 't': goto yy69; - case 'V': goto yy477; - case 'W': - case 'w': goto yy68; - case 'X': goto yy478; - case 'Y': - case 'y': goto yy67; - default: goto yy57; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; } -yy1055: +yy143: + YYDEBUG(143, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy655; - case '.': goto yy602; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1057; - default: goto yy57; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; } -yy1056: +yy144: + YYDEBUG(144, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy655; - case '.': goto yy602; - case '0': - case '1': - case '2': goto yy1057; - default: goto yy57; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; } -yy1057: +yy145: + YYDEBUG(145, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy1058; - case '.': goto yy602; - default: goto yy57; + if (yych == ')') goto yy140; + goto yy4; +yy146: + YYDEBUG(146, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy4; + if (yych <= 'Z') goto yy142; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; + } } -yy1058: - yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1059; - case '1': - case '2': goto yy1060; - case '3': goto yy1061; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy659; - default: goto yy57; +yy147: + YYDEBUG(147, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy4; + if (yych <= 'Z') goto yy143; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy151; + goto yy4; + } + } +yy148: + YYDEBUG(148, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + if (yybm[0+yych] & 8) { + goto yy149; + } + goto yy57; +yy149: + YYDEBUG(149, *YYCURSOR); + yyaccept = 0; + YYMARKER = ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(150, *YYCURSOR); + if (yybm[0+yych] & 8) { + goto yy149; } -yy1059: - yyaccept = 13; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1062; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy4; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy4; } -yy1060: - yyaccept = 13; +yy151: + YYDEBUG(151, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1062; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy4; + if (yych <= 'Z') goto yy144; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; + } } -yy1061: - yyaccept = 13; +yy152: + YYDEBUG(152, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': goto yy1062; - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy604; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy657; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy4; + if (yych <= 'Z') goto yy145; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + if (yych >= '{') goto yy4; + } } -yy1062: - yyaccept = 15; +yy153: + YYDEBUG(153, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy605; - case 'n': goto yy661; - case 'r': goto yy662; - case 's': goto yy660; - case 't': goto yy663; - default: goto yy764; + if (yybm[0+yych] & 16) { + goto yy154; } -yy1063: + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych <= '/') { + if (yych <= '.') goto yy4; + goto yy148; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } +yy154: + YYDEBUG(154, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; +yy155: + YYDEBUG(155, *YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; + } + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy57; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy57; + } +yy156: + YYDEBUG(156, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '\t': goto yy1052; - case '-': goto yy1051; - case '.': goto yy1064; - case '/': goto yy730; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1066; - case '6': - case '7': - case '8': - case '9': goto yy741; - case ':': goto yy1065; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy1054; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Z') goto yy141; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy141; + goto yy4; } -yy1064: +yy157: + YYDEBUG(157, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1088; - case '1': goto yy1089; - case '2': - case '3': - case '4': - case '5': goto yy1090; - case '6': - case '7': - case '8': - case '9': goto yy1091; - default: goto yy578; + if (yych <= 'S') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'Z') { + if (yych >= 'U') goto yy142; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1065: + YYDEBUG(158, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych != '+') goto yy4; + } + } else { + if (yych <= 'Z') { + if (yych <= '-') goto yy159; + if (yych <= '@') goto yy4; + goto yy143; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy159: + YYDEBUG(159, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1083; - case '6': - case '7': - case '8': - case '9': goto yy1084; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy160; + if (yych <= '2') goto yy161; + if (yych <= '9') goto yy162; + goto yy57; +yy160: + YYDEBUG(160, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy162; + if (yych <= ':') goto yy163; + goto yy4; +yy161: + YYDEBUG(161, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '5') { + if (yych <= '/') goto yy4; + if (yych >= '5') goto yy164; + } else { + if (yych <= '9') goto yy140; + if (yych <= ':') goto yy163; + goto yy4; } -yy1066: +yy162: + YYDEBUG(162, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '-': goto yy785; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1067; - default: goto yy61; + if (yych <= '/') goto yy4; + if (yych <= '5') goto yy164; + if (yych <= '9') goto yy140; + if (yych >= ';') goto yy4; +yy163: + YYDEBUG(163, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy4; + if (yych <= '5') goto yy164; + if (yych <= '9') goto yy140; + goto yy4; +yy164: + YYDEBUG(164, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy140; + goto yy4; +yy165: + YYDEBUG(165, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'C') goto yy142; + if (yych >= 'E') goto yy168; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'd') goto yy166; + if (yych <= 'e') goto yy168; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1067: - yyaccept = 24; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'A': - case 'D': - case 'F': - case 'H': - case 'I': - case 'J': - case 'M': - case 'N': - case 'O': - case 'S': - case 'T': - case 'V': - case 'X': - case 'Y': - case 'a': - case 'd': - case 'f': - case 'h': - case 'j': - case 'm': - case 'n': - case 'o': - case 's': - case 't': - case 'w': - case 'y': goto yy791; - case '-': goto yy788; - case '.': goto yy792; - case '/': goto yy789; - case '0': goto yy1069; - case '1': goto yy1070; - case '2': goto yy1071; - case '3': goto yy1072; - case '4': - case '5': goto yy1073; - case '6': goto yy1074; - case '7': - case '8': - case '9': goto yy55; - case ':': goto yy807; - case 'W': goto yy810; - default: goto yy1068; +yy166: + YYDEBUG(166, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= 'N') { + if (yych <= ')') { + if (yych >= ')') goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'M') goto yy143; + goto yy174; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy143; + if (yych >= 'a') goto yy143; + } else { + if (yych <= 'n') goto yy174; + if (yych <= 'z') goto yy143; + } } -yy1068: -#line 1199 "ext/date/lib/parse_date.re" +yy167: + YYDEBUG(167, *YYCURSOR); +#line 1587 "ext/date/lib/parse_date.re" { - DEBUG_OUTPUT("gnunocolon"); + const timelib_relunit* relunit; + DEBUG_OUTPUT("daytext"); TIMELIB_INIT; - switch (s->time->have_time) { - case 0: - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - s->time->s = 0; - break; - case 1: - s->time->y = timelib_get_nr((char **) &ptr, 4); - break; - default: - TIMELIB_DEINIT; - add_error(s, "Double time specification"); - return TIMELIB_ERROR; + TIMELIB_HAVE_RELATIVE(); + TIMELIB_HAVE_WEEKDAY_RELATIVE(); + TIMELIB_UNHAVE_TIME(); + relunit = timelib_lookup_relunit((char**) &ptr); + s->time->relative.weekday = relunit->multiplier; + if (s->time->relative.weekday_behavior != 2) { + s->time->relative.weekday_behavior = 1; + } + + TIMELIB_DEINIT; + return TIMELIB_WEEKDAY; + } +#line 3615 "ext/date/lib/parse_date.c" +yy168: + YYDEBUG(168, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'K') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'J') goto yy143; + } + } else { + if (yych <= 'j') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'k') goto yy169; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy169: + YYDEBUG(169, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy144; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'd') goto yy170; + if (yych <= 'z') goto yy144; + goto yy4; } - s->time->have_time++; - TIMELIB_DEINIT; - return TIMELIB_GNU_NOCOLON; } -#line 22422 "" -yy1069: +yy170: + YYDEBUG(170, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1081; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1082; - default: goto yy61; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy145; + goto yy4; + } else { + if (yych <= 'a') goto yy171; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1070: +yy171: + YYDEBUG(171, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': goto yy1080; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1079; - default: goto yy61; + if (yych <= 'X') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Y') goto yy172; + if (yych != 'y') goto yy4; } -yy1071: +yy172: + YYDEBUG(172, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1079; - default: goto yy61; + if (yych == 'S') goto yy173; + if (yych != 's') goto yy167; +yy173: + YYDEBUG(173, *YYCURSOR); + yych = *++YYCURSOR; + goto yy167; +yy174: + YYDEBUG(174, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy144; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'e') goto yy175; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1072: +yy175: + YYDEBUG(175, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1077; - case '6': goto yy1078; - case '7': - case '8': - case '9': goto yy1075; - default: goto yy61; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'R') goto yy145; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 's') goto yy176; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1073: +yy176: + YYDEBUG(176, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'D') goto yy177; + if (yych != 'd') goto yy4; + } +yy177: + YYDEBUG(177, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1075; - default: goto yy61; + if (yych == 'A') goto yy178; + if (yych != 'a') goto yy57; +yy178: + YYDEBUG(178, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy173; + if (yych == 'y') goto yy173; + goto yy57; +yy179: + YYDEBUG(179, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych <= '/') { + if (yych <= '.') goto yy4; + goto yy148; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy142; + goto yy166; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'E') goto yy168; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy147; + } else { + if (yych <= 'e') goto yy181; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1074: + YYDEBUG(180, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy174; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 'n') goto yy187; + if (yych <= 'z') goto yy151; + goto yy167; + } + } + } +yy181: + YYDEBUG(181, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'J') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'K') goto yy169; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'j') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'k') goto yy182; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy182: + YYDEBUG(182, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy170; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'd') goto yy183; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy183: + YYDEBUG(183, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy171; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy184; + if (yych <= 'z') goto yy153; + goto yy4; + } + } +yy184: + YYDEBUG(184, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'Y') goto yy172; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'y') goto yy185; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy185: + YYDEBUG(185, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy167; + } else { + if (yych <= '/') goto yy148; + if (yych <= 'R') goto yy167; + goto yy173; + } + } else { + if (yych <= '`') { + if (yych == '_') goto yy148; + goto yy167; + } else { + if (yych == 's') goto yy186; + if (yych <= 'z') goto yy154; + goto yy167; + } + } +yy186: + YYDEBUG(186, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; + } + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy167; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy167; + } +yy187: + YYDEBUG(187, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy175; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'e') goto yy188; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy188: + YYDEBUG(188, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy176; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 's') goto yy189; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy189: + YYDEBUG(189, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'D') goto yy177; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'd') goto yy190; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy190: + YYDEBUG(190, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1075; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy61; + if (yych == 'A') goto yy178; + if (yych != 'a') goto yy155; + YYDEBUG(191, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy173; + if (yych == 'y') goto yy186; + goto yy155; +yy192: + YYDEBUG(192, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'C') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'B') goto yy142; + } + } else { + if (yych <= 'b') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'c') goto yy193; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1075: - yyaccept = 25; +yy193: + YYDEBUG(193, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy55; - default: goto yy1076; + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych >= '\t') goto yy196; + } else { + if (yych == ' ') goto yy196; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + } else { + if (yych == 'E') goto yy202; + goto yy143; + } + } else { + if (yych <= 'd') { + if (yych >= 'a') goto yy143; + } else { + if (yych <= 'e') goto yy202; + if (yych <= 'z') goto yy143; + } + } } -yy1076: -#line 1245 "ext/date/lib/parse_date.re" +yy194: + YYDEBUG(194, *YYCURSOR); +#line 1646 "ext/date/lib/parse_date.re" { - int tz_not_found; - DEBUG_OUTPUT("iso8601nocolon"); + DEBUG_OUTPUT("monthtext"); TIMELIB_INIT; - TIMELIB_HAVE_TIME(); - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = timelib_get_nr((char **) &ptr, 2); - s->time->s = timelib_get_nr((char **) &ptr, 2); - - if (*ptr != '\0') { - s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); - if (tz_not_found) { - add_error(s, "The timezone could not be found in the database"); - } - } + TIMELIB_HAVE_DATE(); + s->time->m = timelib_lookup_month((char **) &ptr); TIMELIB_DEINIT; - return TIMELIB_ISO_NOCOLON; + return TIMELIB_DATE_TEXT; } -#line 22567 "" -yy1077: - yyaccept = 25; +#line 4144 "ext/date/lib/parse_date.c" +yy195: + YYDEBUG(195, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 21) YYFILL(21); + yych = *YYCURSOR; +yy196: + YYDEBUG(196, *YYCURSOR); + if (yybm[0+yych] & 32) { + goto yy195; + } + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy198; + if (yych <= '3') goto yy200; + if (yych <= '9') goto yy201; + goto yy57; +yy197: + YYDEBUG(197, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy196; + if (yych <= '0') goto yy357; + if (yych <= '2') goto yy358; + if (yych <= '3') goto yy359; + goto yy196; +yy198: + YYDEBUG(198, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy1076; + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy298; + goto yy299; + } else { + if (yych <= '2') goto yy355; + if (yych <= '9') goto yy356; + goto yy216; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy212; + if (yych <= 'q') goto yy216; + goto yy213; + } else { + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1078: - yyaccept = 25; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': goto yy821; - case '7': - case '8': - case '9': goto yy55; - default: goto yy1076; +yy199: + YYDEBUG(199, *YYCURSOR); +#line 1396 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("datetextual | datenoyear"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->m = timelib_get_month((char **) &ptr); + s->time->d = timelib_get_nr((char **) &ptr, 2); + s->time->y = timelib_get_nr((char **) &ptr, 4); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_DATE_TEXT; } -yy1079: - yyaccept = 25; +#line 4207 "ext/date/lib/parse_date.c" +yy200: + YYDEBUG(200, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy1076; + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy298; + goto yy299; + } else { + if (yych <= '2') goto yy209; + if (yych <= '9') goto yy210; + goto yy216; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy212; + if (yych <= 'q') goto yy216; + goto yy213; + } else { + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1080: - yyaccept = 25; +yy201: + YYDEBUG(201, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': goto yy845; - case '1': - case '2': goto yy846; - case '3': goto yy847; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy1076; + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy207; + goto yy208; + } else { + if (yych <= '2') goto yy209; + if (yych <= '9') goto yy210; + goto yy216; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy212; + if (yych <= 'q') goto yy216; + goto yy213; + } else { + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1081: - yyaccept = 25; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': goto yy877; - case '1': - case '2': goto yy846; - case '3': goto yy847; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy1076; +yy202: + YYDEBUG(202, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'M') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'L') goto yy144; + } + } else { + if (yych <= 'l') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'm') goto yy203; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1082: - yyaccept = 25; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case 'D': - case 'F': - case 'H': - case 'M': - case 'S': - case 'T': - case 'W': - case 'Y': - case 'd': - case 'f': - case 'h': - case 'm': - case 's': - case 't': - case 'w': - case 'y': goto yy61; - case '0': goto yy845; - case '1': - case '2': goto yy846; - case '3': goto yy847; - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy821; - default: goto yy1076; +yy203: + YYDEBUG(203, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'B') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'A') goto yy145; + } + } else { + if (yych <= 'a') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'b') goto yy204; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1083: - yyaccept = 11; +yy204: + YYDEBUG(204, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy1085; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1084; - default: goto yy491; + if (yych <= 'D') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'E') goto yy205; + if (yych != 'e') goto yy4; } -yy1084: - yyaccept = 11; +yy205: + YYDEBUG(205, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy206; + if (yych != 'r') goto yy57; +yy206: + YYDEBUG(206, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': - case ':': goto yy1085; - default: goto yy491; + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy194; + goto yy196; + } else { + if (yych <= '.') { + if (yych <= ',') goto yy194; + goto yy196; + } else { + if (yych <= '/') goto yy194; + if (yych <= '9') goto yy196; + goto yy194; + } } -yy1085: +yy207: + YYDEBUG(207, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1086; - case '6': goto yy1087; - case '7': - case '8': - case '9': goto yy496; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy57; + } else { + if (yych <= '0') goto yy296; + if (yych <= '9') goto yy297; + if (yych <= ':') goto yy221; + goto yy57; } -yy1086: - yyaccept = 11; +yy208: + YYDEBUG(208, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '2') goto yy297; + if (yych <= '9') goto yy296; + if (yych <= ':') goto yy264; + goto yy57; + } +yy209: + YYDEBUG(209, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '4') goto yy296; + if (yych <= '9') goto yy293; + if (yych <= ':') goto yy264; + goto yy57; + } +yy210: + YYDEBUG(210, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '9') goto yy293; + if (yych <= ':') goto yy264; + goto yy57; + } +yy211: + YYDEBUG(211, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy496; - default: goto yy491; + goto yy216; +yy212: + YYDEBUG(212, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + goto yy216; +yy213: + YYDEBUG(213, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + goto yy216; +yy214: + YYDEBUG(214, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + goto yy216; +yy215: + YYDEBUG(215, *YYCURSOR); + yyaccept = 6; + YYMARKER = ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 18) YYFILL(18); + yych = *YYCURSOR; +yy216: + YYDEBUG(216, *YYCURSOR); + if (yybm[0+yych] & 64) { + goto yy215; + } + if (yych <= '2') { + if (yych <= '/') goto yy199; + if (yych <= '0') goto yy259; + if (yych <= '1') goto yy260; + goto yy261; + } else { + if (yych <= '9') goto yy262; + if (yych != 'T') goto yy199; } -yy1087: - yyaccept = 11; + YYDEBUG(217, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy218; + if (yych <= '2') goto yy219; + if (yych <= '9') goto yy220; + goto yy57; +yy218: + YYDEBUG(218, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy57; + } else { + if (yych <= '9') goto yy220; + if (yych <= ':') goto yy221; + goto yy57; + } +yy219: + YYDEBUG(219, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy57; + } else { + if (yych <= '4') goto yy220; + if (yych == ':') goto yy221; + goto yy57; + } +yy220: + YYDEBUG(220, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '.') goto yy221; + if (yych != ':') goto yy57; +yy221: + YYDEBUG(221, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy222; + if (yych <= '9') goto yy224; + goto yy57; +yy222: + YYDEBUG(222, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': goto yy496; - default: goto yy491; + if (yych <= '/') { + if (yych == '.') goto yy225; + } else { + if (yych <= '9') goto yy224; + if (yych <= ':') goto yy225; } -yy1088: - yyaccept = 11; +yy223: + YYDEBUG(223, *YYCURSOR); +#line 1694 "ext/date/lib/parse_date.re" + { + int tz_not_found; + DEBUG_OUTPUT("dateshortwithtimeshort | dateshortwithtimelong | dateshortwithtimelongtz"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->m = timelib_get_month((char **) &ptr); + s->time->d = timelib_get_nr((char **) &ptr, 2); + + TIMELIB_HAVE_TIME(); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + if (*ptr == ':') { + s->time->s = timelib_get_nr((char **) &ptr, 2); + + if (*ptr == '.') { + s->time->f = timelib_get_frac_nr((char **) &ptr, 8); + } + } + + if (*ptr != '\0') { + s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); + if (tz_not_found) { + add_error(s, "The timezone could not be found in the database"); + } + } + TIMELIB_DEINIT; + return TIMELIB_SHORTDATE_WITH_TIME; + } +#line 4505 "ext/date/lib/parse_date.c" +yy224: + YYDEBUG(224, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy1092; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1091; - case ':': goto yy1085; - default: goto yy491; + if (yych == '.') goto yy225; + if (yych != ':') goto yy223; +yy225: + YYDEBUG(225, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy226; + if (yych <= '6') goto yy227; + if (yych <= '9') goto yy228; + goto yy57; +yy226: + YYDEBUG(226, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy223; + if (yych <= '9') goto yy229; + goto yy223; +yy227: + YYDEBUG(227, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '0') goto yy229; + goto yy223; +yy228: + YYDEBUG(228, *YYCURSOR); + yych = *++YYCURSOR; + goto yy223; +yy229: + YYDEBUG(229, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '*') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy231; + goto yy223; + } else { + if (yych <= ' ') goto yy231; + if (yych == '(') goto yy231; + goto yy223; + } + } else { + if (yych <= '@') { + if (yych == ',') goto yy223; + if (yych <= '-') goto yy231; + goto yy223; + } else { + if (yych <= 'Z') goto yy231; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy231; + goto yy223; + } } -yy1089: - yyaccept = 11; +yy230: + YYDEBUG(230, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; +yy231: + YYDEBUG(231, *YYCURSOR); + if (yych <= '+') { + if (yych <= ' ') { + if (yych == '\t') goto yy230; + if (yych <= 0x1F) goto yy57; + goto yy230; + } else { + if (yych == '(') goto yy234; + if (yych <= '*') goto yy57; + goto yy233; + } + } else { + if (yych <= 'F') { + if (yych == '-') goto yy233; + if (yych <= '@') goto yy57; + goto yy235; + } else { + if (yych <= 'Z') { + if (yych >= 'H') goto yy235; + } else { + if (yych <= '`') goto yy57; + if (yych <= 'z') goto yy236; + goto yy57; + } + } + } +yy232: + YYDEBUG(232, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych == ')') goto yy228; + if (yych <= '@') goto yy223; + goto yy237; + } else { + if (yych <= 'Z') { + if (yych <= 'M') goto yy257; + goto yy237; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy242; + goto yy223; + } + } +yy233: + YYDEBUG(233, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy252; + if (yych <= '2') goto yy253; + if (yych <= '9') goto yy254; + goto yy57; +yy234: + YYDEBUG(234, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') goto yy57; + if (yych <= 'Z') goto yy236; + if (yych <= '`') goto yy57; + if (yych <= 'z') goto yy236; + goto yy57; +yy235: + YYDEBUG(235, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= 'Z') goto yy237; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy242; + goto yy223; + } +yy236: + YYDEBUG(236, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= 'Z') goto yy237; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } +yy237: + YYDEBUG(237, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= 'Z') goto yy238; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } +yy238: + YYDEBUG(238, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= 'Z') goto yy239; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } +yy239: + YYDEBUG(239, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= 'Z') goto yy240; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } +yy240: + YYDEBUG(240, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '@') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= 'Z') goto yy241; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } +yy241: + YYDEBUG(241, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == ')') goto yy228; + goto yy223; +yy242: + YYDEBUG(242, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy1092; - case '0': - case '1': - case '2': goto yy1091; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1084; - case ':': goto yy1085; - default: goto yy491; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych == '.') goto yy223; + goto yy244; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy223; + if (yych <= 'Z') goto yy238; + goto yy223; + } else { + if (yych <= '_') goto yy244; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } } -yy1090: - yyaccept = 11; +yy243: + YYDEBUG(243, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy1092; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1084; - case ':': goto yy1085; - default: goto yy491; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych == '.') goto yy223; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy223; + if (yych <= 'Z') goto yy239; + goto yy223; + } else { + if (yych <= '_') goto yy244; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy247; + goto yy223; + } + } +yy244: + YYDEBUG(244, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + if (yych <= '@') goto yy57; + if (yych <= 'Z') goto yy245; + if (yych <= '`') goto yy57; + if (yych >= '{') goto yy57; +yy245: + YYDEBUG(245, *YYCURSOR); + yyaccept = 7; + YYMARKER = ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(246, *YYCURSOR); + if (yych <= '@') { + if (yych <= '-') { + if (yych <= ',') goto yy223; + goto yy244; + } else { + if (yych == '/') goto yy244; + goto yy223; + } + } else { + if (yych <= '_') { + if (yych <= 'Z') goto yy245; + if (yych <= '^') goto yy223; + goto yy244; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy245; + goto yy223; + } } -yy1091: - yyaccept = 11; +yy247: + YYDEBUG(247, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': goto yy602; - case '.': goto yy1092; - case ':': goto yy1085; - default: goto yy491; - } -yy1092: - yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1093; - case '6': goto yy1094; - case '7': - case '8': - case '9': goto yy610; - default: goto yy57; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych == '.') goto yy223; + goto yy244; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy223; + if (yych <= 'Z') goto yy240; + goto yy223; + } else { + if (yych <= '_') goto yy244; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } } -yy1093: - yyaccept = 11; + YYDEBUG(248, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1095; - default: goto yy491; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych == '.') goto yy223; + goto yy244; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy223; + if (yych <= 'Z') goto yy241; + goto yy223; + } else { + if (yych <= '_') goto yy244; + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } } -yy1094: - yyaccept = 11; + YYDEBUG(249, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': goto yy1095; - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy611; - default: goto yy491; + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy223; + goto yy228; + } else { + if (yych == '-') goto yy244; + goto yy223; + } + } else { + if (yych <= '_') { + if (yych <= '/') goto yy244; + if (yych <= '^') goto yy223; + goto yy244; + } else { + if (yych <= '`') goto yy223; + if (yych >= '{') goto yy223; + } } -yy1095: - yyaccept = 11; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '.': goto yy497; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy605; - default: goto yy491; +yy250: + YYDEBUG(250, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(251, *YYCURSOR); + if (yych <= '/') { + if (yych == '-') goto yy244; + if (yych <= '.') goto yy57; + goto yy244; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy57; + goto yy244; + } else { + if (yych <= '`') goto yy57; + if (yych <= 'z') goto yy250; + goto yy57; + } } -yy1096: +yy252: + YYDEBUG(252, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '\t': goto yy460; - case '-': goto yy1051; - case '.': goto yy474; - case '/': goto yy472; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1066; - case '6': - case '7': - case '8': - case '9': goto yy741; - case ':': goto yy483; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy462; - } -yy1097: + if (yych <= '/') goto yy223; + if (yych <= '9') goto yy254; + if (yych <= ':') goto yy255; + goto yy223; +yy253: + YYDEBUG(253, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '\t': goto yy1052; - case '-': goto yy1051; - case '.': goto yy1064; - case '/': goto yy472; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1066; - case '6': - case '7': - case '8': - case '9': goto yy741; - case ':': goto yy1065; - case 'n': goto yy470; - case 'r': goto yy471; - case 's': goto yy464; - case 't': goto yy468; - default: goto yy1054; + if (yych <= '5') { + if (yych <= '/') goto yy223; + if (yych >= '5') goto yy256; + } else { + if (yych <= '9') goto yy228; + if (yych <= ':') goto yy255; + goto yy223; } -yy1098: +yy254: + YYDEBUG(254, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'E': - case 'e': goto yy1099; - default: goto yy4; - } -yy1099: + if (yych <= '/') goto yy223; + if (yych <= '5') goto yy256; + if (yych <= '9') goto yy228; + if (yych >= ';') goto yy223; +yy255: + YYDEBUG(255, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'V': - case 'v': goto yy1100; - default: goto yy4; + if (yych <= '/') goto yy223; + if (yych <= '5') goto yy256; + if (yych <= '9') goto yy228; + goto yy223; +yy256: + YYDEBUG(256, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy223; + if (yych <= '9') goto yy228; + goto yy223; +yy257: + YYDEBUG(257, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych == ')') goto yy228; + if (yych <= '@') goto yy223; + goto yy238; + } else { + if (yych <= 'Z') { + if (yych >= 'U') goto yy238; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy238; + goto yy223; + } + } + YYDEBUG(258, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= ')') { + if (yych <= '(') goto yy223; + goto yy228; + } else { + if (yych == '+') goto yy233; + goto yy223; + } + } else { + if (yych <= 'Z') { + if (yych <= '-') goto yy233; + if (yych <= '@') goto yy223; + goto yy239; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy239; + goto yy223; + } + } +yy259: + YYDEBUG(259, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy199; + } else { + if (yych <= '0') goto yy291; + if (yych <= '9') goto yy292; + if (yych <= ':') goto yy221; + goto yy199; } -yy1100: +yy260: + YYDEBUG(260, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy199; + } else { + if (yych <= '2') goto yy292; + if (yych <= '9') goto yy291; + if (yych <= ':') goto yy264; + goto yy199; + } +yy261: + YYDEBUG(261, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy199; + } else { + if (yych <= '4') goto yy291; + if (yych <= '9') goto yy263; + if (yych <= ':') goto yy264; + goto yy199; + } +yy262: + YYDEBUG(262, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy199; + } else { + if (yych <= '9') goto yy263; + if (yych <= ':') goto yy264; + goto yy199; + } +yy263: + YYDEBUG(263, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'I': - case 'i': goto yy1101; - default: goto yy4; + if (yych <= '/') goto yy199; + if (yych <= '9') goto yy289; + goto yy199; +yy264: + YYDEBUG(264, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy265; + if (yych <= '9') goto yy266; + goto yy57; +yy265: + YYDEBUG(265, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy267; + goto yy223; + } else { + if (yych <= '9') goto yy282; + if (yych <= ':') goto yy267; + goto yy223; } -yy1101: +yy266: + YYDEBUG(266, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy267; + if (yych != ':') goto yy223; +yy267: + YYDEBUG(267, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'O': - case 'o': goto yy1102; - default: goto yy4; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy268; + if (yych <= '6') goto yy269; + if (yych <= '9') goto yy228; + goto yy57; +yy268: + YYDEBUG(268, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy223; + if (yych <= '9') goto yy270; + goto yy223; +yy269: + YYDEBUG(269, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '0') goto yy223; +yy270: + YYDEBUG(270, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '*') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy272; + goto yy223; + } else { + if (yych <= ' ') goto yy272; + if (yych == '(') goto yy272; + goto yy223; + } + } else { + if (yych <= '@') { + if (yych == ',') goto yy223; + if (yych <= '-') goto yy272; + goto yy223; + } else { + if (yych <= 'Z') goto yy272; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy272; + goto yy223; + } } -yy1102: - yyaccept = 0; +yy271: + YYDEBUG(271, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; +yy272: + YYDEBUG(272, *YYCURSOR); + if (yych <= '@') { + if (yych <= '\'') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy57; + goto yy271; + } else { + if (yych == ' ') goto yy271; + goto yy57; + } + } else { + if (yych <= '+') { + if (yych <= '(') goto yy234; + if (yych <= '*') goto yy57; + goto yy233; + } else { + if (yych == '-') goto yy233; + goto yy57; + } + } + } else { + if (yych <= 'Z') { + if (yych <= 'G') { + if (yych <= 'A') goto yy273; + if (yych <= 'F') goto yy235; + goto yy232; + } else { + if (yych != 'P') goto yy235; + } + } else { + if (yych <= 'o') { + if (yych <= '`') goto yy57; + if (yych <= 'a') goto yy274; + goto yy236; + } else { + if (yych <= 'p') goto yy274; + if (yych <= 'z') goto yy236; + goto yy57; + } + } + } +yy273: + YYDEBUG(273, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'U': - case 'u': goto yy1103; - default: goto yy4; + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= '.') goto yy275; + if (yych <= '@') goto yy223; + goto yy237; + } + } else { + if (yych <= '`') { + if (yych <= 'M') goto yy276; + if (yych <= 'Z') goto yy237; + goto yy223; + } else { + if (yych == 'm') goto yy281; + if (yych <= 'z') goto yy242; + goto yy223; + } } -yy1103: +yy274: + YYDEBUG(274, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= '.') goto yy275; + if (yych <= '@') goto yy223; + goto yy237; + } + } else { + if (yych <= '`') { + if (yych <= 'M') goto yy276; + if (yych <= 'Z') goto yy237; + goto yy223; + } else { + if (yych == 'm') goto yy276; + if (yych <= 'z') goto yy237; + goto yy223; + } + } +yy275: + YYDEBUG(275, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy1104; - default: goto yy57; + if (yych == 'M') goto yy280; + if (yych == 'm') goto yy280; + goto yy57; +yy276: + YYDEBUG(276, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ')') { + if (yych <= '\t') { + if (yych <= 0x00) goto yy278; + if (yych <= 0x08) goto yy223; + goto yy278; + } else { + if (yych == ' ') goto yy278; + if (yych <= '(') goto yy223; + goto yy228; + } + } else { + if (yych <= '@') { + if (yych != '.') goto yy223; + } else { + if (yych <= 'Z') goto yy238; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy238; + goto yy223; + } } -yy1104: +yy277: + YYDEBUG(277, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy1105; - default: goto yy57; + if (yych <= '\t') { + if (yych <= 0x00) goto yy278; + if (yych <= 0x08) goto yy57; + } else { + if (yych != ' ') goto yy57; + } +yy278: + YYDEBUG(278, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(279, *YYCURSOR); +#line 1670 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("dateshortwithtimeshort12 | dateshortwithtimelong12"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->m = timelib_get_month((char **) &ptr); + s->time->d = timelib_get_nr((char **) &ptr, 2); + + TIMELIB_HAVE_TIME(); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + if (*ptr == ':' || *ptr == '.') { + s->time->s = timelib_get_nr((char **) &ptr, 2); + + if (*ptr == '.') { + s->time->f = timelib_get_frac_nr((char **) &ptr, 8); + } + } + + s->time->h += timelib_meridian((char **) &ptr, s->time->h); + TIMELIB_DEINIT; + return TIMELIB_SHORTDATE_WITH_TIME; + } +#line 5226 "ext/date/lib/parse_date.c" +yy280: + YYDEBUG(280, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy278; + if (yych == '\t') goto yy278; + goto yy57; + } else { + if (yych <= ' ') goto yy278; + if (yych == '.') goto yy277; + goto yy57; + } +yy281: + YYDEBUG(281, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '-') { + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy278; + if (yych == '\t') goto yy278; + goto yy223; + } else { + if (yych <= '(') { + if (yych <= ' ') goto yy278; + goto yy223; + } else { + if (yych <= ')') goto yy228; + if (yych <= ',') goto yy223; + goto yy244; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '.') goto yy277; + if (yych <= '/') goto yy244; + if (yych <= '@') goto yy223; + goto yy238; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy223; + goto yy244; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy243; + goto yy223; + } + } + } +yy282: + YYDEBUG(282, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy283; + if (yych <= 0x1F) goto yy223; + } else { + if (yych == '.') goto yy267; + if (yych <= '9') goto yy223; + goto yy267; + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy285; + if (yych <= 'O') goto yy223; + goto yy285; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy223; + goto yy285; + } else { + if (yych == 'p') goto yy285; + goto yy223; + } + } } -yy1105: +yy283: + YYDEBUG(283, *YYCURSOR); ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); yych = *YYCURSOR; -yy1106: - switch (yych) { - case '\t': - case ' ': goto yy1105; - case 'D': - case 'd': goto yy1110; - case 'F': - case 'f': goto yy1111; - case 'H': - case 'h': goto yy1109; - case 'M': - case 'm': goto yy1108; - case 'S': - case 's': goto yy1107; - case 'T': - case 't': goto yy1114; - case 'W': - case 'w': goto yy1113; - case 'Y': - case 'y': goto yy1112; - default: goto yy57; + YYDEBUG(284, *YYCURSOR); + if (yych <= 'A') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy283; + goto yy57; + } else { + if (yych <= ' ') goto yy283; + if (yych <= '@') goto yy57; + } + } else { + if (yych <= '`') { + if (yych != 'P') goto yy57; + } else { + if (yych <= 'a') goto yy285; + if (yych != 'p') goto yy57; + } } -yy1107: +yy285: + YYDEBUG(285, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1179; - case 'E': - case 'e': goto yy1180; - case 'U': - case 'u': goto yy1178; - default: goto yy57; + if (yych <= 'L') { + if (yych != '.') goto yy57; + } else { + if (yych <= 'M') goto yy287; + if (yych == 'm') goto yy287; + goto yy57; } -yy1108: +yy286: + YYDEBUG(286, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy1170; - case 'O': - case 'o': goto yy1169; - default: goto yy57; - } -yy1109: + if (yych == 'M') goto yy287; + if (yych != 'm') goto yy57; +yy287: + YYDEBUG(287, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1167; - default: goto yy57; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy278; + if (yych == '\t') goto yy278; + goto yy57; + } else { + if (yych <= ' ') goto yy278; + if (yych != '.') goto yy57; } -yy1110: +yy288: + YYDEBUG(288, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1166; - default: goto yy57; + if (yych <= '\t') { + if (yych <= 0x00) goto yy278; + if (yych <= 0x08) goto yy57; + goto yy278; + } else { + if (yych == ' ') goto yy278; + goto yy57; } -yy1111: +yy289: + YYDEBUG(289, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1151; - case 'R': - case 'r': goto yy1150; - default: goto yy57; - } -yy1112: + if (yych <= '/') goto yy199; + if (yych >= ':') goto yy199; + YYDEBUG(290, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1147; - default: goto yy57; + goto yy199; +yy291: + YYDEBUG(291, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy199; + } else { + if (yych <= '9') goto yy289; + if (yych <= ':') goto yy221; + goto yy199; } -yy1113: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1133; - default: goto yy57; +yy292: + YYDEBUG(292, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy199; + } else { + if (yych <= '9') goto yy289; + if (yych <= ':') goto yy264; + goto yy199; } -yy1114: +yy293: + YYDEBUG(293, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy1115; - case 'U': - case 'u': goto yy1116; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy294: + YYDEBUG(294, *YYCURSOR); + ++YYCURSOR; +yy295: + YYDEBUG(295, *YYCURSOR); +#line 1370 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("datenoday"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->m = timelib_get_month((char **) &ptr); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->d = 1; + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_DATE_NO_DAY; } -yy1115: +#line 5416 "ext/date/lib/parse_date.c" +yy296: + YYDEBUG(296, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'U': - case 'u': goto yy1128; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy57; + } else { + if (yych <= '9') goto yy294; + if (yych <= ':') goto yy221; + goto yy57; } -yy1116: +yy297: + YYDEBUG(297, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1117; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '9') goto yy294; + if (yych <= ':') goto yy264; + goto yy57; } -yy1117: - yyaccept = 26; +yy298: + YYDEBUG(298, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'S': - case 's': goto yy1121; - default: goto yy1118; + if (yych <= '9') { + if (yych <= '/') { + if (yych == '.') goto yy331; + goto yy216; + } else { + if (yych <= '0') goto yy332; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy221; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1118: -#line 1629 "ext/date/lib/parse_date.re" - { - timelib_sll i; - int behavior = 0; - DEBUG_OUTPUT("relativetext"); - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - - while(*ptr) { - i = timelib_get_relative_text((char **) &ptr, &behavior); - timelib_eat_spaces((char **) &ptr); - timelib_set_relative((char **) &ptr, i, behavior, s); +yy299: + YYDEBUG(299, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '/') { + if (yych != '.') goto yy216; + } else { + if (yych <= '0') goto yy301; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy264; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; } - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; } -#line 23406 "" -yy1119: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); - yych = *YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'O': - case 'o': goto yy1125; - default: goto yy57; +yy300: + YYDEBUG(300, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy306; + goto yy307; + } else { + if (yych <= '2') goto yy308; + if (yych <= '5') goto yy309; + if (yych <= '9') goto yy310; + goto yy216; } -yy1121: +yy301: + YYDEBUG(301, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1122; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '0') goto yy304; + if (yych <= '9') goto yy305; + if (yych <= ':') goto yy264; + goto yy57; } -yy1122: +yy302: + YYDEBUG(302, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1123; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '2') goto yy305; + if (yych <= '9') goto yy304; + if (yych <= ':') goto yy264; + goto yy57; } -yy1123: +yy303: + YYDEBUG(303, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy264; + goto yy57; + } else { + if (yych <= '4') goto yy304; + if (yych <= '9') goto yy294; + if (yych <= ':') goto yy264; + goto yy57; } -yy1124: - yyaccept = 26; +yy304: + YYDEBUG(304, *YYCURSOR); + yyaccept = 8; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - default: goto yy1118; - } -yy1125: - yych = *++YYCURSOR; - switch (yych) { - case 'F': - case 'f': goto yy1126; - default: goto yy57; - } -yy1126: - ++YYCURSOR; -#line 1114 "ext/date/lib/parse_date.re" - { - timelib_sll i; - int behavior = 0; - DEBUG_OUTPUT("weekdayof"); - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - TIMELIB_HAVE_SPECIAL_RELATIVE(); - - i = timelib_get_relative_text((char **) &ptr, &behavior); - timelib_eat_spaces((char **) &ptr); - if (i > 0) { /* first, second... etc */ - s->time->relative.special.type = TIMELIB_SPECIAL_DAY_OF_WEEK_IN_MONTH; - timelib_set_relative((char **) &ptr, i, 1, s); - } else { /* last */ - s->time->relative.special.type = TIMELIB_SPECIAL_LAST_DAY_OF_WEEK_IN_MONTH; - timelib_set_relative((char **) &ptr, i, behavior, s); - } - TIMELIB_DEINIT; - return TIMELIB_WEEK_DAY_OF_MONTH; - } -#line 23477 "" -yy1128: - yyaccept = 26; + if (yych == '.') goto yy221; + if (yych == ':') goto yy221; + goto yy295; +yy305: + YYDEBUG(305, *YYCURSOR); + yyaccept = 8; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'R': - case 'r': goto yy1129; - default: goto yy1118; + if (yych == '.') goto yy264; + if (yych == ':') goto yy264; + goto yy295; +yy306: + YYDEBUG(306, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy326; + goto yy199; + } else { + if (yych <= '0') goto yy325; + if (yych <= '9') goto yy330; + if (yych <= ':') goto yy326; + goto yy199; } -yy1129: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy1130; - default: goto yy57; +yy307: + YYDEBUG(307, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy311; + goto yy199; + } else { + if (yych <= '2') goto yy330; + if (yych <= '9') goto yy325; + if (yych <= ':') goto yy311; + goto yy199; } -yy1130: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1131; - default: goto yy57; +yy308: + YYDEBUG(308, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy311; + goto yy199; + } else { + if (yych <= '4') goto yy325; + if (yych <= '9') goto yy324; + if (yych <= ':') goto yy311; + goto yy199; } -yy1131: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1132; - default: goto yy57; +yy309: + YYDEBUG(309, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy311; + goto yy199; + } else { + if (yych <= '9') goto yy324; + if (yych <= ':') goto yy311; + goto yy199; } -yy1132: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; +yy310: + YYDEBUG(310, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych != '.') goto yy199; + } else { + if (yych <= '9') goto yy263; + if (yych >= ';') goto yy199; } -yy1133: +yy311: + YYDEBUG(311, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1135; - case 'E': - case 'e': goto yy1134; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy312; + if (yych <= '6') goto yy313; + if (yych <= '9') goto yy266; + goto yy57; +yy312: + YYDEBUG(312, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy267; + goto yy223; + } else { + if (yych <= '9') goto yy314; + if (yych <= ':') goto yy267; + goto yy223; } -yy1134: - yych = *++YYCURSOR; - switch (yych) { - case 'K': - case 'k': goto yy1141; - default: goto yy57; +yy313: + YYDEBUG(313, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy267; + goto yy223; + } else { + if (yych <= '0') goto yy270; + if (yych == ':') goto yy267; + goto yy223; } -yy1135: - yyaccept = 26; +yy314: + YYDEBUG(314, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'N': - case 'n': goto yy1136; - default: goto yy1118; + if (yych <= ',') { + if (yych <= ' ') { + if (yych == '\t') goto yy316; + if (yych <= 0x1F) goto yy223; + goto yy316; + } else { + if (yych <= '(') { + if (yych <= '\'') goto yy223; + goto yy316; + } else { + if (yych == '+') goto yy316; + goto yy223; + } + } + } else { + if (yych <= ':') { + if (yych <= '-') goto yy316; + if (yych <= '.') goto yy267; + if (yych <= '9') goto yy223; + goto yy267; + } else { + if (yych <= 'Z') { + if (yych <= '@') goto yy223; + goto yy316; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy316; + goto yy223; + } + } } -yy1136: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1137; - default: goto yy57; +yy315: + YYDEBUG(315, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; +yy316: + YYDEBUG(316, *YYCURSOR); + if (yych <= '@') { + if (yych <= '\'') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy57; + goto yy315; + } else { + if (yych == ' ') goto yy315; + goto yy57; + } + } else { + if (yych <= '+') { + if (yych <= '(') goto yy234; + if (yych <= '*') goto yy57; + goto yy233; + } else { + if (yych == '-') goto yy233; + goto yy57; + } + } + } else { + if (yych <= 'Z') { + if (yych <= 'G') { + if (yych <= 'A') goto yy317; + if (yych <= 'F') goto yy235; + goto yy232; + } else { + if (yych != 'P') goto yy235; + } + } else { + if (yych <= 'o') { + if (yych <= '`') goto yy57; + if (yych <= 'a') goto yy318; + goto yy236; + } else { + if (yych <= 'p') goto yy318; + if (yych <= 'z') goto yy236; + goto yy57; + } + } } -yy1137: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy1138; - default: goto yy57; +yy317: + YYDEBUG(317, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= '.') goto yy320; + if (yych <= '@') goto yy223; + goto yy237; + } + } else { + if (yych <= '`') { + if (yych <= 'M') goto yy319; + if (yych <= 'Z') goto yy237; + goto yy223; + } else { + if (yych == 'm') goto yy323; + if (yych <= 'z') goto yy242; + goto yy223; + } } -yy1138: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1139; - default: goto yy57; +yy318: + YYDEBUG(318, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= '.') goto yy320; + if (yych <= '@') goto yy223; + goto yy237; + } + } else { + if (yych <= '`') { + if (yych <= 'M') goto yy319; + if (yych <= 'Z') goto yy237; + goto yy223; + } else { + if (yych == 'm') goto yy319; + if (yych <= 'z') goto yy237; + goto yy223; + } } -yy1139: +yy319: + YYDEBUG(319, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ')') { + if (yych <= '\t') { + if (yych <= 0x00) goto yy278; + if (yych <= 0x08) goto yy223; + goto yy278; + } else { + if (yych == ' ') goto yy278; + if (yych <= '(') goto yy223; + goto yy228; + } + } else { + if (yych <= '@') { + if (yych == '.') goto yy322; + goto yy223; + } else { + if (yych <= 'Z') goto yy238; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy238; + goto yy223; + } + } +yy320: + YYDEBUG(320, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1140; - default: goto yy57; + if (yych == 'M') goto yy321; + if (yych != 'm') goto yy57; +yy321: + YYDEBUG(321, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy278; + if (yych == '\t') goto yy278; + goto yy57; + } else { + if (yych <= ' ') goto yy278; + if (yych != '.') goto yy57; } -yy1140: +yy322: + YYDEBUG(322, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; + if (yych <= '\t') { + if (yych <= 0x00) goto yy278; + if (yych <= 0x08) goto yy57; + goto yy278; + } else { + if (yych == ' ') goto yy278; + goto yy57; } -yy1141: - yyaccept = 27; +yy323: + YYDEBUG(323, *YYCURSOR); + yyaccept = 7; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'D': - case 'd': goto yy1144; - case 'S': - case 's': goto yy1143; - default: goto yy1142; + if (yych <= '-') { + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy278; + if (yych == '\t') goto yy278; + goto yy223; + } else { + if (yych <= '(') { + if (yych <= ' ') goto yy278; + goto yy223; + } else { + if (yych <= ')') goto yy228; + if (yych <= ',') goto yy223; + goto yy244; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '.') goto yy322; + if (yych <= '/') goto yy244; + if (yych <= '@') goto yy223; + goto yy238; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy223; + goto yy244; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy243; + goto yy223; + } + } } -yy1142: -#line 1605 "ext/date/lib/parse_date.re" - { - timelib_sll i; - int behavior = 0; - DEBUG_OUTPUT("relativetextweek"); - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - - while(*ptr) { - i = timelib_get_relative_text((char **) &ptr, &behavior); - timelib_eat_spaces((char **) &ptr); - timelib_set_relative((char **) &ptr, i, behavior, s); - s->time->relative.weekday_behavior = 2; - - /* to handle the format weekday + last/this/next week */ - if (s->time->relative.have_weekday_relative == 0) { - TIMELIB_HAVE_WEEKDAY_RELATIVE(); - s->time->relative.weekday = 1; +yy324: + YYDEBUG(324, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy283; + if (yych <= 0x1F) goto yy199; + goto yy283; + } else { + if (yych <= '.') { + if (yych <= '-') goto yy199; + goto yy267; + } else { + if (yych <= '/') goto yy199; + if (yych <= '9') goto yy289; + goto yy267; + } + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy285; + if (yych <= 'O') goto yy199; + goto yy285; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy199; + goto yy285; + } else { + if (yych == 'p') goto yy285; + goto yy199; } } - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; } -#line 23611 "" -yy1143: - yych = *++YYCURSOR; - goto yy1118; -yy1144: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1145; - default: goto yy57; +yy325: + YYDEBUG(325, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy283; + if (yych <= 0x1F) goto yy199; + goto yy283; + } else { + if (yych <= '.') { + if (yych <= '-') goto yy199; + } else { + if (yych <= '/') goto yy199; + if (yych <= '9') goto yy289; + } + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy285; + if (yych <= 'O') goto yy199; + goto yy285; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy199; + goto yy285; + } else { + if (yych == 'p') goto yy285; + goto yy199; + } + } } -yy1145: +yy326: + YYDEBUG(326, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1146; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy327; + if (yych <= '6') goto yy328; + if (yych <= '9') goto yy224; + goto yy57; +yy327: + YYDEBUG(327, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy225; + goto yy223; + } else { + if (yych <= '9') goto yy329; + if (yych <= ':') goto yy225; + goto yy223; } -yy1146: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy1143; - default: goto yy1118; +yy328: + YYDEBUG(328, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy225; + goto yy223; + } else { + if (yych <= '0') goto yy270; + if (yych == ':') goto yy225; + goto yy223; } -yy1147: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1148; - default: goto yy57; +yy329: + YYDEBUG(329, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= ' ') { + if (yych == '\t') goto yy272; + if (yych <= 0x1F) goto yy223; + goto yy272; + } else { + if (yych <= '(') { + if (yych <= '\'') goto yy223; + goto yy272; + } else { + if (yych == '+') goto yy272; + goto yy223; + } + } + } else { + if (yych <= ':') { + if (yych <= '-') goto yy272; + if (yych <= '.') goto yy225; + if (yych <= '9') goto yy223; + goto yy225; + } else { + if (yych <= 'Z') { + if (yych <= '@') goto yy223; + goto yy272; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy272; + goto yy223; + } + } } -yy1148: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy1149; - default: goto yy57; +yy330: + YYDEBUG(330, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy283; + if (yych <= 0x1F) goto yy199; + goto yy283; + } else { + if (yych <= '.') { + if (yych <= '-') goto yy199; + goto yy311; + } else { + if (yych <= '/') goto yy199; + if (yych <= '9') goto yy289; + goto yy311; + } + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy285; + if (yych <= 'O') goto yy199; + goto yy285; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy199; + goto yy285; + } else { + if (yych == 'p') goto yy285; + goto yy199; + } + } } -yy1149: - yych = *++YYCURSOR; - switch (yych) { - case 'S': - case 's': goto yy1143; - default: goto yy1118; +yy331: + YYDEBUG(331, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy333; + goto yy334; + } else { + if (yych <= '2') goto yy335; + if (yych <= '5') goto yy336; + if (yych <= '9') goto yy337; + goto yy216; } -yy1150: +yy332: + YYDEBUG(332, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy1163; - default: goto yy57; + if (yych <= '/') { + if (yych == '.') goto yy221; + goto yy57; + } else { + if (yych <= '0') goto yy304; + if (yych <= '9') goto yy305; + if (yych <= ':') goto yy221; + goto yy57; } -yy1151: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy1152; - default: goto yy57; +yy333: + YYDEBUG(333, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy350; + goto yy199; + } else { + if (yych <= '0') goto yy349; + if (yych <= '9') goto yy354; + if (yych <= ':') goto yy350; + goto yy199; } -yy1152: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1153; - default: goto yy57; +yy334: + YYDEBUG(334, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy338; + goto yy199; + } else { + if (yych <= '2') goto yy354; + if (yych <= '9') goto yy349; + if (yych <= ':') goto yy338; + goto yy199; + } +yy335: + YYDEBUG(335, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy338; + goto yy199; + } else { + if (yych <= '4') goto yy349; + if (yych <= '9') goto yy348; + if (yych <= ':') goto yy338; + goto yy199; } -yy1153: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy1155; - case 'N': - case 'n': goto yy1154; - default: goto yy57; +yy336: + YYDEBUG(336, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy338; + goto yy199; + } else { + if (yych <= '9') goto yy348; + if (yych <= ':') goto yy338; + goto yy199; } -yy1154: - yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy1160; - default: goto yy57; +yy337: + YYDEBUG(337, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych != '.') goto yy199; + } else { + if (yych <= '9') goto yy263; + if (yych >= ';') goto yy199; } -yy1155: +yy338: + YYDEBUG(338, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy1156; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy339; + if (yych <= '6') goto yy340; + if (yych <= '9') goto yy266; + goto yy57; +yy339: + YYDEBUG(339, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy267; + goto yy223; + } else { + if (yych <= '9') goto yy341; + if (yych <= ':') goto yy267; + goto yy223; } -yy1156: - yych = *++YYCURSOR; - switch (yych) { - case 'I': - case 'i': goto yy1157; - default: goto yy57; +yy340: + YYDEBUG(340, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy267; + goto yy223; + } else { + if (yych <= '0') goto yy229; + if (yych == ':') goto yy267; + goto yy223; } -yy1157: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy1158; - default: goto yy57; +yy341: + YYDEBUG(341, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= ' ') { + if (yych == '\t') goto yy343; + if (yych <= 0x1F) goto yy223; + goto yy343; + } else { + if (yych <= '(') { + if (yych <= '\'') goto yy223; + goto yy343; + } else { + if (yych == '+') goto yy343; + goto yy223; + } + } + } else { + if (yych <= ':') { + if (yych <= '-') goto yy343; + if (yych <= '.') goto yy267; + if (yych <= '9') goto yy223; + goto yy267; + } else { + if (yych <= 'Z') { + if (yych <= '@') goto yy223; + goto yy343; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy343; + goto yy223; + } + } } -yy1158: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy1159; - default: goto yy57; +yy342: + YYDEBUG(342, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; +yy343: + YYDEBUG(343, *YYCURSOR); + if (yych <= '@') { + if (yych <= '\'') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy57; + goto yy342; + } else { + if (yych == ' ') goto yy342; + goto yy57; + } + } else { + if (yych <= '+') { + if (yych <= '(') goto yy234; + if (yych <= '*') goto yy57; + goto yy233; + } else { + if (yych == '-') goto yy233; + goto yy57; + } + } + } else { + if (yych <= 'Z') { + if (yych <= 'G') { + if (yych <= 'A') goto yy344; + if (yych <= 'F') goto yy235; + goto yy232; + } else { + if (yych != 'P') goto yy235; + } + } else { + if (yych <= 'o') { + if (yych <= '`') goto yy57; + if (yych <= 'a') goto yy345; + goto yy236; + } else { + if (yych <= 'p') goto yy345; + if (yych <= 'z') goto yy236; + goto yy57; + } + } } -yy1159: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1149; - default: goto yy57; +yy344: + YYDEBUG(344, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= '.') goto yy286; + if (yych <= '@') goto yy223; + goto yy237; + } + } else { + if (yych <= '`') { + if (yych <= 'M') goto yy346; + if (yych <= 'Z') goto yy237; + goto yy223; + } else { + if (yych == 'm') goto yy347; + if (yych <= 'z') goto yy242; + goto yy223; + } } -yy1160: - yych = *++YYCURSOR; - switch (yych) { - case 'G': - case 'g': goto yy1161; - default: goto yy57; +yy345: + YYDEBUG(345, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy228; + goto yy223; + } else { + if (yych <= '.') goto yy286; + if (yych <= '@') goto yy223; + goto yy237; + } + } else { + if (yych <= '`') { + if (yych <= 'M') goto yy346; + if (yych <= 'Z') goto yy237; + goto yy223; + } else { + if (yych == 'm') goto yy346; + if (yych <= 'z') goto yy237; + goto yy223; + } } -yy1161: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy1162; - default: goto yy57; +yy346: + YYDEBUG(346, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ')') { + if (yych <= '\t') { + if (yych <= 0x00) goto yy278; + if (yych <= 0x08) goto yy223; + goto yy278; + } else { + if (yych == ' ') goto yy278; + if (yych <= '(') goto yy223; + goto yy228; + } + } else { + if (yych <= '@') { + if (yych == '.') goto yy288; + goto yy223; + } else { + if (yych <= 'Z') goto yy238; + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy238; + goto yy223; + } } -yy1162: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1149; - default: goto yy57; +yy347: + YYDEBUG(347, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '-') { + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy278; + if (yych == '\t') goto yy278; + goto yy223; + } else { + if (yych <= '(') { + if (yych <= ' ') goto yy278; + goto yy223; + } else { + if (yych <= ')') goto yy228; + if (yych <= ',') goto yy223; + goto yy244; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '.') goto yy288; + if (yych <= '/') goto yy244; + if (yych <= '@') goto yy223; + goto yy238; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy223; + goto yy244; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy243; + goto yy223; + } + } } -yy1163: - yyaccept = 26; +yy348: + YYDEBUG(348, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'D': - case 'd': goto yy1164; - default: goto yy1118; + if (yych <= '/') { + if (yych == '.') goto yy225; + goto yy199; + } else { + if (yych <= '9') goto yy289; + if (yych <= ':') goto yy225; + goto yy199; } -yy1164: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1165; - default: goto yy57; +yy349: + YYDEBUG(349, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych != '.') goto yy199; + } else { + if (yych <= '9') goto yy289; + if (yych >= ';') goto yy199; } -yy1165: +yy350: + YYDEBUG(350, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy351; + if (yych <= '6') goto yy352; + if (yych <= '9') goto yy224; + goto yy57; +yy351: + YYDEBUG(351, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy225; + goto yy223; + } else { + if (yych <= '9') goto yy353; + if (yych <= ':') goto yy225; + goto yy223; } -yy1166: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1149; - default: goto yy57; +yy352: + YYDEBUG(352, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy225; + goto yy223; + } else { + if (yych <= '0') goto yy229; + if (yych == ':') goto yy225; + goto yy223; } -yy1167: - yych = *++YYCURSOR; - switch (yych) { - case 'U': - case 'u': goto yy1168; - default: goto yy57; +yy353: + YYDEBUG(353, *YYCURSOR); + yyaccept = 7; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= ' ') { + if (yych == '\t') goto yy231; + if (yych <= 0x1F) goto yy223; + goto yy231; + } else { + if (yych <= '(') { + if (yych <= '\'') goto yy223; + goto yy231; + } else { + if (yych == '+') goto yy231; + goto yy223; + } + } + } else { + if (yych <= ':') { + if (yych <= '-') goto yy231; + if (yych <= '.') goto yy225; + if (yych <= '9') goto yy223; + goto yy225; + } else { + if (yych <= 'Z') { + if (yych <= '@') goto yy223; + goto yy231; + } else { + if (yych <= '`') goto yy223; + if (yych <= 'z') goto yy231; + goto yy223; + } + } } -yy1168: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy1149; - default: goto yy57; +yy354: + YYDEBUG(354, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy338; + goto yy199; + } else { + if (yych <= '9') goto yy289; + if (yych <= ':') goto yy338; + goto yy199; } -yy1169: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy1174; - default: goto yy57; +yy355: + YYDEBUG(355, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '/') { + if (yych == '.') goto yy300; + goto yy216; + } else { + if (yych <= '0') goto yy332; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy264; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1170: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy1171; - default: goto yy57; +yy356: + YYDEBUG(356, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '/') { + if (yych == '.') goto yy300; + goto yy216; + } else { + if (yych <= '0') goto yy332; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy264; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1171: - yyaccept = 26; +yy357: + YYDEBUG(357, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'S': - case 's': goto yy1143; - case 'U': - case 'u': goto yy1172; - default: goto yy1118; + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy360; + goto yy361; + } else { + if (yych <= '2') goto yy368; + if (yych <= '9') goto yy369; + goto yy216; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy212; + if (yych <= 'q') goto yy216; + goto yy213; + } else { + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1172: - yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1173; - default: goto yy57; +yy358: + YYDEBUG(358, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych <= '0') goto yy360; + goto yy361; + } else { + if (yych <= '2') goto yy368; + if (yych <= '9') goto yy369; + goto yy216; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy212; + if (yych <= 'q') goto yy216; + goto yy213; + } else { + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1173: - yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1149; - default: goto yy57; +yy359: + YYDEBUG(359, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy216; + if (yych >= '1') goto yy361; + } else { + if (yych <= '2') goto yy209; + if (yych <= '9') goto yy210; + goto yy216; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy212; + if (yych <= 'q') goto yy216; + goto yy213; + } else { + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1174: - yyaccept = 26; +yy360: + YYDEBUG(360, *YYCURSOR); + yyaccept = 6; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'D': - case 'd': goto yy1175; - case 'T': - case 't': goto yy1176; - default: goto yy1118; + if (yych <= '9') { + if (yych <= '/') { + if (yych <= ',') goto yy216; + if (yych <= '-') goto yy362; + if (yych <= '.') goto yy331; + goto yy216; + } else { + if (yych <= '0') goto yy332; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy221; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1175: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1177; - default: goto yy57; +yy361: + YYDEBUG(361, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '/') { + if (yych <= ',') goto yy216; + if (yych <= '-') goto yy362; + if (yych <= '.') goto yy300; + goto yy216; + } else { + if (yych <= '0') goto yy301; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy264; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1176: +yy362: + YYDEBUG(362, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy1149; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(363, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= '/') goto yy364; + if (yych <= '9') goto yy365; +yy364: + YYDEBUG(364, *YYCURSOR); +#line 1510 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("pgtextshort"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->m = timelib_get_month((char **) &ptr); + s->time->d = timelib_get_nr((char **) &ptr, 2); + s->time->y = timelib_get_nr((char **) &ptr, 4); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_PG_TEXT; } -yy1177: +#line 6648 "ext/date/lib/parse_date.c" +yy365: + YYDEBUG(365, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; - } -yy1178: + if (yych <= '/') goto yy364; + if (yych >= ':') goto yy364; + YYDEBUG(366, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy1189; - default: goto yy57; - } -yy1179: + if (yych <= '/') goto yy364; + if (yych >= ':') goto yy364; + YYDEBUG(367, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1184; - default: goto yy57; + goto yy364; +yy368: + YYDEBUG(368, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '/') { + if (yych <= ',') goto yy216; + if (yych <= '-') goto yy362; + if (yych <= '.') goto yy300; + goto yy216; + } else { + if (yych <= '0') goto yy332; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy264; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1180: - yych = *++YYCURSOR; - switch (yych) { - case 'C': - case 'c': goto yy1181; - default: goto yy57; +yy369: + YYDEBUG(369, *YYCURSOR); + yyaccept = 6; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '/') { + if (yych <= ',') goto yy216; + if (yych <= '-') goto yy362; + if (yych <= '.') goto yy300; + goto yy216; + } else { + if (yych <= '0') goto yy332; + if (yych <= '1') goto yy302; + if (yych <= '2') goto yy303; + goto yy297; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy264; + if (yych == 'n') goto yy212; + goto yy216; + } else { + if (yych <= 'r') goto yy213; + if (yych <= 's') goto yy211; + if (yych <= 't') goto yy214; + goto yy216; + } } -yy1181: - yyaccept = 26; +yy370: + YYDEBUG(370, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case 'O': - case 'o': goto yy1182; - case 'S': - case 's': goto yy1143; - default: goto yy1118; + if (yych <= 'B') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'C') goto yy193; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'b') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'c') goto yy371; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1182: - yych = *++YYCURSOR; - switch (yych) { - case 'N': - case 'n': goto yy1183; - default: goto yy57; +yy371: + YYDEBUG(371, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'D') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'E') goto yy202; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'd') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'e') goto yy373; + if (yych <= 'z') goto yy151; + goto yy194; + } + } } -yy1183: +yy372: + YYDEBUG(372, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1149; - default: goto yy57; + if (yybm[0+yych] & 8) { + goto yy149; } -yy1184: - yyaccept = 26; + if (yych <= '/') goto yy196; + if (yych <= '0') goto yy357; + if (yych <= '2') goto yy358; + if (yych <= '3') goto yy359; + goto yy196; +yy373: + YYDEBUG(373, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'U': - case 'u': goto yy1185; - default: goto yy1118; - } -yy1185: - yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy1186; - default: goto yy57; + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'M') goto yy203; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'l') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'm') goto yy374; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1186: - yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1187; - default: goto yy57; +yy374: + YYDEBUG(374, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'A') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'B') goto yy204; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'b') goto yy375; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1187: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1188; - default: goto yy57; +yy375: + YYDEBUG(375, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'E') goto yy205; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'e') goto yy376; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1188: +yy376: + YYDEBUG(376, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; - } -yy1189: - yyaccept = 26; + if (yych == 'R') goto yy206; + if (yych != 'r') goto yy155; +yy377: + YYDEBUG(377, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1119; - case 'D': - case 'd': goto yy1190; - default: goto yy1118; + if (yybm[0+yych] & 16) { + goto yy154; } -yy1190: - yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1191; - default: goto yy57; + if (yych <= '-') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy194; + } else { + if (yych <= ' ') goto yy196; + if (yych <= ',') goto yy194; + } + } else { + if (yych <= '9') { + if (yych == '/') goto yy148; + goto yy196; + } else { + if (yych == '_') goto yy148; + goto yy194; + } } -yy1191: +yy378: + YYDEBUG(378, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1124; - default: goto yy57; + if (yybm[0+yych] & 8) { + goto yy149; } -yy1192: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'E': goto yy1099; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'e': goto yy1193; - default: goto yy4; + goto yy196; +yy379: + YYDEBUG(379, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy142; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 't') goto yy380; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1193: - yyaccept = 0; +yy380: + YYDEBUG(380, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'V': goto yy1100; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'v': goto yy1194; - default: goto yy4; + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'O') goto yy143; + } + } else { + if (yych <= 'n') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'o') goto yy381; + if (yych <= 'z') goto yy143; + goto yy194; + } + } } -yy1194: +yy381: + YYDEBUG(381, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'B') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'A') goto yy144; + } + } else { + if (yych <= 'a') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'b') goto yy382; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy382: + YYDEBUG(382, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy145; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'e') goto yy383; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy383: + YYDEBUG(383, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Q') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'R') goto yy206; + if (yych == 'r') goto yy206; + goto yy4; + } +yy384: + YYDEBUG(384, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'I': goto yy1101; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'i': goto yy1195; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy380; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 't') goto yy385; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1195: - yyaccept = 0; +yy385: + YYDEBUG(385, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'O': goto yy1102; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'o': goto yy1196; - default: goto yy4; + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'N') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'O') goto yy381; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'n') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'o') goto yy386; + if (yych <= 'z') goto yy151; + goto yy194; + } + } } -yy1196: +yy386: + YYDEBUG(386, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'U': goto yy1103; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'u': goto yy1197; - default: goto yy4; + if (yych <= 'A') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'B') goto yy382; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'b') goto yy387; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1197: - yych = *++YYCURSOR; - switch (yych) { - case 'S': goto yy1104; - case 's': goto yy1198; - default: goto yy155; +yy387: + YYDEBUG(387, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy383; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'e') goto yy388; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1198: - yych = *++YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy1105; - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy57; +yy388: + YYDEBUG(388, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'Q') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'R') goto yy206; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'r') goto yy377; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1199: +yy389: + YYDEBUG(389, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'G': - case 'g': goto yy1213; - default: goto yy4; + if (yych <= 'G') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'F') goto yy142; + goto yy397; + } + } else { + if (yych <= 'f') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'g') goto yy397; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1200: +yy390: + YYDEBUG(390, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'E': - case 'e': goto yy1201; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy142; + goto yy394; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'r') goto yy394; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1201: +yy391: + YYDEBUG(391, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'V': - case 'v': goto yy1202; - default: goto yy4; + if (yych <= 'O') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'N') goto yy142; + } + } else { + if (yych <= 'n') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'o') goto yy392; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy392: + YYDEBUG(392, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= '@') { + if (yych == ')') goto yy140; + } else { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy393; + if (yych <= 'z') goto yy143; + } +yy393: + YYDEBUG(393, *YYCURSOR); +#line 1566 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("ago"); + TIMELIB_INIT; + s->time->relative.y = 0 - s->time->relative.y; + s->time->relative.m = 0 - s->time->relative.m; + s->time->relative.d = 0 - s->time->relative.d; + s->time->relative.h = 0 - s->time->relative.h; + s->time->relative.i = 0 - s->time->relative.i; + s->time->relative.s = 0 - s->time->relative.s; + s->time->relative.weekday = 0 - s->time->relative.weekday; + if (s->time->relative.weekday == 0) { + s->time->relative.weekday = -7; + } + if (s->time->relative.have_special_relative && s->time->relative.special.type == TIMELIB_SPECIAL_WEEKDAY) { + s->time->relative.special.amount = 0 - s->time->relative.special.amount; + } + TIMELIB_DEINIT; + return TIMELIB_AGO; + } +#line 7306 "ext/date/lib/parse_date.c" +yy394: + YYDEBUG(394, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'I') goto yy143; + } + } else { + if (yych <= 'h') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'i') goto yy395; + if (yych <= 'z') goto yy143; + goto yy194; + } + } } -yy1202: +yy395: + YYDEBUG(395, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'E': - case 'e': goto yy1203; - default: goto yy4; + if (yych <= 'L') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'K') goto yy144; + } + } else { + if (yych <= 'k') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'l') goto yy396; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1203: +yy396: + YYDEBUG(396, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy194; + } else { + if (yych <= ' ') goto yy196; + if (yych == ')') goto yy140; + goto yy194; + } + } else { + if (yych <= '@') { + if (yych == '/') goto yy194; + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy194; + if (yych <= 'z') goto yy145; + goto yy194; + } + } +yy397: + YYDEBUG(397, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'U') goto yy143; + } + } else { + if (yych <= 't') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'u') goto yy398; + if (yych <= 'z') goto yy143; + goto yy194; + } + } + } +yy398: + YYDEBUG(398, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'N': - case 'n': goto yy1204; - default: goto yy4; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'R') goto yy144; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 's') goto yy399; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy399: + YYDEBUG(399, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy145; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 't') goto yy400; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy400: + YYDEBUG(400, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '.') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy196; + } else { + if (yych <= '/') goto yy194; + if (yych <= '9') goto yy196; + goto yy194; + } + } +yy401: + YYDEBUG(401, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'F') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'G') goto yy397; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'f') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'g') goto yy408; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy402: + YYDEBUG(402, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy394; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'r') goto yy405; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy403: + YYDEBUG(403, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'O') goto yy392; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'n') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'o') goto yy404; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy404: + YYDEBUG(404, *YYCURSOR); + yyaccept = 9; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy393; + } else { + if (yych == '.') goto yy393; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy393; + if (yych <= 'Z') goto yy143; + goto yy393; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy393; + if (yych <= 'z') goto yy151; + goto yy393; + } + } +yy405: + YYDEBUG(405, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'H') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'I') goto yy395; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'h') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'i') goto yy406; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy406: + YYDEBUG(406, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'K') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'L') goto yy396; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'k') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'l') goto yy407; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy407: + YYDEBUG(407, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy194; + goto yy196; + } else { + if (yych <= ')') { + if (yych <= '(') goto yy194; + goto yy140; + } else { + if (yych <= ',') goto yy194; + if (yych <= '-') goto yy378; + goto yy196; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '/') goto yy148; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy194; + goto yy145; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy194; + goto yy148; + } else { + if (yych <= '`') goto yy194; + if (yych <= 'z') goto yy153; + goto yy194; + } + } } -yy1204: +yy408: + YYDEBUG(408, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'T') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'U') goto yy398; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 't') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'u') goto yy409; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy409: + YYDEBUG(409, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'T': - case 't': goto yy1205; - default: goto yy4; + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy399; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 's') goto yy410; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1205: - yych = *++YYCURSOR; - switch (yych) { - case 'H': - case 'h': goto yy1206; - default: goto yy57; +yy410: + YYDEBUG(410, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy400; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 't') goto yy411; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1206: - yych = *++YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy1207; - default: goto yy57; +yy411: + YYDEBUG(411, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; } -yy1207: - ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); - yych = *YYCURSOR; -yy1208: - switch (yych) { - case '\t': - case ' ': goto yy1207; - case 'D': - case 'd': goto yy1110; - case 'F': - case 'f': goto yy1111; - case 'H': - case 'h': goto yy1109; - case 'M': - case 'm': goto yy1108; - case 'S': - case 's': goto yy1107; - case 'T': - case 't': goto yy1114; - case 'W': - case 'w': goto yy1209; - case 'Y': - case 'y': goto yy1112; - default: goto yy57; + if (yych <= ',') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy194; + } else { + if (yych <= ' ') goto yy196; + if (yych == ')') goto yy140; + goto yy194; + } + } else { + if (yych <= '/') { + if (yych <= '-') goto yy378; + if (yych <= '.') goto yy196; + goto yy148; + } else { + if (yych <= '9') goto yy196; + if (yych == '_') goto yy148; + goto yy194; + } } -yy1209: +yy412: + YYDEBUG(412, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1210; - default: goto yy57; + if (yych <= 'N') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'L') goto yy419; + if (yych <= 'M') goto yy142; + goto yy418; + } + } else { + if (yych <= 'l') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'k') goto yy142; + goto yy419; + } else { + if (yych == 'n') goto yy418; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1210: +yy413: + YYDEBUG(413, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1135; - case 'E': - case 'e': goto yy1211; - default: goto yy57; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy142; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'n') goto yy414; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1211: - yych = *++YYCURSOR; - switch (yych) { - case 'K': - case 'k': goto yy1212; - default: goto yy57; +yy414: + YYDEBUG(414, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'U') goto yy143; + } + } else { + if (yych <= 't') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'u') goto yy415; + if (yych <= 'z') goto yy143; + goto yy194; + } + } } -yy1212: +yy415: + YYDEBUG(415, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1144; - case 'S': - case 's': goto yy1143; - default: goto yy57; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy144; + goto yy4; + } else { + if (yych <= 'a') goto yy416; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1213: +yy416: + YYDEBUG(416, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'H': - case 'h': goto yy1214; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy145; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'r') goto yy417; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1214: +yy417: + YYDEBUG(417, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'T': - case 't': goto yy1215; - default: goto yy4; + if (yych <= 'X') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Y') goto yy206; + if (yych == 'y') goto yy206; + goto yy4; + } +yy418: + YYDEBUG(418, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych == 'E') goto yy420; + goto yy143; + } + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'e') goto yy420; + if (yych <= 'z') goto yy143; + goto yy194; + } + } } -yy1215: +yy419: + YYDEBUG(419, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'Y') goto yy143; + } + } else { + if (yych <= 'x') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'y') goto yy420; + if (yych <= 'z') goto yy143; + goto yy194; + } + } + } +yy420: + YYDEBUG(420, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy194; + } else { + if (yych <= ' ') goto yy196; + if (yych == ')') goto yy140; + goto yy194; + } + } else { + if (yych <= '@') { + if (yych == '/') goto yy194; + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy194; + if (yych <= 'z') goto yy144; + goto yy194; + } + } +yy421: + YYDEBUG(421, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1207; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'H': - case 'h': goto yy1216; - default: goto yy4; + if (yych <= 'M') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych <= '/') goto yy148; + goto yy4; + } else { + if (yych == 'L') goto yy419; + goto yy142; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'N') goto yy418; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'm') { + if (yych == 'l') goto yy428; + goto yy147; + } else { + if (yych <= 'n') goto yy427; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1216: +yy422: + YYDEBUG(422, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1207; - case ')': goto yy140; - default: goto yy4; + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy414; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'n') goto yy423; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1217: +yy423: + YYDEBUG(423, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'T') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'U') goto yy415; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 't') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'u') goto yy424; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy424: + YYDEBUG(424, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'G': goto yy1213; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'g': goto yy1225; - default: goto yy4; + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy416; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy425; + if (yych <= 'z') goto yy152; + goto yy4; + } } -yy1218: +yy425: + YYDEBUG(425, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'E': goto yy1201; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'e': goto yy1219; - default: goto yy4; + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy417; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'r') goto yy426; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy426: + YYDEBUG(426, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'Y') goto yy206; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'y') goto yy377; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy427: + YYDEBUG(427, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'D') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'E') goto yy420; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'd') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'e') goto yy429; + if (yych <= 'z') goto yy151; + goto yy194; + } + } } -yy1219: +yy428: + YYDEBUG(428, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'X') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'Y') goto yy420; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'x') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'y') goto yy429; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy429: + YYDEBUG(429, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy194; + goto yy196; + } else { + if (yych <= ')') { + if (yych <= '(') goto yy194; + goto yy140; + } else { + if (yych <= ',') goto yy194; + if (yych <= '-') goto yy378; + goto yy196; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '/') goto yy148; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy194; + goto yy144; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy194; + goto yy148; + } else { + if (yych <= '`') goto yy194; + if (yych <= 'z') goto yy152; + goto yy194; + } + } + } +yy430: + YYDEBUG(430, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'V': goto yy1202; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'v': goto yy1220; - default: goto yy4; + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy4; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy196; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'Z') { + if (yych >= 'J') goto yy142; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy142; + goto yy4; + } + } } -yy1220: +yy431: + YYDEBUG(431, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'E': goto yy1203; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'e': goto yy1221; - default: goto yy4; + if (yych <= ',') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy4; + } else { + if (yych <= ' ') goto yy196; + if (yych == ')') goto yy140; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych == '/') goto yy4; + if (yych <= '9') goto yy196; + goto yy4; + } else { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1221: +yy432: + YYDEBUG(432, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'N': goto yy1204; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'n': goto yy1222; - default: goto yy4; + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy4; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy196; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'Z') { + if (yych >= 'J') goto yy142; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy142; + goto yy4; + } + } } -yy1222: + YYDEBUG(433, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'T': goto yy1205; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 't': goto yy1223; - default: goto yy4; + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy4; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy196; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy4; + goto yy143; + } else { + if (yych <= 'Z') { + if (yych >= 'J') goto yy143; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy143; + goto yy4; + } + } } -yy1223: - yych = *++YYCURSOR; - switch (yych) { - case 'H': goto yy1206; - case 'h': goto yy1224; - default: goto yy155; + YYDEBUG(434, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy4; + } else { + if (yych <= ' ') goto yy196; + if (yych == ')') goto yy140; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych == '/') goto yy4; + if (yych <= '9') goto yy196; + goto yy4; + } else { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1224: - yych = *++YYCURSOR; - switch (yych) { - case '\t': - case ' ': goto yy1207; - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy57; +yy435: + YYDEBUG(435, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy196; + goto yy4; + } else { + if (yych <= ' ') goto yy196; + if (yych == ')') goto yy140; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych == '/') goto yy4; + if (yych <= '9') goto yy196; + goto yy4; + } else { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1225: +yy436: + YYDEBUG(436, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'H': goto yy1214; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'h': goto yy1226; - default: goto yy4; + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy4; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy196; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'Z') { + if (yych <= 'I') goto yy431; + goto yy142; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy142; + goto yy4; + } + } } -yy1226: +yy437: + YYDEBUG(437, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'T': goto yy1215; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 't': goto yy1227; - default: goto yy4; + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '9') { + if (yych <= '/') goto yy4; + goto yy457; + } else { + if (yych <= ':') goto yy163; + if (yych <= 'C') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy4; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy4; + goto yy61; + } else { + if (yych <= 'R') goto yy4; + if (yych <= 'T') goto yy61; + goto yy4; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy4; + if (yych <= 'Y') goto yy61; + goto yy4; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy4; + } else { + if (yych == 'g') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1227: +yy438: + YYDEBUG(438, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1207; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'H': goto yy1216; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'h': goto yy1228; - default: goto yy4; + if (yych <= 'T') { + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '4') { + if (yych <= '/') goto yy4; + goto yy457; + } else { + if (yych <= '5') goto yy442; + if (yych <= '9') goto yy443; + goto yy163; + } + } + } else { + if (yych <= 'G') { + if (yych <= 'D') { + if (yych <= 'C') goto yy4; + goto yy61; + } else { + if (yych == 'F') goto yy61; + goto yy4; + } + } else { + if (yych <= 'L') { + if (yych <= 'H') goto yy61; + goto yy4; + } else { + if (yych <= 'M') goto yy61; + if (yych <= 'R') goto yy4; + goto yy61; + } + } + } + } else { + if (yych <= 'g') { + if (yych <= 'Y') { + if (yych == 'W') goto yy61; + if (yych <= 'X') goto yy4; + goto yy61; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy4; + goto yy61; + } else { + if (yych == 'f') goto yy61; + goto yy4; + } + } + } else { + if (yych <= 't') { + if (yych <= 'l') { + if (yych <= 'h') goto yy61; + goto yy4; + } else { + if (yych <= 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1228: +yy439: + YYDEBUG(439, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1207; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy4; + if (yych <= 'T') { + if (yych <= 'C') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '5') { + if (yych <= '/') goto yy4; + goto yy442; + } else { + if (yych <= '9') goto yy443; + if (yych <= ':') goto yy163; + goto yy4; + } + } + } else { + if (yych <= 'G') { + if (yych == 'E') goto yy4; + if (yych <= 'F') goto yy61; + goto yy4; + } else { + if (yych <= 'L') { + if (yych <= 'H') goto yy61; + goto yy4; + } else { + if (yych <= 'M') goto yy61; + if (yych <= 'R') goto yy4; + goto yy61; + } + } + } + } else { + if (yych <= 'g') { + if (yych <= 'Y') { + if (yych == 'W') goto yy61; + if (yych <= 'X') goto yy4; + goto yy61; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy4; + goto yy61; + } else { + if (yych == 'f') goto yy61; + goto yy4; + } + } + } else { + if (yych <= 't') { + if (yych <= 'l') { + if (yych <= 'h') goto yy61; + goto yy4; + } else { + if (yych <= 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1229: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'C': - case 'c': goto yy1245; - case 'P': - case 'p': goto yy1247; - case 'V': - case 'v': goto yy1246; - default: goto yy4; +yy440: + YYDEBUG(440, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(441, *YYCURSOR); + if (yybm[0+yych] & 4) { + goto yy58; } -yy1230: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'T': - case 't': goto yy1240; - default: goto yy4; + if (yych <= ',') { + if (yych == '+') goto yy440; + goto yy57; + } else { + if (yych <= '-') goto yy440; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy55; + goto yy57; } -yy1231: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'y': - case 'z': goto yy142; - case 'X': - case 'x': goto yy1237; - default: goto yy4; +yy442: + YYDEBUG(442, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy456; + if (yych <= 'C') goto yy4; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy4; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy4; + goto yy61; + } else { + if (yych <= 'R') goto yy4; + if (yych <= 'T') goto yy61; + goto yy4; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy4; + if (yych <= 'Y') goto yy61; + goto yy4; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy4; + } else { + if (yych == 'g') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } + } +yy443: + YYDEBUG(443, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy444; + if (yych <= 'C') goto yy4; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy4; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy4; + goto yy61; + } else { + if (yych <= 'R') goto yy4; + if (yych <= 'T') goto yy61; + goto yy4; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy4; + if (yych <= 'Y') goto yy61; + goto yy4; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy4; + } else { + if (yych == 'g') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1232: +yy444: + YYDEBUG(444, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'N': - case 'n': goto yy1233; - default: goto yy4; - } -yy1233: + if (yych <= '/') goto yy61; + if (yych >= ':') goto yy61; +yy445: + YYDEBUG(445, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'D': - case 'd': goto yy1234; - default: goto yy167; + if (yybm[0+yych] & 2) { + goto yy55; } -yy1234: + if (yych != '-') goto yy61; +yy446: + YYDEBUG(446, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1235; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; - } -yy1235: + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy447; + if (yych <= '1') goto yy448; + goto yy57; +yy447: + YYDEBUG(447, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy145; - case 'Y': - case 'y': goto yy1236; - default: goto yy4; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy449; + goto yy57; +yy448: + YYDEBUG(448, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '3') goto yy57; +yy449: + YYDEBUG(449, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '-') goto yy57; + YYDEBUG(450, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy451; + if (yych <= '2') goto yy452; + if (yych <= '3') goto yy453; + goto yy57; +yy451: + YYDEBUG(451, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy454; + goto yy57; +yy452: + YYDEBUG(452, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy454; + goto yy57; +yy453: + YYDEBUG(453, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '2') goto yy57; +yy454: + YYDEBUG(454, *YYCURSOR); + ++YYCURSOR; +yy455: + YYDEBUG(455, *YYCURSOR); +#line 1280 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("iso8601date4 | iso8601date2 | iso8601dateslash | dateslash"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_unsigned_nr((char **) &ptr, 4); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = timelib_get_nr((char **) &ptr, 2); + TIMELIB_DEINIT; + return TIMELIB_ISO_DATE; } -yy1236: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - default: goto yy167; +#line 9067 "ext/date/lib/parse_date.c" +yy456: + YYDEBUG(456, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy445; + if (yych <= 'C') goto yy4; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy4; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy4; + goto yy61; + } else { + if (yych <= 'R') goto yy4; + if (yych <= 'T') goto yy61; + goto yy4; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy4; + if (yych <= 'Y') goto yy61; + goto yy4; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy4; + } else { + if (yych == 'g') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1237: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1238; - default: goto yy4; +yy457: + YYDEBUG(457, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'T') { + if (yych <= 'C') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '5') { + if (yych <= '/') goto yy4; + } else { + if (yych <= '9') goto yy456; + if (yych <= ':') goto yy163; + goto yy4; + } + } + } else { + if (yych <= 'G') { + if (yych == 'E') goto yy4; + if (yych <= 'F') goto yy61; + goto yy4; + } else { + if (yych <= 'L') { + if (yych <= 'H') goto yy61; + goto yy4; + } else { + if (yych <= 'M') goto yy61; + if (yych <= 'R') goto yy4; + goto yy61; + } + } + } + } else { + if (yych <= 'g') { + if (yych <= 'Y') { + if (yych == 'W') goto yy61; + if (yych <= 'X') goto yy4; + goto yy61; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy4; + goto yy61; + } else { + if (yych == 'f') goto yy61; + goto yy4; + } + } + } else { + if (yych <= 't') { + if (yych <= 'l') { + if (yych <= 'h') goto yy61; + goto yy4; + } else { + if (yych <= 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1238: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'H': - case 'h': goto yy1239; - default: goto yy4; + YYDEBUG(458, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych <= '/') goto yy4; + if (yych <= '9') goto yy459; + if (yych <= 'C') goto yy4; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy4; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy4; + goto yy61; + } else { + if (yych <= 'R') goto yy4; + if (yych <= 'T') goto yy61; + goto yy4; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy4; + if (yych <= 'Y') goto yy61; + goto yy4; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy4; + } else { + if (yych == 'g') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1239: +yy459: + YYDEBUG(459, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1207; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; + if (yybm[0+yych] & 2) { + goto yy55; + } + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy4; + goto yy61; + } else { + if (yych == '-') goto yy446; + if (yych <= 'C') goto yy4; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy4; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy4; + goto yy61; + } else { + if (yych <= 'R') goto yy4; + if (yych <= 'T') goto yy61; + goto yy4; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy4; + if (yych <= 'Y') goto yy61; + goto yy4; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy4; + } else { + if (yych == 'g') goto yy4; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy4; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy4; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy4; + } + } + } } -yy1240: +yy460: + YYDEBUG(460, *YYCURSOR); yych = *++YYCURSOR; + if (yych <= '/') goto yy462; + if (yych <= '0') goto yy736; + if (yych <= '1') goto yy737; + if (yych <= '9') goto yy738; + goto yy462; +yy461: + YYDEBUG(461, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); + yych = *YYCURSOR; +yy462: + YYDEBUG(462, *YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '\t': + case ' ': goto yy461; + case '-': + case '.': goto yy577; case 'A': - case 'B': - case 'C': + case 'a': goto yy480; case 'D': - case 'E': + case 'd': goto yy466; case 'F': - case 'G': + case 'f': goto yy467; case 'H': - case 'I': + case 'h': goto yy64; + case 'I': goto yy475; case 'J': - case 'K': - case 'L': + case 'j': goto yy479; case 'M': + case 'm': goto yy465; case 'N': + case 'n': goto yy482; case 'O': + case 'o': goto yy481; case 'P': - case 'Q': - case 'R': + case 'p': goto yy484; case 'S': + case 's': goto yy463; case 'T': - case 'V': + case 't': goto yy69; + case 'V': goto yy477; case 'W': - case 'X': + case 'w': goto yy68; + case 'X': goto yy478; case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'U': - case 'u': goto yy1241; - default: goto yy167; + case 'y': goto yy67; + default: goto yy57; } -yy1241: +yy463: + YYDEBUG(463, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'R': - case 'r': goto yy1242; - default: goto yy4; + if (yych <= 'U') { + if (yych <= 'D') { + if (yych == 'A') goto yy127; + goto yy57; + } else { + if (yych <= 'E') goto yy1049; + if (yych <= 'T') goto yy57; + goto yy126; + } + } else { + if (yych <= 'd') { + if (yych == 'a') goto yy127; + goto yy57; + } else { + if (yych <= 'e') goto yy1049; + if (yych == 'u') goto yy126; + goto yy57; + } } -yy1242: +yy464: + YYDEBUG(464, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'D': - case 'd': goto yy1243; - default: goto yy4; - } -yy1243: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1244; - default: goto yy4; + if (yych <= '`') { + if (yych <= 'D') { + if (yych == 'A') goto yy127; + goto yy57; + } else { + if (yych <= 'E') goto yy1049; + if (yych == 'U') goto yy126; + goto yy57; + } + } else { + if (yych <= 'e') { + if (yych <= 'a') goto yy127; + if (yych <= 'd') goto yy57; + goto yy1049; + } else { + if (yych <= 's') goto yy57; + if (yych <= 't') goto yy729; + if (yych <= 'u') goto yy126; + goto yy57; + } } -yy1244: +yy465: + YYDEBUG(465, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy173; - default: goto yy57; + if (yych <= 'O') { + if (yych <= 'H') { + if (yych == 'A') goto yy592; + goto yy57; + } else { + if (yych <= 'I') goto yy118; + if (yych <= 'N') goto yy57; + goto yy117; + } + } else { + if (yych <= 'h') { + if (yych == 'a') goto yy592; + goto yy57; + } else { + if (yych <= 'i') goto yy118; + if (yych == 'o') goto yy117; + goto yy57; + } } -yy1245: +yy466: + YYDEBUG(466, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'O': - case 'o': goto yy1256; - default: goto yy4; + if (yych <= 'E') { + if (yych == 'A') goto yy114; + if (yych <= 'D') goto yy57; + goto yy579; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy114; + } else { + if (yych == 'e') goto yy579; + goto yy57; + } } -yy1246: +yy467: + YYDEBUG(467, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'E': - case 'e': goto yy1253; - default: goto yy4; + if (yych <= 'R') { + if (yych <= 'N') { + if (yych == 'E') goto yy595; + goto yy57; + } else { + if (yych <= 'O') goto yy99; + if (yych <= 'Q') goto yy57; + goto yy98; + } + } else { + if (yych <= 'n') { + if (yych == 'e') goto yy595; + goto yy57; + } else { + if (yych <= 'o') goto yy99; + if (yych == 'r') goto yy98; + goto yy57; + } } -yy1247: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); +yy468: + YYDEBUG(468, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'H') goto yy70; + if (yych <= 'T') goto yy57; + goto yy71; + } else { + if (yych <= 'h') { + if (yych <= 'g') goto yy57; + goto yy1048; + } else { + if (yych == 'u') goto yy71; + goto yy57; + } + } +yy469: + YYDEBUG(469, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy742; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy741; + goto yy61; +yy470: + YYDEBUG(470, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'c') { + if (yych == 'O') goto yy530; + goto yy57; + } else { + if (yych <= 'd') goto yy729; + if (yych == 'o') goto yy530; + goto yy57; + } +yy471: + YYDEBUG(471, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy729; + goto yy57; +yy472: + YYDEBUG(472, *YYCURSOR); + yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case '\t': - case ' ': - case '.': case '0': case '1': - case '2': - case '3': + case '2': goto yy666; + case '3': goto yy668; case '4': case '5': case '6': case '7': case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; + case '9': goto yy669; case 'A': - case 'B': - case 'C': + case 'a': goto yy673; case 'D': - case 'E': + case 'd': goto yy677; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy671; case 'J': - case 'K': - case 'L': + case 'j': goto yy670; case 'M': + case 'm': goto yy672; case 'N': + case 'n': goto yy676; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy675; case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1248; - default: goto yy194; + case 's': goto yy674; + default: goto yy57; } -yy1248: - yyaccept = 5; - yych = *(YYMARKER = ++YYCURSOR); +yy473: + YYDEBUG(473, *YYCURSOR); + yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': + case '0': goto yy616; + case '1': goto yy617; case '2': case '3': case '4': @@ -26454,12809 +9569,15179 @@ static int scan(Scanner *s) case '6': case '7': case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; + case '9': goto yy618; case 'A': - case 'B': - case 'C': + case 'a': goto yy622; case 'D': + case 'd': goto yy626; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy620; case 'J': - case 'K': - case 'L': + case 'j': goto yy619; case 'M': + case 'm': goto yy621; case 'N': + case 'n': goto yy625; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy624; case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'E': - case 'e': goto yy1249; - default: goto yy194; + case 's': goto yy623; + default: goto yy578; + } +yy474: + YYDEBUG(474, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '1') { + if (yych <= '/') goto yy578; + if (yych <= '0') goto yy568; + goto yy569; + } else { + if (yych <= '5') goto yy570; + if (yych <= '9') goto yy571; + goto yy578; + } +yy475: + YYDEBUG(475, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '.') goto yy532; + } + } else { + if (yych <= 'U') { + if (yych <= '9') goto yy534; + if (yych == 'I') goto yy567; + } else { + if (yych == 'W') goto yy476; + if (yych <= 'X') goto yy540; + } + } +yy476: + YYDEBUG(476, *YYCURSOR); +#line 1409 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("datenoyearrev"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->d = timelib_get_nr((char **) &ptr, 2); + timelib_skip_day_suffix((char **) &ptr); + s->time->m = timelib_get_month((char **) &ptr); + TIMELIB_DEINIT; + return TIMELIB_DATE_TEXT; + } +#line 9638 "ext/date/lib/parse_date.c" +yy477: + YYDEBUG(477, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '9') { + if (yych <= '.') goto yy532; + if (yych <= '/') goto yy476; + goto yy534; + } else { + if (yych == 'I') goto yy565; + goto yy476; + } + } +yy478: + YYDEBUG(478, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '9') { + if (yych <= '.') goto yy532; + if (yych <= '/') goto yy476; + goto yy534; + } else { + if (yych == 'I') goto yy564; + goto yy476; + } + } +yy479: + YYDEBUG(479, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'A') goto yy557; + if (yych <= 'T') goto yy57; + goto yy556; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy557; + } else { + if (yych == 'u') goto yy556; + goto yy57; + } + } +yy480: + YYDEBUG(480, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= 'L') { + if (yych == '.') goto yy485; + goto yy57; + } else { + if (yych <= 'M') goto yy486; + if (yych == 'P') goto yy550; + goto yy57; + } + } else { + if (yych <= 'o') { + if (yych <= 'U') goto yy549; + if (yych == 'm') goto yy486; + goto yy57; + } else { + if (yych <= 'p') goto yy550; + if (yych == 'u') goto yy549; + goto yy57; + } } -yy1249: +yy481: + YYDEBUG(481, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'M': - case 'm': goto yy1250; - default: goto yy4; + if (yych == 'C') goto yy544; + if (yych == 'c') goto yy544; + goto yy57; +yy482: + YYDEBUG(482, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy530; + if (yych == 'o') goto yy530; + goto yy57; +yy483: + YYDEBUG(483, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy490; + if (yych <= '9') goto yy492; + goto yy57; +yy484: + YYDEBUG(484, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych != '.') goto yy57; + } else { + if (yych <= 'M') goto yy486; + if (yych == 'm') goto yy486; + goto yy57; } -yy1250: - yyaccept = 0; +yy485: + YYDEBUG(485, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy486; + if (yych != 'm') goto yy57; +yy486: + YYDEBUG(486, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy488; + if (yych == '\t') goto yy488; + goto yy57; + } else { + if (yych <= ' ') goto yy488; + if (yych != '.') goto yy57; + } + YYDEBUG(487, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '\t') { + if (yych <= 0x00) goto yy488; + if (yych <= 0x08) goto yy57; + } else { + if (yych != ' ') goto yy57; + } +yy488: + YYDEBUG(488, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(489, *YYCURSOR); +#line 1136 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("timetiny12 | timeshort12 | timelong12"); + TIMELIB_INIT; + TIMELIB_HAVE_TIME(); + s->time->h = timelib_get_nr((char **) &ptr, 2); + if (*ptr == ':' || *ptr == '.') { + s->time->i = timelib_get_nr((char **) &ptr, 2); + if (*ptr == ':' || *ptr == '.') { + s->time->s = timelib_get_nr((char **) &ptr, 2); + } + } + s->time->h += timelib_meridian((char **) &ptr, s->time->h); + TIMELIB_DEINIT; + return TIMELIB_TIME12; + } +#line 9795 "ext/date/lib/parse_date.c" +yy490: + YYDEBUG(490, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'B': - case 'b': goto yy1251; - default: goto yy4; + if (yych <= '/') { + if (yych == '.') goto yy493; + } else { + if (yych <= '9') goto yy507; + if (yych <= ':') goto yy493; } -yy1251: +yy491: + YYDEBUG(491, *YYCURSOR); +#line 1173 "ext/date/lib/parse_date.re" + { + int tz_not_found; + DEBUG_OUTPUT("timeshort24 | timelong24 | iso8601long"); + TIMELIB_INIT; + TIMELIB_HAVE_TIME(); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + if (*ptr == ':' || *ptr == '.') { + s->time->s = timelib_get_nr((char **) &ptr, 2); + + if (*ptr == '.') { + s->time->f = timelib_get_frac_nr((char **) &ptr, 8); + } + } + + if (*ptr != '\0') { + s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); + if (tz_not_found) { + add_error(s, "The timezone could not be found in the database"); + } + } + TIMELIB_DEINIT; + return TIMELIB_TIME24_WITH_ZONE; + } +#line 9833 "ext/date/lib/parse_date.c" +yy492: + YYDEBUG(492, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy493; + if (yych != ':') goto yy491; +yy493: + YYDEBUG(493, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'E': - case 'e': goto yy1252; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy494; + if (yych <= '6') goto yy495; + if (yych <= '9') goto yy496; + goto yy57; +yy494: + YYDEBUG(494, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy500; + goto yy491; +yy495: + YYDEBUG(495, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych == '0') goto yy500; + goto yy491; +yy496: + YYDEBUG(496, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych != '.') goto yy491; +yy497: + YYDEBUG(497, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy498: + YYDEBUG(498, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(499, *YYCURSOR); + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy498; + goto yy491; +yy500: + YYDEBUG(500, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych <= 0x1F) { + if (yych != '\t') goto yy491; + } else { + if (yych <= ' ') goto yy501; + if (yych == '.') goto yy497; + goto yy491; + } + } else { + if (yych <= '`') { + if (yych <= 'A') goto yy503; + if (yych == 'P') goto yy503; + goto yy491; + } else { + if (yych <= 'a') goto yy503; + if (yych == 'p') goto yy503; + goto yy491; + } } -yy1252: +yy501: + YYDEBUG(501, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; + YYDEBUG(502, *YYCURSOR); + if (yych <= 'A') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy501; + goto yy57; + } else { + if (yych <= ' ') goto yy501; + if (yych <= '@') goto yy57; + } + } else { + if (yych <= '`') { + if (yych != 'P') goto yy57; + } else { + if (yych <= 'a') goto yy503; + if (yych != 'p') goto yy57; + } + } +yy503: + YYDEBUG(503, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy206; - default: goto yy57; + if (yych <= 'L') { + if (yych != '.') goto yy57; + } else { + if (yych <= 'M') goto yy505; + if (yych == 'm') goto yy505; + goto yy57; } -yy1253: + YYDEBUG(504, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'N': - case 'n': goto yy1254; - default: goto yy4; + if (yych == 'M') goto yy505; + if (yych != 'm') goto yy57; +yy505: + YYDEBUG(505, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy488; + if (yych == '\t') goto yy488; + goto yy57; + } else { + if (yych <= ' ') goto yy488; + if (yych != '.') goto yy57; } -yy1254: + YYDEBUG(506, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '\t') { + if (yych <= 0x00) goto yy488; + if (yych <= 0x08) goto yy57; + goto yy488; + } else { + if (yych == ' ') goto yy488; + goto yy57; + } +yy507: + YYDEBUG(507, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy508; + if (yych <= 0x1F) goto yy491; + } else { + if (yych == '.') goto yy493; + if (yych <= '9') goto yy491; + goto yy511; + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy510; + if (yych <= 'O') goto yy491; + goto yy510; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy491; + goto yy510; + } else { + if (yych == 'p') goto yy510; + goto yy491; + } + } + } +yy508: + YYDEBUG(508, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; + YYDEBUG(509, *YYCURSOR); + if (yych <= 'A') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy508; + goto yy57; + } else { + if (yych <= ' ') goto yy508; + if (yych <= '@') goto yy57; + } + } else { + if (yych <= '`') { + if (yych != 'P') goto yy57; + } else { + if (yych <= 'a') goto yy510; + if (yych != 'p') goto yy57; + } + } +yy510: + YYDEBUG(510, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'T': - case 't': goto yy1255; - default: goto yy4; + if (yych <= 'L') { + if (yych == '.') goto yy527; + goto yy57; + } else { + if (yych <= 'M') goto yy528; + if (yych == 'm') goto yy528; + goto yy57; } -yy1255: - yyaccept = 0; +yy511: + YYDEBUG(511, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy512; + if (yych <= '6') goto yy513; + if (yych <= '9') goto yy496; + goto yy57; +yy512: + YYDEBUG(512, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'H': - case 'h': goto yy1206; - default: goto yy4; + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy514; + goto yy491; +yy513: + YYDEBUG(513, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych != '0') goto yy491; +yy514: + YYDEBUG(514, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy501; + if (yych <= 0x1F) goto yy491; + goto yy501; + } else { + if (yych == '.') goto yy515; + if (yych <= '9') goto yy491; + goto yy516; + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy503; + if (yych <= 'O') goto yy491; + goto yy503; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy491; + goto yy503; + } else { + if (yych == 'p') goto yy503; + goto yy491; + } + } } -yy1256: +yy515: + YYDEBUG(515, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'N': - case 'n': goto yy1257; - default: goto yy4; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy525; + goto yy57; +yy516: + YYDEBUG(516, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy517: + YYDEBUG(517, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; + YYDEBUG(518, *YYCURSOR); + if (yych <= 'O') { + if (yych <= '9') { + if (yych <= '/') goto yy57; + goto yy517; + } else { + if (yych != 'A') goto yy57; + } + } else { + if (yych <= 'a') { + if (yych <= 'P') goto yy519; + if (yych <= '`') goto yy57; + } else { + if (yych != 'p') goto yy57; + } } -yy1257: +yy519: + YYDEBUG(519, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'D': - case 'd': goto yy1216; - default: goto yy4; + if (yych <= 'L') { + if (yych != '.') goto yy57; + } else { + if (yych <= 'M') goto yy521; + if (yych == 'm') goto yy521; + goto yy57; } -yy1258: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'C': goto yy1245; - case 'P': goto yy1247; - case 'V': goto yy1246; - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'c': goto yy1274; - case 'p': goto yy1276; - case 'v': goto yy1275; - default: goto yy4; + YYDEBUG(520, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy521; + if (yych != 'm') goto yy57; +yy521: + YYDEBUG(521, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy523; + if (yych == '\t') goto yy523; + goto yy57; + } else { + if (yych <= ' ') goto yy523; + if (yych != '.') goto yy57; + } + YYDEBUG(522, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '\t') { + if (yych <= 0x00) goto yy523; + if (yych <= 0x08) goto yy57; + } else { + if (yych != ' ') goto yy57; + } +yy523: + YYDEBUG(523, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(524, *YYCURSOR); +#line 1153 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("mssqltime"); + TIMELIB_INIT; + TIMELIB_HAVE_TIME(); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + if (*ptr == ':' || *ptr == '.') { + s->time->s = timelib_get_nr((char **) &ptr, 2); + + if (*ptr == ':' || *ptr == '.') { + s->time->f = timelib_get_frac_nr((char **) &ptr, 8); + } + } + timelib_eat_spaces((char **) &ptr); + s->time->h += timelib_meridian((char **) &ptr, s->time->h); + TIMELIB_DEINIT; + return TIMELIB_TIME24_WITH_ZONE; } -yy1259: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'T': goto yy1240; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 't': goto yy1269; - default: goto yy4; +#line 10162 "ext/date/lib/parse_date.c" +yy525: + YYDEBUG(525, *YYCURSOR); + yyaccept = 11; + YYMARKER = ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; + YYDEBUG(526, *YYCURSOR); + if (yych <= 'O') { + if (yych <= '9') { + if (yych <= '/') goto yy491; + goto yy525; + } else { + if (yych == 'A') goto yy519; + goto yy491; + } + } else { + if (yych <= 'a') { + if (yych <= 'P') goto yy519; + if (yych <= '`') goto yy491; + goto yy519; + } else { + if (yych == 'p') goto yy519; + goto yy491; + } } -yy1260: - yyaccept = 0; +yy527: + YYDEBUG(527, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy528; + if (yych != 'm') goto yy57; +yy528: + YYDEBUG(528, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy488; + if (yych == '\t') goto yy488; + goto yy57; + } else { + if (yych <= ' ') goto yy488; + if (yych != '.') goto yy57; + } + YYDEBUG(529, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '\t') { + if (yych <= 0x00) goto yy488; + if (yych <= 0x08) goto yy57; + goto yy488; + } else { + if (yych == ' ') goto yy488; + goto yy57; + } +yy530: + YYDEBUG(530, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'V') goto yy531; + if (yych != 'v') goto yy57; +yy531: + YYDEBUG(531, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'Y': - case 'Z': goto yy142; - case 'X': goto yy1237; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'y': - case 'z': goto yy147; - case 'x': goto yy1266; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych != '\t') goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy536; + if (yych == 'e') goto yy536; + goto yy476; + } } -yy1261: - yyaccept = 0; +yy532: + YYDEBUG(532, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 4) YYFILL(4); + yych = *YYCURSOR; +yy533: + YYDEBUG(533, *YYCURSOR); + if (yych <= ' ') { + if (yych == '\t') goto yy532; + if (yych <= 0x1F) goto yy57; + goto yy532; + } else { + if (yych <= '.') { + if (yych <= ',') goto yy57; + goto yy532; + } else { + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + } + } +yy534: + YYDEBUG(534, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= '/') goto yy535; + if (yych <= '9') goto yy541; +yy535: + YYDEBUG(535, *YYCURSOR); +#line 1331 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("datefull"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->d = timelib_get_nr((char **) &ptr, 2); + timelib_skip_day_suffix((char **) &ptr); + s->time->m = timelib_get_month((char **) &ptr); + s->time->y = timelib_get_nr((char **) &ptr, 4); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_DATE_FULL; + } +#line 10281 "ext/date/lib/parse_date.c" +yy536: + YYDEBUG(536, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy537; + if (yych != 'm') goto yy57; +yy537: + YYDEBUG(537, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy538; + if (yych != 'b') goto yy57; +yy538: + YYDEBUG(538, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy539; + if (yych != 'e') goto yy57; +yy539: + YYDEBUG(539, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy540; + if (yych != 'r') goto yy57; +yy540: + YYDEBUG(540, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'N': goto yy1233; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'n': goto yy1262; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy532; + if (yych <= 0x1F) goto yy476; + goto yy532; + } else { + if (yych <= '.') { + if (yych <= ',') goto yy476; + goto yy532; + } else { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } + } +yy541: + YYDEBUG(541, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy535; + if (yych >= ':') goto yy535; +yy542: + YYDEBUG(542, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy535; + if (yych >= ':') goto yy535; + YYDEBUG(543, *YYCURSOR); + yych = *++YYCURSOR; + goto yy535; +yy544: + YYDEBUG(544, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy545; + if (yych != 't') goto yy57; +yy545: + YYDEBUG(545, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'N') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'O') goto yy546; + if (yych != 'o') goto yy476; + } } -yy1262: - yyaccept = 4; +yy546: + YYDEBUG(546, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy547; + if (yych != 'b') goto yy57; +yy547: + YYDEBUG(547, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy548; + if (yych != 'e') goto yy57; +yy548: + YYDEBUG(548, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy540; + if (yych == 'r') goto yy540; + goto yy57; +yy549: + YYDEBUG(549, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy553; + if (yych == 'g') goto yy553; + goto yy57; +yy550: + YYDEBUG(550, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy551; + if (yych != 'r') goto yy57; +yy551: + YYDEBUG(551, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'D': goto yy1234; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'd': goto yy1263; - default: goto yy167; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'I') goto yy552; + if (yych != 'i') goto yy476; + } } -yy1263: - yyaccept = 0; +yy552: + YYDEBUG(552, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'L') goto yy540; + if (yych == 'l') goto yy540; + goto yy57; +yy553: + YYDEBUG(553, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1235; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': goto yy1264; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'T') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'U') goto yy554; + if (yych != 'u') goto yy476; + } } -yy1264: - yyaccept = 0; +yy554: + YYDEBUG(554, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy555; + if (yych != 's') goto yy57; +yy555: + YYDEBUG(555, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy540; + if (yych == 't') goto yy540; + goto yy57; +yy556: + YYDEBUG(556, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych == 'L') goto yy563; + if (yych <= 'M') goto yy57; + goto yy562; + } else { + if (yych <= 'l') { + if (yych <= 'k') goto yy57; + goto yy563; + } else { + if (yych == 'n') goto yy562; + goto yy57; + } + } +yy557: + YYDEBUG(557, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy558; + if (yych != 'n') goto yy57; +yy558: + YYDEBUG(558, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': goto yy145; - case 'Y': goto yy1236; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy153; - case 'y': goto yy1265; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'T') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'U') goto yy559; + if (yych != 'u') goto yy476; + } } -yy1265: - yyaccept = 4; +yy559: + YYDEBUG(559, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy560; + if (yych != 'a') goto yy57; +yy560: + YYDEBUG(560, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy561; + if (yych != 'r') goto yy57; +yy561: + YYDEBUG(561, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy540; + if (yych == 'y') goto yy540; + goto yy57; +yy562: + YYDEBUG(562, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy167; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy540; + if (yych == 'e') goto yy540; + goto yy476; + } + } +yy563: + YYDEBUG(563, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'X') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'Y') goto yy540; + if (yych == 'y') goto yy540; + goto yy476; + } } -yy1266: - yyaccept = 0; +yy564: + YYDEBUG(564, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1238; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1267; - default: goto yy4; + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '9') { + if (yych <= '.') goto yy532; + if (yych <= '/') goto yy476; + goto yy534; + } else { + if (yych == 'I') goto yy540; + goto yy476; + } } -yy1267: - yyaccept = 0; +yy565: + YYDEBUG(565, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'H': goto yy1239; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'h': goto yy1268; - default: goto yy4; + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '9') { + if (yych <= '.') goto yy532; + if (yych <= '/') goto yy476; + goto yy534; + } else { + if (yych != 'I') goto yy476; + } } -yy1268: - yyaccept = 0; + YYDEBUG(566, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1207; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '9') { + if (yych <= '.') goto yy532; + if (yych <= '/') goto yy476; + goto yy534; + } else { + if (yych == 'I') goto yy540; + goto yy476; + } } -yy1269: - yyaccept = 4; +yy567: + YYDEBUG(567, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'U': goto yy1241; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'u': goto yy1270; - default: goto yy167; + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '9') { + if (yych <= '.') goto yy532; + if (yych <= '/') goto yy476; + goto yy534; + } else { + if (yych == 'I') goto yy540; + goto yy476; + } + } +yy568: + YYDEBUG(568, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + goto yy601; + } else { + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy615; + if (yych <= ':') goto yy493; + goto yy491; + } +yy569: + YYDEBUG(569, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + if (yych <= '.') goto yy601; + goto yy491; + } else { + if (yych <= '2') goto yy615; + if (yych <= '9') goto yy614; + if (yych <= ':') goto yy493; + goto yy491; + } +yy570: + YYDEBUG(570, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + goto yy601; + } else { + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy614; + if (yych <= ':') goto yy493; + goto yy491; } -yy1270: - yyaccept = 0; +yy571: + YYDEBUG(571, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + goto yy601; + } else { + if (yych == ':') goto yy493; + goto yy491; + } +yy572: + YYDEBUG(572, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy595; + if (yych == 'e') goto yy595; + goto yy57; +yy573: + YYDEBUG(573, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy592; + if (yych == 'a') goto yy592; + goto yy57; +yy574: + YYDEBUG(574, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'P') goto yy550; + if (yych <= 'T') goto yy57; + goto yy549; + } else { + if (yych <= 'p') { + if (yych <= 'o') goto yy57; + goto yy550; + } else { + if (yych == 'u') goto yy549; + goto yy57; + } + } +yy575: + YYDEBUG(575, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy585; + if (yych == 'e') goto yy585; + goto yy57; +yy576: + YYDEBUG(576, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy579; + if (yych == 'e') goto yy579; + goto yy57; +yy577: + YYDEBUG(577, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); + yych = *YYCURSOR; +yy578: + YYDEBUG(578, *YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '\t': + case ' ': case '-': - case '/': - case '_': goto yy148; + case '.': goto yy577; case 'A': - case 'B': - case 'C': + case 'a': goto yy574; case 'D': - case 'E': + case 'd': goto yy576; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy572; + case 'I': goto yy475; case 'J': - case 'K': - case 'L': + case 'j': goto yy479; case 'M': + case 'm': goto yy573; case 'N': + case 'n': goto yy482; case 'O': - case 'P': - case 'Q': + case 'o': goto yy481; case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'R': goto yy1242; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'r': goto yy1271; - default: goto yy4; + case 's': goto yy575; + case 'V': goto yy477; + case 'X': goto yy478; + default: goto yy57; } -yy1271: - yyaccept = 0; +yy579: + YYDEBUG(579, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy580; + if (yych != 'c') goto yy57; +yy580: + YYDEBUG(580, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'D': goto yy1243; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'd': goto yy1272; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy581; + if (yych != 'e') goto yy476; + } + } +yy581: + YYDEBUG(581, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy582; + if (yych != 'm') goto yy57; +yy582: + YYDEBUG(582, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy583; + if (yych != 'b') goto yy57; +yy583: + YYDEBUG(583, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy584; + if (yych != 'e') goto yy57; +yy584: + YYDEBUG(584, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy540; + if (yych == 'r') goto yy540; + goto yy57; +yy585: + YYDEBUG(585, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'P') goto yy586; + if (yych != 'p') goto yy57; +yy586: + YYDEBUG(586, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'S') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'T') goto yy587; + if (yych != 't') goto yy476; + } + } +yy587: + YYDEBUG(587, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy588; + if (yych != 'e') goto yy476; + } + } +yy588: + YYDEBUG(588, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy589; + if (yych != 'm') goto yy57; +yy589: + YYDEBUG(589, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy590; + if (yych != 'b') goto yy57; +yy590: + YYDEBUG(590, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy591; + if (yych != 'e') goto yy57; +yy591: + YYDEBUG(591, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy540; + if (yych == 'r') goto yy540; + goto yy57; +yy592: + YYDEBUG(592, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Y') { + if (yych == 'R') goto yy593; + if (yych <= 'X') goto yy57; + goto yy540; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy57; + } else { + if (yych == 'y') goto yy540; + goto yy57; + } + } +yy593: + YYDEBUG(593, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'B') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'C') goto yy594; + if (yych != 'c') goto yy476; + } + } +yy594: + YYDEBUG(594, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy540; + if (yych == 'h') goto yy540; + goto yy57; +yy595: + YYDEBUG(595, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy596; + if (yych != 'b') goto yy57; +yy596: + YYDEBUG(596, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + goto yy532; + } + } else { + if (yych <= 'Q') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'R') goto yy597; + if (yych != 'r') goto yy476; + } + } +yy597: + YYDEBUG(597, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'U') goto yy598; + if (yych != 'u') goto yy57; +yy598: + YYDEBUG(598, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy599; + if (yych != 'a') goto yy57; +yy599: + YYDEBUG(599, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy600; + if (yych != 'r') goto yy57; +yy600: + YYDEBUG(600, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy540; + if (yych == 'y') goto yy540; + goto yy57; +yy601: + YYDEBUG(601, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy608; + if (yych <= '6') goto yy609; + if (yych <= '9') goto yy610; + goto yy57; +yy602: + YYDEBUG(602, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(603, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy604: + YYDEBUG(604, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy605: + YYDEBUG(605, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(606, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(607, *YYCURSOR); +#line 1345 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("pointed date YYYY"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->d = timelib_get_nr((char **) &ptr, 2); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->y = timelib_get_nr((char **) &ptr, 4); + TIMELIB_DEINIT; + return TIMELIB_DATE_FULL_POINTED; + } +#line 11029 "ext/date/lib/parse_date.c" +yy608: + YYDEBUG(608, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy613; + goto yy491; +yy609: + YYDEBUG(609, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy497; + goto yy491; + } else { + if (yych <= '0') goto yy613; + if (yych <= '9') goto yy611; + goto yy491; + } +yy610: + YYDEBUG(610, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych >= ':') goto yy491; +yy611: + YYDEBUG(611, *YYCURSOR); + yyaccept = 12; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') goto yy612; + if (yych <= '9') goto yy605; +yy612: + YYDEBUG(612, *YYCURSOR); +#line 1357 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("pointed date YY"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->d = timelib_get_nr((char **) &ptr, 2); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->y = timelib_get_nr((char **) &ptr, 2); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_DATE_FULL_POINTED; } -yy1272: - yyaccept = 0; +#line 11077 "ext/date/lib/parse_date.c" +yy613: + YYDEBUG(613, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1244; - case 'a': goto yy1273; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy4; + if (yych <= '9') { + if (yych <= ' ') { + if (yych == '\t') goto yy501; + if (yych <= 0x1F) goto yy491; + goto yy501; + } else { + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + goto yy605; + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy503; + if (yych <= 'O') goto yy491; + goto yy503; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy491; + goto yy503; + } else { + if (yych == 'p') goto yy503; + goto yy491; + } + } } -yy1273: +yy614: + YYDEBUG(614, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy508; + if (yych <= 0x1F) goto yy491; + goto yy508; + } else { + if (yych == '.') goto yy493; + if (yych <= '9') goto yy491; + goto yy493; + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy510; + if (yych <= 'O') goto yy491; + goto yy510; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy491; + goto yy510; + } else { + if (yych == 'p') goto yy510; + goto yy491; + } + } + } +yy615: + YYDEBUG(615, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ':') { + if (yych <= ' ') { + if (yych == '\t') goto yy508; + if (yych <= 0x1F) goto yy491; + goto yy508; + } else { + if (yych <= '-') { + if (yych <= ',') goto yy491; + goto yy602; + } else { + if (yych <= '.') goto yy601; + if (yych <= '9') goto yy491; + goto yy493; + } + } + } else { + if (yych <= 'P') { + if (yych == 'A') goto yy510; + if (yych <= 'O') goto yy491; + goto yy510; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy491; + goto yy510; + } else { + if (yych == 'p') goto yy510; + goto yy491; + } + } + } +yy616: + YYDEBUG(616, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': goto yy173; - case 'y': goto yy186; - default: goto yy155; + if (yych <= '.') { + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy655; + goto yy602; + } else { + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy618; + goto yy57; } -yy1274: - yyaccept = 0; +yy617: + YYDEBUG(617, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') { + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy655; + goto yy602; + } else { + if (yych <= '/') goto yy57; + if (yych >= '3') goto yy57; + } +yy618: + YYDEBUG(618, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy655; + if (yych <= '.') goto yy602; + goto yy57; +yy619: + YYDEBUG(619, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'A') goto yy651; + if (yych <= 'T') goto yy57; + goto yy650; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy651; + } else { + if (yych == 'u') goto yy650; + goto yy57; + } + } +yy620: + YYDEBUG(620, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy648; + if (yych == 'e') goto yy648; + goto yy57; +yy621: + YYDEBUG(621, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy645; + if (yych == 'a') goto yy645; + goto yy57; +yy622: + YYDEBUG(622, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'P') goto yy642; + if (yych <= 'T') goto yy57; + goto yy641; + } else { + if (yych <= 'p') { + if (yych <= 'o') goto yy57; + goto yy642; + } else { + if (yych == 'u') goto yy641; + goto yy57; + } + } +yy623: + YYDEBUG(623, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy638; + if (yych == 'e') goto yy638; + goto yy57; +yy624: + YYDEBUG(624, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy636; + if (yych == 'c') goto yy636; + goto yy57; +yy625: + YYDEBUG(625, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy634; + if (yych == 'o') goto yy634; + goto yy57; +yy626: + YYDEBUG(626, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy627; + if (yych != 'e') goto yy57; +yy627: + YYDEBUG(627, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy628; + if (yych != 'c') goto yy57; +yy628: + YYDEBUG(628, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'O': goto yy1256; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'o': goto yy1285; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych >= '.') goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy581; + if (yych == 'e') goto yy581; + goto yy476; + } } -yy1275: - yyaccept = 0; +yy629: + YYDEBUG(629, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy533; + if (yych <= '0') goto yy630; + if (yych <= '2') goto yy631; + if (yych <= '3') goto yy632; + goto yy533; +yy630: + YYDEBUG(630, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy535; + if (yych <= '9') goto yy633; + goto yy535; +yy631: + YYDEBUG(631, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy535; + if (yych <= '9') goto yy633; + goto yy535; +yy632: + YYDEBUG(632, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy535; + if (yych <= '1') goto yy633; + if (yych <= '9') goto yy541; + goto yy535; +yy633: + YYDEBUG(633, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy535; + if (yych <= '9') goto yy542; + goto yy535; +yy634: + YYDEBUG(634, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'V') goto yy635; + if (yych != 'v') goto yy57; +yy635: + YYDEBUG(635, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'E': goto yy1253; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'e': goto yy1282; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy536; + if (yych == 'e') goto yy536; + goto yy476; + } + } +yy636: + YYDEBUG(636, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy637; + if (yych != 't') goto yy57; +yy637: + YYDEBUG(637, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'N') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'O') goto yy546; + if (yych == 'o') goto yy546; + goto yy476; + } } -yy1276: - yyaccept = 5; +yy638: + YYDEBUG(638, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'P') goto yy639; + if (yych != 'p') goto yy57; +yy639: + YYDEBUG(639, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1248; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1277; - default: goto yy194; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'S') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'T') goto yy640; + if (yych != 't') goto yy476; + } } -yy1277: - yyaccept = 5; +yy640: + YYDEBUG(640, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'E': goto yy1249; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'e': goto yy1278; - default: goto yy194; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy588; + if (yych == 'e') goto yy588; + goto yy476; + } } -yy1278: - yyaccept = 0; +yy641: + YYDEBUG(641, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy644; + if (yych == 'g') goto yy644; + goto yy57; +yy642: + YYDEBUG(642, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy643; + if (yych != 'r') goto yy57; +yy643: + YYDEBUG(643, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'M': goto yy1250; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'm': goto yy1279; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'H') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'I') goto yy552; + if (yych == 'i') goto yy552; + goto yy476; + } } -yy1279: - yyaccept = 0; +yy644: + YYDEBUG(644, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'B': goto yy1251; - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'b': goto yy1280; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'T') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'U') goto yy554; + if (yych == 'u') goto yy554; + goto yy476; + } + } +yy645: + YYDEBUG(645, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Y') { + if (yych == 'R') goto yy646; + if (yych <= 'X') goto yy57; + goto yy647; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy57; + } else { + if (yych == 'y') goto yy647; + goto yy57; + } + } +yy646: + YYDEBUG(646, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'B') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'C') goto yy594; + if (yych == 'c') goto yy594; + goto yy476; + } } -yy1280: +yy647: + YYDEBUG(647, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy476; + goto yy532; + } else { + if (yych == ' ') goto yy532; + goto yy476; + } + } else { + if (yych <= '.') { + if (yych <= '-') goto yy629; + goto yy532; + } else { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } + } +yy648: + YYDEBUG(648, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'E': goto yy1252; - case 'e': goto yy1281; - default: goto yy155; + if (yych == 'B') goto yy649; + if (yych != 'b') goto yy57; +yy649: + YYDEBUG(649, *YYCURSOR); + yyaccept = 10; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'Q') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'R') goto yy597; + if (yych == 'r') goto yy597; + goto yy476; + } } -yy1281: +yy650: + YYDEBUG(650, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'R': goto yy206; - case 'r': goto yy377; - default: goto yy155; + if (yych <= 'N') { + if (yych == 'L') goto yy654; + if (yych <= 'M') goto yy57; + goto yy653; + } else { + if (yych <= 'l') { + if (yych <= 'k') goto yy57; + goto yy654; + } else { + if (yych == 'n') goto yy653; + goto yy57; + } } -yy1282: - yyaccept = 0; +yy651: + YYDEBUG(651, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy652; + if (yych != 'n') goto yy57; +yy652: + YYDEBUG(652, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'N': goto yy1254; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'n': goto yy1283; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'T') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'U') goto yy559; + if (yych == 'u') goto yy559; + goto yy476; + } } -yy1283: - yyaccept = 0; +yy653: + YYDEBUG(653, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'T': goto yy1255; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 't': goto yy1284; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'D') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'E') goto yy540; + if (yych == 'e') goto yy540; + goto yy476; + } } -yy1284: - yyaccept = 0; +yy654: + YYDEBUG(654, *YYCURSOR); + yyaccept = 10; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'H': goto yy1206; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'h': goto yy1224; - default: goto yy4; + if (yych <= '.') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy532; + goto yy476; + } else { + if (yych <= ' ') goto yy532; + if (yych <= ',') goto yy476; + if (yych <= '-') goto yy629; + goto yy532; + } + } else { + if (yych <= 'X') { + if (yych <= '/') goto yy476; + if (yych <= '9') goto yy534; + goto yy476; + } else { + if (yych <= 'Y') goto yy540; + if (yych == 'y') goto yy540; + goto yy476; + } } -yy1285: - yyaccept = 0; +yy655: + YYDEBUG(655, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy656; + if (yych <= '3') goto yy658; + if (yych <= '9') goto yy659; + goto yy57; +yy656: + YYDEBUG(656, *YYCURSOR); + yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'N': goto yy1257; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'n': goto yy1286; - default: goto yy4; + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy665; + if (yych >= 'n') goto yy661; + } else { + if (yych <= 'r') { + if (yych >= 'r') goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + } + } +yy657: + YYDEBUG(657, *YYCURSOR); +#line 1318 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("gnudateshort"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = timelib_get_nr((char **) &ptr, 2); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_ISO_DATE; } -yy1286: - yyaccept = 0; +#line 11730 "ext/date/lib/parse_date.c" +yy658: + YYDEBUG(658, *YYCURSOR); + yyaccept = 13; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'D': goto yy1216; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'd': goto yy1228; - default: goto yy4; + if (yych <= 'n') { + if (yych <= '1') { + if (yych <= '/') goto yy657; + goto yy665; + } else { + if (yych <= '9') goto yy604; + if (yych <= 'm') goto yy657; + goto yy661; + } + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } } -yy1287: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'C': - case 'c': goto yy1288; - default: goto yy4; +yy659: + YYDEBUG(659, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy604; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } } -yy1288: +yy660: + YYDEBUG(660, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'K': - case 'k': goto yy1289; - default: goto yy4; + if (yych == 't') goto yy664; + goto yy57; +yy661: + YYDEBUG(661, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy664; + goto yy57; +yy662: + YYDEBUG(662, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy664; + goto yy57; +yy663: + YYDEBUG(663, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != 'h') goto yy57; +yy664: + YYDEBUG(664, *YYCURSOR); + yych = *++YYCURSOR; + goto yy657; +yy665: + YYDEBUG(665, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy605; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } } -yy1289: - yyaccept = 0; +yy666: + YYDEBUG(666, *YYCURSOR); + yyaccept = 14; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ' ': goto yy1290; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; + if (yych <= 'n') { + if (yych <= '/') { + if (yych >= '/') goto yy723; + } else { + if (yych <= '9') goto yy669; + if (yych >= 'n') goto yy720; + } + } else { + if (yych <= 'r') { + if (yych >= 'r') goto yy721; + } else { + if (yych <= 's') goto yy719; + if (yych <= 't') goto yy722; + } + } +yy667: + YYDEBUG(667, *YYCURSOR); +#line 1265 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("americanshort | american"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = timelib_get_nr((char **) &ptr, 2); + if (*ptr == '/') { + s->time->y = timelib_get_nr((char **) &ptr, 4); + TIMELIB_PROCESS_YEAR(s->time->y); + } + TIMELIB_DEINIT; + return TIMELIB_AMERICAN; } -yy1290: - yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1291; - default: goto yy57; +#line 11850 "ext/date/lib/parse_date.c" +yy668: + YYDEBUG(668, *YYCURSOR); + yyaccept = 14; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') { + if (yych <= '.') goto yy667; + goto yy723; + } else { + if (yych <= '1') goto yy669; + if (yych <= 'm') goto yy667; + goto yy720; + } + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy667; + goto yy721; + } else { + if (yych <= 's') goto yy719; + if (yych <= 't') goto yy722; + goto yy667; + } } -yy1291: - yych = *++YYCURSOR; - switch (yych) { - case 'F': - case 'f': goto yy1292; - default: goto yy57; +yy669: + YYDEBUG(669, *YYCURSOR); + yyaccept = 14; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych == '/') goto yy723; + if (yych <= 'm') goto yy667; + goto yy720; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy667; + goto yy721; + } else { + if (yych <= 's') goto yy719; + if (yych <= 't') goto yy722; + goto yy667; + } } -yy1292: +yy670: + YYDEBUG(670, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ' ': goto yy1293; - default: goto yy57; + if (yych <= 'U') { + if (yych == 'A') goto yy718; + if (yych <= 'T') goto yy57; + goto yy717; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy718; + } else { + if (yych == 'u') goto yy717; + goto yy57; + } } -yy1293: +yy671: + YYDEBUG(671, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy1294; - case '2': goto yy1296; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1297; - default: goto yy57; + if (yych == 'E') goto yy716; + if (yych == 'e') goto yy716; + goto yy57; +yy672: + YYDEBUG(672, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy715; + if (yych == 'a') goto yy715; + goto yy57; +yy673: + YYDEBUG(673, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'P') goto yy714; + if (yych <= 'T') goto yy57; + goto yy713; + } else { + if (yych <= 'p') { + if (yych <= 'o') goto yy57; + goto yy714; + } else { + if (yych == 'u') goto yy713; + goto yy57; + } } -yy1294: - yyaccept = 28; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1297; - default: goto yy1298; +yy674: + YYDEBUG(674, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy711; + if (yych == 'e') goto yy711; + goto yy57; +yy675: + YYDEBUG(675, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy710; + if (yych == 'c') goto yy710; + goto yy57; +yy676: + YYDEBUG(676, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy709; + if (yych == 'o') goto yy709; + goto yy57; +yy677: + YYDEBUG(677, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy678; + if (yych != 'e') goto yy57; +yy678: + YYDEBUG(678, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy679; + if (yych != 'c') goto yy57; +yy679: + YYDEBUG(679, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '/') goto yy57; +yy680: + YYDEBUG(680, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(681, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(682, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(683, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(684, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(685, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy686; + if (yych <= '2') goto yy687; + goto yy57; +yy686: + YYDEBUG(686, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy688; + goto yy57; +yy687: + YYDEBUG(687, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '5') goto yy57; +yy688: + YYDEBUG(688, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(689, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '6') goto yy57; + YYDEBUG(690, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(691, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(692, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy693; + if (yych <= '6') goto yy694; + goto yy57; +yy693: + YYDEBUG(693, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy695; + goto yy57; +yy694: + YYDEBUG(694, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '0') goto yy57; +yy695: + YYDEBUG(695, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '\t') goto yy696; + if (yych != ' ') goto yy57; +yy696: + YYDEBUG(696, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; + YYDEBUG(697, *YYCURSOR); + if (yych <= '*') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy57; + goto yy696; + } else { + if (yych == ' ') goto yy696; + goto yy57; + } + } else { + if (yych <= '-') { + if (yych == ',') goto yy57; + goto yy699; + } else { + if (yych != 'G') goto yy57; + } } -yy1295: -#line 1091 "ext/date/lib/parse_date.re" + YYDEBUG(698, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy707; + goto yy57; +yy699: + YYDEBUG(699, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy700; + if (yych <= '2') goto yy702; + if (yych <= '9') goto yy703; + goto yy57; +yy700: + YYDEBUG(700, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= '/') goto yy701; + if (yych <= '9') goto yy703; + if (yych <= ':') goto yy704; +yy701: + YYDEBUG(701, *YYCURSOR); +#line 1536 "ext/date/lib/parse_date.re" { - DEBUG_OUTPUT("backof | frontof"); + int tz_not_found; + DEBUG_OUTPUT("clf"); TIMELIB_INIT; - TIMELIB_UNHAVE_TIME(); TIMELIB_HAVE_TIME(); - - if (*ptr == 'b') { - s->time->h = timelib_get_nr((char **) &ptr, 2); - s->time->i = 15; - } else { - s->time->h = timelib_get_nr((char **) &ptr, 2) - 1; - s->time->i = 45; - } - if (*ptr != '\0' ) { - timelib_eat_spaces((char **) &ptr); - s->time->h += timelib_meridian((char **) &ptr, s->time->h); + TIMELIB_HAVE_DATE(); + s->time->d = timelib_get_nr((char **) &ptr, 2); + s->time->m = timelib_get_month((char **) &ptr); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + s->time->s = timelib_get_nr((char **) &ptr, 2); + s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); + if (tz_not_found) { + add_error(s, "The timezone could not be found in the database"); } - TIMELIB_DEINIT; - return TIMELIB_LF_DAY_OF_MONTH; - } -#line 28647 "" -yy1296: - yyaccept = 28; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy1297; - default: goto yy1298; - } -yy1297: - yyaccept = 28; - YYMARKER = ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; -yy1298: - switch (yych) { - case '\t': - case ' ': goto yy1297; - case 'A': - case 'P': - case 'a': - case 'p': goto yy1299; - default: goto yy1295; + return TIMELIB_CLF; } -yy1299: +#line 12103 "ext/date/lib/parse_date.c" +yy702: + YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy1300; - case 'M': - case 'm': goto yy1301; - default: goto yy57; + if (yych <= '5') { + if (yych <= '/') goto yy701; + if (yych >= '5') goto yy705; + } else { + if (yych <= '9') goto yy706; + if (yych <= ':') goto yy704; + goto yy701; } -yy1300: +yy703: + YYDEBUG(703, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy1301; - default: goto yy57; + if (yych <= '/') goto yy701; + if (yych <= '5') goto yy705; + if (yych <= '9') goto yy706; + if (yych >= ';') goto yy701; +yy704: + YYDEBUG(704, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy701; + if (yych <= '5') goto yy705; + if (yych <= '9') goto yy706; + goto yy701; +yy705: + YYDEBUG(705, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy701; + if (yych >= ':') goto yy701; +yy706: + YYDEBUG(706, *YYCURSOR); + yych = *++YYCURSOR; + goto yy701; +yy707: + YYDEBUG(707, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != 'T') goto yy57; + YYDEBUG(708, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '+') goto yy699; + if (yych == '-') goto yy699; + goto yy57; +yy709: + YYDEBUG(709, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'V') goto yy679; + if (yych == 'v') goto yy679; + goto yy57; +yy710: + YYDEBUG(710, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy679; + if (yych == 't') goto yy679; + goto yy57; +yy711: + YYDEBUG(711, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'P') goto yy712; + if (yych != 'p') goto yy57; +yy712: + YYDEBUG(712, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych == '/') goto yy680; + goto yy57; + } else { + if (yych <= 'T') goto yy679; + if (yych == 't') goto yy679; + goto yy57; } -yy1301: +yy713: + YYDEBUG(713, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy1303; - case '.': goto yy1302; - default: goto yy57; + if (yych == 'G') goto yy679; + if (yych == 'g') goto yy679; + goto yy57; +yy714: + YYDEBUG(714, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy679; + if (yych == 'r') goto yy679; + goto yy57; +yy715: + YYDEBUG(715, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Y') { + if (yych == 'R') goto yy679; + if (yych <= 'X') goto yy57; + goto yy679; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy57; + goto yy679; + } else { + if (yych == 'y') goto yy679; + goto yy57; + } } -yy1302: +yy716: + YYDEBUG(716, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy1303; - default: goto yy57; + if (yych == 'B') goto yy679; + if (yych == 'b') goto yy679; + goto yy57; +yy717: + YYDEBUG(717, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych == 'L') goto yy679; + if (yych <= 'M') goto yy57; + goto yy679; + } else { + if (yych <= 'l') { + if (yych <= 'k') goto yy57; + goto yy679; + } else { + if (yych == 'n') goto yy679; + goto yy57; + } } -yy1303: +yy718: + YYDEBUG(718, *YYCURSOR); yych = *++YYCURSOR; - goto yy1295; -yy1304: - yyaccept = 0; + if (yych == 'N') goto yy679; + if (yych == 'n') goto yy679; + goto yy57; +yy719: + YYDEBUG(719, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 't') goto yy728; + goto yy57; +yy720: + YYDEBUG(720, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy728; + goto yy57; +yy721: + YYDEBUG(721, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy728; + goto yy57; +yy722: + YYDEBUG(722, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'h') goto yy728; + goto yy57; +yy723: + YYDEBUG(723, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(724, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy667; + if (yych >= ':') goto yy667; + YYDEBUG(725, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy667; + if (yych >= ':') goto yy667; + YYDEBUG(726, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy667; + if (yych >= ':') goto yy667; + YYDEBUG(727, *YYCURSOR); + yych = *++YYCURSOR; + goto yy667; +yy728: + YYDEBUG(728, *YYCURSOR); + yyaccept = 14; yych = *(YYMARKER = ++YYCURSOR); + if (yych == '/') goto yy723; + goto yy667; +yy729: + YYDEBUG(729, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') { + if (yych == '\t') goto yy731; + goto yy578; + } else { + if (yych <= '-') goto yy732; + if (yych <= '.') goto yy731; + if (yych >= '0') goto yy578; + } +yy730: + YYDEBUG(730, *YYCURSOR); + yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; case 'A': - case 'B': + case 'a': goto yy673; case 'D': - case 'E': + case 'd': goto yy677; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy671; case 'J': - case 'K': - case 'L': + case 'j': goto yy670; case 'M': + case 'm': goto yy672; case 'N': + case 'n': goto yy676; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy675; case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'C': goto yy1288; - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'c': goto yy1305; - default: goto yy4; + case 's': goto yy674; + default: goto yy57; } -yy1305: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); +yy731: + YYDEBUG(731, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy578; + if (yych <= '0') goto yy736; + if (yych <= '1') goto yy737; + if (yych <= '9') goto yy738; + goto yy578; +yy732: + YYDEBUG(732, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy578; + if (yych <= '0') goto yy733; + if (yych <= '1') goto yy734; + if (yych <= '9') goto yy735; + goto yy578; +yy733: + YYDEBUG(733, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') goto yy57; + if (yych <= '.') goto yy602; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy735; + goto yy57; +yy734: + YYDEBUG(734, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') goto yy57; + if (yych <= '.') goto yy602; + if (yych <= '/') goto yy57; + if (yych >= '3') goto yy57; +yy735: + YYDEBUG(735, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') goto yy57; + if (yych <= '.') goto yy602; + goto yy57; +yy736: + YYDEBUG(736, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') { + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy602; + goto yy739; + } else { + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy738; + goto yy57; + } +yy737: + YYDEBUG(737, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') { + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy602; + goto yy739; + } else { + if (yych <= '/') goto yy57; + if (yych >= '3') goto yy57; + } +yy738: + YYDEBUG(738, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy602; + if (yych >= '/') goto yy57; +yy739: + YYDEBUG(739, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(740, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy611; + goto yy57; +yy741: + YYDEBUG(741, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy785; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy783; + goto yy61; +yy742: + YYDEBUG(742, *YYCURSOR); + yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; + case '0': goto yy751; + case '1': goto yy752; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy753; case 'A': - case 'B': - case 'C': + case 'a': goto yy746; case 'D': - case 'E': + case 'd': goto yy750; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy744; case 'J': - case 'L': + case 'j': goto yy743; case 'M': + case 'm': goto yy745; case 'N': + case 'n': goto yy749; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy748; case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'K': goto yy1289; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'k': goto yy1306; - default: goto yy4; + case 's': goto yy747; + default: goto yy57; + } +yy743: + YYDEBUG(743, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'A') goto yy782; + if (yych <= 'T') goto yy57; + goto yy781; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy782; + } else { + if (yych == 'u') goto yy781; + goto yy57; + } + } +yy744: + YYDEBUG(744, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy780; + if (yych == 'e') goto yy780; + goto yy57; +yy745: + YYDEBUG(745, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy779; + if (yych == 'a') goto yy779; + goto yy57; +yy746: + YYDEBUG(746, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'P') goto yy778; + if (yych <= 'T') goto yy57; + goto yy777; + } else { + if (yych <= 'p') { + if (yych <= 'o') goto yy57; + goto yy778; + } else { + if (yych == 'u') goto yy777; + goto yy57; + } + } +yy747: + YYDEBUG(747, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy775; + if (yych == 'e') goto yy775; + goto yy57; +yy748: + YYDEBUG(748, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy774; + if (yych == 'c') goto yy774; + goto yy57; +yy749: + YYDEBUG(749, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy773; + if (yych == 'o') goto yy773; + goto yy57; +yy750: + YYDEBUG(750, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy765; + if (yych == 'e') goto yy765; + goto yy57; +yy751: + YYDEBUG(751, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy754; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy758; + goto yy57; +yy752: + YYDEBUG(752, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy754; + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy758; + goto yy57; +yy753: + YYDEBUG(753, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '-') goto yy57; +yy754: + YYDEBUG(754, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy755; + if (yych <= '3') goto yy756; + if (yych <= '9') goto yy757; + goto yy57; +yy755: + YYDEBUG(755, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy757; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy756: + YYDEBUG(756, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '1') goto yy757; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy757: + YYDEBUG(757, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'q') { + if (yych == 'n') goto yy661; + goto yy657; + } else { + if (yych <= 'r') goto yy662; + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } +yy758: + YYDEBUG(758, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '-') goto yy57; + YYDEBUG(759, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '2') { + if (yych <= '/') goto yy57; + if (yych >= '1') goto yy761; + } else { + if (yych <= '3') goto yy762; + if (yych <= '9') goto yy757; + goto yy57; + } + YYDEBUG(760, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy763; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy761: + YYDEBUG(761, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy763; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy762: + YYDEBUG(762, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '1') goto yy763; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy763: + YYDEBUG(763, *YYCURSOR); + yyaccept = 15; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'q') { + if (yych == 'n') goto yy661; + } else { + if (yych <= 'r') goto yy662; + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + } +yy764: + YYDEBUG(764, *YYCURSOR); +#line 1292 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("iso8601date2"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = timelib_get_nr((char **) &ptr, 2); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_ISO_DATE; + } +#line 12667 "ext/date/lib/parse_date.c" +yy765: + YYDEBUG(765, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy766; + if (yych != 'c') goto yy57; +yy766: + YYDEBUG(766, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '-') goto yy57; +yy767: + YYDEBUG(767, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy768; + if (yych <= '2') goto yy769; + if (yych <= '3') goto yy770; + goto yy57; +yy768: + YYDEBUG(768, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy771; + goto yy57; +yy769: + YYDEBUG(769, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy771; + goto yy57; +yy770: + YYDEBUG(770, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '2') goto yy57; +yy771: + YYDEBUG(771, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(772, *YYCURSOR); +#line 1523 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("pgtextreverse"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_month((char **) &ptr); + s->time->d = timelib_get_nr((char **) &ptr, 2); + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_PG_TEXT; } -yy1306: - yyaccept = 0; +#line 12718 "ext/date/lib/parse_date.c" +yy773: + YYDEBUG(773, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'V') goto yy766; + if (yych == 'v') goto yy766; + goto yy57; +yy774: + YYDEBUG(774, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy766; + if (yych == 't') goto yy766; + goto yy57; +yy775: + YYDEBUG(775, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'P') goto yy776; + if (yych != 'p') goto yy57; +yy776: + YYDEBUG(776, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych == '-') goto yy767; + goto yy57; + } else { + if (yych <= 'T') goto yy766; + if (yych == 't') goto yy766; + goto yy57; + } +yy777: + YYDEBUG(777, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy766; + if (yych == 'g') goto yy766; + goto yy57; +yy778: + YYDEBUG(778, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy766; + if (yych == 'r') goto yy766; + goto yy57; +yy779: + YYDEBUG(779, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Y') { + if (yych == 'R') goto yy766; + if (yych <= 'X') goto yy57; + goto yy766; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy57; + goto yy766; + } else { + if (yych == 'y') goto yy766; + goto yy57; + } + } +yy780: + YYDEBUG(780, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy766; + if (yych == 'b') goto yy766; + goto yy57; +yy781: + YYDEBUG(781, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych == 'L') goto yy766; + if (yych <= 'M') goto yy57; + goto yy766; + } else { + if (yych <= 'l') { + if (yych <= 'k') goto yy57; + goto yy766; + } else { + if (yych == 'n') goto yy766; + goto yy57; + } + } +yy782: + YYDEBUG(782, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy766; + if (yych == 'n') goto yy766; + goto yy57; +yy783: + YYDEBUG(783, *YYCURSOR); + yyaccept = 16; yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ' ': goto yy1290; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; + case '\t': + case ' ': case 'A': - case 'B': - case 'C': case 'D': - case 'E': case 'F': - case 'G': case 'H': case 'I': case 'J': - case 'K': - case 'L': case 'M': case 'N': case 'O': - case 'P': - case 'Q': - case 'R': case 'S': case 'T': - case 'U': case 'V': - case 'W': case 'X': case 'Y': - case 'Z': goto yy144; case 'a': - case 'b': - case 'c': case 'd': - case 'e': case 'f': - case 'g': case 'h': - case 'i': case 'j': - case 'k': - case 'l': case 'm': case 'n': case 'o': - case 'p': - case 'q': - case 'r': case 's': case 't': - case 'u': - case 'v': case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; + case 'y': goto yy791; + case '-': goto yy788; + case '.': goto yy792; + case '/': goto yy789; + case '0': goto yy805; + case '1': goto yy806; + case '2': goto yy808; + case '3': goto yy809; + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy55; + case ':': goto yy807; + case 'W': goto yy810; + default: goto yy784; } -yy1307: +yy784: + YYDEBUG(784, *YYCURSOR); +#line 1557 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("year4"); + TIMELIB_INIT; + s->time->y = timelib_get_nr((char **) &ptr, 4); + TIMELIB_DEINIT; + return TIMELIB_CLF; + } +#line 12864 "ext/date/lib/parse_date.c" +yy785: + YYDEBUG(785, *YYCURSOR); yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '0': goto yy786; + case '1': goto yy787; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy753; case 'A': - case 'B': - case 'C': + case 'a': goto yy746; case 'D': - case 'E': + case 'd': goto yy750; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy744; case 'J': - case 'K': - case 'L': + case 'j': goto yy743; case 'M': + case 'm': goto yy745; case 'N': + case 'n': goto yy749; case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; + case 'o': goto yy748; case 'S': - case 's': goto yy1308; - default: goto yy4; + case 's': goto yy747; + default: goto yy57; } -yy1308: +yy786: + YYDEBUG(786, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy754; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy753; + goto yy57; +yy787: + YYDEBUG(787, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy754; + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy753; + goto yy57; +yy788: + YYDEBUG(788, *YYCURSOR); yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '0': goto yy973; + case '1': goto yy975; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy976; case 'A': - case 'B': - case 'C': + case 'a': goto yy967; case 'D': - case 'E': + case 'd': goto yy971; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy965; case 'J': - case 'K': - case 'L': + case 'j': goto yy964; case 'M': + case 'm': goto yy966; case 'N': + case 'n': goto yy970; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy969; case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1309; - default: goto yy4; + case 's': goto yy968; + case 'W': goto yy972; + default: goto yy939; } -yy1309: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); +yy789: + YYDEBUG(789, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy947; + if (yych <= '1') goto yy948; + if (yych <= '9') goto yy949; + goto yy57; +yy790: + YYDEBUG(790, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); + yych = *YYCURSOR; +yy791: + YYDEBUG(791, *YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case '\t': goto yy1105; - case ' ': goto yy1310; - case ')': goto yy140; + case '\t': + case ' ': goto yy790; + case '-': + case '.': goto yy938; case 'A': - case 'B': - case 'C': + case 'a': goto yy800; case 'D': - case 'E': + case 'd': goto yy804; case 'F': - case 'G': + case 'f': goto yy798; case 'H': - case 'I': - case 'J': - case 'K': - case 'L': + case 'h': goto yy64; + case 'I': goto yy793; + case 'J': + case 'j': goto yy797; case 'M': + case 'm': goto yy799; case 'N': + case 'n': goto yy803; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy802; case 'S': + case 's': goto yy801; case 'T': - case 'U': - case 'V': + case 't': goto yy69; + case 'V': goto yy795; case 'W': - case 'X': + case 'w': goto yy68; + case 'X': goto yy796; case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; + case 'y': goto yy67; + default: goto yy57; } -yy1310: +yy792: + YYDEBUG(792, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1311; - default: goto yy1106; + if (yych <= '/') goto yy939; + if (yych <= '0') goto yy931; + if (yych <= '2') goto yy932; + if (yych <= '3') goto yy933; + goto yy939; +yy793: + YYDEBUG(793, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= 'U') { + if (yych == 'I') goto yy930; + } else { + if (yych == 'W') goto yy794; + if (yych <= 'X') goto yy884; } -yy1311: +yy794: + YYDEBUG(794, *YYCURSOR); +#line 1383 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("datenodayrev"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_month((char **) &ptr); + s->time->d = 1; + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_DATE_NO_DAY; + } +#line 13027 "ext/date/lib/parse_date.c" +yy795: + YYDEBUG(795, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1312; - default: goto yy57; + if (yych == 'I') goto yy928; + goto yy794; +yy796: + YYDEBUG(796, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy927; + goto yy794; +yy797: + YYDEBUG(797, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'A') goto yy920; + if (yych <= 'T') goto yy57; + goto yy919; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy920; + } else { + if (yych == 'u') goto yy919; + goto yy57; + } } -yy1312: +yy798: + YYDEBUG(798, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1313; - default: goto yy57; + if (yych <= 'R') { + if (yych <= 'N') { + if (yych == 'E') goto yy913; + goto yy57; + } else { + if (yych <= 'O') goto yy99; + if (yych <= 'Q') goto yy57; + goto yy98; + } + } else { + if (yych <= 'n') { + if (yych == 'e') goto yy913; + goto yy57; + } else { + if (yych <= 'o') goto yy99; + if (yych == 'r') goto yy98; + goto yy57; + } } -yy1313: - yyaccept = 26; +yy799: + YYDEBUG(799, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= 'H') { + if (yych == 'A') goto yy910; + goto yy57; + } else { + if (yych <= 'I') goto yy118; + if (yych <= 'N') goto yy57; + goto yy117; + } + } else { + if (yych <= 'h') { + if (yych == 'a') goto yy910; + goto yy57; + } else { + if (yych <= 'i') goto yy118; + if (yych == 'o') goto yy117; + goto yy57; + } + } +yy800: + YYDEBUG(800, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'P') goto yy904; + if (yych <= 'T') goto yy57; + goto yy903; + } else { + if (yych <= 'p') { + if (yych <= 'o') goto yy57; + goto yy904; + } else { + if (yych == 'u') goto yy903; + goto yy57; + } + } +yy801: + YYDEBUG(801, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= 'D') { + if (yych == 'A') goto yy127; + goto yy57; + } else { + if (yych <= 'E') goto yy896; + if (yych <= 'T') goto yy57; + goto yy126; + } + } else { + if (yych <= 'd') { + if (yych == 'a') goto yy127; + goto yy57; + } else { + if (yych <= 'e') goto yy896; + if (yych == 'u') goto yy126; + goto yy57; + } + } +yy802: + YYDEBUG(802, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy891; + if (yych == 'c') goto yy891; + goto yy57; +yy803: + YYDEBUG(803, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy885; + if (yych == 'o') goto yy885; + goto yy57; +yy804: + YYDEBUG(804, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych == 'A') goto yy114; + if (yych <= 'D') goto yy57; + goto yy878; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy114; + } else { + if (yych == 'e') goto yy878; + goto yy57; + } + } +yy805: + YYDEBUG(805, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '0') goto yy875; + if (yych <= '9') goto yy876; + goto yy61; +yy806: + YYDEBUG(806, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '2') goto yy844; + if (yych <= '9') goto yy823; + goto yy61; +yy807: + YYDEBUG(807, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy824; + if (yych <= '1') goto yy825; + goto yy57; +yy808: + YYDEBUG(808, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy823; + goto yy61; +yy809: + YYDEBUG(809, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '5') goto yy819; + if (yych <= '6') goto yy820; + if (yych <= '9') goto yy55; + goto yy61; +yy810: + YYDEBUG(810, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '5') { + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy811; + if (yych <= '4') goto yy812; + goto yy813; + } else { + if (yych <= 'E') { + if (yych <= 'D') goto yy57; + goto yy83; + } else { + if (yych == 'e') goto yy83; + goto yy57; + } + } +yy811: + YYDEBUG(811, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '0') goto yy57; + if (yych <= '9') goto yy814; + goto yy57; +yy812: + YYDEBUG(812, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy814; + goto yy57; +yy813: + YYDEBUG(813, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '4') goto yy57; +yy814: + YYDEBUG(814, *YYCURSOR); + yyaccept = 17; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ' ': goto yy1314; - case 'S': - case 's': goto yy1143; - default: goto yy1118; + if (yych == '-') goto yy816; + if (yych <= '/') goto yy815; + if (yych <= '7') goto yy817; +yy815: + YYDEBUG(815, *YYCURSOR); +#line 1491 "ext/date/lib/parse_date.re" + { + timelib_sll w, d; + DEBUG_OUTPUT("isoweek"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + TIMELIB_HAVE_RELATIVE(); + + s->time->y = timelib_get_nr((char **) &ptr, 4); + w = timelib_get_nr((char **) &ptr, 2); + d = 1; + s->time->m = 1; + s->time->d = 1; + s->time->relative.d = timelib_daynr_from_weeknr(s->time->y, w, d); + + TIMELIB_DEINIT; + return TIMELIB_ISO_WEEK; } -yy1314: +#line 13260 "ext/date/lib/parse_date.c" +yy816: + YYDEBUG(816, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1315; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych >= '8') goto yy57; +yy817: + YYDEBUG(817, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(818, *YYCURSOR); +#line 1472 "ext/date/lib/parse_date.re" + { + timelib_sll w, d; + DEBUG_OUTPUT("isoweekday"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + TIMELIB_HAVE_RELATIVE(); + + s->time->y = timelib_get_nr((char **) &ptr, 4); + w = timelib_get_nr((char **) &ptr, 2); + d = timelib_get_nr((char **) &ptr, 1); + s->time->m = 1; + s->time->d = 1; + s->time->relative.d = timelib_daynr_from_weeknr(s->time->y, w, d); + + TIMELIB_DEINIT; + return TIMELIB_ISO_WEEK; } -yy1315: +#line 13288 "ext/date/lib/parse_date.c" +yy819: + YYDEBUG(819, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy821; + goto yy61; +yy820: + YYDEBUG(820, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '6') goto yy821; + if (yych <= '9') goto yy55; + goto yy61; +yy821: + YYDEBUG(821, *YYCURSOR); + yyaccept = 18; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 2) { + goto yy55; + } + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych >= ' ') goto yy61; + } else { + if (yych == 'D') goto yy61; + if (yych >= 'F') goto yy61; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy61; + if (yych >= 'M') goto yy61; + } else { + if (yych <= 'R') goto yy822; + if (yych <= 'T') goto yy61; + if (yych >= 'W') goto yy61; + } + } + } else { + if (yych <= 'h') { + if (yych <= 'd') { + if (yych == 'Y') goto yy61; + if (yych >= 'd') goto yy61; + } else { + if (yych == 'f') goto yy61; + if (yych >= 'h') goto yy61; + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych >= 's') goto yy61; + } else { + if (yych <= 'w') { + if (yych >= 'w') goto yy61; + } else { + if (yych == 'y') goto yy61; + } + } + } + } +yy822: + YYDEBUG(822, *YYCURSOR); +#line 1459 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("pgydotd"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->d = timelib_get_nr((char **) &ptr, 3); + s->time->m = 1; + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_PG_YEARDAY; + } +#line 13364 "ext/date/lib/parse_date.c" +yy823: + YYDEBUG(823, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy821; + goto yy61; +yy824: + YYDEBUG(824, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy826; + goto yy57; +yy825: + YYDEBUG(825, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '3') goto yy57; +yy826: + YYDEBUG(826, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(827, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy828; + if (yych <= '2') goto yy829; + if (yych <= '3') goto yy830; + goto yy57; +yy828: + YYDEBUG(828, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy831; + goto yy57; +yy829: + YYDEBUG(829, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy831; + goto yy57; +yy830: + YYDEBUG(830, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '2') goto yy57; +yy831: + YYDEBUG(831, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ' ') goto yy57; + YYDEBUG(832, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy833; + if (yych <= '2') goto yy834; + goto yy57; +yy833: + YYDEBUG(833, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy835; + goto yy57; +yy834: + YYDEBUG(834, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '5') goto yy57; +yy835: + YYDEBUG(835, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(836, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '6') goto yy57; + YYDEBUG(837, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(838, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(839, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy840; + if (yych <= '6') goto yy841; + goto yy57; +yy840: + YYDEBUG(840, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'F': - case 'f': goto yy1316; - default: goto yy57; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy842; + goto yy57; +yy841: + YYDEBUG(841, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '0') goto yy57; +yy842: + YYDEBUG(842, *YYCURSOR); + ++YYCURSOR; +yy843: + YYDEBUG(843, *YYCURSOR); +#line 1433 "ext/date/lib/parse_date.re" + { + int tz_not_found; + DEBUG_OUTPUT("xmlrpc | xmlrpcnocolon | soap | wddx | exif"); + TIMELIB_INIT; + TIMELIB_HAVE_TIME(); + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = timelib_get_nr((char **) &ptr, 2); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + s->time->s = timelib_get_nr((char **) &ptr, 2); + if (*ptr == '.') { + s->time->f = timelib_get_frac_nr((char **) &ptr, 9); + if (*ptr) { /* timezone is optional */ + s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); + if (tz_not_found) { + add_error(s, "The timezone could not be found in the database"); + } + } + } + TIMELIB_DEINIT; + return TIMELIB_XMLRPC_SOAP; } -yy1316: +#line 13492 "ext/date/lib/parse_date.c" +yy844: + YYDEBUG(844, *YYCURSOR); yych = *++YYCURSOR; - goto yy2; -yy1317: - yyaccept = 0; + if (yych <= '2') { + if (yych <= '/') goto yy61; + if (yych >= '1') goto yy846; + } else { + if (yych <= '3') goto yy847; + if (yych <= '9') goto yy821; + goto yy61; + } +yy845: + YYDEBUG(845, *YYCURSOR); + yyaccept = 18; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'S': goto yy1308; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 's': goto yy1318; - default: goto yy4; + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy822; + goto yy61; + } else { + if (yych <= '/') goto yy822; + if (yych <= '9') goto yy848; + if (yych <= 'C') goto yy822; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy822; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy822; + goto yy61; + } else { + if (yych <= 'R') goto yy822; + if (yych <= 'T') goto yy61; + goto yy822; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy822; + if (yych <= 'Y') goto yy61; + goto yy822; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy822; + } else { + if (yych == 'g') goto yy822; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy822; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy822; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy822; + } + } + } } -yy1318: - yyaccept = 0; +yy846: + YYDEBUG(846, *YYCURSOR); + yyaccept = 18; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1309; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1319; - default: goto yy4; + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy822; + goto yy61; + } else { + if (yych <= '/') goto yy822; + if (yych <= '9') goto yy848; + if (yych <= 'C') goto yy822; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy822; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy822; + goto yy61; + } else { + if (yych <= 'R') goto yy822; + if (yych <= 'T') goto yy61; + goto yy822; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy822; + if (yych <= 'Y') goto yy61; + goto yy822; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy822; + } else { + if (yych == 'g') goto yy822; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy822; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy822; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy822; + } + } + } } -yy1319: - yyaccept = 0; +yy847: + YYDEBUG(847, *YYCURSOR); + yyaccept = 18; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy1105; - case ' ': goto yy1310; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy822; + goto yy61; + } else { + if (yych <= '1') { + if (yych <= '/') goto yy822; + } else { + if (yych <= '9') goto yy55; + if (yych <= 'C') goto yy822; + goto yy61; + } + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy822; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy822; + goto yy61; + } else { + if (yych <= 'R') goto yy822; + if (yych <= 'T') goto yy61; + goto yy822; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy822; + if (yych <= 'Y') goto yy61; + goto yy822; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy822; + } else { + if (yych == 'g') goto yy822; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy822; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy822; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy822; + } + } + } } -yy1320: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'B': - case 'b': goto yy1356; - default: goto yy4; +yy848: + YYDEBUG(848, *YYCURSOR); + yyaccept = 19; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 2) { + goto yy55; } -yy1321: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'F': - case 'f': goto yy1346; - case 'R': - case 'r': goto yy1345; - default: goto yy4; + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy60; + if (yych >= ' ') goto yy60; + } else { + if (yych == 'D') goto yy65; + if (yych >= 'F') goto yy66; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy64; + if (yych >= 'M') goto yy63; + } else { + if (yych <= 'S') { + if (yych >= 'S') goto yy62; + } else { + if (yych <= 'T') goto yy850; + if (yych >= 'W') goto yy68; + } + } + } + } else { + if (yych <= 'l') { + if (yych <= 'd') { + if (yych == 'Y') goto yy67; + if (yych >= 'd') goto yy65; + } else { + if (yych <= 'f') { + if (yych >= 'f') goto yy66; + } else { + if (yych == 'h') goto yy64; + } + } + } else { + if (yych <= 't') { + if (yych <= 'm') goto yy63; + if (yych <= 'r') goto yy849; + if (yych <= 's') goto yy62; + goto yy851; + } else { + if (yych <= 'w') { + if (yych >= 'w') goto yy68; + } else { + if (yych == 'y') goto yy67; + } + } + } } -yy1322: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'U': - case 'u': goto yy1342; - default: goto yy4; +yy849: + YYDEBUG(849, *YYCURSOR); +#line 1421 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("datenocolon"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = timelib_get_nr((char **) &ptr, 2); + TIMELIB_DEINIT; + return TIMELIB_DATE_NOCOLON; } -yy1323: +#line 13765 "ext/date/lib/parse_date.c" +yy850: + YYDEBUG(850, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'I': - case 'i': goto yy1325; - case 'O': - case 'o': goto yy1324; - default: goto yy4; + if (yych <= 'H') { + if (yych <= '2') { + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy865; + goto yy866; + } else { + if (yych <= '9') goto yy867; + if (yych <= 'G') goto yy57; + goto yy70; + } + } else { + if (yych <= 'g') { + if (yych == 'U') goto yy71; + goto yy57; + } else { + if (yych <= 'h') goto yy70; + if (yych == 'u') goto yy71; + goto yy57; + } } -yy1324: +yy851: + YYDEBUG(851, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'N': - case 'n': goto yy1328; - default: goto yy4; + if (yych <= 'H') { + if (yych <= '2') { + if (yych <= '/') goto yy57; + if (yych >= '2') goto yy853; + } else { + if (yych <= '9') goto yy854; + if (yych <= 'G') goto yy57; + goto yy70; + } + } else { + if (yych <= 'g') { + if (yych == 'U') goto yy71; + goto yy57; + } else { + if (yych <= 'h') goto yy70; + if (yych == 'u') goto yy71; + goto yy57; + } } -yy1325: + YYDEBUG(852, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'D': - case 'd': goto yy1326; - default: goto yy167; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy859; + if (yych <= '9') goto yy854; + goto yy57; +yy853: + YYDEBUG(853, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '4') goto yy859; + if (yych <= '5') goto yy855; + goto yy57; +yy854: + YYDEBUG(854, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '6') goto yy57; +yy855: + YYDEBUG(855, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy856: + YYDEBUG(856, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy857; + if (yych <= '6') goto yy858; + goto yy57; +yy857: + YYDEBUG(857, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy842; + goto yy57; +yy858: + YYDEBUG(858, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '0') goto yy842; + goto yy57; +yy859: + YYDEBUG(859, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy860; + if (yych <= '9') goto yy856; + goto yy57; +yy860: + YYDEBUG(860, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy861; + if (yych <= '6') goto yy862; + if (yych <= '9') goto yy856; + goto yy57; +yy861: + YYDEBUG(861, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy863; + if (yych <= '6') goto yy864; + if (yych <= '9') goto yy842; + goto yy57; +yy862: + YYDEBUG(862, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy863; + if (yych <= '5') goto yy857; + if (yych <= '6') goto yy858; + goto yy57; +yy863: + YYDEBUG(863, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '9') goto yy842; + goto yy843; +yy864: + YYDEBUG(864, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '0') goto yy842; + goto yy843; +yy865: + YYDEBUG(865, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy874; + if (yych <= '9') goto yy867; + if (yych <= ':') goto yy868; + goto yy57; +yy866: + YYDEBUG(866, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '5') { + if (yych <= '/') goto yy57; + if (yych <= '4') goto yy874; + goto yy855; + } else { + if (yych == ':') goto yy868; + goto yy57; } -yy1326: +yy867: + YYDEBUG(867, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1327; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy855; + if (yych != ':') goto yy57; +yy868: + YYDEBUG(868, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= '6') goto yy57; + YYDEBUG(869, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(870, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(871, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy872; + if (yych <= '6') goto yy873; + goto yy57; +yy872: + YYDEBUG(872, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy842; + goto yy57; +yy873: + YYDEBUG(873, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '0') goto yy842; + goto yy57; +yy874: + YYDEBUG(874, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy860; + if (yych <= '9') goto yy856; + if (yych <= ':') goto yy868; + goto yy57; +yy875: + YYDEBUG(875, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '2') { + if (yych <= '/') goto yy61; + if (yych <= '0') goto yy877; + goto yy846; + } else { + if (yych <= '3') goto yy847; + if (yych <= '9') goto yy821; + goto yy61; } -yy1327: +yy876: + YYDEBUG(876, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '2') { + if (yych <= '/') goto yy61; + if (yych <= '0') goto yy845; + goto yy846; + } else { + if (yych <= '3') goto yy847; + if (yych <= '9') goto yy821; + goto yy61; + } +yy877: + YYDEBUG(877, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy848; + goto yy61; +yy878: + YYDEBUG(878, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy879; + if (yych != 'c') goto yy57; +yy879: + YYDEBUG(879, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'E') goto yy880; + if (yych != 'e') goto yy794; +yy880: + YYDEBUG(880, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy881; + if (yych != 'm') goto yy57; +yy881: + YYDEBUG(881, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy882; + if (yych != 'b') goto yy57; +yy882: + YYDEBUG(882, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy883; + if (yych != 'e') goto yy57; +yy883: + YYDEBUG(883, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy884; + if (yych != 'r') goto yy57; +yy884: + YYDEBUG(884, *YYCURSOR); + yych = *++YYCURSOR; + goto yy794; +yy885: + YYDEBUG(885, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'V') goto yy886; + if (yych != 'v') goto yy57; +yy886: + YYDEBUG(886, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'E') goto yy887; + if (yych != 'e') goto yy794; +yy887: + YYDEBUG(887, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy888; + if (yych != 'm') goto yy57; +yy888: + YYDEBUG(888, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy889; + if (yych != 'b') goto yy57; +yy889: + YYDEBUG(889, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy890; + if (yych != 'e') goto yy57; +yy890: + YYDEBUG(890, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy884; + if (yych == 'r') goto yy884; + goto yy57; +yy891: + YYDEBUG(891, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy892; + if (yych != 't') goto yy57; +yy892: + YYDEBUG(892, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'O') goto yy893; + if (yych != 'o') goto yy794; +yy893: + YYDEBUG(893, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy894; + if (yych != 'b') goto yy57; +yy894: + YYDEBUG(894, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy895; + if (yych != 'e') goto yy57; +yy895: + YYDEBUG(895, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy145; - case 'Y': - case 'y': goto yy1236; - default: goto yy4; + if (yych == 'R') goto yy884; + if (yych == 'r') goto yy884; + goto yy57; +yy896: + YYDEBUG(896, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'P') { + if (yych == 'C') goto yy129; + if (yych <= 'O') goto yy57; + } else { + if (yych <= 'c') { + if (yych <= 'b') goto yy57; + goto yy129; + } else { + if (yych != 'p') goto yy57; + } } -yy1328: +yy897: + YYDEBUG(897, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'T': - case 't': goto yy1329; - default: goto yy4; + if (yych == 'T') goto yy898; + if (yych != 't') goto yy794; +yy898: + YYDEBUG(898, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'E') goto yy899; + if (yych != 'e') goto yy794; +yy899: + YYDEBUG(899, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy900; + if (yych != 'm') goto yy57; +yy900: + YYDEBUG(900, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy901; + if (yych != 'b') goto yy57; +yy901: + YYDEBUG(901, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy902; + if (yych != 'e') goto yy57; +yy902: + YYDEBUG(902, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy884; + if (yych == 'r') goto yy884; + goto yy57; +yy903: + YYDEBUG(903, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy907; + if (yych == 'g') goto yy907; + goto yy57; +yy904: + YYDEBUG(904, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy905; + if (yych != 'r') goto yy57; +yy905: + YYDEBUG(905, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'I') goto yy906; + if (yych != 'i') goto yy794; +yy906: + YYDEBUG(906, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'L') goto yy884; + if (yych == 'l') goto yy884; + goto yy57; +yy907: + YYDEBUG(907, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'U') goto yy908; + if (yych != 'u') goto yy794; +yy908: + YYDEBUG(908, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy909; + if (yych != 's') goto yy57; +yy909: + YYDEBUG(909, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy884; + if (yych == 't') goto yy884; + goto yy57; +yy910: + YYDEBUG(910, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Y') { + if (yych == 'R') goto yy911; + if (yych <= 'X') goto yy57; + goto yy884; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy57; + } else { + if (yych == 'y') goto yy884; + goto yy57; + } } -yy1329: - yyaccept = 0; +yy911: + YYDEBUG(911, *YYCURSOR); + yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ' ': goto yy1330; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; + if (yych == 'C') goto yy912; + if (yych != 'c') goto yy794; +yy912: + YYDEBUG(912, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy884; + if (yych == 'h') goto yy884; + goto yy57; +yy913: + YYDEBUG(913, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy914; + if (yych != 'b') goto yy57; +yy914: + YYDEBUG(914, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'R') goto yy915; + if (yych != 'r') goto yy794; +yy915: + YYDEBUG(915, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'U') goto yy916; + if (yych != 'u') goto yy57; +yy916: + YYDEBUG(916, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy917; + if (yych != 'a') goto yy57; +yy917: + YYDEBUG(917, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy918; + if (yych != 'r') goto yy57; +yy918: + YYDEBUG(918, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy884; + if (yych == 'y') goto yy884; + goto yy57; +yy919: + YYDEBUG(919, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych == 'L') goto yy926; + if (yych <= 'M') goto yy57; + goto yy925; + } else { + if (yych <= 'l') { + if (yych <= 'k') goto yy57; + goto yy926; + } else { + if (yych == 'n') goto yy925; + goto yy57; + } } -yy1330: +yy920: + YYDEBUG(920, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy921; + if (yych != 'n') goto yy57; +yy921: + YYDEBUG(921, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'U') goto yy922; + if (yych != 'u') goto yy794; +yy922: + YYDEBUG(922, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy923; + if (yych != 'a') goto yy57; +yy923: + YYDEBUG(923, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy924; + if (yych != 'r') goto yy57; +yy924: + YYDEBUG(924, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy884; + if (yych == 'y') goto yy884; + goto yy57; +yy925: + YYDEBUG(925, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy884; + if (yych == 'e') goto yy884; + goto yy794; +yy926: + YYDEBUG(926, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy884; + if (yych == 'y') goto yy884; + goto yy794; +yy927: + YYDEBUG(927, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy884; + goto yy794; +yy928: + YYDEBUG(928, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != 'I') goto yy794; + YYDEBUG(929, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy884; + goto yy794; +yy930: + YYDEBUG(930, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy884; + goto yy794; +yy931: + YYDEBUG(931, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy946; + if (yych <= '9') goto yy945; + goto yy57; +yy932: + YYDEBUG(932, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy944; + goto yy57; +yy933: + YYDEBUG(933, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy942; + if (yych <= '6') goto yy941; + goto yy57; +yy934: + YYDEBUG(934, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1331; - default: goto yy57; - } -yy1331: + if (yych == 'E') goto yy913; + if (yych == 'e') goto yy913; + goto yy57; +yy935: + YYDEBUG(935, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy910; + if (yych == 'a') goto yy910; + goto yy57; +yy936: + YYDEBUG(936, *YYCURSOR); yych = *++YYCURSOR; + if (yych == 'E') goto yy940; + if (yych == 'e') goto yy940; + goto yy57; +yy937: + YYDEBUG(937, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy878; + if (yych == 'e') goto yy878; + goto yy57; +yy938: + YYDEBUG(938, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; +yy939: + YYDEBUG(939, *YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { + case '\t': + case ' ': + case '-': + case '.': goto yy938; + case 'A': + case 'a': goto yy800; + case 'D': + case 'd': goto yy937; case 'F': - case 'f': goto yy1332; + case 'f': goto yy934; + case 'I': goto yy793; + case 'J': + case 'j': goto yy797; + case 'M': + case 'm': goto yy935; + case 'N': + case 'n': goto yy803; + case 'O': + case 'o': goto yy802; + case 'S': + case 's': goto yy936; + case 'V': goto yy795; + case 'X': goto yy796; default: goto yy57; } -yy1332: +yy940: + YYDEBUG(940, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ' ': goto yy1333; - default: goto yy57; + if (yych == 'P') goto yy897; + if (yych == 'p') goto yy897; + goto yy57; +yy941: + YYDEBUG(941, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '6') goto yy943; + goto yy57; +yy942: + YYDEBUG(942, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy943: + YYDEBUG(943, *YYCURSOR); + yych = *++YYCURSOR; + goto yy822; +yy944: + YYDEBUG(944, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy943; + goto yy57; +yy945: + YYDEBUG(945, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy943; + goto yy57; +yy946: + YYDEBUG(946, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '0') goto yy57; + if (yych <= '9') goto yy943; + goto yy57; +yy947: + YYDEBUG(947, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') goto yy57; + if (yych <= '/') goto yy950; + if (yych <= '9') goto yy958; + goto yy57; +yy948: + YYDEBUG(948, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') goto yy57; + if (yych <= '/') goto yy950; + if (yych <= '2') goto yy958; + goto yy57; +yy949: + YYDEBUG(949, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '/') goto yy57; +yy950: + YYDEBUG(950, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy951; + if (yych <= '3') goto yy952; + if (yych <= '9') goto yy953; + goto yy57; +yy951: + YYDEBUG(951, *YYCURSOR); + yyaccept = 21; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy455; + if (yych <= '9') goto yy953; + if (yych <= 'm') goto yy455; + goto yy955; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy956; + } else { + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; + } + } +yy952: + YYDEBUG(952, *YYCURSOR); + yyaccept = 21; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy455; + if (yych <= '1') goto yy953; + if (yych <= 'm') goto yy455; + goto yy955; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy956; + } else { + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; + } + } +yy953: + YYDEBUG(953, *YYCURSOR); + yyaccept = 21; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'q') { + if (yych == 'n') goto yy955; + goto yy455; + } else { + if (yych <= 'r') goto yy956; + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; } -yy1333: +yy954: + YYDEBUG(954, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': goto yy1334; - case '2': goto yy1335; - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1336; - default: goto yy57; + if (yych == 't') goto yy454; + goto yy57; +yy955: + YYDEBUG(955, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy454; + goto yy57; +yy956: + YYDEBUG(956, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy454; + goto yy57; +yy957: + YYDEBUG(957, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'h') goto yy454; + goto yy57; +yy958: + YYDEBUG(958, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '/') goto yy57; + YYDEBUG(959, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '2') { + if (yych <= '/') goto yy57; + if (yych >= '1') goto yy961; + } else { + if (yych <= '3') goto yy962; + if (yych <= '9') goto yy953; + goto yy57; } -yy1334: - yyaccept = 28; + YYDEBUG(960, *YYCURSOR); + yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1336; - default: goto yy1337; + if (yych <= 'n') { + if (yych <= '/') goto yy455; + if (yych <= '9') goto yy963; + if (yych <= 'm') goto yy455; + goto yy955; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy956; + } else { + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; + } } -yy1335: - yyaccept = 28; +yy961: + YYDEBUG(961, *YYCURSOR); + yyaccept = 21; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': goto yy1336; - default: goto yy1337; + if (yych <= 'n') { + if (yych <= '/') goto yy455; + if (yych <= '9') goto yy963; + if (yych <= 'm') goto yy455; + goto yy955; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy956; + } else { + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; + } } -yy1336: - yyaccept = 28; - YYMARKER = ++YYCURSOR; - if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); - yych = *YYCURSOR; -yy1337: - switch (yych) { - case '\t': - case ' ': goto yy1336; - case 'A': - case 'P': - case 'a': - case 'p': goto yy1338; - default: goto yy1295; +yy962: + YYDEBUG(962, *YYCURSOR); + yyaccept = 21; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy455; + if (yych <= '1') goto yy963; + if (yych <= 'm') goto yy455; + goto yy955; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy956; + } else { + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; + } } -yy1338: - yych = *++YYCURSOR; - switch (yych) { - case '.': goto yy1339; - case 'M': - case 'm': goto yy1340; - default: goto yy57; +yy963: + YYDEBUG(963, *YYCURSOR); + yyaccept = 21; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych == '/') goto yy454; + if (yych <= 'm') goto yy455; + goto yy955; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy956; + } else { + if (yych <= 's') goto yy954; + if (yych <= 't') goto yy957; + goto yy455; + } } -yy1339: +yy964: + YYDEBUG(964, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'M': - case 'm': goto yy1340; - default: goto yy57; + if (yych <= 'U') { + if (yych == 'A') goto yy1044; + if (yych <= 'T') goto yy57; + goto yy1043; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy57; + goto yy1044; + } else { + if (yych == 'u') goto yy1043; + goto yy57; + } } -yy1340: +yy965: + YYDEBUG(965, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy1303; - case '.': goto yy1341; - default: goto yy57; - } -yy1341: + if (yych == 'E') goto yy1041; + if (yych == 'e') goto yy1041; + goto yy57; +yy966: + YYDEBUG(966, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 0x00: - case '\t': - case ' ': goto yy1303; - default: goto yy57; + if (yych == 'A') goto yy1038; + if (yych == 'a') goto yy1038; + goto yy57; +yy967: + YYDEBUG(967, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'P') goto yy1035; + if (yych <= 'T') goto yy57; + goto yy1034; + } else { + if (yych <= 'p') { + if (yych <= 'o') goto yy57; + goto yy1035; + } else { + if (yych == 'u') goto yy1034; + goto yy57; + } } -yy1342: +yy968: + YYDEBUG(968, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'R': - case 'r': goto yy1343; - default: goto yy4; + if (yych == 'E') goto yy1031; + if (yych == 'e') goto yy1031; + goto yy57; +yy969: + YYDEBUG(969, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy1029; + if (yych == 'c') goto yy1029; + goto yy57; +yy970: + YYDEBUG(970, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy1027; + if (yych == 'o') goto yy1027; + goto yy57; +yy971: + YYDEBUG(971, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1025; + if (yych == 'e') goto yy1025; + goto yy57; +yy972: + YYDEBUG(972, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '0') goto yy811; + if (yych <= '4') goto yy812; + if (yych <= '5') goto yy813; + goto yy57; +yy973: + YYDEBUG(973, *YYCURSOR); + yyaccept = 22; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '-') goto yy977; + if (yych <= '/') goto yy974; + if (yych <= '9') goto yy996; +yy974: + YYDEBUG(974, *YYCURSOR); +#line 1305 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("gnudateshorter"); + TIMELIB_INIT; + TIMELIB_HAVE_DATE(); + s->time->y = timelib_get_nr((char **) &ptr, 4); + s->time->m = timelib_get_nr((char **) &ptr, 2); + s->time->d = 1; + TIMELIB_PROCESS_YEAR(s->time->y); + TIMELIB_DEINIT; + return TIMELIB_ISO_DATE; } -yy1343: +#line 14697 "ext/date/lib/parse_date.c" +yy975: + YYDEBUG(975, *YYCURSOR); + yyaccept = 22; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '-') goto yy977; + if (yych <= '/') goto yy974; + if (yych <= '2') goto yy996; + goto yy974; +yy976: + YYDEBUG(976, *YYCURSOR); + yyaccept = 22; + yych = *(YYMARKER = ++YYCURSOR); + if (yych != '-') goto yy974; +yy977: + YYDEBUG(977, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'T': - case 't': goto yy1344; - default: goto yy4; + if (yych <= '/') goto yy57; + if (yych <= '2') goto yy978; + if (yych <= '3') goto yy979; + if (yych <= '9') goto yy980; + goto yy57; +yy978: + YYDEBUG(978, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '9') { + if (yych <= '/') goto yy657; + goto yy980; + } else { + if (yych == 'T') goto yy985; + goto yy657; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy982; + if (yych <= 'q') goto yy657; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy657; + } } -yy1344: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'H': - case 'h': goto yy1216; - default: goto yy4; +yy979: + YYDEBUG(979, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy657; + } else { + if (yych == 'T') goto yy985; + goto yy657; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy982; + if (yych <= 'q') goto yy657; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy657; + } } -yy1345: +yy980: + YYDEBUG(980, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych == 'T') goto yy985; + if (yych <= 'm') goto yy657; + goto yy982; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy657; + } + } +yy981: + YYDEBUG(981, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'S': - case 's': goto yy1348; - default: goto yy4; + if (yych == 't') goto yy995; + goto yy57; +yy982: + YYDEBUG(982, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy995; + goto yy57; +yy983: + YYDEBUG(983, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'd') goto yy995; + goto yy57; +yy984: + YYDEBUG(984, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'h') goto yy995; + goto yy57; +yy985: + YYDEBUG(985, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy986; + if (yych <= '2') goto yy987; + if (yych <= '9') goto yy988; + goto yy57; +yy986: + YYDEBUG(986, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy988; + if (yych <= ':') goto yy989; + goto yy57; +yy987: + YYDEBUG(987, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '4') goto yy988; + if (yych == ':') goto yy989; + goto yy57; +yy988: + YYDEBUG(988, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; +yy989: + YYDEBUG(989, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy990; + if (yych <= '9') goto yy991; + goto yy57; +yy990: + YYDEBUG(990, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy991; + if (yych <= ':') goto yy992; + goto yy57; +yy991: + YYDEBUG(991, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; +yy992: + YYDEBUG(992, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy993; + if (yych <= '6') goto yy994; + if (yych <= '9') goto yy842; + goto yy57; +yy993: + YYDEBUG(993, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '9') goto yy842; + goto yy843; +yy994: + YYDEBUG(994, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '0') goto yy842; + goto yy843; +yy995: + YYDEBUG(995, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == 'T') goto yy985; + goto yy657; +yy996: + YYDEBUG(996, *YYCURSOR); + yyaccept = 22; + yych = *(YYMARKER = ++YYCURSOR); + if (yych != '-') goto yy974; + YYDEBUG(997, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '2') { + if (yych <= '/') goto yy57; + if (yych >= '1') goto yy999; + } else { + if (yych <= '3') goto yy1000; + if (yych <= '9') goto yy980; + goto yy57; + } + YYDEBUG(998, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '9') { + if (yych <= '/') goto yy657; + goto yy1001; + } else { + if (yych == 'T') goto yy985; + goto yy657; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy982; + if (yych <= 'q') goto yy657; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy657; + } + } +yy999: + YYDEBUG(999, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '9') { + if (yych <= '/') goto yy657; + goto yy1001; + } else { + if (yych == 'T') goto yy985; + goto yy657; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy982; + if (yych <= 'q') goto yy657; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy657; + } + } +yy1000: + YYDEBUG(1000, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'm') { + if (yych <= '1') { + if (yych <= '/') goto yy657; + } else { + if (yych == 'T') goto yy985; + goto yy657; + } + } else { + if (yych <= 'r') { + if (yych <= 'n') goto yy982; + if (yych <= 'q') goto yy657; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy657; + } + } +yy1001: + YYDEBUG(1001, *YYCURSOR); + yyaccept = 21; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych == 'T') goto yy1002; + if (yych <= 'm') goto yy455; + goto yy982; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy455; + goto yy983; + } else { + if (yych <= 's') goto yy981; + if (yych <= 't') goto yy984; + goto yy455; + } } -yy1346: +yy1002: + YYDEBUG(1002, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1347; - default: goto yy4; - } -yy1347: + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy1003; + if (yych <= '2') goto yy1004; + if (yych <= '9') goto yy988; + goto yy57; +yy1003: + YYDEBUG(1003, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'H': - case 'h': goto yy1239; - default: goto yy4; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy1005; + if (yych <= ':') goto yy989; + goto yy57; +yy1004: + YYDEBUG(1004, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '4') goto yy1005; + if (yych == ':') goto yy989; + goto yy57; +yy1005: + YYDEBUG(1005, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(1006, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy1007; + if (yych <= '9') goto yy991; + goto yy57; +yy1007: + YYDEBUG(1007, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy1008; + if (yych <= ':') goto yy992; + goto yy57; +yy1008: + YYDEBUG(1008, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ':') goto yy57; + YYDEBUG(1009, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy1010; + if (yych <= '6') goto yy1011; + if (yych <= '9') goto yy842; + goto yy57; +yy1010: + YYDEBUG(1010, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '9') goto yy1012; + goto yy843; +yy1011: + YYDEBUG(1011, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '0') goto yy843; +yy1012: + YYDEBUG(1012, *YYCURSOR); + yyaccept = 23; + yych = *(YYMARKER = ++YYCURSOR); + if (yych != '.') goto yy843; + YYDEBUG(1013, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy1014: + YYDEBUG(1014, *YYCURSOR); + yyaccept = 23; + YYMARKER = ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 9) YYFILL(9); + yych = *YYCURSOR; + YYDEBUG(1015, *YYCURSOR); + if (yych <= '-') { + if (yych == '+') goto yy1017; + if (yych <= ',') goto yy843; + goto yy1017; + } else { + if (yych <= '9') { + if (yych <= '/') goto yy843; + goto yy1014; + } else { + if (yych != 'G') goto yy843; + } } -yy1348: + YYDEBUG(1016, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'T': - case 't': goto yy1349; - default: goto yy4; + if (yych == 'M') goto yy1023; + goto yy57; +yy1017: + YYDEBUG(1017, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy1018; + if (yych <= '2') goto yy1019; + if (yych <= '9') goto yy1020; + goto yy57; +yy1018: + YYDEBUG(1018, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '9') goto yy1020; + if (yych <= ':') goto yy1021; + goto yy843; +yy1019: + YYDEBUG(1019, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '5') { + if (yych <= '/') goto yy843; + if (yych >= '5') goto yy1022; + } else { + if (yych <= '9') goto yy842; + if (yych <= ':') goto yy1021; + goto yy843; } -yy1349: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy1207; - case ' ': goto yy1350; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; +yy1020: + YYDEBUG(1020, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '5') goto yy1022; + if (yych <= '9') goto yy842; + if (yych >= ';') goto yy843; +yy1021: + YYDEBUG(1021, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '5') goto yy1022; + if (yych <= '9') goto yy842; + goto yy843; +yy1022: + YYDEBUG(1022, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy843; + if (yych <= '9') goto yy842; + goto yy843; +yy1023: + YYDEBUG(1023, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != 'T') goto yy57; + YYDEBUG(1024, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '+') goto yy1017; + if (yych == '-') goto yy1017; + goto yy57; +yy1025: + YYDEBUG(1025, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy1026; + if (yych != 'c') goto yy57; +yy1026: + YYDEBUG(1026, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'E') goto yy880; + if (yych == 'e') goto yy880; + goto yy794; } -yy1350: +yy1027: + YYDEBUG(1027, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'D': - case 'd': goto yy1351; - default: goto yy1208; + if (yych == 'V') goto yy1028; + if (yych != 'v') goto yy57; +yy1028: + YYDEBUG(1028, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'E') goto yy887; + if (yych == 'e') goto yy887; + goto yy794; } -yy1351: +yy1029: + YYDEBUG(1029, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1352; - default: goto yy57; + if (yych == 'T') goto yy1030; + if (yych != 't') goto yy57; +yy1030: + YYDEBUG(1030, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'O') goto yy893; + if (yych == 'o') goto yy893; + goto yy794; } -yy1352: +yy1031: + YYDEBUG(1031, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1353; - default: goto yy57; + if (yych == 'P') goto yy1032; + if (yych != 'p') goto yy57; +yy1032: + YYDEBUG(1032, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'T') goto yy1033; + if (yych != 't') goto yy794; } -yy1353: - yyaccept = 26; +yy1033: + YYDEBUG(1033, *YYCURSOR); + yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ' ': goto yy1354; - case 'S': - case 's': goto yy1143; - default: goto yy1118; + if (yych <= 'D') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'E') goto yy899; + if (yych == 'e') goto yy899; + goto yy794; } -yy1354: +yy1034: + YYDEBUG(1034, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'O': - case 'o': goto yy1355; - default: goto yy57; + if (yych == 'G') goto yy1037; + if (yych == 'g') goto yy1037; + goto yy57; +yy1035: + YYDEBUG(1035, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy1036; + if (yych != 'r') goto yy57; +yy1036: + YYDEBUG(1036, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'H') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'I') goto yy906; + if (yych == 'i') goto yy906; + goto yy794; } -yy1355: +yy1037: + YYDEBUG(1037, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'T') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'U') goto yy908; + if (yych == 'u') goto yy908; + goto yy794; + } +yy1038: + YYDEBUG(1038, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'F': - case 'f': goto yy1316; - default: goto yy57; + if (yych <= 'Y') { + if (yych == 'R') goto yy1039; + if (yych <= 'X') goto yy57; + goto yy1040; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy57; + } else { + if (yych == 'y') goto yy1040; + goto yy57; + } } -yy1356: - yyaccept = 5; +yy1039: + YYDEBUG(1039, *YYCURSOR); + yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'R': - case 'r': goto yy1357; - default: goto yy194; + if (yych <= 'B') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'C') goto yy912; + if (yych == 'c') goto yy912; + goto yy794; } -yy1357: +yy1040: + YYDEBUG(1040, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '-') goto yy767; + goto yy794; +yy1041: + YYDEBUG(1041, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'U': - case 'u': goto yy1358; - default: goto yy4; + if (yych == 'B') goto yy1042; + if (yych != 'b') goto yy57; +yy1042: + YYDEBUG(1042, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'Q') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'R') goto yy915; + if (yych == 'r') goto yy915; + goto yy794; } -yy1358: +yy1043: + YYDEBUG(1043, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1359; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; + if (yych <= 'N') { + if (yych == 'L') goto yy1047; + if (yych <= 'M') goto yy57; + goto yy1046; + } else { + if (yych <= 'l') { + if (yych <= 'k') goto yy57; + goto yy1047; + } else { + if (yych == 'n') goto yy1046; + goto yy57; + } } -yy1359: - yyaccept = 0; +yy1044: + YYDEBUG(1044, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy1045; + if (yych != 'n') goto yy57; +yy1045: + YYDEBUG(1045, *YYCURSOR); + yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'R': - case 'r': goto yy1360; - default: goto yy4; + if (yych <= 'T') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'U') goto yy922; + if (yych == 'u') goto yy922; + goto yy794; } -yy1360: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy206; - default: goto yy57; +yy1046: + YYDEBUG(1046, *YYCURSOR); + yyaccept = 20; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'E') goto yy884; + if (yych == 'e') goto yy884; + goto yy794; } -yy1361: - yyaccept = 0; +yy1047: + YYDEBUG(1047, *YYCURSOR); + yyaccept = 20; yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych == '-') goto yy767; + goto yy794; + } else { + if (yych <= 'Y') goto yy884; + if (yych == 'y') goto yy884; + goto yy794; + } +yy1048: + YYDEBUG(1048, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy578; + goto yy731; + } else { + if (yych <= ',') goto yy578; + if (yych <= '-') goto yy732; + goto yy731; + } + } else { + if (yych <= 'U') { + if (yych <= '/') goto yy730; + if (yych <= 'T') goto yy578; + goto yy78; + } else { + if (yych == 'u') goto yy78; + goto yy578; + } + } +yy1049: + YYDEBUG(1049, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'P') { + if (yych == 'C') goto yy129; + if (yych <= 'O') goto yy57; + goto yy586; + } else { + if (yych <= 'c') { + if (yych <= 'b') goto yy57; + goto yy129; + } else { + if (yych == 'p') goto yy586; + goto yy57; + } + } +yy1050: + YYDEBUG(1050, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '9') { + if (yych <= ',') { + if (yych == '\t') goto yy1052; + goto yy1054; + } else { + if (yych <= '-') goto yy1051; + if (yych <= '.') goto yy731; + if (yych <= '/') goto yy730; + goto yy741; + } + } else { + if (yych <= 'q') { + if (yych == 'n') goto yy470; + goto yy1054; + } else { + if (yych <= 'r') goto yy471; + if (yych <= 's') goto yy464; + if (yych <= 't') goto yy468; + goto yy1054; + } + } +yy1051: + YYDEBUG(1051, *YYCURSOR); + yych = *++YYCURSOR; + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; + case '0': goto yy1055; + case '1': goto yy1056; + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': goto yy618; case 'A': - case 'C': + case 'a': goto yy622; case 'D': - case 'E': + case 'd': goto yy626; case 'F': - case 'G': - case 'H': - case 'I': + case 'f': goto yy620; case 'J': - case 'K': - case 'L': + case 'j': goto yy619; case 'M': + case 'm': goto yy621; case 'N': + case 'n': goto yy625; case 'O': - case 'P': - case 'Q': - case 'R': + case 'o': goto yy624; case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'B': goto yy1356; - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'b': goto yy1379; - default: goto yy4; + case 's': goto yy623; + default: goto yy578; } -yy1362: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); +yy1052: + YYDEBUG(1052, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy1054; + if (yych <= '0') goto yy736; + if (yych <= '1') goto yy737; + if (yych <= '9') goto yy738; + goto yy1054; +yy1053: + YYDEBUG(1053, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 13) YYFILL(13); + yych = *YYCURSOR; +yy1054: + YYDEBUG(1054, *YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; + case '\t': + case ' ': goto yy1053; case '-': - case '/': - case '_': goto yy148; + case '.': goto yy577; case 'A': - case 'B': - case 'C': + case 'a': goto yy574; case 'D': - case 'E': - case 'G': + case 'd': goto yy466; + case 'F': + case 'f': goto yy467; case 'H': - case 'I': + case 'h': goto yy64; + case 'I': goto yy475; case 'J': - case 'K': - case 'L': + case 'j': goto yy479; case 'M': + case 'm': goto yy465; case 'N': + case 'n': goto yy482; case 'O': - case 'P': - case 'Q': + case 'o': goto yy481; case 'S': + case 's': goto yy463; case 'T': - case 'U': - case 'V': + case 't': goto yy69; + case 'V': goto yy477; case 'W': - case 'X': + case 'w': goto yy68; + case 'X': goto yy478; case 'Y': - case 'Z': goto yy142; - case 'F': goto yy1346; - case 'R': goto yy1345; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'f': goto yy1375; - case 'r': goto yy1374; - default: goto yy4; + case 'y': goto yy67; + default: goto yy57; } -yy1363: - yyaccept = 0; +yy1055: + YYDEBUG(1055, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') { + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy655; + goto yy602; + } else { + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy1057; + goto yy57; + } +yy1056: + YYDEBUG(1056, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '.') { + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy655; + goto yy602; + } else { + if (yych <= '/') goto yy57; + if (yych >= '3') goto yy57; + } +yy1057: + YYDEBUG(1057, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= ',') goto yy57; + if (yych <= '-') goto yy1058; + if (yych <= '.') goto yy602; + goto yy57; +yy1058: + YYDEBUG(1058, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '2') { + if (yych <= '/') goto yy57; + if (yych >= '1') goto yy1060; + } else { + if (yych <= '3') goto yy1061; + if (yych <= '9') goto yy659; + goto yy57; + } + YYDEBUG(1059, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy1062; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy1060: + YYDEBUG(1060, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy657; + if (yych <= '9') goto yy1062; + if (yych <= 'm') goto yy657; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy1061: + YYDEBUG(1061, *YYCURSOR); + yyaccept = 13; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '1') { + if (yych <= '/') goto yy657; + } else { + if (yych <= '9') goto yy604; + if (yych <= 'm') goto yy657; + goto yy661; + } + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy657; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy657; + } + } +yy1062: + YYDEBUG(1062, *YYCURSOR); + yyaccept = 15; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'n') { + if (yych <= '/') goto yy764; + if (yych <= '9') goto yy605; + if (yych <= 'm') goto yy764; + goto yy661; + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy764; + goto yy662; + } else { + if (yych <= 's') goto yy660; + if (yych <= 't') goto yy663; + goto yy764; + } + } +yy1063: + YYDEBUG(1063, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '9') { + if (yych <= '-') { + if (yych == '\t') goto yy1052; + if (yych <= ',') goto yy1054; + goto yy1051; + } else { + if (yych <= '.') goto yy1064; + if (yych <= '/') goto yy730; + if (yych <= '5') goto yy1066; + goto yy741; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy1065; + if (yych == 'n') goto yy470; + goto yy1054; + } else { + if (yych <= 'r') goto yy471; + if (yych <= 's') goto yy464; + if (yych <= 't') goto yy468; + goto yy1054; + } + } +yy1064: + YYDEBUG(1064, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '1') { + if (yych <= '/') goto yy578; + if (yych <= '0') goto yy1088; + goto yy1089; + } else { + if (yych <= '5') goto yy1090; + if (yych <= '9') goto yy1091; + goto yy578; + } +yy1065: + YYDEBUG(1065, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy1083; + if (yych <= '9') goto yy1084; + goto yy57; +yy1066: + YYDEBUG(1066, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '-') goto yy785; + if (yych <= '/') goto yy61; + if (yych >= ':') goto yy61; + YYDEBUG(1067, *YYCURSOR); + yyaccept = 24; yych = *(YYMARKER = ++YYCURSOR); + YYDEBUG(-1, yych); switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; + case '\t': + case ' ': case 'A': - case 'B': - case 'C': case 'D': - case 'E': case 'F': - case 'G': case 'H': case 'I': case 'J': - case 'K': - case 'L': case 'M': case 'N': case 'O': - case 'P': - case 'Q': - case 'R': case 'S': case 'T': case 'V': - case 'W': case 'X': case 'Y': - case 'Z': goto yy142; - case 'U': goto yy1342; - case 'a': - case 'b': - case 'c': + case 'a': case 'd': - case 'e': case 'f': - case 'g': case 'h': - case 'i': case 'j': - case 'k': - case 'l': case 'm': case 'n': case 'o': - case 'p': - case 'q': - case 'r': case 's': case 't': - case 'v': case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'u': goto yy1371; - default: goto yy4; + case 'y': goto yy791; + case '-': goto yy788; + case '.': goto yy792; + case '/': goto yy789; + case '0': goto yy1069; + case '1': goto yy1070; + case '2': goto yy1071; + case '3': goto yy1072; + case '4': + case '5': goto yy1073; + case '6': goto yy1074; + case '7': + case '8': + case '9': goto yy55; + case ':': goto yy807; + case 'W': goto yy810; + default: goto yy1068; + } +yy1068: + YYDEBUG(1068, *YYCURSOR); +#line 1199 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("gnunocolon"); + TIMELIB_INIT; + switch (s->time->have_time) { + case 0: + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + s->time->s = 0; + break; + case 1: + s->time->y = timelib_get_nr((char **) &ptr, 4); + break; + default: + TIMELIB_DEINIT; + add_error(s, "Double time specification"); + return TIMELIB_ERROR; + } + s->time->have_time++; + TIMELIB_DEINIT; + return TIMELIB_GNU_NOCOLON; + } +#line 15728 "ext/date/lib/parse_date.c" +yy1069: + YYDEBUG(1069, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '0') goto yy1081; + if (yych <= '9') goto yy1082; + goto yy61; +yy1070: + YYDEBUG(1070, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '2') goto yy1080; + if (yych <= '9') goto yy1079; + goto yy61; +yy1071: + YYDEBUG(1071, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy1079; + goto yy61; +yy1072: + YYDEBUG(1072, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '5') goto yy1077; + if (yych <= '6') goto yy1078; + if (yych <= '9') goto yy1075; + goto yy61; +yy1073: + YYDEBUG(1073, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '9') goto yy1075; + goto yy61; +yy1074: + YYDEBUG(1074, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy61; + if (yych <= '0') goto yy1075; + if (yych <= '9') goto yy55; + goto yy61; +yy1075: + YYDEBUG(1075, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 2) { + goto yy55; + } + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych >= ' ') goto yy61; + } else { + if (yych == 'D') goto yy61; + if (yych >= 'F') goto yy61; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy61; + if (yych >= 'M') goto yy61; + } else { + if (yych <= 'R') goto yy1076; + if (yych <= 'T') goto yy61; + if (yych >= 'W') goto yy61; + } + } + } else { + if (yych <= 'h') { + if (yych <= 'd') { + if (yych == 'Y') goto yy61; + if (yych >= 'd') goto yy61; + } else { + if (yych == 'f') goto yy61; + if (yych >= 'h') goto yy61; + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych >= 's') goto yy61; + } else { + if (yych <= 'w') { + if (yych >= 'w') goto yy61; + } else { + if (yych == 'y') goto yy61; + } + } + } + } +yy1076: + YYDEBUG(1076, *YYCURSOR); +#line 1245 "ext/date/lib/parse_date.re" + { + int tz_not_found; + DEBUG_OUTPUT("iso8601nocolon"); + TIMELIB_INIT; + TIMELIB_HAVE_TIME(); + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = timelib_get_nr((char **) &ptr, 2); + s->time->s = timelib_get_nr((char **) &ptr, 2); + + if (*ptr != '\0') { + s->time->z = timelib_get_zone((char **) &ptr, &s->time->dst, s->time, &tz_not_found, s->tzdb); + if (tz_not_found) { + add_error(s, "The timezone could not be found in the database"); + } + } + TIMELIB_DEINIT; + return TIMELIB_ISO_NOCOLON; + } +#line 15839 "ext/date/lib/parse_date.c" +yy1077: + YYDEBUG(1077, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy1076; + goto yy61; + } else { + if (yych <= '/') goto yy1076; + if (yych <= '9') goto yy821; + if (yych <= 'C') goto yy1076; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy1076; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy1076; + goto yy61; + } else { + if (yych <= 'R') goto yy1076; + if (yych <= 'T') goto yy61; + goto yy1076; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy1076; + if (yych <= 'Y') goto yy61; + goto yy1076; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy1076; + } else { + if (yych == 'g') goto yy1076; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy1076; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy1076; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy1076; + } + } + } + } +yy1078: + YYDEBUG(1078, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy1076; + goto yy61; + } else { + if (yych <= '6') { + if (yych <= '/') goto yy1076; + goto yy821; + } else { + if (yych <= '9') goto yy55; + if (yych <= 'C') goto yy1076; + goto yy61; + } + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy1076; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy1076; + goto yy61; + } else { + if (yych <= 'R') goto yy1076; + if (yych <= 'T') goto yy61; + goto yy1076; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy1076; + if (yych <= 'Y') goto yy61; + goto yy1076; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy1076; + } else { + if (yych == 'g') goto yy1076; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy1076; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy1076; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy1076; + } + } + } + } +yy1079: + YYDEBUG(1079, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'V') { + if (yych <= 'D') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy1076; + goto yy61; + } else { + if (yych <= '/') goto yy1076; + if (yych <= '9') goto yy821; + if (yych <= 'C') goto yy1076; + goto yy61; + } + } else { + if (yych <= 'H') { + if (yych == 'F') goto yy61; + if (yych <= 'G') goto yy1076; + goto yy61; + } else { + if (yych <= 'M') { + if (yych <= 'L') goto yy1076; + goto yy61; + } else { + if (yych <= 'R') goto yy1076; + if (yych <= 'T') goto yy61; + goto yy1076; + } + } + } + } else { + if (yych <= 'h') { + if (yych <= 'c') { + if (yych == 'X') goto yy1076; + if (yych <= 'Y') goto yy61; + goto yy1076; + } else { + if (yych <= 'e') { + if (yych <= 'd') goto yy61; + goto yy1076; + } else { + if (yych == 'g') goto yy1076; + goto yy61; + } + } + } else { + if (yych <= 't') { + if (yych == 'm') goto yy61; + if (yych <= 'r') goto yy1076; + goto yy61; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy1076; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy1076; + } + } + } + } +yy1080: + YYDEBUG(1080, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'T') { + if (yych <= '9') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy1076; + goto yy61; + } else { + if (yych <= '0') { + if (yych <= '/') goto yy1076; + goto yy845; + } else { + if (yych <= '2') goto yy846; + if (yych <= '3') goto yy847; + goto yy821; + } + } + } else { + if (yych <= 'G') { + if (yych <= 'D') { + if (yych <= 'C') goto yy1076; + goto yy61; + } else { + if (yych == 'F') goto yy61; + goto yy1076; + } + } else { + if (yych <= 'L') { + if (yych <= 'H') goto yy61; + goto yy1076; + } else { + if (yych <= 'M') goto yy61; + if (yych <= 'R') goto yy1076; + goto yy61; + } + } + } + } else { + if (yych <= 'g') { + if (yych <= 'Y') { + if (yych == 'W') goto yy61; + if (yych <= 'X') goto yy1076; + goto yy61; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy1076; + goto yy61; + } else { + if (yych == 'f') goto yy61; + goto yy1076; + } + } + } else { + if (yych <= 't') { + if (yych <= 'l') { + if (yych <= 'h') goto yy61; + goto yy1076; + } else { + if (yych <= 'm') goto yy61; + if (yych <= 'r') goto yy1076; + goto yy61; + } + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy1076; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy1076; + } + } + } + } +yy1081: + YYDEBUG(1081, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'T') { + if (yych <= '9') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy1076; + goto yy61; + } else { + if (yych <= '0') { + if (yych <= '/') goto yy1076; + goto yy877; + } else { + if (yych <= '2') goto yy846; + if (yych <= '3') goto yy847; + goto yy821; + } + } + } else { + if (yych <= 'G') { + if (yych <= 'D') { + if (yych <= 'C') goto yy1076; + goto yy61; + } else { + if (yych == 'F') goto yy61; + goto yy1076; + } + } else { + if (yych <= 'L') { + if (yych <= 'H') goto yy61; + goto yy1076; + } else { + if (yych <= 'M') goto yy61; + if (yych <= 'R') goto yy1076; + goto yy61; + } + } + } + } else { + if (yych <= 'g') { + if (yych <= 'Y') { + if (yych == 'W') goto yy61; + if (yych <= 'X') goto yy1076; + goto yy61; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy1076; + goto yy61; + } else { + if (yych == 'f') goto yy61; + goto yy1076; + } + } + } else { + if (yych <= 't') { + if (yych <= 'l') { + if (yych <= 'h') goto yy61; + goto yy1076; + } else { + if (yych <= 'm') goto yy61; + if (yych <= 'r') goto yy1076; + goto yy61; + } + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy1076; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy1076; + } + } + } + } +yy1082: + YYDEBUG(1082, *YYCURSOR); + yyaccept = 25; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'T') { + if (yych <= '9') { + if (yych <= ' ') { + if (yych == '\t') goto yy61; + if (yych <= 0x1F) goto yy1076; + goto yy61; + } else { + if (yych <= '0') { + if (yych <= '/') goto yy1076; + goto yy845; + } else { + if (yych <= '2') goto yy846; + if (yych <= '3') goto yy847; + goto yy821; + } + } + } else { + if (yych <= 'G') { + if (yych <= 'D') { + if (yych <= 'C') goto yy1076; + goto yy61; + } else { + if (yych == 'F') goto yy61; + goto yy1076; + } + } else { + if (yych <= 'L') { + if (yych <= 'H') goto yy61; + goto yy1076; + } else { + if (yych <= 'M') goto yy61; + if (yych <= 'R') goto yy1076; + goto yy61; + } + } + } + } else { + if (yych <= 'g') { + if (yych <= 'Y') { + if (yych == 'W') goto yy61; + if (yych <= 'X') goto yy1076; + goto yy61; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy1076; + goto yy61; + } else { + if (yych == 'f') goto yy61; + goto yy1076; + } + } + } else { + if (yych <= 't') { + if (yych <= 'l') { + if (yych <= 'h') goto yy61; + goto yy1076; + } else { + if (yych <= 'm') goto yy61; + if (yych <= 'r') goto yy1076; + goto yy61; + } + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy1076; + goto yy61; + } else { + if (yych == 'y') goto yy61; + goto yy1076; + } + } + } } -yy1364: - yyaccept = 0; +yy1083: + YYDEBUG(1083, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'I': goto yy1325; - case 'O': goto yy1324; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'i': goto yy1366; - case 'o': goto yy1365; - default: goto yy4; + if (yych <= '/') { + if (yych == '.') goto yy1085; + goto yy491; + } else { + if (yych <= '9') goto yy1084; + if (yych <= ':') goto yy1085; + goto yy491; } -yy1365: - yyaccept = 0; +yy1084: + YYDEBUG(1084, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'N': goto yy1328; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'n': goto yy1369; - default: goto yy4; + if (yych == '.') goto yy1085; + if (yych != ':') goto yy491; +yy1085: + YYDEBUG(1085, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy1086; + if (yych <= '6') goto yy1087; + if (yych <= '9') goto yy496; + goto yy57; +yy1086: + YYDEBUG(1086, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy496; + goto yy491; +yy1087: + YYDEBUG(1087, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych == '0') goto yy496; + goto yy491; +yy1088: + YYDEBUG(1088, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + goto yy1092; + } else { + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy1091; + if (yych <= ':') goto yy1085; + goto yy491; } -yy1366: - yyaccept = 4; +yy1089: + YYDEBUG(1089, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'D': goto yy1326; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'd': goto yy1367; - default: goto yy167; + if (yych <= '/') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + if (yych <= '.') goto yy1092; + goto yy491; + } else { + if (yych <= '2') goto yy1091; + if (yych <= '9') goto yy1084; + if (yych <= ':') goto yy1085; + goto yy491; } -yy1367: - yyaccept = 0; +yy1090: + YYDEBUG(1090, *YYCURSOR); + yyaccept = 11; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1327; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': goto yy1368; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; + if (yych <= '.') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + goto yy1092; + } else { + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy1084; + if (yych <= ':') goto yy1085; + goto yy491; + } +yy1091: + YYDEBUG(1091, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ',') goto yy491; + if (yych <= '-') goto yy602; + } else { + if (yych == ':') goto yy1085; + goto yy491; + } +yy1092: + YYDEBUG(1092, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '5') goto yy1093; + if (yych <= '6') goto yy1094; + if (yych <= '9') goto yy610; + goto yy57; +yy1093: + YYDEBUG(1093, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy1095; + goto yy491; +yy1094: + YYDEBUG(1094, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych == '.') goto yy497; + goto yy491; + } else { + if (yych <= '0') goto yy1095; + if (yych <= '9') goto yy611; + goto yy491; + } +yy1095: + YYDEBUG(1095, *YYCURSOR); + yyaccept = 11; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '.') goto yy497; + if (yych <= '/') goto yy491; + if (yych <= '9') goto yy605; + goto yy491; +yy1096: + YYDEBUG(1096, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '9') { + if (yych <= '-') { + if (yych == '\t') goto yy460; + if (yych <= ',') goto yy462; + goto yy1051; + } else { + if (yych <= '.') goto yy474; + if (yych <= '/') goto yy472; + if (yych <= '5') goto yy1066; + goto yy741; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy483; + if (yych == 'n') goto yy470; + goto yy462; + } else { + if (yych <= 'r') goto yy471; + if (yych <= 's') goto yy464; + if (yych <= 't') goto yy468; + goto yy462; + } } -yy1368: +yy1097: + YYDEBUG(1097, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '9') { + if (yych <= '-') { + if (yych == '\t') goto yy1052; + if (yych <= ',') goto yy1054; + goto yy1051; + } else { + if (yych <= '.') goto yy1064; + if (yych <= '/') goto yy472; + if (yych <= '5') goto yy1066; + goto yy741; + } + } else { + if (yych <= 'q') { + if (yych <= ':') goto yy1065; + if (yych == 'n') goto yy470; + goto yy1054; + } else { + if (yych <= 'r') goto yy471; + if (yych <= 's') goto yy464; + if (yych <= 't') goto yy468; + goto yy1054; + } + } +yy1098: + YYDEBUG(1098, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy142; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'e') goto yy1099; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1099: + YYDEBUG(1099, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'V') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'U') goto yy143; + } + } else { + if (yych <= 'u') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'v') goto yy1100; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1100: + YYDEBUG(1100, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'I') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'H') goto yy144; + } + } else { + if (yych <= 'h') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'i') goto yy1101; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1101: + YYDEBUG(1101, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'N') goto yy145; + } + } else { + if (yych <= 'n') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'o') goto yy1102; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1102: + YYDEBUG(1102, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': goto yy145; - case 'Y': goto yy1236; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy153; - case 'y': goto yy1265; - default: goto yy4; + if (yych <= 'T') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'U') goto yy1103; + if (yych != 'u') goto yy4; } -yy1369: - yyaccept = 0; +yy1103: + YYDEBUG(1103, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy1104; + if (yych != 's') goto yy57; +yy1104: + YYDEBUG(1104, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '\t') goto yy1105; + if (yych != ' ') goto yy57; +yy1105: + YYDEBUG(1105, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); + yych = *YYCURSOR; +yy1106: + YYDEBUG(1106, *YYCURSOR); + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy1105; + if (yych <= 0x1F) goto yy57; + goto yy1105; + } else { + if (yych == 'D') goto yy1110; + if (yych <= 'E') goto yy57; + goto yy1111; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy1109; + if (yych <= 'L') goto yy57; + goto yy1108; + } else { + if (yych <= 'S') { + if (yych <= 'R') goto yy57; + } else { + if (yych <= 'T') goto yy1114; + if (yych <= 'V') goto yy57; + goto yy1113; + } + } + } + } else { + if (yych <= 'l') { + if (yych <= 'd') { + if (yych == 'Y') goto yy1112; + if (yych <= 'c') goto yy57; + goto yy1110; + } else { + if (yych <= 'f') { + if (yych <= 'e') goto yy57; + goto yy1111; + } else { + if (yych == 'h') goto yy1109; + goto yy57; + } + } + } else { + if (yych <= 't') { + if (yych <= 'm') goto yy1108; + if (yych <= 'r') goto yy57; + if (yych >= 't') goto yy1114; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy57; + goto yy1113; + } else { + if (yych == 'y') goto yy1112; + goto yy57; + } + } + } + } +yy1107: + YYDEBUG(1107, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= 'D') { + if (yych == 'A') goto yy1179; + goto yy57; + } else { + if (yych <= 'E') goto yy1180; + if (yych <= 'T') goto yy57; + goto yy1178; + } + } else { + if (yych <= 'd') { + if (yych == 'a') goto yy1179; + goto yy57; + } else { + if (yych <= 'e') goto yy1180; + if (yych == 'u') goto yy1178; + goto yy57; + } + } +yy1108: + YYDEBUG(1108, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych == 'I') goto yy1170; + if (yych <= 'N') goto yy57; + goto yy1169; + } else { + if (yych <= 'i') { + if (yych <= 'h') goto yy57; + goto yy1170; + } else { + if (yych == 'o') goto yy1169; + goto yy57; + } + } +yy1109: + YYDEBUG(1109, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy1167; + if (yych == 'o') goto yy1167; + goto yy57; +yy1110: + YYDEBUG(1110, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1166; + if (yych == 'a') goto yy1166; + goto yy57; +yy1111: + YYDEBUG(1111, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'R') { + if (yych == 'O') goto yy1151; + if (yych <= 'Q') goto yy57; + goto yy1150; + } else { + if (yych <= 'o') { + if (yych <= 'n') goto yy57; + goto yy1151; + } else { + if (yych == 'r') goto yy1150; + goto yy57; + } + } +yy1112: + YYDEBUG(1112, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1147; + if (yych == 'e') goto yy1147; + goto yy57; +yy1113: + YYDEBUG(1113, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1133; + if (yych == 'e') goto yy1133; + goto yy57; +yy1114: + YYDEBUG(1114, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych == 'H') goto yy1115; + if (yych <= 'T') goto yy57; + goto yy1116; + } else { + if (yych <= 'h') { + if (yych <= 'g') goto yy57; + } else { + if (yych == 'u') goto yy1116; + goto yy57; + } + } +yy1115: + YYDEBUG(1115, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'U') goto yy1128; + if (yych == 'u') goto yy1128; + goto yy57; +yy1116: + YYDEBUG(1116, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1117; + if (yych != 'e') goto yy57; +yy1117: + YYDEBUG(1117, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'T': goto yy1329; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 't': goto yy1370; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych >= ' ') goto yy1119; + } else { + if (yych <= 'S') { + if (yych >= 'S') goto yy1121; + } else { + if (yych == 's') goto yy1121; + } + } +yy1118: + YYDEBUG(1118, *YYCURSOR); +#line 1629 "ext/date/lib/parse_date.re" + { + timelib_sll i; + int behavior = 0; + DEBUG_OUTPUT("relativetext"); + TIMELIB_INIT; + TIMELIB_HAVE_RELATIVE(); + + while(*ptr) { + i = timelib_get_relative_text((char **) &ptr, &behavior); + timelib_eat_spaces((char **) &ptr); + timelib_set_relative((char **) &ptr, i, behavior, s); + } + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; + } +#line 16753 "ext/date/lib/parse_date.c" +yy1119: + YYDEBUG(1119, *YYCURSOR); + ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2); + yych = *YYCURSOR; + YYDEBUG(1120, *YYCURSOR); + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych <= 0x1F) goto yy57; + goto yy1119; + } else { + if (yych <= 'O') { + if (yych <= 'N') goto yy57; + goto yy1125; + } else { + if (yych == 'o') goto yy1125; + goto yy57; + } + } +yy1121: + YYDEBUG(1121, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1122; + if (yych != 'd') goto yy57; +yy1122: + YYDEBUG(1122, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1123; + if (yych != 'a') goto yy57; +yy1123: + YYDEBUG(1123, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych != 'y') goto yy57; +yy1124: + YYDEBUG(1124, *YYCURSOR); + yyaccept = 26; + yych = *(YYMARKER = ++YYCURSOR); + if (yych == '\t') goto yy1119; + if (yych == ' ') goto yy1119; + goto yy1118; +yy1125: + YYDEBUG(1125, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'F') goto yy1126; + if (yych != 'f') goto yy57; +yy1126: + YYDEBUG(1126, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(1127, *YYCURSOR); +#line 1114 "ext/date/lib/parse_date.re" + { + timelib_sll i; + int behavior = 0; + DEBUG_OUTPUT("weekdayof"); + TIMELIB_INIT; + TIMELIB_HAVE_RELATIVE(); + TIMELIB_HAVE_SPECIAL_RELATIVE(); + + i = timelib_get_relative_text((char **) &ptr, &behavior); + timelib_eat_spaces((char **) &ptr); + if (i > 0) { /* first, second... etc */ + s->time->relative.special.type = TIMELIB_SPECIAL_DAY_OF_WEEK_IN_MONTH; + timelib_set_relative((char **) &ptr, i, 1, s); + } else { /* last */ + s->time->relative.special.type = TIMELIB_SPECIAL_LAST_DAY_OF_WEEK_IN_MONTH; + timelib_set_relative((char **) &ptr, i, behavior, s); + } + TIMELIB_DEINIT; + return TIMELIB_WEEK_DAY_OF_MONTH; } -yy1370: - yyaccept = 0; +#line 16825 "ext/date/lib/parse_date.c" +yy1128: + YYDEBUG(1128, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ' ': goto yy1330; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych <= 0x1F) goto yy1118; + goto yy1119; + } else { + if (yych <= 'R') { + if (yych <= 'Q') goto yy1118; + } else { + if (yych != 'r') goto yy1118; + } } -yy1371: - yyaccept = 0; + YYDEBUG(1129, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy1130; + if (yych != 's') goto yy57; +yy1130: + YYDEBUG(1130, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1131; + if (yych != 'd') goto yy57; +yy1131: + YYDEBUG(1131, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1132; + if (yych != 'a') goto yy57; +yy1132: + YYDEBUG(1132, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych == 'y') goto yy1124; + goto yy57; +yy1133: + YYDEBUG(1133, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= 'C') goto yy57; + if (yych <= 'D') goto yy1135; + } else { + if (yych <= 'c') goto yy57; + if (yych <= 'd') goto yy1135; + if (yych >= 'f') goto yy57; + } + YYDEBUG(1134, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'K') goto yy1141; + if (yych == 'k') goto yy1141; + goto yy57; +yy1135: + YYDEBUG(1135, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'R': goto yy1343; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'r': goto yy1372; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych <= 0x1F) goto yy1118; + goto yy1119; + } else { + if (yych <= 'N') { + if (yych <= 'M') goto yy1118; + } else { + if (yych != 'n') goto yy1118; + } } -yy1372: - yyaccept = 0; + YYDEBUG(1136, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1137; + if (yych != 'e') goto yy57; +yy1137: + YYDEBUG(1137, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy1138; + if (yych != 's') goto yy57; +yy1138: + YYDEBUG(1138, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1139; + if (yych != 'd') goto yy57; +yy1139: + YYDEBUG(1139, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1140; + if (yych != 'a') goto yy57; +yy1140: + YYDEBUG(1140, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych == 'y') goto yy1124; + goto yy57; +yy1141: + YYDEBUG(1141, *YYCURSOR); + yyaccept = 27; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'T': goto yy1344; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 't': goto yy1373; - default: goto yy4; + if (yych <= 'S') { + if (yych == 'D') goto yy1144; + if (yych >= 'S') goto yy1143; + } else { + if (yych <= 'd') { + if (yych >= 'd') goto yy1144; + } else { + if (yych == 's') goto yy1143; + } + } +yy1142: + YYDEBUG(1142, *YYCURSOR); +#line 1605 "ext/date/lib/parse_date.re" + { + timelib_sll i; + int behavior = 0; + DEBUG_OUTPUT("relativetextweek"); + TIMELIB_INIT; + TIMELIB_HAVE_RELATIVE(); + + while(*ptr) { + i = timelib_get_relative_text((char **) &ptr, &behavior); + timelib_eat_spaces((char **) &ptr); + timelib_set_relative((char **) &ptr, i, behavior, s); + s->time->relative.weekday_behavior = 2; + + /* to handle the format weekday + last/this/next week */ + if (s->time->relative.have_weekday_relative == 0) { + TIMELIB_HAVE_WEEKDAY_RELATIVE(); + s->time->relative.weekday = 1; + } + } + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; + } +#line 16956 "ext/date/lib/parse_date.c" +yy1143: + YYDEBUG(1143, *YYCURSOR); + yych = *++YYCURSOR; + goto yy1118; +yy1144: + YYDEBUG(1144, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1145; + if (yych != 'a') goto yy57; +yy1145: + YYDEBUG(1145, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1146; + if (yych != 'y') goto yy57; +yy1146: + YYDEBUG(1146, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy1143; + if (yych == 's') goto yy1143; + goto yy1118; +yy1147: + YYDEBUG(1147, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1148; + if (yych != 'a') goto yy57; +yy1148: + YYDEBUG(1148, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy1149; + if (yych != 'r') goto yy57; +yy1149: + YYDEBUG(1149, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy1143; + if (yych == 's') goto yy1143; + goto yy1118; +yy1150: + YYDEBUG(1150, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy1163; + if (yych == 'i') goto yy1163; + goto yy57; +yy1151: + YYDEBUG(1151, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy1152; + if (yych != 'r') goto yy57; +yy1152: + YYDEBUG(1152, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy1153; + if (yych != 't') goto yy57; +yy1153: + YYDEBUG(1153, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych == 'H') goto yy1155; + if (yych <= 'M') goto yy57; + } else { + if (yych <= 'h') { + if (yych <= 'g') goto yy57; + goto yy1155; + } else { + if (yych != 'n') goto yy57; + } } -yy1373: - yyaccept = 0; + YYDEBUG(1154, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy1160; + if (yych == 'i') goto yy1160; + goto yy57; +yy1155: + YYDEBUG(1155, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy1156; + if (yych != 'n') goto yy57; +yy1156: + YYDEBUG(1156, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy1157; + if (yych != 'i') goto yy57; +yy1157: + YYDEBUG(1157, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy1158; + if (yych != 'g') goto yy57; +yy1158: + YYDEBUG(1158, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy1159; + if (yych != 'h') goto yy57; +yy1159: + YYDEBUG(1159, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy1149; + if (yych == 't') goto yy1149; + goto yy57; +yy1160: + YYDEBUG(1160, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy1161; + if (yych != 'g') goto yy57; +yy1161: + YYDEBUG(1161, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy1162; + if (yych != 'h') goto yy57; +yy1162: + YYDEBUG(1162, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy1149; + if (yych == 't') goto yy1149; + goto yy57; +yy1163: + YYDEBUG(1163, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'H': goto yy1216; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'h': goto yy1228; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych <= 0x1F) goto yy1118; + goto yy1119; + } else { + if (yych <= 'D') { + if (yych <= 'C') goto yy1118; + } else { + if (yych != 'd') goto yy1118; + } } -yy1374: - yyaccept = 0; + YYDEBUG(1164, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1165; + if (yych != 'a') goto yy57; +yy1165: + YYDEBUG(1165, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych == 'y') goto yy1124; + goto yy57; +yy1166: + YYDEBUG(1166, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1149; + if (yych == 'y') goto yy1149; + goto yy57; +yy1167: + YYDEBUG(1167, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'U') goto yy1168; + if (yych != 'u') goto yy57; +yy1168: + YYDEBUG(1168, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy1149; + if (yych == 'r') goto yy1149; + goto yy57; +yy1169: + YYDEBUG(1169, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy1174; + if (yych == 'n') goto yy1174; + goto yy57; +yy1170: + YYDEBUG(1170, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy1171; + if (yych != 'n') goto yy57; +yy1171: + YYDEBUG(1171, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'S': goto yy1348; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 's': goto yy1377; - default: goto yy4; + if (yych <= 'U') { + if (yych == 'S') goto yy1143; + if (yych <= 'T') goto yy1118; + } else { + if (yych <= 's') { + if (yych <= 'r') goto yy1118; + goto yy1143; + } else { + if (yych != 'u') goto yy1118; + } } -yy1375: - yyaccept = 0; + YYDEBUG(1172, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy1173; + if (yych != 't') goto yy57; +yy1173: + YYDEBUG(1173, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1149; + if (yych == 'e') goto yy1149; + goto yy57; +yy1174: + YYDEBUG(1174, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1347; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1376; - default: goto yy4; + if (yych <= 'D') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy1119; + goto yy1118; + } else { + if (yych <= ' ') goto yy1119; + if (yych <= 'C') goto yy1118; + } + } else { + if (yych <= 'c') { + if (yych == 'T') goto yy1176; + goto yy1118; + } else { + if (yych <= 'd') goto yy1175; + if (yych == 't') goto yy1176; + goto yy1118; + } } -yy1376: - yyaccept = 0; +yy1175: + YYDEBUG(1175, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1177; + if (yych == 'a') goto yy1177; + goto yy57; +yy1176: + YYDEBUG(1176, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy1149; + if (yych == 'h') goto yy1149; + goto yy57; +yy1177: + YYDEBUG(1177, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych == 'y') goto yy1124; + goto yy57; +yy1178: + YYDEBUG(1178, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy1189; + if (yych == 'n') goto yy1189; + goto yy57; +yy1179: + YYDEBUG(1179, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy1184; + if (yych == 't') goto yy1184; + goto yy57; +yy1180: + YYDEBUG(1180, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy1181; + if (yych != 'c') goto yy57; +yy1181: + YYDEBUG(1181, *YYCURSOR); + yyaccept = 26; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych == 'O') goto yy1182; + if (yych <= 'R') goto yy1118; + goto yy1143; + } else { + if (yych <= 'o') { + if (yych <= 'n') goto yy1118; + } else { + if (yych == 's') goto yy1143; + goto yy1118; + } + } +yy1182: + YYDEBUG(1182, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy1183; + if (yych != 'n') goto yy57; +yy1183: + YYDEBUG(1183, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1149; + if (yych == 'd') goto yy1149; + goto yy57; +yy1184: + YYDEBUG(1184, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'H': goto yy1239; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'h': goto yy1268; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych <= 0x1F) goto yy1118; + goto yy1119; + } else { + if (yych <= 'U') { + if (yych <= 'T') goto yy1118; + } else { + if (yych != 'u') goto yy1118; + } } -yy1377: - yyaccept = 0; + YYDEBUG(1185, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy1186; + if (yych != 'r') goto yy57; +yy1186: + YYDEBUG(1186, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1187; + if (yych != 'd') goto yy57; +yy1187: + YYDEBUG(1187, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1188; + if (yych != 'a') goto yy57; +yy1188: + YYDEBUG(1188, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych == 'y') goto yy1124; + goto yy57; +yy1189: + YYDEBUG(1189, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'T': goto yy1349; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 't': goto yy1378; - default: goto yy4; + if (yych <= ' ') { + if (yych == '\t') goto yy1119; + if (yych <= 0x1F) goto yy1118; + goto yy1119; + } else { + if (yych <= 'D') { + if (yych <= 'C') goto yy1118; + } else { + if (yych != 'd') goto yy1118; + } } -yy1378: + YYDEBUG(1190, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1191; + if (yych != 'a') goto yy57; +yy1191: + YYDEBUG(1191, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1124; + if (yych == 'y') goto yy1124; + goto yy57; +yy1192: + YYDEBUG(1192, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': goto yy1207; - case ' ': goto yy1350; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1099; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'e') goto yy1193; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1379: - yyaccept = 5; +yy1193: + YYDEBUG(1193, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'R': goto yy1357; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'r': goto yy1380; - default: goto yy194; + if (yych <= 'U') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'V') goto yy1100; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'u') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'v') goto yy1194; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1380: +yy1194: + YYDEBUG(1194, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'U': goto yy1358; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'u': goto yy1381; - default: goto yy4; + if (yych <= 'H') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'I') goto yy1101; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'h') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'i') goto yy1195; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1381: +yy1195: + YYDEBUG(1195, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1359; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': goto yy1382; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; + if (yych <= 'N') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'O') goto yy1102; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'n') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'o') goto yy1196; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1382: +yy1196: + YYDEBUG(1196, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'R': goto yy1360; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'r': goto yy1383; - default: goto yy4; + if (yych <= 'T') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'U') goto yy1103; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'u') goto yy1197; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1383: +yy1197: + YYDEBUG(1197, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': goto yy206; - case 'y': goto yy377; - default: goto yy155; + if (yych == 'S') goto yy1104; + if (yych != 's') goto yy155; + YYDEBUG(1198, *YYCURSOR); + yych = *++YYCURSOR; + if (yybm[0+yych] & 16) { + goto yy154; } -yy1384: + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy57; + goto yy1105; + } else { + if (yych == ' ') goto yy1105; + goto yy57; + } + } else { + if (yych <= '/') { + if (yych == '.') goto yy57; + goto yy148; + } else { + if (yych == '_') goto yy148; + goto yy57; + } + } +yy1199: + YYDEBUG(1199, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1385; - default: goto yy57; + if (yych <= 'G') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'F') goto yy142; + goto yy1213; + } + } else { + if (yych <= 'f') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'g') goto yy1213; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1385: +yy1200: + YYDEBUG(1200, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy142; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'e') goto yy1201; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1201: + YYDEBUG(1201, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'V') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'U') goto yy143; + } + } else { + if (yych <= 'u') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'v') goto yy1202; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1202: + YYDEBUG(1202, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy144; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'e') goto yy1203; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1203: + YYDEBUG(1203, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy145; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'n') goto yy1204; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1204: + YYDEBUG(1204, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'T') goto yy1205; + if (yych != 't') goto yy4; + } +yy1205: + YYDEBUG(1205, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'H') goto yy1206; + if (yych != 'h') goto yy57; +yy1206: + YYDEBUG(1206, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '\t') goto yy1207; + if (yych != ' ') goto yy57; +yy1207: + YYDEBUG(1207, *YYCURSOR); ++YYCURSOR; - if (YYLIMIT <= YYCURSOR) YYFILL(1); + if ((YYLIMIT - YYCURSOR) < 11) YYFILL(11); yych = *YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1385; - default: goto yy1387; +yy1208: + YYDEBUG(1208, *YYCURSOR); + if (yych <= 'W') { + if (yych <= 'F') { + if (yych <= ' ') { + if (yych == '\t') goto yy1207; + if (yych <= 0x1F) goto yy57; + goto yy1207; + } else { + if (yych == 'D') goto yy1110; + if (yych <= 'E') goto yy57; + goto yy1111; + } + } else { + if (yych <= 'M') { + if (yych == 'H') goto yy1109; + if (yych <= 'L') goto yy57; + goto yy1108; + } else { + if (yych <= 'S') { + if (yych <= 'R') goto yy57; + goto yy1107; + } else { + if (yych <= 'T') goto yy1114; + if (yych <= 'V') goto yy57; + } + } + } + } else { + if (yych <= 'l') { + if (yych <= 'd') { + if (yych == 'Y') goto yy1112; + if (yych <= 'c') goto yy57; + goto yy1110; + } else { + if (yych <= 'f') { + if (yych <= 'e') goto yy57; + goto yy1111; + } else { + if (yych == 'h') goto yy1109; + goto yy57; + } + } + } else { + if (yych <= 't') { + if (yych <= 'm') goto yy1108; + if (yych <= 'r') goto yy57; + if (yych <= 's') goto yy1107; + goto yy1114; + } else { + if (yych <= 'w') { + if (yych <= 'v') goto yy57; + } else { + if (yych == 'y') goto yy1112; + goto yy57; + } + } + } } -yy1387: -#line 1049 "ext/date/lib/parse_date.re" - { - timelib_ull i; - - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - TIMELIB_UNHAVE_DATE(); - TIMELIB_UNHAVE_TIME(); - TIMELIB_HAVE_TZ(); - - i = timelib_get_unsigned_nr((char **) &ptr, 24); - s->time->y = 1970; - s->time->m = 1; - s->time->d = 1; - s->time->h = s->time->i = s->time->s = 0; - s->time->f = 0.0; - s->time->relative.s += i; - s->time->is_localtime = 1; - s->time->zone_type = TIMELIB_ZONETYPE_OFFSET; - s->time->z = 0; - - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; + YYDEBUG(1209, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy1210; + if (yych != 'e') goto yy57; +yy1210: + YYDEBUG(1210, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= 'C') goto yy57; + if (yych <= 'D') goto yy1135; + } else { + if (yych <= 'c') goto yy57; + if (yych <= 'd') goto yy1135; + if (yych >= 'f') goto yy57; } -#line 32134 "" -yy1388: + YYDEBUG(1211, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'N': - case 'n': goto yy1429; - default: goto yy4; + if (yych == 'K') goto yy1212; + if (yych != 'k') goto yy57; +yy1212: + YYDEBUG(1212, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych == 'D') goto yy1144; + if (yych <= 'R') goto yy57; + goto yy1143; + } else { + if (yych <= 'd') { + if (yych <= 'c') goto yy57; + goto yy1144; + } else { + if (yych == 's') goto yy1143; + goto yy57; + } } -yy1389: +yy1213: + YYDEBUG(1213, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'I': - case 'i': goto yy1421; - case 'U': - case 'u': goto yy1422; - default: goto yy4; + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy143; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'h') goto yy1214; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1390: +yy1214: + YYDEBUG(1214, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'D': - case 'd': goto yy1410; - case 'M': - case 'm': goto yy1411; - default: goto yy4; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy144; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 't') goto yy1215; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1215: + YYDEBUG(1215, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy1207; + goto yy4; + } else { + if (yych <= ' ') goto yy1207; + if (yych == ')') goto yy140; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych == 'H') goto yy1216; + if (yych <= 'Z') goto yy145; + goto yy4; + } else { + if (yych == 'h') goto yy1216; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1216: + YYDEBUG(1216, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 0x1F) { + if (yych == '\t') goto yy1207; + goto yy4; + } else { + if (yych <= ' ') goto yy1207; + if (yych == ')') goto yy140; + goto yy4; + } +yy1217: + YYDEBUG(1217, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'F') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'G') goto yy1213; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'f') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'g') goto yy1225; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1218: + YYDEBUG(1218, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1201; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'e') goto yy1219; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1219: + YYDEBUG(1219, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'U') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'V') goto yy1202; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'u') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'v') goto yy1220; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1220: + YYDEBUG(1220, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1203; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'e') goto yy1221; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1391: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'E': - case 'e': goto yy1406; - default: goto yy4; +yy1221: + YYDEBUG(1221, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1204; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'n') goto yy1222; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1392: +yy1222: + YYDEBUG(1222, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'T') goto yy1205; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 't') goto yy1223; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy1223: + YYDEBUG(1223, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'E': - case 'e': goto yy1402; - default: goto yy4; + if (yych == 'H') goto yy1206; + if (yych != 'h') goto yy155; +yy1224: + YYDEBUG(1224, *YYCURSOR); + yych = *++YYCURSOR; + if (yybm[0+yych] & 16) { + goto yy154; } -yy1393: + if (yych <= ',') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy57; + goto yy1207; + } else { + if (yych == ' ') goto yy1207; + goto yy57; + } + } else { + if (yych <= '/') { + if (yych == '.') goto yy57; + goto yy148; + } else { + if (yych == '_') goto yy148; + goto yy57; + } + } +yy1225: + YYDEBUG(1225, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy1214; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'h') goto yy1226; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1226: + YYDEBUG(1226, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1215; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 't') goto yy1227; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy1227: + YYDEBUG(1227, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy4; + goto yy1207; + } else { + if (yych == ' ') goto yy1207; + goto yy4; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + goto yy148; + } + } + } else { + if (yych <= '^') { + if (yych <= 'G') { + if (yych <= '@') goto yy4; + goto yy145; + } else { + if (yych <= 'H') goto yy1216; + if (yych <= 'Z') goto yy145; + goto yy4; + } + } else { + if (yych <= 'g') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'h') goto yy1228; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy1228: + YYDEBUG(1228, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; + } + if (yych <= ')') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy1207; + goto yy4; + } else { + if (yych <= ' ') goto yy1207; + if (yych <= '(') goto yy4; + goto yy140; + } + } else { + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy4; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy4; + } + } +yy1229: + YYDEBUG(1229, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy1065; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1396; - default: goto yy57; + if (yych <= 'V') { + if (yych <= 'B') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'O') { + if (yych <= 'C') goto yy1245; + goto yy142; + } else { + if (yych <= 'P') goto yy1247; + if (yych <= 'U') goto yy142; + goto yy1246; + } + } + } else { + if (yych <= 'o') { + if (yych <= '`') { + if (yych <= 'Z') goto yy142; + goto yy4; + } else { + if (yych == 'c') goto yy1245; + goto yy142; + } + } else { + if (yych <= 'u') { + if (yych <= 'p') goto yy1247; + goto yy142; + } else { + if (yych <= 'v') goto yy1246; + if (yych <= 'z') goto yy142; + goto yy4; + } + } } -yy1394: +yy1230: + YYDEBUG(1230, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy1065; - case '0': - case '1': - case '2': - case '3': - case '4': goto yy1396; - default: goto yy57; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy142; + goto yy1240; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 't') goto yy1240; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1395: +yy1231: + YYDEBUG(1231, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy1065; - default: goto yy57; + if (yych <= 'X') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'W') goto yy142; + goto yy1237; + } + } else { + if (yych <= 'w') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'x') goto yy1237; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1396: +yy1232: + YYDEBUG(1232, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '.': - case ':': goto yy1065; - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1397; - default: goto yy57; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy142; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'n') goto yy1233; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1397: +yy1233: + YYDEBUG(1233, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1398; - default: goto yy57; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy167; + goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'C') goto yy143; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy167; + goto yy143; + } else { + if (yych <= 'd') goto yy1234; + if (yych <= 'z') goto yy143; + goto yy167; + } } -yy1398: - yyaccept = 24; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': goto yy1399; - case '6': goto yy1400; - default: goto yy1068; +yy1234: + YYDEBUG(1234, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy144; + goto yy4; + } else { + if (yych <= 'a') goto yy1235; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1399: +yy1235: + YYDEBUG(1235, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy1401; - default: goto yy57; + if (yych <= 'Y') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'X') goto yy145; + } + } else { + if (yych <= 'x') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'y') goto yy1236; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1400: +yy1236: + YYDEBUG(1236, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case '0': goto yy1401; - default: goto yy57; + if (yych == ')') goto yy140; + goto yy167; +yy1237: + YYDEBUG(1237, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1238; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1401: +yy1238: + YYDEBUG(1238, *YYCURSOR); yych = *++YYCURSOR; - goto yy1076; -yy1402: + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy144; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'h') goto yy1239; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1239: + YYDEBUG(1239, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy4; + goto yy1207; + } else { + if (yych == ' ') goto yy1207; + goto yy4; + } + } else { + if (yych <= 'Z') { + if (yych <= ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy145; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1240: + YYDEBUG(1240, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'L': - case 'l': goto yy1403; - default: goto yy4; + if (yych <= 'U') { + if (yych <= ')') { + if (yych <= '(') goto yy167; + goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'T') goto yy143; + } + } else { + if (yych <= 't') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy167; + goto yy143; + } else { + if (yych <= 'u') goto yy1241; + if (yych <= 'z') goto yy143; + goto yy167; + } } -yy1403: +yy1241: + YYDEBUG(1241, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'F': - case 'f': goto yy1404; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy144; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'r') goto yy1242; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1404: +yy1242: + YYDEBUG(1242, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'T': - case 't': goto yy1405; - default: goto yy4; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy145; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'd') goto yy1243; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1405: +yy1243: + YYDEBUG(1243, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'H': - case 'h': goto yy1206; - default: goto yy4; + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'A') goto yy1244; + if (yych != 'a') goto yy4; } -yy1406: +yy1244: + YYDEBUG(1244, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'S': - case 's': goto yy1407; - default: goto yy167; + if (yych == 'Y') goto yy173; + if (yych == 'y') goto yy173; + goto yy57; +yy1245: + YYDEBUG(1245, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'N') goto yy143; + goto yy1256; + } + } else { + if (yych <= 'n') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'o') goto yy1256; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1407: +yy1246: + YYDEBUG(1246, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'D': - case 'd': goto yy1408; - default: goto yy4; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy143; + goto yy1253; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'e') goto yy1253; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1408: +yy1247: + YYDEBUG(1247, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'T') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 't') goto yy1248; + if (yych <= 'z') goto yy143; + goto yy194; + } + } + } +yy1248: + YYDEBUG(1248, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'E') goto yy144; + } + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy194; + goto yy144; + } else { + if (yych <= 'e') goto yy1249; + if (yych <= 'z') goto yy144; + goto yy194; + } + } + } +yy1249: + YYDEBUG(1249, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1409; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy4; + if (yych <= 'M') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'L') goto yy145; + } + } else { + if (yych <= 'l') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'm') goto yy1250; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1409: +yy1250: + YYDEBUG(1250, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'A') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'B') goto yy1251; + if (yych != 'b') goto yy4; + } +yy1251: + YYDEBUG(1251, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'Y': - case 'y': goto yy173; - default: goto yy4; + if (yych == 'E') goto yy1252; + if (yych != 'e') goto yy57; +yy1252: + YYDEBUG(1252, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy206; + if (yych == 'r') goto yy206; + goto yy57; +yy1253: + YYDEBUG(1253, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy144; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'n') goto yy1254; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1254: + YYDEBUG(1254, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy145; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 't') goto yy1255; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1255: + YYDEBUG(1255, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'H') goto yy1206; + if (yych == 'h') goto yy1206; + goto yy4; } -yy1410: +yy1256: + YYDEBUG(1256, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1418; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy4; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy144; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'n') goto yy1257; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1411: +yy1257: + YYDEBUG(1257, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'O': - case 'o': goto yy1412; - default: goto yy4; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy145; + goto yy1216; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'd') goto yy1216; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1412: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'R': - case 'r': goto yy1413; - default: goto yy4; +yy1258: + YYDEBUG(1258, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'U') { + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + goto yy148; + } + } else { + if (yych <= 'C') { + if (yych <= '@') goto yy4; + if (yych <= 'B') goto yy142; + goto yy1245; + } else { + if (yych == 'P') goto yy1247; + goto yy142; + } + } + } else { + if (yych <= 'b') { + if (yych <= '^') { + if (yych <= 'V') goto yy1246; + if (yych <= 'Z') goto yy142; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + goto yy147; + } + } else { + if (yych <= 'p') { + if (yych <= 'c') goto yy1274; + if (yych <= 'o') goto yy147; + goto yy1276; + } else { + if (yych == 'v') goto yy1275; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1259: + YYDEBUG(1259, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1240; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 't') goto yy1269; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1260: + YYDEBUG(1260, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'W') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'X') goto yy1237; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'w') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'x') goto yy1266; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1261: + YYDEBUG(1261, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1233; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'n') goto yy1262; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1262: + YYDEBUG(1262, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1234; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 'd') goto yy1263; + if (yych <= 'z') goto yy151; + goto yy167; + } + } + } +yy1263: + YYDEBUG(1263, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1235; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1264; + if (yych <= 'z') goto yy152; + goto yy4; + } + } +yy1264: + YYDEBUG(1264, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'Y') goto yy1236; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'x') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'y') goto yy1265; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy1265: + YYDEBUG(1265, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; } -yy1413: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'R': - case 'r': goto yy1414; - default: goto yy4; + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych <= '/') { + if (yych <= '.') goto yy167; + goto yy148; + } else { + if (yych == '_') goto yy148; + goto yy167; + } } -yy1414: +yy1266: + YYDEBUG(1266, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'O': - case 'o': goto yy1415; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1238; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1267; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1415: - yych = *++YYCURSOR; - switch (yych) { - case 'W': - case 'w': goto yy1416; - default: goto yy57; +yy1267: + YYDEBUG(1267, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy1239; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'h') goto yy1268; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1416: - ++YYCURSOR; -yy1417: -#line 1037 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("tomorrow"); - TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - TIMELIB_UNHAVE_TIME(); - - s->time->relative.d = 1; - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; +yy1268: + YYDEBUG(1268, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '-') { + if (yych <= ' ') { + if (yych == '\t') goto yy1207; + if (yych <= 0x1F) goto yy4; + goto yy1207; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } + } else { + if (yych <= 'Z') { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -#line 33153 "" -yy1418: +yy1269: + YYDEBUG(1269, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'T') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'U') goto yy1241; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 't') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 'u') goto yy1270; + if (yych <= 'z') goto yy151; + goto yy167; + } + } + } +yy1270: + YYDEBUG(1270, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy1242; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'r') goto yy1271; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy1271: + YYDEBUG(1271, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1243; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'd') goto yy1272; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy1272: + YYDEBUG(1272, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1244; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1273; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy1273: + YYDEBUG(1273, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy144; - case 'Y': - case 'y': goto yy1419; - default: goto yy4; + if (yych == 'Y') goto yy173; + if (yych == 'y') goto yy186; + goto yy155; +yy1274: + YYDEBUG(1274, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'O') goto yy1256; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'n') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'o') goto yy1285; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1275: + YYDEBUG(1275, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1253; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'e') goto yy1282; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1276: + YYDEBUG(1276, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'S') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'T') goto yy1248; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 's') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 't') goto yy1277; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy1277: + YYDEBUG(1277, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'D') { + if (yych <= '@') goto yy194; + goto yy144; + } else { + if (yych <= 'E') goto yy1249; + if (yych <= 'Z') goto yy144; + goto yy194; + } + } else { + if (yych <= 'd') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy152; + } else { + if (yych <= 'e') goto yy1278; + if (yych <= 'z') goto yy152; + goto yy194; + } + } } -yy1419: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - default: goto yy1420; +yy1278: + YYDEBUG(1278, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'M') goto yy1250; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'l') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'm') goto yy1279; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1420: -#line 1027 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("midnight | today"); - TIMELIB_INIT; - TIMELIB_UNHAVE_TIME(); - - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; +yy1279: + YYDEBUG(1279, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'A') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'B') goto yy1251; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'b') goto yy1280; + if (yych <= 'z') goto yy154; + goto yy4; + } } -#line 33280 "" -yy1421: +yy1280: + YYDEBUG(1280, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'R': - case 'r': goto yy1427; - case 'S': - case 's': goto yy1428; - default: goto yy4; - } -yy1422: + if (yych == 'E') goto yy1252; + if (yych != 'e') goto yy155; + YYDEBUG(1281, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'R': - case 'r': goto yy1423; - default: goto yy167; + if (yych == 'R') goto yy206; + if (yych == 'r') goto yy377; + goto yy155; +yy1282: + YYDEBUG(1282, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1254; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'n') goto yy1283; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1423: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'S': - case 's': goto yy1424; - default: goto yy4; +yy1283: + YYDEBUG(1283, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1255; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 't') goto yy1284; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1424: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'D': - case 'd': goto yy1425; - default: goto yy4; +yy1284: + YYDEBUG(1284, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'H') goto yy1206; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'h') goto yy1224; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1425: +yy1285: + YYDEBUG(1285, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1426; - default: goto yy4; + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1257; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'n') goto yy1286; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1426: +yy1286: + YYDEBUG(1286, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1216; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'd') goto yy1228; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy1287: + YYDEBUG(1287, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy173; - default: goto yy57; + if (yych <= 'C') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'B') goto yy142; + } + } else { + if (yych <= 'b') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'c') goto yy1288; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1427: +yy1288: + YYDEBUG(1288, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'D': - case 'd': goto yy1239; - default: goto yy4; + if (yych <= 'K') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'J') goto yy143; + } + } else { + if (yych <= 'j') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'k') goto yy1289; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1428: +yy1289: + YYDEBUG(1289, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1105; - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; + if (yych <= ')') { + if (yych == ' ') goto yy1290; + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= 'Z') { + if (yych <= '@') goto yy4; + goto yy144; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1290: + YYDEBUG(1290, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy1291; + if (yych != 'o') goto yy57; +yy1291: + YYDEBUG(1291, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'F') goto yy1292; + if (yych != 'f') goto yy57; +yy1292: + YYDEBUG(1292, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ' ') goto yy57; + YYDEBUG(1293, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy1294; + if (yych <= '2') goto yy1296; + if (yych <= '9') goto yy1297; + goto yy57; +yy1294: + YYDEBUG(1294, *YYCURSOR); + yyaccept = 28; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') goto yy1298; + if (yych <= '9') goto yy1297; + goto yy1298; +yy1295: + YYDEBUG(1295, *YYCURSOR); +#line 1091 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("backof | frontof"); + TIMELIB_INIT; + TIMELIB_UNHAVE_TIME(); + TIMELIB_HAVE_TIME(); + + if (*ptr == 'b') { + s->time->h = timelib_get_nr((char **) &ptr, 2); + s->time->i = 15; + } else { + s->time->h = timelib_get_nr((char **) &ptr, 2) - 1; + s->time->i = 45; + } + if (*ptr != '\0' ) { + timelib_eat_spaces((char **) &ptr); + s->time->h += timelib_meridian((char **) &ptr, s->time->h); + } + + TIMELIB_DEINIT; + return TIMELIB_LF_DAY_OF_MONTH; + } +#line 19655 "ext/date/lib/parse_date.c" +yy1296: + YYDEBUG(1296, *YYCURSOR); + yyaccept = 28; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') goto yy1298; + if (yych >= '5') goto yy1298; +yy1297: + YYDEBUG(1297, *YYCURSOR); + yyaccept = 28; + YYMARKER = ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; +yy1298: + YYDEBUG(1298, *YYCURSOR); + if (yych <= 'A') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy1297; + goto yy1295; + } else { + if (yych <= ' ') goto yy1297; + if (yych <= '@') goto yy1295; + } + } else { + if (yych <= '`') { + if (yych != 'P') goto yy1295; + } else { + if (yych <= 'a') goto yy1299; + if (yych != 'p') goto yy1295; + } } -yy1429: +yy1299: + YYDEBUG(1299, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1430; - default: goto yy4; + if (yych <= 'L') { + if (yych != '.') goto yy57; + } else { + if (yych <= 'M') goto yy1301; + if (yych == 'm') goto yy1301; + goto yy57; } -yy1430: + YYDEBUG(1300, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'H': - case 'h': goto yy1239; - default: goto yy4; + if (yych == 'M') goto yy1301; + if (yych != 'm') goto yy57; +yy1301: + YYDEBUG(1301, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy1303; + if (yych == '\t') goto yy1303; + goto yy57; + } else { + if (yych <= ' ') goto yy1303; + if (yych != '.') goto yy57; } -yy1431: + YYDEBUG(1302, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '\t') { + if (yych <= 0x00) goto yy1303; + if (yych <= 0x08) goto yy57; + } else { + if (yych != ' ') goto yy57; + } +yy1303: + YYDEBUG(1303, *YYCURSOR); + yych = *++YYCURSOR; + goto yy1295; +yy1304: + YYDEBUG(1304, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'N': goto yy1429; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'n': goto yy1461; - default: goto yy4; + if (yych <= 'B') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'C') goto yy1288; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'b') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'c') goto yy1305; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1432: +yy1305: + YYDEBUG(1305, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'I': goto yy1421; - case 'U': goto yy1422; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'i': goto yy1453; - case 'u': goto yy1454; - default: goto yy4; + if (yych <= 'J') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'K') goto yy1289; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'j') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'k') goto yy1306; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1306: + YYDEBUG(1306, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= '(') { + if (yych == ' ') goto yy1290; + goto yy4; + } else { + if (yych <= ')') goto yy140; + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '^') { + if (yych <= '/') goto yy148; + if (yych <= '@') goto yy4; + if (yych <= 'Z') goto yy144; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy152; + goto yy4; + } } -yy1433: +yy1307: + YYDEBUG(1307, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'R') goto yy142; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 's') goto yy1308; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1308: + YYDEBUG(1308, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1309; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1309: + YYDEBUG(1309, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'D': goto yy1410; - case 'M': goto yy1411; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'd': goto yy1444; - case 'm': goto yy1445; - default: goto yy4; + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy4; + goto yy1105; + } else { + if (yych != ' ') goto yy4; + } + } else { + if (yych <= 'Z') { + if (yych <= ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy144; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1434: - yyaccept = 0; +yy1310: + YYDEBUG(1310, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1311; + if (yych != 'd') goto yy1106; +yy1311: + YYDEBUG(1311, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1312; + if (yych != 'a') goto yy57; +yy1312: + YYDEBUG(1312, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1313; + if (yych != 'y') goto yy57; +yy1313: + YYDEBUG(1313, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'E': goto yy1406; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'e': goto yy1440; - default: goto yy4; + if (yych <= 'R') { + if (yych != ' ') goto yy1118; + } else { + if (yych <= 'S') goto yy1143; + if (yych == 's') goto yy1143; + goto yy1118; } -yy1435: + YYDEBUG(1314, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy1315; + if (yych != 'o') goto yy57; +yy1315: + YYDEBUG(1315, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'F') goto yy1316; + if (yych != 'f') goto yy57; +yy1316: + YYDEBUG(1316, *YYCURSOR); + yych = *++YYCURSOR; + goto yy2; +yy1317: + YYDEBUG(1317, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'E': goto yy1402; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'e': goto yy1436; - default: goto yy4; + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy1308; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 's') goto yy1318; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1436: +yy1318: + YYDEBUG(1318, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'L': goto yy1403; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'l': goto yy1437; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1309; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1319; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1437: +yy1319: + YYDEBUG(1319, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'F': goto yy1404; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'f': goto yy1438; - default: goto yy4; + if (yych <= '-') { + if (yych <= ' ') { + if (yych == '\t') goto yy1105; + if (yych <= 0x1F) goto yy4; + goto yy1310; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } + } else { + if (yych <= 'Z') { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1438: +yy1320: + YYDEBUG(1320, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'B') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'A') goto yy142; + goto yy1356; + } + } else { + if (yych <= 'a') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'b') goto yy1356; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1321: + YYDEBUG(1321, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'R') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'F') goto yy1346; + if (yych <= 'Q') goto yy142; + goto yy1345; + } + } else { + if (yych <= 'f') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'e') goto yy142; + goto yy1346; + } else { + if (yych == 'r') goto yy1345; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1322: + YYDEBUG(1322, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'T') goto yy142; + goto yy1342; + } + } else { + if (yych <= 't') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'u') goto yy1342; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1323: + YYDEBUG(1323, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'I') goto yy1325; + if (yych <= 'N') goto yy142; + } + } else { + if (yych <= 'i') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'h') goto yy142; + goto yy1325; + } else { + if (yych == 'o') goto yy1324; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1324: + YYDEBUG(1324, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy143; + goto yy1328; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'n') goto yy1328; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1325: + YYDEBUG(1325, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy167; + goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'C') goto yy143; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy167; + goto yy143; + } else { + if (yych <= 'd') goto yy1326; + if (yych <= 'z') goto yy143; + goto yy167; + } + } +yy1326: + YYDEBUG(1326, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy144; + goto yy4; + } else { + if (yych <= 'a') goto yy1327; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1327: + YYDEBUG(1327, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'Y') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'X') goto yy145; + goto yy1236; + } + } else { + if (yych <= 'x') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'y') goto yy1236; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1328: + YYDEBUG(1328, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy144; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 't') goto yy1329; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1329: + YYDEBUG(1329, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'T': goto yy1405; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 't': goto yy1439; - default: goto yy4; + if (yych <= ')') { + if (yych == ' ') goto yy1330; + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= 'Z') { + if (yych <= '@') goto yy4; + goto yy145; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1330: + YYDEBUG(1330, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy1331; + if (yych != 'o') goto yy57; +yy1331: + YYDEBUG(1331, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'F') goto yy1332; + if (yych != 'f') goto yy57; +yy1332: + YYDEBUG(1332, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != ' ') goto yy57; + YYDEBUG(1333, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '1') goto yy1334; + if (yych <= '2') goto yy1335; + if (yych <= '9') goto yy1336; + goto yy57; +yy1334: + YYDEBUG(1334, *YYCURSOR); + yyaccept = 28; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') goto yy1337; + if (yych <= '9') goto yy1336; + goto yy1337; +yy1335: + YYDEBUG(1335, *YYCURSOR); + yyaccept = 28; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') goto yy1337; + if (yych >= '5') goto yy1337; +yy1336: + YYDEBUG(1336, *YYCURSOR); + yyaccept = 28; + YYMARKER = ++YYCURSOR; + if ((YYLIMIT - YYCURSOR) < 5) YYFILL(5); + yych = *YYCURSOR; +yy1337: + YYDEBUG(1337, *YYCURSOR); + if (yych <= 'A') { + if (yych <= 0x1F) { + if (yych == '\t') goto yy1336; + goto yy1295; + } else { + if (yych <= ' ') goto yy1336; + if (yych <= '@') goto yy1295; + } + } else { + if (yych <= '`') { + if (yych != 'P') goto yy1295; + } else { + if (yych <= 'a') goto yy1338; + if (yych != 'p') goto yy1295; + } + } +yy1338: + YYDEBUG(1338, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych != '.') goto yy57; + } else { + if (yych <= 'M') goto yy1340; + if (yych == 'm') goto yy1340; + goto yy57; + } + YYDEBUG(1339, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'M') goto yy1340; + if (yych != 'm') goto yy57; +yy1340: + YYDEBUG(1340, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 0x1F) { + if (yych <= 0x00) goto yy1303; + if (yych == '\t') goto yy1303; + goto yy57; + } else { + if (yych <= ' ') goto yy1303; + if (yych != '.') goto yy57; + } + YYDEBUG(1341, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '\t') { + if (yych <= 0x00) goto yy1303; + if (yych <= 0x08) goto yy57; + goto yy1303; + } else { + if (yych == ' ') goto yy1303; + goto yy57; + } +yy1342: + YYDEBUG(1342, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy143; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'r') goto yy1343; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1343: + YYDEBUG(1343, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy144; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 't') goto yy1344; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1344: + YYDEBUG(1344, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy145; + goto yy1216; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'h') goto yy1216; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1345: + YYDEBUG(1345, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'R') goto yy143; + goto yy1348; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 's') goto yy1348; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1439: +yy1346: + YYDEBUG(1346, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1347; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1347: + YYDEBUG(1347, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy144; + goto yy1239; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'h') goto yy1239; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1348: + YYDEBUG(1348, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy144; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 't') goto yy1349; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1349: + YYDEBUG(1349, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'H': goto yy1206; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'h': goto yy1224; - default: goto yy4; + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy4; + goto yy1207; + } else { + if (yych != ' ') goto yy4; + } + } else { + if (yych <= 'Z') { + if (yych <= ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy145; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1440: - yyaccept = 4; +yy1350: + YYDEBUG(1350, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy1351; + if (yych != 'd') goto yy1208; +yy1351: + YYDEBUG(1351, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy1352; + if (yych != 'a') goto yy57; +yy1352: + YYDEBUG(1352, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy1353; + if (yych != 'y') goto yy57; +yy1353: + YYDEBUG(1353, *YYCURSOR); + yyaccept = 26; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'S': goto yy1407; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 's': goto yy1441; - default: goto yy167; + if (yych <= 'R') { + if (yych != ' ') goto yy1118; + } else { + if (yych <= 'S') goto yy1143; + if (yych == 's') goto yy1143; + goto yy1118; } -yy1441: - yyaccept = 0; + YYDEBUG(1354, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'O') goto yy1355; + if (yych != 'o') goto yy57; +yy1355: + YYDEBUG(1355, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'F') goto yy1316; + if (yych == 'f') goto yy1316; + goto yy57; +yy1356: + YYDEBUG(1356, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'D': goto yy1408; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'd': goto yy1442; - default: goto yy4; + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'R') goto yy143; + } + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'r') goto yy1357; + if (yych <= 'z') goto yy143; + goto yy194; + } + } } -yy1442: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1409; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': goto yy1443; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy4; +yy1357: + YYDEBUG(1357, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'T') goto yy144; + } + } else { + if (yych <= 't') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'u') goto yy1358; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1443: +yy1358: + YYDEBUG(1358, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy145; + goto yy4; + } else { + if (yych <= 'a') goto yy1359; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1359: + YYDEBUG(1359, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'Y': goto yy173; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy154; - case 'y': goto yy186; - default: goto yy4; + if (yych <= 'Q') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'R') goto yy1360; + if (yych != 'r') goto yy4; } -yy1444: +yy1360: + YYDEBUG(1360, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy206; + if (yych == 'y') goto yy206; + goto yy57; +yy1361: + YYDEBUG(1361, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1418; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'a': goto yy1451; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - default: goto yy4; + if (yych <= 'A') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'B') goto yy1356; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'b') goto yy1379; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1445: +yy1362: + YYDEBUG(1362, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'O': goto yy1412; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'o': goto yy1446; - default: goto yy4; + if (yych <= 'Q') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych <= '/') goto yy148; + goto yy4; + } else { + if (yych == 'F') goto yy1346; + goto yy142; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'R') goto yy1345; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'q') { + if (yych == 'f') goto yy1375; + goto yy147; + } else { + if (yych <= 'r') goto yy1374; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1446: +yy1363: + YYDEBUG(1363, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'R': goto yy1413; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'r': goto yy1447; - default: goto yy4; + if (yych <= 'T') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'U') goto yy1342; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 't') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'u') goto yy1371; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1364: + YYDEBUG(1364, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych <= '/') goto yy148; + goto yy4; + } else { + if (yych == 'I') goto yy1325; + goto yy142; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'O') goto yy1324; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'n') { + if (yych == 'i') goto yy1366; + goto yy147; + } else { + if (yych <= 'o') goto yy1365; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1365: + YYDEBUG(1365, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1328; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'n') goto yy1369; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1366: + YYDEBUG(1366, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1326; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 'd') goto yy1367; + if (yych <= 'z') goto yy151; + goto yy167; + } + } } -yy1447: +yy1367: + YYDEBUG(1367, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'R': goto yy1414; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'r': goto yy1448; - default: goto yy4; + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1327; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1368; + if (yych <= 'z') goto yy152; + goto yy4; + } } -yy1448: +yy1368: + YYDEBUG(1368, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'O': goto yy1415; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'o': goto yy1449; - default: goto yy4; - } -yy1449: - yych = *++YYCURSOR; - switch (yych) { - case 'W': goto yy1416; - case 'w': goto yy1450; - default: goto yy155; + if (yych <= 'X') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'Y') goto yy1236; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'x') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'y') goto yy1265; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1450: - yyaccept = 29; +yy1369: + YYDEBUG(1369, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy1417; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1329; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 't') goto yy1370; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1451: +yy1370: + YYDEBUG(1370, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': goto yy144; - case 'Y': goto yy1419; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy152; - case 'y': goto yy1452; - default: goto yy4; + if (yych <= '.') { + if (yych <= '(') { + if (yych == ' ') goto yy1330; + goto yy4; + } else { + if (yych <= ')') goto yy140; + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '^') { + if (yych <= '/') goto yy148; + if (yych <= '@') goto yy4; + if (yych <= 'Z') goto yy145; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy153; + goto yy4; + } } -yy1452: - yyaccept = 30; +yy1371: + YYDEBUG(1371, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - default: goto yy1420; + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy1343; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'r') goto yy1372; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1453: +yy1372: + YYDEBUG(1372, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'R': goto yy1427; - case 'S': goto yy1428; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'r': goto yy1459; - case 's': goto yy1460; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1344; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 't') goto yy1373; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1454: - yyaccept = 4; +yy1373: + YYDEBUG(1373, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'R': goto yy1423; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'r': goto yy1455; - default: goto yy167; + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy1216; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'h') goto yy1228; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1455: +yy1374: + YYDEBUG(1374, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'S': goto yy1424; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 's': goto yy1456; - default: goto yy4; + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy1348; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 's') goto yy1377; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1456: +yy1375: + YYDEBUG(1375, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'D': goto yy1425; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'd': goto yy1457; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1347; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1376; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1376: + YYDEBUG(1376, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy1239; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'h') goto yy1268; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1457: +yy1377: + YYDEBUG(1377, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1426; - case 'a': goto yy1458; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1349; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 't') goto yy1378; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1458: - yych = *++YYCURSOR; - switch (yych) { - case 'Y': goto yy173; - case 'y': goto yy186; - default: goto yy155; +yy1378: + YYDEBUG(1378, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '-') { + if (yych <= ' ') { + if (yych == '\t') goto yy1207; + if (yych <= 0x1F) goto yy4; + goto yy1350; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } + } else { + if (yych <= 'Z') { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1459: +yy1379: + YYDEBUG(1379, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'Q') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'R') goto yy1357; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'q') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'r') goto yy1380; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy1380: + YYDEBUG(1380, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'D': goto yy1239; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'd': goto yy1268; - default: goto yy4; + if (yych <= 'T') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'U') goto yy1358; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 't') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'u') goto yy1381; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1460: +yy1381: + YYDEBUG(1381, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': goto yy1105; - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1359; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1382; + if (yych <= 'z') goto yy153; + goto yy4; + } + } +yy1382: + YYDEBUG(1382, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'Q') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'R') goto yy1360; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'r') goto yy1383; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy1383: + YYDEBUG(1383, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy206; + if (yych == 'y') goto yy377; + goto yy155; +yy1384: + YYDEBUG(1384, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; +yy1385: + YYDEBUG(1385, *YYCURSOR); + ++YYCURSOR; + if (YYLIMIT <= YYCURSOR) YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(1386, *YYCURSOR); + if (yych <= '/') goto yy1387; + if (yych <= '9') goto yy1385; +yy1387: + YYDEBUG(1387, *YYCURSOR); +#line 1049 "ext/date/lib/parse_date.re" + { + timelib_ull i; + + TIMELIB_INIT; + TIMELIB_HAVE_RELATIVE(); + TIMELIB_UNHAVE_DATE(); + TIMELIB_UNHAVE_TIME(); + TIMELIB_HAVE_TZ(); + + i = timelib_get_unsigned_nr((char **) &ptr, 24); + s->time->y = 1970; + s->time->m = 1; + s->time->d = 1; + s->time->h = s->time->i = s->time->s = 0; + s->time->f = 0.0; + s->time->relative.s += i; + s->time->is_localtime = 1; + s->time->zone_type = TIMELIB_ZONETYPE_OFFSET; + s->time->z = 0; + + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; + } +#line 21370 "ext/date/lib/parse_date.c" +yy1388: + YYDEBUG(1388, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy142; + goto yy1429; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'n') goto yy1429; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1389: + YYDEBUG(1389, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'U') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'I') goto yy1421; + if (yych <= 'T') goto yy142; + goto yy1422; + } + } else { + if (yych <= 'i') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'h') goto yy142; + goto yy1421; + } else { + if (yych == 'u') goto yy1422; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1390: + YYDEBUG(1390, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'M') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'D') goto yy1410; + if (yych <= 'L') goto yy142; + goto yy1411; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'c') goto yy142; + goto yy1410; + } else { + if (yych == 'm') goto yy1411; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1391: + YYDEBUG(1391, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy142; + goto yy1406; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'e') goto yy1406; + if (yych <= 'z') goto yy142; + goto yy4; + } } -yy1461: - yyaccept = 0; +yy1392: + YYDEBUG(1392, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy142; + goto yy1402; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'e') goto yy1402; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1393: + YYDEBUG(1393, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy1065; + goto yy57; + } else { + if (yych <= '9') goto yy1396; + if (yych <= ':') goto yy1065; + goto yy57; + } +yy1394: + YYDEBUG(1394, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy1065; + goto yy57; + } else { + if (yych <= '4') goto yy1396; + if (yych == ':') goto yy1065; + goto yy57; + } +yy1395: + YYDEBUG(1395, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == '.') goto yy1065; + if (yych == ':') goto yy1065; + goto yy57; +yy1396: + YYDEBUG(1396, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') { + if (yych == '.') goto yy1065; + goto yy57; + } else { + if (yych <= '5') goto yy1397; + if (yych == ':') goto yy1065; + goto yy57; + } +yy1397: + YYDEBUG(1397, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych >= ':') goto yy57; + YYDEBUG(1398, *YYCURSOR); + yyaccept = 24; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1430; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1462; - default: goto yy4; + if (yych <= '/') goto yy1068; + if (yych <= '5') goto yy1399; + if (yych <= '6') goto yy1400; + goto yy1068; +yy1399: + YYDEBUG(1399, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= '/') goto yy57; + if (yych <= '9') goto yy1401; + goto yy57; +yy1400: + YYDEBUG(1400, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '0') goto yy57; +yy1401: + YYDEBUG(1401, *YYCURSOR); + yych = *++YYCURSOR; + goto yy1076; +yy1402: + YYDEBUG(1402, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'L') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'K') goto yy143; + } + } else { + if (yych <= 'k') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'l') goto yy1403; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1462: +yy1403: + YYDEBUG(1403, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'F') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'E') goto yy144; + } + } else { + if (yych <= 'e') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'f') goto yy1404; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1404: + YYDEBUG(1404, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy145; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 't') goto yy1405; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1405: + YYDEBUG(1405, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'H': goto yy1239; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'h': goto yy1268; - default: goto yy4; + if (yych <= 'G') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'H') goto yy1206; + if (yych == 'h') goto yy1206; + goto yy4; } -yy1463: +yy1406: + YYDEBUG(1406, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy142; - case 'R': - case 'r': goto yy1475; - case 'Y': - case 'y': goto yy1476; - default: goto yy4; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy167; + goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'R') goto yy143; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy167; + goto yy143; + } else { + if (yych <= 's') goto yy1407; + if (yych <= 'z') goto yy143; + goto yy167; + } + } +yy1407: + YYDEBUG(1407, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy144; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'd') goto yy1408; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1408: + YYDEBUG(1408, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy145; + goto yy4; + } else { + if (yych <= 'a') goto yy1409; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1409: + YYDEBUG(1409, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'X') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Y') goto yy173; + if (yych == 'y') goto yy173; + goto yy4; + } +yy1410: + YYDEBUG(1410, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy1418; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy143; + goto yy4; + } else { + if (yych <= 'a') goto yy1418; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1411: + YYDEBUG(1411, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'O') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'N') goto yy143; + } + } else { + if (yych <= 'n') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'o') goto yy1412; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1464: +yy1412: + YYDEBUG(1412, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'D': - case 'd': goto yy1469; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy144; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'r') goto yy1413; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1465: +yy1413: + YYDEBUG(1413, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'N': - case 'n': goto yy1466; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy145; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'r') goto yy1414; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1466: +yy1414: + YYDEBUG(1414, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'O') goto yy1415; + if (yych != 'o') goto yy4; + } +yy1415: + YYDEBUG(1415, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'D': - case 'd': goto yy1467; - default: goto yy167; + if (yych == 'W') goto yy1416; + if (yych != 'w') goto yy57; +yy1416: + YYDEBUG(1416, *YYCURSOR); + ++YYCURSOR; +yy1417: + YYDEBUG(1417, *YYCURSOR); +#line 1037 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("tomorrow"); + TIMELIB_INIT; + TIMELIB_HAVE_RELATIVE(); + TIMELIB_UNHAVE_TIME(); + + s->time->relative.d = 1; + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; } -yy1467: +#line 21817 "ext/date/lib/parse_date.c" +yy1418: + YYDEBUG(1418, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'a': goto yy1468; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy4; + if (yych <= 'Y') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'X') goto yy144; + } + } else { + if (yych <= 'x') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'y') goto yy1419; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1419: + YYDEBUG(1419, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= '@') { + if (yych == ')') goto yy140; + } else { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy1420; + if (yych <= 'z') goto yy145; + } +yy1420: + YYDEBUG(1420, *YYCURSOR); +#line 1027 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("midnight | today"); + TIMELIB_INIT; + TIMELIB_UNHAVE_TIME(); + + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; } -yy1468: +#line 21861 "ext/date/lib/parse_date.c" +yy1421: + YYDEBUG(1421, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy145; - case 'Y': - case 'y': goto yy1236; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'Q') goto yy143; + if (yych <= 'R') goto yy1427; + goto yy1428; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'r') goto yy1427; + if (yych <= 's') goto yy1428; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1469: +yy1422: + YYDEBUG(1422, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'N': - case 'n': goto yy1470; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy167; + goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'Q') goto yy143; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy167; + goto yy143; + } else { + if (yych <= 'r') goto yy1423; + if (yych <= 'z') goto yy143; + goto yy167; + } } -yy1470: +yy1423: + YYDEBUG(1423, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'I': - case 'i': goto yy1471; - default: goto yy4; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'R') goto yy144; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 's') goto yy1424; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1471: +yy1424: + YYDEBUG(1424, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'G': - case 'g': goto yy1472; - default: goto yy4; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy145; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'd') goto yy1425; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1425: + YYDEBUG(1425, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'A') goto yy1426; + if (yych != 'a') goto yy4; + } +yy1426: + YYDEBUG(1426, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy173; + if (yych == 'y') goto yy173; + goto yy57; +yy1427: + YYDEBUG(1427, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy144; + goto yy1239; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'd') goto yy1239; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1472: +yy1428: + YYDEBUG(1428, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'H': - case 'h': goto yy1473; - default: goto yy4; + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy4; + goto yy1105; + } else { + if (yych == ' ') goto yy1105; + goto yy4; + } + } else { + if (yych <= 'Z') { + if (yych <= ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy144; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1473: +yy1429: + YYDEBUG(1429, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'T': - case 't': goto yy1474; - default: goto yy57; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1430; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1474: +yy1430: + YYDEBUG(1430, *YYCURSOR); yych = *++YYCURSOR; - goto yy1420; -yy1475: - yyaccept = 5; + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy144; + goto yy1239; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'h') goto yy1239; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1431: + YYDEBUG(1431, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'C': - case 'c': goto yy1477; - default: goto yy194; + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1429; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'n') goto yy1461; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1476: - yyaccept = 5; +yy1432: + YYDEBUG(1432, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy194; + if (yych <= 'T') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych <= '/') goto yy148; + goto yy4; + } else { + if (yych == 'I') goto yy1421; + goto yy142; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'U') goto yy1422; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 't') { + if (yych == 'i') goto yy1453; + goto yy147; + } else { + if (yych <= 'u') goto yy1454; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1477: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'H': - case 'h': goto yy396; - default: goto yy4; +yy1433: + YYDEBUG(1433, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych <= '/') goto yy148; + goto yy4; + } else { + if (yych == 'D') goto yy1410; + goto yy142; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'M') goto yy1411; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'l') { + if (yych == 'd') goto yy1444; + goto yy147; + } else { + if (yych <= 'm') goto yy1445; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1478: +yy1434: + YYDEBUG(1434, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': goto yy142; - case 'R': goto yy1475; - case 'Y': goto yy1476; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy147; - case 'r': goto yy1490; - case 'y': goto yy1491; - default: goto yy4; + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1406; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'e') goto yy1440; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1479: +yy1435: + YYDEBUG(1435, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'D': goto yy1469; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'd': goto yy1484; - default: goto yy4; + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1402; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'e') goto yy1436; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1480: +yy1436: + YYDEBUG(1436, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'N': goto yy1466; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'n': goto yy1481; - default: goto yy4; + if (yych <= 'K') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'L') goto yy1403; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'k') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'l') goto yy1437; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1481: - yyaccept = 4; +yy1437: + YYDEBUG(1437, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'D': goto yy1467; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'd': goto yy1482; - default: goto yy167; + if (yych <= 'E') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'F') goto yy1404; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'e') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'f') goto yy1438; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy1438: + YYDEBUG(1438, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1405; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 't') goto yy1439; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy1439: + YYDEBUG(1439, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'H') goto yy1206; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'h') goto yy1224; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1482: +yy1440: + YYDEBUG(1440, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy1407; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 's') goto yy1441; + if (yych <= 'z') goto yy151; + goto yy167; + } + } + } +yy1441: + YYDEBUG(1441, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': goto yy1468; - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': goto yy1483; - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy4; + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1408; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'd') goto yy1442; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1483: +yy1442: + YYDEBUG(1442, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Z': goto yy145; - case 'Y': goto yy1236; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'z': goto yy153; - case 'y': goto yy1265; - default: goto yy4; + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1409; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1443; + if (yych <= 'z') goto yy153; + goto yy4; + } } -yy1484: +yy1443: + YYDEBUG(1443, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'N': goto yy1470; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'n': goto yy1485; - default: goto yy4; + if (yych <= 'X') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'Y') goto yy173; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'y') goto yy186; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1485: +yy1444: + YYDEBUG(1444, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'I': goto yy1471; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'i': goto yy1486; - default: goto yy4; + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1418; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1451; + if (yych <= 'z') goto yy151; + goto yy4; + } + } +yy1445: + YYDEBUG(1445, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'O') goto yy1412; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'n') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'o') goto yy1446; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1486: +yy1446: + YYDEBUG(1446, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'G': goto yy1472; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'g': goto yy1487; - default: goto yy4; + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy1413; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'r') goto yy1447; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1487: +yy1447: + YYDEBUG(1447, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'H': goto yy1473; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'h': goto yy1488; - default: goto yy4; + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy1414; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'r') goto yy1448; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1488: +yy1448: + YYDEBUG(1448, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'N') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'O') goto yy1415; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'o') goto yy1449; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy1449: + YYDEBUG(1449, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'T': goto yy1474; - case 't': goto yy1489; - default: goto yy155; + if (yych == 'W') goto yy1416; + if (yych != 'w') goto yy155; + YYDEBUG(1450, *YYCURSOR); + yyaccept = 29; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; + } + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy1417; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy1417; + } +yy1451: + YYDEBUG(1451, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'Y') goto yy1419; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'x') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'y') goto yy1452; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1489: +yy1452: + YYDEBUG(1452, *YYCURSOR); yyaccept = 30; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy1420; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy1420; + } else { + if (yych == '.') goto yy1420; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy1420; + if (yych <= 'Z') goto yy145; + goto yy1420; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy1420; + if (yych <= 'z') goto yy153; + goto yy1420; + } } -yy1490: - yyaccept = 5; +yy1453: + YYDEBUG(1453, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'C': goto yy1477; - case 'a': - case 'b': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'c': goto yy1492; - default: goto yy194; + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych <= '/') { + if (yych <= '.') goto yy4; + goto yy148; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy143; + goto yy1427; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'S') goto yy1428; + goto yy143; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'r') { + if (yych <= 'q') goto yy151; + goto yy1459; + } else { + if (yych <= 's') goto yy1460; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1454: + YYDEBUG(1454, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy1423; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 'r') goto yy1455; + if (yych <= 'z') goto yy151; + goto yy167; + } + } + } +yy1455: + YYDEBUG(1455, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy1424; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 's') goto yy1456; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy1456: + YYDEBUG(1456, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1425; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'd') goto yy1457; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1491: - yyaccept = 5; +yy1457: + YYDEBUG(1457, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - default: goto yy194; + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1426; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1458; + if (yych <= 'z') goto yy154; + goto yy4; + } } -yy1492: +yy1458: + YYDEBUG(1458, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy173; + if (yych == 'y') goto yy186; + goto yy155; +yy1459: + YYDEBUG(1459, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'H': goto yy396; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'h': goto yy407; - default: goto yy4; + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1239; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'd') goto yy1268; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1493: +yy1460: + YYDEBUG(1460, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '-') { + if (yych <= ' ') { + if (yych == '\t') goto yy1105; + if (yych <= 0x1F) goto yy4; + goto yy1105; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } + } else { + if (yych <= 'Z') { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy1461: + YYDEBUG(1461, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1430; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1462; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1462: + YYDEBUG(1462, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy1239; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'h') goto yy1268; + if (yych <= 'z') goto yy152; + goto yy4; + } + } + } +yy1463: + YYDEBUG(1463, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'x': - case 'y': - case 'z': goto yy142; - case 'O': - case 'o': goto yy1501; - case 'V': - case 'v': goto yy1502; - case 'W': - case 'w': goto yy1499; - default: goto yy4; + if (yych <= 'Y') { + if (yych <= '@') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == 'R') goto yy1475; + if (yych <= 'X') goto yy142; + goto yy1476; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'q') goto yy142; + goto yy1475; + } else { + if (yych == 'y') goto yy1476; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1464: + YYDEBUG(1464, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'C') goto yy142; + goto yy1469; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'd') goto yy1469; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1465: + YYDEBUG(1465, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy142; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'n') goto yy1466; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1466: + YYDEBUG(1466, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'D') { + if (yych <= ')') { + if (yych <= '(') goto yy167; + goto yy140; + } else { + if (yych <= '@') goto yy167; + if (yych <= 'C') goto yy143; + } + } else { + if (yych <= 'c') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy167; + goto yy143; + } else { + if (yych <= 'd') goto yy1467; + if (yych <= 'z') goto yy143; + goto yy167; + } } -yy1494: +yy1467: + YYDEBUG(1467, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'y': - case 'z': goto yy142; - case 'X': - case 'x': goto yy1498; - default: goto yy4; + if (yych <= 'A') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + } else { + if (yych <= '`') { + if (yych <= 'Z') goto yy144; + goto yy4; + } else { + if (yych <= 'a') goto yy1468; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1495: +yy1468: + YYDEBUG(1468, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'N': - case 'n': goto yy1496; - default: goto yy4; + if (yych <= 'Y') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'X') goto yy145; + goto yy1236; + } + } else { + if (yych <= 'x') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'y') goto yy1236; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1496: +yy1469: + YYDEBUG(1469, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1497; - default: goto yy4; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy143; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'n') goto yy1470; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1497: +yy1470: + YYDEBUG(1470, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'H': - case 'h': goto yy1239; - default: goto yy4; + if (yych <= 'I') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'H') goto yy144; + } + } else { + if (yych <= 'h') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'i') goto yy1471; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1471: + YYDEBUG(1471, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'G') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'F') goto yy145; + } + } else { + if (yych <= 'f') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'g') goto yy1472; + if (yych <= 'z') goto yy145; + goto yy4; + } + } +yy1472: + YYDEBUG(1472, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'H') goto yy1473; + if (yych != 'h') goto yy4; + } +yy1473: + YYDEBUG(1473, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy1474; + if (yych != 't') goto yy57; +yy1474: + YYDEBUG(1474, *YYCURSOR); + yych = *++YYCURSOR; + goto yy1420; +yy1475: + YYDEBUG(1475, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych == 'C') goto yy1477; + goto yy143; + } + } else { + if (yych <= 'b') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'c') goto yy1477; + if (yych <= 'z') goto yy143; + goto yy194; + } + } } -yy1498: +yy1476: + YYDEBUG(1476, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '-') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy194; + goto yy196; + } else { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy197; + } + } else { + if (yych <= '@') { + if (yych == '/') goto yy194; + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy194; + if (yych <= 'z') goto yy143; + goto yy194; + } + } +yy1477: + YYDEBUG(1477, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1428; - default: goto yy4; + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy144; + goto yy396; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'h') goto yy396; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1499: - ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - default: goto yy1500; +yy1478: + YYDEBUG(1478, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= '@') { + if (yych <= '/') goto yy148; + goto yy4; + } else { + if (yych == 'R') goto yy1475; + goto yy142; + } + } + } else { + if (yych <= '`') { + if (yych <= 'Z') { + if (yych <= 'Y') goto yy1476; + goto yy142; + } else { + if (yych == '_') goto yy148; + goto yy4; + } + } else { + if (yych <= 'x') { + if (yych == 'r') goto yy1490; + goto yy147; + } else { + if (yych <= 'y') goto yy1491; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1500: -#line 1006 "ext/date/lib/parse_date.re" - { - DEBUG_OUTPUT("now"); - TIMELIB_INIT; - - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; +yy1479: + YYDEBUG(1479, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1469; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'd') goto yy1484; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -#line 37522 "" -yy1501: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'N': - case 'n': goto yy1507; - default: goto yy4; +yy1480: + YYDEBUG(1480, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1466; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'n') goto yy1481; + if (yych <= 'z') goto yy147; + goto yy4; + } + } + } +yy1481: + YYDEBUG(1481, *YYCURSOR); + yyaccept = 4; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'C') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy167; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy167; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'D') goto yy1467; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy167; + goto yy148; + } else { + if (yych <= 'c') { + if (yych <= '`') goto yy167; + goto yy151; + } else { + if (yych <= 'd') goto yy1482; + if (yych <= 'z') goto yy151; + goto yy167; + } + } + } +yy1482: + YYDEBUG(1482, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '@') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '_') { + if (yych <= 'A') goto yy1468; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= '`') goto yy4; + if (yych <= 'a') goto yy1483; + if (yych <= 'z') goto yy152; + goto yy4; + } + } +yy1483: + YYDEBUG(1483, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'X') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'Y') goto yy1236; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'x') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'y') goto yy1265; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } -yy1502: - yyaccept = 5; +yy1484: + YYDEBUG(1484, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy197; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'E': - case 'e': goto yy1503; - default: goto yy194; + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1470; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'n') goto yy1485; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1503: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'M': - case 'm': goto yy1504; - default: goto yy4; +yy1485: + YYDEBUG(1485, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'H') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'I') goto yy1471; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'h') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'i') goto yy1486; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1504: +yy1486: + YYDEBUG(1486, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'F') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'G') goto yy1472; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'f') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'g') goto yy1487; + if (yych <= 'z') goto yy153; + goto yy4; + } + } + } +yy1487: + YYDEBUG(1487, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'G') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'H') goto yy1473; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'h') goto yy1488; + if (yych <= 'z') goto yy154; + goto yy4; + } + } +yy1488: + YYDEBUG(1488, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'B': - case 'b': goto yy1505; - default: goto yy4; + if (yych == 'T') goto yy1474; + if (yych != 't') goto yy155; + YYDEBUG(1489, *YYCURSOR); + yyaccept = 30; + yych = *(YYMARKER = ++YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy154; } -yy1505: + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy1420; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy1420; + } +yy1490: + YYDEBUG(1490, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'B') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'C') goto yy1477; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'b') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'c') goto yy1492; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy1491: + YYDEBUG(1491, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '.') { + if (yych <= ' ') { + if (yych == '\t') goto yy196; + if (yych <= 0x1F) goto yy194; + goto yy196; + } else { + if (yych <= ')') { + if (yych <= '(') goto yy194; + goto yy140; + } else { + if (yych <= ',') goto yy194; + if (yych <= '-') goto yy372; + goto yy196; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '/') goto yy148; + if (yych <= '9') goto yy196; + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= '_') { + if (yych <= '^') goto yy194; + goto yy148; + } else { + if (yych <= '`') goto yy194; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy1492: + YYDEBUG(1492, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'E': - case 'e': goto yy1506; - default: goto yy4; + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy396; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'h') goto yy407; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1506: +yy1493: + YYDEBUG(1493, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'R': - case 'r': goto yy206; - default: goto yy57; + if (yych <= 'W') { + if (yych <= 'N') { + if (yych == ')') goto yy140; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'O') goto yy1501; + if (yych <= 'U') goto yy142; + if (yych <= 'V') goto yy1502; + goto yy1499; + } + } else { + if (yych <= 'o') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + if (yych <= 'n') goto yy142; + goto yy1501; + } else { + if (yych <= 'v') { + if (yych <= 'u') goto yy142; + goto yy1502; + } else { + if (yych <= 'w') goto yy1499; + if (yych <= 'z') goto yy142; + goto yy4; + } + } } -yy1507: +yy1494: + YYDEBUG(1494, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'X') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'W') goto yy142; + goto yy1498; + } + } else { + if (yych <= 'w') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'x') goto yy1498; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1495: + YYDEBUG(1495, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy142; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 'n') goto yy1496; + if (yych <= 'z') goto yy142; + goto yy4; + } + } +yy1496: + YYDEBUG(1496, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1497; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1497: + YYDEBUG(1497, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'H') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'G') goto yy144; + goto yy1239; + } + } else { + if (yych <= 'g') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'h') goto yy1239; + if (yych <= 'z') goto yy144; + goto yy4; + } + } +yy1498: + YYDEBUG(1498, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + goto yy1428; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1428; + if (yych <= 'z') goto yy143; + goto yy4; + } + } +yy1499: + YYDEBUG(1499, *YYCURSOR); ++YYCURSOR; - switch ((yych = *YYCURSOR)) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - default: goto yy1508; + if ((yych = *YYCURSOR) <= '@') { + if (yych == ')') goto yy140; + } else { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy1500; + if (yych <= 'z') goto yy143; } -yy1508: -#line 1015 "ext/date/lib/parse_date.re" +yy1500: + YYDEBUG(1500, *YYCURSOR); +#line 1006 "ext/date/lib/parse_date.re" { - DEBUG_OUTPUT("noon"); + DEBUG_OUTPUT("now"); TIMELIB_INIT; - TIMELIB_UNHAVE_TIME(); - TIMELIB_HAVE_TIME(); - s->time->h = 12; TIMELIB_DEINIT; return TIMELIB_RELATIVE; } -#line 37856 "" -yy1509: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'O': goto yy1501; - case 'V': goto yy1502; - case 'W': goto yy1499; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'x': - case 'y': - case 'z': goto yy147; - case 'o': goto yy1516; - case 'v': goto yy1517; - case 'w': goto yy1515; - default: goto yy4; +#line 23881 "ext/date/lib/parse_date.c" +yy1501: + YYDEBUG(1501, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'N') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'M') goto yy143; + goto yy1507; + } + } else { + if (yych <= 'm') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 'n') goto yy1507; + if (yych <= 'z') goto yy143; + goto yy4; + } } -yy1510: - yyaccept = 0; +yy1502: + YYDEBUG(1502, *YYCURSOR); + yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'Y': - case 'Z': goto yy142; - case 'X': goto yy1498; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'y': - case 'z': goto yy147; - case 'x': goto yy1514; - default: goto yy4; + if (yych <= '/') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= ',') { + if (yych <= ')') goto yy140; + goto yy194; + } else { + if (yych <= '-') goto yy197; + if (yych <= '.') goto yy196; + goto yy194; + } + } + } else { + if (yych <= 'Z') { + if (yych <= '@') { + if (yych <= '9') goto yy196; + goto yy194; + } else { + if (yych != 'E') goto yy143; + } + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy194; + goto yy143; + } else { + if (yych <= 'e') goto yy1503; + if (yych <= 'z') goto yy143; + goto yy194; + } + } + } +yy1503: + YYDEBUG(1503, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'M') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'L') goto yy144; + } + } else { + if (yych <= 'l') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'm') goto yy1504; + if (yych <= 'z') goto yy144; + goto yy4; + } } -yy1511: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'N': goto yy1496; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 'n': goto yy1512; - default: goto yy4; +yy1504: + YYDEBUG(1504, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'B') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'A') goto yy145; + } + } else { + if (yych <= 'a') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'b') goto yy1505; + if (yych <= 'z') goto yy145; + goto yy4; + } } -yy1512: +yy1505: + YYDEBUG(1505, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1497; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1513; - default: goto yy4; + if (yych <= 'D') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'E') goto yy1506; + if (yych != 'e') goto yy4; } -yy1513: +yy1506: + YYDEBUG(1506, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy206; + if (yych == 'r') goto yy206; + goto yy57; +yy1507: + YYDEBUG(1507, *YYCURSOR); + ++YYCURSOR; + if ((yych = *YYCURSOR) <= '@') { + if (yych == ')') goto yy140; + } else { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy1508; + if (yych <= 'z') goto yy144; + } +yy1508: + YYDEBUG(1508, *YYCURSOR); +#line 1015 "ext/date/lib/parse_date.re" + { + DEBUG_OUTPUT("noon"); + TIMELIB_INIT; + TIMELIB_UNHAVE_TIME(); + TIMELIB_HAVE_TIME(); + s->time->h = 12; + + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; + } +#line 24031 "ext/date/lib/parse_date.c" +yy1509: + YYDEBUG(1509, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'H': goto yy1239; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'h': goto yy1268; - default: goto yy4; + if (yych <= 'V') { + if (yych <= '.') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych == '-') goto yy148; + goto yy4; + } + } else { + if (yych <= 'N') { + if (yych <= '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } else { + if (yych <= 'O') goto yy1501; + if (yych <= 'U') goto yy142; + goto yy1502; + } + } + } else { + if (yych <= 'n') { + if (yych <= '^') { + if (yych <= 'W') goto yy1499; + if (yych <= 'Z') goto yy142; + goto yy4; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy4; + goto yy147; + } + } else { + if (yych <= 'v') { + if (yych <= 'o') goto yy1516; + if (yych <= 'u') goto yy147; + goto yy1517; + } else { + if (yych <= 'w') goto yy1515; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1514: +yy1510: + YYDEBUG(1510, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1428; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1460; - default: goto yy4; + if (yych <= 'W') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'X') goto yy1498; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'w') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'x') goto yy1514; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1515: - yyaccept = 31; +yy1511: + YYDEBUG(1511, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - default: goto yy1500; + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1496; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 'n') goto yy1512; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } -yy1516: +yy1512: + YYDEBUG(1512, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'N': goto yy1507; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'n': goto yy1522; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1497; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1513; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } -yy1517: - yyaccept = 5; +yy1513: + YYDEBUG(1513, *YYCURSOR); + yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '\t': - case ' ': - case '.': - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': goto yy196; - case ')': goto yy140; - case '-': goto yy372; - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'E': goto yy1503; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 'e': goto yy1518; - default: goto yy194; + if (yych <= 'G') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'H') goto yy1239; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'g') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'h') goto yy1268; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } -yy1518: +yy1514: + YYDEBUG(1514, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'M': goto yy1504; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'm': goto yy1519; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1428; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1460; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1515: + YYDEBUG(1515, *YYCURSOR); + yyaccept = 31; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy1500; + } else { + if (yych == '.') goto yy1500; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy1500; + if (yych <= 'Z') goto yy143; + goto yy1500; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy1500; + if (yych <= 'z') goto yy151; + goto yy1500; + } + } +yy1516: + YYDEBUG(1516, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'M') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'N') goto yy1507; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'm') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 'n') goto yy1522; + if (yych <= 'z') goto yy151; + goto yy4; + } + } + } +yy1517: + YYDEBUG(1517, *YYCURSOR); + yyaccept = 5; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= '9') { + if (yych <= '(') { + if (yych <= '\t') { + if (yych <= 0x08) goto yy194; + goto yy196; + } else { + if (yych == ' ') goto yy196; + goto yy194; + } + } else { + if (yych <= '-') { + if (yych <= ')') goto yy140; + if (yych <= ',') goto yy194; + goto yy372; + } else { + if (yych == '/') goto yy148; + goto yy196; + } + } + } else { + if (yych <= '^') { + if (yych <= 'D') { + if (yych <= '@') goto yy194; + goto yy143; + } else { + if (yych <= 'E') goto yy1503; + if (yych <= 'Z') goto yy143; + goto yy194; + } + } else { + if (yych <= 'd') { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy194; + goto yy151; + } else { + if (yych <= 'e') goto yy1518; + if (yych <= 'z') goto yy151; + goto yy194; + } + } + } +yy1518: + YYDEBUG(1518, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'L') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'M') goto yy1504; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'l') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'm') goto yy1519; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } yy1519: + YYDEBUG(1519, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'B': goto yy1505; - case 'a': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'b': goto yy1520; - default: goto yy4; + if (yych <= 'A') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'B') goto yy1505; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'a') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'b') goto yy1520; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } yy1520: + YYDEBUG(1520, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'E': goto yy1506; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'e': goto yy1521; - default: goto yy4; + if (yych <= 'D') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'E') goto yy1506; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'e') goto yy1521; + if (yych <= 'z') goto yy154; + goto yy4; + } } yy1521: + YYDEBUG(1521, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'R': goto yy206; - case 'r': goto yy377; - default: goto yy155; - } + if (yych == 'R') goto yy206; + if (yych == 'r') goto yy377; + goto yy155; yy1522: + YYDEBUG(1522, *YYCURSOR); yyaccept = 32; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - default: goto yy1508; - } -yy1523: - yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy142; - case 'S': - case 's': goto yy1524; - default: goto yy4; + if (yych <= '/') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy1508; + } else { + if (yych == '.') goto yy1508; + goto yy148; + } + } else { + if (yych <= '^') { + if (yych <= '@') goto yy1508; + if (yych <= 'Z') goto yy144; + goto yy1508; + } else { + if (yych <= '_') goto yy148; + if (yych <= '`') goto yy1508; + if (yych <= 'z') goto yy152; + goto yy1508; + } + } +yy1523: + YYDEBUG(1523, *YYCURSOR); + yych = *++YYCURSOR; + if (yych <= 'S') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'R') goto yy142; + } + } else { + if (yych <= 'r') { + if (yych <= 'Z') goto yy142; + if (yych <= '`') goto yy4; + goto yy142; + } else { + if (yych <= 's') goto yy1524; + if (yych <= 'z') goto yy142; + goto yy4; + } } yy1524: + YYDEBUG(1524, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy143; - case 'T': - case 't': goto yy1525; - default: goto yy4; + if (yych <= 'T') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'S') goto yy143; + } + } else { + if (yych <= 's') { + if (yych <= 'Z') goto yy143; + if (yych <= '`') goto yy4; + goto yy143; + } else { + if (yych <= 't') goto yy1525; + if (yych <= 'z') goto yy143; + goto yy4; + } } yy1525: + YYDEBUG(1525, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy144; - case 'E': - case 'e': goto yy1526; - default: goto yy4; + if (yych <= 'E') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'D') goto yy144; + } + } else { + if (yych <= 'd') { + if (yych <= 'Z') goto yy144; + if (yych <= '`') goto yy4; + goto yy144; + } else { + if (yych <= 'e') goto yy1526; + if (yych <= 'z') goto yy144; + goto yy4; + } } yy1526: + YYDEBUG(1526, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case ')': goto yy140; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy145; - case 'R': - case 'r': goto yy1527; - default: goto yy4; + if (yych <= 'R') { + if (yych <= ')') { + if (yych <= '(') goto yy4; + goto yy140; + } else { + if (yych <= '@') goto yy4; + if (yych <= 'Q') goto yy145; + } + } else { + if (yych <= 'q') { + if (yych <= 'Z') goto yy145; + if (yych <= '`') goto yy4; + goto yy145; + } else { + if (yych <= 'r') goto yy1527; + if (yych <= 'z') goto yy145; + goto yy4; + } } yy1527: + YYDEBUG(1527, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case 'D': - case 'd': goto yy1528; - default: goto yy4; + if (yych <= 'C') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych <= 'D') goto yy1528; + if (yych != 'd') goto yy4; } yy1528: + YYDEBUG(1528, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': - case 'a': goto yy1529; - default: goto yy57; - } + if (yych == 'A') goto yy1529; + if (yych != 'a') goto yy57; yy1529: + YYDEBUG(1529, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': - case 'y': goto yy1530; - default: goto yy57; - } + if (yych == 'Y') goto yy1530; + if (yych != 'y') goto yy57; yy1530: + YYDEBUG(1530, *YYCURSOR); ++YYCURSOR; yy1531: + YYDEBUG(1531, *YYCURSOR); #line 994 "ext/date/lib/parse_date.re" { DEBUG_OUTPUT("yesterday"); TIMELIB_INIT; - TIMELIB_HAVE_RELATIVE(); - TIMELIB_UNHAVE_TIME(); - - s->time->relative.d = -1; - TIMELIB_DEINIT; - return TIMELIB_RELATIVE; - } -#line 38927 "" -yy1532: - yyaccept = 0; - yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy142; - case 'S': goto yy1524; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy147; - case 's': goto yy1533; - default: goto yy4; + TIMELIB_HAVE_RELATIVE(); + TIMELIB_UNHAVE_TIME(); + + s->time->relative.d = -1; + TIMELIB_DEINIT; + return TIMELIB_RELATIVE; + } +#line 24575 "ext/date/lib/parse_date.c" +yy1532: + YYDEBUG(1532, *YYCURSOR); + yyaccept = 0; + yych = *(YYMARKER = ++YYCURSOR); + if (yych <= 'R') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy142; + } + } else { + if (yych <= '_') { + if (yych <= 'S') goto yy1524; + if (yych <= 'Z') goto yy142; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'r') { + if (yych <= '`') goto yy4; + goto yy147; + } else { + if (yych <= 's') goto yy1533; + if (yych <= 'z') goto yy147; + goto yy4; + } + } } yy1533: + YYDEBUG(1533, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy143; - case 'T': goto yy1525; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy151; - case 't': goto yy1534; - default: goto yy4; + if (yych <= 'S') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy143; + } + } else { + if (yych <= '_') { + if (yych <= 'T') goto yy1525; + if (yych <= 'Z') goto yy143; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 's') { + if (yych <= '`') goto yy4; + goto yy151; + } else { + if (yych <= 't') goto yy1534; + if (yych <= 'z') goto yy151; + goto yy4; + } + } } yy1534: + YYDEBUG(1534, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'R': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy144; - case 'E': goto yy1526; - case 'a': - case 'b': - case 'c': - case 'd': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy152; - case 'e': goto yy1535; - default: goto yy4; + if (yych <= 'D') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy144; + } + } else { + if (yych <= '_') { + if (yych <= 'E') goto yy1526; + if (yych <= 'Z') goto yy144; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'd') { + if (yych <= '`') goto yy4; + goto yy152; + } else { + if (yych <= 'e') goto yy1535; + if (yych <= 'z') goto yy152; + goto yy4; + } + } } yy1535: + YYDEBUG(1535, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'A': - case 'B': - case 'C': - case 'D': - case 'E': - case 'F': - case 'G': - case 'H': - case 'I': - case 'J': - case 'K': - case 'L': - case 'M': - case 'N': - case 'O': - case 'P': - case 'Q': - case 'S': - case 'T': - case 'U': - case 'V': - case 'W': - case 'X': - case 'Y': - case 'Z': goto yy145; - case 'R': goto yy1527; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy153; - case 'r': goto yy1536; - default: goto yy4; + if (yych <= 'Q') { + if (yych <= '-') { + if (yych == ')') goto yy140; + if (yych <= ',') goto yy4; + goto yy148; + } else { + if (yych == '/') goto yy148; + if (yych <= '@') goto yy4; + goto yy145; + } + } else { + if (yych <= '_') { + if (yych <= 'R') goto yy1527; + if (yych <= 'Z') goto yy145; + if (yych <= '^') goto yy4; + goto yy148; + } else { + if (yych <= 'q') { + if (yych <= '`') goto yy4; + goto yy153; + } else { + if (yych <= 'r') goto yy1536; + if (yych <= 'z') goto yy153; + goto yy4; + } + } } yy1536: + YYDEBUG(1536, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case ')': goto yy140; - case '-': - case '/': - case '_': goto yy148; - case 'D': goto yy1528; - case 'a': - case 'b': - case 'c': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - case 'd': goto yy1537; - default: goto yy4; + if (yych <= 'C') { + if (yych <= ',') { + if (yych == ')') goto yy140; + goto yy4; + } else { + if (yych == '.') goto yy4; + if (yych <= '/') goto yy148; + goto yy4; + } + } else { + if (yych <= '`') { + if (yych <= 'D') goto yy1528; + if (yych == '_') goto yy148; + goto yy4; + } else { + if (yych == 'd') goto yy1537; + if (yych <= 'z') goto yy154; + goto yy4; + } } yy1537: + YYDEBUG(1537, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'A': goto yy1529; - case 'a': goto yy1538; - default: goto yy155; - } -yy1538: + if (yych == 'A') goto yy1529; + if (yych != 'a') goto yy155; + YYDEBUG(1538, *YYCURSOR); yych = *++YYCURSOR; - switch (yych) { - case 'Y': goto yy1530; - case 'y': goto yy1539; - default: goto yy155; - } -yy1539: + if (yych == 'Y') goto yy1530; + if (yych != 'y') goto yy155; + YYDEBUG(1539, *YYCURSOR); yyaccept = 33; yych = *(YYMARKER = ++YYCURSOR); - switch (yych) { - case '-': - case '/': - case '_': goto yy148; - case 'a': - case 'b': - case 'c': - case 'd': - case 'e': - case 'f': - case 'g': - case 'h': - case 'i': - case 'j': - case 'k': - case 'l': - case 'm': - case 'n': - case 'o': - case 'p': - case 'q': - case 'r': - case 's': - case 't': - case 'u': - case 'v': - case 'w': - case 'x': - case 'y': - case 'z': goto yy154; - default: goto yy1531; + if (yybm[0+yych] & 16) { + goto yy154; + } + if (yych <= '.') { + if (yych == '-') goto yy148; + goto yy1531; + } else { + if (yych <= '/') goto yy148; + if (yych == '_') goto yy148; + goto yy1531; } } #line 1755 "ext/date/lib/parse_date.re" From 9f8501b3b7ee90274cf2ecd2e262e6314542ff5f Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Thu, 23 Jun 2011 21:27:42 +0000 Subject: [PATCH 0218/2394] These are annoyingly slow --- ext/date/tests/date_diff.phpt | 4 ++++ ext/standard/tests/file/001.phpt | 1 + ext/standard/tests/file/005_variation.phpt | 3 +++ ext/standard/tests/file/fread_socket_variation1.phpt | 4 ++++ ext/standard/tests/general_functions/proc_open02.phpt | 1 + ext/standard/tests/misc/time_nanosleep_basic.phpt | 4 +++- ext/standard/tests/strings/htmlentities_html4.phpt | 4 ++++ tests/func/005a.phpt | 4 ++++ tests/func/010.phpt | 4 ++++ 9 files changed, 28 insertions(+), 1 deletion(-) diff --git a/ext/date/tests/date_diff.phpt b/ext/date/tests/date_diff.phpt index 31783a884dea7..e01a94e767910 100644 --- a/ext/date/tests/date_diff.phpt +++ b/ext/date/tests/date_diff.phpt @@ -1,5 +1,9 @@ --TEST-- Extensive test for date_diff(). +--SKIPIF-- + --INI-- date.timezone=UTC --FILE-- diff --git a/ext/standard/tests/file/001.phpt b/ext/standard/tests/file/001.phpt index e3768b19dd79c..d604699ac4f09 100644 --- a/ext/standard/tests/file/001.phpt +++ b/ext/standard/tests/file/001.phpt @@ -5,6 +5,7 @@ File type functions if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip no symlinks on Windows'); } +if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> --FILE-- --FILE-- --FILE-- --FILE-- + --CREDITS-- Àlex Corretgé - alex@corretge.cat --FILE-- diff --git a/ext/standard/tests/strings/htmlentities_html4.phpt b/ext/standard/tests/strings/htmlentities_html4.phpt index 3f700e828a440..d7bff707fdb45 100644 --- a/ext/standard/tests/strings/htmlentities_html4.phpt +++ b/ext/standard/tests/strings/htmlentities_html4.phpt @@ -1,5 +1,9 @@ --TEST-- htmlentities() conformance check (HTML 4) +--SKIPIF-- + --FILE-- --FILE-- --FILE-- Date: Thu, 23 Jun 2011 21:53:25 +0000 Subject: [PATCH 0219/2394] - Missing valid path check --- ext/standard/basic_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index f9db33dee878f..68671c1a9c639 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -4640,7 +4640,7 @@ PHP_FUNCTION(error_log) int opt_err = 0, argc = ZEND_NUM_ARGS(); long erropt = 0; - if (zend_parse_parameters(argc TSRMLS_CC, "s|lss", &message, &message_len, &erropt, &opt, &opt_len, &headers, &headers_len) == FAILURE) { + if (zend_parse_parameters(argc TSRMLS_CC, "s|lps", &message, &message_len, &erropt, &opt, &opt_len, &headers, &headers_len) == FAILURE) { return; } From 72f7be3df024b80544a647718aad73ed71c66d78 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 23 Jun 2011 23:00:53 +0000 Subject: [PATCH 0220/2394] - Improved parse error messages --- Zend/tests/bug48693.phpt | 2 +- Zend/tests/function_arguments_001.phpt | 2 +- Zend/zend_globals.h | 1 + Zend/zend_language_parser.y | 268 +++++++--- Zend/zend_language_scanner.c | 672 +++++++++++++------------ Zend/zend_language_scanner.l | 2 + Zend/zend_language_scanner_defs.h | 2 +- main/main.c | 6 +- 8 files changed, 541 insertions(+), 414 deletions(-) diff --git a/Zend/tests/bug48693.phpt b/Zend/tests/bug48693.phpt index e5743460290fb..7eabe00542e0c 100644 --- a/Zend/tests/bug48693.phpt +++ b/Zend/tests/bug48693.phpt @@ -20,7 +20,7 @@ var_dump( --EXPECTF-- Parse error: syntax error, unexpected '}' in %s(%d) : runtime-created function on line 1 -Parse error: syntax error, unexpected $end in %s(%d) : runtime-created function on line 1 +Parse error: syntax error, unexpected end of file in %s(%d) : runtime-created function on line 1 bool(false) int(2) bool(false) diff --git a/Zend/tests/function_arguments_001.phpt b/Zend/tests/function_arguments_001.phpt index bf0cd4a206d28..747bd25766003 100644 --- a/Zend/tests/function_arguments_001.phpt +++ b/Zend/tests/function_arguments_001.phpt @@ -5,5 +5,5 @@ Argument parsing error #001 function foo($arg1 string) {} ?> --EXPECTF-- -Parse error: syntax error, unexpected T_STRING, expecting ')' in %sfunction_arguments_001.php on line %d +Parse error: syntax error, unexpected 'string' (T_STRING), expecting ')' in %sfunction_arguments_001.php on line %d diff --git a/Zend/zend_globals.h b/Zend/zend_globals.h index b88fe83604e88..7a89a0e960ef3 100644 --- a/Zend/zend_globals.h +++ b/Zend/zend_globals.h @@ -101,6 +101,7 @@ struct _zend_compiler_globals { HashTable *auto_globals; + zend_bool parse_error; zend_bool in_compilation; zend_bool short_tags; zend_bool asp_tags; diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index e3d079c551940..e6f49a1595f91 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -35,6 +35,9 @@ #include "zend_API.h" #include "zend_constants.h" +#define YYSIZE_T size_t +#define yytnamerr zend_yytnamerr +static YYSIZE_T zend_yytnamerr(char*, const char*); #define YYERROR_VERBOSE #define YYSTYPE znode @@ -49,107 +52,160 @@ %pure_parser %expect 2 +%token END 0 "end of file" %left T_INCLUDE T_INCLUDE_ONCE T_EVAL T_REQUIRE T_REQUIRE_ONCE +%token T_INCLUDE "include (T_INCLUDE)" +%token T_INCLUDE_ONCE "include_once (T_INCLUDE_ONCE)" +%token T_EVAL "eval (T_EVAL)" +%token T_REQUIRE "require (T_REQUIRE)" +%token T_REQUIRE_ONCE "require_once (T_REQUIRE_ONCE)" %left ',' %left T_LOGICAL_OR +%token T_LOGICAL_OR "or (T_LOGICAL_OR)" %left T_LOGICAL_XOR +%token T_LOGICAL_XOR "xor (T_LOGICAL_XOR)" %left T_LOGICAL_AND +%token T_LOGICAL_AND "and (T_LOGICAL_AND)" %right T_PRINT +%token T_PRINT "print (T_PRINT)" %left '=' T_PLUS_EQUAL T_MINUS_EQUAL T_MUL_EQUAL T_DIV_EQUAL T_CONCAT_EQUAL T_MOD_EQUAL T_AND_EQUAL T_OR_EQUAL T_XOR_EQUAL T_SL_EQUAL T_SR_EQUAL +%token T_PLUS_EQUAL "+= (T_PLUS_EQUAL)" +%token T_MINUS_EQUAL "-= (T_MINUS_EQUAL)" +%token T_MUL_EQUAL "*= (T_MUL_EQUAL)" +%token T_DIV_EQUAL "/= (T_DIV_EQUAL)" +%token T_CONCAT_EQUAL ".= (T_CONCAT_EQUAL)" +%token T_MOD_EQUAL "%= (T_MOD_EQUAL)" +%token T_AND_EQUAL "&= (T_AND_EQUAL)" +%token T_OR_EQUAL "|= (T_OR_EQUAL)" +%token T_XOR_EQUAL "^= (T_XOR_EQUAL)" +%token T_SL_EQUAL "<<= (T_SL_EQUAL)" +%token T_SR_EQUAL ">>= (T_SR_EQUAL)" %left '?' ':' %left T_BOOLEAN_OR -%left T_BOOLEAN_AND +%token T_BOOLEAN_OR "|| (T_BOOLEAN_OR)" +%left T_BOOLEAN_AND +%token T_BOOLEAN_AND "&& (T_BOOLEAN_AND)" %left '|' %left '^' %left '&' %nonassoc T_IS_EQUAL T_IS_NOT_EQUAL T_IS_IDENTICAL T_IS_NOT_IDENTICAL +%token T_IS_EQUAL "== (T_IS_EQUAL)" +%token T_IS_NOT_EQUAL "!= (T_IS_NOT_EQUAL)" +%token T_IS_IDENTICAL "=== (T_IS_IDENTICAL)" +%token T_IS_NOT_IDENTICAL "!== (T_IS_NOT_IDENTICAL)" %nonassoc '<' T_IS_SMALLER_OR_EQUAL '>' T_IS_GREATER_OR_EQUAL +%token T_IS_SMALLER_OR_EQUAL "<= (T_IS_SMALLER_OR_EQUAL)" +%token T_IS_GREATER_OR_EQUAL ">= (T_IS_GREATER_OR_EQUAL)" %left T_SL T_SR +%token T_SL "<< (T_SL)" +%token T_SR ">> (T_SR)" %left '+' '-' '.' %left '*' '/' '%' %right '!' %nonassoc T_INSTANCEOF +%token T_INSTANCEOF "instanceof (T_INSTANCEOF)" %right '~' T_INC T_DEC T_INT_CAST T_DOUBLE_CAST T_STRING_CAST T_ARRAY_CAST T_OBJECT_CAST T_BOOL_CAST T_UNSET_CAST '@' +%token T_INC "++ (T_INC)" +%token T_DEC "-- (T_DEC)" +%token T_INT_CAST "(int) (T_INT_CAST)" +%token T_SCALAR_CAST "(scalar) (T_SCALAR_CAST)" +%token T_DOUBLE_CAST "(double) (T_DOUBLE_CAST)" +%token T_STRING_CAST "(string) (T_STRING_CAST)" +%token T_ARRAY_CAST "(array) (T_ARRAY_CAST)" +%token T_OBJECT_CAST "(object) (T_OBJECT_CAST)" +%token T_BOOL_CAST "(bool) (T_BOOL_CAST)" +%token T_UNSET_CAST "(unset) (T_UNSET_CAST)" %right '[' %nonassoc T_NEW T_CLONE -%token T_EXIT -%token T_IF +%token T_NEW "new (T_NEW)" +%token T_CLONE "clone (T_CLONE)" +%token T_EXIT "exit (T_EXIT)" +%token T_IF "if (T_IF)" %left T_ELSEIF -%left T_ELSE -%left T_ENDIF -%token T_LNUMBER -%token T_DNUMBER -%token T_STRING -%token T_STRING_VARNAME -%token T_VARIABLE -%token T_NUM_STRING +%token T_ELSEIF "elseif (T_ELSEIF)" +%left T_ELSE +%token T_ELSE "else (T_ELSE)" +%left T_ENDIF +%token T_ENDIF "endif (T_ENDIF)" +%token T_LNUMBER "integer number (T_LNUMBER)" +%token T_DNUMBER "floating-point number (T_DNUMBER)" +%token T_STRING "identifier (T_STRING)" +%token T_STRING_VARNAME "variable name (T_STRING_VARNAME)" +%token T_VARIABLE "variable (T_VARIABLE)" +%token T_NUM_STRING "number (T_NUM_STRING)" %token T_INLINE_HTML %token T_CHARACTER %token T_BAD_CHARACTER -%token T_ENCAPSED_AND_WHITESPACE -%token T_CONSTANT_ENCAPSED_STRING -%token T_ECHO -%token T_DO -%token T_WHILE -%token T_ENDWHILE -%token T_FOR -%token T_ENDFOR -%token T_FOREACH -%token T_ENDFOREACH -%token T_DECLARE -%token T_ENDDECLARE -%token T_AS -%token T_SWITCH -%token T_ENDSWITCH -%token T_CASE -%token T_DEFAULT -%token T_BREAK -%token T_CONTINUE -%token T_GOTO -%token T_FUNCTION -%token T_CONST -%token T_RETURN -%token T_TRY -%token T_CATCH -%token T_THROW -%token T_USE -%token T_INSTEADOF -%token T_GLOBAL +%token T_ENCAPSED_AND_WHITESPACE "quoted-string and whitespace (T_ENCAPSED_AND_WHITESPACE)" +%token T_CONSTANT_ENCAPSED_STRING "quoted-string (T_CONSTANT_ENCAPSED_STRING)" +%token T_ECHO "echo (T_ECHO)" +%token T_DO "do (T_DO)" +%token T_WHILE "while (T_WHILE)" +%token T_ENDWHILE "endwhile (T_ENDWHILE)" +%token T_FOR "for (T_FOR)" +%token T_ENDFOR "endfor (T_ENDFOR)" +%token T_FOREACH "foreach (T_FOREACH)" +%token T_ENDFOREACH "endforeach (T_ENDFOREACH)" +%token T_DECLARE "declare (T_DECLARE)" +%token T_ENDDECLARE "enddeclare (T_ENDDECLARE)" +%token T_AS "as (T_AS)" +%token T_SWITCH "switch (T_SWITCH)" +%token T_ENDSWITCH "endswitch (T_ENDSWITCH)" +%token T_CASE "case (T_CASE)" +%token T_DEFAULT "default (T_DEFAULT)" +%token T_BREAK "break (T_BREAK)" +%token T_CONTINUE "continue (T_CONTINUE)" +%token T_GOTO "goto (T_GOTO)" +%token T_FUNCTION "function (T_FUNCTION)" +%token T_CONST "const (T_CONST)" +%token T_RETURN "return (T_RETURN)" +%token T_TRY "try (T_TRY)" +%token T_CATCH "catch (T_CATCH)" +%token T_THROW "throw (T_THROW)" +%token T_USE "use (T_USE)" +%token T_INSTEADOF "insteadof (T_INSTEADOF)" +%token T_GLOBAL "global (T_GLOBAL)" %right T_STATIC T_ABSTRACT T_FINAL T_PRIVATE T_PROTECTED T_PUBLIC -%token T_VAR -%token T_UNSET -%token T_ISSET -%token T_EMPTY -%token T_HALT_COMPILER -%token T_CLASS -%token T_TRAIT -%token T_INTERFACE -%token T_EXTENDS -%token T_IMPLEMENTS -%token T_OBJECT_OPERATOR -%token T_DOUBLE_ARROW -%token T_LIST -%token T_ARRAY -%token T_CLASS_C -%token T_METHOD_C -%token T_FUNC_C -%token T_LINE -%token T_FILE -%token T_COMMENT -%token T_DOC_COMMENT -%token T_OPEN_TAG -%token T_OPEN_TAG_WITH_ECHO -%token T_CLOSE_TAG -%token T_WHITESPACE -%token T_START_HEREDOC -%token T_END_HEREDOC -%token T_DOLLAR_OPEN_CURLY_BRACES -%token T_CURLY_OPEN -%token T_PAAMAYIM_NEKUDOTAYIM -%token T_NAMESPACE -%token T_NS_C -%token T_DIR -%token T_NS_SEPARATOR +%token T_STATIC "static (T_STATIC)" +%token T_ABSTRACT "abstract (T_ABSTRACT)" +%token T_FINAL "final (T_FINAL)" +%token T_PRIVATE "private (T_PRIVATE)" +%token T_PROTECTED "protected (T_PROTECTED)" +%token T_PUBLIC "public (T_PUBLIC)" +%token T_VAR "var (T_VAR)" +%token T_UNSET "unset (T_UNSET)" +%token T_ISSET "isset (T_ISSET)" +%token T_EMPTY "empty (T_EMPTY)" +%token T_HALT_COMPILER "__halt_compiler (T_HALT_COMPILER)" +%token T_CLASS "class (T_CLASS)" +%token T_TRAIT "trait (T_TRAIT)" +%token T_INTERFACE "interface (T_INTERFACE)" +%token T_EXTENDS "extends (T_EXTENDS)" +%token T_IMPLEMENTS "implements (T_IMPLEMENTS)" +%token T_OBJECT_OPERATOR "-> (T_OBJECT_OPERATOR)" +%token T_DOUBLE_ARROW "=> (T_DOUBLE_ARROW)" +%token T_LIST "list (T_LIST)" +%token T_ARRAY "array (T_ARRAY)" +%token T_CLASS_C "__CLASS__ (T_CLASS_C)" +%token T_METHOD_C "__METHOD__ (T_METHOD_C)" +%token T_FUNC_C "__FUNCTION__ (T_FUNC_C)" +%token T_LINE "__LINE__ (T_LINE)" +%token T_FILE "__FILE__ (T_FILE)" +%token T_COMMENT "comment (T_COMMENT)" +%token T_DOC_COMMENT "doc comment (T_DOC_COMMENT)" +%token T_OPEN_TAG "open tag (T_OPEN_TAG)" +%token T_OPEN_TAG_WITH_ECHO "open tag with echo (T_OPEN_TAG_WITH_ECHO)" +%token T_CLOSE_TAG "close tag (T_CLOSE_TAG)" +%token T_WHITESPACE "whitespace (T_WHITESPACE)" +%token T_START_HEREDOC "heredoc start (T_START_HEREDOC)" +%token T_END_HEREDOC "heredoc end (T_END_HEREDOC)" +%token T_DOLLAR_OPEN_CURLY_BRACES "${ (T_DOLLAR_OPEN_CURLY_BRACES)" +%token T_CURLY_OPEN "{$ (T_CURLY_OPEN)" +%token T_PAAMAYIM_NEKUDOTAYIM ":: (T_PAAMAYIM_NEKUDOTAYIM)" +%token T_NAMESPACE "namespace (T_NAMESPACE)" +%token T_NS_C "__NAMESPACE__ (T_NS_C)" +%token T_DIR "__DIR__ (T_DIR)" +%token T_NS_SEPARATOR "\\ (T_NS_SEPARATOR)" %% /* Rules */ @@ -1079,6 +1135,70 @@ class_constant: %% +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T zend_yytnamerr(char *yyres, const char *yystr) +{ + if (!yyres) { + return yystrlen(yystr); + } + { + TSRMLS_FETCH(); + if (CG(parse_error) == 0) { + char buffer[120], *end, *str, *tok1 = NULL, *tok2 = NULL; + unsigned int len = 0, toklen = 0, yystr_len; + + CG(parse_error) = 1; + + if (LANG_SCNG(yy_text)[0] == 0 && + LANG_SCNG(yy_leng) == 1 && + memcmp(yystr, ZEND_STRL("\"end of file\"")) == 0) { + return yystpcpy(yyres, "end of file") - yyres; + } + + str = LANG_SCNG(yy_text); + end = memchr(str, '\n', LANG_SCNG(yy_leng)); + yystr_len = yystrlen(yystr); + + if ((tok1 = memchr(yystr, '(', yystr_len)) != NULL + && (tok2 = zend_memrchr(yystr, ')', yystr_len)) != NULL) { + toklen = (tok2 - tok1) + 1; + } else { + tok1 = tok2 = NULL; + toklen = 0; + } + + if (end == NULL) { + len = LANG_SCNG(yy_leng) > 30 ? 30 : LANG_SCNG(yy_leng); + } else { + len = (end - str) > 30 ? 30 : (end - str); + } + if (toklen) { + snprintf(buffer, sizeof(buffer), "'%.*s' %.*s", len, str, toklen, tok1); + } else { + snprintf(buffer, sizeof(buffer), "'%.*s'", len, str); + } + return yystpcpy(yyres, buffer) - yyres; + } + } + if (*yystr == '"') { + YYSIZE_T yyn = 0; + const char *yyp = yystr; + + for (; *++yyp != '"'; ++yyn) { + yyres[yyn] = *yyp; + } + yyres[yyn] = '\0'; + return yyn; + } + return yystpcpy(yyres, yystr) - yyres; +} + /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 96d775e1d3071..9097b5b8bb7ac 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jun 5 21:39:30 2011 */ +/* Generated by re2c 0.13.5 on Thu Jun 23 17:57:45 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -176,6 +176,7 @@ static void yy_scan_buffer(char *str, unsigned int len TSRMLS_DC) void startup_scanner(TSRMLS_D) { + CG(parse_error) = 0; CG(heredoc) = NULL; CG(heredoc_len) = 0; CG(doc_comment) = NULL; @@ -189,6 +190,7 @@ void shutdown_scanner(TSRMLS_D) efree(CG(heredoc)); CG(heredoc_len)=0; } + CG(parse_error) = 0; zend_stack_destroy(&SCNG(state_stack)); RESET_DOC_COMMENT(); } @@ -982,7 +984,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yymore_restart: -#line 986 "Zend/zend_language_scanner.c" +#line 988 "Zend/zend_language_scanner.c" { YYCTYPE yych; unsigned int yyaccept = 0; @@ -1081,7 +1083,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1710 "Zend/zend_language_scanner.l" +#line 1712 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1141,7 +1143,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_INLINE_HTML; } -#line 1145 "Zend/zend_language_scanner.c" +#line 1147 "Zend/zend_language_scanner.c" yy4: YYDEBUG(4, *YYCURSOR); yych = *++YYCURSOR; @@ -1159,7 +1161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1698 "Zend/zend_language_scanner.l" +#line 1700 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1171,14 +1173,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) goto inline_char_handler; } } -#line 1175 "Zend/zend_language_scanner.c" +#line 1177 "Zend/zend_language_scanner.c" yy7: YYDEBUG(7, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1675 "Zend/zend_language_scanner.l" +#line 1677 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1190,7 +1192,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) goto inline_char_handler; } } -#line 1194 "Zend/zend_language_scanner.c" +#line 1196 "Zend/zend_language_scanner.c" yy9: YYDEBUG(9, *YYCURSOR); yych = *++YYCURSOR; @@ -1376,7 +1378,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1635 "Zend/zend_language_scanner.l" +#line 1637 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1393,7 +1395,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_IN_SCRIPTING); return T_OPEN_TAG; } -#line 1397 "Zend/zend_language_scanner.c" +#line 1399 "Zend/zend_language_scanner.c" yy39: YYDEBUG(39, *YYCURSOR); yych = *++YYCURSOR; @@ -1420,7 +1422,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1653 "Zend/zend_language_scanner.l" +#line 1655 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1432,13 +1434,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) goto inline_char_handler; } } -#line 1436 "Zend/zend_language_scanner.c" +#line 1438 "Zend/zend_language_scanner.c" yy45: YYDEBUG(45, *YYCURSOR); ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1666 "Zend/zend_language_scanner.l" +#line 1668 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1446,7 +1448,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_IN_SCRIPTING); return T_OPEN_TAG_WITH_ECHO; } -#line 1450 "Zend/zend_language_scanner.c" +#line 1452 "Zend/zend_language_scanner.c" yy47: YYDEBUG(47, *YYCURSOR); yych = *++YYCURSOR; @@ -1473,7 +1475,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1688 "Zend/zend_language_scanner.l" +#line 1690 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1482,7 +1484,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_IN_SCRIPTING); return T_OPEN_TAG; } -#line 1486 "Zend/zend_language_scanner.c" +#line 1488 "Zend/zend_language_scanner.c" yy52: YYDEBUG(52, *YYCURSOR); ++YYCURSOR; @@ -1553,7 +1555,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2161 "Zend/zend_language_scanner.l" +#line 2163 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1594,7 +1596,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_scan_escape_string(zendlval, yytext, yyleng, '`' TSRMLS_CC); return T_ENCAPSED_AND_WHITESPACE; } -#line 1598 "Zend/zend_language_scanner.c" +#line 1600 "Zend/zend_language_scanner.c" yy57: YYDEBUG(57, *YYCURSOR); yych = *++YYCURSOR; @@ -1605,12 +1607,12 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2105 "Zend/zend_language_scanner.l" +#line 2107 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; } -#line 1614 "Zend/zend_language_scanner.c" +#line 1616 "Zend/zend_language_scanner.c" yy60: YYDEBUG(60, *YYCURSOR); yych = *++YYCURSOR; @@ -1620,14 +1622,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2092 "Zend/zend_language_scanner.l" +#line 2094 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); yyless(1); return T_CURLY_OPEN; } -#line 1631 "Zend/zend_language_scanner.c" +#line 1633 "Zend/zend_language_scanner.c" yy63: YYDEBUG(63, *YYCURSOR); yyaccept = 0; @@ -1643,24 +1645,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1794 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1653 "Zend/zend_language_scanner.c" +#line 1655 "Zend/zend_language_scanner.c" yy66: YYDEBUG(66, *YYCURSOR); ++YYCURSOR; YYDEBUG(67, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1428 "Zend/zend_language_scanner.l" +#line 1430 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; } -#line 1664 "Zend/zend_language_scanner.c" +#line 1666 "Zend/zend_language_scanner.c" yy68: YYDEBUG(68, *YYCURSOR); yych = *++YYCURSOR; @@ -1674,7 +1676,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1784 "Zend/zend_language_scanner.l" +#line 1786 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1682,7 +1684,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1686 "Zend/zend_language_scanner.c" +#line 1688 "Zend/zend_language_scanner.c" yy72: YYDEBUG(72, *YYCURSOR); yych = *++YYCURSOR; @@ -1700,7 +1702,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1774 "Zend/zend_language_scanner.l" +#line 1776 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1708,7 +1710,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1712 "Zend/zend_language_scanner.c" +#line 1714 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_DOUBLE_QUOTES: @@ -1776,7 +1778,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2111 "Zend/zend_language_scanner.l" +#line 2113 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1825,7 +1827,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_scan_escape_string(zendlval, yytext, yyleng, '"' TSRMLS_CC); return T_ENCAPSED_AND_WHITESPACE; } -#line 1829 "Zend/zend_language_scanner.c" +#line 1831 "Zend/zend_language_scanner.c" yy79: YYDEBUG(79, *YYCURSOR); yych = *++YYCURSOR; @@ -1836,12 +1838,12 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2100 "Zend/zend_language_scanner.l" +#line 2102 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; } -#line 1845 "Zend/zend_language_scanner.c" +#line 1847 "Zend/zend_language_scanner.c" yy82: YYDEBUG(82, *YYCURSOR); yych = *++YYCURSOR; @@ -1851,14 +1853,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2092 "Zend/zend_language_scanner.l" +#line 2094 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); yyless(1); return T_CURLY_OPEN; } -#line 1862 "Zend/zend_language_scanner.c" +#line 1864 "Zend/zend_language_scanner.c" yy85: YYDEBUG(85, *YYCURSOR); yyaccept = 0; @@ -1874,24 +1876,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1794 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1884 "Zend/zend_language_scanner.c" +#line 1886 "Zend/zend_language_scanner.c" yy88: YYDEBUG(88, *YYCURSOR); ++YYCURSOR; YYDEBUG(89, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1428 "Zend/zend_language_scanner.l" +#line 1430 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; } -#line 1895 "Zend/zend_language_scanner.c" +#line 1897 "Zend/zend_language_scanner.c" yy90: YYDEBUG(90, *YYCURSOR); yych = *++YYCURSOR; @@ -1905,7 +1907,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1784 "Zend/zend_language_scanner.l" +#line 1786 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1913,7 +1915,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1917 "Zend/zend_language_scanner.c" +#line 1919 "Zend/zend_language_scanner.c" yy94: YYDEBUG(94, *YYCURSOR); yych = *++YYCURSOR; @@ -1931,7 +1933,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1774 "Zend/zend_language_scanner.l" +#line 1776 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1939,7 +1941,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 1943 "Zend/zend_language_scanner.c" +#line 1945 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_END_HEREDOC: @@ -1950,7 +1952,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2079 "Zend/zend_language_scanner.l" +#line 2081 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -1962,7 +1964,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_IN_SCRIPTING); return T_END_HEREDOC; } -#line 1966 "Zend/zend_language_scanner.c" +#line 1968 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_HEREDOC: { @@ -2024,7 +2026,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2203 "Zend/zend_language_scanner.l" +#line 2205 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2095,7 +2097,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_scan_escape_string(zendlval, yytext, yyleng - newline, 0 TSRMLS_CC); return T_ENCAPSED_AND_WHITESPACE; } -#line 2099 "Zend/zend_language_scanner.c" +#line 2101 "Zend/zend_language_scanner.c" yy105: YYDEBUG(105, *YYCURSOR); yych = *++YYCURSOR; @@ -2110,14 +2112,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2092 "Zend/zend_language_scanner.l" +#line 2094 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); yyless(1); return T_CURLY_OPEN; } -#line 2121 "Zend/zend_language_scanner.c" +#line 2123 "Zend/zend_language_scanner.c" yy109: YYDEBUG(109, *YYCURSOR); yyaccept = 0; @@ -2133,24 +2135,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1794 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 2143 "Zend/zend_language_scanner.c" +#line 2145 "Zend/zend_language_scanner.c" yy112: YYDEBUG(112, *YYCURSOR); ++YYCURSOR; YYDEBUG(113, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1428 "Zend/zend_language_scanner.l" +#line 1430 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; } -#line 2154 "Zend/zend_language_scanner.c" +#line 2156 "Zend/zend_language_scanner.c" yy114: YYDEBUG(114, *YYCURSOR); yych = *++YYCURSOR; @@ -2164,7 +2166,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1784 "Zend/zend_language_scanner.l" +#line 1786 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2172,7 +2174,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 2176 "Zend/zend_language_scanner.c" +#line 2178 "Zend/zend_language_scanner.c" yy118: YYDEBUG(118, *YYCURSOR); yych = *++YYCURSOR; @@ -2190,7 +2192,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1774 "Zend/zend_language_scanner.l" +#line 1776 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2198,7 +2200,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_VARIABLE; } -#line 2202 "Zend/zend_language_scanner.c" +#line 2204 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_IN_SCRIPTING: @@ -2379,13 +2381,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1817 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 2389 "Zend/zend_language_scanner.c" +#line 2391 "Zend/zend_language_scanner.c" yy125: YYDEBUG(125, *YYCURSOR); yych = *++YYCURSOR; @@ -2611,11 +2613,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy138: YYDEBUG(138, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1417 "Zend/zend_language_scanner.l" +#line 1419 "Zend/zend_language_scanner.l" { return yytext[0]; } -#line 2619 "Zend/zend_language_scanner.c" +#line 2621 "Zend/zend_language_scanner.c" yy139: YYDEBUG(139, *YYCURSOR); ++YYCURSOR; @@ -2624,7 +2626,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy140: YYDEBUG(140, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1152 "Zend/zend_language_scanner.l" +#line 1154 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -2632,7 +2634,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 2636 "Zend/zend_language_scanner.c" +#line 2638 "Zend/zend_language_scanner.c" yy141: YYDEBUG(141, *YYCURSOR); yych = *++YYCURSOR; @@ -2643,11 +2645,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(143, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1181 "Zend/zend_language_scanner.l" +#line 1183 "Zend/zend_language_scanner.l" { return T_NS_SEPARATOR; } -#line 2651 "Zend/zend_language_scanner.c" +#line 2653 "Zend/zend_language_scanner.c" yy144: YYDEBUG(144, *YYCURSOR); yych = *++YYCURSOR; @@ -2875,18 +2877,18 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(168, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1422 "Zend/zend_language_scanner.l" +#line 1424 "Zend/zend_language_scanner.l" { yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return '{'; } -#line 2884 "Zend/zend_language_scanner.c" +#line 2886 "Zend/zend_language_scanner.c" yy169: YYDEBUG(169, *YYCURSOR); ++YYCURSOR; YYDEBUG(170, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1434 "Zend/zend_language_scanner.l" +#line 1436 "Zend/zend_language_scanner.l" { RESET_DOC_COMMENT(); if (!zend_stack_is_empty(&SCNG(state_stack))) { @@ -2894,7 +2896,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return '}'; } -#line 2898 "Zend/zend_language_scanner.c" +#line 2900 "Zend/zend_language_scanner.c" yy171: YYDEBUG(171, *YYCURSOR); yyaccept = 2; @@ -2917,7 +2919,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy172: YYDEBUG(172, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1460 "Zend/zend_language_scanner.l" +#line 1462 "Zend/zend_language_scanner.l" { if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */ zendlval->value.lval = strtol(yytext, NULL, 0); @@ -2938,7 +2940,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_LONG; return T_LNUMBER; } -#line 2942 "Zend/zend_language_scanner.c" +#line 2944 "Zend/zend_language_scanner.c" yy173: YYDEBUG(173, *YYCURSOR); yyaccept = 2; @@ -2966,7 +2968,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1822 "Zend/zend_language_scanner.l" +#line 1824 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3000,14 +3002,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_COMMENT; } -#line 3004 "Zend/zend_language_scanner.c" +#line 3006 "Zend/zend_language_scanner.c" yy177: YYDEBUG(177, *YYCURSOR); ++YYCURSOR; yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1913 "Zend/zend_language_scanner.l" +#line 1915 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3075,14 +3077,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_CONSTANT_ENCAPSED_STRING; } -#line 3079 "Zend/zend_language_scanner.c" +#line 3081 "Zend/zend_language_scanner.c" yy179: YYDEBUG(179, *YYCURSOR); ++YYCURSOR; yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1982 "Zend/zend_language_scanner.l" +#line 1984 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3123,24 +3125,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_DOUBLE_QUOTES); return '"'; } -#line 3127 "Zend/zend_language_scanner.c" +#line 3129 "Zend/zend_language_scanner.c" yy181: YYDEBUG(181, *YYCURSOR); ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2073 "Zend/zend_language_scanner.l" +#line 2075 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; } -#line 3138 "Zend/zend_language_scanner.c" +#line 3140 "Zend/zend_language_scanner.c" yy183: YYDEBUG(183, *YYCURSOR); ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2331 "Zend/zend_language_scanner.l" +#line 2333 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3149,7 +3151,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 3153 "Zend/zend_language_scanner.c" +#line 3155 "Zend/zend_language_scanner.c" yy185: YYDEBUG(185, *YYCURSOR); ++YYCURSOR; @@ -3176,13 +3178,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy189: YYDEBUG(189, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1521 "Zend/zend_language_scanner.l" +#line 1523 "Zend/zend_language_scanner.l" { zendlval->value.dval = zend_strtod(yytext, NULL); zendlval->type = IS_DOUBLE; return T_DNUMBER; } -#line 3186 "Zend/zend_language_scanner.c" +#line 3188 "Zend/zend_language_scanner.c" yy190: YYDEBUG(190, *YYCURSOR); yyaccept = 2; @@ -3267,7 +3269,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(200, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1481 "Zend/zend_language_scanner.l" +#line 1483 "Zend/zend_language_scanner.l" { char *hex = yytext + 2; /* Skip "0x" */ int len = yyleng - 2; @@ -3288,7 +3290,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_DNUMBER; } } -#line 3292 "Zend/zend_language_scanner.c" +#line 3294 "Zend/zend_language_scanner.c" yy201: YYDEBUG(201, *YYCURSOR); ++YYCURSOR; @@ -3297,7 +3299,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy202: YYDEBUG(202, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1890 "Zend/zend_language_scanner.l" +#line 1892 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3305,7 +3307,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(INITIAL); return T_CLOSE_TAG; /* implicit ';' at php-end tag */ } -#line 3309 "Zend/zend_language_scanner.c" +#line 3311 "Zend/zend_language_scanner.c" yy203: YYDEBUG(203, *YYCURSOR); yych = *++YYCURSOR; @@ -3339,13 +3341,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy207: YYDEBUG(207, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1794 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 3349 "Zend/zend_language_scanner.c" +#line 3351 "Zend/zend_language_scanner.c" yy208: YYDEBUG(208, *YYCURSOR); yych = *++YYCURSOR; @@ -3359,11 +3361,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(210, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1405 "Zend/zend_language_scanner.l" +#line 1407 "Zend/zend_language_scanner.l" { return T_LOGICAL_XOR; } -#line 3367 "Zend/zend_language_scanner.c" +#line 3369 "Zend/zend_language_scanner.c" yy211: YYDEBUG(211, *YYCURSOR); ++YYCURSOR; @@ -3372,61 +3374,61 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(212, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1397 "Zend/zend_language_scanner.l" +#line 1399 "Zend/zend_language_scanner.l" { return T_LOGICAL_OR; } -#line 3380 "Zend/zend_language_scanner.c" +#line 3382 "Zend/zend_language_scanner.c" yy213: YYDEBUG(213, *YYCURSOR); ++YYCURSOR; YYDEBUG(214, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1385 "Zend/zend_language_scanner.l" +#line 1387 "Zend/zend_language_scanner.l" { return T_XOR_EQUAL; } -#line 3390 "Zend/zend_language_scanner.c" +#line 3392 "Zend/zend_language_scanner.c" yy215: YYDEBUG(215, *YYCURSOR); ++YYCURSOR; YYDEBUG(216, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1389 "Zend/zend_language_scanner.l" +#line 1391 "Zend/zend_language_scanner.l" { return T_BOOLEAN_OR; } -#line 3400 "Zend/zend_language_scanner.c" +#line 3402 "Zend/zend_language_scanner.c" yy217: YYDEBUG(217, *YYCURSOR); ++YYCURSOR; YYDEBUG(218, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1381 "Zend/zend_language_scanner.l" +#line 1383 "Zend/zend_language_scanner.l" { return T_OR_EQUAL; } -#line 3410 "Zend/zend_language_scanner.c" +#line 3412 "Zend/zend_language_scanner.c" yy219: YYDEBUG(219, *YYCURSOR); ++YYCURSOR; YYDEBUG(220, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1393 "Zend/zend_language_scanner.l" +#line 1395 "Zend/zend_language_scanner.l" { return T_BOOLEAN_AND; } -#line 3420 "Zend/zend_language_scanner.c" +#line 3422 "Zend/zend_language_scanner.c" yy221: YYDEBUG(221, *YYCURSOR); ++YYCURSOR; YYDEBUG(222, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1377 "Zend/zend_language_scanner.l" +#line 1379 "Zend/zend_language_scanner.l" { return T_AND_EQUAL; } -#line 3430 "Zend/zend_language_scanner.c" +#line 3432 "Zend/zend_language_scanner.c" yy223: YYDEBUG(223, *YYCURSOR); ++YYCURSOR; @@ -3435,7 +3437,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy224: YYDEBUG(224, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1899 "Zend/zend_language_scanner.l" +#line 1901 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3448,17 +3450,17 @@ int lex_scan(zval *zendlval TSRMLS_DC) return yytext[0]; } } -#line 3452 "Zend/zend_language_scanner.c" +#line 3454 "Zend/zend_language_scanner.c" yy225: YYDEBUG(225, *YYCURSOR); ++YYCURSOR; YYDEBUG(226, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1365 "Zend/zend_language_scanner.l" +#line 1367 "Zend/zend_language_scanner.l" { return T_MOD_EQUAL; } -#line 3462 "Zend/zend_language_scanner.c" +#line 3464 "Zend/zend_language_scanner.c" yy227: YYDEBUG(227, *YYCURSOR); yych = *++YYCURSOR; @@ -3489,11 +3491,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(232, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1361 "Zend/zend_language_scanner.l" +#line 1363 "Zend/zend_language_scanner.l" { return T_CONCAT_EQUAL; } -#line 3497 "Zend/zend_language_scanner.c" +#line 3499 "Zend/zend_language_scanner.c" yy233: YYDEBUG(233, *YYCURSOR); yyaccept = 4; @@ -3502,7 +3504,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy234: YYDEBUG(234, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1856 "Zend/zend_language_scanner.l" +#line 1858 "Zend/zend_language_scanner.l" { int doc_com; @@ -3536,7 +3538,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_COMMENT; } -#line 3540 "Zend/zend_language_scanner.c" +#line 3542 "Zend/zend_language_scanner.c" yy235: YYDEBUG(235, *YYCURSOR); yych = *++YYCURSOR; @@ -3546,11 +3548,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(237, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1357 "Zend/zend_language_scanner.l" +#line 1359 "Zend/zend_language_scanner.l" { return T_DIV_EQUAL; } -#line 3554 "Zend/zend_language_scanner.c" +#line 3556 "Zend/zend_language_scanner.c" yy238: YYDEBUG(238, *YYCURSOR); yych = *++YYCURSOR; @@ -3573,42 +3575,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(242, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1353 "Zend/zend_language_scanner.l" +#line 1355 "Zend/zend_language_scanner.l" { return T_MUL_EQUAL; } -#line 3581 "Zend/zend_language_scanner.c" +#line 3583 "Zend/zend_language_scanner.c" yy243: YYDEBUG(243, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) == '=') goto yy247; YYDEBUG(244, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1413 "Zend/zend_language_scanner.l" +#line 1415 "Zend/zend_language_scanner.l" { return T_SR; } -#line 3592 "Zend/zend_language_scanner.c" +#line 3594 "Zend/zend_language_scanner.c" yy245: YYDEBUG(245, *YYCURSOR); ++YYCURSOR; YYDEBUG(246, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1341 "Zend/zend_language_scanner.l" +#line 1343 "Zend/zend_language_scanner.l" { return T_IS_GREATER_OR_EQUAL; } -#line 3602 "Zend/zend_language_scanner.c" +#line 3604 "Zend/zend_language_scanner.c" yy247: YYDEBUG(247, *YYCURSOR); ++YYCURSOR; YYDEBUG(248, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1373 "Zend/zend_language_scanner.l" +#line 1375 "Zend/zend_language_scanner.l" { return T_SR_EQUAL; } -#line 3612 "Zend/zend_language_scanner.c" +#line 3614 "Zend/zend_language_scanner.c" yy249: YYDEBUG(249, *YYCURSOR); yyaccept = 5; @@ -3619,11 +3621,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy250: YYDEBUG(250, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1409 "Zend/zend_language_scanner.l" +#line 1411 "Zend/zend_language_scanner.l" { return T_SL; } -#line 3627 "Zend/zend_language_scanner.c" +#line 3629 "Zend/zend_language_scanner.c" yy251: YYDEBUG(251, *YYCURSOR); yych = *++YYCURSOR; @@ -3635,22 +3637,22 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(253, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1337 "Zend/zend_language_scanner.l" +#line 1339 "Zend/zend_language_scanner.l" { return T_IS_SMALLER_OR_EQUAL; } -#line 3643 "Zend/zend_language_scanner.c" +#line 3645 "Zend/zend_language_scanner.c" yy254: YYDEBUG(254, *YYCURSOR); ++YYCURSOR; yy255: YYDEBUG(255, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1333 "Zend/zend_language_scanner.l" +#line 1335 "Zend/zend_language_scanner.l" { return T_IS_NOT_EQUAL; } -#line 3654 "Zend/zend_language_scanner.c" +#line 3656 "Zend/zend_language_scanner.c" yy256: YYDEBUG(256, *YYCURSOR); yych = *++YYCURSOR; @@ -3701,11 +3703,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(264, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1369 "Zend/zend_language_scanner.l" +#line 1371 "Zend/zend_language_scanner.l" { return T_SL_EQUAL; } -#line 3709 "Zend/zend_language_scanner.c" +#line 3711 "Zend/zend_language_scanner.c" yy265: YYDEBUG(265, *YYCURSOR); ++YYCURSOR; @@ -3810,7 +3812,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy275: YYDEBUG(275, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2024 "Zend/zend_language_scanner.l" +#line 2026 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -3858,7 +3860,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_START_HEREDOC; } -#line 3862 "Zend/zend_language_scanner.c" +#line 3864 "Zend/zend_language_scanner.c" yy276: YYDEBUG(276, *YYCURSOR); yych = *++YYCURSOR; @@ -3898,31 +3900,31 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(281, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1325 "Zend/zend_language_scanner.l" +#line 1327 "Zend/zend_language_scanner.l" { return T_IS_NOT_IDENTICAL; } -#line 3906 "Zend/zend_language_scanner.c" +#line 3908 "Zend/zend_language_scanner.c" yy282: YYDEBUG(282, *YYCURSOR); ++YYCURSOR; YYDEBUG(283, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1345 "Zend/zend_language_scanner.l" +#line 1347 "Zend/zend_language_scanner.l" { return T_PLUS_EQUAL; } -#line 3916 "Zend/zend_language_scanner.c" +#line 3918 "Zend/zend_language_scanner.c" yy284: YYDEBUG(284, *YYCURSOR); ++YYCURSOR; YYDEBUG(285, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1313 "Zend/zend_language_scanner.l" +#line 1315 "Zend/zend_language_scanner.l" { return T_INC; } -#line 3926 "Zend/zend_language_scanner.c" +#line 3928 "Zend/zend_language_scanner.c" yy286: YYDEBUG(286, *YYCURSOR); yych = *++YYCURSOR; @@ -3941,42 +3943,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(289, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1305 "Zend/zend_language_scanner.l" +#line 1307 "Zend/zend_language_scanner.l" { return T_LIST; } -#line 3949 "Zend/zend_language_scanner.c" +#line 3951 "Zend/zend_language_scanner.c" yy290: YYDEBUG(290, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) == '=') goto yy294; YYDEBUG(291, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1329 "Zend/zend_language_scanner.l" +#line 1331 "Zend/zend_language_scanner.l" { return T_IS_EQUAL; } -#line 3960 "Zend/zend_language_scanner.c" +#line 3962 "Zend/zend_language_scanner.c" yy292: YYDEBUG(292, *YYCURSOR); ++YYCURSOR; YYDEBUG(293, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1301 "Zend/zend_language_scanner.l" +#line 1303 "Zend/zend_language_scanner.l" { return T_DOUBLE_ARROW; } -#line 3970 "Zend/zend_language_scanner.c" +#line 3972 "Zend/zend_language_scanner.c" yy294: YYDEBUG(294, *YYCURSOR); ++YYCURSOR; YYDEBUG(295, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1321 "Zend/zend_language_scanner.l" +#line 1323 "Zend/zend_language_scanner.l" { return T_IS_IDENTICAL; } -#line 3980 "Zend/zend_language_scanner.c" +#line 3982 "Zend/zend_language_scanner.c" yy296: YYDEBUG(296, *YYCURSOR); yych = *++YYCURSOR; @@ -4098,7 +4100,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(314, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1625 "Zend/zend_language_scanner.l" +#line 1627 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4108,7 +4110,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NS_C; } -#line 4112 "Zend/zend_language_scanner.c" +#line 4114 "Zend/zend_language_scanner.c" yy315: YYDEBUG(315, *YYCURSOR); yych = *++YYCURSOR; @@ -4128,7 +4130,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(319, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1598 "Zend/zend_language_scanner.l" +#line 1600 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4155,7 +4157,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_DIR; } -#line 4159 "Zend/zend_language_scanner.c" +#line 4161 "Zend/zend_language_scanner.c" yy320: YYDEBUG(320, *YYCURSOR); yych = *++YYCURSOR; @@ -4180,13 +4182,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(325, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1580 "Zend/zend_language_scanner.l" +#line 1582 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; return T_LINE; } -#line 4190 "Zend/zend_language_scanner.c" +#line 4192 "Zend/zend_language_scanner.c" yy326: YYDEBUG(326, *YYCURSOR); yych = *++YYCURSOR; @@ -4221,7 +4223,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(333, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1559 "Zend/zend_language_scanner.l" +#line 1561 "Zend/zend_language_scanner.l" { char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4242,7 +4244,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_METHOD_C; } -#line 4246 "Zend/zend_language_scanner.c" +#line 4248 "Zend/zend_language_scanner.c" yy334: YYDEBUG(334, *YYCURSOR); yych = *++YYCURSOR; @@ -4293,7 +4295,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(344, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1543 "Zend/zend_language_scanner.l" +#line 1545 "Zend/zend_language_scanner.l" { char *func_name = NULL; @@ -4309,7 +4311,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FUNC_C; } -#line 4313 "Zend/zend_language_scanner.c" +#line 4315 "Zend/zend_language_scanner.c" yy345: YYDEBUG(345, *YYCURSOR); yych = *++YYCURSOR; @@ -4329,7 +4331,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(349, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1586 "Zend/zend_language_scanner.l" +#line 1588 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4341,7 +4343,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FILE; } -#line 4345 "Zend/zend_language_scanner.c" +#line 4347 "Zend/zend_language_scanner.c" yy350: YYDEBUG(350, *YYCURSOR); yych = *++YYCURSOR; @@ -4371,7 +4373,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(356, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1527 "Zend/zend_language_scanner.l" +#line 1529 "Zend/zend_language_scanner.l" { char *class_name = NULL; @@ -4387,7 +4389,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_CLASS_C; } -#line 4391 "Zend/zend_language_scanner.c" +#line 4393 "Zend/zend_language_scanner.c" yy357: YYDEBUG(357, *YYCURSOR); yych = *++YYCURSOR; @@ -4449,11 +4451,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(369, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1269 "Zend/zend_language_scanner.l" +#line 1271 "Zend/zend_language_scanner.l" { return T_HALT_COMPILER; } -#line 4457 "Zend/zend_language_scanner.c" +#line 4459 "Zend/zend_language_scanner.c" yy370: YYDEBUG(370, *YYCURSOR); yych = *++YYCURSOR; @@ -4473,11 +4475,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(373, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1249 "Zend/zend_language_scanner.l" +#line 1251 "Zend/zend_language_scanner.l" { return T_USE; } -#line 4481 "Zend/zend_language_scanner.c" +#line 4483 "Zend/zend_language_scanner.c" yy374: YYDEBUG(374, *YYCURSOR); yych = *++YYCURSOR; @@ -4496,11 +4498,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(377, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1297 "Zend/zend_language_scanner.l" +#line 1299 "Zend/zend_language_scanner.l" { return T_UNSET; } -#line 4504 "Zend/zend_language_scanner.c" +#line 4506 "Zend/zend_language_scanner.c" yy378: YYDEBUG(378, *YYCURSOR); ++YYCURSOR; @@ -4672,11 +4674,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(395, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1197 "Zend/zend_language_scanner.l" +#line 1199 "Zend/zend_language_scanner.l" { return T_INT_CAST; } -#line 4680 "Zend/zend_language_scanner.c" +#line 4682 "Zend/zend_language_scanner.c" yy396: YYDEBUG(396, *YYCURSOR); yych = *++YYCURSOR; @@ -4720,11 +4722,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(404, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1201 "Zend/zend_language_scanner.l" +#line 1203 "Zend/zend_language_scanner.l" { return T_DOUBLE_CAST; } -#line 4728 "Zend/zend_language_scanner.c" +#line 4730 "Zend/zend_language_scanner.c" yy405: YYDEBUG(405, *YYCURSOR); yych = *++YYCURSOR; @@ -4794,11 +4796,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(418, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1205 "Zend/zend_language_scanner.l" +#line 1207 "Zend/zend_language_scanner.l" { return T_STRING_CAST; } -#line 4802 "Zend/zend_language_scanner.c" +#line 4804 "Zend/zend_language_scanner.c" yy419: YYDEBUG(419, *YYCURSOR); yych = *++YYCURSOR; @@ -4831,11 +4833,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(425, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1209 "Zend/zend_language_scanner.l" +#line 1211 "Zend/zend_language_scanner.l" { return T_ARRAY_CAST; } -#line 4839 "Zend/zend_language_scanner.c" +#line 4841 "Zend/zend_language_scanner.c" yy426: YYDEBUG(426, *YYCURSOR); yych = *++YYCURSOR; @@ -4873,11 +4875,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(433, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1213 "Zend/zend_language_scanner.l" +#line 1215 "Zend/zend_language_scanner.l" { return T_OBJECT_CAST; } -#line 4881 "Zend/zend_language_scanner.c" +#line 4883 "Zend/zend_language_scanner.c" yy434: YYDEBUG(434, *YYCURSOR); yych = *++YYCURSOR; @@ -4918,11 +4920,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(441, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1217 "Zend/zend_language_scanner.l" +#line 1219 "Zend/zend_language_scanner.l" { return T_BOOL_CAST; } -#line 4926 "Zend/zend_language_scanner.c" +#line 4928 "Zend/zend_language_scanner.c" yy442: YYDEBUG(442, *YYCURSOR); yych = *++YYCURSOR; @@ -4982,11 +4984,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(453, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1221 "Zend/zend_language_scanner.l" +#line 1223 "Zend/zend_language_scanner.l" { return T_UNSET_CAST; } -#line 4990 "Zend/zend_language_scanner.c" +#line 4992 "Zend/zend_language_scanner.c" yy454: YYDEBUG(454, *YYCURSOR); yych = *++YYCURSOR; @@ -5000,11 +5002,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(456, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1193 "Zend/zend_language_scanner.l" +#line 1195 "Zend/zend_language_scanner.l" { return T_VAR; } -#line 5008 "Zend/zend_language_scanner.c" +#line 5010 "Zend/zend_language_scanner.c" yy457: YYDEBUG(457, *YYCURSOR); yych = *++YYCURSOR; @@ -5024,11 +5026,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(460, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1185 "Zend/zend_language_scanner.l" +#line 1187 "Zend/zend_language_scanner.l" { return T_NEW; } -#line 5032 "Zend/zend_language_scanner.c" +#line 5034 "Zend/zend_language_scanner.c" yy461: YYDEBUG(461, *YYCURSOR); yych = *++YYCURSOR; @@ -5067,21 +5069,21 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(468, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1245 "Zend/zend_language_scanner.l" +#line 1247 "Zend/zend_language_scanner.l" { return T_NAMESPACE; } -#line 5075 "Zend/zend_language_scanner.c" +#line 5077 "Zend/zend_language_scanner.c" yy469: YYDEBUG(469, *YYCURSOR); ++YYCURSOR; YYDEBUG(470, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1177 "Zend/zend_language_scanner.l" +#line 1179 "Zend/zend_language_scanner.l" { return T_PAAMAYIM_NEKUDOTAYIM; } -#line 5085 "Zend/zend_language_scanner.c" +#line 5087 "Zend/zend_language_scanner.c" yy471: YYDEBUG(471, *YYCURSOR); ++YYCURSOR; @@ -5103,32 +5105,32 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(474, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1349 "Zend/zend_language_scanner.l" +#line 1351 "Zend/zend_language_scanner.l" { return T_MINUS_EQUAL; } -#line 5111 "Zend/zend_language_scanner.c" +#line 5113 "Zend/zend_language_scanner.c" yy475: YYDEBUG(475, *YYCURSOR); ++YYCURSOR; YYDEBUG(476, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1317 "Zend/zend_language_scanner.l" +#line 1319 "Zend/zend_language_scanner.l" { return T_DEC; } -#line 5121 "Zend/zend_language_scanner.c" +#line 5123 "Zend/zend_language_scanner.c" yy477: YYDEBUG(477, *YYCURSOR); ++YYCURSOR; YYDEBUG(478, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1147 "Zend/zend_language_scanner.l" +#line 1149 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); return T_OBJECT_OPERATOR; } -#line 5132 "Zend/zend_language_scanner.c" +#line 5134 "Zend/zend_language_scanner.c" yy479: YYDEBUG(479, *YYCURSOR); yych = *++YYCURSOR; @@ -5173,11 +5175,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(485, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1293 "Zend/zend_language_scanner.l" +#line 1295 "Zend/zend_language_scanner.l" { return T_PUBLIC; } -#line 5181 "Zend/zend_language_scanner.c" +#line 5183 "Zend/zend_language_scanner.c" yy486: YYDEBUG(486, *YYCURSOR); yych = *++YYCURSOR; @@ -5232,11 +5234,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(494, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1289 "Zend/zend_language_scanner.l" +#line 1291 "Zend/zend_language_scanner.l" { return T_PROTECTED; } -#line 5240 "Zend/zend_language_scanner.c" +#line 5242 "Zend/zend_language_scanner.c" yy495: YYDEBUG(495, *YYCURSOR); yych = *++YYCURSOR; @@ -5266,11 +5268,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(500, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1285 "Zend/zend_language_scanner.l" +#line 1287 "Zend/zend_language_scanner.l" { return T_PRIVATE; } -#line 5274 "Zend/zend_language_scanner.c" +#line 5276 "Zend/zend_language_scanner.c" yy501: YYDEBUG(501, *YYCURSOR); ++YYCURSOR; @@ -5279,11 +5281,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(502, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1123 "Zend/zend_language_scanner.l" +#line 1125 "Zend/zend_language_scanner.l" { return T_PRINT; } -#line 5287 "Zend/zend_language_scanner.c" +#line 5289 "Zend/zend_language_scanner.c" yy503: YYDEBUG(503, *YYCURSOR); yych = *++YYCURSOR; @@ -5308,11 +5310,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(507, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1115 "Zend/zend_language_scanner.l" +#line 1117 "Zend/zend_language_scanner.l" { return T_GOTO; } -#line 5316 "Zend/zend_language_scanner.c" +#line 5318 "Zend/zend_language_scanner.c" yy508: YYDEBUG(508, *YYCURSOR); yych = *++YYCURSOR; @@ -5336,11 +5338,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(512, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1257 "Zend/zend_language_scanner.l" +#line 1259 "Zend/zend_language_scanner.l" { return T_GLOBAL; } -#line 5344 "Zend/zend_language_scanner.c" +#line 5346 "Zend/zend_language_scanner.c" yy513: YYDEBUG(513, *YYCURSOR); yych = *++YYCURSOR; @@ -5377,11 +5379,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(520, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1107 "Zend/zend_language_scanner.l" +#line 1109 "Zend/zend_language_scanner.l" { return T_BREAK; } -#line 5385 "Zend/zend_language_scanner.c" +#line 5387 "Zend/zend_language_scanner.c" yy521: YYDEBUG(521, *YYCURSOR); yych = *++YYCURSOR; @@ -5421,11 +5423,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(528, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1091 "Zend/zend_language_scanner.l" +#line 1093 "Zend/zend_language_scanner.l" { return T_SWITCH; } -#line 5429 "Zend/zend_language_scanner.c" +#line 5431 "Zend/zend_language_scanner.c" yy529: YYDEBUG(529, *YYCURSOR); yych = *++YYCURSOR; @@ -5449,11 +5451,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(533, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1273 "Zend/zend_language_scanner.l" +#line 1275 "Zend/zend_language_scanner.l" { return T_STATIC; } -#line 5457 "Zend/zend_language_scanner.c" +#line 5459 "Zend/zend_language_scanner.c" yy534: YYDEBUG(534, *YYCURSOR); yych = *++YYCURSOR; @@ -5480,11 +5482,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(538, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1087 "Zend/zend_language_scanner.l" +#line 1089 "Zend/zend_language_scanner.l" { return T_AS; } -#line 5488 "Zend/zend_language_scanner.c" +#line 5490 "Zend/zend_language_scanner.c" yy539: YYDEBUG(539, *YYCURSOR); yych = *++YYCURSOR; @@ -5503,11 +5505,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(542, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1309 "Zend/zend_language_scanner.l" +#line 1311 "Zend/zend_language_scanner.l" { return T_ARRAY; } -#line 5511 "Zend/zend_language_scanner.c" +#line 5513 "Zend/zend_language_scanner.c" yy543: YYDEBUG(543, *YYCURSOR); ++YYCURSOR; @@ -5516,11 +5518,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(544, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1401 "Zend/zend_language_scanner.l" +#line 1403 "Zend/zend_language_scanner.l" { return T_LOGICAL_AND; } -#line 5524 "Zend/zend_language_scanner.c" +#line 5526 "Zend/zend_language_scanner.c" yy545: YYDEBUG(545, *YYCURSOR); yych = *++YYCURSOR; @@ -5554,11 +5556,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(551, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1277 "Zend/zend_language_scanner.l" +#line 1279 "Zend/zend_language_scanner.l" { return T_ABSTRACT; } -#line 5562 "Zend/zend_language_scanner.c" +#line 5564 "Zend/zend_language_scanner.c" yy552: YYDEBUG(552, *YYCURSOR); yych = *++YYCURSOR; @@ -5582,11 +5584,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(556, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1047 "Zend/zend_language_scanner.l" +#line 1049 "Zend/zend_language_scanner.l" { return T_WHILE; } -#line 5590 "Zend/zend_language_scanner.c" +#line 5592 "Zend/zend_language_scanner.c" yy557: YYDEBUG(557, *YYCURSOR); ++YYCURSOR; @@ -5595,11 +5597,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(558, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1031 "Zend/zend_language_scanner.l" +#line 1033 "Zend/zend_language_scanner.l" { return T_IF; } -#line 5603 "Zend/zend_language_scanner.c" +#line 5605 "Zend/zend_language_scanner.c" yy559: YYDEBUG(559, *YYCURSOR); yych = *++YYCURSOR; @@ -5651,11 +5653,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(565, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1261 "Zend/zend_language_scanner.l" +#line 1263 "Zend/zend_language_scanner.l" { return T_ISSET; } -#line 5659 "Zend/zend_language_scanner.c" +#line 5661 "Zend/zend_language_scanner.c" yy566: YYDEBUG(566, *YYCURSOR); yych = *++YYCURSOR; @@ -5709,11 +5711,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy573: YYDEBUG(573, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1229 "Zend/zend_language_scanner.l" +#line 1231 "Zend/zend_language_scanner.l" { return T_INCLUDE; } -#line 5717 "Zend/zend_language_scanner.c" +#line 5719 "Zend/zend_language_scanner.c" yy574: YYDEBUG(574, *YYCURSOR); yych = *++YYCURSOR; @@ -5742,11 +5744,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(579, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1233 "Zend/zend_language_scanner.l" +#line 1235 "Zend/zend_language_scanner.l" { return T_INCLUDE_ONCE; } -#line 5750 "Zend/zend_language_scanner.c" +#line 5752 "Zend/zend_language_scanner.c" yy580: YYDEBUG(580, *YYCURSOR); yych = *++YYCURSOR; @@ -5780,11 +5782,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(586, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1131 "Zend/zend_language_scanner.l" +#line 1133 "Zend/zend_language_scanner.l" { return T_INTERFACE; } -#line 5788 "Zend/zend_language_scanner.c" +#line 5790 "Zend/zend_language_scanner.c" yy587: YYDEBUG(587, *YYCURSOR); yych = *++YYCURSOR; @@ -5834,11 +5836,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(594, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1253 "Zend/zend_language_scanner.l" +#line 1255 "Zend/zend_language_scanner.l" { return T_INSTEADOF; } -#line 5842 "Zend/zend_language_scanner.c" +#line 5844 "Zend/zend_language_scanner.c" yy595: YYDEBUG(595, *YYCURSOR); yych = *++YYCURSOR; @@ -5867,11 +5869,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(600, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1083 "Zend/zend_language_scanner.l" +#line 1085 "Zend/zend_language_scanner.l" { return T_INSTANCEOF; } -#line 5875 "Zend/zend_language_scanner.c" +#line 5877 "Zend/zend_language_scanner.c" yy601: YYDEBUG(601, *YYCURSOR); yych = *++YYCURSOR; @@ -5915,11 +5917,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(609, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1143 "Zend/zend_language_scanner.l" +#line 1145 "Zend/zend_language_scanner.l" { return T_IMPLEMENTS; } -#line 5923 "Zend/zend_language_scanner.c" +#line 5925 "Zend/zend_language_scanner.c" yy610: YYDEBUG(610, *YYCURSOR); yych = *++YYCURSOR; @@ -5947,11 +5949,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(613, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1019 "Zend/zend_language_scanner.l" +#line 1021 "Zend/zend_language_scanner.l" { return T_TRY; } -#line 5955 "Zend/zend_language_scanner.c" +#line 5957 "Zend/zend_language_scanner.c" yy614: YYDEBUG(614, *YYCURSOR); yych = *++YYCURSOR; @@ -5970,11 +5972,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(617, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1135 "Zend/zend_language_scanner.l" +#line 1137 "Zend/zend_language_scanner.l" { return T_TRAIT; } -#line 5978 "Zend/zend_language_scanner.c" +#line 5980 "Zend/zend_language_scanner.c" yy618: YYDEBUG(618, *YYCURSOR); yych = *++YYCURSOR; @@ -5993,11 +5995,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(621, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1027 "Zend/zend_language_scanner.l" +#line 1029 "Zend/zend_language_scanner.l" { return T_THROW; } -#line 6001 "Zend/zend_language_scanner.c" +#line 6003 "Zend/zend_language_scanner.c" yy622: YYDEBUG(622, *YYCURSOR); yych = *++YYCURSOR; @@ -6058,11 +6060,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy629: YYDEBUG(629, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1237 "Zend/zend_language_scanner.l" +#line 1239 "Zend/zend_language_scanner.l" { return T_REQUIRE; } -#line 6066 "Zend/zend_language_scanner.c" +#line 6068 "Zend/zend_language_scanner.c" yy630: YYDEBUG(630, *YYCURSOR); yych = *++YYCURSOR; @@ -6091,11 +6093,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(635, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1241 "Zend/zend_language_scanner.l" +#line 1243 "Zend/zend_language_scanner.l" { return T_REQUIRE_ONCE; } -#line 6099 "Zend/zend_language_scanner.c" +#line 6101 "Zend/zend_language_scanner.c" yy636: YYDEBUG(636, *YYCURSOR); yych = *++YYCURSOR; @@ -6114,11 +6116,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(639, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1015 "Zend/zend_language_scanner.l" +#line 1017 "Zend/zend_language_scanner.l" { return T_RETURN; } -#line 6122 "Zend/zend_language_scanner.c" +#line 6124 "Zend/zend_language_scanner.c" yy640: YYDEBUG(640, *YYCURSOR); yych = *++YYCURSOR; @@ -6199,11 +6201,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(650, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1111 "Zend/zend_language_scanner.l" +#line 1113 "Zend/zend_language_scanner.l" { return T_CONTINUE; } -#line 6207 "Zend/zend_language_scanner.c" +#line 6209 "Zend/zend_language_scanner.c" yy651: YYDEBUG(651, *YYCURSOR); ++YYCURSOR; @@ -6212,11 +6214,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(652, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1011 "Zend/zend_language_scanner.l" +#line 1013 "Zend/zend_language_scanner.l" { return T_CONST; } -#line 6220 "Zend/zend_language_scanner.c" +#line 6222 "Zend/zend_language_scanner.c" yy653: YYDEBUG(653, *YYCURSOR); yych = *++YYCURSOR; @@ -6241,11 +6243,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(657, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1189 "Zend/zend_language_scanner.l" +#line 1191 "Zend/zend_language_scanner.l" { return T_CLONE; } -#line 6249 "Zend/zend_language_scanner.c" +#line 6251 "Zend/zend_language_scanner.c" yy658: YYDEBUG(658, *YYCURSOR); yych = *++YYCURSOR; @@ -6259,11 +6261,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(660, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1127 "Zend/zend_language_scanner.l" +#line 1129 "Zend/zend_language_scanner.l" { return T_CLASS; } -#line 6267 "Zend/zend_language_scanner.c" +#line 6269 "Zend/zend_language_scanner.c" yy661: YYDEBUG(661, *YYCURSOR); yych = *++YYCURSOR; @@ -6283,11 +6285,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(664, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1099 "Zend/zend_language_scanner.l" +#line 1101 "Zend/zend_language_scanner.l" { return T_CASE; } -#line 6291 "Zend/zend_language_scanner.c" +#line 6293 "Zend/zend_language_scanner.c" yy665: YYDEBUG(665, *YYCURSOR); yych = *++YYCURSOR; @@ -6301,11 +6303,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(667, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1023 "Zend/zend_language_scanner.l" +#line 1025 "Zend/zend_language_scanner.l" { return T_CATCH; } -#line 6309 "Zend/zend_language_scanner.c" +#line 6311 "Zend/zend_language_scanner.c" yy668: YYDEBUG(668, *YYCURSOR); yych = *++YYCURSOR; @@ -6356,11 +6358,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(677, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1007 "Zend/zend_language_scanner.l" +#line 1009 "Zend/zend_language_scanner.l" { return T_FUNCTION; } -#line 6364 "Zend/zend_language_scanner.c" +#line 6366 "Zend/zend_language_scanner.c" yy678: YYDEBUG(678, *YYCURSOR); ++YYCURSOR; @@ -6384,11 +6386,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy679: YYDEBUG(679, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1059 "Zend/zend_language_scanner.l" +#line 1061 "Zend/zend_language_scanner.l" { return T_FOR; } -#line 6392 "Zend/zend_language_scanner.c" +#line 6394 "Zend/zend_language_scanner.c" yy680: YYDEBUG(680, *YYCURSOR); yych = *++YYCURSOR; @@ -6412,11 +6414,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(684, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1067 "Zend/zend_language_scanner.l" +#line 1069 "Zend/zend_language_scanner.l" { return T_FOREACH; } -#line 6420 "Zend/zend_language_scanner.c" +#line 6422 "Zend/zend_language_scanner.c" yy685: YYDEBUG(685, *YYCURSOR); yych = *++YYCURSOR; @@ -6435,11 +6437,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(688, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1281 "Zend/zend_language_scanner.l" +#line 1283 "Zend/zend_language_scanner.l" { return T_FINAL; } -#line 6443 "Zend/zend_language_scanner.c" +#line 6445 "Zend/zend_language_scanner.c" yy689: YYDEBUG(689, *YYCURSOR); yych = *++YYCURSOR; @@ -6470,11 +6472,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(692, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1055 "Zend/zend_language_scanner.l" +#line 1057 "Zend/zend_language_scanner.l" { return T_DO; } -#line 6478 "Zend/zend_language_scanner.c" +#line 6480 "Zend/zend_language_scanner.c" yy693: YYDEBUG(693, *YYCURSOR); ++YYCURSOR; @@ -6483,11 +6485,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(694, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1003 "Zend/zend_language_scanner.l" +#line 1005 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6491 "Zend/zend_language_scanner.c" +#line 6493 "Zend/zend_language_scanner.c" yy695: YYDEBUG(695, *YYCURSOR); yych = *++YYCURSOR; @@ -6522,11 +6524,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(701, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1103 "Zend/zend_language_scanner.l" +#line 1105 "Zend/zend_language_scanner.l" { return T_DEFAULT; } -#line 6530 "Zend/zend_language_scanner.c" +#line 6532 "Zend/zend_language_scanner.c" yy702: YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; @@ -6550,11 +6552,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(706, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1075 "Zend/zend_language_scanner.l" +#line 1077 "Zend/zend_language_scanner.l" { return T_DECLARE; } -#line 6558 "Zend/zend_language_scanner.c" +#line 6560 "Zend/zend_language_scanner.c" yy707: YYDEBUG(707, *YYCURSOR); yych = *++YYCURSOR; @@ -6634,11 +6636,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(719, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1139 "Zend/zend_language_scanner.l" +#line 1141 "Zend/zend_language_scanner.l" { return T_EXTENDS; } -#line 6642 "Zend/zend_language_scanner.c" +#line 6644 "Zend/zend_language_scanner.c" yy720: YYDEBUG(720, *YYCURSOR); ++YYCURSOR; @@ -6647,11 +6649,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(721, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 999 "Zend/zend_language_scanner.l" +#line 1001 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6655 "Zend/zend_language_scanner.c" +#line 6657 "Zend/zend_language_scanner.c" yy722: YYDEBUG(722, *YYCURSOR); yych = *++YYCURSOR; @@ -6665,11 +6667,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(724, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1225 "Zend/zend_language_scanner.l" +#line 1227 "Zend/zend_language_scanner.l" { return T_EVAL; } -#line 6673 "Zend/zend_language_scanner.c" +#line 6675 "Zend/zend_language_scanner.c" yy725: YYDEBUG(725, *YYCURSOR); yych = *++YYCURSOR; @@ -6739,11 +6741,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(735, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1051 "Zend/zend_language_scanner.l" +#line 1053 "Zend/zend_language_scanner.l" { return T_ENDWHILE; } -#line 6747 "Zend/zend_language_scanner.c" +#line 6749 "Zend/zend_language_scanner.c" yy736: YYDEBUG(736, *YYCURSOR); yych = *++YYCURSOR; @@ -6772,11 +6774,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(741, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1095 "Zend/zend_language_scanner.l" +#line 1097 "Zend/zend_language_scanner.l" { return T_ENDSWITCH; } -#line 6780 "Zend/zend_language_scanner.c" +#line 6782 "Zend/zend_language_scanner.c" yy742: YYDEBUG(742, *YYCURSOR); ++YYCURSOR; @@ -6785,11 +6787,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(743, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1039 "Zend/zend_language_scanner.l" +#line 1041 "Zend/zend_language_scanner.l" { return T_ENDIF; } -#line 6793 "Zend/zend_language_scanner.c" +#line 6795 "Zend/zend_language_scanner.c" yy744: YYDEBUG(744, *YYCURSOR); yych = *++YYCURSOR; @@ -6818,11 +6820,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy746: YYDEBUG(746, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1063 "Zend/zend_language_scanner.l" +#line 1065 "Zend/zend_language_scanner.l" { return T_ENDFOR; } -#line 6826 "Zend/zend_language_scanner.c" +#line 6828 "Zend/zend_language_scanner.c" yy747: YYDEBUG(747, *YYCURSOR); yych = *++YYCURSOR; @@ -6846,11 +6848,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(751, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1071 "Zend/zend_language_scanner.l" +#line 1073 "Zend/zend_language_scanner.l" { return T_ENDFOREACH; } -#line 6854 "Zend/zend_language_scanner.c" +#line 6856 "Zend/zend_language_scanner.c" yy752: YYDEBUG(752, *YYCURSOR); yych = *++YYCURSOR; @@ -6884,11 +6886,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(758, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1079 "Zend/zend_language_scanner.l" +#line 1081 "Zend/zend_language_scanner.l" { return T_ENDDECLARE; } -#line 6892 "Zend/zend_language_scanner.c" +#line 6894 "Zend/zend_language_scanner.c" yy759: YYDEBUG(759, *YYCURSOR); yych = *++YYCURSOR; @@ -6907,11 +6909,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(762, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1265 "Zend/zend_language_scanner.l" +#line 1267 "Zend/zend_language_scanner.l" { return T_EMPTY; } -#line 6915 "Zend/zend_language_scanner.c" +#line 6917 "Zend/zend_language_scanner.c" yy763: YYDEBUG(763, *YYCURSOR); yych = *++YYCURSOR; @@ -6940,11 +6942,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy765: YYDEBUG(765, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1043 "Zend/zend_language_scanner.l" +#line 1045 "Zend/zend_language_scanner.l" { return T_ELSE; } -#line 6948 "Zend/zend_language_scanner.c" +#line 6950 "Zend/zend_language_scanner.c" yy766: YYDEBUG(766, *YYCURSOR); yych = *++YYCURSOR; @@ -6958,11 +6960,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(768, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1035 "Zend/zend_language_scanner.l" +#line 1037 "Zend/zend_language_scanner.l" { return T_ELSEIF; } -#line 6966 "Zend/zend_language_scanner.c" +#line 6968 "Zend/zend_language_scanner.c" yy769: YYDEBUG(769, *YYCURSOR); yych = *++YYCURSOR; @@ -6976,11 +6978,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(771, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1119 "Zend/zend_language_scanner.l" +#line 1121 "Zend/zend_language_scanner.l" { return T_ECHO; } -#line 6984 "Zend/zend_language_scanner.c" +#line 6986 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7053,7 +7055,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy775: YYDEBUG(775, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1152 "Zend/zend_language_scanner.l" +#line 1154 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -7061,7 +7063,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7065 "Zend/zend_language_scanner.c" +#line 7067 "Zend/zend_language_scanner.c" yy776: YYDEBUG(776, *YYCURSOR); ++YYCURSOR; @@ -7069,13 +7071,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy777: YYDEBUG(777, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1171 "Zend/zend_language_scanner.l" +#line 1173 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); goto restart; } -#line 7079 "Zend/zend_language_scanner.c" +#line 7081 "Zend/zend_language_scanner.c" yy778: YYDEBUG(778, *YYCURSOR); ++YYCURSOR; @@ -7084,14 +7086,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy779: YYDEBUG(779, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1164 "Zend/zend_language_scanner.l" +#line 1166 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7095 "Zend/zend_language_scanner.c" +#line 7097 "Zend/zend_language_scanner.c" yy780: YYDEBUG(780, *YYCURSOR); yych = *++YYCURSOR; @@ -7112,11 +7114,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(784, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1160 "Zend/zend_language_scanner.l" +#line 1162 "Zend/zend_language_scanner.l" { return T_OBJECT_OPERATOR; } -#line 7120 "Zend/zend_language_scanner.c" +#line 7122 "Zend/zend_language_scanner.c" yy785: YYDEBUG(785, *YYCURSOR); ++YYCURSOR; @@ -7186,7 +7188,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy790: YYDEBUG(790, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1443 "Zend/zend_language_scanner.l" +#line 1445 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -7194,20 +7196,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7198 "Zend/zend_language_scanner.c" +#line 7200 "Zend/zend_language_scanner.c" yy791: YYDEBUG(791, *YYCURSOR); ++YYCURSOR; YYDEBUG(792, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1452 "Zend/zend_language_scanner.l" +#line 1454 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7211 "Zend/zend_language_scanner.c" +#line 7213 "Zend/zend_language_scanner.c" yy793: YYDEBUG(793, *YYCURSOR); ++YYCURSOR; @@ -7229,7 +7231,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(798, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2275 "Zend/zend_language_scanner.l" +#line 2277 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7284,7 +7286,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7288 "Zend/zend_language_scanner.c" +#line 7290 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7384,7 +7386,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy802: YYDEBUG(802, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1502 "Zend/zend_language_scanner.l" +#line 1504 "Zend/zend_language_scanner.l" { /* Offset could be treated as a long */ if (yyleng < MAX_LENGTH_OF_LONG - 1 || (yyleng == MAX_LENGTH_OF_LONG - 1 && strcmp(yytext, long_min_digits) < 0)) { zendlval->value.lval = strtol(yytext, NULL, 10); @@ -7396,7 +7398,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7400 "Zend/zend_language_scanner.c" +#line 7402 "Zend/zend_language_scanner.c" yy803: YYDEBUG(803, *YYCURSOR); yych = *++YYCURSOR; @@ -7416,23 +7418,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy805: YYDEBUG(805, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1803 "Zend/zend_language_scanner.l" +#line 1805 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7425 "Zend/zend_language_scanner.c" +#line 7427 "Zend/zend_language_scanner.c" yy806: YYDEBUG(806, *YYCURSOR); ++YYCURSOR; YYDEBUG(807, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1798 "Zend/zend_language_scanner.l" +#line 1800 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7436 "Zend/zend_language_scanner.c" +#line 7438 "Zend/zend_language_scanner.c" yy808: YYDEBUG(808, *YYCURSOR); yych = *++YYCURSOR; @@ -7442,14 +7444,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(810, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1808 "Zend/zend_language_scanner.l" +#line 1810 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7453 "Zend/zend_language_scanner.c" +#line 7455 "Zend/zend_language_scanner.c" yy811: YYDEBUG(811, *YYCURSOR); ++YYCURSOR; @@ -7458,19 +7460,19 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy812: YYDEBUG(812, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1817 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7468 "Zend/zend_language_scanner.c" +#line 7470 "Zend/zend_language_scanner.c" yy813: YYDEBUG(813, *YYCURSOR); ++YYCURSOR; YYDEBUG(814, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2331 "Zend/zend_language_scanner.l" +#line 2333 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7479,7 +7481,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7483 "Zend/zend_language_scanner.c" +#line 7485 "Zend/zend_language_scanner.c" yy815: YYDEBUG(815, *YYCURSOR); ++YYCURSOR; @@ -7515,13 +7517,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy819: YYDEBUG(819, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1792 "Zend/zend_language_scanner.l" +#line 1794 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7525 "Zend/zend_language_scanner.c" +#line 7527 "Zend/zend_language_scanner.c" yy820: YYDEBUG(820, *YYCURSOR); ++YYCURSOR; @@ -7553,14 +7555,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy826: YYDEBUG(826, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1514 "Zend/zend_language_scanner.l" +#line 1516 "Zend/zend_language_scanner.l" { /* Offset must be treated as a string */ zendlval->value.str.val = (char *)estrndup(yytext, yyleng); zendlval->value.str.len = yyleng; zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7564 "Zend/zend_language_scanner.c" +#line 7566 "Zend/zend_language_scanner.c" yy827: YYDEBUG(827, *YYCURSOR); ++YYCURSOR; @@ -7573,6 +7575,6 @@ int lex_scan(zval *zendlval TSRMLS_DC) goto yy826; } } -#line 2340 "Zend/zend_language_scanner.l" +#line 2342 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index cd329c61f942c..8c04cf7602868 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -174,6 +174,7 @@ static void yy_scan_buffer(char *str, unsigned int len TSRMLS_DC) void startup_scanner(TSRMLS_D) { + CG(parse_error) = 0; CG(heredoc) = NULL; CG(heredoc_len) = 0; CG(doc_comment) = NULL; @@ -187,6 +188,7 @@ void shutdown_scanner(TSRMLS_D) efree(CG(heredoc)); CG(heredoc_len)=0; } + CG(parse_error) = 0; zend_stack_destroy(&SCNG(state_stack)); RESET_DOC_COMMENT(); } diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index f0bd4af35b922..0c78414666643 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jun 5 21:39:30 2011 */ +/* Generated by re2c 0.13.5 on Thu Jun 23 17:57:45 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/main/main.c b/main/main.c index f4a70cb113585..e52853397fa34 100644 --- a/main/main.c +++ b/main/main.c @@ -990,7 +990,7 @@ static void php_error_cb(int type, const char *error_filename, const uint error_ char *append_string = INI_STR("error_append_string"); if (PG(html_errors)) { - if (type == E_ERROR) { + if (type == E_ERROR || type == E_PARSE) { size_t len; char *buf = php_escape_html_entities(buffer, buffer_len, &len, 0, ENT_COMPAT, NULL TSRMLS_CC); php_printf("%s
\n%s: %s in %s on line %d
\n%s", STR_PRINT(prepend_string), error_type_str, buf, error_filename, error_lineno, STR_PRINT(append_string)); @@ -1061,7 +1061,9 @@ static void php_error_cb(int type, const char *error_filename, const uint error_ sapi_header_op(SAPI_HEADER_REPLACE, &ctr TSRMLS_CC); } /* the parser would return 1 (failure), we can bail out nicely */ - if (type != E_PARSE) { + if (type == E_PARSE) { + CG(parse_error) = 0; + } else { /* restore memory limit */ zend_set_memory_limit(PG(memory_limit)); efree(buffer); From bcf7e60d4cb7b64e6df7179f91a198ddbd2fb2ab Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 24 Jun 2011 00:38:53 +0000 Subject: [PATCH 0221/2394] - Fixed build on Windows --- Zend/zend_language_parser.y | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index e6f49a1595f91..3d774bff25008 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -1150,7 +1150,8 @@ static YYSIZE_T zend_yytnamerr(char *yyres, const char *yystr) { TSRMLS_FETCH(); if (CG(parse_error) == 0) { - char buffer[120], *end, *str, *tok1 = NULL, *tok2 = NULL; + char buffer[120]; + const unsigned char *end, *str, *tok1 = NULL, *tok2 = NULL; unsigned int len = 0, toklen = 0, yystr_len; CG(parse_error) = 1; @@ -1158,7 +1159,8 @@ static YYSIZE_T zend_yytnamerr(char *yyres, const char *yystr) if (LANG_SCNG(yy_text)[0] == 0 && LANG_SCNG(yy_leng) == 1 && memcmp(yystr, ZEND_STRL("\"end of file\"")) == 0) { - return yystpcpy(yyres, "end of file") - yyres; + yystpcpy(yyres, "end of file"); + return sizeof("end of file")-1; } str = LANG_SCNG(yy_text); @@ -1183,7 +1185,8 @@ static YYSIZE_T zend_yytnamerr(char *yyres, const char *yystr) } else { snprintf(buffer, sizeof(buffer), "'%.*s'", len, str); } - return yystpcpy(yyres, buffer) - yyres; + yystpcpy(yyres, buffer); + return len + (toklen ? toklen + 1 : 0) + 2; } } if (*yystr == '"') { @@ -1196,7 +1199,8 @@ static YYSIZE_T zend_yytnamerr(char *yyres, const char *yystr) yyres[yyn] = '\0'; return yyn; } - return yystpcpy(yyres, yystr) - yyres; + yystpcpy(yyres, yystr); + return strlen(yystr); } /* From 29565d1a4cad22d6bc3cd5ffc12174dd26969974 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Fri, 24 Jun 2011 11:19:34 +0000 Subject: [PATCH 0222/2394] - Added a new PHPAPI function to return module_initialized: php_get_module_initialized(). --- main/main.c | 7 +++++++ main/php.h | 1 + 2 files changed, 8 insertions(+) diff --git a/main/main.c b/main/main.c index e52853397fa34..f02720130fbc6 100644 --- a/main/main.c +++ b/main/main.c @@ -528,6 +528,13 @@ static int php_during_module_shutdown(void) } /* }}} */ +/* {{{ php_get_module_initialized + */ +PHPAPI int php_get_module_initialized(void) +{ + return module_initialized; +} + /* {{{ php_log_err */ PHPAPI void php_log_err(char *log_message TSRMLS_DC) diff --git a/main/php.h b/main/php.h index 278d6390fbb34..e108c254131ea 100644 --- a/main/php.h +++ b/main/php.h @@ -285,6 +285,7 @@ void phperror(char *error); PHPAPI int php_write(void *buf, uint size TSRMLS_DC); PHPAPI int php_printf(const char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, 2); +PHPAPI int php_get_module_initialized(void); PHPAPI void php_log_err(char *log_message TSRMLS_DC); int Debug(char *format, ...) PHP_ATTRIBUTE_FORMAT(printf, 1, 2); int cfgparse(void); From c4e0d06aee31686539c6cb8d2d9dc062cf822438 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 24 Jun 2011 19:18:06 +0000 Subject: [PATCH 0223/2394] - Added SKIPIF --- ext/pcntl/tests/pcntl_exec.phpt | 5 ++++- ext/pcntl/tests/pcntl_exec_2.phpt | 7 ++++++- ext/pcntl/tests/pcntl_exec_3.phpt | 2 ++ ext/pcntl/tests/pcntl_signal.phpt | 1 + ext/pcntl/tests/pcntl_wait.phpt | 2 +- 5 files changed, 14 insertions(+), 3 deletions(-) diff --git a/ext/pcntl/tests/pcntl_exec.phpt b/ext/pcntl/tests/pcntl_exec.phpt index 756fc959c3cf5..9d2ec1dcf5fad 100644 --- a/ext/pcntl/tests/pcntl_exec.phpt +++ b/ext/pcntl/tests/pcntl_exec.phpt @@ -1,7 +1,10 @@ --TEST-- pcntl_exec() --SKIPIF-- - + --FILE-- + --FILE-- --FILE-- --FILE-- - Date: Fri, 24 Jun 2011 19:23:25 +0000 Subject: [PATCH 0224/2394] - Fixed tests --- tests/basic/bug51709_1.phpt | 2 +- tests/basic/bug51709_2.phpt | 2 +- tests/lang/bug21820.phpt | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/basic/bug51709_1.phpt b/tests/basic/bug51709_1.phpt index 8abb92555d782..19d298ad7d42d 100644 --- a/tests/basic/bug51709_1.phpt +++ b/tests/basic/bug51709_1.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: syntax error, unexpected T_FOR, expecting T_STRING in %sbug51709_1.php on line %d +Parse error: syntax error, unexpected 'for' (T_FOR), expecting identifier (T_STRING) in %sbug51709_1.php on line %d diff --git a/tests/basic/bug51709_2.phpt b/tests/basic/bug51709_2.phpt index 7763cafe52399..c5e904df8307a 100644 --- a/tests/basic/bug51709_2.phpt +++ b/tests/basic/bug51709_2.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: syntax error, unexpected T_GOTO, expecting T_STRING in %sbug51709_2.php on line %d +Parse error: syntax error, unexpected 'goto' (T_GOTO), expecting identifier (T_STRING) in %sbug51709_2.php on line %d diff --git a/tests/lang/bug21820.phpt b/tests/lang/bug21820.phpt index 0ca233ea84113..b862309e311c1 100644 --- a/tests/lang/bug21820.phpt +++ b/tests/lang/bug21820.phpt @@ -9,5 +9,5 @@ $arr = array('foo' => 'bar'); echo "$arr['foo']"; ?> ---EXPECTREGEX-- -Parse error: (parse|syntax) error, .*expecting `?T_STRING'? or `?T_VARIABLE'? or `?T_NUM_STRING'? in .*bug21820.php on line .* +--EXPECTF-- +Parse error: syntax error, unexpected '' (T_ENCAPSED_AND_WHITESPACE), expecting identifier (T_STRING) or variable (T_VARIABLE) or number (T_NUM_STRING) in %sbug21820.php on line %d From 6bf101db546c8d015e2e7343f5173afa379d1a48 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Fri, 24 Jun 2011 23:10:37 +0000 Subject: [PATCH 0225/2394] Add http_proxy env var support to run-tests.php result submission --- run-tests.php | 35 +++++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/run-tests.php b/run-tests.php index dc5b7178efde2..0b0b253c15dd4 100755 --- a/run-tests.php +++ b/run-tests.php @@ -312,6 +312,7 @@ function write_information($show_html) define('PHP_QA_EMAIL', 'qa-reports@lists.php.net'); define('QA_SUBMISSION_PAGE', 'http://qa.php.net/buildtest-process.php'); +define('QA_REPORTS_PAGE', 'http://qa.php.net/reports'); function save_or_mail_results() { @@ -324,9 +325,13 @@ function save_or_mail_results() if ($sum_results['FAILED'] || $sum_results['BORKED'] || $sum_results['WARNED'] || $sum_results['LEAKED'] || $sum_results['XFAILED']) { echo "\nYou may have found a problem in PHP."; } - echo "\nWe would like to send this report automatically to the\n"; - echo "PHP QA team, to give us a better understanding of how\nthe test cases are doing. If you don't want to send it\n"; - echo "immediately, you can choose \"s\" to save the report to\na file that you can send us later.\n"; + echo "\nThis report can be automatically sent to the PHP QA team at\n"; + echo QA_REPORTS_PAGE . "\n"; + echo "Reports for current versions of PHP will also appear on\n"; + echo "http://news.php.net/php.qa.reports\n"; + echo "This gives us a better understanding of PHP's behavior.\n"; + echo "If you don't want to send the report immediately you can choose\n"; + echo "option \"s\" to save it. You can then email this report to ". PHP_QA_EMAIL . " later.\n"; echo "Do you want to send this report now? [Yns]: "; flush(); @@ -951,14 +956,24 @@ function mail_qa_team($data, $compression, $status = false) { $url_bits = parse_url(QA_SUBMISSION_PAGE); - if (empty($url_bits['port'])) { - $url_bits['port'] = 80; - } + if (($proxy = getenv('http_proxy'))) { + $proxy = parse_url($proxy); + $path = $url_bits['host'].$url_bits['path']; + $host = $proxy['host']; + if (empty($proxy['port'])) { + $proxy['port'] = 80; + } + $port = $proxy['port']; + } else { + $path = $url_bits['path']; + $host = $url_bits['host']; + $port = empty($url_bits['port']) ? 80 : $port = $url_bits['port']; + } $data = "php_test_data=" . urlencode(base64_encode(str_replace("\00", '[0x0]', $data))); $data_length = strlen($data); - $fs = fsockopen($url_bits['host'], $url_bits['port'], $errno, $errstr, 10); + $fs = fsockopen($host, $port, $errno, $errstr, 10); if (!$fs) { return false; @@ -966,9 +981,9 @@ function mail_qa_team($data, $compression, $status = false) $php_version = urlencode(TESTED_PHP_VERSION); - echo "\nPosting to {$url_bits['host']} {$url_bits['path']}\n"; - fwrite($fs, "POST " . $url_bits['path'] . "?status=$status&version=$php_version HTTP/1.1\r\n"); - fwrite($fs, "Host: " . $url_bits['host'] . "\r\n"); + echo "\nPosting to ". QA_SUBMISSION_PAGE . "\n"; + fwrite($fs, "POST " . $path . "?status=$status&version=$php_version HTTP/1.1\r\n"); + fwrite($fs, "Host: " . $host . "\r\n"); fwrite($fs, "User-Agent: QA Browser 0.1\r\n"); fwrite($fs, "Content-Type: application/x-www-form-urlencoded\r\n"); fwrite($fs, "Content-Length: " . $data_length . "\r\n\r\n"); From bf61fbb33ad1efc138193ef09a7047344001063e Mon Sep 17 00:00:00 2001 From: Knut Urdalen Date: Sat, 25 Jun 2011 04:50:42 +0000 Subject: [PATCH 0226/2394] fixed/refactored some spl tests related to owner/group retrieval --- .../DirectoryIterator_getGroup_basic.phpt | 20 +++++------ .../DirectoryIterator_getOwner_basic.phpt | 35 +++++++++--------- ext/spl/tests/SplFileInfo_getGroup_basic.phpt | 36 +++++++++---------- ext/spl/tests/SplFileInfo_getOwner_basic.phpt | 36 +++++++++---------- 4 files changed, 56 insertions(+), 71 deletions(-) diff --git a/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt b/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt index 58387cccef232..3573d85852f12 100644 --- a/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt +++ b/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt @@ -8,23 +8,19 @@ Daniel Londero Francesco Trucchia Jacopo Romei #Test Fest Cesena (Italy) on 2009-06-20 ---SKIPIF-- - --FILE-- getGroup() == $result); - +$dirname = basename(__FILE__, '.phpt'); +mkdir($dirname); +$dir = new DirectoryIterator($dirname); +$expected = filegroup($dirname); +$actual = $dir->getGroup(); +var_dump($expected == $actual); ?> --CLEAN-- --EXPECTF-- bool(true) diff --git a/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt b/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt index e342dcdb6fa53..f02cb6e04e4a9 100644 --- a/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt +++ b/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt @@ -1,29 +1,26 @@ ---TEST-- -SPL: Spl Directory Iterator test getOwner ---CREDITS-- +--TEST-- +SPL: DirectoryIterator test getOwner +--CREDITS-- Cesare D'Amico Andrea Giorgini Filippo De Santis Daniel Londero Francesco Trucchia Jacopo Romei -#Test Fest Cesena (Italy) on 2009-06-20 ---SKIPIF-- - ---FILE-- -getOwner() == $result); - +#Test Fest Cesena (Italy) on 2009-06-20 +--FILE-- +getOwner(); +var_dump($expected == $actual); ?> --CLEAN-- ---EXPECTF-- +$dirname = basename(__FILE__, '.phpt'); +rmdir($dirname); +?> +--EXPECTF-- bool(true) diff --git a/ext/spl/tests/SplFileInfo_getGroup_basic.phpt b/ext/spl/tests/SplFileInfo_getGroup_basic.phpt index 7b0528d7d1714..c5808c57d9edf 100644 --- a/ext/spl/tests/SplFileInfo_getGroup_basic.phpt +++ b/ext/spl/tests/SplFileInfo_getGroup_basic.phpt @@ -1,30 +1,26 @@ ---TEST-- -SPL: Spl File Info test getGroup ---CREDITS-- +--TEST-- +SPL: SplFileInfo test getGroup +--CREDITS-- Cesare D'Amico Andrea Giorgini Filippo De Santis Daniel Londero Francesco Trucchia Jacopo Romei -#Test Fest Cesena (Italy) on 2009-06-20 ---SKIPIF-- - ---FILE-- -getGroup() == $result); - +#Test Fest Cesena (Italy) on 2009-06-20 +--FILE-- +getGroup(); +var_dump($expected == $actual); ?> --CLEAN-- ---EXPECTF-- +$filename = basename(__FILE__, 'phpt').'tmp'; +unlink($filename); +?> +--EXPECTF-- bool(true) diff --git a/ext/spl/tests/SplFileInfo_getOwner_basic.phpt b/ext/spl/tests/SplFileInfo_getOwner_basic.phpt index 50f79430c9e8c..790dcc69ba058 100644 --- a/ext/spl/tests/SplFileInfo_getOwner_basic.phpt +++ b/ext/spl/tests/SplFileInfo_getOwner_basic.phpt @@ -1,30 +1,26 @@ ---TEST-- -SPL: Spl File Info test getOwner ---CREDITS-- +--TEST-- +SPL: SplFileInfo test getOwner +--CREDITS-- Cesare D'Amico Andrea Giorgini Filippo De Santis Daniel Londero Francesco Trucchia Jacopo Romei -#Test Fest Cesena (Italy) on 2009-06-20 ---SKIPIF-- - ---FILE-- -getOwner() == $result); - +#Test Fest Cesena (Italy) on 2009-06-20 +--FILE-- +getOwner(); +var_dump($expected == $actual); ?> --CLEAN-- ---EXPECTF-- +$filename = basename(__FILE__, 'phpt').'tmp'; +unlink($filename); +?> +--EXPECTF-- bool(true) From 785a7a5056cab7d6c20a64e31e93e2b97b0ab72e Mon Sep 17 00:00:00 2001 From: Knut Urdalen Date: Sat, 25 Jun 2011 07:45:41 +0000 Subject: [PATCH 0227/2394] fixed temp directory names in spl tests --- ext/spl/tests/DirectoryIterator_getGroup_basic.phpt | 4 ++-- ext/spl/tests/DirectoryIterator_getOwner_basic.phpt | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt b/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt index 3573d85852f12..9cc9fadbeeaeb 100644 --- a/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt +++ b/ext/spl/tests/DirectoryIterator_getGroup_basic.phpt @@ -10,7 +10,7 @@ Jacopo Romei #Test Fest Cesena (Italy) on 2009-06-20 --FILE-- --CLEAN-- --EXPECTF-- diff --git a/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt b/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt index f02cb6e04e4a9..c5e9f7c2c643b 100644 --- a/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt +++ b/ext/spl/tests/DirectoryIterator_getOwner_basic.phpt @@ -10,7 +10,7 @@ Jacopo Romei #Test Fest Cesena (Italy) on 2009-06-20 --FILE-- --CLEAN-- --EXPECTF-- From 6b56f4a5b832961f2ac6b03a9e123d5ffd427cef Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Sat, 25 Jun 2011 10:16:46 +0000 Subject: [PATCH 0228/2394] - Fixed layout. Tabs on the terminal don't align nicely in most cases. --- sapi/cli/php_cli.c | 66 +++++++++++++++++++++++----------------------- 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 6b8113ad1747f..5932c7cf8b644 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -499,51 +499,51 @@ static void php_cli_usage(char *argv0) } printf( "Usage: %s [options] [-f] [--] [args...]\n" - " %s [options] -r [--] [args...]\n" - " %s [options] [-B ] -R [-E ] [--] [args...]\n" - " %s [options] [-B ] -F [-E ] [--] [args...]\n" - " %s [options] -- [args...]\n" - " %s [options] -a\n" + " %s [options] -r [--] [args...]\n" + " %s [options] [-B ] -R [-E ] [--] [args...]\n" + " %s [options] [-B ] -F [-E ] [--] [args...]\n" + " %s [options] -- [args...]\n" + " %s [options] -a\n" "\n" #if (HAVE_LIBREADLINE || HAVE_LIBEDIT) && !defined(COMPILE_DL_READLINE) - " -a Run as interactive shell\n" + " -a Run as interactive shell\n" #else - " -a Run interactively\n" + " -a Run interactively\n" #endif " -c | Look for php.ini file in this directory\n" - " -n No php.ini file will be used\n" - " -d foo[=bar] Define INI entry foo with value 'bar'\n" - " -e Generate extended information for debugger/profiler\n" - " -f Parse and execute .\n" - " -h This help\n" - " -i PHP information\n" - " -l Syntax check only (lint)\n" - " -m Show compiled in modules\n" - " -r Run PHP without using script tags \n" + " -n No php.ini file will be used\n" + " -d foo[=bar] Define INI entry foo with value 'bar'\n" + " -e Generate extended information for debugger/profiler\n" + " -f Parse and execute .\n" + " -h This help\n" + " -i PHP information\n" + " -l Syntax check only (lint)\n" + " -m Show compiled in modules\n" + " -r Run PHP without using script tags \n" " -B Run PHP before processing input lines\n" - " -R Run PHP for every input line\n" - " -F Parse and execute for every input line\n" - " -E Run PHP after processing all input lines\n" - " -H Hide any passed arguments from external tools.\n" + " -R Run PHP for every input line\n" + " -F Parse and execute for every input line\n" + " -E Run PHP after processing all input lines\n" + " -H Hide any passed arguments from external tools.\n" " -S : Run with built-in web server.\n" - " -t Specify document root for bult-in web server.\n" - " -s Output HTML syntax highlighted source.\n" - " -v Version number\n" - " -w Output source with stripped comments and whitespace.\n" - " -z Load Zend extension .\n" + " -t Specify document root for bult-in web server.\n" + " -s Output HTML syntax highlighted source.\n" + " -v Version number\n" + " -w Output source with stripped comments and whitespace.\n" + " -z Load Zend extension .\n" "\n" - " args... Arguments passed to script. Use -- args when first argument\n" - " starts with - or script is read from stdin\n" + " args... Arguments passed to script. Use -- args when first argument\n" + " starts with - or script is read from stdin\n" "\n" - " --ini Show configuration file names\n" + " --ini Show configuration file names\n" "\n" #if (HAVE_REFLECTION) - " --rf Show information about function .\n" - " --rc Show information about class .\n" - " --re Show information about extension .\n" - " --rz Show information about Zend extension .\n" + " --rf Show information about function .\n" + " --rc Show information about class .\n" + " --re Show information about extension .\n" + " --rz Show information about Zend extension .\n" #endif - " --ri Show configuration for extension .\n" + " --ri Show configuration for extension .\n" "\n" , prog, prog, prog, prog, prog, prog); } From eeade7180a50161e695d1f257b2d51fe73b34f4b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sat, 25 Jun 2011 10:47:54 +0000 Subject: [PATCH 0229/2394] - reflection is always enabled --- sapi/cli/php_cli.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 5932c7cf8b644..ced9753377da0 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -29,9 +29,7 @@ #include "zend_modules.h" #include "zend_interfaces.h" -#ifdef HAVE_REFLECTION #include "ext/reflection/php_reflection.h" -#endif #include "SAPI.h" @@ -158,7 +156,6 @@ const opt_struct OPTIONS[] = { {'?', 0, "usage"},/* help alias (both '?' and 'usage') */ {'v', 0, "version"}, {'z', 1, "zend-extension"}, -#ifdef HAVE_REFLECTION {10, 1, "rf"}, {10, 1, "rfunction"}, {11, 1, "rc"}, @@ -167,7 +164,6 @@ const opt_struct OPTIONS[] = { {12, 1, "rextension"}, {13, 1, "rz"}, {13, 1, "rzendextension"}, -#endif {14, 1, "ri"}, {14, 1, "rextinfo"}, {15, 0, "ini"}, @@ -537,12 +533,10 @@ static void php_cli_usage(char *argv0) "\n" " --ini Show configuration file names\n" "\n" -#if (HAVE_REFLECTION) " --rf Show information about function .\n" " --rc Show information about class .\n" " --re Show information about extension .\n" " --rz Show information about Zend extension .\n" -#endif " --ri Show configuration for extension .\n" "\n" , prog, prog, prog, prog, prog, prog); @@ -873,8 +867,6 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ case 'H': hide_argv = 1; break; - -#ifdef HAVE_REFLECTION case 10: behavior=PHP_MODE_REFLECTION_FUNCTION; reflection_what = php_optarg; @@ -891,7 +883,6 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ behavior=PHP_MODE_REFLECTION_ZEND_EXTENSION; reflection_what = php_optarg; break; -#endif case 14: behavior=PHP_MODE_REFLECTION_EXT_INFO; reflection_what = php_optarg; @@ -1083,7 +1074,6 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ break; } -#ifdef HAVE_REFLECTION case PHP_MODE_REFLECTION_FUNCTION: case PHP_MODE_REFLECTION_CLASS: case PHP_MODE_REFLECTION_EXTENSION: @@ -1138,7 +1128,6 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ break; } -#endif /* reflection */ case PHP_MODE_REFLECTION_EXT_INFO: { int len = strlen(reflection_what); From 9424d255c96307de3f254d3602a9ab6e35f01156 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 25 Jun 2011 13:15:24 +0000 Subject: [PATCH 0230/2394] - Fixed crash when zend_eval_string bailouts (-r 'a();') Reported by: David Tajchreber --- sapi/cli/php_cli.c | 811 +++++++++++++++++++++++---------------------- 1 file changed, 407 insertions(+), 404 deletions(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index ced9753377da0..cdce8364455e3 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -668,495 +668,498 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ const char *param_error=NULL; int hide_argv = 0; - CG(in_compilation) = 0; /* not initialized but needed for several options */ - EG(uninitialized_zval_ptr) = NULL; + zend_try { + + CG(in_compilation) = 0; /* not initialized but needed for several options */ + EG(uninitialized_zval_ptr) = NULL; - while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { - switch (c) { + while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { + switch (c) { - case 'i': /* php info & quit */ - if (php_request_startup(TSRMLS_C)==FAILURE) { - goto err; - } - request_started = 1; - php_print_info(0xFFFFFFFF TSRMLS_CC); - php_output_end_all(TSRMLS_C); - exit_status = (c == '?' && argc > 1 && !strchr(argv[1], c)); - goto out; + case 'i': /* php info & quit */ + if (php_request_startup(TSRMLS_C)==FAILURE) { + goto err; + } + request_started = 1; + php_print_info(0xFFFFFFFF TSRMLS_CC); + php_output_end_all(TSRMLS_C); + exit_status = (c == '?' && argc > 1 && !strchr(argv[1], c)); + goto out; - case 'v': /* show php version & quit */ - php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2011 The PHP Group\n%s", - PHP_VERSION, cli_sapi_module.name, __DATE__, __TIME__, + case 'v': /* show php version & quit */ + php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2011 The PHP Group\n%s", + PHP_VERSION, cli_sapi_module.name, __DATE__, __TIME__, #if ZEND_DEBUG && defined(HAVE_GCOV) - "(DEBUG GCOV)", + "(DEBUG GCOV)", #elif ZEND_DEBUG - "(DEBUG)", + "(DEBUG)", #elif defined(HAVE_GCOV) - "(GCOV)", + "(GCOV)", #else - "", + "", #endif - get_zend_version() - ); - sapi_deactivate(TSRMLS_C); - goto out; + get_zend_version() + ); + sapi_deactivate(TSRMLS_C); + goto out; - case 'm': /* list compiled in modules */ - if (php_request_startup(TSRMLS_C)==FAILURE) { - goto err; - } - request_started = 1; - php_printf("[PHP Modules]\n"); - print_modules(TSRMLS_C); - php_printf("\n[Zend Modules]\n"); - print_extensions(TSRMLS_C); - php_printf("\n"); - php_output_end_all(TSRMLS_C); - exit_status=0; - goto out; + case 'm': /* list compiled in modules */ + if (php_request_startup(TSRMLS_C)==FAILURE) { + goto err; + } + request_started = 1; + php_printf("[PHP Modules]\n"); + print_modules(TSRMLS_C); + php_printf("\n[Zend Modules]\n"); + print_extensions(TSRMLS_C); + php_printf("\n"); + php_output_end_all(TSRMLS_C); + exit_status=0; + goto out; - default: - break; + default: + break; + } } - } - /* Set some CLI defaults */ - SG(options) |= SAPI_OPTION_NO_CHDIR; + /* Set some CLI defaults */ + SG(options) |= SAPI_OPTION_NO_CHDIR; - php_optind = orig_optind; - php_optarg = orig_optarg; - while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { - switch (c) { + php_optind = orig_optind; + php_optarg = orig_optarg; + while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2)) != -1) { + switch (c) { - case 'a': /* interactive mode */ - if (!interactive) { - if (behavior != PHP_MODE_STANDARD) { - param_error = param_mode_conflict; - break; - } + case 'a': /* interactive mode */ + if (!interactive) { + if (behavior != PHP_MODE_STANDARD) { + param_error = param_mode_conflict; + break; + } - interactive=1; - } - break; + interactive=1; + } + break; - case 'C': /* don't chdir to the script directory */ - /* This is default so NOP */ - break; + case 'C': /* don't chdir to the script directory */ + /* This is default so NOP */ + break; - case 'F': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_run || script_file) { - param_error = "You can use -R or -F only once.\n"; + case 'F': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_run || script_file) { + param_error = "You can use -R or -F only once.\n"; + break; + } + } else if (behavior != PHP_MODE_STANDARD) { + param_error = param_mode_conflict; break; } - } else if (behavior != PHP_MODE_STANDARD) { - param_error = param_mode_conflict; + behavior=PHP_MODE_PROCESS_STDIN; + script_file = php_optarg; break; - } - behavior=PHP_MODE_PROCESS_STDIN; - script_file = php_optarg; - break; - case 'f': /* parse file */ - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = param_mode_conflict; - break; - } else if (script_file) { - param_error = "You can use -f only once.\n"; + case 'f': /* parse file */ + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = param_mode_conflict; + break; + } else if (script_file) { + param_error = "You can use -f only once.\n"; + break; + } + script_file = php_optarg; break; - } - script_file = php_optarg; - break; - case 'l': /* syntax check mode */ - if (behavior != PHP_MODE_STANDARD) { + case 'l': /* syntax check mode */ + if (behavior != PHP_MODE_STANDARD) { + break; + } + behavior=PHP_MODE_LINT; break; - } - behavior=PHP_MODE_LINT; - break; #if 0 /* not yet operational, see also below ... */ - case '': /* generate indented source mode*/ - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = "Source indenting only works for files.\n"; + case '': /* generate indented source mode*/ + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = "Source indenting only works for files.\n"; + break; + } + behavior=PHP_MODE_INDENT; break; - } - behavior=PHP_MODE_INDENT; - break; #endif - case 'q': /* do not generate HTTP headers */ - /* This is default so NOP */ - break; + case 'q': /* do not generate HTTP headers */ + /* This is default so NOP */ + break; - case 'r': /* run code from command line */ - if (behavior == PHP_MODE_CLI_DIRECT) { - if (exec_direct || script_file) { - param_error = "You can use -r only once.\n"; + case 'r': /* run code from command line */ + if (behavior == PHP_MODE_CLI_DIRECT) { + if (exec_direct || script_file) { + param_error = "You can use -r only once.\n"; + break; + } + } else if (behavior != PHP_MODE_STANDARD || interactive) { + param_error = param_mode_conflict; break; } - } else if (behavior != PHP_MODE_STANDARD || interactive) { - param_error = param_mode_conflict; + behavior=PHP_MODE_CLI_DIRECT; + exec_direct=php_optarg; break; - } - behavior=PHP_MODE_CLI_DIRECT; - exec_direct=php_optarg; - break; - - case 'R': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_run || script_file) { - param_error = "You can use -R or -F only once.\n"; + + case 'R': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_run || script_file) { + param_error = "You can use -R or -F only once.\n"; + break; + } + } else if (behavior != PHP_MODE_STANDARD) { + param_error = param_mode_conflict; break; } - } else if (behavior != PHP_MODE_STANDARD) { - param_error = param_mode_conflict; + behavior=PHP_MODE_PROCESS_STDIN; + exec_run=php_optarg; break; - } - behavior=PHP_MODE_PROCESS_STDIN; - exec_run=php_optarg; - break; - case 'B': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_begin) { - param_error = "You can use -B only once.\n"; + case 'B': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_begin) { + param_error = "You can use -B only once.\n"; + break; + } + } else if (behavior != PHP_MODE_STANDARD || interactive) { + param_error = param_mode_conflict; break; } - } else if (behavior != PHP_MODE_STANDARD || interactive) { - param_error = param_mode_conflict; + behavior=PHP_MODE_PROCESS_STDIN; + exec_begin=php_optarg; break; - } - behavior=PHP_MODE_PROCESS_STDIN; - exec_begin=php_optarg; - break; - case 'E': - if (behavior == PHP_MODE_PROCESS_STDIN) { - if (exec_end) { - param_error = "You can use -E only once.\n"; + case 'E': + if (behavior == PHP_MODE_PROCESS_STDIN) { + if (exec_end) { + param_error = "You can use -E only once.\n"; + break; + } + } else if (behavior != PHP_MODE_STANDARD || interactive) { + param_error = param_mode_conflict; break; } - } else if (behavior != PHP_MODE_STANDARD || interactive) { - param_error = param_mode_conflict; + behavior=PHP_MODE_PROCESS_STDIN; + exec_end=php_optarg; break; - } - behavior=PHP_MODE_PROCESS_STDIN; - exec_end=php_optarg; - break; - case 's': /* generate highlighted HTML from source */ - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = "Source highlighting only works for files.\n"; + case 's': /* generate highlighted HTML from source */ + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = "Source highlighting only works for files.\n"; + break; + } + behavior=PHP_MODE_HIGHLIGHT; break; - } - behavior=PHP_MODE_HIGHLIGHT; - break; - case 'w': - if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { - param_error = "Source stripping only works for files.\n"; + case 'w': + if (behavior == PHP_MODE_CLI_DIRECT || behavior == PHP_MODE_PROCESS_STDIN) { + param_error = "Source stripping only works for files.\n"; + break; + } + behavior=PHP_MODE_STRIP; break; - } - behavior=PHP_MODE_STRIP; - break; - case 'z': /* load extension file */ - zend_load_extension(php_optarg); - break; - case 'H': - hide_argv = 1; - break; - case 10: - behavior=PHP_MODE_REFLECTION_FUNCTION; - reflection_what = php_optarg; - break; - case 11: - behavior=PHP_MODE_REFLECTION_CLASS; - reflection_what = php_optarg; - break; - case 12: - behavior=PHP_MODE_REFLECTION_EXTENSION; - reflection_what = php_optarg; - break; - case 13: - behavior=PHP_MODE_REFLECTION_ZEND_EXTENSION; - reflection_what = php_optarg; - break; - case 14: - behavior=PHP_MODE_REFLECTION_EXT_INFO; - reflection_what = php_optarg; - break; - case 15: - behavior = PHP_MODE_SHOW_INI_CONFIG; - break; - default: - break; + case 'z': /* load extension file */ + zend_load_extension(php_optarg); + break; + case 'H': + hide_argv = 1; + break; + case 10: + behavior=PHP_MODE_REFLECTION_FUNCTION; + reflection_what = php_optarg; + break; + case 11: + behavior=PHP_MODE_REFLECTION_CLASS; + reflection_what = php_optarg; + break; + case 12: + behavior=PHP_MODE_REFLECTION_EXTENSION; + reflection_what = php_optarg; + break; + case 13: + behavior=PHP_MODE_REFLECTION_ZEND_EXTENSION; + reflection_what = php_optarg; + break; + case 14: + behavior=PHP_MODE_REFLECTION_EXT_INFO; + reflection_what = php_optarg; + break; + case 15: + behavior = PHP_MODE_SHOW_INI_CONFIG; + break; + default: + break; + } } - } - if (param_error) { - PUTS(param_error); - exit_status=1; - goto err; - } + if (param_error) { + PUTS(param_error); + exit_status=1; + goto err; + } - if (interactive) { + if (interactive) { #if (HAVE_LIBREADLINE || HAVE_LIBEDIT) && !defined(COMPILE_DL_READLINE) - printf("Interactive shell\n\n"); + printf("Interactive shell\n\n"); #else - printf("Interactive mode enabled\n\n"); + printf("Interactive mode enabled\n\n"); #endif - fflush(stdout); - } - - CG(interactive) = interactive; - - /* only set script_file if not set already and not in direct mode and not at end of parameter list */ - if (argc > php_optind - && !script_file - && behavior!=PHP_MODE_CLI_DIRECT - && behavior!=PHP_MODE_PROCESS_STDIN - && strcmp(argv[php_optind-1],"--")) - { - script_file=argv[php_optind]; - php_optind++; - } - if (script_file) { - if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { - goto err; + fflush(stdout); } - script_filename = script_file; - } else { - /* We could handle PHP_MODE_PROCESS_STDIN in a different manner */ - /* here but this would make things only more complicated. And it */ - /* is consitent with the way -R works where the stdin file handle*/ - /* is also accessible. */ - file_handle.filename = "-"; - file_handle.handle.fp = stdin; - } - file_handle.type = ZEND_HANDLE_FP; - file_handle.opened_path = NULL; - file_handle.free_filename = 0; - php_self = file_handle.filename; - - /* before registering argv to module exchange the *new* argv[0] */ - /* we can achieve this without allocating more memory */ - SG(request_info).argc=argc-php_optind+1; - arg_excp = argv+php_optind-1; - arg_free = argv[php_optind-1]; - SG(request_info).path_translated = file_handle.filename; - argv[php_optind-1] = file_handle.filename; - SG(request_info).argv=argv+php_optind-1; - - if (php_request_startup(TSRMLS_C)==FAILURE) { - *arg_excp = arg_free; - fclose(file_handle.handle.fp); - PUTS("Could not startup.\n"); - goto err; - } - request_started = 1; - CG(start_lineno) = lineno; - *arg_excp = arg_free; /* reconstuct argv */ - - if (hide_argv) { - int i; - for (i = 1; i < argc; i++) { - memset(argv[i], 0, strlen(argv[i])); - } - } - zend_is_auto_global("_SERVER", sizeof("_SERVER")-1 TSRMLS_CC); + CG(interactive) = interactive; - PG(during_request_startup) = 0; - switch (behavior) { - case PHP_MODE_STANDARD: - if (strcmp(file_handle.filename, "-")) { - cli_register_file_handles(TSRMLS_C); + /* only set script_file if not set already and not in direct mode and not at end of parameter list */ + if (argc > php_optind + && !script_file + && behavior!=PHP_MODE_CLI_DIRECT + && behavior!=PHP_MODE_PROCESS_STDIN + && strcmp(argv[php_optind-1],"--")) + { + script_file=argv[php_optind]; + php_optind++; } - - if (interactive && cli_shell_callbacks.cli_shell_run) { - exit_status = cli_shell_callbacks.cli_shell_run(TSRMLS_C); + if (script_file) { + if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { + goto err; + } + script_filename = script_file; } else { - php_execute_script(&file_handle TSRMLS_CC); - exit_status = EG(exit_status); + /* We could handle PHP_MODE_PROCESS_STDIN in a different manner */ + /* here but this would make things only more complicated. And it */ + /* is consitent with the way -R works where the stdin file handle*/ + /* is also accessible. */ + file_handle.filename = "-"; + file_handle.handle.fp = stdin; } - break; - case PHP_MODE_LINT: - exit_status = php_lint_script(&file_handle TSRMLS_CC); - if (exit_status==SUCCESS) { - zend_printf("No syntax errors detected in %s\n", file_handle.filename); - } else { - zend_printf("Errors parsing %s\n", file_handle.filename); + file_handle.type = ZEND_HANDLE_FP; + file_handle.opened_path = NULL; + file_handle.free_filename = 0; + php_self = file_handle.filename; + + /* before registering argv to module exchange the *new* argv[0] */ + /* we can achieve this without allocating more memory */ + SG(request_info).argc=argc-php_optind+1; + arg_excp = argv+php_optind-1; + arg_free = argv[php_optind-1]; + SG(request_info).path_translated = file_handle.filename; + argv[php_optind-1] = file_handle.filename; + SG(request_info).argv=argv+php_optind-1; + + if (php_request_startup(TSRMLS_C)==FAILURE) { + *arg_excp = arg_free; + fclose(file_handle.handle.fp); + PUTS("Could not startup.\n"); + goto err; } - break; - case PHP_MODE_STRIP: - if (open_file_for_scanning(&file_handle TSRMLS_CC)==SUCCESS) { - zend_strip(TSRMLS_C); + request_started = 1; + CG(start_lineno) = lineno; + *arg_excp = arg_free; /* reconstuct argv */ + + if (hide_argv) { + int i; + for (i = 1; i < argc; i++) { + memset(argv[i], 0, strlen(argv[i])); + } } - goto out; - break; - case PHP_MODE_HIGHLIGHT: - { - zend_syntax_highlighter_ini syntax_highlighter_ini; + zend_is_auto_global("_SERVER", sizeof("_SERVER")-1 TSRMLS_CC); + + PG(during_request_startup) = 0; + switch (behavior) { + case PHP_MODE_STANDARD: + if (strcmp(file_handle.filename, "-")) { + cli_register_file_handles(TSRMLS_C); + } + + if (interactive && cli_shell_callbacks.cli_shell_run) { + exit_status = cli_shell_callbacks.cli_shell_run(TSRMLS_C); + } else { + php_execute_script(&file_handle TSRMLS_CC); + exit_status = EG(exit_status); + } + break; + case PHP_MODE_LINT: + exit_status = php_lint_script(&file_handle TSRMLS_CC); + if (exit_status==SUCCESS) { + zend_printf("No syntax errors detected in %s\n", file_handle.filename); + } else { + zend_printf("Errors parsing %s\n", file_handle.filename); + } + break; + case PHP_MODE_STRIP: if (open_file_for_scanning(&file_handle TSRMLS_CC)==SUCCESS) { - php_get_highlight_struct(&syntax_highlighter_ini); - zend_highlight(&syntax_highlighter_ini TSRMLS_CC); + zend_strip(TSRMLS_C); } goto out; - } - break; -#if 0 - /* Zeev might want to do something with this one day */ - case PHP_MODE_INDENT: - open_file_for_scanning(&file_handle TSRMLS_CC); - zend_indent(); - zend_file_handle_dtor(file_handle.handle TSRMLS_CC); - goto out; - break; -#endif - case PHP_MODE_CLI_DIRECT: - cli_register_file_handles(TSRMLS_C); - if (zend_eval_string_ex(exec_direct, NULL, "Command line code", 1 TSRMLS_CC) == FAILURE) { - exit_status=254; - } - break; - - case PHP_MODE_PROCESS_STDIN: - { - char *input; - size_t len, index = 0; - zval *argn, *argi; - - cli_register_file_handles(TSRMLS_C); + break; + case PHP_MODE_HIGHLIGHT: + { + zend_syntax_highlighter_ini syntax_highlighter_ini; - if (exec_begin && zend_eval_string_ex(exec_begin, NULL, "Command line begin code", 1 TSRMLS_CC) == FAILURE) { - exit_status=254; - } - ALLOC_ZVAL(argi); - Z_TYPE_P(argi) = IS_LONG; - Z_LVAL_P(argi) = index; - INIT_PZVAL(argi); - zend_hash_update(&EG(symbol_table), "argi", sizeof("argi"), &argi, sizeof(zval *), NULL); - while (exit_status == SUCCESS && (input=php_stream_gets(s_in_process, NULL, 0)) != NULL) { - len = strlen(input); - while (len-- && (input[len]=='\n' || input[len]=='\r')) { - input[len] = '\0'; + if (open_file_for_scanning(&file_handle TSRMLS_CC)==SUCCESS) { + php_get_highlight_struct(&syntax_highlighter_ini); + zend_highlight(&syntax_highlighter_ini TSRMLS_CC); } - ALLOC_ZVAL(argn); - Z_TYPE_P(argn) = IS_STRING; - Z_STRLEN_P(argn) = ++len; - Z_STRVAL_P(argn) = estrndup(input, len); - INIT_PZVAL(argn); - zend_hash_update(&EG(symbol_table), "argn", sizeof("argn"), &argn, sizeof(zval *), NULL); - Z_LVAL_P(argi) = ++index; - if (exec_run) { - if (zend_eval_string_ex(exec_run, NULL, "Command line run code", 1 TSRMLS_CC) == FAILURE) { - exit_status=254; - } - } else { - if (script_file) { - if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { - exit_status = 1; - } else { - CG(start_lineno) = lineno; - php_execute_script(&file_handle TSRMLS_CC); - exit_status = EG(exit_status); - } - } - } - efree(input); + goto out; } - if (exec_end && zend_eval_string_ex(exec_end, NULL, "Command line end code", 1 TSRMLS_CC) == FAILURE) { + break; +#if 0 + /* Zeev might want to do something with this one day */ + case PHP_MODE_INDENT: + open_file_for_scanning(&file_handle TSRMLS_CC); + zend_indent(); + zend_file_handle_dtor(file_handle.handle TSRMLS_CC); + goto out; + break; +#endif + case PHP_MODE_CLI_DIRECT: + cli_register_file_handles(TSRMLS_C); + if (zend_eval_string_ex(exec_direct, NULL, "Command line code", 1 TSRMLS_CC) == FAILURE) { exit_status=254; } - break; - } - case PHP_MODE_REFLECTION_FUNCTION: - case PHP_MODE_REFLECTION_CLASS: - case PHP_MODE_REFLECTION_EXTENSION: - case PHP_MODE_REFLECTION_ZEND_EXTENSION: + + case PHP_MODE_PROCESS_STDIN: { - zend_class_entry *pce = NULL; - zval *arg, *ref; - zend_execute_data execute_data; + char *input; + size_t len, index = 0; + zval *argn, *argi; - switch (behavior) { - default: - break; - case PHP_MODE_REFLECTION_FUNCTION: - if (strstr(reflection_what, "::")) { - pce = reflection_method_ptr; - } else { - pce = reflection_function_ptr; + cli_register_file_handles(TSRMLS_C); + + if (exec_begin && zend_eval_string_ex(exec_begin, NULL, "Command line begin code", 1 TSRMLS_CC) == FAILURE) { + exit_status=254; + } + ALLOC_ZVAL(argi); + Z_TYPE_P(argi) = IS_LONG; + Z_LVAL_P(argi) = index; + INIT_PZVAL(argi); + zend_hash_update(&EG(symbol_table), "argi", sizeof("argi"), &argi, sizeof(zval *), NULL); + while (exit_status == SUCCESS && (input=php_stream_gets(s_in_process, NULL, 0)) != NULL) { + len = strlen(input); + while (len-- && (input[len]=='\n' || input[len]=='\r')) { + input[len] = '\0'; + } + ALLOC_ZVAL(argn); + Z_TYPE_P(argn) = IS_STRING; + Z_STRLEN_P(argn) = ++len; + Z_STRVAL_P(argn) = estrndup(input, len); + INIT_PZVAL(argn); + zend_hash_update(&EG(symbol_table), "argn", sizeof("argn"), &argn, sizeof(zval *), NULL); + Z_LVAL_P(argi) = ++index; + if (exec_run) { + if (zend_eval_string_ex(exec_run, NULL, "Command line run code", 1 TSRMLS_CC) == FAILURE) { + exit_status=254; } - break; - case PHP_MODE_REFLECTION_CLASS: - pce = reflection_class_ptr; - break; - case PHP_MODE_REFLECTION_EXTENSION: - pce = reflection_extension_ptr; - break; - case PHP_MODE_REFLECTION_ZEND_EXTENSION: - pce = reflection_zend_extension_ptr; - break; + } else { + if (script_file) { + if (cli_seek_file_begin(&file_handle, script_file, &lineno TSRMLS_CC) != SUCCESS) { + exit_status = 1; + } else { + CG(start_lineno) = lineno; + php_execute_script(&file_handle TSRMLS_CC); + exit_status = EG(exit_status); + } + } + } + efree(input); } - - MAKE_STD_ZVAL(arg); - ZVAL_STRING(arg, reflection_what, 1); - ALLOC_ZVAL(ref); - object_init_ex(ref, pce); - INIT_PZVAL(ref); - - memset(&execute_data, 0, sizeof(zend_execute_data)); - EG(current_execute_data) = &execute_data; - EX(function_state).function = pce->constructor; - zend_call_method_with_1_params(&ref, pce, &pce->constructor, "__construct", NULL, arg); - - if (EG(exception)) { - zval *msg = zend_read_property(zend_exception_get_default(TSRMLS_C), EG(exception), "message", sizeof("message")-1, 0 TSRMLS_CC); - zend_printf("Exception: %s\n", Z_STRVAL_P(msg)); - zval_ptr_dtor(&EG(exception)); - EG(exception) = NULL; - } else { - zend_call_method_with_1_params(NULL, reflection_ptr, NULL, "export", NULL, ref); + if (exec_end && zend_eval_string_ex(exec_end, NULL, "Command line end code", 1 TSRMLS_CC) == FAILURE) { + exit_status=254; } - zval_ptr_dtor(&ref); - zval_ptr_dtor(&arg); break; } - case PHP_MODE_REFLECTION_EXT_INFO: - { - int len = strlen(reflection_what); - char *lcname = zend_str_tolower_dup(reflection_what, len); - zend_module_entry *module; + case PHP_MODE_REFLECTION_FUNCTION: + case PHP_MODE_REFLECTION_CLASS: + case PHP_MODE_REFLECTION_EXTENSION: + case PHP_MODE_REFLECTION_ZEND_EXTENSION: + { + zend_class_entry *pce = NULL; + zval *arg, *ref; + zend_execute_data execute_data; + + switch (behavior) { + default: + break; + case PHP_MODE_REFLECTION_FUNCTION: + if (strstr(reflection_what, "::")) { + pce = reflection_method_ptr; + } else { + pce = reflection_function_ptr; + } + break; + case PHP_MODE_REFLECTION_CLASS: + pce = reflection_class_ptr; + break; + case PHP_MODE_REFLECTION_EXTENSION: + pce = reflection_extension_ptr; + break; + case PHP_MODE_REFLECTION_ZEND_EXTENSION: + pce = reflection_zend_extension_ptr; + break; + } + + MAKE_STD_ZVAL(arg); + ZVAL_STRING(arg, reflection_what, 1); + ALLOC_ZVAL(ref); + object_init_ex(ref, pce); + INIT_PZVAL(ref); + + memset(&execute_data, 0, sizeof(zend_execute_data)); + EG(current_execute_data) = &execute_data; + EX(function_state).function = pce->constructor; + zend_call_method_with_1_params(&ref, pce, &pce->constructor, "__construct", NULL, arg); + + if (EG(exception)) { + zval *msg = zend_read_property(zend_exception_get_default(TSRMLS_C), EG(exception), "message", sizeof("message")-1, 0 TSRMLS_CC); + zend_printf("Exception: %s\n", Z_STRVAL_P(msg)); + zval_ptr_dtor(&EG(exception)); + EG(exception) = NULL; + } else { + zend_call_method_with_1_params(NULL, reflection_ptr, NULL, "export", NULL, ref); + } + zval_ptr_dtor(&ref); + zval_ptr_dtor(&arg); - if (zend_hash_find(&module_registry, lcname, len+1, (void**)&module) == FAILURE) { - if (!strcmp(reflection_what, "main")) { - display_ini_entries(NULL); + break; + } + case PHP_MODE_REFLECTION_EXT_INFO: + { + int len = strlen(reflection_what); + char *lcname = zend_str_tolower_dup(reflection_what, len); + zend_module_entry *module; + + if (zend_hash_find(&module_registry, lcname, len+1, (void**)&module) == FAILURE) { + if (!strcmp(reflection_what, "main")) { + display_ini_entries(NULL); + } else { + zend_printf("Extension '%s' not present.\n", reflection_what); + exit_status = 1; + } } else { - zend_printf("Extension '%s' not present.\n", reflection_what); - exit_status = 1; + php_info_print_module(module TSRMLS_CC); } - } else { - php_info_print_module(module TSRMLS_CC); + + efree(lcname); + break; } - - efree(lcname); - break; - } - case PHP_MODE_SHOW_INI_CONFIG: - { - zend_printf("Configuration File (php.ini) Path: %s\n", PHP_CONFIG_FILE_PATH); - zend_printf("Loaded Configuration File: %s\n", php_ini_opened_path ? php_ini_opened_path : "(none)"); - zend_printf("Scan for additional .ini files in: %s\n", php_ini_scanned_path ? php_ini_scanned_path : "(none)"); - zend_printf("Additional .ini files parsed: %s\n", php_ini_scanned_files ? php_ini_scanned_files : "(none)"); - break; - } - } + case PHP_MODE_SHOW_INI_CONFIG: + { + zend_printf("Configuration File (php.ini) Path: %s\n", PHP_CONFIG_FILE_PATH); + zend_printf("Loaded Configuration File: %s\n", php_ini_opened_path ? php_ini_opened_path : "(none)"); + zend_printf("Scan for additional .ini files in: %s\n", php_ini_scanned_path ? php_ini_scanned_path : "(none)"); + zend_printf("Additional .ini files parsed: %s\n", php_ini_scanned_files ? php_ini_scanned_files : "(none)"); + break; + } + } + } zend_end_try(); out: if (exit_status == 0) { From 7b1f738b70ad148152d671f982aafda02528692b Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 25 Jun 2011 14:17:17 +0000 Subject: [PATCH 0231/2394] - Fixed crash when calling sapi_shutdown() and sapi hasn't been started Reported by: David Tajchreber --- sapi/cli/php_cli.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index cdce8364455e3..14ac439a86967 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -1194,7 +1194,7 @@ int main(int argc, char *argv[]) #endif int c; int exit_status = SUCCESS; - int module_started = 0; + int module_started = 0, sapi_started = 0; char *php_optarg = NULL; int php_optind = 1; char *ini_path_override = NULL; @@ -1312,6 +1312,7 @@ int main(int argc, char *argv[]) sapi_module->phpinfo_as_text = 1; sapi_module->php_ini_ignore_cwd = 1; sapi_startup(sapi_module); + sapi_started = 1; sapi_module->php_ini_ignore = ini_ignore; @@ -1364,7 +1365,9 @@ int main(int argc, char *argv[]) if (module_started) { php_module_shutdown(TSRMLS_C); } - sapi_shutdown(); + if (sapi_started) { + sapi_shutdown(); + } #ifdef ZTS tsrm_shutdown(); #endif From 8841454a10a54a9d3a61ab95e869b810eb729a16 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 25 Jun 2011 20:40:03 +0000 Subject: [PATCH 0232/2394] - Fixed crash when using -e option --- sapi/cli/php_cli.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 14ac439a86967..81a2d259593bb 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -1196,7 +1196,7 @@ int main(int argc, char *argv[]) int exit_status = SUCCESS; int module_started = 0, sapi_started = 0; char *php_optarg = NULL; - int php_optind = 1; + int php_optind = 1, use_extended_info = 0; char *ini_path_override = NULL; char *ini_entries = NULL; int ini_entries_len = 0; @@ -1301,7 +1301,7 @@ int main(int argc, char *argv[]) sapi_module = &cli_sapi_module; goto exit_loop; case 'e': /* enable extended info output */ - CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; + use_extended_info = 1; break; } } @@ -1343,6 +1343,11 @@ int main(int argc, char *argv[]) goto out; } module_started = 1; + + /* -e option */ + if (use_extended_info) { + CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; + } zend_first_try { #ifndef PHP_CLI_WIN32_NO_CONSOLE From 27934faf973f3099690290e6e5fc009f60b63c76 Mon Sep 17 00:00:00 2001 From: Knut Urdalen Date: Sat, 25 Jun 2011 21:22:42 +0000 Subject: [PATCH 0233/2394] small fix in disk_total_space() tests (PHP_5_3 already includes this) --- ext/standard/tests/file/disk_total_space_variation.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/file/disk_total_space_variation.phpt b/ext/standard/tests/file/disk_total_space_variation.phpt index 78f1932e3a816..ba2ceb2d1b96a 100644 --- a/ext/standard/tests/file/disk_total_space_variation.phpt +++ b/ext/standard/tests/file/disk_total_space_variation.phpt @@ -118,6 +118,6 @@ NULL Warning: disk_total_space() expects parameter 1 to be a valid path, string given in %s on line %d NULL *** Testing with Binary Input *** -float(64246190080) +float(%d) --- Done --- From dace636cc984260f51e6b03df476f8cc81a81969 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sun, 26 Jun 2011 15:48:11 +0000 Subject: [PATCH 0234/2394] - Replaced shm_slots with a real scoreboard - Added several improvements to the status page --- sapi/fpm/config.m4 | 2 +- sapi/fpm/fpm/fpm.c | 2 + sapi/fpm/fpm/fpm_atomic.h | 6 +- sapi/fpm/fpm/fpm_children.c | 19 ++- sapi/fpm/fpm/fpm_children.h | 1 + sapi/fpm/fpm/fpm_conf.c | 10 -- sapi/fpm/fpm/fpm_log.c | 63 +++---- sapi/fpm/fpm/fpm_main.c | 6 - sapi/fpm/fpm/fpm_process_ctl.c | 32 +++- sapi/fpm/fpm/fpm_request.c | 212 +++++++++++++++-------- sapi/fpm/fpm/fpm_scoreboard.c | 301 +++++++++++++++++++++++++++++++++ sapi/fpm/fpm/fpm_scoreboard.h | 84 +++++++++ sapi/fpm/fpm/fpm_shm.c | 92 +++------- sapi/fpm/fpm/fpm_shm.h | 15 +- sapi/fpm/fpm/fpm_shm_slots.c | 119 ------------- sapi/fpm/fpm/fpm_shm_slots.h | 57 ------- sapi/fpm/fpm/fpm_sockets.c | 30 ++-- sapi/fpm/fpm/fpm_sockets.h | 2 +- sapi/fpm/fpm/fpm_status.c | 234 +++++++++---------------- sapi/fpm/fpm/fpm_worker_pool.c | 14 +- sapi/fpm/fpm/fpm_worker_pool.h | 11 +- 21 files changed, 729 insertions(+), 583 deletions(-) create mode 100644 sapi/fpm/fpm/fpm_scoreboard.c create mode 100644 sapi/fpm/fpm/fpm_scoreboard.h delete mode 100644 sapi/fpm/fpm/fpm_shm_slots.c delete mode 100644 sapi/fpm/fpm/fpm_shm_slots.h diff --git a/sapi/fpm/config.m4 b/sapi/fpm/config.m4 index 751f866bb2955..6cdfeb7391011 100644 --- a/sapi/fpm/config.m4 +++ b/sapi/fpm/config.m4 @@ -438,7 +438,7 @@ if test "$PHP_FPM" != "no"; then fpm/fpm_process_ctl.c \ fpm/fpm_request.c \ fpm/fpm_shm.c \ - fpm/fpm_shm_slots.c \ + fpm/fpm_scoreboard.c \ fpm/fpm_signals.c \ fpm/fpm_sockets.c \ fpm/fpm_status.c \ diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index f80f943910664..b0b3b2b7a4cdd 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -18,6 +18,7 @@ #include "fpm_process_ctl.h" #include "fpm_conf.h" #include "fpm_worker_pool.h" +#include "fpm_scoreboard.h" #include "fpm_stdio.h" #include "fpm_log.h" #include "zlog.h" @@ -51,6 +52,7 @@ int fpm_init(int argc, char **argv, char *config, char *prefix, int test_conf) / 0 > fpm_log_init_main() || 0 > fpm_conf_init_main(test_conf) || 0 > fpm_unix_init_main() || + 0 > fpm_scoreboard_init_main() || 0 > fpm_pctl_init_main() || 0 > fpm_env_init_main() || 0 > fpm_signals_init_main() || diff --git a/sapi/fpm/fpm/fpm_atomic.h b/sapi/fpm/fpm/fpm_atomic.h index 638bafddc889d..662dd4726d522 100644 --- a/sapi/fpm/fpm/fpm_atomic.h +++ b/sapi/fpm/fpm/fpm_atomic.h @@ -146,7 +146,7 @@ static inline atomic_uint_t atomic_cmp_set(atomic_t *lock, atomic_uint_t old, at static inline int fpm_spinlock(atomic_t *lock, int try_once) /* {{{ */ { if (try_once) { - return atomic_cmp_set(lock, 0, 1) ? 0 : -1; + return atomic_cmp_set(lock, 0, 1) ? 1 : 0; } for (;;) { @@ -158,9 +158,11 @@ static inline int fpm_spinlock(atomic_t *lock, int try_once) /* {{{ */ sched_yield(); } - return 0; + return 1; } /* }}} */ +#define fpm_unlock(lock) lock = 0 + #endif diff --git a/sapi/fpm/fpm/fpm_children.c b/sapi/fpm/fpm/fpm_children.c index d8338725e48c9..05d741cb89b7c 100644 --- a/sapi/fpm/fpm/fpm_children.c +++ b/sapi/fpm/fpm/fpm_children.c @@ -25,7 +25,7 @@ #include "fpm_stdio.h" #include "fpm_unix.h" #include "fpm_env.h" -#include "fpm_shm_slots.h" +#include "fpm_scoreboard.h" #include "fpm_status.h" #include "fpm_log.h" @@ -51,6 +51,7 @@ static struct fpm_child_s *fpm_child_alloc() /* {{{ */ } memset(ret, 0, sizeof(*ret)); + ret->scoreboard_i = -1; return ret; } /* }}} */ @@ -238,7 +239,7 @@ void fpm_children_bury() /* {{{ */ fpm_child_unlink(child); - fpm_shm_slots_discard_slot(child); + fpm_scoreboard_proc_free(wp->scoreboard, child->scoreboard_i); fpm_clock_get(&tv1); @@ -316,7 +317,7 @@ static struct fpm_child_s *fpm_resources_prepare(struct fpm_worker_pool_s *wp) / return 0; } - if (0 > fpm_shm_slots_prepare_slot(c)) { + if (0 > fpm_scoreboard_proc_alloc(wp->scoreboard, &c->scoreboard_i)) { fpm_stdio_discard_pipes(c); fpm_child_free(c); return 0; @@ -328,7 +329,7 @@ static struct fpm_child_s *fpm_resources_prepare(struct fpm_worker_pool_s *wp) / static void fpm_resources_discard(struct fpm_child_s *child) /* {{{ */ { - fpm_shm_slots_discard_slot(child); + fpm_scoreboard_proc_free(child->wp->scoreboard, child->scoreboard_i); fpm_stdio_discard_pipes(child); fpm_child_free(child); } @@ -336,7 +337,14 @@ static void fpm_resources_discard(struct fpm_child_s *child) /* {{{ */ static void fpm_child_resources_use(struct fpm_child_s *child) /* {{{ */ { - fpm_shm_slots_child_use_slot(child); + struct fpm_worker_pool_s *wp; + for (wp = fpm_worker_all_pools; wp; wp = wp->next) { + if (wp == child->wp) { + continue; + } + fpm_scoreboard_free(wp->scoreboard); + } + fpm_scoreboard_child_use(child->wp->scoreboard, child->scoreboard_i, child->pid); fpm_stdio_child_use_pipes(child); fpm_child_free(child); } @@ -344,7 +352,6 @@ static void fpm_child_resources_use(struct fpm_child_s *child) /* {{{ */ static void fpm_parent_resources_use(struct fpm_child_s *child) /* {{{ */ { - fpm_shm_slots_parent_use_slot(child); fpm_stdio_parent_use_pipes(child); fpm_child_link(child); } diff --git a/sapi/fpm/fpm/fpm_children.h b/sapi/fpm/fpm/fpm_children.h index 4010a4f3b82c0..9c79f234e8f39 100644 --- a/sapi/fpm/fpm/fpm_children.h +++ b/sapi/fpm/fpm/fpm_children.h @@ -30,6 +30,7 @@ struct fpm_child_s { struct timeval slow_logged; int idle_kill; pid_t pid; + int scoreboard_i; }; #endif diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index f82806644fd3c..07d982393fc5d 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -656,16 +656,6 @@ static int fpm_conf_process_all_pools() /* {{{ */ return -1; } } - wp->shm_status = fpm_shm_alloc(sizeof(struct fpm_status_s)); - if (!wp->shm_status) { - zlog(ZLOG_ERROR, "[pool %s] unable to allocate shared memory for status page '%s'", wp->config->name, status); - return -1; - } - fpm_status_update_accepted_conn(wp->shm_status, 0); - fpm_status_update_activity(wp->shm_status, -1, -1, -1, 0, -1, 1); - fpm_status_update_max_children_reached(wp->shm_status, 0); - fpm_status_set_pm(wp->shm_status, wp->config->pm); - /* memset(&fpm_status.last_update, 0, sizeof(fpm_status.last_update)); */ } if (wp->config->access_log && *wp->config->access_log) { diff --git a/sapi/fpm/fpm/fpm_log.c b/sapi/fpm/fpm/fpm_log.c index 243ed867645f4..ef1c0c3be382c 100644 --- a/sapi/fpm/fpm/fpm_log.c +++ b/sapi/fpm/fpm/fpm_log.c @@ -17,7 +17,7 @@ #include "fpm_clock.h" #include "fpm_process_ctl.h" #include "fpm_signals.h" -#include "fpm_shm_slots.h" +#include "fpm_scoreboard.h" #include "fastcgi.h" #include "zlog.h" @@ -28,7 +28,6 @@ #endif static char *fpm_log_format = NULL; -static char *fpm_log_pool = NULL; static int fpm_log_fd = -1; #ifdef HAVE_TIMES static float tick; @@ -99,10 +98,6 @@ int fpm_log_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ } } - if (wp->config->name) { - fpm_log_pool = strdup(wp->config->name); - } - if (fpm_log_fd == -1) { fpm_log_fd = wp->log_fd; } @@ -125,8 +120,8 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ char buffer[FPM_LOG_BUFFER]; int token, test; size_t len, len2; -// fcgi_request *request = (fcgi_request*) SG(server_context); - struct fpm_shm_slot_s slot, *slot_p; + struct fpm_scoreboard_proc_s proc, *proc_p; + struct fpm_scoreboard_s *scoreboard; struct timeval uptime, now; char tmp[129]; char format[129]; @@ -148,16 +143,22 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ fpm_clock_get(&now); now_epoch = time(NULL); + if (!test) { - slot_p = fpm_shm_slots_acquire(0, 0); - if (!slot_p) { - zlog(ZLOG_WARNING, "Unable to acquire shm slot"); + scoreboard = fpm_scoreboard_get(); + if (!scoreboard) { + zlog(ZLOG_WARNING, "unable to get scoreboard"); + return -1; + } + proc_p = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (!proc_p) { + zlog(ZLOG_WARNING, "[pool %s] Unable to acquire shm slot", scoreboard->pool); return -1; } - slot = *slot_p; - fpm_shm_slots_release(slot_p); + proc = *proc_p; + fpm_scoreboard_proc_release(proc_p); - timersub(&now, &slot.accepted, &uptime); + timersub(&now, &proc.accepted, &uptime); } token = 0; @@ -198,18 +199,18 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ if (format[0] == '\0' || !strcasecmp(format, "total")) { if (!test) { tms_total = - (slot.cpu_finished.tms_utime + slot.cpu_finished.tms_stime + slot.cpu_finished.tms_cutime + slot.cpu_finished.tms_cstime) + (proc.cpu_finished.tms_utime + proc.cpu_finished.tms_stime + proc.cpu_finished.tms_cutime + proc.cpu_finished.tms_cstime) - - (slot.cpu_accepted.tms_utime + slot.cpu_accepted.tms_stime + slot.cpu_accepted.tms_cutime + slot.cpu_accepted.tms_cstime) + (proc.cpu_accepted.tms_utime + proc.cpu_accepted.tms_stime + proc.cpu_accepted.tms_cutime + proc.cpu_accepted.tms_cstime) ; } } else if (!strcasecmp(format, "user")) { if (!test) { - tms_total = (slot.cpu_finished.tms_utime + slot.cpu_finished.tms_cutime) - (slot.cpu_accepted.tms_utime + slot.cpu_accepted.tms_cutime); + tms_total = (proc.cpu_finished.tms_utime + proc.cpu_finished.tms_cutime) - (proc.cpu_accepted.tms_utime + proc.cpu_accepted.tms_cutime); } } else if (!strcasecmp(format, "system")) { if (!test) { - tms_total = (slot.cpu_finished.tms_stime + slot.cpu_finished.tms_cstime) - (slot.cpu_accepted.tms_stime + slot.cpu_accepted.tms_cstime); + tms_total = (proc.cpu_finished.tms_stime + proc.cpu_finished.tms_cstime) - (proc.cpu_accepted.tms_stime + proc.cpu_accepted.tms_cstime); } } else { zlog(ZLOG_WARNING, "only 'total', 'user' or 'system' are allowed as a modifier for %%%c ('%s')", *s, format); @@ -218,7 +219,7 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ format[0] = '\0'; if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.2f", tms_total / tick / (slot.cpu_duration.tv_sec + slot.cpu_duration.tv_usec / 1000000.) * 100.); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.2f", tms_total / tick / (proc.cpu_duration.tv_sec + proc.cpu_duration.tv_usec / 1000000.) * 100.); } break; #endif @@ -264,19 +265,19 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ case 'f': /* script */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.script_filename && *slot.script_filename ? slot.script_filename : "-"); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", proc.script_filename && *proc.script_filename ? proc.script_filename : "-"); } break; case 'l': /* content length */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%zu", slot.content_length); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%zu", proc.content_length); } break; case 'm': /* method */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.request_method && *slot.request_method ? slot.request_method : "-"); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", proc.request_method && *proc.request_method ? proc.request_method : "-"); } break; @@ -284,19 +285,19 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ /* seconds */ if (format[0] == '\0' || !strcasecmp(format, "bytes")) { if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%zu", slot.memory); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%zu", proc.memory); } /* kilobytes */ } else if (!strcasecmp(format, "kilobytes") || !strcasecmp(format, "kilo")) { if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", slot.memory / 1024); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", proc.memory / 1024); } /* megabytes */ } else if (!strcasecmp(format, "megabytes") || !strcasecmp(format, "mega")) { if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", slot.memory / 1024 / 1024); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", proc.memory / 1024 / 1024); } } else { @@ -308,7 +309,7 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ case 'n': /* pool name */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", fpm_log_pool ? fpm_log_pool : "-"); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", scoreboard->pool[0] ? scoreboard->pool : "-"); } break; @@ -374,19 +375,19 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ case 'q': /* query_string */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.query_string ? slot.query_string : ""); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", proc.query_string ? proc.query_string : ""); } break; case 'Q': /* '?' */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.query_string && *slot.query_string ? "?" : ""); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", proc.query_string && *proc.query_string ? "?" : ""); } break; case 'r': /* request URI */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.request_uri ? slot.request_uri : "-"); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", proc.request_uri ? proc.request_uri : "-"); } break; @@ -408,7 +409,7 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ if (!test) { time_t *t; if (*s == 't') { - t = &slot.accepted_epoch; + t = &proc.accepted_epoch; } else { t = &now_epoch; } @@ -424,7 +425,7 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ case 'u': /* remote user */ if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", slot.auth_user ? slot.auth_user : "-"); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%s", proc.auth_user ? proc.auth_user : "-"); } break; diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 37c932e5b4810..8946135ad1110 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1565,7 +1565,6 @@ static zend_module_entry cgi_module_entry = { */ int main(int argc, char *argv[]) { - int free_query_string = 0; int exit_status = SUCCESS; int cgi = 0, c; zend_file_handle file_handle; @@ -1918,11 +1917,6 @@ consult the installation file that came with this distribution, or visit \n\ exit_status = EG(exit_status); } - if (free_query_string && SG(request_info).query_string) { - free(SG(request_info).query_string); - SG(request_info).query_string = NULL; - } - requests++; if (max_requests && (requests == max_requests)) { fcgi_finish_request(&request, 1); diff --git a/sapi/fpm/fpm/fpm_process_ctl.c b/sapi/fpm/fpm/fpm_process_ctl.c index bd50c46c297f1..c297c2d44a69f 100644 --- a/sapi/fpm/fpm/fpm_process_ctl.c +++ b/sapi/fpm/fpm/fpm_process_ctl.c @@ -18,7 +18,7 @@ #include "fpm_cleanup.h" #include "fpm_request.h" #include "fpm_worker_pool.h" -#include "fpm_status.h" +#include "fpm_scoreboard.h" #include "fpm_sockets.h" #include "zlog.h" @@ -337,10 +337,24 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ } /* update status structure for all PMs */ - if (0 > fpm_socket_get_listening_queue(wp, &cur_lq, NULL)) { - cur_lq = 0; + if (wp->listen_address_domain == FPM_AF_INET) { + if (0 > fpm_socket_get_listening_queue(wp->listening_socket, &cur_lq, NULL)) { + cur_lq = 0; +#if 0 + } else { + if (cur_lq > 0) { + if (!wp->warn_lq) { + zlog(ZLOG_WARNING, "[pool %s] listening queue is not empty, #%d requests are waiting to be served, consider raising pm.max_children setting (%d)", wp->config->name, cur_lq, wp->config->pm_max_children); + wp->warn_lq = 1; + } + } else { + wp->warn_lq = 0; + } +#endif + } + fpm_scoreboard_update(-1, -1, cur_lq, -1, -1, -1, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); } - fpm_status_update_activity(wp->shm_status, idle, active, idle + active, cur_lq, wp->listening_queue_len, 0); + /* the rest is only used by PM_STYLE_DYNAMIC */ if (wp->config->pm != PM_STYLE_DYNAMIC) continue; @@ -357,8 +371,8 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ if (idle < wp->config->pm_min_spare_servers) { if (wp->running_children >= wp->config->pm_max_children) { if (!wp->warn_max_children) { - fpm_status_increment_max_children_reached(wp->shm_status); - zlog(ZLOG_WARNING, "[pool %s] server reached max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); + fpm_scoreboard_update(0, 0, 0, 0, 0, 1, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); + zlog(ZLOG_WARNING, "[pool %s] server reached pm.max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); wp->warn_max_children = 1; } wp->idle_spawn_rate = 1; @@ -366,7 +380,7 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ } if (wp->idle_spawn_rate >= 8) { - zlog(ZLOG_WARNING, "[pool %s] seems busy (you may need to increase start_servers, or min/max_spare_servers), spawning %d children, there are %d idle, and %d total children", wp->config->name, wp->idle_spawn_rate, idle, wp->running_children); + zlog(ZLOG_WARNING, "[pool %s] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning %d children, there are %d idle, and %d total children", wp->config->name, wp->idle_spawn_rate, idle, wp->running_children); } /* compute the number of idle process to spawn */ @@ -376,8 +390,8 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ children_to_fork = MIN(children_to_fork, wp->config->pm_max_children - wp->running_children); if (children_to_fork <= 0) { if (!wp->warn_max_children) { - fpm_status_increment_max_children_reached(wp->shm_status); - zlog(ZLOG_WARNING, "[pool %s] server reached max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); + fpm_scoreboard_update(0, 0, 0, 0, 0, 1, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); + zlog(ZLOG_WARNING, "[pool %s] server reached pm.max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); wp->warn_max_children = 1; } wp->idle_spawn_rate = 1; diff --git a/sapi/fpm/fpm/fpm_request.c b/sapi/fpm/fpm/fpm_request.c index 492e76275be12..37d161a5c3c0e 100644 --- a/sapi/fpm/fpm/fpm_request.c +++ b/sapi/fpm/fpm/fpm_request.c @@ -16,7 +16,7 @@ #include "fpm_php_trace.h" #include "fpm_process_ctl.h" #include "fpm_children.h" -#include "fpm_shm_slots.h" +#include "fpm_scoreboard.h" #include "fpm_status.h" #include "fpm_request.h" #include "fpm_log.h" @@ -25,170 +25,237 @@ void fpm_request_accepting() /* {{{ */ { - struct fpm_shm_slot_s *slot; - - slot = fpm_shm_slots_acquire(0, 0); - slot->request_stage = FPM_REQUEST_ACCEPTING; - fpm_clock_get(&slot->tv); - memset(slot->request_uri, 0, sizeof(slot->request_uri)); - memset(slot->request_method, 0, sizeof(slot->request_method)); - slot->content_length = 0; - memset(slot->script_filename, 0, sizeof(slot->script_filename)); - fpm_shm_slots_release(slot); + struct fpm_scoreboard_proc_s *proc; + struct timeval now; + + fpm_clock_get(&now); + + proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (proc == NULL) { + zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + return; + } + + proc->request_stage = FPM_REQUEST_ACCEPTING; + proc->tv = now; + proc->request_uri[0] = '\0'; + proc->request_method[0] = '\0'; + proc->script_filename[0] = '\0'; + proc->content_length = 0; + fpm_scoreboard_proc_release(proc); + + /* idle++, active-- */ + fpm_scoreboard_update(1, -1, 0, 0, 0, 0, FPM_SCOREBOARD_ACTION_INC, NULL); } /* }}} */ void fpm_request_reading_headers() /* {{{ */ { - struct fpm_shm_slot_s *slot; + struct fpm_scoreboard_proc_s *proc; + + struct timeval now; + clock_t now_epoch; +#ifdef HAVE_TIMES + struct tms cpu; +#endif - slot = fpm_shm_slots_acquire(0, 0); - slot->request_stage = FPM_REQUEST_READING_HEADERS; - fpm_clock_get(&slot->tv); - slot->accepted = slot->tv; - slot->accepted_epoch = time(NULL); + fpm_clock_get(&now); + now_epoch = time(NULL); #ifdef HAVE_TIMES - times(&slot->cpu_accepted); + times(&cpu); #endif - fpm_shm_slots_release(slot); - fpm_status_increment_accepted_conn(fpm_status_shm); + proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (proc == NULL) { + zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + return; + } + + proc->request_stage = FPM_REQUEST_READING_HEADERS; + proc->tv = now; + proc->accepted = now; + proc->accepted_epoch = now_epoch; +#ifdef HAVE_TIMES + proc->cpu_accepted = cpu; +#endif + fpm_scoreboard_proc_release(proc); + + /* idle--, active++, request++ */ + fpm_scoreboard_update(-1, 1, 0, 0, 1, 0, FPM_SCOREBOARD_ACTION_INC, NULL); } /* }}} */ void fpm_request_info() /* {{{ */ { TSRMLS_FETCH(); - struct fpm_shm_slot_s *slot; + struct fpm_scoreboard_proc_s *proc; char *request_uri = fpm_php_request_uri(TSRMLS_C); char *request_method = fpm_php_request_method(TSRMLS_C); char *script_filename = fpm_php_script_filename(TSRMLS_C); char *query_string = fpm_php_query_string(TSRMLS_C); char *auth_user = fpm_php_auth_user(TSRMLS_C); + size_t content_length = fpm_php_content_length(TSRMLS_C); + struct timeval now; + + fpm_clock_get(&now); + + proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (proc == NULL) { + zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + return; + } - slot = fpm_shm_slots_acquire(0, 0); - slot->request_stage = FPM_REQUEST_INFO; - fpm_clock_get(&slot->tv); + proc->request_stage = FPM_REQUEST_INFO; + proc->tv = now; if (request_uri) { - strlcpy(slot->request_uri, request_uri, sizeof(slot->request_uri)); + strlcpy(proc->request_uri, request_uri, sizeof(proc->request_uri)); } if (request_method) { - strlcpy(slot->request_method, request_method, sizeof(slot->request_method)); + strlcpy(proc->request_method, request_method, sizeof(proc->request_method)); } if (query_string) { - strlcpy(slot->query_string, query_string, sizeof(slot->query_string)); + strlcpy(proc->query_string, query_string, sizeof(proc->query_string)); } if (auth_user) { - strlcpy(slot->auth_user, auth_user, sizeof(slot->auth_user)); + strlcpy(proc->auth_user, auth_user, sizeof(proc->auth_user)); } - slot->content_length = fpm_php_content_length(TSRMLS_C); + proc->content_length = content_length; /* if cgi.fix_pathinfo is set to "1" and script cannot be found (404) the sapi_globals.request_info.path_translated is set to NULL */ if (script_filename) { - strlcpy(slot->script_filename, script_filename, sizeof(slot->script_filename)); + strlcpy(proc->script_filename, script_filename, sizeof(proc->script_filename)); } - fpm_shm_slots_release(slot); + fpm_scoreboard_proc_release(proc); } /* }}} */ void fpm_request_executing() /* {{{ */ { - struct fpm_shm_slot_s *slot; + struct fpm_scoreboard_proc_s *proc; + struct timeval now; + + fpm_clock_get(&now); + + proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (proc == NULL) { + zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + return; + } - slot = fpm_shm_slots_acquire(0, 0); - slot->request_stage = FPM_REQUEST_EXECUTING; - fpm_clock_get(&slot->tv); - fpm_shm_slots_release(slot); + proc->request_stage = FPM_REQUEST_EXECUTING; + proc->tv = now; + fpm_scoreboard_proc_release(proc); } /* }}} */ void fpm_request_end(TSRMLS_D) /* {{{ */ { - struct fpm_shm_slot_s *slot; + struct fpm_scoreboard_proc_s *proc; + struct timeval now; +#ifdef HAVE_TIMES + struct tms cpu; +#endif + size_t memory = zend_memory_peak_usage(1 TSRMLS_CC); + + fpm_clock_get(&now); +#ifdef HAVE_TIMES + times(&cpu); +#endif - slot = fpm_shm_slots_acquire(0, 0); - slot->request_stage = FPM_REQUEST_FINISHED; - fpm_clock_get(&slot->tv); + proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (proc == NULL) { + zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + return; + } + proc->request_stage = FPM_REQUEST_FINISHED; + proc->tv = now; #ifdef HAVE_TIMES - times(&slot->cpu_finished); - timersub(&slot->tv, &slot->accepted, &slot->cpu_duration); + proc->cpu_finished = cpu; + timersub(&proc->tv, &proc->accepted, &proc->cpu_duration); #endif - slot->memory = zend_memory_peak_usage(1 TSRMLS_CC); - fpm_shm_slots_release(slot); + proc->memory = memory; + fpm_scoreboard_proc_release(proc); } /* }}} */ void fpm_request_finished() /* {{{ */ { - struct fpm_shm_slot_s *slot; - - slot = fpm_shm_slots_acquire(0, 0); - slot->request_stage = FPM_REQUEST_FINISHED; - fpm_clock_get(&slot->tv); - memset(&slot->accepted, 0, sizeof(slot->accepted)); - slot->accepted_epoch = 0; - fpm_shm_slots_release(slot); + struct fpm_scoreboard_proc_s *proc; + struct timeval now; + + fpm_clock_get(&now); + + proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); + if (proc == NULL) { + zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + return; + } + + proc->request_stage = FPM_REQUEST_FINISHED; + proc->tv = now; + memset(&proc->accepted, 0, sizeof(proc->accepted)); + proc->accepted_epoch = 0; + fpm_scoreboard_proc_release(proc); } /* }}} */ void fpm_request_check_timed_out(struct fpm_child_s *child, struct timeval *now, int terminate_timeout, int slowlog_timeout) /* {{{ */ { - struct fpm_shm_slot_s *slot; - struct fpm_shm_slot_s slot_c; + struct fpm_scoreboard_proc_s proc, *proc_p; - slot = fpm_shm_slot(child); - if (!fpm_shm_slots_acquire(slot, 1)) { + proc_p = fpm_scoreboard_proc_acquire(0, child->scoreboard_i, 1); + if (!proc_p) { return; } - slot_c = *slot; - fpm_shm_slots_release(slot); + proc = *proc_p; + fpm_scoreboard_proc_release(proc_p); #if HAVE_FPM_TRACE if (child->slow_logged.tv_sec) { - if (child->slow_logged.tv_sec != slot_c.accepted.tv_sec || child->slow_logged.tv_usec != slot_c.accepted.tv_usec) { + if (child->slow_logged.tv_sec != proc.accepted.tv_sec || child->slow_logged.tv_usec != proc.accepted.tv_usec) { child->slow_logged.tv_sec = 0; child->slow_logged.tv_usec = 0; } } #endif - if (slot_c.request_stage > FPM_REQUEST_ACCEPTING && slot_c.request_stage < FPM_REQUEST_END) { - char purified_script_filename[sizeof(slot_c.script_filename)]; + if (proc.request_stage > FPM_REQUEST_ACCEPTING && proc.request_stage < FPM_REQUEST_END) { + char purified_script_filename[sizeof(proc.script_filename)]; struct timeval tv; - timersub(now, &slot_c.accepted, &tv); + timersub(now, &proc.accepted, &tv); #if HAVE_FPM_TRACE if (child->slow_logged.tv_sec == 0 && slowlog_timeout && - slot_c.request_stage == FPM_REQUEST_EXECUTING && tv.tv_sec >= slowlog_timeout) { + proc.request_stage == FPM_REQUEST_EXECUTING && tv.tv_sec >= slowlog_timeout) { - str_purify_filename(purified_script_filename, slot_c.script_filename, sizeof(slot_c.script_filename)); + str_purify_filename(purified_script_filename, proc.script_filename, sizeof(proc.script_filename)); - child->slow_logged = slot_c.accepted; + child->slow_logged = proc.accepted; child->tracer = fpm_php_trace; fpm_trace_signal(child->pid); zlog(ZLOG_WARNING, "[pool %s] child %d, script '%s' (request: \"%s %s\") executing too slow (%d.%06d sec), logging", - child->wp->config->name, (int) child->pid, purified_script_filename, slot_c.request_method, slot_c.request_uri, + child->wp->config->name, (int) child->pid, purified_script_filename, proc.request_method, proc.request_uri, (int) tv.tv_sec, (int) tv.tv_usec); } else #endif if (terminate_timeout && tv.tv_sec >= terminate_timeout) { - str_purify_filename(purified_script_filename, slot_c.script_filename, sizeof(slot_c.script_filename)); + str_purify_filename(purified_script_filename, proc.script_filename, sizeof(proc.script_filename)); fpm_pctl_kill(child->pid, FPM_PCTL_TERM); zlog(ZLOG_WARNING, "[pool %s] child %d, script '%s' (request: \"%s %s\") execution timed out (%d.%06d sec), terminating", - child->wp->config->name, (int) child->pid, purified_script_filename, slot_c.request_method, slot_c.request_uri, + child->wp->config->name, (int) child->pid, purified_script_filename, proc.request_method, proc.request_uri, (int) tv.tv_sec, (int) tv.tv_usec); } } @@ -197,11 +264,14 @@ void fpm_request_check_timed_out(struct fpm_child_s *child, struct timeval *now, int fpm_request_is_idle(struct fpm_child_s *child) /* {{{ */ { - struct fpm_shm_slot_s slot; + struct fpm_scoreboard_proc_s *proc; /* no need in atomicity here */ - slot = *fpm_shm_slot(child); + proc = fpm_scoreboard_proc_get(child->wp->scoreboard, child->scoreboard_i); + if (!proc) { + return 0; + } - return slot.request_stage == FPM_REQUEST_ACCEPTING; + return proc->request_stage == FPM_REQUEST_ACCEPTING; } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_scoreboard.c b/sapi/fpm/fpm/fpm_scoreboard.c new file mode 100644 index 0000000000000..a68e13ae8ddda --- /dev/null +++ b/sapi/fpm/fpm/fpm_scoreboard.c @@ -0,0 +1,301 @@ + + /* $Id: fpm_status.c 312399 2011-06-23 08:03:52Z fat $ */ + /* (c) 2009 Jerome Loyet */ + +#include "php.h" +#include "SAPI.h" +#include +#include + +#include "fpm_config.h" +#include "fpm_scoreboard.h" +#include "fpm_shm.h" +#include "fpm_sockets.h" +#include "fpm_worker_pool.h" +#include "fpm_clock.h" +#include "zlog.h" + +static struct fpm_scoreboard_s *fpm_scoreboard = NULL; +static int fpm_scoreboard_i = -1; + +int fpm_scoreboard_init_main() /* {{{ */ +{ + struct fpm_worker_pool_s *wp; + int i; + + for (wp = fpm_worker_all_pools; wp; wp = wp->next) { + if (wp->config->pm_max_children < 1) { + zlog(ZLOG_ERROR, "[pool %s] Unable to create scoreboard SHM because max_client is not set", wp->config->name); + return -1; + } + + if (wp->scoreboard) { + zlog(ZLOG_ERROR, "[pool %s] Unable to create scoreboard SHM because it already exists", wp->config->name); + return -1; + } + + wp->scoreboard = fpm_shm_alloc(sizeof(struct fpm_scoreboard_s) + (wp->config->pm_max_children - 1) * sizeof(struct fpm_scoreboard_proc_s *)); + if (!wp->scoreboard) { + return -1; + } + wp->scoreboard->nprocs = wp->config->pm_max_children; + for (i=0; iscoreboard->nprocs; i++) { + wp->scoreboard->procs[i] = NULL; + } + + wp->scoreboard->pm = wp->config->pm; + wp->scoreboard->start_epoch = time(NULL); + strlcpy(wp->scoreboard->pool, wp->config->name, sizeof(wp->scoreboard->pool)); + } + return 0; +} +/* }}} */ + +void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int requests, int max_children_reached, int action, struct fpm_scoreboard_s *scoreboard) /* {{{ */ +{ + if (!scoreboard) { + scoreboard = fpm_scoreboard; + } + if (!scoreboard) { + zlog(ZLOG_WARNING, "Unable to update scoreboard: the SHM has not been found"); + return; + } + + + fpm_spinlock(&scoreboard->lock, 0); + if (action == FPM_SCOREBOARD_ACTION_SET) { + if (idle >= 0) { + scoreboard->idle = idle; + } + if (active >= 0) { + scoreboard->active = active; + } + if (lq >= 0) { + scoreboard->lq = lq; + } + if (lq_len >= 0) { + scoreboard->lq_len = lq_len; + } +#ifdef HAVE_FPM_LQ /* prevent unnecessary test */ + if (scoreboard->lq > scoreboard->lq_max) { + scoreboard->lq_max = scoreboard->lq; + } +#endif + if (requests >= 0) { + scoreboard->requests = requests; + } + + if (max_children_reached >= 0) { + scoreboard->max_children_reached = max_children_reached; + } + } else { + if (scoreboard->idle + idle > 0) { + scoreboard->idle += idle; + } else { + scoreboard->idle = 0; + } + + if (scoreboard->active + active > 0) { + scoreboard->active += active; + } else { + scoreboard->active = 0; + } + + if (scoreboard->requests + requests > 0) { + scoreboard->requests += requests; + } else { + scoreboard->requests = 0; + } + + if (scoreboard->max_children_reached + max_children_reached > 0) { + scoreboard->max_children_reached += max_children_reached; + } else { + scoreboard->max_children_reached = 0; + } + } + + if (scoreboard->active > scoreboard->active_max) { + scoreboard->active_max = scoreboard->active; + } + + fpm_unlock(scoreboard->lock); +} +/* }}} */ + +struct fpm_scoreboard_s *fpm_scoreboard_get() /* {{{*/ +{ + return fpm_scoreboard; +} +/* }}} */ + +struct fpm_scoreboard_proc_s *fpm_scoreboard_proc_get(struct fpm_scoreboard_s *scoreboard, int child_index) /* {{{*/ +{ + if (!scoreboard) { + scoreboard = fpm_scoreboard; + } + + if (!scoreboard) { + return NULL; + } + + if (child_index < 0) { + child_index = fpm_scoreboard_i; + } + + if (child_index < 0 || child_index >= scoreboard->nprocs) { + return NULL; + } + + return scoreboard->procs[child_index]; +} +/* }}} */ + +struct fpm_scoreboard_s *fpm_scoreboard_acquire(struct fpm_scoreboard_s *scoreboard, int nohang) /* {{{ */ +{ + struct fpm_scoreboard_s *s; + + s = scoreboard ? scoreboard : fpm_scoreboard; + if (!s) { + return NULL; + } + + if (!fpm_spinlock(&s->lock, nohang)) { + return NULL; + } + return s; +} +/* }}} */ + +void fpm_scoreboard_release(struct fpm_scoreboard_s *scoreboard) { + if (!scoreboard) { + return; + } + + scoreboard->lock = 0; +} + +struct fpm_scoreboard_proc_s *fpm_scoreboard_proc_acquire(struct fpm_scoreboard_s *scoreboard, int child_index, int nohang) /* {{{ */ +{ + struct fpm_scoreboard_proc_s *proc; + + proc = fpm_scoreboard_proc_get(scoreboard, child_index); + if (!proc) { + return NULL; + } + + if (!fpm_spinlock(&proc->lock, nohang)) { + return NULL; + } + + return proc; +} +/* }}} */ + +void fpm_scoreboard_proc_release(struct fpm_scoreboard_proc_s *proc) /* {{{ */ +{ + if (!proc) { + return; + } + + proc->lock = 0; +} + +void fpm_scoreboard_free(struct fpm_scoreboard_s *scoreboard) /* {{{ */ +{ + int i; + + if (!scoreboard) { + zlog(ZLOG_ERROR, "**scoreboard is NULL"); + return; + } + + for (i=0; inprocs; i++) { + if (!scoreboard->procs[i]) { + continue; + } + fpm_shm_free(scoreboard->procs[i], sizeof(struct fpm_scoreboard_proc_s)); + } + fpm_shm_free(scoreboard, sizeof(struct fpm_scoreboard_s)); +} +/* }}} */ + +void fpm_scoreboard_child_use(struct fpm_scoreboard_s *scoreboard, int child_index, pid_t pid) /* {{{ */ +{ + struct fpm_scoreboard_proc_s *proc; + fpm_scoreboard = scoreboard; + fpm_scoreboard_i = child_index; + proc = fpm_scoreboard_proc_get(scoreboard, child_index); + if (!proc) { + return; + } + proc->pid = pid; +} +/* }}} */ + +void fpm_scoreboard_proc_free(struct fpm_scoreboard_s *scoreboard, int child_index) /* {{{ */ +{ + if (!scoreboard) { + return; + } + + if (child_index < 0 || child_index >= scoreboard->nprocs) { + return; + } + + if (scoreboard->procs[child_index]) { + fpm_shm_free(scoreboard->procs[child_index], sizeof(struct fpm_scoreboard_proc_s)); + scoreboard->procs[child_index] = NULL; + } + + /* set this slot as free to avoid search on next alloc */ + scoreboard->free_proc = child_index; +} +/* }}} */ + +int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_index) /* {{{ */ +{ + int i = -1; + + if (!scoreboard || !child_index) { + return -1; + } + + /* first try the slot which is supposed to be free */ + if (scoreboard->free_proc >= 0 && scoreboard->free_proc < scoreboard->nprocs) { + if (!scoreboard->procs[scoreboard->free_proc]) { + i = scoreboard->free_proc; + } + } + + if (i < 0) { /* the supposed free slot is not, let's search for a free slot */ + zlog(ZLOG_DEBUG, "[pool %s] the proc->free_slot was not free. Let's search", scoreboard->pool); + for (i=0; inprocs; i++) { + if (!scoreboard->procs[i]) { /* found */ + break; + } + } + } + + /* no free slot */ + if (i < 0 || i >= scoreboard->nprocs) { + zlog(ZLOG_ERROR, "[pool %s] no free scoreboard slot", scoreboard->pool); + return -1; + } + + scoreboard->procs[i] = fpm_shm_alloc(sizeof(struct fpm_scoreboard_proc_s)); + if (!scoreboard->procs[i]) { + return -1; + } + *child_index = i; + + /* supposed next slot is free */ + if (i + 1 >= scoreboard->nprocs) { + scoreboard->free_proc = 0; + } else { + scoreboard->free_proc = i + 1; + } + + return 0; +} +/* }}} */ + diff --git a/sapi/fpm/fpm/fpm_scoreboard.h b/sapi/fpm/fpm/fpm_scoreboard.h new file mode 100644 index 0000000000000..00860878cb027 --- /dev/null +++ b/sapi/fpm/fpm/fpm_scoreboard.h @@ -0,0 +1,84 @@ + + /* $Id: fpm_status.h 312263 2011-06-18 17:46:16Z felipe $ */ + /* (c) 2009 Jerome Loyet */ + +#ifndef FPM_SCOREBOARD_H +#define FPM_SCOREBOARD_H 1 + +#include +#ifdef HAVE_TIMES +#include +#endif + +#include "fpm_request.h" +#include "fpm_worker_pool.h" +#include "fpm_atomic.h" + +#define FPM_SCOREBOARD_ACTION_SET 0 +#define FPM_SCOREBOARD_ACTION_INC 1 + +struct fpm_scoreboard_proc_s { + union { + atomic_t lock; + char dummy[16]; + }; + pid_t pid; + enum fpm_request_stage_e request_stage; + struct timeval accepted; + time_t accepted_epoch; + struct timeval tv; + char request_uri[128]; + char query_string[512]; + char request_method[16]; + size_t content_length; /* used with POST only */ + char script_filename[256]; + char auth_user[32]; +#ifdef HAVE_TIMES + struct tms cpu_accepted; + struct tms cpu_finished; + struct timeval cpu_duration; +#endif + size_t memory; +}; + +struct fpm_scoreboard_s { + union { + atomic_t lock; + char dummy[16]; + }; + char pool[32]; + int pm; + time_t start_epoch; + int idle; + int active; + int active_max; + unsigned long int requests; + unsigned int max_children_reached; + int lq; + int lq_max; + unsigned int lq_len; + unsigned int nprocs; + int free_proc; + struct fpm_scoreboard_proc_s *procs[]; +}; + +int fpm_scoreboard_init_main(); +int fpm_scoreboard_init_child(struct fpm_worker_pool_s *wp); + +void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int requests, int max_children_reached, int action, struct fpm_scoreboard_s *scoreboard); +struct fpm_scoreboard_s *fpm_scoreboard_get(); +struct fpm_scoreboard_proc_s *fpm_scoreboard_proc_get(struct fpm_scoreboard_s *scoreboard, int child_index); + +struct fpm_scoreboard_s *fpm_scoreboard_acquire(struct fpm_scoreboard_s *scoreboard, int nohang); +void fpm_scoreboard_release(struct fpm_scoreboard_s *scoreboard); +struct fpm_scoreboard_proc_s *fpm_scoreboard_proc_acquire(struct fpm_scoreboard_s *scoreboard, int child_index, int nohang); +void fpm_scoreboard_proc_release(struct fpm_scoreboard_proc_s *proc); + +void fpm_scoreboard_free(struct fpm_scoreboard_s *scoreboard); + +void fpm_scoreboard_child_use(struct fpm_scoreboard_s *scoreboard, int child_index, pid_t pid); + +void fpm_scoreboard_proc_free(struct fpm_scoreboard_s *scoreboard, int child_index); +int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_index); + +#endif diff --git a/sapi/fpm/fpm/fpm_shm.c b/sapi/fpm/fpm/fpm_shm.c index 5f4040990c09f..8d068d2784ac9 100644 --- a/sapi/fpm/fpm/fpm_shm.c +++ b/sapi/fpm/fpm/fpm_shm.c @@ -1,12 +1,10 @@ /* $Id: fpm_shm.c,v 1.3 2008/05/24 17:38:47 anight Exp $ */ - /* (c) 2007,2008 Andrei Nigmatulin */ + /* (c) 2007,2008 Andrei Nigmatulin, Jerome Loyet */ -#include "fpm_config.h" - -#include #include -#include +#include +#include #include "fpm_shm.h" #include "zlog.h" @@ -17,85 +15,43 @@ #define MAP_ANONYMOUS MAP_ANON #endif -struct fpm_shm_s *fpm_shm_alloc(size_t sz) /* {{{ */ +void *fpm_shm_alloc(size_t size) /* {{{ */ { - struct fpm_shm_s *shm; + void *mem; - shm = malloc(sizeof(*shm)); + mem = mmap(0, size, PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_SHARED, -1, 0); - if (!shm) { - return 0; +#ifdef MAP_FAILED + if (mem == MAP_FAILED) { + zlog(ZLOG_SYSERROR, "unable to allocate %zu bytes in shared memory: %s", size, strerror(errno)); + return NULL; } +#endif - shm->mem = mmap(0, sz, PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_SHARED, -1, 0); - - if (!shm->mem) { - zlog(ZLOG_SYSERROR, "mmap(MAP_ANONYMOUS | MAP_SHARED) failed"); - free(shm); - return 0; + if (!mem) { + zlog(ZLOG_SYSERROR, "unable to allocate %zu bytes in shared memory", size); + return NULL; } - shm->used = 0; - shm->sz = sz; - return shm; + memset(mem, size, 0); + return mem; } /* }}} */ -void fpm_shm_free(struct fpm_shm_s *shm, int do_unmap) /* {{{ */ +int fpm_shm_free(void *mem, size_t size) /* {{{ */ { - if (do_unmap) { - munmap(shm->mem, shm->sz); + if (!mem) { + zlog(ZLOG_ERROR, "mem is NULL"); + return 0; } - free(shm); -} -/* }}} */ -void fpm_shm_free_list(struct fpm_shm_s *shm, void *mem) /* {{{ */ -{ - struct fpm_shm_s *next; - - for (; shm; shm = next) { - next = shm->next; - fpm_shm_free(shm, mem != shm->mem); + if (munmap(mem, size) == -1) { + zlog(ZLOG_SYSERROR, "Unable to free shm: %s", strerror(errno)); + return 0; } -} -/* }}} */ - -void *fpm_shm_alloc_chunk(struct fpm_shm_s **head, size_t sz, void **mem) /* {{{ */ -{ - size_t pagesize = getpagesize(); - static const size_t cache_line_size = 16; - size_t aligned_sz; - struct fpm_shm_s *shm; - void *ret; - - sz = (sz + cache_line_size - 1) & -cache_line_size; - shm = *head; - - if (0 == shm || shm->sz - shm->used < sz) { - /* allocate one more shm segment */ - aligned_sz = (sz + pagesize - 1) & -pagesize; - shm = fpm_shm_alloc(aligned_sz); - - if (!shm) { - return 0; - } - - shm->next = *head; - - if (shm->next) { - shm->next->prev = shm; - } - - shm->prev = 0; - *head = shm; - } - *mem = shm->mem; - ret = (char *) shm->mem + shm->used; - shm->used += sz; - return ret; + return 1; } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_shm.h b/sapi/fpm/fpm/fpm_shm.h index bbff54c4021c3..bcc3d8c1a86a0 100644 --- a/sapi/fpm/fpm/fpm_shm.h +++ b/sapi/fpm/fpm/fpm_shm.h @@ -5,19 +5,8 @@ #ifndef FPM_SHM_H #define FPM_SHM_H 1 -struct fpm_shm_s; - -struct fpm_shm_s { - struct fpm_shm_s *prev, *next; - void *mem; - size_t sz; - size_t used; -}; - -struct fpm_shm_s *fpm_shm_alloc(size_t sz); -void fpm_shm_free(struct fpm_shm_s *shm, int do_unmap); -void fpm_shm_free_list(struct fpm_shm_s *, void *); -void *fpm_shm_alloc_chunk(struct fpm_shm_s **head, size_t sz, void **mem); +void *fpm_shm_alloc(size_t size); +int fpm_shm_free(void *mem, size_t size); #endif diff --git a/sapi/fpm/fpm/fpm_shm_slots.c b/sapi/fpm/fpm/fpm_shm_slots.c deleted file mode 100644 index 2c10d6bb96a6c..0000000000000 --- a/sapi/fpm/fpm/fpm_shm_slots.c +++ /dev/null @@ -1,119 +0,0 @@ - - /* $Id: fpm_shm_slots.c,v 1.2 2008/05/24 17:38:47 anight Exp $ */ - /* (c) 2007,2008 Andrei Nigmatulin */ - -#include "fpm_config.h" - -#include "fpm_atomic.h" -#include "fpm_worker_pool.h" -#include "fpm_children.h" -#include "fpm_shm.h" -#include "fpm_shm_slots.h" -#include "zlog.h" - -static void *shm_mem; -static struct fpm_shm_slot_s *shm_slot; - -int fpm_shm_slots_prepare_slot(struct fpm_child_s *child) /* {{{ */ -{ - struct fpm_worker_pool_s *wp = child->wp; - struct fpm_shm_slot_ptr_s *shm_slot_ptr; - - child->shm_slot_i = wp->slots_used.used; - shm_slot_ptr = fpm_array_push(&wp->slots_used); - - if (0 == shm_slot_ptr) { - return -1; - } - - if (0 == wp->slots_free.used) { - shm_slot_ptr->shm_slot = fpm_shm_alloc_chunk(&wp->shm_list, sizeof(struct fpm_shm_slot_s), &shm_slot_ptr->mem); - if (!shm_slot_ptr->shm_slot) { - return -1; - } - } else { - *shm_slot_ptr = *(struct fpm_shm_slot_ptr_s *) fpm_array_item_last(&wp->slots_free); - --wp->slots_free.used; - } - - memset(shm_slot_ptr->shm_slot, 0, sizeof(struct fpm_shm_slot_s)); - shm_slot_ptr->child = child; - return 0; -} -/* }}} */ - -void fpm_shm_slots_discard_slot(struct fpm_child_s *child) /* {{{ */ -{ - struct fpm_shm_slot_ptr_s *shm_slot_ptr; - struct fpm_worker_pool_s *wp = child->wp; - int n; - - shm_slot_ptr = fpm_array_push(&wp->slots_free); - if (shm_slot_ptr) { - struct fpm_shm_slot_ptr_s *shm_slot_ptr_used; - - shm_slot_ptr_used = fpm_array_item(&wp->slots_used, child->shm_slot_i); - *shm_slot_ptr = *shm_slot_ptr_used; - shm_slot_ptr->child = 0; - } - - n = fpm_array_item_remove(&wp->slots_used, child->shm_slot_i); - if (n > -1) { - shm_slot_ptr = fpm_array_item(&wp->slots_used, n); - shm_slot_ptr->child->shm_slot_i = n; - } -} -/* }}} */ - -void fpm_shm_slots_child_use_slot(struct fpm_child_s *child) /* {{{ */ -{ - struct fpm_shm_slot_ptr_s *shm_slot_ptr; - struct fpm_worker_pool_s *wp = child->wp; - - shm_slot_ptr = fpm_array_item(&wp->slots_used, child->shm_slot_i); - shm_slot = shm_slot_ptr->shm_slot; - shm_mem = shm_slot_ptr->mem; -} -/* }}} */ - -void fpm_shm_slots_parent_use_slot(struct fpm_child_s *child) /* {{{ */ -{ - /* nothing to do */ -} -/* }}} */ - -void *fpm_shm_slots_mem() /* {{{ */ -{ - return shm_mem; -} -/* }}} */ - -struct fpm_shm_slot_s *fpm_shm_slot(struct fpm_child_s *child) /* {{{ */ -{ - struct fpm_shm_slot_ptr_s *shm_slot_ptr; - struct fpm_worker_pool_s *wp = child->wp; - - shm_slot_ptr = fpm_array_item(&wp->slots_used, child->shm_slot_i); - return shm_slot_ptr->shm_slot; -} -/* }}} */ - -struct fpm_shm_slot_s *fpm_shm_slots_acquire(struct fpm_shm_slot_s *s, int nohang) /* {{{ */ -{ - if (s == 0) { - s = shm_slot; - } - - if (0 > fpm_spinlock(&s->lock, nohang)) { - return 0; - } - return s; -} -/* }}} */ - -void fpm_shm_slots_release(struct fpm_shm_slot_s *s) /* {{{ */ -{ - s->lock = 0; -} -/* }}} */ - diff --git a/sapi/fpm/fpm/fpm_shm_slots.h b/sapi/fpm/fpm/fpm_shm_slots.h deleted file mode 100644 index 03303848e92a7..0000000000000 --- a/sapi/fpm/fpm/fpm_shm_slots.h +++ /dev/null @@ -1,57 +0,0 @@ - - /* $Id: fpm_shm_slots.h,v 1.2 2008/05/24 17:38:47 anight Exp $ */ - /* (c) 2007,2008 Andrei Nigmatulin */ - -#ifndef FPM_SHM_SLOTS_H -#define FPM_SHM_SLOTS_H 1 - -#ifdef HAVE_TIMES -#include -#endif - -#include "fpm_atomic.h" -#include "fpm_worker_pool.h" -#include "fpm_request.h" - -struct fpm_child_s; - -struct fpm_shm_slot_s { - union { - atomic_t lock; - char dummy[16]; - }; - enum fpm_request_stage_e request_stage; - struct timeval accepted; - time_t accepted_epoch; - struct timeval tv; - char request_uri[128]; - char query_string[512]; - char request_method[16]; - size_t content_length; /* used with POST only */ - char script_filename[256]; - char auth_user[32]; -#ifdef HAVE_TIMES - struct tms cpu_accepted; - struct tms cpu_finished; - struct timeval cpu_duration; -#endif - size_t memory; -}; - -struct fpm_shm_slot_ptr_s { - void *mem; - struct fpm_shm_slot_s *shm_slot; - struct fpm_child_s *child; -}; - -int fpm_shm_slots_prepare_slot(struct fpm_child_s *child); -void fpm_shm_slots_discard_slot(struct fpm_child_s *child); -void fpm_shm_slots_child_use_slot(struct fpm_child_s *child); -void fpm_shm_slots_parent_use_slot(struct fpm_child_s *child); -void *fpm_shm_slots_mem(); -struct fpm_shm_slot_s *fpm_shm_slot(struct fpm_child_s *child); -struct fpm_shm_slot_s *fpm_shm_slots_acquire(struct fpm_shm_slot_s *, int nohang); -void fpm_shm_slots_release(struct fpm_shm_slot_s *); - -#endif - diff --git a/sapi/fpm/fpm/fpm_sockets.c b/sapi/fpm/fpm/fpm_sockets.c index d8931502643d5..08e2342e56cfb 100644 --- a/sapi/fpm/fpm/fpm_sockets.c +++ b/sapi/fpm/fpm/fpm_sockets.c @@ -28,6 +28,7 @@ #include "fpm_str.h" #include "fpm_env.h" #include "fpm_cleanup.h" +#include "fpm_scoreboard.h" struct listening_socket_s { int refcount; @@ -207,6 +208,7 @@ static int fpm_sockets_new_listening_socket(struct fpm_worker_pool_s *wp, struct zlog(ZLOG_SYSERROR, "listen() for address '%s' failed", wp->config->listen_address); return -1; } + return sock; } /* }}} */ @@ -222,6 +224,7 @@ static int fpm_sockets_get_listening_socket(struct fpm_worker_pool_s *wp, struct sock = fpm_sockets_new_listening_socket(wp, sa, socklen); fpm_sockets_hash_op(sock, sa, 0, wp->listen_address_domain, FPM_STORE_USE_SOCKET); + return sock; } /* }}} */ @@ -294,7 +297,7 @@ static int fpm_socket_af_unix_listening_socket(struct fpm_worker_pool_s *wp) /* int fpm_sockets_init_main() /* {{{ */ { - unsigned i; + unsigned i, lq_len; struct fpm_worker_pool_s *wp; char *inherited = getenv("FPM_SOCKETS"); struct listening_socket_s *ls; @@ -344,13 +347,13 @@ int fpm_sockets_init_main() /* {{{ */ break; } - if (0 > fpm_socket_get_listening_queue(wp, NULL, (unsigned *) &wp->listening_queue_len)) { - wp->listening_queue_len = -1; - } - if (wp->listening_socket == -1) { return -1; } + + if (wp->listen_address_domain == FPM_AF_INET && fpm_socket_get_listening_queue(wp->listening_socket, NULL, &lq_len) >= 0) { + fpm_scoreboard_update(-1, -1, -1, (int)lq_len, -1, -1, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); + } } /* close unused sockets that was inherited */ @@ -383,16 +386,13 @@ int fpm_sockets_init_main() /* {{{ */ #include -int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_lq, unsigned *max_lq) +int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) { - if (wp->listen_address_domain != FPM_AF_INET) { - return -1; - } - struct tcp_info info; socklen_t len = sizeof(info); - if (0 > getsockopt(wp->listening_socket, IPPROTO_TCP, TCP_INFO, &info, &len)) { + if (0 > getsockopt(sock, IPPROTO_TCP, TCP_INFO, &info, &len)) { + zlog(ZLOG_SYSERROR, "unable to retrieve TCP_INFO for socket"); return -1; } @@ -416,13 +416,13 @@ int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_l #ifdef HAVE_LQ_SO_LISTENQ -int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_lq, unsigned *max_lq) +int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) { int val; socklen_t len = sizeof(val); if (cur_lq) { - if (0 > getsockopt(wp->listening_socket, SOL_SOCKET, SO_LISTENQLEN, &val, &len)) { + if (0 > getsockopt(sock, SOL_SOCKET, SO_LISTENQLEN, &val, &len)) { return -1; } @@ -430,7 +430,7 @@ int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_l } if (max_lq) { - if (0 > getsockopt(wp->listening_socket, SOL_SOCKET, SO_LISTENQLIMIT, &val, &len)) { + if (0 > getsockopt(sock, SOL_SOCKET, SO_LISTENQLIMIT, &val, &len)) { return -1; } @@ -444,7 +444,7 @@ int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_l #else -int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_lq, unsigned *max_lq) +int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) { return -1; } diff --git a/sapi/fpm/fpm/fpm_sockets.h b/sapi/fpm/fpm/fpm_sockets.h index b74fc234c2b02..447fbff4b245b 100644 --- a/sapi/fpm/fpm/fpm_sockets.h +++ b/sapi/fpm/fpm/fpm_sockets.h @@ -21,7 +21,7 @@ enum fpm_address_domain fpm_sockets_domain_from_address(char *addr); int fpm_sockets_init_main(); -int fpm_socket_get_listening_queue(struct fpm_worker_pool_s *wp, unsigned *cur_lq, unsigned *max_lq); +int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq); static inline int fd_set_blocked(int fd, int blocked) /* {{{ */ diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 63f15d6e971c7..9fab7e7fb3dbd 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -7,13 +7,13 @@ #include #include "fpm_config.h" +#include "fpm_scoreboard.h" #include "fpm_status.h" #include "fpm_clock.h" -#include "fpm_shm_slots.h" +#include "fpm_scoreboard.h" #include "zlog.h" +#include "fpm_atomic.h" -struct fpm_shm_s *fpm_status_shm = NULL; -static char *fpm_status_pool = NULL; static char *fpm_status_uri = NULL; static char *fpm_status_ping_uri = NULL; static char *fpm_status_ping_response = NULL; @@ -25,146 +25,30 @@ int fpm_status_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ zlog(ZLOG_ERROR, "unable to init fpm_status because conf structure is NULL"); return -1; } - if (wp->config->pm_status_path || wp->config->ping_path) { - if (wp->config->pm_status_path) { - if (!wp->shm_status) { - zlog(ZLOG_ERROR, "[pool %s] unable to init fpm_status because the dedicated SHM has not been set", wp->config->name); - return -1; - } - fpm_status_shm = wp->shm_status; - } - fpm_status_pool = strdup(wp->config->name); - if (wp->config->pm_status_path) { - fpm_status_uri = strdup(wp->config->pm_status_path); - } - if (wp->config->ping_path) { - if (!wp->config->ping_response) { - zlog(ZLOG_ERROR, "[pool %s] ping is set (%s) but pong is not set.", wp->config->name, wp->config->ping_path); - return -1; - } - fpm_status_ping_uri = strdup(wp->config->ping_path); - fpm_status_ping_response = strdup(wp->config->ping_response); - } - } - return 0; -} -/* }}} */ - -void fpm_status_set_pm(struct fpm_shm_s *shm, int pm) /* {{{ */ -{ - struct fpm_status_s status; - - if (!shm) shm = fpm_status_shm; - if (!shm || !shm->mem) return; - - /* one shot operation */ - status = *(struct fpm_status_s *)shm->mem; - - status.pm = pm; - - /* one shot operation */ - *(struct fpm_status_s *)shm->mem = status; -} -/* }}} */ -void fpm_status_increment_accepted_conn(struct fpm_shm_s *shm) /* {{{ */ -{ - struct fpm_status_s status; - - if (!shm) shm = fpm_status_shm; - if (!shm || !shm->mem) return; - - /* one shot operation */ - status = *(struct fpm_status_s *)shm->mem; - - status.accepted_conn++; - - /* one shot operation */ - *(struct fpm_status_s *)shm->mem = status; -} -/* }}} */ - -void fpm_status_update_accepted_conn(struct fpm_shm_s *shm, unsigned long int accepted_conn) /* {{{ */ -{ - struct fpm_status_s status; - - if (!shm) shm = fpm_status_shm; - if (!shm || !shm->mem) return; - - /* one shot operation */ - status = *(struct fpm_status_s *)shm->mem; - - status.accepted_conn = accepted_conn; - - /* one shot operation */ - *(struct fpm_status_s *)shm->mem = status; -} -/* }}} */ - -void fpm_status_increment_max_children_reached(struct fpm_shm_s *shm) /* {{{ */ -{ - struct fpm_status_s status; - - if (!shm) shm = fpm_status_shm; - if (!shm || !shm->mem) return; - - /* one shot operation */ - status = *(struct fpm_status_s *)shm->mem; - - status.max_children_reached++; - - /* one shot operation */ - *(struct fpm_status_s *)shm->mem = status; -} -/* }}} */ - -void fpm_status_update_max_children_reached(struct fpm_shm_s *shm, unsigned int max_children_reached) /* {{{ */ -{ - struct fpm_status_s status; - - if (!shm) shm = fpm_status_shm; - if (!shm || !shm->mem) return; - - /* one shot operation */ - status = *(struct fpm_status_s *)shm->mem; - - status.max_children_reached = max_children_reached; - - /* one shot operation */ - *(struct fpm_status_s *)shm->mem = status; -} -/* }}} */ - -void fpm_status_update_activity(struct fpm_shm_s *shm, int idle, int active, int total, unsigned cur_lq, int max_lq, int clear_last_update) /* {{{ */ -{ - struct fpm_status_s status; - - if (!shm) shm = fpm_status_shm; - if (!shm || !shm->mem) return; - - /* one shot operation */ - status = *(struct fpm_status_s *)shm->mem; + if (wp->config->pm_status_path) { + fpm_status_uri = strdup(wp->config->pm_status_path); + } - status.idle = idle; - status.active = active; - status.total = total; - status.cur_lq = cur_lq; - status.max_lq = max_lq; - if (clear_last_update) { - memset(&status.last_update, 0, sizeof(status.last_update)); - } else { - fpm_clock_get(&status.last_update); + if (wp->config->ping_path) { + if (!wp->config->ping_response) { + zlog(ZLOG_ERROR, "[pool %s] ping is set (%s) but pong is not set.", wp->config->name, wp->config->ping_path); + return -1; + } + fpm_status_ping_uri = strdup(wp->config->ping_path); + fpm_status_ping_response = strdup(wp->config->ping_response); } - /* one shot operation */ - *(struct fpm_status_s *)shm->mem = status; + return 0; } /* }}} */ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ { - struct fpm_status_s status; - char *buffer, *syntax; + struct fpm_scoreboard_s scoreboard, *scoreboard_p; +// struct fpm_scoreboard_proc_s proc; + char *buffer, *syntax, *time_format, time_buffer[64]; + time_t now_epoch; if (!SG(request_info).request_uri) { return 0; @@ -181,19 +65,28 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ /* STATUS */ if (fpm_status_uri && !strcmp(fpm_status_uri, SG(request_info).request_uri)) { - if (!fpm_status_shm || !fpm_status_shm->mem) { - zlog(ZLOG_ERROR, "[pool %s] unable to find or access status shared memory", fpm_status_pool); + scoreboard_p = fpm_scoreboard_get(); + if (!scoreboard_p) { + zlog(ZLOG_ERROR, "status: unable to find or access status shared memory"); SG(sapi_headers).http_response_code = 500; sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); PUTS("Internal error. Please review log file for errors."); return 1; } - /* one shot operation */ - status = *(struct fpm_status_s *)fpm_status_shm->mem; + if (!fpm_spinlock(&scoreboard_p->lock, 1)) { + zlog(ZLOG_NOTICE, "[pool %s] status: scoreboard already in used.", scoreboard_p->pool); + SG(sapi_headers).http_response_code = 503; + sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + PUTS("Server busy. Please try again later."); + return 1; + } + /* copy the scoreboard not to bother other processes */ + scoreboard = *scoreboard_p; + fpm_unlock(scoreboard_p->lock); - if (status.idle < 0 || status.active < 0 || status.total < 0) { - zlog(ZLOG_ERROR, "[pool %s] invalid status values", fpm_status_pool); + if (scoreboard.idle < 0 || scoreboard.active < 0) { + zlog(ZLOG_ERROR, "[pool %s] invalid status values", scoreboard.pool); SG(sapi_headers).http_response_code = 500; sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); PUTS("Internal error. Please review log file for errors."); @@ -203,88 +96,113 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ /* HTML */ if (SG(request_info).query_string && strstr(SG(request_info).query_string, "html")) { sapi_add_header_ex(ZEND_STRL("Content-Type: text/html"), 1, 1 TSRMLS_CC); + time_format = "%d/%b/%Y:%H:%M:%S %z"; syntax = "\n" "\n" "\n" + "\n" + "\n" "\n" #if HAVE_FPM_LQ - "\n" - "\n" + "\n" + "\n" + "\n" #endif "\n" "\n" "\n" + "\n" "\n" "
pool%s
process manager%s
start time%s
start since%lu
accepted conn%lu
listen queue len%u
max listen queue len%d
listen queue%u
max listen queue%u
listen queue len%d
idle processes%d
active processes%d
total processes%d
max active processes%d
max children reached%u
"; /* XML */ } else if (SG(request_info).request_uri && strstr(SG(request_info).query_string, "xml")) { sapi_add_header_ex(ZEND_STRL("Content-Type: text/xml"), 1, 1 TSRMLS_CC); + time_format = "%s"; syntax = "\n" "\n" "%s\n" "%s\n" + "%s\n" + "%lu\n" "%lu\n" #if HAVE_FPM_LQ - "%u\n" - "%d\n" + "%u\n" + "%u\n" + "%d\n" #endif "%d\n" "%d\n" "%d\n" + "%d\n" "%u\n" ""; /* JSON */ } else if (SG(request_info).request_uri && strstr(SG(request_info).query_string, "json")) { sapi_add_header_ex(ZEND_STRL("Content-Type: application/json"), 1, 1 TSRMLS_CC); - + time_format = "%s"; syntax = "{" "\"pool\":\"%s\"," "\"process manager\":\"%s\"," + "\"start time\":%s," + "\"start since\":%lu," "\"accepted conn\":%lu," #if HAVE_FPM_LQ - "\"listen queue len\":%u," - "\"max listen queue len\":%d," + "\"listen queue\":%u," + "\"max listen queue\":%u," + "\"listen queue len\":%d," #endif "\"idle processes\":%d," "\"active processes\":%d," "\"total processes\":%d," + "\"max active processes\":%d," "\"max children reached\":%u" "}"; /* TEXT */ } else { sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + time_format = "%d/%b/%Y:%H:%M:%S %z"; syntax = "pool: %s\n" "process manager: %s\n" + "start time: %s\n" + "start since: %lu\n" "accepted conn: %lu\n" #if HAVE_FPM_LQ - "listen queue len: %u\n" - "max listen queue len: %d\n" + "listen queue: %u\n" + "max listen queue: %u\n" + "listen queue len: %d\n" #endif "idle processes: %d\n" "active processes: %d\n" "total processes: %d\n" + "max active processes: %d\n" "max children reached: %u\n"; } + strftime(time_buffer, sizeof(time_buffer) - 1, time_format, localtime(&scoreboard.start_epoch)); + now_epoch = time(NULL); spprintf(&buffer, 0, syntax, - fpm_status_pool, - status.pm == PM_STYLE_STATIC ? "static" : "dynamic", - status.accepted_conn, + scoreboard.pool, + scoreboard.pm == PM_STYLE_STATIC ? "static" : "dynamic", + time_buffer, + now_epoch - scoreboard.start_epoch, + scoreboard.requests, #if HAVE_FPM_LQ - status.cur_lq, - status.max_lq, + scoreboard.lq, + scoreboard.lq_max, + scoreboard.lq_len, #endif - status.idle, - status.active, - status.total, - status.max_children_reached); + scoreboard.idle, + scoreboard.active, + scoreboard.idle + scoreboard.active, + scoreboard.active_max, + scoreboard.max_children_reached); SG(sapi_headers).http_response_code = 200; PUTS(buffer); diff --git a/sapi/fpm/fpm/fpm_worker_pool.c b/sapi/fpm/fpm/fpm_worker_pool.c index e799e35026373..6c6d9cce03be3 100644 --- a/sapi/fpm/fpm/fpm_worker_pool.c +++ b/sapi/fpm/fpm/fpm_worker_pool.c @@ -13,8 +13,9 @@ #include "fpm_cleanup.h" #include "fpm_children.h" #include "fpm_shm.h" -#include "fpm_shm_slots.h" +#include "fpm_scoreboard.h" #include "fpm_conf.h" +#include "zlog.h" struct fpm_worker_pool_s *fpm_worker_all_pools; @@ -26,18 +27,15 @@ static void fpm_worker_pool_cleanup(int which, void *arg) /* {{{ */ wp_next = wp->next; fpm_worker_pool_config_free(wp->config); fpm_children_free(wp->children); - fpm_array_free(&wp->slots_used); - fpm_array_free(&wp->slots_free); - fpm_shm_free_list(wp->shm_list, which == FPM_CLEANUP_CHILD ? fpm_shm_slots_mem() : 0); - if (wp->shm_status && which != FPM_CLEANUP_CHILD) { - fpm_shm_free(wp->shm_status, !fpm_globals.is_child); + if ((which & FPM_CLEANUP_CHILD) == 0 && fpm_globals.parent_pid == getpid()) { + fpm_scoreboard_free(wp->scoreboard); } free(wp->config); free(wp->user); free(wp->home); free(wp); } - fpm_worker_all_pools = 0; + fpm_worker_all_pools = NULL; } /* }}} */ @@ -52,8 +50,6 @@ struct fpm_worker_pool_s *fpm_worker_pool_alloc() /* {{{ */ memset(ret, 0, sizeof(struct fpm_worker_pool_s)); - fpm_array_init(&ret->slots_used, sizeof(struct fpm_shm_slot_ptr_s), 50); - fpm_array_init(&ret->slots_free, sizeof(struct fpm_shm_slot_ptr_s), 50); ret->idle_spawn_rate = 1; ret->log_fd = -1; return ret; diff --git a/sapi/fpm/fpm/fpm_worker_pool.h b/sapi/fpm/fpm/fpm_worker_pool.h index e014255cf148f..098def5b7e276 100644 --- a/sapi/fpm/fpm/fpm_worker_pool.h +++ b/sapi/fpm/fpm/fpm_worker_pool.h @@ -6,7 +6,6 @@ #define FPM_WORKER_POOL_H 1 #include "fpm_conf.h" -#include "fpm_arrays.h" #include "fpm_shm.h" struct fpm_worker_pool_s; @@ -25,20 +24,18 @@ struct fpm_worker_pool_s { char *user, *home; /* for setting env USER and HOME */ enum fpm_address_domain listen_address_domain; int listening_socket; - int listening_queue_len; int set_uid, set_gid; /* config uid and gid */ int socket_uid, socket_gid, socket_mode; - struct fpm_shm_s *shm_list; - struct fpm_array_s slots_used; - struct fpm_array_s slots_free; - /* runtime */ struct fpm_child_s *children; int running_children; int idle_spawn_rate; int warn_max_children; - struct fpm_shm_s *shm_status; +#if 0 + int warn_lq; +#endif + struct fpm_scoreboard_s *scoreboard; int log_fd; }; From b158091ed6f725e443b9a49fe7212596bd1c218b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 26 Jun 2011 21:34:39 +0000 Subject: [PATCH 0235/2394] Fix crypt_blowfish 8-bit chars problem (CVE-2011-2483), add tests # See details at http://www.openwall.com/lists/announce/2011/06/21/1 --- ext/standard/crypt.c | 2 +- ext/standard/crypt_blowfish.c | 74 +++++++++++++++++-- .../tests/strings/crypt_blowfish.phpt | 50 +++++++++++++ 3 files changed, 117 insertions(+), 9 deletions(-) create mode 100644 ext/standard/tests/strings/crypt_blowfish.phpt diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index 65d83243d69a1..03a080aa23325 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -240,7 +240,7 @@ PHP_FUNCTION(crypt) } else if ( salt[0] == '$' && salt[1] == '2' && - salt[2] == 'a' && + (salt[2] != 'a' && salt[2] != 'x') || salt[3] == '$' && salt[4] >= '0' && salt[4] <= '3' && salt[5] >= '0' && salt[5] <= '9' && diff --git a/ext/standard/crypt_blowfish.c b/ext/standard/crypt_blowfish.c index 6c99a396d5006..9e3a9241d0afc 100644 --- a/ext/standard/crypt_blowfish.c +++ b/ext/standard/crypt_blowfish.c @@ -1,5 +1,5 @@ /* - $Id$ + $Id$ */ /* * This code comes from John the Ripper password cracker, with reentrant @@ -7,6 +7,7 @@ * cracking removed. * * Written by Solar Designer in 1998-2002 and + * placed in the public domain. Quick self-test added in 2011 and also * placed in the public domain. * * There's absolutely no warranty. @@ -51,6 +52,13 @@ #define __CONST __const #endif +/* + * Please keep this enabled. We really don't want incompatible hashes to be + * produced. The performance cost of this quick self-test is around 0.6% at + * the "$2a$08" setting. + */ +#define BF_SELF_TEST + #ifdef __i386__ #define BF_ASM 0 #define BF_SCALE 1 @@ -63,6 +71,7 @@ #endif typedef unsigned int BF_word; +typedef signed int BF_word_signed; /* Number of Blowfish rounds, this is also hardcoded into a few places */ #define BF_N 16 @@ -555,7 +564,7 @@ static void BF_swap(BF_word *x, int count) } while (ptr < &data.ctx.S[3][0xFF]); #endif -static void BF_set_key(__CONST char *key, BF_key expanded, BF_key initial) +static void BF_set_key(__CONST char *key, BF_key expanded, BF_key initial, int sign_extension_bug) { __CONST char *ptr = key; int i, j; @@ -565,7 +574,10 @@ static void BF_set_key(__CONST char *key, BF_key expanded, BF_key initial) tmp = 0; for (j = 0; j < 4; j++) { tmp <<= 8; - tmp |= *ptr; + if (sign_extension_bug) + tmp |= (BF_word_signed)(signed char)*ptr; + else + tmp |= (unsigned char)*ptr; if (!*ptr) ptr = key; else ptr++; } @@ -575,8 +587,9 @@ static void BF_set_key(__CONST char *key, BF_key expanded, BF_key initial) } } -char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, - char *output, int size) +static char *BF_crypt(__CONST char *key, __CONST char *setting, + char *output, int size, + BF_word min) { #if BF_ASM extern void _BF_body_r(BF_ctx *ctx); @@ -602,7 +615,7 @@ char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, if (setting[0] != '$' || setting[1] != '2' || - setting[2] != 'a' || + (setting[2] != 'a' && setting[2] != 'x') || setting[3] != '$' || setting[4] < '0' || setting[4] > '3' || setting[5] < '0' || setting[5] > '9' || @@ -613,7 +626,7 @@ char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, } count = (BF_word)1 << ((setting[4] - '0') * 10 + (setting[5] - '0')); - if (count < 16 || BF_decode(data.binary.salt, &setting[7], 16)) { + if (count < min || BF_decode(data.binary.salt, &setting[7], 16)) { clean(data.binary.salt, sizeof(data.binary.salt)); __set_errno(EINVAL); return NULL; @@ -621,7 +634,7 @@ char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, BF_swap(data.binary.salt, 4); - BF_set_key(key, data.expanded_key, data.ctx.P); + BF_set_key(key, data.expanded_key, data.ctx.P, setting[2] == 'x'); memcpy(data.ctx.S, BF_init_state.S, sizeof(data.ctx.S)); @@ -721,14 +734,59 @@ char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, BF_encode(&output[7 + 22], data.binary.output, 23); output[7 + 22 + 31] = '\0'; + #ifndef BF_SELF_TEST /* Overwrite the most obvious sensitive data we have on the stack. Note * that this does not guarantee there's no sensitive data left on the * stack and/or in registers; I'm not aware of portable code that does. */ clean(&data, sizeof(data)); +#endif return output; } +char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, + char *output, int size) +{ +#ifdef BF_SELF_TEST + __CONST char *test_key = "8b \xd0\xc1\xd2\xcf\xcc\xd8"; + __CONST char *test_2a = + "$2a$00$abcdefghijklmnopqrstuui1D709vfamulimlGcq0qq3UvuUasvEa" + "\0" + "canary"; + __CONST char *test_2x = + "$2x$00$abcdefghijklmnopqrstuuVUrPmXD6q/nVSSp7pNDhCR9071IfIRe" + "\0" + "canary"; + __CONST char *test_hash, *p; + int ok; + char buf[7 + 22 + 31 + 1 + 6 + 1]; + + output = BF_crypt(key, setting, output, size, 16); + +/* Do a quick self-test. This also happens to overwrite BF_crypt()'s data. */ + test_hash = (setting[2] == 'x') ? test_2x : test_2a; + memcpy(buf, test_hash, sizeof(buf)); + memset(buf, -1, sizeof(buf) - (6 + 1)); /* keep "canary" only */ + p = BF_crypt(test_key, test_hash, buf, sizeof(buf) - 6, 1); + + ok = (p == buf && !memcmp(p, test_hash, sizeof(buf))); + +/* This could reveal what hash type we were using last. Unfortunately, we + * can't reliably clean the test_hash pointer. */ + clean(&buf, sizeof(buf)); + + if (ok) + return output; + +/* Should not happen */ + __set_errno(EINVAL); /* pretend we don't support this hash type */ + return NULL; +#else +#warning Self-test is disabled, please enable + return BF_crypt(key, setting, output, size, 16); +#endif +} + char *php_crypt_gensalt_blowfish_rn(unsigned long count, __CONST char *input, int size, char *output, int output_size) { diff --git a/ext/standard/tests/strings/crypt_blowfish.phpt b/ext/standard/tests/strings/crypt_blowfish.phpt new file mode 100644 index 0000000000000..cce09c1518544 --- /dev/null +++ b/ext/standard/tests/strings/crypt_blowfish.phpt @@ -0,0 +1,50 @@ +--TEST-- +Official blowfish tests (http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/glibc/crypt_blowfish/wrapper.c) +--SKIPIF-- + +--FILE-- + +--EXPECT-- +0. OK +1. OK +2. OK +3. OK +4. OK +5. OK +6. OK +7. OK +8. OK +9. OK +10. OK +11. OK \ No newline at end of file From 9a38856c3ab6d4237a249b46b88f1a91a9b2b5cd Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 27 Jun 2011 01:36:39 +0000 Subject: [PATCH 0236/2394] - Fixed data type usage in 64bit Reported by: Leonildo Costa --- ext/pdo_odbc/odbc_driver.c | 2 +- ext/pdo_odbc/odbc_stmt.c | 2 +- ext/pdo_odbc/php_pdo_odbc_int.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/pdo_odbc/odbc_driver.c b/ext/pdo_odbc/odbc_driver.c index f2576496938d1..97b57478633a6 100755 --- a/ext/pdo_odbc/odbc_driver.c +++ b/ext/pdo_odbc/odbc_driver.c @@ -224,7 +224,7 @@ static long odbc_handle_doer(pdo_dbh_t *dbh, const char *sql, long sql_len TSRML { pdo_odbc_db_handle *H = (pdo_odbc_db_handle *)dbh->driver_data; RETCODE rc; - long row_count = -1; + SQLLEN row_count = -1; PDO_ODBC_HSTMT stmt; rc = SQLAllocHandle(SQL_HANDLE_STMT, H->dbc, &stmt); diff --git a/ext/pdo_odbc/odbc_stmt.c b/ext/pdo_odbc/odbc_stmt.c index 85061dfb84376..12c5bc4bb2f0d 100755 --- a/ext/pdo_odbc/odbc_stmt.c +++ b/ext/pdo_odbc/odbc_stmt.c @@ -164,7 +164,7 @@ static int odbc_stmt_execute(pdo_stmt_t *stmt TSRMLS_DC) RETCODE rc; pdo_odbc_stmt *S = (pdo_odbc_stmt*)stmt->driver_data; char *buf = NULL; - long row_count = -1; + SQLLEN row_count = -1; if (stmt->executed) { SQLCloseCursor(S->stmt); diff --git a/ext/pdo_odbc/php_pdo_odbc_int.h b/ext/pdo_odbc/php_pdo_odbc_int.h index 2472e770d7d09..4c216ffafa5e0 100755 --- a/ext/pdo_odbc/php_pdo_odbc_int.h +++ b/ext/pdo_odbc/php_pdo_odbc_int.h @@ -136,7 +136,7 @@ typedef struct { typedef struct { char *data; unsigned long datalen; - long fetched_len; + SQLLEN fetched_len; SWORD coltype; char colname[128]; unsigned is_long; From 527313919bef1dd03bad7a64d2376e6a19595f1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 27 Jun 2011 11:33:03 +0000 Subject: [PATCH 0237/2394] - fixed request_timeout and slowlog_timeout from last FPM commit (r312496) - typo --- sapi/fpm/fpm/fpm_events.c | 1 + sapi/fpm/fpm/fpm_process_ctl.c | 2 +- sapi/fpm/fpm/fpm_request.c | 15 ++++++++------- sapi/fpm/fpm/fpm_shm.c | 13 +++++++++++++ sapi/fpm/fpm/fpm_shm.h | 1 + 5 files changed, 24 insertions(+), 8 deletions(-) diff --git a/sapi/fpm/fpm/fpm_events.c b/sapi/fpm/fpm/fpm_events.c index 7ba982bf75c7f..8ae9ad2e20719 100644 --- a/sapi/fpm/fpm/fpm_events.c +++ b/sapi/fpm/fpm/fpm_events.c @@ -263,6 +263,7 @@ void fpm_event_loop(int err) /* {{{ */ if (!err) { fpm_pctl_perform_idle_server_maintenance_heartbeat(NULL, 0, NULL); + zlog(ZLOG_DEBUG, "%zu bytes have been reserved in SHM", fpm_shm_get_size_allocated()); zlog(ZLOG_NOTICE, "ready to handle connections"); } diff --git a/sapi/fpm/fpm/fpm_process_ctl.c b/sapi/fpm/fpm/fpm_process_ctl.c index c297c2d44a69f..0f2685c738fd3 100644 --- a/sapi/fpm/fpm/fpm_process_ctl.c +++ b/sapi/fpm/fpm/fpm_process_ctl.c @@ -352,7 +352,7 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ } #endif } - fpm_scoreboard_update(-1, -1, cur_lq, -1, -1, -1, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); + fpm_scoreboard_update(idle, active, cur_lq, -1, -1, -1, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); } diff --git a/sapi/fpm/fpm/fpm_request.c b/sapi/fpm/fpm/fpm_request.c index 37d161a5c3c0e..e0d1815dbe99b 100644 --- a/sapi/fpm/fpm/fpm_request.c +++ b/sapi/fpm/fpm/fpm_request.c @@ -32,7 +32,7 @@ void fpm_request_accepting() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); return; } @@ -67,7 +67,7 @@ void fpm_request_reading_headers() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); return; } @@ -101,7 +101,7 @@ void fpm_request_info() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); return; } @@ -145,7 +145,7 @@ void fpm_request_executing() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); return; } @@ -171,7 +171,7 @@ void fpm_request_end(TSRMLS_D) /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); return; } proc->request_stage = FPM_REQUEST_FINISHED; @@ -194,7 +194,7 @@ void fpm_request_finished() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to aquire proc scoreboard"); + zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); return; } @@ -210,8 +210,9 @@ void fpm_request_check_timed_out(struct fpm_child_s *child, struct timeval *now, { struct fpm_scoreboard_proc_s proc, *proc_p; - proc_p = fpm_scoreboard_proc_acquire(0, child->scoreboard_i, 1); + proc_p = fpm_scoreboard_proc_acquire(child->wp->scoreboard, child->scoreboard_i, 1); if (!proc_p) { + zlog(ZLOG_WARNING, "unable to acquire scoreboard"); return; } diff --git a/sapi/fpm/fpm/fpm_shm.c b/sapi/fpm/fpm/fpm_shm.c index 8d068d2784ac9..a777612de0f81 100644 --- a/sapi/fpm/fpm/fpm_shm.c +++ b/sapi/fpm/fpm/fpm_shm.c @@ -15,6 +15,8 @@ #define MAP_ANONYMOUS MAP_ANON #endif +static size_t fpm_shm_size = 0; + void *fpm_shm_alloc(size_t size) /* {{{ */ { void *mem; @@ -34,6 +36,7 @@ void *fpm_shm_alloc(size_t size) /* {{{ */ } memset(mem, size, 0); + fpm_shm_size += size; return mem; } /* }}} */ @@ -50,8 +53,18 @@ int fpm_shm_free(void *mem, size_t size) /* {{{ */ return 0; } + if (fpm_shm_size - size > 0) { + fpm_shm_size -= size; + } else { + fpm_shm_size = 0; + } return 1; } /* }}} */ +size_t fpm_shm_get_size_allocated() /* {{{*/ +{ + return fpm_shm_size; +} +/* }}} */ diff --git a/sapi/fpm/fpm/fpm_shm.h b/sapi/fpm/fpm/fpm_shm.h index bcc3d8c1a86a0..bcb609981449b 100644 --- a/sapi/fpm/fpm/fpm_shm.h +++ b/sapi/fpm/fpm/fpm_shm.h @@ -7,6 +7,7 @@ void *fpm_shm_alloc(size_t size); int fpm_shm_free(void *mem, size_t size); +size_t fpm_shm_get_size_allocated(); #endif From 39a15706cdf954c1a73d7fb110e3bd977da82599 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 27 Jun 2011 11:47:43 +0000 Subject: [PATCH 0238/2394] - Updated to version 2011.8 (2011h) --- ext/date/lib/timezonedb.h | 1661 ++++++++++++++++--------------------- 1 file changed, 703 insertions(+), 958 deletions(-) diff --git a/ext/date/lib/timezonedb.h b/ext/date/lib/timezonedb.h index c8634408332f4..7f2a3a0c6bdc9 100644 --- a/ext/date/lib/timezonedb.h +++ b/ext/date/lib/timezonedb.h @@ -1,4 +1,4 @@ -const timelib_tzdb_index_entry timezonedb_idx_builtin[571] = { +const timelib_tzdb_index_entry timezonedb_idx_builtin[573] = { { "Africa/Abidjan" , 0x000000 }, { "Africa/Accra" , 0x000055 }, { "Africa/Addis_Ababa" , 0x0000FD }, @@ -139,440 +139,442 @@ const timelib_tzdb_index_entry timezonedb_idx_builtin[571] = { { "America/Kentucky/Louisville" , 0x00C43B }, { "America/Kentucky/Monticello" , 0x00C859 }, { "America/Knox_IN" , 0x00CBDE }, - { "America/La_Paz" , 0x00CF4F }, - { "America/Lima" , 0x00CFB6 }, - { "America/Los_Angeles" , 0x00D05E }, - { "America/Louisville" , 0x00D46F }, - { "America/Maceio" , 0x00D864 }, - { "America/Managua" , 0x00D99E }, - { "America/Manaus" , 0x00DA51 }, - { "America/Marigot" , 0x00DB53 }, - { "America/Martinique" , 0x00DBA8 }, - { "America/Matamoros" , 0x00DC14 }, - { "America/Mazatlan" , 0x00DE6D }, - { "America/Mendoza" , 0x00E0DA }, - { "America/Menominee" , 0x00E28E }, - { "America/Merida" , 0x00E60F }, - { "America/Metlakatla" , 0x00E84A }, - { "America/Mexico_City" , 0x00EBA8 }, - { "America/Miquelon" , 0x00EE23 }, - { "America/Moncton" , 0x00F095 }, - { "America/Monterrey" , 0x00F52C }, - { "America/Montevideo" , 0x00F78F }, - { "America/Montreal" , 0x00FAA1 }, - { "America/Montserrat" , 0x00FFB7 }, - { "America/Nassau" , 0x01000C }, - { "America/New_York" , 0x010351 }, - { "America/Nipigon" , 0x01085C }, - { "America/Nome" , 0x010BAD }, - { "America/Noronha" , 0x010F2B }, - { "America/North_Dakota/Beulah" , 0x01105B }, - { "America/North_Dakota/Center" , 0x0113EF }, - { "America/North_Dakota/New_Salem" , 0x011783 }, - { "America/Ojinaga" , 0x011B2C }, - { "America/Panama" , 0x011D8D }, - { "America/Pangnirtung" , 0x011DE2 }, - { "America/Paramaribo" , 0x012118 }, - { "America/Phoenix" , 0x0121AA }, - { "America/Port-au-Prince" , 0x012258 }, - { "America/Port_of_Spain" , 0x012473 }, - { "America/Porto_Acre" , 0x012374 }, - { "America/Porto_Velho" , 0x0124C8 }, - { "America/Puerto_Rico" , 0x0125BE }, - { "America/Rainy_River" , 0x012629 }, - { "America/Rankin_Inlet" , 0x012961 }, - { "America/Recife" , 0x012C47 }, - { "America/Regina" , 0x012D71 }, - { "America/Resolute" , 0x012F2F }, - { "America/Rio_Branco" , 0x013228 }, - { "America/Rosario" , 0x01332B }, - { "America/Santa_Isabel" , 0x0134D1 }, - { "America/Santarem" , 0x013874 }, - { "America/Santiago" , 0x013979 }, - { "America/Santo_Domingo" , 0x013D22 }, - { "America/Sao_Paulo" , 0x013DE8 }, - { "America/Scoresbysund" , 0x0140F7 }, - { "America/Shiprock" , 0x0143E5 }, - { "America/Sitka" , 0x014774 }, - { "America/St_Barthelemy" , 0x014AFC }, - { "America/St_Johns" , 0x014B51 }, - { "America/St_Kitts" , 0x0150A4 }, - { "America/St_Lucia" , 0x0150F9 }, - { "America/St_Thomas" , 0x01514E }, - { "America/St_Vincent" , 0x0151A3 }, - { "America/Swift_Current" , 0x0151F8 }, - { "America/Tegucigalpa" , 0x015319 }, - { "America/Thule" , 0x015398 }, - { "America/Thunder_Bay" , 0x0155DF }, - { "America/Tijuana" , 0x015928 }, - { "America/Toronto" , 0x015CC1 }, - { "America/Tortola" , 0x0161D8 }, - { "America/Vancouver" , 0x01622D }, - { "America/Virgin" , 0x01666A }, - { "America/Whitehorse" , 0x0166BF }, - { "America/Winnipeg" , 0x0169DC }, - { "America/Yakutat" , 0x016E1C }, - { "America/Yellowknife" , 0x017187 }, - { "Antarctica/Casey" , 0x017497 }, - { "Antarctica/Davis" , 0x017522 }, - { "Antarctica/DumontDUrville" , 0x0175B9 }, - { "Antarctica/Macquarie" , 0x01764B }, - { "Antarctica/Mawson" , 0x0178C5 }, - { "Antarctica/McMurdo" , 0x017941 }, - { "Antarctica/Palmer" , 0x017C43 }, - { "Antarctica/Rothera" , 0x017F5F }, - { "Antarctica/South_Pole" , 0x017FD5 }, - { "Antarctica/Syowa" , 0x0182DD }, - { "Antarctica/Vostok" , 0x01834B }, - { "Arctic/Longyearbyen" , 0x0183BC }, - { "Asia/Aden" , 0x0186EE }, - { "Asia/Almaty" , 0x018743 }, - { "Asia/Amman" , 0x0188C2 }, - { "Asia/Anadyr" , 0x018B82 }, - { "Asia/Aqtau" , 0x018E70 }, - { "Asia/Aqtobe" , 0x01906F }, - { "Asia/Ashgabat" , 0x019227 }, - { "Asia/Ashkhabad" , 0x019344 }, - { "Asia/Baghdad" , 0x019461 }, - { "Asia/Bahrain" , 0x0195D6 }, - { "Asia/Baku" , 0x01963C }, - { "Asia/Bangkok" , 0x019924 }, - { "Asia/Beirut" , 0x019979 }, - { "Asia/Bishkek" , 0x019C86 }, - { "Asia/Brunei" , 0x019E32 }, - { "Asia/Calcutta" , 0x019E94 }, - { "Asia/Choibalsan" , 0x019F0D }, - { "Asia/Chongqing" , 0x01A086 }, - { "Asia/Chungking" , 0x01A175 }, - { "Asia/Colombo" , 0x01A224 }, - { "Asia/Dacca" , 0x01A2C0 }, - { "Asia/Damascus" , 0x01A366 }, - { "Asia/Dhaka" , 0x01A6B6 }, - { "Asia/Dili" , 0x01A75C }, - { "Asia/Dubai" , 0x01A7E5 }, - { "Asia/Dushanbe" , 0x01A83A }, - { "Asia/Gaza" , 0x01A93D }, - { "Asia/Harbin" , 0x01AC86 }, - { "Asia/Ho_Chi_Minh" , 0x01AD6D }, - { "Asia/Hong_Kong" , 0x01ADE5 }, - { "Asia/Hovd" , 0x01AFA7 }, - { "Asia/Irkutsk" , 0x01B11F }, - { "Asia/Istanbul" , 0x01B406 }, - { "Asia/Jakarta" , 0x01B7F3 }, - { "Asia/Jayapura" , 0x01B89D }, - { "Asia/Jerusalem" , 0x01B939 }, - { "Asia/Kabul" , 0x01BC68 }, - { "Asia/Kamchatka" , 0x01BCB9 }, - { "Asia/Karachi" , 0x01BF9E }, - { "Asia/Kashgar" , 0x01C053 }, - { "Asia/Kathmandu" , 0x01C124 }, - { "Asia/Katmandu" , 0x01C18A }, - { "Asia/Kolkata" , 0x01C1F0 }, - { "Asia/Krasnoyarsk" , 0x01C269 }, - { "Asia/Kuala_Lumpur" , 0x01C552 }, - { "Asia/Kuching" , 0x01C60F }, - { "Asia/Kuwait" , 0x01C6FD }, - { "Asia/Macao" , 0x01C752 }, - { "Asia/Macau" , 0x01C88D }, - { "Asia/Magadan" , 0x01C9C8 }, - { "Asia/Makassar" , 0x01CCAB }, - { "Asia/Manila" , 0x01CD6F }, - { "Asia/Muscat" , 0x01CDF4 }, - { "Asia/Nicosia" , 0x01CE49 }, - { "Asia/Novokuznetsk" , 0x01D131 }, - { "Asia/Novosibirsk" , 0x01D434 }, - { "Asia/Omsk" , 0x01D728 }, - { "Asia/Oral" , 0x01DA10 }, - { "Asia/Phnom_Penh" , 0x01DBE0 }, - { "Asia/Pontianak" , 0x01DC58 }, - { "Asia/Pyongyang" , 0x01DD19 }, - { "Asia/Qatar" , 0x01DD86 }, - { "Asia/Qyzylorda" , 0x01DDEC }, - { "Asia/Rangoon" , 0x01DFC2 }, - { "Asia/Riyadh" , 0x01E03A }, - { "Asia/Saigon" , 0x01E08F }, - { "Asia/Sakhalin" , 0x01E107 }, - { "Asia/Samarkand" , 0x01E407 }, - { "Asia/Seoul" , 0x01E53D }, - { "Asia/Shanghai" , 0x01E5E1 }, - { "Asia/Singapore" , 0x01E6C1 }, - { "Asia/Taipei" , 0x01E778 }, - { "Asia/Tashkent" , 0x01E890 }, - { "Asia/Tbilisi" , 0x01E9C1 }, - { "Asia/Tehran" , 0x01EB7B }, - { "Asia/Tel_Aviv" , 0x01EDE9 }, - { "Asia/Thimbu" , 0x01F118 }, - { "Asia/Thimphu" , 0x01F17E }, - { "Asia/Tokyo" , 0x01F1E4 }, - { "Asia/Ujung_Pandang" , 0x01F26D }, - { "Asia/Ulaanbaatar" , 0x01F2E9 }, - { "Asia/Ulan_Bator" , 0x01F444 }, - { "Asia/Urumqi" , 0x01F591 }, - { "Asia/Vientiane" , 0x01F658 }, - { "Asia/Vladivostok" , 0x01F6D0 }, - { "Asia/Yakutsk" , 0x01F9BD }, - { "Asia/Yekaterinburg" , 0x01FCA3 }, - { "Asia/Yerevan" , 0x01FFAF }, - { "Atlantic/Azores" , 0x0202B3 }, - { "Atlantic/Bermuda" , 0x0207B6 }, - { "Atlantic/Canary" , 0x020A97 }, - { "Atlantic/Cape_Verde" , 0x020D6D }, - { "Atlantic/Faeroe" , 0x020DE6 }, - { "Atlantic/Faroe" , 0x02108A }, - { "Atlantic/Jan_Mayen" , 0x02132E }, - { "Atlantic/Madeira" , 0x021660 }, - { "Atlantic/Reykjavik" , 0x021B69 }, - { "Atlantic/South_Georgia" , 0x021D22 }, - { "Atlantic/St_Helena" , 0x022030 }, - { "Atlantic/Stanley" , 0x021D66 }, - { "Australia/ACT" , 0x022085 }, - { "Australia/Adelaide" , 0x0223A2 }, - { "Australia/Brisbane" , 0x0226CE }, - { "Australia/Broken_Hill" , 0x022795 }, - { "Australia/Canberra" , 0x022AD3 }, - { "Australia/Currie" , 0x022DF0 }, - { "Australia/Darwin" , 0x023123 }, - { "Australia/Eucla" , 0x0231A9 }, - { "Australia/Hobart" , 0x02327E }, - { "Australia/LHI" , 0x0235DC }, - { "Australia/Lindeman" , 0x023877 }, - { "Australia/Lord_Howe" , 0x023958 }, - { "Australia/Melbourne" , 0x023C03 }, - { "Australia/North" , 0x023F28 }, - { "Australia/NSW" , 0x023F9C }, - { "Australia/Perth" , 0x0242B9 }, - { "Australia/Queensland" , 0x024391 }, - { "Australia/South" , 0x02443D }, - { "Australia/Sydney" , 0x02475A }, - { "Australia/Tasmania" , 0x024A97 }, - { "Australia/Victoria" , 0x024DDC }, - { "Australia/West" , 0x0250F9 }, - { "Australia/Yancowinna" , 0x0251AF }, - { "Brazil/Acre" , 0x0254D1 }, - { "Brazil/DeNoronha" , 0x0255D0 }, - { "Brazil/East" , 0x0256F0 }, - { "Brazil/West" , 0x0259CD }, - { "Canada/Atlantic" , 0x025AC5 }, - { "Canada/Central" , 0x025FAD }, - { "Canada/East-Saskatchewan" , 0x0268B7 }, - { "Canada/Eastern" , 0x0263C7 }, - { "Canada/Mountain" , 0x026A40 }, - { "Canada/Newfoundland" , 0x026DB6 }, - { "Canada/Pacific" , 0x0272E1 }, - { "Canada/Saskatchewan" , 0x0276FA }, - { "Canada/Yukon" , 0x027883 }, - { "CET" , 0x027B86 }, - { "Chile/Continental" , 0x027E8F }, - { "Chile/EasterIsland" , 0x02822A }, - { "CST6CDT" , 0x02856C }, - { "Cuba" , 0x0288BD }, - { "EET" , 0x028C30 }, - { "Egypt" , 0x028EE3 }, - { "Eire" , 0x0291A6 }, - { "EST" , 0x0296B7 }, - { "EST5EDT" , 0x0296FB }, - { "Etc/GMT" , 0x029A4C }, - { "Etc/GMT+0" , 0x029B18 }, - { "Etc/GMT+1" , 0x029BA2 }, - { "Etc/GMT+10" , 0x029C2F }, - { "Etc/GMT+11" , 0x029CBD }, - { "Etc/GMT+12" , 0x029D4B }, - { "Etc/GMT+2" , 0x029E66 }, - { "Etc/GMT+3" , 0x029EF2 }, - { "Etc/GMT+4" , 0x029F7E }, - { "Etc/GMT+5" , 0x02A00A }, - { "Etc/GMT+6" , 0x02A096 }, - { "Etc/GMT+7" , 0x02A122 }, - { "Etc/GMT+8" , 0x02A1AE }, - { "Etc/GMT+9" , 0x02A23A }, - { "Etc/GMT-0" , 0x029AD4 }, - { "Etc/GMT-1" , 0x029B5C }, - { "Etc/GMT-10" , 0x029BE8 }, - { "Etc/GMT-11" , 0x029C76 }, - { "Etc/GMT-12" , 0x029D04 }, - { "Etc/GMT-13" , 0x029D92 }, - { "Etc/GMT-14" , 0x029DD9 }, - { "Etc/GMT-2" , 0x029E20 }, - { "Etc/GMT-3" , 0x029EAC }, - { "Etc/GMT-4" , 0x029F38 }, - { "Etc/GMT-5" , 0x029FC4 }, - { "Etc/GMT-6" , 0x02A050 }, - { "Etc/GMT-7" , 0x02A0DC }, - { "Etc/GMT-8" , 0x02A168 }, - { "Etc/GMT-9" , 0x02A1F4 }, - { "Etc/GMT0" , 0x029A90 }, - { "Etc/Greenwich" , 0x02A280 }, - { "Etc/UCT" , 0x02A2C4 }, - { "Etc/Universal" , 0x02A308 }, - { "Etc/UTC" , 0x02A34C }, - { "Etc/Zulu" , 0x02A390 }, - { "Europe/Amsterdam" , 0x02A3D4 }, - { "Europe/Andorra" , 0x02A812 }, - { "Europe/Athens" , 0x02AA8E }, - { "Europe/Belfast" , 0x02ADD1 }, - { "Europe/Belgrade" , 0x02B308 }, - { "Europe/Berlin" , 0x02B5D1 }, - { "Europe/Bratislava" , 0x02B927 }, - { "Europe/Brussels" , 0x02BC59 }, - { "Europe/Bucharest" , 0x02C090 }, - { "Europe/Budapest" , 0x02C3BA }, - { "Europe/Chisinau" , 0x02C72D }, - { "Europe/Copenhagen" , 0x02CABB }, - { "Europe/Dublin" , 0x02CDC5 }, - { "Europe/Gibraltar" , 0x02D2D6 }, - { "Europe/Guernsey" , 0x02D72D }, - { "Europe/Helsinki" , 0x02DC64 }, - { "Europe/Isle_of_Man" , 0x02DF1A }, - { "Europe/Istanbul" , 0x02E451 }, - { "Europe/Jersey" , 0x02E83E }, - { "Europe/Kaliningrad" , 0x02ED75 }, - { "Europe/Kiev" , 0x02F0D8 }, - { "Europe/Lisbon" , 0x02F3EF }, - { "Europe/Ljubljana" , 0x02F8F3 }, - { "Europe/London" , 0x02FBBC }, - { "Europe/Luxembourg" , 0x0300F3 }, - { "Europe/Madrid" , 0x030549 }, - { "Europe/Malta" , 0x03090F }, - { "Europe/Mariehamn" , 0x030CC8 }, - { "Europe/Minsk" , 0x030F7E }, - { "Europe/Monaco" , 0x031289 }, - { "Europe/Moscow" , 0x0316C4 }, - { "Europe/Nicosia" , 0x031A16 }, - { "Europe/Oslo" , 0x031CFE }, - { "Europe/Paris" , 0x032030 }, - { "Europe/Podgorica" , 0x032476 }, - { "Europe/Prague" , 0x03273F }, - { "Europe/Riga" , 0x032A71 }, - { "Europe/Rome" , 0x032DB6 }, - { "Europe/Samara" , 0x033179 }, - { "Europe/San_Marino" , 0x0334B2 }, - { "Europe/Sarajevo" , 0x033875 }, - { "Europe/Simferopol" , 0x033B3E }, - { "Europe/Skopje" , 0x033E69 }, - { "Europe/Sofia" , 0x034132 }, - { "Europe/Stockholm" , 0x03443A }, - { "Europe/Tallinn" , 0x0346E9 }, - { "Europe/Tirane" , 0x034A23 }, - { "Europe/Tiraspol" , 0x034D29 }, - { "Europe/Uzhgorod" , 0x0350B7 }, - { "Europe/Vaduz" , 0x0353CE }, - { "Europe/Vatican" , 0x035661 }, - { "Europe/Vienna" , 0x035A24 }, - { "Europe/Vilnius" , 0x035D51 }, - { "Europe/Volgograd" , 0x036090 }, - { "Europe/Warsaw" , 0x036399 }, - { "Europe/Zagreb" , 0x03677A }, - { "Europe/Zaporozhye" , 0x036A43 }, - { "Europe/Zurich" , 0x036D84 }, - { "Factory" , 0x037033 }, - { "GB" , 0x0370A4 }, - { "GB-Eire" , 0x0375DB }, - { "GMT" , 0x037B12 }, - { "GMT+0" , 0x037BDE }, - { "GMT-0" , 0x037B9A }, - { "GMT0" , 0x037B56 }, - { "Greenwich" , 0x037C22 }, - { "Hongkong" , 0x037C66 }, - { "HST" , 0x037E28 }, - { "Iceland" , 0x037E6C }, - { "Indian/Antananarivo" , 0x038025 }, - { "Indian/Chagos" , 0x038099 }, - { "Indian/Christmas" , 0x0380FB }, - { "Indian/Cocos" , 0x03813F }, - { "Indian/Comoro" , 0x038183 }, - { "Indian/Kerguelen" , 0x0381D8 }, - { "Indian/Mahe" , 0x03822D }, - { "Indian/Maldives" , 0x038282 }, - { "Indian/Mauritius" , 0x0382D7 }, - { "Indian/Mayotte" , 0x03834D }, - { "Indian/Reunion" , 0x0383A2 }, - { "Iran" , 0x0383F7 }, - { "Israel" , 0x038665 }, - { "Jamaica" , 0x038994 }, - { "Japan" , 0x038A59 }, - { "Kwajalein" , 0x038AE2 }, - { "Libya" , 0x038B45 }, - { "MET" , 0x038C3F }, - { "Mexico/BajaNorte" , 0x038F48 }, - { "Mexico/BajaSur" , 0x0392B1 }, - { "Mexico/General" , 0x0394F6 }, - { "MST" , 0x039754 }, - { "MST7MDT" , 0x039798 }, - { "Navajo" , 0x039AE9 }, - { "NZ" , 0x039E62 }, - { "NZ-CHAT" , 0x03A1E0 }, - { "Pacific/Apia" , 0x03A4C8 }, - { "Pacific/Auckland" , 0x03A546 }, - { "Pacific/Chatham" , 0x03A8D2 }, - { "Pacific/Chuuk" , 0x03ABC9 }, - { "Pacific/Easter" , 0x03AC22 }, - { "Pacific/Efate" , 0x03AF80 }, - { "Pacific/Enderbury" , 0x03B046 }, - { "Pacific/Fakaofo" , 0x03B0B4 }, - { "Pacific/Fiji" , 0x03B0F8 }, - { "Pacific/Funafuti" , 0x03B182 }, - { "Pacific/Galapagos" , 0x03B1C6 }, - { "Pacific/Gambier" , 0x03B23E }, - { "Pacific/Guadalcanal" , 0x03B2A3 }, - { "Pacific/Guam" , 0x03B2F8 }, - { "Pacific/Honolulu" , 0x03B34E }, - { "Pacific/Johnston" , 0x03B3C5 }, - { "Pacific/Kiritimati" , 0x03B417 }, - { "Pacific/Kosrae" , 0x03B482 }, - { "Pacific/Kwajalein" , 0x03B4DF }, - { "Pacific/Majuro" , 0x03B54B }, - { "Pacific/Marquesas" , 0x03B5AA }, - { "Pacific/Midway" , 0x03B611 }, - { "Pacific/Nauru" , 0x03B69B }, - { "Pacific/Niue" , 0x03B713 }, - { "Pacific/Norfolk" , 0x03B771 }, - { "Pacific/Noumea" , 0x03B7C6 }, - { "Pacific/Pago_Pago" , 0x03B856 }, - { "Pacific/Palau" , 0x03B8DF }, - { "Pacific/Pitcairn" , 0x03B923 }, - { "Pacific/Pohnpei" , 0x03B978 }, - { "Pacific/Ponape" , 0x03B9CD }, - { "Pacific/Port_Moresby" , 0x03BA12 }, - { "Pacific/Rarotonga" , 0x03BA56 }, - { "Pacific/Saipan" , 0x03BB32 }, - { "Pacific/Samoa" , 0x03BB95 }, - { "Pacific/Tahiti" , 0x03BC1E }, - { "Pacific/Tarawa" , 0x03BC83 }, - { "Pacific/Tongatapu" , 0x03BCD7 }, - { "Pacific/Truk" , 0x03BD63 }, - { "Pacific/Wake" , 0x03BDA8 }, - { "Pacific/Wallis" , 0x03BDF8 }, - { "Pacific/Yap" , 0x03BE3C }, - { "Poland" , 0x03BE81 }, - { "Portugal" , 0x03C262 }, - { "PRC" , 0x03C75E }, - { "PST8PDT" , 0x03C80F }, - { "ROC" , 0x03CB60 }, - { "ROK" , 0x03CC78 }, - { "Singapore" , 0x03CD1C }, - { "Turkey" , 0x03CDD3 }, - { "UCT" , 0x03D1C0 }, - { "Universal" , 0x03D204 }, - { "US/Alaska" , 0x03D248 }, - { "US/Aleutian" , 0x03D5B1 }, - { "US/Arizona" , 0x03D917 }, - { "US/Central" , 0x03D9A5 }, - { "US/East-Indiana" , 0x03E3AF }, - { "US/Eastern" , 0x03DEB0 }, - { "US/Hawaii" , 0x03E619 }, - { "US/Indiana-Starke" , 0x03E68A }, - { "US/Michigan" , 0x03E9FB }, - { "US/Mountain" , 0x03ED32 }, - { "US/Pacific" , 0x03F0AB }, - { "US/Pacific-New" , 0x03F4B0 }, - { "US/Samoa" , 0x03F8B5 }, - { "UTC" , 0x03F93E }, - { "W-SU" , 0x03FC35 }, - { "WET" , 0x03F982 }, - { "Zulu" , 0x03FF70 }, + { "America/Kralendijk" , 0x00CF4F }, + { "America/La_Paz" , 0x00CFB5 }, + { "America/Lima" , 0x00D01C }, + { "America/Los_Angeles" , 0x00D0C4 }, + { "America/Louisville" , 0x00D4D5 }, + { "America/Lower_Princes" , 0x00D8CA }, + { "America/Maceio" , 0x00D930 }, + { "America/Managua" , 0x00DA6A }, + { "America/Manaus" , 0x00DB1D }, + { "America/Marigot" , 0x00DC1F }, + { "America/Martinique" , 0x00DC74 }, + { "America/Matamoros" , 0x00DCE0 }, + { "America/Mazatlan" , 0x00DF39 }, + { "America/Mendoza" , 0x00E1A6 }, + { "America/Menominee" , 0x00E35A }, + { "America/Merida" , 0x00E6DB }, + { "America/Metlakatla" , 0x00E916 }, + { "America/Mexico_City" , 0x00EC74 }, + { "America/Miquelon" , 0x00EEEF }, + { "America/Moncton" , 0x00F161 }, + { "America/Monterrey" , 0x00F5F8 }, + { "America/Montevideo" , 0x00F85B }, + { "America/Montreal" , 0x00FB6D }, + { "America/Montserrat" , 0x010083 }, + { "America/Nassau" , 0x0100D8 }, + { "America/New_York" , 0x01041D }, + { "America/Nipigon" , 0x010928 }, + { "America/Nome" , 0x010C79 }, + { "America/Noronha" , 0x010FF7 }, + { "America/North_Dakota/Beulah" , 0x011127 }, + { "America/North_Dakota/Center" , 0x0114BB }, + { "America/North_Dakota/New_Salem" , 0x01184F }, + { "America/Ojinaga" , 0x011BF8 }, + { "America/Panama" , 0x011E59 }, + { "America/Pangnirtung" , 0x011EAE }, + { "America/Paramaribo" , 0x0121E4 }, + { "America/Phoenix" , 0x012276 }, + { "America/Port-au-Prince" , 0x012324 }, + { "America/Port_of_Spain" , 0x01253F }, + { "America/Porto_Acre" , 0x012440 }, + { "America/Porto_Velho" , 0x012594 }, + { "America/Puerto_Rico" , 0x01268A }, + { "America/Rainy_River" , 0x0126F5 }, + { "America/Rankin_Inlet" , 0x012A2D }, + { "America/Recife" , 0x012D13 }, + { "America/Regina" , 0x012E3D }, + { "America/Resolute" , 0x012FFB }, + { "America/Rio_Branco" , 0x0132F4 }, + { "America/Rosario" , 0x0133F7 }, + { "America/Santa_Isabel" , 0x01359D }, + { "America/Santarem" , 0x013940 }, + { "America/Santiago" , 0x013A45 }, + { "America/Santo_Domingo" , 0x013DEE }, + { "America/Sao_Paulo" , 0x013EB4 }, + { "America/Scoresbysund" , 0x0141C3 }, + { "America/Shiprock" , 0x0144B1 }, + { "America/Sitka" , 0x014840 }, + { "America/St_Barthelemy" , 0x014BC8 }, + { "America/St_Johns" , 0x014C1D }, + { "America/St_Kitts" , 0x015170 }, + { "America/St_Lucia" , 0x0151C5 }, + { "America/St_Thomas" , 0x01521A }, + { "America/St_Vincent" , 0x01526F }, + { "America/Swift_Current" , 0x0152C4 }, + { "America/Tegucigalpa" , 0x0153E5 }, + { "America/Thule" , 0x015464 }, + { "America/Thunder_Bay" , 0x0156AB }, + { "America/Tijuana" , 0x0159F4 }, + { "America/Toronto" , 0x015D8D }, + { "America/Tortola" , 0x0162A4 }, + { "America/Vancouver" , 0x0162F9 }, + { "America/Virgin" , 0x016736 }, + { "America/Whitehorse" , 0x01678B }, + { "America/Winnipeg" , 0x016AA8 }, + { "America/Yakutat" , 0x016EE8 }, + { "America/Yellowknife" , 0x017253 }, + { "Antarctica/Casey" , 0x017563 }, + { "Antarctica/Davis" , 0x0175EE }, + { "Antarctica/DumontDUrville" , 0x017685 }, + { "Antarctica/Macquarie" , 0x017717 }, + { "Antarctica/Mawson" , 0x017991 }, + { "Antarctica/McMurdo" , 0x017A0D }, + { "Antarctica/Palmer" , 0x017D0F }, + { "Antarctica/Rothera" , 0x01802B }, + { "Antarctica/South_Pole" , 0x0180A1 }, + { "Antarctica/Syowa" , 0x0183A9 }, + { "Antarctica/Vostok" , 0x018417 }, + { "Arctic/Longyearbyen" , 0x018488 }, + { "Asia/Aden" , 0x0187BA }, + { "Asia/Almaty" , 0x01880F }, + { "Asia/Amman" , 0x01898E }, + { "Asia/Anadyr" , 0x018C4E }, + { "Asia/Aqtau" , 0x018E33 }, + { "Asia/Aqtobe" , 0x019032 }, + { "Asia/Ashgabat" , 0x0191EA }, + { "Asia/Ashkhabad" , 0x019307 }, + { "Asia/Baghdad" , 0x019424 }, + { "Asia/Bahrain" , 0x019599 }, + { "Asia/Baku" , 0x0195FF }, + { "Asia/Bangkok" , 0x0198E7 }, + { "Asia/Beirut" , 0x01993C }, + { "Asia/Bishkek" , 0x019C49 }, + { "Asia/Brunei" , 0x019DF5 }, + { "Asia/Calcutta" , 0x019E57 }, + { "Asia/Choibalsan" , 0x019ED0 }, + { "Asia/Chongqing" , 0x01A049 }, + { "Asia/Chungking" , 0x01A138 }, + { "Asia/Colombo" , 0x01A1E7 }, + { "Asia/Dacca" , 0x01A283 }, + { "Asia/Damascus" , 0x01A329 }, + { "Asia/Dhaka" , 0x01A679 }, + { "Asia/Dili" , 0x01A71F }, + { "Asia/Dubai" , 0x01A7A8 }, + { "Asia/Dushanbe" , 0x01A7FD }, + { "Asia/Gaza" , 0x01A900 }, + { "Asia/Harbin" , 0x01AC49 }, + { "Asia/Ho_Chi_Minh" , 0x01AD30 }, + { "Asia/Hong_Kong" , 0x01ADA8 }, + { "Asia/Hovd" , 0x01AF6A }, + { "Asia/Irkutsk" , 0x01B0E2 }, + { "Asia/Istanbul" , 0x01B2C8 }, + { "Asia/Jakarta" , 0x01B6B5 }, + { "Asia/Jayapura" , 0x01B75F }, + { "Asia/Jerusalem" , 0x01B7FB }, + { "Asia/Kabul" , 0x01BB2A }, + { "Asia/Kamchatka" , 0x01BB7B }, + { "Asia/Karachi" , 0x01BD57 }, + { "Asia/Kashgar" , 0x01BE0C }, + { "Asia/Kathmandu" , 0x01BEDD }, + { "Asia/Katmandu" , 0x01BF43 }, + { "Asia/Kolkata" , 0x01BFA9 }, + { "Asia/Krasnoyarsk" , 0x01C022 }, + { "Asia/Kuala_Lumpur" , 0x01C20A }, + { "Asia/Kuching" , 0x01C2C7 }, + { "Asia/Kuwait" , 0x01C3B5 }, + { "Asia/Macao" , 0x01C40A }, + { "Asia/Macau" , 0x01C545 }, + { "Asia/Magadan" , 0x01C680 }, + { "Asia/Makassar" , 0x01C862 }, + { "Asia/Manila" , 0x01C926 }, + { "Asia/Muscat" , 0x01C9AB }, + { "Asia/Nicosia" , 0x01CA00 }, + { "Asia/Novokuznetsk" , 0x01CCE8 }, + { "Asia/Novosibirsk" , 0x01CEEA }, + { "Asia/Omsk" , 0x01D0D5 }, + { "Asia/Oral" , 0x01D2BC }, + { "Asia/Phnom_Penh" , 0x01D48C }, + { "Asia/Pontianak" , 0x01D504 }, + { "Asia/Pyongyang" , 0x01D5C5 }, + { "Asia/Qatar" , 0x01D632 }, + { "Asia/Qyzylorda" , 0x01D698 }, + { "Asia/Rangoon" , 0x01D86E }, + { "Asia/Riyadh" , 0x01D8E6 }, + { "Asia/Saigon" , 0x01D93B }, + { "Asia/Sakhalin" , 0x01D9B3 }, + { "Asia/Samarkand" , 0x01DBAA }, + { "Asia/Seoul" , 0x01DCE0 }, + { "Asia/Shanghai" , 0x01DD84 }, + { "Asia/Singapore" , 0x01DE64 }, + { "Asia/Taipei" , 0x01DF1B }, + { "Asia/Tashkent" , 0x01E033 }, + { "Asia/Tbilisi" , 0x01E164 }, + { "Asia/Tehran" , 0x01E31E }, + { "Asia/Tel_Aviv" , 0x01E58C }, + { "Asia/Thimbu" , 0x01E8BB }, + { "Asia/Thimphu" , 0x01E921 }, + { "Asia/Tokyo" , 0x01E987 }, + { "Asia/Ujung_Pandang" , 0x01EA10 }, + { "Asia/Ulaanbaatar" , 0x01EA8C }, + { "Asia/Ulan_Bator" , 0x01EBE7 }, + { "Asia/Urumqi" , 0x01ED34 }, + { "Asia/Vientiane" , 0x01EDFB }, + { "Asia/Vladivostok" , 0x01EE73 }, + { "Asia/Yakutsk" , 0x01F05F }, + { "Asia/Yekaterinburg" , 0x01F244 }, + { "Asia/Yerevan" , 0x01F44F }, + { "Atlantic/Azores" , 0x01F753 }, + { "Atlantic/Bermuda" , 0x01FC56 }, + { "Atlantic/Canary" , 0x01FF37 }, + { "Atlantic/Cape_Verde" , 0x02020D }, + { "Atlantic/Faeroe" , 0x020286 }, + { "Atlantic/Faroe" , 0x02052A }, + { "Atlantic/Jan_Mayen" , 0x0207CE }, + { "Atlantic/Madeira" , 0x020B00 }, + { "Atlantic/Reykjavik" , 0x021009 }, + { "Atlantic/South_Georgia" , 0x0211C2 }, + { "Atlantic/St_Helena" , 0x0214D0 }, + { "Atlantic/Stanley" , 0x021206 }, + { "Australia/ACT" , 0x021525 }, + { "Australia/Adelaide" , 0x021842 }, + { "Australia/Brisbane" , 0x021B6E }, + { "Australia/Broken_Hill" , 0x021C35 }, + { "Australia/Canberra" , 0x021F73 }, + { "Australia/Currie" , 0x022290 }, + { "Australia/Darwin" , 0x0225C3 }, + { "Australia/Eucla" , 0x022649 }, + { "Australia/Hobart" , 0x02271E }, + { "Australia/LHI" , 0x022A7C }, + { "Australia/Lindeman" , 0x022D17 }, + { "Australia/Lord_Howe" , 0x022DF8 }, + { "Australia/Melbourne" , 0x0230A3 }, + { "Australia/North" , 0x0233C8 }, + { "Australia/NSW" , 0x02343C }, + { "Australia/Perth" , 0x023759 }, + { "Australia/Queensland" , 0x023831 }, + { "Australia/South" , 0x0238DD }, + { "Australia/Sydney" , 0x023BFA }, + { "Australia/Tasmania" , 0x023F37 }, + { "Australia/Victoria" , 0x02427C }, + { "Australia/West" , 0x024599 }, + { "Australia/Yancowinna" , 0x02464F }, + { "Brazil/Acre" , 0x024971 }, + { "Brazil/DeNoronha" , 0x024A70 }, + { "Brazil/East" , 0x024B90 }, + { "Brazil/West" , 0x024E6D }, + { "Canada/Atlantic" , 0x024F65 }, + { "Canada/Central" , 0x02544D }, + { "Canada/East-Saskatchewan" , 0x025D57 }, + { "Canada/Eastern" , 0x025867 }, + { "Canada/Mountain" , 0x025EE0 }, + { "Canada/Newfoundland" , 0x026256 }, + { "Canada/Pacific" , 0x026781 }, + { "Canada/Saskatchewan" , 0x026B9A }, + { "Canada/Yukon" , 0x026D23 }, + { "CET" , 0x027026 }, + { "Chile/Continental" , 0x02732F }, + { "Chile/EasterIsland" , 0x0276CA }, + { "CST6CDT" , 0x027A0C }, + { "Cuba" , 0x027D5D }, + { "EET" , 0x0280D0 }, + { "Egypt" , 0x028383 }, + { "Eire" , 0x028646 }, + { "EST" , 0x028B57 }, + { "EST5EDT" , 0x028B9B }, + { "Etc/GMT" , 0x028EEC }, + { "Etc/GMT+0" , 0x028FB8 }, + { "Etc/GMT+1" , 0x029042 }, + { "Etc/GMT+10" , 0x0290CF }, + { "Etc/GMT+11" , 0x02915D }, + { "Etc/GMT+12" , 0x0291EB }, + { "Etc/GMT+2" , 0x029306 }, + { "Etc/GMT+3" , 0x029392 }, + { "Etc/GMT+4" , 0x02941E }, + { "Etc/GMT+5" , 0x0294AA }, + { "Etc/GMT+6" , 0x029536 }, + { "Etc/GMT+7" , 0x0295C2 }, + { "Etc/GMT+8" , 0x02964E }, + { "Etc/GMT+9" , 0x0296DA }, + { "Etc/GMT-0" , 0x028F74 }, + { "Etc/GMT-1" , 0x028FFC }, + { "Etc/GMT-10" , 0x029088 }, + { "Etc/GMT-11" , 0x029116 }, + { "Etc/GMT-12" , 0x0291A4 }, + { "Etc/GMT-13" , 0x029232 }, + { "Etc/GMT-14" , 0x029279 }, + { "Etc/GMT-2" , 0x0292C0 }, + { "Etc/GMT-3" , 0x02934C }, + { "Etc/GMT-4" , 0x0293D8 }, + { "Etc/GMT-5" , 0x029464 }, + { "Etc/GMT-6" , 0x0294F0 }, + { "Etc/GMT-7" , 0x02957C }, + { "Etc/GMT-8" , 0x029608 }, + { "Etc/GMT-9" , 0x029694 }, + { "Etc/GMT0" , 0x028F30 }, + { "Etc/Greenwich" , 0x029720 }, + { "Etc/UCT" , 0x029764 }, + { "Etc/Universal" , 0x0297A8 }, + { "Etc/UTC" , 0x0297EC }, + { "Etc/Zulu" , 0x029830 }, + { "Europe/Amsterdam" , 0x029874 }, + { "Europe/Andorra" , 0x029CB2 }, + { "Europe/Athens" , 0x029F2E }, + { "Europe/Belfast" , 0x02A271 }, + { "Europe/Belgrade" , 0x02A7A8 }, + { "Europe/Berlin" , 0x02AA71 }, + { "Europe/Bratislava" , 0x02ADC7 }, + { "Europe/Brussels" , 0x02B0F9 }, + { "Europe/Bucharest" , 0x02B530 }, + { "Europe/Budapest" , 0x02B85A }, + { "Europe/Chisinau" , 0x02BBCD }, + { "Europe/Copenhagen" , 0x02BF5B }, + { "Europe/Dublin" , 0x02C265 }, + { "Europe/Gibraltar" , 0x02C776 }, + { "Europe/Guernsey" , 0x02CBCD }, + { "Europe/Helsinki" , 0x02D104 }, + { "Europe/Isle_of_Man" , 0x02D3BA }, + { "Europe/Istanbul" , 0x02D8F1 }, + { "Europe/Jersey" , 0x02DCDE }, + { "Europe/Kaliningrad" , 0x02E215 }, + { "Europe/Kiev" , 0x02E477 }, + { "Europe/Lisbon" , 0x02E78E }, + { "Europe/Ljubljana" , 0x02EC92 }, + { "Europe/London" , 0x02EF5B }, + { "Europe/Luxembourg" , 0x02F492 }, + { "Europe/Madrid" , 0x02F8E8 }, + { "Europe/Malta" , 0x02FCAE }, + { "Europe/Mariehamn" , 0x030067 }, + { "Europe/Minsk" , 0x03031D }, + { "Europe/Monaco" , 0x030628 }, + { "Europe/Moscow" , 0x030A63 }, + { "Europe/Nicosia" , 0x030CB4 }, + { "Europe/Oslo" , 0x030F9C }, + { "Europe/Paris" , 0x0312CE }, + { "Europe/Podgorica" , 0x031714 }, + { "Europe/Prague" , 0x0319DD }, + { "Europe/Riga" , 0x031D0F }, + { "Europe/Rome" , 0x032054 }, + { "Europe/Samara" , 0x032417 }, + { "Europe/San_Marino" , 0x032647 }, + { "Europe/Sarajevo" , 0x032A0A }, + { "Europe/Simferopol" , 0x032CD3 }, + { "Europe/Skopje" , 0x032FFE }, + { "Europe/Sofia" , 0x0332C7 }, + { "Europe/Stockholm" , 0x0335CF }, + { "Europe/Tallinn" , 0x03387E }, + { "Europe/Tirane" , 0x033BB8 }, + { "Europe/Tiraspol" , 0x033EBE }, + { "Europe/Uzhgorod" , 0x03424C }, + { "Europe/Vaduz" , 0x034563 }, + { "Europe/Vatican" , 0x0347F6 }, + { "Europe/Vienna" , 0x034BB9 }, + { "Europe/Vilnius" , 0x034EE6 }, + { "Europe/Volgograd" , 0x035225 }, + { "Europe/Warsaw" , 0x035425 }, + { "Europe/Zagreb" , 0x035806 }, + { "Europe/Zaporozhye" , 0x035ACF }, + { "Europe/Zurich" , 0x035E10 }, + { "Factory" , 0x0360BF }, + { "GB" , 0x036130 }, + { "GB-Eire" , 0x036667 }, + { "GMT" , 0x036B9E }, + { "GMT+0" , 0x036C6A }, + { "GMT-0" , 0x036C26 }, + { "GMT0" , 0x036BE2 }, + { "Greenwich" , 0x036CAE }, + { "Hongkong" , 0x036CF2 }, + { "HST" , 0x036EB4 }, + { "Iceland" , 0x036EF8 }, + { "Indian/Antananarivo" , 0x0370B1 }, + { "Indian/Chagos" , 0x037125 }, + { "Indian/Christmas" , 0x037187 }, + { "Indian/Cocos" , 0x0371CB }, + { "Indian/Comoro" , 0x03720F }, + { "Indian/Kerguelen" , 0x037264 }, + { "Indian/Mahe" , 0x0372B9 }, + { "Indian/Maldives" , 0x03730E }, + { "Indian/Mauritius" , 0x037363 }, + { "Indian/Mayotte" , 0x0373D9 }, + { "Indian/Reunion" , 0x03742E }, + { "Iran" , 0x037483 }, + { "Israel" , 0x0376F1 }, + { "Jamaica" , 0x037A20 }, + { "Japan" , 0x037AE5 }, + { "Kwajalein" , 0x037B6E }, + { "Libya" , 0x037BD1 }, + { "MET" , 0x037CCB }, + { "Mexico/BajaNorte" , 0x037FD4 }, + { "Mexico/BajaSur" , 0x03833D }, + { "Mexico/General" , 0x038582 }, + { "MST" , 0x0387E0 }, + { "MST7MDT" , 0x038824 }, + { "Navajo" , 0x038B75 }, + { "NZ" , 0x038EEE }, + { "NZ-CHAT" , 0x03926C }, + { "Pacific/Apia" , 0x039554 }, + { "Pacific/Auckland" , 0x0395D2 }, + { "Pacific/Chatham" , 0x03995E }, + { "Pacific/Chuuk" , 0x039C55 }, + { "Pacific/Easter" , 0x039CAE }, + { "Pacific/Efate" , 0x03A00C }, + { "Pacific/Enderbury" , 0x03A0D2 }, + { "Pacific/Fakaofo" , 0x03A140 }, + { "Pacific/Fiji" , 0x03A184 }, + { "Pacific/Funafuti" , 0x03A20E }, + { "Pacific/Galapagos" , 0x03A252 }, + { "Pacific/Gambier" , 0x03A2CA }, + { "Pacific/Guadalcanal" , 0x03A32F }, + { "Pacific/Guam" , 0x03A384 }, + { "Pacific/Honolulu" , 0x03A3DA }, + { "Pacific/Johnston" , 0x03A451 }, + { "Pacific/Kiritimati" , 0x03A4A3 }, + { "Pacific/Kosrae" , 0x03A50E }, + { "Pacific/Kwajalein" , 0x03A56B }, + { "Pacific/Majuro" , 0x03A5D7 }, + { "Pacific/Marquesas" , 0x03A636 }, + { "Pacific/Midway" , 0x03A69D }, + { "Pacific/Nauru" , 0x03A727 }, + { "Pacific/Niue" , 0x03A79F }, + { "Pacific/Norfolk" , 0x03A7FD }, + { "Pacific/Noumea" , 0x03A852 }, + { "Pacific/Pago_Pago" , 0x03A8E2 }, + { "Pacific/Palau" , 0x03A96B }, + { "Pacific/Pitcairn" , 0x03A9AF }, + { "Pacific/Pohnpei" , 0x03AA04 }, + { "Pacific/Ponape" , 0x03AA59 }, + { "Pacific/Port_Moresby" , 0x03AA9E }, + { "Pacific/Rarotonga" , 0x03AAE2 }, + { "Pacific/Saipan" , 0x03ABBE }, + { "Pacific/Samoa" , 0x03AC21 }, + { "Pacific/Tahiti" , 0x03ACAA }, + { "Pacific/Tarawa" , 0x03AD0F }, + { "Pacific/Tongatapu" , 0x03AD63 }, + { "Pacific/Truk" , 0x03ADEF }, + { "Pacific/Wake" , 0x03AE34 }, + { "Pacific/Wallis" , 0x03AE84 }, + { "Pacific/Yap" , 0x03AEC8 }, + { "Poland" , 0x03AF0D }, + { "Portugal" , 0x03B2EE }, + { "PRC" , 0x03B7EA }, + { "PST8PDT" , 0x03B89B }, + { "ROC" , 0x03BBEC }, + { "ROK" , 0x03BD04 }, + { "Singapore" , 0x03BDA8 }, + { "Turkey" , 0x03BE5F }, + { "UCT" , 0x03C24C }, + { "Universal" , 0x03C290 }, + { "US/Alaska" , 0x03C2D4 }, + { "US/Aleutian" , 0x03C63D }, + { "US/Arizona" , 0x03C9A3 }, + { "US/Central" , 0x03CA31 }, + { "US/East-Indiana" , 0x03D43B }, + { "US/Eastern" , 0x03CF3C }, + { "US/Hawaii" , 0x03D6A5 }, + { "US/Indiana-Starke" , 0x03D716 }, + { "US/Michigan" , 0x03DA87 }, + { "US/Mountain" , 0x03DDBE }, + { "US/Pacific" , 0x03E137 }, + { "US/Pacific-New" , 0x03E53C }, + { "US/Samoa" , 0x03E941 }, + { "UTC" , 0x03E9CA }, + { "W-SU" , 0x03ECC1 }, + { "WET" , 0x03EA0E }, + { "Zulu" , 0x03EEFB }, }; /* This is a generated file, do not modify */ -const unsigned char timelib_timezone_db_data_builtin[262068] = { +const unsigned char timelib_timezone_db_data_builtin[257855] = { /* Africa/Abidjan */ @@ -2562,7 +2564,7 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x00, 0x00, 0x0B, 0x4D, 0x61, 0x74, 0x6F, 0x20, 0x47, 0x72, 0x6F, 0x73, 0x73, 0x6F, /* America/Curacao */ -0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x50, 0x48, 0x50, 0x31, 0x01, 0x43, 0x57, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x93, 0x1E, 0x2E, 0x20, 0xF6, 0x98, 0xEC, 0x48, 0x01, 0x02, 0xFF, 0xFF, 0xBF, 0x60, 0x00, 0x00, 0xFF, 0xFF, 0xC0, 0xB8, @@ -4247,6 +4249,15 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, +/* America/Kralendijk */ +0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x51, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x93, 0x1E, 0x2E, 0x20, +0xF6, 0x98, 0xEC, 0x48, 0x01, 0x02, 0xFF, 0xFF, 0xBF, 0x60, 0x00, 0x00, 0xFF, 0xFF, 0xC0, 0xB8, +0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x08, 0x4C, 0x4D, 0x54, 0x00, 0x41, 0x4E, 0x54, 0x00, +0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9B, 0xDE, 0xAB, 0x00, 0xAA, +0x79, 0xED, 0x00, 0x00, 0x00, 0x00, + /* America/La_Paz */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x4F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, @@ -4403,6 +4414,15 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, +/* America/Lower_Princes */ +0x50, 0x48, 0x50, 0x31, 0x01, 0x53, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x93, 0x1E, 0x2E, 0x20, +0xF6, 0x98, 0xEC, 0x48, 0x01, 0x02, 0xFF, 0xFF, 0xBF, 0x60, 0x00, 0x00, 0xFF, 0xFF, 0xC0, 0xB8, +0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x08, 0x4C, 0x4D, 0x54, 0x00, 0x41, 0x4E, 0x54, 0x00, +0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xA4, 0xDF, 0x92, 0x00, 0xB2, +0x74, 0xAD, 0x00, 0x00, 0x00, 0x00, + /* America/Maceio */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, @@ -7489,7 +7509,7 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Anadyr */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xAA, 0x19, 0x1D, 0x9C, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xAA, 0x19, 0x1D, 0x9C, 0xB5, 0xA3, 0x8C, 0xC0, 0x15, 0x27, 0x1B, 0x30, 0x16, 0x18, 0x4F, 0xA0, 0x17, 0x08, 0x4E, 0xB0, 0x17, 0xF9, 0x91, 0x30, 0x18, 0xE9, 0x90, 0x40, 0x19, 0xDA, 0xC4, 0xB0, 0x1A, 0xCC, 0x15, 0x40, 0x1B, 0xBC, 0x22, 0x60, 0x1C, 0xAC, 0x13, 0x60, 0x1D, 0x9C, 0x04, 0x60, 0x1E, 0x8B, 0xF5, 0x60, @@ -7505,35 +7525,19 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0x88, 0xE0, 0x41, 0x83, 0x9E, 0x60, 0x42, 0x45, 0x6A, 0xE0, 0x43, 0x63, 0x80, 0x60, 0x44, 0x25, 0x4C, 0xE0, 0x45, 0x43, 0x62, 0x60, 0x46, 0x05, 0x2E, 0xE0, 0x47, 0x23, 0x44, 0x60, 0x47, 0xEE, 0x4B, 0x60, 0x49, 0x03, 0x26, 0x60, 0x49, 0xCE, 0x2D, 0x60, 0x4A, 0xE3, 0x08, 0x60, -0x4B, 0xAE, 0x0F, 0x60, 0x4C, 0xCC, 0x32, 0xF0, 0x4D, 0x8D, 0xFF, 0x70, 0x4E, 0xAC, 0x14, 0xF0, -0x4F, 0x6D, 0xE1, 0x70, 0x50, 0x8B, 0xF6, 0xF0, 0x51, 0x56, 0xFD, 0xF0, 0x52, 0x6B, 0xD8, 0xF0, -0x53, 0x36, 0xDF, 0xF0, 0x54, 0x4B, 0xBA, 0xF0, 0x55, 0x16, 0xC1, 0xF0, 0x56, 0x2B, 0x9C, 0xF0, -0x56, 0xF6, 0xA3, 0xF0, 0x58, 0x14, 0xB9, 0x70, 0x58, 0xD6, 0x85, 0xF0, 0x59, 0xF4, 0x9B, 0x70, -0x5A, 0xB6, 0x67, 0xF0, 0x5B, 0xD4, 0x7D, 0x70, 0x5C, 0x9F, 0x84, 0x70, 0x5D, 0xB4, 0x5F, 0x70, -0x5E, 0x7F, 0x66, 0x70, 0x5F, 0x94, 0x41, 0x70, 0x60, 0x5F, 0x48, 0x70, 0x61, 0x7D, 0x5D, 0xF0, -0x62, 0x3F, 0x2A, 0x70, 0x63, 0x5D, 0x3F, 0xF0, 0x64, 0x1F, 0x0C, 0x70, 0x65, 0x3D, 0x21, 0xF0, -0x66, 0x08, 0x28, 0xF0, 0x67, 0x1D, 0x03, 0xF0, 0x67, 0xE8, 0x0A, 0xF0, 0x68, 0xFC, 0xE5, 0xF0, -0x69, 0xC7, 0xEC, 0xF0, 0x6A, 0xDC, 0xC7, 0xF0, 0x6B, 0xA7, 0xCE, 0xF0, 0x6C, 0xC5, 0xE4, 0x70, -0x6D, 0x87, 0xB0, 0xF0, 0x6E, 0xA5, 0xC6, 0x70, 0x6F, 0x67, 0x92, 0xF0, 0x70, 0x85, 0xA8, 0x70, -0x71, 0x50, 0xAF, 0x70, 0x72, 0x65, 0x8A, 0x70, 0x73, 0x30, 0x91, 0x70, 0x74, 0x45, 0x6C, 0x70, -0x75, 0x10, 0x73, 0x70, 0x76, 0x2E, 0x88, 0xF0, 0x76, 0xF0, 0x55, 0x70, 0x78, 0x0E, 0x6A, 0xF0, -0x78, 0xD0, 0x37, 0x70, 0x79, 0xEE, 0x4C, 0xF0, 0x7A, 0xB0, 0x19, 0x70, 0x7B, 0xCE, 0x2E, 0xF0, -0x7C, 0x99, 0x35, 0xF0, 0x7D, 0xAE, 0x10, 0xF0, 0x7E, 0x79, 0x17, 0xF0, 0x7F, 0x8D, 0xF2, 0xF0, -0x01, 0x03, 0x02, 0x03, 0x04, 0x01, 0x04, 0x01, 0x04, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, -0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x05, 0x04, 0x01, 0x06, 0x05, 0x06, 0x05, 0x06, +0x4B, 0xAE, 0x0F, 0x60, 0x4C, 0xCC, 0x32, 0xF0, 0x4D, 0x8D, 0xFF, 0x70, 0x01, 0x03, 0x02, 0x03, +0x04, 0x01, 0x04, 0x01, 0x04, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, +0x06, 0x05, 0x07, 0x08, 0x05, 0x04, 0x01, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, -0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x07, -0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, -0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, -0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, -0x08, 0x07, 0x08, 0x07, 0x08, 0x00, 0x00, 0xA6, 0x64, 0x00, 0x00, 0x00, 0x00, 0xA8, 0xC0, 0x00, -0x04, 0x00, 0x00, 0xC4, 0xE0, 0x01, 0x09, 0x00, 0x00, 0xB6, 0xD0, 0x00, 0x04, 0x00, 0x00, 0xB6, -0xD0, 0x01, 0x09, 0x00, 0x00, 0xA8, 0xC0, 0x00, 0x04, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, 0x00, -0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x41, -0x4E, 0x41, 0x54, 0x00, 0x41, 0x4E, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, -0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xEC, 0x21, 0x38, -0x02, 0x21, 0x79, 0xED, 0x00, 0x00, 0x00, 0x16, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, -0x38, 0x20, 0x2D, 0x20, 0x42, 0x65, 0x72, 0x69, 0x6E, 0x67, 0x20, 0x53, 0x65, 0x61, +0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x05, 0x00, 0x00, 0xA6, 0x64, +0x00, 0x00, 0x00, 0x00, 0xA8, 0xC0, 0x00, 0x04, 0x00, 0x00, 0xC4, 0xE0, 0x01, 0x09, 0x00, 0x00, +0xB6, 0xD0, 0x00, 0x04, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, 0x00, 0x00, 0xA8, 0xC0, 0x00, 0x04, +0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, 0x00, 0x9A, 0xB0, +0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x41, 0x4E, 0x41, 0x54, 0x00, 0x41, 0x4E, 0x41, 0x53, 0x54, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0xEC, 0x21, 0x38, 0x02, 0x21, 0x79, 0xED, 0x00, 0x00, 0x00, 0x16, 0x4D, +0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x38, 0x20, 0x2D, 0x20, 0x42, 0x65, 0x72, 0x69, 0x6E, +0x67, 0x20, 0x53, 0x65, 0x61, /* Asia/Aqtau */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x4B, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -8159,8 +8163,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Irkutsk */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xA2, 0x12, 0x0F, 0xB0, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xA2, 0x12, 0x0F, 0xB0, 0xB5, 0xA3, 0xD3, 0x10, 0x15, 0x27, 0x61, 0x80, 0x16, 0x18, 0x95, 0xF0, 0x17, 0x08, 0x95, 0x00, 0x17, 0xF9, 0xC9, 0x70, 0x18, 0xE9, 0xC8, 0x80, 0x19, 0xDA, 0xFC, 0xF0, 0x1A, 0xCC, 0x4D, 0x80, 0x1B, 0xBC, 0x5A, 0xA0, 0x1C, 0xAC, 0x4B, 0xA0, 0x1D, 0x9C, 0x3C, 0xA0, 0x1E, 0x8C, 0x2D, 0xA0, @@ -8176,35 +8180,19 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xC1, 0x20, 0x41, 0x83, 0xD6, 0xA0, 0x42, 0x45, 0xA3, 0x20, 0x43, 0x63, 0xB8, 0xA0, 0x44, 0x25, 0x85, 0x20, 0x45, 0x43, 0x9A, 0xA0, 0x46, 0x05, 0x67, 0x20, 0x47, 0x23, 0x7C, 0xA0, 0x47, 0xEE, 0x83, 0xA0, 0x49, 0x03, 0x5E, 0xA0, 0x49, 0xCE, 0x65, 0xA0, 0x4A, 0xE3, 0x40, 0xA0, -0x4B, 0xAE, 0x47, 0xA0, 0x4C, 0xCC, 0x5D, 0x20, 0x4D, 0x8E, 0x29, 0xA0, 0x4E, 0xAC, 0x3F, 0x20, -0x4F, 0x6E, 0x0B, 0xA0, 0x50, 0x8C, 0x21, 0x20, 0x51, 0x57, 0x28, 0x20, 0x52, 0x6C, 0x03, 0x20, -0x53, 0x37, 0x0A, 0x20, 0x54, 0x4B, 0xE5, 0x20, 0x55, 0x16, 0xEC, 0x20, 0x56, 0x2B, 0xC7, 0x20, -0x56, 0xF6, 0xCE, 0x20, 0x58, 0x14, 0xE3, 0xA0, 0x58, 0xD6, 0xB0, 0x20, 0x59, 0xF4, 0xC5, 0xA0, -0x5A, 0xB6, 0x92, 0x20, 0x5B, 0xD4, 0xA7, 0xA0, 0x5C, 0x9F, 0xAE, 0xA0, 0x5D, 0xB4, 0x89, 0xA0, -0x5E, 0x7F, 0x90, 0xA0, 0x5F, 0x94, 0x6B, 0xA0, 0x60, 0x5F, 0x72, 0xA0, 0x61, 0x7D, 0x88, 0x20, -0x62, 0x3F, 0x54, 0xA0, 0x63, 0x5D, 0x6A, 0x20, 0x64, 0x1F, 0x36, 0xA0, 0x65, 0x3D, 0x4C, 0x20, -0x66, 0x08, 0x53, 0x20, 0x67, 0x1D, 0x2E, 0x20, 0x67, 0xE8, 0x35, 0x20, 0x68, 0xFD, 0x10, 0x20, -0x69, 0xC8, 0x17, 0x20, 0x6A, 0xDC, 0xF2, 0x20, 0x6B, 0xA7, 0xF9, 0x20, 0x6C, 0xC6, 0x0E, 0xA0, -0x6D, 0x87, 0xDB, 0x20, 0x6E, 0xA5, 0xF0, 0xA0, 0x6F, 0x67, 0xBD, 0x20, 0x70, 0x85, 0xD2, 0xA0, -0x71, 0x50, 0xD9, 0xA0, 0x72, 0x65, 0xB4, 0xA0, 0x73, 0x30, 0xBB, 0xA0, 0x74, 0x45, 0x96, 0xA0, -0x75, 0x10, 0x9D, 0xA0, 0x76, 0x2E, 0xB3, 0x20, 0x76, 0xF0, 0x7F, 0xA0, 0x78, 0x0E, 0x95, 0x20, -0x78, 0xD0, 0x61, 0xA0, 0x79, 0xEE, 0x77, 0x20, 0x7A, 0xB0, 0x43, 0xA0, 0x7B, 0xCE, 0x59, 0x20, -0x7C, 0x99, 0x60, 0x20, 0x7D, 0xAE, 0x3B, 0x20, 0x7E, 0x79, 0x42, 0x20, 0x7F, 0x8E, 0x1D, 0x20, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x47, 0xA0, 0x4C, 0xCC, 0x5D, 0x20, 0x4D, 0x8E, 0x29, 0xA0, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x00, 0x00, 0x61, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x62, 0x70, 0x00, -0x04, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x09, 0x00, 0x00, 0x70, 0x80, 0x00, 0x04, 0x00, 0x00, 0x70, -0x80, 0x00, 0x04, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x09, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, -0x00, 0x62, 0x70, 0x00, 0x04, 0x49, 0x4D, 0x54, 0x00, 0x49, 0x52, 0x4B, 0x54, 0x00, 0x49, 0x52, -0x4B, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xD9, 0x14, 0xEA, 0x01, 0xB1, 0xDB, 0xB5, 0x00, 0x00, 0x00, 0x17, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x35, 0x20, 0x2D, 0x20, 0x4C, 0x61, 0x6B, 0x65, -0x20, 0x42, 0x61, 0x69, 0x6B, 0x61, 0x6C, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x00, 0x00, 0x61, 0xD0, +0x00, 0x00, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x09, 0x00, 0x00, +0x70, 0x80, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x00, 0x04, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x09, +0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x7E, 0x90, +0x00, 0x04, 0x49, 0x4D, 0x54, 0x00, 0x49, 0x52, 0x4B, 0x54, 0x00, 0x49, 0x52, 0x4B, 0x53, 0x54, +0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0xD9, 0x14, 0xEA, 0x01, 0xB1, 0xDB, 0xB5, 0x00, 0x00, 0x00, 0x17, 0x4D, +0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x35, 0x20, 0x2D, 0x20, 0x4C, 0x61, 0x6B, 0x65, 0x20, +0x42, 0x61, 0x69, 0x6B, 0x61, 0x6C, /* Asia/Istanbul */ 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -8360,7 +8348,7 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Kamchatka */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xA7, 0x52, 0x96, 0xC4, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xA7, 0x52, 0x96, 0xC4, 0xB5, 0xA3, 0x9A, 0xD0, 0x15, 0x27, 0x29, 0x40, 0x16, 0x18, 0x5D, 0xB0, 0x17, 0x08, 0x5C, 0xC0, 0x17, 0xF9, 0x91, 0x30, 0x18, 0xE9, 0x90, 0x40, 0x19, 0xDA, 0xC4, 0xB0, 0x1A, 0xCC, 0x15, 0x40, 0x1B, 0xBC, 0x22, 0x60, 0x1C, 0xAC, 0x13, 0x60, 0x1D, 0x9C, 0x04, 0x60, 0x1E, 0x8B, 0xF5, 0x60, @@ -8376,35 +8364,18 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0x88, 0xE0, 0x41, 0x83, 0x9E, 0x60, 0x42, 0x45, 0x6A, 0xE0, 0x43, 0x63, 0x80, 0x60, 0x44, 0x25, 0x4C, 0xE0, 0x45, 0x43, 0x62, 0x60, 0x46, 0x05, 0x2E, 0xE0, 0x47, 0x23, 0x44, 0x60, 0x47, 0xEE, 0x4B, 0x60, 0x49, 0x03, 0x26, 0x60, 0x49, 0xCE, 0x2D, 0x60, 0x4A, 0xE3, 0x08, 0x60, -0x4B, 0xAE, 0x0F, 0x60, 0x4C, 0xCC, 0x32, 0xF0, 0x4D, 0x8D, 0xFF, 0x70, 0x4E, 0xAC, 0x14, 0xF0, -0x4F, 0x6D, 0xE1, 0x70, 0x50, 0x8B, 0xF6, 0xF0, 0x51, 0x56, 0xFD, 0xF0, 0x52, 0x6B, 0xD8, 0xF0, -0x53, 0x36, 0xDF, 0xF0, 0x54, 0x4B, 0xBA, 0xF0, 0x55, 0x16, 0xC1, 0xF0, 0x56, 0x2B, 0x9C, 0xF0, -0x56, 0xF6, 0xA3, 0xF0, 0x58, 0x14, 0xB9, 0x70, 0x58, 0xD6, 0x85, 0xF0, 0x59, 0xF4, 0x9B, 0x70, -0x5A, 0xB6, 0x67, 0xF0, 0x5B, 0xD4, 0x7D, 0x70, 0x5C, 0x9F, 0x84, 0x70, 0x5D, 0xB4, 0x5F, 0x70, -0x5E, 0x7F, 0x66, 0x70, 0x5F, 0x94, 0x41, 0x70, 0x60, 0x5F, 0x48, 0x70, 0x61, 0x7D, 0x5D, 0xF0, -0x62, 0x3F, 0x2A, 0x70, 0x63, 0x5D, 0x3F, 0xF0, 0x64, 0x1F, 0x0C, 0x70, 0x65, 0x3D, 0x21, 0xF0, -0x66, 0x08, 0x28, 0xF0, 0x67, 0x1D, 0x03, 0xF0, 0x67, 0xE8, 0x0A, 0xF0, 0x68, 0xFC, 0xE5, 0xF0, -0x69, 0xC7, 0xEC, 0xF0, 0x6A, 0xDC, 0xC7, 0xF0, 0x6B, 0xA7, 0xCE, 0xF0, 0x6C, 0xC5, 0xE4, 0x70, -0x6D, 0x87, 0xB0, 0xF0, 0x6E, 0xA5, 0xC6, 0x70, 0x6F, 0x67, 0x92, 0xF0, 0x70, 0x85, 0xA8, 0x70, -0x71, 0x50, 0xAF, 0x70, 0x72, 0x65, 0x8A, 0x70, 0x73, 0x30, 0x91, 0x70, 0x74, 0x45, 0x6C, 0x70, -0x75, 0x10, 0x73, 0x70, 0x76, 0x2E, 0x88, 0xF0, 0x76, 0xF0, 0x55, 0x70, 0x78, 0x0E, 0x6A, 0xF0, -0x78, 0xD0, 0x37, 0x70, 0x79, 0xEE, 0x4C, 0xF0, 0x7A, 0xB0, 0x19, 0x70, 0x7B, 0xCE, 0x2E, 0xF0, -0x7C, 0x99, 0x35, 0xF0, 0x7D, 0xAE, 0x10, 0xF0, 0x7E, 0x79, 0x17, 0xF0, 0x7F, 0x8D, 0xF2, 0xF0, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x0F, 0x60, 0x4C, 0xCC, 0x32, 0xF0, 0x4D, 0x8D, 0xFF, 0x70, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x06, -0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, -0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, -0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, -0x07, 0x06, 0x07, 0x06, 0x07, 0x00, 0x00, 0x94, 0xBC, 0x00, 0x00, 0x00, 0x00, 0x9A, 0xB0, 0x00, -0x04, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, 0x00, 0x00, 0xA8, 0xC0, 0x00, 0x04, 0x00, 0x00, 0xA8, -0xC0, 0x00, 0x04, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, -0x00, 0x9A, 0xB0, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x50, 0x45, 0x54, 0x54, 0x00, 0x50, 0x45, -0x54, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xDA, 0x39, 0xE2, 0x02, 0x04, 0xBD, 0x28, 0x00, 0x00, 0x00, 0x15, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x38, 0x20, 0x2D, 0x20, 0x4B, 0x61, 0x6D, 0x63, -0x68, 0x61, 0x74, 0x6B, 0x61, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x00, 0x00, 0x94, 0xBC, +0x00, 0x00, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x04, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, 0x00, 0x00, +0xA8, 0xC0, 0x00, 0x04, 0x00, 0x00, 0xA8, 0xC0, 0x00, 0x04, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x09, +0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, +0x50, 0x45, 0x54, 0x54, 0x00, 0x50, 0x45, 0x54, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, +0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xDA, 0x39, 0xE2, 0x02, +0x04, 0xBD, 0x28, 0x00, 0x00, 0x00, 0x15, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x38, +0x20, 0x2D, 0x20, 0x4B, 0x61, 0x6D, 0x63, 0x68, 0x61, 0x74, 0x6B, 0x61, /* Asia/Karachi */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x50, 0x4B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -8466,8 +8437,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Krasnoyarsk */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xF9, 0x0D, 0xF8, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xF9, 0x0D, 0xF8, 0xB5, 0xA3, 0xE1, 0x20, 0x15, 0x27, 0x6F, 0x90, 0x16, 0x18, 0xA4, 0x00, 0x17, 0x08, 0xA3, 0x10, 0x17, 0xF9, 0xD7, 0x80, 0x18, 0xE9, 0xD6, 0x90, 0x19, 0xDB, 0x0B, 0x00, 0x1A, 0xCC, 0x5B, 0x90, 0x1B, 0xBC, 0x68, 0xB0, 0x1C, 0xAC, 0x59, 0xB0, 0x1D, 0x9C, 0x4A, 0xB0, 0x1E, 0x8C, 0x3B, 0xB0, @@ -8483,35 +8454,19 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xCF, 0x30, 0x41, 0x83, 0xE4, 0xB0, 0x42, 0x45, 0xB1, 0x30, 0x43, 0x63, 0xC6, 0xB0, 0x44, 0x25, 0x93, 0x30, 0x45, 0x43, 0xA8, 0xB0, 0x46, 0x05, 0x75, 0x30, 0x47, 0x23, 0x8A, 0xB0, 0x47, 0xEE, 0x91, 0xB0, 0x49, 0x03, 0x6C, 0xB0, 0x49, 0xCE, 0x73, 0xB0, 0x4A, 0xE3, 0x4E, 0xB0, -0x4B, 0xAE, 0x55, 0xB0, 0x4C, 0xCC, 0x6B, 0x30, 0x4D, 0x8E, 0x37, 0xB0, 0x4E, 0xAC, 0x4D, 0x30, -0x4F, 0x6E, 0x19, 0xB0, 0x50, 0x8C, 0x2F, 0x30, 0x51, 0x57, 0x36, 0x30, 0x52, 0x6C, 0x11, 0x30, -0x53, 0x37, 0x18, 0x30, 0x54, 0x4B, 0xF3, 0x30, 0x55, 0x16, 0xFA, 0x30, 0x56, 0x2B, 0xD5, 0x30, -0x56, 0xF6, 0xDC, 0x30, 0x58, 0x14, 0xF1, 0xB0, 0x58, 0xD6, 0xBE, 0x30, 0x59, 0xF4, 0xD3, 0xB0, -0x5A, 0xB6, 0xA0, 0x30, 0x5B, 0xD4, 0xB5, 0xB0, 0x5C, 0x9F, 0xBC, 0xB0, 0x5D, 0xB4, 0x97, 0xB0, -0x5E, 0x7F, 0x9E, 0xB0, 0x5F, 0x94, 0x79, 0xB0, 0x60, 0x5F, 0x80, 0xB0, 0x61, 0x7D, 0x96, 0x30, -0x62, 0x3F, 0x62, 0xB0, 0x63, 0x5D, 0x78, 0x30, 0x64, 0x1F, 0x44, 0xB0, 0x65, 0x3D, 0x5A, 0x30, -0x66, 0x08, 0x61, 0x30, 0x67, 0x1D, 0x3C, 0x30, 0x67, 0xE8, 0x43, 0x30, 0x68, 0xFD, 0x1E, 0x30, -0x69, 0xC8, 0x25, 0x30, 0x6A, 0xDD, 0x00, 0x30, 0x6B, 0xA8, 0x07, 0x30, 0x6C, 0xC6, 0x1C, 0xB0, -0x6D, 0x87, 0xE9, 0x30, 0x6E, 0xA5, 0xFE, 0xB0, 0x6F, 0x67, 0xCB, 0x30, 0x70, 0x85, 0xE0, 0xB0, -0x71, 0x50, 0xE7, 0xB0, 0x72, 0x65, 0xC2, 0xB0, 0x73, 0x30, 0xC9, 0xB0, 0x74, 0x45, 0xA4, 0xB0, -0x75, 0x10, 0xAB, 0xB0, 0x76, 0x2E, 0xC1, 0x30, 0x76, 0xF0, 0x8D, 0xB0, 0x78, 0x0E, 0xA3, 0x30, -0x78, 0xD0, 0x6F, 0xB0, 0x79, 0xEE, 0x85, 0x30, 0x7A, 0xB0, 0x51, 0xB0, 0x7B, 0xCE, 0x67, 0x30, -0x7C, 0x99, 0x6E, 0x30, 0x7D, 0xAE, 0x49, 0x30, 0x7E, 0x79, 0x50, 0x30, 0x7F, 0x8E, 0x2B, 0x30, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x55, 0xB0, 0x4C, 0xCC, 0x6B, 0x30, 0x4D, 0x8E, 0x37, 0xB0, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x00, 0x00, 0x57, 0x08, 0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, -0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, -0x70, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, -0x00, 0x54, 0x60, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, -0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xDE, 0xCD, 0xC2, 0x01, 0xA0, 0x4F, 0x85, 0x00, 0x00, 0x00, 0x19, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x34, 0x20, 0x2D, 0x20, 0x59, 0x65, 0x6E, 0x69, -0x73, 0x65, 0x69, 0x20, 0x52, 0x69, 0x76, 0x65, 0x72, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x00, 0x00, 0x57, 0x08, +0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, +0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, +0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, +0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x53, 0x54, +0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0xDE, 0xCD, 0xC2, 0x01, 0xA0, 0x4F, 0x85, 0x00, 0x00, 0x00, 0x19, 0x4D, +0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x34, 0x20, 0x2D, 0x20, 0x59, 0x65, 0x6E, 0x69, 0x73, +0x65, 0x69, 0x20, 0x52, 0x69, 0x76, 0x65, 0x72, /* Asia/Kuala_Lumpur */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x4D, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -8598,8 +8553,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Magadan */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xAA, 0x19, 0x36, 0xA0, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xAA, 0x19, 0x36, 0xA0, 0xB5, 0xA3, 0xA8, 0xE0, 0x15, 0x27, 0x37, 0x50, 0x16, 0x18, 0x6B, 0xC0, 0x17, 0x08, 0x6A, 0xD0, 0x17, 0xF9, 0x9F, 0x40, 0x18, 0xE9, 0x9E, 0x50, 0x19, 0xDA, 0xD2, 0xC0, 0x1A, 0xCC, 0x23, 0x50, 0x1B, 0xBC, 0x30, 0x70, 0x1C, 0xAC, 0x21, 0x70, 0x1D, 0x9C, 0x12, 0x70, 0x1E, 0x8C, 0x03, 0x70, @@ -8615,35 +8570,19 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0x96, 0xF0, 0x41, 0x83, 0xAC, 0x70, 0x42, 0x45, 0x78, 0xF0, 0x43, 0x63, 0x8E, 0x70, 0x44, 0x25, 0x5A, 0xF0, 0x45, 0x43, 0x70, 0x70, 0x46, 0x05, 0x3C, 0xF0, 0x47, 0x23, 0x52, 0x70, 0x47, 0xEE, 0x59, 0x70, 0x49, 0x03, 0x34, 0x70, 0x49, 0xCE, 0x3B, 0x70, 0x4A, 0xE3, 0x16, 0x70, -0x4B, 0xAE, 0x1D, 0x70, 0x4C, 0xCC, 0x32, 0xF0, 0x4D, 0x8D, 0xFF, 0x70, 0x4E, 0xAC, 0x14, 0xF0, -0x4F, 0x6D, 0xE1, 0x70, 0x50, 0x8B, 0xF6, 0xF0, 0x51, 0x56, 0xFD, 0xF0, 0x52, 0x6B, 0xD8, 0xF0, -0x53, 0x36, 0xDF, 0xF0, 0x54, 0x4B, 0xBA, 0xF0, 0x55, 0x16, 0xC1, 0xF0, 0x56, 0x2B, 0x9C, 0xF0, -0x56, 0xF6, 0xA3, 0xF0, 0x58, 0x14, 0xB9, 0x70, 0x58, 0xD6, 0x85, 0xF0, 0x59, 0xF4, 0x9B, 0x70, -0x5A, 0xB6, 0x67, 0xF0, 0x5B, 0xD4, 0x7D, 0x70, 0x5C, 0x9F, 0x84, 0x70, 0x5D, 0xB4, 0x5F, 0x70, -0x5E, 0x7F, 0x66, 0x70, 0x5F, 0x94, 0x41, 0x70, 0x60, 0x5F, 0x48, 0x70, 0x61, 0x7D, 0x5D, 0xF0, -0x62, 0x3F, 0x2A, 0x70, 0x63, 0x5D, 0x3F, 0xF0, 0x64, 0x1F, 0x0C, 0x70, 0x65, 0x3D, 0x21, 0xF0, -0x66, 0x08, 0x28, 0xF0, 0x67, 0x1D, 0x03, 0xF0, 0x67, 0xE8, 0x0A, 0xF0, 0x68, 0xFC, 0xE5, 0xF0, -0x69, 0xC7, 0xEC, 0xF0, 0x6A, 0xDC, 0xC7, 0xF0, 0x6B, 0xA7, 0xCE, 0xF0, 0x6C, 0xC5, 0xE4, 0x70, -0x6D, 0x87, 0xB0, 0xF0, 0x6E, 0xA5, 0xC6, 0x70, 0x6F, 0x67, 0x92, 0xF0, 0x70, 0x85, 0xA8, 0x70, -0x71, 0x50, 0xAF, 0x70, 0x72, 0x65, 0x8A, 0x70, 0x73, 0x30, 0x91, 0x70, 0x74, 0x45, 0x6C, 0x70, -0x75, 0x10, 0x73, 0x70, 0x76, 0x2E, 0x88, 0xF0, 0x76, 0xF0, 0x55, 0x70, 0x78, 0x0E, 0x6A, 0xF0, -0x78, 0xD0, 0x37, 0x70, 0x79, 0xEE, 0x4C, 0xF0, 0x7A, 0xB0, 0x19, 0x70, 0x7B, 0xCE, 0x2E, 0xF0, -0x7C, 0x99, 0x35, 0xF0, 0x7D, 0xAE, 0x10, 0xF0, 0x7E, 0x79, 0x17, 0xF0, 0x7F, 0x8D, 0xF2, 0xF0, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x1D, 0x70, 0x4C, 0xCC, 0x32, 0xF0, 0x4D, 0x8D, 0xFF, 0x70, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x00, 0x00, 0x8D, 0x60, 0x00, 0x00, 0x00, 0x00, 0x8C, 0xA0, 0x00, -0x04, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x04, 0x00, 0x00, 0x9A, -0xB0, 0x00, 0x04, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x09, 0x00, -0x00, 0x8C, 0xA0, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x4D, 0x41, 0x47, 0x54, 0x00, 0x4D, 0x41, -0x47, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xE4, 0x38, 0x7A, 0x01, 0xF8, 0xC2, 0xC0, 0x00, 0x00, 0x00, 0x13, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x38, 0x20, 0x2D, 0x20, 0x4D, 0x61, 0x67, 0x61, -0x64, 0x61, 0x6E, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x00, 0x00, 0x8D, 0x60, +0x00, 0x00, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x04, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, 0x00, 0x00, +0x9A, 0xB0, 0x00, 0x04, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x04, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x09, +0x00, 0x00, 0x9A, 0xB0, 0x01, 0x09, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x04, 0x00, 0x00, 0xA8, 0xC0, +0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x4D, 0x41, 0x47, 0x54, 0x00, 0x4D, 0x41, 0x47, 0x53, 0x54, +0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0xE4, 0x38, 0x7A, 0x01, 0xF8, 0xC2, 0xC0, 0x00, 0x00, 0x00, 0x13, 0x4D, +0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x38, 0x20, 0x2D, 0x20, 0x4D, 0x61, 0x67, 0x61, 0x64, +0x61, 0x6E, /* Asia/Makassar */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x49, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -8730,8 +8669,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Novokuznetsk */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0xF9, 0x13, 0x40, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0xF9, 0x13, 0x40, 0xB5, 0xA3, 0xE1, 0x20, 0x15, 0x27, 0x6F, 0x90, 0x16, 0x18, 0xA4, 0x00, 0x17, 0x08, 0xA3, 0x10, 0x17, 0xF9, 0xD7, 0x80, 0x18, 0xE9, 0xD6, 0x90, 0x19, 0xDB, 0x0B, 0x00, 0x1A, 0xCC, 0x5B, 0x90, 0x1B, 0xBC, 0x68, 0xB0, 0x1C, 0xAC, 0x59, 0xB0, 0x1D, 0x9C, 0x4A, 0xB0, 0x1E, 0x8C, 0x3B, 0xB0, @@ -8747,42 +8686,26 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xCF, 0x30, 0x41, 0x83, 0xE4, 0xB0, 0x42, 0x45, 0xB1, 0x30, 0x43, 0x63, 0xC6, 0xB0, 0x44, 0x25, 0x93, 0x30, 0x45, 0x43, 0xA8, 0xB0, 0x46, 0x05, 0x75, 0x30, 0x47, 0x23, 0x8A, 0xB0, 0x47, 0xEE, 0x91, 0xB0, 0x49, 0x03, 0x6C, 0xB0, 0x49, 0xCE, 0x73, 0xB0, 0x4A, 0xE3, 0x4E, 0xB0, -0x4B, 0xAE, 0x55, 0xB0, 0x4C, 0xCC, 0x79, 0x40, 0x4D, 0x8E, 0x45, 0xC0, 0x4E, 0xAC, 0x5B, 0x40, -0x4F, 0x6E, 0x27, 0xC0, 0x50, 0x8C, 0x3D, 0x40, 0x51, 0x57, 0x44, 0x40, 0x52, 0x6C, 0x1F, 0x40, -0x53, 0x37, 0x26, 0x40, 0x54, 0x4C, 0x01, 0x40, 0x55, 0x17, 0x08, 0x40, 0x56, 0x2B, 0xE3, 0x40, -0x56, 0xF6, 0xEA, 0x40, 0x58, 0x14, 0xFF, 0xC0, 0x58, 0xD6, 0xCC, 0x40, 0x59, 0xF4, 0xE1, 0xC0, -0x5A, 0xB6, 0xAE, 0x40, 0x5B, 0xD4, 0xC3, 0xC0, 0x5C, 0x9F, 0xCA, 0xC0, 0x5D, 0xB4, 0xA5, 0xC0, -0x5E, 0x7F, 0xAC, 0xC0, 0x5F, 0x94, 0x87, 0xC0, 0x60, 0x5F, 0x8E, 0xC0, 0x61, 0x7D, 0xA4, 0x40, -0x62, 0x3F, 0x70, 0xC0, 0x63, 0x5D, 0x86, 0x40, 0x64, 0x1F, 0x52, 0xC0, 0x65, 0x3D, 0x68, 0x40, -0x66, 0x08, 0x6F, 0x40, 0x67, 0x1D, 0x4A, 0x40, 0x67, 0xE8, 0x51, 0x40, 0x68, 0xFD, 0x2C, 0x40, -0x69, 0xC8, 0x33, 0x40, 0x6A, 0xDD, 0x0E, 0x40, 0x6B, 0xA8, 0x15, 0x40, 0x6C, 0xC6, 0x2A, 0xC0, -0x6D, 0x87, 0xF7, 0x40, 0x6E, 0xA6, 0x0C, 0xC0, 0x6F, 0x67, 0xD9, 0x40, 0x70, 0x85, 0xEE, 0xC0, -0x71, 0x50, 0xF5, 0xC0, 0x72, 0x65, 0xD0, 0xC0, 0x73, 0x30, 0xD7, 0xC0, 0x74, 0x45, 0xB2, 0xC0, -0x75, 0x10, 0xB9, 0xC0, 0x76, 0x2E, 0xCF, 0x40, 0x76, 0xF0, 0x9B, 0xC0, 0x78, 0x0E, 0xB1, 0x40, -0x78, 0xD0, 0x7D, 0xC0, 0x79, 0xEE, 0x93, 0x40, 0x7A, 0xB0, 0x5F, 0xC0, 0x7B, 0xCE, 0x75, 0x40, -0x7C, 0x99, 0x7C, 0x40, 0x7D, 0xAE, 0x57, 0x40, 0x7E, 0x79, 0x5E, 0x40, 0x7F, 0x8E, 0x39, 0x40, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x55, 0xB0, 0x4C, 0xCC, 0x79, 0x40, 0x4D, 0x8E, 0x45, 0xC0, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x00, 0x00, 0x51, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, -0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, -0x70, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, -0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x0F, 0x00, 0x00, 0x54, 0x60, 0x00, -0x15, 0x4E, 0x4D, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x53, 0x54, 0x00, -0x4E, 0x4F, 0x56, 0x53, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, -0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0xDB, 0x58, 0x58, 0x01, 0x97, 0x96, 0x72, 0x00, 0x00, 0x00, 0x18, 0x4D, 0x6F, 0x73, 0x63, 0x6F, -0x77, 0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, 0x4E, 0x6F, 0x76, 0x6F, 0x6B, 0x75, 0x7A, 0x6E, 0x65, -0x74, 0x73, 0x6B, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x09, 0x0A, 0x00, 0x00, 0x51, 0xC0, +0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, +0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, +0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, +0x01, 0x0F, 0x00, 0x00, 0x54, 0x60, 0x00, 0x15, 0x00, 0x00, 0x62, 0x70, 0x00, 0x15, 0x4E, 0x4D, +0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x53, 0x54, 0x00, 0x4E, 0x4F, 0x56, +0x53, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, +0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xDB, +0x58, 0x58, 0x01, 0x97, 0x96, 0x72, 0x00, 0x00, 0x00, 0x18, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, +0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, 0x4E, 0x6F, 0x76, 0x6F, 0x6B, 0x75, 0x7A, 0x6E, 0x65, 0x74, +0x73, 0x6B, /* Asia/Novosibirsk */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x76, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xDB, 0x19, 0x24, +0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xDB, 0x19, 0x24, 0xB5, 0xA3, 0xE1, 0x20, 0x15, 0x27, 0x6F, 0x90, 0x16, 0x18, 0xA4, 0x00, 0x17, 0x08, 0xA3, 0x10, 0x17, 0xF9, 0xD7, 0x80, 0x18, 0xE9, 0xD6, 0x90, 0x19, 0xDB, 0x0B, 0x00, 0x1A, 0xCC, 0x5B, 0x90, 0x1B, 0xBC, 0x68, 0xB0, 0x1C, 0xAC, 0x59, 0xB0, 0x1D, 0x9C, 0x4A, 0xB0, 0x1E, 0x8C, 0x3B, 0xB0, @@ -8799,40 +8722,23 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x43, 0x63, 0xD4, 0xC0, 0x44, 0x25, 0xA1, 0x40, 0x45, 0x43, 0xB6, 0xC0, 0x46, 0x05, 0x83, 0x40, 0x47, 0x23, 0x98, 0xC0, 0x47, 0xEE, 0x9F, 0xC0, 0x49, 0x03, 0x7A, 0xC0, 0x49, 0xCE, 0x81, 0xC0, 0x4A, 0xE3, 0x5C, 0xC0, 0x4B, 0xAE, 0x63, 0xC0, 0x4C, 0xCC, 0x79, 0x40, 0x4D, 0x8E, 0x45, 0xC0, -0x4E, 0xAC, 0x5B, 0x40, 0x4F, 0x6E, 0x27, 0xC0, 0x50, 0x8C, 0x3D, 0x40, 0x51, 0x57, 0x44, 0x40, -0x52, 0x6C, 0x1F, 0x40, 0x53, 0x37, 0x26, 0x40, 0x54, 0x4C, 0x01, 0x40, 0x55, 0x17, 0x08, 0x40, -0x56, 0x2B, 0xE3, 0x40, 0x56, 0xF6, 0xEA, 0x40, 0x58, 0x14, 0xFF, 0xC0, 0x58, 0xD6, 0xCC, 0x40, -0x59, 0xF4, 0xE1, 0xC0, 0x5A, 0xB6, 0xAE, 0x40, 0x5B, 0xD4, 0xC3, 0xC0, 0x5C, 0x9F, 0xCA, 0xC0, -0x5D, 0xB4, 0xA5, 0xC0, 0x5E, 0x7F, 0xAC, 0xC0, 0x5F, 0x94, 0x87, 0xC0, 0x60, 0x5F, 0x8E, 0xC0, -0x61, 0x7D, 0xA4, 0x40, 0x62, 0x3F, 0x70, 0xC0, 0x63, 0x5D, 0x86, 0x40, 0x64, 0x1F, 0x52, 0xC0, -0x65, 0x3D, 0x68, 0x40, 0x66, 0x08, 0x6F, 0x40, 0x67, 0x1D, 0x4A, 0x40, 0x67, 0xE8, 0x51, 0x40, -0x68, 0xFD, 0x2C, 0x40, 0x69, 0xC8, 0x33, 0x40, 0x6A, 0xDD, 0x0E, 0x40, 0x6B, 0xA8, 0x15, 0x40, -0x6C, 0xC6, 0x2A, 0xC0, 0x6D, 0x87, 0xF7, 0x40, 0x6E, 0xA6, 0x0C, 0xC0, 0x6F, 0x67, 0xD9, 0x40, -0x70, 0x85, 0xEE, 0xC0, 0x71, 0x50, 0xF5, 0xC0, 0x72, 0x65, 0xD0, 0xC0, 0x73, 0x30, 0xD7, 0xC0, -0x74, 0x45, 0xB2, 0xC0, 0x75, 0x10, 0xB9, 0xC0, 0x76, 0x2E, 0xCF, 0x40, 0x76, 0xF0, 0x9B, 0xC0, -0x78, 0x0E, 0xB1, 0x40, 0x78, 0xD0, 0x7D, 0xC0, 0x79, 0xEE, 0x93, 0x40, 0x7A, 0xB0, 0x5F, 0xC0, -0x7B, 0xCE, 0x75, 0x40, 0x7C, 0x99, 0x7C, 0x40, 0x7D, 0xAE, 0x57, 0x40, 0x7E, 0x79, 0x5E, 0x40, -0x7F, 0x8E, 0x39, 0x40, 0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, -0x08, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, -0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, -0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, +0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x08, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, -0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x00, 0x00, 0x4D, 0xBC, 0x00, 0x00, -0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, -0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, -0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, -0x4C, 0x4D, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x53, 0x54, 0x00, 0x00, -0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0xDD, 0x4D, 0xA5, 0x01, 0x91, 0x2D, 0xD2, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, -0x63, 0x6F, 0x77, 0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, 0x4E, 0x6F, 0x76, 0x6F, 0x73, 0x69, 0x62, -0x69, 0x72, 0x73, 0x6B, +0x04, 0x00, 0x00, 0x4D, 0xBC, 0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x70, +0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, +0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x00, +0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x54, 0x00, +0x4E, 0x4F, 0x56, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xDD, 0x4D, 0xA5, 0x01, 0x91, 0x2D, 0xD2, +0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, +0x4E, 0x6F, 0x76, 0x6F, 0x73, 0x69, 0x62, 0x69, 0x72, 0x73, 0x6B, /* Asia/Omsk */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xB3, 0x40, 0xB0, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xB3, 0x40, 0xB0, 0xB5, 0xA3, 0xEF, 0x30, 0x15, 0x27, 0x7D, 0xA0, 0x16, 0x18, 0xB2, 0x10, 0x17, 0x08, 0xB1, 0x20, 0x17, 0xF9, 0xE5, 0x90, 0x18, 0xE9, 0xE4, 0xA0, 0x19, 0xDB, 0x19, 0x10, 0x1A, 0xCC, 0x69, 0xA0, 0x1B, 0xBC, 0x76, 0xC0, 0x1C, 0xAC, 0x67, 0xC0, 0x1D, 0x9C, 0x58, 0xC0, 0x1E, 0x8C, 0x49, 0xC0, @@ -8848,35 +8754,19 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xDD, 0x40, 0x41, 0x83, 0xF2, 0xC0, 0x42, 0x45, 0xBF, 0x40, 0x43, 0x63, 0xD4, 0xC0, 0x44, 0x25, 0xA1, 0x40, 0x45, 0x43, 0xB6, 0xC0, 0x46, 0x05, 0x83, 0x40, 0x47, 0x23, 0x98, 0xC0, 0x47, 0xEE, 0x9F, 0xC0, 0x49, 0x03, 0x7A, 0xC0, 0x49, 0xCE, 0x81, 0xC0, 0x4A, 0xE3, 0x5C, 0xC0, -0x4B, 0xAE, 0x63, 0xC0, 0x4C, 0xCC, 0x79, 0x40, 0x4D, 0x8E, 0x45, 0xC0, 0x4E, 0xAC, 0x5B, 0x40, -0x4F, 0x6E, 0x27, 0xC0, 0x50, 0x8C, 0x3D, 0x40, 0x51, 0x57, 0x44, 0x40, 0x52, 0x6C, 0x1F, 0x40, -0x53, 0x37, 0x26, 0x40, 0x54, 0x4C, 0x01, 0x40, 0x55, 0x17, 0x08, 0x40, 0x56, 0x2B, 0xE3, 0x40, -0x56, 0xF6, 0xEA, 0x40, 0x58, 0x14, 0xFF, 0xC0, 0x58, 0xD6, 0xCC, 0x40, 0x59, 0xF4, 0xE1, 0xC0, -0x5A, 0xB6, 0xAE, 0x40, 0x5B, 0xD4, 0xC3, 0xC0, 0x5C, 0x9F, 0xCA, 0xC0, 0x5D, 0xB4, 0xA5, 0xC0, -0x5E, 0x7F, 0xAC, 0xC0, 0x5F, 0x94, 0x87, 0xC0, 0x60, 0x5F, 0x8E, 0xC0, 0x61, 0x7D, 0xA4, 0x40, -0x62, 0x3F, 0x70, 0xC0, 0x63, 0x5D, 0x86, 0x40, 0x64, 0x1F, 0x52, 0xC0, 0x65, 0x3D, 0x68, 0x40, -0x66, 0x08, 0x6F, 0x40, 0x67, 0x1D, 0x4A, 0x40, 0x67, 0xE8, 0x51, 0x40, 0x68, 0xFD, 0x2C, 0x40, -0x69, 0xC8, 0x33, 0x40, 0x6A, 0xDD, 0x0E, 0x40, 0x6B, 0xA8, 0x15, 0x40, 0x6C, 0xC6, 0x2A, 0xC0, -0x6D, 0x87, 0xF7, 0x40, 0x6E, 0xA6, 0x0C, 0xC0, 0x6F, 0x67, 0xD9, 0x40, 0x70, 0x85, 0xEE, 0xC0, -0x71, 0x50, 0xF5, 0xC0, 0x72, 0x65, 0xD0, 0xC0, 0x73, 0x30, 0xD7, 0xC0, 0x74, 0x45, 0xB2, 0xC0, -0x75, 0x10, 0xB9, 0xC0, 0x76, 0x2E, 0xCF, 0x40, 0x76, 0xF0, 0x9B, 0xC0, 0x78, 0x0E, 0xB1, 0x40, -0x78, 0xD0, 0x7D, 0xC0, 0x79, 0xEE, 0x93, 0x40, 0x7A, 0xB0, 0x5F, 0xC0, 0x7B, 0xCE, 0x75, 0x40, -0x7C, 0x99, 0x7C, 0x40, 0x7D, 0xAE, 0x57, 0x40, 0x7E, 0x79, 0x5E, 0x40, 0x7F, 0x8E, 0x39, 0x40, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x63, 0xC0, 0x4C, 0xCC, 0x79, 0x40, 0x4D, 0x8E, 0x45, 0xC0, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x00, 0x00, 0x44, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x46, 0x50, 0x00, -0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x54, -0x60, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x01, 0x09, 0x00, -0x00, 0x46, 0x50, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x4F, 0x4D, 0x53, 0x54, 0x00, 0x4F, 0x4D, -0x53, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xDD, 0x40, 0xA0, 0x01, 0x82, 0xA8, 0x60, 0x00, 0x00, 0x00, 0x18, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, 0x77, 0x65, 0x73, 0x74, -0x20, 0x53, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x00, 0x00, 0x44, 0xD0, +0x00, 0x00, 0x00, 0x00, 0x46, 0x50, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, +0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, +0x00, 0x00, 0x54, 0x60, 0x01, 0x09, 0x00, 0x00, 0x46, 0x50, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, +0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x4F, 0x4D, 0x53, 0x54, 0x00, 0x4F, 0x4D, 0x53, 0x53, 0x54, +0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0xDD, 0x40, 0xA0, 0x01, 0x82, 0xA8, 0x60, 0x00, 0x00, 0x00, 0x18, 0x4D, +0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, 0x77, 0x65, 0x73, 0x74, 0x20, +0x53, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, /* Asia/Oral */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x4B, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -9016,7 +8906,7 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Sakhalin */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x76, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x17, 0x86, 0xF0, 0xCD, 0xB8, +0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x17, 0x86, 0xF0, 0xCD, 0xB8, 0xC3, 0xCE, 0x85, 0x70, 0xD2, 0x30, 0xB2, 0xF0, 0x15, 0x27, 0x37, 0x50, 0x16, 0x18, 0x6B, 0xC0, 0x17, 0x08, 0x6A, 0xD0, 0x17, 0xF9, 0x9F, 0x40, 0x18, 0xE9, 0x9E, 0x50, 0x19, 0xDA, 0xD2, 0xC0, 0x1A, 0xCC, 0x23, 0x50, 0x1B, 0xBC, 0x30, 0x70, 0x1C, 0xAC, 0x21, 0x70, 0x1D, 0x9C, 0x12, 0x70, @@ -9033,36 +8923,19 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x43, 0x63, 0x9C, 0x80, 0x44, 0x25, 0x69, 0x00, 0x45, 0x43, 0x7E, 0x80, 0x46, 0x05, 0x4B, 0x00, 0x47, 0x23, 0x60, 0x80, 0x47, 0xEE, 0x67, 0x80, 0x49, 0x03, 0x42, 0x80, 0x49, 0xCE, 0x49, 0x80, 0x4A, 0xE3, 0x24, 0x80, 0x4B, 0xAE, 0x2B, 0x80, 0x4C, 0xCC, 0x41, 0x00, 0x4D, 0x8E, 0x0D, 0x80, -0x4E, 0xAC, 0x23, 0x00, 0x4F, 0x6D, 0xEF, 0x80, 0x50, 0x8C, 0x05, 0x00, 0x51, 0x57, 0x0C, 0x00, -0x52, 0x6B, 0xE7, 0x00, 0x53, 0x36, 0xEE, 0x00, 0x54, 0x4B, 0xC9, 0x00, 0x55, 0x16, 0xD0, 0x00, -0x56, 0x2B, 0xAB, 0x00, 0x56, 0xF6, 0xB2, 0x00, 0x58, 0x14, 0xC7, 0x80, 0x58, 0xD6, 0x94, 0x00, -0x59, 0xF4, 0xA9, 0x80, 0x5A, 0xB6, 0x76, 0x00, 0x5B, 0xD4, 0x8B, 0x80, 0x5C, 0x9F, 0x92, 0x80, -0x5D, 0xB4, 0x6D, 0x80, 0x5E, 0x7F, 0x74, 0x80, 0x5F, 0x94, 0x4F, 0x80, 0x60, 0x5F, 0x56, 0x80, -0x61, 0x7D, 0x6C, 0x00, 0x62, 0x3F, 0x38, 0x80, 0x63, 0x5D, 0x4E, 0x00, 0x64, 0x1F, 0x1A, 0x80, -0x65, 0x3D, 0x30, 0x00, 0x66, 0x08, 0x37, 0x00, 0x67, 0x1D, 0x12, 0x00, 0x67, 0xE8, 0x19, 0x00, -0x68, 0xFC, 0xF4, 0x00, 0x69, 0xC7, 0xFB, 0x00, 0x6A, 0xDC, 0xD6, 0x00, 0x6B, 0xA7, 0xDD, 0x00, -0x6C, 0xC5, 0xF2, 0x80, 0x6D, 0x87, 0xBF, 0x00, 0x6E, 0xA5, 0xD4, 0x80, 0x6F, 0x67, 0xA1, 0x00, -0x70, 0x85, 0xB6, 0x80, 0x71, 0x50, 0xBD, 0x80, 0x72, 0x65, 0x98, 0x80, 0x73, 0x30, 0x9F, 0x80, -0x74, 0x45, 0x7A, 0x80, 0x75, 0x10, 0x81, 0x80, 0x76, 0x2E, 0x97, 0x00, 0x76, 0xF0, 0x63, 0x80, -0x78, 0x0E, 0x79, 0x00, 0x78, 0xD0, 0x45, 0x80, 0x79, 0xEE, 0x5B, 0x00, 0x7A, 0xB0, 0x27, 0x80, -0x7B, 0xCE, 0x3D, 0x00, 0x7C, 0x99, 0x44, 0x00, 0x7D, 0xAE, 0x1F, 0x00, 0x7E, 0x79, 0x26, 0x00, -0x7F, 0x8E, 0x01, 0x00, 0x01, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x06, -0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x05, 0x03, 0x04, -0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, -0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, +0x01, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, +0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x05, 0x03, 0x04, 0x06, 0x05, 0x06, 0x05, +0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, -0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, -0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, -0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x07, 0x08, 0x00, 0x00, 0x85, 0xC8, 0x00, 0x00, -0x00, 0x00, 0x7E, 0x90, 0x00, 0x04, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x08, 0x00, 0x00, 0xA8, 0xC0, -0x01, 0x0C, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x12, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x12, 0x00, 0x00, -0xA8, 0xC0, 0x01, 0x0C, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x0C, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x12, -0x4C, 0x4D, 0x54, 0x00, 0x43, 0x4A, 0x54, 0x00, 0x4A, 0x53, 0x54, 0x00, 0x53, 0x41, 0x4B, 0x53, -0x54, 0x00, 0x53, 0x41, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xD0, 0xFE, 0x9A, 0x01, 0xEC, 0x66, -0xB0, 0x00, 0x00, 0x00, 0x1B, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x37, 0x20, 0x2D, -0x20, 0x53, 0x61, 0x6B, 0x68, 0x61, 0x6C, 0x69, 0x6E, 0x20, 0x49, 0x73, 0x6C, 0x61, 0x6E, 0x64, - +0x05, 0x00, 0x00, 0x85, 0xC8, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x04, 0x00, 0x00, 0x7E, +0x90, 0x00, 0x08, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x0C, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x12, 0x00, +0x00, 0x9A, 0xB0, 0x00, 0x12, 0x00, 0x00, 0xA8, 0xC0, 0x01, 0x0C, 0x00, 0x00, 0x9A, 0xB0, 0x01, +0x0C, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x12, 0x4C, 0x4D, 0x54, 0x00, 0x43, 0x4A, 0x54, 0x00, 0x4A, +0x53, 0x54, 0x00, 0x53, 0x41, 0x4B, 0x53, 0x54, 0x00, 0x53, 0x41, 0x4B, 0x54, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0xD0, 0xFE, 0x9A, 0x01, 0xEC, 0x66, 0xB0, 0x00, 0x00, 0x00, 0x1B, 0x4D, 0x6F, 0x73, 0x63, +0x6F, 0x77, 0x2B, 0x30, 0x37, 0x20, 0x2D, 0x20, 0x53, 0x61, 0x6B, 0x68, 0x61, 0x6C, 0x69, 0x6E, +0x20, 0x49, 0x73, 0x6C, 0x61, 0x6E, 0x64, /* Asia/Samarkand */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x55, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -9409,8 +9282,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Asia/Vladivostok */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x16, 0xA7, 0x59, 0x47, 0x50, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x16, 0xA7, 0x59, 0x47, 0x50, 0xB5, 0xA3, 0xB6, 0xF0, 0x15, 0x27, 0x45, 0x60, 0x16, 0x18, 0x79, 0xD0, 0x17, 0x08, 0x78, 0xE0, 0x17, 0xF9, 0xAD, 0x50, 0x18, 0xE9, 0xAC, 0x60, 0x19, 0xDA, 0xE0, 0xD0, 0x1A, 0xCC, 0x31, 0x60, 0x1B, 0xBC, 0x3E, 0x80, 0x1C, 0xAC, 0x2F, 0x80, 0x1D, 0x9C, 0x20, 0x80, 0x1E, 0x8C, 0x11, 0x80, @@ -9426,40 +9299,24 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xA5, 0x00, 0x41, 0x83, 0xBA, 0x80, 0x42, 0x45, 0x87, 0x00, 0x43, 0x63, 0x9C, 0x80, 0x44, 0x25, 0x69, 0x00, 0x45, 0x43, 0x7E, 0x80, 0x46, 0x05, 0x4B, 0x00, 0x47, 0x23, 0x60, 0x80, 0x47, 0xEE, 0x67, 0x80, 0x49, 0x03, 0x42, 0x80, 0x49, 0xCE, 0x49, 0x80, 0x4A, 0xE3, 0x24, 0x80, -0x4B, 0xAE, 0x2B, 0x80, 0x4C, 0xCC, 0x41, 0x00, 0x4D, 0x8E, 0x0D, 0x80, 0x4E, 0xAC, 0x23, 0x00, -0x4F, 0x6D, 0xEF, 0x80, 0x50, 0x8C, 0x05, 0x00, 0x51, 0x57, 0x0C, 0x00, 0x52, 0x6B, 0xE7, 0x00, -0x53, 0x36, 0xEE, 0x00, 0x54, 0x4B, 0xC9, 0x00, 0x55, 0x16, 0xD0, 0x00, 0x56, 0x2B, 0xAB, 0x00, -0x56, 0xF6, 0xB2, 0x00, 0x58, 0x14, 0xC7, 0x80, 0x58, 0xD6, 0x94, 0x00, 0x59, 0xF4, 0xA9, 0x80, -0x5A, 0xB6, 0x76, 0x00, 0x5B, 0xD4, 0x8B, 0x80, 0x5C, 0x9F, 0x92, 0x80, 0x5D, 0xB4, 0x6D, 0x80, -0x5E, 0x7F, 0x74, 0x80, 0x5F, 0x94, 0x4F, 0x80, 0x60, 0x5F, 0x56, 0x80, 0x61, 0x7D, 0x6C, 0x00, -0x62, 0x3F, 0x38, 0x80, 0x63, 0x5D, 0x4E, 0x00, 0x64, 0x1F, 0x1A, 0x80, 0x65, 0x3D, 0x30, 0x00, -0x66, 0x08, 0x37, 0x00, 0x67, 0x1D, 0x12, 0x00, 0x67, 0xE8, 0x19, 0x00, 0x68, 0xFC, 0xF4, 0x00, -0x69, 0xC7, 0xFB, 0x00, 0x6A, 0xDC, 0xD6, 0x00, 0x6B, 0xA7, 0xDD, 0x00, 0x6C, 0xC5, 0xF2, 0x80, -0x6D, 0x87, 0xBF, 0x00, 0x6E, 0xA5, 0xD4, 0x80, 0x6F, 0x67, 0xA1, 0x00, 0x70, 0x85, 0xB6, 0x80, -0x71, 0x50, 0xBD, 0x80, 0x72, 0x65, 0x98, 0x80, 0x73, 0x30, 0x9F, 0x80, 0x74, 0x45, 0x7A, 0x80, -0x75, 0x10, 0x81, 0x80, 0x76, 0x2E, 0x97, 0x00, 0x76, 0xF0, 0x63, 0x80, 0x78, 0x0E, 0x79, 0x00, -0x78, 0xD0, 0x45, 0x80, 0x79, 0xEE, 0x5B, 0x00, 0x7A, 0xB0, 0x27, 0x80, 0x7B, 0xCE, 0x3D, 0x00, -0x7C, 0x99, 0x44, 0x00, 0x7D, 0xAE, 0x1F, 0x00, 0x7E, 0x79, 0x26, 0x00, 0x7F, 0x8E, 0x01, 0x00, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x2B, 0x80, 0x4C, 0xCC, 0x41, 0x00, 0x4D, 0x8E, 0x0D, 0x80, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x00, 0x00, 0x7B, 0xB0, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x00, -0x04, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x09, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x04, 0x00, 0x00, 0x8C, -0xA0, 0x00, 0x04, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x09, 0x00, 0x00, 0x8C, 0xA0, 0x01, 0x0F, 0x00, -0x00, 0x7E, 0x90, 0x00, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x56, 0x4C, 0x41, 0x54, 0x00, 0x56, 0x4C, -0x41, 0x53, 0x54, 0x00, 0x56, 0x4C, 0x41, 0x53, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, -0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xCB, 0x32, 0x3A, 0x01, -0xDB, 0xF8, 0xF5, 0x00, 0x00, 0x00, 0x16, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x37, -0x20, 0x2D, 0x20, 0x41, 0x6D, 0x75, 0x72, 0x20, 0x52, 0x69, 0x76, 0x65, 0x72, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x00, 0x00, 0x7B, 0xB0, +0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x04, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x09, 0x00, 0x00, +0x8C, 0xA0, 0x00, 0x04, 0x00, 0x00, 0x8C, 0xA0, 0x00, 0x04, 0x00, 0x00, 0x9A, 0xB0, 0x01, 0x09, +0x00, 0x00, 0x8C, 0xA0, 0x01, 0x0F, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x09, 0x00, 0x00, 0x9A, 0xB0, +0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x56, 0x4C, 0x41, 0x54, 0x00, 0x56, 0x4C, 0x41, 0x53, 0x54, +0x00, 0x56, 0x4C, 0x41, 0x53, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, +0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xCB, 0x32, 0x3A, 0x01, 0xDB, +0xF8, 0xF5, 0x00, 0x00, 0x00, 0x16, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x37, 0x20, +0x2D, 0x20, 0x41, 0x6D, 0x75, 0x72, 0x20, 0x52, 0x69, 0x76, 0x65, 0x72, /* Asia/Yakutsk */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xDB, 0xEA, 0x70, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0F, 0xA1, 0xDB, 0xEA, 0x70, 0xB5, 0xA3, 0xC5, 0x00, 0x15, 0x27, 0x53, 0x70, 0x16, 0x18, 0x87, 0xE0, 0x17, 0x08, 0x86, 0xF0, 0x17, 0xF9, 0xBB, 0x60, 0x18, 0xE9, 0xBA, 0x70, 0x19, 0xDA, 0xEE, 0xE0, 0x1A, 0xCC, 0x3F, 0x70, 0x1B, 0xBC, 0x4C, 0x90, 0x1C, 0xAC, 0x3D, 0x90, 0x1D, 0x9C, 0x2E, 0x90, 0x1E, 0x8C, 0x1F, 0x90, @@ -9475,40 +9332,24 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xB3, 0x10, 0x41, 0x83, 0xC8, 0x90, 0x42, 0x45, 0x95, 0x10, 0x43, 0x63, 0xAA, 0x90, 0x44, 0x25, 0x77, 0x10, 0x45, 0x43, 0x8C, 0x90, 0x46, 0x05, 0x59, 0x10, 0x47, 0x23, 0x6E, 0x90, 0x47, 0xEE, 0x75, 0x90, 0x49, 0x03, 0x50, 0x90, 0x49, 0xCE, 0x57, 0x90, 0x4A, 0xE3, 0x32, 0x90, -0x4B, 0xAE, 0x39, 0x90, 0x4C, 0xCC, 0x4F, 0x10, 0x4D, 0x8E, 0x1B, 0x90, 0x4E, 0xAC, 0x31, 0x10, -0x4F, 0x6D, 0xFD, 0x90, 0x50, 0x8C, 0x13, 0x10, 0x51, 0x57, 0x1A, 0x10, 0x52, 0x6B, 0xF5, 0x10, -0x53, 0x36, 0xFC, 0x10, 0x54, 0x4B, 0xD7, 0x10, 0x55, 0x16, 0xDE, 0x10, 0x56, 0x2B, 0xB9, 0x10, -0x56, 0xF6, 0xC0, 0x10, 0x58, 0x14, 0xD5, 0x90, 0x58, 0xD6, 0xA2, 0x10, 0x59, 0xF4, 0xB7, 0x90, -0x5A, 0xB6, 0x84, 0x10, 0x5B, 0xD4, 0x99, 0x90, 0x5C, 0x9F, 0xA0, 0x90, 0x5D, 0xB4, 0x7B, 0x90, -0x5E, 0x7F, 0x82, 0x90, 0x5F, 0x94, 0x5D, 0x90, 0x60, 0x5F, 0x64, 0x90, 0x61, 0x7D, 0x7A, 0x10, -0x62, 0x3F, 0x46, 0x90, 0x63, 0x5D, 0x5C, 0x10, 0x64, 0x1F, 0x28, 0x90, 0x65, 0x3D, 0x3E, 0x10, -0x66, 0x08, 0x45, 0x10, 0x67, 0x1D, 0x20, 0x10, 0x67, 0xE8, 0x27, 0x10, 0x68, 0xFD, 0x02, 0x10, -0x69, 0xC8, 0x09, 0x10, 0x6A, 0xDC, 0xE4, 0x10, 0x6B, 0xA7, 0xEB, 0x10, 0x6C, 0xC6, 0x00, 0x90, -0x6D, 0x87, 0xCD, 0x10, 0x6E, 0xA5, 0xE2, 0x90, 0x6F, 0x67, 0xAF, 0x10, 0x70, 0x85, 0xC4, 0x90, -0x71, 0x50, 0xCB, 0x90, 0x72, 0x65, 0xA6, 0x90, 0x73, 0x30, 0xAD, 0x90, 0x74, 0x45, 0x88, 0x90, -0x75, 0x10, 0x8F, 0x90, 0x76, 0x2E, 0xA5, 0x10, 0x76, 0xF0, 0x71, 0x90, 0x78, 0x0E, 0x87, 0x10, -0x78, 0xD0, 0x53, 0x90, 0x79, 0xEE, 0x69, 0x10, 0x7A, 0xB0, 0x35, 0x90, 0x7B, 0xCE, 0x4B, 0x10, -0x7C, 0x99, 0x52, 0x10, 0x7D, 0xAE, 0x2D, 0x10, 0x7E, 0x79, 0x34, 0x10, 0x7F, 0x8E, 0x0F, 0x10, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, +0x4B, 0xAE, 0x39, 0x90, 0x4C, 0xCC, 0x4F, 0x10, 0x4D, 0x8E, 0x1B, 0x90, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x00, 0x00, 0x79, 0x90, 0x00, 0x00, 0x00, 0x00, 0x70, 0x80, 0x00, -0x04, 0x00, 0x00, 0x8C, 0xA0, 0x01, 0x09, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x04, 0x00, 0x00, 0x7E, -0x90, 0x00, 0x04, 0x00, 0x00, 0x8C, 0xA0, 0x01, 0x09, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x09, 0x00, -0x00, 0x70, 0x80, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x59, 0x41, 0x4B, 0x54, 0x00, 0x59, 0x41, -0x4B, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xE7, 0xEF, 0x00, 0x01, 0xD8, 0x83, 0x8A, 0x00, 0x00, 0x00, 0x16, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x36, 0x20, 0x2D, 0x20, 0x4C, 0x65, 0x6E, 0x61, -0x20, 0x52, 0x69, 0x76, 0x65, 0x72, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x00, 0x00, 0x79, 0x90, +0x00, 0x00, 0x00, 0x00, 0x70, 0x80, 0x00, 0x04, 0x00, 0x00, 0x8C, 0xA0, 0x01, 0x09, 0x00, 0x00, +0x7E, 0x90, 0x00, 0x04, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x04, 0x00, 0x00, 0x8C, 0xA0, 0x01, 0x09, +0x00, 0x00, 0x7E, 0x90, 0x01, 0x09, 0x00, 0x00, 0x70, 0x80, 0x00, 0x04, 0x00, 0x00, 0x8C, 0xA0, +0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x59, 0x41, 0x4B, 0x54, 0x00, 0x59, 0x41, 0x4B, 0x53, 0x54, +0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0xE7, 0xEF, 0x00, 0x01, 0xD8, 0x83, 0x8A, 0x00, 0x00, 0x00, 0x16, 0x4D, +0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x36, 0x20, 0x2D, 0x20, 0x4C, 0x65, 0x6E, 0x61, 0x20, +0x52, 0x69, 0x76, 0x65, 0x72, /* Asia/Yekaterinburg */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0x12, 0xAD, 0xF0, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0x12, 0xAD, 0xF0, 0xB5, 0xA3, 0xFD, 0x40, 0x15, 0x27, 0x8B, 0xB0, 0x16, 0x18, 0xC0, 0x20, 0x17, 0x08, 0xBF, 0x30, 0x17, 0xF9, 0xF3, 0xA0, 0x18, 0xE9, 0xF2, 0xB0, 0x19, 0xDB, 0x27, 0x20, 0x1A, 0xCC, 0x77, 0xB0, 0x1B, 0xBC, 0x84, 0xD0, 0x1C, 0xAC, 0x75, 0xD0, 0x1D, 0x9C, 0x66, 0xD0, 0x1E, 0x8C, 0x57, 0xD0, @@ -9524,37 +9365,21 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x65, 0xEB, 0x50, 0x41, 0x84, 0x00, 0xD0, 0x42, 0x45, 0xCD, 0x50, 0x43, 0x63, 0xE2, 0xD0, 0x44, 0x25, 0xAF, 0x50, 0x45, 0x43, 0xC4, 0xD0, 0x46, 0x05, 0x91, 0x50, 0x47, 0x23, 0xA6, 0xD0, 0x47, 0xEE, 0xAD, 0xD0, 0x49, 0x03, 0x88, 0xD0, 0x49, 0xCE, 0x8F, 0xD0, 0x4A, 0xE3, 0x6A, 0xD0, -0x4B, 0xAE, 0x71, 0xD0, 0x4C, 0xCC, 0x87, 0x50, 0x4D, 0x8E, 0x53, 0xD0, 0x4E, 0xAC, 0x69, 0x50, -0x4F, 0x6E, 0x35, 0xD0, 0x50, 0x8C, 0x4B, 0x50, 0x51, 0x57, 0x52, 0x50, 0x52, 0x6C, 0x2D, 0x50, -0x53, 0x37, 0x34, 0x50, 0x54, 0x4C, 0x0F, 0x50, 0x55, 0x17, 0x16, 0x50, 0x56, 0x2B, 0xF1, 0x50, -0x56, 0xF6, 0xF8, 0x50, 0x58, 0x15, 0x0D, 0xD0, 0x58, 0xD6, 0xDA, 0x50, 0x59, 0xF4, 0xEF, 0xD0, -0x5A, 0xB6, 0xBC, 0x50, 0x5B, 0xD4, 0xD1, 0xD0, 0x5C, 0x9F, 0xD8, 0xD0, 0x5D, 0xB4, 0xB3, 0xD0, -0x5E, 0x7F, 0xBA, 0xD0, 0x5F, 0x94, 0x95, 0xD0, 0x60, 0x5F, 0x9C, 0xD0, 0x61, 0x7D, 0xB2, 0x50, -0x62, 0x3F, 0x7E, 0xD0, 0x63, 0x5D, 0x94, 0x50, 0x64, 0x1F, 0x60, 0xD0, 0x65, 0x3D, 0x76, 0x50, -0x66, 0x08, 0x7D, 0x50, 0x67, 0x1D, 0x58, 0x50, 0x67, 0xE8, 0x5F, 0x50, 0x68, 0xFD, 0x3A, 0x50, -0x69, 0xC8, 0x41, 0x50, 0x6A, 0xDD, 0x1C, 0x50, 0x6B, 0xA8, 0x23, 0x50, 0x6C, 0xC6, 0x38, 0xD0, -0x6D, 0x88, 0x05, 0x50, 0x6E, 0xA6, 0x1A, 0xD0, 0x6F, 0x67, 0xE7, 0x50, 0x70, 0x85, 0xFC, 0xD0, -0x71, 0x51, 0x03, 0xD0, 0x72, 0x65, 0xDE, 0xD0, 0x73, 0x30, 0xE5, 0xD0, 0x74, 0x45, 0xC0, 0xD0, -0x75, 0x10, 0xC7, 0xD0, 0x76, 0x2E, 0xDD, 0x50, 0x76, 0xF0, 0xA9, 0xD0, 0x78, 0x0E, 0xBF, 0x50, -0x78, 0xD0, 0x8B, 0xD0, 0x79, 0xEE, 0xA1, 0x50, 0x7A, 0xB0, 0x6D, 0xD0, 0x7B, 0xCE, 0x83, 0x50, -0x7C, 0x99, 0x8A, 0x50, 0x7D, 0xAE, 0x65, 0x50, 0x7E, 0x79, 0x6C, 0x50, 0x7F, 0x8E, 0x47, 0x50, -0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x0B, 0x08, 0x09, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, -0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, -0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, -0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, -0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, +0x4B, 0xAE, 0x71, 0xD0, 0x4C, 0xCC, 0x87, 0x50, 0x4D, 0x8E, 0x53, 0xD0, 0x01, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x04, 0x06, 0x07, 0x0B, 0x08, 0x09, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, -0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x00, 0x00, 0x38, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x38, 0x40, 0x00, -0x04, 0x00, 0x00, 0x54, 0x60, 0x01, 0x09, 0x00, 0x00, 0x46, 0x50, 0x00, 0x04, 0x00, 0x00, 0x46, -0x50, 0x00, 0x04, 0x00, 0x00, 0x54, 0x60, 0x01, 0x09, 0x00, 0x00, 0x46, 0x50, 0x01, 0x09, 0x00, -0x00, 0x38, 0x40, 0x00, 0x04, 0x00, 0x00, 0x54, 0x60, 0x01, 0x0F, 0x00, 0x00, 0x46, 0x50, 0x00, -0x15, 0x00, 0x00, 0x54, 0x60, 0x01, 0x0F, 0x00, 0x00, 0x46, 0x50, 0x00, 0x15, 0x4C, 0x4D, 0x54, -0x00, 0x53, 0x56, 0x45, 0x54, 0x00, 0x53, 0x56, 0x45, 0x53, 0x54, 0x00, 0x59, 0x45, 0x4B, 0x53, -0x54, 0x00, 0x59, 0x45, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, -0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0xE0, 0x13, 0x48, 0x01, 0x6F, 0x20, 0x60, 0x00, 0x00, 0x00, 0x11, 0x4D, 0x6F, 0x73, 0x63, 0x6F, -0x77, 0x2B, 0x30, 0x32, 0x20, 0x2D, 0x20, 0x55, 0x72, 0x61, 0x6C, 0x73, +0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0C, 0x00, 0x00, 0x38, 0xD0, +0x00, 0x00, 0x00, 0x00, 0x38, 0x40, 0x00, 0x04, 0x00, 0x00, 0x54, 0x60, 0x01, 0x09, 0x00, 0x00, +0x46, 0x50, 0x00, 0x04, 0x00, 0x00, 0x46, 0x50, 0x00, 0x04, 0x00, 0x00, 0x54, 0x60, 0x01, 0x09, +0x00, 0x00, 0x46, 0x50, 0x01, 0x09, 0x00, 0x00, 0x38, 0x40, 0x00, 0x04, 0x00, 0x00, 0x54, 0x60, +0x01, 0x0F, 0x00, 0x00, 0x46, 0x50, 0x00, 0x15, 0x00, 0x00, 0x54, 0x60, 0x01, 0x0F, 0x00, 0x00, +0x46, 0x50, 0x00, 0x15, 0x00, 0x00, 0x54, 0x60, 0x00, 0x15, 0x4C, 0x4D, 0x54, 0x00, 0x53, 0x56, +0x45, 0x54, 0x00, 0x53, 0x56, 0x45, 0x53, 0x54, 0x00, 0x59, 0x45, 0x4B, 0x53, 0x54, 0x00, 0x59, +0x45, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x01, 0x01, +0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, +0x13, 0x48, 0x01, 0x6F, 0x20, 0x60, 0x00, 0x00, 0x00, 0x11, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, +0x2B, 0x30, 0x32, 0x20, 0x2D, 0x20, 0x55, 0x72, 0x61, 0x6C, 0x73, /* Asia/Yerevan */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x4D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -13654,8 +13479,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Europe/Kaliningrad */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0E, 0x00, 0x00, 0x00, 0x0E, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, 0x0E, 0x00, 0x00, 0x00, 0x1A, 0x9B, 0x0C, 0x17, 0x60, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x4D, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x1A, 0x9B, 0x0C, 0x17, 0x60, 0x9B, 0xD5, 0xDA, 0xF0, 0x9C, 0xD9, 0xAE, 0x90, 0x9D, 0xA4, 0xB5, 0x90, 0x9E, 0xB9, 0x90, 0x90, 0x9F, 0x84, 0x97, 0x90, 0xC8, 0x09, 0x71, 0x90, 0xCC, 0xE7, 0x4B, 0x10, 0xCD, 0xA9, 0x17, 0x90, 0xCE, 0xA2, 0x43, 0x10, 0xCF, 0x92, 0x34, 0x10, 0xD0, 0x82, 0x25, 0x10, 0xD0, 0xFA, 0x01, 0x70, @@ -13675,39 +13500,23 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x43, 0x64, 0x0D, 0x00, 0x44, 0x25, 0xD9, 0x80, 0x45, 0x43, 0xEF, 0x00, 0x46, 0x05, 0xBB, 0x80, 0x47, 0x23, 0xD1, 0x00, 0x47, 0xEE, 0xD8, 0x00, 0x49, 0x03, 0xB3, 0x00, 0x49, 0xCE, 0xBA, 0x00, 0x4A, 0xE3, 0x95, 0x00, 0x4B, 0xAE, 0x9C, 0x00, 0x4C, 0xCC, 0xB1, 0x80, 0x4D, 0x8E, 0x7E, 0x00, -0x4E, 0xAC, 0x93, 0x80, 0x4F, 0x6E, 0x60, 0x00, 0x50, 0x8C, 0x75, 0x80, 0x51, 0x57, 0x7C, 0x80, -0x52, 0x6C, 0x57, 0x80, 0x53, 0x37, 0x5E, 0x80, 0x54, 0x4C, 0x39, 0x80, 0x55, 0x17, 0x40, 0x80, -0x56, 0x2C, 0x1B, 0x80, 0x56, 0xF7, 0x22, 0x80, 0x58, 0x15, 0x38, 0x00, 0x58, 0xD7, 0x04, 0x80, -0x59, 0xF5, 0x1A, 0x00, 0x5A, 0xB6, 0xE6, 0x80, 0x5B, 0xD4, 0xFC, 0x00, 0x5C, 0xA0, 0x03, 0x00, -0x5D, 0xB4, 0xDE, 0x00, 0x5E, 0x7F, 0xE5, 0x00, 0x5F, 0x94, 0xC0, 0x00, 0x60, 0x5F, 0xC7, 0x00, -0x61, 0x7D, 0xDC, 0x80, 0x62, 0x3F, 0xA9, 0x00, 0x63, 0x5D, 0xBE, 0x80, 0x64, 0x1F, 0x8B, 0x00, -0x65, 0x3D, 0xA0, 0x80, 0x66, 0x08, 0xA7, 0x80, 0x67, 0x1D, 0x82, 0x80, 0x67, 0xE8, 0x89, 0x80, -0x68, 0xFD, 0x64, 0x80, 0x69, 0xC8, 0x6B, 0x80, 0x6A, 0xDD, 0x46, 0x80, 0x6B, 0xA8, 0x4D, 0x80, -0x6C, 0xC6, 0x63, 0x00, 0x6D, 0x88, 0x2F, 0x80, 0x6E, 0xA6, 0x45, 0x00, 0x6F, 0x68, 0x11, 0x80, -0x70, 0x86, 0x27, 0x00, 0x71, 0x51, 0x2E, 0x00, 0x72, 0x66, 0x09, 0x00, 0x73, 0x31, 0x10, 0x00, -0x74, 0x45, 0xEB, 0x00, 0x75, 0x10, 0xF2, 0x00, 0x76, 0x2F, 0x07, 0x80, 0x76, 0xF0, 0xD4, 0x00, -0x78, 0x0E, 0xE9, 0x80, 0x78, 0xD0, 0xB6, 0x00, 0x79, 0xEE, 0xCB, 0x80, 0x7A, 0xB0, 0x98, 0x00, -0x7B, 0xCE, 0xAD, 0x80, 0x7C, 0x99, 0xB4, 0x80, 0x7D, 0xAE, 0x8F, 0x80, 0x7E, 0x79, 0x96, 0x80, -0x7F, 0x8E, 0x71, 0x80, 0x00, 0x01, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, -0x05, 0x04, 0x05, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x0A, 0x0B, 0x0C, 0x0D, 0x0A, 0x0B, 0x0A, 0x0B, +0x00, 0x01, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x05, 0x04, 0x05, 0x07, +0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, +0x09, 0x08, 0x09, 0x08, 0x0A, 0x0B, 0x0C, 0x0D, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, -0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, -0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, -0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, -0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, -0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x00, 0x00, 0x1C, 0x20, 0x01, 0x00, 0x00, 0x00, 0x0E, 0x10, -0x00, 0x05, 0x00, 0x00, 0x1C, 0x20, 0x01, 0x00, 0x00, 0x00, 0x0E, 0x10, 0x00, 0x05, 0x00, 0x00, -0x2A, 0x30, 0x01, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x05, 0x00, 0x00, 0x38, 0x40, 0x01, 0x09, -0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, -0x01, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x16, 0x00, 0x00, -0x2A, 0x30, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x16, 0x43, 0x45, 0x53, 0x54, 0x00, 0x43, -0x45, 0x54, 0x00, 0x4D, 0x53, 0x44, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x45, 0x45, 0x53, 0x54, 0x00, -0x45, 0x45, 0x54, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, +0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0A, 0x0B, 0x0E, 0x00, 0x00, 0x1C, +0x20, 0x01, 0x00, 0x00, 0x00, 0x0E, 0x10, 0x00, 0x05, 0x00, 0x00, 0x1C, 0x20, 0x01, 0x00, 0x00, +0x00, 0x0E, 0x10, 0x00, 0x05, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, +0x05, 0x00, 0x00, 0x38, 0x40, 0x01, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x2A, +0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, 0x01, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x11, 0x00, +0x00, 0x1C, 0x20, 0x00, 0x16, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, +0x16, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x16, 0x43, 0x45, 0x53, 0x54, 0x00, 0x43, 0x45, 0x54, 0x00, +0x4D, 0x53, 0x44, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x45, 0x45, 0x53, 0x54, 0x00, 0x45, 0x45, 0x54, +0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0xDC, 0xD1, 0xF2, 0x01, 0x31, 0xF0, 0x50, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, -0x6F, 0x77, 0x2D, 0x30, 0x31, 0x20, 0x2D, 0x20, 0x4B, 0x61, 0x6C, 0x69, 0x6E, 0x69, 0x6E, 0x67, -0x72, 0x61, 0x64, +0xDC, 0xD1, 0xF2, 0x01, 0x31, 0xF0, 0x50, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, +0x77, 0x2D, 0x30, 0x31, 0x20, 0x2D, 0x20, 0x4B, 0x61, 0x6C, 0x69, 0x6E, 0x69, 0x6E, 0x67, 0x72, +0x61, 0x64, /* Europe/Kiev */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x55, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -14343,8 +14152,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Europe/Moscow */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x81, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x1E, 0x9B, 0x5F, 0x1E, 0xD8, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x4C, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x1E, 0x9B, 0x5F, 0x1E, 0xD8, 0x9D, 0x3E, 0xF2, 0x98, 0x9E, 0x2A, 0xEF, 0x18, 0x9E, 0xF7, 0x39, 0x88, 0x9F, 0x84, 0x58, 0x18, 0xA0, 0xD8, 0x6D, 0x08, 0xA1, 0x00, 0x16, 0x28, 0xA1, 0x3C, 0xA6, 0x40, 0xA4, 0x10, 0x6D, 0xC0, 0xA4, 0x3D, 0x32, 0xB0, 0xA5, 0x15, 0x68, 0xB0, 0xA5, 0x3D, 0x03, 0xC0, 0xA7, 0x1E, 0x45, 0x50, @@ -14363,39 +14172,23 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x66, 0x07, 0x70, 0x41, 0x84, 0x1C, 0xF0, 0x42, 0x45, 0xE9, 0x70, 0x43, 0x63, 0xFE, 0xF0, 0x44, 0x25, 0xCB, 0x70, 0x45, 0x43, 0xE0, 0xF0, 0x46, 0x05, 0xAD, 0x70, 0x47, 0x23, 0xC2, 0xF0, 0x47, 0xEE, 0xC9, 0xF0, 0x49, 0x03, 0xA4, 0xF0, 0x49, 0xCE, 0xAB, 0xF0, 0x4A, 0xE3, 0x86, 0xF0, -0x4B, 0xAE, 0x8D, 0xF0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, 0x4E, 0xAC, 0x85, 0x70, -0x4F, 0x6E, 0x51, 0xF0, 0x50, 0x8C, 0x67, 0x70, 0x51, 0x57, 0x6E, 0x70, 0x52, 0x6C, 0x49, 0x70, -0x53, 0x37, 0x50, 0x70, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x17, 0x32, 0x70, 0x56, 0x2C, 0x0D, 0x70, -0x56, 0xF7, 0x14, 0x70, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD6, 0xF6, 0x70, 0x59, 0xF5, 0x0B, 0xF0, -0x5A, 0xB6, 0xD8, 0x70, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9F, 0xF4, 0xF0, 0x5D, 0xB4, 0xCF, 0xF0, -0x5E, 0x7F, 0xD6, 0xF0, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5F, 0xB8, 0xF0, 0x61, 0x7D, 0xCE, 0x70, -0x62, 0x3F, 0x9A, 0xF0, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1F, 0x7C, 0xF0, 0x65, 0x3D, 0x92, 0x70, -0x66, 0x08, 0x99, 0x70, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE8, 0x7B, 0x70, 0x68, 0xFD, 0x56, 0x70, -0x69, 0xC8, 0x5D, 0x70, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA8, 0x3F, 0x70, 0x6C, 0xC6, 0x54, 0xF0, -0x6D, 0x88, 0x21, 0x70, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x68, 0x03, 0x70, 0x70, 0x86, 0x18, 0xF0, -0x71, 0x51, 0x1F, 0xF0, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x31, 0x01, 0xF0, 0x74, 0x45, 0xDC, 0xF0, -0x75, 0x10, 0xE3, 0xF0, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xF0, 0xC5, 0xF0, 0x78, 0x0E, 0xDB, 0x70, -0x78, 0xD0, 0xA7, 0xF0, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xB0, 0x89, 0xF0, 0x7B, 0xCE, 0x9F, 0x70, -0x7C, 0x99, 0xA6, 0x70, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x79, 0x88, 0x70, 0x7F, 0x8E, 0x63, 0x70, -0x02, 0x01, 0x02, 0x03, 0x01, 0x03, 0x05, 0x04, 0x05, 0x06, 0x05, 0x04, 0x07, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x0A, 0x0B, 0x08, 0x05, 0x04, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, +0x4B, 0xAE, 0x8D, 0xF0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, 0x02, 0x01, 0x02, 0x03, +0x01, 0x03, 0x05, 0x04, 0x05, 0x06, 0x05, 0x04, 0x07, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x0A, 0x0B, +0x08, 0x05, 0x04, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x00, 0x00, 0x23, 0x28, 0x00, 0x00, 0x00, 0x00, 0x31, 0x68, 0x01, 0x04, 0x00, 0x00, 0x23, -0x58, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x78, 0x01, 0x08, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, -0x00, 0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x46, 0x50, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, -0x15, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x2A, -0x30, 0x01, 0x19, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x15, 0x4D, 0x4D, 0x54, 0x00, 0x4D, 0x53, 0x54, -0x00, 0x4D, 0x44, 0x53, 0x54, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x4D, 0x53, 0x44, 0x00, 0x45, 0x45, -0x54, 0x00, 0x45, 0x45, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, -0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0xDE, 0x65, 0x98, 0x01, 0x4C, 0x01, 0x7D, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, -0x77, 0x2B, 0x30, 0x30, 0x20, 0x2D, 0x20, 0x77, 0x65, 0x73, 0x74, 0x20, 0x52, 0x75, 0x73, 0x73, -0x69, 0x61, +0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x0C, 0x00, 0x00, 0x23, 0x28, 0x00, 0x00, 0x00, 0x00, +0x31, 0x68, 0x01, 0x04, 0x00, 0x00, 0x23, 0x58, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x78, 0x01, 0x08, +0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x46, 0x50, +0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x15, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, +0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x19, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x15, +0x00, 0x00, 0x38, 0x40, 0x00, 0x0D, 0x4D, 0x4D, 0x54, 0x00, 0x4D, 0x53, 0x54, 0x00, 0x4D, 0x44, +0x53, 0x54, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x4D, 0x53, 0x44, 0x00, 0x45, 0x45, 0x54, 0x00, 0x45, +0x45, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, +0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xDE, +0x65, 0x98, 0x01, 0x4C, 0x01, 0x7D, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, +0x2B, 0x30, 0x30, 0x20, 0x2D, 0x20, 0x77, 0x65, 0x73, 0x74, 0x20, 0x52, 0x75, 0x73, 0x73, 0x69, +0x61, /* Europe/Nicosia */ 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -14793,7 +14586,7 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Europe/Samara */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x76, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0x00, 0x26, 0x9C, +0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0x00, 0x26, 0x9C, 0xB5, 0xA4, 0x0B, 0x50, 0xBE, 0x4C, 0x26, 0xC0, 0x15, 0x27, 0x99, 0xC0, 0x16, 0x18, 0xCE, 0x30, 0x17, 0x08, 0xCD, 0x40, 0x17, 0xFA, 0x01, 0xB0, 0x18, 0xEA, 0x00, 0xC0, 0x19, 0xDB, 0x35, 0x30, 0x1A, 0xCC, 0x85, 0xC0, 0x1B, 0xBC, 0x92, 0xE0, 0x1C, 0xAC, 0x83, 0xE0, 0x1D, 0x9C, 0x74, 0xE0, @@ -14810,39 +14603,23 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x43, 0x63, 0xF0, 0xE0, 0x44, 0x25, 0xBD, 0x60, 0x45, 0x43, 0xD2, 0xE0, 0x46, 0x05, 0x9F, 0x60, 0x47, 0x23, 0xB4, 0xE0, 0x47, 0xEE, 0xBB, 0xE0, 0x49, 0x03, 0x96, 0xE0, 0x49, 0xCE, 0x9D, 0xE0, 0x4A, 0xE3, 0x78, 0xE0, 0x4B, 0xAE, 0x7F, 0xE0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, -0x4E, 0xAC, 0x85, 0x70, 0x4F, 0x6E, 0x51, 0xF0, 0x50, 0x8C, 0x67, 0x70, 0x51, 0x57, 0x6E, 0x70, -0x52, 0x6C, 0x49, 0x70, 0x53, 0x37, 0x50, 0x70, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x17, 0x32, 0x70, -0x56, 0x2C, 0x0D, 0x70, 0x56, 0xF7, 0x14, 0x70, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD6, 0xF6, 0x70, -0x59, 0xF5, 0x0B, 0xF0, 0x5A, 0xB6, 0xD8, 0x70, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9F, 0xF4, 0xF0, -0x5D, 0xB4, 0xCF, 0xF0, 0x5E, 0x7F, 0xD6, 0xF0, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5F, 0xB8, 0xF0, -0x61, 0x7D, 0xCE, 0x70, 0x62, 0x3F, 0x9A, 0xF0, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1F, 0x7C, 0xF0, -0x65, 0x3D, 0x92, 0x70, 0x66, 0x08, 0x99, 0x70, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE8, 0x7B, 0x70, -0x68, 0xFD, 0x56, 0x70, 0x69, 0xC8, 0x5D, 0x70, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA8, 0x3F, 0x70, -0x6C, 0xC6, 0x54, 0xF0, 0x6D, 0x88, 0x21, 0x70, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x68, 0x03, 0x70, -0x70, 0x86, 0x18, 0xF0, 0x71, 0x51, 0x1F, 0xF0, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x31, 0x01, 0xF0, -0x74, 0x45, 0xDC, 0xF0, 0x75, 0x10, 0xE3, 0xF0, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xF0, 0xC5, 0xF0, -0x78, 0x0E, 0xDB, 0x70, 0x78, 0xD0, 0xA7, 0xF0, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xB0, 0x89, 0xF0, -0x7B, 0xCE, 0x9F, 0x70, 0x7C, 0x99, 0xA6, 0x70, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x79, 0x88, 0x70, -0x7F, 0x8E, 0x63, 0x70, 0x01, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x06, -0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x07, 0x08, 0x07, 0x08, 0x09, 0x08, 0x02, 0x0B, 0x02, +0x01, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, +0x05, 0x06, 0x05, 0x07, 0x08, 0x07, 0x08, 0x09, 0x08, 0x02, 0x0B, 0x02, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, -0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, -0x0C, 0x0D, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, -0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, -0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, -0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x00, 0x00, 0x2F, 0x04, 0x00, 0x00, -0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x38, 0x40, 0x00, 0x04, 0x00, 0x00, 0x46, 0x50, -0x01, 0x09, 0x00, 0x00, 0x38, 0x40, 0x00, 0x0F, 0x00, 0x00, 0x38, 0x40, 0x00, 0x0F, 0x00, 0x00, -0x46, 0x50, 0x01, 0x09, 0x00, 0x00, 0x38, 0x40, 0x01, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0F, -0x00, 0x00, 0x2A, 0x30, 0x01, 0x09, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x0F, 0x00, 0x00, 0x46, 0x50, -0x01, 0x14, 0x00, 0x00, 0x46, 0x50, 0x01, 0x14, 0x00, 0x00, 0x38, 0x40, 0x00, 0x04, 0x00, 0x00, -0x38, 0x40, 0x01, 0x14, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x4C, 0x4D, 0x54, 0x00, 0x53, 0x41, -0x4D, 0x54, 0x00, 0x4B, 0x55, 0x59, 0x53, 0x54, 0x00, 0x4B, 0x55, 0x59, 0x54, 0x00, 0x53, 0x41, -0x4D, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, -0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xDA, 0x81, 0x7F, 0x01, 0x5F, 0x2E, 0x58, 0x00, 0x00, 0x00, 0x19, -0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x20, 0x2D, 0x20, 0x53, 0x61, 0x6D, 0x61, 0x72, 0x61, 0x2C, -0x20, 0x55, 0x64, 0x6D, 0x75, 0x72, 0x74, 0x69, 0x61, +0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0C, 0x0D, 0x0E, 0x0F, +0x0D, 0x00, 0x00, 0x2F, 0x04, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x38, +0x40, 0x00, 0x04, 0x00, 0x00, 0x46, 0x50, 0x01, 0x09, 0x00, 0x00, 0x38, 0x40, 0x00, 0x0F, 0x00, +0x00, 0x38, 0x40, 0x00, 0x0F, 0x00, 0x00, 0x46, 0x50, 0x01, 0x09, 0x00, 0x00, 0x38, 0x40, 0x01, +0x09, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0F, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x09, 0x00, 0x00, 0x1C, +0x20, 0x00, 0x0F, 0x00, 0x00, 0x46, 0x50, 0x01, 0x14, 0x00, 0x00, 0x46, 0x50, 0x01, 0x14, 0x00, +0x00, 0x38, 0x40, 0x00, 0x04, 0x00, 0x00, 0x38, 0x40, 0x01, 0x14, 0x00, 0x00, 0x2A, 0x30, 0x00, +0x04, 0x4C, 0x4D, 0x54, 0x00, 0x53, 0x41, 0x4D, 0x54, 0x00, 0x4B, 0x55, 0x59, 0x53, 0x54, 0x00, +0x4B, 0x55, 0x59, 0x54, 0x00, 0x53, 0x41, 0x4D, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xDA, 0x81, 0x7F, 0x01, +0x5F, 0x2E, 0x58, 0x00, 0x00, 0x00, 0x19, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x20, 0x2D, 0x20, +0x53, 0x61, 0x6D, 0x61, 0x72, 0x61, 0x2C, 0x20, 0x55, 0x64, 0x6D, 0x75, 0x72, 0x74, 0x69, 0x61, + /* Europe/San_Marino */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x53, 0x4D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -15583,7 +15360,7 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* Europe/Volgograd */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x19, 0xA1, 0xF5, 0x46, 0xDC, +0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x19, 0xA1, 0xF5, 0x46, 0xDC, 0xAB, 0xD8, 0x86, 0x50, 0xB5, 0xA4, 0x0B, 0x50, 0xF0, 0xB0, 0x4C, 0x40, 0x15, 0x27, 0x99, 0xC0, 0x16, 0x18, 0xCE, 0x30, 0x17, 0x08, 0xCD, 0x40, 0x17, 0xFA, 0x01, 0xB0, 0x18, 0xEA, 0x00, 0xC0, 0x19, 0xDB, 0x35, 0x30, 0x1A, 0xCC, 0x85, 0xC0, 0x1B, 0xBC, 0x92, 0xE0, 0x1C, 0xAC, 0x83, 0xE0, @@ -15599,37 +15376,21 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x66, 0x07, 0x70, 0x41, 0x84, 0x1C, 0xF0, 0x42, 0x45, 0xE9, 0x70, 0x43, 0x63, 0xFE, 0xF0, 0x44, 0x25, 0xCB, 0x70, 0x45, 0x43, 0xE0, 0xF0, 0x46, 0x05, 0xAD, 0x70, 0x47, 0x23, 0xC2, 0xF0, 0x47, 0xEE, 0xC9, 0xF0, 0x49, 0x03, 0xA4, 0xF0, 0x49, 0xCE, 0xAB, 0xF0, 0x4A, 0xE3, 0x86, 0xF0, -0x4B, 0xAE, 0x8D, 0xF0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, 0x4E, 0xAC, 0x85, 0x70, -0x4F, 0x6E, 0x51, 0xF0, 0x50, 0x8C, 0x67, 0x70, 0x51, 0x57, 0x6E, 0x70, 0x52, 0x6C, 0x49, 0x70, -0x53, 0x37, 0x50, 0x70, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x17, 0x32, 0x70, 0x56, 0x2C, 0x0D, 0x70, -0x56, 0xF7, 0x14, 0x70, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD6, 0xF6, 0x70, 0x59, 0xF5, 0x0B, 0xF0, -0x5A, 0xB6, 0xD8, 0x70, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9F, 0xF4, 0xF0, 0x5D, 0xB4, 0xCF, 0xF0, -0x5E, 0x7F, 0xD6, 0xF0, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5F, 0xB8, 0xF0, 0x61, 0x7D, 0xCE, 0x70, -0x62, 0x3F, 0x9A, 0xF0, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1F, 0x7C, 0xF0, 0x65, 0x3D, 0x92, 0x70, -0x66, 0x08, 0x99, 0x70, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE8, 0x7B, 0x70, 0x68, 0xFD, 0x56, 0x70, -0x69, 0xC8, 0x5D, 0x70, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA8, 0x3F, 0x70, 0x6C, 0xC6, 0x54, 0xF0, -0x6D, 0x88, 0x21, 0x70, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x68, 0x03, 0x70, 0x70, 0x86, 0x18, 0xF0, -0x71, 0x51, 0x1F, 0xF0, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x31, 0x01, 0xF0, 0x74, 0x45, 0xDC, 0xF0, -0x75, 0x10, 0xE3, 0xF0, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xF0, 0xC5, 0xF0, 0x78, 0x0E, 0xDB, 0x70, -0x78, 0xD0, 0xA7, 0xF0, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xB0, 0x89, 0xF0, 0x7B, 0xCE, 0x9F, 0x70, -0x7C, 0x99, 0xA6, 0x70, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x79, 0x88, 0x70, 0x7F, 0x8E, 0x63, 0x70, -0x01, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x06, 0x07, 0x06, -0x07, 0x06, 0x07, 0x06, 0x08, 0x09, 0x08, 0x09, 0x06, 0x08, 0x0A, 0x08, 0x09, 0x08, 0x09, 0x08, +0x4B, 0xAE, 0x8D, 0xF0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, 0x01, 0x02, 0x03, 0x05, +0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, +0x08, 0x09, 0x08, 0x09, 0x06, 0x08, 0x0A, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x09, 0x08, 0x09, 0x00, 0x00, 0x29, 0xA4, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, -0x04, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x09, 0x00, 0x00, 0x38, 0x40, 0x00, 0x09, 0x00, 0x00, 0x46, -0x50, 0x01, 0x0E, 0x00, 0x00, 0x38, 0x40, 0x00, 0x14, 0x00, 0x00, 0x38, 0x40, 0x00, 0x14, 0x00, -0x00, 0x46, 0x50, 0x01, 0x0E, 0x00, 0x00, 0x38, 0x40, 0x01, 0x0E, 0x00, 0x00, 0x2A, 0x30, 0x00, -0x14, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x14, 0x4C, 0x4D, 0x54, 0x00, 0x54, 0x53, 0x41, 0x54, 0x00, -0x53, 0x54, 0x41, 0x54, 0x00, 0x56, 0x4F, 0x4C, 0x53, 0x54, 0x00, 0x56, 0x4F, 0x4C, 0x54, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xD3, 0xB0, 0xB5, 0x01, 0x56, 0x6E, 0xC2, 0x00, 0x00, -0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, 0x30, 0x30, 0x20, 0x2D, 0x20, 0x43, 0x61, -0x73, 0x70, 0x69, 0x61, 0x6E, 0x20, 0x53, 0x65, 0x61, +0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x06, 0x00, 0x00, 0x29, 0xA4, +0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x09, 0x00, 0x00, +0x38, 0x40, 0x00, 0x09, 0x00, 0x00, 0x46, 0x50, 0x01, 0x0E, 0x00, 0x00, 0x38, 0x40, 0x00, 0x14, +0x00, 0x00, 0x38, 0x40, 0x00, 0x14, 0x00, 0x00, 0x46, 0x50, 0x01, 0x0E, 0x00, 0x00, 0x38, 0x40, +0x01, 0x0E, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x14, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x14, 0x4C, 0x4D, +0x54, 0x00, 0x54, 0x53, 0x41, 0x54, 0x00, 0x53, 0x54, 0x41, 0x54, 0x00, 0x56, 0x4F, 0x4C, 0x53, +0x54, 0x00, 0x56, 0x4F, 0x4C, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, +0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xD3, 0xB0, +0xB5, 0x01, 0x56, 0x6E, 0xC2, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2B, +0x30, 0x30, 0x20, 0x2D, 0x20, 0x43, 0x61, 0x73, 0x70, 0x69, 0x61, 0x6E, 0x20, 0x53, 0x65, 0x61, + /* Europe/Warsaw */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x50, 0x4C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -18353,8 +18114,8 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { /* W-SU */ 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x81, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x1E, 0x9B, 0x5F, 0x1E, 0xD8, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x4C, 0x00, 0x00, 0x00, 0x0D, 0x00, 0x00, 0x00, 0x1E, 0x9B, 0x5F, 0x1E, 0xD8, 0x9D, 0x3E, 0xF2, 0x98, 0x9E, 0x2A, 0xEF, 0x18, 0x9E, 0xF7, 0x39, 0x88, 0x9F, 0x84, 0x58, 0x18, 0xA0, 0xD8, 0x6D, 0x08, 0xA1, 0x00, 0x16, 0x28, 0xA1, 0x3C, 0xA6, 0x40, 0xA4, 0x10, 0x6D, 0xC0, 0xA4, 0x3D, 0x32, 0xB0, 0xA5, 0x15, 0x68, 0xB0, 0xA5, 0x3D, 0x03, 0xC0, 0xA7, 0x1E, 0x45, 0x50, @@ -18373,37 +18134,21 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x40, 0x66, 0x07, 0x70, 0x41, 0x84, 0x1C, 0xF0, 0x42, 0x45, 0xE9, 0x70, 0x43, 0x63, 0xFE, 0xF0, 0x44, 0x25, 0xCB, 0x70, 0x45, 0x43, 0xE0, 0xF0, 0x46, 0x05, 0xAD, 0x70, 0x47, 0x23, 0xC2, 0xF0, 0x47, 0xEE, 0xC9, 0xF0, 0x49, 0x03, 0xA4, 0xF0, 0x49, 0xCE, 0xAB, 0xF0, 0x4A, 0xE3, 0x86, 0xF0, -0x4B, 0xAE, 0x8D, 0xF0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, 0x4E, 0xAC, 0x85, 0x70, -0x4F, 0x6E, 0x51, 0xF0, 0x50, 0x8C, 0x67, 0x70, 0x51, 0x57, 0x6E, 0x70, 0x52, 0x6C, 0x49, 0x70, -0x53, 0x37, 0x50, 0x70, 0x54, 0x4C, 0x2B, 0x70, 0x55, 0x17, 0x32, 0x70, 0x56, 0x2C, 0x0D, 0x70, -0x56, 0xF7, 0x14, 0x70, 0x58, 0x15, 0x29, 0xF0, 0x58, 0xD6, 0xF6, 0x70, 0x59, 0xF5, 0x0B, 0xF0, -0x5A, 0xB6, 0xD8, 0x70, 0x5B, 0xD4, 0xED, 0xF0, 0x5C, 0x9F, 0xF4, 0xF0, 0x5D, 0xB4, 0xCF, 0xF0, -0x5E, 0x7F, 0xD6, 0xF0, 0x5F, 0x94, 0xB1, 0xF0, 0x60, 0x5F, 0xB8, 0xF0, 0x61, 0x7D, 0xCE, 0x70, -0x62, 0x3F, 0x9A, 0xF0, 0x63, 0x5D, 0xB0, 0x70, 0x64, 0x1F, 0x7C, 0xF0, 0x65, 0x3D, 0x92, 0x70, -0x66, 0x08, 0x99, 0x70, 0x67, 0x1D, 0x74, 0x70, 0x67, 0xE8, 0x7B, 0x70, 0x68, 0xFD, 0x56, 0x70, -0x69, 0xC8, 0x5D, 0x70, 0x6A, 0xDD, 0x38, 0x70, 0x6B, 0xA8, 0x3F, 0x70, 0x6C, 0xC6, 0x54, 0xF0, -0x6D, 0x88, 0x21, 0x70, 0x6E, 0xA6, 0x36, 0xF0, 0x6F, 0x68, 0x03, 0x70, 0x70, 0x86, 0x18, 0xF0, -0x71, 0x51, 0x1F, 0xF0, 0x72, 0x65, 0xFA, 0xF0, 0x73, 0x31, 0x01, 0xF0, 0x74, 0x45, 0xDC, 0xF0, -0x75, 0x10, 0xE3, 0xF0, 0x76, 0x2E, 0xF9, 0x70, 0x76, 0xF0, 0xC5, 0xF0, 0x78, 0x0E, 0xDB, 0x70, -0x78, 0xD0, 0xA7, 0xF0, 0x79, 0xEE, 0xBD, 0x70, 0x7A, 0xB0, 0x89, 0xF0, 0x7B, 0xCE, 0x9F, 0x70, -0x7C, 0x99, 0xA6, 0x70, 0x7D, 0xAE, 0x81, 0x70, 0x7E, 0x79, 0x88, 0x70, 0x7F, 0x8E, 0x63, 0x70, -0x02, 0x01, 0x02, 0x03, 0x01, 0x03, 0x05, 0x04, 0x05, 0x06, 0x05, 0x04, 0x07, 0x04, 0x05, 0x04, -0x05, 0x04, 0x05, 0x04, 0x05, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, -0x09, 0x08, 0x0A, 0x0B, 0x08, 0x05, 0x04, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, +0x4B, 0xAE, 0x8D, 0xF0, 0x4C, 0xCC, 0xA3, 0x70, 0x4D, 0x8E, 0x6F, 0xF0, 0x02, 0x01, 0x02, 0x03, +0x01, 0x03, 0x05, 0x04, 0x05, 0x06, 0x05, 0x04, 0x07, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, +0x05, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x0A, 0x0B, +0x08, 0x05, 0x04, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, -0x08, 0x00, 0x00, 0x23, 0x28, 0x00, 0x00, 0x00, 0x00, 0x31, 0x68, 0x01, 0x04, 0x00, 0x00, 0x23, -0x58, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x78, 0x01, 0x08, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, -0x00, 0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x46, 0x50, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, -0x15, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x2A, -0x30, 0x01, 0x19, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x15, 0x4D, 0x4D, 0x54, 0x00, 0x4D, 0x53, 0x54, -0x00, 0x4D, 0x44, 0x53, 0x54, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x4D, 0x53, 0x44, 0x00, 0x45, 0x45, -0x54, 0x00, 0x45, 0x45, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, -0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, +0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x0C, 0x00, 0x00, 0x23, 0x28, 0x00, 0x00, 0x00, 0x00, +0x31, 0x68, 0x01, 0x04, 0x00, 0x00, 0x23, 0x58, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x78, 0x01, 0x08, +0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x46, 0x50, +0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x15, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, +0x38, 0x40, 0x01, 0x11, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x19, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x15, +0x00, 0x00, 0x38, 0x40, 0x00, 0x0D, 0x4D, 0x4D, 0x54, 0x00, 0x4D, 0x53, 0x54, 0x00, 0x4D, 0x44, +0x53, 0x54, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x4D, 0x53, 0x44, 0x00, 0x45, 0x45, 0x54, 0x00, 0x45, +0x45, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, +0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, +0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, /* Zulu */ 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -18412,4 +18157,4 @@ const unsigned char timelib_timezone_db_data_builtin[262068] = { 0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, }; -const timelib_tzdb timezonedb_builtin = { "2011.7", 571, timezonedb_idx_builtin, timelib_timezone_db_data_builtin }; +const timelib_tzdb timezonedb_builtin = { "2011.8", 573, timezonedb_idx_builtin, timelib_timezone_db_data_builtin }; From 74c6b760932cf57c709543521d38974a8e0fd7fb Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 27 Jun 2011 20:28:30 +0000 Subject: [PATCH 0239/2394] Fix 5.1 detection on ubuntu natty --- ext/dba/config.m4 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ext/dba/config.m4 b/ext/dba/config.m4 index 0746602104ffc..4b123518b46a3 100644 --- a/ext/dba/config.m4 +++ b/ext/dba/config.m4 @@ -311,7 +311,7 @@ if test "$PHP_DB4" != "no"; then PHP_DBA_STD_BEGIN dbdp4="/usr/local/BerkeleyDB.4." dbdp5="/usr/local/BerkeleyDB.5." - for i in $PHP_DB4 ${dbdp5}0 ${dbdp4}8 ${dbdp4}7 ${dbdp4}6 ${dbdp4}5 ${dbdp4}4 ${dbdp4}3 ${dbdp4}2 ${dbdp4}1 ${dbdp}0 /usr/local /usr; do + for i in $PHP_DB4 ${dbdp5}1 ${dbdp5}0 ${dbdp4}8 ${dbdp4}7 ${dbdp4}6 ${dbdp4}5 ${dbdp4}4 ${dbdp4}3 ${dbdp4}2 ${dbdp4}1 ${dbdp}0 /usr/local /usr; do if test -f "$i/db5/db.h"; then THIS_PREFIX=$i THIS_INCLUDE=$i/db5/db.h @@ -320,6 +320,10 @@ if test "$PHP_DB4" != "no"; then THIS_PREFIX=$i THIS_INCLUDE=$i/db4/db.h break + elif test -f "$i/include/db5.1/db.h"; then + THIS_PREFIX=$i + THIS_INCLUDE=$i/include/db5.1/db.h + break elif test -f "$i/include/db5.0/db.h"; then THIS_PREFIX=$i THIS_INCLUDE=$i/include/db5.0/db.h @@ -358,7 +362,7 @@ if test "$PHP_DB4" != "no"; then break fi done - PHP_DBA_DB_CHECK(4, db-5.0 db-4.8 db-4.7 db-4.6 db-4.5 db-4.4 db-4.3 db-4.2 db-4.1 db-4.0 db-4 db4 db, [(void)db_create((DB**)0, (DB_ENV*)0, 0)]) + PHP_DBA_DB_CHECK(4, db-5.1 db-5.0 db-4.8 db-4.7 db-4.6 db-4.5 db-4.4 db-4.3 db-4.2 db-4.1 db-4.0 db-4 db4 db, [(void)db_create((DB**)0, (DB_ENV*)0, 0)]) fi PHP_DBA_STD_RESULT(db4,Berkeley DB4) From fe62d3739b1405c1cf9f5864ab66d030b2798b09 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Mon, 27 Jun 2011 22:58:59 +0000 Subject: [PATCH 0240/2394] Keep the DBA DB4 test status quo after Berkeley DB 5.2 introduced error message prefixes --- ext/dba/dba_db4.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/dba/dba_db4.c b/ext/dba/dba_db4.c index a935485387875..b47aed160c51f 100644 --- a/ext/dba/dba_db4.c +++ b/ext/dba/dba_db4.c @@ -46,11 +46,12 @@ static void php_dba_db4_errcall_fcn( #if (DB_VERSION_MAJOR == 5 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 8)) /* Bug 51086, Berkeley DB 4.8.26 */ -/* This code suppresses a BDB 4.8 error message that BDB incorrectly emits */ +/* This code suppresses a BDB 4.8+ error message, thus keeping PHP test compatibility */ { char *function = get_active_function_name(TSRMLS_C); if (function && (!strcmp(function,"dba_popen") || !strcmp(function,"dba_open")) - && !strncmp(msg, "fop_read_meta", sizeof("fop_read_meta")-1)) { + && (!strncmp(msg, "fop_read_meta", sizeof("fop_read_meta")-1) + || !strncmp(msg, "BDB0004 fop_read_meta", sizeof("BDB0004 fop_read_meta")-1))) { return; } } From f7a024023ffacbe0161c1588151a703c0e4dd306 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 27 Jun 2011 23:18:26 +0000 Subject: [PATCH 0241/2394] - Fixed crash on invalid addr:port (Chris Jones, Felipe) --- sapi/cli/php_cli_server.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index f7b4d8ad5b57a..f8c68148f85ec 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -360,6 +360,9 @@ static int sapi_cli_server_startup(sapi_module_struct *sapi_module) /* {{{ */ static int sapi_cli_server_ub_write(const char *str, uint str_length TSRMLS_DC) /* {{{ */ { php_cli_server_client *client = SG(server_context); + if (!client) { + return 0; + } if (client->capturing) { php_cli_server_chunk *chunk = php_cli_server_chunk_heap_new_self_contained(str_length); if (!chunk) { @@ -400,7 +403,7 @@ static int sapi_cli_server_send_headers(sapi_headers_struct *sapi_headers TSRMLS sapi_header_struct *h; zend_llist_position pos; - if (client->capturing || SG(request_info).no_headers) { + if (client == NULL || client->capturing || SG(request_info).no_headers) { return SAPI_HEADER_SENT_SUCCESSFULLY; } @@ -1506,7 +1509,9 @@ static int php_cli_server_send_error_page(php_cli_server *server, php_cli_server php_cli_server_client_begin_capture(client); zend_try { php_info_print_style(TSRMLS_C); - php_cli_server_buffer_append(&client->content_sender.buffer, client->capture_buffer.first); + if (client->capture_buffer.first) { + php_cli_server_buffer_append(&client->content_sender.buffer, client->capture_buffer.first); + } client->capture_buffer.first = client->capture_buffer.last = NULL; } zend_catch { err = 1; @@ -1785,7 +1790,11 @@ static int php_cli_server_ctor(php_cli_server *server, const char *addr, const c php_socket_t server_sock = SOCK_ERR; host = pestrdup(addr, 1); - if (!host) { + if (!host || *host == ':' ) { + if (host) { + pefree(host, 1); + } + fprintf(stderr, "Invalid built-in web-server addr:port argument\n"); return FAILURE; } From 299eea40e7ac8db14603d8fb4e77a4af2ca3c18f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Tue, 28 Jun 2011 10:27:29 +0000 Subject: [PATCH 0242/2394] - Fixed socket_import_stream returning NULL on some errors and FALSE on others --- ext/sockets/sockets.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 456e89d087545..42af613a98be1 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -2520,6 +2520,7 @@ PHP_FUNCTION(socket_import_stream) error: if (retsock != NULL) efree(retsock); + RETURN_FALSE; } /* }}} */ From e53ca46fc06ce3e45ef5af4c5380a152d4707a2c Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Tue, 28 Jun 2011 11:09:06 +0000 Subject: [PATCH 0243/2394] Fixed bug #54971 (Wrong result when using iterator_to_array with use_keys on true) --- ext/spl/spl_iterators.c | 2 ++ ext/spl/tests/bug54971.phpt | 45 +++++++++++++++++++++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 ext/spl/tests/bug54971.phpt diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index d8ee7c525fa4b..e062486731517 100755 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -3446,6 +3446,7 @@ PHPAPI int spl_iterator_apply(zval *obj, spl_iterator_apply_func_t apply_func, v goto done; } + iter->index = 0; if (iter->funcs->rewind) { iter->funcs->rewind(iter TSRMLS_CC); if (EG(exception)) { @@ -3460,6 +3461,7 @@ PHPAPI int spl_iterator_apply(zval *obj, spl_iterator_apply_func_t apply_func, v if (apply_func(iter, puser TSRMLS_CC) == ZEND_HASH_APPLY_STOP || EG(exception)) { goto done; } + iter->index++; iter->funcs->move_forward(iter TSRMLS_CC); if (EG(exception)) { goto done; diff --git a/ext/spl/tests/bug54971.phpt b/ext/spl/tests/bug54971.phpt new file mode 100644 index 0000000000000..166613b434e3e --- /dev/null +++ b/ext/spl/tests/bug54971.phpt @@ -0,0 +1,45 @@ +--TEST-- +Bug #54971 (Wrong result when using iterator_to_array with use_keys on true) +--FILE-- + +val1 +val2 + +XML; + + +$doc = new DOMDocument(); +$doc->loadXML($source); + +$xpath = new DOMXPath($doc); +$items = $xpath->query('//node'); + +print_r(iterator_to_array($items, false)); +print_r(iterator_to_array($items, true)); +?> +--EXPECT-- +Array +( + [0] => DOMElement Object + ( + ) + + [1] => DOMElement Object + ( + ) + +) +Array +( + [0] => DOMElement Object + ( + ) + + [1] => DOMElement Object + ( + ) + +) From dedab512698c4577e75ebff7128212edc807a3d5 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Tue, 28 Jun 2011 18:58:07 +0000 Subject: [PATCH 0244/2394] clarify sqlite deprecation --- NEWS | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 284dd853508f5..3ef7f8e064925 100644 --- a/NEWS +++ b/NEWS @@ -19,7 +19,8 @@ PHP NEWS . y2k_compliance ini option. (Kalle) - Moved extensions to PECL: (Johannes) - . ext/sqlite. + . ext/sqlite. (Note: the ext/sqlite3 and ext/pdo_sqlite extensions are + not affected) - Changed $_SERVER['REQUEST_TIME'] to include microsecond precision. (Ilia) - Changed default value of "default_charset" php.ini option from ISO-8859-1 to From 9fd561fe611b15a6e49f19c289a999442654dd0a Mon Sep 17 00:00:00 2001 From: Knut Urdalen Date: Tue, 28 Jun 2011 20:17:15 +0000 Subject: [PATCH 0245/2394] working on test coverage for ext/dom, here's 17 more tests --- .../tests/DOMDocument_loadHTML_error1.phpt | 15 +++++++ .../tests/DOMDocument_loadHTML_error2.phpt | 15 +++++++ ...MDocument_relaxNGValidateSource_basic.phpt | 39 ++++++++++++++++++ ...Document_relaxNGValidateSource_error1.phpt | 41 +++++++++++++++++++ ...Document_relaxNGValidateSource_error2.phpt | 39 ++++++++++++++++++ .../DOMDocument_relaxNGValidate_basic.phpt | 24 +++++++++++ .../DOMDocument_relaxNGValidate_basic.rng | 11 +++++ .../DOMDocument_relaxNGValidate_error1.phpt | 26 ++++++++++++ .../DOMDocument_relaxNGValidate_error2.phpt | 25 +++++++++++ ...plementation_createDocumentType_basic.phpt | 18 ++++++++ ...OMImplementation_createDocument_basic.phpt | 14 +++++++ .../DOMImplementation_hasFeature_basic.phpt | 15 +++++++ ext/dom/tests/DOMNode_C14NFile_basic.phpt | 38 +++++++++++++++++ ext/dom/tests/DOMNode_C14N_basic.phpt | 29 +++++++++++++ ext/dom/tests/DOMNode_getLineNo_basic.phpt | 19 +++++++++ ext/dom/tests/DOMNode_getNodePath_basic.phpt | 19 +++++++++ .../tests/DOMNode_insertBefore_error1.phpt | 24 +++++++++++ 17 files changed, 411 insertions(+) create mode 100644 ext/dom/tests/DOMDocument_loadHTML_error1.phpt create mode 100644 ext/dom/tests/DOMDocument_loadHTML_error2.phpt create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidateSource_basic.phpt create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidateSource_error1.phpt create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidateSource_error2.phpt create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidate_basic.phpt create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidate_basic.rng create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidate_error1.phpt create mode 100644 ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt create mode 100644 ext/dom/tests/DOMImplementation_createDocumentType_basic.phpt create mode 100644 ext/dom/tests/DOMImplementation_createDocument_basic.phpt create mode 100644 ext/dom/tests/DOMImplementation_hasFeature_basic.phpt create mode 100644 ext/dom/tests/DOMNode_C14NFile_basic.phpt create mode 100644 ext/dom/tests/DOMNode_C14N_basic.phpt create mode 100644 ext/dom/tests/DOMNode_getLineNo_basic.phpt create mode 100644 ext/dom/tests/DOMNode_getNodePath_basic.phpt create mode 100644 ext/dom/tests/DOMNode_insertBefore_error1.phpt diff --git a/ext/dom/tests/DOMDocument_loadHTML_error1.phpt b/ext/dom/tests/DOMDocument_loadHTML_error1.phpt new file mode 100644 index 0000000000000..c7b5e614d7cd3 --- /dev/null +++ b/ext/dom/tests/DOMDocument_loadHTML_error1.phpt @@ -0,0 +1,15 @@ +--TEST-- +DOMDocument::loadHTML() should fail if no parameter is given +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- +loadHTML(); +?> +--EXPECTF-- +Warning: DOMDocument::loadHTML() expects exactly 1 parameter, 0 given in %s on line %d diff --git a/ext/dom/tests/DOMDocument_loadHTML_error2.phpt b/ext/dom/tests/DOMDocument_loadHTML_error2.phpt new file mode 100644 index 0000000000000..3167c0189034a --- /dev/null +++ b/ext/dom/tests/DOMDocument_loadHTML_error2.phpt @@ -0,0 +1,15 @@ +--TEST-- +DOMDocument::loadHTML() should fail if empty string provided as input +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- +loadHTML(''); +?> +--EXPECTF-- +Warning: DOMDocument::loadHTML(): Empty string supplied as input in %s on line %d diff --git a/ext/dom/tests/DOMDocument_relaxNGValidateSource_basic.phpt b/ext/dom/tests/DOMDocument_relaxNGValidateSource_basic.phpt new file mode 100644 index 0000000000000..93b9cf717374b --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidateSource_basic.phpt @@ -0,0 +1,39 @@ +--TEST-- +DOMDocument::relaxNGValidateSource() +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- + + + + + + + + + + +RNG; + +$good_xml = <<< GOOD_XML + + + Pear + +GOOD_XML; + +$doc = new DOMDocument(); +$doc->loadXML($good_xml); +$result = $doc->relaxNGValidateSource($rng); +var_dump($result); + +?> +--EXPECTF-- +bool(true) diff --git a/ext/dom/tests/DOMDocument_relaxNGValidateSource_error1.phpt b/ext/dom/tests/DOMDocument_relaxNGValidateSource_error1.phpt new file mode 100644 index 0000000000000..7da71a57a190c --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidateSource_error1.phpt @@ -0,0 +1,41 @@ +--TEST-- +DOMDocument::relaxNGValidateSource() should fail if document doesn't validate +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- + + + + + + + + + + +RNG; + +$bad_xml = <<< BAD_XML + + + Pear + Pear + +BAD_XML; + +$doc = new DOMDocument(); +$doc->loadXML($bad_xml); +$result = $doc->relaxNGValidateSource($rng); +var_dump($result); + +?> +--EXPECTF-- +Warning: DOMDocument::relaxNGValidateSource(): Did not expect element pear there in %s on line %d +bool(false) diff --git a/ext/dom/tests/DOMDocument_relaxNGValidateSource_error2.phpt b/ext/dom/tests/DOMDocument_relaxNGValidateSource_error2.phpt new file mode 100644 index 0000000000000..d689934f4e8bf --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidateSource_error2.phpt @@ -0,0 +1,39 @@ +--TEST-- +DOMDocument::relaxNGValidateSource() should fail on invalid RNG schema +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- + + + + + + + +RNG; + +$xml = <<< XML + + + Pear + +XML; + +$doc = new DOMDocument(); +$doc->loadXML($xml); +$result = $doc->relaxNGValidateSource($rng); +var_dump($result); + +?> +--EXPECTF-- +Warning: DOMDocument::relaxNGValidateSource(): xmlRelaxNGParseElement: element has no content in %s on line %d + +Warning: DOMDocument::relaxNGValidateSource(): Invalid RelaxNG in %s on line %d +bool(false) diff --git a/ext/dom/tests/DOMDocument_relaxNGValidate_basic.phpt b/ext/dom/tests/DOMDocument_relaxNGValidate_basic.phpt new file mode 100644 index 0000000000000..76a64425cebc2 --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidate_basic.phpt @@ -0,0 +1,24 @@ +--TEST-- +DOMDocument::relaxNGValidate() +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- + + + Pear + +XML; +$doc = new DOMDocument(); +$doc->loadXML($xml); +$result = $doc->relaxNGValidate($rng); +var_dump($result); +?> +--EXPECTF-- +bool(true) diff --git a/ext/dom/tests/DOMDocument_relaxNGValidate_basic.rng b/ext/dom/tests/DOMDocument_relaxNGValidate_basic.rng new file mode 100644 index 0000000000000..35e3518443260 --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidate_basic.rng @@ -0,0 +1,11 @@ + + + + + + + + + + diff --git a/ext/dom/tests/DOMDocument_relaxNGValidate_error1.phpt b/ext/dom/tests/DOMDocument_relaxNGValidate_error1.phpt new file mode 100644 index 0000000000000..82957c35bd588 --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidate_error1.phpt @@ -0,0 +1,26 @@ +--TEST-- +DOMDocument::relaxNGValidate() should fail if document doesn't validate +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- + + + Pear + Pear + +XML; +$doc = new DOMDocument(); +$doc->loadXML($xml); +$result = $doc->relaxNGValidate($rng); +var_dump($result); +?> +--EXPECTF-- +Warning: DOMDocument::relaxNGValidate(): Did not expect element pear there in %s on line %d +bool(false) diff --git a/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt b/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt new file mode 100644 index 0000000000000..85749210b0812 --- /dev/null +++ b/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt @@ -0,0 +1,25 @@ +--TEST-- +DOMDocument::relaxNGValidate() should fail on invalid RelaxNG file source +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- + + + Pear + Pear + +XML; +$doc = new DOMDocument(); +$doc->loadXML($xml); +$result = $doc->relaxNGValidate($rng); +var_dump($result); +?> +--EXPECTF-- + diff --git a/ext/dom/tests/DOMImplementation_createDocumentType_basic.phpt b/ext/dom/tests/DOMImplementation_createDocumentType_basic.phpt new file mode 100644 index 0000000000000..3b19ea461457a --- /dev/null +++ b/ext/dom/tests/DOMImplementation_createDocumentType_basic.phpt @@ -0,0 +1,18 @@ +--TEST-- +DOMImplementation::createDocumentType() +--SKIPIF-- + +--FILE-- +createDocumentType("html", + "-//W3C//DTD XHTML 1.0 Strict//EN", + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"); +$doc = $imp->createDocument(null, 'html', $doctype); +echo $doc->saveHTML(); +?> +--EXPECTF-- + + diff --git a/ext/dom/tests/DOMImplementation_createDocument_basic.phpt b/ext/dom/tests/DOMImplementation_createDocument_basic.phpt new file mode 100644 index 0000000000000..78d20aeee5fad --- /dev/null +++ b/ext/dom/tests/DOMImplementation_createDocument_basic.phpt @@ -0,0 +1,14 @@ +--TEST-- +DOMImplementation::createDocument() +--SKIPIF-- + +--FILE-- +createDocument(null, 'html'); +echo $doc->saveHTML(); +?> +--EXPECTF-- + diff --git a/ext/dom/tests/DOMImplementation_hasFeature_basic.phpt b/ext/dom/tests/DOMImplementation_hasFeature_basic.phpt new file mode 100644 index 0000000000000..b53e912b779f3 --- /dev/null +++ b/ext/dom/tests/DOMImplementation_hasFeature_basic.phpt @@ -0,0 +1,15 @@ +--TEST-- +DOMImplementation::hasFeature() +--SKIPIF-- + +--FILE-- +hasFeature('Core', '1.0')); +var_dump($imp->hasFeature('XML', '2.0')); +?> +--EXPECTF-- +bool(true) +bool(true) diff --git a/ext/dom/tests/DOMNode_C14NFile_basic.phpt b/ext/dom/tests/DOMNode_C14NFile_basic.phpt new file mode 100644 index 0000000000000..6af6e3ecb28c7 --- /dev/null +++ b/ext/dom/tests/DOMNode_C14NFile_basic.phpt @@ -0,0 +1,38 @@ +--TEST-- +DOMNode::C14NFile() +--SKIPIF-- + +--FILE-- + + + + The Grapes of Wrath + John Steinbeck + + + The Pearl + John Steinbeck + + +XML; + +$output = dirname(__FILE__).'/DOMNode_C14NFile_basic.tmp'; +$doc = new DOMDocument(); +$doc->loadXML($xml); +$node = $doc->getElementsByTagName('title')->item(0); +var_dump($node->C14NFile($output)); +$content = file_get_contents($output); +var_dump($content); +?> +--CLEAN-- + +--EXPECTF-- +int(34) +string(34) "The Grapes of Wrath" diff --git a/ext/dom/tests/DOMNode_C14N_basic.phpt b/ext/dom/tests/DOMNode_C14N_basic.phpt new file mode 100644 index 0000000000000..52a47a15d2716 --- /dev/null +++ b/ext/dom/tests/DOMNode_C14N_basic.phpt @@ -0,0 +1,29 @@ +--TEST-- +DOMNode::C14N() +--SKIPIF-- + +--FILE-- + + + + The Grapes of Wrath + John Steinbeck + + + The Pearl + John Steinbeck + + +XML; + +$doc = new DOMDocument(); +$doc->loadXML($xml); +$node = $doc->getElementsByTagName('title')->item(0); +var_dump($node->C14N()); +?> +--EXPECTF-- +string(34) "The Grapes of Wrath" diff --git a/ext/dom/tests/DOMNode_getLineNo_basic.phpt b/ext/dom/tests/DOMNode_getLineNo_basic.phpt new file mode 100644 index 0000000000000..3f57681c3e072 --- /dev/null +++ b/ext/dom/tests/DOMNode_getLineNo_basic.phpt @@ -0,0 +1,19 @@ +--TEST-- +DOMNode::getLineNo() +--SKIPIF-- + +--FILE-- +load($file); +$nodes = $doc->getElementsByTagName('title'); +foreach($nodes as $node) { + var_dump($node->getLineNo()); +} +?> +--EXPECTF-- +int(4) +int(8) diff --git a/ext/dom/tests/DOMNode_getNodePath_basic.phpt b/ext/dom/tests/DOMNode_getNodePath_basic.phpt new file mode 100644 index 0000000000000..7c14ffab9091c --- /dev/null +++ b/ext/dom/tests/DOMNode_getNodePath_basic.phpt @@ -0,0 +1,19 @@ +--TEST-- +DOMNode::getNodePath() +--SKIPIF-- + +--FILE-- +load($file); +$nodes = $doc->getElementsByTagName('title'); +foreach($nodes as $node) { + var_dump($node->getNodePath()); +} +?> +--EXPECTF-- +string(20) "/books/book[1]/title" +string(20) "/books/book[2]/title" diff --git a/ext/dom/tests/DOMNode_insertBefore_error1.phpt b/ext/dom/tests/DOMNode_insertBefore_error1.phpt new file mode 100644 index 0000000000000..d655479d00434 --- /dev/null +++ b/ext/dom/tests/DOMNode_insertBefore_error1.phpt @@ -0,0 +1,24 @@ +--TEST-- +DOMNode::insertBefore() should fail if node belongs to another document +--CREDITS-- +Knut Urdalen +--SKIPIF-- + +--FILE-- +createElement("foo"); +$node_in_doc2 = $doc2->createElement("bar"); + +try { + $node_in_doc2->insertBefore($node_in_doc1); +} catch(DOMException $e) { + echo $e->getMessage(); +} + +?> +--EXPECTF-- +Wrong Document Error From b2a3d3132d5e22abe898fb0368c219373d2b1e98 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 28 Jun 2011 23:47:05 +0000 Subject: [PATCH 0246/2394] Fixed test --- .../serialization_miscTypes_001.phpt | Bin 7587 -> 7586 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/standard/tests/serialize/serialization_miscTypes_001.phpt b/ext/standard/tests/serialize/serialization_miscTypes_001.phpt index d939274a01068656796adfccc1bf31d07967f5fa..038068249effa2c720ddfcc39512f7a6050ea5d5 100644 GIT binary patch delta 24 fcmZ2%y~uil7C*C*vE^o6el}(%OS8>pLb==kS55{Z delta 25 gcmZ2vz1Vt#7C*DGf$?Ttel})iLnF)0rb4;g09=6vM*si- From 8c3ef4a222112b0f593d266b1b06b0750cd25d2b Mon Sep 17 00:00:00 2001 From: Peter Cowburn Date: Wed, 29 Jun 2011 09:00:37 +0000 Subject: [PATCH 0247/2394] Fix NEWS --- NEWS | 1 - 1 file changed, 1 deletion(-) diff --git a/NEWS b/NEWS index 3ef7f8e064925..99b272d5b1328 100644 --- a/NEWS +++ b/NEWS @@ -201,7 +201,6 @@ PHP NEWS - Improved SPL extension: . Added RegexIterator::getRegex() method. (Joshua Thijssen) . Added SplObjectStorage::getHash() hook. (Etienne) - . Added SplFileInfo::getExtension(). FR #48767. (Peter Cowburn) . Added CallbackFilterIterator and RecursiveCallbackFilterIterator (Arnaud) - Improved ZLIB extension: From 5024c3279818a5b55c6ebc2c3382c1b0d2675ec3 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 29 Jun 2011 23:29:01 +0000 Subject: [PATCH 0248/2394] fix #55072 in-built web server needs to check -t option is a directory --- sapi/cli/php_cli_server.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index f8c68148f85ec..b0423a1a4f770 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -88,6 +88,10 @@ # define SOCK_EADDRINUSE WSAEADDRINUSE #endif +#ifndef S_ISDIR +#define S_ISDIR(mode) (((mode)&S_IFMT) == S_IFDIR) +#endif + #include "ext/standard/file.h" /* for php_set_sock_blocking() :-( */ #include "ext/standard/php_smart_str.h" #include "ext/standard/html.h" @@ -2060,6 +2064,10 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ fprintf(stderr, "Directory or script %s does not exist.\n", document_root); return 1; } + if (!S_ISDIR(sb.st_mode)) { + fprintf(stderr, "%s is not a directory.\n", document_root); + return 1; + } } else { document_root = "."; } From cdad24cda58947161e2cb93b035264569e277f51 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 29 Jun 2011 23:44:02 +0000 Subject: [PATCH 0249/2394] correct error message for a missing document root in the cli webserver the document root is always a directory. --- sapi/cli/php_cli_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index b0423a1a4f770..1eec3a4f1bee8 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2061,7 +2061,7 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ if (document_root) { struct stat sb; if (stat(document_root, &sb)) { - fprintf(stderr, "Directory or script %s does not exist.\n", document_root); + fprintf(stderr, "Directory %s does not exist.\n", document_root); return 1; } if (!S_ISDIR(sb.st_mode)) { From 86ff3bab2d329be319e618046753353d1afcf246 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Thu, 30 Jun 2011 09:26:35 +0000 Subject: [PATCH 0250/2394] - Fixed bug #55082 (var_export() doesn't escape properties properly). --- .../tests/general_functions/var_export_basic9.phpt | 11 +++++++++++ ext/standard/var.c | 14 +++++++++++--- 2 files changed, 22 insertions(+), 3 deletions(-) create mode 100644 ext/standard/tests/general_functions/var_export_basic9.phpt diff --git a/ext/standard/tests/general_functions/var_export_basic9.phpt b/ext/standard/tests/general_functions/var_export_basic9.phpt new file mode 100644 index 0000000000000..3c9706edfd0d8 --- /dev/null +++ b/ext/standard/tests/general_functions/var_export_basic9.phpt @@ -0,0 +1,11 @@ +--TEST-- +Bug #55082: var_export() doesn't escape properties properly +--FILE-- +{'\'\\'} = 7; + echo var_export($x); +--EXPECT-- +stdClass::__set_state(array( + '\'\\' => 7, +)) diff --git a/ext/standard/var.c b/ext/standard/var.c index b715af4701e42..82d701cfa4250 100644 --- a/ext/standard/var.c +++ b/ext/standard/var.c @@ -384,18 +384,26 @@ static int php_object_element_export(zval **zv TSRMLS_DC, int num_args, va_list { int level; smart_str *buf; - char *prop_name, *class_name; level = va_arg(args, int); buf = va_arg(args, smart_str *); buffer_append_spaces(buf, level + 2); if (hash_key->nKeyLength != 0) { - zend_unmangle_property_name(hash_key->arKey, hash_key->nKeyLength - 1, &class_name, &prop_name); + char *class_name, /* ignored, but must be passed to unmangle */ + *pname, + *pname_esc; + int pname_esc_len; + + zend_unmangle_property_name(hash_key->arKey, hash_key->nKeyLength - 1, + &class_name, &pname); + pname_esc = php_addcslashes(pname, strlen(pname), &pname_esc_len, 0, + "'\\", 2 TSRMLS_CC); smart_str_appendc(buf, '\''); - smart_str_appends(buf, prop_name); + smart_str_appendl(buf, pname_esc, pname_esc_len); smart_str_appendc(buf, '\''); + efree(pname_esc); } else { smart_str_append_long(buf, (long) hash_key->h); } From 7497a0eb4a8057b8f194962066db07230974eea2 Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Thu, 30 Jun 2011 23:50:56 +0000 Subject: [PATCH 0251/2394] Updated name to 'PHP Development Server', and CTRL-C to Ctrl-C, as per PHP bug #55071 --- sapi/cli/php_cli_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 1eec3a4f1bee8..ab2dc6c32b691 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2081,7 +2081,7 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ } sapi_module.phpinfo_as_text = 0; - printf("Server is listening on %s:%d in %s ... Press CTRL-C to quit.\n", server.host, server.port, document_root); + printf("PHP Development Server is listening on %s:%d in %s ... Press Ctrl-C to quit.\n", server.host, server.port, document_root); #if defined(HAVE_SIGNAL_H) && defined(SIGINT) signal(SIGINT, php_cli_server_sigint_handler); From 4296f07fcc7974fef8fe4fe87f0ee16fe919496f Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 1 Jul 2011 17:18:50 +0000 Subject: [PATCH 0252/2394] - Reverted php_printf -> printf change --- sapi/cli/php_cli.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 81a2d259593bb..64278af0da92a 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -172,7 +172,7 @@ const opt_struct OPTIONS[] = { static int print_module_info(zend_module_entry *module TSRMLS_DC) /* {{{ */ { - printf("%s\n", module->name); + php_printf("%s\n", module->name); return ZEND_HASH_APPLY_KEEP; } /* }}} */ @@ -202,7 +202,7 @@ static void print_modules(TSRMLS_D) /* {{{ */ static int print_extension_info(zend_extension *ext, void *arg TSRMLS_DC) /* {{{ */ { - printf("%s\n", ext->name); + php_printf("%s\n", ext->name); return ZEND_HASH_APPLY_KEEP; } /* }}} */ From 93acedd1ffe094e6173e5e882afb34b7f43b8fc6 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 1 Jul 2011 23:13:53 +0000 Subject: [PATCH 0253/2394] - Fixed bug #55080 (Deprecated call in run--test.php) patch by: fedora at famillecollet dot com --- run-tests.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/run-tests.php b/run-tests.php index 0b0b253c15dd4..a615efccdcff8 100755 --- a/run-tests.php +++ b/run-tests.php @@ -491,7 +491,7 @@ function save_or_mail_results() $argv = array(__FILE__); } - $argv = array_merge($argv, split(' ', getenv('TEST_PHP_ARGS'))); + $argv = array_merge($argv, explode(' ', getenv('TEST_PHP_ARGS'))); $argc = count($argv); } From be0e5d7f957f881abc3c91c1c72590c852f77aef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sat, 2 Jul 2011 12:03:32 +0000 Subject: [PATCH 0254/2394] - Fixed bug #55111 (sockets extension fails to compile on Mac OSX). --- ext/sockets/sockets.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 42af613a98be1..6b5631c9fbd8f 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -2202,11 +2202,13 @@ PHP_FUNCTION(socket_set_option) else if (level == IPPROTO_IPV6) { switch (optname) { case MCAST_JOIN_GROUP: - case MCAST_LEAVE_GROUP: + case MCAST_LEAVE_GROUP: +#ifdef HAS_MCAST_EXT case MCAST_BLOCK_SOURCE: case MCAST_UNBLOCK_SOURCE: case MCAST_JOIN_SOURCE_GROUP: case MCAST_LEAVE_SOURCE_GROUP: +#endif if (php_do_mcast_opt(php_sock, level, optname, arg4 TSRMLS_CC) == FAILURE) { RETURN_FALSE; } else { From 2fb5b8200b898f577d3fee3924fa2fd1af3ca0e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 2 Jul 2011 16:10:18 +0000 Subject: [PATCH 0255/2394] - Implemented FR #54577 (Enhanced status page with full status and details about each processes - Added a web page (status.html) for real-time FPM status - Fixed missing Expires and Cache-Control headers for ping and status pages --- sapi/fpm/Makefile.frag | 3 + sapi/fpm/fpm/fpm.c | 1 - sapi/fpm/fpm/fpm_children.c | 3 +- sapi/fpm/fpm/fpm_log.c | 43 +--- sapi/fpm/fpm/fpm_log.h | 1 - sapi/fpm/fpm/fpm_request.c | 29 ++- sapi/fpm/fpm/fpm_request.h | 1 + sapi/fpm/fpm/fpm_scoreboard.c | 47 +++- sapi/fpm/fpm/fpm_scoreboard.h | 11 +- sapi/fpm/fpm/fpm_status.c | 290 +++++++++++++++++++-- sapi/fpm/php-fpm.conf.in | 92 +++++-- sapi/fpm/status.html | 459 ++++++++++++++++++++++++++++++++++ 12 files changed, 886 insertions(+), 94 deletions(-) create mode 100644 sapi/fpm/status.html diff --git a/sapi/fpm/Makefile.frag b/sapi/fpm/Makefile.frag index 6da67f952ed21..6ed9e4a24976c 100644 --- a/sapi/fpm/Makefile.frag +++ b/sapi/fpm/Makefile.frag @@ -18,3 +18,6 @@ install-fpm: $(SAPI_FPM_PATH) @$(mkinstalldirs) $(INSTALL_ROOT)$(mandir)/man8 @$(INSTALL_DATA) sapi/fpm/php-fpm.8 $(INSTALL_ROOT)$(mandir)/man8/php-fpm$(program_suffix).8 + @echo "Installing PHP FPM status page: $(INSTALL_ROOT)$(datadir)/fpm/" + @$(mkinstalldirs) $(INSTALL_ROOT)$(datadir)/fpm + @$(INSTALL_DATA) sapi/fpm/status.html $(INSTALL_ROOT)$(datadir)/fpm/status.html diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index b0b3b2b7a4cdd..13106dfe4d8e1 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -49,7 +49,6 @@ int fpm_init(int argc, char **argv, char *config, char *prefix, int test_conf) / if (0 > fpm_php_init_main() || 0 > fpm_stdio_init_main() || - 0 > fpm_log_init_main() || 0 > fpm_conf_init_main(test_conf) || 0 > fpm_unix_init_main() || 0 > fpm_scoreboard_init_main() || diff --git a/sapi/fpm/fpm/fpm_children.c b/sapi/fpm/fpm/fpm_children.c index 05d741cb89b7c..65f56e7269b15 100644 --- a/sapi/fpm/fpm/fpm_children.c +++ b/sapi/fpm/fpm/fpm_children.c @@ -344,7 +344,8 @@ static void fpm_child_resources_use(struct fpm_child_s *child) /* {{{ */ } fpm_scoreboard_free(wp->scoreboard); } - fpm_scoreboard_child_use(child->wp->scoreboard, child->scoreboard_i, child->pid); + + fpm_scoreboard_child_use(child->wp->scoreboard, child->scoreboard_i, getpid()); fpm_stdio_child_use_pipes(child); fpm_child_free(child); } diff --git a/sapi/fpm/fpm/fpm_log.c b/sapi/fpm/fpm/fpm_log.c index ef1c0c3be382c..5360c45f7acef 100644 --- a/sapi/fpm/fpm/fpm_log.c +++ b/sapi/fpm/fpm/fpm_log.c @@ -29,9 +29,6 @@ static char *fpm_log_format = NULL; static int fpm_log_fd = -1; -#ifdef HAVE_TIMES -static float tick; -#endif int fpm_log_open(int reopen) /* {{{ */ { @@ -67,24 +64,6 @@ int fpm_log_open(int reopen) /* {{{ */ } /* }}} */ -int fpm_log_init_main() /* {{{ */ -{ -#ifdef HAVE_TIMES -#if (defined(HAVE_SYSCONF) && defined(_SC_CLK_TCK)) - tick = sysconf(_SC_CLK_TCK); -#else /* _SC_CLK_TCK */ -#ifdef HZ - tick = HZ; -#else /* HZ */ - tick = 100; -#endif /* HZ */ -#endif /* _SC_CLK_TCK */ - zlog(ZLOG_DEBUG, "got clock tick '%.0f'", tick); -#endif /* HAVE_TIMES */ - return 0; -} -/* }}} */ - /* }}} */ int fpm_log_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ { @@ -122,7 +101,6 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ size_t len, len2; struct fpm_scoreboard_proc_s proc, *proc_p; struct fpm_scoreboard_s *scoreboard; - struct timeval uptime, now; char tmp[129]; char format[129]; time_t now_epoch; @@ -141,7 +119,6 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ test = 1; } - fpm_clock_get(&now); now_epoch = time(NULL); if (!test) { @@ -157,8 +134,6 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ } proc = *proc_p; fpm_scoreboard_proc_release(proc_p); - - timersub(&now, &proc.accepted, &uptime); } token = 0; @@ -198,19 +173,15 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ case 'C': /* %CPU */ if (format[0] == '\0' || !strcasecmp(format, "total")) { if (!test) { - tms_total = - (proc.cpu_finished.tms_utime + proc.cpu_finished.tms_stime + proc.cpu_finished.tms_cutime + proc.cpu_finished.tms_cstime) - - - (proc.cpu_accepted.tms_utime + proc.cpu_accepted.tms_stime + proc.cpu_accepted.tms_cutime + proc.cpu_accepted.tms_cstime) - ; + tms_total = proc.last_request_cpu.tms_utime + proc.last_request_cpu.tms_stime + proc.last_request_cpu.tms_cutime + proc.last_request_cpu.tms_cstime; } } else if (!strcasecmp(format, "user")) { if (!test) { - tms_total = (proc.cpu_finished.tms_utime + proc.cpu_finished.tms_cutime) - (proc.cpu_accepted.tms_utime + proc.cpu_accepted.tms_cutime); + tms_total = proc.last_request_cpu.tms_utime + proc.last_request_cpu.tms_cutime; } } else if (!strcasecmp(format, "system")) { if (!test) { - tms_total = (proc.cpu_finished.tms_stime + proc.cpu_finished.tms_cstime) - (proc.cpu_accepted.tms_stime + proc.cpu_accepted.tms_cstime); + tms_total = proc.last_request_cpu.tms_stime + proc.last_request_cpu.tms_cstime; } } else { zlog(ZLOG_WARNING, "only 'total', 'user' or 'system' are allowed as a modifier for %%%c ('%s')", *s, format); @@ -219,7 +190,7 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ format[0] = '\0'; if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.2f", tms_total / tick / (proc.cpu_duration.tv_sec + proc.cpu_duration.tv_usec / 1000000.) * 100.); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.2f", tms_total / fpm_scoreboard_get_tick() / (proc.cpu_duration.tv_sec + proc.cpu_duration.tv_usec / 1000000.) * 100.); } break; #endif @@ -228,19 +199,19 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ /* seconds */ if (format[0] == '\0' || !strcasecmp(format, "seconds")) { if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.3f", uptime.tv_sec + uptime.tv_usec / 1000000.); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.3f", proc.duration.tv_sec + proc.duration.tv_usec / 1000000.); } /* miliseconds */ } else if (!strcasecmp(format, "miliseconds") || !strcasecmp(format, "mili")) { if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.3f", uptime.tv_sec * 1000. + uptime.tv_usec / 1000.); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%.3f", proc.duration.tv_sec * 1000. + proc.duration.tv_usec / 1000.); } /* microseconds */ } else if (!strcasecmp(format, "microseconds") || !strcasecmp(format, "micro")) { if (!test) { - len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", uptime.tv_sec * 1000000UL + uptime.tv_usec); + len2 = snprintf(b, FPM_LOG_BUFFER - len, "%lu", proc.duration.tv_sec * 1000000UL + proc.duration.tv_usec); } } else { diff --git a/sapi/fpm/fpm/fpm_log.h b/sapi/fpm/fpm/fpm_log.h index 74f842646fa02..f0199d9cb6dc0 100644 --- a/sapi/fpm/fpm/fpm_log.h +++ b/sapi/fpm/fpm/fpm_log.h @@ -6,7 +6,6 @@ #define FPM_LOG_H 1 #include "fpm_worker_pool.h" -int fpm_log_init_main(); int fpm_log_init_child(struct fpm_worker_pool_s *wp); int fpm_log_write(char *log_format TSRMLS_DC); int fpm_log_open(int reopen); diff --git a/sapi/fpm/fpm/fpm_request.c b/sapi/fpm/fpm/fpm_request.c index e0d1815dbe99b..f94196b562f7c 100644 --- a/sapi/fpm/fpm/fpm_request.c +++ b/sapi/fpm/fpm/fpm_request.c @@ -23,6 +23,19 @@ #include "zlog.h" +static const char *requests_stages[] = { + [FPM_REQUEST_ACCEPTING] = "Idle", + [FPM_REQUEST_READING_HEADERS] = "Reading headers", + [FPM_REQUEST_INFO] = "Getting request informations", + [FPM_REQUEST_EXECUTING] = "Running", + [FPM_REQUEST_END] = "Ending", + [FPM_REQUEST_FINISHED] = "Finishing", +}; + +const char *fpm_request_get_stage_name(int stage) { + return requests_stages[stage]; +} + void fpm_request_accepting() /* {{{ */ { struct fpm_scoreboard_proc_s *proc; @@ -38,10 +51,6 @@ void fpm_request_accepting() /* {{{ */ proc->request_stage = FPM_REQUEST_ACCEPTING; proc->tv = now; - proc->request_uri[0] = '\0'; - proc->request_method[0] = '\0'; - proc->script_filename[0] = '\0'; - proc->content_length = 0; fpm_scoreboard_proc_release(proc); /* idle++, active-- */ @@ -78,6 +87,12 @@ void fpm_request_reading_headers() /* {{{ */ #ifdef HAVE_TIMES proc->cpu_accepted = cpu; #endif + proc->requests++; + proc->request_uri[0] = '\0'; + proc->request_method[0] = '\0'; + proc->script_filename[0] = '\0'; + proc->query_string[0] = '\0'; + proc->content_length = 0; fpm_scoreboard_proc_release(proc); /* idle--, active++, request++ */ @@ -176,9 +191,13 @@ void fpm_request_end(TSRMLS_D) /* {{{ */ } proc->request_stage = FPM_REQUEST_FINISHED; proc->tv = now; + timersub(&now, &proc->accepted, &proc->duration); #ifdef HAVE_TIMES - proc->cpu_finished = cpu; timersub(&proc->tv, &proc->accepted, &proc->cpu_duration); + proc->last_request_cpu.tms_utime = cpu.tms_utime - proc->cpu_accepted.tms_utime; + proc->last_request_cpu.tms_stime = cpu.tms_stime - proc->cpu_accepted.tms_stime; + proc->last_request_cpu.tms_cutime = cpu.tms_cutime - proc->cpu_accepted.tms_cutime; + proc->last_request_cpu.tms_cstime = cpu.tms_cstime - proc->cpu_accepted.tms_cstime; #endif proc->memory = memory; fpm_scoreboard_proc_release(proc); diff --git a/sapi/fpm/fpm/fpm_request.h b/sapi/fpm/fpm/fpm_request.h index b3014a5f1dcb0..05cca228b1948 100644 --- a/sapi/fpm/fpm/fpm_request.h +++ b/sapi/fpm/fpm/fpm_request.h @@ -17,6 +17,7 @@ struct timeval; void fpm_request_check_timed_out(struct fpm_child_s *child, struct timeval *tv, int terminate_timeout, int slowlog_timeout); int fpm_request_is_idle(struct fpm_child_s *child); +const char *fpm_request_get_stage_name(int stage); enum fpm_request_stage_e { FPM_REQUEST_ACCEPTING = 1, diff --git a/sapi/fpm/fpm/fpm_scoreboard.c b/sapi/fpm/fpm/fpm_scoreboard.c index a68e13ae8ddda..a980df91069c1 100644 --- a/sapi/fpm/fpm/fpm_scoreboard.c +++ b/sapi/fpm/fpm/fpm_scoreboard.c @@ -17,12 +17,30 @@ static struct fpm_scoreboard_s *fpm_scoreboard = NULL; static int fpm_scoreboard_i = -1; +#ifdef HAVE_TIMES +static float fpm_scoreboard_tick; +#endif + int fpm_scoreboard_init_main() /* {{{ */ { struct fpm_worker_pool_s *wp; int i; +#ifdef HAVE_TIMES +#if (defined(HAVE_SYSCONF) && defined(_SC_CLK_TCK)) + fpm_scoreboard_tick = sysconf(_SC_CLK_TCK); +#else /* _SC_CLK_TCK */ +#ifdef HZ + fpm_scoreboard_tick = HZ; +#else /* HZ */ + fpm_scoreboard_tick = 100; +#endif /* HZ */ +#endif /* _SC_CLK_TCK */ + zlog(ZLOG_DEBUG, "got clock tick '%.0f'", fpm_scoreboard_tick); +#endif /* HAVE_TIMES */ + + for (wp = fpm_worker_all_pools; wp; wp = wp->next) { if (wp->config->pm_max_children < 1) { zlog(ZLOG_ERROR, "[pool %s] Unable to create scoreboard SHM because max_client is not set", wp->config->name); @@ -40,7 +58,11 @@ int fpm_scoreboard_init_main() /* {{{ */ } wp->scoreboard->nprocs = wp->config->pm_max_children; for (i=0; iscoreboard->nprocs; i++) { - wp->scoreboard->procs[i] = NULL; + wp->scoreboard->procs[i] = fpm_shm_alloc(sizeof(struct fpm_scoreboard_proc_s)); + if (!wp->scoreboard->procs[i]) { + return -1; + } + memset(wp->scoreboard->procs[i], 0, sizeof(struct fpm_scoreboard_proc_s)); } wp->scoreboard->pm = wp->config->pm; @@ -229,6 +251,7 @@ void fpm_scoreboard_child_use(struct fpm_scoreboard_s *scoreboard, int child_ind return; } proc->pid = pid; + proc->start_epoch = time(NULL); } /* }}} */ @@ -242,9 +265,8 @@ void fpm_scoreboard_proc_free(struct fpm_scoreboard_s *scoreboard, int child_ind return; } - if (scoreboard->procs[child_index]) { - fpm_shm_free(scoreboard->procs[child_index], sizeof(struct fpm_scoreboard_proc_s)); - scoreboard->procs[child_index] = NULL; + if (scoreboard->procs[child_index] && scoreboard->procs[child_index]->used > 0) { + memset(scoreboard->procs[child_index], 0, sizeof(struct fpm_scoreboard_proc_s)); } /* set this slot as free to avoid search on next alloc */ @@ -262,7 +284,7 @@ int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_in /* first try the slot which is supposed to be free */ if (scoreboard->free_proc >= 0 && scoreboard->free_proc < scoreboard->nprocs) { - if (!scoreboard->procs[scoreboard->free_proc]) { + if (scoreboard->procs[scoreboard->free_proc] && !scoreboard->procs[scoreboard->free_proc]->used) { i = scoreboard->free_proc; } } @@ -270,7 +292,7 @@ int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_in if (i < 0) { /* the supposed free slot is not, let's search for a free slot */ zlog(ZLOG_DEBUG, "[pool %s] the proc->free_slot was not free. Let's search", scoreboard->pool); for (i=0; inprocs; i++) { - if (!scoreboard->procs[i]) { /* found */ + if (scoreboard->procs[i] && !scoreboard->procs[i]->used) { /* found */ break; } } @@ -282,10 +304,7 @@ int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_in return -1; } - scoreboard->procs[i] = fpm_shm_alloc(sizeof(struct fpm_scoreboard_proc_s)); - if (!scoreboard->procs[i]) { - return -1; - } + scoreboard->procs[i]->used = 1; *child_index = i; /* supposed next slot is free */ @@ -299,3 +318,11 @@ int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_in } /* }}} */ +#ifdef HAVE_TIMES +float fpm_scoreboard_get_tick() /* {{{ */ +{ + return fpm_scoreboard_tick; +} +/* }}} */ +#endif + diff --git a/sapi/fpm/fpm/fpm_scoreboard.h b/sapi/fpm/fpm/fpm_scoreboard.h index 00860878cb027..136ea481a4a5e 100644 --- a/sapi/fpm/fpm/fpm_scoreboard.h +++ b/sapi/fpm/fpm/fpm_scoreboard.h @@ -22,9 +22,13 @@ struct fpm_scoreboard_proc_s { atomic_t lock; char dummy[16]; }; + int used; + time_t start_epoch; pid_t pid; + unsigned long requests; enum fpm_request_stage_e request_stage; struct timeval accepted; + struct timeval duration; time_t accepted_epoch; struct timeval tv; char request_uri[128]; @@ -35,8 +39,9 @@ struct fpm_scoreboard_proc_s { char auth_user[32]; #ifdef HAVE_TIMES struct tms cpu_accepted; - struct tms cpu_finished; struct timeval cpu_duration; + struct tms last_request_cpu; + struct timeval last_request_cpu_duration; #endif size_t memory; }; @@ -81,4 +86,8 @@ void fpm_scoreboard_child_use(struct fpm_scoreboard_s *scoreboard, int child_ind void fpm_scoreboard_proc_free(struct fpm_scoreboard_s *scoreboard, int child_index); int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_index); +#ifdef HAVE_TIMES +float fpm_scoreboard_get_tick(); +#endif + #endif diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 9fab7e7fb3dbd..ac9365de8a0a3 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -13,6 +13,7 @@ #include "fpm_scoreboard.h" #include "zlog.h" #include "fpm_atomic.h" +#include static char *fpm_status_uri = NULL; static char *fpm_status_ping_uri = NULL; @@ -46,9 +47,12 @@ int fpm_status_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ { struct fpm_scoreboard_s scoreboard, *scoreboard_p; -// struct fpm_scoreboard_proc_s proc; - char *buffer, *syntax, *time_format, time_buffer[64]; + struct fpm_scoreboard_proc_s proc; + char *buffer, *time_format, time_buffer[64]; time_t now_epoch; + int full, encode; + char *short_syntax, *short_post; + char *full_pre, *full_syntax, *full_post, *full_separator; if (!SG(request_info).request_uri) { return 0; @@ -56,7 +60,10 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ /* PING */ if (fpm_status_ping_uri && fpm_status_ping_response && !strcmp(fpm_status_ping_uri, SG(request_info).request_uri)) { + fpm_request_executing(); sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); SG(sapi_headers).http_response_code = 200; PUTS(fpm_status_ping_response); return 1; @@ -64,12 +71,15 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ /* STATUS */ if (fpm_status_uri && !strcmp(fpm_status_uri, SG(request_info).request_uri)) { + fpm_request_executing(); scoreboard_p = fpm_scoreboard_get(); if (!scoreboard_p) { zlog(ZLOG_ERROR, "status: unable to find or access status shared memory"); SG(sapi_headers).http_response_code = 500; sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); PUTS("Internal error. Please review log file for errors."); return 1; } @@ -78,6 +88,8 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ zlog(ZLOG_NOTICE, "[pool %s] status: scoreboard already in used.", scoreboard_p->pool); SG(sapi_headers).http_response_code = 503; sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); PUTS("Server busy. Please try again later."); return 1; } @@ -89,38 +101,99 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ zlog(ZLOG_ERROR, "[pool %s] invalid status values", scoreboard.pool); SG(sapi_headers).http_response_code = 500; sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); PUTS("Internal error. Please review log file for errors."); return 1; } + /* full status ? */ + full = SG(request_info).request_uri && strstr(SG(request_info).query_string, "full"); + short_syntax = short_post = NULL; + full_separator = full_pre = full_syntax = full_post = NULL; + encode = 0; + /* HTML */ if (SG(request_info).query_string && strstr(SG(request_info).query_string, "html")) { sapi_add_header_ex(ZEND_STRL("Content-Type: text/html"), 1, 1 TSRMLS_CC); time_format = "%d/%b/%Y:%H:%M:%S %z"; - syntax = + encode = 1; + + short_syntax = + "\n" + "\n" + "PHP-FPM Status Page\n" + "\n" "\n" - "\n" - "\n" - "\n" - "\n" - "\n" + "\n" + "\n" + "\n" + "\n" + "\n" +#if HAVE_FPM_LQ + "\n" + "\n" + "\n" +#endif + "\n" + "\n" + "\n" + "\n" + "\n" + "
pool%s
process manager%s
start time%s
start since%lu
accepted conn%lu
pool%s
process manager%s
start time%s
start since%lu
accepted conn%lu
listen queue%u
max listen queue%u
listen queue len%d
idle processes%d
active processes%d
total processes%d
max active processes%d
max children reached%u
\n"; + + if (!full) { + short_post = ""; + } else { + full_pre = + "\n" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "" + "" #if HAVE_FPM_LQ - "\n" - "\n" - "\n" + "" #endif - "\n" - "\n" - "\n" - "\n" - "\n" - "
pidstatestart timestart sincerequestsrequest durationrequest methodrequest uricontent lengthuserscript
listen queue%u
max listen queue%u
listen queue len%d
last request cpu
idle processes%d
active processes%d
total processes%d
max active processes%d
max children reached%u
"; + "last request memory" + "\n"; + + full_syntax = + "" + "%d" + "%s" + "%s" + "%lu" + "%lu" + "%lu" + "%s" + "%s%s%s" + "%zu" + "%s" + "%s" +#if HAVE_FPM_LQ + "%.2f" +#endif + "%zu" + "\n"; + + full_post = ""; + } /* XML */ } else if (SG(request_info).request_uri && strstr(SG(request_info).query_string, "xml")) { sapi_add_header_ex(ZEND_STRL("Content-Type: text/xml"), 1, 1 TSRMLS_CC); time_format = "%s"; - syntax = + encode = 1; + + short_syntax = "\n" "\n" "%s\n" @@ -137,14 +210,40 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "%d\n" "%d\n" "%d\n" - "%u\n" - ""; + "%u\n"; + + if (!full) { + short_post = ""; + } else { + full_pre = "\n"; + full_syntax = + "" + "%d" + "%s" + "%s" + "%lu" + "%lu" + "%lu" + "%s" + "%s%s%s" + "%zu" + "%s" + "" +#if HAVE_FPM_LQ + "%.2f" +#endif + "%zu" + "\n" + ; + full_post = "\n"; + } /* JSON */ } else if (SG(request_info).request_uri && strstr(SG(request_info).query_string, "json")) { sapi_add_header_ex(ZEND_STRL("Content-Type: application/json"), 1, 1 TSRMLS_CC); time_format = "%s"; - syntax = + + short_syntax = "{" "\"pool\":\"%s\"," "\"process manager\":\"%s\"," @@ -160,14 +259,41 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "\"active processes\":%d," "\"total processes\":%d," "\"max active processes\":%d," - "\"max children reached\":%u" - "}"; + "\"max children reached\":%u"; + + if (!full) { + short_post = "}"; + } else { + full_separator = ","; + full_pre = ", \"processes\":["; + + full_syntax = "{" + "\"pid\":%d," + "\"state\":\"%s\"," + "\"start time\":%s," + "\"start since\":%lu," + "\"requests\":%lu," + "\"request duration\":%lu," + "\"request method\":\"%s\"," + "\"request uri\":\"%s%s%s\"," + "\"content length\":%zu," + "\"user\":\"%s\"," + "\"script\":\"%s\"," +#if HAVE_FPM_LQ + "\"last request cpu\":%.2f," +#endif + "\"last request memory\":%zu" + "}"; + + full_post = "]}"; + } /* TEXT */ } else { sapi_add_header_ex(ZEND_STRL("Content-Type: text/plain"), 1, 1 TSRMLS_CC); time_format = "%d/%b/%Y:%H:%M:%S %z"; - syntax = + + short_syntax = "pool: %s\n" "process manager: %s\n" "start time: %s\n" @@ -183,11 +309,35 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "total processes: %d\n" "max active processes: %d\n" "max children reached: %u\n"; + + if (full) { + full_syntax = + "\n" + "************************\n" + "pid: %d\n" + "state: %s\n" + "start time: %s\n" + "start since: %lu\n" + "requests: %lu\n" + "request duration: %lu\n" + "request method: %s\n" + "request URI: %s%s%s\n" + "content length: %zu\n" + "user: %s\n" + "script: %s\n" +#ifdef HAVE_FPM_LQ + "last request cpu: %.2f\n" +#endif + "last request memory: %zu\n"; + } } + sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); + strftime(time_buffer, sizeof(time_buffer) - 1, time_format, localtime(&scoreboard.start_epoch)); now_epoch = time(NULL); - spprintf(&buffer, 0, syntax, + spprintf(&buffer, 0, short_syntax, scoreboard.pool, scoreboard.pm == PM_STYLE_STATIC ? "static" : "dynamic", time_buffer, @@ -208,6 +358,96 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ PUTS(buffer); efree(buffer); + if (short_post) { + PUTS(short_post); + } + + /* no need to test the var 'full' */ + if (full_syntax) { + int i, len, first; + char *query_string; + struct timeval duration, now; +#ifdef HAVE_FPM_LQ + float cpu; +#endif + + fpm_clock_get(&now); + + if (full_pre) { + PUTS(full_pre); + } + + first = 1; + for (i=0; inprocs; i++) { + if (!scoreboard_p->procs[i] || !scoreboard_p->procs[i]->used) { + continue; + } + proc = *scoreboard_p->procs[i]; + + if (first) { + first = 0; + } else { + if (full_separator) { + PUTS(full_separator); + } + } + + query_string = NULL; + len = 0; + if (proc.query_string[0] != '\0') { + if (!encode) { + query_string = proc.query_string; + } else { + query_string = php_escape_html_entities_ex((unsigned char *)proc.query_string, strlen(proc.query_string), &len, 1, ENT_HTML_IGNORE_ERRORS & ENT_COMPAT, NULL, 1 TSRMLS_CC); + } + } + +#ifdef HAVE_FPM_LQ + /* prevent NaN */ + if (proc.cpu_duration.tv_sec == 0 && proc.cpu_duration.tv_usec == 0) { + cpu = 0.; + } else { + cpu = (proc.last_request_cpu.tms_utime + proc.last_request_cpu.tms_stime + proc.last_request_cpu.tms_cutime + proc.last_request_cpu.tms_cstime) / fpm_scoreboard_get_tick() / (proc.cpu_duration.tv_sec + proc.cpu_duration.tv_usec / 1000000.) * 100.; + } +#endif + + if (proc.request_stage == FPM_REQUEST_ACCEPTING) { + duration = proc.duration; + } else { + timersub(&now, &proc.accepted, &duration); + } + strftime(time_buffer, sizeof(time_buffer) - 1, time_format, localtime(&proc.start_epoch)); + spprintf(&buffer, 0, full_syntax, + proc.pid, + fpm_request_get_stage_name(proc.request_stage), + time_buffer, + now_epoch - proc.start_epoch, + proc.requests, + duration.tv_sec * 1000000UL + duration.tv_usec, + proc.request_method[0] != '\0' ? proc.request_method : "-", + proc.request_uri[0] != '\0' ? proc.request_uri : "-", + query_string ? "?" : "", + query_string ? query_string : "", + proc.content_length, + proc.auth_user[0] != '\0' ? proc.auth_user : "-", + proc.script_filename[0] != '\0' ? proc.script_filename : "-", +#ifdef HAVE_FPM_LQ + proc.request_stage == FPM_REQUEST_ACCEPTING ? cpu : 0., +#endif + proc.request_stage == FPM_REQUEST_ACCEPTING ? proc.memory : 0); + PUTS(buffer); + efree(buffer); + + if (len > 0 && query_string) { + efree(query_string); + } + } + + if (full_post) { + PUTS(full_post); + } + } + return 1; } diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index c3b0627cd103d..46a2098dfa5d5 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -182,34 +182,98 @@ pm.max_children = 50 ;pm.max_requests = 500 ; The URI to view the FPM status page. If this value is not set, no URI will be -; recognized as a status page. By default, the status page shows the following -; information: -; accepted conn - the number of request accepted by the pool; +; recognized as a status page. It shows the following informations: ; pool - the name of the pool; ; process manager - static or dynamic; +; start time - the date and time FPM has started; +; start since - number of seconds since FPM has started; +; accepted conn - the number of request accepted by the pool; +; listen queue - the number of request in the queue of pending +; connections (see backlog in listen(2)); +; max listen queue - the maximum number of requests in the queue +; of pending connections since FPM has started; +; listen queue len - the size of the socket queue of pending connections; ; idle processes - the number of idle processes; ; active processes - the number of active processes; -; total processes - the number of idle + active processes. +; total processes - the number of idle + active processes; +; max active processes - the maximum number of active processes since FPM +; has started; ; max children reached - number of times, the process limit has been reached, ; when pm tries to start more children (works only for -; pm 'dynamic') -; The values of 'idle processes', 'active processes' and 'total processes' are -; updated each second. The value of 'accepted conn' is updated in real time. +; pm 'dynamic'); +; Value are updated in real time. ; Example output: -; accepted conn: 12073 ; pool: www ; process manager: static -; idle processes: 35 -; active processes: 65 -; total processes: 100 -; max children reached: 1 +; start time: 01/Jul/2011:17:53:49 +0200 +; start since: 62636 +; accepted conn: 190460 +; listen queue: 0 +; max listen queue: 1 +; listen queue len: 42 +; idle processes: 4 +; active processes: 11 +; total processes: 15 +; max active processes: 12 +; max children reached: 0 +; ; By default the status page output is formatted as text/plain. Passing either -; 'html', 'xml' or 'json' as a query string will return the corresponding output -; syntax. Example: +; 'html', 'xml' or 'json' in the query string will return the corresponding +; output syntax. Example: ; http://www.foo.bar/status ; http://www.foo.bar/status?json ; http://www.foo.bar/status?html ; http://www.foo.bar/status?xml +; +; By default the status page only outputs short status. Passing 'full' in the +; query string will also return status for each pool process. +; Example: +; http://www.foo.bar/status?full +; http://www.foo.bar/status?json&full +; http://www.foo.bar/status?html&full +; http://www.foo.bar/status?xml&full +; The Full status returns for each process: +; pid - the PID of the process; +; state - the state of the process (Idle, Running, ...); +; start time - the date and time the process has started; +; start since - the number of seconds since the process has started; +; requests - the number of requests the process has served; +; request duration - the duration in µs of the requests; +; request method - the request method (GET, POST, ...); +; request URI - the request URI with the query string; +; content length - the content length of the request (only with POST); +; user - the user (PHP_AUTH_USER) (or '-' if not set); +; script - the main script called (or '-' if not set); +; last request cpu - the %cpu the last request consumed +; it's always 0 if the process is not in Idle state +; because CPU calculation is done when the request +; processing has terminated; +; last request memory - the max amount of memory the last request consumed +; it's always 0 if the process is not in Idle state +; because memory calculation is done when the request +; processing has terminated; +; If the process is in Idle state, then informations are related to the +; last request the process has served. Otherwise informations are related to +; the current request being served. +; Example output: +; ************************ +; pid: 31330 +; state: Running +; start time: 01/Jul/2011:17:53:49 +0200 +; start since: 63087 +; requests: 12808 +; request duration: 1250261 +; request method: GET +; request URI: /test_mem.php?N=10000 +; content length: 0 +; user: - +; script: /home/fat/web/docs/php/test_mem.php +; last request cpu: 0.00 +; last request memory: 0 +; +; Note: There is a real-time FPM status monitoring sample web page available +; It's available in: @EXPANDED_DATADIR@/fpm/status.html +; ; Note: The value must start with a leading slash (/). The value can be ; anything, but it may not be a good idea to use the .php extension or it ; may conflict with a real PHP file. diff --git a/sapi/fpm/status.html b/sapi/fpm/status.html new file mode 100644 index 0000000000000..86492d73df071 --- /dev/null +++ b/sapi/fpm/status.html @@ -0,0 +1,459 @@ + + + + + + + PHP-FPM status page + + +
+ + + + +
+ PHP Logo

PHP-FPM real-time status page

+
+
+ + + + + + + + +
Status URL
Ajax status
Refresh Rate
Actions + + +
+

Pool Status

+ + +
 
+

Active Processes status

+ + +
PID↓Start TimeStart SinceRequests ServedRequest DurationRequest methodRequest URIContent LengthUserScript
+

Idle Processes status

+ + +
PID↓Start TimeStart SinceRequests ServedRequest DurationRequest methodRequest URIContent LengthUserScriptLast Request %CPULast Request Memory
+
+

+ + Valid XHTML 1.0 Transitional + +

+ + + From 710ff963f41eec6e3b49e77032c1ab2587e596dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 2 Jul 2011 16:34:39 +0000 Subject: [PATCH 0256/2394] - Implemented FR #54499 (FPM ping and status_path should handle HEAD request) --- sapi/fpm/fpm/fpm_status.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index ac9365de8a0a3..cf912c06a98ec 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -65,6 +65,12 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); SG(sapi_headers).http_response_code = 200; + + /* handle HEAD */ + if (SG(request_info).headers_only) { + return 1; + } + PUTS(fpm_status_ping_response); return 1; } @@ -107,6 +113,16 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ return 1; } + /* send common headers */ + sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); + sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); + SG(sapi_headers).http_response_code = 200; + + /* handle HEAD */ + if (SG(request_info).headers_only) { + return 1; + } + /* full status ? */ full = SG(request_info).request_uri && strstr(SG(request_info).query_string, "full"); short_syntax = short_post = NULL; @@ -332,9 +348,6 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ } } - sapi_add_header_ex(ZEND_STRL("Expires: Thu, 01 Jan 1970 00:00:00 GMT"), 1, 1 TSRMLS_CC); - sapi_add_header_ex(ZEND_STRL("Cache-Control: no-cache, no-store, must-revalidate, max-age=0"), 1, 1 TSRMLS_CC); - strftime(time_buffer, sizeof(time_buffer) - 1, time_format, localtime(&scoreboard.start_epoch)); now_epoch = time(NULL); spprintf(&buffer, 0, short_syntax, @@ -354,7 +367,6 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ scoreboard.active_max, scoreboard.max_children_reached); - SG(sapi_headers).http_response_code = 200; PUTS(buffer); efree(buffer); From b06e62d4fe2171c618fe440afa4b9e2a81861592 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 2 Jul 2011 16:40:59 +0000 Subject: [PATCH 0257/2394] - Fix php_escape_html_entities_ex call (int * has been changed to size_t *) --- sapi/fpm/fpm/fpm_status.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index cf912c06a98ec..977ce3252aa5f 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -376,7 +376,8 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ /* no need to test the var 'full' */ if (full_syntax) { - int i, len, first; + int i, first; + size_t len; char *query_string; struct timeval duration, now; #ifdef HAVE_FPM_LQ From 0124c28610ace0814720821060142b3309cd5f87 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 2 Jul 2011 17:12:20 +0000 Subject: [PATCH 0258/2394] - Fixed bug #55086 (Namespace alias does not work inside trait's use block) patch by: Pierrick --- Zend/tests/bug55086.phpt | 36 ++++++++++++++++++++++++++++++++++++ Zend/zend_compile.c | 2 ++ Zend/zend_language_parser.y | 4 ++-- 3 files changed, 40 insertions(+), 2 deletions(-) create mode 100644 Zend/tests/bug55086.phpt diff --git a/Zend/tests/bug55086.phpt b/Zend/tests/bug55086.phpt new file mode 100644 index 0000000000000..9a5c747b9f007 --- /dev/null +++ b/Zend/tests/bug55086.phpt @@ -0,0 +1,36 @@ +--TEST-- +Bug #55086 (Namespace alias does not work inside trait's use block) +--FILE-- +hello(), PHP_EOL; + echo $a->foo(), PHP_EOL; + try { + } catch(namespace \Foo $e) + { + } +} +?> +--EXPECT-- +hello from t1 +hello from t1 diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 7842ec8f2ef00..5f9cef311bf72 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -4052,6 +4052,8 @@ void zend_prepare_reference(znode *result, znode *class_name, znode *method_name /* REM: There should not be a need for copying, zend_do_begin_class_declaration is also just using that string */ if (class_name) { + ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; + zend_resolve_class_name(class_name, &fetch_type, 1 TSRMLS_CC); method_ref->class_name = Z_STRVAL(class_name->u.constant); method_ref->cname_len = Z_STRLEN(class_name->u.constant); } else { diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 3d774bff25008..4dd5bdb977ea5 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -612,8 +612,8 @@ trait_precedence: ; trait_reference_list: - fully_qualified_class_name { zend_init_list(&$$.u.op.ptr, Z_STRVAL($1.u.constant) TSRMLS_CC); } - | trait_reference_list ',' fully_qualified_class_name { zend_add_to_list(&$1.u.op.ptr, Z_STRVAL($3.u.constant) TSRMLS_CC); $$ = $1; } + fully_qualified_class_name { ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; zend_resolve_class_name(&$1, &fetch_type, 1 TSRMLS_CC); zend_init_list(&$$.u.op.ptr, Z_STRVAL($1.u.constant) TSRMLS_CC); } + | trait_reference_list ',' fully_qualified_class_name { ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; zend_resolve_class_name(&$3, &fetch_type, 1 TSRMLS_CC); zend_add_to_list(&$1.u.op.ptr, Z_STRVAL($3.u.constant) TSRMLS_CC); $$ = $1; } ; trait_method_reference: From 9b64314250c9574a9fb846dcb43b5da4d8a00223 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sat, 2 Jul 2011 23:41:01 +0000 Subject: [PATCH 0259/2394] - Implemented FR #54172 (Overriding the pid file location of php-fpm) --- sapi/fpm/fpm/fpm.c | 4 +++- sapi/fpm/fpm/fpm.h | 3 ++- sapi/fpm/fpm/fpm_conf.c | 4 ++++ sapi/fpm/fpm/fpm_main.c | 12 ++++++++++-- 4 files changed, 19 insertions(+), 4 deletions(-) diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index 13106dfe4d8e1..ca0be3d19e8e3 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -29,6 +29,7 @@ struct fpm_globals_s fpm_globals = { .argv = NULL, .config = NULL, .prefix = NULL, + .pid = NULL, .running_children = 0, .error_log_fd = 0, .log_level = 0, @@ -38,7 +39,7 @@ struct fpm_globals_s fpm_globals = { .test_successful = 0 }; -int fpm_init(int argc, char **argv, char *config, char *prefix, int test_conf) /* {{{ */ +int fpm_init(int argc, char **argv, char *config, char *prefix, char *pid, int test_conf) /* {{{ */ { fpm_globals.argc = argc; fpm_globals.argv = argv; @@ -46,6 +47,7 @@ int fpm_init(int argc, char **argv, char *config, char *prefix, int test_conf) / fpm_globals.config = strdup(config); } fpm_globals.prefix = prefix; + fpm_globals.pid = pid; if (0 > fpm_php_init_main() || 0 > fpm_stdio_init_main() || diff --git a/sapi/fpm/fpm/fpm.h b/sapi/fpm/fpm/fpm.h index f06d9ed6a91ce..3c6f798fba6ff 100644 --- a/sapi/fpm/fpm/fpm.h +++ b/sapi/fpm/fpm/fpm.h @@ -8,7 +8,7 @@ #include int fpm_run(int *max_requests); -int fpm_init(int argc, char **argv, char *config, char *prefix, int test_conf); +int fpm_init(int argc, char **argv, char *config, char *prefix, char *pid, int test_conf); struct fpm_globals_s { pid_t parent_pid; @@ -16,6 +16,7 @@ struct fpm_globals_s { char **argv; char *config; char *prefix; + char *pid; int running_children; int error_log_fd; int log_level; diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 07d982393fc5d..0a1494d40428c 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -1206,6 +1206,10 @@ int fpm_conf_init_main(int test_conf) /* {{{ */ } } + if (fpm_globals.pid && *fpm_globals.pid) { + fpm_global_config.pid_file = strdup(fpm_globals.pid); + } + if (fpm_globals.config == NULL) { char *tmp; diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 8946135ad1110..6df89d6045794 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -155,6 +155,7 @@ static const opt_struct OPTIONS[] = { {'y', 1, "fpm-config"}, {'t', 0, "test"}, {'p', 1, "prefix"}, + {'g', 1, "pid"}, {'-', 0, NULL} /* end of args */ }; @@ -959,7 +960,7 @@ static void php_cgi_usage(char *argv0) prog = "php"; } - php_printf( "Usage: %s [-n] [-e] [-h] [-i] [-m] [-v] [-t] [-p ] [-c ] [-d foo[=bar]] [-y ]\n" + php_printf( "Usage: %s [-n] [-e] [-h] [-i] [-m] [-v] [-t] [-p ] [-g ] [-c ] [-d foo[=bar]] [-y ]\n" " -c | Look for php.ini file in this directory\n" " -n No php.ini file will be used\n" " -d foo[=bar] Define INI entry foo with value 'bar'\n" @@ -970,6 +971,8 @@ static void php_cgi_usage(char *argv0) " -v Version number\n" " -p, --prefix \n" " Specify alternative prefix path to FastCGI process manager (default: %s).\n" + " -g, --pid \n" + " Specify the PID file location.\n" " -y, --fpm-config \n" " Specify alternative path to FastCGI process manager config file.\n" " -t, --test Test FPM configuration and exit\n", @@ -1585,6 +1588,7 @@ int main(int argc, char *argv[]) fcgi_request request; char *fpm_config = NULL; char *fpm_prefix = NULL; + char *fpm_pid = NULL; int test_conf = 0; #ifdef HAVE_SIGNAL_H @@ -1669,6 +1673,10 @@ int main(int argc, char *argv[]) fpm_prefix = php_optarg; break; + case 'g': + fpm_pid = php_optarg; + break; + case 'e': /* enable extended info output */ CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; break; @@ -1814,7 +1822,7 @@ consult the installation file that came with this distribution, or visit \n\ } } - if (0 > fpm_init(argc, argv, fpm_config ? fpm_config : CGIG(fpm_config), fpm_prefix, test_conf)) { + if (0 > fpm_init(argc, argv, fpm_config ? fpm_config : CGIG(fpm_config), fpm_prefix, fpm_pid, test_conf)) { return FAILURE; } From 96d927c6ac552c8b32511e680acebd81256380e2 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 3 Jul 2011 01:06:20 +0000 Subject: [PATCH 0260/2394] - Fixed crash when using -e option --- sapi/fpm/fpm/fpm_main.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 6df89d6045794..ced0875913756 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1569,7 +1569,7 @@ static zend_module_entry cgi_module_entry = { int main(int argc, char *argv[]) { int exit_status = SUCCESS; - int cgi = 0, c; + int cgi = 0, c, use_extended_info = 0; zend_file_handle file_handle; /* temporary locals */ @@ -1678,7 +1678,7 @@ int main(int argc, char *argv[]) break; case 'e': /* enable extended info output */ - CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; + use_extended_info = 1; break; case 't': @@ -1781,6 +1781,10 @@ int main(int argc, char *argv[]) #endif return FAILURE; } + + if (use_extended_info) { + CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO; + } /* check force_cgi after startup, so we have proper output */ if (cgi && CGIG(force_redirect)) { From 5f33819f9c8ec391e1e1d6bb32bcc48928521070 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 3 Jul 2011 01:29:23 +0000 Subject: [PATCH 0261/2394] - Removed accidental offsetof definition --- Zend/zend_operators.h | 5 ----- 1 file changed, 5 deletions(-) diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 7f831f93ffbef..8e3a37eee75ff 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -451,11 +451,6 @@ ZEND_API void zend_update_current_locale(void); #define zend_update_current_locale() #endif -#ifndef offsetof -#define offsetof(t,f) \ - ((int)(&((t*)0)->f)) -#endif - static zend_always_inline int fast_increment_function(zval *op1) { if (EXPECTED(Z_TYPE_P(op1) == IS_LONG)) { From df10314070db8a065a078c300d1ddfa30d70d93c Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 3 Jul 2011 14:45:41 +0000 Subject: [PATCH 0262/2394] - Fixed bug #55118 (Imcomplete start message) --- sapi/cli/php_cli_server.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index ab2dc6c32b691..365f352244202 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2069,7 +2069,15 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ return 1; } } else { - document_root = "."; + char path[MAXPATHLEN]; + char *ret = NULL; + +#if HAVE_GETCWD + ret = VCWD_GETCWD(path, MAXPATHLEN); +#elif HAVE_GETWD + ret = VCWD_GETWD(path); +#endif + document_root = ret ? path : "."; } if (argc > php_optind) { From bc427b0eba75d8c4c14f92bbda282f3e9c4f0a36 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 4 Jul 2011 12:49:46 +0000 Subject: [PATCH 0263/2394] fix comment syntax --- sapi/fpm/php-fpm.conf.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index 46a2098dfa5d5..2997ac67f92d6 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -322,7 +322,7 @@ pm.max_children = 50 ; - server specifics like: %{REQUEST_METHOD}e or %{SERVER_PROTOCOL}e ; - HTTP headers like: %{HTTP_HOST}e or %{HTTP_USER_AGENT}e ; %f: script filename -: %l: content-length of the request (for POST request only) +; %l: content-length of the request (for POST request only) ; %m: request method ; %M: peak of memory allocated by PHP ; it can accept the following format: From 34b8924f958e06bcfdd3a8c0719e1a2a4edbd506 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 4 Jul 2011 14:55:39 +0000 Subject: [PATCH 0264/2394] Fixed bug #53727 (Inconsistent behavior of is_subclass_of with interfaces) --- Zend/tests/bug53727.phpt | 22 +++++++++++++ Zend/tests/is_a.phpt | 2 +- Zend/zend_builtin_functions.c | 31 ++++--------------- .../class_object/is_a_variation_001.phpt | 8 +++++ 4 files changed, 37 insertions(+), 26 deletions(-) create mode 100644 Zend/tests/bug53727.phpt diff --git a/Zend/tests/bug53727.phpt b/Zend/tests/bug53727.phpt new file mode 100644 index 0000000000000..22cd5232c7c15 --- /dev/null +++ b/Zend/tests/bug53727.phpt @@ -0,0 +1,22 @@ +--TEST-- +Bug #53727 (Inconsistent behavior of is_subclass_of with interfaces) +--FILE-- +parent; - } else { - instance_ce = instance_ce->parent; - } - } else { - instance_ce = Z_OBJCE_P(obj); - } - - if (!instance_ce) { - RETURN_FALSE; - } - - if (instanceof_function(instance_ce, *ce TSRMLS_CC)) { - retval = 1; - } else { + if (only_subclass && instance_ce == *ce) { retval = 0; + } else { + retval = instanceof_function(instance_ce, *ce TSRMLS_CC); } } diff --git a/ext/standard/tests/class_object/is_a_variation_001.phpt b/ext/standard/tests/class_object/is_a_variation_001.phpt index d2d6ce24071f7..1021544065bf8 100644 --- a/ext/standard/tests/class_object/is_a_variation_001.phpt +++ b/ext/standard/tests/class_object/is_a_variation_001.phpt @@ -144,15 +144,23 @@ Arg value bool(false) Arg value + +Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value + +Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value string + +Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value String + +Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value From e3668bdf1c6f32a6df178723f8da7aba17eb2097 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 4 Jul 2011 23:38:09 +0000 Subject: [PATCH 0265/2394] fix crypt() issue with overlong salt --- .../tests/strings/crypt_variation1.phpt | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 ext/standard/tests/strings/crypt_variation1.phpt diff --git a/ext/standard/tests/strings/crypt_variation1.phpt b/ext/standard/tests/strings/crypt_variation1.phpt new file mode 100644 index 0000000000000..6e0d3fe121504 --- /dev/null +++ b/ext/standard/tests/strings/crypt_variation1.phpt @@ -0,0 +1,23 @@ +--TEST-- +crypt() function - long salt +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +$5$AAAAAAAAAAAAAAAA$frotiiztWZiwcncxnY5tWG9Ida2WOZEximjLXCleQu6 +$5$AAAAAAAAAAAAAAAA$frotiiztWZiwcncxnY5tWG9Ida2WOZEximjLXCleQu6 +$5$AAAAAAAAAAAAAAAA$frotiiztWZiwcncxnY5tWG9Ida2WOZEximjLXCleQu6 From d12fab2d4b2b545cd81f13afeeabfc732194db22 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 5 Jul 2011 01:24:10 +0000 Subject: [PATCH 0266/2394] - moved STR2STR, BOOL2STR and PM2STR from fpm_conf.h to fpm_conf.c (Giovanni Giacobbi) --- sapi/fpm/fpm/fpm_conf.c | 9 ++++++--- sapi/fpm/fpm/fpm_conf.h | 4 ---- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 0a1494d40428c..cc7baea31e7e4 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -44,6 +44,12 @@ #include "fpm_log.h" #include "zlog.h" +#define STR2STR(a) (a ? a : "undefined") +#define BOOL2STR(a) (a ? "yes" : "no") +#define PM2STR(a) (a == PM_STYLE_STATIC ? "static" : "dynamic") +#define GO(field) offsetof(struct fpm_global_config_s, field) +#define WPO(field) offsetof(struct fpm_worker_pool_config_s, field) + static int fpm_conf_load_ini_file(char *filename TSRMLS_DC); static char *fpm_conf_set_integer(zval *value, void **config, intptr_t offset); static char *fpm_conf_set_time(zval *value, void **config, intptr_t offset); @@ -60,9 +66,6 @@ static char *ini_filename = NULL; static int ini_lineno = 0; static char *ini_include = NULL; -#define GO(field) offsetof(struct fpm_global_config_s, field) -#define WPO(field) offsetof(struct fpm_worker_pool_config_s, field) - static struct ini_value_parser_s ini_fpm_global_options[] = { { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index d1087641d38e9..e8615ebae0ebb 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -10,10 +10,6 @@ #define FPM_CONF_MAX_PONG_LENGTH 64 -#define STR2STR(a) (a ? a : "undefined") -#define BOOL2STR(a) (a ? "yes" : "no") -#define PM2STR(a) (a == PM_STYLE_STATIC ? "static" : "dynamic") - struct key_value_s; struct key_value_s { From e57914c1d803d94d259a45182f7b1eef92b4ee65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 5 Jul 2011 01:43:50 +0000 Subject: [PATCH 0267/2394] Fixed memory leak --- sapi/fpm/fpm/fpm_conf.c | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index cc7baea31e7e4..9e52c794496a9 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -123,6 +123,9 @@ static int fpm_conf_is_dir(char *path) /* {{{ */ } /* }}} */ +/* + * Expands the '$pool' token in a dynamically allocated string + */ static int fpm_conf_expand_pool_name(char **value) { char *token; @@ -130,15 +133,23 @@ static int fpm_conf_expand_pool_name(char **value) { return 0; } - while ((token = strstr(*value, "$pool"))) { + while (*value && (token = strstr(*value, "$pool"))) { char *buf; - char *p1 = *value; char *p2 = token + strlen("$pool"); + + /* If we are not in a pool, we cannot expand this name now */ if (!current_wp || !current_wp->config || !current_wp->config->name) { return -1; } + + /* "aaa$poolbbb" becomes "aaa\0oolbbb" */ token[0] = '\0'; - spprintf(&buf, 0, "%s%s%s", p1, current_wp->config->name, p2); + + /* Build a brand new string with the expanded token */ + spprintf(&buf, 0, "%s%s%s", *value, current_wp->config->name, p2); + + /* Free the previous value and save the new one */ + free(*value); *value = strdup(buf); efree(buf); } From a3b31f5c1854732d4837be01488ce878d0627ce0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 5 Jul 2011 02:42:40 +0000 Subject: [PATCH 0268/2394] - ws and cosmetics --- sapi/fpm/fpm/fastcgi.c | 2 +- sapi/fpm/fpm/fpm.c | 54 ++++++------ sapi/fpm/fpm/fpm_conf.c | 160 +++++++++++++++++----------------- sapi/fpm/fpm/fpm_conf.h | 5 +- sapi/fpm/fpm/fpm_env.c | 2 +- sapi/fpm/fpm/fpm_main.c | 49 ++++++----- sapi/fpm/fpm/fpm_scoreboard.c | 6 +- sapi/fpm/fpm/fpm_signals.c | 20 ++--- 8 files changed, 151 insertions(+), 147 deletions(-) diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index 00a658721425c..ffa310daf6739 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -194,7 +194,7 @@ int fcgi_init(void) socklen_t len = sizeof(sa); #endif zend_hash_init(&fcgi_mgmt_vars, 0, NULL, fcgi_free_mgmt_var_cb, 1); - fcgi_set_mgmt_var("FCGI_MPXS_CONNS", sizeof("FCGI_MPXS_CONNS")-1, "0", sizeof("0")-1); + fcgi_set_mgmt_var("FCGI_MPXS_CONNS", sizeof("FCGI_MPXS_CONNS") - 1, "0", sizeof("0")-1); is_initialized = 1; #ifdef _WIN32 diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index ca0be3d19e8e3..153bb29250f65 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -24,20 +24,20 @@ #include "zlog.h" struct fpm_globals_s fpm_globals = { - .parent_pid = 0, - .argc = 0, - .argv = NULL, - .config = NULL, - .prefix = NULL, - .pid = NULL, - .running_children = 0, - .error_log_fd = 0, - .log_level = 0, - .listening_socket = 0, - .max_requests = 0, - .is_child = 0, - .test_successful = 0 - }; + .parent_pid = 0, + .argc = 0, + .argv = NULL, + .config = NULL, + .prefix = NULL, + .pid = NULL, + .running_children = 0, + .error_log_fd = 0, + .log_level = 0, + .listening_socket = 0, + .max_requests = 0, + .is_child = 0, + .test_successful = 0 +}; int fpm_init(int argc, char **argv, char *config, char *prefix, char *pid, int test_conf) /* {{{ */ { @@ -49,19 +49,19 @@ int fpm_init(int argc, char **argv, char *config, char *prefix, char *pid, int t fpm_globals.prefix = prefix; fpm_globals.pid = pid; - if (0 > fpm_php_init_main() || - 0 > fpm_stdio_init_main() || - 0 > fpm_conf_init_main(test_conf) || - 0 > fpm_unix_init_main() || - 0 > fpm_scoreboard_init_main() || - 0 > fpm_pctl_init_main() || - 0 > fpm_env_init_main() || - 0 > fpm_signals_init_main() || - 0 > fpm_children_init_main() || - 0 > fpm_sockets_init_main() || - 0 > fpm_worker_pool_init_main() || - 0 > fpm_event_init_main()) { - + if (0 > fpm_php_init_main() || + 0 > fpm_stdio_init_main() || + 0 > fpm_conf_init_main(test_conf) || + 0 > fpm_unix_init_main() || + 0 > fpm_scoreboard_init_main() || + 0 > fpm_pctl_init_main() || + 0 > fpm_env_init_main() || + 0 > fpm_signals_init_main() || + 0 > fpm_children_init_main() || + 0 > fpm_sockets_init_main() || + 0 > fpm_worker_pool_init_main() || + 0 > fpm_event_init_main()) { + if (fpm_globals.test_successful) { exit(0); } else { diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 9e52c794496a9..7fe27eda5e4df 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -67,47 +67,47 @@ static int ini_lineno = 0; static char *ini_include = NULL; static struct ini_value_parser_s ini_fpm_global_options[] = { - { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, - { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, - { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, - { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, - { "pid", &fpm_conf_set_string, GO(pid_file) }, - { "error_log", &fpm_conf_set_string, GO(error_log) }, - { "log_level", &fpm_conf_set_log_level, 0 }, - { "rlimit_files", &fpm_conf_set_integer, GO(rlimit_files) }, - { "rlimit_core", &fpm_conf_set_rlimit_core,GO(rlimit_core) }, + { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, + { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, + { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, + { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, + { "pid", &fpm_conf_set_string, GO(pid_file) }, + { "error_log", &fpm_conf_set_string, GO(error_log) }, + { "log_level", &fpm_conf_set_log_level, 0 }, + { "rlimit_files", &fpm_conf_set_integer, GO(rlimit_files) }, + { "rlimit_core", &fpm_conf_set_rlimit_core, GO(rlimit_core) }, { 0, 0, 0 } }; static struct ini_value_parser_s ini_fpm_pool_options[] = { - { "prefix", &fpm_conf_set_string, WPO(prefix) }, - { "user", &fpm_conf_set_string, WPO(user) }, - { "group", &fpm_conf_set_string, WPO(group) }, - { "chroot", &fpm_conf_set_string, WPO(chroot) }, - { "chdir", &fpm_conf_set_string, WPO(chdir) }, - { "request_terminate_timeout", &fpm_conf_set_time, WPO(request_terminate_timeout) }, - { "request_slowlog_timeout", &fpm_conf_set_time, WPO(request_slowlog_timeout) }, - { "slowlog", &fpm_conf_set_string, WPO(slowlog) }, - { "rlimit_files", &fpm_conf_set_integer, WPO(rlimit_files) }, - { "rlimit_core", &fpm_conf_set_rlimit_core, WPO(rlimit_core) }, - { "catch_workers_output", &fpm_conf_set_boolean, WPO(catch_workers_output) }, - { "listen", &fpm_conf_set_string, WPO(listen_address) }, - { "listen.owner", &fpm_conf_set_string, WPO(listen_owner) }, - { "listen.group", &fpm_conf_set_string, WPO(listen_group) }, - { "listen.mode", &fpm_conf_set_string, WPO(listen_mode) }, - { "listen.backlog", &fpm_conf_set_integer, WPO(listen_backlog) }, - { "listen.allowed_clients", &fpm_conf_set_string, WPO(listen_allowed_clients) }, - { "pm", &fpm_conf_set_pm, WPO(pm) }, - { "pm.max_requests", &fpm_conf_set_integer, WPO(pm_max_requests) }, - { "pm.max_children", &fpm_conf_set_integer, WPO(pm_max_children) }, - { "pm.start_servers", &fpm_conf_set_integer, WPO(pm_start_servers) }, - { "pm.min_spare_servers", &fpm_conf_set_integer, WPO(pm_min_spare_servers) }, - { "pm.max_spare_servers", &fpm_conf_set_integer, WPO(pm_max_spare_servers) }, - { "pm.status_path", &fpm_conf_set_string, WPO(pm_status_path) }, - { "ping.path", &fpm_conf_set_string, WPO(ping_path) }, - { "ping.response", &fpm_conf_set_string, WPO(ping_response) }, - { "access.log", &fpm_conf_set_string, WPO(access_log) }, - { "access.format", &fpm_conf_set_string, WPO(access_format) }, + { "prefix", &fpm_conf_set_string, WPO(prefix) }, + { "user", &fpm_conf_set_string, WPO(user) }, + { "group", &fpm_conf_set_string, WPO(group) }, + { "chroot", &fpm_conf_set_string, WPO(chroot) }, + { "chdir", &fpm_conf_set_string, WPO(chdir) }, + { "request_terminate_timeout", &fpm_conf_set_time, WPO(request_terminate_timeout) }, + { "request_slowlog_timeout", &fpm_conf_set_time, WPO(request_slowlog_timeout) }, + { "slowlog", &fpm_conf_set_string, WPO(slowlog) }, + { "rlimit_files", &fpm_conf_set_integer, WPO(rlimit_files) }, + { "rlimit_core", &fpm_conf_set_rlimit_core, WPO(rlimit_core) }, + { "catch_workers_output", &fpm_conf_set_boolean, WPO(catch_workers_output) }, + { "listen", &fpm_conf_set_string, WPO(listen_address) }, + { "listen.owner", &fpm_conf_set_string, WPO(listen_owner) }, + { "listen.group", &fpm_conf_set_string, WPO(listen_group) }, + { "listen.mode", &fpm_conf_set_string, WPO(listen_mode) }, + { "listen.backlog", &fpm_conf_set_integer, WPO(listen_backlog) }, + { "listen.allowed_clients", &fpm_conf_set_string, WPO(listen_allowed_clients) }, + { "pm", &fpm_conf_set_pm, WPO(pm) }, + { "pm.max_requests", &fpm_conf_set_integer, WPO(pm_max_requests) }, + { "pm.max_children", &fpm_conf_set_integer, WPO(pm_max_children) }, + { "pm.start_servers", &fpm_conf_set_integer, WPO(pm_start_servers) }, + { "pm.min_spare_servers", &fpm_conf_set_integer, WPO(pm_min_spare_servers) }, + { "pm.max_spare_servers", &fpm_conf_set_integer, WPO(pm_max_spare_servers) }, + { "pm.status_path", &fpm_conf_set_string, WPO(pm_status_path) }, + { "ping.path", &fpm_conf_set_string, WPO(ping_path) }, + { "ping.response", &fpm_conf_set_string, WPO(ping_response) }, + { "access.log", &fpm_conf_set_string, WPO(access_log) }, + { "access.format", &fpm_conf_set_string, WPO(access_format) }, { 0, 0, 0 } }; @@ -198,7 +198,7 @@ static char *fpm_conf_set_integer(zval *value, void **config, intptr_t offset) / char *val = Z_STRVAL_P(value); char *p; - for(p=val; *p; p++) { + for (p = val; *p; p++) { if ( p == val && *p == '-' ) continue; if (*p < '0' || *p > '9') { return "is not a valid number (greater or equal than zero)"; @@ -627,7 +627,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ return -1; } - for (i=0; iconfig->name, ping); return -1; @@ -664,7 +664,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ return -1; } - for (i=0; iconfig->name, status); return -1; @@ -727,14 +727,14 @@ static int fpm_conf_process_all_pools() /* {{{ */ char **p; for (kv = wp->config->php_values; kv; kv = kv->next) { - for (p=options; *p; p++) { + for (p = options; *p; p++) { if (!strcasecmp(kv->key, *p)) { fpm_evaluate_full_path(&kv->value, wp, NULL, 0); } } } for (kv = wp->config->php_admin_values; kv; kv = kv->next) { - for (p=options; *p; p++) { + for (p = options; *p; p++) { if (!strcasecmp(kv->key, *p)) { fpm_evaluate_full_path(&kv->value, wp, NULL, 0); } @@ -864,7 +864,7 @@ static void fpm_conf_ini_parser_include(char *inc, void *arg TSRMLS_DC) /* {{{ * return; } - for(i=0; iconfig; } - for (;parser->name; parser++) { + for (; parser->name; parser++) { if (!strcasecmp(parser->name, Z_STRVAL_P(name))) { char *ret; if (!parser->parser) { @@ -1107,7 +1107,7 @@ int fpm_conf_load_ini_file(char *filename TSRMLS_DC) /* {{{ */ while (nb_read > 0) { int tmp; memset(buf, 0, sizeof(char) * (1024 + 1)); - for (n=0; n<1024 && (nb_read = read(fd, &c, sizeof(char))) == sizeof(char) && c != '\n'; n++) { + for (n = 0; n < 1024 && (nb_read = read(fd, &c, sizeof(char))) == sizeof(char) && c != '\n'; n++) { buf[n] = c; } buf[n++] = '\n'; @@ -1148,49 +1148,49 @@ static void fpm_conf_dump() /* {{{ */ struct fpm_worker_pool_s *wp; zlog(ZLOG_NOTICE, "[General]"); - zlog(ZLOG_NOTICE, "\tpid = %s", STR2STR(fpm_global_config.pid_file)); - zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize)); - zlog(ZLOG_NOTICE, "\terror_log = %s", STR2STR(fpm_global_config.error_log)); - zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name()); - zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); + zlog(ZLOG_NOTICE, "\tpid = %s", STR2STR(fpm_global_config.pid_file)); + zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize)); + zlog(ZLOG_NOTICE, "\terror_log = %s", STR2STR(fpm_global_config.error_log)); + zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name()); + zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval); zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold); - zlog(ZLOG_NOTICE, "\trlimit_files = %d", fpm_global_config.rlimit_files); - zlog(ZLOG_NOTICE, "\trlimit_core = %d", fpm_global_config.rlimit_core); + zlog(ZLOG_NOTICE, "\trlimit_files = %d", fpm_global_config.rlimit_files); + zlog(ZLOG_NOTICE, "\trlimit_core = %d", fpm_global_config.rlimit_core); zlog(ZLOG_NOTICE, " "); for (wp = fpm_worker_all_pools; wp; wp = wp->next) { struct key_value_s *kv; if (!wp->config) continue; - zlog(ZLOG_NOTICE, "[%s]", STR2STR(wp->config->name)); - zlog(ZLOG_NOTICE, "\tprefix = %s", STR2STR(wp->config->prefix)); - zlog(ZLOG_NOTICE, "\tuser = %s", STR2STR(wp->config->user)); - zlog(ZLOG_NOTICE, "\tgroup = %s", STR2STR(wp->config->group)); - zlog(ZLOG_NOTICE, "\tchroot = %s", STR2STR(wp->config->chroot)); - zlog(ZLOG_NOTICE, "\tchdir = %s", STR2STR(wp->config->chdir)); - zlog(ZLOG_NOTICE, "\tlisten = %s", STR2STR(wp->config->listen_address)); - zlog(ZLOG_NOTICE, "\tlisten.backlog = %d", wp->config->listen_backlog); - zlog(ZLOG_NOTICE, "\tlisten.owner = %s", STR2STR(wp->config->listen_owner)); - zlog(ZLOG_NOTICE, "\tlisten.group = %s", STR2STR(wp->config->listen_group)); - zlog(ZLOG_NOTICE, "\tlisten.mode = %s", STR2STR(wp->config->listen_mode)); - zlog(ZLOG_NOTICE, "\tlisten.allowed_clients = %s", STR2STR(wp->config->listen_allowed_clients)); - zlog(ZLOG_NOTICE, "\tpm = %s", PM2STR(wp->config->pm)); - zlog(ZLOG_NOTICE, "\tpm.max_children = %d", wp->config->pm_max_children); - zlog(ZLOG_NOTICE, "\tpm.max_requests = %d", wp->config->pm_max_requests); - zlog(ZLOG_NOTICE, "\tpm.start_servers = %d", wp->config->pm_start_servers); - zlog(ZLOG_NOTICE, "\tpm.min_spare_servers = %d", wp->config->pm_min_spare_servers); - zlog(ZLOG_NOTICE, "\tpm.max_spare_servers = %d", wp->config->pm_max_spare_servers); - zlog(ZLOG_NOTICE, "\tpm.status_path = %s", STR2STR(wp->config->pm_status_path)); - zlog(ZLOG_NOTICE, "\tping.path = %s", STR2STR(wp->config->ping_path)); - zlog(ZLOG_NOTICE, "\tping.response = %s", STR2STR(wp->config->ping_response)); - zlog(ZLOG_NOTICE, "\taccess.log = %s", STR2STR(wp->config->access_log)); - zlog(ZLOG_NOTICE, "\taccess.format = %s", STR2STR(wp->config->access_format)); - zlog(ZLOG_NOTICE, "\tcatch_workers_output = %s", BOOL2STR(wp->config->catch_workers_output)); + zlog(ZLOG_NOTICE, "[%s]", STR2STR(wp->config->name)); + zlog(ZLOG_NOTICE, "\tprefix = %s", STR2STR(wp->config->prefix)); + zlog(ZLOG_NOTICE, "\tuser = %s", STR2STR(wp->config->user)); + zlog(ZLOG_NOTICE, "\tgroup = %s", STR2STR(wp->config->group)); + zlog(ZLOG_NOTICE, "\tchroot = %s", STR2STR(wp->config->chroot)); + zlog(ZLOG_NOTICE, "\tchdir = %s", STR2STR(wp->config->chdir)); + zlog(ZLOG_NOTICE, "\tlisten = %s", STR2STR(wp->config->listen_address)); + zlog(ZLOG_NOTICE, "\tlisten.backlog = %d", wp->config->listen_backlog); + zlog(ZLOG_NOTICE, "\tlisten.owner = %s", STR2STR(wp->config->listen_owner)); + zlog(ZLOG_NOTICE, "\tlisten.group = %s", STR2STR(wp->config->listen_group)); + zlog(ZLOG_NOTICE, "\tlisten.mode = %s", STR2STR(wp->config->listen_mode)); + zlog(ZLOG_NOTICE, "\tlisten.allowed_clients = %s", STR2STR(wp->config->listen_allowed_clients)); + zlog(ZLOG_NOTICE, "\tpm = %s", PM2STR(wp->config->pm)); + zlog(ZLOG_NOTICE, "\tpm.max_children = %d", wp->config->pm_max_children); + zlog(ZLOG_NOTICE, "\tpm.max_requests = %d", wp->config->pm_max_requests); + zlog(ZLOG_NOTICE, "\tpm.start_servers = %d", wp->config->pm_start_servers); + zlog(ZLOG_NOTICE, "\tpm.min_spare_servers = %d", wp->config->pm_min_spare_servers); + zlog(ZLOG_NOTICE, "\tpm.max_spare_servers = %d", wp->config->pm_max_spare_servers); + zlog(ZLOG_NOTICE, "\tpm.status_path = %s", STR2STR(wp->config->pm_status_path)); + zlog(ZLOG_NOTICE, "\tping.path = %s", STR2STR(wp->config->ping_path)); + zlog(ZLOG_NOTICE, "\tping.response = %s", STR2STR(wp->config->ping_response)); + zlog(ZLOG_NOTICE, "\taccess.log = %s", STR2STR(wp->config->access_log)); + zlog(ZLOG_NOTICE, "\taccess.format = %s", STR2STR(wp->config->access_format)); + zlog(ZLOG_NOTICE, "\tcatch_workers_output = %s", BOOL2STR(wp->config->catch_workers_output)); zlog(ZLOG_NOTICE, "\trequest_terminate_timeout = %ds", wp->config->request_terminate_timeout); - zlog(ZLOG_NOTICE, "\trequest_slowlog_timeout = %ds", wp->config->request_slowlog_timeout); - zlog(ZLOG_NOTICE, "\tslowlog = %s", STR2STR(wp->config->slowlog)); - zlog(ZLOG_NOTICE, "\trlimit_files = %d", wp->config->rlimit_files); - zlog(ZLOG_NOTICE, "\trlimit_core = %d", wp->config->rlimit_core); + zlog(ZLOG_NOTICE, "\trequest_slowlog_timeout = %ds", wp->config->request_slowlog_timeout); + zlog(ZLOG_NOTICE, "\tslowlog = %s", STR2STR(wp->config->slowlog)); + zlog(ZLOG_NOTICE, "\trlimit_files = %d", wp->config->rlimit_files); + zlog(ZLOG_NOTICE, "\trlimit_core = %d", wp->config->rlimit_core); for (kv = wp->config->env; kv; kv = kv->next) { zlog(ZLOG_NOTICE, "\tenv[%s] = %s", kv->key, kv->value); diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index e8615ebae0ebb..2152527eea41a 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -72,7 +72,10 @@ struct ini_value_parser_s { intptr_t offset; }; -enum { PM_STYLE_STATIC = 1, PM_STYLE_DYNAMIC = 2 }; +enum { + PM_STYLE_STATIC = 1, + PM_STYLE_DYNAMIC = 2 +}; int fpm_conf_init_main(int test_conf); int fpm_worker_pool_config_free(struct fpm_worker_pool_config_s *wpc); diff --git a/sapi/fpm/fpm/fpm_env.c b/sapi/fpm/fpm/fpm_env.c index aa647d15bcdb3..03bf8234007ce 100644 --- a/sapi/fpm/fpm/fpm_env.c +++ b/sapi/fpm/fpm/fpm_env.c @@ -141,7 +141,7 @@ int fpm_env_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ struct key_value_s *kv; char *title; spprintf(&title, 0, "pool %s", wp->config->name); - fpm_env_setproctitle(title); + fpm_env_setproctitle(title); efree(title); clearenv(); diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index ced0875913756..7dbd6c00c9a51 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -422,8 +422,8 @@ static int sapi_cgi_send_headers(sapi_headers_struct *sapi_headers TSRMLS_DC) } else { h = (sapi_header_struct*)zend_llist_get_first_ex(&sapi_headers->headers, &pos); while (h) { - if (h->header_len > sizeof("Status:")-1 && - strncasecmp(h->header, "Status:", sizeof("Status:")-1) == 0 + if (h->header_len > sizeof("Status:") - 1 && + strncasecmp(h->header, "Status:", sizeof("Status:") - 1) == 0 ) { has_status = 1; break; @@ -458,16 +458,16 @@ static int sapi_cgi_send_headers(sapi_headers_struct *sapi_headers TSRMLS_DC) while (h) { /* prevent CRLFCRLF */ if (h->header_len) { - if (h->header_len > sizeof("Status:")-1 && - strncasecmp(h->header, "Status:", sizeof("Status:")-1) == 0 + if (h->header_len > sizeof("Status:") - 1 && + strncasecmp(h->header, "Status:", sizeof("Status:") - 1) == 0 ) { if (!ignore_status) { ignore_status = 1; PHPWRITE_H(h->header, h->header_len); PHPWRITE_H("\r\n", 2); } - } else if (response_status == 304 && h->header_len > sizeof("Content-Type:")-1 && - strncasecmp(h->header, "Content-Type:", sizeof("Content-Type:")-1) == 0 + } else if (response_status == 304 && h->header_len > sizeof("Content-Type:") - 1 && + strncasecmp(h->header, "Content-Type:", sizeof("Content-Type:") - 1) == 0 ) { h = (sapi_header_struct*)zend_llist_get_next_ex(&sapi_headers->headers, &pos); continue; @@ -498,7 +498,7 @@ static int sapi_cgi_read_post(char *buffer, uint count_bytes TSRMLS_DC) fcgi_request *request = (fcgi_request*) SG(server_context); if (request_body_fd == -1) { char *request_body_filename = sapi_cgibin_getenv((char *) "REQUEST_BODY_FILE", - sizeof("REQUEST_BODY_FILE")-1 TSRMLS_CC); + sizeof("REQUEST_BODY_FILE") - 1 TSRMLS_CC); if (request_body_filename && *request_body_filename) { request_body_fd = open(request_body_filename, O_RDONLY); @@ -605,7 +605,7 @@ static char *_sapi_cgibin_putenv(char *name, char *value TSRMLS_DC) static char *sapi_cgi_read_cookies(TSRMLS_D) { - return sapi_cgibin_getenv((char *) "HTTP_COOKIE", sizeof("HTTP_COOKIE")-1 TSRMLS_CC); + return sapi_cgibin_getenv((char *) "HTTP_COOKIE", sizeof("HTTP_COOKIE") - 1 TSRMLS_CC); } void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) @@ -674,12 +674,13 @@ static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC) if (CGIG(fix_pathinfo)) { char *script_name = SG(request_info).request_uri; unsigned int script_name_len = script_name ? strlen(script_name) : 0; - char *path_info = sapi_cgibin_getenv("PATH_INFO", sizeof("PATH_INFO")-1 TSRMLS_CC); + char *path_info = sapi_cgibin_getenv("PATH_INFO", sizeof("PATH_INFO") - 1 TSRMLS_CC); unsigned int path_info_len = path_info ? strlen(path_info) : 0; php_self_len = script_name_len + path_info_len; php_self = emalloc(php_self_len + 1); + /* Concat script_name and path_info into php_self */ if (script_name) { memcpy(php_self, script_name, script_name_len + 1); } @@ -1083,8 +1084,8 @@ static int is_valid_path(const char *path) */ static void init_request_info(TSRMLS_D) { - char *env_script_filename = sapi_cgibin_getenv("SCRIPT_FILENAME", sizeof("SCRIPT_FILENAME")-1 TSRMLS_CC); - char *env_path_translated = sapi_cgibin_getenv("PATH_TRANSLATED", sizeof("PATH_TRANSLATED")-1 TSRMLS_CC); + char *env_script_filename = sapi_cgibin_getenv("SCRIPT_FILENAME", sizeof("SCRIPT_FILENAME") - 1 TSRMLS_CC); + char *env_path_translated = sapi_cgibin_getenv("PATH_TRANSLATED", sizeof("PATH_TRANSLATED") - 1 TSRMLS_CC); char *script_path_translated = env_script_filename; char *ini; int apache_was_here = 0; @@ -1112,17 +1113,17 @@ static void init_request_info(TSRMLS_D) * of the script will be retreived later via argc/argv */ if (script_path_translated) { const char *auth; - char *content_length = sapi_cgibin_getenv("CONTENT_LENGTH", sizeof("CONTENT_LENGTH")-1 TSRMLS_CC); - char *content_type = sapi_cgibin_getenv("CONTENT_TYPE", sizeof("CONTENT_TYPE")-1 TSRMLS_CC); - char *env_path_info = sapi_cgibin_getenv("PATH_INFO", sizeof("PATH_INFO")-1 TSRMLS_CC); - char *env_script_name = sapi_cgibin_getenv("SCRIPT_NAME", sizeof("SCRIPT_NAME")-1 TSRMLS_CC); + char *content_length = sapi_cgibin_getenv("CONTENT_LENGTH", sizeof("CONTENT_LENGTH") - 1 TSRMLS_CC); + char *content_type = sapi_cgibin_getenv("CONTENT_TYPE", sizeof("CONTENT_TYPE") - 1 TSRMLS_CC); + char *env_path_info = sapi_cgibin_getenv("PATH_INFO", sizeof("PATH_INFO") - 1 TSRMLS_CC); + char *env_script_name = sapi_cgibin_getenv("SCRIPT_NAME", sizeof("SCRIPT_NAME") - 1 TSRMLS_CC); /* Hack for buggy IIS that sets incorrect PATH_INFO */ - char *env_server_software = sapi_cgibin_getenv("SERVER_SOFTWARE", sizeof("SERVER_SOFTWARE")-1 TSRMLS_CC); + char *env_server_software = sapi_cgibin_getenv("SERVER_SOFTWARE", sizeof("SERVER_SOFTWARE") - 1 TSRMLS_CC); if (env_server_software && env_script_name && env_path_info && - strncmp(env_server_software, "Microsoft-IIS", sizeof("Microsoft-IIS")-1) == 0 && + strncmp(env_server_software, "Microsoft-IIS", sizeof("Microsoft-IIS") - 1) == 0 && strncmp(env_path_info, env_script_name, strlen(env_script_name)) == 0 ) { env_path_info = _sapi_cgibin_putenv("ORIG_PATH_INFO", env_path_info TSRMLS_CC); @@ -1160,8 +1161,8 @@ static void init_request_info(TSRMLS_D) if (CGIG(fix_pathinfo)) { struct stat st; char *real_path = NULL; - char *env_redirect_url = sapi_cgibin_getenv("REDIRECT_URL", sizeof("REDIRECT_URL")-1 TSRMLS_CC); - char *env_document_root = sapi_cgibin_getenv("DOCUMENT_ROOT", sizeof("DOCUMENT_ROOT")-1 TSRMLS_CC); + char *env_redirect_url = sapi_cgibin_getenv("REDIRECT_URL", sizeof("REDIRECT_URL") - 1 TSRMLS_CC); + char *env_document_root = sapi_cgibin_getenv("DOCUMENT_ROOT", sizeof("DOCUMENT_ROOT") - 1 TSRMLS_CC); char *orig_path_translated = env_path_translated; char *orig_path_info = env_path_info; char *orig_script_name = env_script_name; @@ -1396,19 +1397,19 @@ static void init_request_info(TSRMLS_D) SG(request_info).path_translated = estrdup(script_path_translated); } - SG(request_info).request_method = sapi_cgibin_getenv("REQUEST_METHOD", sizeof("REQUEST_METHOD")-1 TSRMLS_CC); + SG(request_info).request_method = sapi_cgibin_getenv("REQUEST_METHOD", sizeof("REQUEST_METHOD") - 1 TSRMLS_CC); /* FIXME - Work out proto_num here */ - SG(request_info).query_string = sapi_cgibin_getenv("QUERY_STRING", sizeof("QUERY_STRING")-1 TSRMLS_CC); + SG(request_info).query_string = sapi_cgibin_getenv("QUERY_STRING", sizeof("QUERY_STRING") - 1 TSRMLS_CC); SG(request_info).content_type = (content_type ? content_type : "" ); SG(request_info).content_length = (content_length ? atoi(content_length) : 0); /* The CGI RFC allows servers to pass on unvalidated Authorization data */ - auth = sapi_cgibin_getenv("HTTP_AUTHORIZATION", sizeof("HTTP_AUTHORIZATION")-1 TSRMLS_CC); + auth = sapi_cgibin_getenv("HTTP_AUTHORIZATION", sizeof("HTTP_AUTHORIZATION") - 1 TSRMLS_CC); php_handle_auth_data(auth TSRMLS_CC); } /* INI stuff */ - ini = sapi_cgibin_getenv("PHP_VALUE", sizeof("PHP_VALUE")-1 TSRMLS_CC); + ini = sapi_cgibin_getenv("PHP_VALUE", sizeof("PHP_VALUE") - 1 TSRMLS_CC); if (ini) { int mode = ZEND_INI_USER; char *tmp; @@ -1417,7 +1418,7 @@ static void init_request_info(TSRMLS_D) efree(tmp); } - ini = sapi_cgibin_getenv("PHP_ADMIN_VALUE", sizeof("PHP_ADMIN_VALUE")-1 TSRMLS_CC); + ini = sapi_cgibin_getenv("PHP_ADMIN_VALUE", sizeof("PHP_ADMIN_VALUE") - 1 TSRMLS_CC); if (ini) { int mode = ZEND_INI_SYSTEM; char *tmp; diff --git a/sapi/fpm/fpm/fpm_scoreboard.c b/sapi/fpm/fpm/fpm_scoreboard.c index a980df91069c1..4222f6037c765 100644 --- a/sapi/fpm/fpm/fpm_scoreboard.c +++ b/sapi/fpm/fpm/fpm_scoreboard.c @@ -57,7 +57,7 @@ int fpm_scoreboard_init_main() /* {{{ */ return -1; } wp->scoreboard->nprocs = wp->config->pm_max_children; - for (i=0; iscoreboard->nprocs; i++) { + for (i = 0; i < wp->scoreboard->nprocs; i++) { wp->scoreboard->procs[i] = fpm_shm_alloc(sizeof(struct fpm_scoreboard_proc_s)); if (!wp->scoreboard->procs[i]) { return -1; @@ -231,7 +231,7 @@ void fpm_scoreboard_free(struct fpm_scoreboard_s *scoreboard) /* {{{ */ return; } - for (i=0; inprocs; i++) { + for (i = 0; i < scoreboard->nprocs; i++) { if (!scoreboard->procs[i]) { continue; } @@ -291,7 +291,7 @@ int fpm_scoreboard_proc_alloc(struct fpm_scoreboard_s *scoreboard, int *child_in if (i < 0) { /* the supposed free slot is not, let's search for a free slot */ zlog(ZLOG_DEBUG, "[pool %s] the proc->free_slot was not free. Let's search", scoreboard->pool); - for (i=0; inprocs; i++) { + for (i = 0; i < scoreboard->nprocs; i++) { if (scoreboard->procs[i] && !scoreboard->procs[i]->used) { /* found */ break; } diff --git a/sapi/fpm/fpm/fpm_signals.c b/sapi/fpm/fpm/fpm_signals.c index aea69750bff64..7c317e57606f5 100644 --- a/sapi/fpm/fpm/fpm_signals.c +++ b/sapi/fpm/fpm/fpm_signals.c @@ -201,11 +201,11 @@ int fpm_signals_init_main() /* {{{ */ sigfillset(&act.sa_mask); if (0 > sigaction(SIGTERM, &act, 0) || - 0 > sigaction(SIGINT, &act, 0) || - 0 > sigaction(SIGUSR1, &act, 0) || - 0 > sigaction(SIGUSR2, &act, 0) || - 0 > sigaction(SIGCHLD, &act, 0) || - 0 > sigaction(SIGQUIT, &act, 0)) { + 0 > sigaction(SIGINT, &act, 0) || + 0 > sigaction(SIGUSR1, &act, 0) || + 0 > sigaction(SIGUSR2, &act, 0) || + 0 > sigaction(SIGCHLD, &act, 0) || + 0 > sigaction(SIGQUIT, &act, 0)) { zlog(ZLOG_SYSERROR, "sigaction() failed"); return -1; @@ -230,11 +230,11 @@ int fpm_signals_init_child() /* {{{ */ close(sp[1]); if (0 > sigaction(SIGTERM, &act_dfl, 0) || - 0 > sigaction(SIGINT, &act_dfl, 0) || - 0 > sigaction(SIGUSR1, &act_dfl, 0) || - 0 > sigaction(SIGUSR2, &act_dfl, 0) || - 0 > sigaction(SIGCHLD, &act_dfl, 0) || - 0 > sigaction(SIGQUIT, &act, 0)) { + 0 > sigaction(SIGINT, &act_dfl, 0) || + 0 > sigaction(SIGUSR1, &act_dfl, 0) || + 0 > sigaction(SIGUSR2, &act_dfl, 0) || + 0 > sigaction(SIGCHLD, &act_dfl, 0) || + 0 > sigaction(SIGQUIT, &act, 0)) { zlog(ZLOG_SYSERROR, "sigaction() failed"); return -1; From 9898f9070ffdc983e2ed0387df760f8441ddc49c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Tue, 5 Jul 2011 16:09:06 +0000 Subject: [PATCH 0269/2394] - Fixed bug #52935 (call exit in user_error_handler cause stream relate core). --- main/streams/streams.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/main/streams/streams.c b/main/streams/streams.c index 673795971a40c..15c1454547ac3 100755 --- a/main/streams/streams.c +++ b/main/streams/streams.c @@ -163,6 +163,7 @@ void php_stream_display_wrapper_errors(php_stream_wrapper *wrapper, const char * char *tmp = estrdup(path); char *msg; int free_msg = 0; + php_stream_wrapper orig_wrapper; if (wrapper) { if (wrapper->err_count > 0) { @@ -207,7 +208,16 @@ void php_stream_display_wrapper_errors(php_stream_wrapper *wrapper, const char * } php_strip_url_passwd(tmp); + if (wrapper) { + /* see bug #52935 */ + orig_wrapper = *wrapper; + wrapper->err_stack = NULL; + wrapper->err_count = 0; + } php_error_docref1(NULL TSRMLS_CC, tmp, E_WARNING, "%s: %s", caption, msg); + if (wrapper) { + *wrapper = orig_wrapper; + } efree(tmp); if (free_msg) { efree(msg); From 035536adca9ff53afdce34beba270a1f7744548b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 5 Jul 2011 18:09:07 +0000 Subject: [PATCH 0270/2394] - Fixed wrong value of log_level when invoking fpm with -tt --- sapi/fpm/fpm/fpm_conf.c | 2 +- sapi/fpm/fpm/zlog.c | 10 ++++++++-- sapi/fpm/fpm/zlog.h | 2 +- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 7fe27eda5e4df..6a37ae27f4f21 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -1151,7 +1151,7 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tpid = %s", STR2STR(fpm_global_config.pid_file)); zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize)); zlog(ZLOG_NOTICE, "\terror_log = %s", STR2STR(fpm_global_config.error_log)); - zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name()); + zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name(fpm_globals.log_level)); zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval); zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold); diff --git a/sapi/fpm/fpm/zlog.c b/sapi/fpm/fpm/zlog.c index e45f5c5379598..6b062eb8ae22f 100644 --- a/sapi/fpm/fpm/zlog.c +++ b/sapi/fpm/fpm/zlog.c @@ -29,9 +29,15 @@ static const char *level_names[] = { [ZLOG_ALERT] = "ALERT", }; -const char *zlog_get_level_name() /* {{{ */ +const char *zlog_get_level_name(int log_level) /* {{{ */ { - return level_names[zlog_level]; + if (log_level < 0) { + log_level = zlog_level; + } else if (log_level < ZLOG_DEBUG || log_level > ZLOG_ALERT) { + return "unknown value"; + } + + return level_names[log_level]; } /* }}} */ diff --git a/sapi/fpm/fpm/zlog.h b/sapi/fpm/fpm/zlog.h index 598c075e35ef6..a83e329023e4a 100644 --- a/sapi/fpm/fpm/zlog.h +++ b/sapi/fpm/fpm/zlog.h @@ -11,7 +11,7 @@ struct timeval; int zlog_set_fd(int new_fd); int zlog_set_level(int new_value); -const char *zlog_get_level_name(); +const char *zlog_get_level_name(int log_level); void zlog_set_launched(void); size_t zlog_print_time(struct timeval *tv, char *timebuf, size_t timebuf_len); From af84289663a5c4a0bcee7a2ac7285bbcb4c385af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 5 Jul 2011 19:22:45 +0000 Subject: [PATCH 0271/2394] - FR #52052: Added partial syslog support (on error_log only) --- sapi/fpm/fpm/fpm_conf.c | 221 ++++++++++++++++++++++++++++++++++++--- sapi/fpm/fpm/fpm_conf.h | 5 + sapi/fpm/fpm/fpm_stdio.c | 28 ++++- sapi/fpm/fpm/zlog.c | 68 +++++++++--- sapi/fpm/fpm/zlog.h | 8 ++ sapi/fpm/php-fpm.conf.in | 15 +++ 6 files changed, 309 insertions(+), 36 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 6a37ae27f4f21..a7ad4d2551169 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -31,6 +31,7 @@ #include "zend_ini_scanner.h" #include "zend_globals.h" #include "zend_stream.h" +#include "php_syslog.h" #include "fpm.h" #include "fpm_conf.h" @@ -58,8 +59,16 @@ static char *fpm_conf_set_string(zval *value, void **config, intptr_t offset); static char *fpm_conf_set_log_level(zval *value, void **config, intptr_t offset); static char *fpm_conf_set_rlimit_core(zval *value, void **config, intptr_t offset); static char *fpm_conf_set_pm(zval *value, void **config, intptr_t offset); +#ifdef HAVE_SYSLOG_H +static char *fpm_conf_set_syslog_facility(zval *value, void **config, intptr_t offset); +#endif -struct fpm_global_config_s fpm_global_config = { .daemonize = 1 }; +struct fpm_global_config_s fpm_global_config = { + .daemonize = 1, +#ifdef HAVE_SYSLOG_H + .syslog_facility = -1 +#endif +}; static struct fpm_worker_pool_s *current_wp = NULL; static int ini_recursion = 0; static char *ini_filename = NULL; @@ -67,15 +76,19 @@ static int ini_lineno = 0; static char *ini_include = NULL; static struct ini_value_parser_s ini_fpm_global_options[] = { - { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, - { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, - { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, - { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, - { "pid", &fpm_conf_set_string, GO(pid_file) }, - { "error_log", &fpm_conf_set_string, GO(error_log) }, - { "log_level", &fpm_conf_set_log_level, 0 }, - { "rlimit_files", &fpm_conf_set_integer, GO(rlimit_files) }, - { "rlimit_core", &fpm_conf_set_rlimit_core, GO(rlimit_core) }, + { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, + { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, + { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, + { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, + { "pid", &fpm_conf_set_string, GO(pid_file) }, + { "error_log", &fpm_conf_set_string, GO(error_log) }, + { "log_level", &fpm_conf_set_log_level, GO(log_level) }, +#ifdef HAVE_SYSLOG_H + { "syslog.ident", &fpm_conf_set_string, GO(syslog_ident) }, + { "syslog.facility", &fpm_conf_set_syslog_facility, GO(syslog_facility) }, +#endif + { "rlimit_files", &fpm_conf_set_integer, GO(rlimit_files) }, + { "rlimit_core", &fpm_conf_set_rlimit_core, GO(rlimit_core) }, { 0, 0, 0 } }; @@ -252,25 +265,178 @@ static char *fpm_conf_set_time(zval *value, void **config, intptr_t offset) /* { static char *fpm_conf_set_log_level(zval *value, void **config, intptr_t offset) /* {{{ */ { char *val = Z_STRVAL_P(value); + int log_level; if (!strcasecmp(val, "debug")) { - fpm_globals.log_level = ZLOG_DEBUG; + log_level = ZLOG_DEBUG; } else if (!strcasecmp(val, "notice")) { - fpm_globals.log_level = ZLOG_NOTICE; + log_level = ZLOG_NOTICE; } else if (!strcasecmp(val, "warning") || !strcasecmp(val, "warn")) { - fpm_globals.log_level = ZLOG_WARNING; + log_level = ZLOG_WARNING; } else if (!strcasecmp(val, "error")) { - fpm_globals.log_level = ZLOG_ERROR; + log_level = ZLOG_ERROR; } else if (!strcasecmp(val, "alert")) { - fpm_globals.log_level = ZLOG_ALERT; + log_level = ZLOG_ALERT; } else { return "invalid value for 'log_level'"; } + * (int *) ((char *) *config + offset) = log_level; return NULL; } /* }}} */ +#ifdef HAVE_SYSLOG_H +static char *fpm_conf_set_syslog_facility(zval *value, void **config, intptr_t offset) /* {{{ */ +{ + char *val = Z_STRVAL_P(value); + int *conf = (int *) ((char *) *config + offset); + +#ifdef LOG_AUTH + if (!strcasecmp(val, "AUTH")) { + *conf = LOG_AUTH; + return NULL; + } +#endif + +#ifdef LOG_AUTHPRIV + if (!strcasecmp(val, "AUTHPRIV")) { + *conf = LOG_AUTHPRIV; + return NULL; + } +#endif + +#ifdef LOG_CRON + if (!strcasecmp(val, "CRON")) { + *conf = LOG_CRON; + return NULL; + } +#endif + +#ifdef LOG_DAEMON + if (!strcasecmp(val, "DAEMON")) { + *conf = LOG_DAEMON; + return NULL; + } +#endif + +#ifdef LOG_FTP + if (!strcasecmp(val, "FTP")) { + *conf = LOG_FTP; + return NULL; + } +#endif + +#ifdef LOG_KERN + if (!strcasecmp(val, "KERN")) { + *conf = LOG_KERN; + return NULL; + } +#endif + +#ifdef LOG_LPR + if (!strcasecmp(val, "LPR")) { + *conf = LOG_LPR; + return NULL; + } +#endif + +#ifdef LOG_MAIL + if (!strcasecmp(val, "MAIL")) { + *conf = LOG_MAIL; + return NULL; + } +#endif + +#ifdef LOG_NEWS + if (!strcasecmp(val, "NEWS")) { + *conf = LOG_NEWS; + return NULL; + } +#endif + +#ifdef LOG_SYSLOG + if (!strcasecmp(val, "SYSLOG")) { + *conf = LOG_SYSLOG; + return NULL; + } +#endif + +#ifdef LOG_USER + if (!strcasecmp(val, "USER")) { + *conf = LOG_USER; + return NULL; + } +#endif + +#ifdef LOG_UUCP + if (!strcasecmp(val, "UUCP")) { + *conf = LOG_UUCP; + return NULL; + } +#endif + +#ifdef LOG_LOCAL0 + if (!strcasecmp(val, "LOCAL0")) { + *conf = LOG_LOCAL0; + return NULL; + } +#endif + +#ifdef LOG_LOCAL1 + if (!strcasecmp(val, "LOCAL1")) { + *conf = LOG_LOCAL1; + return NULL; + } +#endif + +#ifdef LOG_LOCAL2 + if (!strcasecmp(val, "LOCAL2")) { + *conf = LOG_LOCAL2; + return NULL; + } +#endif + +#ifdef LOG_LOCAL3 + if (!strcasecmp(val, "LOCAL3")) { + *conf = LOG_LOCAL3; + return NULL; + } +#endif + +#ifdef LOG_LOCAL4 + if (!strcasecmp(val, "LOCAL4")) { + *conf = LOG_LOCAL4; + return NULL; + } +#endif + +#ifdef LOG_LOCAL5 + if (!strcasecmp(val, "LOCAL5")) { + *conf = LOG_LOCAL5; + return NULL; + } +#endif + +#ifdef LOG_LOCAL6 + if (!strcasecmp(val, "LOCAL6")) { + *conf = LOG_LOCAL6; + return NULL; + } +#endif + +#ifdef LOG_LOCAL7 + if (!strcasecmp(val, "LOCAL7")) { + *conf = LOG_LOCAL7; + return NULL; + } +#endif + + return "invalid value"; +} +/* }}} */ +#endif + static char *fpm_conf_set_rlimit_core(zval *value, void **config, intptr_t offset) /* {{{ */ { char *val = Z_STRVAL_P(value); @@ -794,11 +960,26 @@ static int fpm_conf_post_process(TSRMLS_D) /* {{{ */ fpm_evaluate_full_path(&fpm_global_config.pid_file, NULL, PHP_LOCALSTATEDIR, 0); } + fpm_globals.log_level = fpm_global_config.log_level; + if (!fpm_global_config.error_log) { fpm_global_config.error_log = strdup("log/php-fpm.log"); } - fpm_evaluate_full_path(&fpm_global_config.error_log, NULL, PHP_LOCALSTATEDIR, 0); +#ifdef HAVE_SYSLOG_H + if (!fpm_global_config.syslog_ident) { + fpm_global_config.syslog_ident = strdup("php-fpm"); + } + + if (fpm_global_config.syslog_facility < 0) { + fpm_global_config.syslog_facility = LOG_DAEMON; + } + + if (strcasecmp(fpm_global_config.error_log, "syslog") != 0) +#endif + { + fpm_evaluate_full_path(&fpm_global_config.error_log, NULL, PHP_LOCALSTATEDIR, 0); + } if (0 > fpm_stdio_open_error_log(0)) { return -1; @@ -832,6 +1013,10 @@ static void fpm_conf_cleanup(int which, void *arg) /* {{{ */ free(fpm_global_config.error_log); fpm_global_config.pid_file = 0; fpm_global_config.error_log = 0; +#ifdef HAVE_SYSLOG_H + free(fpm_global_config.syslog_ident); + fpm_global_config.syslog_ident = 0; +#endif free(fpm_globals.config); } /* }}} */ @@ -1152,6 +1337,10 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize)); zlog(ZLOG_NOTICE, "\terror_log = %s", STR2STR(fpm_global_config.error_log)); zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name(fpm_globals.log_level)); +#ifdef HAVE_SYSLOG_H + zlog(ZLOG_NOTICE, "\tsyslog.ident = %s", STR2STR(fpm_global_config.syslog_ident)); + zlog(ZLOG_NOTICE, "\tsyslog.facility = %d", fpm_global_config.syslog_facility); /* FIXME: convert to string */ +#endif zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval); zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold); diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index 2152527eea41a..87a5cd332b6f3 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -25,6 +25,11 @@ struct fpm_global_config_s { int daemonize; char *pid_file; char *error_log; + int log_level; +#ifdef HAVE_SYSLOG_H + char *syslog_ident; + int syslog_facility; +#endif int rlimit_files; int rlimit_core; }; diff --git a/sapi/fpm/fpm/fpm_stdio.c b/sapi/fpm/fpm/fpm_stdio.c index 571f3074b53af..4948194f84ff3 100644 --- a/sapi/fpm/fpm/fpm_stdio.c +++ b/sapi/fpm/fpm/fpm_stdio.c @@ -11,6 +11,8 @@ #include #include +#include "php_syslog.h" + #include "fpm.h" #include "fpm_children.h" #include "fpm_events.h" @@ -42,8 +44,10 @@ int fpm_stdio_init_main() /* {{{ */ int fpm_stdio_init_final() /* {{{ */ { if (fpm_global_config.daemonize) { - if (fpm_globals.error_log_fd != STDERR_FILENO) { - /* there might be messages to stderr from libevent, we need to log them all */ + /* prevent duping if logging to syslog */ + if (fpm_globals.error_log_fd > 0 && fpm_globals.error_log_fd != STDERR_FILENO) { + + /* there might be messages to stderr from other parts of the code, we need to log them all */ if (0 > dup2(fpm_globals.error_log_fd, STDERR_FILENO)) { zlog(ZLOG_SYSERROR, "dup2() failed"); return -1; @@ -57,7 +61,14 @@ int fpm_stdio_init_final() /* {{{ */ int fpm_stdio_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ { - close(fpm_globals.error_log_fd); +#ifdef HAVE_SYSLOG_H + if (fpm_globals.error_log_fd == ZLOG_SYSLOG) { + closelog(); /* ensure to close syslog not to interrupt with PHP syslog code */ + } else +#endif + if (fpm_globals.error_log_fd > 0) { + close(fpm_globals.error_log_fd); + } fpm_globals.error_log_fd = -1; zlog_set_fd(-1); @@ -249,6 +260,17 @@ int fpm_stdio_open_error_log(int reopen) /* {{{ */ { int fd; +#ifdef HAVE_SYSLOG_H + if (!strcasecmp(fpm_global_config.error_log, "syslog")) { + openlog(fpm_global_config.syslog_ident, LOG_PID | LOG_CONS, fpm_global_config.syslog_facility); + fpm_globals.error_log_fd = ZLOG_SYSLOG; + if (fpm_global_config.daemonize) { + zlog_set_fd(fpm_globals.error_log_fd); + } + return 0; + } +#endif + fd = open(fpm_global_config.error_log, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); if (0 > fd) { zlog(ZLOG_SYSERROR, "open(\"%s\") failed", fpm_global_config.error_log); diff --git a/sapi/fpm/fpm/zlog.c b/sapi/fpm/fpm/zlog.c index 6b062eb8ae22f..b127ec16f67a0 100644 --- a/sapi/fpm/fpm/zlog.c +++ b/sapi/fpm/fpm/zlog.c @@ -12,6 +12,8 @@ #include #include +#include "php_syslog.h" + #include "zlog.h" #include "fpm.h" @@ -22,12 +24,22 @@ static int zlog_level = ZLOG_NOTICE; static int launched = 0; static const char *level_names[] = { - [ZLOG_DEBUG] = "DEBUG", - [ZLOG_NOTICE] = "NOTICE", - [ZLOG_WARNING] = "WARNING", - [ZLOG_ERROR] = "ERROR", - [ZLOG_ALERT] = "ALERT", + [ZLOG_DEBUG] = "DEBUG", + [ZLOG_NOTICE] = "NOTICE", + [ZLOG_WARNING] = "WARNING", + [ZLOG_ERROR] = "ERROR", + [ZLOG_ALERT] = "ALERT", +}; + +#ifdef HAVE_SYSLOG_H +const int syslog_priorities[] = { + [ZLOG_DEBUG] = LOG_DEBUG, + [ZLOG_NOTICE] = LOG_NOTICE, + [ZLOG_WARNING] = LOG_WARNING, + [ZLOG_ERROR] = LOG_ERR, + [ZLOG_ALERT] = LOG_ALERT, }; +#endif const char *zlog_get_level_name(int log_level) /* {{{ */ { @@ -94,18 +106,30 @@ void zlog_ex(const char *function, int line, int flags, const char *fmt, ...) /* } saved_errno = errno; - if (!fpm_globals.is_child) { - gettimeofday(&tv, 0); - len = zlog_print_time(&tv, buf, buf_size); - } - if (zlog_level == ZLOG_DEBUG) { +#ifdef HAVE_SYSLOG_H + if (zlog_fd == ZLOG_SYSLOG /* && !fpm_globals.is_child */) { + len = 0; + if (zlog_level == ZLOG_DEBUG) { + len += snprintf(buf, buf_size, "[%s] %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], function, line); + } else { + len += snprintf(buf, buf_size, "[%s] ", level_names[flags & ZLOG_LEVEL_MASK]); + } + } else +#endif + { if (!fpm_globals.is_child) { - len += snprintf(buf + len, buf_size - len, "%s: pid %d, %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], getpid(), function, line); + gettimeofday(&tv, 0); + len = zlog_print_time(&tv, buf, buf_size); + } + if (zlog_level == ZLOG_DEBUG) { + if (!fpm_globals.is_child) { + len += snprintf(buf + len, buf_size - len, "%s: pid %d, %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], getpid(), function, line); + } else { + len += snprintf(buf + len, buf_size - len, "%s: %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], function, line); + } } else { - len += snprintf(buf + len, buf_size - len, "%s: %s(), line %d: ", level_names[flags & ZLOG_LEVEL_MASK], function, line); + len += snprintf(buf + len, buf_size - len, "%s: ", level_names[flags & ZLOG_LEVEL_MASK]); } - } else { - len += snprintf(buf + len, buf_size - len, "%s: ", level_names[flags & ZLOG_LEVEL_MASK]); } if (len > buf_size - 1) { @@ -135,9 +159,19 @@ void zlog_ex(const char *function, int line, int flags, const char *fmt, ...) /* len = buf_size - 1; } - buf[len++] = '\n'; - write(zlog_fd > -1 ? zlog_fd : STDERR_FILENO, buf, len); - if (zlog_fd != STDERR_FILENO && zlog_fd > -1 && !launched && (flags & ZLOG_LEVEL_MASK) >= ZLOG_NOTICE) { +#ifdef HAVE_SYSLOG_H + if (zlog_fd == ZLOG_SYSLOG) { + buf[len] = '\0'; + php_syslog(syslog_priorities[zlog_level], "%s", buf); + buf[len++] = '\n'; + } else +#endif + { + buf[len++] = '\n'; + write(zlog_fd > -1 ? zlog_fd : STDERR_FILENO, buf, len); + } + + if (zlog_fd != STDERR_FILENO && zlog_fd != -1 && !launched && (flags & ZLOG_LEVEL_MASK) >= ZLOG_NOTICE) { write(STDERR_FILENO, buf, len); } } diff --git a/sapi/fpm/fpm/zlog.h b/sapi/fpm/fpm/zlog.h index a83e329023e4a..e6a5c019a8840 100644 --- a/sapi/fpm/fpm/zlog.h +++ b/sapi/fpm/fpm/zlog.h @@ -19,6 +19,10 @@ size_t zlog_print_time(struct timeval *tv, char *timebuf, size_t timebuf_len); void zlog_ex(const char *function, int line, int flags, const char *fmt, ...) __attribute__ ((format(printf,4,5))); +#ifdef HAVE_SYSLOG_H +extern const int syslog_priorities[]; +#endif + enum { ZLOG_DEBUG = 1, ZLOG_NOTICE = 2, @@ -33,4 +37,8 @@ enum { #define ZLOG_SYSERROR (ZLOG_ERROR | ZLOG_HAVE_ERRNO) +#ifdef HAVE_SYSLOG_H +#define ZLOG_SYSLOG -2 +#endif + #endif diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index 2997ac67f92d6..00db9e340e788 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -25,10 +25,25 @@ ;pid = run/php-fpm.pid ; Error log file +; If it's set to "syslog", log is sent to syslogd instead of being written +; in a local file. ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@ ; Default Value: log/php-fpm.log ;error_log = log/php-fpm.log +; syslog_facility is used to specify what type of program is logging the +; message. This lets syslogd specify that messages from different facilities +; will be handled differently. +; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON) +; Default Value: daemon +;syslog.facility = daemon + +; syslog_ident is prepended to every message. If you have multiple FPM +; instances running on the same server, you can change the default value +; which must suit common needs. +; Default Value: php-fpm +;syslog.ident = php-fpm + ; Log level ; Possible Values: alert, error, warning, notice, debug ; Default Value: notice From 3c82aab1518e321e560cc6daedf1c698741fb861 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 5 Jul 2011 20:10:45 +0000 Subject: [PATCH 0272/2394] Fixed bug relating to un-initialized memory access --- ext/standard/crypt_sha256.c | 3 ++- ext/standard/crypt_sha512.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ext/standard/crypt_sha256.c b/ext/standard/crypt_sha256.c index 26260992ef094..231206bca14db 100644 --- a/ext/standard/crypt_sha256.c +++ b/ext/standard/crypt_sha256.c @@ -395,9 +395,10 @@ char * php_sha256_crypt_r(const char *key, const char *salt, char *buffer, int b } if ((salt - (char *) 0) % __alignof__(uint32_t) != 0) { - char *tmp = (char *) alloca(salt_len + __alignof__(uint32_t)); + char *tmp = (char *) alloca(salt_len + 1 + __alignof__(uint32_t)); salt = copied_salt = memcpy(tmp + __alignof__(uint32_t) - (tmp - (char *) 0) % __alignof__ (uint32_t), salt, salt_len); + tmp[salt_len] = 0; } /* Prepare for the real work. */ diff --git a/ext/standard/crypt_sha512.c b/ext/standard/crypt_sha512.c index a51e11a37c208..708ad67caa3ba 100644 --- a/ext/standard/crypt_sha512.c +++ b/ext/standard/crypt_sha512.c @@ -430,8 +430,8 @@ php_sha512_crypt_r(const char *key, const char *salt, char *buffer, int buflen) } if ((salt - (char *) 0) % __alignof__ (uint64_t) != 0) { - char *tmp = (char *) alloca(salt_len + __alignof__(uint64_t)); - + char *tmp = (char *) alloca(salt_len + 1 + __alignof__(uint64_t)); + tmp[salt_len] = 0; salt = copied_salt = memcpy(tmp + __alignof__(uint64_t) - (tmp - (char *) 0) % __alignof__(uint64_t), salt, salt_len); } From fa27e05438d9071f197a52a8977771e44ad751ba Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 5 Jul 2011 20:31:53 +0000 Subject: [PATCH 0273/2394] free data in case of failure in the callee not in the caller --- ext/mysqlnd/mysqlnd.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index a927018dd188e..e6072e3201277 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -157,6 +157,7 @@ MYSQLND_METHOD(mysqlnd_conn, free_contents)(MYSQLND * conn TSRMLS_DC) mnd_pefree(conn->unix_socket, pers); conn->unix_socket = NULL; } + DBG_INF_FMT("scheme=%s", conn->scheme); if (conn->scheme) { mnd_pefree(conn->scheme, pers); conn->scheme = NULL; @@ -717,7 +718,7 @@ MYSQLND_METHOD(mysqlnd_conn, connect)(MYSQLND * conn, SET_OOM_ERROR(conn->error_info); goto err; /* OOM */ } - DBG_INF_FMT("transport=%s", transport); + DBG_INF_FMT("transport=%s conn->scheme=%s", transport, conn->scheme); conn->scheme = mnd_pestrndup(transport, transport_len, conn->persistent); conn->scheme_len = transport_len; mnd_sprintf_free(transport); @@ -936,7 +937,7 @@ MYSQLND_METHOD(mysqlnd_conn, connect)(MYSQLND * conn, /* no mnd_ since we don't allocate it */ efree(errstr); } - + conn->m->free_contents(conn TSRMLS_CC); MYSQLND_INC_CONN_STATISTIC(conn->stats, STAT_CONNECT_FAILURE); DBG_RETURN(FAIL); @@ -977,9 +978,6 @@ PHPAPI MYSQLND * mysqlnd_connect(MYSQLND * conn, object - we are free to kill it! */ conn->m->dtor(conn TSRMLS_CC); - } else { - /* This will also close conn->net->stream if it has been opened */ - conn->m->free_contents(conn TSRMLS_CC); } DBG_RETURN(NULL); } From 1dcd19eba05dd98922fdbb45cb29a5b5703bbd6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 5 Jul 2011 21:03:26 +0000 Subject: [PATCH 0274/2394] - Implemented FR #54098 (Lowered default value for Process Manager) --- sapi/fpm/php-fpm.conf.in | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index 00db9e340e788..b3151c0a99950 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -170,25 +170,26 @@ pm = dynamic ; This value sets the limit on the number of simultaneous requests that will be ; served. Equivalent to the ApacheMaxClients directive with mpm_prefork. ; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP -; CGI. +; CGI. The below defaults are based on a server without much resources. Don't +; forget to tweak pm.* to fit your needs. ; Note: Used when pm is set to either 'static' or 'dynamic' ; Note: This value is mandatory. -pm.max_children = 50 +pm.max_children = 5 ; The number of child processes created on startup. ; Note: Used only when pm is set to 'dynamic' ; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2 -;pm.start_servers = 20 +pm.start_servers = 2 ; The desired minimum number of idle server processes. ; Note: Used only when pm is set to 'dynamic' ; Note: Mandatory when pm is set to 'dynamic' -;pm.min_spare_servers = 5 +pm.min_spare_servers = 1 ; The desired maximum number of idle server processes. ; Note: Used only when pm is set to 'dynamic' ; Note: Mandatory when pm is set to 'dynamic' -;pm.max_spare_servers = 35 +pm.max_spare_servers = 3 ; The number of requests each child process should execute before respawning. ; This can be useful to work around memory leaks in 3rd party libraries. For From 8cf3c27f82f53f3e7b4c0b3e903a53329126d160 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Wed, 6 Jul 2011 00:33:38 +0000 Subject: [PATCH 0275/2394] - Fixed bug #55137 (Changing trait static method visibility) --- Zend/tests/traits/bug55137.phpt | 26 ++++++++++++++++++++++++++ Zend/zend_compile.c | 2 ++ 2 files changed, 28 insertions(+) create mode 100644 Zend/tests/traits/bug55137.phpt diff --git a/Zend/tests/traits/bug55137.phpt b/Zend/tests/traits/bug55137.phpt new file mode 100644 index 0000000000000..4a4e6e61a24d8 --- /dev/null +++ b/Zend/tests/traits/bug55137.phpt @@ -0,0 +1,26 @@ +--TEST-- +Bug #55137 (Changing trait static method visibility) +--FILE-- + +--EXPECT-- +abc +def diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 5f9cef311bf72..f3b6b77718cda 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3661,6 +3661,7 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; } + fn_copy.common.fn_flags |= fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK); } lcname_len = aliases[i]->alias_len; @@ -3700,6 +3701,7 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; } + fn_copy.common.fn_flags |= fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK); } } i++; From c10d14887099b3294816f9757e7f6ea55e4b0bfa Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Wed, 6 Jul 2011 01:54:54 +0000 Subject: [PATCH 0276/2394] - Fixed bug #55076 (requires() fails in a subdirectory with the in-built webserver) --- sapi/cli/php_cli_server.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 365f352244202..66d3bc5ae487d 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2060,6 +2060,8 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ if (document_root) { struct stat sb; + char resolved_path[MAXPATHLEN]; + if (stat(document_root, &sb)) { fprintf(stderr, "Directory %s does not exist.\n", document_root); return 1; @@ -2068,6 +2070,9 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ fprintf(stderr, "%s is not a directory.\n", document_root); return 1; } + if (VCWD_REALPATH(document_root, resolved_path)) { + document_root = resolved_path; + } } else { char path[MAXPATHLEN]; char *ret = NULL; From e501b7613d09addbc324afc6934bcabea512ccf9 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 6 Jul 2011 11:13:38 +0000 Subject: [PATCH 0277/2394] - add apache 2.3 (upcoming 2.4) handler --- sapi/apache2handler/config.w32 | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/sapi/apache2handler/config.w32 b/sapi/apache2handler/config.w32 index 2f2084cb1425d..8d8a6c4b69447 100644 --- a/sapi/apache2handler/config.w32 +++ b/sapi/apache2handler/config.w32 @@ -5,7 +5,7 @@ ARG_ENABLE('apache2handler', 'Build Apache 2.x handler', 'no'); if (PHP_APACHE2HANDLER != "no") { if (PHP_ZTS == "no") { - WARNING("Apache2 module requires an --enable-zts build of PHP on windows"); + WARNING("Apache 2.0 module requires an --enable-zts build of PHP on windows"); } else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2HANDLER", PHP_PHP_BUILD + "\\include\\apache2") && CHECK_LIB("libhttpd.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2") && CHECK_LIB("libapr.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2") && @@ -23,7 +23,7 @@ ARG_ENABLE('apache2-2handler', 'Build Apache 2.2.x handler', 'no'); if (PHP_APACHE2_2HANDLER != "no") { if (PHP_ZTS == "no") { - WARNING("Apache2 module requires an --enable-zts build of PHP on windows"); + WARNING("Apache 2.2 module requires an --enable-zts build of PHP on windows"); } else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2_2HANDLER", PHP_PHP_BUILD + "\\include\\apache2_2") && CHECK_LIB("libhttpd.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2") && CHECK_LIB("libapr-1.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2") && @@ -37,3 +37,22 @@ if (PHP_APACHE2_2HANDLER != "no") { WARNING("Could not find apache2.2 libraries/headers"); } } + +ARG_ENABLE('apache2-3handler', 'Build Apache 2.3.x handler', 'no'); +if (PHP_APACHE2_3HANDLER != "no") { + if (PHP_ZTS == "no") { + WARNING("Apache 2.3 module requires an --enable-zts build of PHP on windows"); + } else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2_3HANDLER", PHP_PHP_BUILD + "\\include\\apache2_3") && + CHECK_LIB("libhttpd.lib", "apache2_3handler", PHP_PHP_BUILD + "\\lib\\apache2_3") && + CHECK_LIB("libapr-1.lib", "apache2_3handler", PHP_PHP_BUILD + "\\lib\\apache2_3") && + CHECK_LIB("libaprutil-1.lib", "apache2_3handler", PHP_PHP_BUILD + "\\lib\\apache2_3") + ) { + SAPI('apache2_3handler', 'mod_php5.c sapi_apache2.c apache_config.c php_functions.c', + 'php' + PHP_VERSION + 'apache2_3.dll', + '/D PHP_APACHE2_EXPORTS /I win32', + 'sapi\\apache2handler'); + } else { + WARNING("Could not find apache2.3 libraries/headers"); + } +} + From 3931078e7fd46c544887262c1edeb8d53294e52f Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 6 Jul 2011 12:04:02 +0000 Subject: [PATCH 0278/2394] Fixed bug #55135 (Array keys are no longer type casted in unset()) --- Zend/tests/bug55135.phpt | 38 ++++++++++++++++++ Zend/zend_vm_def.h | 7 +++- Zend/zend_vm_execute.h | 84 ++++++++++++++++++++++++++++++++++------ 3 files changed, 116 insertions(+), 13 deletions(-) create mode 100644 Zend/tests/bug55135.phpt diff --git a/Zend/tests/bug55135.phpt b/Zend/tests/bug55135.phpt new file mode 100644 index 0000000000000..f6d0aafacaeec --- /dev/null +++ b/Zend/tests/bug55135.phpt @@ -0,0 +1,38 @@ +--TEST-- +Bug #55135 (Array keys are no longer type casted in unset()) +--FILE-- + 2); +$a = "1"; +unset($array[$a]); +print_r($array); + +// Those works. +$array = array(1 => 2); +$a = 1; +unset($array[$a]); +print_r($array); + +$array = array(1 => 2); +unset($array[1]); +print_r($array); + +$array = array(1 => 2); +$a = 1; +unset($array["1"]); +print_r($array); +?> +--EXPECT-- +Array +( +) +Array +( +) +Array +( +) +Array +( +) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 77d208ce53268..aad9585a8ff6a 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -3917,7 +3917,6 @@ ZEND_VM_HANDLER(75, ZEND_UNSET_DIM, VAR|UNUSED|CV, CONST|TMP|VAR|CV) case IS_RESOURCE: case IS_BOOL: case IS_LONG: -ZEND_VM_C_LABEL(num_index_dim): hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -3944,6 +3943,12 @@ ZEND_VM_C_LABEL(num_index_dim): zval_ptr_dtor(&offset); } break; +ZEND_VM_C_LABEL(num_index_dim): + zend_hash_index_del(ht, hval); + if (OP2_TYPE == IS_CV || OP2_TYPE == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index fd726eb880a72..569254dcf18e3 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -13526,7 +13526,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -13553,6 +13552,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -15506,7 +15511,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -15533,6 +15537,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -17682,7 +17692,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -17709,6 +17718,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -20670,7 +20685,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -20697,6 +20711,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_CV == IS_CV || IS_CV == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -21992,7 +22012,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_H case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -22019,6 +22038,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_H zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -23135,7 +23160,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -23162,6 +23186,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -24278,7 +24308,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -24305,6 +24334,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -25687,7 +25722,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -25714,6 +25748,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_CV == IS_CV || IS_CV == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -28838,7 +28878,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -28865,6 +28904,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -30692,7 +30737,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -30719,6 +30763,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -32741,7 +32791,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -32768,6 +32817,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; @@ -35466,7 +35521,6 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ case IS_RESOURCE: case IS_BOOL: case IS_LONG: -num_index_dim: hval = Z_LVAL_P(offset); zend_hash_index_del(ht, hval); break; @@ -35493,6 +35547,12 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ zval_ptr_dtor(&offset); } break; +num_index_dim: + zend_hash_index_del(ht, hval); + if (IS_CV == IS_CV || IS_CV == IS_VAR) { + zval_ptr_dtor(&offset); + } + break; case IS_NULL: zend_hash_del(ht, "", sizeof("")); break; From 50b654ab0e28ae65436bcfeae224b54138dcbb39 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 6 Jul 2011 20:38:58 +0000 Subject: [PATCH 0279/2394] Fixed bug#55084 (Function registered by header_register_callback is called only once per process). (Hannes) also fixed an issue when header()s are sent from the callback function --- main/SAPI.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/main/SAPI.c b/main/SAPI.c index a0d58805fbcd3..91ed4be654111 100644 --- a/main/SAPI.c +++ b/main/SAPI.c @@ -430,6 +430,8 @@ SAPI_API void sapi_activate(TSRMLS_D) SG(sapi_headers).http_status_line = NULL; SG(sapi_headers).mimetype = NULL; SG(headers_sent) = 0; + SG(callback_run) = 0; + SG(callback_func) = NULL; SG(read_post_bytes) = 0; SG(request_info).post_data = NULL; SG(request_info).raw_post_data = NULL; @@ -539,6 +541,10 @@ SAPI_API void sapi_deactivate(TSRMLS_D) sapi_send_headers_free(TSRMLS_C); SG(sapi_started) = 0; SG(headers_sent) = 0; + SG(callback_run) = 0; + if (SG(callback_func)) { + zval_ptr_dtor(&SG(callback_func)); + } SG(request_info).headers_read = 0; SG(global_request_time) = 0; } @@ -816,7 +822,7 @@ SAPI_API int sapi_send_headers(TSRMLS_D) int retval; int ret = FAILURE; - if (SG(headers_sent) || SG(request_info).no_headers) { + if (SG(headers_sent) || SG(request_info).no_headers || SG(callback_run)) { return SUCCESS; } From 866240200f41560593e2e8958e713f3aa3a03a6c Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 7 Jul 2011 23:07:14 +0000 Subject: [PATCH 0280/2394] - Fixed bug #55156 (ReflectionClass::getDocComment() returns comment even though the class has none) --- Zend/tests/bug55156.phpt | 30 ++++++++++++++++++++++++++++++ Zend/zend_compile.c | 6 ++++++ 2 files changed, 36 insertions(+) create mode 100644 Zend/tests/bug55156.phpt diff --git a/Zend/tests/bug55156.phpt b/Zend/tests/bug55156.phpt new file mode 100644 index 0000000000000..6c0ff768d1c69 --- /dev/null +++ b/Zend/tests/bug55156.phpt @@ -0,0 +1,30 @@ +--TEST-- +Bug #55156 (ReflectionClass::getDocComment() returns comment even though the class has none) +--FILE-- +getDocComment()); + + /** test1 */ + class bar { } + + /** test2 */ + class foo extends namespace\bar { } + + $x = new \ReflectionClass('foo\bar'); + var_dump($x->getDocComment()); + + $x = new \ReflectionClass('foo\foo'); + var_dump($x->getDocComment()); +} + +?> +--EXPECTF-- +bool(false) +string(12) "/** test1 */" +string(12) "/** test2 */" diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index f3b6b77718cda..15906fc4c34a9 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6487,6 +6487,12 @@ void zend_do_begin_namespace(const znode *name, zend_bool with_bracket TSRMLS_DC efree(CG(current_import)); CG(current_import) = NULL; } + + if (CG(doc_comment)) { + efree(CG(doc_comment)); + CG(doc_comment) = NULL; + CG(doc_comment_len) = 0; + } } /* }}} */ From 31c043e7af9ea99d117c91bcfe29900c95744f1b Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 8 Jul 2011 19:52:21 +0000 Subject: [PATCH 0281/2394] - CS and WS --- Zend/zend_compile.c | 124 +++++++++++++++++--------------------------- 1 file changed, 47 insertions(+), 77 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 15906fc4c34a9..b392df3242147 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3524,8 +3524,7 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM fe->op_array.function_name = newname; /* was setting it to fe which does not work since fe is stack allocated and not a stable address */ - /* fe->op_array.prototype = fe->op_array.prototype; */ - + /* fe->op_array.prototype = fe->op_array.prototype; */ if (fe->op_array.arg_info) { zend_arg_info *tmpArginfo; @@ -3557,13 +3556,13 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM } /* }}}} */ -static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) +static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { zend_class_entry *ce = va_arg(args, zend_class_entry*); int add = 0; zend_function* existing_fn; zend_function fn_copy, *fn_copy_p; - zend_function* prototype = NULL; /* is used to determine the prototype according to the inheritance chain */ + zend_function* prototype = NULL; /* is used to determine the prototype according to the inheritance chain */ if (zend_hash_quick_find(&ce->function_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h, (void**) &existing_fn) == FAILURE) { add = 1; /* not found */ @@ -3623,8 +3622,9 @@ static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int return ZEND_HASH_APPLY_REMOVE; } +/* }}} */ -static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) +static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { HashTable* target; zend_trait_alias** aliases; @@ -3645,18 +3645,15 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, /* apply aliases which are qualified with a class name, there should not be any ambiguity */ if (aliases) { while (aliases[i]) { - - if (/* Scope unset or equal to the function we compare to */ - (!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) - && /* and, the alias applies to fn */ - (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, - aliases[i]->trait_method->mname_len, - fn->common.function_name, fnname_len) == 0)) { + /* Scope unset or equal to the function we compare to, and the alias applies to fn */ + if ((!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) + && (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, aliases[i]->trait_method->mname_len, fn->common.function_name, fnname_len) == 0)) { if (aliases[i]->alias) { fn_copy = *fn; zend_traits_duplicate_function(&fn_copy, estrndup(aliases[i]->alias, aliases[i]->alias_len) TSRMLS_CC); - - if (aliases[i]->modifiers) { /* if it is 0, no modifieres has been changed */ + + /* if it is 0, no modifieres has been changed */ + if (aliases[i]->modifiers) { fn_copy.common.fn_flags = aliases[i]->modifiers; if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; @@ -3686,17 +3683,15 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, zend_traits_duplicate_function(&fn_copy, estrndup(fn->common.function_name, fnname_len) TSRMLS_CC); /* apply aliases which are not qualified by a class name, or which have not - alias name, just setting visibility */ + * alias name, just setting visibility */ if (aliases) { i = 0; while (aliases[i]) { - if (/* Scope unset or equal to the function we compare to */ - (!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) - && /* and, the alias applies to fn */ - (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, - aliases[i]->trait_method->mname_len, - fn->common.function_name, fnname_len) == 0)) { - if (!aliases[i]->alias && aliases[i]->modifiers) { /* if it is 0, no modifieres has been changed */ + /* Scope unset or equal to the function we compare to, and the alias applies to fn */ + if ((!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) + && (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, aliases[i]->trait_method->mname_len, fn->common.function_name, fnname_len) == 0)) { + /* if it is 0, no modifieres has been changed */ + if (!aliases[i]->alias && aliases[i]->modifiers) { fn_copy.common.fn_flags = aliases[i]->modifiers; if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; @@ -3717,14 +3712,14 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, return ZEND_HASH_APPLY_KEEP; } +/* }}} */ -/** -* Copies function table entries to target function table with applied aliasing -*/ -static void zend_traits_copy_trait_function_table(HashTable *target, HashTable *source, zend_trait_alias** aliases, HashTable* exclude_table TSRMLS_DC) { - zend_hash_apply_with_arguments(source TSRMLS_CC, (apply_func_args_t)zend_traits_copy_functions, 3, /* 3 is number of args for apply_func */ - target, aliases, exclude_table); +/* Copies function table entries to target function table with applied aliasing */ +static void zend_traits_copy_trait_function_table(HashTable *target, HashTable *source, zend_trait_alias** aliases, HashTable* exclude_table TSRMLS_DC) /* {{{ */ +{ + zend_hash_apply_with_arguments(source TSRMLS_CC, (apply_func_args_t)zend_traits_copy_functions, 3, target, aliases, exclude_table); } +/* }}} */ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* {{{ */ { @@ -3734,7 +3729,6 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* zend_class_entry *cur_ce; /* resolve class references */ - if (ce->trait_precedences) { i = 0; while ((cur_precedence = ce->trait_precedences[i])) { @@ -3770,7 +3764,8 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* } /* }}} */ -static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_trait_precedence **precedences, zend_class_entry *trait) { +static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_trait_precedence **precedences, zend_class_entry *trait) /* {{{ */ +{ size_t i = 0, j; if (!precedences) { @@ -3795,6 +3790,7 @@ static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_tra ++i; } } +/* }}} */ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ */ { @@ -3806,18 +3802,16 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ /* prepare copies of trait function tables for combination */ function_tables = malloc(sizeof(HashTable*) * ce->num_traits); resulting_table = (HashTable *) malloc(sizeof(HashTable)); - zend_hash_init_ex(resulting_table, 10, /* TODO: revisit this start size, may be its not optimal */ - /* NULL, ZEND_FUNCTION_DTOR, 0, 0); */ - NULL, NULL, 0, 0); + + /* TODO: revisit this start size, may be its not optimal */ + zend_hash_init_ex(resulting_table, 10, NULL, NULL, 0, 0); for (i = 0; i < ce->num_traits; i++) { function_tables[i] = (HashTable *) malloc(sizeof(HashTable)); - zend_hash_init_ex(function_tables[i], ce->traits[i]->function_table.nNumOfElements, - /* NULL, ZEND_FUNCTION_DTOR, 0, 0); */ - NULL, NULL, 0, 0); + zend_hash_init_ex(function_tables[i], ce->traits[i]->function_table.nNumOfElements, NULL, NULL, 0, 0); - zend_hash_init_ex(&exclude_table, 2, /* TODO: revisit this start size, may be its not optimal */ - NULL, NULL, 0, 0); + /* TODO: revisit this start size, may be its not optimal */ + zend_hash_init_ex(&exclude_table, 2, NULL, NULL, 0, 0); zend_traits_compile_exclude_table(&exclude_table, ce->trait_precedences, ce->traits[i]); /* copies functions, applies defined aliasing, and excludes unused trait methods */ @@ -3827,16 +3821,14 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ /* now merge trait methods */ for (i = 0; i < ce->num_traits; i++) { - zend_hash_apply_with_arguments(function_tables[i] TSRMLS_CC, (apply_func_args_t)zend_traits_merge_functions, 5, /* 5 is number of args for apply_func */ - i, ce->num_traits, resulting_table, function_tables, ce); + zend_hash_apply_with_arguments(function_tables[i] TSRMLS_CC, (apply_func_args_t)zend_traits_merge_functions, 5, i, ce->num_traits, resulting_table, function_tables, ce); } - /* now the resulting_table contains all trait methods we would have to - add to the class - in the following step the methods are inserted into the method table - if there is already a method with the same name it is replaced iff ce != fn.scope - --> all inherited methods are overridden, methods defined in the class are left - untouched */ + /* Now the resulting_table contains all trait methods we would have to + * add to the class in the following step the methods are inserted into the method table + * if there is already a method with the same name it is replaced iff ce != fn.scope + * --> all inherited methods are overridden, methods defined in the class are left untouched + */ zend_hash_apply_with_arguments(resulting_table TSRMLS_CC, (apply_func_args_t)zend_traits_merge_functions_to_class, 1, ce); /* free temporary function tables */ @@ -3865,6 +3857,7 @@ static zend_class_entry* find_first_definition(zend_class_entry *ce, size_t curr return coliding_ce; } +/* }}} */ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ */ { @@ -3881,21 +3874,18 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { zval* prop_value; - /* in the following steps the properties are inserted into the property table - for that, a very strict approach is applied: - - check for compatibility, if not compatible with any property in class -> fatal - - if compatible, then strict notice - */ - - + /* In the following steps the properties are inserted into the property table + * for that, a very strict approach is applied: + * - check for compatibility, if not compatible with any property in class -> fatal + * - if compatible, then strict notice + */ for (i = 0; i < ce->num_traits; i++) { for (zend_hash_internal_pointer_reset(&ce->traits[i]->properties_info); zend_hash_get_current_data(&ce->traits[i]->properties_info, (void *) &property_info) == SUCCESS; zend_hash_move_forward(&ce->traits[i]->properties_info)) { - /* property_info now contains the property */ - /* first get the unmangeld name if necessary, - then check whether the property is already there */ + * then check whether the property is already there + */ if ((property_info->flags & ZEND_ACC_PPP_MASK) == ZEND_ACC_PUBLIC) { prop_hash = property_info->h; prop_name = property_info->name; @@ -3965,7 +3955,7 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { } } } - +/* }}} */ ZEND_API void zend_do_bind_traits(zend_class_entry *ce TSRMLS_DC) /* {{{ */ { @@ -4096,26 +4086,6 @@ void zend_prepare_trait_alias(znode *result, znode *method_reference, znode *mod } /* }}} */ -/*void init_trait_alias(znode* result, const znode* method_name, const znode* alias, const znode* modifiers TSRMLS_DC)*/ /* {{{ */ -/*{ - zend_trait_alias* trait_alias = emalloc(sizeof(zend_trait_alias)); - trait_alias->method_name = Z_UNIVAL(method_name->u.constant); - - // may be method is only excluded, then the alias node is NULL - if (alias) { - trait_alias->alias = Z_UNIVAL(alias->u.constant); - trait_alias->modifiers = Z_LVAL(modifiers->u.constant); - } else { - - } - trait_alias->function = NULL; - - - result->u.var = trait_alias; -} -*/ -/* }}} */ - void zend_prepare_trait_precedence(znode *result, znode *method_reference, znode *trait_list TSRMLS_DC) /* {{{ */ { zend_trait_precedence *trait_precedence = emalloc(sizeof(zend_trait_precedence)); From 5cb1602aabf74d882d5f69ab1d88c9890701f718 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 9 Jul 2011 12:06:11 +0000 Subject: [PATCH 0282/2394] - Minor optimization and clean up --- Zend/zend_compile.c | 94 ++++++++++++++++++++++----------------------- 1 file changed, 46 insertions(+), 48 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index b392df3242147..3fd38ae717f52 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3394,7 +3394,6 @@ static int zend_traits_merge_functions(zend_function *fn TSRMLS_DC, int num_args zend_class_entry *ce; size_t collision = 0; size_t abstract_solved = 0; - /* unsigned int name_len; */ zend_function* other_trait_fn; current = va_arg(args, size_t); /* index of current trait */ @@ -3432,11 +3431,11 @@ static int zend_traits_merge_functions(zend_function *fn TSRMLS_DC, int num_args if (collision) { zend_function* class_fn; - /* make sure method is not already overridden in class */ + /* make sure method is not already overridden in class */ if (zend_hash_quick_find(&ce->function_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h, (void **)&class_fn) == FAILURE || class_fn->common.scope != ce) { - zend_error(E_COMPILE_ERROR, "Trait method %s has not been applied, because there are collisions with other trait methods on %s", fn->common.function_name, ce->name); + zend_error(E_COMPILE_ERROR, "Trait method %s has not been applied, because there are collisions with other trait methods on %s", fn->common.function_name, ce->name); } zend_function_dtor(fn); @@ -3630,11 +3629,9 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, zend_trait_alias** aliases; HashTable* exclude_table; char* lcname; - unsigned int lcname_len; unsigned int fnname_len; zend_function fn_copy; void* dummy; - size_t i = 0; target = va_arg(args, HashTable*); aliases = va_arg(args, zend_trait_alias**); @@ -3646,30 +3643,28 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, if (aliases) { while (aliases[i]) { /* Scope unset or equal to the function we compare to, and the alias applies to fn */ - if ((!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) + if (aliases[i]->alias != NULL + && (!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) + && aliases[i]->trait_method->mname_len == fnname_len && (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, aliases[i]->trait_method->mname_len, fn->common.function_name, fnname_len) == 0)) { - if (aliases[i]->alias) { - fn_copy = *fn; - zend_traits_duplicate_function(&fn_copy, estrndup(aliases[i]->alias, aliases[i]->alias_len) TSRMLS_CC); + fn_copy = *fn; + zend_traits_duplicate_function(&fn_copy, estrndup(aliases[i]->alias, aliases[i]->alias_len) TSRMLS_CC); - /* if it is 0, no modifieres has been changed */ - if (aliases[i]->modifiers) { - fn_copy.common.fn_flags = aliases[i]->modifiers; - if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { - fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; - } - fn_copy.common.fn_flags |= fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK); + /* if it is 0, no modifieres has been changed */ + if (aliases[i]->modifiers) { + fn_copy.common.fn_flags = aliases[i]->modifiers; + if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { + fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; } + fn_copy.common.fn_flags |= fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK); + } - lcname_len = aliases[i]->alias_len; - lcname = zend_str_tolower_dup(aliases[i]->alias, lcname_len); + lcname = zend_str_tolower_dup(aliases[i]->alias, aliases[i]->alias_len); - if (zend_hash_add(target, lcname, lcname_len+1, &fn_copy, sizeof(zend_function), NULL)==FAILURE) { - zend_error(E_COMPILE_ERROR, "Failed to add aliased trait method (%s) to the trait table. There is probably already a trait method with the same name", fn_copy.common.function_name); - } - /* aliases[i]->function = fn_copy; */ - efree(lcname); + if (zend_hash_add(target, lcname, aliases[i]->alias_len+1, &fn_copy, sizeof(zend_function), NULL)==FAILURE) { + zend_error(E_COMPILE_ERROR, "Failed to add aliased trait method (%s) to the trait table. There is probably already a trait method with the same name", fn_copy.common.function_name); } + efree(lcname); } i++; } @@ -3677,7 +3672,7 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, lcname = zend_str_tolower_dup(fn->common.function_name, fnname_len); - if (zend_hash_find(exclude_table, lcname, fnname_len, &dummy) == FAILURE) { + if (exclude_table == NULL || zend_hash_find(exclude_table, lcname, fnname_len, &dummy) == FAILURE) { /* is not in hashtable, thus, function is not to be excluded */ fn_copy = *fn; zend_traits_duplicate_function(&fn_copy, estrndup(fn->common.function_name, fnname_len) TSRMLS_CC); @@ -3688,16 +3683,16 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, i = 0; while (aliases[i]) { /* Scope unset or equal to the function we compare to, and the alias applies to fn */ - if ((!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) + if (aliases[i]->alias == NULL && aliases[i]->modifiers != 0 + && (!aliases[i]->trait_method->ce || fn->common.scope == aliases[i]->trait_method->ce) + && (aliases[i]->trait_method->mname_len == fnname_len) && (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, aliases[i]->trait_method->mname_len, fn->common.function_name, fnname_len) == 0)) { - /* if it is 0, no modifieres has been changed */ - if (!aliases[i]->alias && aliases[i]->modifiers) { - fn_copy.common.fn_flags = aliases[i]->modifiers; - if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { - fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; - } - fn_copy.common.fn_flags |= fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK); + fn_copy.common.fn_flags = aliases[i]->modifiers; + + if (!(aliases[i]->modifiers & ZEND_ACC_PPP_MASK)) { + fn_copy.common.fn_flags |= ZEND_ACC_PUBLIC; } + fn_copy.common.fn_flags |= fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK); } i++; } @@ -3726,24 +3721,21 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* size_t i, j = 0; zend_trait_precedence *cur_precedence; zend_trait_method_reference *cur_method_ref; - zend_class_entry *cur_ce; /* resolve class references */ if (ce->trait_precedences) { i = 0; while ((cur_precedence = ce->trait_precedences[i])) { - cur_ce = zend_fetch_class(cur_precedence->trait_method->class_name, cur_precedence->trait_method->cname_len, ZEND_FETCH_CLASS_TRAIT TSRMLS_CC); - cur_precedence->trait_method->ce = cur_ce; - if (cur_precedence->exclude_from_classes) { + cur_precedence->trait_method->ce = zend_fetch_class(cur_precedence->trait_method->class_name, cur_precedence->trait_method->cname_len, ZEND_FETCH_CLASS_TRAIT TSRMLS_CC); + j = 0; while (cur_precedence->exclude_from_classes[j]) { char* class_name = (char*)cur_precedence->exclude_from_classes[j]; zend_uint name_length = strlen(class_name); - cur_ce = zend_fetch_class(class_name, name_length, ZEND_FETCH_CLASS_TRAIT TSRMLS_CC); + cur_precedence->exclude_from_classes[j] = zend_fetch_class(class_name, name_length, ZEND_FETCH_CLASS_TRAIT TSRMLS_CC); efree(class_name); - cur_precedence->exclude_from_classes[j] = cur_ce; j++; } } @@ -3754,8 +3746,8 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* if (ce->trait_aliases) { i = 0; while (ce->trait_aliases[i]) { - cur_method_ref = ce->trait_aliases[i]->trait_method; - if (cur_method_ref->class_name) { + if (ce->trait_aliases[i]->trait_method->class_name) { + cur_method_ref = ce->trait_aliases[i]->trait_method; cur_method_ref->ce = zend_fetch_class(cur_method_ref->class_name, cur_method_ref->cname_len, ZEND_FETCH_CLASS_TRAIT TSRMLS_CC); } i++; @@ -3778,6 +3770,7 @@ static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_tra if (precedences[i]->exclude_from_classes[j] == trait) { zend_uint lcname_len = precedences[i]->trait_method->mname_len; char *lcname = zend_str_tolower_dup(precedences[i]->trait_method->method_name, lcname_len); + if (zend_hash_add(exclude_table, lcname, lcname_len, NULL, 0, NULL) == FAILURE) { efree(lcname); zend_error(E_COMPILE_ERROR, "Failed to evaluate a trait precedence (%s). Method of trait %s was defined to be excluded multiple times", precedences[i]->trait_method->method_name, trait->name); @@ -3804,19 +3797,24 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ resulting_table = (HashTable *) malloc(sizeof(HashTable)); /* TODO: revisit this start size, may be its not optimal */ - zend_hash_init_ex(resulting_table, 10, NULL, NULL, 0, 0); + zend_hash_init_ex(resulting_table, 10, NULL, NULL, 1, 0); for (i = 0; i < ce->num_traits; i++) { function_tables[i] = (HashTable *) malloc(sizeof(HashTable)); - zend_hash_init_ex(function_tables[i], ce->traits[i]->function_table.nNumOfElements, NULL, NULL, 0, 0); + zend_hash_init_ex(function_tables[i], ce->traits[i]->function_table.nNumOfElements, NULL, NULL, 1, 0); + + if (ce->trait_precedences) { + /* TODO: revisit this start size, may be its not optimal */ + zend_hash_init_ex(&exclude_table, 2, NULL, NULL, 0, 0); - /* TODO: revisit this start size, may be its not optimal */ - zend_hash_init_ex(&exclude_table, 2, NULL, NULL, 0, 0); - zend_traits_compile_exclude_table(&exclude_table, ce->trait_precedences, ce->traits[i]); + zend_traits_compile_exclude_table(&exclude_table, ce->trait_precedences, ce->traits[i]); - /* copies functions, applies defined aliasing, and excludes unused trait methods */ - zend_traits_copy_trait_function_table(function_tables[i], &ce->traits[i]->function_table, ce->trait_aliases, &exclude_table TSRMLS_CC); - zend_hash_graceful_destroy(&exclude_table); + /* copies functions, applies defined aliasing, and excludes unused trait methods */ + zend_traits_copy_trait_function_table(function_tables[i], &ce->traits[i]->function_table, ce->trait_aliases, &exclude_table TSRMLS_CC); + zend_hash_graceful_destroy(&exclude_table); + } else { + zend_traits_copy_trait_function_table(function_tables[i], &ce->traits[i]->function_table, ce->trait_aliases, NULL TSRMLS_CC); + } } /* now merge trait methods */ From 0fe6fd9e89147042137092526f7b1619d2b492b1 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 9 Jul 2011 17:27:59 +0000 Subject: [PATCH 0283/2394] - Changed zend_resolve_class_name() prototype # No needed to pass fetch_type as pointer here --- Zend/zend_compile.c | 29 +++++++++++------------------ Zend/zend_compile.h | 2 +- Zend/zend_language_parser.y | 4 ++-- 3 files changed, 14 insertions(+), 21 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 3fd38ae717f52..c9b1d67308e2a 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -699,9 +699,7 @@ void zend_do_fetch_static_member(znode *result, znode *class_name TSRMLS_DC) /* if (class_name->op_type == IS_CONST && ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_name->u.constant), Z_STRLEN(class_name->u.constant))) { - ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; - - zend_resolve_class_name(class_name, &fetch_type, 1 TSRMLS_CC); + zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); class_node = *class_name; } else { zend_do_fetch_class(&class_node, class_name TSRMLS_CC); @@ -1856,7 +1854,7 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con if (class_type->u.constant.type != IS_NULL) { cur_arg_info->type_hint = IS_OBJECT; if (ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_type->u.constant), Z_STRLEN(class_type->u.constant))) { - zend_resolve_class_name(class_type, &opline->extended_value, 1 TSRMLS_CC); + zend_resolve_class_name(class_type, opline->extended_value, 1 TSRMLS_CC); } class_type->u.constant.value.str.val = zend_new_interned_string(class_type->u.constant.value.str.val, class_type->u.constant.value.str.len + 1, 1 TSRMLS_CC); cur_arg_info->class_name = class_type->u.constant.value.str.val; @@ -2063,7 +2061,7 @@ void zend_resolve_non_class_name(znode *element_name, zend_bool check_namespace } /* }}} */ -void zend_resolve_class_name(znode *class_name, ulong *fetch_type, int check_ns_name TSRMLS_DC) /* {{{ */ +void zend_resolve_class_name(znode *class_name, ulong fetch_type, int check_ns_name TSRMLS_DC) /* {{{ */ { char *compound; char *lcname; @@ -2171,7 +2169,7 @@ void zend_do_fetch_class(znode *result, znode *class_name TSRMLS_DC) /* {{{ */ zval_dtor(&class_name->u.constant); break; default: - zend_resolve_class_name(class_name, &opline->extended_value, 0 TSRMLS_CC); + zend_resolve_class_name(class_name, opline->extended_value, 0 TSRMLS_CC); opline->op2_type = IS_CONST; opline->op2.constant = zend_add_class_name_literal(CG(active_op_array), &class_name->u.constant TSRMLS_CC); @@ -2329,7 +2327,6 @@ int zend_do_begin_class_member_function_call(znode *class_name, znode *method_na znode class_node; unsigned char *ptr = NULL; zend_op *opline; - ulong fetch_type = 0; if (method_name->op_type == IS_CONST) { char *lcname = zend_str_tolower_dup(Z_STRVAL(method_name->u.constant), Z_STRLEN(method_name->u.constant)); @@ -2343,8 +2340,7 @@ int zend_do_begin_class_member_function_call(znode *class_name, znode *method_na if (class_name->op_type == IS_CONST && ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_name->u.constant), Z_STRLEN(class_name->u.constant))) { - fetch_type = ZEND_FETCH_CLASS_GLOBAL; - zend_resolve_class_name(class_name, &fetch_type, 1 TSRMLS_CC); + zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); class_node = *class_name; opline = get_next_op(CG(active_op_array) TSRMLS_CC); } else { @@ -2687,9 +2683,7 @@ void zend_do_begin_catch(znode *try_token, znode *class_name, znode *catch_var, if (class_name->op_type == IS_CONST && ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_name->u.constant), Z_STRLEN(class_name->u.constant))) { - ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; - - zend_resolve_class_name(class_name, &fetch_type, 1 TSRMLS_CC); + zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); catch_class = *class_name; } else { zend_error(E_COMPILE_ERROR, "Bad class name in the catch statement"); @@ -4042,8 +4036,7 @@ void zend_prepare_reference(znode *result, znode *class_name, znode *method_name /* REM: There should not be a need for copying, zend_do_begin_class_declaration is also just using that string */ if (class_name) { - ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; - zend_resolve_class_name(class_name, &fetch_type, 1 TSRMLS_CC); + zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); method_ref->class_name = Z_STRVAL(class_name->u.constant); method_ref->cname_len = Z_STRLEN(class_name->u.constant); } else { @@ -4735,7 +4728,7 @@ void zend_do_implements_interface(znode *interface_name TSRMLS_DC) /* {{{ */ opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_ADD_INTERFACE; SET_NODE(opline->op1, &CG(implementing_class)); - zend_resolve_class_name(interface_name, &opline->extended_value, 0 TSRMLS_CC); + zend_resolve_class_name(interface_name, opline->extended_value, 0 TSRMLS_CC); opline->extended_value = (opline->extended_value & ~ZEND_FETCH_CLASS_MASK) | ZEND_FETCH_CLASS_INTERFACE; opline->op2_type = IS_CONST; opline->op2.constant = zend_add_class_name_literal(CG(active_op_array), &interface_name->u.constant TSRMLS_CC); @@ -4760,7 +4753,7 @@ void zend_do_implements_trait(znode *trait_name TSRMLS_DC) /* {{{ */ opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_ADD_TRAIT; SET_NODE(opline->op1, &CG(implementing_class)); - zend_resolve_class_name(trait_name, &opline->extended_value, 0 TSRMLS_CC); + zend_resolve_class_name(trait_name, opline->extended_value, 0 TSRMLS_CC); opline->extended_value = ZEND_FETCH_CLASS_TRAIT; opline->op2_type = IS_CONST; opline->op2.constant = zend_add_class_name_literal(CG(active_op_array), &trait_name->u.constant TSRMLS_CC); @@ -5109,7 +5102,7 @@ void zend_do_fetch_constant(znode *result, znode *constant_container, znode *con if (ZEND_FETCH_CLASS_STATIC == type) { zend_error(E_ERROR, "\"static::\" is not allowed in compile-time constants"); } else if (ZEND_FETCH_CLASS_DEFAULT == type) { - zend_resolve_class_name(constant_container, &fetch_type, 1 TSRMLS_CC); + zend_resolve_class_name(constant_container, fetch_type, 1 TSRMLS_CC); } zend_do_build_full_name(NULL, constant_container, constant_name, 1 TSRMLS_CC); *result = *constant_container; @@ -5118,7 +5111,7 @@ void zend_do_fetch_constant(znode *result, znode *constant_container, znode *con case ZEND_RT: if (constant_container->op_type == IS_CONST && ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(constant_container->u.constant), Z_STRLEN(constant_container->u.constant))) { - zend_resolve_class_name(constant_container, &fetch_type, 1 TSRMLS_CC); + zend_resolve_class_name(constant_container, fetch_type, 1 TSRMLS_CC); } else { zend_do_fetch_class(&tmp, constant_container TSRMLS_CC); constant_container = &tmp; diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 332b8cb6f7afb..8cb04755238c8 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -414,7 +414,7 @@ ZEND_API int zend_get_compiled_lineno(TSRMLS_D); ZEND_API size_t zend_get_scanned_file_offset(TSRMLS_D); void zend_resolve_non_class_name(znode *element_name, zend_bool check_namespace TSRMLS_DC); -void zend_resolve_class_name(znode *class_name, ulong *fetch_type, int check_ns_name TSRMLS_DC); +void zend_resolve_class_name(znode *class_name, ulong fetch_type, int check_ns_name TSRMLS_DC); ZEND_API char* zend_get_compiled_variable_name(const zend_op_array *op_array, zend_uint var, int* name_len); #ifdef ZTS diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 4dd5bdb977ea5..089209154afca 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -612,8 +612,8 @@ trait_precedence: ; trait_reference_list: - fully_qualified_class_name { ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; zend_resolve_class_name(&$1, &fetch_type, 1 TSRMLS_CC); zend_init_list(&$$.u.op.ptr, Z_STRVAL($1.u.constant) TSRMLS_CC); } - | trait_reference_list ',' fully_qualified_class_name { ulong fetch_type = ZEND_FETCH_CLASS_GLOBAL; zend_resolve_class_name(&$3, &fetch_type, 1 TSRMLS_CC); zend_add_to_list(&$1.u.op.ptr, Z_STRVAL($3.u.constant) TSRMLS_CC); $$ = $1; } + fully_qualified_class_name { zend_resolve_class_name(&$1, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); zend_init_list(&$$.u.op.ptr, Z_STRVAL($1.u.constant) TSRMLS_CC); } + | trait_reference_list ',' fully_qualified_class_name { zend_resolve_class_name(&$3, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); zend_add_to_list(&$1.u.op.ptr, Z_STRVAL($3.u.constant) TSRMLS_CC); $$ = $1; } ; trait_method_reference: From 5d20a8f80193685877ae3c57e676240e6f2384b3 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 10 Jul 2011 02:00:00 +0000 Subject: [PATCH 0284/2394] - Minor optimization, use the computed hash when available --- Zend/zend_API.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 28ac9e9364586..b3ea607361d57 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -2023,10 +2023,18 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio } fname_len = strlen(ptr->fname); lowercase_name = zend_new_interned_string(zend_str_tolower_dup(ptr->fname, fname_len), fname_len + 1, 1 TSRMLS_CC); - if (zend_hash_add(target_function_table, lowercase_name, fname_len+1, &function, sizeof(zend_function), (void**)®_function) == FAILURE) { - unload=1; - str_efree(lowercase_name); - break; + if (IS_INTERNED(lowercase_name)) { + if (zend_hash_quick_add(target_function_table, lowercase_name, fname_len+1, INTERNED_HASH(lowercase_name), &function, sizeof(zend_function), (void**)®_function) == FAILURE) { + unload=1; + str_efree(lowercase_name); + break; + } + } else { + if (zend_hash_add(target_function_table, lowercase_name, fname_len+1, &function, sizeof(zend_function), (void**)®_function) == FAILURE) { + unload=1; + str_efree(lowercase_name); + break; + } } if (scope) { /* Look for ctor, dtor, clone From 6ff1746371e0f9b4f32d58be8da871e906c55057 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 10 Jul 2011 02:20:34 +0000 Subject: [PATCH 0285/2394] - update libpng to 1.2.45 --- win32/build/libs_version.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/win32/build/libs_version.txt b/win32/build/libs_version.txt index 8221e190ba84d..2dd6933dae99c 100644 --- a/win32/build/libs_version.txt +++ b/win32/build/libs_version.txt @@ -1 +1,2 @@ libcurl-7.21.6 +libpng-1.2.45 From 17a7fd065648305b2b3be8687fe75ed728557841 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 10 Jul 2011 12:37:42 +0000 Subject: [PATCH 0286/2394] - Minor optimization taking the computed hash of interned strings --- Zend/zend_API.c | 29 +++++++++++++++-------------- Zend/zend_compile.c | 20 ++++++++++++++++++-- Zend/zend_constants.c | 9 ++++++++- 3 files changed, 41 insertions(+), 17 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index b3ea607361d57..cacfcfb9ff24d 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -1917,7 +1917,7 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio const zend_function_entry *ptr = functions; zend_function function, *reg_function; zend_internal_function *internal_function = (zend_internal_function *)&function; - int count=0, unload=0; + int count=0, unload=0, result=0; HashTable *target_function_table = function_table; int error_type; zend_function *ctor = NULL, *dtor = NULL, *clone = NULL, *__get = NULL, *__set = NULL, *__unset = NULL, *__isset = NULL, *__call = NULL, *__callstatic = NULL, *__tostring = NULL; @@ -2024,24 +2024,21 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio fname_len = strlen(ptr->fname); lowercase_name = zend_new_interned_string(zend_str_tolower_dup(ptr->fname, fname_len), fname_len + 1, 1 TSRMLS_CC); if (IS_INTERNED(lowercase_name)) { - if (zend_hash_quick_add(target_function_table, lowercase_name, fname_len+1, INTERNED_HASH(lowercase_name), &function, sizeof(zend_function), (void**)®_function) == FAILURE) { - unload=1; - str_efree(lowercase_name); - break; - } - } else { - if (zend_hash_add(target_function_table, lowercase_name, fname_len+1, &function, sizeof(zend_function), (void**)®_function) == FAILURE) { - unload=1; - str_efree(lowercase_name); - break; - } + result = zend_hash_quick_add(target_function_table, lowercase_name, fname_len+1, INTERNED_HASH(lowercase_name), &function, sizeof(zend_function), (void**)®_function); + } else { + result = zend_hash_add(target_function_table, lowercase_name, fname_len+1, &function, sizeof(zend_function), (void**)®_function); + } + if (result == FAILURE) { + unload=1; + str_efree(lowercase_name); + break; } if (scope) { /* Look for ctor, dtor, clone * If it's an old-style constructor, store it only if we don't have * a constructor already. */ - if ((fname_len == class_name_len) && !memcmp(lowercase_name, lc_class_name, class_name_len+1) && !ctor) { + if ((fname_len == class_name_len) && !ctor && !memcmp(lowercase_name, lc_class_name, class_name_len+1)) { ctor = reg_function; } else if ((fname_len == sizeof(ZEND_CONSTRUCTOR_FUNC_NAME)-1) && !memcmp(lowercase_name, ZEND_CONSTRUCTOR_FUNC_NAME, sizeof(ZEND_CONSTRUCTOR_FUNC_NAME))) { ctor = reg_function; @@ -2395,7 +2392,11 @@ static zend_class_entry *do_register_internal_class(zend_class_entry *orig_class zend_str_tolower_copy(lowercase_name, orig_class_entry->name, class_entry->name_length); lowercase_name = zend_new_interned_string(lowercase_name, class_entry->name_length + 1, 1 TSRMLS_CC); - zend_hash_update(CG(class_table), lowercase_name, class_entry->name_length+1, &class_entry, sizeof(zend_class_entry *), NULL); + if (IS_INTERNED(lowercase_name)) { + zend_hash_quick_update(CG(class_table), lowercase_name, class_entry->name_length+1, INTERNED_HASH(lowercase_name), &class_entry, sizeof(zend_class_entry *), NULL); + } else { + zend_hash_update(CG(class_table), lowercase_name, class_entry->name_length+1, &class_entry, sizeof(zend_class_entry *), NULL); + } str_efree(lowercase_name); return class_entry; } diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index c9b1d67308e2a..dea887dfef397 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -1543,9 +1543,16 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n op_array.line_start = zend_get_compiled_lineno(TSRMLS_C); if (is_method) { + int result; + lcname = zend_new_interned_string(zend_str_tolower_dup(name, name_len), name_len + 1, 1 TSRMLS_CC); - if (zend_hash_add(&CG(active_class_entry)->function_table, lcname, name_len+1, &op_array, sizeof(zend_op_array), (void **) &CG(active_op_array)) == FAILURE) { + if (IS_INTERNED(lcname)) { + result = zend_hash_quick_add(&CG(active_class_entry)->function_table, lcname, name_len+1, INTERNED_HASH(lcname), &op_array, sizeof(zend_op_array), (void **) &CG(active_op_array)); + } else { + result = zend_hash_add(&CG(active_class_entry)->function_table, lcname, name_len+1, &op_array, sizeof(zend_op_array), (void **) &CG(active_op_array)); + } + if (result == FAILURE) { zend_error(E_COMPILE_ERROR, "Cannot redeclare %s::%s()", CG(active_class_entry)->name, name); } @@ -4860,6 +4867,8 @@ void zend_do_declare_property(const znode *var_name, const znode *value, zend_ui void zend_do_declare_class_constant(znode *var_name, const znode *value TSRMLS_DC) /* {{{ */ { zval *property; + char *cname = NULL; + int result; if(Z_TYPE(value->u.constant) == IS_CONSTANT_ARRAY) { zend_error(E_COMPILE_ERROR, "Arrays are not allowed in class constants"); @@ -4872,8 +4881,15 @@ void zend_do_declare_class_constant(znode *var_name, const znode *value TSRMLS_D ALLOC_ZVAL(property); *property = value->u.constant; + + cname = zend_new_interned_string(var_name->u.constant.value.str.val, var_name->u.constant.value.str.len+1, 0 TSRMLS_CC); - if (zend_hash_add(&CG(active_class_entry)->constants_table, zend_new_interned_string(var_name->u.constant.value.str.val, var_name->u.constant.value.str.len+1, 0 TSRMLS_CC), var_name->u.constant.value.str.len+1, &property, sizeof(zval *), NULL)==FAILURE) { + if (IS_INTERNED(cname)) { + result = zend_hash_quick_add(&CG(active_class_entry)->constants_table, cname, var_name->u.constant.value.str.len+1, INTERNED_HASH(cname), &property, sizeof(zval *), NULL); + } else { + result = zend_hash_add(&CG(active_class_entry)->constants_table, cname, var_name->u.constant.value.str.len+1, &property, sizeof(zval *), NULL); + } + if (result == FAILURE) { FREE_ZVAL(property); zend_error(E_COMPILE_ERROR, "Cannot redefine class constant %s::%s", CG(active_class_entry)->name, var_name->u.constant.value.str.val); } diff --git a/Zend/zend_constants.c b/Zend/zend_constants.c index b6957957208d1..58cc495ebbf8b 100644 --- a/Zend/zend_constants.c +++ b/Zend/zend_constants.c @@ -452,6 +452,7 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC) char *lowercase_name = NULL; char *name; int ret = SUCCESS; + ulong chash = 0; #if 0 printf("Registering constant for module %d\n", c->module_number); @@ -463,6 +464,7 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC) zend_str_tolower(lowercase_name, c->name_len-1); lowercase_name = zend_new_interned_string(lowercase_name, c->name_len, 1 TSRMLS_CC); name = lowercase_name; + chash = IS_INTERNED(lowercase_name) ? INTERNED_HASH(lowercase_name) : 0; } else { char *slash = strrchr(c->name, '\\'); if(slash) { @@ -470,15 +472,20 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC) zend_str_tolower(lowercase_name, slash-c->name); lowercase_name = zend_new_interned_string(lowercase_name, c->name_len, 1 TSRMLS_CC); name = lowercase_name; + + chash = IS_INTERNED(lowercase_name) ? INTERNED_HASH(lowercase_name) : 0; } else { name = c->name; } } + if (chash == 0) { + chash = zend_hash_func(name, c->name_len); + } /* Check if the user is trying to define the internal pseudo constant name __COMPILER_HALT_OFFSET__ */ if ((c->name_len == sizeof("__COMPILER_HALT_OFFSET__") && !memcmp(name, "__COMPILER_HALT_OFFSET__", sizeof("__COMPILER_HALT_OFFSET__")-1)) - || zend_hash_add(EG(zend_constants), name, c->name_len, (void *) c, sizeof(zend_constant), NULL)==FAILURE) { + || zend_hash_quick_add(EG(zend_constants), name, c->name_len, chash, (void *) c, sizeof(zend_constant), NULL)==FAILURE) { /* The internal __COMPILER_HALT_OFFSET__ is prefixed by NULL byte */ if (c->name[0] == '\0' && c->name_len > sizeof("\0__COMPILER_HALT_OFFSET__") From 31a69cd480377567c976277a39a516ba0e24b057 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 10 Jul 2011 13:05:32 +0000 Subject: [PATCH 0287/2394] - Year++ --- Zend/zend_vm_execute.h | 2 +- Zend/zend_vm_gen.php | 4 ++-- Zend/zend_vm_opcodes.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 569254dcf18e3..99a939644b65c 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2010 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2011 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm_gen.php b/Zend/zend_vm_gen.php index 692279595d019..850cc59670ec4 100644 --- a/Zend/zend_vm_gen.php +++ b/Zend/zend_vm_gen.php @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2010 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2011 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | @@ -24,7 +24,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2010 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2011 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 4cd1ac43466a3..ed80ddc7a5142 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2010 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2011 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | From b8dd53b713a6528259e9936000639838611a60b5 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 10 Jul 2011 14:19:51 +0000 Subject: [PATCH 0288/2394] - use warning here to match unix behavior --- ext/mcrypt/mcrypt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c index 0d1ad3b850705..609dac1d5fb21 100644 --- a/ext/mcrypt/mcrypt.c +++ b/ext/mcrypt/mcrypt.c @@ -1394,7 +1394,7 @@ PHP_FUNCTION(mcrypt_create_iv) BYTE *iv_b = (BYTE *) iv; if (php_win32_get_random_bytes(iv_b, (size_t) size) == FAILURE){ efree(iv); - php_error_docref(NULL TSRMLS_CC, E_ERROR, "Could not gather sufficient random data"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not gather sufficient random data"); RETURN_FALSE; } n = size; From 04432e7dd85d774a3eac6f3effca9f4e7cfb42d6 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 10 Jul 2011 14:36:32 +0000 Subject: [PATCH 0289/2394] - fix bug #55169, mcrypt_create_iv always fails to gather sufficient random data --- win32/winutil.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/win32/winutil.c b/win32/winutil.c index dae01584a94e2..f3043f50aae12 100644 --- a/win32/winutil.c +++ b/win32/winutil.c @@ -87,7 +87,7 @@ PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{ #endif if (has_crypto_ctx == 0) { - if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_MACHINE_KEYSET)) { + if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, 0)) { /* Could mean that the key container does not exist, let try again by asking for a new one */ if (GetLastError() == NTE_BAD_KEYSET) { @@ -97,6 +97,8 @@ PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{ has_crypto_ctx = 0; } } + } else { + has_crypto_ctx = 1; } } From 8278f831a5a596b7b2c9f66709a1c927eae42296 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 10 Jul 2011 14:59:33 +0000 Subject: [PATCH 0290/2394] - use php_win32_get_random_bytes instead of over slow and partially wrong openssl's version --- ext/openssl/openssl.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index a36a523bff088..5f7650d7d2724 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -4920,10 +4920,19 @@ PHP_FUNCTION(openssl_random_pseudo_bytes) buffer = emalloc(buffer_length + 1); +#ifdef PHP_WIN32 + strong_result = 1; + /* random/urandom equivalent on Windows */ + if (php_win32_get_random_bytes(buffer, (size_t) buffer_length) == FAILURE){ + efree(buffer); + RETURN_FALSE; + } +#else if ((strong_result = RAND_pseudo_bytes(buffer, buffer_length)) < 0) { efree(buffer); RETURN_FALSE; } +#endif buffer[buffer_length] = 0; RETVAL_STRINGL((char *)buffer, buffer_length, 0); From 62e4cfc2d0d7bb56fe4940adb78eb96a2c389ac2 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 10 Jul 2011 15:03:38 +0000 Subject: [PATCH 0291/2394] - Added zend_is_auto_global_quick function --- Zend/zend_compile.c | 17 ++++++++++++----- Zend/zend_compile.h | 1 + 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index dea887dfef397..37cdde52b7305 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -640,7 +640,7 @@ void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar } else if (IS_INTERNED(Z_STRVAL(varname->u.constant))) { hash = INTERNED_HASH(Z_STRVAL(varname->u.constant)); } - if (!zend_is_auto_global(varname->u.constant.value.str.val, varname->u.constant.value.str.len TSRMLS_CC) && + if (!zend_is_auto_global_quick(varname->u.constant.value.str.val, varname->u.constant.value.str.len, hash TSRMLS_CC) && !(varname->u.constant.value.str.len == (sizeof("this")-1) && !memcmp(varname->u.constant.value.str.val, "this", sizeof("this"))) && (CG(active_op_array)->last == 0 || @@ -670,7 +670,7 @@ void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar if (varname->op_type == IS_CONST) { CALCULATE_LITERAL_HASH(opline_ptr->op1.constant); - if (zend_is_auto_global(varname->u.constant.value.str.val, varname->u.constant.value.str.len TSRMLS_CC)) { + if (zend_is_auto_global_quick(varname->u.constant.value.str.val, varname->u.constant.value.str.len, Z_HASH_P(&CONSTANT(opline_ptr->op1.constant)) TSRMLS_CC)) { opline_ptr->extended_value = ZEND_FETCH_GLOBAL; } } @@ -1816,7 +1816,7 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con return; } - if (zend_is_auto_global(Z_STRVAL(varname->u.constant), Z_STRLEN(varname->u.constant) TSRMLS_CC)) { + if (zend_is_auto_global_quick(Z_STRVAL(varname->u.constant), Z_STRLEN(varname->u.constant), 0 TSRMLS_CC)) { zend_error(E_COMPILE_ERROR, "Cannot re-assign auto-global variable %s", Z_STRVAL(varname->u.constant)); } else { var.op_type = IS_CV; @@ -6182,11 +6182,12 @@ void zend_do_ticks(TSRMLS_D) /* {{{ */ } /* }}} */ -zend_bool zend_is_auto_global(const char *name, uint name_len TSRMLS_DC) /* {{{ */ +zend_bool zend_is_auto_global_quick(const char *name, uint name_len, ulong hashval TSRMLS_DC) /* {{{ */ { zend_auto_global *auto_global; + ulong hash = hashval ? hashval : zend_hash_func(name, name_len+1); - if (zend_hash_find(CG(auto_globals), name, name_len+1, (void **) &auto_global)==SUCCESS) { + if (zend_hash_quick_find(CG(auto_globals), name, name_len+1, hash, (void **) &auto_global)==SUCCESS) { if (auto_global->armed) { auto_global->armed = auto_global->auto_global_callback(auto_global->name, auto_global->name_len TSRMLS_CC); } @@ -6196,6 +6197,12 @@ zend_bool zend_is_auto_global(const char *name, uint name_len TSRMLS_DC) /* {{{ } /* }}} */ +zend_bool zend_is_auto_global(const char *name, uint name_len TSRMLS_DC) /* {{{ */ +{ + return zend_is_auto_global_quick(name, name_len, 0 TSRMLS_CC); +} +/* }}} */ + int zend_register_auto_global(const char *name, uint name_len, zend_bool jit, zend_auto_global_callback auto_global_callback TSRMLS_DC) /* {{{ */ { zend_auto_global auto_global; diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 8cb04755238c8..a3802e469d197 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -682,6 +682,7 @@ typedef struct _zend_auto_global { ZEND_API int zend_register_auto_global(const char *name, uint name_len, zend_bool jit, zend_auto_global_callback auto_global_callback TSRMLS_DC); ZEND_API void zend_activate_auto_globals(TSRMLS_D); ZEND_API zend_bool zend_is_auto_global(const char *name, uint name_len TSRMLS_DC); +ZEND_API zend_bool zend_is_auto_global_quick(const char *name, uint name_len, ulong hashval TSRMLS_DC); ZEND_API size_t zend_dirname(char *path, size_t len); int zendlex(znode *zendlval TSRMLS_DC); From fb6440b4f13cc3281d37141ca8796d73369682be Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 11 Jul 2011 07:10:30 +0000 Subject: [PATCH 0292/2394] Fixed bug #55150 (php -a segfaults) --- Zend/zend_compile.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 37cdde52b7305..06bdf36fea128 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -70,6 +70,10 @@ #define GET_CACHE_SLOT(literal) do { \ CG(active_op_array)->literals[literal].cache_slot = CG(active_op_array)->last_cache_slot++; \ + if ((CG(active_op_array)->fn_flags & ZEND_ACC_INTERACTIVE) && CG(active_op_array)->run_time_cache) { \ + CG(active_op_array)->run_time_cache = erealloc(CG(active_op_array)->run_time_cache, CG(active_op_array)->last_cache_slot * sizeof(void*)); \ + CG(active_op_array)->run_time_cache[CG(active_op_array)->last_cache_slot - 1] = NULL; \ + } \ } while (0) #define POLYMORPHIC_CACHE_SLOT_SIZE 2 @@ -77,6 +81,11 @@ #define GET_POLYMORPHIC_CACHE_SLOT(literal) do { \ CG(active_op_array)->literals[literal].cache_slot = CG(active_op_array)->last_cache_slot; \ CG(active_op_array)->last_cache_slot += POLYMORPHIC_CACHE_SLOT_SIZE; \ + if ((CG(active_op_array)->fn_flags & ZEND_ACC_INTERACTIVE) && CG(active_op_array)->run_time_cache) { \ + CG(active_op_array)->run_time_cache = erealloc(CG(active_op_array)->run_time_cache, CG(active_op_array)->last_cache_slot * sizeof(void*)); \ + CG(active_op_array)->run_time_cache[CG(active_op_array)->last_cache_slot - 1] = NULL; \ + CG(active_op_array)->run_time_cache[CG(active_op_array)->last_cache_slot - 2] = NULL; \ + } \ } while (0) #define FREE_POLYMORPHIC_CACHE_SLOT(literal) do { \ From 1ca51e87eaa5af76e8bdf599dca767e41f5331ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Mon, 11 Jul 2011 08:29:39 +0000 Subject: [PATCH 0293/2394] - Further fix for bug #55111 (compilation failure of ext/sockets in Mac OS X). --- ext/sockets/multicast.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index 49e9c5cf730e9..a9d1ea11eea07 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -423,8 +423,8 @@ int php_if_index_to_addr4(unsigned if_index, php_socket *php_sock, struct in_add #define ifr_ifindex ifr_index #endif - if_req.ifr_ifindex = if_index; #if defined(SIOCGIFNAME) + if_req.ifr_ifindex = if_index; if (ioctl(php_sock->bsd_socket, SIOCGIFNAME, &if_req) == -1) { #elif defined(HAVE_IF_INDEXTONAME) if (if_indextoname(if_index, if_req.ifr_name) == NULL) { @@ -503,14 +503,25 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i if ((((struct sockaddr*)&cur_req->ifr_addr)->sa_family == AF_INET) && (((struct sockaddr_in*)&cur_req->ifr_addr)->sin_addr.s_addr == addr->s_addr)) { +#if defined(SIOCGIFINDEX) if (ioctl(php_sock->bsd_socket, SIOCGIFINDEX, (char*)cur_req) == -1) { +#elif defined(HAVE_IF_NAMETOINDEX) + unsigned index_tmp; + if ((index_tmp = if_nametoindex(cur_req->ifr_name)) == 0) { +#else +#error Neither SIOCGIFINDEX nor if_nametoindex are available +#endif php_error_docref(NULL TSRMLS_CC, E_WARNING, "Error converting interface name to index: error %d", errno); goto err; } else { +#if defined(SIOCGIFINDEX) *if_index = cur_req->ifr_ifindex; +#else + *if_index = index_tmp; +#endif efree(buf); return SUCCESS; } From 8171e1d81e14ff881e27ba0dc8dd67dad1d0ea05 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 11 Jul 2011 09:47:59 +0000 Subject: [PATCH 0294/2394] Fixed bug #54332 (Crash in zend_mm_check_ptr // Heap corruption) --- ext/standard/tests/strings/bug54332.phpt | 8 ++++++++ main/snprintf.c | 5 ++++- main/spprintf.c | 5 ++++- 3 files changed, 16 insertions(+), 2 deletions(-) create mode 100644 ext/standard/tests/strings/bug54332.phpt diff --git a/ext/standard/tests/strings/bug54332.phpt b/ext/standard/tests/strings/bug54332.phpt new file mode 100644 index 0000000000000..122b387ec5fab --- /dev/null +++ b/ext/standard/tests/strings/bug54332.phpt @@ -0,0 +1,8 @@ +--TEST-- +Bug #54332 (Crash in zend_mm_check_ptr // Heap corruption) +--FILE-- + +--EXPECT-- +1 000 000 000 000 000 052 504 760 255 204 420 248 704 468 581 108 159 154 915 854 115 511 802 457 988 908 195 786 371 375 080 447 864 043 704 443 832 883 878 176 942 523 235 360 430 575 644 792 184 786 706 982 848 387 200 926 575 803 737 830 233 794 788 090 059 368 953 234 970 799 945 081 119 038 967 640 880 074 652 742 780 142 494 579 258 788 820 056 842 838 115 669 472 196 386 865 459 400 540 16000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 diff --git a/main/snprintf.c b/main/snprintf.c index a1b253cfdaef2..6e5a89a34cbd1 100644 --- a/main/snprintf.c +++ b/main/snprintf.c @@ -497,8 +497,11 @@ char * ap_php_conv_p2(register u_wide_int num, register int nbits, char format, * NUM_BUF_SIZE is the size of the buffer used for arithmetic conversions * * XXX: this is a magic number; do not decrease it + * Emax = 1023 + * NDIG = 320 + * NUM_BUF_SIZE >= strlen("-") + Emax + strlrn(".") + NDIG + strlen("E+1023") + 1; */ -#define NUM_BUF_SIZE 512 +#define NUM_BUF_SIZE 2048 /* diff --git a/main/spprintf.c b/main/spprintf.c index 8c90fda3780c5..8599d890eed24 100644 --- a/main/spprintf.c +++ b/main/spprintf.c @@ -119,8 +119,11 @@ * NUM_BUF_SIZE is the size of the buffer used for arithmetic conversions * * XXX: this is a magic number; do not decrease it + * Emax = 1023 + * NDIG = 320 + * NUM_BUF_SIZE >= strlen("-") + Emax + strlrn(".") + NDIG + strlen("E+1023") + 1; */ -#define NUM_BUF_SIZE 512 +#define NUM_BUF_SIZE 2048 /* * The INS_CHAR macro inserts a character in the buffer. From 0f3e70fe014dd4d40773f01c35b4b6451c76e300 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 11 Jul 2011 10:31:49 +0000 Subject: [PATCH 0295/2394] Fixed bug #54305 (Crash in gc_remove_zval_from_buffer) --- Zend/tests/bug54305.phpt | 22 ++++++++++++++++ Zend/zend_vm_def.h | 14 +++++++--- Zend/zend_vm_execute.h | 56 ++++++++++++++++++++++++++++------------ 3 files changed, 72 insertions(+), 20 deletions(-) create mode 100644 Zend/tests/bug54305.phpt diff --git a/Zend/tests/bug54305.phpt b/Zend/tests/bug54305.phpt new file mode 100644 index 0000000000000..8e85d2be58ec1 --- /dev/null +++ b/Zend/tests/bug54305.phpt @@ -0,0 +1,22 @@ +--TEST-- +Bug #54305 (Crash in gc_remove_zval_from_buffer) +--FILE-- + +--EXPECTF-- +Method [ public method methodWithArgs ] { + @@ %sbug54305.php %d - %d + + - Parameters [2] { + Parameter #0 [ $a ] + Parameter #1 [ $b ] + } +} diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index aad9585a8ff6a..cdc6456282b78 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -982,10 +982,16 @@ ZEND_VM_HANDLER(40, ZEND_ECHO, CONST|TMP|VAR|CV, ANY) if (OP1_TYPE != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && - Z_OBJ_HT_P(z)->get_method != NULL && - zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { - zend_print_variable(&z_copy); - zval_dtor(&z_copy); + Z_OBJ_HT_P(z)->get_method != NULL) { + if (OP1_TYPE == IS_TMP_VAR) { + INIT_PZVAL(z); + } + if (zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { + zend_print_variable(&z_copy); + zval_dtor(&z_copy); + } else { + zend_print_variable(z); + } } else { zend_print_variable(z); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 99a939644b65c..039d199d47416 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -2012,10 +2012,16 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) if (IS_CONST != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && - Z_OBJ_HT_P(z)->get_method != NULL && - zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { - zend_print_variable(&z_copy); - zval_dtor(&z_copy); + Z_OBJ_HT_P(z)->get_method != NULL) { + if (IS_CONST == IS_TMP_VAR) { + INIT_PZVAL(z); + } + if (zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { + zend_print_variable(&z_copy); + zval_dtor(&z_copy); + } else { + zend_print_variable(z); + } } else { zend_print_variable(z); } @@ -6278,10 +6284,16 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && - Z_OBJ_HT_P(z)->get_method != NULL && - zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { - zend_print_variable(&z_copy); - zval_dtor(&z_copy); + Z_OBJ_HT_P(z)->get_method != NULL) { + if (IS_TMP_VAR == IS_TMP_VAR) { + INIT_PZVAL(z); + } + if (zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { + zend_print_variable(&z_copy); + zval_dtor(&z_copy); + } else { + zend_print_variable(z); + } } else { zend_print_variable(z); } @@ -10455,10 +10467,16 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && - Z_OBJ_HT_P(z)->get_method != NULL && - zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { - zend_print_variable(&z_copy); - zval_dtor(&z_copy); + Z_OBJ_HT_P(z)->get_method != NULL) { + if (IS_VAR == IS_TMP_VAR) { + INIT_PZVAL(z); + } + if (zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { + zend_print_variable(&z_copy); + zval_dtor(&z_copy); + } else { + zend_print_variable(z); + } } else { zend_print_variable(z); } @@ -26192,10 +26210,16 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && - Z_OBJ_HT_P(z)->get_method != NULL && - zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { - zend_print_variable(&z_copy); - zval_dtor(&z_copy); + Z_OBJ_HT_P(z)->get_method != NULL) { + if (IS_CV == IS_TMP_VAR) { + INIT_PZVAL(z); + } + if (zend_std_cast_object_tostring(z, &z_copy, IS_STRING TSRMLS_CC) == SUCCESS) { + zend_print_variable(&z_copy); + zval_dtor(&z_copy); + } else { + zend_print_variable(z); + } } else { zend_print_variable(z); } From 0511fa337eac340af49432c56e2c1d19f1d680d9 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Mon, 11 Jul 2011 11:16:22 +0000 Subject: [PATCH 0296/2394] Added XsltProcessor::setSecurityPrefs($options) and getSecurityPrefs() to define forbidden operations within XSLT stylesheets, default is not to enable any write operations from XSLT anymore. Bug #54446 --- NEWS | 5 +++ UPGRADING | 3 ++ ext/xsl/php_xsl.c | 8 ++++ ext/xsl/php_xsl.h | 9 +++++ ext/xsl/xsl_fe.h | 3 ++ ext/xsl/xsltprocessor.c | 82 +++++++++++++++++++++++++++++++++++++++++ 6 files changed, 110 insertions(+) diff --git a/NEWS b/NEWS index 99b272d5b1328..3ee3bdd85fe4b 100644 --- a/NEWS +++ b/NEWS @@ -203,6 +203,11 @@ PHP NEWS . Added SplObjectStorage::getHash() hook. (Etienne) . Added CallbackFilterIterator and RecursiveCallbackFilterIterator (Arnaud) +- Improved XSL extension: + . Added XsltProcessor::setSecurityPrefs($options) and getSecurityPrefs() to + define forbidden operations within XSLT stylesheets, default is not to + enable any write operations from XSLT anymore. Bug #54446 + - Improved ZLIB extension: . Re-implemented non-file related functionality. (Mike) diff --git a/UPGRADING b/UPGRADING index 0d849a15e5a0f..534e8bf5b7c12 100755 --- a/UPGRADING +++ b/UPGRADING @@ -174,6 +174,9 @@ UPGRADE NOTES - PHP X.Y just the first matching node. - All SimpleXMLElement children are now always printed when using var_dump(), var_export(), and print_r(). +- Write operations within XSLT (for example with the extension sax:output) are + disabled by default. You can define what is forbidden with the method + XsltProcess::setSecurityPrefs($options) =================================== 5. Changes made to existing methods diff --git a/ext/xsl/php_xsl.c b/ext/xsl/php_xsl.c index 90f45be280dc1..13ed910b5d454 100644 --- a/ext/xsl/php_xsl.c +++ b/ext/xsl/php_xsl.c @@ -126,6 +126,7 @@ zend_object_value xsl_objects_new(zend_class_entry *class_type TSRMLS_DC) intern->node_list = NULL; intern->doc = NULL; intern->profiling = NULL; + intern->securityPrefs = XSL_SECPREF_WRITE_FILE | XSL_SECPREF_WRITE_NETWORK | XSL_SECPREF_CREATE_DIRECTORY; zend_object_std_init(&intern->std, class_type TSRMLS_CC); object_properties_init(&intern->std, class_type); @@ -166,6 +167,13 @@ PHP_MINIT_FUNCTION(xsl) REGISTER_LONG_CONSTANT("XSL_CLONE_NEVER", -1, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("XSL_CLONE_ALWAYS", 1, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("XSL_SECPREF_NONE", XSL_SECPREF_NONE, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("XSL_SECPREF_READ_FILE", XSL_SECPREF_READ_FILE, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("XSL_SECPREF_WRITE_FILE", XSL_SECPREF_WRITE_FILE, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("XSL_SECPREF_CREATE_DIRECTORY", XSL_SECPREF_CREATE_DIRECTORY, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("XSL_SECPREF_READ_NETWORK", XSL_SECPREF_READ_NETWORK, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("XSL_SECPREF_WRITE_NETWORK", XSL_SECPREF_WRITE_NETWORK, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("LIBXSLT_VERSION", LIBXSLT_VERSION, CONST_CS | CONST_PERSISTENT); REGISTER_STRING_CONSTANT("LIBXSLT_DOTTED_VERSION", LIBXSLT_DOTTED_VERSION, CONST_CS | CONST_PERSISTENT); diff --git a/ext/xsl/php_xsl.h b/ext/xsl/php_xsl.h index 5d1ffa5c3fdb5..8782077413a36 100644 --- a/ext/xsl/php_xsl.h +++ b/ext/xsl/php_xsl.h @@ -32,6 +32,7 @@ extern zend_module_entry xsl_module_entry; #include #include #include +#include #if HAVE_XSL_EXSLT #include #include @@ -43,6 +44,13 @@ extern zend_module_entry xsl_module_entry; #include #include +#define XSL_SECPREF_NONE 0 +#define XSL_SECPREF_READ_FILE 2 +#define XSL_SECPREF_WRITE_FILE 4 +#define XSL_SECPREF_CREATE_DIRECTORY 8 +#define XSL_SECPREF_READ_NETWORK 16 +#define XSL_SECPREF_WRITE_NETWORK 32 + typedef struct _xsl_object { zend_object std; void *ptr; @@ -55,6 +63,7 @@ typedef struct _xsl_object { HashTable *node_list; php_libxml_node_object *doc; char *profiling; + long securityPrefs; } xsl_object; void php_xsl_set_object(zval *wrapper, void *obj TSRMLS_DC); diff --git a/ext/xsl/xsl_fe.h b/ext/xsl/xsl_fe.h index f6bc1f5ae00a8..a9fb16b2b20bb 100644 --- a/ext/xsl/xsl_fe.h +++ b/ext/xsl/xsl_fe.h @@ -34,6 +34,9 @@ PHP_FUNCTION(xsl_xsltprocessor_remove_parameter); PHP_FUNCTION(xsl_xsltprocessor_has_exslt_support); PHP_FUNCTION(xsl_xsltprocessor_register_php_functions); PHP_FUNCTION(xsl_xsltprocessor_set_profiling); +PHP_FUNCTION(xsl_xsltprocessor_set_security_prefs); +PHP_FUNCTION(xsl_xsltprocessor_get_security_prefs); + #endif /* diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 8cb341516700a..4d27b9cbf1c06 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -71,6 +71,13 @@ ZEND_END_ARG_INFO(); ZEND_BEGIN_ARG_INFO_EX(arginfo_xsl_xsltprocessor_set_profiling, 0, 0, 1) ZEND_ARG_INFO(0, filename) ZEND_END_ARG_INFO(); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_xsl_xsltprocessor_set_security_prefs, 0, 0, 1) + ZEND_ARG_INFO(0, securityPrefs) +ZEND_END_ARG_INFO(); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_xsl_xsltprocessor_get_security_prefs, 0, 0, 0) +ZEND_END_ARG_INFO(); /* }}} */ /* @@ -91,6 +98,8 @@ const zend_function_entry php_xsl_xsltprocessor_class_functions[] = { PHP_FALIAS(hasExsltSupport, xsl_xsltprocessor_has_exslt_support, arginfo_xsl_xsltprocessor_has_exslt_support) PHP_FALIAS(registerPHPFunctions, xsl_xsltprocessor_register_php_functions, arginfo_xsl_xsltprocessor_register_php_functions) PHP_FALIAS(setProfiling, xsl_xsltprocessor_set_profiling, arginfo_xsl_xsltprocessor_set_profiling) + PHP_FALIAS(setSecurityPrefs, xsl_xsltprocessor_set_security_prefs, arginfo_xsl_xsltprocessor_set_security_prefs) + PHP_FALIAS(getSecurityPrefs, xsl_xsltprocessor_get_security_prefs, arginfo_xsl_xsltprocessor_get_security_prefs) {NULL, NULL, NULL} }; @@ -531,11 +540,46 @@ static xmlDocPtr php_xsl_apply_stylesheet(zval *id, xsl_object *intern, xsltStyl } efree(member); + /* Add security checks */ + /* XSLT_SECPREF_READ_FILE and XSLT_SECPREF_READ_NETWORK aren't needed */ + + xsltSecurityPrefsPtr secPrefs = xsltNewSecurityPrefs(); + + if (intern->securityPrefs & XSL_SECPREF_READ_FILE ) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_READ_FILE, xsltSecurityForbid)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + } + } + if (intern->securityPrefs & XSL_SECPREF_WRITE_FILE ) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_WRITE_FILE, xsltSecurityForbid)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + } + } + if (intern->securityPrefs & XSL_SECPREF_CREATE_DIRECTORY ) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_CREATE_DIRECTORY, xsltSecurityForbid)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + } + } + if (intern->securityPrefs & XSL_SECPREF_READ_NETWORK) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_READ_NETWORK, xsltSecurityForbid)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + } + } + if (intern->securityPrefs & XSL_SECPREF_WRITE_NETWORK) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_WRITE_NETWORK, xsltSecurityForbid)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + } + } + + if (0 != xsltSetCtxtSecurityPrefs(secPrefs, ctxt)) + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security handler"); + newdocp = xsltApplyStylesheetUser(style, doc, (const char**) params, NULL, f, ctxt); if (f) { fclose(f); } xsltFreeTransformContext(ctxt); + xsltFreeSecurityPrefs(secPrefs); if (intern->node_list != NULL) { zend_hash_destroy(intern->node_list); @@ -857,6 +901,44 @@ PHP_FUNCTION(xsl_xsltprocessor_set_profiling) } /* }}} end xsl_xsltprocessor_set_profiling */ +/* {{{ proto long xsl_xsltprocessor_set_security_prefs(long securityPrefs) */ +PHP_FUNCTION(xsl_xsltprocessor_set_security_prefs) +{ + zval *id; + xsl_object *intern; + DOM_GET_THIS(id); + long securityPrefs, oldSecurityPrefs; + + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "l", &securityPrefs) == SUCCESS) { + intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); + oldSecurityPrefs = intern->securityPrefs; + intern->securityPrefs = securityPrefs; + RETURN_LONG(oldSecurityPrefs); + } else { + WRONG_PARAM_COUNT; + } +} +/* }}} end xsl_xsltprocessor_set_security_prefs */ + +/* {{{ proto long xsl_xsltprocessor_get_security_prefs() */ +PHP_FUNCTION(xsl_xsltprocessor_get_security_prefs) +{ + zval *id; + xsl_object *intern; + DOM_GET_THIS(id); + long securityPrefs; + + if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "") == SUCCESS) { + intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); + RETURN_LONG(intern->securityPrefs); + } else { + WRONG_PARAM_COUNT; + } +} +/* }}} end xsl_xsltprocessor_get_security_prefs */ + + + /* {{{ proto bool xsl_xsltprocessor_has_exslt_support(); */ PHP_FUNCTION(xsl_xsltprocessor_has_exslt_support) From 0a7aeb7f2844a37619e2fd6f4e2c5b53d62e7ec3 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Mon, 11 Jul 2011 15:02:56 +0000 Subject: [PATCH 0297/2394] Added the ability to pass options to loadHTML (Chregu, fxmulder at gmail dot com) --- NEWS | 3 +++ ext/dom/document.c | 10 ++++++++-- ext/libxml/libxml.c | 10 ++++++++++ 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 3ee3bdd85fe4b..0c7b61f4a9188 100644 --- a/NEWS +++ b/NEWS @@ -140,6 +140,9 @@ PHP NEWS . Added Tokyo Cabinet abstract DB support. (Michael Maclean) . Added Berkeley DB 5 support. (Johannes, Chris Jones) +- Improved DOM extension: + . Added the ability to pass options to loadHTML (Chregu, fxmulder at gmail dot com) + - Improved filesystem functions: . scandir() now accepts SCANDIR_SORT_NONE as a possible sorting_order value. FR #53407. (Adam) diff --git a/ext/dom/document.c b/ext/dom/document.c index e01e2c34d6687..2b11e7f1c43f4 100644 --- a/ext/dom/document.c +++ b/ext/dom/document.c @@ -149,10 +149,12 @@ ZEND_END_ARG_INFO(); ZEND_BEGIN_ARG_INFO_EX(arginfo_dom_document_loadhtml, 0, 0, 1) ZEND_ARG_INFO(0, source) + ZEND_ARG_INFO(0, options) ZEND_END_ARG_INFO(); ZEND_BEGIN_ARG_INFO_EX(arginfo_dom_document_loadhtmlfile, 0, 0, 1) ZEND_ARG_INFO(0, source) + ZEND_ARG_INFO(0, options) ZEND_END_ARG_INFO(); ZEND_BEGIN_ARG_INFO_EX(arginfo_dom_document_savehtml, 0, 0, 0) @@ -2155,12 +2157,12 @@ static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */ dom_object *intern; dom_doc_propsptr doc_prop; char *source; - int source_len, refcount, ret; + int source_len, refcount, ret, options = 0; htmlParserCtxtPtr ctxt; id = getThis(); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &source, &source_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &source, &source_len, &options) == FAILURE) { return; } @@ -2180,6 +2182,10 @@ static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */ RETURN_FALSE; } + if (options) { + htmlCtxtUseOptions(ctxt, options); + } + ctxt->vctxt.error = php_libxml_ctx_error; ctxt->vctxt.warning = php_libxml_ctx_warning; if (ctxt->sax != NULL) { diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index e19075cd263a4..9518e13cc0a88 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -618,6 +618,7 @@ static PHP_MINIT_FUNCTION(libxml) REGISTER_LONG_CONSTANT("LIBXML_NSCLEAN", XML_PARSE_NSCLEAN, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("LIBXML_NOCDATA", XML_PARSE_NOCDATA, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("LIBXML_NONET", XML_PARSE_NONET, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("LIBXML_PEDANTIC", XML_PARSE_PEDANTIC, CONST_CS | CONST_PERSISTENT); #if LIBXML_VERSION >= 20621 REGISTER_LONG_CONSTANT("LIBXML_COMPACT", XML_PARSE_COMPACT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("LIBXML_NOXMLDECL", XML_SAVE_NO_DECL, CONST_CS | CONST_PERSISTENT); @@ -627,6 +628,15 @@ static PHP_MINIT_FUNCTION(libxml) #endif REGISTER_LONG_CONSTANT("LIBXML_NOEMPTYTAG", LIBXML_SAVE_NOEMPTYTAG, CONST_CS | CONST_PERSISTENT); + /* Additional constants for use with loading html */ +#if LIBXML_VERSION >= 20707 + REGISTER_LONG_CONSTANT("LIBXML_HTML_NOIMPLIED", HTML_PARSE_NOIMPLIED, CONST_CS | CONST_PERSISTENT); +#endif + +#if LIBXML_VERSION >= 20708 + REGISTER_LONG_CONSTANT("LIBXML_HTML_NODEFDTD", HTML_PARSE_NODEFDTD, CONST_CS | CONST_PERSISTENT); +#endif + /* Error levels */ REGISTER_LONG_CONSTANT("LIBXML_ERR_NONE", XML_ERR_NONE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("LIBXML_ERR_WARNING", XML_ERR_WARNING, CONST_CS | CONST_PERSISTENT); From 388a473255244b8ff8daac24802dda8abf967f48 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 11 Jul 2011 17:01:23 +0000 Subject: [PATCH 0298/2394] Fixed bug #55014 (Compile failure due to improper use of ctime_r()). --- main/reentrancy.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main/reentrancy.c b/main/reentrancy.c index 5a714273b90ed..b2fe8f117fdea 100644 --- a/main/reentrancy.c +++ b/main/reentrancy.c @@ -60,14 +60,14 @@ static MUTEX_T reentrant_locks[NUMBER_OF_LOCKS]; PHPAPI char *php_ctime_r(const time_t *clock, char *buf) { - if (ctime_r(clock, buf, 26) == buf) + if (ctime_r(clock, buf) == buf) return (buf); return (NULL); } PHPAPI char *php_asctime_r(const struct tm *tm, char *buf) { - if (asctime_r(tm, buf, 26) == buf) + if (asctime_r(tm, buf) == buf) return (buf); return (NULL); } From 513dc26776434f6667c0c2140b8d522133c3e210 Mon Sep 17 00:00:00 2001 From: Kalle Sommer Nielsen Date: Tue, 12 Jul 2011 03:56:32 +0000 Subject: [PATCH 0299/2394] Changed http_response_code() to be able to set a response code --- ext/standard/basic_functions.c | 3 ++- ext/standard/head.c | 22 +++++++++++++++++++--- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 68671c1a9c639..0c7079286cc45 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -1483,7 +1483,8 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO(arginfo_headers_list, 0) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO(arginfo_http_response_code, 0) +ZEND_BEGIN_ARG_INFO_EX(arginfo_http_response_code, 0, 0, 0) + ZEND_ARG_INFO(0, response_code) ZEND_END_ARG_INFO() /* }}} */ /* {{{ html.c */ diff --git a/ext/standard/head.c b/ext/standard/head.c index 2f0ad9e3f68b3..ec5ed95657479 100644 --- a/ext/standard/head.c +++ b/ext/standard/head.c @@ -280,14 +280,30 @@ PHP_FUNCTION(headers_list) } /* }}} */ -/* {{{ proto long http_response_code() - Returns the current HTTP response code */ +/* {{{ proto long http_response_code([int response_code]) + Sets a response code, or returns the current HTTP response code */ PHP_FUNCTION(http_response_code) { - if (zend_parse_parameters_none() == FAILURE) { + long response_code = 0; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &response_code) == FAILURE) { return; } + if (response_code) + { + long old_response_code; + + old_response_code = SG(sapi_headers).http_response_code; + SG(sapi_headers).http_response_code = response_code; + + if (old_response_code) { + RETURN_LONG(old_response_code); + } + + RETURN_TRUE; + } + if (!SG(sapi_headers).http_response_code) { RETURN_FALSE; } From 3f0abb300c33d30022af2040fdbbc57adb3301fd Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 12 Jul 2011 04:45:38 +0000 Subject: [PATCH 0300/2394] MF53 --- sapi/litespeed/lsapi_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sapi/litespeed/lsapi_main.c b/sapi/litespeed/lsapi_main.c index 907afda290ff0..c1684f72f2efb 100644 --- a/sapi/litespeed/lsapi_main.c +++ b/sapi/litespeed/lsapi_main.c @@ -495,6 +495,7 @@ static int cli_main( int argc, char * argv[] ) "implicit_flush", "1", "output_buffering", "0", "max_execution_time", "0", + "max_input_time", "-1", NULL }; From 0c8c69e89b5a408673092ddbfa890036b52b8edc Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Tue, 12 Jul 2011 04:58:38 +0000 Subject: [PATCH 0301/2394] Added XsltProcessor::setSecurityPrefs($options) and getSecurityPrefs() to define forbidden operations within XSLT stylesheets, default is not to enable any write operations from XSLT anymore. Bug #54446 (second iteration of the code for trunk, first commit for 5.4 branch) --- ext/xsl/xsltprocessor.c | 84 ++++++++++++++++++++++------------------- 1 file changed, 46 insertions(+), 38 deletions(-) diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 4d27b9cbf1c06..82a223787ae97 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -484,6 +484,8 @@ static xmlDocPtr php_xsl_apply_stylesheet(zval *id, xsl_object *intern, xsltStyl zval *doXInclude, *member; zend_object_handlers *std_hnd; FILE *f; + int secPrefsError = 0; + xsltSecurityPrefsPtr secPrefs = NULL; node = php_libxml_import_node(docp TSRMLS_CC); @@ -540,46 +542,54 @@ static xmlDocPtr php_xsl_apply_stylesheet(zval *id, xsl_object *intern, xsltStyl } efree(member); - /* Add security checks */ - /* XSLT_SECPREF_READ_FILE and XSLT_SECPREF_READ_NETWORK aren't needed */ - - xsltSecurityPrefsPtr secPrefs = xsltNewSecurityPrefs(); - - if (intern->securityPrefs & XSL_SECPREF_READ_FILE ) { - if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_READ_FILE, xsltSecurityForbid)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + + //if securityPrefs is set to NONE, we don't have to do any checks, but otherwise... + if (intern->securityPrefs != XSL_SECPREF_NONE) { + secPrefs = xsltNewSecurityPrefs(); + if (intern->securityPrefs & XSL_SECPREF_READ_FILE ) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_READ_FILE, xsltSecurityForbid)) { + secPrefsError = 1; + } } - } - if (intern->securityPrefs & XSL_SECPREF_WRITE_FILE ) { - if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_WRITE_FILE, xsltSecurityForbid)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + if (intern->securityPrefs & XSL_SECPREF_WRITE_FILE ) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_WRITE_FILE, xsltSecurityForbid)) { + secPrefsError = 1; + } } - } - if (intern->securityPrefs & XSL_SECPREF_CREATE_DIRECTORY ) { - if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_CREATE_DIRECTORY, xsltSecurityForbid)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + if (intern->securityPrefs & XSL_SECPREF_CREATE_DIRECTORY ) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_CREATE_DIRECTORY, xsltSecurityForbid)) { + secPrefsError = 1; + } } - } - if (intern->securityPrefs & XSL_SECPREF_READ_NETWORK) { - if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_READ_NETWORK, xsltSecurityForbid)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + if (intern->securityPrefs & XSL_SECPREF_READ_NETWORK) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_READ_NETWORK, xsltSecurityForbid)) { + secPrefsError = 1; + } } - } - if (intern->securityPrefs & XSL_SECPREF_WRITE_NETWORK) { - if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_WRITE_NETWORK, xsltSecurityForbid)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties"); + if (intern->securityPrefs & XSL_SECPREF_WRITE_NETWORK) { + if (0 != xsltSetSecurityPrefs(secPrefs, XSLT_SECPREF_WRITE_NETWORK, xsltSecurityForbid)) { + secPrefsError = 1; + } + } + + if (0 != xsltSetCtxtSecurityPrefs(secPrefs, ctxt)) { + secPrefsError = 1; } } - - if (0 != xsltSetCtxtSecurityPrefs(secPrefs, ctxt)) - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security handler"); - - newdocp = xsltApplyStylesheetUser(style, doc, (const char**) params, NULL, f, ctxt); + + if (secPrefsError == 1) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can't set libxslt security properties, not doing transformation for security reasons"); + } else { + newdocp = xsltApplyStylesheetUser(style, doc, (const char**) params, NULL, f, ctxt); + } if (f) { fclose(f); } + xsltFreeTransformContext(ctxt); - xsltFreeSecurityPrefs(secPrefs); + if (secPrefs) { + xsltFreeSecurityPrefs(secPrefs); + } if (intern->node_list != NULL) { zend_hash_destroy(intern->node_list); @@ -908,15 +918,13 @@ PHP_FUNCTION(xsl_xsltprocessor_set_security_prefs) xsl_object *intern; DOM_GET_THIS(id); long securityPrefs, oldSecurityPrefs; - - if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "l", &securityPrefs) == SUCCESS) { - intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); - oldSecurityPrefs = intern->securityPrefs; - intern->securityPrefs = securityPrefs; - RETURN_LONG(oldSecurityPrefs); - } else { - WRONG_PARAM_COUNT; + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &securityPrefs) == FAILURE) { + return; } + intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); + oldSecurityPrefs = intern->securityPrefs; + intern->securityPrefs = securityPrefs; + RETURN_LONG(oldSecurityPrefs); } /* }}} end xsl_xsltprocessor_set_security_prefs */ From 23ad275e24fbc9b49af65fe1030eab87a9c13c3a Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 12 Jul 2011 04:58:55 +0000 Subject: [PATCH 0302/2394] MF53 --- sapi/litespeed/lsapilib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/litespeed/lsapilib.c b/sapi/litespeed/lsapilib.c index 3c3373ac7ebd9..7d0ea27fd7668 100644 --- a/sapi/litespeed/lsapilib.c +++ b/sapi/litespeed/lsapilib.c @@ -1442,7 +1442,7 @@ int LSAPI_ParseSockAddr( const char * pBind, struct sockaddr * pAddr ) return -1; } - while( isspace( *p ) ) { + while( isspace( *pBind ) ) { ++pBind; } @@ -1498,7 +1498,7 @@ int LSAPI_ParseSockAddr( const char * pBind, struct sockaddr * pAddr ) } port = atoi( pEnd ); - if (( port <= 0 )||( port > 655535 )) { + if (( port <= 0 )||( port > 65535 )) { return -1; } if ( doAddrInfo ) { From 35f19cb9692511ad6cb73a116a5e44d7d2e8ecc8 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 12 Jul 2011 05:20:40 +0000 Subject: [PATCH 0303/2394] remove warning for is_a() BC --- Zend/zend_builtin_functions.c | 1 - 1 file changed, 1 deletion(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index b634e3de00c31..6f82776391718 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -848,7 +848,6 @@ static void is_a_impl(INTERNAL_FUNCTION_PARAMETERS, zend_bool only_subclass) if (Z_TYPE_P(obj) == IS_STRING) { zend_class_entry **the_ce; if (zend_lookup_class(Z_STRVAL_P(obj), Z_STRLEN_P(obj), &the_ce TSRMLS_CC) == FAILURE) { - zend_error(E_WARNING, "Unknown class passed as parameter"); RETURN_FALSE; } instance_ce = *the_ce; From 01607c413761d4525f69cc6dd67c292742107724 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Tue, 12 Jul 2011 06:56:11 +0000 Subject: [PATCH 0304/2394] Added credentials to XSL NEWS entry --- NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 0c7b61f4a9188..9bc1b7da0cc93 100644 --- a/NEWS +++ b/NEWS @@ -209,7 +209,7 @@ PHP NEWS - Improved XSL extension: . Added XsltProcessor::setSecurityPrefs($options) and getSecurityPrefs() to define forbidden operations within XSLT stylesheets, default is not to - enable any write operations from XSLT anymore. Bug #54446 + enable write operations from XSLT. Bug #54446 (Chregu, Nicolas Gregoire) - Improved ZLIB extension: . Re-implemented non-file related functionality. (Mike) From 96b5e69889c9be2549a4d33bf98a2729fc067cb8 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 12 Jul 2011 11:46:41 +0000 Subject: [PATCH 0305/2394] - Bug #55169, improve fix, allow non interactive user, hash-like ops only usage --- win32/winutil.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/win32/winutil.c b/win32/winutil.c index f3043f50aae12..a7a6922f64b23 100644 --- a/win32/winutil.c +++ b/win32/winutil.c @@ -87,11 +87,14 @@ PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{ #endif if (has_crypto_ctx == 0) { - if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, 0)) { + /* CRYPT_VERIFYCONTEXT > only hashing&co-like use, no need to acces prv keys */ + if (!CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_MACHINE_KEYSET|CRYPT_VERIFYCONTEXT )) { /* Could mean that the key container does not exist, let try - again by asking for a new one */ + again by asking for a new one. If it fails here, it surely means that the user running + this process does not have the permission(s) to use this container. + */ if (GetLastError() == NTE_BAD_KEYSET) { - if (CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_NEWKEYSET)) { + if (CryptAcquireContext(&hCryptProv, NULL, NULL, PROV_RSA_FULL, CRYPT_NEWKEYSET | CRYPT_MACHINE_KEYSET | CRYPT_VERIFYCONTEXT )) { has_crypto_ctx = 1; } else { has_crypto_ctx = 0; From b6745ea43a7c04551b112901882eb7a992773cd6 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 12 Jul 2011 15:15:17 +0000 Subject: [PATCH 0306/2394] - Fixed bug #55187, readlink returns weird characters when false result --- ext/standard/link_win32.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/standard/link_win32.c b/ext/standard/link_win32.c index d7589bbb7b720..703bcc1e23a24 100644 --- a/ext/standard/link_win32.c +++ b/ext/standard/link_win32.c @@ -76,6 +76,7 @@ PHP_FUNCTION(readlink) if (php_sys_readlink(link, target, MAXPATHLEN) == -1) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "readlink failed to read the symbolic link (%s), error %d)", link, GetLastError()); + RETURN_FALSE; } RETURN_STRING(target, 1); } From c13f2c3e2c22829d58d6f5b9b8106ae76b580b52 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Tue, 12 Jul 2011 21:43:17 +0000 Subject: [PATCH 0307/2394] Fix #48860 Implement Serialization for DLL --- ext/spl/spl_dllist.c | 118 +++++++++++++++++- .../SplDoublyLinkedList_serialization.phpt | 67 ++++++++++ 2 files changed, 184 insertions(+), 1 deletion(-) create mode 100644 ext/spl/tests/SplDoublyLinkedList_serialization.phpt diff --git a/ext/spl/spl_dllist.c b/ext/spl/spl_dllist.c index 2030bcf5de729..2c90243a20222 100644 --- a/ext/spl/spl_dllist.c +++ b/ext/spl/spl_dllist.c @@ -27,6 +27,9 @@ #include "zend_hash.h" #include "php_spl.h" +#include "ext/standard/info.h" +#include "ext/standard/php_var.h" +#include "ext/standard/php_smart_str.h" #include "spl_functions.h" #include "spl_engine.h" #include "spl_iterators.h" @@ -1129,6 +1132,108 @@ SPL_METHOD(SplDoublyLinkedList, current) } } /* }}} */ +/* {{{ proto string SplDoublyLinkedList::serialize() + Serializes storage */ +SPL_METHOD(SplDoublyLinkedList, serialize) +{ + spl_dllist_object *intern = (spl_dllist_object*)zend_object_store_get_object(getThis() TSRMLS_CC); + smart_str buf = {0}; + spl_ptr_llist_element *current = intern->llist->head, *next; + zval *flags; + php_serialize_data_t var_hash; + + if (zend_parse_parameters_none() == FAILURE) { + return; + } + + PHP_VAR_SERIALIZE_INIT(var_hash); + + /* flags */ + MAKE_STD_ZVAL(flags); + ZVAL_LONG(flags, intern->flags); + php_var_serialize(&buf, &flags, &var_hash TSRMLS_CC); + zval_ptr_dtor(&flags); + + /* elements */ + while (current) { + smart_str_appendc(&buf, ':'); + next = current->next; + + php_var_serialize(&buf, (zval **)¤t->data, &var_hash TSRMLS_CC); + + current = next; + } + + smart_str_0(&buf); + + /* done */ + PHP_VAR_SERIALIZE_DESTROY(var_hash); + + if (buf.c) { + RETURN_STRINGL(buf.c, buf.len, 0); + } else { + RETURN_NULL(); + } + +} /* }}} */ + +/* {{{ proto void SplDoublyLinkedList::unserialize(string serialized) + Unserializes storage */ +SPL_METHOD(SplDoublyLinkedList, unserialize) +{ + spl_dllist_object *intern = (spl_dllist_object*)zend_object_store_get_object(getThis() TSRMLS_CC); + zval *flags, *elem; + char *buf; + int buf_len; + const unsigned char *p, *s; + php_unserialize_data_t var_hash; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &buf, &buf_len) == FAILURE) { + return; + } + + if (buf_len == 0) { + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Serialized string cannot be empty"); + return; + } + + s = p = (const unsigned char*)buf; + PHP_VAR_UNSERIALIZE_INIT(var_hash); + + /* flags */ + ALLOC_INIT_ZVAL(flags); + if (!php_var_unserialize(&elem, &p, s + buf_len, &var_hash TSRMLS_CC) || Z_TYPE_P(elem) != IS_LONG) { + zval_ptr_dtor(&flags); + goto error; + } + intern->flags = Z_LVAL_P(elem); + zval_ptr_dtor(&flags); + + /* elements */ + while(*p == ':') { + ++p; + ALLOC_INIT_ZVAL(elem); + if (!php_var_unserialize(&elem, &p, s + buf_len, &var_hash TSRMLS_CC)) { + zval_ptr_dtor(&elem); + goto error; + } + + spl_ptr_llist_push(intern->llist, elem TSRMLS_CC); + } + + if (*p != '\0') { + goto error; + } + + PHP_VAR_UNSERIALIZE_DESTROY(var_hash); + return; + +error: + PHP_VAR_UNSERIALIZE_DESTROY(var_hash); + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Error at offset %ld of %d bytes", (long)((char*)p - buf), buf_len); + return; + +} /* }}} */ /* iterator handler table */ zend_object_iterator_funcs spl_dllist_it_funcs = { @@ -1190,6 +1295,10 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO(arginfo_dllist_void, 0) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_dllist_serialized, 0) + ZEND_ARG_INFO(0, serialized) +ZEND_END_ARG_INFO(); + static const zend_function_entry spl_funcs_SplQueue[] = { SPL_MA(SplQueue, enqueue, SplDoublyLinkedList, push, arginfo_dllist_push, ZEND_ACC_PUBLIC) SPL_MA(SplQueue, dequeue, SplDoublyLinkedList, shift, arginfo_dllist_void, ZEND_ACC_PUBLIC) @@ -1203,20 +1312,26 @@ static const zend_function_entry spl_funcs_SplDoublyLinkedList[] = { SPL_ME(SplDoublyLinkedList, unshift, arginfo_dllist_push, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, top, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, bottom, arginfo_dllist_void, ZEND_ACC_PUBLIC) - SPL_ME(SplDoublyLinkedList, count, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, isEmpty, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, setIteratorMode, arginfo_dllist_setiteratormode, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, getIteratorMode, arginfo_dllist_void, ZEND_ACC_PUBLIC) + /* Countable */ + SPL_ME(SplDoublyLinkedList, count, arginfo_dllist_void, ZEND_ACC_PUBLIC) + /* ArrayAccess */ SPL_ME(SplDoublyLinkedList, offsetExists, arginfo_dllist_offsetGet, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, offsetGet, arginfo_dllist_offsetGet, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, offsetSet, arginfo_dllist_offsetSet, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, offsetUnset, arginfo_dllist_offsetGet, ZEND_ACC_PUBLIC) + /* Iterator */ SPL_ME(SplDoublyLinkedList, rewind, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, current, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, key, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, next, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, prev, arginfo_dllist_void, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, valid, arginfo_dllist_void, ZEND_ACC_PUBLIC) + /* Serializable */ + SPL_ME(SplDoublyLinkedList, unserialize, arginfo_dllist_serialized, ZEND_ACC_PUBLIC) + SPL_ME(SplDoublyLinkedList, serialize, arginfo_dllist_void, ZEND_ACC_PUBLIC) {NULL, NULL, NULL} }; /* }}} */ @@ -1238,6 +1353,7 @@ PHP_MINIT_FUNCTION(spl_dllist) /* {{{ */ REGISTER_SPL_IMPLEMENTS(SplDoublyLinkedList, Iterator); REGISTER_SPL_IMPLEMENTS(SplDoublyLinkedList, Countable); REGISTER_SPL_IMPLEMENTS(SplDoublyLinkedList, ArrayAccess); + REGISTER_SPL_IMPLEMENTS(SplDoublyLinkedList, Serializable); spl_ce_SplDoublyLinkedList->get_iterator = spl_dllist_get_iterator; diff --git a/ext/spl/tests/SplDoublyLinkedList_serialization.phpt b/ext/spl/tests/SplDoublyLinkedList_serialization.phpt new file mode 100644 index 0000000000000..7ab7d78174f7e --- /dev/null +++ b/ext/spl/tests/SplDoublyLinkedList_serialization.phpt @@ -0,0 +1,67 @@ +--TEST-- +Check Serialization/unserialization +--FILE-- +enqueue("a"); +$q->enqueue("b"); + +var_dump($q, $ss = serialize($q), unserialize($ss)); + +$s = new SplStack(); + +$s->push("a"); +$s->push("b"); + +var_dump($s, $ss = serialize($s), unserialize($ss)); +?> +==END== +--EXPECTF-- +object(SplQueue)#%d (2) { + ["flags":"SplDoublyLinkedList":private]=> + int(4) + ["dllist":"SplDoublyLinkedList":private]=> + array(2) { + [0]=> + string(1) "a" + [1]=> + string(1) "b" + } +} +string(42) "C:8:"SplQueue":22:{i:4;:s:1:"a";:s:1:"b";}" +object(SplQueue)#%d (2) { + ["flags":"SplDoublyLinkedList":private]=> + int(4) + ["dllist":"SplDoublyLinkedList":private]=> + array(2) { + [0]=> + string(1) "a" + [1]=> + string(1) "b" + } +} +object(SplStack)#%d (2) { + ["flags":"SplDoublyLinkedList":private]=> + int(6) + ["dllist":"SplDoublyLinkedList":private]=> + array(2) { + [0]=> + string(1) "a" + [1]=> + string(1) "b" + } +} +string(42) "C:8:"SplStack":22:{i:6;:s:1:"a";:s:1:"b";}" +object(SplStack)#%d (2) { + ["flags":"SplDoublyLinkedList":private]=> + int(6) + ["dllist":"SplDoublyLinkedList":private]=> + array(2) { + [0]=> + string(1) "a" + [1]=> + string(1) "b" + } +} +==END== From 28c3a180b26bee5221f34ccb86a3723747604962 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Tue, 12 Jul 2011 21:57:14 +0000 Subject: [PATCH 0308/2394] Fix crash --- ext/spl/spl_dllist.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/spl/spl_dllist.c b/ext/spl/spl_dllist.c index 2c90243a20222..06d22e1b619e6 100644 --- a/ext/spl/spl_dllist.c +++ b/ext/spl/spl_dllist.c @@ -1202,11 +1202,11 @@ SPL_METHOD(SplDoublyLinkedList, unserialize) /* flags */ ALLOC_INIT_ZVAL(flags); - if (!php_var_unserialize(&elem, &p, s + buf_len, &var_hash TSRMLS_CC) || Z_TYPE_P(elem) != IS_LONG) { + if (!php_var_unserialize(&flags, &p, s + buf_len, &var_hash TSRMLS_CC) || Z_TYPE_P(flags) != IS_LONG) { zval_ptr_dtor(&flags); goto error; } - intern->flags = Z_LVAL_P(elem); + intern->flags = Z_LVAL_P(flags); zval_ptr_dtor(&flags); /* elements */ From 1655d6d4c7d778b5a43e2f5c8f40c8f4ad1a5fbd Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 13 Jul 2011 06:42:39 +0000 Subject: [PATCH 0309/2394] - bind to the available crt version --- win32/build/config.w32 | 1 + 1 file changed, 1 insertion(+) diff --git a/win32/build/config.w32 b/win32/build/config.w32 index 2351ee695b50b..516172b2605cc 100644 --- a/win32/build/config.w32 +++ b/win32/build/config.w32 @@ -151,6 +151,7 @@ if (VCVERS >= 1400) { // Set some debug/release specific options ADD_FLAG('CFLAGS', ' /RTC1 '); } + ADD_FLAG('CFLAGS', ' /D_BIND_TO_CURRENT_CRT_VERSION =1 '); } ARG_WITH('mp', 'Tell VC9+ use up to [n,auto,disable] processes for compilation', 'auto'); From 3311b0f83fd3aac4918b803f9abd22a31178d910 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Wed, 13 Jul 2011 16:08:03 +0000 Subject: [PATCH 0310/2394] Use datetime examine diff file from 5.3 in 5.4 and trunk. --- ext/date/tests/examine_diff.inc | 73 +++++++++++++++++---------------- 1 file changed, 37 insertions(+), 36 deletions(-) diff --git a/ext/date/tests/examine_diff.inc b/ext/date/tests/examine_diff.inc index 35b4ae333d3fe..c3dcba93884f6 100644 --- a/ext/date/tests/examine_diff.inc +++ b/ext/date/tests/examine_diff.inc @@ -1,16 +1,22 @@ */ +/**#@+ + * Which test segments should be displayed? + */ +define('PHPT_DATETIME_SHOW_DIFF', 1); +define('PHPT_DATETIME_SHOW_DAYS', 2); +define('PHPT_DATETIME_SHOW_ADD', 3); +define('PHPT_DATETIME_SHOW_SUB', 4); +/**#@-*/ + /** - * Provides a consistent interface for executing date diff tests - * - * Tests the diff() method then passes the resulting - * interval to the add()/sub() method as a double check + * Provides a consistent interface for executing date diff/add/sub tests * * @param string|DateTime $end_date the end date in YYYY-MM-DD format * (can include time HH:MM:SS) or a DateTime object @@ -41,38 +47,33 @@ function examine_diff($end_date, $start_date, $expect_spec, $expect_days, $absol } $end_date = $end->format('Y-m-d H:i:s T'); - $force_sub = false; - if ($absolute) { - $tmp_interval = $start->diff($end); - if ($tmp_interval->format('%r')) { - $force_sub = true; - } + $expect_interval = new DateInterval('P' . substr($expect_spec, 2)); + if (substr($expect_spec, 1, 1) == '-') { + $expect_interval->invert = true; } - $result_interval = $start->diff($end, $absolute); - $result_spec = $result_interval->format('P%R%yY%mM%dDT%hH%iM%sS'); - $result_days = $result_interval->format('%a'); - - // Also make sure add()/sub() works the same way as diff(). - if ($force_sub) { - $start->sub($result_interval); - $sign = '-'; - } else { - $start->add($result_interval); - $sign = '+'; + if (PHPT_DATETIME_SHOW == PHPT_DATETIME_SHOW_DIFF) { + $result_interval = $start->diff($end, $absolute); + $result_spec = $result_interval->format('P%R%yY%mM%dDT%hH%iM%sS'); + echo "DIFF: $end_date - $start_date = **$result_spec**\n"; + // echo "DIFF: $end_date - $start_date = **$expect_spec**\n"; + } + if (PHPT_DATETIME_SHOW == PHPT_DATETIME_SHOW_DAYS) { + $result_interval = $start->diff($end, $absolute); + $result_days = $result_interval->format('%a'); + echo "DAYS: **$result_days**\n"; + // echo "DAYS: **$expect_days**\n"; + } + if (PHPT_DATETIME_SHOW == PHPT_DATETIME_SHOW_ADD) { + $start->add($expect_interval); + $result_end_date = $start->format('Y-m-d H:i:s T'); + echo "ADD: $start_date + $expect_spec = **$result_end_date**\n"; + // echo "ADD: $start_date + $expect_spec = **$end_date**\n"; + } + if (PHPT_DATETIME_SHOW == PHPT_DATETIME_SHOW_SUB) { + $end->sub($expect_interval); + $result_start_date = $end->format('Y-m-d H:i:s T'); + echo "SUB: $end_date - $expect_spec = **$result_start_date**\n"; + // echo "SUB: $end_date - $expect_spec = **$start_date**\n"; } - - $result_end_date = $start->format('Y-m-d H:i:s T'); - - // Leaving this here for making adjustments later. - $expect_full = "FWD: $end_date - $start_date = **$expect_spec** | " - . "BACK: $start_date $sign $expect_spec = **$end_date** | " - . "DAYS: **$expect_days**"; - // echo "$expect_full\n"; - // return; - - $result_full = "FWD: $end_date - $start_date = **$result_spec** | " - . "BACK: $start_date $sign $result_spec = **$result_end_date** | " - . "DAYS: **$result_days**"; - echo "$result_full\n"; } From b23070291b54b38a5b8227c710bc72aa3cf16231 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Wed, 13 Jul 2011 16:21:10 +0000 Subject: [PATCH 0311/2394] Add test for constructing times during the dst/st conversion. --- .../tests/DateTime_construct-dst-overlap.phpt | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 ext/date/tests/DateTime_construct-dst-overlap.phpt diff --git a/ext/date/tests/DateTime_construct-dst-overlap.phpt b/ext/date/tests/DateTime_construct-dst-overlap.phpt new file mode 100644 index 0000000000000..05ed525ac4127 --- /dev/null +++ b/ext/date/tests/DateTime_construct-dst-overlap.phpt @@ -0,0 +1,15 @@ +--TEST-- +DateTime::__construct() -- fall daylight/standard overlap +--CREDITS-- +Daniel Convissor +--FILE-- +format('P') . "\n"; + +?> +--EXPECT-- +-04:00 From e3253b79ad8d895adbc2cd3aec239bb433b98005 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Wed, 13 Jul 2011 16:22:58 +0000 Subject: [PATCH 0312/2394] Have test for add/sub/diff one second during DST/ST transition. --- .../tests/DateTime_add-fall-type2-type2.phpt | 2 ++ .../tests/DateTime_add-fall-type2-type3.phpt | 2 ++ .../tests/DateTime_add-fall-type3-type2.phpt | 2 ++ .../tests/DateTime_add-fall-type3-type3.phpt | 2 ++ .../tests/DateTime_data-fall-type2-type2.inc | 12 ++++++++++++ .../tests/DateTime_data-fall-type2-type3.inc | 14 ++++++++++++++ .../tests/DateTime_data-fall-type3-type2.inc | 14 ++++++++++++++ .../tests/DateTime_data-fall-type3-type3.inc | 16 ++++++++++++++++ .../tests/DateTime_days-fall-type2-type2.phpt | 2 ++ .../tests/DateTime_days-fall-type2-type3.phpt | 2 ++ .../tests/DateTime_days-fall-type3-type2.phpt | 2 ++ .../tests/DateTime_days-fall-type3-type3.phpt | 2 ++ .../tests/DateTime_diff-fall-type2-type2.phpt | 2 ++ .../tests/DateTime_diff-fall-type2-type3.phpt | 2 ++ .../tests/DateTime_diff-fall-type3-type2.phpt | 2 ++ .../tests/DateTime_diff-fall-type3-type3.phpt | 2 ++ .../tests/DateTime_sub-fall-type2-type2.phpt | 2 ++ .../tests/DateTime_sub-fall-type2-type3.phpt | 2 ++ .../tests/DateTime_sub-fall-type3-type2.phpt | 2 ++ .../tests/DateTime_sub-fall-type3-type3.phpt | 2 ++ 20 files changed, 88 insertions(+) diff --git a/ext/date/tests/DateTime_add-fall-type2-type2.phpt b/ext/date/tests/DateTime_add-fall-type2-type2.phpt index 0801a042c902f..82cc81c9eb646 100644 --- a/ext/date/tests/DateTime_add-fall-type2-type2.phpt +++ b/ext/date/tests/DateTime_add-fall-type2-type2.phpt @@ -49,3 +49,5 @@ test_time_fall_type2_post_type2_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT test_time_fall_type2_post_type2_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** test_time_fall_type2_post_type2_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** test_time_fall_type2_post_type2_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_dtsec_type2_stsec: ADD: 2010-11-07 01:59:59 EDT + P+0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** +test_time_fall_type2_stsec_type2_dtsec: ADD: 2010-11-07 01:00:00 EST + P-0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** diff --git a/ext/date/tests/DateTime_add-fall-type2-type3.phpt b/ext/date/tests/DateTime_add-fall-type2-type3.phpt index a342e86c4a94e..077dd565d1dba 100644 --- a/ext/date/tests/DateTime_add-fall-type2-type3.phpt +++ b/ext/date/tests/DateTime_add-fall-type2-type3.phpt @@ -49,3 +49,5 @@ test_time_fall_type2_post_type3_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT test_time_fall_type2_post_type3_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** test_time_fall_type2_post_type3_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** test_time_fall_type2_post_type3_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type2_dtsec_type3_stsec: ADD: 2010-11-07 01:59:59 EDT + P+0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** +test_time_fall_type2_stsec_type3_dtsec: ADD: 2010-11-07 01:00:00 EST + P-0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** diff --git a/ext/date/tests/DateTime_add-fall-type3-type2.phpt b/ext/date/tests/DateTime_add-fall-type3-type2.phpt index 289e303b16d68..0588cbf2836eb 100644 --- a/ext/date/tests/DateTime_add-fall-type3-type2.phpt +++ b/ext/date/tests/DateTime_add-fall-type3-type2.phpt @@ -49,3 +49,5 @@ test_time_fall_type3_post_type2_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT test_time_fall_type3_post_type2_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** test_time_fall_type3_post_type2_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** test_time_fall_type3_post_type2_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_dtsec_type2_stsec: ADD: 2010-11-07 01:59:59 EDT + P+0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** +test_time_fall_type3_stsec_type2_dtsec: ADD: 2010-11-07 01:00:00 EST + P-0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** diff --git a/ext/date/tests/DateTime_add-fall-type3-type3.phpt b/ext/date/tests/DateTime_add-fall-type3-type3.phpt index 517f4abaf81e5..24315529a07e0 100644 --- a/ext/date/tests/DateTime_add-fall-type3-type3.phpt +++ b/ext/date/tests/DateTime_add-fall-type3-type3.phpt @@ -49,3 +49,5 @@ test_time_fall_type3_post_type3_redodt: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT test_time_fall_type3_post_type3_redost: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT18H45M15S = **2010-11-07 01:14:44 EST** test_time_fall_type3_post_type3_st: ADD: 2010-11-08 19:59:59 EST + P-0Y0M1DT16H43M4S = **2010-11-07 03:16:55 EST** test_time_fall_type3_post_type3_post: ADD: 2010-11-08 18:57:55 EST + P+0Y0M0DT1H2M4S = **2010-11-08 19:59:59 EST** +test_time_fall_type3_dtsec_type3_stsec: ADD: 2010-11-07 01:59:59 EDT + P+0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** +test_time_fall_type3_stsec_type3_dtsec: ADD: 2010-11-07 01:00:00 EST + P-0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** diff --git a/ext/date/tests/DateTime_data-fall-type2-type2.inc b/ext/date/tests/DateTime_data-fall-type2-type2.inc index 748590e634d7e..faf8f437594e6 100644 --- a/ext/date/tests/DateTime_data-fall-type2-type2.inc +++ b/ext/date/tests/DateTime_data-fall-type2-type2.inc @@ -17,6 +17,8 @@ date_default_timezone_set('America/New_York'); * + redost: standard time in the redo period 2010-11-07 01:14:44 EST * + st: standard time on the transition day 2010-11-07 03:16:55 EST * + post: the day after the transition day 2010-11-08 19:59:59 EST + * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT + * + stsec: standard time first secodn 2010-11-07 01:00:00 EST */ echo "test_time_fall_type2_prev_type2_prev: "; $end = new DateTime('2010-11-06 18:38:28 EDT'); // prev, zt2 @@ -197,3 +199,13 @@ echo "test_time_fall_type2_post_type2_post: "; $end = new DateTime('2010-11-08 19:59:59 EST'); // post, zt2 $start = new DateTime('2010-11-08 18:57:55 EST'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_fall_type2_dtsec_type2_stsec: "; +$end = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +$start = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_fall_type2_stsec_type2_dtsec: "; +$end = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +$start = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-fall-type2-type3.inc b/ext/date/tests/DateTime_data-fall-type2-type3.inc index 368934c98fc1d..c135dae2d6828 100644 --- a/ext/date/tests/DateTime_data-fall-type2-type3.inc +++ b/ext/date/tests/DateTime_data-fall-type2-type3.inc @@ -17,6 +17,8 @@ date_default_timezone_set('America/New_York'); * + redost: standard time in the redo period 2010-11-07 01:14:44 EST * + st: standard time on the transition day 2010-11-07 03:16:55 EST * + post: the day after the transition day 2010-11-08 19:59:59 EST + * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT + * + stsec: standard time first secodn 2010-11-07 01:00:00 EST */ echo "test_time_fall_type2_prev_type3_prev: "; $end = new DateTime('2010-11-06 18:38:28'); // prev, zt3 @@ -209,3 +211,15 @@ echo "test_time_fall_type2_post_type3_post: "; $end = new DateTime('2010-11-08 19:59:59'); // post, zt3 $start = new DateTime('2010-11-08 18:57:55 EST'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_fall_type2_dtsec_type3_stsec: "; +$end = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +$end->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +$start = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_fall_type2_stsec_type3_dtsec: "; +$end = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +$end->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +$start = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-fall-type3-type2.inc b/ext/date/tests/DateTime_data-fall-type3-type2.inc index 467139bcc469d..38917fd5ecd2b 100644 --- a/ext/date/tests/DateTime_data-fall-type3-type2.inc +++ b/ext/date/tests/DateTime_data-fall-type3-type2.inc @@ -17,6 +17,8 @@ date_default_timezone_set('America/New_York'); * + redost: standard time in the redo period 2010-11-07 01:14:44 EST * + st: standard time on the transition day 2010-11-07 03:16:55 EST * + post: the day after the transition day 2010-11-08 19:59:59 EST + * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT + * + stsec: standard time first secodn 2010-11-07 01:00:00 EST */ echo "test_time_fall_type3_prev_type2_prev: "; $end = new DateTime('2010-11-06 18:38:28 EDT'); // prev, zt2 @@ -211,3 +213,15 @@ echo "test_time_fall_type3_post_type2_post: "; $end = new DateTime('2010-11-08 19:59:59 EST'); // post, zt2 $start = new DateTime('2010-11-08 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_fall_type3_dtsec_type2_stsec: "; +$end = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +$start = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +$start->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_fall_type3_stsec_type2_dtsec: "; +$end = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +$start = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +$start->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-fall-type3-type3.inc b/ext/date/tests/DateTime_data-fall-type3-type3.inc index c8ebd59d60963..53a97408768dc 100644 --- a/ext/date/tests/DateTime_data-fall-type3-type3.inc +++ b/ext/date/tests/DateTime_data-fall-type3-type3.inc @@ -17,6 +17,8 @@ date_default_timezone_set('America/New_York'); * + redost: standard time in the redo period 2010-11-07 01:14:44 EST, + TZ * + st: standard time on the transition day 2010-11-07 03:16:55 * + post: the day after the transition day 2010-11-08 19:59:59 + * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT, + TZ + * + stsec: standard time first secodn 2010-11-07 01:00:00 EST, + TZ */ echo "test_time_fall_type3_prev_type3_prev: "; $end = new DateTime('2010-11-06 18:38:28'); // prev, zt3 @@ -221,3 +223,17 @@ echo "test_time_fall_type3_post_type3_post: "; $end = new DateTime('2010-11-08 19:59:59'); // post, zt3 $start = new DateTime('2010-11-08 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_fall_type3_dtsec_type3_stsec: "; +$end = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +$end->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +$start = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +$start->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_fall_type3_stsec_type3_dtsec: "; +$end = new DateTime('2010-11-07 01:59:59 EDT'); // dtsec, zt2 +$end->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +$start = new DateTime('2010-11-07 01:00:00 EST'); // stsec, zt2 +$start->setTimezone(new DateTimeZone('America/New_York')); // zt2 -> zt3 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_days-fall-type2-type2.phpt b/ext/date/tests/DateTime_days-fall-type2-type2.phpt index c71d8c2bc4d52..3af156c7614e5 100644 --- a/ext/date/tests/DateTime_days-fall-type2-type2.phpt +++ b/ext/date/tests/DateTime_days-fall-type2-type2.phpt @@ -47,3 +47,5 @@ test_time_fall_type2_post_type2_redodt: DAYS: **1** test_time_fall_type2_post_type2_redost: DAYS: **1** test_time_fall_type2_post_type2_st: DAYS: **1** test_time_fall_type2_post_type2_post: DAYS: **0** +test_time_fall_type2_dtsec_type2_stsec: DAYS: **0** +test_time_fall_type2_stsec_type2_dtsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-fall-type2-type3.phpt b/ext/date/tests/DateTime_days-fall-type2-type3.phpt index 548c1bfbcafb3..8a4296b7606fe 100644 --- a/ext/date/tests/DateTime_days-fall-type2-type3.phpt +++ b/ext/date/tests/DateTime_days-fall-type2-type3.phpt @@ -47,3 +47,5 @@ test_time_fall_type2_post_type3_redodt: DAYS: **1** test_time_fall_type2_post_type3_redost: DAYS: **1** test_time_fall_type2_post_type3_st: DAYS: **1** test_time_fall_type2_post_type3_post: DAYS: **0** +test_time_fall_type2_dtsec_type3_stsec: DAYS: **0** +test_time_fall_type2_stsec_type3_dtsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-fall-type3-type2.phpt b/ext/date/tests/DateTime_days-fall-type3-type2.phpt index 053a3541e9ab0..d5456036c2bb4 100644 --- a/ext/date/tests/DateTime_days-fall-type3-type2.phpt +++ b/ext/date/tests/DateTime_days-fall-type3-type2.phpt @@ -47,3 +47,5 @@ test_time_fall_type3_post_type2_redodt: DAYS: **1** test_time_fall_type3_post_type2_redost: DAYS: **1** test_time_fall_type3_post_type2_st: DAYS: **1** test_time_fall_type3_post_type2_post: DAYS: **0** +test_time_fall_type3_dtsec_type2_stsec: DAYS: **0** +test_time_fall_type3_stsec_type2_dtsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-fall-type3-type3.phpt b/ext/date/tests/DateTime_days-fall-type3-type3.phpt index 9f80bd68786b1..38e4ef50f5812 100644 --- a/ext/date/tests/DateTime_days-fall-type3-type3.phpt +++ b/ext/date/tests/DateTime_days-fall-type3-type3.phpt @@ -47,3 +47,5 @@ test_time_fall_type3_post_type3_redodt: DAYS: **1** test_time_fall_type3_post_type3_redost: DAYS: **1** test_time_fall_type3_post_type3_st: DAYS: **1** test_time_fall_type3_post_type3_post: DAYS: **0** +test_time_fall_type3_dtsec_type3_stsec: DAYS: **0** +test_time_fall_type3_stsec_type3_dtsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_diff-fall-type2-type2.phpt b/ext/date/tests/DateTime_diff-fall-type2-type2.phpt index 276d84892d9b0..3e7cf7dbf2a21 100644 --- a/ext/date/tests/DateTime_diff-fall-type2-type2.phpt +++ b/ext/date/tests/DateTime_diff-fall-type2-type2.phpt @@ -49,3 +49,5 @@ test_time_fall_type2_post_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11- test_time_fall_type2_post_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** test_time_fall_type2_post_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** test_time_fall_type2_post_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** +test_time_fall_type2_dtsec_type2_stsec: DIFF: 2010-11-07 01:00:00 EST - 2010-11-07 01:59:59 EDT = **P+0Y0M0DT0H0M1S** +test_time_fall_type2_stsec_type2_dtsec: DIFF: 2010-11-07 01:59:59 EDT - 2010-11-07 01:00:00 EST = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_diff-fall-type2-type3.phpt b/ext/date/tests/DateTime_diff-fall-type2-type3.phpt index b06c787d066e0..ec790f02ecb31 100644 --- a/ext/date/tests/DateTime_diff-fall-type2-type3.phpt +++ b/ext/date/tests/DateTime_diff-fall-type2-type3.phpt @@ -49,3 +49,5 @@ test_time_fall_type2_post_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11- test_time_fall_type2_post_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** test_time_fall_type2_post_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** test_time_fall_type2_post_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** +test_time_fall_type2_dtsec_type3_stsec: DIFF: 2010-11-07 01:00:00 EST - 2010-11-07 01:59:59 EDT = **P+0Y0M0DT0H0M1S** +test_time_fall_type2_stsec_type3_dtsec: DIFF: 2010-11-07 01:59:59 EDT - 2010-11-07 01:00:00 EST = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_diff-fall-type3-type2.phpt b/ext/date/tests/DateTime_diff-fall-type3-type2.phpt index 58d72808b833c..c9f268ff9795e 100644 --- a/ext/date/tests/DateTime_diff-fall-type3-type2.phpt +++ b/ext/date/tests/DateTime_diff-fall-type3-type2.phpt @@ -49,3 +49,5 @@ test_time_fall_type3_post_type2_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11- test_time_fall_type3_post_type2_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** test_time_fall_type3_post_type2_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** test_time_fall_type3_post_type2_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** +test_time_fall_type3_dtsec_type2_stsec: DIFF: 2010-11-07 01:00:00 EST - 2010-11-07 01:59:59 EDT = **P+0Y0M0DT0H0M1S** +test_time_fall_type3_stsec_type2_dtsec: DIFF: 2010-11-07 01:59:59 EDT - 2010-11-07 01:00:00 EST = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_diff-fall-type3-type3.phpt b/ext/date/tests/DateTime_diff-fall-type3-type3.phpt index d8313b78fc646..bf25fef620701 100644 --- a/ext/date/tests/DateTime_diff-fall-type3-type3.phpt +++ b/ext/date/tests/DateTime_diff-fall-type3-type3.phpt @@ -49,3 +49,5 @@ test_time_fall_type3_post_type3_redodt: DIFF: 2010-11-07 01:12:33 EDT - 2010-11- test_time_fall_type3_post_type3_redost: DIFF: 2010-11-07 01:14:44 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT18H45M15S** test_time_fall_type3_post_type3_st: DIFF: 2010-11-07 03:16:55 EST - 2010-11-08 19:59:59 EST = **P-0Y0M1DT16H43M4S** test_time_fall_type3_post_type3_post: DIFF: 2010-11-08 19:59:59 EST - 2010-11-08 18:57:55 EST = **P+0Y0M0DT1H2M4S** +test_time_fall_type3_dtsec_type3_stsec: DIFF: 2010-11-07 01:00:00 EST - 2010-11-07 01:59:59 EDT = **P+0Y0M0DT0H0M1S** +test_time_fall_type3_stsec_type3_dtsec: DIFF: 2010-11-07 01:59:59 EDT - 2010-11-07 01:00:00 EST = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_sub-fall-type2-type2.phpt b/ext/date/tests/DateTime_sub-fall-type2-type2.phpt index ac1147f78e6c9..3138e1cd84067 100644 --- a/ext/date/tests/DateTime_sub-fall-type2-type2.phpt +++ b/ext/date/tests/DateTime_sub-fall-type2-type2.phpt @@ -49,3 +49,5 @@ test_time_fall_type2_post_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT test_time_fall_type2_post_type2_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** test_time_fall_type2_post_type2_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** test_time_fall_type2_post_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** +test_time_fall_type2_dtsec_type2_stsec: SUB: 2010-11-07 01:00:00 EST - P+0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** +test_time_fall_type2_stsec_type2_dtsec: SUB: 2010-11-07 01:59:59 EDT - P-0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type2-type3.phpt b/ext/date/tests/DateTime_sub-fall-type2-type3.phpt index f2fad2c9eba7b..6c2a9e03da8d4 100644 --- a/ext/date/tests/DateTime_sub-fall-type2-type3.phpt +++ b/ext/date/tests/DateTime_sub-fall-type2-type3.phpt @@ -49,3 +49,5 @@ test_time_fall_type2_post_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT test_time_fall_type2_post_type3_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** test_time_fall_type2_post_type3_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** test_time_fall_type2_post_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** +test_time_fall_type2_dtsec_type3_stsec: SUB: 2010-11-07 01:00:00 EST - P+0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** +test_time_fall_type2_stsec_type3_dtsec: SUB: 2010-11-07 01:59:59 EDT - P-0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type3-type2.phpt b/ext/date/tests/DateTime_sub-fall-type3-type2.phpt index 10a35c4af2c1d..e545ea5e25aaa 100644 --- a/ext/date/tests/DateTime_sub-fall-type3-type2.phpt +++ b/ext/date/tests/DateTime_sub-fall-type3-type2.phpt @@ -49,3 +49,5 @@ test_time_fall_type3_post_type2_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT test_time_fall_type3_post_type2_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** test_time_fall_type3_post_type2_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** test_time_fall_type3_post_type2_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** +test_time_fall_type3_dtsec_type2_stsec: SUB: 2010-11-07 01:00:00 EST - P+0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** +test_time_fall_type3_stsec_type2_dtsec: SUB: 2010-11-07 01:59:59 EDT - P-0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** diff --git a/ext/date/tests/DateTime_sub-fall-type3-type3.phpt b/ext/date/tests/DateTime_sub-fall-type3-type3.phpt index 518d741bc9417..6448b5d8423fa 100644 --- a/ext/date/tests/DateTime_sub-fall-type3-type3.phpt +++ b/ext/date/tests/DateTime_sub-fall-type3-type3.phpt @@ -49,3 +49,5 @@ test_time_fall_type3_post_type3_redodt: SUB: 2010-11-07 01:12:33 EDT - P-0Y0M1DT test_time_fall_type3_post_type3_redost: SUB: 2010-11-07 01:14:44 EST - P-0Y0M1DT18H45M15S = **2010-11-08 19:59:59 EST** test_time_fall_type3_post_type3_st: SUB: 2010-11-07 03:16:55 EST - P-0Y0M1DT16H43M4S = **2010-11-08 19:59:59 EST** test_time_fall_type3_post_type3_post: SUB: 2010-11-08 19:59:59 EST - P+0Y0M0DT1H2M4S = **2010-11-08 18:57:55 EST** +test_time_fall_type3_dtsec_type3_stsec: SUB: 2010-11-07 01:00:00 EST - P+0Y0M0DT0H0M1S = **2010-11-07 01:59:59 EDT** +test_time_fall_type3_stsec_type3_dtsec: SUB: 2010-11-07 01:59:59 EDT - P-0Y0M0DT0H0M1S = **2010-11-07 01:00:00 EST** From 3af61f1bf2ad087ddd133a08bb22ea21a14c117a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Wed, 13 Jul 2011 23:28:48 +0000 Subject: [PATCH 0313/2394] find option '-not' is not POSIX compliant --- build/build.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/build.mk b/build/build.mk index 61d6033fc17e6..ac5dadb313b0f 100644 --- a/build/build.mk +++ b/build/build.mk @@ -67,7 +67,7 @@ cvsclean-work: done svnclean-work: - @for i in `find . -type d -not -path '*/.svn/*' | grep -v '.svn'`; do \ + @for i in `find . -type d ! -path '*/.svn/*' | grep -v '.svn'`; do \ (cd $$i 2>/dev/null && rm -rf `svn propget svn:ignore . | grep -v config.nice` *.o *.a *.lo *.la *.gcno *.gcda .libs || true); \ done From 731029a672baf50bef0a2cb1e178a9b7de002e87 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 14 Jul 2011 10:54:39 +0000 Subject: [PATCH 0314/2394] - fix decl --- win32/build/config.w32 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/win32/build/config.w32 b/win32/build/config.w32 index 516172b2605cc..0cec4b140f2df 100644 --- a/win32/build/config.w32 +++ b/win32/build/config.w32 @@ -151,7 +151,7 @@ if (VCVERS >= 1400) { // Set some debug/release specific options ADD_FLAG('CFLAGS', ' /RTC1 '); } - ADD_FLAG('CFLAGS', ' /D_BIND_TO_CURRENT_CRT_VERSION =1 '); + ADD_FLAG('CFLAGS', ' /D_BIND_TO_CURRENT_CRT_VERSION=1 '); } ARG_WITH('mp', 'Tell VC9+ use up to [n,auto,disable] processes for compilation', 'auto'); From 4488350bb501cdf49717f7ad375de409b8902ae2 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 14 Jul 2011 11:12:33 +0000 Subject: [PATCH 0315/2394] - fix build --- ext/xsl/xsltprocessor.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 82a223787ae97..59c8bed8b06ca 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -916,8 +916,9 @@ PHP_FUNCTION(xsl_xsltprocessor_set_security_prefs) { zval *id; xsl_object *intern; - DOM_GET_THIS(id); long securityPrefs, oldSecurityPrefs; + + DOM_GET_THIS(id); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &securityPrefs) == FAILURE) { return; } @@ -933,9 +934,9 @@ PHP_FUNCTION(xsl_xsltprocessor_get_security_prefs) { zval *id; xsl_object *intern; - DOM_GET_THIS(id); long securityPrefs; + DOM_GET_THIS(id); if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "") == SUCCESS) { intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); RETURN_LONG(intern->securityPrefs); From ecd9d194d034d01babb446dc431d6b766928e0bc Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Thu, 14 Jul 2011 12:21:15 +0000 Subject: [PATCH 0316/2394] - Added a check for an enviroment variable (ZEND_DONT_UNLOAD_MODULES) that, if set, prevents PHP from dl_closing() modules on shutdown. - This makes it possible to spot memory leaks with valgrind in shared modules. --- Zend/zend_API.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index cacfcfb9ff24d..9e4385f079b1f 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -2266,7 +2266,7 @@ void module_destructor(zend_module_entry *module) /* {{{ */ #if HAVE_LIBDL #if !(defined(NETWARE) && defined(APACHE_1_BUILD)) - if (module->handle) { + if (module->handle && !getenv("ZEND_DONT_UNLOAD_MODULES")) { DL_UNLOAD(module->handle); } #endif From 4dbc1a57edfee44a7fab4f5cf850f86330a025de Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Thu, 14 Jul 2011 18:49:12 +0000 Subject: [PATCH 0317/2394] Fix prototypes for ldap_control_paged_result and fix function name in tests --- ext/ldap/ldap.c | 5 ++--- ext/ldap/tests/ldap_control_paged_results_variation1.phpt | 4 ++-- ext/ldap/tests/ldap_control_paged_results_variation3.phpt | 8 ++++---- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c index 0ecb5ddf75bf7..790ef6bf545f8 100644 --- a/ext/ldap/ldap.c +++ b/ext/ldap/ldap.c @@ -2186,7 +2186,7 @@ PHP_FUNCTION(ldap_8859_to_t61) #endif #ifdef LDAP_CONTROL_PAGEDRESULTS -/* {{{ proto bool ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) +/* {{{ proto mixed ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) Inject paged results control*/ PHP_FUNCTION(ldap_control_paged_result) { @@ -2278,7 +2278,7 @@ PHP_FUNCTION(ldap_control_paged_result) } /* }}} */ -/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string cookie [, int estimated]]) +/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string &cookie [, int &estimated]]) Extract paged results control response */ PHP_FUNCTION(ldap_control_paged_result_response) { @@ -2292,7 +2292,6 @@ PHP_FUNCTION(ldap_control_paged_result_response) ber_tag_t tag; int rc, lerrcode, myargcount = ZEND_NUM_ARGS(); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rr|zz", &link, &result, &cookie, &estimated) != SUCCESS) { return; } diff --git a/ext/ldap/tests/ldap_control_paged_results_variation1.phpt b/ext/ldap/tests/ldap_control_paged_results_variation1.phpt index 7220666099254..0e894464f4a23 100644 --- a/ext/ldap/tests/ldap_control_paged_results_variation1.phpt +++ b/ext/ldap/tests/ldap_control_paged_results_variation1.phpt @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page) +ldap_ldap_control_paged_result() test (fetching the first page) --CREDITS-- Jean-Sebastien Hedde --SKIPIF-- @@ -17,7 +17,7 @@ insert_dummy_data($link); $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; var_dump( - ldap_control_paged_results($link, 1), + ldap_control_paged_result($link, 1), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); diff --git a/ext/ldap/tests/ldap_control_paged_results_variation3.phpt b/ext/ldap/tests/ldap_control_paged_results_variation3.phpt index b5f3a7218b36c..43a68aea79dcc 100644 --- a/ext/ldap/tests/ldap_control_paged_results_variation3.phpt +++ b/ext/ldap/tests/ldap_control_paged_results_variation3.phpt @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page then the next final page) +ldap_ldap_control_paged_result() test (fetching the first page then the next final page) --CREDITS-- Jean-Sebastien Hedde --SKIPIF-- @@ -18,11 +18,11 @@ $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; $cookie = ''; var_dump( - ldap_control_paged_results($link, 2, true, $cookie), + ldap_control_paged_result($link, 2, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result), - ldap_control_paged_results_response($link, $result, $cookie), - ldap_control_paged_results($link, 20, true, $cookie), + ldap_control_paged_result_response($link, $result, $cookie), + ldap_control_paged_result($link, 20, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); From cad2e53064dddc958af24fefb96a8706ffcbf19a Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Fri, 15 Jul 2011 15:25:24 +0000 Subject: [PATCH 0318/2394] Fix #55212. Only declare STREAM_PF_INET6 if PHP is compiled with IPv6 support --- ext/standard/file.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/standard/file.c b/ext/standard/file.c index 0d6f7cf5ce496..f9fba1bc9fce9 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -236,10 +236,12 @@ PHP_MINIT_FUNCTION(file) REGISTER_LONG_CONSTANT("STREAM_PF_INET", AF_INET, CONST_CS|CONST_PERSISTENT); #endif -#ifdef PF_INET6 +#if HAVE_IPV6 +# ifdef PF_INET6 REGISTER_LONG_CONSTANT("STREAM_PF_INET6", PF_INET6, CONST_CS|CONST_PERSISTENT); -#elif defined(AF_INET6) +# elif defined(AF_INET6) REGISTER_LONG_CONSTANT("STREAM_PF_INET6", AF_INET6, CONST_CS|CONST_PERSISTENT); +# endif #endif #ifdef PF_UNIX From 1cf88d931e0726d1df5b42243a6fca1f98757d5f Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Fri, 15 Jul 2011 19:17:22 +0000 Subject: [PATCH 0319/2394] Updated is_a() and is_subclass_of() tests as per the removed E_WARNING from r313162 which was inspired by discussion after r312904 and PHP Bug #53727 --- ext/standard/tests/class_object/is_a_variation_001.phpt | 8 -------- .../tests/class_object/is_subclass_of_variation_001.phpt | 4 ---- .../tests/class_object/is_subclass_of_variation_004.phpt | 4 ---- 3 files changed, 16 deletions(-) diff --git a/ext/standard/tests/class_object/is_a_variation_001.phpt b/ext/standard/tests/class_object/is_a_variation_001.phpt index 1021544065bf8..d2d6ce24071f7 100644 --- a/ext/standard/tests/class_object/is_a_variation_001.phpt +++ b/ext/standard/tests/class_object/is_a_variation_001.phpt @@ -144,23 +144,15 @@ Arg value bool(false) Arg value - -Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value - -Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value string - -Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value String - -Warning: Unknown class passed as parameter in %sis_a_variation_001.php on line %d bool(false) Arg value diff --git a/ext/standard/tests/class_object/is_subclass_of_variation_001.phpt b/ext/standard/tests/class_object/is_subclass_of_variation_001.phpt index f11183d489d1b..14aaa3347b01b 100644 --- a/ext/standard/tests/class_object/is_subclass_of_variation_001.phpt +++ b/ext/standard/tests/class_object/is_subclass_of_variation_001.phpt @@ -150,21 +150,17 @@ Arg value bool(false) Arg value -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value string In __autoload(string) -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value String In __autoload(String) -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value diff --git a/ext/standard/tests/class_object/is_subclass_of_variation_004.phpt b/ext/standard/tests/class_object/is_subclass_of_variation_004.phpt index 72a02a0b2b0b8..2f46c4a8dfedc 100644 --- a/ext/standard/tests/class_object/is_subclass_of_variation_004.phpt +++ b/ext/standard/tests/class_object/is_subclass_of_variation_004.phpt @@ -150,21 +150,17 @@ Arg value bool(false) Arg value -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value string In __autoload(string) -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value String In __autoload(String) -Error: 2 - Unknown class passed as parameter, %s(79) bool(false) Arg value From 281d0eade46da893356f56d2782e32f691e075ae Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 17 Jul 2011 13:57:28 +0000 Subject: [PATCH 0320/2394] update ARG_INFO_EX for walk and get methods, fix comments --- ext/snmp/snmp.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index af4d80b8082a0..529be7e4a5e2c 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -347,10 +347,12 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_snmp_get, 0, 0, 1) ZEND_ARG_INFO(0, object_id) + ZEND_ARG_INFO(0, use_orignames) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_snmp_walk, 0, 0, 3) +ZEND_BEGIN_ARG_INFO_EX(arginfo_snmp_walk, 0, 0, 4) ZEND_ARG_INFO(0, object_id) + ZEND_ARG_INFO(0, suffix_keys) ZEND_ARG_INFO(0, non_repeaters) ZEND_ARG_INFO(0, max_repetitions) ZEND_END_ARG_INFO() @@ -1778,7 +1780,7 @@ PHP_METHOD(snmp, close) } /* }}} */ -/* {{{ proto mixed SNMP::get_assoc(mixed object_id) +/* {{{ proto mixed SNMP::get(mixed object_id [, bool preserve_keys]) Fetch a SNMP object returing scalar for single OID and array of oid->value pairs for multi OID request */ PHP_METHOD(snmp, get) { @@ -1786,7 +1788,7 @@ PHP_METHOD(snmp, get) } /* }}} */ -/* {{{ proto mixed SNMP::getnext(mixed object_id) +/* {{{ proto mixed SNMP::getnext(mixed object_id) Fetch a SNMP object returing scalar for single OID and array of oid->value pairs for multi OID request */ PHP_METHOD(snmp, getnext) { @@ -1794,7 +1796,7 @@ PHP_METHOD(snmp, getnext) } /* }}} */ -/* {{{ proto mixed SNMP::walk(mixed object_id) +/* {{{ proto mixed SNMP::walk(mixed object_id [, bool $suffix_as_key = FALSE [, int $non_repeaters [, int $max_repetitions ]]]) Return all objects including their respective object id withing the specified one as array of oid->value pairs */ PHP_METHOD(snmp, walk) { From 5ba64c511f8d643d704c18bcd5e6d0a371919592 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sun, 17 Jul 2011 14:31:32 +0000 Subject: [PATCH 0321/2394] backport r313323 and r313326 from PHP_5_4 --- sapi/fpm/fpm/fpm_children.c | 17 ++++++++++++++++- sapi/fpm/fpm/fpm_conf.c | 10 +++++++++- sapi/fpm/fpm/fpm_conf.h | 1 + sapi/fpm/php-fpm.conf.in | 7 +++++++ 4 files changed, 33 insertions(+), 2 deletions(-) diff --git a/sapi/fpm/fpm/fpm_children.c b/sapi/fpm/fpm/fpm_children.c index 65f56e7269b15..769c519a85600 100644 --- a/sapi/fpm/fpm/fpm_children.c +++ b/sapi/fpm/fpm/fpm_children.c @@ -363,6 +363,7 @@ int fpm_children_make(struct fpm_worker_pool_s *wp, int in_event_loop, int nb_to pid_t pid; struct fpm_child_s *child; int max; + static int warned = 0; if (wp->config->pm == PM_STYLE_DYNAMIC) { if (!in_event_loop) { /* starting */ @@ -374,7 +375,16 @@ int fpm_children_make(struct fpm_worker_pool_s *wp, int in_event_loop, int nb_to max = wp->config->pm_max_children; } - while (fpm_pctl_can_spawn_children() && wp->running_children < max) { + /* + * fork children while: + * - fpm_pctl_can_spawn_children : FPM is running in a NORMAL state (aka not restart, stop or reload) + * - wp->running_children < max : there is less than the max process for the current pool + * - (fpm_global_config.process_max < 1 || fpm_globals.running_children < fpm_global_config.process_max): + * if fpm_global_config.process_max is set, FPM has not fork this number of processes (globaly) + */ + while (fpm_pctl_can_spawn_children() && wp->running_children < max && (fpm_global_config.process_max < 1 || fpm_globals.running_children < fpm_global_config.process_max)) { + + warned = 0; child = fpm_resources_prepare(wp); if (!child) { @@ -407,6 +417,11 @@ int fpm_children_make(struct fpm_worker_pool_s *wp, int in_event_loop, int nb_to } + if (!warned && fpm_global_config.process_max > 0 && fpm_globals.running_children >= fpm_global_config.process_max) { + warned = 1; + zlog(ZLOG_WARNING, "The maximum number of processes has been reached. Please review your configuration and consider raising 'process.max'"); + } + return 1; /* we are done */ } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index a7ad4d2551169..b1958af30bb45 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -66,8 +66,9 @@ static char *fpm_conf_set_syslog_facility(zval *value, void **config, intptr_t o struct fpm_global_config_s fpm_global_config = { .daemonize = 1, #ifdef HAVE_SYSLOG_H - .syslog_facility = -1 + .syslog_facility = -1, #endif + .process_max = 0, }; static struct fpm_worker_pool_s *current_wp = NULL; static int ini_recursion = 0; @@ -79,6 +80,7 @@ static struct ini_value_parser_s ini_fpm_global_options[] = { { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, + { "process.max", &fpm_conf_set_integer, GO(process_max) }, { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, { "pid", &fpm_conf_set_string, GO(pid_file) }, { "error_log", &fpm_conf_set_string, GO(error_log) }, @@ -962,6 +964,11 @@ static int fpm_conf_post_process(TSRMLS_D) /* {{{ */ fpm_globals.log_level = fpm_global_config.log_level; + if (fpm_global_config.process_max < 0) { + zlog(ZLOG_ERROR, "process_max can't be negative"); + return -1; + } + if (!fpm_global_config.error_log) { fpm_global_config.error_log = strdup("log/php-fpm.log"); } @@ -1342,6 +1349,7 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tsyslog.facility = %d", fpm_global_config.syslog_facility); /* FIXME: convert to string */ #endif zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); + zlog(ZLOG_NOTICE, "\tprocess.max = %d", fpm_global_config.process_max); zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval); zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold); zlog(ZLOG_NOTICE, "\trlimit_files = %d", fpm_global_config.rlimit_files); diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index 87a5cd332b6f3..bbfcbb8a775e3 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -32,6 +32,7 @@ struct fpm_global_config_s { #endif int rlimit_files; int rlimit_core; + int process_max; }; extern struct fpm_global_config_s fpm_global_config; diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index b3151c0a99950..ecc71313323a5 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -69,6 +69,13 @@ ; Default Value: 0 ;process_control_timeout = 0 +; The maximum number of processes FPM will fork. This has been design to control +; the global number of processes when using dynamic PM within a lot of pools. +; Use it with caution. +; Note: A value of 0 indicates no limit +; Default Value: 0 +; process.max = 128 + ; Send FPM to background. Set to 'no' to keep FPM in foreground for debugging. ; Default Value: yes ;daemonize = yes From a3592145f81b5bd8a5be8cc5c54469c2b6be3807 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sun, 17 Jul 2011 14:42:58 +0000 Subject: [PATCH 0322/2394] backport r313186 from PHP_5_4 --- sapi/fpm/fpm/fpm_conf.c | 53 ++++++++++++++++++++++++++++++++++ sapi/fpm/fpm/fpm_conf.h | 1 + sapi/fpm/fpm/fpm_main.c | 6 ++++ sapi/fpm/fpm/fpm_php.c | 34 ++++++++++++++++++++++ sapi/fpm/fpm/fpm_php.h | 1 + sapi/fpm/fpm/fpm_worker_pool.h | 1 + sapi/fpm/php-fpm.conf.in | 8 +++++ 7 files changed, 104 insertions(+) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index b1958af30bb45..edb514f1be419 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -123,6 +123,7 @@ static struct ini_value_parser_s ini_fpm_pool_options[] = { { "ping.response", &fpm_conf_set_string, WPO(ping_response) }, { "access.log", &fpm_conf_set_string, WPO(access_log) }, { "access.format", &fpm_conf_set_string, WPO(access_format) }, + { "security.limit_extensions", &fpm_conf_set_string, WPO(security_limit_extensions) }, { 0, 0, 0 } }; @@ -601,6 +602,7 @@ int fpm_worker_pool_config_free(struct fpm_worker_pool_config_s *wpc) /* {{{ */ free(wpc->prefix); free(wpc->access_log); free(wpc->access_format); + free(wpc->security_limit_extensions); return 0; } @@ -847,6 +849,56 @@ static int fpm_conf_process_all_pools() /* {{{ */ } } + if (!wp->config->security_limit_extensions) { + wp->config->security_limit_extensions = strdup(".php"); + } + + if (*wp->config->security_limit_extensions) { + int nb_ext; + char *ext; + char *security_limit_extensions; + char *limit_extensions; + + + /* strdup because strtok(3) alters the string it parses */ + security_limit_extensions = strdup(wp->config->security_limit_extensions); + limit_extensions = security_limit_extensions; + nb_ext = 0; + + /* find the number of extensions */ + while ((ext = strtok(limit_extensions, " \t"))) { + limit_extensions = NULL; + nb_ext++; + } + free(security_limit_extensions); + + /* if something found */ + if (nb_ext > 0) { + + /* malloc the extension array */ + wp->limit_extensions = malloc(sizeof(char *) * (nb_ext + 1)); + if (!wp->limit_extensions) { + zlog(ZLOG_ERROR, "[pool %s] unable to malloc extensions array", wp->config->name); + return -1; + } + + /* strdup because strtok(3) alters the string it parses */ + security_limit_extensions = strdup(wp->config->security_limit_extensions); + limit_extensions = security_limit_extensions; + nb_ext = 0; + + /* parse the string and save the extension in the array */ + while ((ext = strtok(security_limit_extensions, " \t"))) { + security_limit_extensions = NULL; + wp->limit_extensions[nb_ext++] = strdup(ext); + } + + /* end the array with NULL in order to parse it */ + wp->limit_extensions[nb_ext] = NULL; + free(security_limit_extensions); + } + } + if (wp->config->chroot && *wp->config->chroot) { fpm_evaluate_full_path(&wp->config->chroot, wp, NULL, 1); @@ -1388,6 +1440,7 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tslowlog = %s", STR2STR(wp->config->slowlog)); zlog(ZLOG_NOTICE, "\trlimit_files = %d", wp->config->rlimit_files); zlog(ZLOG_NOTICE, "\trlimit_core = %d", wp->config->rlimit_core); + zlog(ZLOG_NOTICE, "\tsecurity.limit_extensions = %s", wp->config->security_limit_extensions); for (kv = wp->config->env; kv; kv = kv->next) { zlog(ZLOG_NOTICE, "\tenv[%s] = %s", kv->key, kv->value); diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index bbfcbb8a775e3..11c688ae7b4db 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -67,6 +67,7 @@ struct fpm_worker_pool_config_s { char *listen_group; char *listen_mode; char *listen_allowed_clients; + char *security_limit_extensions; struct key_value_s *env; struct key_value_s *php_admin_values; struct key_value_s *php_values; diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 7dbd6c00c9a51..06370d855ce04 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1879,6 +1879,12 @@ consult the installation file that came with this distribution, or visit \n\ goto fastcgi_request_done; } + if (fpm_php_limit_extensions(SG(request_info).path_translated)) { + SG(sapi_headers).http_response_code = 403; + PUTS("Access denied.\n"); + goto fastcgi_request_done; + } + /* path_translated exists, we can continue ! */ if (php_fopen_primary_script(&file_handle TSRMLS_CC) == FAILURE) { zend_try { diff --git a/sapi/fpm/fpm/fpm_php.c b/sapi/fpm/fpm/fpm_php.c index 33b9e410e1fff..f320f5148e6be 100644 --- a/sapi/fpm/fpm/fpm_php.c +++ b/sapi/fpm/fpm/fpm_php.c @@ -19,6 +19,9 @@ #include "fpm_php.h" #include "fpm_cleanup.h" #include "fpm_worker_pool.h" +#include "zlog.h" + +static char **limit_extensions = NULL; static int fpm_php_zend_ini_alter_master(char *name, int name_length, char *new_value, int new_value_length, int mode, int stage TSRMLS_DC) /* {{{ */ { @@ -219,7 +222,38 @@ int fpm_php_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ 0 > fpm_php_set_allowed_clients(wp)) { return -1; } + + if (wp->limit_extensions) { + limit_extensions = wp->limit_extensions; + } return 0; } /* }}} */ +int fpm_php_limit_extensions(char *path) /* {{{ */ +{ + char **p; + size_t path_len; + + if (!path || !limit_extensions) { + return 0; /* allowed by default */ + } + + p = limit_extensions; + path_len = strlen(path); + while (p && *p) { + size_t ext_len = strlen(*p); + if (path_len > ext_len) { + char *path_ext = path + path_len - ext_len; + if (strcmp(*p, path_ext) == 0) { + return 0; /* allow as the extension has been found */ + } + } + p++; + } + + + zlog(ZLOG_NOTICE, "Access to the file '%s' has been denied (see security.limit_extensions)", path); + return 1; /* extension not found: not allowed */ +} +/* }}} */ diff --git a/sapi/fpm/fpm/fpm_php.h b/sapi/fpm/fpm/fpm_php.h index 62a47e7fd37b3..a2c7ed318a092 100644 --- a/sapi/fpm/fpm/fpm_php.h +++ b/sapi/fpm/fpm/fpm_php.h @@ -43,6 +43,7 @@ size_t fpm_php_content_length(TSRMLS_D); void fpm_php_soft_quit(); int fpm_php_init_main(); int fpm_php_apply_defines_ex(struct key_value_s *kv, int mode); +int fpm_php_limit_extensions(char *path); #endif diff --git a/sapi/fpm/fpm/fpm_worker_pool.h b/sapi/fpm/fpm/fpm_worker_pool.h index 098def5b7e276..100c3689cb6ed 100644 --- a/sapi/fpm/fpm/fpm_worker_pool.h +++ b/sapi/fpm/fpm/fpm_worker_pool.h @@ -37,6 +37,7 @@ struct fpm_worker_pool_s { #endif struct fpm_scoreboard_s *scoreboard; int log_fd; + char **limit_extensions; }; struct fpm_worker_pool_s *fpm_worker_pool_alloc(); diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index ecc71313323a5..76a1c36368b9a 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -428,6 +428,14 @@ pm.max_spare_servers = 3 ; process time (several ms). ; Default Value: no ;catch_workers_output = yes + +; Limits the extensions of the main script FPM will allow to parse. This can +; prevent configuration mistakes on the web server side. You should only limit +; FPM to .php extensions to prevent malicious users to use other extensions to +; exectute php code. +; Note: set an empty value to allow all extensions. +; Default Value: .php +;security.limit_extensions = .php .php3 .php4 .php5 ; Pass environment variables like LD_LIBRARY_PATH. All $VARIABLEs are taken from ; the current environment. From a80c2ee19b6534b54780703cb5fc4ba5071dadd3 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 17 Jul 2011 17:27:00 +0000 Subject: [PATCH 0323/2394] fix FR #54502: allow user to change OID value output mode when SNMP_VALUE_OBJECT is used. --- NEWS | 3 + UPGRADING | 7 + ext/snmp/snmp.c | 177 ++++++++++---------- ext/snmp/tests/snmp_get_valueretrieval.phpt | 14 +- ext/snmp/tests/snmp_getvalue.phpt | 37 ++++ 5 files changed, 144 insertions(+), 94 deletions(-) diff --git a/NEWS b/NEWS index 9bc1b7da0cc93..7a792084906f4 100644 --- a/NEWS +++ b/NEWS @@ -221,6 +221,9 @@ PHP NEWS . Allow ~infinite OIDs in GET/GETNEXT/SET queries. Autochunk them to max_oids upon request. . Introducing unit tests for extension with ~full coverage. + . Way of representing OID value can now be changed when SNMP_VALUE_OBJECT + is used for value output mode. Use or'ed SNMP_VALUE_LIBRARY(default if + not specified) or SNMP_VALUE_PLAIN. (FR #54502) . Fixed bugs . #44193 (snmp v3 noAuthNoPriv doesn't work) . #45893 (Snmp buffer limited to 2048 char) diff --git a/UPGRADING b/UPGRADING index 534e8bf5b7c12..9fec6dd689b60 100755 --- a/UPGRADING +++ b/UPGRADING @@ -283,6 +283,13 @@ UPGRADE NOTES - PHP X.Y - Multi OID get/getnext/set queries are now supported. - New constants added for use in snmp_set_oid_output_format() function. + - Function snmp_set_valueretrieval() changed it's behaviour: + SNMP_VALUE_OBJECT can be combined with one of + SNMP_VALUE_PLAIN or SNMP_VALUE_LIBRARY resulting OID value + changes. When no SNMP_VALUE_PLAIN or SNMP_VALUE_LIBRARY + is supplied with SNMP_VALUE_OBJECT, SNMP_VALUE_LIBRARY is used. + Prior to 5.4.0 when no SNMP_VALUE_PLAIN or SNMP_VALUE_LIBRARY + was supplied with SNMP_VALUE_OBJECT, SNMP_VALUE_PLAIN was used. - Added feature-rich OO API (SNMP class) - Dropped UCD-SNMP compatibility code. Consider upgrading to net-snmp v5.3+. Net-SNMP v5.4+ is required for Windows version. diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 529be7e4a5e2c..7507640debb9c 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -94,9 +94,9 @@ extern netsnmp_log_handler *logh_head; } #endif -#define SNMP_VALUE_LIBRARY 0 -#define SNMP_VALUE_PLAIN 1 -#define SNMP_VALUE_OBJECT 2 +#define SNMP_VALUE_LIBRARY (0 << 0) +#define SNMP_VALUE_PLAIN (1 << 0) +#define SNMP_VALUE_OBJECT (1 << 1) typedef struct snmp_session php_snmp_session; #define PHP_SNMP_SESSION_RES_NAME "SNMP session" @@ -559,7 +559,7 @@ static void php_snmp_getvalue(struct variable_list *vars, zval *snmpval TSRMLS_D int buflen = sizeof(sbuf) - 1; int val_len = vars->val_len; - if (valueretrieval == SNMP_VALUE_LIBRARY) { + if ((valueretrieval & SNMP_VALUE_PLAIN) == 0) { val_len += 32; /* snprint_value will add type info into value, make some space for it */ } @@ -575,96 +575,92 @@ static void php_snmp_getvalue(struct variable_list *vars, zval *snmpval TSRMLS_D *buf = 0; - if (valueretrieval == SNMP_VALUE_LIBRARY) { - snprint_value(buf, buflen, vars->name, vars->name_length, vars); - ZVAL_STRING(snmpval, buf, 1); - if(dbuf){ /* malloc was used to store value */ - efree(dbuf); - } - return; - } - MAKE_STD_ZVAL(val); - switch (vars->type) { - case ASN_BIT_STR: /* 0x03, asn1.h */ - ZVAL_STRINGL(val, (char *)vars->val.bitstring, vars->val_len, 1); - break; + if (valueretrieval & SNMP_VALUE_PLAIN) { + switch (vars->type) { + case ASN_BIT_STR: /* 0x03, asn1.h */ + ZVAL_STRINGL(val, (char *)vars->val.bitstring, vars->val_len, 1); + break; - case ASN_OCTET_STR: /* 0x04, asn1.h */ - case ASN_OPAQUE: /* 0x44, snmp_impl.h */ - ZVAL_STRINGL(val, (char *)vars->val.string, vars->val_len, 1); - break; + case ASN_OCTET_STR: /* 0x04, asn1.h */ + case ASN_OPAQUE: /* 0x44, snmp_impl.h */ + ZVAL_STRINGL(val, (char *)vars->val.string, vars->val_len, 1); + break; - case ASN_NULL: /* 0x05, asn1.h */ - ZVAL_NULL(val); - break; + case ASN_NULL: /* 0x05, asn1.h */ + ZVAL_NULL(val); + break; - case ASN_OBJECT_ID: /* 0x06, asn1.h */ - snprint_objid(buf, buflen, vars->val.objid, vars->val_len / sizeof(oid)); - ZVAL_STRING(val, buf, 1); - break; + case ASN_OBJECT_ID: /* 0x06, asn1.h */ + snprint_objid(buf, buflen, vars->val.objid, vars->val_len / sizeof(oid)); + ZVAL_STRING(val, buf, 1); + break; - case ASN_IPADDRESS: /* 0x40, snmp_impl.h */ - snprintf(buf, buflen, "%d.%d.%d.%d", - (vars->val.string)[0], (vars->val.string)[1], - (vars->val.string)[2], (vars->val.string)[3]); - buf[buflen]=0; - ZVAL_STRING(val, buf, 1); - break; - - case ASN_COUNTER: /* 0x41, snmp_impl.h */ - case ASN_GAUGE: /* 0x42, snmp_impl.h */ - /* ASN_UNSIGNED is the same as ASN_GAUGE */ - case ASN_TIMETICKS: /* 0x43, snmp_impl.h */ - case ASN_UINTEGER: /* 0x47, snmp_impl.h */ - snprintf(buf, buflen, "%lu", *vars->val.integer); - buf[buflen]=0; - ZVAL_STRING(val, buf, 1); - break; + case ASN_IPADDRESS: /* 0x40, snmp_impl.h */ + snprintf(buf, buflen, "%d.%d.%d.%d", + (vars->val.string)[0], (vars->val.string)[1], + (vars->val.string)[2], (vars->val.string)[3]); + buf[buflen]=0; + ZVAL_STRING(val, buf, 1); + break; - case ASN_INTEGER: /* 0x02, asn1.h */ - snprintf(buf, buflen, "%ld", *vars->val.integer); - buf[buflen]=0; - ZVAL_STRING(val, buf, 1); - break; + case ASN_COUNTER: /* 0x41, snmp_impl.h */ + case ASN_GAUGE: /* 0x42, snmp_impl.h */ + /* ASN_UNSIGNED is the same as ASN_GAUGE */ + case ASN_TIMETICKS: /* 0x43, snmp_impl.h */ + case ASN_UINTEGER: /* 0x47, snmp_impl.h */ + snprintf(buf, buflen, "%lu", *vars->val.integer); + buf[buflen]=0; + ZVAL_STRING(val, buf, 1); + break; + + case ASN_INTEGER: /* 0x02, asn1.h */ + snprintf(buf, buflen, "%ld", *vars->val.integer); + buf[buflen]=0; + ZVAL_STRING(val, buf, 1); + break; #if defined(NETSNMP_WITH_OPAQUE_SPECIAL_TYPES) || defined(OPAQUE_SPECIAL_TYPES) - case ASN_OPAQUE_FLOAT: /* 0x78, asn1.h */ - snprintf(buf, buflen, "%f", *vars->val.floatVal); - ZVAL_STRING(val, buf, 1); - break; + case ASN_OPAQUE_FLOAT: /* 0x78, asn1.h */ + snprintf(buf, buflen, "%f", *vars->val.floatVal); + ZVAL_STRING(val, buf, 1); + break; - case ASN_OPAQUE_DOUBLE: /* 0x79, asn1.h */ - snprintf(buf, buflen, "%Lf", *vars->val.doubleVal); - ZVAL_STRING(val, buf, 1); - break; + case ASN_OPAQUE_DOUBLE: /* 0x79, asn1.h */ + snprintf(buf, buflen, "%Lf", *vars->val.doubleVal); + ZVAL_STRING(val, buf, 1); + break; - case ASN_OPAQUE_I64: /* 0x80, asn1.h */ - printI64(buf, vars->val.counter64); - ZVAL_STRING(val, buf, 1); - break; + case ASN_OPAQUE_I64: /* 0x80, asn1.h */ + printI64(buf, vars->val.counter64); + ZVAL_STRING(val, buf, 1); + break; - case ASN_OPAQUE_U64: /* 0x81, asn1.h */ + case ASN_OPAQUE_U64: /* 0x81, asn1.h */ #endif - case ASN_COUNTER64: /* 0x46, snmp_impl.h */ - printU64(buf, vars->val.counter64); - ZVAL_STRING(val, buf, 1); - break; + case ASN_COUNTER64: /* 0x46, snmp_impl.h */ + printU64(buf, vars->val.counter64); + ZVAL_STRING(val, buf, 1); + break; - default: - ZVAL_STRING(val, "Unknown value type", 1); - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown value type: %u", vars->type); - break; + default: + ZVAL_STRING(val, "Unknown value type", 1); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown value type: %u", vars->type); + break; + } + } else /* use Net-SNMP value translation */ { + snprint_value(buf, buflen, vars->name, vars->name_length, vars); + ZVAL_STRING(val, buf, 1); } - if (valueretrieval == SNMP_VALUE_PLAIN) { - *snmpval = *val; - zval_copy_ctor(snmpval); - } else { + if (valueretrieval & SNMP_VALUE_OBJECT) { object_init(snmpval); add_property_long(snmpval, "type", vars->type); add_property_zval(snmpval, "value", val); + } else { + *snmpval = *val; + zval_copy_ctor(snmpval); } zval_ptr_dtor(&val); @@ -1655,16 +1651,12 @@ PHP_FUNCTION(snmp_set_valueretrieval) RETURN_FALSE; } - switch(method) { - case SNMP_VALUE_LIBRARY: - case SNMP_VALUE_PLAIN: - case SNMP_VALUE_OBJECT: + if (method >= 0 && method <= (SNMP_VALUE_LIBRARY|SNMP_VALUE_PLAIN|SNMP_VALUE_OBJECT)) { SNMP_G(valueretrieval) = method; RETURN_TRUE; - break; - default: - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown SNMP value retrieval method '%ld'", method); - RETURN_FALSE; + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown SNMP value retrieval method '%ld'", method); + RETURN_FALSE; } } /* }}} */ @@ -1673,6 +1665,10 @@ PHP_FUNCTION(snmp_set_valueretrieval) Return the method how the SNMP values will be returned */ PHP_FUNCTION(snmp_get_valueretrieval) { + if (zend_parse_parameters_none() == FAILURE) { + RETURN_FALSE; + } + RETURN_LONG(SNMP_G(valueretrieval)); } /* }}} */ @@ -2200,16 +2196,11 @@ static int php_snmp_write_valueretrieval(php_snmp_object *snmp_object, zval *new newval = &ztmp; } - switch(Z_LVAL_P(newval)) { - case SNMP_VALUE_LIBRARY: - case SNMP_VALUE_PLAIN: - case SNMP_VALUE_OBJECT: - snmp_object->valueretrieval = Z_LVAL_P(newval); - break; - default: - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown SNMP value retrieval method '%ld'", Z_LVAL_P(newval)); - ret = FAILURE; - break; + if (Z_LVAL_P(newval) >= 0 && Z_LVAL_P(newval) <= (SNMP_VALUE_LIBRARY|SNMP_VALUE_PLAIN|SNMP_VALUE_OBJECT)) { + snmp_object->valueretrieval = Z_LVAL_P(newval); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown SNMP value retrieval method '%ld'", Z_LVAL_P(newval)); + ret = FAILURE; } if (newval == &ztmp) { diff --git a/ext/snmp/tests/snmp_get_valueretrieval.phpt b/ext/snmp/tests/snmp_get_valueretrieval.phpt index 90bd0bab6407f..660d643e41d00 100644 --- a/ext/snmp/tests/snmp_get_valueretrieval.phpt +++ b/ext/snmp/tests/snmp_get_valueretrieval.phpt @@ -12,6 +12,7 @@ require_once(dirname(__FILE__).'/snmp_include.inc'); echo "Checking error handling\n"; var_dump(snmp_get_valueretrieval('noarg')); +var_dump(snmp_set_valueretrieval()); var_dump(snmp_set_valueretrieval('noarg')); var_dump(snmp_set_valueretrieval(67)); @@ -23,11 +24,20 @@ snmp_set_valueretrieval(SNMP_VALUE_PLAIN); var_dump(snmp_get_valueretrieval() === SNMP_VALUE_PLAIN); snmp_set_valueretrieval(SNMP_VALUE_OBJECT); var_dump(snmp_get_valueretrieval() === SNMP_VALUE_OBJECT); +snmp_set_valueretrieval(SNMP_VALUE_PLAIN|SNMP_VALUE_OBJECT); +var_dump(snmp_get_valueretrieval() === (SNMP_VALUE_PLAIN|SNMP_VALUE_OBJECT)); +snmp_set_valueretrieval(SNMP_VALUE_LIBRARY|SNMP_VALUE_OBJECT); +var_dump(snmp_get_valueretrieval() === (SNMP_VALUE_LIBRARY|SNMP_VALUE_OBJECT)); ?> --EXPECTF-- Checking error handling -int(%d) + +Warning: snmp_get_valueretrieval() expects exactly 0 parameters, 1 given in %s on line %d +bool(false) + +Warning: snmp_set_valueretrieval() expects exactly 1 parameter, 0 given in %s on line %d +bool(false) Warning: snmp_set_valueretrieval() expects parameter 1 to be long, %s given in %s on line %d bool(false) @@ -39,3 +49,5 @@ int(%d) bool(true) bool(true) bool(true) +bool(true) +bool(true) diff --git a/ext/snmp/tests/snmp_getvalue.phpt b/ext/snmp/tests/snmp_getvalue.phpt index 0eefbb335e8f4..178354a8cfbc7 100644 --- a/ext/snmp/tests/snmp_getvalue.phpt +++ b/ext/snmp/tests/snmp_getvalue.phpt @@ -28,6 +28,29 @@ echo gettype($z)."\n"; var_dump($z->type); var_dump($z->value); +echo "Get with SNMP_VALUE_OBJECT | SNMP_VALUE_PLAIN\n"; +snmp_set_valueretrieval(SNMP_VALUE_OBJECT | SNMP_VALUE_PLAIN); +$z = snmpget($hostname, $community, '.1.3.6.1.2.1.1.1.0', $timeout, $retries); +echo gettype($z)."\n"; +var_dump($z->type); +var_dump($z->value); + +echo "Get with SNMP_VALUE_OBJECT for BITS OID\n"; +snmp_set_valueretrieval(SNMP_VALUE_OBJECT); +$z = snmpget($hostname, $community, '.1.3.6.1.2.1.88.1.4.2.1.3.6.95.115.110.109.112.100.95.108.105.110.107.68.111.119.110', $timeout, $retries); +echo gettype($z)."\n"; +var_dump($z->type); +var_dump($z->value); + +echo "Get with SNMP_VALUE_OBJECT | SNMP_VALUE_PLAIN for BITS OID\n"; +snmp_set_valueretrieval(SNMP_VALUE_OBJECT | SNMP_VALUE_PLAIN); +$z = snmpget($hostname, $community, '.1.3.6.1.2.1.88.1.4.2.1.3.6.95.115.110.109.112.100.95.108.105.110.107.68.111.119.110', $timeout, $retries); +echo gettype($z)."\n"; +var_dump($z->type); +var_dump(is_numeric($z->value)); +var_dump(is_string($z->value)); +var_dump(bin2hex($z->value)); + echo "Check parsing of different OID types\n"; snmp_set_valueretrieval(SNMP_VALUE_PLAIN); var_dump(count(snmp2_walk($hostname, $community, '.', $timeout, $retries))); @@ -41,6 +64,20 @@ string(%d) "%s" Get with SNMP_VALUE_OBJECT object int(4) +string(%d) "STRING: %s" +Get with SNMP_VALUE_OBJECT | SNMP_VALUE_PLAIN +object +int(4) string(%d) "%s" +Get with SNMP_VALUE_OBJECT for BITS OID +object +int(4) +string(25) "BITS: %d %s" +Get with SNMP_VALUE_OBJECT | SNMP_VALUE_PLAIN for BITS OID +object +int(4) +bool(false) +bool(true) +string(2) "%d" Check parsing of different OID types int(%d) From e1d4676065f8ba63197acb75e7a1f1242c4f633b Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 17 Jul 2011 18:17:43 +0000 Subject: [PATCH 0324/2394] swap non_repeaters and max_repetitions in walk query, max_repetitions whould be used more frequently --- ext/snmp/snmp.c | 6 +++--- ext/snmp/tests/snmp-object-error.phpt | 2 +- ext/snmp/tests/snmp-object.phpt | 12 ++++++------ 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 7507640debb9c..cbbee99e59b10 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -353,8 +353,8 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_snmp_walk, 0, 0, 4) ZEND_ARG_INFO(0, object_id) ZEND_ARG_INFO(0, suffix_keys) - ZEND_ARG_INFO(0, non_repeaters) ZEND_ARG_INFO(0, max_repetitions) + ZEND_ARG_INFO(0, non_repeaters) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_snmp_set, 0, 0, 3) @@ -1370,7 +1370,7 @@ static void php_snmp(INTERNAL_FUNCTION_PARAMETERS, int st, int version) RETURN_FALSE; } } else if (st & SNMP_CMD_WALK) { - if (zend_parse_parameters(argc TSRMLS_CC, "Z|bll", &oid, &suffix_keys, &(objid_query.non_repeaters), &(objid_query.max_repetitions)) == FAILURE) { + if (zend_parse_parameters(argc TSRMLS_CC, "Z|bll", &oid, &suffix_keys, &(objid_query.max_repetitions), &(objid_query.non_repeaters)) == FAILURE) { RETURN_FALSE; } if (suffix_keys) { @@ -1792,7 +1792,7 @@ PHP_METHOD(snmp, getnext) } /* }}} */ -/* {{{ proto mixed SNMP::walk(mixed object_id [, bool $suffix_as_key = FALSE [, int $non_repeaters [, int $max_repetitions ]]]) +/* {{{ proto mixed SNMP::walk(mixed object_id [, bool $suffix_as_key = FALSE [, int $max_repetitions [, int $non_repeaters]]) Return all objects including their respective object id withing the specified one as array of oid->value pairs */ PHP_METHOD(snmp, walk) { diff --git a/ext/snmp/tests/snmp-object-error.phpt b/ext/snmp/tests/snmp-object-error.phpt index 00db3a318c5c8..83ba2b72631c6 100644 --- a/ext/snmp/tests/snmp-object-error.phpt +++ b/ext/snmp/tests/snmp-object-error.phpt @@ -47,7 +47,7 @@ var_dump($session->close()); $session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); var_dump($session->walk('.1.3.6.1.2.1.1', FALSE, '')); -var_dump($session->walk('.1.3.6.1.2.1.1', FALSE, 0, '')); +var_dump($session->walk('.1.3.6.1.2.1.1', FALSE, 30, '')); var_dump($session->get()); var_dump($session->getnext()); var_dump($session->set()); diff --git a/ext/snmp/tests/snmp-object.phpt b/ext/snmp/tests/snmp-object.phpt index 684391b461e84..7830ec2cd7481 100644 --- a/ext/snmp/tests/snmp-object.phpt +++ b/ext/snmp/tests/snmp-object.phpt @@ -48,18 +48,18 @@ var_dump(key($z)); var_dump(array_shift($z)); var_dump($session->close()); -echo "WALK multiple on single OID, non_repeaters set to 0\n"; +echo "WALK multiple on single OID, max_repetitions set to 30\n"; $session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); -$z = $session->walk('.1.3.6.1.2.1.1', 0); +$z = $session->walk('.1.3.6.1.2.1.1', FALSE, 30); var_dump(gettype($z)); var_dump(count($z)); var_dump(key($z)); var_dump(array_shift($z)); var_dump($session->close()); -echo "WALK multiple on single OID, non_repeaters set to 0, max_repetitions set to 30\n"; +echo "WALK multiple on single OID, max_repetitions set to 30, non_repeaters set to 0\n"; $session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); -$z = $session->walk('.1.3.6.1.2.1.1', 0, 30); +$z = $session->walk('.1.3.6.1.2.1.1', FALSE, 30, 0); var_dump(gettype($z)); var_dump(count($z)); var_dump(key($z)); @@ -154,13 +154,13 @@ int(%d) string(%d) "%S" string(%d) "%S" bool(true) -WALK multiple on single OID, non_repeaters set to 0 +WALK multiple on single OID, max_repetitions set to 30 string(5) "array" int(%d) string(%d) "%S" string(%d) "%S" bool(true) -WALK multiple on single OID, non_repeaters set to 0, max_repetitions set to 30 +WALK multiple on single OID, max_repetitions set to 30, non_repeaters set to 0 string(5) "array" int(%d) string(%d) "%S" From 5c110b9a76febcecb9c81e7ff7449dc3d59b1999 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sun, 17 Jul 2011 19:45:05 +0000 Subject: [PATCH 0325/2394] new propery noOIDIncreasingCheck allowing to skip OID increasing check (userful for bogus SNMP agents) --- ext/snmp/php_snmp.h | 1 + ext/snmp/snmp.c | 114 ++++++++------------- ext/snmp/tests/snmp-object-properties.phpt | 10 ++ 3 files changed, 55 insertions(+), 70 deletions(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index 7ba07e005f0e0..e7b3576ee5de6 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -93,6 +93,7 @@ typedef struct _php_snmp_object { int enum_print; int oid_output_format; int snmp_errno; + int noOIDIncreasingCheck; char snmp_errstr[128]; } php_snmp_object; diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index cbbee99e59b10..58f5e52427714 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -376,6 +376,7 @@ struct objid_query { long max_repetitions; int valueretrieval; int array_output; + int noOIDIncreasingCheck; snmpobjarg *vars; }; @@ -878,7 +879,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, /* OID increase check */ if (st & SNMP_CMD_WALK) { - if (snmp_oid_compare(name, name_length, vars->name, vars->name_length) >= 0) { + if (objid_query->noOIDIncreasingCheck == FALSE && snmp_oid_compare(name, name_length, vars->name, vars->name_length) >= 0) { snprint_objid(buf2, sizeof(buf2), vars->name, vars->name_length); php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_NOT_INCREASING, "Error: OID not increasing: %s", buf2); keepwalking = 0; @@ -1331,6 +1332,7 @@ static void php_snmp(INTERNAL_FUNCTION_PARAMETERS, int st, int version) objid_query.max_repetitions = -1; objid_query.non_repeaters = 0; objid_query.valueretrieval = SNMP_G(valueretrieval); + objid_query.noOIDIncreasingCheck = FALSE; if (session_less_mode) { if (version == SNMP_VERSION_3) { @@ -1424,6 +1426,7 @@ static void php_snmp(INTERNAL_FUNCTION_PARAMETERS, int st, int version) objid_query.max_repetitions = snmp_object->max_oids; } } + objid_query.noOIDIncreasingCheck = snmp_object->noOIDIncreasingCheck; objid_query.valueretrieval = snmp_object->valueretrieval; glob_snmp_object.enum_print = netsnmp_ds_get_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_PRINT_NUMERIC_ENUM); netsnmp_ds_set_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_PRINT_NUMERIC_ENUM, snmp_object->enum_print); @@ -2107,41 +2110,28 @@ static int php_snmp_read_max_oids(php_snmp_object *snmp_object, zval **retval TS } /* }}} */ -/* {{{ */ -static int php_snmp_read_valueretrieval(php_snmp_object *snmp_object, zval **retval TSRMLS_DC) -{ - MAKE_STD_ZVAL(*retval); - ZVAL_LONG(*retval, snmp_object->valueretrieval); - return SUCCESS; -} -/* }}} */ +#define PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(name) \ + static int php_snmp_read_##name(php_snmp_object *snmp_object, zval **retval TSRMLS_DC) \ + { \ + MAKE_STD_ZVAL(*retval); \ + ZVAL_BOOL(*retval, snmp_object->name); \ + return SUCCESS; \ + } -/* {{{ */ -static int php_snmp_read_quick_print(php_snmp_object *snmp_object, zval **retval TSRMLS_DC) -{ - MAKE_STD_ZVAL(*retval); - ZVAL_BOOL(*retval, snmp_object->quick_print); - return SUCCESS; -} -/* }}} */ +PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(noOIDIncreasingCheck) +PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(quick_print) +PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(enum_print) -/* {{{ */ -static int php_snmp_read_enum_print(php_snmp_object *snmp_object, zval **retval TSRMLS_DC) -{ - MAKE_STD_ZVAL(*retval); - ZVAL_BOOL(*retval, snmp_object->enum_print); - return SUCCESS; -} -/* }}} */ +#define PHP_SNMP_LONG_PROPERTY_READER_FUNCTION(name) \ + static int php_snmp_read_##name(php_snmp_object *snmp_object, zval **retval TSRMLS_DC) \ + { \ + MAKE_STD_ZVAL(*retval); \ + ZVAL_LONG(*retval, snmp_object->name); \ + return SUCCESS; \ + } -/* {{{ */ -static int php_snmp_read_oid_output_format(php_snmp_object *snmp_object, zval **retval TSRMLS_DC) -{ - MAKE_STD_ZVAL(*retval); - ZVAL_LONG(*retval, snmp_object->oid_output_format); - return SUCCESS; -} -/* }}} */ +PHP_SNMP_LONG_PROPERTY_READER_FUNCTION(valueretrieval) +PHP_SNMP_LONG_PROPERTY_READER_FUNCTION(oid_output_format) /* {{{ */ static int php_snmp_write_info(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) @@ -2211,45 +2201,28 @@ static int php_snmp_write_valueretrieval(php_snmp_object *snmp_object, zval *new } /* }}} */ -/* {{{ */ -static int php_snmp_write_quick_print(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) -{ - zval ztmp; - if (Z_TYPE_P(newval) != IS_BOOL) { - ztmp = *newval; - zval_copy_ctor(&ztmp); - convert_to_boolean(&ztmp); - newval = &ztmp; - } - - snmp_object->quick_print = Z_LVAL_P(newval); - - if (newval == &ztmp) { - zval_dtor(newval); - } - return SUCCESS; +#define PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(name) \ +static int php_snmp_write_##name(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) \ +{ \ + zval ztmp; \ + if (Z_TYPE_P(newval) != IS_BOOL) { \ + ztmp = *newval; \ + zval_copy_ctor(&ztmp); \ + convert_to_boolean(&ztmp); \ + newval = &ztmp; \ + } \ +\ + snmp_object->name = Z_LVAL_P(newval); \ +\ + if (newval == &ztmp) { \ + zval_dtor(newval); \ + } \ + return SUCCESS; \ } -/* }}} */ -/* {{{ */ -static int php_snmp_write_enum_print(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) -{ - zval ztmp; - if (Z_TYPE_P(newval) != IS_BOOL) { - ztmp = *newval; - zval_copy_ctor(&ztmp); - convert_to_boolean(&ztmp); - newval = &ztmp; - } - - snmp_object->enum_print = Z_LVAL_P(newval); - - if (newval == &ztmp) { - zval_dtor(newval); - } - return SUCCESS; -} -/* }}} */ +PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(quick_print) +PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(enum_print) +PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(noOIDIncreasingCheck) /* {{{ */ static int php_snmp_write_oid_output_format(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) @@ -2311,6 +2284,7 @@ const php_snmp_prop_handler php_snmp_property_entries[] = { PHP_SNMP_PROPERTY_ENTRY_RECORD(quick_print), PHP_SNMP_PROPERTY_ENTRY_RECORD(enum_print), PHP_SNMP_PROPERTY_ENTRY_RECORD(oid_output_format), + PHP_SNMP_PROPERTY_ENTRY_RECORD(noOIDIncreasingCheck), { NULL, 0, NULL, NULL} }; /* }}} */ diff --git a/ext/snmp/tests/snmp-object-properties.phpt b/ext/snmp/tests/snmp-object-properties.phpt index 98423670c1ad4..51699a5a30822 100644 --- a/ext/snmp/tests/snmp-object-properties.phpt +++ b/ext/snmp/tests/snmp-object-properties.phpt @@ -26,6 +26,7 @@ $session->enum_print = TRUE; $session->quick_print = TRUE; $session->valueretrieval = SNMP_VALUE_LIBRARY; $session->oid_output_format = SNMP_OID_OUTPUT_NUMERIC; +$session->noOIDIncreasingCheck = TRUE; var_dump($session); @@ -34,6 +35,7 @@ $session->enum_print = "1"; $session->quick_print = "1"; $session->valueretrieval = "1"; $session->oid_output_format = "3"; +$session->noOIDIncreasingCheck = "45"; var_dump($session); @@ -87,6 +89,8 @@ object(SNMP)#%d (%d) { bool(false) ["oid_output_format"]=> int(3) + ["noOIDIncreasingCheck"]=> + bool(false) } object(SNMP)#%d (%d) { ["info"]=> @@ -110,6 +114,8 @@ object(SNMP)#%d (%d) { bool(true) ["oid_output_format"]=> int(4) + ["noOIDIncreasingCheck"]=> + bool(true) } object(SNMP)#%d (%d) { ["info"]=> @@ -133,6 +139,8 @@ object(SNMP)#%d (%d) { bool(true) ["oid_output_format"]=> int(3) + ["noOIDIncreasingCheck"]=> + bool(true) } bool(true) bool(true) @@ -159,6 +167,8 @@ object(SNMP)#%d (%d) { bool(true) ["oid_output_format"]=> int(3) + ["noOIDIncreasingCheck"]=> + bool(true) ["123"]=> string(11) "param_value" } From 22065bc0506bca5dff16208270e4d335ecf83a92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Sun, 17 Jul 2011 23:33:22 +0000 Subject: [PATCH 0326/2394] - get rid of FPM_AUTOCONFIG_H which has never existed since FPM integration into core --- sapi/fpm/fpm/fastcgi.c | 4 ---- sapi/fpm/fpm/fpm_config.h | 4 ---- sapi/fpm/fpm/fpm_main.c | 4 ---- 3 files changed, 12 deletions(-) diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index ffa310daf6739..86e82ae98ab98 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -28,11 +28,7 @@ #include #include -#ifdef FPM_AUTOCONFIG_H -#include -#else #include -#endif #include #include diff --git a/sapi/fpm/fpm/fpm_config.h b/sapi/fpm/fpm/fpm_config.h index 3637f376c29d2..856414a920246 100644 --- a/sapi/fpm/fpm/fpm_config.h +++ b/sapi/fpm/fpm/fpm_config.h @@ -3,10 +3,6 @@ #include -#ifdef FPM_AUTOCONFIG_H -# include -#endif - /* Solaris does not have it */ #ifndef INADDR_NONE # define INADDR_NONE (-1) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 06370d855ce04..4611981578986 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -99,11 +99,7 @@ int __riscosify_control = __RISCOSIFY_STRICT_UNIX_SPECS; #include "fastcgi.h" -#ifdef FPM_AUTOCONFIG_H -#include -#else #include -#endif #include #include #include From a476f4d92cc1d0e7d29d7ebaafce510f73f94334 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 18 Jul 2011 00:09:30 +0000 Subject: [PATCH 0327/2394] - remove is_fastcgi because FPM is always fastcgi --- sapi/fpm/fpm/fastcgi.c | 36 +------ sapi/fpm/fpm/fastcgi.h | 2 - sapi/fpm/fpm/fpm_main.c | 209 ++++++++++++---------------------------- 3 files changed, 66 insertions(+), 181 deletions(-) diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index 86e82ae98ab98..1a50274812e1c 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -141,7 +141,6 @@ typedef union _sa_t { static HashTable fcgi_mgmt_vars; static int is_initialized = 0; -static int is_fastcgi = 0; static int in_shutdown = 0; static in_addr_t *allowed_clients = NULL; @@ -203,9 +202,7 @@ int fcgi_init(void) return 0; } # endif - if ((GetStdHandle(STD_OUTPUT_HANDLE) == INVALID_HANDLE_VALUE) && - (GetStdHandle(STD_ERROR_HANDLE) == INVALID_HANDLE_VALUE) && - (GetStdHandle(STD_INPUT_HANDLE) != INVALID_HANDLE_VALUE)) { + { char *str; DWORD pipe_mode = PIPE_READMODE_BYTE | PIPE_WAIT; HANDLE pipe = GetStdHandle(STD_INPUT_HANDLE); @@ -224,36 +221,14 @@ int fcgi_init(void) if (str != NULL) { fcgi_accept_mutex = (HANDLE) atoi(str); } - return is_fastcgi = 1; - } else { - return is_fastcgi = 0; + return 1; } #else - errno = 0; - if (getpeername(0, (struct sockaddr *)&sa, &len) != 0 && errno == ENOTCONN) { - fcgi_setup_signals(); - return is_fastcgi = 1; - } else { - return is_fastcgi = 0; - } + fcgi_setup_signals(); + return 1; #endif } - return is_fastcgi; -} - - -int fcgi_is_fastcgi(void) -{ - if (!is_initialized) { - return fcgi_init(); - } else { - return is_fastcgi; - } -} - -void fcgi_set_is_fastcgi(int new_value) -{ - is_fastcgi = new_value; + return 1; } void fcgi_set_in_shutdown(int new_value) @@ -266,7 +241,6 @@ void fcgi_shutdown(void) if (is_initialized) { zend_hash_destroy(&fcgi_mgmt_vars); } - is_fastcgi = 0; if (allowed_clients) { free(allowed_clients); } diff --git a/sapi/fpm/fpm/fastcgi.h b/sapi/fpm/fpm/fastcgi.h index 4129def0502a9..caac528547756 100644 --- a/sapi/fpm/fpm/fastcgi.h +++ b/sapi/fpm/fpm/fastcgi.h @@ -114,12 +114,10 @@ typedef struct _fcgi_request { int fcgi_init(void); void fcgi_shutdown(void); -int fcgi_is_fastcgi(void); void fcgi_init_request(fcgi_request *req, int listen_socket); int fcgi_accept_request(fcgi_request *req); int fcgi_finish_request(fcgi_request *req, int force_close); -void fcgi_set_is_fastcgi(int new_value); void fcgi_set_in_shutdown(int); void fcgi_set_allowed_clients(char *); void fcgi_close(fcgi_request *req, int force, int destroy); diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 4611981578986..0648b0c73b93c 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -106,6 +106,7 @@ int __riscosify_control = __RISCOSIFY_STRICT_UNIX_SPECS; #include #include #include +#include #ifndef PHP_WIN32 /* XXX this will need to change later when threaded fastcgi is implemented. shane */ @@ -260,35 +261,16 @@ static void print_extensions(TSRMLS_D) zend_llist_destroy(&sorted_exts); } -#ifndef STDOUT_FILENO -#define STDOUT_FILENO 1 -#endif - static inline size_t sapi_cgibin_single_write(const char *str, uint str_length TSRMLS_DC) { -#ifdef PHP_WRITE_STDOUT long ret; -#else - size_t ret; -#endif - if (fcgi_is_fastcgi()) { - fcgi_request *request = (fcgi_request*) SG(server_context); - long ret = fcgi_write(request, FCGI_STDOUT, str, str_length); - if (ret <= 0) { - return 0; - } - return ret; + fcgi_request *request = (fcgi_request*) SG(server_context); + ret = fcgi_write(request, FCGI_STDOUT, str, str_length); + if (ret <= 0) { + return 0; } - -#ifdef PHP_WRITE_STDOUT - ret = write(STDOUT_FILENO, str, str_length); - if (ret <= 0) return 0; - return ret; -#else - ret = fwrite(str, 1, MIN(str_length, 16384), stdout); return ret; -#endif } static int sapi_cgibin_ub_write(const char *str, uint str_length TSRMLS_DC) @@ -313,18 +295,12 @@ static int sapi_cgibin_ub_write(const char *str, uint str_length TSRMLS_DC) static void sapi_cgibin_flush(void *server_context) { - if (fcgi_is_fastcgi()) { - fcgi_request *request = (fcgi_request*) server_context; - if ( + fcgi_request *request = (fcgi_request*) server_context; + if ( #ifndef PHP_WIN32 - !parent && + !parent && #endif - request && !fcgi_flush(request, 0)) { - php_handle_aborted_connection(); - } - return; - } - if (fflush(stdout) == EOF) { + request && !fcgi_flush(request, 0)) { php_handle_aborted_connection(); } } @@ -490,31 +466,27 @@ static int sapi_cgi_read_post(char *buffer, uint count_bytes TSRMLS_DC) count_bytes = MIN(count_bytes, (uint) SG(request_info).content_length - SG(read_post_bytes)); while (read_bytes < count_bytes) { - if (fcgi_is_fastcgi()) { - fcgi_request *request = (fcgi_request*) SG(server_context); - if (request_body_fd == -1) { - char *request_body_filename = sapi_cgibin_getenv((char *) "REQUEST_BODY_FILE", - sizeof("REQUEST_BODY_FILE") - 1 TSRMLS_CC); - - if (request_body_filename && *request_body_filename) { - request_body_fd = open(request_body_filename, O_RDONLY); - - if (0 > request_body_fd) { - php_error(E_WARNING, "REQUEST_BODY_FILE: open('%s') failed: %s (%d)", - request_body_filename, strerror(errno), errno); - return 0; - } + fcgi_request *request = (fcgi_request*) SG(server_context); + if (request_body_fd == -1) { + char *request_body_filename = sapi_cgibin_getenv((char *) "REQUEST_BODY_FILE", + sizeof("REQUEST_BODY_FILE") - 1 TSRMLS_CC); + + if (request_body_filename && *request_body_filename) { + request_body_fd = open(request_body_filename, O_RDONLY); + + if (0 > request_body_fd) { + php_error(E_WARNING, "REQUEST_BODY_FILE: open('%s') failed: %s (%d)", + request_body_filename, strerror(errno), errno); + return 0; } } + } - /* If REQUEST_BODY_FILE variable not available - read post body from fastcgi stream */ - if (request_body_fd < 0) { - tmp_read_bytes = fcgi_read(request, buffer + read_bytes, count_bytes - read_bytes); - } else { - tmp_read_bytes = read(request_body_fd, buffer + read_bytes, count_bytes - read_bytes); - } + /* If REQUEST_BODY_FILE variable not available - read post body from fastcgi stream */ + if (request_body_fd < 0) { + tmp_read_bytes = fcgi_read(request, buffer + read_bytes, count_bytes - read_bytes); } else { - tmp_read_bytes = read(STDIN_FILENO, buffer + read_bytes, count_bytes - read_bytes); + tmp_read_bytes = read(request_body_fd, buffer + read_bytes, count_bytes - read_bytes); } if (tmp_read_bytes <= 0) { break; @@ -526,77 +498,21 @@ static int sapi_cgi_read_post(char *buffer, uint count_bytes TSRMLS_DC) static char *sapi_cgibin_getenv(char *name, size_t name_len TSRMLS_DC) { - /* when php is started by mod_fastcgi, no regular environment - * is provided to PHP. It is always sent to PHP at the start - * of a request. So we have to do our own lookup to get env - * vars. This could probably be faster somehow. */ - if (fcgi_is_fastcgi()) { - fcgi_request *request = (fcgi_request*) SG(server_context); - return fcgi_getenv(request, name, name_len); - } - /* if cgi, or fastcgi and not found in fcgi env - check the regular environment */ - return getenv(name); + fcgi_request *request = (fcgi_request*) SG(server_context); + return fcgi_getenv(request, name, name_len); } static char *_sapi_cgibin_putenv(char *name, char *value TSRMLS_DC) { int name_len; -#if !HAVE_SETENV || !HAVE_UNSETENV - int len; - char *buf; -#endif if (!name) { return NULL; } name_len = strlen(name); - /* when php is started by mod_fastcgi, no regular environment - * is provided to PHP. It is always sent to PHP at the start - * of a request. So we have to do our own lookup to get env - * vars. This could probably be faster somehow. */ - if (fcgi_is_fastcgi()) { - fcgi_request *request = (fcgi_request*) SG(server_context); - return fcgi_putenv(request, name, name_len, value); - } - -#if HAVE_SETENV - if (value) { - setenv(name, value, 1); - } -#endif -#if HAVE_UNSETENV - if (!value) { - unsetenv(name); - } -#endif - -#if !HAVE_SETENV || !HAVE_UNSETENV - /* if cgi, or fastcgi and not found in fcgi env - check the regular environment - this leaks, but it's only cgi anyway, we'll fix - it for 5.0 - */ - len = name_len + (value ? strlen(value) : 0) + sizeof("=") + 2; - buf = (char *) malloc(len); - if (buf == NULL) { - return getenv(name); - } -#endif -#if !HAVE_SETENV - if (value) { - len = slprintf(buf, len - 1, "%s=%s", name, value); - putenv(buf); - } -#endif -#if !HAVE_UNSETENV - if (!value) { - len = slprintf(buf, len - 1, "%s=", name); - putenv(buf); - } -#endif - return getenv(name); + fcgi_request *request = (fcgi_request*) SG(server_context); + return fcgi_putenv(request, name, name_len, value); } static char *sapi_cgi_read_cookies(TSRMLS_D) @@ -606,6 +522,15 @@ static char *sapi_cgi_read_cookies(TSRMLS_D) void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) { + fcgi_request *request; + HashPosition pos; + int magic_quotes_gpc;; + char *var, **val; + uint var_len; + ulong idx; + int filter_arg; + + if (PG(http_globals)[TRACK_VARS_ENV] && array_ptr != PG(http_globals)[TRACK_VARS_ENV] && Z_TYPE_P(PG(http_globals)[TRACK_VARS_ENV]) == IS_ARRAY && @@ -631,30 +556,24 @@ void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) /* call php's original import as a catch-all */ php_php_import_environment_variables(array_ptr TSRMLS_CC); - if (fcgi_is_fastcgi()) { - fcgi_request *request = (fcgi_request*) SG(server_context); - HashPosition pos; - int magic_quotes_gpc = PG(magic_quotes_gpc); - char *var, **val; - uint var_len; - ulong idx; - int filter_arg = (array_ptr == PG(http_globals)[TRACK_VARS_ENV])?PARSE_ENV:PARSE_SERVER; - - /* turn off magic_quotes while importing environment variables */ - PG(magic_quotes_gpc) = 0; - for (zend_hash_internal_pointer_reset_ex(request->env, &pos); - zend_hash_get_current_key_ex(request->env, &var, &var_len, &idx, 0, &pos) == HASH_KEY_IS_STRING && - zend_hash_get_current_data_ex(request->env, (void **) &val, &pos) == SUCCESS; - zend_hash_move_forward_ex(request->env, &pos) - ) { - unsigned int new_val_len; + request = (fcgi_request*) SG(server_context); + magic_quotes_gpc = PG(magic_quotes_gpc); + filter_arg = (array_ptr == PG(http_globals)[TRACK_VARS_ENV])?PARSE_ENV:PARSE_SERVER; - if (sapi_module.input_filter(filter_arg, var, val, strlen(*val), &new_val_len TSRMLS_CC)) { - php_register_variable_safe(var, *val, new_val_len, array_ptr TSRMLS_CC); - } + /* turn off magic_quotes while importing environment variables */ + PG(magic_quotes_gpc) = 0; + for (zend_hash_internal_pointer_reset_ex(request->env, &pos); + zend_hash_get_current_key_ex(request->env, &var, &var_len, &idx, 0, &pos) == HASH_KEY_IS_STRING && + zend_hash_get_current_data_ex(request->env, (void **) &val, &pos) == SUCCESS; + zend_hash_move_forward_ex(request->env, &pos) + ) { + unsigned int new_val_len; + + if (sapi_module.input_filter(filter_arg, var, val, strlen(*val), &new_val_len TSRMLS_CC)) { + php_register_variable_safe(var, *val, new_val_len, array_ptr TSRMLS_CC); } - PG(magic_quotes_gpc) = magic_quotes_gpc; } + PG(magic_quotes_gpc) = magic_quotes_gpc; } static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC) @@ -700,7 +619,7 @@ static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC) static void sapi_cgi_log_message(char *message TSRMLS_DC) { - if (fcgi_is_fastcgi() && CGIG(fcgi_logging)) { + if (CGIG(fcgi_logging)) { fcgi_request *request; request = (fcgi_request*) SG(server_context); @@ -714,10 +633,9 @@ static void sapi_cgi_log_message(char *message TSRMLS_DC) free(buf); } else { fprintf(stderr, "%s\n", message); + //FIXME zlog(ZLOG_NOTICE, "PHP message: %s", message); } /* ignore return code */ - } else { - fprintf(stderr, "%s\n", message); } } @@ -875,16 +793,12 @@ static int sapi_cgi_deactivate(TSRMLS_D) 2. When the first call occurs and the request is not set up, flush fails on FastCGI. */ if (SG(sapi_started)) { - if (fcgi_is_fastcgi()) { - if ( + if ( #ifndef PHP_WIN32 - !parent && + !parent && #endif - !fcgi_finish_request((fcgi_request*)SG(server_context), 0)) { - php_handle_aborted_connection(); - } - } else { - sapi_cgibin_flush(SG(server_context)); + !fcgi_finish_request((fcgi_request*)SG(server_context), 0)) { + php_handle_aborted_connection(); } } return SUCCESS; @@ -1528,7 +1442,7 @@ PHP_FUNCTION(fastcgi_finish_request) /* {{{ */ { fcgi_request *request = (fcgi_request*) SG(server_context); - if (fcgi_is_fastcgi() && request->fd >= 0) { + if (request->fd >= 0) { php_output_end_all(TSRMLS_C); php_header(TSRMLS_C); @@ -1829,7 +1743,6 @@ consult the installation file that came with this distribution, or visit \n\ fcgi_fd = fpm_run(&max_requests); parent = 0; - fcgi_set_is_fastcgi(1); /* make php call us to get _ENV vars */ php_php_import_environment_variables = php_import_environment_variables; From 1dc21c2fd035673b9e5822ca73a8ed3682f252f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 18 Jul 2011 00:19:22 +0000 Subject: [PATCH 0328/2394] remove unused variable --- sapi/fpm/fpm/fastcgi.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index 1a50274812e1c..4ffa1ec2909d9 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -184,10 +184,6 @@ static void fcgi_setup_signals(void) int fcgi_init(void) { if (!is_initialized) { -#ifndef _WIN32 - sa_t sa; - socklen_t len = sizeof(sa); -#endif zend_hash_init(&fcgi_mgmt_vars, 0, NULL, fcgi_free_mgmt_var_cb, 1); fcgi_set_mgmt_var("FCGI_MPXS_CONNS", sizeof("FCGI_MPXS_CONNS") - 1, "0", sizeof("0")-1); From 6d3ff0eda1996745019f561e445ce4011ad4c746 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 18 Jul 2011 00:53:13 +0000 Subject: [PATCH 0329/2394] - don't write directly to stderr, use the internal logger instead (zlog) --- sapi/fpm/fpm/fpm_main.c | 25 +++++-------------------- sapi/fpm/fpm/fpm_php.c | 4 ++-- 2 files changed, 7 insertions(+), 22 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 0648b0c73b93c..f362a2cbc3f5d 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -620,22 +620,7 @@ static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC) static void sapi_cgi_log_message(char *message TSRMLS_DC) { if (CGIG(fcgi_logging)) { - fcgi_request *request; - - request = (fcgi_request*) SG(server_context); - if (request) { - int len = strlen(message); - char *buf = malloc(len+2); - - memcpy(buf, message, len); - memcpy(buf + len, "\n", sizeof("\n")); - fcgi_write(request, FCGI_STDERR, buf, len+1); - free(buf); - } else { - fprintf(stderr, "%s\n", message); - //FIXME zlog(ZLOG_NOTICE, "PHP message: %s", message); - } - /* ignore return code */ + zlog(ZLOG_NOTICE, "PHP message: %s", message); } } @@ -1349,17 +1334,17 @@ static void fastcgi_ini_parser(zval *arg1, zval *arg2, zval *arg3, int callback_ if (!mode) return; if (callback_type != ZEND_INI_PARSER_ENTRY) { - fprintf(stderr, "Passing INI directive through FastCGI: only classic entries are allowed\n"); + zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: only classic entries are allowed"); return; } if (!key || strlen(key) < 1) { - fprintf(stderr, "Passing INI directive through FastCGI: empty key\n"); + zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: empty key"); return; } if (!value) { - fprintf(stderr, "Passing INI directive through FastCGI: empty value for key '%s'\n", key); + zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: empty value for key '%s'", key); return; } @@ -1367,7 +1352,7 @@ static void fastcgi_ini_parser(zval *arg1, zval *arg2, zval *arg3, int callback_ kv.value = value; kv.next = NULL; if (fpm_php_apply_defines_ex(&kv, *mode) == -1) { - fprintf(stderr, "Passing INI directive through FastCGI: unable to set '%s'\n", key); + zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: unable to set '%s'", key); } } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_php.c b/sapi/fpm/fpm/fpm_php.c index f320f5148e6be..d541f2944618a 100644 --- a/sapi/fpm/fpm/fpm_php.c +++ b/sapi/fpm/fpm/fpm_php.c @@ -120,13 +120,13 @@ static int fpm_php_apply_defines(struct fpm_worker_pool_s *wp) /* {{{ */ for (kv = wp->config->php_values; kv; kv = kv->next) { if (fpm_php_apply_defines_ex(kv, ZEND_INI_USER) == -1) { - fprintf(stderr, "Unable to set php_value '%s'", kv->key); + zlog(ZLOG_ERROR, "Unable to set php_value '%s'", kv->key); } } for (kv = wp->config->php_admin_values; kv; kv = kv->next) { if (fpm_php_apply_defines_ex(kv, ZEND_INI_SYSTEM) == -1) { - fprintf(stderr, "Unable to set php_admin_value '%s'", kv->key); + zlog(ZLOG_ERROR, "Unable to set php_admin_value '%s'", kv->key); } } From b150a6db240b1a955d617b7bca3316ca84bd3453 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Mon, 18 Jul 2011 08:36:17 +0000 Subject: [PATCH 0330/2394] added numeric entities encode/decode in hex format. --- ext/mbstring/libmbfl/mbfl/mbfilter.c | 143 ++++++++++++++++++++++++++- ext/mbstring/mbstring.c | 14 ++- 2 files changed, 151 insertions(+), 6 deletions(-) diff --git a/ext/mbstring/libmbfl/mbfl/mbfilter.c b/ext/mbstring/libmbfl/mbfl/mbfilter.c index 9eec3b4afc9cd..9f929cc3b2d63 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfilter.c +++ b/ext/mbstring/libmbfl/mbfl/mbfilter.c @@ -2746,7 +2746,9 @@ collector_decode_htmlnumericentity(int c, void *data) } break; case 2: - if (c >= 0x30 && c <= 0x39) { /* '0' - '9' */ + if (c == 0x78) { /* 'x' */ + pc->status = 4; + } else if (c >= 0x30 && c <= 0x39) { /* '0' - '9' */ pc->cache = c - 0x30; pc->status = 3; pc->digit = 1; @@ -2810,6 +2812,89 @@ collector_decode_htmlnumericentity(int c, void *data) (*pc->decoder->filter_function)(c, pc->decoder); } break; + case 4: + if (c >= 0x30 && c <= 0x39) { /* '0' - '9' */ + pc->cache = c - 0x30; + pc->status = 5; + pc->digit = 1; + } else if (c >= 0x41 && c <= 0x46) { /* 'A' - 'F' */ + pc->cache = c - 0x41 + 10; + pc->status = 5; + pc->digit = 1; + } else if (c >= 0x61 && c <= 0x66) { /* 'a' - 'f' */ + pc->cache = c - 0x61 + 10; + pc->status = 5; + pc->digit = 1; + } else { + pc->status = 0; + (*pc->decoder->filter_function)(0x26, pc->decoder); /* '&' */ + (*pc->decoder->filter_function)(0x23, pc->decoder); /* '#' */ + (*pc->decoder->filter_function)(0x78, pc->decoder); /* 'x' */ + (*pc->decoder->filter_function)(c, pc->decoder); + } + break; + case 5: + s = 0; + f = 0; + if ((c >= 0x30 && c <= 0x39) || + (c >= 0x41 && c <= 0x46) || + (c >= 0x61 && c <= 0x66)) { /* '0' - '9' or 'a' - 'f' */ + if (pc->digit > 9) { + pc->status = 0; + s = pc->cache; + f = 1; + } else { + if (c >= 0x30 && c <= 0x39) { + s = pc->cache*16 + (c - 0x30); + } else if (c >= 0x41 && c <= 0x46) { + s = pc->cache*16 + (c - 0x41 + 10); + } else { + s = pc->cache*16 + (c - 0x61 + 10); + } + pc->cache = s; + pc->digit++; + } + } else { + pc->status = 0; + s = pc->cache; + f = 1; + n = 0; + size = pc->mapsize; + while (n < size) { + mapelm = &(pc->convmap[n*4]); + d = s - mapelm[2]; + if (d >= mapelm[0] && d <= mapelm[1]) { + f = 0; + (*pc->decoder->filter_function)(d, pc->decoder); + if (c != 0x3b) { /* ';' */ + (*pc->decoder->filter_function)(c, pc->decoder); + } + break; + } + n++; + } + } + if (f) { + (*pc->decoder->filter_function)(0x26, pc->decoder); /* '&' */ + (*pc->decoder->filter_function)(0x23, pc->decoder); /* '#' */ + (*pc->decoder->filter_function)(0x78, pc->decoder); /* 'x' */ + r = 1; + n = pc->digit; + while (n > 0) { + r *= 16; + n--; + } + s %= r; + r /= 16; + while (r > 0) { + d = s/r; + s %= r; + r /= 16; + (*pc->decoder->filter_function)(mbfl_hexchar_table[d], pc->decoder); + } + (*pc->decoder->filter_function)(c, pc->decoder); + } + break; default: if (c == 0x26) { /* '&' */ pc->status = 1; @@ -2822,6 +2907,53 @@ collector_decode_htmlnumericentity(int c, void *data) return c; } +static int +collector_encode_hex_htmlnumericentity(int c, void *data) +{ + struct collector_htmlnumericentity_data *pc = (struct collector_htmlnumericentity_data *)data; + int f, n, s, r, d, size, *mapelm; + + size = pc->mapsize; + f = 0; + n = 0; + while (n < size) { + mapelm = &(pc->convmap[n*4]); + if (c >= mapelm[0] && c <= mapelm[1]) { + s = (c + mapelm[2]) & mapelm[3]; + if (s >= 0) { + (*pc->decoder->filter_function)(0x26, pc->decoder); /* '&' */ + (*pc->decoder->filter_function)(0x23, pc->decoder); /* '#' */ + (*pc->decoder->filter_function)(0x78, pc->decoder); /* 'x' */ + r = 0x1000000; + s %= r; + while (r > 0) { + d = s/r; + if (d || f) { + f = 1; + s %= r; + (*pc->decoder->filter_function)(mbfl_hexchar_table[d], pc->decoder); + } + r /= 16; + } + if (!f) { + f = 1; + (*pc->decoder->filter_function)(mbfl_hexchar_table[0], pc->decoder); + } + (*pc->decoder->filter_function)(0x3b, pc->decoder); /* ';' */ + } + } + if (f) { + break; + } + n++; + } + if (!f) { + (*pc->decoder->filter_function)(c, pc->decoder); + } + + return c; +} + mbfl_string * mbfl_html_numeric_entity( mbfl_string *string, @@ -2850,12 +2982,17 @@ mbfl_html_numeric_entity( string->no_encoding, mbfl_memory_device_output, 0, &device); /* wchar filter */ - if (type == 0) { + if (type == 0) { /* decimal output */ encoder = mbfl_convert_filter_new( string->no_encoding, mbfl_no_encoding_wchar, collector_encode_htmlnumericentity, 0, &pc); - } else { + } else if (type == 2) { /* hex output */ + encoder = mbfl_convert_filter_new( + string->no_encoding, + mbfl_no_encoding_wchar, + collector_encode_hex_htmlnumericentity, 0, &pc); + } else { /* type == 1: decimal/hex input */ encoder = mbfl_convert_filter_new( string->no_encoding, mbfl_no_encoding_wchar, diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 34644a553bc61..f87b51abf7e90 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -412,6 +412,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_encode_numericentity, 0, 0, 2) ZEND_ARG_INFO(0, string) ZEND_ARG_INFO(0, convmap) ZEND_ARG_INFO(0, encoding) + ZEND_ARG_INFO(0, is_hex) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_decode_numericentity, 0, 0, 2) @@ -3682,10 +3683,11 @@ php_mb_numericentity_exec(INTERNAL_FUNCTION_PARAMETERS, int type) HashTable *target_hash; size_t argc = ZEND_NUM_ARGS(); int i, *convmap, *mapelm, mapsize=0; + zend_bool is_hex = 0; mbfl_string string, result, *ret; enum mbfl_no_encoding no_encoding; - if (zend_parse_parameters(argc TSRMLS_CC, "szs", &str, &str_len, &zconvmap, &encoding, &encoding_len) == FAILURE) { + if (zend_parse_parameters(argc TSRMLS_CC, "sz|sb", &str, &str_len, &zconvmap, &encoding, &encoding_len, &is_hex) == FAILURE) { return; } @@ -3696,7 +3698,7 @@ php_mb_numericentity_exec(INTERNAL_FUNCTION_PARAMETERS, int type) string.len = str_len; /* encoding */ - if (argc == 3) { + if ((argc == 3 || argc == 4) && encoding_len > 0) { no_encoding = mbfl_name2no_encoding(encoding); if (no_encoding == mbfl_no_encoding_invalid) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown encoding \"%s\"", encoding); @@ -3706,6 +3708,12 @@ php_mb_numericentity_exec(INTERNAL_FUNCTION_PARAMETERS, int type) } } + if (argc == 4) { + if (type == 0 && is_hex) { + type = 2; /* output in hex format */ + } + } + /* conversion map */ convmap = NULL; if (Z_TYPE_P(zconvmap) == IS_ARRAY) { @@ -3743,7 +3751,7 @@ php_mb_numericentity_exec(INTERNAL_FUNCTION_PARAMETERS, int type) } /* }}} */ -/* {{{ proto string mb_encode_numericentity(string string, array convmap [, string encoding]) +/* {{{ proto string mb_encode_numericentity(string string, array convmap [, string encoding [, bool is_hex]]) Converts specified characters to HTML numeric entities */ PHP_FUNCTION(mb_encode_numericentity) { From ba22d8a37b0a0cd4e5f5fd537c58d72d8212298c Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 18 Jul 2011 10:25:36 +0000 Subject: [PATCH 0331/2394] - fix bug #54204, Can't set a value with a PATH section in php.ini --- main/php_ini.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/php_ini.c b/main/php_ini.c index 8ad7362bba3b1..48e0654441ef5 100644 --- a/main/php_ini.c +++ b/main/php_ini.c @@ -828,7 +828,7 @@ PHPAPI void php_ini_activate_per_dir_config(char *path, uint path_len TSRMLS_DC) #if PHP_WIN32 memcpy(path_bak, path, path_len); - path_bak[path_len - 1] = 0; + path_bak[path_len] = 0; TRANSLATE_SLASHES_LOWER(path_bak); path = path_bak; #endif From 3c323a5d6d8c7654d7c32488ce0b1d28cc95badd Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 18 Jul 2011 12:00:08 +0000 Subject: [PATCH 0332/2394] - not a good idea after all and did not do what I thought it should do --- win32/build/config.w32 | 1 - 1 file changed, 1 deletion(-) diff --git a/win32/build/config.w32 b/win32/build/config.w32 index 0cec4b140f2df..2351ee695b50b 100644 --- a/win32/build/config.w32 +++ b/win32/build/config.w32 @@ -151,7 +151,6 @@ if (VCVERS >= 1400) { // Set some debug/release specific options ADD_FLAG('CFLAGS', ' /RTC1 '); } - ADD_FLAG('CFLAGS', ' /D_BIND_TO_CURRENT_CRT_VERSION=1 '); } ARG_WITH('mp', 'Tell VC9+ use up to [n,auto,disable] processes for compilation', 'auto'); From 251879c890694138682d5e3af67aefae99b20495 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 18 Jul 2011 21:03:44 +0000 Subject: [PATCH 0333/2394] fix a segfault when passing an empty value to a ini parameter from the web server (php_(admin_)?value) --- sapi/fpm/fpm/fpm_main.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index f362a2cbc3f5d..cda0c1d983b25 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1327,22 +1327,28 @@ static void init_request_info(TSRMLS_D) static void fastcgi_ini_parser(zval *arg1, zval *arg2, zval *arg3, int callback_type, void *arg TSRMLS_DC) /* {{{ */ { int *mode = (int *)arg; - char *key = Z_STRVAL_P(arg1); - char *value = Z_STRVAL_P(arg2); + char *key; + char *value = NULL; struct key_value_s kv; - if (!mode) return; + if (!mode || !arg1) return; if (callback_type != ZEND_INI_PARSER_ENTRY) { zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: only classic entries are allowed"); return; } + key = Z_STRVAL_P(arg1); + if (!key || strlen(key) < 1) { zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: empty key"); return; } + if (arg2) { + value = Z_STRVAL_P(arg2); + } + if (!value) { zlog(ZLOG_ERROR, "Passing INI directive through FastCGI: empty value for key '%s'", key); return; From 03315d9625dc87515f1dfbf1cc7d53c4451b5ec9 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 18 Jul 2011 21:26:29 +0000 Subject: [PATCH 0334/2394] - update blowfish to 1.2 (Solar Designer) --- README.REDIST.BINS | 27 ++- ext/standard/crypt_blowfish.c | 415 +++++++++++++++++++++------------- ext/standard/crypt_blowfish.h | 32 +++ ext/standard/php_crypt_r.h | 4 +- 4 files changed, 309 insertions(+), 169 deletions(-) create mode 100644 ext/standard/crypt_blowfish.h diff --git a/README.REDIST.BINS b/README.REDIST.BINS index afa108300b0d7..968c3ec0c87e4 100644 --- a/README.REDIST.BINS +++ b/README.REDIST.BINS @@ -51,27 +51,40 @@ SUCH DAMAGE. 6. ext/standard crypt's blowfish implementation +The crypt_blowfish homepage is: + +http://www.openwall.com/crypt/ + This code comes from John the Ripper password cracker, with reentrant and crypt(3) interfaces added, but optimizations specific to password cracking removed. -Written by Solar Designer in 1998-2002 and -placed in the public domain. +Written by Solar Designer in 1998-2011. +No copyright is claimed, and the software is hereby placed in the public +domain. In case this attempt to disclaim copyright and place the software +in the public domain is deemed null and void, then the software is +Copyright (c) 1998-2011 Solar Designer and it is hereby released to the +general public under the following terms: + +Redistribution and use in source and binary forms, with or without +modification, are permitted. -There's absolutely no warranty. +There's ABSOLUTELY NO WARRANTY, express or implied. It is my intent that you should be able to use this on your system, -as a part of a software package, or anywhere else to improve security, +as part of a software package, or anywhere else to improve security, ensure compatibility, or for any other purpose. I would appreciate it if you give credit where it is due and keep your modifications in the public domain as well, but I don't require that in order to let you place this code and any modifications you make under a license of your choice. -This implementation is compatible with OpenBSD bcrypt.c (version 2a) -by Niels Provos , and uses some of his +This implementation is mostly compatible with OpenBSD's bcrypt.c (prefix +"$2a$") by Niels Provos , and uses some of his ideas. The password hashing algorithm was designed by David Mazieres -. +. For more information on the level of compatibility, +please refer to the comments in BF_set_key() and to the crypt(3) man page +included in the crypt_blowfish tarball. There's a paper on the algorithm that explains its design decisions: diff --git a/ext/standard/crypt_blowfish.c b/ext/standard/crypt_blowfish.c index 9e3a9241d0afc..e010352b55e91 100644 --- a/ext/standard/crypt_blowfish.c +++ b/ext/standard/crypt_blowfish.c @@ -1,29 +1,39 @@ +/* $Id$ */ /* - $Id$ -*/ -/* + * The crypt_blowfish homepage is: + * + * http://www.openwall.com/crypt/ + * * This code comes from John the Ripper password cracker, with reentrant * and crypt(3) interfaces added, but optimizations specific to password * cracking removed. * - * Written by Solar Designer in 1998-2002 and - * placed in the public domain. Quick self-test added in 2011 and also - * placed in the public domain. + * Written by Solar Designer in 1998-2011. + * No copyright is claimed, and the software is hereby placed in the public + * domain. In case this attempt to disclaim copyright and place the software + * in the public domain is deemed null and void, then the software is + * Copyright (c) 1998-2011 Solar Designer and it is hereby released to the + * general public under the following terms: * - * There's absolutely no warranty. + * Redistribution and use in source and binary forms, with or without + * modification, are permitted. + * + * There's ABSOLUTELY NO WARRANTY, express or implied. * * It is my intent that you should be able to use this on your system, - * as a part of a software package, or anywhere else to improve security, + * as part of a software package, or anywhere else to improve security, * ensure compatibility, or for any other purpose. I would appreciate * it if you give credit where it is due and keep your modifications in * the public domain as well, but I don't require that in order to let * you place this code and any modifications you make under a license * of your choice. * - * This implementation is compatible with OpenBSD bcrypt.c (version 2a) - * by Niels Provos , and uses some of his + * This implementation is mostly compatible with OpenBSD's bcrypt.c (prefix + * "$2a$") by Niels Provos , and uses some of his * ideas. The password hashing algorithm was designed by David Mazieres - * . + * . For more information on the level of compatibility, + * please refer to the comments in BF_set_key() below and to the crypt(3) + * man page included in the crypt_blowfish tarball. * * There's a paper on the algorithm that explains its design decisions: * @@ -41,23 +51,8 @@ #define __set_errno(val) errno = (val) #endif - -#ifndef __const -#ifdef __GNUC__ -#define __CONST __const -#else -#define __CONST -#endif -#else -#define __CONST __const -#endif - -/* - * Please keep this enabled. We really don't want incompatible hashes to be - * produced. The performance cost of this quick self-test is around 0.6% at - * the "$2a$08" setting. - */ -#define BF_SELF_TEST +/* Just to make sure the prototypes match the actual definitions */ +#include "crypt_blowfish.h" #ifdef __i386__ #define BF_ASM 0 @@ -379,35 +374,21 @@ static unsigned char BF_atoi64[0x60] = { 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 64, 64, 64, 64, 64 }; -/* - * This may be optimized out if built with function inlining and no BF_ASM. - */ -static void clean(void *data, int size) -{ -#if BF_ASM - extern void _BF_clean(void *data); -#endif - memset(data, 0, size); -#if BF_ASM - _BF_clean(data); -#endif -} - #define BF_safe_atoi64(dst, src) \ { \ tmp = (unsigned char)(src); \ - if (tmp == '$') break; \ + if (tmp == '$') break; /* PHP hack */ \ if ((unsigned int)(tmp -= 0x20) >= 0x60) return -1; \ tmp = BF_atoi64[tmp]; \ if (tmp > 63) return -1; \ (dst) = tmp; \ } -static int BF_decode(BF_word *dst, __CONST char *src, int size) +static int BF_decode(BF_word *dst, const char *src, int size) { unsigned char *dptr = (unsigned char *)dst; unsigned char *end = dptr + size; - unsigned char *sptr = (unsigned char *)src; + const unsigned char *sptr = (const unsigned char *)src; unsigned int tmp, c1, c2, c3, c4; do { @@ -424,16 +405,16 @@ static int BF_decode(BF_word *dst, __CONST char *src, int size) *dptr++ = ((c3 & 0x03) << 6) | c4; } while (dptr < end); - while (dptr < end) + while (dptr < end) /* PHP hack */ *dptr++ = 0; return 0; } -static void BF_encode(char *dst, __CONST BF_word *src, int size) +static void BF_encode(char *dst, const BF_word *src, int size) { - unsigned char *sptr = (unsigned char *)src; - unsigned char *end = sptr + size; + const unsigned char *sptr = (const unsigned char *)src; + const unsigned char *end = sptr + size; unsigned char *dptr = (unsigned char *)dst; unsigned int c1, c2; @@ -564,36 +545,117 @@ static void BF_swap(BF_word *x, int count) } while (ptr < &data.ctx.S[3][0xFF]); #endif -static void BF_set_key(__CONST char *key, BF_key expanded, BF_key initial, int sign_extension_bug) +static void BF_set_key(const char *key, BF_key expanded, BF_key initial, + unsigned char flags) { - __CONST char *ptr = key; - int i, j; - BF_word tmp; + const char *ptr = key; + unsigned int bug, i, j; + BF_word safety, sign, diff, tmp[2]; + +/* + * There was a sign extension bug in older revisions of this function. While + * we would have liked to simply fix the bug and move on, we have to provide + * a backwards compatibility feature (essentially the bug) for some systems and + * a safety measure for some others. The latter is needed because for certain + * multiple inputs to the buggy algorithm there exist easily found inputs to + * the correct algorithm that produce the same hash. Thus, we optionally + * deviate from the correct algorithm just enough to avoid such collisions. + * While the bug itself affected the majority of passwords containing + * characters with the 8th bit set (although only a percentage of those in a + * collision-producing way), the anti-collision safety measure affects + * only a subset of passwords containing the '\xff' character (not even all of + * those passwords, just some of them). This character is not found in valid + * UTF-8 sequences and is rarely used in popular 8-bit character encodings. + * Thus, the safety measure is unlikely to cause much annoyance, and is a + * reasonable tradeoff to use when authenticating against existing hashes that + * are not reliably known to have been computed with the correct algorithm. + * + * We use an approach that tries to minimize side-channel leaks of password + * information - that is, we mostly use fixed-cost bitwise operations instead + * of branches or table lookups. (One conditional branch based on password + * length remains. It is not part of the bug aftermath, though, and is + * difficult and possibly unreasonable to avoid given the use of C strings by + * the caller, which results in similar timing leaks anyway.) + * + * For actual implementation, we set an array index in the variable "bug" + * (0 means no bug, 1 means sign extension bug emulation) and a flag in the + * variable "safety" (bit 16 is set when the safety measure is requested). + * Valid combinations of settings are: + * + * Prefix "$2a$": bug = 0, safety = 0x10000 + * Prefix "$2x$": bug = 1, safety = 0 + * Prefix "$2y$": bug = 0, safety = 0 + */ + bug = (unsigned int)flags & 1; + safety = ((BF_word)flags & 2) << 15; + + sign = diff = 0; for (i = 0; i < BF_N + 2; i++) { - tmp = 0; + tmp[0] = tmp[1] = 0; for (j = 0; j < 4; j++) { - tmp <<= 8; - if (sign_extension_bug) - tmp |= (BF_word_signed)(signed char)*ptr; + tmp[0] <<= 8; + tmp[0] |= (unsigned char)*ptr; /* correct */ + tmp[1] <<= 8; + tmp[1] |= (BF_word_signed)(signed char)*ptr; /* bug */ +/* + * Sign extension in the first char has no effect - nothing to overwrite yet, + * and those extra 24 bits will be fully shifted out of the 32-bit word. For + * chars 2, 3, 4 in each four-char block, we set bit 7 of "sign" if sign + * extension in tmp[1] occurs. Once this flag is set, it remains set. + */ + if (j) + sign |= tmp[1] & 0x80; + if (!*ptr) + ptr = key; else - tmp |= (unsigned char)*ptr; - - if (!*ptr) ptr = key; else ptr++; + ptr++; } + diff |= tmp[0] ^ tmp[1]; /* Non-zero on any differences */ - expanded[i] = tmp; - initial[i] = BF_init_state.P[i] ^ tmp; + expanded[i] = tmp[bug]; + initial[i] = BF_init_state.P[i] ^ tmp[bug]; } + +/* + * At this point, "diff" is zero iff the correct and buggy algorithms produced + * exactly the same result. If so and if "sign" is non-zero, which indicates + * that there was a non-benign sign extension, this means that we have a + * collision between the correctly computed hash for this password and a set of + * passwords that could be supplied to the buggy algorithm. Our safety measure + * is meant to protect from such many-buggy to one-correct collisions, by + * deviating from the correct algorithm in such cases. Let's check for this. + */ + diff |= diff >> 16; /* still zero iff exact match */ + diff &= 0xffff; /* ditto */ + diff += 0xffff; /* bit 16 set iff "diff" was non-zero (on non-match) */ + sign <<= 9; /* move the non-benign sign extension flag to bit 16 */ + sign &= ~diff & safety; /* action needed? */ + +/* + * If we have determined that we need to deviate from the correct algorithm, + * flip bit 16 in initial expanded key. (The choice of 16 is arbitrary, but + * let's stick to it now. It came out of the approach we used above, and it's + * not any worse than any other choice we could make.) + * + * It is crucial that we don't do the same to the expanded key used in the main + * Eksblowfish loop. By doing it to only one of these two, we deviate from a + * state that could be directly specified by a password to the buggy algorithm + * (and to the fully correct one as well, but that's a side-effect). + */ + initial[0] ^= sign; } -static char *BF_crypt(__CONST char *key, __CONST char *setting, - char *output, int size, - BF_word min) +static char *BF_crypt(const char *key, const char *setting, + char *output, int size, + BF_word min) { #if BF_ASM extern void _BF_body_r(BF_ctx *ctx); #endif + static const unsigned char flags_by_subtype[26] = + {2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 0}; struct { BF_ctx ctx; BF_key expanded_key; @@ -615,7 +677,8 @@ static char *BF_crypt(__CONST char *key, __CONST char *setting, if (setting[0] != '$' || setting[1] != '2' || - (setting[2] != 'a' && setting[2] != 'x') || + setting[2] < 'a' || setting[2] > 'z' || + !flags_by_subtype[(unsigned int)(unsigned char)setting[2] - 'a'] || setting[3] != '$' || setting[4] < '0' || setting[4] > '3' || setting[5] < '0' || setting[5] > '9' || @@ -627,14 +690,13 @@ static char *BF_crypt(__CONST char *key, __CONST char *setting, count = (BF_word)1 << ((setting[4] - '0') * 10 + (setting[5] - '0')); if (count < min || BF_decode(data.binary.salt, &setting[7], 16)) { - clean(data.binary.salt, sizeof(data.binary.salt)); __set_errno(EINVAL); return NULL; } - BF_swap(data.binary.salt, 4); - BF_set_key(key, data.expanded_key, data.ctx.P, setting[2] == 'x'); + BF_set_key(key, data.expanded_key, data.ctx.P, + flags_by_subtype[(unsigned int)(unsigned char)setting[2] - 'a']); memcpy(data.ctx.S, BF_init_state.S, sizeof(data.ctx.S)); @@ -664,51 +726,33 @@ static char *BF_crypt(__CONST char *key, __CONST char *setting, } while (ptr < &data.ctx.S[3][0xFF]); do { - data.ctx.P[0] ^= data.expanded_key[0]; - data.ctx.P[1] ^= data.expanded_key[1]; - data.ctx.P[2] ^= data.expanded_key[2]; - data.ctx.P[3] ^= data.expanded_key[3]; - data.ctx.P[4] ^= data.expanded_key[4]; - data.ctx.P[5] ^= data.expanded_key[5]; - data.ctx.P[6] ^= data.expanded_key[6]; - data.ctx.P[7] ^= data.expanded_key[7]; - data.ctx.P[8] ^= data.expanded_key[8]; - data.ctx.P[9] ^= data.expanded_key[9]; - data.ctx.P[10] ^= data.expanded_key[10]; - data.ctx.P[11] ^= data.expanded_key[11]; - data.ctx.P[12] ^= data.expanded_key[12]; - data.ctx.P[13] ^= data.expanded_key[13]; - data.ctx.P[14] ^= data.expanded_key[14]; - data.ctx.P[15] ^= data.expanded_key[15]; - data.ctx.P[16] ^= data.expanded_key[16]; - data.ctx.P[17] ^= data.expanded_key[17]; - - BF_body(); - - tmp1 = data.binary.salt[0]; - tmp2 = data.binary.salt[1]; - tmp3 = data.binary.salt[2]; - tmp4 = data.binary.salt[3]; - data.ctx.P[0] ^= tmp1; - data.ctx.P[1] ^= tmp2; - data.ctx.P[2] ^= tmp3; - data.ctx.P[3] ^= tmp4; - data.ctx.P[4] ^= tmp1; - data.ctx.P[5] ^= tmp2; - data.ctx.P[6] ^= tmp3; - data.ctx.P[7] ^= tmp4; - data.ctx.P[8] ^= tmp1; - data.ctx.P[9] ^= tmp2; - data.ctx.P[10] ^= tmp3; - data.ctx.P[11] ^= tmp4; - data.ctx.P[12] ^= tmp1; - data.ctx.P[13] ^= tmp2; - data.ctx.P[14] ^= tmp3; - data.ctx.P[15] ^= tmp4; - data.ctx.P[16] ^= tmp1; - data.ctx.P[17] ^= tmp2; - - BF_body(); + int done; + + for (i = 0; i < BF_N + 2; i += 2) { + data.ctx.P[i] ^= data.expanded_key[i]; + data.ctx.P[i + 1] ^= data.expanded_key[i + 1]; + } + + done = 0; + do { + BF_body(); + if (done) + break; + done = 1; + + tmp1 = data.binary.salt[0]; + tmp2 = data.binary.salt[1]; + tmp3 = data.binary.salt[2]; + tmp4 = data.binary.salt[3]; + for (i = 0; i < BF_N; i += 4) { + data.ctx.P[i] ^= tmp1; + data.ctx.P[i + 1] ^= tmp2; + data.ctx.P[i + 2] ^= tmp3; + data.ctx.P[i + 3] ^= tmp4; + } + data.ctx.P[16] ^= tmp1; + data.ctx.P[17] ^= tmp2; + } while (1); } while (--count); for (i = 0; i < 6; i += 2) { @@ -734,64 +778,114 @@ static char *BF_crypt(__CONST char *key, __CONST char *setting, BF_encode(&output[7 + 22], data.binary.output, 23); output[7 + 22 + 31] = '\0'; - #ifndef BF_SELF_TEST -/* Overwrite the most obvious sensitive data we have on the stack. Note - * that this does not guarantee there's no sensitive data left on the - * stack and/or in registers; I'm not aware of portable code that does. */ - clean(&data, sizeof(data)); -#endif - return output; } -char *php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, +static int _crypt_output_magic(const char *setting, char *output, int size) +{ + if (size < 3) + return -1; + + output[0] = '*'; + output[1] = '0'; + output[2] = '\0'; + + if (setting[0] == '*' && setting[1] == '0') + output[1] = '1'; + + return 0; +} + +/* + * Please preserve the runtime self-test. It serves two purposes at once: + * + * 1. We really can't afford the risk of producing incompatible hashes e.g. + * when there's something like gcc bug 26587 again, whereas an application or + * library integrating this code might not also integrate our external tests or + * it might not run them after every build. Even if it does, the miscompile + * might only occur on the production build, but not on a testing build (such + * as because of different optimization settings). It is painful to recover + * from incorrectly-computed hashes - merely fixing whatever broke is not + * enough. Thus, a proactive measure like this self-test is needed. + * + * 2. We don't want to leave sensitive data from our actual password hash + * computation on the stack or in registers. Previous revisions of the code + * would do explicit cleanups, but simply running the self-test after hash + * computation is more reliable. + * + * The performance cost of this quick self-test is around 0.6% at the "$2a$08" + * setting. + */ +char *php_crypt_blowfish_rn(const char *key, const char *setting, char *output, int size) { -#ifdef BF_SELF_TEST - __CONST char *test_key = "8b \xd0\xc1\xd2\xcf\xcc\xd8"; - __CONST char *test_2a = - "$2a$00$abcdefghijklmnopqrstuui1D709vfamulimlGcq0qq3UvuUasvEa" - "\0" - "canary"; - __CONST char *test_2x = - "$2x$00$abcdefghijklmnopqrstuuVUrPmXD6q/nVSSp7pNDhCR9071IfIRe" - "\0" - "canary"; - __CONST char *test_hash, *p; - int ok; - char buf[7 + 22 + 31 + 1 + 6 + 1]; - - output = BF_crypt(key, setting, output, size, 16); - -/* Do a quick self-test. This also happens to overwrite BF_crypt()'s data. */ - test_hash = (setting[2] == 'x') ? test_2x : test_2a; - memcpy(buf, test_hash, sizeof(buf)); - memset(buf, -1, sizeof(buf) - (6 + 1)); /* keep "canary" only */ - p = BF_crypt(test_key, test_hash, buf, sizeof(buf) - 6, 1); - - ok = (p == buf && !memcmp(p, test_hash, sizeof(buf))); - -/* This could reveal what hash type we were using last. Unfortunately, we - * can't reliably clean the test_hash pointer. */ - clean(&buf, sizeof(buf)); + const char *test_key = "8b \xd0\xc1\xd2\xcf\xcc\xd8"; + const char *test_setting = "$2a$00$abcdefghijklmnopqrstuu"; + static const char * const test_hash[2] = + {"VUrPmXD6q/nVSSp7pNDhCR9071IfIRe\0\x55", /* $2x$ */ + "i1D709vfamulimlGcq0qq3UvuUasvEa\0\x55"}; /* $2a$, $2y$ */ + char *retval; + const char *p; + int save_errno, ok; + struct { + char s[7 + 22 + 1]; + char o[7 + 22 + 31 + 1 + 1 + 1]; + } buf; +/* Hash the supplied password */ + _crypt_output_magic(setting, output, size); + retval = BF_crypt(key, setting, output, size, 16); + save_errno = errno; + +/* + * Do a quick self-test. It is important that we make both calls to BF_crypt() + * from the same scope such that they likely use the same stack locations, + * which makes the second call overwrite the first call's sensitive data on the + * stack and makes it more likely that any alignment related issues would be + * detected by the self-test. + */ + memcpy(buf.s, test_setting, sizeof(buf.s)); + if (retval) + buf.s[2] = setting[2]; + memset(buf.o, 0x55, sizeof(buf.o)); + buf.o[sizeof(buf.o) - 1] = 0; + p = BF_crypt(test_key, buf.s, buf.o, sizeof(buf.o) - (1 + 1), 1); + + ok = (p == buf.o && + !memcmp(p, buf.s, 7 + 22) && + !memcmp(p + (7 + 22), + test_hash[(unsigned int)(unsigned char)buf.s[2] & 1], + 31 + 1 + 1 + 1)); + + { + const char *k = "\xff\xa3" "34" "\xff\xff\xff\xa3" "345"; + BF_key ae, ai, ye, yi; + BF_set_key(k, ae, ai, 2); /* $2a$ */ + BF_set_key(k, ye, yi, 4); /* $2y$ */ + ai[0] ^= 0x10000; /* undo the safety (for comparison) */ + ok = ok && ai[0] == 0xdb9c59bc && ye[17] == 0x33343500 && + !memcmp(ae, ye, sizeof(ae)) && + !memcmp(ai, yi, sizeof(ai)); + } + + __set_errno(save_errno); if (ok) - return output; + return retval; /* Should not happen */ + _crypt_output_magic(setting, output, size); __set_errno(EINVAL); /* pretend we don't support this hash type */ return NULL; -#else -#warning Self-test is disabled, please enable - return BF_crypt(key, setting, output, size, 16); -#endif } -char *php_crypt_gensalt_blowfish_rn(unsigned long count, - __CONST char *input, int size, char *output, int output_size) +#if 0 +char *_crypt_gensalt_blowfish_rn(const char *prefix, unsigned long count, + const char *input, int size, char *output, int output_size) { if (size < 16 || output_size < 7 + 22 + 1 || - (count && (count < 4 || count > 31))) { + (count && (count < 4 || count > 31)) || + prefix[0] != '$' || prefix[1] != '2' || + (prefix[2] != 'a' && prefix[2] != 'y')) { if (output_size > 0) output[0] = '\0'; __set_errno((output_size < 7 + 22 + 1) ? ERANGE : EINVAL); return NULL; @@ -801,14 +895,15 @@ char *php_crypt_gensalt_blowfish_rn(unsigned long count, output[0] = '$'; output[1] = '2'; - output[2] = 'a'; + output[2] = prefix[2]; output[3] = '$'; - output[4] = (char) ('0' + count / 10); + output[4] = '0' + count / 10; output[5] = '0' + count % 10; output[6] = '$'; - BF_encode(&output[7], (BF_word *)input, 16); + BF_encode(&output[7], (const BF_word *)input, 16); output[7 + 22] = '\0'; return output; } +#endif diff --git a/ext/standard/crypt_blowfish.h b/ext/standard/crypt_blowfish.h new file mode 100644 index 0000000000000..34316854c8beb --- /dev/null +++ b/ext/standard/crypt_blowfish.h @@ -0,0 +1,32 @@ +/* $Id$ */ +/* + * Written by Solar Designer in 2000-2011. + * No copyright is claimed, and the software is hereby placed in the public + * domain. In case this attempt to disclaim copyright and place the software + * in the public domain is deemed null and void, then the software is + * Copyright (c) 2000-2011 Solar Designer and it is hereby released to the + * general public under the following terms: + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted. + * + * There's ABSOLUTELY NO WARRANTY, express or implied. + * + * See crypt_blowfish.c for more information. + */ + +#ifndef _CRYPT_BLOWFISH_H +#define _CRYPT_BLOWFISH_H + +#if 0 +extern int _crypt_output_magic(const char *setting, char *output, int size); +#endif +extern char *php_crypt_blowfish_rn(const char *key, const char *setting, + char *output, int size); +#if 0 +extern char *_crypt_gensalt_blowfish_rn(const char *prefix, + unsigned long count, + const char *input, int size, char *output, int output_size); +#endif + +#endif diff --git a/ext/standard/php_crypt_r.h b/ext/standard/php_crypt_r.h index 6bfaa298d2b40..d515a5ea4cebd 100644 --- a/ext/standard/php_crypt_r.h +++ b/ext/standard/php_crypt_r.h @@ -46,9 +46,9 @@ PHPAPI char *php_crypt_r (const char *__key, const char *__salt, struct php_cryp #define MD5_HASH_MAX_LEN 120 +#include "crypt_blowfish.h" + extern char * php_md5_crypt_r(const char *pw, const char *salt, char *out); -extern char * php_crypt_blowfish_rn(__CONST char *key, __CONST char *setting, - char *output, int size); extern char * php_sha512_crypt_r (const char *key, const char *salt, char *buffer, int buflen); extern char * php_sha256_crypt_r (const char *key, const char *salt, char *buffer, int buflen); From 9fa7a7e554219a3a1f864aa47e00eb287b0f750c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Mon, 18 Jul 2011 21:49:38 +0000 Subject: [PATCH 0335/2394] order fpm configuration items the same way in php-fpm.conf.in, fpm_conf.h and fpm_conf.c --- sapi/fpm/fpm/fpm_conf.c | 276 +++++++++++++++++++++------------------ sapi/fpm/fpm/fpm_conf.h | 50 +++---- sapi/fpm/php-fpm.conf.in | 48 +++---- 3 files changed, 203 insertions(+), 171 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index edb514f1be419..c2ae52797eccd 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -76,53 +76,59 @@ static char *ini_filename = NULL; static int ini_lineno = 0; static char *ini_include = NULL; +/* + * Please keep the same order as in fpm_conf.h and in php-fpm.conf.in + */ static struct ini_value_parser_s ini_fpm_global_options[] = { - { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, - { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, - { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, - { "process.max", &fpm_conf_set_integer, GO(process_max) }, - { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, { "pid", &fpm_conf_set_string, GO(pid_file) }, { "error_log", &fpm_conf_set_string, GO(error_log) }, - { "log_level", &fpm_conf_set_log_level, GO(log_level) }, #ifdef HAVE_SYSLOG_H { "syslog.ident", &fpm_conf_set_string, GO(syslog_ident) }, { "syslog.facility", &fpm_conf_set_syslog_facility, GO(syslog_facility) }, #endif + { "log_level", &fpm_conf_set_log_level, GO(log_level) }, + { "emergency_restart_threshold", &fpm_conf_set_integer, GO(emergency_restart_threshold) }, + { "emergency_restart_interval", &fpm_conf_set_time, GO(emergency_restart_interval) }, + { "process_control_timeout", &fpm_conf_set_time, GO(process_control_timeout) }, + { "process.max", &fpm_conf_set_integer, GO(process_max) }, + { "daemonize", &fpm_conf_set_boolean, GO(daemonize) }, { "rlimit_files", &fpm_conf_set_integer, GO(rlimit_files) }, { "rlimit_core", &fpm_conf_set_rlimit_core, GO(rlimit_core) }, { 0, 0, 0 } }; +/* + * Please keep the same order as in fpm_conf.h and in php-fpm.conf.in + */ static struct ini_value_parser_s ini_fpm_pool_options[] = { { "prefix", &fpm_conf_set_string, WPO(prefix) }, { "user", &fpm_conf_set_string, WPO(user) }, { "group", &fpm_conf_set_string, WPO(group) }, - { "chroot", &fpm_conf_set_string, WPO(chroot) }, - { "chdir", &fpm_conf_set_string, WPO(chdir) }, - { "request_terminate_timeout", &fpm_conf_set_time, WPO(request_terminate_timeout) }, - { "request_slowlog_timeout", &fpm_conf_set_time, WPO(request_slowlog_timeout) }, - { "slowlog", &fpm_conf_set_string, WPO(slowlog) }, - { "rlimit_files", &fpm_conf_set_integer, WPO(rlimit_files) }, - { "rlimit_core", &fpm_conf_set_rlimit_core, WPO(rlimit_core) }, - { "catch_workers_output", &fpm_conf_set_boolean, WPO(catch_workers_output) }, { "listen", &fpm_conf_set_string, WPO(listen_address) }, + { "listen.backlog", &fpm_conf_set_integer, WPO(listen_backlog) }, { "listen.owner", &fpm_conf_set_string, WPO(listen_owner) }, { "listen.group", &fpm_conf_set_string, WPO(listen_group) }, { "listen.mode", &fpm_conf_set_string, WPO(listen_mode) }, - { "listen.backlog", &fpm_conf_set_integer, WPO(listen_backlog) }, { "listen.allowed_clients", &fpm_conf_set_string, WPO(listen_allowed_clients) }, { "pm", &fpm_conf_set_pm, WPO(pm) }, - { "pm.max_requests", &fpm_conf_set_integer, WPO(pm_max_requests) }, { "pm.max_children", &fpm_conf_set_integer, WPO(pm_max_children) }, { "pm.start_servers", &fpm_conf_set_integer, WPO(pm_start_servers) }, { "pm.min_spare_servers", &fpm_conf_set_integer, WPO(pm_min_spare_servers) }, { "pm.max_spare_servers", &fpm_conf_set_integer, WPO(pm_max_spare_servers) }, + { "pm.max_requests", &fpm_conf_set_integer, WPO(pm_max_requests) }, { "pm.status_path", &fpm_conf_set_string, WPO(pm_status_path) }, { "ping.path", &fpm_conf_set_string, WPO(ping_path) }, { "ping.response", &fpm_conf_set_string, WPO(ping_response) }, { "access.log", &fpm_conf_set_string, WPO(access_log) }, { "access.format", &fpm_conf_set_string, WPO(access_format) }, + { "slowlog", &fpm_conf_set_string, WPO(slowlog) }, + { "request_slowlog_timeout", &fpm_conf_set_time, WPO(request_slowlog_timeout) }, + { "request_terminate_timeout", &fpm_conf_set_time, WPO(request_terminate_timeout) }, + { "rlimit_files", &fpm_conf_set_integer, WPO(rlimit_files) }, + { "rlimit_core", &fpm_conf_set_rlimit_core, WPO(rlimit_core) }, + { "chroot", &fpm_conf_set_string, WPO(chroot) }, + { "chdir", &fpm_conf_set_string, WPO(chdir) }, + { "catch_workers_output", &fpm_conf_set_boolean, WPO(catch_workers_output) }, { "security.limit_extensions", &fpm_conf_set_string, WPO(security_limit_extensions) }, { 0, 0, 0 } }; @@ -568,13 +574,24 @@ int fpm_worker_pool_config_free(struct fpm_worker_pool_config_s *wpc) /* {{{ */ struct key_value_s *kv, *kv_next; free(wpc->name); - free(wpc->pm_status_path); - free(wpc->ping_path); - free(wpc->ping_response); + free(wpc->prefix); + free(wpc->user); + free(wpc->group); free(wpc->listen_address); free(wpc->listen_owner); free(wpc->listen_group); free(wpc->listen_mode); + free(wpc->listen_allowed_clients); + free(wpc->pm_status_path); + free(wpc->ping_path); + free(wpc->ping_response); + free(wpc->access_log); + free(wpc->access_format); + free(wpc->slowlog); + free(wpc->chroot); + free(wpc->chdir); + free(wpc->security_limit_extensions); + for (kv = wpc->php_values; kv; kv = kv_next) { kv_next = kv->next; free(kv->key); @@ -593,16 +610,6 @@ int fpm_worker_pool_config_free(struct fpm_worker_pool_config_s *wpc) /* {{{ */ free(kv->value); free(kv); } - free(wpc->listen_allowed_clients); - free(wpc->user); - free(wpc->group); - free(wpc->chroot); - free(wpc->chdir); - free(wpc->slowlog); - free(wpc->prefix); - free(wpc->access_log); - free(wpc->access_format); - free(wpc->security_limit_extensions); return 0; } @@ -679,6 +686,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ for (wp = fpm_worker_all_pools; wp; wp = wp->next) { + /* prefix */ if (wp->config->prefix && *wp->config->prefix) { fpm_evaluate_full_path(&wp->config->prefix, NULL, NULL, 0); @@ -688,6 +696,13 @@ static int fpm_conf_process_all_pools() /* {{{ */ } } + /* user */ + if (!wp->config->user) { + zlog(ZLOG_ALERT, "[pool %s] user has not been defined", wp->config->name); + return -1; + } + + /* listen */ if (wp->config->listen_address && *wp->config->listen_address) { wp->listen_address_domain = fpm_sockets_domain_from_address(wp->config->listen_address); @@ -699,21 +714,19 @@ static int fpm_conf_process_all_pools() /* {{{ */ return -1; } - if (!wp->config->user) { - zlog(ZLOG_ALERT, "[pool %s] user has not been defined", wp->config->name); - return -1; - } - + /* pm */ if (wp->config->pm != PM_STYLE_STATIC && wp->config->pm != PM_STYLE_DYNAMIC) { zlog(ZLOG_ALERT, "[pool %s] the process manager is missing (static or dynamic)", wp->config->name); return -1; } + /* pm.max_children */ if (wp->config->pm_max_children < 1) { zlog(ZLOG_ALERT, "[pool %s] pm.max_children must be a positive value", wp->config->name); return -1; } + /* pm.start_servers, pm.min_spare_servers, pm.max_spare_servers */ if (wp->config->pm == PM_STYLE_DYNAMIC) { struct fpm_worker_pool_config_s *config = wp->config; @@ -749,40 +762,31 @@ static int fpm_conf_process_all_pools() /* {{{ */ } - if (wp->config->slowlog && *wp->config->slowlog) { - fpm_evaluate_full_path(&wp->config->slowlog, wp, NULL, 0); - } + /* status */ + if (wp->config->pm_status_path && *wp->config->pm_status_path) { + int i; + char *status = wp->config->pm_status_path; + /* struct fpm_status_s fpm_status; */ - if (wp->config->request_slowlog_timeout) { -#if HAVE_FPM_TRACE - if (! (wp->config->slowlog && *wp->config->slowlog)) { - zlog(ZLOG_ERROR, "[pool %s] 'slowlog' must be specified for use with 'request_slowlog_timeout'", wp->config->name); + if (*status != '/') { + zlog(ZLOG_ERROR, "[pool %s] the status path '%s' must start with a '/'", wp->config->name, status); return -1; } -#else - static int warned = 0; - if (!warned) { - zlog(ZLOG_WARNING, "[pool %s] 'request_slowlog_timeout' is not supported on your system", wp->config->name); - warned = 1; + if (strlen(status) < 2) { + zlog(ZLOG_ERROR, "[pool %s] the status path '%s' is not long enough", wp->config->name, status); + return -1; } - wp->config->request_slowlog_timeout = 0; -#endif - - if (wp->config->slowlog && *wp->config->slowlog) { - int fd; - - fd = open(wp->config->slowlog, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); - - if (0 > fd) { - zlog(ZLOG_SYSERROR, "open(%s) failed", wp->config->slowlog); + for (i = 0; i < strlen(status); i++) { + if (!isalnum(status[i]) && status[i] != '/' && status[i] != '-' && status[i] != '_' && status[i] != '.') { + zlog(ZLOG_ERROR, "[pool %s] the status path '%s' must contain only the following characters '[alphanum]/_-.'", wp->config->name, status); return -1; } - close(fd); } } + /* ping */ if (wp->config->ping_path && *wp->config->ping_path) { char *ping = wp->config->ping_path; int i; @@ -819,36 +823,96 @@ static int fpm_conf_process_all_pools() /* {{{ */ } } - if (wp->config->pm_status_path && *wp->config->pm_status_path) { - int i; - char *status = wp->config->pm_status_path; - /* struct fpm_status_s fpm_status; */ + /* access.log, access.format */ + if (wp->config->access_log && *wp->config->access_log) { + fpm_evaluate_full_path(&wp->config->access_log, wp, NULL, 0); + if (!wp->config->access_format) { + wp->config->access_format = strdup("%R - %u %t \"%m %r\" %s"); + } + } - if (*status != '/') { - zlog(ZLOG_ERROR, "[pool %s] the status path '%s' must start with a '/'", wp->config->name, status); + /* slowlog */ + if (wp->config->slowlog && *wp->config->slowlog) { + fpm_evaluate_full_path(&wp->config->slowlog, wp, NULL, 0); + } + + /* request_slowlog_timeout */ + if (wp->config->request_slowlog_timeout) { +#if HAVE_FPM_TRACE + if (! (wp->config->slowlog && *wp->config->slowlog)) { + zlog(ZLOG_ERROR, "[pool %s] 'slowlog' must be specified for use with 'request_slowlog_timeout'", wp->config->name); return -1; } +#else + static int warned = 0; - if (strlen(status) < 2) { - zlog(ZLOG_ERROR, "[pool %s] the status path '%s' is not long enough", wp->config->name, status); - return -1; + if (!warned) { + zlog(ZLOG_WARNING, "[pool %s] 'request_slowlog_timeout' is not supported on your system", wp->config->name); + warned = 1; } - for (i = 0; i < strlen(status); i++) { - if (!isalnum(status[i]) && status[i] != '/' && status[i] != '-' && status[i] != '_' && status[i] != '.') { - zlog(ZLOG_ERROR, "[pool %s] the status path '%s' must contain only the following characters '[alphanum]/_-.'", wp->config->name, status); + wp->config->request_slowlog_timeout = 0; +#endif + + if (wp->config->slowlog && *wp->config->slowlog) { + int fd; + + fd = open(wp->config->slowlog, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); + + if (0 > fd) { + zlog(ZLOG_SYSERROR, "open(%s) failed", wp->config->slowlog); return -1; } + close(fd); } } - if (wp->config->access_log && *wp->config->access_log) { - fpm_evaluate_full_path(&wp->config->access_log, wp, NULL, 0); - if (!wp->config->access_format) { - wp->config->access_format = strdup("%R - %u %t \"%m %r\" %s"); + /* chroot */ + if (wp->config->chroot && *wp->config->chroot) { + + fpm_evaluate_full_path(&wp->config->chroot, wp, NULL, 1); + + if (*wp->config->chroot != '/') { + zlog(ZLOG_ERROR, "[pool %s] the chroot path '%s' must start with a '/'", wp->config->name, wp->config->chroot); + return -1; + } + if (!fpm_conf_is_dir(wp->config->chroot)) { + zlog(ZLOG_ERROR, "[pool %s] the chroot path '%s' does not exist or is not a directory", wp->config->name, wp->config->chroot); + return -1; } } + /* chdir */ + if (wp->config->chdir && *wp->config->chdir) { + + fpm_evaluate_full_path(&wp->config->chdir, wp, NULL, 0); + + if (*wp->config->chdir != '/') { + zlog(ZLOG_ERROR, "[pool %s] the chdir path '%s' must start with a '/'", wp->config->name, wp->config->chdir); + return -1; + } + + if (wp->config->chroot) { + char *buf; + + spprintf(&buf, 0, "%s/%s", wp->config->chroot, wp->config->chdir); + + if (!fpm_conf_is_dir(buf)) { + zlog(ZLOG_ERROR, "[pool %s] the chdir path '%s' within the chroot path '%s' ('%s') does not exist or is not a directory", wp->config->name, wp->config->chdir, wp->config->chroot, buf); + efree(buf); + return -1; + } + + efree(buf); + } else { + if (!fpm_conf_is_dir(wp->config->chdir)) { + zlog(ZLOG_ERROR, "[pool %s] the chdir path '%s' does not exist or is not a directory", wp->config->name, wp->config->chdir); + return -1; + } + } + } + + /* security.limit_extensions */ if (!wp->config->security_limit_extensions) { wp->config->security_limit_extensions = strdup(".php"); } @@ -899,48 +963,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ } } - if (wp->config->chroot && *wp->config->chroot) { - - fpm_evaluate_full_path(&wp->config->chroot, wp, NULL, 1); - - if (*wp->config->chroot != '/') { - zlog(ZLOG_ERROR, "[pool %s] the chroot path '%s' must start with a '/'", wp->config->name, wp->config->chroot); - return -1; - } - if (!fpm_conf_is_dir(wp->config->chroot)) { - zlog(ZLOG_ERROR, "[pool %s] the chroot path '%s' does not exist or is not a directory", wp->config->name, wp->config->chroot); - return -1; - } - } - - if (wp->config->chdir && *wp->config->chdir) { - - fpm_evaluate_full_path(&wp->config->chdir, wp, NULL, 0); - - if (*wp->config->chdir != '/') { - zlog(ZLOG_ERROR, "[pool %s] the chdir path '%s' must start with a '/'", wp->config->name, wp->config->chdir); - return -1; - } - - if (wp->config->chroot) { - char *buf; - - spprintf(&buf, 0, "%s/%s", wp->config->chroot, wp->config->chdir); - - if (!fpm_conf_is_dir(buf)) { - zlog(ZLOG_ERROR, "[pool %s] the chdir path '%s' within the chroot path '%s' ('%s') does not exist or is not a directory", wp->config->name, wp->config->chdir, wp->config->chroot, buf); - efree(buf); - return -1; - } - - efree(buf); - } else { - if (!fpm_conf_is_dir(wp->config->chdir)) { - zlog(ZLOG_ERROR, "[pool %s] the chdir path '%s' does not exist or is not a directory", wp->config->name, wp->config->chdir); - return -1; - } - } - } + /* env[], php_value[], php_admin_values[] */ if (!wp->config->chroot) { struct key_value_s *kv; char *options[] = FPM_PHP_INI_TO_EXPAND; @@ -1391,19 +1414,22 @@ static void fpm_conf_dump() /* {{{ */ { struct fpm_worker_pool_s *wp; + /* + * Please keep the same order as in fpm_conf.h and in php-fpm.conf.in + */ zlog(ZLOG_NOTICE, "[General]"); zlog(ZLOG_NOTICE, "\tpid = %s", STR2STR(fpm_global_config.pid_file)); - zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize)); zlog(ZLOG_NOTICE, "\terror_log = %s", STR2STR(fpm_global_config.error_log)); - zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name(fpm_globals.log_level)); #ifdef HAVE_SYSLOG_H zlog(ZLOG_NOTICE, "\tsyslog.ident = %s", STR2STR(fpm_global_config.syslog_ident)); zlog(ZLOG_NOTICE, "\tsyslog.facility = %d", fpm_global_config.syslog_facility); /* FIXME: convert to string */ #endif - zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); - zlog(ZLOG_NOTICE, "\tprocess.max = %d", fpm_global_config.process_max); + zlog(ZLOG_NOTICE, "\tlog_level = %s", zlog_get_level_name(fpm_globals.log_level)); zlog(ZLOG_NOTICE, "\temergency_restart_interval = %ds", fpm_global_config.emergency_restart_interval); zlog(ZLOG_NOTICE, "\temergency_restart_threshold = %d", fpm_global_config.emergency_restart_threshold); + zlog(ZLOG_NOTICE, "\tprocess_control_timeout = %ds", fpm_global_config.process_control_timeout); + zlog(ZLOG_NOTICE, "\tprocess.max = %d", fpm_global_config.process_max); + zlog(ZLOG_NOTICE, "\tdaemonize = %s", BOOL2STR(fpm_global_config.daemonize)); zlog(ZLOG_NOTICE, "\trlimit_files = %d", fpm_global_config.rlimit_files); zlog(ZLOG_NOTICE, "\trlimit_core = %d", fpm_global_config.rlimit_core); zlog(ZLOG_NOTICE, " "); @@ -1415,8 +1441,6 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tprefix = %s", STR2STR(wp->config->prefix)); zlog(ZLOG_NOTICE, "\tuser = %s", STR2STR(wp->config->user)); zlog(ZLOG_NOTICE, "\tgroup = %s", STR2STR(wp->config->group)); - zlog(ZLOG_NOTICE, "\tchroot = %s", STR2STR(wp->config->chroot)); - zlog(ZLOG_NOTICE, "\tchdir = %s", STR2STR(wp->config->chdir)); zlog(ZLOG_NOTICE, "\tlisten = %s", STR2STR(wp->config->listen_address)); zlog(ZLOG_NOTICE, "\tlisten.backlog = %d", wp->config->listen_backlog); zlog(ZLOG_NOTICE, "\tlisten.owner = %s", STR2STR(wp->config->listen_owner)); @@ -1425,21 +1449,23 @@ static void fpm_conf_dump() /* {{{ */ zlog(ZLOG_NOTICE, "\tlisten.allowed_clients = %s", STR2STR(wp->config->listen_allowed_clients)); zlog(ZLOG_NOTICE, "\tpm = %s", PM2STR(wp->config->pm)); zlog(ZLOG_NOTICE, "\tpm.max_children = %d", wp->config->pm_max_children); - zlog(ZLOG_NOTICE, "\tpm.max_requests = %d", wp->config->pm_max_requests); zlog(ZLOG_NOTICE, "\tpm.start_servers = %d", wp->config->pm_start_servers); zlog(ZLOG_NOTICE, "\tpm.min_spare_servers = %d", wp->config->pm_min_spare_servers); zlog(ZLOG_NOTICE, "\tpm.max_spare_servers = %d", wp->config->pm_max_spare_servers); + zlog(ZLOG_NOTICE, "\tpm.max_requests = %d", wp->config->pm_max_requests); zlog(ZLOG_NOTICE, "\tpm.status_path = %s", STR2STR(wp->config->pm_status_path)); zlog(ZLOG_NOTICE, "\tping.path = %s", STR2STR(wp->config->ping_path)); zlog(ZLOG_NOTICE, "\tping.response = %s", STR2STR(wp->config->ping_response)); zlog(ZLOG_NOTICE, "\taccess.log = %s", STR2STR(wp->config->access_log)); zlog(ZLOG_NOTICE, "\taccess.format = %s", STR2STR(wp->config->access_format)); - zlog(ZLOG_NOTICE, "\tcatch_workers_output = %s", BOOL2STR(wp->config->catch_workers_output)); - zlog(ZLOG_NOTICE, "\trequest_terminate_timeout = %ds", wp->config->request_terminate_timeout); - zlog(ZLOG_NOTICE, "\trequest_slowlog_timeout = %ds", wp->config->request_slowlog_timeout); zlog(ZLOG_NOTICE, "\tslowlog = %s", STR2STR(wp->config->slowlog)); + zlog(ZLOG_NOTICE, "\trequest_slowlog_timeout = %ds", wp->config->request_slowlog_timeout); + zlog(ZLOG_NOTICE, "\trequest_terminate_timeout = %ds", wp->config->request_terminate_timeout); zlog(ZLOG_NOTICE, "\trlimit_files = %d", wp->config->rlimit_files); zlog(ZLOG_NOTICE, "\trlimit_core = %d", wp->config->rlimit_core); + zlog(ZLOG_NOTICE, "\tchroot = %s", STR2STR(wp->config->chroot)); + zlog(ZLOG_NOTICE, "\tchdir = %s", STR2STR(wp->config->chdir)); + zlog(ZLOG_NOTICE, "\tcatch_workers_output = %s", BOOL2STR(wp->config->catch_workers_output)); zlog(ZLOG_NOTICE, "\tsecurity.limit_extensions = %s", wp->config->security_limit_extensions); for (kv = wp->config->env; kv; kv = kv->next) { diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index 11c688ae7b4db..027e21f8bbed5 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -18,55 +18,61 @@ struct key_value_s { char *value; }; +/* + * Please keep the same order as in fpm_conf.c and in php-fpm.conf.in + */ struct fpm_global_config_s { - int emergency_restart_threshold; - int emergency_restart_interval; - int process_control_timeout; - int daemonize; char *pid_file; char *error_log; - int log_level; #ifdef HAVE_SYSLOG_H char *syslog_ident; int syslog_facility; #endif + int log_level; + int emergency_restart_threshold; + int emergency_restart_interval; + int process_control_timeout; + int process_max; + int daemonize; int rlimit_files; int rlimit_core; - int process_max; }; extern struct fpm_global_config_s fpm_global_config; +/* + * Please keep the same order as in fpm_conf.c and in php-fpm.conf.in + */ struct fpm_worker_pool_config_s { char *name; char *prefix; char *user; char *group; - char *chroot; - char *chdir; - int request_terminate_timeout; - int request_slowlog_timeout; - char *slowlog; - int rlimit_files; - int rlimit_core; - int catch_workers_output; + char *listen_address; + int listen_backlog; + char *listen_owner; + char *listen_group; + char *listen_mode; + char *listen_allowed_clients; int pm; int pm_max_children; - char *pm_status_path; - int pm_max_requests; int pm_start_servers; int pm_min_spare_servers; int pm_max_spare_servers; + int pm_max_requests; + char *pm_status_path; char *ping_path; char *ping_response; char *access_log; char *access_format; - char *listen_address; - int listen_backlog; - char *listen_owner; - char *listen_group; - char *listen_mode; - char *listen_allowed_clients; + char *slowlog; + int request_slowlog_timeout; + int request_terminate_timeout; + int rlimit_files; + int rlimit_core; + char *chroot; + char *chdir; + int catch_workers_output; char *security_limit_extensions; struct key_value_s *env; struct key_value_s *php_admin_values; diff --git a/sapi/fpm/php-fpm.conf.in b/sapi/fpm/php-fpm.conf.in index 76a1c36368b9a..bd2b6c01aff31 100644 --- a/sapi/fpm/php-fpm.conf.in +++ b/sapi/fpm/php-fpm.conf.in @@ -116,6 +116,12 @@ ; Default Value: none ;prefix = /path/to/pools/$pool +; Unix user/group of processes +; Note: The user is mandatory. If the group is not set, the default user's group +; will be used. +user = @php_fpm_user@ +group = @php_fpm_group@ + ; The address on which to accept FastCGI requests. ; Valid syntaxes are: ; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific address on @@ -129,14 +135,6 @@ listen = 127.0.0.1:9000 ; Set listen(2) backlog. ; Default Value: 128 (-1 on FreeBSD and OpenBSD) ;listen.backlog = 128 - -; List of ipv4 addresses of FastCGI clients which are allowed to connect. -; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original -; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address -; must be separated by a comma. If this value is left blank, connections will be -; accepted from any ip address. -; Default Value: any -;listen.allowed_clients = 127.0.0.1 ; Set permissions for unix socket, if one is used. In Linux, read/write ; permissions must be set in order to allow connections from a web server. Many @@ -146,12 +144,14 @@ listen = 127.0.0.1:9000 ;listen.owner = @php_fpm_user@ ;listen.group = @php_fpm_group@ ;listen.mode = 0666 - -; Unix user/group of processes -; Note: The user is mandatory. If the group is not set, the default user's group -; will be used. -user = @php_fpm_user@ -group = @php_fpm_group@ + +; List of ipv4 addresses of FastCGI clients which are allowed to connect. +; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original +; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address +; must be separated by a comma. If this value is left blank, connections will be +; accepted from any ip address. +; Default Value: any +;listen.allowed_clients = 127.0.0.1 ; Choose how the process manager will control the number of child processes. ; Possible Values: @@ -379,12 +379,10 @@ pm.max_spare_servers = 3 ; Default: "%R - %u %t \"%m %r\" %s" ;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%" -; The timeout for serving a single request after which the worker process will -; be killed. This option should be used when the 'max_execution_time' ini option -; does not stop script execution for some reason. A value of '0' means 'off'. -; Available units: s(econds)(default), m(inutes), h(ours), or d(ays) -; Default Value: 0 -;request_terminate_timeout = 0 +; The log file for slow requests +; Default Value: not set +; Note: slowlog is mandatory if request_slowlog_timeout is set +;slowlog = log/$pool.log.slow ; The timeout for serving a single request after which a PHP backtrace will be ; dumped to the 'slowlog' file. A value of '0s' means 'off'. @@ -392,10 +390,12 @@ pm.max_spare_servers = 3 ; Default Value: 0 ;request_slowlog_timeout = 0 -; The log file for slow requests -; Default Value: not set -; Note: slowlog is mandatory if request_slowlog_timeout is set -;slowlog = log/$pool.log.slow +; The timeout for serving a single request after which the worker process will +; be killed. This option should be used when the 'max_execution_time' ini option +; does not stop script execution for some reason. A value of '0' means 'off'. +; Available units: s(econds)(default), m(inutes), h(ours), or d(ays) +; Default Value: 0 +;request_terminate_timeout = 0 ; Set open file descriptor rlimit. ; Default Value: system defined value From 101a9ee4e228329ab8d669a935381acb3f042465 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 19 Jul 2011 10:22:42 +0000 Subject: [PATCH 0336/2394] - update libpng to 1.2.46 --- win32/build/libs_version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/win32/build/libs_version.txt b/win32/build/libs_version.txt index 2dd6933dae99c..282afb790bf1e 100644 --- a/win32/build/libs_version.txt +++ b/win32/build/libs_version.txt @@ -1,2 +1,2 @@ libcurl-7.21.6 -libpng-1.2.45 +libpng-1.2.46 From 8ebba9c69df50446d501ffabe4217f71b422927f Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 19 Jul 2011 12:02:22 +0000 Subject: [PATCH 0337/2394] - cleanup --- php.ini-development | 3 --- php.ini-production | 1 - 2 files changed, 4 deletions(-) diff --git a/php.ini-development b/php.ini-development index 3c161360b8923..92185959f7232 100644 --- a/php.ini-development +++ b/php.ini-development @@ -883,7 +883,6 @@ default_socket_timeout = 60 ; ;extension=php_bz2.dll ;extension=php_curl.dll -;extension=php_dba.dll ;extension=php_fileinfo.dll ;extension=php_gd2.dll ;extension=php_gettext.dll @@ -894,8 +893,6 @@ default_socket_timeout = 60 ;extension=php_ldap.dll ;extension=php_mbstring.dll ;extension=php_exif.dll ; Must be after mbstring as it depends on it -;extension=php_ming.dll -;extension=php_mssql.dll ;extension=php_mysql.dll ;extension=php_mysqli.dll ;extension=php_oci8.dll ; Use with Oracle 10gR2 Instant Client diff --git a/php.ini-production b/php.ini-production index 869f0c6ceb07c..576cf41479778 100644 --- a/php.ini-production +++ b/php.ini-production @@ -899,7 +899,6 @@ default_socket_timeout = 60 ;extension=php_oci8_11g.dll ; Use with Oracle 11g Instant Client ;extension=php_openssl.dll ;extension=php_pdo_firebird.dll -;extension=php_pdo_mssql.dll ;extension=php_pdo_mysql.dll ;extension=php_pdo_oci.dll ;extension=php_pdo_odbc.dll From 8e42748a37b9de490760650c18cf73e0ece8d355 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Tue, 19 Jul 2011 17:47:34 +0000 Subject: [PATCH 0338/2394] - Print HTTP method as well in the log. - Print response code also when the request is processed by a script. - Those changes partly closes #55109. --- sapi/cli/php_cli_server.c | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 66d3bc5ae487d..c9a26ae8f1d82 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1479,7 +1479,7 @@ static void php_cli_server_client_dtor(php_cli_server_client *client) /* {{{ */ static void php_cli_server_close_connection(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ { #ifdef DEBUG - php_cli_server_logf("%s: Closing" TSRMLS_CC, client->addr_str); + php_cli_server_logf("%s Closing" TSRMLS_CC, client->addr_str); #endif zend_hash_index_del(&server->clients, client->sock); } /* }}} */ @@ -1575,7 +1575,7 @@ static int php_cli_server_send_error_page(php_cli_server *server, php_cli_server php_cli_server_buffer_prepend(&client->content_sender.buffer, chunk); } - php_cli_server_logf("%s: %s - Sending error page (%d)" TSRMLS_CC, client->addr_str, client->request.request_uri, status); + php_cli_server_logf("%s %s %s - Sending error page (%d)" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri, status); php_cli_server_poller_add(&server->poller, POLLOUT, client->sock); efree(escaped_request_uri); return SUCCESS; @@ -1612,6 +1612,8 @@ static int php_cli_server_dispatch_script(php_cli_server *server, php_cli_server } zend_end_try(); } + php_cli_server_logf("%s %s %s - Response sent successfully (%d)" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri, SG(sapi_headers).http_response_code); + php_request_shutdown(0); php_cli_server_close_connection(server, client TSRMLS_CC); destroy_request_info(&SG(request_info)); @@ -1627,10 +1629,10 @@ static int php_cli_server_begin_send_static(php_cli_server *server, php_cli_serv if (fd < 0) { char *errstr = get_last_error(); if (errstr) { - php_cli_server_logf("%s: %s - %s" TSRMLS_CC, client->addr_str, client->request.request_uri, errstr); + php_cli_server_logf("%s %s %s - %s" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri, errstr); pefree(errstr, 1); } else { - php_cli_server_logf("%s: %s - ?" TSRMLS_CC, client->addr_str, client->request.request_uri); + php_cli_server_logf("%s %s %s - ?" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri); } return php_cli_server_send_error_page(server, client, 404 TSRMLS_CC); } @@ -1880,12 +1882,12 @@ static int php_cli_server_recv_event_read_request(php_cli_server *server, php_cl char *errstr = NULL; int status = php_cli_server_client_read_request(client, &errstr TSRMLS_CC); if (status < 0) { - php_cli_server_logf("%s: Invalid request (%s)" TSRMLS_CC, client->addr_str, errstr); + php_cli_server_logf("%s Invalid request (%s)" TSRMLS_CC, client->addr_str, errstr); efree(errstr); php_cli_server_close_connection(server, client TSRMLS_CC); return FAILURE; } else if (status == 1) { - php_cli_server_logf("%s: %s" TSRMLS_CC, client->addr_str, client->request.request_uri); + php_cli_server_logf("%s %s %s - Request read" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri); php_cli_server_poller_remove(&server->poller, POLLIN, client->sock); php_cli_server_dispatch(server, client TSRMLS_CC); } else { @@ -1970,7 +1972,7 @@ static int php_cli_server_do_event_for_each_fd_callback(void *_params, int fd, i return SUCCESS; } #ifdef DEBUG - php_cli_server_logf("%s: Accepted" TSRMLS_CC, client->addr_str); + php_cli_server_logf("%s Accepted" TSRMLS_CC, client->addr_str); #endif zend_hash_index_update(&server->clients, client_sock, &client, sizeof(client), NULL); php_cli_server_recv_event_read_request(server, client TSRMLS_CC); From 7505322d15e7b4909936c8e50eea38ffac0a7ec2 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Tue, 19 Jul 2011 18:00:16 +0000 Subject: [PATCH 0339/2394] - Buffers are local to the blocks where they belong. --- sapi/cli/php_cli_server.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index c9a26ae8f1d82..f02f2520e4ce6 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2048,6 +2048,7 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ extern const opt_struct OPTIONS[]; const char *document_root = NULL; const char *router = NULL; + char document_root_buf[MAXPATHLEN]; while ((c = php_getopt(argc, argv, OPTIONS, &php_optarg, &php_optind, 0, 2))!=-1) { switch (c) { @@ -2062,7 +2063,6 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ if (document_root) { struct stat sb; - char resolved_path[MAXPATHLEN]; if (stat(document_root, &sb)) { fprintf(stderr, "Directory %s does not exist.\n", document_root); @@ -2072,19 +2072,18 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ fprintf(stderr, "%s is not a directory.\n", document_root); return 1; } - if (VCWD_REALPATH(document_root, resolved_path)) { - document_root = resolved_path; + if (VCWD_REALPATH(document_root, document_root_buf)) { + document_root = document_root_buf; } } else { - char path[MAXPATHLEN]; char *ret = NULL; #if HAVE_GETCWD - ret = VCWD_GETCWD(path, MAXPATHLEN); + ret = VCWD_GETCWD(document_root_buf, MAXPATHLEN); #elif HAVE_GETWD - ret = VCWD_GETWD(path); + ret = VCWD_GETWD(document_root_buf); #endif - document_root = ret ? path : "."; + document_root = ret ? document_root_buf: "."; } if (argc > php_optind) { From 9f98a430fd2b7e18635cb2a3a3bab157eee06a41 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Tue, 19 Jul 2011 18:17:25 +0000 Subject: [PATCH 0340/2394] - Fixed bug #55107 (Null bytes in URL cause insecure behavior (code execution / code disclosure)). --- sapi/cli/php_cli_server.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index f02f2520e4ce6..bad7d512132d4 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -242,6 +242,7 @@ static php_cli_server_http_reponse_status_code_pair status_map[] = { }; static php_cli_server_http_reponse_status_code_pair template_map[] = { + { 400, "

%s

Your browser sent a request that this server could not understand.

" }, { 404, "

%s

The requested resource %s was not found on this server.

" }, { 500, "

%s

The server is temporality unavaiable.

" } }; @@ -1600,6 +1601,11 @@ static int php_cli_server_dispatch_script(php_cli_server *server, php_cli_server destroy_request_info(&SG(request_info)); return FAILURE; } + if (strlen(client->request.path_translated) != client->request.path_translated_len) { + /* can't handle paths that contain nul bytes */ + destroy_request_info(&SG(request_info)); + return php_cli_server_send_error_page(server, client, 400 TSRMLS_CC); + } { zend_file_handle zfd; zfd.type = ZEND_HANDLE_FILENAME; @@ -1625,6 +1631,11 @@ static int php_cli_server_begin_send_static(php_cli_server *server, php_cli_serv int fd; int status = 200; + if (client->request.path_translated && strlen(client->request.path_translated) != client->request.path_translated_len) { + /* can't handle paths that contain nul bytes */ + return php_cli_server_send_error_page(server, client, 400 TSRMLS_CC); + } + fd = client->request.path_translated ? open(client->request.path_translated, O_RDONLY): -1; if (fd < 0) { char *errstr = get_last_error(); From fcf8f2bcaf1cd506424e8ce6d93ec57a54c404a0 Mon Sep 17 00:00:00 2001 From: Popa Adrian Marius Date: Tue, 19 Jul 2011 20:08:42 +0000 Subject: [PATCH 0341/2394] Fix for bug http://bugs.php.net/54426 Checks for NULL are wrong as the values can be provided by the triggers --- ext/interbase/ibase_query.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/ext/interbase/ibase_query.c b/ext/interbase/ibase_query.c index b9e8db87818f4..9eac22284bdad 100644 --- a/ext/interbase/ibase_query.c +++ b/ext/interbase/ibase_query.c @@ -672,14 +672,7 @@ static int _php_ibase_bind(XSQLDA *sqlda, zval ***b_vars, BIND_BUF *buf, /* {{{ if (! force_null) break; case IS_NULL: - - /* complain if this field doesn't allow NULL values */ - if (! (var->sqltype & 1)) { - _php_ibase_module_error("Parameter %d: non-empty value required" TSRMLS_CC, i+1); - rv = FAILURE; - } else { buf[i].sqlind = -1; - } if (var->sqltype & SQL_ARRAY) ++array_cnt; From e97b0d7522aa66decf4ee20dd67f5fac44474dde Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 19 Jul 2011 22:12:13 +0000 Subject: [PATCH 0342/2394] - Fixed bug #55231 (Unsatisfied symbols __sync_fetch_and_add_4) --- ext/standard/php_crypt_r.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index 2d71710cfddae..69c48610f3895 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -94,7 +94,8 @@ void _crypt_extended_init_r(void) if (!initialized) { #ifdef PHP_WIN32 InterlockedIncrement(&initialized); -#elif (defined(__GNUC__) && (__GNUC__ >= 4 && __GNUC_MINOR__ >= 1)) +#elif (defined(__GNUC__) && (__GNUC__ > 4 || \ + (__GNUC__ == 4 && (__GNUC_MINOR__ > 1 || (__GNUC_MINOR__ == 1 && __GNUC_PATCHLEVEL__ > 1))))) __sync_fetch_and_add(&initialized, 1); #elif defined(HAVE_ATOMIC_H) /* Solaris 10 defines atomic API within */ membar_producer(); From 02581a0052ced423c7926eff8a18c08d18e9d69b Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Tue, 19 Jul 2011 22:15:56 +0000 Subject: [PATCH 0343/2394] openssl_encrypt() / openssl_decrypt() were flawed and truncated the key to the default size for the case of a variable key length cipher. The result is a key of 448 bits being passed to the blowfish algorithm would be truncated to 128 bit. Also fixed an error in the zend_parse_parameters() having an invalid character being used. --- ext/openssl/openssl.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 5f7650d7d2724..1f0a79d93639a 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -1016,9 +1016,7 @@ PHP_MINIT_FUNCTION(openssl) OpenSSL_add_all_digests(); OpenSSL_add_all_algorithms(); - ERR_load_ERR_strings(); - ERR_load_crypto_strings(); - ERR_load_EVP_strings(); + SSL_load_error_strings(); /* register a resource id number with OpenSSL so that we can map SSL -> stream structures in * OpenSSL callbacks */ @@ -3039,7 +3037,7 @@ PHP_FUNCTION(openssl_pkey_export_to_file) BIO * bio_out = NULL; const EVP_CIPHER * cipher; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zṕ|s!a!", &zpkey, &filename, &filename_len, &passphrase, &passphrase_len, &args) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zp|s!a!", &zpkey, &filename, &filename_len, &passphrase, &passphrase_len, &args) == FAILURE) { return; } RETVAL_FALSE; @@ -4722,7 +4720,11 @@ PHP_FUNCTION(openssl_encrypt) outlen = data_len + EVP_CIPHER_block_size(cipher_type); outbuf = emalloc(outlen + 1); - EVP_EncryptInit(&cipher_ctx, cipher_type, key, (unsigned char *)iv); + EVP_EncryptInit(&cipher_ctx, cipher_type, NULL, NULL); + if (password_len > keylen) { + EVP_CIPHER_CTX_set_key_length(&cipher_ctx, password_len); + } + EVP_EncryptInit_ex(&cipher_ctx, NULL, NULL, key, (unsigned char *)iv); if (options & OPENSSL_ZERO_PADDING) { EVP_CIPHER_CTX_set_padding(&cipher_ctx, 0); } @@ -4805,7 +4807,11 @@ PHP_FUNCTION(openssl_decrypt) outlen = data_len + EVP_CIPHER_block_size(cipher_type); outbuf = emalloc(outlen + 1); - EVP_DecryptInit(&cipher_ctx, cipher_type, key, (unsigned char *)iv); + EVP_DecryptInit(&cipher_ctx, cipher_type, NULL, NULL); + if (password_len > keylen) { + EVP_CIPHER_CTX_set_key_length(&cipher_ctx, password_len); + } + EVP_DecryptInit_ex(&cipher_ctx, NULL, NULL, key, (unsigned char *)iv); if (options & OPENSSL_ZERO_PADDING) { EVP_CIPHER_CTX_set_padding(&cipher_ctx, 0); } From 3d10c57cd6a6930760f3220ce6c9c0243fa9acb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 19 Jul 2011 22:18:08 +0000 Subject: [PATCH 0344/2394] - enhanced log messages - code cosmetic --- sapi/fpm/fpm/fastcgi.c | 11 +++++---- sapi/fpm/fpm/fpm.c | 2 ++ sapi/fpm/fpm/fpm_children.c | 18 +++++++------- sapi/fpm/fpm/fpm_cleanup.c | 1 - sapi/fpm/fpm/fpm_conf.c | 23 +++++++++--------- sapi/fpm/fpm/fpm_conf.h | 2 ++ sapi/fpm/fpm/fpm_env.c | 1 - sapi/fpm/fpm/fpm_events.c | 8 +++---- sapi/fpm/fpm/fpm_log.c | 8 +++---- sapi/fpm/fpm/fpm_main.c | 14 +++++------ sapi/fpm/fpm/fpm_php.c | 2 +- sapi/fpm/fpm/fpm_php_trace.c | 2 +- sapi/fpm/fpm/fpm_process_ctl.c | 2 +- sapi/fpm/fpm/fpm_request.c | 14 +++++------ sapi/fpm/fpm/fpm_shm.c | 2 +- sapi/fpm/fpm/fpm_signals.c | 10 ++++---- sapi/fpm/fpm/fpm_sockets.c | 10 ++++---- sapi/fpm/fpm/fpm_status.c | 5 ++-- sapi/fpm/fpm/fpm_stdio.c | 27 +++++++++++---------- sapi/fpm/fpm/fpm_trace_mach.c | 4 ++-- sapi/fpm/fpm/fpm_trace_pread.c | 4 ++-- sapi/fpm/fpm/fpm_trace_ptrace.c | 8 +++---- sapi/fpm/fpm/fpm_unix.c | 42 ++++++++++++++++----------------- sapi/fpm/fpm/fpm_worker_pool.c | 1 - 24 files changed, 112 insertions(+), 109 deletions(-) diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index 4ffa1ec2909d9..b8d10a538d8d1 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -29,8 +29,9 @@ #include #include -#include -#include +#include "fpm.h" +#include "fpm_request.h" +#include "zlog.h" #ifdef _WIN32 @@ -267,7 +268,7 @@ void fcgi_set_allowed_clients(char *ip) } allowed_clients[n] = inet_addr(cur); if (allowed_clients[n] == INADDR_NONE) { - fprintf(stderr, "Wrong IP address '%s' in FCGI_WEB_SERVER_ADDRS or listen.allowed_clients\n", cur); + zlog(ZLOG_ERROR, "Wrong IP address '%s' in listen.allowed_clients", cur); } n++; cur = end; @@ -815,7 +816,7 @@ int fcgi_accept_request(fcgi_request *req) n++; } if (!allowed) { - fprintf(stderr, "Connection from disallowed IP address '%s' is dropped.\n", inet_ntoa(sa.sa_inet.sin_addr)); + zlog(ZLOG_ERROR, "Connection disallowed: IP address '%s' has been dropped.", inet_ntoa(sa.sa_inet.sin_addr)); closesocket(req->fd); req->fd = -1; continue; @@ -871,7 +872,7 @@ int fcgi_accept_request(fcgi_request *req) } fcgi_close(req, 1, 0); } else { - fprintf(stderr, "Too many open file descriptors. FD_SETSIZE limit exceeded."); + zlog(ZLOG_ERROR, "Too many open file descriptors. FD_SETSIZE limit exceeded."); fcgi_close(req, 1, 0); } #endif diff --git a/sapi/fpm/fpm/fpm.c b/sapi/fpm/fpm/fpm.c index 153bb29250f65..d405949ae4bee 100644 --- a/sapi/fpm/fpm/fpm.c +++ b/sapi/fpm/fpm/fpm.c @@ -65,11 +65,13 @@ int fpm_init(int argc, char **argv, char *config, char *prefix, char *pid, int t if (fpm_globals.test_successful) { exit(0); } else { + zlog(ZLOG_ERROR, "FPM initialization failed"); return -1; } } if (0 > fpm_conf_write_pid()) { + zlog(ZLOG_ERROR, "FPM initialization failed"); return -1; } diff --git a/sapi/fpm/fpm/fpm_children.c b/sapi/fpm/fpm/fpm_children.c index 769c519a85600..383a75ddc8e2c 100644 --- a/sapi/fpm/fpm/fpm_children.c +++ b/sapi/fpm/fpm/fpm_children.c @@ -147,13 +147,13 @@ static void fpm_child_init(struct fpm_worker_pool_s *wp) /* {{{ */ { fpm_globals.max_requests = wp->config->pm_max_requests; - if (0 > fpm_stdio_init_child(wp) || - 0 > fpm_log_init_child(wp) || - 0 > fpm_status_init_child(wp) || - 0 > fpm_unix_init_child(wp) || - 0 > fpm_signals_init_child() || - 0 > fpm_env_init_child(wp) || - 0 > fpm_php_init_child(wp)) { + if (0 > fpm_stdio_init_child(wp) || + 0 > fpm_log_init_child(wp) || + 0 > fpm_status_init_child(wp) || + 0 > fpm_unix_init_child(wp) || + 0 > fpm_signals_init_child() || + 0 > fpm_env_init_child(wp) || + 0 > fpm_php_init_child(wp)) { zlog(ZLOG_ERROR, "[pool %s] child failed to initialize", wp->config->name); exit(255); @@ -292,7 +292,7 @@ void fpm_children_bury() /* {{{ */ } } } else { - zlog(ZLOG_ALERT, "oops, unknown child (%d) exited %s", pid, buf); + zlog(ZLOG_ALERT, "oops, unknown child (%d) exited %s. Please open a bug report (https://bugs.php.net).", pid, buf); } } } @@ -305,7 +305,7 @@ static struct fpm_child_s *fpm_resources_prepare(struct fpm_worker_pool_s *wp) / c = fpm_child_alloc(); if (!c) { - zlog(ZLOG_ERROR, "[pool %s] malloc failed", wp->config->name); + zlog(ZLOG_ERROR, "[pool %s] unable to malloc new child", wp->config->name); return 0; } diff --git a/sapi/fpm/fpm/fpm_cleanup.c b/sapi/fpm/fpm/fpm_cleanup.c index 3f59e65854728..260ddb32e7621 100644 --- a/sapi/fpm/fpm/fpm_cleanup.c +++ b/sapi/fpm/fpm/fpm_cleanup.c @@ -8,7 +8,6 @@ #include "fpm_arrays.h" #include "fpm_cleanup.h" -#include "zlog.h" struct cleanup_s { int type; diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index c2ae52797eccd..bbb7207eb2019 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -47,7 +47,6 @@ #define STR2STR(a) (a ? a : "undefined") #define BOOL2STR(a) (a ? "yes" : "no") -#define PM2STR(a) (a == PM_STYLE_STATIC ? "static" : "dynamic") #define GO(field) offsetof(struct fpm_global_config_s, field) #define WPO(field) offsetof(struct fpm_worker_pool_config_s, field) @@ -680,7 +679,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ struct fpm_worker_pool_s *wp; if (!fpm_worker_all_pools) { - zlog(ZLOG_ERROR, "at least one pool section must be specified in config file"); + zlog(ZLOG_ERROR, "No pool defined. at least one pool section must be specified in config file"); return -1; } @@ -742,8 +741,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ if (config->pm_min_spare_servers > config->pm_max_children || config->pm_max_spare_servers > config->pm_max_children) { - zlog(ZLOG_ALERT, "[pool %s] pm.min_spare_servers(%d) and pm.max_spare_servers(%d) cannot be greater than pm.max_children(%d)", - wp->config->name, config->pm_min_spare_servers, config->pm_max_spare_servers, config->pm_max_children); + zlog(ZLOG_ALERT, "[pool %s] pm.min_spare_servers(%d) and pm.max_spare_servers(%d) cannot be greater than pm.max_children(%d)", wp->config->name, config->pm_min_spare_servers, config->pm_max_spare_servers, config->pm_max_children); return -1; } @@ -755,6 +753,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ if (config->pm_start_servers <= 0) { config->pm_start_servers = config->pm_min_spare_servers + ((config->pm_max_spare_servers - config->pm_min_spare_servers) / 2); zlog(ZLOG_WARNING, "[pool %s] pm.start_servers is not set. It's been set to %d.", wp->config->name, config->pm_start_servers); + } else if (config->pm_start_servers < config->pm_min_spare_servers || config->pm_start_servers > config->pm_max_spare_servers) { zlog(ZLOG_ALERT, "[pool %s] pm.start_servers(%d) must not be less than pm.min_spare_servers(%d) and not greater than pm.max_spare_servers(%d)", wp->config->name, config->pm_start_servers, config->pm_min_spare_servers, config->pm_max_spare_servers); return -1; @@ -766,7 +765,6 @@ static int fpm_conf_process_all_pools() /* {{{ */ if (wp->config->pm_status_path && *wp->config->pm_status_path) { int i; char *status = wp->config->pm_status_path; - /* struct fpm_status_s fpm_status; */ if (*status != '/') { zlog(ZLOG_ERROR, "[pool %s] the status path '%s' must start with a '/'", wp->config->name, status); @@ -860,7 +858,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ fd = open(wp->config->slowlog, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); if (0 > fd) { - zlog(ZLOG_SYSERROR, "open(%s) failed", wp->config->slowlog); + zlog(ZLOG_SYSERROR, "Unable to create or open slowlog(%s)", wp->config->slowlog); return -1; } close(fd); @@ -876,6 +874,7 @@ static int fpm_conf_process_all_pools() /* {{{ */ zlog(ZLOG_ERROR, "[pool %s] the chroot path '%s' must start with a '/'", wp->config->name, wp->config->chroot); return -1; } + if (!fpm_conf_is_dir(wp->config->chroot)) { zlog(ZLOG_ERROR, "[pool %s] the chroot path '%s' does not exist or is not a directory", wp->config->name, wp->config->chroot); return -1; @@ -993,7 +992,7 @@ int fpm_conf_unlink_pid() /* {{{ */ { if (fpm_global_config.pid_file) { if (0 > unlink(fpm_global_config.pid_file)) { - zlog(ZLOG_SYSERROR, "unlink(\"%s\") failed", fpm_global_config.pid_file); + zlog(ZLOG_SYSERROR, "Unable to remove the PID file (%s).", fpm_global_config.pid_file); return -1; } } @@ -1013,14 +1012,14 @@ int fpm_conf_write_pid() /* {{{ */ fd = creat(fpm_global_config.pid_file, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH); if (fd < 0) { - zlog(ZLOG_SYSERROR, "creat(\"%s\") failed", fpm_global_config.pid_file); + zlog(ZLOG_SYSERROR, "Unable to create the PID file (%s).", fpm_global_config.pid_file); return -1; } len = sprintf(buf, "%d", (int) fpm_globals.parent_pid); if (len != write(fd, buf, len)) { - zlog(ZLOG_SYSERROR, "write() failed"); + zlog(ZLOG_SYSERROR, "Unable to write to the PID file."); return -1; } close(fd); @@ -1355,18 +1354,18 @@ int fpm_conf_load_ini_file(char *filename TSRMLS_DC) /* {{{ */ int ret = 1; if (!filename || !filename[0]) { - zlog(ZLOG_ERROR, "Configuration file is empty"); + zlog(ZLOG_ERROR, "configuration filename is empty"); return -1; } fd = open(filename, O_RDONLY, 0); if (fd < 0) { - zlog(ZLOG_ERROR, "Unable to open file '%s', errno=%d", filename, errno); + zlog(ZLOG_SYSERROR, "failed to open configuration file '%s'", filename); return -1; } if (ini_recursion++ > 4) { - zlog(ZLOG_ERROR, "You can include more than 5 files recusively"); + zlog(ZLOG_ERROR, "failed to include more than 5 files recusively"); return -1; } diff --git a/sapi/fpm/fpm/fpm_conf.h b/sapi/fpm/fpm/fpm_conf.h index 027e21f8bbed5..56556e95a44b8 100644 --- a/sapi/fpm/fpm/fpm_conf.h +++ b/sapi/fpm/fpm/fpm_conf.h @@ -8,6 +8,8 @@ #include #include "php.h" +#define PM2STR(a) (a == PM_STYLE_STATIC ? "static" : "dynamic") + #define FPM_CONF_MAX_PONG_LENGTH 64 struct key_value_s; diff --git a/sapi/fpm/fpm/fpm_env.c b/sapi/fpm/fpm/fpm_env.c index 03bf8234007ce..6b64fedfec47c 100644 --- a/sapi/fpm/fpm/fpm_env.c +++ b/sapi/fpm/fpm/fpm_env.c @@ -13,7 +13,6 @@ #include "fpm_env.h" #include "fpm.h" -#include "zlog.h" #ifndef HAVE_SETPROCTITLE #ifdef __linux__ diff --git a/sapi/fpm/fpm/fpm_events.c b/sapi/fpm/fpm/fpm_events.c index 8ae9ad2e20719..1e95e1eef2f38 100644 --- a/sapi/fpm/fpm/fpm_events.c +++ b/sapi/fpm/fpm/fpm_events.c @@ -66,7 +66,7 @@ static void fpm_got_signal(struct fpm_event_s *ev, short which, void *arg) /* {{ if (res <= 0) { if (res < 0 && errno != EAGAIN && errno != EWOULDBLOCK) { - zlog(ZLOG_SYSERROR, "read() failed"); + zlog(ZLOG_SYSERROR, "unable to read from the signal pipe"); } return; } @@ -153,7 +153,7 @@ static int fpm_event_queue_add(struct fpm_event_queue_s **queue, struct fpm_even } if (!(elt = malloc(sizeof(struct fpm_event_queue_s)))) { - zlog(ZLOG_SYSERROR, "malloc() failed"); + zlog(ZLOG_SYSERROR, "Unable to add the event to queue: malloc() failed"); return -1; } elt->prev = NULL; @@ -232,7 +232,7 @@ int fpm_event_init_main() /* {{{ */ /* malloc the max number of necessary fds for polling */ fpm_event_ufds = malloc(sizeof(php_pollfd) * fpm_event_nfds_max); if (!fpm_event_ufds) { - zlog(ZLOG_SYSERROR, "malloc() failed"); + zlog(ZLOG_SYSERROR, "Error while initializing events: malloc() failed"); return -1; } @@ -318,7 +318,7 @@ void fpm_event_loop(int err) /* {{{ */ /* wait for inconming event or timeout */ if ((ret = php_poll2(fpm_event_ufds, i, timeout)) == -1) { if (errno != EINTR) { - zlog(ZLOG_WARNING, "php_poll2() returns %d", errno); + zlog(ZLOG_SYSERROR, "failed to wait for events: php_poll2()"); } } else if (ret > 0) { diff --git a/sapi/fpm/fpm/fpm_log.c b/sapi/fpm/fpm/fpm_log.c index 5360c45f7acef..69bd31b1135c7 100644 --- a/sapi/fpm/fpm/fpm_log.c +++ b/sapi/fpm/fpm/fpm_log.c @@ -44,7 +44,7 @@ int fpm_log_open(int reopen) /* {{{ */ fd = open(wp->config->access_log, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); if (0 > fd) { - zlog(ZLOG_SYSERROR, "open(\"%s\") failed", wp->config->access_log); + zlog(ZLOG_SYSERROR, "failed to open access log (%s)", wp->config->access_log); return -1; } @@ -124,12 +124,12 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ if (!test) { scoreboard = fpm_scoreboard_get(); if (!scoreboard) { - zlog(ZLOG_WARNING, "unable to get scoreboard"); + zlog(ZLOG_WARNING, "unable to get scoreboard while preparing the access log"); return -1; } proc_p = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (!proc_p) { - zlog(ZLOG_WARNING, "[pool %s] Unable to acquire shm slot", scoreboard->pool); + zlog(ZLOG_WARNING, "[pool %s] Unable to acquire shm slot while preparing the access log", scoreboard->pool); return -1; } proc = *proc_p; @@ -147,7 +147,7 @@ int fpm_log_write(char *log_format TSRMLS_DC) /* {{{ */ while (*s != '\0') { if (len > FPM_LOG_BUFFER) { - zlog(ZLOG_NOTICE, "the log buffer is full (%d). The log request has been truncated.", FPM_LOG_BUFFER); + zlog(ZLOG_NOTICE, "the log buffer is full (%d). The access log request has been truncated.", FPM_LOG_BUFFER); len = FPM_LOG_BUFFER - 1; break; } diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index cda0c1d983b25..773cf2cf6d58a 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -100,13 +100,13 @@ int __riscosify_control = __RISCOSIFY_STRICT_UNIX_SPECS; #include "fastcgi.h" #include -#include -#include -#include -#include -#include -#include -#include +#include "fpm.h" +#include "fpm_request.h" +#include "fpm_status.h" +#include "fpm_conf.h" +#include "fpm_php.h" +#include "fpm_log.h" +#include "zlog.h" #ifndef PHP_WIN32 /* XXX this will need to change later when threaded fastcgi is implemented. shane */ diff --git a/sapi/fpm/fpm/fpm_php.c b/sapi/fpm/fpm/fpm_php.c index d541f2944618a..840eec73efbae 100644 --- a/sapi/fpm/fpm/fpm_php.c +++ b/sapi/fpm/fpm/fpm_php.c @@ -253,7 +253,7 @@ int fpm_php_limit_extensions(char *path) /* {{{ */ } - zlog(ZLOG_NOTICE, "Access to the file '%s' has been denied (see security.limit_extensions)", path); + zlog(ZLOG_NOTICE, "Access to the script '%s' has been denied (see security.limit_extensions)", path); return 1; /* extension not found: not allowed */ } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_php_trace.c b/sapi/fpm/fpm/fpm_php_trace.c index 03874584f645d..cd97aebb3347a 100644 --- a/sapi/fpm/fpm/fpm_php_trace.c +++ b/sapi/fpm/fpm/fpm_php_trace.c @@ -144,7 +144,7 @@ void fpm_php_trace(struct fpm_child_s *child) /* {{{ */ slowlog = fopen(child->wp->config->slowlog, "a+"); if (!slowlog) { - zlog(ZLOG_SYSERROR, "fopen(%s) failed", child->wp->config->slowlog); + zlog(ZLOG_SYSERROR, "unable to open slowlog (%s)", child->wp->config->slowlog); goto done0; } diff --git a/sapi/fpm/fpm/fpm_process_ctl.c b/sapi/fpm/fpm/fpm_process_ctl.c index 0f2685c738fd3..5e7ca5d9003f3 100644 --- a/sapi/fpm/fpm/fpm_process_ctl.c +++ b/sapi/fpm/fpm/fpm_process_ctl.c @@ -99,7 +99,7 @@ static void fpm_pctl_exec() /* {{{ */ fpm_cleanups_run(FPM_CLEANUP_PARENT_EXEC); execvp(saved_argv[0], saved_argv); - zlog(ZLOG_SYSERROR, "execvp() failed"); + zlog(ZLOG_SYSERROR, "failed to reload: execvp() failed"); exit(1); } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_request.c b/sapi/fpm/fpm/fpm_request.c index f94196b562f7c..f7cd815f64ed3 100644 --- a/sapi/fpm/fpm/fpm_request.c +++ b/sapi/fpm/fpm/fpm_request.c @@ -45,7 +45,7 @@ void fpm_request_accepting() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire proc scoreboard"); return; } @@ -76,7 +76,7 @@ void fpm_request_reading_headers() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire proc scoreboard"); return; } @@ -116,7 +116,7 @@ void fpm_request_info() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire proc scoreboard"); return; } @@ -160,7 +160,7 @@ void fpm_request_executing() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire proc scoreboard"); return; } @@ -186,7 +186,7 @@ void fpm_request_end(TSRMLS_D) /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire proc scoreboard"); return; } proc->request_stage = FPM_REQUEST_FINISHED; @@ -213,7 +213,7 @@ void fpm_request_finished() /* {{{ */ proc = fpm_scoreboard_proc_acquire(NULL, -1, 0); if (proc == NULL) { - zlog(ZLOG_WARNING, "unable to acquire proc scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire proc scoreboard"); return; } @@ -231,7 +231,7 @@ void fpm_request_check_timed_out(struct fpm_child_s *child, struct timeval *now, proc_p = fpm_scoreboard_proc_acquire(child->wp->scoreboard, child->scoreboard_i, 1); if (!proc_p) { - zlog(ZLOG_WARNING, "unable to acquire scoreboard"); + zlog(ZLOG_WARNING, "failed to acquire scoreboard"); return; } diff --git a/sapi/fpm/fpm/fpm_shm.c b/sapi/fpm/fpm/fpm_shm.c index a777612de0f81..6acbddf9a6c5b 100644 --- a/sapi/fpm/fpm/fpm_shm.c +++ b/sapi/fpm/fpm/fpm_shm.c @@ -49,7 +49,7 @@ int fpm_shm_free(void *mem, size_t size) /* {{{ */ } if (munmap(mem, size) == -1) { - zlog(ZLOG_SYSERROR, "Unable to free shm: %s", strerror(errno)); + zlog(ZLOG_SYSERROR, "Unable to free shm"); return 0; } diff --git a/sapi/fpm/fpm/fpm_signals.c b/sapi/fpm/fpm/fpm_signals.c index 7c317e57606f5..8993a860ae87d 100644 --- a/sapi/fpm/fpm/fpm_signals.c +++ b/sapi/fpm/fpm/fpm_signals.c @@ -182,17 +182,17 @@ int fpm_signals_init_main() /* {{{ */ struct sigaction act; if (0 > socketpair(AF_UNIX, SOCK_STREAM, 0, sp)) { - zlog(ZLOG_SYSERROR, "socketpair() failed"); + zlog(ZLOG_SYSERROR, "failed to init signals: socketpair()"); return -1; } if (0 > fd_set_blocked(sp[0], 0) || 0 > fd_set_blocked(sp[1], 0)) { - zlog(ZLOG_SYSERROR, "fd_set_blocked() failed"); + zlog(ZLOG_SYSERROR, "failed to init signals: fd_set_blocked()"); return -1; } if (0 > fcntl(sp[0], F_SETFD, FD_CLOEXEC) || 0 > fcntl(sp[1], F_SETFD, FD_CLOEXEC)) { - zlog(ZLOG_SYSERROR, "fcntl(F_SETFD, FD_CLOEXEC) failed"); + zlog(ZLOG_SYSERROR, "falied to init signals: fcntl(F_SETFD, FD_CLOEXEC)"); return -1; } @@ -207,7 +207,7 @@ int fpm_signals_init_main() /* {{{ */ 0 > sigaction(SIGCHLD, &act, 0) || 0 > sigaction(SIGQUIT, &act, 0)) { - zlog(ZLOG_SYSERROR, "sigaction() failed"); + zlog(ZLOG_SYSERROR, "failed to init signals: sigaction()"); return -1; } return 0; @@ -236,7 +236,7 @@ int fpm_signals_init_child() /* {{{ */ 0 > sigaction(SIGCHLD, &act_dfl, 0) || 0 > sigaction(SIGQUIT, &act, 0)) { - zlog(ZLOG_SYSERROR, "sigaction() failed"); + zlog(ZLOG_SYSERROR, "failed to init child signals: sigaction()"); return -1; } return 0; diff --git a/sapi/fpm/fpm/fpm_sockets.c b/sapi/fpm/fpm/fpm_sockets.c index 08e2342e56cfb..cb4897e9b408b 100644 --- a/sapi/fpm/fpm/fpm_sockets.c +++ b/sapi/fpm/fpm/fpm_sockets.c @@ -172,7 +172,7 @@ static int fpm_sockets_new_listening_socket(struct fpm_worker_pool_s *wp, struct sock = socket(sa->sa_family, SOCK_STREAM, 0); if (0 > sock) { - zlog(ZLOG_SYSERROR, "socket() failed"); + zlog(ZLOG_SYSERROR, "failed to create new listening socket: socket()"); return -1; } @@ -184,7 +184,7 @@ static int fpm_sockets_new_listening_socket(struct fpm_worker_pool_s *wp, struct } if (0 > bind(sock, sa, socklen)) { - zlog(ZLOG_SYSERROR, "bind() for address '%s' failed", wp->config->listen_address); + zlog(ZLOG_SYSERROR, "unable to bind listening socket for address '%s'", wp->config->listen_address); if (wp->listen_address_domain == FPM_AF_UNIX) { umask(saved_umask); } @@ -198,14 +198,14 @@ static int fpm_sockets_new_listening_socket(struct fpm_worker_pool_s *wp, struct if (wp->socket_uid != -1 || wp->socket_gid != -1) { if (0 > chown(path, wp->socket_uid, wp->socket_gid)) { - zlog(ZLOG_SYSERROR, "chown() for address '%s' failed", wp->config->listen_address); + zlog(ZLOG_SYSERROR, "failed to chown() the socket '%s'", wp->config->listen_address); return -1; } } } if (0 > listen(sock, wp->config->listen_backlog)) { - zlog(ZLOG_SYSERROR, "listen() for address '%s' failed", wp->config->listen_address); + zlog(ZLOG_SYSERROR, "failed to listen to address '%s'", wp->config->listen_address); return -1; } @@ -392,7 +392,7 @@ int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) socklen_t len = sizeof(info); if (0 > getsockopt(sock, IPPROTO_TCP, TCP_INFO, &info, &len)) { - zlog(ZLOG_SYSERROR, "unable to retrieve TCP_INFO for socket"); + zlog(ZLOG_SYSERROR, "failed to retrieve TCP_INFO for socket"); return -1; } diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 977ce3252aa5f..83de76d5abd80 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -13,6 +13,7 @@ #include "fpm_scoreboard.h" #include "zlog.h" #include "fpm_atomic.h" +#include "fpm_conf.h" #include static char *fpm_status_uri = NULL; @@ -33,7 +34,7 @@ int fpm_status_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ if (wp->config->ping_path) { if (!wp->config->ping_response) { - zlog(ZLOG_ERROR, "[pool %s] ping is set (%s) but pong is not set.", wp->config->name, wp->config->ping_path); + zlog(ZLOG_ERROR, "[pool %s] ping is set (%s) but ping.response is not set.", wp->config->name, wp->config->ping_path); return -1; } fpm_status_ping_uri = strdup(wp->config->ping_path); @@ -352,7 +353,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ now_epoch = time(NULL); spprintf(&buffer, 0, short_syntax, scoreboard.pool, - scoreboard.pm == PM_STYLE_STATIC ? "static" : "dynamic", + PM2STR(scoreboard.pm), time_buffer, now_epoch - scoreboard.start_epoch, scoreboard.requests, diff --git a/sapi/fpm/fpm/fpm_stdio.c b/sapi/fpm/fpm/fpm_stdio.c index 4948194f84ff3..6a587d00ee790 100644 --- a/sapi/fpm/fpm/fpm_stdio.c +++ b/sapi/fpm/fpm/fpm_stdio.c @@ -28,12 +28,12 @@ int fpm_stdio_init_main() /* {{{ */ int fd = open("/dev/null", O_RDWR); if (0 > fd) { - zlog(ZLOG_SYSERROR, "open(\"/dev/null\") failed"); + zlog(ZLOG_SYSERROR, "failed to init stdio: open(\"/dev/null\")"); return -1; } if (0 > dup2(fd, STDIN_FILENO) || 0 > dup2(fd, STDOUT_FILENO)) { - zlog(ZLOG_SYSERROR, "dup2() failed"); + zlog(ZLOG_SYSERROR, "failed to init stdio: dup2()"); return -1; } close(fd); @@ -49,7 +49,7 @@ int fpm_stdio_init_final() /* {{{ */ /* there might be messages to stderr from other parts of the code, we need to log them all */ if (0 > dup2(fpm_globals.error_log_fd, STDERR_FILENO)) { - zlog(ZLOG_SYSERROR, "dup2() failed"); + zlog(ZLOG_SYSERROR, "failed to init stdio: dup2()"); return -1; } } @@ -74,7 +74,7 @@ int fpm_stdio_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ if (wp->listening_socket != STDIN_FILENO) { if (0 > dup2(wp->listening_socket, STDIN_FILENO)) { - zlog(ZLOG_SYSERROR, "dup2() failed"); + zlog(ZLOG_SYSERROR, "failed to init child stdio: dup2()"); return -1; } } @@ -116,7 +116,7 @@ static void fpm_stdio_child_said(struct fpm_event_s *ev, short which, void *arg) } else { /* error or pipe is closed */ if (res < 0) { /* error */ - zlog(ZLOG_SYSERROR, "read() failed"); + zlog(ZLOG_SYSERROR, "unable to read what child say"); } fpm_event_del(event); @@ -186,20 +186,23 @@ int fpm_stdio_prepare_pipes(struct fpm_child_s *child) /* {{{ */ } if (0 > pipe(fd_stdout)) { - zlog(ZLOG_SYSERROR, "pipe() failed"); + zlog(ZLOG_SYSERROR, "failed to prepare the stdout pipe"); return -1; } if (0 > pipe(fd_stderr)) { - zlog(ZLOG_SYSERROR, "pipe() failed"); - close(fd_stdout[0]); close(fd_stdout[1]); + zlog(ZLOG_SYSERROR, "failed to prepare the stderr pipe"); + close(fd_stdout[0]); + close(fd_stdout[1]); return -1; } if (0 > fd_set_blocked(fd_stdout[0], 0) || 0 > fd_set_blocked(fd_stderr[0], 0)) { - zlog(ZLOG_SYSERROR, "fd_set_blocked() failed"); - close(fd_stdout[0]); close(fd_stdout[1]); - close(fd_stderr[0]); close(fd_stderr[1]); + zlog(ZLOG_SYSERROR, "failed to unblock pipes"); + close(fd_stdout[0]); + close(fd_stdout[1]); + close(fd_stderr[0]); + close(fd_stderr[1]); return -1; } return 0; @@ -273,7 +276,7 @@ int fpm_stdio_open_error_log(int reopen) /* {{{ */ fd = open(fpm_global_config.error_log, O_WRONLY | O_APPEND | O_CREAT, S_IRUSR | S_IWUSR); if (0 > fd) { - zlog(ZLOG_SYSERROR, "open(\"%s\") failed", fpm_global_config.error_log); + zlog(ZLOG_SYSERROR, "failed to open error_log (%s)", fpm_global_config.error_log); return -1; } diff --git a/sapi/fpm/fpm/fpm_trace_mach.c b/sapi/fpm/fpm/fpm_trace_mach.c index fe26fd9e2e8ab..3b85e6a343577 100644 --- a/sapi/fpm/fpm/fpm_trace_mach.c +++ b/sapi/fpm/fpm/fpm_trace_mach.c @@ -37,7 +37,7 @@ static int fpm_mach_vm_read_page(vm_offset_t page) /* {{{ */ kr = mach_vm_read(target, page, fpm_pagesize, &local_page, &local_size); if (kr != KERN_SUCCESS) { - zlog(ZLOG_ERROR, "mach_vm_read() failed: %s (%d)", mach_error_string(kr), kr); + zlog(ZLOG_ERROR, "failed to read vm page: mach_vm_read(): %s (%d)", mach_error_string(kr), kr); return -1; } return 0; @@ -47,7 +47,7 @@ static int fpm_mach_vm_read_page(vm_offset_t page) /* {{{ */ int fpm_trace_signal(pid_t pid) /* {{{ */ { if (0 > fpm_pctl_kill(pid, FPM_PCTL_STOP)) { - zlog(ZLOG_SYSERROR, "kill(SIGSTOP) failed"); + zlog(ZLOG_SYSERROR, "failed to send SIGSTOP to %d", pid); return -1; } return 0; diff --git a/sapi/fpm/fpm/fpm_trace_pread.c b/sapi/fpm/fpm/fpm_trace_pread.c index eda84928ed075..6a6155740bdba 100644 --- a/sapi/fpm/fpm/fpm_trace_pread.c +++ b/sapi/fpm/fpm/fpm_trace_pread.c @@ -26,7 +26,7 @@ static int mem_file = -1; int fpm_trace_signal(pid_t pid) /* {{{ */ { if (0 > fpm_pctl_kill(pid, FPM_PCTL_STOP)) { - zlog(ZLOG_SYSERROR, "kill(SIGSTOP) failed"); + zlog(ZLOG_SYSERROR, "failed to send SIGSTOP to %d", pid); return -1; } return 0; @@ -40,7 +40,7 @@ int fpm_trace_ready(pid_t pid) /* {{{ */ sprintf(buf, "/proc/%d/" PROC_MEM_FILE, (int) pid); mem_file = open(buf, O_RDONLY); if (0 > mem_file) { - zlog(ZLOG_SYSERROR, "open(%s) failed", buf); + zlog(ZLOG_SYSERROR, "failed to open %s", buf); return -1; } return 0; diff --git a/sapi/fpm/fpm/fpm_trace_ptrace.c b/sapi/fpm/fpm/fpm_trace_ptrace.c index 395c1ac08da23..838c61867c4ab 100644 --- a/sapi/fpm/fpm/fpm_trace_ptrace.c +++ b/sapi/fpm/fpm/fpm_trace_ptrace.c @@ -29,7 +29,7 @@ static pid_t traced_pid; int fpm_trace_signal(pid_t pid) /* {{{ */ { if (0 > ptrace(PTRACE_ATTACH, pid, 0, 0)) { - zlog(ZLOG_SYSERROR, "ptrace(ATTACH) failed"); + zlog(ZLOG_SYSERROR, "failed to ptrace(ATTACH) child %d", pid); return -1; } return 0; @@ -46,7 +46,7 @@ int fpm_trace_ready(pid_t pid) /* {{{ */ int fpm_trace_close(pid_t pid) /* {{{ */ { if (0 > ptrace(PTRACE_DETACH, pid, (void *) 1, 0)) { - zlog(ZLOG_SYSERROR, "ptrace(DETACH) failed"); + zlog(ZLOG_SYSERROR, "failed to ptrace(DETACH) child %d", pid); return -1; } traced_pid = 0; @@ -65,14 +65,14 @@ int fpm_trace_get_long(long addr, long *data) /* {{{ */ }; if (0 > ptrace(PT_IO, traced_pid, (void *) &ptio, 0)) { - zlog(ZLOG_SYSERROR, "ptrace(PT_IO) failed"); + zlog(ZLOG_SYSERROR, "failed to ptrace(PT_IO) pid %d", traced_pid); return -1; } #else errno = 0; *data = ptrace(PTRACE_PEEKDATA, traced_pid, (void *) addr, 0); if (errno) { - zlog(ZLOG_SYSERROR, "ptrace(PEEKDATA) failed"); + zlog(ZLOG_SYSERROR, "failed to ptrace(PEEKDATA) pid %d", traced_pid); return -1; } #endif diff --git a/sapi/fpm/fpm/fpm_unix.c b/sapi/fpm/fpm/fpm_unix.c index d29d3879950f0..17d0b8125cc54 100644 --- a/sapi/fpm/fpm/fpm_unix.c +++ b/sapi/fpm/fpm/fpm_unix.c @@ -73,6 +73,7 @@ int fpm_unix_resolve_socket_premissions(struct fpm_worker_pool_s *wp) /* {{{ */ static int fpm_unix_conf_wp(struct fpm_worker_pool_s *wp) /* {{{ */ { + struct passwd *pwd; int is_root = !geteuid(); if (is_root) { @@ -119,23 +120,20 @@ static int fpm_unix_conf_wp(struct fpm_worker_pool_s *wp) /* {{{ */ #endif } else { /* not root */ if (wp->config->user && *wp->config->user) { - zlog(ZLOG_WARNING, "[pool %s] 'user' directive is ignored", wp->config->name); + zlog(ZLOG_WARNING, "[pool %s] 'user' directive is ignored when FPM is not running as root", wp->config->name); } if (wp->config->group && *wp->config->group) { - zlog(ZLOG_WARNING, "[pool %s] 'group' directive is ignored", wp->config->name); + zlog(ZLOG_WARNING, "[pool %s] 'group' directive is ignored when FPM is not running as root", wp->config->name); } if (wp->config->chroot && *wp->config->chroot) { - zlog(ZLOG_WARNING, "[pool %s] 'chroot' directive is ignored", wp->config->name); + zlog(ZLOG_WARNING, "[pool %s] 'chroot' directive is ignored when FPM is not running as root", wp->config->name); } - { /* set up HOME and USER anyway */ - struct passwd *pwd; - - pwd = getpwuid(getuid()); - if (pwd) { - wp->user = strdup(pwd->pw_name); - wp->home = strdup(pwd->pw_dir); - } + /* set up HOME and USER anyway */ + pwd = getpwuid(getuid()); + if (pwd) { + wp->user = strdup(pwd->pw_name); + wp->home = strdup(pwd->pw_dir); } } return 0; @@ -153,7 +151,7 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ r.rlim_max = r.rlim_cur = (rlim_t) wp->config->rlimit_files; if (0 > setrlimit(RLIMIT_NOFILE, &r)) { - zlog(ZLOG_SYSERROR, "[pool %s] unable to set rlimit_files for this pool. Please check your system limits or decrease rlimit_files. setrlimit(RLIMIT_NOFILE, %d) failed (%d)", wp->config->name, wp->config->rlimit_files, errno); + zlog(ZLOG_SYSERROR, "[pool %s] failed to set rlimit_files for this pool. Please check your system limits or decrease rlimit_files. setrlimit(RLIMIT_NOFILE, %d)", wp->config->name, wp->config->rlimit_files); } } @@ -163,13 +161,13 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ r.rlim_max = r.rlim_cur = wp->config->rlimit_core == -1 ? (rlim_t) RLIM_INFINITY : (rlim_t) wp->config->rlimit_core; if (0 > setrlimit(RLIMIT_CORE, &r)) { - zlog(ZLOG_SYSERROR, "[pool %s] unable to set rlimit_core for this pool. Please check your system limits or decrease rlimit_core. setrlimit(RLIMIT_CORE, %d) failed (%d)", wp->config->name, wp->config->rlimit_core, errno); + zlog(ZLOG_SYSERROR, "[pool %s] failed to set rlimit_core for this pool. Please check your system limits or decrease rlimit_core. setrlimit(RLIMIT_CORE, %d)", wp->config->name, wp->config->rlimit_core); } } if (is_root && wp->config->chroot && *wp->config->chroot) { if (0 > chroot(wp->config->chroot)) { - zlog(ZLOG_SYSERROR, "[pool %s] chroot(%s) failed", wp->config->name, wp->config->chroot); + zlog(ZLOG_SYSERROR, "[pool %s] failed to chroot(%s)", wp->config->name, wp->config->chroot); return -1; } made_chroot = 1; @@ -177,7 +175,7 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ if (wp->config->chdir && *wp->config->chdir) { if (0 > chdir(wp->config->chdir)) { - zlog(ZLOG_SYSERROR, "[pool %s] chdir(%s) failed", wp->config->name, wp->config->chdir); + zlog(ZLOG_SYSERROR, "[pool %s] failed to chdir(%s)", wp->config->name, wp->config->chdir); return -1; } } else if (made_chroot) { @@ -187,17 +185,17 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ if (is_root) { if (wp->set_gid) { if (0 > setgid(wp->set_gid)) { - zlog(ZLOG_SYSERROR, "[pool %s] setgid(%d) failed", wp->config->name, wp->set_gid); + zlog(ZLOG_SYSERROR, "[pool %s] failed to setgid(%d)", wp->config->name, wp->set_gid); return -1; } } if (wp->set_uid) { if (0 > initgroups(wp->config->user, wp->set_gid)) { - zlog(ZLOG_SYSERROR, "[pool %s] initgroups(%s, %d) failed", wp->config->name, wp->config->user, wp->set_gid); + zlog(ZLOG_SYSERROR, "[pool %s] failed to initgroups(%s, %d)", wp->config->name, wp->config->user, wp->set_gid); return -1; } if (0 > setuid(wp->set_uid)) { - zlog(ZLOG_SYSERROR, "[pool %s] setuid(%d) failed", wp->config->name, wp->set_uid); + zlog(ZLOG_SYSERROR, "[pool %s] failed to setuid(%d)", wp->config->name, wp->set_uid); return -1; } } @@ -205,7 +203,7 @@ int fpm_unix_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ #ifdef HAVE_PRCTL if (0 > prctl(PR_SET_DUMPABLE, 1, 0, 0, 0)) { - zlog(ZLOG_SYSERROR, "[pool %s] prctl(PR_SET_DUMPABLE) failed", wp->config->name); + zlog(ZLOG_SYSERROR, "[pool %s] failed to prctl(PR_SET_DUMPABLE)", wp->config->name); } #endif @@ -226,7 +224,7 @@ int fpm_unix_init_main() /* {{{ */ r.rlim_max = r.rlim_cur = (rlim_t) fpm_global_config.rlimit_files; if (0 > setrlimit(RLIMIT_NOFILE, &r)) { - zlog(ZLOG_SYSERROR, "unable to set rlimit_core for this pool. Please check your system limits or decrease rlimit_files. setrlimit(RLIMIT_NOFILE, %d) failed (%d)", fpm_global_config.rlimit_files, errno); + zlog(ZLOG_SYSERROR, "failed to set rlimit_core for this pool. Please check your system limits or decrease rlimit_files. setrlimit(RLIMIT_NOFILE, %d)", fpm_global_config.rlimit_files); return -1; } } @@ -237,7 +235,7 @@ int fpm_unix_init_main() /* {{{ */ r.rlim_max = r.rlim_cur = fpm_global_config.rlimit_core == -1 ? (rlim_t) RLIM_INFINITY : (rlim_t) fpm_global_config.rlimit_core; if (0 > setrlimit(RLIMIT_CORE, &r)) { - zlog(ZLOG_SYSERROR, "unable to set rlimit_core for this pool. Please check your system limits or decrease rlimit_core. setrlimit(RLIMIT_CORE, %d) failed (%d)", fpm_global_config.rlimit_core, errno); + zlog(ZLOG_SYSERROR, "failed to set rlimit_core for this pool. Please check your system limits or decrease rlimit_core. setrlimit(RLIMIT_CORE, %d)", fpm_global_config.rlimit_core); return -1; } } @@ -246,7 +244,7 @@ int fpm_unix_init_main() /* {{{ */ if (fpm_global_config.daemonize) { switch (fork()) { case -1 : - zlog(ZLOG_SYSERROR, "daemonized fork() failed"); + zlog(ZLOG_SYSERROR, "failed to daemonize"); return -1; case 0 : break; diff --git a/sapi/fpm/fpm/fpm_worker_pool.c b/sapi/fpm/fpm/fpm_worker_pool.c index 6c6d9cce03be3..123f9893fac1f 100644 --- a/sapi/fpm/fpm/fpm_worker_pool.c +++ b/sapi/fpm/fpm/fpm_worker_pool.c @@ -15,7 +15,6 @@ #include "fpm_shm.h" #include "fpm_scoreboard.h" #include "fpm_conf.h" -#include "zlog.h" struct fpm_worker_pool_s *fpm_worker_all_pools; From 25fb19764afbc8be10581f5a93578c0c99ac38bc Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Tue, 19 Jul 2011 22:29:55 +0000 Subject: [PATCH 0345/2394] Revert change to use a special Windows version of openssl_random_pseudo_bytes(). Lets discuss this on internals first. We're advertising something from the OpenSSL library and then subverting it with another Windows OS call. What are the implications of this? Should we make this available in ext/standard/ instead? --- ext/openssl/openssl.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 1f0a79d93639a..270896a7335b3 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -4926,19 +4926,10 @@ PHP_FUNCTION(openssl_random_pseudo_bytes) buffer = emalloc(buffer_length + 1); -#ifdef PHP_WIN32 - strong_result = 1; - /* random/urandom equivalent on Windows */ - if (php_win32_get_random_bytes(buffer, (size_t) buffer_length) == FAILURE){ - efree(buffer); - RETURN_FALSE; - } -#else if ((strong_result = RAND_pseudo_bytes(buffer, buffer_length)) < 0) { efree(buffer); RETURN_FALSE; } -#endif buffer[buffer_length] = 0; RETVAL_STRINGL((char *)buffer, buffer_length, 0); From 9620fb7e090c6a73c02efefa6313f97c05ace808 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 19 Jul 2011 22:38:04 +0000 Subject: [PATCH 0346/2394] - Dropped restriction of not setting the same value multiple times, the last one holds (giovanni at giacobbi dot net) --- sapi/fpm/fpm/fpm_conf.c | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index bbb7207eb2019..bcfe618b602d9 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -195,21 +195,25 @@ static char *fpm_conf_set_boolean(zval *value, void **config, intptr_t offset) / static char *fpm_conf_set_string(zval *value, void **config, intptr_t offset) /* {{{ */ { - char *new; - char **old = (char **) ((char *) *config + offset); - if (*old) { - return "it's already been defined. Can't do that twice."; + char **config_val = (char **) ((char *) *config + offset); + + if (!config_val) { + return "internal error: NULL value"; + } + + /* Check if there is a previous value to deallocate */ + if (*config_val) { + free(*config_val); } - new = strdup(Z_STRVAL_P(value)); - if (!new) { + *config_val = strdup(Z_STRVAL_P(value)); + if (!*config_val) { return "fpm_conf_set_string(): strdup() failed"; } - if (fpm_conf_expand_pool_name(&new) == -1) { + if (fpm_conf_expand_pool_name(config_val) == -1) { return "Can't use '$pool' when the pool is not defined"; } - *old = new; return NULL; } /* }}} */ @@ -219,8 +223,9 @@ static char *fpm_conf_set_integer(zval *value, void **config, intptr_t offset) / char *val = Z_STRVAL_P(value); char *p; + /* we don't use strtol because we don't want to allow negative values */ for (p = val; *p; p++) { - if ( p == val && *p == '-' ) continue; + if (p == val && *p == '-') continue; if (*p < '0' || *p > '9') { return "is not a valid number (greater or equal than zero)"; } From 69c3f8cbbabf313b74fbd29bb2ed268ff7c3e9e1 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 19 Jul 2011 23:01:41 +0000 Subject: [PATCH 0347/2394] - re apply the rng change specific to windows, long term it should be a std function but as this function was badly introduced in the 1st place, we have to fix the bad things here instead, pls do not revert again, bad idea. --- ext/openssl/openssl.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 270896a7335b3..1f0a79d93639a 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -4926,10 +4926,19 @@ PHP_FUNCTION(openssl_random_pseudo_bytes) buffer = emalloc(buffer_length + 1); +#ifdef PHP_WIN32 + strong_result = 1; + /* random/urandom equivalent on Windows */ + if (php_win32_get_random_bytes(buffer, (size_t) buffer_length) == FAILURE){ + efree(buffer); + RETURN_FALSE; + } +#else if ((strong_result = RAND_pseudo_bytes(buffer, buffer_length)) < 0) { efree(buffer); RETURN_FALSE; } +#endif buffer[buffer_length] = 0; RETVAL_STRINGL((char *)buffer, buffer_length, 0); From 81cd23df4a6a0bc6f7dbbafd12223475444147a3 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Wed, 20 Jul 2011 04:34:01 +0000 Subject: [PATCH 0348/2394] - Fixed bug #55073 (PHP-CLI-webserver does not listen on ipv6 interfaces), letting getaddrinfo(3) validate IPv6 addresses. --- sapi/cli/php_cli_server.c | 38 +++++++++++++++++++++++++++----------- 1 file changed, 27 insertions(+), 11 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index bad7d512132d4..fe1bdb1163009 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1806,17 +1806,33 @@ static int php_cli_server_ctor(php_cli_server *server, const char *addr, const c int port = 3000; php_socket_t server_sock = SOCK_ERR; - host = pestrdup(addr, 1); - if (!host || *host == ':' ) { - if (host) { - pefree(host, 1); + if (addr[0] == '[') { + char *p; + host = pestrdup(addr + 1, 1); + if (!host) { + return FAILURE; } - fprintf(stderr, "Invalid built-in web-server addr:port argument\n"); - return FAILURE; - } - - { - char *p = strchr(host, ':'); + p = strchr(host, ']'); + if (p) { + *p++ = '\0'; + if (*p == ':') { + port = strtol(p + 1, &p, 10); + } else if (*p != '\0') { + p = NULL; + } + } + if (!p) { + fprintf(stderr, "Invalid IPv6 address: %s\n", host); + retval = FAILURE; + goto out; + } + } else { + char *p; + host = pestrdup(addr, 1); + if (!host) { + return FAILURE; + } + p = strrchr(host, ':'); if (p) { *p++ = '\0'; port = strtol(p, &p, 10); @@ -2106,7 +2122,7 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ } sapi_module.phpinfo_as_text = 0; - printf("PHP Development Server is listening on %s:%d in %s ... Press Ctrl-C to quit.\n", server.host, server.port, document_root); + printf("PHP Development Server is listening on %s in %s ... Press Ctrl-C to quit.\n", server_bind_address, document_root); #if defined(HAVE_SIGNAL_H) && defined(SIGINT) signal(SIGINT, php_cli_server_sigint_handler); From 06381a8f2572f5d01ca48cea65c9ba985afbfe00 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Wed, 20 Jul 2011 08:43:12 +0000 Subject: [PATCH 0349/2394] - Better error handling. --- sapi/cli/php_cli_server.c | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index fe1bdb1163009..ddca03b036d6c 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1805,9 +1805,9 @@ static int php_cli_server_ctor(php_cli_server *server, const char *addr, const c int err = 0; int port = 3000; php_socket_t server_sock = SOCK_ERR; + char *p = NULL; if (addr[0] == '[') { - char *p; host = pestrdup(addr + 1, 1); if (!host) { return FAILURE; @@ -1817,27 +1817,32 @@ static int php_cli_server_ctor(php_cli_server *server, const char *addr, const c *p++ = '\0'; if (*p == ':') { port = strtol(p + 1, &p, 10); + if (port <= 0) { + p = NULL; + } } else if (*p != '\0') { p = NULL; } } - if (!p) { - fprintf(stderr, "Invalid IPv6 address: %s\n", host); - retval = FAILURE; - goto out; - } } else { - char *p; host = pestrdup(addr, 1); if (!host) { return FAILURE; } - p = strrchr(host, ':'); + p = strchr(host, ':'); if (p) { *p++ = '\0'; port = strtol(p, &p, 10); + if (port <= 0) { + p = NULL; + } } } + if (!p) { + fprintf(stderr, "Invalid address: %s\n", addr); + retval = FAILURE; + goto out; + } server_sock = php_network_listen_socket(host, &port, SOCK_STREAM, &server->address_family, &server->socklen, &errstr TSRMLS_CC); if (server_sock == SOCK_ERR) { From b07ad1e1a2721e030b589a38fb4d5758e2084cfe Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Wed, 20 Jul 2011 09:00:20 +0000 Subject: [PATCH 0350/2394] Fixed bug #55071. Maybe a bit overkill? --- sapi/cli/php_cli_server.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index ddca03b036d6c..04d24684e5275 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2127,7 +2127,19 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ } sapi_module.phpinfo_as_text = 0; - printf("PHP Development Server is listening on %s in %s ... Press Ctrl-C to quit.\n", server_bind_address, document_root); + { + struct timeval tv; + struct tm tm; + char buf[52]; + gettimeofday(&tv, NULL); + php_localtime_r(&tv.tv_sec, &tm); + php_asctime_r(&tm, buf); + printf("PHP Development Server started at %s" + "Listening on %s\n" + "Document root is %s\n" + "Press Ctrl-C to quit.\n", + buf, server_bind_address, document_root); + } #if defined(HAVE_SIGNAL_H) && defined(SIGINT) signal(SIGINT, php_cli_server_sigint_handler); From 038ba91426c7d30df2ce5b84c408f0291398161b Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Wed, 20 Jul 2011 18:24:14 +0000 Subject: [PATCH 0351/2394] Rename and enhance test for bug 55253 now that bugs web is up. --- .../{bug.add.zone2.phpt => bug55253.phpt} | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) rename ext/date/tests/{bug.add.zone2.phpt => bug55253.phpt} (57%) diff --git a/ext/date/tests/bug.add.zone2.phpt b/ext/date/tests/bug55253.phpt similarity index 57% rename from ext/date/tests/bug.add.zone2.phpt rename to ext/date/tests/bug55253.phpt index 6b59eb434afb5..3c0efc4691dd3 100755 --- a/ext/date/tests/bug.add.zone2.phpt +++ b/ext/date/tests/bug55253.phpt @@ -1,9 +1,9 @@ --TEST-- -DateTime::add() mistakenly modifies objects having zone type 2 +DateTime::add() and sub() result -1 hour on objects with time zone type 2 --CREDITS-- Daniel Convissor --XFAIL-- -Bug exists +Bug 55253 exists --FILE-- add($interval); echo 'Zone Type 3: ' . $date3->format('Y-m-d H:i:s T') . "\n"; echo 'Zone Type 2: ' . $date2->format('Y-m-d H:i:s T') . "\n"; +// Try subtracting from expected result. +$date3 = new DateTime('2010-10-04 04:19:48'); +$date2 = new DateTime('2010-10-04 04:19:48 EDT'); + +echo $interval->format('Subtract %h hours %i minutes from expected') . "\n"; +$date3->sub($interval); +$date2->sub($interval); + +echo 'Zone Type 3: ' . $date3->format('Y-m-d H:i:s T') . "\n"; +echo 'Zone Type 2: ' . $date2->format('Y-m-d H:i:s T') . "\n"; + ?> --EXPECT-- Zone Type 3: 2010-10-04 02:18:48 EDT @@ -31,3 +42,6 @@ Zone Type 2: 2010-10-04 02:18:48 EDT Add 2 hours 1 minutes Zone Type 3: 2010-10-04 04:19:48 EDT Zone Type 2: 2010-10-04 04:19:48 EDT +Subtract 2 hours 1 minutes from expected +Zone Type 3: 2010-10-04 02:18:48 EDT +Zone Type 2: 2010-10-04 02:18:48 EDT From 80cff0c0e933242ae434bb4f280b141b4d4594b4 Mon Sep 17 00:00:00 2001 From: Ryan Biesemeyer Date: Wed, 20 Jul 2011 18:59:05 +0000 Subject: [PATCH 0352/2394] tests for bug #55169 (mcrypt and openssl) --- ext/mcrypt/tests/bug55169.phpt | 43 +++++++++++++++++++++++++++++++++ ext/openssl/tests/bug55169.phpt | 43 +++++++++++++++++++++++++++++++++ 2 files changed, 86 insertions(+) create mode 100644 ext/mcrypt/tests/bug55169.phpt create mode 100644 ext/openssl/tests/bug55169.phpt diff --git a/ext/mcrypt/tests/bug55169.phpt b/ext/mcrypt/tests/bug55169.phpt new file mode 100644 index 0000000000000..7bddd50875ba6 --- /dev/null +++ b/ext/mcrypt/tests/bug55169.phpt @@ -0,0 +1,43 @@ +--TEST-- +mcrypt_create_iv +https://bugs.php.net/bug.php?id=55169 +--CREDIT-- +Ryan Biesemeyer +--FILE-- + +--EXPECTF-- +Input: 1 + Length: 1 + Hex: %x + +Input: 2 + Length: 2 + Hex: %x + +Input: 4 + Length: 4 + Hex: %x + +Input: 8 + Length: 8 + Hex: %x + +Input: 16 + Length: 16 + Hex: %x + +Input: 32 + Length: 32 + Hex: %x + +Input: 64 + Length: 64 + Hex: %x diff --git a/ext/openssl/tests/bug55169.phpt b/ext/openssl/tests/bug55169.phpt new file mode 100644 index 0000000000000..39c070013d392 --- /dev/null +++ b/ext/openssl/tests/bug55169.phpt @@ -0,0 +1,43 @@ +--TEST-- +openssl_random_pseudo_bytes test +https://bugs.php.net/bug.php?id=55169 +--INI-- +extension=php_openssl.dll +--SKIPIF-- +if(!extension_loaded('openssl')) echo 'skip - requires openssl extension' +--FILE-- + +--EXPECTF-- +Lengths: Bytes: -1 and Hex: 0 +string(0) "" +NULL + +Lengths: Bytes: 0 and Hex: 0 +string(0) "" +NULL + +Lengths: Bytes: 1 and Hex: 2 +string(2) "%x" +bool(true) + +Lengths: Bytes: 2 and Hex: 4 +string(4) "%x" +bool(true) + +Lengths: Bytes: 3 and Hex: 6 +string(6) "%x" +bool(true) + +Lengths: Bytes: 4 and Hex: 8 +string(8) "%x" +bool(true) From 2ac4cd97c89f383f7a5cb90aa5ce1bbedd050c7f Mon Sep 17 00:00:00 2001 From: Ryan Biesemeyer Date: Wed, 20 Jul 2011 20:57:17 +0000 Subject: [PATCH 0353/2394] update test for bug #55169, don't require the extension in INI --- ext/openssl/tests/bug55169.phpt | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/openssl/tests/bug55169.phpt b/ext/openssl/tests/bug55169.phpt index 39c070013d392..b18071080e888 100644 --- a/ext/openssl/tests/bug55169.phpt +++ b/ext/openssl/tests/bug55169.phpt @@ -1,8 +1,6 @@ --TEST-- openssl_random_pseudo_bytes test https://bugs.php.net/bug.php?id=55169 ---INI-- -extension=php_openssl.dll --SKIPIF-- if(!extension_loaded('openssl')) echo 'skip - requires openssl extension' --FILE-- From 7b21ee9b3fd28dcf70c138db9ff6859a6fdbbc85 Mon Sep 17 00:00:00 2001 From: Ryan Biesemeyer Date: Wed, 20 Jul 2011 21:13:03 +0000 Subject: [PATCH 0354/2394] update test for bug #55169, fix skipif --- ext/openssl/tests/bug55169.phpt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/openssl/tests/bug55169.phpt b/ext/openssl/tests/bug55169.phpt index b18071080e888..e45ac5b1f7d37 100644 --- a/ext/openssl/tests/bug55169.phpt +++ b/ext/openssl/tests/bug55169.phpt @@ -2,7 +2,9 @@ openssl_random_pseudo_bytes test https://bugs.php.net/bug.php?id=55169 --SKIPIF-- -if(!extension_loaded('openssl')) echo 'skip - requires openssl extension' + --FILE-- Date: Wed, 20 Jul 2011 21:25:39 +0000 Subject: [PATCH 0355/2394] removing openssl test for bug #55169 per Scott MacVicar's request; duplicate coverage of opensssl_random_pseudo_bytes.phpt --- ext/openssl/tests/bug55169.phpt | 43 --------------------------------- 1 file changed, 43 deletions(-) delete mode 100644 ext/openssl/tests/bug55169.phpt diff --git a/ext/openssl/tests/bug55169.phpt b/ext/openssl/tests/bug55169.phpt deleted file mode 100644 index e45ac5b1f7d37..0000000000000 --- a/ext/openssl/tests/bug55169.phpt +++ /dev/null @@ -1,43 +0,0 @@ ---TEST-- -openssl_random_pseudo_bytes test -https://bugs.php.net/bug.php?id=55169 ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -Lengths: Bytes: -1 and Hex: 0 -string(0) "" -NULL - -Lengths: Bytes: 0 and Hex: 0 -string(0) "" -NULL - -Lengths: Bytes: 1 and Hex: 2 -string(2) "%x" -bool(true) - -Lengths: Bytes: 2 and Hex: 4 -string(4) "%x" -bool(true) - -Lengths: Bytes: 3 and Hex: 6 -string(6) "%x" -bool(true) - -Lengths: Bytes: 4 and Hex: 8 -string(8) "%x" -bool(true) From 1f396617ebd7edf139466b2a9f9f5dca98339ae7 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Thu, 21 Jul 2011 07:31:29 +0000 Subject: [PATCH 0356/2394] - Show PHP_VERSION in the banner. Suggested by Chris and others. --- sapi/cli/php_cli_server.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 04d24684e5275..b33c8b0eb7a6c 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2134,11 +2134,11 @@ int do_cli_server(int argc, char **argv TSRMLS_DC) /* {{{ */ gettimeofday(&tv, NULL); php_localtime_r(&tv.tv_sec, &tm); php_asctime_r(&tm, buf); - printf("PHP Development Server started at %s" + printf("PHP %s Development Server started at %s" "Listening on %s\n" "Document root is %s\n" "Press Ctrl-C to quit.\n", - buf, server_bind_address, document_root); + PHP_VERSION, buf, server_bind_address, document_root); } #if defined(HAVE_SIGNAL_H) && defined(SIGINT) From 96c45c85adb97967298e31c546cece5e21ccf49e Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Thu, 21 Jul 2011 12:47:07 +0000 Subject: [PATCH 0357/2394] s/noOIDIncreasingCheck/oid_increasing_check/ --- ext/snmp/php_snmp.h | 2 +- ext/snmp/snmp.c | 15 ++++++++------- ext/snmp/tests/snmp-object-properties.phpt | 16 ++++++++-------- 3 files changed, 17 insertions(+), 16 deletions(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index e7b3576ee5de6..81db1130c4ca6 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -93,7 +93,7 @@ typedef struct _php_snmp_object { int enum_print; int oid_output_format; int snmp_errno; - int noOIDIncreasingCheck; + int oid_increasing_check; char snmp_errstr[128]; } php_snmp_object; diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 58f5e52427714..fe6e56736afe2 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -376,7 +376,7 @@ struct objid_query { long max_repetitions; int valueretrieval; int array_output; - int noOIDIncreasingCheck; + int oid_increasing_check; snmpobjarg *vars; }; @@ -879,7 +879,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, /* OID increase check */ if (st & SNMP_CMD_WALK) { - if (objid_query->noOIDIncreasingCheck == FALSE && snmp_oid_compare(name, name_length, vars->name, vars->name_length) >= 0) { + if (objid_query->oid_increasing_check == TRUE && snmp_oid_compare(name, name_length, vars->name, vars->name_length) >= 0) { snprint_objid(buf2, sizeof(buf2), vars->name, vars->name_length); php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_NOT_INCREASING, "Error: OID not increasing: %s", buf2); keepwalking = 0; @@ -1332,7 +1332,7 @@ static void php_snmp(INTERNAL_FUNCTION_PARAMETERS, int st, int version) objid_query.max_repetitions = -1; objid_query.non_repeaters = 0; objid_query.valueretrieval = SNMP_G(valueretrieval); - objid_query.noOIDIncreasingCheck = FALSE; + objid_query.oid_increasing_check = TRUE; if (session_less_mode) { if (version == SNMP_VERSION_3) { @@ -1426,7 +1426,7 @@ static void php_snmp(INTERNAL_FUNCTION_PARAMETERS, int st, int version) objid_query.max_repetitions = snmp_object->max_oids; } } - objid_query.noOIDIncreasingCheck = snmp_object->noOIDIncreasingCheck; + objid_query.oid_increasing_check = snmp_object->oid_increasing_check; objid_query.valueretrieval = snmp_object->valueretrieval; glob_snmp_object.enum_print = netsnmp_ds_get_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_PRINT_NUMERIC_ENUM); netsnmp_ds_set_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_PRINT_NUMERIC_ENUM, snmp_object->enum_print); @@ -1757,6 +1757,7 @@ PHP_METHOD(snmp, __construct) snmp_object->enum_print = netsnmp_ds_get_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_PRINT_NUMERIC_ENUM); snmp_object->oid_output_format = netsnmp_ds_get_int(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_OID_OUTPUT_FORMAT); snmp_object->quick_print = netsnmp_ds_get_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_QUICK_PRINT); + snmp_object->oid_increasing_check = TRUE; } /* }}} */ @@ -2118,7 +2119,7 @@ static int php_snmp_read_max_oids(php_snmp_object *snmp_object, zval **retval TS return SUCCESS; \ } -PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(noOIDIncreasingCheck) +PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(oid_increasing_check) PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(quick_print) PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(enum_print) @@ -2222,7 +2223,7 @@ static int php_snmp_write_##name(php_snmp_object *snmp_object, zval *newval TSRM PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(quick_print) PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(enum_print) -PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(noOIDIncreasingCheck) +PHP_SNMP_BOOL_PROPERTY_WRITER_FUNCTION(oid_increasing_check) /* {{{ */ static int php_snmp_write_oid_output_format(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) @@ -2284,7 +2285,7 @@ const php_snmp_prop_handler php_snmp_property_entries[] = { PHP_SNMP_PROPERTY_ENTRY_RECORD(quick_print), PHP_SNMP_PROPERTY_ENTRY_RECORD(enum_print), PHP_SNMP_PROPERTY_ENTRY_RECORD(oid_output_format), - PHP_SNMP_PROPERTY_ENTRY_RECORD(noOIDIncreasingCheck), + PHP_SNMP_PROPERTY_ENTRY_RECORD(oid_increasing_check), { NULL, 0, NULL, NULL} }; /* }}} */ diff --git a/ext/snmp/tests/snmp-object-properties.phpt b/ext/snmp/tests/snmp-object-properties.phpt index 51699a5a30822..e4c0538a09c51 100644 --- a/ext/snmp/tests/snmp-object-properties.phpt +++ b/ext/snmp/tests/snmp-object-properties.phpt @@ -26,7 +26,7 @@ $session->enum_print = TRUE; $session->quick_print = TRUE; $session->valueretrieval = SNMP_VALUE_LIBRARY; $session->oid_output_format = SNMP_OID_OUTPUT_NUMERIC; -$session->noOIDIncreasingCheck = TRUE; +$session->oid_increasing_check = FALSE; var_dump($session); @@ -35,7 +35,7 @@ $session->enum_print = "1"; $session->quick_print = "1"; $session->valueretrieval = "1"; $session->oid_output_format = "3"; -$session->noOIDIncreasingCheck = "45"; +$session->oid_increasing_check = "45"; var_dump($session); @@ -89,8 +89,8 @@ object(SNMP)#%d (%d) { bool(false) ["oid_output_format"]=> int(3) - ["noOIDIncreasingCheck"]=> - bool(false) + ["oid_increasing_check"]=> + bool(true) } object(SNMP)#%d (%d) { ["info"]=> @@ -114,8 +114,8 @@ object(SNMP)#%d (%d) { bool(true) ["oid_output_format"]=> int(4) - ["noOIDIncreasingCheck"]=> - bool(true) + ["oid_increasing_check"]=> + bool(false) } object(SNMP)#%d (%d) { ["info"]=> @@ -139,7 +139,7 @@ object(SNMP)#%d (%d) { bool(true) ["oid_output_format"]=> int(3) - ["noOIDIncreasingCheck"]=> + ["oid_increasing_check"]=> bool(true) } bool(true) @@ -167,7 +167,7 @@ object(SNMP)#%d (%d) { bool(true) ["oid_output_format"]=> int(3) - ["noOIDIncreasingCheck"]=> + ["oid_increasing_check"]=> bool(true) ["123"]=> string(11) "param_value" From b93e77900ecf5d7e345304d54fd8be2af0909429 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Thu, 21 Jul 2011 15:35:06 +0000 Subject: [PATCH 0358/2394] Have test for add/sub/diff one second during ST/DST transition in spring. --- ext/date/tests/DateTime_add-spring-type2-type2.phpt | 2 ++ ext/date/tests/DateTime_add-spring-type2-type3.phpt | 2 ++ ext/date/tests/DateTime_add-spring-type3-type2.phpt | 2 ++ ext/date/tests/DateTime_add-spring-type3-type3.phpt | 2 ++ ext/date/tests/DateTime_data-spring-type2-type2.inc | 12 ++++++++++++ ext/date/tests/DateTime_data-spring-type2-type3.inc | 12 ++++++++++++ ext/date/tests/DateTime_data-spring-type3-type2.inc | 12 ++++++++++++ ext/date/tests/DateTime_data-spring-type3-type3.inc | 12 ++++++++++++ ext/date/tests/DateTime_days-spring-type2-type2.phpt | 2 ++ ext/date/tests/DateTime_days-spring-type2-type3.phpt | 2 ++ ext/date/tests/DateTime_days-spring-type3-type2.phpt | 2 ++ ext/date/tests/DateTime_days-spring-type3-type3.phpt | 2 ++ ext/date/tests/DateTime_diff-spring-type2-type2.phpt | 2 ++ ext/date/tests/DateTime_diff-spring-type2-type3.phpt | 2 ++ ext/date/tests/DateTime_diff-spring-type3-type2.phpt | 2 ++ ext/date/tests/DateTime_diff-spring-type3-type3.phpt | 2 ++ ext/date/tests/DateTime_sub-spring-type2-type2.phpt | 2 ++ ext/date/tests/DateTime_sub-spring-type2-type3.phpt | 2 ++ ext/date/tests/DateTime_sub-spring-type3-type2.phpt | 2 ++ ext/date/tests/DateTime_sub-spring-type3-type3.phpt | 2 ++ 20 files changed, 80 insertions(+) diff --git a/ext/date/tests/DateTime_add-spring-type2-type2.phpt b/ext/date/tests/DateTime_add-spring-type2-type2.phpt index 8cf898138d390..b64c274766b9c 100644 --- a/ext/date/tests/DateTime_add-spring-type2-type2.phpt +++ b/ext/date/tests/DateTime_add-spring-type2-type2.phpt @@ -29,3 +29,5 @@ test_time_spring_type2_post_type2_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT test_time_spring_type2_post_type2_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** test_time_spring_type2_post_type2_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** test_time_spring_type2_post_type2_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_stsec_type2_dtsec: ADD: 2010-03-13 01:59:59 EST + P+0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** +test_time_spring_type2_dtsec_type2_stsec: ADD: 2010-03-15 03:00:00 EDT + P-0Y0M0DT0H0M1S = **2010-03-15 01:59:59 EST** diff --git a/ext/date/tests/DateTime_add-spring-type2-type3.phpt b/ext/date/tests/DateTime_add-spring-type2-type3.phpt index 45c43597c0047..5544651f29c08 100644 --- a/ext/date/tests/DateTime_add-spring-type2-type3.phpt +++ b/ext/date/tests/DateTime_add-spring-type2-type3.phpt @@ -29,3 +29,5 @@ test_time_spring_type2_post_type3_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT test_time_spring_type2_post_type3_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** test_time_spring_type2_post_type3_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** test_time_spring_type2_post_type3_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type2_stsec_type3_dtsec: ADD: 2010-03-13 01:59:59 EST + P+0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** +test_time_spring_type2_dtsec_type3_stsec: ADD: 2010-03-15 03:00:00 EDT + P-0Y0M0DT0H0M1S = **2010-03-15 01:59:59 EST** diff --git a/ext/date/tests/DateTime_add-spring-type3-type2.phpt b/ext/date/tests/DateTime_add-spring-type3-type2.phpt index 261bf4e0ab11f..fe75a5c26dba7 100644 --- a/ext/date/tests/DateTime_add-spring-type3-type2.phpt +++ b/ext/date/tests/DateTime_add-spring-type3-type2.phpt @@ -29,3 +29,5 @@ test_time_spring_type3_post_type2_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT test_time_spring_type3_post_type2_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** test_time_spring_type3_post_type2_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** test_time_spring_type3_post_type2_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_stsec_type2_dtsec: ADD: 2010-03-13 01:59:59 EST + P+0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** +test_time_spring_type3_dtsec_type2_stsec: ADD: 2010-03-15 03:00:00 EDT + P-0Y0M0DT0H0M1S = **2010-03-15 01:59:59 EST** diff --git a/ext/date/tests/DateTime_add-spring-type3-type3.phpt b/ext/date/tests/DateTime_add-spring-type3-type3.phpt index 17c371078d04a..b2a5c3e817328 100644 --- a/ext/date/tests/DateTime_add-spring-type3-type3.phpt +++ b/ext/date/tests/DateTime_add-spring-type3-type3.phpt @@ -29,3 +29,5 @@ test_time_spring_type3_post_type3_prev: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M2DT test_time_spring_type3_post_type3_st: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT18H49M39S = **2010-03-14 00:10:20 EST** test_time_spring_type3_post_type3_dt: ADD: 2010-03-15 19:59:59 EDT + P-0Y0M1DT16H43M4S = **2010-03-14 03:16:55 EDT** test_time_spring_type3_post_type3_post: ADD: 2010-03-15 18:57:55 EDT + P+0Y0M0DT1H2M4S = **2010-03-15 19:59:59 EDT** +test_time_spring_type3_stsec_type3_dtsec: ADD: 2010-03-13 01:59:59 EST + P+0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** +test_time_spring_type3_dtsec_type3_stsec: ADD: 2010-03-15 03:00:00 EDT + P-0Y0M0DT0H0M1S = **2010-03-15 01:59:59 EST** diff --git a/ext/date/tests/DateTime_data-spring-type2-type2.inc b/ext/date/tests/DateTime_data-spring-type2-type2.inc index 353d701f3eebb..3556b207b382a 100644 --- a/ext/date/tests/DateTime_data-spring-type2-type2.inc +++ b/ext/date/tests/DateTime_data-spring-type2-type2.inc @@ -15,6 +15,8 @@ date_default_timezone_set('America/New_York'); * + st: standard time on transition day 2010-03-14 00:10:20 EST * + dt: daylight time on the transition day 2010-03-14 03:16:55 EDT * + post: the day after the transition day 2010-03-15 19:59:59 EDT + * + stsec: standard time 1 sec before change 2010-03-14 01:59:59 EST + * + dtsec: daylight time first second 2010-03-14 03:00:00 EDT */ echo "test_time_spring_type2_prev_type2_prev: "; $end = new DateTime('2010-03-13 18:38:28 EST'); // prev, zt2 @@ -95,3 +97,13 @@ echo "test_time_spring_type2_post_type2_post: "; $end = new DateTime('2010-03-15 19:59:59 EDT'); // post, zt2 $start = new DateTime('2010-03-15 18:57:55 EDT'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_spring_type2_stsec_type2_dtsec: "; +$end = new DateTime('2010-03-15 03:00:00 EDT'); // dtsec, zt2 +$start = new DateTime('2010-03-13 01:59:59 EST'); // stsec, zt2 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_spring_type2_dtsec_type2_stsec: "; +$end = new DateTime('2010-03-15 01:59:59 EST'); // stsec, zt2 +$start = new DateTime('2010-03-13 03:00:00 EDT'); // dtsec, zt2 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-spring-type2-type3.inc b/ext/date/tests/DateTime_data-spring-type2-type3.inc index 11e960620de16..b06825837c71c 100644 --- a/ext/date/tests/DateTime_data-spring-type2-type3.inc +++ b/ext/date/tests/DateTime_data-spring-type2-type3.inc @@ -15,6 +15,8 @@ date_default_timezone_set('America/New_York'); * + st: standard time on transition day 2010-03-14 00:10:20 EST * + dt: daylight time on the transition day 2010-03-14 03:16:55 EDT * + post: the day after the transition day 2010-03-15 19:59:59 EDT + * + stsec: standard time 1 sec before change 2010-03-14 01:59:59 EST + * + dtsec: daylight time first second 2010-03-14 03:00:00 EDT */ echo "test_time_spring_type2_prev_type3_prev: "; $end = new DateTime('2010-03-13 18:38:28'); // prev, zt3 @@ -95,3 +97,13 @@ echo "test_time_spring_type2_post_type3_post: "; $end = new DateTime('2010-03-15 19:59:59'); // post, zt3 $start = new DateTime('2010-03-15 18:57:55 EDT'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_spring_type2_stsec_type3_dtsec: "; +$end = new DateTime('2010-03-15 03:00:00'); // dtsec, zt3 +$start = new DateTime('2010-03-13 01:59:59 EST'); // stsec, zt2 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_spring_type2_dtsec_type3_stsec: "; +$end = new DateTime('2010-03-15 01:59:59'); // stsec, zt3 +$start = new DateTime('2010-03-13 03:00:00 EDT'); // dtsec, zt2 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-spring-type3-type2.inc b/ext/date/tests/DateTime_data-spring-type3-type2.inc index 7cd2b703688d1..244cd58819e29 100644 --- a/ext/date/tests/DateTime_data-spring-type3-type2.inc +++ b/ext/date/tests/DateTime_data-spring-type3-type2.inc @@ -15,6 +15,8 @@ date_default_timezone_set('America/New_York'); * + st: standard time on transition day 2010-03-14 00:10:20 EST * + dt: daylight time on the transition day 2010-03-14 03:16:55 EDT * + post: the day after the transition day 2010-03-15 19:59:59 EDT + * + stsec: standard time 1 sec before change 2010-03-14 01:59:59 EST + * + dtsec: daylight time first second 2010-03-14 03:00:00 EDT */ echo "test_time_spring_type3_prev_type2_prev: "; $end = new DateTime('2010-03-13 18:38:28 EST'); // prev, zt2 @@ -95,3 +97,13 @@ echo "test_time_spring_type3_post_type2_post: "; $end = new DateTime('2010-03-15 19:59:59 EDT'); // post, zt2 $start = new DateTime('2010-03-15 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_spring_type3_stsec_type2_dtsec: "; +$end = new DateTime('2010-03-15 03:00:00 EDT'); // dtsec, zt2 +$start = new DateTime('2010-03-13 01:59:59'); // stsec, zt3 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_spring_type3_dtsec_type2_stsec: "; +$end = new DateTime('2010-03-15 01:59:59 EST'); // stsec, zt2 +$start = new DateTime('2010-03-13 03:00:00'); // dtsec, zt3 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-spring-type3-type3.inc b/ext/date/tests/DateTime_data-spring-type3-type3.inc index 5c5d5ffba4479..d87373c5a4b40 100644 --- a/ext/date/tests/DateTime_data-spring-type3-type3.inc +++ b/ext/date/tests/DateTime_data-spring-type3-type3.inc @@ -15,6 +15,8 @@ date_default_timezone_set('America/New_York'); * + st: standard time on transition day 2010-03-14 00:10:20 * + dt: daylight time on the transition day 2010-03-14 03:16:55 * + post: the day after the transition day 2010-03-15 19:59:59 + * + stsec: standard time 1 sec before change 2010-03-14 01:59:59 + * + dtsec: daylight time first second 2010-03-14 03:00:00 */ echo "test_time_spring_type3_prev_type3_prev: "; $end = new DateTime('2010-03-13 18:38:28'); // prev, zt3 @@ -95,3 +97,13 @@ echo "test_time_spring_type3_post_type3_post: "; $end = new DateTime('2010-03-15 19:59:59'); // post, zt3 $start = new DateTime('2010-03-15 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); + +echo "test_time_spring_type3_stsec_type3_dtsec: "; +$end = new DateTime('2010-03-15 03:00:00'); // dtsec, zt3 +$start = new DateTime('2010-03-13 01:59:59'); // stsec, zt3 +examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); + +echo "test_time_spring_type3_dtsec_type3_stsec: "; +$end = new DateTime('2010-03-15 01:59:59'); // stsec, zt3 +$start = new DateTime('2010-03-13 03:00:00'); // dtsec, zt3 +examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_days-spring-type2-type2.phpt b/ext/date/tests/DateTime_days-spring-type2-type2.phpt index ead12e0e6e909..3f9c353523ae7 100644 --- a/ext/date/tests/DateTime_days-spring-type2-type2.phpt +++ b/ext/date/tests/DateTime_days-spring-type2-type2.phpt @@ -27,3 +27,5 @@ test_time_spring_type2_post_type2_prev: DAYS: **2** test_time_spring_type2_post_type2_st: DAYS: **1** test_time_spring_type2_post_type2_dt: DAYS: **1** test_time_spring_type2_post_type2_post: DAYS: **0** +test_time_spring_type2_stsec_type2_dtsec: DAYS: **0** +test_time_spring_type2_dtsec_type2_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type2-type3.phpt b/ext/date/tests/DateTime_days-spring-type2-type3.phpt index bed7ac8f469ec..77ac5fdb6daf5 100644 --- a/ext/date/tests/DateTime_days-spring-type2-type3.phpt +++ b/ext/date/tests/DateTime_days-spring-type2-type3.phpt @@ -27,3 +27,5 @@ test_time_spring_type2_post_type3_prev: DAYS: **2** test_time_spring_type2_post_type3_st: DAYS: **1** test_time_spring_type2_post_type3_dt: DAYS: **1** test_time_spring_type2_post_type3_post: DAYS: **0** +test_time_spring_type2_stsec_type3_dtsec: DAYS: **0** +test_time_spring_type2_dtsec_type3_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type3-type2.phpt b/ext/date/tests/DateTime_days-spring-type3-type2.phpt index 782dee567d08a..09aa8d9c1d7af 100644 --- a/ext/date/tests/DateTime_days-spring-type3-type2.phpt +++ b/ext/date/tests/DateTime_days-spring-type3-type2.phpt @@ -27,3 +27,5 @@ test_time_spring_type3_post_type2_prev: DAYS: **2** test_time_spring_type3_post_type2_st: DAYS: **1** test_time_spring_type3_post_type2_dt: DAYS: **1** test_time_spring_type3_post_type2_post: DAYS: **0** +test_time_spring_type3_stsec_type2_dtsec: DAYS: **0** +test_time_spring_type3_dtsec_type2_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type3-type3.phpt b/ext/date/tests/DateTime_days-spring-type3-type3.phpt index 4b8e8c0d9c374..f947329dea9b3 100644 --- a/ext/date/tests/DateTime_days-spring-type3-type3.phpt +++ b/ext/date/tests/DateTime_days-spring-type3-type3.phpt @@ -27,3 +27,5 @@ test_time_spring_type3_post_type3_prev: DAYS: **2** test_time_spring_type3_post_type3_st: DAYS: **1** test_time_spring_type3_post_type3_dt: DAYS: **1** test_time_spring_type3_post_type3_post: DAYS: **0** +test_time_spring_type3_stsec_type3_dtsec: DAYS: **0** +test_time_spring_type3_dtsec_type3_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_diff-spring-type2-type2.phpt b/ext/date/tests/DateTime_diff-spring-type2-type2.phpt index 7e9d5a5e71739..4c590cd998af4 100644 --- a/ext/date/tests/DateTime_diff-spring-type2-type2.phpt +++ b/ext/date/tests/DateTime_diff-spring-type2-type2.phpt @@ -29,3 +29,5 @@ test_time_spring_type2_post_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03- test_time_spring_type2_post_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** test_time_spring_type2_post_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** test_time_spring_type2_post_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** +test_time_spring_type2_stsec_type2_dtsec: DIFF: 2010-03-15 03:00:00 EDT - 2010-03-13 01:59:59 EST = **P+0Y0M0DT0H0M1S** +test_time_spring_type2_dtsec_type2_stsec: DIFF: 2010-03-15 01:59:59 EST - 2010-03-15 03:00:00 EDT = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_diff-spring-type2-type3.phpt b/ext/date/tests/DateTime_diff-spring-type2-type3.phpt index 0c19782ed76e1..98dcf7968268b 100644 --- a/ext/date/tests/DateTime_diff-spring-type2-type3.phpt +++ b/ext/date/tests/DateTime_diff-spring-type2-type3.phpt @@ -29,3 +29,5 @@ test_time_spring_type2_post_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03- test_time_spring_type2_post_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** test_time_spring_type2_post_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** test_time_spring_type2_post_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** +test_time_spring_type2_stsec_type3_dtsec: DIFF: 2010-03-15 03:00:00 EDT - 2010-03-13 01:59:59 EST = **P+0Y0M0DT0H0M1S** +test_time_spring_type2_dtsec_type3_stsec: DIFF: 2010-03-15 01:59:59 EST - 2010-03-15 03:00:00 EDT = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_diff-spring-type3-type2.phpt b/ext/date/tests/DateTime_diff-spring-type3-type2.phpt index f2a31c1780ca6..5a59f78df2271 100644 --- a/ext/date/tests/DateTime_diff-spring-type3-type2.phpt +++ b/ext/date/tests/DateTime_diff-spring-type3-type2.phpt @@ -29,3 +29,5 @@ test_time_spring_type3_post_type2_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03- test_time_spring_type3_post_type2_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** test_time_spring_type3_post_type2_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** test_time_spring_type3_post_type2_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** +test_time_spring_type3_stsec_type2_dtsec: DIFF: 2010-03-15 03:00:00 EDT - 2010-03-13 01:59:59 EST = **P+0Y0M0DT0H0M1S** +test_time_spring_type3_dtsec_type2_stsec: DIFF: 2010-03-15 01:59:59 EST - 2010-03-15 03:00:00 EDT = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_diff-spring-type3-type3.phpt b/ext/date/tests/DateTime_diff-spring-type3-type3.phpt index 5f5c3d5b3efc2..926f299e03f67 100644 --- a/ext/date/tests/DateTime_diff-spring-type3-type3.phpt +++ b/ext/date/tests/DateTime_diff-spring-type3-type3.phpt @@ -29,3 +29,5 @@ test_time_spring_type3_post_type3_prev: DIFF: 2010-03-13 18:38:28 EST - 2010-03- test_time_spring_type3_post_type3_st: DIFF: 2010-03-14 00:10:20 EST - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT18H49M39S** test_time_spring_type3_post_type3_dt: DIFF: 2010-03-14 03:16:55 EDT - 2010-03-15 19:59:59 EDT = **P-0Y0M1DT16H43M4S** test_time_spring_type3_post_type3_post: DIFF: 2010-03-15 19:59:59 EDT - 2010-03-15 18:57:55 EDT = **P+0Y0M0DT1H2M4S** +test_time_spring_type3_stsec_type2_dtsec: DIFF: 2010-03-15 03:00:00 EDT - 2010-03-13 01:59:59 EST = **P+0Y0M0DT0H0M1S** +test_time_spring_type3_dtsec_type2_stsec: DIFF: 2010-03-15 01:59:59 EST - 2010-03-15 03:00:00 EDT = **P-0Y0M0DT0H0M1S** diff --git a/ext/date/tests/DateTime_sub-spring-type2-type2.phpt b/ext/date/tests/DateTime_sub-spring-type2-type2.phpt index 55eb45c024d2d..2b1817d79b3b8 100644 --- a/ext/date/tests/DateTime_sub-spring-type2-type2.phpt +++ b/ext/date/tests/DateTime_sub-spring-type2-type2.phpt @@ -29,3 +29,5 @@ test_time_spring_type2_post_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT test_time_spring_type2_post_type2_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** test_time_spring_type2_post_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** test_time_spring_type2_post_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** +test_time_spring_type2_stsec_type2_dtsec: SUB: 2010-03-15 03:00:00 EDT - P+0Y0M0DT0H0M1S = **2010-03-13 01:59:59 EST** +test_time_spring_type2_dtsec_type2_stsec: SUB: 2010-03-15 01:59:59 EST - P-0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** diff --git a/ext/date/tests/DateTime_sub-spring-type2-type3.phpt b/ext/date/tests/DateTime_sub-spring-type2-type3.phpt index f41586cc2fb4b..a5c43df911c7a 100644 --- a/ext/date/tests/DateTime_sub-spring-type2-type3.phpt +++ b/ext/date/tests/DateTime_sub-spring-type2-type3.phpt @@ -29,3 +29,5 @@ test_time_spring_type2_post_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT test_time_spring_type2_post_type3_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** test_time_spring_type2_post_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** test_time_spring_type2_post_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** +test_time_spring_type2_stsec_type3_dtsec: SUB: 2010-03-15 03:00:00 EDT - P+0Y0M0DT0H0M1S = **2010-03-13 01:59:59 EST** +test_time_spring_type2_dtsec_type3_stsec: SUB: 2010-03-15 01:59:59 EST - P-0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** diff --git a/ext/date/tests/DateTime_sub-spring-type3-type2.phpt b/ext/date/tests/DateTime_sub-spring-type3-type2.phpt index 234940d351359..bcbbe25c79411 100644 --- a/ext/date/tests/DateTime_sub-spring-type3-type2.phpt +++ b/ext/date/tests/DateTime_sub-spring-type3-type2.phpt @@ -29,3 +29,5 @@ test_time_spring_type3_post_type2_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT test_time_spring_type3_post_type2_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** test_time_spring_type3_post_type2_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** test_time_spring_type3_post_type2_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** +test_time_spring_type3_stsec_type2_dtsec: SUB: 2010-03-15 03:00:00 EDT - P+0Y0M0DT0H0M1S = **2010-03-13 01:59:59 EST** +test_time_spring_type3_dtsec_type2_stsec: SUB: 2010-03-15 01:59:59 EST - P-0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** diff --git a/ext/date/tests/DateTime_sub-spring-type3-type3.phpt b/ext/date/tests/DateTime_sub-spring-type3-type3.phpt index 73d9e27489c91..2ed190f744d4f 100644 --- a/ext/date/tests/DateTime_sub-spring-type3-type3.phpt +++ b/ext/date/tests/DateTime_sub-spring-type3-type3.phpt @@ -29,3 +29,5 @@ test_time_spring_type3_post_type3_prev: SUB: 2010-03-13 18:38:28 EST - P-0Y0M2DT test_time_spring_type3_post_type3_st: SUB: 2010-03-14 00:10:20 EST - P-0Y0M1DT18H49M39S = **2010-03-15 19:59:59 EDT** test_time_spring_type3_post_type3_dt: SUB: 2010-03-14 03:16:55 EDT - P-0Y0M1DT16H43M4S = **2010-03-15 19:59:59 EDT** test_time_spring_type3_post_type3_post: SUB: 2010-03-15 19:59:59 EDT - P+0Y0M0DT1H2M4S = **2010-03-15 18:57:55 EDT** +test_time_spring_type3_stsec_type3_dtsec: SUB: 2010-03-15 03:00:00 EDT - P+0Y0M0DT0H0M1S = **2010-03-13 01:59:59 EST** +test_time_spring_type3_dtsec_type3_stsec: SUB: 2010-03-15 01:59:59 EST - P-0Y0M0DT0H0M1S = **2010-03-15 03:00:00 EDT** From 800b0cfcba856138dc2bb6c62ecbc3c424556ff5 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Thu, 21 Jul 2011 19:45:18 +0000 Subject: [PATCH 0359/2394] Revert r311205. Test works in original form and should not vary between branches in this case. --- ext/date/tests/bug33532.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/date/tests/bug33532.phpt b/ext/date/tests/bug33532.phpt index d778d8b5cee5b..286ceb4cec018 100644 --- a/ext/date/tests/bug33532.phpt +++ b/ext/date/tests/bug33532.phpt @@ -29,10 +29,10 @@ print "datestr " . date ("H:i:s A F j Y T", $tStamp) . "\n"; TZ has NOT been set Should strftime==datestr? Strftime seems to assume GMT tStamp. input 10:00:00 AM July 1 2005 -strftime 10:00:00 AM July 1 2005 UTC -0500 +strftime 10:00:00 AM July 1 2005 UTC +0000 datestr 10:00:00 AM July 1 2005 UTC Setting TZ input 10:00:00 AM July 1 2005 -strftime 10:00:00 AM July 1 2005 EST -0500 +strftime 10:00:00 AM July 1 2005 EST +1000 datestr 10:00:00 AM July 1 2005 EST From 5ef9ab3b03867e8644b5140d618842199ef69202 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Thu, 21 Jul 2011 19:56:54 +0000 Subject: [PATCH 0360/2394] Fix spelling error. --- ext/date/tests/DateTime_data-fall-type2-type2.inc | 2 +- ext/date/tests/DateTime_data-fall-type2-type3.inc | 2 +- ext/date/tests/DateTime_data-fall-type3-type2.inc | 2 +- ext/date/tests/DateTime_data-fall-type3-type3.inc | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/date/tests/DateTime_data-fall-type2-type2.inc b/ext/date/tests/DateTime_data-fall-type2-type2.inc index faf8f437594e6..c45c059f32ba0 100644 --- a/ext/date/tests/DateTime_data-fall-type2-type2.inc +++ b/ext/date/tests/DateTime_data-fall-type2-type2.inc @@ -18,7 +18,7 @@ date_default_timezone_set('America/New_York'); * + st: standard time on the transition day 2010-11-07 03:16:55 EST * + post: the day after the transition day 2010-11-08 19:59:59 EST * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT - * + stsec: standard time first secodn 2010-11-07 01:00:00 EST + * + stsec: standard time first second 2010-11-07 01:00:00 EST */ echo "test_time_fall_type2_prev_type2_prev: "; $end = new DateTime('2010-11-06 18:38:28 EDT'); // prev, zt2 diff --git a/ext/date/tests/DateTime_data-fall-type2-type3.inc b/ext/date/tests/DateTime_data-fall-type2-type3.inc index c135dae2d6828..a62a8b2b415e1 100644 --- a/ext/date/tests/DateTime_data-fall-type2-type3.inc +++ b/ext/date/tests/DateTime_data-fall-type2-type3.inc @@ -18,7 +18,7 @@ date_default_timezone_set('America/New_York'); * + st: standard time on the transition day 2010-11-07 03:16:55 EST * + post: the day after the transition day 2010-11-08 19:59:59 EST * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT - * + stsec: standard time first secodn 2010-11-07 01:00:00 EST + * + stsec: standard time first second 2010-11-07 01:00:00 EST */ echo "test_time_fall_type2_prev_type3_prev: "; $end = new DateTime('2010-11-06 18:38:28'); // prev, zt3 diff --git a/ext/date/tests/DateTime_data-fall-type3-type2.inc b/ext/date/tests/DateTime_data-fall-type3-type2.inc index 38917fd5ecd2b..51ef5ff52fc87 100644 --- a/ext/date/tests/DateTime_data-fall-type3-type2.inc +++ b/ext/date/tests/DateTime_data-fall-type3-type2.inc @@ -18,7 +18,7 @@ date_default_timezone_set('America/New_York'); * + st: standard time on the transition day 2010-11-07 03:16:55 EST * + post: the day after the transition day 2010-11-08 19:59:59 EST * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT - * + stsec: standard time first secodn 2010-11-07 01:00:00 EST + * + stsec: standard time first second 2010-11-07 01:00:00 EST */ echo "test_time_fall_type3_prev_type2_prev: "; $end = new DateTime('2010-11-06 18:38:28 EDT'); // prev, zt2 diff --git a/ext/date/tests/DateTime_data-fall-type3-type3.inc b/ext/date/tests/DateTime_data-fall-type3-type3.inc index 53a97408768dc..48c1c332a5d50 100644 --- a/ext/date/tests/DateTime_data-fall-type3-type3.inc +++ b/ext/date/tests/DateTime_data-fall-type3-type3.inc @@ -18,7 +18,7 @@ date_default_timezone_set('America/New_York'); * + st: standard time on the transition day 2010-11-07 03:16:55 * + post: the day after the transition day 2010-11-08 19:59:59 * + dtsec: daylight time 1 sec before change 2010-11-07 01:59:59 EDT, + TZ - * + stsec: standard time first secodn 2010-11-07 01:00:00 EST, + TZ + * + stsec: standard time first second 2010-11-07 01:00:00 EST, + TZ */ echo "test_time_fall_type3_prev_type3_prev: "; $end = new DateTime('2010-11-06 18:38:28'); // prev, zt3 From cc1c7af0375db5b7ad2c7752569b925cc3372377 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 22 Jul 2011 11:25:30 +0000 Subject: [PATCH 0361/2394] - remove magic quotes support, functions are kept (see the NEWS entry for the details) for BC reasons but do not allow to set enable MQ --- Zend/zend_float.c | 2 +- Zend/zend_ini_scanner.c | 2 +- Zend/zend_ini_scanner_defs.h | 2 +- Zend/zend_language_scanner.c | 2 +- Zend/zend_language_scanner_defs.h | 2 +- Zend/zend_operators.h | 1 - configure.in | 9 - ext/bz2/bz2.c | 7 - ext/dba/dba.c | 20 +- ext/exif/exif.c | 32 +-- ext/exif/tests/bug34704.phpt | 1 - ext/exif/tests/exif002.phpt | 1 - ext/exif/tests/exif006.phpt | 90 -------- ext/filter/filter.c | 2 - ext/filter/tests/bug39763.phpt | 17 -- ext/filter/tests/bug42718-2.phpt | 3 - ext/filter/tests/bug42718.phpt | 1 - ext/hash/tests/mhash_001.phpt | 2 - ext/hash/tests/mhash_004.phpt | 2 - ext/iconv/tests/translit-utf8.phpt | 1 - ext/interbase/ibase_query.c | 7 +- ext/mssql/php_mssql.c | 18 +- ext/mysql/php_mysql.c | 8 + ext/mysqli/mysqli.c | 4 + ext/pcre/php_pcre.c | 2 +- ext/pcre/tests/bug33200.phpt | 13 -- ext/pdo/tests/pdo_test.inc | 3 +- ext/pgsql/pgsql.c | 17 +- ext/phar/func_interceptors.c | 2 +- ext/phar/tests/fgc_edgecases.phpt | 24 +-- ext/spl/examples/dbaarray.inc | 5 +- ext/spl/spl_directory.c | 15 -- .../SplFileObject_fwrite_variation_003.phpt | 22 -- ext/standard/basic_functions.c | 24 ++- ext/standard/exec.c | 11 +- ext/standard/file.c | 76 ++----- ext/standard/php_string.h | 1 - ext/standard/streamsfuncs.c | 15 +- ext/standard/string.c | 87 ++------ ext/standard/tests/file/magic_quotes.phpt | 77 ------- .../get_cfg_var_variation8.phpt | 37 ++-- .../get_magic_quotes_gpc.phpt | 39 +--- .../get_magic_quotes_runtime.phpt | 52 +---- .../set_magic_quotes_runtime_variation1.phpt | 204 ------------------ .../tests/strings/add-and-stripslashes.phpt | 12 +- .../tests/strings/addslashes_variation3.phpt | 196 ----------------- ext/standard/tests/strings/bug22904.phpt | 30 --- .../tests/strings/parse_str_basic3.phpt | Bin 5223 -> 5087 bytes .../strings/stripslashes_variation5.phpt | Bin 8397 -> 0 bytes ext/sybase_ct/php_sybase_ct.c | 6 +- ext/sysvsem/tests/sysv.phpt | 2 - ext/xml/tests/xml001.phpt | 2 - ext/xml/tests/xml002.phpt | 2 - ext/xml/tests/xml003.phpt | 2 - ext/xml/tests/xml004.phpt | 2 - ext/xml/tests/xml_closures_001.phpt | 2 - ext/zlib/tests/004.phpt | 23 -- ext/zlib/zlib.c | 11 +- main/main.c | 11 +- main/php_globals.h | 4 - main/php_variables.c | 27 +-- main/rfc1867.c | 11 +- php.ini-development | 29 --- php.ini-production | 29 --- sapi/cgi/cgi_main.c | 5 - sapi/fpm/fpm/fpm_main.c | 5 - tests/basic/023.phpt | 2 - tests/basic/024.phpt | 1 - tests/basic/025.phpt | 1 - tests/basic/026.phpt | 1 - tests/basic/027.phpt | 1 - tests/basic/bug46313-win.phpt | 65 ++++++ tests/basic/bug46313.phpt | 54 ----- tests/basic/bug46759.phpt | 20 -- tests/security/magic_quotes_gpc.phpt | 13 -- win32/build/config.w32.h.in | 1 - win32/syslog.reg | 2 +- 77 files changed, 211 insertions(+), 1323 deletions(-) diff --git a/Zend/zend_float.c b/Zend/zend_float.c index db8d000dd4a6f..9e9f7bb651ef7 100644 --- a/Zend/zend_float.c +++ b/Zend/zend_float.c @@ -31,7 +31,7 @@ ZEND_API void zend_init_fpu(TSRMLS_D) /* {{{ */ EG(saved_fpu_cw_ptr) = (void*)&EG(saved_fpu_cw); } XPFPA_STORE_CW(EG(saved_fpu_cw_ptr)); - XPFPA_SWITCH_DOUBLE(); +// XPFPA_SWITCH_DOUBLE(); #else EG(saved_fpu_cw_ptr) = NULL; #endif diff --git a/Zend/zend_ini_scanner.c b/Zend/zend_ini_scanner.c index a7e71a5a5d180..0b950c212e22d 100644 --- a/Zend/zend_ini_scanner.c +++ b/Zend/zend_ini_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon Aug 30 19:00:33 2010 */ +/* Generated by re2c 0.13.5 on Mon Jan 03 10:40:06 2011 */ #line 1 "Zend/zend_ini_scanner.l" /* +----------------------------------------------------------------------+ diff --git a/Zend/zend_ini_scanner_defs.h b/Zend/zend_ini_scanner_defs.h index a3e7cbca70e94..1610e3a1f17d5 100644 --- a/Zend/zend_ini_scanner_defs.h +++ b/Zend/zend_ini_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon Aug 30 19:00:34 2010 */ +/* Generated by re2c 0.13.5 on Mon Jan 03 10:40:06 2011 */ #line 3 "Zend/zend_ini_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 9097b5b8bb7ac..bdbae58f7edd5 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Thu Jun 23 17:57:45 2011 */ +/* Generated by re2c 0.13.5 on Fri Jul 22 13:16:46 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 0c78414666643..04997ff06038b 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Thu Jun 23 17:57:45 2011 */ +/* Generated by re2c 0.13.5 on Fri Jul 22 13:16:46 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 8e3a37eee75ff..e599ca4971d8d 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -474,7 +474,6 @@ static zend_always_inline int fast_increment_function(zval *op1) "0:" : : "r"(op1)); -#else if (UNEXPECTED(Z_LVAL_P(op1) == LONG_MAX)) { /* switch to double */ Z_DVAL_P(op1) = (double)LONG_MAX + 1.0; diff --git a/configure.in b/configure.in index 0b0eb200ae19e..666ee31da692b 100644 --- a/configure.in +++ b/configure.in @@ -901,15 +901,6 @@ else AC_DEFINE(PHP_SIGCHILD, 0, [ ]) fi -PHP_ARG_ENABLE(magic-quotes, whether to enable magic quotes by default, -[ --enable-magic-quotes Enable magic quotes by default.], no, no) - -if test "$PHP_MAGIC_QUOTES" = "yes"; then - AC_DEFINE(MAGIC_QUOTES, 1, [ ]) -else - AC_DEFINE(MAGIC_QUOTES, 0, [ ]) -fi - PHP_ARG_ENABLE(libgcc, whether to explicitly link against libgcc, [ --enable-libgcc Enable explicitly linking against libgcc], no, no) diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c index 1e3c7b7617e3b..310589fc102f9 100644 --- a/ext/bz2/bz2.c +++ b/ext/bz2/bz2.c @@ -352,13 +352,6 @@ static PHP_FUNCTION(bzread) } Z_STRVAL_P(return_value)[Z_STRLEN_P(return_value)] = 0; - - if (PG(magic_quotes_runtime)) { - Z_STRVAL_P(return_value) = php_addslashes( Z_STRVAL_P(return_value), - Z_STRLEN_P(return_value), - &Z_STRLEN_P(return_value), 1 TSRMLS_CC); - } - Z_TYPE_P(return_value) = IS_STRING; } /* }}} */ diff --git a/ext/dba/dba.c b/ext/dba/dba.c index 97b83d45a1af6..55fde324596b7 100644 --- a/ext/dba/dba.c +++ b/ext/dba/dba.c @@ -560,20 +560,9 @@ static void php_dba_update(INTERNAL_FUNCTION_PARAMETERS, int mode) DBA_WRITE_CHECK; - if (PG(magic_quotes_runtime)) { - v = estrndup(val, val_len); - php_stripslashes(v, &val_len TSRMLS_CC); - if (info->hnd->update(info, key_str, key_len, v, val_len, mode TSRMLS_CC) == SUCCESS) { - efree(v); - DBA_ID_DONE; - RETURN_TRUE; - } - efree(v); - } else { - if (info->hnd->update(info, key_str, key_len, val, val_len, mode TSRMLS_CC) == SUCCESS) { - DBA_ID_DONE; - RETURN_TRUE; - } + if (info->hnd->update(info, key_str, key_len, val, val_len, mode TSRMLS_CC) == SUCCESS) { + DBA_ID_DONE; + RETURN_TRUE; } DBA_ID_DONE; @@ -1029,9 +1018,6 @@ PHP_FUNCTION(dba_fetch) skip = 0; } if((val = info->hnd->fetch(info, key_str, key_len, skip, &len TSRMLS_CC)) != NULL) { - if (val && PG(magic_quotes_runtime)) { - val = php_addslashes(val, len, &len, 1 TSRMLS_CC); - } DBA_ID_DONE; RETURN_STRINGL(val, len, 0); } diff --git a/ext/exif/exif.c b/ext/exif/exif.c index f5e837484581a..48af4d64ddfd7 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -1697,11 +1697,7 @@ static void exif_iif_add_value(image_info_type *image_info, int section_index, c case TAG_FMT_STRING: if (value) { length = php_strnlen(value, length); - if (PG(magic_quotes_runtime)) { - info_value->s = php_addslashes(value, length, &length, 0 TSRMLS_CC); - } else { - info_value->s = estrndup(value, length); - } + info_value->s = estrndup(value, length); info_data->length = length; } else { info_data->length = 0; @@ -1724,11 +1720,7 @@ static void exif_iif_add_value(image_info_type *image_info, int section_index, c case TAG_FMT_UNDEFINED: if (value) { /* do not recompute length here */ - if (PG(magic_quotes_runtime)) { - info_value->s = php_addslashes(value, length, &length, 0 TSRMLS_CC); - } else { - info_value->s = estrndup(value, length); - } + info_value->s = estrndup(value, length); info_data->length = length; } else { info_data->length = 0; @@ -1850,11 +1842,7 @@ static void exif_iif_add_str(image_info_type *image_info, int section_index, cha info_data->format = TAG_FMT_STRING; info_data->length = 1; info_data->name = estrdup(name); - if (PG(magic_quotes_runtime)) { - info_data->value.s = php_addslashes(value, strlen(value), NULL, 0 TSRMLS_CC); - } else { - info_data->value.s = estrdup(value); - } + info_data->value.s = estrdup(value); image_info->sections_found |= 1<info_list[section_index].count++; } @@ -1895,17 +1883,9 @@ static void exif_iif_add_buffer(image_info_type *image_info, int section_index, info_data->format = TAG_FMT_UNDEFINED; info_data->length = length; info_data->name = estrdup(name); - if (PG(magic_quotes_runtime)) { -#ifdef EXIF_DEBUG - exif_error_docref(NULL EXIFERR_CC, image_info, E_NOTICE, "Adding %s as buffer%s", name, exif_char_dump(value, length, 0)); -#endif - info_data->value.s = php_addslashes(value, length, &length, 0 TSRMLS_CC); - info_data->length = length; - } else { - info_data->value.s = safe_emalloc(length, 1, 1); - memcpy(info_data->value.s, value, length); - info_data->value.s[length] = 0; - } + info_data->value.s = safe_emalloc(length, 1, 1); + memcpy(info_data->value.s, value, length); + info_data->value.s[length] = 0; image_info->sections_found |= 1<info_list[section_index].count++; } diff --git a/ext/exif/tests/bug34704.phpt b/ext/exif/tests/bug34704.phpt index b6b26de78d67c..7688ce861af33 100755 --- a/ext/exif/tests/bug34704.phpt +++ b/ext/exif/tests/bug34704.phpt @@ -3,7 +3,6 @@ Bug #34704 (Infinite recursion due to corrupt JPEG) --SKIPIF-- --INI-- -magic_quotes_runtime=0 output_handler= zlib.output_compression=0 --FILE-- diff --git a/ext/exif/tests/exif002.phpt b/ext/exif/tests/exif002.phpt index 1b1220c60073a..2a70f2920c9a5 100644 --- a/ext/exif/tests/exif002.phpt +++ b/ext/exif/tests/exif002.phpt @@ -3,7 +3,6 @@ Check for exif_thumbnail --SKIPIF-- --INI-- -magic_quotes_runtime=0 output_handler= zlib.output_compression=0 --FILE-- diff --git a/ext/exif/tests/exif006.phpt b/ext/exif/tests/exif006.phpt index 10458c083d951..e69de29bb2d1d 100644 --- a/ext/exif/tests/exif006.phpt +++ b/ext/exif/tests/exif006.phpt @@ -1,90 +0,0 @@ ---TEST-- -Check for exif_read_data, magic_quotes_runtime ---SKIPIF-- - ---INI-- -output_handler= -zlib.output_compression=0 -magic_quotes_runtime=1 ---FILE-- - ---EXPECTF-- -Deprecated: Directive 'magic_quotes_runtime' is deprecated in PHP 5.3 and greater in Unknown on line 0 -array(5) { - ["FILE"]=> - array(6) { - ["FileName"]=> - string(9) "test6.jpg" - ["FileDateTime"]=> - int(%d) - ["FileSize"]=> - int(1240) - ["FileType"]=> - int(2) - ["MimeType"]=> - string(10) "image/jpeg" - ["SectionsFound"]=> - string(33) "ANY_TAG, IFD0, THUMBNAIL, COMMENT" - } - ["COMPUTED"]=> - array(12) { - ["html"]=> - string(24) "width=\"1\" height=\"1\"" - ["Height"]=> - int(1) - ["Width"]=> - int(1) - ["IsColor"]=> - int(1) - ["ByteOrderMotorola"]=> - int(1) - ["UserComment"]=> - string(16) "Hallo \'Du\'+da!" - ["UserCommentEncoding"]=> - string(5) "ASCII" - ["Copyright"]=> - string(45) "Photo \"M. Boerger\"., Edited \'M. Boerger\'." - ["Copyright.Photographer"]=> - string(21) "Photo \"M. Boerger\"." - ["Copyright.Editor"]=> - string(22) "Edited \'M. Boerger\'." - ["Thumbnail.FileType"]=> - int(2) - ["Thumbnail.MimeType"]=> - string(10) "image/jpeg" - } - ["IFD0"]=> - array(2) { - ["Copyright"]=> - string(21) "Photo \"M. Boerger\"." - ["UserComment"]=> - string(5) "ASCII" - } - ["THUMBNAIL"]=> - array(2) { - ["JPEGInterchangeFormat"]=> - int(134) - ["JPEGInterchangeFormatLength"]=> - int(523) - } - ["COMMENT"]=> - array(3) { - [0]=> - string(13) "Comment \"1\"" - [1]=> - string(13) "Comment \'2\'" - [2]=> - string(13) "Comment #3end" - } -} diff --git a/ext/filter/filter.c b/ext/filter/filter.c index e67bc7546dd31..6e617190601ab 100644 --- a/ext/filter/filter.c +++ b/ext/filter/filter.c @@ -464,8 +464,6 @@ static unsigned int php_sapi_filter(int arg, char *var, char **val, unsigned int Z_STRVAL(new_var) = estrndup(*val, val_len); INIT_PZVAL(tmp_new_var); php_zval_filter(&tmp_new_var, IF_G(default_filter), IF_G(default_filter_flags), NULL, NULL/*charset*/, 0 TSRMLS_CC); - } else if (PG(magic_quotes_gpc) && !retval) { /* for PARSE_STRING php_register_variable_safe() will do the addslashes() */ - Z_STRVAL(new_var) = php_addslashes(*val, Z_STRLEN(new_var), &Z_STRLEN(new_var), 0 TSRMLS_CC); } else { Z_STRVAL(new_var) = estrndup(*val, val_len); } diff --git a/ext/filter/tests/bug39763.phpt b/ext/filter/tests/bug39763.phpt index 36ee41561a8a6..e69de29bb2d1d 100644 --- a/ext/filter/tests/bug39763.phpt +++ b/ext/filter/tests/bug39763.phpt @@ -1,17 +0,0 @@ ---TEST-- -Bug #39763 (filter applies magic_quotes twice in parse_str()) ---INI-- -magic_quotes_gpc=1 -filter.default= ---FILE-- - ---EXPECT-- -Deprecated: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in Unknown on line 0 -\"probably a bug\" -\"probably a bug\" \ No newline at end of file diff --git a/ext/filter/tests/bug42718-2.phpt b/ext/filter/tests/bug42718-2.phpt index 13cd990d0031d..ed210681d3621 100644 --- a/ext/filter/tests/bug42718-2.phpt +++ b/ext/filter/tests/bug42718-2.phpt @@ -4,7 +4,6 @@ Bug #42718 - 2 (unsafe_raw filter not applied when configured as default filter) --INI-- display_errors=0 -magic_quotes_gpc=1 filter.default=unsafe_raw filter.default_flags= --GET-- @@ -13,9 +12,7 @@ a=1%00 --EXPECT-- unsafe_raw -1\0 diff --git a/ext/filter/tests/bug42718.phpt b/ext/filter/tests/bug42718.phpt index d1ede3f7d2cfc..ba56d3988a6fd 100644 --- a/ext/filter/tests/bug42718.phpt +++ b/ext/filter/tests/bug42718.phpt @@ -5,7 +5,6 @@ FILTER_UNSAFE_RAW not applied when configured as default filter, even with flags --SKIPIF-- --INI-- -magic_quotes_gpc=0 filter.default=unsafe_raw filter.default_flags=4 --GET-- diff --git a/ext/hash/tests/mhash_001.phpt b/ext/hash/tests/mhash_001.phpt index b2a92839befac..5df03782592af 100644 --- a/ext/hash/tests/mhash_001.phpt +++ b/ext/hash/tests/mhash_001.phpt @@ -1,7 +1,5 @@ --TEST-- mhash() test ---INI-- -magic_quotes_runtime=0 --SKIPIF-- --INI-- -magic_quotes_runtime=0 error_reporting=2047 --FILE-- vary_string; /* no break */ case SQL_TEXT: - if (PG(magic_quotes_runtime)) { - Z_STRVAL_P(val) = php_addslashes(data, len, &Z_STRLEN_P(val), 0 TSRMLS_CC); - Z_TYPE_P(val) = IS_STRING; - } else { - ZVAL_STRINGL(val,(char *) data,len,1); - } + ZVAL_STRINGL(val,(char *) data,len,1); break; case SQL_SHORT: n = *(short *) data; diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c index 3e00158334819..f3af40bc2b2a5 100644 --- a/ext/mssql/php_mssql.c +++ b/ext/mssql/php_mssql.c @@ -1520,27 +1520,17 @@ static void php_mssql_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, int result_type) if (Z_TYPE(result->data[result->cur_row][i]) != IS_NULL) { char *data; int data_len; - int should_copy; if (Z_TYPE(result->data[result->cur_row][i]) == IS_STRING) { - if (PG(magic_quotes_runtime)) { - data = php_addslashes(Z_STRVAL(result->data[result->cur_row][i]), Z_STRLEN(result->data[result->cur_row][i]), &data_len, 0 TSRMLS_CC); - should_copy = 0; - } - else - { - data = Z_STRVAL(result->data[result->cur_row][i]); - data_len = Z_STRLEN(result->data[result->cur_row][i]); - should_copy = 1; - } + data = Z_STRVAL(result->data[result->cur_row][i]); + data_len = Z_STRLEN(result->data[result->cur_row][i]); if (result_type & MSSQL_NUM) { - add_index_stringl(return_value, i, data, data_len, should_copy); - should_copy = 1; + add_index_stringl(return_value, i, data, data_len, 1); } if (result_type & MSSQL_ASSOC) { - add_assoc_stringl(return_value, result->fields[i].name, data, data_len, should_copy); + add_assoc_stringl(return_value, result->fields[i].name, data, data_len, 1); } } else if (Z_TYPE(result->data[result->cur_row][i]) == IS_LONG) { diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index df9dac549b99d..cfce37d5d564b 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -1955,12 +1955,16 @@ Q: String or long first? if (sql_row[field_offset]) { Z_TYPE_P(return_value) = IS_STRING; +#if PHP_API_VERSION < 20100412 if (PG(magic_quotes_runtime)) { Z_STRVAL_P(return_value) = php_addslashes(sql_row[field_offset], sql_row_lengths[field_offset],&Z_STRLEN_P(return_value), 0 TSRMLS_CC); } else { +#endif Z_STRLEN_P(return_value) = sql_row_lengths[field_offset]; Z_STRVAL_P(return_value) = (char *) safe_estrndup(sql_row[field_offset], Z_STRLEN_P(return_value)); +#if PHP_API_VERSION < 20100412 } +#endif } else { Z_TYPE_P(return_value) = IS_NULL; } @@ -2078,12 +2082,16 @@ static void php_mysql_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, long result_type, MAKE_STD_ZVAL(data); +#if PHP_API_VERSION < 20100412 if (PG(magic_quotes_runtime)) { Z_TYPE_P(data) = IS_STRING; Z_STRVAL_P(data) = php_addslashes(mysql_row[i], mysql_row_lengths[i], &Z_STRLEN_P(data), 0 TSRMLS_CC); } else { +#endif ZVAL_STRINGL(data, mysql_row[i], mysql_row_lengths[i], 1); +#if PHP_API_VERSION < 20100412 } +#endif if (result_type & MYSQL_NUM) { add_index_zval(return_value, i, data); diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index add2d123d8636..b784ff863f76f 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -1137,13 +1137,17 @@ void php_mysqli_fetch_into_hash_aux(zval *return_value, MYSQL_RES * result, long #endif { +#if PHP_API_VERSION < 20100412 /* check if we need magic quotes */ if (PG(magic_quotes_runtime)) { Z_TYPE_P(res) = IS_STRING; Z_STRVAL_P(res) = php_addslashes(row[i], field_len[i], &Z_STRLEN_P(res), 0 TSRMLS_CC); } else { +#endif ZVAL_STRINGL(res, row[i], field_len[i], 1); +#if PHP_API_VERSION < 20100412 } +#endif } if (fetchtype & MYSQLI_NUM) { diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index cc96fafe87793..5e1a75394f673 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -898,7 +898,7 @@ static int preg_do_eval(char *eval_str, int eval_str_len, char *subject, match = subject + offsets[backref<<1]; match_len = offsets[(backref<<1)+1] - offsets[backref<<1]; if (match_len) { - esc_match = php_addslashes_ex(match, match_len, &esc_match_len, 0, 1 TSRMLS_CC); + esc_match = php_addslashes(match, match_len, &esc_match_len, 0 TSRMLS_CC); } else { esc_match = match; esc_match_len = 0; diff --git a/ext/pcre/tests/bug33200.phpt b/ext/pcre/tests/bug33200.phpt index ddbb06519bb3d..e69de29bb2d1d 100644 --- a/ext/pcre/tests/bug33200.phpt +++ b/ext/pcre/tests/bug33200.phpt @@ -1,13 +0,0 @@ ---TEST-- -Bug #33200 (magic_quotes_sybase = On makes 'e' modifier misbehave) ---INI-- -magic_quotes_sybase=1 ---FILE-- - ---EXPECT-- -Deprecated: Directive 'magic_quotes_sybase' is deprecated in PHP 5.3 and greater in Unknown on line 0 -SOME '$SAMPLE' TEXT diff --git a/ext/pdo/tests/pdo_test.inc b/ext/pdo/tests/pdo_test.inc index bbaeb71af7e96..f2e076793a755 100644 --- a/ext/pdo/tests/pdo_test.inc +++ b/ext/pdo/tests/pdo_test.inc @@ -11,7 +11,6 @@ if (getenv('PDOTEST_DSN') === false) { $append = true; } } - if (ini_get('magic_quotes_runtime')) $common = stripslashes($common); $conf = eval($common); foreach($conf['ENV'] as $n=>$v) putenv("$n=$v"); } @@ -76,4 +75,4 @@ class PDOTest { return self::factory(); } } -?> \ No newline at end of file +?> diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c index 9ab1a071e6ae6..c2dd8b4a27f9d 100644 --- a/ext/pgsql/pgsql.c +++ b/ext/pgsql/pgsql.c @@ -2499,12 +2499,8 @@ static void php_pgsql_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, long result_type, int should_copy=0; const uint element_len = strlen(element); - if (PG(magic_quotes_runtime)) { - data = php_addslashes(element, element_len, &data_len, 0 TSRMLS_CC); - } else { - data = safe_estrndup(element, element_len); - data_len = element_len; - } + data = safe_estrndup(element, element_len); + data_len = element_len; if (result_type & PGSQL_NUM) { add_index_stringl(return_value, i, data, data_len, should_copy); @@ -6213,12 +6209,9 @@ PHP_PGSQL_API int php_pgsql_result2array(PGresult *pg_result, zval *ret_array TS size_t data_len; const size_t element_len = strlen(element); - if (PG(magic_quotes_runtime)) { - data = php_addslashes(element, element_len, &data_len, 0 TSRMLS_CC); - } else { - data = safe_estrndup(element, element_len); - data_len = element_len; - } + data = safe_estrndup(element, element_len); + data_len = element_len; + field_name = PQfname(pg_result, i); add_assoc_stringl(row, field_name, data, data_len, 0); } diff --git a/ext/phar/func_interceptors.c b/ext/phar/func_interceptors.c index 1b3f0f461b809..d90aeac7ac0e5 100644 --- a/ext/phar/func_interceptors.c +++ b/ext/phar/func_interceptors.c @@ -203,7 +203,7 @@ PHAR_FUNC(phar_file_get_contents) /* {{{ */ /* uses mmap if possible */ if ((len = php_stream_copy_to_mem(stream, &contents, maxlen, 0)) > 0) { -#if PHP_MAJOR_VERSION < 6 +#if PHP_API_VERSION < 20100412 if (PG(magic_quotes_runtime)) { int newlen; contents = php_addslashes(contents, len, &newlen, 1 TSRMLS_CC); /* 1 = free source string */ diff --git a/ext/phar/tests/fgc_edgecases.phpt b/ext/phar/tests/fgc_edgecases.phpt index 5b85d0dcf2876..b943546963b1c 100644 --- a/ext/phar/tests/fgc_edgecases.phpt +++ b/ext/phar/tests/fgc_edgecases.phpt @@ -33,7 +33,6 @@ echo file_get_contents("foob", true); echo file_get_contents("./hi", 0, $context); echo file_get_contents("../oops"); echo file_get_contents("./hi", 0, $context, 50000); -ini_set("magic_quotes_runtime", 1); echo file_get_contents("./hi"); echo file_get_contents("./hi", 0, $context, 0, 0); ?> @@ -60,7 +59,6 @@ echo file_get_contents("foob", true); echo file_get_contents("./hi", 0, $context); echo file_get_contents("../oops"); echo file_get_contents("./hi", 0, $context, 50000); -ini_set("magic_quotes_runtime", 1); echo file_get_contents("./hi"); echo file_get_contents("./hi", 0, $context, 0, 0); ?> @@ -78,7 +76,6 @@ echo file_get_contents("foob", true); echo file_get_contents("./hi", 0, $context); echo file_get_contents("../oops"); echo file_get_contents("./hi", 0, $context, 50000); -ini_set("magic_quotes_runtime", 1); echo file_get_contents("./hi"); echo file_get_contents("./hi", 0, $context, 0, 0); ?> @@ -87,17 +84,16 @@ Warning: file_get_contents(phar://%sfgc_edgecases.phar.php/oops): failed to open Warning: file_get_contents(): Failed to seek to position 50000 in the stream in phar://%sfgc_edgecases.phar.php/foo/hi on line %d ===DONE=== diff --git a/ext/spl/examples/dbaarray.inc b/ext/spl/examples/dbaarray.inc index fcd6bb378a3f7..d448ad7299b41 100755 --- a/ext/spl/examples/dbaarray.inc +++ b/ext/spl/examples/dbaarray.inc @@ -51,9 +51,6 @@ class DbaArray extends DbaReader implements ArrayAccess { $data = dba_fetch($name, $this->db); if($data) { - if (ini_get('magic_quotes_runtime')) { - $data = stripslashes($data); - } //return unserialize($data); return $data; } @@ -95,4 +92,4 @@ class DbaArray extends DbaReader implements ArrayAccess } } -?> \ No newline at end of file +?> diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index f1eaffe479ef7..3c7055097541e 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -1993,7 +1993,6 @@ static int spl_filesystem_file_read(spl_filesystem_object *intern, int silent TS { char *buf; size_t line_len = 0; - int len; long line_add = (intern->u.file.current_line || intern->u.file.current_zval) ? 1 : 0; spl_filesystem_file_free_line(intern TSRMLS_CC); @@ -2026,11 +2025,6 @@ static int spl_filesystem_file_read(spl_filesystem_object *intern, int silent TS buf[line_len] = '\0'; } - if (PG(magic_quotes_runtime)) { - buf = php_addslashes(buf, line_len, &len, 1 TSRMLS_CC); - line_len = len; - } - intern->u.file.current_line = buf; intern->u.file.current_line_len = line_len; } @@ -2778,7 +2772,6 @@ SPL_METHOD(SplFileObject, fwrite) spl_filesystem_object *intern = (spl_filesystem_object*)zend_object_store_get_object(getThis() TSRMLS_CC); char *str; int str_len; - int ret; long length = 0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &str, &str_len, &length) == FAILURE) { @@ -2792,14 +2785,6 @@ SPL_METHOD(SplFileObject, fwrite) RETURN_LONG(0); } - if (PG(magic_quotes_runtime)) { - str = estrndup(str, str_len); - php_stripslashes(str, &str_len TSRMLS_CC); - ret = php_stream_write(intern->u.file.stream, str, str_len); - efree(str); - RETURN_LONG(ret); - } - RETURN_LONG(php_stream_write(intern->u.file.stream, str, str_len)); } /* }}} */ diff --git a/ext/spl/tests/SplFileObject_fwrite_variation_003.phpt b/ext/spl/tests/SplFileObject_fwrite_variation_003.phpt index 429d2a66bc914..e69de29bb2d1d 100644 --- a/ext/spl/tests/SplFileObject_fwrite_variation_003.phpt +++ b/ext/spl/tests/SplFileObject_fwrite_variation_003.phpt @@ -1,22 +0,0 @@ ---TEST-- -SplFileObject::fwrite function - writing with magic_quotes_runtime ini set ---FILE-- -fwrite('"test" \'write\''); -var_dump(file_get_contents($file)); -?> ---CLEAN-- - ---EXPECT-- -string(18) "\"test\" \'write\'" diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 0c7079286cc45..48c4fccdbf22e 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -2966,8 +2966,8 @@ const zend_function_entry basic_functions[] = { /* {{{ */ PHP_DEP_FALIAS(magic_quotes_runtime, set_magic_quotes_runtime, arginfo_set_magic_quotes_runtime) PHP_DEP_FE(set_magic_quotes_runtime, arginfo_set_magic_quotes_runtime) - PHP_FE(get_magic_quotes_gpc, arginfo_get_magic_quotes_gpc) - PHP_FE(get_magic_quotes_runtime, arginfo_get_magic_quotes_runtime) + PHP_DEP_FE(get_magic_quotes_gpc, arginfo_get_magic_quotes_gpc) + PHP_DEP_FE(get_magic_quotes_runtime, arginfo_get_magic_quotes_runtime) PHP_FE(error_log, arginfo_error_log) PHP_FE(error_get_last, arginfo_error_get_last) @@ -4586,7 +4586,7 @@ PHP_FUNCTION(get_cfg_var) /* }}} */ /* {{{ proto bool set_magic_quotes_runtime(int new_setting) - Set the current active configuration setting of magic_quotes_runtime and return previous */ + magic_quotes_runtime is not supported anymore */ PHP_FUNCTION(set_magic_quotes_runtime) { zend_bool new_setting; @@ -4594,11 +4594,11 @@ PHP_FUNCTION(set_magic_quotes_runtime) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "b", &new_setting) == FAILURE) { return; } - - if (zend_alter_ini_entry_ex("magic_quotes_runtime", sizeof("magic_quotes_runtime"), new_setting ? "1" : "0", 1, PHP_INI_USER, PHP_INI_STAGE_RUNTIME, 0 TSRMLS_CC) == FAILURE) { - RETURN_FALSE; + + if (new_setting) { + php_error_docref(NULL TSRMLS_CC, E_CORE_ERROR, "magic_quotes_runtime is not supported anymore"); } - RETURN_TRUE; + RETURN_FALSE; } /* }}} */ @@ -4606,7 +4606,10 @@ PHP_FUNCTION(set_magic_quotes_runtime) Get the current active configuration setting of magic_quotes_runtime */ PHP_FUNCTION(get_magic_quotes_runtime) { - RETURN_LONG(PG(magic_quotes_runtime)); + if (zend_parse_parameters_none() == FAILURE) { + return; + } + RETURN_FALSE; } /* }}} */ @@ -4614,7 +4617,10 @@ PHP_FUNCTION(get_magic_quotes_runtime) Get the current active configuration setting of magic_quotes_gpc */ PHP_FUNCTION(get_magic_quotes_gpc) { - RETURN_LONG(PG(magic_quotes_gpc)); + if (zend_parse_parameters_none() == FAILURE) { + return; + } + RETURN_FALSE; } /* }}} */ diff --git a/ext/standard/exec.c b/ext/standard/exec.c index 890f73726bc20..ac96fe68155ff 100644 --- a/ext/standard/exec.c +++ b/ext/standard/exec.c @@ -60,7 +60,7 @@ PHPAPI int php_exec(int type, char *cmd, zval *array, zval *return_value TSRMLS_DC) { FILE *fp; - char *buf, *tmp=NULL; + char *buf; int l = 0, pclose_return; char *b, *d=NULL; php_stream *stream; @@ -139,14 +139,7 @@ PHPAPI int php_exec(int type, char *cmd, zval *array, zval *return_value TSRMLS_ } /* Return last line from the shell command */ - if (PG(magic_quotes_runtime)) { - int len; - - tmp = php_addslashes(buf, bufl, &len, 0 TSRMLS_CC); - RETVAL_STRINGL(tmp, len, 0); - } else { - RETVAL_STRINGL(buf, bufl, 1); - } + RETVAL_STRINGL(buf, bufl, 1); } else { /* should return NULL, but for BC we return "" */ RETVAL_EMPTY_STRING(); } diff --git a/ext/standard/file.c b/ext/standard/file.c index f9fba1bc9fce9..3ef8980f24841 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -423,13 +423,7 @@ PHP_FUNCTION(get_meta_tags) have_name = 1; } else if (saw_content) { STR_FREE(value); - /* Get the CONTENT attr (Single word attr, non-quoted) */ - if (PG(magic_quotes_runtime)) { - value = php_addslashes(md.token_data, 0, &md.token_len, 0 TSRMLS_CC); - } else { - value = estrndup(md.token_data, md.token_len); - } - + value = estrndup(md.token_data, md.token_len); have_content = 1; } @@ -463,13 +457,7 @@ PHP_FUNCTION(get_meta_tags) have_name = 1; } else if (saw_content) { STR_FREE(value); - /* Get the CONTENT attr (Single word attr, non-quoted) */ - if (PG(magic_quotes_runtime)) { - value = php_addslashes(md.token_data, 0, &md.token_len, 0 TSRMLS_CC); - } else { - value = estrndup(md.token_data, md.token_len); - } - + value = estrndup(md.token_data, md.token_len); have_content = 1; } @@ -561,11 +549,6 @@ PHP_FUNCTION(file_get_contents) } if ((len = php_stream_copy_to_mem(stream, &contents, maxlen, 0)) > 0) { - - if (PG(magic_quotes_runtime)) { - contents = php_addslashes(contents, len, &len, 1 TSRMLS_CC); /* 1 = free source string */ - } - RETVAL_STRINGL(contents, len, 0); } else if (len == 0) { RETVAL_EMPTY_STRING(); @@ -724,9 +707,9 @@ PHP_FUNCTION(file) { char *filename; int filename_len; - char *slashed, *target_buf=NULL, *p, *s, *e; + char *target_buf=NULL, *p, *s, *e; register int i = 0; - int target_len, len; + int target_len; char eol_marker = '\n'; long flags = 0; zend_bool use_include_path; @@ -778,13 +761,7 @@ PHP_FUNCTION(file) do { p++; parse_eol: - if (PG(magic_quotes_runtime)) { - /* s is in target_buf which is freed at the end of the function */ - slashed = php_addslashes(s, (p-s), &len, 0 TSRMLS_CC); - add_index_stringl(return_value, i++, slashed, len, 0); - } else { - add_index_stringl(return_value, i++, estrndup(s, p-s), p-s, 0); - } + add_index_stringl(return_value, i++, estrndup(s, p-s), p-s, 0); s = p; } while ((p = memchr(p, eol_marker, (e-p)))); } else { @@ -797,13 +774,7 @@ PHP_FUNCTION(file) s = ++p; continue; } - if (PG(magic_quotes_runtime)) { - /* s is in target_buf which is freed at the end of the function */ - slashed = php_addslashes(s, (p-s-windows_eol), &len, 0 TSRMLS_CC); - add_index_stringl(return_value, i++, slashed, len, 0); - } else { - add_index_stringl(return_value, i++, estrndup(s, p-s-windows_eol), p-s-windows_eol, 0); - } + add_index_stringl(return_value, i++, estrndup(s, p-s-windows_eol), p-s-windows_eol, 0); s = ++p; } while ((p = memchr(p, eol_marker, (e-p)))); } @@ -1049,16 +1020,11 @@ PHPAPI PHP_FUNCTION(fgets) } } - if (PG(magic_quotes_runtime)) { - Z_STRVAL_P(return_value) = php_addslashes(buf, line_len, &Z_STRLEN_P(return_value), 1 TSRMLS_CC); - Z_TYPE_P(return_value) = IS_STRING; - } else { - ZVAL_STRINGL(return_value, buf, line_len, 0); - /* resize buffer if it's much larger than the result. - * Only needed if the user requested a buffer size. */ - if (argc > 1 && Z_STRLEN_P(return_value) < len / 2) { - Z_STRVAL_P(return_value) = erealloc(buf, line_len + 1); - } + ZVAL_STRINGL(return_value, buf, line_len, 0); + /* resize buffer if it's much larger than the result. + * Only needed if the user requested a buffer size. */ + if (argc > 1 && Z_STRLEN_P(return_value) < len / 2) { + Z_STRVAL_P(return_value) = erealloc(buf, line_len + 1); } return; @@ -1219,11 +1185,6 @@ PHPAPI PHP_FUNCTION(fwrite) PHP_STREAM_TO_ZVAL(stream, &arg1); - if (PG(magic_quotes_runtime)) { - buffer = estrndup(arg2, num_bytes); - php_stripslashes(buffer, &num_bytes TSRMLS_CC); - } - ret = php_stream_write(stream, buffer ? buffer : arg2, num_bytes); if (buffer) { efree(buffer); @@ -1790,11 +1751,6 @@ PHPAPI PHP_FUNCTION(fread) /* needed because recv/read/gzread doesnt put a null at the end*/ Z_STRVAL_P(return_value)[Z_STRLEN_P(return_value)] = 0; - - if (PG(magic_quotes_runtime)) { - Z_STRVAL_P(return_value) = php_addslashes(Z_STRVAL_P(return_value), - Z_STRLEN_P(return_value), &Z_STRLEN_P(return_value), 1 TSRMLS_CC); - } Z_TYPE_P(return_value) = IS_STRING; } /* }}} */ @@ -1950,15 +1906,7 @@ PHPAPI int php_fputcsv(php_stream *stream, zval *fields, char delimiter, char en smart_str_appendc(&csvline, '\n'); smart_str_0(&csvline); - if (!PG(magic_quotes_runtime)) { - ret = php_stream_write(stream, csvline.c, csvline.len); - } else { - char *buffer = estrndup(csvline.c, csvline.len); - int len = csvline.len; - php_stripslashes(buffer, &len TSRMLS_CC); - ret = php_stream_write(stream, buffer, len); - efree(buffer); - } + ret = php_stream_write(stream, csvline.c, csvline.len); smart_str_free(&csvline); diff --git a/ext/standard/php_string.h b/ext/standard/php_string.h index 23c703336abaa..c6d916dbcc182 100644 --- a/ext/standard/php_string.h +++ b/ext/standard/php_string.h @@ -122,7 +122,6 @@ PHPAPI char *php_strtoupper(char *s, size_t len); PHPAPI char *php_strtolower(char *s, size_t len); PHPAPI char *php_strtr(char *str, int len, char *str_from, char *str_to, int trlen); PHPAPI char *php_addslashes(char *str, int length, int *new_length, int freeit TSRMLS_DC); -PHPAPI char *php_addslashes_ex(char *str, int length, int *new_length, int freeit, int ignore_sybase TSRMLS_DC); PHPAPI char *php_addcslashes(char *str, int length, int *new_length, int freeit, char *what, int wlength TSRMLS_DC); PHPAPI void php_stripslashes(char *str, int *len TSRMLS_DC); PHPAPI void php_stripcslashes(char *str, int *len); diff --git a/ext/standard/streamsfuncs.c b/ext/standard/streamsfuncs.c index befb13fd7aa9b..54aef6afa00e2 100644 --- a/ext/standard/streamsfuncs.c +++ b/ext/standard/streamsfuncs.c @@ -395,13 +395,7 @@ PHP_FUNCTION(stream_socket_recvfrom) } read_buf[recvd] = '\0'; - if (PG(magic_quotes_runtime)) { - Z_TYPE_P(return_value) = IS_STRING; - Z_STRVAL_P(return_value) = php_addslashes(Z_STRVAL_P(return_value), Z_STRLEN_P(return_value), &Z_STRLEN_P(return_value), 1 TSRMLS_CC); - return; - } else { - RETURN_STRINGL(read_buf, recvd, 0); - } + RETURN_STRINGL(read_buf, recvd, 0); } efree(read_buf); @@ -417,8 +411,7 @@ PHP_FUNCTION(stream_get_contents) zval *zsrc; long maxlen = PHP_STREAM_COPY_ALL, desiredpos = -1L; - int len, - newlen; + int len; char *contents = NULL; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|ll", &zsrc, &maxlen, &desiredpos) == FAILURE) { @@ -450,10 +443,6 @@ PHP_FUNCTION(stream_get_contents) len = php_stream_copy_to_mem(stream, &contents, maxlen, 0); if (contents) { - if (len && PG(magic_quotes_runtime)) { - contents = php_addslashes(contents, len, &newlen, 1 TSRMLS_CC); /* 1 = free source string */ - len = newlen; - } RETVAL_STRINGL(contents, len, 0); } else { RETVAL_EMPTY_STRING(); diff --git a/ext/standard/string.c b/ext/standard/string.c index 44c5cd3b0062c..1717b3b711593 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -3015,34 +3015,6 @@ PHPAPI void php_stripslashes(char *str, int *len TSRMLS_DC) s = str; t = str; - if (PG(magic_quotes_sybase)) { - while (l > 0) { - if (*t == '\'') { - if ((l > 0) && (t[1] == '\'')) { - t++; - if (len != NULL) { - (*len)--; - } - l--; - } - *s++ = *t++; - } else if (*t == '\\' && t[1] == '0' && l > 0) { - *s++='\0'; - t+=2; - if (len != NULL) { - (*len)--; - } - l--; - } else { - *s++ = *t++; - } - l--; - } - *s = '\0'; - - return; - } - while (l > 0) { if (*t == '\\') { t++; /* skip the slash */ @@ -3286,14 +3258,6 @@ PHPAPI char *php_addcslashes(char *str, int length, int *new_length, int should_ /* {{{ php_addslashes */ PHPAPI char *php_addslashes(char *str, int length, int *new_length, int should_free TSRMLS_DC) -{ - return php_addslashes_ex(str, length, new_length, should_free, 0 TSRMLS_CC); -} -/* }}} */ - -/* {{{ php_addslashes_ex - */ -PHPAPI char *php_addslashes_ex(char *str, int length, int *new_length, int should_free, int ignore_sybase TSRMLS_DC) { /* maximum string length, worst case situation */ char *new_str; @@ -3313,42 +3277,23 @@ PHPAPI char *php_addslashes_ex(char *str, int length, int *new_length, int shoul end = source + length; target = new_str; - if (!ignore_sybase && PG(magic_quotes_sybase)) { - while (source < end) { - switch (*source) { - case '\0': - *target++ = '\\'; - *target++ = '0'; - break; - case '\'': - *target++ = '\''; - *target++ = '\''; - break; - default: - *target++ = *source; - break; - } - source++; - } - } else { - while (source < end) { - switch (*source) { - case '\0': - *target++ = '\\'; - *target++ = '0'; - break; - case '\'': - case '\"': - case '\\': - *target++ = '\\'; - /* break is missing *intentionally* */ - default: - *target++ = *source; - break; - } - - source++; + while (source < end) { + switch (*source) { + case '\0': + *target++ = '\\'; + *target++ = '0'; + break; + case '\'': + case '\"': + case '\\': + *target++ = '\\'; + /* break is missing *intentionally* */ + default: + *target++ = *source; + break; } + + source++; } *target = 0; diff --git a/ext/standard/tests/file/magic_quotes.phpt b/ext/standard/tests/file/magic_quotes.phpt index 0f42cd7c87925..e69de29bb2d1d 100644 --- a/ext/standard/tests/file/magic_quotes.phpt +++ b/ext/standard/tests/file/magic_quotes.phpt @@ -1,77 +0,0 @@ ---TEST-- -various magic quotes tests ---INI-- -error_reporting=14335 ---FILE-- - ---EXPECTF-- -int(0) -int(0) - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -int(1) - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -int(1) -string(30) "some\'content\'here\"and}there" - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -int(0) -string(27) "some'content'here"and}there" - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -int(1) -string(30) "some\'content\'here\"and}there" - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d - -Warning: set_magic_quotes_runtime() expects exactly 1 parameter, 0 given in %s on line %d -NULL -int(0) -string(27) "some'content'here"and}there" -Done diff --git a/ext/standard/tests/general_functions/get_cfg_var_variation8.phpt b/ext/standard/tests/general_functions/get_cfg_var_variation8.phpt index 7db0d1cc781f2..c7a72de944d04 100644 --- a/ext/standard/tests/general_functions/get_cfg_var_variation8.phpt +++ b/ext/standard/tests/general_functions/get_cfg_var_variation8.phpt @@ -1,20 +1,17 @@ ---TEST-- -Test function get_cfg_var() by calling deprecated option ---CREDITS-- -Francesco Fullone ff@ideato.it -#PHPTestFest Cesena Italia on 2009-06-20 ---INI-- -magic_quotes_gpc=1 ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -Deprecated: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in %s on line 0 -*** Test by calling method or function with deprecated option *** -string(1) "1" - +--TEST-- +Test function get_cfg_var() by calling deprecated option +--CREDITS-- +Francesco Fullone ff@ideato.it +#PHPTestFest Cesena Italia on 2009-06-20 +--INI-- +magic_quotes_gpc=1 +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +Fatal error: Directive 'magic_quotes_gpc' is no longer available in PHP in Unknown on line 0 diff --git a/ext/standard/tests/general_functions/get_magic_quotes_gpc.phpt b/ext/standard/tests/general_functions/get_magic_quotes_gpc.phpt index cfa4dcc6816b9..b1c694a72068e 100644 --- a/ext/standard/tests/general_functions/get_magic_quotes_gpc.phpt +++ b/ext/standard/tests/general_functions/get_magic_quotes_gpc.phpt @@ -1,27 +1,13 @@ --TEST-- Test get_magic_quotes_gpc() function ---INI-- -magic_quotes_gpc = 0 --FILE-- ===DONE=== ---EXPECT-- +--EXPECTF-- Simple testcase for get_magic_quotes_gpc() function --- magic quotes gpc set in INI file: 0 -- - --- Set magic quotes gpc to 1 - not allowed so should fail! -- +Deprecated: Function get_magic_quotes_gpc() is deprecated in %s on line %d bool(false) --- magic quotes gpc after set: 0 -- - --- Set magic quotes gpc to 0: -- -bool(false) +-- Error cases -- --- magic quotes gpc after set: 0 -- +Deprecated: Function get_magic_quotes_gpc() is deprecated in %s on line %d --- Error cases -- -int(0) -===DONE=== \ No newline at end of file +Warning: get_magic_quotes_gpc() expects exactly 0 parameters, 1 given in %s on line %d +NULL +===DONE=== diff --git a/ext/standard/tests/general_functions/get_magic_quotes_runtime.phpt b/ext/standard/tests/general_functions/get_magic_quotes_runtime.phpt index fca064d840573..abcef3577c372 100644 --- a/ext/standard/tests/general_functions/get_magic_quotes_runtime.phpt +++ b/ext/standard/tests/general_functions/get_magic_quotes_runtime.phpt @@ -1,32 +1,14 @@ --TEST-- Test get_magic_quotes_runtime() function ---INI-- -magic_quotes_runtime = 0 --FILE-- -===DONE=== ---EXPECTF-- -Simple testcase for set_magic_quotes_runtime() function -magic quotes runtime set in INI file: 0 --- Iterator 1 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 2 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 3 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 4 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 5 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 6 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 7 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 8 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 9 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 10 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 11 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 12 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 13 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 14 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 15 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 1 --- Iterator 16 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 17 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 18 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 19 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d - -Warning: set_magic_quotes_runtime() expects parameter 1 to be boolean, object given in %s on line %d -NULL -New value of magic_quotes_runtime after last set is 0 --- Iterator 20 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d - -Warning: set_magic_quotes_runtime() expects parameter 1 to be boolean, resource given in %s on line %d -NULL -New value of magic_quotes_runtime after last set is 0 --- Iterator 21 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 --- Iterator 22 -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) -New value of magic_quotes_runtime after last set is 0 -===DONE=== diff --git a/ext/standard/tests/strings/add-and-stripslashes.phpt b/ext/standard/tests/strings/add-and-stripslashes.phpt index a5eab410b907b..6f01176d4e717 100644 --- a/ext/standard/tests/strings/add-and-stripslashes.phpt +++ b/ext/standard/tests/strings/add-and-stripslashes.phpt @@ -1,5 +1,5 @@ --TEST-- -addslashes() and stripslashes() functions, normal and sybase-style +addslashes() and stripslashes() functions --FILE-- --EXPECT-- Normal: OK -Sybase: OK diff --git a/ext/standard/tests/strings/addslashes_variation3.phpt b/ext/standard/tests/strings/addslashes_variation3.phpt index 8f46ebe9a4b14..e69de29bb2d1d 100644 --- a/ext/standard/tests/strings/addslashes_variation3.phpt +++ b/ext/standard/tests/strings/addslashes_variation3.phpt @@ -1,196 +0,0 @@ ---TEST-- -Test addslashes() function : usage variations - with magic_quotes_sybase directive ON ---FILE-- -', - "hello\x00world", - - // heredoc strings - $heredoc_string, - $heredoc_null_string - ); - -$count = 1; -// looping to test for all strings in $str_array -foreach( $str_array as $str ) { - echo "\n-- Iteration $count --\n"; - var_dump( addslashes($str) ); - $count ++; -} - -echo "Done\n"; -?> ---EXPECTF-- -*** Testing addslashes() : with php directive magic_quotes_sybase set ON *** - --- Iteration 1 -- -string(11) "Hello world" - --- Iteration 2 -- -string(18) "how''re you doing?" - --- Iteration 3 -- -string(30) "don''t disturb u''r neighbours" - --- Iteration 4 -- -string(34) "don''t disturb u''r neighbours''''" - --- Iteration 5 -- -string(0) "" - --- Iteration 6 -- -string(2) "''" - --- Iteration 7 -- -string(2) "''" - --- Iteration 8 -- -string(30) "he said, "he will be on leave"" - --- Iteration 9 -- -string(31) "he said, ""he will be on leave"" - --- Iteration 10 -- -string(9) """"PHP"""" - --- Iteration 11 -- -string(0) "" - --- Iteration 12 -- -string(1) """ - --- Iteration 13 -- -string(1) """ - --- Iteration 14 -- -string(6) "hello"" - --- Iteration 15 -- -string(25) "Is your name Ram\Krishna?" - --- Iteration 16 -- -string(8) "\0.0.0.0" - --- Iteration 17 -- -string(26) "c:\php\testcase\addslashes" - --- Iteration 18 -- -string(1) "\" - --- Iteration 19 -- -string(12) "hello\0world" - --- Iteration 20 -- -string(9) "\0hello\0" - --- Iteration 21 -- -string(9) "\0\0hello" - --- Iteration 22 -- -string(2) "\0" - --- Iteration 23 -- -string(12) "''\0.0.0.0''" - --- Iteration 24 -- -string(14) "''\0.0.0.0''\0" - --- Iteration 25 -- -string(13) "\0''c:\php\''" - --- Iteration 26 -- -string(10) ""\0.0.0.0"" - --- Iteration 27 -- -string(13) ""c:\php\"\0''" - --- Iteration 28 -- -string(20) ""hello"''world''\0//" - --- Iteration 29 -- -string(18) "0xABCDEF0123456789" - --- Iteration 30 -- -string(15) "«cdef0123456789" - --- Iteration 31 -- -string(18) "!@#$%&*@$%#&/;:,<>" - --- Iteration 32 -- -string(12) "hello\0world" - --- Iteration 33 -- -string(71) "This is line 1 of ''heredoc'' string -This is line 2 of "heredoc" string" - --- Iteration 34 -- -string(0) "" -Done diff --git a/ext/standard/tests/strings/bug22904.phpt b/ext/standard/tests/strings/bug22904.phpt index 3c56e1a414dc9..e69de29bb2d1d 100644 --- a/ext/standard/tests/strings/bug22904.phpt +++ b/ext/standard/tests/strings/bug22904.phpt @@ -1,30 +0,0 @@ ---TEST-- -Bug #22904 (magic mode failed for cybase with '\0') ---FILE-- -not active yet - ---EXPECT-- -not active yet diff --git a/ext/standard/tests/strings/parse_str_basic3.phpt b/ext/standard/tests/strings/parse_str_basic3.phpt index 06e614374ebb3a3295c5c557709fa2894a3d66ab..f0f5981e8f36336c6cc678e5799f04a6a9b39779 100644 GIT binary patch delta 146 zcmaE^abJCc^~T71oSSEHIk2)?XeucAPkz8}!(|3!85+bG*_uwCz%Md+Kbz2GUjaTP z1E8>@LUBn^W?s5Nd1gt5f>L2=eo1PI5>&7ltbDS7u$l>m(&YTSlElnBkX8l;28F!R UoE(Vq91h{h>p8hL38pgx0Al$rPyhe` delta 242 zcmcbw{#;{%wX~<7r>-tnZen_7a(rQFeo1O^e0o8$f~`V+-bRauoXIY!1x2aJi6yBi zRtheeKxRp1S*n6Mx(0QH%wmNUxLSqGJcR&{00mP$V}-=L6ovGnRG<+>AmPxw?7aN) zJfQgsIhlE>3I<#g-xzN8;^Jpzv(!{j@{gGu$8W=K4rCe{#7thmZy{|2WIHMpmlS2@ tr7M(YmSiZzD1n`t5;OTDzkxDHEvkHSeqKppW*$g=i~$I4b`+S$3;@3+iu%N5cO;L6_bqHy!e8mU(}!M z%<^KAT3YrxD5?aBB+i~WbJ;yZYA~3cexD5n#!MtBBx&qlBmqx6k@Who%t9yiqY$Q$ zCH!2#C69eh-y|@AD?jyM#m{|b{%01YBAF*Q3!VsY{aE0-O95YhGX{fCUw%DB2S+Ct z-i0yTfwMSDqx9xN0OFFz@Vwy|dgZs z&jUXpcn+S3g&R3#F1L%%^P)({aCCHZ`gLZ^JU;>a8~CAs5kyNc3sbXP+b|iE2`fxk zX@W?|qH+>uK~Q-r97z+P95k3x779*0j`@v2jWU;S;TYuqJupD=qHN|JM@5dZ6r1P< z9FND`NkyDsf_VxKcGg0`f;)fYo559rnV&@vL~s?wfotv>_wfjn=|DifVU(!Mi>}OA zz)h5a8=?6LmP~EwMxmKvKP9*y7Lb`Sgu*}f7PtWthJ+L^cGnuy>{w+|c#4;4cU@s! zP)eL;SupHuad(oi-yq?>i_MJhuKXaNg5gOO2!1J87v0-c4_d|;!{Y$|?Z9OnX=8TR z6;nbzc|tiwD%eJyrZVmK$y(K}wSHEvGruI%UDz#rCEy!h*}ueo;)VRABR)QTlIH8#n$&#xh0bp5w(mtG{PfTTaoFrA=drx_t}N=8C&a zy8~MJ*P;}mL>V=+ZJU|ap8V6bJ6c9Xz;{vFV`X)^FilpJk5vim+?{6LjA+S&t41Nn&VC9aNXI(yd%i)FrBnYT~AF zN@~3AL|K@ke2orC?}8}0AW=>upj`*cC@dLmowMGU~&|0+z-jGOmp~th_Lps8H%Dl@%$?*KwKz z$JzwnAP<_HTBB3x_@O)x3b^JV)=K9@m+iztc$&l-<6Con(_}uTMBFvxu~rbTw1arH zF$fc1x~)>>sB6L{=w|o4)(wTqq02L0+a$8DOJs~h^ixKgbS)_d|06DMbh*f8xSifr zGrw;A?giZ}?_2FKs6w}4(A%|p7wtIih20EfWa&oomUc{eTck_51=8ZCEml8zH;?pH zNoGm&B&T}fsnp7fw&oOYrTRZmx0PJ9rDGrAAWk_2E#;=i9=e@CRlW#(8 zvDcRl68^hx)U^ZH4BU!ATXLvJZC#$l;uaTe$r+Ir%Ox`%ZaT#K*1tk8D)r}b!4m#h-2#Z+5eMwE*6r>okH&;{4zJJHsh|4gta+TwFS r`?m4ZX#VSI_4DZiem~W%!#+(73Jwqd1-HG4C)zsr_&YXwoND|F(hAR< diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index 129f687bd176b..c07cdcd7e626c 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -1814,11 +1814,7 @@ static void php_sybase_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, int numerics) ALLOC_ZVAL(tmp); *tmp = result->data[result->store ? result->cur_row : 0][i]; INIT_PZVAL(tmp); - if (PG(magic_quotes_runtime) && Z_TYPE_P(tmp) == IS_STRING) { - Z_STRVAL_P(tmp) = php_addslashes(Z_STRVAL_P(tmp), Z_STRLEN_P(tmp), &Z_STRLEN_P(tmp), 0 TSRMLS_CC); - } else { - zval_copy_ctor(tmp); - } + zval_copy_ctor(tmp); if (numerics) { zend_hash_index_update(Z_ARRVAL_P(return_value), i, (void *) &tmp, sizeof(zval *), NULL); Z_ADDREF_P(tmp); diff --git a/ext/sysvsem/tests/sysv.phpt b/ext/sysvsem/tests/sysv.phpt index 4245d8ef0c4ab..3a962be31a41e 100644 --- a/ext/sysvsem/tests/sysv.phpt +++ b/ext/sysvsem/tests/sysv.phpt @@ -6,8 +6,6 @@ if(!extension_loaded('sysvsem') || !extension_loaded('sysvshm')) { die("skip Both sysvsem and sysvshm required"); } ?> ---INI-- -magic_quotes_runtime=0 --FILE-- ---INI-- -magic_quotes_runtime=0 --FILE-- ---INI-- -magic_quotes_runtime=0 --FILE-- ---INI-- -magic_quotes_runtime=0 --FILE-- ---INI-- -magic_quotes_runtime=0 --FILE-- ---INI-- -magic_quotes_runtime=0 --FILE-- --EXPECTF-- @@ -66,24 +63,4 @@ array(6) { string(39) "and I know that it descends down on me " } -array(6) { - [0]=> - string(37) "When you\'re taught through feelings -" - [1]=> - string(26) "Destiny flying high above -" - [2]=> - string(38) "all I know is that you can realize it -" - [3]=> - string(18) "Destiny who cares -" - [4]=> - string(19) "as it turns around -" - [5]=> - string(39) "and I know that it descends down on me -" -} Done diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 08450a3aa33af..0f61bfde91a69 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -426,7 +426,7 @@ static PHP_FUNCTION(gzfile) char *filename; int filename_len; int flags = REPORT_ERRORS; - char *slashed, buf[8192] = {0}; + char buf[8192] = {0}; register int i = 0; long use_include_path = 0; php_stream *stream; @@ -454,14 +454,7 @@ static PHP_FUNCTION(gzfile) memset(buf, 0, sizeof(buf)); while (php_stream_gets(stream, buf, sizeof(buf) - 1) != NULL) { - if (PG(magic_quotes_runtime)) { - int len; - - slashed = php_addslashes(buf, 0, &len, 0 TSRMLS_CC); /* 0 = don't free source string */ - add_index_stringl(return_value, i++, slashed, len, 0); - } else { - add_index_string(return_value, i++, buf, 1); - } + add_index_string(return_value, i++, buf, 1); } php_stream_close(stream); } diff --git a/main/main.c b/main/main.c index f02720130fbc6..f6b90314394e3 100644 --- a/main/main.c +++ b/main/main.c @@ -440,9 +440,6 @@ PHP_INI_BEGIN() STD_PHP_INI_BOOLEAN("ignore_repeated_source", "0", PHP_INI_ALL, OnUpdateBool, ignore_repeated_source, php_core_globals, core_globals) STD_PHP_INI_BOOLEAN("report_memleaks", "1", PHP_INI_ALL, OnUpdateBool, report_memleaks, php_core_globals, core_globals) STD_PHP_INI_BOOLEAN("report_zend_debug", "1", PHP_INI_ALL, OnUpdateBool, report_zend_debug, php_core_globals, core_globals) - STD_PHP_INI_BOOLEAN("magic_quotes_gpc", "1", PHP_INI_PERDIR|PHP_INI_SYSTEM, OnUpdateBool, magic_quotes_gpc, php_core_globals, core_globals) - STD_PHP_INI_BOOLEAN("magic_quotes_runtime", "0", PHP_INI_ALL, OnUpdateBool, magic_quotes_runtime, php_core_globals, core_globals) - STD_PHP_INI_BOOLEAN("magic_quotes_sybase", "0", PHP_INI_ALL, OnUpdateBool, magic_quotes_sybase, php_core_globals, core_globals) STD_PHP_INI_ENTRY("output_buffering", "0", PHP_INI_PERDIR|PHP_INI_SYSTEM, OnUpdateLong, output_buffering, php_core_globals, core_globals) STD_PHP_INI_ENTRY("output_handler", NULL, PHP_INI_PERDIR|PHP_INI_SYSTEM, OnUpdateString, output_handler, php_core_globals, core_globals) STD_PHP_INI_BOOLEAN("register_argc_argv", "1", PHP_INI_PERDIR|PHP_INI_SYSTEM, OnUpdateBool, register_argc_argv, php_core_globals, core_globals) @@ -2153,15 +2150,12 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod struct { const long error_level; const char *phrase; - const char *directives[13]; /* Remember to change this if the number of directives change */ + const char *directives[16]; /* Remember to change this if the number of directives change */ } directives[2] = { { E_DEPRECATED, "Directive '%s' is deprecated in PHP 5.3 and greater", { - "magic_quotes_gpc", - "magic_quotes_runtime", - "magic_quotes_sybase", NULL } }, @@ -2172,6 +2166,9 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod "allow_call_time_pass_reference", "define_syslog_variables", "highlight.bg", + "magic_quotes_gpc", + "magic_quotes_runtime", + "magic_quotes_sybase", "register_globals", "register_long_arrays", "safe_mode", diff --git a/main/php_globals.h b/main/php_globals.h index 0ce398aafc3e8..bf6674d54b8ea 100644 --- a/main/php_globals.h +++ b/main/php_globals.h @@ -54,10 +54,6 @@ typedef struct _arg_separators { } arg_separators; struct _php_core_globals { - zend_bool magic_quotes_gpc; - zend_bool magic_quotes_runtime; - zend_bool magic_quotes_sybase; - zend_bool implicit_flush; long output_buffering; diff --git a/main/php_variables.c b/main/php_variables.c index f6dde71417a37..8bd1b01c334b2 100644 --- a/main/php_variables.c +++ b/main/php_variables.c @@ -47,11 +47,7 @@ PHPAPI void php_register_variable_safe(char *var, char *strval, int str_len, zva /* Prepare value */ Z_STRLEN(new_entry) = str_len; - if (PG(magic_quotes_gpc)) { - Z_STRVAL(new_entry) = php_addslashes(strval, Z_STRLEN(new_entry), &Z_STRLEN(new_entry), 0 TSRMLS_CC); - } else { - Z_STRVAL(new_entry) = estrndup(strval, Z_STRLEN(new_entry)); - } + Z_STRVAL(new_entry) = estrndup(strval, Z_STRLEN(new_entry)); Z_TYPE(new_entry) = IS_STRING; php_register_variable_ex(var, &new_entry, track_vars_array TSRMLS_CC); @@ -180,11 +176,7 @@ PHPAPI void php_register_variable_ex(char *var_name, zval *val, zval *track_vars array_init(gpc_element); zend_hash_next_index_insert(symtable1, &gpc_element, sizeof(zval *), (void **) &gpc_element_p); } else { - if (PG(magic_quotes_gpc)) { - escaped_index = php_addslashes(index, index_len, &index_len, 0 TSRMLS_CC); - } else { - escaped_index = index; - } + escaped_index = index; if (zend_symtable_find(symtable1, escaped_index, index_len + 1, (void **) &gpc_element_p) == FAILURE || Z_TYPE_PP(gpc_element_p) != IS_ARRAY) { MAKE_STD_ZVAL(gpc_element); @@ -216,11 +208,7 @@ PHPAPI void php_register_variable_ex(char *var_name, zval *val, zval *track_vars if (!index) { zend_hash_next_index_insert(symtable1, &gpc_element, sizeof(zval *), (void **) &gpc_element_p); } else { - if (PG(magic_quotes_gpc)) { - escaped_index = php_addslashes(index, index_len, &index_len, 0 TSRMLS_CC); - } else { - escaped_index = index; - } + escaped_index = index; /* * According to rfc2965, more specific paths are listed above the less specific ones. * If we encounter a duplicate cookie name, we should skip it, since it is not possible @@ -425,10 +413,6 @@ void _php_import_environment_variables(zval *array_ptr TSRMLS_DC) size_t alloc_size = sizeof(buf); unsigned long nlen; /* ptrdiff_t is not portable */ - /* turn off magic_quotes while importing environment variables */ - int magic_quotes_gpc = PG(magic_quotes_gpc); - PG(magic_quotes_gpc) = 0; - for (env = environ; env != NULL && *env != NULL; env++) { p = strchr(*env, '='); if (!p) { /* malformed entry? */ @@ -446,7 +430,6 @@ void _php_import_environment_variables(zval *array_ptr TSRMLS_DC) if (t != buf && t != NULL) { efree(t); } - PG(magic_quotes_gpc) = magic_quotes_gpc; } zend_bool php_std_auto_global_callback(char *name, uint name_len TSRMLS_DC) @@ -560,8 +543,6 @@ PHPAPI int php_handle_special_queries(TSRMLS_D) static inline void php_register_server_variables(TSRMLS_D) { zval *array_ptr = NULL; - /* turn off magic_quotes while importing server variables */ - int magic_quotes_gpc = PG(magic_quotes_gpc); ALLOC_ZVAL(array_ptr); array_init(array_ptr); @@ -570,7 +551,6 @@ static inline void php_register_server_variables(TSRMLS_D) zval_ptr_dtor(&PG(http_globals)[TRACK_VARS_SERVER]); } PG(http_globals)[TRACK_VARS_SERVER] = array_ptr; - PG(magic_quotes_gpc) = 0; /* Server variables */ if (sapi_module.register_server_variables) { @@ -595,7 +575,6 @@ static inline void php_register_server_variables(TSRMLS_D) php_register_variable_ex("REQUEST_TIME", &new_entry, array_ptr TSRMLS_CC); } - PG(magic_quotes_gpc) = magic_quotes_gpc; } /* }}} */ diff --git a/main/rfc1867.c b/main/rfc1867.c index 4467aaff160e8..f6dfae997bdcf 100644 --- a/main/rfc1867.c +++ b/main/rfc1867.c @@ -1119,15 +1119,6 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler) /* {{{ */ * the user does basename() they get a bogus file name. Until IE's user base drops * to nill or problem is fixed this code must remain enabled for all systems. */ s = _basename(internal_encoding, filename TSRMLS_CC); -#ifdef PHP_WIN32 - if (PG(magic_quotes_gpc)) { - s = s ? s : filename; - tmp = strrchr(s, '\''); - s = tmp >= s ? tmp + 1: s; - tmp = strrchr(s, '"'); - s = tmp >= s ? tmp + 1: s; - } -#endif if (!s) { s = filename; } @@ -1182,7 +1173,7 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler) /* {{{ */ s = ""; { - /* store temp_filename as-is (without magic_quotes_gpc-ing it, in case upload_tmp_dir + /* store temp_filename as-is (in case upload_tmp_dir * contains escapeable characters. escape only the variable name.) */ zval zfilename; diff --git a/php.ini-development b/php.ini-development index 92185959f7232..4a1eb4f01764b 100644 --- a/php.ini-development +++ b/php.ini-development @@ -116,11 +116,6 @@ ; Development Value: On ; Production Value: On -; magic_quotes_gpc -; Default Value: On -; Development Value: Off -; Production Value: Off - ; max_input_time ; Default Value: -1 (Unlimited) ; Development Value: 60 (60 seconds) @@ -663,30 +658,6 @@ auto_globals_jit = On ; http://php.net/post-max-size post_max_size = 8M -; Magic quotes are a preprocessing feature of PHP where PHP will attempt to -; escape any character sequences in GET, POST, COOKIE and ENV data which might -; otherwise corrupt data being placed in resources such as databases before -; making that data available to you. Because of character encoding issues and -; non-standard SQL implementations across many databases, it's not currently -; possible for this feature to be 100% accurate. PHP's default behavior is to -; enable the feature. We strongly recommend you use the escaping mechanisms -; designed specifically for the database your using instead of relying on this -; feature. Also note, this feature has been deprecated as of PHP 5.3.0 and is -; scheduled for removal in PHP 6. -; Default Value: On -; Development Value: Off -; Production Value: Off -; http://php.net/magic-quotes-gpc -magic_quotes_gpc = Off - -; Magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc. -; http://php.net/magic-quotes-runtime -magic_quotes_runtime = Off - -; Use Sybase-style magic quotes (escape ' with '' instead of \'). -; http://php.net/magic-quotes-sybase -magic_quotes_sybase = Off - ; Automatically add files before PHP document. ; http://php.net/auto-prepend-file auto_prepend_file = diff --git a/php.ini-production b/php.ini-production index 576cf41479778..ab7b266440be2 100644 --- a/php.ini-production +++ b/php.ini-production @@ -116,11 +116,6 @@ ; Development Value: On ; Production Value: On -; magic_quotes_gpc -; Default Value: On -; Development Value: Off -; Production Value: Off - ; max_input_time ; Default Value: -1 (Unlimited) ; Development Value: 60 (60 seconds) @@ -663,30 +658,6 @@ auto_globals_jit = On ; http://php.net/post-max-size post_max_size = 8M -; Magic quotes are a preprocessing feature of PHP where PHP will attempt to -; escape any character sequences in GET, POST, COOKIE and ENV data which might -; otherwise corrupt data being placed in resources such as databases before -; making that data available to you. Because of character encoding issues and -; non-standard SQL implementations across many databases, it's not currently -; possible for this feature to be 100% accurate. PHP's default behavior is to -; enable the feature. We strongly recommend you use the escaping mechanisms -; designed specifically for the database your using instead of relying on this -; feature. Also note, this feature has been deprecated as of PHP 5.3.0 and is -; scheduled for removal in PHP 6. -; Default Value: On -; Development Value: Off -; Production Value: Off -; http://php.net/magic-quotes-gpc -magic_quotes_gpc = Off - -; Magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc. -; http://php.net/magic-quotes-runtime -magic_quotes_runtime = Off - -; Use Sybase-style magic quotes (escape ' with '' instead of \'). -; http://php.net/magic-quotes-sybase -magic_quotes_sybase = Off - ; Automatically add files before PHP document. ; http://php.net/auto-prepend-file auto_prepend_file = diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index 01c417bef267f..b19d501ba247f 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -648,12 +648,7 @@ static void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) if (fcgi_is_fastcgi()) { fcgi_request *request = (fcgi_request*) SG(server_context); - int magic_quotes_gpc = PG(magic_quotes_gpc); - - /* turn off magic_quotes while importing environment variables */ - PG(magic_quotes_gpc) = 0; fcgi_loadenv(request, cgi_php_load_env_var, array_ptr TSRMLS_CC); - PG(magic_quotes_gpc) = magic_quotes_gpc; } } diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 773cf2cf6d58a..f9c15ba7e2f80 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -524,7 +524,6 @@ void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) { fcgi_request *request; HashPosition pos; - int magic_quotes_gpc;; char *var, **val; uint var_len; ulong idx; @@ -557,11 +556,8 @@ void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) php_php_import_environment_variables(array_ptr TSRMLS_CC); request = (fcgi_request*) SG(server_context); - magic_quotes_gpc = PG(magic_quotes_gpc); filter_arg = (array_ptr == PG(http_globals)[TRACK_VARS_ENV])?PARSE_ENV:PARSE_SERVER; - /* turn off magic_quotes while importing environment variables */ - PG(magic_quotes_gpc) = 0; for (zend_hash_internal_pointer_reset_ex(request->env, &pos); zend_hash_get_current_key_ex(request->env, &var, &var_len, &idx, 0, &pos) == HASH_KEY_IS_STRING && zend_hash_get_current_data_ex(request->env, (void **) &val, &pos) == SUCCESS; @@ -573,7 +569,6 @@ void cgi_php_import_environment_variables(zval *array_ptr TSRMLS_DC) php_register_variable_safe(var, *val, new_val_len, array_ptr TSRMLS_CC); } } - PG(magic_quotes_gpc) = magic_quotes_gpc; } static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC) diff --git a/tests/basic/023.phpt b/tests/basic/023.phpt index 4eb698fa05b70..181745ea5b693 100644 --- a/tests/basic/023.phpt +++ b/tests/basic/023.phpt @@ -1,7 +1,5 @@ --TEST-- Cookies test#2 ---INI-- -magic_quotes_gpc=0 --COOKIE-- c o o k i e=value; c o o k i e= v a l u e ;;c%20o+o k+i%20e=v;name="value","value",UEhQIQ==;UEhQIQ==foo --FILE-- diff --git a/tests/basic/024.phpt b/tests/basic/024.phpt index 847eeac824f89..497d3514e0e29 100644 --- a/tests/basic/024.phpt +++ b/tests/basic/024.phpt @@ -1,7 +1,6 @@ --TEST-- Test HTTP_RAW_POST_DATA creation --INI-- -magic_quotes_gpc=0 always_populate_raw_post_data=1 --POST-- a=ABC&y=XYZ&c[]=1&c[]=2&c[a]=3 diff --git a/tests/basic/025.phpt b/tests/basic/025.phpt index bafcac8091a46..58191bcd61daf 100644 --- a/tests/basic/025.phpt +++ b/tests/basic/025.phpt @@ -1,7 +1,6 @@ --TEST-- Test HTTP_RAW_POST_DATA with excessive post length --INI-- -magic_quotes_gpc=0 always_populate_raw_post_data=1 post_max_size=1K --POST-- diff --git a/tests/basic/026.phpt b/tests/basic/026.phpt index 957aa1972cb41..b98a31f430772 100644 --- a/tests/basic/026.phpt +++ b/tests/basic/026.phpt @@ -1,7 +1,6 @@ --TEST-- Registration of HTTP_RAW_POST_DATA due to unknown content-type --INI-- -magic_quotes_gpc=0 always_populate_raw_post_data=0 --POST_RAW-- Content-Type: unknown/type diff --git a/tests/basic/027.phpt b/tests/basic/027.phpt index ae5d78d50dd98..aa001f65a37ed 100644 --- a/tests/basic/027.phpt +++ b/tests/basic/027.phpt @@ -1,7 +1,6 @@ --TEST-- Handling of max_input_nesting_level being reached --INI-- -magic_quotes_gpc=0 always_populate_raw_post_data=0 display_errors=0 max_input_nesting_level=10 diff --git a/tests/basic/bug46313-win.phpt b/tests/basic/bug46313-win.phpt index 457e5eb7b3ed4..e588bec767a53 100644 --- a/tests/basic/bug46313-win.phpt +++ b/tests/basic/bug46313-win.phpt @@ -1,3 +1,68 @@ +--TEST-- +Bug #46313 (Magic quotes broke $_FILES) +--SKIPIF-- + +--INI-- +magic_quotes_gpc=1 +file_uploads=1 +register_globals=1 +--POST_RAW-- +Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737 +-----------------------------20896060251896012921717172737 +Content-Disposition: form-data; name="o1'file"; filename="o1'file.png" +Content-Type: text/plain-file1 + +1 +-----------------------------20896060251896012921717172737 +Content-Disposition: form-data; name="o2'file"; filename="o2'file2.txt" +Content-Type: text/plain-file2 + +2 +-----------------------------20896060251896012921717172737-- +--FILE-- + +--EXPECTF-- +array(2) { + ["o1\'file"]=> + array(5) { + ["name"]=> + string(12) "o1" + ["type"]=> + string(16) "text/plain-file1" + ["tmp_name"]=> + string(14) "%s" + ["error"]=> + int(0) + ["size"]=> + int(1) + } + ["o2\'file"]=> + array(5) { + ["name"]=> + string(13) "o2" + ["type"]=> + string(16) "text/plain-file2" + ["tmp_name"]=> + string(14) "%s" + ["error"]=> + int(0) + ["size"]=> + int(1) + } +} +string(12) "o1" +bool(true) +string(%d) "%s" +bool(true) +Warning: Directive 'register_globals' is deprecated in PHP 5.3 and greater in Unknown on line 0 +Warning: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in Unknown on line 0 + --TEST-- Bug #46313 (Magic quotes broke $_FILES) --SKIPIF-- diff --git a/tests/basic/bug46313.phpt b/tests/basic/bug46313.phpt index 6c1f65c935c2c..e69de29bb2d1d 100644 --- a/tests/basic/bug46313.phpt +++ b/tests/basic/bug46313.phpt @@ -1,54 +0,0 @@ ---TEST-- -Bug #46313 (Magic quotes broke $_FILES) ---SKIPIF-- - ---INI-- -magic_quotes_gpc=1 -file_uploads=1 -display_errors=0 ---POST_RAW-- -Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737 ------------------------------20896060251896012921717172737 -Content-Disposition: form-data; name="o1'file"; filename="o1'file.png" -Content-Type: text/plain-file1 - -1 ------------------------------20896060251896012921717172737 -Content-Disposition: form-data; name="o2'file"; filename="o2'file2.txt" -Content-Type: text/plain-file2 - -2 ------------------------------20896060251896012921717172737-- ---FILE-- - ---EXPECTF-- -array(2) { - ["o1\'file"]=> - array(5) { - ["name"]=> - string(12) "o1\'file.png" - ["type"]=> - string(16) "text/plain-file1" - ["tmp_name"]=> - string(%d) "%s" - ["error"]=> - int(0) - ["size"]=> - int(1) - } - ["o2\'file"]=> - array(5) { - ["name"]=> - string(13) "o2\'file2.txt" - ["type"]=> - string(16) "text/plain-file2" - ["tmp_name"]=> - string(%d) "%s" - ["error"]=> - int(0) - ["size"]=> - int(1) - } -} diff --git a/tests/basic/bug46759.phpt b/tests/basic/bug46759.phpt index d35cd534c2cc3..e69de29bb2d1d 100644 --- a/tests/basic/bug46759.phpt +++ b/tests/basic/bug46759.phpt @@ -1,20 +0,0 @@ ---TEST-- -Testing magic_quotes_gpc ---INI-- -display_errors=0 -magic_quotes_gpc=1 ---GET-- -a='&b="&c=\" ---FILE-- - $value) -{ - echo $key . ": " . $value . "\n"; -} - -?> ---EXPECT-- -a: \' -b: \" -c: \\\" diff --git a/tests/security/magic_quotes_gpc.phpt b/tests/security/magic_quotes_gpc.phpt index 382ab94d2d176..e69de29bb2d1d 100644 --- a/tests/security/magic_quotes_gpc.phpt +++ b/tests/security/magic_quotes_gpc.phpt @@ -1,13 +0,0 @@ ---TEST-- -Test if magic_quotes_gpc works as expected ---INI-- -display_errors=0 -magic_quotes_gpc=1 ---GET-- -a=abc'"%00123 ---FILE-- - ---EXPECT-- -abc\'\"\0123 diff --git a/win32/build/config.w32.h.in b/win32/build/config.w32.h.in index 9d885667f0abe..13b36fad1cc58 100644 --- a/win32/build/config.w32.h.in +++ b/win32/build/config.w32.h.in @@ -33,7 +33,6 @@ /* PHP Runtime Configuration */ #define PHP_URL_FOPEN 1 -#define MAGIC_QUOTES 0 #define USE_CONFIG_FILE 1 #define DEFAULT_SHORT_OPEN_TAG "1" diff --git a/win32/syslog.reg b/win32/syslog.reg index 4d3e273970f91..cb12d6e6b9743 100644 --- a/win32/syslog.reg +++ b/win32/syslog.reg @@ -2,4 +2,4 @@ REGEDIT4 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\Application\PHP-5.3.99-dev] "TypesSupported"=dword:00000007 -"EventMessageFile"="g:\\test\\srcinstall6\\php5ts_debug.dll" +"EventMessageFile"="g:\\test\\srctrunkinstall\\php5ts.dll" From ebe8f32891c6ad83ee7183264e7aacf1f402c5f8 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 22 Jul 2011 11:26:23 +0000 Subject: [PATCH 0362/2394] - WS --- ext/mysqli/mysqli.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index b784ff863f76f..a0815ea8bd128 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -1143,11 +1143,11 @@ void php_mysqli_fetch_into_hash_aux(zval *return_value, MYSQL_RES * result, long Z_TYPE_P(res) = IS_STRING; Z_STRVAL_P(res) = php_addslashes(row[i], field_len[i], &Z_STRLEN_P(res), 0 TSRMLS_CC); } else { -#endif +#endif ZVAL_STRINGL(res, row[i], field_len[i], 1); #if PHP_API_VERSION < 20100412 } -#endif +#endif } if (fetchtype & MYSQLI_NUM) { From f169f6f4786e19e45c318f09fb5cc87c21a7050b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 22 Jul 2011 11:42:15 +0000 Subject: [PATCH 0363/2394] - should not have been applied --- Zend/zend_float.c | 2 +- Zend/zend_operators.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Zend/zend_float.c b/Zend/zend_float.c index 9e9f7bb651ef7..db8d000dd4a6f 100644 --- a/Zend/zend_float.c +++ b/Zend/zend_float.c @@ -31,7 +31,7 @@ ZEND_API void zend_init_fpu(TSRMLS_D) /* {{{ */ EG(saved_fpu_cw_ptr) = (void*)&EG(saved_fpu_cw); } XPFPA_STORE_CW(EG(saved_fpu_cw_ptr)); -// XPFPA_SWITCH_DOUBLE(); + XPFPA_SWITCH_DOUBLE(); #else EG(saved_fpu_cw_ptr) = NULL; #endif diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index e599ca4971d8d..8e3a37eee75ff 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -474,6 +474,7 @@ static zend_always_inline int fast_increment_function(zval *op1) "0:" : : "r"(op1)); +#else if (UNEXPECTED(Z_LVAL_P(op1) == LONG_MAX)) { /* switch to double */ Z_DVAL_P(op1) = (double)LONG_MAX + 1.0; From fb5da94c1bdb1cf69d0ba77fb372b84724339d98 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Fri, 22 Jul 2011 12:12:05 +0000 Subject: [PATCH 0364/2394] Delete empty test files (old MQ tests) --- ext/exif/tests/exif006.phpt | 0 ext/filter/tests/bug39763.phpt | 0 ext/pcre/tests/bug33200.phpt | 0 ext/spl/tests/SplFileObject_fwrite_variation_003.phpt | 0 ext/standard/tests/file/magic_quotes.phpt | 0 .../general_functions/set_magic_quotes_runtime_variation1.phpt | 0 ext/standard/tests/strings/addslashes_variation3.phpt | 0 ext/standard/tests/strings/bug22904.phpt | 0 ext/standard/tests/strings/stripslashes_variation5.phpt | 0 tests/basic/bug46313.phpt | 0 tests/basic/bug46759.phpt | 0 tests/security/magic_quotes_gpc.phpt | 0 12 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 ext/exif/tests/exif006.phpt delete mode 100644 ext/filter/tests/bug39763.phpt delete mode 100644 ext/pcre/tests/bug33200.phpt delete mode 100644 ext/spl/tests/SplFileObject_fwrite_variation_003.phpt delete mode 100644 ext/standard/tests/file/magic_quotes.phpt delete mode 100644 ext/standard/tests/general_functions/set_magic_quotes_runtime_variation1.phpt delete mode 100644 ext/standard/tests/strings/addslashes_variation3.phpt delete mode 100644 ext/standard/tests/strings/bug22904.phpt delete mode 100644 ext/standard/tests/strings/stripslashes_variation5.phpt delete mode 100644 tests/basic/bug46313.phpt delete mode 100644 tests/basic/bug46759.phpt delete mode 100644 tests/security/magic_quotes_gpc.phpt diff --git a/ext/exif/tests/exif006.phpt b/ext/exif/tests/exif006.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/filter/tests/bug39763.phpt b/ext/filter/tests/bug39763.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/pcre/tests/bug33200.phpt b/ext/pcre/tests/bug33200.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/spl/tests/SplFileObject_fwrite_variation_003.phpt b/ext/spl/tests/SplFileObject_fwrite_variation_003.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/standard/tests/file/magic_quotes.phpt b/ext/standard/tests/file/magic_quotes.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/standard/tests/general_functions/set_magic_quotes_runtime_variation1.phpt b/ext/standard/tests/general_functions/set_magic_quotes_runtime_variation1.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/standard/tests/strings/addslashes_variation3.phpt b/ext/standard/tests/strings/addslashes_variation3.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/standard/tests/strings/bug22904.phpt b/ext/standard/tests/strings/bug22904.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/ext/standard/tests/strings/stripslashes_variation5.phpt b/ext/standard/tests/strings/stripslashes_variation5.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/tests/basic/bug46313.phpt b/tests/basic/bug46313.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/tests/basic/bug46759.phpt b/tests/basic/bug46759.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/tests/security/magic_quotes_gpc.phpt b/tests/security/magic_quotes_gpc.phpt deleted file mode 100644 index e69de29bb2d1d..0000000000000 From b2558d5f358e4672aa934b728d1d746678cc54e2 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 23 Jul 2011 01:08:24 +0000 Subject: [PATCH 0365/2394] - Disable __sync_fetch_and_add for HPUX for now, gcc seems not provide __sync_fetch_and_add_4 for all targets --- ext/standard/php_crypt_r.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index 69c48610f3895..e8b482ab6b7d8 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -94,7 +94,7 @@ void _crypt_extended_init_r(void) if (!initialized) { #ifdef PHP_WIN32 InterlockedIncrement(&initialized); -#elif (defined(__GNUC__) && (__GNUC__ > 4 || \ +#elif (defined(__GNUC__) && !defined(__hpux) && (__GNUC__ > 4 || \ (__GNUC__ == 4 && (__GNUC_MINOR__ > 1 || (__GNUC_MINOR__ == 1 && __GNUC_PATCHLEVEL__ > 1))))) __sync_fetch_and_add(&initialized, 1); #elif defined(HAVE_ATOMIC_H) /* Solaris 10 defines atomic API within */ From 39988d126332f236bbd1b3e5b73af65bede531df Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Sat, 23 Jul 2011 01:29:44 +0000 Subject: [PATCH 0366/2394] When we have a blocking SSL socket, respect the timeout option. reading from SSL sockets could block indefinitely due to the lack of timeout --- ext/openssl/xp_ssl.c | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c index e4b101ef6adcf..4b530408eb9e2 100644 --- a/ext/openssl/xp_ssl.c +++ b/ext/openssl/xp_ssl.c @@ -204,6 +204,36 @@ static size_t php_openssl_sockop_write(php_stream *stream, const char *buf, size return didwrite; } +static void php_openssl_stream_wait_for_data(php_stream *stream, php_netstream_data_t *sock TSRMLS_DC) +{ + int retval; + struct timeval *ptimeout; + + if (sock->socket == -1) { + return; + } + + sock->timeout_event = 0; + + if (sock->timeout.tv_sec == -1) + ptimeout = NULL; + else + ptimeout = &sock->timeout; + + while(1) { + retval = php_pollfd_for(sock->socket, PHP_POLLREADABLE, ptimeout); + + if (retval == 0) + sock->timeout_event = 1; + + if (retval >= 0) + break; + + if (php_socket_errno() != EINTR) + break; + } +} + static size_t php_openssl_sockop_read(php_stream *stream, char *buf, size_t count TSRMLS_DC) { php_openssl_netstream_data_t *sslsock = (php_openssl_netstream_data_t*)stream->abstract; @@ -213,6 +243,13 @@ static size_t php_openssl_sockop_read(php_stream *stream, char *buf, size_t coun int retry = 1; do { + if (sslsock->s.is_blocked) { + php_openssl_stream_wait_for_data(stream, &(sslsock->s) TSRMLS_CC); + if (sslsock->s.timeout_event) { + break; + } + /* there is no guarantee that there is application data available but something is there */ + } nr_bytes = SSL_read(sslsock->ssl_handle, buf, count); if (nr_bytes <= 0) { From 1ed2f1cf5dea994a68d4c1a29bedbe5d9b0e165e Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 23 Jul 2011 07:40:40 +0000 Subject: [PATCH 0367/2394] provide backwards compatibility for 'p' in zend_parse_parameters() --- ext/snmp/snmp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index fe6e56736afe2..4f26889c397db 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -1683,7 +1683,11 @@ PHP_FUNCTION(snmp_read_mib) char *filename; int filename_len; +#if PHP_VERSION_ID < 50399 + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &filename, &filename_len) == FAILURE) { +#else if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) { +#endif RETURN_FALSE; } From c724b2eeb1c1192faab05cad70b370c262dd9c5a Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Sat, 23 Jul 2011 11:29:26 +0000 Subject: [PATCH 0368/2394] - Give index.php a precedence over index.html. Patch by davidc. --- sapi/cli/php_cli_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index b33c8b0eb7a6c..7b549cea7e1f5 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1065,7 +1065,7 @@ static void php_cli_server_request_dtor(php_cli_server_request *req) /* {{{ */ static void php_cli_server_request_translate_vpath(php_cli_server_request *request, const char *document_root, size_t document_root_len) /* {{{ */ { struct stat sb; - static const char *index_files[] = { "index.html", "index.php", NULL }; + static const char *index_files[] = { "index.php", "index.html", NULL }; char *buf = safe_pemalloc(1, request->vpath_len, 1 + document_root_len + 1 + sizeof("index.html"), 1); char *p = buf, *prev_patch = 0, *q, *vpath; memmove(p, document_root, document_root_len); From f295302af66efd30a6a8ca72be7872a4696ce5b9 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sat, 23 Jul 2011 13:48:07 +0000 Subject: [PATCH 0369/2394] Fixed bug in the handling of conflicting property initializers for traits. # Bug was uncovered by discussion in http://news.php.net/php.internals/54129 # Forgot to check the actual value of the initializer comparison, only checked # whether comparison was successful which is not enough. --- ...ding-conflicting-property-initializer.phpt | 23 +++++++++++++++++++ Zend/zend_compile.c | 14 ++++++----- 2 files changed, 31 insertions(+), 6 deletions(-) create mode 100644 Zend/tests/traits/bugs/overridding-conflicting-property-initializer.phpt diff --git a/Zend/tests/traits/bugs/overridding-conflicting-property-initializer.phpt b/Zend/tests/traits/bugs/overridding-conflicting-property-initializer.phpt new file mode 100644 index 0000000000000..1b9d98dac0cab --- /dev/null +++ b/Zend/tests/traits/bugs/overridding-conflicting-property-initializer.phpt @@ -0,0 +1,23 @@ +--TEST-- +Properties are considered incompatible if they are different in any of their +defined characteristics. Thus, initialization values have to be equal, too. +--FILE-- +zoo, "\n"; +?> +--EXPECTF-- +Fatal error: baz and foo define the same property ($zoo) in the composition of baz. However, the definition differs and is considered incompatible. Class was composed in %s on line %d \ No newline at end of file diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 06bdf36fea128..0069f3f44ec09 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3919,13 +3919,15 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { if ((coliding_prop->flags & ZEND_ACC_PPP_MASK) == (property_info->flags & ZEND_ACC_PPP_MASK)) { /* flags are identical, now the value needs to be checked */ if (property_info->flags & ZEND_ACC_STATIC) { - not_compatible = compare_function(&compare_result, - ce->default_static_members_table[coliding_prop->offset], - ce->traits[i]->default_static_members_table[property_info->offset] TSRMLS_CC) == FAILURE; + not_compatible = (FAILURE == compare_function(&compare_result, + ce->default_static_members_table[coliding_prop->offset], + ce->traits[i]->default_static_members_table[property_info->offset] TSRMLS_CC)) + || (Z_LVAL(compare_result) != 0); } else { - not_compatible = compare_function(&compare_result, - ce->default_properties_table[coliding_prop->offset], - ce->traits[i]->default_properties_table[property_info->offset] TSRMLS_CC) == FAILURE; + not_compatible = (FAILURE == compare_function(&compare_result, + ce->default_properties_table[coliding_prop->offset], + ce->traits[i]->default_properties_table[property_info->offset] TSRMLS_CC)) + || (Z_LVAL(compare_result) != 0); } } else { /* the flags are not identical, thus, we assume properties are not compatible */ From c9fdd777fb972949ba4f32ef3cb9f69793e34789 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sat, 23 Jul 2011 18:12:31 +0000 Subject: [PATCH 0370/2394] Fixed incorrect initialization when copied op_array.vars was NULL (TRAITS) --- Zend/zend_compile.c | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 0069f3f44ec09..b005e4a4ed8ef 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3502,15 +3502,20 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM fe->op_array.refcount = emalloc(sizeof(zend_uint)); *(fe->op_array.refcount) = 1; - i = fe->op_array.last_var; - dupvars = safe_emalloc(fe->op_array.last_var, sizeof(zend_compiled_variable), 0); - while (i > 0) { - i--; - dupvars[i].name = estrndup(fe->op_array.vars[i].name, fe->op_array.vars[i].name_len); - dupvars[i].name_len = fe->op_array.vars[i].name_len; - dupvars[i].hash_value = fe->op_array.vars[i].hash_value; - } - fe->op_array.vars = dupvars; + if (fe->op_array.vars) { + i = fe->op_array.last_var; + dupvars = safe_emalloc(fe->op_array.last_var, sizeof(zend_compiled_variable), 0); + while (i > 0) { + i--; + dupvars[i].name = estrndup(fe->op_array.vars[i].name, fe->op_array.vars[i].name_len); + dupvars[i].name_len = fe->op_array.vars[i].name_len; + dupvars[i].hash_value = fe->op_array.vars[i].hash_value; + } + fe->op_array.vars = dupvars; + } + else { + fe->op_array.vars = NULL; + } opcode_copy = safe_emalloc(sizeof(zend_op), fe->op_array.last, 0); for(i = 0; i < fe->op_array.last; i++) { From 35f58b972f4172a63e99fdd118a7c7c3e041555d Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sat, 23 Jul 2011 19:08:43 +0000 Subject: [PATCH 0371/2394] Added missing class_uses(..) function to SPL to mirror class_implements(..). # Was pointed out as missing in bug #55266. --- NEWS | 1 + ext/spl/php_spl.c | 36 ++++++++++++++++++++++++++++++++++++ ext/spl/php_spl.h | 1 + ext/spl/spl_functions.c | 12 ++++++++++++ ext/spl/spl_functions.h | 1 + 5 files changed, 51 insertions(+) diff --git a/NEWS b/NEWS index 7a792084906f4..2d451c317fbb1 100644 --- a/NEWS +++ b/NEWS @@ -205,6 +205,7 @@ PHP NEWS . Added RegexIterator::getRegex() method. (Joshua Thijssen) . Added SplObjectStorage::getHash() hook. (Etienne) . Added CallbackFilterIterator and RecursiveCallbackFilterIterator (Arnaud) + . Added missing class_uses(..) as pointed out by #55266 (Stefan) - Improved XSL extension: . Added XsltProcessor::setSecurityPrefs($options) and getSecurityPrefs() to diff --git a/ext/spl/php_spl.c b/ext/spl/php_spl.c index de59a02c93b9c..8b49b6c5e1b24 100755 --- a/ext/spl/php_spl.c +++ b/ext/spl/php_spl.c @@ -166,6 +166,35 @@ PHP_FUNCTION(class_implements) } /* }}} */ +/* {{{ proto array class_uses(mixed what [, bool autoload ]) + Return all traits used by a class. */ +PHP_FUNCTION(class_uses) +{ + zval *obj; + zend_bool autoload = 1; + zend_class_entry *ce; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|b", &obj, &autoload) == FAILURE) { + RETURN_FALSE; + } + if (Z_TYPE_P(obj) != IS_OBJECT && Z_TYPE_P(obj) != IS_STRING) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "object or string expected"); + RETURN_FALSE; + } + + if (Z_TYPE_P(obj) == IS_STRING) { + if (NULL == (ce = spl_find_ce_by_name(Z_STRVAL_P(obj), Z_STRLEN_P(obj), autoload TSRMLS_CC))) { + RETURN_FALSE; + } + } else { + ce = Z_OBJCE_P(obj); + } + + array_init(return_value); + spl_add_traits(return_value, ce, 1, ZEND_ACC_TRAIT TSRMLS_CC); +} +/* }}} */ + #define SPL_ADD_CLASS(class_name, z_list, sub, allow, ce_flags) \ spl_add_classes(spl_ce_ ## class_name, z_list, sub, allow, ce_flags TSRMLS_CC) @@ -933,6 +962,12 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_implements, 0, 0, 1) ZEND_ARG_INFO(0, autoload) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_uses, 0, 0, 1) + ZEND_ARG_INFO(0, what) + ZEND_ARG_INFO(0, autoload) +ZEND_END_ARG_INFO() + + ZEND_BEGIN_ARG_INFO(arginfo_spl_classes, 0) ZEND_END_ARG_INFO() @@ -977,6 +1012,7 @@ const zend_function_entry spl_functions[] = { PHP_FE(spl_autoload_call, arginfo_spl_autoload_call) PHP_FE(class_parents, arginfo_class_parents) PHP_FE(class_implements, arginfo_class_implements) + PHP_FE(class_uses, arginfo_class_uses) PHP_FE(spl_object_hash, arginfo_spl_object_hash) #ifdef SPL_ITERATORS_H PHP_FE(iterator_to_array, arginfo_iterator_to_array) diff --git a/ext/spl/php_spl.h b/ext/spl/php_spl.h index ee6482548a919..7c6e174e97ac7 100755 --- a/ext/spl/php_spl.h +++ b/ext/spl/php_spl.h @@ -85,6 +85,7 @@ extern zend_spl_globals spl_globals; PHP_FUNCTION(spl_classes); PHP_FUNCTION(class_parents); PHP_FUNCTION(class_implements); +PHP_FUNCTION(class_uses); PHPAPI void php_spl_object_hash(zval *obj, char* md5str TSRMLS_DC); diff --git a/ext/spl/spl_functions.c b/ext/spl/spl_functions.c index 1d20b6a7f2c2c..84976bd0ad9c7 100755 --- a/ext/spl/spl_functions.c +++ b/ext/spl/spl_functions.c @@ -103,6 +103,18 @@ void spl_add_interfaces(zval *list, zend_class_entry * pce, int allow, int ce_fl } /* }}} */ +/* {{{ spl_add_traits */ +void spl_add_traits(zval *list, zend_class_entry * pce, int allow, int ce_flags TSRMLS_DC) +{ + zend_uint num_traits; + + for (num_traits = 0; num_traits < pce->num_traits; num_traits++) { + spl_add_class_name(list, pce->traits[num_traits], allow, ce_flags TSRMLS_CC); + } +} +/* }}} */ + + /* {{{ spl_add_classes */ int spl_add_classes(zend_class_entry *pce, zval *list, int sub, int allow, int ce_flags TSRMLS_DC) { diff --git a/ext/spl/spl_functions.h b/ext/spl/spl_functions.h index d5e3e72670e0e..69feb3834f16c 100755 --- a/ext/spl/spl_functions.h +++ b/ext/spl/spl_functions.h @@ -62,6 +62,7 @@ void spl_register_property( zend_class_entry * class_entry, char *prop_name, int */ void spl_add_class_name(zval * list, zend_class_entry * pce, int allow, int ce_flags TSRMLS_DC); void spl_add_interfaces(zval * list, zend_class_entry * pce, int allow, int ce_flags TSRMLS_DC); +void spl_add_traits(zval * list, zend_class_entry * pce, int allow, int ce_flags TSRMLS_DC); int spl_add_classes(zend_class_entry *pce, zval *list, int sub, int allow, int ce_flags TSRMLS_DC); /* caller must efree(return) */ From cbe0ed86e76c4e25ba7ee507238b4dcbc28f863a Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sat, 23 Jul 2011 20:23:21 +0000 Subject: [PATCH 0372/2394] - add short array syntax as defined in https://wiki.php.net/rfc/shortsyntaxforarrays, 2nd solution using => only --- UPGRADING | 6 +++++- Zend/zend_language_parser.y | 2 ++ tests/lang/array_shortcut_001.phpt | 13 +++++++++++++ tests/lang/array_shortcut_002.phpt | 13 +++++++++++++ tests/lang/array_shortcut_003.phpt | 13 +++++++++++++ tests/lang/array_shortcut_005.phpt | 20 ++++++++++++++++++++ 6 files changed, 66 insertions(+), 1 deletion(-) create mode 100644 tests/lang/array_shortcut_001.phpt create mode 100644 tests/lang/array_shortcut_002.phpt create mode 100644 tests/lang/array_shortcut_003.phpt create mode 100644 tests/lang/array_shortcut_005.phpt diff --git a/UPGRADING b/UPGRADING index 9fec6dd689b60..ba47155b9f099 100755 --- a/UPGRADING +++ b/UPGRADING @@ -448,4 +448,8 @@ UPGRADE NOTES - PHP X.Y - fnv164 - joaat - + k. New Syntax + - Short array syntax + $a = [1, 2, 3, 4]; + $a = ['one' => 1, 'two' => 2, 'three' => 3, 'four' => 4]; + $a = ['one' => 1, 2, 'three' => 3, 4]; diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 089209154afca..140d742d045ff 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -761,6 +761,7 @@ expr_without_variable: | '@' { zend_do_begin_silence(&$1 TSRMLS_CC); } expr { zend_do_end_silence(&$1 TSRMLS_CC); $$ = $3; } | scalar { $$ = $1; } | T_ARRAY '(' array_pair_list ')' { $$ = $3; } + | '[' array_pair_list ']' { $$ = $2; } | '`' backticks_expr '`' { zend_do_shell_exec(&$$, &$2 TSRMLS_CC); } | T_PRINT expr { zend_do_print(&$$, &$2 TSRMLS_CC); } | function is_reference '(' { zend_do_begin_lambda_function_declaration(&$$, &$1, $2.op_type, 0 TSRMLS_CC); } @@ -894,6 +895,7 @@ static_scalar: /* compile-time evaluated scalars */ | '+' static_scalar { ZVAL_LONG(&$1.u.constant, 0); add_function(&$2.u.constant, &$1.u.constant, &$2.u.constant TSRMLS_CC); $$ = $2; } | '-' static_scalar { ZVAL_LONG(&$1.u.constant, 0); sub_function(&$2.u.constant, &$1.u.constant, &$2.u.constant TSRMLS_CC); $$ = $2; } | T_ARRAY '(' static_array_pair_list ')' { $$ = $3; Z_TYPE($$.u.constant) = IS_CONSTANT_ARRAY; } + | '[' static_array_pair_list ']' { $$ = $2; Z_TYPE($$.u.constant) = IS_CONSTANT_ARRAY; } | static_class_constant { $$ = $1; } ; diff --git a/tests/lang/array_shortcut_001.phpt b/tests/lang/array_shortcut_001.phpt new file mode 100644 index 0000000000000..18a10ea09b454 --- /dev/null +++ b/tests/lang/array_shortcut_001.phpt @@ -0,0 +1,13 @@ +--TEST-- +Square bracket array shortcut test +--FILE-- + +--EXPECT-- +Array +( + [0] => 1 + [1] => 2 + [2] => 3 +) diff --git a/tests/lang/array_shortcut_002.phpt b/tests/lang/array_shortcut_002.phpt new file mode 100644 index 0000000000000..25aee9ba397bf --- /dev/null +++ b/tests/lang/array_shortcut_002.phpt @@ -0,0 +1,13 @@ +--TEST-- +Square bracket associative array shortcut test +--FILE-- + "orange", "bar" => "apple", "baz" => "lemon"]); +?> +--EXPECT-- +Array +( + [foo] => orange + [bar] => apple + [baz] => lemon +) diff --git a/tests/lang/array_shortcut_003.phpt b/tests/lang/array_shortcut_003.phpt new file mode 100644 index 0000000000000..75e428b63ef3a --- /dev/null +++ b/tests/lang/array_shortcut_003.phpt @@ -0,0 +1,13 @@ +--TEST-- +Testing array shortcut and bracket operator +--FILE-- + +--EXPECT-- +Array +( + [0] => 2 + [1] => 4 +) diff --git a/tests/lang/array_shortcut_005.phpt b/tests/lang/array_shortcut_005.phpt new file mode 100644 index 0000000000000..7cc7386f83fb7 --- /dev/null +++ b/tests/lang/array_shortcut_005.phpt @@ -0,0 +1,20 @@ +--TEST-- +Testing nested array shortcut +--FILE-- + "orange", "bar" => "apple", "baz" => "lemon"]]); +?> +--EXPECT-- +Array +( + [0] => 1 + [1] => 2 + [2] => 3 + [3] => Array + ( + [foo] => orange + [bar] => apple + [baz] => lemon + ) + +) From e708f4bb89dffadc65970c7116680144cece3f31 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sat, 23 Jul 2011 20:27:08 +0000 Subject: [PATCH 0373/2394] - add short array syntax, missing files and info --- UPGRADING | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/UPGRADING b/UPGRADING index ba47155b9f099..be650a37845f6 100755 --- a/UPGRADING +++ b/UPGRADING @@ -30,6 +30,7 @@ UPGRADE NOTES - PHP X.Y h. New methods i. New class constants j. New hash algorithms + k. New Syntax ======================================== 1. Changes made to default configuration @@ -449,7 +450,7 @@ UPGRADE NOTES - PHP X.Y - joaat k. New Syntax - - Short array syntax + - Short array syntax in 5.4.0 $a = [1, 2, 3, 4]; $a = ['one' => 1, 'two' => 2, 'three' => 3, 'four' => 4]; $a = ['one' => 1, 2, 'three' => 3, 4]; From 48870107dcf08978a033e318dbab0f79564c5d77 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sat, 23 Jul 2011 20:45:18 +0000 Subject: [PATCH 0374/2394] - MQ section --- UPGRADING | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/UPGRADING b/UPGRADING index be650a37845f6..dca9d20f2999c 100755 --- a/UPGRADING +++ b/UPGRADING @@ -216,6 +216,14 @@ UPGRADE NOTES - PHP X.Y a. removed features + - magic quotes + . remove magic_quotes_gpc, magic_quotes_runtime, + magic_quotes_sybase (calling ini_set('magic_....') + returns 0|false + . get_magic_quotes_gpc, get_magic_quotes_runtime are kept but + always return false + . set_magic_quotes_runtime raises an E_CORE_ERROR + - register_globals - register_long_arrays - Safe mode From 7bb8f9eecb813f18e310fb49ad19f65b39a7780c Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sat, 23 Jul 2011 22:07:22 +0000 Subject: [PATCH 0375/2394] Change E_ALL to include E_STRICT --- Zend/zend_builtin_functions.c | 2 +- Zend/zend_errors.h | 2 +- php.ini-development | 18 +++++++++--------- php.ini-production | 16 ++++++++-------- 4 files changed, 19 insertions(+), 19 deletions(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 6f82776391718..a81e9a8283f9d 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1501,7 +1501,7 @@ ZEND_FUNCTION(set_error_handler) zval *error_handler; zend_bool had_orig_error_handler=0; char *error_handler_name = NULL; - long error_type = E_ALL | E_STRICT; + long error_type = E_ALL; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|l", &error_handler, &error_type) == FAILURE) { return; diff --git a/Zend/zend_errors.h b/Zend/zend_errors.h index 03cdd8d9f833b..1e5f218c30120 100644 --- a/Zend/zend_errors.h +++ b/Zend/zend_errors.h @@ -38,7 +38,7 @@ #define E_DEPRECATED (1<<13L) #define E_USER_DEPRECATED (1<<14L) -#define E_ALL (E_ERROR | E_WARNING | E_PARSE | E_NOTICE | E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_COMPILE_WARNING | E_USER_ERROR | E_USER_WARNING | E_USER_NOTICE | E_RECOVERABLE_ERROR | E_DEPRECATED | E_USER_DEPRECATED) +#define E_ALL (E_ERROR | E_WARNING | E_PARSE | E_NOTICE | E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_COMPILE_WARNING | E_USER_ERROR | E_USER_WARNING | E_USER_NOTICE | E_RECOVERABLE_ERROR | E_DEPRECATED | E_USER_DEPRECATED | E_STRICT) #define E_CORE (E_CORE_ERROR | E_CORE_WARNING) #endif /* ZEND_ERRORS_H */ diff --git a/php.ini-development b/php.ini-development index 4a1eb4f01764b..2595e1d43da88 100644 --- a/php.ini-development +++ b/php.ini-development @@ -102,8 +102,8 @@ ; Production Value: Off ; error_reporting -; Default Value: E_ALL & ~E_NOTICE -; Development Value: E_ALL | E_STRICT +; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED +; Development Value: E_ALL ; Production Value: E_ALL & ~E_DEPRECATED ; html_errors @@ -412,7 +412,7 @@ memory_limit = 128M ; recommend error reporting setting. Your production server shouldn't be wasting ; resources complaining about best practices and coding standards. That's what ; development servers and development settings are for. -; Note: The php.ini-development file has this setting as E_ALL | E_STRICT. This +; Note: The php.ini-development file has this setting as E_ALL. This ; means it pretty much reports everything which is exactly what you want during ; development and early testing. ; @@ -443,15 +443,15 @@ memory_limit = 128M ; E_USER_DEPRECATED - user-generated deprecation warnings ; ; Common Values: -; E_ALL & ~E_NOTICE (Show all errors, except for notices and coding standards warnings.) -; E_ALL & ~E_NOTICE | E_STRICT (Show all errors, except for notices) +; E_ALL (Show all errors, warnings and notices including coding standards.) +; E_ALL & ~E_NOTICE (Show all errors, except for notices) +; E_ALL & ~E_NOTICE & ~E_STRICT (Show all errors, except for notices and coding standards warnings.) ; E_COMPILE_ERROR|E_RECOVERABLE_ERROR|E_ERROR|E_CORE_ERROR (Show only errors) -; E_ALL | E_STRICT (Show all errors, warnings and notices including coding standards.) -; Default Value: E_ALL & ~E_NOTICE -; Development Value: E_ALL | E_STRICT +; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED +; Development Value: E_ALL ; Production Value: E_ALL & ~E_DEPRECATED ; http://php.net/error-reporting -error_reporting = E_ALL | E_STRICT +error_reporting = E_ALL ; This directive controls whether or not and where PHP will output errors, ; notices and warnings too. Error output is very useful during development, but diff --git a/php.ini-production b/php.ini-production index ab7b266440be2..dd7ffe221d5fb 100644 --- a/php.ini-production +++ b/php.ini-production @@ -102,8 +102,8 @@ ; Production Value: Off ; error_reporting -; Default Value: E_ALL & ~E_NOTICE -; Development Value: E_ALL | E_STRICT +; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED +; Development Value: E_ALL ; Production Value: E_ALL & ~E_DEPRECATED ; html_errors @@ -412,7 +412,7 @@ memory_limit = 128M ; recommend error reporting setting. Your production server shouldn't be wasting ; resources complaining about best practices and coding standards. That's what ; development servers and development settings are for. -; Note: The php.ini-development file has this setting as E_ALL | E_STRICT. This +; Note: The php.ini-development file has this setting as E_ALL. This ; means it pretty much reports everything which is exactly what you want during ; development and early testing. ; @@ -443,12 +443,12 @@ memory_limit = 128M ; E_USER_DEPRECATED - user-generated deprecation warnings ; ; Common Values: -; E_ALL & ~E_NOTICE (Show all errors, except for notices and coding standards warnings.) -; E_ALL & ~E_NOTICE | E_STRICT (Show all errors, except for notices) +; E_ALL (Show all errors, warnings and notices including coding standards.) +; E_ALL & ~E_NOTICE (Show all errors, except for notices) +; E_ALL & ~E_NOTICE & ~E_STRICT (Show all errors, except for notices and coding standards warnings.) ; E_COMPILE_ERROR|E_RECOVERABLE_ERROR|E_ERROR|E_CORE_ERROR (Show only errors) -; E_ALL | E_STRICT (Show all errors, warnings and notices including coding standards.) -; Default Value: E_ALL & ~E_NOTICE -; Development Value: E_ALL | E_STRICT +; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED +; Development Value: E_ALL ; Production Value: E_ALL & ~E_DEPRECATED ; http://php.net/error-reporting error_reporting = E_ALL & ~E_DEPRECATED From 3f43c3ef9dd0acdfed761aac3d3407c5b5284acb Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 24 Jul 2011 05:42:29 +0000 Subject: [PATCH 0376/2394] No E_STRICT in production --- php.ini-development | 4 ++-- php.ini-production | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/php.ini-development b/php.ini-development index 2595e1d43da88..bbb22dd6d9e53 100644 --- a/php.ini-development +++ b/php.ini-development @@ -104,7 +104,7 @@ ; error_reporting ; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED ; Development Value: E_ALL -; Production Value: E_ALL & ~E_DEPRECATED +; Production Value: E_ALL & ~E_DEPRECATED & ~E_STRICT ; html_errors ; Default Value: On @@ -449,7 +449,7 @@ memory_limit = 128M ; E_COMPILE_ERROR|E_RECOVERABLE_ERROR|E_ERROR|E_CORE_ERROR (Show only errors) ; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED ; Development Value: E_ALL -; Production Value: E_ALL & ~E_DEPRECATED +; Production Value: E_ALL & ~E_DEPRECATED & ~E_STRICT ; http://php.net/error-reporting error_reporting = E_ALL diff --git a/php.ini-production b/php.ini-production index dd7ffe221d5fb..8e0773ffc1076 100644 --- a/php.ini-production +++ b/php.ini-production @@ -104,7 +104,7 @@ ; error_reporting ; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED ; Development Value: E_ALL -; Production Value: E_ALL & ~E_DEPRECATED +; Production Value: E_ALL & ~E_DEPRECATED & ~E_STRICT ; html_errors ; Default Value: On @@ -449,9 +449,9 @@ memory_limit = 128M ; E_COMPILE_ERROR|E_RECOVERABLE_ERROR|E_ERROR|E_CORE_ERROR (Show only errors) ; Default Value: E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED ; Development Value: E_ALL -; Production Value: E_ALL & ~E_DEPRECATED +; Production Value: E_ALL & ~E_DEPRECATED & ~E_STRICT ; http://php.net/error-reporting -error_reporting = E_ALL & ~E_DEPRECATED +error_reporting = E_ALL & ~E_DEPRECATED & ~E_STRICT ; This directive controls whether or not and where PHP will output errors, ; notices and warnings too. Error output is very useful during development, but From f9cb269d59e049253e243422401119a6972ddbb9 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sun, 24 Jul 2011 10:20:08 +0000 Subject: [PATCH 0377/2394] Added forgotten tests cases for class_uses() from commit rev. 313640 --- ext/spl/tests/class_uses_basic.phpt | 33 +++ ext/spl/tests/class_uses_basic2.phpt | 69 ++++++ ext/spl/tests/class_uses_variation.phpt | 45 ++++ ext/spl/tests/class_uses_variation1.phpt | 221 +++++++++++++++++++ ext/spl/tests/class_uses_variation2.phpt | 261 +++++++++++++++++++++++ 5 files changed, 629 insertions(+) create mode 100644 ext/spl/tests/class_uses_basic.phpt create mode 100644 ext/spl/tests/class_uses_basic2.phpt create mode 100644 ext/spl/tests/class_uses_variation.phpt create mode 100644 ext/spl/tests/class_uses_variation1.phpt create mode 100644 ext/spl/tests/class_uses_variation2.phpt diff --git a/ext/spl/tests/class_uses_basic.phpt b/ext/spl/tests/class_uses_basic.phpt new file mode 100644 index 0000000000000..8aeb7b52a77ff --- /dev/null +++ b/ext/spl/tests/class_uses_basic.phpt @@ -0,0 +1,33 @@ +--TEST-- +SPL: Test class_implements() function : basic +--FILE-- + +===DONE=== +--EXPECT-- +*** Testing class_uses() : basic *** +array(1) { + ["foo"]=> + string(3) "foo" +} +array(1) { + ["foo"]=> + string(3) "foo" +} +===DONE=== diff --git a/ext/spl/tests/class_uses_basic2.phpt b/ext/spl/tests/class_uses_basic2.phpt new file mode 100644 index 0000000000000..a0ffe8b861f66 --- /dev/null +++ b/ext/spl/tests/class_uses_basic2.phpt @@ -0,0 +1,69 @@ +--TEST-- +SPL: Test class_uses() function : basic +--FILE-- + +===DONE=== +--EXPECT-- +*** Testing class_uses() : basic *** +array(2) { + ["foo"]=> + string(3) "foo" + ["bar"]=> + string(3) "bar" +} +array(2) { + ["foo"]=> + string(3) "foo" + ["bar"]=> + string(3) "bar" +} +array(1) { + ["foo"]=> + string(3) "foo" +} +array(1) { + ["foo"]=> + string(3) "foo" +} +array(0) { +} +array(0) { +} +===DONE=== diff --git a/ext/spl/tests/class_uses_variation.phpt b/ext/spl/tests/class_uses_variation.phpt new file mode 100644 index 0000000000000..9c21521c6050b --- /dev/null +++ b/ext/spl/tests/class_uses_variation.phpt @@ -0,0 +1,45 @@ +--TEST-- +SPL: Test class_uses() function : variation - no interfaces and autoload +--FILE-- + +===DONE=== +--EXPECTF-- +*** Testing class_uses() : variation *** +--- testing no traits --- +array(0) { +} +array(0) { +} + +--- testing autoload --- +attempting to autoload non-existent + +Warning: class_uses(): Class non-existent does not exist and could not be loaded in %s on line %d +bool(false) + +Warning: class_uses(): Class non-existent2 does not exist in %s on line %d +bool(false) +===DONE=== diff --git a/ext/spl/tests/class_uses_variation1.phpt b/ext/spl/tests/class_uses_variation1.phpt new file mode 100644 index 0000000000000..aa0ba35c941c8 --- /dev/null +++ b/ext/spl/tests/class_uses_variation1.phpt @@ -0,0 +1,221 @@ +--TEST-- +SPL: Test class_uses() function : variation +--FILE-- + 1, 'two' => 2); + +//array of values to iterate over +$inputs = array( + + // int data + 'int 0' => 0, + 'int 1' => 1, + 'int 12345' => 12345, + 'int -12345' => -2345, + + // float data + 'float 10.5' => 10.5, + 'float -10.5' => -10.5, + 'float 12.3456789000e10' => 12.3456789000e10, + 'float -12.3456789000e10' => -12.3456789000e10, + 'float .5' => .5, + + // array data + 'empty array' => array(), + 'int indexed array' => $index_array, + 'associative array' => $assoc_array, + 'nested arrays' => array('foo', $index_array, $assoc_array), + + // null data + 'uppercase NULL' => NULL, + 'lowercase null' => null, + + // boolean data + 'lowercase true' => true, + 'lowercase false' =>false, + 'uppercase TRUE' =>TRUE, + 'uppercase FALSE' =>FALSE, + + // empty data + 'empty string DQ' => "", + 'empty string SQ' => '', + + // object data + 'instance of classWithToString' => new classWithToString(), + 'instance of classWithoutToString' => new classWithoutToString(), + + // undefined data + 'undefined var' => @$undefined_var, + + // unset data + 'unset var' => @$unset_var, + + //resource + 'resource' => $res, +); + +// loop through each element of the array for pattern + +foreach($inputs as $key =>$value) { + echo "\n--$key--\n"; + var_dump( class_uses($value, $autoload) ); +}; + +fclose($res); + +?> +===DONE=== +--EXPECTF-- +*** Testing class_uses() : variation *** + +--int 0-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--int 1-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--int 12345-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--int -12345-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--float 10.5-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--float -10.5-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--float 12.3456789000e10-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--float -12.3456789000e10-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--float .5-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--empty array-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--int indexed array-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--associative array-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--nested arrays-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--uppercase NULL-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--lowercase null-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--lowercase true-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--lowercase false-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--uppercase TRUE-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--uppercase FALSE-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--empty string DQ-- +Error: 2 - class_uses(): Class does not exist and could not be loaded, %s(%d) +bool(false) + +--empty string SQ-- +Error: 2 - class_uses(): Class does not exist and could not be loaded, %s(%d) +bool(false) + +--instance of classWithToString-- +array(0) { +} + +--instance of classWithoutToString-- +array(0) { +} + +--undefined var-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--unset var-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) + +--resource-- +Error: 2 - class_uses(): object or string expected, %s(%d) +bool(false) +===DONE=== diff --git a/ext/spl/tests/class_uses_variation2.phpt b/ext/spl/tests/class_uses_variation2.phpt new file mode 100644 index 0000000000000..36c9623cb3adf --- /dev/null +++ b/ext/spl/tests/class_uses_variation2.phpt @@ -0,0 +1,261 @@ +--TEST-- +SPL: Test class_uses() function : variation +--FILE-- + 1, 'two' => 2); + +//array of values to iterate over +$inputs = array( + + // int data + 'int 0' => 0, + 'int 1' => 1, + 'int 12345' => 12345, + 'int -12345' => -2345, + + // float data + 'float 10.5' => 10.5, + 'float -10.5' => -10.5, + 'float 12.3456789000e10' => 12.3456789000e10, + 'float -12.3456789000e10' => -12.3456789000e10, + 'float .5' => .5, + + // array data + 'empty array' => array(), + 'int indexed array' => $index_array, + 'associative array' => $assoc_array, + 'nested arrays' => array('foo', $index_array, $assoc_array), + + // null data + 'uppercase NULL' => NULL, + 'lowercase null' => null, + + // boolean data + 'lowercase true' => true, + 'lowercase false' =>false, + 'uppercase TRUE' =>TRUE, + 'uppercase FALSE' =>FALSE, + + // empty data + 'empty string DQ' => "", + 'empty string SQ' => '', + + // object data + 'instance of classWithToString' => new classWithToString(), + 'instance of classWithoutToString' => new classWithoutToString(), + + // undefined data + 'undefined var' => @$undefined_var, + + // unset data + 'unset var' => @$unset_var, + + //resource + 'resource' => $res, +); + +// loop through each element of the array for pattern + +foreach($inputs as $key =>$value) { + echo "\n--$key--\n"; + var_dump( class_uses($class, $value) ); +}; + +fclose($res); + +?> +===DONE=== +--EXPECTF-- +*** Testing class_uses() : variation *** + +--int 0-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--int 1-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--int 12345-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--int -12345-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--float 10.5-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--float -10.5-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--float 12.3456789000e10-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--float -12.3456789000e10-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--float .5-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--empty array-- +Error: 2 - class_uses() expects parameter 2 to be boolean, array given, %s(%d) +bool(false) + +--int indexed array-- +Error: 2 - class_uses() expects parameter 2 to be boolean, array given, %s(%d) +bool(false) + +--associative array-- +Error: 2 - class_uses() expects parameter 2 to be boolean, array given, %s(%d) +bool(false) + +--nested arrays-- +Error: 2 - class_uses() expects parameter 2 to be boolean, array given, %s(%d) +bool(false) + +--uppercase NULL-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--lowercase null-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--lowercase true-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--lowercase false-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--uppercase TRUE-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--uppercase FALSE-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--empty string DQ-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--empty string SQ-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--instance of classWithToString-- +Error: 2 - class_uses() expects parameter 2 to be boolean, object given, %s(%d) +bool(false) + +--instance of classWithoutToString-- +Error: 2 - class_uses() expects parameter 2 to be boolean, object given, %s(%d) +bool(false) + +--undefined var-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--unset var-- +array(1) { + ["foo"]=> + string(3) "foo" +} + +--resource-- +Error: 2 - class_uses() expects parameter 2 to be boolean, resource given, %s(%d) +bool(false) +===DONE=== From c168ea847783d1ccf08980bd811a0f2d4ea7cf89 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 25 Jul 2011 05:32:08 +0000 Subject: [PATCH 0378/2394] When you add something that changes the phpinfo output, please update this test. --- ext/standard/tests/general_functions/phpinfo.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/standard/tests/general_functions/phpinfo.phpt b/ext/standard/tests/general_functions/phpinfo.phpt index df6aef832e5b8..10b8e5531a884 100644 --- a/ext/standard/tests/general_functions/phpinfo.phpt +++ b/ext/standard/tests/general_functions/phpinfo.phpt @@ -34,6 +34,7 @@ Zend Extension Build => API%s PHP Extension Build => API%s Debug Build => %s Thread Safety => %s +Zend Signal Handling => %s Zend Memory Manager => %s Zend Signal Handling => %s Zend Multibyte Support => %s From f8a3334c89defdff21e4e658d2fd531d540cf231 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 25 Jul 2011 11:30:53 +0000 Subject: [PATCH 0379/2394] - Added new macro to be used in the end of zend_function_entry declaration (Gwynne) --- Zend/zend_API.h | 2 ++ main/php.h | 1 + 2 files changed, 3 insertions(+) diff --git a/Zend/zend_API.h b/Zend/zend_API.h index db040f6be46fd..487356e575efb 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -96,6 +96,8 @@ typedef struct _zend_fcall_info_cache { #define ZEND_NS_FALIAS(ns, name, alias, arg_info) ZEND_NS_FENTRY(ns, name, ZEND_FN(alias), arg_info, 0) #define ZEND_NS_DEP_FALIAS(ns, name, alias, arg_info) ZEND_NS_FENTRY(ns, name, ZEND_FN(alias), arg_info, ZEND_ACC_DEPRECATED) +#define ZEND_FE_END { NULL, NULL, NULL, 0, 0 } + #define ZEND_ARG_INFO(pass_by_ref, name) { #name, sizeof(#name)-1, NULL, 0, 0, 0, pass_by_ref}, #define ZEND_ARG_PASS_INFO(pass_by_ref) { NULL, 0, NULL, 0, 0, 0, pass_by_ref}, #define ZEND_ARG_OBJ_INFO(pass_by_ref, name, classname, allow_null) { #name, sizeof(#name)-1, #classname, sizeof(#classname)-1, IS_OBJECT, allow_null, pass_by_ref}, diff --git a/main/php.h b/main/php.h index e108c254131ea..7af265c78aeb8 100644 --- a/main/php.h +++ b/main/php.h @@ -359,6 +359,7 @@ END_EXTERN_C() #define PHP_MALIAS ZEND_MALIAS #define PHP_ABSTRACT_ME ZEND_ABSTRACT_ME #define PHP_ME_MAPPING ZEND_ME_MAPPING +#define PHP_FE_END ZEND_FE_END #define PHP_MODULE_STARTUP_N ZEND_MODULE_STARTUP_N #define PHP_MODULE_SHUTDOWN_N ZEND_MODULE_SHUTDOWN_N From da376383e847f9f2a09955a4e9f5ae0371f26131 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 25 Jul 2011 11:35:02 +0000 Subject: [PATCH 0380/2394] - Make usage of new PHP_FE_END macro --- ext/bcmath/bcmath.c | 2 +- ext/bz2/bz2.c | 2 +- ext/calendar/calendar.c | 2 +- ext/com_dotnet/com_extension.c | 2 +- ext/com_dotnet/com_persist.c | 2 +- ext/ctype/ctype.c | 2 +- ext/curl/interface.c | 2 +- ext/date/php_date.c | 10 ++++---- ext/dba/dba.c | 2 +- ext/dom/attr.c | 2 +- ext/dom/cdatasection.c | 2 +- ext/dom/characterdata.c | 2 +- ext/dom/document.c | 2 +- ext/dom/documentfragment.c | 2 +- ext/dom/documenttype.c | 2 +- ext/dom/domconfiguration.c | 2 +- ext/dom/domerror.c | 2 +- ext/dom/domerrorhandler.c | 2 +- ext/dom/domexception.c | 2 +- ext/dom/domimplementation.c | 2 +- ext/dom/domimplementationsource.c | 2 +- ext/dom/domlocator.c | 2 +- ext/dom/domstringlist.c | 2 +- ext/dom/element.c | 2 +- ext/dom/entity.c | 2 +- ext/dom/entityreference.c | 2 +- ext/dom/namednodemap.c | 2 +- ext/dom/namelist.c | 2 +- ext/dom/node.c | 2 +- ext/dom/nodelist.c | 2 +- ext/dom/notation.c | 2 +- ext/dom/php_dom.c | 2 +- ext/dom/processinginstruction.c | 2 +- ext/dom/string_extend.c | 2 +- ext/dom/text.c | 2 +- ext/dom/typeinfo.c | 2 +- ext/dom/userdatahandler.c | 2 +- ext/dom/xpath.c | 2 +- ext/enchant/enchant.c | 3 +-- ext/ereg/ereg.c | 2 +- ext/exif/exif.c | 2 +- ext/fileinfo/fileinfo.c | 2 +- ext/filter/filter.c | 2 +- ext/ftp/php_ftp.c | 2 +- ext/gd/gd.c | 2 +- ext/gettext/gettext.c | 2 +- ext/gmp/gmp.c | 2 +- ext/hash/hash.c | 2 +- ext/iconv/iconv.c | 2 +- ext/imap/php_imap.c | 2 +- ext/interbase/interbase.c | 2 +- ext/intl/php_intl.c | 2 +- ext/json/json.c | 2 +- ext/ldap/ldap.c | 2 +- ext/libxml/libxml.c | 2 +- ext/mbstring/mbstring.c | 2 +- ext/mcrypt/mcrypt.c | 2 +- ext/mssql/php_mssql.c | 2 +- ext/mysql/php_mysql.c | 2 +- ext/mysqli/mysqli_fe.c | 2 +- ext/mysqlnd/php_mysqlnd.c | 2 +- ext/oci8/oci8.c | 6 ++--- ext/odbc/php_odbc.c | 2 +- ext/openssl/openssl.c | 2 +- ext/pcntl/pcntl.c | 2 +- ext/pcre/php_pcre.c | 2 +- ext/pdo/pdo.c | 2 +- ext/pdo_dblib/pdo_dblib.c | 2 +- ext/pdo_firebird/pdo_firebird.c | 2 +- ext/pdo_mysql/pdo_mysql.c | 2 +- ext/pdo_oci/pdo_oci.c | 2 +- ext/pdo_odbc/pdo_odbc.c | 2 +- ext/pdo_pgsql/pgsql_driver.c | 2 +- ext/pdo_sqlite/pdo_sqlite.c | 2 +- ext/pdo_sqlite/sqlite_driver.c | 2 +- ext/pgsql/pgsql.c | 2 +- ext/phar/phar.c | 2 +- ext/phar/phar_object.c | 6 ++--- ext/posix/posix.c | 2 +- ext/pspell/pspell.c | 2 +- ext/readline/readline.c | 2 +- ext/recode/recode.c | 2 +- ext/reflection/php_reflection.c | 26 +++++++++---------- ext/session/session.c | 2 +- ext/shmop/shmop.c | 2 +- ext/simplexml/simplexml.c | 4 +-- ext/skeleton/skeleton.c | 2 +- ext/snmp/snmp.c | 4 +-- ext/soap/soap.c | 14 +++++------ ext/sockets/sockets.c | 2 +- ext/spl/php_spl.c | 4 +-- ext/spl/spl_array.c | 6 ++--- ext/spl/spl_directory.c | 14 +++++------ ext/spl/spl_dllist.c | 4 +-- ext/spl/spl_fixedarray.c | 2 +- ext/spl/spl_iterators.c | 42 +++++++++++++++---------------- ext/sqlite3/sqlite3.c | 6 ++--- ext/standard/basic_functions.c | 2 +- ext/sybase_ct/php_sybase_ct.c | 2 +- ext/sysvmsg/sysvmsg.c | 2 +- ext/sysvsem/sysvsem.c | 2 +- ext/sysvshm/sysvshm.c | 2 +- ext/tidy/tidy.c | 6 ++--- ext/tokenizer/tokenizer.c | 2 +- ext/wddx/wddx.c | 2 +- ext/xml/xml.c | 2 +- ext/xmlreader/php_xmlreader.c | 2 +- ext/xmlrpc/xmlrpc-epi-php.c | 2 +- ext/xmlwriter/php_xmlwriter.c | 2 +- ext/xsl/php_xsl.c | 2 +- ext/zip/php_zip.c | 3 +-- ext/zlib/zlib.c | 2 +- 112 files changed, 174 insertions(+), 176 deletions(-) diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c index f684a49a54252..f42d3363b3a99 100644 --- a/ext/bcmath/bcmath.c +++ b/ext/bcmath/bcmath.c @@ -106,7 +106,7 @@ const zend_function_entry bcmath_functions[] = { PHP_FE(bcscale, arginfo_bcscale) PHP_FE(bccomp, arginfo_bccomp) PHP_FE(bcpowmod, arginfo_bcpowmod) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry bcmath_module_entry = { diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c index 310589fc102f9..1a8bc41b06d1b 100644 --- a/ext/bz2/bz2.c +++ b/ext/bz2/bz2.c @@ -107,7 +107,7 @@ static const zend_function_entry bz2_functions[] = { PHP_FE(bzerror, arginfo_bzerror) PHP_FE(bzcompress, arginfo_bzcompress) PHP_FE(bzdecompress, arginfo_bzdecompress) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry bz2_module_entry = { diff --git a/ext/calendar/calendar.c b/ext/calendar/calendar.c index 61bf4d10a12c0..e1546ebf23f0e 100644 --- a/ext/calendar/calendar.c +++ b/ext/calendar/calendar.c @@ -148,7 +148,7 @@ const zend_function_entry calendar_functions[] = { PHP_FE(cal_from_jd, arginfo_cal_from_jd) PHP_FE(cal_days_in_month, arginfo_cal_days_in_month) PHP_FE(cal_info, arginfo_cal_info) - {NULL, NULL, NULL} + PHP_FE_END }; diff --git a/ext/com_dotnet/com_extension.c b/ext/com_dotnet/com_extension.c index 4ded383c05249..bf6e536d954ad 100644 --- a/ext/com_dotnet/com_extension.c +++ b/ext/com_dotnet/com_extension.c @@ -228,7 +228,7 @@ const zend_function_entry com_dotnet_functions[] = { PHP_FE(com_message_pump, arginfo_com_message_pump) PHP_FE(com_load_typelib, arginfo_com_load_typelib) PHP_FE(com_get_active_object, arginfo_com_get_active_object) - { NULL, NULL, NULL } + PHP_FE_END }; /* {{{ com_dotnet_module_entry diff --git a/ext/com_dotnet/com_persist.c b/ext/com_dotnet/com_persist.c index c72bf622a417f..edacf21e26c34 100755 --- a/ext/com_dotnet/com_persist.c +++ b/ext/com_dotnet/com_persist.c @@ -685,7 +685,7 @@ static const zend_function_entry com_persist_helper_methods[] = { CPH_ME(InitNew, NULL) CPH_ME(LoadFromStream, NULL) CPH_ME(SaveToStream, NULL) - {NULL, NULL, NULL} + PHP_FE_END }; static void helper_free_storage(void *obj TSRMLS_DC) diff --git a/ext/ctype/ctype.c b/ext/ctype/ctype.c index 05169619bf30c..b80e1df6ed4d2 100644 --- a/ext/ctype/ctype.c +++ b/ext/ctype/ctype.c @@ -106,7 +106,7 @@ static const zend_function_entry ctype_functions[] = { PHP_FE(ctype_space, arginfo_ctype_space) PHP_FE(ctype_upper, arginfo_ctype_upper) PHP_FE(ctype_xdigit, arginfo_ctype_xdigit) - {NULL, NULL, NULL} /* Must be the last line in ctype_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 88502df8bf123..ce12171d60033 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -305,7 +305,7 @@ const zend_function_entry curl_functions[] = { PHP_FE(curl_multi_getcontent, arginfo_curl_multi_getcontent) PHP_FE(curl_multi_info_read, arginfo_curl_multi_info_read) PHP_FE(curl_multi_close, arginfo_curl_multi_close) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 1930e88abd264..24a44b91107cc 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -425,7 +425,7 @@ const zend_function_entry date_functions[] = { PHP_FE(date_sunrise, arginfo_date_sunrise) PHP_FE(date_sunset, arginfo_date_sunset) PHP_FE(date_sun_info, arginfo_date_sun_info) - {NULL, NULL, NULL} + PHP_FE_END }; const zend_function_entry date_funcs_date[] = { @@ -447,7 +447,7 @@ const zend_function_entry date_funcs_date[] = { PHP_ME_MAPPING(setTimestamp, date_timestamp_set, arginfo_date_method_timestamp_set, 0) PHP_ME_MAPPING(getTimestamp, date_timestamp_get, arginfo_date_method_timestamp_get, 0) PHP_ME_MAPPING(diff, date_diff, arginfo_date_method_diff, 0) - {NULL, NULL, NULL} + PHP_FE_END }; const zend_function_entry date_funcs_timezone[] = { @@ -458,19 +458,19 @@ const zend_function_entry date_funcs_timezone[] = { PHP_ME_MAPPING(getLocation, timezone_location_get, arginfo_timezone_method_location_get, 0) PHP_ME_MAPPING(listAbbreviations, timezone_abbreviations_list, arginfo_timezone_abbreviations_list, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) PHP_ME_MAPPING(listIdentifiers, timezone_identifiers_list, arginfo_timezone_identifiers_list, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - {NULL, NULL, NULL} + PHP_FE_END }; const zend_function_entry date_funcs_interval[] = { PHP_ME(DateInterval, __construct, arginfo_date_interval_construct, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) PHP_ME_MAPPING(format, date_interval_format, arginfo_date_method_interval_format, 0) PHP_ME_MAPPING(createFromDateString, date_interval_create_from_date_string, arginfo_date_interval_create_from_date_string, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - {NULL, NULL, NULL} + PHP_FE_END }; const zend_function_entry date_funcs_period[] = { PHP_ME(DatePeriod, __construct, arginfo_date_period_construct, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC); diff --git a/ext/dba/dba.c b/ext/dba/dba.c index 55fde324596b7..9b78be4b1e832 100644 --- a/ext/dba/dba.c +++ b/ext/dba/dba.c @@ -146,7 +146,7 @@ const zend_function_entry dba_functions[] = { PHP_FE(dba_handlers, arginfo_dba_handlers) PHP_FE(dba_list, arginfo_dba_list) PHP_FE(dba_key_split, arginfo_dba_key_split) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/dom/attr.c b/ext/dom/attr.c index cfa249cacb4e5..63978779f6edf 100644 --- a/ext/dom/attr.c +++ b/ext/dom/attr.c @@ -49,7 +49,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_attr_class_functions[] = { PHP_FALIAS(isId, dom_attr_is_id, arginfo_dom_attr_is_id) PHP_ME(domattr, __construct, arginfo_dom_attr_construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void DOMAttr::__construct(string name, [string value]); */ diff --git a/ext/dom/cdatasection.c b/ext/dom/cdatasection.c index a9642c47686e5..bb133fef8787a 100644 --- a/ext/dom/cdatasection.c +++ b/ext/dom/cdatasection.c @@ -43,7 +43,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_cdatasection_class_functions[] = { PHP_ME(domcdatasection, __construct, arginfo_dom_cdatasection_construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void DOMCdataSection::__construct(string value); */ diff --git a/ext/dom/characterdata.c b/ext/dom/characterdata.c index f56c39c8e7e5f..98bb5a0785f2c 100644 --- a/ext/dom/characterdata.c +++ b/ext/dom/characterdata.c @@ -68,7 +68,7 @@ const zend_function_entry php_dom_characterdata_class_functions[] = { PHP_FALIAS(insertData, dom_characterdata_insert_data, arginfo_dom_characterdata_insert_data) PHP_FALIAS(deleteData, dom_characterdata_delete_data, arginfo_dom_characterdata_delete_data) PHP_FALIAS(replaceData, dom_characterdata_replace_data, arginfo_dom_characterdata_replace_data) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ data string diff --git a/ext/dom/document.c b/ext/dom/document.c index 2b11e7f1c43f4..b5402472b793a 100644 --- a/ext/dom/document.c +++ b/ext/dom/document.c @@ -231,7 +231,7 @@ const zend_function_entry php_dom_document_class_functions[] = { /* {{{ */ PHP_FALIAS(relaxNGValidateSource, dom_document_relaxNG_validate_xml, arginfo_dom_document_relaxNG_validate_xml) #endif PHP_ME(domdocument, registerNodeClass, arginfo_dom_document_registernodeclass, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/dom/documentfragment.c b/ext/dom/documentfragment.c index 2e88b726de89d..da01cd9aa655a 100644 --- a/ext/dom/documentfragment.c +++ b/ext/dom/documentfragment.c @@ -46,7 +46,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_documentfragment_class_functions[] = { PHP_ME(domdocumentfragment, __construct, arginfo_dom_documentfragement_construct, ZEND_ACC_PUBLIC) PHP_ME(domdocumentfragment, appendXML, arginfo_dom_documentfragement_appendXML, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void DOMDocumentFragment::__construct(); */ diff --git a/ext/dom/documenttype.c b/ext/dom/documenttype.c index a83c7eac17b3a..69b21c3c82b18 100644 --- a/ext/dom/documenttype.c +++ b/ext/dom/documenttype.c @@ -35,7 +35,7 @@ */ const zend_function_entry php_dom_documenttype_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ name string diff --git a/ext/dom/domconfiguration.c b/ext/dom/domconfiguration.c index 1ad57fe65eba7..76f18da046e87 100644 --- a/ext/dom/domconfiguration.c +++ b/ext/dom/domconfiguration.c @@ -54,7 +54,7 @@ const zend_function_entry php_dom_domconfiguration_class_functions[] = { PHP_FALIAS(setParameter, dom_domconfiguration_set_parameter, arginfo_dom_configuration_set_parameter) PHP_FALIAS(getParameter, dom_domconfiguration_get_parameter, arginfo_dom_configuration_get_parameter) PHP_FALIAS(canSetParameter, dom_domconfiguration_can_set_parameter, arginfo_dom_configuration_can_set_parameter) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/domerror.c b/ext/dom/domerror.c index 414defe484e70..0f5f3f7d90ddd 100644 --- a/ext/dom/domerror.c +++ b/ext/dom/domerror.c @@ -36,7 +36,7 @@ */ const zend_function_entry php_dom_domerror_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/domerrorhandler.c b/ext/dom/domerrorhandler.c index 4df9e351611bd..9fcc4e9eaa2db 100644 --- a/ext/dom/domerrorhandler.c +++ b/ext/dom/domerrorhandler.c @@ -42,7 +42,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_domerrorhandler_class_functions[] = { PHP_FALIAS(handleError, dom_domerrorhandler_handle_error, arginfo_dom_domerrorhandler_handle_error) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/domexception.c b/ext/dom/domexception.c index 8046873bb04fb..5477e34ef3f0a 100644 --- a/ext/dom/domexception.c +++ b/ext/dom/domexception.c @@ -37,7 +37,7 @@ extern zend_class_entry *dom_domexception_class_entry; const zend_function_entry php_dom_domexception_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; void php_dom_throw_error_with_message(int error_code, char *error_message, int strict_error TSRMLS_DC) /* {{{ */ diff --git a/ext/dom/domimplementation.c b/ext/dom/domimplementation.c index c931dc5ede05e..c7ad1d7bb7ce6 100644 --- a/ext/dom/domimplementation.c +++ b/ext/dom/domimplementation.c @@ -61,7 +61,7 @@ const zend_function_entry php_dom_domimplementation_class_functions[] = { PHP_ME(domimplementation, hasFeature, arginfo_dom_implementation_has_feature, ZEND_ACC_PUBLIC|ZEND_ACC_ALLOW_STATIC) PHP_ME(domimplementation, createDocumentType, arginfo_dom_implementation_create_documenttype, ZEND_ACC_PUBLIC|ZEND_ACC_ALLOW_STATIC) PHP_ME(domimplementation, createDocument, arginfo_dom_implementation_create_document, ZEND_ACC_PUBLIC|ZEND_ACC_ALLOW_STATIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto boolean dom_domimplementation_has_feature(string feature, string version); diff --git a/ext/dom/domimplementationsource.c b/ext/dom/domimplementationsource.c index 0fc33a2ed71fc..e7638834c674c 100644 --- a/ext/dom/domimplementationsource.c +++ b/ext/dom/domimplementationsource.c @@ -48,7 +48,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_domimplementationsource_class_functions[] = { PHP_FALIAS(getDomimplementation, dom_domimplementationsource_get_domimplementation, arginfo_dom_implementationsource_getdomimplementation) PHP_FALIAS(getDomimplementations, dom_domimplementationsource_get_domimplementations, arginfo_dom_implementationsource_getdomimplementations) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/domlocator.c b/ext/dom/domlocator.c index b31a4564a95a9..f2c92bebdf177 100644 --- a/ext/dom/domlocator.c +++ b/ext/dom/domlocator.c @@ -36,7 +36,7 @@ */ const zend_function_entry php_dom_domlocator_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/domstringlist.c b/ext/dom/domstringlist.c index 0791ec8d8ed5b..f00d5ff44e927 100644 --- a/ext/dom/domstringlist.c +++ b/ext/dom/domstringlist.c @@ -42,7 +42,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_domstringlist_class_functions[] = { PHP_FALIAS(item, dom_domstringlist_item, arginfo_dom_stringlist_item) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/element.c b/ext/dom/element.c index 5a7d007e23180..66ad2af163bb6 100644 --- a/ext/dom/element.c +++ b/ext/dom/element.c @@ -146,7 +146,7 @@ const zend_function_entry php_dom_element_class_functions[] = { /* {{{ */ PHP_FALIAS(setIdAttributeNS, dom_element_set_id_attribute_ns, arginfo_dom_element_set_id_attribute_ns) PHP_FALIAS(setIdAttributeNode, dom_element_set_id_attribute_node, arginfo_dom_element_set_id_attribute_node) PHP_ME(domelement, __construct, arginfo_dom_element_construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/dom/entity.c b/ext/dom/entity.c index 71eeacf924956..5b7151e5b3540 100644 --- a/ext/dom/entity.c +++ b/ext/dom/entity.c @@ -36,7 +36,7 @@ */ const zend_function_entry php_dom_entity_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ publicId string diff --git a/ext/dom/entityreference.c b/ext/dom/entityreference.c index b9404ba1cd59d..daabf41ea5501 100644 --- a/ext/dom/entityreference.c +++ b/ext/dom/entityreference.c @@ -42,7 +42,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_entityreference_class_functions[] = { PHP_ME(domentityreference, __construct, arginfo_dom_entityreference_construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void DOMEntityReference::__construct(string name); */ diff --git a/ext/dom/namednodemap.c b/ext/dom/namednodemap.c index d259963e2fa2d..963371a8e58fe 100644 --- a/ext/dom/namednodemap.c +++ b/ext/dom/namednodemap.c @@ -74,7 +74,7 @@ const zend_function_entry php_dom_namednodemap_class_functions[] = { /* {{{ */ PHP_FALIAS(getNamedItemNS, dom_namednodemap_get_named_item_ns, arginfo_dom_namednodemap_get_named_item_ns) PHP_FALIAS(setNamedItemNS, dom_namednodemap_set_named_item_ns, arginfo_dom_namednodemap_set_named_item_ns) PHP_FALIAS(removeNamedItemNS, dom_namednodemap_remove_named_item_ns, arginfo_dom_namednodemap_remove_named_item_ns) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/dom/namelist.c b/ext/dom/namelist.c index 2d2bc69ee6076..fb454a783a822 100644 --- a/ext/dom/namelist.c +++ b/ext/dom/namelist.c @@ -47,7 +47,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_namelist_class_functions[] = { PHP_FALIAS(getName, dom_namelist_get_name, arginfo_dom_namelist_get_name) PHP_FALIAS(getNamespaceURI, dom_namelist_get_namespace_uri, arginfo_dom_namelist_get_namespace_uri) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ length int diff --git a/ext/dom/node.c b/ext/dom/node.c index 17040521e148f..839c797bb6a55 100644 --- a/ext/dom/node.c +++ b/ext/dom/node.c @@ -155,7 +155,7 @@ const zend_function_entry php_dom_node_class_functions[] = { /* {{{ */ PHP_ME(domnode, getLineNo, arginfo_dom_node_getLineNo, ZEND_ACC_PUBLIC) PHP_ME(domnode, C14N, arginfo_dom_node_C14N, ZEND_ACC_PUBLIC) PHP_ME(domnode, C14NFile, arginfo_dom_node_C14NFile, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/dom/nodelist.c b/ext/dom/nodelist.c index 2baeea29d9696..f7d7d15450d91 100644 --- a/ext/dom/nodelist.c +++ b/ext/dom/nodelist.c @@ -43,7 +43,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_nodelist_class_functions[] = { PHP_FALIAS(item, dom_nodelist_item, arginfo_dom_nodelist_item) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ length int diff --git a/ext/dom/notation.c b/ext/dom/notation.c index d1b93eb8dbeba..bb3c12f28fdb2 100644 --- a/ext/dom/notation.c +++ b/ext/dom/notation.c @@ -35,7 +35,7 @@ */ const zend_function_entry php_dom_notation_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c index 69f13023a516c..d92e9449de868 100644 --- a/ext/dom/php_dom.c +++ b/ext/dom/php_dom.c @@ -543,7 +543,7 @@ ZEND_END_ARG_INFO() static const zend_function_entry dom_functions[] = { PHP_FE(dom_import_simplexml, arginfo_dom_import_simplexml) - {NULL, NULL, NULL} + PHP_FE_END }; static zend_object_handlers* dom_get_obj_handlers(TSRMLS_D) { diff --git a/ext/dom/processinginstruction.c b/ext/dom/processinginstruction.c index 88ddb3692b7b9..ac59518c59977 100644 --- a/ext/dom/processinginstruction.c +++ b/ext/dom/processinginstruction.c @@ -44,7 +44,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_processinginstruction_class_functions[] = { PHP_ME(domprocessinginstruction, __construct, arginfo_dom_processinginstruction_construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void DOMProcessingInstruction::__construct(string name, [string value]); */ diff --git a/ext/dom/string_extend.c b/ext/dom/string_extend.c index 1cdc261f33216..f2b4623dd3a08 100644 --- a/ext/dom/string_extend.c +++ b/ext/dom/string_extend.c @@ -47,7 +47,7 @@ ZEND_END_ARG_INFO(); const zend_function_entry php_dom_string_extend_class_functions[] = { PHP_FALIAS(findOffset16, dom_string_extend_find_offset16, arginfo_dom_string_extend_find_offset16) PHP_FALIAS(findOffset32, dom_string_extend_find_offset32, arginfo_dom_string_extend_find_offset32) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/text.c b/ext/dom/text.c index d0e599b8f4d0b..b418345cb0778 100644 --- a/ext/dom/text.c +++ b/ext/dom/text.c @@ -58,7 +58,7 @@ const zend_function_entry php_dom_text_class_functions[] = { PHP_FALIAS(isElementContentWhitespace, dom_text_is_whitespace_in_element_content, arginfo_dom_text_is_whitespace_in_element_content) PHP_FALIAS(replaceWholeText, dom_text_replace_whole_text, arginfo_dom_text_replace_whole_text) PHP_ME(domtext, __construct, arginfo_dom_text_construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void DOMText::__construct([string value]); */ diff --git a/ext/dom/typeinfo.c b/ext/dom/typeinfo.c index 275d9d71afbcf..43dc4d1971694 100644 --- a/ext/dom/typeinfo.c +++ b/ext/dom/typeinfo.c @@ -36,7 +36,7 @@ */ const zend_function_entry php_dom_typeinfo_class_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/userdatahandler.c b/ext/dom/userdatahandler.c index 4d6aa1eea5b8f..08f11620f772a 100644 --- a/ext/dom/userdatahandler.c +++ b/ext/dom/userdatahandler.c @@ -37,7 +37,7 @@ const zend_function_entry php_dom_userdatahandler_class_functions[] = { PHP_FALIAS(handle, dom_userdatahandler_handle, NULL) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ attribute protos, not implemented yet */ diff --git a/ext/dom/xpath.c b/ext/dom/xpath.c index 4999770667db7..ba2b972518df0 100644 --- a/ext/dom/xpath.c +++ b/ext/dom/xpath.c @@ -68,7 +68,7 @@ const zend_function_entry php_dom_xpath_class_functions[] = { PHP_FALIAS(query, dom_xpath_query, arginfo_dom_xpath_query) PHP_FALIAS(evaluate, dom_xpath_evaluate, arginfo_dom_xpath_evaluate) PHP_FALIAS(registerPhpFunctions, dom_xpath_register_php_functions, arginfo_dom_xpath_register_php_functions) - {NULL, NULL, NULL} + PHP_FE_END }; diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c index 81404db53aab1..8bbea75f84c96 100755 --- a/ext/enchant/enchant.c +++ b/ext/enchant/enchant.c @@ -146,8 +146,7 @@ zend_function_entry enchant_functions[] = { PHP_FE(enchant_dict_get_error, arginfo_enchant_broker_free_dict) PHP_FE(enchant_dict_describe, arginfo_enchant_broker_free_dict) PHP_FE(enchant_dict_quick_check, arginfo_enchant_dict_quick_check) - - {NULL, NULL, NULL} /* Must be the last line in enchant_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/ereg/ereg.c b/ext/ereg/ereg.c index 1600e46babe44..3fbaa2cc63a5f 100644 --- a/ext/ereg/ereg.c +++ b/ext/ereg/ereg.c @@ -59,7 +59,7 @@ const zend_function_entry ereg_functions[] = { PHP_DEP_FE(split, arginfo_split) PHP_DEP_FE(spliti, arginfo_split) PHP_DEP_FE(sql_regcase, arginfo_sql_regcase) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/exif/exif.c b/ext/exif/exif.c index 48af4d64ddfd7..d7d19eff8eb7c 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -134,7 +134,7 @@ const zend_function_entry exif_functions[] = { PHP_FE(exif_tagname, arginfo_exif_tagname) PHP_FE(exif_thumbnail, arginfo_exif_thumbnail) PHP_FE(exif_imagetype, arginfo_exif_imagetype) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c index 613c043771ef7..3376c5d69bf33 100644 --- a/ext/fileinfo/fileinfo.c +++ b/ext/fileinfo/fileinfo.c @@ -171,7 +171,7 @@ zend_function_entry finfo_class_functions[] = { ZEND_ME_MAPPING(set_flags, finfo_set_flags,arginfo_finfo_method_set_flags, ZEND_ACC_PUBLIC) ZEND_ME_MAPPING(file, finfo_file, arginfo_finfo_method_file, ZEND_ACC_PUBLIC) ZEND_ME_MAPPING(buffer, finfo_buffer, arginfo_finfo_method_buffer, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/filter/filter.c b/ext/filter/filter.c index 6e617190601ab..ebbe0991e9423 100644 --- a/ext/filter/filter.c +++ b/ext/filter/filter.c @@ -128,7 +128,7 @@ static const zend_function_entry filter_functions[] = { PHP_FE(filter_list, arginfo_filter_list) PHP_FE(filter_has_var, arginfo_filter_has_var) PHP_FE(filter_id, arginfo_filter_id) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/ftp/php_ftp.c b/ext/ftp/php_ftp.c index 6c44733fedfc7..ec3f7c7049647 100644 --- a/ext/ftp/php_ftp.c +++ b/ext/ftp/php_ftp.c @@ -278,7 +278,7 @@ const zend_function_entry php_ftp_functions[] = { PHP_FE(ftp_nb_put, arginfo_ftp_nb_put) PHP_FE(ftp_nb_fput, arginfo_ftp_nb_fput) PHP_FALIAS(ftp_quit, ftp_close, arginfo_ftp_close) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry php_ftp_module_entry = { diff --git a/ext/gd/gd.c b/ext/gd/gd.c index 1fe321773c5ef..ed42395c42a23 100644 --- a/ext/gd/gd.c +++ b/ext/gd/gd.c @@ -1065,7 +1065,7 @@ const zend_function_entry gd_functions[] = { PHP_FE(imagefilter, arginfo_imagefilter) PHP_FE(imageconvolution, arginfo_imageconvolution) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/gettext/gettext.c b/ext/gettext/gettext.c index dbdeebd96187e..0daa643d7dbb2 100644 --- a/ext/gettext/gettext.c +++ b/ext/gettext/gettext.c @@ -112,7 +112,7 @@ const zend_function_entry php_gettext_functions[] = { #if HAVE_BIND_TEXTDOMAIN_CODESET PHP_NAMED_FE(bind_textdomain_codeset, zif_bind_textdomain_codeset, arginfo_bind_textdomain_codeset) #endif - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/gmp/gmp.c b/ext/gmp/gmp.c index 039eb46b44436..5f04ef9aa5baa 100644 --- a/ext/gmp/gmp.c +++ b/ext/gmp/gmp.c @@ -280,7 +280,7 @@ const zend_function_entry gmp_functions[] = { ZEND_FE(gmp_popcount, arginfo_gmp_popcount) ZEND_FE(gmp_hamdist, arginfo_gmp_hamdist) ZEND_FE(gmp_nextprime, arginfo_gmp_nextprime) - {NULL, NULL, NULL} /* Must be the last line in gmp_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/hash/hash.c b/ext/hash/hash.c index 1c2d4241c40d8..2a9e54c8bcb5d 100644 --- a/ext/hash/hash.c +++ b/ext/hash/hash.c @@ -1071,7 +1071,7 @@ const zend_function_entry hash_functions[] = { PHP_FE(mhash, arginfo_mhash) #endif - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/iconv/iconv.c b/ext/iconv/iconv.c index a03977b4bd5c9..58e75314230bc 100644 --- a/ext/iconv/iconv.c +++ b/ext/iconv/iconv.c @@ -136,7 +136,7 @@ const zend_function_entry iconv_functions[] = { PHP_FE(iconv_mime_encode, arginfo_iconv_mime_encode) PHP_FE(iconv_mime_decode, arginfo_iconv_mime_decode) PHP_FE(iconv_mime_decode_headers, arginfo_iconv_mime_decode_headers) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index 34fae16763353..9c0ed32dd91e3 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -551,7 +551,7 @@ const zend_function_entry imap_functions[] = { PHP_FALIAS(imap_scan, imap_listscan, arginfo_imap_listscan) PHP_FALIAS(imap_create, imap_createmailbox, arginfo_imap_createmailbox) PHP_FALIAS(imap_rename, imap_renamemailbox, arginfo_imap_renamemailbox) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/interbase/interbase.c b/ext/interbase/interbase.c index bc50175a233ce..1e1440cbd3f80 100644 --- a/ext/interbase/interbase.c +++ b/ext/interbase/interbase.c @@ -441,7 +441,7 @@ const zend_function_entry ibase_functions[] = { PHP_FALIAS(fbird_wait_event, ibase_wait_event, arginfo_ibase_wait_event) PHP_FALIAS(fbird_set_event_handler, ibase_set_event_handler, arginfo_ibase_set_event_handler) PHP_FALIAS(fbird_free_event_handler, ibase_free_event_handler, arginfo_ibase_free_event_handler) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry ibase_module_entry = { diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index 25d93980ef90f..de5226b3d84ba 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -534,7 +534,7 @@ zend_function_entry intl_functions[] = { PHP_FE( intl_is_failure, intl_1_arg ) PHP_FE( intl_error_name, intl_1_arg ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/json/json.c b/ext/json/json.c index 7231e647c3afd..fd8af799c80cd 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -64,7 +64,7 @@ static const zend_function_entry json_functions[] = { PHP_FE(json_encode, arginfo_json_encode) PHP_FE(json_decode, arginfo_json_decode) PHP_FE(json_last_error, arginfo_json_last_error) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c index 790ef6bf545f8..04caa86da7d07 100644 --- a/ext/ldap/ldap.c +++ b/ext/ldap/ldap.c @@ -2712,7 +2712,7 @@ const zend_function_entry ldap_functions[] = { PHP_FE(ldap_control_paged_result, arginfo_ldap_control_paged_result) PHP_FE(ldap_control_paged_result_response, arginfo_ldap_control_paged_result_response) #endif - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index 9518e13cc0a88..25988a6d6014c 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -121,7 +121,7 @@ static const zend_function_entry libxml_functions[] = { PHP_FE(libxml_clear_errors, arginfo_libxml_clear_errors) PHP_FE(libxml_get_errors, arginfo_libxml_get_errors) PHP_FE(libxml_disable_entity_loader, arginfo_libxml_disable_entity_loader) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry libxml_module_entry = { diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index f87b51abf7e90..1600f97252965 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -559,7 +559,7 @@ const zend_function_entry mbstring_functions[] = { #if HAVE_MBREGEX PHP_MBREGEX_FUNCTION_ENTRIES #endif - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c index 609dac1d5fb21..3eaa168c3345d 100644 --- a/ext/mcrypt/mcrypt.c +++ b/ext/mcrypt/mcrypt.c @@ -280,7 +280,7 @@ const zend_function_entry mcrypt_functions[] = { /* {{{ */ PHP_FE(mcrypt_module_get_supported_key_sizes, arginfo_mcrypt_module_get_supported_key_sizes) PHP_FE(mcrypt_module_close, arginfo_mcrypt_module_close) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c index f3af40bc2b2a5..5a8625641360b 100644 --- a/ext/mssql/php_mssql.c +++ b/ext/mssql/php_mssql.c @@ -178,7 +178,7 @@ const zend_function_entry mssql_functions[] = { PHP_FE(mssql_execute, arginfo_mssql_execute) PHP_FE(mssql_free_statement, arginfo_mssql_free_statement) PHP_FE(mssql_guid_string, arginfo_mssql_guid_string) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index cfce37d5d564b..78972c95c1bb4 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -320,7 +320,7 @@ static const zend_function_entry mysql_functions[] = { PHP_FALIAS(mysql_dbname, mysql_result, arginfo_mysql_result) PHP_FALIAS(mysql_tablename, mysql_result, arginfo_mysql_result) PHP_FALIAS(mysql_table_name, mysql_result, arginfo_mysql_result) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c index 6d80c5507c75a..eb133b1a80d9a 100644 --- a/ext/mysqli/mysqli_fe.c +++ b/ext/mysqli/mysqli_fe.c @@ -460,7 +460,7 @@ const zend_function_entry mysqli_functions[] = { PHP_FALIAS(mysqli_escape_string, mysqli_real_escape_string, arginfo_mysqli_query) PHP_FALIAS(mysqli_set_opt, mysqli_options, NULL) - {NULL, NULL, NULL} /* Must be the last line in mysqli_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index c02ae58b4e8ef..1c744cea68317 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -33,7 +33,7 @@ * Every user visible function must have an entry in mysqlnd_functions[]. */ static zend_function_entry mysqlnd_functions[] = { - {NULL, NULL, NULL} /* Must be the last line in mysqlnd_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index 13713d10ea6af..9417dec0d9e97 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -937,7 +937,7 @@ zend_function_entry php_oci_functions[] = { PHP_FALIAS(ocicollsize, oci_collection_size, arginfo_oci_collection_size) PHP_FALIAS(ocicollmax, oci_collection_max, arginfo_oci_collection_max) PHP_FALIAS(ocicolltrim, oci_collection_trim, arginfo_oci_collection_trim) - {NULL,NULL,NULL} + PHP_FE_END }; static @@ -968,7 +968,7 @@ zend_function_entry php_oci_lob_class_functions[] = { PHP_FALIAS(save, oci_lob_save, arginfo_oci_lob_save_method) PHP_FALIAS(savefile, oci_lob_import, arginfo_oci_lob_import_method) PHP_FALIAS(free, oci_free_descriptor, arginfo_oci_free_descriptor_method) - {NULL,NULL,NULL} + PHP_FE_END }; static @@ -985,7 +985,7 @@ zend_function_entry php_oci_coll_class_functions[] = { PHP_FALIAS(max, oci_collection_max, arginfo_oci_collection_max_method) PHP_FALIAS(trim, oci_collection_trim, arginfo_oci_collection_trim_method) PHP_FALIAS(free, oci_free_collection, arginfo_oci_collection_free_method) - {NULL,NULL,NULL} + PHP_FE_END }; zend_module_entry oci8_module_entry = { diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c index 5275a35b451db..52e8f57a0407f 100644 --- a/ext/odbc/php_odbc.c +++ b/ext/odbc/php_odbc.c @@ -383,7 +383,7 @@ const zend_function_entry odbc_functions[] = { #endif PHP_FALIAS(odbc_do, odbc_exec, arginfo_odbc_exec) PHP_FALIAS(odbc_field_precision, odbc_field_len, arginfo_odbc_field_len) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 1f0a79d93639a..89574eab3fd43 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -442,7 +442,7 @@ const zend_function_entry openssl_functions[] = { PHP_FE(openssl_random_pseudo_bytes, arginfo_openssl_random_pseudo_bytes) PHP_FE(openssl_error_string, arginfo_openssl_error_string) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index d2a9130230f9d..f5d4161a9a7fa 100755 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -172,7 +172,7 @@ const zend_function_entry pcntl_functions[] = { PHP_FE(pcntl_sigwaitinfo, arginfo_pcntl_sigwaitinfo) PHP_FE(pcntl_sigtimedwait, arginfo_pcntl_sigtimedwait) #endif - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry pcntl_module_entry = { diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index 5e1a75394f673..27bea79922ac5 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -1894,7 +1894,7 @@ static const zend_function_entry pcre_functions[] = { PHP_FE(preg_quote, arginfo_preg_quote) PHP_FE(preg_grep, arginfo_preg_grep) PHP_FE(preg_last_error, arginfo_preg_last_error) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry pcre_module_entry = { diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c index f83d304dec83f..1604d51858fa4 100755 --- a/ext/pdo/pdo.c +++ b/ext/pdo/pdo.c @@ -125,7 +125,7 @@ ZEND_END_ARG_INFO() /* {{{ pdo_functions[] */ const zend_function_entry pdo_functions[] = { PHP_FE(pdo_drivers, arginfo_pdo_drivers) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pdo_dblib/pdo_dblib.c b/ext/pdo_dblib/pdo_dblib.c index 531a569ecc691..278c1985a1c01 100644 --- a/ext/pdo_dblib/pdo_dblib.c +++ b/ext/pdo_dblib/pdo_dblib.c @@ -36,7 +36,7 @@ ZEND_DECLARE_MODULE_GLOBALS(dblib) static PHP_GINIT_FUNCTION(dblib); const zend_function_entry pdo_dblib_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; #if ZEND_MODULE_API_NO >= 20050922 diff --git a/ext/pdo_firebird/pdo_firebird.c b/ext/pdo_firebird/pdo_firebird.c index a732ff9960757..6459c70364d0d 100644 --- a/ext/pdo_firebird/pdo_firebird.c +++ b/ext/pdo_firebird/pdo_firebird.c @@ -31,7 +31,7 @@ #include "php_pdo_firebird_int.h" const zend_function_entry pdo_firebird_functions[] = { /* {{{ */ - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index 831676fcd2076..5fdab6ba942b7 100755 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -170,7 +170,7 @@ static PHP_GINIT_FUNCTION(pdo_mysql) /* {{{ pdo_mysql_functions[] */ const zend_function_entry pdo_mysql_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pdo_oci/pdo_oci.c b/ext/pdo_oci/pdo_oci.c index 2fbfc318465eb..78539761b7018 100755 --- a/ext/pdo_oci/pdo_oci.c +++ b/ext/pdo_oci/pdo_oci.c @@ -32,7 +32,7 @@ /* {{{ pdo_oci_functions[] */ const zend_function_entry pdo_oci_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pdo_odbc/pdo_odbc.c b/ext/pdo_odbc/pdo_odbc.c index 7611cd485b1bb..69ac263ac7e66 100755 --- a/ext/pdo_odbc/pdo_odbc.c +++ b/ext/pdo_odbc/pdo_odbc.c @@ -32,7 +32,7 @@ /* {{{ pdo_odbc_functions[] */ const zend_function_entry pdo_odbc_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c index 5d3c081680721..aa6df34a2e508 100644 --- a/ext/pdo_pgsql/pgsql_driver.c +++ b/ext/pdo_pgsql/pgsql_driver.c @@ -984,7 +984,7 @@ static const zend_function_entry dbh_methods[] = { PHP_ME(PDO, pgsqlCopyFromFile, NULL, ZEND_ACC_PUBLIC) PHP_ME(PDO, pgsqlCopyToArray, NULL, ZEND_ACC_PUBLIC) PHP_ME(PDO, pgsqlCopyToFile, NULL, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry *pdo_pgsql_get_driver_methods(pdo_dbh_t *dbh, int kind TSRMLS_DC) diff --git a/ext/pdo_sqlite/pdo_sqlite.c b/ext/pdo_sqlite/pdo_sqlite.c index 053ae3bddf5f8..c9a514a41bd84 100644 --- a/ext/pdo_sqlite/pdo_sqlite.c +++ b/ext/pdo_sqlite/pdo_sqlite.c @@ -35,7 +35,7 @@ /* {{{ pdo_sqlite_functions[] */ const zend_function_entry pdo_sqlite_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pdo_sqlite/sqlite_driver.c b/ext/pdo_sqlite/sqlite_driver.c index 0bd77b3c84dc9..71768a31b1fe0 100644 --- a/ext/pdo_sqlite/sqlite_driver.c +++ b/ext/pdo_sqlite/sqlite_driver.c @@ -593,7 +593,7 @@ static PHP_METHOD(SQLite, sqliteCreateAggregate) static const zend_function_entry dbh_methods[] = { PHP_ME(SQLite, sqliteCreateFunction, NULL, ZEND_ACC_PUBLIC) PHP_ME(SQLite, sqliteCreateAggregate, NULL, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry *get_driver_methods(pdo_dbh_t *dbh, int kind TSRMLS_DC) diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c index c2dd8b4a27f9d..a82271776c175 100644 --- a/ext/pgsql/pgsql.c +++ b/ext/pgsql/pgsql.c @@ -697,7 +697,7 @@ const zend_function_entry pgsql_functions[] = { PHP_FALIAS(pg_clientencoding, pg_client_encoding, arginfo_pg_client_encoding) PHP_FALIAS(pg_setclientencoding, pg_set_client_encoding, arginfo_pg_set_client_encoding) #endif - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/phar/phar.c b/ext/phar/phar.c index bf432ac2c2839..c31fd7d070967 100644 --- a/ext/phar/phar.c +++ b/ext/phar/phar.c @@ -3291,7 +3291,7 @@ ZEND_GET_MODULE(phar) * Every user visible function must have an entry in phar_functions[]. */ zend_function_entry phar_functions[] = { - {NULL, NULL, NULL} /* Must be the last line in phar_functions[] */ + PHP_FE_END }; /* }}}*/ diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index 176d660a1cdce..38ef95fbd1ce9 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -5488,7 +5488,7 @@ zend_function_entry php_archive_methods[] = { PHP_ME(Phar, mungServer, arginfo_phar_mungServer, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, unlinkArchive, arginfo_phar_ua, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) PHP_ME(Phar, webPhar, arginfo_phar_webPhar, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC|ZEND_ACC_FINAL) - {NULL, NULL, NULL} + PHP_FE_END }; #if HAVE_SPL @@ -5518,12 +5518,12 @@ zend_function_entry php_entry_methods[] = { PHP_ME(PharFileInfo, isCompressed, arginfo_phar_compo, ZEND_ACC_PUBLIC) PHP_ME(PharFileInfo, isCRCChecked, arginfo_phar__void, ZEND_ACC_PUBLIC) PHP_ME(PharFileInfo, setMetadata, arginfo_phar_setMetadata, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #endif /* HAVE_SPL */ zend_function_entry phar_exception_methods[] = { - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/posix/posix.c b/ext/posix/posix.c index 580911afa651e..be2a4f53ce322 100644 --- a/ext/posix/posix.c +++ b/ext/posix/posix.c @@ -301,7 +301,7 @@ const zend_function_entry posix_functions[] = { PHP_FE(posix_initgroups, arginfo_posix_initgroups) #endif - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/pspell/pspell.c b/ext/pspell/pspell.c index abdded3fd21f9..7e56d77a6b1d3 100644 --- a/ext/pspell/pspell.c +++ b/ext/pspell/pspell.c @@ -198,7 +198,7 @@ static const zend_function_entry pspell_functions[] = { PHP_FE(pspell_config_data_dir, arginfo_pspell_config_data_dir) PHP_FE(pspell_config_repl, arginfo_pspell_config_repl) PHP_FE(pspell_config_save_repl, arginfo_pspell_config_save_repl) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/readline/readline.c b/ext/readline/readline.c index d199cdf51758e..a5d0f7d2bac37 100644 --- a/ext/readline/readline.c +++ b/ext/readline/readline.c @@ -146,7 +146,7 @@ static const zend_function_entry php_readline_functions[] = { PHP_FE(readline_redisplay, arginfo_readline_redisplay) PHP_FE(readline_on_new_line, arginfo_readline_on_new_line) #endif - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry readline_module_entry = { diff --git a/ext/recode/recode.c b/ext/recode/recode.c index 747df23b95a43..5b82b3fd62a80 100644 --- a/ext/recode/recode.c +++ b/ext/recode/recode.c @@ -84,7 +84,7 @@ static const zend_function_entry php_recode_functions[] = { PHP_FE(recode_string, arginfo_recode_string) PHP_FE(recode_file, arginfo_recode_file) PHP_FALIAS(recode, recode_string, arginfo_recode_string) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry recode_module_entry = { diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 850192e84c654..9f770360d306b 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -5485,7 +5485,7 @@ ZEND_METHOD(reflection_zend_extension, getCopyright) /* {{{ method tables */ static const zend_function_entry reflection_exception_functions[] = { - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO(arginfo_reflection__void, 0) @@ -5504,13 +5504,13 @@ ZEND_END_ARG_INFO() static const zend_function_entry reflection_functions[] = { ZEND_ME(reflection, getModifierNames, arginfo_reflection_getModifierNames, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) ZEND_ME(reflection, export, arginfo_reflection_export, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry reflector_functions[] = { ZEND_FENTRY(export, NULL, NULL, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) ZEND_ABSTRACT_ME(reflector, __toString, arginfo_reflection__void) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_reflection_function_export, 0, 0, 1) @@ -5553,7 +5553,7 @@ static const zend_function_entry reflection_function_abstract_functions[] = { ZEND_ME(reflection_function, getStartLine, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getStaticVariables, arginfo_reflection__void, 0) ZEND_ME(reflection_function, returnsReference, arginfo_reflection__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry reflection_function_functions[] = { @@ -5564,7 +5564,7 @@ static const zend_function_entry reflection_function_functions[] = { ZEND_ME(reflection_function, invoke, arginfo_reflection_function_invoke, 0) ZEND_ME(reflection_function, invokeArgs, arginfo_reflection_function_invokeArgs, 0) ZEND_ME(reflection_function, getClosure, arginfo_reflection__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_reflection_method_export, 0, 0, 2) @@ -5615,7 +5615,7 @@ static const zend_function_entry reflection_method_functions[] = { ZEND_ME(reflection_method, getDeclaringClass, arginfo_reflection__void, 0) ZEND_ME(reflection_method, getPrototype, arginfo_reflection__void, 0) ZEND_ME(reflection_property, setAccessible, arginfo_reflection_method_setAccessible, 0) - {NULL, NULL, NULL} + PHP_FE_END }; @@ -5740,7 +5740,7 @@ static const zend_function_entry reflection_class_functions[] = { ZEND_ME(reflection_class, inNamespace, arginfo_reflection__void, 0) ZEND_ME(reflection_class, getNamespaceName, arginfo_reflection__void, 0) ZEND_ME(reflection_class, getShortName, arginfo_reflection__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; @@ -5756,7 +5756,7 @@ ZEND_END_ARG_INFO() static const zend_function_entry reflection_object_functions[] = { ZEND_ME(reflection_object, export, arginfo_reflection_object_export, ZEND_ACC_STATIC|ZEND_ACC_PUBLIC) ZEND_ME(reflection_object, __construct, arginfo_reflection_object___construct, 0) - {NULL, NULL, NULL} + PHP_FE_END }; @@ -5801,7 +5801,7 @@ static const zend_function_entry reflection_property_functions[] = { ZEND_ME(reflection_property, getDeclaringClass, arginfo_reflection__void, 0) ZEND_ME(reflection_property, getDocComment, arginfo_reflection__void, 0) ZEND_ME(reflection_property, setAccessible, arginfo_reflection_property_setAccessible, 0) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_reflection_parameter_export, 0, 0, 2) @@ -5832,7 +5832,7 @@ static const zend_function_entry reflection_parameter_functions[] = { ZEND_ME(reflection_parameter, isOptional, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, isDefaultValueAvailable, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, getDefaultValue, arginfo_reflection__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_reflection_extension_export, 0, 0, 1) @@ -5860,7 +5860,7 @@ static const zend_function_entry reflection_extension_functions[] = { ZEND_ME(reflection_extension, info, arginfo_reflection__void, 0) ZEND_ME(reflection_extension, isPersistent, arginfo_reflection__void, 0) ZEND_ME(reflection_extension, isTemporary, arginfo_reflection__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO(arginfo_reflection_zend_extension___construct, 0) @@ -5877,12 +5877,12 @@ static const zend_function_entry reflection_zend_extension_functions[] = { ZEND_ME(reflection_zend_extension, getAuthor, arginfo_reflection__void, 0) ZEND_ME(reflection_zend_extension, getURL, arginfo_reflection__void, 0) ZEND_ME(reflection_zend_extension, getCopyright, arginfo_reflection__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ const zend_function_entry reflection_ext_functions[] = { /* {{{ */ - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ static zend_object_handlers *zend_std_obj_handlers; diff --git a/ext/session/session.c b/ext/session/session.c index 08449e2b66eed..16528e2d731c5 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -1904,7 +1904,7 @@ static const zend_function_entry session_functions[] = { PHP_FE(session_get_cookie_params, arginfo_session_void) PHP_FE(session_write_close, arginfo_session_void) PHP_FALIAS(session_commit, session_write_close, arginfo_session_void) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/shmop/shmop.c b/ext/shmop/shmop.c index 9d0b0f8ac32ab..1982763a2338e 100644 --- a/ext/shmop/shmop.c +++ b/ext/shmop/shmop.c @@ -87,7 +87,7 @@ const zend_function_entry shmop_functions[] = { PHP_FE(shmop_size, arginfo_shmop_size) PHP_FE(shmop_write, arginfo_shmop_write) PHP_FE(shmop_delete, arginfo_shmop_delete) - {NULL, NULL, NULL} /* Must be the last line in shmop_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index 2ec0ca4ab8ae1..6f4e366108993 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -2546,7 +2546,7 @@ const zend_function_entry simplexml_functions[] = { /* {{{ */ PHP_FE(simplexml_load_file, arginfo_simplexml_load_file) PHP_FE(simplexml_load_string, arginfo_simplexml_load_string) PHP_FE(simplexml_import_dom, arginfo_simplexml_import_dom) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ @@ -2593,7 +2593,7 @@ static const zend_function_entry sxe_functions[] = { /* {{{ */ SXE_ME(addAttribute, arginfo_simplexmlelement_addchild, ZEND_ACC_PUBLIC) SXE_ME(__toString, arginfo_simplexmlelement__void, ZEND_ACC_PUBLIC) SXE_ME(count, arginfo_simplexmlelement__void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/skeleton/skeleton.c b/ext/skeleton/skeleton.c index 42685757da8ad..920354a066021 100644 --- a/ext/skeleton/skeleton.c +++ b/ext/skeleton/skeleton.c @@ -23,7 +23,7 @@ static int le_extname; const zend_function_entry extname_functions[] = { PHP_FE(confirm_extname_compiled, NULL) /* For testing, remove later. */ /* __function_entries_here__ */ - {NULL, NULL, NULL} /* Must be the last line in extname_functions[] */ + PHP_FE_END /* Must be the last line in extname_functions[] */ }; /* }}} */ diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 4f26889c397db..67d6cebe36407 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -410,7 +410,7 @@ const zend_function_entry snmp_functions[] = { PHP_FE(snmp_get_valueretrieval, arginfo_snmp_get_valueretrieval) PHP_FE(snmp_read_mib, arginfo_snmp_read_mib) - {NULL,NULL,NULL} + PHP_FE_END }; /* }}} */ @@ -2276,7 +2276,7 @@ static zend_function_entry php_snmp_class_methods[] = { PHP_ME(snmp, getErrno, arginfo_snmp_void, ZEND_ACC_PUBLIC) PHP_ME(snmp, getError, arginfo_snmp_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #define PHP_SNMP_PROPERTY_ENTRY_RECORD(name) \ diff --git a/ext/soap/soap.c b/ext/soap/soap.c index 89e7204157117..aa6cf65e09a9c 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -377,13 +377,13 @@ ZEND_END_ARG_INFO() static const zend_function_entry soap_functions[] = { PHP_FE(use_soap_error_handler, arginfo_soap_use_soap_error_handler) PHP_FE(is_soap_fault, arginfo_soap_is_soap_fault) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry soap_fault_functions[] = { SOAP_CTOR(SoapFault, SoapFault, arginfo_soapfault_soapfault, 0) PHP_ME(SoapFault, __toString, arginfo_soap__void, 0) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry soap_server_functions[] = { @@ -396,7 +396,7 @@ static const zend_function_entry soap_server_functions[] = { PHP_ME(SoapServer, handle, arginfo_soapserver_handle, 0) PHP_ME(SoapServer, fault, arginfo_soapserver_fault, 0) PHP_ME(SoapServer, addSoapHeader, arginfo_soapserver_addsoapheader, 0) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry soap_client_functions[] = { @@ -413,22 +413,22 @@ static const zend_function_entry soap_client_functions[] = { PHP_ME(SoapClient, __setCookie, arginfo_soapclient___setcookie, 0) PHP_ME(SoapClient, __setLocation, arginfo_soapclient___setlocation, 0) PHP_ME(SoapClient, __setSoapHeaders, arginfo_soapclient___setsoapheaders, 0) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry soap_var_functions[] = { SOAP_CTOR(SoapVar, SoapVar, arginfo_soapvar_soapvar, 0) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry soap_param_functions[] = { SOAP_CTOR(SoapParam, SoapParam, arginfo_soapparam_soapparam, 0) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry soap_header_functions[] = { SOAP_CTOR(SoapHeader, SoapHeader, arginfo_soapheader_soapheader, 0) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry soap_module_entry = { diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 6b5631c9fbd8f..9c034a3f27708 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -314,7 +314,7 @@ const zend_function_entry sockets_functions[] = { PHP_FALIAS(socket_getopt, socket_get_option, arginfo_socket_get_option) PHP_FALIAS(socket_setopt, socket_set_option, arginfo_socket_set_option) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/spl/php_spl.c b/ext/spl/php_spl.c index 8b49b6c5e1b24..5caa4c9825378 100755 --- a/ext/spl/php_spl.c +++ b/ext/spl/php_spl.c @@ -1012,14 +1012,14 @@ const zend_function_entry spl_functions[] = { PHP_FE(spl_autoload_call, arginfo_spl_autoload_call) PHP_FE(class_parents, arginfo_class_parents) PHP_FE(class_implements, arginfo_class_implements) - PHP_FE(class_uses, arginfo_class_uses) + PHP_FE(class_uses, arginfo_class_uses) PHP_FE(spl_object_hash, arginfo_spl_object_hash) #ifdef SPL_ITERATORS_H PHP_FE(iterator_to_array, arginfo_iterator_to_array) PHP_FE(iterator_count, arginfo_iterator) PHP_FE(iterator_apply, arginfo_iterator_apply) #endif /* SPL_ITERATORS_H */ - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/spl/spl_array.c b/ext/spl/spl_array.c index ed87df36ca762..a4eecedfd61a7 100755 --- a/ext/spl/spl_array.c +++ b/ext/spl/spl_array.c @@ -1861,7 +1861,7 @@ static const zend_function_entry spl_funcs_ArrayObject[] = { SPL_ME(Array, exchangeArray, arginfo_array_exchangeArray, ZEND_ACC_PUBLIC) SPL_ME(Array, setIteratorClass, arginfo_array_setIteratorClass, ZEND_ACC_PUBLIC) SPL_ME(Array, getIteratorClass, arginfo_array_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry spl_funcs_ArrayIterator[] = { @@ -1890,13 +1890,13 @@ static const zend_function_entry spl_funcs_ArrayIterator[] = { SPL_ME(Array, next, arginfo_array_void, ZEND_ACC_PUBLIC) SPL_ME(Array, valid, arginfo_array_void, ZEND_ACC_PUBLIC) SPL_ME(Array, seek, arginfo_array_seek, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry spl_funcs_RecursiveArrayIterator[] = { SPL_ME(Array, hasChildren, arginfo_array_void, ZEND_ACC_PUBLIC) SPL_ME(Array, getChildren, arginfo_array_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 3c7055097541e..81de56c7ce556 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -1918,7 +1918,7 @@ static const zend_function_entry spl_SplFileInfo_functions[] = { SPL_ME(SplFileInfo, setFileClass, arginfo_info_optinalFileClass, ZEND_ACC_PUBLIC) SPL_ME(SplFileInfo, setInfoClass, arginfo_info_optinalFileClass, ZEND_ACC_PUBLIC) SPL_MA(SplFileInfo, __toString, SplFileInfo, getPathname, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO(arginfo_dir___construct, 0) @@ -1944,7 +1944,7 @@ static const zend_function_entry spl_DirectoryIterator_functions[] = { SPL_ME(DirectoryIterator, next, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) SPL_ME(DirectoryIterator, seek, arginfo_dir_it_seek, ZEND_ACC_PUBLIC) SPL_MA(DirectoryIterator, __toString, DirectoryIterator, getFilename, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_r_dir___construct, 0, 0, 1) @@ -1968,7 +1968,7 @@ static const zend_function_entry spl_FilesystemIterator_functions[] = { SPL_ME(FilesystemIterator, current, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) SPL_ME(FilesystemIterator, getFlags, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) SPL_ME(FilesystemIterator, setFlags, arginfo_r_dir_setFlags, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry spl_RecursiveDirectoryIterator_functions[] = { @@ -1977,14 +1977,14 @@ static const zend_function_entry spl_RecursiveDirectoryIterator_functions[] = { SPL_ME(RecursiveDirectoryIterator, getChildren, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveDirectoryIterator, getSubPath, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveDirectoryIterator, getSubPathname,arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #ifdef HAVE_GLOB static const zend_function_entry spl_GlobIterator_functions[] = { SPL_ME(GlobIterator, __construct, arginfo_r_dir___construct, ZEND_ACC_PUBLIC) SPL_ME(GlobIterator, count, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #endif /* }}} */ @@ -2928,7 +2928,7 @@ static const zend_function_entry spl_SplFileObject_functions[] = { /* mappings */ SPL_MA(SplFileObject, getCurrentLine, SplFileObject, fgets, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) SPL_MA(SplFileObject, __toString, SplFileObject, current, arginfo_splfileinfo_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_temp_file_object___construct, 0, 0, 0) @@ -2937,7 +2937,7 @@ ZEND_END_ARG_INFO() static const zend_function_entry spl_SplTempFileObject_functions[] = { SPL_ME(SplTempFileObject, __construct, arginfo_temp_file_object___construct, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/spl/spl_dllist.c b/ext/spl/spl_dllist.c index 06d22e1b619e6..5d8ff80d819e3 100644 --- a/ext/spl/spl_dllist.c +++ b/ext/spl/spl_dllist.c @@ -1302,7 +1302,7 @@ ZEND_END_ARG_INFO(); static const zend_function_entry spl_funcs_SplQueue[] = { SPL_MA(SplQueue, enqueue, SplDoublyLinkedList, push, arginfo_dllist_push, ZEND_ACC_PUBLIC) SPL_MA(SplQueue, dequeue, SplDoublyLinkedList, shift, arginfo_dllist_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry spl_funcs_SplDoublyLinkedList[] = { @@ -1332,7 +1332,7 @@ static const zend_function_entry spl_funcs_SplDoublyLinkedList[] = { /* Serializable */ SPL_ME(SplDoublyLinkedList, unserialize, arginfo_dllist_serialized, ZEND_ACC_PUBLIC) SPL_ME(SplDoublyLinkedList, serialize, arginfo_dllist_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c index 89c4130bdf6ae..c49528e89fbd2 100644 --- a/ext/spl/spl_fixedarray.c +++ b/ext/spl/spl_fixedarray.c @@ -1073,7 +1073,7 @@ static zend_function_entry spl_funcs_SplFixedArray[] = { /* {{{ */ SPL_ME(SplFixedArray, key, arginfo_splfixedarray_void, ZEND_ACC_PUBLIC) SPL_ME(SplFixedArray, next, arginfo_splfixedarray_void, ZEND_ACC_PUBLIC) SPL_ME(SplFixedArray, valid, arginfo_splfixedarray_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index e062486731517..57f3d5200fbdc 100755 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -69,7 +69,7 @@ ZEND_END_ARG_INFO() const zend_function_entry spl_funcs_RecursiveIterator[] = { SPL_ABSTRACT_ME(RecursiveIterator, hasChildren, arginfo_recursive_it_void) SPL_ABSTRACT_ME(RecursiveIterator, getChildren, arginfo_recursive_it_void) - {NULL, NULL, NULL} + PHP_FE_END }; typedef enum { @@ -990,7 +990,7 @@ static const zend_function_entry spl_funcs_RecursiveIteratorIterator[] = { SPL_ME(RecursiveIteratorIterator, nextElement, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveIteratorIterator, setMaxDepth, arginfo_recursive_it_setMaxDepth, ZEND_ACC_PUBLIC) SPL_ME(RecursiveIteratorIterator, getMaxDepth, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static void spl_recursive_tree_iterator_get_prefix(spl_recursive_it_object *object, zval *return_value TSRMLS_DC) @@ -1268,7 +1268,7 @@ static const zend_function_entry spl_funcs_RecursiveTreeIterator[] = { SPL_ME(RecursiveTreeIterator, setPrefixPart, arginfo_recursive_tree_it_setPrefixPart, ZEND_ACC_PUBLIC) SPL_ME(RecursiveTreeIterator, getEntry, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveTreeIterator, getPostfix, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #if MBO_0 @@ -2306,7 +2306,7 @@ static const zend_function_entry spl_funcs_FilterIterator[] = { SPL_ME(FilterIterator, next, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(dual_it, getInnerIterator, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ABSTRACT_ME(FilterIterator, accept, arginfo_recursive_it_void) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO(arginfo_callback_filter_it___construct, 0) @@ -2317,7 +2317,7 @@ ZEND_END_ARG_INFO(); static const zend_function_entry spl_funcs_CallbackFilterIterator[] = { SPL_ME(CallbackFilterIterator, __construct, arginfo_callback_filter_it___construct, ZEND_ACC_PUBLIC) SPL_ME(CallbackFilterIterator, accept, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO(arginfo_recursive_callback_filter_it___construct, 0) @@ -2329,7 +2329,7 @@ static const zend_function_entry spl_funcs_RecursiveCallbackFilterIterator[] = { SPL_ME(RecursiveCallbackFilterIterator, __construct, arginfo_recursive_callback_filter_it___construct, ZEND_ACC_PUBLIC) SPL_ME(RecursiveFilterIterator, hasChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveCallbackFilterIterator, getChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO(arginfo_parent_it___construct, 0) @@ -2340,13 +2340,13 @@ static const zend_function_entry spl_funcs_RecursiveFilterIterator[] = { SPL_ME(RecursiveFilterIterator, __construct, arginfo_parent_it___construct, ZEND_ACC_PUBLIC) SPL_ME(RecursiveFilterIterator, hasChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveFilterIterator, getChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry spl_funcs_ParentIterator[] = { SPL_ME(ParentIterator, __construct, arginfo_parent_it___construct, ZEND_ACC_PUBLIC) SPL_MA(ParentIterator, accept, RecursiveFilterIterator, hasChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #if HAVE_PCRE || HAVE_BUNDLED_PCRE @@ -2380,7 +2380,7 @@ static const zend_function_entry spl_funcs_RegexIterator[] = { SPL_ME(RegexIterator, getPregFlags, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RegexIterator, setPregFlags, arginfo_regex_it_set_preg_flags, ZEND_ACC_PUBLIC) SPL_ME(RegexIterator, getRegex, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_rec_regex_it___construct, 0, 0, 2) @@ -2395,7 +2395,7 @@ static const zend_function_entry spl_funcs_RecursiveRegexIterator[] = { SPL_ME(RecursiveRegexIterator, __construct, arginfo_rec_regex_it___construct, ZEND_ACC_PUBLIC) SPL_ME(RecursiveFilterIterator, hasChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveRegexIterator, getChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; #endif @@ -2524,7 +2524,7 @@ ZEND_END_ARG_INFO(); static const zend_function_entry spl_funcs_SeekableIterator[] = { SPL_ABSTRACT_ME(SeekableIterator, seek, arginfo_seekable_it_seek) - {NULL, NULL, NULL} + PHP_FE_END }; ZEND_BEGIN_ARG_INFO_EX(arginfo_limit_it___construct, 0, 0, 1) @@ -2547,7 +2547,7 @@ static const zend_function_entry spl_funcs_LimitIterator[] = { SPL_ME(LimitIterator, seek, arginfo_limit_it_seek, ZEND_ACC_PUBLIC) SPL_ME(LimitIterator, getPosition, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(dual_it, getInnerIterator, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; static inline int spl_caching_it_valid(spl_dual_it_object *intern TSRMLS_DC) @@ -2978,7 +2978,7 @@ static const zend_function_entry spl_funcs_CachingIterator[] = { SPL_ME(CachingIterator, offsetExists, arginfo_caching_it_offsetGet, ZEND_ACC_PUBLIC) SPL_ME(CachingIterator, getCache, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(CachingIterator, count, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void RecursiveCachingIterator::__construct(RecursiveIterator it [, flags = CIT_CALL_TOSTRING]) @@ -3031,7 +3031,7 @@ static const zend_function_entry spl_funcs_RecursiveCachingIterator[] = { SPL_ME(RecursiveCachingIterator, __construct, arginfo_caching_rec_it___construct, ZEND_ACC_PUBLIC) SPL_ME(RecursiveCachingIterator, hasChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(RecursiveCachingIterator, getChildren, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void IteratorIterator::__construct(Traversable it) @@ -3053,7 +3053,7 @@ static const zend_function_entry spl_funcs_IteratorIterator[] = { SPL_ME(dual_it, current, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(dual_it, next, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(dual_it, getInnerIterator, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void NoRewindIterator::__construct(Iterator it) @@ -3162,7 +3162,7 @@ static const zend_function_entry spl_funcs_NoRewindIterator[] = { SPL_ME(NoRewindIterator, current, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(NoRewindIterator, next, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(dual_it, getInnerIterator, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void InfiniteIterator::__construct(Iterator it) @@ -3198,7 +3198,7 @@ SPL_METHOD(InfiniteIterator, next) static const zend_function_entry spl_funcs_InfiniteIterator[] = { SPL_ME(InfiniteIterator, __construct, arginfo_norewind_it___construct, ZEND_ACC_PUBLIC) SPL_ME(InfiniteIterator, next, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ proto void EmptyIterator::rewind() @@ -3255,7 +3255,7 @@ static const zend_function_entry spl_funcs_EmptyIterator[] = { SPL_ME(EmptyIterator, key, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(EmptyIterator, current, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(EmptyIterator, next, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; int spl_append_it_next_iterator(spl_dual_it_object *intern TSRMLS_DC) /* {{{*/ @@ -3432,7 +3432,7 @@ static const zend_function_entry spl_funcs_AppendIterator[] = { SPL_ME(dual_it, getInnerIterator, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(AppendIterator, getIteratorIndex, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) SPL_ME(AppendIterator, getArrayIterator, arginfo_recursive_it_void, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; PHPAPI int spl_iterator_apply(zval *obj, spl_iterator_apply_func_t apply_func, void *puser TSRMLS_DC) @@ -3624,12 +3624,12 @@ PHP_FUNCTION(iterator_apply) static const zend_function_entry spl_funcs_OuterIterator[] = { SPL_ABSTRACT_ME(OuterIterator, getInnerIterator, arginfo_recursive_it_void) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry spl_funcs_Countable[] = { SPL_ABSTRACT_ME(Countable, count, arginfo_recursive_it_void) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ PHP_MINIT_FUNCTION(spl_iterators) diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c index 9c922414b877b..a4f35aeeb793e 100644 --- a/ext/sqlite3/sqlite3.c +++ b/ext/sqlite3/sqlite3.c @@ -1813,7 +1813,7 @@ static zend_function_entry php_sqlite3_class_methods[] = { PHP_ME(sqlite3, enableExceptions, argingo_sqlite3_enableexceptions, ZEND_ACC_PUBLIC) /* Aliases */ PHP_MALIAS(sqlite3, __construct, open, arginfo_sqlite3_open, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ @@ -1828,7 +1828,7 @@ static zend_function_entry php_sqlite3_stmt_class_methods[] = { PHP_ME(sqlite3stmt, bindValue, arginfo_sqlite3stmt_bindvalue, ZEND_ACC_PUBLIC) PHP_ME(sqlite3stmt, readOnly, arginfo_sqlite3_void, ZEND_ACC_PUBLIC) PHP_ME(sqlite3stmt, __construct, arginfo_sqlite3stmt_construct, ZEND_ACC_PRIVATE|ZEND_ACC_CTOR) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ @@ -1841,7 +1841,7 @@ static zend_function_entry php_sqlite3_result_class_methods[] = { PHP_ME(sqlite3result, reset, arginfo_sqlite3_void, ZEND_ACC_PUBLIC) PHP_ME(sqlite3result, finalize, arginfo_sqlite3_void, ZEND_ACC_PUBLIC) PHP_ME(sqlite3result, __construct, arginfo_sqlite3_void, ZEND_ACC_PRIVATE|ZEND_ACC_CTOR) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 48c4fccdbf22e..a83b8db3a6099 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -3377,7 +3377,7 @@ const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(sys_get_temp_dir, arginfo_sys_get_temp_dir) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index c07cdcd7e626c..3c8b7bd223a4b 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -204,7 +204,7 @@ const zend_function_entry sybase_functions[] = { PHP_FALIAS(mssql_set_message_handler, sybase_set_message_handler, arginfo_sybase_set_message_handler) PHP_FALIAS(mssql_deadlock_retry_count, sybase_deadlock_retry_count, arginfo_sybase_deadlock_retry_count) #endif - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry sybase_module_entry = { diff --git a/ext/sysvmsg/sysvmsg.c b/ext/sysvmsg/sysvmsg.c index 048a89f694e1e..d2b93eb4ef46b 100644 --- a/ext/sysvmsg/sysvmsg.c +++ b/ext/sysvmsg/sysvmsg.c @@ -95,7 +95,7 @@ const zend_function_entry sysvmsg_functions[] = { PHP_FE(msg_stat_queue, arginfo_msg_stat_queue) PHP_FE(msg_set_queue, arginfo_msg_set_queue) PHP_FE(msg_queue_exists, arginfo_msg_queue_exists) - {NULL, NULL, NULL} /* Must be the last line in sysvmsg_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/sysvsem/sysvsem.c b/ext/sysvsem/sysvsem.c index c19a47b9fcdde..67ac97d564d55 100644 --- a/ext/sysvsem/sysvsem.c +++ b/ext/sysvsem/sysvsem.c @@ -84,7 +84,7 @@ const zend_function_entry sysvsem_functions[] = { PHP_FE(sem_acquire, arginfo_sem_acquire) PHP_FE(sem_release, arginfo_sem_release) PHP_FE(sem_remove, arginfo_sem_remove) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/sysvshm/sysvshm.c b/ext/sysvshm/sysvshm.c index 0c910fe077337..33b1070325a6e 100644 --- a/ext/sysvshm/sysvshm.c +++ b/ext/sysvshm/sysvshm.c @@ -86,7 +86,7 @@ const zend_function_entry sysvshm_functions[] = { PHP_FE(shm_has_var, arginfo_shm_has_var) PHP_FE(shm_get_var, arginfo_shm_get_var) PHP_FE(shm_remove_var, arginfo_shm_remove_var) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/tidy/tidy.c b/ext/tidy/tidy.c index 2b859683f3d2d..1ba910c9578ec 100644 --- a/ext/tidy/tidy.c +++ b/ext/tidy/tidy.c @@ -400,7 +400,7 @@ static const zend_function_entry tidy_functions[] = { PHP_FE(tidy_get_head, arginfo_tidy_get_head) PHP_FE(tidy_get_html, arginfo_tidy_get_html) PHP_FE(tidy_get_body, arginfo_tidy_get_body) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry tidy_funcs_doc[] = { @@ -425,7 +425,7 @@ static const zend_function_entry tidy_funcs_doc[] = { TIDY_METHOD_MAP(html, tidy_get_html, NULL) TIDY_METHOD_MAP(body, tidy_get_body, NULL) TIDY_DOC_ME(__construct, NULL) - {NULL, NULL, NULL} + PHP_FE_END }; static const zend_function_entry tidy_funcs_node[] = { @@ -439,7 +439,7 @@ static const zend_function_entry tidy_funcs_node[] = { TIDY_NODE_ME(isPhp, NULL) TIDY_NODE_ME(getParent, NULL) TIDY_NODE_PRIVATE_ME(__construct, NULL) - {NULL, NULL, NULL} + PHP_FE_END }; static zend_class_entry *tidy_ce_doc, *tidy_ce_node; diff --git a/ext/tokenizer/tokenizer.c b/ext/tokenizer/tokenizer.c index add3168f7c0c5..c6c901f352262 100644 --- a/ext/tokenizer/tokenizer.c +++ b/ext/tokenizer/tokenizer.c @@ -52,7 +52,7 @@ ZEND_END_ARG_INFO() const zend_function_entry tokenizer_functions[] = { PHP_FE(token_get_all, arginfo_token_get_all) PHP_FE(token_name, arginfo_token_name) - {NULL, NULL, NULL} /* Must be the last line in tokenizer_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/wddx/wddx.c b/ext/wddx/wddx.c index 477793cb5ee98..13345017a0617 100644 --- a/ext/wddx/wddx.c +++ b/ext/wddx/wddx.c @@ -141,7 +141,7 @@ const zend_function_entry wddx_functions[] = { PHP_FE(wddx_packet_end, arginfo_wddx_packet_end) PHP_FE(wddx_add_vars, arginfo_wddx_add_vars) PHP_FE(wddx_deserialize, arginfo_wddx_deserialize) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/xml/xml.c b/ext/xml/xml.c index e9c3a6ad914b5..d7d2d7df41343 100644 --- a/ext/xml/xml.c +++ b/ext/xml/xml.c @@ -238,7 +238,7 @@ const zend_function_entry xml_functions[] = { PHP_FE(xml_parser_get_option, arginfo_xml_parser_get_option) PHP_FE(utf8_encode, arginfo_utf8_encode) PHP_FE(utf8_decode, arginfo_utf8_decode) - {NULL, NULL, NULL} + PHP_FE_END }; #ifdef LIBXML_EXPAT_COMPAT diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c index 83d8f5ca8da23..f875896026ef9 100644 --- a/ext/xmlreader/php_xmlreader.c +++ b/ext/xmlreader/php_xmlreader.c @@ -1306,7 +1306,7 @@ static const zend_function_entry xmlreader_functions[] = { PHP_ME(xmlreader, setRelaxNGSchemaSource, arginfo_xmlreader_setRelaxNGSchemaSource, ZEND_ACC_PUBLIC) PHP_ME(xmlreader, XML, arginfo_xmlreader_XML, ZEND_ACC_PUBLIC|ZEND_ACC_ALLOW_STATIC) PHP_ME(xmlreader, expand, arginfo_xmlreader_expand, ZEND_ACC_PUBLIC) - {NULL, NULL, NULL} + PHP_FE_END }; /* {{{ PHP_MINIT_FUNCTION diff --git a/ext/xmlrpc/xmlrpc-epi-php.c b/ext/xmlrpc/xmlrpc-epi-php.c index f3d144818a3c0..87c93e220a092 100644 --- a/ext/xmlrpc/xmlrpc-epi-php.c +++ b/ext/xmlrpc/xmlrpc-epi-php.c @@ -158,7 +158,7 @@ const zend_function_entry xmlrpc_functions[] = { PHP_FE(xmlrpc_parse_method_descriptions, arginfo_xmlrpc_parse_method_descriptions) PHP_FE(xmlrpc_server_add_introspection_data, arginfo_xmlrpc_server_add_introspection_data) PHP_FE(xmlrpc_server_register_introspection_callback, arginfo_xmlrpc_server_register_introspection_callback) - {NULL, NULL, NULL} + PHP_FE_END }; zend_module_entry xmlrpc_module_entry = { diff --git a/ext/xmlwriter/php_xmlwriter.c b/ext/xmlwriter/php_xmlwriter.c index c0609fb10898a..4ea895374eeb8 100644 --- a/ext/xmlwriter/php_xmlwriter.c +++ b/ext/xmlwriter/php_xmlwriter.c @@ -526,7 +526,7 @@ static const zend_function_entry xmlwriter_functions[] = { #endif PHP_FE(xmlwriter_output_memory, arginfo_xmlwriter_output_memory) PHP_FE(xmlwriter_flush, arginfo_xmlwriter_flush) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/xsl/php_xsl.c b/ext/xsl/php_xsl.c index 13ed910b5d454..896c28596c1f9 100644 --- a/ext/xsl/php_xsl.c +++ b/ext/xsl/php_xsl.c @@ -35,7 +35,7 @@ static zend_object_handlers xsl_object_handlers; * Every user visible function must have an entry in xsl_functions[]. */ const zend_function_entry xsl_functions[] = { - {NULL, NULL, NULL} /* Must be the last line in xsl_functions[] */ + PHP_FE_END }; /* }}} */ diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index 3aa3988e8e1dc..d13757403c432 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -781,8 +781,7 @@ static const zend_function_entry zip_functions[] = { PHP_FE(zip_entry_name, arginfo_zip_entry_name) PHP_FE(zip_entry_compressedsize, arginfo_zip_entry_compressedsize) PHP_FE(zip_entry_compressionmethod, arginfo_zip_entry_compressionmethod) - - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 0f61bfde91a69..b5300fc334c9f 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -737,7 +737,7 @@ static const zend_function_entry php_zlib_functions[] = { PHP_FE(zlib_encode, arginfo_zlib_encode) PHP_FE(zlib_decode, arginfo_zlib_decode) PHP_FE(zlib_get_coding_type, arginfo_zlib_get_coding_type) - {NULL, NULL, NULL} + PHP_FE_END }; /* }}} */ From ed1d46aac4bab404b041aa3af1353dfa68572879 Mon Sep 17 00:00:00 2001 From: Popa Adrian Marius Date: Mon, 25 Jul 2011 11:41:06 +0000 Subject: [PATCH 0381/2394] fix ident --- ext/interbase/tests/003.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/interbase/tests/003.phpt b/ext/interbase/tests/003.phpt index 0263010b0236f..38959332d2a7d 100644 --- a/ext/interbase/tests/003.phpt +++ b/ext/interbase/tests/003.phpt @@ -21,7 +21,7 @@ InterBase: misc sql types (may take a while) v_numeric15_0 numeric(15,0), v_double double precision, v_float float, - v_integer integer, + v_integer integer, v_smallint smallint, v_varchar varchar(10000) )"); From 28461a5f3ce24758cf93fb46a4e0255a6d15bf14 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 25 Jul 2011 11:50:10 +0000 Subject: [PATCH 0382/2394] - Use ZEND_FE_END macro here --- Zend/zend_builtin_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index a81e9a8283f9d..a5fd7108ffaa8 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -306,7 +306,7 @@ static const zend_function_entry builtin_functions[] = { /* {{{ */ ZEND_FE(gc_enabled, arginfo_zend__void) ZEND_FE(gc_enable, arginfo_zend__void) ZEND_FE(gc_disable, arginfo_zend__void) - { NULL, NULL, NULL } + ZEND_FE_END }; /* }}} */ From 06f18d8cca75cc469287a4a3c3d978e05c6a4022 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 25 Jul 2011 11:51:43 +0000 Subject: [PATCH 0383/2394] - Fix compiler warning --- Zend/zend_builtin_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index a5fd7108ffaa8..c4917ecac277a 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1215,7 +1215,7 @@ ZEND_FUNCTION(class_exists) found = zend_hash_find(EG(class_table), name, len+1, (void **) &ce); free_alloca(lc_name, use_heap); - RETURN_BOOL(found == SUCCESS && !((*ce)->ce_flags & (ZEND_ACC_INTERFACE | ZEND_ACC_TRAIT) > ZEND_ACC_EXPLICIT_ABSTRACT_CLASS)); + RETURN_BOOL(found == SUCCESS && !(((*ce)->ce_flags & (ZEND_ACC_INTERFACE | ZEND_ACC_TRAIT)) > ZEND_ACC_EXPLICIT_ABSTRACT_CLASS)); } if (zend_lookup_class(class_name, class_name_len, &ce TSRMLS_CC) == SUCCESS) { From 44bdf8aab1e5eb7172218826e86f9866f2070e4b Mon Sep 17 00:00:00 2001 From: Popa Adrian Marius Date: Mon, 25 Jul 2011 13:04:22 +0000 Subject: [PATCH 0384/2394] Replace FIELD with CONSTANT (that is the alias returned in Firebird stable 2.5.x ) --- ext/interbase/tests/003.phpt | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/ext/interbase/tests/003.phpt b/ext/interbase/tests/003.phpt index 38959332d2a7d..652e3bdc52a12 100644 --- a/ext/interbase/tests/003.phpt +++ b/ext/interbase/tests/003.phpt @@ -157,27 +157,27 @@ array(22) { int(10) ["ID_10"]=> int(11) - ["FIELD_00"]=> + ["CONSTANT"]=> int(12) - ["FIELD_01"]=> + ["CONSTANT_01"]=> int(13) - ["FIELD_02"]=> + ["CONSTANT_02"]=> int(14) - ["FIELD_03"]=> + ["CONSTANT_03"]=> int(15) - ["FIELD_04"]=> + ["CONSTANT_04"]=> int(16) - ["FIELD_05"]=> + ["CONSTANT_05"]=> int(17) - ["FIELD_06"]=> + ["CONSTANT_06"]=> int(18) - ["FIELD_07"]=> + ["CONSTANT_07"]=> int(19) - ["FIELD_08"]=> + ["CONSTANT_08"]=> int(20) - ["FIELD_09"]=> + ["CONSTANT_09"]=> int(21) - ["FIELD_10"]=> + ["CONSTANT_10"]=> int(22) } end of test From 43db3374052f5bf191f51a65c433f55e3e88c37a Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 25 Jul 2011 14:53:01 +0000 Subject: [PATCH 0385/2394] Test update. 5.4+ throws a catchable fatal error, 5.3 does not. --- ext/mysqli/tests/connect.inc | 18 +++++++++++- ext/mysqli/tests/mysqli_fetch_object.phpt | 29 +++++++++---------- ext/mysqli/tests/mysqli_fetch_object_oo.phpt | 30 +++++++++++--------- 3 files changed, 48 insertions(+), 29 deletions(-) diff --git a/ext/mysqli/tests/connect.inc b/ext/mysqli/tests/connect.inc index 6c6c48b5fcdc5..f32592f43d25f 100644 --- a/ext/mysqli/tests/connect.inc +++ b/ext/mysqli/tests/connect.inc @@ -225,4 +225,20 @@ } else { printf("skip Eeeek/BUG/FIXME - connect.inc included twice! skipif bug?\n"); } -?> \ No newline at end of file + + function handle_catchable_fatal($errno, $error, $file, $line) { + static $errcodes = array(); + if (empty($errcodes)) { + $constants = get_defined_constants(); + foreach ($constants as $name => $value) { + if (substr($name, 0, 2) == "E_") + $errcodes[$value] = $name; + } + } + printf("[%s] %s in %s on line %s\n", + (isset($errcodes[$errno])) ? $errcodes[$errno] : $errno, + $error, $file, $line); + + return true; + } +?> diff --git a/ext/mysqli/tests/mysqli_fetch_object.phpt b/ext/mysqli/tests/mysqli_fetch_object.phpt index f164c4e19bb5a..c70871e6ea919 100644 --- a/ext/mysqli/tests/mysqli_fetch_object.phpt +++ b/ext/mysqli/tests/mysqli_fetch_object.phpt @@ -10,6 +10,8 @@ require_once('skipifconnectfailure.inc'); ID !== "3") || ($obj->label !== "c") || ($obj->a !== NULL) || ($obj->b !== NULL) || (get_class($obj) != 'mysqli_fetch_object_construct')) { printf("[006] Object seems wrong. [%d] %s\n", mysqli_errno($link), mysqli_error($link)); @@ -97,7 +99,7 @@ require_once('skipifconnectfailure.inc'); Also, I did not ask to get exceptions using the mysqli_options() */ try { - if (false !== ($obj = mysqli_fetch_object($res, 'mysqli_fetch_object_construct', 'a'))) + if (false !== ($obj = @mysqli_fetch_object($res, 'mysqli_fetch_object_construct', 'a'))) printf("[011] Should have failed\n"); } catch (Exception $e) { printf("%s\n", $e->getMessage()); @@ -136,22 +138,19 @@ require_once('skipifconnectfailure.inc'); require_once("clean_table.inc"); ?> --EXPECTF-- -Warning: Missing argument 1 for mysqli_fetch_object_construct::__construct() in %s on line %d - -Warning: Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d - -Notice: Undefined variable: a in %s on line %d - -Notice: Undefined variable: b in %s on line %d - -Warning: Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d - -Notice: Undefined variable: b in %s on line %d +[E_WARNING] mysqli_fetch_object() expects at least 1 parameter, 0 given in %s on line %d +[E_WARNING] mysqli_fetch_object() expects parameter 1 to be mysqli_result, null given in %s on line %d +[E_WARNING] Missing argument 1 for mysqli_fetch_object_construct::__construct() in %s on line %d +[E_WARNING] Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d +[E_NOTICE] Undefined variable: a in %s on line %d +[E_NOTICE] Undefined variable: b in %s on line %d +[E_WARNING] Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d +[E_NOTICE] Undefined variable: b in %s on line %d NULL NULL - -Warning: mysqli_fetch_object(): Couldn't fetch mysqli_result in %s on line %d +[E_WARNING] mysqli_fetch_object(): Couldn't fetch mysqli_result in %s on line %d NULL +[E_RECOVERABLE_ERROR] Argument 3 passed to mysqli_fetch_object() must be of the type array, string given in %s on line %d Parameter ctor_params must be an array Fatal error: Class 'this_class_does_not_exist' not found in %s on line %d \ No newline at end of file diff --git a/ext/mysqli/tests/mysqli_fetch_object_oo.phpt b/ext/mysqli/tests/mysqli_fetch_object_oo.phpt index 3b263e49e4a0e..1d62c6dd4f05c 100644 --- a/ext/mysqli/tests/mysqli_fetch_object_oo.phpt +++ b/ext/mysqli/tests/mysqli_fetch_object_oo.phpt @@ -9,6 +9,7 @@ require_once('skipifconnectfailure.inc'); --FILE-- --EXPECTF-- -Warning: Missing argument 1 for mysqli_fetch_object_construct::__construct() in %s on line %d - -Warning: Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d - -Notice: Undefined variable: a in %s on line %d - -Notice: Undefined variable: b in %s on line %d - -Warning: Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d - -Notice: Undefined variable: b in %s on line %d +[E_WARNING] mysqli_result::__construct(): invalid object or resource mysql%s +%s on line %d +[E_WARNING] mysqli_result::fetch_object(): Couldn't fetch mysqli_result in %s on line %d +[E_WARNING] mysqli_result::fetch_object() expects parameter 1 to be string, object given in %s on line %d +[E_RECOVERABLE_ERROR] Argument 2 passed to mysqli_result::fetch_object() must be of the type array, object given in %s on line %d +[E_WARNING] mysqli_result::fetch_object() expects parameter 1 to be string, object given in %s on line %d +[E_RECOVERABLE_ERROR] Argument 2 passed to mysqli_result::fetch_object() must be of the type array, object given in %s on line %d +[E_WARNING] mysqli_result::fetch_object() expects at most 2 parameters, 3 given in %s on line %d +[E_RECOVERABLE_ERROR] Argument 2 passed to mysqli_result::fetch_object() must be of the type array, null given in %s on line %d +[E_WARNING] Missing argument 1 for mysqli_fetch_object_construct::__construct() in %s on line %d +[E_WARNING] Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d +[E_NOTICE] Undefined variable: a in %s on line %d +[E_NOTICE] Undefined variable: b in %s on line %d +[E_WARNING] Missing argument 2 for mysqli_fetch_object_construct::__construct() in %s on line %d +[E_NOTICE] Undefined variable: b in %s on line %d NULL NULL - -Warning: mysqli_fetch_object(): Couldn't fetch mysqli_result in %s on line %d +[E_WARNING] mysqli_fetch_object(): Couldn't fetch mysqli_result in %s on line %d NULL Fatal error: Class 'this_class_does_not_exist' not found in %s on line %d \ No newline at end of file From 658d0d66fd30ee034c6e9b90f6a74d20116f0144 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 25 Jul 2011 15:07:54 +0000 Subject: [PATCH 0386/2394] Test update. 5.4+ is more verbose. --- .../mysqli_class_mysqli_result_reflection.phpt | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt index 7d2e0c30b7e11..988b82732a5c2 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt @@ -234,9 +234,23 @@ isInternal: yes isUserDefined: no returnsReference: no Modifiers: 256 -Number of Parameters: 0 +Number of Parameters: 2 Number of Required Parameters: 0 +Inspecting parameter 'class_name' of method 'fetch_object' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + +Inspecting parameter 'params' of method 'fetch_object' +isArray: yes +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + Inspecting method 'fetch_row' isFinal: no isAbstract: no From a06539a10d1ca6f83804115ce34b27b25ea77b8a Mon Sep 17 00:00:00 2001 From: Florian Anderiasch Date: Mon, 25 Jul 2011 16:45:39 +0000 Subject: [PATCH 0387/2394] Fix #55121 Segfault with multipart/form-data POST --- sapi/cli/php_cli_server.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 7b549cea7e1f5..0c5fb9cd1f691 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1409,8 +1409,9 @@ static void php_cli_server_client_populate_request_info(const php_cli_server_cli request_info->content_length = request_info->post_data_length = client->request.content_len; { char **val; + const char delimiter[] = ";"; if (SUCCESS == zend_hash_find(&client->request.headers, "Content-Type", sizeof("Content-Type"), (void**)&val)) { - request_info->content_type = *val; + request_info->content_type = strtok(*val, delimiter); } } } /* }}} */ From 090bfcdfe197165ba3dd7125d4ef48866fc769a7 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 25 Jul 2011 16:50:07 +0000 Subject: [PATCH 0388/2394] - add expand_filepath_with_mode (not used anywhere yet but will be used for file ops (fopen&co) to avoid extra links resolution and other non required ops on open --- UPGRADING.INTERNALS | 4 ++++ main/fopen_wrappers.c | 10 +++++++++- main/fopen_wrappers.h | 1 + 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index a230a4db26156..e9d0adf5541f6 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -11,6 +11,7 @@ UPGRADE NOTES - PHP X.Y f. streams that enclose private streams g. leak_variable h. API Signature changes + i. new TSRM function expand_filepath_with_mode 2. Build system changes a. Unix build system changes @@ -184,6 +185,9 @@ it increments the refcounts of those objects instead. . php_unescape_html_entities PHPAPI char *php_unescape_html_entities(unsigned char *old, size_t oldlen, size_t *newlen, int all, int flags, char *hint_charset TSRMLS_DC); + i. + PHPAPI char *expand_filepath_with_mode(const char *filepath, char *real_path, const char *relative_to, size_t relative_to_len, int realpath_mode TSRMLS_DC); + expand_filepath_with_mode lets define how realpath will behave, using one of the existing mode: CWD_EXPAND , CWD_FILEPATH or CWD_REALPATH. ======================== 2. Build system changes diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c index 812d591767b21..8766aaf893997 100644 --- a/main/fopen_wrappers.c +++ b/main/fopen_wrappers.c @@ -740,6 +740,14 @@ PHPAPI char *expand_filepath(const char *filepath, char *real_path TSRMLS_DC) /* {{{ expand_filepath_ex */ PHPAPI char *expand_filepath_ex(const char *filepath, char *real_path, const char *relative_to, size_t relative_to_len TSRMLS_DC) +{ + return expand_filepath_with_mode(filepath, real_path, relative_to, relative_to_len, CWD_FILEPATH TSRMLS_CC); +} +/* }}} */ + +/* {{{ expand_filepath_use_realpath + */ +PHPAPI char *expand_filepath_with_mode(const char *filepath, char *real_path, const char *relative_to, size_t relative_to_len, int realpath_mode TSRMLS_DC) { cwd_state new_state; char cwd[MAXPATHLEN]; @@ -785,7 +793,7 @@ PHPAPI char *expand_filepath_ex(const char *filepath, char *real_path, const cha new_state.cwd = strdup(cwd); new_state.cwd_length = strlen(cwd); - if (virtual_file_ex(&new_state, filepath, NULL, CWD_FILEPATH TSRMLS_CC)) { + if (virtual_file_ex(&new_state, filepath, NULL, realpath_mode TSRMLS_CC)) { free(new_state.cwd); return NULL; } diff --git a/main/fopen_wrappers.h b/main/fopen_wrappers.h index 842780a1b2102..0f4ff94a8509b 100644 --- a/main/fopen_wrappers.h +++ b/main/fopen_wrappers.h @@ -28,6 +28,7 @@ BEGIN_EXTERN_C() PHPAPI int php_fopen_primary_script(zend_file_handle *file_handle TSRMLS_DC); PHPAPI char *expand_filepath(const char *filepath, char *real_path TSRMLS_DC); PHPAPI char *expand_filepath_ex(const char *filepath, char *real_path, const char *relative_to, size_t relative_to_len TSRMLS_DC); +PHPAPI char *expand_filepath_with_mode(const char *filepath, char *real_path, const char *relative_to, size_t relative_to_len, int use_realpath TSRMLS_DC); PHPAPI int php_check_open_basedir(const char *path TSRMLS_DC); PHPAPI int php_check_open_basedir_ex(const char *path, int warn TSRMLS_DC); From 9b32facc32a92a265c7b833d8061c2bcd3d9f1b8 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Mon, 25 Jul 2011 17:22:48 +0000 Subject: [PATCH 0389/2394] Update skipif --- ext/oci8/tests/xmltype_02.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/oci8/tests/xmltype_02.phpt b/ext/oci8/tests/xmltype_02.phpt index 83b4123067d4d..5ac294102e962 100644 --- a/ext/oci8/tests/xmltype_02.phpt +++ b/ext/oci8/tests/xmltype_02.phpt @@ -4,6 +4,7 @@ Basic XMLType test #2 true, 'timesten' => false); // test runs on these DBs require(dirname(__FILE__).'/skipif.inc'); +if (!extension_loaded("simplexml")) die ("skip no simplexml extension"); ?> --FILE-- Date: Mon, 25 Jul 2011 17:25:47 +0000 Subject: [PATCH 0390/2394] Remove old testname. This file now diverges from PHP_5_3 --- ext/oci8/package.xml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/oci8/package.xml b/ext/oci8/package.xml index 0bb6eb532bf34..22c05c6ab6035 100644 --- a/ext/oci8/package.xml +++ b/ext/oci8/package.xml @@ -33,7 +33,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> no - 2011-06-10 + 2011-07-25 @@ -338,7 +338,6 @@ http://pear.php.net/dtd/package-2.0.xsd"> - From f4e6769e87cb43e736bd6c86add51dc8bd8cddb8 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Mon, 25 Jul 2011 17:30:09 +0000 Subject: [PATCH 0391/2394] Patch r313663 and r313665 to allow PECL builds to work with earlier releases --- ext/oci8/oci8.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index 9417dec0d9e97..4512c1f848fcd 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -937,7 +937,11 @@ zend_function_entry php_oci_functions[] = { PHP_FALIAS(ocicollsize, oci_collection_size, arginfo_oci_collection_size) PHP_FALIAS(ocicollmax, oci_collection_max, arginfo_oci_collection_max) PHP_FALIAS(ocicolltrim, oci_collection_trim, arginfo_oci_collection_trim) +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION == 3 && PHP_RELEASE_VERSION >= 7) || (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION >= 4) || (PHP_MAJOR_VERSION > 5) PHP_FE_END +#else + {NULL,NULL,NULL} +#endif }; static @@ -968,7 +972,11 @@ zend_function_entry php_oci_lob_class_functions[] = { PHP_FALIAS(save, oci_lob_save, arginfo_oci_lob_save_method) PHP_FALIAS(savefile, oci_lob_import, arginfo_oci_lob_import_method) PHP_FALIAS(free, oci_free_descriptor, arginfo_oci_free_descriptor_method) +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION == 3 && PHP_RELEASE_VERSION >= 7) || (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION >= 4) || (PHP_MAJOR_VERSION > 5) PHP_FE_END +#else + {NULL,NULL,NULL} +#endif }; static @@ -985,7 +993,11 @@ zend_function_entry php_oci_coll_class_functions[] = { PHP_FALIAS(max, oci_collection_max, arginfo_oci_collection_max_method) PHP_FALIAS(trim, oci_collection_trim, arginfo_oci_collection_trim_method) PHP_FALIAS(free, oci_free_collection, arginfo_oci_collection_free_method) +#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION == 3 && PHP_RELEASE_VERSION >= 7) || (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION >= 4) || (PHP_MAJOR_VERSION > 5) PHP_FE_END +#else + {NULL,NULL,NULL} +#endif }; zend_module_entry oci8_module_entry = { From d1763936e2f094d3bf9dc64336bd48da5e20ce97 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Mon, 25 Jul 2011 23:40:57 +0000 Subject: [PATCH 0392/2394] Fix cast warning seen on some platforms --- ext/oci8/oci8.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index 4512c1f848fcd..d5abe1b9de498 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -37,6 +37,13 @@ #include "php_ini.h" #include "ext/standard/php_smart_str.h" +#ifdef HAVE_STDINT_H +#include +#endif +#ifdef PHP_WIN32 +#include "win32/php_stdint.h" +#endif + #if HAVE_OCI8 #if PHP_MAJOR_VERSION > 5 @@ -51,6 +58,14 @@ #include "php_oci8_int.h" #include "zend_hash.h" +#if defined(HAVE_STDINT_H) || defined(PHP_WIN32) +#define OCI8_INT_TO_PTR(I) ((void *)(intptr_t)(I)) +#define OCI8_PTR_TO_INT(P) ((int)(intptr_t)(P)) +#else +#define OCI8_INT_TO_PTR(I) ((void *)(I)) +#define OCI8_PTR_TO_INT(P) ((int)(P)) +#endif + ZEND_DECLARE_MODULE_GLOBALS(oci) #if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 1) || (PHP_MAJOR_VERSION > 5) /* This "if" allows PECL builds from this file to be portable to older PHP releases */ @@ -1877,7 +1892,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char int type, link; void *ptr; - link = (int) le->ptr; + link = OCI8_PTR_TO_INT(le->ptr); ptr = zend_list_find(link,&type); if (ptr && (type == le_connection)) { connection = (php_oci_connection *)ptr; @@ -2116,7 +2131,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char #else connection->rsrc_id = zend_list_insert(connection, le_connection); #endif - new_le.ptr = (void *)connection->rsrc_id; + new_le.ptr = OCI8_INT_TO_PTR(connection->rsrc_id); new_le.type = le_index_ptr; zend_hash_update(&EG(regular_list), connection->hash_key, strlen(connection->hash_key)+1, (void *)&new_le, sizeof(zend_rsrc_list_entry), NULL); OCI_G(num_links)++; From 438cc3e255b0a9f6b8b40ea0e5268f7b15a96d63 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 26 Jul 2011 07:30:41 +0000 Subject: [PATCH 0393/2394] - use cwd_expand now --- ext/spl/spl_directory.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 81de56c7ce556..21986e171be5d 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -1219,10 +1219,7 @@ SPL_METHOD(SplFileInfo, getLinkTarget) #if defined(PHP_WIN32) || HAVE_SYMLINK if (!IS_ABSOLUTE_PATH(intern->file_name, intern->file_name_len)) { char expanded_path[MAXPATHLEN]; - - /* TODO: Fix expand_filepath to do not resolve links but only expand the path - (Pierre) */ - if (!expand_filepath(intern->file_name, expanded_path TSRMLS_CC)) { + if (!expand_filepath_with_mode(intern->file_name, expanded_path, NULL, 0, CWD_EXPAND TSRMLS_CC)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "No such file or directory"); RETURN_FALSE; } From 4cbca588f7637686f94d58141423895347b12e5d Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 26 Jul 2011 09:27:53 +0000 Subject: [PATCH 0394/2394] - simplify --- main/fopen_wrappers.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c index 8766aaf893997..2c18044b33432 100644 --- a/main/fopen_wrappers.c +++ b/main/fopen_wrappers.c @@ -628,16 +628,11 @@ PHPAPI FILE *php_fopen_with_path(const char *filename, const char *mode, const c filename_length = strlen(filename); /* Relative path open */ - if (*filename == '.') { - return php_fopen_and_set_opened_path(filename, mode, opened_path TSRMLS_CC); - } - + if ((*filename == '.') /* Absolute path open */ - if (IS_ABSOLUTE_PATH(filename, filename_length)) { - return php_fopen_and_set_opened_path(filename, mode, opened_path TSRMLS_CC); - } - - if (!path || (path && !*path)) { + || IS_ABSOLUTE_PATH(filename, filename_length) + || (!path || (path && !*path)) + ) { return php_fopen_and_set_opened_path(filename, mode, opened_path TSRMLS_CC); } From ff58394fd689d288270f2b45ae4736fcdf308123 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 26 Jul 2011 09:30:49 +0000 Subject: [PATCH 0395/2394] Fix mysqlnd detection --- ext/pdo_mysql/tests/mysql_pdo_test.inc | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/pdo_mysql/tests/mysql_pdo_test.inc b/ext/pdo_mysql/tests/mysql_pdo_test.inc index a3ffd5b9ccb38..0af2e6df65f03 100644 --- a/ext/pdo_mysql/tests/mysql_pdo_test.inc +++ b/ext/pdo_mysql/tests/mysql_pdo_test.inc @@ -155,6 +155,7 @@ class MySQLPDOTest extends PDOTest { phpinfo(); $tmp = ob_get_contents(); ob_end_clean(); + $tmp = stristr($tmp, "PDO Driver for MySQL => enabled"); return (bool)preg_match('/Client API version.*mysqlnd/', $tmp); } From 63ebb307305d4cdc91dc88d0665ee3360acaaa08 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 26 Jul 2011 09:33:01 +0000 Subject: [PATCH 0396/2394] Would be nice if tests get updated whenever a feature is added by the person adding the feature... --- ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt index 9200d7bbd4e80..e99385799f8ca 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt @@ -15,13 +15,18 @@ require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); 'MYSQL_ATTR_FOUND_ROWS' => true, 'MYSQL_ATTR_IGNORE_SPACE' => true, 'MYSQL_ATTR_INIT_COMMAND' => true, + "MYSQL_ATTR_SSL_KEY" => true, + "MYSQL_ATTR_SSL_CERT" => true, + "MYSQL_ATTR_SSL_CA" => true, + "MYSQL_ATTR_SSL_CAPATH" => true, + "MYSQL_ATTR_SSL_CIPHER" => true, ); if (!MySQLPDOTest::isPDOMySQLnd()) { - $expected['MYSQL_ATTR_MAX_BUFFER_SIZE'] = true; - $expected['MYSQL_ATTR_READ_DEFAULT_FILE'] = true; - $expected['MYSQL_ATTR_READ_DEFAULT_GROUP'] = true; - $expected['MYSQL_ATTR_COMPRESS'] = true; + $expected['MYSQL_ATTR_MAX_BUFFER_SIZE'] = true; + $expected['MYSQL_ATTR_READ_DEFAULT_FILE'] = true; + $expected['MYSQL_ATTR_READ_DEFAULT_GROUP'] = true; + $expected['MYSQL_ATTR_COMPRESS'] = true; } /* From 8e3de07b4fa6a1b54efaa18b211be1530fdcbde6 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 26 Jul 2011 15:37:59 +0000 Subject: [PATCH 0397/2394] Check what happens if switching DB via API fails. Expected: no change of current DB/schema. --- ext/mysqli/tests/mysqli_select_db.phpt | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/tests/mysqli_select_db.phpt b/ext/mysqli/tests/mysqli_select_db.phpt index d700a2b557bdc..b44487b24eef0 100644 --- a/ext/mysqli/tests/mysqli_select_db.phpt +++ b/ext/mysqli/tests/mysqli_select_db.phpt @@ -55,15 +55,33 @@ require_once('skipifconnectfailure.inc'); mysqli_free_result($res); } - mysqli_report(MYSQLI_REPORT_OFF); + if (!$res = mysqli_query($link, "SELECT DATABASE() AS dbname")) + printf("[012] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + + if (!$row = mysqli_fetch_assoc($res)) + printf("[013] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + + $current_db = $row['dbname']; + + mysqli_report(MYSQLI_REPORT_OFF); mysqli_select_db($link, 'I can not imagine that this database exists'); mysqli_report(MYSQLI_REPORT_ERROR); mysqli_select_db($link, 'I can not imagine that this database exists'); + if (!$res = mysqli_query($link, "SELECT DATABASE() AS dbname")) + printf("[014] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + + if (!$row = mysqli_fetch_assoc($res)) + printf("[015] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + + if (strtolower($row['dbname']) != strtolower($current_db)) + printf("[016] Current DB should not change if set fails\n"); + + mysqli_close($link); if (NULL !== ($tmp = mysqli_select_db($link, $db))) - printf("[012] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp); + printf("[017] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp); print "done!\n"; ?> From 498aaae6d86f9b32c4da160bd50cb5962a0b8617 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 26 Jul 2011 16:14:59 +0000 Subject: [PATCH 0398/2394] Double check if line is sill usable and connected to last successfully selected db. --- ext/mysqli/tests/mysqli_select_db.phpt | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/ext/mysqli/tests/mysqli_select_db.phpt b/ext/mysqli/tests/mysqli_select_db.phpt index b44487b24eef0..7527a1313b506 100644 --- a/ext/mysqli/tests/mysqli_select_db.phpt +++ b/ext/mysqli/tests/mysqli_select_db.phpt @@ -9,6 +9,7 @@ require_once('skipifconnectfailure.inc'); --FILE-- select_db($db)) + printf("[012] Failed to set '%s' as current DB; [%d] %s\n", $link->errno, $link->error); + if (!$res = mysqli_query($link, "SELECT DATABASE() AS dbname")) - printf("[012] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + printf("[013] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!$row = mysqli_fetch_assoc($res)) - printf("[013] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + printf("[014] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); $current_db = $row['dbname']; @@ -69,14 +73,20 @@ require_once('skipifconnectfailure.inc'); mysqli_select_db($link, 'I can not imagine that this database exists'); if (!$res = mysqli_query($link, "SELECT DATABASE() AS dbname")) - printf("[014] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + printf("[015] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!$row = mysqli_fetch_assoc($res)) - printf("[015] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + printf("[016] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (strtolower($row['dbname']) != strtolower($current_db)) - printf("[016] Current DB should not change if set fails\n"); + printf("[017] Current DB should not change if set fails\n"); + + + if (!$res = $link->query("SELECT id FROM test WHERE id = 1")) + printf("[018] [%d] %s\n"); + $row = $res->fetch_assoc(); + $res->free(); mysqli_close($link); @@ -85,6 +95,8 @@ require_once('skipifconnectfailure.inc'); print "done!\n"; ?> +--CLEAN-- + --EXPECTF-- Warning: mysqli_select_db(): (%d/%d): Unknown database '%s' in %s on line %d From fc8afdf178d5672e74e67683e21404bc31f361fc Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 26 Jul 2011 17:44:20 +0000 Subject: [PATCH 0399/2394] - Fixed bug 55124, recursive mkdir fails with current (dot) directory in path --- ext/standard/tests/file/bug55124.phpt | 18 ++++++++++++++++++ main/streams/plain_wrapper.c | 21 +++++++-------------- 2 files changed, 25 insertions(+), 14 deletions(-) create mode 100644 ext/standard/tests/file/bug55124.phpt diff --git a/ext/standard/tests/file/bug55124.phpt b/ext/standard/tests/file/bug55124.phpt new file mode 100644 index 0000000000000..892d4508d898f --- /dev/null +++ b/ext/standard/tests/file/bug55124.phpt @@ -0,0 +1,18 @@ +--TEST-- +Bug #55124 (recursive mkdir fails with current (dot) directory in path) +--FILE-- + +--EXPECT-- +OK diff --git a/main/streams/plain_wrapper.c b/main/streams/plain_wrapper.c index 041a0e34e2e65..8303adb5b1208 100644 --- a/main/streams/plain_wrapper.c +++ b/main/streams/plain_wrapper.c @@ -1147,24 +1147,18 @@ static int php_plain_files_mkdir(php_stream_wrapper *wrapper, char *dir, int mod ret = php_mkdir(dir, mode TSRMLS_CC); } else { /* we look for directory separator from the end of string, thus hopefuly reducing our work load */ - char *e, *buf; + char *e; struct stat sb; int dir_len = strlen(dir); int offset = 0; + char buf[MAXPATHLEN]; - buf = estrndup(dir, dir_len); - -#ifdef PHP_WIN32 - e = buf; - while (*e) { - if (*e == '/') { - *e = DEFAULT_SLASH; - } - e++; + if (!expand_filepath_with_mode(dir, buf, NULL, 0, CWD_EXPAND TSRMLS_CC)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid path"); + return 0; } -#else - e = buf + dir_len; -#endif + + e = buf + strlen(buf); if ((p = memchr(buf, DEFAULT_SLASH, dir_len))) { offset = p - buf + 1; @@ -1216,7 +1210,6 @@ static int php_plain_files_mkdir(php_stream_wrapper *wrapper, char *dir, int mod } } } - efree(buf); } if (ret < 0) { /* Failure */ From 97913140b57a2777757f4982bac3e65d68547f44 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 26 Jul 2011 23:49:37 +0000 Subject: [PATCH 0400/2394] Fix #55269 (--enable-dtrace fail on FreeBSD) --- acinclude.m4 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/acinclude.m4 b/acinclude.m4 index bf9a4493247b4..89d6c6f27b2ff 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2923,6 +2923,10 @@ dnl header-file dnl Add providerdesc.o into global objects when needed case $host_alias in + *freebsd*) + PHP_GLOBAL_OBJS="[$]PHP_GLOBAL_OBJS [$]ac_bdir[$]ac_provsrc.o" + PHP_LDFLAGS="$PHP_LDFLAGS -lelf" + ;; *solaris*) PHP_GLOBAL_OBJS="[$]PHP_GLOBAL_OBJS [$]ac_bdir[$]ac_provsrc.o" ;; From 823d7a0534c3eaec7c8f6ff4889240df77baa58e Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Wed, 27 Jul 2011 00:04:23 +0000 Subject: [PATCH 0401/2394] Add explicit casts to remove some of Pierre's snapshot build warnings --- ext/oci8/oci8_lob.c | 6 +++--- ext/oci8/oci8_statement.c | 2 +- ext/oci8/php_oci8_int.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/oci8/oci8_lob.c b/ext/oci8/oci8_lob.c index 0169583347dbe..c55e0d6077042 100644 --- a/ext/oci8/oci8_lob.c +++ b/ext/oci8/oci8_lob.c @@ -893,7 +893,7 @@ int php_oci_lob_is_equal (php_oci_descriptor *descriptor_first, php_oci_descript /* {{{ php_oci_lob_write_tmp() Create temporary LOB and write data to it */ -int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, ub1 type, char *data, int data_len TSRMLS_DC) +int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, long type, char *data, int data_len TSRMLS_DC) { php_oci_connection *connection = descriptor->connection; OCILobLocator *lob = descriptor->descriptor; @@ -905,7 +905,7 @@ int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, ub1 type, char *data, /* only these two are allowed */ break; default: - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid temporary lob type: %d", type); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid temporary lob type: %ld", type); return 1; break; } @@ -921,7 +921,7 @@ int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, ub1 type, char *data, lob, OCI_DEFAULT, OCI_DEFAULT, - type, + (ub1)type, OCI_ATTR_NOCACHE, OCI_DURATION_SESSION ) diff --git a/ext/oci8/oci8_statement.c b/ext/oci8/oci8_statement.c index bc836241805ec..b74b94e2a2e4b 100644 --- a/ext/oci8/oci8_statement.c +++ b/ext/oci8/oci8_statement.c @@ -1480,7 +1480,7 @@ int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int nam name_len, (dvoid *) bindp->array.elements, (sb4) bind->array.max_length, - type, + (ub2)type, (dvoid *)bindp->array.indicators, (ub2 *)bind->array.element_lengths, (ub2 *)0, /* bindp->array.retcodes, */ diff --git a/ext/oci8/php_oci8_int.h b/ext/oci8/php_oci8_int.h index ba45260673f35..bef0fb9268f0d 100644 --- a/ext/oci8/php_oci8_int.h +++ b/ext/oci8/php_oci8_int.h @@ -405,7 +405,7 @@ int php_oci_lob_get_buffering (php_oci_descriptor *); int php_oci_lob_copy (php_oci_descriptor *, php_oci_descriptor *, long TSRMLS_DC); int php_oci_lob_close (php_oci_descriptor * TSRMLS_DC); int php_oci_temp_lob_close (php_oci_descriptor * TSRMLS_DC); -int php_oci_lob_write_tmp (php_oci_descriptor *, ub1, char *, int TSRMLS_DC); +int php_oci_lob_write_tmp (php_oci_descriptor *, long, char *, int TSRMLS_DC); void php_oci_lob_free(php_oci_descriptor * TSRMLS_DC); int php_oci_lob_import(php_oci_descriptor *descriptor, char * TSRMLS_DC); int php_oci_lob_append (php_oci_descriptor *, php_oci_descriptor * TSRMLS_DC); From 4d0f1bfeb437c8f4c5b3513f14225d5e0a48b756 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 00:14:02 +0000 Subject: [PATCH 0402/2394] - add binary suport, FR #50638, as defined in RFC https://wiki.php.net/rfc/binnotation4ints, patch by Jonah Harris --- Zend/zend_language_scanner.c | 4562 +++++++++++++++-------------- Zend/zend_language_scanner.l | 23 +- Zend/zend_language_scanner_defs.h | 2 +- Zend/zend_strtod.c | 38 + Zend/zend_strtod.h | 1 + 5 files changed, 2378 insertions(+), 2248 deletions(-) diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index bdbae58f7edd5..c3dc70a55f273 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Fri Jul 22 13:16:46 2011 */ +/* Generated by re2c 0.13.5 on Wed Jul 27 02:06:14 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1083,7 +1083,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1712 "Zend/zend_language_scanner.l" +#line 1733 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1161,7 +1161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1700 "Zend/zend_language_scanner.l" +#line 1721 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1180,7 +1180,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1677 "Zend/zend_language_scanner.l" +#line 1698 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1378,7 +1378,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1637 "Zend/zend_language_scanner.l" +#line 1658 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1422,7 +1422,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1655 "Zend/zend_language_scanner.l" +#line 1676 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1440,7 +1440,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1668 "Zend/zend_language_scanner.l" +#line 1689 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1475,7 +1475,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1690 "Zend/zend_language_scanner.l" +#line 1711 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1555,7 +1555,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2163 "Zend/zend_language_scanner.l" +#line 2184 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1607,7 +1607,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2107 "Zend/zend_language_scanner.l" +#line 2128 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; @@ -1622,7 +1622,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2094 "Zend/zend_language_scanner.l" +#line 2115 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1645,7 +1645,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1794 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1657,7 +1657,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(67, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1430 "Zend/zend_language_scanner.l" +#line 1431 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -1676,7 +1676,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1786 "Zend/zend_language_scanner.l" +#line 1807 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1702,7 +1702,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1776 "Zend/zend_language_scanner.l" +#line 1797 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1778,7 +1778,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2113 "Zend/zend_language_scanner.l" +#line 2134 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1838,7 +1838,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2102 "Zend/zend_language_scanner.l" +#line 2123 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; @@ -1853,7 +1853,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2094 "Zend/zend_language_scanner.l" +#line 2115 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1876,7 +1876,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1794 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1888,7 +1888,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(89, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1430 "Zend/zend_language_scanner.l" +#line 1431 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -1907,7 +1907,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1786 "Zend/zend_language_scanner.l" +#line 1807 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1933,7 +1933,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1776 "Zend/zend_language_scanner.l" +#line 1797 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1952,7 +1952,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2081 "Zend/zend_language_scanner.l" +#line 2102 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -2026,7 +2026,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2205 "Zend/zend_language_scanner.l" +#line 2226 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2112,7 +2112,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2094 "Zend/zend_language_scanner.l" +#line 2115 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -2135,7 +2135,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1794 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -2147,7 +2147,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(113, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1430 "Zend/zend_language_scanner.l" +#line 1431 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -2166,7 +2166,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1786 "Zend/zend_language_scanner.l" +#line 1807 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2192,7 +2192,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1776 "Zend/zend_language_scanner.l" +#line 1797 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2212,32 +2212,32 @@ int lex_scan(zval *zendlval TSRMLS_DC) 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 56, 56, 56, 56, 56, 56, 56, 56, - 56, 56, 0, 0, 0, 0, 0, 0, - 0, 40, 40, 40, 40, 40, 40, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 0, 0, 0, 0, 8, - 0, 40, 40, 40, 40, 40, 40, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 0, 0, 0, 0, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, - 8, 8, 8, 8, 8, 8, 8, 8, + 60, 60, 44, 44, 44, 44, 44, 44, + 44, 44, 0, 0, 0, 0, 0, 0, + 0, 36, 36, 36, 36, 36, 36, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 0, 0, 0, 0, 4, + 0, 36, 36, 36, 36, 36, 36, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 0, 0, 0, 0, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, }; YYDEBUG(121, *YYCURSOR); YYFILL(16); @@ -2365,23 +2365,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(-1, yych); switch ((yych = *YYCURSOR)) { case 'C': - case 'c': goto yy707; + case 'c': goto yy711; case 'L': - case 'l': goto yy708; + case 'l': goto yy712; case 'M': - case 'm': goto yy709; + case 'm': goto yy713; case 'N': - case 'n': goto yy710; + case 'n': goto yy714; case 'V': - case 'v': goto yy711; + case 'v': goto yy715; case 'X': - case 'x': goto yy712; + case 'x': goto yy716; default: goto yy186; } yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1817 "Zend/zend_language_scanner.l" +#line 1838 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -2393,20 +2393,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'H') { - if (yych == 'E') goto yy689; + if (yych == 'E') goto yy693; goto yy186; } else { - if (yych <= 'I') goto yy690; + if (yych <= 'I') goto yy694; if (yych <= 'N') goto yy186; - goto yy691; + goto yy695; } } else { if (yych <= 'h') { - if (yych == 'e') goto yy689; + if (yych == 'e') goto yy693; goto yy186; } else { - if (yych <= 'i') goto yy690; - if (yych == 'o') goto yy691; + if (yych <= 'i') goto yy694; + if (yych == 'o') goto yy695; goto yy186; } } @@ -2415,20 +2415,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'U') { if (yych <= 'N') { - if (yych == 'I') goto yy668; + if (yych == 'I') goto yy672; goto yy186; } else { - if (yych <= 'O') goto yy669; + if (yych <= 'O') goto yy673; if (yych <= 'T') goto yy186; - goto yy670; + goto yy674; } } else { if (yych <= 'n') { - if (yych == 'i') goto yy668; + if (yych == 'i') goto yy672; goto yy186; } else { - if (yych <= 'o') goto yy669; - if (yych == 'u') goto yy670; + if (yych <= 'o') goto yy673; + if (yych == 'u') goto yy674; goto yy186; } } @@ -2437,42 +2437,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'K') { - if (yych == 'A') goto yy640; + if (yych == 'A') goto yy644; goto yy186; } else { - if (yych <= 'L') goto yy641; + if (yych <= 'L') goto yy645; if (yych <= 'N') goto yy186; - goto yy642; + goto yy646; } } else { if (yych <= 'k') { - if (yych == 'a') goto yy640; + if (yych == 'a') goto yy644; goto yy186; } else { - if (yych <= 'l') goto yy641; - if (yych == 'o') goto yy642; + if (yych <= 'l') goto yy645; + if (yych == 'o') goto yy646; goto yy186; } } yy128: YYDEBUG(128, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy622; - if (yych == 'e') goto yy622; + if (yych == 'E') goto yy626; + if (yych == 'e') goto yy626; goto yy186; yy129: YYDEBUG(129, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'R') { - if (yych == 'H') goto yy610; + if (yych == 'H') goto yy614; if (yych <= 'Q') goto yy186; - goto yy611; + goto yy615; } else { if (yych <= 'h') { if (yych <= 'g') goto yy186; - goto yy610; + goto yy614; } else { - if (yych == 'r') goto yy611; + if (yych == 'r') goto yy615; goto yy186; } } @@ -2481,53 +2481,53 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'S') { if (yych <= 'L') { - if (yych == 'F') goto yy557; + if (yych == 'F') goto yy561; goto yy186; } else { - if (yych <= 'M') goto yy559; - if (yych <= 'N') goto yy560; + if (yych <= 'M') goto yy563; + if (yych <= 'N') goto yy564; if (yych <= 'R') goto yy186; - goto yy561; + goto yy565; } } else { if (yych <= 'm') { - if (yych == 'f') goto yy557; + if (yych == 'f') goto yy561; if (yych <= 'l') goto yy186; - goto yy559; + goto yy563; } else { - if (yych <= 'n') goto yy560; - if (yych == 's') goto yy561; + if (yych <= 'n') goto yy564; + if (yych == 's') goto yy565; goto yy186; } } yy131: YYDEBUG(131, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy552; - if (yych == 'h') goto yy552; + if (yych == 'H') goto yy556; + if (yych == 'h') goto yy556; goto yy186; yy132: YYDEBUG(132, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'S') { if (yych <= 'M') { - if (yych == 'B') goto yy534; + if (yych == 'B') goto yy538; goto yy186; } else { - if (yych <= 'N') goto yy535; + if (yych <= 'N') goto yy539; if (yych <= 'Q') goto yy186; - if (yych <= 'R') goto yy536; - goto yy537; + if (yych <= 'R') goto yy540; + goto yy541; } } else { if (yych <= 'n') { - if (yych == 'b') goto yy534; + if (yych == 'b') goto yy538; if (yych <= 'm') goto yy186; - goto yy535; + goto yy539; } else { if (yych <= 'q') goto yy186; - if (yych <= 'r') goto yy536; - if (yych <= 's') goto yy537; + if (yych <= 'r') goto yy540; + if (yych <= 's') goto yy541; goto yy186; } } @@ -2535,15 +2535,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(133, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'W') { - if (yych == 'T') goto yy522; + if (yych == 'T') goto yy526; if (yych <= 'V') goto yy186; - goto yy523; + goto yy527; } else { if (yych <= 't') { if (yych <= 's') goto yy186; - goto yy522; + goto yy526; } else { - if (yych == 'w') goto yy523; + if (yych == 'w') goto yy527; goto yy186; } } @@ -2554,18 +2554,18 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (yych <= ';') { if (yych <= '"') { if (yych <= '!') goto yy186; - goto yy514; + goto yy518; } else { - if (yych == '\'') goto yy515; + if (yych == '\'') goto yy519; goto yy186; } } else { if (yych <= 'R') { - if (yych <= '<') goto yy513; + if (yych <= '<') goto yy517; if (yych <= 'Q') goto yy186; - goto yy516; + goto yy520; } else { - if (yych == 'r') goto yy516; + if (yych == 'r') goto yy520; goto yy186; } } @@ -2573,15 +2573,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(135, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'L') goto yy503; + if (yych == 'L') goto yy507; if (yych <= 'N') goto yy186; - goto yy504; + goto yy508; } else { if (yych <= 'l') { if (yych <= 'k') goto yy186; - goto yy503; + goto yy507; } else { - if (yych == 'o') goto yy504; + if (yych == 'o') goto yy508; goto yy186; } } @@ -2589,15 +2589,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(136, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'U') { - if (yych == 'R') goto yy479; + if (yych == 'R') goto yy483; if (yych <= 'T') goto yy186; - goto yy480; + goto yy484; } else { if (yych <= 'r') { if (yych <= 'q') goto yy186; - goto yy479; + goto yy483; } else { - if (yych == 'u') goto yy480; + if (yych == 'u') goto yy484; goto yy186; } } @@ -2605,15 +2605,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(137, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '<') { - if (yych == '-') goto yy475; + if (yych == '-') goto yy479; } else { - if (yych <= '=') goto yy473; - if (yych <= '>') goto yy477; + if (yych <= '=') goto yy477; + if (yych <= '>') goto yy481; } yy138: YYDEBUG(138, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1419 "Zend/zend_language_scanner.l" +#line 1420 "Zend/zend_language_scanner.l" { return yytext[0]; } @@ -2622,11 +2622,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(139, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy472; + goto yy476; yy140: YYDEBUG(140, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1154 "Zend/zend_language_scanner.l" +#line 1155 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -2638,14 +2638,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy141: YYDEBUG(141, *YYCURSOR); yych = *++YYCURSOR; - if (yych == ':') goto yy469; + if (yych == ':') goto yy473; goto yy138; yy142: YYDEBUG(142, *YYCURSOR); ++YYCURSOR; YYDEBUG(143, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1183 "Zend/zend_language_scanner.l" +#line 1184 "Zend/zend_language_scanner.l" { return T_NS_SEPARATOR; } @@ -2654,23 +2654,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(144, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'E') { - if (yych == 'A') goto yy457; + if (yych == 'A') goto yy461; if (yych <= 'D') goto yy186; - goto yy458; + goto yy462; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy457; + goto yy461; } else { - if (yych == 'e') goto yy458; + if (yych == 'e') goto yy462; goto yy186; } } yy145: YYDEBUG(145, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy454; - if (yych == 'a') goto yy454; + if (yych == 'A') goto yy458; + if (yych == 'a') goto yy458; goto yy186; yy146: YYDEBUG(146, *YYCURSOR); @@ -2679,47 +2679,47 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (yych <= 'S') { if (yych <= 'D') { if (yych <= ' ') { - if (yych == '\t') goto yy379; + if (yych == '\t') goto yy383; if (yych <= 0x1F) goto yy138; - goto yy379; + goto yy383; } else { if (yych <= '@') goto yy138; if (yych == 'C') goto yy138; - goto yy379; + goto yy383; } } else { if (yych <= 'I') { - if (yych == 'F') goto yy379; + if (yych == 'F') goto yy383; if (yych <= 'H') goto yy138; - goto yy379; + goto yy383; } else { - if (yych == 'O') goto yy379; + if (yych == 'O') goto yy383; if (yych <= 'Q') goto yy138; - goto yy379; + goto yy383; } } } else { if (yych <= 'f') { if (yych <= 'b') { - if (yych == 'U') goto yy379; + if (yych == 'U') goto yy383; if (yych <= '`') goto yy138; - goto yy379; + goto yy383; } else { - if (yych == 'd') goto yy379; + if (yych == 'd') goto yy383; if (yych <= 'e') goto yy138; - goto yy379; + goto yy383; } } else { if (yych <= 'o') { - if (yych == 'i') goto yy379; + if (yych == 'i') goto yy383; if (yych <= 'n') goto yy138; - goto yy379; + goto yy383; } else { if (yych <= 's') { if (yych <= 'q') goto yy138; - goto yy379; + goto yy383; } else { - if (yych == 'u') goto yy379; + if (yych == 'u') goto yy383; goto yy138; } } @@ -2729,139 +2729,139 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(147, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'S') { - if (yych == 'N') goto yy370; + if (yych == 'N') goto yy374; if (yych <= 'R') goto yy186; - goto yy371; + goto yy375; } else { if (yych <= 'n') { if (yych <= 'm') goto yy186; - goto yy370; + goto yy374; } else { - if (yych == 's') goto yy371; + if (yych == 's') goto yy375; goto yy186; } } yy148: YYDEBUG(148, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '_') goto yy296; + if (yych == '_') goto yy300; goto yy186; yy149: YYDEBUG(149, *YYCURSOR); yych = *++YYCURSOR; if (yych <= '<') goto yy138; - if (yych <= '=') goto yy290; - if (yych <= '>') goto yy292; + if (yych <= '=') goto yy294; + if (yych <= '>') goto yy296; goto yy138; yy150: YYDEBUG(150, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy286; - if (yych == 'i') goto yy286; + if (yych == 'I') goto yy290; + if (yych == 'i') goto yy290; goto yy186; yy151: YYDEBUG(151, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '+') goto yy284; - if (yych == '=') goto yy282; + if (yych == '+') goto yy288; + if (yych == '=') goto yy286; goto yy138; yy152: YYDEBUG(152, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '=') goto yy279; + if (yych == '=') goto yy283; goto yy138; yy153: YYDEBUG(153, *YYCURSOR); yyaccept = 1; yych = *(YYMARKER = ++YYCURSOR); if (yych <= ';') { - if (yych == '/') goto yy251; + if (yych == '/') goto yy255; goto yy138; } else { - if (yych <= '<') goto yy249; - if (yych <= '=') goto yy252; - if (yych <= '>') goto yy254; + if (yych <= '<') goto yy253; + if (yych <= '=') goto yy256; + if (yych <= '>') goto yy258; goto yy138; } yy154: YYDEBUG(154, *YYCURSOR); yych = *++YYCURSOR; if (yych <= '<') goto yy138; - if (yych <= '=') goto yy245; - if (yych <= '>') goto yy243; + if (yych <= '=') goto yy249; + if (yych <= '>') goto yy247; goto yy138; yy155: YYDEBUG(155, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '=') goto yy241; + if (yych == '=') goto yy245; goto yy138; yy156: YYDEBUG(156, *YYCURSOR); yych = *++YYCURSOR; if (yych <= '.') { - if (yych == '*') goto yy233; + if (yych == '*') goto yy237; goto yy138; } else { - if (yych <= '/') goto yy235; - if (yych == '=') goto yy236; + if (yych <= '/') goto yy239; + if (yych == '=') goto yy240; goto yy138; } yy157: YYDEBUG(157, *YYCURSOR); yych = *++YYCURSOR; if (yych <= '/') goto yy138; - if (yych <= '9') goto yy229; - if (yych == '=') goto yy231; + if (yych <= '9') goto yy233; + if (yych == '=') goto yy235; goto yy138; yy158: YYDEBUG(158, *YYCURSOR); yych = *++YYCURSOR; if (yych <= '<') goto yy138; - if (yych <= '=') goto yy225; - if (yych <= '>') goto yy223; + if (yych <= '=') goto yy229; + if (yych <= '>') goto yy227; goto yy138; yy159: YYDEBUG(159, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '&') goto yy219; - if (yych == '=') goto yy221; + if (yych == '&') goto yy223; + if (yych == '=') goto yy225; goto yy138; yy160: YYDEBUG(160, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '=') goto yy217; - if (yych == '|') goto yy215; + if (yych == '=') goto yy221; + if (yych == '|') goto yy219; goto yy138; yy161: YYDEBUG(161, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '=') goto yy213; + if (yych == '=') goto yy217; goto yy138; yy162: YYDEBUG(162, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy211; - if (yych == 'r') goto yy211; + if (yych == 'R') goto yy215; + if (yych == 'r') goto yy215; goto yy186; yy163: YYDEBUG(163, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy208; - if (yych == 'o') goto yy208; + if (yych == 'O') goto yy212; + if (yych == 'o') goto yy212; goto yy186; yy164: YYDEBUG(164, *YYCURSOR); yych = *++YYCURSOR; if (yych <= '_') { if (yych <= '@') goto yy138; - if (yych <= 'Z') goto yy205; + if (yych <= 'Z') goto yy209; if (yych <= '^') goto yy138; - goto yy205; + goto yy209; } else { if (yych <= '`') goto yy138; - if (yych <= 'z') goto yy205; + if (yych <= 'z') goto yy209; if (yych <= '~') goto yy138; - goto yy205; + goto yy209; } yy165: YYDEBUG(165, *YYCURSOR); @@ -2870,14 +2870,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy166: YYDEBUG(166, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '>') goto yy201; + if (yych == '>') goto yy205; goto yy138; yy167: YYDEBUG(167, *YYCURSOR); ++YYCURSOR; YYDEBUG(168, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1424 "Zend/zend_language_scanner.l" +#line 1425 "Zend/zend_language_scanner.l" { yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return '{'; @@ -2888,7 +2888,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(170, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1436 "Zend/zend_language_scanner.l" +#line 1437 "Zend/zend_language_scanner.l" { RESET_DOC_COMMENT(); if (!zend_stack_is_empty(&SCNG(state_stack))) { @@ -2902,24 +2902,29 @@ int lex_scan(zval *zendlval TSRMLS_DC) yyaccept = 2; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 'E') { - if (yych <= '/') { + if (yych <= '9') { if (yych == '.') goto yy187; + if (yych >= '0') goto yy190; } else { - if (yych <= '9') goto yy190; + if (yych == 'B') goto yy198; if (yych >= 'E') goto yy192; } } else { - if (yych <= 'd') { + if (yych <= 'b') { if (yych == 'X') goto yy197; + if (yych >= 'b') goto yy198; } else { - if (yych <= 'e') goto yy192; - if (yych == 'x') goto yy197; + if (yych <= 'e') { + if (yych >= 'e') goto yy192; + } else { + if (yych == 'x') goto yy197; + } } } yy172: YYDEBUG(172, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1462 "Zend/zend_language_scanner.l" +#line 1483 "Zend/zend_language_scanner.l" { if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */ zendlval->value.lval = strtol(yytext, NULL, 0); @@ -2940,7 +2945,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_LONG; return T_LNUMBER; } -#line 2944 "Zend/zend_language_scanner.c" +#line 2949 "Zend/zend_language_scanner.c" yy173: YYDEBUG(173, *YYCURSOR); yyaccept = 2; @@ -2968,7 +2973,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1824 "Zend/zend_language_scanner.l" +#line 1845 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3002,14 +3007,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_COMMENT; } -#line 3006 "Zend/zend_language_scanner.c" +#line 3011 "Zend/zend_language_scanner.c" yy177: YYDEBUG(177, *YYCURSOR); ++YYCURSOR; yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1915 "Zend/zend_language_scanner.l" +#line 1936 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3077,14 +3082,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_CONSTANT_ENCAPSED_STRING; } -#line 3081 "Zend/zend_language_scanner.c" +#line 3086 "Zend/zend_language_scanner.c" yy179: YYDEBUG(179, *YYCURSOR); ++YYCURSOR; yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1984 "Zend/zend_language_scanner.l" +#line 2005 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3125,24 +3130,24 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(ST_DOUBLE_QUOTES); return '"'; } -#line 3129 "Zend/zend_language_scanner.c" +#line 3134 "Zend/zend_language_scanner.c" yy181: YYDEBUG(181, *YYCURSOR); ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2075 "Zend/zend_language_scanner.l" +#line 2096 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; } -#line 3140 "Zend/zend_language_scanner.c" +#line 3145 "Zend/zend_language_scanner.c" yy183: YYDEBUG(183, *YYCURSOR); ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2333 "Zend/zend_language_scanner.l" +#line 2354 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3151,7 +3156,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 3155 "Zend/zend_language_scanner.c" +#line 3160 "Zend/zend_language_scanner.c" yy185: YYDEBUG(185, *YYCURSOR); ++YYCURSOR; @@ -3159,7 +3164,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *YYCURSOR; yy186: YYDEBUG(186, *YYCURSOR); - if (yybm[0+yych] & 8) { + if (yybm[0+yych] & 4) { goto yy185; } goto yy124; @@ -3170,7 +3175,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYFILL(3); yych = *YYCURSOR; YYDEBUG(188, *YYCURSOR); - if (yybm[0+yych] & 16) { + if (yybm[0+yych] & 8) { goto yy187; } if (yych == 'E') goto yy192; @@ -3178,13 +3183,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy189: YYDEBUG(189, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1523 "Zend/zend_language_scanner.l" +#line 1544 "Zend/zend_language_scanner.l" { zendlval->value.dval = zend_strtod(yytext, NULL); zendlval->type = IS_DOUBLE; return T_DNUMBER; } -#line 3188 "Zend/zend_language_scanner.c" +#line 3193 "Zend/zend_language_scanner.c" yy190: YYDEBUG(190, *YYCURSOR); yyaccept = 2; @@ -3231,10 +3236,10 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (yyaccept <= 3) { goto yy189; } else { - goto yy234; + goto yy238; } } else { - goto yy250; + goto yy254; } } yy194: @@ -3255,21 +3260,61 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(197, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 32) { - goto yy198; + goto yy202; } goto yy193; yy198: YYDEBUG(198, *YYCURSOR); + yych = *++YYCURSOR; + if (yybm[0+yych] & 16) { + goto yy199; + } + goto yy193; +yy199: + YYDEBUG(199, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(199, *YYCURSOR); + YYDEBUG(200, *YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy199; + } + YYDEBUG(201, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1462 "Zend/zend_language_scanner.l" + { + char *bin = yytext + 2; /* Skip "0b" */ + int len = yyleng - 2; + + /* Skip any leading 0s */ + while (*bin == '0') { + ++bin; + --len; + } + + if (len < SIZEOF_LONG * 2) { + zendlval->value.lval = strtol(bin, NULL, 2); + zendlval->type = IS_LONG; + return T_LNUMBER; + } else { + zendlval->value.dval = zend_bin_strtod(bin, NULL); + zendlval->type = IS_DOUBLE; + return T_DNUMBER; + } +} +#line 3306 "Zend/zend_language_scanner.c" +yy202: + YYDEBUG(202, *YYCURSOR); + ++YYCURSOR; + YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(203, *YYCURSOR); if (yybm[0+yych] & 32) { - goto yy198; + goto yy202; } - YYDEBUG(200, *YYCURSOR); + YYDEBUG(204, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1483 "Zend/zend_language_scanner.l" +#line 1504 "Zend/zend_language_scanner.l" { char *hex = yytext + 2; /* Skip "0x" */ int len = yyleng - 2; @@ -3290,16 +3335,16 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_DNUMBER; } } -#line 3294 "Zend/zend_language_scanner.c" -yy201: - YYDEBUG(201, *YYCURSOR); +#line 3339 "Zend/zend_language_scanner.c" +yy205: + YYDEBUG(205, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '\n') goto yy203; - if (yych == '\r') goto yy204; -yy202: - YYDEBUG(202, *YYCURSOR); + if ((yych = *YYCURSOR) == '\n') goto yy207; + if (yych == '\r') goto yy208; +yy206: + YYDEBUG(206, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1892 "Zend/zend_language_scanner.l" +#line 1913 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3307,137 +3352,137 @@ int lex_scan(zval *zendlval TSRMLS_DC) BEGIN(INITIAL); return T_CLOSE_TAG; /* implicit ';' at php-end tag */ } -#line 3311 "Zend/zend_language_scanner.c" -yy203: - YYDEBUG(203, *YYCURSOR); +#line 3356 "Zend/zend_language_scanner.c" +yy207: + YYDEBUG(207, *YYCURSOR); yych = *++YYCURSOR; - goto yy202; -yy204: - YYDEBUG(204, *YYCURSOR); + goto yy206; +yy208: + YYDEBUG(208, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\n') goto yy203; - goto yy202; -yy205: - YYDEBUG(205, *YYCURSOR); + if (yych == '\n') goto yy207; + goto yy206; +yy209: + YYDEBUG(209, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(206, *YYCURSOR); + YYDEBUG(210, *YYCURSOR); if (yych <= '^') { if (yych <= '9') { - if (yych >= '0') goto yy205; + if (yych >= '0') goto yy209; } else { - if (yych <= '@') goto yy207; - if (yych <= 'Z') goto yy205; + if (yych <= '@') goto yy211; + if (yych <= 'Z') goto yy209; } } else { if (yych <= '`') { - if (yych <= '_') goto yy205; + if (yych <= '_') goto yy209; } else { - if (yych <= 'z') goto yy205; - if (yych >= 0x7F) goto yy205; + if (yych <= 'z') goto yy209; + if (yych >= 0x7F) goto yy209; } } -yy207: - YYDEBUG(207, *YYCURSOR); +yy211: + YYDEBUG(211, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1794 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 3351 "Zend/zend_language_scanner.c" -yy208: - YYDEBUG(208, *YYCURSOR); +#line 3396 "Zend/zend_language_scanner.c" +yy212: + YYDEBUG(212, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy209; + if (yych == 'R') goto yy213; if (yych != 'r') goto yy186; -yy209: - YYDEBUG(209, *YYCURSOR); +yy213: + YYDEBUG(213, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(210, *YYCURSOR); + YYDEBUG(214, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1407 "Zend/zend_language_scanner.l" +#line 1408 "Zend/zend_language_scanner.l" { return T_LOGICAL_XOR; } -#line 3369 "Zend/zend_language_scanner.c" -yy211: - YYDEBUG(211, *YYCURSOR); +#line 3414 "Zend/zend_language_scanner.c" +yy215: + YYDEBUG(215, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(212, *YYCURSOR); + YYDEBUG(216, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1399 "Zend/zend_language_scanner.l" +#line 1400 "Zend/zend_language_scanner.l" { return T_LOGICAL_OR; } -#line 3382 "Zend/zend_language_scanner.c" -yy213: - YYDEBUG(213, *YYCURSOR); +#line 3427 "Zend/zend_language_scanner.c" +yy217: + YYDEBUG(217, *YYCURSOR); ++YYCURSOR; - YYDEBUG(214, *YYCURSOR); + YYDEBUG(218, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1387 "Zend/zend_language_scanner.l" +#line 1388 "Zend/zend_language_scanner.l" { return T_XOR_EQUAL; } -#line 3392 "Zend/zend_language_scanner.c" -yy215: - YYDEBUG(215, *YYCURSOR); +#line 3437 "Zend/zend_language_scanner.c" +yy219: + YYDEBUG(219, *YYCURSOR); ++YYCURSOR; - YYDEBUG(216, *YYCURSOR); + YYDEBUG(220, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1391 "Zend/zend_language_scanner.l" +#line 1392 "Zend/zend_language_scanner.l" { return T_BOOLEAN_OR; } -#line 3402 "Zend/zend_language_scanner.c" -yy217: - YYDEBUG(217, *YYCURSOR); +#line 3447 "Zend/zend_language_scanner.c" +yy221: + YYDEBUG(221, *YYCURSOR); ++YYCURSOR; - YYDEBUG(218, *YYCURSOR); + YYDEBUG(222, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1383 "Zend/zend_language_scanner.l" +#line 1384 "Zend/zend_language_scanner.l" { return T_OR_EQUAL; } -#line 3412 "Zend/zend_language_scanner.c" -yy219: - YYDEBUG(219, *YYCURSOR); +#line 3457 "Zend/zend_language_scanner.c" +yy223: + YYDEBUG(223, *YYCURSOR); ++YYCURSOR; - YYDEBUG(220, *YYCURSOR); + YYDEBUG(224, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1395 "Zend/zend_language_scanner.l" +#line 1396 "Zend/zend_language_scanner.l" { return T_BOOLEAN_AND; } -#line 3422 "Zend/zend_language_scanner.c" -yy221: - YYDEBUG(221, *YYCURSOR); +#line 3467 "Zend/zend_language_scanner.c" +yy225: + YYDEBUG(225, *YYCURSOR); ++YYCURSOR; - YYDEBUG(222, *YYCURSOR); + YYDEBUG(226, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1379 "Zend/zend_language_scanner.l" +#line 1380 "Zend/zend_language_scanner.l" { return T_AND_EQUAL; } -#line 3432 "Zend/zend_language_scanner.c" -yy223: - YYDEBUG(223, *YYCURSOR); +#line 3477 "Zend/zend_language_scanner.c" +yy227: + YYDEBUG(227, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '\n') goto yy227; - if (yych == '\r') goto yy228; -yy224: - YYDEBUG(224, *YYCURSOR); + if ((yych = *YYCURSOR) == '\n') goto yy231; + if (yych == '\r') goto yy232; +yy228: + YYDEBUG(228, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1901 "Zend/zend_language_scanner.l" +#line 1922 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3450,61 +3495,61 @@ int lex_scan(zval *zendlval TSRMLS_DC) return yytext[0]; } } -#line 3454 "Zend/zend_language_scanner.c" -yy225: - YYDEBUG(225, *YYCURSOR); +#line 3499 "Zend/zend_language_scanner.c" +yy229: + YYDEBUG(229, *YYCURSOR); ++YYCURSOR; - YYDEBUG(226, *YYCURSOR); + YYDEBUG(230, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1367 "Zend/zend_language_scanner.l" +#line 1368 "Zend/zend_language_scanner.l" { return T_MOD_EQUAL; } -#line 3464 "Zend/zend_language_scanner.c" -yy227: - YYDEBUG(227, *YYCURSOR); +#line 3509 "Zend/zend_language_scanner.c" +yy231: + YYDEBUG(231, *YYCURSOR); yych = *++YYCURSOR; - goto yy224; -yy228: - YYDEBUG(228, *YYCURSOR); + goto yy228; +yy232: + YYDEBUG(232, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\n') goto yy227; - goto yy224; -yy229: - YYDEBUG(229, *YYCURSOR); + if (yych == '\n') goto yy231; + goto yy228; +yy233: + YYDEBUG(233, *YYCURSOR); yyaccept = 3; YYMARKER = ++YYCURSOR; YYFILL(3); yych = *YYCURSOR; - YYDEBUG(230, *YYCURSOR); + YYDEBUG(234, *YYCURSOR); if (yych <= 'D') { if (yych <= '/') goto yy189; - if (yych <= '9') goto yy229; + if (yych <= '9') goto yy233; goto yy189; } else { if (yych <= 'E') goto yy192; if (yych == 'e') goto yy192; goto yy189; } -yy231: - YYDEBUG(231, *YYCURSOR); +yy235: + YYDEBUG(235, *YYCURSOR); ++YYCURSOR; - YYDEBUG(232, *YYCURSOR); + YYDEBUG(236, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1363 "Zend/zend_language_scanner.l" +#line 1364 "Zend/zend_language_scanner.l" { return T_CONCAT_EQUAL; } -#line 3499 "Zend/zend_language_scanner.c" -yy233: - YYDEBUG(233, *YYCURSOR); +#line 3544 "Zend/zend_language_scanner.c" +yy237: + YYDEBUG(237, *YYCURSOR); yyaccept = 4; yych = *(YYMARKER = ++YYCURSOR); - if (yych == '*') goto yy238; -yy234: - YYDEBUG(234, *YYCURSOR); + if (yych == '*') goto yy242; +yy238: + YYDEBUG(238, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1858 "Zend/zend_language_scanner.l" +#line 1879 "Zend/zend_language_scanner.l" { int doc_com; @@ -3538,281 +3583,281 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_COMMENT; } -#line 3542 "Zend/zend_language_scanner.c" -yy235: - YYDEBUG(235, *YYCURSOR); +#line 3587 "Zend/zend_language_scanner.c" +yy239: + YYDEBUG(239, *YYCURSOR); yych = *++YYCURSOR; goto yy176; -yy236: - YYDEBUG(236, *YYCURSOR); +yy240: + YYDEBUG(240, *YYCURSOR); ++YYCURSOR; - YYDEBUG(237, *YYCURSOR); + YYDEBUG(241, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1359 "Zend/zend_language_scanner.l" +#line 1360 "Zend/zend_language_scanner.l" { return T_DIV_EQUAL; } -#line 3556 "Zend/zend_language_scanner.c" -yy238: - YYDEBUG(238, *YYCURSOR); +#line 3601 "Zend/zend_language_scanner.c" +yy242: + YYDEBUG(242, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 64) { - goto yy239; + goto yy243; } goto yy193; -yy239: - YYDEBUG(239, *YYCURSOR); +yy243: + YYDEBUG(243, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(240, *YYCURSOR); + YYDEBUG(244, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy239; + goto yy243; } - goto yy234; -yy241: - YYDEBUG(241, *YYCURSOR); + goto yy238; +yy245: + YYDEBUG(245, *YYCURSOR); ++YYCURSOR; - YYDEBUG(242, *YYCURSOR); + YYDEBUG(246, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1355 "Zend/zend_language_scanner.l" +#line 1356 "Zend/zend_language_scanner.l" { return T_MUL_EQUAL; } -#line 3583 "Zend/zend_language_scanner.c" -yy243: - YYDEBUG(243, *YYCURSOR); +#line 3628 "Zend/zend_language_scanner.c" +yy247: + YYDEBUG(247, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '=') goto yy247; - YYDEBUG(244, *YYCURSOR); + if ((yych = *YYCURSOR) == '=') goto yy251; + YYDEBUG(248, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1415 "Zend/zend_language_scanner.l" +#line 1416 "Zend/zend_language_scanner.l" { return T_SR; } -#line 3594 "Zend/zend_language_scanner.c" -yy245: - YYDEBUG(245, *YYCURSOR); +#line 3639 "Zend/zend_language_scanner.c" +yy249: + YYDEBUG(249, *YYCURSOR); ++YYCURSOR; - YYDEBUG(246, *YYCURSOR); + YYDEBUG(250, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1343 "Zend/zend_language_scanner.l" +#line 1344 "Zend/zend_language_scanner.l" { return T_IS_GREATER_OR_EQUAL; } -#line 3604 "Zend/zend_language_scanner.c" -yy247: - YYDEBUG(247, *YYCURSOR); +#line 3649 "Zend/zend_language_scanner.c" +yy251: + YYDEBUG(251, *YYCURSOR); ++YYCURSOR; - YYDEBUG(248, *YYCURSOR); + YYDEBUG(252, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1375 "Zend/zend_language_scanner.l" +#line 1376 "Zend/zend_language_scanner.l" { return T_SR_EQUAL; } -#line 3614 "Zend/zend_language_scanner.c" -yy249: - YYDEBUG(249, *YYCURSOR); +#line 3659 "Zend/zend_language_scanner.c" +yy253: + YYDEBUG(253, *YYCURSOR); yyaccept = 5; yych = *(YYMARKER = ++YYCURSOR); - if (yych <= ';') goto yy250; - if (yych <= '<') goto yy265; - if (yych <= '=') goto yy263; -yy250: - YYDEBUG(250, *YYCURSOR); + if (yych <= ';') goto yy254; + if (yych <= '<') goto yy269; + if (yych <= '=') goto yy267; +yy254: + YYDEBUG(254, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1411 "Zend/zend_language_scanner.l" +#line 1412 "Zend/zend_language_scanner.l" { return T_SL; } -#line 3629 "Zend/zend_language_scanner.c" -yy251: - YYDEBUG(251, *YYCURSOR); +#line 3674 "Zend/zend_language_scanner.c" +yy255: + YYDEBUG(255, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy256; - if (yych == 's') goto yy256; + if (yych == 'S') goto yy260; + if (yych == 's') goto yy260; goto yy193; -yy252: - YYDEBUG(252, *YYCURSOR); +yy256: + YYDEBUG(256, *YYCURSOR); ++YYCURSOR; - YYDEBUG(253, *YYCURSOR); + YYDEBUG(257, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1339 "Zend/zend_language_scanner.l" +#line 1340 "Zend/zend_language_scanner.l" { return T_IS_SMALLER_OR_EQUAL; } -#line 3645 "Zend/zend_language_scanner.c" -yy254: - YYDEBUG(254, *YYCURSOR); +#line 3690 "Zend/zend_language_scanner.c" +yy258: + YYDEBUG(258, *YYCURSOR); ++YYCURSOR; -yy255: - YYDEBUG(255, *YYCURSOR); +yy259: + YYDEBUG(259, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1335 "Zend/zend_language_scanner.l" +#line 1336 "Zend/zend_language_scanner.l" { return T_IS_NOT_EQUAL; } -#line 3656 "Zend/zend_language_scanner.c" -yy256: - YYDEBUG(256, *YYCURSOR); +#line 3701 "Zend/zend_language_scanner.c" +yy260: + YYDEBUG(260, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy257; + if (yych == 'C') goto yy261; if (yych != 'c') goto yy193; -yy257: - YYDEBUG(257, *YYCURSOR); +yy261: + YYDEBUG(261, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy258; + if (yych == 'R') goto yy262; if (yych != 'r') goto yy193; -yy258: - YYDEBUG(258, *YYCURSOR); +yy262: + YYDEBUG(262, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy259; + if (yych == 'I') goto yy263; if (yych != 'i') goto yy193; -yy259: - YYDEBUG(259, *YYCURSOR); +yy263: + YYDEBUG(263, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy260; + if (yych == 'P') goto yy264; if (yych != 'p') goto yy193; -yy260: - YYDEBUG(260, *YYCURSOR); +yy264: + YYDEBUG(264, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy261; + if (yych == 'T') goto yy265; if (yych != 't') goto yy193; -yy261: - YYDEBUG(261, *YYCURSOR); +yy265: + YYDEBUG(265, *YYCURSOR); ++YYCURSOR; YYFILL(3); yych = *YYCURSOR; - YYDEBUG(262, *YYCURSOR); + YYDEBUG(266, *YYCURSOR); if (yych <= '\r') { if (yych <= 0x08) goto yy193; - if (yych <= '\n') goto yy261; + if (yych <= '\n') goto yy265; if (yych <= '\f') goto yy193; - goto yy261; + goto yy265; } else { if (yych <= ' ') { if (yych <= 0x1F) goto yy193; - goto yy261; + goto yy265; } else { - if (yych == '>') goto yy201; + if (yych == '>') goto yy205; goto yy193; } } -yy263: - YYDEBUG(263, *YYCURSOR); +yy267: + YYDEBUG(267, *YYCURSOR); ++YYCURSOR; - YYDEBUG(264, *YYCURSOR); + YYDEBUG(268, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1371 "Zend/zend_language_scanner.l" +#line 1372 "Zend/zend_language_scanner.l" { return T_SL_EQUAL; } -#line 3711 "Zend/zend_language_scanner.c" -yy265: - YYDEBUG(265, *YYCURSOR); +#line 3756 "Zend/zend_language_scanner.c" +yy269: + YYDEBUG(269, *YYCURSOR); ++YYCURSOR; YYFILL(2); yych = *YYCURSOR; - YYDEBUG(266, *YYCURSOR); + YYDEBUG(270, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy265; + goto yy269; } if (yych <= 'Z') { if (yych <= '&') { - if (yych == '"') goto yy270; + if (yych == '"') goto yy274; goto yy193; } else { - if (yych <= '\'') goto yy269; + if (yych <= '\'') goto yy273; if (yych <= '@') goto yy193; } } else { if (yych <= '`') { if (yych != '_') goto yy193; } else { - if (yych <= 'z') goto yy267; + if (yych <= 'z') goto yy271; if (yych <= '~') goto yy193; } } -yy267: - YYDEBUG(267, *YYCURSOR); +yy271: + YYDEBUG(271, *YYCURSOR); ++YYCURSOR; YYFILL(2); yych = *YYCURSOR; - YYDEBUG(268, *YYCURSOR); + YYDEBUG(272, *YYCURSOR); if (yych <= '@') { if (yych <= '\f') { - if (yych == '\n') goto yy274; + if (yych == '\n') goto yy278; goto yy193; } else { - if (yych <= '\r') goto yy276; + if (yych <= '\r') goto yy280; if (yych <= '/') goto yy193; - if (yych <= '9') goto yy267; + if (yych <= '9') goto yy271; goto yy193; } } else { if (yych <= '_') { - if (yych <= 'Z') goto yy267; + if (yych <= 'Z') goto yy271; if (yych <= '^') goto yy193; - goto yy267; + goto yy271; } else { if (yych <= '`') goto yy193; - if (yych <= 'z') goto yy267; + if (yych <= 'z') goto yy271; if (yych <= '~') goto yy193; - goto yy267; + goto yy271; } } -yy269: - YYDEBUG(269, *YYCURSOR); +yy273: + YYDEBUG(273, *YYCURSOR); yych = *++YYCURSOR; if (yych == '\'') goto yy193; - if (yych <= '/') goto yy278; + if (yych <= '/') goto yy282; if (yych <= '9') goto yy193; - goto yy278; -yy270: - YYDEBUG(270, *YYCURSOR); + goto yy282; +yy274: + YYDEBUG(274, *YYCURSOR); yych = *++YYCURSOR; if (yych == '"') goto yy193; - if (yych <= '/') goto yy272; + if (yych <= '/') goto yy276; if (yych <= '9') goto yy193; - goto yy272; -yy271: - YYDEBUG(271, *YYCURSOR); + goto yy276; +yy275: + YYDEBUG(275, *YYCURSOR); ++YYCURSOR; YYFILL(3); yych = *YYCURSOR; -yy272: - YYDEBUG(272, *YYCURSOR); +yy276: + YYDEBUG(276, *YYCURSOR); if (yych <= 'Z') { if (yych <= '/') { if (yych != '"') goto yy193; } else { - if (yych <= '9') goto yy271; + if (yych <= '9') goto yy275; if (yych <= '@') goto yy193; - goto yy271; + goto yy275; } } else { if (yych <= '`') { - if (yych == '_') goto yy271; + if (yych == '_') goto yy275; goto yy193; } else { - if (yych <= 'z') goto yy271; + if (yych <= 'z') goto yy275; if (yych <= '~') goto yy193; - goto yy271; + goto yy275; } } -yy273: - YYDEBUG(273, *YYCURSOR); +yy277: + YYDEBUG(277, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\n') goto yy274; - if (yych == '\r') goto yy276; + if (yych == '\n') goto yy278; + if (yych == '\r') goto yy280; goto yy193; -yy274: - YYDEBUG(274, *YYCURSOR); +yy278: + YYDEBUG(278, *YYCURSOR); ++YYCURSOR; -yy275: - YYDEBUG(275, *YYCURSOR); +yy279: + YYDEBUG(279, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2026 "Zend/zend_language_scanner.l" +#line 2047 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -3860,247 +3905,247 @@ int lex_scan(zval *zendlval TSRMLS_DC) return T_START_HEREDOC; } -#line 3864 "Zend/zend_language_scanner.c" -yy276: - YYDEBUG(276, *YYCURSOR); +#line 3909 "Zend/zend_language_scanner.c" +yy280: + YYDEBUG(280, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '\n') goto yy274; - goto yy275; -yy277: - YYDEBUG(277, *YYCURSOR); + if (yych == '\n') goto yy278; + goto yy279; +yy281: + YYDEBUG(281, *YYCURSOR); ++YYCURSOR; YYFILL(3); yych = *YYCURSOR; -yy278: - YYDEBUG(278, *YYCURSOR); +yy282: + YYDEBUG(282, *YYCURSOR); if (yych <= 'Z') { if (yych <= '/') { - if (yych == '\'') goto yy273; + if (yych == '\'') goto yy277; goto yy193; } else { - if (yych <= '9') goto yy277; + if (yych <= '9') goto yy281; if (yych <= '@') goto yy193; - goto yy277; + goto yy281; } } else { if (yych <= '`') { - if (yych == '_') goto yy277; + if (yych == '_') goto yy281; goto yy193; } else { - if (yych <= 'z') goto yy277; + if (yych <= 'z') goto yy281; if (yych <= '~') goto yy193; - goto yy277; + goto yy281; } } -yy279: - YYDEBUG(279, *YYCURSOR); +yy283: + YYDEBUG(283, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '=') goto yy255; - YYDEBUG(280, *YYCURSOR); + if (yych != '=') goto yy259; + YYDEBUG(284, *YYCURSOR); ++YYCURSOR; - YYDEBUG(281, *YYCURSOR); + YYDEBUG(285, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1327 "Zend/zend_language_scanner.l" +#line 1328 "Zend/zend_language_scanner.l" { return T_IS_NOT_IDENTICAL; } -#line 3908 "Zend/zend_language_scanner.c" -yy282: - YYDEBUG(282, *YYCURSOR); +#line 3953 "Zend/zend_language_scanner.c" +yy286: + YYDEBUG(286, *YYCURSOR); ++YYCURSOR; - YYDEBUG(283, *YYCURSOR); + YYDEBUG(287, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1347 "Zend/zend_language_scanner.l" +#line 1348 "Zend/zend_language_scanner.l" { return T_PLUS_EQUAL; } -#line 3918 "Zend/zend_language_scanner.c" -yy284: - YYDEBUG(284, *YYCURSOR); +#line 3963 "Zend/zend_language_scanner.c" +yy288: + YYDEBUG(288, *YYCURSOR); ++YYCURSOR; - YYDEBUG(285, *YYCURSOR); + YYDEBUG(289, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1315 "Zend/zend_language_scanner.l" +#line 1316 "Zend/zend_language_scanner.l" { return T_INC; } -#line 3928 "Zend/zend_language_scanner.c" -yy286: - YYDEBUG(286, *YYCURSOR); +#line 3973 "Zend/zend_language_scanner.c" +yy290: + YYDEBUG(290, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy287; + if (yych == 'S') goto yy291; if (yych != 's') goto yy186; -yy287: - YYDEBUG(287, *YYCURSOR); +yy291: + YYDEBUG(291, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy288; + if (yych == 'T') goto yy292; if (yych != 't') goto yy186; -yy288: - YYDEBUG(288, *YYCURSOR); +yy292: + YYDEBUG(292, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(289, *YYCURSOR); + YYDEBUG(293, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1307 "Zend/zend_language_scanner.l" +#line 1308 "Zend/zend_language_scanner.l" { return T_LIST; } -#line 3951 "Zend/zend_language_scanner.c" -yy290: - YYDEBUG(290, *YYCURSOR); +#line 3996 "Zend/zend_language_scanner.c" +yy294: + YYDEBUG(294, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '=') goto yy294; - YYDEBUG(291, *YYCURSOR); + if ((yych = *YYCURSOR) == '=') goto yy298; + YYDEBUG(295, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1331 "Zend/zend_language_scanner.l" +#line 1332 "Zend/zend_language_scanner.l" { return T_IS_EQUAL; } -#line 3962 "Zend/zend_language_scanner.c" -yy292: - YYDEBUG(292, *YYCURSOR); +#line 4007 "Zend/zend_language_scanner.c" +yy296: + YYDEBUG(296, *YYCURSOR); ++YYCURSOR; - YYDEBUG(293, *YYCURSOR); + YYDEBUG(297, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1303 "Zend/zend_language_scanner.l" +#line 1304 "Zend/zend_language_scanner.l" { return T_DOUBLE_ARROW; } -#line 3972 "Zend/zend_language_scanner.c" -yy294: - YYDEBUG(294, *YYCURSOR); +#line 4017 "Zend/zend_language_scanner.c" +yy298: + YYDEBUG(298, *YYCURSOR); ++YYCURSOR; - YYDEBUG(295, *YYCURSOR); + YYDEBUG(299, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1323 "Zend/zend_language_scanner.l" +#line 1324 "Zend/zend_language_scanner.l" { return T_IS_IDENTICAL; } -#line 3982 "Zend/zend_language_scanner.c" -yy296: - YYDEBUG(296, *YYCURSOR); +#line 4027 "Zend/zend_language_scanner.c" +yy300: + YYDEBUG(300, *YYCURSOR); yych = *++YYCURSOR; YYDEBUG(-1, yych); switch (yych) { case 'C': - case 'c': goto yy298; + case 'c': goto yy302; case 'D': - case 'd': goto yy302; + case 'd': goto yy306; case 'F': - case 'f': goto yy299; + case 'f': goto yy303; case 'H': - case 'h': goto yy297; + case 'h': goto yy301; case 'L': - case 'l': goto yy301; + case 'l': goto yy305; case 'M': - case 'm': goto yy300; + case 'm': goto yy304; case 'N': - case 'n': goto yy303; + case 'n': goto yy307; default: goto yy186; } -yy297: - YYDEBUG(297, *YYCURSOR); +yy301: + YYDEBUG(301, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy357; - if (yych == 'a') goto yy357; + if (yych == 'A') goto yy361; + if (yych == 'a') goto yy361; goto yy186; -yy298: - YYDEBUG(298, *YYCURSOR); +yy302: + YYDEBUG(302, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy350; - if (yych == 'l') goto yy350; + if (yych == 'L') goto yy354; + if (yych == 'l') goto yy354; goto yy186; -yy299: - YYDEBUG(299, *YYCURSOR); +yy303: + YYDEBUG(303, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'U') { - if (yych == 'I') goto yy334; + if (yych == 'I') goto yy338; if (yych <= 'T') goto yy186; - goto yy335; + goto yy339; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; - goto yy334; + goto yy338; } else { - if (yych == 'u') goto yy335; + if (yych == 'u') goto yy339; goto yy186; } } -yy300: - YYDEBUG(300, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'E') goto yy326; - if (yych == 'e') goto yy326; - goto yy186; -yy301: - YYDEBUG(301, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'I') goto yy320; - if (yych == 'i') goto yy320; - goto yy186; -yy302: - YYDEBUG(302, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'I') goto yy315; - if (yych == 'i') goto yy315; - goto yy186; -yy303: - YYDEBUG(303, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'A') goto yy304; - if (yych != 'a') goto yy186; yy304: YYDEBUG(304, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy305; - if (yych != 'm') goto yy186; + if (yych == 'E') goto yy330; + if (yych == 'e') goto yy330; + goto yy186; yy305: YYDEBUG(305, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy306; - if (yych != 'e') goto yy186; + if (yych == 'I') goto yy324; + if (yych == 'i') goto yy324; + goto yy186; yy306: YYDEBUG(306, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy307; - if (yych != 's') goto yy186; + if (yych == 'I') goto yy319; + if (yych == 'i') goto yy319; + goto yy186; yy307: YYDEBUG(307, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy308; - if (yych != 'p') goto yy186; + if (yych == 'A') goto yy308; + if (yych != 'a') goto yy186; yy308: YYDEBUG(308, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy309; - if (yych != 'a') goto yy186; + if (yych == 'M') goto yy309; + if (yych != 'm') goto yy186; yy309: YYDEBUG(309, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy310; - if (yych != 'c') goto yy186; + if (yych == 'E') goto yy310; + if (yych != 'e') goto yy186; yy310: YYDEBUG(310, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy311; - if (yych != 'e') goto yy186; + if (yych == 'S') goto yy311; + if (yych != 's') goto yy186; yy311: YYDEBUG(311, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'P') goto yy312; + if (yych != 'p') goto yy186; +yy312: YYDEBUG(312, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'A') goto yy313; + if (yych != 'a') goto yy186; +yy313: YYDEBUG(313, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'C') goto yy314; + if (yych != 'c') goto yy186; +yy314: + YYDEBUG(314, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy315; + if (yych != 'e') goto yy186; +yy315: + YYDEBUG(315, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(316, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(317, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(314, *YYCURSOR); + YYDEBUG(318, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1627 "Zend/zend_language_scanner.l" +#line 1648 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4110,27 +4155,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NS_C; } -#line 4114 "Zend/zend_language_scanner.c" -yy315: - YYDEBUG(315, *YYCURSOR); +#line 4159 "Zend/zend_language_scanner.c" +yy319: + YYDEBUG(319, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy316; + if (yych == 'R') goto yy320; if (yych != 'r') goto yy186; -yy316: - YYDEBUG(316, *YYCURSOR); +yy320: + YYDEBUG(320, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(317, *YYCURSOR); + YYDEBUG(321, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(318, *YYCURSOR); + YYDEBUG(322, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(319, *YYCURSOR); + YYDEBUG(323, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1600 "Zend/zend_language_scanner.l" +#line 1621 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4157,73 +4202,73 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_DIR; } -#line 4161 "Zend/zend_language_scanner.c" -yy320: - YYDEBUG(320, *YYCURSOR); +#line 4206 "Zend/zend_language_scanner.c" +yy324: + YYDEBUG(324, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy321; + if (yych == 'N') goto yy325; if (yych != 'n') goto yy186; -yy321: - YYDEBUG(321, *YYCURSOR); +yy325: + YYDEBUG(325, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy322; + if (yych == 'E') goto yy326; if (yych != 'e') goto yy186; -yy322: - YYDEBUG(322, *YYCURSOR); +yy326: + YYDEBUG(326, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(323, *YYCURSOR); + YYDEBUG(327, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(324, *YYCURSOR); + YYDEBUG(328, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(325, *YYCURSOR); + YYDEBUG(329, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1582 "Zend/zend_language_scanner.l" +#line 1603 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; return T_LINE; } -#line 4192 "Zend/zend_language_scanner.c" -yy326: - YYDEBUG(326, *YYCURSOR); +#line 4237 "Zend/zend_language_scanner.c" +yy330: + YYDEBUG(330, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy327; + if (yych == 'T') goto yy331; if (yych != 't') goto yy186; -yy327: - YYDEBUG(327, *YYCURSOR); +yy331: + YYDEBUG(331, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy328; + if (yych == 'H') goto yy332; if (yych != 'h') goto yy186; -yy328: - YYDEBUG(328, *YYCURSOR); +yy332: + YYDEBUG(332, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy329; + if (yych == 'O') goto yy333; if (yych != 'o') goto yy186; -yy329: - YYDEBUG(329, *YYCURSOR); +yy333: + YYDEBUG(333, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy330; + if (yych == 'D') goto yy334; if (yych != 'd') goto yy186; -yy330: - YYDEBUG(330, *YYCURSOR); +yy334: + YYDEBUG(334, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(331, *YYCURSOR); + YYDEBUG(335, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(332, *YYCURSOR); + YYDEBUG(336, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(333, *YYCURSOR); + YYDEBUG(337, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1561 "Zend/zend_language_scanner.l" +#line 1582 "Zend/zend_language_scanner.l" { char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4244,58 +4289,58 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_METHOD_C; } -#line 4248 "Zend/zend_language_scanner.c" -yy334: - YYDEBUG(334, *YYCURSOR); +#line 4293 "Zend/zend_language_scanner.c" +yy338: + YYDEBUG(338, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy345; - if (yych == 'l') goto yy345; + if (yych == 'L') goto yy349; + if (yych == 'l') goto yy349; goto yy186; -yy335: - YYDEBUG(335, *YYCURSOR); +yy339: + YYDEBUG(339, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy336; + if (yych == 'N') goto yy340; if (yych != 'n') goto yy186; -yy336: - YYDEBUG(336, *YYCURSOR); +yy340: + YYDEBUG(340, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy337; + if (yych == 'C') goto yy341; if (yych != 'c') goto yy186; -yy337: - YYDEBUG(337, *YYCURSOR); +yy341: + YYDEBUG(341, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy338; + if (yych == 'T') goto yy342; if (yych != 't') goto yy186; -yy338: - YYDEBUG(338, *YYCURSOR); +yy342: + YYDEBUG(342, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy339; + if (yych == 'I') goto yy343; if (yych != 'i') goto yy186; -yy339: - YYDEBUG(339, *YYCURSOR); +yy343: + YYDEBUG(343, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy340; + if (yych == 'O') goto yy344; if (yych != 'o') goto yy186; -yy340: - YYDEBUG(340, *YYCURSOR); +yy344: + YYDEBUG(344, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy341; + if (yych == 'N') goto yy345; if (yych != 'n') goto yy186; -yy341: - YYDEBUG(341, *YYCURSOR); +yy345: + YYDEBUG(345, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(342, *YYCURSOR); + YYDEBUG(346, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(343, *YYCURSOR); + YYDEBUG(347, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(344, *YYCURSOR); + YYDEBUG(348, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1545 "Zend/zend_language_scanner.l" +#line 1566 "Zend/zend_language_scanner.l" { char *func_name = NULL; @@ -4311,27 +4356,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FUNC_C; } -#line 4315 "Zend/zend_language_scanner.c" -yy345: - YYDEBUG(345, *YYCURSOR); +#line 4360 "Zend/zend_language_scanner.c" +yy349: + YYDEBUG(349, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy346; + if (yych == 'E') goto yy350; if (yych != 'e') goto yy186; -yy346: - YYDEBUG(346, *YYCURSOR); +yy350: + YYDEBUG(350, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(347, *YYCURSOR); + YYDEBUG(351, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(348, *YYCURSOR); + YYDEBUG(352, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(349, *YYCURSOR); + YYDEBUG(353, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1588 "Zend/zend_language_scanner.l" +#line 1609 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4343,37 +4388,37 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FILE; } -#line 4347 "Zend/zend_language_scanner.c" -yy350: - YYDEBUG(350, *YYCURSOR); +#line 4392 "Zend/zend_language_scanner.c" +yy354: + YYDEBUG(354, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy351; + if (yych == 'A') goto yy355; if (yych != 'a') goto yy186; -yy351: - YYDEBUG(351, *YYCURSOR); +yy355: + YYDEBUG(355, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy352; + if (yych == 'S') goto yy356; if (yych != 's') goto yy186; -yy352: - YYDEBUG(352, *YYCURSOR); +yy356: + YYDEBUG(356, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy353; + if (yych == 'S') goto yy357; if (yych != 's') goto yy186; -yy353: - YYDEBUG(353, *YYCURSOR); +yy357: + YYDEBUG(357, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(354, *YYCURSOR); + YYDEBUG(358, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(355, *YYCURSOR); + YYDEBUG(359, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(356, *YYCURSOR); + YYDEBUG(360, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1529 "Zend/zend_language_scanner.l" +#line 1550 "Zend/zend_language_scanner.l" { char *class_name = NULL; @@ -4389,2470 +4434,2447 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_CLASS_C; } -#line 4393 "Zend/zend_language_scanner.c" -yy357: - YYDEBUG(357, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'L') goto yy358; - if (yych != 'l') goto yy186; -yy358: - YYDEBUG(358, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'T') goto yy359; - if (yych != 't') goto yy186; -yy359: - YYDEBUG(359, *YYCURSOR); - yych = *++YYCURSOR; - if (yych != '_') goto yy186; - YYDEBUG(360, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'C') goto yy361; - if (yych != 'c') goto yy186; +#line 4438 "Zend/zend_language_scanner.c" yy361: YYDEBUG(361, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy362; - if (yych != 'o') goto yy186; + if (yych == 'L') goto yy362; + if (yych != 'l') goto yy186; yy362: YYDEBUG(362, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy363; - if (yych != 'm') goto yy186; + if (yych == 'T') goto yy363; + if (yych != 't') goto yy186; yy363: YYDEBUG(363, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy364; - if (yych != 'p') goto yy186; -yy364: + if (yych != '_') goto yy186; YYDEBUG(364, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy365; - if (yych != 'i') goto yy186; + if (yych == 'C') goto yy365; + if (yych != 'c') goto yy186; yy365: YYDEBUG(365, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy366; - if (yych != 'l') goto yy186; + if (yych == 'O') goto yy366; + if (yych != 'o') goto yy186; yy366: YYDEBUG(366, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy367; - if (yych != 'e') goto yy186; + if (yych == 'M') goto yy367; + if (yych != 'm') goto yy186; yy367: YYDEBUG(367, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy368; - if (yych != 'r') goto yy186; + if (yych == 'P') goto yy368; + if (yych != 'p') goto yy186; yy368: YYDEBUG(368, *YYCURSOR); - ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { - goto yy185; - } + yych = *++YYCURSOR; + if (yych == 'I') goto yy369; + if (yych != 'i') goto yy186; +yy369: YYDEBUG(369, *YYCURSOR); - yyleng = YYCURSOR - SCNG(yy_text); -#line 1271 "Zend/zend_language_scanner.l" - { - return T_HALT_COMPILER; -} -#line 4459 "Zend/zend_language_scanner.c" + yych = *++YYCURSOR; + if (yych == 'L') goto yy370; + if (yych != 'l') goto yy186; yy370: YYDEBUG(370, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy374; - if (yych == 's') goto yy374; - goto yy186; + if (yych == 'E') goto yy371; + if (yych != 'e') goto yy186; yy371: YYDEBUG(371, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy372; - if (yych != 'e') goto yy186; + if (yych == 'R') goto yy372; + if (yych != 'r') goto yy186; yy372: YYDEBUG(372, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } YYDEBUG(373, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1251 "Zend/zend_language_scanner.l" +#line 1272 "Zend/zend_language_scanner.l" { - return T_USE; + return T_HALT_COMPILER; } -#line 4483 "Zend/zend_language_scanner.c" +#line 4504 "Zend/zend_language_scanner.c" yy374: YYDEBUG(374, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy375; - if (yych != 'e') goto yy186; + if (yych == 'S') goto yy378; + if (yych == 's') goto yy378; + goto yy186; yy375: YYDEBUG(375, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy376; - if (yych != 't') goto yy186; + if (yych == 'E') goto yy376; + if (yych != 'e') goto yy186; yy376: YYDEBUG(376, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } YYDEBUG(377, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1299 "Zend/zend_language_scanner.l" +#line 1252 "Zend/zend_language_scanner.l" { - return T_UNSET; + return T_USE; } -#line 4506 "Zend/zend_language_scanner.c" +#line 4528 "Zend/zend_language_scanner.c" yy378: YYDEBUG(378, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy379; + if (yych != 'e') goto yy186; +yy379: + YYDEBUG(379, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy380; + if (yych != 't') goto yy186; +yy380: + YYDEBUG(380, *YYCURSOR); + ++YYCURSOR; + if (yybm[0+(yych = *YYCURSOR)] & 4) { + goto yy185; + } + YYDEBUG(381, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1300 "Zend/zend_language_scanner.l" + { + return T_UNSET; +} +#line 4551 "Zend/zend_language_scanner.c" +yy382: + YYDEBUG(382, *YYCURSOR); ++YYCURSOR; YYFILL(7); yych = *YYCURSOR; -yy379: - YYDEBUG(379, *YYCURSOR); +yy383: + YYDEBUG(383, *YYCURSOR); if (yych <= 'S') { if (yych <= 'D') { if (yych <= ' ') { - if (yych == '\t') goto yy378; + if (yych == '\t') goto yy382; if (yych <= 0x1F) goto yy193; - goto yy378; + goto yy382; } else { if (yych <= 'A') { if (yych <= '@') goto yy193; - goto yy383; + goto yy387; } else { - if (yych <= 'B') goto yy381; + if (yych <= 'B') goto yy385; if (yych <= 'C') goto yy193; - goto yy386; + goto yy390; } } } else { if (yych <= 'I') { - if (yych == 'F') goto yy387; + if (yych == 'F') goto yy391; if (yych <= 'H') goto yy193; - goto yy388; + goto yy392; } else { if (yych <= 'O') { if (yych <= 'N') goto yy193; - goto yy382; + goto yy386; } else { if (yych <= 'Q') goto yy193; - if (yych <= 'R') goto yy385; - goto yy384; + if (yych <= 'R') goto yy389; + goto yy388; } } } } else { if (yych <= 'f') { if (yych <= 'a') { - if (yych == 'U') goto yy380; + if (yych == 'U') goto yy384; if (yych <= '`') goto yy193; - goto yy383; + goto yy387; } else { if (yych <= 'c') { - if (yych <= 'b') goto yy381; + if (yych <= 'b') goto yy385; goto yy193; } else { - if (yych <= 'd') goto yy386; + if (yych <= 'd') goto yy390; if (yych <= 'e') goto yy193; - goto yy387; + goto yy391; } } } else { if (yych <= 'q') { if (yych <= 'i') { if (yych <= 'h') goto yy193; - goto yy388; + goto yy392; } else { - if (yych == 'o') goto yy382; + if (yych == 'o') goto yy386; goto yy193; } } else { if (yych <= 's') { - if (yych <= 'r') goto yy385; - goto yy384; + if (yych <= 'r') goto yy389; + goto yy388; } else { if (yych != 'u') goto yy193; } } } } -yy380: - YYDEBUG(380, *YYCURSOR); +yy384: + YYDEBUG(384, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy447; - if (yych == 'n') goto yy447; + if (yych == 'N') goto yy451; + if (yych == 'n') goto yy451; goto yy193; -yy381: - YYDEBUG(381, *YYCURSOR); +yy385: + YYDEBUG(385, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'I') goto yy434; + if (yych == 'I') goto yy438; if (yych <= 'N') goto yy193; - goto yy435; + goto yy439; } else { if (yych <= 'i') { if (yych <= 'h') goto yy193; - goto yy434; + goto yy438; } else { - if (yych == 'o') goto yy435; + if (yych == 'o') goto yy439; goto yy193; } } -yy382: - YYDEBUG(382, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'B') goto yy426; - if (yych == 'b') goto yy426; - goto yy193; -yy383: - YYDEBUG(383, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'R') goto yy419; - if (yych == 'r') goto yy419; - goto yy193; -yy384: - YYDEBUG(384, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'T') goto yy411; - if (yych == 't') goto yy411; - goto yy193; -yy385: - YYDEBUG(385, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'E') goto yy409; - if (yych == 'e') goto yy409; - goto yy193; yy386: YYDEBUG(386, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy405; - if (yych == 'o') goto yy405; + if (yych == 'B') goto yy430; + if (yych == 'b') goto yy430; goto yy193; yy387: YYDEBUG(387, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy398; - if (yych == 'l') goto yy398; + if (yych == 'R') goto yy423; + if (yych == 'r') goto yy423; goto yy193; yy388: YYDEBUG(388, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy389; - if (yych != 'n') goto yy193; + if (yych == 'T') goto yy415; + if (yych == 't') goto yy415; + goto yy193; yy389: YYDEBUG(389, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy390; - if (yych != 't') goto yy193; + if (yych == 'E') goto yy413; + if (yych == 'e') goto yy413; + goto yy193; yy390: YYDEBUG(390, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy391; - if (yych != 'e') goto yy393; + if (yych == 'O') goto yy409; + if (yych == 'o') goto yy409; + goto yy193; yy391: YYDEBUG(391, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy396; - if (yych == 'g') goto yy396; + if (yych == 'L') goto yy402; + if (yych == 'l') goto yy402; goto yy193; yy392: YYDEBUG(392, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy393; + if (yych != 'n') goto yy193; +yy393: + YYDEBUG(393, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'T') goto yy394; + if (yych != 't') goto yy193; +yy394: + YYDEBUG(394, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy395; + if (yych != 'e') goto yy397; +yy395: + YYDEBUG(395, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy400; + if (yych == 'g') goto yy400; + goto yy193; +yy396: + YYDEBUG(396, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy393: - YYDEBUG(393, *YYCURSOR); +yy397: + YYDEBUG(397, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy392; + if (yych == '\t') goto yy396; goto yy193; } else { - if (yych <= ' ') goto yy392; + if (yych <= ' ') goto yy396; if (yych != ')') goto yy193; } - YYDEBUG(394, *YYCURSOR); + YYDEBUG(398, *YYCURSOR); ++YYCURSOR; - YYDEBUG(395, *YYCURSOR); + YYDEBUG(399, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1199 "Zend/zend_language_scanner.l" +#line 1200 "Zend/zend_language_scanner.l" { return T_INT_CAST; } -#line 4682 "Zend/zend_language_scanner.c" -yy396: - YYDEBUG(396, *YYCURSOR); +#line 4727 "Zend/zend_language_scanner.c" +yy400: + YYDEBUG(400, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy397; + if (yych == 'E') goto yy401; if (yych != 'e') goto yy193; -yy397: - YYDEBUG(397, *YYCURSOR); +yy401: + YYDEBUG(401, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy392; - if (yych == 'r') goto yy392; + if (yych == 'R') goto yy396; + if (yych == 'r') goto yy396; goto yy193; -yy398: - YYDEBUG(398, *YYCURSOR); +yy402: + YYDEBUG(402, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy399; + if (yych == 'O') goto yy403; if (yych != 'o') goto yy193; -yy399: - YYDEBUG(399, *YYCURSOR); +yy403: + YYDEBUG(403, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy400; + if (yych == 'A') goto yy404; if (yych != 'a') goto yy193; -yy400: - YYDEBUG(400, *YYCURSOR); +yy404: + YYDEBUG(404, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy401; + if (yych == 'T') goto yy405; if (yych != 't') goto yy193; -yy401: - YYDEBUG(401, *YYCURSOR); +yy405: + YYDEBUG(405, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(402, *YYCURSOR); + YYDEBUG(406, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy401; + if (yych == '\t') goto yy405; goto yy193; } else { - if (yych <= ' ') goto yy401; + if (yych <= ' ') goto yy405; if (yych != ')') goto yy193; } - YYDEBUG(403, *YYCURSOR); + YYDEBUG(407, *YYCURSOR); ++YYCURSOR; - YYDEBUG(404, *YYCURSOR); + YYDEBUG(408, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1203 "Zend/zend_language_scanner.l" +#line 1204 "Zend/zend_language_scanner.l" { return T_DOUBLE_CAST; } -#line 4730 "Zend/zend_language_scanner.c" -yy405: - YYDEBUG(405, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'U') goto yy406; - if (yych != 'u') goto yy193; -yy406: - YYDEBUG(406, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'B') goto yy407; - if (yych != 'b') goto yy193; -yy407: - YYDEBUG(407, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'L') goto yy408; - if (yych != 'l') goto yy193; -yy408: - YYDEBUG(408, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'E') goto yy401; - if (yych == 'e') goto yy401; - goto yy193; +#line 4775 "Zend/zend_language_scanner.c" yy409: YYDEBUG(409, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy410; - if (yych != 'a') goto yy193; + if (yych == 'U') goto yy410; + if (yych != 'u') goto yy193; yy410: YYDEBUG(410, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy401; - if (yych == 'l') goto yy401; - goto yy193; + if (yych == 'B') goto yy411; + if (yych != 'b') goto yy193; yy411: YYDEBUG(411, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy412; - if (yych != 'r') goto yy193; + if (yych == 'L') goto yy412; + if (yych != 'l') goto yy193; yy412: YYDEBUG(412, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy413; - if (yych != 'i') goto yy193; + if (yych == 'E') goto yy405; + if (yych == 'e') goto yy405; + goto yy193; yy413: YYDEBUG(413, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy414; - if (yych != 'n') goto yy193; + if (yych == 'A') goto yy414; + if (yych != 'a') goto yy193; yy414: YYDEBUG(414, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy415; - if (yych != 'g') goto yy193; + if (yych == 'L') goto yy405; + if (yych == 'l') goto yy405; + goto yy193; yy415: YYDEBUG(415, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy416; + if (yych != 'r') goto yy193; +yy416: + YYDEBUG(416, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy417; + if (yych != 'i') goto yy193; +yy417: + YYDEBUG(417, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy418; + if (yych != 'n') goto yy193; +yy418: + YYDEBUG(418, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy419; + if (yych != 'g') goto yy193; +yy419: + YYDEBUG(419, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(416, *YYCURSOR); + YYDEBUG(420, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy415; + if (yych == '\t') goto yy419; goto yy193; } else { - if (yych <= ' ') goto yy415; + if (yych <= ' ') goto yy419; if (yych != ')') goto yy193; } - YYDEBUG(417, *YYCURSOR); + YYDEBUG(421, *YYCURSOR); ++YYCURSOR; - YYDEBUG(418, *YYCURSOR); + YYDEBUG(422, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1207 "Zend/zend_language_scanner.l" +#line 1208 "Zend/zend_language_scanner.l" { return T_STRING_CAST; } -#line 4804 "Zend/zend_language_scanner.c" -yy419: - YYDEBUG(419, *YYCURSOR); +#line 4849 "Zend/zend_language_scanner.c" +yy423: + YYDEBUG(423, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy420; + if (yych == 'R') goto yy424; if (yych != 'r') goto yy193; -yy420: - YYDEBUG(420, *YYCURSOR); +yy424: + YYDEBUG(424, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy421; + if (yych == 'A') goto yy425; if (yych != 'a') goto yy193; -yy421: - YYDEBUG(421, *YYCURSOR); +yy425: + YYDEBUG(425, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy422; + if (yych == 'Y') goto yy426; if (yych != 'y') goto yy193; -yy422: - YYDEBUG(422, *YYCURSOR); +yy426: + YYDEBUG(426, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(423, *YYCURSOR); + YYDEBUG(427, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy422; + if (yych == '\t') goto yy426; goto yy193; } else { - if (yych <= ' ') goto yy422; + if (yych <= ' ') goto yy426; if (yych != ')') goto yy193; } - YYDEBUG(424, *YYCURSOR); + YYDEBUG(428, *YYCURSOR); ++YYCURSOR; - YYDEBUG(425, *YYCURSOR); + YYDEBUG(429, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1211 "Zend/zend_language_scanner.l" +#line 1212 "Zend/zend_language_scanner.l" { return T_ARRAY_CAST; } -#line 4841 "Zend/zend_language_scanner.c" -yy426: - YYDEBUG(426, *YYCURSOR); +#line 4886 "Zend/zend_language_scanner.c" +yy430: + YYDEBUG(430, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'J') goto yy427; + if (yych == 'J') goto yy431; if (yych != 'j') goto yy193; -yy427: - YYDEBUG(427, *YYCURSOR); +yy431: + YYDEBUG(431, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy428; + if (yych == 'E') goto yy432; if (yych != 'e') goto yy193; -yy428: - YYDEBUG(428, *YYCURSOR); +yy432: + YYDEBUG(432, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy429; + if (yych == 'C') goto yy433; if (yych != 'c') goto yy193; -yy429: - YYDEBUG(429, *YYCURSOR); +yy433: + YYDEBUG(433, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy430; + if (yych == 'T') goto yy434; if (yych != 't') goto yy193; -yy430: - YYDEBUG(430, *YYCURSOR); +yy434: + YYDEBUG(434, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(431, *YYCURSOR); + YYDEBUG(435, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy430; + if (yych == '\t') goto yy434; goto yy193; } else { - if (yych <= ' ') goto yy430; + if (yych <= ' ') goto yy434; if (yych != ')') goto yy193; } - YYDEBUG(432, *YYCURSOR); + YYDEBUG(436, *YYCURSOR); ++YYCURSOR; - YYDEBUG(433, *YYCURSOR); + YYDEBUG(437, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1215 "Zend/zend_language_scanner.l" +#line 1216 "Zend/zend_language_scanner.l" { return T_OBJECT_CAST; } -#line 4883 "Zend/zend_language_scanner.c" -yy434: - YYDEBUG(434, *YYCURSOR); +#line 4928 "Zend/zend_language_scanner.c" +yy438: + YYDEBUG(438, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy444; - if (yych == 'n') goto yy444; + if (yych == 'N') goto yy448; + if (yych == 'n') goto yy448; goto yy193; -yy435: - YYDEBUG(435, *YYCURSOR); +yy439: + YYDEBUG(439, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy436; + if (yych == 'O') goto yy440; if (yych != 'o') goto yy193; -yy436: - YYDEBUG(436, *YYCURSOR); +yy440: + YYDEBUG(440, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy437; + if (yych == 'L') goto yy441; if (yych != 'l') goto yy193; -yy437: - YYDEBUG(437, *YYCURSOR); +yy441: + YYDEBUG(441, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy442; - if (yych == 'e') goto yy442; - goto yy439; -yy438: - YYDEBUG(438, *YYCURSOR); + if (yych == 'E') goto yy446; + if (yych == 'e') goto yy446; + goto yy443; +yy442: + YYDEBUG(442, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy439: - YYDEBUG(439, *YYCURSOR); +yy443: + YYDEBUG(443, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy438; + if (yych == '\t') goto yy442; goto yy193; } else { - if (yych <= ' ') goto yy438; + if (yych <= ' ') goto yy442; if (yych != ')') goto yy193; } - YYDEBUG(440, *YYCURSOR); + YYDEBUG(444, *YYCURSOR); ++YYCURSOR; - YYDEBUG(441, *YYCURSOR); + YYDEBUG(445, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1219 "Zend/zend_language_scanner.l" +#line 1220 "Zend/zend_language_scanner.l" { return T_BOOL_CAST; } -#line 4928 "Zend/zend_language_scanner.c" -yy442: - YYDEBUG(442, *YYCURSOR); +#line 4973 "Zend/zend_language_scanner.c" +yy446: + YYDEBUG(446, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy443; + if (yych == 'A') goto yy447; if (yych != 'a') goto yy193; -yy443: - YYDEBUG(443, *YYCURSOR); +yy447: + YYDEBUG(447, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy438; - if (yych == 'n') goto yy438; + if (yych == 'N') goto yy442; + if (yych == 'n') goto yy442; goto yy193; -yy444: - YYDEBUG(444, *YYCURSOR); +yy448: + YYDEBUG(448, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy445; + if (yych == 'A') goto yy449; if (yych != 'a') goto yy193; -yy445: - YYDEBUG(445, *YYCURSOR); +yy449: + YYDEBUG(449, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy446; + if (yych == 'R') goto yy450; if (yych != 'r') goto yy193; -yy446: - YYDEBUG(446, *YYCURSOR); +yy450: + YYDEBUG(450, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy415; - if (yych == 'y') goto yy415; + if (yych == 'Y') goto yy419; + if (yych == 'y') goto yy419; goto yy193; -yy447: - YYDEBUG(447, *YYCURSOR); +yy451: + YYDEBUG(451, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy448; + if (yych == 'S') goto yy452; if (yych != 's') goto yy193; -yy448: - YYDEBUG(448, *YYCURSOR); +yy452: + YYDEBUG(452, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy449; + if (yych == 'E') goto yy453; if (yych != 'e') goto yy193; -yy449: - YYDEBUG(449, *YYCURSOR); +yy453: + YYDEBUG(453, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy450; + if (yych == 'T') goto yy454; if (yych != 't') goto yy193; -yy450: - YYDEBUG(450, *YYCURSOR); +yy454: + YYDEBUG(454, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(451, *YYCURSOR); + YYDEBUG(455, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy450; + if (yych == '\t') goto yy454; goto yy193; } else { - if (yych <= ' ') goto yy450; + if (yych <= ' ') goto yy454; if (yych != ')') goto yy193; } - YYDEBUG(452, *YYCURSOR); + YYDEBUG(456, *YYCURSOR); ++YYCURSOR; - YYDEBUG(453, *YYCURSOR); + YYDEBUG(457, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1223 "Zend/zend_language_scanner.l" +#line 1224 "Zend/zend_language_scanner.l" { return T_UNSET_CAST; } -#line 4992 "Zend/zend_language_scanner.c" -yy454: - YYDEBUG(454, *YYCURSOR); +#line 5037 "Zend/zend_language_scanner.c" +yy458: + YYDEBUG(458, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy455; + if (yych == 'R') goto yy459; if (yych != 'r') goto yy186; -yy455: - YYDEBUG(455, *YYCURSOR); +yy459: + YYDEBUG(459, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(456, *YYCURSOR); + YYDEBUG(460, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1195 "Zend/zend_language_scanner.l" +#line 1196 "Zend/zend_language_scanner.l" { return T_VAR; } -#line 5010 "Zend/zend_language_scanner.c" -yy457: - YYDEBUG(457, *YYCURSOR); +#line 5055 "Zend/zend_language_scanner.c" +yy461: + YYDEBUG(461, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy461; - if (yych == 'm') goto yy461; + if (yych == 'M') goto yy465; + if (yych == 'm') goto yy465; goto yy186; -yy458: - YYDEBUG(458, *YYCURSOR); +yy462: + YYDEBUG(462, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy459; + if (yych == 'W') goto yy463; if (yych != 'w') goto yy186; -yy459: - YYDEBUG(459, *YYCURSOR); +yy463: + YYDEBUG(463, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(460, *YYCURSOR); + YYDEBUG(464, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1187 "Zend/zend_language_scanner.l" +#line 1188 "Zend/zend_language_scanner.l" { return T_NEW; } -#line 5034 "Zend/zend_language_scanner.c" -yy461: - YYDEBUG(461, *YYCURSOR); +#line 5079 "Zend/zend_language_scanner.c" +yy465: + YYDEBUG(465, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy462; + if (yych == 'E') goto yy466; if (yych != 'e') goto yy186; -yy462: - YYDEBUG(462, *YYCURSOR); +yy466: + YYDEBUG(466, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy463; + if (yych == 'S') goto yy467; if (yych != 's') goto yy186; -yy463: - YYDEBUG(463, *YYCURSOR); +yy467: + YYDEBUG(467, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy464; + if (yych == 'P') goto yy468; if (yych != 'p') goto yy186; -yy464: - YYDEBUG(464, *YYCURSOR); +yy468: + YYDEBUG(468, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy465; + if (yych == 'A') goto yy469; if (yych != 'a') goto yy186; -yy465: - YYDEBUG(465, *YYCURSOR); +yy469: + YYDEBUG(469, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy466; + if (yych == 'C') goto yy470; if (yych != 'c') goto yy186; -yy466: - YYDEBUG(466, *YYCURSOR); +yy470: + YYDEBUG(470, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy467; + if (yych == 'E') goto yy471; if (yych != 'e') goto yy186; -yy467: - YYDEBUG(467, *YYCURSOR); +yy471: + YYDEBUG(471, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(468, *YYCURSOR); + YYDEBUG(472, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1247 "Zend/zend_language_scanner.l" +#line 1248 "Zend/zend_language_scanner.l" { return T_NAMESPACE; } -#line 5077 "Zend/zend_language_scanner.c" -yy469: - YYDEBUG(469, *YYCURSOR); +#line 5122 "Zend/zend_language_scanner.c" +yy473: + YYDEBUG(473, *YYCURSOR); ++YYCURSOR; - YYDEBUG(470, *YYCURSOR); + YYDEBUG(474, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1179 "Zend/zend_language_scanner.l" +#line 1180 "Zend/zend_language_scanner.l" { return T_PAAMAYIM_NEKUDOTAYIM; } -#line 5087 "Zend/zend_language_scanner.c" -yy471: - YYDEBUG(471, *YYCURSOR); +#line 5132 "Zend/zend_language_scanner.c" +yy475: + YYDEBUG(475, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy472: - YYDEBUG(472, *YYCURSOR); +yy476: + YYDEBUG(476, *YYCURSOR); if (yych <= '\f') { if (yych <= 0x08) goto yy140; - if (yych <= '\n') goto yy471; + if (yych <= '\n') goto yy475; goto yy140; } else { - if (yych <= '\r') goto yy471; - if (yych == ' ') goto yy471; + if (yych <= '\r') goto yy475; + if (yych == ' ') goto yy475; goto yy140; } -yy473: - YYDEBUG(473, *YYCURSOR); +yy477: + YYDEBUG(477, *YYCURSOR); ++YYCURSOR; - YYDEBUG(474, *YYCURSOR); + YYDEBUG(478, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1351 "Zend/zend_language_scanner.l" +#line 1352 "Zend/zend_language_scanner.l" { return T_MINUS_EQUAL; } -#line 5113 "Zend/zend_language_scanner.c" -yy475: - YYDEBUG(475, *YYCURSOR); +#line 5158 "Zend/zend_language_scanner.c" +yy479: + YYDEBUG(479, *YYCURSOR); ++YYCURSOR; - YYDEBUG(476, *YYCURSOR); + YYDEBUG(480, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1319 "Zend/zend_language_scanner.l" +#line 1320 "Zend/zend_language_scanner.l" { return T_DEC; } -#line 5123 "Zend/zend_language_scanner.c" -yy477: - YYDEBUG(477, *YYCURSOR); +#line 5168 "Zend/zend_language_scanner.c" +yy481: + YYDEBUG(481, *YYCURSOR); ++YYCURSOR; - YYDEBUG(478, *YYCURSOR); + YYDEBUG(482, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1149 "Zend/zend_language_scanner.l" +#line 1150 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); return T_OBJECT_OPERATOR; } -#line 5134 "Zend/zend_language_scanner.c" -yy479: - YYDEBUG(479, *YYCURSOR); +#line 5179 "Zend/zend_language_scanner.c" +yy483: + YYDEBUG(483, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'I') goto yy486; + if (yych == 'I') goto yy490; if (yych <= 'N') goto yy186; - goto yy487; + goto yy491; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; - goto yy486; + goto yy490; } else { - if (yych == 'o') goto yy487; + if (yych == 'o') goto yy491; goto yy186; } } -yy480: - YYDEBUG(480, *YYCURSOR); +yy484: + YYDEBUG(484, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy481; + if (yych == 'B') goto yy485; if (yych != 'b') goto yy186; -yy481: - YYDEBUG(481, *YYCURSOR); +yy485: + YYDEBUG(485, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy482; + if (yych == 'L') goto yy486; if (yych != 'l') goto yy186; -yy482: - YYDEBUG(482, *YYCURSOR); +yy486: + YYDEBUG(486, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy483; + if (yych == 'I') goto yy487; if (yych != 'i') goto yy186; -yy483: - YYDEBUG(483, *YYCURSOR); +yy487: + YYDEBUG(487, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy484; + if (yych == 'C') goto yy488; if (yych != 'c') goto yy186; -yy484: - YYDEBUG(484, *YYCURSOR); +yy488: + YYDEBUG(488, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(485, *YYCURSOR); + YYDEBUG(489, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1295 "Zend/zend_language_scanner.l" +#line 1296 "Zend/zend_language_scanner.l" { return T_PUBLIC; } -#line 5183 "Zend/zend_language_scanner.c" -yy486: - YYDEBUG(486, *YYCURSOR); +#line 5228 "Zend/zend_language_scanner.c" +yy490: + YYDEBUG(490, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'V') { - if (yych == 'N') goto yy495; + if (yych == 'N') goto yy499; if (yych <= 'U') goto yy186; - goto yy496; + goto yy500; } else { if (yych <= 'n') { if (yych <= 'm') goto yy186; - goto yy495; + goto yy499; } else { - if (yych == 'v') goto yy496; + if (yych == 'v') goto yy500; goto yy186; } } -yy487: - YYDEBUG(487, *YYCURSOR); +yy491: + YYDEBUG(491, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy488; + if (yych == 'T') goto yy492; if (yych != 't') goto yy186; -yy488: - YYDEBUG(488, *YYCURSOR); +yy492: + YYDEBUG(492, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy489; + if (yych == 'E') goto yy493; if (yych != 'e') goto yy186; -yy489: - YYDEBUG(489, *YYCURSOR); +yy493: + YYDEBUG(493, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy490; + if (yych == 'C') goto yy494; if (yych != 'c') goto yy186; -yy490: - YYDEBUG(490, *YYCURSOR); +yy494: + YYDEBUG(494, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy491; + if (yych == 'T') goto yy495; if (yych != 't') goto yy186; -yy491: - YYDEBUG(491, *YYCURSOR); +yy495: + YYDEBUG(495, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy492; + if (yych == 'E') goto yy496; if (yych != 'e') goto yy186; -yy492: - YYDEBUG(492, *YYCURSOR); +yy496: + YYDEBUG(496, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy493; + if (yych == 'D') goto yy497; if (yych != 'd') goto yy186; -yy493: - YYDEBUG(493, *YYCURSOR); +yy497: + YYDEBUG(497, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(494, *YYCURSOR); + YYDEBUG(498, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1291 "Zend/zend_language_scanner.l" +#line 1292 "Zend/zend_language_scanner.l" { return T_PROTECTED; } -#line 5242 "Zend/zend_language_scanner.c" -yy495: - YYDEBUG(495, *YYCURSOR); +#line 5287 "Zend/zend_language_scanner.c" +yy499: + YYDEBUG(499, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy501; - if (yych == 't') goto yy501; + if (yych == 'T') goto yy505; + if (yych == 't') goto yy505; goto yy186; -yy496: - YYDEBUG(496, *YYCURSOR); +yy500: + YYDEBUG(500, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy497; + if (yych == 'A') goto yy501; if (yych != 'a') goto yy186; -yy497: - YYDEBUG(497, *YYCURSOR); +yy501: + YYDEBUG(501, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy498; + if (yych == 'T') goto yy502; if (yych != 't') goto yy186; -yy498: - YYDEBUG(498, *YYCURSOR); +yy502: + YYDEBUG(502, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy499; + if (yych == 'E') goto yy503; if (yych != 'e') goto yy186; -yy499: - YYDEBUG(499, *YYCURSOR); +yy503: + YYDEBUG(503, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(500, *YYCURSOR); + YYDEBUG(504, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1287 "Zend/zend_language_scanner.l" +#line 1288 "Zend/zend_language_scanner.l" { return T_PRIVATE; } -#line 5276 "Zend/zend_language_scanner.c" -yy501: - YYDEBUG(501, *YYCURSOR); +#line 5321 "Zend/zend_language_scanner.c" +yy505: + YYDEBUG(505, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(502, *YYCURSOR); + YYDEBUG(506, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1125 "Zend/zend_language_scanner.l" +#line 1126 "Zend/zend_language_scanner.l" { return T_PRINT; } -#line 5289 "Zend/zend_language_scanner.c" -yy503: - YYDEBUG(503, *YYCURSOR); +#line 5334 "Zend/zend_language_scanner.c" +yy507: + YYDEBUG(507, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy508; - if (yych == 'o') goto yy508; + if (yych == 'O') goto yy512; + if (yych == 'o') goto yy512; goto yy186; -yy504: - YYDEBUG(504, *YYCURSOR); +yy508: + YYDEBUG(508, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy505; + if (yych == 'T') goto yy509; if (yych != 't') goto yy186; -yy505: - YYDEBUG(505, *YYCURSOR); +yy509: + YYDEBUG(509, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy506; + if (yych == 'O') goto yy510; if (yych != 'o') goto yy186; -yy506: - YYDEBUG(506, *YYCURSOR); +yy510: + YYDEBUG(510, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(507, *YYCURSOR); + YYDEBUG(511, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1117 "Zend/zend_language_scanner.l" +#line 1118 "Zend/zend_language_scanner.l" { return T_GOTO; } -#line 5318 "Zend/zend_language_scanner.c" -yy508: - YYDEBUG(508, *YYCURSOR); +#line 5363 "Zend/zend_language_scanner.c" +yy512: + YYDEBUG(512, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy509; + if (yych == 'B') goto yy513; if (yych != 'b') goto yy186; -yy509: - YYDEBUG(509, *YYCURSOR); +yy513: + YYDEBUG(513, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy510; + if (yych == 'A') goto yy514; if (yych != 'a') goto yy186; -yy510: - YYDEBUG(510, *YYCURSOR); +yy514: + YYDEBUG(514, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy511; + if (yych == 'L') goto yy515; if (yych != 'l') goto yy186; -yy511: - YYDEBUG(511, *YYCURSOR); +yy515: + YYDEBUG(515, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(512, *YYCURSOR); + YYDEBUG(516, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1259 "Zend/zend_language_scanner.l" +#line 1260 "Zend/zend_language_scanner.l" { return T_GLOBAL; } -#line 5346 "Zend/zend_language_scanner.c" -yy513: - YYDEBUG(513, *YYCURSOR); +#line 5391 "Zend/zend_language_scanner.c" +yy517: + YYDEBUG(517, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '<') goto yy521; + if (yych == '<') goto yy525; goto yy193; -yy514: - YYDEBUG(514, *YYCURSOR); +yy518: + YYDEBUG(518, *YYCURSOR); yych = *++YYCURSOR; goto yy180; -yy515: - YYDEBUG(515, *YYCURSOR); +yy519: + YYDEBUG(519, *YYCURSOR); yych = *++YYCURSOR; goto yy178; -yy516: - YYDEBUG(516, *YYCURSOR); +yy520: + YYDEBUG(520, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy517; + if (yych == 'E') goto yy521; if (yych != 'e') goto yy186; -yy517: - YYDEBUG(517, *YYCURSOR); +yy521: + YYDEBUG(521, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy518; + if (yych == 'A') goto yy522; if (yych != 'a') goto yy186; -yy518: - YYDEBUG(518, *YYCURSOR); +yy522: + YYDEBUG(522, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'K') goto yy519; + if (yych == 'K') goto yy523; if (yych != 'k') goto yy186; -yy519: - YYDEBUG(519, *YYCURSOR); +yy523: + YYDEBUG(523, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(520, *YYCURSOR); + YYDEBUG(524, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1109 "Zend/zend_language_scanner.l" +#line 1110 "Zend/zend_language_scanner.l" { return T_BREAK; } -#line 5387 "Zend/zend_language_scanner.c" -yy521: - YYDEBUG(521, *YYCURSOR); +#line 5432 "Zend/zend_language_scanner.c" +yy525: + YYDEBUG(525, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '<') goto yy265; + if (yych == '<') goto yy269; goto yy193; -yy522: - YYDEBUG(522, *YYCURSOR); +yy526: + YYDEBUG(526, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy529; - if (yych == 'a') goto yy529; + if (yych == 'A') goto yy533; + if (yych == 'a') goto yy533; goto yy186; -yy523: - YYDEBUG(523, *YYCURSOR); +yy527: + YYDEBUG(527, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy524; + if (yych == 'I') goto yy528; if (yych != 'i') goto yy186; -yy524: - YYDEBUG(524, *YYCURSOR); +yy528: + YYDEBUG(528, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy525; + if (yych == 'T') goto yy529; if (yych != 't') goto yy186; -yy525: - YYDEBUG(525, *YYCURSOR); +yy529: + YYDEBUG(529, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy526; + if (yych == 'C') goto yy530; if (yych != 'c') goto yy186; -yy526: - YYDEBUG(526, *YYCURSOR); +yy530: + YYDEBUG(530, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy527; + if (yych == 'H') goto yy531; if (yych != 'h') goto yy186; -yy527: - YYDEBUG(527, *YYCURSOR); +yy531: + YYDEBUG(531, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(528, *YYCURSOR); + YYDEBUG(532, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1093 "Zend/zend_language_scanner.l" +#line 1094 "Zend/zend_language_scanner.l" { return T_SWITCH; } -#line 5431 "Zend/zend_language_scanner.c" -yy529: - YYDEBUG(529, *YYCURSOR); +#line 5476 "Zend/zend_language_scanner.c" +yy533: + YYDEBUG(533, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy530; + if (yych == 'T') goto yy534; if (yych != 't') goto yy186; -yy530: - YYDEBUG(530, *YYCURSOR); +yy534: + YYDEBUG(534, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy531; + if (yych == 'I') goto yy535; if (yych != 'i') goto yy186; -yy531: - YYDEBUG(531, *YYCURSOR); +yy535: + YYDEBUG(535, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy532; + if (yych == 'C') goto yy536; if (yych != 'c') goto yy186; -yy532: - YYDEBUG(532, *YYCURSOR); +yy536: + YYDEBUG(536, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(533, *YYCURSOR); + YYDEBUG(537, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1275 "Zend/zend_language_scanner.l" +#line 1276 "Zend/zend_language_scanner.l" { return T_STATIC; } -#line 5459 "Zend/zend_language_scanner.c" -yy534: - YYDEBUG(534, *YYCURSOR); +#line 5504 "Zend/zend_language_scanner.c" +yy538: + YYDEBUG(538, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy545; - if (yych == 's') goto yy545; + if (yych == 'S') goto yy549; + if (yych == 's') goto yy549; goto yy186; -yy535: - YYDEBUG(535, *YYCURSOR); +yy539: + YYDEBUG(539, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy543; - if (yych == 'd') goto yy543; + if (yych == 'D') goto yy547; + if (yych == 'd') goto yy547; goto yy186; -yy536: - YYDEBUG(536, *YYCURSOR); +yy540: + YYDEBUG(540, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy539; - if (yych == 'r') goto yy539; + if (yych == 'R') goto yy543; + if (yych == 'r') goto yy543; goto yy186; -yy537: - YYDEBUG(537, *YYCURSOR); +yy541: + YYDEBUG(541, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(538, *YYCURSOR); + YYDEBUG(542, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1089 "Zend/zend_language_scanner.l" +#line 1090 "Zend/zend_language_scanner.l" { return T_AS; } -#line 5490 "Zend/zend_language_scanner.c" -yy539: - YYDEBUG(539, *YYCURSOR); +#line 5535 "Zend/zend_language_scanner.c" +yy543: + YYDEBUG(543, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy540; + if (yych == 'A') goto yy544; if (yych != 'a') goto yy186; -yy540: - YYDEBUG(540, *YYCURSOR); +yy544: + YYDEBUG(544, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy541; + if (yych == 'Y') goto yy545; if (yych != 'y') goto yy186; -yy541: - YYDEBUG(541, *YYCURSOR); +yy545: + YYDEBUG(545, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(542, *YYCURSOR); + YYDEBUG(546, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1311 "Zend/zend_language_scanner.l" +#line 1312 "Zend/zend_language_scanner.l" { return T_ARRAY; } -#line 5513 "Zend/zend_language_scanner.c" -yy543: - YYDEBUG(543, *YYCURSOR); +#line 5558 "Zend/zend_language_scanner.c" +yy547: + YYDEBUG(547, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(544, *YYCURSOR); + YYDEBUG(548, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1403 "Zend/zend_language_scanner.l" +#line 1404 "Zend/zend_language_scanner.l" { return T_LOGICAL_AND; } -#line 5526 "Zend/zend_language_scanner.c" -yy545: - YYDEBUG(545, *YYCURSOR); +#line 5571 "Zend/zend_language_scanner.c" +yy549: + YYDEBUG(549, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy546; + if (yych == 'T') goto yy550; if (yych != 't') goto yy186; -yy546: - YYDEBUG(546, *YYCURSOR); +yy550: + YYDEBUG(550, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy547; + if (yych == 'R') goto yy551; if (yych != 'r') goto yy186; -yy547: - YYDEBUG(547, *YYCURSOR); +yy551: + YYDEBUG(551, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy548; + if (yych == 'A') goto yy552; if (yych != 'a') goto yy186; -yy548: - YYDEBUG(548, *YYCURSOR); +yy552: + YYDEBUG(552, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy549; + if (yych == 'C') goto yy553; if (yych != 'c') goto yy186; -yy549: - YYDEBUG(549, *YYCURSOR); +yy553: + YYDEBUG(553, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy550; + if (yych == 'T') goto yy554; if (yych != 't') goto yy186; -yy550: - YYDEBUG(550, *YYCURSOR); +yy554: + YYDEBUG(554, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(551, *YYCURSOR); + YYDEBUG(555, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1279 "Zend/zend_language_scanner.l" +#line 1280 "Zend/zend_language_scanner.l" { return T_ABSTRACT; } -#line 5564 "Zend/zend_language_scanner.c" -yy552: - YYDEBUG(552, *YYCURSOR); +#line 5609 "Zend/zend_language_scanner.c" +yy556: + YYDEBUG(556, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy553; + if (yych == 'I') goto yy557; if (yych != 'i') goto yy186; -yy553: - YYDEBUG(553, *YYCURSOR); +yy557: + YYDEBUG(557, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy554; + if (yych == 'L') goto yy558; if (yych != 'l') goto yy186; -yy554: - YYDEBUG(554, *YYCURSOR); +yy558: + YYDEBUG(558, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy555; + if (yych == 'E') goto yy559; if (yych != 'e') goto yy186; -yy555: - YYDEBUG(555, *YYCURSOR); +yy559: + YYDEBUG(559, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(556, *YYCURSOR); + YYDEBUG(560, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1049 "Zend/zend_language_scanner.l" +#line 1050 "Zend/zend_language_scanner.l" { return T_WHILE; } -#line 5592 "Zend/zend_language_scanner.c" -yy557: - YYDEBUG(557, *YYCURSOR); +#line 5637 "Zend/zend_language_scanner.c" +yy561: + YYDEBUG(561, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(558, *YYCURSOR); + YYDEBUG(562, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1033 "Zend/zend_language_scanner.l" +#line 1034 "Zend/zend_language_scanner.l" { return T_IF; } -#line 5605 "Zend/zend_language_scanner.c" -yy559: - YYDEBUG(559, *YYCURSOR); +#line 5650 "Zend/zend_language_scanner.c" +yy563: + YYDEBUG(563, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy601; - if (yych == 'p') goto yy601; + if (yych == 'P') goto yy605; + if (yych == 'p') goto yy605; goto yy186; -yy560: - YYDEBUG(560, *YYCURSOR); +yy564: + YYDEBUG(564, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'C') { if (yych <= 'B') goto yy186; - goto yy568; + goto yy572; } else { if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy566; - goto yy567; + if (yych <= 'S') goto yy570; + goto yy571; } } else { if (yych <= 'r') { - if (yych == 'c') goto yy568; + if (yych == 'c') goto yy572; goto yy186; } else { - if (yych <= 's') goto yy566; - if (yych <= 't') goto yy567; + if (yych <= 's') goto yy570; + if (yych <= 't') goto yy571; goto yy186; } } -yy561: - YYDEBUG(561, *YYCURSOR); +yy565: + YYDEBUG(565, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy562; + if (yych == 'S') goto yy566; if (yych != 's') goto yy186; -yy562: - YYDEBUG(562, *YYCURSOR); +yy566: + YYDEBUG(566, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy563; + if (yych == 'E') goto yy567; if (yych != 'e') goto yy186; -yy563: - YYDEBUG(563, *YYCURSOR); +yy567: + YYDEBUG(567, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy564; + if (yych == 'T') goto yy568; if (yych != 't') goto yy186; -yy564: - YYDEBUG(564, *YYCURSOR); +yy568: + YYDEBUG(568, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(565, *YYCURSOR); + YYDEBUG(569, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1263 "Zend/zend_language_scanner.l" +#line 1264 "Zend/zend_language_scanner.l" { return T_ISSET; } -#line 5661 "Zend/zend_language_scanner.c" -yy566: - YYDEBUG(566, *YYCURSOR); +#line 5706 "Zend/zend_language_scanner.c" +yy570: + YYDEBUG(570, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy587; - if (yych == 't') goto yy587; + if (yych == 'T') goto yy591; + if (yych == 't') goto yy591; goto yy186; -yy567: - YYDEBUG(567, *YYCURSOR); +yy571: + YYDEBUG(571, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy580; - if (yych == 'e') goto yy580; + if (yych == 'E') goto yy584; + if (yych == 'e') goto yy584; goto yy186; -yy568: - YYDEBUG(568, *YYCURSOR); +yy572: + YYDEBUG(572, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy569; + if (yych == 'L') goto yy573; if (yych != 'l') goto yy186; -yy569: - YYDEBUG(569, *YYCURSOR); +yy573: + YYDEBUG(573, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy570; + if (yych == 'U') goto yy574; if (yych != 'u') goto yy186; -yy570: - YYDEBUG(570, *YYCURSOR); +yy574: + YYDEBUG(574, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy571; + if (yych == 'D') goto yy575; if (yych != 'd') goto yy186; -yy571: - YYDEBUG(571, *YYCURSOR); +yy575: + YYDEBUG(575, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy572; + if (yych == 'E') goto yy576; if (yych != 'e') goto yy186; -yy572: - YYDEBUG(572, *YYCURSOR); +yy576: + YYDEBUG(576, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '9') { if (yych >= '0') goto yy185; } else { - if (yych <= '@') goto yy573; + if (yych <= '@') goto yy577; if (yych <= 'Z') goto yy185; } } else { if (yych <= '`') { - if (yych <= '_') goto yy574; + if (yych <= '_') goto yy578; } else { if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy573: - YYDEBUG(573, *YYCURSOR); +yy577: + YYDEBUG(577, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1231 "Zend/zend_language_scanner.l" +#line 1232 "Zend/zend_language_scanner.l" { return T_INCLUDE; } -#line 5719 "Zend/zend_language_scanner.c" -yy574: - YYDEBUG(574, *YYCURSOR); +#line 5764 "Zend/zend_language_scanner.c" +yy578: + YYDEBUG(578, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy575; + if (yych == 'O') goto yy579; if (yych != 'o') goto yy186; -yy575: - YYDEBUG(575, *YYCURSOR); +yy579: + YYDEBUG(579, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy576; + if (yych == 'N') goto yy580; if (yych != 'n') goto yy186; -yy576: - YYDEBUG(576, *YYCURSOR); +yy580: + YYDEBUG(580, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy577; + if (yych == 'C') goto yy581; if (yych != 'c') goto yy186; -yy577: - YYDEBUG(577, *YYCURSOR); +yy581: + YYDEBUG(581, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy578; + if (yych == 'E') goto yy582; if (yych != 'e') goto yy186; -yy578: - YYDEBUG(578, *YYCURSOR); +yy582: + YYDEBUG(582, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(579, *YYCURSOR); + YYDEBUG(583, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1235 "Zend/zend_language_scanner.l" +#line 1236 "Zend/zend_language_scanner.l" { return T_INCLUDE_ONCE; } -#line 5752 "Zend/zend_language_scanner.c" -yy580: - YYDEBUG(580, *YYCURSOR); +#line 5797 "Zend/zend_language_scanner.c" +yy584: + YYDEBUG(584, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy581; + if (yych == 'R') goto yy585; if (yych != 'r') goto yy186; -yy581: - YYDEBUG(581, *YYCURSOR); +yy585: + YYDEBUG(585, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy582; + if (yych == 'F') goto yy586; if (yych != 'f') goto yy186; -yy582: - YYDEBUG(582, *YYCURSOR); +yy586: + YYDEBUG(586, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy583; + if (yych == 'A') goto yy587; if (yych != 'a') goto yy186; -yy583: - YYDEBUG(583, *YYCURSOR); +yy587: + YYDEBUG(587, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy584; + if (yych == 'C') goto yy588; if (yych != 'c') goto yy186; -yy584: - YYDEBUG(584, *YYCURSOR); +yy588: + YYDEBUG(588, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy585; + if (yych == 'E') goto yy589; if (yych != 'e') goto yy186; -yy585: - YYDEBUG(585, *YYCURSOR); +yy589: + YYDEBUG(589, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(586, *YYCURSOR); + YYDEBUG(590, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1133 "Zend/zend_language_scanner.l" +#line 1134 "Zend/zend_language_scanner.l" { return T_INTERFACE; } -#line 5790 "Zend/zend_language_scanner.c" -yy587: - YYDEBUG(587, *YYCURSOR); +#line 5835 "Zend/zend_language_scanner.c" +yy591: + YYDEBUG(591, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'E') { - if (yych == 'A') goto yy588; + if (yych == 'A') goto yy592; if (yych <= 'D') goto yy186; - goto yy589; + goto yy593; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; } else { - if (yych == 'e') goto yy589; + if (yych == 'e') goto yy593; goto yy186; } } -yy588: - YYDEBUG(588, *YYCURSOR); +yy592: + YYDEBUG(592, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy595; - if (yych == 'n') goto yy595; + if (yych == 'N') goto yy599; + if (yych == 'n') goto yy599; goto yy186; -yy589: - YYDEBUG(589, *YYCURSOR); +yy593: + YYDEBUG(593, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy590; + if (yych == 'A') goto yy594; if (yych != 'a') goto yy186; -yy590: - YYDEBUG(590, *YYCURSOR); +yy594: + YYDEBUG(594, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy591; + if (yych == 'D') goto yy595; if (yych != 'd') goto yy186; -yy591: - YYDEBUG(591, *YYCURSOR); +yy595: + YYDEBUG(595, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy592; + if (yych == 'O') goto yy596; if (yych != 'o') goto yy186; -yy592: - YYDEBUG(592, *YYCURSOR); +yy596: + YYDEBUG(596, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy593; + if (yych == 'F') goto yy597; if (yych != 'f') goto yy186; -yy593: - YYDEBUG(593, *YYCURSOR); +yy597: + YYDEBUG(597, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(594, *YYCURSOR); + YYDEBUG(598, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1255 "Zend/zend_language_scanner.l" +#line 1256 "Zend/zend_language_scanner.l" { return T_INSTEADOF; } -#line 5844 "Zend/zend_language_scanner.c" -yy595: - YYDEBUG(595, *YYCURSOR); +#line 5889 "Zend/zend_language_scanner.c" +yy599: + YYDEBUG(599, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy596; + if (yych == 'C') goto yy600; if (yych != 'c') goto yy186; -yy596: - YYDEBUG(596, *YYCURSOR); +yy600: + YYDEBUG(600, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy597; + if (yych == 'E') goto yy601; if (yych != 'e') goto yy186; -yy597: - YYDEBUG(597, *YYCURSOR); +yy601: + YYDEBUG(601, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy598; + if (yych == 'O') goto yy602; if (yych != 'o') goto yy186; -yy598: - YYDEBUG(598, *YYCURSOR); +yy602: + YYDEBUG(602, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy599; - if (yych != 'f') goto yy186; -yy599: - YYDEBUG(599, *YYCURSOR); + if (yych == 'F') goto yy603; + if (yych != 'f') goto yy186; +yy603: + YYDEBUG(603, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(600, *YYCURSOR); + YYDEBUG(604, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1085 "Zend/zend_language_scanner.l" +#line 1086 "Zend/zend_language_scanner.l" { return T_INSTANCEOF; } -#line 5877 "Zend/zend_language_scanner.c" -yy601: - YYDEBUG(601, *YYCURSOR); +#line 5922 "Zend/zend_language_scanner.c" +yy605: + YYDEBUG(605, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy602; + if (yych == 'L') goto yy606; if (yych != 'l') goto yy186; -yy602: - YYDEBUG(602, *YYCURSOR); +yy606: + YYDEBUG(606, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy603; + if (yych == 'E') goto yy607; if (yych != 'e') goto yy186; -yy603: - YYDEBUG(603, *YYCURSOR); +yy607: + YYDEBUG(607, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy604; + if (yych == 'M') goto yy608; if (yych != 'm') goto yy186; -yy604: - YYDEBUG(604, *YYCURSOR); +yy608: + YYDEBUG(608, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy605; + if (yych == 'E') goto yy609; if (yych != 'e') goto yy186; -yy605: - YYDEBUG(605, *YYCURSOR); +yy609: + YYDEBUG(609, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy606; + if (yych == 'N') goto yy610; if (yych != 'n') goto yy186; -yy606: - YYDEBUG(606, *YYCURSOR); +yy610: + YYDEBUG(610, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy607; + if (yych == 'T') goto yy611; if (yych != 't') goto yy186; -yy607: - YYDEBUG(607, *YYCURSOR); +yy611: + YYDEBUG(611, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy608; + if (yych == 'S') goto yy612; if (yych != 's') goto yy186; -yy608: - YYDEBUG(608, *YYCURSOR); +yy612: + YYDEBUG(612, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(609, *YYCURSOR); + YYDEBUG(613, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1145 "Zend/zend_language_scanner.l" +#line 1146 "Zend/zend_language_scanner.l" { return T_IMPLEMENTS; } -#line 5925 "Zend/zend_language_scanner.c" -yy610: - YYDEBUG(610, *YYCURSOR); +#line 5970 "Zend/zend_language_scanner.c" +yy614: + YYDEBUG(614, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy618; - if (yych == 'r') goto yy618; + if (yych == 'R') goto yy622; + if (yych == 'r') goto yy622; goto yy186; -yy611: - YYDEBUG(611, *YYCURSOR); +yy615: + YYDEBUG(615, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'Y') { - if (yych == 'A') goto yy614; + if (yych == 'A') goto yy618; if (yych <= 'X') goto yy186; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy614; + goto yy618; } else { if (yych != 'y') goto yy186; } } - YYDEBUG(612, *YYCURSOR); + YYDEBUG(616, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(613, *YYCURSOR); + YYDEBUG(617, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1021 "Zend/zend_language_scanner.l" +#line 1022 "Zend/zend_language_scanner.l" { return T_TRY; } -#line 5957 "Zend/zend_language_scanner.c" -yy614: - YYDEBUG(614, *YYCURSOR); +#line 6002 "Zend/zend_language_scanner.c" +yy618: + YYDEBUG(618, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy615; + if (yych == 'I') goto yy619; if (yych != 'i') goto yy186; -yy615: - YYDEBUG(615, *YYCURSOR); +yy619: + YYDEBUG(619, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy616; + if (yych == 'T') goto yy620; if (yych != 't') goto yy186; -yy616: - YYDEBUG(616, *YYCURSOR); +yy620: + YYDEBUG(620, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(617, *YYCURSOR); + YYDEBUG(621, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1137 "Zend/zend_language_scanner.l" +#line 1138 "Zend/zend_language_scanner.l" { return T_TRAIT; } -#line 5980 "Zend/zend_language_scanner.c" -yy618: - YYDEBUG(618, *YYCURSOR); +#line 6025 "Zend/zend_language_scanner.c" +yy622: + YYDEBUG(622, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy619; + if (yych == 'O') goto yy623; if (yych != 'o') goto yy186; -yy619: - YYDEBUG(619, *YYCURSOR); +yy623: + YYDEBUG(623, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy620; + if (yych == 'W') goto yy624; if (yych != 'w') goto yy186; -yy620: - YYDEBUG(620, *YYCURSOR); +yy624: + YYDEBUG(624, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(621, *YYCURSOR); + YYDEBUG(625, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1029 "Zend/zend_language_scanner.l" +#line 1030 "Zend/zend_language_scanner.l" { return T_THROW; } -#line 6003 "Zend/zend_language_scanner.c" -yy622: - YYDEBUG(622, *YYCURSOR); +#line 6048 "Zend/zend_language_scanner.c" +yy626: + YYDEBUG(626, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'Q') goto yy624; + if (yych == 'Q') goto yy628; if (yych <= 'S') goto yy186; } else { if (yych <= 'q') { if (yych <= 'p') goto yy186; - goto yy624; + goto yy628; } else { if (yych != 't') goto yy186; } } - YYDEBUG(623, *YYCURSOR); + YYDEBUG(627, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy636; - if (yych == 'u') goto yy636; + if (yych == 'U') goto yy640; + if (yych == 'u') goto yy640; goto yy186; -yy624: - YYDEBUG(624, *YYCURSOR); +yy628: + YYDEBUG(628, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy625; + if (yych == 'U') goto yy629; if (yych != 'u') goto yy186; -yy625: - YYDEBUG(625, *YYCURSOR); +yy629: + YYDEBUG(629, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy626; + if (yych == 'I') goto yy630; if (yych != 'i') goto yy186; -yy626: - YYDEBUG(626, *YYCURSOR); +yy630: + YYDEBUG(630, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy627; + if (yych == 'R') goto yy631; if (yych != 'r') goto yy186; -yy627: - YYDEBUG(627, *YYCURSOR); +yy631: + YYDEBUG(631, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy628; + if (yych == 'E') goto yy632; if (yych != 'e') goto yy186; -yy628: - YYDEBUG(628, *YYCURSOR); +yy632: + YYDEBUG(632, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '9') { if (yych >= '0') goto yy185; } else { - if (yych <= '@') goto yy629; + if (yych <= '@') goto yy633; if (yych <= 'Z') goto yy185; } } else { if (yych <= '`') { - if (yych <= '_') goto yy630; + if (yych <= '_') goto yy634; } else { if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy629: - YYDEBUG(629, *YYCURSOR); +yy633: + YYDEBUG(633, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1239 "Zend/zend_language_scanner.l" +#line 1240 "Zend/zend_language_scanner.l" { return T_REQUIRE; } -#line 6068 "Zend/zend_language_scanner.c" -yy630: - YYDEBUG(630, *YYCURSOR); +#line 6113 "Zend/zend_language_scanner.c" +yy634: + YYDEBUG(634, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy631; + if (yych == 'O') goto yy635; if (yych != 'o') goto yy186; -yy631: - YYDEBUG(631, *YYCURSOR); +yy635: + YYDEBUG(635, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy632; + if (yych == 'N') goto yy636; if (yych != 'n') goto yy186; -yy632: - YYDEBUG(632, *YYCURSOR); +yy636: + YYDEBUG(636, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy633; + if (yych == 'C') goto yy637; if (yych != 'c') goto yy186; -yy633: - YYDEBUG(633, *YYCURSOR); +yy637: + YYDEBUG(637, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy634; + if (yych == 'E') goto yy638; if (yych != 'e') goto yy186; -yy634: - YYDEBUG(634, *YYCURSOR); +yy638: + YYDEBUG(638, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(635, *YYCURSOR); + YYDEBUG(639, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1243 "Zend/zend_language_scanner.l" +#line 1244 "Zend/zend_language_scanner.l" { return T_REQUIRE_ONCE; } -#line 6101 "Zend/zend_language_scanner.c" -yy636: - YYDEBUG(636, *YYCURSOR); +#line 6146 "Zend/zend_language_scanner.c" +yy640: + YYDEBUG(640, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy637; + if (yych == 'R') goto yy641; if (yych != 'r') goto yy186; -yy637: - YYDEBUG(637, *YYCURSOR); +yy641: + YYDEBUG(641, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy638; + if (yych == 'N') goto yy642; if (yych != 'n') goto yy186; -yy638: - YYDEBUG(638, *YYCURSOR); +yy642: + YYDEBUG(642, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(639, *YYCURSOR); + YYDEBUG(643, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1017 "Zend/zend_language_scanner.l" +#line 1018 "Zend/zend_language_scanner.l" { return T_RETURN; } -#line 6124 "Zend/zend_language_scanner.c" -yy640: - YYDEBUG(640, *YYCURSOR); +#line 6169 "Zend/zend_language_scanner.c" +yy644: + YYDEBUG(644, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy662; - goto yy661; + if (yych <= 'S') goto yy666; + goto yy665; } else { if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy662; - if (yych <= 't') goto yy661; + if (yych <= 's') goto yy666; + if (yych <= 't') goto yy665; goto yy186; } -yy641: - YYDEBUG(641, *YYCURSOR); +yy645: + YYDEBUG(645, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'A') goto yy653; + if (yych == 'A') goto yy657; if (yych <= 'N') goto yy186; - goto yy654; + goto yy658; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy653; + goto yy657; } else { - if (yych == 'o') goto yy654; + if (yych == 'o') goto yy658; goto yy186; } } -yy642: - YYDEBUG(642, *YYCURSOR); +yy646: + YYDEBUG(646, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy643; + if (yych == 'N') goto yy647; if (yych != 'n') goto yy186; -yy643: - YYDEBUG(643, *YYCURSOR); +yy647: + YYDEBUG(647, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'R') goto yy186; - if (yych >= 'T') goto yy645; + if (yych >= 'T') goto yy649; } else { if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy644; - if (yych <= 't') goto yy645; + if (yych <= 's') goto yy648; + if (yych <= 't') goto yy649; goto yy186; } -yy644: - YYDEBUG(644, *YYCURSOR); +yy648: + YYDEBUG(648, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy651; - if (yych == 't') goto yy651; + if (yych == 'T') goto yy655; + if (yych == 't') goto yy655; goto yy186; -yy645: - YYDEBUG(645, *YYCURSOR); +yy649: + YYDEBUG(649, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy646; + if (yych == 'I') goto yy650; if (yych != 'i') goto yy186; -yy646: - YYDEBUG(646, *YYCURSOR); +yy650: + YYDEBUG(650, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy647; + if (yych == 'N') goto yy651; if (yych != 'n') goto yy186; -yy647: - YYDEBUG(647, *YYCURSOR); +yy651: + YYDEBUG(651, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy648; + if (yych == 'U') goto yy652; if (yych != 'u') goto yy186; -yy648: - YYDEBUG(648, *YYCURSOR); +yy652: + YYDEBUG(652, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy649; + if (yych == 'E') goto yy653; if (yych != 'e') goto yy186; -yy649: - YYDEBUG(649, *YYCURSOR); +yy653: + YYDEBUG(653, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(650, *YYCURSOR); + YYDEBUG(654, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1113 "Zend/zend_language_scanner.l" +#line 1114 "Zend/zend_language_scanner.l" { return T_CONTINUE; } -#line 6209 "Zend/zend_language_scanner.c" -yy651: - YYDEBUG(651, *YYCURSOR); +#line 6254 "Zend/zend_language_scanner.c" +yy655: + YYDEBUG(655, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(652, *YYCURSOR); + YYDEBUG(656, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1013 "Zend/zend_language_scanner.l" +#line 1014 "Zend/zend_language_scanner.l" { return T_CONST; } -#line 6222 "Zend/zend_language_scanner.c" -yy653: - YYDEBUG(653, *YYCURSOR); +#line 6267 "Zend/zend_language_scanner.c" +yy657: + YYDEBUG(657, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy658; - if (yych == 's') goto yy658; + if (yych == 'S') goto yy662; + if (yych == 's') goto yy662; goto yy186; -yy654: - YYDEBUG(654, *YYCURSOR); +yy658: + YYDEBUG(658, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy655; + if (yych == 'N') goto yy659; if (yych != 'n') goto yy186; -yy655: - YYDEBUG(655, *YYCURSOR); +yy659: + YYDEBUG(659, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy656; + if (yych == 'E') goto yy660; if (yych != 'e') goto yy186; -yy656: - YYDEBUG(656, *YYCURSOR); +yy660: + YYDEBUG(660, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(657, *YYCURSOR); + YYDEBUG(661, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1191 "Zend/zend_language_scanner.l" +#line 1192 "Zend/zend_language_scanner.l" { return T_CLONE; } -#line 6251 "Zend/zend_language_scanner.c" -yy658: - YYDEBUG(658, *YYCURSOR); +#line 6296 "Zend/zend_language_scanner.c" +yy662: + YYDEBUG(662, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy659; + if (yych == 'S') goto yy663; if (yych != 's') goto yy186; -yy659: - YYDEBUG(659, *YYCURSOR); +yy663: + YYDEBUG(663, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(660, *YYCURSOR); + YYDEBUG(664, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1129 "Zend/zend_language_scanner.l" +#line 1130 "Zend/zend_language_scanner.l" { return T_CLASS; } -#line 6269 "Zend/zend_language_scanner.c" -yy661: - YYDEBUG(661, *YYCURSOR); +#line 6314 "Zend/zend_language_scanner.c" +yy665: + YYDEBUG(665, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy665; - if (yych == 'c') goto yy665; + if (yych == 'C') goto yy669; + if (yych == 'c') goto yy669; goto yy186; -yy662: - YYDEBUG(662, *YYCURSOR); +yy666: + YYDEBUG(666, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy663; + if (yych == 'E') goto yy667; if (yych != 'e') goto yy186; -yy663: - YYDEBUG(663, *YYCURSOR); +yy667: + YYDEBUG(667, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(664, *YYCURSOR); + YYDEBUG(668, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1101 "Zend/zend_language_scanner.l" +#line 1102 "Zend/zend_language_scanner.l" { return T_CASE; } -#line 6293 "Zend/zend_language_scanner.c" -yy665: - YYDEBUG(665, *YYCURSOR); +#line 6338 "Zend/zend_language_scanner.c" +yy669: + YYDEBUG(669, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy666; + if (yych == 'H') goto yy670; if (yych != 'h') goto yy186; -yy666: - YYDEBUG(666, *YYCURSOR); +yy670: + YYDEBUG(670, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(667, *YYCURSOR); + YYDEBUG(671, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1025 "Zend/zend_language_scanner.l" +#line 1026 "Zend/zend_language_scanner.l" { return T_CATCH; } -#line 6311 "Zend/zend_language_scanner.c" -yy668: - YYDEBUG(668, *YYCURSOR); +#line 6356 "Zend/zend_language_scanner.c" +yy672: + YYDEBUG(672, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy685; - if (yych == 'n') goto yy685; + if (yych == 'N') goto yy689; + if (yych == 'n') goto yy689; goto yy186; -yy669: - YYDEBUG(669, *YYCURSOR); +yy673: + YYDEBUG(673, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy678; - if (yych == 'r') goto yy678; + if (yych == 'R') goto yy682; + if (yych == 'r') goto yy682; goto yy186; -yy670: - YYDEBUG(670, *YYCURSOR); +yy674: + YYDEBUG(674, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy671; + if (yych == 'N') goto yy675; if (yych != 'n') goto yy186; -yy671: - YYDEBUG(671, *YYCURSOR); +yy675: + YYDEBUG(675, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy672; + if (yych == 'C') goto yy676; if (yych != 'c') goto yy186; -yy672: - YYDEBUG(672, *YYCURSOR); +yy676: + YYDEBUG(676, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy673; + if (yych == 'T') goto yy677; if (yych != 't') goto yy186; -yy673: - YYDEBUG(673, *YYCURSOR); +yy677: + YYDEBUG(677, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy674; + if (yych == 'I') goto yy678; if (yych != 'i') goto yy186; -yy674: - YYDEBUG(674, *YYCURSOR); +yy678: + YYDEBUG(678, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy675; + if (yych == 'O') goto yy679; if (yych != 'o') goto yy186; -yy675: - YYDEBUG(675, *YYCURSOR); +yy679: + YYDEBUG(679, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy676; + if (yych == 'N') goto yy680; if (yych != 'n') goto yy186; -yy676: - YYDEBUG(676, *YYCURSOR); +yy680: + YYDEBUG(680, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(677, *YYCURSOR); + YYDEBUG(681, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1009 "Zend/zend_language_scanner.l" +#line 1010 "Zend/zend_language_scanner.l" { return T_FUNCTION; } -#line 6366 "Zend/zend_language_scanner.c" -yy678: - YYDEBUG(678, *YYCURSOR); +#line 6411 "Zend/zend_language_scanner.c" +yy682: + YYDEBUG(682, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy679; + if (yych <= '/') goto yy683; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy680; + if (yych == 'E') goto yy684; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy680; + if (yych <= 'e') goto yy684; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy679: - YYDEBUG(679, *YYCURSOR); +yy683: + YYDEBUG(683, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1061 "Zend/zend_language_scanner.l" +#line 1062 "Zend/zend_language_scanner.l" { return T_FOR; } -#line 6394 "Zend/zend_language_scanner.c" -yy680: - YYDEBUG(680, *YYCURSOR); +#line 6439 "Zend/zend_language_scanner.c" +yy684: + YYDEBUG(684, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy681; + if (yych == 'A') goto yy685; if (yych != 'a') goto yy186; -yy681: - YYDEBUG(681, *YYCURSOR); +yy685: + YYDEBUG(685, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy682; + if (yych == 'C') goto yy686; if (yych != 'c') goto yy186; -yy682: - YYDEBUG(682, *YYCURSOR); +yy686: + YYDEBUG(686, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy683; + if (yych == 'H') goto yy687; if (yych != 'h') goto yy186; -yy683: - YYDEBUG(683, *YYCURSOR); +yy687: + YYDEBUG(687, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(684, *YYCURSOR); + YYDEBUG(688, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1069 "Zend/zend_language_scanner.l" +#line 1070 "Zend/zend_language_scanner.l" { return T_FOREACH; } -#line 6422 "Zend/zend_language_scanner.c" -yy685: - YYDEBUG(685, *YYCURSOR); +#line 6467 "Zend/zend_language_scanner.c" +yy689: + YYDEBUG(689, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy686; + if (yych == 'A') goto yy690; if (yych != 'a') goto yy186; -yy686: - YYDEBUG(686, *YYCURSOR); +yy690: + YYDEBUG(690, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy687; + if (yych == 'L') goto yy691; if (yych != 'l') goto yy186; -yy687: - YYDEBUG(687, *YYCURSOR); +yy691: + YYDEBUG(691, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(688, *YYCURSOR); + YYDEBUG(692, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1283 "Zend/zend_language_scanner.l" +#line 1284 "Zend/zend_language_scanner.l" { return T_FINAL; } -#line 6445 "Zend/zend_language_scanner.c" -yy689: - YYDEBUG(689, *YYCURSOR); +#line 6490 "Zend/zend_language_scanner.c" +yy693: + YYDEBUG(693, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'F') { - if (yych == 'C') goto yy695; + if (yych == 'C') goto yy699; if (yych <= 'E') goto yy186; - goto yy696; + goto yy700; } else { if (yych <= 'c') { if (yych <= 'b') goto yy186; - goto yy695; + goto yy699; } else { - if (yych == 'f') goto yy696; + if (yych == 'f') goto yy700; goto yy186; } } -yy690: - YYDEBUG(690, *YYCURSOR); +yy694: + YYDEBUG(694, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy693; - if (yych == 'e') goto yy693; + if (yych == 'E') goto yy697; + if (yych == 'e') goto yy697; goto yy186; -yy691: - YYDEBUG(691, *YYCURSOR); +yy695: + YYDEBUG(695, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(692, *YYCURSOR); + YYDEBUG(696, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1057 "Zend/zend_language_scanner.l" +#line 1058 "Zend/zend_language_scanner.l" { return T_DO; } -#line 6480 "Zend/zend_language_scanner.c" -yy693: - YYDEBUG(693, *YYCURSOR); +#line 6525 "Zend/zend_language_scanner.c" +yy697: + YYDEBUG(697, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(694, *YYCURSOR); + YYDEBUG(698, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1005 "Zend/zend_language_scanner.l" +#line 1006 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6493 "Zend/zend_language_scanner.c" -yy695: - YYDEBUG(695, *YYCURSOR); +#line 6538 "Zend/zend_language_scanner.c" +yy699: + YYDEBUG(699, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy702; - if (yych == 'l') goto yy702; + if (yych == 'L') goto yy706; + if (yych == 'l') goto yy706; goto yy186; -yy696: - YYDEBUG(696, *YYCURSOR); +yy700: + YYDEBUG(700, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy697; + if (yych == 'A') goto yy701; if (yych != 'a') goto yy186; -yy697: - YYDEBUG(697, *YYCURSOR); +yy701: + YYDEBUG(701, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy698; + if (yych == 'U') goto yy702; if (yych != 'u') goto yy186; -yy698: - YYDEBUG(698, *YYCURSOR); +yy702: + YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy699; + if (yych == 'L') goto yy703; if (yych != 'l') goto yy186; -yy699: - YYDEBUG(699, *YYCURSOR); +yy703: + YYDEBUG(703, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy700; + if (yych == 'T') goto yy704; if (yych != 't') goto yy186; -yy700: - YYDEBUG(700, *YYCURSOR); +yy704: + YYDEBUG(704, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(701, *YYCURSOR); + YYDEBUG(705, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1105 "Zend/zend_language_scanner.l" +#line 1106 "Zend/zend_language_scanner.l" { return T_DEFAULT; } -#line 6532 "Zend/zend_language_scanner.c" -yy702: - YYDEBUG(702, *YYCURSOR); +#line 6577 "Zend/zend_language_scanner.c" +yy706: + YYDEBUG(706, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy703; + if (yych == 'A') goto yy707; if (yych != 'a') goto yy186; -yy703: - YYDEBUG(703, *YYCURSOR); +yy707: + YYDEBUG(707, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy704; + if (yych == 'R') goto yy708; if (yych != 'r') goto yy186; -yy704: - YYDEBUG(704, *YYCURSOR); +yy708: + YYDEBUG(708, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy705; + if (yych == 'E') goto yy709; if (yych != 'e') goto yy186; -yy705: - YYDEBUG(705, *YYCURSOR); +yy709: + YYDEBUG(709, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(706, *YYCURSOR); + YYDEBUG(710, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1077 "Zend/zend_language_scanner.l" +#line 1078 "Zend/zend_language_scanner.l" { return T_DECLARE; } -#line 6560 "Zend/zend_language_scanner.c" -yy707: - YYDEBUG(707, *YYCURSOR); +#line 6605 "Zend/zend_language_scanner.c" +yy711: + YYDEBUG(711, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy769; - if (yych == 'h') goto yy769; + if (yych == 'H') goto yy773; + if (yych == 'h') goto yy773; goto yy186; -yy708: - YYDEBUG(708, *YYCURSOR); +yy712: + YYDEBUG(712, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy763; - if (yych == 's') goto yy763; + if (yych == 'S') goto yy767; + if (yych == 's') goto yy767; goto yy186; -yy709: - YYDEBUG(709, *YYCURSOR); +yy713: + YYDEBUG(713, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy759; - if (yych == 'p') goto yy759; + if (yych == 'P') goto yy763; + if (yych == 'p') goto yy763; goto yy186; -yy710: - YYDEBUG(710, *YYCURSOR); +yy714: + YYDEBUG(714, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy725; - if (yych == 'd') goto yy725; + if (yych == 'D') goto yy729; + if (yych == 'd') goto yy729; goto yy186; -yy711: - YYDEBUG(711, *YYCURSOR); +yy715: + YYDEBUG(715, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy722; - if (yych == 'a') goto yy722; + if (yych == 'A') goto yy726; + if (yych == 'a') goto yy726; goto yy186; -yy712: - YYDEBUG(712, *YYCURSOR); +yy716: + YYDEBUG(716, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'I') goto yy713; + if (yych == 'I') goto yy717; if (yych <= 'S') goto yy186; - goto yy714; + goto yy718; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; } else { - if (yych == 't') goto yy714; + if (yych == 't') goto yy718; goto yy186; } } -yy713: - YYDEBUG(713, *YYCURSOR); +yy717: + YYDEBUG(717, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy720; - if (yych == 't') goto yy720; + if (yych == 'T') goto yy724; + if (yych == 't') goto yy724; goto yy186; -yy714: - YYDEBUG(714, *YYCURSOR); +yy718: + YYDEBUG(718, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy715; + if (yych == 'E') goto yy719; if (yych != 'e') goto yy186; -yy715: - YYDEBUG(715, *YYCURSOR); +yy719: + YYDEBUG(719, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy716; + if (yych == 'N') goto yy720; if (yych != 'n') goto yy186; -yy716: - YYDEBUG(716, *YYCURSOR); +yy720: + YYDEBUG(720, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy717; + if (yych == 'D') goto yy721; if (yych != 'd') goto yy186; -yy717: - YYDEBUG(717, *YYCURSOR); +yy721: + YYDEBUG(721, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy718; + if (yych == 'S') goto yy722; if (yych != 's') goto yy186; -yy718: - YYDEBUG(718, *YYCURSOR); +yy722: + YYDEBUG(722, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(719, *YYCURSOR); + YYDEBUG(723, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1141 "Zend/zend_language_scanner.l" +#line 1142 "Zend/zend_language_scanner.l" { return T_EXTENDS; } -#line 6644 "Zend/zend_language_scanner.c" -yy720: - YYDEBUG(720, *YYCURSOR); +#line 6689 "Zend/zend_language_scanner.c" +yy724: + YYDEBUG(724, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(721, *YYCURSOR); + YYDEBUG(725, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1001 "Zend/zend_language_scanner.l" +#line 1002 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6657 "Zend/zend_language_scanner.c" -yy722: - YYDEBUG(722, *YYCURSOR); +#line 6702 "Zend/zend_language_scanner.c" +yy726: + YYDEBUG(726, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy723; + if (yych == 'L') goto yy727; if (yych != 'l') goto yy186; -yy723: - YYDEBUG(723, *YYCURSOR); +yy727: + YYDEBUG(727, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(724, *YYCURSOR); + YYDEBUG(728, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1227 "Zend/zend_language_scanner.l" +#line 1228 "Zend/zend_language_scanner.l" { return T_EVAL; } -#line 6675 "Zend/zend_language_scanner.c" -yy725: - YYDEBUG(725, *YYCURSOR); +#line 6720 "Zend/zend_language_scanner.c" +yy729: + YYDEBUG(729, *YYCURSOR); yych = *++YYCURSOR; YYDEBUG(-1, yych); switch (yych) { case 'D': - case 'd': goto yy726; + case 'd': goto yy730; case 'F': - case 'f': goto yy727; + case 'f': goto yy731; case 'I': - case 'i': goto yy728; + case 'i': goto yy732; case 'S': - case 's': goto yy729; + case 's': goto yy733; case 'W': - case 'w': goto yy730; + case 'w': goto yy734; default: goto yy186; } -yy726: - YYDEBUG(726, *YYCURSOR); +yy730: + YYDEBUG(730, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy752; - if (yych == 'e') goto yy752; + if (yych == 'E') goto yy756; + if (yych == 'e') goto yy756; goto yy186; -yy727: - YYDEBUG(727, *YYCURSOR); +yy731: + YYDEBUG(731, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy744; - if (yych == 'o') goto yy744; + if (yych == 'O') goto yy748; + if (yych == 'o') goto yy748; goto yy186; -yy728: - YYDEBUG(728, *YYCURSOR); +yy732: + YYDEBUG(732, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy742; - if (yych == 'f') goto yy742; + if (yych == 'F') goto yy746; + if (yych == 'f') goto yy746; goto yy186; -yy729: - YYDEBUG(729, *YYCURSOR); +yy733: + YYDEBUG(733, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy736; - if (yych == 'w') goto yy736; + if (yych == 'W') goto yy740; + if (yych == 'w') goto yy740; goto yy186; -yy730: - YYDEBUG(730, *YYCURSOR); +yy734: + YYDEBUG(734, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy731; + if (yych == 'H') goto yy735; if (yych != 'h') goto yy186; -yy731: - YYDEBUG(731, *YYCURSOR); +yy735: + YYDEBUG(735, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy732; + if (yych == 'I') goto yy736; if (yych != 'i') goto yy186; -yy732: - YYDEBUG(732, *YYCURSOR); +yy736: + YYDEBUG(736, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy733; + if (yych == 'L') goto yy737; if (yych != 'l') goto yy186; -yy733: - YYDEBUG(733, *YYCURSOR); +yy737: + YYDEBUG(737, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy734; + if (yych == 'E') goto yy738; if (yych != 'e') goto yy186; -yy734: - YYDEBUG(734, *YYCURSOR); +yy738: + YYDEBUG(738, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(735, *YYCURSOR); + YYDEBUG(739, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1053 "Zend/zend_language_scanner.l" +#line 1054 "Zend/zend_language_scanner.l" { return T_ENDWHILE; } -#line 6749 "Zend/zend_language_scanner.c" -yy736: - YYDEBUG(736, *YYCURSOR); +#line 6794 "Zend/zend_language_scanner.c" +yy740: + YYDEBUG(740, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy737; + if (yych == 'I') goto yy741; if (yych != 'i') goto yy186; -yy737: - YYDEBUG(737, *YYCURSOR); +yy741: + YYDEBUG(741, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy738; + if (yych == 'T') goto yy742; if (yych != 't') goto yy186; -yy738: - YYDEBUG(738, *YYCURSOR); +yy742: + YYDEBUG(742, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy739; + if (yych == 'C') goto yy743; if (yych != 'c') goto yy186; -yy739: - YYDEBUG(739, *YYCURSOR); +yy743: + YYDEBUG(743, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy740; + if (yych == 'H') goto yy744; if (yych != 'h') goto yy186; -yy740: - YYDEBUG(740, *YYCURSOR); +yy744: + YYDEBUG(744, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(741, *YYCURSOR); + YYDEBUG(745, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1097 "Zend/zend_language_scanner.l" +#line 1098 "Zend/zend_language_scanner.l" { return T_ENDSWITCH; } -#line 6782 "Zend/zend_language_scanner.c" -yy742: - YYDEBUG(742, *YYCURSOR); +#line 6827 "Zend/zend_language_scanner.c" +yy746: + YYDEBUG(746, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(743, *YYCURSOR); + YYDEBUG(747, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1041 "Zend/zend_language_scanner.l" +#line 1042 "Zend/zend_language_scanner.l" { return T_ENDIF; } -#line 6795 "Zend/zend_language_scanner.c" -yy744: - YYDEBUG(744, *YYCURSOR); +#line 6840 "Zend/zend_language_scanner.c" +yy748: + YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy745; + if (yych == 'R') goto yy749; if (yych != 'r') goto yy186; -yy745: - YYDEBUG(745, *YYCURSOR); +yy749: + YYDEBUG(749, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy746; + if (yych <= '/') goto yy750; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy747; + if (yych == 'E') goto yy751; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy747; + if (yych <= 'e') goto yy751; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy746: - YYDEBUG(746, *YYCURSOR); - yyleng = YYCURSOR - SCNG(yy_text); -#line 1065 "Zend/zend_language_scanner.l" - { - return T_ENDFOR; -} -#line 6828 "Zend/zend_language_scanner.c" -yy747: - YYDEBUG(747, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'A') goto yy748; - if (yych != 'a') goto yy186; -yy748: - YYDEBUG(748, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'C') goto yy749; - if (yych != 'c') goto yy186; -yy749: - YYDEBUG(749, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'H') goto yy750; - if (yych != 'h') goto yy186; yy750: YYDEBUG(750, *YYCURSOR); - ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { - goto yy185; - } - YYDEBUG(751, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1073 "Zend/zend_language_scanner.l" +#line 1066 "Zend/zend_language_scanner.l" { - return T_ENDFOREACH; + return T_ENDFOR; } -#line 6856 "Zend/zend_language_scanner.c" +#line 6873 "Zend/zend_language_scanner.c" +yy751: + YYDEBUG(751, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy752; + if (yych != 'a') goto yy186; yy752: YYDEBUG(752, *YYCURSOR); yych = *++YYCURSOR; @@ -6861,128 +6883,151 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy753: YYDEBUG(753, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy754; - if (yych != 'l') goto yy186; + if (yych == 'H') goto yy754; + if (yych != 'h') goto yy186; yy754: YYDEBUG(754, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'A') goto yy755; - if (yych != 'a') goto yy186; -yy755: + ++YYCURSOR; + if (yybm[0+(yych = *YYCURSOR)] & 4) { + goto yy185; + } YYDEBUG(755, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'R') goto yy756; - if (yych != 'r') goto yy186; + yyleng = YYCURSOR - SCNG(yy_text); +#line 1074 "Zend/zend_language_scanner.l" + { + return T_ENDFOREACH; +} +#line 6901 "Zend/zend_language_scanner.c" yy756: YYDEBUG(756, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy757; - if (yych != 'e') goto yy186; + if (yych == 'C') goto yy757; + if (yych != 'c') goto yy186; yy757: YYDEBUG(757, *YYCURSOR); - ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { - goto yy185; - } + yych = *++YYCURSOR; + if (yych == 'L') goto yy758; + if (yych != 'l') goto yy186; +yy758: YYDEBUG(758, *YYCURSOR); - yyleng = YYCURSOR - SCNG(yy_text); -#line 1081 "Zend/zend_language_scanner.l" - { - return T_ENDDECLARE; -} -#line 6894 "Zend/zend_language_scanner.c" + yych = *++YYCURSOR; + if (yych == 'A') goto yy759; + if (yych != 'a') goto yy186; yy759: YYDEBUG(759, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy760; - if (yych != 't') goto yy186; + if (yych == 'R') goto yy760; + if (yych != 'r') goto yy186; yy760: YYDEBUG(760, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy761; - if (yych != 'y') goto yy186; + if (yych == 'E') goto yy761; + if (yych != 'e') goto yy186; yy761: YYDEBUG(761, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } YYDEBUG(762, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1267 "Zend/zend_language_scanner.l" +#line 1082 "Zend/zend_language_scanner.l" { - return T_EMPTY; + return T_ENDDECLARE; } -#line 6917 "Zend/zend_language_scanner.c" +#line 6939 "Zend/zend_language_scanner.c" yy763: YYDEBUG(763, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy764; - if (yych != 'e') goto yy186; + if (yych == 'T') goto yy764; + if (yych != 't') goto yy186; yy764: YYDEBUG(764, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy765; + if (yych != 'y') goto yy186; +yy765: + YYDEBUG(765, *YYCURSOR); + ++YYCURSOR; + if (yybm[0+(yych = *YYCURSOR)] & 4) { + goto yy185; + } + YYDEBUG(766, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1268 "Zend/zend_language_scanner.l" + { + return T_EMPTY; +} +#line 6962 "Zend/zend_language_scanner.c" +yy767: + YYDEBUG(767, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy768; + if (yych != 'e') goto yy186; +yy768: + YYDEBUG(768, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy765; + if (yych <= '/') goto yy769; if (yych <= '9') goto yy185; } else { - if (yych == 'I') goto yy766; + if (yych == 'I') goto yy770; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'h') { if (yych != '`') goto yy185; } else { - if (yych <= 'i') goto yy766; + if (yych <= 'i') goto yy770; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy765: - YYDEBUG(765, *YYCURSOR); +yy769: + YYDEBUG(769, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1045 "Zend/zend_language_scanner.l" +#line 1046 "Zend/zend_language_scanner.l" { return T_ELSE; } -#line 6950 "Zend/zend_language_scanner.c" -yy766: - YYDEBUG(766, *YYCURSOR); +#line 6995 "Zend/zend_language_scanner.c" +yy770: + YYDEBUG(770, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy767; + if (yych == 'F') goto yy771; if (yych != 'f') goto yy186; -yy767: - YYDEBUG(767, *YYCURSOR); +yy771: + YYDEBUG(771, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(768, *YYCURSOR); + YYDEBUG(772, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1037 "Zend/zend_language_scanner.l" +#line 1038 "Zend/zend_language_scanner.l" { return T_ELSEIF; } -#line 6968 "Zend/zend_language_scanner.c" -yy769: - YYDEBUG(769, *YYCURSOR); +#line 7013 "Zend/zend_language_scanner.c" +yy773: + YYDEBUG(773, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy770; + if (yych == 'O') goto yy774; if (yych != 'o') goto yy186; -yy770: - YYDEBUG(770, *YYCURSOR); +yy774: + YYDEBUG(774, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 8) { + if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(771, *YYCURSOR); + YYDEBUG(775, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1121 "Zend/zend_language_scanner.l" +#line 1122 "Zend/zend_language_scanner.l" { return T_ECHO; } -#line 6986 "Zend/zend_language_scanner.c" +#line 7031 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7021,41 +7066,41 @@ int lex_scan(zval *zendlval TSRMLS_DC) 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, }; - YYDEBUG(772, *YYCURSOR); + YYDEBUG(776, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '-') { if (yych <= '\r') { - if (yych <= 0x08) goto yy780; - if (yych <= '\n') goto yy774; - if (yych <= '\f') goto yy780; + if (yych <= 0x08) goto yy784; + if (yych <= '\n') goto yy778; + if (yych <= '\f') goto yy784; } else { - if (yych == ' ') goto yy774; - if (yych <= ',') goto yy780; - goto yy776; + if (yych == ' ') goto yy778; + if (yych <= ',') goto yy784; + goto yy780; } } else { if (yych <= '_') { - if (yych <= '@') goto yy780; - if (yych <= 'Z') goto yy778; - if (yych <= '^') goto yy780; - goto yy778; + if (yych <= '@') goto yy784; + if (yych <= 'Z') goto yy782; + if (yych <= '^') goto yy784; + goto yy782; } else { - if (yych <= '`') goto yy780; - if (yych <= 'z') goto yy778; - if (yych <= '~') goto yy780; - goto yy778; + if (yych <= '`') goto yy784; + if (yych <= 'z') goto yy782; + if (yych <= '~') goto yy784; + goto yy782; } } -yy774: - YYDEBUG(774, *YYCURSOR); +yy778: + YYDEBUG(778, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy786; -yy775: - YYDEBUG(775, *YYCURSOR); + goto yy790; +yy779: + YYDEBUG(779, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1154 "Zend/zend_language_scanner.l" +#line 1155 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -7063,73 +7108,73 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7067 "Zend/zend_language_scanner.c" -yy776: - YYDEBUG(776, *YYCURSOR); +#line 7112 "Zend/zend_language_scanner.c" +yy780: + YYDEBUG(780, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '>') goto yy783; -yy777: - YYDEBUG(777, *YYCURSOR); + if ((yych = *YYCURSOR) == '>') goto yy787; +yy781: + YYDEBUG(781, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1173 "Zend/zend_language_scanner.l" +#line 1174 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); goto restart; } -#line 7081 "Zend/zend_language_scanner.c" -yy778: - YYDEBUG(778, *YYCURSOR); +#line 7126 "Zend/zend_language_scanner.c" +yy782: + YYDEBUG(782, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy782; -yy779: - YYDEBUG(779, *YYCURSOR); + goto yy786; +yy783: + YYDEBUG(783, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1166 "Zend/zend_language_scanner.l" +#line 1167 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7097 "Zend/zend_language_scanner.c" -yy780: - YYDEBUG(780, *YYCURSOR); +#line 7142 "Zend/zend_language_scanner.c" +yy784: + YYDEBUG(784, *YYCURSOR); yych = *++YYCURSOR; - goto yy777; -yy781: - YYDEBUG(781, *YYCURSOR); + goto yy781; +yy785: + YYDEBUG(785, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy782: - YYDEBUG(782, *YYCURSOR); +yy786: + YYDEBUG(786, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy781; + goto yy785; } - goto yy779; -yy783: - YYDEBUG(783, *YYCURSOR); + goto yy783; +yy787: + YYDEBUG(787, *YYCURSOR); ++YYCURSOR; - YYDEBUG(784, *YYCURSOR); + YYDEBUG(788, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1162 "Zend/zend_language_scanner.l" +#line 1163 "Zend/zend_language_scanner.l" { return T_OBJECT_OPERATOR; } -#line 7122 "Zend/zend_language_scanner.c" -yy785: - YYDEBUG(785, *YYCURSOR); +#line 7167 "Zend/zend_language_scanner.c" +yy789: + YYDEBUG(789, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy786: - YYDEBUG(786, *YYCURSOR); +yy790: + YYDEBUG(790, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy785; + goto yy789; } - goto yy775; + goto yy779; } /* *********************************** */ yyc_ST_LOOKING_FOR_VARNAME: @@ -7168,27 +7213,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; - YYDEBUG(787, *YYCURSOR); + YYDEBUG(791, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '_') { - if (yych <= '@') goto yy791; - if (yych <= 'Z') goto yy789; - if (yych <= '^') goto yy791; + if (yych <= '@') goto yy795; + if (yych <= 'Z') goto yy793; + if (yych <= '^') goto yy795; } else { - if (yych <= '`') goto yy791; - if (yych <= 'z') goto yy789; - if (yych <= '~') goto yy791; + if (yych <= '`') goto yy795; + if (yych <= 'z') goto yy793; + if (yych <= '~') goto yy795; } -yy789: - YYDEBUG(789, *YYCURSOR); +yy793: + YYDEBUG(793, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy794; -yy790: - YYDEBUG(790, *YYCURSOR); + goto yy798; +yy794: + YYDEBUG(794, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1445 "Zend/zend_language_scanner.l" +#line 1446 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -7196,42 +7241,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7200 "Zend/zend_language_scanner.c" -yy791: - YYDEBUG(791, *YYCURSOR); +#line 7245 "Zend/zend_language_scanner.c" +yy795: + YYDEBUG(795, *YYCURSOR); ++YYCURSOR; - YYDEBUG(792, *YYCURSOR); + YYDEBUG(796, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1454 "Zend/zend_language_scanner.l" +#line 1455 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7213 "Zend/zend_language_scanner.c" -yy793: - YYDEBUG(793, *YYCURSOR); +#line 7258 "Zend/zend_language_scanner.c" +yy797: + YYDEBUG(797, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy794: - YYDEBUG(794, *YYCURSOR); +yy798: + YYDEBUG(798, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy793; + goto yy797; } - goto yy790; + goto yy794; } /* *********************************** */ yyc_ST_NOWDOC: - YYDEBUG(795, *YYCURSOR); + YYDEBUG(799, *YYCURSOR); YYFILL(1); yych = *YYCURSOR; - YYDEBUG(797, *YYCURSOR); + YYDEBUG(801, *YYCURSOR); ++YYCURSOR; - YYDEBUG(798, *YYCURSOR); + YYDEBUG(802, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2277 "Zend/zend_language_scanner.l" +#line 2298 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7286,7 +7331,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7290 "Zend/zend_language_scanner.c" +#line 7335 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7297,96 +7342,103 @@ int lex_scan(zval *zendlval TSRMLS_DC) 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 224, 224, 224, 224, 224, 224, 224, 224, - 224, 224, 0, 0, 0, 0, 0, 0, - 0, 160, 160, 160, 160, 160, 160, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 0, 0, 0, 0, 32, - 0, 160, 160, 160, 160, 160, 160, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 0, 0, 0, 0, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, - 32, 32, 32, 32, 32, 32, 32, 32, + 240, 240, 112, 112, 112, 112, 112, 112, + 112, 112, 0, 0, 0, 0, 0, 0, + 0, 80, 80, 80, 80, 80, 80, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 0, 0, 0, 0, 16, + 0, 80, 80, 80, 80, 80, 80, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 0, 0, 0, 0, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, + 16, 16, 16, 16, 16, 16, 16, 16, }; - YYDEBUG(799, *YYCURSOR); + YYDEBUG(803, *YYCURSOR); YYFILL(3); yych = *YYCURSOR; if (yych <= '/') { if (yych <= ' ') { if (yych <= '\f') { - if (yych <= 0x08) goto yy813; - if (yych <= '\n') goto yy809; - goto yy813; + if (yych <= 0x08) goto yy817; + if (yych <= '\n') goto yy813; + goto yy817; } else { - if (yych <= '\r') goto yy809; - if (yych <= 0x1F) goto yy813; - goto yy809; + if (yych <= '\r') goto yy813; + if (yych <= 0x1F) goto yy817; + goto yy813; } } else { if (yych <= '$') { - if (yych <= '"') goto yy808; - if (yych <= '#') goto yy809; - goto yy804; - } else { - if (yych == '\'') goto yy809; + if (yych <= '"') goto yy812; + if (yych <= '#') goto yy813; goto yy808; + } else { + if (yych == '\'') goto yy813; + goto yy812; } } } else { if (yych <= '\\') { if (yych <= '@') { - if (yych <= '0') goto yy801; - if (yych <= '9') goto yy803; - goto yy808; + if (yych <= '0') goto yy805; + if (yych <= '9') goto yy807; + goto yy812; } else { - if (yych <= 'Z') goto yy811; - if (yych <= '[') goto yy808; - goto yy809; + if (yych <= 'Z') goto yy815; + if (yych <= '[') goto yy812; + goto yy813; } } else { if (yych <= '_') { - if (yych <= ']') goto yy806; - if (yych <= '^') goto yy808; - goto yy811; + if (yych <= ']') goto yy810; + if (yych <= '^') goto yy812; + goto yy815; } else { - if (yych <= '`') goto yy808; - if (yych <= 'z') goto yy811; - if (yych <= '~') goto yy808; - goto yy811; + if (yych <= '`') goto yy812; + if (yych <= 'z') goto yy815; + if (yych <= '~') goto yy812; + goto yy815; } } } -yy801: - YYDEBUG(801, *YYCURSOR); +yy805: + YYDEBUG(805, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 'W') { - if (yych <= '/') goto yy802; - if (yych <= '9') goto yy824; + if (yych <= '9') { + if (yych >= '0') goto yy829; + } else { + if (yych == 'B') goto yy826; + } } else { - if (yych <= 'X') goto yy822; - if (yych == 'x') goto yy822; + if (yych <= 'b') { + if (yych <= 'X') goto yy828; + if (yych >= 'b') goto yy826; + } else { + if (yych == 'x') goto yy828; + } } -yy802: - YYDEBUG(802, *YYCURSOR); +yy806: + YYDEBUG(806, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1504 "Zend/zend_language_scanner.l" +#line 1525 "Zend/zend_language_scanner.l" { /* Offset could be treated as a long */ if (yyleng < MAX_LENGTH_OF_LONG - 1 || (yyleng == MAX_LENGTH_OF_LONG - 1 && strcmp(yytext, long_min_digits) < 0)) { zendlval->value.lval = strtol(yytext, NULL, 10); @@ -7398,81 +7450,81 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7402 "Zend/zend_language_scanner.c" -yy803: - YYDEBUG(803, *YYCURSOR); +#line 7454 "Zend/zend_language_scanner.c" +yy807: + YYDEBUG(807, *YYCURSOR); yych = *++YYCURSOR; - goto yy821; -yy804: - YYDEBUG(804, *YYCURSOR); + goto yy825; +yy808: + YYDEBUG(808, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '_') { - if (yych <= '@') goto yy805; - if (yych <= 'Z') goto yy817; - if (yych >= '_') goto yy817; + if (yych <= '@') goto yy809; + if (yych <= 'Z') goto yy821; + if (yych >= '_') goto yy821; } else { - if (yych <= '`') goto yy805; - if (yych <= 'z') goto yy817; - if (yych >= 0x7F) goto yy817; + if (yych <= '`') goto yy809; + if (yych <= 'z') goto yy821; + if (yych >= 0x7F) goto yy821; } -yy805: - YYDEBUG(805, *YYCURSOR); +yy809: + YYDEBUG(809, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1805 "Zend/zend_language_scanner.l" +#line 1826 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7427 "Zend/zend_language_scanner.c" -yy806: - YYDEBUG(806, *YYCURSOR); +#line 7479 "Zend/zend_language_scanner.c" +yy810: + YYDEBUG(810, *YYCURSOR); ++YYCURSOR; - YYDEBUG(807, *YYCURSOR); + YYDEBUG(811, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1800 "Zend/zend_language_scanner.l" +#line 1821 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7438 "Zend/zend_language_scanner.c" -yy808: - YYDEBUG(808, *YYCURSOR); +#line 7490 "Zend/zend_language_scanner.c" +yy812: + YYDEBUG(812, *YYCURSOR); yych = *++YYCURSOR; - goto yy805; -yy809: - YYDEBUG(809, *YYCURSOR); + goto yy809; +yy813: + YYDEBUG(813, *YYCURSOR); ++YYCURSOR; - YYDEBUG(810, *YYCURSOR); + YYDEBUG(814, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1810 "Zend/zend_language_scanner.l" +#line 1831 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7455 "Zend/zend_language_scanner.c" -yy811: - YYDEBUG(811, *YYCURSOR); +#line 7507 "Zend/zend_language_scanner.c" +yy815: + YYDEBUG(815, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy816; -yy812: - YYDEBUG(812, *YYCURSOR); + goto yy820; +yy816: + YYDEBUG(816, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1817 "Zend/zend_language_scanner.l" +#line 1838 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7470 "Zend/zend_language_scanner.c" -yy813: - YYDEBUG(813, *YYCURSOR); +#line 7522 "Zend/zend_language_scanner.c" +yy817: + YYDEBUG(817, *YYCURSOR); ++YYCURSOR; - YYDEBUG(814, *YYCURSOR); + YYDEBUG(818, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2333 "Zend/zend_language_scanner.l" +#line 2354 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7481,100 +7533,118 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7485 "Zend/zend_language_scanner.c" -yy815: - YYDEBUG(815, *YYCURSOR); +#line 7537 "Zend/zend_language_scanner.c" +yy819: + YYDEBUG(819, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy816: - YYDEBUG(816, *YYCURSOR); - if (yybm[0+yych] & 32) { - goto yy815; +yy820: + YYDEBUG(820, *YYCURSOR); + if (yybm[0+yych] & 16) { + goto yy819; } - goto yy812; -yy817: - YYDEBUG(817, *YYCURSOR); + goto yy816; +yy821: + YYDEBUG(821, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(818, *YYCURSOR); + YYDEBUG(822, *YYCURSOR); if (yych <= '^') { if (yych <= '9') { - if (yych >= '0') goto yy817; + if (yych >= '0') goto yy821; } else { - if (yych <= '@') goto yy819; - if (yych <= 'Z') goto yy817; + if (yych <= '@') goto yy823; + if (yych <= 'Z') goto yy821; } } else { if (yych <= '`') { - if (yych <= '_') goto yy817; + if (yych <= '_') goto yy821; } else { - if (yych <= 'z') goto yy817; - if (yych >= 0x7F) goto yy817; + if (yych <= 'z') goto yy821; + if (yych >= 0x7F) goto yy821; } } -yy819: - YYDEBUG(819, *YYCURSOR); +yy823: + YYDEBUG(823, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1794 "Zend/zend_language_scanner.l" +#line 1815 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7527 "Zend/zend_language_scanner.c" -yy820: - YYDEBUG(820, *YYCURSOR); +#line 7579 "Zend/zend_language_scanner.c" +yy824: + YYDEBUG(824, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy821: - YYDEBUG(821, *YYCURSOR); - if (yybm[0+yych] & 64) { - goto yy820; +yy825: + YYDEBUG(825, *YYCURSOR); + if (yybm[0+yych] & 32) { + goto yy824; } - goto yy802; -yy822: - YYDEBUG(822, *YYCURSOR); + goto yy806; +yy826: + YYDEBUG(826, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 128) { - goto yy827; + goto yy834; } - YYDEBUG(823, *YYCURSOR); +yy827: + YYDEBUG(827, *YYCURSOR); YYCURSOR = YYMARKER; - goto yy802; -yy824: - YYDEBUG(824, *YYCURSOR); + goto yy806; +yy828: + YYDEBUG(828, *YYCURSOR); + yych = *++YYCURSOR; + if (yybm[0+yych] & 64) { + goto yy832; + } + goto yy827; +yy829: + YYDEBUG(829, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(825, *YYCURSOR); - if (yych <= '/') goto yy826; - if (yych <= '9') goto yy824; -yy826: - YYDEBUG(826, *YYCURSOR); + YYDEBUG(830, *YYCURSOR); + if (yych <= '/') goto yy831; + if (yych <= '9') goto yy829; +yy831: + YYDEBUG(831, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1516 "Zend/zend_language_scanner.l" +#line 1537 "Zend/zend_language_scanner.l" { /* Offset must be treated as a string */ zendlval->value.str.val = (char *)estrndup(yytext, yyleng); zendlval->value.str.len = yyleng; zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7566 "Zend/zend_language_scanner.c" -yy827: - YYDEBUG(827, *YYCURSOR); +#line 7626 "Zend/zend_language_scanner.c" +yy832: + YYDEBUG(832, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(828, *YYCURSOR); + YYDEBUG(833, *YYCURSOR); + if (yybm[0+yych] & 64) { + goto yy832; + } + goto yy831; +yy834: + YYDEBUG(834, *YYCURSOR); + ++YYCURSOR; + YYFILL(1); + yych = *YYCURSOR; + YYDEBUG(835, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy827; + goto yy834; } - goto yy826; + goto yy831; } } -#line 2342 "Zend/zend_language_scanner.l" +#line 2363 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 8c04cf7602868..2af529d0bcbb0 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -987,6 +987,7 @@ LNUM [0-9]+ DNUM ([0-9]*"."[0-9]+)|([0-9]+"."[0-9]*) EXPONENT_DNUM (({LNUM}|{DNUM})[eE][+-]?{LNUM}) HNUM "0x"[0-9a-fA-F]+ +BNUM "0b"[01]+ LABEL [a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]* WHITESPACE [ \n\r\t]+ TABS_AND_SPACES [ \t]* @@ -1458,6 +1459,26 @@ NEWLINE ("\r"|"\n"|"\r\n") goto restart; } +{BNUM} { + char *bin = yytext + 2; /* Skip "0b" */ + int len = yyleng - 2; + + /* Skip any leading 0s */ + while (*bin == '0') { + ++bin; + --len; + } + + if (len < SIZEOF_LONG * 2) { + zendlval->value.lval = strtol(bin, NULL, 2); + zendlval->type = IS_LONG; + return T_LNUMBER; + } else { + zendlval->value.dval = zend_bin_strtod(bin, NULL); + zendlval->type = IS_DOUBLE; + return T_DNUMBER; + } +} {LNUM} { if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */ @@ -1513,7 +1534,7 @@ NEWLINE ("\r"|"\n"|"\r\n") return T_NUM_STRING; } -{LNUM}|{HNUM} { /* Offset must be treated as a string */ +{LNUM}|{HNUM}|{BNUM} { /* Offset must be treated as a string */ zendlval->value.str.val = (char *)estrndup(yytext, yyleng); zendlval->value.str.len = yyleng; zendlval->type = IS_STRING; diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 04997ff06038b..a6101740e7e1b 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Fri Jul 22 13:16:46 2011 */ +/* Generated by re2c 0.13.5 on Wed Jul 27 02:06:14 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_strtod.c b/Zend/zend_strtod.c index 62113bcd609b9..3f41f85a28c0a 100644 --- a/Zend/zend_strtod.c +++ b/Zend/zend_strtod.c @@ -2639,6 +2639,44 @@ ZEND_API double zend_oct_strtod(const char *str, const char **endptr) return value; } +ZEND_API double zend_bin_strtod(const char *str, const char **endptr) +{ + const char *s = str; + char c; + double value = 0; + int any = 0; + + if ('0' == *s && ('b' == s[1] || 'B' == s[1])) { + s += 2; + } + + while ((c = *s++)) { + /* + * Verify the validity of the current character as a base-2 digit. In + * the event that an invalid digit is found, halt the conversion and + * return the portion which has been converted thus far. + */ + if ('0' == c || '1' == c) + value = value * 2 + c - '0'; + else + break; + + any = 1; + } + + /* + * As with many strtoX implementations, should the subject sequence be + * empty or not well-formed, no conversion is performed and the original + * value of str is stored in *endptr, provided that endptr is not a null + * pointer. + */ + if (NULL != endptr) { + *endptr = (char *)(any ? s - 1 : str); + } + + return value; +} + /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_strtod.h b/Zend/zend_strtod.h index 67554d2be44a1..d847306825036 100644 --- a/Zend/zend_strtod.h +++ b/Zend/zend_strtod.h @@ -30,6 +30,7 @@ ZEND_API char * zend_dtoa(double _d, int mode, int ndigits, int *decpt, int *sig ZEND_API double zend_strtod(const char *s00, const char **se); ZEND_API double zend_hex_strtod(const char *str, const char **endptr); ZEND_API double zend_oct_strtod(const char *str, const char **endptr); +ZEND_API double zend_bin_strtod(const char *str, const char **endptr); ZEND_API int zend_startup_strtod(void); ZEND_API int zend_shutdown_strtod(void); END_EXTERN_C() From 011e29a9567b38bd6b176dcc256dffcb106e3e3a Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 00:18:35 +0000 Subject: [PATCH 0403/2394] - upgrading entry for binary number format --- UPGRADING | 3 +++ 1 file changed, 3 insertions(+) diff --git a/UPGRADING b/UPGRADING index dca9d20f2999c..6b2f6488c1bc9 100755 --- a/UPGRADING +++ b/UPGRADING @@ -462,3 +462,6 @@ UPGRADE NOTES - PHP X.Y $a = [1, 2, 3, 4]; $a = ['one' => 1, 'two' => 2, 'three' => 3, 'four' => 4]; $a = ['one' => 1, 2, 'three' => 3, 4]; + + - Binary number format + 0b00100 0b010101 From 4d28bb722bbb84c66afdb142b9d305d8634dc222 Mon Sep 17 00:00:00 2001 From: Peter Cowburn Date: Wed, 27 Jul 2011 08:48:08 +0000 Subject: [PATCH 0404/2394] added (recursive)callbackfilteriterator to spl_classes() (bug #55287) --- ext/spl/php_spl.c | 2 ++ ext/spl/spl_iterators.h | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/spl/php_spl.c b/ext/spl/php_spl.c index 5caa4c9825378..96615b6136ccb 100755 --- a/ext/spl/php_spl.c +++ b/ext/spl/php_spl.c @@ -205,6 +205,7 @@ PHP_FUNCTION(class_uses) SPL_ADD_CLASS(BadFunctionCallException, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(BadMethodCallException, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(CachingIterator, z_list, sub, allow, ce_flags); \ + SPL_ADD_CLASS(CallbackFilterIterator, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(Countable, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(DirectoryIterator, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(DomainException, z_list, sub, allow, ce_flags); \ @@ -228,6 +229,7 @@ PHP_FUNCTION(class_uses) SPL_ADD_CLASS(RangeException, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(RecursiveArrayIterator, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(RecursiveCachingIterator, z_list, sub, allow, ce_flags); \ + SPL_ADD_CLASS(RecursiveCallbackFilterIterator, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(RecursiveDirectoryIterator, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(RecursiveFilterIterator, z_list, sub, allow, ce_flags); \ SPL_ADD_CLASS(RecursiveIterator, z_list, sub, allow, ce_flags); \ diff --git a/ext/spl/spl_iterators.h b/ext/spl/spl_iterators.h index 9bbdd68751bc8..8860a11924187 100755 --- a/ext/spl/spl_iterators.h +++ b/ext/spl/spl_iterators.h @@ -52,6 +52,8 @@ extern PHPAPI zend_class_entry *spl_ce_AppendIterator; extern PHPAPI zend_class_entry *spl_ce_RegexIterator; extern PHPAPI zend_class_entry *spl_ce_RecursiveRegexIterator; extern PHPAPI zend_class_entry *spl_ce_Countable; +extern PHPAPI zend_class_entry *spl_ce_CallbackFilterIterator; +extern PHPAPI zend_class_entry *spl_ce_RecursiveCallbackFilterIterator; PHP_MINIT_FUNCTION(spl_iterators); From 2e1825830fcbe389fb8324656d1b20abf2c9232b Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 27 Jul 2011 10:26:59 +0000 Subject: [PATCH 0405/2394] longer error messages, don't cut them --- ext/mysqlnd/mysqlnd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index e6072e3201277..e02fd79099b03 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -931,9 +931,9 @@ MYSQLND_METHOD(mysqlnd_conn, connect)(MYSQLND * conn, PACKET_FREE(greet_packet); if (errstr) { - DBG_ERR_FMT("[%u] %.64s (trying to connect via %s)", errcode, errstr, conn->scheme); + DBG_ERR_FMT("[%u] %.128s (trying to connect via %s)", errcode, errstr, conn->scheme); SET_CLIENT_ERROR(conn->error_info, errcode? errcode:CR_CONNECTION_ERROR, UNKNOWN_SQLSTATE, errstr); - php_error_docref(NULL TSRMLS_CC, E_WARNING, "[%u] %.64s (trying to connect via %s)", errcode, errstr, conn->scheme); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "[%u] %.128s (trying to connect via %s)", errcode, errstr, conn->scheme); /* no mnd_ since we don't allocate it */ efree(errstr); } From 9f1689e4297650625718466a194cb59ecb48e6ff Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 11:57:44 +0000 Subject: [PATCH 0406/2394] - do not resolve the link if all we want is to open that file --- TSRM/tsrm_virtual_cwd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index 1ceaad7b15b6b..8b4025b561e9b 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -1453,7 +1453,7 @@ CWD_API FILE *virtual_fopen(const char *path, const char *mode TSRMLS_DC) /* {{{ } CWD_STATE_COPY(&new_state, &CWDG(cwd)); - if (virtual_file_ex(&new_state, path, NULL, CWD_FILEPATH TSRMLS_CC)) { + if (virtual_file_ex(&new_state, path, NULL, CWD_EXPAND TSRMLS_CC)) { CWD_STATE_FREE(&new_state); return NULL; } From df16bb2aef49083e073a0b08a181923aa8d98ba8 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 11:58:39 +0000 Subject: [PATCH 0407/2394] - WS --- TSRM/tsrm_virtual_cwd.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index 8b4025b561e9b..0c9b616db03a2 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -705,8 +705,7 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1; } else { CWDG(realpath_cache_size) -= sizeof(realpath_cache_bucket) + r->path_len + 1 + r->realpath_len + 1; - } - + } free(r); } else if (key == (*bucket)->key && path_len == (*bucket)->path_len && memcmp(path, (*bucket)->path, path_len) == 0) { From dd06894b56f3842c9709457b75a4e8a2e707f7fa Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 12:20:32 +0000 Subject: [PATCH 0408/2394] - do not resolve the link if all we want is to open that file --- main/fopen_wrappers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c index 2c18044b33432..f00127bc06570 100644 --- a/main/fopen_wrappers.c +++ b/main/fopen_wrappers.c @@ -348,7 +348,7 @@ static FILE *php_fopen_and_set_opened_path(const char *path, const char *mode, c } fp = VCWD_FOPEN(path, mode); if (fp && opened_path) { - *opened_path = expand_filepath(path, NULL TSRMLS_CC); + *opened_path = expand_filepath_with_mode(path, NULL, NULL, 0, CWD_EXPAND TSRMLS_CC); } return fp; } From 0beb0e7056302449aa3423327f5bec7ccd47b3be Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 27 Jul 2011 14:17:45 +0000 Subject: [PATCH 0409/2394] Check if given string is long enough in zend_*_strtod --- Zend/zend_strtod.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Zend/zend_strtod.c b/Zend/zend_strtod.c index 3f41f85a28c0a..c43587eef30bb 100644 --- a/Zend/zend_strtod.c +++ b/Zend/zend_strtod.c @@ -2585,6 +2585,11 @@ ZEND_API double zend_hex_strtod(const char *str, const char **endptr) int any = 0; double value = 0; + if (strlen(str) < 2) { + *endptr = str; + return 0.0; + } + if (*s == '0' && (s[1] == 'x' || s[1] == 'X')) { s += 2; } @@ -2618,6 +2623,11 @@ ZEND_API double zend_oct_strtod(const char *str, const char **endptr) double value = 0; int any = 0; + if (strlen(str) < 1) { + *endptr = str; + return 0.0; + } + /* skip leading zero */ s++; @@ -2646,6 +2656,11 @@ ZEND_API double zend_bin_strtod(const char *str, const char **endptr) double value = 0; int any = 0; + if (strlen(str) < 2) { + *endptr = str; + return 0.0; + } + if ('0' == *s && ('b' == s[1] || 'B' == s[1])) { s += 2; } From b2e3d0abd53375b0dbdacb74b9444c365ea997b3 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 14:23:06 +0000 Subject: [PATCH 0410/2394] - Fix #55295, check if malloc failed --- TSRM/tsrm_win32.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/TSRM/tsrm_win32.c b/TSRM/tsrm_win32.c index 6031cc29da14f..d49506636f454 100644 --- a/TSRM/tsrm_win32.c +++ b/TSRM/tsrm_win32.c @@ -530,6 +530,10 @@ TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd, } cmd = (char*)malloc(strlen(command)+strlen(TWG(comspec))+sizeof(" /c ")+2); + if (!cmd) { + return NULL; + } + sprintf(cmd, "%s /c \"%s\"", TWG(comspec), command); if (asuser) { res = CreateProcessAsUser(token_user, NULL, cmd, &security, &security, security.bInheritHandle, dwCreateFlags, env, cwd, &startup, &process); From 7b9071f71d14ae17813a931b80463ff4b26975c3 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 27 Jul 2011 14:58:30 +0000 Subject: [PATCH 0411/2394] - do safemode/open basedir checks 1st, and use only expand not realpath (it is done by the safemode/openbasedir check already) --- ext/fileinfo/fileinfo.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c index 3376c5d69bf33..6d8525c557d19 100644 --- a/ext/fileinfo/fileinfo.c +++ b/ext/fileinfo/fileinfo.c @@ -293,10 +293,6 @@ PHP_FUNCTION(finfo_open) if (file_len == 0) { file = NULL; } else if (file && *file) { /* user specified file, perform open_basedir checks */ - if (!VCWD_REALPATH(file, resolved_path)) { - RETURN_FALSE; - } - file = resolved_path; #if PHP_API_VERSION < 20100412 if ((PG(safe_mode) && (!php_checkuid(file, NULL, CHECKUID_CHECK_FILE_AND_DIR))) || php_check_open_basedir(file TSRMLS_CC)) { @@ -305,6 +301,10 @@ PHP_FUNCTION(finfo_open) #endif RETURN_FALSE; } + if (!expand_filepath_with_mode(file, resolved_path, NULL, 0, CWD_EXPAND TSRMLS_CC)) { + RETURN_FALSE; + } + file = resolved_path; } finfo = emalloc(sizeof(struct php_fileinfo)); From 8089b31002f73bdf488da444a0c634d36928852f Mon Sep 17 00:00:00 2001 From: Gopal Vijayaraghavan Date: Thu, 28 Jul 2011 03:03:06 +0000 Subject: [PATCH 0412/2394] merge to trunk - Allow zend_is_interned_string to be pluggable --- Zend/zend_string.c | 8 ++++++++ Zend/zend_string.h | 3 ++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/Zend/zend_string.c b/Zend/zend_string.c index 949c191582470..77b165ab20247 100644 --- a/Zend/zend_string.c +++ b/Zend/zend_string.c @@ -30,10 +30,12 @@ #endif ZEND_API const char *(*zend_new_interned_string)(const char *str, int len, int free_src TSRMLS_DC); +ZEND_API zend_bool (*zend_is_interned_string)(const char *str TSRMLS_DC); ZEND_API void (*zend_interned_strings_snapshot)(TSRMLS_D); ZEND_API void (*zend_interned_strings_restore)(TSRMLS_D); static const char *zend_new_interned_string_int(const char *str, int len, int free_src TSRMLS_DC); +static zend_bool zend_is_interned_string_int(const char *str TSRMLS_DC); static void zend_interned_strings_snapshot_int(TSRMLS_D); static void zend_interned_strings_restore_int(TSRMLS_D); @@ -64,6 +66,7 @@ void zend_interned_strings_init(TSRMLS_D) #endif zend_new_interned_string = zend_new_interned_string_int; + zend_is_interned_string = zend_is_interned_string_int; zend_interned_strings_snapshot = zend_interned_strings_snapshot_int; zend_interned_strings_restore = zend_interned_strings_restore_int; } @@ -177,6 +180,11 @@ static const char *zend_new_interned_string_int(const char *arKey, int nKeyLengt #endif } +static zend_bool zend_is_interned_string_int(const char *s TSRMLS_DC) +{ + return (((s) >= CG(interned_strings_start)) && ((s) < CG(interned_strings_end))); +} + static void zend_interned_strings_snapshot_int(TSRMLS_D) { CG(interned_strings_snapshot_top) = CG(interned_strings_top); diff --git a/Zend/zend_string.h b/Zend/zend_string.h index a130fbcc38386..5dcc950fafa0d 100644 --- a/Zend/zend_string.h +++ b/Zend/zend_string.h @@ -24,6 +24,7 @@ #include "zend.h" ZEND_API extern const char *(*zend_new_interned_string)(const char *str, int len, int free_src TSRMLS_DC); +ZEND_API extern zend_bool (*zend_is_interned_string)(const char *str TSRMLS_DC); ZEND_API extern void (*zend_interned_strings_snapshot)(TSRMLS_D); ZEND_API extern void (*zend_interned_strings_restore)(TSRMLS_D); @@ -33,7 +34,7 @@ void zend_interned_strings_dtor(TSRMLS_D); #ifndef ZTS #define IS_INTERNED(s) \ - (((s) >= CG(interned_strings_start)) && ((s) < CG(interned_strings_end))) + (zend_is_interned_string ? zend_is_interned_string((s) TSRMLS_CC) : 0) #else From 40b059de97252888ac7eae0131bb1c0e30cc1de4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:31:34 +0000 Subject: [PATCH 0413/2394] - Fix #55301 (curl part) check if malloc succeded --- ext/curl/interface.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index ce12171d60033..ff2aff07c1404 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -819,6 +819,9 @@ PHP_MINIT_FUNCTION(curl) int i, c = CRYPTO_num_locks(); php_curl_openssl_tsl = malloc(c * sizeof(MUTEX_T)); + if (!php_curl_openssl_tsl) { + return FAILURE; + } for (i = 0; i < c; ++i) { php_curl_openssl_tsl[i] = tsrm_mutex_alloc(); From 0c715414e0484234b4e7bce855b66df28b293299 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:34:16 +0000 Subject: [PATCH 0414/2394] - Fix #55301 (com_dotnet part) check if malloc succeded --- ext/com_dotnet/com_dotnet.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/com_dotnet/com_dotnet.c b/ext/com_dotnet/com_dotnet.c index 06291ab57dbf4..7c206f62953fc 100644 --- a/ext/com_dotnet/com_dotnet.c +++ b/ext/com_dotnet/com_dotnet.c @@ -129,6 +129,9 @@ static HRESULT dotnet_init(char **p_where TSRMLS_DC) char *where = ""; stuff = malloc(sizeof(*stuff)); + if (!stuff) { + return S_FALSE; + } memset(stuff, 0, sizeof(*stuff)); where = "CoCreateInstance"; From e28e0ef658d16927e25699217c2ea62f978d20af Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:37:04 +0000 Subject: [PATCH 0415/2394] - Fix #55301 (pdo_odbc part) check if malloc succeded --- ext/pdo_odbc/pdo_odbc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/pdo_odbc/pdo_odbc.c b/ext/pdo_odbc/pdo_odbc.c index 69ac263ac7e66..bc71aada53c9a 100755 --- a/ext/pdo_odbc/pdo_odbc.c +++ b/ext/pdo_odbc/pdo_odbc.c @@ -98,6 +98,9 @@ PHP_MINIT_FUNCTION(pdo_odbc) char *instance = INI_STR("pdo_odbc.db2_instance_name"); if (instance) { char *env = malloc(sizeof("DB2INSTANCE=") + strlen(instance)); + if (!env) { + return FAILURE; + } strcpy(env, "DB2INSTANCE="); strcat(env, instance); putenv(env); From 27cb62423caa06769a023e59664bb2189485aaf4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:39:08 +0000 Subject: [PATCH 0416/2394] - Fix #55301 (interbase part) check if malloc succeded --- ext/interbase/interbase.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ext/interbase/interbase.c b/ext/interbase/interbase.c index 1e1440cbd3f80..6578469852ceb 100644 --- a/ext/interbase/interbase.c +++ b/ext/interbase/interbase.c @@ -998,9 +998,12 @@ static void _php_ibase_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) /* ZEND_REGISTER_RESOURCE(return_value, ib_link, le_link); } else { zend_rsrc_list_entry new_le; - + ib_link = (ibase_db_link *) malloc(sizeof(ibase_db_link)); - + if (!ib_link) { + RETURN_FALSE; + } + /* hash it up */ Z_TYPE(new_le) = le_plink; new_le.ptr = ib_link; From 7053100f3dc9e3c083b030cc4f574e8bc2430924 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:42:45 +0000 Subject: [PATCH 0417/2394] - Fix #55301 (readline part) check if malloc succeded --- ext/readline/readline.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ext/readline/readline.c b/ext/readline/readline.c index a5d0f7d2bac37..e9cdacb275a4c 100644 --- a/ext/readline/readline.c +++ b/ext/readline/readline.c @@ -478,6 +478,9 @@ static char **_readline_completion_cb(const char *text, int start, int end) matches = rl_completion_matches(text,_readline_command_generator); } else { matches = malloc(sizeof(char *) * 2); + if (!matches) { + return NULL; + } matches[0] = strdup(""); matches[1] = '\0'; } @@ -518,7 +521,10 @@ PHP_FUNCTION(readline_completion_function) zval_copy_ctor(_readline_completion); rl_attempted_completion_function = _readline_completion_cb; - + if (rl_attempted_completion_function == NULL) { + efree(name); + RETURN_FALSE; + } RETURN_TRUE; } From 96b142795cf361ea078b248ba542f8261cdb0245 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:52:45 +0000 Subject: [PATCH 0418/2394] - Fix #55301 (url scanner part) check if malloc succeded --- ext/standard/url_scanner_ex.c | 7 +++++-- ext/standard/url_scanner_ex.re | 8 ++++++-- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ext/standard/url_scanner_ex.c b/ext/standard/url_scanner_ex.c index f9c017ff93b77..d883d4dfa3293 100644 --- a/ext/standard/url_scanner_ex.c +++ b/ext/standard/url_scanner_ex.c @@ -57,9 +57,12 @@ static PHP_INI_MH(OnUpdateTags) if (ctx->tags) zend_hash_destroy(ctx->tags); - else + else { ctx->tags = malloc(sizeof(HashTable)); - + if (!ctx->tags) { + return FAILURE; + } + } zend_hash_init(ctx->tags, 0, NULL, NULL, 1); for (key = php_strtok_r(tmp, ",", &lasts); diff --git a/ext/standard/url_scanner_ex.re b/ext/standard/url_scanner_ex.re index 7994925b1c080..e7218a14f1f54 100644 --- a/ext/standard/url_scanner_ex.re +++ b/ext/standard/url_scanner_ex.re @@ -55,9 +55,13 @@ static PHP_INI_MH(OnUpdateTags) if (ctx->tags) zend_hash_destroy(ctx->tags); - else + else { ctx->tags = malloc(sizeof(HashTable)); - + if (!ctx->tags) { + return FAILURE; + } + } + zend_hash_init(ctx->tags, 0, NULL, NULL, 1); for (key = php_strtok_r(tmp, ",", &lasts); From 5703457cd08f5774ba4f83bbb0f3c70d47a9c3a9 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 10:58:28 +0000 Subject: [PATCH 0419/2394] - Fix #55301 (sybase part) check if malloc succeded --- ext/sybase_ct/php_sybase_ct.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index 3c8b7bd223a4b..5429a3c88d9dd 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -777,6 +777,10 @@ static void php_sybase_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) } sybase_ptr = (sybase_link *) malloc(sizeof(sybase_link)); + if (sybase_ptr) { + efree(hashed_details); + RETURN_FALSE; + } if (!php_sybase_do_connect_internal(sybase_ptr, host, user, passwd, charset, appname TSRMLS_CC)) { free(sybase_ptr); efree(hashed_details); From 7cf389ad2c7a7300ab7b582341f56bf496c1a8fe Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 11:01:04 +0000 Subject: [PATCH 0420/2394] - Fix #55301 (mssql part) check if malloc succeded --- ext/mssql/php_mssql.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c index 5a8625641360b..1cc5564a3e2f1 100644 --- a/ext/mssql/php_mssql.c +++ b/ext/mssql/php_mssql.c @@ -685,6 +685,13 @@ static void php_mssql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) /* hash it up */ mssql_ptr = (mssql_link *) malloc(sizeof(mssql_link)); + if (!mssql_ptr) { + efree(hashed_details); + dbfreelogin(mssql.login); + dbclose(mssql.link); + RETURN_FALSE; + } + memcpy(mssql_ptr, &mssql, sizeof(mssql_link)); Z_TYPE(new_le) = le_plink; new_le.ptr = mssql_ptr; From b32445d4f3ad5954db43761312be7a8f3fc58ca3 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 28 Jul 2011 12:01:42 +0000 Subject: [PATCH 0421/2394] Reverted Gopal's patch that allowed plugable interned string check 1. It introduced a significant slowdown 2. It didn't fix the real problem in APC (I'm goint to commit the fix) --- Zend/zend_string.c | 8 -------- Zend/zend_string.h | 3 +-- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/Zend/zend_string.c b/Zend/zend_string.c index 77b165ab20247..949c191582470 100644 --- a/Zend/zend_string.c +++ b/Zend/zend_string.c @@ -30,12 +30,10 @@ #endif ZEND_API const char *(*zend_new_interned_string)(const char *str, int len, int free_src TSRMLS_DC); -ZEND_API zend_bool (*zend_is_interned_string)(const char *str TSRMLS_DC); ZEND_API void (*zend_interned_strings_snapshot)(TSRMLS_D); ZEND_API void (*zend_interned_strings_restore)(TSRMLS_D); static const char *zend_new_interned_string_int(const char *str, int len, int free_src TSRMLS_DC); -static zend_bool zend_is_interned_string_int(const char *str TSRMLS_DC); static void zend_interned_strings_snapshot_int(TSRMLS_D); static void zend_interned_strings_restore_int(TSRMLS_D); @@ -66,7 +64,6 @@ void zend_interned_strings_init(TSRMLS_D) #endif zend_new_interned_string = zend_new_interned_string_int; - zend_is_interned_string = zend_is_interned_string_int; zend_interned_strings_snapshot = zend_interned_strings_snapshot_int; zend_interned_strings_restore = zend_interned_strings_restore_int; } @@ -180,11 +177,6 @@ static const char *zend_new_interned_string_int(const char *arKey, int nKeyLengt #endif } -static zend_bool zend_is_interned_string_int(const char *s TSRMLS_DC) -{ - return (((s) >= CG(interned_strings_start)) && ((s) < CG(interned_strings_end))); -} - static void zend_interned_strings_snapshot_int(TSRMLS_D) { CG(interned_strings_snapshot_top) = CG(interned_strings_top); diff --git a/Zend/zend_string.h b/Zend/zend_string.h index 5dcc950fafa0d..a130fbcc38386 100644 --- a/Zend/zend_string.h +++ b/Zend/zend_string.h @@ -24,7 +24,6 @@ #include "zend.h" ZEND_API extern const char *(*zend_new_interned_string)(const char *str, int len, int free_src TSRMLS_DC); -ZEND_API extern zend_bool (*zend_is_interned_string)(const char *str TSRMLS_DC); ZEND_API extern void (*zend_interned_strings_snapshot)(TSRMLS_D); ZEND_API extern void (*zend_interned_strings_restore)(TSRMLS_D); @@ -34,7 +33,7 @@ void zend_interned_strings_dtor(TSRMLS_D); #ifndef ZTS #define IS_INTERNED(s) \ - (zend_is_interned_string ? zend_is_interned_string((s) TSRMLS_CC) : 0) + (((s) >= CG(interned_strings_start)) && ((s) < CG(interned_strings_end))) #else From d7819b62cc849d2f5a59935fff30fb1ef439ac75 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 28 Jul 2011 21:16:51 +0000 Subject: [PATCH 0422/2394] - Fix #55301 (sybase part, take #2) check if malloc succeded --- ext/sybase_ct/php_sybase_ct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index 5429a3c88d9dd..e3dc415f839d5 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -777,7 +777,7 @@ static void php_sybase_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) } sybase_ptr = (sybase_link *) malloc(sizeof(sybase_link)); - if (sybase_ptr) { + if (!sybase_ptr) { efree(hashed_details); RETURN_FALSE; } From b07c3c3e014ab0f492e4424eaa17db810c94970d Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 31 Jul 2011 12:27:47 +0000 Subject: [PATCH 0423/2394] - Fixed bug #55326 (Trait method copying misindentifies serialization callbacks) patch by: Gustavo Lopes (cataphract@php) --- Zend/zend_compile.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index b005e4a4ed8ef..c6c096c810e44 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3476,8 +3476,6 @@ static int zend_traits_merge_functions(zend_function *fn TSRMLS_DC, int num_args else if (!IS_EQUAL(mname, mname_len, "__isset")) (ce)->__isset = (fe); \ else if (!IS_EQUAL(mname, mname_len, "__callstatic"))(ce)->__callstatic = (fe); \ else if (!IS_EQUAL(mname, mname_len, "__tostring")) (ce)->__tostring = (fe); \ - else if (!IS_EQUAL(mname, mname_len, "serialize_func")) (ce)->serialize_func = (fe); \ - else if (!IS_EQUAL(mname, mname_len, "unserialize_func"))(ce)->unserialize_func = (fe); \ } /* {{{ Originates from php_runkit_function_copy_ctor From 70aad763e9f06f4045d0a06b21b55ffccdda1084 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sun, 31 Jul 2011 16:15:40 +0000 Subject: [PATCH 0424/2394] Fixed test which was assuming that E_STRICT is not on by default. --- Zend/tests/traits/property001.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/tests/traits/property001.phpt b/Zend/tests/traits/property001.phpt index 7efd02ecc7043..d5e4ddc617e4a 100644 --- a/Zend/tests/traits/property001.phpt +++ b/Zend/tests/traits/property001.phpt @@ -13,6 +13,7 @@ trait THello2 { } echo "PRE-CLASS-GUARD-TraitsTest\n"; +error_reporting(E_ALL & ~E_STRICT); // ensuring that it is only for E_STRICT class TraitsTest { use THello1; From 03f514d0a07dd66d7068df19f40cdf313560e3a9 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sun, 31 Jul 2011 16:35:09 +0000 Subject: [PATCH 0425/2394] Added: SKIP when tokenizer extension is not available --- ext/tokenizer/tests/token_get_all_basic.phpt | 2 ++ ext/tokenizer/tests/token_get_all_error.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation1.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation10.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation11.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation12.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation13.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation14.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation15.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation16.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation17.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation18.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation19.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation2.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation3.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation4.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation5.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation6.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation7.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation8.phpt | 2 ++ ext/tokenizer/tests/token_get_all_variation9.phpt | 2 ++ 21 files changed, 42 insertions(+) diff --git a/ext/tokenizer/tests/token_get_all_basic.phpt b/ext/tokenizer/tests/token_get_all_basic.phpt index 5eb6311b57fee..7af8109f89622 100644 --- a/ext/tokenizer/tests/token_get_all_basic.phpt +++ b/ext/tokenizer/tests/token_get_all_basic.phpt @@ -1,5 +1,7 @@ --TEST-- Test token_get_all() function : basic functionality +--SKIPIF-- + --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --INI-- short_open_tag=On --FILE-- diff --git a/ext/tokenizer/tests/token_get_all_variation16.phpt b/ext/tokenizer/tests/token_get_all_variation16.phpt index 4ae694e7419a1..39550bdb3d8f5 100644 --- a/ext/tokenizer/tests/token_get_all_variation16.phpt +++ b/ext/tokenizer/tests/token_get_all_variation16.phpt @@ -1,5 +1,7 @@ --TEST-- Test token_get_all() function : usage variations - with function constructs +--SKIPIF-- + --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- Date: Sun, 31 Jul 2011 17:39:30 +0000 Subject: [PATCH 0426/2394] Added __TRAIT__ magic constant [TRAITS] [DOC] # __TRAIT__ behaves like __CLASS__ more or less but is constraint to traits. # Since traits are not types, there are not many valid use cases, and trying # to use __TRAIT__ to make traits more like classes is discouraged. --- Zend/tests/traits/trait_constant_001.phpt | 36 + Zend/tests/traits/trait_constant_002.phpt | 27 + Zend/zend_language_parser.y | 2 + Zend/zend_language_scanner.c | 3374 +++++++++-------- Zend/zend_language_scanner.l | 20 + Zend/zend_language_scanner_defs.h | 2 +- .../tests/token_get_all_variation12.phpt | 111 +- 7 files changed, 1878 insertions(+), 1694 deletions(-) create mode 100644 Zend/tests/traits/trait_constant_001.phpt create mode 100644 Zend/tests/traits/trait_constant_002.phpt diff --git a/Zend/tests/traits/trait_constant_001.phpt b/Zend/tests/traits/trait_constant_001.phpt new file mode 100644 index 0000000000000..0fd8ff921b202 --- /dev/null +++ b/Zend/tests/traits/trait_constant_001.phpt @@ -0,0 +1,36 @@ +--TEST-- +__TRAIT__: Basics, a constant denoiting the trait of definition. +--FILE-- + +--EXPECT-- +TestTrait +TestTrait +TestTrait diff --git a/Zend/tests/traits/trait_constant_002.phpt b/Zend/tests/traits/trait_constant_002.phpt new file mode 100644 index 0000000000000..327dd44a64d6b --- /dev/null +++ b/Zend/tests/traits/trait_constant_002.phpt @@ -0,0 +1,27 @@ +--TEST-- +__TRAIT__: Use outside of traits. +--FILE-- + +--EXPECT-- +string(0) "" +string(0) "" +string(0) "" \ No newline at end of file diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 140d742d045ff..f89c1f121cb5f 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -187,6 +187,7 @@ static YYSIZE_T zend_yytnamerr(char*, const char*); %token T_LIST "list (T_LIST)" %token T_ARRAY "array (T_ARRAY)" %token T_CLASS_C "__CLASS__ (T_CLASS_C)" +%token T_TRAIT_C "__TRAIT__ (T_TRAIT_C)" %token T_METHOD_C "__METHOD__ (T_METHOD_C)" %token T_FUNC_C "__FUNCTION__ (T_FUNC_C)" %token T_LINE "__LINE__ (T_LINE)" @@ -879,6 +880,7 @@ common_scalar: | T_FILE { $$ = $1; } | T_DIR { $$ = $1; } | T_CLASS_C { $$ = $1; } + | T_TRAIT_C { $$ = $1; } | T_METHOD_C { $$ = $1; } | T_FUNC_C { $$ = $1; } | T_NS_C { $$ = $1; } diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index c3dc70a55f273..e71e2bf05c24d 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Wed Jul 27 02:06:14 2011 */ +/* Generated by re2c 0.13.5 on Sun Jul 31 17:59:24 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1083,7 +1083,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1733 "Zend/zend_language_scanner.l" +#line 1753 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1161,7 +1161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1721 "Zend/zend_language_scanner.l" +#line 1741 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1180,7 +1180,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1698 "Zend/zend_language_scanner.l" +#line 1718 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1378,7 +1378,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1658 "Zend/zend_language_scanner.l" +#line 1678 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1422,7 +1422,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1676 "Zend/zend_language_scanner.l" +#line 1696 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1440,7 +1440,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1689 "Zend/zend_language_scanner.l" +#line 1709 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1475,7 +1475,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1711 "Zend/zend_language_scanner.l" +#line 1731 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1555,7 +1555,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2184 "Zend/zend_language_scanner.l" +#line 2204 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1607,7 +1607,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2128 "Zend/zend_language_scanner.l" +#line 2148 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; @@ -1622,7 +1622,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2115 "Zend/zend_language_scanner.l" +#line 2135 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1645,7 +1645,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1835 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1676,7 +1676,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1807 "Zend/zend_language_scanner.l" +#line 1827 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1702,7 +1702,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1797 "Zend/zend_language_scanner.l" +#line 1817 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1778,7 +1778,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2134 "Zend/zend_language_scanner.l" +#line 2154 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1838,7 +1838,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2123 "Zend/zend_language_scanner.l" +#line 2143 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; @@ -1853,7 +1853,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2115 "Zend/zend_language_scanner.l" +#line 2135 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1876,7 +1876,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1835 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1907,7 +1907,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1807 "Zend/zend_language_scanner.l" +#line 1827 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1933,7 +1933,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1797 "Zend/zend_language_scanner.l" +#line 1817 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1952,7 +1952,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2102 "Zend/zend_language_scanner.l" +#line 2122 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -2026,7 +2026,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2226 "Zend/zend_language_scanner.l" +#line 2246 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2112,7 +2112,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2115 "Zend/zend_language_scanner.l" +#line 2135 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -2135,7 +2135,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1835 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -2166,7 +2166,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1807 "Zend/zend_language_scanner.l" +#line 1827 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2192,7 +2192,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1797 "Zend/zend_language_scanner.l" +#line 1817 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2365,23 +2365,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(-1, yych); switch ((yych = *YYCURSOR)) { case 'C': - case 'c': goto yy711; + case 'c': goto yy719; case 'L': - case 'l': goto yy712; + case 'l': goto yy720; case 'M': - case 'm': goto yy713; + case 'm': goto yy721; case 'N': - case 'n': goto yy714; + case 'n': goto yy722; case 'V': - case 'v': goto yy715; + case 'v': goto yy723; case 'X': - case 'x': goto yy716; + case 'x': goto yy724; default: goto yy186; } yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1838 "Zend/zend_language_scanner.l" +#line 1858 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -2393,20 +2393,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'H') { - if (yych == 'E') goto yy693; + if (yych == 'E') goto yy701; goto yy186; } else { - if (yych <= 'I') goto yy694; + if (yych <= 'I') goto yy702; if (yych <= 'N') goto yy186; - goto yy695; + goto yy703; } } else { if (yych <= 'h') { - if (yych == 'e') goto yy693; + if (yych == 'e') goto yy701; goto yy186; } else { - if (yych <= 'i') goto yy694; - if (yych == 'o') goto yy695; + if (yych <= 'i') goto yy702; + if (yych == 'o') goto yy703; goto yy186; } } @@ -2415,20 +2415,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'U') { if (yych <= 'N') { - if (yych == 'I') goto yy672; + if (yych == 'I') goto yy680; goto yy186; } else { - if (yych <= 'O') goto yy673; + if (yych <= 'O') goto yy681; if (yych <= 'T') goto yy186; - goto yy674; + goto yy682; } } else { if (yych <= 'n') { - if (yych == 'i') goto yy672; + if (yych == 'i') goto yy680; goto yy186; } else { - if (yych <= 'o') goto yy673; - if (yych == 'u') goto yy674; + if (yych <= 'o') goto yy681; + if (yych == 'u') goto yy682; goto yy186; } } @@ -2437,42 +2437,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'K') { - if (yych == 'A') goto yy644; + if (yych == 'A') goto yy652; goto yy186; } else { - if (yych <= 'L') goto yy645; + if (yych <= 'L') goto yy653; if (yych <= 'N') goto yy186; - goto yy646; + goto yy654; } } else { if (yych <= 'k') { - if (yych == 'a') goto yy644; + if (yych == 'a') goto yy652; goto yy186; } else { - if (yych <= 'l') goto yy645; - if (yych == 'o') goto yy646; + if (yych <= 'l') goto yy653; + if (yych == 'o') goto yy654; goto yy186; } } yy128: YYDEBUG(128, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy626; - if (yych == 'e') goto yy626; + if (yych == 'E') goto yy634; + if (yych == 'e') goto yy634; goto yy186; yy129: YYDEBUG(129, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'R') { - if (yych == 'H') goto yy614; + if (yych == 'H') goto yy622; if (yych <= 'Q') goto yy186; - goto yy615; + goto yy623; } else { if (yych <= 'h') { if (yych <= 'g') goto yy186; - goto yy614; + goto yy622; } else { - if (yych == 'r') goto yy615; + if (yych == 'r') goto yy623; goto yy186; } } @@ -2481,53 +2481,53 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'S') { if (yych <= 'L') { - if (yych == 'F') goto yy561; + if (yych == 'F') goto yy569; goto yy186; } else { - if (yych <= 'M') goto yy563; - if (yych <= 'N') goto yy564; + if (yych <= 'M') goto yy571; + if (yych <= 'N') goto yy572; if (yych <= 'R') goto yy186; - goto yy565; + goto yy573; } } else { if (yych <= 'm') { - if (yych == 'f') goto yy561; + if (yych == 'f') goto yy569; if (yych <= 'l') goto yy186; - goto yy563; + goto yy571; } else { - if (yych <= 'n') goto yy564; - if (yych == 's') goto yy565; + if (yych <= 'n') goto yy572; + if (yych == 's') goto yy573; goto yy186; } } yy131: YYDEBUG(131, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy556; - if (yych == 'h') goto yy556; + if (yych == 'H') goto yy564; + if (yych == 'h') goto yy564; goto yy186; yy132: YYDEBUG(132, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'S') { if (yych <= 'M') { - if (yych == 'B') goto yy538; + if (yych == 'B') goto yy546; goto yy186; } else { - if (yych <= 'N') goto yy539; + if (yych <= 'N') goto yy547; if (yych <= 'Q') goto yy186; - if (yych <= 'R') goto yy540; - goto yy541; + if (yych <= 'R') goto yy548; + goto yy549; } } else { if (yych <= 'n') { - if (yych == 'b') goto yy538; + if (yych == 'b') goto yy546; if (yych <= 'm') goto yy186; - goto yy539; + goto yy547; } else { if (yych <= 'q') goto yy186; - if (yych <= 'r') goto yy540; - if (yych <= 's') goto yy541; + if (yych <= 'r') goto yy548; + if (yych <= 's') goto yy549; goto yy186; } } @@ -2535,15 +2535,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(133, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'W') { - if (yych == 'T') goto yy526; + if (yych == 'T') goto yy534; if (yych <= 'V') goto yy186; - goto yy527; + goto yy535; } else { if (yych <= 't') { if (yych <= 's') goto yy186; - goto yy526; + goto yy534; } else { - if (yych == 'w') goto yy527; + if (yych == 'w') goto yy535; goto yy186; } } @@ -2554,18 +2554,18 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (yych <= ';') { if (yych <= '"') { if (yych <= '!') goto yy186; - goto yy518; + goto yy526; } else { - if (yych == '\'') goto yy519; + if (yych == '\'') goto yy527; goto yy186; } } else { if (yych <= 'R') { - if (yych <= '<') goto yy517; + if (yych <= '<') goto yy525; if (yych <= 'Q') goto yy186; - goto yy520; + goto yy528; } else { - if (yych == 'r') goto yy520; + if (yych == 'r') goto yy528; goto yy186; } } @@ -2573,15 +2573,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(135, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'L') goto yy507; + if (yych == 'L') goto yy515; if (yych <= 'N') goto yy186; - goto yy508; + goto yy516; } else { if (yych <= 'l') { if (yych <= 'k') goto yy186; - goto yy507; + goto yy515; } else { - if (yych == 'o') goto yy508; + if (yych == 'o') goto yy516; goto yy186; } } @@ -2589,15 +2589,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(136, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'U') { - if (yych == 'R') goto yy483; + if (yych == 'R') goto yy491; if (yych <= 'T') goto yy186; - goto yy484; + goto yy492; } else { if (yych <= 'r') { if (yych <= 'q') goto yy186; - goto yy483; + goto yy491; } else { - if (yych == 'u') goto yy484; + if (yych == 'u') goto yy492; goto yy186; } } @@ -2605,10 +2605,10 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(137, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '<') { - if (yych == '-') goto yy479; + if (yych == '-') goto yy487; } else { - if (yych <= '=') goto yy477; - if (yych <= '>') goto yy481; + if (yych <= '=') goto yy485; + if (yych <= '>') goto yy489; } yy138: YYDEBUG(138, *YYCURSOR); @@ -2622,7 +2622,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(139, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy476; + goto yy484; yy140: YYDEBUG(140, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); @@ -2638,7 +2638,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy141: YYDEBUG(141, *YYCURSOR); yych = *++YYCURSOR; - if (yych == ':') goto yy473; + if (yych == ':') goto yy481; goto yy138; yy142: YYDEBUG(142, *YYCURSOR); @@ -2654,23 +2654,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(144, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'E') { - if (yych == 'A') goto yy461; + if (yych == 'A') goto yy469; if (yych <= 'D') goto yy186; - goto yy462; + goto yy470; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy461; + goto yy469; } else { - if (yych == 'e') goto yy462; + if (yych == 'e') goto yy470; goto yy186; } } yy145: YYDEBUG(145, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy458; - if (yych == 'a') goto yy458; + if (yych == 'A') goto yy466; + if (yych == 'a') goto yy466; goto yy186; yy146: YYDEBUG(146, *YYCURSOR); @@ -2679,47 +2679,47 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (yych <= 'S') { if (yych <= 'D') { if (yych <= ' ') { - if (yych == '\t') goto yy383; + if (yych == '\t') goto yy391; if (yych <= 0x1F) goto yy138; - goto yy383; + goto yy391; } else { if (yych <= '@') goto yy138; if (yych == 'C') goto yy138; - goto yy383; + goto yy391; } } else { if (yych <= 'I') { - if (yych == 'F') goto yy383; + if (yych == 'F') goto yy391; if (yych <= 'H') goto yy138; - goto yy383; + goto yy391; } else { - if (yych == 'O') goto yy383; + if (yych == 'O') goto yy391; if (yych <= 'Q') goto yy138; - goto yy383; + goto yy391; } } } else { if (yych <= 'f') { if (yych <= 'b') { - if (yych == 'U') goto yy383; + if (yych == 'U') goto yy391; if (yych <= '`') goto yy138; - goto yy383; + goto yy391; } else { - if (yych == 'd') goto yy383; + if (yych == 'd') goto yy391; if (yych <= 'e') goto yy138; - goto yy383; + goto yy391; } } else { if (yych <= 'o') { - if (yych == 'i') goto yy383; + if (yych == 'i') goto yy391; if (yych <= 'n') goto yy138; - goto yy383; + goto yy391; } else { if (yych <= 's') { if (yych <= 'q') goto yy138; - goto yy383; + goto yy391; } else { - if (yych == 'u') goto yy383; + if (yych == 'u') goto yy391; goto yy138; } } @@ -2729,15 +2729,15 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(147, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'S') { - if (yych == 'N') goto yy374; + if (yych == 'N') goto yy382; if (yych <= 'R') goto yy186; - goto yy375; + goto yy383; } else { if (yych <= 'n') { if (yych <= 'm') goto yy186; - goto yy374; + goto yy382; } else { - if (yych == 's') goto yy375; + if (yych == 's') goto yy383; goto yy186; } } @@ -2973,7 +2973,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1845 "Zend/zend_language_scanner.l" +#line 1865 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3014,7 +3014,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1936 "Zend/zend_language_scanner.l" +#line 1956 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3089,7 +3089,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2005 "Zend/zend_language_scanner.l" +#line 2025 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3136,7 +3136,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2096 "Zend/zend_language_scanner.l" +#line 2116 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; @@ -3147,7 +3147,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2354 "Zend/zend_language_scanner.l" +#line 2374 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3344,7 +3344,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy206: YYDEBUG(206, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1913 "Zend/zend_language_scanner.l" +#line 1933 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3386,7 +3386,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy211: YYDEBUG(211, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1835 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -3482,7 +3482,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy228: YYDEBUG(228, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1922 "Zend/zend_language_scanner.l" +#line 1942 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3549,7 +3549,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy238: YYDEBUG(238, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1879 "Zend/zend_language_scanner.l" +#line 1899 "Zend/zend_language_scanner.l" { int doc_com; @@ -3857,7 +3857,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy279: YYDEBUG(279, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2047 "Zend/zend_language_scanner.l" +#line 2067 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -4032,120 +4032,128 @@ int lex_scan(zval *zendlval TSRMLS_DC) case 'C': case 'c': goto yy302; case 'D': - case 'd': goto yy306; + case 'd': goto yy307; case 'F': - case 'f': goto yy303; + case 'f': goto yy304; case 'H': case 'h': goto yy301; case 'L': - case 'l': goto yy305; + case 'l': goto yy306; case 'M': - case 'm': goto yy304; + case 'm': goto yy305; case 'N': - case 'n': goto yy307; + case 'n': goto yy308; + case 'T': + case 't': goto yy303; default: goto yy186; } yy301: YYDEBUG(301, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy361; - if (yych == 'a') goto yy361; + if (yych == 'A') goto yy369; + if (yych == 'a') goto yy369; goto yy186; yy302: YYDEBUG(302, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy354; - if (yych == 'l') goto yy354; + if (yych == 'L') goto yy362; + if (yych == 'l') goto yy362; goto yy186; yy303: YYDEBUG(303, *YYCURSOR); yych = *++YYCURSOR; + if (yych == 'R') goto yy355; + if (yych == 'r') goto yy355; + goto yy186; +yy304: + YYDEBUG(304, *YYCURSOR); + yych = *++YYCURSOR; if (yych <= 'U') { - if (yych == 'I') goto yy338; + if (yych == 'I') goto yy339; if (yych <= 'T') goto yy186; - goto yy339; + goto yy340; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; - goto yy338; + goto yy339; } else { - if (yych == 'u') goto yy339; + if (yych == 'u') goto yy340; goto yy186; } } -yy304: - YYDEBUG(304, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'E') goto yy330; - if (yych == 'e') goto yy330; - goto yy186; yy305: YYDEBUG(305, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy324; - if (yych == 'i') goto yy324; + if (yych == 'E') goto yy331; + if (yych == 'e') goto yy331; goto yy186; yy306: YYDEBUG(306, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy319; - if (yych == 'i') goto yy319; + if (yych == 'I') goto yy325; + if (yych == 'i') goto yy325; goto yy186; yy307: YYDEBUG(307, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy308; - if (yych != 'a') goto yy186; + if (yych == 'I') goto yy320; + if (yych == 'i') goto yy320; + goto yy186; yy308: YYDEBUG(308, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy309; - if (yych != 'm') goto yy186; + if (yych == 'A') goto yy309; + if (yych != 'a') goto yy186; yy309: YYDEBUG(309, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy310; - if (yych != 'e') goto yy186; + if (yych == 'M') goto yy310; + if (yych != 'm') goto yy186; yy310: YYDEBUG(310, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy311; - if (yych != 's') goto yy186; + if (yych == 'E') goto yy311; + if (yych != 'e') goto yy186; yy311: YYDEBUG(311, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy312; - if (yych != 'p') goto yy186; + if (yych == 'S') goto yy312; + if (yych != 's') goto yy186; yy312: YYDEBUG(312, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy313; - if (yych != 'a') goto yy186; + if (yych == 'P') goto yy313; + if (yych != 'p') goto yy186; yy313: YYDEBUG(313, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy314; - if (yych != 'c') goto yy186; + if (yych == 'A') goto yy314; + if (yych != 'a') goto yy186; yy314: YYDEBUG(314, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy315; - if (yych != 'e') goto yy186; + if (yych == 'C') goto yy315; + if (yych != 'c') goto yy186; yy315: YYDEBUG(315, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'E') goto yy316; + if (yych != 'e') goto yy186; +yy316: YYDEBUG(316, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(317, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(318, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(318, *YYCURSOR); + YYDEBUG(319, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1648 "Zend/zend_language_scanner.l" +#line 1668 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4155,27 +4163,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NS_C; } -#line 4159 "Zend/zend_language_scanner.c" -yy319: - YYDEBUG(319, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'R') goto yy320; - if (yych != 'r') goto yy186; +#line 4167 "Zend/zend_language_scanner.c" yy320: YYDEBUG(320, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'R') goto yy321; + if (yych != 'r') goto yy186; +yy321: YYDEBUG(321, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(322, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(323, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(323, *YYCURSOR); + YYDEBUG(324, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1621 "Zend/zend_language_scanner.l" +#line 1641 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4202,73 +4210,73 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_DIR; } -#line 4206 "Zend/zend_language_scanner.c" -yy324: - YYDEBUG(324, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'N') goto yy325; - if (yych != 'n') goto yy186; +#line 4214 "Zend/zend_language_scanner.c" yy325: YYDEBUG(325, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy326; - if (yych != 'e') goto yy186; + if (yych == 'N') goto yy326; + if (yych != 'n') goto yy186; yy326: YYDEBUG(326, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'E') goto yy327; + if (yych != 'e') goto yy186; +yy327: YYDEBUG(327, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(328, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(329, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(329, *YYCURSOR); + YYDEBUG(330, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1603 "Zend/zend_language_scanner.l" +#line 1623 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; return T_LINE; } -#line 4237 "Zend/zend_language_scanner.c" -yy330: - YYDEBUG(330, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'T') goto yy331; - if (yych != 't') goto yy186; +#line 4245 "Zend/zend_language_scanner.c" yy331: YYDEBUG(331, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy332; - if (yych != 'h') goto yy186; + if (yych == 'T') goto yy332; + if (yych != 't') goto yy186; yy332: YYDEBUG(332, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy333; - if (yych != 'o') goto yy186; + if (yych == 'H') goto yy333; + if (yych != 'h') goto yy186; yy333: YYDEBUG(333, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy334; - if (yych != 'd') goto yy186; + if (yych == 'O') goto yy334; + if (yych != 'o') goto yy186; yy334: YYDEBUG(334, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'D') goto yy335; + if (yych != 'd') goto yy186; +yy335: YYDEBUG(335, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(336, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(337, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(337, *YYCURSOR); + YYDEBUG(338, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1582 "Zend/zend_language_scanner.l" +#line 1602 "Zend/zend_language_scanner.l" { char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4289,58 +4297,58 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_METHOD_C; } -#line 4293 "Zend/zend_language_scanner.c" -yy338: - YYDEBUG(338, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'L') goto yy349; - if (yych == 'l') goto yy349; - goto yy186; +#line 4301 "Zend/zend_language_scanner.c" yy339: YYDEBUG(339, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy340; - if (yych != 'n') goto yy186; + if (yych == 'L') goto yy350; + if (yych == 'l') goto yy350; + goto yy186; yy340: YYDEBUG(340, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy341; - if (yych != 'c') goto yy186; + if (yych == 'N') goto yy341; + if (yych != 'n') goto yy186; yy341: YYDEBUG(341, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy342; - if (yych != 't') goto yy186; + if (yych == 'C') goto yy342; + if (yych != 'c') goto yy186; yy342: YYDEBUG(342, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy343; - if (yych != 'i') goto yy186; + if (yych == 'T') goto yy343; + if (yych != 't') goto yy186; yy343: YYDEBUG(343, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy344; - if (yych != 'o') goto yy186; + if (yych == 'I') goto yy344; + if (yych != 'i') goto yy186; yy344: YYDEBUG(344, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy345; - if (yych != 'n') goto yy186; + if (yych == 'O') goto yy345; + if (yych != 'o') goto yy186; yy345: YYDEBUG(345, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'N') goto yy346; + if (yych != 'n') goto yy186; +yy346: YYDEBUG(346, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(347, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(348, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(348, *YYCURSOR); + YYDEBUG(349, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1566 "Zend/zend_language_scanner.l" +#line 1586 "Zend/zend_language_scanner.l" { char *func_name = NULL; @@ -4356,27 +4364,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FUNC_C; } -#line 4360 "Zend/zend_language_scanner.c" -yy349: - YYDEBUG(349, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'E') goto yy350; - if (yych != 'e') goto yy186; +#line 4368 "Zend/zend_language_scanner.c" yy350: YYDEBUG(350, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'E') goto yy351; + if (yych != 'e') goto yy186; +yy351: YYDEBUG(351, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(352, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(353, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(353, *YYCURSOR); + YYDEBUG(354, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1609 "Zend/zend_language_scanner.l" +#line 1629 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4388,35 +4396,85 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_FILE; } -#line 4392 "Zend/zend_language_scanner.c" -yy354: - YYDEBUG(354, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'A') goto yy355; - if (yych != 'a') goto yy186; +#line 4400 "Zend/zend_language_scanner.c" yy355: YYDEBUG(355, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy356; - if (yych != 's') goto yy186; + if (yych == 'A') goto yy356; + if (yych != 'a') goto yy186; yy356: YYDEBUG(356, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy357; - if (yych != 's') goto yy186; + if (yych == 'I') goto yy357; + if (yych != 'i') goto yy186; yy357: YYDEBUG(357, *YYCURSOR); yych = *++YYCURSOR; - if (yych != '_') goto yy186; + if (yych == 'T') goto yy358; + if (yych != 't') goto yy186; +yy358: YYDEBUG(358, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; YYDEBUG(359, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(360, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(360, *YYCURSOR); + YYDEBUG(361, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1566 "Zend/zend_language_scanner.l" + { + char *trait_name = NULL; + + if (CG(active_class_entry) + && (ZEND_ACC_TRAIT == + (CG(active_class_entry)->ce_flags & ZEND_ACC_TRAIT))) { + trait_name = CG(active_class_entry)->name; + } + + if (!trait_name) { + trait_name = ""; + } + + zendlval->value.str.len = strlen(trait_name); + zendlval->value.str.val = estrndup(trait_name, zendlval->value.str.len); + zendlval->type = IS_STRING; + + return T_TRAIT_C; +} +#line 4450 "Zend/zend_language_scanner.c" +yy362: + YYDEBUG(362, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy363; + if (yych != 'a') goto yy186; +yy363: + YYDEBUG(363, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy364; + if (yych != 's') goto yy186; +yy364: + YYDEBUG(364, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy365; + if (yych != 's') goto yy186; +yy365: + YYDEBUG(365, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(366, *YYCURSOR); + yych = *++YYCURSOR; + if (yych != '_') goto yy186; + YYDEBUG(367, *YYCURSOR); + ++YYCURSOR; + if (yybm[0+(yych = *YYCURSOR)] & 4) { + goto yy185; + } + YYDEBUG(368, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1550 "Zend/zend_language_scanner.l" { @@ -4434,418 +4492,376 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_CLASS_C; } -#line 4438 "Zend/zend_language_scanner.c" -yy361: - YYDEBUG(361, *YYCURSOR); +#line 4496 "Zend/zend_language_scanner.c" +yy369: + YYDEBUG(369, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy362; + if (yych == 'L') goto yy370; if (yych != 'l') goto yy186; -yy362: - YYDEBUG(362, *YYCURSOR); +yy370: + YYDEBUG(370, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy363; + if (yych == 'T') goto yy371; if (yych != 't') goto yy186; -yy363: - YYDEBUG(363, *YYCURSOR); +yy371: + YYDEBUG(371, *YYCURSOR); yych = *++YYCURSOR; if (yych != '_') goto yy186; - YYDEBUG(364, *YYCURSOR); + YYDEBUG(372, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy365; + if (yych == 'C') goto yy373; if (yych != 'c') goto yy186; -yy365: - YYDEBUG(365, *YYCURSOR); +yy373: + YYDEBUG(373, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy366; + if (yych == 'O') goto yy374; if (yych != 'o') goto yy186; -yy366: - YYDEBUG(366, *YYCURSOR); +yy374: + YYDEBUG(374, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy367; + if (yych == 'M') goto yy375; if (yych != 'm') goto yy186; -yy367: - YYDEBUG(367, *YYCURSOR); +yy375: + YYDEBUG(375, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy368; + if (yych == 'P') goto yy376; if (yych != 'p') goto yy186; -yy368: - YYDEBUG(368, *YYCURSOR); +yy376: + YYDEBUG(376, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy369; + if (yych == 'I') goto yy377; if (yych != 'i') goto yy186; -yy369: - YYDEBUG(369, *YYCURSOR); +yy377: + YYDEBUG(377, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy370; + if (yych == 'L') goto yy378; if (yych != 'l') goto yy186; -yy370: - YYDEBUG(370, *YYCURSOR); +yy378: + YYDEBUG(378, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy371; + if (yych == 'E') goto yy379; if (yych != 'e') goto yy186; -yy371: - YYDEBUG(371, *YYCURSOR); +yy379: + YYDEBUG(379, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy372; + if (yych == 'R') goto yy380; if (yych != 'r') goto yy186; -yy372: - YYDEBUG(372, *YYCURSOR); +yy380: + YYDEBUG(380, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(373, *YYCURSOR); + YYDEBUG(381, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1272 "Zend/zend_language_scanner.l" { return T_HALT_COMPILER; } -#line 4504 "Zend/zend_language_scanner.c" -yy374: - YYDEBUG(374, *YYCURSOR); +#line 4562 "Zend/zend_language_scanner.c" +yy382: + YYDEBUG(382, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy378; - if (yych == 's') goto yy378; + if (yych == 'S') goto yy386; + if (yych == 's') goto yy386; goto yy186; -yy375: - YYDEBUG(375, *YYCURSOR); +yy383: + YYDEBUG(383, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy376; + if (yych == 'E') goto yy384; if (yych != 'e') goto yy186; -yy376: - YYDEBUG(376, *YYCURSOR); +yy384: + YYDEBUG(384, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(377, *YYCURSOR); + YYDEBUG(385, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1252 "Zend/zend_language_scanner.l" { return T_USE; } -#line 4528 "Zend/zend_language_scanner.c" -yy378: - YYDEBUG(378, *YYCURSOR); +#line 4586 "Zend/zend_language_scanner.c" +yy386: + YYDEBUG(386, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy379; + if (yych == 'E') goto yy387; if (yych != 'e') goto yy186; -yy379: - YYDEBUG(379, *YYCURSOR); +yy387: + YYDEBUG(387, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy380; + if (yych == 'T') goto yy388; if (yych != 't') goto yy186; -yy380: - YYDEBUG(380, *YYCURSOR); +yy388: + YYDEBUG(388, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(381, *YYCURSOR); + YYDEBUG(389, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1300 "Zend/zend_language_scanner.l" { return T_UNSET; } -#line 4551 "Zend/zend_language_scanner.c" -yy382: - YYDEBUG(382, *YYCURSOR); +#line 4609 "Zend/zend_language_scanner.c" +yy390: + YYDEBUG(390, *YYCURSOR); ++YYCURSOR; YYFILL(7); yych = *YYCURSOR; -yy383: - YYDEBUG(383, *YYCURSOR); +yy391: + YYDEBUG(391, *YYCURSOR); if (yych <= 'S') { if (yych <= 'D') { if (yych <= ' ') { - if (yych == '\t') goto yy382; + if (yych == '\t') goto yy390; if (yych <= 0x1F) goto yy193; - goto yy382; + goto yy390; } else { if (yych <= 'A') { if (yych <= '@') goto yy193; - goto yy387; + goto yy395; } else { - if (yych <= 'B') goto yy385; + if (yych <= 'B') goto yy393; if (yych <= 'C') goto yy193; - goto yy390; + goto yy398; } } } else { if (yych <= 'I') { - if (yych == 'F') goto yy391; + if (yych == 'F') goto yy399; if (yych <= 'H') goto yy193; - goto yy392; + goto yy400; } else { if (yych <= 'O') { if (yych <= 'N') goto yy193; - goto yy386; + goto yy394; } else { if (yych <= 'Q') goto yy193; - if (yych <= 'R') goto yy389; - goto yy388; + if (yych <= 'R') goto yy397; + goto yy396; } } } } else { if (yych <= 'f') { if (yych <= 'a') { - if (yych == 'U') goto yy384; + if (yych == 'U') goto yy392; if (yych <= '`') goto yy193; - goto yy387; + goto yy395; } else { if (yych <= 'c') { - if (yych <= 'b') goto yy385; + if (yych <= 'b') goto yy393; goto yy193; } else { - if (yych <= 'd') goto yy390; + if (yych <= 'd') goto yy398; if (yych <= 'e') goto yy193; - goto yy391; + goto yy399; } } } else { if (yych <= 'q') { if (yych <= 'i') { if (yych <= 'h') goto yy193; - goto yy392; + goto yy400; } else { - if (yych == 'o') goto yy386; + if (yych == 'o') goto yy394; goto yy193; } } else { if (yych <= 's') { - if (yych <= 'r') goto yy389; - goto yy388; + if (yych <= 'r') goto yy397; + goto yy396; } else { if (yych != 'u') goto yy193; } } } } -yy384: - YYDEBUG(384, *YYCURSOR); +yy392: + YYDEBUG(392, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy451; - if (yych == 'n') goto yy451; + if (yych == 'N') goto yy459; + if (yych == 'n') goto yy459; goto yy193; -yy385: - YYDEBUG(385, *YYCURSOR); +yy393: + YYDEBUG(393, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'I') goto yy438; + if (yych == 'I') goto yy446; if (yych <= 'N') goto yy193; - goto yy439; + goto yy447; } else { if (yych <= 'i') { if (yych <= 'h') goto yy193; - goto yy438; + goto yy446; } else { - if (yych == 'o') goto yy439; + if (yych == 'o') goto yy447; goto yy193; } } -yy386: - YYDEBUG(386, *YYCURSOR); +yy394: + YYDEBUG(394, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy430; - if (yych == 'b') goto yy430; + if (yych == 'B') goto yy438; + if (yych == 'b') goto yy438; goto yy193; -yy387: - YYDEBUG(387, *YYCURSOR); +yy395: + YYDEBUG(395, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy423; - if (yych == 'r') goto yy423; + if (yych == 'R') goto yy431; + if (yych == 'r') goto yy431; goto yy193; -yy388: - YYDEBUG(388, *YYCURSOR); +yy396: + YYDEBUG(396, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy415; - if (yych == 't') goto yy415; + if (yych == 'T') goto yy423; + if (yych == 't') goto yy423; goto yy193; -yy389: - YYDEBUG(389, *YYCURSOR); +yy397: + YYDEBUG(397, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy413; - if (yych == 'e') goto yy413; + if (yych == 'E') goto yy421; + if (yych == 'e') goto yy421; goto yy193; -yy390: - YYDEBUG(390, *YYCURSOR); +yy398: + YYDEBUG(398, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy409; - if (yych == 'o') goto yy409; + if (yych == 'O') goto yy417; + if (yych == 'o') goto yy417; goto yy193; -yy391: - YYDEBUG(391, *YYCURSOR); +yy399: + YYDEBUG(399, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy402; - if (yych == 'l') goto yy402; + if (yych == 'L') goto yy410; + if (yych == 'l') goto yy410; goto yy193; -yy392: - YYDEBUG(392, *YYCURSOR); +yy400: + YYDEBUG(400, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy393; + if (yych == 'N') goto yy401; if (yych != 'n') goto yy193; -yy393: - YYDEBUG(393, *YYCURSOR); +yy401: + YYDEBUG(401, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy394; + if (yych == 'T') goto yy402; if (yych != 't') goto yy193; -yy394: - YYDEBUG(394, *YYCURSOR); +yy402: + YYDEBUG(402, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy395; - if (yych != 'e') goto yy397; -yy395: - YYDEBUG(395, *YYCURSOR); + if (yych == 'E') goto yy403; + if (yych != 'e') goto yy405; +yy403: + YYDEBUG(403, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'G') goto yy400; - if (yych == 'g') goto yy400; + if (yych == 'G') goto yy408; + if (yych == 'g') goto yy408; goto yy193; -yy396: - YYDEBUG(396, *YYCURSOR); +yy404: + YYDEBUG(404, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy397: - YYDEBUG(397, *YYCURSOR); +yy405: + YYDEBUG(405, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy396; + if (yych == '\t') goto yy404; goto yy193; } else { - if (yych <= ' ') goto yy396; + if (yych <= ' ') goto yy404; if (yych != ')') goto yy193; } - YYDEBUG(398, *YYCURSOR); + YYDEBUG(406, *YYCURSOR); ++YYCURSOR; - YYDEBUG(399, *YYCURSOR); + YYDEBUG(407, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1200 "Zend/zend_language_scanner.l" { return T_INT_CAST; } -#line 4727 "Zend/zend_language_scanner.c" -yy400: - YYDEBUG(400, *YYCURSOR); +#line 4785 "Zend/zend_language_scanner.c" +yy408: + YYDEBUG(408, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy401; + if (yych == 'E') goto yy409; if (yych != 'e') goto yy193; -yy401: - YYDEBUG(401, *YYCURSOR); +yy409: + YYDEBUG(409, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy396; - if (yych == 'r') goto yy396; + if (yych == 'R') goto yy404; + if (yych == 'r') goto yy404; goto yy193; -yy402: - YYDEBUG(402, *YYCURSOR); +yy410: + YYDEBUG(410, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy403; + if (yych == 'O') goto yy411; if (yych != 'o') goto yy193; -yy403: - YYDEBUG(403, *YYCURSOR); +yy411: + YYDEBUG(411, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy404; + if (yych == 'A') goto yy412; if (yych != 'a') goto yy193; -yy404: - YYDEBUG(404, *YYCURSOR); +yy412: + YYDEBUG(412, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy405; + if (yych == 'T') goto yy413; if (yych != 't') goto yy193; -yy405: - YYDEBUG(405, *YYCURSOR); +yy413: + YYDEBUG(413, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(406, *YYCURSOR); + YYDEBUG(414, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy405; + if (yych == '\t') goto yy413; goto yy193; } else { - if (yych <= ' ') goto yy405; + if (yych <= ' ') goto yy413; if (yych != ')') goto yy193; } - YYDEBUG(407, *YYCURSOR); + YYDEBUG(415, *YYCURSOR); ++YYCURSOR; - YYDEBUG(408, *YYCURSOR); + YYDEBUG(416, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1204 "Zend/zend_language_scanner.l" { return T_DOUBLE_CAST; } -#line 4775 "Zend/zend_language_scanner.c" -yy409: - YYDEBUG(409, *YYCURSOR); +#line 4833 "Zend/zend_language_scanner.c" +yy417: + YYDEBUG(417, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy410; + if (yych == 'U') goto yy418; if (yych != 'u') goto yy193; -yy410: - YYDEBUG(410, *YYCURSOR); +yy418: + YYDEBUG(418, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy411; + if (yych == 'B') goto yy419; if (yych != 'b') goto yy193; -yy411: - YYDEBUG(411, *YYCURSOR); +yy419: + YYDEBUG(419, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy412; + if (yych == 'L') goto yy420; if (yych != 'l') goto yy193; -yy412: - YYDEBUG(412, *YYCURSOR); +yy420: + YYDEBUG(420, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy405; - if (yych == 'e') goto yy405; + if (yych == 'E') goto yy413; + if (yych == 'e') goto yy413; goto yy193; -yy413: - YYDEBUG(413, *YYCURSOR); +yy421: + YYDEBUG(421, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy414; + if (yych == 'A') goto yy422; if (yych != 'a') goto yy193; -yy414: - YYDEBUG(414, *YYCURSOR); +yy422: + YYDEBUG(422, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy405; - if (yych == 'l') goto yy405; + if (yych == 'L') goto yy413; + if (yych == 'l') goto yy413; goto yy193; -yy415: - YYDEBUG(415, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'R') goto yy416; - if (yych != 'r') goto yy193; -yy416: - YYDEBUG(416, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'I') goto yy417; - if (yych != 'i') goto yy193; -yy417: - YYDEBUG(417, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'N') goto yy418; - if (yych != 'n') goto yy193; -yy418: - YYDEBUG(418, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'G') goto yy419; - if (yych != 'g') goto yy193; -yy419: - YYDEBUG(419, *YYCURSOR); - ++YYCURSOR; - YYFILL(1); - yych = *YYCURSOR; - YYDEBUG(420, *YYCURSOR); - if (yych <= 0x1F) { - if (yych == '\t') goto yy419; - goto yy193; - } else { - if (yych <= ' ') goto yy419; - if (yych != ')') goto yy193; - } - YYDEBUG(421, *YYCURSOR); - ++YYCURSOR; - YYDEBUG(422, *YYCURSOR); - yyleng = YYCURSOR - SCNG(yy_text); -#line 1208 "Zend/zend_language_scanner.l" - { - return T_STRING_CAST; -} -#line 4849 "Zend/zend_language_scanner.c" yy423: YYDEBUG(423, *YYCURSOR); yych = *++YYCURSOR; @@ -4854,55 +4870,55 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy424: YYDEBUG(424, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy425; - if (yych != 'a') goto yy193; + if (yych == 'I') goto yy425; + if (yych != 'i') goto yy193; yy425: YYDEBUG(425, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy426; - if (yych != 'y') goto yy193; + if (yych == 'N') goto yy426; + if (yych != 'n') goto yy193; yy426: YYDEBUG(426, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'G') goto yy427; + if (yych != 'g') goto yy193; +yy427: + YYDEBUG(427, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(427, *YYCURSOR); + YYDEBUG(428, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy426; + if (yych == '\t') goto yy427; goto yy193; } else { - if (yych <= ' ') goto yy426; + if (yych <= ' ') goto yy427; if (yych != ')') goto yy193; } - YYDEBUG(428, *YYCURSOR); - ++YYCURSOR; YYDEBUG(429, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(430, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1212 "Zend/zend_language_scanner.l" +#line 1208 "Zend/zend_language_scanner.l" { - return T_ARRAY_CAST; + return T_STRING_CAST; } -#line 4886 "Zend/zend_language_scanner.c" -yy430: - YYDEBUG(430, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'J') goto yy431; - if (yych != 'j') goto yy193; +#line 4907 "Zend/zend_language_scanner.c" yy431: YYDEBUG(431, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy432; - if (yych != 'e') goto yy193; + if (yych == 'R') goto yy432; + if (yych != 'r') goto yy193; yy432: YYDEBUG(432, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy433; - if (yych != 'c') goto yy193; + if (yych == 'A') goto yy433; + if (yych != 'a') goto yy193; yy433: YYDEBUG(433, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy434; - if (yych != 't') goto yy193; + if (yych == 'Y') goto yy434; + if (yych != 'y') goto yy193; yy434: YYDEBUG(434, *YYCURSOR); ++YYCURSOR; @@ -4920,39 +4936,36 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(437, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1216 "Zend/zend_language_scanner.l" +#line 1212 "Zend/zend_language_scanner.l" { - return T_OBJECT_CAST; + return T_ARRAY_CAST; } -#line 4928 "Zend/zend_language_scanner.c" +#line 4944 "Zend/zend_language_scanner.c" yy438: YYDEBUG(438, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy448; - if (yych == 'n') goto yy448; - goto yy193; + if (yych == 'J') goto yy439; + if (yych != 'j') goto yy193; yy439: YYDEBUG(439, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy440; - if (yych != 'o') goto yy193; + if (yych == 'E') goto yy440; + if (yych != 'e') goto yy193; yy440: YYDEBUG(440, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy441; - if (yych != 'l') goto yy193; + if (yych == 'C') goto yy441; + if (yych != 'c') goto yy193; yy441: YYDEBUG(441, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy446; - if (yych == 'e') goto yy446; - goto yy443; + if (yych == 'T') goto yy442; + if (yych != 't') goto yy193; yy442: YYDEBUG(442, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy443: YYDEBUG(443, *YYCURSOR); if (yych <= 0x1F) { if (yych == '\t') goto yy442; @@ -4965,2069 +4978,2114 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(445, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1220 "Zend/zend_language_scanner.l" +#line 1216 "Zend/zend_language_scanner.l" { - return T_BOOL_CAST; + return T_OBJECT_CAST; } -#line 4973 "Zend/zend_language_scanner.c" +#line 4986 "Zend/zend_language_scanner.c" yy446: YYDEBUG(446, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy447; - if (yych != 'a') goto yy193; + if (yych == 'N') goto yy456; + if (yych == 'n') goto yy456; + goto yy193; yy447: YYDEBUG(447, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy442; - if (yych == 'n') goto yy442; - goto yy193; + if (yych == 'O') goto yy448; + if (yych != 'o') goto yy193; yy448: YYDEBUG(448, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy449; - if (yych != 'a') goto yy193; + if (yych == 'L') goto yy449; + if (yych != 'l') goto yy193; yy449: YYDEBUG(449, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy450; - if (yych != 'r') goto yy193; + if (yych == 'E') goto yy454; + if (yych == 'e') goto yy454; + goto yy451; yy450: YYDEBUG(450, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'Y') goto yy419; - if (yych == 'y') goto yy419; - goto yy193; + ++YYCURSOR; + YYFILL(1); + yych = *YYCURSOR; yy451: YYDEBUG(451, *YYCURSOR); + if (yych <= 0x1F) { + if (yych == '\t') goto yy450; + goto yy193; + } else { + if (yych <= ' ') goto yy450; + if (yych != ')') goto yy193; + } + YYDEBUG(452, *YYCURSOR); + ++YYCURSOR; + YYDEBUG(453, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1220 "Zend/zend_language_scanner.l" + { + return T_BOOL_CAST; +} +#line 5031 "Zend/zend_language_scanner.c" +yy454: + YYDEBUG(454, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy452; + if (yych == 'A') goto yy455; + if (yych != 'a') goto yy193; +yy455: + YYDEBUG(455, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy450; + if (yych == 'n') goto yy450; + goto yy193; +yy456: + YYDEBUG(456, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy457; + if (yych != 'a') goto yy193; +yy457: + YYDEBUG(457, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'R') goto yy458; + if (yych != 'r') goto yy193; +yy458: + YYDEBUG(458, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'Y') goto yy427; + if (yych == 'y') goto yy427; + goto yy193; +yy459: + YYDEBUG(459, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy460; if (yych != 's') goto yy193; -yy452: - YYDEBUG(452, *YYCURSOR); +yy460: + YYDEBUG(460, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy453; + if (yych == 'E') goto yy461; if (yych != 'e') goto yy193; -yy453: - YYDEBUG(453, *YYCURSOR); +yy461: + YYDEBUG(461, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy454; + if (yych == 'T') goto yy462; if (yych != 't') goto yy193; -yy454: - YYDEBUG(454, *YYCURSOR); +yy462: + YYDEBUG(462, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(455, *YYCURSOR); + YYDEBUG(463, *YYCURSOR); if (yych <= 0x1F) { - if (yych == '\t') goto yy454; + if (yych == '\t') goto yy462; goto yy193; } else { - if (yych <= ' ') goto yy454; + if (yych <= ' ') goto yy462; if (yych != ')') goto yy193; } - YYDEBUG(456, *YYCURSOR); + YYDEBUG(464, *YYCURSOR); ++YYCURSOR; - YYDEBUG(457, *YYCURSOR); + YYDEBUG(465, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1224 "Zend/zend_language_scanner.l" { return T_UNSET_CAST; } -#line 5037 "Zend/zend_language_scanner.c" -yy458: - YYDEBUG(458, *YYCURSOR); +#line 5095 "Zend/zend_language_scanner.c" +yy466: + YYDEBUG(466, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy459; + if (yych == 'R') goto yy467; if (yych != 'r') goto yy186; -yy459: - YYDEBUG(459, *YYCURSOR); +yy467: + YYDEBUG(467, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(460, *YYCURSOR); + YYDEBUG(468, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1196 "Zend/zend_language_scanner.l" { return T_VAR; } -#line 5055 "Zend/zend_language_scanner.c" -yy461: - YYDEBUG(461, *YYCURSOR); +#line 5113 "Zend/zend_language_scanner.c" +yy469: + YYDEBUG(469, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy465; - if (yych == 'm') goto yy465; + if (yych == 'M') goto yy473; + if (yych == 'm') goto yy473; goto yy186; -yy462: - YYDEBUG(462, *YYCURSOR); +yy470: + YYDEBUG(470, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy463; + if (yych == 'W') goto yy471; if (yych != 'w') goto yy186; -yy463: - YYDEBUG(463, *YYCURSOR); +yy471: + YYDEBUG(471, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(464, *YYCURSOR); + YYDEBUG(472, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1188 "Zend/zend_language_scanner.l" { return T_NEW; } -#line 5079 "Zend/zend_language_scanner.c" -yy465: - YYDEBUG(465, *YYCURSOR); +#line 5137 "Zend/zend_language_scanner.c" +yy473: + YYDEBUG(473, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy466; + if (yych == 'E') goto yy474; if (yych != 'e') goto yy186; -yy466: - YYDEBUG(466, *YYCURSOR); +yy474: + YYDEBUG(474, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy467; + if (yych == 'S') goto yy475; if (yych != 's') goto yy186; -yy467: - YYDEBUG(467, *YYCURSOR); +yy475: + YYDEBUG(475, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy468; + if (yych == 'P') goto yy476; if (yych != 'p') goto yy186; -yy468: - YYDEBUG(468, *YYCURSOR); +yy476: + YYDEBUG(476, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy469; + if (yych == 'A') goto yy477; if (yych != 'a') goto yy186; -yy469: - YYDEBUG(469, *YYCURSOR); +yy477: + YYDEBUG(477, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy470; + if (yych == 'C') goto yy478; if (yych != 'c') goto yy186; -yy470: - YYDEBUG(470, *YYCURSOR); +yy478: + YYDEBUG(478, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy471; + if (yych == 'E') goto yy479; if (yych != 'e') goto yy186; -yy471: - YYDEBUG(471, *YYCURSOR); +yy479: + YYDEBUG(479, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(472, *YYCURSOR); + YYDEBUG(480, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1248 "Zend/zend_language_scanner.l" { return T_NAMESPACE; } -#line 5122 "Zend/zend_language_scanner.c" -yy473: - YYDEBUG(473, *YYCURSOR); +#line 5180 "Zend/zend_language_scanner.c" +yy481: + YYDEBUG(481, *YYCURSOR); ++YYCURSOR; - YYDEBUG(474, *YYCURSOR); + YYDEBUG(482, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1180 "Zend/zend_language_scanner.l" { return T_PAAMAYIM_NEKUDOTAYIM; } -#line 5132 "Zend/zend_language_scanner.c" -yy475: - YYDEBUG(475, *YYCURSOR); +#line 5190 "Zend/zend_language_scanner.c" +yy483: + YYDEBUG(483, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy476: - YYDEBUG(476, *YYCURSOR); +yy484: + YYDEBUG(484, *YYCURSOR); if (yych <= '\f') { if (yych <= 0x08) goto yy140; - if (yych <= '\n') goto yy475; + if (yych <= '\n') goto yy483; goto yy140; } else { - if (yych <= '\r') goto yy475; - if (yych == ' ') goto yy475; + if (yych <= '\r') goto yy483; + if (yych == ' ') goto yy483; goto yy140; } -yy477: - YYDEBUG(477, *YYCURSOR); +yy485: + YYDEBUG(485, *YYCURSOR); ++YYCURSOR; - YYDEBUG(478, *YYCURSOR); + YYDEBUG(486, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1352 "Zend/zend_language_scanner.l" { return T_MINUS_EQUAL; } -#line 5158 "Zend/zend_language_scanner.c" -yy479: - YYDEBUG(479, *YYCURSOR); +#line 5216 "Zend/zend_language_scanner.c" +yy487: + YYDEBUG(487, *YYCURSOR); ++YYCURSOR; - YYDEBUG(480, *YYCURSOR); + YYDEBUG(488, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1320 "Zend/zend_language_scanner.l" { return T_DEC; } -#line 5168 "Zend/zend_language_scanner.c" -yy481: - YYDEBUG(481, *YYCURSOR); +#line 5226 "Zend/zend_language_scanner.c" +yy489: + YYDEBUG(489, *YYCURSOR); ++YYCURSOR; - YYDEBUG(482, *YYCURSOR); + YYDEBUG(490, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1150 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); return T_OBJECT_OPERATOR; } -#line 5179 "Zend/zend_language_scanner.c" -yy483: - YYDEBUG(483, *YYCURSOR); +#line 5237 "Zend/zend_language_scanner.c" +yy491: + YYDEBUG(491, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'I') goto yy490; + if (yych == 'I') goto yy498; if (yych <= 'N') goto yy186; - goto yy491; + goto yy499; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; - goto yy490; + goto yy498; } else { - if (yych == 'o') goto yy491; + if (yych == 'o') goto yy499; goto yy186; } } -yy484: - YYDEBUG(484, *YYCURSOR); +yy492: + YYDEBUG(492, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy485; + if (yych == 'B') goto yy493; if (yych != 'b') goto yy186; -yy485: - YYDEBUG(485, *YYCURSOR); +yy493: + YYDEBUG(493, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy486; + if (yych == 'L') goto yy494; if (yych != 'l') goto yy186; -yy486: - YYDEBUG(486, *YYCURSOR); +yy494: + YYDEBUG(494, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy487; + if (yych == 'I') goto yy495; if (yych != 'i') goto yy186; -yy487: - YYDEBUG(487, *YYCURSOR); +yy495: + YYDEBUG(495, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy488; + if (yych == 'C') goto yy496; if (yych != 'c') goto yy186; -yy488: - YYDEBUG(488, *YYCURSOR); +yy496: + YYDEBUG(496, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(489, *YYCURSOR); + YYDEBUG(497, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1296 "Zend/zend_language_scanner.l" { return T_PUBLIC; } -#line 5228 "Zend/zend_language_scanner.c" -yy490: - YYDEBUG(490, *YYCURSOR); +#line 5286 "Zend/zend_language_scanner.c" +yy498: + YYDEBUG(498, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'V') { - if (yych == 'N') goto yy499; + if (yych == 'N') goto yy507; if (yych <= 'U') goto yy186; - goto yy500; + goto yy508; } else { if (yych <= 'n') { if (yych <= 'm') goto yy186; - goto yy499; + goto yy507; } else { - if (yych == 'v') goto yy500; + if (yych == 'v') goto yy508; goto yy186; } } -yy491: - YYDEBUG(491, *YYCURSOR); +yy499: + YYDEBUG(499, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy492; + if (yych == 'T') goto yy500; if (yych != 't') goto yy186; -yy492: - YYDEBUG(492, *YYCURSOR); +yy500: + YYDEBUG(500, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy493; + if (yych == 'E') goto yy501; if (yych != 'e') goto yy186; -yy493: - YYDEBUG(493, *YYCURSOR); +yy501: + YYDEBUG(501, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy494; + if (yych == 'C') goto yy502; if (yych != 'c') goto yy186; -yy494: - YYDEBUG(494, *YYCURSOR); +yy502: + YYDEBUG(502, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy495; + if (yych == 'T') goto yy503; if (yych != 't') goto yy186; -yy495: - YYDEBUG(495, *YYCURSOR); +yy503: + YYDEBUG(503, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy496; + if (yych == 'E') goto yy504; if (yych != 'e') goto yy186; -yy496: - YYDEBUG(496, *YYCURSOR); +yy504: + YYDEBUG(504, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy497; + if (yych == 'D') goto yy505; if (yych != 'd') goto yy186; -yy497: - YYDEBUG(497, *YYCURSOR); +yy505: + YYDEBUG(505, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(498, *YYCURSOR); + YYDEBUG(506, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1292 "Zend/zend_language_scanner.l" { return T_PROTECTED; } -#line 5287 "Zend/zend_language_scanner.c" -yy499: - YYDEBUG(499, *YYCURSOR); +#line 5345 "Zend/zend_language_scanner.c" +yy507: + YYDEBUG(507, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy505; - if (yych == 't') goto yy505; + if (yych == 'T') goto yy513; + if (yych == 't') goto yy513; goto yy186; -yy500: - YYDEBUG(500, *YYCURSOR); +yy508: + YYDEBUG(508, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy501; + if (yych == 'A') goto yy509; if (yych != 'a') goto yy186; -yy501: - YYDEBUG(501, *YYCURSOR); +yy509: + YYDEBUG(509, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy502; + if (yych == 'T') goto yy510; if (yych != 't') goto yy186; -yy502: - YYDEBUG(502, *YYCURSOR); +yy510: + YYDEBUG(510, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy503; + if (yych == 'E') goto yy511; if (yych != 'e') goto yy186; -yy503: - YYDEBUG(503, *YYCURSOR); +yy511: + YYDEBUG(511, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(504, *YYCURSOR); + YYDEBUG(512, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1288 "Zend/zend_language_scanner.l" { return T_PRIVATE; } -#line 5321 "Zend/zend_language_scanner.c" -yy505: - YYDEBUG(505, *YYCURSOR); +#line 5379 "Zend/zend_language_scanner.c" +yy513: + YYDEBUG(513, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(506, *YYCURSOR); + YYDEBUG(514, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1126 "Zend/zend_language_scanner.l" { return T_PRINT; } -#line 5334 "Zend/zend_language_scanner.c" -yy507: - YYDEBUG(507, *YYCURSOR); +#line 5392 "Zend/zend_language_scanner.c" +yy515: + YYDEBUG(515, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy512; - if (yych == 'o') goto yy512; + if (yych == 'O') goto yy520; + if (yych == 'o') goto yy520; goto yy186; -yy508: - YYDEBUG(508, *YYCURSOR); +yy516: + YYDEBUG(516, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy509; + if (yych == 'T') goto yy517; if (yych != 't') goto yy186; -yy509: - YYDEBUG(509, *YYCURSOR); +yy517: + YYDEBUG(517, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy510; + if (yych == 'O') goto yy518; if (yych != 'o') goto yy186; -yy510: - YYDEBUG(510, *YYCURSOR); +yy518: + YYDEBUG(518, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(511, *YYCURSOR); + YYDEBUG(519, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1118 "Zend/zend_language_scanner.l" { return T_GOTO; } -#line 5363 "Zend/zend_language_scanner.c" -yy512: - YYDEBUG(512, *YYCURSOR); +#line 5421 "Zend/zend_language_scanner.c" +yy520: + YYDEBUG(520, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'B') goto yy513; + if (yych == 'B') goto yy521; if (yych != 'b') goto yy186; -yy513: - YYDEBUG(513, *YYCURSOR); +yy521: + YYDEBUG(521, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy514; + if (yych == 'A') goto yy522; if (yych != 'a') goto yy186; -yy514: - YYDEBUG(514, *YYCURSOR); +yy522: + YYDEBUG(522, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy515; + if (yych == 'L') goto yy523; if (yych != 'l') goto yy186; -yy515: - YYDEBUG(515, *YYCURSOR); +yy523: + YYDEBUG(523, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(516, *YYCURSOR); + YYDEBUG(524, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1260 "Zend/zend_language_scanner.l" { return T_GLOBAL; } -#line 5391 "Zend/zend_language_scanner.c" -yy517: - YYDEBUG(517, *YYCURSOR); +#line 5449 "Zend/zend_language_scanner.c" +yy525: + YYDEBUG(525, *YYCURSOR); yych = *++YYCURSOR; - if (yych == '<') goto yy525; + if (yych == '<') goto yy533; goto yy193; -yy518: - YYDEBUG(518, *YYCURSOR); +yy526: + YYDEBUG(526, *YYCURSOR); yych = *++YYCURSOR; goto yy180; -yy519: - YYDEBUG(519, *YYCURSOR); +yy527: + YYDEBUG(527, *YYCURSOR); yych = *++YYCURSOR; goto yy178; -yy520: - YYDEBUG(520, *YYCURSOR); +yy528: + YYDEBUG(528, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy521; + if (yych == 'E') goto yy529; if (yych != 'e') goto yy186; -yy521: - YYDEBUG(521, *YYCURSOR); +yy529: + YYDEBUG(529, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy522; + if (yych == 'A') goto yy530; if (yych != 'a') goto yy186; -yy522: - YYDEBUG(522, *YYCURSOR); +yy530: + YYDEBUG(530, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'K') goto yy523; + if (yych == 'K') goto yy531; if (yych != 'k') goto yy186; -yy523: - YYDEBUG(523, *YYCURSOR); +yy531: + YYDEBUG(531, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(524, *YYCURSOR); + YYDEBUG(532, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1110 "Zend/zend_language_scanner.l" { return T_BREAK; } -#line 5432 "Zend/zend_language_scanner.c" -yy525: - YYDEBUG(525, *YYCURSOR); +#line 5490 "Zend/zend_language_scanner.c" +yy533: + YYDEBUG(533, *YYCURSOR); yych = *++YYCURSOR; if (yych == '<') goto yy269; goto yy193; -yy526: - YYDEBUG(526, *YYCURSOR); +yy534: + YYDEBUG(534, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy533; - if (yych == 'a') goto yy533; + if (yych == 'A') goto yy541; + if (yych == 'a') goto yy541; goto yy186; -yy527: - YYDEBUG(527, *YYCURSOR); +yy535: + YYDEBUG(535, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy528; + if (yych == 'I') goto yy536; if (yych != 'i') goto yy186; -yy528: - YYDEBUG(528, *YYCURSOR); +yy536: + YYDEBUG(536, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy529; + if (yych == 'T') goto yy537; if (yych != 't') goto yy186; -yy529: - YYDEBUG(529, *YYCURSOR); +yy537: + YYDEBUG(537, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy530; + if (yych == 'C') goto yy538; if (yych != 'c') goto yy186; -yy530: - YYDEBUG(530, *YYCURSOR); +yy538: + YYDEBUG(538, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy531; + if (yych == 'H') goto yy539; if (yych != 'h') goto yy186; -yy531: - YYDEBUG(531, *YYCURSOR); +yy539: + YYDEBUG(539, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(532, *YYCURSOR); + YYDEBUG(540, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1094 "Zend/zend_language_scanner.l" { return T_SWITCH; } -#line 5476 "Zend/zend_language_scanner.c" -yy533: - YYDEBUG(533, *YYCURSOR); +#line 5534 "Zend/zend_language_scanner.c" +yy541: + YYDEBUG(541, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy534; + if (yych == 'T') goto yy542; if (yych != 't') goto yy186; -yy534: - YYDEBUG(534, *YYCURSOR); +yy542: + YYDEBUG(542, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy535; + if (yych == 'I') goto yy543; if (yych != 'i') goto yy186; -yy535: - YYDEBUG(535, *YYCURSOR); +yy543: + YYDEBUG(543, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy536; + if (yych == 'C') goto yy544; if (yych != 'c') goto yy186; -yy536: - YYDEBUG(536, *YYCURSOR); +yy544: + YYDEBUG(544, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(537, *YYCURSOR); + YYDEBUG(545, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1276 "Zend/zend_language_scanner.l" { return T_STATIC; } -#line 5504 "Zend/zend_language_scanner.c" -yy538: - YYDEBUG(538, *YYCURSOR); +#line 5562 "Zend/zend_language_scanner.c" +yy546: + YYDEBUG(546, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy549; - if (yych == 's') goto yy549; + if (yych == 'S') goto yy557; + if (yych == 's') goto yy557; goto yy186; -yy539: - YYDEBUG(539, *YYCURSOR); +yy547: + YYDEBUG(547, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy547; - if (yych == 'd') goto yy547; + if (yych == 'D') goto yy555; + if (yych == 'd') goto yy555; goto yy186; -yy540: - YYDEBUG(540, *YYCURSOR); +yy548: + YYDEBUG(548, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy543; - if (yych == 'r') goto yy543; + if (yych == 'R') goto yy551; + if (yych == 'r') goto yy551; goto yy186; -yy541: - YYDEBUG(541, *YYCURSOR); +yy549: + YYDEBUG(549, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(542, *YYCURSOR); + YYDEBUG(550, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1090 "Zend/zend_language_scanner.l" { return T_AS; } -#line 5535 "Zend/zend_language_scanner.c" -yy543: - YYDEBUG(543, *YYCURSOR); +#line 5593 "Zend/zend_language_scanner.c" +yy551: + YYDEBUG(551, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy544; + if (yych == 'A') goto yy552; if (yych != 'a') goto yy186; -yy544: - YYDEBUG(544, *YYCURSOR); +yy552: + YYDEBUG(552, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy545; + if (yych == 'Y') goto yy553; if (yych != 'y') goto yy186; -yy545: - YYDEBUG(545, *YYCURSOR); +yy553: + YYDEBUG(553, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(546, *YYCURSOR); + YYDEBUG(554, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1312 "Zend/zend_language_scanner.l" { return T_ARRAY; } -#line 5558 "Zend/zend_language_scanner.c" -yy547: - YYDEBUG(547, *YYCURSOR); +#line 5616 "Zend/zend_language_scanner.c" +yy555: + YYDEBUG(555, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(548, *YYCURSOR); + YYDEBUG(556, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1404 "Zend/zend_language_scanner.l" { return T_LOGICAL_AND; } -#line 5571 "Zend/zend_language_scanner.c" -yy549: - YYDEBUG(549, *YYCURSOR); +#line 5629 "Zend/zend_language_scanner.c" +yy557: + YYDEBUG(557, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy550; + if (yych == 'T') goto yy558; if (yych != 't') goto yy186; -yy550: - YYDEBUG(550, *YYCURSOR); +yy558: + YYDEBUG(558, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy551; + if (yych == 'R') goto yy559; if (yych != 'r') goto yy186; -yy551: - YYDEBUG(551, *YYCURSOR); +yy559: + YYDEBUG(559, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy552; + if (yych == 'A') goto yy560; if (yych != 'a') goto yy186; -yy552: - YYDEBUG(552, *YYCURSOR); +yy560: + YYDEBUG(560, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy553; + if (yych == 'C') goto yy561; if (yych != 'c') goto yy186; -yy553: - YYDEBUG(553, *YYCURSOR); +yy561: + YYDEBUG(561, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy554; + if (yych == 'T') goto yy562; if (yych != 't') goto yy186; -yy554: - YYDEBUG(554, *YYCURSOR); +yy562: + YYDEBUG(562, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(555, *YYCURSOR); + YYDEBUG(563, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1280 "Zend/zend_language_scanner.l" { return T_ABSTRACT; } -#line 5609 "Zend/zend_language_scanner.c" -yy556: - YYDEBUG(556, *YYCURSOR); +#line 5667 "Zend/zend_language_scanner.c" +yy564: + YYDEBUG(564, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy557; + if (yych == 'I') goto yy565; if (yych != 'i') goto yy186; -yy557: - YYDEBUG(557, *YYCURSOR); +yy565: + YYDEBUG(565, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy558; + if (yych == 'L') goto yy566; if (yych != 'l') goto yy186; -yy558: - YYDEBUG(558, *YYCURSOR); +yy566: + YYDEBUG(566, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy559; + if (yych == 'E') goto yy567; if (yych != 'e') goto yy186; -yy559: - YYDEBUG(559, *YYCURSOR); +yy567: + YYDEBUG(567, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(560, *YYCURSOR); + YYDEBUG(568, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1050 "Zend/zend_language_scanner.l" { return T_WHILE; } -#line 5637 "Zend/zend_language_scanner.c" -yy561: - YYDEBUG(561, *YYCURSOR); +#line 5695 "Zend/zend_language_scanner.c" +yy569: + YYDEBUG(569, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(562, *YYCURSOR); + YYDEBUG(570, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1034 "Zend/zend_language_scanner.l" { return T_IF; } -#line 5650 "Zend/zend_language_scanner.c" -yy563: - YYDEBUG(563, *YYCURSOR); +#line 5708 "Zend/zend_language_scanner.c" +yy571: + YYDEBUG(571, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy605; - if (yych == 'p') goto yy605; + if (yych == 'P') goto yy613; + if (yych == 'p') goto yy613; goto yy186; -yy564: - YYDEBUG(564, *YYCURSOR); +yy572: + YYDEBUG(572, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'C') { if (yych <= 'B') goto yy186; - goto yy572; + goto yy580; } else { if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy570; - goto yy571; + if (yych <= 'S') goto yy578; + goto yy579; } } else { if (yych <= 'r') { - if (yych == 'c') goto yy572; + if (yych == 'c') goto yy580; goto yy186; } else { - if (yych <= 's') goto yy570; - if (yych <= 't') goto yy571; + if (yych <= 's') goto yy578; + if (yych <= 't') goto yy579; goto yy186; } } -yy565: - YYDEBUG(565, *YYCURSOR); +yy573: + YYDEBUG(573, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy566; + if (yych == 'S') goto yy574; if (yych != 's') goto yy186; -yy566: - YYDEBUG(566, *YYCURSOR); +yy574: + YYDEBUG(574, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy567; + if (yych == 'E') goto yy575; if (yych != 'e') goto yy186; -yy567: - YYDEBUG(567, *YYCURSOR); +yy575: + YYDEBUG(575, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy568; + if (yych == 'T') goto yy576; if (yych != 't') goto yy186; -yy568: - YYDEBUG(568, *YYCURSOR); +yy576: + YYDEBUG(576, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(569, *YYCURSOR); + YYDEBUG(577, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1264 "Zend/zend_language_scanner.l" { return T_ISSET; } -#line 5706 "Zend/zend_language_scanner.c" -yy570: - YYDEBUG(570, *YYCURSOR); +#line 5764 "Zend/zend_language_scanner.c" +yy578: + YYDEBUG(578, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy591; - if (yych == 't') goto yy591; + if (yych == 'T') goto yy599; + if (yych == 't') goto yy599; goto yy186; -yy571: - YYDEBUG(571, *YYCURSOR); +yy579: + YYDEBUG(579, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy584; - if (yych == 'e') goto yy584; + if (yych == 'E') goto yy592; + if (yych == 'e') goto yy592; goto yy186; -yy572: - YYDEBUG(572, *YYCURSOR); +yy580: + YYDEBUG(580, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy573; + if (yych == 'L') goto yy581; if (yych != 'l') goto yy186; -yy573: - YYDEBUG(573, *YYCURSOR); +yy581: + YYDEBUG(581, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy574; + if (yych == 'U') goto yy582; if (yych != 'u') goto yy186; -yy574: - YYDEBUG(574, *YYCURSOR); +yy582: + YYDEBUG(582, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy575; + if (yych == 'D') goto yy583; if (yych != 'd') goto yy186; -yy575: - YYDEBUG(575, *YYCURSOR); +yy583: + YYDEBUG(583, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy576; + if (yych == 'E') goto yy584; if (yych != 'e') goto yy186; -yy576: - YYDEBUG(576, *YYCURSOR); +yy584: + YYDEBUG(584, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '9') { if (yych >= '0') goto yy185; } else { - if (yych <= '@') goto yy577; + if (yych <= '@') goto yy585; if (yych <= 'Z') goto yy185; } } else { if (yych <= '`') { - if (yych <= '_') goto yy578; + if (yych <= '_') goto yy586; } else { if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy577: - YYDEBUG(577, *YYCURSOR); +yy585: + YYDEBUG(585, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1232 "Zend/zend_language_scanner.l" { return T_INCLUDE; } -#line 5764 "Zend/zend_language_scanner.c" -yy578: - YYDEBUG(578, *YYCURSOR); +#line 5822 "Zend/zend_language_scanner.c" +yy586: + YYDEBUG(586, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy579; + if (yych == 'O') goto yy587; if (yych != 'o') goto yy186; -yy579: - YYDEBUG(579, *YYCURSOR); +yy587: + YYDEBUG(587, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy580; + if (yych == 'N') goto yy588; if (yych != 'n') goto yy186; -yy580: - YYDEBUG(580, *YYCURSOR); +yy588: + YYDEBUG(588, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy581; + if (yych == 'C') goto yy589; if (yych != 'c') goto yy186; -yy581: - YYDEBUG(581, *YYCURSOR); +yy589: + YYDEBUG(589, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy582; + if (yych == 'E') goto yy590; if (yych != 'e') goto yy186; -yy582: - YYDEBUG(582, *YYCURSOR); +yy590: + YYDEBUG(590, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(583, *YYCURSOR); + YYDEBUG(591, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1236 "Zend/zend_language_scanner.l" { return T_INCLUDE_ONCE; } -#line 5797 "Zend/zend_language_scanner.c" -yy584: - YYDEBUG(584, *YYCURSOR); +#line 5855 "Zend/zend_language_scanner.c" +yy592: + YYDEBUG(592, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy585; + if (yych == 'R') goto yy593; if (yych != 'r') goto yy186; -yy585: - YYDEBUG(585, *YYCURSOR); +yy593: + YYDEBUG(593, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy586; + if (yych == 'F') goto yy594; if (yych != 'f') goto yy186; -yy586: - YYDEBUG(586, *YYCURSOR); +yy594: + YYDEBUG(594, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy587; + if (yych == 'A') goto yy595; if (yych != 'a') goto yy186; -yy587: - YYDEBUG(587, *YYCURSOR); +yy595: + YYDEBUG(595, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy588; + if (yych == 'C') goto yy596; if (yych != 'c') goto yy186; -yy588: - YYDEBUG(588, *YYCURSOR); +yy596: + YYDEBUG(596, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy589; + if (yych == 'E') goto yy597; if (yych != 'e') goto yy186; -yy589: - YYDEBUG(589, *YYCURSOR); +yy597: + YYDEBUG(597, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(590, *YYCURSOR); + YYDEBUG(598, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1134 "Zend/zend_language_scanner.l" { return T_INTERFACE; } -#line 5835 "Zend/zend_language_scanner.c" -yy591: - YYDEBUG(591, *YYCURSOR); +#line 5893 "Zend/zend_language_scanner.c" +yy599: + YYDEBUG(599, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'E') { - if (yych == 'A') goto yy592; + if (yych == 'A') goto yy600; if (yych <= 'D') goto yy186; - goto yy593; + goto yy601; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; } else { - if (yych == 'e') goto yy593; + if (yych == 'e') goto yy601; goto yy186; } } -yy592: - YYDEBUG(592, *YYCURSOR); +yy600: + YYDEBUG(600, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy599; - if (yych == 'n') goto yy599; + if (yych == 'N') goto yy607; + if (yych == 'n') goto yy607; goto yy186; -yy593: - YYDEBUG(593, *YYCURSOR); +yy601: + YYDEBUG(601, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy594; + if (yych == 'A') goto yy602; if (yych != 'a') goto yy186; -yy594: - YYDEBUG(594, *YYCURSOR); +yy602: + YYDEBUG(602, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy595; + if (yych == 'D') goto yy603; if (yych != 'd') goto yy186; -yy595: - YYDEBUG(595, *YYCURSOR); +yy603: + YYDEBUG(603, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy596; + if (yych == 'O') goto yy604; if (yych != 'o') goto yy186; -yy596: - YYDEBUG(596, *YYCURSOR); +yy604: + YYDEBUG(604, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy597; + if (yych == 'F') goto yy605; if (yych != 'f') goto yy186; -yy597: - YYDEBUG(597, *YYCURSOR); +yy605: + YYDEBUG(605, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(598, *YYCURSOR); + YYDEBUG(606, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1256 "Zend/zend_language_scanner.l" { return T_INSTEADOF; } -#line 5889 "Zend/zend_language_scanner.c" -yy599: - YYDEBUG(599, *YYCURSOR); +#line 5947 "Zend/zend_language_scanner.c" +yy607: + YYDEBUG(607, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy600; + if (yych == 'C') goto yy608; if (yych != 'c') goto yy186; -yy600: - YYDEBUG(600, *YYCURSOR); +yy608: + YYDEBUG(608, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy601; + if (yych == 'E') goto yy609; if (yych != 'e') goto yy186; -yy601: - YYDEBUG(601, *YYCURSOR); +yy609: + YYDEBUG(609, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy602; + if (yych == 'O') goto yy610; if (yych != 'o') goto yy186; -yy602: - YYDEBUG(602, *YYCURSOR); +yy610: + YYDEBUG(610, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy603; + if (yych == 'F') goto yy611; if (yych != 'f') goto yy186; -yy603: - YYDEBUG(603, *YYCURSOR); +yy611: + YYDEBUG(611, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(604, *YYCURSOR); + YYDEBUG(612, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1086 "Zend/zend_language_scanner.l" { return T_INSTANCEOF; } -#line 5922 "Zend/zend_language_scanner.c" -yy605: - YYDEBUG(605, *YYCURSOR); +#line 5980 "Zend/zend_language_scanner.c" +yy613: + YYDEBUG(613, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy606; + if (yych == 'L') goto yy614; if (yych != 'l') goto yy186; -yy606: - YYDEBUG(606, *YYCURSOR); +yy614: + YYDEBUG(614, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy607; + if (yych == 'E') goto yy615; if (yych != 'e') goto yy186; -yy607: - YYDEBUG(607, *YYCURSOR); +yy615: + YYDEBUG(615, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'M') goto yy608; + if (yych == 'M') goto yy616; if (yych != 'm') goto yy186; -yy608: - YYDEBUG(608, *YYCURSOR); +yy616: + YYDEBUG(616, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy609; + if (yych == 'E') goto yy617; if (yych != 'e') goto yy186; -yy609: - YYDEBUG(609, *YYCURSOR); +yy617: + YYDEBUG(617, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy610; + if (yych == 'N') goto yy618; if (yych != 'n') goto yy186; -yy610: - YYDEBUG(610, *YYCURSOR); +yy618: + YYDEBUG(618, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy611; + if (yych == 'T') goto yy619; if (yych != 't') goto yy186; -yy611: - YYDEBUG(611, *YYCURSOR); +yy619: + YYDEBUG(619, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy612; + if (yych == 'S') goto yy620; if (yych != 's') goto yy186; -yy612: - YYDEBUG(612, *YYCURSOR); +yy620: + YYDEBUG(620, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(613, *YYCURSOR); + YYDEBUG(621, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1146 "Zend/zend_language_scanner.l" { return T_IMPLEMENTS; } -#line 5970 "Zend/zend_language_scanner.c" -yy614: - YYDEBUG(614, *YYCURSOR); +#line 6028 "Zend/zend_language_scanner.c" +yy622: + YYDEBUG(622, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy622; - if (yych == 'r') goto yy622; + if (yych == 'R') goto yy630; + if (yych == 'r') goto yy630; goto yy186; -yy615: - YYDEBUG(615, *YYCURSOR); +yy623: + YYDEBUG(623, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'Y') { - if (yych == 'A') goto yy618; + if (yych == 'A') goto yy626; if (yych <= 'X') goto yy186; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy618; + goto yy626; } else { if (yych != 'y') goto yy186; } } - YYDEBUG(616, *YYCURSOR); + YYDEBUG(624, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(617, *YYCURSOR); + YYDEBUG(625, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1022 "Zend/zend_language_scanner.l" { return T_TRY; } -#line 6002 "Zend/zend_language_scanner.c" -yy618: - YYDEBUG(618, *YYCURSOR); +#line 6060 "Zend/zend_language_scanner.c" +yy626: + YYDEBUG(626, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy619; + if (yych == 'I') goto yy627; if (yych != 'i') goto yy186; -yy619: - YYDEBUG(619, *YYCURSOR); +yy627: + YYDEBUG(627, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy620; + if (yych == 'T') goto yy628; if (yych != 't') goto yy186; -yy620: - YYDEBUG(620, *YYCURSOR); +yy628: + YYDEBUG(628, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(621, *YYCURSOR); + YYDEBUG(629, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1138 "Zend/zend_language_scanner.l" { return T_TRAIT; } -#line 6025 "Zend/zend_language_scanner.c" -yy622: - YYDEBUG(622, *YYCURSOR); +#line 6083 "Zend/zend_language_scanner.c" +yy630: + YYDEBUG(630, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy623; + if (yych == 'O') goto yy631; if (yych != 'o') goto yy186; -yy623: - YYDEBUG(623, *YYCURSOR); +yy631: + YYDEBUG(631, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy624; + if (yych == 'W') goto yy632; if (yych != 'w') goto yy186; -yy624: - YYDEBUG(624, *YYCURSOR); +yy632: + YYDEBUG(632, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(625, *YYCURSOR); + YYDEBUG(633, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1030 "Zend/zend_language_scanner.l" { return T_THROW; } -#line 6048 "Zend/zend_language_scanner.c" -yy626: - YYDEBUG(626, *YYCURSOR); +#line 6106 "Zend/zend_language_scanner.c" +yy634: + YYDEBUG(634, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'Q') goto yy628; + if (yych == 'Q') goto yy636; if (yych <= 'S') goto yy186; } else { if (yych <= 'q') { if (yych <= 'p') goto yy186; - goto yy628; + goto yy636; } else { if (yych != 't') goto yy186; } } - YYDEBUG(627, *YYCURSOR); + YYDEBUG(635, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy640; - if (yych == 'u') goto yy640; + if (yych == 'U') goto yy648; + if (yych == 'u') goto yy648; goto yy186; -yy628: - YYDEBUG(628, *YYCURSOR); +yy636: + YYDEBUG(636, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy629; + if (yych == 'U') goto yy637; if (yych != 'u') goto yy186; -yy629: - YYDEBUG(629, *YYCURSOR); +yy637: + YYDEBUG(637, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy630; + if (yych == 'I') goto yy638; if (yych != 'i') goto yy186; -yy630: - YYDEBUG(630, *YYCURSOR); +yy638: + YYDEBUG(638, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy631; + if (yych == 'R') goto yy639; if (yych != 'r') goto yy186; -yy631: - YYDEBUG(631, *YYCURSOR); +yy639: + YYDEBUG(639, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy632; + if (yych == 'E') goto yy640; if (yych != 'e') goto yy186; -yy632: - YYDEBUG(632, *YYCURSOR); +yy640: + YYDEBUG(640, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '9') { if (yych >= '0') goto yy185; } else { - if (yych <= '@') goto yy633; + if (yych <= '@') goto yy641; if (yych <= 'Z') goto yy185; } } else { if (yych <= '`') { - if (yych <= '_') goto yy634; + if (yych <= '_') goto yy642; } else { if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy633: - YYDEBUG(633, *YYCURSOR); +yy641: + YYDEBUG(641, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1240 "Zend/zend_language_scanner.l" { return T_REQUIRE; } -#line 6113 "Zend/zend_language_scanner.c" -yy634: - YYDEBUG(634, *YYCURSOR); +#line 6171 "Zend/zend_language_scanner.c" +yy642: + YYDEBUG(642, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy635; + if (yych == 'O') goto yy643; if (yych != 'o') goto yy186; -yy635: - YYDEBUG(635, *YYCURSOR); +yy643: + YYDEBUG(643, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy636; + if (yych == 'N') goto yy644; if (yych != 'n') goto yy186; -yy636: - YYDEBUG(636, *YYCURSOR); +yy644: + YYDEBUG(644, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy637; + if (yych == 'C') goto yy645; if (yych != 'c') goto yy186; -yy637: - YYDEBUG(637, *YYCURSOR); +yy645: + YYDEBUG(645, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy638; + if (yych == 'E') goto yy646; if (yych != 'e') goto yy186; -yy638: - YYDEBUG(638, *YYCURSOR); +yy646: + YYDEBUG(646, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(639, *YYCURSOR); + YYDEBUG(647, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1244 "Zend/zend_language_scanner.l" { return T_REQUIRE_ONCE; } -#line 6146 "Zend/zend_language_scanner.c" -yy640: - YYDEBUG(640, *YYCURSOR); +#line 6204 "Zend/zend_language_scanner.c" +yy648: + YYDEBUG(648, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy641; + if (yych == 'R') goto yy649; if (yych != 'r') goto yy186; -yy641: - YYDEBUG(641, *YYCURSOR); +yy649: + YYDEBUG(649, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy642; + if (yych == 'N') goto yy650; if (yych != 'n') goto yy186; -yy642: - YYDEBUG(642, *YYCURSOR); +yy650: + YYDEBUG(650, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(643, *YYCURSOR); + YYDEBUG(651, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1018 "Zend/zend_language_scanner.l" { return T_RETURN; } -#line 6169 "Zend/zend_language_scanner.c" -yy644: - YYDEBUG(644, *YYCURSOR); +#line 6227 "Zend/zend_language_scanner.c" +yy652: + YYDEBUG(652, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy666; - goto yy665; + if (yych <= 'S') goto yy674; + goto yy673; } else { if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy666; - if (yych <= 't') goto yy665; + if (yych <= 's') goto yy674; + if (yych <= 't') goto yy673; goto yy186; } -yy645: - YYDEBUG(645, *YYCURSOR); +yy653: + YYDEBUG(653, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'O') { - if (yych == 'A') goto yy657; + if (yych == 'A') goto yy665; if (yych <= 'N') goto yy186; - goto yy658; + goto yy666; } else { if (yych <= 'a') { if (yych <= '`') goto yy186; - goto yy657; + goto yy665; } else { - if (yych == 'o') goto yy658; + if (yych == 'o') goto yy666; goto yy186; } } -yy646: - YYDEBUG(646, *YYCURSOR); +yy654: + YYDEBUG(654, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy647; + if (yych == 'N') goto yy655; if (yych != 'n') goto yy186; -yy647: - YYDEBUG(647, *YYCURSOR); +yy655: + YYDEBUG(655, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { if (yych <= 'R') goto yy186; - if (yych >= 'T') goto yy649; + if (yych >= 'T') goto yy657; } else { if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy648; - if (yych <= 't') goto yy649; + if (yych <= 's') goto yy656; + if (yych <= 't') goto yy657; goto yy186; } -yy648: - YYDEBUG(648, *YYCURSOR); +yy656: + YYDEBUG(656, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy655; - if (yych == 't') goto yy655; + if (yych == 'T') goto yy663; + if (yych == 't') goto yy663; goto yy186; -yy649: - YYDEBUG(649, *YYCURSOR); +yy657: + YYDEBUG(657, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy650; + if (yych == 'I') goto yy658; if (yych != 'i') goto yy186; -yy650: - YYDEBUG(650, *YYCURSOR); +yy658: + YYDEBUG(658, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy651; + if (yych == 'N') goto yy659; if (yych != 'n') goto yy186; -yy651: - YYDEBUG(651, *YYCURSOR); +yy659: + YYDEBUG(659, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy652; + if (yych == 'U') goto yy660; if (yych != 'u') goto yy186; -yy652: - YYDEBUG(652, *YYCURSOR); +yy660: + YYDEBUG(660, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy653; + if (yych == 'E') goto yy661; if (yych != 'e') goto yy186; -yy653: - YYDEBUG(653, *YYCURSOR); +yy661: + YYDEBUG(661, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(654, *YYCURSOR); + YYDEBUG(662, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1114 "Zend/zend_language_scanner.l" { return T_CONTINUE; } -#line 6254 "Zend/zend_language_scanner.c" -yy655: - YYDEBUG(655, *YYCURSOR); +#line 6312 "Zend/zend_language_scanner.c" +yy663: + YYDEBUG(663, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(656, *YYCURSOR); + YYDEBUG(664, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1014 "Zend/zend_language_scanner.l" { return T_CONST; } -#line 6267 "Zend/zend_language_scanner.c" -yy657: - YYDEBUG(657, *YYCURSOR); +#line 6325 "Zend/zend_language_scanner.c" +yy665: + YYDEBUG(665, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy662; - if (yych == 's') goto yy662; + if (yych == 'S') goto yy670; + if (yych == 's') goto yy670; goto yy186; -yy658: - YYDEBUG(658, *YYCURSOR); +yy666: + YYDEBUG(666, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy659; + if (yych == 'N') goto yy667; if (yych != 'n') goto yy186; -yy659: - YYDEBUG(659, *YYCURSOR); +yy667: + YYDEBUG(667, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy660; + if (yych == 'E') goto yy668; if (yych != 'e') goto yy186; -yy660: - YYDEBUG(660, *YYCURSOR); +yy668: + YYDEBUG(668, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(661, *YYCURSOR); + YYDEBUG(669, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1192 "Zend/zend_language_scanner.l" { return T_CLONE; } -#line 6296 "Zend/zend_language_scanner.c" -yy662: - YYDEBUG(662, *YYCURSOR); +#line 6354 "Zend/zend_language_scanner.c" +yy670: + YYDEBUG(670, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy663; + if (yych == 'S') goto yy671; if (yych != 's') goto yy186; -yy663: - YYDEBUG(663, *YYCURSOR); +yy671: + YYDEBUG(671, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(664, *YYCURSOR); + YYDEBUG(672, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1130 "Zend/zend_language_scanner.l" { return T_CLASS; } -#line 6314 "Zend/zend_language_scanner.c" -yy665: - YYDEBUG(665, *YYCURSOR); +#line 6372 "Zend/zend_language_scanner.c" +yy673: + YYDEBUG(673, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy669; - if (yych == 'c') goto yy669; + if (yych == 'C') goto yy677; + if (yych == 'c') goto yy677; goto yy186; -yy666: - YYDEBUG(666, *YYCURSOR); +yy674: + YYDEBUG(674, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy667; + if (yych == 'E') goto yy675; if (yych != 'e') goto yy186; -yy667: - YYDEBUG(667, *YYCURSOR); +yy675: + YYDEBUG(675, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(668, *YYCURSOR); + YYDEBUG(676, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1102 "Zend/zend_language_scanner.l" { return T_CASE; } -#line 6338 "Zend/zend_language_scanner.c" -yy669: - YYDEBUG(669, *YYCURSOR); +#line 6396 "Zend/zend_language_scanner.c" +yy677: + YYDEBUG(677, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy670; + if (yych == 'H') goto yy678; if (yych != 'h') goto yy186; -yy670: - YYDEBUG(670, *YYCURSOR); +yy678: + YYDEBUG(678, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(671, *YYCURSOR); + YYDEBUG(679, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1026 "Zend/zend_language_scanner.l" { return T_CATCH; } -#line 6356 "Zend/zend_language_scanner.c" -yy672: - YYDEBUG(672, *YYCURSOR); +#line 6414 "Zend/zend_language_scanner.c" +yy680: + YYDEBUG(680, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy689; - if (yych == 'n') goto yy689; + if (yych == 'N') goto yy697; + if (yych == 'n') goto yy697; goto yy186; -yy673: - YYDEBUG(673, *YYCURSOR); +yy681: + YYDEBUG(681, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy682; - if (yych == 'r') goto yy682; + if (yych == 'R') goto yy690; + if (yych == 'r') goto yy690; goto yy186; -yy674: - YYDEBUG(674, *YYCURSOR); +yy682: + YYDEBUG(682, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy675; + if (yych == 'N') goto yy683; if (yych != 'n') goto yy186; -yy675: - YYDEBUG(675, *YYCURSOR); +yy683: + YYDEBUG(683, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy676; + if (yych == 'C') goto yy684; if (yych != 'c') goto yy186; -yy676: - YYDEBUG(676, *YYCURSOR); +yy684: + YYDEBUG(684, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy677; + if (yych == 'T') goto yy685; if (yych != 't') goto yy186; -yy677: - YYDEBUG(677, *YYCURSOR); +yy685: + YYDEBUG(685, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy678; + if (yych == 'I') goto yy686; if (yych != 'i') goto yy186; -yy678: - YYDEBUG(678, *YYCURSOR); +yy686: + YYDEBUG(686, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy679; + if (yych == 'O') goto yy687; if (yych != 'o') goto yy186; -yy679: - YYDEBUG(679, *YYCURSOR); +yy687: + YYDEBUG(687, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy680; + if (yych == 'N') goto yy688; if (yych != 'n') goto yy186; -yy680: - YYDEBUG(680, *YYCURSOR); +yy688: + YYDEBUG(688, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(681, *YYCURSOR); + YYDEBUG(689, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1010 "Zend/zend_language_scanner.l" { return T_FUNCTION; } -#line 6411 "Zend/zend_language_scanner.c" -yy682: - YYDEBUG(682, *YYCURSOR); +#line 6469 "Zend/zend_language_scanner.c" +yy690: + YYDEBUG(690, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy683; + if (yych <= '/') goto yy691; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy684; + if (yych == 'E') goto yy692; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy684; + if (yych <= 'e') goto yy692; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy683: - YYDEBUG(683, *YYCURSOR); +yy691: + YYDEBUG(691, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1062 "Zend/zend_language_scanner.l" { return T_FOR; } -#line 6439 "Zend/zend_language_scanner.c" -yy684: - YYDEBUG(684, *YYCURSOR); +#line 6497 "Zend/zend_language_scanner.c" +yy692: + YYDEBUG(692, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy685; + if (yych == 'A') goto yy693; if (yych != 'a') goto yy186; -yy685: - YYDEBUG(685, *YYCURSOR); +yy693: + YYDEBUG(693, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy686; + if (yych == 'C') goto yy694; if (yych != 'c') goto yy186; -yy686: - YYDEBUG(686, *YYCURSOR); +yy694: + YYDEBUG(694, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy687; + if (yych == 'H') goto yy695; if (yych != 'h') goto yy186; -yy687: - YYDEBUG(687, *YYCURSOR); +yy695: + YYDEBUG(695, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(688, *YYCURSOR); + YYDEBUG(696, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1070 "Zend/zend_language_scanner.l" { return T_FOREACH; } -#line 6467 "Zend/zend_language_scanner.c" -yy689: - YYDEBUG(689, *YYCURSOR); +#line 6525 "Zend/zend_language_scanner.c" +yy697: + YYDEBUG(697, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy690; + if (yych == 'A') goto yy698; if (yych != 'a') goto yy186; -yy690: - YYDEBUG(690, *YYCURSOR); +yy698: + YYDEBUG(698, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy691; + if (yych == 'L') goto yy699; if (yych != 'l') goto yy186; -yy691: - YYDEBUG(691, *YYCURSOR); +yy699: + YYDEBUG(699, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(692, *YYCURSOR); + YYDEBUG(700, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1284 "Zend/zend_language_scanner.l" { return T_FINAL; } -#line 6490 "Zend/zend_language_scanner.c" -yy693: - YYDEBUG(693, *YYCURSOR); +#line 6548 "Zend/zend_language_scanner.c" +yy701: + YYDEBUG(701, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'F') { - if (yych == 'C') goto yy699; + if (yych == 'C') goto yy707; if (yych <= 'E') goto yy186; - goto yy700; + goto yy708; } else { if (yych <= 'c') { if (yych <= 'b') goto yy186; - goto yy699; + goto yy707; } else { - if (yych == 'f') goto yy700; + if (yych == 'f') goto yy708; goto yy186; } } -yy694: - YYDEBUG(694, *YYCURSOR); +yy702: + YYDEBUG(702, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy697; - if (yych == 'e') goto yy697; + if (yych == 'E') goto yy705; + if (yych == 'e') goto yy705; goto yy186; -yy695: - YYDEBUG(695, *YYCURSOR); +yy703: + YYDEBUG(703, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(696, *YYCURSOR); + YYDEBUG(704, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1058 "Zend/zend_language_scanner.l" { return T_DO; } -#line 6525 "Zend/zend_language_scanner.c" -yy697: - YYDEBUG(697, *YYCURSOR); +#line 6583 "Zend/zend_language_scanner.c" +yy705: + YYDEBUG(705, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(698, *YYCURSOR); + YYDEBUG(706, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1006 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6538 "Zend/zend_language_scanner.c" -yy699: - YYDEBUG(699, *YYCURSOR); +#line 6596 "Zend/zend_language_scanner.c" +yy707: + YYDEBUG(707, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy706; - if (yych == 'l') goto yy706; + if (yych == 'L') goto yy714; + if (yych == 'l') goto yy714; goto yy186; -yy700: - YYDEBUG(700, *YYCURSOR); +yy708: + YYDEBUG(708, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy701; + if (yych == 'A') goto yy709; if (yych != 'a') goto yy186; -yy701: - YYDEBUG(701, *YYCURSOR); +yy709: + YYDEBUG(709, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy702; + if (yych == 'U') goto yy710; if (yych != 'u') goto yy186; -yy702: - YYDEBUG(702, *YYCURSOR); +yy710: + YYDEBUG(710, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy703; + if (yych == 'L') goto yy711; if (yych != 'l') goto yy186; -yy703: - YYDEBUG(703, *YYCURSOR); +yy711: + YYDEBUG(711, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy704; + if (yych == 'T') goto yy712; if (yych != 't') goto yy186; -yy704: - YYDEBUG(704, *YYCURSOR); +yy712: + YYDEBUG(712, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(705, *YYCURSOR); + YYDEBUG(713, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1106 "Zend/zend_language_scanner.l" { return T_DEFAULT; } -#line 6577 "Zend/zend_language_scanner.c" -yy706: - YYDEBUG(706, *YYCURSOR); +#line 6635 "Zend/zend_language_scanner.c" +yy714: + YYDEBUG(714, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy707; + if (yych == 'A') goto yy715; if (yych != 'a') goto yy186; -yy707: - YYDEBUG(707, *YYCURSOR); +yy715: + YYDEBUG(715, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy708; + if (yych == 'R') goto yy716; if (yych != 'r') goto yy186; -yy708: - YYDEBUG(708, *YYCURSOR); +yy716: + YYDEBUG(716, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy709; + if (yych == 'E') goto yy717; if (yych != 'e') goto yy186; -yy709: - YYDEBUG(709, *YYCURSOR); +yy717: + YYDEBUG(717, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(710, *YYCURSOR); + YYDEBUG(718, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1078 "Zend/zend_language_scanner.l" { return T_DECLARE; } -#line 6605 "Zend/zend_language_scanner.c" -yy711: - YYDEBUG(711, *YYCURSOR); +#line 6663 "Zend/zend_language_scanner.c" +yy719: + YYDEBUG(719, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy773; - if (yych == 'h') goto yy773; + if (yych == 'H') goto yy781; + if (yych == 'h') goto yy781; goto yy186; -yy712: - YYDEBUG(712, *YYCURSOR); +yy720: + YYDEBUG(720, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy767; - if (yych == 's') goto yy767; + if (yych == 'S') goto yy775; + if (yych == 's') goto yy775; goto yy186; -yy713: - YYDEBUG(713, *YYCURSOR); +yy721: + YYDEBUG(721, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy763; - if (yych == 'p') goto yy763; + if (yych == 'P') goto yy771; + if (yych == 'p') goto yy771; goto yy186; -yy714: - YYDEBUG(714, *YYCURSOR); +yy722: + YYDEBUG(722, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy729; - if (yych == 'd') goto yy729; + if (yych == 'D') goto yy737; + if (yych == 'd') goto yy737; goto yy186; -yy715: - YYDEBUG(715, *YYCURSOR); +yy723: + YYDEBUG(723, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy726; - if (yych == 'a') goto yy726; + if (yych == 'A') goto yy734; + if (yych == 'a') goto yy734; goto yy186; -yy716: - YYDEBUG(716, *YYCURSOR); +yy724: + YYDEBUG(724, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'I') goto yy717; + if (yych == 'I') goto yy725; if (yych <= 'S') goto yy186; - goto yy718; + goto yy726; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; } else { - if (yych == 't') goto yy718; + if (yych == 't') goto yy726; goto yy186; } } -yy717: - YYDEBUG(717, *YYCURSOR); +yy725: + YYDEBUG(725, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy724; - if (yych == 't') goto yy724; + if (yych == 'T') goto yy732; + if (yych == 't') goto yy732; goto yy186; -yy718: - YYDEBUG(718, *YYCURSOR); +yy726: + YYDEBUG(726, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy719; + if (yych == 'E') goto yy727; if (yych != 'e') goto yy186; -yy719: - YYDEBUG(719, *YYCURSOR); +yy727: + YYDEBUG(727, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy720; + if (yych == 'N') goto yy728; if (yych != 'n') goto yy186; -yy720: - YYDEBUG(720, *YYCURSOR); +yy728: + YYDEBUG(728, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy721; + if (yych == 'D') goto yy729; if (yych != 'd') goto yy186; -yy721: - YYDEBUG(721, *YYCURSOR); +yy729: + YYDEBUG(729, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy722; + if (yych == 'S') goto yy730; if (yych != 's') goto yy186; -yy722: - YYDEBUG(722, *YYCURSOR); +yy730: + YYDEBUG(730, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(723, *YYCURSOR); + YYDEBUG(731, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1142 "Zend/zend_language_scanner.l" { return T_EXTENDS; } -#line 6689 "Zend/zend_language_scanner.c" -yy724: - YYDEBUG(724, *YYCURSOR); +#line 6747 "Zend/zend_language_scanner.c" +yy732: + YYDEBUG(732, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(725, *YYCURSOR); + YYDEBUG(733, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1002 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6702 "Zend/zend_language_scanner.c" -yy726: - YYDEBUG(726, *YYCURSOR); +#line 6760 "Zend/zend_language_scanner.c" +yy734: + YYDEBUG(734, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy727; + if (yych == 'L') goto yy735; if (yych != 'l') goto yy186; -yy727: - YYDEBUG(727, *YYCURSOR); +yy735: + YYDEBUG(735, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(728, *YYCURSOR); + YYDEBUG(736, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1228 "Zend/zend_language_scanner.l" { return T_EVAL; } -#line 6720 "Zend/zend_language_scanner.c" -yy729: - YYDEBUG(729, *YYCURSOR); +#line 6778 "Zend/zend_language_scanner.c" +yy737: + YYDEBUG(737, *YYCURSOR); yych = *++YYCURSOR; YYDEBUG(-1, yych); switch (yych) { case 'D': - case 'd': goto yy730; + case 'd': goto yy738; case 'F': - case 'f': goto yy731; + case 'f': goto yy739; case 'I': - case 'i': goto yy732; + case 'i': goto yy740; case 'S': - case 's': goto yy733; + case 's': goto yy741; case 'W': - case 'w': goto yy734; + case 'w': goto yy742; default: goto yy186; } -yy730: - YYDEBUG(730, *YYCURSOR); +yy738: + YYDEBUG(738, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy756; - if (yych == 'e') goto yy756; + if (yych == 'E') goto yy764; + if (yych == 'e') goto yy764; goto yy186; -yy731: - YYDEBUG(731, *YYCURSOR); +yy739: + YYDEBUG(739, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy748; - if (yych == 'o') goto yy748; + if (yych == 'O') goto yy756; + if (yych == 'o') goto yy756; goto yy186; -yy732: - YYDEBUG(732, *YYCURSOR); +yy740: + YYDEBUG(740, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy746; - if (yych == 'f') goto yy746; + if (yych == 'F') goto yy754; + if (yych == 'f') goto yy754; goto yy186; -yy733: - YYDEBUG(733, *YYCURSOR); +yy741: + YYDEBUG(741, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy740; - if (yych == 'w') goto yy740; + if (yych == 'W') goto yy748; + if (yych == 'w') goto yy748; goto yy186; -yy734: - YYDEBUG(734, *YYCURSOR); +yy742: + YYDEBUG(742, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy735; + if (yych == 'H') goto yy743; if (yych != 'h') goto yy186; -yy735: - YYDEBUG(735, *YYCURSOR); +yy743: + YYDEBUG(743, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy736; + if (yych == 'I') goto yy744; if (yych != 'i') goto yy186; -yy736: - YYDEBUG(736, *YYCURSOR); +yy744: + YYDEBUG(744, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy737; + if (yych == 'L') goto yy745; if (yych != 'l') goto yy186; -yy737: - YYDEBUG(737, *YYCURSOR); +yy745: + YYDEBUG(745, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy738; + if (yych == 'E') goto yy746; if (yych != 'e') goto yy186; -yy738: - YYDEBUG(738, *YYCURSOR); +yy746: + YYDEBUG(746, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(739, *YYCURSOR); + YYDEBUG(747, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1054 "Zend/zend_language_scanner.l" { return T_ENDWHILE; } -#line 6794 "Zend/zend_language_scanner.c" -yy740: - YYDEBUG(740, *YYCURSOR); +#line 6852 "Zend/zend_language_scanner.c" +yy748: + YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy741; + if (yych == 'I') goto yy749; if (yych != 'i') goto yy186; -yy741: - YYDEBUG(741, *YYCURSOR); +yy749: + YYDEBUG(749, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy742; + if (yych == 'T') goto yy750; if (yych != 't') goto yy186; -yy742: - YYDEBUG(742, *YYCURSOR); +yy750: + YYDEBUG(750, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy743; + if (yych == 'C') goto yy751; if (yych != 'c') goto yy186; -yy743: - YYDEBUG(743, *YYCURSOR); +yy751: + YYDEBUG(751, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy744; + if (yych == 'H') goto yy752; if (yych != 'h') goto yy186; -yy744: - YYDEBUG(744, *YYCURSOR); +yy752: + YYDEBUG(752, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(745, *YYCURSOR); + YYDEBUG(753, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1098 "Zend/zend_language_scanner.l" { return T_ENDSWITCH; } -#line 6827 "Zend/zend_language_scanner.c" -yy746: - YYDEBUG(746, *YYCURSOR); +#line 6885 "Zend/zend_language_scanner.c" +yy754: + YYDEBUG(754, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(747, *YYCURSOR); + YYDEBUG(755, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1042 "Zend/zend_language_scanner.l" { return T_ENDIF; } -#line 6840 "Zend/zend_language_scanner.c" -yy748: - YYDEBUG(748, *YYCURSOR); +#line 6898 "Zend/zend_language_scanner.c" +yy756: + YYDEBUG(756, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy749; + if (yych == 'R') goto yy757; if (yych != 'r') goto yy186; -yy749: - YYDEBUG(749, *YYCURSOR); +yy757: + YYDEBUG(757, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy750; + if (yych <= '/') goto yy758; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy751; + if (yych == 'E') goto yy759; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy751; + if (yych <= 'e') goto yy759; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy750: - YYDEBUG(750, *YYCURSOR); +yy758: + YYDEBUG(758, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1066 "Zend/zend_language_scanner.l" { return T_ENDFOR; } -#line 6873 "Zend/zend_language_scanner.c" -yy751: - YYDEBUG(751, *YYCURSOR); +#line 6931 "Zend/zend_language_scanner.c" +yy759: + YYDEBUG(759, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy752; + if (yych == 'A') goto yy760; if (yych != 'a') goto yy186; -yy752: - YYDEBUG(752, *YYCURSOR); +yy760: + YYDEBUG(760, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy753; + if (yych == 'C') goto yy761; if (yych != 'c') goto yy186; -yy753: - YYDEBUG(753, *YYCURSOR); +yy761: + YYDEBUG(761, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy754; + if (yych == 'H') goto yy762; if (yych != 'h') goto yy186; -yy754: - YYDEBUG(754, *YYCURSOR); +yy762: + YYDEBUG(762, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(755, *YYCURSOR); + YYDEBUG(763, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1074 "Zend/zend_language_scanner.l" { return T_ENDFOREACH; } -#line 6901 "Zend/zend_language_scanner.c" -yy756: - YYDEBUG(756, *YYCURSOR); +#line 6959 "Zend/zend_language_scanner.c" +yy764: + YYDEBUG(764, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy757; + if (yych == 'C') goto yy765; if (yych != 'c') goto yy186; -yy757: - YYDEBUG(757, *YYCURSOR); +yy765: + YYDEBUG(765, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy758; + if (yych == 'L') goto yy766; if (yych != 'l') goto yy186; -yy758: - YYDEBUG(758, *YYCURSOR); +yy766: + YYDEBUG(766, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy759; + if (yych == 'A') goto yy767; if (yych != 'a') goto yy186; -yy759: - YYDEBUG(759, *YYCURSOR); +yy767: + YYDEBUG(767, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy760; + if (yych == 'R') goto yy768; if (yych != 'r') goto yy186; -yy760: - YYDEBUG(760, *YYCURSOR); +yy768: + YYDEBUG(768, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy761; + if (yych == 'E') goto yy769; if (yych != 'e') goto yy186; -yy761: - YYDEBUG(761, *YYCURSOR); +yy769: + YYDEBUG(769, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(762, *YYCURSOR); + YYDEBUG(770, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1082 "Zend/zend_language_scanner.l" { return T_ENDDECLARE; } -#line 6939 "Zend/zend_language_scanner.c" -yy763: - YYDEBUG(763, *YYCURSOR); +#line 6997 "Zend/zend_language_scanner.c" +yy771: + YYDEBUG(771, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy764; + if (yych == 'T') goto yy772; if (yych != 't') goto yy186; -yy764: - YYDEBUG(764, *YYCURSOR); +yy772: + YYDEBUG(772, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy765; + if (yych == 'Y') goto yy773; if (yych != 'y') goto yy186; -yy765: - YYDEBUG(765, *YYCURSOR); +yy773: + YYDEBUG(773, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(766, *YYCURSOR); + YYDEBUG(774, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1268 "Zend/zend_language_scanner.l" { return T_EMPTY; } -#line 6962 "Zend/zend_language_scanner.c" -yy767: - YYDEBUG(767, *YYCURSOR); +#line 7020 "Zend/zend_language_scanner.c" +yy775: + YYDEBUG(775, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy768; + if (yych == 'E') goto yy776; if (yych != 'e') goto yy186; -yy768: - YYDEBUG(768, *YYCURSOR); +yy776: + YYDEBUG(776, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy769; + if (yych <= '/') goto yy777; if (yych <= '9') goto yy185; } else { - if (yych == 'I') goto yy770; + if (yych == 'I') goto yy778; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'h') { if (yych != '`') goto yy185; } else { - if (yych <= 'i') goto yy770; + if (yych <= 'i') goto yy778; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy769: - YYDEBUG(769, *YYCURSOR); +yy777: + YYDEBUG(777, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1046 "Zend/zend_language_scanner.l" { return T_ELSE; } -#line 6995 "Zend/zend_language_scanner.c" -yy770: - YYDEBUG(770, *YYCURSOR); +#line 7053 "Zend/zend_language_scanner.c" +yy778: + YYDEBUG(778, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy771; + if (yych == 'F') goto yy779; if (yych != 'f') goto yy186; -yy771: - YYDEBUG(771, *YYCURSOR); +yy779: + YYDEBUG(779, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(772, *YYCURSOR); + YYDEBUG(780, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1038 "Zend/zend_language_scanner.l" { return T_ELSEIF; } -#line 7013 "Zend/zend_language_scanner.c" -yy773: - YYDEBUG(773, *YYCURSOR); +#line 7071 "Zend/zend_language_scanner.c" +yy781: + YYDEBUG(781, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy774; + if (yych == 'O') goto yy782; if (yych != 'o') goto yy186; -yy774: - YYDEBUG(774, *YYCURSOR); +yy782: + YYDEBUG(782, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(775, *YYCURSOR); + YYDEBUG(783, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1122 "Zend/zend_language_scanner.l" { return T_ECHO; } -#line 7031 "Zend/zend_language_scanner.c" +#line 7089 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7066,39 +7124,39 @@ int lex_scan(zval *zendlval TSRMLS_DC) 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, }; - YYDEBUG(776, *YYCURSOR); + YYDEBUG(784, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '-') { if (yych <= '\r') { - if (yych <= 0x08) goto yy784; - if (yych <= '\n') goto yy778; - if (yych <= '\f') goto yy784; + if (yych <= 0x08) goto yy792; + if (yych <= '\n') goto yy786; + if (yych <= '\f') goto yy792; } else { - if (yych == ' ') goto yy778; - if (yych <= ',') goto yy784; - goto yy780; + if (yych == ' ') goto yy786; + if (yych <= ',') goto yy792; + goto yy788; } } else { if (yych <= '_') { - if (yych <= '@') goto yy784; - if (yych <= 'Z') goto yy782; - if (yych <= '^') goto yy784; - goto yy782; + if (yych <= '@') goto yy792; + if (yych <= 'Z') goto yy790; + if (yych <= '^') goto yy792; + goto yy790; } else { - if (yych <= '`') goto yy784; - if (yych <= 'z') goto yy782; - if (yych <= '~') goto yy784; - goto yy782; + if (yych <= '`') goto yy792; + if (yych <= 'z') goto yy790; + if (yych <= '~') goto yy792; + goto yy790; } } -yy778: - YYDEBUG(778, *YYCURSOR); +yy786: + YYDEBUG(786, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy790; -yy779: - YYDEBUG(779, *YYCURSOR); + goto yy798; +yy787: + YYDEBUG(787, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1155 "Zend/zend_language_scanner.l" { @@ -7108,13 +7166,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7112 "Zend/zend_language_scanner.c" -yy780: - YYDEBUG(780, *YYCURSOR); +#line 7170 "Zend/zend_language_scanner.c" +yy788: + YYDEBUG(788, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '>') goto yy787; -yy781: - YYDEBUG(781, *YYCURSOR); + if ((yych = *YYCURSOR) == '>') goto yy795; +yy789: + YYDEBUG(789, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1174 "Zend/zend_language_scanner.l" { @@ -7122,14 +7180,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_pop_state(TSRMLS_C); goto restart; } -#line 7126 "Zend/zend_language_scanner.c" -yy782: - YYDEBUG(782, *YYCURSOR); +#line 7184 "Zend/zend_language_scanner.c" +yy790: + YYDEBUG(790, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy786; -yy783: - YYDEBUG(783, *YYCURSOR); + goto yy794; +yy791: + YYDEBUG(791, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1167 "Zend/zend_language_scanner.l" { @@ -7138,43 +7196,43 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_STRING; } -#line 7142 "Zend/zend_language_scanner.c" -yy784: - YYDEBUG(784, *YYCURSOR); +#line 7200 "Zend/zend_language_scanner.c" +yy792: + YYDEBUG(792, *YYCURSOR); yych = *++YYCURSOR; - goto yy781; -yy785: - YYDEBUG(785, *YYCURSOR); + goto yy789; +yy793: + YYDEBUG(793, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy786: - YYDEBUG(786, *YYCURSOR); +yy794: + YYDEBUG(794, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy785; + goto yy793; } - goto yy783; -yy787: - YYDEBUG(787, *YYCURSOR); + goto yy791; +yy795: + YYDEBUG(795, *YYCURSOR); ++YYCURSOR; - YYDEBUG(788, *YYCURSOR); + YYDEBUG(796, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1163 "Zend/zend_language_scanner.l" { return T_OBJECT_OPERATOR; } -#line 7167 "Zend/zend_language_scanner.c" -yy789: - YYDEBUG(789, *YYCURSOR); +#line 7225 "Zend/zend_language_scanner.c" +yy797: + YYDEBUG(797, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy790: - YYDEBUG(790, *YYCURSOR); +yy798: + YYDEBUG(798, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy789; + goto yy797; } - goto yy779; + goto yy787; } /* *********************************** */ yyc_ST_LOOKING_FOR_VARNAME: @@ -7213,25 +7271,25 @@ int lex_scan(zval *zendlval TSRMLS_DC) 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; - YYDEBUG(791, *YYCURSOR); + YYDEBUG(799, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '_') { - if (yych <= '@') goto yy795; - if (yych <= 'Z') goto yy793; - if (yych <= '^') goto yy795; + if (yych <= '@') goto yy803; + if (yych <= 'Z') goto yy801; + if (yych <= '^') goto yy803; } else { - if (yych <= '`') goto yy795; - if (yych <= 'z') goto yy793; - if (yych <= '~') goto yy795; + if (yych <= '`') goto yy803; + if (yych <= 'z') goto yy801; + if (yych <= '~') goto yy803; } -yy793: - YYDEBUG(793, *YYCURSOR); +yy801: + YYDEBUG(801, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy798; -yy794: - YYDEBUG(794, *YYCURSOR); + goto yy806; +yy802: + YYDEBUG(802, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1446 "Zend/zend_language_scanner.l" { @@ -7241,11 +7299,11 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7245 "Zend/zend_language_scanner.c" -yy795: - YYDEBUG(795, *YYCURSOR); +#line 7303 "Zend/zend_language_scanner.c" +yy803: + YYDEBUG(803, *YYCURSOR); ++YYCURSOR; - YYDEBUG(796, *YYCURSOR); + YYDEBUG(804, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1455 "Zend/zend_language_scanner.l" { @@ -7254,29 +7312,29 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7258 "Zend/zend_language_scanner.c" -yy797: - YYDEBUG(797, *YYCURSOR); +#line 7316 "Zend/zend_language_scanner.c" +yy805: + YYDEBUG(805, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy798: - YYDEBUG(798, *YYCURSOR); +yy806: + YYDEBUG(806, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy797; + goto yy805; } - goto yy794; + goto yy802; } /* *********************************** */ yyc_ST_NOWDOC: - YYDEBUG(799, *YYCURSOR); + YYDEBUG(807, *YYCURSOR); YYFILL(1); yych = *YYCURSOR; - YYDEBUG(801, *YYCURSOR); + YYDEBUG(809, *YYCURSOR); ++YYCURSOR; - YYDEBUG(802, *YYCURSOR); + YYDEBUG(810, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2298 "Zend/zend_language_scanner.l" +#line 2318 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7331,7 +7389,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7335 "Zend/zend_language_scanner.c" +#line 7393 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7369,74 +7427,74 @@ int lex_scan(zval *zendlval TSRMLS_DC) 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, }; - YYDEBUG(803, *YYCURSOR); + YYDEBUG(811, *YYCURSOR); YYFILL(3); yych = *YYCURSOR; if (yych <= '/') { if (yych <= ' ') { if (yych <= '\f') { - if (yych <= 0x08) goto yy817; - if (yych <= '\n') goto yy813; - goto yy817; + if (yych <= 0x08) goto yy825; + if (yych <= '\n') goto yy821; + goto yy825; } else { - if (yych <= '\r') goto yy813; - if (yych <= 0x1F) goto yy817; - goto yy813; + if (yych <= '\r') goto yy821; + if (yych <= 0x1F) goto yy825; + goto yy821; } } else { if (yych <= '$') { - if (yych <= '"') goto yy812; - if (yych <= '#') goto yy813; - goto yy808; + if (yych <= '"') goto yy820; + if (yych <= '#') goto yy821; + goto yy816; } else { - if (yych == '\'') goto yy813; - goto yy812; + if (yych == '\'') goto yy821; + goto yy820; } } } else { if (yych <= '\\') { if (yych <= '@') { - if (yych <= '0') goto yy805; - if (yych <= '9') goto yy807; - goto yy812; + if (yych <= '0') goto yy813; + if (yych <= '9') goto yy815; + goto yy820; } else { - if (yych <= 'Z') goto yy815; - if (yych <= '[') goto yy812; - goto yy813; + if (yych <= 'Z') goto yy823; + if (yych <= '[') goto yy820; + goto yy821; } } else { if (yych <= '_') { - if (yych <= ']') goto yy810; - if (yych <= '^') goto yy812; - goto yy815; + if (yych <= ']') goto yy818; + if (yych <= '^') goto yy820; + goto yy823; } else { - if (yych <= '`') goto yy812; - if (yych <= 'z') goto yy815; - if (yych <= '~') goto yy812; - goto yy815; + if (yych <= '`') goto yy820; + if (yych <= 'z') goto yy823; + if (yych <= '~') goto yy820; + goto yy823; } } } -yy805: - YYDEBUG(805, *YYCURSOR); +yy813: + YYDEBUG(813, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 'W') { if (yych <= '9') { - if (yych >= '0') goto yy829; + if (yych >= '0') goto yy837; } else { - if (yych == 'B') goto yy826; + if (yych == 'B') goto yy834; } } else { if (yych <= 'b') { - if (yych <= 'X') goto yy828; - if (yych >= 'b') goto yy826; + if (yych <= 'X') goto yy836; + if (yych >= 'b') goto yy834; } else { - if (yych == 'x') goto yy828; + if (yych == 'x') goto yy836; } } -yy806: - YYDEBUG(806, *YYCURSOR); +yy814: + YYDEBUG(814, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1525 "Zend/zend_language_scanner.l" { /* Offset could be treated as a long */ @@ -7450,81 +7508,81 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7454 "Zend/zend_language_scanner.c" -yy807: - YYDEBUG(807, *YYCURSOR); +#line 7512 "Zend/zend_language_scanner.c" +yy815: + YYDEBUG(815, *YYCURSOR); yych = *++YYCURSOR; - goto yy825; -yy808: - YYDEBUG(808, *YYCURSOR); + goto yy833; +yy816: + YYDEBUG(816, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '_') { - if (yych <= '@') goto yy809; - if (yych <= 'Z') goto yy821; - if (yych >= '_') goto yy821; + if (yych <= '@') goto yy817; + if (yych <= 'Z') goto yy829; + if (yych >= '_') goto yy829; } else { - if (yych <= '`') goto yy809; - if (yych <= 'z') goto yy821; - if (yych >= 0x7F) goto yy821; + if (yych <= '`') goto yy817; + if (yych <= 'z') goto yy829; + if (yych >= 0x7F) goto yy829; } -yy809: - YYDEBUG(809, *YYCURSOR); +yy817: + YYDEBUG(817, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1826 "Zend/zend_language_scanner.l" +#line 1846 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7479 "Zend/zend_language_scanner.c" -yy810: - YYDEBUG(810, *YYCURSOR); +#line 7537 "Zend/zend_language_scanner.c" +yy818: + YYDEBUG(818, *YYCURSOR); ++YYCURSOR; - YYDEBUG(811, *YYCURSOR); + YYDEBUG(819, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1821 "Zend/zend_language_scanner.l" +#line 1841 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7490 "Zend/zend_language_scanner.c" -yy812: - YYDEBUG(812, *YYCURSOR); +#line 7548 "Zend/zend_language_scanner.c" +yy820: + YYDEBUG(820, *YYCURSOR); yych = *++YYCURSOR; - goto yy809; -yy813: - YYDEBUG(813, *YYCURSOR); + goto yy817; +yy821: + YYDEBUG(821, *YYCURSOR); ++YYCURSOR; - YYDEBUG(814, *YYCURSOR); + YYDEBUG(822, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1831 "Zend/zend_language_scanner.l" +#line 1851 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7507 "Zend/zend_language_scanner.c" -yy815: - YYDEBUG(815, *YYCURSOR); +#line 7565 "Zend/zend_language_scanner.c" +yy823: + YYDEBUG(823, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy820; -yy816: - YYDEBUG(816, *YYCURSOR); + goto yy828; +yy824: + YYDEBUG(824, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1838 "Zend/zend_language_scanner.l" +#line 1858 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7522 "Zend/zend_language_scanner.c" -yy817: - YYDEBUG(817, *YYCURSOR); +#line 7580 "Zend/zend_language_scanner.c" +yy825: + YYDEBUG(825, *YYCURSOR); ++YYCURSOR; - YYDEBUG(818, *YYCURSOR); + YYDEBUG(826, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2354 "Zend/zend_language_scanner.l" +#line 2374 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7533,87 +7591,87 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7537 "Zend/zend_language_scanner.c" -yy819: - YYDEBUG(819, *YYCURSOR); +#line 7595 "Zend/zend_language_scanner.c" +yy827: + YYDEBUG(827, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy820: - YYDEBUG(820, *YYCURSOR); +yy828: + YYDEBUG(828, *YYCURSOR); if (yybm[0+yych] & 16) { - goto yy819; + goto yy827; } - goto yy816; -yy821: - YYDEBUG(821, *YYCURSOR); + goto yy824; +yy829: + YYDEBUG(829, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(822, *YYCURSOR); + YYDEBUG(830, *YYCURSOR); if (yych <= '^') { if (yych <= '9') { - if (yych >= '0') goto yy821; + if (yych >= '0') goto yy829; } else { - if (yych <= '@') goto yy823; - if (yych <= 'Z') goto yy821; + if (yych <= '@') goto yy831; + if (yych <= 'Z') goto yy829; } } else { if (yych <= '`') { - if (yych <= '_') goto yy821; + if (yych <= '_') goto yy829; } else { - if (yych <= 'z') goto yy821; - if (yych >= 0x7F) goto yy821; + if (yych <= 'z') goto yy829; + if (yych >= 0x7F) goto yy829; } } -yy823: - YYDEBUG(823, *YYCURSOR); +yy831: + YYDEBUG(831, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1815 "Zend/zend_language_scanner.l" +#line 1835 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7579 "Zend/zend_language_scanner.c" -yy824: - YYDEBUG(824, *YYCURSOR); +#line 7637 "Zend/zend_language_scanner.c" +yy832: + YYDEBUG(832, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy825: - YYDEBUG(825, *YYCURSOR); +yy833: + YYDEBUG(833, *YYCURSOR); if (yybm[0+yych] & 32) { - goto yy824; + goto yy832; } - goto yy806; -yy826: - YYDEBUG(826, *YYCURSOR); + goto yy814; +yy834: + YYDEBUG(834, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 128) { - goto yy834; + goto yy842; } -yy827: - YYDEBUG(827, *YYCURSOR); +yy835: + YYDEBUG(835, *YYCURSOR); YYCURSOR = YYMARKER; - goto yy806; -yy828: - YYDEBUG(828, *YYCURSOR); + goto yy814; +yy836: + YYDEBUG(836, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 64) { - goto yy832; + goto yy840; } - goto yy827; -yy829: - YYDEBUG(829, *YYCURSOR); + goto yy835; +yy837: + YYDEBUG(837, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(830, *YYCURSOR); - if (yych <= '/') goto yy831; - if (yych <= '9') goto yy829; -yy831: - YYDEBUG(831, *YYCURSOR); + YYDEBUG(838, *YYCURSOR); + if (yych <= '/') goto yy839; + if (yych <= '9') goto yy837; +yy839: + YYDEBUG(839, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1537 "Zend/zend_language_scanner.l" { /* Offset must be treated as a string */ @@ -7622,29 +7680,29 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7626 "Zend/zend_language_scanner.c" -yy832: - YYDEBUG(832, *YYCURSOR); +#line 7684 "Zend/zend_language_scanner.c" +yy840: + YYDEBUG(840, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(833, *YYCURSOR); + YYDEBUG(841, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy832; + goto yy840; } - goto yy831; -yy834: - YYDEBUG(834, *YYCURSOR); + goto yy839; +yy842: + YYDEBUG(842, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(835, *YYCURSOR); + YYDEBUG(843, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy834; + goto yy842; } - goto yy831; + goto yy839; } } -#line 2363 "Zend/zend_language_scanner.l" +#line 2383 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 2af529d0bcbb0..1a22f0b7e19c2 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1563,6 +1563,26 @@ NEWLINE ("\r"|"\n"|"\r\n") return T_CLASS_C; } +"__TRAIT__" { + char *trait_name = NULL; + + if (CG(active_class_entry) + && (ZEND_ACC_TRAIT == + (CG(active_class_entry)->ce_flags & ZEND_ACC_TRAIT))) { + trait_name = CG(active_class_entry)->name; + } + + if (!trait_name) { + trait_name = ""; + } + + zendlval->value.str.len = strlen(trait_name); + zendlval->value.str.val = estrndup(trait_name, zendlval->value.str.len); + zendlval->type = IS_STRING; + + return T_TRAIT_C; +} + "__FUNCTION__" { char *func_name = NULL; diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index a6101740e7e1b..15cc351d248fb 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Wed Jul 27 02:06:14 2011 */ +/* Generated by re2c 0.13.5 on Sun Jul 31 17:59:24 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/ext/tokenizer/tests/token_get_all_variation12.phpt b/ext/tokenizer/tests/token_get_all_variation12.phpt index 0968649ced3a1..368fb0867cb5f 100644 --- a/ext/tokenizer/tests/token_get_all_variation12.phpt +++ b/ext/tokenizer/tests/token_get_all_variation12.phpt @@ -5,17 +5,18 @@ Test token_get_all() function : usage variations - with predefined language cons --FILE-- "; var_dump( token_get_all($source)); -// parsing __CLASS__ and __FUNCTION__ tokens -echo "-- with CLASS and FUNCTION --\n"; +// parsing __CLASS__, __TRAIT__ and __FUNCTION__ tokens +echo "-- with CLASS, TRAIT and FUNCTION --\n"; $source = ' array(3) { [0]=> @@ -263,14 +265,14 @@ array(30) { string(3) " " [2]=> - int(4) + int(%d) } [12]=> array(3) { [0]=> int(%d) [1]=> - string(8) "function" + string(4) "echo" [2]=> int(5) } @@ -279,7 +281,7 @@ array(30) { [0]=> int(%d) [1]=> - string(1) " " + string(2) " " [2]=> int(5) } @@ -288,15 +290,13 @@ array(30) { [0]=> int(%d) [1]=> - string(10) "myFunction" + string(9) "__TRAIT__" [2]=> int(5) } [15]=> - string(1) "(" + string(1) ";" [16]=> - string(1) ")" - [17]=> array(3) { [0]=> int(%d) @@ -306,58 +306,99 @@ array(30) { [2]=> int(5) } + [17]=> + array(3) { + [0]=> + int(%d) + [1]=> + string(8) "function" + [2]=> + int(6) + } [18]=> - string(1) "{" + array(3) { + [0]=> + int(%d) + [1]=> + string(1) " " + [2]=> + int(6) + } [19]=> array(3) { [0]=> int(%d) [1]=> - string(2) " " + string(10) "myFunction" [2]=> int(6) } [20]=> + string(1) "(" + [21]=> + string(1) ")" + [22]=> array(3) { [0]=> int(%d) [1]=> - string(4) "echo" + string(3) " + " [2]=> int(6) } - [21]=> + [23]=> + string(1) "{" + [24]=> array(3) { [0]=> int(%d) [1]=> string(2) " " [2]=> - int(6) + int(7) } - [22]=> + [25]=> + array(3) { + [0]=> + int(%d) + [1]=> + string(4) "echo" + [2]=> + int(7) + } + [26]=> + array(3) { + [0]=> + int(%d) + [1]=> + string(2) " " + [2]=> + int(7) + } + [27]=> array(3) { [0]=> int(%d) [1]=> string(12) "__FUNCTION__" [2]=> - int(6) + int(7) } - [23]=> + [28]=> string(1) ";" - [24]=> + [29]=> array(3) { [0]=> int(%d) [1]=> string(1) " " [2]=> - int(6) + int(7) } - [25]=> + [30]=> string(1) "}" - [26]=> + [31]=> array(3) { [0]=> int(%d) @@ -365,11 +406,11 @@ array(30) { string(1) " " [2]=> - int(6) + int(7) } - [27]=> + [32]=> string(1) "}" - [28]=> + [33]=> array(3) { [0]=> int(%d) @@ -377,16 +418,16 @@ array(30) { string(1) " " [2]=> - int(7) + int(8) } - [29]=> + [34]=> array(3) { [0]=> int(%d) [1]=> string(2) "?>" [2]=> - int(8) + int(9) } } -- with LINE and METHOD -- From 88f497f27d4432fa0f6b81cbbe61a1cde486aed2 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Sun, 31 Jul 2011 18:18:56 +0000 Subject: [PATCH 0427/2394] Fixed Bug #55214 use of __CLASS__ within trait returns trait name not class name [TRAITS] [DOC] --- Zend/tests/traits/bug55214.phpt | 48 +++++ Zend/zend_compile.c | 97 +++++++--- Zend/zend_language_scanner.c | 311 ++++++++++++++++-------------- Zend/zend_language_scanner.l | 31 ++- Zend/zend_language_scanner_defs.h | 2 +- 5 files changed, 296 insertions(+), 193 deletions(-) create mode 100644 Zend/tests/traits/bug55214.phpt diff --git a/Zend/tests/traits/bug55214.phpt b/Zend/tests/traits/bug55214.phpt new file mode 100644 index 0000000000000..9f3cb4f0e405b --- /dev/null +++ b/Zend/tests/traits/bug55214.phpt @@ -0,0 +1,48 @@ +--TEST-- +Bug #55214 (Use of __CLASS__ within trait returns trait name not class name) +--FILE-- +get_class_name_obj(); +var_dump($r); + +$r = UsingIndirect::get_class_name(); +var_dump($r); + +$o = new UsingIndirect(); +$r = $o->get_class_name_obj(); +var_dump($r); + + +?> +--EXPECT-- +string(9) "SomeClass" +string(9) "SomeClass" +string(13) "UsingIndirect" +string(13) "UsingIndirect" diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index c6c096c810e44..96fd936ace24b 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3480,11 +3480,13 @@ static int zend_traits_merge_functions(zend_function *fn TSRMLS_DC, int num_args /* {{{ Originates from php_runkit_function_copy_ctor Duplicate structures in an op_array where necessary to make an outright duplicate */ -static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRMLS_DC) +static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry *target_ce, char *newname TSRMLS_DC) { zend_literal *literals_copy; zend_compiled_variable *dupvars; zend_op *opcode_copy; + zval class_name_zv; + int class_name_literal; int i; if (fe->op_array.static_variables) { @@ -3496,24 +3498,34 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM fe->op_array.static_variables = tmpHash; } + + /* TODO: Verify that this size is a global thing, do not see why but is used + like this elsewhere */ + literals_copy = (zend_literal*)emalloc(CG(context).literals_size * sizeof(zend_literal)); + + for (i = 0; i < fe->op_array.last_literal; i++) { + literals_copy[i] = fe->op_array.literals[i]; + zval_copy_ctor(&literals_copy[i].constant); + } + fe->op_array.literals = literals_copy; + fe->op_array.refcount = emalloc(sizeof(zend_uint)); *(fe->op_array.refcount) = 1; - if (fe->op_array.vars) { - i = fe->op_array.last_var; - dupvars = safe_emalloc(fe->op_array.last_var, sizeof(zend_compiled_variable), 0); - while (i > 0) { - i--; - dupvars[i].name = estrndup(fe->op_array.vars[i].name, fe->op_array.vars[i].name_len); - dupvars[i].name_len = fe->op_array.vars[i].name_len; - dupvars[i].hash_value = fe->op_array.vars[i].hash_value; - } - fe->op_array.vars = dupvars; - } - else { - fe->op_array.vars = NULL; - } + if (fe->op_array.vars) { + i = fe->op_array.last_var; + dupvars = safe_emalloc(fe->op_array.last_var, sizeof(zend_compiled_variable), 0); + while (i > 0) { + i--; + dupvars[i].name = estrndup(fe->op_array.vars[i].name, fe->op_array.vars[i].name_len); + dupvars[i].name_len = fe->op_array.vars[i].name_len; + dupvars[i].hash_value = fe->op_array.vars[i].hash_value; + } + fe->op_array.vars = dupvars; + } else { + fe->op_array.vars = NULL; + } opcode_copy = safe_emalloc(sizeof(zend_op), fe->op_array.last, 0); for(i = 0; i < fe->op_array.last; i++) { @@ -3523,6 +3535,19 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM opcode_copy[i].op1.jmp_addr < fe->op_array.opcodes + fe->op_array.last) { opcode_copy[i].op1.jmp_addr = opcode_copy + (fe->op_array.opcodes[i].op1.jmp_addr - fe->op_array.opcodes); } + } else { + /* if __CLASS__ i.e. T_CLASS_C was used, we need to fix it up here */ + if (target_ce + /* REM: used a IS_NULL place holder with a special marker LVAL */ + && Z_TYPE_P(opcode_copy[i].op1.zv) == IS_NULL + && Z_LVAL_P(opcode_copy[i].op1.zv) == ZEND_ACC_TRAIT + /* Only on merge into an actual class */ + && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) { + INIT_ZVAL(class_name_zv); + ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 0); + class_name_literal = zend_add_literal(&fe->op_array, &class_name_zv TSRMLS_CC); + opcode_copy[i].op1.zv = &fe->op_array.literals[class_name_literal].constant; + } } if (opcode_copy[i].op2_type != IS_CONST) { @@ -3530,6 +3555,19 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM opcode_copy[i].op2.jmp_addr < fe->op_array.opcodes + fe->op_array.last) { opcode_copy[i].op2.jmp_addr = opcode_copy + (fe->op_array.opcodes[i].op2.jmp_addr - fe->op_array.opcodes); } + } else { + /* if __CLASS__ i.e. T_CLASS_C was used, we need to fix it up here */ + if (target_ce + /* REM: used a IS_NULL place holder with a special marker LVAL */ + && Z_TYPE_P(opcode_copy[i].op2.zv) == IS_NULL + && Z_LVAL_P(opcode_copy[i].op2.zv) == ZEND_ACC_TRAIT + /* Only on merge into an actual class */ + && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) { + INIT_ZVAL(class_name_zv); + ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 0); + class_name_literal = zend_add_literal(&fe->op_array, &class_name_zv TSRMLS_CC); + opcode_copy[i].op2.zv = &fe->op_array.literals[class_name_literal].constant; + } } } fe->op_array.opcodes = opcode_copy; @@ -3557,14 +3595,6 @@ static void zend_traits_duplicate_function(zend_function *fe, char *newname TSRM fe->op_array.brk_cont_array = (zend_brk_cont_element*)estrndup((char*)fe->op_array.brk_cont_array, sizeof(zend_brk_cont_element) * fe->op_array.last_brk_cont); - /* TODO: check whether there is something similar and whether that is ok */ - literals_copy = (zend_literal*)emalloc(fe->op_array.last_literal * sizeof(zend_literal)); - - for (i = 0; i < fe->op_array.last_literal; i++) { - literals_copy[i] = fe->op_array.literals[i]; - zval_copy_ctor(&literals_copy[i].constant); - } - fe->op_array.literals = literals_copy; } /* }}}} */ @@ -3617,7 +3647,7 @@ static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int ce->ce_flags |= ZEND_HAS_STATIC_IN_METHODS; } fn_copy = *fn; - zend_traits_duplicate_function(&fn_copy, estrdup(fn->common.function_name) TSRMLS_CC); + zend_traits_duplicate_function(&fn_copy, ce, estrdup(fn->common.function_name) TSRMLS_CC); if (zend_hash_quick_update(&ce->function_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h, &fn_copy, sizeof(zend_function), (void**)&fn_copy_p)==FAILURE) { zend_error(E_COMPILE_ERROR, "Trait method %s has not been applied, because failure occured during updating class method table", hash_key->arKey); @@ -3639,6 +3669,7 @@ static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { HashTable* target; + zend_class_entry *target_ce; zend_trait_alias** aliases; HashTable* exclude_table; char* lcname; @@ -3646,8 +3677,10 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, zend_function fn_copy; void* dummy; size_t i = 0; - target = va_arg(args, HashTable*); - aliases = va_arg(args, zend_trait_alias**); + + target = va_arg(args, HashTable*); + target_ce = va_arg(args, zend_class_entry*); + aliases = va_arg(args, zend_trait_alias**); exclude_table = va_arg(args, HashTable*); fnname_len = strlen(fn->common.function_name); @@ -3661,7 +3694,7 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, && aliases[i]->trait_method->mname_len == fnname_len && (zend_binary_strcasecmp(aliases[i]->trait_method->method_name, aliases[i]->trait_method->mname_len, fn->common.function_name, fnname_len) == 0)) { fn_copy = *fn; - zend_traits_duplicate_function(&fn_copy, estrndup(aliases[i]->alias, aliases[i]->alias_len) TSRMLS_CC); + zend_traits_duplicate_function(&fn_copy, NULL, estrndup(aliases[i]->alias, aliases[i]->alias_len) TSRMLS_CC); /* if it is 0, no modifieres has been changed */ if (aliases[i]->modifiers) { @@ -3688,7 +3721,7 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, if (exclude_table == NULL || zend_hash_find(exclude_table, lcname, fnname_len, &dummy) == FAILURE) { /* is not in hashtable, thus, function is not to be excluded */ fn_copy = *fn; - zend_traits_duplicate_function(&fn_copy, estrndup(fn->common.function_name, fnname_len) TSRMLS_CC); + zend_traits_duplicate_function(&fn_copy, NULL, estrndup(fn->common.function_name, fnname_len) TSRMLS_CC); /* apply aliases which are not qualified by a class name, or which have not * alias name, just setting visibility */ @@ -3723,9 +3756,9 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, /* }}} */ /* Copies function table entries to target function table with applied aliasing */ -static void zend_traits_copy_trait_function_table(HashTable *target, HashTable *source, zend_trait_alias** aliases, HashTable* exclude_table TSRMLS_DC) /* {{{ */ +static void zend_traits_copy_trait_function_table(HashTable *target, zend_class_entry *target_ce, HashTable *source, zend_trait_alias** aliases, HashTable* exclude_table TSRMLS_DC) /* {{{ */ { - zend_hash_apply_with_arguments(source TSRMLS_CC, (apply_func_args_t)zend_traits_copy_functions, 3, target, aliases, exclude_table); + zend_hash_apply_with_arguments(source TSRMLS_CC, (apply_func_args_t)zend_traits_copy_functions, 4, target, target_ce, aliases, exclude_table); } /* }}} */ @@ -3823,10 +3856,10 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ zend_traits_compile_exclude_table(&exclude_table, ce->trait_precedences, ce->traits[i]); /* copies functions, applies defined aliasing, and excludes unused trait methods */ - zend_traits_copy_trait_function_table(function_tables[i], &ce->traits[i]->function_table, ce->trait_aliases, &exclude_table TSRMLS_CC); + zend_traits_copy_trait_function_table(function_tables[i], ce, &ce->traits[i]->function_table, ce->trait_aliases, &exclude_table TSRMLS_CC); zend_hash_graceful_destroy(&exclude_table); } else { - zend_traits_copy_trait_function_table(function_tables[i], &ce->traits[i]->function_table, ce->trait_aliases, NULL TSRMLS_CC); + zend_traits_copy_trait_function_table(function_tables[i], ce, &ce->traits[i]->function_table, ce->trait_aliases, NULL TSRMLS_CC); } } diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index e71e2bf05c24d..8bb35136ecd43 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jul 31 17:59:24 2011 */ +/* Generated by re2c 0.13.5 on Sun Jul 31 20:09:37 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1083,7 +1083,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1753 "Zend/zend_language_scanner.l" +#line 1764 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1161,7 +1161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1741 "Zend/zend_language_scanner.l" +#line 1752 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1180,7 +1180,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1718 "Zend/zend_language_scanner.l" +#line 1729 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1378,7 +1378,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1678 "Zend/zend_language_scanner.l" +#line 1689 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1422,7 +1422,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1696 "Zend/zend_language_scanner.l" +#line 1707 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1440,7 +1440,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1709 "Zend/zend_language_scanner.l" +#line 1720 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1475,7 +1475,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1731 "Zend/zend_language_scanner.l" +#line 1742 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1555,7 +1555,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2204 "Zend/zend_language_scanner.l" +#line 2215 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1607,7 +1607,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2148 "Zend/zend_language_scanner.l" +#line 2159 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; @@ -1622,7 +1622,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2135 "Zend/zend_language_scanner.l" +#line 2146 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1645,7 +1645,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1835 "Zend/zend_language_scanner.l" +#line 1846 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1676,7 +1676,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1827 "Zend/zend_language_scanner.l" +#line 1838 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1702,7 +1702,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1817 "Zend/zend_language_scanner.l" +#line 1828 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1778,7 +1778,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2154 "Zend/zend_language_scanner.l" +#line 2165 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1838,7 +1838,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2143 "Zend/zend_language_scanner.l" +#line 2154 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; @@ -1853,7 +1853,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2135 "Zend/zend_language_scanner.l" +#line 2146 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1876,7 +1876,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1835 "Zend/zend_language_scanner.l" +#line 1846 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1907,7 +1907,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1827 "Zend/zend_language_scanner.l" +#line 1838 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1933,7 +1933,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1817 "Zend/zend_language_scanner.l" +#line 1828 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1952,7 +1952,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2122 "Zend/zend_language_scanner.l" +#line 2133 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -2026,7 +2026,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2246 "Zend/zend_language_scanner.l" +#line 2257 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2112,7 +2112,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2135 "Zend/zend_language_scanner.l" +#line 2146 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -2135,7 +2135,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1835 "Zend/zend_language_scanner.l" +#line 1846 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -2166,7 +2166,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1827 "Zend/zend_language_scanner.l" +#line 1838 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2192,7 +2192,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1817 "Zend/zend_language_scanner.l" +#line 1828 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2381,7 +2381,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1858 "Zend/zend_language_scanner.l" +#line 1869 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -2973,7 +2973,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1865 "Zend/zend_language_scanner.l" +#line 1876 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3014,7 +3014,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1956 "Zend/zend_language_scanner.l" +#line 1967 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3089,7 +3089,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2025 "Zend/zend_language_scanner.l" +#line 2036 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3136,7 +3136,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2116 "Zend/zend_language_scanner.l" +#line 2127 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; @@ -3147,7 +3147,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2374 "Zend/zend_language_scanner.l" +#line 2385 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3344,7 +3344,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy206: YYDEBUG(206, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1933 "Zend/zend_language_scanner.l" +#line 1944 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3386,7 +3386,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy211: YYDEBUG(211, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1835 "Zend/zend_language_scanner.l" +#line 1846 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -3482,7 +3482,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy228: YYDEBUG(228, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1942 "Zend/zend_language_scanner.l" +#line 1953 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3549,7 +3549,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy238: YYDEBUG(238, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1899 "Zend/zend_language_scanner.l" +#line 1910 "Zend/zend_language_scanner.l" { int doc_com; @@ -3857,7 +3857,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy279: YYDEBUG(279, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2067 "Zend/zend_language_scanner.l" +#line 2078 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -4153,7 +4153,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(319, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1668 "Zend/zend_language_scanner.l" +#line 1679 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4183,7 +4183,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(324, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1641 "Zend/zend_language_scanner.l" +#line 1652 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4235,7 +4235,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(330, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1623 "Zend/zend_language_scanner.l" +#line 1634 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; @@ -4276,7 +4276,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(338, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1602 "Zend/zend_language_scanner.l" +#line 1613 "Zend/zend_language_scanner.l" { char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4348,7 +4348,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(349, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1586 "Zend/zend_language_scanner.l" +#line 1597 "Zend/zend_language_scanner.l" { char *func_name = NULL; @@ -4384,7 +4384,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(354, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1629 "Zend/zend_language_scanner.l" +#line 1640 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4426,7 +4426,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(361, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1566 "Zend/zend_language_scanner.l" +#line 1577 "Zend/zend_language_scanner.l" { char *trait_name = NULL; @@ -4479,20 +4479,31 @@ int lex_scan(zval *zendlval TSRMLS_DC) #line 1550 "Zend/zend_language_scanner.l" { char *class_name = NULL; - - if (CG(active_class_entry)) { - class_name = CG(active_class_entry)->name; - } - - if (!class_name) { - class_name = ""; + + if (CG(active_class_entry) + && (ZEND_ACC_TRAIT == + (CG(active_class_entry)->ce_flags & ZEND_ACC_TRAIT))) { + // This is a hack, we abuse IS_NULL to indicate an invalid value + // if __CLASS__ is encountered in a trait, however, we also not that we + // should fix it up when we copy the method into an actual class + zendlval->value.lval = ZEND_ACC_TRAIT; + zendlval->type = IS_NULL; + } else { + if (CG(active_class_entry)) { + class_name = CG(active_class_entry)->name; + } + + if (!class_name) { + class_name = ""; + } + + zendlval->value.str.len = strlen(class_name); + zendlval->value.str.val = estrndup(class_name, zendlval->value.str.len); + zendlval->type = IS_STRING; } - zendlval->value.str.len = strlen(class_name); - zendlval->value.str.val = estrndup(class_name, zendlval->value.str.len); - zendlval->type = IS_STRING; return T_CLASS_C; } -#line 4496 "Zend/zend_language_scanner.c" +#line 4507 "Zend/zend_language_scanner.c" yy369: YYDEBUG(369, *YYCURSOR); yych = *++YYCURSOR; @@ -4558,7 +4569,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_HALT_COMPILER; } -#line 4562 "Zend/zend_language_scanner.c" +#line 4573 "Zend/zend_language_scanner.c" yy382: YYDEBUG(382, *YYCURSOR); yych = *++YYCURSOR; @@ -4582,7 +4593,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_USE; } -#line 4586 "Zend/zend_language_scanner.c" +#line 4597 "Zend/zend_language_scanner.c" yy386: YYDEBUG(386, *YYCURSOR); yych = *++YYCURSOR; @@ -4605,7 +4616,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_UNSET; } -#line 4609 "Zend/zend_language_scanner.c" +#line 4620 "Zend/zend_language_scanner.c" yy390: YYDEBUG(390, *YYCURSOR); ++YYCURSOR; @@ -4781,7 +4792,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INT_CAST; } -#line 4785 "Zend/zend_language_scanner.c" +#line 4796 "Zend/zend_language_scanner.c" yy408: YYDEBUG(408, *YYCURSOR); yych = *++YYCURSOR; @@ -4829,7 +4840,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_DOUBLE_CAST; } -#line 4833 "Zend/zend_language_scanner.c" +#line 4844 "Zend/zend_language_scanner.c" yy417: YYDEBUG(417, *YYCURSOR); yych = *++YYCURSOR; @@ -4903,7 +4914,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_STRING_CAST; } -#line 4907 "Zend/zend_language_scanner.c" +#line 4918 "Zend/zend_language_scanner.c" yy431: YYDEBUG(431, *YYCURSOR); yych = *++YYCURSOR; @@ -4940,7 +4951,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ARRAY_CAST; } -#line 4944 "Zend/zend_language_scanner.c" +#line 4955 "Zend/zend_language_scanner.c" yy438: YYDEBUG(438, *YYCURSOR); yych = *++YYCURSOR; @@ -4982,7 +4993,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_OBJECT_CAST; } -#line 4986 "Zend/zend_language_scanner.c" +#line 4997 "Zend/zend_language_scanner.c" yy446: YYDEBUG(446, *YYCURSOR); yych = *++YYCURSOR; @@ -5027,7 +5038,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_BOOL_CAST; } -#line 5031 "Zend/zend_language_scanner.c" +#line 5042 "Zend/zend_language_scanner.c" yy454: YYDEBUG(454, *YYCURSOR); yych = *++YYCURSOR; @@ -5091,7 +5102,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_UNSET_CAST; } -#line 5095 "Zend/zend_language_scanner.c" +#line 5106 "Zend/zend_language_scanner.c" yy466: YYDEBUG(466, *YYCURSOR); yych = *++YYCURSOR; @@ -5109,7 +5120,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_VAR; } -#line 5113 "Zend/zend_language_scanner.c" +#line 5124 "Zend/zend_language_scanner.c" yy469: YYDEBUG(469, *YYCURSOR); yych = *++YYCURSOR; @@ -5133,7 +5144,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_NEW; } -#line 5137 "Zend/zend_language_scanner.c" +#line 5148 "Zend/zend_language_scanner.c" yy473: YYDEBUG(473, *YYCURSOR); yych = *++YYCURSOR; @@ -5176,7 +5187,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_NAMESPACE; } -#line 5180 "Zend/zend_language_scanner.c" +#line 5191 "Zend/zend_language_scanner.c" yy481: YYDEBUG(481, *YYCURSOR); ++YYCURSOR; @@ -5186,7 +5197,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_PAAMAYIM_NEKUDOTAYIM; } -#line 5190 "Zend/zend_language_scanner.c" +#line 5201 "Zend/zend_language_scanner.c" yy483: YYDEBUG(483, *YYCURSOR); ++YYCURSOR; @@ -5212,7 +5223,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_MINUS_EQUAL; } -#line 5216 "Zend/zend_language_scanner.c" +#line 5227 "Zend/zend_language_scanner.c" yy487: YYDEBUG(487, *YYCURSOR); ++YYCURSOR; @@ -5222,7 +5233,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_DEC; } -#line 5226 "Zend/zend_language_scanner.c" +#line 5237 "Zend/zend_language_scanner.c" yy489: YYDEBUG(489, *YYCURSOR); ++YYCURSOR; @@ -5233,7 +5244,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); return T_OBJECT_OPERATOR; } -#line 5237 "Zend/zend_language_scanner.c" +#line 5248 "Zend/zend_language_scanner.c" yy491: YYDEBUG(491, *YYCURSOR); yych = *++YYCURSOR; @@ -5282,7 +5293,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_PUBLIC; } -#line 5286 "Zend/zend_language_scanner.c" +#line 5297 "Zend/zend_language_scanner.c" yy498: YYDEBUG(498, *YYCURSOR); yych = *++YYCURSOR; @@ -5341,7 +5352,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_PROTECTED; } -#line 5345 "Zend/zend_language_scanner.c" +#line 5356 "Zend/zend_language_scanner.c" yy507: YYDEBUG(507, *YYCURSOR); yych = *++YYCURSOR; @@ -5375,7 +5386,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_PRIVATE; } -#line 5379 "Zend/zend_language_scanner.c" +#line 5390 "Zend/zend_language_scanner.c" yy513: YYDEBUG(513, *YYCURSOR); ++YYCURSOR; @@ -5388,7 +5399,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_PRINT; } -#line 5392 "Zend/zend_language_scanner.c" +#line 5403 "Zend/zend_language_scanner.c" yy515: YYDEBUG(515, *YYCURSOR); yych = *++YYCURSOR; @@ -5417,7 +5428,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_GOTO; } -#line 5421 "Zend/zend_language_scanner.c" +#line 5432 "Zend/zend_language_scanner.c" yy520: YYDEBUG(520, *YYCURSOR); yych = *++YYCURSOR; @@ -5445,7 +5456,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_GLOBAL; } -#line 5449 "Zend/zend_language_scanner.c" +#line 5460 "Zend/zend_language_scanner.c" yy525: YYDEBUG(525, *YYCURSOR); yych = *++YYCURSOR; @@ -5486,7 +5497,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_BREAK; } -#line 5490 "Zend/zend_language_scanner.c" +#line 5501 "Zend/zend_language_scanner.c" yy533: YYDEBUG(533, *YYCURSOR); yych = *++YYCURSOR; @@ -5530,7 +5541,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_SWITCH; } -#line 5534 "Zend/zend_language_scanner.c" +#line 5545 "Zend/zend_language_scanner.c" yy541: YYDEBUG(541, *YYCURSOR); yych = *++YYCURSOR; @@ -5558,7 +5569,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_STATIC; } -#line 5562 "Zend/zend_language_scanner.c" +#line 5573 "Zend/zend_language_scanner.c" yy546: YYDEBUG(546, *YYCURSOR); yych = *++YYCURSOR; @@ -5589,7 +5600,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_AS; } -#line 5593 "Zend/zend_language_scanner.c" +#line 5604 "Zend/zend_language_scanner.c" yy551: YYDEBUG(551, *YYCURSOR); yych = *++YYCURSOR; @@ -5612,7 +5623,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ARRAY; } -#line 5616 "Zend/zend_language_scanner.c" +#line 5627 "Zend/zend_language_scanner.c" yy555: YYDEBUG(555, *YYCURSOR); ++YYCURSOR; @@ -5625,7 +5636,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_LOGICAL_AND; } -#line 5629 "Zend/zend_language_scanner.c" +#line 5640 "Zend/zend_language_scanner.c" yy557: YYDEBUG(557, *YYCURSOR); yych = *++YYCURSOR; @@ -5663,7 +5674,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ABSTRACT; } -#line 5667 "Zend/zend_language_scanner.c" +#line 5678 "Zend/zend_language_scanner.c" yy564: YYDEBUG(564, *YYCURSOR); yych = *++YYCURSOR; @@ -5691,7 +5702,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_WHILE; } -#line 5695 "Zend/zend_language_scanner.c" +#line 5706 "Zend/zend_language_scanner.c" yy569: YYDEBUG(569, *YYCURSOR); ++YYCURSOR; @@ -5704,7 +5715,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_IF; } -#line 5708 "Zend/zend_language_scanner.c" +#line 5719 "Zend/zend_language_scanner.c" yy571: YYDEBUG(571, *YYCURSOR); yych = *++YYCURSOR; @@ -5760,7 +5771,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ISSET; } -#line 5764 "Zend/zend_language_scanner.c" +#line 5775 "Zend/zend_language_scanner.c" yy578: YYDEBUG(578, *YYCURSOR); yych = *++YYCURSOR; @@ -5818,7 +5829,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INCLUDE; } -#line 5822 "Zend/zend_language_scanner.c" +#line 5833 "Zend/zend_language_scanner.c" yy586: YYDEBUG(586, *YYCURSOR); yych = *++YYCURSOR; @@ -5851,7 +5862,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INCLUDE_ONCE; } -#line 5855 "Zend/zend_language_scanner.c" +#line 5866 "Zend/zend_language_scanner.c" yy592: YYDEBUG(592, *YYCURSOR); yych = *++YYCURSOR; @@ -5889,7 +5900,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INTERFACE; } -#line 5893 "Zend/zend_language_scanner.c" +#line 5904 "Zend/zend_language_scanner.c" yy599: YYDEBUG(599, *YYCURSOR); yych = *++YYCURSOR; @@ -5943,7 +5954,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INSTEADOF; } -#line 5947 "Zend/zend_language_scanner.c" +#line 5958 "Zend/zend_language_scanner.c" yy607: YYDEBUG(607, *YYCURSOR); yych = *++YYCURSOR; @@ -5976,7 +5987,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_INSTANCEOF; } -#line 5980 "Zend/zend_language_scanner.c" +#line 5991 "Zend/zend_language_scanner.c" yy613: YYDEBUG(613, *YYCURSOR); yych = *++YYCURSOR; @@ -6024,7 +6035,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_IMPLEMENTS; } -#line 6028 "Zend/zend_language_scanner.c" +#line 6039 "Zend/zend_language_scanner.c" yy622: YYDEBUG(622, *YYCURSOR); yych = *++YYCURSOR; @@ -6056,7 +6067,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_TRY; } -#line 6060 "Zend/zend_language_scanner.c" +#line 6071 "Zend/zend_language_scanner.c" yy626: YYDEBUG(626, *YYCURSOR); yych = *++YYCURSOR; @@ -6079,7 +6090,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_TRAIT; } -#line 6083 "Zend/zend_language_scanner.c" +#line 6094 "Zend/zend_language_scanner.c" yy630: YYDEBUG(630, *YYCURSOR); yych = *++YYCURSOR; @@ -6102,7 +6113,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_THROW; } -#line 6106 "Zend/zend_language_scanner.c" +#line 6117 "Zend/zend_language_scanner.c" yy634: YYDEBUG(634, *YYCURSOR); yych = *++YYCURSOR; @@ -6167,7 +6178,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_REQUIRE; } -#line 6171 "Zend/zend_language_scanner.c" +#line 6182 "Zend/zend_language_scanner.c" yy642: YYDEBUG(642, *YYCURSOR); yych = *++YYCURSOR; @@ -6200,7 +6211,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_REQUIRE_ONCE; } -#line 6204 "Zend/zend_language_scanner.c" +#line 6215 "Zend/zend_language_scanner.c" yy648: YYDEBUG(648, *YYCURSOR); yych = *++YYCURSOR; @@ -6223,7 +6234,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_RETURN; } -#line 6227 "Zend/zend_language_scanner.c" +#line 6238 "Zend/zend_language_scanner.c" yy652: YYDEBUG(652, *YYCURSOR); yych = *++YYCURSOR; @@ -6308,7 +6319,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CONTINUE; } -#line 6312 "Zend/zend_language_scanner.c" +#line 6323 "Zend/zend_language_scanner.c" yy663: YYDEBUG(663, *YYCURSOR); ++YYCURSOR; @@ -6321,7 +6332,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CONST; } -#line 6325 "Zend/zend_language_scanner.c" +#line 6336 "Zend/zend_language_scanner.c" yy665: YYDEBUG(665, *YYCURSOR); yych = *++YYCURSOR; @@ -6350,7 +6361,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CLONE; } -#line 6354 "Zend/zend_language_scanner.c" +#line 6365 "Zend/zend_language_scanner.c" yy670: YYDEBUG(670, *YYCURSOR); yych = *++YYCURSOR; @@ -6368,7 +6379,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CLASS; } -#line 6372 "Zend/zend_language_scanner.c" +#line 6383 "Zend/zend_language_scanner.c" yy673: YYDEBUG(673, *YYCURSOR); yych = *++YYCURSOR; @@ -6392,7 +6403,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CASE; } -#line 6396 "Zend/zend_language_scanner.c" +#line 6407 "Zend/zend_language_scanner.c" yy677: YYDEBUG(677, *YYCURSOR); yych = *++YYCURSOR; @@ -6410,7 +6421,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CATCH; } -#line 6414 "Zend/zend_language_scanner.c" +#line 6425 "Zend/zend_language_scanner.c" yy680: YYDEBUG(680, *YYCURSOR); yych = *++YYCURSOR; @@ -6465,7 +6476,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_FUNCTION; } -#line 6469 "Zend/zend_language_scanner.c" +#line 6480 "Zend/zend_language_scanner.c" yy690: YYDEBUG(690, *YYCURSOR); ++YYCURSOR; @@ -6493,7 +6504,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_FOR; } -#line 6497 "Zend/zend_language_scanner.c" +#line 6508 "Zend/zend_language_scanner.c" yy692: YYDEBUG(692, *YYCURSOR); yych = *++YYCURSOR; @@ -6521,7 +6532,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_FOREACH; } -#line 6525 "Zend/zend_language_scanner.c" +#line 6536 "Zend/zend_language_scanner.c" yy697: YYDEBUG(697, *YYCURSOR); yych = *++YYCURSOR; @@ -6544,7 +6555,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_FINAL; } -#line 6548 "Zend/zend_language_scanner.c" +#line 6559 "Zend/zend_language_scanner.c" yy701: YYDEBUG(701, *YYCURSOR); yych = *++YYCURSOR; @@ -6579,7 +6590,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_DO; } -#line 6583 "Zend/zend_language_scanner.c" +#line 6594 "Zend/zend_language_scanner.c" yy705: YYDEBUG(705, *YYCURSOR); ++YYCURSOR; @@ -6592,7 +6603,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_EXIT; } -#line 6596 "Zend/zend_language_scanner.c" +#line 6607 "Zend/zend_language_scanner.c" yy707: YYDEBUG(707, *YYCURSOR); yych = *++YYCURSOR; @@ -6631,7 +6642,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_DEFAULT; } -#line 6635 "Zend/zend_language_scanner.c" +#line 6646 "Zend/zend_language_scanner.c" yy714: YYDEBUG(714, *YYCURSOR); yych = *++YYCURSOR; @@ -6659,7 +6670,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_DECLARE; } -#line 6663 "Zend/zend_language_scanner.c" +#line 6674 "Zend/zend_language_scanner.c" yy719: YYDEBUG(719, *YYCURSOR); yych = *++YYCURSOR; @@ -6743,7 +6754,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_EXTENDS; } -#line 6747 "Zend/zend_language_scanner.c" +#line 6758 "Zend/zend_language_scanner.c" yy732: YYDEBUG(732, *YYCURSOR); ++YYCURSOR; @@ -6756,7 +6767,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_EXIT; } -#line 6760 "Zend/zend_language_scanner.c" +#line 6771 "Zend/zend_language_scanner.c" yy734: YYDEBUG(734, *YYCURSOR); yych = *++YYCURSOR; @@ -6774,7 +6785,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_EVAL; } -#line 6778 "Zend/zend_language_scanner.c" +#line 6789 "Zend/zend_language_scanner.c" yy737: YYDEBUG(737, *YYCURSOR); yych = *++YYCURSOR; @@ -6848,7 +6859,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ENDWHILE; } -#line 6852 "Zend/zend_language_scanner.c" +#line 6863 "Zend/zend_language_scanner.c" yy748: YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; @@ -6881,7 +6892,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ENDSWITCH; } -#line 6885 "Zend/zend_language_scanner.c" +#line 6896 "Zend/zend_language_scanner.c" yy754: YYDEBUG(754, *YYCURSOR); ++YYCURSOR; @@ -6894,7 +6905,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ENDIF; } -#line 6898 "Zend/zend_language_scanner.c" +#line 6909 "Zend/zend_language_scanner.c" yy756: YYDEBUG(756, *YYCURSOR); yych = *++YYCURSOR; @@ -6927,7 +6938,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ENDFOR; } -#line 6931 "Zend/zend_language_scanner.c" +#line 6942 "Zend/zend_language_scanner.c" yy759: YYDEBUG(759, *YYCURSOR); yych = *++YYCURSOR; @@ -6955,7 +6966,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ENDFOREACH; } -#line 6959 "Zend/zend_language_scanner.c" +#line 6970 "Zend/zend_language_scanner.c" yy764: YYDEBUG(764, *YYCURSOR); yych = *++YYCURSOR; @@ -6993,7 +7004,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ENDDECLARE; } -#line 6997 "Zend/zend_language_scanner.c" +#line 7008 "Zend/zend_language_scanner.c" yy771: YYDEBUG(771, *YYCURSOR); yych = *++YYCURSOR; @@ -7016,7 +7027,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_EMPTY; } -#line 7020 "Zend/zend_language_scanner.c" +#line 7031 "Zend/zend_language_scanner.c" yy775: YYDEBUG(775, *YYCURSOR); yych = *++YYCURSOR; @@ -7049,7 +7060,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ELSE; } -#line 7053 "Zend/zend_language_scanner.c" +#line 7064 "Zend/zend_language_scanner.c" yy778: YYDEBUG(778, *YYCURSOR); yych = *++YYCURSOR; @@ -7067,7 +7078,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ELSEIF; } -#line 7071 "Zend/zend_language_scanner.c" +#line 7082 "Zend/zend_language_scanner.c" yy781: YYDEBUG(781, *YYCURSOR); yych = *++YYCURSOR; @@ -7085,7 +7096,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_ECHO; } -#line 7089 "Zend/zend_language_scanner.c" +#line 7100 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7166,7 +7177,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7170 "Zend/zend_language_scanner.c" +#line 7181 "Zend/zend_language_scanner.c" yy788: YYDEBUG(788, *YYCURSOR); ++YYCURSOR; @@ -7180,7 +7191,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_pop_state(TSRMLS_C); goto restart; } -#line 7184 "Zend/zend_language_scanner.c" +#line 7195 "Zend/zend_language_scanner.c" yy790: YYDEBUG(790, *YYCURSOR); ++YYCURSOR; @@ -7196,7 +7207,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_STRING; } -#line 7200 "Zend/zend_language_scanner.c" +#line 7211 "Zend/zend_language_scanner.c" yy792: YYDEBUG(792, *YYCURSOR); yych = *++YYCURSOR; @@ -7221,7 +7232,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_OBJECT_OPERATOR; } -#line 7225 "Zend/zend_language_scanner.c" +#line 7236 "Zend/zend_language_scanner.c" yy797: YYDEBUG(797, *YYCURSOR); ++YYCURSOR; @@ -7299,7 +7310,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7303 "Zend/zend_language_scanner.c" +#line 7314 "Zend/zend_language_scanner.c" yy803: YYDEBUG(803, *YYCURSOR); ++YYCURSOR; @@ -7312,7 +7323,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7316 "Zend/zend_language_scanner.c" +#line 7327 "Zend/zend_language_scanner.c" yy805: YYDEBUG(805, *YYCURSOR); ++YYCURSOR; @@ -7334,7 +7345,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(810, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2318 "Zend/zend_language_scanner.l" +#line 2329 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7389,7 +7400,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7393 "Zend/zend_language_scanner.c" +#line 7404 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7508,7 +7519,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7512 "Zend/zend_language_scanner.c" +#line 7523 "Zend/zend_language_scanner.c" yy815: YYDEBUG(815, *YYCURSOR); yych = *++YYCURSOR; @@ -7528,23 +7539,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy817: YYDEBUG(817, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1846 "Zend/zend_language_scanner.l" +#line 1857 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7537 "Zend/zend_language_scanner.c" +#line 7548 "Zend/zend_language_scanner.c" yy818: YYDEBUG(818, *YYCURSOR); ++YYCURSOR; YYDEBUG(819, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1841 "Zend/zend_language_scanner.l" +#line 1852 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7548 "Zend/zend_language_scanner.c" +#line 7559 "Zend/zend_language_scanner.c" yy820: YYDEBUG(820, *YYCURSOR); yych = *++YYCURSOR; @@ -7554,14 +7565,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(822, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1851 "Zend/zend_language_scanner.l" +#line 1862 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7565 "Zend/zend_language_scanner.c" +#line 7576 "Zend/zend_language_scanner.c" yy823: YYDEBUG(823, *YYCURSOR); ++YYCURSOR; @@ -7570,19 +7581,19 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy824: YYDEBUG(824, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1858 "Zend/zend_language_scanner.l" +#line 1869 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7580 "Zend/zend_language_scanner.c" +#line 7591 "Zend/zend_language_scanner.c" yy825: YYDEBUG(825, *YYCURSOR); ++YYCURSOR; YYDEBUG(826, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2374 "Zend/zend_language_scanner.l" +#line 2385 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7591,7 +7602,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7595 "Zend/zend_language_scanner.c" +#line 7606 "Zend/zend_language_scanner.c" yy827: YYDEBUG(827, *YYCURSOR); ++YYCURSOR; @@ -7627,13 +7638,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy831: YYDEBUG(831, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1835 "Zend/zend_language_scanner.l" +#line 1846 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7637 "Zend/zend_language_scanner.c" +#line 7648 "Zend/zend_language_scanner.c" yy832: YYDEBUG(832, *YYCURSOR); ++YYCURSOR; @@ -7680,7 +7691,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7684 "Zend/zend_language_scanner.c" +#line 7695 "Zend/zend_language_scanner.c" yy840: YYDEBUG(840, *YYCURSOR); ++YYCURSOR; @@ -7703,6 +7714,6 @@ int lex_scan(zval *zendlval TSRMLS_DC) goto yy839; } } -#line 2383 "Zend/zend_language_scanner.l" +#line 2394 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 1a22f0b7e19c2..73e22e209e522 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1549,17 +1549,28 @@ NEWLINE ("\r"|"\n"|"\r\n") "__CLASS__" { char *class_name = NULL; - - if (CG(active_class_entry)) { - class_name = CG(active_class_entry)->name; - } - - if (!class_name) { - class_name = ""; + + if (CG(active_class_entry) + && (ZEND_ACC_TRAIT == + (CG(active_class_entry)->ce_flags & ZEND_ACC_TRAIT))) { + // This is a hack, we abuse IS_NULL to indicate an invalid value + // if __CLASS__ is encountered in a trait, however, we also not that we + // should fix it up when we copy the method into an actual class + zendlval->value.lval = ZEND_ACC_TRAIT; + zendlval->type = IS_NULL; + } else { + if (CG(active_class_entry)) { + class_name = CG(active_class_entry)->name; + } + + if (!class_name) { + class_name = ""; + } + + zendlval->value.str.len = strlen(class_name); + zendlval->value.str.val = estrndup(class_name, zendlval->value.str.len); + zendlval->type = IS_STRING; } - zendlval->value.str.len = strlen(class_name); - zendlval->value.str.val = estrndup(class_name, zendlval->value.str.len); - zendlval->type = IS_STRING; return T_CLASS_C; } diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 15cc351d248fb..84ec3a480f6c6 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jul 31 17:59:24 2011 */ +/* Generated by re2c 0.13.5 on Sun Jul 31 20:09:38 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { From 4442b3f7a8f90af90d9838121415d725b303b067 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 31 Jul 2011 18:51:15 +0000 Subject: [PATCH 0428/2394] - Fixed tests --- Zend/tests/error_reporting01.phpt | 2 +- Zend/tests/error_reporting05.phpt | 2 +- Zend/tests/error_reporting06.phpt | 2 +- Zend/tests/error_reporting07.phpt | 2 +- Zend/tests/error_reporting10.phpt | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Zend/tests/error_reporting01.phpt b/Zend/tests/error_reporting01.phpt index 096977065c61d..5153d41eab420 100644 --- a/Zend/tests/error_reporting01.phpt +++ b/Zend/tests/error_reporting01.phpt @@ -22,5 +22,5 @@ var_dump(error_reporting()); echo "Done\n"; ?> --EXPECT-- -int(30719) +int(32767) Done diff --git a/Zend/tests/error_reporting05.phpt b/Zend/tests/error_reporting05.phpt index 2bf392d7c9da9..fe5374c4f7abf 100644 --- a/Zend/tests/error_reporting05.phpt +++ b/Zend/tests/error_reporting05.phpt @@ -30,5 +30,5 @@ echo "Done\n"; Notice: Undefined variable: undef_value in %s on line %d Notice: Undefined variable: undef_name in %s on line %d -int(30719) +int(32767) Done diff --git a/Zend/tests/error_reporting06.phpt b/Zend/tests/error_reporting06.phpt index beb91bf094b30..285a623f2b4b6 100644 --- a/Zend/tests/error_reporting06.phpt +++ b/Zend/tests/error_reporting06.phpt @@ -26,5 +26,5 @@ var_dump(error_reporting()); echo "Done\n"; ?> --EXPECTF-- -int(30719) +int(32767) Done diff --git a/Zend/tests/error_reporting07.phpt b/Zend/tests/error_reporting07.phpt index 5da970c158216..c63efae604b5e 100644 --- a/Zend/tests/error_reporting07.phpt +++ b/Zend/tests/error_reporting07.phpt @@ -26,5 +26,5 @@ var_dump(error_reporting()); echo "Done\n"; ?> --EXPECTF-- -int(30719) +int(32767) Done diff --git a/Zend/tests/error_reporting10.phpt b/Zend/tests/error_reporting10.phpt index 7205acda3eb5b..12b1db57baed9 100644 --- a/Zend/tests/error_reporting10.phpt +++ b/Zend/tests/error_reporting10.phpt @@ -30,6 +30,6 @@ var_dump(error_reporting()); echo "Done\n"; ?> --EXPECTF-- -int(30719) -int(30711) +int(32767) +int(32759) Done From 991e108a85349792e3cb167076511e8429b902d0 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 31 Jul 2011 20:50:09 +0000 Subject: [PATCH 0429/2394] - blowfish 1.2 update, 2nd part --- ext/standard/crypt.c | 2 +- .../tests/strings/crypt_blowfish.phpt | 32 +++++++++++++++++-- 2 files changed, 31 insertions(+), 3 deletions(-) diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index 03a080aa23325..fda95d8f9cbe9 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -240,7 +240,7 @@ PHP_FUNCTION(crypt) } else if ( salt[0] == '$' && salt[1] == '2' && - (salt[2] != 'a' && salt[2] != 'x') || + salt[2] >= 'a' && salt[2] <= 'z' && salt[3] == '$' && salt[4] >= '0' && salt[4] <= '3' && salt[5] >= '0' && salt[5] <= '9' && diff --git a/ext/standard/tests/strings/crypt_blowfish.phpt b/ext/standard/tests/strings/crypt_blowfish.phpt index cce09c1518544..20a6a2750af72 100644 --- a/ext/standard/tests/strings/crypt_blowfish.phpt +++ b/ext/standard/tests/strings/crypt_blowfish.phpt @@ -15,13 +15,27 @@ $tests =array( array('$2a$05$XXXXXXXXXXXXXXXXXXXXXOAcXxm9kjPGEMsLznoKqmqw7tc8WCx4a', 'U*U*U'), array('$2a$05$abcdefghijklmnopqrstuu5s2v8.iXieOjg/.AySBTTZIIVFJeBui', '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789chars after 72 are ignored'), array('$2x$05$/OK.fbVrR/bpIqNJ5ianF.CE5elHaaO4EbggVDjb8P19RukzXSM3e', "\xa3"), + array('$2x$05$/OK.fbVrR/bpIqNJ5ianF.CE5elHaaO4EbggVDjb8P19RukzXSM3e', "\xff\xff\xa3"), + array('$2y$05$/OK.fbVrR/bpIqNJ5ianF.CE5elHaaO4EbggVDjb8P19RukzXSM3e', "\xff\xff\xa3"), + array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.nqd1wy.pTMdcvrRWxyiGL2eMz.2a85.', "\xff\xff\xa3"), + array('$2y$05$/OK.fbVrR/bpIqNJ5ianF.Sa7shbm4.OzKpvFnX1pQLmQW96oUlCq', "\xa3"), array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.Sa7shbm4.OzKpvFnX1pQLmQW96oUlCq', "\xa3"), + array('$2x$05$/OK.fbVrR/bpIqNJ5ianF.o./n25XVfn6oAPaUvHe.Csk4zRfsYPi', "1\xa3345"), + array('$2x$05$/OK.fbVrR/bpIqNJ5ianF.o./n25XVfn6oAPaUvHe.Csk4zRfsYPi', "\xff\xa3345"), + array('$2x$05$/OK.fbVrR/bpIqNJ5ianF.o./n25XVfn6oAPaUvHe.Csk4zRfsYPi', "\xff\xa334\xff\xff\xff\xa3345"), + array('$2y$05$/OK.fbVrR/bpIqNJ5ianF.o./n25XVfn6oAPaUvHe.Csk4zRfsYPi', "\xff\xa334\xff\xff\xff\xa3345"), + array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.ZC1JEJ8Z4gPfpe1JOr/oyPXTWl9EFd.', "\xff\xa334\xff\xff\xff\xa3345"), + array('$2y$05$/OK.fbVrR/bpIqNJ5ianF.nRht2l/HRhr6zmCp9vYUvvsqynflf9e', "\xff\xa3345"), + array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.nRht2l/HRhr6zmCp9vYUvvsqynflf9e', "\xff\xa3345"), + array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.6IflQkJytoRVc1yuaNtHfiuq.FRlSIS', "\xa3ab"), + array('$2x$05$/OK.fbVrR/bpIqNJ5ianF.6IflQkJytoRVc1yuaNtHfiuq.FRlSIS', "\xa3ab"), + array('$2y$05$/OK.fbVrR/bpIqNJ5ianF.6IflQkJytoRVc1yuaNtHfiuq.FRlSIS', "\xa3ab"), array('$2x$05$6bNw2HLQYeqHYyBfLMsv/OiwqTymGIGzFsA4hOTWebfehXHNprcAS', "\xd1\x91"), array('$2x$05$6bNw2HLQYeqHYyBfLMsv/O9LIGgn8OMzuDoHfof8AQimSGfcSWxnS', "\xd0\xc1\xd2\xcf\xcc\xd8"), array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.swQOIzjOiJ9GHEPuhEkvqrUyvWhEMx6', "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaachars after 72 are ignored as usual"), array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.R9xrDjiycxMbQE2bp.vgqlYpW5wx2yy', "\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55\xaa\x55"), array('$2a$05$/OK.fbVrR/bpIqNJ5ianF.9tQZzcJfm3uj2NvJ/n5xkhpqLrMpWCe', "\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff\x55\xaa\xff"), - array('$2a$05$CCCCCCCCCCCCCCCCCCCCC.7uG0VCzI2bS7j6ymqJi9CdcdxiRTWNy', ''), + array('$2a$05$CCCCCCCCCCCCCCCCCCCCC.7uG0VCzI2bS7j6ymqJi9CdcdxiRTWNy', ''), ); $i=0; @@ -47,4 +61,18 @@ foreach($tests as $test) { 8. OK 9. OK 10. OK -11. OK \ No newline at end of file +11. OK +12. OK +13. OK +14. OK +15. OK +16. OK +17. OK +18. OK +19. OK +20. OK +21. OK +22. OK +23. OK +24. OK +25. OK From d868c716173cdf1563d1d80cbb0e44d8960c8b41 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 31 Jul 2011 21:47:03 +0000 Subject: [PATCH 0430/2394] fix salt truncation bug in sha256 --- ext/standard/crypt_sha256.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/crypt_sha256.c b/ext/standard/crypt_sha256.c index 231206bca14db..d334e3d477d89 100644 --- a/ext/standard/crypt_sha256.c +++ b/ext/standard/crypt_sha256.c @@ -398,7 +398,7 @@ char * php_sha256_crypt_r(const char *key, const char *salt, char *buffer, int b char *tmp = (char *) alloca(salt_len + 1 + __alignof__(uint32_t)); salt = copied_salt = memcpy(tmp + __alignof__(uint32_t) - (tmp - (char *) 0) % __alignof__ (uint32_t), salt, salt_len); - tmp[salt_len] = 0; + copied_salt[salt_len] = 0; } /* Prepare for the real work. */ From 2f1752cb49e70db055c00230f41d262c485b0880 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 31 Jul 2011 22:43:21 +0000 Subject: [PATCH 0431/2394] retore open_basedir check for unlink --- main/streams/plain_wrapper.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main/streams/plain_wrapper.c b/main/streams/plain_wrapper.c index 8303adb5b1208..c54ccd2ccffe9 100644 --- a/main/streams/plain_wrapper.c +++ b/main/streams/plain_wrapper.c @@ -1035,6 +1035,10 @@ static int php_plain_files_unlink(php_stream_wrapper *wrapper, char *url, int op url = p + 3; } + if (php_check_open_basedir(url TSRMLS_CC)) { + return 0; + } + ret = VCWD_UNLINK(url); if (ret == -1) { if (options & REPORT_ERRORS) { From b56c6b24ffc72e2d733d87d4ae08051951e4f10d Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 31 Jul 2011 23:14:04 +0000 Subject: [PATCH 0432/2394] fix termination in sha-512 too --- ext/standard/crypt_sha512.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/crypt_sha512.c b/ext/standard/crypt_sha512.c index 708ad67caa3ba..0955532131588 100644 --- a/ext/standard/crypt_sha512.c +++ b/ext/standard/crypt_sha512.c @@ -431,8 +431,8 @@ php_sha512_crypt_r(const char *key, const char *salt, char *buffer, int buflen) if ((salt - (char *) 0) % __alignof__ (uint64_t) != 0) { char *tmp = (char *) alloca(salt_len + 1 + __alignof__(uint64_t)); - tmp[salt_len] = 0; salt = copied_salt = memcpy(tmp + __alignof__(uint64_t) - (tmp - (char *) 0) % __alignof__(uint64_t), salt, salt_len); + copied_salt[salt_len] = 0; } /* Prepare for the real work. */ From 553a08c4e11d16447f826aaa5eb861cb147f3c9b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 1 Aug 2011 01:00:57 +0000 Subject: [PATCH 0433/2394] fix failing tests --- .../tests/DOMDocument_loadHTML_error1.phpt | 2 +- .../DOMDocument_relaxNGValidate_error2.phpt | 6 ++ ext/fileinfo/tests/finfo_open_001.phpt | 18 +++++ ext/fileinfo/tests/finfo_open_error.phpt | 10 ++- ext/iconv/tests/bug52941.phpt | 4 +- ext/iconv/tests/iconv_stream_filter.phpt | 2 + ext/mbstring/tests/bug43301.phpt | 2 +- ext/mcrypt/tests/blowfish.phpt | 10 +-- tests/basic/028.phpt | 26 ++++---- tests/basic/bug46313-win.phpt | 65 ------------------- 10 files changed, 57 insertions(+), 88 deletions(-) diff --git a/ext/dom/tests/DOMDocument_loadHTML_error1.phpt b/ext/dom/tests/DOMDocument_loadHTML_error1.phpt index c7b5e614d7cd3..de8d349e9ff55 100644 --- a/ext/dom/tests/DOMDocument_loadHTML_error1.phpt +++ b/ext/dom/tests/DOMDocument_loadHTML_error1.phpt @@ -12,4 +12,4 @@ $doc = new DOMDocument(); $doc->loadHTML(); ?> --EXPECTF-- -Warning: DOMDocument::loadHTML() expects exactly 1 parameter, 0 given in %s on line %d +Warning: DOMDocument::loadHTML() expects at least 1 parameter, 0 given in %s on line %d diff --git a/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt b/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt index 85749210b0812..7c5f8901e7236 100644 --- a/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt +++ b/ext/dom/tests/DOMDocument_relaxNGValidate_error2.phpt @@ -23,3 +23,9 @@ var_dump($result); ?> --EXPECTF-- +Warning: DOMDocument::relaxNGValidate(): I/O warning : failed to load external entity "%s/foo.rng" in %s on line %d + +Warning: DOMDocument::relaxNGValidate(): xmlRelaxNGParse: could not load %s/foo.rng in %s on line %d + +Warning: DOMDocument::relaxNGValidate(): Invalid RelaxNG in %s on line %d +bool(false) diff --git a/ext/fileinfo/tests/finfo_open_001.phpt b/ext/fileinfo/tests/finfo_open_001.phpt index 9513b54bad3bb..de55ae353f70a 100644 --- a/ext/fileinfo/tests/finfo_open_001.phpt +++ b/ext/fileinfo/tests/finfo_open_001.phpt @@ -18,6 +18,24 @@ Warning: finfo_open() expects parameter 2 to be a valid path, string given in %s bool(false) resource(%d) of type (file_info) resource(%d) of type (file_info) + +Warning: finfo_open(%s/123): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(%s/123): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(): Failed to load magic database at '%s/123'. in %s on line %d bool(false) + +Warning: finfo_open(%s/1): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(%s/1): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(): Failed to load magic database at '%s/1'. in %s on line %d bool(false) + +Warning: finfo_open(/foo/bar/inexistent): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(/foo/bar/inexistent): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(): Failed to load magic database at '/foo/bar/inexistent'. in %s on line %d bool(false) diff --git a/ext/fileinfo/tests/finfo_open_error.phpt b/ext/fileinfo/tests/finfo_open_error.phpt index 2876b17884cee..80a6bfd637e8b 100644 --- a/ext/fileinfo/tests/finfo_open_error.phpt +++ b/ext/fileinfo/tests/finfo_open_error.phpt @@ -26,6 +26,12 @@ var_dump( new finfo('foobar') ); ===DONE=== --EXPECTF-- *** Testing finfo_open() : error functionality *** + +Warning: finfo_open(%s/foobarfile): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(%s/foobarfile): failed to open stream: No such file or directory in %s on line %d + +Warning: finfo_open(): Failed to load magic database at '%s/foobarfile'. in %s on line %d bool(false) Warning: finfo_open() expects parameter 1 to be long, array given in %s on line %d @@ -37,10 +43,10 @@ bool(false) Notice: finfo_open(): Warning: using regular magic file `%s' in %s on line %d resource(%d) of type (file_info) -Warning: finfo_open() expects parameter 1 to be long, %unicode_string_optional% given in %s on line %d +Warning: finfo_open() expects parameter 1 to be long, string given in %s on line %d bool(false) -Warning: finfo::finfo() expects parameter 1 to be long, %unicode_string_optional% given in %s on line %d +Warning: finfo::finfo() expects parameter 1 to be long, string given in %s on line %d object(finfo)#%d (%d) { } ===DONE=== diff --git a/ext/iconv/tests/bug52941.phpt b/ext/iconv/tests/bug52941.phpt index 753c9ada14375..31aabd5e46eb7 100644 --- a/ext/iconv/tests/bug52941.phpt +++ b/ext/iconv/tests/bug52941.phpt @@ -32,10 +32,10 @@ var_dump($decoded['To']); string(17) "" string(29) "=?ks_c_5601-1987?B?UkU6odk=?=" string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" -string(32) "=?ks_c_5601-1987?B?UkU6odk=?=Foo" +string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" string(18) "" string(17) "" string(29) "=?ks_c_5601-1987?B?UkU6odk=?=" string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" -string(32) "=?ks_c_5601-1987?B?UkU6odk=?=Foo" +string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" string(18) "" diff --git a/ext/iconv/tests/iconv_stream_filter.phpt b/ext/iconv/tests/iconv_stream_filter.phpt index 6a60bafeb81a2..003c631846938 100644 --- a/ext/iconv/tests/iconv_stream_filter.phpt +++ b/ext/iconv/tests/iconv_stream_filter.phpt @@ -34,6 +34,8 @@ string(2) "42" string(20) "a4b3a4f3a4cba4c1a4cf" string(10) "69636f6e76" string(2) "0a" + +Warning: fread(): iconv stream filter ("ISO-2022-JP"=>"EUC-JP"): invalid multibyte sequence in %s on line %d bool(true) bool(true) bool(true) diff --git a/ext/mbstring/tests/bug43301.phpt b/ext/mbstring/tests/bug43301.phpt index 310426a14286e..1a22e4b64df82 100644 --- a/ext/mbstring/tests/bug43301.phpt +++ b/ext/mbstring/tests/bug43301.phpt @@ -15,7 +15,7 @@ echo mb_ereg_replace($ptr,'$1',$txt,'e'); ?> --EXPECTF-- -Parse error: syntax error, unexpected T_LNUMBER, expecting T_VARIABLE or '$' in %sbug43301.php(%d) : mbregex replace on line 1 +Parse error: syntax error, unexpected '1' (T_LNUMBER), expecting variable (T_VARIABLE) or '$' in %sbug43301.php(%d) : mbregex replace on line %d Fatal error: mb_ereg_replace(): Failed evaluating code: $1 in %sbug43301.php on line %d diff --git a/ext/mcrypt/tests/blowfish.phpt b/ext/mcrypt/tests/blowfish.phpt index bd8df9d14db1d..a133091d78ef1 100644 --- a/ext/mcrypt/tests/blowfish.phpt +++ b/ext/mcrypt/tests/blowfish.phpt @@ -4,10 +4,12 @@ Test for blowfish compatibility --FILE-- ---EXPECTF-- +--EXPECT-- array(15) { ["name1"]=> string(8) "testname" @@ -77,28 +77,28 @@ array(15) { string(8) "testname" ["name3"]=> string(8) "testname" - ["name\\4"]=> + ["name\4"]=> string(8) "testname" - ["name\\5"]=> + ["name\5"]=> string(8) "testname" - ["name\\\'6"]=> + ["name\'6"]=> string(8) "testname" - ["name\\\"7"]=> + ["name\"7"]=> string(8) "testname" - ["name\\8"]=> + ["name\8"]=> string(8) "testname" - ["name\\9"]=> + ["name\9"]=> string(8) "testname" - ["name\'10"]=> + ["name'10"]=> string(8) "testname" - ["name\\\"11"]=> + ["name\"11"]=> string(8) "testname" - ["name\\12"]=> + ["name\12"]=> string(8) "testname" - ["name\\13"]=> + ["name\13"]=> string(8) "testname" - ["name\\\'14"]=> + ["name\'14"]=> string(8) "testname" - ["name\"15"]=> + ["name"15"]=> string(8) "testname" } diff --git a/tests/basic/bug46313-win.phpt b/tests/basic/bug46313-win.phpt index e588bec767a53..63da7bb67eead 100644 --- a/tests/basic/bug46313-win.phpt +++ b/tests/basic/bug46313-win.phpt @@ -3,9 +3,7 @@ Bug #46313 (Magic quotes broke $_FILES) --SKIPIF-- --INI-- -magic_quotes_gpc=1 file_uploads=1 -register_globals=1 --POST_RAW-- Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737 -----------------------------20896060251896012921717172737 @@ -62,66 +60,3 @@ string(%d) "%s" bool(true) Warning: Directive 'register_globals' is deprecated in PHP 5.3 and greater in Unknown on line 0 Warning: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in Unknown on line 0 - ---TEST-- -Bug #46313 (Magic quotes broke $_FILES) ---SKIPIF-- - ---INI-- -magic_quotes_gpc=1 -file_uploads=1 ---POST_RAW-- -Content-Type: multipart/form-data; boundary=---------------------------20896060251896012921717172737 ------------------------------20896060251896012921717172737 -Content-Disposition: form-data; name="o1'file"; filename="o1'file.png" -Content-Type: text/plain-file1 - -1 ------------------------------20896060251896012921717172737 -Content-Disposition: form-data; name="o2'file"; filename="o2'file2.txt" -Content-Type: text/plain-file2 - -2 ------------------------------20896060251896012921717172737-- ---FILE-- - ---EXPECTF-- -array(2) { - ["o1\'file"]=> - array(5) { - ["name"]=> - string(12) "o1" - ["type"]=> - string(16) "text/plain-file1" - ["tmp_name"]=> - string(14) "%s" - ["error"]=> - int(0) - ["size"]=> - int(1) - } - ["o2\'file"]=> - array(5) { - ["name"]=> - string(13) "o2" - ["type"]=> - string(16) "text/plain-file2" - ["tmp_name"]=> - string(14) "%s" - ["error"]=> - int(0) - ["size"]=> - int(1) - } -} -string(12) "o1" -bool(true) -string(%d) "%s" -bool(true) - From 30aa3cea6a572883ee52fe0996350cb2ca86886b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 1 Aug 2011 03:42:02 +0000 Subject: [PATCH 0434/2394] fix tests --- ext/posix/tests/posix_times_basic.phpt | 10 +++---- .../tests/rfc1867_invalid_settings.phpt | 4 +-- .../tests/rfc1867_invalid_settings_2.phpt | 4 +-- ext/session/tests/session_encode_basic.phpt | 4 ++- ext/standard/tests/file/copy_variation4.phpt | Bin 4654 -> 4966 bytes .../tests/file/parse_ini_file_variation3.phpt | 4 +-- .../tests/file/stream_rfc2397_006.phpt | 7 +++-- .../tests/file/tempnam_variation7.phpt | 8 +++--- .../getservbyname_variation10.phpt | 6 ++++ .../getservbyname_variation9.phpt | 6 ++++ .../general_functions/parse_ini_basic.data | 4 +-- .../general_functions/parse_ini_basic.phpt | 4 +-- .../general_functions/parse_ini_booleans.phpt | 8 +++--- .../tests/general_functions/phpinfo.phpt | 1 - .../general_functions/proc_nice_basic.phpt | 2 +- .../general_functions/proc_nice_error.phpt | 19 +++++++------ .../set_magic_quotes_runtime_basic.phpt | 26 ++++++------------ ext/standard/tests/mail/mail_basic2.phpt | 17 ++++++------ ext/standard/tests/mail/mail_variation2.phpt | 15 +++++----- .../serialization_miscTypes_001.phpt | Bin 7586 -> 7617 bytes ext/standard/tests/streams/bug54623.phpt | 2 ++ .../tests/strings/htmlentities04.phpt | 3 +- 22 files changed, 81 insertions(+), 73 deletions(-) diff --git a/ext/posix/tests/posix_times_basic.phpt b/ext/posix/tests/posix_times_basic.phpt index eb8af10df4092..5da6434b1433b 100644 --- a/ext/posix/tests/posix_times_basic.phpt +++ b/ext/posix/tests/posix_times_basic.phpt @@ -24,14 +24,14 @@ Test posix_times() function : basic functionality Basic test of POSIX times function array(5) { ["ticks"]=> - int(%d) + int(%i) ["utime"]=> - int(%d) + int(%i) ["stime"]=> - int(%d) + int(%i) ["cutime"]=> - int(%d) + int(%i) ["cstime"]=> - int(%d) + int(%i) } ===DONE==== diff --git a/ext/session/tests/rfc1867_invalid_settings.phpt b/ext/session/tests/rfc1867_invalid_settings.phpt index e973a1bd5f21f..29fe630509acc 100644 --- a/ext/session/tests/rfc1867_invalid_settings.phpt +++ b/ext/session/tests/rfc1867_invalid_settings.phpt @@ -9,7 +9,5 @@ session.upload_progress.freq=-1 var_dump(ini_get("session.upload_progress.freq")); ?> --EXPECTF-- -PHP Warning: PHP Startup: session.upload_progress.freq must be greater than or equal to zero in %s - Warning: PHP Startup: session.upload_progress.freq must be greater than or equal to zero in %s -%unicode|string%(%d) "1%" +string(%d) "1%" diff --git a/ext/session/tests/rfc1867_invalid_settings_2.phpt b/ext/session/tests/rfc1867_invalid_settings_2.phpt index 7853a685114d5..bd35852c1dbfb 100644 --- a/ext/session/tests/rfc1867_invalid_settings_2.phpt +++ b/ext/session/tests/rfc1867_invalid_settings_2.phpt @@ -9,7 +9,5 @@ session.upload_progress.freq=200% var_dump(ini_get("session.upload_progress.freq")); ?> --EXPECTF-- -PHP Warning: PHP Startup: session.upload_progress.freq cannot be over 100% in %s - Warning: PHP Startup: session.upload_progress.freq cannot be over 100% in %s -%unicode|string%(%d) "1%" +string(%d) "1%" diff --git a/ext/session/tests/session_encode_basic.phpt b/ext/session/tests/session_encode_basic.phpt index b087f7441404f..dfe40d204d086 100644 --- a/ext/session/tests/session_encode_basic.phpt +++ b/ext/session/tests/session_encode_basic.phpt @@ -1,5 +1,7 @@ --TEST-- Test session_encode() function : basic functionality +--INI-- +serialize_precision=100 --SKIPIF-- --FILE-- @@ -120,7 +122,7 @@ string(13) "data|d:-10.5;" string(20) "data|d:123456789000;" -- Iteration 8 -- -string(29) "data|d:1.2345678899999999E-9;" +string(%d) "data|d:1.2345678899999999145113427164344339914681114578343112953007221221923828125E-9;" -- Iteration 9 -- string(11) "data|d:0.5;" diff --git a/ext/standard/tests/file/copy_variation4.phpt b/ext/standard/tests/file/copy_variation4.phpt index 48386743f325e3cfedaa7712443a6af249aa9593..3c8224da0a917e8284f362c79fb1d050ff02e519 100644 GIT binary patch delta 488 zcmZ3d@=R@m3{MhQcw$jrW?s6LLRw}{YJ6%%W^qZehNePlML}wENwGpfVo_plYDsF5 zf}ui5zCu!}LZU)hVoqiXP^Kh9N1?c+2&h{jJ+mw|Pa!i;LA6*RKTjbiGcQ#^HHFJB z)W>J?bY5j|Ean-JYhJ&g5 - string(5) "30719" + string(5) "32767" ["display_errors"]=> string(1) "1" ["display_startup_errors"]=> @@ -101,4 +101,4 @@ array(11) { ["docref_ext"]=> string(5) ".html" } -===Done=== \ No newline at end of file +===Done=== diff --git a/ext/standard/tests/file/stream_rfc2397_006.phpt b/ext/standard/tests/file/stream_rfc2397_006.phpt index dab6cd5612e2c..e6694a2861628 100755 --- a/ext/standard/tests/file/stream_rfc2397_006.phpt +++ b/ext/standard/tests/file/stream_rfc2397_006.phpt @@ -21,8 +21,11 @@ foreach($streams as $stream) ===DONE=== --EXPECTF-- -string(0) "" -string(6) "foobar" +Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %s line %d +NULL + +Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %s line %d +NULL string(13) "foobar foobar" Warning: file_get_contents(data:;base64,#Zm9vYmFyIGZvb2Jhc=): failed to open stream: rfc2397: unable to decode in %sstream_rfc2397_006.php on line %d diff --git a/ext/standard/tests/file/tempnam_variation7.phpt b/ext/standard/tests/file/tempnam_variation7.phpt index dd823d47a22d3..b21a123ab7774 100644 --- a/ext/standard/tests/file/tempnam_variation7.phpt +++ b/ext/standard/tests/file/tempnam_variation7.phpt @@ -98,19 +98,19 @@ File created in => temp dir Warning: tempnam() expects parameter 1 to be a valid path, string given in %s on line %d -- File is not created -- -Warning: unlink(): Invalid argument in %s on line %d +Warning: unlink(): No such file or directory in %s on line %d -- Iteration 7 -- Warning: tempnam() expects parameter 1 to be a valid path, array given in %s on line %d -- File is not created -- -Warning: unlink(): Invalid argument in %s on line %d +Warning: unlink(): No such file or directory in %s on line %d -- Iteration 8 -- -File name is => /tmp/tempnam_variation3.tmp%s +File name is => %s/tempnam_variation3.tmp%s File permissions are => 100600 File created in => temp dir -- Iteration 9 -- -File name is => /tmp/tempnam_variation3.tmp%s +File name is => %s/tempnam_variation3.tmp%s File permissions are => 100600 File created in => temp dir diff --git a/ext/standard/tests/general_functions/getservbyname_variation10.phpt b/ext/standard/tests/general_functions/getservbyname_variation10.phpt index 70aa5676465c9..c7ed144f109fa 100755 --- a/ext/standard/tests/general_functions/getservbyname_variation10.phpt +++ b/ext/standard/tests/general_functions/getservbyname_variation10.phpt @@ -1,5 +1,11 @@ --TEST-- Test function getservbyname() by substituting argument 2 with emptyUnsetUndefNull values. +--SKIPIF-- + --FILE-- --FILE-- string(51) "asdadfsdjkslkj ¡@£$$ { } !^~|¥¥{[()/)&/% ¤ # #" ["php_constant"]=> - string(5) "30719" + string(1) "2" ["user_constant"]=> string(21) "this_is_test_constant" } @@ -76,7 +76,7 @@ array(26) { ["dqstring"]=> string(41) "asdadfsdjkslkj ¡@£$$€¥¥{[()/)&/%#¤" ["php_constant"]=> - string(5) "30719" + string(1) "2" } ["comments"]=> array(1) { diff --git a/ext/standard/tests/general_functions/parse_ini_booleans.phpt b/ext/standard/tests/general_functions/parse_ini_booleans.phpt index 37965789e081f..7b012c50f6e9d 100644 --- a/ext/standard/tests/general_functions/parse_ini_booleans.phpt +++ b/ext/standard/tests/general_functions/parse_ini_booleans.phpt @@ -15,15 +15,15 @@ array(3) { ["error_reporting values"]=> array(6) { ["foo"]=> - string(7) "30719 8" + string(7) "32767 8" ["error_reporting"]=> - string(5) "30719" + string(5) "32767" ["error_reporting1"]=> string(4) "4177" ["error_reporting2"]=> - string(5) "30711" + string(5) "32759" ["error_reporting3"]=> - string(5) "30711" + string(5) "32759" ["error_reporting4"]=> string(5) "32759" } diff --git a/ext/standard/tests/general_functions/phpinfo.phpt b/ext/standard/tests/general_functions/phpinfo.phpt index 10b8e5531a884..01b0c62c3b5e9 100644 --- a/ext/standard/tests/general_functions/phpinfo.phpt +++ b/ext/standard/tests/general_functions/phpinfo.phpt @@ -36,7 +36,6 @@ Debug Build => %s Thread Safety => %s Zend Signal Handling => %s Zend Memory Manager => %s -Zend Signal Handling => %s Zend Multibyte Support => %s IPv6 Support => %s DTrace Support => %s diff --git a/ext/standard/tests/general_functions/proc_nice_basic.phpt b/ext/standard/tests/general_functions/proc_nice_basic.phpt index 3a958901a240e..83b5165679fe4 100644 --- a/ext/standard/tests/general_functions/proc_nice_basic.phpt +++ b/ext/standard/tests/general_functions/proc_nice_basic.phpt @@ -13,7 +13,7 @@ if(!function_exists('proc_nice')) die("skip. proc_nice not available "); 2) return $matches[2]; diff --git a/ext/standard/tests/general_functions/proc_nice_error.phpt b/ext/standard/tests/general_functions/proc_nice_error.phpt index 09f84fa552a13..a05a18263ec87 100644 --- a/ext/standard/tests/general_functions/proc_nice_error.phpt +++ b/ext/standard/tests/general_functions/proc_nice_error.phpt @@ -6,20 +6,23 @@ if(!function_exists('proc_nice')) die("skip. proc_nice not available "); ?> --FILE-- --EXPECTF-- -Parse error: syntax error, unexpected T_VARIABLE, expecting ',' or ';' in %s on line %d +*** Test by calling method or function with incorrect numbers of arguments *** + +Warning: proc_nice() expects exactly 1 parameter, 2 given in %s line %d +bool(false) + +Warning: proc_nice() expects exactly 1 parameter, 0 given in %s line %d +bool(false) diff --git a/ext/standard/tests/general_functions/set_magic_quotes_runtime_basic.phpt b/ext/standard/tests/general_functions/set_magic_quotes_runtime_basic.phpt index eb647435ac97b..3e5f6f0ff7420 100644 --- a/ext/standard/tests/general_functions/set_magic_quotes_runtime_basic.phpt +++ b/ext/standard/tests/general_functions/set_magic_quotes_runtime_basic.phpt @@ -13,11 +13,6 @@ echo "Simple testcase for set_magic_quotes_runtime() function - basic test\n"; $g = get_magic_quotes_runtime(); echo "\n-- magic quotes runtime set in INI file: " . $g . "--\n"; -echo "\n-- Set magic quotes runtime to 1: --\n"; -var_dump(set_magic_quotes_runtime(1)); -$g = get_magic_quotes_runtime(); -echo "\n-- magic quotes runtime after set: " . $g . " --\n"; - echo "\n-- Set magic quotes runtime to 0: --\n"; var_dump(set_magic_quotes_runtime(0)); $g = get_magic_quotes_runtime(); @@ -33,26 +28,23 @@ echo "\n-- magic quotes runtime after set: " . $g . " --\n"; --EXPECTF-- Simple testcase for set_magic_quotes_runtime() function - basic test --- magic quotes runtime set in INI file: 0-- - --- Set magic quotes runtime to 1: -- - -Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) +Deprecated: Function get_magic_quotes_runtime() is deprecated in %s on line %d --- magic quotes runtime after set: 1 -- +-- magic quotes runtime set in INI file: -- -- Set magic quotes runtime to 0: -- Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) +bool(false) --- magic quotes runtime after set: 0 -- +Deprecated: Function get_magic_quotes_runtime() is deprecated in %s on line %d + +-- magic quotes runtime after set: -- -- Set magic quotes runtime to 1: -- Deprecated: Function set_magic_quotes_runtime() is deprecated in %s on line %d -bool(true) --- magic quotes runtime after set: 1 -- -===DONE=== \ No newline at end of file +Fatal error: set_magic_quotes_runtime(): magic_quotes_runtime is not supported anymore in Unknown on line 0 + + diff --git a/ext/standard/tests/mail/mail_basic2.phpt b/ext/standard/tests/mail/mail_basic2.phpt index 2ac4d20b1f7a2..8967d18c4f094 100644 --- a/ext/standard/tests/mail/mail_basic2.phpt +++ b/ext/standard/tests/mail/mail_basic2.phpt @@ -6,7 +6,7 @@ if(substr(PHP_OS, 0, 3) == "WIN") die("skip Won't run on Windows"); ?> --INI-- -sendmail_path="sed > /tmp/php_test_mailBasic2.out" +sendmail_path="cat > /tmp/php_test_mailBasic2.out" mail.add_x_header = Off --FILE-- ===DONE=== ---EXPECT-- +--EXPECTF-- *** Testing mail() : basic functionality *** -- extra parameters -- bool(true) -To: user@company.com -Subject: Test Subject -KHeaders - -A Message ---- Extras +%w1%wTo: user@company.com +%w2%wSubject: Test Subject +%w3%wKHeaders +%w4%w +%w5%wA Message ===DONE=== diff --git a/ext/standard/tests/mail/mail_variation2.phpt b/ext/standard/tests/mail/mail_variation2.phpt index d6eafd2e5240f..c16c2706a77a4 100644 --- a/ext/standard/tests/mail/mail_variation2.phpt +++ b/ext/standard/tests/mail/mail_variation2.phpt @@ -1,8 +1,8 @@ --TEST-- Test mail() function : variation force extra parameters --INI-- -sendmail_path="sed > /tmp/php_test_mailVariation2.out" -mail.force_extra_parameters="-e4a---forced-params" +sendmail_path="cat > /tmp/php_test_mailVariation2.out" +mail.force_extra_parameters="-n" mail.add_x_header = Off --SKIPIF-- ===DONE=== ---EXPECT-- +--EXPECTF-- *** Testing mail() : basic functionality *** bool(true) -To: user@company.com -Subject: Test Subject - -A Message ----forced-params +%w1%wTo: user@company.com +%w2%wSubject: Test Subject +%w3%w +%w4%wA Message ===DONE=== diff --git a/ext/standard/tests/serialize/serialization_miscTypes_001.phpt b/ext/standard/tests/serialize/serialization_miscTypes_001.phpt index 038068249effa2c720ddfcc39512f7a6050ea5d5..548a67345f996a18483732433e5aab8a01a50f7a 100644 GIT binary patch delta 46 zcmZ2veb9P>lZ>aIr>-tnacWU!VoqjNYJ5RaYI0_AW`3Tnq4`GpuY!ywn@xpsxdDl7 B5J3O{ delta 17 YcmX?Ty~uik)5gS4f{bRHLxgg<0Yg>>i2wiq diff --git a/ext/standard/tests/streams/bug54623.phpt b/ext/standard/tests/streams/bug54623.phpt index cd83854f43222..63e907a5af2b4 100644 --- a/ext/standard/tests/streams/bug54623.phpt +++ b/ext/standard/tests/streams/bug54623.phpt @@ -14,4 +14,6 @@ fwrite($sock, "3"); int(%d) int(%d) +Notice: fwrite(): send of 1 bytes failed with errno=61 Connection refused in %s on line %d + Warning: fwrite(): %d is not a valid stream resource in %s on line %d diff --git a/ext/standard/tests/strings/htmlentities04.phpt b/ext/standard/tests/strings/htmlentities04.phpt index 565c11bbc8dda..2501ff092ced4 100644 --- a/ext/standard/tests/strings/htmlentities04.phpt +++ b/ext/standard/tests/strings/htmlentities04.phpt @@ -16,5 +16,6 @@ mbstring.internal_encoding=pass setlocale( LC_CTYPE, "ja_JP.EUC-JP", "ja_JP.eucJP" ); var_dump(htmlentities("\xa1\xa2\xa1\xa3\xa1\xa4", ENT_QUOTES, '')); ?> ---EXPECT-- +--EXPECTF-- +Strict Standards: htmlentities(): Only basic entities substitution is supported for multi-byte encodings other than UTF-8; functionality is equivalent to htmlspecialchars in %s line %d string(6) "¡¢¡£¡¤" From 5c42cde3cb3daf7d001d6fe86fba05e311be1cfa Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 1 Aug 2011 04:29:37 +0000 Subject: [PATCH 0435/2394] fix params parsing --- ext/dom/document.c | 3 ++- ext/interbase/interbase.c | 3 ++- ext/ldap/ldap.c | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/dom/document.c b/ext/dom/document.c index b5402472b793a..393f178882000 100644 --- a/ext/dom/document.c +++ b/ext/dom/document.c @@ -2157,7 +2157,8 @@ static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */ dom_object *intern; dom_doc_propsptr doc_prop; char *source; - int source_len, refcount, ret, options = 0; + int source_len, refcount, ret; + long options = 0; htmlParserCtxtPtr ctxt; id = getThis(); diff --git a/ext/interbase/interbase.c b/ext/interbase/interbase.c index 6578469852ceb..10d3a848072b0 100644 --- a/ext/interbase/interbase.c +++ b/ext/interbase/interbase.c @@ -1125,7 +1125,8 @@ PHP_FUNCTION(ibase_drop_db) PHP_FUNCTION(ibase_trans) { - unsigned short i, argn, link_cnt = 0, tpb_len = 0; + unsigned short i, link_cnt = 0, tpb_len = 0; + int argn; char last_tpb[TPB_MAX_SIZE]; ibase_db_link **ib_link = NULL; ibase_trans *ib_trans; diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c index 04caa86da7d07..fa0a9f12794c2 100644 --- a/ext/ldap/ldap.c +++ b/ext/ldap/ldap.c @@ -587,7 +587,7 @@ static void php_set_opts(LDAP *ldap, int sizelimit, int timelimit, int deref, in */ static void php_ldap_do_search(INTERNAL_FUNCTION_PARAMETERS, int scope) { - zval *link, *base_dn, **filter, *attrs, **attr; + zval *link, *base_dn, **filter, *attrs = NULL, **attr; long attrsonly, sizelimit, timelimit, deref; char *ldap_base_dn = NULL, *ldap_filter = NULL, **ldap_attrs = NULL; ldap_linkdata *ld = NULL; From 8ff0701e8d40171aae71d4650f515ba83e574566 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 1 Aug 2011 11:21:23 +0000 Subject: [PATCH 0436/2394] Fixed bug #50816 (Using class constants in array definition fails). --- Zend/tests/bug45742.phpt | 2 +- Zend/tests/bug50816.phpt | 48 +++++++++ Zend/zend_hash.c | 206 +++++++++++++++++++++++---------------- 3 files changed, 173 insertions(+), 83 deletions(-) create mode 100644 Zend/tests/bug50816.phpt diff --git a/Zend/tests/bug45742.phpt b/Zend/tests/bug45742.phpt index b21e093049eac..bde690b39acbf 100644 --- a/Zend/tests/bug45742.phpt +++ b/Zend/tests/bug45742.phpt @@ -20,5 +20,5 @@ var_dump( ArrayProperty::$array ); --EXPECT-- array(1) { [1]=> - int(23) + int(42) } diff --git a/Zend/tests/bug50816.phpt b/Zend/tests/bug50816.phpt new file mode 100644 index 0000000000000..98a89380c3011 --- /dev/null +++ b/Zend/tests/bug50816.phpt @@ -0,0 +1,48 @@ +--TEST-- +Bug #50816 (Using class constants in array definition fails) +--FILE-- + 'one', self::TWO => 'two',); + + public static $mapWithConst1 = array(1 => 'one', self::TWO => 'two',); + public static $mapWithConst2 = array(self::ONE => 'one', 1 => 'two',); + + public static $mapWithoutConst = array(1 => 'one', 1 => 'two',); +} + +$mapWithConst = array(1 => 'one', 1 => 'two',); + +$mapWithoutConst = array(Foo::ONE => 'one', Foo::TWO => 'two',); +$mapWithoutConst0 = array(1 => 'one', 1 => 'two',); +$mapWithoutConst1 = array(ONE => 'one', 1 => 'two',); +$mapWithoutConst2 = array(1 => 'one', TWO => 'two',); +$mapWithoutConst3 = array(ONE => 'one', TWO => 'two',); + +var_dump(Foo::$mapWithConst[1]); +var_dump(Foo::$mapWithConst1[1]); +var_dump(Foo::$mapWithConst2[1]); +var_dump(Foo::$mapWithoutConst[1]); +var_dump($mapWithConst[1]); +var_dump($mapWithoutConst[1]); +var_dump($mapWithoutConst0[1]); +var_dump($mapWithoutConst1[1]); +var_dump($mapWithoutConst2[1]); +var_dump($mapWithoutConst3[1]); +--EXPECT-- +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" +string(3) "two" diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index ec08f89bed716..3585dbee058c2 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -1211,8 +1211,9 @@ ZEND_API int zend_hash_get_current_data_ex(HashTable *ht, void **pData, HashPosi */ ZEND_API int zend_hash_update_current_key_ex(HashTable *ht, int key_type, const char *str_index, uint str_length, ulong num_index, int mode, HashPosition *pos) { - Bucket *p; -#ifdef ZEND_SIGNALS + Bucket *p, *q; + ulong h; +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif @@ -1227,105 +1228,142 @@ ZEND_API int zend_hash_update_current_key_ex(HashTable *ht, int key_type, const return SUCCESS; } - if (mode != HASH_UPDATE_KEY_ANYWAY) { - Bucket *q = ht->arBuckets[num_index & ht->nTableMask]; - int found = 0; - - while (q != NULL) { - if (q == p) { - found = 1; - } else if (!q->nKeyLength && q->h == num_index) { - if (found) { - if (mode & HASH_UPDATE_KEY_IF_BEFORE) { - break; - } else { - if (p->nKeyLength) { - zend_hash_del(ht, p->arKey, p->nKeyLength); - } else { - zend_hash_index_del(ht, p->h); - } - return FAILURE; - } - } else { - if (mode & HASH_UPDATE_KEY_IF_AFTER) { - break; - } else { - if (p->nKeyLength) { - zend_hash_del(ht, p->arKey, p->nKeyLength); - } else { - zend_hash_index_del(ht, p->h); - } - return FAILURE; - } - } - } - q = q->pNext; + q = ht->arBuckets[num_index & ht->nTableMask]; + while (q != NULL) { + if (!q->nKeyLength && q->h == num_index) { + break; } + q = q->pNext; } - - zend_hash_index_del(ht, num_index); } else if (key_type == HASH_KEY_IS_STRING) { - if (p->nKeyLength == str_length && - memcmp(p->arKey, str_index, str_length) == 0) { + if (IS_INTERNED(str_index)) { + h = INTERNED_HASH(str_index); + } else { + h = zend_inline_hash_func(str_index, str_length); + } + + if (p->arKey == str_index || + (p->nKeyLength == str_length && + p->h == h && + memcmp(p->arKey, str_index, str_length) == 0)) { return SUCCESS; } - if (mode != HASH_UPDATE_KEY_ANYWAY) { - ulong h = zend_inline_hash_func(str_index, str_length); - Bucket *q = ht->arBuckets[h & ht->nTableMask]; - int found = 0; - - while (q != NULL) { - if (q == p) { - found = 1; - } else if (q->h == h && q->nKeyLength == str_length && - memcmp(q->arKey, str_index, str_length) == 0) { - if (found) { - if (mode & HASH_UPDATE_KEY_IF_BEFORE) { - break; - } else { - if (p->nKeyLength) { - zend_hash_del(ht, p->arKey, p->nKeyLength); - } else { - zend_hash_index_del(ht, p->h); - } - return FAILURE; - } - } else { - if (mode & HASH_UPDATE_KEY_IF_AFTER) { - break; - } else { - if (p->nKeyLength) { - zend_hash_del(ht, p->arKey, p->nKeyLength); - } else { - zend_hash_index_del(ht, p->h); - } - return FAILURE; - } - } - } - q = q->pNext; + q = ht->arBuckets[h & ht->nTableMask]; + + while (q != NULL) { + if (q->arKey == str_index || + (q->h == h && q->nKeyLength == str_length && + memcmp(q->arKey, str_index, str_length) == 0)) { + break; } + q = q->pNext; } - - zend_hash_del(ht, str_index, str_length); } else { return FAILURE; } HANDLE_BLOCK_INTERRUPTIONS(); + if (q) { + if (mode != HASH_UPDATE_KEY_ANYWAY) { + Bucket *r = p->pListLast; + int found = HASH_UPDATE_KEY_IF_BEFORE; + + while (r) { + if (r == q) { + found = HASH_UPDATE_KEY_IF_AFTER; + break; + } + r = r->pListLast; + } + if (mode & found) { + /* delete current bucket */ + if (p == ht->arBuckets[p->h & ht->nTableMask]) { + ht->arBuckets[p->h & ht->nTableMask] = p->pNext; + } else { + p->pLast->pNext = p->pNext; + } + if (p->pNext) { + p->pNext->pLast = p->pLast; + } + if (p->pListLast != NULL) { + p->pListLast->pListNext = p->pListNext; + } else { + /* Deleting the head of the list */ + ht->pListHead = p->pListNext; + } + if (p->pListNext != NULL) { + p->pListNext->pListLast = p->pListLast; + } else { + ht->pListTail = p->pListLast; + } + if (ht->pInternalPointer == p) { + ht->pInternalPointer = p->pListNext; + } + if (ht->pDestructor) { + ht->pDestructor(p->pData); + } + if (p->pData != &p->pDataPtr) { + pefree(p->pData, ht->persistent); + } + pefree(p, ht->persistent); + ht->nNumOfElements--; + HANDLE_UNBLOCK_INTERRUPTIONS(); + return FAILURE; + } + } + /* delete another bucket with the same key */ + if (q == ht->arBuckets[q->h & ht->nTableMask]) { + ht->arBuckets[q->h & ht->nTableMask] = q->pNext; + } else { + q->pLast->pNext = q->pNext; + } + if (q->pNext) { + q->pNext->pLast = q->pLast; + } + if (q->pListLast != NULL) { + q->pListLast->pListNext = q->pListNext; + } else { + /* Deleting the head of the list */ + ht->pListHead = q->pListNext; + } + if (q->pListNext != NULL) { + q->pListNext->pListLast = q->pListLast; + } else { + ht->pListTail = q->pListLast; + } + if (ht->pInternalPointer == q) { + ht->pInternalPointer = q->pListNext; + } + if (ht->pDestructor) { + ht->pDestructor(q->pData); + } + if (q->pData != &q->pDataPtr) { + pefree(q->pData, ht->persistent); + } + pefree(q, ht->persistent); + ht->nNumOfElements--; + } + if (p->pNext) { p->pNext->pLast = p->pLast; } if (p->pLast) { p->pLast->pNext = p->pNext; - } else{ + } else { ht->arBuckets[p->h & ht->nTableMask] = p->pNext; } - if (p->nKeyLength != str_length) { - Bucket *q = (Bucket *) pemalloc(sizeof(Bucket) + str_length, ht->persistent); + if ((IS_INTERNED(p->arKey) != IS_INTERNED(str_index)) || + (!IS_INTERNED(p->arKey) && p->nKeyLength != str_length)) { + Bucket *q; + + if (IS_INTERNED(str_index)) { + q = (Bucket *) pemalloc(sizeof(Bucket), ht->persistent); + } else { + q = (Bucket *) pemalloc(sizeof(Bucket) + str_length, ht->persistent); + } q->nKeyLength = str_length; if (p->pData == &p->pDataPtr) { @@ -1359,9 +1397,13 @@ ZEND_API int zend_hash_update_current_key_ex(HashTable *ht, int key_type, const if (key_type == HASH_KEY_IS_LONG) { p->h = num_index; } else { - p->arKey = (char*)(p+1); - memcpy(p->arKey, str_index, str_length); - p->h = zend_inline_hash_func(str_index, str_length); + p->h = h; + if (IS_INTERNED(str_index)) { + p->arKey = str_index; + } else { + p->arKey = (char*)(p+1); + memcpy(p->arKey, str_index, str_length); + } } CONNECT_TO_BUCKET_DLLIST(p, ht->arBuckets[p->h & ht->nTableMask]); From 74f68932b7381e0930d05428128ea360559c77fa Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 1 Aug 2011 12:08:44 +0000 Subject: [PATCH 0437/2394] Added support for Class::{expr}() syntax (Pierrick) --- Zend/tests/bug55247.phpt | 33 +++++++++++++++++++++++++++++++++ Zend/zend_language_parser.y | 4 ++-- 2 files changed, 35 insertions(+), 2 deletions(-) create mode 100644 Zend/tests/bug55247.phpt diff --git a/Zend/tests/bug55247.phpt b/Zend/tests/bug55247.phpt new file mode 100644 index 0000000000000..6fa893f892c47 --- /dev/null +++ b/Zend/tests/bug55247.phpt @@ -0,0 +1,33 @@ +--TEST-- +Request #55247 (Parser problem with static calls using string method name) +--FILE-- +method(); +$test->$method(); +$test->{'method'}(); + +Test::method(); +Test::$method(); +Test::{'method'}(); +--EXPECT-- +method +method +method +method +method +method diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index f89c1f121cb5f..ef390ffd5606d 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -797,13 +797,13 @@ function_call: | T_NS_SEPARATOR namespace_name '(' { $3.u.op.opline_num = zend_do_begin_function_call(&$2, 0 TSRMLS_CC); } function_call_parameter_list ')' { zend_do_end_function_call(&$2, &$$, &$5, 0, $3.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } - | class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING '(' { $4.u.op.opline_num = zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } + | class_name T_PAAMAYIM_NEKUDOTAYIM variable_name '(' { $4.u.op.opline_num = zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } function_call_parameter_list ')' { zend_do_end_function_call($4.u.op.opline_num?NULL:&$3, &$$, &$6, $4.u.op.opline_num, $4.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} | class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects '(' { zend_do_end_variable_parse(&$3, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } function_call_parameter_list ')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} - | variable_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING '(' { zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } + | variable_class_name T_PAAMAYIM_NEKUDOTAYIM variable_name '(' { zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } function_call_parameter_list ')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} | variable_class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects '(' { zend_do_end_variable_parse(&$3, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } From d4a80cfa8d7b2a5f30976c144efa33b3d159622a Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 1 Aug 2011 15:23:16 +0000 Subject: [PATCH 0438/2394] Fixed bug #55305 (ref lost: 1st ref instantiated in class def, 2nd ref made w/o instantiating) --- Zend/tests/bug55305.phpt | 16 ++++++++++++++++ Zend/zend_vm_def.h | 2 ++ Zend/zend_vm_execute.h | 24 ++++++++++++++++++++++++ 3 files changed, 42 insertions(+) create mode 100644 Zend/tests/bug55305.phpt diff --git a/Zend/tests/bug55305.phpt b/Zend/tests/bug55305.phpt new file mode 100644 index 0000000000000..7f0749a315259 --- /dev/null +++ b/Zend/tests/bug55305.phpt @@ -0,0 +1,16 @@ +--TEST-- +Bug #55305 (ref lost: 1st ref instantiated in class def, 2nd ref made w/o instantiating) +--FILE-- +bar =& $f->foo; +var_dump($f->foo); +var_dump($f->bar); +?> +--EXPECT-- +string(4) "test" +string(4) "test" diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index cdc6456282b78..3901b3804f76f 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1417,6 +1417,8 @@ ZEND_VM_HANDLER(85, ZEND_FETCH_OBJ_W, VAR|UNUSED|CV, CONST|TMP|VAR|CV) Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 039d199d47416..5b336256f7e0c 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -12736,6 +12736,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -14875,6 +14877,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -16935,6 +16939,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -19999,6 +20005,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -21596,6 +21604,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -22835,6 +22845,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_H Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -23983,6 +23995,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_H Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -25399,6 +25413,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HA Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -28303,6 +28319,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -30225,6 +30243,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -32159,6 +32179,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); @@ -34960,6 +34982,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE Z_DELREF_PP(retval_ptr); SEPARATE_ZVAL_TO_MAKE_IS_REF(retval_ptr); Z_ADDREF_PP(retval_ptr); + EX_T(opline->result.var).var.ptr = *EX_T(opline->result.var).var.ptr_ptr; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } CHECK_EXCEPTION(); From 3bd0db004e3d61db4ba1039ad71a03619ce69c92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= Date: Tue, 2 Aug 2011 00:58:51 +0000 Subject: [PATCH 0439/2394] - Fixed bug #55340 (segfault when using some arguments -- bug introduced by commit r313351) --- sapi/fpm/fpm/fpm_main.c | 54 ++++++++++++++++++++++++++++++++++------- 1 file changed, 45 insertions(+), 9 deletions(-) diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index f9c15ba7e2f80..752a8c85d440a 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -125,6 +125,7 @@ static int parent = 1; #endif static int request_body_fd; +static int fpm_is_running = 0; static char *sapi_cgibin_getenv(char *name, size_t name_len TSRMLS_DC); static void fastcgi_ini_parser(zval *arg1, zval *arg2, zval *arg3, int callback_type, void *arg TSRMLS_DC); @@ -261,16 +262,34 @@ static void print_extensions(TSRMLS_D) zend_llist_destroy(&sorted_exts); } +#ifndef STDOUT_FILENO +#define STDOUT_FILENO 1 +#endif + static inline size_t sapi_cgibin_single_write(const char *str, uint str_length TSRMLS_DC) { - long ret; + size_t ret; - fcgi_request *request = (fcgi_request*) SG(server_context); - ret = fcgi_write(request, FCGI_STDOUT, str, str_length); + /* sapi has started which means everyhting must be send through fcgi */ + if (fpm_is_running) { + fcgi_request *request = (fcgi_request*) SG(server_context); + ret = fcgi_write(request, FCGI_STDOUT, str, str_length); + if (ret <= 0) { + return 0; + } + return ret; + } + + /* sapi has not started, output to stdout instead of fcgi */ +#ifdef PHP_WRITE_STDOUT + ret = write(STDOUT_FILENO, str, str_length); if (ret <= 0) { return 0; } return ret; +#else + return fwrite(str, 1, MIN(str_length, 16384), stdout); +#endif } static int sapi_cgibin_ub_write(const char *str, uint str_length TSRMLS_DC) @@ -295,12 +314,21 @@ static int sapi_cgibin_ub_write(const char *str, uint str_length TSRMLS_DC) static void sapi_cgibin_flush(void *server_context) { - fcgi_request *request = (fcgi_request*) server_context; - if ( + /* fpm has started, let use fcgi instead of stdout */ + if (fpm_is_running) { + fcgi_request *request = (fcgi_request*) server_context; + if ( #ifndef PHP_WIN32 - !parent && + !parent && #endif - request && !fcgi_flush(request, 0)) { + request && !fcgi_flush(request, 0)) { + php_handle_aborted_connection(); + } + return; + } + + /* fpm has not started yet, let use stdout instead of fcgi */ + if (fflush(stdout) == EOF) { php_handle_aborted_connection(); } } @@ -498,8 +526,14 @@ static int sapi_cgi_read_post(char *buffer, uint count_bytes TSRMLS_DC) static char *sapi_cgibin_getenv(char *name, size_t name_len TSRMLS_DC) { - fcgi_request *request = (fcgi_request*) SG(server_context); - return fcgi_getenv(request, name, name_len); + /* if fpm has started, use fcgi env */ + if (fpm_is_running) { + fcgi_request *request = (fcgi_request*) SG(server_context); + return fcgi_getenv(request, name, name_len); + } + + /* if fpm has not started yet, use std env */ + return getenv(name); } static char *_sapi_cgibin_putenv(char *name, char *value TSRMLS_DC) @@ -1727,6 +1761,8 @@ consult the installation file that came with this distribution, or visit \n\ return FAILURE; } + fpm_is_running = 1; + fcgi_fd = fpm_run(&max_requests); parent = 0; From 17dc1d261054ea0845a40f5c7737d9bec20f0e22 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Tue, 2 Aug 2011 02:42:41 +0000 Subject: [PATCH 0440/2394] updated libmbfl for version 1.3.0. --- ext/mbstring/libmbfl/filters/Makefile.am | 17 +- ext/mbstring/libmbfl/filters/emoji2uni.h | 1155 +++++++++++++++++ .../libmbfl/filters/mbfilter_cp5022x.c | 7 +- .../libmbfl/filters/mbfilter_sjis_mac.c | 865 ++++++++++++ .../libmbfl/filters/mbfilter_sjis_mac.h | 45 + .../libmbfl/filters/mbfilter_sjis_mobile.c | 1103 ++++++++++++++++ .../libmbfl/filters/mbfilter_sjis_mobile.h | 64 + ext/mbstring/libmbfl/filters/mk_emoji_tbl.pl | 425 ++++++ ext/mbstring/libmbfl/filters/sjis_mac2uni.h | 214 +++ ext/mbstring/libmbfl/mbfl/eaw_table.h | 32 +- ext/mbstring/libmbfl/mbfl/mbfilter.h | 2 +- ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 18 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 10 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 8 + ext/mbstring/libmbfl/mbfl/mbfl_ident.c | 1 + ext/mbstring/libmbfl/mbfl/mk_eaw_tbl.awk | 7 +- ext/mbstring/libmbfl/tests/emoji.c | 119 ++ 17 files changed, 4069 insertions(+), 23 deletions(-) create mode 100644 ext/mbstring/libmbfl/filters/emoji2uni.h create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h create mode 100755 ext/mbstring/libmbfl/filters/mk_emoji_tbl.pl create mode 100644 ext/mbstring/libmbfl/filters/sjis_mac2uni.h create mode 100644 ext/mbstring/libmbfl/tests/emoji.c diff --git a/ext/mbstring/libmbfl/filters/Makefile.am b/ext/mbstring/libmbfl/filters/Makefile.am index 99df73b8dcc2d..d4d781c3dfc27 100644 --- a/ext/mbstring/libmbfl/filters/Makefile.am +++ b/ext/mbstring/libmbfl/filters/Makefile.am @@ -1,6 +1,7 @@ EXTRA_DIST=mk_sb_tbl.awk noinst_LTLIBRARIES=libmbfl_filters.la INCLUDES=-I../mbfl +PERL=perl libmbfl_filters_la_LDFLAGS=-version-info $(SHLIB_VERSION) libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_hz.c \ @@ -33,6 +34,8 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_base64.c \ mbfilter_sjis.c \ mbfilter_sjis_open.c \ + mbfilter_sjis_mobile.c \ + mbfilter_sjis_mac.c \ mbfilter_7bit.c \ mbfilter_qprint.c \ mbfilter_ucs4.c \ @@ -102,6 +105,8 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_qprint.h \ mbfilter_sjis.h \ mbfilter_sjis_open.h \ + mbfilter_sjis_mobile.h \ + mbfilter_sjis_mac.h \ mbfilter_ucs2.h \ mbfilter_ucs4.h \ mbfilter_uhc.h \ @@ -143,7 +148,9 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ unicode_table_armscii8.h \ unicode_table_cp850.h \ unicode_table_uhc.h \ - translit_kana_jisx0201_jisx0208.h + translit_kana_jisx0201_jisx0208.h \ + emoji2uni.h \ + sjis_mac2uni.h mbfilter_iso8859_2.c: unicode_table_iso8859_2.h @@ -238,8 +245,14 @@ unicode_table_iso8859_16.h: mk_sb_tbl.awk $(AWK) -v TABLE_NAME=iso8859_16_ucs_table \ -v IFNDEF_NAME=UNICODE_TABLEISO8859_16_H -f mk_sb_tbl.awk 8859-16.TXT > $@ +EmojiSources.txt : + $(FETCH_VIA_FTP) ftp://ftp.unicode.org/Public/UNIDATA/$@ + +emoji2uni.h : mk_emoji_tbl.pl + $(PERL) mk_emoji_tbl.pl EmojiSources.txt + unidata: 8859-1.TXT 8859-2.TXT 8859-3.TXT 8859-4.TXT 8859-5.TXT 8859-6.TXT \ 8859-7.TXT 8859-8.TXT 8859-9.TXT 8859-10.TXT 8859-11.TXT 8859-13.TXT \ -8859-14.TXT 8859-15.TXT 8859-16.TXT +8859-14.TXT 8859-15.TXT 8859-16.TXT EmojiSources.txt .PHONY: unidata diff --git a/ext/mbstring/libmbfl/filters/emoji2uni.h b/ext/mbstring/libmbfl/filters/emoji2uni.h new file mode 100644 index 0000000000000..99c7cc2d9d86c --- /dev/null +++ b/ext/mbstring/libmbfl/filters/emoji2uni.h @@ -0,0 +1,1155 @@ +const int mb_tbl_code2uni_docomo1_min = 0x28c2; +const int mb_tbl_code2uni_docomo1_max = 0x29db; + +const int mb_tbl_code2uni_docomo1[] = { // 0x28c2 - 0x29db + 0x02600, 0x02601, 0x02614, 0x026c4, + 0x026a1, 0x1f300, 0x1f301, 0x1f302, + 0x02648, 0x02649, 0x0264a, 0x0264b, + 0x0264c, 0x0264d, 0x0264e, 0x0264f, + 0x02650, 0x02651, 0x02652, 0x02653, + 0x1f3bd, 0x026be, 0x026f3, 0x1f3be, + 0x026bd, 0x1f3bf, 0x1f3c0, 0x1f3c1, + 0x1f4df, 0x1f683, 0x024c2, 0x1f684, + 0x1f697, 0x1f699, 0x1f68c, 0x1f6a2, + 0x02708, 0x1f3e0, 0x1f3e2, 0x1f3e3, + 0x1f3e5, 0x1f3e6, 0x1f3e7, 0x1f3e8, + 0x1f3ea, 0x026fd, 0x1f17f, 0x1f6a5, + 0x1f6bb, 0x1f374, 0x02615, 0x1f378, + 0x1f37a, 0x1f354, 0x1f460, 0x02702, + 0x1f3a4, 0x1f3a5, 0x02197, 0x1f3a0, + 0x1f3a7, 0x1f3a8, 0x1f3a9, 0x1f3aa, + 0x1f3ab, 0x1f6ac, 0x1f6ad, 0x1f4f7, + 0x1f45c, 0x1f4d6, 0x1f380, 0x1f381, + 0x1f382, 0x0260e, 0x1f4f1, 0x1f4dd, + 0x1f4fa, 0x1f3ae, 0x1f4bf, 0x02665, + 0x02660, 0x02666, 0x02663, 0x1f440, + 0x1f442, 0x0270a, 0x0270c, 0x0270b, + 0x02198, 0x02196, 0x1f463, 0x1f45f, + 0x1f453, 0x0267f, 0x1f311, 0x1f314, + 0x1f313, 0x1f319, 0x1f315, 0x1f436, + 0x1f431, 0x026f5, 0x1f384, 0x02199, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x1f3ac, 0x1f45d, + 0x02712, 0x00000, 0x00000, 0x1f464, + 0x1f4ba, 0x1f303, 0x00000, 0x00000, + 0x00000, 0x1f51c, 0x1f51b, 0x1f51a, + 0x023f0, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x1f4f2, 0x1f4e9, 0x1f4e0, 0x00000, + 0x00000, 0x02709, 0x00000, 0x00000, + 0x1f4b4, 0x1f193, 0x1f194, 0x1f511, + 0x021a9, 0x1f191, 0x1f50d, 0x1f195, + 0x1f6a9, 0x00000, 0x00023, 0x00000, + 0x00031, 0x00032, 0x00033, 0x00034, + 0x00035, 0x00036, 0x00037, 0x00038, + 0x00039, 0x00030, 0x02764, 0x1f493, + 0x1f494, 0x1f495, 0x1f603, 0x1f620, + 0x1f61e, 0x1f616, 0x1f635, 0x02934, + 0x1f3b5, 0x02668, 0x1f4a0, 0x1f48b, + 0x02728, 0x1f4a1, 0x1f4a2, 0x1f44a, + 0x1f4a3, 0x1f3b6, 0x02935, 0x1f4a4, + 0x02757, 0x02049, 0x0203c, 0x1f4a5, + 0x1f4a6, 0x1f4a7, 0x1f4a8, 0x03030, + 0x027b0, 0x1f197, 0x00000, 0x00000, + 0x1f455, 0x1f45b, 0x1f484, 0x1f456, + 0x1f3c2, 0x1f514, 0x1f6aa, 0x1f4b0, + 0x1f4bb, 0x1f48c, 0x1f527, 0x0270f, + 0x1f451, 0x1f48d, 0x023f3, 0x1f6b2, + 0x1f375, 0x0231a, 0x1f614, 0x1f60c, + 0x1f605, 0x1f613, 0x1f621, 0x1f612, + 0x1f60d, 0x1f44d, 0x1f61c, 0x1f609, + 0x1f606, 0x1f623, 0x1f60f, 0x1f62d, + 0x1f622, 0x1f196, 0x1f4ce, 0x000a9, + 0x02122, 0x1f3c3, 0x03299, 0x0267b, + 0x000ae, 0x026a0, 0x1f232, 0x1f233, + 0x1f234, 0x1f235, 0x02194, 0x02195, + 0x1f3eb, 0x1f30a, 0x1f5fb, 0x1f340, + 0x1f352, 0x1f337, 0x1f34c, 0x1f34e, + 0x1f331, 0x1f341, 0x1f338, 0x1f359, + 0x1f370, 0x1f376, 0x1f35c, 0x1f35e, + 0x1f40c, 0x1f424, 0x1f427, 0x1f41f, + 0x1f60b, 0x1f601, 0x1f434, 0x1f437, + 0x1f377, 0x1f631, }; + +const int mb_tbl_code2uni_kddi1_min = 0x24b8; +const int mb_tbl_code2uni_kddi1_max = 0x25c0; + +const int mb_tbl_code2uni_kddi1[] = { // 0x24b8 - 0x25c0 + 0x1f342, 0x1f4bc, 0x026f2, 0x026fa, + 0x1f004, 0x1f19a, 0x1f3c6, 0x1f422, + 0x1f1ea, 0x1f1f7, 0x1f6a7, 0x1f6c0, + 0x1f38c, 0x1f306, 0x1f423, 0x1f4b9, + 0x1f46e, 0x1f3e3, 0x1f3e5, 0x1f3eb, + 0x1f3e8, 0x1f6a2, 0x1f51e, 0x1f4f6, + 0x1f192, 0x1f239, 0x1f202, 0x1f194, + 0x1f235, 0x1f233, 0x1f22f, 0x1f23a, + 0x1f446, 0x1f447, 0x1f52e, 0x1f4f3, + 0x1f4f4, 0x1f4dd, 0x1f454, 0x1f33a, + 0x1f490, 0x1f335, 0x1f376, 0x1f37b, + 0x03297, 0x1f48a, 0x1f388, 0x1f389, + 0x00000, 0x1f452, 0x1f462, 0x1f485, + 0x1f487, 0x1f488, 0x1f458, 0x1f459, + 0x02665, 0x1f496, 0x1f499, 0x1f49a, + 0x1f49b, 0x1f49c, 0x02728, 0x1f3bf, + 0x02b55, 0x1f375, 0x1f35e, 0x1f366, + 0x1f35f, 0x1f361, 0x1f358, 0x1f35a, + 0x1f35d, 0x1f35b, 0x1f362, 0x1f363, + 0x1f34e, 0x1f34a, 0x1f345, 0x1f346, + 0x1f371, 0x1f372, 0x1f60f, 0x1f614, + 0x1f624, 0x1f623, 0x1f616, 0x1f62a, + 0x1f60c, 0x1f628, 0x1f637, 0x1f633, + 0x1f612, 0x1f632, 0x1f630, 0x1f3bc, + 0x1f60a, 0x1f61a, 0x1f618, 0x1f443, + 0x1f444, 0x1f64f, 0x1f44f, 0x1f44c, + 0x1f44e, 0x1f44b, 0x1f645, 0x1f646, + 0x1f647, 0x1f491, 0x1f46f, 0x1f3ba, + 0x1f3b1, 0x1f3ca, 0x1f692, 0x1f691, + 0x1f693, 0x1f3a2, 0x1f38d, 0x1f38e, + 0x1f393, 0x1f392, 0x1f38f, 0x1f302, + 0x1f470, 0x1f367, 0x1f387, 0x1f41a, + 0x1f390, 0x1f383, 0x1f391, 0x1f385, + 0x1f303, 0x1f308, 0x1f3e9, 0x1f305, + 0x1f3a9, 0x1f3ec, 0x1f3ef, 0x1f3f0, + 0x1f3ed, 0x1f1eb, 0x1f1e9, 0x1f1ee, + 0x1f1ec, 0x1f1e8, 0x1f1f0, 0x1f471, + 0x1f472, 0x1f473, 0x1f474, 0x1f475, + 0x1f476, 0x1f477, 0x1f478, 0x1f42c, + 0x1f483, 0x1f420, 0x1f41b, 0x1f418, + 0x1f428, 0x1f42e, 0x1f40d, 0x1f414, + 0x1f417, 0x1f42b, 0x1f170, 0x1f171, + 0x1f17e, 0x1f18e, 0x1f463, 0x1f45f, + 0x1f6a9, 0x02934, 0x02935, 0x02049, + 0x0203c, 0x027b0, 0x1f348, 0x1f34d, + 0x1f347, 0x1f34c, 0x1f33d, 0x1f344, + 0x1f330, 0x1f351, 0x1f360, 0x1f355, + 0x1f357, 0x1f38b, 0x1f379, 0x1f432, + 0x1f3b9, 0x1f3c4, 0x1f3a3, 0x1f3b3, + 0x1f479, 0x1f47a, 0x1f43c, 0x1f445, + 0x1f43d, 0x1f33c, 0x1f368, 0x1f369, + 0x1f36a, 0x1f36b, 0x1f36c, 0x1f36d, + 0x1f648, 0x1f64a, 0x1f649, 0x1f30b, + 0x1f49d, 0x1f524, 0x1f36e, 0x1f41d, + 0x1f41e, 0x1f36f, 0x1f34f, 0x1f4b8, + 0x1f4ab, 0x1f621, 0x1f63e, 0x1f30c, + 0x1f63d, 0x1f63a, 0x1f4e9, 0x1f639, + 0x1f602, 0x1f63b, 0x1f640, 0x1f629, + 0x1f63f, 0x1f622, 0x1f63c, 0x1f457, + 0x1f5ff, 0x1f689, 0x1f3b4, 0x1f0cf, + 0x1f364, 0x1f4e7, 0x1f6b6, 0x1f6a8, + 0x00000, 0x1f493, 0x1f425, 0x1f456, + 0x1f48c, 0x0267b, 0x02194, 0x02195, + 0x1f30a, 0x1f331, 0x1f40c, 0x1f638, + 0x1f601, 0x00000, 0x1f33f, 0x0270a, + 0x00023, 0x1f64b, 0x1f64c, 0x1f64d, + 0x1f64e, }; +const int mb_tbl_code2uni_kddi2_min = 0x26ec; +const int mb_tbl_code2uni_kddi2_max = 0x2863; + +const int mb_tbl_code2uni_kddi2[] = { // 0x26ec - 0x2863 + 0x1f320, 0x1f300, 0x1f6a5, 0x1f3c3, + 0x02747, 0x1f3a1, 0x1f3b0, 0x1f38a, + 0x1f433, 0x1f603, 0x1f620, 0x1f62d, + 0x1f62b, 0x1f4a4, 0x1f4a1, 0x1f494, + 0x1f495, 0x02734, 0x1f4a3, 0x1f525, + 0x023f3, 0x1f6ac, 0x1f6ad, 0x0267f, + 0x1f530, 0x026a0, 0x02757, 0x02753, + 0x026d4, 0x026c4, 0x1f319, 0x026a1, + 0x02600, 0x1f31b, 0x02744, 0x02b50, + 0x02614, 0x02601, 0x026c5, 0x02648, + 0x02649, 0x0264a, 0x0264b, 0x0264c, + 0x0264d, 0x0264e, 0x0264f, 0x02650, + 0x02651, 0x02652, 0x02653, 0x026ce, + 0x1f45c, 0x1f4d4, 0x1f3ab, 0x1f4d6, + 0x1f4ce, 0x0270f, 0x1f4d0, 0x1f3e7, + 0x1f3ea, 0x1f6bb, 0x1f17f, 0x1f68f, + 0x1f4e1, 0x02693, 0x1f3e6, 0x1f3e0, + 0x1f374, 0x1f3e2, 0x1f6b2, 0x1f68c, + 0x1f685, 0x1f697, 0x1f69a, 0x02708, + 0x026f5, 0x1f683, 0x026bd, 0x1f3be, + 0x1f3c2, 0x1f3c1, 0x026be, 0x1f3c8, + 0x02668, 0x1f3ee, 0x1f3ac, 0x1f309, + 0x1f5fc, 0x1f377, 0x1f378, 0x1f37a, + 0x1f356, 0x1f3af, 0x1f3ae, 0x1f4b0, + 0x1f3b2, 0x1f384, 0x1f338, 0x1f47b, + 0x1f1ef, 0x1f349, 0x1f341, 0x1f381, + 0x1f370, 0x1f373, 0x1f352, 0x1f421, + 0x1f353, 0x1f359, 0x1f354, 0x1f430, + 0x1f434, 0x1f435, 0x1f438, 0x1f431, + 0x1f427, 0x1f41c, 0x1f437, 0x1f429, + 0x1f424, 0x1f436, 0x1f334, 0x1f33b, + 0x1f337, 0x1f4a2, 0x1f4a7, 0x1f61c, + 0x1f198, 0x1f4aa, 0x1f498, 0x1f48b, + 0x1f47e, 0x1f365, 0x1f43e, 0x1f47f, + 0x1f4ae, 0x03299, 0x1f4af, 0x1f44a, + 0x1f4a8, 0x1f4a9, 0x0261d, 0x1f250, + 0x1f480, 0x1f44d, 0x1f469, 0x0263a, + 0x1f468, 0x1f4ac, 0x1f453, 0x1f448, + 0x1f449, 0x1f46a, 0x1f4fa, 0x1f3a4, + 0x1f45b, 0x1f3b6, 0x1f3b8, 0x1f3bb, + 0x1f3a7, 0x1f484, 0x1f52b, 0x1f486, + 0x1f4bf, 0x1f45a, 0x1f47d, 0x1f199, + 0x1f489, 0x1f50a, 0x1f514, 0x1f340, + 0x1f48d, 0x1f4f7, 0x02702, 0x1f3a5, + 0x1f50d, 0x1f511, 0x1f460, 0x1f4ea, + 0x1f512, 0x1f4db, 0x1f4de, 0x1f4e6, + 0x1f4e0, 0x02709, 0x00031, 0x00032, + 0x00033, 0x00034, 0x00035, 0x00036, + 0x00037, 0x00038, 0x00039, 0x1f51f, + 0x00000, 0x025c0, 0x025b6, 0x023ea, + 0x023e9, 0x025ab, 0x025aa, 0x02139, + 0x025fd, 0x025fe, 0x1f538, 0x1f539, + 0x025fb, 0x025fc, 0x026aa, 0x026ab, + 0x02795, 0x02796, 0x02733, 0x02b06, + 0x02b07, 0x1f6ab, 0x1f53d, 0x1f53c, + 0x023ec, 0x023eb, 0x1f536, 0x1f537, + 0x02b1c, 0x02b1b, 0x1f534, 0x1f535, + 0x02196, 0x02198, 0x02122, 0x02716, + 0x0274c, 0x0274e, 0x027a1, 0x02b05, + 0x02797, 0x02197, 0x02199, 0x02714, + 0x000a9, 0x000ae, 0x1f53a, 0x1f53b, + 0x021aa, 0x021a9, 0x02705, 0x1f4dc, + 0x1f4cd, 0x1f4c3, 0x1f4be, 0x1f4c5, + 0x1f4cb, 0x1f4d7, 0x1f4d8, 0x1f4d9, + 0x1f4d5, 0x1f4c4, 0x1f4c6, 0x1f4d3, + 0x1f4c7, 0x1f4cc, 0x1f4d2, 0x1f4da, + 0x1f4cf, 0x026fd, 0x1f5fe, 0x1f1fa, + 0x1f4ca, 0x1f4c8, 0x1f4c9, 0x00000, + 0x1f193, 0x1f4b2, 0x0231a, 0x0231b, + 0x1f4b3, 0x1f4b4, 0x1f4f9, 0x1f52a, + 0x1f4fc, 0x1f529, 0x1f4bd, 0x1f526, + 0x1f50b, 0x1f4b5, 0x00000, 0x1f527, + 0x1f4f1, 0x1f50c, 0x1f517, 0x1f4f0, + 0x02003, 0x02002, 0x02005, 0x1f4c1, + 0x1f4c2, 0x1f4e8, 0x1f4e4, 0x1f4e5, + 0x023f0, 0x02764, 0x0260e, 0x02615, + 0x1f301, 0x026f3, 0x1f3c0, 0x1f4df, + 0x1f3a8, 0x1f3ad, 0x1f3aa, 0x1f380, + 0x1f382, 0x02660, 0x02666, 0x02663, + 0x1f440, 0x1f442, 0x0270c, 0x0270b, + 0x1f311, 0x1f314, 0x1f313, 0x1f191, + 0x00030, 0x1f197, 0x1f635, 0x1f49e, + 0x1f4a5, 0x1f4a6, 0x00000, 0x1f30f, + 0x1f35c, 0x00000, 0x1f510, 0x1f520, + 0x1f521, 0x1f522, 0x1f523, 0x1f251, + 0x02611, 0x02712, 0x1f518, 0x1f50e, + 0x1f519, 0x1f516, 0x1f4f2, 0x1f3e1, + 0x1f4eb, 0x1f4d1, 0x1f50f, 0x1f503, + 0x1f195, 0x1f455, 0x1f45e, 0x1f4bb, + 0x1f4fb, 0x1f339, 0x026ea, 0x1f687, + 0x1f5fb, 0x1f3b5, 0x1f47c, 0x1f42f, + 0x1f43b, 0x1f42d, 0x1f609, 0x1f60d, + 0x1f631, 0x1f613, 0x1f419, 0x1f680, + 0x1f451, 0x1f48f, 0x1f528, 0x1f386, + }; +const int mb_tbl_code2uni_sb1_min = 0x27a9; +const int mb_tbl_code2uni_sb1_max = 0x285a; + +const int mb_tbl_code2uni_sb1[] = { // 0x27a9 - 0x285a + 0x1f4eb, 0x1f4ee, 0x1f4e9, 0x1f4f2, + 0x1f61c, 0x1f60d, 0x1f631, 0x1f613, + 0x1f435, 0x1f419, 0x1f437, 0x1f47d, + 0x1f680, 0x1f451, 0x1f4a1, 0x1f340, + 0x1f48f, 0x1f381, 0x1f52b, 0x1f50d, + 0x1f3c3, 0x1f528, 0x1f386, 0x1f341, + 0x1f342, 0x1f47f, 0x1f47b, 0x1f480, + 0x1f525, 0x1f4bc, 0x1f4ba, 0x1f354, + 0x026f2, 0x026fa, 0x02668, 0x1f3a1, + 0x1f3ab, 0x1f4bf, 0x1f4c0, 0x1f4fb, + 0x1f4fc, 0x1f4fa, 0x1f47e, 0x0303d, + 0x1f004, 0x1f19a, 0x1f4b0, 0x1f3af, + 0x1f3c6, 0x1f3c1, 0x1f3b0, 0x1f40e, + 0x1f6a4, 0x1f6b2, 0x1f6a7, 0x1f6b9, + 0x1f6ba, 0x1f6bc, 0x1f489, 0x1f4a4, + 0x026a1, 0x1f460, 0x1f6c0, 0x1f6bd, + 0x1f50a, 0x1f4e2, 0x1f38c, 0x1f512, + 0x1f513, 0x1f306, 0x1f373, 0x1f4d6, + 0x1f4b1, 0x1f4b9, 0x1f4e1, 0x1f4aa, + 0x1f3e6, 0x1f6a5, 0x1f17f, 0x1f68f, + 0x1f6bb, 0x1f46e, 0x1f3e3, 0x1f3e7, + 0x1f3e5, 0x1f3ea, 0x1f3eb, 0x1f3e8, + 0x1f68c, 0x1f695, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x1f6b6, + 0x1f6a2, 0x1f201, 0x1f49f, 0x02734, + 0x02733, 0x1f51e, 0x1f6ad, 0x1f530, + 0x0267f, 0x1f4f6, 0x02665, 0x02666, + 0x02660, 0x02663, 0x00023, 0x00000, + 0x1f195, 0x1f199, 0x1f192, 0x1f236, + 0x1f21a, 0x1f237, 0x1f238, 0x1f534, + 0x1f532, 0x1f533, 0x00031, 0x00032, + 0x00033, 0x00034, 0x00035, 0x00036, + 0x00037, 0x00038, 0x00039, 0x00030, + 0x1f250, 0x1f239, 0x1f202, 0x1f194, + 0x1f235, 0x1f233, 0x1f22f, 0x1f23a, + 0x1f446, 0x1f447, 0x1f448, 0x1f449, + 0x02b06, 0x02b07, 0x027a1, 0x02b05, + 0x02197, 0x02196, 0x02198, 0x02199, + 0x025b6, 0x025c0, 0x023e9, 0x023ea, + 0x1f52f, 0x02648, 0x02649, 0x0264a, + 0x0264b, 0x0264c, 0x0264d, 0x0264e, + 0x0264f, 0x02650, 0x02651, 0x02652, + 0x02653, 0x026ce, 0x1f51d, 0x1f197, + 0x000a9, 0x000ae, 0x1f4f3, 0x1f4f4, + 0x026a0, 0x1f481, }; +const int mb_tbl_code2uni_sb2_min = 0x2921; +const int mb_tbl_code2uni_sb2_max = 0x29cc; + +const int mb_tbl_code2uni_sb2[] = { // 0x2921 - 0x29cc + 0x1f466, 0x1f467, 0x1f48b, 0x1f468, + 0x1f469, 0x1f455, 0x1f45f, 0x1f4f7, + 0x0260e, 0x1f4f1, 0x1f4e0, 0x1f4bb, + 0x1f44a, 0x1f44d, 0x0261d, 0x0270a, + 0x0270c, 0x0270b, 0x1f3bf, 0x026f3, + 0x1f3be, 0x026be, 0x1f3c4, 0x026bd, + 0x1f41f, 0x1f434, 0x1f697, 0x026f5, + 0x02708, 0x1f683, 0x1f685, 0x02753, + 0x02757, 0x02764, 0x1f494, 0x1f550, + 0x1f551, 0x1f552, 0x1f553, 0x1f554, + 0x1f555, 0x1f556, 0x1f557, 0x1f558, + 0x1f559, 0x1f55a, 0x1f55b, 0x1f338, + 0x1f531, 0x1f339, 0x1f384, 0x1f48d, + 0x1f48e, 0x1f3e0, 0x026ea, 0x1f3e2, + 0x1f689, 0x026fd, 0x1f5fb, 0x1f3a4, + 0x1f3a5, 0x1f3b5, 0x1f511, 0x1f3b7, + 0x1f3b8, 0x1f3ba, 0x1f374, 0x1f378, + 0x02615, 0x1f370, 0x1f37a, 0x026c4, + 0x02601, 0x02600, 0x02614, 0x1f319, + 0x1f304, 0x1f47c, 0x1f431, 0x1f42f, + 0x1f43b, 0x1f436, 0x1f42d, 0x1f433, + 0x1f427, 0x1f60a, 0x1f603, 0x1f61e, + 0x1f620, 0x1f4a9, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x1f4dd, + 0x1f454, 0x1f33a, 0x1f337, 0x1f33b, + 0x1f490, 0x1f334, 0x1f335, 0x1f6be, + 0x1f3a7, 0x1f376, 0x1f37b, 0x03297, + 0x1f6ac, 0x1f48a, 0x1f388, 0x1f4a3, + 0x1f389, 0x02702, 0x1f380, 0x03299, + 0x1f4bd, 0x1f4e3, 0x1f452, 0x1f457, + 0x1f461, 0x1f462, 0x1f484, 0x1f485, + 0x1f486, 0x1f487, 0x1f488, 0x1f458, + 0x1f459, 0x1f45c, 0x1f3ac, 0x1f514, + 0x1f3b6, 0x1f493, 0x1f497, 0x1f498, + 0x1f499, 0x1f49a, 0x1f49b, 0x1f49c, + 0x02728, 0x02b50, 0x1f4a8, 0x1f4a6, + 0x02b55, 0x0274c, 0x1f4a2, 0x1f31f, + 0x02754, 0x02755, 0x1f375, 0x1f35e, + 0x1f366, 0x1f35f, 0x1f361, 0x1f358, + 0x1f35a, 0x1f35d, 0x1f35c, 0x1f35b, + 0x1f359, 0x1f362, 0x1f363, 0x1f34e, + 0x1f34a, 0x1f353, 0x1f349, 0x1f345, + 0x1f346, 0x1f382, 0x1f371, 0x1f372, + }; +const int mb_tbl_code2uni_sb3_min = 0x2a99; +const int mb_tbl_code2uni_sb3_max = 0x2b2e; + +const int mb_tbl_code2uni_sb3[] = { // 0x2a99 - 0x2b2e + 0x1f625, 0x1f60f, 0x1f614, 0x1f601, + 0x1f609, 0x1f623, 0x1f616, 0x1f62a, + 0x1f61d, 0x1f60c, 0x1f628, 0x1f637, + 0x1f633, 0x1f612, 0x1f630, 0x1f632, + 0x1f62d, 0x1f602, 0x1f622, 0x0263a, + 0x1f604, 0x1f621, 0x1f61a, 0x1f618, + 0x1f440, 0x1f443, 0x1f442, 0x1f444, + 0x1f64f, 0x1f44b, 0x1f44f, 0x1f44c, + 0x1f44e, 0x1f450, 0x1f645, 0x1f646, + 0x1f491, 0x1f647, 0x1f64c, 0x1f46b, + 0x1f46f, 0x1f3c0, 0x1f3c8, 0x1f3b1, + 0x1f3ca, 0x1f699, 0x1f69a, 0x1f692, + 0x1f691, 0x1f693, 0x1f3a2, 0x1f687, + 0x1f684, 0x1f38d, 0x1f49d, 0x1f38e, + 0x1f393, 0x1f392, 0x1f38f, 0x1f302, + 0x1f492, 0x1f30a, 0x1f367, 0x1f387, + 0x1f41a, 0x1f390, 0x1f300, 0x1f33e, + 0x1f383, 0x1f391, 0x1f343, 0x1f385, + 0x1f305, 0x1f307, 0x1f303, 0x1f308, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x00000, + 0x00000, 0x00000, 0x00000, 0x1f3e9, + 0x1f3a8, 0x1f3a9, 0x1f3ec, 0x1f3ef, + 0x1f3f0, 0x1f3a6, 0x1f3ed, 0x1f5fc, + 0x00000, 0x1f1ef, 0x1f1fa, 0x1f1eb, + 0x1f1e9, 0x1f1ee, 0x1f1ec, 0x1f1ea, + 0x1f1f7, 0x1f1e8, 0x1f1f0, 0x1f471, + 0x1f472, 0x1f473, 0x1f474, 0x1f475, + 0x1f476, 0x1f477, 0x1f478, 0x1f5fd, + 0x1f482, 0x1f483, 0x1f42c, 0x1f426, + 0x1f420, 0x1f424, 0x1f439, 0x1f41b, + 0x1f418, 0x1f428, 0x1f412, 0x1f411, + 0x1f43a, 0x1f42e, 0x1f430, 0x1f40d, + 0x1f414, 0x1f417, 0x1f42b, 0x1f438, + 0x1f170, 0x1f171, 0x1f18e, 0x1f17e, + 0x1f463, 0x02122, }; + + + +const int mb_tbl_uni_docomo2code1_min = 0x0023; +const int mb_tbl_uni_docomo2code1_max = 0x00ae; + +const int mb_tbl_uni_docomo2code1_key[] = { // 0x0023 - 0x00ae + 0x0023, 0x0030, 0x0031, 0x0032, + 0x0033, 0x0034, 0x0035, 0x0036, + 0x0037, 0x0038, 0x0039, 0x00a9, + 0x00ae, }; + +const int mb_tbl_uni_docomo2code1_value[] = { // 0x0023 - 0x00ae + 0x2964, 0x296f, 0x2966, 0x2967, + 0x2968, 0x2969, 0x296a, 0x296b, + 0x296c, 0x296d, 0x296e, 0x29b5, + 0x29ba, }; + + + + + + + + + + + + + + + +const int mb_tbl_uni_docomo2code2_min = 0x203c; +const int mb_tbl_uni_docomo2code2_max = 0x3299; + +const int mb_tbl_uni_docomo2code2_key[] = { // 0x203c - 0x3299 + 0x203c, 0x2049, 0x2122, 0x2194, + 0x2195, 0x2196, 0x2197, 0x2198, + 0x2199, 0x21a9, 0x231a, 0x23f0, + 0x23f3, 0x24c2, 0x2600, 0x2601, + 0x260e, 0x2614, 0x2615, 0x2648, + 0x2649, 0x264a, 0x264b, 0x264c, + 0x264d, 0x264e, 0x264f, 0x2650, + 0x2651, 0x2652, 0x2653, 0x2660, + 0x2663, 0x2665, 0x2666, 0x2668, + 0x267b, 0x267f, 0x26a0, 0x26a1, + 0x26bd, 0x26be, 0x26c4, 0x26f3, + 0x26f5, 0x26fd, 0x2702, 0x2708, + 0x2709, 0x270a, 0x270b, 0x270c, + 0x270f, 0x2712, 0x2728, 0x2757, + 0x2764, 0x27b0, 0x2934, 0x2935, + 0x3030, 0x3299, }; + +const int mb_tbl_uni_docomo2code2_value[] = { // 0x203c - 0x3299 + 0x2988, 0x2987, 0x29b6, 0x29c0, + 0x29c1, 0x291b, 0x28fc, 0x291a, + 0x2929, 0x295e, 0x29a3, 0x293e, + 0x29a0, 0x28e0, 0x28c2, 0x28c3, + 0x290b, 0x28c4, 0x28f4, 0x28ca, + 0x28cb, 0x28cc, 0x28cd, 0x28ce, + 0x28cf, 0x28d0, 0x28d1, 0x28d2, + 0x28d3, 0x28d4, 0x28d5, 0x2912, + 0x2914, 0x2911, 0x2913, 0x297b, + 0x29b9, 0x291f, 0x29bb, 0x28c6, + 0x28da, 0x28d7, 0x28c5, 0x28d8, + 0x2927, 0x28ef, 0x28f9, 0x28e6, + 0x2957, 0x2917, 0x2919, 0x2918, + 0x299d, 0x2932, 0x297e, 0x2986, + 0x2970, 0x298e, 0x2979, 0x2984, + 0x298d, 0x29b8, }; + + +const int mb_tbl_uni_docomo2code3_min = 0x1f17f; +const int mb_tbl_uni_docomo2code3_max = 0x1f6bb; + +const int mb_tbl_uni_docomo2code3_key[] = { // 0x1f17f - 0x1f6bb + 0x1f17f, 0x1f191, 0x1f193, 0x1f194, + 0x1f195, 0x1f196, 0x1f197, 0x1f232, + 0x1f233, 0x1f234, 0x1f235, 0x1f300, + 0x1f301, 0x1f302, 0x1f303, 0x1f30a, + 0x1f311, 0x1f313, 0x1f314, 0x1f315, + 0x1f319, 0x1f331, 0x1f337, 0x1f338, + 0x1f340, 0x1f341, 0x1f34c, 0x1f34e, + 0x1f352, 0x1f354, 0x1f359, 0x1f35c, + 0x1f35e, 0x1f370, 0x1f374, 0x1f375, + 0x1f376, 0x1f377, 0x1f378, 0x1f37a, + 0x1f380, 0x1f381, 0x1f382, 0x1f384, + 0x1f3a0, 0x1f3a4, 0x1f3a5, 0x1f3a7, + 0x1f3a8, 0x1f3a9, 0x1f3aa, 0x1f3ab, + 0x1f3ac, 0x1f3ae, 0x1f3b5, 0x1f3b6, + 0x1f3bd, 0x1f3be, 0x1f3bf, 0x1f3c0, + 0x1f3c1, 0x1f3c2, 0x1f3c3, 0x1f3e0, + 0x1f3e2, 0x1f3e3, 0x1f3e5, 0x1f3e6, + 0x1f3e7, 0x1f3e8, 0x1f3ea, 0x1f3eb, + 0x1f40c, 0x1f41f, 0x1f424, 0x1f427, + 0x1f431, 0x1f434, 0x1f436, 0x1f437, + 0x1f440, 0x1f442, 0x1f44a, 0x1f44d, + 0x1f451, 0x1f453, 0x1f455, 0x1f456, + 0x1f45b, 0x1f45c, 0x1f45d, 0x1f45f, + 0x1f460, 0x1f463, 0x1f464, 0x1f484, + 0x1f48b, 0x1f48c, 0x1f48d, 0x1f493, + 0x1f494, 0x1f495, 0x1f4a0, 0x1f4a1, + 0x1f4a2, 0x1f4a3, 0x1f4a4, 0x1f4a5, + 0x1f4a6, 0x1f4a7, 0x1f4a8, 0x1f4b0, + 0x1f4b4, 0x1f4ba, 0x1f4bb, 0x1f4bf, + 0x1f4ce, 0x1f4d6, 0x1f4dd, 0x1f4df, + 0x1f4e0, 0x1f4e9, 0x1f4f1, 0x1f4f2, + 0x1f4f7, 0x1f4fa, 0x1f50d, 0x1f511, + 0x1f514, 0x1f51a, 0x1f51b, 0x1f51c, + 0x1f527, 0x1f5fb, 0x1f601, 0x1f603, + 0x1f605, 0x1f606, 0x1f609, 0x1f60b, + 0x1f60c, 0x1f60d, 0x1f60f, 0x1f612, + 0x1f613, 0x1f614, 0x1f616, 0x1f61c, + 0x1f61e, 0x1f620, 0x1f621, 0x1f622, + 0x1f623, 0x1f62d, 0x1f631, 0x1f635, + 0x1f683, 0x1f684, 0x1f68c, 0x1f697, + 0x1f699, 0x1f6a2, 0x1f6a5, 0x1f6a9, + 0x1f6aa, 0x1f6ac, 0x1f6ad, 0x1f6b2, + 0x1f6bb, }; + +const int mb_tbl_uni_docomo2code3_value[] = { // 0x1f17f - 0x1f6bb + 0x28f0, 0x295f, 0x295b, 0x295c, + 0x2961, 0x29b3, 0x298f, 0x29bc, + 0x29bd, 0x29be, 0x29bf, 0x28c7, + 0x28c8, 0x28c9, 0x2937, 0x29c3, + 0x2920, 0x2922, 0x2921, 0x2924, + 0x2923, 0x29ca, 0x29c7, 0x29cc, + 0x29c5, 0x29cb, 0x29c8, 0x29c9, + 0x29c6, 0x28f7, 0x29cd, 0x29d0, + 0x29d1, 0x29ce, 0x28f3, 0x29a2, + 0x29cf, 0x29da, 0x28f5, 0x28f6, + 0x2908, 0x2909, 0x290a, 0x2928, + 0x28fd, 0x28fa, 0x28fb, 0x28fe, + 0x28ff, 0x2900, 0x2901, 0x2902, + 0x2930, 0x290f, 0x297a, 0x2983, + 0x28d6, 0x28d9, 0x28db, 0x28dc, + 0x28dd, 0x2996, 0x29b7, 0x28e7, + 0x28e8, 0x28e9, 0x28ea, 0x28eb, + 0x28ec, 0x28ed, 0x28ee, 0x29c2, + 0x29d2, 0x29d5, 0x29d3, 0x29d4, + 0x2926, 0x29d8, 0x2925, 0x29d9, + 0x2915, 0x2916, 0x2981, 0x29ab, + 0x299e, 0x291e, 0x2992, 0x2995, + 0x2993, 0x2906, 0x2931, 0x291d, + 0x28f8, 0x291c, 0x2935, 0x2994, + 0x297d, 0x299b, 0x299f, 0x2971, + 0x2972, 0x2973, 0x297c, 0x297f, + 0x2980, 0x2982, 0x2985, 0x2989, + 0x298a, 0x298b, 0x298c, 0x2999, + 0x295a, 0x2936, 0x299a, 0x2910, + 0x29b4, 0x2907, 0x290d, 0x28de, + 0x2954, 0x2953, 0x290c, 0x2952, + 0x2905, 0x290e, 0x2960, 0x295d, + 0x2997, 0x293d, 0x293c, 0x293b, + 0x299c, 0x29c4, 0x29d7, 0x2974, + 0x29a6, 0x29ae, 0x29ad, 0x29d6, + 0x29a5, 0x29aa, 0x29b0, 0x29a9, + 0x29a7, 0x29a4, 0x2977, 0x29ac, + 0x2976, 0x2975, 0x29a8, 0x29b2, + 0x29af, 0x29b1, 0x29db, 0x2978, + 0x28df, 0x28e1, 0x28e4, 0x28e2, + 0x28e3, 0x28e5, 0x28f1, 0x2962, + 0x2998, 0x2903, 0x2904, 0x29a1, + 0x28f2, }; + + + +const int mb_tbl_uni_kddi2code1_min = 0x0023; +const int mb_tbl_uni_kddi2code1_max = 0x00ae; + +const int mb_tbl_uni_kddi2code1_key[] = { // 0x0023 - 0x00ae + 0x0023, 0x0030, 0x0031, 0x0032, + 0x0033, 0x0034, 0x0035, 0x0036, + 0x0037, 0x0038, 0x0039, 0x00a9, + 0x00ae, }; + +const int mb_tbl_uni_kddi2code1_value[] = { // 0x0023 - 0x00ae + 0x25bc, 0x2830, 0x27a6, 0x27a7, + 0x27a8, 0x27a9, 0x27aa, 0x27ab, + 0x27ac, 0x27ad, 0x27ae, 0x27dc, + 0x27dd, }; + +const int mb_tbl_uni_kddi2code2_min = 0x2002; +const int mb_tbl_uni_kddi2code2_max = 0x3299; + +const int mb_tbl_uni_kddi2code2_key[] = { // 0x2002 - 0x3299 + 0x2002, 0x2003, 0x2005, 0x203c, + 0x2049, 0x2122, 0x2139, 0x2194, + 0x2195, 0x2196, 0x2197, 0x2198, + 0x2199, 0x21a9, 0x21aa, 0x231a, + 0x231b, 0x23e9, 0x23ea, 0x23eb, + 0x23ec, 0x23f0, 0x23f3, 0x25aa, + 0x25ab, 0x25b6, 0x25c0, 0x25fb, + 0x25fc, 0x25fd, 0x25fe, 0x2600, + 0x2601, 0x260e, 0x2611, 0x2614, + 0x2615, 0x261d, 0x263a, 0x2648, + 0x2649, 0x264a, 0x264b, 0x264c, + 0x264d, 0x264e, 0x264f, 0x2650, + 0x2651, 0x2652, 0x2653, 0x2660, + 0x2663, 0x2665, 0x2666, 0x2668, + 0x267b, 0x267f, 0x2693, 0x26a0, + 0x26a1, 0x26aa, 0x26ab, 0x26bd, + 0x26be, 0x26c4, 0x26c5, 0x26ce, + 0x26d4, 0x26ea, 0x26f2, 0x26f3, + 0x26f5, 0x26fa, 0x26fd, 0x2702, + 0x2705, 0x2708, 0x2709, 0x270a, + 0x270b, 0x270c, 0x270f, 0x2712, + 0x2714, 0x2716, 0x2728, 0x2733, + 0x2734, 0x2744, 0x2747, 0x274c, + 0x274e, 0x2753, 0x2757, 0x2764, + 0x2795, 0x2796, 0x2797, 0x27a1, + 0x27b0, 0x2934, 0x2935, 0x2b05, + 0x2b06, 0x2b07, 0x2b1b, 0x2b1c, + 0x2b50, 0x2b55, 0x3297, 0x3299, + }; + +const int mb_tbl_uni_kddi2code2_value[] = { // 0x2002 - 0x3299 + 0x2811, 0x2810, 0x2812, 0x2568, + 0x2567, 0x27d2, 0x27b7, 0x25b2, + 0x25b3, 0x27d0, 0x27d9, 0x27d1, + 0x27da, 0x27e1, 0x27e0, 0x27fe, + 0x27ff, 0x27b4, 0x27b3, 0x27c9, + 0x27c8, 0x2818, 0x2700, 0x27b6, + 0x27b5, 0x27b2, 0x27b1, 0x27bc, + 0x27bd, 0x27b8, 0x27b9, 0x270c, + 0x2711, 0x281a, 0x2840, 0x2710, + 0x281b, 0x277a, 0x277f, 0x2713, + 0x2714, 0x2715, 0x2716, 0x2717, + 0x2718, 0x2719, 0x271a, 0x271b, + 0x271c, 0x271d, 0x271e, 0x2825, + 0x2827, 0x24f0, 0x2826, 0x2740, + 0x25b1, 0x2703, 0x272d, 0x2705, + 0x270b, 0x27be, 0x27bf, 0x273a, + 0x273e, 0x2709, 0x2712, 0x271f, + 0x2708, 0x2852, 0x24ba, 0x281d, + 0x2738, 0x24bb, 0x27f5, 0x279a, + 0x27e2, 0x2737, 0x27a5, 0x25bb, + 0x282b, 0x282a, 0x2725, 0x2841, + 0x27db, 0x27d3, 0x24f6, 0x27c2, + 0x26fd, 0x270e, 0x26f0, 0x27d4, + 0x27d5, 0x2707, 0x2706, 0x2819, + 0x27c0, 0x27c1, 0x27d8, 0x27d6, + 0x2569, 0x2565, 0x2566, 0x27d7, + 0x27c3, 0x27c4, 0x27cd, 0x27cc, + 0x270f, 0x24f8, 0x24e4, 0x2775, + }; + +const int mb_tbl_uni_kddi2code3_min = 0x1f004; +const int mb_tbl_uni_kddi2code3_max = 0x1f6c0; + +const int mb_tbl_uni_kddi2code3_key[] = { // 0x1f004 - 0x1f6c0 + 0x1f004, 0x1f0cf, 0x1f170, 0x1f171, + 0x1f17e, 0x1f17f, 0x1f18e, 0x1f191, + 0x1f192, 0x1f193, 0x1f194, 0x1f195, + 0x1f197, 0x1f198, 0x1f199, 0x1f19a, + 0x1f1e8, 0x1f1e9, 0x1f1ea, 0x1f1eb, + 0x1f1ec, 0x1f1ee, 0x1f1ef, 0x1f1f0, + 0x1f1f7, 0x1f1fa, 0x1f202, 0x1f22f, + 0x1f233, 0x1f235, 0x1f239, 0x1f23a, + 0x1f250, 0x1f251, 0x1f300, 0x1f301, + 0x1f302, 0x1f303, 0x1f305, 0x1f306, + 0x1f308, 0x1f309, 0x1f30a, 0x1f30b, + 0x1f30c, 0x1f30f, 0x1f311, 0x1f313, + 0x1f314, 0x1f319, 0x1f31b, 0x1f320, + 0x1f330, 0x1f331, 0x1f334, 0x1f335, + 0x1f337, 0x1f338, 0x1f339, 0x1f33a, + 0x1f33b, 0x1f33c, 0x1f33d, 0x1f33f, + 0x1f340, 0x1f341, 0x1f342, 0x1f344, + 0x1f345, 0x1f346, 0x1f347, 0x1f348, + 0x1f349, 0x1f34a, 0x1f34c, 0x1f34d, + 0x1f34e, 0x1f34f, 0x1f351, 0x1f352, + 0x1f353, 0x1f354, 0x1f355, 0x1f356, + 0x1f357, 0x1f358, 0x1f359, 0x1f35a, + 0x1f35b, 0x1f35c, 0x1f35d, 0x1f35e, + 0x1f35f, 0x1f360, 0x1f361, 0x1f362, + 0x1f363, 0x1f364, 0x1f365, 0x1f366, + 0x1f367, 0x1f368, 0x1f369, 0x1f36a, + 0x1f36b, 0x1f36c, 0x1f36d, 0x1f36e, + 0x1f36f, 0x1f370, 0x1f371, 0x1f372, + 0x1f373, 0x1f374, 0x1f375, 0x1f376, + 0x1f377, 0x1f378, 0x1f379, 0x1f37a, + 0x1f37b, 0x1f380, 0x1f381, 0x1f382, + 0x1f383, 0x1f384, 0x1f385, 0x1f386, + 0x1f387, 0x1f388, 0x1f389, 0x1f38a, + 0x1f38b, 0x1f38c, 0x1f38d, 0x1f38e, + 0x1f38f, 0x1f390, 0x1f391, 0x1f392, + 0x1f393, 0x1f3a1, 0x1f3a2, 0x1f3a3, + 0x1f3a4, 0x1f3a5, 0x1f3a7, 0x1f3a8, + 0x1f3a9, 0x1f3aa, 0x1f3ab, 0x1f3ac, + 0x1f3ad, 0x1f3ae, 0x1f3af, 0x1f3b0, + 0x1f3b1, 0x1f3b2, 0x1f3b3, 0x1f3b4, + 0x1f3b5, 0x1f3b6, 0x1f3b8, 0x1f3b9, + 0x1f3ba, 0x1f3bb, 0x1f3bc, 0x1f3be, + 0x1f3bf, 0x1f3c0, 0x1f3c1, 0x1f3c2, + 0x1f3c3, 0x1f3c4, 0x1f3c6, 0x1f3c8, + 0x1f3ca, 0x1f3e0, 0x1f3e1, 0x1f3e2, + 0x1f3e3, 0x1f3e5, 0x1f3e6, 0x1f3e7, + 0x1f3e8, 0x1f3e9, 0x1f3ea, 0x1f3eb, + 0x1f3ec, 0x1f3ed, 0x1f3ee, 0x1f3ef, + 0x1f3f0, 0x1f40c, 0x1f40d, 0x1f414, + 0x1f417, 0x1f418, 0x1f419, 0x1f41a, + 0x1f41b, 0x1f41c, 0x1f41d, 0x1f41e, + 0x1f420, 0x1f421, 0x1f422, 0x1f423, + 0x1f424, 0x1f425, 0x1f427, 0x1f428, + 0x1f429, 0x1f42b, 0x1f42c, 0x1f42d, + 0x1f42e, 0x1f42f, 0x1f430, 0x1f431, + 0x1f432, 0x1f433, 0x1f434, 0x1f435, + 0x1f436, 0x1f437, 0x1f438, 0x1f43b, + 0x1f43c, 0x1f43d, 0x1f43e, 0x1f440, + 0x1f442, 0x1f443, 0x1f444, 0x1f445, + 0x1f446, 0x1f447, 0x1f448, 0x1f449, + 0x1f44a, 0x1f44b, 0x1f44c, 0x1f44d, + 0x1f44e, 0x1f44f, 0x1f451, 0x1f452, + 0x1f453, 0x1f454, 0x1f455, 0x1f456, + 0x1f457, 0x1f458, 0x1f459, 0x1f45a, + 0x1f45b, 0x1f45c, 0x1f45e, 0x1f45f, + 0x1f460, 0x1f462, 0x1f463, 0x1f468, + 0x1f469, 0x1f46a, 0x1f46e, 0x1f46f, + 0x1f470, 0x1f471, 0x1f472, 0x1f473, + 0x1f474, 0x1f475, 0x1f476, 0x1f477, + 0x1f478, 0x1f479, 0x1f47a, 0x1f47b, + 0x1f47c, 0x1f47d, 0x1f47e, 0x1f47f, + 0x1f480, 0x1f483, 0x1f484, 0x1f485, + 0x1f486, 0x1f487, 0x1f488, 0x1f489, + 0x1f48a, 0x1f48b, 0x1f48c, 0x1f48d, + 0x1f48f, 0x1f490, 0x1f491, 0x1f493, + 0x1f494, 0x1f495, 0x1f496, 0x1f498, + 0x1f499, 0x1f49a, 0x1f49b, 0x1f49c, + 0x1f49d, 0x1f49e, 0x1f4a1, 0x1f4a2, + 0x1f4a3, 0x1f4a4, 0x1f4a5, 0x1f4a6, + 0x1f4a7, 0x1f4a8, 0x1f4a9, 0x1f4aa, + 0x1f4ab, 0x1f4ac, 0x1f4ae, 0x1f4af, + 0x1f4b0, 0x1f4b2, 0x1f4b3, 0x1f4b4, + 0x1f4b5, 0x1f4b8, 0x1f4b9, 0x1f4bb, + 0x1f4bc, 0x1f4bd, 0x1f4be, 0x1f4bf, + 0x1f4c1, 0x1f4c2, 0x1f4c3, 0x1f4c4, + 0x1f4c5, 0x1f4c6, 0x1f4c7, 0x1f4c8, + 0x1f4c9, 0x1f4ca, 0x1f4cb, 0x1f4cc, + 0x1f4cd, 0x1f4ce, 0x1f4cf, 0x1f4d0, + 0x1f4d1, 0x1f4d2, 0x1f4d3, 0x1f4d4, + 0x1f4d5, 0x1f4d6, 0x1f4d7, 0x1f4d8, + 0x1f4d9, 0x1f4da, 0x1f4db, 0x1f4dc, + 0x1f4dd, 0x1f4de, 0x1f4df, 0x1f4e0, + 0x1f4e1, 0x1f4e4, 0x1f4e5, 0x1f4e6, + 0x1f4e7, 0x1f4e8, 0x1f4e9, 0x1f4ea, + 0x1f4eb, 0x1f4f0, 0x1f4f1, 0x1f4f2, + 0x1f4f3, 0x1f4f4, 0x1f4f6, 0x1f4f7, + 0x1f4f9, 0x1f4fa, 0x1f4fb, 0x1f4fc, + 0x1f503, 0x1f50a, 0x1f50b, 0x1f50c, + 0x1f50d, 0x1f50e, 0x1f50f, 0x1f510, + 0x1f511, 0x1f512, 0x1f514, 0x1f516, + 0x1f517, 0x1f518, 0x1f519, 0x1f51e, + 0x1f51f, 0x1f520, 0x1f521, 0x1f522, + 0x1f523, 0x1f524, 0x1f525, 0x1f526, + 0x1f527, 0x1f528, 0x1f529, 0x1f52a, + 0x1f52b, 0x1f52e, 0x1f530, 0x1f534, + 0x1f535, 0x1f536, 0x1f537, 0x1f538, + 0x1f539, 0x1f53a, 0x1f53b, 0x1f53c, + 0x1f53d, 0x1f5fb, 0x1f5fc, 0x1f5fe, + 0x1f5ff, 0x1f601, 0x1f602, 0x1f603, + 0x1f609, 0x1f60a, 0x1f60c, 0x1f60d, + 0x1f60f, 0x1f612, 0x1f613, 0x1f614, + 0x1f616, 0x1f618, 0x1f61a, 0x1f61c, + 0x1f620, 0x1f621, 0x1f622, 0x1f623, + 0x1f624, 0x1f628, 0x1f629, 0x1f62a, + 0x1f62b, 0x1f62d, 0x1f630, 0x1f631, + 0x1f632, 0x1f633, 0x1f635, 0x1f637, + 0x1f638, 0x1f639, 0x1f63a, 0x1f63b, + 0x1f63c, 0x1f63d, 0x1f63e, 0x1f63f, + 0x1f640, 0x1f645, 0x1f646, 0x1f647, + 0x1f648, 0x1f649, 0x1f64a, 0x1f64b, + 0x1f64c, 0x1f64d, 0x1f64e, 0x1f64f, + 0x1f680, 0x1f683, 0x1f685, 0x1f687, + 0x1f689, 0x1f68c, 0x1f68f, 0x1f691, + 0x1f692, 0x1f693, 0x1f697, 0x1f69a, + 0x1f6a2, 0x1f6a5, 0x1f6a7, 0x1f6a8, + 0x1f6a9, 0x1f6ab, 0x1f6ac, 0x1f6ad, + 0x1f6b2, 0x1f6b6, 0x1f6bb, 0x1f6c0, + }; + +const int mb_tbl_uni_kddi2code3_value[] = { // 0x1f004 - 0x1f6c0 + 0x24bc, 0x25a7, 0x255e, 0x255f, + 0x2560, 0x272a, 0x2561, 0x282f, + 0x24d0, 0x27fc, 0x24d3, 0x284c, + 0x2831, 0x276c, 0x2793, 0x24bd, + 0x2549, 0x2546, 0x24c0, 0x2545, + 0x2548, 0x2547, 0x2750, 0x254a, + 0x24c1, 0x27f7, 0x24d2, 0x24d6, + 0x24d5, 0x24d4, 0x24d1, 0x24d7, + 0x277b, 0x283f, 0x26ed, 0x281c, + 0x2533, 0x253c, 0x253f, 0x24c5, + 0x253d, 0x2743, 0x25b4, 0x258b, + 0x2597, 0x2837, 0x282c, 0x282e, + 0x282d, 0x270a, 0x270d, 0x26ec, + 0x2570, 0x25b5, 0x2766, 0x24e1, + 0x2768, 0x274e, 0x2851, 0x24df, + 0x2767, 0x2581, 0x256e, 0x25ba, + 0x2797, 0x2752, 0x24b8, 0x256f, + 0x2506, 0x2507, 0x256c, 0x256a, + 0x2751, 0x2505, 0x256d, 0x256b, + 0x2504, 0x2592, 0x2571, 0x2756, + 0x2758, 0x275a, 0x2573, 0x2748, + 0x2574, 0x24fe, 0x2759, 0x24ff, + 0x2501, 0x2838, 0x2500, 0x24fa, + 0x24fc, 0x2572, 0x24fd, 0x2502, + 0x2503, 0x25a8, 0x2771, 0x24fb, + 0x2535, 0x2582, 0x2583, 0x2584, + 0x2585, 0x2586, 0x2587, 0x258e, + 0x2591, 0x2754, 0x2508, 0x2509, + 0x2755, 0x2730, 0x24f9, 0x24e2, + 0x2745, 0x2746, 0x2576, 0x2747, + 0x24e3, 0x2823, 0x2753, 0x2824, + 0x2539, 0x274d, 0x253b, 0x2863, + 0x2536, 0x24e6, 0x24e7, 0x26f3, + 0x2575, 0x24c4, 0x252e, 0x252f, + 0x2532, 0x2538, 0x253a, 0x2531, + 0x2530, 0x26f1, 0x252d, 0x257a, + 0x2787, 0x279b, 0x278c, 0x2820, + 0x2540, 0x2822, 0x2722, 0x2742, + 0x2821, 0x274a, 0x2749, 0x26f2, + 0x2528, 0x274c, 0x257b, 0x25a6, + 0x2855, 0x2789, 0x278a, 0x2578, + 0x2527, 0x278b, 0x2517, 0x273b, + 0x24f7, 0x281e, 0x273d, 0x273c, + 0x26ef, 0x2579, 0x24be, 0x273f, + 0x2529, 0x272f, 0x2847, 0x2731, + 0x24c9, 0x24ca, 0x272e, 0x2727, + 0x24cc, 0x253e, 0x2728, 0x24cb, + 0x2541, 0x2544, 0x2741, 0x2542, + 0x2543, 0x25b6, 0x255a, 0x255b, + 0x255c, 0x2557, 0x285e, 0x2537, + 0x2556, 0x2761, 0x258f, 0x2590, + 0x2555, 0x2757, 0x24bf, 0x24c6, + 0x2764, 0x25ae, 0x2760, 0x2558, + 0x2763, 0x255d, 0x2553, 0x2859, + 0x2559, 0x2857, 0x275b, 0x275f, + 0x2577, 0x26f4, 0x275c, 0x275d, + 0x2765, 0x2762, 0x275e, 0x2858, + 0x257e, 0x2580, 0x2772, 0x2828, + 0x2829, 0x251b, 0x251c, 0x257f, + 0x24d8, 0x24d9, 0x2783, 0x2784, + 0x2777, 0x2521, 0x251f, 0x277d, + 0x2520, 0x251e, 0x2860, 0x24e9, + 0x2782, 0x24de, 0x284d, 0x25af, + 0x25a3, 0x24ee, 0x24ef, 0x2791, + 0x2788, 0x2720, 0x284e, 0x2563, + 0x279e, 0x24ea, 0x2562, 0x2780, + 0x277e, 0x2785, 0x24c8, 0x2526, + 0x2534, 0x254b, 0x254c, 0x254d, + 0x254e, 0x254f, 0x2550, 0x2551, + 0x2552, 0x257c, 0x257d, 0x274f, + 0x2856, 0x2792, 0x2770, 0x2773, + 0x277c, 0x2554, 0x278d, 0x24eb, + 0x278f, 0x24ec, 0x24ed, 0x2794, + 0x24e5, 0x276f, 0x25b0, 0x2798, + 0x2861, 0x24e0, 0x2525, 0x25ad, + 0x26fb, 0x26fc, 0x24f1, 0x276e, + 0x24f2, 0x24f3, 0x24f4, 0x24f5, + 0x258c, 0x2833, 0x26fa, 0x2769, + 0x26fe, 0x26f9, 0x2834, 0x2835, + 0x276a, 0x2778, 0x2779, 0x276d, + 0x2594, 0x2781, 0x2774, 0x2776, + 0x274b, 0x27fd, 0x2800, 0x2801, + 0x2809, 0x2593, 0x24c7, 0x284f, + 0x24b9, 0x2806, 0x27e6, 0x2790, + 0x2813, 0x2814, 0x27e5, 0x27ed, + 0x27e7, 0x27ee, 0x27f0, 0x27f9, + 0x27fa, 0x27f8, 0x27e8, 0x27f1, + 0x27e4, 0x2724, 0x27f4, 0x2726, + 0x2849, 0x27f2, 0x27ef, 0x2721, + 0x27ec, 0x2723, 0x27e9, 0x27ea, + 0x27eb, 0x27f3, 0x27a1, 0x27e3, + 0x24dd, 0x27a2, 0x281f, 0x27a4, + 0x272c, 0x2816, 0x2817, 0x27a3, + 0x25a9, 0x2815, 0x259a, 0x279f, + 0x2848, 0x280f, 0x280c, 0x2846, + 0x24db, 0x24dc, 0x24cf, 0x2799, + 0x2802, 0x2786, 0x2850, 0x2804, + 0x284b, 0x2795, 0x2808, 0x280d, + 0x279c, 0x2843, 0x284a, 0x283a, + 0x279d, 0x27a0, 0x2796, 0x2845, + 0x280e, 0x2842, 0x2844, 0x24ce, + 0x27af, 0x283b, 0x283c, 0x283d, + 0x283e, 0x258d, 0x26ff, 0x2807, + 0x280b, 0x2862, 0x2805, 0x2803, + 0x278e, 0x24da, 0x2704, 0x27ce, + 0x27cf, 0x27ca, 0x27cb, 0x27ba, + 0x27bb, 0x27de, 0x27df, 0x27c7, + 0x27c6, 0x2854, 0x2744, 0x27f6, + 0x25a4, 0x25b8, 0x259c, 0x26f5, + 0x285a, 0x2518, 0x2510, 0x285b, + 0x250a, 0x2514, 0x285d, 0x250b, + 0x250e, 0x251a, 0x2519, 0x276b, + 0x26f6, 0x2595, 0x25a1, 0x250d, + 0x250c, 0x2511, 0x259f, 0x250f, + 0x26f8, 0x26f7, 0x2516, 0x285c, + 0x2515, 0x2513, 0x2832, 0x2512, + 0x25b7, 0x259b, 0x2599, 0x259d, + 0x25a2, 0x2598, 0x2596, 0x25a0, + 0x259e, 0x2522, 0x2523, 0x2524, + 0x2588, 0x258a, 0x2589, 0x25bd, + 0x25be, 0x25bf, 0x25c0, 0x251d, + 0x285f, 0x2739, 0x2734, 0x2853, + 0x25a5, 0x2733, 0x272b, 0x252b, + 0x252a, 0x252c, 0x2735, 0x2736, + 0x24cd, 0x26ee, 0x24c2, 0x25ab, + 0x2564, 0x27c5, 0x2701, 0x2702, + 0x2732, 0x25aa, 0x2729, 0x24c3, + }; + + + +const int mb_tbl_uni_sb2code1_min = 0x0023; +const int mb_tbl_uni_sb2code1_max = 0x00ae; + +const int mb_tbl_uni_sb2code1_key[] = { // 0x0023 - 0x00ae + 0x0023, 0x0030, 0x0031, 0x0032, + 0x0033, 0x0034, 0x0035, 0x0036, + 0x0037, 0x0038, 0x0039, 0x00a9, + 0x00ae, }; + +const int mb_tbl_uni_sb2code1_value[] = { // 0x0023 - 0x00ae + 0x2817, 0x282c, 0x2823, 0x2824, + 0x2825, 0x2826, 0x2827, 0x2828, + 0x2829, 0x282a, 0x282b, 0x2855, + 0x2856, }; + +const int mb_tbl_uni_sb2code2_min = 0x2122; +const int mb_tbl_uni_sb2code2_max = 0x3299; + +const int mb_tbl_uni_sb2code2_key[] = { // 0x2122 - 0x3299 + 0x2122, 0x2196, 0x2197, 0x2198, + 0x2199, 0x23e9, 0x23ea, 0x25b6, + 0x25c0, 0x2600, 0x2601, 0x260e, + 0x2614, 0x2615, 0x261d, 0x263a, + 0x2648, 0x2649, 0x264a, 0x264b, + 0x264c, 0x264d, 0x264e, 0x264f, + 0x2650, 0x2651, 0x2652, 0x2653, + 0x2660, 0x2663, 0x2665, 0x2666, + 0x2668, 0x267f, 0x26a0, 0x26a1, + 0x26bd, 0x26be, 0x26c4, 0x26ce, + 0x26ea, 0x26f2, 0x26f3, 0x26f5, + 0x26fa, 0x26fd, 0x2702, 0x2708, + 0x270a, 0x270b, 0x270c, 0x2728, + 0x2733, 0x2734, 0x274c, 0x2753, + 0x2754, 0x2755, 0x2757, 0x2764, + 0x27a1, 0x2b05, 0x2b06, 0x2b07, + 0x2b50, 0x2b55, 0x303d, 0x3297, + 0x3299, }; + +const int mb_tbl_uni_sb2code2_value[] = { // 0x2122 - 0x3299 + 0x2b2e, 0x283e, 0x283d, 0x283f, + 0x2840, 0x2843, 0x2844, 0x2841, + 0x2842, 0x296a, 0x2969, 0x2929, + 0x296b, 0x2965, 0x292f, 0x2aac, + 0x2846, 0x2847, 0x2848, 0x2849, + 0x284a, 0x284b, 0x284c, 0x284d, + 0x284e, 0x284f, 0x2850, 0x2851, + 0x2815, 0x2816, 0x2813, 0x2814, + 0x27cb, 0x2811, 0x2859, 0x27e5, + 0x2938, 0x2936, 0x2968, 0x2852, + 0x2957, 0x27c9, 0x2934, 0x293c, + 0x27ca, 0x295a, 0x2992, 0x293d, + 0x2930, 0x2932, 0x2931, 0x29ad, + 0x280d, 0x280c, 0x29b2, 0x2940, + 0x29b5, 0x29b6, 0x2941, 0x2942, + 0x283b, 0x283c, 0x2839, 0x283a, + 0x29ae, 0x29b1, 0x27d4, 0x298c, + 0x2994, }; + +const int mb_tbl_uni_sb2code3_min = 0x1f004; +const int mb_tbl_uni_sb2code3_max = 0x1f6c0; + +const int mb_tbl_uni_sb2code3_key[] = { // 0x1f004 - 0x1f6c0 + 0x1f004, 0x1f170, 0x1f171, 0x1f17e, + 0x1f17f, 0x1f18e, 0x1f192, 0x1f194, + 0x1f195, 0x1f197, 0x1f199, 0x1f19a, + 0x1f1e8, 0x1f1e9, 0x1f1ea, 0x1f1eb, + 0x1f1ec, 0x1f1ee, 0x1f1ef, 0x1f1f0, + 0x1f1f7, 0x1f1fa, 0x1f201, 0x1f202, + 0x1f21a, 0x1f22f, 0x1f233, 0x1f235, + 0x1f236, 0x1f237, 0x1f238, 0x1f239, + 0x1f23a, 0x1f250, 0x1f300, 0x1f302, + 0x1f303, 0x1f304, 0x1f305, 0x1f306, + 0x1f307, 0x1f308, 0x1f30a, 0x1f319, + 0x1f31f, 0x1f334, 0x1f335, 0x1f337, + 0x1f338, 0x1f339, 0x1f33a, 0x1f33b, + 0x1f33e, 0x1f340, 0x1f341, 0x1f342, + 0x1f343, 0x1f345, 0x1f346, 0x1f349, + 0x1f34a, 0x1f34e, 0x1f353, 0x1f354, + 0x1f358, 0x1f359, 0x1f35a, 0x1f35b, + 0x1f35c, 0x1f35d, 0x1f35e, 0x1f35f, + 0x1f361, 0x1f362, 0x1f363, 0x1f366, + 0x1f367, 0x1f370, 0x1f371, 0x1f372, + 0x1f373, 0x1f374, 0x1f375, 0x1f376, + 0x1f378, 0x1f37a, 0x1f37b, 0x1f380, + 0x1f381, 0x1f382, 0x1f383, 0x1f384, + 0x1f385, 0x1f386, 0x1f387, 0x1f388, + 0x1f389, 0x1f38c, 0x1f38d, 0x1f38e, + 0x1f38f, 0x1f390, 0x1f391, 0x1f392, + 0x1f393, 0x1f3a1, 0x1f3a2, 0x1f3a4, + 0x1f3a5, 0x1f3a6, 0x1f3a7, 0x1f3a8, + 0x1f3a9, 0x1f3ab, 0x1f3ac, 0x1f3af, + 0x1f3b0, 0x1f3b1, 0x1f3b5, 0x1f3b6, + 0x1f3b7, 0x1f3b8, 0x1f3ba, 0x1f3be, + 0x1f3bf, 0x1f3c0, 0x1f3c1, 0x1f3c3, + 0x1f3c4, 0x1f3c6, 0x1f3c8, 0x1f3ca, + 0x1f3e0, 0x1f3e2, 0x1f3e3, 0x1f3e5, + 0x1f3e6, 0x1f3e7, 0x1f3e8, 0x1f3e9, + 0x1f3ea, 0x1f3eb, 0x1f3ec, 0x1f3ed, + 0x1f3ef, 0x1f3f0, 0x1f40d, 0x1f40e, + 0x1f411, 0x1f412, 0x1f414, 0x1f417, + 0x1f418, 0x1f419, 0x1f41a, 0x1f41b, + 0x1f41f, 0x1f420, 0x1f424, 0x1f426, + 0x1f427, 0x1f428, 0x1f42b, 0x1f42c, + 0x1f42d, 0x1f42e, 0x1f42f, 0x1f430, + 0x1f431, 0x1f433, 0x1f434, 0x1f435, + 0x1f436, 0x1f437, 0x1f438, 0x1f439, + 0x1f43a, 0x1f43b, 0x1f440, 0x1f442, + 0x1f443, 0x1f444, 0x1f446, 0x1f447, + 0x1f448, 0x1f449, 0x1f44a, 0x1f44b, + 0x1f44c, 0x1f44d, 0x1f44e, 0x1f44f, + 0x1f450, 0x1f451, 0x1f452, 0x1f454, + 0x1f455, 0x1f457, 0x1f458, 0x1f459, + 0x1f45c, 0x1f45f, 0x1f460, 0x1f461, + 0x1f462, 0x1f463, 0x1f466, 0x1f467, + 0x1f468, 0x1f469, 0x1f46b, 0x1f46e, + 0x1f46f, 0x1f471, 0x1f472, 0x1f473, + 0x1f474, 0x1f475, 0x1f476, 0x1f477, + 0x1f478, 0x1f47b, 0x1f47c, 0x1f47d, + 0x1f47e, 0x1f47f, 0x1f480, 0x1f481, + 0x1f482, 0x1f483, 0x1f484, 0x1f485, + 0x1f486, 0x1f487, 0x1f488, 0x1f489, + 0x1f48a, 0x1f48b, 0x1f48d, 0x1f48e, + 0x1f48f, 0x1f490, 0x1f491, 0x1f492, + 0x1f493, 0x1f494, 0x1f497, 0x1f498, + 0x1f499, 0x1f49a, 0x1f49b, 0x1f49c, + 0x1f49d, 0x1f49f, 0x1f4a1, 0x1f4a2, + 0x1f4a3, 0x1f4a4, 0x1f4a6, 0x1f4a8, + 0x1f4a9, 0x1f4aa, 0x1f4b0, 0x1f4b1, + 0x1f4b9, 0x1f4ba, 0x1f4bb, 0x1f4bc, + 0x1f4bd, 0x1f4bf, 0x1f4c0, 0x1f4d6, + 0x1f4dd, 0x1f4e0, 0x1f4e1, 0x1f4e2, + 0x1f4e3, 0x1f4e9, 0x1f4eb, 0x1f4ee, + 0x1f4f1, 0x1f4f2, 0x1f4f3, 0x1f4f4, + 0x1f4f6, 0x1f4f7, 0x1f4fa, 0x1f4fb, + 0x1f4fc, 0x1f50a, 0x1f50d, 0x1f511, + 0x1f512, 0x1f513, 0x1f514, 0x1f51d, + 0x1f51e, 0x1f525, 0x1f528, 0x1f52b, + 0x1f52f, 0x1f530, 0x1f531, 0x1f532, + 0x1f533, 0x1f534, 0x1f550, 0x1f551, + 0x1f552, 0x1f553, 0x1f554, 0x1f555, + 0x1f556, 0x1f557, 0x1f558, 0x1f559, + 0x1f55a, 0x1f55b, 0x1f5fb, 0x1f5fc, + 0x1f5fd, 0x1f601, 0x1f602, 0x1f603, + 0x1f604, 0x1f609, 0x1f60a, 0x1f60c, + 0x1f60d, 0x1f60f, 0x1f612, 0x1f613, + 0x1f614, 0x1f616, 0x1f618, 0x1f61a, + 0x1f61c, 0x1f61d, 0x1f61e, 0x1f620, + 0x1f621, 0x1f622, 0x1f623, 0x1f625, + 0x1f628, 0x1f62a, 0x1f62d, 0x1f630, + 0x1f631, 0x1f632, 0x1f633, 0x1f637, + 0x1f645, 0x1f646, 0x1f647, 0x1f64c, + 0x1f64f, 0x1f680, 0x1f683, 0x1f684, + 0x1f685, 0x1f687, 0x1f689, 0x1f68c, + 0x1f68f, 0x1f691, 0x1f692, 0x1f693, + 0x1f695, 0x1f697, 0x1f699, 0x1f69a, + 0x1f6a2, 0x1f6a4, 0x1f6a5, 0x1f6a7, + 0x1f6ac, 0x1f6ad, 0x1f6b2, 0x1f6b6, + 0x1f6b9, 0x1f6ba, 0x1f6bb, 0x1f6bc, + 0x1f6bd, 0x1f6be, 0x1f6c0, }; + +const int mb_tbl_uni_sb2code3_value[] = { // 0x1f004 - 0x1f6c0 + 0x27d5, 0x2b29, 0x2b2a, 0x2b2c, + 0x27f7, 0x2b2b, 0x281b, 0x2830, + 0x2819, 0x2854, 0x281a, 0x27d6, + 0x2b0a, 0x2b05, 0x2b08, 0x2b04, + 0x2b07, 0x2b06, 0x2b02, 0x2b0b, + 0x2b09, 0x2b03, 0x280a, 0x282f, + 0x281d, 0x2833, 0x2832, 0x2831, + 0x281c, 0x281e, 0x281f, 0x282e, + 0x2834, 0x282d, 0x2adb, 0x2ad4, + 0x2ae3, 0x296d, 0x2ae1, 0x27ee, + 0x2ae2, 0x2ae4, 0x2ad6, 0x296c, + 0x29b4, 0x2986, 0x2987, 0x2983, + 0x2950, 0x2952, 0x2982, 0x2984, + 0x2adc, 0x27b8, 0x27c0, 0x27c1, + 0x2adf, 0x29c8, 0x29c9, 0x29c7, + 0x29c5, 0x29c4, 0x29c6, 0x27c8, + 0x29bc, 0x29c1, 0x29bd, 0x29c0, + 0x29bf, 0x29be, 0x29b8, 0x29ba, + 0x29bb, 0x29c2, 0x29c3, 0x29b9, + 0x2ad7, 0x2966, 0x29cb, 0x29cc, + 0x27ef, 0x2963, 0x29b7, 0x298a, + 0x2964, 0x2967, 0x298b, 0x2993, + 0x27ba, 0x29ca, 0x2add, 0x2953, + 0x2ae0, 0x27bf, 0x2ad8, 0x298f, + 0x2991, 0x27eb, 0x2ace, 0x2ad0, + 0x2ad3, 0x2ada, 0x2ade, 0x2ad2, + 0x2ad1, 0x27cc, 0x2acb, 0x295c, + 0x295d, 0x2afe, 0x2989, 0x2af9, + 0x2afa, 0x27cd, 0x29a3, 0x27d8, + 0x27db, 0x2ac4, 0x295e, 0x29a5, + 0x2960, 0x2961, 0x2962, 0x2935, + 0x2933, 0x2ac2, 0x27da, 0x27bd, + 0x2937, 0x27d9, 0x2ac3, 0x2ac5, + 0x2956, 0x2958, 0x27fb, 0x27fd, + 0x27f5, 0x27fc, 0x2800, 0x2af8, + 0x27fe, 0x27ff, 0x2afb, 0x2aff, + 0x2afc, 0x2afd, 0x2b24, 0x27dc, + 0x2b20, 0x2b1f, 0x2b25, 0x2b26, + 0x2b1d, 0x27b2, 0x2ad9, 0x2b1c, + 0x2939, 0x2b19, 0x2b1a, 0x2b18, + 0x2975, 0x2b1e, 0x2b27, 0x2b17, + 0x2973, 0x2b22, 0x2970, 0x2b23, + 0x296f, 0x2974, 0x293a, 0x27b1, + 0x2972, 0x27b3, 0x2b28, 0x2b1b, + 0x2b21, 0x2971, 0x2ab1, 0x2ab3, + 0x2ab2, 0x2ab4, 0x2835, 0x2836, + 0x2837, 0x2838, 0x292d, 0x2ab6, + 0x2ab8, 0x292e, 0x2ab9, 0x2ab7, + 0x2aba, 0x27b6, 0x2997, 0x2981, + 0x2926, 0x2998, 0x29a0, 0x29a1, + 0x29a2, 0x2927, 0x27e6, 0x2999, + 0x299a, 0x2b2d, 0x2921, 0x2922, + 0x2924, 0x2925, 0x2ac0, 0x27fa, + 0x2ac1, 0x2b0c, 0x2b0d, 0x2b0e, + 0x2b0f, 0x2b10, 0x2b11, 0x2b12, + 0x2b13, 0x27c3, 0x296e, 0x27b4, + 0x27d3, 0x27c2, 0x27c4, 0x285a, + 0x2b15, 0x2b16, 0x299b, 0x299c, + 0x299d, 0x299e, 0x299f, 0x27e3, + 0x298e, 0x2923, 0x2954, 0x2955, + 0x27b9, 0x2985, 0x2abd, 0x2ad5, + 0x29a6, 0x2943, 0x29a7, 0x29a8, + 0x29a9, 0x29aa, 0x29ab, 0x29ac, + 0x2acf, 0x280b, 0x27b7, 0x29b3, + 0x2990, 0x27e4, 0x29b0, 0x29af, + 0x297a, 0x27f4, 0x27d7, 0x27f1, + 0x27f2, 0x27c7, 0x292c, 0x27c6, + 0x2995, 0x27ce, 0x27cf, 0x27f0, + 0x2980, 0x292b, 0x27f3, 0x27ea, + 0x2996, 0x27ab, 0x27a9, 0x27aa, + 0x292a, 0x27ac, 0x2857, 0x2858, + 0x2812, 0x2928, 0x27d2, 0x27d0, + 0x27d1, 0x27e9, 0x27bc, 0x295f, + 0x27ec, 0x27ed, 0x29a4, 0x2853, + 0x280e, 0x27c5, 0x27be, 0x27bb, + 0x2845, 0x2810, 0x2951, 0x2821, + 0x2822, 0x2820, 0x2944, 0x2945, + 0x2946, 0x2947, 0x2948, 0x2949, + 0x294a, 0x294b, 0x294c, 0x294d, + 0x294e, 0x294f, 0x295b, 0x2b00, + 0x2b14, 0x2a9c, 0x2aaa, 0x2977, + 0x2aad, 0x2a9d, 0x2976, 0x2aa2, + 0x27ae, 0x2a9a, 0x2aa6, 0x27b0, + 0x2a9b, 0x2a9f, 0x2ab0, 0x2aaf, + 0x27ad, 0x2aa1, 0x2978, 0x2979, + 0x2aae, 0x2aab, 0x2a9e, 0x2a99, + 0x2aa3, 0x2aa0, 0x2aa9, 0x2aa7, + 0x27af, 0x2aa8, 0x2aa5, 0x2aa4, + 0x2abb, 0x2abc, 0x2abe, 0x2abf, + 0x2ab5, 0x27b5, 0x293e, 0x2acd, + 0x293f, 0x2acc, 0x2959, 0x2801, + 0x27f8, 0x2ac9, 0x2ac8, 0x2aca, + 0x2802, 0x293b, 0x2ac6, 0x2ac7, + 0x2809, 0x27dd, 0x27f6, 0x27df, + 0x298d, 0x280f, 0x27de, 0x2808, + 0x27e0, 0x27e1, 0x27f9, 0x27e2, + 0x27e8, 0x2988, 0x27e7, }; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_cp5022x.c b/ext/mbstring/libmbfl/filters/mbfilter_cp5022x.c index 96a8758879b0d..8d733a9d19799 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_cp5022x.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_cp5022x.c @@ -250,7 +250,7 @@ mbfl_filt_conv_jis_ms_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(0x203e, filter->data)); } else if (filter->status == 0x20 && c > 0x20 && c < 0x60) { /* kana */ CK((*filter->output_function)(0xff40 + c, filter->data)); - } else if ((filter->status == 0x80 || filter->status == 0x90) && c > 0x20 && c < 0x7f) { /* kanji first char */ + } else if ((filter->status == 0x80 || filter->status == 0x90) && c > 0x20 && c < 0x93) { /* kanji first char */ filter->cache = c; filter->status += 1; } else if (c >= 0 && c < 0x80) { /* latin, CTLs */ @@ -282,10 +282,7 @@ mbfl_filt_conv_jis_ms_wchar(int c, mbfl_convert_filter *filter) w = cp932ext3_ucs_table[s - cp932ext3_ucs_table_min]; } else if (s >= 94 * 94 && s < 114 * 94) { /* user-defined => PUA (Microsoft extended) */ - w = (s & 0xff) + ((s >> 8) - 94) * 94 + 0xe000; - } else if (s >= 212 * 94 && s < 222 * 94) { - /* user-defined => PUA (G3 85 - 94 Ku) */ - w = (s & 0xff) + ((s >> 8) - 212) * 94 + 0xe000 + 10 * 94; + w = s - 94*94 + 0xe000; } else { w = 0; } diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c new file mode 100644 index 0000000000000..b70515f6321cb --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c @@ -0,0 +1,865 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * the source code included in this files was separated from mbfilter_sjis_open.c + * by Rui Hirokawa on 25 July 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_sjis_mac.h" + +#include "unicode_table_cp932_ext.h" +#include "unicode_table_jis.h" + +static int mbfl_filt_ident_sjis_mac(int c, mbfl_identify_filter *filter); + +static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 +}; + +static const char *mbfl_encoding_sjis_mac_aliases[] = {"MacJapanese", "x-Mac-Japanese", NULL}; + +const mbfl_encoding mbfl_encoding_sjis_mac = { + mbfl_no_encoding_sjis_mac, + "SJIS-mac", + "Shift_JIS", + (const char *(*)[])&mbfl_encoding_sjis_mac_aliases, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const struct mbfl_identify_vtbl vtbl_identify_sjis_mac = { + mbfl_no_encoding_sjis_mac, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_sjis_mac +}; + +const struct mbfl_convert_vtbl vtbl_sjis_mac_wchar = { + mbfl_no_encoding_sjis_mac, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mac_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_mac = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_mac, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mac, + mbfl_filt_conv_sjis_mac_flush +}; + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + +#define SJIS_ENCODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + s1--; \ + s1 >>= 1; \ + if ((c1) < 0x5f) { \ + s1 += 0x71; \ + } else { \ + s1 += 0xb1; \ + } \ + s2 = c2; \ + if ((c1) & 1) { \ + if ((c2) < 0x60) { \ + s2--; \ + } \ + s2 += 0x20; \ + } else { \ + s2 += 0x7e; \ + } \ + } while (0) + +#define SJIS_DECODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + if (s1 < 0xa0) { \ + s1 -= 0x81; \ + } else { \ + s1 -= 0xc1; \ + } \ + s1 <<= 1; \ + s1 += 0x21; \ + s2 = c2; \ + if (s2 < 0x9f) { \ + if (s2 < 0x7f) { \ + s2++; \ + } \ + s2 -= 0x20; \ + } else { \ + s1++; \ + s2 -= 0x7e; \ + } \ + } while (0) + +#include "sjis_mac2uni.h" + +const int code_tbl[][3] = { + {0x02f0, 0x0303, 0x2460}, + {0x030e, 0x0321, 0x2474}, + {0x032c, 0x0334, 0x2776}, + {0x0341, 0x0349, 0x2488}, + {0x034e, 0x0359, 0x2160}, + {0x0362, 0x036d, 0x2170}, + {0x038a, 0x03a3, 0x249c}, +}; + +const int code_ofst_tbl[] [2]= { + {0x03ac, 0x03c9}, + {0x0406, 0x0420}, + {0x0432, 0x0441}, + {0x0468, 0x0480}, + {0x04b8, 0x04e8}, + {0x050c, 0x0551}, + {0x1ed9, 0x1f18}, + {0x1ff2, 0x20a5}, +}; + +const int *code_map[] = { + sjis_mac2wchar1, sjis_mac2wchar2, sjis_mac2wchar3, sjis_mac2wchar4, + sjis_mac2wchar5, sjis_mac2wchar6, sjis_mac2wchar7, sjis_mac2wchar8}; + +const int code_tbl_m[][6] = { + {0x0340, 0xf860, 0x0030, 0x002e, 0x0000, 0x0000}, + {0x03c9, 0xf860, 0x0054, 0x0042, 0x0000, 0x0000}, + {0x035c, 0xf860, 0x0058, 0x0056, 0x0000, 0x0000}, + {0x0370, 0xf860, 0x0078, 0x0076, 0x0000, 0x0000}, + {0x0439, 0xf860, 0x2193, 0x2191, 0x0000, 0x0000}, + {0x0409, 0xf861, 0x0046, 0x0041, 0x0058, 0x0000}, + {0x035b, 0xf861, 0x0058, 0x0049, 0x0056, 0x0000}, + {0x036f, 0xf861, 0x0078, 0x0069, 0x0076, 0x0000}, + {0x035a, 0xf862, 0x0058, 0x0049, 0x0049, 0x0049}, + {0x036e, 0xf862, 0x0078, 0x0069, 0x0069, 0x0069}, + {0x0522, 0xf862, 0x6709, 0x9650, 0x4f1a, 0x793e}, + {0x0523, 0xf862, 0x8ca1, 0x56e3, 0x6cd5, 0x4eba}, +}; + +const int s_form_tbl[] = { + 0x2010,0x2016,0x2026, + 0x3001,0x3002,0x301c,0x3041,0x3043,0x3045,0x3047,0x3049, + 0x3063,0x3083,0x3085,0x3087,0x308e,0x30a1,0x30a3,0x30a5, + 0x30a7,0x30a9,0x30c3,0x30e3,0x30e5,0x30e7,0x30ee,0x30f5, + 0x30f6,0x30fc,0xff1d,0xff3b,0xff3d,0xff5c,0xffe3, // vertical f87e (34) + 0x2026,0xff47,0xff4d, // halfwidth f87f (3) + 0x5927,0x5c0f,0x63a7, // enclosing circle 20dd (3) + 0x21e6,0x21e7,0x21e8,0x21e9, // black arrow f87a (4) +}; + +const int s_form_sjis_tbl[] = { + 0xeb5d,0xeb61,0xeb63, + 0xeb41,0xeb42,0xeb60,0xec9f,0xeca1,0xeca3,0xeca5,0xeca7, + 0xecc1,0xece1,0xece3,0xece5,0xecec,0xed40,0xed42,0xed44, + 0xed46,0xed48,0xed62,0xed83,0xed85,0xed87,0xed8e,0xed95, + 0xed96,0xeb5b,0xeb81,0xeb6d,0xeb6e,0xeb62,0xeb50, // vertical + 0x00ff,0x864b,0x8645, // halfwidth + 0x8791,0x8792,0x879d, // enclosing circle + 0x86d4,0x86d5,0x86d3,0x86d6, // black arrow +}; + +const int s_form_sjis_fallback_tbl[] = { + 0x815d,0x8161,0x8163, + 0x8141,0x8142,0x8160,0x829f,0x82a1,0x82a3,0x82a5,0x82a7, + 0x82c1,0x82e1,0x82e3,0x82e5,0x82ec,0x8340,0x8342,0x8344, + 0x8346,0x8348,0x8362,0x8383,0x8385,0x8387,0x838e,0x8395, + 0x8396,0x815b,0x8181,0x816d,0x816e,0x8162,0x8150, // vertical + 0x815d,0x8287,0x828d, // halfwidth + 0x91e5,0x8fac,0x8d54, // enclosing circle + 0x86d0,0x86d1,0x86cf,0x86d2, // arrow +}; + +const int wchar2sjis_mac_r_tbl[][3] = { + {0x2160, 0x216b, 0x034e}, + {0x2170, 0x217b, 0x0362}, + {0x2460, 0x2473, 0x02f0}, + {0x2474, 0x2487, 0x030e}, + {0x2488, 0x2490, 0x0341}, + {0x249c, 0x24b5, 0x038a}, + {0x2776, 0x277e, 0x032c}, + {0x30f7, 0x30fa, 0x054e}, + {0x32a4, 0x32a9, 0x04ba}, +}; + +const int wchar2sjis_mac_r_map[][2] = { + {0x2660, 0x2667}, + {0x322a, 0x3243}, + {0x3296, 0x329e}, + {0x3300, 0x33d4}, + {0xfe30, 0xfe44}, +}; + +const int *wchar2sjis_mac_code_map[] = { + wchar2sjis_mac4, wchar2sjis_mac7, wchar2sjis_mac8, wchar2sjis_mac9, wchar2sjis_mac10}; + +const int wchar2sjis_mac_wchar_tbl[][2] = { + {0x2109, 0x03c2}, + {0x2110, 0x21ef5}, + {0x2113, 0x03bc}, + {0x2116, 0x0406}, + {0x2121, 0x0408}, + {0x21c4, 0x0437}, + {0x21c5, 0x0438}, + {0x21c6, 0x0436}, + {0x21e6, 0x043b}, + {0x21e7, 0x043c}, + {0x21e8, 0x043a}, + {0x21e9, 0x043d}, + {0x221f, 0x0525}, + {0x222e, 0x0524}, + {0x22bf, 0x0526}, + {0x260e, 0x041f}, + {0x261c, 0x0433}, + {0x261d, 0x0434}, + {0x261e, 0x0432}, + {0x261f, 0x0435}, + {0x3004, 0x0420}, + {0x301d, 0x0538}, + {0x301f, 0x0539}, + {0x3020, 0x041e}, + {0x3094, 0x054c}, +}; + + + +/* + * SJIS-mac => wchar + */ +int +mbfl_filt_conv_sjis_mac_wchar(int c, mbfl_convert_filter *filter) +{ + int i, j, n; + int c1, s, s1, s2, w; + + switch (filter->status) { + case 0: + if (c >= 0 && c < 0x80 && c != 0x5c) { /* latin */ + CK((*filter->output_function)(c, filter->data)); + } else if (c > 0xa0 && c < 0xe0) { /* kana */ + CK((*filter->output_function)(0xfec0 + c, filter->data)); + } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ + filter->status = 1; + filter->cache = c; + } else if (c == 0x5c) { + CK((*filter->output_function)(0x00a5, filter->data)); + } else if (c == 0x80) { + CK((*filter->output_function)(0x005c, filter->data)); + } else if (c == 0xa0) { + CK((*filter->output_function)(0x00a0, filter->data)); + } else if (c == 0xfd) { + CK((*filter->output_function)(0x00a9, filter->data)); + } else if (c == 0xfe) { + CK((*filter->output_function)(0x2122, filter->data)); + } else if (c == 0xff) { + CK((*filter->output_function)(0x2026, filter->data)); + CK((*filter->output_function)(0xf87f, filter->data)); + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + case 1: /* kanji second char */ + filter->status = 0; + c1 = filter->cache; + if (c >= 0x40 && c <= 0xfc && c != 0x7f) { + w = 0; + SJIS_DECODE(c1, c, s1, s2); + s = (s1 - 0x21)*94 + s2 - 0x21; + if (s <= 0x89) { + if (s == 0x1c) { + w = 0x2014; /* EM DASH */ + } else if (s == 0x1f) { + w = 0xff3c; /* FULLWIDTH REVERSE SOLIDUS */ + } else if (s == 0x20) { + w = 0x301c; /* FULLWIDTH TILDE */ + } else if (s == 0x21) { + w = 0x2016; /* PARALLEL TO */ + } else if (s == 0x3c) { + w = 0x2212; /* FULLWIDTH HYPHEN-MINUS */ + } else if (s == 0x50) { + w = 0x00a2; /* FULLWIDTH CENT SIGN */ + } else if (s == 0x51) { + w = 0x00a3; /* FULLWIDTH POUND SIGN */ + } else if (s == 0x89) { + w = 0x00ac; /* FULLWIDTH NOT SIGN */ + } + } + + /* apple gaiji area 0x8540 - 0x886d */ + if (w == 0) { + for (i=0; i<7; i++) { + if (s >= code_tbl[i][0] && s <= code_tbl[i][1]) { + w = s - code_tbl[i][0] + code_tbl[i][2]; + break; + } + } + } + + if (w == 0) { + + for (i=0; i<12; i++) { + if (s == code_tbl_m[i][0]) { + if (code_tbl_m[i][1] == 0xf860) { + n = 4; + } else if (code_tbl_m[i][1] == 0xf861) { + n = 5; + } else { + n = 6; + } + for (j=1; joutput_function)(code_tbl_m[i][j], filter->data)); + } + w = code_tbl_m[i][n-1]; + break; + } + } + } + + if (w == 0) { + for (i=0; i<8; i++) { + if (s >= code_ofst_tbl[i][0] && s <= code_ofst_tbl[i][1]) { + w = code_map[i][s - code_ofst_tbl[i][0]]; + if (w >= 0x10000) { + CK((*filter->output_function)(w & 0xffff, filter->data)); + if (w & 0x10000) { + w = 0xf87a; + } else if (w & 0x20000) { + w = 0xf87e; + } else if (w & 0x40000) { + w = 0xf87f; + } else if (w & 0x80000) { + w = 0x20dd; + } else if (w & 0xF0000) { + // TBD + w = 0; + } else { + w = 0; + } + } + + break; + } + } + } + + if (w == 0 && s >= 0 && s < jisx0208_ucs_table_size) { /* X 0208 */ + w = jisx0208_ucs_table[s]; + } + + if (w <= 0) { + w = (s1 << 8) | s2; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_WINCP932; + } + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + w = (c1 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + default: + filter->status = 0; + break; + } + + return c; +} + +/* + * wchar => SJIS-mac + */ +int +mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) +{ + int i, j; + int c1, c2, s1, s2, mode; + + s1 = 0; + s2 = 0; + + // a1: U+0000 -> U+046F + // a2: U+2000 -> U+30FF + // i: U+4E00 -> U+9FFF + // r: U+FF00 -> U+FFFF + + switch (filter->status) { + + case 1: + c1 = filter->cache; + filter->cache = 0; + filter->status = 0; + + s1 = 0; + s2 = 0; + + if (c == 0xf87a) { + for (i=0;i<4;i++) { + if (c1 == s_form_tbl[i+34+3+3]) { + s1 = s_form_sjis_tbl[i+34+3+3]; + break; + } + } + if (s1 <= 0) { + s2 = c1; + } + } else if (c == 0x20dd) { + for (i=0;i<3;i++) { + if (c1 == s_form_tbl[i+34+3]) { + s1 = s_form_sjis_tbl[i+34+3]; + break; + } + } + if (s1 <= 0) { + s2 = c1; + } + } else if (c == 0xf87f) { + for (i=0;i<3;i++) { + if (c1 == s_form_tbl[i+34]) { + s1 = s_form_sjis_tbl[i+34]; + break; + } + } + if (s1 <= 0) { + s2 = c1; s1 = -1; + } + } else if (c == 0xf87e) { + for (i=0;i<34;i++) { + if (c1 == s_form_tbl[i]) { + s1 = s_form_sjis_tbl[i]; + break; + } + } + if (s1 <= 0) { + s2 = c1; s1 = -1; + } + } else { + s2 = c1; + s1 = c; + } + + if (s2 > 0) { + for (i=0;i= 0) { + if (s1 < 0x100) { + CK((*filter->output_function)(s1, filter->data)); + } else { + CK((*filter->output_function)((s1 >> 8) & 0xff, filter->data)); + CK((*filter->output_function)(s1 & 0xff, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + + if (s2 <= 0 || s1 == -1) { + break; + } + + case 0: + + if (c >= ucs_a1_jis_table_min && c < ucs_a1_jis_table_max) { + s1 = ucs_a1_jis_table[c - ucs_a1_jis_table_min]; + if (c == 0x5c) { + s1 = 0x80; + } else if (c == 0xa9) { + s1 = 0xfd; + } + } else if (c >= ucs_a2_jis_table_min && c < ucs_a2_jis_table_max) { + s1 = ucs_a2_jis_table[c - ucs_a2_jis_table_min]; + if (c == 0x2122) { + s1 = 0xfe; + } else if (c == 0x2014) { + s1 = 0x213d; + } else if (c == 0x2116) { + s1 = 0x2c1d; + } + } else if (c >= ucs_i_jis_table_min && c < ucs_i_jis_table_max) { + s1 = ucs_i_jis_table[c - ucs_i_jis_table_min]; + } else if (c >= ucs_r_jis_table_min && c < ucs_r_jis_table_max) { + s1 = ucs_r_jis_table[c - ucs_r_jis_table_min]; + } + + if (c >= 0x2000) { + for (i=0;istatus = 1; + filter->cache = c; + return c; + } + } + + if (c == 0xf860 || c == 0xf861 || c == 0xf862) { + filter->status = 2; + filter->cache = c; + return c; + } + } + + if (s1 <= 0) { + c1 = c & ~MBFL_WCSPLANE_MASK; + if (c1 == MBFL_WCSPLANE_WINCP932) { + s1 = c & MBFL_WCSPLANE_MASK; + s2 = 1; + } else if (c1 == MBFL_WCSPLANE_JIS0208) { + s1 = c & MBFL_WCSPLANE_MASK; + } else if (c1 == MBFL_WCSPLANE_JIS0212) { + s1 = c & MBFL_WCSPLANE_MASK; + s1 |= 0x8080; + } else if (c == 0xa0) { + s1 = 0x00a0; + } else if (c == 0xa5) { /* YEN SIGN */ + s1 = 0x005c; + } else if (c == 0xff3c) { /* FULLWIDTH REVERSE SOLIDUS */ + s1 = 0x2140; + } + } + + if (s1 <= 0) { + for (i=0; i= wchar2sjis_mac_r_tbl[i][0] && c <= wchar2sjis_mac_r_tbl[i][1]) { + s1 = c - wchar2sjis_mac_r_tbl[i][0] + wchar2sjis_mac_r_tbl[i][2]; + break; + } + } + + if (s1 <= 0) { + for (i=0; i= wchar2sjis_mac_r_map[i][0] && c <= wchar2sjis_mac_r_map[i][1]) { + s1 = wchar2sjis_mac_code_map[i][c-wchar2sjis_mac_r_map[i][0]]; + break; + } + } + } + + if (s1 <= 0) { + for (i=0; i 0) { + c1 = s1/94+0x21; + c2 = s1-94*(c1-0x21)+0x21; + s1 = (c1 << 8) | c2; + s2 = 1; + } + } + + if ((s1 <= 0) || (s1 >= 0x8080 && s2 == 0)) { /* not found or X 0212 */ + s1 = -1; + c1 = 0; + + if (c == 0) { + s1 = 0; + } else if (s1 <= 0) { + s1 = -1; + } + } + + if (s1 >= 0) { + if (s1 < 0x100) { /* latin or kana */ + CK((*filter->output_function)(s1, filter->data)); + } else { /* kanji */ + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + break; + + + case 2: + c1 = filter->cache; + filter->cache = 0; + filter->status = 0; + if (c1 == 0xf860) { + for (i=0; i<5; i++) { + if (c == code_tbl_m[i][2]) { + filter->cache = c | 0x10000; + filter->status = 3; + break; + } + } + } else if (c1 == 0xf861) { + for (i=0; i<3; i++) { + if (c == code_tbl_m[i+5][2]) { + filter->cache = c | 0x20000; + filter->status = 3; + break; + } + } + } else if (c1 == 0xf862) { + for (i=0; i<4; i++) { + if (c == code_tbl_m[i+5+3][2]) { + filter->cache = c | 0x40000; + filter->status = 3; + break; + } + } + } + + if (filter->status == 0 && filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c1, filter)); + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + + break; + + case 3: + s1 = 0; + c1 = filter->cache & 0xffff; + mode = (filter->cache & 0xf0000) >> 16; + + filter->cache = 0; + filter->status = 0; + + if (mode == 0x1) { + for (i=0; i<5; i++) { + if (c1 == code_tbl_m[i][2] && c == code_tbl_m[i][3]) { + s1 = code_tbl_m[i][0]; + break; + } + } + + if (s1 > 0) { + c1 = s1/94+0x21; + c2 = s1-94*(c1-0x21)+0x21; + SJIS_ENCODE(c1, c2, s1, s2); + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + + if (s1 <= 0 && filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(0xf860, filter)); + CK(mbfl_filt_conv_illegal_output(c1, filter)); + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + + } else if (mode == 0x2) { + for (i=0; i<3; i++) { + if (c1 == code_tbl_m[i+5][2] && c == code_tbl_m[i+5][3]) { + filter->cache = c | 0x20000; + filter->status = 4; + break; + } + } + } else if (mode == 0x4) { + for (i=0; i<4; i++) { + if (c1 == code_tbl_m[i+8][2] && c == code_tbl_m[i+8][3]) { + filter->cache = c | 0x40000; + filter->status = 4; + break; + } + } + } + break; + + case 4: + s1 = 0; + c1 = filter->cache & 0xffff; + mode = (filter->cache & 0xf0000) >> 16; + + filter->cache = 0; + filter->status = 0; + + if (mode == 0x2) { + for (i=0; i<3; i++) { + if (c1 == code_tbl_m[i+5][3] && c == code_tbl_m[i+5][4]) { + s1 = code_tbl_m[i+5][0]; + break; + } + } + + if (s1 > 0) { + c1 = s1/94+0x21; + c2 = s1-94*(c1-0x21)+0x21; + SJIS_ENCODE(c1, c2, s1, s2); + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + + if (s1 <= 0 && filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(0xf861, filter)); + for (i=0; i<3; i++) { + if (c1 == code_tbl_m[i+5][3]) { + CK(mbfl_filt_conv_illegal_output(code_tbl_m[i+5][2], filter)); + break; + } + } + CK(mbfl_filt_conv_illegal_output(c1, filter)); + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } else if (mode == 0x4) { + for (i=0; i<4; i++) { + if (c1 == code_tbl_m[i+8][3] && c == code_tbl_m[i+8][4]) { + filter->cache = c | 0x40000; + filter->status = 5; + break; + } + } + } + break; + + case 5: + s1 = 0; + c1 = filter->cache & 0xffff; + mode = (filter->cache & 0xf0000) >> 16; + + filter->cache = 0; + filter->status = 0; + + if (mode == 0x4) { + for (i=0; i<4; i++) { + if (c1 == code_tbl_m[i+8][4] && c == code_tbl_m[i+8][5]) { + s1 = code_tbl_m[i+8][0]; + break; + } + } + + if (s1 > 0) { + c1 = s1/94+0x21; + c2 = s1-94*(c1-0x21)+0x21; + SJIS_ENCODE(c1, c2, s1, s2); + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + + if (s1 <= 0 && filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(0xf862, filter)); + for (i=0; i<4; i++) { + if (c1 == code_tbl_m[i+8][4]) { + CK(mbfl_filt_conv_illegal_output( code_tbl_m[i+8][2], filter)); + CK(mbfl_filt_conv_illegal_output( code_tbl_m[i+8][3], filter)); + break; + } + } + CK(mbfl_filt_conv_illegal_output(c1, filter)); + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + break; + + default: + filter->status = 0; + break; + } + return c; +} + +int +mbfl_filt_conv_sjis_mac_flush(mbfl_convert_filter *filter) +{ + int i, c1, s1 = 0; + if (filter->status == 1 && filter->cache > 0) { + c1 = filter->cache; + for (i=0;i 0) { + CK((*filter->output_function)((s1 >> 8) & 0xff, filter->data)); + CK((*filter->output_function)(s1 & 0xff, filter->data)); + } + } + filter->cache = 0; + filter->status = 0; + + if (filter->flush_function != NULL) { + return (*filter->flush_function)(filter->data); + } + + return 0; +} + +static int mbfl_filt_ident_sjis_mac(int c, mbfl_identify_filter *filter) +{ + if (filter->status) { /* kanji second char */ + if (c < 0x40 || c > 0xfc || c == 0x7f) { /* bad */ + filter->flag = 1; + } + filter->status = 0; + } else if (c >= 0 && c < 0x80) { /* latin ok */ + ; + } else if (c > 0xa0 && c < 0xe0) { /* kana ok */ + ; + } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ + filter->status = 1; + } else { /* bad */ + filter->flag = 1; + } + + return c; +} + + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h new file mode 100644 index 0000000000000..3f332d9a6c2f4 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h @@ -0,0 +1,45 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * the source code included in this files was separated from mbfilter_sjis_open.c + * by Rui Hirokawa on 25 July 2011. + * + */ + +#ifndef MBFL_MBFILTER_SJIS_MAC_H +#define MBFL_MBFILTER_SJIS_MAC_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_sjis_mac; + +extern const struct mbfl_identify_vtbl vtbl_identify_sjis_mac; +extern const struct mbfl_convert_vtbl vtbl_sjis_mac_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_mac; + +int mbfl_filt_conv_sjis_mac_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_sjis_mac_flush(mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_SJIS_MAC_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c new file mode 100644 index 0000000000000..62cb186f9f957 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -0,0 +1,1103 @@ + +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * the source code included in this files was separated from mbfilter_sjis_open.c + * by Rui Hirokawa on 25 July 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_sjis_mobile.h" + +#include "unicode_table_cp932_ext.h" +#include "unicode_table_jis.h" + +#include "emoji2uni.h" + +static int mbfl_filt_ident_sjis_mobile(int c, mbfl_identify_filter *filter); + +static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 +}; + +const mbfl_encoding mbfl_encoding_sjis_docomo = { + mbfl_no_encoding_sjis_docomo, + "SJIS-Mobile#DOCOMO", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const mbfl_encoding mbfl_encoding_sjis_kddi = { + mbfl_no_encoding_sjis_kddi, + "SJIS-Mobile#KDDI", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const mbfl_encoding mbfl_encoding_sjis_sb = { + mbfl_no_encoding_sjis_sb, + "SJIS-Mobile#SOFTBANK", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const mbfl_encoding mbfl_encoding_sjis_docomo_pua = { + mbfl_no_encoding_sjis_docomo_pua, + "SJIS-Mobile#DOCOMO-PUA", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const mbfl_encoding mbfl_encoding_sjis_kddi_pua = { + mbfl_no_encoding_sjis_kddi_pua, + "SJIS-Mobile#KDDI-PUA", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const mbfl_encoding mbfl_encoding_sjis_kddi_pua_b = { + mbfl_no_encoding_sjis_kddi_pua_b, + "SJIS-Mobile#KDDI-PUA-B", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const mbfl_encoding mbfl_encoding_sjis_sb_pua = { + mbfl_no_encoding_sjis_sb_pua, + "SJIS-Mobile#SOFTBANK-PUA", + "Shift_JIS", + NULL, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const struct mbfl_convert_vtbl vtbl_sjis_docomo_wchar = { + mbfl_no_encoding_sjis_docomo, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_docomo, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_sjis_kddi_wchar = { + mbfl_no_encoding_sjis_kddi, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_kddi, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_sjis_sb_wchar = { + mbfl_no_encoding_sjis_sb, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_sb, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_sjis_docomo_pua_wchar = { + mbfl_no_encoding_sjis_docomo_pua, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo_pua = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_docomo_pua, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_wchar = { + mbfl_no_encoding_sjis_kddi_pua, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_kddi_pua, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_b_wchar = { + mbfl_no_encoding_sjis_kddi_pua_b, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua_b = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_kddi_pua_b, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_sjis_sb_pua_wchar = { + mbfl_no_encoding_sjis_sb_pua, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_sjis_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis_sb_pua, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_sjis_mobile, + mbfl_filt_conv_common_flush +}; + + + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + +#define SJIS_ENCODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + s1--; \ + s1 >>= 1; \ + if ((c1) < 0x5f) { \ + s1 += 0x71; \ + } else { \ + s1 += 0xb1; \ + } \ + s2 = c2; \ + if ((c1) & 1) { \ + if ((c2) < 0x60) { \ + s2--; \ + } \ + s2 += 0x20; \ + } else { \ + s2 += 0x7e; \ + } \ + } while (0) + +#define SJIS_DECODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + if (s1 < 0xa0) { \ + s1 -= 0x81; \ + } else { \ + s1 -= 0xc1; \ + } \ + s1 <<= 1; \ + s1 += 0x21; \ + s2 = c2; \ + if (s2 < 0x9f) { \ + if (s2 < 0x7f) { \ + s2++; \ + } \ + s2 -= 0x20; \ + } else { \ + s1++; \ + s2 -= 0x7e; \ + } \ + } while (0) + +int +mbfiler_sjis_emoji_docomo2unicode(int s, int *snd) +{ + int w = s; + if (s >= mb_tbl_code2uni_docomo1_min && s <= mb_tbl_code2uni_docomo1_max) { + if (s >= mb_tbl_code2uni_docomo1_min + 0x00a2 && + s <= mb_tbl_code2uni_docomo1_min + 0x00ad && + s != mb_tbl_code2uni_docomo1_min + 0x00a3) { + w = 0x20E3; + *snd = mb_tbl_code2uni_docomo1[s - mb_tbl_code2uni_docomo1_min]; + } else { + w = mb_tbl_code2uni_docomo1[s - mb_tbl_code2uni_docomo1_min]; + *snd = 0; + if (!w) { + w = s; + } + } + } + return w; +} + +int +mbfiler_sjis_emoji_kddi2unicode(int s, int *snd) +{ + int w = s, si; + const char flags[][2] = {"FR","DE","IT","GB","CN","KR","ES","RU","JP","US"}; + + *snd = 0; + if (s >= mb_tbl_code2uni_kddi1_min && + s <= mb_tbl_code2uni_kddi1_max) { + si = s - mb_tbl_code2uni_kddi1_min; + if (si == 0x0008) { + *snd = 0x1F1A5 + flags[6][0]; w = 0x1F1A5 + flags[6][1]; + } else if (si == 0x0009) { + *snd = 0x1F1A5 + flags[7][0]; w = 0x1F1A5 + flags[7][1]; + } else if (si >= 0x008d && si <= 0x0092) { + *snd = 0x1F1A5 + flags[si - 0x8d][0]; + w = 0x1F1A5 + flags[si - 0x8d][1]; + } else if (si == 0x0104) { + *snd = 0x0023; w = 0x20E3; + } else { + w = mb_tbl_code2uni_kddi1[si]; + } + } else if (s >= mb_tbl_code2uni_kddi2_min && + s <= mb_tbl_code2uni_kddi2_max) { + si = s - mb_tbl_code2uni_kddi2_min; + if (si == 100) { + *snd = 0x1F1A5 + flags[8][0]; w = 0x1F1A5 + flags[8][1]; + } else if (si >= 0x00ba && si <= 0x00c2) { + *snd = si-0x00ba+0x0031; w = 0x20E3; + } else if (si == 0x010b) { + *snd = 0x1F1A5 + flags[9][0]; w = 0x1F1A5 + flags[9][1]; + } else if (si == 0x0144) { + *snd = 0x0030; w = 0x20E3; + } else { + w = mb_tbl_code2uni_kddi2[si]; + } + } + return w; +} + +int +mbfiler_sjis_emoji_sb2unicode(int s, int *snd) +{ + int w = s, si; + const char flags[][2] = {"JP","US","FR","DE","IT","GB","ES","RU","CN","KR"}; + + *snd = 0; + if (s >= mb_tbl_code2uni_sb1_min && + s <= mb_tbl_code2uni_sb1_max) { + si = s - mb_tbl_code2uni_sb1_min; + if (si == 0x006e || (si >= 0x007a && si <= 0x0083)) { + *snd = mb_tbl_code2uni_sb1[si]; + w = 0x20E3; + } else { + w = mb_tbl_code2uni_sb1[si]; + } + } else if (s >= mb_tbl_code2uni_sb2_min && + s <= mb_tbl_code2uni_sb2_max) { + si = s - mb_tbl_code2uni_sb2_min; + w = mb_tbl_code2uni_sb2[si]; + } else if (s >= mb_tbl_code2uni_sb3_min && + s <= mb_tbl_code2uni_sb3_max) { + si = s - mb_tbl_code2uni_sb3_min; + if (si >= 0x0069 && si <= 0x0072) { + *snd = 0x1F1A5 + flags[si - 0x0069][0]; + w = 0x1F1A5 + flags[si - 0x0069][1]; + } else { + w = mb_tbl_code2uni_sb3[si]; + } + } + return w; +} + +int +mbfiler_sjis_emoji_kddi2unicode_pua(int s, int *w) +{ + + if (s >= 0x26ec && s <= 0x2838) { + *w = s - 0x26ec + 0xe468; + } else if (s >= 0x284c && s <= 0x2863) { + *w = s - 0x284c + 0xe5b5; + } else if (s >= 0x24b8 && s <= 0x24ca) { + *w = s - 0x24b8 + 0xe5cd; + } else if (s >= 0x24cb && s <= 0x2545) { + *w = s - 0x24cb + 0xea80; + } else if (s >= 0x2839 && s <= 0x284b) { + *w = s - 0x2839 + 0xeafb; + } else if (s >= 0x2546 && s <= 0x25c0) { + *w = s - 0x2546 + 0xeb0e; + } + + return *w; +} + +int +mbfiler_sjis_emoji_kddi2unicode_pua_b(int s, int c1, int c, int *w) +{ + if ((c1 == 0xf3 && (c >= 0x40 && c<=0xfc && c != 0x7f)) || + (c1 == 0xf4 && (c >= 0x40 && c<=0x93 && c != 0x7f)) || + ((c1 == 0xf6 || c1 == 0xf7) && (c >= 0x40 && c<=0xfc && c != 0x7f))) { + *w = (c1 << 8) + c - 0x0700; /* KDDI unofficial UTF-8 encoding */ + } + return *w; +} + +int +mbfiler_sjis_emoji2unicode_pua(int s, int *w) +{ + if (s >= 0x27a9 && s <= 0x2802) { + *w = s - 0x27a9 + 0xe101; + } else if (s >= 0x2808 && s <= 0x285a) { + *w = s - 0x2808 + 0xe201; + } else if (s >= 0x2921 && s <= 0x297a) { + *w = s - 0x2921 + 0xe001; + } else if (s >= 0x2980 && s <= 0x29cc) { + *w = s - 0x2980 + 0xe301; + } else if (s >= 0x2a99 && s <= 0x2ae4) { + *w = s - 0x2a99 + 0xe401; + } else if (s >= 0x2af8 && s <= 0x2b2e) { + *w = s - 0x2af8 + 0xe501; + } + return *w; +} + +int +mbfiler_unicode_pua2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2) +{ + int match = 1; + + if (c >= 0xe468 && c <= 0xe5b4) { + *s1 = c - 0xe468 + 0x26ec; + } else if (c >= 0xe5b5 && c <= 0xe5cc) { + *s1 = c - 0xe5b5 + 0x284c; + } else if (c >= 0xe5cd && c <= 0xe5df) { + *s1 = c - 0xe5cd + 0x24b8; + } else if (c >= 0xea80 && c <= 0xeafa) { + *s1 = c - 0xea80 + 0x24cb; + } else if (c >= 0xeafb && c <= 0xeb0d) { + *s1 = c - 0xeafb + 0x2839; + } else if (c >= 0xeb0e && c <= 0xeb88) { + *s1 = c - 0xeb0e + 0x2546; + } else { + match = 0; + } + if (match && *s1 >0) { + *c1 = *s1/94+0x21; + *c2 = *s1-94*(*c1-0x21)+0x21; + *s1 = (*c1 << 8) | *c2; + *s2 = 1; + } + + return 1; +} + + + +int +mbfiler_unicode_pua2sjis_emoji(int c, int *s1, int *s2, int *c1, int *c2, int *sjis_encoded) +{ + int match = 1; + + if (c >= 0xe001 && c <= 0xe05a) { + *s1 = c - 0xe001 + 0x2921; + } else if (c >= 0xe101 && c <= 0xe15a) { + *s1 = c - 0xe101 + 0x27a9; + } else if (c >= 0xe201 && c <= 0xe253) { + *s1 = c - 0xe201 + 0x2808; + } else if (c >= 0xe301 && c <= 0xe34d) { + *s1 = c - 0xe301 + 0x2980; + } else if (c >= 0xe401 && c <= 0xe44c) { + *s1 = c - 0xe401 + 0x2a99; + } else if (c >= 0xe501 && c <= 0xe537) { + *s1 = c - 0xe501 + 0x2af8; + } else if ( + ((c >= 0xec40 && c<=0xecfc) && c != 0xec7f) || + ((c >= 0xed40 && c<=0xed93) && c != 0xed7f) || + ((c >= 0xef40 && c<=0xeffc) && c != 0xef7f) || + ((c >= 0xf040 && c<=0xf0fc) && c != 0xf07f)) { + /* KDDI unofficial UTF-8 encoding */ + *s1 = c + 0x0700; + *sjis_encoded = 1; + } else { + match = 0; + } + if (match && *sjis_encoded == 0 && *s1 >0) { + *c1 = *s1/94+0x21; + *c2 = *s1-94*(*c1-0x21)+0x21; + *s1 = (*c1 << 8) | *c2; + *s2 = 1; + } + + return 1; +} + +int +mbfiler_unicode2sjis_emoji_docomo(int c, int *s1, int *s2, int *c1, int *c2, mbfl_convert_filter *filter) +{ + int i, match = 0, c1s; + + if (filter->status == 1) { + c1s = filter->cache; + filter->cache = 0; + filter->status = 0; + if (c == 0x20E3) { + if (c1s == 0x0023) { + *s1 = 0x2964; + match = 1; + } else if (c1s == 0x0030) { + *s1 = 0x296f; + match = 1; + } else if (c1s >= 0x0031 && c1s <= 0x0039) { + *s1 = 0x2966 + (c1s - 0x0031); + match = 1; + } + } else { + if (c1s >= ucs_a1_jis_table_min && c1s < ucs_a1_jis_table_max) { + c1s = ucs_a1_jis_table[c1s - ucs_a1_jis_table_min]; + CK((*filter->output_function)(c1s, filter->data)); + } + } + } else { + if (c == 0x0023 || (c >= 0x0030 && c<=0x0039)) { + filter->status = 1; + filter->cache = c; + *s1 = -1; + return 0; + } + + if (c == 0x00A9) { + *s1 = 0x29b5; match = 1; + } else if (c == 0x00AE) { + *s1 = 0x29ba; match = 1; + } else if (c >= mb_tbl_uni_docomo2code2_min && c <= mb_tbl_uni_docomo2code2_max) { + for (i=0; i < sizeof(mb_tbl_uni_docomo2code2_key)/sizeof(int); i++) { + if (c >0 && mb_tbl_uni_docomo2code2_key[i] == c) { + *s1 = mb_tbl_uni_docomo2code2_value[i]; + match = 1; + break; + } + } + } else if (c >= mb_tbl_uni_docomo2code3_min && c <= mb_tbl_uni_docomo2code3_max) { + for (i=0; i < sizeof(mb_tbl_uni_docomo2code3_key)/sizeof(int); i++) { + if (c >0 && mb_tbl_uni_docomo2code3_key[i] == c) { + *s1 = mb_tbl_uni_docomo2code3_value[i]; + match = 1; + break; + } + } + } + } + + if (match && *s1 >0) { + *c1 = *s1/94+0x21; + *c2 = *s1-94*(*c1-0x21)+0x21; + *s1 = (*c1 << 8) | *c2; + *s2 = 1; + } + + return 1; +} + +const char nflags_s[][2] = {"CN","DE","ES","FR","GB","IT","JP","KR","RU","US"}; +const int nflags_code_kddi[] = {0x2549, 0x2546, 0x24c0, 0x2545, 0x2548, 0x2547, 0x2750, 0x254a, 0x24c1, 0x27f7}; +const int nflags_code_sb[] = {0x2b0a, 0x2b05, 0x2b08, 0x2b04, 0x2b07, 0x2b06, 0x2b02, 0x2b0b, 0x2b09, 0x2b03}; + +int +mbfiler_unicode2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2, mbfl_convert_filter *filter) +{ + int i, match = 0, c1s; + + if (filter->status == 1) { + c1s = filter->cache; + filter->cache = 0; + filter->status = 0; + if (c == 0x20E3) { + if (c1s == 0x0023) { + *s1 = 0x25bc; + match = 1; + } else if (c1s == 0x0030) { + *s1 = 0x2830; + match = 1; + } else if (c1s >= 0x0031 && c1s <= 0x0039) { + *s1 = 0x27a6 + (c1s - 0x0031); + match = 1; + } + } else if ((c >= 0x1F1A5 + 0x41 && c <= 0x1F1A5 + 0x5A) && + (c1s >= 0x1F1A5 + 0x41 && c1s <= 0x1F1A5 + 0x5A)) { + for (i=0;i<10;i++) { + if (c1s == 0x1F1A5 + nflags_s[i][0] && c == 0x1F1A5 + nflags_s[i][1]) { + *s1 = nflags_code_kddi[i]; + match = 1; + break; + } + } + } else { + if (c1s >= ucs_a1_jis_table_min && c1s < ucs_a1_jis_table_max) { + c1s = ucs_a1_jis_table[c1s - ucs_a1_jis_table_min]; + CK((*filter->output_function)(c1s, filter->data)); + } + } + } else { + if (c == 0x0023 || ( c >= 0x0030 && c<=0x0039) || + (c >= 0x1F1A5 + 0x41 && c<= 0x1F1A5 + 0x5A)) { + filter->status = 1; + filter->cache = c; + *s1 = -1; + return 0; + } + + if (c == 0x00A9) { + *s1 = 0x27dc; match = 1; + } else if (c == 0x00AE) { + *s1 = 0x27dd; match = 1; + } else if (c >= mb_tbl_uni_kddi2code2_min && c <= mb_tbl_uni_kddi2code2_max) { + for (i=0; i < sizeof(mb_tbl_uni_kddi2code2_key)/sizeof(int); i++) { + if (c >0 && mb_tbl_uni_kddi2code2_key[i] == c) { + *s1 = mb_tbl_uni_kddi2code2_value[i]; + match = 1; + break; + } + } + } else if (c >= mb_tbl_uni_kddi2code3_min && c <= mb_tbl_uni_kddi2code3_max) { + for (i=0; i < sizeof(mb_tbl_uni_kddi2code3_key)/sizeof(int); i++) { + if (c >0 && mb_tbl_uni_kddi2code3_key[i] == c) { + *s1 = mb_tbl_uni_kddi2code3_value[i]; + match = 1; + break; + } + } + } + } + + if (match && *s1 >0) { + *c1 = *s1/94+0x21; + *c2 = *s1-94*(*c1-0x21)+0x21; + *s1 = (*c1 << 8) | *c2; + *s2 = 1; + } + + return 1; +} + +int +mbfiler_unicode2sjis_emoji_sb(int c, int *s1, int *s2, int *c1, int *c2, mbfl_convert_filter *filter) +{ + int i, match = 0, c1s; + + if (filter->status == 1) { + filter->status = 0; + c1s = filter->cache; + filter->cache = 0; + if (c == 0x20E3) { + if (c1s == 0x0023) { + *s1 = 0x2817; + match = 1; + } else if (c1s == 0x0030) { + *s1 = 0x282c; + match = 1; + } else if (c1s >= 0x0031 && c1s <= 0x0039) { + *s1 = 0x2823 + (c1s - 0x0031); + match = 1; + } + } else if ((c >= 0x1F1A5 + 0x41 && c <= 0x1F1A5 + 0x5A) && + (c1s >= 0x1F1A5 + 0x41 && c1s <= 0x1F1A5 + 0x5A)) { + for (i=0;i<10;i++) { + if (c1s == 0x1F1A5 + nflags_s[i][0] && c == 0x1F1A5 + nflags_s[i][1]) { + *s1 = nflags_code_sb[i]; + match = 1; + break; + } + } + } else { + if (c1s >= ucs_a1_jis_table_min && c1s < ucs_a1_jis_table_max) { + c1s = ucs_a1_jis_table[c1s - ucs_a1_jis_table_min]; + CK((*filter->output_function)(c1s, filter->data)); + } + } + } else { + if (c == 0x0023 || ( c >= 0x0030 && c<=0x0039) || + (c >= 0x1F1A5 + 0x41 && c<= 0x1F1A5 + 0x5A)) { + filter->status = 1; + filter->cache = c; + *s1 = -1; + return 0; + } + + if (c == 0x00A9) { + *s1 = 0x2855; match = 1; + } else if (c == 0x00AE) { + *s1 = 0x2856; match = 1; + } else if (c >= mb_tbl_uni_sb2code2_min && c <= mb_tbl_uni_sb2code2_max) { + for (i=0; i < sizeof(mb_tbl_uni_sb2code2_key)/sizeof(int); i++) { + if (c >0 && mb_tbl_uni_sb2code2_key[i] == c) { + *s1 = mb_tbl_uni_sb2code2_value[i]; + match = 1; + break; + } + } + } else if (c >= mb_tbl_uni_sb2code3_min && c <= mb_tbl_uni_sb2code3_max) { + for (i=0; i < sizeof(mb_tbl_uni_sb2code3_key)/sizeof(int); i++) { + if (c >0 && mb_tbl_uni_sb2code3_key[i] == c) { + *s1 = mb_tbl_uni_sb2code3_value[i]; + match = 1; + break; + } + } + } + } + + if (match && *s1 >0) { + *c1 = *s1/94+0x21; + *c2 = *s1-94*(*c1-0x21)+0x21; + *s1 = (*c1 << 8) | *c2; + *s2 = 1; + } + + return 1; +} + +/* + * SJIS-win => wchar + */ +int +mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) +{ + int c1, s, s1, s2, w; + int snd = 0; + + switch (filter->status) { + case 0: + if (c >= 0 && c < 0x80) { /* latin */ + if ((filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || + filter->from->no_encoding == mbfl_no_encoding_sjis_sb) && c == 0x1b) { + filter->cache = c; + filter->status = 2; + } else { + CK((*filter->output_function)(c, filter->data)); + } + } else if (c > 0xa0 && c < 0xe0) { /* kana */ + CK((*filter->output_function)(0xfec0 + c, filter->data)); + } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ + filter->status = 1; + filter->cache = c; + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + case 1: /* kanji second char */ + filter->status = 0; + c1 = filter->cache; + if (c >= 0x40 && c <= 0xfc && c != 0x7f) { + w = 0; + SJIS_DECODE(c1, c, s1, s2); + s = (s1 - 0x21)*94 + s2 - 0x21; + if (s <= 137) { + if (s == 31) { + w = 0xff3c; /* FULLWIDTH REVERSE SOLIDUS */ + } else if (s == 32) { + w = 0xff5e; /* FULLWIDTH TILDE */ + } else if (s == 33) { + w = 0x2225; /* PARALLEL TO */ + } else if (s == 60) { + w = 0xff0d; /* FULLWIDTH HYPHEN-MINUS */ + } else if (s == 80) { + w = 0xffe0; /* FULLWIDTH CENT SIGN */ + } else if (s == 81) { + w = 0xffe1; /* FULLWIDTH POUND SIGN */ + } else if (s == 137) { + w = 0xffe2; /* FULLWIDTH NOT SIGN */ + } + } + if (w == 0) { + if (s >= cp932ext1_ucs_table_min && s < cp932ext1_ucs_table_max) { /* vendor ext1 (13ku) */ + w = cp932ext1_ucs_table[s - cp932ext1_ucs_table_min]; + } else if (s >= 0 && s < jisx0208_ucs_table_size) { /* X 0208 */ + w = jisx0208_ucs_table[s]; + } else if (s >= cp932ext2_ucs_table_min && s < cp932ext2_ucs_table_max) { /* vendor ext2 (89ku - 92ku) */ + w = cp932ext2_ucs_table[s - cp932ext2_ucs_table_min]; + } else if (s >= cp932ext3_ucs_table_min && s < cp932ext3_ucs_table_max) { /* vendor ext3 (115ku - 119ku) */ + w = cp932ext3_ucs_table[s - cp932ext3_ucs_table_min]; + } else if (s >= (94*94) && s < (114*94)) { /* user (95ku - 114ku) */ + w = s - (94*94) + 0xe000; + } + + if (s >= (94*94) && s < 119*94) { + if (filter->from->no_encoding == mbfl_no_encoding_sjis_docomo) { + w = mbfiler_sjis_emoji_docomo2unicode(s, &snd); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi) { + w = mbfiler_sjis_emoji_kddi2unicode(s, &snd); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { + w = mbfiler_sjis_emoji_sb2unicode(s, &snd); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi_pua) { + mbfiler_sjis_emoji_kddi2unicode_pua(s, &w); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b) { + mbfiler_sjis_emoji_kddi2unicode_pua_b(s, c1, c, &w); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua) { + mbfiler_sjis_emoji2unicode_pua(s, &w); + } + if (w > 0 && snd > 0) { + CK((*filter->output_function)(snd, filter->data)); + } + } + } + if (w <= 0) { + w = (s1 << 8) | s2; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_WINCP932; + } + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + w = (c1 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + case 2: + if ((filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || + filter->from->no_encoding == mbfl_no_encoding_sjis_sb) && + c == 0x24) { + filter->cache = c; + filter->status = 3; + } else { + filter->cache = 0; + filter->status = 0; + CK((*filter->output_function)(0x1b, filter->data)); + } + break; + + case 3: + /* Softbank Emoji: ESC $ [GEFOPQ] X 0x0f */ + if ((filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || + filter->from->no_encoding == mbfl_no_encoding_sjis_sb) && + ((c >= 0x45 && c <= 0x47) || (c >= 0x4f && c <= 0x51))) { + filter->cache = c; + filter->status = 4; + } else { + filter->cache = 0; + filter->status = 0; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + } + break; + + case 4: + /* Softbank Emoji Web code: ESC $ [GEFOPQ] X 0x0f */ + w = 0; + if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || + filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { + c1 = filter->cache; + + if (c == 0x0f) { + w = c; + filter->cache = 0; + filter->status = 0; + } else { + if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua) { + if (c1 == 0x47 && c >= 0x21 && c <= 0x7a) { + w = c - 0x0021 + 0xe001; + } else if (c1 == 0x45 && c >= 0x21 && c <= 0x7a) { + w = c - 0x0021 + 0xe101; + } else if (c1 == 0x46 && c >= 0x21 && c <= 0x7a) { + w = c - 0x0021 + 0xe201; + } else if (c1 == 0x4f && c >= 0x21 && c <= 0x6d) { + w = c - 0x0021 + 0xe301; + } else if (c1 == 0x50 && c >= 0x21 && c <= 0x6c) { + w = c - 0x0021 + 0xe401; + } else if (c1 == 0x51 && c >= 0x21 && c <= 0x5e) { + w = c - 0x0021 + 0xe501; + } + } else { + if (c1 == 0x47 && c >= 0x21 && c <= 0x7a) { + s1 = 0x91; s2 = c; + } else if (c1 == 0x45 && c >= 0x21 && c <= 0x7a) { + s1 = 0x8d; s2 = c; + } else if (c1 == 0x46 && c >= 0x21 && c <= 0x7a) { + s1 = 0x8e; s2 = c; + } else if (c1 == 0x4f && c >= 0x21 && c <= 0x6d) { + s1 = 0x92; s2 = c; + } else if (c1 == 0x50 && c >= 0x21 && c <= 0x6c) { + s1 = 0x95; s2 = c; + } else if (c1 == 0x51 && c >= 0x21 && c <= 0x5e) { + s1 = 0x96; s2 = c; + } + s = (s1 - 0x21)*94 + s2 - 0x21; + w = mbfiler_sjis_emoji_sb2unicode(s, &snd); + if (w > 0 && snd > 0) { + CK((*filter->output_function)(snd, filter->data)); + } + } + if (w > 0) { + CK((*filter->output_function)(w, filter->data)); + } + } + } + + if (w <= 0) { + c1 = filter->cache; + filter->cache = 0; + filter->status = 0; + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + CK((*filter->output_function)(c1 & 0xff, filter->data)); + CK((*filter->output_function)(w, filter->data)); + } + break; + + default: + filter->status = 0; + break; + } + + return c; +} + +/* + * wchar => SJIS-win + */ +int +mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter) +{ + int c1, c2, s1, s2; + int sjis_encoded = 0; + + s1 = 0; + s2 = 0; + if (c >= ucs_a1_jis_table_min && c < ucs_a1_jis_table_max) { + s1 = ucs_a1_jis_table[c - ucs_a1_jis_table_min]; + } else if (c >= ucs_a2_jis_table_min && c < ucs_a2_jis_table_max) { + s1 = ucs_a2_jis_table[c - ucs_a2_jis_table_min]; + } else if (c >= ucs_i_jis_table_min && c < ucs_i_jis_table_max) { + s1 = ucs_i_jis_table[c - ucs_i_jis_table_min]; + } else if (c >= ucs_r_jis_table_min && c < ucs_r_jis_table_max) { + s1 = ucs_r_jis_table[c - ucs_r_jis_table_min]; + } else if (c >= 0xe000 && c < (0xe000 + 20*94)) { /* user (95ku - 114ku) */ + s1 = c - 0xe000; + c1 = s1/94 + 0x7f; + c2 = s1%94 + 0x21; + s1 = (c1 << 8) | c2; + s2 = 1; + } + if (s1 <= 0) { + c1 = c & ~MBFL_WCSPLANE_MASK; + if (c1 == MBFL_WCSPLANE_WINCP932) { + s1 = c & MBFL_WCSPLANE_MASK; + s2 = 1; + } else if (c1 == MBFL_WCSPLANE_JIS0208) { + s1 = c & MBFL_WCSPLANE_MASK; + } else if (c1 == MBFL_WCSPLANE_JIS0212) { + s1 = c & MBFL_WCSPLANE_MASK; + s1 |= 0x8080; + } else if (c == 0xa5) { /* YEN SIGN */ + s1 = 0x216f; /* FULLWIDTH YEN SIGN */ + } else if (c == 0x203e) { /* OVER LINE */ + s1 = 0x2131; /* FULLWIDTH MACRON */ + } else if (c == 0xff3c) { /* FULLWIDTH REVERSE SOLIDUS */ + s1 = 0x2140; + } else if (c == 0xff5e) { /* FULLWIDTH TILDE */ + s1 = 0x2141; + } else if (c == 0x2225) { /* PARALLEL TO */ + s1 = 0x2142; + } else if (c == 0xff0d) { /* FULLWIDTH HYPHEN-MINUS */ + s1 = 0x215d; + } else if (c == 0xffe0) { /* FULLWIDTH CENT SIGN */ + s1 = 0x2171; + } else if (c == 0xffe1) { /* FULLWIDTH POUND SIGN */ + s1 = 0x2172; + } else if (c == 0xffe2) { /* FULLWIDTH NOT SIGN */ + s1 = 0x224c; + } + } + + if ((s1 <= 0) || (s1 >= 0x8080 && s2 == 0)) { /* not found or X 0212 */ + s1 = -1; + c1 = 0; + c2 = cp932ext1_ucs_table_max - cp932ext1_ucs_table_min; + while (c1 < c2) { /* CP932 vendor ext1 (13ku) */ + if (c == cp932ext1_ucs_table[c1]) { + s1 = ((c1/94 + 0x2d) << 8) + (c1%94 + 0x21); + break; + } + c1++; + } + if (s1 <= 0) { + c1 = 0; + c2 = cp932ext2_ucs_table_max - cp932ext2_ucs_table_min; + while (c1 < c2) { /* CP932 vendor ext2 (115ku - 119ku) */ + if (c == cp932ext2_ucs_table[c1]) { + s1 = ((c1/94 + 0x93) << 8) + (c1%94 + 0x21); + break; + } + c1++; + } + } + + if (s1 <= 0) { + c1 = 0; + c2 = cp932ext3_ucs_table_max - cp932ext3_ucs_table_min; + while (c1 < c2) { /* CP932 vendor ext3 (115ku - 119ku) */ + if (c == cp932ext3_ucs_table[c1]) { + s1 = ((c1/94 + 0x93) << 8) + (c1%94 + 0x21); + break; + } + c1++; + } + } + if (c == 0) { + s1 = 0; + } else if (s1 <= 0) { + s1 = -1; + } + } + + if (filter->to->no_encoding == mbfl_no_encoding_sjis_docomo) { + mbfiler_unicode2sjis_emoji_docomo(c, &s1, &s2, &c1, &c2, filter); + } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi) { + mbfiler_unicode2sjis_emoji_kddi(c, &s1, &s2, &c1, &c2, filter); + } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_sb) { + mbfiler_unicode2sjis_emoji_sb(c, &s1, &s2, &c1, &c2, filter); + } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua) { + mbfiler_unicode_pua2sjis_emoji_kddi(c, &s1, &s2, &c1, &c2); + } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_docomo_pua || + filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b || + filter->to->no_encoding == mbfl_no_encoding_sjis_sb_pua) { + mbfiler_unicode_pua2sjis_emoji(c, &s1, &s2, &c1, &c2, &sjis_encoded); + } + + if (filter->status == 1 && filter->cache > 0) { + return c; + } + + if (s1 >= 0) { + if (s1 < 0x100) { /* latin or kana */ + CK((*filter->output_function)(s1, filter->data)); + } else { /* kanji */ + if (sjis_encoded) { + s2 = s1 & 0xff; + s1 = (s1 >> 8) & 0xff; + } else { + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); + } + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + + return c; +} + +static int mbfl_filt_ident_sjis_mobile(int c, mbfl_identify_filter *filter) +{ + if (filter->status) { /* kanji second char */ + if (c < 0x40 || c > 0xfc || c == 0x7f) { /* bad */ + filter->flag = 1; + } + filter->status = 0; + } else if (c >= 0 && c < 0x80) { /* latin ok */ + ; + } else if (c > 0xa0 && c < 0xe0) { /* kana ok */ + ; + } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ + filter->status = 1; + } else { /* bad */ + filter->flag = 1; + } + + return c; +} + + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h new file mode 100644 index 0000000000000..405577ca89686 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -0,0 +1,64 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * the source code included in this files was separated from mbfilter_sjis_open.c + * by Rui Hirokawa on 25 July 2011. + * + */ + +#ifndef MBFL_MBFILTER_SJIS_MOBILE_H +#define MBFL_MBFILTER_SJIS_MOBILE_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_sjis_docomo; +extern const mbfl_encoding mbfl_encoding_sjis_kddi; +extern const mbfl_encoding mbfl_encoding_sjis_sb; +extern const mbfl_encoding mbfl_encoding_sjis_docomo_pua; +extern const mbfl_encoding mbfl_encoding_sjis_kddi_pua; +extern const mbfl_encoding mbfl_encoding_sjis_kddi_pua_b; +extern const mbfl_encoding mbfl_encoding_sjis_sb_pua; + +extern const struct mbfl_identify_vtbl vtbl_identify_sjis_mobile; + +extern const struct mbfl_convert_vtbl vtbl_sjis_docomo_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo; +extern const struct mbfl_convert_vtbl vtbl_sjis_kddi_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi; +extern const struct mbfl_convert_vtbl vtbl_sjis_sb_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb; + +extern const struct mbfl_convert_vtbl vtbl_sjis_docomo_pua_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo_pua; +extern const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua; +extern const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_b_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua_b; +extern const struct mbfl_convert_vtbl vtbl_sjis_sb_pua_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua; + +int mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_SJIS_MOBILE_H */ diff --git a/ext/mbstring/libmbfl/filters/mk_emoji_tbl.pl b/ext/mbstring/libmbfl/filters/mk_emoji_tbl.pl new file mode 100755 index 0000000000000..5b5c3d63ff4f9 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mk_emoji_tbl.pl @@ -0,0 +1,425 @@ +#!/usr/bin/perl +# script to generate Shift_JIS encoded Emoji to/from Unicode conversion table. +# Rui Hirokawa +# +# usage: mktbl.pl EmojiSources.txt +# +# Unicoe;DoCoMo;KDDI;SoftBank + +@docomo = (); +@kddi = (); +@softbank = (); + +@to_docomo = (); +@to_kddi = (); +@to_sb = (); + +$fname = "emoji2uni.h"; +open(OUT,">$fname") or die $!; + +sub sjis2code { + my @c = unpack("C*", pack("H4", $_[0])); + + # Shift_JIS -> JIS + $c[0] = (($c[0]-($c[0]<160?112:176))<<1)-($c[1]<159?1:0); + $c[1] -= ($c[1]<159?($c[1]>127?32:31):126); + + $s = ($c[0] - 0x21)*94 + $c[1]-0x21; + + return $s; +} + +sub show_code { + my @c = @_; + $s = "\t"; + for ($i=0; $i<=$#c; $i++) {# + if ($c[$i]) { + @v = split(' ',$c[$i]); + $s .= "0x$v[0], \t"; + if ($#v > 0) { + print "$i $v[0] $v[1]\n"; + } + } else { + $s .= "0x0000, \t"; + } + if ($i % 4 == 3) { + $s .= "\n\t"; + } + } + return $s; +} + +while(<>) { + if ($_ =~ /^\d+/) { + @v = split(/;/,$_); + if ($v[1] =~ /[\dA-F]+/) { + $code = &sjis2code($v[1]); + $docomo{$code} = $v[0]; + $to_docomo{$v[0]} = $code; + } + if ($v[2] =~ /[\dA-F]+/) { + $code = &sjis2code($v[2]); + $kddi{$code} = $v[0]; + $to_kddi{$v[0]} = $code; + } + if ($v[3] =~ /[\dA-F]+/) { + $code = &sjis2code($v[3]); + $softbank{$code} = $v[0]; + $to_sb{$v[0]} = $code; + } + } +} + +print "DoCoMo\n"; + +$docomo_min = 10434; +$docomo_max = 10434+281; +@docomo_v = (); + +foreach $key (sort {hex($a) <=> hex($b)} keys(%docomo)) { + $s = $key; + $pos = $s % 94; + $ku = ($s - $pos)/94; + $v = $key - $docomo_min; + #print "$ku:$pos - ". $v ."=> $docomo{$key}\n"; + $docomo_v[$key-$docomo_min] = $docomo{$key}; +} + +$to_docomo_min = 10434; + +$to_docomo_min1 = 0x0023; +$to_docomo_max1 = 0x00AE; +$to_docomo_min2 = 0x203C; +$to_docomo_max2 = 0x3299; +$to_docomo_min3 = 0x1F17F; +$to_docomo_max3 = 0x1F6BB; + +@r_docomo1_key = (); +@r_docomo1_val = (); + +@r_docomo2_key = (); +@r_docomo2_val = (); + +@r_docomo3_key = (); +@r_docomo3_val = (); + + +foreach $key (sort {hex($a) <=> hex($b)} keys(%to_docomo)) { + $s = $to_docomo{$key}; + + $pos = $s % 94; + $ku = ($s - $pos)/94; + $v = $to_docomo{$key} - $to_docomo_min; + $h = sprintf("%x",$s); + #print "$ku:$pos = $h ($v) <= $key\n"; + if (hex($key) <= $to_docomo_max1) { + push(@r_docomo1_key, $key); + push(@r_docomo1_val, sprintf("%x", $to_docomo{$key})); + } elsif (hex($key) <= $to_docomo_max2) { + push(@r_docomo2_key, $key); + push(@r_docomo2_val, $h); + } elsif (hex($key) >= $to_docomo_max3) { + push(@r_docomo3_key, $key); + push(@r_docomo3_val, $h); + } +} + +push(@r_docomo1_key, 0x00); +push(@r_docomo1_val, 0x00); +push(@r_docomo2_key, 0x00); +push(@r_docomo2_val, 0x00); +push(@r_docomo3_key, 0x00); +push(@r_docomo3_val, 0x00); + +print OUT "int mb_tbl_code2uni_docomo_min = $docomo_min;\n"; +print OUT "int mb_tbl_code2uni_docomo_max = $docomo_max;\n\n"; + +print OUT "int mb_tbl_code2uni_docomo[] = {\n"; +print OUT &show_code(@docomo_v); +print OUT "};\n\n"; + +print OUT "int mb_tbl_uni_docomo2code_min1 = $to_docomo_min1;\n"; +print OUT "int mb_tbl_uni_docomo2code_max1 = $to_docomo_max1;\n"; +print OUT "int mb_tbl_uni_docomo2code_min2 = $to_docomo_min2;\n"; +print OUT "int mb_tbl_uni_docomo2code_max2 = $to_docomo_max2;\n"; +print OUT "int mb_tbl_uni_docomo2code_min3 = $to_docomo_min3;\n"; +print OUT "int mb_tbl_uni_docomo2code_max3 = $to_docomo_max3;\n\n"; + +#print "DOCOMO reverse 1\n"; + +print OUT "int mb_tbl_uni_docomo2code_key1[] = {\n"; +print OUT &show_code(@r_docomo1_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_docomo2code_val1[] = {\n"; +print OUT &show_code(@r_docomo1_val),"\n"; +print OUT "};\n\n"; + +#print "DOCOMO reverse 2\n"; + +print OUT "int mb_tbl_uni_docomo2code_key2[] = {\n"; +print OUT &show_code(@r_docomo2_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_docomo2code_val2[] = {\n"; +print OUT &show_code(@r_docomo2_val),"\n"; +print OUT "};\n\n"; + +print "DOCOMO reverse 3\n"; + +print OUT "int mb_tbl_uni_docomo2code_key3[] = {\n"; +print OUT &show_code(@r_docomo3_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_docomo2code_val3[] = {\n"; +print OUT &show_code(@r_docomo3_val),"\n"; +print OUT "};\n\n"; + +#print "DOCOMO reverse end \n"; + +$kddi_min1 = 9400; +$kddi_max1 = 9400+264; +$kddi_min2 = 9400+564; +$kddi_max2 = 9400+939; + +@kddi_v1 = (); +@kddi_v2 = (); + +#print "KDDI\n"; + +foreach $key (sort {hex($a) <=> hex($b)} keys(%kddi)) { + $s = $key; + $pos = $s % 94; + $ku = ($s - $pos)/94; + $v = $key - $kddi_min1; + $h = sprintf("%x",$key); + #print "$ku:$pos :: $v ($h) => $kddi{$key}\n"; + + if ($key <= $kddi_max1) { + $kddi_v1[$key-$kddi_min1] = $kddi{$key}; + } elsif ($key <= $kddi_max2) { + $kddi_v2[$key-$kddi_min2] = $kddi{$key}; + } +} + +$to_kddi_min = 9660; +$to_kddi_min1 = 0x0030; +$to_kddi_max1 = 0x00AE; +$to_kddi_min2 = 0x2002; +$to_kddi_max2 = 0x3299; +$to_kddi_min3 = 0x1F004; +$to_kddi_max3 = 0x1F6C0; + +@r_kddi1_key = (); @r_kddi1_val = (); +@r_kddi2_key = (); @r_kddi2_val = (); +@r_kddi3_key = (); @r_kddi3_val = (); + +foreach $key (sort {hex($a) <=> hex($b)} keys(%to_kddi)) { + $s = $to_kddi{$key}; + + $pos = $s % 94; + $ku = ($s - $pos)/94; + $v = $to_kddi{$key} - $to_kddi_min; + $h = sprintf("%x",$s); + #print "$ku:$pos = $h ($v) <= $key\n"; + if (hex($key) <= $to_kddi_max1) { + push(@r_kddi1_key, $key); + push(@r_kddi1_val, $h); + } elsif (hex($key) <= $to_kddi_max2) { + push(@r_kddi2_key, $key); + push(@r_kddi2_val, $h); + } else { + push(@r_kddi3_key, $key); + push(@r_kddi3_val, $h); + } +} + +push(@r_kddi1_key, 0x00); +push(@r_kddi1_val, 0x00); +push(@r_kddi2_key, 0x00); +push(@r_kddi2_val, 0x00); +push(@r_kddi3_key, 0x00); +push(@r_kddi3_val, 0x00); + +print OUT "int mb_tbl_code2uni_kddi1_min = $kddi_min1;\n"; +print OUT "int mb_tbl_code2uni_kddi1_max = $kddi_max1;\n"; +print OUT "int mb_tbl_code2uni_kddi2_min = $kddi_min2;\n"; +print OUT "int mb_tbl_code2uni_kddi2_max = $kddi_max2;\n\n"; + +#print "KDDI 1\n"; + +print OUT "int mb_tbl_code2uni_kddi1[] = {\n"; +print OUT &show_code(@kddi_v1); +print OUT "};\n\n"; + +#print "KDDI 2\n"; + +print OUT "int mb_tbl_code2uni_kddi2[] = {\n"; +print OUT &show_code(@kddi_v2); +print OUT "};\n\n"; + +print OUT "int mb_tbl_uni_kddi2code_min1 = $to_kddi_min1;\n"; +print OUT "int mb_tbl_uni_kddi2code_max1 = $to_kddi_max1;\n"; +print OUT "int mb_tbl_uni_kddi2code_min2 = $to_kddi_min2;\n"; +print OUT "int mb_tbl_uni_kddi2code_max2 = $to_kddi_max2;\n"; +print OUT "int mb_tbl_uni_kddi2code_min3 = $to_kddi_min3;\n"; +print OUT "int mb_tbl_uni_kddi2code_max3 = $to_kddi_max3;\n\n"; + +#print "KDDI reverse 1\n"; + +print OUT "int mb_tbl_uni_kddi2code_key1[] = {\n"; +print OUT &show_code(@r_kddi1_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_kddi2code_val1[] = {\n"; +print OUT &show_code(@r_kddi1_val),"\n"; +print OUT "};\n\n"; + +#print "KDDI reverse 1\n"; + +print OUT "int mb_tbl_uni_kddi2code_key2[] = {\n"; +print OUT &show_code(@r_kddi2_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_kddi2code_val2[] = {\n"; +print OUT &show_code(@r_kddi2_val),"\n"; +print OUT "};\n\n"; + +#print "KDDI reverse 3\n"; + +print OUT "int mb_tbl_uni_kddi2code_key3[] = {\n"; +print OUT &show_code(@r_kddi3_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_kddi2code_val3[] = {\n"; +print OUT &show_code(@r_kddi3_val),"\n"; +print OUT "};\n\n"; + + +$sb_min1 = 10153; +$sb_max1 = 10153+177; +$sb_min2 = 10153+376; +$sb_max2 = 10153+547; +$sb_min3 = 10153+752; +$sb_max3 = 10153+901; + +@sb_v1 = (); +@sb_v2 = (); +@sb_v3 = (); + +if (1) { + print "SoftBank\n"; + + foreach $key (sort {hex($a) <=> hex($b)} keys(%softbank)) { + $s = $key; + $pos = $s % 94; + $ku = ($s - $pos)/94; + $v = $key - $sb_min1; + $h = sprintf("%x",$key); + #print "$ku:$pos :: $v ($h) => $softbank{$key}\n"; + if ($key <= $sb_max1) { + $sb_v1[$key-$sb_min1] = $softbank{$key}; + } elsif ($key <= $sb_max2) { + $sb_v2[$key-$sb_min2] = $softbank{$key}; + } elsif ($key <= $sb_max3) { + $sb_v3[$key-$sb_min3] = $softbank{$key}; + } + } + +} + +$to_sb_min = 10263; +$to_sb_min1 = 0x0023; +$to_sb_max1 = 0x00AE; +$to_sb_min2 = 0x2122; +$to_sb_max2 = 0x3299; +$to_sb_min3 = 0x1F004; +$to_sb_max3 = 0x1F6C0; + +@r_sb1_key = (); @r_sb1_val = (); +@r_sb2_key = (); @r_sb2_val = (); +@r_sb3_key = (); @r_sb3_val = (); + +foreach $key (sort {hex($a) <=> hex($b)} keys(%to_sb)) { + $s = $to_sb{$key}; + + $pos = $s % 94; + $ku = ($s - $pos)/94; + $v = $to_sb{$key} - $to_sb_min; + $h = sprintf("%x",$s); + #print "$ku:$pos = $h ($v) <= $key\n"; + if (hex($key) <= $to_sb_max1) { + push(@r_sb1_key, $key); + push(@r_sb1_val, $h); + } elsif (hex($key) >= $to_sb_min2 && hex($key) <= $to_sb_max2) { + push(@r_sb2_key, $key); + push(@r_sb2_val, $h); + } else { + push(@r_sb3_key, $key); + push(@r_sb3_val, $h); + } +} + +push(@r_sb1_key, 0x00); +push(@r_sb1_val, 0x00); +push(@r_sb2_key, 0x00); +push(@r_sb2_val, 0x00); +push(@r_sb3_key, 0x00); +push(@r_sb3_val, 0x00); + + +print OUT "int mb_tbl_code2uni_sb1_min = $sb_min1;\n"; +print OUT "int mb_tbl_code2uni_sb1_max = $sb_max1;\n"; +print OUT "int mb_tbl_code2uni_sb2_min = $sb_min2;\n"; +print OUT "int mb_tbl_code2uni_sb2_max = $sb_max2;\n"; +print OUT "int mb_tbl_code2uni_sb3_min = $sb_min3;\n"; +print OUT "int mb_tbl_code2uni_sb3_max = $sb_max3;\n\n"; + +#print "SoftBank 1\n"; + +print OUT "int mb_tbl_code2uni_sb1[] = {\n"; +print OUT &show_code(@sb_v1); +print OUT "};\n\n"; + +#print "SoftBank 2\n"; + +print OUT "int mb_tbl_code2uni_sb2[] = {\n"; +print OUT &show_code(@sb_v2); +print OUT "};\n\n"; + +#print "SoftBank 3\n"; + +print OUT "int mb_tbl_code2uni_sb3[] = {\n"; +print OUT &show_code(@sb_v3); +print OUT "};\n\n"; + +print OUT "int mb_tbl_uni_sb2code_min1 = $to_sb_min1;\n"; +print OUT "int mb_tbl_uni_sb2code_max1 = $to_sb_max1;\n"; +print OUT "int mb_tbl_uni_sb2code_min2 = $to_sb_min2;\n"; +print OUT "int mb_tbl_uni_sb2code_max2 = $to_sb_max2;\n"; +print OUT "int mb_tbl_uni_sb2code_min3 = $to_sb_min3;\n"; +print OUT "int mb_tbl_uni_sb2code_max3 = $to_sb_max3;\n\n"; + +#print "SB reverse 1\n"; + +print OUT "int mb_tbl_uni_sb2code_key1[] = {\n"; +print OUT &show_code(@r_sb1_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_sb2code_val1[] = {\n"; +print OUT &show_code(@r_sb1_val),"\n"; +print OUT "};\n\n"; + +#print "SB reverse 2\n"; + +print OUT "int mb_tbl_uni_sb2code_key2[] = {\n"; +print OUT &show_code(@r_sb2_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_sb2code_val2[] = {\n"; +print OUT &show_code(@r_sb2_val),"\n"; +print OUT "};\n\n"; + +#print "SB reverse 3\n"; + +print OUT "int mb_tbl_uni_sb2code_key3[] = {\n"; +print OUT &show_code(@r_sb3_key),"\n"; +print OUT "};\n\n"; +print OUT "int mb_tbl_uni_sb2code_val3[] = {\n"; +print OUT &show_code(@r_sb3_val),"\n"; +print OUT "};\n\n"; + + +close(OUT); diff --git a/ext/mbstring/libmbfl/filters/sjis_mac2uni.h b/ext/mbstring/libmbfl/filters/sjis_mac2uni.h new file mode 100644 index 0000000000000..cbfdf311dad2a --- /dev/null +++ b/ext/mbstring/libmbfl/filters/sjis_mac2uni.h @@ -0,0 +1,214 @@ +const int sjis_mac2wchar1[] = { // 0x03ac - 0x03c9 +0x0339c, 0x0339f, 0x0339d, 0x033a0, +0x033a4, 0x4ff4d, 0x033a1, 0x033a5, +0x0339e, 0x033a2, 0x0338e, 0x4ff47, +0x0338f, 0x033c4, 0x03396, 0x03397, +0x02113, 0x03398, 0x033b3, 0x033b2, +0x033b1, 0x033b0, 0x02109, 0x033d4, +0x033cb, 0x03390, 0x03385, 0x03386, +0x03387, 0xff860, }; +const int sjis_mac2wchar2[] = { // 0x0406 - 0x0420 +0x02116, 0x033cd, +0x02121, 0xff861, 0x02664, 0x02667, +0x02661, 0x02662, 0x02660, 0x02663, +0x02665, 0x02666, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x03020, 0x0260e, +0x03004, }; +const int sjis_mac2wchar3[] = { // 0x0432 - 0x0441 +0x0261e, 0x0261c, +0x0261d, 0x0261f, 0x021c6, 0x021c4, +0x021c5, 0xff860, 0x021e8, 0x021e6, +0x021e7, 0x021e9, 0x121e8, 0x121e6, +0x121e7, 0x121e9, }; +const int sjis_mac2wchar4[] = { // 0x0468 - 0x0480 +0x03230, 0x0322a, 0x0322b, 0x0322c, +0x0322d, 0x0322e, 0x0322f, 0x03240, +0x03237, 0x03242, 0x03243, 0x03239, +0x0323a, 0x03231, 0x0323e, 0x03234, +0x03232, 0x0323b, 0x03236, 0x03233, +0x03235, 0x0323c, 0x0323d, 0x0323f, +0x03238, }; +const int sjis_mac2wchar5[] = { // 0x04b8 - 0x04e8 +0x85927, 0x85c0f, 0x032a4, 0x032a5, +0x032a6, 0x032a7, 0x032a8, 0x032a9, +0x03296, 0x0329d, 0x03298, 0x0329e, +0x863a7, 0x03299, 0x03349, 0x03322, +0x0334d, 0x03314, 0x03316, 0x03305, +0x03333, 0x0334e, 0x03303, 0x03336, +0x03318, 0x03315, 0x03327, 0x03351, +0x0334a, 0x03339, 0x03357, 0x0330d, +0x03342, 0x03323, 0x03326, 0x0333b, +0x0332b, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x03300, 0x0331e, 0x0332a, 0x03331, +0x03347, }; +const int sjis_mac2wchar6[] = { // 0x050c - 0x0551 +0x0337e, 0x0337d, 0x0337c, 0x0337b, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x0337f, 0xff862, 0xff862, +0x0222e, 0x0221f, 0x022bf, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x0301d, 0x0301f, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x03094, 0x00000, 0x030f7, 0x030f8, +0x030f9, 0x030fa, }; +const int sjis_mac2wchar7[] = { // 0x1ed9 - 0x1f18 +0x23001, 0x23002, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x2ffe3, 0x0fe33, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x230fc, +0x0fe31, 0x22010, 0x00000, 0x00000, +0x2301c, 0x22016, 0x2ff5c, 0x22026, +0x0fe30, 0x00000, 0x00000, 0x00000, +0x00000, 0x0fe35, 0x0fe36, 0x0fe39, +0x0fe3a, 0x2ff3b, 0x2ff3d, 0x0fe37, +0x0fe38, 0x0fe3f, 0x0fe40, 0x0fe3d, +0x0fe3e, 0x0fe41, 0x0fe42, 0x0fe43, +0x0fe44, 0x0fe3b, 0x0fe3c, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x2ff1d, }; +const int sjis_mac2wchar8[] = { // 0x1ff2 - 0x20a5 +0x23041, 0x00000, +0x23043, 0x00000, 0x23045, 0x00000, +0x23047, 0x00000, 0x23049, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x23063, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x23083, 0x00000, 0x23085, 0x00000, +0x23087, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x2308e, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x230a1, 0x00000, 0x230a3, 0x00000, +0x230a5, 0x00000, 0x230a7, 0x00000, +0x230a9, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x230c3, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x00000, 0x230e3, 0x00000, +0x230e5, 0x00000, 0x230e7, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x00000, 0x230ee, 0x00000, 0x00000, +0x00000, 0x00000, 0x00000, 0x00000, +0x230f5, 0x230f6, }; + +const int wchar2sjis_mac4[] = { // 0x2660 - 0x2667 +0x040e, 0x040c, 0x040d, 0x040f, +0x040a, 0x0410, 0x0411, 0x040b, +}; + +const int wchar2sjis_mac7[] = { // 0x322a - 0x3243 +0x0469, 0x046a, +0x046b, 0x046c, 0x046d, 0x046e, +0x0468, 0x0475, 0x0478, 0x047b, +0x0477, 0x047c, 0x047a, 0x0470, +0x0480, 0x0473, 0x0474, 0x0479, +0x047d, 0x047e, 0x0476, 0x047f, +0x046f, 0x0000, 0x0471, 0x0472, +}; + +const int wchar2sjis_mac8[] = { // 0x3296 - 0x329e +0x04c0, 0x0000, +0x04c2, 0x04c5, 0x0000, 0x0000, +0x0000, 0x04c1, 0x04c3, }; + +const int wchar2sjis_mac9[] = { // 0x3300 - 0x33d4 +0x04e4, 0x0000, 0x0000, 0x04ce, +0x0000, 0x04cb, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x04d7, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x04c9, 0x04d1, 0x04ca, 0x0000, +0x04d0, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x04e5, 0x0000, +0x0000, 0x0000, 0x04c7, 0x04d9, +0x0000, 0x0000, 0x04da, 0x04d2, +0x0000, 0x0000, 0x04e6, 0x04dc, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x04e7, 0x0000, 0x04cc, +0x0000, 0x0000, 0x04cf, 0x0000, +0x0000, 0x04d5, 0x0000, 0x04db, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x04d8, 0x0000, +0x0000, 0x0000, 0x0000, 0x04e8, +0x0000, 0x04c6, 0x04d4, 0x0000, +0x0000, 0x04c8, 0x04cd, 0x0000, +0x0000, 0x04d3, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x04d6, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x050f, +0x050e, 0x050d, 0x050c, 0x0521, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x03c6, 0x03c7, 0x03c8, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x03b6, 0x03b8, +0x03c5, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x03ba, 0x03bb, +0x03bd, 0x0000, 0x0000, 0x0000, +0x03ac, 0x03ae, 0x03b4, 0x03ad, +0x03af, 0x03b2, 0x03b5, 0x0000, +0x03b0, 0x03b3, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x03c1, 0x03c0, 0x03bf, 0x03be, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x03b9, 0x0000, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x03c4, +0x0000, 0x0407, 0x0000, 0x0000, +0x0000, 0x0000, 0x0000, 0x0000, +0x03c3, }; + +const int wchar2sjis_mac10[] = { // 0xfe30 - 0xfe44 +0x1efc, 0x1ef4, 0x0000, 0x1ee9, +0x0000, 0x1f01, 0x1f02, 0x1f07, +0x1f08, 0x1f03, 0x1f04, 0x1f11, +0x1f12, 0x1f0b, 0x1f0c, 0x1f09, +0x1f0a, 0x1f0d, 0x1f0e, 0x1f0f, +0x1f10, }; diff --git a/ext/mbstring/libmbfl/mbfl/eaw_table.h b/ext/mbstring/libmbfl/mbfl/eaw_table.h index a4f1e4fdf18c7..af310ea1d8e1e 100644 --- a/ext/mbstring/libmbfl/mbfl/eaw_table.h +++ b/ext/mbstring/libmbfl/mbfl/eaw_table.h @@ -2,8 +2,9 @@ static const struct { int begin; int end; } mbfl_eaw_table[] = { - { 0x1100, 0x1159 }, - { 0x115f, 0x115f }, + { 0x1100, 0x115f }, + { 0x11a3, 0x11a7 }, + { 0x11fa, 0x11ff }, { 0x2329, 0x232a }, { 0x2e80, 0x2e99 }, { 0x2e9b, 0x2ef3 }, @@ -12,25 +13,32 @@ static const struct { { 0x3000, 0x303e }, { 0x3041, 0x3096 }, { 0x3099, 0x30ff }, - { 0x3105, 0x312c }, + { 0x3105, 0x312d }, { 0x3131, 0x318e }, - { 0x3190, 0x31b7 }, + { 0x3190, 0x31ba }, + { 0x31c0, 0x31e3 }, { 0x31f0, 0x321e }, - { 0x3220, 0x3243 }, - { 0x3250, 0x327d }, - { 0x327f, 0x32fe }, - { 0x3300, 0x4db5 }, - { 0x4e00, 0x9fa5 }, - { 0xa000, 0xa48c }, + { 0x3220, 0x3247 }, + { 0x3250, 0x32fe }, + { 0x3300, 0x4dbf }, + { 0x4e00, 0xa48c }, { 0xa490, 0xa4c6 }, + { 0xa960, 0xa97c }, { 0xac00, 0xd7a3 }, - { 0xf900, 0xfa2d }, - { 0xfa30, 0xfa6a }, + { 0xd7b0, 0xd7c6 }, + { 0xd7cb, 0xd7fb }, + { 0xf900, 0xfaff }, + { 0xfe10, 0xfe19 }, { 0xfe30, 0xfe52 }, { 0xfe54, 0xfe66 }, { 0xfe68, 0xfe6b }, { 0xff01, 0xff60 }, { 0xffe0, 0xffe6 }, + { 0x1b000, 0x1b001 }, + { 0x1f200, 0x1f202 }, + { 0x1f210, 0x1f23a }, + { 0x1f240, 0x1f248 }, + { 0x1f250, 0x1f251 }, { 0x20000, 0x2fffd }, { 0x30000, 0x3fffd } }; diff --git a/ext/mbstring/libmbfl/mbfl/mbfilter.h b/ext/mbstring/libmbfl/mbfl/mbfilter.h index 8e073c94d2cef..4db78d01f53de 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfilter.h +++ b/ext/mbstring/libmbfl/mbfl/mbfilter.h @@ -102,7 +102,7 @@ * version information */ #define MBFL_VERSION_MAJOR 1 -#define MBFL_VERSION_MINOR 1 +#define MBFL_VERSION_MINOR 3 #define MBFL_VERSION_TEENY 0 /* diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index d81b533dd1295..776ff986eb0bc 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -52,6 +52,8 @@ #include "filters/mbfilter_iso2022_kr.h" #include "filters/mbfilter_sjis.h" #include "filters/mbfilter_sjis_open.h" +#include "filters/mbfilter_sjis_mobile.h" +#include "filters/mbfilter_sjis_mac.h" #include "filters/mbfilter_cp51932.h" #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" @@ -125,6 +127,22 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_eucjpwin, &vtbl_cp932_wchar, &vtbl_wchar_cp932, + &vtbl_sjis_docomo_wchar, + &vtbl_wchar_sjis_docomo, + &vtbl_sjis_kddi_wchar, + &vtbl_wchar_sjis_kddi, + &vtbl_sjis_sb_wchar, + &vtbl_wchar_sjis_sb, + &vtbl_sjis_docomo_pua_wchar, + &vtbl_wchar_sjis_docomo_pua, + &vtbl_sjis_kddi_pua_wchar, + &vtbl_wchar_sjis_kddi_pua, + &vtbl_sjis_kddi_pua_b_wchar, + &vtbl_wchar_sjis_kddi_pua_b, + &vtbl_sjis_sb_pua_wchar, + &vtbl_wchar_sjis_sb_pua, + &vtbl_sjis_mac_wchar, + &vtbl_wchar_sjis_mac, &vtbl_euccn_wchar, &vtbl_wchar_euccn, &vtbl_cp936_wchar, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index 17955b2c9a4a2..c91ffa062224a 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -58,6 +58,8 @@ #include "filters/mbfilter_iso2022_kr.h" #include "filters/mbfilter_sjis.h" #include "filters/mbfilter_sjis_open.h" +#include "filters/mbfilter_sjis_mobile.h" +#include "filters/mbfilter_sjis_mac.h" #include "filters/mbfilter_cp51932.h" #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" @@ -156,6 +158,14 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_sjis, &mbfl_encoding_eucjp_win, &mbfl_encoding_sjis_open, + &mbfl_encoding_sjis_docomo, + &mbfl_encoding_sjis_kddi, + &mbfl_encoding_sjis_sb, + &mbfl_encoding_sjis_docomo_pua, + &mbfl_encoding_sjis_kddi_pua, + &mbfl_encoding_sjis_kddi_pua_b, + &mbfl_encoding_sjis_sb_pua, + &mbfl_encoding_sjis_mac, &mbfl_encoding_cp932, &mbfl_encoding_cp51932, &mbfl_encoding_jis, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index fd3a66df6e318..9c152ef7afd58 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -69,6 +69,14 @@ enum mbfl_no_encoding { mbfl_no_encoding_sjis, mbfl_no_encoding_eucjp_win, mbfl_no_encoding_sjis_open, + mbfl_no_encoding_sjis_docomo, + mbfl_no_encoding_sjis_kddi, + mbfl_no_encoding_sjis_sb, + mbfl_no_encoding_sjis_docomo_pua, + mbfl_no_encoding_sjis_kddi_pua, + mbfl_no_encoding_sjis_kddi_pua_b, + mbfl_no_encoding_sjis_sb_pua, + mbfl_no_encoding_sjis_mac, mbfl_no_encoding_cp932, mbfl_no_encoding_cp51932, mbfl_no_encoding_jis, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c index 0d61169af3a53..21dd89806053e 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c @@ -51,6 +51,7 @@ #include "filters/mbfilter_iso2022_kr.h" #include "filters/mbfilter_sjis.h" #include "filters/mbfilter_sjis_open.h" +#include "filters/mbfilter_sjis_mobile.h" #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_euc_jp.h" diff --git a/ext/mbstring/libmbfl/mbfl/mk_eaw_tbl.awk b/ext/mbstring/libmbfl/mbfl/mk_eaw_tbl.awk index c7deb4cdf5af4..02c73f2025923 100644 --- a/ext/mbstring/libmbfl/mbfl/mk_eaw_tbl.awk +++ b/ext/mbstring/libmbfl/mbfl/mk_eaw_tbl.awk @@ -18,7 +18,8 @@ BEGIN { /^[0-9a-fA-F]+;/ { if ($2 == "W" || $2 == "F") { - v = ( "0x" $1 ) + 0 + + v = strtonum( "0x" $1 ) if (prev < 0) { first = v } else if (v - prev > 1) { @@ -44,8 +45,8 @@ BEGIN { /^[0-9a-fA-F]+\.\./ { if ($4 == "W" || $4 == "F") { - vs = ( "0x" $1 ) + 0 - ve = ( "0x" $3 ) + 0 + vs = strtonum( "0x" $1 ) + ve = strtonum( "0x" $3 ) if (prev < 0) { first = vs } else if (vs - prev > 1) { diff --git a/ext/mbstring/libmbfl/tests/emoji.c b/ext/mbstring/libmbfl/tests/emoji.c new file mode 100644 index 0000000000000..4f6a346576108 --- /dev/null +++ b/ext/mbstring/libmbfl/tests/emoji.c @@ -0,0 +1,119 @@ +/** + * this is a small sample script to use libmbfl. + * Rui Hirokawa + * + * this file is encoded in EUC-JP. + */ + +#include +#include +#include +#include "mbfl/mbfilter.h" + +static void hexdump(const mbfl_string *ptr) +{ + unsigned int i; + + for (i = 0; i < ptr->len; i++) { + printf("%%%02x", ptr->val[i]); + } + + printf(" (%u)\n", ptr->len); +} + +//#define TEST_DOCOMO +//#define TEST_KDDI +#define TEST_SOFTBANK + +int main(int argc, char **argv) +{ + enum mbfl_no_encoding from_encoding, to_encoding; + enum mbfl_no_language no_language; + mbfl_buffer_converter *convd = NULL, *convd2 = NULL; + mbfl_memory_device dev, dev2; + mbfl_string string, result, *ret; +#ifdef TEST_DOCOMO + //char str[] = {0xF9,0xD7,0x00}; // U+2122 + //char str[] = {0xF9,0x82,0x00}; // U+1F195 + char str[] = {0xF9,0xD6,0x00}; // U+00A9 +#endif +#ifdef TEST_KDDI + //char str[] = {0xF7,0x6A,0x00};// U+2122 + //char str[] = {0xF7,0xE5,0x00}; // U+1F195 + //char str[] = {0xF3,0xD2,0x00}; // U+1F1E8 U+1F1F3 + char str[] = {0xF7,0x74,0x00}; // U+00A9 +#endif +#ifdef TEST_SOFTBANK + //char str[] = {0xFB,0xD7,0x00};// U+2122 + //char str[] = {0xF7,0xB2,0x00}; // U+1F195 + //char str[] = {0xFB,0xB3,0x00}; // U+1F1E8 U+1F1F3 + char str[] = {0xF7,0xEE,0x00}; // U+00A9 +#endif + int final = 0; + int state = 0; + int i; + + no_language = mbfl_name2no_language("Japanese"); +#ifdef TEST_DOCOMO + from_encoding = mbfl_name2no_encoding("SJIS-win#DOCOMO"); +#endif +#ifdef TEST_KDDI + from_encoding = mbfl_name2no_encoding("SJIS-win#KDDI"); +#endif +#ifdef TEST_SOFTBANK + from_encoding = mbfl_name2no_encoding("SJIS-win#SOFTBANK"); +#endif + to_encoding = mbfl_name2no_encoding("UTF-8"); + + convd = mbfl_buffer_converter_new(from_encoding, to_encoding, 0); + + mbfl_memory_device_init(&dev, 0, 4096); + mbfl_string_init_set(&string, no_language, from_encoding); + mbfl_memory_device_realloc(&dev, dev.length + dev.allocsz, dev.allocsz); + + strcpy(dev.buffer, str); + dev.pos += strlen(str); + + mbfl_memory_device_result(&dev, &string); + mbfl_string_init_set(&result, no_language, to_encoding); + ret = mbfl_buffer_converter_feed_result(convd, &string, &result); + +#if 0 + for (i = 0; i < result.len; i+= 2) { + if (result.val[i] >= 0xD8 && result.val[i] < 0xE0) { // Surrogate pair + int h = (result.val[i] & 0x07)<<8 | result.val[i+1]; + int l = (result.val[i+2] & 0x03)<<8 | result.val[i+3]; + int c = (h<<(2+8)) | l; + printf("U+%x\n",c+0x10000); + i+=2; + } else { + printf("U+%x\n",(result.val[i] << 8) | result.val[i+1]); + } + } + hexdump(&result); +#endif + + +#if 1 + convd2 = mbfl_buffer_converter_new(to_encoding, from_encoding, 0); + mbfl_memory_device_init(&dev2, 0, 4096); + mbfl_string_init_set(&string, no_language, to_encoding); + mbfl_memory_device_realloc(&dev2, dev2.length + dev2.allocsz, dev2.allocsz); + + memcpy(dev2.buffer, result.val, result.len+1); + dev2.pos += strlen(dev2.buffer); + + mbfl_memory_device_result(&dev2, &string); + mbfl_string_init_set(&result, no_language, from_encoding); + ret = mbfl_buffer_converter_feed_result(convd2, &string, &result); + hexdump(&result); + mbfl_buffer_converter_delete(convd2); +#endif + mbfl_string_clear(&result); + mbfl_string_clear(&string); + + mbfl_buffer_converter_delete(convd); + + + return EXIT_SUCCESS; +} From 52948b534cf34cc337ab55f3dc67feef8fed0a86 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Tue, 2 Aug 2011 02:50:11 +0000 Subject: [PATCH 0441/2394] added new files of libmbfl 1.3.0. --- ext/mbstring/config.m4 | 2 ++ ext/mbstring/config.w32 | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/mbstring/config.m4 b/ext/mbstring/config.m4 index a28af46629d20..f8763c6da3539 100644 --- a/ext/mbstring/config.m4 +++ b/ext/mbstring/config.m4 @@ -264,6 +264,8 @@ AC_DEFUN([PHP_MBSTRING_SETUP_LIBMBFL], [ libmbfl/filters/mbfilter_qprint.c libmbfl/filters/mbfilter_sjis.c libmbfl/filters/mbfilter_sjis_open.c + libmbfl/filters/mbfilter_sjis_mobile.c + libmbfl/filters/mbfilter_sjis_mac.c libmbfl/filters/mbfilter_tl_jisx0201_jisx0208.c libmbfl/filters/mbfilter_ucs2.c libmbfl/filters/mbfilter_ucs4.c diff --git a/ext/mbstring/config.w32 b/ext/mbstring/config.w32 index ae0972f62a40c..3dc792de77a2b 100644 --- a/ext/mbstring/config.w32 +++ b/ext/mbstring/config.w32 @@ -35,7 +35,7 @@ if (PHP_MBSTRING != "no") { mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c \ mbfilter_koi8u.c mbfilter_cp1254.c \ mbfilter_uuencode.c mbfilter_armscii8.c mbfilter_cp850.c \ - mbfilter_cp5022x.c mbfilter_sjis_open.c \ + mbfilter_cp5022x.c mbfilter_sjis_open.c mbfilter_sjis_mobile.c mbfilter_sjis_mac.c \ mbfilter_tl_jisx0201_jisx0208.c", "mbstring"); ADD_SOURCES("ext/mbstring/libmbfl/mbfl", "mbfilter.c mbfilter_8bit.c \ From 5771c1fb8682168c0dc55094bad999b01ef0a2b9 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Tue, 2 Aug 2011 03:18:53 +0000 Subject: [PATCH 0442/2394] added version number of libmbfl. --- ext/mbstring/mbstring.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 1600f97252965..2b9da43f042eb 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -1682,6 +1682,11 @@ PHP_MINFO_FUNCTION(mbstring) php_info_print_table_row(2, "Multibyte Support", "enabled"); php_info_print_table_row(2, "Multibyte string engine", "libmbfl"); php_info_print_table_row(2, "HTTP input encoding translation", MBSTRG(encoding_translation) ? "enabled": "disabled"); + { + char tmp[256]; + snprintf(tmp, sizeof(tmp), "%d.%d.%d", MBFL_VERSION_MAJOR, MBFL_VERSION_MINOR, MBFL_VERSION_TEENY); + php_info_print_table_row(2, "libmbfl version", tmp); + } php_info_print_table_end(); php_info_print_table_start(); From 6803a389284d8ae29d3d8e00d3e62ba8106362f1 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 2 Aug 2011 07:38:23 +0000 Subject: [PATCH 0443/2394] Fixed bug #55339 (Segfault with allow_call_time_pass_reference = Off) --- Zend/zend.c | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/Zend/zend.c b/Zend/zend.c index 1ad2baf06623a..f2e433353f60d 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -975,6 +975,23 @@ ZEND_API int zend_get_configuration_directive(const char *name, uint name_length } /* }}} */ +#define SAVE_STACK(stack) do { \ + if (CG(stack).top) { \ + memcpy(&stack, &CG(stack), sizeof(zend_stack)); \ + CG(stack).top = CG(stack).max = 0; \ + CG(stack).elements = NULL; \ + } else { \ + stack.top = 0; \ + } \ + } while (0) + +#define RESTORE_STACK(stack) do { \ + if (stack.top) { \ + zend_stack_destroy(&CG(stack)); \ + memcpy(&CG(stack), &stack, sizeof(zend_stack)); \ + } \ + } while (0) + ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */ { va_list args; @@ -987,6 +1004,14 @@ ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */ zval *orig_user_error_handler; zend_bool in_compilation; zend_class_entry *saved_class_entry; + zend_stack bp_stack; + zend_stack function_call_stack; + zend_stack switch_cond_stack; + zend_stack foreach_copy_stack; + zend_stack object_stack; + zend_stack declare_stack; + zend_stack list_stack; + zend_stack context_stack; TSRMLS_FETCH(); /* Obtain relevant filename and lineno */ @@ -1123,6 +1148,14 @@ ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */ if (in_compilation) { saved_class_entry = CG(active_class_entry); CG(active_class_entry) = NULL; + SAVE_STACK(bp_stack); + SAVE_STACK(function_call_stack); + SAVE_STACK(switch_cond_stack); + SAVE_STACK(foreach_copy_stack); + SAVE_STACK(object_stack); + SAVE_STACK(declare_stack); + SAVE_STACK(list_stack); + SAVE_STACK(context_stack); } if (call_user_function_ex(CG(function_table), NULL, orig_user_error_handler, &retval, 5, params, 1, NULL TSRMLS_CC) == SUCCESS) { @@ -1139,6 +1172,14 @@ ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */ if (in_compilation) { CG(active_class_entry) = saved_class_entry; + RESTORE_STACK(bp_stack); + RESTORE_STACK(function_call_stack); + RESTORE_STACK(switch_cond_stack); + RESTORE_STACK(foreach_copy_stack); + RESTORE_STACK(object_stack); + RESTORE_STACK(declare_stack); + RESTORE_STACK(list_stack); + RESTORE_STACK(context_stack); } if (!EG(user_error_handler)) { From 4d31e1d143a7153b654ff2516f8c0ff0bb4d8117 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 2 Aug 2011 13:41:20 +0000 Subject: [PATCH 0444/2394] fix warnings due to change in zend_property_info (structure extended in the middle!!) --- ext/mysqli/mysqli_driver.c | 16 ++++---- ext/mysqli/mysqli_priv.h | 10 ++--- ext/mysqli/mysqli_prop.c | 76 ++++++++++++++++++------------------- ext/mysqli/mysqli_warning.c | 10 ++--- 4 files changed, 56 insertions(+), 56 deletions(-) diff --git a/ext/mysqli/mysqli_driver.c b/ext/mysqli/mysqli_driver.c index fd4698febce8c..e6a1fc8fb4335 100644 --- a/ext/mysqli/mysqli_driver.c +++ b/ext/mysqli/mysqli_driver.c @@ -151,14 +151,14 @@ const mysqli_property_entry mysqli_driver_property_entries[] = { }; /* {{{ mysqli_warning_property_info_entries */ -zend_property_info mysqli_driver_property_info_entries[] = { - {ZEND_ACC_PUBLIC, "client_info", sizeof("client_info") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "client_version", sizeof("client_version") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "driver_version", sizeof("driver_version") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "embedded", sizeof("embedded") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "reconnect", sizeof("reconnect") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "report_mode", sizeof("report_mode") - 1, 0, NULL, 0, NULL}, - {0, NULL, 0, 0, NULL, 0, NULL}, +const zend_property_info mysqli_driver_property_info_entries[] = { + {ZEND_ACC_PUBLIC, "client_info", sizeof("client_info") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "client_version", sizeof("client_version") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "driver_version", sizeof("driver_version") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "embedded", sizeof("embedded") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "reconnect", sizeof("reconnect") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "report_mode", sizeof("report_mode") - 1, -1, 0, NULL, 0, NULL}, + {0, NULL, 0, -1, 0, NULL, 0, NULL}, }; /* }}} */ diff --git a/ext/mysqli/mysqli_priv.h b/ext/mysqli/mysqli_priv.h index e6c8e28951e8b..adafe55c140af 100644 --- a/ext/mysqli/mysqli_priv.h +++ b/ext/mysqli/mysqli_priv.h @@ -52,11 +52,11 @@ extern const mysqli_property_entry mysqli_stmt_property_entries[]; extern const mysqli_property_entry mysqli_driver_property_entries[]; extern const mysqli_property_entry mysqli_warning_property_entries[]; -extern zend_property_info mysqli_link_property_info_entries[]; -extern zend_property_info mysqli_result_property_info_entries[]; -extern zend_property_info mysqli_stmt_property_info_entries[]; -extern zend_property_info mysqli_driver_property_info_entries[]; -extern zend_property_info mysqli_warning_property_info_entries[]; +extern const zend_property_info mysqli_link_property_info_entries[]; +extern const zend_property_info mysqli_result_property_info_entries[]; +extern const zend_property_info mysqli_stmt_property_info_entries[]; +extern const zend_property_info mysqli_driver_property_info_entries[]; +extern const zend_property_info mysqli_warning_property_info_entries[]; extern int php_le_pmysqli(void); extern void php_mysqli_dtor_p_elements(void *data); diff --git a/ext/mysqli/mysqli_prop.c b/ext/mysqli/mysqli_prop.c index 1e272c8d45014..8a5eef2dcd564 100644 --- a/ext/mysqli/mysqli_prop.c +++ b/ext/mysqli/mysqli_prop.c @@ -336,26 +336,26 @@ const mysqli_property_entry mysqli_link_property_entries[] = { {NULL, 0, NULL, NULL} }; -/* should not be const, as it is patched during runtime */ -zend_property_info mysqli_link_property_info_entries[] = { - {ZEND_ACC_PUBLIC, "affected_rows", sizeof("affected_rows") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "client_info", sizeof("client_info") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "client_version", sizeof("client_version") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "connect_errno", sizeof("connect_errno") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "connect_error", sizeof("connect_error") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "error", sizeof("error") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "field_count", sizeof("field_count") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "host_info", sizeof("host_info") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "info", sizeof("info") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "insert_id", sizeof("insert_id") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "server_info", sizeof("server_info") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "server_version", sizeof("server_version") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "protocol_version", sizeof("protocol_version")-1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "thread_id", sizeof("thread_id") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "warning_count", sizeof("warning_count") - 1, 0, NULL, 0, NULL}, - {0, NULL, 0, 0, NULL, 0, NULL} + +const zend_property_info mysqli_link_property_info_entries[] = { + {ZEND_ACC_PUBLIC, "affected_rows", sizeof("affected_rows") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "client_info", sizeof("client_info") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "client_version", sizeof("client_version") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "connect_errno", sizeof("connect_errno") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "connect_error", sizeof("connect_error") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "error", sizeof("error") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "field_count", sizeof("field_count") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "host_info", sizeof("host_info") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "info", sizeof("info") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "insert_id", sizeof("insert_id") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "server_info", sizeof("server_info") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "server_version", sizeof("server_version") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "protocol_version", sizeof("protocol_version")-1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "thread_id", sizeof("thread_id") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "warning_count", sizeof("warning_count") - 1, -1, 0, NULL, 0, NULL}, + {0, NULL, 0, -1, 0, NULL, 0, NULL} }; @@ -368,13 +368,13 @@ const mysqli_property_entry mysqli_result_property_entries[] = { {NULL, 0, NULL, NULL} }; -zend_property_info mysqli_result_property_info_entries[] = { - {ZEND_ACC_PUBLIC, "current_field", sizeof("current_field")-1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "field_count", sizeof("field_count") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "lengths", sizeof("lengths") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "num_rows", sizeof("num_rows") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "type", sizeof("type") - 1, 0, NULL, 0, NULL}, - {0, NULL, 0, 0, NULL, 0, NULL} +const zend_property_info mysqli_result_property_info_entries[] = { + {ZEND_ACC_PUBLIC, "current_field", sizeof("current_field")-1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "field_count", sizeof("field_count") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "lengths", sizeof("lengths") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "num_rows", sizeof("num_rows") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "type", sizeof("type") - 1, -1, 0, NULL, 0, NULL}, + {0, NULL, 0, -1, 0, NULL, 0, NULL} }; const mysqli_property_entry mysqli_stmt_property_entries[] = { @@ -391,17 +391,17 @@ const mysqli_property_entry mysqli_stmt_property_entries[] = { }; -zend_property_info mysqli_stmt_property_info_entries[] = { - {ZEND_ACC_PUBLIC, "affected_rows", sizeof("affected_rows") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "insert_id", sizeof("insert_id") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "num_rows", sizeof("num_rows") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "param_count",sizeof("param_count") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "field_count",sizeof("field_count") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "error", sizeof("error") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "id", sizeof("id") - 1, 0, NULL, 0, NULL}, - {0, NULL, 0, 0, NULL, 0, NULL} +const zend_property_info mysqli_stmt_property_info_entries[] = { + {ZEND_ACC_PUBLIC, "affected_rows", sizeof("affected_rows") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "insert_id", sizeof("insert_id") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "num_rows", sizeof("num_rows") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "param_count",sizeof("param_count") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "field_count",sizeof("field_count") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "error", sizeof("error") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "id", sizeof("id") - 1, -1, 0, NULL, 0, NULL}, + {0, NULL, 0, -1, 0, NULL, 0, NULL} }; /* diff --git a/ext/mysqli/mysqli_warning.c b/ext/mysqli/mysqli_warning.c index ee815121b3f87..e6d2f516ec4bd 100644 --- a/ext/mysqli/mysqli_warning.c +++ b/ext/mysqli/mysqli_warning.c @@ -330,11 +330,11 @@ const mysqli_property_entry mysqli_warning_property_entries[] = { /* }}} */ /* {{{ mysqli_warning_property_info_entries */ -zend_property_info mysqli_warning_property_info_entries[] = { - {ZEND_ACC_PUBLIC, "message", sizeof("message") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, 0, NULL, 0, NULL}, - {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, 0, NULL, 0, NULL}, - {0, NULL, 0, 0, NULL, 0, NULL} +const zend_property_info mysqli_warning_property_info_entries[] = { + {ZEND_ACC_PUBLIC, "message", sizeof("message") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, -1, 0, NULL, 0, NULL}, + {0, NULL, 0, -1, 0, NULL, 0, NULL} }; /* }}} */ From 1abe1fb48fdf4e52dfa2e22c4d648c192ff61269 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 2 Aug 2011 14:02:21 +0000 Subject: [PATCH 0445/2394] compile out both parts of the code that are currently unused - fixes a compilation warning --- ext/mysqli/mysqli.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index a0815ea8bd128..fc35c8302e943 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -867,7 +867,7 @@ PHP_RINIT_FUNCTION(mysqli) } /* }}} */ -#ifdef MYSQLI_USE_MYSQLND +#if defined(A0) && defined(MYSQLI_USE_MYSQLND) static void php_mysqli_persistent_helper_for_every(void *p) { TSRMLS_FETCH(); @@ -898,7 +898,7 @@ PHP_RSHUTDOWN_FUNCTION(mysqli) if (MyG(error_msg)) { efree(MyG(error_msg)); } -#if defined(A0) && MYSQLI_USE_MYSQLND +#if defined(A0) && defined(MYSQLI_USE_MYSQLND) /* psession is being called when the connection is freed - explicitly or implicitly */ zend_hash_apply(&EG(persistent_list), (apply_func_t) php_mysqli_persistent_helper_once TSRMLS_CC); #endif From 71cb8322f525449db95749e9f6f0ffcdfc8011c5 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 2 Aug 2011 14:18:56 +0000 Subject: [PATCH 0446/2394] completely compile out a currently non-needed function --- ext/mysql/php_mysql.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index 78972c95c1bb4..f6fd05eb91cee 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -608,7 +608,7 @@ PHP_RINIT_FUNCTION(mysql) /* }}} */ -#ifdef MYSQL_USE_MYSQLND +#if defined(A0) && defined(MYSQL_USE_MYSQLND) static int php_mysql_persistent_helper(zend_rsrc_list_entry *le TSRMLS_DC) { if (le->type == le_plink) { @@ -637,7 +637,7 @@ PHP_RSHUTDOWN_FUNCTION(mysql) efree(MySG(connect_error)); } -#if defined(A0) && MYSQL_USE_MYSQLND +#if defined(A0) && defined(MYSQL_USE_MYSQLND) zend_hash_apply(&EG(persistent_list), (apply_func_t) php_mysql_persistent_helper TSRMLS_CC); #endif From 45867c1750609014d8ac9e1d5ea22841ef3a943e Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 2 Aug 2011 15:30:58 +0000 Subject: [PATCH 0447/2394] Remove a warning by explicitly compiling out a non-used variable --- ext/mysqli/mysqli_api.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index e5fc756a3778a..041875480cd4c 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -2237,7 +2237,9 @@ PHP_FUNCTION(mysqli_stmt_attr_set) MY_STMT *stmt; zval *mysql_stmt; long mode_in; +#if MYSQL_VERSION_ID >= 50107 my_bool mode_b; +#endif ulong mode; ulong attr; void *mode_p; From 99a49480622ccebf4fea3119369f8131bd82ceeb Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Wed, 3 Aug 2011 12:09:28 +0000 Subject: [PATCH 0448/2394] MF PHP_5_4. --- .../libmbfl/filters/mbfilter_sjis_mobile.c | 23 ++++++++++++++++--- .../libmbfl/filters/mbfilter_sjis_mobile.h | 1 + 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c index 62cb186f9f957..5653086647a5e 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -139,7 +139,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo = { mbfl_filt_conv_common_ctor, mbfl_filt_conv_common_dtor, mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush + mbfl_filt_conv_sjis_mobile_flush }; const struct mbfl_convert_vtbl vtbl_sjis_kddi_wchar = { @@ -157,7 +157,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi = { mbfl_filt_conv_common_ctor, mbfl_filt_conv_common_dtor, mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush + mbfl_filt_conv_sjis_mobile_flush }; const struct mbfl_convert_vtbl vtbl_sjis_sb_wchar = { @@ -175,7 +175,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb = { mbfl_filt_conv_common_ctor, mbfl_filt_conv_common_dtor, mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush + mbfl_filt_conv_sjis_mobile_flush }; const struct mbfl_convert_vtbl vtbl_sjis_docomo_pua_wchar = { @@ -1080,6 +1080,23 @@ mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter) return c; } +int +mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter) +{ + int c1 = filter->cache; + if (filter->status == 1 && (c1 == 0x0023 || (c1 >= 0x0030 && c1<=0x0039))) { + CK((*filter->output_function)(c1, filter->data)); + } + filter->status = 0; + filter->cache = 0; + + if (filter->flush_function != NULL) { + return (*filter->flush_function)(filter->data); + } + + return 0; +} + static int mbfl_filt_ident_sjis_mobile(int c, mbfl_identify_filter *filter) { if (filter->status) { /* kanji second char */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h index 405577ca89686..bf504ff3b3684 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -60,5 +60,6 @@ extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua; int mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter); #endif /* MBFL_MBFILTER_SJIS_MOBILE_H */ From 38cb153c427220558147b55a4715860aec4ada04 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 3 Aug 2011 13:19:03 +0000 Subject: [PATCH 0449/2394] - update libcurl to 7.21.7 --- win32/build/libs_version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/win32/build/libs_version.txt b/win32/build/libs_version.txt index 282afb790bf1e..7f808fb5297b5 100644 --- a/win32/build/libs_version.txt +++ b/win32/build/libs_version.txt @@ -1,2 +1,2 @@ -libcurl-7.21.6 +libcurl-7.21.7 libpng-1.2.46 From 463de70efd83274ba8df51a4b75a21c8e6382baa Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 4 Aug 2011 00:59:43 +0000 Subject: [PATCH 0450/2394] - Fixed possible efree(NULL) (bug #55296) --- ext/intl/collator/collator_compare.c | 12 +++-- ext/intl/dateformat/dateformat_attr.c | 4 +- ext/intl/formatter/formatter_attr.c | 12 +++-- ext/intl/formatter/formatter_parse.c | 8 ++- ext/intl/grapheme/grapheme_string.c | 25 +++++++--- ext/intl/grapheme/grapheme_util.c | 49 ++++++++++++++----- ext/intl/idn/idn.c | 4 +- ext/intl/msgformat/msgformat_attr.c | 4 +- ext/intl/msgformat/msgformat_parse.c | 4 +- ext/intl/normalizer/normalizer_normalize.c | 8 ++- .../transliterator/transliterator_methods.c | 8 ++- 11 files changed, 103 insertions(+), 35 deletions(-) diff --git a/ext/intl/collator/collator_compare.c b/ext/intl/collator/collator_compare.c index 4e7b3a7d4949f..840855661cd63 100755 --- a/ext/intl/collator/collator_compare.c +++ b/ext/intl/collator/collator_compare.c @@ -74,7 +74,9 @@ PHP_FUNCTION( collator_compare ) /* Set error messages. */ intl_errors_set_custom_msg( COLLATOR_ERROR_P( co ), "Error converting first argument to UTF-16", 0 TSRMLS_CC ); - efree( ustr1 ); + if (ustr1) { + efree( ustr1 ); + } RETURN_FALSE; } @@ -88,8 +90,12 @@ PHP_FUNCTION( collator_compare ) /* Set error messages. */ intl_errors_set_custom_msg( COLLATOR_ERROR_P( co ), "Error converting second argument to UTF-16", 0 TSRMLS_CC ); - efree( ustr1 ); - efree( ustr2 ); + if (ustr1) { + efree( ustr1 ); + } + if (ustr2) { + efree( ustr2 ); + } RETURN_FALSE; } diff --git a/ext/intl/dateformat/dateformat_attr.c b/ext/intl/dateformat/dateformat_attr.c index 7c6cef9536009..6131cedc956b5 100755 --- a/ext/intl/dateformat/dateformat_attr.c +++ b/ext/intl/dateformat/dateformat_attr.c @@ -276,7 +276,9 @@ PHP_FUNCTION( datefmt_set_pattern ) udat_applyPattern(DATE_FORMAT_OBJECT(dfo), (UBool)is_pattern_localized, svalue, slength); - efree(svalue); + if (svalue) { + efree(svalue); + } INTL_METHOD_CHECK_STATUS(dfo, "Error setting symbol value"); RETURN_TRUE; diff --git a/ext/intl/formatter/formatter_attr.c b/ext/intl/formatter/formatter_attr.c index 46d61fb1fce58..b306bbedeb9f4 100755 --- a/ext/intl/formatter/formatter_attr.c +++ b/ext/intl/formatter/formatter_attr.c @@ -233,7 +233,9 @@ PHP_FUNCTION( numfmt_set_text_attribute ) /* Actually set new attribute value. */ unum_setTextAttribute(FORMATTER_OBJECT(nfo), attribute, svalue, slength, &INTL_DATA_ERROR_CODE(nfo)); - efree(svalue); + if (svalue) { + efree(svalue); + } INTL_METHOD_CHECK_STATUS( nfo, "Error setting text attribute" ); RETURN_TRUE; @@ -326,7 +328,9 @@ PHP_FUNCTION( numfmt_set_symbol ) /* Actually set the symbol. */ unum_setSymbol(FORMATTER_OBJECT(nfo), symbol, svalue, slength, &INTL_DATA_ERROR_CODE(nfo)); - efree(svalue); + if (svalue) { + efree(svalue); + } INTL_METHOD_CHECK_STATUS( nfo, "Error setting symbol value" ); RETURN_TRUE; @@ -406,7 +410,9 @@ PHP_FUNCTION( numfmt_set_pattern ) /* TODO: add parse error information */ unum_applyPattern(FORMATTER_OBJECT(nfo), 0, svalue, slength, NULL, &INTL_DATA_ERROR_CODE(nfo)); - efree(svalue); + if (svalue) { + efree(svalue); + } INTL_METHOD_CHECK_STATUS( nfo, "Error setting pattern value" ); RETURN_TRUE; diff --git a/ext/intl/formatter/formatter_parse.c b/ext/intl/formatter/formatter_parse.c index b73095d3e4e7c..cbdde855dece8 100755 --- a/ext/intl/formatter/formatter_parse.c +++ b/ext/intl/formatter/formatter_parse.c @@ -107,7 +107,9 @@ PHP_FUNCTION( numfmt_parse ) ZVAL_LONG(zposition, position); } - efree(sstr); + if (sstr) { + efree(sstr); + } INTL_METHOD_CHECK_STATUS( nfo, "Number parsing failed" ); } @@ -161,7 +163,9 @@ PHP_FUNCTION( numfmt_parse_currency ) zval_dtor(zposition); ZVAL_LONG(zposition, position); } - efree(sstr); + if (sstr) { + efree(sstr); + } INTL_METHOD_CHECK_STATUS( nfo, "Number parsing failed" ); /* Convert parsed currency to UTF-8 and pass it back to caller. */ diff --git a/ext/intl/grapheme/grapheme_string.c b/ext/intl/grapheme/grapheme_string.c index 1784d028a8bea..095cc2a0466ca 100755 --- a/ext/intl/grapheme/grapheme_string.c +++ b/ext/intl/grapheme/grapheme_string.c @@ -84,13 +84,17 @@ PHP_FUNCTION(grapheme_strlen) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( ustring ); + if (ustring) { + efree( ustring ); + } RETURN_NULL(); } ret_len = grapheme_split_string(ustring, ustring_len, NULL, 0 TSRMLS_CC ); - efree( ustring ); + if (ustring) { + efree( ustring ); + } if (ret_len >= 0) { RETVAL_LONG(ret_len); @@ -447,7 +451,9 @@ PHP_FUNCTION(grapheme_substr) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( ustr ); + if (ustr) { + efree( ustr ); + } RETURN_FALSE; } @@ -485,7 +491,9 @@ PHP_FUNCTION(grapheme_substr) intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, "grapheme_substr: start not contained in string", 1 TSRMLS_CC ); - efree(ustr); + if (ustr) { + efree(ustr); + } ubrk_close(bi); RETURN_FALSE; } @@ -499,7 +507,9 @@ PHP_FUNCTION(grapheme_substr) status = U_ZERO_ERROR; intl_convert_utf16_to_utf8((char **)&sub_str, &sub_str_len, ustr + sub_str_start_pos, ustr_len - sub_str_start_pos, &status); - efree( ustr ); + if (ustr) { + efree( ustr ); + } ubrk_close( bi ); if ( U_FAILURE( status ) ) { @@ -509,6 +519,7 @@ PHP_FUNCTION(grapheme_substr) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting output string to UTF-8", 0 TSRMLS_CC ); + efree( sub_str ); RETURN_FALSE; @@ -897,7 +908,9 @@ PHP_FUNCTION(grapheme_extract) ret_pos = (*grapheme_extract_iters[extract_type])(bi, size, pstr, str_len); - efree(ustr); + if (ustr) { + efree(ustr); + } ubrk_close(bi); if ( NULL != next ) { diff --git a/ext/intl/grapheme/grapheme_util.c b/ext/intl/grapheme/grapheme_util.c index 1978d274a0fd3..db56431648599 100755 --- a/ext/intl/grapheme/grapheme_util.c +++ b/ext/intl/grapheme/grapheme_util.c @@ -170,7 +170,9 @@ grapheme_strrpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned c /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( uhaystack ); + if (uhaystack) { + efree( uhaystack ); + } return -1; } @@ -187,7 +189,9 @@ grapheme_strrpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned c if ( NULL == puhaystack ) { intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, "grapheme_strpos: Offset not contained in string", 1 TSRMLS_CC ); - efree( uhaystack ); + if (uhaystack) { + efree( uhaystack ); + } ubrk_close (bi); return -1; } @@ -203,8 +207,12 @@ grapheme_strrpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned c /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( uhaystack ); - efree( uneedle ); + if (uhaystack) { + efree( uhaystack ); + } + if (uneedle) { + efree( uneedle ); + } ubrk_close (bi); return -1; } @@ -260,8 +268,12 @@ grapheme_strrpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned c } exit: - efree( uhaystack ); - efree( uneedle ); + if (uhaystack) { + efree( uhaystack ); + } + if (uneedle) { + efree( uneedle ); + } ubrk_close (bi); return ret_pos; @@ -295,7 +307,9 @@ grapheme_strpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned ch /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( uhaystack ); + if (uhaystack) { + efree( uhaystack ); + } return -1; } @@ -310,8 +324,9 @@ grapheme_strpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned ch if ( NULL == puhaystack ) { intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, "grapheme_strpos: Offset not contained in string", 1 TSRMLS_CC ); - - efree( uhaystack ); + if (uhaystack) { + efree( uhaystack ); + } ubrk_close (bi); return -1; @@ -332,8 +347,12 @@ grapheme_strpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned ch /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( uhaystack ); - efree( uneedle ); + if (uhaystack) { + efree( uhaystack ); + } + if (uneedle) { + efree( uneedle ); + } ubrk_close (bi); return -1; @@ -347,8 +366,12 @@ grapheme_strpos_utf16(unsigned char *haystack, int32_t haystack_len, unsigned ch *puchar_pos = ubrk_current(bi); - efree( uhaystack ); - efree( uneedle ); + if (uhaystack) { + efree( uhaystack ); + } + if (uneedle) { + efree( uneedle ); + } ubrk_close (bi); return ret_pos; diff --git a/ext/intl/idn/idn.c b/ext/intl/idn/idn.c index e7a3b6a6d2d96..23cd0ea872447 100644 --- a/ext/intl/idn/idn.c +++ b/ext/intl/idn/idn.c @@ -85,7 +85,9 @@ static void php_intl_idn_to(INTERNAL_FUNCTION_PARAMETERS, int mode) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree(ustring); + if (ustring) { + efree(ustring); + } RETURN_FALSE; } else { UParseError parse_error; diff --git a/ext/intl/msgformat/msgformat_attr.c b/ext/intl/msgformat/msgformat_attr.c index 47350b2b451ed..cf346651424b0 100755 --- a/ext/intl/msgformat/msgformat_attr.c +++ b/ext/intl/msgformat/msgformat_attr.c @@ -90,7 +90,9 @@ PHP_FUNCTION( msgfmt_set_pattern ) /* TODO: add parse error information */ umsg_applyPattern(MSG_FORMAT_OBJECT(mfo), spattern, spattern_len, NULL, &INTL_DATA_ERROR_CODE(mfo)); - efree(spattern); + if (spattern) { + efree(spattern); + } INTL_METHOD_CHECK_STATUS(mfo, "Error setting symbol value"); if(mfo->mf_data.orig_format) { diff --git a/ext/intl/msgformat/msgformat_parse.c b/ext/intl/msgformat/msgformat_parse.c index 61c5213f05ef6..8393d4c6e3958 100755 --- a/ext/intl/msgformat/msgformat_parse.c +++ b/ext/intl/msgformat/msgformat_parse.c @@ -40,7 +40,9 @@ static void msgfmt_do_parse(MessageFormatter_object *mfo, char *source, int src_ INTL_METHOD_CHECK_STATUS(mfo, "Converting parse string failed"); umsg_parse_helper(MSG_FORMAT_OBJECT(mfo), &count, &fargs, usource, usrc_len, &INTL_DATA_ERROR_CODE(mfo)); - efree(usource); + if (usource) { + efree(usource); + } INTL_METHOD_CHECK_STATUS(mfo, "Parsing failed"); array_init(return_value); diff --git a/ext/intl/normalizer/normalizer_normalize.c b/ext/intl/normalizer/normalizer_normalize.c index 482c4a01e5912..466ab97e12c86 100755 --- a/ext/intl/normalizer/normalizer_normalize.c +++ b/ext/intl/normalizer/normalizer_normalize.c @@ -96,7 +96,9 @@ PHP_FUNCTION( normalizer_normalize ) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting input string to UTF-16", 0 TSRMLS_CC ); - efree( uinput ); + if (uinput) { + efree( uinput ); + } RETURN_FALSE; } @@ -220,7 +222,9 @@ PHP_FUNCTION( normalizer_is_normalized ) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting string to UTF-16.", 0 TSRMLS_CC ); - efree( uinput ); + if (uinput) { + efree( uinput ); + } RETURN_FALSE; } diff --git a/ext/intl/transliterator/transliterator_methods.c b/ext/intl/transliterator/transliterator_methods.c index e7ea329cef7c8..d0cfb9790d957 100644 --- a/ext/intl/transliterator/transliterator_methods.c +++ b/ext/intl/transliterator/transliterator_methods.c @@ -60,7 +60,9 @@ static int create_transliterator( char *str_id, int str_id_len, long direction, /* Open ICU Transliterator. */ utrans = utrans_openU( ustr_id, ustr_id_len, (UTransDirection ) direction, NULL, -1, &parse_error, TRANSLITERATOR_ERROR_CODE_P( to ) ); - efree( ustr_id ); + if (ustr_id) { + efree( ustr_id ); + } if( U_FAILURE( TRANSLITERATOR_ERROR_CODE( to ) ) ) { @@ -172,7 +174,9 @@ PHP_FUNCTION( transliterator_create_from_rules ) /* Open ICU Transliterator. */ utrans = utrans_openU( id, ( sizeof( id ) - 1 ) / ( sizeof( *id ) ), (UTransDirection ) direction, ustr_rules, ustr_rules_len, &parse_error, TRANSLITERATOR_ERROR_CODE_P( to ) ); - efree( ustr_rules ); + if (ustr_rules) { + efree( ustr_rules ); + } intl_error_set_code( NULL, INTL_DATA_ERROR_CODE( to ) TSRMLS_CC ); if( U_FAILURE( INTL_DATA_ERROR_CODE( to ) ) ) From 11f198b203a715ff4495b452e2ec10bc6f60baad Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 4 Aug 2011 09:51:26 +0000 Subject: [PATCH 0451/2394] Add mysqli_error_list() that returns an array with errors. Typically only one and just one for libmysql. mysqlnd can return generate more than one error during its work and with mysqli_error() only the last error is being reported. In the array returned by mysqli_error_list() / $mysqli->error_list, all errors will be found. The list is reset when the next command is executed --- ext/mysqli/mysqli_fe.c | 2 + ext/mysqli/mysqli_fe.h | 2 + ext/mysqli/mysqli_nonapi.c | 88 +++++++++++++++++ ext/mysqli/mysqli_prop.c | 98 +++++++++++++++++++ ext/mysqli/tests/057.phpt | 3 + ext/mysqli/tests/bug34810.phpt | 5 + .../tests/mysqli_class_mysqli_interface.phpt | 8 ++ ...ysqli_class_mysqli_properties_no_conn.phpt | 4 + .../tests/mysqli_class_mysqli_reflection.phpt | 9 ++ .../mysqli_class_mysqli_stmt_interface.phpt | 8 ++ ext/mysqli/tests/mysqli_connect.phpt | 2 +- ext/mysqli/tests/mysqli_connect_oo.phpt | 2 +- ext/mysqli/tests/mysqli_kill.phpt | 12 +++ ext/mysqli/tests/mysqli_real_connect.phpt | 4 +- .../tests/mysqli_real_connect_pconn.phpt | 2 +- ext/mysqlnd/mysqlnd.c | 28 ++++++ ext/mysqlnd/mysqlnd_auth.c | 5 +- ext/mysqlnd/mysqlnd_loaddata.c | 14 +-- ext/mysqlnd/mysqlnd_priv.h | 28 +++++- ext/mysqlnd/mysqlnd_ps.c | 49 +++++++--- ext/mysqlnd/mysqlnd_result.c | 10 +- ext/mysqlnd/mysqlnd_result_meta.c | 2 +- ext/mysqlnd/mysqlnd_structs.h | 9 ++ 23 files changed, 363 insertions(+), 31 deletions(-) diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c index eb133b1a80d9a..a126148b29f6e 100644 --- a/ext/mysqli/mysqli_fe.c +++ b/ext/mysqli/mysqli_fe.c @@ -352,6 +352,7 @@ const zend_function_entry mysqli_functions[] = { #endif PHP_FE(mysqli_errno, arginfo_mysqli_only_link) PHP_FE(mysqli_error, arginfo_mysqli_only_link) + PHP_FE(mysqli_error_list, arginfo_mysqli_only_link) PHP_FE(mysqli_stmt_execute, arginfo_mysqli_only_statement) PHP_FALIAS(mysqli_execute, mysqli_stmt_execute, arginfo_mysqli_only_statement) PHP_FE(mysqli_fetch_field, arginfo_mysqli_only_result) @@ -424,6 +425,7 @@ const zend_function_entry mysqli_functions[] = { PHP_FE(mysqli_stmt_data_seek, arginfo_mysqli_stmt_data_seek) PHP_FE(mysqli_stmt_errno, arginfo_mysqli_only_statement) PHP_FE(mysqli_stmt_error, arginfo_mysqli_only_statement) + PHP_FE(mysqli_stmt_error_list, arginfo_mysqli_only_statement) PHP_FE(mysqli_stmt_fetch, arginfo_mysqli_only_statement) PHP_FE(mysqli_stmt_field_count, arginfo_mysqli_only_statement) PHP_FE(mysqli_stmt_free_result, arginfo_mysqli_only_statement) diff --git a/ext/mysqli/mysqli_fe.h b/ext/mysqli/mysqli_fe.h index bf2a70ab56941..9dc78431101c9 100644 --- a/ext/mysqli/mysqli_fe.h +++ b/ext/mysqli/mysqli_fe.h @@ -38,6 +38,7 @@ PHP_FUNCTION(mysqli_debug); PHP_FUNCTION(mysqli_dump_debug_info); PHP_FUNCTION(mysqli_errno); PHP_FUNCTION(mysqli_error); +PHP_FUNCTION(mysqli_error_list); PHP_FUNCTION(mysqli_fetch_all); PHP_FUNCTION(mysqli_fetch_array); PHP_FUNCTION(mysqli_fetch_assoc); @@ -111,6 +112,7 @@ PHP_FUNCTION(mysqli_stmt_close); PHP_FUNCTION(mysqli_stmt_data_seek); PHP_FUNCTION(mysqli_stmt_errno); PHP_FUNCTION(mysqli_stmt_error); +PHP_FUNCTION(mysqli_stmt_error_list); PHP_FUNCTION(mysqli_stmt_free_result); PHP_FUNCTION(mysqli_stmt_get_result); PHP_FUNCTION(mysqli_stmt_get_warnings); diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index 11c0618c49f1b..8dbaed2bffefd 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -385,6 +385,7 @@ PHP_FUNCTION(mysqli_fetch_all) /* }}} */ + /* {{{ proto array mysqli_get_client_stats(void) Returns statistics about the zval cache */ PHP_FUNCTION(mysqli_get_client_stats) @@ -415,6 +416,93 @@ PHP_FUNCTION(mysqli_get_connection_stats) #endif /* }}} */ +/* {{{ proto mixed mysqli_error_list (object connection) + Fetches all client errors */ +PHP_FUNCTION(mysqli_error_list) +{ + MY_MYSQL *mysql; + zval *mysql_link; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { + return; + } + MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); + array_init(return_value); +#if defined(MYSQLI_USE_MYSQLND) + if (mysql->mysql->error_info.error_list) { + MYSQLND_ERROR_LIST_ELEMENT * message; + zend_llist_position pos; + for (message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_first_ex(mysql->mysql->error_info.error_list, &pos); + message; + message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_next_ex(mysql->mysql->error_info.error_list, &pos)) + { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), message->error_no); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), message->sqlstate, 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), message->error, 1); + add_next_index_zval(return_value, single_error); + } + } +#else + if (mysql_errno(mysql->mysql)) { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), mysql_errno(mysql->mysql)); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), mysql_sqlstate(mysql->mysql), 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), mysql_error(mysql->mysql), 1); + add_next_index_zval(return_value, single_error); + } +#endif +} +/* }}} */ + + +/* {{{ proto string mysqli_stmt_error_list(object stmt) +*/ +PHP_FUNCTION(mysqli_stmt_error_list) +{ + MY_STMT *stmt; + zval *mysql_stmt; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_stmt, mysqli_stmt_class_entry) == FAILURE) { + return; + } + MYSQLI_FETCH_RESOURCE_STMT(stmt, &mysql_stmt, MYSQLI_STATUS_INITIALIZED); + array_init(return_value); +#if defined(MYSQLI_USE_MYSQLND) + if (stmt->stmt && stmt->stmt->data && stmt->stmt->data->error_info.error_list) { + MYSQLND_ERROR_LIST_ELEMENT * message; + zend_llist_position pos; + for (message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_first_ex(stmt->stmt->data->error_info.error_list, &pos); + message; + message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_next_ex(stmt->stmt->data->error_info.error_list, &pos)) + { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), message->error_no); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), message->sqlstate, 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), message->error, 1); + add_next_index_zval(return_value, single_error); + } + } +#else + if (mysql_stmt_errno(stmt->stmt)) { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), mysql_stmt_errno(stmt->stmt)); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), mysql_stmt_sqlstate(stmt->stmt), 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), mysql_stmt_error(stmt->stmt), 1); + add_next_index_zval(return_value, single_error); + } +#endif +} +/* }}} */ + /* {{{ proto mixed mysqli_fetch_object (object result [, string class_name [, NULL|array ctor_params]]) Fetch a result row as an object */ diff --git a/ext/mysqli/mysqli_prop.c b/ext/mysqli/mysqli_prop.c index 8a5eef2dcd564..9e233022c068b 100644 --- a/ext/mysqli/mysqli_prop.c +++ b/ext/mysqli/mysqli_prop.c @@ -189,6 +189,54 @@ static int link_affected_rows_read(mysqli_object *obj, zval **retval TSRMLS_DC) } /* }}} */ + +/* {{{ property link_error_list_read */ +static int link_error_list_read(mysqli_object *obj, zval **retval TSRMLS_DC) +{ + MY_MYSQL *mysql; + + MAKE_STD_ZVAL(*retval); + + CHECK_STATUS(MYSQLI_STATUS_VALID); + + mysql = (MY_MYSQL *)((MYSQLI_RESOURCE *)(obj->ptr))->ptr; + + array_init(*retval); + if (mysql) { +#if defined(MYSQLI_USE_MYSQLND) + if (mysql->mysql->error_info.error_list) { + MYSQLND_ERROR_LIST_ELEMENT * message; + zend_llist_position pos; + for (message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_first_ex(mysql->mysql->error_info.error_list, &pos); + message; + message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_next_ex(mysql->mysql->error_info.error_list, &pos)) + { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), message->error_no); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), message->sqlstate, 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), message->error, 1); + add_next_index_zval(*retval, single_error); + } + } +#else + if (mysql_errno(mysql->mysql)) { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), mysql_errno(mysql->mysql)); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), mysql_sqlstate(mysql->mysql), 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), mysql_error(mysql->mysql), 1); + add_next_index_zval(*retval, single_error); + } +#endif + } + return SUCCESS; +} +/* }}} */ + + /* link properties */ MYSQLI_MAP_PROPERTY_FUNC_LONG(link_errno_read, mysql_errno, MYSQLI_GET_MYSQL(MYSQLI_STATUS_INITIALIZED), ulong, "%lu") MYSQLI_MAP_PROPERTY_FUNC_STRING(link_error_read, mysql_error, MYSQLI_GET_MYSQL(MYSQLI_STATUS_INITIALIZED)) @@ -202,6 +250,7 @@ MYSQLI_MAP_PROPERTY_FUNC_LONG(link_server_version_read, mysql_get_server_version MYSQLI_MAP_PROPERTY_FUNC_STRING(link_sqlstate_read, mysql_sqlstate, MYSQLI_GET_MYSQL(MYSQLI_STATUS_VALID)) MYSQLI_MAP_PROPERTY_FUNC_LONG(link_thread_id_read, mysql_thread_id, MYSQLI_GET_MYSQL(MYSQLI_STATUS_VALID), ulong, "%lu") MYSQLI_MAP_PROPERTY_FUNC_LONG(link_warning_count_read, mysql_warning_count, MYSQLI_GET_MYSQL(MYSQLI_STATUS_VALID), ulong, "%lu") + /* result properties */ /* {{{ property result_type_read */ @@ -306,6 +355,51 @@ static int stmt_affected_rows_read(mysqli_object *obj, zval **retval TSRMLS_DC) } /* }}} */ +/* {{{ property stmt_error_list_read */ +static int stmt_error_list_read(mysqli_object *obj, zval **retval TSRMLS_DC) +{ + MY_STMT * stmt; + + MAKE_STD_ZVAL(*retval); + CHECK_STATUS(MYSQLI_STATUS_INITIALIZED); + + stmt = (MY_STMT *)((MYSQLI_RESOURCE *)(obj->ptr))->ptr; + array_init(*retval); + if (stmt && stmt->stmt) { +#if defined(MYSQLI_USE_MYSQLND) + if (stmt->stmt->data && stmt->stmt->data->error_info.error_list) { + MYSQLND_ERROR_LIST_ELEMENT * message; + zend_llist_position pos; + for (message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_first_ex(stmt->stmt->data->error_info.error_list, &pos); + message; + message = (MYSQLND_ERROR_LIST_ELEMENT *) zend_llist_get_next_ex(stmt->stmt->data->error_info.error_list, &pos)) + { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), message->error_no); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), message->sqlstate, 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), message->error, 1); + add_next_index_zval(*retval, single_error); + } + } +#else + if (mysql_stmt_errno(stmt->stmt)) { + zval * single_error; + MAKE_STD_ZVAL(single_error); + array_init(single_error); + add_assoc_long_ex(single_error, "errno", sizeof("errno"), mysql_stmt_errno(stmt->stmt)); + add_assoc_string_ex(single_error, "sqlstate", sizeof("sqlstate"), mysql_stmt_sqlstate(stmt->stmt), 1); + add_assoc_string_ex(single_error, "error", sizeof("error"), mysql_stmt_error(stmt->stmt), 1); + add_next_index_zval(*retval, single_error); + } +#endif + } + return SUCCESS; +} +/* }}} */ + + MYSQLI_MAP_PROPERTY_FUNC_LONG(stmt_insert_id_read, mysql_stmt_insert_id, MYSQLI_GET_STMT(MYSQLI_STATUS_VALID), my_ulonglong, MYSQLI_LLU_SPEC) MYSQLI_MAP_PROPERTY_FUNC_LONG(stmt_num_rows_read, mysql_stmt_num_rows, MYSQLI_GET_STMT(MYSQLI_STATUS_VALID), my_ulonglong, MYSQLI_LLU_SPEC) MYSQLI_MAP_PROPERTY_FUNC_LONG(stmt_param_count_read, mysql_stmt_param_count, MYSQLI_GET_STMT(MYSQLI_STATUS_VALID), ulong, "%lu") @@ -323,6 +417,7 @@ const mysqli_property_entry mysqli_link_property_entries[] = { {"connect_error", sizeof("connect_error") - 1, link_connect_error_read, NULL}, {"errno", sizeof("errno") - 1, link_errno_read, NULL}, {"error", sizeof("error") - 1, link_error_read, NULL}, + {"error_list", sizeof("error_list") - 1, link_error_list_read, NULL}, {"field_count", sizeof("field_count") - 1, link_field_count_read, NULL}, {"host_info", sizeof("host_info") - 1, link_host_info_read, NULL}, {"info", sizeof("info") - 1, link_info_read, NULL}, @@ -345,6 +440,7 @@ const zend_property_info mysqli_link_property_info_entries[] = { {ZEND_ACC_PUBLIC, "connect_error", sizeof("connect_error") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "error", sizeof("error") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "error_list", sizeof("error_list") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "field_count", sizeof("field_count") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "host_info", sizeof("host_info") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "info", sizeof("info") - 1, -1, 0, NULL, 0, NULL}, @@ -385,6 +481,7 @@ const mysqli_property_entry mysqli_stmt_property_entries[] = { {"field_count", sizeof("field_count") - 1, stmt_field_count_read, NULL}, {"errno", sizeof("errno") - 1, stmt_errno_read, NULL}, {"error", sizeof("error") - 1, stmt_error_read, NULL}, + {"error_list", sizeof("error_list") - 1, stmt_error_list_read, NULL}, {"sqlstate", sizeof("sqlstate") - 1, stmt_sqlstate_read, NULL}, {"id", sizeof("id") - 1, stmt_id_read, NULL}, {NULL, 0, NULL, NULL} @@ -399,6 +496,7 @@ const zend_property_info mysqli_stmt_property_info_entries[] = { {ZEND_ACC_PUBLIC, "field_count",sizeof("field_count") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "errno", sizeof("errno") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "error", sizeof("error") - 1, -1, 0, NULL, 0, NULL}, + {ZEND_ACC_PUBLIC, "error_list", sizeof("error_list") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "sqlstate", sizeof("sqlstate") - 1, -1, 0, NULL, 0, NULL}, {ZEND_ACC_PUBLIC, "id", sizeof("id") - 1, -1, 0, NULL, 0, NULL}, {0, NULL, 0, -1, 0, NULL, 0, NULL} diff --git a/ext/mysqli/tests/057.phpt b/ext/mysqli/tests/057.phpt index 8c8b3eeed7d8f..2cb887506aa4f 100644 --- a/ext/mysqli/tests/057.phpt +++ b/ext/mysqli/tests/057.phpt @@ -91,6 +91,9 @@ object(mysqli_stmt)#%d (%d) { int(0) [%u|b%"error"]=> %unicode|string%(0) "" + [%u|b%"error_list"]=> + array(0) { + } [%u|b%"sqlstate"]=> %unicode|string%(5) "00000" [%u|b%"id"]=> diff --git a/ext/mysqli/tests/bug34810.phpt b/ext/mysqli/tests/bug34810.phpt index 35eb71753461f..c6158b99137af 100644 --- a/ext/mysqli/tests/bug34810.phpt +++ b/ext/mysqli/tests/bug34810.phpt @@ -77,6 +77,9 @@ object(mysqli)#%d (%d) { int(0) [%u|b%"error"]=> %unicode|string%(0) "" + [%u|b%"error_list"]=> + array(0) { + } [%u|b%"field_count"]=> int(0) [%u|b%"host_info"]=> @@ -113,6 +116,8 @@ object(mysqli)#%d (%d) { int(0) [%u|b%"error"]=> %unicode|string%(0) "" + [%u|b%"error_list"]=> + NULL [%u|b%"field_count"]=> NULL [%u|b%"host_info"]=> diff --git a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt index a3bd92fcfc70c..9eff426911af4 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt @@ -131,6 +131,11 @@ require_once('skipifconnectfailure.inc'); $mysqli->error, gettype($mysqli->error), mysqli_error($link), gettype(mysqli_error($link))); + assert(mysqli_error_list($link) === $mysqli->error_list); + printf("mysqli->error_list = '%s'/%s ('%s'/%s)\n", + $mysqli->error_list, gettype($mysqli->error_list), + mysqli_error_list($link), gettype(mysqli_error_list($link))); + assert(mysqli_field_count($link) === $mysqli->field_count); printf("mysqli->field_count = '%s'/%s ('%s'/%s)\n", $mysqli->field_count, gettype($mysqli->field_count), @@ -222,6 +227,7 @@ connect_errno connect_error errno error +error_list field_count host_info info @@ -241,6 +247,7 @@ connect_errno connect_error errno error +error_list field_count host_info info @@ -258,6 +265,7 @@ mysqli->client_info = '%s'/%unicode|string% ('%s'/%unicode|string%) mysqli->client_version = '%d'/integer ('%d'/integer) mysqli->errno = '0'/integer ('0'/integer) mysqli->error = ''/%unicode|string% (''/%unicode|string%) +mysqli->error_list = 'Array'/array ('Array'/array) mysqli->field_count = '0'/integer ('0'/integer) mysqli->insert_id = '0'/integer ('0'/integer) mysqli->sqlstate = '00000'/%unicode|string% ('00000'/%unicode|string%) diff --git a/ext/mysqli/tests/mysqli_class_mysqli_properties_no_conn.phpt b/ext/mysqli/tests/mysqli_class_mysqli_properties_no_conn.phpt index d0940a7561424..61630b0961ec3 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_properties_no_conn.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_properties_no_conn.phpt @@ -151,6 +151,7 @@ connect_errno = '%s' connect_error = ''%s' errno = 'NULL' error = 'NULL' +error_list = 'NULL' field_count = 'NULL' host_info = 'NULL' info = 'NULL' @@ -170,6 +171,7 @@ connect_errno = '%s' connect_error = '%s' errno = 'NULL' error = 'NULL' +error_list = 'NULL' field_count = 'NULL' host_info = 'NULL' info = 'NULL' @@ -220,6 +222,7 @@ connect_errno = '%s' connect_error = '%s' errno = 'NULL' error = 'NULL' +error_list = 'NULL' field_count = 'NULL' host_info = 'NULL' info = 'NULL' @@ -239,6 +242,7 @@ connect_errno = '%s' connect_error = '%s' errno = 'NULL' error = 'NULL' +error_list = 'NULL' field_count = 'NULL' host_info = 'NULL' info = 'NULL' diff --git a/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt index 3ce2b588f804a..c7f348323e2de 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt @@ -1129,6 +1129,14 @@ isStatic: no isDefault: yes Modifiers: 256 +Inspecting property 'error_list' +isPublic: yes +isPrivate: no +isProtected: no +isStatic: no +isDefault: yes +Modifiers: 256 + Inspecting property 'field_count' isPublic: yes isPrivate: no @@ -1215,6 +1223,7 @@ Default property 'connect_errno' Default property 'connect_error' Default property 'errno' Default property 'error' +Default property 'error_list' Default property 'field_count' Default property 'host_info' Default property 'info' diff --git a/ext/mysqli/tests/mysqli_class_mysqli_stmt_interface.phpt b/ext/mysqli/tests/mysqli_class_mysqli_stmt_interface.phpt index 7cbb12721275d..acf737919887e 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_stmt_interface.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_stmt_interface.phpt @@ -97,6 +97,9 @@ printf("stmt->errno = '%s'\n", $stmt->errno); assert(mysqli_stmt_error($stmt) === $stmt->error); printf("stmt->error = '%s'\n", $stmt->error); +assert(mysqli_stmt_error_list($stmt) === $stmt->error_list); +var_dump("stmt->error = ", $stmt->error_list); + assert(mysqli_stmt_field_count($stmt) === $stmt->field_count); printf("stmt->field_count = '%s'\n", $stmt->field_count); @@ -143,6 +146,7 @@ Class variables: affected_rows errno error +error_list field_count id insert_id @@ -158,6 +162,7 @@ param_count field_count errno error +error_list sqlstate id @@ -173,6 +178,9 @@ stmt->affected_rows = '' stmt->affected_rows = '1' stmt->errno = '0' stmt->error = '' +string(14) "stmt->error = " +array(0) { +} stmt->field_count = '0' stmt->id = '%d' stmt->insert_id = '0' diff --git a/ext/mysqli/tests/mysqli_connect.phpt b/ext/mysqli/tests/mysqli_connect.phpt index cf7c7bede87fd..e9d6ed543fa95 100644 --- a/ext/mysqli/tests/mysqli_connect.phpt +++ b/ext/mysqli/tests/mysqli_connect.phpt @@ -146,7 +146,7 @@ mysqli_connect() print "done!"; ?> --EXPECTF-- -Warning: mysqli_connect(): (%d/%d): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d +Warning: mysqli_connect(): (%s/%d): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d array(1) { [%u|b%"testing"]=> %unicode|string%(21) "mysqli.default_socket" diff --git a/ext/mysqli/tests/mysqli_connect_oo.phpt b/ext/mysqli/tests/mysqli_connect_oo.phpt index d406e24845d13..af257ca6df96c 100644 --- a/ext/mysqli/tests/mysqli_connect_oo.phpt +++ b/ext/mysqli/tests/mysqli_connect_oo.phpt @@ -144,7 +144,7 @@ new mysqli() print "done!"; ?> --EXPECTF-- -Warning: mysqli::mysqli(): (%d/%d): Access denied for user '%sunknown%s'@'%s' (using password: %s) in %s on line %d +Warning: mysqli::mysqli(): (%s/%d): Access denied for user '%sunknown%s'@'%s' (using password: %s) in %s on line %d ... and now Exceptions Access denied for user '%s'@'%s' (using password: %s) done! \ No newline at end of file diff --git a/ext/mysqli/tests/mysqli_kill.phpt b/ext/mysqli/tests/mysqli_kill.phpt index 5706adf46d4bd..bb83dd6c05766 100644 --- a/ext/mysqli/tests/mysqli_kill.phpt +++ b/ext/mysqli/tests/mysqli_kill.phpt @@ -96,6 +96,18 @@ object(mysqli)#%d (%d) { int(2006) [%u|b%"error"]=> %unicode|string%(%d) "%s" + [%u|b%"error_list"]=> + array(1) { + [0]=> + array(3) { + [%u|b%"errno"]=> + int(2006) + [%u|b%"sqlstate"]=> + %unicode|string%(5) "%s" + [%u|b%"error"]=> + %unicode|string%(%d) "%s" + } + } [%u|b%"field_count"]=> int(0) [%u|b%"host_info"]=> diff --git a/ext/mysqli/tests/mysqli_real_connect.phpt b/ext/mysqli/tests/mysqli_real_connect.phpt index 2c371328b989b..350c30092eb3d 100644 --- a/ext/mysqli/tests/mysqli_real_connect.phpt +++ b/ext/mysqli/tests/mysqli_real_connect.phpt @@ -175,7 +175,7 @@ require_once('skipifconnectfailure.inc'); require_once("clean_table.inc"); ?> --EXPECTF-- -Warning: mysqli_real_connect(): (%d/%d): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d +Warning: mysqli_real_connect(): (%s/%d): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d object(mysqli)#%d (%d) { [%u|b%"affected_rows"]=> NULL @@ -191,6 +191,8 @@ object(mysqli)#%d (%d) { %s [%u|b%"error"]=> %s + [%u|b%"error_list"]=> + NULL [%u|b%"field_count"]=> NULL [%u|b%"host_info"]=> diff --git a/ext/mysqli/tests/mysqli_real_connect_pconn.phpt b/ext/mysqli/tests/mysqli_real_connect_pconn.phpt index 5dedd47c9615d..4cc18198c67c7 100644 --- a/ext/mysqli/tests/mysqli_real_connect_pconn.phpt +++ b/ext/mysqli/tests/mysqli_real_connect_pconn.phpt @@ -151,5 +151,5 @@ mysqli.max_persistent=10 require_once("clean_table.inc"); ?> --EXPECTF-- -Warning: mysqli_real_connect(): (%d/%d): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d +Warning: mysqli_real_connect(): (%s/%d): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d done! diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index e02fd79099b03..e850862c88e21 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -69,6 +69,21 @@ static struct st_mysqlnd_conn_methods *mysqlnd_conn_methods; static struct st_mysqlnd_plugin_core mysqlnd_plugin_core; +/* {{{ mysqlnd_error_list_pdtor */ +static void +mysqlnd_error_list_pdtor(void * pDest) +{ + MYSQLND_ERROR_LIST_ELEMENT * element = (MYSQLND_ERROR_LIST_ELEMENT *) pDest; + TSRMLS_FETCH(); + DBG_ENTER("mysqlnd_error_list_pdtor"); + if (element->error) { + mnd_pefree(element->error, TRUE); + } + DBG_VOID_RETURN; +} +/* }}} */ + + /* {{{ mysqlnd_library_end */ PHPAPI void mysqlnd_library_end(TSRMLS_D) { @@ -178,6 +193,11 @@ MYSQLND_METHOD(mysqlnd_conn, free_contents)(MYSQLND * conn TSRMLS_DC) mnd_pefree(conn->last_message, pers); conn->last_message = NULL; } + if (conn->error_info.error_list) { + zend_llist_clean(conn->error_info.error_list); + mnd_pefree(conn->error_info.error_list, pers); + conn->error_info.error_list = NULL; + } conn->charset = NULL; conn->greet_charset = NULL; @@ -2492,6 +2512,14 @@ PHPAPI MYSQLND * _mysqlnd_init(zend_bool persistent TSRMLS_DC) ret = NULL; } + ret->error_info.error_list = mnd_pecalloc(1, sizeof(zend_llist), persistent); + if (!ret->error_info.error_list) { + ret->m->dtor(ret TSRMLS_CC); + ret = NULL; + } else { + zend_llist_init(ret->error_info.error_list, sizeof(MYSQLND_ERROR_LIST_ELEMENT), (llist_dtor_func_t)mysqlnd_error_list_pdtor, persistent); + } + DBG_RETURN(ret); } /* }}} */ diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index 1bb08013c279b..1a56e8ef0af4d 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -137,8 +137,7 @@ mysqlnd_auth_handshake(MYSQLND * conn, strlcpy(conn->error_info.sqlstate, auth_resp_packet->sqlstate, sizeof(conn->error_info.sqlstate)); DBG_ERR_FMT("ERROR:%u [SQLSTATE:%s] %s", auth_resp_packet->error_no, auth_resp_packet->sqlstate, auth_resp_packet->error); } - conn->error_info.error_no = auth_resp_packet->error_no; - strlcpy(conn->error_info.error, auth_resp_packet->error, sizeof(conn->error_info.error)); + SET_CLIENT_ERROR(conn->error_info, auth_resp_packet->error_no, UNKNOWN_SQLSTATE, auth_resp_packet->error); } goto end; } @@ -235,7 +234,7 @@ mysqlnd_auth_change_user(MYSQLND * const conn, } ret = PACKET_READ(chg_user_resp, conn); - conn->error_info = chg_user_resp->error_info; + COPY_CLIENT_ERROR(conn->error_info, chg_user_resp->error_info); if (0xFE == chg_user_resp->response_code) { ret = FAIL; diff --git a/ext/mysqlnd/mysqlnd_loaddata.c b/ext/mysqlnd/mysqlnd_loaddata.c index e7803c816906a..db7a9e720185d 100644 --- a/ext/mysqlnd/mysqlnd_loaddata.c +++ b/ext/mysqlnd/mysqlnd_loaddata.c @@ -181,11 +181,12 @@ mysqlnd_handle_local_infile(MYSQLND *conn, const char *filename, zend_bool *is_w /* init handler: allocate read buffer and open file */ if (infile.local_infile_init(&info, (char *)filename, conn->infile.userdata TSRMLS_CC)) { + char tmp_buf[sizeof(conn->error_info.error)]; + int tmp_error_no; *is_warning = TRUE; /* error occured */ - strcpy(conn->error_info.sqlstate, UNKNOWN_SQLSTATE); - conn->error_info.error_no = - infile.local_infile_error(info, conn->error_info.error, sizeof(conn->error_info.error) TSRMLS_CC); + tmp_error_no = infile.local_infile_error(info, tmp_buf, sizeof(tmp_buf) TSRMLS_CC); + SET_CLIENT_ERROR(conn->error_info, tmp_error_no, UNKNOWN_SQLSTATE, tmp_buf); /* write empty packet to server */ ret = conn->net->m.send(conn, empty_packet, 0 TSRMLS_CC); goto infile_error; @@ -208,11 +209,12 @@ mysqlnd_handle_local_infile(MYSQLND *conn, const char *filename, zend_bool *is_w /* error during read occured */ if (bufsize < 0) { + char tmp_buf[sizeof(conn->error_info.error)]; + int tmp_error_no; *is_warning = TRUE; DBG_ERR_FMT("Bufsize < 0, warning, %d %s %s", CR_SERVER_LOST, UNKNOWN_SQLSTATE, lost_conn); - strcpy(conn->error_info.sqlstate, UNKNOWN_SQLSTATE); - conn->error_info.error_no = - infile.local_infile_error(info, conn->error_info.error, sizeof(conn->error_info.error) TSRMLS_CC); + tmp_error_no = infile.local_infile_error(info, tmp_buf, sizeof(tmp_buf) TSRMLS_CC); + SET_CLIENT_ERROR(conn->error_info, tmp_error_no, UNKNOWN_SQLSTATE, tmp_buf); goto infile_error; } diff --git a/ext/mysqlnd/mysqlnd_priv.h b/ext/mysqlnd/mysqlnd_priv.h index 49ec127800634..5bd688a285417 100644 --- a/ext/mysqlnd/mysqlnd_priv.h +++ b/ext/mysqlnd/mysqlnd_priv.h @@ -134,15 +134,41 @@ (error_info).error_no = 0; \ (error_info).error[0] = '\0'; \ strlcpy((error_info).sqlstate, "00000", sizeof((error_info).sqlstate)); \ + if ((error_info).error_list) { \ + zend_llist_clean((error_info).error_list); \ + } \ } + #define SET_CLIENT_ERROR(error_info, a, b, c) \ - { \ +{ \ + if (0 == (a)) { \ + SET_EMPTY_ERROR((error_info)); \ + } else { \ (error_info).error_no = (a); \ strlcpy((error_info).sqlstate, (b), sizeof((error_info).sqlstate)); \ strlcpy((error_info).error, (c), sizeof((error_info).error)); \ + if ((error_info).error_list) {\ + MYSQLND_ERROR_LIST_ELEMENT error_for_the_list = {0}; \ + \ + error_for_the_list.error_no = (a); \ + strlcpy(error_for_the_list.sqlstate, (b), sizeof(error_for_the_list.sqlstate)); \ + error_for_the_list.error = mnd_pestrdup((c), TRUE); \ + if (error_for_the_list.error) { \ + DBG_INF_FMT("adding error [%s] to the list", error_for_the_list.error); \ + zend_llist_add_element((error_info).error_list, &error_for_the_list); \ + } \ + } \ + } \ +} + + +#define COPY_CLIENT_ERROR(error_info_to, error_info_from) \ + { \ + SET_CLIENT_ERROR((error_info_to), (error_info_from).error_no, (error_info_from).sqlstate, (error_info_from).error); \ } + #define SET_OOM_ERROR(error_info) SET_CLIENT_ERROR((error_info), CR_OUT_OF_MEMORY, UNKNOWN_SQLSTATE, mysqlnd_out_of_memory) diff --git a/ext/mysqlnd/mysqlnd_ps.c b/ext/mysqlnd/mysqlnd_ps.c index 0930987094dac..e4688c15646d3 100644 --- a/ext/mysqlnd/mysqlnd_ps.c +++ b/ext/mysqlnd/mysqlnd_ps.c @@ -52,6 +52,22 @@ enum_func_status mysqlnd_fetch_stmt_row_cursor(MYSQLND_RES *result, void *param, static void mysqlnd_stmt_separate_result_bind(MYSQLND_STMT * const stmt TSRMLS_DC); static void mysqlnd_stmt_separate_one_result_bind(MYSQLND_STMT * const stmt, unsigned int param_no TSRMLS_DC); + +/* {{{ mysqlnd_ps_error_list_pdtor */ +static void +mysqlnd_ps_error_list_pdtor(void * pDest) +{ + MYSQLND_ERROR_LIST_ELEMENT * element = (MYSQLND_ERROR_LIST_ELEMENT *) pDest; + TSRMLS_FETCH(); + DBG_ENTER("mysqlnd_ps_error_list_pdtor"); + if (element->error) { + mnd_pefree(element->error, TRUE); + } + DBG_VOID_RETURN; +} +/* }}} */ + + /* {{{ mysqlnd_stmt::store_result */ static MYSQLND_RES * MYSQLND_METHOD(mysqlnd_stmt, store_result)(MYSQLND_STMT * const s TSRMLS_DC) @@ -110,7 +126,7 @@ MYSQLND_METHOD(mysqlnd_stmt, store_result)(MYSQLND_STMT * const s TSRMLS_DC) stmt->state = MYSQLND_STMT_USE_OR_STORE_CALLED; } else { - conn->error_info = result->stored_data->error_info; + COPY_CLIENT_ERROR(conn->error_info, result->stored_data->error_info); stmt->result->m.free_result_contents(stmt->result TSRMLS_CC); mnd_efree(stmt->result); stmt->result = NULL; @@ -177,7 +193,7 @@ MYSQLND_METHOD(mysqlnd_stmt, get_result)(MYSQLND_STMT * const s TSRMLS_DC) stmt->state = MYSQLND_STMT_PREPARED; result->type = MYSQLND_RES_PS_BUF; } else { - stmt->error_info = conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, conn->error_info); stmt->state = MYSQLND_STMT_PREPARED; break; } @@ -300,7 +316,8 @@ mysqlnd_stmt_read_prepare_response(MYSQLND_STMT * s TSRMLS_DC) } if (0xFF == prepare_resp->error_code) { - stmt->error_info = stmt->conn->error_info = prepare_resp->error_info; + COPY_CLIENT_ERROR(stmt->error_info, prepare_resp->error_info); + COPY_CLIENT_ERROR(stmt->conn->error_info, prepare_resp->error_info); goto done; } ret = PASS; @@ -484,7 +501,7 @@ mysqlnd_stmt_execute_parse_response(MYSQLND_STMT * const s TSRMLS_DC) ret = mysqlnd_query_read_result_set_header(stmt->conn, s TSRMLS_CC); if (ret == FAIL) { - stmt->error_info = conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, conn->error_info); stmt->upsert_status.affected_rows = conn->upsert_status.affected_rows; if (CONN_GET_STATE(conn) == CONN_QUIT_SENT) { /* close the statement here, the connection has been closed */ @@ -685,7 +702,7 @@ MYSQLND_METHOD(mysqlnd_stmt, execute)(MYSQLND_STMT * const s TSRMLS_DC) } if (ret == FAIL) { - stmt->error_info = conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, conn->error_info); DBG_INF("FAIL"); DBG_RETURN(FAIL); } @@ -902,8 +919,8 @@ mysqlnd_stmt_fetch_row_unbuffered(MYSQLND_RES *result, void *param, unsigned int *fetched_anything = TRUE; } else if (ret == FAIL) { if (row_packet->error_info.error_no) { - stmt->conn->error_info = row_packet->error_info; - stmt->error_info = row_packet->error_info; + COPY_CLIENT_ERROR(stmt->conn->error_info, row_packet->error_info); + COPY_CLIENT_ERROR(stmt->error_info, row_packet->error_info); } CONN_SET_STATE(result->conn, CONN_READY); result->unbuf->eof_reached = TRUE; /* so next time we won't get an error */ @@ -1014,7 +1031,7 @@ mysqlnd_fetch_stmt_row_cursor(MYSQLND_RES *result, void *param, unsigned int fla if (FAIL == stmt->conn->m->simple_command(stmt->conn, COM_STMT_FETCH, buf, sizeof(buf), PROT_LAST /* we will handle the response packet*/, FALSE, TRUE TSRMLS_CC)) { - stmt->error_info = stmt->conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, stmt->conn->error_info); DBG_RETURN(FAIL); } @@ -1218,7 +1235,7 @@ MYSQLND_METHOD(mysqlnd_stmt, reset)(MYSQLND_STMT * const s TSRMLS_DC) FAIL == (ret = conn->m->simple_command(conn, COM_STMT_RESET, cmd_buf, sizeof(cmd_buf), PROT_OK_PACKET, FALSE, TRUE TSRMLS_CC))) { - stmt->error_info = conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, conn->error_info); } stmt->upsert_status = conn->upsert_status; @@ -1337,7 +1354,7 @@ MYSQLND_METHOD(mysqlnd_stmt, send_long_data)(MYSQLND_STMT * const s, unsigned in ret = conn->m->simple_command(conn, cmd, cmd_buf, packet_len, PROT_LAST , FALSE, TRUE TSRMLS_CC); mnd_efree(cmd_buf); if (FAIL == ret) { - stmt->error_info = conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, conn->error_info); } } else { ret = FAIL; @@ -2117,6 +2134,11 @@ MYSQLND_METHOD(mysqlnd_stmt, free_stmt_content)(MYSQLND_STMT * const s TSRMLS_DC stmt->result->m.free_result_internal(stmt->result TSRMLS_CC); stmt->result = NULL; } + if (stmt->error_info.error_list) { + zend_llist_clean(stmt->error_info.error_list); + mnd_pefree(stmt->error_info.error_list, s->persistent); + stmt->error_info.error_list = NULL; + } DBG_VOID_RETURN; } @@ -2174,7 +2196,7 @@ MYSQLND_METHOD_PRIVATE(mysqlnd_stmt, net_close)(MYSQLND_STMT * const s, zend_boo FAIL == conn->m->simple_command(conn, COM_STMT_CLOSE, cmd_buf, sizeof(cmd_buf), PROT_LAST /* COM_STMT_CLOSE doesn't send an OK packet*/, FALSE, TRUE TSRMLS_CC)) { - stmt->error_info = conn->error_info; + COPY_CLIENT_ERROR(stmt->error_info, conn->error_info); DBG_RETURN(FAIL); } } @@ -2375,6 +2397,11 @@ MYSQLND_STMT * _mysqlnd_stmt_init(MYSQLND * const conn TSRMLS_DC) or normal query result will close it then. */ stmt->conn = conn->m->get_reference(conn TSRMLS_CC); + stmt->error_info.error_list = mnd_pecalloc(1, sizeof(zend_llist), ret->persistent); + if (!stmt->error_info.error_list) { + break; + } + zend_llist_init(stmt->error_info.error_list, sizeof(MYSQLND_ERROR_LIST_ELEMENT), (llist_dtor_func_t) mysqlnd_ps_error_list_pdtor, conn->persistent); DBG_RETURN(ret); } while (0); diff --git a/ext/mysqlnd/mysqlnd_result.c b/ext/mysqlnd/mysqlnd_result.c index f1c633278860a..6262793803bc4 100644 --- a/ext/mysqlnd/mysqlnd_result.c +++ b/ext/mysqlnd/mysqlnd_result.c @@ -400,7 +400,7 @@ mysqlnd_query_read_result_set_header(MYSQLND *conn, MYSQLND_STMT * s TSRMLS_DC) This will copy the error code and the messages, as they are buffers in the struct */ - conn->error_info = rset_header->error_info; + COPY_CLIENT_ERROR(conn->error_info, rset_header->error_info); ret = FAIL; DBG_ERR_FMT("error=%s", rset_header->error_info.error); /* Return back from CONN_QUERY_SENT */ @@ -705,7 +705,7 @@ mysqlnd_fetch_row_unbuffered_c(MYSQLND_RES * result TSRMLS_DC) } } else if (ret == FAIL) { if (row_packet->error_info.error_no) { - result->conn->error_info = row_packet->error_info; + COPY_CLIENT_ERROR(result->conn->error_info, row_packet->error_info); DBG_ERR_FMT("errorno=%u error=%s", row_packet->error_info.error_no, row_packet->error_info.error); } CONN_SET_STATE(result->conn, CONN_READY); @@ -840,7 +840,7 @@ mysqlnd_fetch_row_unbuffered(MYSQLND_RES * result, void *param, unsigned int fla result->unbuf->row_count++; } else if (ret == FAIL) { if (row_packet->error_info.error_no) { - result->conn->error_info = row_packet->error_info; + COPY_CLIENT_ERROR(result->conn->error_info, row_packet->error_info); DBG_ERR_FMT("errorno=%u error=%s", row_packet->error_info.error_no, row_packet->error_info.error); } CONN_SET_STATE(result->conn, CONN_READY); @@ -1228,7 +1228,7 @@ MYSQLND_METHOD(mysqlnd_res, store_result_fetch_data)(MYSQLND * const conn, MYSQL } if (ret == FAIL) { - set->error_info = row_packet->error_info; + COPY_CLIENT_ERROR(set->error_info, row_packet->error_info); } else { /* Position at the first row */ set->data_cursor = set->data; @@ -1277,7 +1277,7 @@ MYSQLND_METHOD(mysqlnd_res, store_result)(MYSQLND_RES * result, ret = result->m.store_result_fetch_data(conn, result, result->meta, ps_protocol TSRMLS_CC); if (FAIL == ret) { if (result->stored_data) { - conn->error_info = result->stored_data->error_info; + COPY_CLIENT_ERROR(conn->error_info, result->stored_data->error_info); } else { SET_OOM_ERROR(conn->error_info); } diff --git a/ext/mysqlnd/mysqlnd_result_meta.c b/ext/mysqlnd/mysqlnd_result_meta.c index fbef4daf8c681..51588016a4c02 100644 --- a/ext/mysqlnd/mysqlnd_result_meta.c +++ b/ext/mysqlnd/mysqlnd_result_meta.c @@ -170,7 +170,7 @@ MYSQLND_METHOD(mysqlnd_res_meta, read_metadata)(MYSQLND_RES_METADATA * const met DBG_RETURN(FAIL); } if (field_packet->error_info.error_no) { - conn->error_info = field_packet->error_info; + COPY_CLIENT_ERROR(conn->error_info, field_packet->error_info); /* Return back from CONN_QUERY_SENT */ PACKET_FREE(field_packet); DBG_RETURN(FAIL); diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index edea2e895c105..94af6ced24a82 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -102,9 +102,18 @@ typedef struct st_mysqlnd_error_info char error[MYSQLND_ERRMSG_SIZE+1]; char sqlstate[MYSQLND_SQLSTATE_LENGTH + 1]; unsigned int error_no; + zend_llist * error_list; } MYSQLND_ERROR_INFO; +typedef struct st_mysqlnd_error_list_element +{ + char * error; + char sqlstate[MYSQLND_SQLSTATE_LENGTH + 1]; + unsigned int error_no; +} MYSQLND_ERROR_LIST_ELEMENT; + + typedef struct st_mysqlnd_infile_info { php_stream *fd; From 8cf0864b8ce348e0b36600ce115e9fd8c3224986 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Thu, 4 Aug 2011 10:56:59 +0000 Subject: [PATCH 0452/2394] - Added missing check (thanks neweracracker at gmail dot com) --- ext/intl/grapheme/grapheme_string.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/intl/grapheme/grapheme_string.c b/ext/intl/grapheme/grapheme_string.c index 095cc2a0466ca..769ff7ddbb152 100755 --- a/ext/intl/grapheme/grapheme_string.c +++ b/ext/intl/grapheme/grapheme_string.c @@ -519,8 +519,9 @@ PHP_FUNCTION(grapheme_substr) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting output string to UTF-8", 0 TSRMLS_CC ); - - efree( sub_str ); + if (sub_str) { + efree( sub_str ); + } RETURN_FALSE; } From bab1e815d2a52259edf026e7f8cb93c8067d6dfe Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Thu, 4 Aug 2011 12:11:04 +0000 Subject: [PATCH 0453/2394] removed invalid 5,6 byte encoding from utf-8 based on Unicode 5.2. --- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 57 ++------------------ 1 file changed, 4 insertions(+), 53 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index c6777b29fd3f1..0e788f389c904 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -52,7 +52,7 @@ static const unsigned char mblen_table_utf8[] = { 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 1, 1 + 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, 1, 1, 1, 1, 1 }; static const char *mbfl_encoding_utf8_aliases[] = {"utf8", NULL}; @@ -111,40 +111,23 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) case 0x10: /* 2byte code 2nd char */ case 0x21: /* 3byte code 3rd char */ case 0x32: /* 4byte code 4th char */ - case 0x43: /* 5byte code 5th char */ - case 0x54: /* 6byte code 6th char */ filter->status = 0; s = filter->cache | (c & 0x3f); if ((status == 0x10 && s >= 0x80) || (status == 0x21 && s >= 0x800 && (s < 0xd800 || s > 0xdfff)) || - (status == 0x32 && s >= 0x10000) || - (status == 0x43 && s >= 0x200000) || - (status == 0x54 && s >= 0x4000000 && s < MBFL_WCSGROUP_UCS4MAX)) { + (status == 0x32 && s >= 0x10000 && s < 0x200000)) { CK((*filter->output_function)(s, filter->data)); } break; case 0x20: /* 3byte code 2nd char */ case 0x31: /* 4byte code 3rd char */ - case 0x42: /* 5byte code 4th char */ - case 0x53: /* 6byte code 5th char */ filter->cache |= ((c & 0x3f) << 6); filter->status++; break; case 0x30: /* 4byte code 2nd char */ - case 0x41: /* 5byte code 3rd char */ - case 0x52: /* 6byte code 4th char */ filter->cache |= ((c & 0x3f) << 12); filter->status++; break; - case 0x40: /* 5byte code 2nd char */ - case 0x51: /* 6byte code 3rd char */ - filter->cache |= ((c & 0x3f) << 18); - filter->status++; - break; - case 0x50: /* 6byte code 2nd char */ - filter->cache |= ((c & 0x3f) << 24); - filter->status++; - break; default: filter->status = 0; break; @@ -158,12 +141,6 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) } else if (c < 0xf8) { /* 4byte code first char */ filter->status = 0x30; filter->cache = (c & 0x7) << 18; - } else if (c < 0xfc) { /* 5byte code first char */ - filter->status = 0x40; - filter->cache = (c & 0x3) << 24; - } else if (c < 0xfe) { /* 6 byte code first char */ - filter->status = 0x50; - filter->cache = (c & 0x1) << 30; } else { filter->status = 0; filter->cache = 0; @@ -177,7 +154,7 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) */ int mbfl_filt_conv_wchar_utf8(int c, mbfl_convert_filter *filter) { - if (c >= 0 && c < MBFL_WCSGROUP_UCS4MAX) { + if (c >= 0 && c < 0x200000) { if (c < 0x80) { CK((*filter->output_function)(c, filter->data)); } else if (c < 0x800) { @@ -187,21 +164,8 @@ int mbfl_filt_conv_wchar_utf8(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(((c >> 12) & 0x0f) | 0xe0, filter->data)); CK((*filter->output_function)(((c >> 6) & 0x3f) | 0x80, filter->data)); CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); - } else if (c < 0x200000) { - CK((*filter->output_function)(((c >> 18) & 0x07) | 0xf0, filter->data)); - CK((*filter->output_function)(((c >> 12) & 0x3f) | 0x80, filter->data)); - CK((*filter->output_function)(((c >> 6) & 0x3f) | 0x80, filter->data)); - CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); - } else if (c < 0x4000000) { - CK((*filter->output_function)(((c >> 24) & 0x03) | 0xf8, filter->data)); - CK((*filter->output_function)(((c >> 18) & 0x3f) | 0x80, filter->data)); - CK((*filter->output_function)(((c >> 12) & 0x3f) | 0x80, filter->data)); - CK((*filter->output_function)(((c >> 6) & 0x3f) | 0x80, filter->data)); - CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); } else { - CK((*filter->output_function)(((c >> 30) & 0x01) | 0xfc, filter->data)); - CK((*filter->output_function)(((c >> 24) & 0x3f) | 0x80, filter->data)); - CK((*filter->output_function)(((c >> 18) & 0x3f) | 0x80, filter->data)); + CK((*filter->output_function)(((c >> 18) & 0x07) | 0xf0, filter->data)); CK((*filter->output_function)(((c >> 12) & 0x3f) | 0x80, filter->data)); CK((*filter->output_function)(((c >> 6) & 0x3f) | 0x80, filter->data)); CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); @@ -229,20 +193,11 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) case 0x20: /* 3 byte code 2nd char */ case 0x30: /* 4 byte code 2nd char */ case 0x31: /* 4 byte code 3rd char */ - case 0x40: /* 5 byte code 2nd char */ - case 0x41: /* 5 byte code 3rd char */ - case 0x42: /* 5 byte code 4th char */ - case 0x50: /* 6 byte code 2nd char */ - case 0x51: /* 6 byte code 3rd char */ - case 0x52: /* 6 byte code 4th char */ - case 0x53: /* 6 byte code 5th char */ filter->status++; break; case 0x10: /* 2 byte code 2nd char */ case 0x21: /* 3 byte code 3rd char */ case 0x32: /* 4 byte code 4th char */ - case 0x43: /* 5 byte code 5th char */ - case 0x54: /* 6 byte code 6th char */ filter->status = 0; break; default: @@ -261,10 +216,6 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) filter->status = 0x20; } else if (c < 0xf8) { /* 4 byte code 1st char */ filter->status = 0x30; - } else if (c < 0xfc) { /* 5 byte code 1st char */ - filter->status = 0x40; - } else if (c < 0xfe) { /* 6 byte code 1st char */ - filter->status = 0x50; } else { filter->flag = 1; /* bad */ } From 5bd3e8324d8606fa9a0fbd63ae9e2302a48a961a Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Fri, 5 Aug 2011 04:28:24 +0000 Subject: [PATCH 0454/2394] added check for invalid utf-8 encoding (merge from libmbfl-1.3.1). --- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 93 +++++++++++++++++--- 1 file changed, 79 insertions(+), 14 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index 0e788f389c904..6e81fbc1c4069 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -98,7 +98,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_utf8 = { */ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) { - int s; + int s, c1, w = 0; if (c < 0x80) { if (c >= 0) { @@ -108,40 +108,79 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) } else if (c < 0xc0) { int status = filter->status & 0xff; switch (status) { - case 0x10: /* 2byte code 2nd char */ - case 0x21: /* 3byte code 3rd char */ - case 0x32: /* 4byte code 4th char */ + case 0x10: /* 2byte code 2nd char: 0x80-0xbf */ + case 0x21: /* 3byte code 3rd char: 0x80-0xbf */ + case 0x32: /* 4byte code 4th char: 0x80-0xbf */ filter->status = 0; s = filter->cache | (c & 0x3f); + filter->cache = 0; if ((status == 0x10 && s >= 0x80) || (status == 0x21 && s >= 0x800 && (s < 0xd800 || s > 0xdfff)) || (status == 0x32 && s >= 0x10000 && s < 0x200000)) { CK((*filter->output_function)(s, filter->data)); + } else { + w = s & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); } break; - case 0x20: /* 3byte code 2nd char */ - case 0x31: /* 4byte code 3rd char */ + case 0x20: /* 3byte code 2nd char: 0:0xa0-0xbf,1-F:0x80-0x9f */ + s = filter->cache | ((c & 0x3f) << 6); + c1 = (s >> 12) & 0xf; + if ((c1 == 0x0 && c >= 0xa0) || c1 > 0) { + filter->cache = s; + filter->status++; + } else { + w = s & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + filter->status = 0; + filter->cache = 0; + } + break; + case 0x31: /* 4byte code 3rd char: 0x80-0xbf */ filter->cache |= ((c & 0x3f) << 6); filter->status++; break; - case 0x30: /* 4byte code 2nd char */ - filter->cache |= ((c & 0x3f) << 12); - filter->status++; + case 0x30: /* 4byte code 2nd char: 0:0x90-0xbf,1-3:0x80-0xbf,4:0x80-0x8f */ + s = filter->cache | ((c & 0x3f) << 12); + c1 = (s >> 18) & 0x7; + if ((c1 == 0x0 && c >= 0x90) || + (c1 > 0x0 && c1 < 0x4) || + (c1 == 0x4 && c < 0x90)) { + filter->cache = s; + filter->status++; + } else { + w = s & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + filter->status = 0; + filter->cache = 0; + } break; default: filter->status = 0; break; } - } else if (c < 0xe0) { /* 2byte code first char */ + } else if (c < 0xc2) { /* invalid: 0xc0,0xc1 */ + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + filter->status = 0; + filter->cache = 0; + } else if (c < 0xe0) { /* 2byte code first char: 0xc2-0xdf */ filter->status = 0x10; filter->cache = (c & 0x1f) << 6; - } else if (c < 0xf0) { /* 3byte code first char */ + } else if (c < 0xf0) { /* 3byte code first char: 0xe0-0xef */ filter->status = 0x20; filter->cache = (c & 0xf) << 12; - } else if (c < 0xf8) { /* 4byte code first char */ + } else if (c < 0xf5) { /* 4byte code first char: 0xf0-0xf4 */ filter->status = 0x30; filter->cache = (c & 0x7) << 18; } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); filter->status = 0; filter->cache = 0; } @@ -154,7 +193,7 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) */ int mbfl_filt_conv_wchar_utf8(int c, mbfl_convert_filter *filter) { - if (c >= 0 && c < 0x200000) { + if (c >= 0 && c < 0x110000) { if (c < 0x80) { CK((*filter->output_function)(c, filter->data)); } else if (c < 0x800) { @@ -181,6 +220,11 @@ int mbfl_filt_conv_wchar_utf8(int c, mbfl_convert_filter *filter) static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) { + int c1; + + c1 = (filter->status >> 8) & 0xff; + filter->status &= 0xff; + if (c < 0x80) { if (c < 0) { filter->flag = 1; /* bad */ @@ -191,7 +235,23 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) } else if (c < 0xc0) { switch (filter->status) { case 0x20: /* 3 byte code 2nd char */ + if ((c1 == 0x0 && c >= 0xa0) || c1 > 0x0) { + filter->status++; + } else { + filter->flag = 1; /* bad */ + filter->status = 0; + } + break; case 0x30: /* 4 byte code 2nd char */ + if ((c1 == 0x0 && c >= 0x90) || + (c1 > 0x0 && c1 < 0x4) || + (c1 == 0x4 && c < 0x90)) { + filter->status++; + } else { + filter->flag = 1; /* bad */ + filter->status = 0; + } + break; case 0x31: /* 4 byte code 3rd char */ filter->status++; break; @@ -205,6 +265,9 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) filter->status = 0; break; } + } else if (c < 0xc2) { /* 0xc0,0xc1 */ + filter->flag = 1; /* bad */ + filter->status = 0; } else { if (filter->status) { filter->flag = 1; /* bad */ @@ -214,8 +277,10 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) filter->status = 0x10; } else if (c < 0xf0) { /* 3 byte code 1st char */ filter->status = 0x20; - } else if (c < 0xf8) { /* 4 byte code 1st char */ + filter->status |= (c & 0xf) << 8; + } else if (c < 0xf5) { /* 4 byte code 1st char */ filter->status = 0x30; + filter->status |= (c & 0x7) << 8; } else { filter->flag = 1; /* bad */ } From 5f1107144a4c5e4938defabce886bcab8b70d9b3 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 5 Aug 2011 13:39:30 +0000 Subject: [PATCH 0455/2394] Fix for bug #55283 SSL options set by mysqli_ssl_set ignored for MySQLi persistent connections --- ext/mysqli/mysqli_nonapi.c | 10 ++++--- ext/mysqli/tests/bug55283.phpt | 55 ++++++++++++++++++++++++++++++++++ 2 files changed, 61 insertions(+), 4 deletions(-) create mode 100644 ext/mysqli/tests/bug55283.phpt diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index 8dbaed2bffefd..2844c4df1b0c9 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -141,10 +141,12 @@ void mysqli_common_connect(INTERNAL_FUNCTION_PARAMETERS, zend_bool is_real_conne hostname = MyG(default_host); } - if (mysql->mysql && mysqli_resource && (mysqli_resource->status > MYSQLI_STATUS_INITIALIZED || (strlen(SAFE_STR(hostname)) > 2 && !strncasecmp(hostname, "p:", 2)))) { - /* already connected, we should close the connection */ - php_mysqli_close(mysql, MYSQLI_CLOSE_IMPLICIT, mysqli_resource->status TSRMLS_CC); - } + if (mysql->mysql && mysqli_resource && + (mysqli_resource->status > MYSQLI_STATUS_INITIALIZED)) + { + /* already connected, we should close the connection */ + php_mysqli_close(mysql, MYSQLI_CLOSE_IMPLICIT, mysqli_resource->status TSRMLS_CC); + } if (strlen(SAFE_STR(hostname)) > 2 && !strncasecmp(hostname, "p:", 2)) { hostname += 2; diff --git a/ext/mysqli/tests/bug55283.phpt b/ext/mysqli/tests/bug55283.phpt new file mode 100644 index 0000000000000..0611c773cf21b --- /dev/null +++ b/ext/mysqli/tests/bug55283.phpt @@ -0,0 +1,55 @@ +--TEST-- +Bug #55283 (SSL options set by mysqli_ssl_set ignored for MySQLi persistent connections) +--SKIPIF-- +query("SHOW STATUS LIKE 'Ssl_cipher'"); + $row = $res->fetch_row(); + if ($row[1] === "") { + die('skip Server started without SSL support'); + } +} +?> +--FILE-- +query("SHOW STATUS LIKE 'Ssl_cipher'"); + var_dump($r->fetch_row()); + } + + /* non-persistent connection */ + $link2 = mysqli_init(); + mysqli_ssl_set($link2, null, null, null, null, "RC4-MD5"); + if (my_mysqli_real_connect($link2, $host, $user, $passwd, $db, $port, null, $flags)) { + $r2 = $link2->query("SHOW STATUS LIKE 'Ssl_cipher'"); + var_dump($r2->fetch_row()); + } + + echo "done\n"; +?> +--EXPECTF-- +array(2) { + [0]=> + string(10) "Ssl_cipher" + [1]=> + string(7) "RC4-MD5" +} +array(2) { + [0]=> + string(10) "Ssl_cipher" + [1]=> + string(7) "RC4-MD5" +} +done \ No newline at end of file From 1ac9192d468ad91829a409e1b7d17a9cad84c298 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Fri, 5 Aug 2011 22:18:42 +0000 Subject: [PATCH 0456/2394] Fix missing va_end() found by Coverity --- Zend/zend_hash.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index 3585dbee058c2..4286ce9dc8765 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -777,6 +777,7 @@ ZEND_API void zend_hash_apply_with_arguments(HashTable *ht TSRMLS_DC, apply_func p = p->pListNext; } if (result & ZEND_HASH_APPLY_STOP) { + va_end(args); break; } va_end(args); From 68f785ac70dae03fdfa72f67939eb375df44326f Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Fri, 5 Aug 2011 22:18:50 +0000 Subject: [PATCH 0457/2394] Improve test portabilty --- ext/oci8/tests/bug37220.phpt | 2 +- ext/oci8/tests/xmltype_02.phpt | 22 +++++++++++----------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/ext/oci8/tests/bug37220.phpt b/ext/oci8/tests/bug37220.phpt index 8d59644b8eada..fd91dc73d6207 100644 --- a/ext/oci8/tests/bug37220.phpt +++ b/ext/oci8/tests/bug37220.phpt @@ -43,7 +43,7 @@ oci_execute($stmt); while ($row = oci_fetch_array($stmt, OCI_ASSOC+OCI_RETURN_NULLS)) { foreach ($row as $item) { - echo $item."\n"; + echo trim($item)."\n"; } echo "\n"; } diff --git a/ext/oci8/tests/xmltype_02.phpt b/ext/oci8/tests/xmltype_02.phpt index 5ac294102e962..28e9401baf485 100644 --- a/ext/oci8/tests/xmltype_02.phpt +++ b/ext/oci8/tests/xmltype_02.phpt @@ -164,18 +164,18 @@ object(SimpleXMLElement)#%d (10) { string(2) "10" } Test 3: Update changes using a temporary CLOB -string(331) " +string(%d) " -1 -Southlake, Texas -Owned -25000 -1 -Rear load -true -N -Street -10 +%sWarehouseId>1 +%sWarehouseName>Southlake, Texas +%sBuilding>Owned +%sArea>25000 +%sDocks>1 +%sDockType>Rear load +%sWaterAccess>true +%sRailAccess>N +%sParking>Street +%sVClearance>10 " ===DONE=== \ No newline at end of file From dc1e148165c81e6e638fd592e3e8afc6fb1f154a Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Fri, 5 Aug 2011 22:26:16 +0000 Subject: [PATCH 0458/2394] Another potential missing va_end() found by Coverity --- Zend/zend_API.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 9e4385f079b1f..fa9d8a0686481 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -959,6 +959,7 @@ ZEND_API int zend_parse_method_parameters_ex(int flags, int num_args TSRMLS_DC, zend_error(E_CORE_ERROR, "%s::%s() must be derived from %s::%s", ce->name, get_active_function_name(TSRMLS_C), Z_OBJCE_P(this_ptr)->name, get_active_function_name(TSRMLS_C)); } + va_end(va); return FAILURE; } From c9342c81d68543d3d4ae6bb3c60d7e3cba267559 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Fri, 5 Aug 2011 22:39:40 +0000 Subject: [PATCH 0459/2394] efree match_sets on an error here - found by Coverity --- ext/pcre/php_pcre.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index 27bea79922ac5..41fdb32a7b4d3 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -644,6 +644,7 @@ PHPAPI void php_pcre_match_impl(pcre_cache_entry *pce, char *subject, int subjec if (pcre_get_substring_list(subject, offsets, count, &stringlist) < 0) { efree(subpat_names); efree(offsets); + if (match_sets) efree(match_sets); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Get subpatterns list failed"); RETURN_FALSE; } From 65e381ba1dce9ab00a2396775c2f3b69729ab02b Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 6 Aug 2011 00:59:21 +0000 Subject: [PATCH 0460/2394] - Fixed bug #55313 (Number of retries not set when params specified) patch by: kevin at kevinlocke dot name --- ext/imap/php_imap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index 9c0ed32dd91e3..a0b52ed243db8 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -1227,7 +1227,7 @@ static void php_imap_do_open(INTERNAL_FUNCTION_PARAMETERS, int persistent) IMAPG(imap_password) = estrndup(passwd, passwd_len); #ifdef SET_MAXLOGINTRIALS - if (argc == 5) { + if (argc >= 5) { if (retries < 0) { php_error_docref(NULL TSRMLS_CC, E_WARNING ,"Retries must be greater or equal to 0"); } else { From 9c289189d3d17a47051cea8018452c9ba02759de Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 6 Aug 2011 01:22:27 +0000 Subject: [PATCH 0461/2394] - Added missing PHP_FE_END/ZEND_FE_END --- Zend/zend_API.c | 4 ++-- ext/intl/collator/collator_class.c | 2 +- ext/intl/dateformat/dateformat_class.c | 2 +- ext/intl/formatter/formatter_class.c | 2 +- ext/intl/locale/locale_class.c | 2 +- ext/intl/msgformat/msgformat_class.c | 2 +- ext/intl/normalizer/normalizer_class.c | 2 +- ext/intl/resourcebundle/resourcebundle_class.c | 2 +- ext/intl/spoofchecker/spoofchecker_class.c | 2 +- ext/intl/transliterator/transliterator_class.c | 2 +- ext/json/json.c | 2 +- ext/standard/user_filters.c | 2 +- sapi/apache_hooks/php_apache.c | 2 +- sapi/milter/php_milter.c | 2 +- 14 files changed, 15 insertions(+), 15 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index fa9d8a0686481..fb49767e03d8d 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -2505,7 +2505,7 @@ ZEND_API ZEND_FUNCTION(display_disabled_function) static zend_function_entry disabled_function[] = { ZEND_FE(display_disabled_function, NULL) - { NULL, NULL, NULL } + ZEND_FE_END }; ZEND_API int zend_disable_function(char *function_name, uint function_name_length TSRMLS_DC) /* {{{ */ @@ -2529,7 +2529,7 @@ static zend_object_value display_disabled_class(zend_class_entry *class_type TSR /* }}} */ static const zend_function_entry disabled_class_new[] = { - { NULL, NULL, NULL } + ZEND_FE_END }; ZEND_API int zend_disable_class(char *class_name, uint class_name_length TSRMLS_DC) /* {{{ */ diff --git a/ext/intl/collator/collator_class.c b/ext/intl/collator/collator_class.c index 4f11aff86f93e..de744dcefeccd 100755 --- a/ext/intl/collator/collator_class.c +++ b/ext/intl/collator/collator_class.c @@ -127,7 +127,7 @@ zend_function_entry Collator_class_functions[] = { PHP_NAMED_FE( getErrorCode, ZEND_FN( collator_get_error_code ), collator_0_args ) PHP_NAMED_FE( getErrorMessage, ZEND_FN( collator_get_error_message ), collator_0_args ) PHP_NAMED_FE( getSortKey, ZEND_FN( collator_get_sort_key ), collator_2_args ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/dateformat/dateformat_class.c b/ext/intl/dateformat/dateformat_class.c index 674e219d0bbd6..c66610f23b982 100755 --- a/ext/intl/dateformat/dateformat_class.c +++ b/ext/intl/dateformat/dateformat_class.c @@ -170,7 +170,7 @@ static zend_function_entry IntlDateFormatter_class_functions[] = { PHP_NAMED_FE( localtime, ZEND_FN( datefmt_localtime ), datefmt_parse_args ) PHP_NAMED_FE( getErrorCode, ZEND_FN( datefmt_get_error_code ), arginfo_intldateformatter_getdatetype ) PHP_NAMED_FE( getErrorMessage, ZEND_FN( datefmt_get_error_message ), arginfo_intldateformatter_getdatetype ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/formatter/formatter_class.c b/ext/intl/formatter/formatter_class.c index 54410332554f0..8fcda643bf5c1 100755 --- a/ext/intl/formatter/formatter_class.c +++ b/ext/intl/formatter/formatter_class.c @@ -179,7 +179,7 @@ static zend_function_entry NumberFormatter_class_functions[] = { PHP_NAMED_FE( getLocale, ZEND_FN( numfmt_get_locale ), arginfo_numberformatter_getlocale ) PHP_NAMED_FE( getErrorCode, ZEND_FN( numfmt_get_error_code ), arginfo_numberformatter_getpattern ) PHP_NAMED_FE( getErrorMessage, ZEND_FN( numfmt_get_error_message ), arginfo_numberformatter_getpattern ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/locale/locale_class.c b/ext/intl/locale/locale_class.c index bba6449ac73fd..432cfb28fce25 100755 --- a/ext/intl/locale/locale_class.c +++ b/ext/intl/locale/locale_class.c @@ -85,7 +85,7 @@ zend_function_entry Locale_class_functions[] = { ZEND_FENTRY( lookup, ZEND_FN( locale_lookup ), locale_4_args, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC ) ZEND_FENTRY( canonicalize, ZEND_FN( locale_canonicalize ), locale_1_arg , ZEND_ACC_PUBLIC|ZEND_ACC_STATIC ) ZEND_FENTRY( acceptFromHttp, ZEND_FN( locale_accept_from_http ), locale_1_arg , ZEND_ACC_PUBLIC|ZEND_ACC_STATIC ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/msgformat/msgformat_class.c b/ext/intl/msgformat/msgformat_class.c index 59e222a4fc2fa..d0138854eb085 100755 --- a/ext/intl/msgformat/msgformat_class.c +++ b/ext/intl/msgformat/msgformat_class.c @@ -144,7 +144,7 @@ static zend_function_entry MessageFormatter_class_functions[] = { PHP_NAMED_FE( getLocale, ZEND_FN( msgfmt_get_locale ), arginfo_messageformatter_geterrormessage ) PHP_NAMED_FE( getErrorCode, ZEND_FN( msgfmt_get_error_code ), arginfo_messageformatter_geterrormessage ) PHP_NAMED_FE( getErrorMessage, ZEND_FN( msgfmt_get_error_message ), arginfo_messageformatter_geterrormessage ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/normalizer/normalizer_class.c b/ext/intl/normalizer/normalizer_class.c index 736f7ecbf4a20..154d877e3f597 100755 --- a/ext/intl/normalizer/normalizer_class.c +++ b/ext/intl/normalizer/normalizer_class.c @@ -44,7 +44,7 @@ ZEND_END_ARG_INFO() zend_function_entry Normalizer_class_functions[] = { ZEND_FENTRY( normalize, ZEND_FN( normalizer_normalize ), normalizer_3_args, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC ) ZEND_FENTRY( isNormalized, ZEND_FN( normalizer_is_normalized ), normalizer_3_args, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/resourcebundle/resourcebundle_class.c b/ext/intl/resourcebundle/resourcebundle_class.c index 5d925ae6bf37f..5471e5b3f6a41 100644 --- a/ext/intl/resourcebundle/resourcebundle_class.c +++ b/ext/intl/resourcebundle/resourcebundle_class.c @@ -399,7 +399,7 @@ static zend_function_entry ResourceBundle_class_functions[] = { ZEND_NAMED_ME( getLocales, ZEND_FN(resourcebundle_locales), arginfo_resourcebundle_getlocales, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC ) ZEND_NAMED_ME( getErrorCode, ZEND_FN(resourcebundle_get_error_code), arginfo_resourcebundle_get_error_code, ZEND_ACC_PUBLIC ) ZEND_NAMED_ME( getErrorMessage, ZEND_FN(resourcebundle_get_error_message), arginfo_resourcebundle_get_error_message, ZEND_ACC_PUBLIC ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/spoofchecker/spoofchecker_class.c b/ext/intl/spoofchecker/spoofchecker_class.c index 3f00cdf15fe9d..6c19fbb0f65e5 100755 --- a/ext/intl/spoofchecker/spoofchecker_class.c +++ b/ext/intl/spoofchecker/spoofchecker_class.c @@ -113,7 +113,7 @@ zend_function_entry Spoofchecker_class_functions[] = { PHP_ME(Spoofchecker, areConfusable, spoofchecker_are_confusable, ZEND_ACC_PUBLIC) PHP_ME(Spoofchecker, setAllowedLocales, spoofchecker_set_allowed_locales, ZEND_ACC_PUBLIC) PHP_ME(Spoofchecker, setChecks, spoofchecker_set_checks, ZEND_ACC_PUBLIC) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/intl/transliterator/transliterator_class.c b/ext/intl/transliterator/transliterator_class.c index 727cf1e4851af..8d4d0649e97e5 100644 --- a/ext/intl/transliterator/transliterator_class.c +++ b/ext/intl/transliterator/transliterator_class.c @@ -386,7 +386,7 @@ zend_function_entry Transliterator_class_functions[] = { PHP_ME_MAPPING( transliterate, transliterator_transliterate, ainfo_trans_me_transliterate, ZEND_ACC_PUBLIC ) PHP_ME_MAPPING( getErrorCode, transliterator_get_error_code, ainfo_trans_void, ZEND_ACC_PUBLIC ) PHP_ME_MAPPING( getErrorMessage,transliterator_get_error_message, ainfo_trans_void, ZEND_ACC_PUBLIC ) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/json/json.c b/ext/json/json.c index fd8af799c80cd..39e3d4d7c98f3 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -75,7 +75,7 @@ ZEND_END_ARG_INFO(); static const zend_function_entry json_serializable_interface[] = { PHP_ABSTRACT_ME(JsonSerializable, jsonSerialize, json_serialize_arginfo) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/ext/standard/user_filters.c b/ext/standard/user_filters.c index 0050cb35eb4ef..752c52af8347c 100644 --- a/ext/standard/user_filters.c +++ b/ext/standard/user_filters.c @@ -71,7 +71,7 @@ static const zend_function_entry user_filter_class_funcs[] = { PHP_NAMED_FE(filter, PHP_FN(user_filter_nop), arginfo_php_user_filter_filter) PHP_NAMED_FE(onCreate, PHP_FN(user_filter_nop), arginfo_php_user_filter_onCreate) PHP_NAMED_FE(onClose, PHP_FN(user_filter_nop), arginfo_php_user_filter_onClose) - { NULL, NULL, NULL } + PHP_FE_END }; static zend_class_entry user_filter_class_entry; diff --git a/sapi/apache_hooks/php_apache.c b/sapi/apache_hooks/php_apache.c index 319979e7a2ef8..0c4e99303a6bc 100644 --- a/sapi/apache_hooks/php_apache.c +++ b/sapi/apache_hooks/php_apache.c @@ -1384,7 +1384,7 @@ const static zend_function_entry php_apache_request_class_functions[] = { PHP_FALIAS(method_uri, apache_request_sub_req_method_uri, NULL) PHP_FALIAS(run, apache_request_run, NULL) PHP_FALIAS(internal_redirect, apache_request_internal_redirect, NULL) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ diff --git a/sapi/milter/php_milter.c b/sapi/milter/php_milter.c index 0ea2bd7e7d39c..4161447733d1c 100644 --- a/sapi/milter/php_milter.c +++ b/sapi/milter/php_milter.c @@ -833,7 +833,7 @@ const static zend_function_entry milter_functions[] = { PHP_FE(smfi_addrcpt, arginfo_smfi_addrcpt) PHP_FE(smfi_delrcpt, arginfo_smfi_delrcpt) PHP_FE(smfi_replacebody, arginfo_smfi_replacebody) - { NULL, NULL, NULL } + PHP_FE_END }; /* }}} */ From 2bc6bcb96ed608921629af9420dfe12c97b08aa8 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 6 Aug 2011 01:48:45 +0000 Subject: [PATCH 0462/2394] updated libmbfl version to 1.3.1. --- ext/mbstring/libmbfl/mbfl/mbfilter.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/libmbfl/mbfl/mbfilter.h b/ext/mbstring/libmbfl/mbfl/mbfilter.h index 4db78d01f53de..496d1b12cac4f 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfilter.h +++ b/ext/mbstring/libmbfl/mbfl/mbfilter.h @@ -103,7 +103,7 @@ */ #define MBFL_VERSION_MAJOR 1 #define MBFL_VERSION_MINOR 3 -#define MBFL_VERSION_TEENY 0 +#define MBFL_VERSION_TEENY 1 /* * convert filter From b3414d3c025b39af866383b6206ac854aa3ac5e1 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 6 Aug 2011 02:22:15 +0000 Subject: [PATCH 0463/2394] added ill-formed utf-8 check for 0xEDXXXX. --- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index 6e81fbc1c4069..94aaadd8aac74 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -124,10 +124,12 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(w, filter->data)); } break; - case 0x20: /* 3byte code 2nd char: 0:0xa0-0xbf,1-F:0x80-0x9f */ + case 0x20: /* 3byte code 2nd char: 0:0xa0-0xbf,D:0x80-9F,1-C,E-F:0x80-0x9f */ s = filter->cache | ((c & 0x3f) << 6); c1 = (s >> 12) & 0xf; - if ((c1 == 0x0 && c >= 0xa0) || c1 > 0) { + if ((c1 == 0x0 && c >= 0xa0) || + (c1 == 0xd && c < 0xa0) || + (c1 > 0x0 && c1 != 0xd)) { filter->cache = s; filter->status++; } else { @@ -235,7 +237,9 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) } else if (c < 0xc0) { switch (filter->status) { case 0x20: /* 3 byte code 2nd char */ - if ((c1 == 0x0 && c >= 0xa0) || c1 > 0x0) { + if ((c1 == 0x0 && c >= 0xa0) || + (c1 == 0xd && c < 0xa0) || + (c1 > 0x0 && c1 != 0xd)) { filter->status++; } else { filter->flag = 1; /* bad */ From 70eb1c1267418756b5077357763c762317f4e0e1 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 6 Aug 2011 04:25:44 +0000 Subject: [PATCH 0464/2394] improved error handling for ill-formed utf-8 based on the Unicode recommendation. --- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 54 ++++++++++++-------- 1 file changed, 32 insertions(+), 22 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index 94aaadd8aac74..df8872ad6d913 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -98,7 +98,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_utf8 = { */ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) { - int s, c1, w = 0; + int s, c1, w = 0, flag = 0; if (c < 0x80) { if (c >= 0) { @@ -120,8 +120,7 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(s, filter->data)); } else { w = s & MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; - CK((*filter->output_function)(w, filter->data)); + flag = 1; } break; case 0x20: /* 3byte code 2nd char: 0:0xa0-0xbf,D:0x80-9F,1-C,E-F:0x80-0x9f */ @@ -134,10 +133,7 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) filter->status++; } else { w = s & MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; - CK((*filter->output_function)(w, filter->data)); - filter->status = 0; - filter->cache = 0; + flag = 1; } break; case 0x31: /* 4byte code 3rd char: 0x80-0xbf */ @@ -154,33 +150,47 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) filter->status++; } else { w = s & MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; - CK((*filter->output_function)(w, filter->data)); - filter->status = 0; - filter->cache = 0; + flag = 1; } break; default: - filter->status = 0; + w = c & MBFL_WCSGROUP_MASK; + flag = 1; break; } } else if (c < 0xc2) { /* invalid: 0xc0,0xc1 */ w = c & MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; - CK((*filter->output_function)(w, filter->data)); - filter->status = 0; - filter->cache = 0; + flag = 1; } else if (c < 0xe0) { /* 2byte code first char: 0xc2-0xdf */ - filter->status = 0x10; - filter->cache = (c & 0x1f) << 6; + if (filter->status == 0x0) { + filter->status = 0x10; + filter->cache = (c & 0x1f) << 6; + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } } else if (c < 0xf0) { /* 3byte code first char: 0xe0-0xef */ - filter->status = 0x20; - filter->cache = (c & 0xf) << 12; + if (filter->status == 0x0) { + filter->status = 0x20; + filter->cache = (c & 0xf) << 12; + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } } else if (c < 0xf5) { /* 4byte code first char: 0xf0-0xf4 */ - filter->status = 0x30; - filter->cache = (c & 0x7) << 18; + if (filter->status == 0x0) { + filter->status = 0x30; + filter->cache = (c & 0x7) << 18; + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } } else { w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } + + if (flag) { w |= MBFL_WCSGROUP_THROUGH; CK((*filter->output_function)(w, filter->data)); filter->status = 0; From fc3e0ff1ec40d49dd5f9d5da78f3a9a8d16635b1 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 6 Aug 2011 12:19:16 +0000 Subject: [PATCH 0465/2394] fixed encoding conversion when http_input=auto. --- ext/mbstring/mb_gpc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mbstring/mb_gpc.c b/ext/mbstring/mb_gpc.c index 041227d15dbaf..985a604ebbabd 100644 --- a/ext/mbstring/mb_gpc.c +++ b/ext/mbstring/mb_gpc.c @@ -264,8 +264,8 @@ const mbfl_encoding *_php_mb_encoding_handler_ex(const php_mb_encoding_handler_i } else { /* auto detect */ from_encoding = NULL; - identd = mbfl_encoding_detector_new((enum mbfl_no_encoding *)info->from_encodings, info->num_from_encodings, MBSTRG(strict_detection)); - if (identd) { + identd = mbfl_encoding_detector_new2(info->from_encodings, info->num_from_encodings, MBSTRG(strict_detection)); + if (identd != NULL) { n = 0; while (n < num) { string.val = (unsigned char *)val_list[n]; From 9480eace41dae14a956e8853ca19400701945543 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 6 Aug 2011 14:47:44 +0000 Subject: [PATCH 0466/2394] - Added ZEND_MOD_END macro to use in the end of zend_module_dep[] --- Zend/zend_modules.h | 2 ++ ext/dom/php_dom.c | 2 +- ext/exif/exif.c | 2 +- ext/imap/php_imap.c | 2 +- ext/mysql/php_mysql.c | 2 +- ext/mysqli/mysqli.c | 2 +- ext/mysqlnd/php_mysqlnd.c | 2 +- ext/pdo/pdo.c | 2 +- ext/pdo_dblib/pdo_dblib.c | 2 +- ext/pdo_firebird/pdo_firebird.c | 2 +- ext/pdo_mysql/pdo_mysql.c | 2 +- ext/pdo_oci/pdo_oci.c | 2 +- ext/pdo_odbc/pdo_odbc.c | 2 +- ext/pdo_pgsql/pdo_pgsql.c | 2 +- ext/pdo_sqlite/pdo_sqlite.c | 2 +- ext/phar/phar.c | 2 +- ext/session/session.c | 2 +- ext/simplexml/simplexml.c | 2 +- ext/standard/basic_functions.c | 2 +- ext/xml/xml.c | 2 +- ext/xmlreader/php_xmlreader.c | 2 +- ext/xsl/php_xsl.c | 2 +- 22 files changed, 23 insertions(+), 21 deletions(-) diff --git a/Zend/zend_modules.h b/Zend/zend_modules.h index e27677b7ef827..1a2051cf69597 100644 --- a/Zend/zend_modules.h +++ b/Zend/zend_modules.h @@ -113,6 +113,8 @@ struct _zend_module_entry { #define ZEND_MOD_CONFLICTS(name) ZEND_MOD_CONFLICTS_EX(name, NULL, NULL) #define ZEND_MOD_OPTIONAL(name) ZEND_MOD_OPTIONAL_EX(name, NULL, NULL) +#define ZEND_MOD_END { NULL, NULL, NULL, 0 } + struct _zend_module_dep { const char *name; /* module name */ const char *rel; /* version relationship: NULL (exists), lt|le|eq|ge|gt (to given version) */ diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c index d92e9449de868..afbf1b9062b99 100644 --- a/ext/dom/php_dom.c +++ b/ext/dom/php_dom.c @@ -553,7 +553,7 @@ static zend_object_handlers* dom_get_obj_handlers(TSRMLS_D) { static const zend_module_dep dom_deps[] = { ZEND_MOD_REQUIRED("libxml") ZEND_MOD_CONFLICTS("domxml") - {NULL, NULL, NULL} + ZEND_MOD_END }; zend_module_entry dom_module_entry = { /* {{{ */ diff --git a/ext/exif/exif.c b/ext/exif/exif.c index d7d19eff8eb7c..7d7a2a4645dec 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -254,7 +254,7 @@ PHP_MSHUTDOWN_FUNCTION(exif) static const zend_module_dep exif_module_deps[] = { ZEND_MOD_REQUIRED("standard") ZEND_MOD_OPTIONAL("mbstring") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* }}} */ diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index a0b52ed243db8..90e330d9ac80e 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -558,7 +558,7 @@ const zend_function_entry imap_functions[] = { /* {{{ imap dependencies */ static const zend_module_dep imap_deps[] = { ZEND_MOD_REQUIRED("standard") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* }}} */ diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index f6fd05eb91cee..8a0d5434cfbbd 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -329,7 +329,7 @@ static const zend_module_dep mysql_deps[] = { #if defined(MYSQL_USE_MYSQLND) ZEND_MOD_REQUIRED("mysqlnd") #endif - {NULL, NULL, NULL} + ZEND_MOD_END }; /* {{{ mysql_module_entry diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index fc35c8302e943..4ba13f5116639 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -941,7 +941,7 @@ static const zend_module_dep mysqli_deps[] = { #if defined(MYSQLI_USE_MYSQLND) ZEND_MOD_REQUIRED("mysqlnd") #endif - {NULL, NULL, NULL} + ZEND_MOD_END }; /* {{{ mysqli_module_entry diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index 1c744cea68317..5682bdeef86b3 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -312,7 +312,7 @@ static PHP_RSHUTDOWN_FUNCTION(mysqlnd) static const zend_module_dep mysqlnd_deps[] = { ZEND_MOD_REQUIRED("standard") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* {{{ mysqlnd_module_entry diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c index 1604d51858fa4..169ce32e25fe9 100755 --- a/ext/pdo/pdo.c +++ b/ext/pdo/pdo.c @@ -135,7 +135,7 @@ static const zend_module_dep pdo_deps[] = { #ifdef HAVE_SPL ZEND_MOD_REQUIRED("spl") #endif - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif /* }}} */ diff --git a/ext/pdo_dblib/pdo_dblib.c b/ext/pdo_dblib/pdo_dblib.c index 278c1985a1c01..17bc8f86aa45e 100644 --- a/ext/pdo_dblib/pdo_dblib.c +++ b/ext/pdo_dblib/pdo_dblib.c @@ -42,7 +42,7 @@ const zend_function_entry pdo_dblib_functions[] = { #if ZEND_MODULE_API_NO >= 20050922 static const zend_module_dep pdo_dblib_deps[] = { ZEND_MOD_REQUIRED("pdo") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif diff --git a/ext/pdo_firebird/pdo_firebird.c b/ext/pdo_firebird/pdo_firebird.c index 6459c70364d0d..4f04f939fc264 100644 --- a/ext/pdo_firebird/pdo_firebird.c +++ b/ext/pdo_firebird/pdo_firebird.c @@ -40,7 +40,7 @@ const zend_function_entry pdo_firebird_functions[] = { /* {{{ */ #if ZEND_MODULE_API_NO >= 20050922 static const zend_module_dep pdo_firebird_deps[] = { ZEND_MOD_REQUIRED("pdo") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif /* }}} */ diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index 5fdab6ba942b7..97cce4a1de05d 100755 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -181,7 +181,7 @@ static const zend_module_dep pdo_mysql_deps[] = { #ifdef PDO_USE_MYSQLND ZEND_MOD_REQUIRED("mysqlnd") #endif - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif /* }}} */ diff --git a/ext/pdo_oci/pdo_oci.c b/ext/pdo_oci/pdo_oci.c index 78539761b7018..9182cf3bf4226 100755 --- a/ext/pdo_oci/pdo_oci.c +++ b/ext/pdo_oci/pdo_oci.c @@ -41,7 +41,7 @@ const zend_function_entry pdo_oci_functions[] = { #if ZEND_MODULE_API_NO >= 20050922 static const zend_module_dep pdo_oci_deps[] = { ZEND_MOD_REQUIRED("pdo") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif diff --git a/ext/pdo_odbc/pdo_odbc.c b/ext/pdo_odbc/pdo_odbc.c index bc71aada53c9a..7a021e61a716c 100755 --- a/ext/pdo_odbc/pdo_odbc.c +++ b/ext/pdo_odbc/pdo_odbc.c @@ -40,7 +40,7 @@ const zend_function_entry pdo_odbc_functions[] = { #if ZEND_MODULE_API_NO >= 20050922 static const zend_module_dep pdo_odbc_deps[] = { ZEND_MOD_REQUIRED("pdo") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif /* }}} */ diff --git a/ext/pdo_pgsql/pdo_pgsql.c b/ext/pdo_pgsql/pdo_pgsql.c index 805d752afc517..b30a7a4f47c8c 100644 --- a/ext/pdo_pgsql/pdo_pgsql.c +++ b/ext/pdo_pgsql/pdo_pgsql.c @@ -50,7 +50,7 @@ const zend_function_entry pdo_pgsql_functions[] = { #if ZEND_MODULE_API_NO >= 20050922 static const zend_module_dep pdo_pgsql_deps[] = { ZEND_MOD_REQUIRED("pdo") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif /* }}} */ diff --git a/ext/pdo_sqlite/pdo_sqlite.c b/ext/pdo_sqlite/pdo_sqlite.c index c9a514a41bd84..ab3ec3f6cd902 100644 --- a/ext/pdo_sqlite/pdo_sqlite.c +++ b/ext/pdo_sqlite/pdo_sqlite.c @@ -44,7 +44,7 @@ const zend_function_entry pdo_sqlite_functions[] = { #if ZEND_MODULE_API_NO >= 20050922 static const zend_module_dep pdo_sqlite_deps[] = { ZEND_MOD_REQUIRED("pdo") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif /* }}} */ diff --git a/ext/phar/phar.c b/ext/phar/phar.c index c31fd7d070967..70ca17fb42d61 100644 --- a/ext/phar/phar.c +++ b/ext/phar/phar.c @@ -3719,7 +3719,7 @@ static const zend_module_dep phar_deps[] = { #if HAVE_SPL ZEND_MOD_REQUIRED("spl") #endif - {NULL, NULL, NULL} + ZEND_MOD_END }; zend_module_entry phar_module_entry = { diff --git a/ext/session/session.c b/ext/session/session.c index 16528e2d731c5..bc3b3487a08a7 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -2075,7 +2075,7 @@ static PHP_MINFO_FUNCTION(session) /* {{{ */ static const zend_module_dep session_deps[] = { /* {{{ */ ZEND_MOD_OPTIONAL("hash") ZEND_MOD_REQUIRED("spl") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* }}} */ diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index 6f4e366108993..c7bada57c40ea 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -2553,7 +2553,7 @@ const zend_function_entry simplexml_functions[] = { /* {{{ */ static const zend_module_dep simplexml_deps[] = { /* {{{ */ ZEND_MOD_REQUIRED("libxml") ZEND_MOD_REQUIRED("spl") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* }}} */ diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index a83b8db3a6099..3b604efe2ae85 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -3383,7 +3383,7 @@ const zend_function_entry basic_functions[] = { /* {{{ */ static const zend_module_dep standard_deps[] = { /* {{{ */ ZEND_MOD_OPTIONAL("session") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* }}} */ diff --git a/ext/xml/xml.c b/ext/xml/xml.c index d7d2d7df41343..6788c86bc34d8 100644 --- a/ext/xml/xml.c +++ b/ext/xml/xml.c @@ -244,7 +244,7 @@ const zend_function_entry xml_functions[] = { #ifdef LIBXML_EXPAT_COMPAT static const zend_module_dep xml_deps[] = { ZEND_MOD_REQUIRED("libxml") - {NULL, NULL, NULL} + ZEND_MOD_END }; #endif diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c index f875896026ef9..c1f1712efe864 100644 --- a/ext/xmlreader/php_xmlreader.c +++ b/ext/xmlreader/php_xmlreader.c @@ -321,7 +321,7 @@ static xmlRelaxNGPtr _xmlreader_get_relaxNG(char *source, int source_len, int ty static const zend_module_dep xmlreader_deps[] = { ZEND_MOD_REQUIRED("libxml") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* {{{ xmlreader_module_entry diff --git a/ext/xsl/php_xsl.c b/ext/xsl/php_xsl.c index 896c28596c1f9..f8d2519defad1 100644 --- a/ext/xsl/php_xsl.c +++ b/ext/xsl/php_xsl.c @@ -41,7 +41,7 @@ const zend_function_entry xsl_functions[] = { static const zend_module_dep xsl_deps[] = { ZEND_MOD_REQUIRED("libxml") - {NULL, NULL, NULL} + ZEND_MOD_END }; /* {{{ xsl_module_entry From bc514c8339bf24776102df9763c0a9fd9c4fb47c Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 6 Aug 2011 15:23:06 +0000 Subject: [PATCH 0467/2394] changed mapping of 0xa5 for SJIS-mac to prevent security attack. --- ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c index b70515f6321cb..03c4c0c793f97 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c @@ -568,7 +568,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) } else if (c == 0xa0) { s1 = 0x00a0; } else if (c == 0xa5) { /* YEN SIGN */ - s1 = 0x005c; + s1 = 0x216f; /* FULLWIDTH YEN SIGN */ } else if (c == 0xff3c) { /* FULLWIDTH REVERSE SOLIDUS */ s1 = 0x2140; } From 1bc34a491cae760b0b18ede16fbb672620ee749d Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sat, 6 Aug 2011 21:10:29 +0000 Subject: [PATCH 0468/2394] Fix another Coverity warning by initializing this to NULL prior to the strtok_r call --- main/php_ini.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/php_ini.c b/main/php_ini.c index 48e0654441ef5..7d7c26012eec4 100644 --- a/main/php_ini.c +++ b/main/php_ini.c @@ -484,7 +484,7 @@ int php_init_config(TSRMLS_D) if ((envpath = getenv("PATH")) != NULL) { char *search_dir, search_path[MAXPATHLEN]; - char *last; + char *last = NULL; path = estrdup(envpath); search_dir = php_strtok_r(path, ":", &last); From facfed523deaed83ff346e205e09e24c6097f926 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sat, 6 Aug 2011 23:34:13 +0000 Subject: [PATCH 0469/2394] Not our issue, but fixing here for now and reporting upstream --- ext/sqlite3/libsqlite/sqlite3.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/sqlite3/libsqlite/sqlite3.c b/ext/sqlite3/libsqlite/sqlite3.c index d461dad4a4780..786a3ec62f02a 100644 --- a/ext/sqlite3/libsqlite/sqlite3.c +++ b/ext/sqlite3/libsqlite/sqlite3.c @@ -111471,6 +111471,7 @@ static void fts3Appendf( z = z2; } if( z==0 ) *pRc = SQLITE_NOMEM; + va_end(ap); sqlite3_free(*pz); *pz = z; } From 1a9f66d6d4e3431f0e95280cedccd845285acb21 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sat, 6 Aug 2011 23:42:52 +0000 Subject: [PATCH 0470/2394] Avoid a potential double-free here --- sapi/cli/php_cli_server.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 0c5fb9cd1f691..6c725a7814bca 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -910,6 +910,7 @@ static int php_network_listen_socket(const char *host, int *port, int socktype, for (p = sal; *p; p++) { if (sa) { pefree(sa, 1); + sa = NULL; } retval = socket((*p)->sa_family, socktype, 0); From 71af9259e3362fb1735b4b0b3d5f495f36f63285 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 00:01:17 +0000 Subject: [PATCH 0471/2394] Use property_info.name here instead since *name might be free'ed at this point @dmitry please review --- Zend/zend_API.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index fb49767e03d8d..18aae835fd685 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -3378,7 +3378,7 @@ ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, in property_info.ce = ce; - zend_hash_quick_update(&ce->properties_info, name, name_length + 1, h, &property_info, sizeof(zend_property_info), NULL); + zend_hash_quick_update(&ce->properties_info, property_info.name, property_info.name_length+1, h, &property_info, sizeof(zend_property_info), NULL); return SUCCESS; } From c70aa9436acb5f221d86c991761146b7f0bf9f8d Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 00:18:38 +0000 Subject: [PATCH 0472/2394] These naked strcpy()s scare me --- ext/ereg/ereg.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/ereg/ereg.c b/ext/ereg/ereg.c index 3fbaa2cc63a5f..c2b065210a561 100644 --- a/ext/ereg/ereg.c +++ b/ext/ereg/ereg.c @@ -474,7 +474,7 @@ PHP_EREG_API char *php_ereg_replace(const char *pattern, const char *replace, co if (new_l + 1 > buf_len) { buf_len = 1 + buf_len + 2 * new_l; nbuf = emalloc(buf_len); - strcpy(nbuf, buf); + strncpy(nbuf, buf, buf_len-1); efree(buf); buf = nbuf; } @@ -511,7 +511,7 @@ PHP_EREG_API char *php_ereg_replace(const char *pattern, const char *replace, co if (new_l + 1 > buf_len) { buf_len = 1 + buf_len + 2 * new_l; nbuf = safe_emalloc(buf_len, sizeof(char), 0); - strcpy(nbuf, buf); + strncpy(nbuf, buf, buf_len-1); efree(buf); buf = nbuf; } @@ -526,7 +526,7 @@ PHP_EREG_API char *php_ereg_replace(const char *pattern, const char *replace, co if (new_l + 1 > buf_len) { buf_len = new_l + 1; /* now we know exactly how long it is */ nbuf = safe_emalloc(buf_len, sizeof(char), 0); - strcpy(nbuf, buf); + strncpy(nbuf, buf, buf_len-1); efree(buf); buf = nbuf; } From 50d67ef7b5b1ee2105cc2e2cce0910470c305311 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 00:25:22 +0000 Subject: [PATCH 0473/2394] Use snprintf here instead to make the static analyzers happy. --- Zend/zend.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend.c b/Zend/zend.c index f2e433353f60d..b25bfd97e7b29 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -247,7 +247,7 @@ ZEND_API void zend_make_printable_zval(zval *expr, zval *expr_copy, int *use_cop break; case IS_RESOURCE: Z_STRVAL_P(expr_copy) = (char *) emalloc(sizeof("Resource id #") - 1 + MAX_LENGTH_OF_LONG); - Z_STRLEN_P(expr_copy) = sprintf(Z_STRVAL_P(expr_copy), "Resource id #%ld", Z_LVAL_P(expr)); + Z_STRLEN_P(expr_copy) = snprintf(Z_STRVAL_P(expr_copy), sizeof("Resource id #") - 1 + MAX_LENGTH_OF_LONG, "Resource id #%ld", Z_LVAL_P(expr)); break; case IS_ARRAY: Z_STRLEN_P(expr_copy) = sizeof("Array") - 1; From 8dc951194b45c7acc36cd3a140f51d5db1d3f65b Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 00:36:26 +0000 Subject: [PATCH 0474/2394] I'm pretty sure you didn't mean to multiple by the size of a char* there since that makes no sense. output is an array of char, not an array of char* Pierre, please review --- ext/standard/crypt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index fda95d8f9cbe9..865a25beb1951 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -198,7 +198,7 @@ PHP_FUNCTION(crypt) int needed = (sizeof(sha512_salt_prefix) - 1 + sizeof(sha512_rounds_prefix) + 9 + 1 + strlen(salt) + 1 + 43 + 1); - output = emalloc(needed * sizeof(char *)); + output = emalloc(needed); salt[salt_in_len] = '\0'; crypt_res = php_sha512_crypt_r(str, salt, output, needed); @@ -221,7 +221,7 @@ PHP_FUNCTION(crypt) int needed = (sizeof(sha256_salt_prefix) - 1 + sizeof(sha256_rounds_prefix) + 9 + 1 + strlen(salt) + 1 + 43 + 1); - output = emalloc(needed * sizeof(char *)); + output = emalloc(needed); salt[salt_in_len] = '\0'; crypt_res = php_sha256_crypt_r(str, salt, output, needed); From c44c0490d55745c504d29889c4100b00c6fb298f Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 00:50:46 +0000 Subject: [PATCH 0475/2394] Since we have fci_cache = &fci_cache_local inside that block and fci_cache is then later used outside the block, fci_cache_local can't be block-scoped here --- Zend/zend_execute_API.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index f7594d9be1b92..839621ea6b79d 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -763,6 +763,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS zend_class_entry *called_scope = NULL; zval *current_this; zend_execute_data execute_data; + zend_fcall_info_cache fci_cache_local; *fci->retval_ptr_ptr = NULL; @@ -797,7 +798,6 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS } if (!fci_cache || !fci_cache->initialized) { - zend_fcall_info_cache fci_cache_local; char *callable_name; char *error = NULL; From 2b874abb741207a5f3991d37e936c44fc6516484 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 03:25:19 +0000 Subject: [PATCH 0476/2394] Good catch Coverity --- sapi/cgi/cgi_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index b19d501ba247f..c659557b04c18 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -689,6 +689,7 @@ static void sapi_cgi_register_variables(zval *track_vars_array TSRMLS_DC) free_php_self = 1; } else { php_self = path_info; + php_self_len = path_info_len; free_php_self = 0; } } else if (script_name) { From 66527e38ccbb7d532505279e9812a733b2353d5d Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 7 Aug 2011 05:19:55 +0000 Subject: [PATCH 0477/2394] Fixed the bug that temp may depend on a uninitialzed value --- ext/phar/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/phar/util.c b/ext/phar/util.c index c4f1a756cb2cf..2d9383bc08df9 100644 --- a/ext/phar/util.c +++ b/ext/phar/util.c @@ -124,7 +124,7 @@ php_stream *phar_get_efp(phar_entry_info *entry, int follow_links TSRMLS_DC) /* int phar_seek_efp(phar_entry_info *entry, off_t offset, int whence, off_t position, int follow_links TSRMLS_DC) /* {{{ */ { php_stream *fp = phar_get_efp(entry, follow_links TSRMLS_CC); - off_t temp, eoffset; + off_t temp = 0, eoffset = 0; if (!fp) { return -1; From ad0cfd9865b8318a760d0ce018642f4b218d0438 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 7 Aug 2011 05:24:11 +0000 Subject: [PATCH 0478/2394] Initialize temp with 0, avoiding compile warning --- ext/phar/stream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/phar/stream.c b/ext/phar/stream.c index f9bf3f3e01e79..2addae4db5b50 100644 --- a/ext/phar/stream.c +++ b/ext/phar/stream.c @@ -403,7 +403,7 @@ static int phar_stream_seek(php_stream *stream, off_t offset, int whence, off_t phar_entry_data *data = (phar_entry_data *)stream->abstract; phar_entry_info *entry; int res; - off_t temp; + off_t temp = 0; if (data->internal_file->link) { entry = phar_get_link_source(data->internal_file TSRMLS_CC); From 21232aa9f27c05d378f36aea69cf7383a720ce21 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 7 Aug 2011 05:46:31 +0000 Subject: [PATCH 0479/2394] Pointer returned is never used --- ext/phar/dirstream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/phar/dirstream.c b/ext/phar/dirstream.c index f0fe1be45cc9f..4b6fd586f9b99 100644 --- a/ext/phar/dirstream.c +++ b/ext/phar/dirstream.c @@ -503,7 +503,7 @@ int phar_wrapper_mkdir(php_stream_wrapper *wrapper, char *url_from, int mode, in return 0; } - if ((e = phar_get_entry_info_dir(phar, resource->path + 1, strlen(resource->path + 1), 0, &error, 1 TSRMLS_CC))) { + if (phar_get_entry_info_dir(phar, resource->path + 1, strlen(resource->path + 1), 0, &error, 1 TSRMLS_CC)) { /* entry exists as a file */ php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "phar error: cannot create directory \"%s\" in phar \"%s\", file already exists", resource->path+1, resource->host); php_url_free(resource); From ae1746c876459ebcf510253aa4cb397ea9a55836 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 7 Aug 2011 06:04:11 +0000 Subject: [PATCH 0480/2394] class entry is never used --- ext/standard/var.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/standard/var.c b/ext/standard/var.c index 82d701cfa4250..cf9342db4f193 100644 --- a/ext/standard/var.c +++ b/ext/standard/var.c @@ -244,7 +244,6 @@ PHPAPI void php_debug_zval_dump(zval **struc, int level TSRMLS_DC) /* {{{ */ HashTable *myht = NULL; char *class_name; zend_uint class_name_len; - zend_class_entry *ce; int (*zval_element_dump_func)(zval** TSRMLS_DC, int, va_list, zend_hash_key*); int is_temp = 0; @@ -285,7 +284,6 @@ PHPAPI void php_debug_zval_dump(zval **struc, int level TSRMLS_DC) /* {{{ */ PUTS("*RECURSION*\n"); return; } - ce = Z_OBJCE_PP(struc); Z_OBJ_HANDLER_PP(struc, get_class_name)(*struc, &class_name, &class_name_len, 0 TSRMLS_CC); php_printf("%sobject(%s)#%d (%d) refcount(%u){\n", COMMON, class_name, Z_OBJ_HANDLE_PP(struc), myht ? zend_hash_num_elements(myht) : 0, Z_REFCOUNT_PP(struc)); efree(class_name); From 3751efa3dc62ec14f793f43be3e0505348031261 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 7 Aug 2011 06:19:43 +0000 Subject: [PATCH 0481/2394] function_name cannot be false --- Zend/zend_builtin_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index c4917ecac277a..ce972a3ba8c44 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -2157,7 +2157,7 @@ ZEND_FUNCTION(debug_print_backtrace) ZEND_PUTS(class_name); ZEND_PUTS(call_type); } - zend_printf("%s(", function_name?function_name:"main"); + zend_printf("%s(", function_name); if (arg_array) { debug_print_backtrace_args(arg_array TSRMLS_CC); zval_ptr_dtor(&arg_array); From caff611cf30cb0c5a8240fa9e0c41d3bd284c278 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 7 Aug 2011 06:37:22 +0000 Subject: [PATCH 0482/2394] Remove unused variables --- ext/mbstring/mbstring.c | 2 +- ext/xsl/xsltprocessor.c | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 2b9da43f042eb..886c2cdc92a74 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -1147,7 +1147,7 @@ static char *php_mb_rfc1867_getword_conf(const zend_encoding *encoding, char *st static char *php_mb_rfc1867_basename(const zend_encoding *encoding, char *filename TSRMLS_DC) /* {{{ */ { - char *s, *s2, *tmp; + char *s, *s2; const size_t filename_len = strlen(filename); /* The \ check should technically be needed for win32 systems only where diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 59c8bed8b06ca..2aa4479e27f96 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -934,7 +934,6 @@ PHP_FUNCTION(xsl_xsltprocessor_get_security_prefs) { zval *id; xsl_object *intern; - long securityPrefs; DOM_GET_THIS(id); if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "") == SUCCESS) { From 937f7fa87626e90231f787f7b162fac02d50f87b Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 7 Aug 2011 11:13:27 +0000 Subject: [PATCH 0483/2394] Initialize variable with fixed value for avoiding compile warnings --- ext/phar/phar.c | 3 ++- ext/phar/phar_object.c | 4 ++-- ext/phar/util.c | 6 ++++-- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/ext/phar/phar.c b/ext/phar/phar.c index 70ca17fb42d61..866eb41b188ba 100644 --- a/ext/phar/phar.c +++ b/ext/phar/phar.c @@ -667,7 +667,7 @@ static int phar_parse_pharfile(php_stream *fp, char *fname, int fname_len, char php_uint32 manifest_len, manifest_count, manifest_flags, manifest_index, tmp_len, sig_flags; php_uint16 manifest_ver; long offset; - int register_alias, sig_len, temp_alias = 0; + int sig_len, register_alias = 0, temp_alias = 0; char *signature = NULL; if (pphar) { @@ -3391,6 +3391,7 @@ static zend_op_array *phar_compile_file(zend_file_handle *file_handle, int type res = phar_orig_compile_file(file_handle, type TSRMLS_CC); } zend_catch { failed = 1; + res = NULL; } zend_end_try(); if (name) { diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index 38ef95fbd1ce9..6abf5c33b2d01 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -663,7 +663,7 @@ PHP_METHOD(Phar, webPhar) const char *basename; int fname_len, entry_len, code, index_php_len = 0, not_cgi; phar_archive_data *phar = NULL; - phar_entry_info *info; + phar_entry_info *info = NULL; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!s!saz", &alias, &alias_len, &index_php, &index_php_len, &f404, &f404_len, &mimeoverride, &rewrite) == FAILURE) { return; @@ -890,7 +890,7 @@ PHP_METHOD(Phar, webPhar) zend_bailout(); } else { - char *tmp, sa; + char *tmp = NULL, sa = '\0'; sapi_header_line ctr = {0}; ctr.response_code = 301; ctr.line_len = sizeof("HTTP/1.1 301 Moved Permanently")+1; diff --git a/ext/phar/util.c b/ext/phar/util.c index 2d9383bc08df9..22403e8ff0b3b 100644 --- a/ext/phar/util.c +++ b/ext/phar/util.c @@ -124,7 +124,7 @@ php_stream *phar_get_efp(phar_entry_info *entry, int follow_links TSRMLS_DC) /* int phar_seek_efp(phar_entry_info *entry, off_t offset, int whence, off_t position, int follow_links TSRMLS_DC) /* {{{ */ { php_stream *fp = phar_get_efp(entry, follow_links TSRMLS_CC); - off_t temp = 0, eoffset = 0; + off_t temp, eoffset; if (!fp) { return -1; @@ -154,6 +154,8 @@ int phar_seek_efp(phar_entry_info *entry, off_t offset, int whence, off_t positi case SEEK_SET: temp = eoffset + offset; break; + default: + temp = 0; } if (temp > eoffset + (off_t) entry->uncompressed_filesize) { @@ -1203,7 +1205,7 @@ int phar_get_archive(phar_archive_data **archive, char *fname, int fname_len, ch phar_archive_data *fd, **fd_ptr; char *my_realpath, *save; int save_len; - ulong fhash, ahash; + ulong fhash, ahash = 0; phar_request_initialize(TSRMLS_C); From f9ca0cacb30fb9528eb2674176ed203f61e832dd Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 7 Aug 2011 13:04:02 +0000 Subject: [PATCH 0484/2394] - Revert r314387 (property_info.name has the mangled name) --- Zend/zend_API.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 18aae835fd685..96e5b13a6bc44 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -3378,7 +3378,7 @@ ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, in property_info.ce = ce; - zend_hash_quick_update(&ce->properties_info, property_info.name, property_info.name_length+1, h, &property_info, sizeof(zend_property_info), NULL); + zend_hash_quick_update(&ce->properties_info, name, name_length+1, h, &property_info, sizeof(zend_property_info), NULL); return SUCCESS; } From a35462c71cf084d169100bc1bc0de4e3e69f00cf Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 7 Aug 2011 13:19:04 +0000 Subject: [PATCH 0485/2394] Fixed bug that may dereferenced NULL pointer before checking --- ext/standard/basic_functions.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 3b604efe2ae85..cca7d8385a1f4 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -4282,15 +4282,15 @@ PHP_FUNCTION(getopt) /* the first slots are filled by the one short ops * we now extend our array and jump to the new added structs */ opts = (opt_struct *) erealloc(opts, sizeof(opt_struct) * (len + count + 1)); + if (!opts) { + RETURN_FALSE; + } + orig_opts = opts; opts += len; memset(opts, 0, count * sizeof(opt_struct)); - if (!opts) { - RETURN_FALSE; - } - /* Reset the array indexes. */ zend_hash_internal_pointer_reset(Z_ARRVAL_P(p_longopts)); @@ -4327,6 +4327,10 @@ PHP_FUNCTION(getopt) } } else { opts = (opt_struct*) erealloc(opts, sizeof(opt_struct) * (len + 1)); + if (!opts) { + RETURN_FALSE; + } + orig_opts = opts; opts += len; } From 2ce3f11f4bd20548dfdb27366fb2dd8585d6ec2a Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 7 Aug 2011 14:25:30 +0000 Subject: [PATCH 0486/2394] revert -r314422 No need to check erealloc's return --- ext/standard/basic_functions.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index cca7d8385a1f4..3b604efe2ae85 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -4282,15 +4282,15 @@ PHP_FUNCTION(getopt) /* the first slots are filled by the one short ops * we now extend our array and jump to the new added structs */ opts = (opt_struct *) erealloc(opts, sizeof(opt_struct) * (len + count + 1)); - if (!opts) { - RETURN_FALSE; - } - orig_opts = opts; opts += len; memset(opts, 0, count * sizeof(opt_struct)); + if (!opts) { + RETURN_FALSE; + } + /* Reset the array indexes. */ zend_hash_internal_pointer_reset(Z_ARRVAL_P(p_longopts)); @@ -4327,10 +4327,6 @@ PHP_FUNCTION(getopt) } } else { opts = (opt_struct*) erealloc(opts, sizeof(opt_struct) * (len + 1)); - if (!opts) { - RETURN_FALSE; - } - orig_opts = opts; opts += len; } From 97bc4c84032881cd398e46098e8cfbae6f3a9590 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 15:38:36 +0000 Subject: [PATCH 0487/2394] Make static analyzers happy --- ext/standard/php_crypt_r.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index e8b482ab6b7d8..f169c1a745e84 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -377,7 +377,7 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) /* Now make the output string */ memcpy(passwd, MD5_MAGIC, MD5_MAGIC_LEN); strlcpy(passwd + MD5_MAGIC_LEN, sp, sl + 1); - strcat(passwd, "$"); + strncat(passwd, "$", 1); PHP_MD5Final(final, &ctx); From bfffb28ebf44aa872876937e1607fb7316099940 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 15:45:18 +0000 Subject: [PATCH 0488/2394] Not an issue here, but a good habit to follow consistently. Never use strcpy/strcat. --- ext/pdo/php_pdo_int.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/pdo/php_pdo_int.h b/ext/pdo/php_pdo_int.h index fa9abca406872..62b3bb9188489 100755 --- a/ext/pdo/php_pdo_int.h +++ b/ext/pdo/php_pdo_int.h @@ -58,7 +58,7 @@ extern pdo_driver_t *pdo_find_driver(const char *name, int namelen); extern void pdo_handle_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt TSRMLS_DC); #define PDO_DBH_CLEAR_ERR() do { \ - strcpy(dbh->error_code, PDO_ERR_NONE); \ + strncpy(dbh->error_code, PDO_ERR_NONE, sizeof(PDO_ERR_NONE)); \ if (dbh->query_stmt) { \ dbh->query_stmt = NULL; \ zend_objects_store_del_ref(&dbh->query_stmt_zval TSRMLS_CC); \ From 25cdff4d750ddb5ce84ac9ccbf2768946d5e0d5f Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 15:52:46 +0000 Subject: [PATCH 0489/2394] Signed 1-bit bitfields make no sense --- sapi/cli/php_cli_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 6c725a7814bca..f11e1db03dec1 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -169,7 +169,7 @@ typedef struct php_cli_server_client { int content_sender_initialized:1; php_cli_server_content_sender content_sender; php_cli_server_buffer capture_buffer; - int capturing:1; + unsigned int capturing:1; int file_fd; } php_cli_server_client; From d9845c2046990d1f0621cbe6b4091bdc5ba31930 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 15:57:35 +0000 Subject: [PATCH 0490/2394] More signed 1-bit bitfields --- ext/phar/phar_internal.h | 6 +++--- sapi/cli/php_cli_server.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/ext/phar/phar_internal.h b/ext/phar/phar_internal.h index 59ff19fd97261..dc40875fbc4f1 100644 --- a/ext/phar/phar_internal.h +++ b/ext/phar/phar_internal.h @@ -485,9 +485,9 @@ typedef struct _phar_entry_data { off_t position; /* for copies of the phar fp, defines where 0 is */ off_t zero; - int for_write:1; - int is_zip:1; - int is_tar:1; + unsigned int for_write:1; + unsigned int is_zip:1; + unsigned int is_tar:1; phar_entry_info *internal_file; } phar_entry_data; diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index f11e1db03dec1..3202afe00d943 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -160,13 +160,13 @@ typedef struct php_cli_server_client { char *addr_str; size_t addr_str_len; php_http_parser parser; - int request_read:1; + unsigned int request_read:1; char *current_header_name; size_t current_header_name_len; - int current_header_name_allocated:1; + unsigned int current_header_name_allocated:1; size_t post_read_offset; php_cli_server_request request; - int content_sender_initialized:1; + unsigned int content_sender_initialized:1; php_cli_server_content_sender content_sender; php_cli_server_buffer capture_buffer; unsigned int capturing:1; From 7eb5bbbf65f4e142add0bcd2229a9c5b3ac7abf2 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 7 Aug 2011 16:10:34 +0000 Subject: [PATCH 0491/2394] Fix more signed 1-bit bitfield, and let's use strlcpy/strlcat instead for these static string copies --- ext/pdo/php_pdo_int.h | 2 +- ext/standard/php_crypt_r.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/pdo/php_pdo_int.h b/ext/pdo/php_pdo_int.h index 62b3bb9188489..774cd76f1402e 100755 --- a/ext/pdo/php_pdo_int.h +++ b/ext/pdo/php_pdo_int.h @@ -58,7 +58,7 @@ extern pdo_driver_t *pdo_find_driver(const char *name, int namelen); extern void pdo_handle_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt TSRMLS_DC); #define PDO_DBH_CLEAR_ERR() do { \ - strncpy(dbh->error_code, PDO_ERR_NONE, sizeof(PDO_ERR_NONE)); \ + strlcpy(dbh->error_code, PDO_ERR_NONE, sizeof(PDO_ERR_NONE)); \ if (dbh->query_stmt) { \ dbh->query_stmt = NULL; \ zend_objects_store_del_ref(&dbh->query_stmt_zval TSRMLS_CC); \ diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index f169c1a745e84..f4516712dae06 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -377,7 +377,7 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) /* Now make the output string */ memcpy(passwd, MD5_MAGIC, MD5_MAGIC_LEN); strlcpy(passwd + MD5_MAGIC_LEN, sp, sl + 1); - strncat(passwd, "$", 1); + strlcat(passwd, "$", 1); PHP_MD5Final(final, &ctx); From 9e9c9b3430d8242c196ebae5af3df8b8e3d49866 Mon Sep 17 00:00:00 2001 From: Gwynne Raskind Date: Sun, 7 Aug 2011 16:31:21 +0000 Subject: [PATCH 0492/2394] For 5.4, fix C++-style comments. For trunk, forward-port build fix. --- Zend/zend_operators.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 8e3a37eee75ff..9b0c790f8a1b1 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -615,7 +615,11 @@ static zend_always_inline int fast_sub_function(zval *result, zval *op1, zval *o "0:\n\t" "fildl (%2)\n\t" "fildl (%1)\n\t" +#if defined(__clang__) && (__clang_major__ < 2 || (__clang_major__ == 2 && __clang_minor__ < 10)) + "fsubp %%st(1), %%st\n\t" /* LLVM bug #9164 */ +#else "fsubp %%st, %%st(1)\n\t" +#endif "movb $0x2,0xc(%0)\n\t" "fstpl (%0)\n" "1:" @@ -635,7 +639,11 @@ static zend_always_inline int fast_sub_function(zval *result, zval *op1, zval *o "0:\n\t" "fildq (%2)\n\t" "fildq (%1)\n\t" +#if defined(__clang__) && (__clang_major__ < 2 || (__clang_major__ == 2 && __clang_minor__ < 10)) + "fsubp %%st(1), %%st\n\t" /* LLVM bug #9164 */ +#else "fsubp %%st, %%st(1)\n\t" +#endif "movb $0x2,0x14(%0)\n\t" "fstpl (%0)\n" "1:" From b8a2da31b1104904edb0c14e5633c0c1f6139e1f Mon Sep 17 00:00:00 2001 From: Gwynne Raskind Date: Sun, 7 Aug 2011 17:14:14 +0000 Subject: [PATCH 0493/2394] Back- and front-port fixes for #55019 --- ext/intl/grapheme/grapheme_string.c | 6 +++--- ext/intl/grapheme/grapheme_util.c | 4 ++-- ext/intl/grapheme/grapheme_util.h | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/ext/intl/grapheme/grapheme_string.c b/ext/intl/grapheme/grapheme_string.c index 769ff7ddbb152..719015fe64be7 100755 --- a/ext/intl/grapheme/grapheme_string.c +++ b/ext/intl/grapheme/grapheme_string.c @@ -677,7 +677,7 @@ PHP_FUNCTION(grapheme_stristr) /* }}} */ /* {{{ grapheme_extract_charcount_iter - grapheme iterator for grapheme_extract MAXCHARS */ -inline int32_t +static inline int32_t grapheme_extract_charcount_iter(UBreakIterator *bi, int32_t csize, unsigned char *pstr, int32_t str_len) { int pos = 0, prev_pos = 0; @@ -714,7 +714,7 @@ grapheme_extract_charcount_iter(UBreakIterator *bi, int32_t csize, unsigned char /* }}} */ /* {{{ grapheme_extract_bytecount_iter - grapheme iterator for grapheme_extract MAXBYTES */ -inline int32_t +static inline int32_t grapheme_extract_bytecount_iter(UBreakIterator *bi, int32_t bsize, unsigned char *pstr, int32_t str_len) { int pos = 0, prev_pos = 0; @@ -748,7 +748,7 @@ grapheme_extract_bytecount_iter(UBreakIterator *bi, int32_t bsize, unsigned char /* }}} */ /* {{{ grapheme_extract_count_iter - grapheme iterator for grapheme_extract COUNT */ -inline int32_t +static inline int32_t grapheme_extract_count_iter(UBreakIterator *bi, int32_t size, unsigned char *pstr, int32_t str_len) { int pos = 0, next_pos = 0; diff --git a/ext/intl/grapheme/grapheme_util.c b/ext/intl/grapheme/grapheme_util.c index db56431648599..92008554d47b1 100755 --- a/ext/intl/grapheme/grapheme_util.c +++ b/ext/intl/grapheme/grapheme_util.c @@ -432,7 +432,7 @@ int grapheme_split_string(const UChar *text, int32_t text_length, int boundary_a /* }}} */ /* {{{ grapheme_count_graphemes */ -inline int32_t +int32_t grapheme_count_graphemes(UBreakIterator *bi, UChar *string, int32_t string_len) { int ret_len = 0; @@ -456,7 +456,7 @@ grapheme_count_graphemes(UBreakIterator *bi, UChar *string, int32_t string_len) /* }}} */ /* {{{ grapheme_memnstr_grapheme: find needle in haystack using grapheme boundaries */ -inline int32_t +int32_t grapheme_memnstr_grapheme(UBreakIterator *bi, UChar *haystack, UChar *needle, int32_t needle_len, UChar *end) { UChar *p = haystack; diff --git a/ext/intl/grapheme/grapheme_util.h b/ext/intl/grapheme/grapheme_util.h index f8207cac5263d..675c6481b73d0 100755 --- a/ext/intl/grapheme/grapheme_util.h +++ b/ext/intl/grapheme/grapheme_util.h @@ -36,10 +36,10 @@ int grapheme_ascii_check(const unsigned char *day, int32_t len); int grapheme_split_string(const UChar *text, int32_t text_length, int boundary_array[], int boundary_array_len TSRMLS_DC ); -inline int32_t +int32_t grapheme_count_graphemes(UBreakIterator *bi, UChar *string, int32_t string_len); -inline int32_t +int32_t grapheme_memnstr_grapheme(UBreakIterator *bi, UChar *haystack, UChar *needle, int32_t needle_len, UChar *end); inline void *grapheme_memrchr_grapheme(const void *s, int c, int32_t n); From dfe8fbca9e775ed8d66347b7f51cb0df779e8e0b Mon Sep 17 00:00:00 2001 From: Gwynne Raskind Date: Sun, 7 Aug 2011 17:15:40 +0000 Subject: [PATCH 0494/2394] Front- and back-port rev 314431 (missing php.h include) --- ext/intl/resourcebundle/resourcebundle_class.h | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/intl/resourcebundle/resourcebundle_class.h b/ext/intl/resourcebundle/resourcebundle_class.h index 65330dd164ed8..4755d723b8adb 100644 --- a/ext/intl/resourcebundle/resourcebundle_class.h +++ b/ext/intl/resourcebundle/resourcebundle_class.h @@ -20,6 +20,7 @@ #include #include +#include "php.h" #include "intl_error.h" From 20936960b5abaefa184372cc23fee1230f2f66f4 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Sun, 7 Aug 2011 17:36:31 +0000 Subject: [PATCH 0495/2394] - Fixed bug #55378: binary number literal returns float number though its value is enough small --- Zend/tests/binary-32bit.phpt | 154 +++++++++++++++++++++++++++++++++++ Zend/tests/binary.phpt | 154 +++++++++++++++++++++++++++++++++++ Zend/zend_language_scanner.c | 4 +- Zend/zend_language_scanner.l | 2 +- 4 files changed, 311 insertions(+), 3 deletions(-) create mode 100644 Zend/tests/binary-32bit.phpt create mode 100644 Zend/tests/binary.phpt diff --git a/Zend/tests/binary-32bit.phpt b/Zend/tests/binary-32bit.phpt new file mode 100644 index 0000000000000..4b87aded4fc76 --- /dev/null +++ b/Zend/tests/binary-32bit.phpt @@ -0,0 +1,154 @@ +--TEST-- +testing binary literals +--INI-- +precision=14 +--SKIPIF-- + +--FILE-- + +--FILE-- +value.lval = strtol(bin, NULL, 2); zendlval->type = IS_LONG; return T_LNUMBER; diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 73e22e209e522..a5c7fd183365b 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1469,7 +1469,7 @@ NEWLINE ("\r"|"\n"|"\r\n") --len; } - if (len < SIZEOF_LONG * 2) { + if (len < SIZEOF_LONG * 8) { zendlval->value.lval = strtol(bin, NULL, 2); zendlval->type = IS_LONG; return T_LNUMBER; From 5a64b062891604c08382e39dfdd9f72c9535fd09 Mon Sep 17 00:00:00 2001 From: Gwynne Raskind Date: Sun, 7 Aug 2011 18:12:52 +0000 Subject: [PATCH 0496/2394] possible use without init fixed --- ext/date/php_date.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 24a44b91107cc..c9a8465592bca 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2373,7 +2373,7 @@ static void update_errors_warnings(timelib_error_container *last_errors TSRMLS_D PHPAPI int php_date_initialize(php_date_obj *dateobj, /*const*/ char *time_str, int time_str_len, char *format, zval *timezone_object, int ctor TSRMLS_DC) { timelib_time *now; - timelib_tzinfo *tzi; + timelib_tzinfo *tzi = NULL; timelib_error_container *err = NULL; int type = TIMELIB_ZONETYPE_ID, new_dst; char *new_abbr; From 04d7804aec1901a9421103a585d10b568041404a Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Sun, 7 Aug 2011 23:46:00 +0000 Subject: [PATCH 0497/2394] Fixes for variety of issues identified by coverity scan --- ext/pdo/pdo.c | 2 +- ext/pdo/pdo_dbh.c | 2 +- ext/pdo/pdo_sql_parser.re | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c index 169ce32e25fe9..b654fea639948 100755 --- a/ext/pdo/pdo.c +++ b/ext/pdo/pdo.c @@ -191,7 +191,7 @@ PDO_API int php_pdo_register_driver(pdo_driver_t *driver) } return zend_hash_add(&pdo_driver_hash, (char*)driver->driver_name, driver->driver_name_len, - (void**)&driver, sizeof(driver), NULL); + (void**)&driver, sizeof(pdo_driver_t *), NULL); } PDO_API void php_pdo_unregister_driver(pdo_driver_t *driver) diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c index 9cc4162f7f666..c4380d1e48b1e 100755 --- a/ext/pdo/pdo_dbh.c +++ b/ext/pdo/pdo_dbh.c @@ -57,7 +57,7 @@ void pdo_raise_impl_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt, const char *sqlstate pdo_err = &stmt->error_code; } - strcpy(*pdo_err, sqlstate); + strncpy(*pdo_err, sqlstate, 6); /* hash sqlstate to error messages */ msg = pdo_sqlstate_state_to_description(*pdo_err); diff --git a/ext/pdo/pdo_sql_parser.re b/ext/pdo/pdo_sql_parser.re index bb7af3575d324..92411f8075464 100644 --- a/ext/pdo/pdo_sql_parser.re +++ b/ext/pdo/pdo_sql_parser.re @@ -236,6 +236,9 @@ safe: plc->freeq = 0; break; + case IS_BOOL: + convert_to_long(param->parameter); + case IS_LONG: case IS_DOUBLE: convert_to_string(param->parameter); @@ -244,8 +247,6 @@ safe: plc->freeq = 0; break; - case IS_BOOL: - convert_to_long(param->parameter); default: convert_to_string(param->parameter); if (!stmt->dbh->methods->quoter(stmt->dbh, Z_STRVAL_P(param->parameter), From ebefefeba8e802a594df79bd6ae956ed651a7d84 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 8 Aug 2011 00:07:54 +0000 Subject: [PATCH 0498/2394] Avoid strcpy() usage --- ext/pdo/pdo_sql_parser.re | 4 ++-- ext/pdo_sqlite/sqlite_driver.c | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/ext/pdo/pdo_sql_parser.re b/ext/pdo/pdo_sql_parser.re index 92411f8075464..a2a22e751791f 100644 --- a/ext/pdo/pdo_sql_parser.re +++ b/ext/pdo/pdo_sql_parser.re @@ -213,7 +213,7 @@ safe: param->param_type TSRMLS_CC)) { /* bork */ ret = -1; - strcpy(stmt->error_code, stmt->dbh->error_code); + strncpy(stmt->error_code, stmt->dbh->error_code, 6); if (buf) { efree(buf); } @@ -254,7 +254,7 @@ safe: param->param_type TSRMLS_CC)) { /* bork */ ret = -1; - strcpy(stmt->error_code, stmt->dbh->error_code); + strncpy(stmt->error_code, stmt->dbh->error_code, 6); goto clean_up; } plc->freeq = 1; diff --git a/ext/pdo_sqlite/sqlite_driver.c b/ext/pdo_sqlite/sqlite_driver.c index 71768a31b1fe0..0b19e2a9068d1 100644 --- a/ext/pdo_sqlite/sqlite_driver.c +++ b/ext/pdo_sqlite/sqlite_driver.c @@ -47,33 +47,33 @@ int _pdo_sqlite_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt, const char *file, int li } einfo->errmsg = pestrdup((char*)sqlite3_errmsg(H->db), dbh->is_persistent); } else { /* no error */ - strcpy(*pdo_err, PDO_ERR_NONE); + strncpy(*pdo_err, PDO_ERR_NONE, sizeof(PDO_ERR_NONE)); return 0; } switch (einfo->errcode) { case SQLITE_NOTFOUND: - strcpy(*pdo_err, "42S02"); + strncpy(*pdo_err, "42S02", sizeof("42S02")); break; case SQLITE_INTERRUPT: - strcpy(*pdo_err, "01002"); + strncpy(*pdo_err, "01002", sizeof("01002")); break; case SQLITE_NOLFS: - strcpy(*pdo_err, "HYC00"); + strncpy(*pdo_err, "HYC00", sizeof("HYC00")); break; case SQLITE_TOOBIG: - strcpy(*pdo_err, "22001"); + strncpy(*pdo_err, "22001", sizeof("22001")); break; case SQLITE_CONSTRAINT: - strcpy(*pdo_err, "23000"); + strncpy(*pdo_err, "23000", sizeof("23000")); break; case SQLITE_ERROR: default: - strcpy(*pdo_err, "HY000"); + strncpy(*pdo_err, "HY000", sizeof("HY000")); break; } From 4e97a9fc3fbf2d4bb2f0d9221f5bac8f8370702d Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 8 Aug 2011 00:47:40 +0000 Subject: [PATCH 0499/2394] Remove no sense statements --- ext/standard/basic_functions.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 3b604efe2ae85..9d7c0ca4936da 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -4287,10 +4287,6 @@ PHP_FUNCTION(getopt) memset(opts, 0, count * sizeof(opt_struct)); - if (!opts) { - RETURN_FALSE; - } - /* Reset the array indexes. */ zend_hash_internal_pointer_reset(Z_ARRVAL_P(p_longopts)); From 8bae5e220e19e76b8643bdb9fc2b60ff194c5a2f Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 8 Aug 2011 02:33:03 +0000 Subject: [PATCH 0500/2394] Wrong sizeof --- ext/spl/spl_observer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c index 2c0c4bcc5c6c2..2bbd02957962d 100755 --- a/ext/spl/spl_observer.c +++ b/ext/spl/spl_observer.c @@ -146,7 +146,7 @@ static char *spl_object_storage_get_hash(spl_SplObjectStorage *intern, zval *thi return (char*)&Z_OBJVAL_P(obj); #else - char *hash = emalloc((hash_len+1)*sizeof(char *)); + char *hash = emalloc((hash_len+1)*sizeof(char)); zend_object_value zvalue; memset(&zvalue, 0, sizeof(zend_object_value)); From 6ea19be48928d62dbffd3c5057671a220496c70c Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Mon, 8 Aug 2011 03:08:59 +0000 Subject: [PATCH 0501/2394] Use snprintf and strncat to make the static analyzers happy --- Zend/zend.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend.c b/Zend/zend.c index b25bfd97e7b29..333ff693b41e9 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -870,7 +870,7 @@ void zend_append_version_info(const zend_extension *extension) /* {{{ */ char *new_info; uint new_info_length; - new_info_length = sizeof(" with v, by \n") + new_info_length = sizeof(" with v, , by \n") + strlen(extension->name) + strlen(extension->version) + strlen(extension->copyright) @@ -878,10 +878,10 @@ void zend_append_version_info(const zend_extension *extension) /* {{{ */ new_info = (char *) malloc(new_info_length + 1); - sprintf(new_info, " with %s v%s, %s, by %s\n", extension->name, extension->version, extension->copyright, extension->author); + snprintf(new_info, new_info_length, " with %s v%s, %s, by %s\n", extension->name, extension->version, extension->copyright, extension->author); zend_version_info = (char *) realloc(zend_version_info, zend_version_info_length+new_info_length + 1); - strcat(zend_version_info, new_info); + strncat(zend_version_info, new_info, new_info_length); zend_version_info_length += new_info_length; free(new_info); } From caedca8dd035b91dc79c24c09294cbe10c33c6c1 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 8 Aug 2011 06:49:17 +0000 Subject: [PATCH 0502/2394] Make codes more clearly, and make the static analyzer silent.. --- ext/standard/info.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/ext/standard/info.c b/ext/standard/info.c index 2bee7e9803838..f57e4afab39e6 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -245,22 +245,22 @@ static void php_print_gpcse_array(char *name, uint name_length TSRMLS_DC) } } else { tmp2 = **tmp; - switch (Z_TYPE_PP(tmp)) { - default: - tmp = NULL; - zval_copy_ctor(&tmp2); - convert_to_string(&tmp2); - case IS_STRING: - if (!sapi_module.phpinfo_as_text) { - if (Z_STRLEN(tmp2) == 0) { - php_info_print("no value"); - } else { - php_info_print_html_esc(Z_STRVAL(tmp2), Z_STRLEN(tmp2)); - } - } else { - php_info_print(Z_STRVAL(tmp2)); - } + if (Z_TYPE_PP(tmp) != IS_STRING) { + tmp = NULL; + zval_copy_ctor(&tmp2); + convert_to_string(&tmp2); } + + if (!sapi_module.phpinfo_as_text) { + if (Z_STRLEN(tmp2) == 0) { + php_info_print("no value"); + } else { + php_info_print_html_esc(Z_STRVAL(tmp2), Z_STRLEN(tmp2)); + } + } else { + php_info_print(Z_STRVAL(tmp2)); + } + if (!tmp) { zval_dtor(&tmp2); } From 8de80c9679916b1c55a6b5f29068a575ba3d4799 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 8 Aug 2011 07:12:12 +0000 Subject: [PATCH 0503/2394] Prevented the warning about truncate int to char --- sapi/cli/php_cli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 64278af0da92a..9d8c1f113246c 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -615,7 +615,7 @@ static const char *param_mode_conflict = "Either execute direct code, process st */ static int cli_seek_file_begin(zend_file_handle *file_handle, char *script_file, int *lineno TSRMLS_DC) { - char c; + int c; *lineno = 1; From 8ea0c7d6e68e05d9e8cb6a9764428de126559ba5 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 8 Aug 2011 07:42:58 +0000 Subject: [PATCH 0504/2394] - Document the new ZEND_DONT_UNLOAD_MODULES environment variable. --- Zend/README.ZEND_MM | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Zend/README.ZEND_MM b/Zend/README.ZEND_MM index cf9a9b7e832af..60c22556bec33 100644 --- a/Zend/README.ZEND_MM +++ b/Zend/README.ZEND_MM @@ -9,7 +9,7 @@ allocation overhead and speedup memory management. The new manager's "configure" has no "--disable-zend-memory-manager" option, but it has "--enable-malloc-mm" instead. It is enabled by default in DEBUG -build and disabled by default in RELEASE build. when enabled it allows selecting +build and disabled by default in RELEASE build. When enabled it allows selecting between malloc and emalloc at runtime so you can use internal and external memory debuggers without recompilation. @@ -24,6 +24,15 @@ Zend MM disabled: $ USE_ZEND_ALLOC=0 valgrind --leak-check=full sapi/cli/php -r 'leak();' +Shared extensions: +------------------ + +Since PHP 5.4 it is possible to prevent shared extensions from unloading so +that valgrind can correctly track the memory leaks in shared extensions. For +this there is the ZEND_DONT_UNLOAD_MODULES environment variable. If set, then +DL_UNLOAD() is skipped during the shutdown of shared extensions. + + Tweaking: --------- From 802b871ea10fdab50b5b47cce067a3beeb8a9948 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 8 Aug 2011 08:49:55 +0000 Subject: [PATCH 0505/2394] Sizeof mismatch --- ext/spl/spl_observer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c index 2bbd02957962d..2487a08a3cecd 100755 --- a/ext/spl/spl_observer.c +++ b/ext/spl/spl_observer.c @@ -117,7 +117,7 @@ static char *spl_object_storage_get_hash(spl_SplObjectStorage *intern, zval *thi if (rv) { if (Z_TYPE_P(rv) == IS_STRING) { int hash_len = Z_STRLEN_P(rv); - char *hash = emalloc((hash_len+1)*sizeof(char *)); + char *hash = emalloc((hash_len+1)*sizeof(char)); strncpy(hash, Z_STRVAL_P(rv), hash_len); hash[hash_len] = 0; From 5035c11f0e51591749a168e2a8ce6aaa3a75f67d Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Mon, 8 Aug 2011 11:19:49 +0000 Subject: [PATCH 0506/2394] Use snprintf to make the static analyzers happy --- Zend/zend_builtin_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index ce972a3ba8c44..d507b6f5fe164 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1821,7 +1821,7 @@ ZEND_FUNCTION(create_function) function_name[0] = '\0'; do { - function_name_length = 1 + sprintf(function_name + 1, "lambda_%d", ++EG(lambda_count)); + function_name_length = 1 + snprintf(function_name + 1, sizeof("0lambda_")+MAX_LENGTH_OF_LONG, "lambda_%d", ++EG(lambda_count)); } while (zend_hash_add(EG(function_table), function_name, function_name_length+1, &new_function, sizeof(zend_function), NULL)==FAILURE); zend_hash_del(EG(function_table), LAMBDA_TEMP_FUNCNAME, sizeof(LAMBDA_TEMP_FUNCNAME)); RETURN_STRINGL(function_name, function_name_length, 0); From 7f203d43853b63a467c8d8562838b026f43b87f8 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Mon, 8 Aug 2011 11:30:56 +0000 Subject: [PATCH 0507/2394] Fix typo --- Zend/zend_hash.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index 4286ce9dc8765..506def0014a38 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -1207,7 +1207,7 @@ ZEND_API int zend_hash_get_current_data_ex(HashTable *ht, void **pData, HashPosi } } -/* This function changes key of currevt element without changing elements' +/* This function changes key of current element without changing elements' * order. If element with target key already exists, it will be deleted first. */ ZEND_API int zend_hash_update_current_key_ex(HashTable *ht, int key_type, const char *str_index, uint str_length, ulong num_index, int mode, HashPosition *pos) From 482e4b9d703d7b4dba99b70ae9965faa0f727d58 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Mon, 8 Aug 2011 12:05:34 +0000 Subject: [PATCH 0508/2394] Fix validator for SplFileInfo constructor --- ext/spl/spl_directory.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 21986e171be5d..8870926942752 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -633,6 +633,7 @@ static int spl_filesystem_object_constructor_validator(void *object_data TSRMLS_ * constructor or cleared its exception */ return (fsobj->u.dir.entry.d_name[0] != '\0' /* GlobIterator */ || + fsobj->_path != NULL /* SplFileInfo */ || fsobj->orig_path != NULL /* Spl[Temp]FileObject */); } /* }}} */ @@ -2431,7 +2432,9 @@ SPL_METHOD(SplFileObject, setFlags) { spl_filesystem_object *intern = (spl_filesystem_object*)zend_object_store_get_object(getThis() TSRMLS_CC); - zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &intern->flags); + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &intern->flags) == FAILURE) { + return; + } } /* }}} */ /* {{{ proto int SplFileObject::getFlags() From 9c834bd51c5ddaec33cb5a83e733fbd70bfee99d Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 8 Aug 2011 12:10:27 +0000 Subject: [PATCH 0509/2394] Make static analyzers happy --- ext/standard/head.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/head.c b/ext/standard/head.c index ec5ed95657479..05f5fb4e5af9c 100644 --- a/ext/standard/head.c +++ b/ext/standard/head.c @@ -127,7 +127,7 @@ PHPAPI int php_setcookie(char *name, int name_len, char *value, int value_len, t dt = php_format_date("D, d-M-Y H:i:s T", sizeof("D, d-M-Y H:i:s T")-1, expires, 0 TSRMLS_CC); /* check to make sure that the year does not exceed 4 digits in length */ p = zend_memrchr(dt, '-', strlen(dt)); - if (*(p + 5) != ' ') { + if (!p || *(p + 5) != ' ') { efree(dt); efree(cookie); efree(encoded_value); From 0c1516f1741fcab7dd543d1469df6ff35d72d734 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 8 Aug 2011 12:14:58 +0000 Subject: [PATCH 0510/2394] Removed deadcode --- sapi/cgi/cgi_main.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index c659557b04c18..8500449483ec4 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -1533,9 +1533,6 @@ static void add_request_header(char *var, unsigned int var_len, char *val, unsig var[4] == '_') { var_len -= 5; - if (var_len == 0) { - return; - } p = var + 5; var = str = do_alloca(var_len + 1, use_heap); *str++ = *p++; @@ -1604,9 +1601,6 @@ PHP_FUNCTION(apache_request_headers) /* {{{ */ var[4] == '_') { var_len -= 5; - if (var_len == 0) { - continue; - } if (var_len >= alloc_size) { alloc_size = var_len + 64; From bfdd53cd045ceff446f63ca0b97102a1a299d1ba Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 8 Aug 2011 13:45:18 +0000 Subject: [PATCH 0511/2394] Removal of deadcode identified by coverity --- ext/dom/attr.c | 2 +- ext/dom/document.c | 59 +++++++++++++++++------------------ ext/dom/dom_iterators.c | 4 +-- ext/dom/domimplementation.c | 7 ++--- ext/dom/element.c | 24 +++++++------- ext/dom/namednodemap.c | 12 +++---- ext/dom/node.c | 37 ++++++++++------------ ext/dom/nodelist.c | 4 +-- ext/dom/php_dom.c | 7 ++--- ext/dom/text.c | 2 +- ext/dom/xml_common.h | 6 ++-- ext/dom/xpath.c | 6 ++-- ext/xmlreader/php_xmlreader.c | 4 +-- 13 files changed, 83 insertions(+), 91 deletions(-) diff --git a/ext/dom/attr.c b/ext/dom/attr.c index 63978779f6edf..4b335764a6712 100644 --- a/ext/dom/attr.c +++ b/ext/dom/attr.c @@ -228,7 +228,7 @@ int dom_attr_owner_element_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object(nodeparent, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(nodeparent, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } diff --git a/ext/dom/document.c b/ext/dom/document.c index 393f178882000..e0460a01f05cb 100644 --- a/ext/dom/document.c +++ b/ext/dom/document.c @@ -261,7 +261,7 @@ int dom_document_doctype_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object((xmlNodePtr) dtdptr, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object((xmlNodePtr) dtdptr, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -311,7 +311,7 @@ int dom_document_document_element_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object(root, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(root, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -901,7 +901,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_element) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp; dom_object *intern; @@ -924,7 +924,7 @@ PHP_FUNCTION(dom_document_create_element) RETURN_FALSE; } - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_document_create_element */ @@ -934,7 +934,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_document_fragment) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp; dom_object *intern; @@ -951,7 +951,7 @@ PHP_FUNCTION(dom_document_create_document_fragment) RETURN_FALSE; } - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_document_create_document_fragment */ @@ -961,7 +961,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_text_node) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp; int ret, value_len; @@ -979,7 +979,7 @@ PHP_FUNCTION(dom_document_create_text_node) RETURN_FALSE; } - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_document_create_text_node */ @@ -989,7 +989,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_comment) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp; int ret, value_len; @@ -1007,7 +1007,7 @@ PHP_FUNCTION(dom_document_create_comment) RETURN_FALSE; } - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_document_create_comment */ @@ -1017,7 +1017,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_cdatasection) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp; int ret, value_len; @@ -1035,7 +1035,7 @@ PHP_FUNCTION(dom_document_create_cdatasection) RETURN_FALSE; } - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_document_create_cdatasection */ @@ -1045,7 +1045,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_processing_instruction) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp; int ret, value_len, name_len = 0; @@ -1070,7 +1070,7 @@ PHP_FUNCTION(dom_document_create_processing_instruction) node->doc = docp; - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_document_create_processing_instruction */ @@ -1080,7 +1080,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_attribute) { - zval *id, *rv = NULL; + zval *id; xmlAttrPtr node; xmlDocPtr docp; int ret, name_len; @@ -1103,7 +1103,7 @@ PHP_FUNCTION(dom_document_create_attribute) RETURN_FALSE; } - DOM_RET_OBJ(rv, (xmlNodePtr) node, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) node, &ret, intern); } /* }}} end dom_document_create_attribute */ @@ -1114,7 +1114,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_document_create_entity_reference) { - zval *id, *rv = NULL; + zval *id; xmlNode *node; xmlDocPtr docp = NULL; dom_object *intern; @@ -1137,7 +1137,7 @@ PHP_FUNCTION(dom_document_create_entity_reference) RETURN_FALSE; } - DOM_RET_OBJ(rv, (xmlNodePtr) node, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) node, &ret, intern); } /* }}} end dom_document_create_entity_reference */ @@ -1173,7 +1173,6 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_document_import_node) { - zval *rv = NULL; zval *id, *node; xmlDocPtr docp; xmlNodePtr nodep, retnodep; @@ -1219,7 +1218,7 @@ PHP_FUNCTION(dom_document_import_node) } } - DOM_RET_OBJ(rv, (xmlNodePtr) retnodep, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) retnodep, &ret, intern); } /* }}} end dom_document_import_node */ @@ -1229,7 +1228,7 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_document_create_element_ns) { - zval *id, *rv = NULL; + zval *id; xmlDocPtr docp; xmlNodePtr nodep = NULL; xmlNsPtr nsptr = NULL; @@ -1282,7 +1281,7 @@ PHP_FUNCTION(dom_document_create_element_ns) nodep->ns = nsptr; - DOM_RET_OBJ(rv, nodep, &ret, intern); + DOM_RET_OBJ(nodep, &ret, intern); } /* }}} end dom_document_create_element_ns */ @@ -1292,7 +1291,7 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_document_create_attribute_ns) { - zval *id, *rv = NULL; + zval *id; xmlDocPtr docp; xmlNodePtr nodep = NULL, root; xmlNsPtr nsptr; @@ -1347,7 +1346,7 @@ PHP_FUNCTION(dom_document_create_attribute_ns) RETURN_FALSE; } - DOM_RET_OBJ(rv, nodep, &ret, intern); + DOM_RET_OBJ(nodep, &ret, intern); } /* }}} end dom_document_create_attribute_ns */ @@ -1384,7 +1383,7 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_document_get_element_by_id) { - zval *id, *rv = NULL; + zval *id; xmlDocPtr docp; xmlAttrPtr attrp; int ret, idname_len; @@ -1400,7 +1399,7 @@ PHP_FUNCTION(dom_document_get_element_by_id) attrp = xmlGetID(docp, (xmlChar *) idname); if (attrp && attrp->parent) { - DOM_RET_OBJ(rv, (xmlNodePtr) attrp->parent, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) attrp->parent, &ret, intern); } else { RETVAL_NULL(); } @@ -1662,7 +1661,7 @@ static xmlDocPtr dom_document_parser(zval *id, int mode, char *source, int sourc /* {{{ static void dom_parse_document(INTERNAL_FUNCTION_PARAMETERS, int mode) */ static void dom_parse_document(INTERNAL_FUNCTION_PARAMETERS, int mode) { - zval *id, *rv = NULL; + zval *id; xmlDoc *docp = NULL, *newdoc; dom_doc_propsptr doc_prop; dom_object *intern; @@ -1714,7 +1713,7 @@ static void dom_parse_document(INTERNAL_FUNCTION_PARAMETERS, int mode) { RETURN_TRUE; } else { - DOM_RET_OBJ(rv, (xmlNodePtr) newdoc, &ret, NULL); + DOM_RET_OBJ((xmlNodePtr) newdoc, &ret, NULL); } } /* }}} end dom_parser_document */ @@ -2152,7 +2151,7 @@ PHP_FUNCTION(dom_document_relaxNG_validate_xml) static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */ { - zval *id, *rv = NULL; + zval *id; xmlDoc *docp = NULL, *newdoc; dom_object *intern; dom_doc_propsptr doc_prop; @@ -2225,7 +2224,7 @@ static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */ RETURN_TRUE; } else { - DOM_RET_OBJ(rv, (xmlNodePtr) newdoc, &ret, NULL); + DOM_RET_OBJ((xmlNodePtr) newdoc, &ret, NULL); } } /* }}} */ diff --git a/ext/dom/dom_iterators.c b/ext/dom/dom_iterators.c index 35fedc88e1947..72b6b039c6af1 100644 --- a/ext/dom/dom_iterators.c +++ b/ext/dom/dom_iterators.c @@ -251,7 +251,7 @@ static void php_dom_iterator_move_forward(zend_object_iterator *iter TSRMLS_DC) zval_ptr_dtor((zval**)&curobj); if (curnode) { MAKE_STD_ZVAL(curattr); - curattr = php_dom_create_object(curnode, &ret, NULL, curattr, objmap->baseobj TSRMLS_CC); + curattr = php_dom_create_object(curnode, &ret, curattr, objmap->baseobj TSRMLS_CC); } iterator->curobj = curattr; @@ -330,7 +330,7 @@ zend_object_iterator *php_dom_get_iterator(zend_class_entry *ce, zval *object, i err: if (curnode) { MAKE_STD_ZVAL(curattr); - curattr = php_dom_create_object(curnode, &ret, NULL, curattr, objmap->baseobj TSRMLS_CC); + curattr = php_dom_create_object(curnode, &ret, curattr, objmap->baseobj TSRMLS_CC); } iterator->curobj = curattr; diff --git a/ext/dom/domimplementation.c b/ext/dom/domimplementation.c index c7ad1d7bb7ce6..a130cf46b2587 100644 --- a/ext/dom/domimplementation.c +++ b/ext/dom/domimplementation.c @@ -91,7 +91,6 @@ Since: DOM Level 2 */ PHP_METHOD(domimplementation, createDocumentType) { - zval *rv = NULL; xmlDtd *doctype; int ret, name_len = 0, publicid_len = 0, systemid_len = 0; char *name = NULL, *publicid = NULL, *systemid = NULL; @@ -141,7 +140,7 @@ PHP_METHOD(domimplementation, createDocumentType) RETURN_FALSE; } - DOM_RET_OBJ(rv, (xmlNodePtr) doctype, &ret, NULL); + DOM_RET_OBJ((xmlNodePtr) doctype, &ret, NULL); } /* }}} end dom_domimplementation_create_document_type */ @@ -151,7 +150,7 @@ Since: DOM Level 2 */ PHP_METHOD(domimplementation, createDocument) { - zval *node = NULL, *rv = NULL; + zval *node = NULL; xmlDoc *docp; xmlNode *nodep; xmlDtdPtr doctype = NULL; @@ -238,7 +237,7 @@ PHP_METHOD(domimplementation, createDocument) xmlFree(localname); } - DOM_RET_OBJ(rv, (xmlNodePtr) docp, &ret, NULL); + DOM_RET_OBJ((xmlNodePtr) docp, &ret, NULL); if (doctobj != NULL) { doctobj->document = ((dom_object *)((php_libxml_node_ptr *)docp->_private)->_private)->document; diff --git a/ext/dom/element.c b/ext/dom/element.c index 66ad2af163bb6..5003e5008d76e 100644 --- a/ext/dom/element.c +++ b/ext/dom/element.c @@ -371,7 +371,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_element_set_attribute) { - zval *id, *rv = NULL; + zval *id; xmlNode *nodep; xmlNodePtr attr = NULL; int ret, name_len, value_len, name_valid; @@ -426,7 +426,7 @@ PHP_FUNCTION(dom_element_set_attribute) RETURN_FALSE; } - DOM_RET_OBJ(rv, attr, &ret, intern); + DOM_RET_OBJ(attr, &ret, intern); } /* }}} end dom_element_set_attribute */ @@ -485,7 +485,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_element_get_attribute_node) { - zval *id, *rv = NULL; + zval *id; xmlNodePtr nodep, attrp; int name_len, ret; dom_object *intern; @@ -521,7 +521,7 @@ PHP_FUNCTION(dom_element_get_attribute_node) attrp->ns = curns; } - DOM_RET_OBJ(rv, (xmlNodePtr) attrp, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) attrp, &ret, intern); } /* }}} end dom_element_get_attribute_node */ @@ -531,7 +531,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_element_set_attribute_node) { - zval *id, *node, *rv = NULL; + zval *id, *node; xmlNode *nodep; xmlAttr *attrp, *existattrp = NULL; dom_object *intern, *attrobj, *oldobj; @@ -583,7 +583,7 @@ PHP_FUNCTION(dom_element_set_attribute_node) /* Returns old property if removed otherwise NULL */ if (existattrp != NULL) { - DOM_RET_OBJ(rv, (xmlNodePtr) existattrp, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) existattrp, &ret, intern); } else { RETVAL_NULL(); } @@ -597,7 +597,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_element_remove_attribute_node) { - zval *id, *node, *rv = NULL; + zval *id, *node; xmlNode *nodep; xmlAttr *attrp; dom_object *intern, *attrobj; @@ -623,7 +623,7 @@ PHP_FUNCTION(dom_element_remove_attribute_node) xmlUnlinkNode((xmlNodePtr) attrp); - DOM_RET_OBJ(rv, (xmlNodePtr) attrp, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) attrp, &ret, intern); } /* }}} end dom_element_remove_attribute_node */ @@ -925,7 +925,7 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_element_get_attribute_node_ns) { - zval *id, *rv = NULL; + zval *id; xmlNodePtr elemp; xmlAttrPtr attrp; dom_object *intern; @@ -944,7 +944,7 @@ PHP_FUNCTION(dom_element_get_attribute_node_ns) RETURN_NULL(); } - DOM_RET_OBJ(rv, (xmlNodePtr) attrp, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) attrp, &ret, intern); } /* }}} end dom_element_get_attribute_node_ns */ @@ -955,7 +955,7 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_element_set_attribute_node_ns) { - zval *id, *node, *rv = NULL; + zval *id, *node; xmlNode *nodep; xmlNs *nsp; xmlAttr *attrp, *existattrp = NULL; @@ -1014,7 +1014,7 @@ PHP_FUNCTION(dom_element_set_attribute_node_ns) /* Returns old property if removed otherwise NULL */ if (existattrp != NULL) { - DOM_RET_OBJ(rv, (xmlNodePtr) existattrp, &ret, intern); + DOM_RET_OBJ((xmlNodePtr) existattrp, &ret, intern); } else { RETVAL_NULL(); } diff --git a/ext/dom/namednodemap.c b/ext/dom/namednodemap.c index 963371a8e58fe..87842f880e3a0 100644 --- a/ext/dom/namednodemap.c +++ b/ext/dom/namednodemap.c @@ -126,7 +126,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_namednodemap_get_named_item) { - zval *id, *rv = NULL; + zval *id; int ret, namedlen=0; dom_object *intern; xmlNodePtr itemnode = NULL; @@ -166,7 +166,7 @@ PHP_FUNCTION(dom_namednodemap_get_named_item) } if (itemnode) { - DOM_RET_OBJ(rv, itemnode, &ret, objmap->baseobj); + DOM_RET_OBJ(itemnode, &ret, objmap->baseobj); return; } else { RETVAL_NULL(); @@ -200,7 +200,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_namednodemap_item) { - zval *id, *rv = NULL; + zval *id; long index; int ret; dom_object *intern; @@ -243,7 +243,7 @@ PHP_FUNCTION(dom_namednodemap_item) } if (itemnode) { - DOM_RET_OBJ(rv, itemnode, &ret, objmap->baseobj); + DOM_RET_OBJ(itemnode, &ret, objmap->baseobj); return; } } @@ -258,7 +258,7 @@ Since: DOM Level 2 */ PHP_FUNCTION(dom_namednodemap_get_named_item_ns) { - zval *id, *rv = NULL; + zval *id; int ret, namedlen=0, urilen=0; dom_object *intern; xmlNodePtr itemnode = NULL; @@ -298,7 +298,7 @@ PHP_FUNCTION(dom_namednodemap_get_named_item_ns) } if (itemnode) { - DOM_RET_OBJ(rv, itemnode, &ret, objmap->baseobj); + DOM_RET_OBJ(itemnode, &ret, objmap->baseobj); return; } else { RETVAL_NULL(); diff --git a/ext/dom/node.c b/ext/dom/node.c index 839c797bb6a55..690c887ac8822 100644 --- a/ext/dom/node.c +++ b/ext/dom/node.c @@ -429,7 +429,7 @@ int dom_node_parent_node_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object(nodeparent, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(nodeparent, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -498,7 +498,7 @@ int dom_node_first_child_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object(first, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(first, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -535,7 +535,7 @@ int dom_node_last_child_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object(last, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(last, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -569,7 +569,7 @@ int dom_node_previous_sibling_read(dom_object *obj, zval **retval TSRMLS_DC) return SUCCESS; } - if (NULL == (*retval = php_dom_create_object(prevsib, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(prevsib, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -602,7 +602,7 @@ int dom_node_next_sibling_read(dom_object *obj, zval **retval TSRMLS_DC) ALLOC_ZVAL(*retval); - if (NULL == (*retval = php_dom_create_object(nextsib, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object(nextsib, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -674,7 +674,7 @@ int dom_node_owner_document_read(dom_object *obj, zval **retval TSRMLS_DC) ALLOC_ZVAL(*retval); - if (NULL == (*retval = php_dom_create_object((xmlNodePtr) docp, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object((xmlNodePtr) docp, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -998,7 +998,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_node_insert_before) { - zval *id, *node, *ref = NULL, *rv = NULL; + zval *id, *node, *ref = NULL; xmlNodePtr child, new_child, parentp, refp; dom_object *intern, *childobj, *refpobj; int ret, stricterror; @@ -1087,7 +1087,7 @@ PHP_FUNCTION(dom_node_insert_before) xmlUnlinkNode((xmlNodePtr) lastattr); php_libxml_node_free_resource((xmlNodePtr) lastattr TSRMLS_CC); } else { - DOM_RET_OBJ(rv, child, &ret, intern); + DOM_RET_OBJ(child, &ret, intern); return; } } @@ -1129,7 +1129,7 @@ PHP_FUNCTION(dom_node_insert_before) xmlUnlinkNode((xmlNodePtr) lastattr); php_libxml_node_free_resource((xmlNodePtr) lastattr TSRMLS_CC); } else { - DOM_RET_OBJ(rv, child, &ret, intern); + DOM_RET_OBJ(child, &ret, intern); return; } } @@ -1148,7 +1148,7 @@ PHP_FUNCTION(dom_node_insert_before) dom_reconcile_ns(parentp->doc, new_child); - DOM_RET_OBJ(rv, new_child, &ret, intern); + DOM_RET_OBJ(new_child, &ret, intern); } /* }}} end dom_node_insert_before */ @@ -1212,9 +1212,6 @@ PHP_FUNCTION(dom_node_replace_child) } if (foundoldchild) { - xmlNodePtr node; - zval *rv = NULL; - if (newchild->type == XML_DOCUMENT_FRAG_NODE) { xmlNodePtr prevsib, nextsib; prevsib = oldchild->prev; @@ -1232,10 +1229,10 @@ PHP_FUNCTION(dom_node_replace_child) newchildobj->document = intern->document; php_libxml_increment_doc_ref((php_libxml_node_object *)newchildobj, NULL TSRMLS_CC); } - node = xmlReplaceNode(oldchild, newchild); + xmlReplaceNode(oldchild, newchild); dom_reconcile_ns(nodep->doc, newchild); } - DOM_RET_OBJ(rv, oldchild, &ret, intern); + DOM_RET_OBJ(oldchild, &ret, intern); return; } else { php_dom_throw_error(NOT_FOUND_ERR, dom_get_strict_error(intern->document) TSRMLS_CC); @@ -1283,9 +1280,8 @@ PHP_FUNCTION(dom_node_remove_child) while (children) { if (children == child) { - zval *rv = NULL; xmlUnlinkNode(child); - DOM_RET_OBJ(rv, child, &ret, intern); + DOM_RET_OBJ(child, &ret, intern); return; } children = children->next; @@ -1302,7 +1298,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_node_append_child) { - zval *id, *node, *rv = NULL; + zval *id, *node; xmlNodePtr child, nodep, new_child = NULL; dom_object *intern, *childobj; int ret, stricterror; @@ -1393,7 +1389,7 @@ PHP_FUNCTION(dom_node_append_child) dom_reconcile_ns(nodep->doc, new_child); - DOM_RET_OBJ(rv, new_child, &ret, intern); + DOM_RET_OBJ(new_child, &ret, intern); } /* }}} end dom_node_append_child */ @@ -1431,7 +1427,6 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core- */ PHP_FUNCTION(dom_node_clone_node) { - zval *rv = NULL; zval *id; xmlNode *n, *node; int ret; @@ -1483,7 +1478,7 @@ PHP_FUNCTION(dom_node_clone_node) intern = NULL; } - DOM_RET_OBJ(rv, node, &ret, intern); + DOM_RET_OBJ(node, &ret, intern); } /* }}} end dom_node_clone_node */ diff --git a/ext/dom/nodelist.c b/ext/dom/nodelist.c index f7d7d15450d91..5b968c0207844 100644 --- a/ext/dom/nodelist.c +++ b/ext/dom/nodelist.c @@ -104,7 +104,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-84 */ PHP_FUNCTION(dom_nodelist_item) { - zval *id, *rv = NULL; + zval *id; long index; int ret; dom_object *intern; @@ -163,7 +163,7 @@ PHP_FUNCTION(dom_nodelist_item) } if (itemnode) { - DOM_RET_OBJ(rv, itemnode, &ret, objmap->baseobj); + DOM_RET_OBJ(itemnode, &ret, objmap->baseobj); return; } } diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c index afbf1b9062b99..88726c7125d15 100644 --- a/ext/dom/php_dom.c +++ b/ext/dom/php_dom.c @@ -212,7 +212,7 @@ int dom_set_doc_classmap(php_libxml_ref_obj *document, zend_class_entry *basece, zend_hash_init(doc_props->classmap, 0, NULL, NULL, 0); } if (ce) { - return zend_hash_update(doc_props->classmap, basece->name, basece->name_length + 1, &ce, sizeof(ce), NULL); + return zend_hash_update(doc_props->classmap, basece->name, basece->name_length + 1, &ce, sizeof(zend_class_entry *), NULL); } else { zend_hash_del(doc_props->classmap, basece->name, basece->name_length + 1); } @@ -484,7 +484,6 @@ void *php_dom_export_node(zval *object TSRMLS_DC) /* {{{ */ Get a simplexml_element object from dom to allow for processing */ PHP_FUNCTION(dom_import_simplexml) { - zval *rv = NULL; zval *node; xmlNodePtr nodep = NULL; php_libxml_node_object *nodeobj; @@ -498,7 +497,7 @@ PHP_FUNCTION(dom_import_simplexml) nodep = php_libxml_import_node(node TSRMLS_CC); if (nodep && nodeobj && (nodep->type == XML_ELEMENT_NODE || nodep->type == XML_ATTRIBUTE_NODE)) { - DOM_RET_OBJ(rv, (xmlNodePtr) nodep, &ret, (dom_object *)nodeobj); + DOM_RET_OBJ((xmlNodePtr) nodep, &ret, (dom_object *)nodeobj); } else { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid Nodetype to import"); RETURN_NULL(); @@ -1233,7 +1232,7 @@ void php_dom_create_interator(zval *return_value, int ce_type TSRMLS_DC) /* {{{ /* }}} */ /* {{{ php_dom_create_object */ -PHP_DOM_EXPORT zval *php_dom_create_object(xmlNodePtr obj, int *found, zval *wrapper_in, zval *return_value, dom_object *domobj TSRMLS_DC) +PHP_DOM_EXPORT zval *php_dom_create_object(xmlNodePtr obj, int *found, zval *return_value, dom_object *domobj TSRMLS_DC) { zval *wrapper; zend_class_entry *ce; diff --git a/ext/dom/text.c b/ext/dom/text.c index b418345cb0778..b175e57933d6b 100644 --- a/ext/dom/text.c +++ b/ext/dom/text.c @@ -196,7 +196,7 @@ PHP_FUNCTION(dom_text_split_text) nnode->type = XML_TEXT_NODE; } - return_value = php_dom_create_object(nnode, &ret, NULL, return_value, intern TSRMLS_CC); + return_value = php_dom_create_object(nnode, &ret, return_value, intern TSRMLS_CC); } /* }}} end dom_text_split_text */ diff --git a/ext/dom/xml_common.h b/ext/dom/xml_common.h index 075d9ffb97bf1..1f47eb6e39c5c 100644 --- a/ext/dom/xml_common.h +++ b/ext/dom/xml_common.h @@ -54,7 +54,7 @@ typedef struct _dom_object { PHP_DOM_EXPORT extern zend_class_entry *dom_node_class_entry; PHP_DOM_EXPORT dom_object *php_dom_object_get_data(xmlNodePtr obj); -PHP_DOM_EXPORT zval *php_dom_create_object(xmlNodePtr obj, int *found, zval *in, zval* return_value, dom_object *domobj TSRMLS_DC); +PHP_DOM_EXPORT zval *php_dom_create_object(xmlNodePtr obj, int *found, zval* return_value, dom_object *domobj TSRMLS_DC); PHP_DOM_EXPORT xmlNodePtr dom_object_get_node(dom_object *obj); #define DOM_XMLNS_NAMESPACE \ @@ -78,8 +78,8 @@ PHP_DOM_EXPORT xmlNodePtr dom_object_get_node(dom_object *obj); } \ } -#define DOM_RET_OBJ(zval, obj, ret, domobject) \ - if (NULL == (zval = php_dom_create_object(obj, ret, zval, return_value, domobject TSRMLS_CC))) { \ +#define DOM_RET_OBJ(obj, ret, domobject) \ + if (!php_dom_create_object(obj, ret, return_value, domobject TSRMLS_CC)) { \ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); \ RETURN_FALSE; \ } diff --git a/ext/dom/xpath.c b/ext/dom/xpath.c index ba2b972518df0..251f2f75ecf27 100644 --- a/ext/dom/xpath.c +++ b/ext/dom/xpath.c @@ -164,7 +164,7 @@ static void dom_xpath_ext_function_php(xmlXPathParserContextPtr ctxt, int nargs, node->parent = nsparent; node->ns = curns; } - child = php_dom_create_object(node, &ret, NULL, child, (dom_object *)intern TSRMLS_CC); + child = php_dom_create_object(node, &ret, child, (dom_object *)intern TSRMLS_CC); add_next_index_zval(args[i], child); } } @@ -329,7 +329,7 @@ int dom_xpath_document_read(dom_object *obj, zval **retval TSRMLS_DC) } ALLOC_ZVAL(*retval); - if (NULL == (*retval = php_dom_create_object((xmlNodePtr) docp, &ret, NULL, *retval, obj TSRMLS_CC))) { + if (NULL == (*retval = php_dom_create_object((xmlNodePtr) docp, &ret, *retval, obj TSRMLS_CC))) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot create required DOM object"); return FAILURE; } @@ -492,7 +492,7 @@ static void php_xpath_eval(INTERNAL_FUNCTION_PARAMETERS, int type) /* {{{ */ node->parent = nsparent; node->ns = curns; } - child = php_dom_create_object(node, &ret, NULL, child, (dom_object *)intern TSRMLS_CC); + child = php_dom_create_object(node, &ret, child, (dom_object *)intern TSRMLS_CC); add_next_index_zval(retval, child); } } diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c index c1f1712efe864..f756746333378 100644 --- a/ext/xmlreader/php_xmlreader.c +++ b/ext/xmlreader/php_xmlreader.c @@ -1133,7 +1133,7 @@ Moves the position of the current instance to the next node in the stream. */ PHP_METHOD(xmlreader, expand) { #ifdef HAVE_DOM - zval *id, *rv = NULL, *basenode = NULL; + zval *id, *basenode = NULL; int ret; xmlreader_object *intern; xmlNode *node, *nodec; @@ -1163,7 +1163,7 @@ PHP_METHOD(xmlreader, expand) php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Cannot expand this node type"); RETURN_FALSE; } else { - DOM_RET_OBJ(rv, nodec, &ret, (dom_object *)domobj); + DOM_RET_OBJ(nodec, &ret, (dom_object *)domobj); } } } else { From f8154b02886a989feabbb2097cb0be125bad1108 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Mon, 8 Aug 2011 14:52:34 +0000 Subject: [PATCH 0512/2394] Fix typo --- Zend/zend_builtin_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index d507b6f5fe164..3232bfa0d4a17 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1821,7 +1821,7 @@ ZEND_FUNCTION(create_function) function_name[0] = '\0'; do { - function_name_length = 1 + snprintf(function_name + 1, sizeof("0lambda_")+MAX_LENGTH_OF_LONG, "lambda_%d", ++EG(lambda_count)); + function_name_length = 1 + snprintf(function_name + 1, sizeof("lambda_")+MAX_LENGTH_OF_LONG, "lambda_%d", ++EG(lambda_count)); } while (zend_hash_add(EG(function_table), function_name, function_name_length+1, &new_function, sizeof(zend_function), NULL)==FAILURE); zend_hash_del(EG(function_table), LAMBDA_TEMP_FUNCNAME, sizeof(LAMBDA_TEMP_FUNCNAME)); RETURN_STRINGL(function_name, function_name_length, 0); From 022d279a989aa795e9271e656715e541f7275269 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 8 Aug 2011 16:06:40 +0000 Subject: [PATCH 0513/2394] Fixed build --- ext/xsl/xsltprocessor.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 2aa4479e27f96..ff3808bb4f7bd 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -620,7 +620,7 @@ URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html# */ PHP_FUNCTION(xsl_xsltprocessor_transform_to_doc) { - zval *id, *rv = NULL, *docp = NULL; + zval *id, *docp = NULL; xmlDoc *newdocp; xsltStylesheetPtr sheetp; int ret, ret_class_len=0; @@ -664,7 +664,7 @@ PHP_FUNCTION(xsl_xsltprocessor_transform_to_doc) php_libxml_increment_doc_ref(interndoc, newdocp TSRMLS_CC); php_libxml_increment_node_ptr(interndoc, (xmlNodePtr)newdocp, (void *)interndoc TSRMLS_CC); } else { - DOM_RET_OBJ(rv, (xmlNodePtr) newdocp, &ret, NULL); + DOM_RET_OBJ((xmlNodePtr) newdocp, &ret, NULL); } } else { RETURN_FALSE; From fee9fe03343ab7943fe70b03484492bc782e711c Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Mon, 8 Aug 2011 16:14:30 +0000 Subject: [PATCH 0514/2394] reduced memory footprint for codepages. --- ext/mbstring/libmbfl/filters/mbfilter_hz.c | 1 + ext/mbstring/libmbfl/filters/mbfilter_sjis.c | 3 + ext/mbstring/libmbfl/filters/mbfilter_uhc.c | 1 + .../libmbfl/filters/unicode_table_cp932_ext.h | 35 ++++++-- .../libmbfl/filters/unicode_table_cp936.h | 85 ++++++++++++------ .../libmbfl/filters/unicode_table_jis.h | 57 ++++++++---- .../libmbfl/filters/unicode_table_uhc.h | 90 +++++++++++++------ 7 files changed, 194 insertions(+), 78 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_hz.c b/ext/mbstring/libmbfl/filters/mbfilter_hz.c index 81cea2bb3a1d3..cecce3965972a 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_hz.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_hz.c @@ -34,6 +34,7 @@ #include "mbfilter.h" #include "mbfilter_hz.h" +#define UNICODE_TABLE_CP936_DEF #include "unicode_table_cp936.h" static int mbfl_filt_ident_hz(int c, mbfl_identify_filter *filter); diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis.c index b74fca21d5652..61671ade9eb0c 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis.c @@ -34,6 +34,9 @@ #include "mbfilter.h" #include "mbfilter_sjis.h" +#define UNICODE_TABLE_CP932_DEF +#define UNICODE_TABLE_JIS_DEF + #include "unicode_table_cp932_ext.h" #include "unicode_table_jis.h" diff --git a/ext/mbstring/libmbfl/filters/mbfilter_uhc.c b/ext/mbstring/libmbfl/filters/mbfilter_uhc.c index c72d93f5fb758..86765b2ece3f2 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_uhc.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_uhc.c @@ -33,6 +33,7 @@ #include "mbfilter.h" #include "mbfilter_uhc.h" +#define UNICODE_TABLE_UHC_DEF #include "unicode_table_uhc.h" static int mbfl_filt_ident_uhc(int c, mbfl_identify_filter *filter); diff --git a/ext/mbstring/libmbfl/filters/unicode_table_cp932_ext.h b/ext/mbstring/libmbfl/filters/unicode_table_cp932_ext.h index c948dfa16b3c4..b685713142263 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_cp932_ext.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_cp932_ext.h @@ -25,7 +25,9 @@ #ifndef UNICODE_TABLE_CP932_EXT_H #define UNICODE_TABLE_CP932_EXT_H -static const unsigned short cp932ext1_ucs_table[] = { +#ifdef UNICODE_TABLE_CP932_DEF + +const unsigned short cp932ext1_ucs_table[] = { /* ku 13 */ 0x2460,0x2461,0x2462,0x2463,0x2464,0x2465,0x2466,0x2467, 0x2468,0x2469,0x246A,0x246B,0x246C,0x246D,0x246E,0x246F, @@ -40,10 +42,10 @@ static const unsigned short cp932ext1_ucs_table[] = { 0x2261,0x222B,0x222E,0x2211,0x221A,0x22A5,0x2220,0x221F, 0x22BF,0x2235,0x2229,0x222A,0x0000,0x0000 }; -static const int cp932ext1_ucs_table_min = (13 - 1)*94; -static const int cp932ext1_ucs_table_max = (13 - 1)*94 + (sizeof (cp932ext1_ucs_table) / sizeof (unsigned short)); +const int cp932ext1_ucs_table_min = (13 - 1)*94; +const int cp932ext1_ucs_table_max = (13 - 1)*94 + (sizeof (cp932ext1_ucs_table) / sizeof (unsigned short)); -static const unsigned short cp932ext2_ucs_table[] = { +const unsigned short cp932ext2_ucs_table[] = { /* ku 89 */ 0x7E8A,0x891C,0x9348,0x9288,0x84DC,0x4FC9,0x70BB,0x6631, 0x68C8,0x92F9,0x66FB,0x5F45,0x4E28,0x4EE1,0x4EFC,0x4F00, @@ -100,10 +102,10 @@ static const unsigned short cp932ext2_ucs_table[] = { 0x2170,0x2171,0x2172,0x2173,0x2174,0x2175,0x2176,0x2177, 0x2178,0x2179,0xFFE2,0xFFE4,0xFF07,0xFF02 }; -static const int cp932ext2_ucs_table_min = (89 - 1)*94; -static const int cp932ext2_ucs_table_max = (89 - 1)*94 + (sizeof (cp932ext2_ucs_table) / sizeof (unsigned short)); +const int cp932ext2_ucs_table_min = (89 - 1)*94; +const int cp932ext2_ucs_table_max = (89 - 1)*94 + (sizeof (cp932ext2_ucs_table) / sizeof (unsigned short)); -static const unsigned short cp932ext3_ucs_table[] = { +const unsigned short cp932ext3_ucs_table[] = { /* ku 115 */ 0x2170,0x2171,0x2172,0x2173,0x2174,0x2175,0x2176,0x2177, 0x2178,0x2179,0x2160,0x2161,0x2162,0x2163,0x2164,0x2165, @@ -164,7 +166,22 @@ static const unsigned short cp932ext3_ucs_table[] = { 0x9ADC,0x9B75,0x9B72,0x9B8F,0x9BB1,0x9BBB,0x9C00,0x9D70, 0x9D6B,0xFA2D,0x9E19,0x9ED1 }; -static const int cp932ext3_ucs_table_min = (115 - 1)*94; -static const int cp932ext3_ucs_table_max = (115 - 1)*94 + (sizeof (cp932ext3_ucs_table) / sizeof (unsigned short)); +const int cp932ext3_ucs_table_min = (115 - 1)*94; +const int cp932ext3_ucs_table_max = (115 - 1)*94 + (sizeof (cp932ext3_ucs_table) / sizeof (unsigned short)); + +#else + +extern const unsigned short cp932ext1_ucs_table[]; +extern const unsigned short cp932ext2_ucs_table[]; +extern const unsigned short cp932ext3_ucs_table[]; + +extern const int cp932ext1_ucs_table_min; +extern const int cp932ext1_ucs_table_max; +extern const int cp932ext2_ucs_table_min; +extern const int cp932ext2_ucs_table_max; +extern const int cp932ext3_ucs_table_min; +extern const int cp932ext3_ucs_table_max; + +#endif #endif /* UNICODE_TABLE_CP932_EXT_H */ diff --git a/ext/mbstring/libmbfl/filters/unicode_table_cp936.h b/ext/mbstring/libmbfl/filters/unicode_table_cp936.h index aa024d1a45fa8..9ae8ae3669e57 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_cp936.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_cp936.h @@ -28,8 +28,9 @@ /* * Unicode table */ +#ifdef UNICODE_TABLE_CP936_DEF -static const unsigned short cp936_ucs_table[] = { +const unsigned short cp936_ucs_table[] = { /* 0x8100 */ 0x4e02,0x4e04,0x4e05,0x4e06,0x4e0f,0x4e12,0x4e17,0x4e1f, 0x4e20,0x4e21,0x4e23,0x4e26,0x4e29,0x4e2e,0x4e2f,0x4e31, @@ -3159,11 +3160,11 @@ static const unsigned short cp936_ucs_table[] = { 0xfa0c,0xfa0d,0xfa0e,0xfa0f,0xfa11,0xfa13,0xfa14,0xfa18, 0xfa1f,0xfa20,0xfa21,0xfa23,0xfa24,0xfa27,0xfa28,0xfa29}; -static const int cp936_ucs_table_size = (sizeof(cp936_ucs_table)/sizeof(unsigned short)); +const int cp936_ucs_table_size = (sizeof(cp936_ucs_table)/sizeof(unsigned short)); /* UCS -> CP936 */ -static const unsigned short ucs_a1_cp936_table[] = { +const unsigned short ucs_a1_cp936_table[] = { 0x0000,0x0001,0x0002,0x0003,0x0004,0x0005,0x0006,0x0007, 0x0008,0x0009,0x000a,0x000b,0x000c,0x000d,0x000e,0x000f, 0x0010,0x0011,0x0012,0x0013,0x0014,0x0015,0x0016,0x0017, @@ -3308,11 +3309,11 @@ static const unsigned short ucs_a1_cp936_table[] = { 0xa7ea,0xa7eb,0xa7ec,0xa7ed,0xa7ee,0xa7ef,0xa7f0,0xa7f1, 0x0000,0xa7d7}; -static const int ucs_a1_cp936_table_min = 0x0000; -static const int ucs_a1_cp936_table_max = 0x0000 + (sizeof (ucs_a1_cp936_table) / sizeof (unsigned short)); +const int ucs_a1_cp936_table_min = 0x0000; +const int ucs_a1_cp936_table_max = 0x0000 + (sizeof (ucs_a1_cp936_table) / sizeof (unsigned short)); /* 0x2000 */ -static const unsigned short ucs_a2_cp936_table[] = { +const unsigned short ucs_a2_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0xa95c,0x0000,0x0000,0xa843,0xa1aa,0xa844,0xa1ac,0x0000, @@ -3544,10 +3545,10 @@ static const unsigned short ucs_a2_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000 }; -static const int ucs_a2_cp936_table_min = 0x2000; -static const int ucs_a2_cp936_table_max = 0x2000 + (sizeof (ucs_a2_cp936_table) / sizeof (unsigned short)); +const int ucs_a2_cp936_table_min = 0x2000; +const int ucs_a2_cp936_table_max = 0x2000 + (sizeof (ucs_a2_cp936_table) / sizeof (unsigned short)); -static const unsigned short ucs_a3_cp936_table[] = { +const unsigned short ucs_a3_cp936_table[] = { /* 0x2f00 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -3714,11 +3715,11 @@ static const unsigned short ucs_a3_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000 }; -static const int ucs_a3_cp936_table_min = 0x2f00; -static const int ucs_a3_cp936_table_max = 0x2f00 + (sizeof (ucs_a3_cp936_table) / sizeof (unsigned short)); +const int ucs_a3_cp936_table_min = 0x2f00; +const int ucs_a3_cp936_table_max = 0x2f00 + (sizeof (ucs_a3_cp936_table) / sizeof (unsigned short)); /* 4d00h CJK Unified Ideographs (+ Extension A) */ -static const unsigned short ucs_i_cp936_table[] = { +const unsigned short ucs_i_cp936_table[] = { /* 0x4d00 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -6377,13 +6378,13 @@ static const unsigned short ucs_i_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000 }; /* 9fffh */ -static const int ucs_i_cp936_table_min = 0x4d00; -static const int ucs_i_cp936_table_max = 0x4d00 + (sizeof (ucs_i_cp936_table) / sizeof (unsigned short)); +const int ucs_i_cp936_table_min = 0x4d00; +const int ucs_i_cp936_table_max = 0x4d00 + (sizeof (ucs_i_cp936_table) / sizeof (unsigned short)); /* 0xf900 CJK Compatibility Ideographs */ -static const unsigned short ucs_ci_cp936_table[] = { +const unsigned short ucs_ci_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -6423,33 +6424,33 @@ static const unsigned short ucs_ci_cp936_table[] = { 0xfe47,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xfe48, 0xfe49,0xfe4a,0x0000,0xfe4b,0xfe4c,0x0000,0x0000,0xfe4d, 0xfe4e,0xfe4f,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000}; -static const int ucs_ci_cp936_table_min = 0xf900; -static const int ucs_ci_cp936_table_max = 0xf900 + (sizeof (ucs_ci_cp936_table) / sizeof (unsigned short)); +const int ucs_ci_cp936_table_min = 0xf900; +const int ucs_ci_cp936_table_max = 0xf900 + (sizeof (ucs_ci_cp936_table) / sizeof (unsigned short)); /* FE30h CJK Compatibility Forms */ -static const unsigned short ucs_cf_cp936_table[] = { +const unsigned short ucs_cf_cp936_table[] = { 0xa955,0xa6f2,0x0000,0xa6f4,0xa6f5,0xa6e0,0xa6e1,0xa6f0, 0xa6f1,0xa6e2,0xa6e3,0xa6ee,0xa6ef,0xa6e6,0xa6e7,0xa6e4, 0xa6e5,0xa6e8,0xa6e9,0xa6ea,0xa6eb,0x0000,0x0000,0x0000, 0x0000,0xa968,0xa969,0xa96a,0xa96b,0xa96c,0xa96d,0xa96e}; -static const int ucs_cf_cp936_table_min = 0xfe30; -static const int ucs_cf_cp936_table_max = 0xfe30 + (sizeof (ucs_cf_cp936_table) / sizeof (unsigned short)); +const int ucs_cf_cp936_table_min = 0xfe30; +const int ucs_cf_cp936_table_max = 0xfe30 + (sizeof (ucs_cf_cp936_table) / sizeof (unsigned short)); /* FE50h Small Form Variants */ -static const unsigned short ucs_sfv_cp936_table[] = { +const unsigned short ucs_sfv_cp936_table[] = { 0xa96f,0xa970,0xa971,0x0000,0xa972,0xa973,0xa974,0xa975, 0x0000,0xa976,0xa977,0xa978,0xa979,0xa97a,0xa97b,0xa97c, 0xa97d,0xa97e,0xa980,0xa981,0xa982,0xa983,0xa984,0x0000, 0xa985,0xa986,0xa987,0xa988,0x0000,0x0000,0x0000,0x0000}; -static const int ucs_sfv_cp936_table_min = 0xfe50; -static const int ucs_sfv_cp936_table_max = 0xfe50 + (sizeof (ucs_sfv_cp936_table) / sizeof (unsigned short)); +const int ucs_sfv_cp936_table_min = 0xfe50; +const int ucs_sfv_cp936_table_max = 0xfe50 + (sizeof (ucs_sfv_cp936_table) / sizeof (unsigned short)); /* FF00h Halfwidth and Fullwidth Forms */ -static const unsigned short ucs_hff_cp936_table[] = { +const unsigned short ucs_hff_cp936_table[] = { 0x0000,0xa3a1,0xa3a2,0xa3a3,0xa1e7,0xa3a5,0xa3a6,0xa3a7, 0xa3a8,0xa3a9,0xa3aa,0xa3ab,0xa3ac,0xa3ad,0xa3ae,0xa3af, 0xa3b0,0xa3b1,0xa3b2,0xa3b3,0xa3b4,0xa3b5,0xa3b6,0xa3b7, @@ -6483,7 +6484,39 @@ static const unsigned short ucs_hff_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000 }; -static const int ucs_hff_cp936_table_min = 0xff00; -static const int ucs_hff_cp936_table_max = 0xff00 + (sizeof (ucs_hff_cp936_table) / sizeof (unsigned short)); +const int ucs_hff_cp936_table_min = 0xff00; +const int ucs_hff_cp936_table_max = 0xff00 + (sizeof (ucs_hff_cp936_table) / sizeof (unsigned short)); + +#else + +extern const unsigned short cp936_ucs_table[]; +extern const unsigned short ucs_a1_cp936_table[]; +extern const unsigned short ucs_a2_cp936_table[]; +extern const unsigned short ucs_a3_cp936_table[]; +extern const unsigned short ucs_i_cp936_table[]; +extern const unsigned short ucs_ci_cp936_table[]; +extern const unsigned short ucs_cf_cp936_table[]; +extern const unsigned short ucs_sfv_cp936_table[]; +extern const unsigned short ucs_hff_cp936_table[]; + +extern const int cp936_ucs_table_size; +extern const int ucs_a1_cp936_table_min; +extern const int ucs_a1_cp936_table_max; +extern const int ucs_a2_cp936_table_min; +extern const int ucs_a2_cp936_table_max; +extern const int ucs_a3_cp936_table_min; +extern const int ucs_a3_cp936_table_max; +extern const int ucs_i_cp936_table_min; +extern const int ucs_i_cp936_table_max; +extern const int ucs_ci_cp936_table_min; +extern const int ucs_ci_cp936_table_max; +extern const int ucs_cf_cp936_table_min; +extern const int ucs_cf_cp936_table_max; +extern const int ucs_sfv_cp936_table_min; +extern const int ucs_sfv_cp936_table_max; +extern const int ucs_hff_cp936_table_min; +extern const int ucs_hff_cp936_table_max; + +#endif #endif /* UNICODE_TABLE_CP936_H */ diff --git a/ext/mbstring/libmbfl/filters/unicode_table_jis.h b/ext/mbstring/libmbfl/filters/unicode_table_jis.h index 5671c4e8513a0..d0c880a87a48e 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_jis.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_jis.h @@ -27,10 +27,12 @@ #ifndef UNICODE_TABLE_JIS_H #define UNICODE_TABLE_JIS_H +#ifdef UNICODE_TABLE_JIS_DEF + /* * Unicode table */ -static const unsigned short jisx0208_ucs_table[] = { +const unsigned short jisx0208_ucs_table[] = { /* ku 1 */ 0x3000,0x3001,0x3002,0xFF0C,0xFF0E,0x30FB,0xFF1A,0xFF1B, 0xFF1F,0xFF01,0x309B,0x309C,0x00B4,0xFF40,0x00A8,0xFF3E, @@ -1197,9 +1199,9 @@ static const unsigned short jisx0208_ucs_table[] = { 0x582F,0x69C7,0x9059,0x7464,0x51DC,0x7199 }; -static const int jisx0208_ucs_table_size = (sizeof (jisx0208_ucs_table) / sizeof (unsigned short)); +const int jisx0208_ucs_table_size = (sizeof (jisx0208_ucs_table) / sizeof (unsigned short)); -static const unsigned short jisx0212_ucs_table[] = { +const unsigned short jisx0212_ucs_table[] = { /* ku 1 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -2276,9 +2278,9 @@ static const unsigned short jisx0212_ucs_table[] = { 0x9FA2,0x9FA3,0x9FA5 }; -static const int jisx0212_ucs_table_size = (sizeof (jisx0212_ucs_table) / sizeof (unsigned short)); +const int jisx0212_ucs_table_size = (sizeof (jisx0212_ucs_table) / sizeof (unsigned short)); -static const unsigned short ucs_a1_jis_table[] = { +const unsigned short ucs_a1_jis_table[] = { /* 0000h */ 0x0000,0x0001,0x0002,0x0003,0x0004,0x0005,0x0006,0x0007, 0x0008,0x0009,0x000A,0x000B,0x000C,0x000D,0x000E,0x000F, @@ -2429,11 +2431,11 @@ static const unsigned short ucs_a1_jis_table[] = { 0x0000,0x2757,0xA7F2,0xA7F3,0xA7F4,0xA7F5,0xA7F6,0xA7F7, 0xA7F8,0xA7F9,0xA7FA,0xA7FB,0xA7FC,0x0000,0xA7FD,0xA7FE }; -static const int ucs_a1_jis_table_min = 0x0000; -static const int ucs_a1_jis_table_max = 0x0000 + (sizeof (ucs_a1_jis_table) / sizeof (unsigned short)); +const int ucs_a1_jis_table_min = 0x0000; +const int ucs_a1_jis_table_max = 0x0000 + (sizeof (ucs_a1_jis_table) / sizeof (unsigned short)); -static const unsigned short ucs_a2_jis_table[] = { +const unsigned short ucs_a2_jis_table[] = { /* 2000h */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -3012,11 +3014,11 @@ static const unsigned short ucs_a2_jis_table[] = { 0x2570,0x2571,0x2572,0x2573,0x2574,0x2575,0x2576,0x0000, 0x0000,0x0000,0x0000,0x2126,0x213C,0x2133,0x2134,0x0000 }; -static const int ucs_a2_jis_table_min = 0x2000; -static const int ucs_a2_jis_table_max = 0x2000 + (sizeof (ucs_a2_jis_table) / sizeof (unsigned short)); +const int ucs_a2_jis_table_min = 0x2000; +const int ucs_a2_jis_table_max = 0x2000 + (sizeof (ucs_a2_jis_table) / sizeof (unsigned short)); -static const unsigned short ucs_i_jis_table[] = { +const unsigned short ucs_i_jis_table[] = { /* 4E00h */ 0x306C,0x437A,0xB0A1,0x3C37,0xB0A2,0xB0A3,0x0000,0x4B7C, 0x3E66,0x3B30,0x3E65,0x323C,0xB0A4,0x4954,0x4D3F,0x0000, @@ -5805,11 +5807,11 @@ static const unsigned short ucs_i_jis_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000 }; -static const int ucs_i_jis_table_min = 0x4E00; -static const int ucs_i_jis_table_max = 0x4E00 + (sizeof (ucs_i_jis_table) / sizeof (unsigned short)); +const int ucs_i_jis_table_min = 0x4E00; +const int ucs_i_jis_table_max = 0x4E00 + (sizeof (ucs_i_jis_table) / sizeof (unsigned short)); -static const unsigned short ucs_r_jis_table[] = { +const unsigned short ucs_r_jis_table[] = { /* FF00h */ 0x0000,0x212A,0x0000,0x2174,0x2170,0x2173,0x2175,0x0000, 0x214A,0x214B,0x2176,0x215C,0x2124,0x0000,0x2125,0x213F, @@ -5841,7 +5843,30 @@ static const unsigned short ucs_r_jis_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x2131,0x0000,0x216F }; -static const int ucs_r_jis_table_min = 0xFF00; -static const int ucs_r_jis_table_max = 0xFF00 + (sizeof (ucs_r_jis_table) / sizeof (unsigned short)); +int ucs_r_jis_table_min = 0xFF00; +int ucs_r_jis_table_max = 0xFF00 + (sizeof (ucs_r_jis_table) / sizeof (unsigned short)); + +#else + +extern const unsigned short jisx0208_ucs_table[]; +extern const unsigned short jisx0212_ucs_table[]; +extern const unsigned short ucs_a1_jis_table[]; +extern const unsigned short ucs_a2_jis_table[]; +extern const unsigned short ucs_i_jis_table[]; +extern const unsigned short ucs_r_jis_table[]; + +extern const int jisx0208_ucs_table_size; +extern const int jisx0212_ucs_table_size; +extern const int ucs_a1_jis_table_min; +extern const int ucs_a1_jis_table_max; +extern const int ucs_a2_jis_table_min; +extern const int ucs_a2_jis_table_max; +extern const int ucs_i_jis_table_min; +extern const int ucs_i_jis_table_max; +extern int ucs_r_jis_table_min; +extern int ucs_r_jis_table_max; + +#endif + #endif /* UNICODE_TABLE_JIS_H */ diff --git a/ext/mbstring/libmbfl/filters/unicode_table_uhc.h b/ext/mbstring/libmbfl/filters/unicode_table_uhc.h index 802e120e08873..6b98c65b6fb19 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_uhc.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_uhc.h @@ -28,8 +28,9 @@ /* * Unicode table */ +#ifdef UNICODE_TABLE_UHC_DEF -static const unsigned short uhc1_ucs_table[] = { +const unsigned short uhc1_ucs_table[] = { 0xac02,0xac03,0xac05,0xac06,0xac0b,0xac0c,0xac0d,0xac0e, 0xac0f,0xac18,0xac1e,0xac1f,0xac21,0xac22,0xac23,0xac25, 0xac26,0xac27,0xac28,0xac29,0xac2a,0xac2b,0xac2e,0xac32, @@ -792,9 +793,9 @@ static const unsigned short uhc1_ucs_table[] = { 0xc89a,0xc89b,0xc89c,0xc89e,0xc8a0,0xc8a2,0xc8a3,0xc8a4 }; -static const int uhc1_ucs_table_size = (sizeof(uhc1_ucs_table)/sizeof(unsigned short)); +const int uhc1_ucs_table_size = (sizeof(uhc1_ucs_table)/sizeof(unsigned short)); -static const unsigned short uhc2_ucs_table[] = { +const unsigned short uhc2_ucs_table[] = { 0xc8a5,0xc8a6,0xc8a7,0xc8a9,0xc8aa,0xc8ab,0xc8ac,0xc8ad, 0xc8ae,0xc8af,0xc8b0,0xc8b1,0xc8b2,0xc8b3,0xc8b4,0xc8b5, 0xc8b6,0xc8b7,0xc8b8,0xc8b9,0xc8ba,0xc8bb,0xc8be,0xc8bf, @@ -1699,9 +1700,9 @@ static const unsigned short uhc2_ucs_table[] = { 0xd3d0,0xd3d8,0xd3e1,0xd3e3,0xd3ec,0xd3ed,0xd3f0,0xd3f4, 0xd3fc,0xd3fd,0xd3ff,0xd401}; -static const int uhc2_ucs_table_size = (sizeof(uhc2_ucs_table)/sizeof(unsigned short)); +const int uhc2_ucs_table_size = (sizeof(uhc2_ucs_table)/sizeof(unsigned short)); -static const unsigned short uhc3_ucs_table[] = { +const unsigned short uhc3_ucs_table[] = { 0xd408,0xd41d,0xd440,0xd444,0xd45c,0xd460,0xd464,0xd46d, 0xd46f,0xd478,0xd479,0xd47c,0xd47f,0xd480,0xd482,0xd488, 0xd489,0xd48b,0xd48d,0xd494,0xd4a9,0xd4cc,0xd4d0,0xd4d4, @@ -2350,10 +2351,10 @@ static const unsigned short uhc3_ucs_table[] = { 0x665e,0x66e6,0x7199,0x71b9,0x71ba,0x72a7,0x79a7,0x7a00, 0x7fb2,0x8a70}; -static const int uhc3_ucs_table_size = (sizeof(uhc3_ucs_table)/sizeof(unsigned short)); +const int uhc3_ucs_table_size = (sizeof(uhc3_ucs_table)/sizeof(unsigned short)); /* UCS -> UHC */ -static const unsigned short ucs_a1_uhc_table[] = { +const unsigned short ucs_a1_uhc_table[] = { 0x0000,0x0001,0x0002,0x0003,0x0004,0x0005,0x0006,0x0007, 0x0008,0x0009,0x000a,0x000b,0x000c,0x000d,0x000e,0x000f, 0x0010,0x0011,0x0012,0x0013,0x0014,0x0015,0x0016,0x0017, @@ -2498,10 +2499,10 @@ static const unsigned short ucs_a1_uhc_table[] = { 0xacea,0xaceb,0xacec,0xaced,0xacee,0xacef,0xacf0,0xacf1, 0x0000,0xacd7}; -static const int ucs_a1_uhc_table_min = 0x0000; -static const int ucs_a1_uhc_table_max = 0x0000 + (sizeof(ucs_a1_uhc_table)/sizeof(unsigned short)); +const int ucs_a1_uhc_table_min = 0x0000; +const int ucs_a1_uhc_table_max = 0x0000 + (sizeof(ucs_a1_uhc_table)/sizeof(unsigned short)); -static const unsigned short ucs_a2_uhc_table[] = { +const unsigned short ucs_a2_uhc_table[] = { /* 0x2000 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -2714,10 +2715,10 @@ static const unsigned short ucs_a2_uhc_table[] = { 0xa2bc,0xa2bd,0x0000,0xa2c0,0xa2bb,0xa2be,0x0000,0xa2bf, 0xa2cd,0xa2db,0xa2dc,0x0000,0xa2dd,0xa2da}; -static const int ucs_a2_uhc_table_min = 0x2000; -static const int ucs_a2_uhc_table_max = 0x2000 + (sizeof(ucs_a2_uhc_table)/sizeof(unsigned short)); +const int ucs_a2_uhc_table_min = 0x2000; +const int ucs_a2_uhc_table_max = 0x2000 + (sizeof(ucs_a2_uhc_table)/sizeof(unsigned short)); -static const unsigned short ucs_a3_uhc_table[] = { +const unsigned short ucs_a3_uhc_table[] = { /* 0x2f00 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -2878,10 +2879,10 @@ static const unsigned short ucs_a3_uhc_table[] = { 0xa7ea,0x0000,0x0000,0xa7eb,0x0000,0x0000,0xa7df,0x0000, 0xa2e4,0x0000,0x0000,0xa7e4,0xa7ee,0xa7e9}; -static const int ucs_a3_uhc_table_min = 0x2f00; -static const int ucs_a3_uhc_table_max = 0x2f00 + (sizeof(ucs_a3_uhc_table)/sizeof(unsigned short)); +const int ucs_a3_uhc_table_min = 0x2f00; +const int ucs_a3_uhc_table_max = 0x2f00 + (sizeof(ucs_a3_uhc_table)/sizeof(unsigned short)); -static const unsigned short ucs_i_uhc_table[] = { +const unsigned short ucs_i_uhc_table[] = { /* 0x4d00 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -5591,10 +5592,10 @@ static const unsigned short ucs_i_uhc_table[] = { 0xdbc2,0x0000,0x0000,0x0000,0x0000,0xcafe,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0xcfcf}; -static const int ucs_i_uhc_table_min = 0x4d00; -static const int ucs_i_uhc_table_max = 0x4d00 + (sizeof(ucs_i_uhc_table)/sizeof(unsigned short)); +const int ucs_i_uhc_table_min = 0x4d00; +const int ucs_i_uhc_table_max = 0x4d00 + (sizeof(ucs_i_uhc_table)/sizeof(unsigned short)); -static const unsigned short ucs_s_uhc_table[] = { +const unsigned short ucs_s_uhc_table[] = { /* 0xab00 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -7070,10 +7071,10 @@ static const unsigned short ucs_s_uhc_table[] = { 0xc64f,0xc650,0xc651,0xc652}; -static const int ucs_s_uhc_table_min = 0xab00; -static const int ucs_s_uhc_table_max = 0xab00 + (sizeof(ucs_s_uhc_table)/sizeof(unsigned short)); +const int ucs_s_uhc_table_min = 0xab00; +const int ucs_s_uhc_table_max = 0xab00 + (sizeof(ucs_s_uhc_table)/sizeof(unsigned short)); -static const unsigned short ucs_r1_uhc_table[] = { +const unsigned short ucs_r1_uhc_table[] = { /* 0xf800 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -7142,10 +7143,10 @@ static const unsigned short ucs_r1_uhc_table[] = { 0xf4ee,0xf6f4,0xf6f6,0xf7b8,0xf7c8,0xf7d3,0xf8db,0xf8f0, 0xfaa1,0xfaa2,0xfae6,0xfca9}; -static const int ucs_r1_uhc_table_min = 0xf800; -static const int ucs_r1_uhc_table_max = 0xf800 + (sizeof(ucs_r1_uhc_table)/sizeof(unsigned short)); +const int ucs_r1_uhc_table_min = 0xf800; +const int ucs_r1_uhc_table_max = 0xf800 + (sizeof(ucs_r1_uhc_table)/sizeof(unsigned short)); -static const unsigned short ucs_r2_uhc_table[] = { +const unsigned short ucs_r2_uhc_table[] = { /* 0xff00 */ 0x0000,0xa3a1,0xa3a2,0xa3a3,0xa3a4,0xa3a5,0xa3a6,0xa3a7, 0xa3a8,0xa3a9,0xa3aa,0xa3ab,0xa3ac,0xa3ad,0xa3ae,0xa3af, @@ -7177,9 +7178,44 @@ static const unsigned short ucs_r2_uhc_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0xa1cb,0xa1cc,0xa1fe,0xa3fe,0x0000,0xa1cd,0xa3dc}; -static const int ucs_r2_uhc_table_min = 0xff00; -static const int ucs_r2_uhc_table_max = 0xff00 + (sizeof (ucs_r2_uhc_table) / sizeof (unsigned short)); +const int ucs_r2_uhc_table_min = 0xff00; +const int ucs_r2_uhc_table_max = 0xff00 + (sizeof (ucs_r2_uhc_table) / sizeof (unsigned short)); +#else + +extern const unsigned short uhc1_ucs_table[]; +extern const unsigned short uhc2_ucs_table[]; +extern const unsigned short uhc3_ucs_table[]; +extern const unsigned short ucs_a1_uhc_table[]; +extern const unsigned short ucs_a2_uhc_table[]; +extern const unsigned short ucs_a3_uhc_table[]; +extern const unsigned short ucs_i_uhc_table[]; +extern const unsigned short ucs_s_uhc_table[]; +extern const unsigned short ucs_r1_uhc_table[]; +extern const unsigned short ucs_r2_uhc_table[]; + +extern const int uhc1_ucs_table_size; +extern const int uhc2_ucs_table_size; +extern const int uhc3_ucs_table_size; +extern const int ucs_a1_uhc_table_min; +extern const int ucs_a1_uhc_table_max; +extern const int ucs_a2_uhc_table_min; +extern const int ucs_a2_uhc_table_max; +extern const int ucs_a3_uhc_table_min; +extern const int ucs_a3_uhc_table_max; +extern const int ucs_i_uhc_table_min; +extern const int ucs_i_uhc_table_max; +extern const int ucs_s_uhc_table_min; +extern const int ucs_s_uhc_table_max; +extern const int ucs_r1_uhc_table_min; +extern const int ucs_r1_uhc_table_max; +extern const int ucs_r2_uhc_table_min; +extern const int ucs_r2_uhc_table_max; + + + + +#endif From e35f670e2d77eca3da4854e6ee609e92e264992f Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 8 Aug 2011 16:49:43 +0000 Subject: [PATCH 0515/2394] Another build fix relating to previous DOM commit --- ext/xsl/xsltprocessor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index ff3808bb4f7bd..d0baa1fdcf2bb 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -280,7 +280,7 @@ static void xsl_ext_function_php(xmlXPathParserContextPtr ctxt, int nargs, int t node->parent = nsparent; node->ns = curns; } - child = php_dom_create_object(node, &ret, NULL, child, domintern TSRMLS_CC); + child = php_dom_create_object(node, &ret, child, domintern TSRMLS_CC); add_next_index_zval(args[i], child); } } From 61f80c9b08631b911aade4c4995c99c01ab4a0a6 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 8 Aug 2011 16:57:46 +0000 Subject: [PATCH 0516/2394] Remove unnecessary(no sense) memset and making the static analyzer silent --- ext/fileinfo/libmagic/softmagic.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/fileinfo/libmagic/softmagic.c b/ext/fileinfo/libmagic/softmagic.c index 0a06d00f8af1a..da65bfcf83e9e 100644 --- a/ext/fileinfo/libmagic/softmagic.c +++ b/ext/fileinfo/libmagic/softmagic.c @@ -1652,7 +1652,6 @@ convert_libmagic_pattern(zval *pattern, int options) char *t; t = (char *) safe_emalloc(Z_STRLEN_P(pattern), 2, 5); - memset(t, '\0', sizeof(t)); t[j++] = '~'; From 177645fd0543c50a1429d586a14e8e09d7413804 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Tue, 9 Aug 2011 00:40:45 +0000 Subject: [PATCH 0517/2394] - Elided unused argument in internal linkage function. --- ext/standard/html.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ext/standard/html.c b/ext/standard/html.c index faec0dac98e6f..50bc307927d8d 100644 --- a/ext/standard/html.c +++ b/ext/standard/html.c @@ -1520,7 +1520,6 @@ PHP_FUNCTION(htmlentities) static inline void write_s3row_data( const entity_stage3_row *r, unsigned orig_cp, - unsigned uni_cp, enum entity_charset charset, zval *arr) { @@ -1636,7 +1635,7 @@ PHP_FUNCTION(get_html_translation_table) if (((code == '\'' && !(flags & ENT_HTML_QUOTE_SINGLE)) || (code == '"' && !(flags & ENT_HTML_QUOTE_DOUBLE)))) continue; - write_s3row_data(r, code, code, charset, return_value); + write_s3row_data(r, code, charset, return_value); } } } @@ -1658,7 +1657,7 @@ PHP_FUNCTION(get_html_translation_table) if (r->data.ent.entity == NULL) continue; - write_s3row_data(r, i, uni_cp, charset, return_value); + write_s3row_data(r, i, charset, return_value); } } } else { @@ -1677,7 +1676,7 @@ PHP_FUNCTION(get_html_translation_table) continue; /* charset is indifferent, used cs_8859_1 for efficiency */ - write_s3row_data(r, j, j, cs_8859_1, return_value); + write_s3row_data(r, j, cs_8859_1, return_value); } } } From 5998f27321ac914b37dc92ad5cd511cf5f690a4e Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Tue, 9 Aug 2011 02:37:02 +0000 Subject: [PATCH 0518/2394] Remove unused variable --- main/spprintf.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/main/spprintf.c b/main/spprintf.c index 8599d890eed24..79ba346fdff42 100644 --- a/main/spprintf.c +++ b/main/spprintf.c @@ -198,7 +198,6 @@ static size_t strnlen(const char *s, size_t maxlen) { static void xbuf_format_converter(smart_str *xbuf, const char *fmt, va_list ap) /* {{{ */ { char *s = NULL; - char *q; int s_len, free_zcopy; zval *zvp, zcopy; @@ -679,7 +678,7 @@ static void xbuf_format_converter(smart_str *xbuf, const char *fmt, va_list ap) s_len = strlen(s); - if (alternate_form && (q = strchr(s, '.')) == NULL) + if (alternate_form && (strchr(s, '.')) == NULL) s[s_len++] = '.'; break; From 71f76fe4d665c5f8ac9f6d3672f082f6d1510c63 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Tue, 9 Aug 2011 02:42:25 +0000 Subject: [PATCH 0519/2394] Remove unused variable --- main/snprintf.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/main/snprintf.c b/main/snprintf.c index 6e5a89a34cbd1..e623e821d3630 100644 --- a/main/snprintf.c +++ b/main/snprintf.c @@ -587,7 +587,6 @@ static int format_converter(register buffy * odp, const char *fmt, va_list ap) / int i; char *s = NULL; - char *q; int s_len, free_zcopy; zval *zvp, zcopy; @@ -1071,7 +1070,7 @@ static int format_converter(register buffy * odp, const char *fmt, va_list ap) / s_len = strlen(s); - if (alternate_form && (q = strchr(s, '.')) == NULL) { + if (alternate_form && (strchr(s, '.')) == NULL) { s[s_len++] = '.'; } break; From 956e1637846453beb5d6decedcb6135af0fc9be7 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 9 Aug 2011 05:11:19 +0000 Subject: [PATCH 0520/2394] Eliminated compiler's warnings and make static analyzer silent --- ext/fileinfo/fileinfo.c | 2 +- ext/fileinfo/libmagic.patch | 4 ++-- ext/fileinfo/libmagic/magic.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c index 6d8525c557d19..f173fb5ed61e8 100644 --- a/ext/fileinfo/fileinfo.c +++ b/ext/fileinfo/fileinfo.c @@ -388,7 +388,7 @@ static void _php_finfo_get_type(INTERNAL_FUNCTION_PARAMETERS, int mode, int mime long options = 0; char *ret_val = NULL, *buffer = NULL; int buffer_len; - struct php_fileinfo *finfo; + struct php_fileinfo *finfo = NULL; zval *zfinfo, *zcontext = NULL; zval *what; char mime_directory[] = "directory"; diff --git a/ext/fileinfo/libmagic.patch b/ext/fileinfo/libmagic.patch index 276bb011c5c11..a834c0039f0e8 100644 --- a/ext/fileinfo/libmagic.patch +++ b/ext/fileinfo/libmagic.patch @@ -2020,9 +2020,9 @@ diff -u libmagic.orig/magic.c libmagic/magic.c + if (!stream && inname) { + no_in_stream = 1; +#if PHP_API_VERSION < 20100412 -+ stream = php_stream_open_wrapper(inname, "rb", REPORT_ERRORS|ENFORCE_SAFE_MODE, NULL); ++ stream = php_stream_open_wrapper((char *)inname, "rb", REPORT_ERRORS|ENFORCE_SAFE_MODE, NULL); +#else -+ stream = php_stream_open_wrapper(inname, "rb", REPORT_ERRORS, NULL); ++ stream = php_stream_open_wrapper((char *)inname, "rb", REPORT_ERRORS, NULL); +#endif + } + diff --git a/ext/fileinfo/libmagic/magic.c b/ext/fileinfo/libmagic/magic.c index a8bf6d8880f17..51cc67209cac6 100644 --- a/ext/fileinfo/libmagic/magic.c +++ b/ext/fileinfo/libmagic/magic.c @@ -291,9 +291,9 @@ file_or_stream(struct magic_set *ms, const char *inname, php_stream *stream) if (!stream && inname) { no_in_stream = 1; #if PHP_API_VERSION < 20100412 - stream = php_stream_open_wrapper(inname, "rb", REPORT_ERRORS|ENFORCE_SAFE_MODE, NULL); + stream = php_stream_open_wrapper((char *)inname, "rb", REPORT_ERRORS|ENFORCE_SAFE_MODE, NULL); #else - stream = php_stream_open_wrapper(inname, "rb", REPORT_ERRORS, NULL); + stream = php_stream_open_wrapper((char *)inname, "rb", REPORT_ERRORS, NULL); #endif } From b61ea14729402c1f5f00bc810b34afccccdb0e50 Mon Sep 17 00:00:00 2001 From: Joey Smith Date: Tue, 9 Aug 2011 06:36:47 +0000 Subject: [PATCH 0521/2394] Fix an unchecked return - change was back-migrated from version 3.7.6.3 of sqlite.c from upstream. --- ext/sqlite3/libsqlite/sqlite3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sqlite3/libsqlite/sqlite3.c b/ext/sqlite3/libsqlite/sqlite3.c index 786a3ec62f02a..555c63697a336 100644 --- a/ext/sqlite3/libsqlite/sqlite3.c +++ b/ext/sqlite3/libsqlite/sqlite3.c @@ -17818,7 +17818,7 @@ SQLITE_API sqlite3_int64 sqlite3_soft_heap_limit64(sqlite3_int64 n){ sqlite3_int64 priorLimit; sqlite3_int64 excess; #ifndef SQLITE_OMIT_AUTOINIT - sqlite3_initialize(); + if( sqlite3_initialize() ) return 0; #endif sqlite3_mutex_enter(mem0.mutex); priorLimit = mem0.alarmThreshold; From 7402dee0149e1a7d7a380619cb381e7f7c4cb02c Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Tue, 9 Aug 2011 07:31:34 +0000 Subject: [PATCH 0522/2394] Update SQLite3 to the latest version --- ext/sqlite3/libsqlite/sqlite3.c | 7476 ++++++++++++++++++++----------- ext/sqlite3/libsqlite/sqlite3.h | 439 +- 2 files changed, 5315 insertions(+), 2600 deletions(-) diff --git a/ext/sqlite3/libsqlite/sqlite3.c b/ext/sqlite3/libsqlite/sqlite3.c index 555c63697a336..523eb20ac2292 100644 --- a/ext/sqlite3/libsqlite/sqlite3.c +++ b/ext/sqlite3/libsqlite/sqlite3.c @@ -4,7 +4,7 @@ /****************************************************************************** ** This file is an amalgamation of many separate C source files from SQLite -** version 3.7.6.3. By combining all the individual C code files into this +** version 3.7.7.1. By combining all the individual C code files into this ** single large file, the entire code can be compiled as a single translation ** unit. This allows many compilers to do optimizations that would not be ** possible if the files were compiled separately. Performance improvements @@ -654,9 +654,9 @@ extern "C" { ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ -#define SQLITE_VERSION "3.7.6.3" -#define SQLITE_VERSION_NUMBER 3007006 -#define SQLITE_SOURCE_ID "2011-05-19 13:26:54 ed1da510a239ea767a01dc332b667119fa3c908e" +#define SQLITE_VERSION "3.7.7.1" +#define SQLITE_VERSION_NUMBER 3007007 +#define SQLITE_SOURCE_ID "2011-06-28 17:39:05 af0d91adf497f5f36ec3813f04235a6e195a605f" /* ** CAPI3REF: Run-Time Library Version Numbers @@ -857,7 +857,7 @@ typedef int (*sqlite3_callback)(void*,int,char**, char**); ** argument. ^If the callback function of the 3rd argument to ** sqlite3_exec() is not NULL, then it is invoked for each result row ** coming out of the evaluated SQL statements. ^The 4th argument to -** to sqlite3_exec() is relayed through to the 1st argument of each +** sqlite3_exec() is relayed through to the 1st argument of each ** callback invocation. ^If the callback pointer to sqlite3_exec() ** is NULL, then no callback is ever invoked and result rows are ** ignored. @@ -922,7 +922,8 @@ SQLITE_API int sqlite3_exec( ** ** New error codes may be added in future versions of SQLite. ** -** See also: [SQLITE_IOERR_READ | extended result codes] +** See also: [SQLITE_IOERR_READ | extended result codes], +** [sqlite3_vtab_on_conflict()] [SQLITE_ROLLBACK | result codes]. */ #define SQLITE_OK 0 /* Successful result */ /* beginning-of-error-codes */ @@ -999,17 +1000,21 @@ SQLITE_API int sqlite3_exec( #define SQLITE_IOERR_SHMOPEN (SQLITE_IOERR | (18<<8)) #define SQLITE_IOERR_SHMSIZE (SQLITE_IOERR | (19<<8)) #define SQLITE_IOERR_SHMLOCK (SQLITE_IOERR | (20<<8)) +#define SQLITE_IOERR_SHMMAP (SQLITE_IOERR | (21<<8)) +#define SQLITE_IOERR_SEEK (SQLITE_IOERR | (22<<8)) #define SQLITE_LOCKED_SHAREDCACHE (SQLITE_LOCKED | (1<<8)) #define SQLITE_BUSY_RECOVERY (SQLITE_BUSY | (1<<8)) #define SQLITE_CANTOPEN_NOTEMPDIR (SQLITE_CANTOPEN | (1<<8)) +#define SQLITE_CORRUPT_VTAB (SQLITE_CORRUPT | (1<<8)) +#define SQLITE_READONLY_RECOVERY (SQLITE_READONLY | (1<<8)) +#define SQLITE_READONLY_CANTLOCK (SQLITE_READONLY | (2<<8)) /* ** CAPI3REF: Flags For File Open Operations ** ** These bit values are intended for use in the ** 3rd parameter to the [sqlite3_open_v2()] interface and -** in the 4th parameter to the xOpen method of the -** [sqlite3_vfs] object. +** in the 4th parameter to the [sqlite3_vfs.xOpen] method. */ #define SQLITE_OPEN_READONLY 0x00000001 /* Ok for sqlite3_open_v2() */ #define SQLITE_OPEN_READWRITE 0x00000002 /* Ok for sqlite3_open_v2() */ @@ -1017,6 +1022,7 @@ SQLITE_API int sqlite3_exec( #define SQLITE_OPEN_DELETEONCLOSE 0x00000008 /* VFS only */ #define SQLITE_OPEN_EXCLUSIVE 0x00000010 /* VFS only */ #define SQLITE_OPEN_AUTOPROXY 0x00000020 /* VFS only */ +#define SQLITE_OPEN_URI 0x00000040 /* Ok for sqlite3_open_v2() */ #define SQLITE_OPEN_MAIN_DB 0x00000100 /* VFS only */ #define SQLITE_OPEN_TEMP_DB 0x00000200 /* VFS only */ #define SQLITE_OPEN_TRANSIENT_DB 0x00000400 /* VFS only */ @@ -1127,17 +1133,18 @@ struct sqlite3_file { /* ** CAPI3REF: OS Interface File Virtual Methods Object ** -** Every file opened by the [sqlite3_vfs] xOpen method populates an +** Every file opened by the [sqlite3_vfs.xOpen] method populates an ** [sqlite3_file] object (or, more commonly, a subclass of the ** [sqlite3_file] object) with a pointer to an instance of this object. ** This object defines the methods used to perform various operations ** against the open file represented by the [sqlite3_file] object. ** -** If the xOpen method sets the sqlite3_file.pMethods element +** If the [sqlite3_vfs.xOpen] method sets the sqlite3_file.pMethods element ** to a non-NULL pointer, then the sqlite3_io_methods.xClose method -** may be invoked even if the xOpen reported that it failed. The -** only way to prevent a call to xClose following a failed xOpen -** is for the xOpen to set the sqlite3_file.pMethods element to NULL. +** may be invoked even if the [sqlite3_vfs.xOpen] reported that it failed. The +** only way to prevent a call to xClose following a failed [sqlite3_vfs.xOpen] +** is for the [sqlite3_vfs.xOpen] to set the sqlite3_file.pMethods element +** to NULL. ** ** The flags argument to xSync may be one of [SQLITE_SYNC_NORMAL] or ** [SQLITE_SYNC_FULL]. The first choice is the normal fsync(). @@ -1309,7 +1316,8 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** ** An instance of the sqlite3_vfs object defines the interface between ** the SQLite core and the underlying operating system. The "vfs" -** in the name of the object stands for "virtual file system". +** in the name of the object stands for "virtual file system". See +** the [VFS | VFS documentation] for further information. ** ** The value of the iVersion field is initially 1 but may be larger in ** future versions of SQLite. Additional fields may be appended to this @@ -1338,6 +1346,7 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** The zName field holds the name of the VFS module. The name must ** be unique across all VFS modules. ** +** [[sqlite3_vfs.xOpen]] ** ^SQLite guarantees that the zFilename parameter to xOpen ** is either a NULL pointer or string obtained ** from xFullPathname() with an optional suffix added. @@ -1415,6 +1424,7 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** element will be valid after xOpen returns regardless of the success ** or failure of the xOpen call. ** +** [[sqlite3_vfs.xAccess]] ** ^The flags argument to xAccess() may be [SQLITE_ACCESS_EXISTS] ** to test for the existence of a file, or [SQLITE_ACCESS_READWRITE] to ** test whether a file is readable and writable, or [SQLITE_ACCESS_READ] @@ -1439,7 +1449,7 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** method returns a Julian Day Number for the current date and time as ** a floating point value. ** ^The xCurrentTimeInt64() method returns, as an integer, the Julian -** Day Number multipled by 86400000 (the number of milliseconds in +** Day Number multiplied by 86400000 (the number of milliseconds in ** a 24-hour day). ** ^SQLite will use the xCurrentTimeInt64() method to get the current ** date and time if that method is available (if iVersion is 2 or @@ -1661,9 +1671,9 @@ SQLITE_API int sqlite3_os_end(void); ** implementation of an application-defined [sqlite3_os_init()]. ** ** The first argument to sqlite3_config() is an integer -** [SQLITE_CONFIG_SINGLETHREAD | configuration option] that determines +** [configuration option] that determines ** what property of SQLite is to be configured. Subsequent arguments -** vary depending on the [SQLITE_CONFIG_SINGLETHREAD | configuration option] +** vary depending on the [configuration option] ** in the first argument. ** ** ^When a configuration option is set, sqlite3_config() returns [SQLITE_OK]. @@ -1773,6 +1783,7 @@ struct sqlite3_mem_methods { /* ** CAPI3REF: Configuration Options +** KEYWORDS: {configuration option} ** ** These constants are the available integer configuration options that ** can be passed as the first argument to the [sqlite3_config()] interface. @@ -1785,7 +1796,7 @@ struct sqlite3_mem_methods { ** is invoked. ** **
-**
SQLITE_CONFIG_SINGLETHREAD
+** [[SQLITE_CONFIG_SINGLETHREAD]]
SQLITE_CONFIG_SINGLETHREAD
**
There are no arguments to this option. ^This option sets the ** [threading mode] to Single-thread. In other words, it disables ** all mutexing and puts SQLite into a mode where it can only be used @@ -1796,7 +1807,7 @@ struct sqlite3_mem_methods { ** [SQLITE_ERROR] if called with the SQLITE_CONFIG_SINGLETHREAD ** configuration option.
** -**
SQLITE_CONFIG_MULTITHREAD
+** [[SQLITE_CONFIG_MULTITHREAD]]
SQLITE_CONFIG_MULTITHREAD
**
There are no arguments to this option. ^This option sets the ** [threading mode] to Multi-thread. In other words, it disables ** mutexing on [database connection] and [prepared statement] objects. @@ -1810,7 +1821,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] will return [SQLITE_ERROR] if called with the ** SQLITE_CONFIG_MULTITHREAD configuration option.
** -**
SQLITE_CONFIG_SERIALIZED
+** [[SQLITE_CONFIG_SERIALIZED]]
SQLITE_CONFIG_SERIALIZED
**
There are no arguments to this option. ^This option sets the ** [threading mode] to Serialized. In other words, this option enables ** all mutexes including the recursive @@ -1826,7 +1837,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] will return [SQLITE_ERROR] if called with the ** SQLITE_CONFIG_SERIALIZED configuration option.
** -**
SQLITE_CONFIG_MALLOC
+** [[SQLITE_CONFIG_MALLOC]]
SQLITE_CONFIG_MALLOC
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mem_methods] structure. The argument specifies ** alternative low-level memory allocation routines to be used in place of @@ -1834,7 +1845,7 @@ struct sqlite3_mem_methods { ** its own private copy of the content of the [sqlite3_mem_methods] structure ** before the [sqlite3_config()] call returns.
** -**
SQLITE_CONFIG_GETMALLOC
+** [[SQLITE_CONFIG_GETMALLOC]]
SQLITE_CONFIG_GETMALLOC
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mem_methods] structure. The [sqlite3_mem_methods] ** structure is filled with the currently defined memory allocation routines.)^ @@ -1842,7 +1853,7 @@ struct sqlite3_mem_methods { ** routines with a wrapper that simulations memory allocation failure or ** tracks memory usage, for example.
** -**
SQLITE_CONFIG_MEMSTATUS
+** [[SQLITE_CONFIG_MEMSTATUS]]
SQLITE_CONFIG_MEMSTATUS
**
^This option takes single argument of type int, interpreted as a ** boolean, which enables or disables the collection of memory allocation ** statistics. ^(When memory allocation statistics are disabled, the @@ -1858,7 +1869,7 @@ struct sqlite3_mem_methods { ** allocation statistics are disabled by default. **
** -**
SQLITE_CONFIG_SCRATCH
+** [[SQLITE_CONFIG_SCRATCH]]
SQLITE_CONFIG_SCRATCH
**
^This option specifies a static memory buffer that SQLite can use for ** scratch memory. There are three arguments: A pointer an 8-byte ** aligned memory buffer from which the scratch allocations will be @@ -1874,9 +1885,9 @@ struct sqlite3_mem_methods { ** scratch memory beyond what is provided by this configuration option, then ** [sqlite3_malloc()] will be used to obtain the memory needed.
** -**
SQLITE_CONFIG_PAGECACHE
+** [[SQLITE_CONFIG_PAGECACHE]]
SQLITE_CONFIG_PAGECACHE
**
^This option specifies a static memory buffer that SQLite can use for -** the database page cache with the default page cache implemenation. +** the database page cache with the default page cache implementation. ** This configuration should not be used if an application-define page ** cache implementation is loaded using the SQLITE_CONFIG_PCACHE option. ** There are three arguments to this option: A pointer to 8-byte aligned @@ -1895,7 +1906,7 @@ struct sqlite3_mem_methods { ** be aligned to an 8-byte boundary or subsequent behavior of SQLite ** will be undefined.
** -**
SQLITE_CONFIG_HEAP
+** [[SQLITE_CONFIG_HEAP]]
SQLITE_CONFIG_HEAP
**
^This option specifies a static memory buffer that SQLite will use ** for all of its dynamic memory allocation needs beyond those provided ** for by [SQLITE_CONFIG_SCRATCH] and [SQLITE_CONFIG_PAGECACHE]. @@ -1912,7 +1923,7 @@ struct sqlite3_mem_methods { ** The minimum allocation size is capped at 2^12. Reasonable values ** for the minimum allocation size are 2^5 through 2^8.
** -**
SQLITE_CONFIG_MUTEX
+** [[SQLITE_CONFIG_MUTEX]]
SQLITE_CONFIG_MUTEX
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mutex_methods] structure. The argument specifies ** alternative low-level mutex routines to be used in place @@ -1924,7 +1935,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] with the SQLITE_CONFIG_MUTEX configuration option will ** return [SQLITE_ERROR].
** -**
SQLITE_CONFIG_GETMUTEX
+** [[SQLITE_CONFIG_GETMUTEX]]
SQLITE_CONFIG_GETMUTEX
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mutex_methods] structure. The ** [sqlite3_mutex_methods] @@ -1937,7 +1948,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] with the SQLITE_CONFIG_GETMUTEX configuration option will ** return [SQLITE_ERROR].
** -**
SQLITE_CONFIG_LOOKASIDE
+** [[SQLITE_CONFIG_LOOKASIDE]]
SQLITE_CONFIG_LOOKASIDE
**
^(This option takes two arguments that determine the default ** memory allocation for the lookaside memory allocator on each ** [database connection]. The first argument is the @@ -1947,18 +1958,18 @@ struct sqlite3_mem_methods { ** verb to [sqlite3_db_config()] can be used to change the lookaside ** configuration on individual connections.)^
** -**
SQLITE_CONFIG_PCACHE
+** [[SQLITE_CONFIG_PCACHE]]
SQLITE_CONFIG_PCACHE
**
^(This option takes a single argument which is a pointer to ** an [sqlite3_pcache_methods] object. This object specifies the interface ** to a custom page cache implementation.)^ ^SQLite makes a copy of the ** object and uses it for page cache memory allocations.
** -**
SQLITE_CONFIG_GETPCACHE
+** [[SQLITE_CONFIG_GETPCACHE]]
SQLITE_CONFIG_GETPCACHE
**
^(This option takes a single argument which is a pointer to an ** [sqlite3_pcache_methods] object. SQLite copies of the current ** page cache implementation into that object.)^
** -**
SQLITE_CONFIG_LOG
+** [[SQLITE_CONFIG_LOG]]
SQLITE_CONFIG_LOG
**
^The SQLITE_CONFIG_LOG option takes two arguments: a pointer to a ** function with a call signature of void(*)(void*,int,const char*), ** and a pointer to void. ^If the function pointer is not NULL, it is @@ -1976,6 +1987,18 @@ struct sqlite3_mem_methods { ** In a multi-threaded application, the application-defined logger ** function must be threadsafe.
** +** [[SQLITE_CONFIG_URI]]
SQLITE_CONFIG_URI +**
This option takes a single argument of type int. If non-zero, then +** URI handling is globally enabled. If the parameter is zero, then URI handling +** is globally disabled. If URI handling is globally enabled, all filenames +** passed to [sqlite3_open()], [sqlite3_open_v2()], [sqlite3_open16()] or +** specified as part of [ATTACH] commands are interpreted as URIs, regardless +** of whether or not the [SQLITE_OPEN_URI] flag is set when the database +** connection is opened. If it is globally disabled, filenames are +** only interpreted as URIs if the SQLITE_OPEN_URI flag is set when the +** database connection is opened. By default, URI handling is globally +** disabled. The default value may be changed by compiling with the +** [SQLITE_USE_URI] symbol defined. **
*/ #define SQLITE_CONFIG_SINGLETHREAD 1 /* nil */ @@ -1994,6 +2017,7 @@ struct sqlite3_mem_methods { #define SQLITE_CONFIG_PCACHE 14 /* sqlite3_pcache_methods* */ #define SQLITE_CONFIG_GETPCACHE 15 /* sqlite3_pcache_methods* */ #define SQLITE_CONFIG_LOG 16 /* xFunc, void* */ +#define SQLITE_CONFIG_URI 17 /* int */ /* ** CAPI3REF: Database Connection Configuration Options @@ -2079,13 +2103,17 @@ SQLITE_API int sqlite3_extended_result_codes(sqlite3*, int onoff); ** ** ^This routine returns the [rowid] of the most recent ** successful [INSERT] into the database from the [database connection] -** in the first argument. ^If no successful [INSERT]s +** in the first argument. ^As of SQLite version 3.7.7, this routines +** records the last insert rowid of both ordinary tables and [virtual tables]. +** ^If no successful [INSERT]s ** have ever occurred on that database connection, zero is returned. ** -** ^(If an [INSERT] occurs within a trigger, then the [rowid] of the inserted -** row is returned by this routine as long as the trigger is running. -** But once the trigger terminates, the value returned by this routine -** reverts to the last value inserted before the trigger fired.)^ +** ^(If an [INSERT] occurs within a trigger or within a [virtual table] +** method, then this routine will return the [rowid] of the inserted +** row as long as the trigger or virtual table method is running. +** But once the trigger or virtual table method ends, the value returned +** by this routine reverts to what it was before the trigger or virtual +** table method began.)^ ** ** ^An [INSERT] that fails due to a constraint violation is not a ** successful [INSERT] and does not change the value returned by this @@ -2748,6 +2776,9 @@ SQLITE_API int sqlite3_set_authorizer( ** to signal SQLite whether or not the action is permitted. See the ** [sqlite3_set_authorizer | authorizer documentation] for additional ** information. +** +** Note that SQLITE_IGNORE is also used as a [SQLITE_ROLLBACK | return code] +** from the [sqlite3_vtab_on_conflict()] interface. */ #define SQLITE_DENY 1 /* Abort the SQL statement with an error */ #define SQLITE_IGNORE 2 /* Don't allow access, but don't generate an error */ @@ -2870,7 +2901,7 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); /* ** CAPI3REF: Opening A New Database Connection ** -** ^These routines open an SQLite database file whose name is given by the +** ^These routines open an SQLite database file as specified by the ** filename argument. ^The filename argument is interpreted as UTF-8 for ** sqlite3_open() and sqlite3_open_v2() and as UTF-16 in the native byte ** order for sqlite3_open16(). ^(A [database connection] handle is usually @@ -2897,7 +2928,7 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); ** sqlite3_open_v2() can take one of ** the following three values, optionally combined with the ** [SQLITE_OPEN_NOMUTEX], [SQLITE_OPEN_FULLMUTEX], [SQLITE_OPEN_SHAREDCACHE], -** and/or [SQLITE_OPEN_PRIVATECACHE] flags:)^ +** [SQLITE_OPEN_PRIVATECACHE], and/or [SQLITE_OPEN_URI] flags:)^ ** **
** ^(
[SQLITE_OPEN_READONLY]
@@ -2916,9 +2947,8 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); **
** ** If the 3rd parameter to sqlite3_open_v2() is not one of the -** combinations shown above or one of the combinations shown above combined -** with the [SQLITE_OPEN_NOMUTEX], [SQLITE_OPEN_FULLMUTEX], -** [SQLITE_OPEN_SHAREDCACHE] and/or [SQLITE_OPEN_PRIVATECACHE] flags, +** combinations shown above optionally combined with other +** [SQLITE_OPEN_READONLY | SQLITE_OPEN_* bits] ** then the behavior is undefined. ** ** ^If the [SQLITE_OPEN_NOMUTEX] flag is set, then the database connection @@ -2933,6 +2963,11 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); ** [SQLITE_OPEN_PRIVATECACHE] flag causes the database connection to not ** participate in [shared cache mode] even if it is enabled. ** +** ^The fourth parameter to sqlite3_open_v2() is the name of the +** [sqlite3_vfs] object that defines the operating system interface that +** the new database connection should use. ^If the fourth parameter is +** a NULL pointer then the default [sqlite3_vfs] object is used. +** ** ^If the filename is ":memory:", then a private, temporary in-memory database ** is created for the connection. ^This in-memory database will vanish when ** the database connection is closed. Future versions of SQLite might @@ -2945,10 +2980,111 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); ** on-disk database will be created. ^This private database will be ** automatically deleted as soon as the database connection is closed. ** -** ^The fourth parameter to sqlite3_open_v2() is the name of the -** [sqlite3_vfs] object that defines the operating system interface that -** the new database connection should use. ^If the fourth parameter is -** a NULL pointer then the default [sqlite3_vfs] object is used. +** [[URI filenames in sqlite3_open()]]

URI Filenames

+** +** ^If [URI filename] interpretation is enabled, and the filename argument +** begins with "file:", then the filename is interpreted as a URI. ^URI +** filename interpretation is enabled if the [SQLITE_OPEN_URI] flag is +** set in the fourth argument to sqlite3_open_v2(), or if it has +** been enabled globally using the [SQLITE_CONFIG_URI] option with the +** [sqlite3_config()] method or by the [SQLITE_USE_URI] compile-time option. +** As of SQLite version 3.7.7, URI filename interpretation is turned off +** by default, but future releases of SQLite might enable URI filename +** interpretation by default. See "[URI filenames]" for additional +** information. +** +** URI filenames are parsed according to RFC 3986. ^If the URI contains an +** authority, then it must be either an empty string or the string +** "localhost". ^If the authority is not an empty string or "localhost", an +** error is returned to the caller. ^The fragment component of a URI, if +** present, is ignored. +** +** ^SQLite uses the path component of the URI as the name of the disk file +** which contains the database. ^If the path begins with a '/' character, +** then it is interpreted as an absolute path. ^If the path does not begin +** with a '/' (meaning that the authority section is omitted from the URI) +** then the path is interpreted as a relative path. +** ^On windows, the first component of an absolute path +** is a drive specification (e.g. "C:"). +** +** [[core URI query parameters]] +** The query component of a URI may contain parameters that are interpreted +** either by SQLite itself, or by a [VFS | custom VFS implementation]. +** SQLite interprets the following three query parameters: +** +**
    +**
  • vfs: ^The "vfs" parameter may be used to specify the name of +** a VFS object that provides the operating system interface that should +** be used to access the database file on disk. ^If this option is set to +** an empty string the default VFS object is used. ^Specifying an unknown +** VFS is an error. ^If sqlite3_open_v2() is used and the vfs option is +** present, then the VFS specified by the option takes precedence over +** the value passed as the fourth parameter to sqlite3_open_v2(). +** +**
  • mode: ^(The mode parameter may be set to either "ro", "rw" or +** "rwc". Attempting to set it to any other value is an error)^. +** ^If "ro" is specified, then the database is opened for read-only +** access, just as if the [SQLITE_OPEN_READONLY] flag had been set in the +** third argument to sqlite3_prepare_v2(). ^If the mode option is set to +** "rw", then the database is opened for read-write (but not create) +** access, as if SQLITE_OPEN_READWRITE (but not SQLITE_OPEN_CREATE) had +** been set. ^Value "rwc" is equivalent to setting both +** SQLITE_OPEN_READWRITE and SQLITE_OPEN_CREATE. ^If sqlite3_open_v2() is +** used, it is an error to specify a value for the mode parameter that is +** less restrictive than that specified by the flags passed as the third +** parameter. +** +**
  • cache: ^The cache parameter may be set to either "shared" or +** "private". ^Setting it to "shared" is equivalent to setting the +** SQLITE_OPEN_SHAREDCACHE bit in the flags argument passed to +** sqlite3_open_v2(). ^Setting the cache parameter to "private" is +** equivalent to setting the SQLITE_OPEN_PRIVATECACHE bit. +** ^If sqlite3_open_v2() is used and the "cache" parameter is present in +** a URI filename, its value overrides any behaviour requested by setting +** SQLITE_OPEN_PRIVATECACHE or SQLITE_OPEN_SHAREDCACHE flag. +**
+** +** ^Specifying an unknown parameter in the query component of a URI is not an +** error. Future versions of SQLite might understand additional query +** parameters. See "[query parameters with special meaning to SQLite]" for +** additional information. +** +** [[URI filename examples]]

URI filename examples

+** +** +**
URI filenames Results +**
file:data.db +** Open the file "data.db" in the current directory. +**
file:/home/fred/data.db
+** file:///home/fred/data.db
+** file://localhost/home/fred/data.db
+** Open the database file "/home/fred/data.db". +**
file://darkstar/home/fred/data.db +** An error. "darkstar" is not a recognized authority. +**
+** file:///C:/Documents%20and%20Settings/fred/Desktop/data.db +** Windows only: Open the file "data.db" on fred's desktop on drive +** C:. Note that the %20 escaping in this example is not strictly +** necessary - space characters can be used literally +** in URI filenames. +**
file:data.db?mode=ro&cache=private +** Open file "data.db" in the current directory for read-only access. +** Regardless of whether or not shared-cache mode is enabled by +** default, use a private cache. +**
file:/home/fred/data.db?vfs=unix-nolock +** Open file "/home/fred/data.db". Use the special VFS "unix-nolock". +**
file:data.db?mode=readonly +** An error. "readonly" is not a valid option for the "mode" parameter. +**
+** +** ^URI hexadecimal escape sequences (%HH) are supported within the path and +** query components of a URI. A hexadecimal escape sequence consists of a +** percent sign - "%" - followed by exactly two hexadecimal digits +** specifying an octet value. ^Before the path or query components of a +** URI filename are interpreted, they are encoded using UTF-8 and all +** hexadecimal escape sequences replaced by a single byte containing the +** corresponding octet. If this process generates an invalid UTF-8 encoding, +** the results are undefined. ** ** Note to Windows users: The encoding used for the filename argument ** of sqlite3_open() and sqlite3_open_v2() must be UTF-8, not whatever @@ -2971,6 +3107,26 @@ SQLITE_API int sqlite3_open_v2( const char *zVfs /* Name of VFS module to use */ ); +/* +** CAPI3REF: Obtain Values For URI Parameters +** +** This is a utility routine, useful to VFS implementations, that checks +** to see if a database file was a URI that contained a specific query +** parameter, and if so obtains the value of the query parameter. +** +** The zFilename argument is the filename pointer passed into the xOpen() +** method of a VFS implementation. The zParam argument is the name of the +** query parameter we seek. This routine returns the value of the zParam +** parameter if it exists. If the parameter does not exist, this routine +** returns a NULL pointer. +** +** If the zFilename argument to this function is not a pointer that SQLite +** passed into the xOpen VFS method, then the behavior of this routine +** is undefined and probably undesirable. +*/ +SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *zParam); + + /* ** CAPI3REF: Error Codes And Messages ** @@ -3086,43 +3242,45 @@ SQLITE_API int sqlite3_limit(sqlite3*, int id, int newVal); ** Additional information is available at [limits | Limits in SQLite]. ** **
-** ^(
SQLITE_LIMIT_LENGTH
+** [[SQLITE_LIMIT_LENGTH]] ^(
SQLITE_LIMIT_LENGTH
**
The maximum size of any string or BLOB or table row, in bytes.
)^ ** -** ^(
SQLITE_LIMIT_SQL_LENGTH
+** [[SQLITE_LIMIT_SQL_LENGTH]] ^(
SQLITE_LIMIT_SQL_LENGTH
**
The maximum length of an SQL statement, in bytes.
)^ ** -** ^(
SQLITE_LIMIT_COLUMN
+** [[SQLITE_LIMIT_COLUMN]] ^(
SQLITE_LIMIT_COLUMN
**
The maximum number of columns in a table definition or in the ** result set of a [SELECT] or the maximum number of columns in an index ** or in an ORDER BY or GROUP BY clause.
)^ ** -** ^(
SQLITE_LIMIT_EXPR_DEPTH
+** [[SQLITE_LIMIT_EXPR_DEPTH]] ^(
SQLITE_LIMIT_EXPR_DEPTH
**
The maximum depth of the parse tree on any expression.
)^ ** -** ^(
SQLITE_LIMIT_COMPOUND_SELECT
+** [[SQLITE_LIMIT_COMPOUND_SELECT]] ^(
SQLITE_LIMIT_COMPOUND_SELECT
**
The maximum number of terms in a compound SELECT statement.
)^ ** -** ^(
SQLITE_LIMIT_VDBE_OP
+** [[SQLITE_LIMIT_VDBE_OP]] ^(
SQLITE_LIMIT_VDBE_OP
**
The maximum number of instructions in a virtual machine program ** used to implement an SQL statement. This limit is not currently ** enforced, though that might be added in some future release of ** SQLite.
)^ ** -** ^(
SQLITE_LIMIT_FUNCTION_ARG
+** [[SQLITE_LIMIT_FUNCTION_ARG]] ^(
SQLITE_LIMIT_FUNCTION_ARG
**
The maximum number of arguments on a function.
)^ ** -** ^(
SQLITE_LIMIT_ATTACHED
+** [[SQLITE_LIMIT_ATTACHED]] ^(
SQLITE_LIMIT_ATTACHED
**
The maximum number of [ATTACH | attached databases].)^
** +** [[SQLITE_LIMIT_LIKE_PATTERN_LENGTH]] ** ^(
SQLITE_LIMIT_LIKE_PATTERN_LENGTH
**
The maximum length of the pattern argument to the [LIKE] or ** [GLOB] operators.
)^ ** +** [[SQLITE_LIMIT_VARIABLE_NUMBER]] ** ^(
SQLITE_LIMIT_VARIABLE_NUMBER
**
The maximum index number of any [parameter] in an SQL statement.)^ ** -** ^(
SQLITE_LIMIT_TRIGGER_DEPTH
+** [[SQLITE_LIMIT_TRIGGER_DEPTH]] ^(
SQLITE_LIMIT_TRIGGER_DEPTH
**
The maximum depth of recursion for triggers.
)^ **
*/ @@ -3651,7 +3809,7 @@ SQLITE_API const void *sqlite3_column_decltype16(sqlite3_stmt*,int); ** ^[SQLITE_BUSY] means that the database engine was unable to acquire the ** database locks it needs to do its job. ^If the statement is a [COMMIT] ** or occurs outside of an explicit transaction, then you can retry the -** statement. If the statement is not a [COMMIT] and occurs within a +** statement. If the statement is not a [COMMIT] and occurs within an ** explicit transaction then you should rollback the transaction before ** continuing. ** @@ -3930,7 +4088,7 @@ SQLITE_API sqlite3_value *sqlite3_column_value(sqlite3_stmt*, int iCol); ** CAPI3REF: Destroy A Prepared Statement Object ** ** ^The sqlite3_finalize() function is called to delete a [prepared statement]. -** ^If the most recent evaluation of the statement encountered no errors or +** ^If the most recent evaluation of the statement encountered no errors ** or if the statement is never been evaluated, then sqlite3_finalize() returns ** SQLITE_OK. ^If the most recent evaluation of statement S failed, then ** sqlite3_finalize(S) returns the appropriate [error code] or @@ -5157,6 +5315,11 @@ struct sqlite3_module { void (**pxFunc)(sqlite3_context*,int,sqlite3_value**), void **ppArg); int (*xRename)(sqlite3_vtab *pVtab, const char *zNew); + /* The methods above are in version 1 of the sqlite_module object. Those + ** below are for version 2 and greater. */ + int (*xSavepoint)(sqlite3_vtab *pVTab, int); + int (*xRelease)(sqlite3_vtab *pVTab, int); + int (*xRollbackTo)(sqlite3_vtab *pVTab, int); }; /* @@ -5839,7 +6002,7 @@ struct sqlite3_mutex_methods { ** ** ^If the argument to sqlite3_mutex_held() is a NULL pointer then ** the routine should return 1. This seems counter-intuitive since -** clearly the mutex cannot be held if it does not exist. But the +** clearly the mutex cannot be held if it does not exist. But ** the reason the mutex does not exist is because the build is not ** using mutexes. And we do not want the assert() containing the ** call to sqlite3_mutex_held() to fail, so a non-zero return is @@ -5962,7 +6125,8 @@ SQLITE_API int sqlite3_test_control(int op, ...); #define SQLITE_TESTCTRL_ISKEYWORD 16 #define SQLITE_TESTCTRL_PGHDRSZ 17 #define SQLITE_TESTCTRL_SCRATCHMALLOC 18 -#define SQLITE_TESTCTRL_LAST 18 +#define SQLITE_TESTCTRL_LOCALTIME_FAULT 19 +#define SQLITE_TESTCTRL_LAST 19 /* ** CAPI3REF: SQLite Runtime Status @@ -5971,7 +6135,7 @@ SQLITE_API int sqlite3_test_control(int op, ...); ** about the performance of SQLite, and optionally to reset various ** highwater marks. ^The first argument is an integer code for ** the specific parameter to measure. ^(Recognized integer codes -** are of the form [SQLITE_STATUS_MEMORY_USED | SQLITE_STATUS_...].)^ +** are of the form [status parameters | SQLITE_STATUS_...].)^ ** ^The current value of the parameter is returned into *pCurrent. ** ^The highest recorded value is returned in *pHighwater. ^If the ** resetFlag is true, then the highest record value is reset after @@ -5998,12 +6162,13 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF /* ** CAPI3REF: Status Parameters +** KEYWORDS: {status parameters} ** ** These integer constants designate various run-time status parameters ** that can be returned by [sqlite3_status()]. ** **
-** ^(
SQLITE_STATUS_MEMORY_USED
+** [[SQLITE_STATUS_MEMORY_USED]] ^(
SQLITE_STATUS_MEMORY_USED
**
This parameter is the current amount of memory checked out ** using [sqlite3_malloc()], either directly or indirectly. The ** figure includes calls made to [sqlite3_malloc()] by the application @@ -6013,23 +6178,24 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** this parameter. The amount returned is the sum of the allocation ** sizes as reported by the xSize method in [sqlite3_mem_methods].
)^ ** -** ^(
SQLITE_STATUS_MALLOC_SIZE
+** [[SQLITE_STATUS_MALLOC_SIZE]] ^(
SQLITE_STATUS_MALLOC_SIZE
**
This parameter records the largest memory allocation request ** handed to [sqlite3_malloc()] or [sqlite3_realloc()] (or their ** internal equivalents). Only the value returned in the ** *pHighwater parameter to [sqlite3_status()] is of interest. ** The value written into the *pCurrent parameter is undefined.
)^ ** -** ^(
SQLITE_STATUS_MALLOC_COUNT
+** [[SQLITE_STATUS_MALLOC_COUNT]] ^(
SQLITE_STATUS_MALLOC_COUNT
**
This parameter records the number of separate memory allocations ** currently checked out.
)^ ** -** ^(
SQLITE_STATUS_PAGECACHE_USED
+** [[SQLITE_STATUS_PAGECACHE_USED]] ^(
SQLITE_STATUS_PAGECACHE_USED
**
This parameter returns the number of pages used out of the ** [pagecache memory allocator] that was configured using ** [SQLITE_CONFIG_PAGECACHE]. The ** value returned is in pages, not in bytes.
)^ ** +** [[SQLITE_STATUS_PAGECACHE_OVERFLOW]] ** ^(
SQLITE_STATUS_PAGECACHE_OVERFLOW
**
This parameter returns the number of bytes of page cache ** allocation which could not be satisfied by the [SQLITE_CONFIG_PAGECACHE] @@ -6039,13 +6205,13 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** [SQLITE_CONFIG_PAGECACHE]) and allocations that overflowed because ** no space was left in the page cache.
)^ ** -** ^(
SQLITE_STATUS_PAGECACHE_SIZE
+** [[SQLITE_STATUS_PAGECACHE_SIZE]] ^(
SQLITE_STATUS_PAGECACHE_SIZE
**
This parameter records the largest memory allocation request ** handed to [pagecache memory allocator]. Only the value returned in the ** *pHighwater parameter to [sqlite3_status()] is of interest. ** The value written into the *pCurrent parameter is undefined.
)^ ** -** ^(
SQLITE_STATUS_SCRATCH_USED
+** [[SQLITE_STATUS_SCRATCH_USED]] ^(
SQLITE_STATUS_SCRATCH_USED
**
This parameter returns the number of allocations used out of the ** [scratch memory allocator] configured using ** [SQLITE_CONFIG_SCRATCH]. The value returned is in allocations, not @@ -6053,7 +6219,7 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** outstanding at time, this parameter also reports the number of threads ** using scratch memory at the same time.
)^ ** -** ^(
SQLITE_STATUS_SCRATCH_OVERFLOW
+** [[SQLITE_STATUS_SCRATCH_OVERFLOW]] ^(
SQLITE_STATUS_SCRATCH_OVERFLOW
**
This parameter returns the number of bytes of scratch memory ** allocation which could not be satisfied by the [SQLITE_CONFIG_SCRATCH] ** buffer and where forced to overflow to [sqlite3_malloc()]. The values @@ -6063,13 +6229,13 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** slots were available. **
)^ ** -** ^(
SQLITE_STATUS_SCRATCH_SIZE
+** [[SQLITE_STATUS_SCRATCH_SIZE]] ^(
SQLITE_STATUS_SCRATCH_SIZE
**
This parameter records the largest memory allocation request ** handed to [scratch memory allocator]. Only the value returned in the ** *pHighwater parameter to [sqlite3_status()] is of interest. ** The value written into the *pCurrent parameter is undefined.
)^ ** -** ^(
SQLITE_STATUS_PARSER_STACK
+** [[SQLITE_STATUS_PARSER_STACK]] ^(
SQLITE_STATUS_PARSER_STACK
**
This parameter records the deepest parser stack. It is only ** meaningful if SQLite is compiled with [YYTRACKMAXSTACKDEPTH].
)^ **
@@ -6094,9 +6260,9 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** about a single [database connection]. ^The first argument is the ** database connection object to be interrogated. ^The second argument ** is an integer constant, taken from the set of -** [SQLITE_DBSTATUS_LOOKASIDE_USED | SQLITE_DBSTATUS_*] macros, that +** [SQLITE_DBSTATUS options], that ** determines the parameter to interrogate. The set of -** [SQLITE_DBSTATUS_LOOKASIDE_USED | SQLITE_DBSTATUS_*] macros is likely +** [SQLITE_DBSTATUS options] is likely ** to grow in future releases of SQLite. ** ** ^The current value of the requested parameter is written into *pCur @@ -6113,6 +6279,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r /* ** CAPI3REF: Status Parameters for database connections +** KEYWORDS: {SQLITE_DBSTATUS options} ** ** These constants are the available integer "verbs" that can be passed as ** the second argument to the [sqlite3_db_status()] interface. @@ -6124,15 +6291,16 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** if a discontinued or unsupported verb is invoked. ** **
-** ^(
SQLITE_DBSTATUS_LOOKASIDE_USED
+** [[SQLITE_DBSTATUS_LOOKASIDE_USED]] ^(
SQLITE_DBSTATUS_LOOKASIDE_USED
**
This parameter returns the number of lookaside memory slots currently ** checked out.
)^ ** -** ^(
SQLITE_DBSTATUS_LOOKASIDE_HIT
+** [[SQLITE_DBSTATUS_LOOKASIDE_HIT]] ^(
SQLITE_DBSTATUS_LOOKASIDE_HIT
**
This parameter returns the number malloc attempts that were ** satisfied using lookaside memory. Only the high-water value is meaningful; ** the current value is always zero.)^ ** +** [[SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE]] ** ^(
SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE
**
This parameter returns the number malloc attempts that might have ** been satisfied using lookaside memory but failed due to the amount of @@ -6140,6 +6308,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** Only the high-water value is meaningful; ** the current value is always zero.)^ ** +** [[SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL]] ** ^(
SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL
**
This parameter returns the number malloc attempts that might have ** been satisfied using lookaside memory but failed due to all lookaside @@ -6147,12 +6316,12 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** Only the high-water value is meaningful; ** the current value is always zero.)^ ** -** ^(
SQLITE_DBSTATUS_CACHE_USED
+** [[SQLITE_DBSTATUS_CACHE_USED]] ^(
SQLITE_DBSTATUS_CACHE_USED
**
This parameter returns the approximate number of of bytes of heap ** memory used by all pager caches associated with the database connection.)^ ** ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_USED is always 0. ** -** ^(
SQLITE_DBSTATUS_SCHEMA_USED
+** [[SQLITE_DBSTATUS_SCHEMA_USED]] ^(
SQLITE_DBSTATUS_SCHEMA_USED
**
This parameter returns the approximate number of of bytes of heap ** memory used to store the schema for all databases associated ** with the connection - main, temp, and any [ATTACH]-ed databases.)^ @@ -6161,7 +6330,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** [shared cache mode] being enabled. ** ^The highwater mark associated with SQLITE_DBSTATUS_SCHEMA_USED is always 0. ** -** ^(
SQLITE_DBSTATUS_STMT_USED
+** [[SQLITE_DBSTATUS_STMT_USED]] ^(
SQLITE_DBSTATUS_STMT_USED
**
This parameter returns the approximate number of of bytes of heap ** and lookaside memory used by all prepared statements associated with ** the database connection.)^ @@ -6183,7 +6352,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** CAPI3REF: Prepared Statement Status ** ** ^(Each prepared statement maintains various -** [SQLITE_STMTSTATUS_SORT | counters] that measure the number +** [SQLITE_STMTSTATUS counters] that measure the number ** of times it has performed specific operations.)^ These counters can ** be used to monitor the performance characteristics of the prepared ** statements. For example, if the number of table steps greatly exceeds @@ -6194,7 +6363,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** ^(This interface is used to retrieve and reset counter values from ** a [prepared statement]. The first argument is the prepared statement ** object to be interrogated. The second argument -** is an integer code for a specific [SQLITE_STMTSTATUS_SORT | counter] +** is an integer code for a specific [SQLITE_STMTSTATUS counter] ** to be interrogated.)^ ** ^The current value of the requested counter is returned. ** ^If the resetFlg is true, then the counter is reset to zero after this @@ -6206,24 +6375,25 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt*, int op,int resetFlg); /* ** CAPI3REF: Status Parameters for prepared statements +** KEYWORDS: {SQLITE_STMTSTATUS counter} {SQLITE_STMTSTATUS counters} ** ** These preprocessor macros define integer codes that name counter ** values associated with the [sqlite3_stmt_status()] interface. ** The meanings of the various counters are as follows: ** **
-**
SQLITE_STMTSTATUS_FULLSCAN_STEP
+** [[SQLITE_STMTSTATUS_FULLSCAN_STEP]]
SQLITE_STMTSTATUS_FULLSCAN_STEP
**
^This is the number of times that SQLite has stepped forward in ** a table as part of a full table scan. Large numbers for this counter ** may indicate opportunities for performance improvement through ** careful use of indices.
** -**
SQLITE_STMTSTATUS_SORT
+** [[SQLITE_STMTSTATUS_SORT]]
SQLITE_STMTSTATUS_SORT
**
^This is the number of sort operations that have occurred. ** A non-zero value in this counter may indicate an opportunity to ** improvement performance through careful use of indices.
** -**
SQLITE_STMTSTATUS_AUTOINDEX
+** [[SQLITE_STMTSTATUS_AUTOINDEX]]
SQLITE_STMTSTATUS_AUTOINDEX
**
^This is the number of rows inserted into transient indices that ** were created automatically in order to help joins run faster. ** A non-zero value in this counter may indicate an opportunity to @@ -6274,6 +6444,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** the application may discard the parameter after the call to ** [sqlite3_config()] returns.)^ ** +** [[the xInit() page cache method]] ** ^(The xInit() method is called once for each effective ** call to [sqlite3_initialize()])^ ** (usually only once during the lifetime of the process). ^(The xInit() @@ -6284,6 +6455,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** built-in default page cache is used instead of the application defined ** page cache.)^ ** +** [[the xShutdown() page cache method]] ** ^The xShutdown() method is called by [sqlite3_shutdown()]. ** It can be used to clean up ** any outstanding resources before process shutdown, if required. @@ -6298,6 +6470,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** ^SQLite will never invoke xInit() more than once without an intervening ** call to xShutdown(). ** +** [[the xCreate() page cache methods]] ** ^SQLite invokes the xCreate() method to construct a new cache instance. ** SQLite will typically create one cache instance for each open database file, ** though this is not guaranteed. ^The @@ -6322,6 +6495,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** ^Hence, a cache created with bPurgeable false will ** never contain any unpinned pages. ** +** [[the xCachesize() page cache method]] ** ^(The xCachesize() method may be called at any time by SQLite to set the ** suggested maximum cache-size (number of pages stored by) the cache ** instance passed as the first argument. This is the value configured using @@ -6329,14 +6503,16 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** parameter, the implementation is not required to do anything with this ** value; it is advisory only. ** +** [[the xPagecount() page cache methods]] ** The xPagecount() method must return the number of pages currently ** stored in the cache, both pinned and unpinned. ** +** [[the xFetch() page cache methods]] ** The xFetch() method locates a page in the cache and returns a pointer to ** the page, or a NULL pointer. ** A "page", in this context, means a buffer of szPage bytes aligned at an ** 8-byte boundary. The page to be fetched is determined by the key. ^The -** mimimum key value is 1. After it has been retrieved using xFetch, the page +** minimum key value is 1. After it has been retrieved using xFetch, the page ** is considered to be "pinned". ** ** If the requested page is already in the page cache, then the page cache @@ -6360,6 +6536,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** attempt to unpin one or more cache pages by spilling the content of ** pinned pages to disk and synching the operating system disk cache. ** +** [[the xUnpin() page cache method]] ** ^xUnpin() is called by SQLite with a pointer to a currently pinned page ** as its second argument. If the third parameter, discard, is non-zero, ** then the page must be evicted from the cache. @@ -6372,6 +6549,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** call to xUnpin() unpins the page regardless of the number of prior calls ** to xFetch(). ** +** [[the xRekey() page cache methods]] ** The xRekey() method is used to change the key value associated with the ** page passed as the second argument. If the cache ** previously contains an entry associated with newKey, it must be @@ -6384,6 +6562,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** of these pages are pinned, they are implicitly unpinned, meaning that ** they can be safely discarded. ** +** [[the xDestroy() page cache method]] ** ^The xDestroy() method is used to delete a cache allocated by xCreate(). ** All resources associated with the specified cache should be freed. ^After ** calling the xDestroy() method, SQLite considers the [sqlite3_pcache*] @@ -6446,7 +6625,7 @@ typedef struct sqlite3_backup sqlite3_backup; ** There should be exactly one call to sqlite3_backup_finish() for each ** successful call to sqlite3_backup_init(). ** -** sqlite3_backup_init() +** [[sqlite3_backup_init()]] sqlite3_backup_init() ** ** ^The D and N arguments to sqlite3_backup_init(D,N,S,M) are the ** [database connection] associated with the destination database @@ -6473,7 +6652,7 @@ typedef struct sqlite3_backup sqlite3_backup; ** sqlite3_backup_finish() functions to perform the specified backup ** operation. ** -** sqlite3_backup_step() +** [[sqlite3_backup_step()]] sqlite3_backup_step() ** ** ^Function sqlite3_backup_step(B,N) will copy up to N pages between ** the source and destination databases specified by [sqlite3_backup] object B. @@ -6530,7 +6709,7 @@ typedef struct sqlite3_backup sqlite3_backup; ** by the backup operation, then the backup database is automatically ** updated at the same time. ** -** sqlite3_backup_finish() +** [[sqlite3_backup_finish()]] sqlite3_backup_finish() ** ** When sqlite3_backup_step() has returned [SQLITE_DONE], or when the ** application wishes to abandon the backup operation, the application @@ -6553,7 +6732,8 @@ typedef struct sqlite3_backup sqlite3_backup; ** is not a permanent error and does not affect the return value of ** sqlite3_backup_finish(). ** -** sqlite3_backup_remaining(), sqlite3_backup_pagecount() +** [[sqlite3_backup__remaining()]] [[sqlite3_backup_pagecount()]] +** sqlite3_backup_remaining() and sqlite3_backup_pagecount() ** ** ^Each call to sqlite3_backup_step() sets two values inside ** the [sqlite3_backup] object: the number of pages still to be backed @@ -6939,6 +7119,93 @@ SQLITE_API int sqlite3_wal_checkpoint_v2( #define SQLITE_CHECKPOINT_FULL 1 #define SQLITE_CHECKPOINT_RESTART 2 +/* +** CAPI3REF: Virtual Table Interface Configuration +** +** This function may be called by either the [xConnect] or [xCreate] method +** of a [virtual table] implementation to configure +** various facets of the virtual table interface. +** +** If this interface is invoked outside the context of an xConnect or +** xCreate virtual table method then the behavior is undefined. +** +** At present, there is only one option that may be configured using +** this function. (See [SQLITE_VTAB_CONSTRAINT_SUPPORT].) Further options +** may be added in the future. +*/ +SQLITE_API int sqlite3_vtab_config(sqlite3*, int op, ...); + +/* +** CAPI3REF: Virtual Table Configuration Options +** +** These macros define the various options to the +** [sqlite3_vtab_config()] interface that [virtual table] implementations +** can use to customize and optimize their behavior. +** +**
+**
SQLITE_VTAB_CONSTRAINT_SUPPORT +**
Calls of the form +** [sqlite3_vtab_config](db,SQLITE_VTAB_CONSTRAINT_SUPPORT,X) are supported, +** where X is an integer. If X is zero, then the [virtual table] whose +** [xCreate] or [xConnect] method invoked [sqlite3_vtab_config()] does not +** support constraints. In this configuration (which is the default) if +** a call to the [xUpdate] method returns [SQLITE_CONSTRAINT], then the entire +** statement is rolled back as if [ON CONFLICT | OR ABORT] had been +** specified as part of the users SQL statement, regardless of the actual +** ON CONFLICT mode specified. +** +** If X is non-zero, then the virtual table implementation guarantees +** that if [xUpdate] returns [SQLITE_CONSTRAINT], it will do so before +** any modifications to internal or persistent data structures have been made. +** If the [ON CONFLICT] mode is ABORT, FAIL, IGNORE or ROLLBACK, SQLite +** is able to roll back a statement or database transaction, and abandon +** or continue processing the current SQL statement as appropriate. +** If the ON CONFLICT mode is REPLACE and the [xUpdate] method returns +** [SQLITE_CONSTRAINT], SQLite handles this as if the ON CONFLICT mode +** had been ABORT. +** +** Virtual table implementations that are required to handle OR REPLACE +** must do so within the [xUpdate] method. If a call to the +** [sqlite3_vtab_on_conflict()] function indicates that the current ON +** CONFLICT policy is REPLACE, the virtual table implementation should +** silently replace the appropriate rows within the xUpdate callback and +** return SQLITE_OK. Or, if this is not possible, it may return +** SQLITE_CONSTRAINT, in which case SQLite falls back to OR ABORT +** constraint handling. +**
+*/ +#define SQLITE_VTAB_CONSTRAINT_SUPPORT 1 + +/* +** CAPI3REF: Determine The Virtual Table Conflict Policy +** +** This function may only be called from within a call to the [xUpdate] method +** of a [virtual table] implementation for an INSERT or UPDATE operation. ^The +** value returned is one of [SQLITE_ROLLBACK], [SQLITE_IGNORE], [SQLITE_FAIL], +** [SQLITE_ABORT], or [SQLITE_REPLACE], according to the [ON CONFLICT] mode +** of the SQL statement that triggered the call to the [xUpdate] method of the +** [virtual table]. +*/ +SQLITE_API int sqlite3_vtab_on_conflict(sqlite3 *); + +/* +** CAPI3REF: Conflict resolution modes +** +** These constants are returned by [sqlite3_vtab_on_conflict()] to +** inform a [virtual table] implementation what the [ON CONFLICT] mode +** is for the SQL statement being evaluated. +** +** Note that the [SQLITE_IGNORE] constant is also used as a potential +** return value from the [sqlite3_set_authorizer()] callback and that +** [SQLITE_ABORT] is also a [result code]. +*/ +#define SQLITE_ROLLBACK 1 +/* #define SQLITE_IGNORE 2 // Also used by sqlite3_authorizer() callback */ +#define SQLITE_FAIL 3 +/* #define SQLITE_ABORT 4 // Also an error code */ +#define SQLITE_REPLACE 5 + + /* ** Undo the hack that converts floating point types to integer for @@ -7605,6 +7872,7 @@ typedef struct TriggerPrg TriggerPrg; typedef struct TriggerStep TriggerStep; typedef struct UnpackedRecord UnpackedRecord; typedef struct VTable VTable; +typedef struct VtabCtx VtabCtx; typedef struct Walker Walker; typedef struct WherePlan WherePlan; typedef struct WhereInfo WhereInfo; @@ -7661,6 +7929,7 @@ typedef struct BtShared BtShared; SQLITE_PRIVATE int sqlite3BtreeOpen( + sqlite3_vfs *pVfs, /* VFS to use with this b-tree */ const char *zFilename, /* Name of database file to open */ sqlite3 *db, /* Associated database connection */ Btree **ppBtree, /* Return open Btree* here */ @@ -8221,6 +8490,7 @@ SQLITE_PRIVATE int sqlite3VdbeAddOp3(Vdbe*,int,int,int,int); SQLITE_PRIVATE int sqlite3VdbeAddOp4(Vdbe*,int,int,int,int,const char *zP4,int); SQLITE_PRIVATE int sqlite3VdbeAddOp4Int(Vdbe*,int,int,int,int,int); SQLITE_PRIVATE int sqlite3VdbeAddOpList(Vdbe*, int nOp, VdbeOpList const *aOp); +SQLITE_PRIVATE void sqlite3VdbeAddParseSchemaOp(Vdbe*,int,char*); SQLITE_PRIVATE void sqlite3VdbeChangeP1(Vdbe*, int addr, int P1); SQLITE_PRIVATE void sqlite3VdbeChangeP2(Vdbe*, int addr, int P2); SQLITE_PRIVATE void sqlite3VdbeChangeP3(Vdbe*, int addr, int P3); @@ -8234,7 +8504,7 @@ SQLITE_PRIVATE int sqlite3VdbeMakeLabel(Vdbe*); SQLITE_PRIVATE void sqlite3VdbeRunOnlyOnce(Vdbe*); SQLITE_PRIVATE void sqlite3VdbeDelete(Vdbe*); SQLITE_PRIVATE void sqlite3VdbeDeleteObject(sqlite3*,Vdbe*); -SQLITE_PRIVATE void sqlite3VdbeMakeReady(Vdbe*,int,int,int,int,int,int); +SQLITE_PRIVATE void sqlite3VdbeMakeReady(Vdbe*,Parse*); SQLITE_PRIVATE int sqlite3VdbeFinalize(Vdbe*); SQLITE_PRIVATE void sqlite3VdbeResolveLabel(Vdbe*, int); SQLITE_PRIVATE int sqlite3VdbeCurrentAddr(Vdbe*); @@ -8243,6 +8513,7 @@ SQLITE_PRIVATE int sqlite3VdbeAssertMayAbort(Vdbe *, int); SQLITE_PRIVATE void sqlite3VdbeTrace(Vdbe*,FILE*); #endif SQLITE_PRIVATE void sqlite3VdbeResetStepResult(Vdbe*); +SQLITE_PRIVATE void sqlite3VdbeRewind(Vdbe*); SQLITE_PRIVATE int sqlite3VdbeReset(Vdbe*); SQLITE_PRIVATE void sqlite3VdbeSetNumCols(Vdbe*,int); SQLITE_PRIVATE int sqlite3VdbeSetColName(Vdbe*, int, int, const char *, void(*)(void*)); @@ -9019,7 +9290,7 @@ struct Db { ** A thread must be holding a mutex on the corresponding Btree in order ** to access Schema content. This implies that the thread must also be ** holding a mutex on the sqlite3 connection pointer that owns the Btree. -** For a TEMP Schema, on the connection mutex is required. +** For a TEMP Schema, only the connection mutex is required. */ struct Schema { int schema_cookie; /* Database schema version number for this file */ @@ -9140,7 +9411,7 @@ struct sqlite3 { int nDb; /* Number of backends currently in use */ Db *aDb; /* All backends */ int flags; /* Miscellaneous flags. See below */ - int openFlags; /* Flags passed to sqlite3_vfs.xOpen() */ + unsigned int openFlags; /* Flags passed to sqlite3_vfs.xOpen() */ int errCode; /* Most recent error code (SQLITE_*) */ int errMask; /* & result codes with this before returning */ u8 autoCommit; /* The auto-commit flag. */ @@ -9149,6 +9420,7 @@ struct sqlite3 { u8 dfltLockMode; /* Default locking-mode for attached dbs */ signed char nextAutovac; /* Autovac setting after VACUUM if >=0 */ u8 suppressErr; /* Do not issue error messages if true */ + u8 vtabOnConflict; /* Value to return for s3_vtab_on_conflict() */ int nextPagesize; /* Pagesize after VACUUM if >0 */ int nTable; /* Number of tables in the database */ CollSeq *pDfltColl; /* The default collating sequence (BINARY) */ @@ -9207,7 +9479,7 @@ struct sqlite3 { #endif #ifndef SQLITE_OMIT_VIRTUALTABLE Hash aModule; /* populated by sqlite3_create_module() */ - Table *pVTab; /* vtab with active Connect/Create method */ + VtabCtx *pVtabCtx; /* Context for active vtab connect/create */ VTable **aVTrans; /* Virtual tables with open transactions */ int nVTrans; /* Allocated size of aVTrans */ VTable *pDisconnect; /* Disconnect these in next sqlite3_prepare() */ @@ -9291,6 +9563,7 @@ struct sqlite3 { #define SQLITE_IndexCover 0x10 /* Disable index covering table */ #define SQLITE_GroupByOrder 0x20 /* Disable GROUPBY cover of ORDERBY */ #define SQLITE_FactorOutConst 0x40 /* Disable factoring out constants */ +#define SQLITE_IdxRealAsInt 0x80 /* Store REAL as INT in indices */ #define SQLITE_OptMask 0xff /* Mask of all disablable opts */ /* @@ -9570,6 +9843,8 @@ struct VTable { Module *pMod; /* Pointer to module implementation */ sqlite3_vtab *pVtab; /* Pointer to vtab instance */ int nRef; /* Number of pointers to this structure */ + u8 bConstraint; /* True if constraints are supported */ + int iSavepoint; /* Depth of the SAVEPOINT stack */ VTable *pNext; /* Next in linked list (see above) */ }; @@ -10564,9 +10839,8 @@ struct Parse { ** each recursion */ int nVar; /* Number of '?' variables seen in the SQL so far */ - int nVarExpr; /* Number of used slots in apVarExpr[] */ - int nVarExprAlloc; /* Number of allocated slots in apVarExpr[] */ - Expr **apVarExpr; /* Pointers to :aaa and $aaaa wildcard expressions */ + int nzVar; /* Number of available slots in azVar[] */ + char **azVar; /* Pointers to names of parameters */ Vdbe *pReprepare; /* VM being reprepared (sqlite3Reprepare()) */ int nAlias; /* Number of aliased result set columns */ int nAliasAlloc; /* Number of allocated slots for aAlias[] */ @@ -10758,6 +11032,7 @@ struct Sqlite3Config { int bMemstat; /* True to enable memory status */ int bCoreMutex; /* True to enable core mutexing */ int bFullMutex; /* True to enable full mutexing */ + int bOpenUri; /* True to interpret filenames as URIs */ int mxStrlen; /* Maximum string length */ int szLookaside; /* Default lookaside buffer size */ int nLookaside; /* Default lookaside buffer count */ @@ -10786,6 +11061,7 @@ struct Sqlite3Config { int nRefInitMutex; /* Number of users of pInitMutex */ void (*xLog)(void*,int,const char*); /* Function for logging */ void *pLogArg; /* First argument to xLog() */ + int bLocaltimeFault; /* True to fail localtime() calls */ }; /* @@ -11007,6 +11283,8 @@ SQLITE_PRIVATE void sqlite3AddColumnType(Parse*,Token*); SQLITE_PRIVATE void sqlite3AddDefaultValue(Parse*,ExprSpan*); SQLITE_PRIVATE void sqlite3AddCollateType(Parse*, Token*); SQLITE_PRIVATE void sqlite3EndTable(Parse*,Token*,Token*,Select*); +SQLITE_PRIVATE int sqlite3ParseUri(const char*,const char*,unsigned int*, + sqlite3_vfs**,char**,char **); SQLITE_PRIVATE Bitvec *sqlite3BitvecCreate(u32); SQLITE_PRIVATE int sqlite3BitvecTest(Bitvec*, u32); @@ -11211,7 +11489,7 @@ SQLITE_PRIVATE int sqlite3GetInt32(const char *, int*); SQLITE_PRIVATE int sqlite3Atoi(const char*); SQLITE_PRIVATE int sqlite3Utf16ByteLen(const void *pData, int nChar); SQLITE_PRIVATE int sqlite3Utf8CharLen(const char *pData, int nByte); -SQLITE_PRIVATE int sqlite3Utf8Read(const u8*, const u8**); +SQLITE_PRIVATE u32 sqlite3Utf8Read(const u8*, const u8**); /* ** Routines to read and write variable-length integers. These used to @@ -11257,6 +11535,7 @@ SQLITE_PRIVATE char sqlite3ExprAffinity(Expr *pExpr); SQLITE_PRIVATE int sqlite3Atoi64(const char*, i64*, int, u8); SQLITE_PRIVATE void sqlite3Error(sqlite3*, int, const char*,...); SQLITE_PRIVATE void *sqlite3HexToBlob(sqlite3*, const char *z, int n); +SQLITE_PRIVATE u8 sqlite3HexToInt(int h); SQLITE_PRIVATE int sqlite3TwoPartName(Parse *, Token *, Token *, Token **); SQLITE_PRIVATE const char *sqlite3ErrStr(int); SQLITE_PRIVATE int sqlite3ReadSchema(Parse *pParse); @@ -11272,6 +11551,12 @@ SQLITE_PRIVATE int sqlite3AddInt64(i64*,i64); SQLITE_PRIVATE int sqlite3SubInt64(i64*,i64); SQLITE_PRIVATE int sqlite3MulInt64(i64*,i64); SQLITE_PRIVATE int sqlite3AbsInt32(int); +#ifdef SQLITE_ENABLE_8_3_NAMES +SQLITE_PRIVATE void sqlite3FileSuffix3(const char*, char*); +#else +# define sqlite3FileSuffix3(X,Y) +#endif +SQLITE_PRIVATE u8 sqlite3GetBoolean(const char *z); SQLITE_PRIVATE const void *sqlite3ValueText(sqlite3_value*, u8); SQLITE_PRIVATE int sqlite3ValueBytes(sqlite3_value*, u8); @@ -11381,6 +11666,7 @@ SQLITE_PRIVATE int sqlite3Utf8To8(unsigned char*); # define sqlite3VtabLock(X) # define sqlite3VtabUnlock(X) # define sqlite3VtabUnlockList(X) +# define sqlite3VtabSavepoint(X, Y, Z) SQLITE_OK #else SQLITE_PRIVATE void sqlite3VtabClear(sqlite3 *db, Table*); SQLITE_PRIVATE int sqlite3VtabSync(sqlite3 *db, char **); @@ -11389,6 +11675,7 @@ SQLITE_PRIVATE int sqlite3VtabCommit(sqlite3 *db); SQLITE_PRIVATE void sqlite3VtabLock(VTable *); SQLITE_PRIVATE void sqlite3VtabUnlock(VTable *); SQLITE_PRIVATE void sqlite3VtabUnlockList(sqlite3*); +SQLITE_PRIVATE int sqlite3VtabSavepoint(sqlite3 *, int, int); # define sqlite3VtabInSync(db) ((db)->nVTrans>0 && (db)->aVTrans==0) #endif SQLITE_PRIVATE void sqlite3VtabMakeWritable(Parse*,Table*); @@ -11695,7 +11982,9 @@ SQLITE_PRIVATE const unsigned char sqlite3CtypeMap[256] = { }; #endif - +#ifndef SQLITE_USE_URI +# define SQLITE_USE_URI 0 +#endif /* ** The following singleton contains the global configuration for @@ -11705,6 +11994,7 @@ SQLITE_PRIVATE SQLITE_WSD struct Sqlite3Config sqlite3Config = { SQLITE_DEFAULT_MEMSTATUS, /* bMemstat */ 1, /* bCoreMutex */ SQLITE_THREADSAFE==1, /* bFullMutex */ + SQLITE_USE_URI, /* bOpenUri */ 0x7ffffffe, /* mxStrlen */ 100, /* szLookaside */ 500, /* nLookaside */ @@ -11732,6 +12022,7 @@ SQLITE_PRIVATE SQLITE_WSD struct Sqlite3Config sqlite3Config = { 0, /* nRefInitMutex */ 0, /* xLog */ 0, /* pLogArg */ + 0, /* bLocaltimeFault */ }; @@ -12484,11 +12775,11 @@ struct Vdbe { Mem *aVar; /* Values for the OP_Variable opcode. */ char **azVar; /* Name of variables */ ynVar nVar; /* Number of entries in aVar[] */ + ynVar nzVar; /* Number of entries in azVar[] */ u32 cacheCtr; /* VdbeCursor row cache generation counter */ int pc; /* The program counter */ int rc; /* Value to return */ u8 errorAction; /* Recovery action to do in case of an error */ - u8 okVar; /* True if azVar[] has been initialized */ u8 explain; /* True if EXPLAIN present on SQL command */ u8 changeCntOn; /* True to update the change-counter */ u8 expired; /* True if the VM needs to be recompiled */ @@ -12882,22 +13173,6 @@ SQLITE_API int sqlite3_db_status( #ifndef SQLITE_OMIT_DATETIME_FUNCS -/* -** On recent Windows platforms, the localtime_s() function is available -** as part of the "Secure CRT". It is essentially equivalent to -** localtime_r() available under most POSIX platforms, except that the -** order of the parameters is reversed. -** -** See http://msdn.microsoft.com/en-us/library/a442x3ye(VS.80).aspx. -** -** If the user has not indicated to use localtime_r() or localtime_s() -** already, check for an MSVC build environment that provides -** localtime_s(). -*/ -#if !defined(HAVE_LOCALTIME_R) && !defined(HAVE_LOCALTIME_S) && \ - defined(_MSC_VER) && defined(_CRT_INSECURE_DEPRECATE) -#define HAVE_LOCALTIME_S 1 -#endif /* ** A structure for holding a single date and time. @@ -13243,15 +13518,83 @@ static void clearYMD_HMS_TZ(DateTime *p){ p->validTZ = 0; } +/* +** On recent Windows platforms, the localtime_s() function is available +** as part of the "Secure CRT". It is essentially equivalent to +** localtime_r() available under most POSIX platforms, except that the +** order of the parameters is reversed. +** +** See http://msdn.microsoft.com/en-us/library/a442x3ye(VS.80).aspx. +** +** If the user has not indicated to use localtime_r() or localtime_s() +** already, check for an MSVC build environment that provides +** localtime_s(). +*/ +#if !defined(HAVE_LOCALTIME_R) && !defined(HAVE_LOCALTIME_S) && \ + defined(_MSC_VER) && defined(_CRT_INSECURE_DEPRECATE) +#define HAVE_LOCALTIME_S 1 +#endif + +#ifndef SQLITE_OMIT_LOCALTIME +/* +** The following routine implements the rough equivalent of localtime_r() +** using whatever operating-system specific localtime facility that +** is available. This routine returns 0 on success and +** non-zero on any kind of error. +** +** If the sqlite3GlobalConfig.bLocaltimeFault variable is true then this +** routine will always fail. +*/ +static int osLocaltime(time_t *t, struct tm *pTm){ + int rc; +#if (!defined(HAVE_LOCALTIME_R) || !HAVE_LOCALTIME_R) \ + && (!defined(HAVE_LOCALTIME_S) || !HAVE_LOCALTIME_S) + struct tm *pX; + sqlite3_mutex *mutex = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER); + sqlite3_mutex_enter(mutex); + pX = localtime(t); +#ifndef SQLITE_OMIT_BUILTIN_TEST + if( sqlite3GlobalConfig.bLocaltimeFault ) pX = 0; +#endif + if( pX ) *pTm = *pX; + sqlite3_mutex_leave(mutex); + rc = pX==0; +#else +#ifndef SQLITE_OMIT_BUILTIN_TEST + if( sqlite3GlobalConfig.bLocaltimeFault ) return 1; +#endif +#if defined(HAVE_LOCALTIME_R) && HAVE_LOCALTIME_R + rc = localtime_r(t, pTm)==0; +#else + rc = localtime_s(pTm, t); +#endif /* HAVE_LOCALTIME_R */ +#endif /* HAVE_LOCALTIME_R || HAVE_LOCALTIME_S */ + return rc; +} +#endif /* SQLITE_OMIT_LOCALTIME */ + + #ifndef SQLITE_OMIT_LOCALTIME /* -** Compute the difference (in milliseconds) -** between localtime and UTC (a.k.a. GMT) -** for the time value p where p is in UTC. +** Compute the difference (in milliseconds) between localtime and UTC +** (a.k.a. GMT) for the time value p where p is in UTC. If no error occurs, +** return this value and set *pRc to SQLITE_OK. +** +** Or, if an error does occur, set *pRc to SQLITE_ERROR. The returned value +** is undefined in this case. */ -static sqlite3_int64 localtimeOffset(DateTime *p){ +static sqlite3_int64 localtimeOffset( + DateTime *p, /* Date at which to calculate offset */ + sqlite3_context *pCtx, /* Write error here if one occurs */ + int *pRc /* OUT: Error code. SQLITE_OK or ERROR */ +){ DateTime x, y; time_t t; + struct tm sLocal; + + /* Initialize the contents of sLocal to avoid a compiler warning. */ + memset(&sLocal, 0, sizeof(sLocal)); + x = *p; computeYMD_HMS(&x); if( x.Y<1971 || x.Y>=2038 ){ @@ -13269,47 +13612,23 @@ static sqlite3_int64 localtimeOffset(DateTime *p){ x.validJD = 0; computeJD(&x); t = (time_t)(x.iJD/1000 - 21086676*(i64)10000); -#ifdef HAVE_LOCALTIME_R - { - struct tm sLocal; - localtime_r(&t, &sLocal); - y.Y = sLocal.tm_year + 1900; - y.M = sLocal.tm_mon + 1; - y.D = sLocal.tm_mday; - y.h = sLocal.tm_hour; - y.m = sLocal.tm_min; - y.s = sLocal.tm_sec; - } -#elif defined(HAVE_LOCALTIME_S) && HAVE_LOCALTIME_S - { - struct tm sLocal; - localtime_s(&sLocal, &t); - y.Y = sLocal.tm_year + 1900; - y.M = sLocal.tm_mon + 1; - y.D = sLocal.tm_mday; - y.h = sLocal.tm_hour; - y.m = sLocal.tm_min; - y.s = sLocal.tm_sec; - } -#else - { - struct tm *pTm; - sqlite3_mutex_enter(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER)); - pTm = localtime(&t); - y.Y = pTm->tm_year + 1900; - y.M = pTm->tm_mon + 1; - y.D = pTm->tm_mday; - y.h = pTm->tm_hour; - y.m = pTm->tm_min; - y.s = pTm->tm_sec; - sqlite3_mutex_leave(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER)); + if( osLocaltime(&t, &sLocal) ){ + sqlite3_result_error(pCtx, "local time unavailable", -1); + *pRc = SQLITE_ERROR; + return 0; } -#endif + y.Y = sLocal.tm_year + 1900; + y.M = sLocal.tm_mon + 1; + y.D = sLocal.tm_mday; + y.h = sLocal.tm_hour; + y.m = sLocal.tm_min; + y.s = sLocal.tm_sec; y.validYMD = 1; y.validHMS = 1; y.validJD = 0; y.validTZ = 0; computeJD(&y); + *pRc = SQLITE_OK; return y.iJD - x.iJD; } #endif /* SQLITE_OMIT_LOCALTIME */ @@ -13333,9 +13652,12 @@ static sqlite3_int64 localtimeOffset(DateTime *p){ ** localtime ** utc ** -** Return 0 on success and 1 if there is any kind of error. +** Return 0 on success and 1 if there is any kind of error. If the error +** is in a system call (i.e. localtime()), then an error message is written +** to context pCtx. If the error is an unrecognized modifier, no error is +** written to pCtx. */ -static int parseModifier(const char *zMod, DateTime *p){ +static int parseModifier(sqlite3_context *pCtx, const char *zMod, DateTime *p){ int rc = 1; int n; double r; @@ -13355,9 +13677,8 @@ static int parseModifier(const char *zMod, DateTime *p){ */ if( strcmp(z, "localtime")==0 ){ computeJD(p); - p->iJD += localtimeOffset(p); + p->iJD += localtimeOffset(p, pCtx, &rc); clearYMD_HMS_TZ(p); - rc = 0; } break; } @@ -13378,11 +13699,12 @@ static int parseModifier(const char *zMod, DateTime *p){ else if( strcmp(z, "utc")==0 ){ sqlite3_int64 c1; computeJD(p); - c1 = localtimeOffset(p); - p->iJD -= c1; - clearYMD_HMS_TZ(p); - p->iJD += c1 - localtimeOffset(p); - rc = 0; + c1 = localtimeOffset(p, pCtx, &rc); + if( rc==SQLITE_OK ){ + p->iJD -= c1; + clearYMD_HMS_TZ(p); + p->iJD += c1 - localtimeOffset(p, pCtx, &rc); + } } #endif break; @@ -13563,9 +13885,8 @@ static int isDate( } } for(i=1; i= mem0.alarmThreshold ){ + if( nUsed >= mem0.alarmThreshold - nFull ){ mem0.nearlyFull = 1; sqlite3MallocAlarm(nFull); }else{ @@ -18195,7 +18516,7 @@ SQLITE_PRIVATE void sqlite3DbFree(sqlite3 *db, void *p){ ** Change the size of an existing memory allocation */ SQLITE_PRIVATE void *sqlite3Realloc(void *pOld, int nBytes){ - int nOld, nNew; + int nOld, nNew, nDiff; void *pNew; if( pOld==0 ){ return sqlite3Malloc(nBytes); /* IMP: R-28354-25769 */ @@ -18218,9 +18539,10 @@ SQLITE_PRIVATE void *sqlite3Realloc(void *pOld, int nBytes){ }else if( sqlite3GlobalConfig.bMemstat ){ sqlite3_mutex_enter(mem0.mutex); sqlite3StatusSet(SQLITE_STATUS_MALLOC_SIZE, nBytes); - if( sqlite3StatusValue(SQLITE_STATUS_MEMORY_USED)+nNew-nOld >= - mem0.alarmThreshold ){ - sqlite3MallocAlarm(nNew-nOld); + nDiff = nNew - nOld; + if( sqlite3StatusValue(SQLITE_STATUS_MEMORY_USED) >= + mem0.alarmThreshold-nDiff ){ + sqlite3MallocAlarm(nDiff); } assert( sqlite3MemdebugHasType(pOld, MEMTYPE_HEAP) ); assert( sqlite3MemdebugNoType(pOld, ~MEMTYPE_HEAP) ); @@ -19805,7 +20127,7 @@ static const unsigned char sqlite3Utf8Trans1[] = { || (c&0xFFFFF800)==0xD800 \ || (c&0xFFFFFFFE)==0xFFFE ){ c = 0xFFFD; } \ } -SQLITE_PRIVATE int sqlite3Utf8Read( +SQLITE_PRIVATE u32 sqlite3Utf8Read( const unsigned char *zIn, /* First byte of UTF-8 character */ const unsigned char **pzNext /* Write first byte past UTF-8 char here */ ){ @@ -21186,13 +21508,12 @@ SQLITE_PRIVATE void sqlite3Put4byte(unsigned char *p, u32 v){ -#if !defined(SQLITE_OMIT_BLOB_LITERAL) || defined(SQLITE_HAS_CODEC) /* ** Translate a single byte of Hex into an integer. ** This routine only works if h really is a valid hexadecimal ** character: 0..9a..fA..F */ -static u8 hexToInt(int h){ +SQLITE_PRIVATE u8 sqlite3HexToInt(int h){ assert( (h>='0' && h<='9') || (h>='a' && h<='f') || (h>='A' && h<='F') ); #ifdef SQLITE_ASCII h += 9*(1&(h>>6)); @@ -21202,7 +21523,6 @@ static u8 hexToInt(int h){ #endif return (u8)(h & 0xf); } -#endif /* !SQLITE_OMIT_BLOB_LITERAL || SQLITE_HAS_CODEC */ #if !defined(SQLITE_OMIT_BLOB_LITERAL) || defined(SQLITE_HAS_CODEC) /* @@ -21219,7 +21539,7 @@ SQLITE_PRIVATE void *sqlite3HexToBlob(sqlite3 *db, const char *z, int n){ n--; if( zBlob ){ for(i=0; i test.nal +** test.db-wal => test.wal +** test.db-shm => test.shm +*/ +SQLITE_PRIVATE void sqlite3FileSuffix3(const char *zBaseFilename, char *z){ + const char *zOk; + zOk = sqlite3_uri_parameter(zBaseFilename, "8_3_names"); + if( zOk && sqlite3GetBoolean(zOk) ){ + int i, sz; + sz = sqlite3Strlen30(z); + for(i=sz-1; i>0 && z[i]!='/' && z[i]!='.'; i--){} + if( z[i]=='.' && ALWAYS(sz>i+4) ) memcpy(&z[i+1], &z[sz-3], 4); + } +} +#endif + /************** End of util.c ************************************************/ /************** Begin file hash.c ********************************************/ /* @@ -24058,6 +24404,10 @@ SQLITE_API int sqlite3_os_end(void){ # include #endif +#ifdef HAVE_UTIME +# include +#endif + /* ** Allowed values of unixFile.fsFlags */ @@ -24405,6 +24755,18 @@ SQLITE_API int sqlite3_open_file_count = 0; #define threadid 0 #endif +/* +** Different Unix systems declare open() in different ways. Same use +** open(const char*,int,mode_t). Others use open(const char*,int,...). +** The difference is important when using a pointer to the function. +** +** The safest way to deal with the problem is to always use this wrapper +** which always has the same well-defined interface. +*/ +static int posixOpen(const char *zFile, int flags, int mode){ + return open(zFile, flags, mode); +} + /* ** Many system calls are accessed through pointer-to-functions so that ** they may be overridden at runtime to facilitate fault injection during @@ -24416,8 +24778,8 @@ static struct unix_syscall { sqlite3_syscall_ptr pCurrent; /* Current value of the system call */ sqlite3_syscall_ptr pDefault; /* Default value */ } aSyscall[] = { - { "open", (sqlite3_syscall_ptr)open, 0 }, -#define osOpen ((int(*)(const char*,int,...))aSyscall[0].pCurrent) + { "open", (sqlite3_syscall_ptr)posixOpen, 0 }, +#define osOpen ((int(*)(const char*,int,int))aSyscall[0].pCurrent) { "close", (sqlite3_syscall_ptr)close, 0 }, #define osClose ((int(*)(int))aSyscall[1].pCurrent) @@ -24454,7 +24816,7 @@ static struct unix_syscall { { "read", (sqlite3_syscall_ptr)read, 0 }, #define osRead ((ssize_t(*)(int,void*,size_t))aSyscall[8].pCurrent) -#if defined(USE_PREAD) || defined(SQLITE_ENABLE_LOCKING_STYLE) +#if defined(USE_PREAD) || SQLITE_ENABLE_LOCKING_STYLE { "pread", (sqlite3_syscall_ptr)pread, 0 }, #else { "pread", (sqlite3_syscall_ptr)0, 0 }, @@ -24471,7 +24833,7 @@ static struct unix_syscall { { "write", (sqlite3_syscall_ptr)write, 0 }, #define osWrite ((ssize_t(*)(int,const void*,size_t))aSyscall[11].pCurrent) -#if defined(USE_PREAD) || defined(SQLITE_ENABLE_LOCKING_STYLE) +#if defined(USE_PREAD) || SQLITE_ENABLE_LOCKING_STYLE { "pwrite", (sqlite3_syscall_ptr)pwrite, 0 }, #else { "pwrite", (sqlite3_syscall_ptr)0, 0 }, @@ -25057,7 +25419,7 @@ struct unixInodeInfo { UnixUnusedFd *pUnused; /* Unused file descriptors to close */ unixInodeInfo *pNext; /* List of all unixInodeInfo objects */ unixInodeInfo *pPrev; /* .... doubly linked */ -#if defined(SQLITE_ENABLE_LOCKING_STYLE) +#if SQLITE_ENABLE_LOCKING_STYLE unsigned long long sharedByte; /* for AFP simulated shared lock */ #endif #if OS_VXWORKS @@ -26051,8 +26413,10 @@ static int dotlockLock(sqlite3_file *id, int eFileLock) { */ if( pFile->eFileLock > NO_LOCK ){ pFile->eFileLock = eFileLock; -#if !OS_VXWORKS /* Always update the timestamp on the old file */ +#ifdef HAVE_UTIME + utime(zLockFile, NULL); +#else utimes(zLockFile, NULL); #endif return SQLITE_OK; @@ -27214,7 +27578,7 @@ static int unixWrite( SimulateDiskfullError(( wrote=0, amt=1 )); if( amt>0 ){ - if( wrote<0 ){ + if( wrote<0 && pFile->lastErrno!=ENOSPC ){ /* lastErrno set by seekAndWrite */ return SQLITE_IOERR_WRITE; }else{ @@ -27649,7 +28013,8 @@ struct unixShmNode { char *zFilename; /* Name of the mmapped file */ int h; /* Open file descriptor */ int szRegion; /* Size of shared-memory regions */ - int nRegion; /* Size of array apRegion */ + u16 nRegion; /* Size of array apRegion */ + u8 isReadonly; /* True if read-only */ char **apRegion; /* Array of mapped shared-memory regions */ int nRef; /* Number of unixShm objects pointing to this */ unixShm *pFirst; /* All unixShm objects pointing to this */ @@ -27881,6 +28246,7 @@ static int unixOpenSharedMemory(unixFile *pDbFd){ (u32)sStat.st_ino, (u32)sStat.st_dev); #else sqlite3_snprintf(nShmFilename, zShmFilename, "%s-shm", pDbFd->zPath); + sqlite3FileSuffix3(pDbFd->zPath, zShmFilename); #endif pShmNode->h = -1; pDbFd->pInode->pShmNode = pShmNode; @@ -27895,8 +28261,17 @@ static int unixOpenSharedMemory(unixFile *pDbFd){ pShmNode->h = robust_open(zShmFilename, O_RDWR|O_CREAT, (sStat.st_mode & 0777)); if( pShmNode->h<0 ){ - rc = unixLogError(SQLITE_CANTOPEN_BKPT, "open", zShmFilename); - goto shm_open_err; + const char *zRO; + zRO = sqlite3_uri_parameter(pDbFd->zPath, "readonly_shm"); + if( zRO && sqlite3GetBoolean(zRO) ){ + pShmNode->h = robust_open(zShmFilename, O_RDONLY, + (sStat.st_mode & 0777)); + pShmNode->isReadonly = 1; + } + if( pShmNode->h<0 ){ + rc = unixLogError(SQLITE_CANTOPEN_BKPT, "open", zShmFilename); + goto shm_open_err; + } } /* Check to see if another process is holding the dead-man switch. @@ -28035,11 +28410,12 @@ static int unixShmMap( while(pShmNode->nRegion<=iRegion){ void *pMem; if( pShmNode->h>=0 ){ - pMem = mmap(0, szRegion, PROT_READ|PROT_WRITE, + pMem = mmap(0, szRegion, + pShmNode->isReadonly ? PROT_READ : PROT_READ|PROT_WRITE, MAP_SHARED, pShmNode->h, pShmNode->nRegion*szRegion ); if( pMem==MAP_FAILED ){ - rc = SQLITE_IOERR; + rc = unixLogError(SQLITE_IOERR_SHMMAP, "mmap", pShmNode->zFilename); goto shmpage_out; } }else{ @@ -28061,6 +28437,7 @@ static int unixShmMap( }else{ *pp = 0; } + if( pShmNode->isReadonly && rc==SQLITE_OK ) rc = SQLITE_READONLY; sqlite3_mutex_leave(pShmNode->mutex); return rc; } @@ -28914,6 +29291,11 @@ static UnixUnusedFd *findReusableFd(const char *zPath, int flags){ ** corresponding database file and sets *pMode to this value. Whenever ** possible, WAL and journal files are created using the same permissions ** as the associated database file. +** +** If the SQLITE_ENABLE_8_3_NAMES option is enabled, then the +** original filename is unavailable. But 8_3_NAMES is only used for +** FAT filesystems and permissions do not matter there, so just use +** the default permissions. */ static int findCreateFileMode( const char *zPath, /* Path of file (possibly) being created */ @@ -28921,6 +29303,7 @@ static int findCreateFileMode( mode_t *pMode /* OUT: Permissions to open file with */ ){ int rc = SQLITE_OK; /* Return Code */ + *pMode = SQLITE_DEFAULT_FILE_PERMISSIONS; if( flags & (SQLITE_OPEN_WAL|SQLITE_OPEN_MAIN_JOURNAL) ){ char zDb[MAX_PATHNAME+1]; /* Database file path */ int nDb; /* Number of valid bytes in zDb */ @@ -28932,15 +29315,15 @@ static int findCreateFileMode( ** ** "-journal" ** "-wal" - ** "-journal-NNNN" - ** "-wal-NNNN" + ** "-journalNN" + ** "-walNN" ** - ** where NNNN is a 4 digit decimal number. The NNNN naming schemes are + ** where NN is a 4 digit decimal number. The NN naming schemes are ** used by the test_multiplex.c module. */ nDb = sqlite3Strlen30(zPath) - 1; - while( nDb>0 && zPath[nDb]!='l' ) nDb--; - nDb -= ((flags & SQLITE_OPEN_WAL) ? 3 : 7); + while( nDb>0 && zPath[nDb]!='-' ) nDb--; + if( nDb==0 ) return SQLITE_OK; memcpy(zDb, zPath, nDb); zDb[nDb] = '\0'; @@ -28951,8 +29334,6 @@ static int findCreateFileMode( } }else if( flags & SQLITE_OPEN_DELETEONCLOSE ){ *pMode = 0600; - }else{ - *pMode = SQLITE_DEFAULT_FILE_PERMISSIONS; } return rc; } @@ -31160,6 +31541,7 @@ struct winFile { #endif }; + /* ** Forward prototypes. */ @@ -31327,7 +31709,7 @@ SQLITE_API char *sqlite3_win32_mbcs_to_utf8(const char *zFilename){ ** Convert UTF-8 to multibyte character string. Space to hold the ** returned string is obtained from malloc(). */ -static char *utf8ToMbcs(const char *zFilename){ +SQLITE_API char *sqlite3_win32_utf8_to_mbcs(const char *zFilename){ char *zFilenameMbcs; WCHAR *zTmpWide; @@ -31340,6 +31722,109 @@ static char *utf8ToMbcs(const char *zFilename){ return zFilenameMbcs; } + +/* +** The return value of getLastErrorMsg +** is zero if the error message fits in the buffer, or non-zero +** otherwise (if the message was truncated). +*/ +static int getLastErrorMsg(int nBuf, char *zBuf){ + /* FormatMessage returns 0 on failure. Otherwise it + ** returns the number of TCHARs written to the output + ** buffer, excluding the terminating null char. + */ + DWORD error = GetLastError(); + DWORD dwLen = 0; + char *zOut = 0; + + if( isNT() ){ + WCHAR *zTempWide = NULL; + dwLen = FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, + NULL, + error, + 0, + (LPWSTR) &zTempWide, + 0, + 0); + if( dwLen > 0 ){ + /* allocate a buffer and convert to UTF8 */ + zOut = unicodeToUtf8(zTempWide); + /* free the system buffer allocated by FormatMessage */ + LocalFree(zTempWide); + } +/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed. +** Since the ASCII version of these Windows API do not exist for WINCE, +** it's important to not reference them for WINCE builds. +*/ +#if SQLITE_OS_WINCE==0 + }else{ + char *zTemp = NULL; + dwLen = FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, + NULL, + error, + 0, + (LPSTR) &zTemp, + 0, + 0); + if( dwLen > 0 ){ + /* allocate a buffer and convert to UTF8 */ + zOut = sqlite3_win32_mbcs_to_utf8(zTemp); + /* free the system buffer allocated by FormatMessage */ + LocalFree(zTemp); + } +#endif + } + if( 0 == dwLen ){ + sqlite3_snprintf(nBuf, zBuf, "OsError 0x%x (%u)", error, error); + }else{ + /* copy a maximum of nBuf chars to output buffer */ + sqlite3_snprintf(nBuf, zBuf, "%s", zOut); + /* free the UTF8 buffer */ + free(zOut); + } + return 0; +} + +/* +** +** This function - winLogErrorAtLine() - is only ever called via the macro +** winLogError(). +** +** This routine is invoked after an error occurs in an OS function. +** It logs a message using sqlite3_log() containing the current value of +** error code and, if possible, the human-readable equivalent from +** FormatMessage. +** +** The first argument passed to the macro should be the error code that +** will be returned to SQLite (e.g. SQLITE_IOERR_DELETE, SQLITE_CANTOPEN). +** The two subsequent arguments should be the name of the OS function that +** failed and the the associated file-system path, if any. +*/ +#define winLogError(a,b,c) winLogErrorAtLine(a,b,c,__LINE__) +static int winLogErrorAtLine( + int errcode, /* SQLite error code */ + const char *zFunc, /* Name of OS function that failed */ + const char *zPath, /* File path associated with error */ + int iLine /* Source line number where error occurred */ +){ + char zMsg[500]; /* Human readable error text */ + int i; /* Loop counter */ + DWORD iErrno = GetLastError(); /* Error code */ + + zMsg[0] = 0; + getLastErrorMsg(sizeof(zMsg), zMsg); + assert( errcode!=SQLITE_OK ); + if( zPath==0 ) zPath = ""; + for(i=0; zMsg[i] && zMsg[i]!='\r' && zMsg[i]!='\n'; i++){} + zMsg[i] = 0; + sqlite3_log(errcode, + "os_win.c:%d: (%d) %s(%s) - %s", + iLine, iErrno, zFunc, zPath, zMsg + ); + + return errcode; +} + #if SQLITE_OS_WINCE /************************************************************************* ** This section contains code for WinCE only. @@ -31416,6 +31901,7 @@ static BOOL winceCreateLock(const char *zFilename, winFile *pFile){ pFile->hMutex = CreateMutexW(NULL, FALSE, zName); if (!pFile->hMutex){ pFile->lastErrno = GetLastError(); + winLogError(SQLITE_ERROR, "winceCreateLock1", zFilename); free(zName); return FALSE; } @@ -31447,6 +31933,7 @@ static BOOL winceCreateLock(const char *zFilename, winFile *pFile){ /* If mapping failed, close the shared memory handle and erase it */ if (!pFile->shared){ pFile->lastErrno = GetLastError(); + winLogError(SQLITE_ERROR, "winceCreateLock2", zFilename); CloseHandle(pFile->hShared); pFile->hShared = NULL; } @@ -31692,6 +32179,7 @@ static int seekWinFile(winFile *pFile, sqlite3_int64 iOffset){ dwRet = SetFilePointer(pFile->h, lowerBits, &upperBits, FILE_BEGIN); if( (dwRet==INVALID_SET_FILE_POINTER && GetLastError()!=NO_ERROR) ){ pFile->lastErrno = GetLastError(); + winLogError(SQLITE_IOERR_SEEK, "seekWinFile", pFile->zPath); return 1; } @@ -31737,7 +32225,8 @@ static int winClose(sqlite3_file *id){ #endif OSTRACE(("CLOSE %d %s\n", pFile->h, rc ? "ok" : "failed")); OpenCounter(-1); - return rc ? SQLITE_OK : SQLITE_IOERR; + return rc ? SQLITE_OK + : winLogError(SQLITE_IOERR_CLOSE, "winClose", pFile->zPath); } /* @@ -31763,7 +32252,7 @@ static int winRead( } if( !ReadFile(pFile->h, pBuf, amt, &nRead, 0) ){ pFile->lastErrno = GetLastError(); - return SQLITE_IOERR_READ; + return winLogError(SQLITE_IOERR_READ, "winRead", pFile->zPath); } if( nRead<(DWORD)amt ){ /* Unread parts of the buffer must be zero-filled */ @@ -31811,10 +32300,11 @@ static int winWrite( } if( rc ){ - if( pFile->lastErrno==ERROR_HANDLE_DISK_FULL ){ + if( ( pFile->lastErrno==ERROR_HANDLE_DISK_FULL ) + || ( pFile->lastErrno==ERROR_DISK_FULL )){ return SQLITE_FULL; } - return SQLITE_IOERR_WRITE; + return winLogError(SQLITE_IOERR_WRITE, "winWrite", pFile->zPath); } return SQLITE_OK; } @@ -31842,10 +32332,10 @@ static int winTruncate(sqlite3_file *id, sqlite3_int64 nByte){ /* SetEndOfFile() returns non-zero when successful, or zero when it fails. */ if( seekWinFile(pFile, nByte) ){ - rc = SQLITE_IOERR_TRUNCATE; + rc = winLogError(SQLITE_IOERR_TRUNCATE, "winTruncate1", pFile->zPath); }else if( 0==SetEndOfFile(pFile->h) ){ pFile->lastErrno = GetLastError(); - rc = SQLITE_IOERR_TRUNCATE; + rc = winLogError(SQLITE_IOERR_TRUNCATE, "winTruncate2", pFile->zPath); } OSTRACE(("TRUNCATE %d %lld %s\n", pFile->h, nByte, rc ? "failed" : "ok")); @@ -31867,6 +32357,7 @@ SQLITE_API int sqlite3_fullsync_count = 0; static int winSync(sqlite3_file *id, int flags){ #if !defined(NDEBUG) || !defined(SQLITE_NO_SYNC) || defined(SQLITE_DEBUG) winFile *pFile = (winFile*)id; + BOOL rc; #else UNUSED_PARAMETER(id); #endif @@ -31879,32 +32370,33 @@ static int winSync(sqlite3_file *id, int flags){ OSTRACE(("SYNC %d lock=%d\n", pFile->h, pFile->locktype)); + /* Unix cannot, but some systems may return SQLITE_FULL from here. This + ** line is to test that doing so does not cause any problems. + */ + SimulateDiskfullError( return SQLITE_FULL ); + #ifndef SQLITE_TEST UNUSED_PARAMETER(flags); #else - if( flags & SQLITE_SYNC_FULL ){ + if( (flags&0x0F)==SQLITE_SYNC_FULL ){ sqlite3_fullsync_count++; } sqlite3_sync_count++; #endif - /* Unix cannot, but some systems may return SQLITE_FULL from here. This - ** line is to test that doing so does not cause any problems. - */ - SimulateDiskfullError( return SQLITE_FULL ); - SimulateIOError( return SQLITE_IOERR; ); - /* If we compiled with the SQLITE_NO_SYNC flag, then syncing is a ** no-op */ #ifdef SQLITE_NO_SYNC return SQLITE_OK; #else - if( FlushFileBuffers(pFile->h) ){ + rc = FlushFileBuffers(pFile->h); + SimulateIOError( rc=FALSE ); + if( rc ){ return SQLITE_OK; }else{ pFile->lastErrno = GetLastError(); - return SQLITE_IOERR; + return winLogError(SQLITE_IOERR_FSYNC, "winSync", pFile->zPath); } #endif } @@ -31925,7 +32417,7 @@ static int winFileSize(sqlite3_file *id, sqlite3_int64 *pSize){ && ((error = GetLastError()) != NO_ERROR) ) { pFile->lastErrno = error; - return SQLITE_IOERR_FSTAT; + return winLogError(SQLITE_IOERR_FSTAT, "winFileSize", pFile->zPath); } *pSize = (((sqlite3_int64)upperBits)<<32) + lowerBits; return SQLITE_OK; @@ -31964,6 +32456,7 @@ static int getReadLock(winFile *pFile){ } if( res == 0 ){ pFile->lastErrno = GetLastError(); + /* No need to log a failure to lock */ } return res; } @@ -31982,8 +32475,9 @@ static int unlockReadLock(winFile *pFile){ res = UnlockFile(pFile->h, SHARED_FIRST + pFile->sharedLockByte, 0, 1, 0); #endif } - if( res == 0 ){ + if( res==0 && GetLastError()!=ERROR_NOT_LOCKED ){ pFile->lastErrno = GetLastError(); + winLogError(SQLITE_IOERR_UNLOCK, "unlockReadLock", pFile->zPath); } return res; } @@ -32184,7 +32678,7 @@ static int winUnlock(sqlite3_file *id, int locktype){ if( locktype==SHARED_LOCK && !getReadLock(pFile) ){ /* This should never happen. We should always be able to ** reacquire the read lock */ - rc = SQLITE_IOERR_UNLOCK; + rc = winLogError(SQLITE_IOERR_UNLOCK, "winUnlock", pFile->zPath); } } if( type>=RESERVED_LOCK ){ @@ -32499,6 +32993,7 @@ static int winOpenSharedMemory(winFile *pDbFd){ memset(pNew, 0, sizeof(*pNew)); pNew->zFilename = (char*)&pNew[1]; sqlite3_snprintf(nName+15, pNew->zFilename, "%s-shm", pDbFd->zPath); + sqlite3FileSuffix3(pDbFd->zPath, pNew->zFilename); /* Look to see if there is an existing winShmNode that can be used. ** If no matching winShmNode currently exists, create a new one. @@ -32541,7 +33036,7 @@ static int winOpenSharedMemory(winFile *pDbFd){ if( winShmSystemLock(pShmNode, _SHM_WRLCK, WIN_SHM_DMS, 1)==SQLITE_OK ){ rc = winTruncate((sqlite3_file *)&pShmNode->hFile, 0); if( rc!=SQLITE_OK ){ - rc = SQLITE_IOERR_SHMOPEN; + rc = winLogError(SQLITE_IOERR_SHMOPEN, "winOpenShm", pDbFd->zPath); } } if( rc==SQLITE_OK ){ @@ -32800,7 +33295,7 @@ static int winShmMap( */ rc = winFileSize((sqlite3_file *)&pShmNode->hFile, &sz); if( rc!=SQLITE_OK ){ - rc = SQLITE_IOERR_SHMSIZE; + rc = winLogError(SQLITE_IOERR_SHMSIZE, "winShmMap1", pDbFd->zPath); goto shmpage_out; } @@ -32814,7 +33309,7 @@ static int winShmMap( if( !isWrite ) goto shmpage_out; rc = winTruncate((sqlite3_file *)&pShmNode->hFile, nByte); if( rc!=SQLITE_OK ){ - rc = SQLITE_IOERR_SHMSIZE; + rc = winLogError(SQLITE_IOERR_SHMSIZE, "winShmMap2", pDbFd->zPath); goto shmpage_out; } } @@ -32851,7 +33346,7 @@ static int winShmMap( } if( !pMap ){ pShmNode->lastErrno = GetLastError(); - rc = SQLITE_IOERR; + rc = winLogError(SQLITE_IOERR_SHMMAP, "winShmMap3", pDbFd->zPath); if( hMap ) CloseHandle(hMap); goto shmpage_out; } @@ -32933,7 +33428,7 @@ static void *convertUtf8Filename(const char *zFilename){ */ #if SQLITE_OS_WINCE==0 }else{ - zConverted = utf8ToMbcs(zFilename); + zConverted = sqlite3_win32_utf8_to_mbcs(zFilename); #endif } /* caller will handle out of memory */ @@ -33013,68 +33508,6 @@ static int getTempname(int nBuf, char *zBuf){ return SQLITE_OK; } -/* -** The return value of getLastErrorMsg -** is zero if the error message fits in the buffer, or non-zero -** otherwise (if the message was truncated). -*/ -static int getLastErrorMsg(int nBuf, char *zBuf){ - /* FormatMessage returns 0 on failure. Otherwise it - ** returns the number of TCHARs written to the output - ** buffer, excluding the terminating null char. - */ - DWORD error = GetLastError(); - DWORD dwLen = 0; - char *zOut = 0; - - if( isNT() ){ - WCHAR *zTempWide = NULL; - dwLen = FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, - NULL, - error, - 0, - (LPWSTR) &zTempWide, - 0, - 0); - if( dwLen > 0 ){ - /* allocate a buffer and convert to UTF8 */ - zOut = unicodeToUtf8(zTempWide); - /* free the system buffer allocated by FormatMessage */ - LocalFree(zTempWide); - } -/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed. -** Since the ASCII version of these Windows API do not exist for WINCE, -** it's important to not reference them for WINCE builds. -*/ -#if SQLITE_OS_WINCE==0 - }else{ - char *zTemp = NULL; - dwLen = FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, - NULL, - error, - 0, - (LPSTR) &zTemp, - 0, - 0); - if( dwLen > 0 ){ - /* allocate a buffer and convert to UTF8 */ - zOut = sqlite3_win32_mbcs_to_utf8(zTemp); - /* free the system buffer allocated by FormatMessage */ - LocalFree(zTemp); - } -#endif - } - if( 0 == dwLen ){ - sqlite3_snprintf(nBuf, zBuf, "OsError 0x%x (%u)", error, error); - }else{ - /* copy a maximum of nBuf chars to output buffer */ - sqlite3_snprintf(nBuf, zBuf, "%s", zOut); - /* free the UTF8 buffer */ - free(zOut); - } - return 0; -} - /* ** Open a file. */ @@ -33246,6 +33679,7 @@ static int winOpen( if( h==INVALID_HANDLE_VALUE ){ pFile->lastErrno = GetLastError(); + winLogError(SQLITE_CANTOPEN, "winOpen", zUtf8Name); free(zConverted); if( isReadWrite ){ return winOpen(pVfs, zName, id, @@ -33349,7 +33783,8 @@ static int winDelete( "ok" : "failed" )); return ( (rc == INVALID_FILE_ATTRIBUTES) - && (error == ERROR_FILE_NOT_FOUND)) ? SQLITE_OK : SQLITE_IOERR_DELETE; + && (error == ERROR_FILE_NOT_FOUND)) ? SQLITE_OK : + winLogError(SQLITE_IOERR_DELETE, "winDelete", zFilename); } /* @@ -33389,6 +33824,7 @@ static int winAccess( } }else{ if( GetLastError()!=ERROR_FILE_NOT_FOUND ){ + winLogError(SQLITE_IOERR_ACCESS, "winAccess", zFilename); free(zConverted); return SQLITE_IOERR_ACCESS; }else{ @@ -33453,6 +33889,13 @@ static int winFullPathname( void *zConverted; char *zOut; + /* If this path name begins with "/X:", where "X" is any alphabetic + ** character, discard the initial "/" from the pathname. + */ + if( zRelative[0]=='/' && sqlite3Isalpha(zRelative[1]) && zRelative[2]==':' ){ + zRelative++; + } + /* It's odd to simulate an io-error here, but really this is just ** using the io-error infrastructure to test that SQLite handles this ** function failing. This function could fail if, for example, the @@ -34493,6 +34936,13 @@ SQLITE_PRIVATE int sqlite3PcacheFetch( } if( pPg ){ int rc; +#ifdef SQLITE_LOG_CACHE_SPILL + sqlite3_log(SQLITE_FULL, + "spill page %d making room for %d - cache used: %d/%d", + pPg->pgno, pgno, + sqlite3GlobalConfig.pcache.xPagecount(pCache->pCache), + pCache->nMax); +#endif rc = pCache->xStress(pCache->pStress, pPg); if( rc!=SQLITE_OK && rc!=SQLITE_BUSY ){ return rc; @@ -35403,7 +35853,7 @@ static sqlite3_pcache *pcache1Create(int szPage, int bPurgeable){ pGroup = (PGroup*)&pCache[1]; pGroup->mxPinned = 10; }else{ - pGroup = &pcache1_g.grp; + pGroup = &pcache1.grp; } pCache->pGroup = pGroup; pCache->szPage = szPage; @@ -36264,6 +36714,7 @@ SQLITE_PRIVATE int sqlite3RowSetTest(RowSet *pRowSet, u8 iBatch, sqlite3_int64 i #ifdef SQLITE_OMIT_WAL # define sqlite3WalOpen(x,y,z) 0 +# define sqlite3WalLimit(x,y) # define sqlite3WalClose(w,x,y,z) 0 # define sqlite3WalBeginReadTransaction(y,z) 0 # define sqlite3WalEndReadTransaction(z) @@ -36289,9 +36740,12 @@ SQLITE_PRIVATE int sqlite3RowSetTest(RowSet *pRowSet, u8 iBatch, sqlite3_int64 i typedef struct Wal Wal; /* Open and close a connection to a write-ahead log. */ -SQLITE_PRIVATE int sqlite3WalOpen(sqlite3_vfs*, sqlite3_file*, const char *zName, int, Wal**); +SQLITE_PRIVATE int sqlite3WalOpen(sqlite3_vfs*, sqlite3_file*, const char *, int, i64, Wal**); SQLITE_PRIVATE int sqlite3WalClose(Wal *pWal, int sync_flags, int, u8 *); +/* Set the limiting size of a WAL file. */ +SQLITE_PRIVATE void sqlite3WalLimit(Wal*, i64); + /* Used by readers to open (lock) and close (unlock) a snapshot. A ** snapshot is like a read-transaction. It is the state of the database ** at an instant in time. sqlite3WalOpenSnapshot gets a read lock and @@ -40640,6 +41094,8 @@ SQLITE_PRIVATE int sqlite3PagerOpen( int noReadlock = (flags & PAGER_NO_READLOCK)!=0; /* True to omit read-lock */ int pcacheSize = sqlite3PcacheSize(); /* Bytes to allocate for PCache */ u32 szPageDflt = SQLITE_DEFAULT_PAGE_SIZE; /* Default page size */ + const char *zUri = 0; /* URI args to copy */ + int nUri = 0; /* Number of bytes of URI args at *zUri */ /* Figure out how much space is required for each journal file-handle ** (there are two of them, the main journal and the sub-journal). This @@ -40670,6 +41126,7 @@ SQLITE_PRIVATE int sqlite3PagerOpen( ** leave both nPathname and zPathname set to 0. */ if( zFilename && zFilename[0] ){ + const char *z; nPathname = pVfs->mxPathname+1; zPathname = sqlite3Malloc(nPathname*2); if( zPathname==0 ){ @@ -40678,6 +41135,12 @@ SQLITE_PRIVATE int sqlite3PagerOpen( zPathname[0] = 0; /* Make sure initialized even if FullPathname() fails */ rc = sqlite3OsFullPathname(pVfs, zFilename, nPathname, zPathname); nPathname = sqlite3Strlen30(zPathname); + z = zUri = &zFilename[sqlite3Strlen30(zFilename)+1]; + while( *z ){ + z += sqlite3Strlen30(z)+1; + z += sqlite3Strlen30(z)+1; + } + nUri = &z[1] - zUri; if( rc==SQLITE_OK && nPathname+8>pVfs->mxPathname ){ /* This branch is taken when the journal path required by ** the database being opened will be more than pVfs->mxPathname @@ -40710,7 +41173,7 @@ SQLITE_PRIVATE int sqlite3PagerOpen( ROUND8(pcacheSize) + /* PCache object */ ROUND8(pVfs->szOsFile) + /* The main db file */ journalFileSize * 2 + /* The two journal files */ - nPathname + 1 + /* zFilename */ + nPathname + 1 + nUri + /* zFilename */ nPathname + 8 + 1 /* zJournal */ #ifndef SQLITE_OMIT_WAL + nPathname + 4 + 1 /* zWal */ @@ -40732,14 +41195,17 @@ SQLITE_PRIVATE int sqlite3PagerOpen( /* Fill in the Pager.zFilename and Pager.zJournal buffers, if required. */ if( zPathname ){ assert( nPathname>0 ); - pPager->zJournal = (char*)(pPtr += nPathname + 1); + pPager->zJournal = (char*)(pPtr += nPathname + 1 + nUri); memcpy(pPager->zFilename, zPathname, nPathname); + memcpy(&pPager->zFilename[nPathname+1], zUri, nUri); memcpy(pPager->zJournal, zPathname, nPathname); memcpy(&pPager->zJournal[nPathname], "-journal", 8); + sqlite3FileSuffix3(pPager->zFilename, pPager->zJournal); #ifndef SQLITE_OMIT_WAL pPager->zWal = &pPager->zJournal[nPathname+8+1]; memcpy(pPager->zWal, zPathname, nPathname); memcpy(&pPager->zWal[nPathname], "-wal", 4); + sqlite3FileSuffix3(pPager->zFilename, pPager->zWal); #endif sqlite3_free(zPathname); } @@ -42084,8 +42550,8 @@ SQLITE_PRIVATE int sqlite3PagerCommitPhaseOne( pList = pPageOne; pList->pDirty = 0; } - assert( pList!=0 || rc!=SQLITE_OK ); - if( pList ){ + assert( rc==SQLITE_OK ); + if( ALWAYS(pList) ){ rc = pagerWalFrames(pPager, pList, pPager->dbSize, 1, (pPager->fullSync ? pPager->syncFlags : 0) ); @@ -42948,6 +43414,7 @@ SQLITE_PRIVATE int sqlite3PagerOkToChangeJournalMode(Pager *pPager){ SQLITE_PRIVATE i64 sqlite3PagerJournalSizeLimit(Pager *pPager, i64 iLimit){ if( iLimit>=-1 ){ pPager->journalSizeLimit = iLimit; + sqlite3WalLimit(pPager->pWal, iLimit); } return pPager->journalSizeLimit; } @@ -43039,7 +43506,8 @@ static int pagerOpenWal(Pager *pPager){ */ if( rc==SQLITE_OK ){ rc = sqlite3WalOpen(pPager->pVfs, - pPager->fd, pPager->zWal, pPager->exclusiveMode, &pPager->pWal + pPager->fd, pPager->zWal, pPager->exclusiveMode, + pPager->journalSizeLimit, &pPager->pWal ); } @@ -43571,6 +44039,7 @@ struct Wal { sqlite3_file *pDbFd; /* File handle for the database file */ sqlite3_file *pWalFd; /* File handle for WAL file */ u32 iCallback; /* Value to pass to log callback (or 0) */ + i64 mxWalSize; /* Truncate WAL to this size upon reset */ int nWiData; /* Size of array apWiData */ volatile u32 **apWiData; /* Pointer to wal-index content in memory */ u32 szPage; /* Database page size */ @@ -43578,7 +44047,7 @@ struct Wal { u8 exclusiveMode; /* Non-zero if connection is in exclusive mode */ u8 writeLock; /* True if in a write transaction */ u8 ckptLock; /* True if holding a checkpoint lock */ - u8 readOnly; /* True if the WAL file is open read-only */ + u8 readOnly; /* WAL_RDWR, WAL_RDONLY, or WAL_SHM_RDONLY */ WalIndexHdr hdr; /* Wal-index header for current transaction */ const char *zWalName; /* Name of WAL file */ u32 nCkpt; /* Checkpoint sequence counter in the wal-header */ @@ -43594,6 +44063,13 @@ struct Wal { #define WAL_EXCLUSIVE_MODE 1 #define WAL_HEAPMEMORY_MODE 2 +/* +** Possible values for WAL.readOnly +*/ +#define WAL_RDWR 0 /* Normal read/write connection */ +#define WAL_RDONLY 1 /* The WAL file is readonly */ +#define WAL_SHM_RDONLY 2 /* The SHM file is readonly */ + /* ** Each page of the wal-index mapping contains a hash-table made up of ** an array of HASHTABLE_NSLOT elements of the following type. @@ -43687,6 +44163,10 @@ static int walIndexPage(Wal *pWal, int iPage, volatile u32 **ppPage){ rc = sqlite3OsShmMap(pWal->pDbFd, iPage, WALINDEX_PGSZ, pWal->writeLock, (void volatile **)&pWal->apWiData[iPage] ); + if( rc==SQLITE_READONLY ){ + pWal->readOnly |= WAL_SHM_RDONLY; + rc = SQLITE_OK; + } } } @@ -44393,6 +44873,7 @@ SQLITE_PRIVATE int sqlite3WalOpen( sqlite3_file *pDbFd, /* The open database file */ const char *zWalName, /* Name of the WAL file */ int bNoShm, /* True to run in heap-memory mode */ + i64 mxWalSize, /* Truncate WAL to this size on reset */ Wal **ppWal /* OUT: Allocated Wal handle */ ){ int rc; /* Return Code */ @@ -44425,6 +44906,7 @@ SQLITE_PRIVATE int sqlite3WalOpen( pRet->pWalFd = (sqlite3_file *)&pRet[1]; pRet->pDbFd = pDbFd; pRet->readLock = -1; + pRet->mxWalSize = mxWalSize; pRet->zWalName = zWalName; pRet->exclusiveMode = (bNoShm ? WAL_HEAPMEMORY_MODE: WAL_NORMAL_MODE); @@ -44432,7 +44914,7 @@ SQLITE_PRIVATE int sqlite3WalOpen( flags = (SQLITE_OPEN_READWRITE|SQLITE_OPEN_CREATE|SQLITE_OPEN_WAL); rc = sqlite3OsOpen(pVfs, zWalName, pRet->pWalFd, flags, &flags); if( rc==SQLITE_OK && flags&SQLITE_OPEN_READONLY ){ - pRet->readOnly = 1; + pRet->readOnly = WAL_RDONLY; } if( rc!=SQLITE_OK ){ @@ -44446,6 +44928,13 @@ SQLITE_PRIVATE int sqlite3WalOpen( return rc; } +/* +** Change the size to which the WAL file is trucated on each reset. +*/ +SQLITE_PRIVATE void sqlite3WalLimit(Wal *pWal, i64 iLimit){ + if( pWal ) pWal->mxWalSize = iLimit; +} + /* ** Find the smallest page number out of all pages held in the WAL that ** has not been returned by any prior invocation of this method on the @@ -45066,21 +45555,28 @@ static int walIndexReadHdr(Wal *pWal, int *pChanged){ ** with a writer. So get a WRITE lock and try again. */ assert( badHdr==0 || pWal->writeLock==0 ); - if( badHdr && SQLITE_OK==(rc = walLockExclusive(pWal, WAL_WRITE_LOCK, 1)) ){ - pWal->writeLock = 1; - if( SQLITE_OK==(rc = walIndexPage(pWal, 0, &page0)) ){ - badHdr = walIndexTryHdr(pWal, pChanged); - if( badHdr ){ - /* If the wal-index header is still malformed even while holding - ** a WRITE lock, it can only mean that the header is corrupted and - ** needs to be reconstructed. So run recovery to do exactly that. - */ - rc = walIndexRecover(pWal); - *pChanged = 1; + if( badHdr ){ + if( pWal->readOnly & WAL_SHM_RDONLY ){ + if( SQLITE_OK==(rc = walLockShared(pWal, WAL_WRITE_LOCK)) ){ + walUnlockShared(pWal, WAL_WRITE_LOCK); + rc = SQLITE_READONLY_RECOVERY; + } + }else if( SQLITE_OK==(rc = walLockExclusive(pWal, WAL_WRITE_LOCK, 1)) ){ + pWal->writeLock = 1; + if( SQLITE_OK==(rc = walIndexPage(pWal, 0, &page0)) ){ + badHdr = walIndexTryHdr(pWal, pChanged); + if( badHdr ){ + /* If the wal-index header is still malformed even while holding + ** a WRITE lock, it can only mean that the header is corrupted and + ** needs to be reconstructed. So run recovery to do exactly that. + */ + rc = walIndexRecover(pWal); + *pChanged = 1; + } } + pWal->writeLock = 0; + walUnlockExclusive(pWal, WAL_WRITE_LOCK, 1); } - pWal->writeLock = 0; - walUnlockExclusive(pWal, WAL_WRITE_LOCK, 1); } /* If the header is read successfully, check the version number to make @@ -45267,7 +45763,9 @@ static int walTryBeginRead(Wal *pWal, int *pChanged, int useWal, int cnt){ } /* There was once an "if" here. The extra "{" is to preserve indentation. */ { - if( mxReadMark < pWal->hdr.mxFrame || mxI==0 ){ + if( (pWal->readOnly & WAL_SHM_RDONLY)==0 + && (mxReadMarkhdr.mxFrame || mxI==0) + ){ for(i=1; ireadOnly & WAL_SHM_RDONLY)!=0 ); + return rc==SQLITE_BUSY ? WAL_RETRY : SQLITE_READONLY_CANTLOCK; } rc = walLockShared(pWal, WAL_READ_LOCK(mxI)); @@ -45681,6 +46179,24 @@ static int walRestartLog(Wal *pWal){ */ int i; /* Loop counter */ u32 *aSalt = pWal->hdr.aSalt; /* Big-endian salt values */ + + /* Limit the size of WAL file if the journal_size_limit PRAGMA is + ** set to a non-negative value. Log errors encountered + ** during the truncation attempt. */ + if( pWal->mxWalSize>=0 ){ + i64 sz; + int rx; + sqlite3BeginBenignMalloc(); + rx = sqlite3OsFileSize(pWal->pWalFd, &sz); + if( rx==SQLITE_OK && (sz > pWal->mxWalSize) ){ + rx = sqlite3OsTruncate(pWal->pWalFd, pWal->mxWalSize); + } + sqlite3EndBenignMalloc(); + if( rx ){ + sqlite3_log(rx, "cannot limit WAL size: %s", pWal->zWalName); + } + } + pWal->nCkpt++; pWal->hdr.mxFrame = 0; sqlite3Put4byte((u8*)&aSalt[0], 1 + sqlite3Get4byte((u8*)&aSalt[0])); @@ -45906,6 +46422,7 @@ SQLITE_PRIVATE int sqlite3WalCheckpoint( assert( pWal->ckptLock==0 ); assert( pWal->writeLock==0 ); + if( pWal->readOnly ) return SQLITE_READONLY; WALTRACE(("WAL%p: checkpoint begins\n", pWal)); rc = walLockExclusive(pWal, WAL_CKPT_LOCK, 1); if( rc ){ @@ -47786,6 +48303,7 @@ static void ptrmapPut(BtShared *pBt, Pgno key, u8 eType, Pgno parent, int *pRC){ *pRC = SQLITE_CORRUPT_BKPT; goto ptrmap_exit; } + assert( offset <= (int)pBt->usableSize-5 ); pPtrmap = (u8 *)sqlite3PagerGetData(pDbPage); if( eType!=pPtrmap[offset] || get4byte(&pPtrmap[offset+1])!=parent ){ @@ -47825,6 +48343,11 @@ static int ptrmapGet(BtShared *pBt, Pgno key, u8 *pEType, Pgno *pPgno){ pPtrmap = (u8 *)sqlite3PagerGetData(pDbPage); offset = PTRMAP_PTROFFSET(iPtrmap, key); + if( offset<0 ){ + sqlite3PagerUnref(pDbPage); + return SQLITE_CORRUPT_BKPT; + } + assert( offset <= (int)pBt->usableSize-5 ); assert( pEType!=0 ); *pEType = pPtrmap[offset]; if( pPgno ) *pPgno = get4byte(&pPtrmap[offset+1]); @@ -47849,6 +48372,8 @@ static int ptrmapGet(BtShared *pBt, Pgno key, u8 *pEType, Pgno *pPgno){ */ #define findCell(P,I) \ ((P)->aData + ((P)->maskPage & get2byte(&(P)->aData[(P)->cellOffset+2*(I)]))) +#define findCellv2(D,M,O,I) (D+(M&get2byte(D+(O+2*(I))))) + /* ** This a more complex version of findCell() that works for @@ -48686,13 +49211,13 @@ static int btreeInvokeBusyHandler(void *pArg){ ** to problems with locking. */ SQLITE_PRIVATE int sqlite3BtreeOpen( + sqlite3_vfs *pVfs, /* VFS to use for this b-tree */ const char *zFilename, /* Name of the file containing the BTree database */ sqlite3 *db, /* Associated database handle */ Btree **ppBtree, /* Pointer to new Btree object written here */ int flags, /* Options */ int vfsFlags /* Flags passed through to sqlite3_vfs.xOpen() */ ){ - sqlite3_vfs *pVfs; /* The VFS to use for this btree */ BtShared *pBt = 0; /* Shared part of btree structure */ Btree *p; /* Handle to return */ sqlite3_mutex *mutexOpen = 0; /* Prevents a race condition. Ticket #3537 */ @@ -48714,6 +49239,7 @@ SQLITE_PRIVATE int sqlite3BtreeOpen( #endif assert( db!=0 ); + assert( pVfs!=0 ); assert( sqlite3_mutex_held(db->mutex) ); assert( (flags&0xff)==flags ); /* flags fit in 8 bits */ @@ -48732,7 +49258,6 @@ SQLITE_PRIVATE int sqlite3BtreeOpen( if( (vfsFlags & SQLITE_OPEN_MAIN_DB)!=0 && (isMemdb || isTempDb) ){ vfsFlags = (vfsFlags & ~SQLITE_OPEN_MAIN_DB) | SQLITE_OPEN_TEMP_DB; } - pVfs = db->pVfs; p = sqlite3MallocZero(sizeof(Btree)); if( !p ){ return SQLITE_NOMEM; @@ -51443,7 +51968,7 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked( } assert( pCur->apPage[0]->intKey || pIdxKey ); for(;;){ - int lwr, upr; + int lwr, upr, idx; Pgno chldPg; MemPage *pPage = pCur->apPage[pCur->iPage]; int c; @@ -51459,14 +51984,14 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked( lwr = 0; upr = pPage->nCell-1; if( biasRight ){ - pCur->aiIdx[pCur->iPage] = (u16)upr; + pCur->aiIdx[pCur->iPage] = (u16)(idx = upr); }else{ - pCur->aiIdx[pCur->iPage] = (u16)((upr+lwr)/2); + pCur->aiIdx[pCur->iPage] = (u16)(idx = (upr+lwr)/2); } for(;;){ - int idx = pCur->aiIdx[pCur->iPage]; /* Index of current cell in pPage */ u8 *pCell; /* Pointer to current cell in pPage */ + assert( idx==pCur->aiIdx[pCur->iPage] ); pCur->info.nSize = 0; pCell = findCell(pPage, idx) + pPage->childPtrSize; if( pPage->intKey ){ @@ -51549,7 +52074,7 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked( if( lwr>upr ){ break; } - pCur->aiIdx[pCur->iPage] = (u16)((lwr+upr)/2); + pCur->aiIdx[pCur->iPage] = (u16)(idx = (lwr+upr)/2); } assert( lwr==upr+1 ); assert( pPage->isInit ); @@ -52382,10 +52907,10 @@ static int fillInCell( ** "sz" must be the number of bytes in the cell. */ static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){ - int i; /* Loop counter */ u32 pc; /* Offset to cell content of cell being deleted */ u8 *data; /* pPage->aData */ u8 *ptr; /* Used to move bytes around within data[] */ + u8 *endPtr; /* End of loop */ int rc; /* The return code */ int hdr; /* Beginning of the header. 0 most pages. 100 page 1 */ @@ -52410,9 +52935,11 @@ static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){ *pRC = rc; return; } - for(i=idx+1; inCell; i++, ptr+=2){ - ptr[0] = ptr[2]; - ptr[1] = ptr[3]; + endPtr = &data[pPage->cellOffset + 2*pPage->nCell - 2]; + assert( (SQLITE_PTR_TO_INT(ptr)&1)==0 ); /* ptr is always 2-byte aligned */ + while( ptrnCell--; put2byte(&data[hdr+3], pPage->nCell); @@ -52452,6 +52979,7 @@ static void insertCell( int cellOffset; /* Address of first cell pointer in data[] */ u8 *data; /* The content of the whole page */ u8 *ptr; /* Used for moving information around in data[] */ + u8 *endPtr; /* End of the loop */ int nSkip = (iChild ? 4 : 0); @@ -52502,9 +53030,12 @@ static void insertCell( if( iChild ){ put4byte(&data[idx], iChild); } - for(j=end, ptr=&data[j]; j>ins; j-=2, ptr-=2){ - ptr[0] = ptr[-2]; - ptr[1] = ptr[-1]; + ptr = &data[end]; + endPtr = &data[ins]; + assert( (SQLITE_PTR_TO_INT(ptr)&1)==0 ); /* ptr is always 2-byte aligned */ + while( ptr>endPtr ){ + *(u16*)ptr = *(u16*)&ptr[-2]; + ptr -= 2; } put2byte(&data[ins], idx); put2byte(&data[pPage->hdrOffset+3], pPage->nCell); @@ -52549,10 +53080,11 @@ static void assemblePage( pCellptr = &data[pPage->cellOffset + nCell*2]; cellbody = nUsable; for(i=nCell-1; i>=0; i--){ + u16 sz = aSize[i]; pCellptr -= 2; - cellbody -= aSize[i]; + cellbody -= sz; put2byte(pCellptr, cellbody); - memcpy(&data[cellbody], apCell[i], aSize[i]); + memcpy(&data[cellbody], apCell[i], sz); } put2byte(&data[hdr+3], nCell); put2byte(&data[hdr+5], cellbody); @@ -53006,12 +53538,24 @@ static int balance_nonroot( memcpy(pOld->aData, apOld[i]->aData, pBt->pageSize); limit = pOld->nCell+pOld->nOverflow; - for(j=0; jnOverflow>0 ){ + for(j=0; jaData; + u16 maskPage = pOld->maskPage; + u16 cellOffset = pOld->cellOffset; + for(j=0; jp3 = p3; pOp->p4.p = 0; pOp->p4type = P4_NOTUSED; - p->expired = 0; - if( op==OP_ParseSchema ){ - /* Any program that uses the OP_ParseSchema opcode needs to lock - ** all btrees. */ - int j; - for(j=0; jdb->nDb; j++) sqlite3VdbeUsesBtree(p, j); - } #ifdef SQLITE_DEBUG pOp->zComment = 0; if( sqlite3VdbeAddopTrace ) sqlite3VdbePrintOp(0, i, &p->aOp[i]); @@ -57205,6 +57742,20 @@ SQLITE_PRIVATE int sqlite3VdbeAddOp4( return addr; } +/* +** Add an OP_ParseSchema opcode. This routine is broken out from +** sqlite3VdbeAddOp4() since it needs to also local all btrees. +** +** The zWhere string must have been obtained from sqlite3_malloc(). +** This routine will take ownership of the allocated memory. +*/ +SQLITE_PRIVATE void sqlite3VdbeAddParseSchemaOp(Vdbe *p, int iDb, char *zWhere){ + int j; + int addr = sqlite3VdbeAddOp3(p, OP_ParseSchema, iDb, 0, 0); + sqlite3VdbeChangeP4(p, addr, zWhere, P4_DYNAMIC); + for(j=0; jdb->nDb; j++) sqlite3VdbeUsesBtree(p, j); +} + /* ** Add an opcode that includes the p4 value as an integer. */ @@ -58395,44 +58946,88 @@ static void *allocSpace( } /* -** Prepare a virtual machine for execution. This involves things such +** Rewind the VDBE back to the beginning in preparation for +** running it. +*/ +SQLITE_PRIVATE void sqlite3VdbeRewind(Vdbe *p){ +#if defined(SQLITE_DEBUG) || defined(VDBE_PROFILE) + int i; +#endif + assert( p!=0 ); + assert( p->magic==VDBE_MAGIC_INIT ); + + /* There should be at least one opcode. + */ + assert( p->nOp>0 ); + + /* Set the magic to VDBE_MAGIC_RUN sooner rather than later. */ + p->magic = VDBE_MAGIC_RUN; + +#ifdef SQLITE_DEBUG + for(i=1; inMem; i++){ + assert( p->aMem[i].db==p->db ); + } +#endif + p->pc = -1; + p->rc = SQLITE_OK; + p->errorAction = OE_Abort; + p->magic = VDBE_MAGIC_RUN; + p->nChange = 0; + p->cacheCtr = 1; + p->minWriteFileFormat = 255; + p->iStatement = 0; + p->nFkConstraint = 0; +#ifdef VDBE_PROFILE + for(i=0; inOp; i++){ + p->aOp[i].cnt = 0; + p->aOp[i].cycles = 0; + } +#endif +} + +/* +** Prepare a virtual machine for execution for the first time after +** creating the virtual machine. This involves things such ** as allocating stack space and initializing the program counter. ** After the VDBE has be prepped, it can be executed by one or more ** calls to sqlite3VdbeExec(). ** -** This is the only way to move a VDBE from VDBE_MAGIC_INIT to -** VDBE_MAGIC_RUN. +** This function may be called exact once on a each virtual machine. +** After this routine is called the VM has been "packaged" and is ready +** to run. After this routine is called, futher calls to +** sqlite3VdbeAddOp() functions are prohibited. This routine disconnects +** the Vdbe from the Parse object that helped generate it so that the +** the Vdbe becomes an independent entity and the Parse object can be +** destroyed. ** -** This function may be called more than once on a single virtual machine. -** The first call is made while compiling the SQL statement. Subsequent -** calls are made as part of the process of resetting a statement to be -** re-executed (from a call to sqlite3_reset()). The nVar, nMem, nCursor -** and isExplain parameters are only passed correct values the first time -** the function is called. On subsequent calls, from sqlite3_reset(), nVar -** is passed -1 and nMem, nCursor and isExplain are all passed zero. +** Use the sqlite3VdbeRewind() procedure to restore a virtual machine back +** to its initial state after it has been run. */ SQLITE_PRIVATE void sqlite3VdbeMakeReady( Vdbe *p, /* The VDBE */ - int nVar, /* Number of '?' see in the SQL statement */ - int nMem, /* Number of memory cells to allocate */ - int nCursor, /* Number of cursors to allocate */ - int nArg, /* Maximum number of args in SubPrograms */ - int isExplain, /* True if the EXPLAIN keywords is present */ - int usesStmtJournal /* True to set Vdbe.usesStmtJournal */ + Parse *pParse /* Parsing context */ ){ - int n; - sqlite3 *db = p->db; + sqlite3 *db; /* The database connection */ + int nVar; /* Number of parameters */ + int nMem; /* Number of VM memory registers */ + int nCursor; /* Number of cursors required */ + int nArg; /* Number of arguments in subprograms */ + int n; /* Loop counter */ + u8 *zCsr; /* Memory available for allocation */ + u8 *zEnd; /* First byte past allocated memory */ + int nByte; /* How much extra memory is needed */ assert( p!=0 ); - assert( p->magic==VDBE_MAGIC_INIT ); - - /* There should be at least one opcode. - */ assert( p->nOp>0 ); - - /* Set the magic to VDBE_MAGIC_RUN sooner rather than later. */ - p->magic = VDBE_MAGIC_RUN; - + assert( pParse!=0 ); + assert( p->magic==VDBE_MAGIC_INIT ); + db = p->db; + assert( db->mallocFailed==0 ); + nVar = pParse->nVar; + nMem = pParse->nMem; + nCursor = pParse->nTab; + nArg = pParse->nMaxArg; + /* For each cursor required, also allocate a memory cell. Memory ** cells (nMem+1-nCursor)..nMem, inclusive, will never be used by ** the vdbe program. Instead they are used to allocate space for @@ -58445,91 +59040,69 @@ SQLITE_PRIVATE void sqlite3VdbeMakeReady( nMem += nCursor; /* Allocate space for memory registers, SQL variables, VDBE cursors and - ** an array to marshal SQL function arguments in. This is only done the - ** first time this function is called for a given VDBE, not when it is - ** being called from sqlite3_reset() to reset the virtual machine. - */ - if( nVar>=0 && ALWAYS(db->mallocFailed==0) ){ - u8 *zCsr = (u8 *)&p->aOp[p->nOp]; /* Memory avaliable for alloation */ - u8 *zEnd = (u8 *)&p->aOp[p->nOpAlloc]; /* First byte past available mem */ - int nByte; /* How much extra memory needed */ - - resolveP2Values(p, &nArg); - p->usesStmtJournal = (u8)usesStmtJournal; - if( isExplain && nMem<10 ){ - nMem = 10; - } - memset(zCsr, 0, zEnd-zCsr); - zCsr += (zCsr - (u8*)0)&7; - assert( EIGHT_BYTE_ALIGNMENT(zCsr) ); - - /* Memory for registers, parameters, cursor, etc, is allocated in two - ** passes. On the first pass, we try to reuse unused space at the - ** end of the opcode array. If we are unable to satisfy all memory - ** requirements by reusing the opcode array tail, then the second - ** pass will fill in the rest using a fresh allocation. - ** - ** This two-pass approach that reuses as much memory as possible from - ** the leftover space at the end of the opcode array can significantly - ** reduce the amount of memory held by a prepared statement. - */ - do { - nByte = 0; - p->aMem = allocSpace(p->aMem, nMem*sizeof(Mem), &zCsr, zEnd, &nByte); - p->aVar = allocSpace(p->aVar, nVar*sizeof(Mem), &zCsr, zEnd, &nByte); - p->apArg = allocSpace(p->apArg, nArg*sizeof(Mem*), &zCsr, zEnd, &nByte); - p->azVar = allocSpace(p->azVar, nVar*sizeof(char*), &zCsr, zEnd, &nByte); - p->apCsr = allocSpace(p->apCsr, nCursor*sizeof(VdbeCursor*), - &zCsr, zEnd, &nByte); - if( nByte ){ - p->pFree = sqlite3DbMallocZero(db, nByte); - } - zCsr = p->pFree; - zEnd = &zCsr[nByte]; - }while( nByte && !db->mallocFailed ); + ** an array to marshal SQL function arguments in. + */ + zCsr = (u8*)&p->aOp[p->nOp]; /* Memory avaliable for allocation */ + zEnd = (u8*)&p->aOp[p->nOpAlloc]; /* First byte past end of zCsr[] */ - p->nCursor = (u16)nCursor; - if( p->aVar ){ - p->nVar = (ynVar)nVar; - for(n=0; naVar[n].flags = MEM_Null; - p->aVar[n].db = db; - } + resolveP2Values(p, &nArg); + p->usesStmtJournal = (u8)(pParse->isMultiWrite && pParse->mayAbort); + if( pParse->explain && nMem<10 ){ + nMem = 10; + } + memset(zCsr, 0, zEnd-zCsr); + zCsr += (zCsr - (u8*)0)&7; + assert( EIGHT_BYTE_ALIGNMENT(zCsr) ); + p->expired = 0; + + /* Memory for registers, parameters, cursor, etc, is allocated in two + ** passes. On the first pass, we try to reuse unused space at the + ** end of the opcode array. If we are unable to satisfy all memory + ** requirements by reusing the opcode array tail, then the second + ** pass will fill in the rest using a fresh allocation. + ** + ** This two-pass approach that reuses as much memory as possible from + ** the leftover space at the end of the opcode array can significantly + ** reduce the amount of memory held by a prepared statement. + */ + do { + nByte = 0; + p->aMem = allocSpace(p->aMem, nMem*sizeof(Mem), &zCsr, zEnd, &nByte); + p->aVar = allocSpace(p->aVar, nVar*sizeof(Mem), &zCsr, zEnd, &nByte); + p->apArg = allocSpace(p->apArg, nArg*sizeof(Mem*), &zCsr, zEnd, &nByte); + p->azVar = allocSpace(p->azVar, nVar*sizeof(char*), &zCsr, zEnd, &nByte); + p->apCsr = allocSpace(p->apCsr, nCursor*sizeof(VdbeCursor*), + &zCsr, zEnd, &nByte); + if( nByte ){ + p->pFree = sqlite3DbMallocZero(db, nByte); } - if( p->aMem ){ - p->aMem--; /* aMem[] goes from 1..nMem */ - p->nMem = nMem; /* not from 0..nMem-1 */ - for(n=1; n<=nMem; n++){ - p->aMem[n].flags = MEM_Null; - p->aMem[n].db = db; - } + zCsr = p->pFree; + zEnd = &zCsr[nByte]; + }while( nByte && !db->mallocFailed ); + + p->nCursor = (u16)nCursor; + if( p->aVar ){ + p->nVar = (ynVar)nVar; + for(n=0; naVar[n].flags = MEM_Null; + p->aVar[n].db = db; } } -#ifdef SQLITE_DEBUG - for(n=1; nnMem; n++){ - assert( p->aMem[n].db==db ); + if( p->azVar ){ + p->nzVar = pParse->nzVar; + memcpy(p->azVar, pParse->azVar, p->nzVar*sizeof(p->azVar[0])); + memset(pParse->azVar, 0, pParse->nzVar*sizeof(pParse->azVar[0])); } -#endif - - p->pc = -1; - p->rc = SQLITE_OK; - p->errorAction = OE_Abort; - p->explain |= isExplain; - p->magic = VDBE_MAGIC_RUN; - p->nChange = 0; - p->cacheCtr = 1; - p->minWriteFileFormat = 255; - p->iStatement = 0; - p->nFkConstraint = 0; -#ifdef VDBE_PROFILE - { - int i; - for(i=0; inOp; i++){ - p->aOp[i].cnt = 0; - p->aOp[i].cycles = 0; + if( p->aMem ){ + p->aMem--; /* aMem[] goes from 1..nMem */ + p->nMem = nMem; /* not from 0..nMem-1 */ + for(n=1; n<=nMem; n++){ + p->aMem[n].flags = MEM_Null; + p->aMem[n].db = db; } } -#endif + p->explain = pParse->explain; + sqlite3VdbeRewind(p); } /* @@ -58803,6 +59376,7 @@ static int vdbeCommit(sqlite3 *db, Vdbe *p){ if( !zMaster ){ return SQLITE_NOMEM; } + sqlite3FileSuffix3(zMainFile, zMaster); rc = sqlite3OsAccess(pVfs, zMaster, SQLITE_ACCESS_EXISTS, &res); }while( rc==SQLITE_OK && res ); if( rc==SQLITE_OK ){ @@ -59017,6 +59591,15 @@ SQLITE_PRIVATE int sqlite3VdbeCloseStatement(Vdbe *p, int eOp){ db->nStatement--; p->iStatement = 0; + if( rc==SQLITE_OK ){ + if( eOp==SAVEPOINT_ROLLBACK ){ + rc = sqlite3VtabSavepoint(db, SAVEPOINT_ROLLBACK, iSavepoint); + } + if( rc==SQLITE_OK ){ + rc = sqlite3VtabSavepoint(db, SAVEPOINT_RELEASE, iSavepoint); + } + } + /* If the statement transaction is being rolled back, also restore the ** database handles deferred constraint counter to the value it had when ** the statement transaction was opened. */ @@ -59196,17 +59779,11 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){ ** do so. If this operation returns an error, and the current statement ** error code is SQLITE_OK or SQLITE_CONSTRAINT, then promote the ** current statement error code. - ** - ** Note that sqlite3VdbeCloseStatement() can only fail if eStatementOp - ** is SAVEPOINT_ROLLBACK. But if p->rc==SQLITE_OK then eStatementOp - ** must be SAVEPOINT_RELEASE. Hence the NEVER(p->rc==SQLITE_OK) in - ** the following code. */ if( eStatementOp ){ rc = sqlite3VdbeCloseStatement(p, eStatementOp); if( rc ){ - assert( eStatementOp==SAVEPOINT_ROLLBACK ); - if( NEVER(p->rc==SQLITE_OK) || p->rc==SQLITE_CONSTRAINT ){ + if( p->rc==SQLITE_OK || p->rc==SQLITE_CONSTRAINT ){ p->rc = rc; sqlite3DbFree(db, p->zErrMsg); p->zErrMsg = 0; @@ -59399,6 +59976,7 @@ SQLITE_PRIVATE void sqlite3VdbeDeleteAuxData(VdbeFunc *pVdbeFunc, int mask){ */ SQLITE_PRIVATE void sqlite3VdbeDeleteObject(sqlite3 *db, Vdbe *p){ SubProgram *pSub, *pNext; + int i; assert( p->db==0 || p->db==db ); releaseMemArray(p->aVar, p->nVar); releaseMemArray(p->aColName, p->nResColumn*COLNAME_N); @@ -59407,6 +59985,7 @@ SQLITE_PRIVATE void sqlite3VdbeDeleteObject(sqlite3 *db, Vdbe *p){ vdbeFreeOpArray(db, pSub->aOp, pSub->nOp); sqlite3DbFree(db, pSub); } + for(i=p->nzVar-1; i>=0; i--) sqlite3DbFree(db, p->azVar[i]); vdbeFreeOpArray(db, p->aOp, p->nOp); sqlite3DbFree(db, p->aLabel); sqlite3DbFree(db, p->aColName); @@ -59852,7 +60431,7 @@ SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeRecordUnpack( idx += getVarint32(&aKey[idx], serial_type); pMem->enc = pKeyInfo->enc; pMem->db = pKeyInfo->db; - pMem->flags = 0; + /* pMem->flags = 0; // sqlite3VdbeSerialGet() will set this for us */ pMem->zMalloc = 0; d += sqlite3VdbeSerialGet(&aKey[d], serial_type, pMem); pMem++; @@ -59867,6 +60446,7 @@ SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeRecordUnpack( ** This routine destroys a UnpackedRecord object. */ SQLITE_PRIVATE void sqlite3VdbeDeleteUnpackedRecord(UnpackedRecord *p){ +#ifdef SQLITE_DEBUG int i; Mem *pMem; @@ -59880,6 +60460,7 @@ SQLITE_PRIVATE void sqlite3VdbeDeleteUnpackedRecord(UnpackedRecord *p){ */ if( NEVER(pMem->zMalloc) ) sqlite3VdbeMemRelease(pMem); } +#endif if( p->flags & UNPACKED_NEED_FREE ){ sqlite3DbFree(p->pKeyInfo->db, p); } @@ -59933,7 +60514,7 @@ SQLITE_PRIVATE int sqlite3VdbeRecordCompare( /* Compilers may complain that mem1.u.i is potentially uninitialized. ** We could initialize it, as shown here, to silence those complaints. - ** But in fact, mem1.u.i will never actually be used initialized, and doing + ** But in fact, mem1.u.i will never actually be used uninitialized, and doing ** the unnecessary initialization has a measurable negative performance ** impact, since this routine is a very high runner. And so, we choose ** to ignore the compiler warnings and leave this variable uninitialized. @@ -60315,7 +60896,7 @@ SQLITE_API int sqlite3_reset(sqlite3_stmt *pStmt){ Vdbe *v = (Vdbe*)pStmt; sqlite3_mutex_enter(v->db->mutex); rc = sqlite3VdbeReset(v); - sqlite3VdbeMakeReady(v, -1, 0, 0, 0, 0, 0); + sqlite3VdbeRewind(v); assert( (rc & (v->db->errMask))==rc ); rc = sqlite3ApiExit(v->db, rc); sqlite3_mutex_leave(v->db->mutex); @@ -60672,6 +61253,14 @@ static int sqlite3Step(Vdbe *p){ return (rc&db->errMask); } +/* +** The maximum number of times that a statement will try to reparse +** itself before giving up and returning SQLITE_SCHEMA. +*/ +#ifndef SQLITE_MAX_SCHEMA_RETRY +# define SQLITE_MAX_SCHEMA_RETRY 5 +#endif + /* ** This is the top-level implementation of sqlite3_step(). Call ** sqlite3Step() to do most of the work. If a schema error occurs, @@ -60690,7 +61279,7 @@ SQLITE_API int sqlite3_step(sqlite3_stmt *pStmt){ db = v->db; sqlite3_mutex_enter(db->mutex); while( (rc = sqlite3Step(v))==SQLITE_SCHEMA - && cnt++ < 5 + && cnt++ < SQLITE_MAX_SCHEMA_RETRY && (rc2 = rc = sqlite3Reprepare(v))==SQLITE_OK ){ sqlite3_reset(pStmt); v->expired = 0; @@ -61380,32 +61969,6 @@ SQLITE_API int sqlite3_bind_parameter_count(sqlite3_stmt *pStmt){ return p ? p->nVar : 0; } -/* -** Create a mapping from variable numbers to variable names -** in the Vdbe.azVar[] array, if such a mapping does not already -** exist. -*/ -static void createVarMap(Vdbe *p){ - if( !p->okVar ){ - int j; - Op *pOp; - sqlite3_mutex_enter(p->db->mutex); - /* The race condition here is harmless. If two threads call this - ** routine on the same Vdbe at the same time, they both might end - ** up initializing the Vdbe.azVar[] array. That is a little extra - ** work but it results in the same answer. - */ - for(j=0, pOp=p->aOp; jnOp; j++, pOp++){ - if( pOp->opcode==OP_Variable ){ - assert( pOp->p1>0 && pOp->p1<=p->nVar ); - p->azVar[pOp->p1-1] = pOp->p4.z; - } - } - p->okVar = 1; - sqlite3_mutex_leave(p->db->mutex); - } -} - /* ** Return the name of a wildcard parameter. Return NULL if the index ** is out of range or if the wildcard is unnamed. @@ -61414,10 +61977,9 @@ static void createVarMap(Vdbe *p){ */ SQLITE_API const char *sqlite3_bind_parameter_name(sqlite3_stmt *pStmt, int i){ Vdbe *p = (Vdbe*)pStmt; - if( p==0 || i<1 || i>p->nVar ){ + if( p==0 || i<1 || i>p->nzVar ){ return 0; } - createVarMap(p); return p->azVar[i-1]; } @@ -61431,9 +61993,8 @@ SQLITE_PRIVATE int sqlite3VdbeParameterIndex(Vdbe *p, const char *zName, int nNa if( p==0 ){ return 0; } - createVarMap(p); if( zName ){ - for(i=0; inVar; i++){ + for(i=0; inzVar; i++){ const char *z = p->azVar[i]; if( z && memcmp(z,zName,nName)==0 && z[nName]==0 ){ return i+1; @@ -62348,6 +62909,7 @@ SQLITE_PRIVATE int sqlite3VdbeExec( Mem *pOut = 0; /* Output operand */ int iCompare = 0; /* Result of last OP_Compare operation */ int *aPermute = 0; /* Permutation of columns for OP_Compare */ + i64 lastRowid = db->lastRowid; /* Saved value of the last insert ROWID */ #ifdef VDBE_PROFILE u64 start; /* CPU clock count at start of opcode */ int origPc; /* Program counter at start of opcode */ @@ -62756,6 +63318,7 @@ SQLITE_PRIVATE int sqlite3VdbeExec( } cm; struct OP_Trace_stack_vars { char *zTrace; + char *z; } cn; } u; /* End automatically generated code @@ -62989,7 +63552,7 @@ case OP_Yield: { /* in1 */ /* Opcode: HaltIfNull P1 P2 P3 P4 * ** -** Check the value in register P3. If is is NULL then Halt using +** Check the value in register P3. If it is NULL then Halt using ** parameter P1, P2, and P4 as if this were a Halt instruction. If the ** value in register P3 is not NULL, then this routine is a no-op. */ @@ -63026,6 +63589,7 @@ case OP_Halt: { p->nFrame--; sqlite3VdbeSetChanges(db, p->nChange); pc = sqlite3VdbeFrameRestore(pFrame); + lastRowid = db->lastRowid; if( pOp->p2==OE_Ignore ){ /* Instruction pc is the OP_Program that invoked the sub-program ** currently being halted. If the p2 instruction of this OP_Halt @@ -63181,6 +63745,7 @@ case OP_Variable: { /* out2-prerelease */ #endif /* local variables moved into u.ab */ assert( pOp->p1>0 && pOp->p1<=p->nVar ); + assert( pOp->p4.z==0 || pOp->p4.z==p->azVar[pOp->p1-1] ); u.ab.pVar = &p->aVar[pOp->p1 - 1]; if( sqlite3VdbeMemTooBig(u.ab.pVar) ){ goto too_big; @@ -63598,16 +64163,9 @@ case OP_Function: { assert( pOp[-1].opcode==OP_CollSeq ); u.ag.ctx.pColl = pOp[-1].p4.pColl; } + db->lastRowid = lastRowid; (*u.ag.ctx.pFunc->xFunc)(&u.ag.ctx, u.ag.n, u.ag.apVal); /* IMP: R-24505-23230 */ - if( db->mallocFailed ){ - /* Even though a malloc() has failed, the implementation of the - ** user function may have called an sqlite3_result_XXX() function - ** to return a value. The following call releases any resources - ** associated with such a value. - */ - sqlite3VdbeMemRelease(&u.ag.ctx.s); - goto no_mem; - } + lastRowid = db->lastRowid; /* If any auxiliary data functions have been called by this user function, ** immediately call the destructor for any non-static values. @@ -63618,6 +64176,16 @@ case OP_Function: { pOp->p4type = P4_VDBEFUNC; } + if( db->mallocFailed ){ + /* Even though a malloc() has failed, the implementation of the + ** user function may have called an sqlite3_result_XXX() function + ** to return a value. The following call releases any resources + ** associated with such a value. + */ + sqlite3VdbeMemRelease(&u.ag.ctx.s); + goto no_mem; + } + /* If the function returned an error, throw an exception */ if( u.ag.ctx.isError ){ sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(&u.ag.ctx.s)); @@ -63921,7 +64489,7 @@ case OP_ToReal: { /* same as TK_TO_REAL, in1 */ ** If SQLITE_NULLEQ is set in P5 then the result of comparison is always either ** true or false and is never NULL. If both operands are NULL then the result ** of comparison is false. If either operand is NULL then the result is true. -** If neither operand is NULL the the result is the same as it would be if +** If neither operand is NULL the result is the same as it would be if ** the SQLITE_NULLEQ flag were omitted from P5. */ /* Opcode: Eq P1 P2 P3 P4 P5 @@ -63933,7 +64501,7 @@ case OP_ToReal: { /* same as TK_TO_REAL, in1 */ ** If SQLITE_NULLEQ is set in P5 then the result of comparison is always either ** true or false and is never NULL. If both operands are NULL then the result ** of comparison is true. If either operand is NULL then the result is false. -** If neither operand is NULL the the result is the same as it would be if +** If neither operand is NULL the result is the same as it would be if ** the SQLITE_NULLEQ flag were omitted from P5. */ /* Opcode: Le P1 P2 P3 P4 P5 @@ -63971,7 +64539,7 @@ case OP_Ge: { /* same as TK_GE, jump, in1, in3 */ pIn3 = &aMem[pOp->p3]; u.ai.flags1 = pIn1->flags; u.ai.flags3 = pIn3->flags; - if( (pIn1->flags | pIn3->flags)&MEM_Null ){ + if( (u.ai.flags1 | u.ai.flags3)&MEM_Null ){ /* One or both operands are NULL */ if( pOp->p5 & SQLITE_NULLEQ ){ /* If SQLITE_NULLEQ is set (which will only happen if the operator is @@ -63979,7 +64547,7 @@ case OP_Ge: { /* same as TK_GE, jump, in1, in3 */ ** or not both operands are null. */ assert( pOp->opcode==OP_Eq || pOp->opcode==OP_Ne ); - u.ai.res = (pIn1->flags & pIn3->flags & MEM_Null)==0; + u.ai.res = (u.ai.flags1 & u.ai.flags3 & MEM_Null)==0; }else{ /* SQLITE_NULLEQ is clear and at least one operand is NULL, ** then the result is always NULL. @@ -64218,13 +64786,13 @@ case OP_BitNot: { /* same as TK_BITNOT, in1, out2 */ /* Opcode: If P1 P2 P3 * * ** -** Jump to P2 if the value in register P1 is true. The value is +** Jump to P2 if the value in register P1 is true. The value ** is considered true if it is numeric and non-zero. If the value ** in P1 is NULL then take the jump if P3 is true. */ /* Opcode: IfNot P1 P2 P3 * * ** -** Jump to P2 if the value in register P1 is False. The value is +** Jump to P2 if the value in register P1 is False. The value ** is considered true if it has a numeric value of zero. If the value ** in P1 is NULL then take the jump if P3 is true. */ @@ -64805,6 +65373,17 @@ case OP_Savepoint: { }else{ u.aq.nName = sqlite3Strlen30(u.aq.zName); +#ifndef SQLITE_OMIT_VIRTUALTABLE + /* This call is Ok even if this savepoint is actually a transaction + ** savepoint (and therefore should not prompt xSavepoint()) callbacks. + ** If this is a transaction savepoint being opened, it is guaranteed + ** that the db->aVTrans[] array is empty. */ + assert( db->autoCommit==0 || db->nVTrans==0 ); + rc = sqlite3VtabSavepoint(db, SAVEPOINT_BEGIN, + db->nStatement+db->nSavepoint); + if( rc!=SQLITE_OK ) goto abort_due_to_error; +#endif + /* Create a new savepoint structure. */ u.aq.pNew = sqlite3DbMallocRaw(db, sizeof(Savepoint)+u.aq.nName+1); if( u.aq.pNew ){ @@ -64911,6 +65490,11 @@ case OP_Savepoint: { }else{ db->nDeferredCons = u.aq.pSavepoint->nDeferredCons; } + + if( !isTransaction ){ + rc = sqlite3VtabSavepoint(db, u.aq.p1, u.aq.iSavepoint); + if( rc!=SQLITE_OK ) goto abort_due_to_error; + } } } @@ -65050,7 +65634,11 @@ case OP_Transaction: { db->nStatement++; p->iStatement = db->nSavepoint + db->nStatement; } - rc = sqlite3BtreeBeginStmt(u.as.pBt, p->iStatement); + + rc = sqlite3VtabSavepoint(db, SAVEPOINT_BEGIN, p->iStatement-1); + if( rc==SQLITE_OK ){ + rc = sqlite3BtreeBeginStmt(u.as.pBt, p->iStatement); + } /* Store the current value of the database handles deferred constraint ** counter. If the statement transaction needs to be rolled back, @@ -65371,7 +65959,7 @@ case OP_OpenEphemeral: { u.ax.pCx = allocateCursor(p, pOp->p1, pOp->p2, -1, 1); if( u.ax.pCx==0 ) goto no_mem; u.ax.pCx->nullRow = 1; - rc = sqlite3BtreeOpen(0, db, &u.ax.pCx->pBt, + rc = sqlite3BtreeOpen(db->pVfs, 0, db, &u.ax.pCx->pBt, BTREE_OMIT_JOURNAL | BTREE_SINGLE | pOp->p5, vfsFlags); if( rc==SQLITE_OK ){ rc = sqlite3BtreeBeginTrans(u.ax.pCx->pBt, 1); @@ -65858,7 +66446,7 @@ case OP_IsUnique: { /* jump, in3 */ /* Opcode: NotExists P1 P2 P3 * * ** -** Use the content of register P3 as a integer key. If a record +** Use the content of register P3 as an integer key. If a record ** with that key does not exist in table of P1, then jump to P2. ** If the record does exist, then fall through. The cursor is left ** pointing to the record if it exists. @@ -65936,7 +66524,7 @@ case OP_Sequence: { /* out2-prerelease */ ** If P3>0 then P3 is a register in the root frame of this VDBE that holds ** the largest previously generated record number. No new record numbers are ** allowed to be less than this value. When this value reaches its maximum, -** a SQLITE_FULL error is generated. The P3 register is updated with the ' +** an SQLITE_FULL error is generated. The P3 register is updated with the ' ** generated record number. This P3 mechanism is used to help implement the ** AUTOINCREMENT feature. */ @@ -66045,7 +66633,7 @@ case OP_NewRowid: { /* out2-prerelease */ assert( pOp->p3==0 ); /* We cannot be in random rowid mode if this is ** an AUTOINCREMENT table. */ /* on the first attempt, simply do one more than previous */ - u.be.v = db->lastRowid; + u.be.v = lastRowid; u.be.v &= (MAX_ROWID>>1); /* ensure doesn't go negative */ u.be.v++; /* ensure non-zero */ u.be.cnt = 0; @@ -66157,7 +66745,7 @@ case OP_InsertInt: { } if( pOp->p5 & OPFLAG_NCHANGE ) p->nChange++; - if( pOp->p5 & OPFLAG_LASTROWID ) db->lastRowid = u.bf.iKey; + if( pOp->p5 & OPFLAG_LASTROWID ) db->lastRowid = lastRowid = u.bf.iKey; if( u.bf.pData->flags & MEM_Null ){ u.bf.pData->z = 0; u.bf.pData->n = 0; @@ -66578,7 +67166,7 @@ case OP_Next: { /* jump */ /* Opcode: IdxInsert P1 P2 P3 * P5 ** -** Register P2 holds a SQL index key made using the +** Register P2 holds an SQL index key made using the ** MakeRecord instructions. This opcode writes that key ** into the index P1. Data for the entry is nil. ** @@ -67283,7 +67871,7 @@ case OP_Program: { /* jump */ p->nFrame++; u.by.pFrame->pParent = p->pFrame; - u.by.pFrame->lastRowid = db->lastRowid; + u.by.pFrame->lastRowid = lastRowid; u.by.pFrame->nChange = p->nChange; p->nChange = 0; p->pFrame = u.by.pFrame; @@ -68094,11 +68682,15 @@ case OP_VUpdate: { Mem *pX; #endif /* local variables moved into u.cm */ + assert( pOp->p2==1 || pOp->p5==OE_Fail || pOp->p5==OE_Rollback + || pOp->p5==OE_Abort || pOp->p5==OE_Ignore || pOp->p5==OE_Replace + ); u.cm.pVtab = pOp->p4.pVtab->pVtab; u.cm.pModule = (sqlite3_module *)u.cm.pVtab->pModule; u.cm.nArg = pOp->p2; assert( pOp->p4type==P4_VTAB ); if( ALWAYS(u.cm.pModule->xUpdate) ){ + u8 vtabOnConflict = db->vtabOnConflict; u.cm.apArg = p->apArg; u.cm.pX = &aMem[pOp->p3]; for(u.cm.i=0; u.cm.ivtabOnConflict = pOp->p5; rc = u.cm.pModule->xUpdate(u.cm.pVtab, u.cm.nArg, u.cm.apArg, &u.cm.rowid); + db->vtabOnConflict = vtabOnConflict; importVtabErrMsg(p, u.cm.pVtab); if( rc==SQLITE_OK && pOp->p1 ){ assert( u.cm.nArg>1 && u.cm.apArg[0] && (u.cm.apArg[0]->flags&MEM_Null) ); - db->lastRowid = u.cm.rowid; + db->lastRowid = lastRowid = u.cm.rowid; + } + if( rc==SQLITE_CONSTRAINT && pOp->p4.pVtab->bConstraint ){ + if( pOp->p5==OE_Ignore ){ + rc = SQLITE_OK; + }else{ + p->errorAction = ((pOp->p5==OE_Replace) ? OE_Abort : pOp->p5); + } + }else{ + p->nChange++; } - p->nChange++; } break; } @@ -68166,21 +68768,21 @@ case OP_MaxPgcnt: { /* out2-prerelease */ case OP_Trace: { #if 0 /* local variables moved into u.cn */ char *zTrace; + char *z; #endif /* local variables moved into u.cn */ - u.cn.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql); - if( u.cn.zTrace ){ - if( db->xTrace ){ - char *z = sqlite3VdbeExpandSql(p, u.cn.zTrace); - db->xTrace(db->pTraceArg, z); - sqlite3DbFree(db, z); - } + if( db->xTrace && (u.cn.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql))!=0 ){ + u.cn.z = sqlite3VdbeExpandSql(p, u.cn.zTrace); + db->xTrace(db->pTraceArg, u.cn.z); + sqlite3DbFree(db, u.cn.z); + } #ifdef SQLITE_DEBUG - if( (db->flags & SQLITE_SqlTrace)!=0 ){ - sqlite3DebugPrintf("SQL-trace: %s\n", u.cn.zTrace); - } -#endif /* SQLITE_DEBUG */ + if( (db->flags & SQLITE_SqlTrace)!=0 + && (u.cn.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql))!=0 + ){ + sqlite3DebugPrintf("SQL-trace: %s\n", u.cn.zTrace); } +#endif /* SQLITE_DEBUG */ break; } #endif @@ -68264,6 +68866,7 @@ default: { /* This is really OP_Noop and OP_Explain */ ** release the mutexes on btrees that were acquired at the ** top. */ vdbe_return: + db->lastRowid = lastRowid; sqlite3VdbeLeave(p); return rc; @@ -68604,7 +69207,10 @@ SQLITE_API int sqlite3_blob_open( sqlite3VdbeChangeP4(v, 3+flags, SQLITE_INT_TO_PTR(pTab->nCol+1),P4_INT32); sqlite3VdbeChangeP2(v, 7, pTab->nCol); if( !db->mallocFailed ){ - sqlite3VdbeMakeReady(v, 1, 1, 1, 0, 0, 0); + pParse->nVar = 1; + pParse->nMem = 1; + pParse->nTab = 1; + sqlite3VdbeMakeReady(v, pParse); } } @@ -71171,53 +71777,53 @@ SQLITE_PRIVATE void sqlite3ExprAssignVarNumber(Parse *pParse, Expr *pExpr){ /* Wildcard of the form "?". Assign the next variable number */ assert( z[0]=='?' ); pExpr->iColumn = (ynVar)(++pParse->nVar); - }else if( z[0]=='?' ){ - /* Wildcard of the form "?nnn". Convert "nnn" to an integer and - ** use it as the variable number */ - i64 i; - int bOk = 0==sqlite3Atoi64(&z[1], &i, sqlite3Strlen30(&z[1]), SQLITE_UTF8); - pExpr->iColumn = (ynVar)i; - testcase( i==0 ); - testcase( i==1 ); - testcase( i==db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER]-1 ); - testcase( i==db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER] ); - if( bOk==0 || i<1 || i>db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER] ){ - sqlite3ErrorMsg(pParse, "variable number must be between ?1 and ?%d", - db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER]); - } - if( i>pParse->nVar ){ - pParse->nVar = (int)i; - } }else{ - /* Wildcards like ":aaa", "$aaa" or "@aaa". Reuse the same variable - ** number as the prior appearance of the same name, or if the name - ** has never appeared before, reuse the same variable number - */ - int i; - u32 n; - n = sqlite3Strlen30(z); - for(i=0; inVarExpr; i++){ - Expr *pE = pParse->apVarExpr[i]; - assert( pE!=0 ); - if( memcmp(pE->u.zToken, z, n)==0 && pE->u.zToken[n]==0 ){ - pExpr->iColumn = pE->iColumn; - break; + ynVar x = 0; + u32 n = sqlite3Strlen30(z); + if( z[0]=='?' ){ + /* Wildcard of the form "?nnn". Convert "nnn" to an integer and + ** use it as the variable number */ + i64 i; + int bOk = 0==sqlite3Atoi64(&z[1], &i, n-1, SQLITE_UTF8); + pExpr->iColumn = x = (ynVar)i; + testcase( i==0 ); + testcase( i==1 ); + testcase( i==db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER]-1 ); + testcase( i==db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER] ); + if( bOk==0 || i<1 || i>db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER] ){ + sqlite3ErrorMsg(pParse, "variable number must be between ?1 and ?%d", + db->aLimit[SQLITE_LIMIT_VARIABLE_NUMBER]); + x = 0; + } + if( i>pParse->nVar ){ + pParse->nVar = (int)i; } + }else{ + /* Wildcards like ":aaa", "$aaa" or "@aaa". Reuse the same variable + ** number as the prior appearance of the same name, or if the name + ** has never appeared before, reuse the same variable number + */ + ynVar i; + for(i=0; inzVar; i++){ + if( pParse->azVar[i] && memcmp(pParse->azVar[i],z,n+1)==0 ){ + pExpr->iColumn = x = (ynVar)i+1; + break; + } + } + if( x==0 ) x = pExpr->iColumn = (ynVar)(++pParse->nVar); } - if( i>=pParse->nVarExpr ){ - pExpr->iColumn = (ynVar)(++pParse->nVar); - if( pParse->nVarExpr>=pParse->nVarExprAlloc-1 ){ - pParse->nVarExprAlloc += pParse->nVarExprAlloc + 10; - pParse->apVarExpr = - sqlite3DbReallocOrFree( - db, - pParse->apVarExpr, - pParse->nVarExprAlloc*sizeof(pParse->apVarExpr[0]) - ); + if( x>0 ){ + if( x>pParse->nzVar ){ + char **a; + a = sqlite3DbRealloc(db, pParse->azVar, x*sizeof(a[0])); + if( a==0 ) return; /* Error reported through db->mallocFailed */ + pParse->azVar = a; + memset(&a[pParse->nzVar], 0, (x-pParse->nzVar)*sizeof(a[0])); + pParse->nzVar = x; } - if( !db->mallocFailed ){ - assert( pParse->apVarExpr!=0 ); - pParse->apVarExpr[pParse->nVarExpr++] = pExpr; + if( z[0]!='?' || pParse->azVar[x-1]==0 ){ + sqlite3DbFree(db, pParse->azVar[x-1]); + pParse->azVar[x-1] = sqlite3DbStrNDup(db, z, n); } } } @@ -72961,7 +73567,9 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target) assert( pExpr->u.zToken[0]!=0 ); sqlite3VdbeAddOp2(v, OP_Variable, pExpr->iColumn, target); if( pExpr->u.zToken[1]!=0 ){ - sqlite3VdbeChangeP4(v, -1, pExpr->u.zToken, P4_TRANSIENT); + assert( pExpr->u.zToken[0]=='?' + || strcmp(pExpr->u.zToken, pParse->azVar[pExpr->iColumn-1])==0 ); + sqlite3VdbeChangeP4(v, -1, pParse->azVar[pExpr->iColumn-1], P4_STATIC); } break; } @@ -74731,14 +75339,14 @@ static void reloadTableSchema(Parse *pParse, Table *pTab, const char *zName){ /* Reload the table, index and permanent trigger schemas. */ zWhere = sqlite3MPrintf(pParse->db, "tbl_name=%Q", zName); if( !zWhere ) return; - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, zWhere, P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, iDb, zWhere); #ifndef SQLITE_OMIT_TRIGGER /* Now, if the table is not stored in the temp database, reload any temp ** triggers. Don't use IN(...) in case SQLITE_OMIT_SUBQUERY is defined. */ if( (zWhere=whereTempTriggers(pParse, pTab))!=0 ){ - sqlite3VdbeAddOp4(v, OP_ParseSchema, 1, 0, 0, zWhere, P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, 1, zWhere); } #endif } @@ -75992,8 +76600,12 @@ static void attachFunc( sqlite3 *db = sqlite3_context_db_handle(context); const char *zName; const char *zFile; + char *zPath = 0; + char *zErr = 0; + unsigned int flags; Db *aNew; char *zErrDyn = 0; + sqlite3_vfs *pVfs; UNUSED_PARAMETER(NotUsed); @@ -76046,8 +76658,18 @@ static void attachFunc( ** it to obtain the database schema. At this point the schema may ** or may not be initialised. */ - rc = sqlite3BtreeOpen(zFile, db, &aNew->pBt, 0, - db->openFlags | SQLITE_OPEN_MAIN_DB); + flags = db->openFlags; + rc = sqlite3ParseUri(db->pVfs->zName, zFile, &flags, &pVfs, &zPath, &zErr); + if( rc!=SQLITE_OK ){ + if( rc==SQLITE_NOMEM ) db->mallocFailed = 1; + sqlite3_result_error(context, zErr, -1); + sqlite3_free(zErr); + return; + } + assert( pVfs ); + flags |= SQLITE_OPEN_MAIN_DB; + rc = sqlite3BtreeOpen(pVfs, zPath, db, &aNew->pBt, 0, flags); + sqlite3_free( zPath ); db->nDb++; if( rc==SQLITE_CONSTRAINT ){ rc = SQLITE_ERROR; @@ -76918,9 +77540,7 @@ SQLITE_PRIVATE void sqlite3FinishCoding(Parse *pParse){ /* A minimum of one cursor is required if autoincrement is used * See ticket [a696379c1f08866] */ if( pParse->pAinc!=0 && pParse->nTab==0 ) pParse->nTab = 1; - sqlite3VdbeMakeReady(v, pParse->nVar, pParse->nMem, - pParse->nTab, pParse->nMaxArg, pParse->explain, - pParse->isMultiWrite && pParse->mayAbort); + sqlite3VdbeMakeReady(v, pParse); pParse->rc = SQLITE_DONE; pParse->colNamesSet = 0; }else{ @@ -78339,8 +78959,8 @@ SQLITE_PRIVATE void sqlite3EndTable( #endif /* Reparse everything to update our internal data structures */ - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, - sqlite3MPrintf(db, "tbl_name='%q'",p->zName), P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, iDb, + sqlite3MPrintf(db, "tbl_name='%q'", p->zName)); } @@ -79537,9 +80157,8 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex( if( pTblName ){ sqlite3RefillIndex(pParse, pIndex, iMem); sqlite3ChangeCookie(pParse, iDb); - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, - sqlite3MPrintf(db, "name='%q' AND type='index'", pIndex->zName), - P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, iDb, + sqlite3MPrintf(db, "name='%q' AND type='index'", pIndex->zName)); sqlite3VdbeAddOp1(v, OP_Expire, 0); } } @@ -80161,7 +80780,7 @@ SQLITE_PRIVATE int sqlite3OpenTempDatabase(Parse *pParse){ SQLITE_OPEN_DELETEONCLOSE | SQLITE_OPEN_TEMP_DB; - rc = sqlite3BtreeOpen(0, db, &pBt, 0, flags); + rc = sqlite3BtreeOpen(db->pVfs, 0, db, &pBt, 0, flags); if( rc!=SQLITE_OK ){ sqlite3ErrorMsg(pParse, "unable to open a temporary database " "file for storing temporary tables"); @@ -81337,6 +81956,7 @@ SQLITE_PRIVATE void sqlite3DeleteFrom( const char *pVTab = (const char *)sqlite3GetVTable(db, pTab); sqlite3VtabMakeWritable(pParse, pTab); sqlite3VdbeAddOp4(v, OP_VUpdate, 0, 1, iRowid, pVTab, P4_VTAB); + sqlite3VdbeChangeP5(v, OE_Abort); sqlite3MayAbort(pParse); }else #endif @@ -81571,8 +82191,14 @@ SQLITE_PRIVATE int sqlite3GenerateIndexKey( } } if( doMakeRec ){ + const char *zAff; + if( pTab->pSelect || (pParse->db->flags & SQLITE_IdxRealAsInt)!=0 ){ + zAff = 0; + }else{ + zAff = sqlite3IndexAffinityStr(v, pIdx); + } sqlite3VdbeAddOp3(v, OP_MakeRecord, regBase, nCol+1, regOut); - sqlite3VdbeChangeP4(v, -1, sqlite3IndexAffinityStr(v, pIdx), P4_TRANSIENT); + sqlite3VdbeChangeP4(v, -1, zAff, P4_TRANSIENT); } sqlite3ReleaseTempRange(pParse, regBase, nCol+1); return regBase; @@ -82084,10 +82710,10 @@ struct compareInfo { ** whereas only characters less than 0x80 do in ASCII. */ #if defined(SQLITE_EBCDIC) -# define sqlite3Utf8Read(A,C) (*(A++)) -# define GlogUpperToLower(A) A = sqlite3UpperToLower[A] +# define sqlite3Utf8Read(A,C) (*(A++)) +# define GlogUpperToLower(A) A = sqlite3UpperToLower[A] #else -# define GlogUpperToLower(A) if( A<0x80 ){ A = sqlite3UpperToLower[A]; } +# define GlogUpperToLower(A) if( !((A)&~0x7f) ){ A = sqlite3UpperToLower[A]; } #endif static const struct compareInfo globInfo = { '*', '?', '[', 0 }; @@ -82130,9 +82756,9 @@ static int patternCompare( const u8 *zPattern, /* The glob pattern */ const u8 *zString, /* The string to compare against the glob */ const struct compareInfo *pInfo, /* Information about how to do the compare */ - const int esc /* The escape character */ + u32 esc /* The escape character */ ){ - int c, c2; + u32 c, c2; int invert; int seen; u8 matchOne = pInfo->matchOne; @@ -82186,7 +82812,7 @@ static int patternCompare( return 0; } }else if( c==matchSet ){ - int prior_c = 0; + u32 prior_c = 0; assert( esc==0 ); /* This only occurs for GLOB, not LIKE */ seen = 0; invert = 0; @@ -82262,7 +82888,7 @@ static void likeFunc( sqlite3_value **argv ){ const unsigned char *zA, *zB; - int escape = 0; + u32 escape = 0; int nPat; sqlite3 *db = sqlite3_context_db_handle(context); @@ -82352,6 +82978,21 @@ static void sourceidFunc( sqlite3_result_text(context, sqlite3_sourceid(), -1, SQLITE_STATIC); } +/* +** Implementation of the sqlite_log() function. This is a wrapper around +** sqlite3_log(). The return value is NULL. The function exists purely for +** its side-effects. +*/ +static void errlogFunc( + sqlite3_context *context, + int argc, + sqlite3_value **argv +){ + UNUSED_PARAMETER(argc); + UNUSED_PARAMETER(context); + sqlite3_log(sqlite3_value_int(argv[0]), "%s", sqlite3_value_text(argv[1])); +} + /* ** Implementation of the sqlite_compileoption_used() function. ** The result is an integer that identifies if the compiler option @@ -83119,6 +83760,7 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){ FUNCTION(nullif, 2, 0, 1, nullifFunc ), FUNCTION(sqlite_version, 0, 0, 0, versionFunc ), FUNCTION(sqlite_source_id, 0, 0, 0, sourceidFunc ), + FUNCTION(sqlite_log, 2, 0, 0, errlogFunc ), #ifndef SQLITE_OMIT_COMPILEOPTION_DIAGS FUNCTION(sqlite_compileoption_used,1, 0, 0, compileoptionusedFunc ), FUNCTION(sqlite_compileoption_get, 1, 0, 0, compileoptiongetFunc ), @@ -83557,13 +84199,25 @@ static void fkLookupParent( /* If the parent table is the same as the child table, and we are about ** to increment the constraint-counter (i.e. this is an INSERT operation), ** then check if the row being inserted matches itself. If so, do not - ** increment the constraint-counter. */ + ** increment the constraint-counter. + ** + ** If any of the parent-key values are NULL, then the row cannot match + ** itself. So set JUMPIFNULL to make sure we do the OP_Found if any + ** of the parent-key values are NULL (at this point it is known that + ** none of the child key values are). + */ if( pTab==pFKey->pFrom && nIncr==1 ){ int iJump = sqlite3VdbeCurrentAddr(v) + nCol + 1; for(i=0; iaiColumn[i]+1+regData; + assert( aiCol[i]!=pTab->iPKey ); + if( pIdx->aiColumn[i]==pTab->iPKey ){ + /* The parent key is a composite key that includes the IPK column */ + iParent = regData; + } sqlite3VdbeAddOp3(v, OP_Ne, iChild, iJump, iParent); + sqlite3VdbeChangeP5(v, SQLITE_JUMPIFNULL); } sqlite3VdbeAddOp2(v, OP_Goto, 0, iOk); } @@ -85331,6 +85985,7 @@ SQLITE_PRIVATE void sqlite3Insert( const char *pVTab = (const char *)sqlite3GetVTable(db, pTab); sqlite3VtabMakeWritable(pParse, pTab); sqlite3VdbeAddOp4(v, OP_VUpdate, 1, pTab->nCol+2, regIns, pVTab, P4_VTAB); + sqlite3VdbeChangeP5(v, onError==OE_Default ? OE_Abort : onError); sqlite3MayAbort(pParse); }else #endif @@ -86096,6 +86751,18 @@ static int xferOptimization( return 0; /* Tables have different CHECK constraints. Ticket #2252 */ } #endif +#ifndef SQLITE_OMIT_FOREIGN_KEY + /* Disallow the transfer optimization if the destination table constains + ** any foreign key constraints. This is more restrictive than necessary. + ** But the main beneficiary of the transfer optimization is the VACUUM + ** command, and the VACUUM command disables foreign key constraints. So + ** the extra complication to make this rule less restrictive is probably + ** not worth the effort. Ticket [6284df89debdfa61db8073e062908af0c9b6118e] + */ + if( (pParse->db->flags & SQLITE_ForeignKeys)!=0 && pDest->pFKey!=0 ){ + return 0; + } +#endif /* If we get this far, it means either: ** @@ -87428,10 +88095,6 @@ SQLITE_PRIVATE void sqlite3AutoLoadExtensions(sqlite3 *db){ ** This file contains code used to implement the PRAGMA command. */ -/* Ignore this whole file if pragmas are disabled -*/ -#if !defined(SQLITE_OMIT_PRAGMA) - /* ** Interpret the given string as a safety level. Return 0 for OFF, ** 1 for ON or NORMAL and 2 for FULL. Return 1 for an empty or @@ -87464,10 +88127,16 @@ static u8 getSafetyLevel(const char *z){ /* ** Interpret the given string as a boolean value. */ -static u8 getBoolean(const char *z){ +SQLITE_PRIVATE u8 sqlite3GetBoolean(const char *z){ return getSafetyLevel(z)&1; } +/* The sqlite3GetBoolean() function is used by other modules but the +** remainder of this file is specific to PRAGMA processing. So omit +** the rest of the file if PRAGMAs are omitted from the build. +*/ +#if !defined(SQLITE_OMIT_PRAGMA) + /* ** Interpret the given string as a locking mode value. */ @@ -87634,7 +88303,7 @@ static int flagPragma(Parse *pParse, const char *zLeft, const char *zRight){ mask &= ~(SQLITE_ForeignKeys); } - if( getBoolean(zRight) ){ + if( sqlite3GetBoolean(zRight) ){ db->flags |= mask; }else{ db->flags &= ~mask; @@ -87848,7 +88517,7 @@ SQLITE_PRIVATE void sqlite3Pragma( int b = -1; assert( pBt!=0 ); if( zRight ){ - b = getBoolean(zRight); + b = sqlite3GetBoolean(zRight); } if( pId2->n==0 && b>=0 ){ int ii; @@ -88448,7 +89117,7 @@ SQLITE_PRIVATE void sqlite3Pragma( #ifndef NDEBUG if( sqlite3StrICmp(zLeft, "parser_trace")==0 ){ if( zRight ){ - if( getBoolean(zRight) ){ + if( sqlite3GetBoolean(zRight) ){ sqlite3ParserTrace(stderr, "parser: "); }else{ sqlite3ParserTrace(0, 0); @@ -88462,7 +89131,7 @@ SQLITE_PRIVATE void sqlite3Pragma( */ if( sqlite3StrICmp(zLeft, "case_sensitive_like")==0 ){ if( zRight ){ - sqlite3RegisterLikeFunctions(db, getBoolean(zRight)); + sqlite3RegisterLikeFunctions(db, sqlite3GetBoolean(zRight)); } }else @@ -94040,11 +94709,13 @@ SQLITE_PRIVATE int sqlite3Select( ** and pKeyInfo to the KeyInfo structure required to navigate the ** index. ** + ** (2011-04-15) Do not do a full scan of an unordered index. + ** ** In practice the KeyInfo structure will not be used. It is only ** passed to keep OP_OpenRead happy. */ for(pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext){ - if( !pBest || pIdx->nColumnnColumn ){ + if( pIdx->bUnordered==0 && (!pBest || pIdx->nColumnnColumn) ){ pBest = pIdx; } } @@ -94766,9 +95437,8 @@ SQLITE_PRIVATE void sqlite3FinishTrigger( pTrig->table, z); sqlite3DbFree(db, z); sqlite3ChangeCookie(pParse, iDb); - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, sqlite3MPrintf( - db, "type='trigger' AND name='%q'", zName), P4_DYNAMIC - ); + sqlite3VdbeAddParseSchemaOp(v, iDb, + sqlite3MPrintf(db, "type='trigger' AND name='%q'", zName)); } if( db->init.busy ){ @@ -95601,7 +96271,8 @@ static void updateVirtualTable( ExprList *pChanges, /* The columns to change in the UPDATE statement */ Expr *pRowidExpr, /* Expression used to recompute the rowid */ int *aXRef, /* Mapping from columns of pTab to entries in pChanges */ - Expr *pWhere /* WHERE clause of the UPDATE statement */ + Expr *pWhere, /* WHERE clause of the UPDATE statement */ + int onError /* ON CONFLICT strategy */ ); #endif /* SQLITE_OMIT_VIRTUALTABLE */ @@ -95821,7 +96492,7 @@ SQLITE_PRIVATE void sqlite3Update( } for(j=0, pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext, j++){ int reg; - if( chngRowid ){ + if( hasFK || chngRowid ){ reg = ++pParse->nMem; }else{ reg = 0; @@ -95845,7 +96516,7 @@ SQLITE_PRIVATE void sqlite3Update( /* Virtual tables must be handled separately */ if( IsVirtual(pTab) ){ updateVirtualTable(pParse, pTabList, pTab, pChanges, pRowidExpr, aXRef, - pWhere); + pWhere, onError); pWhere = 0; pTabList = 0; goto update_cleanup; @@ -96175,7 +96846,8 @@ static void updateVirtualTable( ExprList *pChanges, /* The columns to change in the UPDATE statement */ Expr *pRowid, /* Expression used to recompute the rowid */ int *aXRef, /* Mapping from columns of pTab to entries in pChanges */ - Expr *pWhere /* WHERE clause of the UPDATE statement */ + Expr *pWhere, /* WHERE clause of the UPDATE statement */ + int onError /* ON CONFLICT strategy */ ){ Vdbe *v = pParse->pVdbe; /* Virtual machine under construction */ ExprList *pEList = 0; /* The result set of the SELECT statement */ @@ -96232,6 +96904,7 @@ static void updateVirtualTable( } sqlite3VtabMakeWritable(pParse, pTab); sqlite3VdbeAddOp4(v, OP_VUpdate, 0, pTab->nCol+2, iReg, pVTab, P4_VTAB); + sqlite3VdbeChangeP5(v, onError==OE_Default ? OE_Abort : onError); sqlite3MayAbort(pParse); sqlite3VdbeAddOp2(v, OP_Next, ephemTab, addr+1); sqlite3VdbeJumpHere(v, addr); @@ -96605,6 +97278,18 @@ SQLITE_PRIVATE int sqlite3RunVacuum(char **pzErrMsg, sqlite3 *db){ */ #ifndef SQLITE_OMIT_VIRTUALTABLE +/* +** Before a virtual table xCreate() or xConnect() method is invoked, the +** sqlite3.pVtabCtx member variable is set to point to an instance of +** this struct allocated on the stack. It is used by the implementation of +** the sqlite3_declare_vtab() and sqlite3_vtab_config() APIs, both of which +** are invoked only from within xCreate and xConnect methods. +*/ +struct VtabCtx { + Table *pTab; + VTable *pVTable; +}; + /* ** The actual function that does the work of creating a new module. ** This function implements the sqlite3_create_module() and @@ -96633,13 +97318,13 @@ static int createModule( pMod->xDestroy = xDestroy; pDel = (Module *)sqlite3HashInsert(&db->aModule, zCopy, nName, (void*)pMod); if( pDel && pDel->xDestroy ){ + sqlite3ResetInternalSchema(db, -1); pDel->xDestroy(pDel->pAux); } sqlite3DbFree(db, pDel); if( pDel==pMod ){ db->mallocFailed = 1; } - sqlite3ResetInternalSchema(db, -1); }else if( xDestroy ){ xDestroy(pAux); } @@ -96962,7 +97647,7 @@ SQLITE_PRIVATE void sqlite3VtabFinishParse(Parse *pParse, Token *pEnd){ sqlite3VdbeAddOp2(v, OP_Expire, 0, 0); zWhere = sqlite3MPrintf(db, "name='%q' AND type='table'", pTab->zName); - sqlite3VdbeAddOp4(v, OP_ParseSchema, iDb, 0, 0, zWhere, P4_DYNAMIC); + sqlite3VdbeAddParseSchemaOp(v, iDb, zWhere); sqlite3VdbeAddOp4(v, OP_VCreate, iDb, 0, 0, pTab->zName, sqlite3Strlen30(pTab->zName) + 1); } @@ -97025,6 +97710,7 @@ static int vtabCallConstructor( int (*xConstruct)(sqlite3*,void*,int,const char*const*,sqlite3_vtab**,char**), char **pzErr ){ + VtabCtx sCtx; VTable *pVTable; int rc; const char *const*azArg = (const char *const*)pTab->azModuleArg; @@ -97044,12 +97730,14 @@ static int vtabCallConstructor( pVTable->db = db; pVTable->pMod = pMod; - assert( !db->pVTab ); - assert( xConstruct ); - db->pVTab = pTab; - /* Invoke the virtual table constructor */ + assert( &db->pVtabCtx ); + assert( xConstruct ); + sCtx.pTab = pTab; + sCtx.pVTable = pVTable; + db->pVtabCtx = &sCtx; rc = xConstruct(db, pMod->pAux, nArg, azArg, &pVTable->pVtab, &zErr); + db->pVtabCtx = 0; if( rc==SQLITE_NOMEM ) db->mallocFailed = 1; if( SQLITE_OK!=rc ){ @@ -97065,7 +97753,7 @@ static int vtabCallConstructor( ** the sqlite3_vtab object if successful. */ pVTable->pVtab->pModule = pMod->pModule; pVTable->nRef = 1; - if( db->pVTab ){ + if( sCtx.pTab ){ const char *zFormat = "vtable constructor did not declare schema: %s"; *pzErr = sqlite3MPrintf(db, zFormat, pTab->zName); sqlite3VtabUnlock(pVTable); @@ -97113,7 +97801,6 @@ static int vtabCallConstructor( } sqlite3DbFree(db, zModuleName); - db->pVTab = 0; return rc; } @@ -97154,11 +97841,11 @@ SQLITE_PRIVATE int sqlite3VtabCallConnect(Parse *pParse, Table *pTab){ return rc; } - /* -** Add the virtual table pVTab to the array sqlite3.aVTrans[]. +** Grow the db->aVTrans[] array so that there is room for at least one +** more v-table. Return SQLITE_NOMEM if a malloc fails, or SQLITE_OK otherwise. */ -static int addToVTrans(sqlite3 *db, VTable *pVTab){ +static int growVTrans(sqlite3 *db){ const int ARRAY_INCR = 5; /* Grow the sqlite3.aVTrans array if required */ @@ -97173,10 +97860,17 @@ static int addToVTrans(sqlite3 *db, VTable *pVTab){ db->aVTrans = aVTrans; } + return SQLITE_OK; +} + +/* +** Add the virtual table pVTab to the array sqlite3.aVTrans[]. Space should +** have already been reserved using growVTrans(). +*/ +static void addToVTrans(sqlite3 *db, VTable *pVTab){ /* Add pVtab to the end of sqlite3.aVTrans */ db->aVTrans[db->nVTrans++] = pVTab; sqlite3VtabLock(pVTab); - return SQLITE_OK; } /* @@ -97214,7 +97908,10 @@ SQLITE_PRIVATE int sqlite3VtabCallCreate(sqlite3 *db, int iDb, const char *zTab, /* Justification of ALWAYS(): The xConstructor method is required to ** create a valid sqlite3_vtab if it returns SQLITE_OK. */ if( rc==SQLITE_OK && ALWAYS(sqlite3GetVTable(db, pTab)) ){ - rc = addToVTrans(db, sqlite3GetVTable(db, pTab)); + rc = growVTrans(db); + if( rc==SQLITE_OK ){ + addToVTrans(db, sqlite3GetVTable(db, pTab)); + } } return rc; @@ -97233,8 +97930,7 @@ SQLITE_API int sqlite3_declare_vtab(sqlite3 *db, const char *zCreateTable){ char *zErr = 0; sqlite3_mutex_enter(db->mutex); - pTab = db->pVTab; - if( !pTab ){ + if( !db->pVtabCtx || !(pTab = db->pVtabCtx->pTab) ){ sqlite3Error(db, SQLITE_MISUSE, 0); sqlite3_mutex_leave(db->mutex); return SQLITE_MISUSE_BKPT; @@ -97261,7 +97957,7 @@ SQLITE_API int sqlite3_declare_vtab(sqlite3 *db, const char *zCreateTable){ pParse->pNewTable->nCol = 0; pParse->pNewTable->aCol = 0; } - db->pVTab = 0; + db->pVtabCtx->pTab = 0; }else{ sqlite3Error(db, SQLITE_ERROR, (zErr ? "%s" : 0), zErr); sqlite3DbFree(db, zErr); @@ -97331,6 +98027,7 @@ static void callFinaliser(sqlite3 *db, int offset){ x = *(int (**)(sqlite3_vtab *))((char *)p->pModule + offset); if( x ) x(p); } + pVTab->iSavepoint = 0; sqlite3VtabUnlock(pVTab); } sqlite3DbFree(db, db->aVTrans); @@ -97413,7 +98110,6 @@ SQLITE_PRIVATE int sqlite3VtabBegin(sqlite3 *db, VTable *pVTab){ if( pModule->xBegin ){ int i; - /* If pVtab is already in the aVTrans array, return early */ for(i=0; inVTrans; i++){ if( db->aVTrans[i]==pVTab ){ @@ -97421,10 +98117,62 @@ SQLITE_PRIVATE int sqlite3VtabBegin(sqlite3 *db, VTable *pVTab){ } } - /* Invoke the xBegin method */ - rc = pModule->xBegin(pVTab->pVtab); + /* Invoke the xBegin method. If successful, add the vtab to the + ** sqlite3.aVTrans[] array. */ + rc = growVTrans(db); if( rc==SQLITE_OK ){ - rc = addToVTrans(db, pVTab); + rc = pModule->xBegin(pVTab->pVtab); + if( rc==SQLITE_OK ){ + addToVTrans(db, pVTab); + } + } + } + return rc; +} + +/* +** Invoke either the xSavepoint, xRollbackTo or xRelease method of all +** virtual tables that currently have an open transaction. Pass iSavepoint +** as the second argument to the virtual table method invoked. +** +** If op is SAVEPOINT_BEGIN, the xSavepoint method is invoked. If it is +** SAVEPOINT_ROLLBACK, the xRollbackTo method. Otherwise, if op is +** SAVEPOINT_RELEASE, then the xRelease method of each virtual table with +** an open transaction is invoked. +** +** If any virtual table method returns an error code other than SQLITE_OK, +** processing is abandoned and the error returned to the caller of this +** function immediately. If all calls to virtual table methods are successful, +** SQLITE_OK is returned. +*/ +SQLITE_PRIVATE int sqlite3VtabSavepoint(sqlite3 *db, int op, int iSavepoint){ + int rc = SQLITE_OK; + + assert( op==SAVEPOINT_RELEASE||op==SAVEPOINT_ROLLBACK||op==SAVEPOINT_BEGIN ); + assert( iSavepoint>=0 ); + if( db->aVTrans ){ + int i; + for(i=0; rc==SQLITE_OK && inVTrans; i++){ + VTable *pVTab = db->aVTrans[i]; + const sqlite3_module *pMod = pVTab->pMod->pModule; + if( pMod->iVersion>=2 ){ + int (*xMethod)(sqlite3_vtab *, int); + switch( op ){ + case SAVEPOINT_BEGIN: + xMethod = pMod->xSavepoint; + pVTab->iSavepoint = iSavepoint+1; + break; + case SAVEPOINT_ROLLBACK: + xMethod = pMod->xRollbackTo; + break; + default: + xMethod = pMod->xRelease; + break; + } + if( xMethod && pVTab->iSavepoint>iSavepoint ){ + rc = xMethod(db->aVTrans[i]->pVtab, iSavepoint); + } + } } } return rc; @@ -97528,6 +98276,57 @@ SQLITE_PRIVATE void sqlite3VtabMakeWritable(Parse *pParse, Table *pTab){ } } +/* +** Return the ON CONFLICT resolution mode in effect for the virtual +** table update operation currently in progress. +** +** The results of this routine are undefined unless it is called from +** within an xUpdate method. +*/ +SQLITE_API int sqlite3_vtab_on_conflict(sqlite3 *db){ + static const unsigned char aMap[] = { + SQLITE_ROLLBACK, SQLITE_ABORT, SQLITE_FAIL, SQLITE_IGNORE, SQLITE_REPLACE + }; + assert( OE_Rollback==1 && OE_Abort==2 && OE_Fail==3 ); + assert( OE_Ignore==4 && OE_Replace==5 ); + assert( db->vtabOnConflict>=1 && db->vtabOnConflict<=5 ); + return (int)aMap[db->vtabOnConflict-1]; +} + +/* +** Call from within the xCreate() or xConnect() methods to provide +** the SQLite core with additional information about the behavior +** of the virtual table being implemented. +*/ +SQLITE_API int sqlite3_vtab_config(sqlite3 *db, int op, ...){ + va_list ap; + int rc = SQLITE_OK; + + sqlite3_mutex_enter(db->mutex); + + va_start(ap, op); + switch( op ){ + case SQLITE_VTAB_CONSTRAINT_SUPPORT: { + VtabCtx *p = db->pVtabCtx; + if( !p ){ + rc = SQLITE_MISUSE_BKPT; + }else{ + assert( p->pTab==0 || (p->pTab->tabFlags & TF_Virtual)!=0 ); + p->pVTable->bConstraint = (u8)va_arg(ap, int); + } + break; + } + default: + rc = SQLITE_MISUSE_BKPT; + break; + } + va_end(ap); + + if( rc!=SQLITE_OK ) sqlite3Error(db, rc, 0); + sqlite3_mutex_leave(db->mutex); + return rc; +} + #endif /* SQLITE_OMIT_VIRTUALTABLE */ /************** End of vtab.c ************************************************/ @@ -106575,13 +107374,12 @@ SQLITE_PRIVATE int sqlite3GetToken(const unsigned char *z, int *tokenType){ testcase( z[0]=='x' ); testcase( z[0]=='X' ); if( z[1]=='\'' ){ *tokenType = TK_BLOB; - for(i=2; (c=z[i])!=0 && c!='\''; i++){ - if( !sqlite3Isxdigit(c) ){ - *tokenType = TK_ILLEGAL; - } + for(i=2; sqlite3Isxdigit(z[i]); i++){} + if( z[i]!='\'' || i%2 ){ + *tokenType = TK_ILLEGAL; + while( z[i] && z[i]!='\'' ){ i++; } } - if( i%2 || !c ) *tokenType = TK_ILLEGAL; - if( c ) i++; + if( z[i] ) i++; return i; } /* Otherwise fall through to the next case */ @@ -106634,9 +107432,8 @@ SQLITE_PRIVATE int sqlite3RunParser(Parse *pParse, const char *zSql, char **pzEr assert( pParse->pNewTable==0 ); assert( pParse->pNewTrigger==0 ); assert( pParse->nVar==0 ); - assert( pParse->nVarExpr==0 ); - assert( pParse->nVarExprAlloc==0 ); - assert( pParse->apVarExpr==0 ); + assert( pParse->nzVar==0 ); + assert( pParse->azVar==0 ); enableLookaside = db->lookaside.bEnabled; if( db->lookaside.pStart ) db->lookaside.bEnabled = 1; while( !db->mallocFailed && zSql[i]!=0 ){ @@ -106730,7 +107527,8 @@ SQLITE_PRIVATE int sqlite3RunParser(Parse *pParse, const char *zSql, char **pzEr } sqlite3DeleteTrigger(db, pParse->pNewTrigger); - sqlite3DbFree(db, pParse->apVarExpr); + for(i=pParse->nzVar-1; i>=0; i--) sqlite3DbFree(db, pParse->azVar[i]); + sqlite3DbFree(db, pParse->azVar); sqlite3DbFree(db, pParse->aAlias); while( pParse->pAinc ){ AutoincInfo *p = pParse->pAinc; @@ -107550,6 +108348,11 @@ SQLITE_API int sqlite3_config(int op, ...){ break; } + case SQLITE_CONFIG_URI: { + sqlite3GlobalConfig.bOpenUri = va_arg(ap, int); + break; + } + default: { rc = SQLITE_ERROR; break; @@ -108909,6 +109712,236 @@ SQLITE_API int sqlite3_limit(sqlite3 *db, int limitId, int newLimit){ return oldLimit; /* IMP: R-53341-35419 */ } +/* +** This function is used to parse both URIs and non-URI filenames passed by the +** user to API functions sqlite3_open() or sqlite3_open_v2(), and for database +** URIs specified as part of ATTACH statements. +** +** The first argument to this function is the name of the VFS to use (or +** a NULL to signify the default VFS) if the URI does not contain a "vfs=xxx" +** query parameter. The second argument contains the URI (or non-URI filename) +** itself. When this function is called the *pFlags variable should contain +** the default flags to open the database handle with. The value stored in +** *pFlags may be updated before returning if the URI filename contains +** "cache=xxx" or "mode=xxx" query parameters. +** +** If successful, SQLITE_OK is returned. In this case *ppVfs is set to point to +** the VFS that should be used to open the database file. *pzFile is set to +** point to a buffer containing the name of the file to open. It is the +** responsibility of the caller to eventually call sqlite3_free() to release +** this buffer. +** +** If an error occurs, then an SQLite error code is returned and *pzErrMsg +** may be set to point to a buffer containing an English language error +** message. It is the responsibility of the caller to eventually release +** this buffer by calling sqlite3_free(). +*/ +SQLITE_PRIVATE int sqlite3ParseUri( + const char *zDefaultVfs, /* VFS to use if no "vfs=xxx" query option */ + const char *zUri, /* Nul-terminated URI to parse */ + unsigned int *pFlags, /* IN/OUT: SQLITE_OPEN_XXX flags */ + sqlite3_vfs **ppVfs, /* OUT: VFS to use */ + char **pzFile, /* OUT: Filename component of URI */ + char **pzErrMsg /* OUT: Error message (if rc!=SQLITE_OK) */ +){ + int rc = SQLITE_OK; + unsigned int flags = *pFlags; + const char *zVfs = zDefaultVfs; + char *zFile; + char c; + int nUri = sqlite3Strlen30(zUri); + + assert( *pzErrMsg==0 ); + + if( ((flags & SQLITE_OPEN_URI) || sqlite3GlobalConfig.bOpenUri) + && nUri>=5 && memcmp(zUri, "file:", 5)==0 + ){ + char *zOpt; + int eState; /* Parser state when parsing URI */ + int iIn; /* Input character index */ + int iOut = 0; /* Output character index */ + int nByte = nUri+2; /* Bytes of space to allocate */ + + /* Make sure the SQLITE_OPEN_URI flag is set to indicate to the VFS xOpen + ** method that there may be extra parameters following the file-name. */ + flags |= SQLITE_OPEN_URI; + + for(iIn=0; iIn=0 && octet<256 ); + if( octet==0 ){ + /* This branch is taken when "%00" appears within the URI. In this + ** case we ignore all text in the remainder of the path, name or + ** value currently being parsed. So ignore the current character + ** and skip to the next "?", "=" or "&", as appropriate. */ + while( (c = zUri[iIn])!=0 && c!='#' + && (eState!=0 || c!='?') + && (eState!=1 || (c!='=' && c!='&')) + && (eState!=2 || c!='&') + ){ + iIn++; + } + continue; + } + c = octet; + }else if( eState==1 && (c=='&' || c=='=') ){ + if( zFile[iOut-1]==0 ){ + /* An empty option name. Ignore this option altogether. */ + while( zUri[iIn] && zUri[iIn]!='#' && zUri[iIn-1]!='&' ) iIn++; + continue; + } + if( c=='&' ){ + zFile[iOut++] = '\0'; + }else{ + eState = 2; + } + c = 0; + }else if( (eState==0 && c=='?') || (eState==2 && c=='&') ){ + c = 0; + eState = 1; + } + zFile[iOut++] = c; + } + if( eState==1 ) zFile[iOut++] = '\0'; + zFile[iOut++] = '\0'; + zFile[iOut++] = '\0'; + + /* Check if there were any options specified that should be interpreted + ** here. Options that are interpreted here include "vfs" and those that + ** correspond to flags that may be passed to the sqlite3_open_v2() + ** method. */ + zOpt = &zFile[sqlite3Strlen30(zFile)+1]; + while( zOpt[0] ){ + int nOpt = sqlite3Strlen30(zOpt); + char *zVal = &zOpt[nOpt+1]; + int nVal = sqlite3Strlen30(zVal); + + if( nOpt==3 && memcmp("vfs", zOpt, 3)==0 ){ + zVfs = zVal; + }else{ + struct OpenMode { + const char *z; + int mode; + } *aMode = 0; + char *zModeType = 0; + int mask = 0; + int limit = 0; + + if( nOpt==5 && memcmp("cache", zOpt, 5)==0 ){ + static struct OpenMode aCacheMode[] = { + { "shared", SQLITE_OPEN_SHAREDCACHE }, + { "private", SQLITE_OPEN_PRIVATECACHE }, + { 0, 0 } + }; + + mask = SQLITE_OPEN_SHAREDCACHE|SQLITE_OPEN_PRIVATECACHE; + aMode = aCacheMode; + limit = mask; + zModeType = "cache"; + } + if( nOpt==4 && memcmp("mode", zOpt, 4)==0 ){ + static struct OpenMode aOpenMode[] = { + { "ro", SQLITE_OPEN_READONLY }, + { "rw", SQLITE_OPEN_READWRITE }, + { "rwc", SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE }, + { 0, 0 } + }; + + mask = SQLITE_OPEN_READONLY|SQLITE_OPEN_READWRITE|SQLITE_OPEN_CREATE; + aMode = aOpenMode; + limit = mask & flags; + zModeType = "access"; + } + + if( aMode ){ + int i; + int mode = 0; + for(i=0; aMode[i].z; i++){ + const char *z = aMode[i].z; + if( nVal==sqlite3Strlen30(z) && 0==memcmp(zVal, z, nVal) ){ + mode = aMode[i].mode; + break; + } + } + if( mode==0 ){ + *pzErrMsg = sqlite3_mprintf("no such %s mode: %s", zModeType, zVal); + rc = SQLITE_ERROR; + goto parse_uri_out; + } + if( mode>limit ){ + *pzErrMsg = sqlite3_mprintf("%s mode not allowed: %s", + zModeType, zVal); + rc = SQLITE_PERM; + goto parse_uri_out; + } + flags = (flags & ~mask) | mode; + } + } + + zOpt = &zVal[nVal+1]; + } + + }else{ + zFile = sqlite3_malloc(nUri+2); + if( !zFile ) return SQLITE_NOMEM; + memcpy(zFile, zUri, nUri); + zFile[nUri] = '\0'; + zFile[nUri+1] = '\0'; + } + + *ppVfs = sqlite3_vfs_find(zVfs); + if( *ppVfs==0 ){ + *pzErrMsg = sqlite3_mprintf("no such vfs: %s", zVfs); + rc = SQLITE_ERROR; + } + parse_uri_out: + if( rc!=SQLITE_OK ){ + sqlite3_free(zFile); + zFile = 0; + } + *pFlags = flags; + *pzFile = zFile; + return rc; +} + + /* ** This routine does the work of opening a database on behalf of ** sqlite3_open() and sqlite3_open16(). The database filename "zFilename" @@ -108917,12 +109950,14 @@ SQLITE_API int sqlite3_limit(sqlite3 *db, int limitId, int newLimit){ static int openDatabase( const char *zFilename, /* Database filename UTF-8 encoded */ sqlite3 **ppDb, /* OUT: Returned database handle */ - unsigned flags, /* Operational flags */ + unsigned int flags, /* Operational flags */ const char *zVfs /* Name of the VFS to use */ ){ - sqlite3 *db; - int rc; - int isThreadsafe; + sqlite3 *db; /* Store allocated handle here */ + int rc; /* Return code */ + int isThreadsafe; /* True for threadsafe connections */ + char *zOpen = 0; /* Filename argument to pass to BtreeOpen() */ + char *zErrMsg = 0; /* Error message from sqlite3ParseUri() */ *ppDb = 0; #ifndef SQLITE_OMIT_AUTOINIT @@ -108946,7 +109981,7 @@ static int openDatabase( testcase( (1<<(flags&7))==0x02 ); /* READONLY */ testcase( (1<<(flags&7))==0x04 ); /* READWRITE */ testcase( (1<<(flags&7))==0x40 ); /* READWRITE | CREATE */ - if( ((1<<(flags&7)) & 0x46)==0 ) return SQLITE_MISUSE; + if( ((1<<(flags&7)) & 0x46)==0 ) return SQLITE_MISUSE_BKPT; if( sqlite3GlobalConfig.bCoreMutex==0 ){ isThreadsafe = 0; @@ -109027,13 +110062,6 @@ static int openDatabase( sqlite3HashInit(&db->aModule); #endif - db->pVfs = sqlite3_vfs_find(zVfs); - if( !db->pVfs ){ - rc = SQLITE_ERROR; - sqlite3Error(db, rc, "no such vfs: %s", zVfs); - goto opendb_out; - } - /* Add the default collation sequence BINARY. BINARY works for both UTF-8 ** and UTF-16, so add a version for each to avoid any unnecessary ** conversions. The only error that can occur here is a malloc() failure. @@ -109056,9 +110084,18 @@ static int openDatabase( createCollation(db, "NOCASE", SQLITE_UTF8, SQLITE_COLL_NOCASE, 0, nocaseCollatingFunc, 0); - /* Open the backend database driver */ + /* Parse the filename/URI argument. */ db->openFlags = flags; - rc = sqlite3BtreeOpen(zFilename, db, &db->aDb[0].pBt, 0, + rc = sqlite3ParseUri(zVfs, zFilename, &flags, &db->pVfs, &zOpen, &zErrMsg); + if( rc!=SQLITE_OK ){ + if( rc==SQLITE_NOMEM ) db->mallocFailed = 1; + sqlite3Error(db, rc, zErrMsg ? "%s" : 0, zErrMsg); + sqlite3_free(zErrMsg); + goto opendb_out; + } + + /* Open the backend database driver */ + rc = sqlite3BtreeOpen(db->pVfs, zOpen, db, &db->aDb[0].pBt, 0, flags | SQLITE_OPEN_MAIN_DB); if( rc!=SQLITE_OK ){ if( rc==SQLITE_IOERR_NOMEM ){ @@ -109151,6 +110188,7 @@ static int openDatabase( sqlite3_wal_autocheckpoint(db, SQLITE_DEFAULT_WAL_AUTOCHECKPOINT); opendb_out: + sqlite3_free(zOpen); if( db ){ assert( db->mutex!=0 || isThreadsafe==0 || sqlite3GlobalConfig.bFullMutex==0 ); sqlite3_mutex_leave(db->mutex); @@ -109182,7 +110220,7 @@ SQLITE_API int sqlite3_open_v2( int flags, /* Flags */ const char *zVfs /* Name of VFS module to use */ ){ - return openDatabase(filename, ppDb, flags, zVfs); + return openDatabase(filename, ppDb, (unsigned int)flags, zVfs); } #ifndef SQLITE_OMIT_UTF16 @@ -109787,12 +110825,45 @@ SQLITE_API int sqlite3_test_control(int op, ...){ break; } + /* sqlite3_test_control(SQLITE_TESTCTRL_LOCALTIME_FAULT, int onoff); + ** + ** If parameter onoff is non-zero, configure the wrappers so that all + ** subsequent calls to localtime() and variants fail. If onoff is zero, + ** undo this setting. + */ + case SQLITE_TESTCTRL_LOCALTIME_FAULT: { + sqlite3GlobalConfig.bLocaltimeFault = va_arg(ap, int); + break; + } + } va_end(ap); #endif /* SQLITE_OMIT_BUILTIN_TEST */ return rc; } +/* +** This is a utility routine, useful to VFS implementations, that checks +** to see if a database file was a URI that contained a specific query +** parameter, and if so obtains the value of the query parameter. +** +** The zFilename argument is the filename pointer passed into the xOpen() +** method of a VFS implementation. The zParam argument is the name of the +** query parameter we seek. This routine returns the value of the zParam +** parameter if it exists. If the parameter does not exist, this routine +** returns a NULL pointer. +*/ +SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *zParam){ + zFilename += sqlite3Strlen30(zFilename) + 1; + while( zFilename[0] ){ + int x = strcmp(zFilename, zParam); + zFilename += sqlite3Strlen30(zFilename) + 1; + if( x==0 ) return zFilename; + zFilename += sqlite3Strlen30(zFilename) + 1; + } + return 0; +} + /************** End of main.c ************************************************/ /************** Begin file notify.c ******************************************/ /* @@ -110422,12 +111493,6 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){ ** into a single segment. */ -#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) - -#if defined(SQLITE_ENABLE_FTS3) && !defined(SQLITE_CORE) -# define SQLITE_CORE 1 -#endif - /************** Include fts3Int.h in the middle of fts3.c ********************/ /************** Begin file fts3Int.h *****************************************/ /* @@ -110443,7 +111508,6 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){ ****************************************************************************** ** */ - #ifndef _FTSINT_H #define _FTSINT_H @@ -110451,6 +111515,16 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){ # define NDEBUG 1 #endif +/* +** FTS4 is really an extension for FTS3. It is enabled using the +** SQLITE_ENABLE_FTS3 macro. But to avoid confusion we also all +** the SQLITE_ENABLE_FTS4 macro to serve as an alisse for SQLITE_ENABLE_FTS3. +*/ +#if defined(SQLITE_ENABLE_FTS4) && !defined(SQLITE_ENABLE_FTS3) +# define SQLITE_ENABLE_FTS3 +#endif + +#ifdef SQLITE_ENABLE_FTS3 /************** Include fts3_tokenizer.h in the middle of fts3Int.h **********/ /************** Begin file fts3_tokenizer.h **********************************/ /* @@ -110749,12 +111823,35 @@ SQLITE_PRIVATE Fts3HashElem *sqlite3Fts3HashFindElem(const Fts3Hash *, const voi */ #define SizeofArray(X) ((int)(sizeof(X)/sizeof(X[0]))) + +#ifndef MIN +# define MIN(x,y) ((x)<(y)?(x):(y)) +#endif + /* ** Maximum length of a varint encoded integer. The varint format is different ** from that used by SQLite, so the maximum length is 10, not 9. */ #define FTS3_VARINT_MAX 10 +/* +** FTS4 virtual tables may maintain multiple indexes - one index of all terms +** in the document set and zero or more prefix indexes. All indexes are stored +** as one or more b+-trees in the %_segments and %_segdir tables. +** +** It is possible to determine which index a b+-tree belongs to based on the +** value stored in the "%_segdir.level" column. Given this value L, the index +** that the b+-tree belongs to is (L<<10). In other words, all b+-trees with +** level values between 0 and 1023 (inclusive) belong to index 0, all levels +** between 1024 and 2047 to index 1, and so on. +** +** It is considered impossible for an index to use more than 1024 levels. In +** theory though this may happen, but only after at least +** (FTS3_MERGE_COUNT^1024) separate flushes of the pending-terms tables. +*/ +#define FTS3_SEGDIR_MAXLEVEL 1024 +#define FTS3_SEGDIR_MAXLEVEL_STR "1024" + /* ** The testcase() macro is only used by the amalgamation. If undefined, ** make it a no-op. @@ -110794,22 +111891,43 @@ typedef unsigned char u8; /* 1-byte (or larger) unsigned integer */ typedef short int i16; /* 2-byte (or larger) signed integer */ typedef unsigned int u32; /* 4-byte unsigned integer */ typedef sqlite3_uint64 u64; /* 8-byte unsigned integer */ + /* ** Macro used to suppress compiler warnings for unused parameters. */ #define UNUSED_PARAMETER(x) (void)(x) + +/* +** Activate assert() only if SQLITE_TEST is enabled. +*/ +#if !defined(NDEBUG) && !defined(SQLITE_DEBUG) +# define NDEBUG 1 +#endif + +/* +** The TESTONLY macro is used to enclose variable declarations or +** other bits of code that are needed to support the arguments +** within testcase() and assert() macros. +*/ +#if defined(SQLITE_DEBUG) || defined(SQLITE_COVERAGE_TEST) +# define TESTONLY(X) X +#else +# define TESTONLY(X) #endif +#endif /* SQLITE_AMALGAMATION */ + typedef struct Fts3Table Fts3Table; typedef struct Fts3Cursor Fts3Cursor; typedef struct Fts3Expr Fts3Expr; typedef struct Fts3Phrase Fts3Phrase; typedef struct Fts3PhraseToken Fts3PhraseToken; +typedef struct Fts3Doclist Fts3Doclist; typedef struct Fts3SegFilter Fts3SegFilter; typedef struct Fts3DeferredToken Fts3DeferredToken; typedef struct Fts3SegReader Fts3SegReader; -typedef struct Fts3SegReaderCursor Fts3SegReaderCursor; +typedef struct Fts3MultiSegReader Fts3MultiSegReader; /* ** A connection to a fulltext index is an instance of the following @@ -110830,7 +111948,7 @@ struct Fts3Table { /* Precompiled statements used by the implementation. Each of these ** statements is run and reset within a single virtual table API call. */ - sqlite3_stmt *aStmt[24]; + sqlite3_stmt *aStmt[27]; char *zReadExprlist; char *zWriteExprlist; @@ -110838,21 +111956,43 @@ struct Fts3Table { int nNodeSize; /* Soft limit for node size */ u8 bHasStat; /* True if %_stat table exists */ u8 bHasDocsize; /* True if %_docsize table exists */ + u8 bDescIdx; /* True if doclists are in reverse order */ int nPgsz; /* Page size for host database */ char *zSegmentsTbl; /* Name of %_segments table */ sqlite3_blob *pSegments; /* Blob handle open on %_segments table */ - /* The following hash table is used to buffer pending index updates during + /* TODO: Fix the first paragraph of this comment. + ** + ** The following hash table is used to buffer pending index updates during ** transactions. Variable nPendingData estimates the memory size of the ** pending data, including hash table overhead, but not malloc overhead. ** When nPendingData exceeds nMaxPendingData, the buffer is flushed ** automatically. Variable iPrevDocid is the docid of the most recently ** inserted record. + ** + ** A single FTS4 table may have multiple full-text indexes. For each index + ** there is an entry in the aIndex[] array. Index 0 is an index of all the + ** terms that appear in the document set. Each subsequent index in aIndex[] + ** is an index of prefixes of a specific length. + */ + int nIndex; /* Size of aIndex[] */ + struct Fts3Index { + int nPrefix; /* Prefix length (0 for main terms index) */ + Fts3Hash hPending; /* Pending terms table for this index */ + } *aIndex; + int nMaxPendingData; /* Max pending data before flush to disk */ + int nPendingData; /* Current bytes of pending data */ + sqlite_int64 iPrevDocid; /* Docid of most recently inserted document */ + +#if defined(SQLITE_DEBUG) + /* State variables used for validating that the transaction control + ** methods of the virtual table are called at appropriate times. These + ** values do not contribution to the FTS computation; they are used for + ** verifying the SQLite core. */ - int nMaxPendingData; - int nPendingData; - sqlite_int64 iPrevDocid; - Fts3Hash pendingTerms; + int inTransaction; /* True after xBegin but before xCommit/xRollback */ + int mxSavepoint; /* Largest valid xSavepoint integer */ +#endif }; /* @@ -110873,8 +112013,10 @@ struct Fts3Cursor { char *pNextId; /* Pointer into the body of aDoclist */ char *aDoclist; /* List of docids for full-text queries */ int nDoclist; /* Size of buffer at aDoclist */ + u8 bDesc; /* True to sort in descending order */ int eEvalmode; /* An FTS3_EVAL_XX constant */ int nRowAvg; /* Average size of database rows, in pages */ + sqlite3_int64 nDoc; /* Documents in table */ int isMatchinfoNeeded; /* True when aMatchinfo[] needs filling in */ u32 *aMatchinfo; /* Information about most recent match */ @@ -110905,47 +112047,70 @@ struct Fts3Cursor { #define FTS3_DOCID_SEARCH 1 /* Lookup by rowid on %_content table */ #define FTS3_FULLTEXT_SEARCH 2 /* Full-text index search */ + +struct Fts3Doclist { + char *aAll; /* Array containing doclist (or NULL) */ + int nAll; /* Size of a[] in bytes */ + char *pNextDocid; /* Pointer to next docid */ + + sqlite3_int64 iDocid; /* Current docid (if pList!=0) */ + int bFreeList; /* True if pList should be sqlite3_free()d */ + char *pList; /* Pointer to position list following iDocid */ + int nList; /* Length of position list */ +} doclist; + /* ** A "phrase" is a sequence of one or more tokens that must match in ** sequence. A single token is the base case and the most common case. ** For a sequence of tokens contained in double-quotes (i.e. "one two three") ** nToken will be the number of tokens in the string. -** -** The nDocMatch and nMatch variables contain data that may be used by the -** matchinfo() function. They are populated when the full-text index is -** queried for hits on the phrase. If one or more tokens in the phrase -** are deferred, the nDocMatch and nMatch variables are populated based -** on the assumption that the */ struct Fts3PhraseToken { char *z; /* Text of the token */ int n; /* Number of bytes in buffer z */ int isPrefix; /* True if token ends with a "*" character */ - int bFulltext; /* True if full-text index was used */ - Fts3SegReaderCursor *pSegcsr; /* Segment-reader for this token */ + + /* Variables above this point are populated when the expression is + ** parsed (by code in fts3_expr.c). Below this point the variables are + ** used when evaluating the expression. */ Fts3DeferredToken *pDeferred; /* Deferred token object for this token */ + Fts3MultiSegReader *pSegcsr; /* Segment-reader for this token */ }; struct Fts3Phrase { - /* Variables populated by fts3_expr.c when parsing a MATCH expression */ + /* Cache of doclist for this phrase. */ + Fts3Doclist doclist; + int bIncr; /* True if doclist is loaded incrementally */ + int iDoclistToken; + + /* Variables below this point are populated by fts3_expr.c when parsing + ** a MATCH expression. Everything above is part of the evaluation phase. + */ int nToken; /* Number of tokens in the phrase */ int iColumn; /* Index of column this phrase must match */ - int isNot; /* Phrase prefixed by unary not (-) operator */ Fts3PhraseToken aToken[1]; /* One entry for each token in the phrase */ }; /* ** A tree of these objects forms the RHS of a MATCH operator. ** -** If Fts3Expr.eType is either FTSQUERY_NEAR or FTSQUERY_PHRASE and isLoaded -** is true, then aDoclist points to a malloced buffer, size nDoclist bytes, -** containing the results of the NEAR or phrase query in FTS3 doclist -** format. As usual, the initial "Length" field found in doclists stored -** on disk is omitted from this buffer. +** If Fts3Expr.eType is FTSQUERY_PHRASE and isLoaded is true, then aDoclist +** points to a malloced buffer, size nDoclist bytes, containing the results +** of this phrase query in FTS3 doclist format. As usual, the initial +** "Length" field found in doclists stored on disk is omitted from this +** buffer. +** +** Variable aMI is used only for FTSQUERY_NEAR nodes to store the global +** matchinfo data. If it is not NULL, it points to an array of size nCol*3, +** where nCol is the number of columns in the queried FTS table. The array +** is populated as follows: +** +** aMI[iCol*3 + 0] = Undefined +** aMI[iCol*3 + 1] = Number of occurrences +** aMI[iCol*3 + 2] = Number of rows containing at least one instance ** -** Variable pCurrent always points to the start of a docid field within -** aDoclist. Since the doclist is usually scanned in docid order, this can -** be used to accelerate seeking to the required docid within the doclist. +** The aMI array is allocated using sqlite3_malloc(). It should be freed +** when the expression node is. */ struct Fts3Expr { int eType; /* One of the FTSQUERY_XXX values defined below */ @@ -110955,12 +112120,13 @@ struct Fts3Expr { Fts3Expr *pRight; /* Right operand */ Fts3Phrase *pPhrase; /* Valid if eType==FTSQUERY_PHRASE */ - int isLoaded; /* True if aDoclist/nDoclist are initialized. */ - char *aDoclist; /* Buffer containing doclist */ - int nDoclist; /* Size of aDoclist in bytes */ + /* The following are used by the fts3_eval.c module. */ + sqlite3_int64 iDocid; /* Current docid */ + u8 bEof; /* True this expression is at EOF already */ + u8 bStart; /* True if iDocid is valid */ + u8 bDeferred; /* True if this expression is entirely deferred */ - sqlite3_int64 iCurrent; - char *pCurrent; + u32 *aMI; }; /* @@ -110988,12 +112154,12 @@ SQLITE_PRIVATE void sqlite3Fts3PendingTermsClear(Fts3Table *); SQLITE_PRIVATE int sqlite3Fts3Optimize(Fts3Table *); SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(int, sqlite3_int64, sqlite3_int64, sqlite3_int64, const char *, int, Fts3SegReader**); -SQLITE_PRIVATE int sqlite3Fts3SegReaderPending(Fts3Table*,const char*,int,int,Fts3SegReader**); +SQLITE_PRIVATE int sqlite3Fts3SegReaderPending( + Fts3Table*,int,const char*,int,int,Fts3SegReader**); SQLITE_PRIVATE void sqlite3Fts3SegReaderFree(Fts3SegReader *); -SQLITE_PRIVATE int sqlite3Fts3SegReaderCost(Fts3Cursor *, Fts3SegReader *, int *); -SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(Fts3Table*, int, sqlite3_stmt **); +SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(Fts3Table*, int, int, sqlite3_stmt **); SQLITE_PRIVATE int sqlite3Fts3ReadLock(Fts3Table *); -SQLITE_PRIVATE int sqlite3Fts3ReadBlock(Fts3Table*, sqlite3_int64, char **, int*); +SQLITE_PRIVATE int sqlite3Fts3ReadBlock(Fts3Table*, sqlite3_int64, char **, int*, int*); SQLITE_PRIVATE int sqlite3Fts3SelectDoctotal(Fts3Table *, sqlite3_stmt **); SQLITE_PRIVATE int sqlite3Fts3SelectDocsize(Fts3Table *, sqlite3_int64, sqlite3_stmt **); @@ -111002,17 +112168,18 @@ SQLITE_PRIVATE void sqlite3Fts3FreeDeferredTokens(Fts3Cursor *); SQLITE_PRIVATE int sqlite3Fts3DeferToken(Fts3Cursor *, Fts3PhraseToken *, int); SQLITE_PRIVATE int sqlite3Fts3CacheDeferredDoclists(Fts3Cursor *); SQLITE_PRIVATE void sqlite3Fts3FreeDeferredDoclists(Fts3Cursor *); -SQLITE_PRIVATE char *sqlite3Fts3DeferredDoclist(Fts3DeferredToken *, int *); SQLITE_PRIVATE void sqlite3Fts3SegmentsClose(Fts3Table *); -#define FTS3_SEGCURSOR_PENDING -1 -#define FTS3_SEGCURSOR_ALL -2 +/* Special values interpreted by sqlite3SegReaderCursor() */ +#define FTS3_SEGCURSOR_PENDING -1 +#define FTS3_SEGCURSOR_ALL -2 + +SQLITE_PRIVATE int sqlite3Fts3SegReaderStart(Fts3Table*, Fts3MultiSegReader*, Fts3SegFilter*); +SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(Fts3Table *, Fts3MultiSegReader *); +SQLITE_PRIVATE void sqlite3Fts3SegReaderFinish(Fts3MultiSegReader *); -SQLITE_PRIVATE int sqlite3Fts3SegReaderStart(Fts3Table*, Fts3SegReaderCursor*, Fts3SegFilter*); -SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(Fts3Table *, Fts3SegReaderCursor *); -SQLITE_PRIVATE void sqlite3Fts3SegReaderFinish(Fts3SegReaderCursor *); SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor( - Fts3Table *, int, const char *, int, int, int, Fts3SegReaderCursor *); + Fts3Table *, int, int, const char *, int, int, int, Fts3MultiSegReader *); /* Flags allowed as part of the 4th argument to SegmentReaderIterate() */ #define FTS3_SEGMENT_REQUIRE_POS 0x00000001 @@ -111029,7 +112196,7 @@ struct Fts3SegFilter { int flags; }; -struct Fts3SegReaderCursor { +struct Fts3MultiSegReader { /* Used internally by sqlite3Fts3SegReaderXXX() calls */ Fts3SegReader **apSegment; /* Array of Fts3SegReader objects */ int nSegment; /* Size of apSegment array */ @@ -111038,8 +112205,12 @@ struct Fts3SegReaderCursor { char *aBuffer; /* Buffer to merge doclists in */ int nBuffer; /* Allocated size of aBuffer[] in bytes */ - /* Cost of running this iterator. Used by fts3.c only. */ - int nCost; + int iColFilter; /* If >=0, filter for this column */ + int bRestart; + + /* Used by fts3.c only. */ + int nCost; /* Cost of running iterator */ + int bLookup; /* True if a lookup of a single entry. */ /* Output values. Valid only after Fts3SegReaderStep() returns SQLITE_ROW. */ char *zTerm; /* Pointer to term buffer */ @@ -111054,11 +112225,9 @@ SQLITE_PRIVATE int sqlite3Fts3GetVarint(const char *, sqlite_int64 *); SQLITE_PRIVATE int sqlite3Fts3GetVarint32(const char *, int *); SQLITE_PRIVATE int sqlite3Fts3VarintLen(sqlite3_uint64); SQLITE_PRIVATE void sqlite3Fts3Dequote(char *); +SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(int,char*,int,char**,sqlite3_int64*,int*,u8*); -SQLITE_PRIVATE char *sqlite3Fts3FindPositions(Fts3Expr *, sqlite3_int64, int); -SQLITE_PRIVATE int sqlite3Fts3ExprLoadDoclist(Fts3Cursor *, Fts3Expr *); -SQLITE_PRIVATE int sqlite3Fts3ExprLoadFtDoclist(Fts3Cursor *, Fts3Expr *, char **, int *); -SQLITE_PRIVATE int sqlite3Fts3ExprNearTrim(Fts3Expr *, Fts3Expr *, int); +SQLITE_PRIVATE int sqlite3Fts3EvalPhraseStats(Fts3Cursor *, Fts3Expr *, u32 *); /* fts3_tokenizer.c */ SQLITE_PRIVATE const char *sqlite3Fts3NextToken(const char *, int *); @@ -111082,15 +112251,45 @@ SQLITE_PRIVATE int sqlite3Fts3ExprParse(sqlite3_tokenizer *, SQLITE_PRIVATE void sqlite3Fts3ExprFree(Fts3Expr *); #ifdef SQLITE_TEST SQLITE_PRIVATE int sqlite3Fts3ExprInitTestInterface(sqlite3 *db); +SQLITE_PRIVATE int sqlite3Fts3InitTerm(sqlite3 *db); #endif /* fts3_aux.c */ SQLITE_PRIVATE int sqlite3Fts3InitAux(sqlite3 *db); +SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor( + Fts3Cursor *pCsr, /* Virtual table cursor handle */ + const char *zTerm, /* Term to query for */ + int nTerm, /* Size of zTerm in bytes */ + int isPrefix, /* True for a prefix search */ + Fts3MultiSegReader **ppSegcsr /* OUT: Allocated seg-reader cursor */ +); + +SQLITE_PRIVATE void sqlite3Fts3EvalPhraseCleanup(Fts3Phrase *); + +SQLITE_PRIVATE int sqlite3Fts3EvalStart(Fts3Cursor *, Fts3Expr *, int); +SQLITE_PRIVATE int sqlite3Fts3EvalNext(Fts3Cursor *pCsr); + +SQLITE_PRIVATE int sqlite3Fts3MsrIncrStart( + Fts3Table*, Fts3MultiSegReader*, int, const char*, int); +SQLITE_PRIVATE int sqlite3Fts3MsrIncrNext( + Fts3Table *, Fts3MultiSegReader *, sqlite3_int64 *, char **, int *); +SQLITE_PRIVATE char *sqlite3Fts3EvalPhrasePoslist(Fts3Cursor *, Fts3Expr *, int iCol); +SQLITE_PRIVATE int sqlite3Fts3MsrOvfl(Fts3Cursor *, Fts3MultiSegReader *, int *); +SQLITE_PRIVATE int sqlite3Fts3MsrIncrRestart(Fts3MultiSegReader *pCsr); + +SQLITE_PRIVATE int sqlite3Fts3DeferredTokenList(Fts3DeferredToken *, char **, int *); + +#endif /* SQLITE_ENABLE_FTS3 */ #endif /* _FTSINT_H */ /************** End of fts3Int.h *********************************************/ /************** Continuing where we left off in fts3.c ***********************/ +#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) + +#if defined(SQLITE_ENABLE_FTS3) && !defined(SQLITE_CORE) +# define SQLITE_CORE 1 +#endif #ifndef SQLITE_CORE @@ -111204,17 +112403,31 @@ static void fts3GetDeltaVarint(char **pp, sqlite3_int64 *pVal){ } /* -** As long as *pp has not reached its end (pEnd), then do the same -** as fts3GetDeltaVarint(): read a single varint and add it to *pVal. -** But if we have reached the end of the varint, just set *pp=0 and -** leave *pVal unchanged. +** When this function is called, *pp points to the first byte following a +** varint that is part of a doclist (or position-list, or any other list +** of varints). This function moves *pp to point to the start of that varint, +** and sets *pVal by the varint value. +** +** Argument pStart points to the first byte of the doclist that the +** varint is part of. */ -static void fts3GetDeltaVarint2(char **pp, char *pEnd, sqlite3_int64 *pVal){ - if( *pp>=pEnd ){ - *pp = 0; - }else{ - fts3GetDeltaVarint(pp, pVal); - } +static void fts3GetReverseVarint( + char **pp, + char *pStart, + sqlite3_int64 *pVal +){ + sqlite3_int64 iVal; + char *p = *pp; + + /* Pointer p now points at the first byte past the varint we are + ** interested in. So, unless the doclist is corrupt, the 0x80 bit is + ** clear on character p[-1]. */ + for(p = (*pp)-2; p>=pStart && *p&0x80; p--); + p++; + *pp = p; + + sqlite3Fts3GetVarint(p, &iVal); + *pVal = iVal; } /* @@ -111308,6 +112521,8 @@ static void fts3DeclareVtab(int *pRc, Fts3Table *p){ char *zSql; /* SQL statement passed to declare_vtab() */ char *zCols; /* List of user defined columns */ + sqlite3_vtab_config(p->db, SQLITE_VTAB_CONSTRAINT_SUPPORT, 1); + /* Create a list of user columns for the virtual table */ zCols = sqlite3_mprintf("%Q, ", p->azColumn[0]); for(i=1; zCols && inColumn; i++){ @@ -111413,6 +112628,9 @@ static void fts3DatabasePageSize(int *pRc, Fts3Table *p){ sqlite3_step(pStmt); p->nPgsz = sqlite3_column_int(pStmt, 0); rc = sqlite3_finalize(pStmt); + }else if( rc==SQLITE_AUTH ){ + p->nPgsz = 1024; + rc = SQLITE_OK; } } assert( p->nPgsz>0 || rc!=SQLITE_OK ); @@ -111587,6 +112805,58 @@ static char *fts3WriteExprList(Fts3Table *p, const char *zFunc, int *pRc){ return zRet; } +static int fts3GobbleInt(const char **pp, int *pnOut){ + const char *p = *pp; + int nInt = 0; + for(p=*pp; p[0]>='0' && p[0]<='9'; p++){ + nInt = nInt * 10 + (p[0] - '0'); + } + if( p==*pp ) return SQLITE_ERROR; + *pnOut = nInt; + *pp = p; + return SQLITE_OK; +} + + +static int fts3PrefixParameter( + const char *zParam, /* ABC in prefix=ABC parameter to parse */ + int *pnIndex, /* OUT: size of *apIndex[] array */ + struct Fts3Index **apIndex, /* OUT: Array of indexes for this table */ + struct Fts3Index **apFree /* OUT: Free this with sqlite3_free() */ +){ + struct Fts3Index *aIndex; + int nIndex = 1; + + if( zParam && zParam[0] ){ + const char *p; + nIndex++; + for(p=zParam; *p; p++){ + if( *p==',' ) nIndex++; + } + } + + aIndex = sqlite3_malloc(sizeof(struct Fts3Index) * nIndex); + *apIndex = *apFree = aIndex; + *pnIndex = nIndex; + if( !aIndex ){ + return SQLITE_NOMEM; + } + + memset(aIndex, 0, sizeof(struct Fts3Index) * nIndex); + if( zParam ){ + const char *p = zParam; + int i; + for(i=1; i MATCHINFO */ + { "prefix", 6, 0 }, /* 1 -> PREFIX */ + { "compress", 8, 0 }, /* 2 -> COMPRESS */ + { "uncompress", 10, 0 }, /* 3 -> UNCOMPRESS */ + { "order", 5, 0 } /* 4 -> ORDER */ + }; + + int iOpt; if( !zVal ){ rc = SQLITE_NOMEM; - goto fts3_init_out; - } - if( nKey==9 && 0==sqlite3_strnicmp(z, "matchinfo", 9) ){ - if( strlen(zVal)==4 && 0==sqlite3_strnicmp(zVal, "fts3", 4) ){ - bNoDocsize = 1; - }else{ - *pzErr = sqlite3_mprintf("unrecognized matchinfo: %s", zVal); + }else{ + for(iOpt=0; iOptnOpt && !sqlite3_strnicmp(z, pOp->zOpt, pOp->nOpt) ){ + break; + } + } + if( iOpt==SizeofArray(aFts4Opt) ){ + *pzErr = sqlite3_mprintf("unrecognized parameter: %s", z); rc = SQLITE_ERROR; + }else{ + switch( iOpt ){ + case 0: /* MATCHINFO */ + if( strlen(zVal)!=4 || sqlite3_strnicmp(zVal, "fts3", 4) ){ + *pzErr = sqlite3_mprintf("unrecognized matchinfo: %s", zVal); + rc = SQLITE_ERROR; + } + bNoDocsize = 1; + break; + + case 1: /* PREFIX */ + sqlite3_free(zPrefix); + zPrefix = zVal; + zVal = 0; + break; + + case 2: /* COMPRESS */ + sqlite3_free(zCompress); + zCompress = zVal; + zVal = 0; + break; + + case 3: /* UNCOMPRESS */ + sqlite3_free(zUncompress); + zUncompress = zVal; + zVal = 0; + break; + + case 4: /* ORDER */ + if( (strlen(zVal)!=3 || sqlite3_strnicmp(zVal, "asc", 3)) + && (strlen(zVal)!=4 || sqlite3_strnicmp(zVal, "desc", 3)) + ){ + *pzErr = sqlite3_mprintf("unrecognized order: %s", zVal); + rc = SQLITE_ERROR; + } + bDescIdx = (zVal[0]=='d' || zVal[0]=='D'); + break; + } } - }else if( nKey==8 && 0==sqlite3_strnicmp(z, "compress", 8) ){ - zCompress = zVal; - zVal = 0; - }else if( nKey==10 && 0==sqlite3_strnicmp(z, "uncompress", 10) ){ - zUncompress = zVal; - zVal = 0; - }else{ - *pzErr = sqlite3_mprintf("unrecognized parameter: %s", z); - rc = SQLITE_ERROR; + sqlite3_free(zVal); } - sqlite3_free(zVal); } /* Otherwise, the argument is a column name. */ @@ -111710,10 +113031,17 @@ static int fts3InitVtab( } assert( pTokenizer ); + rc = fts3PrefixParameter(zPrefix, &nIndex, &aIndex, &aFree); + if( rc==SQLITE_ERROR ){ + assert( zPrefix ); + *pzErr = sqlite3_mprintf("error parsing prefix parameter: %s", zPrefix); + } + if( rc!=SQLITE_OK ) goto fts3_init_out; /* Allocate and populate the Fts3Table structure. */ - nByte = sizeof(Fts3Table) + /* Fts3Table */ + nByte = sizeof(Fts3Table) + /* Fts3Table */ nCol * sizeof(char *) + /* azColumn */ + nIndex * sizeof(struct Fts3Index) + /* aIndex */ nName + /* zName */ nDb + /* zDb */ nString; /* Space for azColumn strings */ @@ -111728,14 +113056,22 @@ static int fts3InitVtab( p->nPendingData = 0; p->azColumn = (char **)&p[1]; p->pTokenizer = pTokenizer; - p->nNodeSize = 1000; p->nMaxPendingData = FTS3_MAX_PENDING_DATA; p->bHasDocsize = (isFts4 && bNoDocsize==0); p->bHasStat = isFts4; - fts3HashInit(&p->pendingTerms, FTS3_HASH_STRING, 1); + p->bDescIdx = bDescIdx; + TESTONLY( p->inTransaction = -1 ); + TESTONLY( p->mxSavepoint = -1 ); + + p->aIndex = (struct Fts3Index *)&p->azColumn[nCol]; + memcpy(p->aIndex, aIndex, sizeof(struct Fts3Index) * nIndex); + p->nIndex = nIndex; + for(i=0; iaIndex[i].hPending, FTS3_HASH_STRING, 1); + } /* Fill in the zName and zDb fields of the vtab structure. */ - zCsr = (char *)&p->azColumn[nCol]; + zCsr = (char *)&p->aIndex[nIndex]; p->zName = zCsr; memcpy(zCsr, argv[2], nName); zCsr += nName; @@ -111746,7 +113082,7 @@ static int fts3InitVtab( /* Fill in the azColumn array */ for(iCol=0; iColnNodeSize = p->nPgsz-35; /* Declare the table schema to SQLite. */ fts3DeclareVtab(&rc, p); fts3_init_out: + sqlite3_free(zPrefix); + sqlite3_free(aFree); sqlite3_free(zCompress); sqlite3_free(zUncompress); sqlite3_free((void *)aCol); @@ -111792,6 +113129,7 @@ static int fts3InitVtab( pTokenizer->pModule->xDestroy(pTokenizer); } }else{ + assert( p->pSegments==0 ); *ppVTab = &p->base; } return rc; @@ -111877,6 +113215,23 @@ static int fts3BestIndexMethod(sqlite3_vtab *pVTab, sqlite3_index_info *pInfo){ pInfo->aConstraintUsage[iCons].argvIndex = 1; pInfo->aConstraintUsage[iCons].omit = 1; } + + /* Regardless of the strategy selected, FTS can deliver rows in rowid (or + ** docid) order. Both ascending and descending are possible. + */ + if( pInfo->nOrderBy==1 ){ + struct sqlite3_index_orderby *pOrder = &pInfo->aOrderBy[0]; + if( pOrder->iColumn<0 || pOrder->iColumn==p->nColumn+1 ){ + if( pOrder->desc ){ + pInfo->idxStr = "DESC"; + }else{ + pInfo->idxStr = "ASC"; + } + pInfo->orderByConsumed = 1; + } + } + + assert( p->pSegments==0 ); return SQLITE_OK; } @@ -111912,6 +113267,7 @@ static int fts3CloseMethod(sqlite3_vtab_cursor *pCursor){ sqlite3Fts3FreeDeferredTokens(pCsr); sqlite3_free(pCsr->aDoclist); sqlite3_free(pCsr->aMatchinfo); + assert( ((Fts3Table *)pCsr->base.pVtab)->pSegments==0 ); sqlite3_free(pCsr); return SQLITE_OK; } @@ -111923,8 +113279,8 @@ static int fts3CloseMethod(sqlite3_vtab_cursor *pCursor){ */ static int fts3CursorSeek(sqlite3_context *pContext, Fts3Cursor *pCsr){ if( pCsr->isRequireSeek ){ - pCsr->isRequireSeek = 0; sqlite3_bind_int64(pCsr->pStmt, 1, pCsr->iPrevId); + pCsr->isRequireSeek = 0; if( SQLITE_ROW==sqlite3_step(pCsr->pStmt) ){ return SQLITE_OK; }else{ @@ -111934,7 +113290,7 @@ static int fts3CursorSeek(sqlite3_context *pContext, Fts3Cursor *pCsr){ ** table is missing a row that is present in the full-text index. ** The data structures are corrupt. */ - rc = SQLITE_CORRUPT; + rc = SQLITE_CORRUPT_VTAB; } pCsr->isEof = 1; if( pContext ){ @@ -111994,7 +113350,7 @@ static int fts3ScanInteriorNode( zCsr += sqlite3Fts3GetVarint(zCsr, &iChild); zCsr += sqlite3Fts3GetVarint(zCsr, &iChild); if( zCsr>zEnd ){ - return SQLITE_CORRUPT; + return SQLITE_CORRUPT_VTAB; } while( zCsrzEnd ){ - rc = SQLITE_CORRUPT; + rc = SQLITE_CORRUPT_VTAB; goto finish_scan; } if( nPrefix+nSuffix>nAlloc ){ @@ -112105,7 +113461,7 @@ static int fts3SelectLeaf( int nBlob; /* Size of zBlob in bytes */ if( piLeaf && piLeaf2 && (*piLeaf!=*piLeaf2) ){ - rc = sqlite3Fts3ReadBlock(p, *piLeaf, &zBlob, &nBlob); + rc = sqlite3Fts3ReadBlock(p, *piLeaf, &zBlob, &nBlob, 0); if( rc==SQLITE_OK ){ rc = fts3SelectLeaf(p, zTerm, nTerm, zBlob, nBlob, piLeaf, 0); } @@ -112115,7 +113471,7 @@ static int fts3SelectLeaf( } if( rc==SQLITE_OK ){ - rc = sqlite3Fts3ReadBlock(p, piLeaf ? *piLeaf : *piLeaf2, &zBlob, &nBlob); + rc = sqlite3Fts3ReadBlock(p, piLeaf?*piLeaf:*piLeaf2, &zBlob, &nBlob, 0); } if( rc==SQLITE_OK ){ rc = fts3SelectLeaf(p, zTerm, nTerm, zBlob, nBlob, piLeaf, piLeaf2); @@ -112491,7 +113847,19 @@ static int fts3PoslistPhraseMerge( } /* -** Merge two position-lists as required by the NEAR operator. +** Merge two position-lists as required by the NEAR operator. The argument +** position lists correspond to the left and right phrases of an expression +** like: +** +** "phrase 1" NEAR "phrase number 2" +** +** Position list *pp1 corresponds to the left-hand side of the NEAR +** expression and *pp2 to the right. As usual, the indexes in the position +** lists are the offsets of the last token in each phrase (tokens "1" and "2" +** in the example above). +** +** The output position list - written to *pp - is a copy of *pp2 with those +** entries that are not sufficiently NEAR entries in *pp1 removed. */ static int fts3PoslistNearMerge( char **pp, /* Output buffer */ @@ -112504,226 +113872,181 @@ static int fts3PoslistNearMerge( char *p1 = *pp1; char *p2 = *pp2; - if( !pp ){ - if( fts3PoslistPhraseMerge(0, nRight, 0, 0, pp1, pp2) ) return 1; - *pp1 = p1; - *pp2 = p2; - return fts3PoslistPhraseMerge(0, nLeft, 0, 0, pp2, pp1); + char *pTmp1 = aTmp; + char *pTmp2; + char *aTmp2; + int res = 1; + + fts3PoslistPhraseMerge(&pTmp1, nRight, 0, 0, pp1, pp2); + aTmp2 = pTmp2 = pTmp1; + *pp1 = p1; + *pp2 = p2; + fts3PoslistPhraseMerge(&pTmp2, nLeft, 1, 0, pp2, pp1); + if( pTmp1!=aTmp && pTmp2!=aTmp2 ){ + fts3PoslistMerge(pp, &aTmp, &aTmp2); + }else if( pTmp1!=aTmp ){ + fts3PoslistCopy(pp, &aTmp); + }else if( pTmp2!=aTmp2 ){ + fts3PoslistCopy(pp, &aTmp2); + }else{ + res = 0; + } + + return res; +} + +/* +** A pointer to an instance of this structure is used as the context +** argument to sqlite3Fts3SegReaderIterate() +*/ +typedef struct TermSelect TermSelect; +struct TermSelect { + int isReqPos; + char *aaOutput[16]; /* Malloc'd output buffer */ + int anOutput[16]; /* Size of output in bytes */ +}; + + +static void fts3GetDeltaVarint3( + char **pp, + char *pEnd, + int bDescIdx, + sqlite3_int64 *pVal +){ + if( *pp>=pEnd ){ + *pp = 0; }else{ - char *pTmp1 = aTmp; - char *pTmp2; - char *aTmp2; - int res = 1; - - fts3PoslistPhraseMerge(&pTmp1, nRight, 0, 0, pp1, pp2); - aTmp2 = pTmp2 = pTmp1; - *pp1 = p1; - *pp2 = p2; - fts3PoslistPhraseMerge(&pTmp2, nLeft, 1, 0, pp2, pp1); - if( pTmp1!=aTmp && pTmp2!=aTmp2 ){ - fts3PoslistMerge(pp, &aTmp, &aTmp2); - }else if( pTmp1!=aTmp ){ - fts3PoslistCopy(pp, &aTmp); - }else if( pTmp2!=aTmp2 ){ - fts3PoslistCopy(pp, &aTmp2); + sqlite3_int64 iVal; + *pp += sqlite3Fts3GetVarint(*pp, &iVal); + if( bDescIdx ){ + *pVal -= iVal; }else{ - res = 0; + *pVal += iVal; } + } +} - return res; +static void fts3PutDeltaVarint3( + char **pp, /* IN/OUT: Output pointer */ + int bDescIdx, /* True for descending docids */ + sqlite3_int64 *piPrev, /* IN/OUT: Previous value written to list */ + int *pbFirst, /* IN/OUT: True after first int written */ + sqlite3_int64 iVal /* Write this value to the list */ +){ + sqlite3_int64 iWrite; + if( bDescIdx==0 || *pbFirst==0 ){ + iWrite = iVal - *piPrev; + }else{ + iWrite = *piPrev - iVal; } + assert( *pbFirst || *piPrev==0 ); + assert( *pbFirst==0 || iWrite>0 ); + *pp += sqlite3Fts3PutVarint(*pp, iWrite); + *piPrev = iVal; + *pbFirst = 1; } -/* -** Values that may be used as the first parameter to fts3DoclistMerge(). -*/ -#define MERGE_NOT 2 /* D + D -> D */ -#define MERGE_AND 3 /* D + D -> D */ -#define MERGE_OR 4 /* D + D -> D */ -#define MERGE_POS_OR 5 /* P + P -> P */ -#define MERGE_PHRASE 6 /* P + P -> D */ -#define MERGE_POS_PHRASE 7 /* P + P -> P */ -#define MERGE_NEAR 8 /* P + P -> D */ -#define MERGE_POS_NEAR 9 /* P + P -> P */ +#define COMPARE_DOCID(i1, i2) ((bDescIdx?-1:1) * (i1-i2)) -/* -** Merge the two doclists passed in buffer a1 (size n1 bytes) and a2 -** (size n2 bytes). The output is written to pre-allocated buffer aBuffer, -** which is guaranteed to be large enough to hold the results. The number -** of bytes written to aBuffer is stored in *pnBuffer before returning. -** -** If successful, SQLITE_OK is returned. Otherwise, if a malloc error -** occurs while allocating a temporary buffer as part of the merge operation, -** SQLITE_NOMEM is returned. -*/ -static int fts3DoclistMerge( - int mergetype, /* One of the MERGE_XXX constants */ - int nParam1, /* Used by MERGE_NEAR and MERGE_POS_NEAR */ - int nParam2, /* Used by MERGE_NEAR and MERGE_POS_NEAR */ - char *aBuffer, /* Pre-allocated output buffer */ - int *pnBuffer, /* OUT: Bytes written to aBuffer */ - char *a1, /* Buffer containing first doclist */ - int n1, /* Size of buffer a1 */ - char *a2, /* Buffer containing second doclist */ - int n2, /* Size of buffer a2 */ - int *pnDoc /* OUT: Number of docids in output */ +static int fts3DoclistOrMerge( + int bDescIdx, /* True if arguments are desc */ + char *a1, int n1, /* First doclist */ + char *a2, int n2, /* Second doclist */ + char **paOut, int *pnOut /* OUT: Malloc'd doclist */ ){ sqlite3_int64 i1 = 0; sqlite3_int64 i2 = 0; sqlite3_int64 iPrev = 0; - - char *p = aBuffer; - char *p1 = a1; - char *p2 = a2; char *pEnd1 = &a1[n1]; char *pEnd2 = &a2[n2]; - int nDoc = 0; - - assert( mergetype==MERGE_OR || mergetype==MERGE_POS_OR - || mergetype==MERGE_AND || mergetype==MERGE_NOT - || mergetype==MERGE_PHRASE || mergetype==MERGE_POS_PHRASE - || mergetype==MERGE_NEAR || mergetype==MERGE_POS_NEAR - ); - - if( !aBuffer ){ - *pnBuffer = 0; - return SQLITE_NOMEM; - } - - /* Read the first docid from each doclist */ - fts3GetDeltaVarint2(&p1, pEnd1, &i1); - fts3GetDeltaVarint2(&p2, pEnd2, &i2); - - switch( mergetype ){ - case MERGE_OR: - case MERGE_POS_OR: - while( p1 || p2 ){ - if( p2 && p1 && i1==i2 ){ - fts3PutDeltaVarint(&p, &iPrev, i1); - if( mergetype==MERGE_POS_OR ) fts3PoslistMerge(&p, &p1, &p2); - fts3GetDeltaVarint2(&p1, pEnd1, &i1); - fts3GetDeltaVarint2(&p2, pEnd2, &i2); - }else if( !p2 || (p1 && i10 ); + + p = aOut; + fts3GetDeltaVarint3(&p1, pEnd1, 0, &i1); + fts3GetDeltaVarint3(&p2, pEnd2, 0, &i2); + + while( p1 && p2 ){ + sqlite3_int64 iDiff = COMPARE_DOCID(i1, i2); + if( iDiff==0 ){ + char *pSave = p; + sqlite3_int64 iPrevSave = iPrev; + int bFirstOutSave = bFirstOut; - fts3GetDeltaVarint2(&p1, pEnd1, &i1); - fts3GetDeltaVarint2(&p2, pEnd2, &i2); - }else if( i1isReqPos ? MERGE_POS_OR : MERGE_OR); +static int fts3TermSelectMerge(Fts3Table *p, TermSelect *pTS){ char *aOut = 0; int nOut = 0; int i; @@ -112750,15 +114072,17 @@ static int fts3TermSelectMerge(TermSelect *pTS){ nOut = pTS->anOutput[i]; pTS->aaOutput[i] = 0; }else{ - int nNew = nOut + pTS->anOutput[i]; - char *aNew = sqlite3_malloc(nNew); - if( !aNew ){ + int nNew; + char *aNew; + + int rc = fts3DoclistOrMerge(p->bDescIdx, + pTS->aaOutput[i], pTS->anOutput[i], aOut, nOut, &aNew, &nNew + ); + if( rc!=SQLITE_OK ){ sqlite3_free(aOut); - return SQLITE_NOMEM; + return rc; } - fts3DoclistMerge(mergetype, 0, 0, - aNew, &nNew, pTS->aaOutput[i], pTS->anOutput[i], aOut, nOut, 0 - ); + sqlite3_free(pTS->aaOutput[i]); sqlite3_free(aOut); pTS->aaOutput[i] = 0; @@ -112794,9 +114118,7 @@ static int fts3TermSelectCb( if( pTS->aaOutput[0]==0 ){ /* If this is the first term selected, copy the doclist to the output - ** buffer using memcpy(). TODO: Add a way to transfer control of the - ** aDoclist buffer from the caller so as to avoid the memcpy(). - */ + ** buffer using memcpy(). */ pTS->aaOutput[0] = sqlite3_malloc(nDoclist); pTS->anOutput[0] = nDoclist; if( pTS->aaOutput[0] ){ @@ -112805,126 +114127,100 @@ static int fts3TermSelectCb( return SQLITE_NOMEM; } }else{ - int mergetype = (pTS->isReqPos ? MERGE_POS_OR : MERGE_OR); char *aMerge = aDoclist; int nMerge = nDoclist; int iOut; for(iOut=0; iOutaaOutput); iOut++){ - char *aNew; - int nNew; if( pTS->aaOutput[iOut]==0 ){ assert( iOut>0 ); pTS->aaOutput[iOut] = aMerge; pTS->anOutput[iOut] = nMerge; break; - } + }else{ + char *aNew; + int nNew; - nNew = nMerge + pTS->anOutput[iOut]; - aNew = sqlite3_malloc(nNew); - if( !aNew ){ - if( aMerge!=aDoclist ){ - sqlite3_free(aMerge); + int rc = fts3DoclistOrMerge(p->bDescIdx, aMerge, nMerge, + pTS->aaOutput[iOut], pTS->anOutput[iOut], &aNew, &nNew + ); + if( rc!=SQLITE_OK ){ + if( aMerge!=aDoclist ) sqlite3_free(aMerge); + return rc; } - return SQLITE_NOMEM; - } - fts3DoclistMerge(mergetype, 0, 0, aNew, &nNew, - pTS->aaOutput[iOut], pTS->anOutput[iOut], aMerge, nMerge, 0 - ); - if( iOut>0 ) sqlite3_free(aMerge); - sqlite3_free(pTS->aaOutput[iOut]); - pTS->aaOutput[iOut] = 0; - - aMerge = aNew; - nMerge = nNew; - if( (iOut+1)==SizeofArray(pTS->aaOutput) ){ - pTS->aaOutput[iOut] = aMerge; - pTS->anOutput[iOut] = nMerge; + if( aMerge!=aDoclist ) sqlite3_free(aMerge); + sqlite3_free(pTS->aaOutput[iOut]); + pTS->aaOutput[iOut] = 0; + + aMerge = aNew; + nMerge = nNew; + if( (iOut+1)==SizeofArray(pTS->aaOutput) ){ + pTS->aaOutput[iOut] = aMerge; + pTS->anOutput[iOut] = nMerge; + } } } } return SQLITE_OK; } -static int fts3DeferredTermSelect( - Fts3DeferredToken *pToken, /* Phrase token */ - int isTermPos, /* True to include positions */ - int *pnOut, /* OUT: Size of list */ - char **ppOut /* OUT: Body of list */ -){ - char *aSource; - int nSource; - - aSource = sqlite3Fts3DeferredDoclist(pToken, &nSource); - if( !aSource ){ - *pnOut = 0; - *ppOut = 0; - }else if( isTermPos ){ - *ppOut = sqlite3_malloc(nSource); - if( !*ppOut ) return SQLITE_NOMEM; - memcpy(*ppOut, aSource, nSource); - *pnOut = nSource; - }else{ - sqlite3_int64 docid; - *pnOut = sqlite3Fts3GetVarint(aSource, &docid); - *ppOut = sqlite3_malloc(*pnOut); - if( !*ppOut ) return SQLITE_NOMEM; - sqlite3Fts3PutVarint(*ppOut, docid); +/* +** Append SegReader object pNew to the end of the pCsr->apSegment[] array. +*/ +static int fts3SegReaderCursorAppend( + Fts3MultiSegReader *pCsr, + Fts3SegReader *pNew +){ + if( (pCsr->nSegment%16)==0 ){ + Fts3SegReader **apNew; + int nByte = (pCsr->nSegment + 16)*sizeof(Fts3SegReader*); + apNew = (Fts3SegReader **)sqlite3_realloc(pCsr->apSegment, nByte); + if( !apNew ){ + sqlite3Fts3SegReaderFree(pNew); + return SQLITE_NOMEM; + } + pCsr->apSegment = apNew; } - + pCsr->apSegment[pCsr->nSegment++] = pNew; return SQLITE_OK; } -SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor( +static int fts3SegReaderCursor( Fts3Table *p, /* FTS3 table handle */ + int iIndex, /* Index to search (from 0 to p->nIndex-1) */ int iLevel, /* Level of segments to scan */ const char *zTerm, /* Term to query for */ int nTerm, /* Size of zTerm in bytes */ int isPrefix, /* True for a prefix search */ int isScan, /* True to scan from zTerm to EOF */ - Fts3SegReaderCursor *pCsr /* Cursor object to populate */ + Fts3MultiSegReader *pCsr /* Cursor object to populate */ ){ int rc = SQLITE_OK; int rc2; - int iAge = 0; sqlite3_stmt *pStmt = 0; - Fts3SegReader *pPending = 0; - - assert( iLevel==FTS3_SEGCURSOR_ALL - || iLevel==FTS3_SEGCURSOR_PENDING - || iLevel>=0 - ); - assert( FTS3_SEGCURSOR_PENDING<0 ); - assert( FTS3_SEGCURSOR_ALL<0 ); - assert( iLevel==FTS3_SEGCURSOR_ALL || (zTerm==0 && isPrefix==1) ); - assert( isPrefix==0 || isScan==0 ); - - - memset(pCsr, 0, sizeof(Fts3SegReaderCursor)); - /* If iLevel is less than 0, include a seg-reader for the pending-terms. */ - assert( isScan==0 || fts3HashCount(&p->pendingTerms)==0 ); - if( iLevel<0 && isScan==0 ){ - rc = sqlite3Fts3SegReaderPending(p, zTerm, nTerm, isPrefix, &pPending); - if( rc==SQLITE_OK && pPending ){ - int nByte = (sizeof(Fts3SegReader *) * 16); - pCsr->apSegment = (Fts3SegReader **)sqlite3_malloc(nByte); - if( pCsr->apSegment==0 ){ - rc = SQLITE_NOMEM; - }else{ - pCsr->apSegment[0] = pPending; - pCsr->nSegment = 1; - pPending = 0; - } + /* If iLevel is less than 0 and this is not a scan, include a seg-reader + ** for the pending-terms. If this is a scan, then this call must be being + ** made by an fts4aux module, not an FTS table. In this case calling + ** Fts3SegReaderPending might segfault, as the data structures used by + ** fts4aux are not completely populated. So it's easiest to filter these + ** calls out here. */ + if( iLevel<0 && p->aIndex ){ + Fts3SegReader *pSeg = 0; + rc = sqlite3Fts3SegReaderPending(p, iIndex, zTerm, nTerm, isPrefix, &pSeg); + if( rc==SQLITE_OK && pSeg ){ + rc = fts3SegReaderCursorAppend(pCsr, pSeg); } } if( iLevel!=FTS3_SEGCURSOR_PENDING ){ if( rc==SQLITE_OK ){ - rc = sqlite3Fts3AllSegdirs(p, iLevel, &pStmt); + rc = sqlite3Fts3AllSegdirs(p, iIndex, iLevel, &pStmt); } + while( rc==SQLITE_OK && SQLITE_ROW==(rc = sqlite3_step(pStmt)) ){ + Fts3SegReader *pSeg = 0; /* Read the values returned by the SELECT into local variables. */ sqlite3_int64 iStartBlock = sqlite3_column_int64(pStmt, 1); @@ -112933,18 +114229,6 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor( int nRoot = sqlite3_column_bytes(pStmt, 4); char const *zRoot = sqlite3_column_blob(pStmt, 4); - /* If nSegment is a multiple of 16 the array needs to be extended. */ - if( (pCsr->nSegment%16)==0 ){ - Fts3SegReader **apNew; - int nByte = (pCsr->nSegment + 16)*sizeof(Fts3SegReader*); - apNew = (Fts3SegReader **)sqlite3_realloc(pCsr->apSegment, nByte); - if( !apNew ){ - rc = SQLITE_NOMEM; - goto finished; - } - pCsr->apSegment = apNew; - } - /* If zTerm is not NULL, and this segment is not stored entirely on its ** root node, the range of leaves scanned can be reduced. Do this. */ if( iStartBlock && zTerm ){ @@ -112954,53 +114238,117 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor( if( isPrefix==0 && isScan==0 ) iLeavesEndBlock = iStartBlock; } - rc = sqlite3Fts3SegReaderNew(iAge, iStartBlock, iLeavesEndBlock, - iEndBlock, zRoot, nRoot, &pCsr->apSegment[pCsr->nSegment] + rc = sqlite3Fts3SegReaderNew(pCsr->nSegment+1, + iStartBlock, iLeavesEndBlock, iEndBlock, zRoot, nRoot, &pSeg ); if( rc!=SQLITE_OK ) goto finished; - pCsr->nSegment++; - iAge++; + rc = fts3SegReaderCursorAppend(pCsr, pSeg); } } finished: rc2 = sqlite3_reset(pStmt); if( rc==SQLITE_DONE ) rc = rc2; - sqlite3Fts3SegReaderFree(pPending); return rc; } +/* +** Set up a cursor object for iterating through a full-text index or a +** single level therein. +*/ +SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor( + Fts3Table *p, /* FTS3 table handle */ + int iIndex, /* Index to search (from 0 to p->nIndex-1) */ + int iLevel, /* Level of segments to scan */ + const char *zTerm, /* Term to query for */ + int nTerm, /* Size of zTerm in bytes */ + int isPrefix, /* True for a prefix search */ + int isScan, /* True to scan from zTerm to EOF */ + Fts3MultiSegReader *pCsr /* Cursor object to populate */ +){ + assert( iIndex>=0 && iIndexnIndex ); + assert( iLevel==FTS3_SEGCURSOR_ALL + || iLevel==FTS3_SEGCURSOR_PENDING + || iLevel>=0 + ); + assert( iLevelaIndex==0 ); + + memset(pCsr, 0, sizeof(Fts3MultiSegReader)); + + return fts3SegReaderCursor( + p, iIndex, iLevel, zTerm, nTerm, isPrefix, isScan, pCsr + ); +} + +static int fts3SegReaderCursorAddZero( + Fts3Table *p, + const char *zTerm, + int nTerm, + Fts3MultiSegReader *pCsr +){ + return fts3SegReaderCursor(p, 0, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 0, 0,pCsr); +} + -static int fts3TermSegReaderCursor( +SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor( Fts3Cursor *pCsr, /* Virtual table cursor handle */ const char *zTerm, /* Term to query for */ int nTerm, /* Size of zTerm in bytes */ int isPrefix, /* True for a prefix search */ - Fts3SegReaderCursor **ppSegcsr /* OUT: Allocated seg-reader cursor */ + Fts3MultiSegReader **ppSegcsr /* OUT: Allocated seg-reader cursor */ ){ - Fts3SegReaderCursor *pSegcsr; /* Object to allocate and return */ + Fts3MultiSegReader *pSegcsr; /* Object to allocate and return */ int rc = SQLITE_NOMEM; /* Return code */ - pSegcsr = sqlite3_malloc(sizeof(Fts3SegReaderCursor)); + pSegcsr = sqlite3_malloc(sizeof(Fts3MultiSegReader)); if( pSegcsr ){ - Fts3Table *p = (Fts3Table *)pCsr->base.pVtab; int i; - int nCost = 0; - rc = sqlite3Fts3SegReaderCursor( - p, FTS3_SEGCURSOR_ALL, zTerm, nTerm, isPrefix, 0, pSegcsr); - - for(i=0; rc==SQLITE_OK && inSegment; i++){ - rc = sqlite3Fts3SegReaderCost(pCsr, pSegcsr->apSegment[i], &nCost); + int bFound = 0; /* True once an index has been found */ + Fts3Table *p = (Fts3Table *)pCsr->base.pVtab; + + if( isPrefix ){ + for(i=1; bFound==0 && inIndex; i++){ + if( p->aIndex[i].nPrefix==nTerm ){ + bFound = 1; + rc = sqlite3Fts3SegReaderCursor( + p, i, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 0, 0, pSegcsr); + pSegcsr->bLookup = 1; + } + } + + for(i=1; bFound==0 && inIndex; i++){ + if( p->aIndex[i].nPrefix==nTerm+1 ){ + bFound = 1; + rc = sqlite3Fts3SegReaderCursor( + p, i, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 1, 0, pSegcsr + ); + if( rc==SQLITE_OK ){ + rc = fts3SegReaderCursorAddZero(p, zTerm, nTerm, pSegcsr); + } + } + } + } + + if( bFound==0 ){ + rc = sqlite3Fts3SegReaderCursor( + p, 0, FTS3_SEGCURSOR_ALL, zTerm, nTerm, isPrefix, 0, pSegcsr + ); + pSegcsr->bLookup = !isPrefix; } - pSegcsr->nCost = nCost; } *ppSegcsr = pSegcsr; return rc; } -static void fts3SegReaderCursorFree(Fts3SegReaderCursor *pSegcsr){ +static void fts3SegReaderCursorFree(Fts3MultiSegReader *pSegcsr){ sqlite3Fts3SegReaderFinish(pSegcsr); sqlite3_free(pSegcsr); } @@ -113025,7 +114373,7 @@ static int fts3TermSelect( char **ppOut /* OUT: Malloced result buffer */ ){ int rc; /* Return code */ - Fts3SegReaderCursor *pSegcsr; /* Seg-reader cursor for this term */ + Fts3MultiSegReader *pSegcsr; /* Seg-reader cursor for this term */ TermSelect tsc; /* Context object for fts3TermSelectCb() */ Fts3SegFilter filter; /* Segment term filter configuration */ @@ -113051,7 +114399,7 @@ static int fts3TermSelect( } if( rc==SQLITE_OK ){ - rc = fts3TermSelectMerge(&tsc); + rc = fts3TermSelectMerge(p, &tsc); } if( rc==SQLITE_OK ){ *ppOut = tsc.aaOutput[0]; @@ -113101,660 +114449,6 @@ static int fts3DoclistCountDocids(int isPoslist, char *aList, int nList){ return nDoc; } -/* -** Call sqlite3Fts3DeferToken() for each token in the expression pExpr. -*/ -static int fts3DeferExpression(Fts3Cursor *pCsr, Fts3Expr *pExpr){ - int rc = SQLITE_OK; - if( pExpr ){ - rc = fts3DeferExpression(pCsr, pExpr->pLeft); - if( rc==SQLITE_OK ){ - rc = fts3DeferExpression(pCsr, pExpr->pRight); - } - if( pExpr->eType==FTSQUERY_PHRASE ){ - int iCol = pExpr->pPhrase->iColumn; - int i; - for(i=0; rc==SQLITE_OK && ipPhrase->nToken; i++){ - Fts3PhraseToken *pToken = &pExpr->pPhrase->aToken[i]; - if( pToken->pDeferred==0 ){ - rc = sqlite3Fts3DeferToken(pCsr, pToken, iCol); - } - } - } - } - return rc; -} - -/* -** This function removes the position information from a doclist. When -** called, buffer aList (size *pnList bytes) contains a doclist that includes -** position information. This function removes the position information so -** that aList contains only docids, and adjusts *pnList to reflect the new -** (possibly reduced) size of the doclist. -*/ -static void fts3DoclistStripPositions( - char *aList, /* IN/OUT: Buffer containing doclist */ - int *pnList /* IN/OUT: Size of doclist in bytes */ -){ - if( aList ){ - char *aEnd = &aList[*pnList]; /* Pointer to one byte after EOF */ - char *p = aList; /* Input cursor */ - char *pOut = aList; /* Output cursor */ - - while( piColumn; - int isTermPos = (pPhrase->nToken>1 || isReqPos); - Fts3Table *p = (Fts3Table *)pCsr->base.pVtab; - int isFirst = 1; - - int iPrevTok = 0; - int nDoc = 0; - - /* If this is an xFilter() evaluation, create a segment-reader for each - ** phrase token. Or, if this is an xNext() or snippet/offsets/matchinfo - ** evaluation, only create segment-readers if there are no Fts3DeferredToken - ** objects attached to the phrase-tokens. - */ - for(ii=0; iinToken; ii++){ - Fts3PhraseToken *pTok = &pPhrase->aToken[ii]; - if( pTok->pSegcsr==0 ){ - if( (pCsr->eEvalmode==FTS3_EVAL_FILTER) - || (pCsr->eEvalmode==FTS3_EVAL_NEXT && pCsr->pDeferred==0) - || (pCsr->eEvalmode==FTS3_EVAL_MATCHINFO && pTok->bFulltext) - ){ - rc = fts3TermSegReaderCursor( - pCsr, pTok->z, pTok->n, pTok->isPrefix, &pTok->pSegcsr - ); - if( rc!=SQLITE_OK ) return rc; - } - } - } - - for(ii=0; iinToken; ii++){ - Fts3PhraseToken *pTok; /* Token to find doclist for */ - int iTok = 0; /* The token being queried this iteration */ - char *pList = 0; /* Pointer to token doclist */ - int nList = 0; /* Size of buffer at pList */ - - /* Select a token to process. If this is an xFilter() call, then tokens - ** are processed in order from least to most costly. Otherwise, tokens - ** are processed in the order in which they occur in the phrase. - */ - if( pCsr->eEvalmode==FTS3_EVAL_MATCHINFO ){ - assert( isReqPos ); - iTok = ii; - pTok = &pPhrase->aToken[iTok]; - if( pTok->bFulltext==0 ) continue; - }else if( pCsr->eEvalmode==FTS3_EVAL_NEXT || isReqPos ){ - iTok = ii; - pTok = &pPhrase->aToken[iTok]; - }else{ - int nMinCost = 0x7FFFFFFF; - int jj; - - /* Find the remaining token with the lowest cost. */ - for(jj=0; jjnToken; jj++){ - Fts3SegReaderCursor *pSegcsr = pPhrase->aToken[jj].pSegcsr; - if( pSegcsr && pSegcsr->nCostnCost; - } - } - pTok = &pPhrase->aToken[iTok]; - - /* This branch is taken if it is determined that loading the doclist - ** for the next token would require more IO than loading all documents - ** currently identified by doclist pOut/nOut. No further doclists will - ** be loaded from the full-text index for this phrase. - */ - if( nMinCost>nDoc && ii>0 ){ - rc = fts3DeferExpression(pCsr, pCsr->pExpr); - break; - } - } - - if( pCsr->eEvalmode==FTS3_EVAL_NEXT && pTok->pDeferred ){ - rc = fts3DeferredTermSelect(pTok->pDeferred, isTermPos, &nList, &pList); - }else{ - if( pTok->pSegcsr ){ - rc = fts3TermSelect(p, pTok, iCol, isTermPos, &nList, &pList); - } - pTok->bFulltext = 1; - } - assert( rc!=SQLITE_OK || pCsr->eEvalmode || pTok->pSegcsr==0 ); - if( rc!=SQLITE_OK ) break; - - if( isFirst ){ - pOut = pList; - nOut = nList; - if( pCsr->eEvalmode==FTS3_EVAL_FILTER && pPhrase->nToken>1 ){ - nDoc = fts3DoclistCountDocids(1, pOut, nOut); - } - isFirst = 0; - iPrevTok = iTok; - }else{ - /* Merge the new term list and the current output. */ - char *aLeft, *aRight; - int nLeft, nRight; - int nDist; - int mt; - - /* If this is the final token of the phrase, and positions were not - ** requested by the caller, use MERGE_PHRASE instead of POS_PHRASE. - ** This drops the position information from the output list. - */ - mt = MERGE_POS_PHRASE; - if( ii==pPhrase->nToken-1 && !isReqPos ) mt = MERGE_PHRASE; - - assert( iPrevTok!=iTok ); - if( iPrevToknToken ){ - assert( pCsr->eEvalmode==FTS3_EVAL_FILTER && isReqPos==0 ); - fts3DoclistStripPositions(pOut, &nOut); - } - *paOut = pOut; - *pnOut = nOut; - }else{ - sqlite3_free(pOut); - } - return rc; -} - -/* -** This function merges two doclists according to the requirements of a -** NEAR operator. -** -** Both input doclists must include position information. The output doclist -** includes position information if the first argument to this function -** is MERGE_POS_NEAR, or does not if it is MERGE_NEAR. -*/ -static int fts3NearMerge( - int mergetype, /* MERGE_POS_NEAR or MERGE_NEAR */ - int nNear, /* Parameter to NEAR operator */ - int nTokenLeft, /* Number of tokens in LHS phrase arg */ - char *aLeft, /* Doclist for LHS (incl. positions) */ - int nLeft, /* Size of LHS doclist in bytes */ - int nTokenRight, /* As nTokenLeft */ - char *aRight, /* As aLeft */ - int nRight, /* As nRight */ - char **paOut, /* OUT: Results of merge (malloced) */ - int *pnOut /* OUT: Sized of output buffer */ -){ - char *aOut; /* Buffer to write output doclist to */ - int rc; /* Return code */ - - assert( mergetype==MERGE_POS_NEAR || MERGE_NEAR ); - - aOut = sqlite3_malloc(nLeft+nRight+1); - if( aOut==0 ){ - rc = SQLITE_NOMEM; - }else{ - rc = fts3DoclistMerge(mergetype, nNear+nTokenRight, nNear+nTokenLeft, - aOut, pnOut, aLeft, nLeft, aRight, nRight, 0 - ); - if( rc!=SQLITE_OK ){ - sqlite3_free(aOut); - aOut = 0; - } - } - - *paOut = aOut; - return rc; -} - -/* -** This function is used as part of the processing for the snippet() and -** offsets() functions. -** -** Both pLeft and pRight are expression nodes of type FTSQUERY_PHRASE. Both -** have their respective doclists (including position information) loaded -** in Fts3Expr.aDoclist/nDoclist. This function removes all entries from -** each doclist that are not within nNear tokens of a corresponding entry -** in the other doclist. -*/ -SQLITE_PRIVATE int sqlite3Fts3ExprNearTrim(Fts3Expr *pLeft, Fts3Expr *pRight, int nNear){ - int rc; /* Return code */ - - assert( pLeft->eType==FTSQUERY_PHRASE ); - assert( pRight->eType==FTSQUERY_PHRASE ); - assert( pLeft->isLoaded && pRight->isLoaded ); - - if( pLeft->aDoclist==0 || pRight->aDoclist==0 ){ - sqlite3_free(pLeft->aDoclist); - sqlite3_free(pRight->aDoclist); - pRight->aDoclist = 0; - pLeft->aDoclist = 0; - rc = SQLITE_OK; - }else{ - char *aOut; /* Buffer in which to assemble new doclist */ - int nOut; /* Size of buffer aOut in bytes */ - - rc = fts3NearMerge(MERGE_POS_NEAR, nNear, - pLeft->pPhrase->nToken, pLeft->aDoclist, pLeft->nDoclist, - pRight->pPhrase->nToken, pRight->aDoclist, pRight->nDoclist, - &aOut, &nOut - ); - if( rc!=SQLITE_OK ) return rc; - sqlite3_free(pRight->aDoclist); - pRight->aDoclist = aOut; - pRight->nDoclist = nOut; - - rc = fts3NearMerge(MERGE_POS_NEAR, nNear, - pRight->pPhrase->nToken, pRight->aDoclist, pRight->nDoclist, - pLeft->pPhrase->nToken, pLeft->aDoclist, pLeft->nDoclist, - &aOut, &nOut - ); - sqlite3_free(pLeft->aDoclist); - pLeft->aDoclist = aOut; - pLeft->nDoclist = nOut; - } - return rc; -} - - -/* -** Allocate an Fts3SegReaderArray for each token in the expression pExpr. -** The allocated objects are stored in the Fts3PhraseToken.pArray member -** variables of each token structure. -*/ -static int fts3ExprAllocateSegReaders( - Fts3Cursor *pCsr, /* FTS3 table */ - Fts3Expr *pExpr, /* Expression to create seg-readers for */ - int *pnExpr /* OUT: Number of AND'd expressions */ -){ - int rc = SQLITE_OK; /* Return code */ - - assert( pCsr->eEvalmode==FTS3_EVAL_FILTER ); - if( pnExpr && pExpr->eType!=FTSQUERY_AND ){ - (*pnExpr)++; - pnExpr = 0; - } - - if( pExpr->eType==FTSQUERY_PHRASE ){ - Fts3Phrase *pPhrase = pExpr->pPhrase; - int ii; - - for(ii=0; rc==SQLITE_OK && iinToken; ii++){ - Fts3PhraseToken *pTok = &pPhrase->aToken[ii]; - if( pTok->pSegcsr==0 ){ - rc = fts3TermSegReaderCursor( - pCsr, pTok->z, pTok->n, pTok->isPrefix, &pTok->pSegcsr - ); - } - } - }else{ - rc = fts3ExprAllocateSegReaders(pCsr, pExpr->pLeft, pnExpr); - if( rc==SQLITE_OK ){ - rc = fts3ExprAllocateSegReaders(pCsr, pExpr->pRight, pnExpr); - } - } - return rc; -} - -/* -** Free the Fts3SegReaderArray objects associated with each token in the -** expression pExpr. In other words, this function frees the resources -** allocated by fts3ExprAllocateSegReaders(). -*/ -static void fts3ExprFreeSegReaders(Fts3Expr *pExpr){ - if( pExpr ){ - Fts3Phrase *pPhrase = pExpr->pPhrase; - if( pPhrase ){ - int kk; - for(kk=0; kknToken; kk++){ - fts3SegReaderCursorFree(pPhrase->aToken[kk].pSegcsr); - pPhrase->aToken[kk].pSegcsr = 0; - } - } - fts3ExprFreeSegReaders(pExpr->pLeft); - fts3ExprFreeSegReaders(pExpr->pRight); - } -} - -/* -** Return the sum of the costs of all tokens in the expression pExpr. This -** function must be called after Fts3SegReaderArrays have been allocated -** for all tokens using fts3ExprAllocateSegReaders(). -*/ -static int fts3ExprCost(Fts3Expr *pExpr){ - int nCost; /* Return value */ - if( pExpr->eType==FTSQUERY_PHRASE ){ - Fts3Phrase *pPhrase = pExpr->pPhrase; - int ii; - nCost = 0; - for(ii=0; iinToken; ii++){ - Fts3SegReaderCursor *pSegcsr = pPhrase->aToken[ii].pSegcsr; - if( pSegcsr ) nCost += pSegcsr->nCost; - } - }else{ - nCost = fts3ExprCost(pExpr->pLeft) + fts3ExprCost(pExpr->pRight); - } - return nCost; -} - -/* -** The following is a helper function (and type) for fts3EvalExpr(). It -** must be called after Fts3SegReaders have been allocated for every token -** in the expression. See the context it is called from in fts3EvalExpr() -** for further explanation. -*/ -typedef struct ExprAndCost ExprAndCost; -struct ExprAndCost { - Fts3Expr *pExpr; - int nCost; -}; -static void fts3ExprAssignCosts( - Fts3Expr *pExpr, /* Expression to create seg-readers for */ - ExprAndCost **ppExprCost /* OUT: Write to *ppExprCost */ -){ - if( pExpr->eType==FTSQUERY_AND ){ - fts3ExprAssignCosts(pExpr->pLeft, ppExprCost); - fts3ExprAssignCosts(pExpr->pRight, ppExprCost); - }else{ - (*ppExprCost)->pExpr = pExpr; - (*ppExprCost)->nCost = fts3ExprCost(pExpr); - (*ppExprCost)++; - } -} - -/* -** Evaluate the full-text expression pExpr against FTS3 table pTab. Store -** the resulting doclist in *paOut and *pnOut. This routine mallocs for -** the space needed to store the output. The caller is responsible for -** freeing the space when it has finished. -** -** This function is called in two distinct contexts: -** -** * From within the virtual table xFilter() method. In this case, the -** output doclist contains entries for all rows in the table, based on -** data read from the full-text index. -** -** In this case, if the query expression contains one or more tokens that -** are very common, then the returned doclist may contain a superset of -** the documents that actually match the expression. -** -** * From within the virtual table xNext() method. This call is only made -** if the call from within xFilter() found that there were very common -** tokens in the query expression and did return a superset of the -** matching documents. In this case the returned doclist contains only -** entries that correspond to the current row of the table. Instead of -** reading the data for each token from the full-text index, the data is -** already available in-memory in the Fts3PhraseToken.pDeferred structures. -** See fts3EvalDeferred() for how it gets there. -** -** In the first case above, Fts3Cursor.doDeferred==0. In the second (if it is -** required) Fts3Cursor.doDeferred==1. -** -** If the SQLite invokes the snippet(), offsets() or matchinfo() function -** as part of a SELECT on an FTS3 table, this function is called on each -** individual phrase expression in the query. If there were very common tokens -** found in the xFilter() call, then this function is called once for phrase -** for each row visited, and the returned doclist contains entries for the -** current row only. Otherwise, if there were no very common tokens, then this -** function is called once only for each phrase in the query and the returned -** doclist contains entries for all rows of the table. -** -** Fts3Cursor.doDeferred==1 when this function is called on phrases as a -** result of a snippet(), offsets() or matchinfo() invocation. -*/ -static int fts3EvalExpr( - Fts3Cursor *p, /* Virtual table cursor handle */ - Fts3Expr *pExpr, /* Parsed fts3 expression */ - char **paOut, /* OUT: Pointer to malloc'd result buffer */ - int *pnOut, /* OUT: Size of buffer at *paOut */ - int isReqPos /* Require positions in output buffer */ -){ - int rc = SQLITE_OK; /* Return code */ - - /* Zero the output parameters. */ - *paOut = 0; - *pnOut = 0; - - if( pExpr ){ - assert( pExpr->eType==FTSQUERY_NEAR || pExpr->eType==FTSQUERY_OR - || pExpr->eType==FTSQUERY_AND || pExpr->eType==FTSQUERY_NOT - || pExpr->eType==FTSQUERY_PHRASE - ); - assert( pExpr->eType==FTSQUERY_PHRASE || isReqPos==0 ); - - if( pExpr->eType==FTSQUERY_PHRASE ){ - rc = fts3PhraseSelect(p, pExpr->pPhrase, - isReqPos || (pExpr->pParent && pExpr->pParent->eType==FTSQUERY_NEAR), - paOut, pnOut - ); - fts3ExprFreeSegReaders(pExpr); - }else if( p->eEvalmode==FTS3_EVAL_FILTER && pExpr->eType==FTSQUERY_AND ){ - ExprAndCost *aExpr = 0; /* Array of AND'd expressions and costs */ - int nExpr = 0; /* Size of aExpr[] */ - char *aRet = 0; /* Doclist to return to caller */ - int nRet = 0; /* Length of aRet[] in bytes */ - int nDoc = 0x7FFFFFFF; - - assert( !isReqPos ); - - rc = fts3ExprAllocateSegReaders(p, pExpr, &nExpr); - if( rc==SQLITE_OK ){ - assert( nExpr>1 ); - aExpr = sqlite3_malloc(sizeof(ExprAndCost) * nExpr); - if( !aExpr ) rc = SQLITE_NOMEM; - } - if( rc==SQLITE_OK ){ - int ii; /* Used to iterate through expressions */ - - fts3ExprAssignCosts(pExpr, &aExpr); - aExpr -= nExpr; - for(ii=0; iipExpr && (pBest==0 || pCand->nCostnCost) ){ - pBest = pCand; - } - } - - if( pBest->nCost>nDoc ){ - rc = fts3DeferExpression(p, p->pExpr); - break; - }else{ - rc = fts3EvalExpr(p, pBest->pExpr, &aNew, &nNew, 0); - if( rc!=SQLITE_OK ) break; - pBest->pExpr = 0; - if( ii==0 ){ - aRet = aNew; - nRet = nNew; - nDoc = fts3DoclistCountDocids(0, aRet, nRet); - }else{ - fts3DoclistMerge( - MERGE_AND, 0, 0, aRet, &nRet, aRet, nRet, aNew, nNew, &nDoc - ); - sqlite3_free(aNew); - } - } - } - } - - if( rc==SQLITE_OK ){ - *paOut = aRet; - *pnOut = nRet; - }else{ - assert( *paOut==0 ); - sqlite3_free(aRet); - } - sqlite3_free(aExpr); - fts3ExprFreeSegReaders(pExpr); - - }else{ - char *aLeft; - char *aRight; - int nLeft; - int nRight; - - assert( pExpr->eType==FTSQUERY_NEAR - || pExpr->eType==FTSQUERY_OR - || pExpr->eType==FTSQUERY_NOT - || (pExpr->eType==FTSQUERY_AND && p->eEvalmode==FTS3_EVAL_NEXT) - ); - - if( 0==(rc = fts3EvalExpr(p, pExpr->pRight, &aRight, &nRight, isReqPos)) - && 0==(rc = fts3EvalExpr(p, pExpr->pLeft, &aLeft, &nLeft, isReqPos)) - ){ - switch( pExpr->eType ){ - case FTSQUERY_NEAR: { - Fts3Expr *pLeft; - Fts3Expr *pRight; - int mergetype = MERGE_NEAR; - if( pExpr->pParent && pExpr->pParent->eType==FTSQUERY_NEAR ){ - mergetype = MERGE_POS_NEAR; - } - pLeft = pExpr->pLeft; - while( pLeft->eType==FTSQUERY_NEAR ){ - pLeft=pLeft->pRight; - } - pRight = pExpr->pRight; - assert( pRight->eType==FTSQUERY_PHRASE ); - assert( pLeft->eType==FTSQUERY_PHRASE ); - - rc = fts3NearMerge(mergetype, pExpr->nNear, - pLeft->pPhrase->nToken, aLeft, nLeft, - pRight->pPhrase->nToken, aRight, nRight, - paOut, pnOut - ); - sqlite3_free(aLeft); - break; - } - - case FTSQUERY_OR: { - /* Allocate a buffer for the output. The maximum size is the - ** sum of the sizes of the two input buffers. The +1 term is - ** so that a buffer of zero bytes is never allocated - this can - ** cause fts3DoclistMerge() to incorrectly return SQLITE_NOMEM. - */ - char *aBuffer = sqlite3_malloc(nRight+nLeft+1); - rc = fts3DoclistMerge(MERGE_OR, 0, 0, aBuffer, pnOut, - aLeft, nLeft, aRight, nRight, 0 - ); - *paOut = aBuffer; - sqlite3_free(aLeft); - break; - } - - default: { - assert( FTSQUERY_NOT==MERGE_NOT && FTSQUERY_AND==MERGE_AND ); - fts3DoclistMerge(pExpr->eType, 0, 0, aLeft, pnOut, - aLeft, nLeft, aRight, nRight, 0 - ); - *paOut = aLeft; - break; - } - } - } - sqlite3_free(aRight); - } - } - - assert( rc==SQLITE_OK || *paOut==0 ); - return rc; -} - -/* -** This function is called from within xNext() for each row visited by -** an FTS3 query. If evaluating the FTS3 query expression within xFilter() -** was able to determine the exact set of matching rows, this function sets -** *pbRes to true and returns SQLITE_IO immediately. -** -** Otherwise, if evaluating the query expression within xFilter() returned a -** superset of the matching documents instead of an exact set (this happens -** when the query includes very common tokens and it is deemed too expensive to -** load their doclists from disk), this function tests if the current row -** really does match the FTS3 query. -** -** If an error occurs, an SQLite error code is returned. Otherwise, SQLITE_OK -** is returned and *pbRes is set to true if the current row matches the -** FTS3 query (and should be included in the results returned to SQLite), or -** false otherwise. -*/ -static int fts3EvalDeferred( - Fts3Cursor *pCsr, /* FTS3 cursor pointing at row to test */ - int *pbRes /* OUT: Set to true if row is a match */ -){ - int rc = SQLITE_OK; - if( pCsr->pDeferred==0 ){ - *pbRes = 1; - }else{ - rc = fts3CursorSeek(0, pCsr); - if( rc==SQLITE_OK ){ - sqlite3Fts3FreeDeferredDoclists(pCsr); - rc = sqlite3Fts3CacheDeferredDoclists(pCsr); - } - if( rc==SQLITE_OK ){ - char *a = 0; - int n = 0; - rc = fts3EvalExpr(pCsr, pCsr->pExpr, &a, &n, 0); - assert( n>=0 ); - *pbRes = (n>0); - sqlite3_free(a); - } - } - return rc; -} - /* ** Advance the cursor to the next row in the %_content table that ** matches the search criteria. For a MATCH search, this will be @@ -113767,31 +114461,20 @@ static int fts3EvalDeferred( ** subsequently to determine whether or not an EOF was hit. */ static int fts3NextMethod(sqlite3_vtab_cursor *pCursor){ - int res; - int rc = SQLITE_OK; /* Return code */ + int rc; Fts3Cursor *pCsr = (Fts3Cursor *)pCursor; - - pCsr->eEvalmode = FTS3_EVAL_NEXT; - do { - if( pCsr->aDoclist==0 ){ - if( SQLITE_ROW!=sqlite3_step(pCsr->pStmt) ){ - pCsr->isEof = 1; - rc = sqlite3_reset(pCsr->pStmt); - break; - } - pCsr->iPrevId = sqlite3_column_int64(pCsr->pStmt, 0); + if( pCsr->eSearch==FTS3_DOCID_SEARCH || pCsr->eSearch==FTS3_FULLSCAN_SEARCH ){ + if( SQLITE_ROW!=sqlite3_step(pCsr->pStmt) ){ + pCsr->isEof = 1; + rc = sqlite3_reset(pCsr->pStmt); }else{ - if( pCsr->pNextId>=&pCsr->aDoclist[pCsr->nDoclist] ){ - pCsr->isEof = 1; - break; - } - sqlite3_reset(pCsr->pStmt); - fts3GetDeltaVarint(&pCsr->pNextId, &pCsr->iPrevId); - pCsr->isRequireSeek = 1; - pCsr->isMatchinfoNeeded = 1; + pCsr->iPrevId = sqlite3_column_int64(pCsr->pStmt, 0); + rc = SQLITE_OK; } - }while( SQLITE_OK==(rc = fts3EvalDeferred(pCsr, &res)) && res==0 ); - + }else{ + rc = sqlite3Fts3EvalNext((Fts3Cursor *)pCursor); + } + assert( ((Fts3Table *)pCsr->base.pVtab)->pSegments==0 ); return rc; } @@ -113818,11 +114501,7 @@ static int fts3FilterMethod( int nVal, /* Number of elements in apVal */ sqlite3_value **apVal /* Arguments for the indexing scheme */ ){ - const char *azSql[] = { - "SELECT %s FROM %Q.'%q_content' AS x WHERE docid = ?", /* non-full-scan */ - "SELECT %s FROM %Q.'%q_content' AS x ", /* full-scan */ - }; - int rc; /* Return code */ + int rc; char *zSql; /* SQL statement used to access %_content */ Fts3Table *p = (Fts3Table *)pCursor->pVtab; Fts3Cursor *pCsr = (Fts3Cursor *)pCursor; @@ -113841,6 +114520,13 @@ static int fts3FilterMethod( sqlite3Fts3ExprFree(pCsr->pExpr); memset(&pCursor[1], 0, sizeof(Fts3Cursor)-sizeof(sqlite3_vtab_cursor)); + if( idxStr ){ + pCsr->bDesc = (idxStr[0]=='D'); + }else{ + pCsr->bDesc = p->bDescIdx; + } + pCsr->eSearch = (i16)idxNum; + if( idxNum!=FTS3_DOCID_SEARCH && idxNum!=FTS3_FULLSCAN_SEARCH ){ int iCol = idxNum-FTS3_FULLTEXT_SEARCH; const char *zQuery = (const char *)sqlite3_value_text(apVal[0]); @@ -113854,8 +114540,8 @@ static int fts3FilterMethod( ); if( rc!=SQLITE_OK ){ if( rc==SQLITE_ERROR ){ - p->base.zErrMsg = sqlite3_mprintf("malformed MATCH expression: [%s]", - zQuery); + static const char *zErr = "malformed MATCH expression: [%s]"; + p->base.zErrMsg = sqlite3_mprintf(zErr, zQuery); } return rc; } @@ -113863,7 +114549,8 @@ static int fts3FilterMethod( rc = sqlite3Fts3ReadLock(p); if( rc!=SQLITE_OK ) return rc; - rc = fts3EvalExpr(pCsr, pCsr->pExpr, &pCsr->aDoclist, &pCsr->nDoclist, 0); + rc = sqlite3Fts3EvalStart(pCsr, pCsr->pExpr, 1); + sqlite3Fts3SegmentsClose(p); if( rc!=SQLITE_OK ) return rc; pCsr->pNextId = pCsr->aDoclist; @@ -113875,20 +114562,24 @@ static int fts3FilterMethod( ** full-text query or docid lookup, the statement retrieves a single ** row by docid. */ - zSql = (char *)azSql[idxNum==FTS3_FULLSCAN_SEARCH]; - zSql = sqlite3_mprintf(zSql, p->zReadExprlist, p->zDb, p->zName); - if( !zSql ){ - rc = SQLITE_NOMEM; + if( idxNum==FTS3_FULLSCAN_SEARCH ){ + const char *zSort = (pCsr->bDesc ? "DESC" : "ASC"); + const char *zTmpl = "SELECT %s FROM %Q.'%q_content' AS x ORDER BY docid %s"; + zSql = sqlite3_mprintf(zTmpl, p->zReadExprlist, p->zDb, p->zName, zSort); }else{ - rc = sqlite3_prepare_v2(p->db, zSql, -1, &pCsr->pStmt, 0); - sqlite3_free(zSql); + const char *zTmpl = "SELECT %s FROM %Q.'%q_content' AS x WHERE docid = ?"; + zSql = sqlite3_mprintf(zTmpl, p->zReadExprlist, p->zDb, p->zName); } - if( rc==SQLITE_OK && idxNum==FTS3_DOCID_SEARCH ){ + if( !zSql ) return SQLITE_NOMEM; + rc = sqlite3_prepare_v2(p->db, zSql, -1, &pCsr->pStmt, 0); + sqlite3_free(zSql); + if( rc!=SQLITE_OK ) return rc; + + if( idxNum==FTS3_DOCID_SEARCH ){ rc = sqlite3_bind_value(pCsr->pStmt, 1, apVal[0]); + if( rc!=SQLITE_OK ) return rc; } - pCsr->eSearch = (i16)idxNum; - if( rc!=SQLITE_OK ) return rc; return fts3NextMethod(pCursor); } @@ -113908,16 +114599,7 @@ static int fts3EofMethod(sqlite3_vtab_cursor *pCursor){ */ static int fts3RowidMethod(sqlite3_vtab_cursor *pCursor, sqlite_int64 *pRowid){ Fts3Cursor *pCsr = (Fts3Cursor *) pCursor; - if( pCsr->aDoclist ){ - *pRowid = pCsr->iPrevId; - }else{ - /* This branch runs if the query is implemented using a full-table scan - ** (not using the full-text index). In this case grab the rowid from the - ** SELECT statement. - */ - assert( pCsr->isRequireSeek==0 ); - *pRowid = sqlite3_column_int64(pCsr->pStmt, 0); - } + *pRowid = pCsr->iPrevId; return SQLITE_OK; } @@ -113930,7 +114612,7 @@ static int fts3ColumnMethod( sqlite3_context *pContext, /* Context for sqlite3_result_xxx() calls */ int iCol /* Index of column to read value from */ ){ - int rc; /* Return Code */ + int rc = SQLITE_OK; /* Return Code */ Fts3Cursor *pCsr = (Fts3Cursor *) pCursor; Fts3Table *p = (Fts3Table *)pCursor->pVtab; @@ -113941,21 +114623,20 @@ static int fts3ColumnMethod( /* This call is a request for the "docid" column. Since "docid" is an ** alias for "rowid", use the xRowid() method to obtain the value. */ - sqlite3_int64 iRowid; - rc = fts3RowidMethod(pCursor, &iRowid); - sqlite3_result_int64(pContext, iRowid); + sqlite3_result_int64(pContext, pCsr->iPrevId); }else if( iCol==p->nColumn ){ /* The extra column whose name is the same as the table. ** Return a blob which is a pointer to the cursor. */ sqlite3_result_blob(pContext, &pCsr, sizeof(pCsr), SQLITE_TRANSIENT); - rc = SQLITE_OK; }else{ rc = fts3CursorSeek(0, pCsr); if( rc==SQLITE_OK ){ sqlite3_result_value(pContext, sqlite3_column_value(pCsr->pStmt, iCol+1)); } } + + assert( ((Fts3Table *)pCsr->base.pVtab)->pSegments==0 ); return rc; } @@ -113987,8 +114668,13 @@ static int fts3SyncMethod(sqlite3_vtab *pVtab){ ** Implementation of xBegin() method. This is a no-op. */ static int fts3BeginMethod(sqlite3_vtab *pVtab){ + TESTONLY( Fts3Table *p = (Fts3Table*)pVtab ); UNUSED_PARAMETER(pVtab); - assert( ((Fts3Table *)pVtab)->nPendingData==0 ); + assert( p->pSegments==0 ); + assert( p->nPendingData==0 ); + assert( p->inTransaction!=1 ); + TESTONLY( p->inTransaction = 1 ); + TESTONLY( p->mxSavepoint = -1; ); return SQLITE_OK; } @@ -113998,8 +114684,13 @@ static int fts3BeginMethod(sqlite3_vtab *pVtab){ ** by fts3SyncMethod(). */ static int fts3CommitMethod(sqlite3_vtab *pVtab){ + TESTONLY( Fts3Table *p = (Fts3Table*)pVtab ); UNUSED_PARAMETER(pVtab); - assert( ((Fts3Table *)pVtab)->nPendingData==0 ); + assert( p->nPendingData==0 ); + assert( p->inTransaction!=0 ); + assert( p->pSegments==0 ); + TESTONLY( p->inTransaction = 0 ); + TESTONLY( p->mxSavepoint = -1; ); return SQLITE_OK; } @@ -114008,93 +114699,31 @@ static int fts3CommitMethod(sqlite3_vtab *pVtab){ ** hash-table. Any changes made to the database are reverted by SQLite. */ static int fts3RollbackMethod(sqlite3_vtab *pVtab){ - sqlite3Fts3PendingTermsClear((Fts3Table *)pVtab); + Fts3Table *p = (Fts3Table*)pVtab; + sqlite3Fts3PendingTermsClear(p); + assert( p->inTransaction!=0 ); + TESTONLY( p->inTransaction = 0 ); + TESTONLY( p->mxSavepoint = -1; ); return SQLITE_OK; } /* -** Load the doclist associated with expression pExpr to pExpr->aDoclist. -** The loaded doclist contains positions as well as the document ids. -** This is used by the matchinfo(), snippet() and offsets() auxillary -** functions. +** When called, *ppPoslist must point to the byte immediately following the +** end of a position-list. i.e. ( (*ppPoslist)[-1]==POS_END ). This function +** moves *ppPoslist so that it instead points to the first byte of the +** same position list. */ -SQLITE_PRIVATE int sqlite3Fts3ExprLoadDoclist(Fts3Cursor *pCsr, Fts3Expr *pExpr){ - int rc; - assert( pExpr->eType==FTSQUERY_PHRASE && pExpr->pPhrase ); - assert( pCsr->eEvalmode==FTS3_EVAL_NEXT ); - rc = fts3EvalExpr(pCsr, pExpr, &pExpr->aDoclist, &pExpr->nDoclist, 1); - return rc; -} +static void fts3ReversePoslist(char *pStart, char **ppPoslist){ + char *p = &(*ppPoslist)[-2]; + char c; -SQLITE_PRIVATE int sqlite3Fts3ExprLoadFtDoclist( - Fts3Cursor *pCsr, - Fts3Expr *pExpr, - char **paDoclist, - int *pnDoclist -){ - int rc; - assert( pCsr->eEvalmode==FTS3_EVAL_NEXT ); - assert( pExpr->eType==FTSQUERY_PHRASE && pExpr->pPhrase ); - pCsr->eEvalmode = FTS3_EVAL_MATCHINFO; - rc = fts3EvalExpr(pCsr, pExpr, paDoclist, pnDoclist, 1); - pCsr->eEvalmode = FTS3_EVAL_NEXT; - return rc; -} - -/* -** After ExprLoadDoclist() (see above) has been called, this function is -** used to iterate/search through the position lists that make up the doclist -** stored in pExpr->aDoclist. -*/ -SQLITE_PRIVATE char *sqlite3Fts3FindPositions( - Fts3Expr *pExpr, /* Access this expressions doclist */ - sqlite3_int64 iDocid, /* Docid associated with requested pos-list */ - int iCol /* Column of requested pos-list */ -){ - assert( pExpr->isLoaded ); - if( pExpr->aDoclist ){ - char *pEnd = &pExpr->aDoclist[pExpr->nDoclist]; - char *pCsr; - - if( pExpr->pCurrent==0 ){ - pExpr->pCurrent = pExpr->aDoclist; - pExpr->iCurrent = 0; - pExpr->pCurrent += sqlite3Fts3GetVarint(pExpr->pCurrent,&pExpr->iCurrent); - } - pCsr = pExpr->pCurrent; - assert( pCsr ); - - while( pCsriCurrentiCurrent); - } - pExpr->pCurrent = pCsr; - }else{ - if( pExpr->iCurrent==iDocid ){ - int iThis = 0; - if( iCol<0 ){ - /* If iCol is negative, return a pointer to the start of the - ** position-list (instead of a pointer to the start of a list - ** of offsets associated with a specific column). - */ - return pCsr; - } - while( iThispStart && (c=*p--)==0 ); + while( p>pStart && (*p & 0x80) | c ){ + c = *p--; } - - return 0; + if( p>pStart ){ p = &p[2]; } + while( *p++&0x80 ); + *ppPoslist = p; } /* @@ -114327,8 +114956,34 @@ static int fts3RenameMethod( return rc; } +static int fts3SavepointMethod(sqlite3_vtab *pVtab, int iSavepoint){ + UNUSED_PARAMETER(iSavepoint); + assert( ((Fts3Table *)pVtab)->inTransaction ); + assert( ((Fts3Table *)pVtab)->mxSavepoint < iSavepoint ); + TESTONLY( ((Fts3Table *)pVtab)->mxSavepoint = iSavepoint ); + return fts3SyncMethod(pVtab); +} +static int fts3ReleaseMethod(sqlite3_vtab *pVtab, int iSavepoint){ + TESTONLY( Fts3Table *p = (Fts3Table*)pVtab ); + UNUSED_PARAMETER(iSavepoint); + UNUSED_PARAMETER(pVtab); + assert( p->inTransaction ); + assert( p->mxSavepoint >= iSavepoint ); + TESTONLY( p->mxSavepoint = iSavepoint-1 ); + return SQLITE_OK; +} +static int fts3RollbackToMethod(sqlite3_vtab *pVtab, int iSavepoint){ + Fts3Table *p = (Fts3Table*)pVtab; + UNUSED_PARAMETER(iSavepoint); + assert( p->inTransaction ); + assert( p->mxSavepoint >= iSavepoint ); + TESTONLY( p->mxSavepoint = iSavepoint ); + sqlite3Fts3PendingTermsClear(p); + return SQLITE_OK; +} + static const sqlite3_module fts3Module = { - /* iVersion */ 0, + /* iVersion */ 2, /* xCreate */ fts3CreateMethod, /* xConnect */ fts3ConnectMethod, /* xBestIndex */ fts3BestIndexMethod, @@ -114348,6 +115003,9 @@ static const sqlite3_module fts3Module = { /* xRollback */ fts3RollbackMethod, /* xFindFunction */ fts3FindFunctionMethod, /* xRename */ fts3RenameMethod, + /* xSavepoint */ fts3SavepointMethod, + /* xRelease */ fts3ReleaseMethod, + /* xRollbackTo */ fts3RollbackToMethod, }; /* @@ -114394,6 +115052,11 @@ SQLITE_PRIVATE int sqlite3Fts3Init(sqlite3 *db){ sqlite3Fts3IcuTokenizerModule(&pIcu); #endif +#ifdef SQLITE_TEST + rc = sqlite3Fts3InitTerm(db); + if( rc!=SQLITE_OK ) return rc; +#endif + rc = sqlite3Fts3InitAux(db); if( rc!=SQLITE_OK ) return rc; @@ -114469,6 +115132,1308 @@ SQLITE_API int sqlite3_extension_init( } #endif + +/* +** Allocate an Fts3MultiSegReader for each token in the expression headed +** by pExpr. +** +** An Fts3SegReader object is a cursor that can seek or scan a range of +** entries within a single segment b-tree. An Fts3MultiSegReader uses multiple +** Fts3SegReader objects internally to provide an interface to seek or scan +** within the union of all segments of a b-tree. Hence the name. +** +** If the allocated Fts3MultiSegReader just seeks to a single entry in a +** segment b-tree (if the term is not a prefix or it is a prefix for which +** there exists prefix b-tree of the right length) then it may be traversed +** and merged incrementally. Otherwise, it has to be merged into an in-memory +** doclist and then traversed. +*/ +static void fts3EvalAllocateReaders( + Fts3Cursor *pCsr, + Fts3Expr *pExpr, + int *pnToken, /* OUT: Total number of tokens in phrase. */ + int *pnOr, /* OUT: Total number of OR nodes in expr. */ + int *pRc +){ + if( pExpr && SQLITE_OK==*pRc ){ + if( pExpr->eType==FTSQUERY_PHRASE ){ + int i; + int nToken = pExpr->pPhrase->nToken; + *pnToken += nToken; + for(i=0; ipPhrase->aToken[i]; + int rc = sqlite3Fts3TermSegReaderCursor(pCsr, + pToken->z, pToken->n, pToken->isPrefix, &pToken->pSegcsr + ); + if( rc!=SQLITE_OK ){ + *pRc = rc; + return; + } + } + assert( pExpr->pPhrase->iDoclistToken==0 ); + pExpr->pPhrase->iDoclistToken = -1; + }else{ + *pnOr += (pExpr->eType==FTSQUERY_OR); + fts3EvalAllocateReaders(pCsr, pExpr->pLeft, pnToken, pnOr, pRc); + fts3EvalAllocateReaders(pCsr, pExpr->pRight, pnToken, pnOr, pRc); + } + } +} + +static void fts3EvalPhraseMergeToken( + Fts3Table *pTab, + Fts3Phrase *p, + int iToken, + char *pList, + int nList +){ + assert( iToken!=p->iDoclistToken ); + + if( pList==0 ){ + sqlite3_free(p->doclist.aAll); + p->doclist.aAll = 0; + p->doclist.nAll = 0; + } + + else if( p->iDoclistToken<0 ){ + p->doclist.aAll = pList; + p->doclist.nAll = nList; + } + + else if( p->doclist.aAll==0 ){ + sqlite3_free(pList); + } + + else { + char *pLeft; + char *pRight; + int nLeft; + int nRight; + int nDiff; + + if( p->iDoclistTokendoclist.aAll; + nLeft = p->doclist.nAll; + pRight = pList; + nRight = nList; + nDiff = iToken - p->iDoclistToken; + }else{ + pRight = p->doclist.aAll; + nRight = p->doclist.nAll; + pLeft = pList; + nLeft = nList; + nDiff = p->iDoclistToken - iToken; + } + + fts3DoclistPhraseMerge(pTab->bDescIdx, nDiff, pLeft, nLeft, pRight,&nRight); + sqlite3_free(pLeft); + p->doclist.aAll = pRight; + p->doclist.nAll = nRight; + } + + if( iToken>p->iDoclistToken ) p->iDoclistToken = iToken; +} + +static int fts3EvalPhraseLoad( + Fts3Cursor *pCsr, + Fts3Phrase *p +){ + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + int iToken; + int rc = SQLITE_OK; + + for(iToken=0; rc==SQLITE_OK && iTokennToken; iToken++){ + Fts3PhraseToken *pToken = &p->aToken[iToken]; + assert( pToken->pDeferred==0 || pToken->pSegcsr==0 ); + + if( pToken->pSegcsr ){ + int nThis = 0; + char *pThis = 0; + rc = fts3TermSelect(pTab, pToken, p->iColumn, 1, &nThis, &pThis); + if( rc==SQLITE_OK ){ + fts3EvalPhraseMergeToken(pTab, p, iToken, pThis, nThis); + } + } + assert( pToken->pSegcsr==0 ); + } + + return rc; +} + +static int fts3EvalDeferredPhrase(Fts3Cursor *pCsr, Fts3Phrase *pPhrase){ + int iToken; + int rc = SQLITE_OK; + + int nMaxUndeferred = pPhrase->iDoclistToken; + char *aPoslist = 0; + int nPoslist = 0; + int iPrev = -1; + + assert( pPhrase->doclist.bFreeList==0 ); + + for(iToken=0; rc==SQLITE_OK && iTokennToken; iToken++){ + Fts3PhraseToken *pToken = &pPhrase->aToken[iToken]; + Fts3DeferredToken *pDeferred = pToken->pDeferred; + + if( pDeferred ){ + char *pList; + int nList; + rc = sqlite3Fts3DeferredTokenList(pDeferred, &pList, &nList); + if( rc!=SQLITE_OK ) return rc; + + if( pList==0 ){ + sqlite3_free(aPoslist); + pPhrase->doclist.pList = 0; + pPhrase->doclist.nList = 0; + return SQLITE_OK; + + }else if( aPoslist==0 ){ + aPoslist = pList; + nPoslist = nList; + + }else{ + char *aOut = pList; + char *p1 = aPoslist; + char *p2 = aOut; + + assert( iPrev>=0 ); + fts3PoslistPhraseMerge(&aOut, iToken-iPrev, 0, 1, &p1, &p2); + sqlite3_free(aPoslist); + aPoslist = pList; + nPoslist = aOut - aPoslist; + if( nPoslist==0 ){ + sqlite3_free(aPoslist); + pPhrase->doclist.pList = 0; + pPhrase->doclist.nList = 0; + return SQLITE_OK; + } + } + iPrev = iToken; + } + } + + if( iPrev>=0 ){ + if( nMaxUndeferred<0 ){ + pPhrase->doclist.pList = aPoslist; + pPhrase->doclist.nList = nPoslist; + pPhrase->doclist.iDocid = pCsr->iPrevId; + pPhrase->doclist.bFreeList = 1; + }else{ + int nDistance; + char *p1; + char *p2; + char *aOut; + + if( nMaxUndeferred>iPrev ){ + p1 = aPoslist; + p2 = pPhrase->doclist.pList; + nDistance = nMaxUndeferred - iPrev; + }else{ + p1 = pPhrase->doclist.pList; + p2 = aPoslist; + nDistance = iPrev - nMaxUndeferred; + } + + aOut = (char *)sqlite3_malloc(nPoslist+8); + if( !aOut ){ + sqlite3_free(aPoslist); + return SQLITE_NOMEM; + } + + pPhrase->doclist.pList = aOut; + if( fts3PoslistPhraseMerge(&aOut, nDistance, 0, 1, &p1, &p2) ){ + pPhrase->doclist.bFreeList = 1; + pPhrase->doclist.nList = (aOut - pPhrase->doclist.pList); + }else{ + sqlite3_free(aOut); + pPhrase->doclist.pList = 0; + pPhrase->doclist.nList = 0; + } + sqlite3_free(aPoslist); + } + } + + return SQLITE_OK; +} + +/* +** This function is called for each Fts3Phrase in a full-text query +** expression to initialize the mechanism for returning rows. Once this +** function has been called successfully on an Fts3Phrase, it may be +** used with fts3EvalPhraseNext() to iterate through the matching docids. +*/ +static int fts3EvalPhraseStart(Fts3Cursor *pCsr, int bOptOk, Fts3Phrase *p){ + int rc; + Fts3PhraseToken *pFirst = &p->aToken[0]; + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + + if( pCsr->bDesc==pTab->bDescIdx + && bOptOk==1 + && p->nToken==1 + && pFirst->pSegcsr + && pFirst->pSegcsr->bLookup + ){ + /* Use the incremental approach. */ + int iCol = (p->iColumn >= pTab->nColumn ? -1 : p->iColumn); + rc = sqlite3Fts3MsrIncrStart( + pTab, pFirst->pSegcsr, iCol, pFirst->z, pFirst->n); + p->bIncr = 1; + + }else{ + /* Load the full doclist for the phrase into memory. */ + rc = fts3EvalPhraseLoad(pCsr, p); + p->bIncr = 0; + } + + assert( rc!=SQLITE_OK || p->nToken<1 || p->aToken[0].pSegcsr==0 || p->bIncr ); + return rc; +} + +/* +** This function is used to iterate backwards (from the end to start) +** through doclists. +*/ +SQLITE_PRIVATE void sqlite3Fts3DoclistPrev( + int bDescIdx, /* True if the doclist is desc */ + char *aDoclist, /* Pointer to entire doclist */ + int nDoclist, /* Length of aDoclist in bytes */ + char **ppIter, /* IN/OUT: Iterator pointer */ + sqlite3_int64 *piDocid, /* IN/OUT: Docid pointer */ + int *pnList, /* IN/OUT: List length pointer */ + u8 *pbEof /* OUT: End-of-file flag */ +){ + char *p = *ppIter; + + assert( nDoclist>0 ); + assert( *pbEof==0 ); + assert( p || *piDocid==0 ); + assert( !p || (p>aDoclist && p<&aDoclist[nDoclist]) ); + + if( p==0 ){ + sqlite3_int64 iDocid = 0; + char *pNext = 0; + char *pDocid = aDoclist; + char *pEnd = &aDoclist[nDoclist]; + int iMul = 1; + + while( pDociddoclist; + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + + if( p->bIncr ){ + assert( p->nToken==1 ); + assert( pDL->pNextDocid==0 ); + rc = sqlite3Fts3MsrIncrNext(pTab, p->aToken[0].pSegcsr, + &pDL->iDocid, &pDL->pList, &pDL->nList + ); + if( rc==SQLITE_OK && !pDL->pList ){ + *pbEof = 1; + } + }else if( pCsr->bDesc!=pTab->bDescIdx && pDL->nAll ){ + sqlite3Fts3DoclistPrev(pTab->bDescIdx, pDL->aAll, pDL->nAll, + &pDL->pNextDocid, &pDL->iDocid, &pDL->nList, pbEof + ); + pDL->pList = pDL->pNextDocid; + }else{ + char *pIter; /* Used to iterate through aAll */ + char *pEnd = &pDL->aAll[pDL->nAll]; /* 1 byte past end of aAll */ + if( pDL->pNextDocid ){ + pIter = pDL->pNextDocid; + }else{ + pIter = pDL->aAll; + } + + if( pIter>=pEnd ){ + /* We have already reached the end of this doclist. EOF. */ + *pbEof = 1; + }else{ + sqlite3_int64 iDelta; + pIter += sqlite3Fts3GetVarint(pIter, &iDelta); + if( pTab->bDescIdx==0 || pDL->pNextDocid==0 ){ + pDL->iDocid += iDelta; + }else{ + pDL->iDocid -= iDelta; + } + pDL->pList = pIter; + fts3PoslistCopy(0, &pIter); + pDL->nList = (pIter - pDL->pList); + + /* pIter now points just past the 0x00 that terminates the position- + ** list for document pDL->iDocid. However, if this position-list was + ** edited in place by fts3EvalNearTrim2(), then pIter may not actually + ** point to the start of the next docid value. The following line deals + ** with this case by advancing pIter past the zero-padding added by + ** fts3EvalNearTrim2(). */ + while( pIterpNextDocid = pIter; + assert( pIter>=&pDL->aAll[pDL->nAll] || *pIter ); + *pbEof = 0; + } + } + + return rc; +} + +static void fts3EvalStartReaders( + Fts3Cursor *pCsr, + Fts3Expr *pExpr, + int bOptOk, + int *pRc +){ + if( pExpr && SQLITE_OK==*pRc ){ + if( pExpr->eType==FTSQUERY_PHRASE ){ + int i; + int nToken = pExpr->pPhrase->nToken; + for(i=0; ipPhrase->aToken[i].pDeferred==0 ) break; + } + pExpr->bDeferred = (i==nToken); + *pRc = fts3EvalPhraseStart(pCsr, bOptOk, pExpr->pPhrase); + }else{ + fts3EvalStartReaders(pCsr, pExpr->pLeft, bOptOk, pRc); + fts3EvalStartReaders(pCsr, pExpr->pRight, bOptOk, pRc); + pExpr->bDeferred = (pExpr->pLeft->bDeferred && pExpr->pRight->bDeferred); + } + } +} + +typedef struct Fts3TokenAndCost Fts3TokenAndCost; +struct Fts3TokenAndCost { + Fts3Phrase *pPhrase; /* The phrase the token belongs to */ + int iToken; /* Position of token in phrase */ + Fts3PhraseToken *pToken; /* The token itself */ + Fts3Expr *pRoot; + int nOvfl; + int iCol; /* The column the token must match */ +}; + +static void fts3EvalTokenCosts( + Fts3Cursor *pCsr, + Fts3Expr *pRoot, + Fts3Expr *pExpr, + Fts3TokenAndCost **ppTC, + Fts3Expr ***ppOr, + int *pRc +){ + if( *pRc==SQLITE_OK && pExpr ){ + if( pExpr->eType==FTSQUERY_PHRASE ){ + Fts3Phrase *pPhrase = pExpr->pPhrase; + int i; + for(i=0; *pRc==SQLITE_OK && inToken; i++){ + Fts3TokenAndCost *pTC = (*ppTC)++; + pTC->pPhrase = pPhrase; + pTC->iToken = i; + pTC->pRoot = pRoot; + pTC->pToken = &pPhrase->aToken[i]; + pTC->iCol = pPhrase->iColumn; + *pRc = sqlite3Fts3MsrOvfl(pCsr, pTC->pToken->pSegcsr, &pTC->nOvfl); + } + }else if( pExpr->eType!=FTSQUERY_NOT ){ + if( pExpr->eType==FTSQUERY_OR ){ + pRoot = pExpr->pLeft; + **ppOr = pRoot; + (*ppOr)++; + } + fts3EvalTokenCosts(pCsr, pRoot, pExpr->pLeft, ppTC, ppOr, pRc); + if( pExpr->eType==FTSQUERY_OR ){ + pRoot = pExpr->pRight; + **ppOr = pRoot; + (*ppOr)++; + } + fts3EvalTokenCosts(pCsr, pRoot, pExpr->pRight, ppTC, ppOr, pRc); + } + } +} + +static int fts3EvalAverageDocsize(Fts3Cursor *pCsr, int *pnPage){ + if( pCsr->nRowAvg==0 ){ + /* The average document size, which is required to calculate the cost + ** of each doclist, has not yet been determined. Read the required + ** data from the %_stat table to calculate it. + ** + ** Entry 0 of the %_stat table is a blob containing (nCol+1) FTS3 + ** varints, where nCol is the number of columns in the FTS3 table. + ** The first varint is the number of documents currently stored in + ** the table. The following nCol varints contain the total amount of + ** data stored in all rows of each column of the table, from left + ** to right. + */ + int rc; + Fts3Table *p = (Fts3Table*)pCsr->base.pVtab; + sqlite3_stmt *pStmt; + sqlite3_int64 nDoc = 0; + sqlite3_int64 nByte = 0; + const char *pEnd; + const char *a; + + rc = sqlite3Fts3SelectDoctotal(p, &pStmt); + if( rc!=SQLITE_OK ) return rc; + a = sqlite3_column_blob(pStmt, 0); + assert( a ); + + pEnd = &a[sqlite3_column_bytes(pStmt, 0)]; + a += sqlite3Fts3GetVarint(a, &nDoc); + while( anDoc = nDoc; + pCsr->nRowAvg = (int)(((nByte / nDoc) + p->nPgsz) / p->nPgsz); + assert( pCsr->nRowAvg>0 ); + rc = sqlite3_reset(pStmt); + if( rc!=SQLITE_OK ) return rc; + } + + *pnPage = pCsr->nRowAvg; + return SQLITE_OK; +} + +static int fts3EvalSelectDeferred( + Fts3Cursor *pCsr, + Fts3Expr *pRoot, + Fts3TokenAndCost *aTC, + int nTC +){ + int nDocSize = 0; + int nDocEst = 0; + int rc = SQLITE_OK; + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + int ii; + + int nOvfl = 0; + int nTerm = 0; + + for(ii=0; iinOvfl) + ){ + pTC = &aTC[jj]; + } + } + assert( pTC ); + + /* At this point pTC points to the cheapest remaining token. */ + if( ii==0 ){ + if( pTC->nOvfl ){ + nDocEst = (pTC->nOvfl * pTab->nPgsz + pTab->nPgsz) / 10; + }else{ + Fts3PhraseToken *pToken = pTC->pToken; + int nList = 0; + char *pList = 0; + rc = fts3TermSelect(pTab, pToken, pTC->iCol, 1, &nList, &pList); + assert( rc==SQLITE_OK || pList==0 ); + + if( rc==SQLITE_OK ){ + nDocEst = fts3DoclistCountDocids(1, pList, nList); + fts3EvalPhraseMergeToken(pTab, pTC->pPhrase, pTC->iToken,pList,nList); + } + } + }else{ + if( pTC->nOvfl>=(nDocEst*nDocSize) ){ + Fts3PhraseToken *pToken = pTC->pToken; + rc = sqlite3Fts3DeferToken(pCsr, pToken, pTC->iCol); + fts3SegReaderCursorFree(pToken->pSegcsr); + pToken->pSegcsr = 0; + } + nDocEst = 1 + (nDocEst/4); + } + pTC->pToken = 0; + } + + return rc; +} + +SQLITE_PRIVATE int sqlite3Fts3EvalStart(Fts3Cursor *pCsr, Fts3Expr *pExpr, int bOptOk){ + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + int rc = SQLITE_OK; + int nToken = 0; + int nOr = 0; + + /* Allocate a MultiSegReader for each token in the expression. */ + fts3EvalAllocateReaders(pCsr, pExpr, &nToken, &nOr, &rc); + + /* Call fts3EvalPhraseStart() on all phrases in the expression. TODO: + ** This call will eventually also be responsible for determining which + ** tokens are 'deferred' until the document text is loaded into memory. + ** + ** Each token in each phrase is dealt with using one of the following + ** three strategies: + ** + ** 1. Entire doclist loaded into memory as part of the + ** fts3EvalStartReaders() call. + ** + ** 2. Doclist loaded into memory incrementally, as part of each + ** sqlite3Fts3EvalNext() call. + ** + ** 3. Token doclist is never loaded. Instead, documents are loaded into + ** memory and scanned for the token as part of the sqlite3Fts3EvalNext() + ** call. This is known as a "deferred" token. + */ + + /* If bOptOk is true, check if there are any tokens that should be deferred. + */ + if( rc==SQLITE_OK && bOptOk && nToken>1 && pTab->bHasStat ){ + Fts3TokenAndCost *aTC; + Fts3Expr **apOr; + aTC = (Fts3TokenAndCost *)sqlite3_malloc( + sizeof(Fts3TokenAndCost) * nToken + + sizeof(Fts3Expr *) * nOr * 2 + ); + apOr = (Fts3Expr **)&aTC[nToken]; + + if( !aTC ){ + rc = SQLITE_NOMEM; + }else{ + int ii; + Fts3TokenAndCost *pTC = aTC; + Fts3Expr **ppOr = apOr; + + fts3EvalTokenCosts(pCsr, 0, pExpr, &pTC, &ppOr, &rc); + nToken = pTC-aTC; + nOr = ppOr-apOr; + + if( rc==SQLITE_OK ){ + rc = fts3EvalSelectDeferred(pCsr, 0, aTC, nToken); + for(ii=0; rc==SQLITE_OK && iidoclist.bFreeList ){ + sqlite3_free(pPhrase->doclist.pList); + } + pPhrase->doclist.pList = 0; + pPhrase->doclist.nList = 0; + pPhrase->doclist.bFreeList = 0; +} + +static int fts3EvalNearTrim2( + int nNear, + char *aTmp, /* Temporary space to use */ + char **paPoslist, /* IN/OUT: Position list */ + int *pnToken, /* IN/OUT: Tokens in phrase of *paPoslist */ + Fts3Phrase *pPhrase /* The phrase object to trim the doclist of */ +){ + int nParam1 = nNear + pPhrase->nToken; + int nParam2 = nNear + *pnToken; + int nNew; + char *p2; + char *pOut; + int res; + + assert( pPhrase->doclist.pList ); + + p2 = pOut = pPhrase->doclist.pList; + res = fts3PoslistNearMerge( + &pOut, aTmp, nParam1, nParam2, paPoslist, &p2 + ); + if( res ){ + nNew = (pOut - pPhrase->doclist.pList) - 1; + assert( pPhrase->doclist.pList[nNew]=='\0' ); + assert( nNew<=pPhrase->doclist.nList && nNew>0 ); + memset(&pPhrase->doclist.pList[nNew], 0, pPhrase->doclist.nList - nNew); + pPhrase->doclist.nList = nNew; + *paPoslist = pPhrase->doclist.pList; + *pnToken = pPhrase->nToken; + } + + return res; +} + +static int fts3EvalNearTest(Fts3Expr *pExpr, int *pRc){ + int res = 1; + + /* The following block runs if pExpr is the root of a NEAR query. + ** For example, the query: + ** + ** "w" NEAR "x" NEAR "y" NEAR "z" + ** + ** which is represented in tree form as: + ** + ** | + ** +--NEAR--+ <-- root of NEAR query + ** | | + ** +--NEAR--+ "z" + ** | | + ** +--NEAR--+ "y" + ** | | + ** "w" "x" + ** + ** The right-hand child of a NEAR node is always a phrase. The + ** left-hand child may be either a phrase or a NEAR node. There are + ** no exceptions to this. + */ + if( *pRc==SQLITE_OK + && pExpr->eType==FTSQUERY_NEAR + && pExpr->bEof==0 + && (pExpr->pParent==0 || pExpr->pParent->eType!=FTSQUERY_NEAR) + ){ + Fts3Expr *p; + int nTmp = 0; /* Bytes of temp space */ + char *aTmp; /* Temp space for PoslistNearMerge() */ + + /* Allocate temporary working space. */ + for(p=pExpr; p->pLeft; p=p->pLeft){ + nTmp += p->pRight->pPhrase->doclist.nList; + } + nTmp += p->pPhrase->doclist.nList; + aTmp = sqlite3_malloc(nTmp*2); + if( !aTmp ){ + *pRc = SQLITE_NOMEM; + res = 0; + }else{ + char *aPoslist = p->pPhrase->doclist.pList; + int nToken = p->pPhrase->nToken; + + for(p=p->pParent;res && p && p->eType==FTSQUERY_NEAR; p=p->pParent){ + Fts3Phrase *pPhrase = p->pRight->pPhrase; + int nNear = p->nNear; + res = fts3EvalNearTrim2(nNear, aTmp, &aPoslist, &nToken, pPhrase); + } + + aPoslist = pExpr->pRight->pPhrase->doclist.pList; + nToken = pExpr->pRight->pPhrase->nToken; + for(p=pExpr->pLeft; p && res; p=p->pLeft){ + int nNear = p->pParent->nNear; + Fts3Phrase *pPhrase = ( + p->eType==FTSQUERY_NEAR ? p->pRight->pPhrase : p->pPhrase + ); + res = fts3EvalNearTrim2(nNear, aTmp, &aPoslist, &nToken, pPhrase); + } + } + + sqlite3_free(aTmp); + } + + return res; +} + +/* +** This macro is used by the fts3EvalNext() function. The two arguments are +** 64-bit docid values. If the current query is "ORDER BY docid ASC", then +** the macro returns (i1 - i2). Or if it is "ORDER BY docid DESC", then +** it returns (i2 - i1). This allows the same code to be used for merging +** doclists in ascending or descending order. +*/ +#define DOCID_CMP(i1, i2) ((pCsr->bDesc?-1:1) * (i1-i2)) + +static void fts3EvalNext( + Fts3Cursor *pCsr, + Fts3Expr *pExpr, + int *pRc +){ + if( *pRc==SQLITE_OK ){ + assert( pExpr->bEof==0 ); + pExpr->bStart = 1; + + switch( pExpr->eType ){ + case FTSQUERY_NEAR: + case FTSQUERY_AND: { + Fts3Expr *pLeft = pExpr->pLeft; + Fts3Expr *pRight = pExpr->pRight; + assert( !pLeft->bDeferred || !pRight->bDeferred ); + if( pLeft->bDeferred ){ + fts3EvalNext(pCsr, pRight, pRc); + pExpr->iDocid = pRight->iDocid; + pExpr->bEof = pRight->bEof; + }else if( pRight->bDeferred ){ + fts3EvalNext(pCsr, pLeft, pRc); + pExpr->iDocid = pLeft->iDocid; + pExpr->bEof = pLeft->bEof; + }else{ + fts3EvalNext(pCsr, pLeft, pRc); + fts3EvalNext(pCsr, pRight, pRc); + + while( !pLeft->bEof && !pRight->bEof && *pRc==SQLITE_OK ){ + sqlite3_int64 iDiff = DOCID_CMP(pLeft->iDocid, pRight->iDocid); + if( iDiff==0 ) break; + if( iDiff<0 ){ + fts3EvalNext(pCsr, pLeft, pRc); + }else{ + fts3EvalNext(pCsr, pRight, pRc); + } + } + + pExpr->iDocid = pLeft->iDocid; + pExpr->bEof = (pLeft->bEof || pRight->bEof); + } + break; + } + + case FTSQUERY_OR: { + Fts3Expr *pLeft = pExpr->pLeft; + Fts3Expr *pRight = pExpr->pRight; + sqlite3_int64 iCmp = DOCID_CMP(pLeft->iDocid, pRight->iDocid); + + assert( pLeft->bStart || pLeft->iDocid==pRight->iDocid ); + assert( pRight->bStart || pLeft->iDocid==pRight->iDocid ); + + if( pRight->bEof || (pLeft->bEof==0 && iCmp<0) ){ + fts3EvalNext(pCsr, pLeft, pRc); + }else if( pLeft->bEof || (pRight->bEof==0 && iCmp>0) ){ + fts3EvalNext(pCsr, pRight, pRc); + }else{ + fts3EvalNext(pCsr, pLeft, pRc); + fts3EvalNext(pCsr, pRight, pRc); + } + + pExpr->bEof = (pLeft->bEof && pRight->bEof); + iCmp = DOCID_CMP(pLeft->iDocid, pRight->iDocid); + if( pRight->bEof || (pLeft->bEof==0 && iCmp<0) ){ + pExpr->iDocid = pLeft->iDocid; + }else{ + pExpr->iDocid = pRight->iDocid; + } + + break; + } + + case FTSQUERY_NOT: { + Fts3Expr *pLeft = pExpr->pLeft; + Fts3Expr *pRight = pExpr->pRight; + + if( pRight->bStart==0 ){ + fts3EvalNext(pCsr, pRight, pRc); + assert( *pRc!=SQLITE_OK || pRight->bStart ); + } + + fts3EvalNext(pCsr, pLeft, pRc); + if( pLeft->bEof==0 ){ + while( !*pRc + && !pRight->bEof + && DOCID_CMP(pLeft->iDocid, pRight->iDocid)>0 + ){ + fts3EvalNext(pCsr, pRight, pRc); + } + } + pExpr->iDocid = pLeft->iDocid; + pExpr->bEof = pLeft->bEof; + break; + } + + default: { + Fts3Phrase *pPhrase = pExpr->pPhrase; + fts3EvalZeroPoslist(pPhrase); + *pRc = fts3EvalPhraseNext(pCsr, pPhrase, &pExpr->bEof); + pExpr->iDocid = pPhrase->doclist.iDocid; + break; + } + } + } +} + +static int fts3EvalDeferredTest(Fts3Cursor *pCsr, Fts3Expr *pExpr, int *pRc){ + int bHit = 1; + if( *pRc==SQLITE_OK ){ + switch( pExpr->eType ){ + case FTSQUERY_NEAR: + case FTSQUERY_AND: + bHit = ( + fts3EvalDeferredTest(pCsr, pExpr->pLeft, pRc) + && fts3EvalDeferredTest(pCsr, pExpr->pRight, pRc) + && fts3EvalNearTest(pExpr, pRc) + ); + + /* If the NEAR expression does not match any rows, zero the doclist for + ** all phrases involved in the NEAR. This is because the snippet(), + ** offsets() and matchinfo() functions are not supposed to recognize + ** any instances of phrases that are part of unmatched NEAR queries. + ** For example if this expression: + ** + ** ... MATCH 'a OR (b NEAR c)' + ** + ** is matched against a row containing: + ** + ** 'a b d e' + ** + ** then any snippet() should ony highlight the "a" term, not the "b" + ** (as "b" is part of a non-matching NEAR clause). + */ + if( bHit==0 + && pExpr->eType==FTSQUERY_NEAR + && (pExpr->pParent==0 || pExpr->pParent->eType!=FTSQUERY_NEAR) + ){ + Fts3Expr *p; + for(p=pExpr; p->pPhrase==0; p=p->pLeft){ + if( p->pRight->iDocid==pCsr->iPrevId ){ + fts3EvalZeroPoslist(p->pRight->pPhrase); + } + } + if( p->iDocid==pCsr->iPrevId ){ + fts3EvalZeroPoslist(p->pPhrase); + } + } + + break; + + case FTSQUERY_OR: { + int bHit1 = fts3EvalDeferredTest(pCsr, pExpr->pLeft, pRc); + int bHit2 = fts3EvalDeferredTest(pCsr, pExpr->pRight, pRc); + bHit = bHit1 || bHit2; + break; + } + + case FTSQUERY_NOT: + bHit = ( + fts3EvalDeferredTest(pCsr, pExpr->pLeft, pRc) + && !fts3EvalDeferredTest(pCsr, pExpr->pRight, pRc) + ); + break; + + default: { + if( pCsr->pDeferred + && (pExpr->iDocid==pCsr->iPrevId || pExpr->bDeferred) + ){ + Fts3Phrase *pPhrase = pExpr->pPhrase; + assert( pExpr->bDeferred || pPhrase->doclist.bFreeList==0 ); + if( pExpr->bDeferred ){ + fts3EvalZeroPoslist(pPhrase); + } + *pRc = fts3EvalDeferredPhrase(pCsr, pPhrase); + bHit = (pPhrase->doclist.pList!=0); + pExpr->iDocid = pCsr->iPrevId; + }else{ + bHit = (pExpr->bEof==0 && pExpr->iDocid==pCsr->iPrevId); + } + break; + } + } + } + return bHit; +} + +/* +** Return 1 if both of the following are true: +** +** 1. *pRc is SQLITE_OK when this function returns, and +** +** 2. After scanning the current FTS table row for the deferred tokens, +** it is determined that the row does not match the query. +** +** Or, if no error occurs and it seems the current row does match the FTS +** query, return 0. +*/ +static int fts3EvalLoadDeferred(Fts3Cursor *pCsr, int *pRc){ + int rc = *pRc; + int bMiss = 0; + if( rc==SQLITE_OK ){ + if( pCsr->pDeferred ){ + rc = fts3CursorSeek(0, pCsr); + if( rc==SQLITE_OK ){ + rc = sqlite3Fts3CacheDeferredDoclists(pCsr); + } + } + bMiss = (0==fts3EvalDeferredTest(pCsr, pCsr->pExpr, &rc)); + sqlite3Fts3FreeDeferredDoclists(pCsr); + *pRc = rc; + } + return (rc==SQLITE_OK && bMiss); +} + +/* +** Advance to the next document that matches the FTS expression in +** Fts3Cursor.pExpr. +*/ +SQLITE_PRIVATE int sqlite3Fts3EvalNext(Fts3Cursor *pCsr){ + int rc = SQLITE_OK; /* Return Code */ + Fts3Expr *pExpr = pCsr->pExpr; + assert( pCsr->isEof==0 ); + if( pExpr==0 ){ + pCsr->isEof = 1; + }else{ + do { + if( pCsr->isRequireSeek==0 ){ + sqlite3_reset(pCsr->pStmt); + } + assert( sqlite3_data_count(pCsr->pStmt)==0 ); + fts3EvalNext(pCsr, pExpr, &rc); + pCsr->isEof = pExpr->bEof; + pCsr->isRequireSeek = 1; + pCsr->isMatchinfoNeeded = 1; + pCsr->iPrevId = pExpr->iDocid; + }while( pCsr->isEof==0 && fts3EvalLoadDeferred(pCsr, &rc) ); + } + return rc; +} + +/* +** Restart interation for expression pExpr so that the next call to +** sqlite3Fts3EvalNext() visits the first row. Do not allow incremental +** loading or merging of phrase doclists for this iteration. +** +** If *pRc is other than SQLITE_OK when this function is called, it is +** a no-op. If an error occurs within this function, *pRc is set to an +** SQLite error code before returning. +*/ +static void fts3EvalRestart( + Fts3Cursor *pCsr, + Fts3Expr *pExpr, + int *pRc +){ + if( pExpr && *pRc==SQLITE_OK ){ + Fts3Phrase *pPhrase = pExpr->pPhrase; + + if( pPhrase ){ + fts3EvalZeroPoslist(pPhrase); + if( pPhrase->bIncr ){ + assert( pPhrase->nToken==1 ); + assert( pPhrase->aToken[0].pSegcsr ); + sqlite3Fts3MsrIncrRestart(pPhrase->aToken[0].pSegcsr); + *pRc = fts3EvalPhraseStart(pCsr, 0, pPhrase); + } + + pPhrase->doclist.pNextDocid = 0; + pPhrase->doclist.iDocid = 0; + } + + pExpr->iDocid = 0; + pExpr->bEof = 0; + pExpr->bStart = 0; + + fts3EvalRestart(pCsr, pExpr->pLeft, pRc); + fts3EvalRestart(pCsr, pExpr->pRight, pRc); + } +} + +/* +** After allocating the Fts3Expr.aMI[] array for each phrase in the +** expression rooted at pExpr, the cursor iterates through all rows matched +** by pExpr, calling this function for each row. This function increments +** the values in Fts3Expr.aMI[] according to the position-list currently +** found in Fts3Expr.pPhrase->doclist.pList for each of the phrase +** expression nodes. +*/ +static void fts3EvalUpdateCounts(Fts3Expr *pExpr){ + if( pExpr ){ + Fts3Phrase *pPhrase = pExpr->pPhrase; + if( pPhrase && pPhrase->doclist.pList ){ + int iCol = 0; + char *p = pPhrase->doclist.pList; + + assert( *p ); + while( 1 ){ + u8 c = 0; + int iCnt = 0; + while( 0xFE & (*p | c) ){ + if( (c&0x80)==0 ) iCnt++; + c = *p++ & 0x80; + } + + /* aMI[iCol*3 + 1] = Number of occurrences + ** aMI[iCol*3 + 2] = Number of rows containing at least one instance + */ + pExpr->aMI[iCol*3 + 1] += iCnt; + pExpr->aMI[iCol*3 + 2] += (iCnt>0); + if( *p==0x00 ) break; + p++; + p += sqlite3Fts3GetVarint32(p, &iCol); + } + } + + fts3EvalUpdateCounts(pExpr->pLeft); + fts3EvalUpdateCounts(pExpr->pRight); + } +} + +/* +** Expression pExpr must be of type FTSQUERY_PHRASE. +** +** If it is not already allocated and populated, this function allocates and +** populates the Fts3Expr.aMI[] array for expression pExpr. If pExpr is part +** of a NEAR expression, then it also allocates and populates the same array +** for all other phrases that are part of the NEAR expression. +** +** SQLITE_OK is returned if the aMI[] array is successfully allocated and +** populated. Otherwise, if an error occurs, an SQLite error code is returned. +*/ +static int fts3EvalGatherStats( + Fts3Cursor *pCsr, /* Cursor object */ + Fts3Expr *pExpr /* FTSQUERY_PHRASE expression */ +){ + int rc = SQLITE_OK; /* Return code */ + + assert( pExpr->eType==FTSQUERY_PHRASE ); + if( pExpr->aMI==0 ){ + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + Fts3Expr *pRoot; /* Root of NEAR expression */ + Fts3Expr *p; /* Iterator used for several purposes */ + + sqlite3_int64 iPrevId = pCsr->iPrevId; + sqlite3_int64 iDocid; + u8 bEof; + + /* Find the root of the NEAR expression */ + pRoot = pExpr; + while( pRoot->pParent && pRoot->pParent->eType==FTSQUERY_NEAR ){ + pRoot = pRoot->pParent; + } + iDocid = pRoot->iDocid; + bEof = pRoot->bEof; + assert( pRoot->bStart ); + + /* Allocate space for the aMSI[] array of each FTSQUERY_PHRASE node */ + for(p=pRoot; p; p=p->pLeft){ + Fts3Expr *pE = (p->eType==FTSQUERY_PHRASE?p:p->pRight); + assert( pE->aMI==0 ); + pE->aMI = (u32 *)sqlite3_malloc(pTab->nColumn * 3 * sizeof(u32)); + if( !pE->aMI ) return SQLITE_NOMEM; + memset(pE->aMI, 0, pTab->nColumn * 3 * sizeof(u32)); + } + + fts3EvalRestart(pCsr, pRoot, &rc); + + while( pCsr->isEof==0 && rc==SQLITE_OK ){ + + do { + /* Ensure the %_content statement is reset. */ + if( pCsr->isRequireSeek==0 ) sqlite3_reset(pCsr->pStmt); + assert( sqlite3_data_count(pCsr->pStmt)==0 ); + + /* Advance to the next document */ + fts3EvalNext(pCsr, pRoot, &rc); + pCsr->isEof = pRoot->bEof; + pCsr->isRequireSeek = 1; + pCsr->isMatchinfoNeeded = 1; + pCsr->iPrevId = pRoot->iDocid; + }while( pCsr->isEof==0 + && pRoot->eType==FTSQUERY_NEAR + && fts3EvalLoadDeferred(pCsr, &rc) + ); + + if( rc==SQLITE_OK && pCsr->isEof==0 ){ + fts3EvalUpdateCounts(pRoot); + } + } + + pCsr->isEof = 0; + pCsr->iPrevId = iPrevId; + + if( bEof ){ + pRoot->bEof = bEof; + }else{ + /* Caution: pRoot may iterate through docids in ascending or descending + ** order. For this reason, even though it seems more defensive, the + ** do loop can not be written: + ** + ** do {...} while( pRoot->iDocidbEof==0 ); + }while( pRoot->iDocid!=iDocid && rc==SQLITE_OK ); + fts3EvalLoadDeferred(pCsr, &rc); + } + } + return rc; +} + +/* +** This function is used by the matchinfo() module to query a phrase +** expression node for the following information: +** +** 1. The total number of occurrences of the phrase in each column of +** the FTS table (considering all rows), and +** +** 2. For each column, the number of rows in the table for which the +** column contains at least one instance of the phrase. +** +** If no error occurs, SQLITE_OK is returned and the values for each column +** written into the array aiOut as follows: +** +** aiOut[iCol*3 + 1] = Number of occurrences +** aiOut[iCol*3 + 2] = Number of rows containing at least one instance +** +** Caveats: +** +** * If a phrase consists entirely of deferred tokens, then all output +** values are set to the number of documents in the table. In other +** words we assume that very common tokens occur exactly once in each +** column of each row of the table. +** +** * If a phrase contains some deferred tokens (and some non-deferred +** tokens), count the potential occurrence identified by considering +** the non-deferred tokens instead of actual phrase occurrences. +** +** * If the phrase is part of a NEAR expression, then only phrase instances +** that meet the NEAR constraint are included in the counts. +*/ +SQLITE_PRIVATE int sqlite3Fts3EvalPhraseStats( + Fts3Cursor *pCsr, /* FTS cursor handle */ + Fts3Expr *pExpr, /* Phrase expression */ + u32 *aiOut /* Array to write results into (see above) */ +){ + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + int rc = SQLITE_OK; + int iCol; + + if( pExpr->bDeferred && pExpr->pParent->eType!=FTSQUERY_NEAR ){ + assert( pCsr->nDoc>0 ); + for(iCol=0; iColnColumn; iCol++){ + aiOut[iCol*3 + 1] = (u32)pCsr->nDoc; + aiOut[iCol*3 + 2] = (u32)pCsr->nDoc; + } + }else{ + rc = fts3EvalGatherStats(pCsr, pExpr); + if( rc==SQLITE_OK ){ + assert( pExpr->aMI ); + for(iCol=0; iColnColumn; iCol++){ + aiOut[iCol*3 + 1] = pExpr->aMI[iCol*3 + 1]; + aiOut[iCol*3 + 2] = pExpr->aMI[iCol*3 + 2]; + } + } + } + + return rc; +} + +/* +** The expression pExpr passed as the second argument to this function +** must be of type FTSQUERY_PHRASE. +** +** The returned value is either NULL or a pointer to a buffer containing +** a position-list indicating the occurrences of the phrase in column iCol +** of the current row. +** +** More specifically, the returned buffer contains 1 varint for each +** occurence of the phrase in the column, stored using the normal (delta+2) +** compression and is terminated by either an 0x01 or 0x00 byte. For example, +** if the requested column contains "a b X c d X X" and the position-list +** for 'X' is requested, the buffer returned may contain: +** +** 0x04 0x05 0x03 0x01 or 0x04 0x05 0x03 0x00 +** +** This function works regardless of whether or not the phrase is deferred, +** incremental, or neither. +*/ +SQLITE_PRIVATE char *sqlite3Fts3EvalPhrasePoslist( + Fts3Cursor *pCsr, /* FTS3 cursor object */ + Fts3Expr *pExpr, /* Phrase to return doclist for */ + int iCol /* Column to return position list for */ +){ + Fts3Phrase *pPhrase = pExpr->pPhrase; + Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab; + char *pIter = pPhrase->doclist.pList; + int iThis; + + assert( iCol>=0 && iColnColumn ); + if( !pIter + || pExpr->bEof + || pExpr->iDocid!=pCsr->iPrevId + || (pPhrase->iColumnnColumn && pPhrase->iColumn!=iCol) + ){ + return 0; + } + + assert( pPhrase->doclist.nList>0 ); + if( *pIter==0x01 ){ + pIter++; + pIter += sqlite3Fts3GetVarint32(pIter, &iThis); + }else{ + iThis = 0; + } + while( iThisdoclist, and +** * any Fts3MultiSegReader objects held by phrase tokens. +*/ +SQLITE_PRIVATE void sqlite3Fts3EvalPhraseCleanup(Fts3Phrase *pPhrase){ + if( pPhrase ){ + int i; + sqlite3_free(pPhrase->doclist.aAll); + fts3EvalZeroPoslist(pPhrase); + memset(&pPhrase->doclist, 0, sizeof(Fts3Doclist)); + for(i=0; inToken; i++){ + fts3SegReaderCursorFree(pPhrase->aToken[i].pSegcsr); + pPhrase->aToken[i].pSegcsr = 0; + } + } +} + #endif /************** End of fts3.c ************************************************/ @@ -114486,7 +116451,6 @@ SQLITE_API int sqlite3_extension_init( ****************************************************************************** ** */ - #if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) @@ -114500,7 +116464,7 @@ struct Fts3auxTable { struct Fts3auxCursor { sqlite3_vtab_cursor base; /* Base class used by SQLite core */ - Fts3SegReaderCursor csr; /* Must be right after "base" */ + Fts3MultiSegReader csr; /* Must be right after "base" */ Fts3SegFilter filter; char *zStop; int nStop; /* Byte-length of string zStop */ @@ -114568,6 +116532,7 @@ static int fts3auxConnectMethod( p->pFts3Tab->zDb = (char *)&p->pFts3Tab[1]; p->pFts3Tab->zName = &p->pFts3Tab->zDb[nDb+1]; p->pFts3Tab->db = db; + p->pFts3Tab->nIndex = 1; memcpy((char *)p->pFts3Tab->zDb, zDb, nDb); memcpy((char *)p->pFts3Tab->zName, zFts3, nFts3); @@ -114814,6 +116779,7 @@ static int fts3auxFilterMethod( int isScan; UNUSED_PARAMETER(nVal); + UNUSED_PARAMETER(idxStr); assert( idxStr==0 ); assert( idxNum==FTS4AUX_EQ_CONSTRAINT || idxNum==0 @@ -114847,7 +116813,7 @@ static int fts3auxFilterMethod( if( pCsr->zStop==0 ) return SQLITE_NOMEM; } - rc = sqlite3Fts3SegReaderCursor(pFts3, FTS3_SEGCURSOR_ALL, + rc = sqlite3Fts3SegReaderCursor(pFts3, 0, FTS3_SEGCURSOR_ALL, pCsr->filter.zTerm, pCsr->filter.nTerm, 0, isScan, &pCsr->csr ); if( rc==SQLITE_OK ){ @@ -114931,7 +116897,10 @@ SQLITE_PRIVATE int sqlite3Fts3InitAux(sqlite3 *db){ 0, /* xCommit */ 0, /* xRollback */ 0, /* xFindFunction */ - 0 /* xRename */ + 0, /* xRename */ + 0, /* xSavepoint */ + 0, /* xRelease */ + 0 /* xRollbackTo */ }; int rc; /* Return code */ @@ -115023,12 +116992,21 @@ SQLITE_API int sqlite3_fts3_enable_parentheses = 0; #define SQLITE_FTS3_DEFAULT_NEAR_PARAM 10 +/* +** isNot: +** This variable is used by function getNextNode(). When getNextNode() is +** called, it sets ParseContext.isNot to true if the 'next node' is a +** FTSQUERY_PHRASE with a unary "-" attached to it. i.e. "mysql" in the +** FTS3 query "sqlite -mysql". Otherwise, ParseContext.isNot is set to +** zero. +*/ typedef struct ParseContext ParseContext; struct ParseContext { sqlite3_tokenizer *pTokenizer; /* Tokenizer module */ const char **azCol; /* Array of column names for fts3 table */ int nCol; /* Number of entries in azCol[] */ int iDefaultCol; /* Default column to query */ + int isNot; /* True if getNextNode() sees a unary - */ sqlite3_context *pCtx; /* Write error message here */ int nNest; /* Number of nested brackets */ }; @@ -115114,7 +117092,7 @@ static int getNextToken( iEnd++; } if( !sqlite3_fts3_enable_parentheses && iStart>0 && z[iStart-1]=='-' ){ - pRet->pPhrase->isNot = 1; + pParse->isNot = 1; } } nConsumed = iEnd; @@ -115166,36 +117144,55 @@ static int getNextString( char *zTemp = 0; int nTemp = 0; + const int nSpace = sizeof(Fts3Expr) + sizeof(Fts3Phrase); + int nToken = 0; + + /* The final Fts3Expr data structure, including the Fts3Phrase, + ** Fts3PhraseToken structures token buffers are all stored as a single + ** allocation so that the expression can be freed with a single call to + ** sqlite3_free(). Setting this up requires a two pass approach. + ** + ** The first pass, in the block below, uses a tokenizer cursor to iterate + ** through the tokens in the expression. This pass uses fts3ReallocOrFree() + ** to assemble data in two dynamic buffers: + ** + ** Buffer p: Points to the Fts3Expr structure, followed by the Fts3Phrase + ** structure, followed by the array of Fts3PhraseToken + ** structures. This pass only populates the Fts3PhraseToken array. + ** + ** Buffer zTemp: Contains copies of all tokens. + ** + ** The second pass, in the block that begins "if( rc==SQLITE_DONE )" below, + ** appends buffer zTemp to buffer p, and fills in the Fts3Expr and Fts3Phrase + ** structures. + */ rc = pModule->xOpen(pTokenizer, zInput, nInput, &pCursor); if( rc==SQLITE_OK ){ int ii; pCursor->pTokenizer = pTokenizer; for(ii=0; rc==SQLITE_OK; ii++){ - const char *zToken; - int nToken, iBegin, iEnd, iPos; - rc = pModule->xNext(pCursor, &zToken, &nToken, &iBegin, &iEnd, &iPos); + const char *zByte; + int nByte, iBegin, iEnd, iPos; + rc = pModule->xNext(pCursor, &zByte, &nByte, &iBegin, &iEnd, &iPos); if( rc==SQLITE_OK ){ - int nByte = sizeof(Fts3Expr) + sizeof(Fts3Phrase); - p = fts3ReallocOrFree(p, nByte+ii*sizeof(Fts3PhraseToken)); - zTemp = fts3ReallocOrFree(zTemp, nTemp + nToken); - if( !p || !zTemp ){ - goto no_mem; - } - if( ii==0 ){ - memset(p, 0, nByte); - p->pPhrase = (Fts3Phrase *)&p[1]; - } - p->pPhrase = (Fts3Phrase *)&p[1]; - memset(&p->pPhrase->aToken[ii], 0, sizeof(Fts3PhraseToken)); - p->pPhrase->nToken = ii+1; - p->pPhrase->aToken[ii].n = nToken; - memcpy(&zTemp[nTemp], zToken, nToken); - nTemp += nToken; - if( iEndpPhrase->aToken[ii].isPrefix = 1; - }else{ - p->pPhrase->aToken[ii].isPrefix = 0; - } + Fts3PhraseToken *pToken; + + p = fts3ReallocOrFree(p, nSpace + ii*sizeof(Fts3PhraseToken)); + if( !p ) goto no_mem; + + zTemp = fts3ReallocOrFree(zTemp, nTemp + nByte); + if( !zTemp ) goto no_mem; + + assert( nToken==ii ); + pToken = &((Fts3Phrase *)(&p[1]))->aToken[ii]; + memset(pToken, 0, sizeof(Fts3PhraseToken)); + + memcpy(&zTemp[nTemp], zByte, nByte); + nTemp += nByte; + + pToken->n = nByte; + pToken->isPrefix = (iEndpPhrase->nToken-1):0) * sizeof(Fts3PhraseToken); - p = fts3ReallocOrFree(p, nByte + nTemp); - if( !p ){ - goto no_mem; - } - if( zTemp ){ - zNew = &(((char *)p)[nByte]); - memcpy(zNew, zTemp, nTemp); - }else{ - memset(p, 0, nByte+nTemp); - } + char *zBuf = 0; + + p = fts3ReallocOrFree(p, nSpace + nToken*sizeof(Fts3PhraseToken) + nTemp); + if( !p ) goto no_mem; + memset(p, 0, (char *)&(((Fts3Phrase *)&p[1])->aToken[0])-(char *)p); + p->eType = FTSQUERY_PHRASE; p->pPhrase = (Fts3Phrase *)&p[1]; + p->pPhrase->iColumn = pParse->iDefaultCol; + p->pPhrase->nToken = nToken; + + zBuf = (char *)&p->pPhrase->aToken[nToken]; + memcpy(zBuf, zTemp, nTemp); + sqlite3_free(zTemp); + for(jj=0; jjpPhrase->nToken; jj++){ - p->pPhrase->aToken[jj].z = &zNew[nNew]; - nNew += p->pPhrase->aToken[jj].n; + p->pPhrase->aToken[jj].z = zBuf; + zBuf += p->pPhrase->aToken[jj].n; } - sqlite3_free(zTemp); - p->eType = FTSQUERY_PHRASE; - p->pPhrase->iColumn = pParse->iDefaultCol; rc = SQLITE_OK; } @@ -115283,6 +117276,8 @@ static int getNextNode( const char *zInput = z; int nInput = n; + pParse->isNot = 0; + /* Skip over any whitespace before checking for a keyword, an open or ** close bracket, or a quoted string. */ @@ -115501,7 +117496,7 @@ static int fts3ExprParse( int isPhrase; if( !sqlite3_fts3_enable_parentheses - && p->eType==FTSQUERY_PHRASE && p->pPhrase->isNot + && p->eType==FTSQUERY_PHRASE && pParse->isNot ){ /* Create an implicit NOT operator. */ Fts3Expr *pNot = fts3MallocZero(sizeof(Fts3Expr)); @@ -115519,7 +117514,6 @@ static int fts3ExprParse( p = pPrev; }else{ int eType = p->eType; - assert( eType!=FTSQUERY_PHRASE || !p->pPhrase->isNot ); isPhrase = (eType==FTSQUERY_PHRASE || p->pLeft); /* The isRequirePhrase variable is set to true if a phrase or @@ -115682,9 +117676,11 @@ SQLITE_PRIVATE int sqlite3Fts3ExprParse( */ SQLITE_PRIVATE void sqlite3Fts3ExprFree(Fts3Expr *p){ if( p ){ + assert( p->eType==FTSQUERY_PHRASE || p->pPhrase==0 ); sqlite3Fts3ExprFree(p->pLeft); sqlite3Fts3ExprFree(p->pRight); - sqlite3_free(p->aDoclist); + sqlite3Fts3EvalPhraseCleanup(p->pPhrase); + sqlite3_free(p->aMI); sqlite3_free(p); } } @@ -115741,7 +117737,7 @@ static char *exprToString(Fts3Expr *pExpr, char *zBuf){ Fts3Phrase *pPhrase = pExpr->pPhrase; int i; zBuf = sqlite3_mprintf( - "%zPHRASE %d %d", zBuf, pPhrase->iColumn, pPhrase->isNot); + "%zPHRASE %d 0", zBuf, pPhrase->iColumn); for(i=0; zBuf && inToken; i++){ zBuf = sqlite3_mprintf("%z %.*s%s", zBuf, pPhrase->aToken[i].n, pPhrase->aToken[i].z, @@ -116288,7 +118284,6 @@ SQLITE_PRIVATE void *sqlite3Fts3HashInsert( - /* ** Class derived from sqlite3_tokenizer */ @@ -116928,12 +118923,12 @@ SQLITE_PRIVATE void sqlite3Fts3PorterTokenizerModule( ** * The FTS3 module is being built into the core of ** SQLite (in which case SQLITE_ENABLE_FTS3 is defined). */ -#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) - #ifndef SQLITE_CORE SQLITE_EXTENSION_INIT1 #endif +#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) + /* ** Implementation of the SQL scalar function for accessing the underlying @@ -117057,7 +119052,7 @@ SQLITE_PRIVATE int sqlite3Fts3InitTokenizer( ){ int rc; char *z = (char *)zArg; - int n; + int n = 0; char *zCopy; char *zEnd; /* Pointer to nul-term of zCopy */ sqlite3_tokenizer_module *m; @@ -117422,7 +119417,6 @@ SQLITE_PRIVATE int sqlite3Fts3InitHashTable( - typedef struct simple_tokenizer { sqlite3_tokenizer base; char delim[128]; /* flag ASCII delimiters */ @@ -117659,14 +119653,40 @@ SQLITE_PRIVATE void sqlite3Fts3SimpleTokenizerModule( */ #define FTS3_NODE_PADDING (FTS3_VARINT_MAX*2) +/* +** Under certain circumstances, b-tree nodes (doclists) can be loaded into +** memory incrementally instead of all at once. This can be a big performance +** win (reduced IO and CPU) if SQLite stops calling the virtual table xNext() +** method before retrieving all query results (as may happen, for example, +** if a query has a LIMIT clause). +** +** Incremental loading is used for b-tree nodes FTS3_NODE_CHUNK_THRESHOLD +** bytes and larger. Nodes are loaded in chunks of FTS3_NODE_CHUNKSIZE bytes. +** The code is written so that the hard lower-limit for each of these values +** is 1. Clearly such small values would be inefficient, but can be useful +** for testing purposes. +** +** If this module is built with SQLITE_TEST defined, these constants may +** be overridden at runtime for testing purposes. File fts3_test.c contains +** a Tcl interface to read and write the values. +*/ +#ifdef SQLITE_TEST +int test_fts3_node_chunksize = (4*1024); +int test_fts3_node_chunk_threshold = (4*1024)*4; +# define FTS3_NODE_CHUNKSIZE test_fts3_node_chunksize +# define FTS3_NODE_CHUNK_THRESHOLD test_fts3_node_chunk_threshold +#else +# define FTS3_NODE_CHUNKSIZE (4*1024) +# define FTS3_NODE_CHUNK_THRESHOLD (FTS3_NODE_CHUNKSIZE*4) +#endif + typedef struct PendingList PendingList; typedef struct SegmentNode SegmentNode; typedef struct SegmentWriter SegmentWriter; /* -** Data structure used while accumulating terms in the pending-terms hash -** table. The hash table entry maps from term (a string) to a malloc'd -** instance of this structure. +** An instance of the following data structure is used to build doclists +** incrementally. See function fts3PendingListAppend() for details. */ struct PendingList { int nData; @@ -117697,7 +119717,6 @@ struct Fts3DeferredToken { ** ** sqlite3Fts3SegReaderNew() ** sqlite3Fts3SegReaderFree() -** sqlite3Fts3SegReaderCost() ** sqlite3Fts3SegReaderIterate() ** ** Methods used to manipulate Fts3SegReader structures: @@ -117716,6 +119735,9 @@ struct Fts3SegReader { char *aNode; /* Pointer to node data (or NULL) */ int nNode; /* Size of buffer at aNode (or 0) */ + int nPopulate; /* If >0, bytes of buffer aNode[] loaded */ + sqlite3_blob *pBlob; /* If not NULL, blob handle to read node */ + Fts3HashElem **ppNextElem; /* Variables set by fts3SegReaderNext(). These may be read directly @@ -117729,8 +119751,11 @@ struct Fts3SegReader { char *aDoclist; /* Pointer to doclist of current entry */ int nDoclist; /* Size of doclist in current entry */ - /* The following variables are used to iterate through the current doclist */ + /* The following variables are used by fts3SegReaderNextDocid() to iterate + ** through the current doclist (aDoclist/nDoclist). + */ char *pOffsetList; + int nOffsetList; /* For descending pending seg-readers only */ sqlite3_int64 iDocid; }; @@ -117768,6 +119793,14 @@ struct SegmentWriter { ** fts3NodeAddTerm() ** fts3NodeWrite() ** fts3NodeFree() +** +** When a b+tree is written to the database (either as a result of a merge +** or the pending-terms table being flushed), leaves are written into the +** database file as soon as they are completely populated. The interior of +** the tree is assembled in memory and written out only once all leaves have +** been populated and stored. This is Ok, as the b+-tree fanout is usually +** very large, meaning that the interior of the tree consumes relatively +** little memory. */ struct SegmentNode { SegmentNode *pParent; /* Parent node (or NULL for root node) */ @@ -117798,10 +119831,10 @@ struct SegmentNode { #define SQL_NEXT_SEGMENTS_ID 10 #define SQL_INSERT_SEGDIR 11 #define SQL_SELECT_LEVEL 12 -#define SQL_SELECT_ALL_LEVEL 13 +#define SQL_SELECT_LEVEL_RANGE 13 #define SQL_SELECT_LEVEL_COUNT 14 -#define SQL_SELECT_SEGDIR_COUNT_MAX 15 -#define SQL_DELETE_SEGDIR_BY_LEVEL 16 +#define SQL_SELECT_SEGDIR_MAX_LEVEL 15 +#define SQL_DELETE_SEGDIR_LEVEL 16 #define SQL_DELETE_SEGMENTS_RANGE 17 #define SQL_CONTENT_INSERT 18 #define SQL_DELETE_DOCSIZE 19 @@ -117810,6 +119843,11 @@ struct SegmentNode { #define SQL_SELECT_DOCTOTAL 22 #define SQL_REPLACE_DOCTOTAL 23 +#define SQL_SELECT_ALL_PREFIX_LEVEL 24 +#define SQL_DELETE_ALL_TERMS_SEGDIR 25 + +#define SQL_DELETE_SEGDIR_RANGE 26 + /* ** This function is used to obtain an SQLite prepared statement handle ** for the statement identified by the second argument. If successful, @@ -117845,10 +119883,11 @@ static int fts3SqlStmt( /* 12 */ "SELECT idx, start_block, leaves_end_block, end_block, root " "FROM %Q.'%q_segdir' WHERE level = ? ORDER BY idx ASC", /* 13 */ "SELECT idx, start_block, leaves_end_block, end_block, root " - "FROM %Q.'%q_segdir' ORDER BY level DESC, idx ASC", + "FROM %Q.'%q_segdir' WHERE level BETWEEN ? AND ?" + "ORDER BY level DESC, idx ASC", /* 14 */ "SELECT count(*) FROM %Q.'%q_segdir' WHERE level = ?", -/* 15 */ "SELECT count(*), max(level) FROM %Q.'%q_segdir'", +/* 15 */ "SELECT max(level) FROM %Q.'%q_segdir' WHERE level BETWEEN ? AND ?", /* 16 */ "DELETE FROM %Q.'%q_segdir' WHERE level = ?", /* 17 */ "DELETE FROM %Q.'%q_segments' WHERE blockid BETWEEN ? AND ?", @@ -117858,6 +119897,11 @@ static int fts3SqlStmt( /* 21 */ "SELECT size FROM %Q.'%q_docsize' WHERE docid=?", /* 22 */ "SELECT value FROM %Q.'%q_stat' WHERE id=0", /* 23 */ "REPLACE INTO %Q.'%q_stat' VALUES(0,?)", +/* 24 */ "", +/* 25 */ "", + +/* 26 */ "DELETE FROM %Q.'%q_segdir' WHERE level BETWEEN ? AND ?", + }; int rc = SQLITE_OK; sqlite3_stmt *pStmt; @@ -117914,7 +119958,7 @@ static int fts3SelectDocsize( rc = sqlite3_step(pStmt); if( rc!=SQLITE_ROW || sqlite3_column_type(pStmt, 0)!=SQLITE_BLOB ){ rc = sqlite3_reset(pStmt); - if( rc==SQLITE_OK ) rc = SQLITE_CORRUPT; + if( rc==SQLITE_OK ) rc = SQLITE_CORRUPT_VTAB; pStmt = 0; }else{ rc = SQLITE_OK; @@ -118013,14 +120057,32 @@ SQLITE_PRIVATE int sqlite3Fts3ReadLock(Fts3Table *p){ ** 3: end_block ** 4: root */ -SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(Fts3Table *p, int iLevel, sqlite3_stmt **ppStmt){ +SQLITE_PRIVATE int sqlite3Fts3AllSegdirs( + Fts3Table *p, /* FTS3 table */ + int iIndex, /* Index for p->aIndex[] */ + int iLevel, /* Level to select */ + sqlite3_stmt **ppStmt /* OUT: Compiled statement */ +){ int rc; sqlite3_stmt *pStmt = 0; + + assert( iLevel==FTS3_SEGCURSOR_ALL || iLevel>=0 ); + assert( iLevel=0 && iIndexnIndex ); + if( iLevel<0 ){ - rc = fts3SqlStmt(p, SQL_SELECT_ALL_LEVEL, &pStmt, 0); + /* "SELECT * FROM %_segdir WHERE level BETWEEN ? AND ? ORDER BY ..." */ + rc = fts3SqlStmt(p, SQL_SELECT_LEVEL_RANGE, &pStmt, 0); + if( rc==SQLITE_OK ){ + sqlite3_bind_int(pStmt, 1, iIndex*FTS3_SEGDIR_MAXLEVEL); + sqlite3_bind_int(pStmt, 2, (iIndex+1)*FTS3_SEGDIR_MAXLEVEL-1); + } }else{ + /* "SELECT * FROM %_segdir WHERE level = ? ORDER BY ..." */ rc = fts3SqlStmt(p, SQL_SELECT_LEVEL, &pStmt, 0); - if( rc==SQLITE_OK ) sqlite3_bind_int(pStmt, 1, iLevel); + if( rc==SQLITE_OK ){ + sqlite3_bind_int(pStmt, 1, iLevel+iIndex*FTS3_SEGDIR_MAXLEVEL); + } } *ppStmt = pStmt; return rc; @@ -118135,6 +120197,47 @@ static int fts3PendingListAppend( return 0; } +/* +** Free a PendingList object allocated by fts3PendingListAppend(). +*/ +static void fts3PendingListDelete(PendingList *pList){ + sqlite3_free(pList); +} + +/* +** Add an entry to one of the pending-terms hash tables. +*/ +static int fts3PendingTermsAddOne( + Fts3Table *p, + int iCol, + int iPos, + Fts3Hash *pHash, /* Pending terms hash table to add entry to */ + const char *zToken, + int nToken +){ + PendingList *pList; + int rc = SQLITE_OK; + + pList = (PendingList *)fts3HashFind(pHash, zToken, nToken); + if( pList ){ + p->nPendingData -= (pList->nData + nToken + sizeof(Fts3HashElem)); + } + if( fts3PendingListAppend(&pList, p->iPrevDocid, iCol, iPos, &rc) ){ + if( pList==fts3HashInsert(pHash, zToken, nToken, pList) ){ + /* Malloc failed while inserting the new entry. This can only + ** happen if there was no previous entry for this token. + */ + assert( 0==fts3HashFind(pHash, zToken, nToken) ); + sqlite3_free(pList); + rc = SQLITE_NOMEM; + } + } + if( rc==SQLITE_OK ){ + p->nPendingData += (pList->nData + nToken + sizeof(Fts3HashElem)); + } + return rc; +} + /* ** Tokenize the nul-terminated string zText and add all tokens to the ** pending-terms hash-table. The docid used is that currently stored in @@ -118165,6 +120268,14 @@ static int fts3PendingTermsAdd( assert( pTokenizer && pModule ); + /* If the user has inserted a NULL value, this function may be called with + ** zText==0. In this case, add zero token entries to the hash table and + ** return early. */ + if( zText==0 ){ + *pnWord = 0; + return SQLITE_OK; + } + rc = pModule->xOpen(pTokenizer, zText, -1, &pCsr); if( rc!=SQLITE_OK ){ return rc; @@ -118175,8 +120286,7 @@ static int fts3PendingTermsAdd( while( SQLITE_OK==rc && SQLITE_OK==(rc = xNext(pCsr, &zToken, &nToken, &iStart, &iEnd, &iPos)) ){ - PendingList *pList; - + int i; if( iPos>=nWord ) nWord = iPos+1; /* Positions cannot be negative; we use -1 as a terminator internally. @@ -118187,22 +120297,19 @@ static int fts3PendingTermsAdd( break; } - pList = (PendingList *)fts3HashFind(&p->pendingTerms, zToken, nToken); - if( pList ){ - p->nPendingData -= (pList->nData + nToken + sizeof(Fts3HashElem)); - } - if( fts3PendingListAppend(&pList, p->iPrevDocid, iCol, iPos, &rc) ){ - if( pList==fts3HashInsert(&p->pendingTerms, zToken, nToken, pList) ){ - /* Malloc failed while inserting the new entry. This can only - ** happen if there was no previous entry for this token. - */ - assert( 0==fts3HashFind(&p->pendingTerms, zToken, nToken) ); - sqlite3_free(pList); - rc = SQLITE_NOMEM; - } - } - if( rc==SQLITE_OK ){ - p->nPendingData += (pList->nData + nToken + sizeof(Fts3HashElem)); + /* Add the term to the terms index */ + rc = fts3PendingTermsAddOne( + p, iCol, iPos, &p->aIndex[0].hPending, zToken, nToken + ); + + /* Add the term to each of the prefix indexes that it is not too + ** short for. */ + for(i=1; rc==SQLITE_OK && inIndex; i++){ + struct Fts3Index *pIndex = &p->aIndex[i]; + if( nTokennPrefix ) continue; + rc = fts3PendingTermsAddOne( + p, iCol, iPos, &pIndex->hPending, zToken, pIndex->nPrefix + ); } } @@ -118232,14 +120339,19 @@ static int fts3PendingTermsDocid(Fts3Table *p, sqlite_int64 iDocid){ } /* -** Discard the contents of the pending-terms hash table. +** Discard the contents of the pending-terms hash tables. */ SQLITE_PRIVATE void sqlite3Fts3PendingTermsClear(Fts3Table *p){ - Fts3HashElem *pElem; - for(pElem=fts3HashFirst(&p->pendingTerms); pElem; pElem=fts3HashNext(pElem)){ - sqlite3_free(fts3HashData(pElem)); + int i; + for(i=0; inIndex; i++){ + Fts3HashElem *pElem; + Fts3Hash *pHash = &p->aIndex[i].hPending; + for(pElem=fts3HashFirst(pHash); pElem; pElem=fts3HashNext(pElem)){ + PendingList *pList = (PendingList *)fts3HashData(pElem); + fts3PendingListDelete(pList); + } + fts3HashClear(pHash); } - fts3HashClear(&p->pendingTerms); p->nPendingData = 0; } @@ -118255,11 +120367,9 @@ static int fts3InsertTerms(Fts3Table *p, sqlite3_value **apVal, u32 *aSz){ int i; /* Iterator variable */ for(i=2; inColumn+2; i++){ const char *zText = (const char *)sqlite3_value_text(apVal[i]); - if( zText ){ - int rc = fts3PendingTermsAdd(p, zText, i-2, &aSz[i-2]); - if( rc!=SQLITE_OK ){ - return rc; - } + int rc = fts3PendingTermsAdd(p, zText, i-2, &aSz[i-2]); + if( rc!=SQLITE_OK ){ + return rc; } aSz[p->nColumn] += sqlite3_value_bytes(apVal[i]); } @@ -118364,14 +120474,14 @@ static int fts3DeleteAll(Fts3Table *p){ static void fts3DeleteTerms( int *pRC, /* Result code */ Fts3Table *p, /* The FTS table to delete from */ - sqlite3_value **apVal, /* apVal[] contains the docid to be deleted */ + sqlite3_value *pRowid, /* The docid to be deleted */ u32 *aSz /* Sizes of deleted document written here */ ){ int rc; sqlite3_stmt *pSelect; if( *pRC ) return; - rc = fts3SqlStmt(p, SQL_SELECT_CONTENT_BY_ROWID, &pSelect, apVal); + rc = fts3SqlStmt(p, SQL_SELECT_CONTENT_BY_ROWID, &pSelect, &pRowid); if( rc==SQLITE_OK ){ if( SQLITE_ROW==sqlite3_step(pSelect) ){ int i; @@ -118397,7 +120507,7 @@ static void fts3DeleteTerms( ** Forward declaration to account for the circular dependency between ** functions fts3SegmentMerge() and fts3AllocateSegdirIdx(). */ -static int fts3SegmentMerge(Fts3Table *, int); +static int fts3SegmentMerge(Fts3Table *, int, int); /* ** This function allocates a new level iLevel index in the segdir table. @@ -118414,7 +120524,12 @@ static int fts3SegmentMerge(Fts3Table *, int); ** If successful, *piIdx is set to the allocated index slot and SQLITE_OK ** returned. Otherwise, an SQLite error code is returned. */ -static int fts3AllocateSegdirIdx(Fts3Table *p, int iLevel, int *piIdx){ +static int fts3AllocateSegdirIdx( + Fts3Table *p, + int iIndex, /* Index for p->aIndex */ + int iLevel, + int *piIdx +){ int rc; /* Return Code */ sqlite3_stmt *pNextIdx; /* Query for next idx at level iLevel */ int iNext = 0; /* Result of query pNextIdx */ @@ -118422,7 +120537,7 @@ static int fts3AllocateSegdirIdx(Fts3Table *p, int iLevel, int *piIdx){ /* Set variable iNext to the next available segdir index at level iLevel. */ rc = fts3SqlStmt(p, SQL_NEXT_SEGMENT_INDEX, &pNextIdx, 0); if( rc==SQLITE_OK ){ - sqlite3_bind_int(pNextIdx, 1, iLevel); + sqlite3_bind_int(pNextIdx, 1, iIndex*FTS3_SEGDIR_MAXLEVEL + iLevel); if( SQLITE_ROW==sqlite3_step(pNextIdx) ){ iNext = sqlite3_column_int(pNextIdx, 0); } @@ -118436,7 +120551,7 @@ static int fts3AllocateSegdirIdx(Fts3Table *p, int iLevel, int *piIdx){ ** if iNext is less than FTS3_MERGE_COUNT, allocate index iNext. */ if( iNext>=FTS3_MERGE_COUNT ){ - rc = fts3SegmentMerge(p, iLevel); + rc = fts3SegmentMerge(p, iIndex, iLevel); *piIdx = 0; }else{ *piIdx = iNext; @@ -118477,7 +120592,8 @@ SQLITE_PRIVATE int sqlite3Fts3ReadBlock( Fts3Table *p, /* FTS3 table handle */ sqlite3_int64 iBlockid, /* Access the row with blockid=$iBlockid */ char **paBlob, /* OUT: Blob data in malloc'd buffer */ - int *pnBlob /* OUT: Size of blob data */ + int *pnBlob, /* OUT: Size of blob data */ + int *pnLoad /* OUT: Bytes actually loaded */ ){ int rc; /* Return code */ @@ -118498,11 +120614,16 @@ SQLITE_PRIVATE int sqlite3Fts3ReadBlock( if( rc==SQLITE_OK ){ int nByte = sqlite3_blob_bytes(p->pSegments); + *pnBlob = nByte; if( paBlob ){ char *aByte = sqlite3_malloc(nByte + FTS3_NODE_PADDING); if( !aByte ){ rc = SQLITE_NOMEM; }else{ + if( pnLoad && nByte>(FTS3_NODE_CHUNK_THRESHOLD) ){ + nByte = FTS3_NODE_CHUNKSIZE; + *pnLoad = nByte; + } rc = sqlite3_blob_read(p->pSegments, aByte, nByte, 0); memset(&aByte[nByte], 0, FTS3_NODE_PADDING); if( rc!=SQLITE_OK ){ @@ -118512,7 +120633,6 @@ SQLITE_PRIVATE int sqlite3Fts3ReadBlock( } *paBlob = aByte; } - *pnBlob = nByte; } return rc; @@ -118526,13 +120646,55 @@ SQLITE_PRIVATE void sqlite3Fts3SegmentsClose(Fts3Table *p){ sqlite3_blob_close(p->pSegments); p->pSegments = 0; } + +static int fts3SegReaderIncrRead(Fts3SegReader *pReader){ + int nRead; /* Number of bytes to read */ + int rc; /* Return code */ + + nRead = MIN(pReader->nNode - pReader->nPopulate, FTS3_NODE_CHUNKSIZE); + rc = sqlite3_blob_read( + pReader->pBlob, + &pReader->aNode[pReader->nPopulate], + nRead, + pReader->nPopulate + ); + + if( rc==SQLITE_OK ){ + pReader->nPopulate += nRead; + memset(&pReader->aNode[pReader->nPopulate], 0, FTS3_NODE_PADDING); + if( pReader->nPopulate==pReader->nNode ){ + sqlite3_blob_close(pReader->pBlob); + pReader->pBlob = 0; + pReader->nPopulate = 0; + } + } + return rc; +} + +static int fts3SegReaderRequire(Fts3SegReader *pReader, char *pFrom, int nByte){ + int rc = SQLITE_OK; + assert( !pReader->pBlob + || (pFrom>=pReader->aNode && pFrom<&pReader->aNode[pReader->nNode]) + ); + while( pReader->pBlob && rc==SQLITE_OK + && (pFrom - pReader->aNode + nByte)>pReader->nPopulate + ){ + rc = fts3SegReaderIncrRead(pReader); + } + return rc; +} /* ** Move the iterator passed as the first argument to the next term in the ** segment. If successful, SQLITE_OK is returned. If there is no next term, ** SQLITE_DONE. Otherwise, an SQLite error code. */ -static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ +static int fts3SegReaderNext( + Fts3Table *p, + Fts3SegReader *pReader, + int bIncr +){ + int rc; /* Return code of various sub-routines */ char *pNext; /* Cursor variable */ int nPrefix; /* Number of bytes in term prefix */ int nSuffix; /* Number of bytes in term suffix */ @@ -118544,7 +120706,6 @@ static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ } if( !pNext || pNext>=&pReader->aNode[pReader->nNode] ){ - int rc; /* Return code from Fts3ReadBlock() */ if( fts3SegReaderIsPending(pReader) ){ Fts3HashElem *pElem = *(pReader->ppNextElem); @@ -118564,6 +120725,8 @@ static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ if( !fts3SegReaderIsRootOnly(pReader) ){ sqlite3_free(pReader->aNode); + sqlite3_blob_close(pReader->pBlob); + pReader->pBlob = 0; } pReader->aNode = 0; @@ -118575,21 +120738,31 @@ static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ } rc = sqlite3Fts3ReadBlock( - p, ++pReader->iCurrentBlock, &pReader->aNode, &pReader->nNode + p, ++pReader->iCurrentBlock, &pReader->aNode, &pReader->nNode, + (bIncr ? &pReader->nPopulate : 0) ); if( rc!=SQLITE_OK ) return rc; + assert( pReader->pBlob==0 ); + if( bIncr && pReader->nPopulatenNode ){ + pReader->pBlob = p->pSegments; + p->pSegments = 0; + } pNext = pReader->aNode; } + + assert( !fts3SegReaderIsPending(pReader) ); + + rc = fts3SegReaderRequire(pReader, pNext, FTS3_VARINT_MAX*2); + if( rc!=SQLITE_OK ) return rc; /* Because of the FTS3_NODE_PADDING bytes of padding, the following is - ** safe (no risk of overread) even if the node data is corrupted. - */ + ** safe (no risk of overread) even if the node data is corrupted. */ pNext += sqlite3Fts3GetVarint32(pNext, &nPrefix); pNext += sqlite3Fts3GetVarint32(pNext, &nSuffix); if( nPrefix<0 || nSuffix<=0 || &pNext[nSuffix]>&pReader->aNode[pReader->nNode] ){ - return SQLITE_CORRUPT; + return SQLITE_CORRUPT_VTAB; } if( nPrefix+nSuffix>pReader->nTermAlloc ){ @@ -118601,6 +120774,10 @@ static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ pReader->zTerm = zNew; pReader->nTermAlloc = nNew; } + + rc = fts3SegReaderRequire(pReader, pNext, nSuffix+FTS3_VARINT_MAX); + if( rc!=SQLITE_OK ) return rc; + memcpy(&pReader->zTerm[nPrefix], pNext, nSuffix); pReader->nTerm = nPrefix+nSuffix; pNext += nSuffix; @@ -118613,9 +120790,9 @@ static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ ** of these statements is untrue, then the data structure is corrupt. */ if( &pReader->aDoclist[pReader->nDoclist]>&pReader->aNode[pReader->nNode] - || pReader->aDoclist[pReader->nDoclist-1] + || (pReader->nPopulate==0 && pReader->aDoclist[pReader->nDoclist-1]) ){ - return SQLITE_CORRUPT; + return SQLITE_CORRUPT_VTAB; } return SQLITE_OK; } @@ -118624,12 +120801,26 @@ static int fts3SegReaderNext(Fts3Table *p, Fts3SegReader *pReader){ ** Set the SegReader to point to the first docid in the doclist associated ** with the current term. */ -static void fts3SegReaderFirstDocid(Fts3SegReader *pReader){ - int n; +static int fts3SegReaderFirstDocid(Fts3Table *pTab, Fts3SegReader *pReader){ + int rc = SQLITE_OK; assert( pReader->aDoclist ); assert( !pReader->pOffsetList ); - n = sqlite3Fts3GetVarint(pReader->aDoclist, &pReader->iDocid); - pReader->pOffsetList = &pReader->aDoclist[n]; + if( pTab->bDescIdx && fts3SegReaderIsPending(pReader) ){ + u8 bEof = 0; + pReader->iDocid = 0; + pReader->nOffsetList = 0; + sqlite3Fts3DoclistPrev(0, + pReader->aDoclist, pReader->nDoclist, &pReader->pOffsetList, + &pReader->iDocid, &pReader->nOffsetList, &bEof + ); + }else{ + rc = fts3SegReaderRequire(pReader, pReader->aDoclist, FTS3_VARINT_MAX); + if( rc==SQLITE_OK ){ + int n = sqlite3Fts3GetVarint(pReader->aDoclist, &pReader->iDocid); + pReader->pOffsetList = &pReader->aDoclist[n]; + } + } + return rc; } /* @@ -118642,128 +120833,125 @@ static void fts3SegReaderFirstDocid(Fts3SegReader *pReader){ ** *pnOffsetList is set to the length of the set of column-offset ** lists, not including the nul-terminator byte. For example: */ -static void fts3SegReaderNextDocid( - Fts3SegReader *pReader, - char **ppOffsetList, - int *pnOffsetList +static int fts3SegReaderNextDocid( + Fts3Table *pTab, + Fts3SegReader *pReader, /* Reader to advance to next docid */ + char **ppOffsetList, /* OUT: Pointer to current position-list */ + int *pnOffsetList /* OUT: Length of *ppOffsetList in bytes */ ){ + int rc = SQLITE_OK; char *p = pReader->pOffsetList; char c = 0; - /* Pointer p currently points at the first byte of an offset list. The - ** following two lines advance it to point one byte past the end of - ** the same offset list. - */ - while( *p | c ) c = *p++ & 0x80; - p++; - - /* If required, populate the output variables with a pointer to and the - ** size of the previous offset-list. - */ - if( ppOffsetList ){ - *ppOffsetList = pReader->pOffsetList; - *pnOffsetList = (int)(p - pReader->pOffsetList - 1); - } + assert( p ); - /* If there are no more entries in the doclist, set pOffsetList to - ** NULL. Otherwise, set Fts3SegReader.iDocid to the next docid and - ** Fts3SegReader.pOffsetList to point to the next offset list before - ** returning. - */ - if( p>=&pReader->aDoclist[pReader->nDoclist] ){ - pReader->pOffsetList = 0; + if( pTab->bDescIdx && fts3SegReaderIsPending(pReader) ){ + /* A pending-terms seg-reader for an FTS4 table that uses order=desc. + ** Pending-terms doclists are always built up in ascending order, so + ** we have to iterate through them backwards here. */ + u8 bEof = 0; + if( ppOffsetList ){ + *ppOffsetList = pReader->pOffsetList; + *pnOffsetList = pReader->nOffsetList - 1; + } + sqlite3Fts3DoclistPrev(0, + pReader->aDoclist, pReader->nDoclist, &p, &pReader->iDocid, + &pReader->nOffsetList, &bEof + ); + if( bEof ){ + pReader->pOffsetList = 0; + }else{ + pReader->pOffsetList = p; + } }else{ - sqlite3_int64 iDelta; - pReader->pOffsetList = p + sqlite3Fts3GetVarint(p, &iDelta); - pReader->iDocid += iDelta; - } -} + char *pEnd = &pReader->aDoclist[pReader->nDoclist]; -/* -** This function is called to estimate the amount of data that will be -** loaded from the disk If SegReaderIterate() is called on this seg-reader, -** in units of average document size. -** -** This can be used as follows: If the caller has a small doclist that -** contains references to N documents, and is considering merging it with -** a large doclist (size X "average documents"), it may opt not to load -** the large doclist if X>N. -*/ -SQLITE_PRIVATE int sqlite3Fts3SegReaderCost( - Fts3Cursor *pCsr, /* FTS3 cursor handle */ - Fts3SegReader *pReader, /* Segment-reader handle */ - int *pnCost /* IN/OUT: Number of bytes read */ -){ - Fts3Table *p = (Fts3Table*)pCsr->base.pVtab; - int rc = SQLITE_OK; /* Return code */ - int nCost = 0; /* Cost in bytes to return */ - int pgsz = p->nPgsz; /* Database page size */ - - /* If this seg-reader is reading the pending-terms table, or if all data - ** for the segment is stored on the root page of the b-tree, then the cost - ** is zero. In this case all required data is already in main memory. - */ - if( p->bHasStat - && !fts3SegReaderIsPending(pReader) - && !fts3SegReaderIsRootOnly(pReader) - ){ - int nBlob = 0; - sqlite3_int64 iBlock; - - if( pCsr->nRowAvg==0 ){ - /* The average document size, which is required to calculate the cost - ** of each doclist, has not yet been determined. Read the required - ** data from the %_stat table to calculate it. - ** - ** Entry 0 of the %_stat table is a blob containing (nCol+1) FTS3 - ** varints, where nCol is the number of columns in the FTS3 table. - ** The first varint is the number of documents currently stored in - ** the table. The following nCol varints contain the total amount of - ** data stored in all rows of each column of the table, from left - ** to right. + /* Pointer p currently points at the first byte of an offset list. The + ** following block advances it to point one byte past the end of + ** the same offset list. */ + while( 1 ){ + + /* The following line of code (and the "p++" below the while() loop) is + ** normally all that is required to move pointer p to the desired + ** position. The exception is if this node is being loaded from disk + ** incrementally and pointer "p" now points to the first byte passed + ** the populated part of pReader->aNode[]. */ - sqlite3_stmt *pStmt; - sqlite3_int64 nDoc = 0; - sqlite3_int64 nByte = 0; - const char *pEnd; - const char *a; - - rc = sqlite3Fts3SelectDoctotal(p, &pStmt); - if( rc!=SQLITE_OK ) return rc; - a = sqlite3_column_blob(pStmt, 0); - assert( a ); - - pEnd = &a[sqlite3_column_bytes(pStmt, 0)]; - a += sqlite3Fts3GetVarint(a, &nDoc); - while( anRowAvg = (int)(((nByte / nDoc) + pgsz) / pgsz); - assert( pCsr->nRowAvg>0 ); - rc = sqlite3_reset(pStmt); + while( *p | c ) c = *p++ & 0x80; + assert( *p==0 ); + + if( pReader->pBlob==0 || p<&pReader->aNode[pReader->nPopulate] ) break; + rc = fts3SegReaderIncrRead(pReader); if( rc!=SQLITE_OK ) return rc; } + p++; + + /* If required, populate the output variables with a pointer to and the + ** size of the previous offset-list. + */ + if( ppOffsetList ){ + *ppOffsetList = pReader->pOffsetList; + *pnOffsetList = (int)(p - pReader->pOffsetList - 1); + } - /* Assume that a blob flows over onto overflow pages if it is larger - ** than (pgsz-35) bytes in size (the file-format documentation - ** confirms this). + while( piStartBlock; iBlock<=pReader->iLeafEndBlock; iBlock++){ - rc = sqlite3Fts3ReadBlock(p, iBlock, 0, &nBlob); - if( rc!=SQLITE_OK ) break; - if( (nBlob+35)>pgsz ){ - int nOvfl = (nBlob + 34)/pgsz; - nCost += ((nOvfl + pCsr->nRowAvg - 1)/pCsr->nRowAvg); + if( p>=pEnd ){ + pReader->pOffsetList = 0; + }else{ + rc = fts3SegReaderRequire(pReader, p, FTS3_VARINT_MAX); + if( rc==SQLITE_OK ){ + sqlite3_int64 iDelta; + pReader->pOffsetList = p + sqlite3Fts3GetVarint(p, &iDelta); + if( pTab->bDescIdx ){ + pReader->iDocid -= iDelta; + }else{ + pReader->iDocid += iDelta; + } } } } - *pnCost += nCost; + return SQLITE_OK; +} + + +SQLITE_PRIVATE int sqlite3Fts3MsrOvfl( + Fts3Cursor *pCsr, + Fts3MultiSegReader *pMsr, + int *pnOvfl +){ + Fts3Table *p = (Fts3Table*)pCsr->base.pVtab; + int nOvfl = 0; + int ii; + int rc = SQLITE_OK; + int pgsz = p->nPgsz; + + assert( p->bHasStat ); + assert( pgsz>0 ); + + for(ii=0; rc==SQLITE_OK && iinSegment; ii++){ + Fts3SegReader *pReader = pMsr->apSegment[ii]; + if( !fts3SegReaderIsPending(pReader) + && !fts3SegReaderIsRootOnly(pReader) + ){ + sqlite3_int64 jj; + for(jj=pReader->iStartBlock; jj<=pReader->iLeafEndBlock; jj++){ + int nBlob; + rc = sqlite3Fts3ReadBlock(p, jj, 0, &nBlob, 0); + if( rc!=SQLITE_OK ) break; + if( (nBlob+35)>pgsz ){ + nOvfl += (nBlob + 34)/pgsz; + } + } + } + } + *pnOvfl = nOvfl; return rc; } @@ -118776,6 +120964,7 @@ SQLITE_PRIVATE void sqlite3Fts3SegReaderFree(Fts3SegReader *pReader){ sqlite3_free(pReader->zTerm); if( !fts3SegReaderIsRootOnly(pReader) ){ sqlite3_free(pReader->aNode); + sqlite3_blob_close(pReader->pBlob); } } sqlite3_free(pReader); @@ -118852,24 +121041,42 @@ static int fts3CompareElemByTerm(const void *lhs, const void *rhs){ /* ** This function is used to allocate an Fts3SegReader that iterates through ** a subset of the terms stored in the Fts3Table.pendingTerms array. +** +** If the isPrefixIter parameter is zero, then the returned SegReader iterates +** through each term in the pending-terms table. Or, if isPrefixIter is +** non-zero, it iterates through each term and its prefixes. For example, if +** the pending terms hash table contains the terms "sqlite", "mysql" and +** "firebird", then the iterator visits the following 'terms' (in the order +** shown): +** +** f fi fir fire fireb firebi firebir firebird +** m my mys mysq mysql +** s sq sql sqli sqlit sqlite +** +** Whereas if isPrefixIter is zero, the terms visited are: +** +** firebird mysql sqlite */ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending( Fts3Table *p, /* Virtual table handle */ + int iIndex, /* Index for p->aIndex */ const char *zTerm, /* Term to search for */ int nTerm, /* Size of buffer zTerm */ - int isPrefix, /* True for a term-prefix query */ + int bPrefix, /* True for a prefix iterator */ Fts3SegReader **ppReader /* OUT: SegReader for pending-terms */ ){ Fts3SegReader *pReader = 0; /* Fts3SegReader object to return */ Fts3HashElem **aElem = 0; /* Array of term hash entries to scan */ int nElem = 0; /* Size of array at aElem */ int rc = SQLITE_OK; /* Return Code */ + Fts3Hash *pHash; - if( isPrefix ){ + pHash = &p->aIndex[iIndex].hPending; + if( bPrefix ){ int nAlloc = 0; /* Size of allocated array at aElem */ Fts3HashElem *pE = 0; /* Iterator variable */ - for(pE=fts3HashFirst(&p->pendingTerms); pE; pE=fts3HashNext(pE)){ + for(pE=fts3HashFirst(pHash); pE; pE=fts3HashNext(pE)){ char *zKey = (char *)fts3HashKey(pE); int nKey = fts3HashKeysize(pE); if( nTerm==0 || (nKey>=nTerm && 0==memcmp(zKey, zTerm, nTerm)) ){ @@ -118886,6 +121093,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending( } aElem = aElem2; } + aElem[nElem++] = pE; } } @@ -118899,7 +121107,9 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending( } }else{ - Fts3HashElem *pE = fts3HashFindElem(&p->pendingTerms, zTerm, nTerm); + /* The query is a simple term lookup that matches at most one term in + ** the index. All that is required is a straight hash-lookup. */ + Fts3HashElem *pE = fts3HashFindElem(pHash, zTerm, nTerm); if( pE ){ aElem = &pE; nElem = 1; @@ -118919,7 +121129,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending( } } - if( isPrefix ){ + if( bPrefix ){ sqlite3_free(aElem); } *ppReader = pReader; @@ -118983,6 +121193,18 @@ static int fts3SegReaderDoclistCmp(Fts3SegReader *pLhs, Fts3SegReader *pRhs){ assert( pLhs->aNode && pRhs->aNode ); return rc; } +static int fts3SegReaderDoclistCmpRev(Fts3SegReader *pLhs, Fts3SegReader *pRhs){ + int rc = (pLhs->pOffsetList==0)-(pRhs->pOffsetList==0); + if( rc==0 ){ + if( pLhs->iDocid==pRhs->iDocid ){ + rc = pRhs->iIdx - pLhs->iIdx; + }else{ + rc = (pLhs->iDocid < pRhs->iDocid) ? 1 : -1; + } + } + assert( pLhs->aNode && pRhs->aNode ); + return rc; +} /* ** Compare the term that the Fts3SegReader object passed as the first argument @@ -119511,16 +121733,16 @@ static void fts3SegWriterFree(SegmentWriter *pWriter){ ** The first value in the apVal[] array is assumed to contain an integer. ** This function tests if there exist any documents with docid values that ** are different from that integer. i.e. if deleting the document with docid -** apVal[0] would mean the FTS3 table were empty. +** pRowid would mean the FTS3 table were empty. ** ** If successful, *pisEmpty is set to true if the table is empty except for -** document apVal[0], or false otherwise, and SQLITE_OK is returned. If an +** document pRowid, or false otherwise, and SQLITE_OK is returned. If an ** error occurs, an SQLite error code is returned. */ -static int fts3IsEmpty(Fts3Table *p, sqlite3_value **apVal, int *pisEmpty){ +static int fts3IsEmpty(Fts3Table *p, sqlite3_value *pRowid, int *pisEmpty){ sqlite3_stmt *pStmt; int rc; - rc = fts3SqlStmt(p, SQL_IS_EMPTY, &pStmt, apVal); + rc = fts3SqlStmt(p, SQL_IS_EMPTY, &pStmt, &pRowid); if( rc==SQLITE_OK ){ if( SQLITE_ROW==sqlite3_step(pStmt) ){ *pisEmpty = sqlite3_column_int(pStmt, 0); @@ -119531,21 +121753,30 @@ static int fts3IsEmpty(Fts3Table *p, sqlite3_value **apVal, int *pisEmpty){ } /* -** Set *pnSegment to the total number of segments in the database. Set -** *pnMax to the largest segment level in the database (segment levels -** are stored in the 'level' column of the %_segdir table). +** Set *pnMax to the largest segment level in the database for the index +** iIndex. +** +** Segment levels are stored in the 'level' column of the %_segdir table. ** ** Return SQLITE_OK if successful, or an SQLite error code if not. */ -static int fts3SegmentCountMax(Fts3Table *p, int *pnSegment, int *pnMax){ +static int fts3SegmentMaxLevel(Fts3Table *p, int iIndex, int *pnMax){ sqlite3_stmt *pStmt; int rc; + assert( iIndex>=0 && iIndexnIndex ); - rc = fts3SqlStmt(p, SQL_SELECT_SEGDIR_COUNT_MAX, &pStmt, 0); + /* Set pStmt to the compiled version of: + ** + ** SELECT max(level) FROM %Q.'%q_segdir' WHERE level BETWEEN ? AND ? + ** + ** (1024 is actually the value of macro FTS3_SEGDIR_PREFIXLEVEL_STR). + */ + rc = fts3SqlStmt(p, SQL_SELECT_SEGDIR_MAX_LEVEL, &pStmt, 0); if( rc!=SQLITE_OK ) return rc; + sqlite3_bind_int(pStmt, 1, iIndex*FTS3_SEGDIR_MAXLEVEL); + sqlite3_bind_int(pStmt, 2, (iIndex+1)*FTS3_SEGDIR_MAXLEVEL - 1); if( SQLITE_ROW==sqlite3_step(pStmt) ){ - *pnSegment = sqlite3_column_int(pStmt, 0); - *pnMax = sqlite3_column_int(pStmt, 1); + *pnMax = sqlite3_column_int(pStmt, 0); } return sqlite3_reset(pStmt); } @@ -119566,6 +121797,7 @@ static int fts3SegmentCountMax(Fts3Table *p, int *pnSegment, int *pnMax){ */ static int fts3DeleteSegdir( Fts3Table *p, /* Virtual table handle */ + int iIndex, /* Index for p->aIndex */ int iLevel, /* Level of %_segdir entries to delete */ Fts3SegReader **apSegment, /* Array of SegReader objects */ int nReader /* Size of array apSegment */ @@ -119588,20 +121820,25 @@ static int fts3DeleteSegdir( return rc; } + assert( iLevel>=0 || iLevel==FTS3_SEGCURSOR_ALL ); if( iLevel==FTS3_SEGCURSOR_ALL ){ - fts3SqlExec(&rc, p, SQL_DELETE_ALL_SEGDIR, 0); - }else if( iLevel==FTS3_SEGCURSOR_PENDING ){ - sqlite3Fts3PendingTermsClear(p); + rc = fts3SqlStmt(p, SQL_DELETE_SEGDIR_RANGE, &pDelete, 0); + if( rc==SQLITE_OK ){ + sqlite3_bind_int(pDelete, 1, iIndex*FTS3_SEGDIR_MAXLEVEL); + sqlite3_bind_int(pDelete, 2, (iIndex+1) * FTS3_SEGDIR_MAXLEVEL - 1); + } }else{ - assert( iLevel>=0 ); - rc = fts3SqlStmt(p, SQL_DELETE_SEGDIR_BY_LEVEL, &pDelete, 0); + rc = fts3SqlStmt(p, SQL_DELETE_SEGDIR_LEVEL, &pDelete, 0); if( rc==SQLITE_OK ){ - sqlite3_bind_int(pDelete, 1, iLevel); - sqlite3_step(pDelete); - rc = sqlite3_reset(pDelete); + sqlite3_bind_int(pDelete, 1, iIndex*FTS3_SEGDIR_MAXLEVEL + iLevel); } } + if( rc==SQLITE_OK ){ + sqlite3_step(pDelete); + rc = sqlite3_reset(pDelete); + } + return rc; } @@ -119648,15 +121885,106 @@ static void fts3ColumnFilter( *pnList = nList; } -SQLITE_PRIVATE int sqlite3Fts3SegReaderStart( +/* +** Cache data in the Fts3MultiSegReader.aBuffer[] buffer (overwriting any +** existing data). Grow the buffer if required. +** +** If successful, return SQLITE_OK. Otherwise, if an OOM error is encountered +** trying to resize the buffer, return SQLITE_NOMEM. +*/ +static int fts3MsrBufferData( + Fts3MultiSegReader *pMsr, /* Multi-segment-reader handle */ + char *pList, + int nList +){ + if( nList>pMsr->nBuffer ){ + char *pNew; + pMsr->nBuffer = nList*2; + pNew = (char *)sqlite3_realloc(pMsr->aBuffer, pMsr->nBuffer); + if( !pNew ) return SQLITE_NOMEM; + pMsr->aBuffer = pNew; + } + + memcpy(pMsr->aBuffer, pList, nList); + return SQLITE_OK; +} + +SQLITE_PRIVATE int sqlite3Fts3MsrIncrNext( Fts3Table *p, /* Virtual table handle */ - Fts3SegReaderCursor *pCsr, /* Cursor object */ - Fts3SegFilter *pFilter /* Restrictions on range of iteration */ + Fts3MultiSegReader *pMsr, /* Multi-segment-reader handle */ + sqlite3_int64 *piDocid, /* OUT: Docid value */ + char **paPoslist, /* OUT: Pointer to position list */ + int *pnPoslist /* OUT: Size of position list in bytes */ +){ + int nMerge = pMsr->nAdvance; + Fts3SegReader **apSegment = pMsr->apSegment; + int (*xCmp)(Fts3SegReader *, Fts3SegReader *) = ( + p->bDescIdx ? fts3SegReaderDoclistCmpRev : fts3SegReaderDoclistCmp + ); + + if( nMerge==0 ){ + *paPoslist = 0; + return SQLITE_OK; + } + + while( 1 ){ + Fts3SegReader *pSeg; + pSeg = pMsr->apSegment[0]; + + if( pSeg->pOffsetList==0 ){ + *paPoslist = 0; + break; + }else{ + int rc; + char *pList; + int nList; + int j; + sqlite3_int64 iDocid = apSegment[0]->iDocid; + + rc = fts3SegReaderNextDocid(p, apSegment[0], &pList, &nList); + j = 1; + while( rc==SQLITE_OK + && jpOffsetList + && apSegment[j]->iDocid==iDocid + ){ + rc = fts3SegReaderNextDocid(p, apSegment[j], 0, 0); + j++; + } + if( rc!=SQLITE_OK ) return rc; + fts3SegReaderSort(pMsr->apSegment, nMerge, j, xCmp); + + if( pMsr->iColFilter>=0 ){ + fts3ColumnFilter(pMsr->iColFilter, &pList, &nList); + } + + if( nList>0 ){ + if( fts3SegReaderIsPending(apSegment[0]) ){ + rc = fts3MsrBufferData(pMsr, pList, nList+1); + if( rc!=SQLITE_OK ) return rc; + *paPoslist = pMsr->aBuffer; + assert( (pMsr->aBuffer[nList] & 0xFE)==0x00 ); + }else{ + *paPoslist = pList; + } + *piDocid = iDocid; + *pnPoslist = nList; + break; + } + } + } + + return SQLITE_OK; +} + +static int fts3SegReaderStart( + Fts3Table *p, /* Virtual table handle */ + Fts3MultiSegReader *pCsr, /* Cursor object */ + const char *zTerm, /* Term searched for (or NULL) */ + int nTerm /* Length of zTerm in bytes */ ){ int i; - - /* Initialize the cursor object */ - pCsr->pFilter = pFilter; + int nSeg = pCsr->nSegment; /* If the Fts3SegFilter defines a specific term (or term prefix) to search ** for, then advance each segment iterator until it points to a term of @@ -119664,24 +121992,105 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStart( ** unnecessary merge/sort operations for the case where single segment ** b-tree leaf nodes contain more than one term. */ - for(i=0; inSegment; i++){ - int nTerm = pFilter->nTerm; - const char *zTerm = pFilter->zTerm; + for(i=0; pCsr->bRestart==0 && inSegment; i++){ Fts3SegReader *pSeg = pCsr->apSegment[i]; do { - int rc = fts3SegReaderNext(p, pSeg); + int rc = fts3SegReaderNext(p, pSeg, 0); if( rc!=SQLITE_OK ) return rc; }while( zTerm && fts3SegReaderTermCmp(pSeg, zTerm, nTerm)<0 ); } - fts3SegReaderSort( - pCsr->apSegment, pCsr->nSegment, pCsr->nSegment, fts3SegReaderCmp); + fts3SegReaderSort(pCsr->apSegment, nSeg, nSeg, fts3SegReaderCmp); return SQLITE_OK; } +SQLITE_PRIVATE int sqlite3Fts3SegReaderStart( + Fts3Table *p, /* Virtual table handle */ + Fts3MultiSegReader *pCsr, /* Cursor object */ + Fts3SegFilter *pFilter /* Restrictions on range of iteration */ +){ + pCsr->pFilter = pFilter; + return fts3SegReaderStart(p, pCsr, pFilter->zTerm, pFilter->nTerm); +} + +SQLITE_PRIVATE int sqlite3Fts3MsrIncrStart( + Fts3Table *p, /* Virtual table handle */ + Fts3MultiSegReader *pCsr, /* Cursor object */ + int iCol, /* Column to match on. */ + const char *zTerm, /* Term to iterate through a doclist for */ + int nTerm /* Number of bytes in zTerm */ +){ + int i; + int rc; + int nSegment = pCsr->nSegment; + int (*xCmp)(Fts3SegReader *, Fts3SegReader *) = ( + p->bDescIdx ? fts3SegReaderDoclistCmpRev : fts3SegReaderDoclistCmp + ); + + assert( pCsr->pFilter==0 ); + assert( zTerm && nTerm>0 ); + + /* Advance each segment iterator until it points to the term zTerm/nTerm. */ + rc = fts3SegReaderStart(p, pCsr, zTerm, nTerm); + if( rc!=SQLITE_OK ) return rc; + + /* Determine how many of the segments actually point to zTerm/nTerm. */ + for(i=0; iapSegment[i]; + if( !pSeg->aNode || fts3SegReaderTermCmp(pSeg, zTerm, nTerm) ){ + break; + } + } + pCsr->nAdvance = i; + + /* Advance each of the segments to point to the first docid. */ + for(i=0; inAdvance; i++){ + rc = fts3SegReaderFirstDocid(p, pCsr->apSegment[i]); + if( rc!=SQLITE_OK ) return rc; + } + fts3SegReaderSort(pCsr->apSegment, i, i, xCmp); + + assert( iCol<0 || iColnColumn ); + pCsr->iColFilter = iCol; + + return SQLITE_OK; +} + +/* +** This function is called on a MultiSegReader that has been started using +** sqlite3Fts3MsrIncrStart(). One or more calls to MsrIncrNext() may also +** have been made. Calling this function puts the MultiSegReader in such +** a state that if the next two calls are: +** +** sqlite3Fts3SegReaderStart() +** sqlite3Fts3SegReaderStep() +** +** then the entire doclist for the term is available in +** MultiSegReader.aDoclist/nDoclist. +*/ +SQLITE_PRIVATE int sqlite3Fts3MsrIncrRestart(Fts3MultiSegReader *pCsr){ + int i; /* Used to iterate through segment-readers */ + + assert( pCsr->zTerm==0 ); + assert( pCsr->nTerm==0 ); + assert( pCsr->aDoclist==0 ); + assert( pCsr->nDoclist==0 ); + + pCsr->nAdvance = 0; + pCsr->bRestart = 1; + for(i=0; inSegment; i++){ + pCsr->apSegment[i]->pOffsetList = 0; + pCsr->apSegment[i]->nOffsetList = 0; + pCsr->apSegment[i]->iDocid = 0; + } + + return SQLITE_OK; +} + + SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( Fts3Table *p, /* Virtual table handle */ - Fts3SegReaderCursor *pCsr /* Cursor object */ + Fts3MultiSegReader *pCsr /* Cursor object */ ){ int rc = SQLITE_OK; @@ -119694,6 +122103,9 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( Fts3SegReader **apSegment = pCsr->apSegment; int nSegment = pCsr->nSegment; Fts3SegFilter *pFilter = pCsr->pFilter; + int (*xCmp)(Fts3SegReader *, Fts3SegReader *) = ( + p->bDescIdx ? fts3SegReaderDoclistCmpRev : fts3SegReaderDoclistCmp + ); if( pCsr->nSegment==0 ) return SQLITE_OK; @@ -119705,7 +122117,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( ** forward. Then sort the list in order of current term again. */ for(i=0; inAdvance; i++){ - rc = fts3SegReaderNext(p, apSegment[i]); + rc = fts3SegReaderNext(p, apSegment[i], 0); if( rc!=SQLITE_OK ) return rc; } fts3SegReaderSort(apSegment, nSegment, pCsr->nAdvance, fts3SegReaderCmp); @@ -119744,10 +122156,18 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( } assert( isIgnoreEmpty || (isRequirePos && !isColFilter) ); - if( nMerge==1 && !isIgnoreEmpty ){ - pCsr->aDoclist = apSegment[0]->aDoclist; + if( nMerge==1 + && !isIgnoreEmpty + && (p->bDescIdx==0 || fts3SegReaderIsPending(apSegment[0])==0) + ){ pCsr->nDoclist = apSegment[0]->nDoclist; - rc = SQLITE_ROW; + if( fts3SegReaderIsPending(apSegment[0]) ){ + rc = fts3MsrBufferData(pCsr, apSegment[0]->aDoclist, pCsr->nDoclist); + pCsr->aDoclist = pCsr->aBuffer; + }else{ + pCsr->aDoclist = apSegment[0]->aDoclist; + } + if( rc==SQLITE_OK ) rc = SQLITE_ROW; }else{ int nDoclist = 0; /* Size of doclist */ sqlite3_int64 iPrev = 0; /* Previous docid stored in doclist */ @@ -119757,22 +122177,22 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( ** and a single term returned with the merged doclist. */ for(i=0; ipOffsetList ){ int j; /* Number of segments that share a docid */ char *pList; int nList; int nByte; sqlite3_int64 iDocid = apSegment[0]->iDocid; - fts3SegReaderNextDocid(apSegment[0], &pList, &nList); + fts3SegReaderNextDocid(p, apSegment[0], &pList, &nList); j = 1; while( jpOffsetList && apSegment[j]->iDocid==iDocid ){ - fts3SegReaderNextDocid(apSegment[j], 0, 0); + fts3SegReaderNextDocid(p, apSegment[j], 0, 0); j++; } @@ -119781,7 +122201,19 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( } if( !isIgnoreEmpty || nList>0 ){ - nByte = sqlite3Fts3VarintLen(iDocid-iPrev) + (isRequirePos?nList+1:0); + + /* Calculate the 'docid' delta value to write into the merged + ** doclist. */ + sqlite3_int64 iDelta; + if( p->bDescIdx && nDoclist>0 ){ + iDelta = iPrev - iDocid; + }else{ + iDelta = iDocid - iPrev; + } + assert( iDelta>0 || (nDoclist==0 && iDelta==iDocid) ); + assert( nDoclist>0 || iDelta==iDocid ); + + nByte = sqlite3Fts3VarintLen(iDelta) + (isRequirePos?nList+1:0); if( nDoclist+nByte>pCsr->nBuffer ){ char *aNew; pCsr->nBuffer = (nDoclist+nByte)*2; @@ -119791,9 +122223,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( } pCsr->aBuffer = aNew; } - nDoclist += sqlite3Fts3PutVarint( - &pCsr->aBuffer[nDoclist], iDocid-iPrev - ); + nDoclist += sqlite3Fts3PutVarint(&pCsr->aBuffer[nDoclist], iDelta); iPrev = iDocid; if( isRequirePos ){ memcpy(&pCsr->aBuffer[nDoclist], pList, nList); @@ -119802,7 +122232,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( } } - fts3SegReaderSort(apSegment, nMerge, j, fts3SegReaderDoclistCmp); + fts3SegReaderSort(apSegment, nMerge, j, xCmp); } if( nDoclist>0 ){ pCsr->aDoclist = pCsr->aBuffer; @@ -119816,8 +122246,9 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep( return rc; } + SQLITE_PRIVATE void sqlite3Fts3SegReaderFinish( - Fts3SegReaderCursor *pCsr /* Cursor object */ + Fts3MultiSegReader *pCsr /* Cursor object */ ){ if( pCsr ){ int i; @@ -119844,43 +122275,56 @@ SQLITE_PRIVATE void sqlite3Fts3SegReaderFinish( ** Otherwise, if successful, SQLITE_OK is returned. If an error occurs, ** an SQLite error code is returned. */ -static int fts3SegmentMerge(Fts3Table *p, int iLevel){ +static int fts3SegmentMerge(Fts3Table *p, int iIndex, int iLevel){ int rc; /* Return code */ int iIdx = 0; /* Index of new segment */ - int iNewLevel = 0; /* Level to create new segment at */ + int iNewLevel = 0; /* Level/index to create new segment at */ SegmentWriter *pWriter = 0; /* Used to write the new, merged, segment */ Fts3SegFilter filter; /* Segment term filter condition */ - Fts3SegReaderCursor csr; /* Cursor to iterate through level(s) */ + Fts3MultiSegReader csr; /* Cursor to iterate through level(s) */ + int bIgnoreEmpty = 0; /* True to ignore empty segments */ - rc = sqlite3Fts3SegReaderCursor(p, iLevel, 0, 0, 1, 0, &csr); + assert( iLevel==FTS3_SEGCURSOR_ALL + || iLevel==FTS3_SEGCURSOR_PENDING + || iLevel>=0 + ); + assert( iLevel=0 && iIndexnIndex ); + + rc = sqlite3Fts3SegReaderCursor(p, iIndex, iLevel, 0, 0, 1, 0, &csr); if( rc!=SQLITE_OK || csr.nSegment==0 ) goto finished; if( iLevel==FTS3_SEGCURSOR_ALL ){ /* This call is to merge all segments in the database to a single ** segment. The level of the new segment is equal to the the numerically - ** greatest segment level currently present in the database. The index - ** of the new segment is always 0. */ - int nDummy; /* TODO: Remove this */ + ** greatest segment level currently present in the database for this + ** index. The idx of the new segment is always 0. */ if( csr.nSegment==1 ){ rc = SQLITE_DONE; goto finished; } - rc = fts3SegmentCountMax(p, &nDummy, &iNewLevel); + rc = fts3SegmentMaxLevel(p, iIndex, &iNewLevel); + bIgnoreEmpty = 1; + + }else if( iLevel==FTS3_SEGCURSOR_PENDING ){ + iNewLevel = iIndex * FTS3_SEGDIR_MAXLEVEL; + rc = fts3AllocateSegdirIdx(p, iIndex, 0, &iIdx); }else{ - /* This call is to merge all segments at level iLevel. Find the next + /* This call is to merge all segments at level iLevel. find the next ** available segment index at level iLevel+1. The call to ** fts3AllocateSegdirIdx() will merge the segments at level iLevel+1 to ** a single iLevel+2 segment if necessary. */ - iNewLevel = iLevel+1; - rc = fts3AllocateSegdirIdx(p, iNewLevel, &iIdx); + rc = fts3AllocateSegdirIdx(p, iIndex, iLevel+1, &iIdx); + iNewLevel = iIndex * FTS3_SEGDIR_MAXLEVEL + iLevel+1; } if( rc!=SQLITE_OK ) goto finished; assert( csr.nSegment>0 ); - assert( iNewLevel>=0 ); + assert( iNewLevel>=(iIndex*FTS3_SEGDIR_MAXLEVEL) ); + assert( iNewLevel<((iIndex+1)*FTS3_SEGDIR_MAXLEVEL) ); memset(&filter, 0, sizeof(Fts3SegFilter)); filter.flags = FTS3_SEGMENT_REQUIRE_POS; - filter.flags |= (iLevel==FTS3_SEGCURSOR_ALL ? FTS3_SEGMENT_IGNORE_EMPTY : 0); + filter.flags |= (bIgnoreEmpty ? FTS3_SEGMENT_IGNORE_EMPTY : 0); rc = sqlite3Fts3SegReaderStart(p, &csr, &filter); while( SQLITE_OK==rc ){ @@ -119892,8 +122336,10 @@ static int fts3SegmentMerge(Fts3Table *p, int iLevel){ if( rc!=SQLITE_OK ) goto finished; assert( pWriter ); - rc = fts3DeleteSegdir(p, iLevel, csr.apSegment, csr.nSegment); - if( rc!=SQLITE_OK ) goto finished; + if( iLevel!=FTS3_SEGCURSOR_PENDING ){ + rc = fts3DeleteSegdir(p, iIndex, iLevel, csr.apSegment, csr.nSegment); + if( rc!=SQLITE_OK ) goto finished; + } rc = fts3SegWriterFlush(p, pWriter, iNewLevel, iIdx); finished: @@ -119904,10 +122350,17 @@ static int fts3SegmentMerge(Fts3Table *p, int iLevel){ /* -** Flush the contents of pendingTerms to a level 0 segment. +** Flush the contents of pendingTerms to level 0 segments. */ SQLITE_PRIVATE int sqlite3Fts3PendingTermsFlush(Fts3Table *p){ - return fts3SegmentMerge(p, FTS3_SEGCURSOR_PENDING); + int rc = SQLITE_OK; + int i; + for(i=0; rc==SQLITE_OK && inIndex; i++){ + rc = fts3SegmentMerge(p, i, FTS3_SEGCURSOR_PENDING); + if( rc==SQLITE_DONE ) rc = SQLITE_OK; + } + sqlite3Fts3PendingTermsClear(p); + return rc; } /* @@ -120058,6 +122511,23 @@ static void fts3UpdateDocTotals( sqlite3_free(a); } +static int fts3DoOptimize(Fts3Table *p, int bReturnDone){ + int i; + int bSeenDone = 0; + int rc = SQLITE_OK; + for(i=0; rc==SQLITE_OK && inIndex; i++){ + rc = fts3SegmentMerge(p, i, FTS3_SEGCURSOR_ALL); + if( rc==SQLITE_DONE ){ + bSeenDone = 1; + rc = SQLITE_OK; + } + } + sqlite3Fts3SegmentsClose(p); + sqlite3Fts3PendingTermsClear(p); + + return (rc==SQLITE_OK && bReturnDone && bSeenDone) ? SQLITE_DONE : rc; +} + /* ** Handle a 'special' INSERT of the form: ** @@ -120074,12 +122544,7 @@ static int fts3SpecialInsert(Fts3Table *p, sqlite3_value *pVal){ if( !zVal ){ return SQLITE_NOMEM; }else if( nVal==8 && 0==sqlite3_strnicmp(zVal, "optimize", 8) ){ - rc = fts3SegmentMerge(p, FTS3_SEGCURSOR_ALL); - if( rc==SQLITE_DONE ){ - rc = SQLITE_OK; - }else{ - sqlite3Fts3PendingTermsClear(p); - } + rc = fts3DoOptimize(p, 0); #ifdef SQLITE_TEST }else if( nVal>9 && 0==sqlite3_strnicmp(zVal, "nodesize=", 9) ){ p->nNodeSize = atoi(&zVal[9]); @@ -120092,44 +122557,9 @@ static int fts3SpecialInsert(Fts3Table *p, sqlite3_value *pVal){ rc = SQLITE_ERROR; } - sqlite3Fts3SegmentsClose(p); return rc; } -/* -** Return the deferred doclist associated with deferred token pDeferred. -** This function assumes that sqlite3Fts3CacheDeferredDoclists() has already -** been called to allocate and populate the doclist. -*/ -SQLITE_PRIVATE char *sqlite3Fts3DeferredDoclist(Fts3DeferredToken *pDeferred, int *pnByte){ - if( pDeferred->pList ){ - *pnByte = pDeferred->pList->nData; - return pDeferred->pList->aData; - } - *pnByte = 0; - return 0; -} - -/* -** Helper fucntion for FreeDeferredDoclists(). This function removes all -** references to deferred doclists from within the tree of Fts3Expr -** structures headed by -*/ -static void fts3DeferredDoclistClear(Fts3Expr *pExpr){ - if( pExpr ){ - fts3DeferredDoclistClear(pExpr->pLeft); - fts3DeferredDoclistClear(pExpr->pRight); - if( pExpr->isLoaded ){ - sqlite3_free(pExpr->aDoclist); - pExpr->isLoaded = 0; - pExpr->aDoclist = 0; - pExpr->nDoclist = 0; - pExpr->pCurrent = 0; - pExpr->iCurrent = 0; - } - } -} - /* ** Delete all cached deferred doclists. Deferred doclists are cached ** (allocated) by the sqlite3Fts3CacheDeferredDoclists() function. @@ -120137,12 +122567,9 @@ static void fts3DeferredDoclistClear(Fts3Expr *pExpr){ SQLITE_PRIVATE void sqlite3Fts3FreeDeferredDoclists(Fts3Cursor *pCsr){ Fts3DeferredToken *pDef; for(pDef=pCsr->pDeferred; pDef; pDef=pDef->pNext){ - sqlite3_free(pDef->pList); + fts3PendingListDelete(pDef->pList); pDef->pList = 0; } - if( pCsr->pDeferred ){ - fts3DeferredDoclistClear(pCsr->pExpr); - } } /* @@ -120154,7 +122581,7 @@ SQLITE_PRIVATE void sqlite3Fts3FreeDeferredTokens(Fts3Cursor *pCsr){ Fts3DeferredToken *pNext; for(pDef=pCsr->pDeferred; pDef; pDef=pNext){ pNext = pDef->pNext; - sqlite3_free(pDef->pList); + fts3PendingListDelete(pDef->pList); sqlite3_free(pDef); } pCsr->pDeferred = 0; @@ -120219,6 +122646,33 @@ SQLITE_PRIVATE int sqlite3Fts3CacheDeferredDoclists(Fts3Cursor *pCsr){ return rc; } +SQLITE_PRIVATE int sqlite3Fts3DeferredTokenList( + Fts3DeferredToken *p, + char **ppData, + int *pnData +){ + char *pRet; + int nSkip; + sqlite3_int64 dummy; + + *ppData = 0; + *pnData = 0; + + if( p->pList==0 ){ + return SQLITE_OK; + } + + pRet = (char *)sqlite3_malloc(p->pList->nData); + if( !pRet ) return SQLITE_NOMEM; + + nSkip = sqlite3Fts3GetVarint(p->pList->aData, &dummy); + *pnData = p->pList->nData - nSkip; + *ppData = pRet; + + memcpy(pRet, &p->pList->aData[nSkip], *pnData); + return SQLITE_OK; +} + /* ** Add an entry for token pToken to the pCsr->pDeferred list. */ @@ -120244,6 +122698,40 @@ SQLITE_PRIVATE int sqlite3Fts3DeferToken( return SQLITE_OK; } +/* +** SQLite value pRowid contains the rowid of a row that may or may not be +** present in the FTS3 table. If it is, delete it and adjust the contents +** of subsiduary data structures accordingly. +*/ +static int fts3DeleteByRowid( + Fts3Table *p, + sqlite3_value *pRowid, + int *pnDoc, + u32 *aSzDel +){ + int isEmpty = 0; + int rc = fts3IsEmpty(p, pRowid, &isEmpty); + if( rc==SQLITE_OK ){ + if( isEmpty ){ + /* Deleting this row means the whole table is empty. In this case + ** delete the contents of all three tables and throw away any + ** data in the pendingTerms hash table. */ + rc = fts3DeleteAll(p); + *pnDoc = *pnDoc - 1; + }else{ + sqlite3_int64 iRemove = sqlite3_value_int64(pRowid); + rc = fts3PendingTermsDocid(p, iRemove); + fts3DeleteTerms(&rc, p, pRowid, aSzDel); + fts3SqlExec(&rc, p, SQL_DELETE_CONTENT, &pRowid); + if( sqlite3_changes(p->db) ) *pnDoc = *pnDoc - 1; + if( p->bHasDocsize ){ + fts3SqlExec(&rc, p, SQL_DELETE_DOCSIZE, &pRowid); + } + } + } + + return rc; +} /* ** This function does the work for the xUpdate method of FTS3 virtual @@ -120259,49 +122747,97 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod( int rc = SQLITE_OK; /* Return Code */ int isRemove = 0; /* True for an UPDATE or DELETE */ sqlite3_int64 iRemove = 0; /* Rowid removed by UPDATE or DELETE */ - u32 *aSzIns; /* Sizes of inserted documents */ + u32 *aSzIns = 0; /* Sizes of inserted documents */ u32 *aSzDel; /* Sizes of deleted documents */ int nChng = 0; /* Net change in number of documents */ + int bInsertDone = 0; assert( p->pSegments==0 ); + /* Check for a "special" INSERT operation. One of the form: + ** + ** INSERT INTO xyz(xyz) VALUES('command'); + */ + if( nArg>1 + && sqlite3_value_type(apVal[0])==SQLITE_NULL + && sqlite3_value_type(apVal[p->nColumn+2])!=SQLITE_NULL + ){ + rc = fts3SpecialInsert(p, apVal[p->nColumn+2]); + goto update_out; + } + /* Allocate space to hold the change in document sizes */ aSzIns = sqlite3_malloc( sizeof(aSzIns[0])*(p->nColumn+1)*2 ); - if( aSzIns==0 ) return SQLITE_NOMEM; + if( aSzIns==0 ){ + rc = SQLITE_NOMEM; + goto update_out; + } aSzDel = &aSzIns[p->nColumn+1]; memset(aSzIns, 0, sizeof(aSzIns[0])*(p->nColumn+1)*2); - /* If this is a DELETE or UPDATE operation, remove the old record. */ - if( sqlite3_value_type(apVal[0])!=SQLITE_NULL ){ - int isEmpty = 0; - rc = fts3IsEmpty(p, apVal, &isEmpty); - if( rc==SQLITE_OK ){ - if( isEmpty ){ - /* Deleting this row means the whole table is empty. In this case - ** delete the contents of all three tables and throw away any - ** data in the pendingTerms hash table. - */ - rc = fts3DeleteAll(p); + /* If this is an INSERT operation, or an UPDATE that modifies the rowid + ** value, then this operation requires constraint handling. + ** + ** If the on-conflict mode is REPLACE, this means that the existing row + ** should be deleted from the database before inserting the new row. Or, + ** if the on-conflict mode is other than REPLACE, then this method must + ** detect the conflict and return SQLITE_CONSTRAINT before beginning to + ** modify the database file. + */ + if( nArg>1 ){ + /* Find the value object that holds the new rowid value. */ + sqlite3_value *pNewRowid = apVal[3+p->nColumn]; + if( sqlite3_value_type(pNewRowid)==SQLITE_NULL ){ + pNewRowid = apVal[1]; + } + + if( sqlite3_value_type(pNewRowid)!=SQLITE_NULL && ( + sqlite3_value_type(apVal[0])==SQLITE_NULL + || sqlite3_value_int64(apVal[0])!=sqlite3_value_int64(pNewRowid) + )){ + /* The new rowid is not NULL (in this case the rowid will be + ** automatically assigned and there is no chance of a conflict), and + ** the statement is either an INSERT or an UPDATE that modifies the + ** rowid column. So if the conflict mode is REPLACE, then delete any + ** existing row with rowid=pNewRowid. + ** + ** Or, if the conflict mode is not REPLACE, insert the new record into + ** the %_content table. If we hit the duplicate rowid constraint (or any + ** other error) while doing so, return immediately. + ** + ** This branch may also run if pNewRowid contains a value that cannot + ** be losslessly converted to an integer. In this case, the eventual + ** call to fts3InsertData() (either just below or further on in this + ** function) will return SQLITE_MISMATCH. If fts3DeleteByRowid is + ** invoked, it will delete zero rows (since no row will have + ** docid=$pNewRowid if $pNewRowid is not an integer value). + */ + if( sqlite3_vtab_on_conflict(p->db)==SQLITE_REPLACE ){ + rc = fts3DeleteByRowid(p, pNewRowid, &nChng, aSzDel); }else{ - isRemove = 1; - iRemove = sqlite3_value_int64(apVal[0]); - rc = fts3PendingTermsDocid(p, iRemove); - fts3DeleteTerms(&rc, p, apVal, aSzDel); - fts3SqlExec(&rc, p, SQL_DELETE_CONTENT, apVal); - if( p->bHasDocsize ){ - fts3SqlExec(&rc, p, SQL_DELETE_DOCSIZE, apVal); - } - nChng--; + rc = fts3InsertData(p, apVal, pRowid); + bInsertDone = 1; } } - }else if( sqlite3_value_type(apVal[p->nColumn+2])!=SQLITE_NULL ){ - sqlite3_free(aSzIns); - return fts3SpecialInsert(p, apVal[p->nColumn+2]); + } + if( rc!=SQLITE_OK ){ + goto update_out; + } + + /* If this is a DELETE or UPDATE operation, remove the old record. */ + if( sqlite3_value_type(apVal[0])!=SQLITE_NULL ){ + assert( sqlite3_value_type(apVal[0])==SQLITE_INTEGER ); + rc = fts3DeleteByRowid(p, apVal[0], &nChng, aSzDel); + isRemove = 1; + iRemove = sqlite3_value_int64(apVal[0]); } /* If this is an INSERT or UPDATE operation, insert the new record. */ if( nArg>1 && rc==SQLITE_OK ){ - rc = fts3InsertData(p, apVal, pRowid); + if( bInsertDone==0 ){ + rc = fts3InsertData(p, apVal, pRowid); + if( rc==SQLITE_CONSTRAINT ) rc = SQLITE_CORRUPT_VTAB; + } if( rc==SQLITE_OK && (!isRemove || *pRowid!=iRemove) ){ rc = fts3PendingTermsDocid(p, *pRowid); } @@ -120318,6 +122854,7 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod( fts3UpdateDocTotals(&rc, p, aSzIns, aSzDel, nChng); } + update_out: sqlite3_free(aSzIns); sqlite3Fts3SegmentsClose(p); return rc; @@ -120332,12 +122869,10 @@ SQLITE_PRIVATE int sqlite3Fts3Optimize(Fts3Table *p){ int rc; rc = sqlite3_exec(p->db, "SAVEPOINT fts3", 0, 0, 0); if( rc==SQLITE_OK ){ - rc = fts3SegmentMerge(p, FTS3_SEGCURSOR_ALL); - if( rc==SQLITE_OK ){ - rc = sqlite3_exec(p->db, "RELEASE fts3", 0, 0, 0); - if( rc==SQLITE_OK ){ - sqlite3Fts3PendingTermsClear(p); - } + rc = fts3DoOptimize(p, 1); + if( rc==SQLITE_OK || rc==SQLITE_DONE ){ + int rc2 = sqlite3_exec(p->db, "RELEASE fts3", 0, 0, 0); + if( rc2!=SQLITE_OK ) rc = rc2; }else{ sqlite3_exec(p->db, "ROLLBACK TO fts3", 0, 0, 0); sqlite3_exec(p->db, "RELEASE fts3", 0, 0, 0); @@ -120526,51 +123061,6 @@ static int fts3ExprIterate( return fts3ExprIterate2(pExpr, &iPhrase, x, pCtx); } -/* -** The argument to this function is always a phrase node. Its doclist -** (Fts3Expr.aDoclist[]) and the doclists associated with all phrase nodes -** to the left of this one in the query tree have already been loaded. -** -** If this phrase node is part of a series of phrase nodes joined by -** NEAR operators (and is not the left-most of said series), then elements are -** removed from the phrases doclist consistent with the NEAR restriction. If -** required, elements may be removed from the doclists of phrases to the -** left of this one that are part of the same series of NEAR operator -** connected phrases. -** -** If an OOM error occurs, SQLITE_NOMEM is returned. Otherwise, SQLITE_OK. -*/ -static int fts3ExprNearTrim(Fts3Expr *pExpr){ - int rc = SQLITE_OK; - Fts3Expr *pParent = pExpr->pParent; - - assert( pExpr->eType==FTSQUERY_PHRASE ); - while( rc==SQLITE_OK - && pParent - && pParent->eType==FTSQUERY_NEAR - && pParent->pRight==pExpr - ){ - /* This expression (pExpr) is the right-hand-side of a NEAR operator. - ** Find the expression to the left of the same operator. - */ - int nNear = pParent->nNear; - Fts3Expr *pLeft = pParent->pLeft; - - if( pLeft->eType!=FTSQUERY_PHRASE ){ - assert( pLeft->eType==FTSQUERY_NEAR ); - assert( pLeft->pRight->eType==FTSQUERY_PHRASE ); - pLeft = pLeft->pRight; - } - - rc = sqlite3Fts3ExprNearTrim(pLeft, pExpr, nNear); - - pExpr = pLeft; - pParent = pExpr->pParent; - } - - return rc; -} - /* ** This is an fts3ExprIterate() callback used while loading the doclists ** for each phrase into Fts3Expr.aDoclist[]/nDoclist. See also @@ -120578,20 +123068,13 @@ static int fts3ExprNearTrim(Fts3Expr *pExpr){ */ static int fts3ExprLoadDoclistsCb(Fts3Expr *pExpr, int iPhrase, void *ctx){ int rc = SQLITE_OK; + Fts3Phrase *pPhrase = pExpr->pPhrase; LoadDoclistCtx *p = (LoadDoclistCtx *)ctx; UNUSED_PARAMETER(iPhrase); p->nPhrase++; - p->nToken += pExpr->pPhrase->nToken; - - if( pExpr->isLoaded==0 ){ - rc = sqlite3Fts3ExprLoadDoclist(p->pCsr, pExpr); - pExpr->isLoaded = 1; - if( rc==SQLITE_OK ){ - rc = fts3ExprNearTrim(pExpr); - } - } + p->nToken += pPhrase->nToken; return rc; } @@ -120765,7 +123248,7 @@ static int fts3SnippetFindPositions(Fts3Expr *pExpr, int iPhrase, void *ctx){ pPhrase->nToken = pExpr->pPhrase->nToken; - pCsr = sqlite3Fts3FindPositions(pExpr, p->pCsr->iPrevId, p->iCol); + pCsr = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol); if( pCsr ){ int iFirst = 0; pPhrase->pList = pCsr; @@ -121122,26 +123605,6 @@ static int fts3ColumnlistCount(char **ppCollist){ return nEntry; } -static void fts3LoadColumnlistCounts(char **pp, u32 *aOut, int isGlobal){ - char *pCsr = *pp; - while( *pCsr ){ - int nHit; - sqlite3_int64 iCol = 0; - if( *pCsr==0x01 ){ - pCsr++; - pCsr += sqlite3Fts3GetVarint(pCsr, &iCol); - } - nHit = fts3ColumnlistCount(&pCsr); - assert( nHit>0 ); - if( isGlobal ){ - aOut[iCol*3+1]++; - } - aOut[iCol*3] += nHit; - } - pCsr++; - *pp = pCsr; -} - /* ** fts3ExprIterate() callback used to collect the "global" matchinfo stats ** for a single query. @@ -121175,48 +123638,9 @@ static int fts3ExprGlobalHitsCb( void *pCtx /* Pointer to MatchInfo structure */ ){ MatchInfo *p = (MatchInfo *)pCtx; - Fts3Cursor *pCsr = p->pCursor; - char *pIter; - char *pEnd; - char *pFree = 0; - u32 *aOut = &p->aMatchinfo[3*iPhrase*p->nCol]; - - assert( pExpr->isLoaded ); - assert( pExpr->eType==FTSQUERY_PHRASE ); - - if( pCsr->pDeferred ){ - Fts3Phrase *pPhrase = pExpr->pPhrase; - int ii; - for(ii=0; iinToken; ii++){ - if( pPhrase->aToken[ii].bFulltext ) break; - } - if( iinToken ){ - int nFree = 0; - int rc = sqlite3Fts3ExprLoadFtDoclist(pCsr, pExpr, &pFree, &nFree); - if( rc!=SQLITE_OK ) return rc; - pIter = pFree; - pEnd = &pFree[nFree]; - }else{ - int iCol; /* Column index */ - for(iCol=0; iColnCol; iCol++){ - aOut[iCol*3 + 1] = (u32)p->nDoc; - aOut[iCol*3 + 2] = (u32)p->nDoc; - } - return SQLITE_OK; - } - }else{ - pIter = pExpr->aDoclist; - pEnd = &pExpr->aDoclist[pExpr->nDoclist]; - } - - /* Fill in the global hit count matrix row for this phrase. */ - while( pIterpCursor, pExpr, &p->aMatchinfo[3*iPhrase*p->nCol] + ); } /* @@ -121233,14 +123657,13 @@ static int fts3ExprLocalHitsCb( int iStart = iPhrase * p->nCol * 3; int i; - for(i=0; inCol; i++) p->aMatchinfo[iStart+i*3] = 0; - - if( pExpr->aDoclist ){ + for(i=0; inCol; i++){ char *pCsr; - - pCsr = sqlite3Fts3FindPositions(pExpr, p->pCursor->iPrevId, -1); + pCsr = sqlite3Fts3EvalPhrasePoslist(p->pCursor, pExpr, i); if( pCsr ){ - fts3LoadColumnlistCounts(&pCsr, &p->aMatchinfo[iStart], 0); + p->aMatchinfo[iStart+i*3] = fts3ColumnlistCount(&pCsr); + }else{ + p->aMatchinfo[iStart+i*3] = 0; } } @@ -121310,7 +123733,7 @@ static int fts3MatchinfoSelectDoctotal( a = sqlite3_column_blob(pStmt, 0); a += sqlite3Fts3GetVarint(a, &nDoc); - if( nDoc==0 ) return SQLITE_CORRUPT; + if( nDoc==0 ) return SQLITE_CORRUPT_VTAB; *pnDoc = (u32)nDoc; if( paLen ) *paLen = a; @@ -121326,9 +123749,8 @@ static int fts3MatchinfoSelectDoctotal( typedef struct LcsIterator LcsIterator; struct LcsIterator { Fts3Expr *pExpr; /* Pointer to phrase expression */ - char *pRead; /* Cursor used to iterate through aDoclist */ int iPosOffset; /* Tokens count up to end of this phrase */ - int iCol; /* Current column number */ + char *pRead; /* Cursor used to iterate through aDoclist */ int iPos; /* Current position */ }; @@ -121359,17 +123781,10 @@ static int fts3LcsIteratorAdvance(LcsIterator *pIter){ int rc = 0; pRead += sqlite3Fts3GetVarint(pRead, &iRead); - if( iRead==0 ){ - pIter->iCol = LCS_ITERATOR_FINISHED; + if( iRead==0 || iRead==1 ){ + pRead = 0; rc = 1; }else{ - if( iRead==1 ){ - pRead += sqlite3Fts3GetVarint(pRead, &iRead); - pIter->iCol = (int)iRead; - pIter->iPos = pIter->iPosOffset; - pRead += sqlite3Fts3GetVarint(pRead, &iRead); - rc = 1; - } pIter->iPos += (int)(iRead-2); } @@ -121401,42 +123816,34 @@ static int fts3MatchinfoLcs(Fts3Cursor *pCsr, MatchInfo *pInfo){ if( !aIter ) return SQLITE_NOMEM; memset(aIter, 0, sizeof(LcsIterator) * pCsr->nPhrase); (void)fts3ExprIterate(pCsr->pExpr, fts3MatchinfoLcsCb, (void*)aIter); + for(i=0; inPhrase; i++){ LcsIterator *pIter = &aIter[i]; nToken -= pIter->pExpr->pPhrase->nToken; pIter->iPosOffset = nToken; - pIter->pRead = sqlite3Fts3FindPositions(pIter->pExpr, pCsr->iPrevId, -1); - if( pIter->pRead ){ - pIter->iPos = pIter->iPosOffset; - fts3LcsIteratorAdvance(&aIter[i]); - }else{ - pIter->iCol = LCS_ITERATOR_FINISHED; - } } for(iCol=0; iColnCol; iCol++){ int nLcs = 0; /* LCS value for this column */ int nLive = 0; /* Number of iterators in aIter not at EOF */ - /* Loop through the iterators in aIter[]. Set nLive to the number of - ** iterators that point to a position-list corresponding to column iCol. - */ for(i=0; inPhrase; i++){ - assert( aIter[i].iCol>=iCol ); - if( aIter[i].iCol==iCol ) nLive++; + LcsIterator *pIt = &aIter[i]; + pIt->pRead = sqlite3Fts3EvalPhrasePoslist(pCsr, pIt->pExpr, iCol); + if( pIt->pRead ){ + pIt->iPos = pIt->iPosOffset; + fts3LcsIteratorAdvance(&aIter[i]); + nLive++; + } } - /* The following loop runs until all iterators in aIter[] have finished - ** iterating through positions in column iCol. Exactly one of the - ** iterators is advanced each time the body of the loop is run. - */ while( nLive>0 ){ LcsIterator *pAdv = 0; /* The iterator to advance by one position */ int nThisLcs = 0; /* LCS for the current iterator positions */ for(i=0; inPhrase; i++){ LcsIterator *pIter = &aIter[i]; - if( iCol!=pIter->iCol ){ + if( pIter->pRead==0 ){ /* This iterator is already at EOF for this column. */ nThisLcs = 0; }else{ @@ -121502,7 +123909,7 @@ static int fts3MatchinfoValues( case FTS3_MATCHINFO_NDOC: if( bGlobal ){ - sqlite3_int64 nDoc; + sqlite3_int64 nDoc = 0; rc = fts3MatchinfoSelectDoctotal(pTab, &pSelect, &nDoc, 0); pInfo->aMatchinfo[0] = (u32)nDoc; } @@ -121758,6 +124165,7 @@ struct TermOffset { }; struct TermOffsetCtx { + Fts3Cursor *pCsr; int iCol; /* Column of table to populate aTerm for */ int iTerm; sqlite3_int64 iDocid; @@ -121775,7 +124183,7 @@ static int fts3ExprTermOffsetInit(Fts3Expr *pExpr, int iPhrase, void *ctx){ int iPos = 0; /* First position in position-list */ UNUSED_PARAMETER(iPhrase); - pList = sqlite3Fts3FindPositions(pExpr, p->iDocid, p->iCol); + pList = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol); nTerm = pExpr->pPhrase->nToken; if( pList ){ fts3GetDeltaPosition(&pList, &iPos); @@ -121828,6 +124236,7 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets( goto offsets_out; } sCtx.iDocid = pCsr->iPrevId; + sCtx.pCsr = pCsr; /* Loop through the table columns, appending offset information to ** string-buffer res for each column. @@ -121903,7 +124312,7 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets( ); rc = fts3StringAppend(&res, aBuffer, -1); }else if( rc==SQLITE_DONE ){ - rc = SQLITE_CORRUPT; + rc = SQLITE_CORRUPT_VTAB; } } } @@ -122491,17 +124900,17 @@ nodeAcquire( if( pNode && iNode==1 ){ pRtree->iDepth = readInt16(pNode->zData); if( pRtree->iDepth>RTREE_MAX_DEPTH ){ - rc = SQLITE_CORRUPT; + rc = SQLITE_CORRUPT_VTAB; } } /* If no error has occurred so far, check if the "number of entries" ** field on the node is too large. If so, set the return code to - ** SQLITE_CORRUPT. + ** SQLITE_CORRUPT_VTAB. */ if( pNode && rc==SQLITE_OK ){ if( NCELL(pNode)>((pRtree->iNodeSize-4)/pRtree->nBytesPerCell) ){ - rc = SQLITE_CORRUPT; + rc = SQLITE_CORRUPT_VTAB; } } @@ -122509,7 +124918,7 @@ nodeAcquire( if( pNode!=0 ){ nodeHashInsert(pRtree, pNode); }else{ - rc = SQLITE_CORRUPT; + rc = SQLITE_CORRUPT_VTAB; } *ppNode = pNode; }else{ @@ -123036,7 +125445,7 @@ static int nodeRowidIndex( return SQLITE_OK; } } - return SQLITE_CORRUPT; + return SQLITE_CORRUPT_VTAB; } /* @@ -123395,7 +125804,7 @@ static float cellArea(Rtree *pRtree, RtreeCell *p){ float area = 1.0; int ii; for(ii=0; ii<(pRtree->nDim*2); ii+=2){ - area = area * (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii])); + area = (float)(area * (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii]))); } return area; } @@ -123408,7 +125817,7 @@ static float cellMargin(Rtree *pRtree, RtreeCell *p){ float margin = 0.0; int ii; for(ii=0; ii<(pRtree->nDim*2); ii+=2){ - margin += (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii])); + margin += (float)(DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii])); } return margin; } @@ -123493,7 +125902,7 @@ static float cellOverlap( o = 0.0; break; }else{ - o = o * (x2-x1); + o = o * (float)(x2-x1); } } overlap += o; @@ -123512,12 +125921,12 @@ static float cellOverlapEnlargement( int nCell, int iExclude ){ - float before; - float after; + double before; + double after; before = cellOverlap(pRtree, p, aCell, nCell, iExclude); cellUnion(pRtree, p, pInsert); after = cellOverlap(pRtree, p, aCell, nCell, iExclude); - return after-before; + return (float)(after-before); } #endif @@ -123539,11 +125948,11 @@ static int ChooseLeaf( for(ii=0; rc==SQLITE_OK && ii<(pRtree->iDepth-iHeight); ii++){ int iCell; - sqlite3_int64 iBest; + sqlite3_int64 iBest = 0; - float fMinGrowth; - float fMinArea; - float fMinOverlap; + float fMinGrowth = 0.0; + float fMinArea = 0.0; + float fMinOverlap = 0.0; int nCell = NCELL(pNode); RtreeCell cell; @@ -123631,7 +126040,7 @@ static int AdjustTree( int iCell; if( nodeParentIndex(pRtree, p, &iCell) ){ - return SQLITE_CORRUPT; + return SQLITE_CORRUPT_VTAB; } nodeGetCell(pRtree, pParent, iCell, &cell); @@ -123973,9 +126382,9 @@ static int splitNodeStartree( int *aSpare; int ii; - int iBestDim; - int iBestSplit; - float fBestMargin; + int iBestDim = 0; + int iBestSplit = 0; + float fBestMargin = 0.0; int nByte = (pRtree->nDim+1)*(sizeof(int*)+nCell*sizeof(int)); @@ -123997,9 +126406,9 @@ static int splitNodeStartree( for(ii=0; iinDim; ii++){ float margin = 0.0; - float fBestOverlap; - float fBestArea; - int iBestLeft; + float fBestOverlap = 0.0; + float fBestArea = 0.0; + int iBestLeft = 0; int nLeft; for( @@ -124303,7 +126712,7 @@ static int fixLeafParent(Rtree *pRtree, RtreeNode *pLeaf){ } rc = sqlite3_reset(pRtree->pReadParent); if( rc==SQLITE_OK ) rc = rc2; - if( rc==SQLITE_OK && !pChild->pParent ) rc = SQLITE_CORRUPT; + if( rc==SQLITE_OK && !pChild->pParent ) rc = SQLITE_CORRUPT_VTAB; pChild = pChild->pParent; } return rc; @@ -124314,7 +126723,7 @@ static int deleteCell(Rtree *, RtreeNode *, int, int); static int removeNode(Rtree *pRtree, RtreeNode *pNode, int iHeight){ int rc; int rc2; - RtreeNode *pParent; + RtreeNode *pParent = 0; int iCell; assert( pNode->nRef==1 ); @@ -124462,19 +126871,19 @@ static int Reinsert( } aOrder[ii] = ii; for(iDim=0; iDimnDim; iDim++){ - aCenterCoord[iDim] += DCOORD(aCell[ii].aCoord[iDim*2]); - aCenterCoord[iDim] += DCOORD(aCell[ii].aCoord[iDim*2+1]); + aCenterCoord[iDim] += (float)DCOORD(aCell[ii].aCoord[iDim*2]); + aCenterCoord[iDim] += (float)DCOORD(aCell[ii].aCoord[iDim*2+1]); } } for(iDim=0; iDimnDim; iDim++){ - aCenterCoord[iDim] = aCenterCoord[iDim]/((float)nCell*2.0); + aCenterCoord[iDim] = (float)(aCenterCoord[iDim]/((float)nCell*2.0)); } for(ii=0; iinDim; iDim++){ - float coord = DCOORD(aCell[ii].aCoord[iDim*2+1]) - - DCOORD(aCell[ii].aCoord[iDim*2]); + float coord = (float)(DCOORD(aCell[ii].aCoord[iDim*2+1]) - + DCOORD(aCell[ii].aCoord[iDim*2])); aDistance[ii] += (coord-aCenterCoord[iDim])*(coord-aCenterCoord[iDim]); } } @@ -124573,10 +126982,10 @@ static int reinsertNodeContent(Rtree *pRtree, RtreeNode *pNode){ /* Find a node to store this cell in. pNode->iNode currently contains ** the height of the sub-tree headed by the cell. */ - rc = ChooseLeaf(pRtree, &cell, pNode->iNode, &pInsert); + rc = ChooseLeaf(pRtree, &cell, (int)pNode->iNode, &pInsert); if( rc==SQLITE_OK ){ int rc2; - rc = rtreeInsertCell(pRtree, pInsert, &cell, pNode->iNode); + rc = rtreeInsertCell(pRtree, pInsert, &cell, (int)pNode->iNode); rc2 = nodeRelease(pRtree, pInsert); if( rc==SQLITE_OK ){ rc = rc2; @@ -124600,113 +127009,119 @@ static int newRowid(Rtree *pRtree, i64 *piRowid){ } /* -** The xUpdate method for rtree module virtual tables. +** Remove the entry with rowid=iDelete from the r-tree structure. */ -static int rtreeUpdate( - sqlite3_vtab *pVtab, - int nData, - sqlite3_value **azData, - sqlite_int64 *pRowid -){ - Rtree *pRtree = (Rtree *)pVtab; - int rc = SQLITE_OK; +static int rtreeDeleteRowid(Rtree *pRtree, sqlite3_int64 iDelete){ + int rc; /* Return code */ + RtreeNode *pLeaf; /* Leaf node containing record iDelete */ + int iCell; /* Index of iDelete cell in pLeaf */ + RtreeNode *pRoot; /* Root node of rtree structure */ - rtreeReference(pRtree); - assert(nData>=1); + /* Obtain a reference to the root node to initialise Rtree.iDepth */ + rc = nodeAcquire(pRtree, 1, 0, &pRoot); - /* If azData[0] is not an SQL NULL value, it is the rowid of a - ** record to delete from the r-tree table. The following block does - ** just that. + /* Obtain a reference to the leaf node that contains the entry + ** about to be deleted. */ - if( sqlite3_value_type(azData[0])!=SQLITE_NULL ){ - i64 iDelete; /* The rowid to delete */ - RtreeNode *pLeaf; /* Leaf node containing record iDelete */ - int iCell; /* Index of iDelete cell in pLeaf */ - RtreeNode *pRoot; - - /* Obtain a reference to the root node to initialise Rtree.iDepth */ - rc = nodeAcquire(pRtree, 1, 0, &pRoot); + if( rc==SQLITE_OK ){ + rc = findLeafNode(pRtree, iDelete, &pLeaf); + } - /* Obtain a reference to the leaf node that contains the entry - ** about to be deleted. - */ + /* Delete the cell in question from the leaf node. */ + if( rc==SQLITE_OK ){ + int rc2; + rc = nodeRowidIndex(pRtree, pLeaf, iDelete, &iCell); if( rc==SQLITE_OK ){ - iDelete = sqlite3_value_int64(azData[0]); - rc = findLeafNode(pRtree, iDelete, &pLeaf); + rc = deleteCell(pRtree, pLeaf, iCell, 0); } - - /* Delete the cell in question from the leaf node. */ + rc2 = nodeRelease(pRtree, pLeaf); if( rc==SQLITE_OK ){ - int rc2; - rc = nodeRowidIndex(pRtree, pLeaf, iDelete, &iCell); - if( rc==SQLITE_OK ){ - rc = deleteCell(pRtree, pLeaf, iCell, 0); - } - rc2 = nodeRelease(pRtree, pLeaf); - if( rc==SQLITE_OK ){ - rc = rc2; - } + rc = rc2; } + } - /* Delete the corresponding entry in the _rowid table. */ - if( rc==SQLITE_OK ){ - sqlite3_bind_int64(pRtree->pDeleteRowid, 1, iDelete); - sqlite3_step(pRtree->pDeleteRowid); - rc = sqlite3_reset(pRtree->pDeleteRowid); - } + /* Delete the corresponding entry in the _rowid table. */ + if( rc==SQLITE_OK ){ + sqlite3_bind_int64(pRtree->pDeleteRowid, 1, iDelete); + sqlite3_step(pRtree->pDeleteRowid); + rc = sqlite3_reset(pRtree->pDeleteRowid); + } - /* Check if the root node now has exactly one child. If so, remove - ** it, schedule the contents of the child for reinsertion and - ** reduce the tree height by one. - ** - ** This is equivalent to copying the contents of the child into - ** the root node (the operation that Gutman's paper says to perform - ** in this scenario). - */ - if( rc==SQLITE_OK && pRtree->iDepth>0 && NCELL(pRoot)==1 ){ - int rc2; - RtreeNode *pChild; - i64 iChild = nodeGetRowid(pRtree, pRoot, 0); - rc = nodeAcquire(pRtree, iChild, pRoot, &pChild); - if( rc==SQLITE_OK ){ - rc = removeNode(pRtree, pChild, pRtree->iDepth-1); - } - rc2 = nodeRelease(pRtree, pChild); - if( rc==SQLITE_OK ) rc = rc2; - if( rc==SQLITE_OK ){ - pRtree->iDepth--; - writeInt16(pRoot->zData, pRtree->iDepth); - pRoot->isDirty = 1; - } + /* Check if the root node now has exactly one child. If so, remove + ** it, schedule the contents of the child for reinsertion and + ** reduce the tree height by one. + ** + ** This is equivalent to copying the contents of the child into + ** the root node (the operation that Gutman's paper says to perform + ** in this scenario). + */ + if( rc==SQLITE_OK && pRtree->iDepth>0 && NCELL(pRoot)==1 ){ + int rc2; + RtreeNode *pChild; + i64 iChild = nodeGetRowid(pRtree, pRoot, 0); + rc = nodeAcquire(pRtree, iChild, pRoot, &pChild); + if( rc==SQLITE_OK ){ + rc = removeNode(pRtree, pChild, pRtree->iDepth-1); } - - /* Re-insert the contents of any underfull nodes removed from the tree. */ - for(pLeaf=pRtree->pDeleted; pLeaf; pLeaf=pRtree->pDeleted){ - if( rc==SQLITE_OK ){ - rc = reinsertNodeContent(pRtree, pLeaf); - } - pRtree->pDeleted = pLeaf->pNext; - sqlite3_free(pLeaf); + rc2 = nodeRelease(pRtree, pChild); + if( rc==SQLITE_OK ) rc = rc2; + if( rc==SQLITE_OK ){ + pRtree->iDepth--; + writeInt16(pRoot->zData, pRtree->iDepth); + pRoot->isDirty = 1; } + } - /* Release the reference to the root node. */ + /* Re-insert the contents of any underfull nodes removed from the tree. */ + for(pLeaf=pRtree->pDeleted; pLeaf; pLeaf=pRtree->pDeleted){ if( rc==SQLITE_OK ){ - rc = nodeRelease(pRtree, pRoot); - }else{ - nodeRelease(pRtree, pRoot); + rc = reinsertNodeContent(pRtree, pLeaf); } + pRtree->pDeleted = pLeaf->pNext; + sqlite3_free(pLeaf); } - /* If the azData[] array contains more than one element, elements - ** (azData[2]..azData[argc-1]) contain a new record to insert into - ** the r-tree structure. + /* Release the reference to the root node. */ + if( rc==SQLITE_OK ){ + rc = nodeRelease(pRtree, pRoot); + }else{ + nodeRelease(pRtree, pRoot); + } + + return rc; +} + +/* +** The xUpdate method for rtree module virtual tables. +*/ +static int rtreeUpdate( + sqlite3_vtab *pVtab, + int nData, + sqlite3_value **azData, + sqlite_int64 *pRowid +){ + Rtree *pRtree = (Rtree *)pVtab; + int rc = SQLITE_OK; + RtreeCell cell; /* New cell to insert if nData>1 */ + int bHaveRowid = 0; /* Set to 1 after new rowid is determined */ + + rtreeReference(pRtree); + assert(nData>=1); + + /* Constraint handling. A write operation on an r-tree table may return + ** SQLITE_CONSTRAINT for two reasons: + ** + ** 1. A duplicate rowid value, or + ** 2. The supplied data violates the "x2>=x1" constraint. + ** + ** In the first case, if the conflict-handling mode is REPLACE, then + ** the conflicting row can be removed before proceeding. In the second + ** case, SQLITE_CONSTRAINT must be returned regardless of the + ** conflict-handling mode specified by the user. */ - if( rc==SQLITE_OK && nData>1 ){ - /* Insert a new record into the r-tree */ - RtreeCell cell; + if( nData>1 ){ int ii; - RtreeNode *pLeaf; /* Populate the cell.aCoord[] array. The first coordinate is azData[3]. */ assert( nData==(pRtree->nDim*2 + 3) ); @@ -124730,18 +127145,49 @@ static int rtreeUpdate( } } - /* Figure out the rowid of the new row. */ - if( sqlite3_value_type(azData[2])==SQLITE_NULL ){ - rc = newRowid(pRtree, &cell.iRowid); - }else{ + /* If a rowid value was supplied, check if it is already present in + ** the table. If so, the constraint has failed. */ + if( sqlite3_value_type(azData[2])!=SQLITE_NULL ){ cell.iRowid = sqlite3_value_int64(azData[2]); - sqlite3_bind_int64(pRtree->pReadRowid, 1, cell.iRowid); - if( SQLITE_ROW==sqlite3_step(pRtree->pReadRowid) ){ - sqlite3_reset(pRtree->pReadRowid); - rc = SQLITE_CONSTRAINT; - goto constraint; + if( sqlite3_value_type(azData[0])==SQLITE_NULL + || sqlite3_value_int64(azData[0])!=cell.iRowid + ){ + int steprc; + sqlite3_bind_int64(pRtree->pReadRowid, 1, cell.iRowid); + steprc = sqlite3_step(pRtree->pReadRowid); + rc = sqlite3_reset(pRtree->pReadRowid); + if( SQLITE_ROW==steprc ){ + if( sqlite3_vtab_on_conflict(pRtree->db)==SQLITE_REPLACE ){ + rc = rtreeDeleteRowid(pRtree, cell.iRowid); + }else{ + rc = SQLITE_CONSTRAINT; + goto constraint; + } + } } - rc = sqlite3_reset(pRtree->pReadRowid); + bHaveRowid = 1; + } + } + + /* If azData[0] is not an SQL NULL value, it is the rowid of a + ** record to delete from the r-tree table. The following block does + ** just that. + */ + if( sqlite3_value_type(azData[0])!=SQLITE_NULL ){ + rc = rtreeDeleteRowid(pRtree, sqlite3_value_int64(azData[0])); + } + + /* If the azData[] array contains more than one element, elements + ** (azData[2]..azData[argc-1]) contain a new record to insert into + ** the r-tree structure. + */ + if( rc==SQLITE_OK && nData>1 ){ + /* Insert the new record into the r-tree */ + RtreeNode *pLeaf; + + /* Figure out the rowid of the new row. */ + if( bHaveRowid==0 ){ + rc = newRowid(pRtree, &cell.iRowid); } *pRowid = cell.iRowid; @@ -124786,7 +127232,7 @@ static int rtreeRename(sqlite3_vtab *pVtab, const char *zNewName){ } static sqlite3_module rtreeModule = { - 0, /* iVersion */ + 0, /* iVersion */ rtreeCreate, /* xCreate - create a table */ rtreeConnect, /* xConnect - connect to an existing table */ rtreeBestIndex, /* xBestIndex - Determine search strategy */ @@ -124805,7 +127251,10 @@ static sqlite3_module rtreeModule = { 0, /* xCommit - commit transaction */ 0, /* xRollback - rollback transaction */ 0, /* xFindFunction - function overloading */ - rtreeRename /* xRename - rename the table */ + rtreeRename, /* xRename - rename the table */ + 0, /* xSavepoint */ + 0, /* xRelease */ + 0 /* xRollbackTo */ }; static int rtreeSqlInit( @@ -124925,7 +127374,7 @@ static int getNodeSize( int rc; char *zSql; if( isCreate ){ - int iPageSize; + int iPageSize = 0; zSql = sqlite3_mprintf("PRAGMA %Q.page_size", pRtree->zDb); rc = getIntFromStmt(db, zSql, &iPageSize); if( rc==SQLITE_OK ){ @@ -124982,6 +127431,8 @@ static int rtreeInit( return SQLITE_ERROR; } + sqlite3_vtab_config(db, SQLITE_VTAB_CONSTRAINT_SUPPORT, 1); + /* Allocate the sqlite3_vtab structure */ nDb = strlen(argv[1]); nName = strlen(argv[2]); @@ -125726,10 +128177,7 @@ SQLITE_API int sqlite3_extension_init( ** ************************************************************************* ** This file implements a tokenizer for fts3 based on the ICU library. -** -** $Id$ */ - #if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) #ifdef SQLITE_ENABLE_ICU diff --git a/ext/sqlite3/libsqlite/sqlite3.h b/ext/sqlite3/libsqlite/sqlite3.h index 85e916c5e5792..ed9edbd20297e 100644 --- a/ext/sqlite3/libsqlite/sqlite3.h +++ b/ext/sqlite3/libsqlite/sqlite3.h @@ -107,9 +107,9 @@ extern "C" { ** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite_version()] and [sqlite_source_id()]. */ -#define SQLITE_VERSION "3.7.6.3" -#define SQLITE_VERSION_NUMBER 3007006 -#define SQLITE_SOURCE_ID "2011-05-19 13:26:54 ed1da510a239ea767a01dc332b667119fa3c908e" +#define SQLITE_VERSION "3.7.7.1" +#define SQLITE_VERSION_NUMBER 3007007 +#define SQLITE_SOURCE_ID "2011-06-28 17:39:05 af0d91adf497f5f36ec3813f04235a6e195a605f" /* ** CAPI3REF: Run-Time Library Version Numbers @@ -310,7 +310,7 @@ typedef int (*sqlite3_callback)(void*,int,char**, char**); ** argument. ^If the callback function of the 3rd argument to ** sqlite3_exec() is not NULL, then it is invoked for each result row ** coming out of the evaluated SQL statements. ^The 4th argument to -** to sqlite3_exec() is relayed through to the 1st argument of each +** sqlite3_exec() is relayed through to the 1st argument of each ** callback invocation. ^If the callback pointer to sqlite3_exec() ** is NULL, then no callback is ever invoked and result rows are ** ignored. @@ -375,7 +375,8 @@ SQLITE_API int sqlite3_exec( ** ** New error codes may be added in future versions of SQLite. ** -** See also: [SQLITE_IOERR_READ | extended result codes] +** See also: [SQLITE_IOERR_READ | extended result codes], +** [sqlite3_vtab_on_conflict()] [SQLITE_ROLLBACK | result codes]. */ #define SQLITE_OK 0 /* Successful result */ /* beginning-of-error-codes */ @@ -452,17 +453,21 @@ SQLITE_API int sqlite3_exec( #define SQLITE_IOERR_SHMOPEN (SQLITE_IOERR | (18<<8)) #define SQLITE_IOERR_SHMSIZE (SQLITE_IOERR | (19<<8)) #define SQLITE_IOERR_SHMLOCK (SQLITE_IOERR | (20<<8)) +#define SQLITE_IOERR_SHMMAP (SQLITE_IOERR | (21<<8)) +#define SQLITE_IOERR_SEEK (SQLITE_IOERR | (22<<8)) #define SQLITE_LOCKED_SHAREDCACHE (SQLITE_LOCKED | (1<<8)) #define SQLITE_BUSY_RECOVERY (SQLITE_BUSY | (1<<8)) #define SQLITE_CANTOPEN_NOTEMPDIR (SQLITE_CANTOPEN | (1<<8)) +#define SQLITE_CORRUPT_VTAB (SQLITE_CORRUPT | (1<<8)) +#define SQLITE_READONLY_RECOVERY (SQLITE_READONLY | (1<<8)) +#define SQLITE_READONLY_CANTLOCK (SQLITE_READONLY | (2<<8)) /* ** CAPI3REF: Flags For File Open Operations ** ** These bit values are intended for use in the ** 3rd parameter to the [sqlite3_open_v2()] interface and -** in the 4th parameter to the xOpen method of the -** [sqlite3_vfs] object. +** in the 4th parameter to the [sqlite3_vfs.xOpen] method. */ #define SQLITE_OPEN_READONLY 0x00000001 /* Ok for sqlite3_open_v2() */ #define SQLITE_OPEN_READWRITE 0x00000002 /* Ok for sqlite3_open_v2() */ @@ -470,6 +475,7 @@ SQLITE_API int sqlite3_exec( #define SQLITE_OPEN_DELETEONCLOSE 0x00000008 /* VFS only */ #define SQLITE_OPEN_EXCLUSIVE 0x00000010 /* VFS only */ #define SQLITE_OPEN_AUTOPROXY 0x00000020 /* VFS only */ +#define SQLITE_OPEN_URI 0x00000040 /* Ok for sqlite3_open_v2() */ #define SQLITE_OPEN_MAIN_DB 0x00000100 /* VFS only */ #define SQLITE_OPEN_TEMP_DB 0x00000200 /* VFS only */ #define SQLITE_OPEN_TRANSIENT_DB 0x00000400 /* VFS only */ @@ -580,17 +586,18 @@ struct sqlite3_file { /* ** CAPI3REF: OS Interface File Virtual Methods Object ** -** Every file opened by the [sqlite3_vfs] xOpen method populates an +** Every file opened by the [sqlite3_vfs.xOpen] method populates an ** [sqlite3_file] object (or, more commonly, a subclass of the ** [sqlite3_file] object) with a pointer to an instance of this object. ** This object defines the methods used to perform various operations ** against the open file represented by the [sqlite3_file] object. ** -** If the xOpen method sets the sqlite3_file.pMethods element +** If the [sqlite3_vfs.xOpen] method sets the sqlite3_file.pMethods element ** to a non-NULL pointer, then the sqlite3_io_methods.xClose method -** may be invoked even if the xOpen reported that it failed. The -** only way to prevent a call to xClose following a failed xOpen -** is for the xOpen to set the sqlite3_file.pMethods element to NULL. +** may be invoked even if the [sqlite3_vfs.xOpen] reported that it failed. The +** only way to prevent a call to xClose following a failed [sqlite3_vfs.xOpen] +** is for the [sqlite3_vfs.xOpen] to set the sqlite3_file.pMethods element +** to NULL. ** ** The flags argument to xSync may be one of [SQLITE_SYNC_NORMAL] or ** [SQLITE_SYNC_FULL]. The first choice is the normal fsync(). @@ -762,7 +769,8 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** ** An instance of the sqlite3_vfs object defines the interface between ** the SQLite core and the underlying operating system. The "vfs" -** in the name of the object stands for "virtual file system". +** in the name of the object stands for "virtual file system". See +** the [VFS | VFS documentation] for further information. ** ** The value of the iVersion field is initially 1 but may be larger in ** future versions of SQLite. Additional fields may be appended to this @@ -791,6 +799,7 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** The zName field holds the name of the VFS module. The name must ** be unique across all VFS modules. ** +** [[sqlite3_vfs.xOpen]] ** ^SQLite guarantees that the zFilename parameter to xOpen ** is either a NULL pointer or string obtained ** from xFullPathname() with an optional suffix added. @@ -868,6 +877,7 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** element will be valid after xOpen returns regardless of the success ** or failure of the xOpen call. ** +** [[sqlite3_vfs.xAccess]] ** ^The flags argument to xAccess() may be [SQLITE_ACCESS_EXISTS] ** to test for the existence of a file, or [SQLITE_ACCESS_READWRITE] to ** test whether a file is readable and writable, or [SQLITE_ACCESS_READ] @@ -892,7 +902,7 @@ typedef struct sqlite3_mutex sqlite3_mutex; ** method returns a Julian Day Number for the current date and time as ** a floating point value. ** ^The xCurrentTimeInt64() method returns, as an integer, the Julian -** Day Number multipled by 86400000 (the number of milliseconds in +** Day Number multiplied by 86400000 (the number of milliseconds in ** a 24-hour day). ** ^SQLite will use the xCurrentTimeInt64() method to get the current ** date and time if that method is available (if iVersion is 2 or @@ -1114,9 +1124,9 @@ SQLITE_API int sqlite3_os_end(void); ** implementation of an application-defined [sqlite3_os_init()]. ** ** The first argument to sqlite3_config() is an integer -** [SQLITE_CONFIG_SINGLETHREAD | configuration option] that determines +** [configuration option] that determines ** what property of SQLite is to be configured. Subsequent arguments -** vary depending on the [SQLITE_CONFIG_SINGLETHREAD | configuration option] +** vary depending on the [configuration option] ** in the first argument. ** ** ^When a configuration option is set, sqlite3_config() returns [SQLITE_OK]. @@ -1226,6 +1236,7 @@ struct sqlite3_mem_methods { /* ** CAPI3REF: Configuration Options +** KEYWORDS: {configuration option} ** ** These constants are the available integer configuration options that ** can be passed as the first argument to the [sqlite3_config()] interface. @@ -1238,7 +1249,7 @@ struct sqlite3_mem_methods { ** is invoked. ** **
-**
SQLITE_CONFIG_SINGLETHREAD
+** [[SQLITE_CONFIG_SINGLETHREAD]]
SQLITE_CONFIG_SINGLETHREAD
**
There are no arguments to this option. ^This option sets the ** [threading mode] to Single-thread. In other words, it disables ** all mutexing and puts SQLite into a mode where it can only be used @@ -1249,7 +1260,7 @@ struct sqlite3_mem_methods { ** [SQLITE_ERROR] if called with the SQLITE_CONFIG_SINGLETHREAD ** configuration option.
** -**
SQLITE_CONFIG_MULTITHREAD
+** [[SQLITE_CONFIG_MULTITHREAD]]
SQLITE_CONFIG_MULTITHREAD
**
There are no arguments to this option. ^This option sets the ** [threading mode] to Multi-thread. In other words, it disables ** mutexing on [database connection] and [prepared statement] objects. @@ -1263,7 +1274,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] will return [SQLITE_ERROR] if called with the ** SQLITE_CONFIG_MULTITHREAD configuration option.
** -**
SQLITE_CONFIG_SERIALIZED
+** [[SQLITE_CONFIG_SERIALIZED]]
SQLITE_CONFIG_SERIALIZED
**
There are no arguments to this option. ^This option sets the ** [threading mode] to Serialized. In other words, this option enables ** all mutexes including the recursive @@ -1279,7 +1290,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] will return [SQLITE_ERROR] if called with the ** SQLITE_CONFIG_SERIALIZED configuration option.
** -**
SQLITE_CONFIG_MALLOC
+** [[SQLITE_CONFIG_MALLOC]]
SQLITE_CONFIG_MALLOC
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mem_methods] structure. The argument specifies ** alternative low-level memory allocation routines to be used in place of @@ -1287,7 +1298,7 @@ struct sqlite3_mem_methods { ** its own private copy of the content of the [sqlite3_mem_methods] structure ** before the [sqlite3_config()] call returns.
** -**
SQLITE_CONFIG_GETMALLOC
+** [[SQLITE_CONFIG_GETMALLOC]]
SQLITE_CONFIG_GETMALLOC
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mem_methods] structure. The [sqlite3_mem_methods] ** structure is filled with the currently defined memory allocation routines.)^ @@ -1295,7 +1306,7 @@ struct sqlite3_mem_methods { ** routines with a wrapper that simulations memory allocation failure or ** tracks memory usage, for example.
** -**
SQLITE_CONFIG_MEMSTATUS
+** [[SQLITE_CONFIG_MEMSTATUS]]
SQLITE_CONFIG_MEMSTATUS
**
^This option takes single argument of type int, interpreted as a ** boolean, which enables or disables the collection of memory allocation ** statistics. ^(When memory allocation statistics are disabled, the @@ -1311,7 +1322,7 @@ struct sqlite3_mem_methods { ** allocation statistics are disabled by default. **
** -**
SQLITE_CONFIG_SCRATCH
+** [[SQLITE_CONFIG_SCRATCH]]
SQLITE_CONFIG_SCRATCH
**
^This option specifies a static memory buffer that SQLite can use for ** scratch memory. There are three arguments: A pointer an 8-byte ** aligned memory buffer from which the scratch allocations will be @@ -1327,9 +1338,9 @@ struct sqlite3_mem_methods { ** scratch memory beyond what is provided by this configuration option, then ** [sqlite3_malloc()] will be used to obtain the memory needed.
** -**
SQLITE_CONFIG_PAGECACHE
+** [[SQLITE_CONFIG_PAGECACHE]]
SQLITE_CONFIG_PAGECACHE
**
^This option specifies a static memory buffer that SQLite can use for -** the database page cache with the default page cache implemenation. +** the database page cache with the default page cache implementation. ** This configuration should not be used if an application-define page ** cache implementation is loaded using the SQLITE_CONFIG_PCACHE option. ** There are three arguments to this option: A pointer to 8-byte aligned @@ -1348,7 +1359,7 @@ struct sqlite3_mem_methods { ** be aligned to an 8-byte boundary or subsequent behavior of SQLite ** will be undefined.
** -**
SQLITE_CONFIG_HEAP
+** [[SQLITE_CONFIG_HEAP]]
SQLITE_CONFIG_HEAP
**
^This option specifies a static memory buffer that SQLite will use ** for all of its dynamic memory allocation needs beyond those provided ** for by [SQLITE_CONFIG_SCRATCH] and [SQLITE_CONFIG_PAGECACHE]. @@ -1365,7 +1376,7 @@ struct sqlite3_mem_methods { ** The minimum allocation size is capped at 2^12. Reasonable values ** for the minimum allocation size are 2^5 through 2^8.
** -**
SQLITE_CONFIG_MUTEX
+** [[SQLITE_CONFIG_MUTEX]]
SQLITE_CONFIG_MUTEX
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mutex_methods] structure. The argument specifies ** alternative low-level mutex routines to be used in place @@ -1377,7 +1388,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] with the SQLITE_CONFIG_MUTEX configuration option will ** return [SQLITE_ERROR].
** -**
SQLITE_CONFIG_GETMUTEX
+** [[SQLITE_CONFIG_GETMUTEX]]
SQLITE_CONFIG_GETMUTEX
**
^(This option takes a single argument which is a pointer to an ** instance of the [sqlite3_mutex_methods] structure. The ** [sqlite3_mutex_methods] @@ -1390,7 +1401,7 @@ struct sqlite3_mem_methods { ** [sqlite3_config()] with the SQLITE_CONFIG_GETMUTEX configuration option will ** return [SQLITE_ERROR].
** -**
SQLITE_CONFIG_LOOKASIDE
+** [[SQLITE_CONFIG_LOOKASIDE]]
SQLITE_CONFIG_LOOKASIDE
**
^(This option takes two arguments that determine the default ** memory allocation for the lookaside memory allocator on each ** [database connection]. The first argument is the @@ -1400,18 +1411,18 @@ struct sqlite3_mem_methods { ** verb to [sqlite3_db_config()] can be used to change the lookaside ** configuration on individual connections.)^
** -**
SQLITE_CONFIG_PCACHE
+** [[SQLITE_CONFIG_PCACHE]]
SQLITE_CONFIG_PCACHE
**
^(This option takes a single argument which is a pointer to ** an [sqlite3_pcache_methods] object. This object specifies the interface ** to a custom page cache implementation.)^ ^SQLite makes a copy of the ** object and uses it for page cache memory allocations.
** -**
SQLITE_CONFIG_GETPCACHE
+** [[SQLITE_CONFIG_GETPCACHE]]
SQLITE_CONFIG_GETPCACHE
**
^(This option takes a single argument which is a pointer to an ** [sqlite3_pcache_methods] object. SQLite copies of the current ** page cache implementation into that object.)^
** -**
SQLITE_CONFIG_LOG
+** [[SQLITE_CONFIG_LOG]]
SQLITE_CONFIG_LOG
**
^The SQLITE_CONFIG_LOG option takes two arguments: a pointer to a ** function with a call signature of void(*)(void*,int,const char*), ** and a pointer to void. ^If the function pointer is not NULL, it is @@ -1429,6 +1440,18 @@ struct sqlite3_mem_methods { ** In a multi-threaded application, the application-defined logger ** function must be threadsafe.
** +** [[SQLITE_CONFIG_URI]]
SQLITE_CONFIG_URI +**
This option takes a single argument of type int. If non-zero, then +** URI handling is globally enabled. If the parameter is zero, then URI handling +** is globally disabled. If URI handling is globally enabled, all filenames +** passed to [sqlite3_open()], [sqlite3_open_v2()], [sqlite3_open16()] or +** specified as part of [ATTACH] commands are interpreted as URIs, regardless +** of whether or not the [SQLITE_OPEN_URI] flag is set when the database +** connection is opened. If it is globally disabled, filenames are +** only interpreted as URIs if the SQLITE_OPEN_URI flag is set when the +** database connection is opened. By default, URI handling is globally +** disabled. The default value may be changed by compiling with the +** [SQLITE_USE_URI] symbol defined. **
*/ #define SQLITE_CONFIG_SINGLETHREAD 1 /* nil */ @@ -1447,6 +1470,7 @@ struct sqlite3_mem_methods { #define SQLITE_CONFIG_PCACHE 14 /* sqlite3_pcache_methods* */ #define SQLITE_CONFIG_GETPCACHE 15 /* sqlite3_pcache_methods* */ #define SQLITE_CONFIG_LOG 16 /* xFunc, void* */ +#define SQLITE_CONFIG_URI 17 /* int */ /* ** CAPI3REF: Database Connection Configuration Options @@ -1532,13 +1556,17 @@ SQLITE_API int sqlite3_extended_result_codes(sqlite3*, int onoff); ** ** ^This routine returns the [rowid] of the most recent ** successful [INSERT] into the database from the [database connection] -** in the first argument. ^If no successful [INSERT]s +** in the first argument. ^As of SQLite version 3.7.7, this routines +** records the last insert rowid of both ordinary tables and [virtual tables]. +** ^If no successful [INSERT]s ** have ever occurred on that database connection, zero is returned. ** -** ^(If an [INSERT] occurs within a trigger, then the [rowid] of the inserted -** row is returned by this routine as long as the trigger is running. -** But once the trigger terminates, the value returned by this routine -** reverts to the last value inserted before the trigger fired.)^ +** ^(If an [INSERT] occurs within a trigger or within a [virtual table] +** method, then this routine will return the [rowid] of the inserted +** row as long as the trigger or virtual table method is running. +** But once the trigger or virtual table method ends, the value returned +** by this routine reverts to what it was before the trigger or virtual +** table method began.)^ ** ** ^An [INSERT] that fails due to a constraint violation is not a ** successful [INSERT] and does not change the value returned by this @@ -2201,6 +2229,9 @@ SQLITE_API int sqlite3_set_authorizer( ** to signal SQLite whether or not the action is permitted. See the ** [sqlite3_set_authorizer | authorizer documentation] for additional ** information. +** +** Note that SQLITE_IGNORE is also used as a [SQLITE_ROLLBACK | return code] +** from the [sqlite3_vtab_on_conflict()] interface. */ #define SQLITE_DENY 1 /* Abort the SQL statement with an error */ #define SQLITE_IGNORE 2 /* Don't allow access, but don't generate an error */ @@ -2323,7 +2354,7 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); /* ** CAPI3REF: Opening A New Database Connection ** -** ^These routines open an SQLite database file whose name is given by the +** ^These routines open an SQLite database file as specified by the ** filename argument. ^The filename argument is interpreted as UTF-8 for ** sqlite3_open() and sqlite3_open_v2() and as UTF-16 in the native byte ** order for sqlite3_open16(). ^(A [database connection] handle is usually @@ -2350,7 +2381,7 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); ** sqlite3_open_v2() can take one of ** the following three values, optionally combined with the ** [SQLITE_OPEN_NOMUTEX], [SQLITE_OPEN_FULLMUTEX], [SQLITE_OPEN_SHAREDCACHE], -** and/or [SQLITE_OPEN_PRIVATECACHE] flags:)^ +** [SQLITE_OPEN_PRIVATECACHE], and/or [SQLITE_OPEN_URI] flags:)^ ** **
** ^(
[SQLITE_OPEN_READONLY]
@@ -2369,9 +2400,8 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); **
** ** If the 3rd parameter to sqlite3_open_v2() is not one of the -** combinations shown above or one of the combinations shown above combined -** with the [SQLITE_OPEN_NOMUTEX], [SQLITE_OPEN_FULLMUTEX], -** [SQLITE_OPEN_SHAREDCACHE] and/or [SQLITE_OPEN_PRIVATECACHE] flags, +** combinations shown above optionally combined with other +** [SQLITE_OPEN_READONLY | SQLITE_OPEN_* bits] ** then the behavior is undefined. ** ** ^If the [SQLITE_OPEN_NOMUTEX] flag is set, then the database connection @@ -2386,6 +2416,11 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); ** [SQLITE_OPEN_PRIVATECACHE] flag causes the database connection to not ** participate in [shared cache mode] even if it is enabled. ** +** ^The fourth parameter to sqlite3_open_v2() is the name of the +** [sqlite3_vfs] object that defines the operating system interface that +** the new database connection should use. ^If the fourth parameter is +** a NULL pointer then the default [sqlite3_vfs] object is used. +** ** ^If the filename is ":memory:", then a private, temporary in-memory database ** is created for the connection. ^This in-memory database will vanish when ** the database connection is closed. Future versions of SQLite might @@ -2398,10 +2433,111 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*); ** on-disk database will be created. ^This private database will be ** automatically deleted as soon as the database connection is closed. ** -** ^The fourth parameter to sqlite3_open_v2() is the name of the -** [sqlite3_vfs] object that defines the operating system interface that -** the new database connection should use. ^If the fourth parameter is -** a NULL pointer then the default [sqlite3_vfs] object is used. +** [[URI filenames in sqlite3_open()]]

URI Filenames

+** +** ^If [URI filename] interpretation is enabled, and the filename argument +** begins with "file:", then the filename is interpreted as a URI. ^URI +** filename interpretation is enabled if the [SQLITE_OPEN_URI] flag is +** set in the fourth argument to sqlite3_open_v2(), or if it has +** been enabled globally using the [SQLITE_CONFIG_URI] option with the +** [sqlite3_config()] method or by the [SQLITE_USE_URI] compile-time option. +** As of SQLite version 3.7.7, URI filename interpretation is turned off +** by default, but future releases of SQLite might enable URI filename +** interpretation by default. See "[URI filenames]" for additional +** information. +** +** URI filenames are parsed according to RFC 3986. ^If the URI contains an +** authority, then it must be either an empty string or the string +** "localhost". ^If the authority is not an empty string or "localhost", an +** error is returned to the caller. ^The fragment component of a URI, if +** present, is ignored. +** +** ^SQLite uses the path component of the URI as the name of the disk file +** which contains the database. ^If the path begins with a '/' character, +** then it is interpreted as an absolute path. ^If the path does not begin +** with a '/' (meaning that the authority section is omitted from the URI) +** then the path is interpreted as a relative path. +** ^On windows, the first component of an absolute path +** is a drive specification (e.g. "C:"). +** +** [[core URI query parameters]] +** The query component of a URI may contain parameters that are interpreted +** either by SQLite itself, or by a [VFS | custom VFS implementation]. +** SQLite interprets the following three query parameters: +** +**
    +**
  • vfs: ^The "vfs" parameter may be used to specify the name of +** a VFS object that provides the operating system interface that should +** be used to access the database file on disk. ^If this option is set to +** an empty string the default VFS object is used. ^Specifying an unknown +** VFS is an error. ^If sqlite3_open_v2() is used and the vfs option is +** present, then the VFS specified by the option takes precedence over +** the value passed as the fourth parameter to sqlite3_open_v2(). +** +**
  • mode: ^(The mode parameter may be set to either "ro", "rw" or +** "rwc". Attempting to set it to any other value is an error)^. +** ^If "ro" is specified, then the database is opened for read-only +** access, just as if the [SQLITE_OPEN_READONLY] flag had been set in the +** third argument to sqlite3_prepare_v2(). ^If the mode option is set to +** "rw", then the database is opened for read-write (but not create) +** access, as if SQLITE_OPEN_READWRITE (but not SQLITE_OPEN_CREATE) had +** been set. ^Value "rwc" is equivalent to setting both +** SQLITE_OPEN_READWRITE and SQLITE_OPEN_CREATE. ^If sqlite3_open_v2() is +** used, it is an error to specify a value for the mode parameter that is +** less restrictive than that specified by the flags passed as the third +** parameter. +** +**
  • cache: ^The cache parameter may be set to either "shared" or +** "private". ^Setting it to "shared" is equivalent to setting the +** SQLITE_OPEN_SHAREDCACHE bit in the flags argument passed to +** sqlite3_open_v2(). ^Setting the cache parameter to "private" is +** equivalent to setting the SQLITE_OPEN_PRIVATECACHE bit. +** ^If sqlite3_open_v2() is used and the "cache" parameter is present in +** a URI filename, its value overrides any behaviour requested by setting +** SQLITE_OPEN_PRIVATECACHE or SQLITE_OPEN_SHAREDCACHE flag. +**
+** +** ^Specifying an unknown parameter in the query component of a URI is not an +** error. Future versions of SQLite might understand additional query +** parameters. See "[query parameters with special meaning to SQLite]" for +** additional information. +** +** [[URI filename examples]]

URI filename examples

+** +** +**
URI filenames Results +**
file:data.db +** Open the file "data.db" in the current directory. +**
file:/home/fred/data.db
+** file:///home/fred/data.db
+** file://localhost/home/fred/data.db
+** Open the database file "/home/fred/data.db". +**
file://darkstar/home/fred/data.db +** An error. "darkstar" is not a recognized authority. +**
+** file:///C:/Documents%20and%20Settings/fred/Desktop/data.db +** Windows only: Open the file "data.db" on fred's desktop on drive +** C:. Note that the %20 escaping in this example is not strictly +** necessary - space characters can be used literally +** in URI filenames. +**
file:data.db?mode=ro&cache=private +** Open file "data.db" in the current directory for read-only access. +** Regardless of whether or not shared-cache mode is enabled by +** default, use a private cache. +**
file:/home/fred/data.db?vfs=unix-nolock +** Open file "/home/fred/data.db". Use the special VFS "unix-nolock". +**
file:data.db?mode=readonly +** An error. "readonly" is not a valid option for the "mode" parameter. +**
+** +** ^URI hexadecimal escape sequences (%HH) are supported within the path and +** query components of a URI. A hexadecimal escape sequence consists of a +** percent sign - "%" - followed by exactly two hexadecimal digits +** specifying an octet value. ^Before the path or query components of a +** URI filename are interpreted, they are encoded using UTF-8 and all +** hexadecimal escape sequences replaced by a single byte containing the +** corresponding octet. If this process generates an invalid UTF-8 encoding, +** the results are undefined. ** ** Note to Windows users: The encoding used for the filename argument ** of sqlite3_open() and sqlite3_open_v2() must be UTF-8, not whatever @@ -2424,6 +2560,26 @@ SQLITE_API int sqlite3_open_v2( const char *zVfs /* Name of VFS module to use */ ); +/* +** CAPI3REF: Obtain Values For URI Parameters +** +** This is a utility routine, useful to VFS implementations, that checks +** to see if a database file was a URI that contained a specific query +** parameter, and if so obtains the value of the query parameter. +** +** The zFilename argument is the filename pointer passed into the xOpen() +** method of a VFS implementation. The zParam argument is the name of the +** query parameter we seek. This routine returns the value of the zParam +** parameter if it exists. If the parameter does not exist, this routine +** returns a NULL pointer. +** +** If the zFilename argument to this function is not a pointer that SQLite +** passed into the xOpen VFS method, then the behavior of this routine +** is undefined and probably undesirable. +*/ +SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *zParam); + + /* ** CAPI3REF: Error Codes And Messages ** @@ -2539,43 +2695,45 @@ SQLITE_API int sqlite3_limit(sqlite3*, int id, int newVal); ** Additional information is available at [limits | Limits in SQLite]. ** **
-** ^(
SQLITE_LIMIT_LENGTH
+** [[SQLITE_LIMIT_LENGTH]] ^(
SQLITE_LIMIT_LENGTH
**
The maximum size of any string or BLOB or table row, in bytes.
)^ ** -** ^(
SQLITE_LIMIT_SQL_LENGTH
+** [[SQLITE_LIMIT_SQL_LENGTH]] ^(
SQLITE_LIMIT_SQL_LENGTH
**
The maximum length of an SQL statement, in bytes.
)^ ** -** ^(
SQLITE_LIMIT_COLUMN
+** [[SQLITE_LIMIT_COLUMN]] ^(
SQLITE_LIMIT_COLUMN
**
The maximum number of columns in a table definition or in the ** result set of a [SELECT] or the maximum number of columns in an index ** or in an ORDER BY or GROUP BY clause.
)^ ** -** ^(
SQLITE_LIMIT_EXPR_DEPTH
+** [[SQLITE_LIMIT_EXPR_DEPTH]] ^(
SQLITE_LIMIT_EXPR_DEPTH
**
The maximum depth of the parse tree on any expression.
)^ ** -** ^(
SQLITE_LIMIT_COMPOUND_SELECT
+** [[SQLITE_LIMIT_COMPOUND_SELECT]] ^(
SQLITE_LIMIT_COMPOUND_SELECT
**
The maximum number of terms in a compound SELECT statement.
)^ ** -** ^(
SQLITE_LIMIT_VDBE_OP
+** [[SQLITE_LIMIT_VDBE_OP]] ^(
SQLITE_LIMIT_VDBE_OP
**
The maximum number of instructions in a virtual machine program ** used to implement an SQL statement. This limit is not currently ** enforced, though that might be added in some future release of ** SQLite.
)^ ** -** ^(
SQLITE_LIMIT_FUNCTION_ARG
+** [[SQLITE_LIMIT_FUNCTION_ARG]] ^(
SQLITE_LIMIT_FUNCTION_ARG
**
The maximum number of arguments on a function.
)^ ** -** ^(
SQLITE_LIMIT_ATTACHED
+** [[SQLITE_LIMIT_ATTACHED]] ^(
SQLITE_LIMIT_ATTACHED
**
The maximum number of [ATTACH | attached databases].)^
** +** [[SQLITE_LIMIT_LIKE_PATTERN_LENGTH]] ** ^(
SQLITE_LIMIT_LIKE_PATTERN_LENGTH
**
The maximum length of the pattern argument to the [LIKE] or ** [GLOB] operators.
)^ ** +** [[SQLITE_LIMIT_VARIABLE_NUMBER]] ** ^(
SQLITE_LIMIT_VARIABLE_NUMBER
**
The maximum index number of any [parameter] in an SQL statement.)^ ** -** ^(
SQLITE_LIMIT_TRIGGER_DEPTH
+** [[SQLITE_LIMIT_TRIGGER_DEPTH]] ^(
SQLITE_LIMIT_TRIGGER_DEPTH
**
The maximum depth of recursion for triggers.
)^ **
*/ @@ -3104,7 +3262,7 @@ SQLITE_API const void *sqlite3_column_decltype16(sqlite3_stmt*,int); ** ^[SQLITE_BUSY] means that the database engine was unable to acquire the ** database locks it needs to do its job. ^If the statement is a [COMMIT] ** or occurs outside of an explicit transaction, then you can retry the -** statement. If the statement is not a [COMMIT] and occurs within a +** statement. If the statement is not a [COMMIT] and occurs within an ** explicit transaction then you should rollback the transaction before ** continuing. ** @@ -3383,7 +3541,7 @@ SQLITE_API sqlite3_value *sqlite3_column_value(sqlite3_stmt*, int iCol); ** CAPI3REF: Destroy A Prepared Statement Object ** ** ^The sqlite3_finalize() function is called to delete a [prepared statement]. -** ^If the most recent evaluation of the statement encountered no errors or +** ^If the most recent evaluation of the statement encountered no errors ** or if the statement is never been evaluated, then sqlite3_finalize() returns ** SQLITE_OK. ^If the most recent evaluation of statement S failed, then ** sqlite3_finalize(S) returns the appropriate [error code] or @@ -4610,6 +4768,11 @@ struct sqlite3_module { void (**pxFunc)(sqlite3_context*,int,sqlite3_value**), void **ppArg); int (*xRename)(sqlite3_vtab *pVtab, const char *zNew); + /* The methods above are in version 1 of the sqlite_module object. Those + ** below are for version 2 and greater. */ + int (*xSavepoint)(sqlite3_vtab *pVTab, int); + int (*xRelease)(sqlite3_vtab *pVTab, int); + int (*xRollbackTo)(sqlite3_vtab *pVTab, int); }; /* @@ -5292,7 +5455,7 @@ struct sqlite3_mutex_methods { ** ** ^If the argument to sqlite3_mutex_held() is a NULL pointer then ** the routine should return 1. This seems counter-intuitive since -** clearly the mutex cannot be held if it does not exist. But the +** clearly the mutex cannot be held if it does not exist. But ** the reason the mutex does not exist is because the build is not ** using mutexes. And we do not want the assert() containing the ** call to sqlite3_mutex_held() to fail, so a non-zero return is @@ -5415,7 +5578,8 @@ SQLITE_API int sqlite3_test_control(int op, ...); #define SQLITE_TESTCTRL_ISKEYWORD 16 #define SQLITE_TESTCTRL_PGHDRSZ 17 #define SQLITE_TESTCTRL_SCRATCHMALLOC 18 -#define SQLITE_TESTCTRL_LAST 18 +#define SQLITE_TESTCTRL_LOCALTIME_FAULT 19 +#define SQLITE_TESTCTRL_LAST 19 /* ** CAPI3REF: SQLite Runtime Status @@ -5424,7 +5588,7 @@ SQLITE_API int sqlite3_test_control(int op, ...); ** about the performance of SQLite, and optionally to reset various ** highwater marks. ^The first argument is an integer code for ** the specific parameter to measure. ^(Recognized integer codes -** are of the form [SQLITE_STATUS_MEMORY_USED | SQLITE_STATUS_...].)^ +** are of the form [status parameters | SQLITE_STATUS_...].)^ ** ^The current value of the parameter is returned into *pCurrent. ** ^The highest recorded value is returned in *pHighwater. ^If the ** resetFlag is true, then the highest record value is reset after @@ -5451,12 +5615,13 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF /* ** CAPI3REF: Status Parameters +** KEYWORDS: {status parameters} ** ** These integer constants designate various run-time status parameters ** that can be returned by [sqlite3_status()]. ** **
-** ^(
SQLITE_STATUS_MEMORY_USED
+** [[SQLITE_STATUS_MEMORY_USED]] ^(
SQLITE_STATUS_MEMORY_USED
**
This parameter is the current amount of memory checked out ** using [sqlite3_malloc()], either directly or indirectly. The ** figure includes calls made to [sqlite3_malloc()] by the application @@ -5466,23 +5631,24 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** this parameter. The amount returned is the sum of the allocation ** sizes as reported by the xSize method in [sqlite3_mem_methods].
)^ ** -** ^(
SQLITE_STATUS_MALLOC_SIZE
+** [[SQLITE_STATUS_MALLOC_SIZE]] ^(
SQLITE_STATUS_MALLOC_SIZE
**
This parameter records the largest memory allocation request ** handed to [sqlite3_malloc()] or [sqlite3_realloc()] (or their ** internal equivalents). Only the value returned in the ** *pHighwater parameter to [sqlite3_status()] is of interest. ** The value written into the *pCurrent parameter is undefined.
)^ ** -** ^(
SQLITE_STATUS_MALLOC_COUNT
+** [[SQLITE_STATUS_MALLOC_COUNT]] ^(
SQLITE_STATUS_MALLOC_COUNT
**
This parameter records the number of separate memory allocations ** currently checked out.
)^ ** -** ^(
SQLITE_STATUS_PAGECACHE_USED
+** [[SQLITE_STATUS_PAGECACHE_USED]] ^(
SQLITE_STATUS_PAGECACHE_USED
**
This parameter returns the number of pages used out of the ** [pagecache memory allocator] that was configured using ** [SQLITE_CONFIG_PAGECACHE]. The ** value returned is in pages, not in bytes.
)^ ** +** [[SQLITE_STATUS_PAGECACHE_OVERFLOW]] ** ^(
SQLITE_STATUS_PAGECACHE_OVERFLOW
**
This parameter returns the number of bytes of page cache ** allocation which could not be satisfied by the [SQLITE_CONFIG_PAGECACHE] @@ -5492,13 +5658,13 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** [SQLITE_CONFIG_PAGECACHE]) and allocations that overflowed because ** no space was left in the page cache.
)^ ** -** ^(
SQLITE_STATUS_PAGECACHE_SIZE
+** [[SQLITE_STATUS_PAGECACHE_SIZE]] ^(
SQLITE_STATUS_PAGECACHE_SIZE
**
This parameter records the largest memory allocation request ** handed to [pagecache memory allocator]. Only the value returned in the ** *pHighwater parameter to [sqlite3_status()] is of interest. ** The value written into the *pCurrent parameter is undefined.
)^ ** -** ^(
SQLITE_STATUS_SCRATCH_USED
+** [[SQLITE_STATUS_SCRATCH_USED]] ^(
SQLITE_STATUS_SCRATCH_USED
**
This parameter returns the number of allocations used out of the ** [scratch memory allocator] configured using ** [SQLITE_CONFIG_SCRATCH]. The value returned is in allocations, not @@ -5506,7 +5672,7 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** outstanding at time, this parameter also reports the number of threads ** using scratch memory at the same time.
)^ ** -** ^(
SQLITE_STATUS_SCRATCH_OVERFLOW
+** [[SQLITE_STATUS_SCRATCH_OVERFLOW]] ^(
SQLITE_STATUS_SCRATCH_OVERFLOW
**
This parameter returns the number of bytes of scratch memory ** allocation which could not be satisfied by the [SQLITE_CONFIG_SCRATCH] ** buffer and where forced to overflow to [sqlite3_malloc()]. The values @@ -5516,13 +5682,13 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** slots were available. **
)^ ** -** ^(
SQLITE_STATUS_SCRATCH_SIZE
+** [[SQLITE_STATUS_SCRATCH_SIZE]] ^(
SQLITE_STATUS_SCRATCH_SIZE
**
This parameter records the largest memory allocation request ** handed to [scratch memory allocator]. Only the value returned in the ** *pHighwater parameter to [sqlite3_status()] is of interest. ** The value written into the *pCurrent parameter is undefined.
)^ ** -** ^(
SQLITE_STATUS_PARSER_STACK
+** [[SQLITE_STATUS_PARSER_STACK]] ^(
SQLITE_STATUS_PARSER_STACK
**
This parameter records the deepest parser stack. It is only ** meaningful if SQLite is compiled with [YYTRACKMAXSTACKDEPTH].
)^ **
@@ -5547,9 +5713,9 @@ SQLITE_API int sqlite3_status(int op, int *pCurrent, int *pHighwater, int resetF ** about a single [database connection]. ^The first argument is the ** database connection object to be interrogated. ^The second argument ** is an integer constant, taken from the set of -** [SQLITE_DBSTATUS_LOOKASIDE_USED | SQLITE_DBSTATUS_*] macros, that +** [SQLITE_DBSTATUS options], that ** determines the parameter to interrogate. The set of -** [SQLITE_DBSTATUS_LOOKASIDE_USED | SQLITE_DBSTATUS_*] macros is likely +** [SQLITE_DBSTATUS options] is likely ** to grow in future releases of SQLite. ** ** ^The current value of the requested parameter is written into *pCur @@ -5566,6 +5732,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r /* ** CAPI3REF: Status Parameters for database connections +** KEYWORDS: {SQLITE_DBSTATUS options} ** ** These constants are the available integer "verbs" that can be passed as ** the second argument to the [sqlite3_db_status()] interface. @@ -5577,15 +5744,16 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** if a discontinued or unsupported verb is invoked. ** **
-** ^(
SQLITE_DBSTATUS_LOOKASIDE_USED
+** [[SQLITE_DBSTATUS_LOOKASIDE_USED]] ^(
SQLITE_DBSTATUS_LOOKASIDE_USED
**
This parameter returns the number of lookaside memory slots currently ** checked out.
)^ ** -** ^(
SQLITE_DBSTATUS_LOOKASIDE_HIT
+** [[SQLITE_DBSTATUS_LOOKASIDE_HIT]] ^(
SQLITE_DBSTATUS_LOOKASIDE_HIT
**
This parameter returns the number malloc attempts that were ** satisfied using lookaside memory. Only the high-water value is meaningful; ** the current value is always zero.)^ ** +** [[SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE]] ** ^(
SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE
**
This parameter returns the number malloc attempts that might have ** been satisfied using lookaside memory but failed due to the amount of @@ -5593,6 +5761,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** Only the high-water value is meaningful; ** the current value is always zero.)^ ** +** [[SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL]] ** ^(
SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL
**
This parameter returns the number malloc attempts that might have ** been satisfied using lookaside memory but failed due to all lookaside @@ -5600,12 +5769,12 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** Only the high-water value is meaningful; ** the current value is always zero.)^ ** -** ^(
SQLITE_DBSTATUS_CACHE_USED
+** [[SQLITE_DBSTATUS_CACHE_USED]] ^(
SQLITE_DBSTATUS_CACHE_USED
**
This parameter returns the approximate number of of bytes of heap ** memory used by all pager caches associated with the database connection.)^ ** ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_USED is always 0. ** -** ^(
SQLITE_DBSTATUS_SCHEMA_USED
+** [[SQLITE_DBSTATUS_SCHEMA_USED]] ^(
SQLITE_DBSTATUS_SCHEMA_USED
**
This parameter returns the approximate number of of bytes of heap ** memory used to store the schema for all databases associated ** with the connection - main, temp, and any [ATTACH]-ed databases.)^ @@ -5614,7 +5783,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** [shared cache mode] being enabled. ** ^The highwater mark associated with SQLITE_DBSTATUS_SCHEMA_USED is always 0. ** -** ^(
SQLITE_DBSTATUS_STMT_USED
+** [[SQLITE_DBSTATUS_STMT_USED]] ^(
SQLITE_DBSTATUS_STMT_USED
**
This parameter returns the approximate number of of bytes of heap ** and lookaside memory used by all prepared statements associated with ** the database connection.)^ @@ -5636,7 +5805,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** CAPI3REF: Prepared Statement Status ** ** ^(Each prepared statement maintains various -** [SQLITE_STMTSTATUS_SORT | counters] that measure the number +** [SQLITE_STMTSTATUS counters] that measure the number ** of times it has performed specific operations.)^ These counters can ** be used to monitor the performance characteristics of the prepared ** statements. For example, if the number of table steps greatly exceeds @@ -5647,7 +5816,7 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r ** ^(This interface is used to retrieve and reset counter values from ** a [prepared statement]. The first argument is the prepared statement ** object to be interrogated. The second argument -** is an integer code for a specific [SQLITE_STMTSTATUS_SORT | counter] +** is an integer code for a specific [SQLITE_STMTSTATUS counter] ** to be interrogated.)^ ** ^The current value of the requested counter is returned. ** ^If the resetFlg is true, then the counter is reset to zero after this @@ -5659,24 +5828,25 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt*, int op,int resetFlg); /* ** CAPI3REF: Status Parameters for prepared statements +** KEYWORDS: {SQLITE_STMTSTATUS counter} {SQLITE_STMTSTATUS counters} ** ** These preprocessor macros define integer codes that name counter ** values associated with the [sqlite3_stmt_status()] interface. ** The meanings of the various counters are as follows: ** **
-**
SQLITE_STMTSTATUS_FULLSCAN_STEP
+** [[SQLITE_STMTSTATUS_FULLSCAN_STEP]]
SQLITE_STMTSTATUS_FULLSCAN_STEP
**
^This is the number of times that SQLite has stepped forward in ** a table as part of a full table scan. Large numbers for this counter ** may indicate opportunities for performance improvement through ** careful use of indices.
** -**
SQLITE_STMTSTATUS_SORT
+** [[SQLITE_STMTSTATUS_SORT]]
SQLITE_STMTSTATUS_SORT
**
^This is the number of sort operations that have occurred. ** A non-zero value in this counter may indicate an opportunity to ** improvement performance through careful use of indices.
** -**
SQLITE_STMTSTATUS_AUTOINDEX
+** [[SQLITE_STMTSTATUS_AUTOINDEX]]
SQLITE_STMTSTATUS_AUTOINDEX
**
^This is the number of rows inserted into transient indices that ** were created automatically in order to help joins run faster. ** A non-zero value in this counter may indicate an opportunity to @@ -5727,6 +5897,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** the application may discard the parameter after the call to ** [sqlite3_config()] returns.)^ ** +** [[the xInit() page cache method]] ** ^(The xInit() method is called once for each effective ** call to [sqlite3_initialize()])^ ** (usually only once during the lifetime of the process). ^(The xInit() @@ -5737,6 +5908,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** built-in default page cache is used instead of the application defined ** page cache.)^ ** +** [[the xShutdown() page cache method]] ** ^The xShutdown() method is called by [sqlite3_shutdown()]. ** It can be used to clean up ** any outstanding resources before process shutdown, if required. @@ -5751,6 +5923,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** ^SQLite will never invoke xInit() more than once without an intervening ** call to xShutdown(). ** +** [[the xCreate() page cache methods]] ** ^SQLite invokes the xCreate() method to construct a new cache instance. ** SQLite will typically create one cache instance for each open database file, ** though this is not guaranteed. ^The @@ -5775,6 +5948,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** ^Hence, a cache created with bPurgeable false will ** never contain any unpinned pages. ** +** [[the xCachesize() page cache method]] ** ^(The xCachesize() method may be called at any time by SQLite to set the ** suggested maximum cache-size (number of pages stored by) the cache ** instance passed as the first argument. This is the value configured using @@ -5782,14 +5956,16 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** parameter, the implementation is not required to do anything with this ** value; it is advisory only. ** +** [[the xPagecount() page cache methods]] ** The xPagecount() method must return the number of pages currently ** stored in the cache, both pinned and unpinned. ** +** [[the xFetch() page cache methods]] ** The xFetch() method locates a page in the cache and returns a pointer to ** the page, or a NULL pointer. ** A "page", in this context, means a buffer of szPage bytes aligned at an ** 8-byte boundary. The page to be fetched is determined by the key. ^The -** mimimum key value is 1. After it has been retrieved using xFetch, the page +** minimum key value is 1. After it has been retrieved using xFetch, the page ** is considered to be "pinned". ** ** If the requested page is already in the page cache, then the page cache @@ -5813,6 +5989,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** attempt to unpin one or more cache pages by spilling the content of ** pinned pages to disk and synching the operating system disk cache. ** +** [[the xUnpin() page cache method]] ** ^xUnpin() is called by SQLite with a pointer to a currently pinned page ** as its second argument. If the third parameter, discard, is non-zero, ** then the page must be evicted from the cache. @@ -5825,6 +6002,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** call to xUnpin() unpins the page regardless of the number of prior calls ** to xFetch(). ** +** [[the xRekey() page cache methods]] ** The xRekey() method is used to change the key value associated with the ** page passed as the second argument. If the cache ** previously contains an entry associated with newKey, it must be @@ -5837,6 +6015,7 @@ typedef struct sqlite3_pcache sqlite3_pcache; ** of these pages are pinned, they are implicitly unpinned, meaning that ** they can be safely discarded. ** +** [[the xDestroy() page cache method]] ** ^The xDestroy() method is used to delete a cache allocated by xCreate(). ** All resources associated with the specified cache should be freed. ^After ** calling the xDestroy() method, SQLite considers the [sqlite3_pcache*] @@ -5899,7 +6078,7 @@ typedef struct sqlite3_backup sqlite3_backup; ** There should be exactly one call to sqlite3_backup_finish() for each ** successful call to sqlite3_backup_init(). ** -** sqlite3_backup_init() +** [[sqlite3_backup_init()]] sqlite3_backup_init() ** ** ^The D and N arguments to sqlite3_backup_init(D,N,S,M) are the ** [database connection] associated with the destination database @@ -5926,7 +6105,7 @@ typedef struct sqlite3_backup sqlite3_backup; ** sqlite3_backup_finish() functions to perform the specified backup ** operation. ** -** sqlite3_backup_step() +** [[sqlite3_backup_step()]] sqlite3_backup_step() ** ** ^Function sqlite3_backup_step(B,N) will copy up to N pages between ** the source and destination databases specified by [sqlite3_backup] object B. @@ -5983,7 +6162,7 @@ typedef struct sqlite3_backup sqlite3_backup; ** by the backup operation, then the backup database is automatically ** updated at the same time. ** -** sqlite3_backup_finish() +** [[sqlite3_backup_finish()]] sqlite3_backup_finish() ** ** When sqlite3_backup_step() has returned [SQLITE_DONE], or when the ** application wishes to abandon the backup operation, the application @@ -6006,7 +6185,8 @@ typedef struct sqlite3_backup sqlite3_backup; ** is not a permanent error and does not affect the return value of ** sqlite3_backup_finish(). ** -** sqlite3_backup_remaining(), sqlite3_backup_pagecount() +** [[sqlite3_backup__remaining()]] [[sqlite3_backup_pagecount()]] +** sqlite3_backup_remaining() and sqlite3_backup_pagecount() ** ** ^Each call to sqlite3_backup_step() sets two values inside ** the [sqlite3_backup] object: the number of pages still to be backed @@ -6392,6 +6572,93 @@ SQLITE_API int sqlite3_wal_checkpoint_v2( #define SQLITE_CHECKPOINT_FULL 1 #define SQLITE_CHECKPOINT_RESTART 2 +/* +** CAPI3REF: Virtual Table Interface Configuration +** +** This function may be called by either the [xConnect] or [xCreate] method +** of a [virtual table] implementation to configure +** various facets of the virtual table interface. +** +** If this interface is invoked outside the context of an xConnect or +** xCreate virtual table method then the behavior is undefined. +** +** At present, there is only one option that may be configured using +** this function. (See [SQLITE_VTAB_CONSTRAINT_SUPPORT].) Further options +** may be added in the future. +*/ +SQLITE_API int sqlite3_vtab_config(sqlite3*, int op, ...); + +/* +** CAPI3REF: Virtual Table Configuration Options +** +** These macros define the various options to the +** [sqlite3_vtab_config()] interface that [virtual table] implementations +** can use to customize and optimize their behavior. +** +**
+**
SQLITE_VTAB_CONSTRAINT_SUPPORT +**
Calls of the form +** [sqlite3_vtab_config](db,SQLITE_VTAB_CONSTRAINT_SUPPORT,X) are supported, +** where X is an integer. If X is zero, then the [virtual table] whose +** [xCreate] or [xConnect] method invoked [sqlite3_vtab_config()] does not +** support constraints. In this configuration (which is the default) if +** a call to the [xUpdate] method returns [SQLITE_CONSTRAINT], then the entire +** statement is rolled back as if [ON CONFLICT | OR ABORT] had been +** specified as part of the users SQL statement, regardless of the actual +** ON CONFLICT mode specified. +** +** If X is non-zero, then the virtual table implementation guarantees +** that if [xUpdate] returns [SQLITE_CONSTRAINT], it will do so before +** any modifications to internal or persistent data structures have been made. +** If the [ON CONFLICT] mode is ABORT, FAIL, IGNORE or ROLLBACK, SQLite +** is able to roll back a statement or database transaction, and abandon +** or continue processing the current SQL statement as appropriate. +** If the ON CONFLICT mode is REPLACE and the [xUpdate] method returns +** [SQLITE_CONSTRAINT], SQLite handles this as if the ON CONFLICT mode +** had been ABORT. +** +** Virtual table implementations that are required to handle OR REPLACE +** must do so within the [xUpdate] method. If a call to the +** [sqlite3_vtab_on_conflict()] function indicates that the current ON +** CONFLICT policy is REPLACE, the virtual table implementation should +** silently replace the appropriate rows within the xUpdate callback and +** return SQLITE_OK. Or, if this is not possible, it may return +** SQLITE_CONSTRAINT, in which case SQLite falls back to OR ABORT +** constraint handling. +**
+*/ +#define SQLITE_VTAB_CONSTRAINT_SUPPORT 1 + +/* +** CAPI3REF: Determine The Virtual Table Conflict Policy +** +** This function may only be called from within a call to the [xUpdate] method +** of a [virtual table] implementation for an INSERT or UPDATE operation. ^The +** value returned is one of [SQLITE_ROLLBACK], [SQLITE_IGNORE], [SQLITE_FAIL], +** [SQLITE_ABORT], or [SQLITE_REPLACE], according to the [ON CONFLICT] mode +** of the SQL statement that triggered the call to the [xUpdate] method of the +** [virtual table]. +*/ +SQLITE_API int sqlite3_vtab_on_conflict(sqlite3 *); + +/* +** CAPI3REF: Conflict resolution modes +** +** These constants are returned by [sqlite3_vtab_on_conflict()] to +** inform a [virtual table] implementation what the [ON CONFLICT] mode +** is for the SQL statement being evaluated. +** +** Note that the [SQLITE_IGNORE] constant is also used as a potential +** return value from the [sqlite3_set_authorizer()] callback and that +** [SQLITE_ABORT] is also a [result code]. +*/ +#define SQLITE_ROLLBACK 1 +/* #define SQLITE_IGNORE 2 // Also used by sqlite3_authorizer() callback */ +#define SQLITE_FAIL 3 +/* #define SQLITE_ABORT 4 // Also an error code */ +#define SQLITE_REPLACE 5 + + /* ** Undo the hack that converts floating point types to integer for From 571427c7db8bb67433f84d0ef75724a5f736a9fa Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 9 Aug 2011 09:35:42 +0000 Subject: [PATCH 0523/2394] Avoiding strcpy usage, Make static analyzer happy --- ext/ereg/regex.patch | 12 ++++++++++++ ext/ereg/regex/regerror.c | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 ext/ereg/regex.patch diff --git a/ext/ereg/regex.patch b/ext/ereg/regex.patch new file mode 100644 index 0000000000000..d10a9b9a46361 --- /dev/null +++ b/ext/ereg/regex.patch @@ -0,0 +1,12 @@ +diff -u regex.orig/regerror.c regex/regerror.c +--- regex.orig/regerror.c 2011-08-09 17:31:11.000000000 +0800 ++++ regex/regerror.c 2011-08-09 17:29:53.000000000 +0800 +@@ -82,7 +82,7 @@ + + if (errcode®_ITOA) { + if (r->code >= 0) +- (void) strcpy(convbuf, r->name); ++ (void) strncpy(convbuf, r->name, 50); + else + sprintf(convbuf, "REG_0x%x", target); + assert(strlen(convbuf) < sizeof(convbuf)); diff --git a/ext/ereg/regex/regerror.c b/ext/ereg/regex/regerror.c index 00009a93c15a5..f8c3ca3538f13 100644 --- a/ext/ereg/regex/regerror.c +++ b/ext/ereg/regex/regerror.c @@ -82,7 +82,7 @@ size_t errbuf_size) if (errcode®_ITOA) { if (r->code >= 0) - (void) strcpy(convbuf, r->name); + (void) strncpy(convbuf, r->name, 50); else sprintf(convbuf, "REG_0x%x", target); assert(strlen(convbuf) < sizeof(convbuf)); From 5dc319589770ef5471f8e86951118794a0368f93 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 9 Aug 2011 12:16:58 +0000 Subject: [PATCH 0524/2394] Avoiding strcpy, strcat, sprintf usage to make static analyzer happy --- ext/ereg/regex.patch | 58 ++++++++++++++++++++++++++++--- ext/ereg/regex/regerror.c | 11 +++--- ext/ereg/regex/regerror.ih | 2 +- ext/standard/crypt.c | 4 +-- ext/standard/http_fopen_wrapper.c | 4 +-- ext/standard/proc_open.c | 4 +-- ext/standard/user_filters.c | 2 +- ext/xml/xml.c | 4 +-- main/fopen_wrappers.c | 5 +-- main/streams/filter.c | 2 +- 10 files changed, 74 insertions(+), 22 deletions(-) diff --git a/ext/ereg/regex.patch b/ext/ereg/regex.patch index d10a9b9a46361..c1e1d7d483c8c 100644 --- a/ext/ereg/regex.patch +++ b/ext/ereg/regex.patch @@ -1,12 +1,62 @@ +Only in regex: regcomp.lo +Only in regex: regcomp.o diff -u regex.orig/regerror.c regex/regerror.c ---- regex.orig/regerror.c 2011-08-09 17:31:11.000000000 +0800 -+++ regex/regerror.c 2011-08-09 17:29:53.000000000 +0800 -@@ -82,7 +82,7 @@ +--- regex.orig/regerror.c 2011-08-09 19:49:30.000000000 +0800 ++++ regex/regerror.c 2011-08-09 19:46:15.000000000 +0800 +@@ -74,7 +74,7 @@ + char convbuf[50]; + + if (errcode == REG_ATOI) +- s = regatoi(preg, convbuf); ++ s = regatoi(preg, convbuf, sizeof(convbuf)); + else { + for (r = rerrs; r->code >= 0; r++) + if (r->code == target) +@@ -82,9 +82,9 @@ if (errcode®_ITOA) { if (r->code >= 0) - (void) strcpy(convbuf, r->name); + (void) strncpy(convbuf, r->name, 50); else - sprintf(convbuf, "REG_0x%x", target); +- sprintf(convbuf, "REG_0x%x", target); ++ snprintf(convbuf, sizeof(convbuf), "REG_0x%x", target); assert(strlen(convbuf) < sizeof(convbuf)); + s = convbuf; + } else +@@ -106,12 +106,13 @@ + + /* + - regatoi - internal routine to implement REG_ATOI +- == static char *regatoi(const regex_t *preg, char *localbuf); ++ == static char *regatoi(const regex_t *preg, char *localbuf, int bufsize); + */ + static char * +-regatoi(preg, localbuf) ++regatoi(preg, localbuf, bufsize) + const regex_t *preg; + char *localbuf; ++int bufsize; + { + register const struct rerr *r; + +@@ -121,6 +122,6 @@ + if (r->code < 0) + return("0"); + +- sprintf(localbuf, "%d", r->code); ++ snprintf(localbuf, bufsize, "%d", r->code); + return(localbuf); + } +diff -u regex.orig/regerror.ih regex/regerror.ih +--- regex.orig/regerror.ih 2011-08-09 19:49:00.000000000 +0800 ++++ regex/regerror.ih 2011-08-09 19:41:07.000000000 +0800 +@@ -4,7 +4,7 @@ + #endif + + /* === regerror.c === */ +-static char *regatoi(const regex_t *preg, char *localbuf); ++static char *regatoi(const regex_t *preg, char *localbuf, int bufsize); + + #ifdef __cplusplus + } diff --git a/ext/ereg/regex/regerror.c b/ext/ereg/regex/regerror.c index f8c3ca3538f13..05737a462ce3d 100644 --- a/ext/ereg/regex/regerror.c +++ b/ext/ereg/regex/regerror.c @@ -74,7 +74,7 @@ size_t errbuf_size) char convbuf[50]; if (errcode == REG_ATOI) - s = regatoi(preg, convbuf); + s = regatoi(preg, convbuf, sizeof(convbuf)); else { for (r = rerrs; r->code >= 0; r++) if (r->code == target) @@ -84,7 +84,7 @@ size_t errbuf_size) if (r->code >= 0) (void) strncpy(convbuf, r->name, 50); else - sprintf(convbuf, "REG_0x%x", target); + snprintf(convbuf, sizeof(convbuf), "REG_0x%x", target); assert(strlen(convbuf) < sizeof(convbuf)); s = convbuf; } else @@ -106,12 +106,13 @@ size_t errbuf_size) /* - regatoi - internal routine to implement REG_ATOI - == static char *regatoi(const regex_t *preg, char *localbuf); + == static char *regatoi(const regex_t *preg, char *localbuf, int bufsize); */ static char * -regatoi(preg, localbuf) +regatoi(preg, localbuf, bufsize) const regex_t *preg; char *localbuf; +int bufsize; { register const struct rerr *r; @@ -121,6 +122,6 @@ char *localbuf; if (r->code < 0) return("0"); - sprintf(localbuf, "%d", r->code); + snprintf(localbuf, bufsize, "%d", r->code); return(localbuf); } diff --git a/ext/ereg/regex/regerror.ih b/ext/ereg/regex/regerror.ih index 2cb668c24f07e..5ff158e57db48 100644 --- a/ext/ereg/regex/regerror.ih +++ b/ext/ereg/regex/regerror.ih @@ -4,7 +4,7 @@ extern "C" { #endif /* === regerror.c === */ -static char *regatoi(const regex_t *preg, char *localbuf); +static char *regatoi(const regex_t *preg, char *localbuf, int bufsize); #ifdef __cplusplus } diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index 865a25beb1951..3bac50f9e4712 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -170,10 +170,10 @@ PHP_FUNCTION(crypt) /* The automatic salt generation covers standard DES, md5-crypt and Blowfish (simple) */ if (!*salt) { #if PHP_MD5_CRYPT - strcpy(salt, "$1$"); + strncpy(salt, "$1$", PHP_MAX_SALT_LEN); php_to64(&salt[3], PHP_CRYPT_RAND, 4); php_to64(&salt[7], PHP_CRYPT_RAND, 4); - strcpy(&salt[11], "$"); + strncpy(&salt[11], "$", PHP_MAX_SALT_LEN - 11); #elif PHP_STD_DES_CRYPT php_to64(&salt[0], PHP_CRYPT_RAND, 2); salt[2] = '\0'; diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index 7a918d9c8368d..4567efc1f2169 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -330,7 +330,7 @@ php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper, char *path, scratch_len = strlen(path) + 29 + Z_STRLEN_PP(tmpzval); scratch = emalloc(scratch_len); strlcpy(scratch, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval) + 1); - strcat(scratch, " "); + strncat(scratch, " ", 1); } } } @@ -344,7 +344,7 @@ php_stream *php_stream_url_wrap_http_ex(php_stream_wrapper *wrapper, char *path, if (!scratch) { scratch_len = strlen(path) + 29 + protocol_version_len; scratch = emalloc(scratch_len); - strcpy(scratch, "GET "); + strncpy(scratch, "GET ", scratch_len); } /* Should we send the entire path in the request line, default to no. */ diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index 9544cc03da64f..6b7f6ba548b22 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -155,8 +155,8 @@ static php_process_env_t _php_array_to_envp(zval *environment, int is_persistent l = string_length + el_len + 1; memcpy(p, string_key, string_length); - strcat(p, "="); - strcat(p, data); + strncat(p, "=", 1); + strncat(p, data, el_len); #ifndef PHP_WIN32 *ep = p; diff --git a/ext/standard/user_filters.c b/ext/standard/user_filters.c index 752c52af8347c..9afc4f1568a87 100644 --- a/ext/standard/user_filters.c +++ b/ext/standard/user_filters.c @@ -311,7 +311,7 @@ static php_stream_filter *user_filter_factory_create(const char *filtername, period = wildcard + (period - filtername); while (period) { *period = '\0'; - strcat(wildcard, ".*"); + strncat(wildcard, ".*", 2); if (SUCCESS == zend_hash_find(BG(user_filter_map), wildcard, strlen(wildcard) + 1, (void**)&fdat)) { period = NULL; } else { diff --git a/ext/xml/xml.c b/ext/xml/xml.c index 6788c86bc34d8..78237c0bb3dd6 100644 --- a/ext/xml/xml.c +++ b/ext/xml/xml.c @@ -950,7 +950,7 @@ void _xml_characterDataHandler(void *userData, const XML_Char *s, int len) if (zend_hash_find(Z_ARRVAL_PP(parser->ctag),"value",sizeof("value"),(void **) &myval) == SUCCESS) { int newlen = Z_STRLEN_PP(myval) + decoded_len; Z_STRVAL_PP(myval) = erealloc(Z_STRVAL_PP(myval),newlen+1); - strcpy(Z_STRVAL_PP(myval) + Z_STRLEN_PP(myval),decoded_value); + strncpy(Z_STRVAL_PP(myval) + Z_STRLEN_PP(myval), decoded_value, decoded_len + 1); Z_STRLEN_PP(myval) += decoded_len; efree(decoded_value); } else { @@ -970,7 +970,7 @@ void _xml_characterDataHandler(void *userData, const XML_Char *s, int len) if (zend_hash_find(Z_ARRVAL_PP(curtag),"value",sizeof("value"),(void **) &myval) == SUCCESS) { int newlen = Z_STRLEN_PP(myval) + decoded_len; Z_STRVAL_PP(myval) = erealloc(Z_STRVAL_PP(myval),newlen+1); - strcpy(Z_STRVAL_PP(myval) + Z_STRLEN_PP(myval),decoded_value); + strncpy(Z_STRVAL_PP(myval) + Z_STRLEN_PP(myval), decoded_value, decoded_len + 1); Z_STRLEN_PP(myval) += decoded_len; efree(decoded_value); return; diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c index f00127bc06570..f4d122bbbb420 100644 --- a/main/fopen_wrappers.c +++ b/main/fopen_wrappers.c @@ -410,7 +410,8 @@ PHPAPI int php_fopen_primary_script(zend_file_handle *file_handle TSRMLS_DC) #endif if (PG(doc_root) && path_info && (length = strlen(PG(doc_root))) && IS_ABSOLUTE_PATH(PG(doc_root), length)) { - filename = emalloc(length + strlen(path_info) + 2); + int path_len = strlen(path_info); + filename = emalloc(length + path_len + 2); if (filename) { memcpy(filename, PG(doc_root), length); if (!IS_SLASH(filename[length - 1])) { /* length is never 0 */ @@ -419,7 +420,7 @@ PHPAPI int php_fopen_primary_script(zend_file_handle *file_handle TSRMLS_DC) if (IS_SLASH(path_info[0])) { length--; } - strcpy(filename + length, path_info); + strncpy(filename + length, path_info, path_len + 1); } } else { filename = SG(request_info).path_translated; diff --git a/main/streams/filter.c b/main/streams/filter.c index 623c66f96da30..99293259e73fd 100644 --- a/main/streams/filter.c +++ b/main/streams/filter.c @@ -270,7 +270,7 @@ PHPAPI php_stream_filter *php_stream_filter_create(const char *filtername, zval period = wildname + (period - filtername); while (period && !filter) { *period = '\0'; - strcat(wildname, ".*"); + strncat(wildname, ".*", 2); if (SUCCESS == zend_hash_find(filter_hash, wildname, strlen(wildname) + 1, (void**)&factory)) { filter = factory->create_filter(filtername, filterparams, persistent TSRMLS_CC); } From 521ce498194f1ed2e33d7f65e2d250e3a0a1d9e3 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 9 Aug 2011 13:10:57 +0000 Subject: [PATCH 0525/2394] Minimize stack usage and added missing dtors --- ext/standard/dns.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/standard/dns.c b/ext/standard/dns.c index 3f740232be83e..dc0ab59367ddc 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -118,7 +118,7 @@ static char *php_gethostbyname(char *name); Get the host name of the current machine */ PHP_FUNCTION(gethostname) { - char buf[4096]; + char buf[MAXHOSTNAMELEN]; if (zend_parse_parameters_none() == FAILURE) { return; @@ -830,12 +830,14 @@ PHP_FUNCTION(dns_get_record) #if defined(HAVE_DNS_SEARCH) handle = dns_open(NULL); if (handle == NULL) { + zval_dtor(return_value); RETURN_FALSE; } #elif defined(HAVE_RES_NSEARCH) memset(&state, 0, sizeof(state)); if (res_ninit(handle)) { - RETURN_FALSE; + zval_dtor(return_value); + RETURN_FALSE; } #else res_init(); From de6cd955d6066a1e6b79619f71eadc1ca4574bc1 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Tue, 9 Aug 2011 14:11:56 +0000 Subject: [PATCH 0526/2394] Make static analyzers happy --- ext/phar/phar_object.c | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index 6abf5c33b2d01..70dcc3fbbd3a8 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -1666,11 +1666,14 @@ static int phar_build(zend_object_iterator *iter, void *puser TSRMLS_DC) /* {{{ } test = expand_filepath(fname, NULL TSRMLS_CC); + efree(fname); if (test) { - efree(fname); fname = test; fname_len = strlen(fname); + } else { + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Could not resolve file path"); + return ZEND_HASH_APPLY_STOP; } save = fname; @@ -1696,6 +1699,11 @@ static int phar_build(zend_object_iterator *iter, void *puser TSRMLS_DC) /* {{{ #else fname = expand_filepath(intern->file_name, NULL TSRMLS_CC); #endif + if (!fname) { + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Could not resolve file path"); + return ZEND_HASH_APPLY_STOP; + } + fname_len = strlen(fname); save = fname; goto phar_spl_fileinfo; @@ -1713,6 +1721,14 @@ static int phar_build(zend_object_iterator *iter, void *puser TSRMLS_DC) /* {{{ phar_spl_fileinfo: if (base_len) { temp = expand_filepath(base, NULL TSRMLS_CC); + if (!temp) { + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Could not resolve file path"); + if (save) { + efree(save); + } + return ZEND_HASH_APPLY_STOP; + } + base = temp; base_len = strlen(base); @@ -4086,7 +4102,10 @@ PHP_METHOD(Phar, getStub) if (phar_obj->arc.archive->fp && !phar_obj->arc.archive->is_brandnew && !(stub->flags & PHAR_ENT_COMPRESSION_MASK)) { fp = phar_obj->arc.archive->fp; } else { - fp = php_stream_open_wrapper(phar_obj->arc.archive->fname, "rb", 0, NULL); + if (!(fp = php_stream_open_wrapper(phar_obj->arc.archive->fname, "rb", 0, NULL))) { + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "phar error: unable to open phar \"%s\"", phar_obj->arc.archive->fname); + return; + } if (stub->flags & PHAR_ENT_COMPRESSION_MASK) { char *filter_name; From 79d418845e1e2e3f8b15a8efd9b2c9a89f03e62b Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Tue, 9 Aug 2011 15:11:33 +0000 Subject: [PATCH 0527/2394] update the news. --- NEWS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/NEWS b/NEWS index 2d451c317fbb1..40e877d3ab783 100644 --- a/NEWS +++ b/NEWS @@ -169,6 +169,10 @@ PHP NEWS . Added paged results support. FR #42060. (ando@OpenLDAP.org, iarenuno@eteo.mondragon.edu, jeanseb@au-fil-du.net, remy.saissy@gmail.com) +- Improved mbstring extension: + . Added Shift_JIS Emoji (pictograms) support. (rui) + . Ill-formed UTF-8 check for security enhancements. (rui) + - Improved MySQL extensions: . MySQL: Deprecated mysql_list_dbs(). FR #50667. (Andrey) . mysqlnd: Added named pipes support. FR #48082. (Andrey) From 1e960014c11fb02302636761e0a57846d7811ec1 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Tue, 9 Aug 2011 15:27:25 +0000 Subject: [PATCH 0528/2394] Fix typos in UPGRADING --- UPGRADING | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/UPGRADING b/UPGRADING index 6b2f6488c1bc9..69a8eff903262 100755 --- a/UPGRADING +++ b/UPGRADING @@ -100,7 +100,7 @@ UPGRADE NOTES - PHP X.Y To create a generic object you can use StdClass: $test = new StdClass; - $text->baz = 1; + $test->baz = 1; ===================================== 4. Changes made to existing functions @@ -328,7 +328,7 @@ UPGRADE NOTES - PHP X.Y multibyte support, but may enable or disable it by zend.multibyte. It doesn't make a lot of sense to enable this option without ext/mbstring, because the most functionality is implemented by mbstrings callbacks. -- Added enable_post_data_reading, which is enable by default. When it's +- Added enable_post_data_reading, which is enabled by default. When it's disabled, the POST data is not read (and processed); the behavior is similar to that of other request methods with body, like PUT. This allows reading the raw POST data in multipart requests and read/process the POST data in a From 0c83631303de37ff5c6a7baaebe7f3d37046dfdf Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Tue, 9 Aug 2011 18:12:06 +0000 Subject: [PATCH 0529/2394] Fix building of pure C++ extensions as static --- build/genif.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/genif.sh b/build/genif.sh index 61d1f00454889..14e19b7d9a466 100644 --- a/build/genif.sh +++ b/build/genif.sh @@ -24,7 +24,7 @@ cd $srcdir module_ptrs="$extra_module_ptrs`echo $@ | $awk -f ./build/order_by_dep.awk`" for ext in ${1+"$@"} ; do - header_list="$header_list ext/$ext/*.h" + header_list="$header_list ext/$ext/*.h*" done includes=`$awk -f ./build/print_include.awk $header_list` From 58da15422cb2f4cc9d70742e43d4840adff48d1f Mon Sep 17 00:00:00 2001 From: Nuno Lopes Date: Tue, 9 Aug 2011 21:53:44 +0000 Subject: [PATCH 0530/2394] terminate timeouting processes with SIGKILL (9) --- run-tests.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/run-tests.php b/run-tests.php index a615efccdcff8..ddd1f5f494a42 100755 --- a/run-tests.php +++ b/run-tests.php @@ -1082,7 +1082,7 @@ function system_with_timeout($commandline, $env = null, $stdin = null) } else if ($n === 0) { /* timed out */ $data .= b"\n ** ERROR: process timed out **\n"; - proc_terminate($proc); + proc_terminate($proc, 9); return $data; } else if ($n > 0) { $line = (binary) fread($pipes[1], 8192); From 1a41799226bf4e0ce9138b31f6f70c41317ad975 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Wed, 10 Aug 2011 01:12:52 +0000 Subject: [PATCH 0531/2394] Remove unused variable --- ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c index 03c4c0c793f97..2afecb83283f5 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c @@ -423,7 +423,7 @@ mbfl_filt_conv_sjis_mac_wchar(int c, mbfl_convert_filter *filter) int mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) { - int i, j; + int i; int c1, c2, s1, s2, mode; s1 = 0; From 70c284009d42d2ad868a649715150a9de84cef8b Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Wed, 10 Aug 2011 11:01:09 +0000 Subject: [PATCH 0532/2394] fix coverity issue 1054: missing break/return --- main/output.c | 1 + 1 file changed, 1 insertion(+) diff --git a/main/output.c b/main/output.c index a70c4340f066b..6006b5321d19f 100644 --- a/main/output.c +++ b/main/output.c @@ -618,6 +618,7 @@ PHPAPI int php_output_handler_hook(php_output_handler_hook_t type, void *arg TSR return SUCCESS; case PHP_OUTPUT_HANDLER_HOOK_GET_LEVEL: *(int *) arg = OG(running)->level; + return SUCCESS; case PHP_OUTPUT_HANDLER_HOOK_IMMUTABLE: OG(running)->flags &= ~(PHP_OUTPUT_HANDLER_REMOVABLE|PHP_OUTPUT_HANDLER_CLEANABLE); return SUCCESS; From d5688cd19e2f23754d24bc579cc19f2df3f78c5f Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 10 Aug 2011 11:59:11 +0000 Subject: [PATCH 0533/2394] Eliminated compiler's warnings --- ext/standard/html.c | 4 ++-- ext/standard/php_incomplete_class.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/standard/html.c b/ext/standard/html.c index 50bc307927d8d..56b33d4fafd54 100644 --- a/ext/standard/html.c +++ b/ext/standard/html.c @@ -378,7 +378,7 @@ static enum entity_charset determine_charset(char *charset_hint TSRMLS_DC) zenc = zend_multibyte_get_internal_encoding(TSRMLS_C); if (zenc != NULL) { - charset_hint = zend_multibyte_get_encoding_name(zenc); + charset_hint = (char *)zend_multibyte_get_encoding_name(zenc); if (charset_hint != NULL && (len=strlen(charset_hint)) != 0) { if ((len == 4) /* sizeof (none|auto|pass) */ && (!memcmp("pass", charset_hint, 4) || @@ -1371,7 +1371,7 @@ PHPAPI char *php_escape_html_entities_ex(unsigned char *old, size_t oldlen, size unsigned code_point; int valid; char *pos = (char*)&old[cursor+1]; - valid = process_numeric_entity(&pos, &code_point); + valid = process_numeric_entity((const char **)&pos, &code_point); if (valid == FAILURE) goto encode_amp; if (flags & ENT_HTML_SUBSTITUTE_DISALLOWED_CHARS) { diff --git a/ext/standard/php_incomplete_class.h b/ext/standard/php_incomplete_class.h index 38796c2c96dc4..e89f9378646bb 100644 --- a/ext/standard/php_incomplete_class.h +++ b/ext/standard/php_incomplete_class.h @@ -38,7 +38,7 @@ free_class_name = 1; \ incomplete_class = 1; \ } else { \ - free_class_name = !zend_get_object_classname(struc, &class_name, &name_len TSRMLS_CC);\ + free_class_name = !zend_get_object_classname(struc, (const char **)&class_name, &name_len TSRMLS_CC);\ } #define PHP_CLEANUP_CLASS_ATTRIBUTES() \ From dc5b3231dc607afb73613da56f912fd5152e0532 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 10 Aug 2011 13:44:48 +0000 Subject: [PATCH 0534/2394] Fixed bug #55323 (SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself) --- ext/soap/php_encoding.c | 39 +++++++++++++++++++++++- ext/soap/tests/bugs/bug55323.phpt | 45 ++++++++++++++++++++++++++++ ext/soap/tests/bugs/bug55323.wsdl | 50 +++++++++++++++++++++++++++++++ 3 files changed, 133 insertions(+), 1 deletion(-) create mode 100644 ext/soap/tests/bugs/bug55323.phpt create mode 100644 ext/soap/tests/bugs/bug55323.wsdl diff --git a/ext/soap/php_encoding.c b/ext/soap/php_encoding.c index e87c84b263628..5469d6d826102 100644 --- a/ext/soap/php_encoding.c +++ b/ext/soap/php_encoding.c @@ -114,6 +114,26 @@ static void set_ns_and_type(xmlNodePtr node, encodeTypePtr type); } \ } +#define CHECK_XML_NULL(xml) \ + { \ + xmlAttrPtr null; \ + if (!xml) { \ + zval *ret; \ + ALLOC_INIT_ZVAL(ret); \ + ZVAL_NULL(ret); \ + return ret; \ + } \ + if (xml->properties) { \ + null = get_attribute(xml->properties, "nil"); \ + if (null) { \ + zval *ret; \ + ALLOC_INIT_ZVAL(ret); \ + ZVAL_NULL(ret); \ + return ret; \ + } \ + } \ + } + #define FIND_ZVAL_NULL(zval, xml, style) \ { \ if (!zval || Z_TYPE_P(zval) == IS_NULL) { \ @@ -338,6 +358,19 @@ static zend_bool soap_check_zval_ref(zval *data, xmlNodePtr node TSRMLS_DC) { return 0; } +static zval* soap_find_xml_ref(xmlNodePtr node TSRMLS_DC) +{ + zval **data_ptr; + + if (SOAP_GLOBAL(ref_map) && + zend_hash_index_find(SOAP_GLOBAL(ref_map), (ulong)node, (void**)&data_ptr) == SUCCESS) { + Z_SET_ISREF_PP(data_ptr); + Z_ADDREF_PP(data_ptr); + return *data_ptr; + } + return NULL; +} + static zend_bool soap_check_xml_ref(zval **data, xmlNodePtr node TSRMLS_DC) { zval **data_ptr; @@ -1497,6 +1530,11 @@ static zval *to_zval_object_ex(encodeTypePtr type, xmlNodePtr data, zend_class_e sdlType->encode->details.sdl_type->kind != XSD_TYPEKIND_LIST && sdlType->encode->details.sdl_type->kind != XSD_TYPEKIND_UNION) { + CHECK_XML_NULL(data); + if ((ret = soap_find_xml_ref(data TSRMLS_CC)) != NULL) { + return ret; + } + if (ce != ZEND_STANDARD_CLASS_DEF_PTR && sdlType->encode->to_zval == sdl_guess_convert_zval && sdlType->encode->details.sdl_type != NULL && @@ -1510,7 +1548,6 @@ static zval *to_zval_object_ex(encodeTypePtr type, xmlNodePtr data, zend_class_e } else { ret = master_to_zval_int(sdlType->encode, data TSRMLS_CC); } - FIND_XML_NULL(data, ret); if (soap_check_xml_ref(&ret, data TSRMLS_CC)) { return ret; } diff --git a/ext/soap/tests/bugs/bug55323.phpt b/ext/soap/tests/bugs/bug55323.phpt new file mode 100644 index 0000000000000..7855dd845a780 --- /dev/null +++ b/ext/soap/tests/bugs/bug55323.phpt @@ -0,0 +1,45 @@ +--TEST-- +Bug #55323 (SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself) +--SKIPIF-- + +--FILE-- + + + + + 1234 + + + + + +EOF; + } + +} + +$soapClient = new TestSoapClient($wsdl, + array('trace' => 1, 'exceptions' => 0)); +$result = $soapClient->getObject(); +var_dump($result); +?> +--EXPECTF-- +object(stdClass)#%d (2) { + ["accountId"]=> + int(1234) + ["parent"]=> + *RECURSION* +} diff --git a/ext/soap/tests/bugs/bug55323.wsdl b/ext/soap/tests/bugs/bug55323.wsdl new file mode 100644 index 0000000000000..c260d34f4eb5a --- /dev/null +++ b/ext/soap/tests/bugs/bug55323.wsdl @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From e289cf7267a7579368b397cd966bc140041c116d Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 10 Aug 2011 14:12:24 +0000 Subject: [PATCH 0535/2394] relax constraint --- ext/mysqlnd/mysqlnd.c | 2 +- ext/mysqlnd/mysqlnd_structs.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index e850862c88e21..80d315a1bd2a2 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -1404,7 +1404,7 @@ MYSQLND_METHOD(mysqlnd_conn, ssl_set)(MYSQLND * const conn, const char * key, co /* {{{ mysqlnd_conn::escape_string */ static ulong -MYSQLND_METHOD(mysqlnd_conn, escape_string)(const MYSQLND * const conn, char *newstr, const char *escapestr, size_t escapestr_len TSRMLS_DC) +MYSQLND_METHOD(mysqlnd_conn, escape_string)(MYSQLND * const conn, char *newstr, const char *escapestr, size_t escapestr_len TSRMLS_DC) { DBG_ENTER("mysqlnd_conn::escape_string"); DBG_INF_FMT("conn=%llu", conn->thread_id); diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 94af6ced24a82..8c3762f9a4bfa 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -352,7 +352,7 @@ struct st_mysqlnd_protocol_methods typedef enum_func_status (*func_mysqlnd_conn__init)(MYSQLND * conn TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn__connect)(MYSQLND *conn, const char *host, const char * user, const char * passwd, unsigned int passwd_len, const char * db, unsigned int db_len, unsigned int port, const char * socket_or_pipe, unsigned int mysql_flags TSRMLS_DC); -typedef ulong (*func_mysqlnd_conn__escape_string)(const MYSQLND * const conn, char *newstr, const char *escapestr, size_t escapestr_len TSRMLS_DC); +typedef ulong (*func_mysqlnd_conn__escape_string)(MYSQLND * const conn, char *newstr, const char *escapestr, size_t escapestr_len TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn__set_charset)(MYSQLND * const conn, const char * const charset TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn__query)(MYSQLND *conn, const char *query, unsigned int query_len TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn__send_query)(MYSQLND *conn, const char *query, unsigned int query_len TSRMLS_DC); From d73bad2f93433c7063879d885a33db0fbf8a5287 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 10 Aug 2011 15:30:07 +0000 Subject: [PATCH 0536/2394] Fixed memset usage (identified by coverity) --- ext/sqlite3/sqlite3.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c index a4f35aeeb793e..dbb81710abcce 100644 --- a/ext/sqlite3/sqlite3.c +++ b/ext/sqlite3/sqlite3.c @@ -2002,7 +2002,7 @@ static zend_object_value php_sqlite3_object_new(zend_class_entry *class_type TSR /* Allocate memory for it */ intern = emalloc(sizeof(php_sqlite3_db_object)); - memset(&intern->zo, 0, sizeof(php_sqlite3_db_object)); + memset(intern, 0, sizeof(php_sqlite3_db_object)); intern->exception = 0; /* Need to keep track of things to free */ @@ -2025,7 +2025,7 @@ static zend_object_value php_sqlite3_stmt_object_new(zend_class_entry *class_typ /* Allocate memory for it */ intern = emalloc(sizeof(php_sqlite3_stmt)); - memset(&intern->zo, 0, sizeof(php_sqlite3_stmt)); + memset(intern, 0, sizeof(php_sqlite3_stmt)); intern->db_obj_zval = NULL; @@ -2046,7 +2046,7 @@ static zend_object_value php_sqlite3_result_object_new(zend_class_entry *class_t /* Allocate memory for it */ intern = emalloc(sizeof(php_sqlite3_result)); - memset(&intern->zo, 0, sizeof(php_sqlite3_result)); + memset(intern, 0, sizeof(php_sqlite3_result)); intern->complete = 0; intern->is_prepared_statement = 0; From b207eebf57cf899e0396c785d273380596028022 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 10 Aug 2011 15:59:32 +0000 Subject: [PATCH 0537/2394] Fix win32 build --- ext/standard/dns.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/standard/dns.c b/ext/standard/dns.c index dc0ab59367ddc..d0979a32f984a 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -62,6 +62,10 @@ #define AF_INET 2 /* internetwork: UDP, TCP, etc. */ #endif +#ifndef MAXHOSTNAMELEN +#define MAXHOSTNAMELEN 255 +#endif + #include "php_dns.h" /* type compat */ From 840ef1e3203778e4872bb96cd648fa2b396da91d Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Wed, 10 Aug 2011 16:31:29 +0000 Subject: [PATCH 0538/2394] - Turn on html_errors by default again in php.ini-production like it was in PHP 5.3, but only generate docref links when the docref_root INI setting is not empty. --- main/main.c | 6 +++--- php.ini-development | 19 ++++++++++--------- php.ini-production | 21 +++++++++++---------- 3 files changed, 24 insertions(+), 22 deletions(-) diff --git a/main/main.c b/main/main.c index f6b90314394e3..9caf5bc02afce 100644 --- a/main/main.c +++ b/main/main.c @@ -721,10 +721,10 @@ PHPAPI void php_verror(const char *docref, const char *params, int type, const c } /* we have a docref for a function AND - * - we show erroes in html mode OR - * - the user wants to see the links anyway + * - we show errors in html mode AND + * - the user wants to see the links */ - if (docref && is_function && (PG(html_errors) || strlen(PG(docref_root)))) { + if (docref && is_function && PG(html_errors) && strlen(PG(docref_root))) { if (strncmp(docref, "http://", 7)) { /* We don't have 'http://' so we use docref_root */ diff --git a/php.ini-development b/php.ini-development index bbb22dd6d9e53..df35cad7873f0 100644 --- a/php.ini-development +++ b/php.ini-development @@ -109,7 +109,7 @@ ; html_errors ; Default Value: On ; Development Value: On -; Production value: Off +; Production value: On ; log_errors ; Default Value: Off @@ -532,23 +532,24 @@ track_errors = On ; An XML-RPC faultCode ;xmlrpc_error_number = 0 -; When PHP displays or logs an error, it has the capability of inserting html -; links to documentation related to that error. This directive controls whether -; those HTML links appear in error messages or not. For performance and security -; reasons, it's recommended you disable this on production servers. +; When PHP displays or logs an error, it has the capability of formatting the +; error message as HTML for easier reading. This directive controls whether +; the error message is formatted as HTML or not. ; Note: This directive is hardcoded to Off for the CLI SAPI ; Default Value: On ; Development Value: On -; Production value: Off +; Production value: On ; http://php.net/html-errors html_errors = On -; If html_errors is set On PHP produces clickable error messages that direct -; to a page describing the error or function causing the error in detail. +; If html_errors is set to On *and* docref_root is not empty, then PHP +; produces clickable error messages that direct to a page describing the error +; or function causing the error in detail. ; You can download a copy of the PHP manual from http://php.net/docs ; and change docref_root to the base URL of your local copy including the ; leading '/'. You must also specify the file extension being used including -; the dot. PHP's default behavior is to leave these settings empty. +; the dot. PHP's default behavior is to leave these settings empty, in which +; case no links to documentation are generated. ; Note: Never use this feature for production boxes. ; http://php.net/docref-root ; Examples diff --git a/php.ini-production b/php.ini-production index 8e0773ffc1076..d814d72ba227c 100644 --- a/php.ini-production +++ b/php.ini-production @@ -109,7 +109,7 @@ ; html_errors ; Default Value: On ; Development Value: On -; Production value: Off +; Production value: On ; log_errors ; Default Value: Off @@ -532,23 +532,24 @@ track_errors = Off ; An XML-RPC faultCode ;xmlrpc_error_number = 0 -; When PHP displays or logs an error, it has the capability of inserting html -; links to documentation related to that error. This directive controls whether -; those HTML links appear in error messages or not. For performance and security -; reasons, it's recommended you disable this on production servers. +; When PHP displays or logs an error, it has the capability of formatting the +; error message as HTML for easier reading. This directive controls whether +; the error message is formatted as HTML or not. ; Note: This directive is hardcoded to Off for the CLI SAPI ; Default Value: On ; Development Value: On -; Production value: Off +; Production value: On ; http://php.net/html-errors -html_errors = Off +html_errors = On -; If html_errors is set On PHP produces clickable error messages that direct -; to a page describing the error or function causing the error in detail. +; If html_errors is set to On *and* docref_root is not empty, then PHP +; produces clickable error messages that direct to a page describing the error +; or function causing the error in detail. ; You can download a copy of the PHP manual from http://php.net/docs ; and change docref_root to the base URL of your local copy including the ; leading '/'. You must also specify the file extension being used including -; the dot. PHP's default behavior is to leave these settings empty. +; the dot. PHP's default behavior is to leave these settings empty, in which +; case no links to documentation are generated. ; Note: Never use this feature for production boxes. ; http://php.net/docref-root ; Examples From 46f5813895ea0e638e196629b0480023ee4ced06 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Wed, 10 Aug 2011 17:40:56 +0000 Subject: [PATCH 0539/2394] Use HOST_NAME_MAX constant here instead for the gethostname() func --- ext/standard/dns.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ext/standard/dns.c b/ext/standard/dns.c index d0979a32f984a..8906bd800770b 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -66,6 +66,12 @@ #define MAXHOSTNAMELEN 255 #endif +/* For the local hostname obtained via gethostname which is different from the + dns-related MAXHOSTNAMELEN constant above */ +#ifndef HOST_NAME_MAX +#define HOST_NAME_MAX 255 +#endif + #include "php_dns.h" /* type compat */ @@ -122,7 +128,7 @@ static char *php_gethostbyname(char *name); Get the host name of the current machine */ PHP_FUNCTION(gethostname) { - char buf[MAXHOSTNAMELEN]; + char buf[HOST_NAME_MAX]; if (zend_parse_parameters_none() == FAILURE) { return; From 69e98c9a6165c991ab0a2de2b74c865a6d05f244 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 11 Aug 2011 06:38:42 +0000 Subject: [PATCH 0540/2394] Fixed possible memory leak --- sapi/cgi/cgi_main.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index 8500449483ec4..b6acb8145a6d8 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -761,7 +761,7 @@ static void php_cgi_ini_activate_user_config(char *path, int path_len, const cha /* Check whether cache entry has expired and rescan if it is */ if (request_time > entry->expires) { - char * real_path; + char *real_path = NULL; int real_path_len; char *s1, *s2; int s_len; @@ -809,6 +809,9 @@ static void php_cgi_ini_activate_user_config(char *path, int path_len, const cha php_parse_user_ini_file(path, PG(user_ini_filename), entry->user_config TSRMLS_CC); } + if (real_path) { + free(real_path); + } entry->expires = request_time + PG(user_ini_cache_ttl); } From a652bb991dad987f873737af0cc3b02f8fcd6c88 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 11 Aug 2011 07:11:39 +0000 Subject: [PATCH 0541/2394] - fix build (introduce by r314641) --- ext/ereg/regex/regerror.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/ereg/regex/regerror.c b/ext/ereg/regex/regerror.c index 05737a462ce3d..1c66d4114e37c 100644 --- a/ext/ereg/regex/regerror.c +++ b/ext/ereg/regex/regerror.c @@ -8,6 +8,7 @@ #include "regex.h" #include "utils.h" #include "regerror.ih" +#include "php.h" /* = #define REG_OKAY 0 From e780e7bfb96cac4e7de6ce7639a85ab86edac232 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Thu, 11 Aug 2011 07:52:04 +0000 Subject: [PATCH 0542/2394] Recored change into regex.patch --- ext/ereg/regex.patch | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/ext/ereg/regex.patch b/ext/ereg/regex.patch index c1e1d7d483c8c..9bc448d7a7dde 100644 --- a/ext/ereg/regex.patch +++ b/ext/ereg/regex.patch @@ -1,9 +1,15 @@ -Only in regex: regcomp.lo -Only in regex: regcomp.o diff -u regex.orig/regerror.c regex/regerror.c --- regex.orig/regerror.c 2011-08-09 19:49:30.000000000 +0800 -+++ regex/regerror.c 2011-08-09 19:46:15.000000000 +0800 -@@ -74,7 +74,7 @@ ++++ regex/regerror.c 2011-08-11 15:13:42.000000000 +0800 +@@ -8,6 +8,7 @@ + #include "regex.h" + #include "utils.h" + #include "regerror.ih" ++#include "php.h" + + /* + = #define REG_OKAY 0 +@@ -74,7 +75,7 @@ char convbuf[50]; if (errcode == REG_ATOI) @@ -12,7 +18,7 @@ diff -u regex.orig/regerror.c regex/regerror.c else { for (r = rerrs; r->code >= 0; r++) if (r->code == target) -@@ -82,9 +82,9 @@ +@@ -82,9 +83,9 @@ if (errcode®_ITOA) { if (r->code >= 0) @@ -24,7 +30,7 @@ diff -u regex.orig/regerror.c regex/regerror.c assert(strlen(convbuf) < sizeof(convbuf)); s = convbuf; } else -@@ -106,12 +106,13 @@ +@@ -106,12 +107,13 @@ /* - regatoi - internal routine to implement REG_ATOI @@ -40,7 +46,7 @@ diff -u regex.orig/regerror.c regex/regerror.c { register const struct rerr *r; -@@ -121,6 +122,6 @@ +@@ -121,6 +123,6 @@ if (r->code < 0) return("0"); From 78c823067f66de77bb3424b523dc5d7bf242d46a Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Thu, 11 Aug 2011 13:01:52 +0000 Subject: [PATCH 0543/2394] Fixed bug #55399 (parse_url() incorrectly treats ':' as a valid path) --- ext/standard/tests/url/bug55399.phpt | 10 ++++++++++ ext/standard/url.c | 4 ++++ 2 files changed, 14 insertions(+) create mode 100644 ext/standard/tests/url/bug55399.phpt diff --git a/ext/standard/tests/url/bug55399.phpt b/ext/standard/tests/url/bug55399.phpt new file mode 100644 index 0000000000000..619c08da6d048 --- /dev/null +++ b/ext/standard/tests/url/bug55399.phpt @@ -0,0 +1,10 @@ +--TEST-- +Bug #55399 (parse_url() incorrectly treats ':' as a valid path) +--FILE-- + +--EXPECT-- +bool(false) diff --git a/ext/standard/url.c b/ext/standard/url.c index e516f15982186..0a1903a22deda 100644 --- a/ext/standard/url.c +++ b/ext/standard/url.c @@ -197,6 +197,10 @@ PHPAPI php_url *php_url_parse_ex(char const *str, int length) efree(ret); return NULL; } + } else if (p == pp && *pp == '\0') { + STR_FREE(ret->scheme); + efree(ret); + return NULL; } else { goto just_path; } From 96eff171611d04fc8025c0c526a589de63226a49 Mon Sep 17 00:00:00 2001 From: Uwe Schindler Date: Thu, 11 Aug 2011 20:25:24 +0000 Subject: [PATCH 0544/2394] Bug #55403: Don't set $_SERVER['HTTPS'] on unsecure connection --- sapi/nsapi/nsapi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sapi/nsapi/nsapi.c b/sapi/nsapi/nsapi.c index fa73301f62af7..a2081eb0c8f11 100644 --- a/sapi/nsapi/nsapi.c +++ b/sapi/nsapi/nsapi.c @@ -723,7 +723,9 @@ static void sapi_nsapi_register_server_variables(zval *track_vars_array TSRMLS_D nsapi_free(value); php_register_variable("SERVER_SOFTWARE", system_version(), track_vars_array TSRMLS_CC); - php_register_variable("HTTPS", (security_active ? "ON" : "OFF"), track_vars_array TSRMLS_CC); + if (security_active) { + php_register_variable("HTTPS", "ON", track_vars_array TSRMLS_CC); + } php_register_variable("GATEWAY_INTERFACE", "CGI/1.1", track_vars_array TSRMLS_CC); /* DOCUMENT_ROOT */ From fa1883de19b15ab224740d3f8347761013627157 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 12 Aug 2011 07:47:03 +0000 Subject: [PATCH 0545/2394] Omitted GCC warning "comparison is always false" --- ext/ereg/ereg.c | 5 +++-- ext/ereg/regex.patch | 20 ++++++++++++-------- ext/ereg/regex/regerror.c | 8 +++++--- ext/standard/var.c | 6 +++--- main/streams/cast.c | 2 +- 5 files changed, 24 insertions(+), 17 deletions(-) diff --git a/ext/ereg/ereg.c b/ext/ereg/ereg.c index c2b065210a561..0dd6845d628b8 100644 --- a/ext/ereg/ereg.c +++ b/ext/ereg/ereg.c @@ -474,7 +474,8 @@ PHP_EREG_API char *php_ereg_replace(const char *pattern, const char *replace, co if (new_l + 1 > buf_len) { buf_len = 1 + buf_len + 2 * new_l; nbuf = emalloc(buf_len); - strncpy(nbuf, buf, buf_len-1); + strncpy(nbuf, buf, buf_len - 1); + nbuf[buf_len - 1] = '\0'; efree(buf); buf = nbuf; } @@ -486,7 +487,7 @@ PHP_EREG_API char *php_ereg_replace(const char *pattern, const char *replace, co walkbuf = &buf[tmp + subs[0].rm_so]; walk = replace; while (*walk) { - if ('\\' == *walk && isdigit(walk[1]) && walk[1] - '0' <= (int)re.re_nsub) { + if ('\\' == *walk && isdigit((unsigned char)walk[1]) && (unsigned char)walk[1] - '0' <= (int)re.re_nsub) { if (subs[walk[1] - '0'].rm_so > -1 && subs[walk[1] - '0'].rm_eo > -1 /* this next case shouldn't happen. it does. */ && subs[walk[1] - '0'].rm_so <= subs[walk[1] - '0'].rm_eo) { diff --git a/ext/ereg/regex.patch b/ext/ereg/regex.patch index 9bc448d7a7dde..864e6bb6d81c9 100644 --- a/ext/ereg/regex.patch +++ b/ext/ereg/regex.patch @@ -1,6 +1,6 @@ diff -u regex.orig/regerror.c regex/regerror.c --- regex.orig/regerror.c 2011-08-09 19:49:30.000000000 +0800 -+++ regex/regerror.c 2011-08-11 15:13:42.000000000 +0800 ++++ regex/regerror.c 2011-08-12 10:45:57.000000000 +0800 @@ -8,6 +8,7 @@ #include "regex.h" #include "utils.h" @@ -9,7 +9,7 @@ diff -u regex.orig/regerror.c regex/regerror.c /* = #define REG_OKAY 0 -@@ -74,7 +75,7 @@ +@@ -74,17 +75,19 @@ char convbuf[50]; if (errcode == REG_ATOI) @@ -18,19 +18,23 @@ diff -u regex.orig/regerror.c regex/regerror.c else { for (r = rerrs; r->code >= 0; r++) if (r->code == target) -@@ -82,9 +83,9 @@ + break; if (errcode®_ITOA) { - if (r->code >= 0) +- if (r->code >= 0) - (void) strcpy(convbuf, r->name); -+ (void) strncpy(convbuf, r->name, 50); - else +- else - sprintf(convbuf, "REG_0x%x", target); ++ if (r->code >= 0) { ++ (void) strncpy(convbuf, r->name, sizeof(convbuf) - 1); ++ convbuf[sizeof(convbuf) - 1] = '\0'; ++ } else { + snprintf(convbuf, sizeof(convbuf), "REG_0x%x", target); ++ } assert(strlen(convbuf) < sizeof(convbuf)); s = convbuf; } else -@@ -106,12 +107,13 @@ +@@ -106,12 +109,13 @@ /* - regatoi - internal routine to implement REG_ATOI @@ -46,7 +50,7 @@ diff -u regex.orig/regerror.c regex/regerror.c { register const struct rerr *r; -@@ -121,6 +123,6 @@ +@@ -121,6 +125,6 @@ if (r->code < 0) return("0"); diff --git a/ext/ereg/regex/regerror.c b/ext/ereg/regex/regerror.c index 1c66d4114e37c..7bf741967ddcb 100644 --- a/ext/ereg/regex/regerror.c +++ b/ext/ereg/regex/regerror.c @@ -82,10 +82,12 @@ size_t errbuf_size) break; if (errcode®_ITOA) { - if (r->code >= 0) - (void) strncpy(convbuf, r->name, 50); - else + if (r->code >= 0) { + (void) strncpy(convbuf, r->name, sizeof(convbuf) - 1); + convbuf[sizeof(convbuf) - 1] = '\0'; + } else { snprintf(convbuf, sizeof(convbuf), "REG_0x%x", target); + } assert(strlen(convbuf) < sizeof(convbuf)); s = convbuf; } else diff --git a/ext/standard/var.c b/ext/standard/var.c index cf9342db4f193..404504a1f3731 100644 --- a/ext/standard/var.c +++ b/ext/standard/var.c @@ -601,7 +601,7 @@ static inline zend_bool php_var_serialize_class_name(smart_str *buf, zval *struc PHP_SET_CLASS_ATTRIBUTES(struc); smart_str_appendl(buf, "O:", 2); - smart_str_append_long(buf, (long)name_len); + smart_str_append_long(buf, (int)name_len); smart_str_appendl(buf, ":\"", 2); smart_str_appendl(buf, class_name, name_len); smart_str_appendl(buf, "\":", 2); @@ -767,12 +767,12 @@ static void php_var_serialize_intern(smart_str *buf, zval *struc, HashTable *var if (ce->serialize(struc, &serialized_data, &serialized_length, (zend_serialize_data *)var_hash TSRMLS_CC) == SUCCESS) { smart_str_appendl(buf, "C:", 2); - smart_str_append_long(buf, (long)Z_OBJCE_P(struc)->name_length); + smart_str_append_long(buf, (int)Z_OBJCE_P(struc)->name_length); smart_str_appendl(buf, ":\"", 2); smart_str_appendl(buf, Z_OBJCE_P(struc)->name, Z_OBJCE_P(struc)->name_length); smart_str_appendl(buf, "\":", 2); - smart_str_append_long(buf, (long)serialized_length); + smart_str_append_long(buf, (int)serialized_length); smart_str_appendl(buf, ":{", 2); smart_str_appendl(buf, serialized_data, serialized_length); smart_str_appendc(buf, '}'); diff --git a/main/streams/cast.c b/main/streams/cast.c index debbd82707492..38eb1a987c009 100644 --- a/main/streams/cast.c +++ b/main/streams/cast.c @@ -271,7 +271,7 @@ PHPAPI int _php_stream_cast(php_stream *stream, int castas, void **ret, int show newstream = php_stream_fopen_tmpfile(); if (newstream) { - int retval = php_stream_copy_to_stream_ex(stream, newstream, PHP_STREAM_COPY_ALL, NULL); + size_t retval = php_stream_copy_to_stream_ex(stream, newstream, PHP_STREAM_COPY_ALL, NULL); if (ret != SUCCESS) { php_stream_close(newstream); From 17fb279359b07637c4acb5e8232cade77466ccfc Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 12 Aug 2011 11:23:16 +0000 Subject: [PATCH 0546/2394] Andrey, please have a look. This should not cause errors. --- .../mysqli_stmt_execute_stored_proc_out.phpt | 75 +++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt diff --git a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt new file mode 100644 index 0000000000000..c6053bcae8fbb --- /dev/null +++ b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt @@ -0,0 +1,75 @@ +--TEST-- +mysqli_stmt_execute() - OUT +--SKIPIF-- + +--FILE-- +query("SELECT 1")) + printf("[013] [%d] %s\n", $link->errno, $link->error); + + } else { + printf("[004] Cannot create SP, [%d] %s.\n", mysqli_errno($link), mysqli_error($link)); + } + + mysqli_close($link); + print "done!"; +?> +--CLEAN-- + +--EXPECTF-- +[008] More results: %s +[009] Next results: %s +done! \ No newline at end of file From caca6934031b7d76311117eb144b7ff6bc3cc921 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 12 Aug 2011 11:23:36 +0000 Subject: [PATCH 0547/2394] Andrey, please have a look. Not sure if the test is correct, e.g. MySQL 5.5.3+ really needed? --- ..._stmt_execute_stored_proc_next_result.phpt | 125 ++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt diff --git a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt new file mode 100644 index 0000000000000..1f92ca1f885e0 --- /dev/null +++ b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt @@ -0,0 +1,125 @@ +--TEST-- +mysqli_stmt_execute() - SP, next result +--SKIPIF-- + +--FILE-- +query("SELECT 1")) + printf("[013] [%d] %s\n", $link->errno, $link->error); + + } else { + printf("[004] Cannot create SP, [%d] %s.\n", mysqli_errno($link), mysqli_error($link)); + } + + if (!mysqli_query($link, 'DROP PROCEDURE IF EXISTS p')) + printf("[014] [%d] %s.\n", mysqli_errno($link), mysqli_error($link)); + + if (mysqli_real_query($link, 'CREATE PROCEDURE p(IN ver_in VARCHAR(25)) BEGIN SELECT ver_in AS _ver_out; SELECT 1 AS _more; END;')) { + // two result sets + if (!$stmt = mysqli_prepare($link, 'CALL p(?)')) + printf("[015] Cannot prepare CALL, [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + + $version = 'myversion'; + if (!mysqli_stmt_bind_param($stmt, 's', $version)) + printf("[016] Cannot bind input parameter, [%d] %s\n", mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + if (!mysqli_stmt_execute($stmt)) + printf("[017] Cannot execute CALL, [%d] %s\n", mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + $version = NULL; + if (!mysqli_stmt_bind_result($stmt, $version) || + !mysqli_stmt_fetch($stmt)) + printf("[018] [%d] %s\n", mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + if ($version !== "myversion") + printf("[019] Results seem wrong, got %s, [%d] %s\n", + $version, + mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + if (!mysqli_more_results($link) || !mysqli_next_result($link)) + printf("[020] [%d] %s\n", $link->errno, $link->error); + + $more = NULL; + if (!mysqli_stmt_bind_result($stmt, $more) || + !mysqli_stmt_fetch($stmt)) + printf("[021] [%d] %s\n", mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + if ($more !== 1) + printf("[022] Results seem wrong, got %s, [%d] %s\n", + $more, + mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + if (!mysqli_stmt_close($stmt)) + printf("[023] Cannot close statement, [%d] %s\n", mysqli_stmt_errno($stmt), mysqli_stmt_error($stmt)); + + + if (!$link->query("SELECT 1")) + printf("[024] [%d] %s\n", $link->errno, $link->error); + + } else { + printf("[025] Cannot create SP, [%d] %s.\n", mysqli_errno($link), mysqli_error($link)); + } + + mysqli_close($link); + print "done!"; +?> +--CLEAN-- + +--EXPECTF-- +[010] More results: yes +[011] Next result: yes +done! \ No newline at end of file From 94b7b548c5139f7f2325c300dfb1038feede7bc1 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 12 Aug 2011 11:51:44 +0000 Subject: [PATCH 0548/2394] MySQL 5.6 fractional seconds and PS --- ext/mysqli/tests/mysqli_stmt_bind_param.phpt | 2 ++ ext/mysqli/tests/mysqli_stmt_bind_result.phpt | 3 +++ 2 files changed, 5 insertions(+) diff --git a/ext/mysqli/tests/mysqli_stmt_bind_param.phpt b/ext/mysqli/tests/mysqli_stmt_bind_param.phpt index 71045789bc44a..d2d825438e40f 100644 --- a/ext/mysqli/tests/mysqli_stmt_bind_param.phpt +++ b/ext/mysqli/tests/mysqli_stmt_bind_param.phpt @@ -304,6 +304,8 @@ require_once('skipifconnectfailure.inc'); func_mysqli_stmt_bind_datatype($link, $engine, "s", "SET('a', 'b')", "a", 870); func_mysqli_stmt_bind_datatype($link, $engine, "s", "SET('a', 'b')", NULL, 880); + if (mysqli_get_server_version($link) >= 50600) + func_mysqli_stmt_bind_datatype($link, $engine, "s", "TIME", "13:27:34.123456", 890, "13:27:34"); $stmt = mysqli_stmt_init($link); if (!mysqli_stmt_prepare($stmt, "INSERT INTO test(id, label) VALUES (?, ?)")) diff --git a/ext/mysqli/tests/mysqli_stmt_bind_result.phpt b/ext/mysqli/tests/mysqli_stmt_bind_result.phpt index 26b39d516f44a..553e71ab6b5fc 100644 --- a/ext/mysqli/tests/mysqli_stmt_bind_result.phpt +++ b/ext/mysqli/tests/mysqli_stmt_bind_result.phpt @@ -294,6 +294,9 @@ require_once('skipifconnectfailure.inc'); func_mysqli_stmt_bind_result($link, $engine, "s", "SET('a', 'b')", "a", 1740, $hint_str_or_unicode); func_mysqli_stmt_bind_result($link, $engine, "s", "SET('a', 'b')", NULL, 1760, $hint_str_or_unicode); + if (mysqli_get_server_version($link) >= 50600) + func_mysqli_stmt_bind_result($link, $engine, "s", "TIME", "13:31:34.123456", 1770, "13:31:34"); + /* Check that the function alias exists. It's a deprecated function, but we have not announce the removal so far, therefore we need to check for it */ if (!is_null($tmp = @mysqli_stmt_bind_result())) From 566a367ef6bfcb604620cdc5cc455af553cedccb Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 12 Aug 2011 14:55:00 +0000 Subject: [PATCH 0549/2394] prevent a crash if cs is NULL, which can happen with MS and lazy connections --- ext/mysqli/mysqli_nonapi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index 2844c4df1b0c9..d720f478b0258 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -992,7 +992,6 @@ PHP_FUNCTION(mysqli_get_charset) } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - object_init(return_value); #if !defined(MYSQLI_USE_MYSQLND) mysql_get_character_set_info(mysql->mysql, &cs); @@ -1006,6 +1005,10 @@ PHP_FUNCTION(mysqli_get_charset) comment = cs.comment; #else cs = mysql->mysql->charset; + if (!cs) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "The connection has no charset associated"); + RETURN_NULL(); + } name = cs->name; collation = cs->collation; minlength = cs->char_minlen; @@ -1014,6 +1017,7 @@ PHP_FUNCTION(mysqli_get_charset) comment = cs->comment; state = 1; /* all charsets are compiled in */ #endif + object_init(return_value); add_property_string(return_value, "charset", (name) ? (char *)name : "", 1); add_property_string(return_value, "collation",(collation) ? (char *)collation : "", 1); From 81700b8b2ff48eec7488d066e2c55293f6b7901d Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Fri, 12 Aug 2011 21:46:40 +0000 Subject: [PATCH 0550/2394] Fix CID 1211, unused intern variable --- ext/spl/spl_fixedarray.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c index c49528e89fbd2..dbcb2b23a1e07 100644 --- a/ext/spl/spl_fixedarray.c +++ b/ext/spl/spl_fixedarray.c @@ -602,7 +602,6 @@ SPL_METHOD(SplFixedArray, count) */ SPL_METHOD(SplFixedArray, toArray) { - spl_fixedarray_object *intern; zval *ret, *tmp; HashTable *ret_ht, *obj_ht; @@ -610,8 +609,6 @@ SPL_METHOD(SplFixedArray, toArray) return; } - intern = (spl_fixedarray_object *)zend_object_store_get_object(getThis() TSRMLS_CC); - ALLOC_HASHTABLE(ret_ht); zend_hash_init(ret_ht, 0, NULL, ZVAL_PTR_DTOR, 0); ALLOC_INIT_ZVAL(ret); From 5128d59331fdba2163dc40fb0107118489b47679 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Fri, 12 Aug 2011 22:05:10 +0000 Subject: [PATCH 0551/2394] Fix CID 538/539, explicitely check for something that should never occur --- ext/spl/spl_array.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/ext/spl/spl_array.c b/ext/spl/spl_array.c index a4eecedfd61a7..ba19d0f9322d8 100755 --- a/ext/spl/spl_array.c +++ b/ext/spl/spl_array.c @@ -322,8 +322,11 @@ static zval **spl_array_get_dimension_ptr_ptr(int check_inherited, zval *object, zval *value; ALLOC_INIT_ZVAL(value); zend_symtable_update(ht, Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, (void**)&value, sizeof(void*), NULL); - zend_symtable_find(ht, Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, (void **) &retval); - return retval; + if (zend_symtable_find(ht, Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, (void **) &retval) != FAILURE) { + return retval; + } else { + return &EG(uninitialized_zval_ptr); + } } else { zend_error(E_NOTICE, "Undefined index: %s", Z_STRVAL_P(offset)); return &EG(uninitialized_zval_ptr); @@ -345,8 +348,11 @@ static zval **spl_array_get_dimension_ptr_ptr(int check_inherited, zval *object, zval *value; ALLOC_INIT_ZVAL(value); zend_hash_index_update(ht, index, (void**)&value, sizeof(void*), NULL); - zend_hash_index_find(ht, index, (void **) &retval); - return retval; + if (zend_hash_index_find(ht, index, (void **) &retval) != FAILURE) { + return retval; + } else { + return &EG(uninitialized_zval_ptr); + } } else { zend_error(E_NOTICE, "Undefined offset: %ld", index); return &EG(uninitialized_zval_ptr); From 80742189b80dc39ab1a8f292675775b1dca0864e Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Fri, 12 Aug 2011 22:20:35 +0000 Subject: [PATCH 0552/2394] Fix CID 593 Mark the missing break by an explicit comment, we DO intend to fall through here --- ext/spl/spl_iterators.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index 57f3d5200fbdc..860cccee4d772 100755 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -214,6 +214,7 @@ static void spl_recursive_it_move_forward_ex(spl_recursive_it_object *object, zv zend_clear_exception(TSRMLS_C); } } + /* fall through */ case RS_START: if (iterator->funcs->valid(iterator TSRMLS_CC) == FAILURE) { break; From 0fe5527ed27a87a0f31f393edf27482a7c9fba59 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Sat, 13 Aug 2011 00:43:34 +0000 Subject: [PATCH 0553/2394] More test portability fixes mostly for gcov.php.net --- ext/oci8/tests/bind_char_1.phpt | 2 ++ ext/oci8/tests/bind_char_2.phpt | 2 ++ ext/oci8/tests/bind_char_3.phpt | 2 ++ ext/oci8/tests/bind_char_4.phpt | 2 ++ ext/oci8/tests/bug27303_1.phpt | 4 +++- ext/oci8/tests/bug27303_2.phpt | 4 +++- ext/oci8/tests/bug27303_4.phpt | 2 ++ ext/oci8/tests/lob_029.phpt | 3 ++- ext/oci8/tests/pecl_bug10194.phpt | 1 + ext/oci8/tests/pecl_bug10194_blob.phpt | 1 + ext/oci8/tests/pecl_bug10194_blob_64.phpt | 1 + 11 files changed, 21 insertions(+), 3 deletions(-) diff --git a/ext/oci8/tests/bind_char_1.phpt b/ext/oci8/tests/bind_char_1.phpt index a5b059ed1de43..a668294d4dfe7 100644 --- a/ext/oci8/tests/bind_char_1.phpt +++ b/ext/oci8/tests/bind_char_1.phpt @@ -10,6 +10,8 @@ if (preg_match('/Release 1[01]\.2\./', oci_server_version($c), $matches) !== 1) die("skip test expected to work only with Oracle 11g or greater version of client"); } ?> +--ENV-- +NLS_LANG= --FILE-- +--ENV-- +NLS_LANG= --FILE-- +--ENV-- +NLS_LANG= --FILE-- +--ENV-- +NLS_LANG= --FILE-- +--ENV-- +NLS_LANG= --FILE-- +--ENV-- +NLS_LANG= --FILE-- +--ENV-- +NLS_LANG= --FILE-- --FILE-- true, 'timesten' => false); // test runs on these DBs require(dirname(__FILE__).'/skipif.inc'); +if ($stress_test !== true) die ('skip Test not run when $stress_test is FALSE'); ?> --INI-- memory_limit=10M diff --git a/ext/oci8/tests/pecl_bug10194_blob.phpt b/ext/oci8/tests/pecl_bug10194_blob.phpt index 38f6d9ed2f7c7..75632ce47334d 100644 --- a/ext/oci8/tests/pecl_bug10194_blob.phpt +++ b/ext/oci8/tests/pecl_bug10194_blob.phpt @@ -5,6 +5,7 @@ PECL Bug #10194 (segfault in Instant Client when memory_limit is reached inside $target_dbs = array('oracledb' => true, 'timesten' => false); // test runs on these DBs require(dirname(__FILE__).'/skipif.inc'); if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platforms only"); +if ($stress_test !== true) die ('skip Test not run when $stress_test is FALSE'); ?> --INI-- memory_limit=3M diff --git a/ext/oci8/tests/pecl_bug10194_blob_64.phpt b/ext/oci8/tests/pecl_bug10194_blob_64.phpt index 9ffc03d320376..da7ec592fc63c 100644 --- a/ext/oci8/tests/pecl_bug10194_blob_64.phpt +++ b/ext/oci8/tests/pecl_bug10194_blob_64.phpt @@ -5,6 +5,7 @@ PECL Bug #10194 (segfault in Instant Client when memory_limit is reached inside $target_dbs = array('oracledb' => true, 'timesten' => false); // test runs on thes require(dirname(__FILE__).'/skipif.inc'); if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platforms only"); +if ($stress_test !== true) die ('skip Test not run when $stress_test is FALSE'); ?> --INI-- memory_limit=6M From 360d18c4790eacd96d2b7d8f08aaf76e58fbd2f9 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 13 Aug 2011 12:44:28 +0000 Subject: [PATCH 0554/2394] added UTF-8-Mobile for pictogram support. --- ext/mbstring/config.m4 | 1 + ext/mbstring/libmbfl/filters/Makefile.am | 2 + ext/mbstring/libmbfl/filters/mbfilter_sjis.c | 4 +- .../libmbfl/filters/mbfilter_sjis_mobile.c | 491 +++++++----------- .../libmbfl/filters/mbfilter_sjis_mobile.h | 19 +- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 38 +- .../libmbfl/filters/mbfilter_utf8_mobile.c | 367 +++++++++++++ .../libmbfl/filters/mbfilter_utf8_mobile.h | 57 ++ ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 9 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 5 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 4 + ext/mbstring/libmbfl/mbfl/mbfl_ident.c | 8 + 12 files changed, 690 insertions(+), 315 deletions(-) create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h diff --git a/ext/mbstring/config.m4 b/ext/mbstring/config.m4 index f8763c6da3539..6751605e1cbe4 100644 --- a/ext/mbstring/config.m4 +++ b/ext/mbstring/config.m4 @@ -275,6 +275,7 @@ AC_DEFUN([PHP_MBSTRING_SETUP_LIBMBFL], [ libmbfl/filters/mbfilter_utf7.c libmbfl/filters/mbfilter_utf7imap.c libmbfl/filters/mbfilter_utf8.c + libmbfl/filters/mbfilter_utf8_mobile.c libmbfl/filters/mbfilter_uuencode.c libmbfl/filters/mbfilter_koi8u.c libmbfl/mbfl/mbfilter.c diff --git a/ext/mbstring/libmbfl/filters/Makefile.am b/ext/mbstring/libmbfl/filters/Makefile.am index d4d781c3dfc27..6edf690c84420 100644 --- a/ext/mbstring/libmbfl/filters/Makefile.am +++ b/ext/mbstring/libmbfl/filters/Makefile.am @@ -43,6 +43,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_utf32.c \ mbfilter_utf16.c \ mbfilter_utf8.c \ + mbfilter_utf8_mobile.c \ mbfilter_utf7.c \ mbfilter_utf7imap.c \ mbfilter_euc_jp_win.c \ @@ -115,6 +116,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_utf7.h \ mbfilter_utf7imap.h \ mbfilter_utf8.h \ + mbfilter_utf8_mobile.h \ mbfilter_uuencode.h \ mbfilter_cp5022x.h \ mbfilter_cp51932.h \ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis.c index 61671ade9eb0c..a2672d8fa2ee6 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis.c @@ -40,7 +40,7 @@ #include "unicode_table_cp932_ext.h" #include "unicode_table_jis.h" -static int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); +int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -276,7 +276,7 @@ mbfl_filt_conv_wchar_sjis(int c, mbfl_convert_filter *filter) return c; } -static int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter) +int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter) { if (filter->status) { /* kanji second char */ if (c < 0x40 || c > 0xfc || c == 0x7f) { /* bad */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c index 5653086647a5e..44e7ca0e9fe0d 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -40,7 +40,7 @@ #include "emoji2uni.h" -static int mbfl_filt_ident_sjis_mobile(int c, mbfl_identify_filter *filter); +extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -124,6 +124,27 @@ const mbfl_encoding mbfl_encoding_sjis_sb_pua = { MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE }; +const struct mbfl_identify_vtbl vtbl_identify_sjis_docomo = { + mbfl_no_encoding_sjis_docomo, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_sjis +}; + +const struct mbfl_identify_vtbl vtbl_identify_sjis_kddi = { + mbfl_no_encoding_sjis_kddi, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_sjis +}; + +const struct mbfl_identify_vtbl vtbl_identify_sjis_sb = { + mbfl_no_encoding_sjis_sb, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_sjis +}; + const struct mbfl_convert_vtbl vtbl_sjis_docomo_wchar = { mbfl_no_encoding_sjis_docomo, mbfl_no_encoding_wchar, @@ -250,7 +271,48 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua = { mbfl_filt_conv_common_flush }; +static const char nflags_s[10][2] = {"CN","DE","ES","FR","GB","IT","JP","KR","RU","US"}; +static const int nflags_code_kddi[10] = {0x2549, 0x2546, 0x24c0, 0x2545, 0x2548, 0x2547, 0x2750, 0x254a, 0x24c1, 0x27f7}; +static const int nflags_code_sb[10] = {0x2b0a, 0x2b05, 0x2b08, 0x2b04, 0x2b07, 0x2b06, 0x2b02, 0x2b0b, 0x2b09, 0x2b03}; + +const int mbfl_docomo2uni_pua[4][3] = { + {0x28c2, 0x2929, 0xe63e}, + {0x2930, 0x2932, 0xe6ac}, + {0x2935, 0x293e, 0xe6b1}, + {0x2952, 0x29db, 0xe6ce}, +}; + +const int mbfl_kddi2uni_pua[6][3] = { + {0x26ec, 0x2838, 0xe468}, + {0x284c, 0x2863, 0xe5b5}, + {0x24b8, 0x24ca, 0xe5cd}, + {0x24cb, 0x2545, 0xea80}, + {0x2839, 0x284b, 0xeafb}, + {0x2546, 0x25c0, 0xeb0e}, +}; + +const int mbfl_sb2uni_pua[6][3] = { + {0x27a9, 0x2802, 0xe101}, + {0x2808, 0x285a, 0xe201}, + {0x2921, 0x297a, 0xe001}, + {0x2980, 0x29cc, 0xe301}, + {0x2a99, 0x2ae4, 0xe401}, + {0x2af8, 0x2b2e, 0xe501}, +}; + +const int mbfl_kddi2uni_pua_b[8][3] = { + {0x24b8, 0x24f6, 0xec40}, + {0x24f7, 0x2573, 0xec80}, + {0x2574, 0x25b2, 0xed40}, + {0x25b3, 0x25c0, 0xed80}, + {0x26ec, 0x272a, 0xef40}, + {0x272b, 0x27a7, 0xef80}, + {0x27a8, 0x27e6, 0xf040}, + {0x27e7, 0x2863, 0xf080}, +}; + +#define NFLAGS(c) (0x1F1A5+(int)(c)) #define CK(statement) do { if ((statement) < 0) return (-1); } while (0) @@ -297,8 +359,59 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua = { } \ } while (0) +#define CODE2JIS(c1,c2,s1,s2) \ + c1 = (s1)/94+0x21; \ + c2 = (s1)-94*((c1)-0x21)+0x21; \ + s1 = ((c1) << 8) | (c2); \ + s2 = 1 + +int +mbfilter_conv_map_tbl(int c, int *w, const int map[][3], int n) +{ + int i, match = 0; + + for (i = 0; i < n; i++) { + if (map[i][0] <= c && c <= map[i][1]) { + *w = c - map[i][0] + map[i][2]; + match = 1; + break; + } + } + return match; +} + +int +mbfilter_conv_r_map_tbl(int c, int *w, const int map[][3], int n) +{ + int i, match = 0; + + for (i = 0; i < n; i++) { + if (map[i][2] <= c && c <= map[i][2] - map[i][0] + map[i][1]) { + *w = c + map[i][0] - map[i][2]; + match = 1; + break; + } + } + return match; +} + +int +mbfilter_conv_seq_tbl(int c, int *w, const int *key, const int *val, int n) +{ + int i, match = 0; + for (i = 0; i< n; i++) { + if (c == key[i]) { + *w = val[i]; + match = 1; + break; + } + } + return match; +} + + int -mbfiler_sjis_emoji_docomo2unicode(int s, int *snd) +mbfilter_sjis_emoji_docomo2unicode(int s, int *snd) { int w = s; if (s >= mb_tbl_code2uni_docomo1_min && s <= mb_tbl_code2uni_docomo1_max) { @@ -319,36 +432,34 @@ mbfiler_sjis_emoji_docomo2unicode(int s, int *snd) } int -mbfiler_sjis_emoji_kddi2unicode(int s, int *snd) +mbfilter_sjis_emoji_kddi2unicode(int s, int *snd) { - int w = s, si; - const char flags[][2] = {"FR","DE","IT","GB","CN","KR","ES","RU","JP","US"}; - + int w = s, si, c; + const int nflags_order_kddi[] = {3, 1, 5, 4, 0, 7}; + *snd = 0; - if (s >= mb_tbl_code2uni_kddi1_min && - s <= mb_tbl_code2uni_kddi1_max) { + if (s >= mb_tbl_code2uni_kddi1_min && s <= mb_tbl_code2uni_kddi1_max) { si = s - mb_tbl_code2uni_kddi1_min; - if (si == 0x0008) { - *snd = 0x1F1A5 + flags[6][0]; w = 0x1F1A5 + flags[6][1]; - } else if (si == 0x0009) { - *snd = 0x1F1A5 + flags[7][0]; w = 0x1F1A5 + flags[7][1]; + if (si == 0x0008) { /* ES */ + *snd = NFLAGS(nflags_s[2][0]); w = NFLAGS(nflags_s[2][1]); + } else if (si == 0x0009) { /* RU */ + *snd = NFLAGS(nflags_s[8][0]); w = NFLAGS(nflags_s[8][1]); } else if (si >= 0x008d && si <= 0x0092) { - *snd = 0x1F1A5 + flags[si - 0x8d][0]; - w = 0x1F1A5 + flags[si - 0x8d][1]; + c = nflags_order_kddi[si-0x008d]; + *snd = NFLAGS(nflags_s[c][0]); w = NFLAGS(nflags_s[c][1]); } else if (si == 0x0104) { *snd = 0x0023; w = 0x20E3; } else { w = mb_tbl_code2uni_kddi1[si]; } - } else if (s >= mb_tbl_code2uni_kddi2_min && - s <= mb_tbl_code2uni_kddi2_max) { + } else if (s >= mb_tbl_code2uni_kddi2_min && s <= mb_tbl_code2uni_kddi2_max) { si = s - mb_tbl_code2uni_kddi2_min; - if (si == 100) { - *snd = 0x1F1A5 + flags[8][0]; w = 0x1F1A5 + flags[8][1]; + if (si == 100) { /* JP */ + *snd = NFLAGS(nflags_s[6][0]); w = NFLAGS(nflags_s[6][1]); } else if (si >= 0x00ba && si <= 0x00c2) { *snd = si-0x00ba+0x0031; w = 0x20E3; - } else if (si == 0x010b) { - *snd = 0x1F1A5 + flags[9][0]; w = 0x1F1A5 + flags[9][1]; + } else if (si == 0x010b) { /* US */ + *snd = NFLAGS(nflags_s[9][0]); w = NFLAGS(nflags_s[9][1]); } else if (si == 0x0144) { *snd = 0x0030; w = 0x20E3; } else { @@ -359,14 +470,13 @@ mbfiler_sjis_emoji_kddi2unicode(int s, int *snd) } int -mbfiler_sjis_emoji_sb2unicode(int s, int *snd) +mbfilter_sjis_emoji_sb2unicode(int s, int *snd) { - int w = s, si; - const char flags[][2] = {"JP","US","FR","DE","IT","GB","ES","RU","CN","KR"}; - + int w = s, si, c; + const int nflags_order_sb[10] = {6, 9, 3, 1, 5, 4, 2, 8, 0, 7}; + *snd = 0; - if (s >= mb_tbl_code2uni_sb1_min && - s <= mb_tbl_code2uni_sb1_max) { + if (s >= mb_tbl_code2uni_sb1_min && s <= mb_tbl_code2uni_sb1_max) { si = s - mb_tbl_code2uni_sb1_min; if (si == 0x006e || (si >= 0x007a && si <= 0x0083)) { *snd = mb_tbl_code2uni_sb1[si]; @@ -374,16 +484,14 @@ mbfiler_sjis_emoji_sb2unicode(int s, int *snd) } else { w = mb_tbl_code2uni_sb1[si]; } - } else if (s >= mb_tbl_code2uni_sb2_min && - s <= mb_tbl_code2uni_sb2_max) { + } else if (s >= mb_tbl_code2uni_sb2_min && s <= mb_tbl_code2uni_sb2_max) { si = s - mb_tbl_code2uni_sb2_min; w = mb_tbl_code2uni_sb2[si]; - } else if (s >= mb_tbl_code2uni_sb3_min && - s <= mb_tbl_code2uni_sb3_max) { + } else if (s >= mb_tbl_code2uni_sb3_min && s <= mb_tbl_code2uni_sb3_max) { si = s - mb_tbl_code2uni_sb3_min; if (si >= 0x0069 && si <= 0x0072) { - *snd = 0x1F1A5 + flags[si - 0x0069][0]; - w = 0x1F1A5 + flags[si - 0x0069][1]; + c = nflags_order_sb[si-0x0069]; + *snd = NFLAGS(nflags_s[c][0]); w = NFLAGS(nflags_s[c][1]); } else { w = mb_tbl_code2uni_sb3[si]; } @@ -392,128 +500,7 @@ mbfiler_sjis_emoji_sb2unicode(int s, int *snd) } int -mbfiler_sjis_emoji_kddi2unicode_pua(int s, int *w) -{ - - if (s >= 0x26ec && s <= 0x2838) { - *w = s - 0x26ec + 0xe468; - } else if (s >= 0x284c && s <= 0x2863) { - *w = s - 0x284c + 0xe5b5; - } else if (s >= 0x24b8 && s <= 0x24ca) { - *w = s - 0x24b8 + 0xe5cd; - } else if (s >= 0x24cb && s <= 0x2545) { - *w = s - 0x24cb + 0xea80; - } else if (s >= 0x2839 && s <= 0x284b) { - *w = s - 0x2839 + 0xeafb; - } else if (s >= 0x2546 && s <= 0x25c0) { - *w = s - 0x2546 + 0xeb0e; - } - - return *w; -} - -int -mbfiler_sjis_emoji_kddi2unicode_pua_b(int s, int c1, int c, int *w) -{ - if ((c1 == 0xf3 && (c >= 0x40 && c<=0xfc && c != 0x7f)) || - (c1 == 0xf4 && (c >= 0x40 && c<=0x93 && c != 0x7f)) || - ((c1 == 0xf6 || c1 == 0xf7) && (c >= 0x40 && c<=0xfc && c != 0x7f))) { - *w = (c1 << 8) + c - 0x0700; /* KDDI unofficial UTF-8 encoding */ - } - return *w; -} - -int -mbfiler_sjis_emoji2unicode_pua(int s, int *w) -{ - if (s >= 0x27a9 && s <= 0x2802) { - *w = s - 0x27a9 + 0xe101; - } else if (s >= 0x2808 && s <= 0x285a) { - *w = s - 0x2808 + 0xe201; - } else if (s >= 0x2921 && s <= 0x297a) { - *w = s - 0x2921 + 0xe001; - } else if (s >= 0x2980 && s <= 0x29cc) { - *w = s - 0x2980 + 0xe301; - } else if (s >= 0x2a99 && s <= 0x2ae4) { - *w = s - 0x2a99 + 0xe401; - } else if (s >= 0x2af8 && s <= 0x2b2e) { - *w = s - 0x2af8 + 0xe501; - } - return *w; -} - -int -mbfiler_unicode_pua2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2) -{ - int match = 1; - - if (c >= 0xe468 && c <= 0xe5b4) { - *s1 = c - 0xe468 + 0x26ec; - } else if (c >= 0xe5b5 && c <= 0xe5cc) { - *s1 = c - 0xe5b5 + 0x284c; - } else if (c >= 0xe5cd && c <= 0xe5df) { - *s1 = c - 0xe5cd + 0x24b8; - } else if (c >= 0xea80 && c <= 0xeafa) { - *s1 = c - 0xea80 + 0x24cb; - } else if (c >= 0xeafb && c <= 0xeb0d) { - *s1 = c - 0xeafb + 0x2839; - } else if (c >= 0xeb0e && c <= 0xeb88) { - *s1 = c - 0xeb0e + 0x2546; - } else { - match = 0; - } - if (match && *s1 >0) { - *c1 = *s1/94+0x21; - *c2 = *s1-94*(*c1-0x21)+0x21; - *s1 = (*c1 << 8) | *c2; - *s2 = 1; - } - - return 1; -} - - - -int -mbfiler_unicode_pua2sjis_emoji(int c, int *s1, int *s2, int *c1, int *c2, int *sjis_encoded) -{ - int match = 1; - - if (c >= 0xe001 && c <= 0xe05a) { - *s1 = c - 0xe001 + 0x2921; - } else if (c >= 0xe101 && c <= 0xe15a) { - *s1 = c - 0xe101 + 0x27a9; - } else if (c >= 0xe201 && c <= 0xe253) { - *s1 = c - 0xe201 + 0x2808; - } else if (c >= 0xe301 && c <= 0xe34d) { - *s1 = c - 0xe301 + 0x2980; - } else if (c >= 0xe401 && c <= 0xe44c) { - *s1 = c - 0xe401 + 0x2a99; - } else if (c >= 0xe501 && c <= 0xe537) { - *s1 = c - 0xe501 + 0x2af8; - } else if ( - ((c >= 0xec40 && c<=0xecfc) && c != 0xec7f) || - ((c >= 0xed40 && c<=0xed93) && c != 0xed7f) || - ((c >= 0xef40 && c<=0xeffc) && c != 0xef7f) || - ((c >= 0xf040 && c<=0xf0fc) && c != 0xf07f)) { - /* KDDI unofficial UTF-8 encoding */ - *s1 = c + 0x0700; - *sjis_encoded = 1; - } else { - match = 0; - } - if (match && *sjis_encoded == 0 && *s1 >0) { - *c1 = *s1/94+0x21; - *c2 = *s1-94*(*c1-0x21)+0x21; - *s1 = (*c1 << 8) | *c2; - *s2 = 1; - } - - return 1; -} - -int -mbfiler_unicode2sjis_emoji_docomo(int c, int *s1, int *s2, int *c1, int *c2, mbfl_convert_filter *filter) +mbfilter_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filter) { int i, match = 0, c1s; @@ -533,17 +520,14 @@ mbfiler_unicode2sjis_emoji_docomo(int c, int *s1, int *s2, int *c1, int *c2, mbf match = 1; } } else { - if (c1s >= ucs_a1_jis_table_min && c1s < ucs_a1_jis_table_max) { - c1s = ucs_a1_jis_table[c1s - ucs_a1_jis_table_min]; - CK((*filter->output_function)(c1s, filter->data)); - } + CK((*filter->output_function)(c1s, filter->data)); } } else { if (c == 0x0023 || (c >= 0x0030 && c<=0x0039)) { filter->status = 1; filter->cache = c; *s1 = -1; - return 0; + return match; } if (c == 0x00A9) { @@ -551,40 +535,19 @@ mbfiler_unicode2sjis_emoji_docomo(int c, int *s1, int *s2, int *c1, int *c2, mbf } else if (c == 0x00AE) { *s1 = 0x29ba; match = 1; } else if (c >= mb_tbl_uni_docomo2code2_min && c <= mb_tbl_uni_docomo2code2_max) { - for (i=0; i < sizeof(mb_tbl_uni_docomo2code2_key)/sizeof(int); i++) { - if (c >0 && mb_tbl_uni_docomo2code2_key[i] == c) { - *s1 = mb_tbl_uni_docomo2code2_value[i]; - match = 1; - break; - } - } + match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_docomo2code2_key, mb_tbl_uni_docomo2code2_value, + sizeof(mb_tbl_uni_docomo2code2_key)/sizeof(int)); } else if (c >= mb_tbl_uni_docomo2code3_min && c <= mb_tbl_uni_docomo2code3_max) { - for (i=0; i < sizeof(mb_tbl_uni_docomo2code3_key)/sizeof(int); i++) { - if (c >0 && mb_tbl_uni_docomo2code3_key[i] == c) { - *s1 = mb_tbl_uni_docomo2code3_value[i]; - match = 1; - break; - } - } + match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_docomo2code3_key, mb_tbl_uni_docomo2code3_value, + sizeof(mb_tbl_uni_docomo2code3_key)/sizeof(int)); } } - if (match && *s1 >0) { - *c1 = *s1/94+0x21; - *c2 = *s1-94*(*c1-0x21)+0x21; - *s1 = (*c1 << 8) | *c2; - *s2 = 1; - } - - return 1; + return match; } -const char nflags_s[][2] = {"CN","DE","ES","FR","GB","IT","JP","KR","RU","US"}; -const int nflags_code_kddi[] = {0x2549, 0x2546, 0x24c0, 0x2545, 0x2548, 0x2547, 0x2750, 0x254a, 0x24c1, 0x27f7}; -const int nflags_code_sb[] = {0x2b0a, 0x2b05, 0x2b08, 0x2b04, 0x2b07, 0x2b06, 0x2b02, 0x2b0b, 0x2b09, 0x2b03}; - int -mbfiler_unicode2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2, mbfl_convert_filter *filter) +mbfilter_unicode2sjis_emoji_kddi(int c, int *s1, mbfl_convert_filter *filter) { int i, match = 0, c1s; @@ -603,10 +566,9 @@ mbfiler_unicode2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2, mbfl_ *s1 = 0x27a6 + (c1s - 0x0031); match = 1; } - } else if ((c >= 0x1F1A5 + 0x41 && c <= 0x1F1A5 + 0x5A) && - (c1s >= 0x1F1A5 + 0x41 && c1s <= 0x1F1A5 + 0x5A)) { - for (i=0;i<10;i++) { - if (c1s == 0x1F1A5 + nflags_s[i][0] && c == 0x1F1A5 + nflags_s[i][1]) { + } else if ((c >= NFLAGS(0x41) && c <= NFLAGS(0x5A)) && (c1s >= NFLAGS(0x41) && c1s <= NFLAGS(0x5A))) { + for (i=0; i<10; i++) { + if (c1s == NFLAGS(nflags_s[i][0]) && c == NFLAGS(nflags_s[i][1])) { *s1 = nflags_code_kddi[i]; match = 1; break; @@ -620,11 +582,11 @@ mbfiler_unicode2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2, mbfl_ } } else { if (c == 0x0023 || ( c >= 0x0030 && c<=0x0039) || - (c >= 0x1F1A5 + 0x41 && c<= 0x1F1A5 + 0x5A)) { + (c >= NFLAGS(0x41) && c<= NFLAGS(0x5A))) { filter->status = 1; filter->cache = c; *s1 = -1; - return 0; + return match; } if (c == 0x00A9) { @@ -632,36 +594,19 @@ mbfiler_unicode2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2, mbfl_ } else if (c == 0x00AE) { *s1 = 0x27dd; match = 1; } else if (c >= mb_tbl_uni_kddi2code2_min && c <= mb_tbl_uni_kddi2code2_max) { - for (i=0; i < sizeof(mb_tbl_uni_kddi2code2_key)/sizeof(int); i++) { - if (c >0 && mb_tbl_uni_kddi2code2_key[i] == c) { - *s1 = mb_tbl_uni_kddi2code2_value[i]; - match = 1; - break; - } - } + match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_kddi2code2_key, mb_tbl_uni_kddi2code2_value, + sizeof(mb_tbl_uni_kddi2code2_key)/sizeof(int)); } else if (c >= mb_tbl_uni_kddi2code3_min && c <= mb_tbl_uni_kddi2code3_max) { - for (i=0; i < sizeof(mb_tbl_uni_kddi2code3_key)/sizeof(int); i++) { - if (c >0 && mb_tbl_uni_kddi2code3_key[i] == c) { - *s1 = mb_tbl_uni_kddi2code3_value[i]; - match = 1; - break; - } - } + match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_kddi2code3_key, mb_tbl_uni_kddi2code3_value, + sizeof(mb_tbl_uni_kddi2code3_key)/sizeof(int)); } } - if (match && *s1 >0) { - *c1 = *s1/94+0x21; - *c2 = *s1-94*(*c1-0x21)+0x21; - *s1 = (*c1 << 8) | *c2; - *s2 = 1; - } - - return 1; + return match; } int -mbfiler_unicode2sjis_emoji_sb(int c, int *s1, int *s2, int *c1, int *c2, mbfl_convert_filter *filter) +mbfilter_unicode2sjis_emoji_sb(int c, int *s1, mbfl_convert_filter *filter) { int i, match = 0, c1s; @@ -680,10 +625,9 @@ mbfiler_unicode2sjis_emoji_sb(int c, int *s1, int *s2, int *c1, int *c2, mbfl_co *s1 = 0x2823 + (c1s - 0x0031); match = 1; } - } else if ((c >= 0x1F1A5 + 0x41 && c <= 0x1F1A5 + 0x5A) && - (c1s >= 0x1F1A5 + 0x41 && c1s <= 0x1F1A5 + 0x5A)) { - for (i=0;i<10;i++) { - if (c1s == 0x1F1A5 + nflags_s[i][0] && c == 0x1F1A5 + nflags_s[i][1]) { + } else if ((c >= NFLAGS(0x41) && c <= NFLAGS(0x5A)) && (c1s >= NFLAGS(0x41) && c1s <= NFLAGS(0x5A))) { + for (i=0; i<10; i++) { + if (c1s == NFLAGS(nflags_s[i][0]) && c == NFLAGS(nflags_s[i][1])) { *s1 = nflags_code_sb[i]; match = 1; break; @@ -696,12 +640,11 @@ mbfiler_unicode2sjis_emoji_sb(int c, int *s1, int *s2, int *c1, int *c2, mbfl_co } } } else { - if (c == 0x0023 || ( c >= 0x0030 && c<=0x0039) || - (c >= 0x1F1A5 + 0x41 && c<= 0x1F1A5 + 0x5A)) { + if (c == 0x0023 || ( c >= 0x0030 && c<=0x0039) || (c >= NFLAGS(0x41) && c<= NFLAGS(0x5A))) { filter->status = 1; filter->cache = c; *s1 = -1; - return 0; + return match; } if (c == 0x00A9) { @@ -709,32 +652,15 @@ mbfiler_unicode2sjis_emoji_sb(int c, int *s1, int *s2, int *c1, int *c2, mbfl_co } else if (c == 0x00AE) { *s1 = 0x2856; match = 1; } else if (c >= mb_tbl_uni_sb2code2_min && c <= mb_tbl_uni_sb2code2_max) { - for (i=0; i < sizeof(mb_tbl_uni_sb2code2_key)/sizeof(int); i++) { - if (c >0 && mb_tbl_uni_sb2code2_key[i] == c) { - *s1 = mb_tbl_uni_sb2code2_value[i]; - match = 1; - break; - } - } + match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_sb2code2_key, mb_tbl_uni_sb2code2_value, + sizeof(mb_tbl_uni_sb2code2_key)/sizeof(int)); } else if (c >= mb_tbl_uni_sb2code3_min && c <= mb_tbl_uni_sb2code3_max) { - for (i=0; i < sizeof(mb_tbl_uni_sb2code3_key)/sizeof(int); i++) { - if (c >0 && mb_tbl_uni_sb2code3_key[i] == c) { - *s1 = mb_tbl_uni_sb2code3_value[i]; - match = 1; - break; - } - } + match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_sb2code3_key, mb_tbl_uni_sb2code3_value, + sizeof(mb_tbl_uni_sb2code3_key)/sizeof(int)); } } - if (match && *s1 >0) { - *c1 = *s1/94+0x21; - *c2 = *s1-94*(*c1-0x21)+0x21; - *s1 = (*c1 << 8) | *c2; - *s2 = 1; - } - - return 1; + return match; } /* @@ -807,18 +733,21 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) if (s >= (94*94) && s < 119*94) { if (filter->from->no_encoding == mbfl_no_encoding_sjis_docomo) { - w = mbfiler_sjis_emoji_docomo2unicode(s, &snd); + w = mbfilter_sjis_emoji_docomo2unicode(s, &snd); } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi) { - w = mbfiler_sjis_emoji_kddi2unicode(s, &snd); + w = mbfilter_sjis_emoji_kddi2unicode(s, &snd); } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { - w = mbfiler_sjis_emoji_sb2unicode(s, &snd); + w = mbfilter_sjis_emoji_sb2unicode(s, &snd); } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi_pua) { - mbfiler_sjis_emoji_kddi2unicode_pua(s, &w); + mbfilter_conv_map_tbl(s, &w, mbfl_kddi2uni_pua, 6); } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b) { - mbfiler_sjis_emoji_kddi2unicode_pua_b(s, c1, c, &w); + mbfilter_conv_map_tbl(s, &w, mbfl_kddi2uni_pua_b, 8); } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua) { - mbfiler_sjis_emoji2unicode_pua(s, &w); + mbfilter_conv_map_tbl(s, &w, mbfl_sb2uni_pua, 6); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_docomo_pua) { + mbfilter_conv_map_tbl(s, &w, mbfl_docomo2uni_pua, 4); } + if (w > 0 && snd > 0) { CK((*filter->output_function)(snd, filter->data)); } @@ -908,7 +837,7 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) s1 = 0x96; s2 = c; } s = (s1 - 0x21)*94 + s2 - 0x21; - w = mbfiler_sjis_emoji_sb2unicode(s, &snd); + w = mbfilter_sjis_emoji_sb2unicode(s, &snd); if (w > 0 && snd > 0) { CK((*filter->output_function)(snd, filter->data)); } @@ -947,7 +876,6 @@ int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter) { int c1, c2, s1, s2; - int sjis_encoded = 0; s1 = 0; s2 = 0; @@ -1038,18 +966,21 @@ mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter) } } - if (filter->to->no_encoding == mbfl_no_encoding_sjis_docomo) { - mbfiler_unicode2sjis_emoji_docomo(c, &s1, &s2, &c1, &c2, filter); - } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi) { - mbfiler_unicode2sjis_emoji_kddi(c, &s1, &s2, &c1, &c2, filter); - } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_sb) { - mbfiler_unicode2sjis_emoji_sb(c, &s1, &s2, &c1, &c2, filter); - } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua) { - mbfiler_unicode_pua2sjis_emoji_kddi(c, &s1, &s2, &c1, &c2); - } else if (filter->to->no_encoding == mbfl_no_encoding_sjis_docomo_pua || - filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b || - filter->to->no_encoding == mbfl_no_encoding_sjis_sb_pua) { - mbfiler_unicode_pua2sjis_emoji(c, &s1, &s2, &c1, &c2, &sjis_encoded); + if ((filter->to->no_encoding == mbfl_no_encoding_sjis_docomo && + mbfilter_unicode2sjis_emoji_docomo(c, &s1, filter) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi && + mbfilter_unicode2sjis_emoji_kddi(c, &s1, filter) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_sjis_sb && + mbfilter_unicode2sjis_emoji_sb(c, &s1, filter) > 0 ) || + (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua && + mbfilter_conv_r_map_tbl(c, &s1, mbfl_kddi2uni_pua, 6) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_sjis_docomo_pua && + mbfilter_conv_r_map_tbl(c, &s1, mbfl_docomo2uni_pua, 4) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b && + mbfilter_conv_r_map_tbl(c, &s1, mbfl_kddi2uni_pua_b, 8) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_sjis_sb_pua && + mbfilter_conv_r_map_tbl(c, &s1, mbfl_sb2uni_pua, 6) > 0)) { + CODE2JIS(c1,c2,s1,s2); } if (filter->status == 1 && filter->cache > 0) { @@ -1060,14 +991,9 @@ mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter) if (s1 < 0x100) { /* latin or kana */ CK((*filter->output_function)(s1, filter->data)); } else { /* kanji */ - if (sjis_encoded) { - s2 = s1 & 0xff; - s1 = (s1 >> 8) & 0xff; - } else { - c1 = (s1 >> 8) & 0xff; - c2 = s1 & 0xff; - SJIS_ENCODE(c1, c2, s1, s2); - } + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); CK((*filter->output_function)(s1, filter->data)); CK((*filter->output_function)(s2, filter->data)); } @@ -1097,24 +1023,3 @@ mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter) return 0; } -static int mbfl_filt_ident_sjis_mobile(int c, mbfl_identify_filter *filter) -{ - if (filter->status) { /* kanji second char */ - if (c < 0x40 || c > 0xfc || c == 0x7f) { /* bad */ - filter->flag = 1; - } - filter->status = 0; - } else if (c >= 0 && c < 0x80) { /* latin ok */ - ; - } else if (c > 0xa0 && c < 0xe0) { /* kana ok */ - ; - } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ - filter->status = 1; - } else { /* bad */ - filter->flag = 1; - } - - return c; -} - - diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h index bf504ff3b3684..4bef92de828f8 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -40,7 +40,9 @@ extern const mbfl_encoding mbfl_encoding_sjis_kddi_pua; extern const mbfl_encoding mbfl_encoding_sjis_kddi_pua_b; extern const mbfl_encoding mbfl_encoding_sjis_sb_pua; -extern const struct mbfl_identify_vtbl vtbl_identify_sjis_mobile; +extern const struct mbfl_identify_vtbl vtbl_identify_sjis_docomo; +extern const struct mbfl_identify_vtbl vtbl_identify_sjis_kddi; +extern const struct mbfl_identify_vtbl vtbl_identify_sjis_sb; extern const struct mbfl_convert_vtbl vtbl_sjis_docomo_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo; @@ -62,4 +64,19 @@ int mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter); +int mbfiler_sjis_emoji_docomo2unicode(int s, int *snd); +int mbfilter_sjis_emoji_kddi2unicode(int s, int *snd); +int mbfilter_sjis_emoji_sb2unicode(int s, int *snd); + +int mbfiler_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filter); +int mbfilter_unicode2sjis_emoji_kddi(int c, int *s1, mbfl_convert_filter *filter); +int mbfilter_unicode2sjis_emoji_sb(int c, int *s1, mbfl_convert_filter *filter); + +int mbfilter_unicode_pua2sjis_emoji_docomo( int c, int *s1, int *s2, int *c1, int *c2); +int mbfilter_unicode_pua2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2); +int mbfilter_unicode_pua2sjis_emoji(int c, int *s1, int *s2, int *c1, int *c2, int *sjis_encoded); + +int mbfilter_conv_map_tbl(int c, int *w, const int map[][3], int n); +int mbfilter_conv_r_map_tbl(int c, int *w, const int map[][3], int n); + #endif /* MBFL_MBFILTER_SJIS_MOBILE_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index df8872ad6d913..26c57b4248532 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -34,25 +34,25 @@ #include "mbfilter.h" #include "mbfilter_utf8.h" -static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter); +int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter); -static const unsigned char mblen_table_utf8[] = { - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, 1, 1, 1, 1, 1 +const unsigned char mblen_table_utf8[] = { + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, 1, 1, 1, 1, 1 }; static const char *mbfl_encoding_utf8_aliases[] = {"utf8", NULL}; @@ -230,7 +230,7 @@ int mbfl_filt_conv_wchar_utf8(int c, mbfl_convert_filter *filter) return c; } -static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) +int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter) { int c1; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c new file mode 100644 index 0000000000000..b5c214882a102 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c @@ -0,0 +1,367 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter.c + * by rui hrokawa on 8 aug 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" + +#include "mbfilter_utf8_mobile.h" +#include "mbfilter_sjis_mobile.h" + +extern int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter); +extern const int mbfl_docomo2uni_pua[4][3]; +extern const int mbfl_kddi2uni_pua[6][3]; +extern const int mbfl_sb2uni_pua[6][3]; +extern const int mbfl_kddi2uni_pua_b[8][3]; + +extern const unsigned char mblen_table_utf8[]; + +static const char *mbfl_encoding_utf8_docomo_aliases[] = {"utf8-mobile#docomo", NULL}; +static const char *mbfl_encoding_utf8_kddi_aliases[] = {"utf8-mobile#kddi", NULL}; +static const char *mbfl_encoding_utf8_kddi_b_aliases[] = {"utf8-mobile#kddi-b", NULL}; +static const char *mbfl_encoding_utf8_sb_aliases[] = {"utf8-mobile#softbank", NULL}; + +const mbfl_encoding mbfl_encoding_utf8_docomo = { + mbfl_no_encoding_utf8_docomo, + "UTF-8-Mobile#DOCOMO", + "UTF-8", + (const char *(*)[])&mbfl_encoding_utf8_docomo_aliases, + mblen_table_utf8, + MBFL_ENCTYPE_MBCS +}; + +const mbfl_encoding mbfl_encoding_utf8_kddi = { + mbfl_no_encoding_utf8_kddi, + "UTF-8-Mobile#KDDI", + "UTF-8", + (const char *(*)[])&mbfl_encoding_utf8_kddi_aliases, + mblen_table_utf8, + MBFL_ENCTYPE_MBCS +}; + +const mbfl_encoding mbfl_encoding_utf8_kddi_b = { + mbfl_no_encoding_utf8_kddi_b, + "UTF-8-Mobile#KDDI-B", + "UTF-8", + (const char *(*)[])&mbfl_encoding_utf8_kddi_b_aliases, + mblen_table_utf8, + MBFL_ENCTYPE_MBCS +}; + +const mbfl_encoding mbfl_encoding_utf8_sb = { + mbfl_no_encoding_utf8_sb, + "UTF-8-Mobile#SOFTBANK", + "UTF-8", + (const char *(*)[])&mbfl_encoding_utf8_sb_aliases, + mblen_table_utf8, + MBFL_ENCTYPE_MBCS +}; + +const struct mbfl_identify_vtbl vtbl_identify_utf8_docomo = { + mbfl_no_encoding_utf8_docomo, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_utf8 +}; + +const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi = { + mbfl_no_encoding_utf8_kddi, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_utf8 +}; + +const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi_b = { + mbfl_no_encoding_utf8_kddi_b, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_utf8 +}; + +const struct mbfl_identify_vtbl vtbl_identify_utf8_sb = { + mbfl_no_encoding_utf8_sb, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_utf8 +}; + +const struct mbfl_convert_vtbl vtbl_utf8_docomo_wchar = { + mbfl_no_encoding_utf8_docomo, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_utf8_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_utf8_docomo = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_utf8_docomo, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_utf8_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_utf8_kddi_wchar = { + mbfl_no_encoding_utf8_kddi, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_utf8_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_utf8_kddi, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_utf8_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_utf8_kddi_b_wchar = { + mbfl_no_encoding_utf8_kddi_b, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_utf8_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi_b = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_utf8_kddi_b, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_utf8_mobile, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_utf8_sb_wchar = { + mbfl_no_encoding_utf8_sb, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_utf8_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_utf8_sb = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_utf8_sb, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_utf8_mobile, + mbfl_filt_conv_common_flush +}; + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + +/* + * UTF-8 => wchar + */ +int mbfl_filt_conv_utf8_mobile_wchar(int c, mbfl_convert_filter *filter) +{ + int s, w = 0, flag = 0; + int s1 = 0, s2 = 0, c1 = 0, c2 = 0, snd = 0; + int sjis_encoded = 0; + + if (c < 0x80) { + if (c >= 0) { + CK((*filter->output_function)(c, filter->data)); + } + filter->status = 0; + } else if (c < 0xc0) { + int status = filter->status & 0xff; + switch (status) { + case 0x10: /* 2byte code 2nd char: 0x80-0xbf */ + case 0x21: /* 3byte code 3rd char: 0x80-0xbf */ + case 0x32: /* 4byte code 4th char: 0x80-0xbf */ + filter->status = 0; + s = filter->cache | (c & 0x3f); + filter->cache = 0; + if ((status == 0x10 && s >= 0x80) || + (status == 0x21 && s >= 0x800 && (s < 0xd800 || s > 0xdfff)) || + (status == 0x32 && s >= 0x10000 && s < 0x200000)) { + + if (filter->from->no_encoding == mbfl_no_encoding_utf8_docomo && + mbfilter_conv_r_map_tbl(s, &s1, mbfl_docomo2uni_pua, 4) > 0) { + s = mbfilter_sjis_emoji_docomo2unicode(s1, &snd); + } else if (filter->from->no_encoding == mbfl_no_encoding_utf8_kddi && + mbfilter_conv_r_map_tbl(s, &s1, mbfl_kddi2uni_pua, 6) > 0) { + s = mbfilter_sjis_emoji_kddi2unicode(s1, &snd); + } else if (filter->from->no_encoding == mbfl_no_encoding_utf8_kddi_b && + mbfilter_conv_r_map_tbl(s, &s1, mbfl_kddi2uni_pua_b, 8) > 0) { + s = mbfilter_sjis_emoji_kddi2unicode(s1, &snd); + } else if (filter->from->no_encoding == mbfl_no_encoding_utf8_sb && + mbfilter_conv_r_map_tbl(s, &s1, mbfl_sb2uni_pua, 6) > 0) { + s = mbfilter_sjis_emoji_sb2unicode(s1, &snd); + } + + if (snd > 0) { + CK((*filter->output_function)(snd, filter->data)); + } + CK((*filter->output_function)(s, filter->data)); + } else { + w = s & MBFL_WCSGROUP_MASK; + flag = 1; + } + break; + case 0x20: /* 3byte code 2nd char: 0:0xa0-0xbf,D:0x80-9F,1-C,E-F:0x80-0x9f */ + s = filter->cache | ((c & 0x3f) << 6); + c1 = (s >> 12) & 0xf; + if ((c1 == 0x0 && c >= 0xa0) || + (c1 == 0xd && c < 0xa0) || + (c1 > 0x0 && c1 != 0xd)) { + filter->cache = s; + filter->status++; + } else { + w = s & MBFL_WCSGROUP_MASK; + flag = 1; + } + break; + case 0x31: /* 4byte code 3rd char: 0x80-0xbf */ + filter->cache |= ((c & 0x3f) << 6); + filter->status++; + break; + case 0x30: /* 4byte code 2nd char: 0:0x90-0xbf,1-3:0x80-0xbf,4:0x80-0x8f */ + s = filter->cache | ((c & 0x3f) << 12); + c1 = (s >> 18) & 0x7; + if ((c1 == 0x0 && c >= 0x90) || + (c1 > 0x0 && c1 < 0x4) || + (c1 == 0x4 && c < 0x90)) { + filter->cache = s; + filter->status++; + } else { + w = s & MBFL_WCSGROUP_MASK; + flag = 1; + } + break; + default: + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + break; + } + } else if (c < 0xc2) { /* invalid: 0xc0,0xc1 */ + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } else if (c < 0xe0) { /* 2byte code first char: 0xc2-0xdf */ + if (filter->status == 0x0) { + filter->status = 0x10; + filter->cache = (c & 0x1f) << 6; + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } + } else if (c < 0xf0) { /* 3byte code first char: 0xe0-0xef */ + if (filter->status == 0x0) { + filter->status = 0x20; + filter->cache = (c & 0xf) << 12; + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } + } else if (c < 0xf5) { /* 4byte code first char: 0xf0-0xf4 */ + if (filter->status == 0x0) { + filter->status = 0x30; + filter->cache = (c & 0x7) << 18; + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } + } else { + w = c & MBFL_WCSGROUP_MASK; + flag = 1; + } + + if (flag) { + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + filter->status = 0; + filter->cache = 0; + } + + return c; +} + +/* + * wchar => UTF-8 + */ +int mbfl_filt_conv_wchar_utf8_mobile(int c, mbfl_convert_filter *filter) +{ + if (c >= 0 && c < 0x110000) { + int s1, s2, c1, c2; + + if ((filter->to->no_encoding == mbfl_no_encoding_utf8_docomo && + mbfilter_unicode2sjis_emoji_docomo(c, &s1, filter) > 0 && + mbfilter_conv_map_tbl(s1, &c1, mbfl_docomo2uni_pua, 4) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_utf8_kddi && + mbfilter_unicode2sjis_emoji_kddi(c, &s1, filter) > 0 && + mbfilter_conv_map_tbl(s1, &c1, mbfl_kddi2uni_pua, 6) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_utf8_kddi_b && + mbfilter_unicode2sjis_emoji_kddi(c, &s1, filter) > 0 && + mbfilter_conv_map_tbl(s1, &c1, mbfl_kddi2uni_pua_b, 8) > 0) || + (filter->to->no_encoding == mbfl_no_encoding_utf8_sb && + mbfilter_unicode2sjis_emoji_sb(c, &s1, filter) > 0 && + mbfilter_conv_map_tbl(s1, &c1, mbfl_sb2uni_pua, 6) > 0)) { + c = c1; + } + + if (filter->status == 1 && filter->cache > 0) { + return c; + } + + if (c < 0x80) { + CK((*filter->output_function)(c, filter->data)); + } else if (c < 0x800) { + CK((*filter->output_function)(((c >> 6) & 0x1f) | 0xc0, filter->data)); + CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); + } else if (c < 0x10000) { + CK((*filter->output_function)(((c >> 12) & 0x0f) | 0xe0, filter->data)); + CK((*filter->output_function)(((c >> 6) & 0x3f) | 0x80, filter->data)); + CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); + } else { + CK((*filter->output_function)(((c >> 18) & 0x07) | 0xf0, filter->data)); + CK((*filter->output_function)(((c >> 12) & 0x3f) | 0x80, filter->data)); + CK((*filter->output_function)(((c >> 6) & 0x3f) | 0x80, filter->data)); + CK((*filter->output_function)((c & 0x3f) | 0x80, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + + return c; +} + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h new file mode 100644 index 0000000000000..d8c411192be53 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h @@ -0,0 +1,57 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter.c + * by rui hrokawa on 8 aug 2011. + * + */ + +#ifndef MBFL_MBFILTER_UTF8_MOBILE_H +#define MBFL_MBFILTER_UTF8_MOBILE_H + +extern const mbfl_encoding mbfl_encoding_utf8_docomo; +extern const mbfl_encoding mbfl_encoding_utf8_kddi; +extern const mbfl_encoding mbfl_encoding_utf8_kddi_b; +extern const mbfl_encoding mbfl_encoding_utf8_sb; + +extern const struct mbfl_identify_vtbl vtbl_identify_utf8_docomo; +extern const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi; +extern const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi_b; +extern const struct mbfl_identify_vtbl vtbl_identify_utf8_sb; + +extern const struct mbfl_convert_vtbl vtbl_utf8_docomo_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_docomo; +extern const struct mbfl_convert_vtbl vtbl_utf8_kddi_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi; +extern const struct mbfl_convert_vtbl vtbl_utf8_kddi_b_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi_b; +extern const struct mbfl_convert_vtbl vtbl_utf8_sb_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_sb; + + + +int mbfl_filt_conv_utf8_mobile_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_utf8_mobile(int c, mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_UTF8_MOBILE_H */ diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index 776ff986eb0bc..644ab3421fd9d 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -89,6 +89,7 @@ #include "filters/mbfilter_utf7.h" #include "filters/mbfilter_utf7imap.h" #include "filters/mbfilter_utf8.h" +#include "filters/mbfilter_utf8_mobile.h" #include "filters/mbfilter_utf16.h" #include "filters/mbfilter_utf32.h" #include "filters/mbfilter_byte2.h" @@ -143,6 +144,14 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_sjis_sb_pua, &vtbl_sjis_mac_wchar, &vtbl_wchar_sjis_mac, + &vtbl_utf8_docomo_wchar, + &vtbl_wchar_utf8_docomo, + &vtbl_utf8_kddi_wchar, + &vtbl_wchar_utf8_kddi, + &vtbl_utf8_kddi_b_wchar, + &vtbl_wchar_utf8_kddi_b, + &vtbl_utf8_sb_wchar, + &vtbl_wchar_utf8_sb, &vtbl_euccn_wchar, &vtbl_wchar_euccn, &vtbl_cp936_wchar, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index c91ffa062224a..b4bfa2b4d0a6f 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -96,6 +96,7 @@ #include "filters/mbfilter_utf7.h" #include "filters/mbfilter_utf7imap.h" #include "filters/mbfilter_utf8.h" +#include "filters/mbfilter_utf8_mobile.h" #include "filters/mbfilter_utf16.h" #include "filters/mbfilter_utf32.h" #include "filters/mbfilter_byte2.h" @@ -166,6 +167,10 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_sjis_kddi_pua_b, &mbfl_encoding_sjis_sb_pua, &mbfl_encoding_sjis_mac, + &mbfl_encoding_utf8_docomo, + &mbfl_encoding_utf8_kddi, + &mbfl_encoding_utf8_kddi_b, + &mbfl_encoding_utf8_sb, &mbfl_encoding_cp932, &mbfl_encoding_cp51932, &mbfl_encoding_jis, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index 9c152ef7afd58..bd094739e8368 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -62,6 +62,10 @@ enum mbfl_no_encoding { mbfl_no_encoding_utf16be, mbfl_no_encoding_utf16le, mbfl_no_encoding_utf8, + mbfl_no_encoding_utf8_docomo, + mbfl_no_encoding_utf8_kddi, + mbfl_no_encoding_utf8_kddi_b, + mbfl_no_encoding_utf8_sb, mbfl_no_encoding_utf7, mbfl_no_encoding_utf7imap, mbfl_no_encoding_ascii, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c index 21dd89806053e..0cfdcdba90da6 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c @@ -56,6 +56,7 @@ #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" +#include "filters/mbfilter_utf8_mobile.h" #include "filters/mbfilter_ascii.h" #include "filters/mbfilter_koi8r.h" #include "filters/mbfilter_koi8u.h" @@ -117,6 +118,13 @@ static const struct mbfl_identify_vtbl *mbfl_identify_filter_list[] = { &vtbl_identify_2022jp, &vtbl_identify_2022jpms, &vtbl_identify_cp51932, + &vtbl_identify_sjis_docomo, + &vtbl_identify_sjis_kddi, + &vtbl_identify_sjis_sb, + &vtbl_identify_utf8_docomo, + &vtbl_identify_utf8_kddi, + &vtbl_identify_utf8_kddi_b, + &vtbl_identify_utf8_sb, &vtbl_identify_euccn, &vtbl_identify_cp936, &vtbl_identify_hz, From 1ec46d3fe38c42be6974e7313d3e4e8e0711b317 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 13 Aug 2011 12:53:40 +0000 Subject: [PATCH 0555/2394] fixed win32 build. --- ext/mbstring/config.w32 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/config.w32 b/ext/mbstring/config.w32 index 3dc792de77a2b..d069c3146da17 100644 --- a/ext/mbstring/config.w32 +++ b/ext/mbstring/config.w32 @@ -32,7 +32,7 @@ if (PHP_MBSTRING != "no") { mbfilter_iso2022_jp_ms.c \ mbfilter_koi8r.c mbfilter_qprint.c mbfilter_sjis.c mbfilter_ucs2.c \ mbfilter_ucs4.c mbfilter_uhc.c mbfilter_utf16.c mbfilter_utf32.c \ - mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c \ + mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c mbfilter_utf8_mobile.c \ mbfilter_koi8u.c mbfilter_cp1254.c \ mbfilter_uuencode.c mbfilter_armscii8.c mbfilter_cp850.c \ mbfilter_cp5022x.c mbfilter_sjis_open.c mbfilter_sjis_mobile.c mbfilter_sjis_mac.c \ From b371e0d1fd0e0b7e74ecf55bdf6fa2ebd652edab Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 13 Aug 2011 13:17:36 +0000 Subject: [PATCH 0556/2394] fixed compile warning. --- ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h | 4 ++-- ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h index 4bef92de828f8..310ec7954b4da 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -64,11 +64,11 @@ int mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter); -int mbfiler_sjis_emoji_docomo2unicode(int s, int *snd); +int mbfilter_sjis_emoji_docomo2unicode(int s, int *snd); int mbfilter_sjis_emoji_kddi2unicode(int s, int *snd); int mbfilter_sjis_emoji_sb2unicode(int s, int *snd); -int mbfiler_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filter); +int mbfilter_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filter); int mbfilter_unicode2sjis_emoji_kddi(int c, int *s1, mbfl_convert_filter *filter); int mbfilter_unicode2sjis_emoji_sb(int c, int *s1, mbfl_convert_filter *filter); diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c index b5c214882a102..be0e6b080fa35 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c @@ -193,8 +193,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_utf8_sb = { int mbfl_filt_conv_utf8_mobile_wchar(int c, mbfl_convert_filter *filter) { int s, w = 0, flag = 0; - int s1 = 0, s2 = 0, c1 = 0, c2 = 0, snd = 0; - int sjis_encoded = 0; + int s1 = 0, c1 = 0, snd = 0; if (c < 0x80) { if (c >= 0) { @@ -320,7 +319,7 @@ int mbfl_filt_conv_utf8_mobile_wchar(int c, mbfl_convert_filter *filter) int mbfl_filt_conv_wchar_utf8_mobile(int c, mbfl_convert_filter *filter) { if (c >= 0 && c < 0x110000) { - int s1, s2, c1, c2; + int s1, c1; if ((filter->to->no_encoding == mbfl_no_encoding_utf8_docomo && mbfilter_unicode2sjis_emoji_docomo(c, &s1, filter) > 0 && From 484e6b8fb3b7e7a28a96a9995da63c6889b1a524 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 14 Aug 2011 14:09:11 +0000 Subject: [PATCH 0557/2394] added gb18030 encoding to mbstring/libmbfl.~ --- ext/mbstring/config.m4 | 1 + ext/mbstring/config.w32 | 2 +- ext/mbstring/libmbfl/filters/Makefile.am | 2 + .../libmbfl/filters/mbfilter_gb18030.c | 444 ++++++++++++++++++ .../libmbfl/filters/mbfilter_gb18030.h | 43 ++ .../libmbfl/filters/mbfilter_sjis_mac.c | 3 - .../libmbfl/filters/unicode_table_cp936.h | 36 +- .../libmbfl/filters/unicode_table_gb18030.h | 233 +++++++++ ext/mbstring/libmbfl/mbfl/mbfl_consts.h | 1 + ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 3 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 2 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 1 + ext/mbstring/libmbfl/mbfl/mbfl_ident.c | 2 + 13 files changed, 757 insertions(+), 16 deletions(-) create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_gb18030.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_gb18030.h create mode 100644 ext/mbstring/libmbfl/filters/unicode_table_gb18030.h diff --git a/ext/mbstring/config.m4 b/ext/mbstring/config.m4 index 6751605e1cbe4..7af344f14123d 100644 --- a/ext/mbstring/config.m4 +++ b/ext/mbstring/config.m4 @@ -235,6 +235,7 @@ AC_DEFUN([PHP_MBSTRING_SETUP_LIBMBFL], [ libmbfl/filters/mbfilter_cp866.c libmbfl/filters/mbfilter_cp932.c libmbfl/filters/mbfilter_cp936.c + libmbfl/filters/mbfilter_gb18030.c libmbfl/filters/mbfilter_euc_cn.c libmbfl/filters/mbfilter_euc_jp.c libmbfl/filters/mbfilter_euc_jp_win.c diff --git a/ext/mbstring/config.w32 b/ext/mbstring/config.w32 index d069c3146da17..8c8bea7e25381 100644 --- a/ext/mbstring/config.w32 +++ b/ext/mbstring/config.w32 @@ -29,7 +29,7 @@ if (PHP_MBSTRING != "no") { mbfilter_iso8859_2.c mbfilter_iso8859_3.c mbfilter_iso8859_4.c \ mbfilter_iso8859_5.c mbfilter_iso8859_6.c mbfilter_iso8859_7.c \ mbfilter_iso8859_8.c mbfilter_iso8859_9.c mbfilter_jis.c \ - mbfilter_iso2022_jp_ms.c \ + mbfilter_iso2022_jp_ms.c mbfilter_gb18030.c \ mbfilter_koi8r.c mbfilter_qprint.c mbfilter_sjis.c mbfilter_ucs2.c \ mbfilter_ucs4.c mbfilter_uhc.c mbfilter_utf16.c mbfilter_utf32.c \ mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c mbfilter_utf8_mobile.c \ diff --git a/ext/mbstring/libmbfl/filters/Makefile.am b/ext/mbstring/libmbfl/filters/Makefile.am index 6edf690c84420..c1e414f011e53 100644 --- a/ext/mbstring/libmbfl/filters/Makefile.am +++ b/ext/mbstring/libmbfl/filters/Makefile.am @@ -53,6 +53,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_euc_kr.c \ mbfilter_uhc.c \ mbfilter_iso2022_jp_ms.c \ + mbfilter_gb18030.c \ mbfilter_iso2022_kr.c \ mbfilter_cp866.c \ mbfilter_koi8r.c \ @@ -76,6 +77,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_cp866.h \ mbfilter_cp932.h \ mbfilter_cp936.h \ + mbfilter_gb18030.h \ mbfilter_euc_cn.h \ mbfilter_euc_jp.h \ mbfilter_euc_jp_win.h \ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c b/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c new file mode 100644 index 0000000000000..31ed9f33db193 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c @@ -0,0 +1,444 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * the source code included in this files was separated from mbfilter_cp936.c + * by rui hirokawa on 11 Aug 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_gb18030.h" + +#include "unicode_table_cp936.h" +#include "unicode_table_gb18030.h" + +static int mbfl_filt_ident_gb18030(int c, mbfl_identify_filter *filter); + +static const char *mbfl_encoding_gb18030_aliases[] = {"gb-18030", "gb-18030-2000", NULL}; + +const mbfl_encoding mbfl_encoding_gb18030 = { + mbfl_no_encoding_gb18030, + "GB18030", + "GB18030", + (const char *(*)[])&mbfl_encoding_gb18030_aliases, + NULL, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const struct mbfl_identify_vtbl vtbl_identify_gb18030 = { + mbfl_no_encoding_gb18030, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_gb18030 +}; + +const struct mbfl_convert_vtbl vtbl_gb18030_wchar = { + mbfl_no_encoding_gb18030, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_gb18030_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_gb18030 = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_gb18030, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_gb18030, + mbfl_filt_conv_common_flush +}; + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + + +int +mbfl_bisec_srch(int w, const unsigned short *tbl, int n) +{ + int k, k1 = 0, k2 = n-1; + int match = 0; + + while (k1 < k2) { + k = (k1+k2) >> 1; + if (w <= tbl[2*k+1]) { + k2 = k; + } else if (w >= tbl[2*k+2]) { + k1 = k + 1; + } else { + return -1; + } + } + return k1; +} + +int +mbfl_bisec_srch2(int w, const unsigned short tbl[], int n) +{ + int k, k1 = 0, k2 = n; + + if (w == tbl[0]) { + return 0; + } + + while (k2 - k1 > 1) { + k = (k1 + k2) >> 1; + if (w < tbl[k]) { + k2 = k; + } else if (w > tbl[k]) { + k1 = k; + } else { + return k; + } + } + return -1; +} + +/* + * GB18030 => wchar + */ +int +mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) +{ + int k; + int c1, c2, c3, w = -1; + + switch (filter->status) { + case 0: + if (c >= 0 && c < 0x80) { /* latin */ + CK((*filter->output_function)(c, filter->data)); + } else if (c == 0x80) { /* euro sign */ + CK((*filter->output_function)(0x20ac, filter->data)); + } else if (c == 0xff) { + CK((*filter->output_function)(0x00ff, filter->data)); + } else if (c > 0x80 && c < 0xff) { /* dbcs/fbcs lead byte */ + filter->status = 1; + filter->cache = c; + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + case 1: /* dbcs/fbcs second byte */ + c1 = filter->cache; + filter->status = 0; + + if (c1 >= 0x81 && c1 <= 0x84 && c >= 0x30 && c <= 0x39) { /* 4 byte range: Unicode BMP */ + filter->status = 2; + filter->cache = (c1 << 8) | c; + return c; + } else if (c1 >= 0x90 && c1 <= 0xe3 && c >= 0x30 && c <= 0x39) { /* 4 byte range: Unicode 16 planes */ + filter->status = 2; + filter->cache = (c1 << 8) | c; + return c; + } else if (((c1 >= 0xaa && c1 <= 0xaf) || (c1 >= 0xf8 && c1 <= 0xfe)) && + (c >= 0xa1 && c <= 0xfe)) { /* UDA part1,2: U+E000-U+E4C5 */ + w = 94*(c1 >= 0xf8 ? c1 - 0xf2 : c1 - 0xaa) + (c - 0xa1) + 0xe000; + CK((*filter->output_function)(w, filter->data)); + } else if (c1 >= 0xa1 && c1 <= 0xa7 && c >= 0x40 && c < 0xa1 && c != 0x7f) { /* UDA part3 : U+E4C6-U+E765*/ + w = 96*(c1 - 0xa1) + c - (c >= 0x80 ? 0x41 : 0x40) + 0xe4c6; + CK((*filter->output_function)(w, filter->data)); + } + + if (w <= 0) { + c2 = (c1 << 8) | c; + for (k = 0; k < mbfl_gb18030_pua_tbl_max; k++) { + if (c2 >= mbfl_gb18030_pua_tbl[k][2] && + c2 <= mbfl_gb18030_pua_tbl[k][2] + mbfl_gb18030_pua_tbl[k][1] - mbfl_gb18030_pua_tbl[k][0]) { + w = c2 - mbfl_gb18030_pua_tbl[k][2] + mbfl_gb18030_pua_tbl[k][0]; + CK((*filter->output_function)(w, filter->data)); + break; + } + } + } + + if (w <= 0) { + if ((c1 >= 0xa1 && c1 <= 0xa9 && c >= 0xa1 && c <= 0xfe) || + (c1 >= 0xb0 && c1 <= 0xf7 && c >= 0xa1 && c <= 0xfe) || + (c1 >= 0x81 && c1 <= 0xa0 && c >= 0x40 && c <= 0xfe && c != 0x7f) || + (c1 >= 0xaa && c1 <= 0xfe && c >= 0x40 && c <= 0xa0 && c != 0x7f) || + (c1 >= 0xa8 && c1 <= 0xa9 && c >= 0x40 && c <= 0xa0 && c != 0x7f)) { + w = (c1 - 0x81)*192 + (c - 0x40); + if (w >= 0 && w < cp936_ucs_table_size) { + w = cp936_ucs_table[w]; + } else { + w = 0; + } + if (w <= 0) { + w = (c1 << 8) | c; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_GB18030; + } + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + w = (c1 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + } + break; + case 2: /* fbcs third byte */ + c1 = (filter->cache >> 8) & 0xff; + c2 = filter->cache & 0xff; + filter->status = 0; + filter->cache = 0; + if (((c1 >= 0x81 && c1 <= 0x84) || (c1 >= 0x90 && c1 <= 0xe3)) && + c2 >= 0x30 && c2 <= 0x39 && c >= 0x81 && c <= 0xfe) { + filter->cache = (c1 << 16) | (c2 << 8) | c; + filter->status = 3; + } else { + w = (c1 << 16) | (c2 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + case 3: /* fbcs fourth byte */ + c1 = (filter->cache >> 16) & 0xff; + c2 = (filter->cache >> 8) & 0xff; + c3 = filter->cache & 0xff; + filter->status = 0; + filter->cache = 0; + if (((c1 >= 0x81 && c1 <= 0x84) || (c1 >= 0x90 && c1 <= 0xe3)) && + c2 >= 0x30 && c2 <= 0x39 && c3 >= 0x81 && c3 <= 0xfe && c >= 0x30 && c <= 0x39) { + if (c1 >= 0x90 && c1 <= 0xe3) { + w = ((c1 - 0x90)*10 + (c2 - 0x30)*126 + (c3 - 0x81))*10 + (c - 0x30) + 0x10000; + } else { /* Unicode BMP */ + w = (((c1 - 0x81)*10 + (c2 - 0x30))*126 + (c3 - 0x81))*10 + (c - 0x30); + if (w >= 0 && w <= 39419) { + k = mbfl_bisec_srch(w, mbfl_gb2uni_tbl, mbfl_gb_uni_max); + if (k<0) { + /* error */ + w = (c1 << 24) | (c2 << 16) | (c3 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + return c; + } + w += mbfl_gb_uni_ofst[k]; + } else { + w = (c1 << 24) | (c2 << 16) | (c3 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + return c; + } + } + CK((*filter->output_function)(w, filter->data)); + } else { + w = (c1 << 24) | (c2 << 16) | (c3 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + default: + filter->status = 0; + break; + } + + return c; +} + +/* + * wchar => GB18030 + */ +int +mbfl_filt_conv_wchar_gb18030(int c, mbfl_convert_filter *filter) +{ + int k, k1, k2; + int c1, s, s1 = 0; + + s = 0; + if (c >= ucs_a1_cp936_table_min && c < ucs_a1_cp936_table_max) { + s = ucs_a1_cp936_table[c - ucs_a1_cp936_table_min]; + } else if (c >= ucs_a2_cp936_table_min && c < ucs_a2_cp936_table_max) { + s = ucs_a2_cp936_table[c - ucs_a2_cp936_table_min]; + } else if (c >= ucs_a3_cp936_table_min && c < ucs_a3_cp936_table_max) { + s = ucs_a3_cp936_table[c - ucs_a3_cp936_table_min]; + } else if (c >= ucs_i_cp936_table_min && c < ucs_i_cp936_table_max) { + s = ucs_i_cp936_table[c - ucs_i_cp936_table_min]; + } else if (c >= ucs_ci_cp936_table_min && c < ucs_ci_cp936_table_max) { + s = ucs_ci_cp936_table[c - ucs_ci_cp936_table_min]; + } else if (c >= ucs_cf_cp936_table_min && c < ucs_cf_cp936_table_max) { + s = ucs_cf_cp936_table[c - ucs_cf_cp936_table_min]; + } else if (c >= ucs_sfv_cp936_table_min && c < ucs_sfv_cp936_table_max) { + s = ucs_sfv_cp936_table[c - ucs_sfv_cp936_table_min]; + } else if (c >= ucs_hff_cp936_table_min && c < ucs_hff_cp936_table_max) { + s = ucs_hff_cp936_table[c - ucs_hff_cp936_table_min]; + } + + if (c == 0x20ac) { /* euro-sign */ + s = 0xa2e3; + } + + if (s <= 0 && c >= mbfl_gb18030_c_tbl_key[0] && + c <= mbfl_gb18030_c_tbl_key[mbfl_gb18030_c_tbl_max-1]) { + k1 = mbfl_bisec_srch2(c, mbfl_gb18030_c_tbl_key, mbfl_gb18030_c_tbl_max); + if (k1 >= 0) { + s = mbfl_gb18030_c_tbl_val[k1]; + } + } + + if (c >= 0xe000 && c <= 0xe864) { /* PUA */ + if (c < 0xe766) { + if (c < 0xe4c6) { + c1 = c - 0xe000; + s = (c1 % 94) + 0xa1; c1 /= 94; + s |= (c1 < 0x06 ? c1 + 0xaa : c1 + 0xf2) << 8; + } else { + c1 = c - 0xe4c6; + s = ((c1 / 96) + 0xa1) << 8; c1 %= 96; + s |= c1 + (c1 >= 0x3f ? 0x41 : 0x40); + } + } else { + /* U+E766..U+E864 */ + k1 = 0; k2 = mbfl_gb18030_pua_tbl_max; + while (k1 < k2) { + k = (k1 + k2) >> 1; + if (c < mbfl_gb18030_pua_tbl[k][0]) { + k2 = k; + } else if (c > mbfl_gb18030_pua_tbl[k][1]) { + k1 = k + 1; + } else { + s = c - mbfl_gb18030_pua_tbl[k][0] + mbfl_gb18030_pua_tbl[k][2]; + break; + } + } + } + } + + if (s <= 0 && c >= 0x0080 && c <= 0xffff) { /* BMP */ + s = mbfl_bisec_srch(c, mbfl_uni2gb_tbl, mbfl_gb_uni_max); + if (s >= 0) { + c1 = c - mbfl_gb_uni_ofst[s]; + s = (c1 % 10) + 0x30; c1 /= 10; + s |= ((c1 % 126) + 0x81) << 8; c1 /= 126; + s |= ((c1 % 10) + 0x30) << 16; c1 /= 10; + s1 = c1 + 0x81; + } + } else if (c >= 0x10000 && c <= 0x10ffff) { /* Code set 3: Unicode U+10000..U+10FFFF */ + c1 = c - 0x10000; + s = (c1 % 10) + 0x30; c1 /= 10; + s |= ((c1 % 126) + 0x81) << 8; c1 /= 126; + s |= ((c1 % 10) + 0x30) << 16; c1 /= 10; + s1 = c1 + 0x90; + } + + if (s <= 0) { + c1 = c & ~MBFL_WCSPLANE_MASK; + if (c1 == MBFL_WCSPLANE_WINCP936) { + s = c & MBFL_WCSPLANE_MASK; + } + if (c == 0) { + s = 0; + } else if (s <= 0) { + s = -1; + } + } + if (s >= 0) { + if (s <= 0x80) { /* latin */ + CK((*filter->output_function)(s, filter->data)); + } else if (s1 > 0) { /* fbcs */ + CK((*filter->output_function)(s1 & 0xff, filter->data)); + CK((*filter->output_function)((s >> 16) & 0xff, filter->data)); + CK((*filter->output_function)((s >> 8) & 0xff, filter->data)); + CK((*filter->output_function)(s & 0xff, filter->data)); + } else { /* dbcs */ + CK((*filter->output_function)((s >> 8) & 0xff, filter->data)); + CK((*filter->output_function)(s & 0xff, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + + return c; +} + +static int mbfl_filt_ident_gb18030(int c, mbfl_identify_filter *filter) +{ + int c1; + + c1 = (filter->status >> 8) & 0xff; + filter->status &= 0xff; + + if (filter->status == 0) { + if (c <= 0x80 || c == 0xff) { + filter->status = 0; + } else { + filter->status = 1; + filter->status |= (c << 8); + } + } else if (filter->status == 1) { /* dbcs/fbcs 2nd byte */ + if (((c1 >= 0x81 && c1 <= 0x84) || (c1 >= 0x90 && c1 <= 0xe3)) && c >= 0x30 && c <= 0x39) { /* fbcs */ + filter->status = 2; + } else if (((c1 >= 0xaa && c1 <= 0xaf) || (c1 >= 0xf8 && c1 <= 0xfe)) && (c >= 0xa1 && c <= 0xfe)) { + filter->status = 0; /* UDA part 1,2 */ + } else if (c1 >= 0xa1 && c1 <= 0xa7 && c >= 0x40 && c < 0xa1 && c != 0x7f) { + filter->status = 0; /* UDA part 3 */ + } else if ((c1 >= 0xa1 && c1 <= 0xa9 && c >= 0xa1 && c <= 0xfe) || + (c1 >= 0xb0 && c1 <= 0xf7 && c >= 0xa1 && c <= 0xfe) || + (c1 >= 0x81 && c1 <= 0xa0 && c >= 0x40 && c <= 0xfe && c != 0x7f) || + (c1 >= 0xaa && c1 <= 0xfe && c >= 0x40 && c <= 0xa0 && c != 0x7f) || + (c1 >= 0xa8 && c1 <= 0xa9 && c >= 0x40 && c <= 0xa0 && c != 0x7f)) { + filter->status = 0; /* DBCS */ + } else { + filter->flag = 1; /* bad */ + filter->status = 0; + } + } else if (filter->status == 2) { /* fbcs 3rd byte */ + if (c > 0x80 && c < 0xff) { + filter->status = 3; + } else { + filter->flag = 1; /* bad */ + filter->status = 0; + } + } else if (filter->status == 3) { /* fbcs 4th byte */ + if (c >= 0x30 && c < 0x40) { + filter->status = 0; + } else { + filter->flag = 1; /* bad */ + filter->status = 0; + } + } else { /* bad */ + filter->flag = 1; + } + + return c; +} + + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_gb18030.h b/ext/mbstring/libmbfl/filters/mbfilter_gb18030.h new file mode 100644 index 0000000000000..e182a39555d71 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_gb18030.h @@ -0,0 +1,43 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * the source code included in this files was separated from mbfilter_cn.h + * by moriyoshi koizumi on 4 dec 2002. + * + */ + +#ifndef MBFL_MBFILTER_GB18030_H +#define MBFL_MBFILTER_GB18030_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_gb18030; +extern const struct mbfl_identify_vtbl vtbl_identify_gb18030; +extern const struct mbfl_convert_vtbl vtbl_gb18030_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_gb18030; + +int mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_gb18030(int c, mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_GB18030_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c index 2afecb83283f5..09236733c0d69 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c @@ -376,9 +376,6 @@ mbfl_filt_conv_sjis_mac_wchar(int c, mbfl_convert_filter *filter) w = 0xf87f; } else if (w & 0x80000) { w = 0x20dd; - } else if (w & 0xF0000) { - // TBD - w = 0; } else { w = 0; } diff --git a/ext/mbstring/libmbfl/filters/unicode_table_cp936.h b/ext/mbstring/libmbfl/filters/unicode_table_cp936.h index 9ae8ae3669e57..f5fece402b409 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_cp936.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_cp936.h @@ -877,7 +877,7 @@ const unsigned short cp936_ucs_table[] = { 0x2477,0x2478,0x2479,0x247a,0x247b,0x247c,0x247d,0x247e, 0x247f,0x2480,0x2481,0x2482,0x2483,0x2484,0x2485,0x2486, 0x2487,0x2460,0x2461,0x2462,0x2463,0x2464,0x2465,0x2466, -0x2467,0x2468,0x2469,0x0000,0x0000,0x3220,0x3221,0x3222, +0x2467,0x2468,0x2469,0x20ac,0x0000,0x3220,0x3221,0x3222, 0x3223,0x3224,0x3225,0x3226,0x3227,0x3228,0x3229,0x0000, 0x0000,0x2160,0x2161,0x2162,0x2163,0x2164,0x2165,0x2166, 0x2167,0x2168,0x2169,0x216a,0x216b,0x0000,0x0000,0x0000, @@ -1022,7 +1022,7 @@ const unsigned short cp936_ucs_table[] = { 0x0000,0x0101,0x00e1,0x01ce,0x00e0,0x0113,0x00e9,0x011b, 0x00e8,0x012b,0x00ed,0x01d0,0x00ec,0x014d,0x00f3,0x01d2, 0x00f2,0x016b,0x00fa,0x01d4,0x00f9,0x01d6,0x01d8,0x01da, -0x01dc,0x00fc,0x00ea,0x0251,0x0000,0x0144,0x0148,0x0000, +0x01dc,0x00fc,0x00ea,0x0251,0x0000,0x0144,0x0148,0x01f9, 0x0261,0x0000,0x0000,0x0000,0x0000,0x3105,0x3106,0x3107, 0x3108,0x3109,0x310a,0x310b,0x310c,0x310d,0x310e,0x310f, 0x3110,0x3111,0x3112,0x3113,0x3114,0x3115,0x3116,0x3117, @@ -1041,8 +1041,8 @@ const unsigned short cp936_ucs_table[] = { 0xfe51,0xfe52,0xfe54,0xfe55,0xfe56,0xfe57,0xfe59,0xfe5a, 0xfe5b,0xfe5c,0xfe5d,0xfe5e,0xfe5f,0xfe60,0xfe61,0x0000, 0xfe62,0xfe63,0xfe64,0xfe65,0xfe66,0xfe68,0xfe69,0xfe6a, -0xfe6b,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3007,0x0000, +0xfe6b,0x303e,0x2ff0,0x2ff1,0x2ff2,0x2ff3,0x2ff4,0x2ff5, +0x2ff6,0x2ff7,0x2ff8,0x2ff9,0x2ffa,0x2ffb,0x3007,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x2500,0x2501,0x2502,0x2503, 0x2504,0x2505,0x2506,0x2507,0x2508,0x2509,0x250a,0x250b, @@ -3158,7 +3158,18 @@ const unsigned short cp936_ucs_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, /* 0xfe00 */ 0xfa0c,0xfa0d,0xfa0e,0xfa0f,0xfa11,0xfa13,0xfa14,0xfa18, -0xfa1f,0xfa20,0xfa21,0xfa23,0xfa24,0xfa27,0xfa28,0xfa29}; +0xfa1f,0xfa20,0xfa21,0xfa23,0xfa24,0xfa27,0xfa28,0xfa29, +0x2e81,0x0000,0x0000,0x0000,0x2e84,0x3473,0x3447,0x2e88, +0x2e8b,0x0000,0x359e,0x361a,0x360e,0x2e8c,0x2e97,0x396e, +0x3918,0x0000,0x39cf,0x39df,0x3a73,0x39d0,0x0000,0x0000, +0x3b4e,0x3c6e,0x3ce0,0x2ea7,0x0000,0x0000,0x2eaa,0x4056, +0x415f,0x2eae,0x4337,0x2eb3,0x2eb6,0x2eb7,0x0000,0x43b1, +0x43ac,0x2ebb,0x43dd,0x44d6,0x4661,0x464c,0x0000,0x0000, +0x4723,0x4729,0x477c,0x478d,0x2eca,0x4947,0x497a,0x497d, +0x4982,0x4983,0x4985,0x4986,0x499f,0x499b,0x49b7,0x49b6, +0x0000,0x0000,0x4ca3,0x4c9f,0x4ca0,0x4ca1,0x4c77,0x4ca2, +0x4d13,0x4d14,0x4d15,0x4d16,0x4d17,0x4d18,0x4d19,0x4dae, +}; const int cp936_ucs_table_size = (sizeof(cp936_ucs_table)/sizeof(unsigned short)); @@ -3229,7 +3240,7 @@ const unsigned short ucs_a1_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0xa8bf,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, /* 0x0200 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -3580,8 +3591,9 @@ const unsigned short ucs_a3_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0xa98a,0xa98b,0xa98c,0xa98d,0xa98e,0xa98f,0xa990,0xa991, +0xa992,0xa993,0xa994,0xa995,0x0000,0x0000,0x0000,0x0000, +/* 0x3000 */ 0xa1a1,0xa1a2,0xa1a3,0xa1a8,0x0000,0xa1a9,0xa965,0xa996, 0xa1b4,0xa1b5,0xa1b6,0xa1b7,0xa1b8,0xa1b9,0xa1ba,0xa1bb, 0xa1be,0xa1bf,0xa893,0xa1fe,0xa1b2,0xa1b3,0xa1bc,0xa1bd, @@ -3589,7 +3601,7 @@ const unsigned short ucs_a3_cp936_table[] = { 0x0000,0xa940,0xa941,0xa942,0xa943,0xa944,0xa945,0xa946, 0xa947,0xa948,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xa989,0x0000, 0x0000,0xa4a1,0xa4a2,0xa4a3,0xa4a4,0xa4a5,0xa4a6,0xa4a7, 0xa4a8,0xa4a9,0xa4aa,0xa4ab,0xa4ac,0xa4ad,0xa4ae,0xa4af, 0xa4b0,0xa4b1,0xa4b2,0xa4b3,0xa4b4,0xa4b5,0xa4b6,0xa4b7, @@ -3723,6 +3735,8 @@ const unsigned short ucs_i_cp936_table[] = { /* 0x4d00 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0xfe98,0xfe99,0xfe9a,0xfe9b,0xfe9c, +0xfe9d,0xfe9e,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, @@ -3740,9 +3754,7 @@ const unsigned short ucs_i_cp936_table[] = { 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xfe9f,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, diff --git a/ext/mbstring/libmbfl/filters/unicode_table_gb18030.h b/ext/mbstring/libmbfl/filters/unicode_table_gb18030.h new file mode 100644 index 0000000000000..7c38045638bb9 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/unicode_table_gb18030.h @@ -0,0 +1,233 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: Rui Hirokawa + * + */ + +#ifndef UNICODE_TABLE_GB18030_H +#define UNICODE_TABLE_GB18030_H + +static const unsigned short mbfl_gb18030_c_tbl_val[58] = +{ + 0xfe50,0xfe54,0xfe57,0xfe58,0xfe5d,0xfe5e,0xfe6b,0xfe6e, + 0xfe71,0xfe73,0xfe74,0xfe75,0xfe79,0xfe84,0xfe56,0xfe55, + 0xfe5a,0xfe5c,0xfe5b,0xfe60,0xfe5f,0xfe62,0xfe65,0xfe63, + 0xfe64,0xfe68,0xfe69,0xfe6a,0xfe6f,0xfe70,0xfe72,0xfe78, + 0xfe77,0xfe7a,0xfe7b,0xfe7d,0xfe7c,0xfe80,0xfe81,0xfe82, + 0xfe83,0xfe85,0xfe86,0xfe87,0xfe88,0xfe89,0xfe8a,0xfe8b, + 0xfe8d,0xfe8c,0xfe8f,0xfe8e,0xfe96,0xfe93,0xfe94,0xfe95, + 0xfe97,0xfe92, +}; + +static const unsigned short mbfl_gb18030_c_tbl_key[58] = +{ + 0x2e81,0x2e84,0x2e88,0x2e8b,0x2e8c,0x2e97,0x2ea7,0x2eaa, + 0x2eae,0x2eb3,0x2eb6,0x2eb7,0x2ebb,0x2eca,0x3447,0x3473, + 0x359e,0x360e,0x361a,0x3918,0x396e,0x39cf,0x39d0,0x39df, + 0x3a73,0x3b4e,0x3c6e,0x3ce0,0x4056,0x415f,0x4337,0x43ac, + 0x43b1,0x43dd,0x44d6,0x464c,0x4661,0x4723,0x4729,0x477c, + 0x478d,0x4947,0x497a,0x497d,0x4982,0x4983,0x4985,0x4986, + 0x499b,0x499f,0x49b6,0x49b7,0x4c77,0x4c9f,0x4ca0,0x4ca1, + 0x4ca2,0x4ca3, +}; + +static const int mbfl_gb18030_c_tbl_max = sizeof(mbfl_gb18030_c_tbl_key)/sizeof(unsigned short); + +static const unsigned short mbfl_gb18030_pua_tbl[][3] = { + {0xe766, 0xe76b, 0xa2ab}, + {0xe76d, 0xe76d, 0xa2e4}, + {0xe76e, 0xe76f, 0xa2ef}, + {0xe770, 0xe771, 0xa2fd}, + {0xe772, 0xe77c, 0xa4f4}, + {0xe77d, 0xe784, 0xa5f7}, + {0xe785, 0xe78c, 0xa6b9}, + {0xe78d, 0xe793, 0xa6d9}, + {0xe794, 0xe795, 0xa6ec}, + {0xe796, 0xe796, 0xa6f3}, + {0xe797, 0xe79f, 0xa6f6}, + {0xe7a0, 0xe7ae, 0xa7c2}, + {0xe7af, 0xe7bb, 0xa7f2}, + {0xe7bc, 0xe7c6, 0xa896}, + {0xe7c7, 0xe7c7, 0xa8bc}, + {0xe7c9, 0xe7cc, 0xa8c1}, + {0xe7cd, 0xe7e1, 0xa8ea}, + {0xe7e2, 0xe7e2, 0xa958}, + {0xe7e3, 0xe7e3, 0xa95b}, + {0xe7e4, 0xe7e6, 0xa95d}, + {0xe7f4, 0xe800, 0xa997}, + {0xe801, 0xe80f, 0xa9f0}, + {0xe810, 0xe814, 0xd7fa}, + {0xe816, 0xe818, 0xfe51}, + {0xe81e, 0xe81e, 0xfe59}, + {0xe826, 0xe826, 0xfe61}, + {0xe82b, 0xe82c, 0xfe66}, + {0xe831, 0xe832, 0xfe6c}, + {0xe83b, 0xe83b, 0xfe76}, + {0xe843, 0xe843, 0xfe7e}, + {0xe854, 0xe855, 0xfe90}, + {0xe864, 0xe864, 0xfea0}, +}; + +static const int mbfl_gb18030_pua_tbl_max = sizeof(mbfl_gb18030_pua_tbl)/(sizeof(unsigned short)*3); + +static const unsigned short mbfl_gb2uni_tbl[] = { +0x0000, 0x0023, 0x0024, 0x0025, 0x0026, 0x002c, 0x002d, 0x0031, +0x0032, 0x0050, 0x0051, 0x0058, 0x0059, 0x005e, 0x005f, 0x005f, +0x0060, 0x0063, 0x0064, 0x0066, 0x0067, 0x0067, 0x0068, 0x0068, +0x0069, 0x006c, 0x006d, 0x007d, 0x007e, 0x0084, 0x0085, 0x0093, +0x0094, 0x00ab, 0x00ac, 0x00ae, 0x00af, 0x00b2, 0x00b3, 0x00cf, +0x00d0, 0x0131, 0x0132, 0x0132, 0x0133, 0x0133, 0x0134, 0x0134, +0x0135, 0x0135, 0x0136, 0x0136, 0x0137, 0x0137, 0x0138, 0x0138, +0x0139, 0x0154, 0x0155, 0x01ab, 0x01ac, 0x01ba, 0x01bb, 0x021f, +0x0220, 0x0220, 0x0221, 0x022d, 0x022e, 0x02e4, 0x02e5, 0x02e5, +0x02e6, 0x02ec, 0x02ed, 0x02ed, 0x02ee, 0x0324, 0x0325, 0x0332, +0x0333, 0x0333, 0x0334, 0x1ef1, 0x1ef2, 0x1ef3, 0x1ef4, 0x1ef4, +0x1ef5, 0x1ef6, 0x1ef7, 0x1efd, 0x1efe, 0x1f06, 0x1f07, 0x1f07, +0x1f08, 0x1f08, 0x1f09, 0x1f0d, 0x1f0e, 0x1f7d, 0x1f7e, 0x1fd3, +0x1fd4, 0x1fd4, 0x1fd5, 0x1fd7, 0x1fd8, 0x1fe3, 0x1fe4, 0x1fed, +0x1fee, 0x202b, 0x202c, 0x202f, 0x2030, 0x2045, 0x2046, 0x2047, +0x2048, 0x20b5, 0x20b6, 0x20bb, 0x20bc, 0x20bc, 0x20bd, 0x20bf, +0x20c0, 0x20c3, 0x20c4, 0x20c5, 0x20c6, 0x20c7, 0x20c8, 0x20c8, +0x20c9, 0x20c9, 0x20ca, 0x20cb, 0x20cc, 0x20d0, 0x20d1, 0x20d5, +0x20d6, 0x20df, 0x20e0, 0x20e2, 0x20e3, 0x20e7, 0x20e8, 0x20f4, +0x20f5, 0x20f6, 0x20f7, 0x20fc, 0x20fd, 0x2121, 0x2122, 0x2124, +0x2125, 0x212f, 0x2130, 0x2148, 0x2149, 0x219a, 0x219b, 0x22e7, +0x22e8, 0x22f1, 0x22f2, 0x2355, 0x2356, 0x2359, 0x235a, 0x2366, +0x2367, 0x2369, 0x236a, 0x2373, 0x2374, 0x2383, 0x2384, 0x238b, +0x238c, 0x2393, 0x2394, 0x2396, 0x2397, 0x2398, 0x2399, 0x23aa, +0x23ab, 0x23c9, 0x23ca, 0x23cb, 0x23cc, 0x2401, 0x2402, 0x2402, +0x2403, 0x2c40, 0x2c41, 0x2c42, 0x2c43, 0x2c45, 0x2c46, 0x2c47, +0x2c48, 0x2c51, 0x2c52, 0x2c60, 0x2c61, 0x2c62, 0x2c63, 0x2c65, +0x2c66, 0x2c69, 0x2c6a, 0x2c6b, 0x2c6c, 0x2c6e, 0x2c6f, 0x2c7c, +0x2c7d, 0x2da1, 0x2da2, 0x2da5, 0x2da6, 0x2da6, 0x2da7, 0x2dab, +0x2dac, 0x2dad, 0x2dae, 0x2dc1, 0x2dc2, 0x2dc3, 0x2dc4, 0x2dca, +0x2dcb, 0x2dcc, 0x2dcd, 0x2dd1, 0x2dd2, 0x2dd7, 0x2dd8, 0x2ecd, +0x2ece, 0x2ed4, 0x2ed5, 0x2f45, 0x2f46, 0x302f, 0x3030, 0x303b, +0x303c, 0x303d, 0x303e, 0x305f, 0x3060, 0x3068, 0x3069, 0x306a, +0x306b, 0x306c, 0x306d, 0x30dd, 0x30de, 0x3108, 0x3109, 0x3232, +0x3233, 0x32a1, 0x32a2, 0x32ac, 0x32ad, 0x35a9, 0x35aa, 0x35fe, +0x35ff, 0x365e, 0x365f, 0x366c, 0x366d, 0x36ff, 0x3700, 0x37d9, +0x37da, 0x38f8, 0x38f9, 0x3969, 0x396a, 0x3cde, 0x3cdf, 0x3de6, +0x3de7, 0x3fbd, 0x3fbe, 0x4031, 0x4032, 0x4035, 0x4036, 0x4060, +0x4061, 0x4158, 0x4159, 0x42cd, 0x42ce, 0x42e1, 0x42e2, 0x43a2, +0x43a3, 0x43a7, 0x43a8, 0x43f9, 0x43fa, 0x4409, 0x440a, 0x45c2, +0x45c3, 0x45f4, 0x45f5, 0x45f6, 0x45f7, 0x45fa, 0x45fb, 0x45fb, +0x45fc, 0x460f, 0x4610, 0x4612, 0x4613, 0x4628, 0x4629, 0x48e7, +0x48e8, 0x490e, 0x490f, 0x497d, 0x497e, 0x4a11, 0x4a12, 0x4a62, +0x4a63, 0x82bc, 0x82bd, 0x82bd, 0x82be, 0x82be, 0x82bf, 0x82cb, +0x82cc, 0x82cc, 0x82cd, 0x82d1, 0x82d2, 0x82d8, 0x82d9, 0x82dc, +0x82dd, 0x82e0, 0x82e1, 0x82e8, 0x82e9, 0x82ef, 0x82f0, 0x82ff, +0x8300, 0x830d, 0x830e, 0x93d4, 0x93d5, 0x9420, 0x9421, 0x943b, +0x943c, 0x948c, 0x948d, 0x9495, 0x9496, 0x94af, 0x94b0, 0x94b0, +0x94b1, 0x94b1, 0x94b2, 0x94b4, 0x94b5, 0x94ba, 0x94bb, 0x94bb, +0x94bc, 0x94bd, 0x94be, 0x98c3, 0x98c4, 0x98c4, 0x98c5, 0x98c8, +0x98c9, 0x98c9, 0x98ca, 0x98ca, 0x98cb, 0x98cb, 0x98cc, 0x9960, +0x9961, 0x99e1, 0x99e2, 0x99fb, +}; + +static const unsigned short mbfl_uni2gb_tbl[] = { +0x0080, 0x00a3, 0x00a5, 0x00a6, 0x00a9, 0x00af, 0x00b2, 0x00b6, +0x00b8, 0x00d6, 0x00d8, 0x00df, 0x00e2, 0x00e7, 0x00eb, 0x00eb, +0x00ee, 0x00f1, 0x00f4, 0x00f6, 0x00f8, 0x00f8, 0x00fb, 0x00fb, +0x00fd, 0x0100, 0x0102, 0x0112, 0x0114, 0x011a, 0x011c, 0x012a, +0x012c, 0x0143, 0x0145, 0x0147, 0x0149, 0x014c, 0x014e, 0x016a, +0x016c, 0x01cd, 0x01cf, 0x01cf, 0x01d1, 0x01d1, 0x01d3, 0x01d3, +0x01d5, 0x01d5, 0x01d7, 0x01d7, 0x01d9, 0x01d9, 0x01db, 0x01db, +0x01dd, 0x01f8, 0x01fa, 0x0250, 0x0252, 0x0260, 0x0262, 0x02c6, +0x02c8, 0x02c8, 0x02cc, 0x02d8, 0x02da, 0x0390, 0x03a2, 0x03a2, +0x03aa, 0x03b0, 0x03c2, 0x03c2, 0x03ca, 0x0400, 0x0402, 0x040f, +0x0450, 0x0450, 0x0452, 0x200f, 0x2011, 0x2012, 0x2017, 0x2017, +0x201a, 0x201b, 0x201e, 0x2024, 0x2027, 0x202f, 0x2031, 0x2031, +0x2034, 0x2034, 0x2036, 0x203a, 0x203c, 0x20ab, 0x20ad, 0x2102, +0x2104, 0x2104, 0x2106, 0x2108, 0x210a, 0x2115, 0x2117, 0x2120, +0x2122, 0x215f, 0x216c, 0x216f, 0x217a, 0x218f, 0x2194, 0x2195, +0x219a, 0x2207, 0x2209, 0x220e, 0x2210, 0x2210, 0x2212, 0x2214, +0x2216, 0x2219, 0x221b, 0x221c, 0x2221, 0x2222, 0x2224, 0x2224, +0x2226, 0x2226, 0x222c, 0x222d, 0x222f, 0x2233, 0x2238, 0x223c, +0x223e, 0x2247, 0x2249, 0x224b, 0x224d, 0x2251, 0x2253, 0x225f, +0x2262, 0x2263, 0x2268, 0x226d, 0x2270, 0x2294, 0x2296, 0x2298, +0x229a, 0x22a4, 0x22a6, 0x22be, 0x22c0, 0x2311, 0x2313, 0x245f, +0x246a, 0x2473, 0x249c, 0x24ff, 0x254c, 0x254f, 0x2574, 0x2580, +0x2590, 0x2592, 0x2596, 0x259f, 0x25a2, 0x25b1, 0x25b4, 0x25bb, +0x25be, 0x25c5, 0x25c8, 0x25ca, 0x25cc, 0x25cd, 0x25d0, 0x25e1, +0x25e6, 0x2604, 0x2607, 0x2608, 0x260a, 0x263f, 0x2641, 0x2641, +0x2643, 0x2e80, 0x2e82, 0x2e83, 0x2e85, 0x2e87, 0x2e89, 0x2e8a, +0x2e8d, 0x2e96, 0x2e98, 0x2ea6, 0x2ea8, 0x2ea9, 0x2eab, 0x2ead, +0x2eaf, 0x2eb2, 0x2eb4, 0x2eb5, 0x2eb8, 0x2eba, 0x2ebc, 0x2ec9, +0x2ecb, 0x2fef, 0x2ffc, 0x2fff, 0x3004, 0x3004, 0x3018, 0x301c, +0x301f, 0x3020, 0x302a, 0x303d, 0x303f, 0x3040, 0x3094, 0x309a, +0x309f, 0x30a0, 0x30f7, 0x30fb, 0x30ff, 0x3104, 0x312a, 0x321f, +0x322a, 0x3230, 0x3232, 0x32a2, 0x32a4, 0x338d, 0x3390, 0x339b, +0x339f, 0x33a0, 0x33a2, 0x33c3, 0x33c5, 0x33cd, 0x33cf, 0x33d0, +0x33d3, 0x33d4, 0x33d6, 0x3446, 0x3448, 0x3472, 0x3474, 0x359d, +0x359f, 0x360d, 0x360f, 0x3619, 0x361b, 0x3917, 0x3919, 0x396d, +0x396f, 0x39ce, 0x39d1, 0x39de, 0x39e0, 0x3a72, 0x3a74, 0x3b4d, +0x3b4f, 0x3c6d, 0x3c6f, 0x3cdf, 0x3ce1, 0x4055, 0x4057, 0x415e, +0x4160, 0x4336, 0x4338, 0x43ab, 0x43ad, 0x43b0, 0x43b2, 0x43dc, +0x43de, 0x44d5, 0x44d7, 0x464b, 0x464d, 0x4660, 0x4662, 0x4722, +0x4724, 0x4728, 0x472a, 0x477b, 0x477d, 0x478c, 0x478e, 0x4946, +0x4948, 0x4979, 0x497b, 0x497c, 0x497e, 0x4981, 0x4984, 0x4984, +0x4987, 0x499a, 0x499c, 0x499e, 0x49a0, 0x49b5, 0x49b8, 0x4c76, +0x4c78, 0x4c9e, 0x4ca4, 0x4d12, 0x4d1a, 0x4dad, 0x4daf, 0x4dff, +0x9fa6, 0xd7ff, 0xe76c, 0xe76c, 0xe7c8, 0xe7c8, 0xe7e7, 0xe7f3, +0xe815, 0xe815, 0xe819, 0xe81d, 0xe81f, 0xe825, 0xe827, 0xe82a, +0xe82d, 0xe830, 0xe833, 0xe83a, 0xe83c, 0xe842, 0xe844, 0xe853, +0xe856, 0xe863, 0xe865, 0xf92b, 0xf92d, 0xf978, 0xf97a, 0xf994, +0xf996, 0xf9e6, 0xf9e8, 0xf9f0, 0xf9f2, 0xfa0b, 0xfa10, 0xfa10, +0xfa12, 0xfa12, 0xfa15, 0xfa17, 0xfa19, 0xfa1e, 0xfa22, 0xfa22, +0xfa25, 0xfa26, 0xfa2a, 0xfe2f, 0xfe32, 0xfe32, 0xfe45, 0xfe48, +0xfe53, 0xfe53, 0xfe58, 0xfe58, 0xfe67, 0xfe67, 0xfe6c, 0xff00, +0xff5f, 0xffdf, 0xffe6, 0xffff, +}; + +static const unsigned short mbfl_gb_uni_ofst[] = { + 128, 129, 131, 133, 134, 135, 137, 140, + 142, 144, 145, 147, 148, 149, 150, 151, + 152, 153, 154, 155, 156, 157, 158, 159, + 160, 161, 162, 163, 164, 165, 166, 167, + 168, 171, 172, 189, 196, 213, 220, 221, + 285, 286, 287, 291, 293, 295, 297, 298, + 300, 301, 302, 303, 304, 305, 306, 307, + 308, 320, 330, 334, 338, 339, 340, 341, + 342, 343, 347, 348, 349, 354, 355, 359, + 360, 361, 362, 363, 365, 369, 371, 372, + 373, 374, 375, 376, 386, 426, 502, 538, + 553, 556, 558, 560, 562, 564, 565, 567, + 571, 573, 574, 575, 576, 577, 578, 579, + 581, 582, 583, 584, 585, 586, 588, 589, + 590, 602, 606, 625, 627, 636, 637, 720, + 724, 810, 813, 850, 860, 861, 862, 864, + 867, 868, 869, 870, 872, 873, 874, 875, + 876, 877, 878, 879, 880, 882, 883, 884, + 885, 886, 887, 888, 889, 890, 891, 892, + 893, 894, 895, 896, 897, 898, 899, 900, + 901, 902, 903, 905, 907, 908, 909, 911, + 912, 917, 924, 925, 21827, 25775, 25866, 25896, + 25929, 25932, 25933, 25934, 25936, 25938, 25939, 25940, + 25942, 25943, 25944, 25945, 25946, 25947, 25948, 25952, + 25953, 25955, 25956, 25959, 25961, 25964, 25966, 25984, + 25994, 25998, 26012, 26016, 26110, 26116, +}; + +static const int mbfl_gb_uni_max = sizeof(mbfl_gb_uni_ofst)/sizeof(unsigned short); + + +#endif /* UNICODE_TABLE_GB18030_H */ diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_consts.h b/ext/mbstring/libmbfl/mbfl/mbfl_consts.h index 05f11cdf22215..07c6296eea809 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_consts.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_consts.h @@ -81,6 +81,7 @@ #define MBFL_WCSPLANE_KOI8U 0x70fc0000 #define MBFL_WCSPLANE_CP1254 0x70fd0000 /* 00h - FFh */ #define MBFL_WCSPLANE_CP850 0x70fe0000 /* 00h - FFh */ +#define MBFL_WCSPLANE_GB18030 0x70ff0000 /* a1a1h-e3329a35h */ #define MBFL_WCSGROUP_MASK 0xffffff #define MBFL_WCSGROUP_UCS4MAX 0x70000000 #define MBFL_WCSGROUP_WCHARMAX 0x78000000 diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index 644ab3421fd9d..e3ac774fd0531 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -59,6 +59,7 @@ #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" +#include "filters/mbfilter_gb18030.h" #include "filters/mbfilter_ascii.h" #include "filters/mbfilter_koi8r.h" #include "filters/mbfilter_koi8u.h" @@ -156,6 +157,8 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_euccn, &vtbl_cp936_wchar, &vtbl_wchar_cp936, + &vtbl_gb18030_wchar, + &vtbl_wchar_gb18030, &vtbl_hz_wchar, &vtbl_wchar_hz, &vtbl_euctw_wchar, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index b4bfa2b4d0a6f..85c4339f283a4 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -65,6 +65,7 @@ #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" +#include "filters/mbfilter_gb18030.h" #include "filters/mbfilter_ascii.h" #include "filters/mbfilter_koi8r.h" #include "filters/mbfilter_koi8u.h" @@ -176,6 +177,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_jis, &mbfl_encoding_2022jp, &mbfl_encoding_2022jpms, + &mbfl_encoding_gb18030, &mbfl_encoding_cp1252, &mbfl_encoding_cp1254, &mbfl_encoding_8859_1, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index bd094739e8368..1ac05757ce7b9 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -86,6 +86,7 @@ enum mbfl_no_encoding { mbfl_no_encoding_jis, mbfl_no_encoding_2022jp, mbfl_no_encoding_2022jpms, + mbfl_no_encoding_gb18030, mbfl_no_encoding_cp1252, mbfl_no_encoding_cp1254, mbfl_no_encoding_8859_1, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c index 0cfdcdba90da6..fdffc70471662 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c @@ -68,6 +68,7 @@ #include "filters/mbfilter_cp1254.h" #include "filters/mbfilter_cp51932.h" #include "filters/mbfilter_cp5022x.h" +#include "filters/mbfilter_gb18030.h" #include "filters/mbfilter_iso8859_1.h" #include "filters/mbfilter_iso8859_2.h" #include "filters/mbfilter_iso8859_3.h" @@ -158,6 +159,7 @@ static const struct mbfl_identify_vtbl *mbfl_identify_filter_list[] = { &vtbl_identify_cp50220, &vtbl_identify_cp50221, &vtbl_identify_cp50222, + &vtbl_identify_gb18030, &vtbl_identify_false, NULL }; From a3ac99b0aadf74b4c83d10e355881159e90743f2 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 14 Aug 2011 14:09:54 +0000 Subject: [PATCH 0558/2394] NEWS update for mbstring. --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index 40e877d3ab783..6898251e23436 100644 --- a/NEWS +++ b/NEWS @@ -172,6 +172,8 @@ PHP NEWS - Improved mbstring extension: . Added Shift_JIS Emoji (pictograms) support. (rui) . Ill-formed UTF-8 check for security enhancements. (rui) + . Added MacJapanese (Shift_JIS) and gb18030 encoding support. (rui) + . Added encode/decode in hex format to mb_[en|de]code_numericentity(). (rui) - Improved MySQL extensions: . MySQL: Deprecated mysql_list_dbs(). FR #50667. (Andrey) From adfdd01372cce9efe22d816dbd4eb2ab66862ab0 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Mon, 15 Aug 2011 08:29:48 +0000 Subject: [PATCH 0559/2394] Addendum for patch to bug #55214: Class name was freed before method literal referring to it. # Thanks to Felipe for catching this. # The fix duplicates the name into the literal to avoid the dependency --- Zend/zend_compile.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 96fd936ace24b..6fdd4a6d3e7e9 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3544,7 +3544,7 @@ static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry * /* Only on merge into an actual class */ && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) { INIT_ZVAL(class_name_zv); - ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 0); + ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 1); class_name_literal = zend_add_literal(&fe->op_array, &class_name_zv TSRMLS_CC); opcode_copy[i].op1.zv = &fe->op_array.literals[class_name_literal].constant; } @@ -3564,7 +3564,7 @@ static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry * /* Only on merge into an actual class */ && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) { INIT_ZVAL(class_name_zv); - ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 0); + ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 1); class_name_literal = zend_add_literal(&fe->op_array, &class_name_zv TSRMLS_CC); opcode_copy[i].op2.zv = &fe->op_array.literals[class_name_literal].constant; } From b14b440c93d9069a7b15a71e2e83a948bca95d9f Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Mon, 15 Aug 2011 09:54:06 +0000 Subject: [PATCH 0560/2394] Fixed Bug #55372 Incorrect handling of literals led to memory corruption. # Dmitry you might want to review this patch, since I split up zend_add_literal # and added a version for post-pass_two() usage. --- Zend/tests/traits/bug55372.phpt | 28 +++++++++++++ Zend/zend_compile.c | 72 ++++++++++++++++++++++----------- 2 files changed, 76 insertions(+), 24 deletions(-) create mode 100644 Zend/tests/traits/bug55372.phpt diff --git a/Zend/tests/traits/bug55372.phpt b/Zend/tests/traits/bug55372.phpt new file mode 100644 index 0000000000000..e215d968aba5b --- /dev/null +++ b/Zend/tests/traits/bug55372.phpt @@ -0,0 +1,28 @@ +--TEST-- +Bug #55372 (Literal handling in methods is inconsistent, causing memory corruption) +--FILE-- +testMethod(); +?> +--EXPECT-- +string(3) "foo" +string(5) "baarr" diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 6fdd4a6d3e7e9..7791d85f420e2 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -339,25 +339,47 @@ void zend_del_literal(zend_op_array *op_array, int n) /* {{{ */ } /* }}} */ +/* Common part of zend_add_literal and zend_append_individual_literal */ +static inline void zend_insert_literal(zend_op_array *op_array, const zval *zv, int literal_position TSRMLS_DC) /* {{{ */ +{ + if (Z_TYPE_P(zv) == IS_STRING || Z_TYPE_P(zv) == IS_CONSTANT) { + zval *z = (zval*)zv; + Z_STRVAL_P(z) = zend_new_interned_string(Z_STRVAL_P(zv), Z_STRLEN_P(zv) + 1, 1 TSRMLS_CC); + } + CONSTANT_EX(op_array, literal_position) = *zv; + Z_SET_REFCOUNT(CONSTANT_EX(op_array, literal_position), 2); + Z_SET_ISREF(CONSTANT_EX(op_array, literal_position)); + op_array->literals[literal_position].hash_value = 0; + op_array->literals[literal_position].cache_slot = -1; +} +/* }}} */ + +/* Is used while compiling a function, using the context to keep track + of an approximate size to avoid to relocate to often. + Literals are truncated to actual size in the second compiler pass (pass_two()). */ int zend_add_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC) /* {{{ */ { int i = op_array->last_literal; op_array->last_literal++; if (i >= CG(context).literals_size) { - CG(context).literals_size += 16; /* FIXME */ + while (i >= CG(context).literals_size) { + CG(context).literals_size += 16; /* FIXME */ + } op_array->literals = (zend_literal*)erealloc(op_array->literals, CG(context).literals_size * sizeof(zend_literal)); } - if (Z_TYPE_P(zv) == IS_STRING || Z_TYPE_P(zv) == IS_CONSTANT) { - zval *z = (zval*)zv; + zend_insert_literal(op_array, zv, i TSRMLS_CC); + return i; +} +/* }}} */ - Z_STRVAL_P(z) = - zend_new_interned_string(Z_STRVAL_P(zv), Z_STRLEN_P(zv) + 1, 1 TSRMLS_CC); - } - CONSTANT_EX(op_array, i) = *zv; - Z_SET_REFCOUNT(CONSTANT_EX(op_array, i), 2); - Z_SET_ISREF(CONSTANT_EX(op_array, i)); - op_array->literals[i].hash_value = 0; - op_array->literals[i].cache_slot = -1; +/* Is used after normal compilation to append an additional literal. + Allocation is done precisely here. */ +int zend_append_individual_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC) /* {{{ */ +{ + int i = op_array->last_literal; + op_array->last_literal++; + op_array->literals = (zend_literal*)erealloc(op_array->literals, (i + 1) * sizeof(zend_literal)); + zend_insert_literal(op_array, zv, i TSRMLS_CC); return i; } /* }}} */ @@ -3488,6 +3510,7 @@ static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry * zval class_name_zv; int class_name_literal; int i; + int number_of_literals; if (fe->op_array.static_variables) { HashTable *tmpHash; @@ -3498,12 +3521,11 @@ static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry * fe->op_array.static_variables = tmpHash; } - - /* TODO: Verify that this size is a global thing, do not see why but is used - like this elsewhere */ - literals_copy = (zend_literal*)emalloc(CG(context).literals_size * sizeof(zend_literal)); - for (i = 0; i < fe->op_array.last_literal; i++) { + number_of_literals = fe->op_array.last_literal; + literals_copy = (zend_literal*)emalloc(number_of_literals * sizeof(zend_literal)); + + for (i = 0; i < number_of_literals; i++) { literals_copy[i] = fe->op_array.literals[i]; zval_copy_ctor(&literals_copy[i].constant); } @@ -3538,14 +3560,15 @@ static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry * } else { /* if __CLASS__ i.e. T_CLASS_C was used, we need to fix it up here */ if (target_ce - /* REM: used a IS_NULL place holder with a special marker LVAL */ + /* REM: used a IS_NULL place holder with a special marker LVAL */ && Z_TYPE_P(opcode_copy[i].op1.zv) == IS_NULL && Z_LVAL_P(opcode_copy[i].op1.zv) == ZEND_ACC_TRAIT - /* Only on merge into an actual class */ - && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) { + /* Only on merge into an actual class */ + && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) + { INIT_ZVAL(class_name_zv); ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 1); - class_name_literal = zend_add_literal(&fe->op_array, &class_name_zv TSRMLS_CC); + class_name_literal = zend_append_individual_literal(&fe->op_array, &class_name_zv TSRMLS_CC); opcode_copy[i].op1.zv = &fe->op_array.literals[class_name_literal].constant; } } @@ -3558,14 +3581,15 @@ static void zend_traits_duplicate_function(zend_function *fe, zend_class_entry * } else { /* if __CLASS__ i.e. T_CLASS_C was used, we need to fix it up here */ if (target_ce - /* REM: used a IS_NULL place holder with a special marker LVAL */ + /* REM: used a IS_NULL place holder with a special marker LVAL */ && Z_TYPE_P(opcode_copy[i].op2.zv) == IS_NULL && Z_LVAL_P(opcode_copy[i].op2.zv) == ZEND_ACC_TRAIT - /* Only on merge into an actual class */ - && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) { + /* Only on merge into an actual class */ + && (ZEND_ACC_TRAIT != (target_ce->ce_flags & ZEND_ACC_TRAIT))) + { INIT_ZVAL(class_name_zv); ZVAL_STRINGL(&class_name_zv, target_ce->name, target_ce->name_length, 1); - class_name_literal = zend_add_literal(&fe->op_array, &class_name_zv TSRMLS_CC); + class_name_literal = zend_append_individual_literal(&fe->op_array, &class_name_zv TSRMLS_CC); opcode_copy[i].op2.zv = &fe->op_array.literals[class_name_literal].constant; } } From f4d3d6c439bc71263f9201f7030d3da7eb6dfe58 Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Mon, 15 Aug 2011 11:16:18 +0000 Subject: [PATCH 0561/2394] Fixed Bug #55355: Inheritance chain was not regarded when checking whether the abstract method of a trait is satisfied. --- Zend/tests/traits/bug55355.phpt | 46 +++++++++++++++++++++++++++++++++ Zend/zend_compile.c | 8 ++++++ 2 files changed, 54 insertions(+) create mode 100644 Zend/tests/traits/bug55355.phpt diff --git a/Zend/tests/traits/bug55355.phpt b/Zend/tests/traits/bug55355.phpt new file mode 100644 index 0000000000000..301ceeeb09e33 --- /dev/null +++ b/Zend/tests/traits/bug55355.phpt @@ -0,0 +1,46 @@ +--TEST-- +Bug #55355 (Abstract functions required by a trait are not correctly found when implemented in an ancestor class) +--FILE-- +foo(); + } + abstract function foo(); +} + +// A class on the second level in the +// inheritance chain +class Level2Impl { + function foo() {} +} + +class Level1Indirect extends Level2Impl {} + +// A class on the first level in the +// inheritance chain +class Level1Direct { + function foo() {} +} + +// Trait Uses + +class Direct { + use ATrait; + function foo() {} +} + +class BaseL2 extends Level1Indirect { + use ATrait; +} + +class BaseL1 extends Level1Direct { + use ATrait; +} + +echo 'DONE'; +?> +--EXPECT-- +DONE diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 7791d85f420e2..777ac20c70456 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3645,6 +3645,14 @@ static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int zend_function* parent_function; if (ce->parent && zend_hash_quick_find(&ce->parent->function_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h, (void**) &parent_function) != FAILURE) { prototype = parent_function; /* ->common.fn_flags |= ZEND_ACC_ABSTRACT; */ + + /* we got that method in the parent class, and are going to override it, + except, if the trait is just asking to have an abstract method implemented. */ + if (fn->common.fn_flags & ZEND_ACC_ABSTRACT) { + /* then we clean up an skip this method */ + zend_function_dtor(fn); + return ZEND_HASH_APPLY_REMOVE; + } } fn->common.scope = ce; From 466d5414dfb43074c9bbfddad31bc96e4def336d Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Mon, 15 Aug 2011 22:16:58 +0000 Subject: [PATCH 0562/2394] Bug #55424 Fatal error when calling a method from a trait that is defined in parent class and required by using an abstract method in the trait. # The method got unconditionally deleted from the class, since it was assumed that we override it, but we did not in case of abstract methods coming from a trait. Thus, dont delete when we try to merge in an abstract method. --- Zend/tests/traits/bug55424.phpt | 35 +++++++++++++++++++++++++++++++++ Zend/zend_compile.c | 11 +++++++---- 2 files changed, 42 insertions(+), 4 deletions(-) create mode 100644 Zend/tests/traits/bug55424.phpt diff --git a/Zend/tests/traits/bug55424.phpt b/Zend/tests/traits/bug55424.phpt new file mode 100644 index 0000000000000..b6c3b545156d0 --- /dev/null +++ b/Zend/tests/traits/bug55424.phpt @@ -0,0 +1,35 @@ +--TEST-- +Bug #55424 (Method got missing from class when a trait defined an abstract method to express a requirement) +--FILE-- +setAttribute(); + } + + abstract function setAttribute(); + } + + class Base + { + function setAttribute() { } + } + + class MyClass extends Base + { + use ATrait; + } + + $i = new Base(); + $i->setAttribute(); + + $t = new MyClass(); + /* setAttribute used to disappear for no good reason. */ + $t->setRequired(); + echo 'DONE'; +?> +--EXPECT-- +DONE diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 777ac20c70456..48e7a2f0f93c9 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -3635,10 +3635,13 @@ static int zend_traits_merge_functions_to_class(zend_function *fn TSRMLS_DC, int } else if (existing_fn->common.scope != ce) { add = 1; /* or inherited from other class or interface */ /* it is just a reference which was added to the subclass while doing the inheritance */ - /* prototype = existing_fn; */ - /* memory is scrambled anyway???? */ - /* function_add_ref(prototype); */ - zend_hash_quick_del(&ce->function_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h); + /* so we can deleted now, and will add the overriding method afterwards */ + + /* except, if we try to add an abstract function, then we should not delete the inherited one */ + /* delete inherited fn if the function to be added is not abstract */ + if ((fn->common.fn_flags & ZEND_ACC_ABSTRACT) == 0) { + zend_hash_quick_del(&ce->function_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h); + } } if (add) { From 306c42023e048451c6bb819661b229e95f314231 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 16 Aug 2011 10:44:47 +0000 Subject: [PATCH 0563/2394] Callable typehint following the rules of is_callable($arg, false); --- Zend/tests/callable_type_hint_001.phpt | 39 + Zend/tests/callable_type_hint_002.phpt | 27 + Zend/tests/callable_type_hint_003.phpt | 21 + Zend/zend.h | 1 + Zend/zend_API.c | 2 + Zend/zend_compile.c | 51 +- Zend/zend_execute.c | 25 +- Zend/zend_language_parser.y | 4 +- Zend/zend_language_scanner.c | 1330 ++++++++++++------------ Zend/zend_language_scanner.l | 4 + ext/reflection/php_reflection.c | 17 + ext/tokenizer/tokenizer_data.c | 4 + 12 files changed, 857 insertions(+), 668 deletions(-) create mode 100644 Zend/tests/callable_type_hint_001.phpt create mode 100644 Zend/tests/callable_type_hint_002.phpt create mode 100644 Zend/tests/callable_type_hint_003.phpt diff --git a/Zend/tests/callable_type_hint_001.phpt b/Zend/tests/callable_type_hint_001.phpt new file mode 100644 index 0000000000000..36643fa64dbfd --- /dev/null +++ b/Zend/tests/callable_type_hint_001.phpt @@ -0,0 +1,39 @@ +--TEST-- +callable type hint#001 +--FILE-- + + string(3) "bar" + [1]=> + string(3) "baz" +} +array(2) { + [0]=> + string(3) "bar" + [1]=> + string(3) "foo" +} +object(Closure)#%d (0) { +} + diff --git a/Zend/tests/callable_type_hint_002.phpt b/Zend/tests/callable_type_hint_002.phpt new file mode 100644 index 0000000000000..b1b7339c317e0 --- /dev/null +++ b/Zend/tests/callable_type_hint_002.phpt @@ -0,0 +1,27 @@ +--TEST-- +callable type hint#002 - Reflection +--FILE-- +getParameters()[0]->isCallable()); + +$rm = new ReflectionMethod("bar", "foo"); +var_dump($rm->getParameters()[0]->isCallable()); + +$rc = new ReflectionFunction($closure); +var_dump($rc->getParameters()[0]->isCallable()); + +?> +--EXPECT-- +bool(true) +bool(true) +bool(true) + diff --git a/Zend/tests/callable_type_hint_003.phpt b/Zend/tests/callable_type_hint_003.phpt new file mode 100644 index 0000000000000..83f5090afac9b --- /dev/null +++ b/Zend/tests/callable_type_hint_003.phpt @@ -0,0 +1,21 @@ +--TEST-- +callable type hint#003 +--FILE-- + +--EXPECT-- +string(6) "strpos" +int(123) +string(6) "strpos" +string(6) "substr" + diff --git a/Zend/zend.h b/Zend/zend.h index 8caa382326e9a..4e1290a5c0c86 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -575,6 +575,7 @@ typedef int (*zend_write_func_t)(const char *str, uint str_length); #define IS_RESOURCE 7 #define IS_CONSTANT 8 #define IS_CONSTANT_ARRAY 9 +#define IS_CALLABLE 10 /* Ugly hack to support constants as static array indices */ #define IS_CONSTANT_TYPE_MASK 0x00f diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 96e5b13a6bc44..5401483db7584 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -217,6 +217,8 @@ ZEND_API char *zend_get_type_by_const(int type) /* {{{ */ return "resource"; case IS_NULL: return "null"; + case IS_CALLABLE: + return "callable"; case IS_ARRAY: return "array"; default: diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 48e7a2f0f93c9..943c5e49918f6 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -1890,27 +1890,38 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con cur_arg_info->allow_null = 0; if (class_type->u.constant.type != IS_NULL) { - cur_arg_info->type_hint = IS_OBJECT; - if (ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_type->u.constant), Z_STRLEN(class_type->u.constant))) { - zend_resolve_class_name(class_type, opline->extended_value, 1 TSRMLS_CC); - } - class_type->u.constant.value.str.val = zend_new_interned_string(class_type->u.constant.value.str.val, class_type->u.constant.value.str.len + 1, 1 TSRMLS_CC); - cur_arg_info->class_name = class_type->u.constant.value.str.val; - cur_arg_info->class_name_len = class_type->u.constant.value.str.len; - if (op == ZEND_RECV_INIT) { - if (Z_TYPE(initialization->u.constant) == IS_NULL || (Z_TYPE(initialization->u.constant) == IS_CONSTANT && !strcasecmp(Z_STRVAL(initialization->u.constant), "NULL"))) { - cur_arg_info->allow_null = 1; - } else { - zend_error(E_COMPILE_ERROR, "Default value for parameters with a class type hint can only be NULL"); + if (class_type->u.constant.type == IS_ARRAY) { + cur_arg_info->type_hint = IS_ARRAY; + if (op == ZEND_RECV_INIT) { + if (Z_TYPE(initialization->u.constant) == IS_NULL || (Z_TYPE(initialization->u.constant) == IS_CONSTANT && !strcasecmp(Z_STRVAL(initialization->u.constant), "NULL"))) { + cur_arg_info->allow_null = 1; + } else if (Z_TYPE(initialization->u.constant) != IS_ARRAY && Z_TYPE(initialization->u.constant) != IS_CONSTANT_ARRAY) { + zend_error(E_COMPILE_ERROR, "Default value for parameters with array type hint can only be an array or NULL"); + } } - } - } else { - cur_arg_info->type_hint = IS_ARRAY; - if (op == ZEND_RECV_INIT) { - if (Z_TYPE(initialization->u.constant) == IS_NULL || (Z_TYPE(initialization->u.constant) == IS_CONSTANT && !strcasecmp(Z_STRVAL(initialization->u.constant), "NULL"))) { - cur_arg_info->allow_null = 1; - } else if (Z_TYPE(initialization->u.constant) != IS_ARRAY && Z_TYPE(initialization->u.constant) != IS_CONSTANT_ARRAY) { - zend_error(E_COMPILE_ERROR, "Default value for parameters with array type hint can only be an array or NULL"); + } else if (class_type->u.constant.type == IS_CALLABLE) { + cur_arg_info->type_hint = IS_CALLABLE; + if (op == ZEND_RECV_INIT) { + if (Z_TYPE(initialization->u.constant) == IS_NULL || (Z_TYPE(initialization->u.constant) == IS_CONSTANT && !strcasecmp(Z_STRVAL(initialization->u.constant), "NULL"))) { + cur_arg_info->allow_null = 1; + } else { + zend_error(E_COMPILE_ERROR, "Default value for parameters with callable type hint can only be NULL"); + } + } + } else { + cur_arg_info->type_hint = IS_OBJECT; + if (ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_type->u.constant), Z_STRLEN(class_type->u.constant))) { + zend_resolve_class_name(class_type, opline->extended_value, 1 TSRMLS_CC); + } + class_type->u.constant.value.str.val = zend_new_interned_string(class_type->u.constant.value.str.val, class_type->u.constant.value.str.len + 1, 1 TSRMLS_CC); + cur_arg_info->class_name = class_type->u.constant.value.str.val; + cur_arg_info->class_name_len = class_type->u.constant.value.str.len; + if (op == ZEND_RECV_INIT) { + if (Z_TYPE(initialization->u.constant) == IS_NULL || (Z_TYPE(initialization->u.constant) == IS_CONSTANT && !strcasecmp(Z_STRVAL(initialization->u.constant), "NULL"))) { + cur_arg_info->allow_null = 1; + } else { + zend_error(E_COMPILE_ERROR, "Default value for parameters with a class type hint can only be NULL"); + } } } } diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 83a3fff6b4dfd..90eb113fe2efc 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -626,13 +626,26 @@ static inline int zend_verify_arg_type(zend_function *zf, zend_uint arg_num, zva need_msg = zend_verify_arg_class_kind(cur_arg_info, fetch_type, &class_name, &ce TSRMLS_CC); return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, need_msg, class_name, zend_zval_type_name(arg), "" TSRMLS_CC); } - } else if (cur_arg_info->type_hint && cur_arg_info->type_hint == IS_ARRAY) { - if (!arg) { - return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, "be of the type array", "", "none", "" TSRMLS_CC); - } + } else if (cur_arg_info->type_hint) { + switch(cur_arg_info->type_hint) { + case IS_ARRAY: + if (!arg) { + return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, "be of the type array", "", "none", "" TSRMLS_CC); + } + + if (Z_TYPE_P(arg) != IS_ARRAY && (Z_TYPE_P(arg) != IS_NULL || !cur_arg_info->allow_null)) { + return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, "be of the type array", "", zend_zval_type_name(arg), "" TSRMLS_CC); + } + break; + + case IS_CALLABLE: + if (!zend_is_callable(arg, IS_CALLABLE_CHECK_SILENT, NULL) && (Z_TYPE_P(arg) != IS_NULL || !cur_arg_info->allow_null)) { + return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, "be callable", "", zend_zval_type_name(arg), "" TSRMLS_CC); + } + break; - if (Z_TYPE_P(arg) != IS_ARRAY && (Z_TYPE_P(arg) != IS_NULL || !cur_arg_info->allow_null)) { - return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, "be of the type array", "", zend_zval_type_name(arg), "" TSRMLS_CC); + default: + zend_error(E_ERROR, "Unknown typehint"); } } return 1; diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index ef390ffd5606d..0a52fe4a258b1 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -186,6 +186,7 @@ static YYSIZE_T zend_yytnamerr(char*, const char*); %token T_DOUBLE_ARROW "=> (T_DOUBLE_ARROW)" %token T_LIST "list (T_LIST)" %token T_ARRAY "array (T_ARRAY)" +%token T_CALLABLE "callable (T_CALLABLE)" %token T_CLASS_C "__CLASS__ (T_CLASS_C)" %token T_TRAIT_C "__TRAIT__ (T_TRAIT_C)" %token T_METHOD_C "__METHOD__ (T_METHOD_C)" @@ -523,7 +524,8 @@ non_empty_parameter_list: optional_class_type: /* empty */ { $$.op_type = IS_UNUSED; } - | T_ARRAY { $$.op_type = IS_CONST; Z_TYPE($$.u.constant)=IS_NULL; } + | T_ARRAY { $$.op_type = IS_CONST; Z_TYPE($$.u.constant)=IS_ARRAY; } + | T_CALLABLE { $$.op_type = IS_CONST; Z_TYPE($$.u.constant)=IS_CALLABLE; } | fully_qualified_class_name { $$ = $1; } ; diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 4447a2f7ff796..c7301b2c7c287 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Aug 7 18:30:41 2011 */ +/* Generated by re2c 0.13.5 on Tue Aug 16 12:22:59 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1083,7 +1083,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1764 "Zend/zend_language_scanner.l" +#line 1768 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1161,7 +1161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1752 "Zend/zend_language_scanner.l" +#line 1756 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1180,7 +1180,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1729 "Zend/zend_language_scanner.l" +#line 1733 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1378,7 +1378,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1689 "Zend/zend_language_scanner.l" +#line 1693 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1422,7 +1422,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1707 "Zend/zend_language_scanner.l" +#line 1711 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1440,7 +1440,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1720 "Zend/zend_language_scanner.l" +#line 1724 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1475,7 +1475,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1742 "Zend/zend_language_scanner.l" +#line 1746 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1555,7 +1555,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2215 "Zend/zend_language_scanner.l" +#line 2219 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1607,7 +1607,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2159 "Zend/zend_language_scanner.l" +#line 2163 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; @@ -1622,7 +1622,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2146 "Zend/zend_language_scanner.l" +#line 2150 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1645,7 +1645,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1846 "Zend/zend_language_scanner.l" +#line 1850 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1657,7 +1657,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(67, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1431 "Zend/zend_language_scanner.l" +#line 1435 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -1676,7 +1676,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1838 "Zend/zend_language_scanner.l" +#line 1842 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1702,7 +1702,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1828 "Zend/zend_language_scanner.l" +#line 1832 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1778,7 +1778,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2165 "Zend/zend_language_scanner.l" +#line 2169 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1838,7 +1838,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2154 "Zend/zend_language_scanner.l" +#line 2158 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; @@ -1853,7 +1853,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2146 "Zend/zend_language_scanner.l" +#line 2150 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1876,7 +1876,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1846 "Zend/zend_language_scanner.l" +#line 1850 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1888,7 +1888,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(89, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1431 "Zend/zend_language_scanner.l" +#line 1435 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -1907,7 +1907,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1838 "Zend/zend_language_scanner.l" +#line 1842 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1933,7 +1933,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1828 "Zend/zend_language_scanner.l" +#line 1832 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1952,7 +1952,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2133 "Zend/zend_language_scanner.l" +#line 2137 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -2026,7 +2026,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2257 "Zend/zend_language_scanner.l" +#line 2261 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2112,7 +2112,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2146 "Zend/zend_language_scanner.l" +#line 2150 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -2135,7 +2135,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1846 "Zend/zend_language_scanner.l" +#line 1850 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -2147,7 +2147,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(113, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1431 "Zend/zend_language_scanner.l" +#line 1435 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -2166,7 +2166,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1838 "Zend/zend_language_scanner.l" +#line 1842 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2192,7 +2192,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1828 "Zend/zend_language_scanner.l" +#line 1832 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2365,23 +2365,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(-1, yych); switch ((yych = *YYCURSOR)) { case 'C': - case 'c': goto yy719; + case 'c': goto yy726; case 'L': - case 'l': goto yy720; + case 'l': goto yy727; case 'M': - case 'm': goto yy721; + case 'm': goto yy728; case 'N': - case 'n': goto yy722; + case 'n': goto yy729; case 'V': - case 'v': goto yy723; + case 'v': goto yy730; case 'X': - case 'x': goto yy724; + case 'x': goto yy731; default: goto yy186; } yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1869 "Zend/zend_language_scanner.l" +#line 1873 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -2393,20 +2393,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'H') { - if (yych == 'E') goto yy701; + if (yych == 'E') goto yy708; goto yy186; } else { - if (yych <= 'I') goto yy702; + if (yych <= 'I') goto yy709; if (yych <= 'N') goto yy186; - goto yy703; + goto yy710; } } else { if (yych <= 'h') { - if (yych == 'e') goto yy701; + if (yych == 'e') goto yy708; goto yy186; } else { - if (yych <= 'i') goto yy702; - if (yych == 'o') goto yy703; + if (yych <= 'i') goto yy709; + if (yych == 'o') goto yy710; goto yy186; } } @@ -2415,20 +2415,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'U') { if (yych <= 'N') { - if (yych == 'I') goto yy680; + if (yych == 'I') goto yy687; goto yy186; } else { - if (yych <= 'O') goto yy681; + if (yych <= 'O') goto yy688; if (yych <= 'T') goto yy186; - goto yy682; + goto yy689; } } else { if (yych <= 'n') { - if (yych == 'i') goto yy680; + if (yych == 'i') goto yy687; goto yy186; } else { - if (yych <= 'o') goto yy681; - if (yych == 'u') goto yy682; + if (yych <= 'o') goto yy688; + if (yych == 'u') goto yy689; goto yy186; } } @@ -2613,7 +2613,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy138: YYDEBUG(138, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1420 "Zend/zend_language_scanner.l" +#line 1424 "Zend/zend_language_scanner.l" { return yytext[0]; } @@ -2877,7 +2877,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(168, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1425 "Zend/zend_language_scanner.l" +#line 1429 "Zend/zend_language_scanner.l" { yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return '{'; @@ -2888,7 +2888,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(170, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1437 "Zend/zend_language_scanner.l" +#line 1441 "Zend/zend_language_scanner.l" { RESET_DOC_COMMENT(); if (!zend_stack_is_empty(&SCNG(state_stack))) { @@ -2924,7 +2924,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy172: YYDEBUG(172, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1483 "Zend/zend_language_scanner.l" +#line 1487 "Zend/zend_language_scanner.l" { if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */ zendlval->value.lval = strtol(yytext, NULL, 0); @@ -2973,7 +2973,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1876 "Zend/zend_language_scanner.l" +#line 1880 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3014,7 +3014,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1967 "Zend/zend_language_scanner.l" +#line 1971 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3089,7 +3089,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2036 "Zend/zend_language_scanner.l" +#line 2040 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3136,7 +3136,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2127 "Zend/zend_language_scanner.l" +#line 2131 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; @@ -3147,7 +3147,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2385 "Zend/zend_language_scanner.l" +#line 2389 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3183,7 +3183,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy189: YYDEBUG(189, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1544 "Zend/zend_language_scanner.l" +#line 1548 "Zend/zend_language_scanner.l" { zendlval->value.dval = zend_strtod(yytext, NULL); zendlval->type = IS_DOUBLE; @@ -3281,7 +3281,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(201, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1462 "Zend/zend_language_scanner.l" +#line 1466 "Zend/zend_language_scanner.l" { char *bin = yytext + 2; /* Skip "0b" */ int len = yyleng - 2; @@ -3314,7 +3314,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(204, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1504 "Zend/zend_language_scanner.l" +#line 1508 "Zend/zend_language_scanner.l" { char *hex = yytext + 2; /* Skip "0x" */ int len = yyleng - 2; @@ -3344,7 +3344,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy206: YYDEBUG(206, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1944 "Zend/zend_language_scanner.l" +#line 1948 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3386,7 +3386,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy211: YYDEBUG(211, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1846 "Zend/zend_language_scanner.l" +#line 1850 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -3406,7 +3406,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(214, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1408 "Zend/zend_language_scanner.l" +#line 1412 "Zend/zend_language_scanner.l" { return T_LOGICAL_XOR; } @@ -3419,7 +3419,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(216, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1400 "Zend/zend_language_scanner.l" +#line 1404 "Zend/zend_language_scanner.l" { return T_LOGICAL_OR; } @@ -3429,7 +3429,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(218, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1388 "Zend/zend_language_scanner.l" +#line 1392 "Zend/zend_language_scanner.l" { return T_XOR_EQUAL; } @@ -3439,7 +3439,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(220, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1392 "Zend/zend_language_scanner.l" +#line 1396 "Zend/zend_language_scanner.l" { return T_BOOLEAN_OR; } @@ -3449,7 +3449,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(222, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1384 "Zend/zend_language_scanner.l" +#line 1388 "Zend/zend_language_scanner.l" { return T_OR_EQUAL; } @@ -3459,7 +3459,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(224, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1396 "Zend/zend_language_scanner.l" +#line 1400 "Zend/zend_language_scanner.l" { return T_BOOLEAN_AND; } @@ -3469,7 +3469,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(226, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1380 "Zend/zend_language_scanner.l" +#line 1384 "Zend/zend_language_scanner.l" { return T_AND_EQUAL; } @@ -3482,7 +3482,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy228: YYDEBUG(228, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1953 "Zend/zend_language_scanner.l" +#line 1957 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3501,7 +3501,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(230, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1368 "Zend/zend_language_scanner.l" +#line 1372 "Zend/zend_language_scanner.l" { return T_MOD_EQUAL; } @@ -3536,7 +3536,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(236, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1364 "Zend/zend_language_scanner.l" +#line 1368 "Zend/zend_language_scanner.l" { return T_CONCAT_EQUAL; } @@ -3549,7 +3549,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy238: YYDEBUG(238, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1910 "Zend/zend_language_scanner.l" +#line 1914 "Zend/zend_language_scanner.l" { int doc_com; @@ -3593,7 +3593,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(241, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1360 "Zend/zend_language_scanner.l" +#line 1364 "Zend/zend_language_scanner.l" { return T_DIV_EQUAL; } @@ -3620,7 +3620,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(246, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1356 "Zend/zend_language_scanner.l" +#line 1360 "Zend/zend_language_scanner.l" { return T_MUL_EQUAL; } @@ -3631,7 +3631,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy251; YYDEBUG(248, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1416 "Zend/zend_language_scanner.l" +#line 1420 "Zend/zend_language_scanner.l" { return T_SR; } @@ -3641,7 +3641,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(250, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1344 "Zend/zend_language_scanner.l" +#line 1348 "Zend/zend_language_scanner.l" { return T_IS_GREATER_OR_EQUAL; } @@ -3651,7 +3651,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(252, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1376 "Zend/zend_language_scanner.l" +#line 1380 "Zend/zend_language_scanner.l" { return T_SR_EQUAL; } @@ -3666,7 +3666,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy254: YYDEBUG(254, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1412 "Zend/zend_language_scanner.l" +#line 1416 "Zend/zend_language_scanner.l" { return T_SL; } @@ -3682,7 +3682,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(257, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1340 "Zend/zend_language_scanner.l" +#line 1344 "Zend/zend_language_scanner.l" { return T_IS_SMALLER_OR_EQUAL; } @@ -3693,7 +3693,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy259: YYDEBUG(259, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1336 "Zend/zend_language_scanner.l" +#line 1340 "Zend/zend_language_scanner.l" { return T_IS_NOT_EQUAL; } @@ -3748,7 +3748,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(268, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1372 "Zend/zend_language_scanner.l" +#line 1376 "Zend/zend_language_scanner.l" { return T_SL_EQUAL; } @@ -3857,7 +3857,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy279: YYDEBUG(279, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2078 "Zend/zend_language_scanner.l" +#line 2082 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -3945,7 +3945,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(285, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1328 "Zend/zend_language_scanner.l" +#line 1332 "Zend/zend_language_scanner.l" { return T_IS_NOT_IDENTICAL; } @@ -3955,7 +3955,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(287, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1348 "Zend/zend_language_scanner.l" +#line 1352 "Zend/zend_language_scanner.l" { return T_PLUS_EQUAL; } @@ -3965,7 +3965,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(289, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1316 "Zend/zend_language_scanner.l" +#line 1320 "Zend/zend_language_scanner.l" { return T_INC; } @@ -3999,7 +3999,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy298; YYDEBUG(295, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1332 "Zend/zend_language_scanner.l" +#line 1336 "Zend/zend_language_scanner.l" { return T_IS_EQUAL; } @@ -4019,7 +4019,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(299, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1324 "Zend/zend_language_scanner.l" +#line 1328 "Zend/zend_language_scanner.l" { return T_IS_IDENTICAL; } @@ -4153,7 +4153,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(319, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1679 "Zend/zend_language_scanner.l" +#line 1683 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4183,7 +4183,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(324, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1652 "Zend/zend_language_scanner.l" +#line 1656 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4235,7 +4235,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(330, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1634 "Zend/zend_language_scanner.l" +#line 1638 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; @@ -4276,7 +4276,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(338, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1613 "Zend/zend_language_scanner.l" +#line 1617 "Zend/zend_language_scanner.l" { char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4348,7 +4348,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(349, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1597 "Zend/zend_language_scanner.l" +#line 1601 "Zend/zend_language_scanner.l" { char *func_name = NULL; @@ -4384,7 +4384,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(354, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1640 "Zend/zend_language_scanner.l" +#line 1644 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4426,7 +4426,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(361, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1577 "Zend/zend_language_scanner.l" +#line 1581 "Zend/zend_language_scanner.l" { char *trait_name = NULL; @@ -4476,7 +4476,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(368, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1550 "Zend/zend_language_scanner.l" +#line 1554 "Zend/zend_language_scanner.l" { char *class_name = NULL; @@ -5219,7 +5219,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(486, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1352 "Zend/zend_language_scanner.l" +#line 1356 "Zend/zend_language_scanner.l" { return T_MINUS_EQUAL; } @@ -5229,7 +5229,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(488, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1320 "Zend/zend_language_scanner.l" +#line 1324 "Zend/zend_language_scanner.l" { return T_DEC; } @@ -5632,7 +5632,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(556, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1404 "Zend/zend_language_scanner.l" +#line 1408 "Zend/zend_language_scanner.l" { return T_LOGICAL_AND; } @@ -6239,14 +6239,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(652, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych <= 'R') goto yy186; - if (yych <= 'S') goto yy674; - goto yy673; + if (yych <= 'L') { + if (yych <= 'K') goto yy186; + goto yy675; + } else { + if (yych <= 'R') goto yy186; + if (yych <= 'S') goto yy674; + goto yy673; + } } else { - if (yych <= 'r') goto yy186; - if (yych <= 's') goto yy674; - if (yych <= 't') goto yy673; - goto yy186; + if (yych <= 'r') { + if (yych == 'l') goto yy675; + goto yy186; + } else { + if (yych <= 's') goto yy674; + if (yych <= 't') goto yy673; + goto yy186; + } } yy653: YYDEBUG(653, *YYCURSOR); @@ -6319,7 +6328,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CONTINUE; } -#line 6323 "Zend/zend_language_scanner.c" +#line 6332 "Zend/zend_language_scanner.c" yy663: YYDEBUG(663, *YYCURSOR); ++YYCURSOR; @@ -6332,7 +6341,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CONST; } -#line 6336 "Zend/zend_language_scanner.c" +#line 6345 "Zend/zend_language_scanner.c" yy665: YYDEBUG(665, *YYCURSOR); yych = *++YYCURSOR; @@ -6361,7 +6370,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CLONE; } -#line 6365 "Zend/zend_language_scanner.c" +#line 6374 "Zend/zend_language_scanner.c" yy670: YYDEBUG(670, *YYCURSOR); yych = *++YYCURSOR; @@ -6379,724 +6388,763 @@ int lex_scan(zval *zendlval TSRMLS_DC) { return T_CLASS; } -#line 6383 "Zend/zend_language_scanner.c" +#line 6392 "Zend/zend_language_scanner.c" yy673: YYDEBUG(673, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy677; - if (yych == 'c') goto yy677; + if (yych == 'C') goto yy684; + if (yych == 'c') goto yy684; goto yy186; yy674: YYDEBUG(674, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy675; - if (yych != 'e') goto yy186; + if (yych == 'E') goto yy682; + if (yych == 'e') goto yy682; + goto yy186; yy675: YYDEBUG(675, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'L') goto yy676; + if (yych != 'l') goto yy186; +yy676: + YYDEBUG(676, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'A') goto yy677; + if (yych != 'a') goto yy186; +yy677: + YYDEBUG(677, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'B') goto yy678; + if (yych != 'b') goto yy186; +yy678: + YYDEBUG(678, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'L') goto yy679; + if (yych != 'l') goto yy186; +yy679: + YYDEBUG(679, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy680; + if (yych != 'e') goto yy186; +yy680: + YYDEBUG(680, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(676, *YYCURSOR); + YYDEBUG(681, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1316 "Zend/zend_language_scanner.l" + { + return T_CALLABLE; +} +#line 6442 "Zend/zend_language_scanner.c" +yy682: + YYDEBUG(682, *YYCURSOR); + ++YYCURSOR; + if (yybm[0+(yych = *YYCURSOR)] & 4) { + goto yy185; + } + YYDEBUG(683, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1102 "Zend/zend_language_scanner.l" { return T_CASE; } -#line 6407 "Zend/zend_language_scanner.c" -yy677: - YYDEBUG(677, *YYCURSOR); +#line 6455 "Zend/zend_language_scanner.c" +yy684: + YYDEBUG(684, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy678; + if (yych == 'H') goto yy685; if (yych != 'h') goto yy186; -yy678: - YYDEBUG(678, *YYCURSOR); +yy685: + YYDEBUG(685, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(679, *YYCURSOR); + YYDEBUG(686, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1026 "Zend/zend_language_scanner.l" { return T_CATCH; } -#line 6425 "Zend/zend_language_scanner.c" -yy680: - YYDEBUG(680, *YYCURSOR); +#line 6473 "Zend/zend_language_scanner.c" +yy687: + YYDEBUG(687, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy697; - if (yych == 'n') goto yy697; + if (yych == 'N') goto yy704; + if (yych == 'n') goto yy704; goto yy186; -yy681: - YYDEBUG(681, *YYCURSOR); +yy688: + YYDEBUG(688, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy690; - if (yych == 'r') goto yy690; + if (yych == 'R') goto yy697; + if (yych == 'r') goto yy697; goto yy186; -yy682: - YYDEBUG(682, *YYCURSOR); +yy689: + YYDEBUG(689, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy683; + if (yych == 'N') goto yy690; if (yych != 'n') goto yy186; -yy683: - YYDEBUG(683, *YYCURSOR); +yy690: + YYDEBUG(690, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy684; + if (yych == 'C') goto yy691; if (yych != 'c') goto yy186; -yy684: - YYDEBUG(684, *YYCURSOR); +yy691: + YYDEBUG(691, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy685; + if (yych == 'T') goto yy692; if (yych != 't') goto yy186; -yy685: - YYDEBUG(685, *YYCURSOR); +yy692: + YYDEBUG(692, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy686; + if (yych == 'I') goto yy693; if (yych != 'i') goto yy186; -yy686: - YYDEBUG(686, *YYCURSOR); +yy693: + YYDEBUG(693, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy687; + if (yych == 'O') goto yy694; if (yych != 'o') goto yy186; -yy687: - YYDEBUG(687, *YYCURSOR); +yy694: + YYDEBUG(694, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy688; + if (yych == 'N') goto yy695; if (yych != 'n') goto yy186; -yy688: - YYDEBUG(688, *YYCURSOR); +yy695: + YYDEBUG(695, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(689, *YYCURSOR); + YYDEBUG(696, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1010 "Zend/zend_language_scanner.l" { return T_FUNCTION; } -#line 6480 "Zend/zend_language_scanner.c" -yy690: - YYDEBUG(690, *YYCURSOR); +#line 6528 "Zend/zend_language_scanner.c" +yy697: + YYDEBUG(697, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy691; + if (yych <= '/') goto yy698; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy692; + if (yych == 'E') goto yy699; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy692; + if (yych <= 'e') goto yy699; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy691: - YYDEBUG(691, *YYCURSOR); +yy698: + YYDEBUG(698, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1062 "Zend/zend_language_scanner.l" { return T_FOR; } -#line 6508 "Zend/zend_language_scanner.c" -yy692: - YYDEBUG(692, *YYCURSOR); +#line 6556 "Zend/zend_language_scanner.c" +yy699: + YYDEBUG(699, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy693; + if (yych == 'A') goto yy700; if (yych != 'a') goto yy186; -yy693: - YYDEBUG(693, *YYCURSOR); +yy700: + YYDEBUG(700, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy694; + if (yych == 'C') goto yy701; if (yych != 'c') goto yy186; -yy694: - YYDEBUG(694, *YYCURSOR); +yy701: + YYDEBUG(701, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy695; + if (yych == 'H') goto yy702; if (yych != 'h') goto yy186; -yy695: - YYDEBUG(695, *YYCURSOR); +yy702: + YYDEBUG(702, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(696, *YYCURSOR); + YYDEBUG(703, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1070 "Zend/zend_language_scanner.l" { return T_FOREACH; } -#line 6536 "Zend/zend_language_scanner.c" -yy697: - YYDEBUG(697, *YYCURSOR); +#line 6584 "Zend/zend_language_scanner.c" +yy704: + YYDEBUG(704, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy698; + if (yych == 'A') goto yy705; if (yych != 'a') goto yy186; -yy698: - YYDEBUG(698, *YYCURSOR); +yy705: + YYDEBUG(705, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy699; + if (yych == 'L') goto yy706; if (yych != 'l') goto yy186; -yy699: - YYDEBUG(699, *YYCURSOR); +yy706: + YYDEBUG(706, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(700, *YYCURSOR); + YYDEBUG(707, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1284 "Zend/zend_language_scanner.l" { return T_FINAL; } -#line 6559 "Zend/zend_language_scanner.c" -yy701: - YYDEBUG(701, *YYCURSOR); +#line 6607 "Zend/zend_language_scanner.c" +yy708: + YYDEBUG(708, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'F') { - if (yych == 'C') goto yy707; + if (yych == 'C') goto yy714; if (yych <= 'E') goto yy186; - goto yy708; + goto yy715; } else { if (yych <= 'c') { if (yych <= 'b') goto yy186; - goto yy707; + goto yy714; } else { - if (yych == 'f') goto yy708; + if (yych == 'f') goto yy715; goto yy186; } } -yy702: - YYDEBUG(702, *YYCURSOR); +yy709: + YYDEBUG(709, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy705; - if (yych == 'e') goto yy705; + if (yych == 'E') goto yy712; + if (yych == 'e') goto yy712; goto yy186; -yy703: - YYDEBUG(703, *YYCURSOR); +yy710: + YYDEBUG(710, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(704, *YYCURSOR); + YYDEBUG(711, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1058 "Zend/zend_language_scanner.l" { return T_DO; } -#line 6594 "Zend/zend_language_scanner.c" -yy705: - YYDEBUG(705, *YYCURSOR); +#line 6642 "Zend/zend_language_scanner.c" +yy712: + YYDEBUG(712, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(706, *YYCURSOR); + YYDEBUG(713, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1006 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6607 "Zend/zend_language_scanner.c" -yy707: - YYDEBUG(707, *YYCURSOR); +#line 6655 "Zend/zend_language_scanner.c" +yy714: + YYDEBUG(714, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy714; - if (yych == 'l') goto yy714; + if (yych == 'L') goto yy721; + if (yych == 'l') goto yy721; goto yy186; -yy708: - YYDEBUG(708, *YYCURSOR); +yy715: + YYDEBUG(715, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy709; + if (yych == 'A') goto yy716; if (yych != 'a') goto yy186; -yy709: - YYDEBUG(709, *YYCURSOR); +yy716: + YYDEBUG(716, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy710; + if (yych == 'U') goto yy717; if (yych != 'u') goto yy186; -yy710: - YYDEBUG(710, *YYCURSOR); +yy717: + YYDEBUG(717, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy711; + if (yych == 'L') goto yy718; if (yych != 'l') goto yy186; -yy711: - YYDEBUG(711, *YYCURSOR); +yy718: + YYDEBUG(718, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy712; + if (yych == 'T') goto yy719; if (yych != 't') goto yy186; -yy712: - YYDEBUG(712, *YYCURSOR); +yy719: + YYDEBUG(719, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(713, *YYCURSOR); + YYDEBUG(720, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1106 "Zend/zend_language_scanner.l" { return T_DEFAULT; } -#line 6646 "Zend/zend_language_scanner.c" -yy714: - YYDEBUG(714, *YYCURSOR); +#line 6694 "Zend/zend_language_scanner.c" +yy721: + YYDEBUG(721, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy715; + if (yych == 'A') goto yy722; if (yych != 'a') goto yy186; -yy715: - YYDEBUG(715, *YYCURSOR); +yy722: + YYDEBUG(722, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy716; + if (yych == 'R') goto yy723; if (yych != 'r') goto yy186; -yy716: - YYDEBUG(716, *YYCURSOR); +yy723: + YYDEBUG(723, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy717; + if (yych == 'E') goto yy724; if (yych != 'e') goto yy186; -yy717: - YYDEBUG(717, *YYCURSOR); +yy724: + YYDEBUG(724, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(718, *YYCURSOR); + YYDEBUG(725, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1078 "Zend/zend_language_scanner.l" { return T_DECLARE; } -#line 6674 "Zend/zend_language_scanner.c" -yy719: - YYDEBUG(719, *YYCURSOR); +#line 6722 "Zend/zend_language_scanner.c" +yy726: + YYDEBUG(726, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy781; - if (yych == 'h') goto yy781; + if (yych == 'H') goto yy788; + if (yych == 'h') goto yy788; goto yy186; -yy720: - YYDEBUG(720, *YYCURSOR); +yy727: + YYDEBUG(727, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy775; - if (yych == 's') goto yy775; + if (yych == 'S') goto yy782; + if (yych == 's') goto yy782; goto yy186; -yy721: - YYDEBUG(721, *YYCURSOR); +yy728: + YYDEBUG(728, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'P') goto yy771; - if (yych == 'p') goto yy771; + if (yych == 'P') goto yy778; + if (yych == 'p') goto yy778; goto yy186; -yy722: - YYDEBUG(722, *YYCURSOR); +yy729: + YYDEBUG(729, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy737; - if (yych == 'd') goto yy737; + if (yych == 'D') goto yy744; + if (yych == 'd') goto yy744; goto yy186; -yy723: - YYDEBUG(723, *YYCURSOR); +yy730: + YYDEBUG(730, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy734; - if (yych == 'a') goto yy734; + if (yych == 'A') goto yy741; + if (yych == 'a') goto yy741; goto yy186; -yy724: - YYDEBUG(724, *YYCURSOR); +yy731: + YYDEBUG(731, *YYCURSOR); yych = *++YYCURSOR; if (yych <= 'T') { - if (yych == 'I') goto yy725; + if (yych == 'I') goto yy732; if (yych <= 'S') goto yy186; - goto yy726; + goto yy733; } else { if (yych <= 'i') { if (yych <= 'h') goto yy186; } else { - if (yych == 't') goto yy726; + if (yych == 't') goto yy733; goto yy186; } } -yy725: - YYDEBUG(725, *YYCURSOR); +yy732: + YYDEBUG(732, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy732; - if (yych == 't') goto yy732; + if (yych == 'T') goto yy739; + if (yych == 't') goto yy739; goto yy186; -yy726: - YYDEBUG(726, *YYCURSOR); +yy733: + YYDEBUG(733, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy727; + if (yych == 'E') goto yy734; if (yych != 'e') goto yy186; -yy727: - YYDEBUG(727, *YYCURSOR); +yy734: + YYDEBUG(734, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy728; + if (yych == 'N') goto yy735; if (yych != 'n') goto yy186; -yy728: - YYDEBUG(728, *YYCURSOR); +yy735: + YYDEBUG(735, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy729; + if (yych == 'D') goto yy736; if (yych != 'd') goto yy186; -yy729: - YYDEBUG(729, *YYCURSOR); +yy736: + YYDEBUG(736, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy730; + if (yych == 'S') goto yy737; if (yych != 's') goto yy186; -yy730: - YYDEBUG(730, *YYCURSOR); +yy737: + YYDEBUG(737, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(731, *YYCURSOR); + YYDEBUG(738, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1142 "Zend/zend_language_scanner.l" { return T_EXTENDS; } -#line 6758 "Zend/zend_language_scanner.c" -yy732: - YYDEBUG(732, *YYCURSOR); +#line 6806 "Zend/zend_language_scanner.c" +yy739: + YYDEBUG(739, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(733, *YYCURSOR); + YYDEBUG(740, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1002 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6771 "Zend/zend_language_scanner.c" -yy734: - YYDEBUG(734, *YYCURSOR); +#line 6819 "Zend/zend_language_scanner.c" +yy741: + YYDEBUG(741, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy735; + if (yych == 'L') goto yy742; if (yych != 'l') goto yy186; -yy735: - YYDEBUG(735, *YYCURSOR); +yy742: + YYDEBUG(742, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(736, *YYCURSOR); + YYDEBUG(743, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1228 "Zend/zend_language_scanner.l" { return T_EVAL; } -#line 6789 "Zend/zend_language_scanner.c" -yy737: - YYDEBUG(737, *YYCURSOR); +#line 6837 "Zend/zend_language_scanner.c" +yy744: + YYDEBUG(744, *YYCURSOR); yych = *++YYCURSOR; YYDEBUG(-1, yych); switch (yych) { case 'D': - case 'd': goto yy738; + case 'd': goto yy745; case 'F': - case 'f': goto yy739; + case 'f': goto yy746; case 'I': - case 'i': goto yy740; + case 'i': goto yy747; case 'S': - case 's': goto yy741; + case 's': goto yy748; case 'W': - case 'w': goto yy742; + case 'w': goto yy749; default: goto yy186; } -yy738: - YYDEBUG(738, *YYCURSOR); +yy745: + YYDEBUG(745, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy764; - if (yych == 'e') goto yy764; + if (yych == 'E') goto yy771; + if (yych == 'e') goto yy771; goto yy186; -yy739: - YYDEBUG(739, *YYCURSOR); +yy746: + YYDEBUG(746, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy756; - if (yych == 'o') goto yy756; + if (yych == 'O') goto yy763; + if (yych == 'o') goto yy763; goto yy186; -yy740: - YYDEBUG(740, *YYCURSOR); +yy747: + YYDEBUG(747, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy754; - if (yych == 'f') goto yy754; + if (yych == 'F') goto yy761; + if (yych == 'f') goto yy761; goto yy186; -yy741: - YYDEBUG(741, *YYCURSOR); +yy748: + YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy748; - if (yych == 'w') goto yy748; + if (yych == 'W') goto yy755; + if (yych == 'w') goto yy755; goto yy186; -yy742: - YYDEBUG(742, *YYCURSOR); +yy749: + YYDEBUG(749, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy743; + if (yych == 'H') goto yy750; if (yych != 'h') goto yy186; -yy743: - YYDEBUG(743, *YYCURSOR); +yy750: + YYDEBUG(750, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy744; + if (yych == 'I') goto yy751; if (yych != 'i') goto yy186; -yy744: - YYDEBUG(744, *YYCURSOR); +yy751: + YYDEBUG(751, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy745; + if (yych == 'L') goto yy752; if (yych != 'l') goto yy186; -yy745: - YYDEBUG(745, *YYCURSOR); +yy752: + YYDEBUG(752, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy746; + if (yych == 'E') goto yy753; if (yych != 'e') goto yy186; -yy746: - YYDEBUG(746, *YYCURSOR); +yy753: + YYDEBUG(753, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(747, *YYCURSOR); + YYDEBUG(754, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1054 "Zend/zend_language_scanner.l" { return T_ENDWHILE; } -#line 6863 "Zend/zend_language_scanner.c" -yy748: - YYDEBUG(748, *YYCURSOR); +#line 6911 "Zend/zend_language_scanner.c" +yy755: + YYDEBUG(755, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy749; + if (yych == 'I') goto yy756; if (yych != 'i') goto yy186; -yy749: - YYDEBUG(749, *YYCURSOR); +yy756: + YYDEBUG(756, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy750; + if (yych == 'T') goto yy757; if (yych != 't') goto yy186; -yy750: - YYDEBUG(750, *YYCURSOR); +yy757: + YYDEBUG(757, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy751; + if (yych == 'C') goto yy758; if (yych != 'c') goto yy186; -yy751: - YYDEBUG(751, *YYCURSOR); +yy758: + YYDEBUG(758, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy752; + if (yych == 'H') goto yy759; if (yych != 'h') goto yy186; -yy752: - YYDEBUG(752, *YYCURSOR); +yy759: + YYDEBUG(759, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(753, *YYCURSOR); + YYDEBUG(760, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1098 "Zend/zend_language_scanner.l" { return T_ENDSWITCH; } -#line 6896 "Zend/zend_language_scanner.c" -yy754: - YYDEBUG(754, *YYCURSOR); +#line 6944 "Zend/zend_language_scanner.c" +yy761: + YYDEBUG(761, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(755, *YYCURSOR); + YYDEBUG(762, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1042 "Zend/zend_language_scanner.l" { return T_ENDIF; } -#line 6909 "Zend/zend_language_scanner.c" -yy756: - YYDEBUG(756, *YYCURSOR); +#line 6957 "Zend/zend_language_scanner.c" +yy763: + YYDEBUG(763, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy757; + if (yych == 'R') goto yy764; if (yych != 'r') goto yy186; -yy757: - YYDEBUG(757, *YYCURSOR); +yy764: + YYDEBUG(764, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy758; + if (yych <= '/') goto yy765; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy759; + if (yych == 'E') goto yy766; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy759; + if (yych <= 'e') goto yy766; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy758: - YYDEBUG(758, *YYCURSOR); +yy765: + YYDEBUG(765, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1066 "Zend/zend_language_scanner.l" { return T_ENDFOR; } -#line 6942 "Zend/zend_language_scanner.c" -yy759: - YYDEBUG(759, *YYCURSOR); +#line 6990 "Zend/zend_language_scanner.c" +yy766: + YYDEBUG(766, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy760; + if (yych == 'A') goto yy767; if (yych != 'a') goto yy186; -yy760: - YYDEBUG(760, *YYCURSOR); +yy767: + YYDEBUG(767, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy761; + if (yych == 'C') goto yy768; if (yych != 'c') goto yy186; -yy761: - YYDEBUG(761, *YYCURSOR); +yy768: + YYDEBUG(768, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy762; + if (yych == 'H') goto yy769; if (yych != 'h') goto yy186; -yy762: - YYDEBUG(762, *YYCURSOR); +yy769: + YYDEBUG(769, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(763, *YYCURSOR); + YYDEBUG(770, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1074 "Zend/zend_language_scanner.l" { return T_ENDFOREACH; } -#line 6970 "Zend/zend_language_scanner.c" -yy764: - YYDEBUG(764, *YYCURSOR); +#line 7018 "Zend/zend_language_scanner.c" +yy771: + YYDEBUG(771, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy765; + if (yych == 'C') goto yy772; if (yych != 'c') goto yy186; -yy765: - YYDEBUG(765, *YYCURSOR); +yy772: + YYDEBUG(772, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy766; + if (yych == 'L') goto yy773; if (yych != 'l') goto yy186; -yy766: - YYDEBUG(766, *YYCURSOR); +yy773: + YYDEBUG(773, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy767; + if (yych == 'A') goto yy774; if (yych != 'a') goto yy186; -yy767: - YYDEBUG(767, *YYCURSOR); +yy774: + YYDEBUG(774, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy768; + if (yych == 'R') goto yy775; if (yych != 'r') goto yy186; -yy768: - YYDEBUG(768, *YYCURSOR); +yy775: + YYDEBUG(775, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy769; + if (yych == 'E') goto yy776; if (yych != 'e') goto yy186; -yy769: - YYDEBUG(769, *YYCURSOR); +yy776: + YYDEBUG(776, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(770, *YYCURSOR); + YYDEBUG(777, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1082 "Zend/zend_language_scanner.l" { return T_ENDDECLARE; } -#line 7008 "Zend/zend_language_scanner.c" -yy771: - YYDEBUG(771, *YYCURSOR); +#line 7056 "Zend/zend_language_scanner.c" +yy778: + YYDEBUG(778, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy772; + if (yych == 'T') goto yy779; if (yych != 't') goto yy186; -yy772: - YYDEBUG(772, *YYCURSOR); +yy779: + YYDEBUG(779, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy773; + if (yych == 'Y') goto yy780; if (yych != 'y') goto yy186; -yy773: - YYDEBUG(773, *YYCURSOR); +yy780: + YYDEBUG(780, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(774, *YYCURSOR); + YYDEBUG(781, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1268 "Zend/zend_language_scanner.l" { return T_EMPTY; } -#line 7031 "Zend/zend_language_scanner.c" -yy775: - YYDEBUG(775, *YYCURSOR); +#line 7079 "Zend/zend_language_scanner.c" +yy782: + YYDEBUG(782, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy776; + if (yych == 'E') goto yy783; if (yych != 'e') goto yy186; -yy776: - YYDEBUG(776, *YYCURSOR); +yy783: + YYDEBUG(783, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy777; + if (yych <= '/') goto yy784; if (yych <= '9') goto yy185; } else { - if (yych == 'I') goto yy778; + if (yych == 'I') goto yy785; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'h') { if (yych != '`') goto yy185; } else { - if (yych <= 'i') goto yy778; + if (yych <= 'i') goto yy785; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy777: - YYDEBUG(777, *YYCURSOR); +yy784: + YYDEBUG(784, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1046 "Zend/zend_language_scanner.l" { return T_ELSE; } -#line 7064 "Zend/zend_language_scanner.c" -yy778: - YYDEBUG(778, *YYCURSOR); +#line 7112 "Zend/zend_language_scanner.c" +yy785: + YYDEBUG(785, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy779; + if (yych == 'F') goto yy786; if (yych != 'f') goto yy186; -yy779: - YYDEBUG(779, *YYCURSOR); +yy786: + YYDEBUG(786, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(780, *YYCURSOR); + YYDEBUG(787, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1038 "Zend/zend_language_scanner.l" { return T_ELSEIF; } -#line 7082 "Zend/zend_language_scanner.c" -yy781: - YYDEBUG(781, *YYCURSOR); +#line 7130 "Zend/zend_language_scanner.c" +yy788: + YYDEBUG(788, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy782; + if (yych == 'O') goto yy789; if (yych != 'o') goto yy186; -yy782: - YYDEBUG(782, *YYCURSOR); +yy789: + YYDEBUG(789, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(783, *YYCURSOR); + YYDEBUG(790, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1122 "Zend/zend_language_scanner.l" { return T_ECHO; } -#line 7100 "Zend/zend_language_scanner.c" +#line 7148 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7135,39 +7183,39 @@ int lex_scan(zval *zendlval TSRMLS_DC) 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, }; - YYDEBUG(784, *YYCURSOR); + YYDEBUG(791, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '-') { if (yych <= '\r') { - if (yych <= 0x08) goto yy792; - if (yych <= '\n') goto yy786; - if (yych <= '\f') goto yy792; + if (yych <= 0x08) goto yy799; + if (yych <= '\n') goto yy793; + if (yych <= '\f') goto yy799; } else { - if (yych == ' ') goto yy786; - if (yych <= ',') goto yy792; - goto yy788; + if (yych == ' ') goto yy793; + if (yych <= ',') goto yy799; + goto yy795; } } else { if (yych <= '_') { - if (yych <= '@') goto yy792; - if (yych <= 'Z') goto yy790; - if (yych <= '^') goto yy792; - goto yy790; + if (yych <= '@') goto yy799; + if (yych <= 'Z') goto yy797; + if (yych <= '^') goto yy799; + goto yy797; } else { - if (yych <= '`') goto yy792; - if (yych <= 'z') goto yy790; - if (yych <= '~') goto yy792; - goto yy790; + if (yych <= '`') goto yy799; + if (yych <= 'z') goto yy797; + if (yych <= '~') goto yy799; + goto yy797; } } -yy786: - YYDEBUG(786, *YYCURSOR); +yy793: + YYDEBUG(793, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy798; -yy787: - YYDEBUG(787, *YYCURSOR); + goto yy805; +yy794: + YYDEBUG(794, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1155 "Zend/zend_language_scanner.l" { @@ -7177,13 +7225,13 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7181 "Zend/zend_language_scanner.c" -yy788: - YYDEBUG(788, *YYCURSOR); +#line 7229 "Zend/zend_language_scanner.c" +yy795: + YYDEBUG(795, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '>') goto yy795; -yy789: - YYDEBUG(789, *YYCURSOR); + if ((yych = *YYCURSOR) == '>') goto yy802; +yy796: + YYDEBUG(796, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1174 "Zend/zend_language_scanner.l" { @@ -7191,14 +7239,14 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_pop_state(TSRMLS_C); goto restart; } -#line 7195 "Zend/zend_language_scanner.c" -yy790: - YYDEBUG(790, *YYCURSOR); +#line 7243 "Zend/zend_language_scanner.c" +yy797: + YYDEBUG(797, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy794; -yy791: - YYDEBUG(791, *YYCURSOR); + goto yy801; +yy798: + YYDEBUG(798, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1167 "Zend/zend_language_scanner.l" { @@ -7207,43 +7255,43 @@ int lex_scan(zval *zendlval TSRMLS_DC) zendlval->type = IS_STRING; return T_STRING; } -#line 7211 "Zend/zend_language_scanner.c" -yy792: - YYDEBUG(792, *YYCURSOR); +#line 7259 "Zend/zend_language_scanner.c" +yy799: + YYDEBUG(799, *YYCURSOR); yych = *++YYCURSOR; - goto yy789; -yy793: - YYDEBUG(793, *YYCURSOR); + goto yy796; +yy800: + YYDEBUG(800, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy794: - YYDEBUG(794, *YYCURSOR); +yy801: + YYDEBUG(801, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy793; + goto yy800; } - goto yy791; -yy795: - YYDEBUG(795, *YYCURSOR); + goto yy798; +yy802: + YYDEBUG(802, *YYCURSOR); ++YYCURSOR; - YYDEBUG(796, *YYCURSOR); + YYDEBUG(803, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1163 "Zend/zend_language_scanner.l" { return T_OBJECT_OPERATOR; } -#line 7236 "Zend/zend_language_scanner.c" -yy797: - YYDEBUG(797, *YYCURSOR); +#line 7284 "Zend/zend_language_scanner.c" +yy804: + YYDEBUG(804, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy798: - YYDEBUG(798, *YYCURSOR); +yy805: + YYDEBUG(805, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy797; + goto yy804; } - goto yy787; + goto yy794; } /* *********************************** */ yyc_ST_LOOKING_FOR_VARNAME: @@ -7282,27 +7330,27 @@ int lex_scan(zval *zendlval TSRMLS_DC) 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; - YYDEBUG(799, *YYCURSOR); + YYDEBUG(806, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '_') { - if (yych <= '@') goto yy803; - if (yych <= 'Z') goto yy801; - if (yych <= '^') goto yy803; + if (yych <= '@') goto yy810; + if (yych <= 'Z') goto yy808; + if (yych <= '^') goto yy810; } else { - if (yych <= '`') goto yy803; - if (yych <= 'z') goto yy801; - if (yych <= '~') goto yy803; + if (yych <= '`') goto yy810; + if (yych <= 'z') goto yy808; + if (yych <= '~') goto yy810; } -yy801: - YYDEBUG(801, *YYCURSOR); +yy808: + YYDEBUG(808, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy806; -yy802: - YYDEBUG(802, *YYCURSOR); + goto yy813; +yy809: + YYDEBUG(809, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1446 "Zend/zend_language_scanner.l" +#line 1450 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -7310,42 +7358,42 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7314 "Zend/zend_language_scanner.c" -yy803: - YYDEBUG(803, *YYCURSOR); +#line 7362 "Zend/zend_language_scanner.c" +yy810: + YYDEBUG(810, *YYCURSOR); ++YYCURSOR; - YYDEBUG(804, *YYCURSOR); + YYDEBUG(811, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1455 "Zend/zend_language_scanner.l" +#line 1459 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7327 "Zend/zend_language_scanner.c" -yy805: - YYDEBUG(805, *YYCURSOR); +#line 7375 "Zend/zend_language_scanner.c" +yy812: + YYDEBUG(812, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy806: - YYDEBUG(806, *YYCURSOR); +yy813: + YYDEBUG(813, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy805; + goto yy812; } - goto yy802; + goto yy809; } /* *********************************** */ yyc_ST_NOWDOC: - YYDEBUG(807, *YYCURSOR); + YYDEBUG(814, *YYCURSOR); YYFILL(1); yych = *YYCURSOR; - YYDEBUG(809, *YYCURSOR); + YYDEBUG(816, *YYCURSOR); ++YYCURSOR; - YYDEBUG(810, *YYCURSOR); + YYDEBUG(817, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2329 "Zend/zend_language_scanner.l" +#line 2333 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7400,7 +7448,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7404 "Zend/zend_language_scanner.c" +#line 7452 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7438,76 +7486,76 @@ int lex_scan(zval *zendlval TSRMLS_DC) 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, }; - YYDEBUG(811, *YYCURSOR); + YYDEBUG(818, *YYCURSOR); YYFILL(3); yych = *YYCURSOR; if (yych <= '/') { if (yych <= ' ') { if (yych <= '\f') { - if (yych <= 0x08) goto yy825; - if (yych <= '\n') goto yy821; - goto yy825; + if (yych <= 0x08) goto yy832; + if (yych <= '\n') goto yy828; + goto yy832; } else { - if (yych <= '\r') goto yy821; - if (yych <= 0x1F) goto yy825; - goto yy821; + if (yych <= '\r') goto yy828; + if (yych <= 0x1F) goto yy832; + goto yy828; } } else { if (yych <= '$') { - if (yych <= '"') goto yy820; - if (yych <= '#') goto yy821; - goto yy816; + if (yych <= '"') goto yy827; + if (yych <= '#') goto yy828; + goto yy823; } else { - if (yych == '\'') goto yy821; - goto yy820; + if (yych == '\'') goto yy828; + goto yy827; } } } else { if (yych <= '\\') { if (yych <= '@') { - if (yych <= '0') goto yy813; - if (yych <= '9') goto yy815; - goto yy820; + if (yych <= '0') goto yy820; + if (yych <= '9') goto yy822; + goto yy827; } else { - if (yych <= 'Z') goto yy823; - if (yych <= '[') goto yy820; - goto yy821; + if (yych <= 'Z') goto yy830; + if (yych <= '[') goto yy827; + goto yy828; } } else { if (yych <= '_') { - if (yych <= ']') goto yy818; - if (yych <= '^') goto yy820; - goto yy823; + if (yych <= ']') goto yy825; + if (yych <= '^') goto yy827; + goto yy830; } else { - if (yych <= '`') goto yy820; - if (yych <= 'z') goto yy823; - if (yych <= '~') goto yy820; - goto yy823; + if (yych <= '`') goto yy827; + if (yych <= 'z') goto yy830; + if (yych <= '~') goto yy827; + goto yy830; } } } -yy813: - YYDEBUG(813, *YYCURSOR); +yy820: + YYDEBUG(820, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 'W') { if (yych <= '9') { - if (yych >= '0') goto yy837; + if (yych >= '0') goto yy844; } else { - if (yych == 'B') goto yy834; + if (yych == 'B') goto yy841; } } else { if (yych <= 'b') { - if (yych <= 'X') goto yy836; - if (yych >= 'b') goto yy834; + if (yych <= 'X') goto yy843; + if (yych >= 'b') goto yy841; } else { - if (yych == 'x') goto yy836; + if (yych == 'x') goto yy843; } } -yy814: - YYDEBUG(814, *YYCURSOR); +yy821: + YYDEBUG(821, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1525 "Zend/zend_language_scanner.l" +#line 1529 "Zend/zend_language_scanner.l" { /* Offset could be treated as a long */ if (yyleng < MAX_LENGTH_OF_LONG - 1 || (yyleng == MAX_LENGTH_OF_LONG - 1 && strcmp(yytext, long_min_digits) < 0)) { zendlval->value.lval = strtol(yytext, NULL, 10); @@ -7519,81 +7567,81 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7523 "Zend/zend_language_scanner.c" -yy815: - YYDEBUG(815, *YYCURSOR); +#line 7571 "Zend/zend_language_scanner.c" +yy822: + YYDEBUG(822, *YYCURSOR); yych = *++YYCURSOR; - goto yy833; -yy816: - YYDEBUG(816, *YYCURSOR); + goto yy840; +yy823: + YYDEBUG(823, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '_') { - if (yych <= '@') goto yy817; - if (yych <= 'Z') goto yy829; - if (yych >= '_') goto yy829; + if (yych <= '@') goto yy824; + if (yych <= 'Z') goto yy836; + if (yych >= '_') goto yy836; } else { - if (yych <= '`') goto yy817; - if (yych <= 'z') goto yy829; - if (yych >= 0x7F) goto yy829; + if (yych <= '`') goto yy824; + if (yych <= 'z') goto yy836; + if (yych >= 0x7F) goto yy836; } -yy817: - YYDEBUG(817, *YYCURSOR); +yy824: + YYDEBUG(824, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1857 "Zend/zend_language_scanner.l" +#line 1861 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7548 "Zend/zend_language_scanner.c" -yy818: - YYDEBUG(818, *YYCURSOR); +#line 7596 "Zend/zend_language_scanner.c" +yy825: + YYDEBUG(825, *YYCURSOR); ++YYCURSOR; - YYDEBUG(819, *YYCURSOR); + YYDEBUG(826, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1852 "Zend/zend_language_scanner.l" +#line 1856 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7559 "Zend/zend_language_scanner.c" -yy820: - YYDEBUG(820, *YYCURSOR); +#line 7607 "Zend/zend_language_scanner.c" +yy827: + YYDEBUG(827, *YYCURSOR); yych = *++YYCURSOR; - goto yy817; -yy821: - YYDEBUG(821, *YYCURSOR); + goto yy824; +yy828: + YYDEBUG(828, *YYCURSOR); ++YYCURSOR; - YYDEBUG(822, *YYCURSOR); + YYDEBUG(829, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1862 "Zend/zend_language_scanner.l" +#line 1866 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7576 "Zend/zend_language_scanner.c" -yy823: - YYDEBUG(823, *YYCURSOR); +#line 7624 "Zend/zend_language_scanner.c" +yy830: + YYDEBUG(830, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy828; -yy824: - YYDEBUG(824, *YYCURSOR); + goto yy835; +yy831: + YYDEBUG(831, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1869 "Zend/zend_language_scanner.l" +#line 1873 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7591 "Zend/zend_language_scanner.c" -yy825: - YYDEBUG(825, *YYCURSOR); +#line 7639 "Zend/zend_language_scanner.c" +yy832: + YYDEBUG(832, *YYCURSOR); ++YYCURSOR; - YYDEBUG(826, *YYCURSOR); + YYDEBUG(833, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2385 "Zend/zend_language_scanner.l" +#line 2389 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7602,118 +7650,118 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7606 "Zend/zend_language_scanner.c" -yy827: - YYDEBUG(827, *YYCURSOR); +#line 7654 "Zend/zend_language_scanner.c" +yy834: + YYDEBUG(834, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy828: - YYDEBUG(828, *YYCURSOR); +yy835: + YYDEBUG(835, *YYCURSOR); if (yybm[0+yych] & 16) { - goto yy827; + goto yy834; } - goto yy824; -yy829: - YYDEBUG(829, *YYCURSOR); + goto yy831; +yy836: + YYDEBUG(836, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(830, *YYCURSOR); + YYDEBUG(837, *YYCURSOR); if (yych <= '^') { if (yych <= '9') { - if (yych >= '0') goto yy829; + if (yych >= '0') goto yy836; } else { - if (yych <= '@') goto yy831; - if (yych <= 'Z') goto yy829; + if (yych <= '@') goto yy838; + if (yych <= 'Z') goto yy836; } } else { if (yych <= '`') { - if (yych <= '_') goto yy829; + if (yych <= '_') goto yy836; } else { - if (yych <= 'z') goto yy829; - if (yych >= 0x7F) goto yy829; + if (yych <= 'z') goto yy836; + if (yych >= 0x7F) goto yy836; } } -yy831: - YYDEBUG(831, *YYCURSOR); +yy838: + YYDEBUG(838, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1846 "Zend/zend_language_scanner.l" +#line 1850 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7648 "Zend/zend_language_scanner.c" -yy832: - YYDEBUG(832, *YYCURSOR); +#line 7696 "Zend/zend_language_scanner.c" +yy839: + YYDEBUG(839, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy833: - YYDEBUG(833, *YYCURSOR); +yy840: + YYDEBUG(840, *YYCURSOR); if (yybm[0+yych] & 32) { - goto yy832; + goto yy839; } - goto yy814; -yy834: - YYDEBUG(834, *YYCURSOR); + goto yy821; +yy841: + YYDEBUG(841, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 128) { - goto yy842; + goto yy849; } -yy835: - YYDEBUG(835, *YYCURSOR); +yy842: + YYDEBUG(842, *YYCURSOR); YYCURSOR = YYMARKER; - goto yy814; -yy836: - YYDEBUG(836, *YYCURSOR); + goto yy821; +yy843: + YYDEBUG(843, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 64) { - goto yy840; + goto yy847; } - goto yy835; -yy837: - YYDEBUG(837, *YYCURSOR); + goto yy842; +yy844: + YYDEBUG(844, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(838, *YYCURSOR); - if (yych <= '/') goto yy839; - if (yych <= '9') goto yy837; -yy839: - YYDEBUG(839, *YYCURSOR); + YYDEBUG(845, *YYCURSOR); + if (yych <= '/') goto yy846; + if (yych <= '9') goto yy844; +yy846: + YYDEBUG(846, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1537 "Zend/zend_language_scanner.l" +#line 1541 "Zend/zend_language_scanner.l" { /* Offset must be treated as a string */ zendlval->value.str.val = (char *)estrndup(yytext, yyleng); zendlval->value.str.len = yyleng; zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7695 "Zend/zend_language_scanner.c" -yy840: - YYDEBUG(840, *YYCURSOR); +#line 7743 "Zend/zend_language_scanner.c" +yy847: + YYDEBUG(847, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(841, *YYCURSOR); + YYDEBUG(848, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy840; + goto yy847; } - goto yy839; -yy842: - YYDEBUG(842, *YYCURSOR); + goto yy846; +yy849: + YYDEBUG(849, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(843, *YYCURSOR); + YYDEBUG(850, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy842; + goto yy849; } - goto yy839; + goto yy846; } } -#line 2394 "Zend/zend_language_scanner.l" +#line 2398 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index a5c7fd183365b..0e3583472f79e 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1313,6 +1313,10 @@ NEWLINE ("\r"|"\n"|"\r\n") return T_ARRAY; } +"callable" { + return T_CALLABLE; +} + "++" { return T_INC; } diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 9f770360d306b..3dfd2f276b7b9 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -2383,6 +2383,22 @@ ZEND_METHOD(reflection_parameter, isArray) } /* }}} */ +/* {{{ proto public bool ReflectionParameter::isCallable() + Returns whether parameter MUST be callable */ +ZEND_METHOD(reflection_parameter, isCallable) +{ + reflection_object *intern; + parameter_reference *param; + + if (zend_parse_parameters_none() == FAILURE) { + return; + } + GET_REFLECTION_OBJECT_PTR(param); + + RETVAL_BOOL(param->arg_info->type_hint == IS_CALLABLE); +} +/* }}} */ + /* {{{ proto public bool ReflectionParameter::allowsNull() Returns whether NULL is allowed as this parameters's value */ ZEND_METHOD(reflection_parameter, allowsNull) @@ -5827,6 +5843,7 @@ static const zend_function_entry reflection_parameter_functions[] = { ZEND_ME(reflection_parameter, getDeclaringClass, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, getClass, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, isArray, arginfo_reflection__void, 0) + ZEND_ME(reflection_parameter, isCallable, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, allowsNull, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, getPosition, arginfo_reflection__void, 0) ZEND_ME(reflection_parameter, isOptional, arginfo_reflection__void, 0) diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index 12d8b0a584b81..54c10399a05f6 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -69,6 +69,7 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_INT_CAST", T_INT_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_DEC", T_DEC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_INC", T_INC, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("T_SCALAR_CAST", T_SCALAR_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CLONE", T_CLONE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_NEW", T_NEW, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_EXIT", T_EXIT, CONST_CS | CONST_PERSISTENT); @@ -134,6 +135,7 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_DOUBLE_ARROW", T_DOUBLE_ARROW, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_LIST", T_LIST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_ARRAY", T_ARRAY, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("T_CALLABLE", T_CALLABLE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CLASS_C", T_CLASS_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_METHOD_C", T_METHOD_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_FUNC_C", T_FUNC_C, CONST_CS | CONST_PERSISTENT); @@ -201,6 +203,7 @@ char *get_token_type_name(int token_type) case T_INT_CAST: return "T_INT_CAST"; case T_DEC: return "T_DEC"; case T_INC: return "T_INC"; + case T_SCALAR_CAST: return "T_SCALAR_CAST"; case T_CLONE: return "T_CLONE"; case T_NEW: return "T_NEW"; case T_EXIT: return "T_EXIT"; @@ -266,6 +269,7 @@ char *get_token_type_name(int token_type) case T_DOUBLE_ARROW: return "T_DOUBLE_ARROW"; case T_LIST: return "T_LIST"; case T_ARRAY: return "T_ARRAY"; + case T_CALLABLE: return "T_CALLABLE"; case T_CLASS_C: return "T_CLASS_C"; case T_METHOD_C: return "T_METHOD_C"; case T_FUNC_C: return "T_FUNC_C"; From b55d116e9aaf972d390c08fad4ab4875b4825d83 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 16 Aug 2011 10:46:49 +0000 Subject: [PATCH 0564/2394] Improve errormessage on wrong use statements --- Zend/zend_compile.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 943c5e49918f6..9e673b854d4df 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6647,6 +6647,9 @@ void zend_do_use(znode *ns_name, znode *new_name, int is_global TSRMLS_DC) /* {{ zend_error(E_COMPILE_ERROR, "Cannot use %s as %s because the name is already in use", Z_STRVAL_P(ns), Z_STRVAL_P(name)); } if (warn) { + if (!strcmp(Z_STRVAL_P(name), "strict")) { + zend_error(E_COMPILE_ERROR, "You seem to be trying to use a different language..."); + } zend_error(E_WARNING, "The use statement with non-compound name '%s' has no effect", Z_STRVAL_P(name)); } efree(lcname); From 35c9c4ed2df399c3ccf85e8708429720f0caf2df Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 16 Aug 2011 12:01:36 +0000 Subject: [PATCH 0565/2394] - Fixed ZTS build --- Zend/zend_execute.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 90eb113fe2efc..2fc9f119fe69c 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -639,7 +639,7 @@ static inline int zend_verify_arg_type(zend_function *zf, zend_uint arg_num, zva break; case IS_CALLABLE: - if (!zend_is_callable(arg, IS_CALLABLE_CHECK_SILENT, NULL) && (Z_TYPE_P(arg) != IS_NULL || !cur_arg_info->allow_null)) { + if (!zend_is_callable(arg, IS_CALLABLE_CHECK_SILENT, NULL TSRMLS_CC) && (Z_TYPE_P(arg) != IS_NULL || !cur_arg_info->allow_null)) { return zend_verify_arg_error(E_RECOVERABLE_ERROR, zf, arg_num, "be callable", "", zend_zval_type_name(arg), "" TSRMLS_CC); } break; From 8db63e887406e37ac664cf71ce7f367e73952000 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 16 Aug 2011 12:13:35 +0000 Subject: [PATCH 0566/2394] - Drop T_SCALAR_CAST --- Zend/zend_language_parser.y | 1 - ext/tokenizer/tokenizer_data.c | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 0a52fe4a258b1..906242fb48212 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -108,7 +108,6 @@ static YYSIZE_T zend_yytnamerr(char*, const char*); %token T_INC "++ (T_INC)" %token T_DEC "-- (T_DEC)" %token T_INT_CAST "(int) (T_INT_CAST)" -%token T_SCALAR_CAST "(scalar) (T_SCALAR_CAST)" %token T_DOUBLE_CAST "(double) (T_DOUBLE_CAST)" %token T_STRING_CAST "(string) (T_STRING_CAST)" %token T_ARRAY_CAST "(array) (T_ARRAY_CAST)" diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index 54c10399a05f6..55ad58c48bcc7 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -69,7 +69,6 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_INT_CAST", T_INT_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_DEC", T_DEC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_INC", T_INC, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("T_SCALAR_CAST", T_SCALAR_CAST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CLONE", T_CLONE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_NEW", T_NEW, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_EXIT", T_EXIT, CONST_CS | CONST_PERSISTENT); @@ -137,6 +136,7 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_ARRAY", T_ARRAY, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CALLABLE", T_CALLABLE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CLASS_C", T_CLASS_C, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("T_TRAIT_C", T_TRAIT_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_METHOD_C", T_METHOD_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_FUNC_C", T_FUNC_C, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_LINE", T_LINE, CONST_CS | CONST_PERSISTENT); @@ -203,7 +203,6 @@ char *get_token_type_name(int token_type) case T_INT_CAST: return "T_INT_CAST"; case T_DEC: return "T_DEC"; case T_INC: return "T_INC"; - case T_SCALAR_CAST: return "T_SCALAR_CAST"; case T_CLONE: return "T_CLONE"; case T_NEW: return "T_NEW"; case T_EXIT: return "T_EXIT"; @@ -271,6 +270,7 @@ char *get_token_type_name(int token_type) case T_ARRAY: return "T_ARRAY"; case T_CALLABLE: return "T_CALLABLE"; case T_CLASS_C: return "T_CLASS_C"; + case T_TRAIT_C: return "T_TRAIT_C"; case T_METHOD_C: return "T_METHOD_C"; case T_FUNC_C: return "T_FUNC_C"; case T_LINE: return "T_LINE"; From bddb3d6c5d824234b9f4b232d0b61a8bdd766d53 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 16 Aug 2011 14:52:54 +0000 Subject: [PATCH 0567/2394] docref_root is now required for html_errors to do anything --- tests/lang/bug35176.phpt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/lang/bug35176.phpt b/tests/lang/bug35176.phpt index dd56c76a68298..2928f7ec455b8 100755 --- a/tests/lang/bug35176.phpt +++ b/tests/lang/bug35176.phpt @@ -2,6 +2,7 @@ Bug #35176 (include()/require()/*_once() produce wrong error messages about main()) --INI-- html_errors=1 +docref_root="/" error_reporting=4095 --FILE-- --EXPECTF--
-Warning: require_once(nonexisiting.php) [function.require-once.html]: failed to open stream: No such file or directory in %sbug35176.php on line 2
+Warning: require_once(nonexisiting.php) [function.require-once.html]: failed to open stream: No such file or directory in %sbug35176.php on line 2

-Fatal error: require_once() [function.require.html]: Failed opening required 'nonexisiting.php' (%s) in %sbug35176.php on line 2
+Fatal error: require_once() [function.require.html]: Failed opening required 'nonexisiting.php' (%s) in %sbug35176.php on line 2
From 9ae3777b10aa624979bec155d078c078c781169b Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 17 Aug 2011 11:15:55 +0000 Subject: [PATCH 0568/2394] compile out when PHP_DEBUG is not present --- ext/mysqlnd/mysqlnd_alloc.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/ext/mysqlnd/mysqlnd_alloc.c b/ext/mysqlnd/mysqlnd_alloc.c index 9f77910acd8fe..0f1e51bfa68f4 100644 --- a/ext/mysqlnd/mysqlnd_alloc.c +++ b/ext/mysqlnd/mysqlnd_alloc.c @@ -78,7 +78,9 @@ void * _mysqlnd_emalloc(size_t size MYSQLND_MEM_D) { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = &MYSQLND_G(debug_emalloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_emalloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); @@ -111,7 +113,9 @@ void * _mysqlnd_pemalloc(size_t size, zend_bool persistent MYSQLND_MEM_D) { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = persistent? &MYSQLND_G(debug_malloc_fail_threshold):&MYSQLND_G(debug_emalloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_pemalloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); @@ -146,7 +150,9 @@ void * _mysqlnd_ecalloc(unsigned int nmemb, size_t size MYSQLND_MEM_D) { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = &MYSQLND_G(debug_ecalloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_ecalloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); DBG_INF_FMT("before: %lu", zend_memory_usage(FALSE TSRMLS_CC)); @@ -179,7 +185,9 @@ void * _mysqlnd_pecalloc(unsigned int nmemb, size_t size, zend_bool persistent M { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = persistent? &MYSQLND_G(debug_calloc_fail_threshold):&MYSQLND_G(debug_ecalloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_pecalloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); @@ -215,7 +223,9 @@ void * _mysqlnd_erealloc(void *ptr, size_t new_size MYSQLND_MEM_D) void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); size_t old_size = collect_memory_statistics && ptr? *(size_t *) (((char*)ptr) - sizeof(size_t)) : 0; +#if PHP_DEBUG long * threshold = &MYSQLND_G(debug_erealloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_erealloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); DBG_INF_FMT("ptr=%p old_size=%lu, new_size=%lu", ptr, old_size, new_size); @@ -248,7 +258,9 @@ void * _mysqlnd_perealloc(void *ptr, size_t new_size, zend_bool persistent MYSQL void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); size_t old_size = collect_memory_statistics && ptr? *(size_t *) (((char*)ptr) - sizeof(size_t)) : 0; +#if PHP_DEBUG long * threshold = persistent? &MYSQLND_G(debug_realloc_fail_threshold):&MYSQLND_G(debug_erealloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_perealloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); DBG_INF_FMT("ptr=%p old_size=%lu new_size=%lu persistent=%u", ptr, old_size, new_size, persistent); @@ -333,7 +345,9 @@ void * _mysqlnd_malloc(size_t size MYSQLND_MEM_D) { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = &MYSQLND_G(debug_malloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_malloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); @@ -364,7 +378,9 @@ void * _mysqlnd_calloc(unsigned int nmemb, size_t size MYSQLND_MEM_D) { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = &MYSQLND_G(debug_calloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_calloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); @@ -395,7 +411,9 @@ void * _mysqlnd_realloc(void *ptr, size_t new_size MYSQLND_MEM_D) { void *ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); +#if PHP_DEBUG long * threshold = &MYSQLND_G(debug_realloc_fail_threshold); +#endif DBG_ENTER(mysqlnd_realloc_name); DBG_INF_FMT("file=%-15s line=%4d", strrchr(__zend_filename, PHP_DIR_SEPARATOR) + 1, __zend_lineno); DBG_INF_FMT("ptr=%p new_size=%lu ", new_size, ptr); From ad76cffcde4a97eda3db6f00cfd6bf5c6bf94aeb Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 17 Aug 2011 11:56:04 +0000 Subject: [PATCH 0569/2394] - use provided stdint.h and avoid double definitions --- sapi/cli/php_http_parser.h | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h index 09ec79acf8f5f..dae45470ae213 100644 --- a/sapi/cli/php_http_parser.h +++ b/sapi/cli/php_http_parser.h @@ -28,17 +28,7 @@ extern "C" { #include #if defined(_WIN32) && !defined(__MINGW32__) -typedef __int8 int8_t; -typedef unsigned __int8 uint8_t; -typedef __int16 int16_t; -typedef unsigned __int16 uint16_t; -typedef __int32 int32_t; -typedef unsigned __int32 uint32_t; -typedef __int64 int64_t; -typedef unsigned __int64 uint64_t; - -typedef unsigned int size_t; -typedef int ssize_t; +#include "win32/php_stdint.h" #else #include #endif From 83414d2e53130719dfc2683ad61b82ae0dde488a Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 17 Aug 2011 11:59:39 +0000 Subject: [PATCH 0570/2394] - WS --- sapi/cli/php_http_parser.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h index dae45470ae213..353550f0171d5 100644 --- a/sapi/cli/php_http_parser.h +++ b/sapi/cli/php_http_parser.h @@ -28,9 +28,9 @@ extern "C" { #include #if defined(_WIN32) && !defined(__MINGW32__) -#include "win32/php_stdint.h" +# include "win32/php_stdint.h" #else -#include +# include #endif /* Compile with -DPHP_HTTP_PARSER_STRICT=0 to make less checks, but run From 5e0bf53ca297693e6af965869e04cbd4420e37fe Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 17 Aug 2011 12:26:43 +0000 Subject: [PATCH 0571/2394] Once is generally enough --- ext/mysqli/mysqli_fe.h | 134 ----------------------------------------- 1 file changed, 134 deletions(-) diff --git a/ext/mysqli/mysqli_fe.h b/ext/mysqli/mysqli_fe.h index 9dc78431101c9..8025aff711699 100644 --- a/ext/mysqli/mysqli_fe.h +++ b/ext/mysqli/mysqli_fe.h @@ -135,138 +135,4 @@ PHP_FUNCTION(mysqli_driver_construct); PHP_METHOD(mysqli_warning,__construct); #endif /* MYSQLI_FE_H */ -/* - +----------------------------------------------------------------------+ - | PHP Version 5 | - +----------------------------------------------------------------------+ - | Copyright (c) 1997-2011 The PHP Group | - +----------------------------------------------------------------------+ - | This source file is subject to version 3.01 of the PHP license, | - | that is bundled with this package in the file LICENSE, and is | - | available through the world-wide-web at the following url: | - | http://www.php.net/license/3_01.txt | - | If you did not receive a copy of the PHP license and are unable to | - | obtain it through the world-wide-web, please send a note to | - | license@php.net so we can mail you a copy immediately. | - +----------------------------------------------------------------------+ - | Author: Georg Richter | - Andrey Hristov | - +----------------------------------------------------------------------+ - - $Id: php_mysqli_structs.h 302179 2010-08-13 09:57:04Z andrey $ -*/ - -#ifndef MYSQLI_FE_H -#define MYSQLI_FE_H - -PHP_FUNCTION(mysqli); -PHP_FUNCTION(mysqli_affected_rows); -PHP_FUNCTION(mysqli_autocommit); -PHP_FUNCTION(mysqli_change_user); -PHP_FUNCTION(mysqli_character_set_name); -PHP_FUNCTION(mysqli_set_charset); -PHP_FUNCTION(mysqli_close); -PHP_FUNCTION(mysqli_commit); -PHP_FUNCTION(mysqli_connect); -PHP_FUNCTION(mysqli_connect_errno); -PHP_FUNCTION(mysqli_connect_error); -PHP_FUNCTION(mysqli_data_seek); -PHP_FUNCTION(mysqli_debug); -PHP_FUNCTION(mysqli_dump_debug_info); -PHP_FUNCTION(mysqli_errno); -PHP_FUNCTION(mysqli_error); -PHP_FUNCTION(mysqli_fetch_all); -PHP_FUNCTION(mysqli_fetch_array); -PHP_FUNCTION(mysqli_fetch_assoc); -PHP_FUNCTION(mysqli_fetch_object); -PHP_FUNCTION(mysqli_fetch_field); -PHP_FUNCTION(mysqli_fetch_fields); -PHP_FUNCTION(mysqli_fetch_field_direct); -PHP_FUNCTION(mysqli_fetch_lengths); -PHP_FUNCTION(mysqli_fetch_row); -PHP_FUNCTION(mysqli_field_count); -PHP_FUNCTION(mysqli_field_seek); -PHP_FUNCTION(mysqli_field_tell); -PHP_FUNCTION(mysqli_free_result); -PHP_FUNCTION(mysqli_get_cache_stats); -PHP_FUNCTION(mysqli_get_client_stats); -PHP_FUNCTION(mysqli_get_connection_stats); -PHP_FUNCTION(mysqli_get_charset); -PHP_FUNCTION(mysqli_get_client_info); -PHP_FUNCTION(mysqli_get_client_version); -PHP_FUNCTION(mysqli_get_host_info); -PHP_FUNCTION(mysqli_get_proto_info); -PHP_FUNCTION(mysqli_get_server_info); -PHP_FUNCTION(mysqli_get_server_version); -PHP_FUNCTION(mysqli_get_warnings); -PHP_FUNCTION(mysqli_info); -PHP_FUNCTION(mysqli_insert_id); -PHP_FUNCTION(mysqli_init); -PHP_FUNCTION(mysqli_kill); -PHP_FUNCTION(mysqli_link_construct); -PHP_FUNCTION(mysqli_set_local_infile_default); -PHP_FUNCTION(mysqli_set_local_infile_handler); -PHP_FUNCTION(mysqli_more_results); -PHP_FUNCTION(mysqli_multi_query); -PHP_FUNCTION(mysqli_next_result); -PHP_FUNCTION(mysqli_num_fields); -PHP_FUNCTION(mysqli_num_rows); -PHP_FUNCTION(mysqli_options); -PHP_FUNCTION(mysqli_ping); -PHP_FUNCTION(mysqli_poll); -PHP_FUNCTION(mysqli_prepare); -PHP_FUNCTION(mysqli_query); -PHP_FUNCTION(mysqli_stmt_result_metadata); -PHP_FUNCTION(mysqli_report); -PHP_FUNCTION(mysqli_read_query_result); -PHP_FUNCTION(mysqli_real_connect); -PHP_FUNCTION(mysqli_real_query); -PHP_FUNCTION(mysqli_real_escape_string); -PHP_FUNCTION(mysqli_reap_async_query); -PHP_FUNCTION(mysqli_rollback); -PHP_FUNCTION(mysqli_row_seek); -PHP_FUNCTION(mysqli_select_db); -PHP_FUNCTION(mysqli_stmt_attr_get); -PHP_FUNCTION(mysqli_stmt_attr_set); -PHP_FUNCTION(mysqli_stmt_bind_param); -PHP_FUNCTION(mysqli_stmt_bind_result); -PHP_FUNCTION(mysqli_stmt_execute); -PHP_FUNCTION(mysqli_stmt_field_count); -PHP_FUNCTION(mysqli_stmt_init); -PHP_FUNCTION(mysqli_stmt_prepare); -PHP_FUNCTION(mysqli_stmt_fetch); -PHP_FUNCTION(mysqli_stmt_param_count); -PHP_FUNCTION(mysqli_stmt_send_long_data); -PHP_FUNCTION(mysqli_embedded_server_end); -PHP_FUNCTION(mysqli_embedded_server_start); -PHP_FUNCTION(mysqli_sqlstate); -PHP_FUNCTION(mysqli_ssl_set); -PHP_FUNCTION(mysqli_stat); -PHP_FUNCTION(mysqli_refresh); -PHP_FUNCTION(mysqli_stmt_affected_rows); -PHP_FUNCTION(mysqli_stmt_close); -PHP_FUNCTION(mysqli_stmt_data_seek); -PHP_FUNCTION(mysqli_stmt_errno); -PHP_FUNCTION(mysqli_stmt_error); -PHP_FUNCTION(mysqli_stmt_free_result); -PHP_FUNCTION(mysqli_stmt_get_result); -PHP_FUNCTION(mysqli_stmt_get_warnings); -PHP_FUNCTION(mysqli_stmt_reset); -PHP_FUNCTION(mysqli_stmt_insert_id); -PHP_FUNCTION(mysqli_stmt_more_results); -PHP_FUNCTION(mysqli_stmt_next_result); -PHP_FUNCTION(mysqli_stmt_num_rows); -PHP_FUNCTION(mysqli_stmt_sqlstate); -PHP_FUNCTION(mysqli_stmt_store_result); -PHP_FUNCTION(mysqli_store_result); -PHP_FUNCTION(mysqli_thread_id); -PHP_FUNCTION(mysqli_thread_safe); -PHP_FUNCTION(mysqli_use_result); -PHP_FUNCTION(mysqli_warning_count); - -PHP_FUNCTION(mysqli_stmt_construct); -PHP_FUNCTION(mysqli_result_construct); -PHP_FUNCTION(mysqli_driver_construct); -PHP_METHOD(mysqli_warning,__construct); -#endif /* MYSQLI_FE_H */ From cb8d6198df882e93bd54776e510642a0fa1f18e3 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Wed, 17 Aug 2011 23:50:04 +0000 Subject: [PATCH 0572/2394] Fix bug #55445 (Incomplete implementation of

Welcome

+--EXPECTF-- +

Welcome chris

diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index c7301b2c7c287..0cb03e85b02d9 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Tue Aug 16 12:22:59 2011 */ +/* Generated by re2c 0.13.5 on Thu Aug 18 01:37:48 2011 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1099,7 +1099,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if (YYCURSOR < YYLIMIT) { switch (*YYCURSOR) { case '?': - if (CG(short_tags) || !strncasecmp(YYCURSOR + 1, "php", 3)) { /* Assume [ \t\n\r] follows "php" */ + if (CG(short_tags) || !strncasecmp(YYCURSOR + 1, "php", 3) || (*(YYCURSOR + 1) == '=')) { /* Assume [ \t\n\r] follows "php" */ break; } continue; diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 0e3583472f79e..827b7bf3d7281 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1780,7 +1780,7 @@ inline_char_handler: if (YYCURSOR < YYLIMIT) { switch (*YYCURSOR) { case '?': - if (CG(short_tags) || !strncasecmp(YYCURSOR + 1, "php", 3)) { /* Assume [ \t\n\r] follows "php" */ + if (CG(short_tags) || !strncasecmp(YYCURSOR + 1, "php", 3) || (*(YYCURSOR + 1) == '=')) { /* Assume [ \t\n\r] follows "php" */ break; } continue; diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 84ec3a480f6c6..069fe7ec2323e 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jul 31 20:09:38 2011 */ +/* Generated by re2c 0.13.5 on Thu Aug 18 01:37:48 2011 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { From 3202573befe9aea739030afa76a22124b478ed8e Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 18 Aug 2011 09:16:04 +0000 Subject: [PATCH 0573/2394] - do not use 64bit integer instead of size_t (can't be alloc'ed), or when the actual possible values are 32bit or lower only --- sapi/cli/php_http_parser.c | 10 +++++----- sapi/cli/php_http_parser.h | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sapi/cli/php_http_parser.c b/sapi/cli/php_http_parser.c index 5d5e44e3e551f..e58fba3410f03 100644 --- a/sapi/cli/php_http_parser.c +++ b/sapi/cli/php_http_parser.c @@ -323,12 +323,12 @@ size_t php_http_parser_execute (php_http_parser *parser, { char c, ch; const char *p = data, *pe; - int64_t to_read; + size_t to_read; enum state state = (enum state) parser->state; enum header_states header_state = (enum header_states) parser->header_state; - uint64_t index = parser->index; - uint64_t nread = parser->nread; + uint32_t index = parser->index; + uint32_t nread = parser->nread; /* technically we could combine all of these (except for url_mark) into one variable, saving stack space, but it seems more clear to have them @@ -1425,7 +1425,7 @@ size_t php_http_parser_execute (php_http_parser *parser, } case s_body_identity: - to_read = MIN(pe - p, (int64_t)parser->content_length); + to_read = MIN(pe - p, (size_t)parser->content_length); if (to_read > 0) { if (settings->on_body) settings->on_body(parser, p, to_read); p += to_read - 1; @@ -1510,7 +1510,7 @@ size_t php_http_parser_execute (php_http_parser *parser, { assert(parser->flags & F_CHUNKED); - to_read = MIN(pe - p, (int64_t)(parser->content_length)); + to_read = MIN(pe - p, (size_t)(parser->content_length)); if (to_read > 0) { if (settings->on_body) settings->on_body(parser, p, to_read); diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h index 353550f0171d5..8be44739a2bc4 100644 --- a/sapi/cli/php_http_parser.h +++ b/sapi/cli/php_http_parser.h @@ -112,7 +112,7 @@ struct php_http_parser { unsigned char index; uint32_t nread; - int64_t content_length; + size_t content_length; /** READ-ONLY **/ unsigned short http_major; From e385f3ccf47fb2f6319248fe71579d230b350ac9 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 19 Aug 2011 07:24:35 +0000 Subject: [PATCH 0574/2394] Fixed #55457(cli built-in web server does not work with IE), introduced by r315128 --- sapi/cli/php_http_parser.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h index 8be44739a2bc4..8fc730d400f6a 100644 --- a/sapi/cli/php_http_parser.h +++ b/sapi/cli/php_http_parser.h @@ -112,7 +112,7 @@ struct php_http_parser { unsigned char index; uint32_t nread; - size_t content_length; + long content_length; /** READ-ONLY **/ unsigned short http_major; From 2ebe3799b1ce9bc686c60e6ba95ec3248ab3001d Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 19 Aug 2011 07:40:51 +0000 Subject: [PATCH 0575/2394] Fixed #55457 for 5.4 branch Use ssize_t instead of long (as pierre suggestion) --- sapi/cli/php_http_parser.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h index 8fc730d400f6a..8254a4367ec3b 100644 --- a/sapi/cli/php_http_parser.h +++ b/sapi/cli/php_http_parser.h @@ -112,7 +112,7 @@ struct php_http_parser { unsigned char index; uint32_t nread; - long content_length; + ssize_t content_length; /** READ-ONLY **/ unsigned short http_major; From 7790c4d975084cf99a6cbd0cc6308caf8c2232b7 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 19 Aug 2011 08:30:26 +0000 Subject: [PATCH 0576/2394] Fixed #55450 (Built in web server not accepting file uploads), which might break #55121 fixing(r313677) Reopened #55121 to let somebody redone the fixing(as I can't reproduce 55121 in redhat 64-bit). --- sapi/cli/php_cli_server.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 3202afe00d943..71d83e9051152 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1401,6 +1401,8 @@ static size_t php_cli_server_client_send_through(php_cli_server_client *client, static void php_cli_server_client_populate_request_info(const php_cli_server_client *client, sapi_request_info *request_info) /* {{{ */ { + char **val; + request_info->request_method = php_http_method_str(client->request.request_method); request_info->proto_num = client->request.protocol_version; request_info->request_uri = client->request.request_uri; @@ -1408,12 +1410,8 @@ static void php_cli_server_client_populate_request_info(const php_cli_server_cli request_info->query_string = client->request.query_string; request_info->post_data = client->request.content; request_info->content_length = request_info->post_data_length = client->request.content_len; - { - char **val; - const char delimiter[] = ";"; - if (SUCCESS == zend_hash_find(&client->request.headers, "Content-Type", sizeof("Content-Type"), (void**)&val)) { - request_info->content_type = strtok(*val, delimiter); - } + if (SUCCESS == zend_hash_find(&client->request.headers, "Content-Type", sizeof("Content-Type"), (void**)&val)) { + request_info->content_type = *val; } } /* }}} */ From ac088cd6c256255c0abf86d974c334232570dc58 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 19 Aug 2011 08:52:29 +0000 Subject: [PATCH 0577/2394] News for bug #55450 --- NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 6898251e23436..ad32affa8f41c 100644 --- a/NEWS +++ b/NEWS @@ -242,6 +242,6 @@ PHP NEWS - Fixed PDO objects binary incompatibility. (Dmitry) - Fixed bug #52211 (iconv() returns part of string on error). (Felipe) - +- Fixed bug #55450 (Built in web server not accepting file uploads). (Laruence) <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From 15c1a736782feda4c641ab876c896ad952f064d8 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 19 Aug 2011 09:59:47 +0000 Subject: [PATCH 0578/2394] - Fixed bug #52461 (Incomplete doctype and missing xmlns) --- ext/standard/info.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/info.c b/ext/standard/info.c index f57e4afab39e6..ae5be6213e5e7 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -633,7 +633,7 @@ PHPAPI char *php_get_uname(char mode) PHPAPI void php_print_info_htmlhead(TSRMLS_D) { php_info_print("\n"); - php_info_print(""); + php_info_print(""); php_info_print("\n"); php_info_print_style(TSRMLS_C); php_info_print("phpinfo()"); From 29d7e7e8c08fa4e53acf5cad168b09b2cd244a96 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 19 Aug 2011 11:33:59 +0000 Subject: [PATCH 0579/2394] - fix build --- sapi/cli/php_http_parser.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sapi/cli/php_http_parser.h b/sapi/cli/php_http_parser.h index 8254a4367ec3b..b740a0995ef13 100644 --- a/sapi/cli/php_http_parser.h +++ b/sapi/cli/php_http_parser.h @@ -28,7 +28,9 @@ extern "C" { #include #if defined(_WIN32) && !defined(__MINGW32__) +# include # include "win32/php_stdint.h" +# include "config.w32.h" #else # include #endif From 9fbde3c349fb6079a251b7463b8ac5d0cebcc98a Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 19 Aug 2011 11:35:37 +0000 Subject: [PATCH 0580/2394] - undefine CALLBACK (btw, generic names like that should be avoided, w/o prefix :) --- sapi/cli/php_http_parser.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sapi/cli/php_http_parser.c b/sapi/cli/php_http_parser.c index e58fba3410f03..13b9ea12bcd1a 100644 --- a/sapi/cli/php_http_parser.c +++ b/sapi/cli/php_http_parser.c @@ -55,7 +55,9 @@ do { \ } \ } while (0) - +#ifdef PHP_WIN32 +# undef CALLBACK +#endif #define CALLBACK(FOR) \ do { \ CALLBACK_NOCLEAR(FOR); \ From 4f980905a0bff94807ea07cb897c0e4cd4e6b83f Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Fri, 19 Aug 2011 22:49:18 +0000 Subject: [PATCH 0581/2394] Unbreak crypt() (fix bug #55439) # If you want to remove static analyser messages, be my guest, # but please run unit tests after --- ext/standard/php_crypt_r.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index f4516712dae06..e8b482ab6b7d8 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -377,7 +377,7 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) /* Now make the output string */ memcpy(passwd, MD5_MAGIC, MD5_MAGIC_LEN); strlcpy(passwd + MD5_MAGIC_LEN, sp, sl + 1); - strlcat(passwd, "$", 1); + strcat(passwd, "$"); PHP_MD5Final(final, &ctx); From c746cf5dc993e8f82845a0d2ec774594663a49e2 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 20 Aug 2011 07:24:04 +0000 Subject: [PATCH 0582/2394] updated libmbfl to 1.3.2 (JISX-0213:2004 support). --- ext/mbstring/config.m4 | 3 + ext/mbstring/config.w32 | 5 +- ext/mbstring/libmbfl/NEWS | 30 + ext/mbstring/libmbfl/filters/Makefile.am | 11 +- ext/mbstring/libmbfl/filters/mbfilter_big5.c | 131 +- ext/mbstring/libmbfl/filters/mbfilter_big5.h | 5 + ext/mbstring/libmbfl/filters/mbfilter_cp936.c | 142 +- .../libmbfl/filters/mbfilter_euc_cn.c | 10 +- .../libmbfl/filters/mbfilter_euc_jp.c | 6 +- .../libmbfl/filters/mbfilter_euc_jp_2004.c | 78 + .../libmbfl/filters/mbfilter_euc_jp_2004.h | 43 + .../libmbfl/filters/mbfilter_gb18030.c | 66 +- ext/mbstring/libmbfl/filters/mbfilter_hz.c | 11 +- .../libmbfl/filters/mbfilter_iso2022jp_2004.c | 212 + .../libmbfl/filters/mbfilter_iso2022jp_2004.h | 44 + ext/mbstring/libmbfl/filters/mbfilter_sjis.c | 2 +- .../libmbfl/filters/mbfilter_sjis_2004.c | 676 +++ .../libmbfl/filters/mbfilter_sjis_2004.h | 49 + .../libmbfl/filters/mbfilter_sjis_mac.c | 73 +- .../libmbfl/filters/mbfilter_sjis_mac.h | 1 - .../libmbfl/filters/mbfilter_sjis_mobile.c | 20 +- .../libmbfl/filters/mbfilter_sjis_open.c | 2 +- .../libmbfl/filters/mbfilter_sjis_open.h | 1 + .../libmbfl/filters/unicode_table_cp936.h | 174 +- .../libmbfl/filters/unicode_table_jis.h | 2 +- .../libmbfl/filters/unicode_table_jis2004.h | 5026 +++++++++++++++++ ext/mbstring/libmbfl/mbfl/mbfilter.h | 2 +- ext/mbstring/libmbfl/mbfl/mbfl_consts.h | 1 + ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 17 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 7 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 4 + ext/mbstring/libmbfl/mbfl/mbfl_ident.c | 5 + 32 files changed, 6635 insertions(+), 224 deletions(-) create mode 100644 ext/mbstring/libmbfl/NEWS create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.h create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.h create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.h create mode 100644 ext/mbstring/libmbfl/filters/unicode_table_jis2004.h diff --git a/ext/mbstring/config.m4 b/ext/mbstring/config.m4 index 7af344f14123d..d27e68bfaff47 100644 --- a/ext/mbstring/config.m4 +++ b/ext/mbstring/config.m4 @@ -238,12 +238,14 @@ AC_DEFUN([PHP_MBSTRING_SETUP_LIBMBFL], [ libmbfl/filters/mbfilter_gb18030.c libmbfl/filters/mbfilter_euc_cn.c libmbfl/filters/mbfilter_euc_jp.c + libmbfl/filters/mbfilter_euc_jp_2004.c libmbfl/filters/mbfilter_euc_jp_win.c libmbfl/filters/mbfilter_euc_kr.c libmbfl/filters/mbfilter_euc_tw.c libmbfl/filters/mbfilter_htmlent.c libmbfl/filters/mbfilter_hz.c libmbfl/filters/mbfilter_iso2022_jp_ms.c + libmbfl/filters/mbfilter_iso2022jp_2004.c libmbfl/filters/mbfilter_iso2022_kr.c libmbfl/filters/mbfilter_iso8859_1.c libmbfl/filters/mbfilter_iso8859_10.c @@ -267,6 +269,7 @@ AC_DEFUN([PHP_MBSTRING_SETUP_LIBMBFL], [ libmbfl/filters/mbfilter_sjis_open.c libmbfl/filters/mbfilter_sjis_mobile.c libmbfl/filters/mbfilter_sjis_mac.c + libmbfl/filters/mbfilter_sjis_2004.c libmbfl/filters/mbfilter_tl_jisx0201_jisx0208.c libmbfl/filters/mbfilter_ucs2.c libmbfl/filters/mbfilter_ucs4.c diff --git a/ext/mbstring/config.w32 b/ext/mbstring/config.w32 index 8c8bea7e25381..cf796b639c2ca 100644 --- a/ext/mbstring/config.w32 +++ b/ext/mbstring/config.w32 @@ -29,13 +29,14 @@ if (PHP_MBSTRING != "no") { mbfilter_iso8859_2.c mbfilter_iso8859_3.c mbfilter_iso8859_4.c \ mbfilter_iso8859_5.c mbfilter_iso8859_6.c mbfilter_iso8859_7.c \ mbfilter_iso8859_8.c mbfilter_iso8859_9.c mbfilter_jis.c \ - mbfilter_iso2022_jp_ms.c mbfilter_gb18030.c \ + mbfilter_iso2022_jp_ms.c mbfilter_gb18030.c mbfiler_sjis_2004.c \ mbfilter_koi8r.c mbfilter_qprint.c mbfilter_sjis.c mbfilter_ucs2.c \ mbfilter_ucs4.c mbfilter_uhc.c mbfilter_utf16.c mbfilter_utf32.c \ mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c mbfilter_utf8_mobile.c \ - mbfilter_koi8u.c mbfilter_cp1254.c \ + mbfilter_koi8u.c mbfilter_cp1254.c mbfilter_euc_jp_2004.c \ mbfilter_uuencode.c mbfilter_armscii8.c mbfilter_cp850.c \ mbfilter_cp5022x.c mbfilter_sjis_open.c mbfilter_sjis_mobile.c mbfilter_sjis_mac.c \ + mbfilter_iso2022jp_2004.c \ mbfilter_tl_jisx0201_jisx0208.c", "mbstring"); ADD_SOURCES("ext/mbstring/libmbfl/mbfl", "mbfilter.c mbfilter_8bit.c \ diff --git a/ext/mbstring/libmbfl/NEWS b/ext/mbstring/libmbfl/NEWS new file mode 100644 index 0000000000000..fc16367ed1012 --- /dev/null +++ b/ext/mbstring/libmbfl/NEWS @@ -0,0 +1,30 @@ + +version 1.3.2 August 20, 2011 + +- added JISX-0213:2004 based encoding : Shift_JIS-2004, EUC-JP-2004, ISO-2022-JP-2004 (rui). +- added gb18030 encoding (rui). +- added CP950 with user user defined area based on Big5 (rui). +- added mapping for user defined character area to CP936 (rui). +- added UTF-8-Mobile to support the pictogram characters defined by mobile phone carrier in Japan (rui). + +version 1.3.1 August 5, 2011 + +- added check for invalid/obsolete utf-8 encoding (rui). + +version 1.3.0 August 1, 2011 + +- added encoding conversion between Shift_JIS and Unicode (6.0 or PUA) + for pictogram characters defined by mobile phone carrier in Japan (rui). + + Detailed info:https://github.com/hirokawa/libmbfl/wiki/Introduction-to-libmbflhttps:--github.com-hirokawa-libmbfl-wiki-Introduction-to-libmbfl-_edit%23 + +- fixed encoding conversion of cp5022x for user defined area (rui). +- added MacJapanese (SJIS-mac) for legacy encoding support (rui). +- backport from PHP 5.2 (rui). + +version 1.1.0 March 02, 2010 + +- added cp5022x encoding (moriyoshi) +- added ISO-2022-JP-MS (moriyoshi) +- moved to github.com from sourceforge.jp (moriyoshi) + diff --git a/ext/mbstring/libmbfl/filters/Makefile.am b/ext/mbstring/libmbfl/filters/Makefile.am index c1e414f011e53..ad7beb5580fe3 100644 --- a/ext/mbstring/libmbfl/filters/Makefile.am +++ b/ext/mbstring/libmbfl/filters/Makefile.am @@ -1,4 +1,4 @@ -EXTRA_DIST=mk_sb_tbl.awk +EXTRA_DIST=Makefile.bcc32 mk_sb_tbl.awk noinst_LTLIBRARIES=libmbfl_filters.la INCLUDES=-I../mbfl PERL=perl @@ -33,6 +33,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_uuencode.c \ mbfilter_base64.c \ mbfilter_sjis.c \ + mbfilter_sjis_2004.c \ mbfilter_sjis_open.c \ mbfilter_sjis_mobile.c \ mbfilter_sjis_mac.c \ @@ -47,12 +48,14 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_utf7.c \ mbfilter_utf7imap.c \ mbfilter_euc_jp_win.c \ + mbfilter_euc_jp_2004.c \ mbfilter_cp932.c \ mbfilter_cp51932.c \ mbfilter_euc_cn.c \ mbfilter_euc_kr.c \ mbfilter_uhc.c \ mbfilter_iso2022_jp_ms.c \ + mbfilter_iso2022_jp_2004.c \ mbfilter_gb18030.c \ mbfilter_iso2022_kr.c \ mbfilter_cp866.c \ @@ -80,12 +83,14 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_gb18030.h \ mbfilter_euc_cn.h \ mbfilter_euc_jp.h \ + mbfilter_euc_jp_2004.h \ mbfilter_euc_jp_win.h \ mbfilter_euc_kr.h \ mbfilter_euc_tw.h \ mbfilter_htmlent.h \ mbfilter_hz.h \ mbfilter_iso2022_jp_ms.h \ + mbfilter_iso2022_jp_2004.h \ mbfilter_iso2022_kr.h \ mbfilter_iso8859_1.h \ mbfilter_iso8859_10.h \ @@ -152,9 +157,9 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ unicode_table_armscii8.h \ unicode_table_cp850.h \ unicode_table_uhc.h \ + unicode_table_gb18030.h \ translit_kana_jisx0201_jisx0208.h \ - emoji2uni.h \ - sjis_mac2uni.h + emoji2uni.h mbfilter_iso8859_2.c: unicode_table_iso8859_2.h diff --git a/ext/mbstring/libmbfl/filters/mbfilter_big5.c b/ext/mbstring/libmbfl/filters/mbfilter_big5.c index aa14e3058d36b..f8227239e947a 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_big5.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_big5.c @@ -57,7 +57,7 @@ static const unsigned char mblen_table_big5[] = { /* 0x81-0xFE */ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1 }; -static const char *mbfl_encoding_big5_aliases[] = {"CN-BIG5", "BIG-FIVE", "BIGFIVE", "CP950", NULL}; +static const char *mbfl_encoding_big5_aliases[] = {"CN-BIG5", "BIG-FIVE", "BIGFIVE", NULL}; const mbfl_encoding mbfl_encoding_big5 = { mbfl_no_encoding_big5, @@ -68,6 +68,15 @@ const mbfl_encoding mbfl_encoding_big5 = { MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE }; +const mbfl_encoding mbfl_encoding_cp950 = { + mbfl_no_encoding_cp950, + "CP950", + "BIG5", + NULL, + mblen_table_big5, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + const struct mbfl_identify_vtbl vtbl_identify_big5 = { mbfl_no_encoding_big5, mbfl_filt_ident_common_ctor, @@ -75,6 +84,13 @@ const struct mbfl_identify_vtbl vtbl_identify_big5 = { mbfl_filt_ident_big5 }; +const struct mbfl_identify_vtbl vtbl_identify_cp950 = { + mbfl_no_encoding_cp950, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_big5 +}; + const struct mbfl_convert_vtbl vtbl_big5_wchar = { mbfl_no_encoding_big5, mbfl_no_encoding_wchar, @@ -93,21 +109,57 @@ const struct mbfl_convert_vtbl vtbl_wchar_big5 = { mbfl_filt_conv_common_flush }; +const struct mbfl_convert_vtbl vtbl_cp950_wchar = { + mbfl_no_encoding_cp950, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_big5_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_cp950 = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_cp950, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_big5, + mbfl_filt_conv_common_flush +}; + #define CK(statement) do { if ((statement) < 0) return (-1); } while (0) +/* 63 + 94 = 157 or 94 */ +static unsigned short cp950_pua_tbl[][4] = { + {0xe000,0xe310,0xfa40,0xfefe}, + {0xe311,0xeeb7,0x8e40,0xa0fe}, + {0xeeb8,0xf6b0,0x8140,0x8dfe}, + {0xf6b1,0xf70e,0xc6a1,0xc6fe}, + {0xf70f,0xf848,0xc740,0xc8fe}, +}; + /* * Big5 => wchar */ int mbfl_filt_conv_big5_wchar(int c, mbfl_convert_filter *filter) { - int c1, w; + int k; + int c1, w, c2; switch (filter->status) { case 0: - if (c >= 0 && c < 0x80) { /* latin */ + if (filter->from->no_encoding == mbfl_no_encoding_cp950) { + c1 = 0x80; + } else { + c1 = 0xa0; + } + + if (c >= 0 && c <= 0x80) { /* latin */ CK((*filter->output_function)(c, filter->data)); - } else if (c > 0xa0 && c < 0xff) { /* dbcs lead byte */ + } else if (c == 0xff) { + CK((*filter->output_function)(0xf8f8, filter->data)); + } else if (c > c1 && c < 0xff) { /* dbcs lead byte */ filter->status = 1; filter->cache = c; } else { @@ -131,6 +183,30 @@ mbfl_filt_conv_big5_wchar(int c, mbfl_convert_filter *filter) } else { w = 0; } + + if (filter->from->no_encoding == mbfl_no_encoding_cp950) { + /* PUA for CP950 */ + if (w <= 0 && + (((c1 >= 0xfa && c1 <= 0xfe) || (c1 >= 0x8e && c1 <= 0xa0) || + (c1 >= 0x81 && c1 <= 0x8d) ||(c1 >= 0xc7 && c1 <= 0xc8)) + && ((c > 0x39 && c < 0x7f) || (c > 0xa0 && c < 0xff))) || + ((c1 == 0xc6) && (c > 0xa0 && c < 0xff))) { + c2 = c1 << 8 | c; + for (k = 0; k < sizeof(cp950_pua_tbl)/(sizeof(unsigned short)*4); k++) { + if (c2 >= cp950_pua_tbl[k][2] && c2 <= cp950_pua_tbl[k][3]) { + break; + } + } + + if ((cp950_pua_tbl[k][2] & 0xff) == 0x40) { + w = 157*(c1 - (cp950_pua_tbl[k][2]>>8)) + c - (c >= 0xa1 ? 0x62 : 0x40) + + cp950_pua_tbl[k][0]; + } else { + w = c2 - cp950_pua_tbl[k][2] + cp950_pua_tbl[k][0]; + } + } + } + if (w <= 0) { w = (c1 << 8) | c; w &= MBFL_WCSPLANE_MASK; @@ -161,7 +237,8 @@ mbfl_filt_conv_big5_wchar(int c, mbfl_convert_filter *filter) int mbfl_filt_conv_wchar_big5(int c, mbfl_convert_filter *filter) { - int c1, s; + int k; + int c1, s, c2; s = 0; if (c >= ucs_a1_big5_table_min && c < ucs_a1_big5_table_max) { @@ -179,6 +256,39 @@ mbfl_filt_conv_wchar_big5(int c, mbfl_convert_filter *filter) } else if (c >= ucs_r2_big5_table_min && c < ucs_r2_big5_table_max) { s = ucs_r2_big5_table[c - ucs_r2_big5_table_min]; } + + if (filter->to->no_encoding == mbfl_no_encoding_cp950) { + if (c >= 0xe000 && c <= 0xf848) { /* PUA for CP950 */ + for (k = 0; k < sizeof(cp950_pua_tbl)/(sizeof(unsigned short)*4); k++) { + if (c <= cp950_pua_tbl[k][1]) { + break; + } + } + c1 = c - cp950_pua_tbl[k][0]; + if ((cp950_pua_tbl[k][2] & 0xff) == 0x40) { + c2 = cp950_pua_tbl[k][2] >> 8; + s = ((c1 / 157) + c2) << 8; c1 %= 157; + s |= c1 + (c1 >= 0x3f ? 0x62 : 0x40); + } else { + s = c1 + cp950_pua_tbl[k][2]; + } + } + + if (c == 0x80) { + s = 0x80; + } else if (c == 0xf8f8) { + s = 0xff; + } else if (c == 0x256d) { + s = 0xa27e; + } else if (c == 0x256e) { + s = 0xa2a1; + } else if (c == 0x256f) { + s = 0xa2a3; + } else if (c == 0x2570) { + s = 0xa2a2; + } + } + if (s <= 0) { c1 = c & ~MBFL_WCSPLANE_MASK; if (c1 == MBFL_WCSPLANE_BIG5) { @@ -191,7 +301,7 @@ mbfl_filt_conv_wchar_big5(int c, mbfl_convert_filter *filter) } } if (s >= 0) { - if (s < 0x80) { /* latin */ + if (s <= 0x80 || s == 0xff) { /* latin */ CK((*filter->output_function)(s, filter->data)); } else { CK((*filter->output_function)((s >> 8) & 0xff, filter->data)); @@ -208,6 +318,13 @@ mbfl_filt_conv_wchar_big5(int c, mbfl_convert_filter *filter) static int mbfl_filt_ident_big5(int c, mbfl_identify_filter *filter) { + int c1; + if (filter->encoding == mbfl_no_encoding_cp950) { + c1 = 0x80; + } else { + c1 = 0xa0; + } + if (filter->status) { /* kanji second char */ if (c < 0x40 || (c > 0x7e && c < 0xa1) ||c > 0xfe) { /* bad */ filter->flag = 1; @@ -215,7 +332,7 @@ static int mbfl_filt_ident_big5(int c, mbfl_identify_filter *filter) filter->status = 0; } else if (c >= 0 && c < 0x80) { /* latin ok */ ; - } else if (c > 0xa0 && c < 0xff) { /* DBCS lead byte */ + } else if (c > c1 && c < 0xff) { /* DBCS lead byte */ filter->status = 1; } else { /* bad */ filter->flag = 1; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_big5.h b/ext/mbstring/libmbfl/filters/mbfilter_big5.h index 6b6a26563b9e0..93d10de61aea3 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_big5.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_big5.h @@ -37,6 +37,11 @@ extern const struct mbfl_identify_vtbl vtbl_identify_big5; extern const struct mbfl_convert_vtbl vtbl_big5_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_big5; +extern const mbfl_encoding mbfl_encoding_cp950; +extern const struct mbfl_identify_vtbl vtbl_identify_cp950; +extern const struct mbfl_convert_vtbl vtbl_cp950_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_cp950; + int mbfl_filt_conv_big5_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_big5(int c, mbfl_convert_filter *filter); diff --git a/ext/mbstring/libmbfl/filters/mbfilter_cp936.c b/ext/mbstring/libmbfl/filters/mbfilter_cp936.c index 4cfaa8eb4e75f..cf609bf9cc833 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_cp936.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_cp936.c @@ -33,7 +33,7 @@ #include "mbfilter.h" #include "mbfilter_cp936.h" - +#define UNICODE_TABLE_CP936_DEF #include "unicode_table_cp936.h" static int mbfl_filt_ident_cp936(int c, mbfl_identify_filter *filter); @@ -102,7 +102,8 @@ const struct mbfl_convert_vtbl vtbl_wchar_cp936 = { int mbfl_filt_conv_cp936_wchar(int c, mbfl_convert_filter *filter) { - int c1, w; + int k; + int c1, c2, w; switch (filter->status) { case 0: @@ -110,39 +111,68 @@ mbfl_filt_conv_cp936_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(c, filter->data)); } else if (c == 0x80) { /* euro sign */ CK((*filter->output_function)(0x20ac, filter->data)); - } else if (c > 0x80 && c < 0xff) { /* dbcs lead byte */ + } else if (c < 0xff) { /* dbcs lead byte */ filter->status = 1; filter->cache = c; - } else { - w = c & MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; - CK((*filter->output_function)(w, filter->data)); + } else { /* 0xff */ + CK((*filter->output_function)(0xf8f5, filter->data)); } break; case 1: /* dbcs second byte */ filter->status = 0; c1 = filter->cache; - if ( c1 < 0xff && c1 > 0x80 && c > 0x39 && c < 0xff && c != 0x7f) { - w = (c1 - 0x81)*192 + (c - 0x40); - if (w >= 0 && w < cp936_ucs_table_size) { - w = cp936_ucs_table[w]; - } else { - w = 0; + + if (((c1 >= 0xaa && c1 <= 0xaf) || (c1 >= 0xf8 && c1 <= 0xfe)) && + (c >= 0xa1 && c <= 0xfe)) { + /* UDA part1,2: U+E000-U+E4C5 */ + w = 94*(c1 >= 0xf8 ? c1 - 0xf2 : c1 - 0xaa) + (c - 0xa1) + 0xe000; + CK((*filter->output_function)(w, filter->data)); + } else if (c1 >= 0xa1 && c1 <= 0xa7 && c >= 0x40 && c < 0xa1 && c != 0x7f) { + /* UDA part3 : U+E4C6-U+E765*/ + w = 96*(c1 - 0xa1) + c - (c >= 0x80 ? 0x41 : 0x40) + 0xe4c6; + CK((*filter->output_function)(w, filter->data)); + } + + c2 = (c1 << 8) | c; + + if (w <= 0 && + ((c2 >= 0xa2ab && c2 <= 0xa9f0 + (0xe80f-0xe801)) || + (c2 >= 0xd7fa && c2 <= 0xd7fa + (0xe814-0xe810)) || + (c2 >= 0xfe50 && c2 <= 0xfe80 + (0xe864-0xe844)))) { + for (k = 0; k < mbfl_cp936_pua_tbl_max; k++) { + if (c2 >= mbfl_cp936_pua_tbl[k][2] && + c2 <= mbfl_cp936_pua_tbl[k][2] + + mbfl_cp936_pua_tbl[k][1] - mbfl_cp936_pua_tbl[k][0]) { + w = c2 - mbfl_cp936_pua_tbl[k][2] + mbfl_cp936_pua_tbl[k][0]; + CK((*filter->output_function)(w, filter->data)); + break; + } } - if (w <= 0) { + } + + if (w <= 0) { + if (c1 < 0xff && c1 > 0x80 && c > 0x39 && c < 0xff && c != 0x7f) { + w = (c1 - 0x81)*192 + (c - 0x40); + if (w >= 0 && w < cp936_ucs_table_size) { + w = cp936_ucs_table[w]; + } else { + w = 0; + } + if (w <= 0) { + w = (c1 << 8) | c; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_WINCP936; + } + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { w = (c1 << 8) | c; - w &= MBFL_WCSPLANE_MASK; - w |= MBFL_WCSPLANE_WINCP936; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); } - CK((*filter->output_function)(w, filter->data)); - } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ - CK((*filter->output_function)(c, filter->data)); - } else { - w = (c1 << 8) | c; - w &= MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; - CK((*filter->output_function)(w, filter->data)); } break; @@ -160,25 +190,75 @@ mbfl_filt_conv_cp936_wchar(int c, mbfl_convert_filter *filter) int mbfl_filt_conv_wchar_cp936(int c, mbfl_convert_filter *filter) { - int c1, s; + int k, k1, k2; + int c1, s = 0, s1; - s = 0; if (c >= ucs_a1_cp936_table_min && c < ucs_a1_cp936_table_max) { + /* U+0000 - U+0451 */ s = ucs_a1_cp936_table[c - ucs_a1_cp936_table_min]; } else if (c >= ucs_a2_cp936_table_min && c < ucs_a2_cp936_table_max) { - s = ucs_a2_cp936_table[c - ucs_a2_cp936_table_min]; + /* U+2000 - U+26FF */ + if (c == 0x203e) { + s = 0xa3fe; + } else if (c == 0x2218) { + s = 0xa1e3; + } else if (c == 0x223c) { + s = 0xa1ab; + } else { + s = ucs_a2_cp936_table[c - ucs_a2_cp936_table_min]; + } } else if (c >= ucs_a3_cp936_table_min && c < ucs_a3_cp936_table_max) { + /* U+2F00 - U+33FF */ s = ucs_a3_cp936_table[c - ucs_a3_cp936_table_min]; } else if (c >= ucs_i_cp936_table_min && c < ucs_i_cp936_table_max) { + /* U+4D00-9FFF CJK Unified Ideographs (+ Extension A) */ s = ucs_i_cp936_table[c - ucs_i_cp936_table_min]; + } else if (c >= 0xe000 && c <= 0xe864) { /* PUA */ + if (c < 0xe766) { + if (c < 0xe4c6) { + c1 = c - 0xe000; + s = (c1 % 94) + 0xa1; c1 /= 94; + s |= (c1 < 0x06 ? c1 + 0xaa : c1 + 0xf2) << 8; + } else { + c1 = c - 0xe4c6; + s = ((c1 / 96) + 0xa1) << 8; c1 %= 96; + s |= c1 + (c1 >= 0x3f ? 0x41 : 0x40); + } + } else { + /* U+E766..U+E864 */ + k1 = 0; k2 = mbfl_cp936_pua_tbl_max; + while (k1 < k2) { + k = (k1 + k2) >> 1; + if (c < mbfl_cp936_pua_tbl[k][0]) { + k2 = k; + } else if (c > mbfl_cp936_pua_tbl[k][1]) { + k1 = k + 1; + } else { + s = c - mbfl_cp936_pua_tbl[k][0] + mbfl_cp936_pua_tbl[k][2]; + break; + } + } + } + } else if (c == 0xf8f5) { + s = 0xff; } else if (c >= ucs_ci_cp936_table_min && c < ucs_ci_cp936_table_max) { + /* U+F900-FA2F CJK Compatibility Ideographs */ s = ucs_ci_cp936_table[c - ucs_ci_cp936_table_min]; } else if (c >= ucs_cf_cp936_table_min && c < ucs_cf_cp936_table_max) { s = ucs_cf_cp936_table[c - ucs_cf_cp936_table_min]; } else if (c >= ucs_sfv_cp936_table_min && c < ucs_sfv_cp936_table_max) { - s = ucs_sfv_cp936_table[c - ucs_sfv_cp936_table_min]; - } else if (c >= ucs_hff_cp936_table_min && c < ucs_hff_cp936_table_max) { - s = ucs_hff_cp936_table[c - ucs_hff_cp936_table_min]; + s = ucs_sfv_cp936_table[c - ucs_sfv_cp936_table_min]; /* U+FE50-FE6F Small Form Variants */ + } else if (c >= ucs_hff_cp936_table_min && c < ucs_hff_cp936_table_max) { + /* U+FF00-FFFF HW/FW Forms */ + if (c == 0xff04) { + s = 0xa1e7; + } else if (c == 0xff5e) { + s = 0xa1ab; + } else if (c >= 0xff01 && c <= 0xff5d) { + s = c - 0xff01 + 0xa3a1; + } else if (c >= 0xffe0 && c <= 0xffe5) { + s = ucs_hff_s_cp936_table[c-0xffe0]; + } } if (s <= 0) { c1 = c & ~MBFL_WCSPLANE_MASK; @@ -192,7 +272,7 @@ mbfl_filt_conv_wchar_cp936(int c, mbfl_convert_filter *filter) } } if (s >= 0) { - if (s <= 0x80) { /* latin */ + if (s <= 0x80 || s == 0xff) { /* latin */ CK((*filter->output_function)(s, filter->data)); } else { CK((*filter->output_function)((s >> 8) & 0xff, filter->data)); diff --git a/ext/mbstring/libmbfl/filters/mbfilter_euc_cn.c b/ext/mbstring/libmbfl/filters/mbfilter_euc_cn.c index cc2bcc1cee220..f91edf364a68e 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_euc_cn.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_euc_cn.c @@ -169,7 +169,15 @@ mbfl_filt_conv_wchar_euccn(int c, mbfl_convert_filter *filter) } else if (c >= ucs_i_cp936_table_min && c < ucs_i_cp936_table_max) { s = ucs_i_cp936_table[c - ucs_i_cp936_table_min]; } else if (c >= ucs_hff_cp936_table_min && c < ucs_hff_cp936_table_max) { - s = ucs_hff_cp936_table[c - ucs_hff_cp936_table_min]; + if (c == 0xff04) { + s = 0xa1e7; + } else if (c == 0xff5e) { + s = 0xa1ab; + } else if (c >= 0xff01 && c <= 0xff5d) { + s = c - 0xff01 + 0xa3a1; + } else if (c >= 0xffe0 && c <= 0xffe5) { + s = ucs_hff_s_cp936_table[c-0xffe0]; + } } c1 = (s >> 8) & 0xff; c2 = s & 0xff; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_euc_jp.c b/ext/mbstring/libmbfl/filters/mbfilter_euc_jp.c index f5c9643772221..7015df4eae642 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_euc_jp.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_euc_jp.c @@ -37,9 +37,9 @@ #include "unicode_table_cp932_ext.h" #include "unicode_table_jis.h" -static int mbfl_filt_ident_eucjp(int c, mbfl_identify_filter *filter); +int mbfl_filt_ident_eucjp(int c, mbfl_identify_filter *filter); -static const unsigned char mblen_table_eucjp[] = { /* 0xA1-0xFE */ +const unsigned char mblen_table_eucjp[] = { /* 0xA1-0xFE */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -275,7 +275,7 @@ mbfl_filt_conv_wchar_eucjp(int c, mbfl_convert_filter *filter) return c; } -static int mbfl_filt_ident_eucjp(int c, mbfl_identify_filter *filter) +int mbfl_filt_ident_eucjp(int c, mbfl_identify_filter *filter) { switch (filter->status) { case 0: /* latin */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.c b/ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.c new file mode 100644 index 0000000000000..2905ce8dfab58 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.c @@ -0,0 +1,78 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_ja.c + * by rui hirokawa on 16 aug 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_euc_jp_2004.h" +#include "mbfilter_sjis_2004.h" + +#include "unicode_table_jis2004.h" + +extern int mbfl_filt_ident_eucjp(int c, mbfl_identify_filter *filter); +extern const unsigned char mblen_table_eucjp[]; + +static const char *mbfl_encoding_eucjp2004_aliases[] = {"EUC_JP-2004", NULL}; + +const mbfl_encoding mbfl_encoding_eucjp2004 = { + mbfl_no_encoding_eucjp2004, + "EUC-JP-2004", + "EUC-JP", + (const char *(*)[])&mbfl_encoding_eucjp2004_aliases, + mblen_table_eucjp, + MBFL_ENCTYPE_MBCS +}; + +const struct mbfl_identify_vtbl vtbl_identify_eucjp2004 = { + mbfl_no_encoding_eucjp2004, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_eucjp +}; + +const struct mbfl_convert_vtbl vtbl_eucjp2004_wchar = { + mbfl_no_encoding_eucjp2004, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_jis2004_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_eucjp2004 = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_eucjp2004, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_jis2004, + mbfl_filt_conv_jis2004_flush +}; + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.h b/ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.h new file mode 100644 index 0000000000000..ce4b60aacc146 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_euc_jp_2004.h @@ -0,0 +1,43 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_ja.h + * by rui hirokawa on 15 aug 2011. + * + */ + +#ifndef MBFL_MBFILTER_EUC_JP_2004_H +#define MBFL_MBFILTER_EUC_JP_2004_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_eucjp2004; +extern const struct mbfl_identify_vtbl vtbl_identify_eucjp2004; +extern const struct mbfl_convert_vtbl vtbl_eucjp2004_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_eucjp2004; + +int mbfl_filt_conv_eucjp2004_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_eucjp2004(int c, mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_EUC_JP_2004_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c b/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c index 31ed9f33db193..4e625b72e3ce6 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_gb18030.c @@ -136,7 +136,7 @@ mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(0x20ac, filter->data)); } else if (c == 0xff) { CK((*filter->output_function)(0x00ff, filter->data)); - } else if (c > 0x80 && c < 0xff) { /* dbcs/fbcs lead byte */ + } else if (c > 0x80 && c < 0xff) { /* dbcs/qbcs lead byte */ filter->status = 1; filter->cache = c; } else { @@ -146,7 +146,7 @@ mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) } break; - case 1: /* dbcs/fbcs second byte */ + case 1: /* dbcs/qbcs second byte */ c1 = filter->cache; filter->status = 0; @@ -154,7 +154,8 @@ mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) filter->status = 2; filter->cache = (c1 << 8) | c; return c; - } else if (c1 >= 0x90 && c1 <= 0xe3 && c >= 0x30 && c <= 0x39) { /* 4 byte range: Unicode 16 planes */ + } else if (c1 >= 0x90 && c1 <= 0xe3 && c >= 0x30 && c <= 0x39) { + /* 4 byte range: Unicode 16 planes */ filter->status = 2; filter->cache = (c1 << 8) | c; return c; @@ -162,16 +163,22 @@ mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) (c >= 0xa1 && c <= 0xfe)) { /* UDA part1,2: U+E000-U+E4C5 */ w = 94*(c1 >= 0xf8 ? c1 - 0xf2 : c1 - 0xaa) + (c - 0xa1) + 0xe000; CK((*filter->output_function)(w, filter->data)); - } else if (c1 >= 0xa1 && c1 <= 0xa7 && c >= 0x40 && c < 0xa1 && c != 0x7f) { /* UDA part3 : U+E4C6-U+E765*/ + } else if (c1 >= 0xa1 && c1 <= 0xa7 && c >= 0x40 && c < 0xa1 && c != 0x7f) { + /* UDA part3 : U+E4C6-U+E765*/ w = 96*(c1 - 0xa1) + c - (c >= 0x80 ? 0x41 : 0x40) + 0xe4c6; CK((*filter->output_function)(w, filter->data)); } - if (w <= 0) { - c2 = (c1 << 8) | c; + c2 = (c1 << 8) | c; + + if (w <= 0 && + ((c2 >= 0xa2ab && c2 <= 0xa9f0 + (0xe80f-0xe801)) || + (c2 >= 0xd7fa && c2 <= 0xd7fa + (0xe814-0xe810)) || + (c2 >= 0xfe50 && c2 <= 0xfe80 + (0xe864-0xe844)))) { for (k = 0; k < mbfl_gb18030_pua_tbl_max; k++) { if (c2 >= mbfl_gb18030_pua_tbl[k][2] && - c2 <= mbfl_gb18030_pua_tbl[k][2] + mbfl_gb18030_pua_tbl[k][1] - mbfl_gb18030_pua_tbl[k][0]) { + c2 <= mbfl_gb18030_pua_tbl[k][2] + mbfl_gb18030_pua_tbl[k][1] + - mbfl_gb18030_pua_tbl[k][0]) { w = c2 - mbfl_gb18030_pua_tbl[k][2] + mbfl_gb18030_pua_tbl[k][0]; CK((*filter->output_function)(w, filter->data)); break; @@ -207,7 +214,7 @@ mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) } } break; - case 2: /* fbcs third byte */ + case 2: /* qbcs third byte */ c1 = (filter->cache >> 8) & 0xff; c2 = filter->cache & 0xff; filter->status = 0; @@ -224,7 +231,7 @@ mbfl_filt_conv_gb18030_wchar(int c, mbfl_convert_filter *filter) } break; - case 3: /* fbcs fourth byte */ + case 3: /* qbcs fourth byte */ c1 = (filter->cache >> 16) & 0xff; c2 = (filter->cache >> 8) & 0xff; c3 = filter->cache & 0xff; @@ -279,9 +286,8 @@ int mbfl_filt_conv_wchar_gb18030(int c, mbfl_convert_filter *filter) { int k, k1, k2; - int c1, s, s1 = 0; + int c1, s = 0, s1 = 0; - s = 0; if (c >= ucs_a1_cp936_table_min && c < ucs_a1_cp936_table_max) { s = ucs_a1_cp936_table[c - ucs_a1_cp936_table_min]; } else if (c >= ucs_a2_cp936_table_min && c < ucs_a2_cp936_table_max) { @@ -291,13 +297,37 @@ mbfl_filt_conv_wchar_gb18030(int c, mbfl_convert_filter *filter) } else if (c >= ucs_i_cp936_table_min && c < ucs_i_cp936_table_max) { s = ucs_i_cp936_table[c - ucs_i_cp936_table_min]; } else if (c >= ucs_ci_cp936_table_min && c < ucs_ci_cp936_table_max) { - s = ucs_ci_cp936_table[c - ucs_ci_cp936_table_min]; + /* U+F900-FA2F CJK Compatibility Ideographs */ + if (c == 0xf92c) { + s = 0xfd9c; + } else if (c == 0xf979) { + s = 0xfd9d; + } else if (c == 0xf995) { + s = 0xfd9e; + } else if (c == 0xf9e7) { + s = 0xfd9f; + } else if (c == 0xf9f1) { + s = 0xfda0; + } else if (c >= 0xfa0c && c <= 0xfa29) { + s = ucs_ci_s_cp936_table[c - 0xfa0c]; + } } else if (c >= ucs_cf_cp936_table_min && c < ucs_cf_cp936_table_max) { + /* FE30h CJK Compatibility Forms */ s = ucs_cf_cp936_table[c - ucs_cf_cp936_table_min]; } else if (c >= ucs_sfv_cp936_table_min && c < ucs_sfv_cp936_table_max) { + /* U+FE50-FE6F Small Form Variants */ s = ucs_sfv_cp936_table[c - ucs_sfv_cp936_table_min]; } else if (c >= ucs_hff_cp936_table_min && c < ucs_hff_cp936_table_max) { - s = ucs_hff_cp936_table[c - ucs_hff_cp936_table_min]; + /* U+FF00-FFFF HW/FW Forms */ + if (c == 0xff04) { + s = 0xa1e7; + } else if (c == 0xff5e) { + s = 0xa1ab; + } else if (c >= 0xff01 && c <= 0xff5d) { + s = c - 0xff01 + 0xa3a1; + } else if (c >= 0xffe0 && c <= 0xffe5) { + s = ucs_hff_s_cp936_table[c-0xffe0]; + } } if (c == 0x20ac) { /* euro-sign */ @@ -371,7 +401,7 @@ mbfl_filt_conv_wchar_gb18030(int c, mbfl_convert_filter *filter) if (s >= 0) { if (s <= 0x80) { /* latin */ CK((*filter->output_function)(s, filter->data)); - } else if (s1 > 0) { /* fbcs */ + } else if (s1 > 0) { /* qbcs */ CK((*filter->output_function)(s1 & 0xff, filter->data)); CK((*filter->output_function)((s >> 16) & 0xff, filter->data)); CK((*filter->output_function)((s >> 8) & 0xff, filter->data)); @@ -403,8 +433,8 @@ static int mbfl_filt_ident_gb18030(int c, mbfl_identify_filter *filter) filter->status = 1; filter->status |= (c << 8); } - } else if (filter->status == 1) { /* dbcs/fbcs 2nd byte */ - if (((c1 >= 0x81 && c1 <= 0x84) || (c1 >= 0x90 && c1 <= 0xe3)) && c >= 0x30 && c <= 0x39) { /* fbcs */ + } else if (filter->status == 1) { /* dbcs/qbcs 2nd byte */ + if (((c1 >= 0x81 && c1 <= 0x84) || (c1 >= 0x90 && c1 <= 0xe3)) && c >= 0x30 && c <= 0x39) { /* qbcs */ filter->status = 2; } else if (((c1 >= 0xaa && c1 <= 0xaf) || (c1 >= 0xf8 && c1 <= 0xfe)) && (c >= 0xa1 && c <= 0xfe)) { filter->status = 0; /* UDA part 1,2 */ @@ -420,14 +450,14 @@ static int mbfl_filt_ident_gb18030(int c, mbfl_identify_filter *filter) filter->flag = 1; /* bad */ filter->status = 0; } - } else if (filter->status == 2) { /* fbcs 3rd byte */ + } else if (filter->status == 2) { /* qbcs 3rd byte */ if (c > 0x80 && c < 0xff) { filter->status = 3; } else { filter->flag = 1; /* bad */ filter->status = 0; } - } else if (filter->status == 3) { /* fbcs 4th byte */ + } else if (filter->status == 3) { /* qbcs 4th byte */ if (c >= 0x30 && c < 0x40) { filter->status = 0; } else { diff --git a/ext/mbstring/libmbfl/filters/mbfilter_hz.c b/ext/mbstring/libmbfl/filters/mbfilter_hz.c index cecce3965972a..893ad5f740c85 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_hz.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_hz.c @@ -34,7 +34,6 @@ #include "mbfilter.h" #include "mbfilter_hz.h" -#define UNICODE_TABLE_CP936_DEF #include "unicode_table_cp936.h" static int mbfl_filt_ident_hz(int c, mbfl_identify_filter *filter); @@ -166,7 +165,15 @@ mbfl_filt_conv_wchar_hz(int c, mbfl_convert_filter *filter) } else if (c >= ucs_i_cp936_table_min && c < ucs_i_cp936_table_max) { s = ucs_i_cp936_table[c - ucs_i_cp936_table_min]; } else if (c >= ucs_hff_cp936_table_min && c < ucs_hff_cp936_table_max) { - s = ucs_hff_cp936_table[c - ucs_hff_cp936_table_min]; + if (c == 0xff04) { + s = 0xa1e7; + } else if (c == 0xff5e) { + s = 0xa1ab; + } else if (c >= 0xff01 && c <= 0xff5d) { + s = c - 0xff01 + 0xa3a1; + } else if (c >= 0xffe0 && c <= 0xffe5) { + s = ucs_hff_s_cp936_table[c-0xffe0]; + } } if (s & 0x8000) { s -= 0x8080; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c new file mode 100644 index 0000000000000..fc807c5139fbb --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c @@ -0,0 +1,212 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_jis.c + * by rui hirokawa on 18 aug 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_iso2022jp_2004.h" +#include "mbfilter_sjis_2004.h" + +#include "unicode_table_jis2004.h" +#include "unicode_table_jis.h" + +extern int mbfl_filt_conv_any_jis_flush(mbfl_convert_filter *filter); + +static int mbfl_filt_conv_2022jp_2004_flush(mbfl_convert_filter *filter); +static int mbfl_filt_ident_2022jp_2004(int c, mbfl_identify_filter *filter); + +const mbfl_encoding mbfl_encoding_2022jp_2004 = { + mbfl_no_encoding_2022jp_2004, + "ISO-2022-JP-2004", + "ISO-2022-JP-2004", + NULL, + NULL, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_SHFTCODE | MBFL_ENCTYPE_GL_UNSAFE +}; + +const struct mbfl_identify_vtbl vtbl_identify_2022jp_2004 = { + mbfl_no_encoding_2022jp_2004, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_2022jp_2004 +}; + +const struct mbfl_convert_vtbl vtbl_2022jp_2004_wchar = { + mbfl_no_encoding_2022jp_2004, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_jis2004_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_2022jp_2004 = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_2022jp_2004, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_jis2004, + mbfl_filt_conv_2022jp_2004_flush +}; + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + +static int +mbfl_filt_conv_2022jp_2004_flush(mbfl_convert_filter *filter) +{ + int k, c1, c2, s1, s2; + + k = filter->cache; + + if ((filter->status & 0xf) == 1 && k >= 0 && k <= jisx0213_u2_tbl_len) { + s1 = jisx0213_u2_fb_tbl[k]; + c1 = (s1 >> 8) & 0x7f; + c2 = s1 & 0x7f; + + if ((filter->status & 0xff00) != 0x200) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x24, filter->data)); /* '$' */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x51, filter->data)); /* 'Q' */ + } + filter->status = 0x200; + CK((*filter->output_function)(c1, filter->data)); + CK((*filter->output_function)(c2, filter->data)); + } + filter->cache = 0; + + /* back to latin */ + if ((filter->status & 0xff00) != 0) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x42, filter->data)); /* 'B' */ + } + + filter->status &= 0xff; + + if (filter->flush_function != NULL) { + return (*filter->flush_function)(filter->data); + } + + return 0; +} + +static int mbfl_filt_ident_2022jp_2004(int c, mbfl_identify_filter *filter) +{ +retry: + switch (filter->status & 0xf) { +/* case 0x00: ASCII */ +/* case 0x80: X 0212 */ +/* case 0x90: X 0213 plane 1 */ +/* case 0xa0: X 0213 plane 2 */ + case 0: + if (c == 0x1b) { + filter->status += 2; + } else if (filter->status == 0x80 && c > 0x20 && c < 0x7f) { /* kanji first char */ + filter->status += 1; + } else if (c >= 0 && c < 0x80) { /* latin, CTLs */ + ; + } else { + filter->flag = 1; /* bad */ + } + break; + +/* case 0x81: X 0208 second char */ + case 1: + if (c == 0x1b) { + filter->status++; + } else { + filter->status &= ~0xf; + if (c < 0x21 || c > 0x7e) { /* bad */ + filter->flag = 1; + } + } + break; + + /* ESC */ + case 2: + if (c == 0x24) { /* '$' */ + filter->status++; + } else if (c == 0x28) { /* '(' */ + filter->status += 3; + } else { + filter->flag = 1; /* bad */ + filter->status &= ~0xf; + goto retry; + } + break; + + /* ESC $ */ + case 3: + if (c == 0x42) { /* 'B' */ + filter->status = 0x80; + } else if (c == 0x28) { /* '(' */ + filter->status++; + } else { + filter->flag = 1; /* bad */ + filter->status &= ~0xf; + goto retry; + } + break; + + /* ESC $ ( */ + case 4: + if (c == 0x51) { /* JIS X 0213 plane 1 */ + filter->status = 0x90; + } else if (c == 0x50) { /* JIS X 0213 plane 2 */ + filter->status = 0xa0; + } else { + filter->flag = 1; /* bad */ + filter->status &= ~0xf; + goto retry; + } + break; + + /* ESC ( */ + case 5: + if (c == 0x42) { /* 'B' */ + filter->status = 0; + } else { + filter->flag = 1; /* bad */ + filter->status &= ~0xf; + goto retry; + } + break; + + default: + filter->status = 0; + break; + } + + return c; +} + + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.h b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.h new file mode 100644 index 0000000000000..f6e56b9b9d7fb --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.h @@ -0,0 +1,44 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_ja.c + * by moriyoshi koizumi on 4 dec 2002. + * + */ + +#ifndef MBFL_MBFILTER_2022JP_2004_H +#define MBFL_MBFILTER_2022JP_2004_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_2022jp_2004; +extern const struct mbfl_identify_vtbl vtbl_identify_2022jp_2004; +extern const struct mbfl_convert_vtbl vtbl_2022jp_2004_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_2022jp_2004; + +int mbfl_filt_conv_2022jp_2004_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_2022jp_2004(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_any_2022jp_2004_flush(mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_2022JP_2004_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis.c index a2672d8fa2ee6..7c463cd7b11e1 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis.c @@ -42,7 +42,7 @@ int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); -static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ +const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c new file mode 100644 index 0000000000000..58d8788629dfb --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c @@ -0,0 +1,676 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_sjis.c + * by rui hirokawa on 15 aug 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_sjis_2004.h" + +#define UNICODE_TABLE_JIS2004_DEF + +#include "unicode_table_jis2004.h" +#include "unicode_table_jis.h" + +extern const unsigned char mblen_table_sjis[]; + +static int mbfl_filt_ident_sjis2004(int c, mbfl_identify_filter *filter); + +static const int uni2sjis_tbl_range[][2] = { + {0x0000, 0x045f}, + {0x4e00, 0x9fff}, + {0xff00, 0xffe5}, + {0xfa0f, 0xfa6a}, +}; + +static const unsigned short *uni2sjis_tbl[] = { + ucs_a1_jisx0213_table, + ucs_i_jisx0213_table, + ucs_r_jisx0213_table, + ucs_r2_jisx0213_table, +}; + +extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); +extern int mbfl_bisec_srch(int w, const unsigned short *tbl, int n); +extern int mbfl_bisec_srch2(int w, const unsigned short tbl[], int n); + +static const char *mbfl_encoding_sjis2004_aliases[] = {"SJIS2004","Shift_JIS-2004", NULL}; + +const mbfl_encoding mbfl_encoding_sjis2004 = { + mbfl_no_encoding_sjis2004, + "SJIS-2004", + "Shift_JIS", + (const char *(*)[])&mbfl_encoding_sjis2004_aliases, + mblen_table_sjis, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE +}; + +const struct mbfl_identify_vtbl vtbl_identify_sjis2004 = { + mbfl_no_encoding_sjis2004, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_sjis +}; + +const struct mbfl_convert_vtbl vtbl_sjis2004_wchar = { + mbfl_no_encoding_sjis2004, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_jis2004_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_sjis2004 = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_sjis2004, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_jis2004, + mbfl_filt_conv_jis2004_flush +}; + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + +#define SJIS_ENCODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + s1--; \ + s1 >>= 1; \ + if ((c1) < 0x5f) { \ + s1 += 0x71; \ + } else { \ + s1 += 0xb1; \ + } \ + s2 = c2; \ + if ((c1) & 1) { \ + if ((c2) < 0x60) { \ + s2--; \ + } \ + s2 += 0x20; \ + } else { \ + s2 += 0x7e; \ + } \ + } while (0) + +#define SJIS_DECODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + if (s1 < 0xa0) { \ + s1 -= 0x81; \ + } else { \ + s1 -= 0xc1; \ + } \ + s1 <<= 1; \ + s1 += 0x21; \ + s2 = c2; \ + if (s2 < 0x9f) { \ + if (s2 < 0x7f) { \ + s2++; \ + } \ + s2 -= 0x20; \ + } else { \ + s1++; \ + s2 -= 0x7e; \ + } \ + } while (0) + + +/* + * JIS-2004 => wchar + */ +int +mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) +{ + int k; + int c1, c2, s, s1, s2, w = 0, w1; + +retry: + switch (filter->status & 0xf) { + case 0: + if (c >= 0 && c < 0x80) { /* latin */ + if (filter->from->no_encoding == mbfl_no_encoding_eucjp2004) { + CK((*filter->output_function)(c, filter->data)); + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis2004) { + if (c == 0x5c) { + CK((*filter->output_function)(0x00a5, filter->data)); + } else if (c == 0x7e) { + CK((*filter->output_function)(0x203e, filter->data)); + } else { + CK((*filter->output_function)(c, filter->data)); + } + } else { /* ISO-2022-JP-2004 */ + if (c == 0x1b) { + filter->status += 6; + } else if ((filter->status == 0x80 || filter->status == 0x90 || filter->status == 0xa0) + && c > 0x20 && c < 0x7f) { /* kanji first char */ + filter->cache = c; + if (filter->status == 0x90) { + filter->status += 1; /* JIS X 0213 plane 1 */ + } else if (filter->status == 0xa0) { + filter->status += 4; /* JIS X 0213 plane 2 */ + } else { + filter->status += 5; /* JIS X 0208 */ + } + } else { + CK((*filter->output_function)(c, filter->data)); + } + } + } else { + if (filter->from->no_encoding == mbfl_no_encoding_eucjp2004) { + if (c > 0xa0 && c < 0xff) { /* X 0213 plane 1 first char */ + filter->status = 1; + filter->cache = c; + } else if (c == 0x8e) { /* kana first char */ + filter->status = 2; + } else if (c == 0x8f) { /* X 0213 plane 2 first char */ + filter->status = 3; + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis2004) { + if (c > 0xa0 && c < 0xe0) { /* kana */ + CK((*filter->output_function)(0xfec0 + c, filter->data)); + } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ + filter->status = 1; + filter->cache = c; + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + } + break; + + case 1: /* kanji second char */ + filter->status &= ~0xf; + c1 = filter->cache; + + if (filter->from->no_encoding == mbfl_no_encoding_eucjp2004) { + if (c > 0xa0 && c < 0xff) { + s1 = c1 - 0x80; + s2 = c - 0x80; + } + } else if (filter->from->no_encoding == mbfl_no_encoding_sjis2004) { + if (c >= 0x40 && c <= 0xfc && c != 0x7f) { + SJIS_DECODE(c1, c, s1, s2); + } + } else { + s1 = c1; + s2 = c; + } + w1 = (s1 << 8) | s2; + + if (w1 >= 0x2121) { + + if ((w1 >= 0x2477 && w1 <= 0x2479) || (w1 >= 0x2479 && w1 <= 0x247B) || + (w1 >= 0x2577 && w1 <= 0x257E) || w1 == 0x2678 || w1 == 0x2B44 || + (w1 >= 0x2B48 && w1 <= 0x2B4F) || (w1 >= 0x2B65 && w1 <= 0x2B66)) { + k = mbfl_bisec_srch2(w1, jisx0213_u2_key, jisx0213_u2_tbl_len); + if (k >= 0) { + w = jisx0213_u2_tbl[2*k]; + CK((*filter->output_function)(w, filter->data)); + w = jisx0213_u2_tbl[2*k+1]; + } + } + + if (w <= 0) { + w1 = (s1 - 0x21)*94 + s2 - 0x21; + if (w1 >= 0 && w1 < jisx0213_ucs_table_size) { + w = jisx0213_ucs_table[w1]; + } + } + + if (w <= 0) { + w1 = (s1 << 8) | s2; + k = mbfl_bisec_srch2(w1, jisx0213_jis_u5_key, jisx0213_u5_tbl_len); + if (k >= 0) { + w = jisx0213_jis_u5_tbl[k] + 0x20000; + } + } + + if (w <= 0) { + if (s1 < 0x7f && s2 < 0x7f) { + w = (s1 << 8) | s2; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_JIS0213; + } else { + w = (c1 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + } + } + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + w = (c1 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + case 2: /* got 0x8e : EUC-JP-2004 */ + filter->status = 0; + if (c > 0xa0 && c < 0xe0) { + w = 0xfec0 + c; + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + w = 0x8e00 | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + case 3: /* got 0x8f, X 0213 plane 2 first char : EUC-JP-2004 */ + if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + filter->status = 0; + } else { + filter->status++; + filter->cache = c; + } + break; + + case 4: /* got 0x8f, X 0213 plane 2 second char */ + + filter->status &= ~0xf; + c1 = filter->cache; + c2 = c; + if (filter->from->no_encoding == mbfl_no_encoding_eucjp2004) { + c1 -= 0x80; + c2 -= 0x80; + } + s1 = c1 - 0x21; + s2 = c2 - 0x21; + + if (s1 >= 0 && s1 < 94 && s2 >= 0 && s2 < 94) { + for (k = 0; k < jisx0213_p2_ofst_len; k++) { + if (s1 == jisx0213_p2_ofst[k]-1) { + break; + } + } + k = k - (jisx0213_p2_ofst[k]-1); + s = (s1 + 94 + k)*94 + s2; + if (s >= 0 && s < jisx0213_ucs_table_size) { + w = jisx0213_ucs_table[s]; + } else { + w = 0; + } + if (w <= 0) { + w1 = ((c1 + k + 94) << 8) | c2; + k = mbfl_bisec_srch2(w1, jisx0213_jis_u5_key, jisx0213_u5_tbl_len); + if (k >= 0) { + w = jisx0213_jis_u5_tbl[k] + 0x20000; + } + } + if (w <= 0) { + w = ((c1 & 0x7f) << 8) | (c2 & 0x7f); + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_JIS0213; + } + CK((*filter->output_function)(w, filter->data)); + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + w = (c1 << 8) | c | 0x8f0000; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + } else { + w = ((c1 & 0x7f) << 8) | (c2 & 0x7f); + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_JIS0213; + } + CK((*filter->output_function)(w, filter->data)); + } + + break; + + case 5: /* X 0212 */ + filter->status &= ~0xf; + c1 = filter->cache; + if (c > 0x20 && c < 0x7f) { + s = (c1 - 0x21)*94 + c - 0x21; + if (s >= 0 && s < jisx0208_ucs_table_size) { + w = jisx0208_ucs_table[s]; + } + } + if (w <= 0) { + w = (c1 << 8) | c; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_JIS0208; + } + CK((*filter->output_function)(w, filter->data)); + break; + + /* ESC */ +/* case 0x06: */ +/* case 0x16: */ +/* case 0x26: */ +/* case 0x86: */ +/* case 0x96: */ +/* case 0xa6: */ + case 6: + if (c == 0x24) { /* '$' */ + filter->status++; + } else if (c == 0x28) { /* '(' */ + filter->status += 3; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + goto retry; + } + break; + + /* ESC $ */ +/* case 0x07: */ +/* case 0x17: */ +/* case 0x27: */ +/* case 0x87: */ +/* case 0x97: */ +/* case 0xa7: */ + case 7: + if (c == 0x42) { /* 'B' -> JIS X 0208-1983 */ + filter->status = 0x80; + } else if (c == 0x28) { /* '(' */ + filter->status++; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + goto retry; + } + break; + + break; + + /* ESC $ ( */ +/* case 0x08: */ +/* case 0x18: */ +/* case 0x28: */ +/* case 0x88: */ +/* case 0x98: */ +/* case 0xa8: */ + case 8: + if (c == 0x51) { /* JIS X 0213 plane 1 */ + filter->status = 0x90; + } else if (c == 0x50) { /* JIS X 0213 plane 2 */ + filter->status = 0xa0; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + CK((*filter->output_function)(0x28, filter->data)); + goto retry; + } + break; + + /* ESC ( */ +/* case 0x09: */ +/* case 0x19: */ +/* case 0x29: */ +/* case 0x89: */ +/* case 0x99: */ + case 9: + if (c == 0x42) { /* 'B' : ASCII */ + filter->status = 0; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x28, filter->data)); + goto retry; + } + break; + + default: + filter->status = 0; + break; + } + + return c; +} + +int +mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { + int k; + int c1, c2, s1 = 0, s2; + +retry: + + if ((filter->status & 0xf)== 0 && ( c == 0x00E6 || + (c >= 0x0254 && c <= 0x02E9) || (c >= 0x304B && c <= 0x31F7))) { + for (k=0;kstatus++; + filter->cache = k; + return c; + } + } + } + + if ((filter->status & 0xf) == 1 && + filter->cache >= 0 && filter->cache <= jisx0213_u2_tbl_len) { + k = filter->cache; + filter->status &= ~0xf; + filter->cache = 0; + + c1 = jisx0213_u2_tbl[2*k]; + if ((c1 == 0x0254 || c1 == 0x028C || c1 == 0x0259 || c1 == 0x025A) + && c == 0x0301) { + k++; + } + if (c == jisx0213_u2_tbl[2*k+1]) { + s1 = jisx0213_u2_key[k]; + } else { /* fallback */ + s1 = jisx0213_u2_fb_tbl[k]; + + if (filter->to->no_encoding == mbfl_no_encoding_sjis2004) { + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); + } else if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + s2 = (s1 & 0xff) + 0x80; + s1 = ((s1 >> 8) & 0xff) + 0x80; + } else { + if (filter->status != 0x200) { + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + CK((*filter->output_function)(0x28, filter->data)); + CK((*filter->output_function)(0x51, filter->data)); + } + filter->status = 0x200; + + s2 = s1 & 0x7f; + s1 = (s1 >> 8) & 0x7f; + } + + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + goto retry; + } + } + + if (s1 <= 0) { + for (k=0; k= uni2sjis_tbl_range[k][0] && c <= uni2sjis_tbl_range[k][1]) { + s1 = uni2sjis_tbl[k][c-uni2sjis_tbl_range[k][0]]; + break; + } + } + } + + if (c >= ucs_c1_jisx0213_min && c <= ucs_c1_jisx0213_max) { + k = mbfl_bisec_srch(c, ucs_c1_jisx0213_tbl, ucs_c1_jisx0213_tbl_len); + if (k >= 0) { + s1 = ucs_c1_jisx0213_ofst[k] + c - ucs_c1_jisx0213_tbl[2*k]; + } + } + + if (c >= jisx0213_u5_tbl_min && c <= jisx0213_u5_tbl_max) { + k = mbfl_bisec_srch2(c - 0x20000, jisx0213_u5_jis_key, jisx0213_u5_tbl_len); + if (k >= 0) { + s1 = jisx0213_u5_jis_tbl[k]; + } + } + + if (s1 <= 0) { + c1 = c & ~MBFL_WCSPLANE_MASK; + if (c1 == MBFL_WCSPLANE_JIS0213) { + s1 = c & MBFL_WCSPLANE_MASK; + } else { + k = mbfl_bisec_srch2(c, jisx0213_uni2sjis_cmap_key, jisx0213_uni2sjis_cmap_len); + if (k >= 0) { + s1 = jisx0213_uni2sjis_cmap_val[k]; + } + } + if (c == 0) { + s1 = 0; + } else if (s1 <= 0) { + s1 = -1; + } + } else if (s1 >= 0x9980) { + s1 = -1; + } + + if (s1 >= 0) { + if (s1 < 0x80) { /* ASCII */ + if (filter->to->no_encoding == mbfl_no_encoding_2022jp_2004 && + (filter->status & 0xff00) != 0) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x42, filter->data)); /* 'B' */ + } + filter->status = 0; + CK((*filter->output_function)(s1, filter->data)); + } else if (s1 < 0x100) { /* latin or kana */ + if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + CK((*filter->output_function)(0x8e, filter->data)); + } + CK((*filter->output_function)(s1, filter->data)); + } else if (s1 < 0x7f00) { /* X 0213 plane 1 */ + if (filter->to->no_encoding == mbfl_no_encoding_sjis2004) { + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); + } else if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + s2 = (s1 & 0xff) + 0x80; + s1 = ((s1 >> 8) & 0xff) + 0x80; + } else { + if ((filter->status & 0xff00) != 0x200) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x24, filter->data)); /* '$' */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x51, filter->data)); /* 'Q' */ + } + filter->status = 0x200; + s2 = s1 & 0xff; + s1 = (s1 >> 8) & 0xff; + } + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } else { /* X 0213 plane 2 */ + if (filter->to->no_encoding == mbfl_no_encoding_sjis2004) { + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); + } else { + s2 = s1 & 0xff; + k = ((s1 >> 8) & 0xff) - 0x7f; + if (k >= 0 && k < jisx0213_p2_ofst_len) { + s1 = jisx0213_p2_ofst[k] - 1 + 0x21; + } + if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + s2 |= 0x80; + s1 |= 0x80; + CK((*filter->output_function)(0x8f, filter->data)); + } else { + if ((filter->status & 0xff00) != 0x200) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x24, filter->data)); /* '$' */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x50, filter->data)); /* 'P' */ + } + filter->status = 0x200; + } + } + + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } +} + +int +mbfl_filt_conv_jis2004_flush(mbfl_convert_filter *filter) +{ + int k, c1, c2, s1, s2; + + k = filter->cache; + + if (filter->status == 1 && k >= 0 && k <= jisx0213_u2_tbl_len) { + s1 = jisx0213_u2_fb_tbl[k]; + + if (filter->to->no_encoding == mbfl_no_encoding_sjis2004) { + c1 = (s1 >> 8) & 0xff; + c2 = s1 & 0xff; + SJIS_ENCODE(c1, c2, s1, s2); + } else if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + s2 = (s1 & 0xff) | 0x80; + s1 = ((s1 >> 8) & 0xff) | 0x80; + } + + CK((*filter->output_function)(s1, filter->data)); + CK((*filter->output_function)(s2, filter->data)); + } + filter->cache = 0; + filter->status = 0; + + if (filter->flush_function != NULL) { + return (*filter->flush_function)(filter->data); + } + + return 0; +} diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.h new file mode 100644 index 0000000000000..cf91f7a06b26d --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.h @@ -0,0 +1,49 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_sjis.c + * by rui hirokawa on 15 aug 2011. + * + */ + +#ifndef MBFL_MBFILTER_SJIS_2004_H +#define MBFL_MBFILTER_SJIS_2004_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_sjis2004; +extern const struct mbfl_identify_vtbl vtbl_identify_sjis2004; +extern const struct mbfl_convert_vtbl vtbl_sjis2004_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_sjis2004; + +int mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter); + +int mbfl_filt_conv_jis2004_flush(mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_SJIS_2004_H */ + +/* + * charset=UTF-8 + */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c index 09236733c0d69..0fd01854ab02c 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c @@ -37,26 +37,10 @@ #include "unicode_table_cp932_ext.h" #include "unicode_table_jis.h" -static int mbfl_filt_ident_sjis_mac(int c, mbfl_identify_filter *filter); - -static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 -}; +extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); +extern const unsigned char mblen_table_sjis[]; + +static int mbfl_filt_conv_sjis_mac_flush(mbfl_convert_filter *filter); static const char *mbfl_encoding_sjis_mac_aliases[] = {"MacJapanese", "x-Mac-Japanese", NULL}; @@ -73,7 +57,7 @@ const struct mbfl_identify_vtbl vtbl_identify_sjis_mac = { mbfl_no_encoding_sjis_mac, mbfl_filt_ident_common_ctor, mbfl_filt_ident_common_dtor, - mbfl_filt_ident_sjis_mac + mbfl_filt_ident_sjis }; const struct mbfl_convert_vtbl vtbl_sjis_mac_wchar = { @@ -141,7 +125,7 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_mac = { #include "sjis_mac2uni.h" -const int code_tbl[][3] = { +static const int code_tbl[][3] = { {0x02f0, 0x0303, 0x2460}, {0x030e, 0x0321, 0x2474}, {0x032c, 0x0334, 0x2776}, @@ -151,7 +135,7 @@ const int code_tbl[][3] = { {0x038a, 0x03a3, 0x249c}, }; -const int code_ofst_tbl[] [2]= { +static const int code_ofst_tbl[] [2]= { {0x03ac, 0x03c9}, {0x0406, 0x0420}, {0x0432, 0x0441}, @@ -162,11 +146,11 @@ const int code_ofst_tbl[] [2]= { {0x1ff2, 0x20a5}, }; -const int *code_map[] = { +static const int *code_map[] = { sjis_mac2wchar1, sjis_mac2wchar2, sjis_mac2wchar3, sjis_mac2wchar4, sjis_mac2wchar5, sjis_mac2wchar6, sjis_mac2wchar7, sjis_mac2wchar8}; -const int code_tbl_m[][6] = { +static const int code_tbl_m[][6] = { {0x0340, 0xf860, 0x0030, 0x002e, 0x0000, 0x0000}, {0x03c9, 0xf860, 0x0054, 0x0042, 0x0000, 0x0000}, {0x035c, 0xf860, 0x0058, 0x0056, 0x0000, 0x0000}, @@ -181,7 +165,7 @@ const int code_tbl_m[][6] = { {0x0523, 0xf862, 0x8ca1, 0x56e3, 0x6cd5, 0x4eba}, }; -const int s_form_tbl[] = { +static const int s_form_tbl[] = { 0x2010,0x2016,0x2026, 0x3001,0x3002,0x301c,0x3041,0x3043,0x3045,0x3047,0x3049, 0x3063,0x3083,0x3085,0x3087,0x308e,0x30a1,0x30a3,0x30a5, @@ -192,7 +176,7 @@ const int s_form_tbl[] = { 0x21e6,0x21e7,0x21e8,0x21e9, // black arrow f87a (4) }; -const int s_form_sjis_tbl[] = { +static const int s_form_sjis_tbl[] = { 0xeb5d,0xeb61,0xeb63, 0xeb41,0xeb42,0xeb60,0xec9f,0xeca1,0xeca3,0xeca5,0xeca7, 0xecc1,0xece1,0xece3,0xece5,0xecec,0xed40,0xed42,0xed44, @@ -203,7 +187,7 @@ const int s_form_sjis_tbl[] = { 0x86d4,0x86d5,0x86d3,0x86d6, // black arrow }; -const int s_form_sjis_fallback_tbl[] = { +static const int s_form_sjis_fallback_tbl[] = { 0x815d,0x8161,0x8163, 0x8141,0x8142,0x8160,0x829f,0x82a1,0x82a3,0x82a5,0x82a7, 0x82c1,0x82e1,0x82e3,0x82e5,0x82ec,0x8340,0x8342,0x8344, @@ -214,7 +198,7 @@ const int s_form_sjis_fallback_tbl[] = { 0x86d0,0x86d1,0x86cf,0x86d2, // arrow }; -const int wchar2sjis_mac_r_tbl[][3] = { +static const int wchar2sjis_mac_r_tbl[][3] = { {0x2160, 0x216b, 0x034e}, {0x2170, 0x217b, 0x0362}, {0x2460, 0x2473, 0x02f0}, @@ -226,7 +210,7 @@ const int wchar2sjis_mac_r_tbl[][3] = { {0x32a4, 0x32a9, 0x04ba}, }; -const int wchar2sjis_mac_r_map[][2] = { +static const unsigned short wchar2sjis_mac_r_map[][2] = { {0x2660, 0x2667}, {0x322a, 0x3243}, {0x3296, 0x329e}, @@ -234,10 +218,10 @@ const int wchar2sjis_mac_r_map[][2] = { {0xfe30, 0xfe44}, }; -const int *wchar2sjis_mac_code_map[] = { +static const int *wchar2sjis_mac_code_map[] = { wchar2sjis_mac4, wchar2sjis_mac7, wchar2sjis_mac8, wchar2sjis_mac9, wchar2sjis_mac10}; -const int wchar2sjis_mac_wchar_tbl[][2] = { +static const int wchar2sjis_mac_wchar_tbl[][2] = { {0x2109, 0x03c2}, {0x2110, 0x21ef5}, {0x2113, 0x03bc}, @@ -580,7 +564,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) } if (s1 <= 0) { - for (i=0; i= wchar2sjis_mac_r_map[i][0] && c <= wchar2sjis_mac_r_map[i][1]) { s1 = wchar2sjis_mac_code_map[i][c-wchar2sjis_mac_r_map[i][0]]; break; @@ -812,7 +796,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) return c; } -int +static int mbfl_filt_conv_sjis_mac_flush(mbfl_convert_filter *filter) { int i, c1, s1 = 0; @@ -839,24 +823,3 @@ mbfl_filt_conv_sjis_mac_flush(mbfl_convert_filter *filter) return 0; } -static int mbfl_filt_ident_sjis_mac(int c, mbfl_identify_filter *filter) -{ - if (filter->status) { /* kanji second char */ - if (c < 0x40 || c > 0xfc || c == 0x7f) { /* bad */ - filter->flag = 1; - } - filter->status = 0; - } else if (c >= 0 && c < 0x80) { /* latin ok */ - ; - } else if (c > 0xa0 && c < 0xe0) { /* kana ok */ - ; - } else if (c > 0x80 && c < 0xfd && c != 0xa0) { /* kanji first char */ - filter->status = 1; - } else { /* bad */ - filter->flag = 1; - } - - return c; -} - - diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h index 3f332d9a6c2f4..3b191aa418074 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.h @@ -40,6 +40,5 @@ extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_mac; int mbfl_filt_conv_sjis_mac_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter); -int mbfl_filt_conv_sjis_mac_flush(mbfl_convert_filter *filter); #endif /* MBFL_MBFILTER_SJIS_MAC_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c index 44e7ca0e9fe0d..6da38db6fae3a 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -41,25 +41,7 @@ #include "emoji2uni.h" extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); - -static const unsigned char mblen_table_sjis[] = { /* 0x80-0x9f,0xE0-0xFF */ - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2 -}; +extern const unsigned char mblen_table_sjis[]; const mbfl_encoding mbfl_encoding_sjis_docomo = { mbfl_no_encoding_sjis_docomo, diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.c index f24210c22f5a0..81ab32edfd530 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.c @@ -139,7 +139,6 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_open = { } \ } while (0) - /* * SJIS-win => wchar */ @@ -308,6 +307,7 @@ mbfl_filt_conv_wchar_sjis_open(int c, mbfl_convert_filter *filter) s1 = -1; } } + if (s1 >= 0) { if (s1 < 0x100) { /* latin or kana */ CK((*filter->output_function)(s1, filter->data)); diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.h index 0bfe1d21ab5e2..f24e42ea22c7c 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_open.h @@ -33,6 +33,7 @@ #include "mbfilter.h" extern const mbfl_encoding mbfl_encoding_sjis_open; + extern const struct mbfl_identify_vtbl vtbl_identify_sjis_open; extern const struct mbfl_convert_vtbl vtbl_sjis_open_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_open; diff --git a/ext/mbstring/libmbfl/filters/unicode_table_cp936.h b/ext/mbstring/libmbfl/filters/unicode_table_cp936.h index f5fece402b409..173c8f4b3f47b 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_cp936.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_cp936.h @@ -6394,51 +6394,62 @@ const int ucs_i_cp936_table_min = 0x4d00; const int ucs_i_cp936_table_max = 0x4d00 + (sizeof (ucs_i_cp936_table) / sizeof (unsigned short)); +/* 0xf900 CJK Compatibility Ideographs (with fallback) */ +static const unsigned short ucs_ci_cp936_table[] = { // 0xf900 - 0xfa2f + +/* F900h */ +0xD84D,0xB8FC,0xDC87,0xD95A,0xBBAC,0xB4AE,0xBEE4,0xFD94, +0xFD94,0xC6F5,0xBDF0,0xC0AE,0xC4CE,0x91D0,0xB05D,0xC15F, +0xCC7D,0xC2DD,0xC2E3,0xDF89,0x98B7,0xC2E5,0xC0D3,0xE7F3, +0xC2E4,0xC0D2,0xF198,0x8179,0xC2D1,0x99DA,0xA080,0xCC6D, +0xFB5B,0x8DB9,0x9E45,0xCB7B,0xD268,0xC0AD,0xC544,0xCF9E, +0xC0C8,0xC0CA,0xC0CB,0xC0C7,0xFD9C,0x81ED,0xC0E4,0x84DA, +0x93EF,0x99A9,0xA074,0xB152,0xC0CF,0xCC4A,0xCC94,0xC2B7, +0xC2B6,0xF494,0xFA98,0xC2B5,0xB593,0xBE47,0xC78A,0xE49B, +0xC2B9,0xD593,0x89C5,0xC5AA,0xBB5C,0xC340,0xC0CE,0xC0DA, +0xD954,0xC0D7,0x89BE,0x8CD2,0x98C7,0x9C49,0xC2A9,0xC0DB, +0xBF7C,0xC2AA,0xC0D5,0xC0DF,0x8443,0xC1E8,0xB6A0,0xBE63, +0xC1E2,0xC1EA,0xD778,0x9282,0x98B7,0xD65A,0xB5A4,0x8C8E, +0xC5AD,0xC2CA,0xAE90,0xB1B1,0xB491,0xB1E3,0x8FCD,0xB2BB, +0xC3DA,0x94B5,0xCBF7,0x85A2,0xC8FB,0xCAA1,0xC87E,0xD566, +0x9AA2,0xB3BD,0xC9F2,0xCAB0,0xC8F4,0xC2D3,0xC2D4,0xC1C1, +0x83C9,0xFD9D,0xC1BA,0xBC5A,0xC1BC,0xD58F,0xC1BF,0x84EE, +0x85CE,0xC5AE,0x8F5D,0xC2C3,0x9E56,0xB55A,0xE982,0xF350, +0xFB90,0xC0E8,0xC1A6,0x95D1,0x9A76,0xDE5D,0xC4EA,0x917A, +0x91D9,0x93D3,0x9D69,0x9F92,0xAD49,0xFD9E,0xBE9A,0xC293, +0xDD82,0xC98F,0xDF42,0xE580,0xC1D0,0xC1D3,0xD1CA,0xC1D2, +0xC1D1,0xD566,0xC1AE,0xC4EE,0xC4ED,0x9A9A,0xBA9F,0xAB43, +0xC1EE,0xE0F2,0x8C8E,0x8E58,0xC1AF,0xC1E1,0xAC93,0xC1E7, +0xF1F6,0xE28F,0xC1E3,0xEC60,0xEE49,0xC0FD,0xB659,0xF5B7, +0xEB60,0x90BA,0xC1CB,0xC1C5,0xE5BC,0xC4F2,0xC1CF,0x98B7, +0xC1C7,0xAF9F,0xDEA4,0xDF7C,0xFD88,0x959E,0xC8EE,0x84A2, +0x9683,0xC1F8,0xC1F7,0xC1EF,0xC1F0,0xC1F4,0xC1F2,0xBC7E, +0xEE90,0xC1F9,0xC2BE,0xEA91,0x8290,0x8D91,0x9C53,0xDD86, +0xC2C9,0x90FC,0xC0F5,0xC2CA,0xC2A1,0xC0FB,0xC0F4,0xC2C4, +0xD2D7,0xC0EE,0xC0E6,0xC4E0,0xC0ED,0xC1A1,0xEEBE,0xFD9F, +0xD165,0xC0EF,0xEB78,0xC4E4,0xC4E7,0xC1DF,0x9FFB,0xAD55, +0xCC41,0xFDA0,0xF75B,0xF7EB,0xC1D6,0xC1DC,0xC552,0xC1A2, +0xF3D2,0xC1A3,0xA0EE,0xD6CB,0xD752,0xCAB2,0xB2E8,0xB4CC, + +/* FA00h */ +0xC7D0,0xB6C8,0xCDD8,0xCCC7,0xD5AC,0xB6B4,0xB1A9,0xDD97, +0xD0D0,0xBDB5,0xD28A,0xC0AA,0xFE40,0xFE41,0xFE42,0xFE43, +0x8956,0xFE44,0xC7E7,0xFE45,0xFE46,0x8444,0xD869,0xD2E6, +0xFE47,0xC9F1,0xCFE9,0xB8A3,0xBEB8,0xBEAB,0xD3F0,0xFE48, +0xFE49,0xFE4A,0xD654,0xFE4B,0xFE4C,0xD2DD,0xB6BC,0xFE4D, +0xFE4E,0xFE4F,0xEF88,0xEF95,0xF05E,0xFA51,0x0000,0x0000, +}; -/* 0xf900 CJK Compatibility Ideographs */ -const unsigned short ucs_ci_cp936_table[] = { -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0xfd9c,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0xfd9d,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0xfd9e,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xfd9f, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0xfda0,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -/* 0xfa00 */ -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0xfe40,0xfe41,0xfe42,0xfe43, -0x0000,0xfe44,0x0000,0xfe45,0xfe46,0x0000,0x0000,0x0000, -0xfe47,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xfe48, -0xfe49,0xfe4a,0x0000,0xfe4b,0xfe4c,0x0000,0x0000,0xfe4d, -0xfe4e,0xfe4f,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000}; const int ucs_ci_cp936_table_min = 0xf900; -const int ucs_ci_cp936_table_max = 0xf900 + (sizeof (ucs_ci_cp936_table) / sizeof (unsigned short)); +const int ucs_ci_cp936_table_max = 0xfa2f; +/* reduced map for GBK: U+FA0C - U+FA29 */ +const unsigned short ucs_ci_s_cp936_table[] = { + 0xfe40,0xfe41,0xfe42,0xfe43, + 0x0000,0xfe44,0x0000,0xfe45,0xfe46,0x0000,0x0000,0x0000, + 0xfe47,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xfe48, + 0xfe49,0xfe4a,0x0000,0xfe4b,0xfe4c,0x0000,0x0000,0xfe4d, + 0xfe4e,0xfe4f}; /* FE30h CJK Compatibility Forms */ const unsigned short ucs_cf_cp936_table[] = { @@ -6462,42 +6473,48 @@ const int ucs_sfv_cp936_table_min = 0xfe50; const int ucs_sfv_cp936_table_max = 0xfe50 + (sizeof (ucs_sfv_cp936_table) / sizeof (unsigned short)); /* FF00h Halfwidth and Fullwidth Forms */ -const unsigned short ucs_hff_cp936_table[] = { -0x0000,0xa3a1,0xa3a2,0xa3a3,0xa1e7,0xa3a5,0xa3a6,0xa3a7, -0xa3a8,0xa3a9,0xa3aa,0xa3ab,0xa3ac,0xa3ad,0xa3ae,0xa3af, -0xa3b0,0xa3b1,0xa3b2,0xa3b3,0xa3b4,0xa3b5,0xa3b6,0xa3b7, -0xa3b8,0xa3b9,0xa3ba,0xa3bb,0xa3bc,0xa3bd,0xa3be,0xa3bf, -0xa3c0,0xa3c1,0xa3c2,0xa3c3,0xa3c4,0xa3c5,0xa3c6,0xa3c7, -0xa3c8,0xa3c9,0xa3ca,0xa3cb,0xa3cc,0xa3cd,0xa3ce,0xa3cf, -0xa3d0,0xa3d1,0xa3d2,0xa3d3,0xa3d4,0xa3d5,0xa3d6,0xa3d7, -0xa3d8,0xa3d9,0xa3da,0xa3db,0xa3dc,0xa3dd,0xa3de,0xa3df, -0xa3e0,0xa3e1,0xa3e2,0xa3e3,0xa3e4,0xa3e5,0xa3e6,0xa3e7, -0xa3e8,0xa3e9,0xa3ea,0xa3eb,0xa3ec,0xa3ed,0xa3ee,0xa3ef, -0xa3f0,0xa3f1,0xa3f2,0xa3f3,0xa3f4,0xa3f5,0xa3f6,0xa3f7, -0xa3f8,0xa3f9,0xa3fa,0xa3fb,0xa3fc,0xa3fd,0xa1ab,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0xa1e9,0xa1ea,0xa956,0xa3fe,0xa957,0xa3a4,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, -0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000 + +/* reduced map: U+FFE0 - U+FFE5 */ +const unsigned short ucs_hff_s_cp936_table[] = { + 0xa1e9,0xa1ea,0xa956,0xa3fe,0xa957,0xa3a4, }; + const int ucs_hff_cp936_table_min = 0xff00; -const int ucs_hff_cp936_table_max = 0xff00 + (sizeof (ucs_hff_cp936_table) / sizeof (unsigned short)); +const int ucs_hff_cp936_table_max = 0xffff; + +/* CP936 local */ + +static const unsigned short mbfl_cp936_pua_tbl[][3] = { + {0xe766, 0xe76b, 0xa2ab}, + {0xe76c, 0xe76d, 0xa2e3}, + {0xe76e, 0xe76f, 0xa2ef}, + {0xe770, 0xe771, 0xa2fd}, + {0xe772, 0xe77c, 0xa4f4}, + {0xe77d, 0xe784, 0xa5f7}, + {0xe785, 0xe78c, 0xa6b9}, + {0xe78d, 0xe793, 0xa6d9}, + {0xe794, 0xe795, 0xa6ec}, + {0xe796, 0xe796, 0xa6f3}, + {0xe797, 0xe79f, 0xa6f6}, + {0xe7a0, 0xe7ae, 0xa7c2}, + {0xe7af, 0xe7bb, 0xa7f2}, + {0xe7bc, 0xe7c6, 0xa896}, + {0xe7c7, 0xe7c7, 0xa8bc}, + {0xe7c8, 0xe7c8, 0xa8bf}, + {0xe7c9, 0xe7cc, 0xa8c1}, + {0xe7cd, 0xe7e1, 0xa8ea}, + {0xe7e2, 0xe7e2, 0xa958}, + {0xe7e3, 0xe7e3, 0xa95b}, + {0xe7e4, 0xe7e6, 0xa95d}, + {0xe7e7, 0xe7f3, 0xa989}, + {0xe7f4, 0xe800, 0xa997}, + {0xe801, 0xe80f, 0xa9f0}, + {0xe810, 0xe814, 0xd7fa}, + {0xe815, 0xe843, 0xfe50}, + {0xe844, 0xe864, 0xfe80}, +}; + +static const int mbfl_cp936_pua_tbl_max = sizeof(mbfl_cp936_pua_tbl)/(sizeof(unsigned short)*3); #else @@ -6506,10 +6523,11 @@ extern const unsigned short ucs_a1_cp936_table[]; extern const unsigned short ucs_a2_cp936_table[]; extern const unsigned short ucs_a3_cp936_table[]; extern const unsigned short ucs_i_cp936_table[]; -extern const unsigned short ucs_ci_cp936_table[]; extern const unsigned short ucs_cf_cp936_table[]; extern const unsigned short ucs_sfv_cp936_table[]; -extern const unsigned short ucs_hff_cp936_table[]; + +extern const unsigned short ucs_ci_s_cp936_table[]; +extern const unsigned short ucs_hff_s_cp936_table[]; extern const int cp936_ucs_table_size; extern const int ucs_a1_cp936_table_min; diff --git a/ext/mbstring/libmbfl/filters/unicode_table_jis.h b/ext/mbstring/libmbfl/filters/unicode_table_jis.h index d0c880a87a48e..9132d4b33c301 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_jis.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_jis.h @@ -5820,7 +5820,7 @@ const unsigned short ucs_r_jis_table[] = { 0x2177,0x2341,0x2342,0x2343,0x2344,0x2345,0x2346,0x2347, 0x2348,0x2349,0x234A,0x234B,0x234C,0x234D,0x234E,0x234F, 0x2350,0x2351,0x2352,0x2353,0x2354,0x2355,0x2356,0x2357, - 0x2358,0x2359,0x235A,0x214E,0x2140,0x214F,0x2130,0x2132, + 0x2358,0x2359,0x235A,0x214E,0x0000,0x214F,0x2130,0x2132, 0x212E,0x2361,0x2362,0x2363,0x2364,0x2365,0x2366,0x2367, 0x2368,0x2369,0x236A,0x236B,0x236C,0x236D,0x236E,0x236F, 0x2370,0x2371,0x2372,0x2373,0x2374,0x2375,0x2376,0x2377, diff --git a/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h b/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h new file mode 100644 index 0000000000000..ddb161e79b51f --- /dev/null +++ b/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h @@ -0,0 +1,5026 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: Rui Hirokawa + */ + +#ifndef UNICODE_TABLE_JIS2004_H +#define UNICODE_TABLE_JIS2004_H + +#ifdef UNICODE_TABLE_JIS2004_DEF + +/* + * Unicode table + */ + +const unsigned short jisx0213_ucs_table[] = { // 0x0000 - 0x2C0F + +/* plane 1 ku 1 */ +0x3000,0x3001,0x3002,0xFF0C,0xFF0E,0x30FB,0xFF1A,0xFF1B, +0xFF1F,0xFF01,0x309B,0x309C,0x00B4,0xFF40,0x00A8,0xFF3E, +0xFFE3,0xFF3F,0x30FD,0x30FE,0x309D,0x309E,0x3003,0x4EDD, +0x3005,0x3006,0x3007,0x30FC,0x2014,0x2010,0xFF0F,0xFF3C, +0x301C,0x2016,0xFF5C,0x2026,0x2025,0x2018,0x2019,0x201C, +0x201D,0xFF08,0xFF09,0x3014,0x3015,0xFF3B,0xFF3D,0xFF5B, +0xFF5D,0x3008,0x3009,0x300A,0x300B,0x300C,0x300D,0x300E, +0x300F,0x3010,0x3011,0xFF0B,0x2212,0x00B1,0x00D7,0x00F7, +0xFF1D,0x2260,0xFF1C,0xFF1E,0x2266,0x2267,0x221E,0x2234, +0x2642,0x2640,0x00B0,0x2032,0x2033,0x2103,0xFFE5,0xFF04, +0x00A2,0x00A3,0xFF05,0xFF03,0xFF06,0xFF0A,0xFF20,0x00A7, +0x2606,0x2605,0x25CB,0x25CF,0x25CE,0x25C7, +/* plane 1 ku 2 */ +0x25C6,0x25A1,0x25A0,0x25B3,0x25B2,0x25BD,0x25BC,0x203B, +0x3012,0x2192,0x2190,0x2191,0x2193,0x3013,0xFF07,0xFF02, +0xFF0D,0xFF5E,0x3033,0x3034,0x3035,0x303B,0x303C,0x30FF, +0x309F,0x2208,0x220B,0x2286,0x2287,0x2282,0x2283,0x222A, +0x2229,0x2284,0x2285,0x228A,0x228B,0x2209,0x2205,0x2305, +0x2306,0x2227,0x2228,0x00AC,0x21D2,0x21D4,0x2200,0x2203, +0x2295,0x2296,0x2297,0x2225,0x2226,0xFF5F,0xFF60,0x3018, +0x3019,0x3016,0x3017,0x2220,0x22A5,0x2312,0x2202,0x2207, +0x2261,0x2252,0x226A,0x226B,0x221A,0x223D,0x221D,0x2235, +0x222B,0x222C,0x2262,0x2243,0x2245,0x2248,0x2276,0x2277, +0x2194,0x212B,0x2030,0x266F,0x266D,0x266A,0x2020,0x2021, +0x00B6,0x266E,0x266B,0x266C,0x2669,0x25EF, +/* plane 1 ku 3 */ +0x25B7,0x25B6,0x25C1,0x25C0,0x2197,0x2198,0x2196,0x2199, +0x21C4,0x21E8,0x21E6,0x21E7,0x21E9,0x2934,0x2935,0xFF10, +0xFF11,0xFF12,0xFF13,0xFF14,0xFF15,0xFF16,0xFF17,0xFF18, +0xFF19,0x29BF,0x25C9,0x303D,0xFE46,0xFE45,0x25E6,0x2022, +0xFF21,0xFF22,0xFF23,0xFF24,0xFF25,0xFF26,0xFF27,0xFF28, +0xFF29,0xFF2A,0xFF2B,0xFF2C,0xFF2D,0xFF2E,0xFF2F,0xFF30, +0xFF31,0xFF32,0xFF33,0xFF34,0xFF35,0xFF36,0xFF37,0xFF38, +0xFF39,0xFF3A,0x2213,0x2135,0x210F,0x33CB,0x2113,0x2127, +0xFF41,0xFF42,0xFF43,0xFF44,0xFF45,0xFF46,0xFF47,0xFF48, +0xFF49,0xFF4A,0xFF4B,0xFF4C,0xFF4D,0xFF4E,0xFF4F,0xFF50, +0xFF51,0xFF52,0xFF53,0xFF54,0xFF55,0xFF56,0xFF57,0xFF58, +0xFF59,0xFF5A,0x30A0,0x2013,0x29FA,0x29FB, +/* plane 1 ku 4 */ +0x3041,0x3042,0x3043,0x3044,0x3045,0x3046,0x3047,0x3048, +0x3049,0x304A,0x304B,0x304C,0x304D,0x304E,0x304F,0x3050, +0x3051,0x3052,0x3053,0x3054,0x3055,0x3056,0x3057,0x3058, +0x3059,0x305A,0x305B,0x305C,0x305D,0x305E,0x305F,0x3060, +0x3061,0x3062,0x3063,0x3064,0x3065,0x3066,0x3067,0x3068, +0x3069,0x306A,0x306B,0x306C,0x306D,0x306E,0x306F,0x3070, +0x3071,0x3072,0x3073,0x3074,0x3075,0x3076,0x3077,0x3078, +0x3079,0x307A,0x307B,0x307C,0x307D,0x307E,0x307F,0x3080, +0x3081,0x3082,0x3083,0x3084,0x3085,0x3086,0x3087,0x3088, +0x3089,0x308A,0x308B,0x308C,0x308D,0x308E,0x308F,0x3090, +0x3091,0x3092,0x3093,0x3094,0x3095,0x3096,0x0000,0x304D, +0x304F,0x3051,0x3053,0x0000,0x0000,0x0000, +/* plane 1 ku 5 */ +0x30A1,0x30A2,0x30A3,0x30A4,0x30A5,0x30A6,0x30A7,0x30A8, +0x30A9,0x30AA,0x30AB,0x30AC,0x30AD,0x30AE,0x30AF,0x30B0, +0x30B1,0x30B2,0x30B3,0x30B4,0x30B5,0x30B6,0x30B7,0x30B8, +0x30B9,0x30BA,0x30BB,0x30BC,0x30BD,0x30BE,0x30BF,0x30C0, +0x30C1,0x30C2,0x30C3,0x30C4,0x30C5,0x30C6,0x30C7,0x30C8, +0x30C9,0x30CA,0x30CB,0x30CC,0x30CD,0x30CE,0x30CF,0x30D0, +0x30D1,0x30D2,0x30D3,0x30D4,0x30D5,0x30D6,0x30D7,0x30D8, +0x30D9,0x30DA,0x30DB,0x30DC,0x30DD,0x30DE,0x30DF,0x30E0, +0x30E1,0x30E2,0x30E3,0x30E4,0x30E5,0x30E6,0x30E7,0x30E8, +0x30E9,0x30EA,0x30EB,0x30EC,0x30ED,0x30EE,0x30EF,0x30F0, +0x30F1,0x30F2,0x30F3,0x30F4,0x30F5,0x30F6,0x30AB,0x30AD, +0x30AF,0x30B1,0x30B3,0x30BB,0x30C4,0x30C8, +/* plane 1 ku 6 */ +0x0391,0x0392,0x0393,0x0394,0x0395,0x0396,0x0397,0x0398, +0x0399,0x039A,0x039B,0x039C,0x039D,0x039E,0x039F,0x03A0, +0x03A1,0x03A3,0x03A4,0x03A5,0x03A6,0x03A7,0x03A8,0x03A9, +0x2664,0x2660,0x2662,0x2666,0x2661,0x2665,0x2667,0x2663, +0x03B1,0x03B2,0x03B3,0x03B4,0x03B5,0x03B6,0x03B7,0x03B8, +0x03B9,0x03BA,0x03BB,0x03BC,0x03BD,0x03BE,0x03BF,0x03C0, +0x03C1,0x03C3,0x03C4,0x03C5,0x03C6,0x03C7,0x03C8,0x03C9, +0x03C2,0x24F5,0x24F6,0x24F7,0x24F8,0x24F9,0x24FA,0x24FB, +0x24FC,0x24FD,0x24FE,0x2616,0x2617,0x3020,0x260E,0x2600, +0x2601,0x2602,0x2603,0x2668,0x25B1,0x31F0,0x31F1,0x31F2, +0x31F3,0x31F4,0x31F5,0x31F6,0x31F7,0x31F8,0x31F9,0x31F7, +0x31FA,0x31FB,0x31FC,0x31FD,0x31FE,0x31FF, +/* plane 1 ku 7 */ +0x0410,0x0411,0x0412,0x0413,0x0414,0x0415,0x0401,0x0416, +0x0417,0x0418,0x0419,0x041A,0x041B,0x041C,0x041D,0x041E, +0x041F,0x0420,0x0421,0x0422,0x0423,0x0424,0x0425,0x0426, +0x0427,0x0428,0x0429,0x042A,0x042B,0x042C,0x042D,0x042E, +0x042F,0x23BE,0x23BF,0x23C0,0x23C1,0x23C2,0x23C3,0x23C4, +0x23C5,0x23C6,0x23C7,0x23C8,0x23C9,0x23CA,0x23CB,0x23CC, +0x0430,0x0431,0x0432,0x0433,0x0434,0x0435,0x0451,0x0436, +0x0437,0x0438,0x0439,0x043A,0x043B,0x043C,0x043D,0x043E, +0x043F,0x0440,0x0441,0x0442,0x0443,0x0444,0x0445,0x0446, +0x0447,0x0448,0x0449,0x044A,0x044B,0x044C,0x044D,0x044E, +0x044F,0x30F7,0x30F8,0x30F9,0x30FA,0x22DA,0x22DB,0x2153, +0x2154,0x2155,0x2713,0x2318,0x2423,0x23CE, +/* plane 1 ku 8 */ +0x2500,0x2502,0x250C,0x2510,0x2518,0x2514,0x251C,0x252C, +0x2524,0x2534,0x253C,0x2501,0x2503,0x250F,0x2513,0x251B, +0x2517,0x2523,0x2533,0x252B,0x253B,0x254B,0x2520,0x252F, +0x2528,0x2537,0x253F,0x251D,0x2530,0x2525,0x2538,0x2542, +0x3251,0x3252,0x3253,0x3254,0x3255,0x3256,0x3257,0x3258, +0x3259,0x325A,0x325B,0x325C,0x325D,0x325E,0x325F,0x32B1, +0x32B2,0x32B3,0x32B4,0x32B5,0x32B6,0x32B7,0x32B8,0x32B9, +0x32BA,0x32BB,0x32BC,0x32BD,0x32BE,0x32BF,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x25D0,0x25D1, +0x25D2,0x25D3,0x203C,0x2047,0x2048,0x2049,0x01CD,0x01CE, +0x01D0,0x1E3E,0x1E3F,0x01F8,0x01F9,0x01D1,0x01D2,0x01D4, +0x01D6,0x01D8,0x01DA,0x01DC,0x0000,0x0000, +/* plane 1 ku 9 */ +0x20AC,0x00A0,0x00A1,0x00A4,0x00A6,0x00A9,0x00AA,0x00AB, +0x00AD,0x00AE,0x00AF,0x00B2,0x00B3,0x00B7,0x00B8,0x00B9, +0x00BA,0x00BB,0x00BC,0x00BD,0x00BE,0x00BF,0x00C0,0x00C1, +0x00C2,0x00C3,0x00C4,0x00C5,0x00C6,0x00C7,0x00C8,0x00C9, +0x00CA,0x00CB,0x00CC,0x00CD,0x00CE,0x00CF,0x00D0,0x00D1, +0x00D2,0x00D3,0x00D4,0x00D5,0x00D6,0x00D8,0x00D9,0x00DA, +0x00DB,0x00DC,0x00DD,0x00DE,0x00DF,0x00E0,0x00E1,0x00E2, +0x00E3,0x00E4,0x00E5,0x00E6,0x00E7,0x00E8,0x00E9,0x00EA, +0x00EB,0x00EC,0x00ED,0x00EE,0x00EF,0x00F0,0x00F1,0x00F2, +0x00F3,0x00F4,0x00F5,0x00F6,0x00F8,0x00F9,0x00FA,0x00FB, +0x00FC,0x00FD,0x00FE,0x00FF,0x0100,0x012A,0x016A,0x0112, +0x014C,0x0101,0x012B,0x016B,0x0113,0x014D, +/* plane 1 ku 10 */ +0x0104,0x02D8,0x0141,0x013D,0x015A,0x0160,0x015E,0x0164, +0x0179,0x017D,0x017B,0x0105,0x02DB,0x0142,0x013E,0x015B, +0x02C7,0x0161,0x015F,0x0165,0x017A,0x02DD,0x017E,0x017C, +0x0154,0x0102,0x0139,0x0106,0x010C,0x0118,0x011A,0x010E, +0x0143,0x0147,0x0150,0x0158,0x016E,0x0170,0x0162,0x0155, +0x0103,0x013A,0x0107,0x010D,0x0119,0x011B,0x010F,0x0111, +0x0144,0x0148,0x0151,0x0159,0x016F,0x0171,0x0163,0x02D9, +0x0108,0x011C,0x0124,0x0134,0x015C,0x016C,0x0109,0x011D, +0x0125,0x0135,0x015D,0x016D,0x0271,0x028B,0x027E,0x0283, +0x0292,0x026C,0x026E,0x0279,0x0288,0x0256,0x0273,0x027D, +0x0282,0x0290,0x027B,0x026D,0x025F,0x0272,0x029D,0x028E, +0x0261,0x014B,0x0270,0x0281,0x0127,0x0295, +/* plane 1 ku 11 */ +0x0294,0x0266,0x0298,0x01C2,0x0253,0x0257,0x0284,0x0260, +0x0193,0x0153,0x0152,0x0268,0x0289,0x0258,0x0275,0x0259, +0x025C,0x025E,0x0250,0x026F,0x028A,0x0264,0x028C,0x0254, +0x0251,0x0252,0x028D,0x0265,0x02A2,0x02A1,0x0255,0x0291, +0x027A,0x0267,0x025A,0x00E6,0x01FD,0x1F70,0x1F71,0x0254, +0x0254,0x028C,0x028C,0x0259,0x0259,0x025A,0x025A,0x1F72, +0x1F73,0x0361,0x02C8,0x02CC,0x02D0,0x02D1,0x0306,0x203F, +0x030B,0x0301,0x0304,0x0300,0x030F,0x030C,0x0302,0x02E5, +0x02E6,0x02E7,0x02E8,0x02E9,0x02E9,0x02E5,0x0325,0x032C, +0x0339,0x031C,0x031F,0x0320,0x0308,0x033D,0x0329,0x032F, +0x02DE,0x0324,0x0330,0x033C,0x0334,0x031D,0x031E,0x0318, +0x0319,0x032A,0x033A,0x033B,0x0303,0x031A, +/* plane 1 ku 12 */ +0x2776,0x2777,0x2778,0x2779,0x277A,0x277B,0x277C,0x277D, +0x277E,0x277F,0x24EB,0x24EC,0x24ED,0x24EE,0x24EF,0x24F0, +0x24F1,0x24F2,0x24F3,0x24F4,0x2170,0x2171,0x2172,0x2173, +0x2174,0x2175,0x2176,0x2177,0x2178,0x2179,0x217A,0x217B, +0x24D0,0x24D1,0x24D2,0x24D3,0x24D4,0x24D5,0x24D6,0x24D7, +0x24D8,0x24D9,0x24DA,0x24DB,0x24DC,0x24DD,0x24DE,0x24DF, +0x24E0,0x24E1,0x24E2,0x24E3,0x24E4,0x24E5,0x24E6,0x24E7, +0x24E8,0x24E9,0x32D0,0x32D1,0x32D2,0x32D3,0x32D4,0x32D5, +0x32D6,0x32D7,0x32D8,0x32D9,0x32DA,0x32DB,0x32DC,0x32DD, +0x32DE,0x32DF,0x32E0,0x32E1,0x32E2,0x32E3,0x32FA,0x32E9, +0x32E5,0x32ED,0x32EC,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x2051,0x2042, +/* plane 1 ku 13 */ +0x2460,0x2461,0x2462,0x2463,0x2464,0x2465,0x2466,0x2467, +0x2468,0x2469,0x246A,0x246B,0x246C,0x246D,0x246E,0x246F, +0x2470,0x2471,0x2472,0x2473,0x2160,0x2161,0x2162,0x2163, +0x2164,0x2165,0x2166,0x2167,0x2168,0x2169,0x216A,0x3349, +0x3314,0x3322,0x334D,0x3318,0x3327,0x3303,0x3336,0x3351, +0x3357,0x330D,0x3326,0x3323,0x332B,0x334A,0x333B,0x339C, +0x339D,0x339E,0x338E,0x338F,0x33C4,0x33A1,0x216B,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x337B,0x301D, +0x301F,0x2116,0x33CD,0x2121,0x32A4,0x32A5,0x32A6,0x32A7, +0x32A8,0x3231,0x3232,0x3239,0x337E,0x337D,0x337C,0x0000, +0x0000,0x0000,0x222E,0x0000,0x0000,0x0000,0x0000,0x221F, +0x22BF,0x0000,0x0000,0x0000,0x2756,0x261E, +/* plane 1 ku 14 */ +0x4FF1,0x0000,0x3402,0x4E28,0x4E2F,0x4E30,0x4E8D,0x4EE1, +0x4EFD,0x4EFF,0x4F03,0x4F0B,0x4F60,0x4F48,0x4F49,0x4F56, +0x4F5F,0x4F6A,0x4F6C,0x4F7E,0x4F8A,0x4F94,0x4F97,0xFA30, +0x4FC9,0x4FE0,0x5001,0x5002,0x500E,0x5018,0x5027,0x502E, +0x5040,0x503B,0x5041,0x5094,0x50CC,0x50F2,0x50D0,0x50E6, +0xFA31,0x5106,0x5103,0x510B,0x511E,0x5135,0x514A,0xFA32, +0x5155,0x5157,0x34B5,0x519D,0x51C3,0x51CA,0x51DE,0x51E2, +0x51EE,0x5201,0x34DB,0x5213,0x5215,0x5249,0x5257,0x5261, +0x5293,0x52C8,0xFA33,0x52CC,0x52D0,0x52D6,0x52DB,0xFA34, +0x52F0,0x52FB,0x5300,0x5307,0x531C,0xFA35,0x5361,0x5363, +0x537D,0x5393,0x539D,0x53B2,0x5412,0x5427,0x544D,0x549C, +0x546B,0x5474,0x547F,0x5488,0x5496,0x54A1, +/* plane 1 ku 15 */ +0x54A9,0x54C6,0x54FF,0x550E,0x552B,0x5535,0x5550,0x555E, +0x5581,0x5586,0x558E,0xFA36,0x55AD,0x55CE,0xFA37,0x5608, +0x560E,0x563B,0x5649,0x5676,0x5666,0xFA38,0x566F,0x5671, +0x5672,0x5699,0x569E,0x56A9,0x56AC,0x56B3,0x56C9,0x56CA, +0x570A,0x0000,0x5721,0x572F,0x5733,0x5734,0x5770,0x5777, +0x577C,0x579C,0xFA0F,0x0000,0x57B8,0x57C7,0x57C8,0x57CF, +0x57E4,0x57ED,0x57F5,0x57F6,0x57FF,0x5809,0xFA10,0x5861, +0x5864,0xFA39,0x587C,0x5889,0x589E,0xFA3A,0x58A9,0x0000, +0x58D2,0x58CE,0x58D4,0x58DA,0x58E0,0x58E9,0x590C,0x8641, +0x595D,0x596D,0x598B,0x5992,0x59A4,0x59C3,0x59D2,0x59DD, +0x5A13,0x5A23,0x5A67,0x5A6D,0x5A77,0x5A7E,0x5A84,0x5A9E, +0x5AA7,0x5AC4,0x0000,0x5B19,0x5B25,0x525D, +/* plane 1 ku 16 */ +0x4E9C,0x5516,0x5A03,0x963F,0x54C0,0x611B,0x6328,0x59F6, +0x9022,0x8475,0x831C,0x7A50,0x60AA,0x63E1,0x6E25,0x65ED, +0x8466,0x82A6,0x9BF5,0x6893,0x5727,0x65A1,0x6271,0x5B9B, +0x59D0,0x867B,0x98F4,0x7D62,0x7DBE,0x9B8E,0x6216,0x7C9F, +0x88B7,0x5B89,0x5EB5,0x6309,0x6697,0x6848,0x95C7,0x978D, +0x674F,0x4EE5,0x4F0A,0x4F4D,0x4F9D,0x5049,0x56F2,0x5937, +0x59D4,0x5A01,0x5C09,0x60DF,0x610F,0x6170,0x6613,0x6905, +0x70BA,0x754F,0x7570,0x79FB,0x7DAD,0x7DEF,0x80C3,0x840E, +0x8863,0x8B02,0x9055,0x907A,0x533B,0x4E95,0x4EA5,0x57DF, +0x80B2,0x90C1,0x78EF,0x4E00,0x58F1,0x6EA2,0x9038,0x7A32, +0x8328,0x828B,0x9C2F,0x5141,0x5370,0x54BD,0x54E1,0x56E0, +0x59FB,0x5F15,0x98F2,0x6DEB,0x80E4,0x852D, +/* plane 1 ku 17 */ +0x9662,0x9670,0x96A0,0x97FB,0x540B,0x53F3,0x5B87,0x70CF, +0x7FBD,0x8FC2,0x96E8,0x536F,0x9D5C,0x7ABA,0x4E11,0x7893, +0x81FC,0x6E26,0x5618,0x5504,0x6B1D,0x851A,0x9C3B,0x59E5, +0x53A9,0x6D66,0x74DC,0x958F,0x5642,0x4E91,0x904B,0x96F2, +0x834F,0x990C,0x53E1,0x55B6,0x5B30,0x5F71,0x6620,0x66F3, +0x6804,0x6C38,0x6CF3,0x6D29,0x745B,0x76C8,0x7A4E,0x9834, +0x82F1,0x885B,0x8A60,0x92ED,0x6DB2,0x75AB,0x76CA,0x99C5, +0x60A6,0x8B01,0x8D8A,0x95B2,0x698E,0x53AD,0x5186,0x5712, +0x5830,0x5944,0x5BB4,0x5EF6,0x6028,0x63A9,0x63F4,0x6CBF, +0x6F14,0x708E,0x7114,0x7159,0x71D5,0x733F,0x7E01,0x8276, +0x82D1,0x8597,0x9060,0x925B,0x9D1B,0x5869,0x65BC,0x6C5A, +0x7525,0x51F9,0x592E,0x5965,0x5F80,0x5FDC, +/* plane 1 ku 18 */ +0x62BC,0x65FA,0x6A2A,0x6B27,0x6BB4,0x738B,0x7FC1,0x8956, +0x9D2C,0x9D0E,0x9EC4,0x5CA1,0x6C96,0x837B,0x5104,0x5C4B, +0x61B6,0x81C6,0x6876,0x7261,0x4E59,0x4FFA,0x5378,0x6069, +0x6E29,0x7A4F,0x97F3,0x4E0B,0x5316,0x4EEE,0x4F55,0x4F3D, +0x4FA1,0x4F73,0x52A0,0x53EF,0x5609,0x590F,0x5AC1,0x5BB6, +0x5BE1,0x79D1,0x6687,0x679C,0x67B6,0x6B4C,0x6CB3,0x706B, +0x73C2,0x798D,0x79BE,0x7A3C,0x7B87,0x82B1,0x82DB,0x8304, +0x8377,0x83EF,0x83D3,0x8766,0x8AB2,0x5629,0x8CA8,0x8FE6, +0x904E,0x971E,0x868A,0x4FC4,0x5CE8,0x6211,0x7259,0x753B, +0x81E5,0x82BD,0x86FE,0x8CC0,0x96C5,0x9913,0x99D5,0x4ECB, +0x4F1A,0x89E3,0x56DE,0x584A,0x58CA,0x5EFB,0x5FEB,0x602A, +0x6094,0x6062,0x61D0,0x6212,0x62D0,0x6539, +/* plane 1 ku 19 */ +0x9B41,0x6666,0x68B0,0x6D77,0x7070,0x754C,0x7686,0x7D75, +0x82A5,0x87F9,0x958B,0x968E,0x8C9D,0x51F1,0x52BE,0x5916, +0x54B3,0x5BB3,0x5D16,0x6168,0x6982,0x6DAF,0x788D,0x84CB, +0x8857,0x8A72,0x93A7,0x9AB8,0x6D6C,0x99A8,0x86D9,0x57A3, +0x67FF,0x86CE,0x920E,0x5283,0x5687,0x5404,0x5ED3,0x62E1, +0x64B9,0x683C,0x6838,0x6BBB,0x7372,0x78BA,0x7A6B,0x899A, +0x89D2,0x8D6B,0x8F03,0x90ED,0x95A3,0x9694,0x9769,0x5B66, +0x5CB3,0x697D,0x984D,0x984E,0x639B,0x7B20,0x6A2B,0x6A7F, +0x68B6,0x9C0D,0x6F5F,0x5272,0x559D,0x6070,0x62EC,0x6D3B, +0x6E07,0x6ED1,0x845B,0x8910,0x8F44,0x4E14,0x9C39,0x53F6, +0x691B,0x6A3A,0x9784,0x682A,0x515C,0x7AC3,0x84B2,0x91DC, +0x938C,0x565B,0x9D28,0x6822,0x8305,0x8431, +/* plane 1 ku 20 */ +0x7CA5,0x5208,0x82C5,0x74E6,0x4E7E,0x4F83,0x51A0,0x5BD2, +0x520A,0x52D8,0x52E7,0x5DFB,0x559A,0x582A,0x59E6,0x5B8C, +0x5B98,0x5BDB,0x5E72,0x5E79,0x60A3,0x611F,0x6163,0x61BE, +0x63DB,0x6562,0x67D1,0x6853,0x68FA,0x6B3E,0x6B53,0x6C57, +0x6F22,0x6F97,0x6F45,0x74B0,0x7518,0x76E3,0x770B,0x7AFF, +0x7BA1,0x7C21,0x7DE9,0x7F36,0x7FF0,0x809D,0x8266,0x839E, +0x89B3,0x8ACC,0x8CAB,0x9084,0x9451,0x9593,0x9591,0x95A2, +0x9665,0x97D3,0x9928,0x8218,0x4E38,0x542B,0x5CB8,0x5DCC, +0x73A9,0x764C,0x773C,0x5CA9,0x7FEB,0x8D0B,0x96C1,0x9811, +0x9854,0x9858,0x4F01,0x4F0E,0x5371,0x559C,0x5668,0x57FA, +0x5947,0x5B09,0x5BC4,0x5C90,0x5E0C,0x5E7E,0x5FCC,0x63EE, +0x673A,0x65D7,0x65E2,0x671F,0x68CB,0x68C4, +/* plane 1 ku 21 */ +0x6A5F,0x5E30,0x6BC5,0x6C17,0x6C7D,0x757F,0x7948,0x5B63, +0x7A00,0x7D00,0x5FBD,0x898F,0x8A18,0x8CB4,0x8D77,0x8ECC, +0x8F1D,0x98E2,0x9A0E,0x9B3C,0x4E80,0x507D,0x5100,0x5993, +0x5B9C,0x622F,0x6280,0x64EC,0x6B3A,0x72A0,0x7591,0x7947, +0x7FA9,0x87FB,0x8ABC,0x8B70,0x63AC,0x83CA,0x97A0,0x5409, +0x5403,0x55AB,0x6854,0x6A58,0x8A70,0x7827,0x6775,0x9ECD, +0x5374,0x5BA2,0x811A,0x8650,0x9006,0x4E18,0x4E45,0x4EC7, +0x4F11,0x53CA,0x5438,0x5BAE,0x5F13,0x6025,0x6551,0x673D, +0x6C42,0x6C72,0x6CE3,0x7078,0x7403,0x7A76,0x7AAE,0x7B08, +0x7D1A,0x7CFE,0x7D66,0x65E7,0x725B,0x53BB,0x5C45,0x5DE8, +0x62D2,0x62E0,0x6319,0x6E20,0x865A,0x8A31,0x8DDD,0x92F8, +0x6F01,0x79A6,0x9B5A,0x4EA8,0x4EAB,0x4EAC, +/* plane 1 ku 22 */ +0x4F9B,0x4FA0,0x50D1,0x5147,0x7AF6,0x5171,0x51F6,0x5354, +0x5321,0x537F,0x53EB,0x55AC,0x5883,0x5CE1,0x5F37,0x5F4A, +0x602F,0x6050,0x606D,0x631F,0x6559,0x6A4B,0x6CC1,0x72C2, +0x72ED,0x77EF,0x80F8,0x8105,0x8208,0x854E,0x90F7,0x93E1, +0x97FF,0x9957,0x9A5A,0x4EF0,0x51DD,0x5C2D,0x6681,0x696D, +0x5C40,0x66F2,0x6975,0x7389,0x6850,0x7C81,0x50C5,0x52E4, +0x5747,0x5DFE,0x9326,0x65A4,0x6B23,0x6B3D,0x7434,0x7981, +0x79BD,0x7B4B,0x7DCA,0x82B9,0x83CC,0x887F,0x895F,0x8B39, +0x8FD1,0x91D1,0x541F,0x9280,0x4E5D,0x5036,0x53E5,0x533A, +0x72D7,0x7396,0x77E9,0x82E6,0x8EAF,0x99C6,0x99C8,0x99D2, +0x5177,0x611A,0x865E,0x55B0,0x7A7A,0x5076,0x5BD3,0x9047, +0x9685,0x4E32,0x6ADB,0x91E7,0x5C51,0x5C48, +/* plane 1 ku 23 */ +0x6398,0x7A9F,0x6C93,0x9774,0x8F61,0x7AAA,0x718A,0x9688, +0x7C82,0x6817,0x7E70,0x6851,0x936C,0x52F2,0x541B,0x85AB, +0x8A13,0x7FA4,0x8ECD,0x90E1,0x5366,0x8888,0x7941,0x4FC2, +0x50BE,0x5211,0x5144,0x5553,0x572D,0x73EA,0x578B,0x5951, +0x5F62,0x5F84,0x6075,0x6176,0x6167,0x61A9,0x63B2,0x643A, +0x656C,0x666F,0x6842,0x6E13,0x7566,0x7A3D,0x7CFB,0x7D4C, +0x7D99,0x7E4B,0x7F6B,0x830E,0x834A,0x86CD,0x8A08,0x8A63, +0x8B66,0x8EFD,0x981A,0x9D8F,0x82B8,0x8FCE,0x9BE8,0x5287, +0x621F,0x6483,0x6FC0,0x9699,0x6841,0x5091,0x6B20,0x6C7A, +0x6F54,0x7A74,0x7D50,0x8840,0x8A23,0x6708,0x4EF6,0x5039, +0x5026,0x5065,0x517C,0x5238,0x5263,0x55A7,0x570F,0x5805, +0x5ACC,0x5EFA,0x61B2,0x61F8,0x62F3,0x6372, +/* plane 1 ku 24 */ +0x691C,0x6A29,0x727D,0x72AC,0x732E,0x7814,0x786F,0x7D79, +0x770C,0x80A9,0x898B,0x8B19,0x8CE2,0x8ED2,0x9063,0x9375, +0x967A,0x9855,0x9A13,0x9E78,0x5143,0x539F,0x53B3,0x5E7B, +0x5F26,0x6E1B,0x6E90,0x7384,0x73FE,0x7D43,0x8237,0x8A00, +0x8AFA,0x9650,0x4E4E,0x500B,0x53E4,0x547C,0x56FA,0x59D1, +0x5B64,0x5DF1,0x5EAB,0x5F27,0x6238,0x6545,0x67AF,0x6E56, +0x72D0,0x7CCA,0x88B4,0x80A1,0x80E1,0x83F0,0x864E,0x8A87, +0x8DE8,0x9237,0x96C7,0x9867,0x9F13,0x4E94,0x4E92,0x4F0D, +0x5348,0x5449,0x543E,0x5A2F,0x5F8C,0x5FA1,0x609F,0x68A7, +0x6A8E,0x745A,0x7881,0x8A9E,0x8AA4,0x8B77,0x9190,0x4E5E, +0x9BC9,0x4EA4,0x4F7C,0x4FAF,0x5019,0x5016,0x5149,0x516C, +0x529F,0x52B9,0x52FE,0x539A,0x53E3,0x5411, +/* plane 1 ku 25 */ +0x540E,0x5589,0x5751,0x57A2,0x597D,0x5B54,0x5B5D,0x5B8F, +0x5DE5,0x5DE7,0x5DF7,0x5E78,0x5E83,0x5E9A,0x5EB7,0x5F18, +0x6052,0x614C,0x6297,0x62D8,0x63A7,0x653B,0x6602,0x6643, +0x66F4,0x676D,0x6821,0x6897,0x69CB,0x6C5F,0x6D2A,0x6D69, +0x6E2F,0x6E9D,0x7532,0x7687,0x786C,0x7A3F,0x7CE0,0x7D05, +0x7D18,0x7D5E,0x7DB1,0x8015,0x8003,0x80AF,0x80B1,0x8154, +0x818F,0x822A,0x8352,0x884C,0x8861,0x8B1B,0x8CA2,0x8CFC, +0x90CA,0x9175,0x9271,0x783F,0x92FC,0x95A4,0x964D,0x9805, +0x9999,0x9AD8,0x9D3B,0x525B,0x52AB,0x53F7,0x5408,0x58D5, +0x62F7,0x6FE0,0x8C6A,0x8F5F,0x9EB9,0x514B,0x523B,0x544A, +0x56FD,0x7A40,0x9177,0x9D60,0x9ED2,0x7344,0x6F09,0x8170, +0x7511,0x5FFD,0x60DA,0x9AA8,0x72DB,0x8FBC, +/* plane 1 ku 26 */ +0x6B64,0x9803,0x4ECA,0x56F0,0x5764,0x58BE,0x5A5A,0x6068, +0x61C7,0x660F,0x6606,0x6839,0x68B1,0x6DF7,0x75D5,0x7D3A, +0x826E,0x9B42,0x4E9B,0x4F50,0x53C9,0x5506,0x5D6F,0x5DE6, +0x5DEE,0x67FB,0x6C99,0x7473,0x7802,0x8A50,0x9396,0x88DF, +0x5750,0x5EA7,0x632B,0x50B5,0x50AC,0x518D,0x6700,0x54C9, +0x585E,0x59BB,0x5BB0,0x5F69,0x624D,0x63A1,0x683D,0x6B73, +0x6E08,0x707D,0x91C7,0x7280,0x7815,0x7826,0x796D,0x658E, +0x7D30,0x83DC,0x88C1,0x8F09,0x969B,0x5264,0x5728,0x6750, +0x7F6A,0x8CA1,0x51B4,0x5742,0x962A,0x583A,0x698A,0x80B4, +0x54B2,0x5D0E,0x57FC,0x7895,0x9DFA,0x4F5C,0x524A,0x548B, +0x643E,0x6628,0x6714,0x67F5,0x7A84,0x7B56,0x7D22,0x932F, +0x685C,0x9BAD,0x7B39,0x5319,0x518A,0x5237, +/* plane 1 ku 27 */ +0x5BDF,0x62F6,0x64AE,0x64E6,0x672D,0x6BBA,0x85A9,0x96D1, +0x7690,0x9BD6,0x634C,0x9306,0x9BAB,0x76BF,0x6652,0x4E09, +0x5098,0x53C2,0x5C71,0x60E8,0x6492,0x6563,0x685F,0x71E6, +0x73CA,0x7523,0x7B97,0x7E82,0x8695,0x8B83,0x8CDB,0x9178, +0x9910,0x65AC,0x66AB,0x6B8B,0x4ED5,0x4ED4,0x4F3A,0x4F7F, +0x523A,0x53F8,0x53F2,0x55E3,0x56DB,0x58EB,0x59CB,0x59C9, +0x59FF,0x5B50,0x5C4D,0x5E02,0x5E2B,0x5FD7,0x601D,0x6307, +0x652F,0x5B5C,0x65AF,0x65BD,0x65E8,0x679D,0x6B62,0x6B7B, +0x6C0F,0x7345,0x7949,0x79C1,0x7CF8,0x7D19,0x7D2B,0x80A2, +0x8102,0x81F3,0x8996,0x8A5E,0x8A69,0x8A66,0x8A8C,0x8AEE, +0x8CC7,0x8CDC,0x96CC,0x98FC,0x6B6F,0x4E8B,0x4F3C,0x4F8D, +0x5150,0x5B57,0x5BFA,0x6148,0x6301,0x6642, +/* plane 1 ku 28 */ +0x6B21,0x6ECB,0x6CBB,0x723E,0x74BD,0x75D4,0x78C1,0x793A, +0x800C,0x8033,0x81EA,0x8494,0x8F9E,0x6C50,0x9E7F,0x5F0F, +0x8B58,0x9D2B,0x7AFA,0x8EF8,0x5B8D,0x96EB,0x4E03,0x53F1, +0x57F7,0x5931,0x5AC9,0x5BA4,0x6089,0x6E7F,0x6F06,0x75BE, +0x8CEA,0x5B9F,0x8500,0x7BE0,0x5072,0x67F4,0x829D,0x5C61, +0x854A,0x7E1E,0x820E,0x5199,0x5C04,0x6368,0x8D66,0x659C, +0x716E,0x793E,0x7D17,0x8005,0x8B1D,0x8ECA,0x906E,0x86C7, +0x90AA,0x501F,0x52FA,0x5C3A,0x6753,0x707C,0x7235,0x914C, +0x91C8,0x932B,0x82E5,0x5BC2,0x5F31,0x60F9,0x4E3B,0x53D6, +0x5B88,0x624B,0x6731,0x6B8A,0x72E9,0x73E0,0x7A2E,0x816B, +0x8DA3,0x9152,0x9996,0x5112,0x53D7,0x546A,0x5BFF,0x6388, +0x6A39,0x7DAC,0x9700,0x56DA,0x53CE,0x5468, +/* plane 1 ku 29 */ +0x5B97,0x5C31,0x5DDE,0x4FEE,0x6101,0x62FE,0x6D32,0x79C0, +0x79CB,0x7D42,0x7E4D,0x7FD2,0x81ED,0x821F,0x8490,0x8846, +0x8972,0x8B90,0x8E74,0x8F2F,0x9031,0x914B,0x916C,0x96C6, +0x919C,0x4EC0,0x4F4F,0x5145,0x5341,0x5F93,0x620E,0x67D4, +0x6C41,0x6E0B,0x7363,0x7E26,0x91CD,0x9283,0x53D4,0x5919, +0x5BBF,0x6DD1,0x795D,0x7E2E,0x7C9B,0x587E,0x719F,0x51FA, +0x8853,0x8FF0,0x4FCA,0x5CFB,0x6625,0x77AC,0x7AE3,0x821C, +0x99FF,0x51C6,0x5FAA,0x65EC,0x696F,0x6B89,0x6DF3,0x6E96, +0x6F64,0x76FE,0x7D14,0x5DE1,0x9075,0x9187,0x9806,0x51E6, +0x521D,0x6240,0x6691,0x66D9,0x6E1A,0x5EB6,0x7DD2,0x7F72, +0x66F8,0x85AF,0x85F7,0x8AF8,0x52A9,0x53D9,0x5973,0x5E8F, +0x5F90,0x6055,0x92E4,0x9664,0x50B7,0x511F, +/* ku 30 */ +0x52DD,0x5320,0x5347,0x53EC,0x54E8,0x5546,0x5531,0x5617, +0x5968,0x59BE,0x5A3C,0x5BB5,0x5C06,0x5C0F,0x5C11,0x5C1A, +0x5E84,0x5E8A,0x5EE0,0x5F70,0x627F,0x6284,0x62DB,0x638C, +0x6377,0x6607,0x660C,0x662D,0x6676,0x677E,0x68A2,0x6A1F, +0x6A35,0x6CBC,0x6D88,0x6E09,0x6E58,0x713C,0x7126,0x7167, +0x75C7,0x7701,0x785D,0x7901,0x7965,0x79F0,0x7AE0,0x7B11, +0x7CA7,0x7D39,0x8096,0x83D6,0x848B,0x8549,0x885D,0x88F3, +0x8A1F,0x8A3C,0x8A54,0x8A73,0x8C61,0x8CDE,0x91A4,0x9266, +0x937E,0x9418,0x969C,0x9798,0x4E0A,0x4E08,0x4E1E,0x4E57, +0x5197,0x5270,0x57CE,0x5834,0x58CC,0x5B22,0x5E38,0x60C5, +0x64FE,0x6761,0x6756,0x6D44,0x72B6,0x7573,0x7A63,0x84B8, +0x8B72,0x91B8,0x9320,0x5631,0x57F4,0x98FE, +/* ku 31 */ +0x62ED,0x690D,0x6B96,0x71ED,0x7E54,0x8077,0x8272,0x89E6, +0x98DF,0x8755,0x8FB1,0x5C3B,0x4F38,0x4FE1,0x4FB5,0x5507, +0x5A20,0x5BDD,0x5BE9,0x5FC3,0x614E,0x632F,0x65B0,0x664B, +0x68EE,0x699B,0x6D78,0x6DF1,0x7533,0x75B9,0x771F,0x795E, +0x79E6,0x7D33,0x81E3,0x82AF,0x85AA,0x89AA,0x8A3A,0x8EAB, +0x8F9B,0x9032,0x91DD,0x9707,0x4EBA,0x4EC1,0x5203,0x5875, +0x58EC,0x5C0B,0x751A,0x5C3D,0x814E,0x8A0A,0x8FC5,0x9663, +0x976D,0x7B25,0x8ACF,0x9808,0x9162,0x56F3,0x53A8,0x9017, +0x5439,0x5782,0x5E25,0x63A8,0x6C34,0x708A,0x7761,0x7C8B, +0x7FE0,0x8870,0x9042,0x9154,0x9310,0x9318,0x968F,0x745E, +0x9AC4,0x5D07,0x5D69,0x6570,0x67A2,0x8DA8,0x96DB,0x636E, +0x6749,0x6919,0x83C5,0x9817,0x96C0,0x88FE, +/* plane 1 ku 32 */ +0x6F84,0x647A,0x5BF8,0x4E16,0x702C,0x755D,0x662F,0x51C4, +0x5236,0x52E2,0x59D3,0x5F81,0x6027,0x6210,0x653F,0x6574, +0x661F,0x6674,0x68F2,0x6816,0x6B63,0x6E05,0x7272,0x751F, +0x76DB,0x7CBE,0x8056,0x58F0,0x88FD,0x897F,0x8AA0,0x8A93, +0x8ACB,0x901D,0x9192,0x9752,0x9759,0x6589,0x7A0E,0x8106, +0x96BB,0x5E2D,0x60DC,0x621A,0x65A5,0x6614,0x6790,0x77F3, +0x7A4D,0x7C4D,0x7E3E,0x810A,0x8CAC,0x8D64,0x8DE1,0x8E5F, +0x78A9,0x5207,0x62D9,0x63A5,0x6442,0x6298,0x8A2D,0x7A83, +0x7BC0,0x8AAC,0x96EA,0x7D76,0x820C,0x8749,0x4ED9,0x5148, +0x5343,0x5360,0x5BA3,0x5C02,0x5C16,0x5DDD,0x6226,0x6247, +0x64B0,0x6813,0x6834,0x6CC9,0x6D45,0x6D17,0x67D3,0x6F5C, +0x714E,0x717D,0x65CB,0x7A7F,0x7BAD,0x7DDA, +/* plane 1 ku 33 */ +0x7E4A,0x7FA8,0x817A,0x821B,0x8239,0x85A6,0x8A6E,0x8CCE, +0x8DF5,0x9078,0x9077,0x92AD,0x9291,0x9583,0x9BAE,0x524D, +0x5584,0x6F38,0x7136,0x5168,0x7985,0x7E55,0x81B3,0x7CCE, +0x564C,0x5851,0x5CA8,0x63AA,0x66FE,0x66FD,0x695A,0x72D9, +0x758F,0x758E,0x790E,0x7956,0x79DF,0x7C97,0x7D20,0x7D44, +0x8607,0x8A34,0x963B,0x9061,0x9F20,0x50E7,0x5275,0x53CC, +0x53E2,0x5009,0x55AA,0x58EE,0x594F,0x723D,0x5B8B,0x5C64, +0x531D,0x60E3,0x60F3,0x635C,0x6383,0x633F,0x63BB,0x64CD, +0x65E9,0x66F9,0x5DE3,0x69CD,0x69FD,0x6F15,0x71E5,0x4E89, +0x75E9,0x76F8,0x7A93,0x7CDF,0x7DCF,0x7D9C,0x8061,0x8349, +0x8358,0x846C,0x84BC,0x85FB,0x88C5,0x8D70,0x9001,0x906D, +0x9397,0x971C,0x9A12,0x50CF,0x5897,0x618E, +/* plane 1 ku 34 */ +0x81D3,0x8535,0x8D08,0x9020,0x4FC3,0x5074,0x5247,0x5373, +0x606F,0x6349,0x675F,0x6E2C,0x8DB3,0x901F,0x4FD7,0x5C5E, +0x8CCA,0x65CF,0x7D9A,0x5352,0x8896,0x5176,0x63C3,0x5B58, +0x5B6B,0x5C0A,0x640D,0x6751,0x905C,0x4ED6,0x591A,0x592A, +0x6C70,0x8A51,0x553E,0x5815,0x59A5,0x60F0,0x6253,0x67C1, +0x8235,0x6955,0x9640,0x99C4,0x9A28,0x4F53,0x5806,0x5BFE, +0x8010,0x5CB1,0x5E2F,0x5F85,0x6020,0x614B,0x6234,0x66FF, +0x6CF0,0x6EDE,0x80CE,0x817F,0x82D4,0x888B,0x8CB8,0x9000, +0x902E,0x968A,0x9EDB,0x9BDB,0x4EE3,0x53F0,0x5927,0x7B2C, +0x918D,0x984C,0x9DF9,0x6EDD,0x7027,0x5353,0x5544,0x5B85, +0x6258,0x629E,0x62D3,0x6CA2,0x6FEF,0x7422,0x8A17,0x9438, +0x6FC1,0x8AFE,0x8338,0x51E7,0x86F8,0x53EA, +/* plane 1 ku 35 */ +0x53E9,0x4F46,0x9054,0x8FB0,0x596A,0x8131,0x5DFD,0x7AEA, +0x8FBF,0x68DA,0x8C37,0x72F8,0x9C48,0x6A3D,0x8AB0,0x4E39, +0x5358,0x5606,0x5766,0x62C5,0x63A2,0x65E6,0x6B4E,0x6DE1, +0x6E5B,0x70AD,0x77ED,0x7AEF,0x7BAA,0x7DBB,0x803D,0x80C6, +0x86CB,0x8A95,0x935B,0x56E3,0x58C7,0x5F3E,0x65AD,0x6696, +0x6A80,0x6BB5,0x7537,0x8AC7,0x5024,0x77E5,0x5730,0x5F1B, +0x6065,0x667A,0x6C60,0x75F4,0x7A1A,0x7F6E,0x81F4,0x8718, +0x9045,0x99B3,0x7BC9,0x755C,0x7AF9,0x7B51,0x84C4,0x9010, +0x79E9,0x7A92,0x8336,0x5AE1,0x7740,0x4E2D,0x4EF2,0x5B99, +0x5FE0,0x62BD,0x663C,0x67F1,0x6CE8,0x866B,0x8877,0x8A3B, +0x914E,0x92F3,0x99D0,0x6A17,0x7026,0x732A,0x82E7,0x8457, +0x8CAF,0x4E01,0x5146,0x51CB,0x558B,0x5BF5, +/* plane 1 ku 36 */ +0x5E16,0x5E33,0x5E81,0x5F14,0x5F35,0x5F6B,0x5FB4,0x61F2, +0x6311,0x66A2,0x671D,0x6F6E,0x7252,0x753A,0x773A,0x8074, +0x8139,0x8178,0x8776,0x8ABF,0x8ADC,0x8D85,0x8DF3,0x929A, +0x9577,0x9802,0x9CE5,0x52C5,0x6357,0x76F4,0x6715,0x6C88, +0x73CD,0x8CC3,0x93AE,0x9673,0x6D25,0x589C,0x690E,0x69CC, +0x8FFD,0x939A,0x75DB,0x901A,0x585A,0x6802,0x63B4,0x69FB, +0x4F43,0x6F2C,0x67D8,0x8FBB,0x8526,0x7DB4,0x9354,0x693F, +0x6F70,0x576A,0x58F7,0x5B2C,0x7D2C,0x722A,0x540A,0x91E3, +0x9DB4,0x4EAD,0x4F4E,0x505C,0x5075,0x5243,0x8C9E,0x5448, +0x5824,0x5B9A,0x5E1D,0x5E95,0x5EAD,0x5EF7,0x5F1F,0x608C, +0x62B5,0x633A,0x63D0,0x68AF,0x6C40,0x7887,0x798E,0x7A0B, +0x7DE0,0x8247,0x8A02,0x8AE6,0x8E44,0x9013, +/* plane 1 ku 37 */ +0x90B8,0x912D,0x91D8,0x9F0E,0x6CE5,0x6458,0x64E2,0x6575, +0x6EF4,0x7684,0x7B1B,0x9069,0x93D1,0x6EBA,0x54F2,0x5FB9, +0x64A4,0x8F4D,0x8FED,0x9244,0x5178,0x586B,0x5929,0x5C55, +0x5E97,0x6DFB,0x7E8F,0x751C,0x8CBC,0x8EE2,0x985B,0x70B9, +0x4F1D,0x6BBF,0x6FB1,0x7530,0x96FB,0x514E,0x5410,0x5835, +0x5857,0x59AC,0x5C60,0x5F92,0x6597,0x675C,0x6E21,0x767B, +0x83DF,0x8CED,0x9014,0x90FD,0x934D,0x7825,0x783A,0x52AA, +0x5EA6,0x571F,0x5974,0x6012,0x5012,0x515A,0x51AC,0x51CD, +0x5200,0x5510,0x5854,0x5858,0x5957,0x5B95,0x5CF6,0x5D8B, +0x60BC,0x6295,0x642D,0x6771,0x6843,0x68BC,0x68DF,0x76D7, +0x6DD8,0x6E6F,0x6D9B,0x706F,0x71C8,0x5F53,0x75D8,0x7977, +0x7B49,0x7B54,0x7B52,0x7CD6,0x7D71,0x5230, +/* plane 1 ku 38 */ +0x8463,0x8569,0x85E4,0x8A0E,0x8B04,0x8C46,0x8E0F,0x9003, +0x900F,0x9419,0x9676,0x982D,0x9A30,0x95D8,0x50CD,0x52D5, +0x540C,0x5802,0x5C0E,0x61A7,0x649E,0x6D1E,0x77B3,0x7AE5, +0x80F4,0x8404,0x9053,0x9285,0x5CE0,0x9D07,0x533F,0x5F97, +0x5FB3,0x6D9C,0x7279,0x7763,0x79BF,0x7BE4,0x6BD2,0x72EC, +0x8AAD,0x6803,0x6A61,0x51F8,0x7A81,0x6934,0x5C4A,0x9CF6, +0x82EB,0x5BC5,0x9149,0x701E,0x5678,0x5C6F,0x60C7,0x6566, +0x6C8C,0x8C5A,0x9041,0x9813,0x5451,0x66C7,0x920D,0x5948, +0x90A3,0x5185,0x4E4D,0x51EA,0x8599,0x8B0E,0x7058,0x637A, +0x934B,0x6962,0x99B4,0x7E04,0x7577,0x5357,0x6960,0x8EDF, +0x96E3,0x6C5D,0x4E8C,0x5C3C,0x5F10,0x8FE9,0x5302,0x8CD1, +0x8089,0x8679,0x5EFF,0x65E5,0x4E73,0x5165, +/* plane 1 ku 39 */ +0x5982,0x5C3F,0x97EE,0x4EFB,0x598A,0x5FCD,0x8A8D,0x6FE1, +0x79B0,0x7962,0x5BE7,0x8471,0x732B,0x71B1,0x5E74,0x5FF5, +0x637B,0x649A,0x71C3,0x7C98,0x4E43,0x5EFC,0x4E4B,0x57DC, +0x56A2,0x60A9,0x6FC3,0x7D0D,0x80FD,0x8133,0x81BF,0x8FB2, +0x8997,0x86A4,0x5DF4,0x628A,0x64AD,0x8987,0x6777,0x6CE2, +0x6D3E,0x7436,0x7834,0x5A46,0x7F75,0x82AD,0x99AC,0x4FF3, +0x5EC3,0x62DD,0x6392,0x6557,0x676F,0x76C3,0x724C,0x80CC, +0x80BA,0x8F29,0x914D,0x500D,0x57F9,0x5A92,0x6885,0x6973, +0x7164,0x72FD,0x8CB7,0x58F2,0x8CE0,0x966A,0x9019,0x877F, +0x79E4,0x77E7,0x8429,0x4F2F,0x5265,0x535A,0x62CD,0x67CF, +0x6CCA,0x767D,0x7B94,0x7C95,0x8236,0x8584,0x8FEB,0x66DD, +0x6F20,0x7206,0x7E1B,0x83AB,0x99C1,0x9EA6, +/* plane 1 ku 40 */ +0x51FD,0x7BB1,0x7872,0x7BB8,0x8087,0x7B48,0x6AE8,0x5E61, +0x808C,0x7551,0x7560,0x516B,0x9262,0x6E8C,0x767A,0x9197, +0x9AEA,0x4F10,0x7F70,0x629C,0x7B4F,0x95A5,0x9CE9,0x567A, +0x5859,0x86E4,0x96BC,0x4F34,0x5224,0x534A,0x53CD,0x53DB, +0x5E06,0x642C,0x6591,0x677F,0x6C3E,0x6C4E,0x7248,0x72AF, +0x73ED,0x7554,0x7E41,0x822C,0x85E9,0x8CA9,0x7BC4,0x91C6, +0x7169,0x9812,0x98EF,0x633D,0x6669,0x756A,0x76E4,0x78D0, +0x8543,0x86EE,0x532A,0x5351,0x5426,0x5983,0x5E87,0x5F7C, +0x60B2,0x6249,0x6279,0x62AB,0x6590,0x6BD4,0x6CCC,0x75B2, +0x76AE,0x7891,0x79D8,0x7DCB,0x7F77,0x80A5,0x88AB,0x8AB9, +0x8CBB,0x907F,0x975E,0x98DB,0x6A0B,0x7C38,0x5099,0x5C3E, +0x5FAE,0x6787,0x6BD8,0x7435,0x7709,0x7F8E, +/* plane 1 ku 41 */ +0x9F3B,0x67CA,0x7A17,0x5339,0x758B,0x9AED,0x5F66,0x819D, +0x83F1,0x8098,0x5F3C,0x5FC5,0x7562,0x7B46,0x903C,0x6867, +0x59EB,0x5A9B,0x7D10,0x767E,0x8B2C,0x4FF5,0x5F6A,0x6A19, +0x6C37,0x6F02,0x74E2,0x7968,0x8868,0x8A55,0x8C79,0x5EDF, +0x63CF,0x75C5,0x79D2,0x82D7,0x9328,0x92F2,0x849C,0x86ED, +0x9C2D,0x54C1,0x5F6C,0x658C,0x6D5C,0x7015,0x8CA7,0x8CD3, +0x983B,0x654F,0x74F6,0x4E0D,0x4ED8,0x57E0,0x592B,0x5A66, +0x5BCC,0x51A8,0x5E03,0x5E9C,0x6016,0x6276,0x6577,0x65A7, +0x666E,0x6D6E,0x7236,0x7B26,0x8150,0x819A,0x8299,0x8B5C, +0x8CA0,0x8CE6,0x8D74,0x961C,0x9644,0x4FAE,0x64AB,0x6B66, +0x821E,0x8461,0x856A,0x90E8,0x5C01,0x6953,0x98A8,0x847A, +0x8557,0x4F0F,0x526F,0x5FA9,0x5E45,0x670D, +/* plane 1 ku 42 */ +0x798F,0x8179,0x8907,0x8986,0x6DF5,0x5F17,0x6255,0x6CB8, +0x4ECF,0x7269,0x9B92,0x5206,0x543B,0x5674,0x58B3,0x61A4, +0x626E,0x711A,0x596E,0x7C89,0x7CDE,0x7D1B,0x96F0,0x6587, +0x805E,0x4E19,0x4F75,0x5175,0x5840,0x5E63,0x5E73,0x5F0A, +0x67C4,0x4E26,0x853D,0x9589,0x965B,0x7C73,0x9801,0x50FB, +0x58C1,0x7656,0x78A7,0x5225,0x77A5,0x8511,0x7B86,0x504F, +0x5909,0x7247,0x7BC7,0x7DE8,0x8FBA,0x8FD4,0x904D,0x4FBF, +0x52C9,0x5A29,0x5F01,0x97AD,0x4FDD,0x8217,0x92EA,0x5703, +0x6355,0x6B69,0x752B,0x88DC,0x8F14,0x7A42,0x52DF,0x5893, +0x6155,0x620A,0x66AE,0x6BCD,0x7C3F,0x83E9,0x5023,0x4FF8, +0x5305,0x5446,0x5831,0x5949,0x5B9D,0x5CF0,0x5CEF,0x5D29, +0x5E96,0x62B1,0x6367,0x653E,0x65B9,0x670B, +/* plane 1 ku 43 */ +0x6CD5,0x6CE1,0x70F9,0x7832,0x7E2B,0x80DE,0x82B3,0x840C, +0x84EC,0x8702,0x8912,0x8A2A,0x8C4A,0x90A6,0x92D2,0x98FD, +0x9CF3,0x9D6C,0x4E4F,0x4EA1,0x508D,0x5256,0x574A,0x59A8, +0x5E3D,0x5FD8,0x5FD9,0x623F,0x66B4,0x671B,0x67D0,0x68D2, +0x5192,0x7D21,0x80AA,0x81A8,0x8B00,0x8C8C,0x8CBF,0x927E, +0x9632,0x5420,0x982C,0x5317,0x50D5,0x535C,0x58A8,0x64B2, +0x6734,0x7267,0x7766,0x7A46,0x91E6,0x52C3,0x6CA1,0x6B86, +0x5800,0x5E4C,0x5954,0x672C,0x7FFB,0x51E1,0x76C6,0x6469, +0x78E8,0x9B54,0x9EBB,0x57CB,0x59B9,0x6627,0x679A,0x6BCE, +0x54E9,0x69D9,0x5E55,0x819C,0x6795,0x9BAA,0x67FE,0x9C52, +0x685D,0x4EA6,0x4FE3,0x53C8,0x62B9,0x672B,0x6CAB,0x8FC4, +0x4FAD,0x7E6D,0x9EBF,0x4E07,0x6162,0x6E80, +/* plane 1 ku 44 */ +0x6F2B,0x8513,0x5473,0x672A,0x9B45,0x5DF3,0x7B95,0x5CAC, +0x5BC6,0x871C,0x6E4A,0x84D1,0x7A14,0x8108,0x5999,0x7C8D, +0x6C11,0x7720,0x52D9,0x5922,0x7121,0x725F,0x77DB,0x9727, +0x9D61,0x690B,0x5A7F,0x5A18,0x51A5,0x540D,0x547D,0x660E, +0x76DF,0x8FF7,0x9298,0x9CF4,0x59EA,0x725D,0x6EC5,0x514D, +0x68C9,0x7DBF,0x7DEC,0x9762,0x9EBA,0x6478,0x6A21,0x8302, +0x5984,0x5B5F,0x6BDB,0x731B,0x76F2,0x7DB2,0x8017,0x8499, +0x5132,0x6728,0x9ED9,0x76EE,0x6762,0x52FF,0x9905,0x5C24, +0x623B,0x7C7E,0x8CB0,0x554F,0x60B6,0x7D0B,0x9580,0x5301, +0x4E5F,0x51B6,0x591C,0x723A,0x8036,0x91CE,0x5F25,0x77E2, +0x5384,0x5F79,0x7D04,0x85AC,0x8A33,0x8E8D,0x9756,0x67F3, +0x85AE,0x9453,0x6109,0x6108,0x6CB9,0x7652, +/* plane 1 ku 45 */ +0x8AED,0x8F38,0x552F,0x4F51,0x512A,0x52C7,0x53CB,0x5BA5, +0x5E7D,0x60A0,0x6182,0x63D6,0x6709,0x67DA,0x6E67,0x6D8C, +0x7336,0x7337,0x7531,0x7950,0x88D5,0x8A98,0x904A,0x9091, +0x90F5,0x96C4,0x878D,0x5915,0x4E88,0x4F59,0x4E0E,0x8A89, +0x8F3F,0x9810,0x50AD,0x5E7C,0x5996,0x5BB9,0x5EB8,0x63DA, +0x63FA,0x64C1,0x66DC,0x694A,0x69D8,0x6D0B,0x6EB6,0x7194, +0x7528,0x7AAF,0x7F8A,0x8000,0x8449,0x84C9,0x8981,0x8B21, +0x8E0A,0x9065,0x967D,0x990A,0x617E,0x6291,0x6B32,0x6C83, +0x6D74,0x7FCC,0x7FFC,0x6DC0,0x7F85,0x87BA,0x88F8,0x6765, +0x83B1,0x983C,0x96F7,0x6D1B,0x7D61,0x843D,0x916A,0x4E71, +0x5375,0x5D50,0x6B04,0x6FEB,0x85CD,0x862D,0x89A7,0x5229, +0x540F,0x5C65,0x674E,0x68A8,0x7406,0x7483, +/* plane 1 ku 46 */ +0x75E2,0x88CF,0x88E1,0x91CC,0x96E2,0x9678,0x5F8B,0x7387, +0x7ACB,0x844E,0x63A0,0x7565,0x5289,0x6D41,0x6E9C,0x7409, +0x7559,0x786B,0x7C92,0x9686,0x7ADC,0x9F8D,0x4FB6,0x616E, +0x65C5,0x865C,0x4E86,0x4EAE,0x50DA,0x4E21,0x51CC,0x5BEE, +0x6599,0x6881,0x6DBC,0x731F,0x7642,0x77AD,0x7A1C,0x7CE7, +0x826F,0x8AD2,0x907C,0x91CF,0x9675,0x9818,0x529B,0x7DD1, +0x502B,0x5398,0x6797,0x6DCB,0x71D0,0x7433,0x81E8,0x8F2A, +0x96A3,0x9C57,0x9E9F,0x7460,0x5841,0x6D99,0x7D2F,0x985E, +0x4EE4,0x4F36,0x4F8B,0x51B7,0x52B1,0x5DBA,0x601C,0x73B2, +0x793C,0x82D3,0x9234,0x96B7,0x96F6,0x970A,0x9E97,0x9F62, +0x66A6,0x6B74,0x5217,0x52A3,0x70C8,0x88C2,0x5EC9,0x604B, +0x6190,0x6F23,0x7149,0x7C3E,0x7DF4,0x806F, +/* plane 1 ku 47 */ +0x84EE,0x9023,0x932C,0x5442,0x9B6F,0x6AD3,0x7089,0x8CC2, +0x8DEF,0x9732,0x52B4,0x5A41,0x5ECA,0x5F04,0x6717,0x697C, +0x6994,0x6D6A,0x6F0F,0x7262,0x72FC,0x7BED,0x8001,0x807E, +0x874B,0x90CE,0x516D,0x9E93,0x7984,0x808B,0x9332,0x8AD6, +0x502D,0x548C,0x8A71,0x6B6A,0x8CC4,0x8107,0x60D1,0x67A0, +0x9DF2,0x4E99,0x4E98,0x9C10,0x8A6B,0x85C1,0x8568,0x6900, +0x6E7E,0x7897,0x8155,0x0000,0x5B41,0x5B56,0x5B7D,0x5B93, +0x5BD8,0x5BEC,0x5C12,0x5C1E,0x5C23,0x5C2B,0x378D,0x5C62, +0xFA3B,0xFA3C,0x0000,0x5C7A,0x5C8F,0x5C9F,0x5CA3,0x5CAA, +0x5CBA,0x5CCB,0x5CD0,0x5CD2,0x5CF4,0x0000,0x37E2,0x5D0D, +0x5D27,0xFA11,0x5D46,0x5D47,0x5D53,0x5D4A,0x5D6D,0x5D81, +0x5DA0,0x5DA4,0x5DA7,0x5DB8,0x5DCB,0x541E, +/* plane 1 ku 48 */ +0x5F0C,0x4E10,0x4E15,0x4E2A,0x4E31,0x4E36,0x4E3C,0x4E3F, +0x4E42,0x4E56,0x4E58,0x4E82,0x4E85,0x8C6B,0x4E8A,0x8212, +0x5F0D,0x4E8E,0x4E9E,0x4E9F,0x4EA0,0x4EA2,0x4EB0,0x4EB3, +0x4EB6,0x4ECE,0x4ECD,0x4EC4,0x4EC6,0x4EC2,0x4ED7,0x4EDE, +0x4EED,0x4EDF,0x4EF7,0x4F09,0x4F5A,0x4F30,0x4F5B,0x4F5D, +0x4F57,0x4F47,0x4F76,0x4F88,0x4F8F,0x4F98,0x4F7B,0x4F69, +0x4F70,0x4F91,0x4F6F,0x4F86,0x4F96,0x5118,0x4FD4,0x4FDF, +0x4FCE,0x4FD8,0x4FDB,0x4FD1,0x4FDA,0x4FD0,0x4FE4,0x4FE5, +0x501A,0x5028,0x5014,0x502A,0x5025,0x5005,0x4F1C,0x4FF6, +0x5021,0x5029,0x502C,0x4FFE,0x4FEF,0x5011,0x5006,0x5043, +0x5047,0x6703,0x5055,0x5050,0x5048,0x505A,0x5056,0x506C, +0x5078,0x5080,0x509A,0x5085,0x50B4,0x50B2, +/* plane 1 ku 49 */ +0x50C9,0x50CA,0x50B3,0x50C2,0x50D6,0x50DE,0x50E5,0x50ED, +0x50E3,0x50EE,0x50F9,0x50F5,0x5109,0x5101,0x5102,0x5116, +0x5115,0x5114,0x511A,0x5121,0x513A,0x5137,0x513C,0x513B, +0x513F,0x5140,0x5152,0x514C,0x5154,0x5162,0x7AF8,0x5169, +0x516A,0x516E,0x5180,0x5182,0x56D8,0x518C,0x5189,0x518F, +0x5191,0x5193,0x5195,0x5196,0x51A4,0x51A6,0x51A2,0x51A9, +0x51AA,0x51AB,0x51B3,0x51B1,0x51B2,0x51B0,0x51B5,0x51BD, +0x51C5,0x51C9,0x51DB,0x51E0,0x8655,0x51E9,0x51ED,0x51F0, +0x51F5,0x51FE,0x5204,0x520B,0x5214,0x520E,0x5227,0x522A, +0x522E,0x5233,0x5239,0x524F,0x5244,0x524B,0x524C,0x525E, +0x5254,0x526A,0x5274,0x5269,0x5273,0x527F,0x527D,0x528D, +0x5294,0x5292,0x5271,0x5288,0x5291,0x8FA8, +/* plane 1 ku 50 */ +0x8FA7,0x52AC,0x52AD,0x52BC,0x52B5,0x52C1,0x52CD,0x52D7, +0x52DE,0x52E3,0x52E6,0x98ED,0x52E0,0x52F3,0x52F5,0x52F8, +0x52F9,0x5306,0x5308,0x7538,0x530D,0x5310,0x530F,0x5315, +0x531A,0x5323,0x532F,0x5331,0x5333,0x5338,0x5340,0x5346, +0x5345,0x4E17,0x5349,0x534D,0x51D6,0x535E,0x5369,0x536E, +0x5918,0x537B,0x5377,0x5382,0x5396,0x53A0,0x53A6,0x53A5, +0x53AE,0x53B0,0x53B6,0x53C3,0x7C12,0x96D9,0x53DF,0x66FC, +0x71EE,0x53EE,0x53E8,0x53ED,0x53FA,0x5401,0x543D,0x5440, +0x542C,0x542D,0x543C,0x542E,0x5436,0x5429,0x541D,0x544E, +0x548F,0x5475,0x548E,0x545F,0x5471,0x5477,0x5470,0x5492, +0x547B,0x5480,0x5476,0x5484,0x5490,0x5486,0x54C7,0x54A2, +0x54B8,0x54A5,0x54AC,0x54C4,0x54C8,0x54A8, +/* plane 1 ku 51 */ +0x54AB,0x54C2,0x54A4,0x54BE,0x54BC,0x54D8,0x54E5,0x54E6, +0x550F,0x5514,0x54FD,0x54EE,0x54ED,0x54FA,0x54E2,0x5539, +0x5540,0x5563,0x554C,0x552E,0x555C,0x5545,0x5556,0x5557, +0x5538,0x5533,0x555D,0x5599,0x5580,0x54AF,0x558A,0x559F, +0x557B,0x557E,0x5598,0x559E,0x55AE,0x557C,0x5583,0x55A9, +0x5587,0x55A8,0x55DA,0x55C5,0x55DF,0x55C4,0x55DC,0x55E4, +0x55D4,0x5614,0x55F7,0x5616,0x55FE,0x55FD,0x561B,0x55F9, +0x564E,0x5650,0x71DF,0x5634,0x5636,0x5632,0x5638,0x566B, +0x5664,0x562F,0x566C,0x566A,0x5686,0x5680,0x568A,0x56A0, +0x5694,0x568F,0x56A5,0x56AE,0x56B6,0x56B4,0x56C2,0x56BC, +0x56C1,0x56C3,0x56C0,0x56C8,0x56CE,0x56D1,0x56D3,0x56D7, +0x56EE,0x56F9,0x5700,0x56FF,0x5704,0x5709, +/* plane 1 ku 52 */ +0x5708,0x570B,0x570D,0x5713,0x5718,0x5716,0x55C7,0x571C, +0x5726,0x5737,0x5738,0x574E,0x573B,0x5740,0x574F,0x5769, +0x57C0,0x5788,0x5761,0x577F,0x5789,0x5793,0x57A0,0x57B3, +0x57A4,0x57AA,0x57B0,0x57C3,0x57C6,0x57D4,0x57D2,0x57D3, +0x580A,0x57D6,0x57E3,0x580B,0x5819,0x581D,0x5872,0x5821, +0x5862,0x584B,0x5870,0x6BC0,0x5852,0x583D,0x5879,0x5885, +0x58B9,0x589F,0x58AB,0x58BA,0x58DE,0x58BB,0x58B8,0x58AE, +0x58C5,0x58D3,0x58D1,0x58D7,0x58D9,0x58D8,0x58E5,0x58DC, +0x58E4,0x58DF,0x58EF,0x58FA,0x58F9,0x58FB,0x58FC,0x58FD, +0x5902,0x590A,0x5910,0x591B,0x68A6,0x5925,0x592C,0x592D, +0x5932,0x5938,0x593E,0x7AD2,0x5955,0x5950,0x594E,0x595A, +0x5958,0x5962,0x5960,0x5967,0x596C,0x5969, +/* plane 1 ku 53 */ +0x5978,0x5981,0x599D,0x4F5E,0x4FAB,0x59A3,0x59B2,0x59C6, +0x59E8,0x59DC,0x598D,0x59D9,0x59DA,0x5A25,0x5A1F,0x5A11, +0x5A1C,0x5A09,0x5A1A,0x5A40,0x5A6C,0x5A49,0x5A35,0x5A36, +0x5A62,0x5A6A,0x5A9A,0x5ABC,0x5ABE,0x5ACB,0x5AC2,0x5ABD, +0x5AE3,0x5AD7,0x5AE6,0x5AE9,0x5AD6,0x5AFA,0x5AFB,0x5B0C, +0x5B0B,0x5B16,0x5B32,0x5AD0,0x5B2A,0x5B36,0x5B3E,0x5B43, +0x5B45,0x5B40,0x5B51,0x5B55,0x5B5A,0x5B5B,0x5B65,0x5B69, +0x5B70,0x5B73,0x5B75,0x5B78,0x6588,0x5B7A,0x5B80,0x5B83, +0x5BA6,0x5BB8,0x5BC3,0x5BC7,0x5BC9,0x5BD4,0x5BD0,0x5BE4, +0x5BE6,0x5BE2,0x5BDE,0x5BE5,0x5BEB,0x5BF0,0x5BF6,0x5BF3, +0x5C05,0x5C07,0x5C08,0x5C0D,0x5C13,0x5C20,0x5C22,0x5C28, +0x5C38,0x5C39,0x5C41,0x5C46,0x5C4E,0x5C53, +/* plane 1 ku 54 */ +0x5C50,0x5C4F,0x5B71,0x5C6C,0x5C6E,0x4E62,0x5C76,0x5C79, +0x5C8C,0x5C91,0x5C94,0x599B,0x5CAB,0x5CBB,0x5CB6,0x5CBC, +0x5CB7,0x5CC5,0x5CBE,0x5CC7,0x5CD9,0x5CE9,0x5CFD,0x5CFA, +0x5CED,0x5D8C,0x5CEA,0x5D0B,0x5D15,0x5D17,0x5D5C,0x5D1F, +0x5D1B,0x5D11,0x5D14,0x5D22,0x5D1A,0x5D19,0x5D18,0x5D4C, +0x5D52,0x5D4E,0x5D4B,0x5D6C,0x5D73,0x5D76,0x5D87,0x5D84, +0x5D82,0x5DA2,0x5D9D,0x5DAC,0x5DAE,0x5DBD,0x5D90,0x5DB7, +0x5DBC,0x5DC9,0x5DCD,0x5DD3,0x5DD2,0x5DD6,0x5DDB,0x5DEB, +0x5DF2,0x5DF5,0x5E0B,0x5E1A,0x5E19,0x5E11,0x5E1B,0x5E36, +0x5E37,0x5E44,0x5E43,0x5E40,0x5E4E,0x5E57,0x5E54,0x5E5F, +0x5E62,0x5E64,0x5E47,0x5E75,0x5E76,0x5E7A,0x9EBC,0x5E7F, +0x5EA0,0x5EC1,0x5EC2,0x5EC8,0x5ED0,0x5ECF, +/* plane 1 ku 55 */ +0x5ED6,0x5EE3,0x5EDD,0x5EDA,0x5EDB,0x5EE2,0x5EE1,0x5EE8, +0x5EE9,0x5EEC,0x5EF1,0x5EF3,0x5EF0,0x5EF4,0x5EF8,0x5EFE, +0x5F03,0x5F09,0x5F5D,0x5F5C,0x5F0B,0x5F11,0x5F16,0x5F29, +0x5F2D,0x5F38,0x5F41,0x5F48,0x5F4C,0x5F4E,0x5F2F,0x5F51, +0x5F56,0x5F57,0x5F59,0x5F61,0x5F6D,0x5F73,0x5F77,0x5F83, +0x5F82,0x5F7F,0x5F8A,0x5F88,0x5F91,0x5F87,0x5F9E,0x5F99, +0x5F98,0x5FA0,0x5FA8,0x5FAD,0x5FBC,0x5FD6,0x5FFB,0x5FE4, +0x5FF8,0x5FF1,0x5FDD,0x60B3,0x5FFF,0x6021,0x6060,0x6019, +0x6010,0x6029,0x600E,0x6031,0x601B,0x6015,0x602B,0x6026, +0x600F,0x603A,0x605A,0x6041,0x606A,0x6077,0x605F,0x604A, +0x6046,0x604D,0x6063,0x6043,0x6064,0x6042,0x606C,0x606B, +0x6059,0x6081,0x608D,0x60E7,0x6083,0x609A, +/* plane 1 ku 56 */ +0x6084,0x609B,0x6096,0x6097,0x6092,0x60A7,0x608B,0x60E1, +0x60B8,0x60E0,0x60D3,0x60B4,0x5FF0,0x60BD,0x60C6,0x60B5, +0x60D8,0x614D,0x6115,0x6106,0x60F6,0x60F7,0x6100,0x60F4, +0x60FA,0x6103,0x6121,0x60FB,0x60F1,0x610D,0x610E,0x6147, +0x613E,0x6128,0x6127,0x614A,0x613F,0x613C,0x612C,0x6134, +0x613D,0x6142,0x6144,0x6173,0x6177,0x6158,0x6159,0x615A, +0x616B,0x6174,0x616F,0x6165,0x6171,0x615F,0x615D,0x6153, +0x6175,0x6199,0x6196,0x6187,0x61AC,0x6194,0x619A,0x618A, +0x6191,0x61AB,0x61AE,0x61CC,0x61CA,0x61C9,0x61F7,0x61C8, +0x61C3,0x61C6,0x61BA,0x61CB,0x7F79,0x61CD,0x61E6,0x61E3, +0x61F6,0x61FA,0x61F4,0x61FF,0x61FD,0x61FC,0x61FE,0x6200, +0x6208,0x6209,0x620D,0x620C,0x6214,0x621B, +/* plane 1 ku 57 */ +0x621E,0x6221,0x622A,0x622E,0x6230,0x6232,0x6233,0x6241, +0x624E,0x625E,0x6263,0x625B,0x6260,0x6268,0x627C,0x6282, +0x6289,0x627E,0x6292,0x6293,0x6296,0x62D4,0x6283,0x6294, +0x62D7,0x62D1,0x62BB,0x62CF,0x62FF,0x62C6,0x64D4,0x62C8, +0x62DC,0x62CC,0x62CA,0x62C2,0x62C7,0x629B,0x62C9,0x630C, +0x62EE,0x62F1,0x6327,0x6302,0x6308,0x62EF,0x62F5,0x6350, +0x633E,0x634D,0x641C,0x634F,0x6396,0x638E,0x6380,0x63AB, +0x6376,0x63A3,0x638F,0x6389,0x639F,0x63B5,0x636B,0x6369, +0x63BE,0x63E9,0x63C0,0x63C6,0x63E3,0x63C9,0x63D2,0x63F6, +0x63C4,0x6416,0x6434,0x6406,0x6413,0x6426,0x6436,0x651D, +0x6417,0x6428,0x640F,0x6467,0x646F,0x6476,0x644E,0x652A, +0x6495,0x6493,0x64A5,0x64A9,0x6488,0x64BC, +/* plane 1 ku 58 */ +0x64DA,0x64D2,0x64C5,0x64C7,0x64BB,0x64D8,0x64C2,0x64F1, +0x64E7,0x8209,0x64E0,0x64E1,0x62AC,0x64E3,0x64EF,0x652C, +0x64F6,0x64F4,0x64F2,0x64FA,0x6500,0x64FD,0x6518,0x651C, +0x6505,0x6524,0x6523,0x652B,0x6534,0x6535,0x6537,0x6536, +0x6538,0x754B,0x6548,0x6556,0x6555,0x654D,0x6558,0x655E, +0x655D,0x6572,0x6578,0x6582,0x6583,0x8B8A,0x659B,0x659F, +0x65AB,0x65B7,0x65C3,0x65C6,0x65C1,0x65C4,0x65CC,0x65D2, +0x65DB,0x65D9,0x65E0,0x65E1,0x65F1,0x6772,0x660A,0x6603, +0x65FB,0x6773,0x6635,0x6636,0x6634,0x661C,0x664F,0x6644, +0x6649,0x6641,0x665E,0x665D,0x6664,0x6667,0x6668,0x665F, +0x6662,0x6670,0x6683,0x6688,0x668E,0x6689,0x6684,0x6698, +0x669D,0x66C1,0x66B9,0x66C9,0x66BE,0x66BC, +/* plane 1 ku 59 */ +0x66C4,0x66B8,0x66D6,0x66DA,0x66E0,0x663F,0x66E6,0x66E9, +0x66F0,0x66F5,0x66F7,0x670F,0x6716,0x671E,0x6726,0x6727, +0x9738,0x672E,0x673F,0x6736,0x6741,0x6738,0x6737,0x6746, +0x675E,0x6760,0x6759,0x6763,0x6764,0x6789,0x6770,0x67A9, +0x677C,0x676A,0x678C,0x678B,0x67A6,0x67A1,0x6785,0x67B7, +0x67EF,0x67B4,0x67EC,0x67B3,0x67E9,0x67B8,0x67E4,0x67DE, +0x67DD,0x67E2,0x67EE,0x67B9,0x67CE,0x67C6,0x67E7,0x6A9C, +0x681E,0x6846,0x6829,0x6840,0x684D,0x6832,0x684E,0x68B3, +0x682B,0x6859,0x6863,0x6877,0x687F,0x689F,0x688F,0x68AD, +0x6894,0x689D,0x689B,0x6883,0x6AAE,0x68B9,0x6874,0x68B5, +0x68A0,0x68BA,0x690F,0x688D,0x687E,0x6901,0x68CA,0x6908, +0x68D8,0x6922,0x6926,0x68E1,0x690C,0x68CD, +/* plane 1 ku 60 */ +0x68D4,0x68E7,0x68D5,0x6936,0x6912,0x6904,0x68D7,0x68E3, +0x6925,0x68F9,0x68E0,0x68EF,0x6928,0x692A,0x691A,0x6923, +0x6921,0x68C6,0x6979,0x6977,0x695C,0x6978,0x696B,0x6954, +0x697E,0x696E,0x6939,0x6974,0x693D,0x6959,0x6930,0x6961, +0x695E,0x695D,0x6981,0x696A,0x69B2,0x69AE,0x69D0,0x69BF, +0x69C1,0x69D3,0x69BE,0x69CE,0x5BE8,0x69CA,0x69DD,0x69BB, +0x69C3,0x69A7,0x6A2E,0x6991,0x69A0,0x699C,0x6995,0x69B4, +0x69DE,0x69E8,0x6A02,0x6A1B,0x69FF,0x6B0A,0x69F9,0x69F2, +0x69E7,0x6A05,0x69B1,0x6A1E,0x69ED,0x6A14,0x69EB,0x6A0A, +0x6A12,0x6AC1,0x6A23,0x6A13,0x6A44,0x6A0C,0x6A72,0x6A36, +0x6A78,0x6A47,0x6A62,0x6A59,0x6A66,0x6A48,0x6A38,0x6A22, +0x6A90,0x6A8D,0x6AA0,0x6A84,0x6AA2,0x6AA3, +/* plane 1 ku 61 */ +0x6A97,0x8617,0x6ABB,0x6AC3,0x6AC2,0x6AB8,0x6AB3,0x6AAC, +0x6ADE,0x6AD1,0x6ADF,0x6AAA,0x6ADA,0x6AEA,0x6AFB,0x6B05, +0x8616,0x6AFA,0x6B12,0x6B16,0x9B31,0x6B1F,0x6B38,0x6B37, +0x76DC,0x6B39,0x98EE,0x6B47,0x6B43,0x6B49,0x6B50,0x6B59, +0x6B54,0x6B5B,0x6B5F,0x6B61,0x6B78,0x6B79,0x6B7F,0x6B80, +0x6B84,0x6B83,0x6B8D,0x6B98,0x6B95,0x6B9E,0x6BA4,0x6BAA, +0x6BAB,0x6BAF,0x6BB2,0x6BB1,0x6BB3,0x6BB7,0x6BBC,0x6BC6, +0x6BCB,0x6BD3,0x6BDF,0x6BEC,0x6BEB,0x6BF3,0x6BEF,0x9EBE, +0x6C08,0x6C13,0x6C14,0x6C1B,0x6C24,0x6C23,0x6C5E,0x6C55, +0x6C62,0x6C6A,0x6C82,0x6C8D,0x6C9A,0x6C81,0x6C9B,0x6C7E, +0x6C68,0x6C73,0x6C92,0x6C90,0x6CC4,0x6CF1,0x6CD3,0x6CBD, +0x6CD7,0x6CC5,0x6CDD,0x6CAE,0x6CB1,0x6CBE, +/* plane 1 ku 62 */ +0x6CBA,0x6CDB,0x6CEF,0x6CD9,0x6CEA,0x6D1F,0x884D,0x6D36, +0x6D2B,0x6D3D,0x6D38,0x6D19,0x6D35,0x6D33,0x6D12,0x6D0C, +0x6D63,0x6D93,0x6D64,0x6D5A,0x6D79,0x6D59,0x6D8E,0x6D95, +0x6FE4,0x6D85,0x6DF9,0x6E15,0x6E0A,0x6DB5,0x6DC7,0x6DE6, +0x6DB8,0x6DC6,0x6DEC,0x6DDE,0x6DCC,0x6DE8,0x6DD2,0x6DC5, +0x6DFA,0x6DD9,0x6DE4,0x6DD5,0x6DEA,0x6DEE,0x6E2D,0x6E6E, +0x6E2E,0x6E19,0x6E72,0x6E5F,0x6E3E,0x6E23,0x6E6B,0x6E2B, +0x6E76,0x6E4D,0x6E1F,0x6E43,0x6E3A,0x6E4E,0x6E24,0x6EFF, +0x6E1D,0x6E38,0x6E82,0x6EAA,0x6E98,0x6EC9,0x6EB7,0x6ED3, +0x6EBD,0x6EAF,0x6EC4,0x6EB2,0x6ED4,0x6ED5,0x6E8F,0x6EA5, +0x6EC2,0x6E9F,0x6F41,0x6F11,0x704C,0x6EEC,0x6EF8,0x6EFE, +0x6F3F,0x6EF2,0x6F31,0x6EEF,0x6F32,0x6ECC, +/* plane 1 ku 63 */ +0x6F3E,0x6F13,0x6EF7,0x6F86,0x6F7A,0x6F78,0x6F81,0x6F80, +0x6F6F,0x6F5B,0x6FF3,0x6F6D,0x6F82,0x6F7C,0x6F58,0x6F8E, +0x6F91,0x6FC2,0x6F66,0x6FB3,0x6FA3,0x6FA1,0x6FA4,0x6FB9, +0x6FC6,0x6FAA,0x6FDF,0x6FD5,0x6FEC,0x6FD4,0x6FD8,0x6FF1, +0x6FEE,0x6FDB,0x7009,0x700B,0x6FFA,0x7011,0x7001,0x700F, +0x6FFE,0x701B,0x701A,0x6F74,0x701D,0x7018,0x701F,0x7030, +0x703E,0x7032,0x7051,0x7063,0x7099,0x7092,0x70AF,0x70F1, +0x70AC,0x70B8,0x70B3,0x70AE,0x70DF,0x70CB,0x70DD,0x70D9, +0x7109,0x70FD,0x711C,0x7119,0x7165,0x7155,0x7188,0x7166, +0x7162,0x714C,0x7156,0x716C,0x718F,0x71FB,0x7184,0x7195, +0x71A8,0x71AC,0x71D7,0x71B9,0x71BE,0x71D2,0x71C9,0x71D4, +0x71CE,0x71E0,0x71EC,0x71E7,0x71F5,0x71FC, +/* plane 1 ku 64 */ +0x71F9,0x71FF,0x720D,0x7210,0x721B,0x7228,0x722D,0x722C, +0x7230,0x7232,0x723B,0x723C,0x723F,0x7240,0x7246,0x724B, +0x7258,0x7274,0x727E,0x7282,0x7281,0x7287,0x7292,0x7296, +0x72A2,0x72A7,0x72B9,0x72B2,0x72C3,0x72C6,0x72C4,0x72CE, +0x72D2,0x72E2,0x72E0,0x72E1,0x72F9,0x72F7,0x500F,0x7317, +0x730A,0x731C,0x7316,0x731D,0x7334,0x732F,0x7329,0x7325, +0x733E,0x734E,0x734F,0x9ED8,0x7357,0x736A,0x7368,0x7370, +0x7378,0x7375,0x737B,0x737A,0x73C8,0x73B3,0x73CE,0x73BB, +0x73C0,0x73E5,0x73EE,0x73DE,0x74A2,0x7405,0x746F,0x7425, +0x73F8,0x7432,0x743A,0x7455,0x743F,0x745F,0x7459,0x7441, +0x745C,0x7469,0x7470,0x7463,0x746A,0x7476,0x747E,0x748B, +0x749E,0x74A7,0x74CA,0x74CF,0x74D4,0x73F1, +/* plane 1 ku 65 */ +0x74E0,0x74E3,0x74E7,0x74E9,0x74EE,0x74F2,0x74F0,0x74F1, +0x74F8,0x74F7,0x7504,0x7503,0x7505,0x750C,0x750E,0x750D, +0x7515,0x7513,0x751E,0x7526,0x752C,0x753C,0x7544,0x754D, +0x754A,0x7549,0x755B,0x7546,0x755A,0x7569,0x7564,0x7567, +0x756B,0x756D,0x7578,0x7576,0x7586,0x7587,0x7574,0x758A, +0x7589,0x7582,0x7594,0x759A,0x759D,0x75A5,0x75A3,0x75C2, +0x75B3,0x75C3,0x75B5,0x75BD,0x75B8,0x75BC,0x75B1,0x75CD, +0x75CA,0x75D2,0x75D9,0x75E3,0x75DE,0x75FE,0x75FF,0x75FC, +0x7601,0x75F0,0x75FA,0x75F2,0x75F3,0x760B,0x760D,0x7609, +0x761F,0x7627,0x7620,0x7621,0x7622,0x7624,0x7634,0x7630, +0x763B,0x7647,0x7648,0x7646,0x765C,0x7658,0x7661,0x7662, +0x7668,0x7669,0x766A,0x7667,0x766C,0x7670, +/* plane 1 ku 66 */ +0x7672,0x7676,0x7678,0x767C,0x7680,0x7683,0x7688,0x768B, +0x768E,0x7696,0x7693,0x7699,0x769A,0x76B0,0x76B4,0x76B8, +0x76B9,0x76BA,0x76C2,0x76CD,0x76D6,0x76D2,0x76DE,0x76E1, +0x76E5,0x76E7,0x76EA,0x862F,0x76FB,0x7708,0x7707,0x7704, +0x7729,0x7724,0x771E,0x7725,0x7726,0x771B,0x7737,0x7738, +0x7747,0x775A,0x7768,0x776B,0x775B,0x7765,0x777F,0x777E, +0x7779,0x778E,0x778B,0x7791,0x77A0,0x779E,0x77B0,0x77B6, +0x77B9,0x77BF,0x77BC,0x77BD,0x77BB,0x77C7,0x77CD,0x77D7, +0x77DA,0x77DC,0x77E3,0x77EE,0x77FC,0x780C,0x7812,0x7926, +0x7820,0x792A,0x7845,0x788E,0x7874,0x7886,0x787C,0x789A, +0x788C,0x78A3,0x78B5,0x78AA,0x78AF,0x78D1,0x78C6,0x78CB, +0x78D4,0x78BE,0x78BC,0x78C5,0x78CA,0x78EC, +/* plane 1 ku 67 */ +0x78E7,0x78DA,0x78FD,0x78F4,0x7907,0x7912,0x7911,0x7919, +0x792C,0x792B,0x7940,0x7960,0x7957,0x795F,0x795A,0x7955, +0x7953,0x797A,0x797F,0x798A,0x799D,0x79A7,0x9F4B,0x79AA, +0x79AE,0x79B3,0x79B9,0x79BA,0x79C9,0x79D5,0x79E7,0x79EC, +0x79E1,0x79E3,0x7A08,0x7A0D,0x7A18,0x7A19,0x7A20,0x7A1F, +0x7980,0x7A31,0x7A3B,0x7A3E,0x7A37,0x7A43,0x7A57,0x7A49, +0x7A61,0x7A62,0x7A69,0x9F9D,0x7A70,0x7A79,0x7A7D,0x7A88, +0x7A97,0x7A95,0x7A98,0x7A96,0x7AA9,0x7AC8,0x7AB0,0x7AB6, +0x7AC5,0x7AC4,0x7ABF,0x9083,0x7AC7,0x7ACA,0x7ACD,0x7ACF, +0x7AD5,0x7AD3,0x7AD9,0x7ADA,0x7ADD,0x7AE1,0x7AE2,0x7AE6, +0x7AED,0x7AF0,0x7B02,0x7B0F,0x7B0A,0x7B06,0x7B33,0x7B18, +0x7B19,0x7B1E,0x7B35,0x7B28,0x7B36,0x7B50, +/* plane 1 ku 68 */ +0x7B7A,0x7B04,0x7B4D,0x7B0B,0x7B4C,0x7B45,0x7B75,0x7B65, +0x7B74,0x7B67,0x7B70,0x7B71,0x7B6C,0x7B6E,0x7B9D,0x7B98, +0x7B9F,0x7B8D,0x7B9C,0x7B9A,0x7B8B,0x7B92,0x7B8F,0x7B5D, +0x7B99,0x7BCB,0x7BC1,0x7BCC,0x7BCF,0x7BB4,0x7BC6,0x7BDD, +0x7BE9,0x7C11,0x7C14,0x7BE6,0x7BE5,0x7C60,0x7C00,0x7C07, +0x7C13,0x7BF3,0x7BF7,0x7C17,0x7C0D,0x7BF6,0x7C23,0x7C27, +0x7C2A,0x7C1F,0x7C37,0x7C2B,0x7C3D,0x7C4C,0x7C43,0x7C54, +0x7C4F,0x7C40,0x7C50,0x7C58,0x7C5F,0x7C64,0x7C56,0x7C65, +0x7C6C,0x7C75,0x7C83,0x7C90,0x7CA4,0x7CAD,0x7CA2,0x7CAB, +0x7CA1,0x7CA8,0x7CB3,0x7CB2,0x7CB1,0x7CAE,0x7CB9,0x7CBD, +0x7CC0,0x7CC5,0x7CC2,0x7CD8,0x7CD2,0x7CDC,0x7CE2,0x9B3B, +0x7CEF,0x7CF2,0x7CF4,0x7CF6,0x7CFA,0x7D06, +/* plane 1 ku 69 */ +0x7D02,0x7D1C,0x7D15,0x7D0A,0x7D45,0x7D4B,0x7D2E,0x7D32, +0x7D3F,0x7D35,0x7D46,0x7D73,0x7D56,0x7D4E,0x7D72,0x7D68, +0x7D6E,0x7D4F,0x7D63,0x7D93,0x7D89,0x7D5B,0x7D8F,0x7D7D, +0x7D9B,0x7DBA,0x7DAE,0x7DA3,0x7DB5,0x7DC7,0x7DBD,0x7DAB, +0x7E3D,0x7DA2,0x7DAF,0x7DDC,0x7DB8,0x7D9F,0x7DB0,0x7DD8, +0x7DDD,0x7DE4,0x7DDE,0x7DFB,0x7DF2,0x7DE1,0x7E05,0x7E0A, +0x7E23,0x7E21,0x7E12,0x7E31,0x7E1F,0x7E09,0x7E0B,0x7E22, +0x7E46,0x7E66,0x7E3B,0x7E35,0x7E39,0x7E43,0x7E37,0x7E32, +0x7E3A,0x7E67,0x7E5D,0x7E56,0x7E5E,0x7E59,0x7E5A,0x7E79, +0x7E6A,0x7E69,0x7E7C,0x7E7B,0x7E83,0x7DD5,0x7E7D,0x8FAE, +0x7E7F,0x7E88,0x7E89,0x7E8C,0x7E92,0x7E90,0x7E93,0x7E94, +0x7E96,0x7E8E,0x7E9B,0x7E9C,0x7F38,0x7F3A, +/* plane 1 ku 70 */ +0x7F45,0x7F4C,0x7F4D,0x7F4E,0x7F50,0x7F51,0x7F55,0x7F54, +0x7F58,0x7F5F,0x7F60,0x7F68,0x7F69,0x7F67,0x7F78,0x7F82, +0x7F86,0x7F83,0x7F88,0x7F87,0x7F8C,0x7F94,0x7F9E,0x7F9D, +0x7F9A,0x7FA3,0x7FAF,0x7FB2,0x7FB9,0x7FAE,0x7FB6,0x7FB8, +0x8B71,0x7FC5,0x7FC6,0x7FCA,0x7FD5,0x7FD4,0x7FE1,0x7FE6, +0x7FE9,0x7FF3,0x7FF9,0x98DC,0x8006,0x8004,0x800B,0x8012, +0x8018,0x8019,0x801C,0x8021,0x8028,0x803F,0x803B,0x804A, +0x8046,0x8052,0x8058,0x805A,0x805F,0x8062,0x8068,0x8073, +0x8072,0x8070,0x8076,0x8079,0x807D,0x807F,0x8084,0x8086, +0x8085,0x809B,0x8093,0x809A,0x80AD,0x5190,0x80AC,0x80DB, +0x80E5,0x80D9,0x80DD,0x80C4,0x80DA,0x80D6,0x8109,0x80EF, +0x80F1,0x811B,0x8129,0x8123,0x812F,0x814B, +/* plane 1 ku 71 */ +0x968B,0x8146,0x813E,0x8153,0x8151,0x80FC,0x8171,0x816E, +0x8165,0x8166,0x8174,0x8183,0x8188,0x818A,0x8180,0x8182, +0x81A0,0x8195,0x81A4,0x81A3,0x815F,0x8193,0x81A9,0x81B0, +0x81B5,0x81BE,0x81B8,0x81BD,0x81C0,0x81C2,0x81BA,0x81C9, +0x81CD,0x81D1,0x81D9,0x81D8,0x81C8,0x81DA,0x81DF,0x81E0, +0x81E7,0x81FA,0x81FB,0x81FE,0x8201,0x8202,0x8205,0x8207, +0x820A,0x820D,0x8210,0x8216,0x8229,0x822B,0x8238,0x8233, +0x8240,0x8259,0x8258,0x825D,0x825A,0x825F,0x8264,0x8262, +0x8268,0x826A,0x826B,0x822E,0x8271,0x8277,0x8278,0x827E, +0x828D,0x8292,0x82AB,0x829F,0x82BB,0x82AC,0x82E1,0x82E3, +0x82DF,0x82D2,0x82F4,0x82F3,0x82FA,0x8393,0x8303,0x82FB, +0x82F9,0x82DE,0x8306,0x82DC,0x8309,0x82D9, +/* plane 1 ku 72 */ +0x8335,0x8334,0x8316,0x8332,0x8331,0x8340,0x8339,0x8350, +0x8345,0x832F,0x832B,0x8317,0x8318,0x8385,0x839A,0x83AA, +0x839F,0x83A2,0x8396,0x8323,0x838E,0x8387,0x838A,0x837C, +0x83B5,0x8373,0x8375,0x83A0,0x8389,0x83A8,0x83F4,0x8413, +0x83EB,0x83CE,0x83FD,0x8403,0x83D8,0x840B,0x83C1,0x83F7, +0x8407,0x83E0,0x83F2,0x840D,0x8422,0x8420,0x83BD,0x8438, +0x8506,0x83FB,0x846D,0x842A,0x843C,0x855A,0x8484,0x8477, +0x846B,0x84AD,0x846E,0x8482,0x8469,0x8446,0x842C,0x846F, +0x8479,0x8435,0x84CA,0x8462,0x84B9,0x84BF,0x849F,0x84D9, +0x84CD,0x84BB,0x84DA,0x84D0,0x84C1,0x84C6,0x84D6,0x84A1, +0x8521,0x84FF,0x84F4,0x8517,0x8518,0x852C,0x851F,0x8515, +0x8514,0x84FC,0x8540,0x8563,0x8558,0x8548, +/* plane 1 ku 73 */ +0x8541,0x8602,0x854B,0x8555,0x8580,0x85A4,0x8588,0x8591, +0x858A,0x85A8,0x856D,0x8594,0x859B,0x85EA,0x8587,0x859C, +0x8577,0x857E,0x8590,0x85C9,0x85BA,0x85CF,0x85B9,0x85D0, +0x85D5,0x85DD,0x85E5,0x85DC,0x85F9,0x860A,0x8613,0x860B, +0x85FE,0x85FA,0x8606,0x8622,0x861A,0x8630,0x863F,0x864D, +0x4E55,0x8654,0x865F,0x8667,0x8671,0x8693,0x86A3,0x86A9, +0x86AA,0x868B,0x868C,0x86B6,0x86AF,0x86C4,0x86C6,0x86B0, +0x86C9,0x8823,0x86AB,0x86D4,0x86DE,0x86E9,0x86EC,0x86DF, +0x86DB,0x86EF,0x8712,0x8706,0x8708,0x8700,0x8703,0x86FB, +0x8711,0x8709,0x870D,0x86F9,0x870A,0x8734,0x873F,0x8737, +0x873B,0x8725,0x8729,0x871A,0x8760,0x875F,0x8778,0x874C, +0x874E,0x8774,0x8757,0x8768,0x876E,0x8759, +/* plane 1 ku 74 */ +0x8753,0x8763,0x876A,0x8805,0x87A2,0x879F,0x8782,0x87AF, +0x87CB,0x87BD,0x87C0,0x87D0,0x96D6,0x87AB,0x87C4,0x87B3, +0x87C7,0x87C6,0x87BB,0x87EF,0x87F2,0x87E0,0x880F,0x880D, +0x87FE,0x87F6,0x87F7,0x880E,0x87D2,0x8811,0x8816,0x8815, +0x8822,0x8821,0x8831,0x8836,0x8839,0x8827,0x883B,0x8844, +0x8842,0x8852,0x8859,0x885E,0x8862,0x886B,0x8881,0x887E, +0x889E,0x8875,0x887D,0x88B5,0x8872,0x8882,0x8897,0x8892, +0x88AE,0x8899,0x88A2,0x888D,0x88A4,0x88B0,0x88BF,0x88B1, +0x88C3,0x88C4,0x88D4,0x88D8,0x88D9,0x88DD,0x88F9,0x8902, +0x88FC,0x88F4,0x88E8,0x88F2,0x8904,0x890C,0x890A,0x8913, +0x8943,0x891E,0x8925,0x892A,0x892B,0x8941,0x8944,0x893B, +0x8936,0x8938,0x894C,0x891D,0x8960,0x895E, +/* plane 1 ku 75 */ +0x8966,0x8964,0x896D,0x896A,0x896F,0x8974,0x8977,0x897E, +0x8983,0x8988,0x898A,0x8993,0x8998,0x89A1,0x89A9,0x89A6, +0x89AC,0x89AF,0x89B2,0x89BA,0x89BD,0x89BF,0x89C0,0x89DA, +0x89DC,0x89DD,0x89E7,0x89F4,0x89F8,0x8A03,0x8A16,0x8A10, +0x8A0C,0x8A1B,0x8A1D,0x8A25,0x8A36,0x8A41,0x8A5B,0x8A52, +0x8A46,0x8A48,0x8A7C,0x8A6D,0x8A6C,0x8A62,0x8A85,0x8A82, +0x8A84,0x8AA8,0x8AA1,0x8A91,0x8AA5,0x8AA6,0x8A9A,0x8AA3, +0x8AC4,0x8ACD,0x8AC2,0x8ADA,0x8AEB,0x8AF3,0x8AE7,0x8AE4, +0x8AF1,0x8B14,0x8AE0,0x8AE2,0x8AF7,0x8ADE,0x8ADB,0x8B0C, +0x8B07,0x8B1A,0x8AE1,0x8B16,0x8B10,0x8B17,0x8B20,0x8B33, +0x97AB,0x8B26,0x8B2B,0x8B3E,0x8B28,0x8B41,0x8B4C,0x8B4F, +0x8B4E,0x8B49,0x8B56,0x8B5B,0x8B5A,0x8B6B, +/* plane 1 ku 76 */ +0x8B5F,0x8B6C,0x8B6F,0x8B74,0x8B7D,0x8B80,0x8B8C,0x8B8E, +0x8B92,0x8B93,0x8B96,0x8B99,0x8B9A,0x8C3A,0x8C41,0x8C3F, +0x8C48,0x8C4C,0x8C4E,0x8C50,0x8C55,0x8C62,0x8C6C,0x8C78, +0x8C7A,0x8C82,0x8C89,0x8C85,0x8C8A,0x8C8D,0x8C8E,0x8C94, +0x8C7C,0x8C98,0x621D,0x8CAD,0x8CAA,0x8CBD,0x8CB2,0x8CB3, +0x8CAE,0x8CB6,0x8CC8,0x8CC1,0x8CE4,0x8CE3,0x8CDA,0x8CFD, +0x8CFA,0x8CFB,0x8D04,0x8D05,0x8D0A,0x8D07,0x8D0F,0x8D0D, +0x8D10,0x9F4E,0x8D13,0x8CCD,0x8D14,0x8D16,0x8D67,0x8D6D, +0x8D71,0x8D73,0x8D81,0x8D99,0x8DC2,0x8DBE,0x8DBA,0x8DCF, +0x8DDA,0x8DD6,0x8DCC,0x8DDB,0x8DCB,0x8DEA,0x8DEB,0x8DDF, +0x8DE3,0x8DFC,0x8E08,0x8E09,0x8DFF,0x8E1D,0x8E1E,0x8E10, +0x8E1F,0x8E42,0x8E35,0x8E30,0x8E34,0x8E4A, +/* plane 1 ku 77 */ +0x8E47,0x8E49,0x8E4C,0x8E50,0x8E48,0x8E59,0x8E64,0x8E60, +0x8E2A,0x8E63,0x8E55,0x8E76,0x8E72,0x8E7C,0x8E81,0x8E87, +0x8E85,0x8E84,0x8E8B,0x8E8A,0x8E93,0x8E91,0x8E94,0x8E99, +0x8EAA,0x8EA1,0x8EAC,0x8EB0,0x8EC6,0x8EB1,0x8EBE,0x8EC5, +0x8EC8,0x8ECB,0x8EDB,0x8EE3,0x8EFC,0x8EFB,0x8EEB,0x8EFE, +0x8F0A,0x8F05,0x8F15,0x8F12,0x8F19,0x8F13,0x8F1C,0x8F1F, +0x8F1B,0x8F0C,0x8F26,0x8F33,0x8F3B,0x8F39,0x8F45,0x8F42, +0x8F3E,0x8F4C,0x8F49,0x8F46,0x8F4E,0x8F57,0x8F5C,0x8F62, +0x8F63,0x8F64,0x8F9C,0x8F9F,0x8FA3,0x8FAD,0x8FAF,0x8FB7, +0x8FDA,0x8FE5,0x8FE2,0x8FEA,0x8FEF,0x9087,0x8FF4,0x9005, +0x8FF9,0x8FFA,0x9011,0x9015,0x9021,0x900D,0x901E,0x9016, +0x900B,0x9027,0x9036,0x9035,0x9039,0x8FF8, +/* plane 1 ku 78 */ +0x904F,0x9050,0x9051,0x9052,0x900E,0x9049,0x903E,0x9056, +0x9058,0x905E,0x9068,0x906F,0x9076,0x96A8,0x9072,0x9082, +0x907D,0x9081,0x9080,0x908A,0x9089,0x908F,0x90A8,0x90AF, +0x90B1,0x90B5,0x90E2,0x90E4,0x6248,0x90DB,0x9102,0x9112, +0x9119,0x9132,0x9130,0x914A,0x9156,0x9158,0x9163,0x9165, +0x9169,0x9173,0x9172,0x918B,0x9189,0x9182,0x91A2,0x91AB, +0x91AF,0x91AA,0x91B5,0x91B4,0x91BA,0x91C0,0x91C1,0x91C9, +0x91CB,0x91D0,0x91D6,0x91DF,0x91E1,0x91DB,0x91FC,0x91F5, +0x91F6,0x921E,0x91FF,0x9214,0x922C,0x9215,0x9211,0x925E, +0x9257,0x9245,0x9249,0x9264,0x9248,0x9295,0x923F,0x924B, +0x9250,0x929C,0x9296,0x9293,0x929B,0x925A,0x92CF,0x92B9, +0x92B7,0x92E9,0x930F,0x92FA,0x9344,0x932E, +/* plane 1 ku 79 */ +0x9319,0x9322,0x931A,0x9323,0x933A,0x9335,0x933B,0x935C, +0x9360,0x937C,0x936E,0x9356,0x93B0,0x93AC,0x93AD,0x9394, +0x93B9,0x93D6,0x93D7,0x93E8,0x93E5,0x93D8,0x93C3,0x93DD, +0x93D0,0x93C8,0x93E4,0x941A,0x9414,0x9413,0x9403,0x9407, +0x9410,0x9436,0x942B,0x9435,0x9421,0x943A,0x9441,0x9452, +0x9444,0x945B,0x9460,0x9462,0x945E,0x946A,0x9229,0x9470, +0x9475,0x9477,0x947D,0x945A,0x947C,0x947E,0x9481,0x947F, +0x9582,0x9587,0x958A,0x9594,0x9596,0x9598,0x9599,0x95A0, +0x95A8,0x95A7,0x95AD,0x95BC,0x95BB,0x95B9,0x95BE,0x95CA, +0x6FF6,0x95C3,0x95CD,0x95CC,0x95D5,0x95D4,0x95D6,0x95DC, +0x95E1,0x95E5,0x95E2,0x9621,0x9628,0x962E,0x962F,0x9642, +0x964C,0x964F,0x964B,0x9677,0x965C,0x965E, +/* plane 1 ku 80 */ +0x965D,0x965F,0x9666,0x9672,0x966C,0x968D,0x9698,0x9695, +0x9697,0x96AA,0x96A7,0x96B1,0x96B2,0x96B0,0x96B4,0x96B6, +0x96B8,0x96B9,0x96CE,0x96CB,0x96C9,0x96CD,0x894D,0x96DC, +0x970D,0x96D5,0x96F9,0x9704,0x9706,0x9708,0x9713,0x970E, +0x9711,0x970F,0x9716,0x9719,0x9724,0x972A,0x9730,0x9739, +0x973D,0x973E,0x9744,0x9746,0x9748,0x9742,0x9749,0x975C, +0x9760,0x9764,0x9766,0x9768,0x52D2,0x976B,0x9771,0x9779, +0x9785,0x977C,0x9781,0x977A,0x9786,0x978B,0x978F,0x9790, +0x979C,0x97A8,0x97A6,0x97A3,0x97B3,0x97B4,0x97C3,0x97C6, +0x97C8,0x97CB,0x97DC,0x97ED,0x9F4F,0x97F2,0x7ADF,0x97F6, +0x97F5,0x980F,0x980C,0x9838,0x9824,0x9821,0x9837,0x983D, +0x9846,0x984F,0x984B,0x986B,0x986F,0x9870, +/* plane 1 ku 81 */ +0x9871,0x9874,0x9873,0x98AA,0x98AF,0x98B1,0x98B6,0x98C4, +0x98C3,0x98C6,0x98E9,0x98EB,0x9903,0x9909,0x9912,0x9914, +0x9918,0x9921,0x991D,0x991E,0x9924,0x9920,0x992C,0x992E, +0x993D,0x993E,0x9942,0x9949,0x9945,0x9950,0x994B,0x9951, +0x9952,0x994C,0x9955,0x9997,0x9998,0x99A5,0x99AD,0x99AE, +0x99BC,0x99DF,0x99DB,0x99DD,0x99D8,0x99D1,0x99ED,0x99EE, +0x99F1,0x99F2,0x99FB,0x99F8,0x9A01,0x9A0F,0x9A05,0x99E2, +0x9A19,0x9A2B,0x9A37,0x9A45,0x9A42,0x9A40,0x9A43,0x9A3E, +0x9A55,0x9A4D,0x9A5B,0x9A57,0x9A5F,0x9A62,0x9A65,0x9A64, +0x9A69,0x9A6B,0x9A6A,0x9AAD,0x9AB0,0x9ABC,0x9AC0,0x9ACF, +0x9AD1,0x9AD3,0x9AD4,0x9ADE,0x9ADF,0x9AE2,0x9AE3,0x9AE6, +0x9AEF,0x9AEB,0x9AEE,0x9AF4,0x9AF1,0x9AF7, +/* plane 1 ku 82 */ +0x9AFB,0x9B06,0x9B18,0x9B1A,0x9B1F,0x9B22,0x9B23,0x9B25, +0x9B27,0x9B28,0x9B29,0x9B2A,0x9B2E,0x9B2F,0x9B32,0x9B44, +0x9B43,0x9B4F,0x9B4D,0x9B4E,0x9B51,0x9B58,0x9B74,0x9B93, +0x9B83,0x9B91,0x9B96,0x9B97,0x9B9F,0x9BA0,0x9BA8,0x9BB4, +0x9BC0,0x9BCA,0x9BB9,0x9BC6,0x9BCF,0x9BD1,0x9BD2,0x9BE3, +0x9BE2,0x9BE4,0x9BD4,0x9BE1,0x9C3A,0x9BF2,0x9BF1,0x9BF0, +0x9C15,0x9C14,0x9C09,0x9C13,0x9C0C,0x9C06,0x9C08,0x9C12, +0x9C0A,0x9C04,0x9C2E,0x9C1B,0x9C25,0x9C24,0x9C21,0x9C30, +0x9C47,0x9C32,0x9C46,0x9C3E,0x9C5A,0x9C60,0x9C67,0x9C76, +0x9C78,0x9CE7,0x9CEC,0x9CF0,0x9D09,0x9D08,0x9CEB,0x9D03, +0x9D06,0x9D2A,0x9D26,0x9DAF,0x9D23,0x9D1F,0x9D44,0x9D15, +0x9D12,0x9D41,0x9D3F,0x9D3E,0x9D46,0x9D48, +/* plane 1 ku 83 */ +0x9D5D,0x9D5E,0x9D64,0x9D51,0x9D50,0x9D59,0x9D72,0x9D89, +0x9D87,0x9DAB,0x9D6F,0x9D7A,0x9D9A,0x9DA4,0x9DA9,0x9DB2, +0x9DC4,0x9DC1,0x9DBB,0x9DB8,0x9DBA,0x9DC6,0x9DCF,0x9DC2, +0x9DD9,0x9DD3,0x9DF8,0x9DE6,0x9DED,0x9DEF,0x9DFD,0x9E1A, +0x9E1B,0x9E1E,0x9E75,0x9E79,0x9E7D,0x9E81,0x9E88,0x9E8B, +0x9E8C,0x9E92,0x9E95,0x9E91,0x9E9D,0x9EA5,0x9EA9,0x9EB8, +0x9EAA,0x9EAD,0x9761,0x9ECC,0x9ECE,0x9ECF,0x9ED0,0x9ED4, +0x9EDC,0x9EDE,0x9EDD,0x9EE0,0x9EE5,0x9EE8,0x9EEF,0x9EF4, +0x9EF6,0x9EF7,0x9EF9,0x9EFB,0x9EFC,0x9EFD,0x9F07,0x9F08, +0x76B7,0x9F15,0x9F21,0x9F2C,0x9F3E,0x9F4A,0x9F52,0x9F54, +0x9F63,0x9F5F,0x9F60,0x9F61,0x9F66,0x9F67,0x9F6C,0x9F6A, +0x9F77,0x9F72,0x9F76,0x9F95,0x9F9C,0x9FA0, +/* plane 1 ku 84 */ +0x582F,0x69C7,0x9059,0x7464,0x51DC,0x7199,0x5653,0x5DE2, +0x5E14,0x5E18,0x5E58,0x5E5E,0x5EBE,0xF928,0x5ECB,0x5EF9, +0x5F00,0x5F02,0x5F07,0x5F1D,0x5F23,0x5F34,0x5F36,0x5F3D, +0x5F40,0x5F45,0x5F54,0x5F58,0x5F64,0x5F67,0x5F7D,0x5F89, +0x5F9C,0x5FA7,0x5FAF,0x5FB5,0x5FB7,0x5FC9,0x5FDE,0x5FE1, +0x5FE9,0x600D,0x6014,0x6018,0x6033,0x6035,0x6047,0xFA3D, +0x609D,0x609E,0x60CB,0x60D4,0x60D5,0x60DD,0x60F8,0x611C, +0x612B,0x6130,0x6137,0xFA3E,0x618D,0xFA3F,0x61BC,0x61B9, +0xFA40,0x6222,0x623E,0x6243,0x6256,0x625A,0x626F,0x6285, +0x62C4,0x62D6,0x62FC,0x630A,0x6318,0x6339,0x6343,0x6365, +0x637C,0x63E5,0x63ED,0x63F5,0x6410,0x6414,0x6422,0x6479, +0x6451,0x6460,0x646D,0x64CE,0x64BE,0x64BF, +/* plane 1 ku 85 */ +0x64C4,0x64CA,0x64D0,0x64F7,0x64FB,0x6522,0x6529,0xFA41, +0x6567,0x659D,0xFA42,0x6600,0x6609,0x6615,0x661E,0x663A, +0x6622,0x6624,0x662B,0x6630,0x6631,0x6633,0x66FB,0x6648, +0x664C,0x0000,0x6659,0x665A,0x6661,0x6665,0x6673,0x6677, +0x6678,0x668D,0xFA43,0x66A0,0x66B2,0x66BB,0x66C6,0x66C8, +0x3B22,0x66DB,0x66E8,0x66FA,0x6713,0xF929,0x6733,0x6766, +0x6747,0x6748,0x677B,0x6781,0x6793,0x6798,0x679B,0x67BB, +0x67F9,0x67C0,0x67D7,0x67FC,0x6801,0x6852,0x681D,0x682C, +0x6831,0x685B,0x6872,0x6875,0xFA44,0x68A3,0x68A5,0x68B2, +0x68C8,0x68D0,0x68E8,0x68ED,0x68F0,0x68F1,0x68FC,0x690A, +0x6949,0x0000,0x6935,0x6942,0x6957,0x6963,0x6964,0x6968, +0x6980,0xFA14,0x69A5,0x69AD,0x69CF,0x3BB6, +/* plane 1 ku 86 */ +0x3BC3,0x69E2,0x69E9,0x69EA,0x69F5,0x69F6,0x6A0F,0x6A15, +0x0000,0x6A3B,0x6A3E,0x6A45,0x6A50,0x6A56,0x6A5B,0x6A6B, +0x6A73,0x0000,0x6A89,0x6A94,0x6A9D,0x6A9E,0x6AA5,0x6AE4, +0x6AE7,0x3C0F,0xF91D,0x6B1B,0x6B1E,0x6B2C,0x6B35,0x6B46, +0x6B56,0x6B60,0x6B65,0x6B67,0x6B77,0x6B82,0x6BA9,0x6BAD, +0xF970,0x6BCF,0x6BD6,0x6BD7,0x6BFF,0x6C05,0x6C10,0x6C33, +0x6C59,0x6C5C,0x6CAA,0x6C74,0x6C76,0x6C85,0x6C86,0x6C98, +0x6C9C,0x6CFB,0x6CC6,0x6CD4,0x6CE0,0x6CEB,0x6CEE,0x0000, +0x6D04,0x6D0E,0x6D2E,0x6D31,0x6D39,0x6D3F,0x6D58,0x6D65, +0xFA45,0x6D82,0x6D87,0x6D89,0x6D94,0x6DAA,0x6DAC,0x6DBF, +0x6DC4,0x6DD6,0x6DDA,0x6DDB,0x6DDD,0x6DFC,0xFA46,0x6E34, +0x6E44,0x6E5C,0x6E5E,0x6EAB,0x6EB1,0x6EC1, +/* plane 1 ku 87 */ +0x6EC7,0x6ECE,0x6F10,0x6F1A,0xFA47,0x6F2A,0x6F2F,0x6F33, +0x6F51,0x6F59,0x6F5E,0x6F61,0x6F62,0x6F7E,0x6F88,0x6F8C, +0x6F8D,0x6F94,0x6FA0,0x6FA7,0x6FB6,0x6FBC,0x6FC7,0x6FCA, +0x6FF9,0x6FF0,0x6FF5,0x7005,0x7006,0x7028,0x704A,0x705D, +0x705E,0x704E,0x7064,0x7075,0x7085,0x70A4,0x70AB,0x70B7, +0x70D4,0x70D8,0x70E4,0x710F,0x712B,0x711E,0x7120,0x712E, +0x7130,0x7146,0x7147,0x7151,0xFA48,0x7152,0x715C,0x7160, +0x7168,0xFA15,0x7185,0x7187,0x7192,0x71C1,0x71BA,0x71C4, +0x71FE,0x7200,0x7215,0x7255,0x7256,0x3E3F,0x728D,0x729B, +0x72BE,0x72C0,0x72FB,0x0000,0x7327,0x7328,0xFA16,0x7350, +0x7366,0x737C,0x7395,0x739F,0x73A0,0x73A2,0x73A6,0x73AB, +0x73C9,0x73CF,0x73D6,0x73D9,0x73E3,0x73E9, +/* plane 1 ku 88 */ +0x7407,0x740A,0x741A,0x741B,0xFA4A,0x7426,0x7428,0x742A, +0x742B,0x742C,0x742E,0x742F,0x7430,0x7444,0x7446,0x7447, +0x744B,0x7457,0x7462,0x746B,0x746D,0x7486,0x7487,0x7489, +0x7498,0x749C,0x749F,0x74A3,0x7490,0x74A6,0x74A8,0x74A9, +0x74B5,0x74BF,0x74C8,0x74C9,0x74DA,0x74FF,0x7501,0x7517, +0x752F,0x756F,0x7579,0x7592,0x3F72,0x75CE,0x75E4,0x7600, +0x7602,0x7608,0x7615,0x7616,0x7619,0x761E,0x762D,0x7635, +0x7643,0x764B,0x7664,0x7665,0x766D,0x766F,0x7671,0x7681, +0x769B,0x769D,0x769E,0x76A6,0x76AA,0x76B6,0x76C5,0x76CC, +0x76CE,0x76D4,0x76E6,0x76F1,0x76FC,0x770A,0x7719,0x7734, +0x7736,0x7746,0x774D,0x774E,0x775C,0x775F,0x7762,0x777A, +0x7780,0x7794,0x77AA,0x77E0,0x782D,0x0000, +/* plane 1 ku 89 */ +0x7843,0x784E,0x784F,0x7851,0x7868,0x786E,0xFA4B,0x78B0, +0x0000,0x78AD,0x78E4,0x78F2,0x7900,0x78F7,0x791C,0x792E, +0x7931,0x7934,0xFA4C,0xFA4D,0x7945,0x7946,0xFA4E,0xFA4F, +0xFA50,0x795C,0xFA51,0xFA19,0xFA1A,0x7979,0xFA52,0xFA53, +0xFA1B,0x7998,0x79B1,0x79B8,0x79C8,0x79CA,0x0000,0x79D4, +0x79DE,0x79EB,0x79ED,0x7A03,0xFA54,0x7A39,0x7A5D,0x7A6D, +0xFA55,0x7A85,0x7AA0,0x0000,0x7AB3,0x7ABB,0x7ACE,0x7AEB, +0x7AFD,0x7B12,0x7B2D,0x7B3B,0x7B47,0x7B4E,0x7B60,0x7B6D, +0x7B6F,0x7B72,0x7B9E,0xFA56,0x7BD7,0x7BD9,0x7C01,0x7C31, +0x7C1E,0x7C20,0x7C33,0x7C36,0x4264,0x0000,0x7C59,0x7C6D, +0x7C79,0x7C8F,0x7C94,0x7CA0,0x7CBC,0x7CD5,0x7CD9,0x7CDD, +0x7D07,0x7D08,0x7D13,0x7D1D,0x7D23,0x7D31, +/* plane 1 ku 90 */ +0x7D41,0x7D48,0x7D53,0x7D5C,0x7D7A,0x7D83,0x7D8B,0x7DA0, +0x7DA6,0x7DC2,0x7DCC,0x7DD6,0x7DE3,0xFA57,0x7E28,0x7E08, +0x7E11,0x7E15,0xFA59,0x7E47,0x7E52,0x7E61,0x7E8A,0x7E8D, +0x7F47,0xFA5A,0x7F91,0x7F97,0x7FBF,0x7FCE,0x7FDB,0x7FDF, +0x7FEC,0x7FEE,0x7FFA,0xFA5B,0x8014,0x8026,0x8035,0x8037, +0x803C,0x80CA,0x80D7,0x80E0,0x80F3,0x8118,0x814A,0x8160, +0x8167,0x8168,0x816D,0x81BB,0x81CA,0x81CF,0x81D7,0xFA5C, +0x4453,0x445B,0x8260,0x8274,0x0000,0x828E,0x82A1,0x82A3, +0x82A4,0x82A9,0x82AE,0x82B7,0x82BE,0x82BF,0x82C6,0x82D5, +0x82FD,0x82FE,0x8300,0x8301,0x8362,0x8322,0x832D,0x833A, +0x8343,0x8347,0x8351,0x8355,0x837D,0x8386,0x8392,0x8398, +0x83A7,0x83A9,0x83BF,0x83C0,0x83C7,0x83CF, +/* plane 1 ku 91 */ +0x83D1,0x83E1,0x83EA,0x8401,0x8406,0x840A,0xFA5F,0x8448, +0x845F,0x8470,0x8473,0x8485,0x849E,0x84AF,0x84B4,0x84BA, +0x84C0,0x84C2,0x0000,0x8532,0x851E,0x8523,0x852F,0x8559, +0x8564,0xFA1F,0x85AD,0x857A,0x858C,0x858F,0x85A2,0x85B0, +0x85CB,0x85CE,0x85ED,0x8612,0x85FF,0x8604,0x8605,0x8610, +0x0000,0x8618,0x8629,0x8638,0x8657,0x865B,0xF936,0x8662, +0x459D,0x866C,0x8675,0x8698,0x86B8,0x86FA,0x86FC,0x86FD, +0x870B,0x8771,0x8787,0x8788,0x87AC,0x87AD,0x87B5,0x45EA, +0x87D6,0x87EC,0x8806,0x880A,0x8810,0x8814,0x881F,0x8898, +0x88AA,0x88CA,0x88CE,0x0000,0x88F5,0x891C,0xFA60,0x8918, +0x8919,0x891A,0x8927,0x8930,0x8932,0x8939,0x8940,0x8994, +0xFA61,0x89D4,0x89E5,0x89F6,0x8A12,0x8A15, +/* plane 1 ku 92 */ +0x8A22,0x8A37,0x8A47,0x8A4E,0x8A5D,0x8A61,0x8A75,0x8A79, +0x8AA7,0x8AD0,0x8ADF,0x8AF4,0x8AF6,0xFA22,0xFA62,0xFA63, +0x8B46,0x8B54,0x8B59,0x8B69,0x8B9D,0x8C49,0x8C68,0xFA64, +0x8CE1,0x8CF4,0x8CF8,0x8CFE,0xFA65,0x8D12,0x8D1B,0x8DAF, +0x8DCE,0x8DD1,0x8DD7,0x8E20,0x8E23,0x8E3D,0x8E70,0x8E7B, +0x0000,0x8EC0,0x4844,0x8EFA,0x8F1E,0x8F2D,0x8F36,0x8F54, +0x0000,0x8FA6,0x8FB5,0x8FE4,0x8FE8,0x8FEE,0x9008,0x902D, +0xFA67,0x9088,0x9095,0x9097,0x9099,0x909B,0x90A2,0x90B3, +0x90BE,0x90C4,0x90C5,0x90C7,0x90D7,0x90DD,0x90DE,0x90EF, +0x90F4,0xFA26,0x9114,0x9115,0x9116,0x9122,0x9123,0x9127, +0x912F,0x9131,0x9134,0x913D,0x9148,0x915B,0x9183,0x919E, +0x91AC,0x91B1,0x91BC,0x91D7,0x91FB,0x91E4, +/* plane 1 ku 93 */ +0x91E5,0x91ED,0x91F1,0x9207,0x9210,0x9238,0x9239,0x923A, +0x923C,0x9240,0x9243,0x924F,0x9278,0x9288,0x92C2,0x92CB, +0x92CC,0x92D3,0x92E0,0x92FF,0x9304,0x931F,0x9321,0x9325, +0x9348,0x9349,0x934A,0x9364,0x9365,0x936A,0x9370,0x939B, +0x93A3,0x93BA,0x93C6,0x93DE,0x93DF,0x9404,0x93FD,0x9433, +0x944A,0x9463,0x946B,0x9471,0x9472,0x958E,0x959F,0x95A6, +0x95A9,0x95AC,0x95B6,0x95BD,0x95CB,0x95D0,0x95D3,0x49B0, +0x95DA,0x95DE,0x9658,0x9684,0xF9DC,0x969D,0x96A4,0x96A5, +0x96D2,0x96DE,0xFA68,0x96E9,0x96EF,0x9733,0x973B,0x974D, +0x974E,0x974F,0x975A,0x976E,0x9773,0x9795,0x97AE,0x97BA, +0x97C1,0x97C9,0x97DE,0x97DB,0x97F4,0xFA69,0x980A,0x981E, +0x982B,0x9830,0xFA6A,0x9852,0x9853,0x9856, +/* plane 1 ku 94 */ +0x9857,0x9859,0x985A,0xF9D0,0x9865,0x986C,0x98BA,0x98C8, +0x98E7,0x9958,0x999E,0x9A02,0x9A03,0x9A24,0x9A2D,0x9A2E, +0x9A38,0x9A4A,0x9A4E,0x9A52,0x9AB6,0x9AC1,0x9AC3,0x9ACE, +0x9AD6,0x9AF9,0x9B02,0x9B08,0x9B20,0x4C17,0x9B2D,0x9B5E, +0x9B79,0x9B66,0x9B72,0x9B75,0x9B84,0x9B8A,0x9B8F,0x9B9E, +0x9BA7,0x9BC1,0x9BCE,0x9BE5,0x9BF8,0x9BFD,0x9C00,0x9C23, +0x9C41,0x9C4F,0x9C50,0x9C53,0x9C63,0x9C65,0x9C77,0x9D1D, +0x9D1E,0x9D43,0x9D47,0x9D52,0x9D63,0x9D70,0x9D7C,0x9D8A, +0x9D96,0x9DC0,0x9DAC,0x9DBC,0x9DD7,0x0000,0x9DE7,0x9E07, +0x9E15,0x9E7C,0x9E9E,0x9EA4,0x9EAC,0x9EAF,0x9EB4,0x9EB5, +0x9EC3,0x9ED1,0x9F10,0x9F39,0x9F57,0x9F90,0x9F94,0x9F97, +0x9FA2,0x59F8,0x5C5B,0x5E77,0x7626,0x7E6B, +/* plane 2 ku 1 */ +0x0000,0x4E02,0x4E0F,0x4E12,0x4E29,0x4E2B,0x4E2E,0x4E40, +0x4E47,0x4E48,0x0000,0x4E51,0x3406,0x0000,0x4E5A,0x4E69, +0x4E9D,0x342C,0x342E,0x4EB9,0x4EBB,0x0000,0x4EBC,0x4EC3, +0x4EC8,0x4ED0,0x4EEB,0x4EDA,0x4EF1,0x4EF5,0x4F00,0x4F16, +0x4F64,0x4F37,0x4F3E,0x4F54,0x4F58,0x0000,0x4F77,0x4F78, +0x4F7A,0x4F7D,0x4F82,0x4F85,0x4F92,0x4F9A,0x4FE6,0x4FB2, +0x4FBE,0x4FC5,0x4FCB,0x4FCF,0x4FD2,0x346A,0x4FF2,0x5000, +0x5010,0x5013,0x501C,0x501E,0x5022,0x3468,0x5042,0x5046, +0x504E,0x5053,0x5057,0x5063,0x5066,0x506A,0x5070,0x50A3, +0x5088,0x5092,0x5093,0x5095,0x5096,0x509C,0x50AA,0x0000, +0x50B1,0x50BA,0x50BB,0x50C4,0x50C7,0x50F3,0x0000,0x50CE, +0x0000,0x50D4,0x50D9,0x50E1,0x50E9,0x3492, +/* plane 2 ku 8 */ +0x5B96,0x5BAC,0x3761,0x5BC0,0x3762,0x5BCE,0x5BD6,0x376C, +0x376B,0x5BF1,0x5BFD,0x3775,0x5C03,0x5C29,0x5C30,0x0000, +0x5C5F,0x5C63,0x5C67,0x5C68,0x5C69,0x5C70,0x0000,0x0000, +0x5C7C,0x0000,0x0000,0x5C88,0x5C8A,0x37C1,0x0000,0x0000, +0x5CA0,0x5CA2,0x5CA6,0x5CA7,0x0000,0x5CAD,0x5CB5,0x0000, +0x5CC9,0x0000,0x0000,0x5D06,0x5D10,0x5D2B,0x5D1D,0x5D20, +0x5D24,0x5D26,0x5D31,0x5D39,0x5D42,0x37E8,0x5D61,0x5D6A, +0x37F4,0x5D70,0x0000,0x37FD,0x5D88,0x3800,0x5D92,0x5D94, +0x5D97,0x5D99,0x5DB0,0x5DB2,0x5DB4,0x0000,0x5DB9,0x5DD1, +0x5DD7,0x5DD8,0x5DE0,0x0000,0x5DE4,0x5DE9,0x382F,0x5E00, +0x3836,0x5E12,0x5E15,0x3840,0x5E1F,0x5E2E,0x5E3E,0x5E49, +0x385C,0x5E56,0x3861,0x5E6B,0x5E6C,0x5E6D, +/* plane 2 ku 3 */ +0x5108,0x0000,0x5117,0x511B,0x0000,0x5160,0x0000,0x5173, +0x5183,0x518B,0x34BC,0x5198,0x51A3,0x51AD,0x34C7,0x51BC, +0x0000,0x0000,0x51F3,0x51F4,0x5202,0x5212,0x5216,0x0000, +0x5255,0x525C,0x526C,0x5277,0x5284,0x5282,0x0000,0x5298, +0x0000,0x52A4,0x52A6,0x52AF,0x52BA,0x52BB,0x52CA,0x351F, +0x52D1,0x0000,0x52F7,0x530A,0x530B,0x5324,0x5335,0x533E, +0x5342,0x0000,0x0000,0x5367,0x536C,0x537A,0x53A4,0x53B4, +0x0000,0x53B7,0x53C0,0x0000,0x355D,0x355E,0x53D5,0x53DA, +0x3563,0x53F4,0x53F5,0x5455,0x5424,0x5428,0x356E,0x5443, +0x5462,0x5466,0x546C,0x548A,0x548D,0x5495,0x54A0,0x54A6, +0x54AD,0x54AE,0x54B7,0x54BA,0x54BF,0x54C3,0x0000,0x54EC, +0x54EF,0x54F1,0x54F3,0x5500,0x5501,0x5509, +/* plane 2 ku 4 */ +0x553C,0x5541,0x35A6,0x5547,0x554A,0x35A8,0x5560,0x5561, +0x5564,0x0000,0x557D,0x5582,0x5588,0x5591,0x35C5,0x55D2, +0x0000,0x0000,0x55BF,0x55C9,0x55CC,0x55D1,0x55DD,0x35DA, +0x55E2,0x0000,0x55E9,0x5628,0x0000,0x5607,0x5610,0x5630, +0x5637,0x35F4,0x563D,0x563F,0x5640,0x5647,0x565E,0x5660, +0x566D,0x3605,0x5688,0x568C,0x5695,0x569A,0x569D,0x56A8, +0x56AD,0x56B2,0x56C5,0x56CD,0x56DF,0x56E8,0x56F6,0x56F7, +0x0000,0x5715,0x5723,0x0000,0x5729,0x0000,0x5745,0x5746, +0x574C,0x574D,0x0000,0x5768,0x576F,0x5773,0x5774,0x5775, +0x577B,0x0000,0x0000,0x57AC,0x579A,0x579D,0x579E,0x57A8, +0x57D7,0x0000,0x57CC,0x0000,0x0000,0x57DE,0x57E6,0x57F0, +0x364A,0x57F8,0x57FB,0x57FD,0x5804,0x581E, +/* plane 2 ku 5 */ +0x5820,0x5827,0x5832,0x5839,0x0000,0x5849,0x584C,0x5867, +0x588A,0x588B,0x588D,0x588F,0x5890,0x5894,0x589D,0x58AA, +0x58B1,0x0000,0x58C3,0x58CD,0x58E2,0x58F3,0x58F4,0x5905, +0x5906,0x590B,0x590D,0x5914,0x5924,0x0000,0x3691,0x593D, +0x3699,0x5946,0x3696,0x0000,0x595B,0x595F,0x0000,0x5975, +0x5976,0x597C,0x599F,0x59AE,0x59BC,0x59C8,0x59CD,0x59DE, +0x59E3,0x59E4,0x59E7,0x59EE,0x0000,0x0000,0x36CF,0x5A0C, +0x5A0D,0x5A17,0x5A27,0x5A2D,0x5A55,0x5A65,0x5A7A,0x5A8B, +0x5A9C,0x5A9F,0x5AA0,0x5AA2,0x5AB1,0x5AB3,0x5AB5,0x5ABA, +0x5ABF,0x5ADA,0x5ADC,0x5AE0,0x5AE5,0x5AF0,0x5AEE,0x5AF5, +0x5B00,0x5B08,0x5B17,0x5B34,0x5B2D,0x5B4C,0x5B52,0x5B68, +0x5B6F,0x5B7C,0x5B7F,0x5B81,0x5B84,0x0000, +/* plane 2 ku 12 */ +0x5E6E,0x0000,0x5EA5,0x5EAA,0x5EAC,0x5EB9,0x5EBF,0x5EC6, +0x5ED2,0x5ED9,0x0000,0x5EFD,0x5F08,0x5F0E,0x5F1C,0x0000, +0x5F1E,0x5F47,0x5F63,0x5F72,0x5F7E,0x5F8F,0x5FA2,0x5FA4, +0x5FB8,0x5FC4,0x38FA,0x5FC7,0x5FCB,0x5FD2,0x5FD3,0x5FD4, +0x5FE2,0x5FEE,0x5FEF,0x5FF3,0x5FFC,0x3917,0x6017,0x6022, +0x6024,0x391A,0x604C,0x607F,0x608A,0x6095,0x60A8,0x0000, +0x60B0,0x60B1,0x60BE,0x60C8,0x60D9,0x60DB,0x60EE,0x60F2, +0x60F5,0x6110,0x6112,0x6113,0x6119,0x611E,0x613A,0x396F, +0x6141,0x6146,0x6160,0x617C,0x0000,0x6192,0x6193,0x6197, +0x6198,0x61A5,0x61A8,0x61AD,0x0000,0x61D5,0x61DD,0x61DF, +0x61F5,0x0000,0x6215,0x6223,0x6229,0x6246,0x624C,0x6251, +0x6252,0x6261,0x6264,0x627B,0x626D,0x6273, +/* plane 2 ku 13 */ +0x6299,0x62A6,0x62D5,0x0000,0x62FD,0x6303,0x630D,0x6310, +0x0000,0x0000,0x6332,0x6335,0x633B,0x633C,0x6341,0x6344, +0x634E,0x0000,0x6359,0x0000,0x0000,0x636C,0x6384,0x6399, +0x0000,0x6394,0x63BD,0x63F7,0x63D4,0x63D5,0x63DC,0x63E0, +0x63EB,0x63EC,0x63F2,0x6409,0x641E,0x6425,0x6429,0x642F, +0x645A,0x645B,0x645D,0x6473,0x647D,0x6487,0x6491,0x649D, +0x649F,0x64CB,0x64CC,0x64D5,0x64D7,0x0000,0x64E4,0x64E5, +0x64FF,0x6504,0x3A6E,0x650F,0x6514,0x6516,0x3A73,0x651E, +0x6532,0x6544,0x6554,0x656B,0x657A,0x6581,0x6584,0x6585, +0x658A,0x65B2,0x65B5,0x65B8,0x65BF,0x65C2,0x65C9,0x65D4, +0x3AD6,0x65F2,0x65F9,0x65FC,0x6604,0x6608,0x6621,0x662A, +0x6645,0x6651,0x664E,0x3AEA,0x0000,0x6657, +/* plane 2 ku 14 */ +0x665B,0x6663,0x0000,0x0000,0x666A,0x666B,0x666C,0x666D, +0x667B,0x6680,0x6690,0x6692,0x6699,0x3B0E,0x66AD,0x66B1, +0x66B5,0x3B1A,0x66BF,0x3B1C,0x66EC,0x3AD7,0x6701,0x6705, +0x6712,0x0000,0x6719,0x0000,0x0000,0x674C,0x674D,0x6754, +0x675D,0x0000,0x0000,0x0000,0x6774,0x6776,0x0000,0x6792, +0x0000,0x8363,0x6810,0x67B0,0x67B2,0x67C3,0x67C8,0x67D2, +0x67D9,0x67DB,0x67F0,0x67F7,0x0000,0x0000,0x0000,0x6818, +0x681F,0x682D,0x0000,0x6833,0x683B,0x683E,0x6844,0x6845, +0x6849,0x684C,0x6855,0x6857,0x3B77,0x686B,0x686E,0x687A, +0x687C,0x6882,0x6890,0x6896,0x3B6D,0x6898,0x6899,0x689A, +0x689C,0x68AA,0x68AB,0x68B4,0x68BB,0x68FB,0x0000,0x0000, +0xFA13,0x68C3,0x68C5,0x68CC,0x68CF,0x68D6, +/* plane 2 ku 15 */ +0x68D9,0x68E4,0x68E5,0x68EC,0x68F7,0x6903,0x6907,0x3B87, +0x3B88,0x0000,0x693B,0x3B8D,0x6946,0x6969,0x696C,0x6972, +0x697A,0x697F,0x6992,0x3BA4,0x6996,0x6998,0x69A6,0x69B0, +0x69B7,0x69BA,0x69BC,0x69C0,0x69D1,0x69D6,0x0000,0x0000, +0x6A30,0x0000,0x0000,0x69E3,0x69EE,0x69EF,0x69F3,0x3BCD, +0x69F4,0x69FE,0x6A11,0x6A1A,0x6A1D,0x0000,0x6A32,0x6A33, +0x6A34,0x6A3F,0x6A46,0x6A49,0x6A7A,0x6A4E,0x6A52,0x6A64, +0x0000,0x6A7E,0x6A83,0x6A8B,0x3BF0,0x6A91,0x6A9F,0x6AA1, +0x0000,0x6AAB,0x6ABD,0x6AC6,0x6AD4,0x6AD0,0x6ADC,0x6ADD, +0x0000,0x0000,0x6AEC,0x6AF1,0x6AF2,0x6AF3,0x6AFD,0x0000, +0x6B0B,0x6B0F,0x6B10,0x6B11,0x0000,0x6B17,0x3C26,0x6B2F, +0x6B4A,0x6B58,0x6B6C,0x6B75,0x6B7A,0x6B81, +/* plane 2 ku 78 */ +0x6B9B,0x6BAE,0x0000,0x6BBD,0x6BBE,0x6BC7,0x6BC8,0x6BC9, +0x6BDA,0x6BE6,0x6BE7,0x6BEE,0x6BF1,0x6C02,0x6C0A,0x6C0E, +0x6C35,0x6C36,0x6C3A,0x0000,0x6C3F,0x6C4D,0x6C5B,0x6C6D, +0x6C84,0x6C89,0x3CC3,0x6C94,0x6C95,0x6C97,0x6CAD,0x6CC2, +0x6CD0,0x3CD2,0x6CD6,0x6CDA,0x6CDC,0x6CE9,0x6CEC,0x6CED, +0x0000,0x6D00,0x6D0A,0x6D24,0x6D26,0x6D27,0x6C67,0x6D2F, +0x6D3C,0x6D5B,0x6D5E,0x6D60,0x6D70,0x6D80,0x6D81,0x6D8A, +0x6D8D,0x6D91,0x6D98,0x0000,0x6E17,0x0000,0x0000,0x0000, +0x6DAB,0x6DAE,0x6DB4,0x6DC2,0x6D34,0x6DC8,0x6DCE,0x6DCF, +0x6DD0,0x6DDF,0x6DE9,0x6DF6,0x6E36,0x6E1E,0x6E22,0x6E27, +0x3D11,0x6E32,0x6E3C,0x6E48,0x6E49,0x6E4B,0x6E4C,0x6E4F, +0x6E51,0x6E53,0x6E54,0x6E57,0x6E63,0x3D1E, +/* plane 2 ku 79 */ +0x6E93,0x6EA7,0x6EB4,0x6EBF,0x6EC3,0x6ECA,0x6ED9,0x6F35, +0x6EEB,0x6EF9,0x6EFB,0x6F0A,0x6F0C,0x6F18,0x6F25,0x6F36, +0x6F3C,0x0000,0x6F52,0x6F57,0x6F5A,0x6F60,0x6F68,0x6F98, +0x6F7D,0x6F90,0x6F96,0x6FBE,0x6F9F,0x6FA5,0x6FAF,0x3D64, +0x6FB5,0x6FC8,0x6FC9,0x6FDA,0x6FDE,0x6FE9,0x0000,0x6FFC, +0x7000,0x7007,0x700A,0x7023,0x0000,0x7039,0x703A,0x703C, +0x7043,0x7047,0x704B,0x3D9A,0x7054,0x7065,0x7069,0x706C, +0x706E,0x7076,0x707E,0x7081,0x7086,0x7095,0x7097,0x70BB, +0x0000,0x709F,0x70B1,0x0000,0x70EC,0x70CA,0x70D1,0x70D3, +0x70DC,0x7103,0x7104,0x7106,0x7107,0x7108,0x710C,0x3DC0, +0x712F,0x7131,0x7150,0x714A,0x7153,0x715E,0x3DD4,0x7196, +0x7180,0x719B,0x71A0,0x71A2,0x71AE,0x71AF, +/* plane 2 ku 80 */ +0x71B3,0x0000,0x71CB,0x71D3,0x71D9,0x71DC,0x7207,0x3E05, +0xFA49,0x722B,0x7234,0x7238,0x7239,0x4E2C,0x7242,0x7253, +0x7257,0x7263,0x0000,0x726E,0x726F,0x7278,0x727F,0x728E, +0x0000,0x72AD,0x72AE,0x72B0,0x72B1,0x72C1,0x3E60,0x72CC, +0x3E66,0x3E68,0x72F3,0x72FA,0x7307,0x7312,0x7318,0x7319, +0x3E83,0x7339,0x732C,0x7331,0x7333,0x733D,0x7352,0x3E94, +0x736B,0x736C,0x0000,0x736E,0x736F,0x7371,0x7377,0x7381, +0x7385,0x738A,0x7394,0x7398,0x739C,0x739E,0x73A5,0x73A8, +0x73B5,0x73B7,0x73B9,0x73BC,0x73BF,0x73C5,0x73CB,0x73E1, +0x73E7,0x73F9,0x7413,0x73FA,0x7401,0x7424,0x7431,0x7439, +0x7453,0x7440,0x7443,0x744D,0x7452,0x745D,0x7471,0x7481, +0x7485,0x7488,0x0000,0x7492,0x7497,0x7499, +/* plane 2 ku 81 */ +0x74A0,0x74A1,0x74A5,0x74AA,0x74AB,0x74B9,0x74BB,0x74BA, +0x74D6,0x74D8,0x74DE,0x74EF,0x74EB,0x0000,0x74FA,0x0000, +0x7520,0x7524,0x752A,0x3F57,0x0000,0x753D,0x753E,0x7540, +0x7548,0x754E,0x7550,0x7552,0x756C,0x7572,0x7571,0x757A, +0x757D,0x757E,0x7581,0x0000,0x758C,0x3F75,0x75A2,0x3F77, +0x75B0,0x75B7,0x75BF,0x75C0,0x75C6,0x75CF,0x75D3,0x75DD, +0x75DF,0x75E0,0x75E7,0x75EC,0x75EE,0x75F1,0x75F9,0x7603, +0x7618,0x7607,0x760F,0x3FAE,0x0000,0x7613,0x761B,0x761C, +0x0000,0x7625,0x7628,0x763C,0x7633,0x0000,0x3FC9,0x7641, +0x0000,0x7649,0x7655,0x3FD7,0x766E,0x7695,0x769C,0x76A1, +0x76A0,0x76A7,0x76A8,0x76AF,0x0000,0x76C9,0x0000,0x76E8, +0x76EC,0x0000,0x7717,0x771A,0x772D,0x7735, +/* plane 2 ku 82 */ +0x0000,0x4039,0x0000,0x0000,0x7758,0x7760,0x776A,0x0000, +0x7772,0x777C,0x777D,0x0000,0x4058,0x779A,0x779F,0x77A2, +0x77A4,0x77A9,0x77DE,0x77DF,0x77E4,0x77E6,0x77EA,0x77EC, +0x4093,0x77F0,0x77F4,0x77FB,0x0000,0x7805,0x7806,0x7809, +0x780D,0x7819,0x7821,0x782C,0x7847,0x7864,0x786A,0x0000, +0x788A,0x7894,0x78A4,0x789D,0x789E,0x789F,0x78BB,0x78C8, +0x78CC,0x78CE,0x78D5,0x78E0,0x78E1,0x78E6,0x78F9,0x78FA, +0x78FB,0x78FE,0x0000,0x7910,0x791B,0x7930,0x7925,0x793B, +0x794A,0x7958,0x795B,0x4105,0x7967,0x7972,0x7994,0x7995, +0x7996,0x799B,0x79A1,0x79A9,0x79B4,0x79BB,0x79C2,0x79C7, +0x79CC,0x79CD,0x79D6,0x4148,0x0000,0x0000,0x414F,0x7A0A, +0x7A11,0x7A15,0x7A1B,0x7A1E,0x4163,0x7A2D, +/* plane 2 ku 83 */ +0x7A38,0x7A47,0x7A4C,0x7A56,0x7A59,0x7A5C,0x7A5F,0x7A60, +0x7A67,0x7A6A,0x7A75,0x7A78,0x7A82,0x7A8A,0x7A90,0x7AA3, +0x7AAC,0x0000,0x41B4,0x7AB9,0x7ABC,0x7ABE,0x41BF,0x7ACC, +0x7AD1,0x7AE7,0x7AE8,0x7AF4,0x0000,0x0000,0x7B07,0x0000, +0x7B3D,0x7B27,0x7B2A,0x7B2E,0x7B2F,0x7B31,0x41E6,0x41F3, +0x7B7F,0x7B41,0x41EE,0x7B55,0x7B79,0x7B64,0x7B66,0x7B69, +0x7B73,0x0000,0x4207,0x7B90,0x7B91,0x7B9B,0x420E,0x7BAF, +0x7BB5,0x7BBC,0x7BC5,0x7BCA,0x0000,0x0000,0x7BD4,0x7BD6, +0x7BDA,0x7BEA,0x7BF0,0x7C03,0x7C0B,0x7C0E,0x7C0F,0x7C26, +0x7C45,0x7C4A,0x7C51,0x7C57,0x7C5E,0x7C61,0x7C69,0x7C6E, +0x7C6F,0x7C70,0x0000,0x0000,0x0000,0x7CA6,0x0000,0x7CB6, +0x7CB7,0x7CBF,0x0000,0x7CC4,0x0000,0x7CC8, +/* plane 2 ku 84 */ +0x7CCD,0x0000,0x7CD7,0x0000,0x7CE6,0x7CEB,0x0000,0x7CF5, +0x7D03,0x7D09,0x42C6,0x7D12,0x7D1E,0x0000,0x0000,0x7D3D, +0x7D3E,0x7D40,0x7D47,0x0000,0x0000,0x42D6,0x7D59,0x7D5A, +0x7D6A,0x7D70,0x42DD,0x7D7F,0x0000,0x7D86,0x7D88,0x7D8C, +0x7D97,0x0000,0x7D9D,0x7DA7,0x7DAA,0x7DB6,0x7DB7,0x7DC0, +0x7DD7,0x7DD9,0x7DE6,0x7DF1,0x7DF9,0x4302,0x0000,0xFA58, +0x7E10,0x7E17,0x7E1D,0x7E20,0x7E27,0x7E2C,0x7E45,0x7E73, +0x7E75,0x7E7E,0x7E86,0x7E87,0x432B,0x7E91,0x7E98,0x7E9A, +0x4343,0x7F3C,0x7F3B,0x7F3E,0x7F43,0x7F44,0x7F4F,0x34C1, +0x0000,0x7F52,0x0000,0x7F61,0x7F63,0x7F64,0x7F6D,0x7F7D, +0x7F7E,0x0000,0x7F90,0x517B,0x0000,0x7F96,0x7F9C,0x7FAD, +0x0000,0x7FC3,0x7FCF,0x7FE3,0x7FE5,0x7FEF, +/* plane 2 ku 85 */ +0x7FF2,0x8002,0x800A,0x8008,0x800E,0x8011,0x8016,0x8024, +0x802C,0x8030,0x8043,0x8066,0x8071,0x8075,0x807B,0x8099, +0x809C,0x80A4,0x80A7,0x80B8,0x0000,0x80C5,0x80D5,0x80D8, +0x80E6,0x0000,0x810D,0x80F5,0x80FB,0x43EE,0x8135,0x8116, +0x811E,0x43F0,0x8124,0x8127,0x812C,0x0000,0x813D,0x4408, +0x8169,0x4417,0x8181,0x441C,0x8184,0x8185,0x4422,0x8198, +0x81B2,0x81C1,0x81C3,0x81D6,0x81DB,0x0000,0x81E4,0x0000, +0x81EC,0x0000,0x81FD,0x81FF,0x0000,0x8204,0x0000,0x8219, +0x8221,0x8222,0x0000,0x8232,0x8234,0x823C,0x8246,0x8249, +0x8245,0x0000,0x824B,0x4476,0x824F,0x447A,0x8257,0x0000, +0x825C,0x8263,0x0000,0xFA5D,0xFA5E,0x8279,0x4491,0x827D, +0x827F,0x8283,0x828A,0x8293,0x82A7,0x82A8, +/* plane 2 ku 86 */ +0x82B2,0x82B4,0x82BA,0x82BC,0x82E2,0x82E8,0x82F7,0x8307, +0x8308,0x830C,0x8354,0x831B,0x831D,0x8330,0x833C,0x8344, +0x8357,0x44BE,0x837F,0x44D4,0x44B3,0x838D,0x8394,0x8395, +0x839B,0x839D,0x83C9,0x83D0,0x83D4,0x83DD,0x83E5,0x83F9, +0x840F,0x8411,0x8415,0x0000,0x8417,0x8439,0x844A,0x844F, +0x8451,0x8452,0x8459,0x845A,0x845C,0x0000,0x8465,0x8476, +0x8478,0x847C,0x8481,0x450D,0x84DC,0x8497,0x84A6,0x84BE, +0x4508,0x84CE,0x84CF,0x84D3,0x0000,0x84E7,0x84EA,0x84EF, +0x84F0,0x84F1,0x84FA,0x84FD,0x850C,0x851B,0x8524,0x8525, +0x852B,0x8534,0x854F,0x856F,0x4525,0x4543,0x853E,0x8551, +0x8553,0x855E,0x8561,0x8562,0x0000,0x857B,0x857D,0x857F, +0x8581,0x8586,0x8593,0x859D,0x859F,0x0000, +/* plane 2 ku 87 */ +0x0000,0x0000,0x85B7,0x85BC,0x85C7,0x85CA,0x85D8,0x85D9, +0x85DF,0x85E1,0x85E6,0x85F6,0x8600,0x8611,0x861E,0x8621, +0x8624,0x8627,0x0000,0x8639,0x863C,0x0000,0x8640,0xFA20, +0x8653,0x8656,0x866F,0x8677,0x867A,0x8687,0x8689,0x868D, +0x8691,0x869C,0x869D,0x86A8,0xFA21,0x86B1,0x86B3,0x86C1, +0x86C3,0x86D1,0x86D5,0x86D7,0x86E3,0x86E6,0x45B8,0x8705, +0x8707,0x870E,0x8710,0x8713,0x8719,0x871F,0x8721,0x8723, +0x8731,0x873A,0x873E,0x8740,0x8743,0x8751,0x8758,0x8764, +0x8765,0x8772,0x877C,0x0000,0x0000,0x87A7,0x8789,0x878B, +0x8793,0x87A0,0x0000,0x45E5,0x87BE,0x0000,0x87C1,0x87CE, +0x87F5,0x87DF,0x0000,0x87E3,0x87E5,0x87E6,0x87EA,0x87EB, +0x87ED,0x8801,0x8803,0x880B,0x8813,0x8828, +/* plane 2 ku 88 */ +0x882E,0x8832,0x883C,0x460F,0x884A,0x8858,0x885F,0x8864, +0x0000,0x0000,0x8869,0x0000,0x886F,0x88A0,0x88BC,0x88BD, +0x88BE,0x88C0,0x88D2,0x0000,0x88D1,0x88D3,0x88DB,0x88F0, +0x88F1,0x4641,0x8901,0x0000,0x8937,0x0000,0x8942,0x8945, +0x8949,0x0000,0x4665,0x8962,0x8980,0x8989,0x8990,0x899F, +0x89B0,0x89B7,0x89D6,0x89D8,0x89EB,0x46A1,0x89F1,0x89F3, +0x89FD,0x89FF,0x46AF,0x8A11,0x8A14,0x0000,0x8A21,0x8A35, +0x8A3E,0x8A45,0x8A4D,0x8A58,0x8AAE,0x8A90,0x8AB7,0x8ABE, +0x8AD7,0x8AFC,0x0000,0x8B0A,0x8B05,0x8B0D,0x8B1C,0x8B1F, +0x8B2D,0x8B43,0x470C,0x8B51,0x8B5E,0x8B76,0x8B7F,0x8B81, +0x8B8B,0x8B94,0x8B95,0x8B9C,0x8B9E,0x8C39,0x0000,0x8C3D, +0x0000,0x0000,0x8C45,0x8C47,0x8C4F,0x8C54, +/* plane 2 ku 89 */ +0x8C57,0x8C69,0x8C6D,0x8C73,0x0000,0x8C93,0x8C92,0x8C99, +0x4764,0x8C9B,0x8CA4,0x8CD6,0x8CD5,0x8CD9,0x0000,0x8CF0, +0x8CF1,0x0000,0x8D09,0x8D0E,0x8D6C,0x8D84,0x8D95,0x8DA6, +0x0000,0x8DC6,0x8DC8,0x8DD9,0x8DEC,0x8E0C,0x47FD,0x8DFD, +0x8E06,0x0000,0x8E14,0x8E16,0x8E21,0x8E22,0x8E27,0x0000, +0x4816,0x8E36,0x8E39,0x8E4B,0x8E54,0x8E62,0x8E6C,0x8E6D, +0x8E6F,0x8E98,0x8E9E,0x8EAE,0x8EB3,0x8EB5,0x8EB6,0x8EBB, +0x0000,0x8ED1,0x8ED4,0x484E,0x8EF9,0x0000,0x8F00,0x8F08, +0x8F17,0x8F2B,0x8F40,0x8F4A,0x8F58,0x0000,0x8FA4,0x8FB4, +0xFA66,0x8FB6,0x0000,0x8FC1,0x8FC6,0xFA24,0x8FCA,0x8FCD, +0x8FD3,0x8FD5,0x8FE0,0x8FF1,0x8FF5,0x8FFB,0x9002,0x900C, +0x9037,0x0000,0x9043,0x9044,0x905D,0x0000, +/* plane 2 ku 90 */ +0x0000,0x9085,0x908C,0x9090,0x961D,0x90A1,0x48B5,0x90B0, +0x90B6,0x90C3,0x90C8,0x0000,0x90DC,0x90DF,0x0000,0x90F6, +0x90F2,0x9100,0x90EB,0x90FE,0x90FF,0x9104,0x9106,0x9118, +0x911C,0x911E,0x9137,0x9139,0x913A,0x9146,0x9147,0x9157, +0x9159,0x9161,0x9164,0x9174,0x9179,0x9185,0x918E,0x91A8, +0x91AE,0x91B3,0x91B6,0x91C3,0x91C4,0x91DA,0x0000,0x0000, +0x91EC,0x91EE,0x9201,0x920A,0x9216,0x9217,0x0000,0x9233, +0x9242,0x9247,0x924A,0x924E,0x9251,0x9256,0x9259,0x9260, +0x9261,0x9265,0x9267,0x9268,0x0000,0x0000,0x927C,0x927D, +0x927F,0x9289,0x928D,0x9297,0x9299,0x929F,0x92A7,0x92AB, +0x0000,0x0000,0x92B2,0x92BF,0x92C0,0x92C6,0x92CE,0x92D0, +0x92D7,0x92D9,0x92E5,0x92E7,0x9311,0x0000, +/* plane 2 ku 91 */ +0x0000,0x92F7,0x92F9,0x92FB,0x9302,0x930D,0x9315,0x931D, +0x931E,0x9327,0x9329,0x0000,0x0000,0x9347,0x9351,0x9357, +0x935A,0x936B,0x9371,0x9373,0x93A1,0x0000,0x0000,0x9388, +0x938B,0x938F,0x939E,0x93F5,0x0000,0x0000,0x93F1,0x93C1, +0x93C7,0x93DC,0x93E2,0x93E7,0x9409,0x940F,0x9416,0x9417, +0x93FB,0x9432,0x9434,0x943B,0x9445,0x0000,0x0000,0x946D, +0x946F,0x9578,0x9579,0x9586,0x958C,0x958D,0x0000,0x95AB, +0x95B4,0x0000,0x95C8,0x0000,0x0000,0x962C,0x9633,0x9634, +0x0000,0x963C,0x9641,0x9661,0x0000,0x9682,0x0000,0x969A, +0x0000,0x49E7,0x96A9,0x96AF,0x96B3,0x96BA,0x96BD,0x49FA, +0x0000,0x96D8,0x96DA,0x96DD,0x4A04,0x9714,0x9723,0x4A29, +0x9736,0x9741,0x9747,0x9755,0x9757,0x975B, +/* plane 2 ku 92 */ +0x976A,0x0000,0x0000,0x9796,0x979A,0x979E,0x97A2,0x97B1, +0x97B2,0x97BE,0x97CC,0x97D1,0x97D4,0x97D8,0x97D9,0x97E1, +0x97F1,0x9804,0x980D,0x980E,0x9814,0x9816,0x4ABC,0x0000, +0x9823,0x9832,0x9833,0x9825,0x9847,0x9866,0x98AB,0x98AD, +0x98B0,0x0000,0x98B7,0x98B8,0x98BB,0x98BC,0x98BF,0x98C2, +0x98C7,0x98CB,0x98E0,0x0000,0x98E1,0x98E3,0x98E5,0x98EA, +0x98F0,0x98F1,0x98F3,0x9908,0x4B3B,0x0000,0x9916,0x9917, +0x0000,0x991A,0x991B,0x991C,0x0000,0x9931,0x9932,0x9933, +0x993A,0x993B,0x993C,0x9940,0x9941,0x9946,0x994D,0x994E, +0x995C,0x995F,0x9960,0x99A3,0x99A6,0x99B9,0x99BD,0x99BF, +0x99C3,0x99C9,0x99D4,0x99D9,0x99DE,0x0000,0x99F0,0x99F9, +0x99FC,0x9A0A,0x9A11,0x9A16,0x9A1A,0x9A20, +/* plane 2 ku 93 */ +0x9A31,0x9A36,0x9A44,0x9A4C,0x9A58,0x4BC2,0x9AAF,0x4BCA, +0x9AB7,0x4BD2,0x9AB9,0x0000,0x9AC6,0x9AD0,0x9AD2,0x9AD5, +0x4BE8,0x9ADC,0x9AE0,0x9AE5,0x9AE9,0x9B03,0x9B0C,0x9B10, +0x9B12,0x9B16,0x9B1C,0x9B2B,0x9B33,0x9B3D,0x4C20,0x9B4B, +0x9B63,0x9B65,0x9B6B,0x9B6C,0x9B73,0x9B76,0x9B77,0x9BA6, +0x9BAC,0x9BB1,0x0000,0x0000,0x9BB2,0x9BB8,0x9BBE,0x9BC7, +0x9BF3,0x9BD8,0x9BDD,0x9BE7,0x9BEA,0x9BEB,0x9BEF,0x9BEE, +0x0000,0x9BFA,0x0000,0x9BF7,0x0000,0x9C16,0x9C18,0x9C19, +0x9C1A,0x9C1D,0x9C22,0x9C27,0x9C29,0x9C2A,0x0000,0x9C31, +0x9C36,0x9C37,0x9C45,0x9C5C,0x0000,0x9C49,0x9C4A,0x0000, +0x9C54,0x9C58,0x9C5B,0x9C5D,0x9C5F,0x9C69,0x9C6A,0x9C6B, +0x9C6D,0x9C6E,0x9C70,0x9C72,0x9C75,0x9C7A, +/* plane 2 ku 94 */ +0x9CE6,0x9CF2,0x9D0B,0x9D02,0x0000,0x9D11,0x9D17,0x9D18, +0x0000,0x4CC4,0x0000,0x9D32,0x4CD1,0x9D42,0x9D4A,0x9D5F, +0x9D62,0x0000,0x9D69,0x9D6B,0x0000,0x9D73,0x9D76,0x9D77, +0x9D7E,0x9D84,0x9D8D,0x9D99,0x9DA1,0x9DBF,0x9DB5,0x9DB9, +0x9DBD,0x9DC3,0x9DC7,0x9DC9,0x9DD6,0x9DDA,0x9DDF,0x9DE0, +0x9DE3,0x9DF4,0x4D07,0x9E0A,0x9E02,0x9E0D,0x9E19,0x9E1C, +0x9E1D,0x9E7B,0x0000,0x9E80,0x9E85,0x9E9B,0x9EA8,0x0000, +0x9EBD,0x0000,0x9EDF,0x9EE7,0x9EEE,0x9EFF,0x9F02,0x4D77, +0x9F03,0x9F17,0x9F19,0x9F2F,0x9F37,0x9F3A,0x9F3D,0x9F41, +0x9F45,0x9F46,0x9F53,0x9F55,0x9F58,0x0000,0x9F5D,0x0000, +0x9F69,0x0000,0x9F6D,0x9F70,0x9F75,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,}; + +const int jisx0213_ucs_table_size = (sizeof(jisx0213_ucs_table)/sizeof(unsigned short)); + + +const unsigned short ucs_a1_jisx0213_table[] = { // 0x0000 - 0x045f + +/* 0000h */ +0x0000,0x0001,0x0002,0x0003,0x0004,0x0005,0x0006,0x0007, +0x0008,0x0009,0x000A,0x000B,0x000C,0x000D,0x000E,0x000F, +0x0010,0x0011,0x0012,0x0013,0x0014,0x0015,0x0016,0x0017, +0x0018,0x0019,0x001A,0x001B,0x001C,0x001D,0x001E,0x001F, +0x0020,0x0021,0x0022,0x0023,0x0024,0x0025,0x0026,0x0027, +0x0028,0x0029,0x002A,0x002B,0x002C,0x002D,0x002E,0x002F, +0x0030,0x0031,0x0032,0x0033,0x0034,0x0035,0x0036,0x0037, +0x0038,0x0039,0x003A,0x003B,0x003C,0x003D,0x003E,0x003F, +0x0040,0x0041,0x0042,0x0043,0x0044,0x0045,0x0046,0x0047, +0x0048,0x0049,0x004A,0x004B,0x004C,0x004D,0x004E,0x004F, +0x0050,0x0051,0x0052,0x0053,0x0054,0x0055,0x0056,0x0057, +0x0058,0x0059,0x005A,0x005B,0x005C,0x005D,0x005E,0x005F, +0x0060,0x0061,0x0062,0x0063,0x0064,0x0065,0x0066,0x0067, +0x0068,0x0069,0x006A,0x006B,0x006C,0x006D,0x006E,0x006F, +0x0070,0x0071,0x0072,0x0073,0x0074,0x0075,0x0076,0x0077, +0x0078,0x0079,0x007A,0x007B,0x007C,0x007D,0x007E,0x007F, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2922,0x2923,0x2171,0x2172,0x2924,0x005C,0x2925,0x2178, +0x212F,0x2926,0x2927,0x2928,0x224C,0x2929,0x292A,0x292B, +0x216B,0x215E,0x292C,0x292D,0x212D,0x0000,0x2279,0x292E, +0x292F,0x2930,0x2931,0x2932,0x2933,0x2934,0x2935,0x2936, +0x2937,0x2938,0x2939,0x293A,0x293B,0x293C,0x293D,0x293E, +0x293F,0x2940,0x2941,0x2942,0x2943,0x2944,0x2945,0x2946, +0x2947,0x2948,0x2949,0x294A,0x294B,0x294C,0x294D,0x215F, +0x294E,0x294F,0x2950,0x2951,0x2952,0x2953,0x2954,0x2955, +0x2956,0x2957,0x2958,0x2959,0x295A,0x295B,0x295C,0x295D, +0x295E,0x295F,0x2960,0x2961,0x2962,0x2963,0x2964,0x2965, +0x2966,0x2967,0x2968,0x2969,0x296A,0x296B,0x296C,0x2160, +0x296D,0x296E,0x296F,0x2970,0x2971,0x2972,0x2973,0x2974, + +/* 0100h */ +0x2975,0x297A,0x2A3A,0x2A49,0x2A21,0x2A2C,0x2A3C,0x2A4B, +0x2A59,0x2A5F,0x0000,0x0000,0x2A3D,0x2A4C,0x2A40,0x2A4F, +0x0000,0x2A50,0x2978,0x297D,0x0000,0x0000,0x0000,0x0000, +0x2A3E,0x2A4D,0x2A3F,0x2A4E,0x2A5A,0x2A60,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x2A5B,0x2A61,0x0000,0x2A7D, +0x0000,0x0000,0x2976,0x297B,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x2A5C,0x2A62,0x0000,0x0000, +0x0000,0x2A3B,0x2A4A,0x0000,0x0000,0x2A24,0x2A2F,0x0000, +0x0000,0x2A23,0x2A2E,0x2A41,0x2A51,0x0000,0x0000,0x2A42, +0x2A52,0x0000,0x0000,0x2A7A,0x2979,0x297E,0x0000,0x0000, +0x2A43,0x2A53,0x2B2B,0x2B2A,0x2A39,0x2A48,0x0000,0x0000, +0x2A44,0x2A54,0x2A25,0x2A30,0x2A5D,0x2A63,0x2A27,0x2A33, +0x2A26,0x2A32,0x2A47,0x2A57,0x2A28,0x2A34,0x0000,0x0000, +0x0000,0x0000,0x2977,0x297C,0x2A5E,0x2A64,0x2A45,0x2A55, +0x2A46,0x2A56,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x2A29,0x2A35,0x2A2B,0x2A38,0x2A2A,0x2A37,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2B29,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x2B24,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x286F,0x2870,0x0000, +0x2871,0x2876,0x2877,0x0000,0x2878,0x0000,0x2879,0x0000, +0x287A,0x0000,0x287B,0x0000,0x287C,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2874,0x2875,0x0000,0x0000,0x0000,0x2B45,0x0000,0x0000, + +/* 0200h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2B33,0x2B39,0x2B3A,0x2B25,0x2B38,0x2B3F,0x2A6E,0x2B26, +0x2B2E,0x2B30,0x2B43,0x0000,0x2B31,0x0000,0x2B32,0x2A75, +0x2B28,0x2A79,0x0000,0x0000,0x2B36,0x2B3C,0x2B22,0x2B42, +0x2B2C,0x0000,0x0000,0x0000,0x2A6A,0x2A74,0x2A6B,0x2B34, +0x2A7B,0x2A65,0x2A76,0x2A6F,0x0000,0x2B2F,0x0000,0x0000, +0x0000,0x2A6C,0x2B41,0x2A73,0x0000,0x2A70,0x2A67,0x0000, +0x0000,0x2A7C,0x2A71,0x2A68,0x2B27,0x0000,0x0000,0x0000, +0x2A6D,0x2B2D,0x2B35,0x2A66,0x2B37,0x2B3B,0x2A78,0x0000, +0x2A72,0x2B40,0x2A69,0x0000,0x2B21,0x2A7E,0x0000,0x0000, +0x2B23,0x0000,0x0000,0x0000,0x0000,0x2A77,0x0000,0x0000, +0x0000,0x2B3E,0x2B3D,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x2A31, +0x2B53,0x0000,0x0000,0x0000,0x2B54,0x0000,0x0000,0x0000, +0x2B55,0x2B56,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2A22,0x2A58,0x0000,0x2A2D,0x0000,0x2A36,0x2B71,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x2B60,0x2B61,0x2B62, +0x2B63,0x2B64,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 0300h */ +0x2B5C,0x2B5A,0x2B5F,0x2B7D,0x2B5B,0x0000,0x2B57,0x0000, +0x2B6D,0x0000,0x0000,0x2B59,0x2B5E,0x0000,0x0000,0x2B5D, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2B78,0x2B79,0x2B7E,0x0000,0x2B6A,0x2B76,0x2B77,0x2B6B, +0x2B6C,0x0000,0x0000,0x0000,0x2B72,0x2B67,0x0000,0x0000, +0x0000,0x2B6F,0x2B7A,0x0000,0x2B68,0x0000,0x0000,0x2B70, +0x2B73,0x0000,0x0000,0x0000,0x2B75,0x0000,0x0000,0x0000, +0x0000,0x2B69,0x2B7B,0x2B7C,0x2B74,0x2B6E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x2B52,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x2621,0x2622,0x2623,0x2624,0x2625,0x2626,0x2627, +0x2628,0x2629,0x262A,0x262B,0x262C,0x262D,0x262E,0x262F, +0x2630,0x2631,0x0000,0x2632,0x2633,0x2634,0x2635,0x2636, +0x2637,0x2638,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x2641,0x2642,0x2643,0x2644,0x2645,0x2646,0x2647, +0x2648,0x2649,0x264A,0x264B,0x264C,0x264D,0x264E,0x264F, +0x2650,0x2651,0x2659,0x2652,0x2653,0x2654,0x2655,0x2656, +0x2657,0x2658,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 0400h */ +0x0000,0x2727,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2721,0x2722,0x2723,0x2724,0x2725,0x2726,0x2728,0x2729, +0x272A,0x272B,0x272C,0x272D,0x272E,0x272F,0x2730,0x2731, +0x2732,0x2733,0x2734,0x2735,0x2736,0x2737,0x2738,0x2739, +0x273A,0x273B,0x273C,0x273D,0x273E,0x273F,0x2740,0x2741, +0x2751,0x2752,0x2753,0x2754,0x2755,0x2756,0x2758,0x2759, +0x275A,0x275B,0x275C,0x275D,0x275E,0x275F,0x2760,0x2761, +0x2762,0x2763,0x2764,0x2765,0x2766,0x2767,0x2768,0x2769, +0x276A,0x276B,0x276C,0x276D,0x276E,0x276F,0x2770,0x2771, +0x0000,0x2757,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +}; + +const int ucs_a1_jisx0213_table_min = 0x0000; +const int ucs_a1_jisx0213_table_max = 0x0000 + + (sizeof(ucs_a1_jisx0213_table)/sizeof(unsigned short)); + +const unsigned short ucs_i_jisx0213_table[] = { // 0x4e00 - 0x9fff + +/* 4E00h */ +0x306C,0x437A,0x7F22,0x3C37,0x0000,0x0000,0x0000,0x4B7C, +0x3E66,0x3B30,0x3E65,0x323C,0x0000,0x4954,0x4D3F,0x7F23, +0x5022,0x312F,0x7F24,0x0000,0x336E,0x5023,0x4024,0x5242, +0x3556,0x4A3A,0x0000,0x0000,0x0000,0x0000,0x3E67,0x0000, +0x0000,0x4E3E,0x0000,0x0000,0x0000,0x0000,0x4A42,0x0000, +0x2E24,0x7F25,0x5024,0x7F26,0x8A2E,0x4366,0x7F27,0x2E25, +0x2E26,0x5025,0x367A,0x0000,0x0000,0x0000,0x5026,0x0000, +0x345D,0x4330,0x0000,0x3C67,0x5027,0x0000,0x0000,0x5028, +0x7F28,0x0000,0x5029,0x4735,0x0000,0x3557,0x0000,0x7F29, +0x7F2A,0x0000,0x0000,0x4737,0x0000,0x4663,0x3843,0x4B33, +0x0000,0x7F2C,0x0000,0x0000,0x0000,0x6949,0x502A,0x3E68, +0x502B,0x3235,0x7F2F,0x0000,0x0000,0x3665,0x3870,0x4C69, +0x0000,0x0000,0x5626,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x7F30,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4D70,0x0000,0x467D,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3425,0x0000, +0x3535,0x0000,0x502C,0x0000,0x0000,0x502D,0x4E3B,0x0000, +0x4D3D,0x4168,0x502F,0x3B76,0x4673,0x2E27,0x5032,0x0000, +0x0000,0x313E,0x385F,0x0000,0x385E,0x3066,0x0000,0x0000, +0x4F4B,0x4F4A,0x0000,0x3A33,0x3021,0x7F31,0x5033,0x5034, +0x5035,0x4B34,0x5036,0x0000,0x3872,0x3067,0x4B72,0x0000, +0x357C,0x0000,0x0000,0x357D,0x357E,0x4462,0x4E3C,0x0000, +0x5037,0x0000,0x0000,0x5038,0x0000,0x0000,0x5039,0x0000, +0x0000,0x7F34,0x3F4D,0x7F35,0x7F37,0x0000,0x0000,0x0000, +0x3D3A,0x3F4E,0x503E,0x7F38,0x503C,0x0000,0x503D,0x3558, +0x7F39,0x0000,0x3A23,0x3270,0x0000,0x503B,0x503A,0x4A29, +0x7F3A,0x0000,0x0000,0x0000,0x3B46,0x3B45,0x423E,0x503F, +0x4955,0x4067,0x7F3C,0x0000,0x0000,0x2138,0x5040,0x5042, +0x0000,0x2E28,0x0000,0x4265,0x4E61,0x304A,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7F3B,0x0000,0x5041,0x323E,0x0000, +0x3644,0x7F3D,0x4367,0x0000,0x0000,0x7F3E,0x376F,0x5043, +0x0000,0x0000,0x0000,0x4724,0x0000,0x2E29,0x0000,0x2E2A, + +/* 4F00h */ +0x7F3F,0x346B,0x0000,0x2E2B,0x0000,0x0000,0x0000,0x0000, +0x0000,0x5044,0x304B,0x2E2C,0x0000,0x3860,0x346C,0x497A, +0x4832,0x3559,0x0000,0x0000,0x0000,0x0000,0x7F40,0x0000, +0x0000,0x0000,0x3271,0x0000,0x5067,0x4541,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x476C, +0x5046,0x0000,0x0000,0x0000,0x483C,0x0000,0x4E62,0x7F42, +0x3F2D,0x0000,0x3B47,0x0000,0x3B77,0x3240,0x7F43,0x0000, +0x0000,0x0000,0x0000,0x4451,0x0000,0x0000,0x4322,0x504A, +0x2E2E,0x2E2F,0x0000,0x0000,0x0000,0x304C,0x4463,0x3D3B, +0x3A34,0x4D24,0x0000,0x424E,0x7F44,0x323F,0x2E30,0x5049, +0x7F45,0x4D3E,0x5045,0x5047,0x3A6E,0x5048,0x5524,0x2E31, +0x2E2D,0x0000,0x0000,0x0000,0x7F41,0x0000,0x0000,0x0000, +0x0000,0x5050,0x2E32,0x0000,0x2E33,0x0000,0x0000,0x5053, +0x5051,0x0000,0x0000,0x3242,0x0000,0x4A3B,0x504B,0x7F47, +0x7F48,0x0000,0x7F49,0x504F,0x3873,0x7F4A,0x2E34,0x3B48, +0x0000,0x0000,0x7F4B,0x3426,0x0000,0x7F4C,0x5054,0x0000, +0x504C,0x0000,0x2E35,0x4E63,0x0000,0x3B78,0x0000,0x504D, +0x0000,0x5052,0x7F4D,0x0000,0x2E36,0x0000,0x5055,0x2E37, +0x504E,0x0000,0x7F4E,0x3621,0x0000,0x304D,0x0000,0x0000, +0x3622,0x3241,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x5525,0x0000,0x4B79,0x496E,0x3874, +0x0000,0x0000,0x7F50,0x0000,0x0000,0x3F2F,0x4E37,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7F51,0x4A58, +0x0000,0x0000,0x3738,0x4225,0x3264,0x7F52,0x0000,0x0000, +0x0000,0x2E39,0x3D53,0x7F53,0x0000,0x0000,0x5059,0x7F54, +0x505E,0x505C,0x7F55,0x0000,0x5057,0x0000,0x0000,0x422F, +0x505A,0x0000,0x505D,0x505B,0x0000,0x4A5D,0x0000,0x5058, +0x2E3A,0x3F2E,0x0000,0x4B73,0x505F,0x5060,0x7F4F,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3D24,0x506D, +0x0000,0x2E21,0x7F57,0x4750,0x0000,0x4936,0x5068,0x0000, +0x4A70,0x0000,0x3236,0x0000,0x0000,0x0000,0x506C,0x0000, + +/* 5000h */ +0x7F58,0x2E3B,0x2E3C,0x0000,0x0000,0x5066,0x506F,0x0000, +0x0000,0x4152,0x0000,0x3844,0x0000,0x475C,0x2E3D,0x6047, +0x7F59,0x506E,0x455D,0x7F5A,0x5063,0x0000,0x3876,0x0000, +0x2E3E,0x3875,0x5061,0x0000,0x7F5B,0x0000,0x7F5C,0x3C5A, +0x0000,0x5069,0x7F5D,0x4A6F,0x434D,0x5065,0x3771,0x2E3F, +0x5062,0x506A,0x5064,0x4E51,0x506B,0x4F41,0x2E40,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3666,0x0000, +0x0000,0x3770,0x0000,0x2E42,0x0000,0x0000,0x0000,0x0000, +0x2E41,0x2E43,0x7F5F,0x5070,0x0000,0x0000,0x7F60,0x5071, +0x5075,0x304E,0x0000,0x0000,0x0000,0x0000,0x7F61,0x4A50, +0x5074,0x0000,0x0000,0x7F62,0x0000,0x5073,0x5077,0x7F63, +0x0000,0x0000,0x5076,0x0000,0x4464,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7F64,0x0000,0x3772,0x7F65,0x0000, +0x0000,0x0000,0x7F66,0x0000,0x5078,0x0000,0x0000,0x0000, +0x7F67,0x0000,0x3C45,0x0000,0x4226,0x4465,0x3676,0x0000, +0x5079,0x0000,0x0000,0x0000,0x0000,0x3536,0x0000,0x0000, +0x507A,0x0000,0x0000,0x0000,0x0000,0x507C,0x0000,0x0000, +0x7F69,0x0000,0x0000,0x0000,0x0000,0x4B35,0x0000,0x0000, +0x0000,0x3766,0x7F6A,0x7F6B,0x2E44,0x7F6C,0x7F6D,0x0000, +0x3B31,0x4877,0x507B,0x0000,0x7F6E,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7F68,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7F6F,0x0000,0x3A45,0x4D43,0x0000,0x0000, +0x0000,0x7F71,0x507E,0x5123,0x507D,0x3A44,0x0000,0x3D7D, +0x0000,0x0000,0x7F72,0x7F73,0x0000,0x0000,0x3739,0x0000, +0x0000,0x0000,0x5124,0x0000,0x7F74,0x364F,0x0000,0x7F75, +0x0000,0x5121,0x5122,0x0000,0x2E45,0x462F,0x7F78,0x417C, +0x2E47,0x3623,0x0000,0x0000,0x7F7A,0x4B4D,0x5125,0x0000, +0x0000,0x7F7B,0x4E3D,0x0000,0x0000,0x0000,0x5126,0x0000, +0x0000,0x7F7C,0x0000,0x5129,0x0000,0x5127,0x2E48,0x414E, +0x0000,0x7F7D,0x0000,0x0000,0x0000,0x5128,0x512A,0x0000, +0x0000,0x0000,0x2E46,0x7F76,0x0000,0x512C,0x0000,0x0000, +0x0000,0x512B,0x0000,0x4A48,0x0000,0x0000,0x0000,0x0000, + +/* 5100h */ +0x3537,0x512E,0x512F,0x2E4B,0x322F,0x0000,0x2E4A,0x0000, +0x8121,0x512D,0x0000,0x2E4C,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x3C74,0x0000,0x5132,0x5131,0x5130,0x8123, +0x5056,0x0000,0x5133,0x8124,0x0000,0x0000,0x2E4D,0x3D7E, +0x0000,0x5134,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4D25,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4C59,0x0000,0x0000,0x2E4E,0x0000,0x5136, +0x0000,0x0000,0x5135,0x5138,0x5137,0x0000,0x0000,0x5139, +0x513A,0x3074,0x0000,0x3835,0x373B,0x3D3C,0x437B,0x3624, +0x4068,0x3877,0x2E4F,0x396E,0x513C,0x4C48,0x4546,0x0000, +0x3B79,0x0000,0x513B,0x0000,0x513D,0x2E51,0x0000,0x2E52, +0x0000,0x0000,0x455E,0x0000,0x3375,0x0000,0x0000,0x0000, +0x8126,0x0000,0x513E,0x0000,0x0000,0x467E,0x0000,0x0000, +0x4134,0x5140,0x5141,0x482C,0x3878,0x4F3B,0x5142,0x0000, +0x0000,0x3626,0x0000,0x8128,0x0000,0x4A3C,0x4236,0x3671, +0x4535,0x0000,0x0000,0x8E74,0x3773,0x0000,0x0000,0x0000, +0x5143,0x0000,0x5144,0x8129,0x0000,0x4662,0x315F,0x0000, +0x0000,0x5147,0x3A7D,0x812A,0x5146,0x3A46,0x0000,0x5148, +0x666E,0x5149,0x4B41,0x514A,0x0000,0x514B,0x514C,0x3E69, +0x812C,0x3C4C,0x0000,0x0000,0x0000,0x2E54,0x0000,0x0000, +0x3427,0x0000,0x514F,0x812D,0x514D,0x4C3D,0x514E,0x0000, +0x495A,0x5150,0x5151,0x5152,0x455F,0x812E,0x0000,0x0000, +0x5156,0x5154,0x5155,0x5153,0x3A63,0x5157,0x4C6A,0x4E64, +0x0000,0x0000,0x0000,0x0000,0x8130,0x5158,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2E55,0x4028,0x5159,0x3D5A,0x0000, +0x0000,0x515A,0x2E56,0x437C,0x4E3F,0x4560,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5245,0x0000, +0x0000,0x0000,0x0000,0x515B,0x7425,0x3645,0x2E57,0x0000, +0x515C,0x4B5E,0x2E58,0x0000,0x0000,0x0000,0x3D68,0x427C, +0x0000,0x515E,0x4664,0x0000,0x0000,0x515F,0x2E59,0x0000, +0x5160,0x332E,0x0000,0x8133,0x8134,0x5161,0x3627,0x0000, +0x464C,0x317A,0x3D50,0x0000,0x0000,0x4821,0x5162,0x0000, + +/* 5200h */ +0x4561,0x2E5A,0x8135,0x3F4F,0x5163,0x0000,0x4A2C,0x405A, +0x3422,0x0000,0x3429,0x5164,0x0000,0x0000,0x5166,0x0000, +0x0000,0x373A,0x8136,0x2E5C,0x5165,0x2E5D,0x8137,0x4E73, +0x0000,0x0000,0x0000,0x0000,0x0000,0x3D69,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x483D,0x4A4C,0x0000,0x5167, +0x0000,0x4D78,0x5168,0x0000,0x0000,0x0000,0x5169,0x0000, +0x457E,0x0000,0x0000,0x516A,0x0000,0x0000,0x4029,0x3A7E, +0x3774,0x516B,0x3B49,0x396F,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x4466,0x516D,0x0000,0x0000,0x4227, +0x0000,0x2E5E,0x3A6F,0x516E,0x516F,0x4130,0x0000,0x516C, +0x0000,0x0000,0x0000,0x0000,0x5171,0x8139,0x4B36,0x2E5F, +0x0000,0x0000,0x0000,0x3964,0x813A,0x2F7E,0x5170,0x0000, +0x0000,0x2E60,0x0000,0x3775,0x3A5E,0x476D,0x0000,0x0000, +0x0000,0x5174,0x5172,0x0000,0x813B,0x0000,0x0000,0x497B, +0x3E6A,0x517B,0x3364,0x5175,0x5173,0x414F,0x0000,0x813C, +0x0000,0x0000,0x0000,0x0000,0x0000,0x5177,0x0000,0x5176, +0x0000,0x0000,0x813E,0x3344,0x813D,0x0000,0x0000,0x3760, +0x517C,0x4E2D,0x0000,0x0000,0x0000,0x5178,0x0000,0x0000, +0x0000,0x517D,0x517A,0x2E61,0x5179,0x0000,0x0000,0x0000, +0x8140,0x0000,0x0000,0x4E4F,0x0000,0x0000,0x0000,0x3879, +0x3243,0x0000,0x0000,0x4E74,0x8142,0x0000,0x8143,0x0000, +0x0000,0x3D75,0x4558,0x3965,0x5222,0x5223,0x0000,0x8144, +0x0000,0x4E65,0x0000,0x0000,0x4F2B,0x5225,0x0000,0x0000, +0x0000,0x387A,0x8145,0x8146,0x5224,0x0000,0x332F,0x0000, +0x0000,0x5226,0x0000,0x4B56,0x0000,0x443C,0x0000,0x4D26, +0x2E62,0x4A59,0x8147,0x0000,0x2E64,0x5227,0x0000,0x0000, +0x2E65,0x8149,0x7055,0x0000,0x0000,0x4630,0x2E66,0x5228, +0x342A,0x4C33,0x0000,0x2E67,0x0000,0x3E21,0x5229,0x4A67, +0x522D,0x0000,0x402A,0x522A,0x3650,0x0000,0x522B,0x342B, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2E69,0x0000,0x372E,0x522E,0x0000,0x522F,0x0000,0x814B, +0x5230,0x5231,0x3C5B,0x2E6A,0x0000,0x0000,0x387B,0x4C5E, + +/* 5300h */ +0x2E6B,0x4C68,0x4677,0x0000,0x0000,0x4A71,0x5232,0x2E6C, +0x5233,0x0000,0x814C,0x814D,0x0000,0x5235,0x0000,0x5237, +0x5236,0x0000,0x0000,0x0000,0x0000,0x5238,0x323D,0x4B4C, +0x0000,0x3A7C,0x5239,0x0000,0x2E6D,0x4159,0x0000,0x0000, +0x3E22,0x3629,0x0000,0x523A,0x814E,0x0000,0x0000,0x0000, +0x0000,0x0000,0x485B,0x0000,0x0000,0x0000,0x0000,0x523B, +0x0000,0x523C,0x0000,0x523D,0x0000,0x814F,0x0000,0x0000, +0x523E,0x4924,0x3668,0x3065,0x0000,0x0000,0x8150,0x463F, +0x523F,0x3D3D,0x8151,0x4069,0x0000,0x5241,0x5240,0x3E23, +0x3861,0x5243,0x483E,0x0000,0x0000,0x5244,0x0000,0x0000, +0x0000,0x485C,0x4234,0x426E,0x3628,0x0000,0x0000,0x466E, +0x4331,0x0000,0x476E,0x0000,0x4B4E,0x0000,0x5246,0x0000, +0x406A,0x2E6F,0x0000,0x2E70,0x0000,0x0000,0x3735,0x8154, +0x0000,0x5247,0x0000,0x0000,0x8155,0x0000,0x5248,0x312C, +0x3075,0x346D,0x0000,0x4228,0x3551,0x4D71,0x0000,0x524B, +0x3237,0x0000,0x8156,0x524A,0x0000,0x2E71,0x0000,0x362A, +0x0000,0x0000,0x524C,0x0000,0x4C71,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2E72,0x0000,0x0000,0x524D,0x0000, +0x4E52,0x0000,0x387C,0x0000,0x0000,0x2E73,0x0000,0x3836, +0x524E,0x0000,0x0000,0x0000,0x8157,0x5250,0x524F,0x0000, +0x3F5F,0x3139,0x0000,0x0000,0x0000,0x315E,0x5251,0x0000, +0x5252,0x0000,0x2E74,0x3837,0x8158,0x0000,0x5253,0x815A, +0x0000,0x0000,0x0000,0x356E,0x0000,0x0000,0x0000,0x0000, +0x815B,0x0000,0x3B32,0x5254,0x0000,0x0000,0x0000,0x0000, +0x4B74,0x3A35,0x355A,0x4D27,0x4150,0x483F,0x3C7D,0x0000, +0x0000,0x0000,0x0000,0x0000,0x3D47,0x815F,0x3C68,0x3C75, +0x0000,0x3D76,0x8160,0x4840,0x0000,0x0000,0x0000,0x5257, +0x0000,0x3143,0x4151,0x387D,0x3845,0x3667,0x0000,0x0000, +0x525B,0x4321,0x427E,0x362B,0x3E24,0x525C,0x525A,0x3244, +0x4266,0x3C38,0x3B4B,0x3126,0x8162,0x8163,0x3370,0x3966, +0x3B4A,0x0000,0x525D,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 5400h */ +0x0000,0x525E,0x0000,0x3549,0x3346,0x0000,0x0000,0x0000, +0x3967,0x3548,0x445F,0x3125,0x4631,0x4C3E,0x3921,0x4D79, +0x4547,0x387E,0x2E75,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x372F,0x0000,0x5267,0x4F7E,0x3663, +0x4B4A,0x0000,0x0000,0x0000,0x8165,0x0000,0x485D,0x2E76, +0x8166,0x5266,0x0000,0x345E,0x5261,0x5262,0x5264,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5265,0x0000, +0x355B,0x3F61,0x0000,0x4A2D,0x5263,0x525F,0x3863,0x0000, +0x5260,0x0000,0x4F24,0x8168,0x0000,0x0000,0x4A72,0x0000, +0x4468,0x3862,0x3970,0x0000,0x0000,0x2E77,0x5268,0x0000, +0x0000,0x465D,0x0000,0x0000,0x0000,0x8164,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x526C, +0x0000,0x0000,0x8169,0x0000,0x0000,0x0000,0x816A,0x0000, +0x3C7E,0x0000,0x3C76,0x2E79,0x816B,0x0000,0x0000,0x0000, +0x526F,0x526D,0x0000,0x4C23,0x2E7A,0x526A,0x5273,0x526E, +0x0000,0x0000,0x0000,0x5271,0x3846,0x4C3F,0x0000,0x2E7B, +0x5272,0x0000,0x0000,0x0000,0x5274,0x0000,0x5276,0x0000, +0x2E7C,0x0000,0x816C,0x3A70,0x4F42,0x816D,0x526B,0x5269, +0x5275,0x0000,0x5270,0x0000,0x0000,0x816E,0x2E7D,0x0000, +0x0000,0x0000,0x0000,0x0000,0x2E78,0x0000,0x0000,0x0000, +0x816F,0x2E7E,0x5278,0x0000,0x5323,0x527A,0x8170,0x0000, +0x527E,0x2F21,0x0000,0x5321,0x527B,0x8171,0x8172,0x533E, +0x0000,0x0000,0x3A69,0x3331,0x0000,0x0000,0x0000,0x8173, +0x5279,0x0000,0x8174,0x0000,0x5325,0x3076,0x5324,0x8175, +0x3025,0x494A,0x5322,0x8176,0x527C,0x0000,0x2F22,0x5277, +0x527D,0x3A48,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5326,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3077,0x532F,0x0000,0x0000,0x5327,0x5328,0x0000, +0x3E25,0x4B69,0x0000,0x0000,0x8178,0x532D,0x532C,0x8179, +0x0000,0x817A,0x452F,0x817B,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x532E,0x0000,0x0000,0x532B,0x0000,0x2F23, + +/* 5500h */ +0x817C,0x817D,0x0000,0x0000,0x3134,0x0000,0x3A36,0x3F30, +0x0000,0x817E,0x0000,0x0000,0x0000,0x0000,0x2F24,0x5329, +0x4562,0x0000,0x0000,0x0000,0x532A,0x0000,0x3022,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2F25,0x0000,0x0000,0x5334,0x4D23, +0x0000,0x3E27,0x0000,0x533A,0x0000,0x2F26,0x0000,0x0000, +0x5339,0x5330,0x0000,0x0000,0x8221,0x0000,0x4243,0x0000, +0x5331,0x8222,0x0000,0x0000,0x426F,0x5336,0x3E26,0x8224, +0x0000,0x0000,0x8225,0x0000,0x5333,0x0000,0x0000,0x4C64, +0x2F27,0x0000,0x0000,0x373C,0x0000,0x0000,0x5337,0x5338, +0x0000,0x0000,0x0000,0x0000,0x5335,0x533B,0x2F28,0x0000, +0x8227,0x8228,0x0000,0x5332,0x8229,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x5341,0x5346,0x822B,0x5342,0x0000, +0x533D,0x2F29,0x822C,0x5347,0x4131,0x0000,0x2F2A,0x5349, +0x822D,0x3922,0x533F,0x437D,0x0000,0x0000,0x2F2B,0x0000, +0x0000,0x822E,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5343,0x533C,0x342D,0x0000,0x346E,0x3365,0x5344,0x5340, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3776, +0x534A,0x5348,0x4153,0x354A,0x362C,0x2F2D,0x5345,0x0000, +0x3674,0x0000,0x0000,0x0000,0x0000,0x0000,0x3144,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x8233, +0x0000,0x0000,0x0000,0x0000,0x534E,0x534C,0x0000,0x5427, +0x0000,0x8234,0x0000,0x0000,0x8235,0x0000,0x2F2E,0x0000, +0x0000,0x8236,0x8230,0x0000,0x5351,0x0000,0x0000,0x0000, +0x0000,0x0000,0x534B,0x0000,0x534F,0x8237,0x0000,0x534D, +0x0000,0x0000,0x8239,0x3B4C,0x5350,0x0000,0x0000,0x0000, +0x0000,0x823B,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5353, +0x0000,0x5358,0x0000,0x0000,0x0000,0x5356,0x5355,0x0000, + +/* 5600h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4332,0x823E, +0x2F30,0x3245,0x0000,0x0000,0x0000,0x0000,0x2F31,0x0000, +0x823F,0x0000,0x0000,0x0000,0x5352,0x0000,0x5354,0x3E28, +0x3133,0x0000,0x0000,0x5357,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x823C,0x325E,0x0000,0x0000,0x0000,0x0000,0x0000,0x5362, +0x8240,0x3E7C,0x535E,0x0000,0x535C,0x0000,0x535D,0x8241, +0x535F,0x0000,0x0000,0x2F32,0x0000,0x8243,0x0000,0x8244, +0x8245,0x0000,0x313D,0x0000,0x0000,0x0000,0x0000,0x8246, +0x0000,0x2F33,0x0000,0x0000,0x4139,0x0000,0x5359,0x0000, +0x535A,0x0000,0x0000,0x7427,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x337A,0x0000,0x0000,0x8247,0x0000, +0x8248,0x0000,0x0000,0x0000,0x5361,0x0000,0x2F35,0x0000, +0x346F,0x0000,0x5364,0x5360,0x5363,0x8249,0x0000,0x2F37, +0x0000,0x2F38,0x2F39,0x0000,0x4A2E,0x0000,0x2F34,0x0000, +0x4655,0x0000,0x4838,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5366,0x0000,0x0000,0x0000,0x0000,0x0000,0x5365,0x3345, +0x824B,0x0000,0x5367,0x0000,0x824C,0x0000,0x0000,0x536A, +0x0000,0x0000,0x0000,0x0000,0x5369,0x824D,0x0000,0x0000, +0x0000,0x2F3A,0x824E,0x0000,0x0000,0x824F,0x2F3B,0x0000, +0x5368,0x0000,0x4739,0x0000,0x0000,0x536B,0x0000,0x0000, +0x8250,0x2F3C,0x0000,0x0000,0x2F3D,0x8251,0x536C,0x0000, +0x0000,0x0000,0x8252,0x2F3E,0x536E,0x0000,0x536D,0x0000, +0x0000,0x0000,0x0000,0x0000,0x5370,0x0000,0x0000,0x0000, +0x5373,0x5371,0x536F,0x5372,0x0000,0x8253,0x0000,0x0000, +0x5374,0x2F3F,0x2F40,0x0000,0x0000,0x8254,0x5375,0x0000, +0x0000,0x5376,0x0000,0x5377,0x0000,0x0000,0x0000,0x5378, +0x5145,0x0000,0x3C7C,0x3B4D,0x0000,0x0000,0x3273,0x8255, +0x3078,0x0000,0x0000,0x4344,0x0000,0x0000,0x0000,0x0000, +0x8256,0x0000,0x0000,0x0000,0x0000,0x0000,0x5379,0x0000, +0x3A24,0x0000,0x304F,0x3F5E,0x0000,0x0000,0x8257,0x8258, +0x0000,0x537A,0x3847,0x0000,0x0000,0x3971,0x0000,0x537C, + +/* 5700h */ +0x537B,0x0000,0x0000,0x4A60,0x537D,0x0000,0x0000,0x0000, +0x5421,0x537E,0x2F41,0x5422,0x0000,0x5423,0x0000,0x3777, +0x0000,0x0000,0x3160,0x5424,0x0000,0x825A,0x5426,0x0000, +0x5425,0x0000,0x0000,0x0000,0x5428,0x0000,0x0000,0x455A, +0x0000,0x2F43,0x0000,0x825B,0x0000,0x0000,0x5429,0x3035, +0x3A5F,0x825D,0x0000,0x0000,0x0000,0x373D,0x0000,0x2F44, +0x434F,0x0000,0x0000,0x2F45,0x2F46,0x0000,0x0000,0x542A, +0x542B,0x0000,0x0000,0x542D,0x0000,0x0000,0x0000,0x0000, +0x542E,0x0000,0x3A64,0x0000,0x0000,0x825F,0x8260,0x3651, +0x0000,0x0000,0x4B37,0x0000,0x8261,0x8262,0x542C,0x542F, +0x3A41,0x3923,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x5433,0x0000,0x0000,0x3A25,0x0000,0x4333,0x0000, +0x8264,0x5430,0x445A,0x0000,0x0000,0x0000,0x0000,0x8265, +0x2F47,0x0000,0x0000,0x8266,0x8267,0x8268,0x0000,0x2F48, +0x0000,0x0000,0x0000,0x8269,0x2F49,0x0000,0x0000,0x5434, +0x0000,0x0000,0x3F62,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5432,0x5435,0x0000,0x373F,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x5436,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x826D,0x0000,0x2F4A,0x826E,0x826F,0x0000, +0x5437,0x0000,0x3924,0x3340,0x5439,0x0000,0x0000,0x0000, +0x8270,0x0000,0x543A,0x0000,0x826C,0x0000,0x0000,0x0000, +0x543B,0x0000,0x0000,0x5438,0x0000,0x0000,0x0000,0x0000, +0x2F4D,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5431,0x0000,0x0000,0x543C,0x0000,0x0000,0x543D,0x2F4E, +0x2F4F,0x0000,0x0000,0x4B64,0x8273,0x0000,0x3E6B,0x2F50, +0x0000,0x0000,0x543F,0x5440,0x543E,0x0000,0x5442,0x8271, +0x0000,0x0000,0x0000,0x0000,0x4738,0x0000,0x8276,0x3068, +0x4956,0x0000,0x0000,0x5443,0x2F51,0x0000,0x8277,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x2F52,0x0000,0x0000, +0x8278,0x0000,0x0000,0x0000,0x3E7D,0x2F53,0x2F54,0x3C39, +0x827A,0x475D,0x3470,0x827B,0x3A6B,0x827C,0x0000,0x2F55, + +/* 5800h */ +0x4B59,0x0000,0x4632,0x0000,0x827D,0x3778,0x424F,0x0000, +0x0000,0x2F56,0x5441,0x5444,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x4244,0x0000,0x0000, +0x0000,0x5445,0x0000,0x0000,0x0000,0x5446,0x827E,0x0000, +0x8321,0x5448,0x0000,0x0000,0x4469,0x0000,0x0000,0x8322, +0x0000,0x0000,0x342E,0x0000,0x0000,0x0000,0x0000,0x7421, +0x3161,0x4A73,0x8323,0x0000,0x3E6C,0x4548,0x0000,0x0000, +0x0000,0x8324,0x3A66,0x0000,0x0000,0x544E,0x0000,0x0000, +0x4A3D,0x4E5D,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x8326,0x3274,0x544A,0x8327,0x0000,0x0000,0x0000, +0x0000,0x413A,0x544D,0x0000,0x4563,0x0000,0x0000,0x4549, +0x4564,0x4839,0x444D,0x0000,0x0000,0x0000,0x3A49,0x0000, +0x0000,0x2F58,0x5449,0x0000,0x2F59,0x0000,0x0000,0x8328, +0x0000,0x3176,0x0000,0x4536,0x0000,0x0000,0x0000,0x0000, +0x544B,0x0000,0x5447,0x0000,0x0000,0x3F50,0x0000,0x0000, +0x0000,0x544F,0x0000,0x0000,0x2F5B,0x0000,0x3D4E,0x0000, +0x0000,0x0000,0x0000,0x362D,0x0000,0x5450,0x0000,0x0000, +0x0000,0x2F5C,0x8329,0x832A,0x0000,0x832B,0x0000,0x832C, +0x832D,0x0000,0x0000,0x4A68,0x832E,0x0000,0x0000,0x417D, +0x0000,0x0000,0x0000,0x0000,0x4446,0x832F,0x2F5D,0x5452, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4B4F,0x2F5F,0x8330,0x5453,0x0000,0x0000,0x5458,0x0000, +0x0000,0x8331,0x0000,0x4A2F,0x0000,0x0000,0x0000,0x0000, +0x5457,0x5451,0x5454,0x5456,0x0000,0x0000,0x3A26,0x0000, +0x0000,0x4A49,0x0000,0x8333,0x0000,0x5459,0x0000,0x4345, +0x0000,0x0000,0x3275,0x0000,0x3E6D,0x8334,0x2F62,0x0000, +0x0000,0x545B,0x2F61,0x545A,0x2F63,0x3968,0x0000,0x545C, +0x545E,0x545D,0x2F64,0x0000,0x5460,0x0000,0x5455,0x5462, +0x2F65,0x0000,0x8335,0x0000,0x5461,0x545F,0x0000,0x0000, +0x0000,0x2F66,0x0000,0x3B4E,0x3F51,0x0000,0x4154,0x5463, +0x403C,0x306D,0x4764,0x8336,0x8337,0x0000,0x0000,0x445B, +0x0000,0x5465,0x5464,0x5466,0x5467,0x5468,0x0000,0x0000, + +/* 5900h */ +0x0000,0x0000,0x5469,0x0000,0x0000,0x8338,0x8339,0x0000, +0x0000,0x4A51,0x546A,0x833A,0x2F67,0x833B,0x0000,0x3246, +0x546B,0x0000,0x0000,0x0000,0x833C,0x4D3C,0x3330,0x0000, +0x5249,0x3D48,0x423F,0x546C,0x4C6B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4C34,0x0000,0x833D,0x546E,0x0000,0x4267, +0x0000,0x4537,0x4240,0x4957,0x546F,0x5470,0x317B,0x0000, +0x0000,0x3C3A,0x5471,0x0000,0x0000,0x0000,0x0000,0x3050, +0x5472,0x0000,0x0000,0x0000,0x0000,0x8340,0x5473,0x0000, +0x0000,0x0000,0x0000,0x0000,0x3162,0x0000,0x8342,0x3471, +0x4660,0x4A74,0x0000,0x0000,0x0000,0x0000,0x5477,0x4155, +0x5476,0x3740,0x0000,0x0000,0x4B5B,0x5475,0x0000,0x4565, +0x5479,0x0000,0x5478,0x8345,0x0000,0x2F69,0x0000,0x8346, +0x547B,0x0000,0x547A,0x0000,0x0000,0x317C,0x0000,0x547C, +0x3E29,0x547E,0x4325,0x0000,0x547D,0x2F6A,0x4A33,0x0000, +0x0000,0x0000,0x0000,0x3D77,0x455B,0x8348,0x8349,0x0000, +0x5521,0x0000,0x0000,0x0000,0x834A,0x3925,0x0000,0x0000, +0x0000,0x5522,0x4721,0x485E,0x4C51,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4725,0x2F6B,0x0000,0x552B,0x0000,0x0000, +0x0000,0x0000,0x2F6C,0x3538,0x0000,0x0000,0x4D45,0x0000, +0x0000,0x4C2F,0x0000,0x562C,0x0000,0x5523,0x0000,0x834B, +0x0000,0x0000,0x0000,0x5526,0x2F6D,0x4245,0x0000,0x0000, +0x4B38,0x0000,0x0000,0x0000,0x454A,0x0000,0x834C,0x0000, +0x0000,0x0000,0x5527,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4B65,0x0000,0x3A4A,0x834D,0x0000,0x3E2A,0x0000, +0x0000,0x0000,0x0000,0x2F6E,0x0000,0x0000,0x5528,0x0000, +0x834E,0x3B50,0x0000,0x3B4F,0x0000,0x834F,0x0000,0x0000, +0x3039,0x3848,0x2F6F,0x402B,0x3051,0x0000,0x0000,0x0000, +0x0000,0x552C,0x552D,0x0000,0x552A,0x2F70,0x8350,0x0000, +0x0000,0x0000,0x0000,0x8351,0x8352,0x3138,0x342F,0x8353, +0x5529,0x0000,0x4C45,0x4931,0x0000,0x0000,0x8354,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3028,0x0000, +0x7E7A,0x0000,0x0000,0x3079,0x0000,0x0000,0x0000,0x3B51, + +/* 5A00h */ +0x0000,0x3052,0x0000,0x3023,0x0000,0x0000,0x0000,0x0000, +0x0000,0x5532,0x0000,0x0000,0x8358,0x8359,0x0000,0x0000, +0x0000,0x5530,0x0000,0x2F71,0x0000,0x0000,0x0000,0x835A, +0x4C3C,0x0000,0x5533,0x0000,0x5531,0x0000,0x0000,0x552F, +0x3F31,0x0000,0x0000,0x2F72,0x0000,0x552E,0x0000,0x835B, +0x0000,0x4A5A,0x0000,0x0000,0x0000,0x835C,0x0000,0x3864, +0x0000,0x0000,0x0000,0x0000,0x0000,0x5537,0x5538,0x0000, +0x0000,0x0000,0x0000,0x0000,0x3E2B,0x0000,0x0000,0x0000, +0x5534,0x4F2C,0x0000,0x0000,0x0000,0x0000,0x474C,0x0000, +0x0000,0x5536,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x835D,0x0000,0x0000, +0x0000,0x0000,0x3A27,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x5539,0x0000,0x0000,0x835E,0x4958,0x2F73, +0x0000,0x0000,0x553A,0x0000,0x5535,0x2F74,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x2F75, +0x0000,0x0000,0x835F,0x0000,0x0000,0x0000,0x2F76,0x4C3B, +0x0000,0x0000,0x0000,0x0000,0x2F77,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x8360,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x475E,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x553B,0x4932,0x8361,0x0000,0x2F78,0x8362, +0x8363,0x0000,0x8364,0x0000,0x0000,0x0000,0x0000,0x2F79, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x8365,0x0000,0x8366,0x0000,0x8367,0x0000,0x0000, +0x0000,0x0000,0x8368,0x0000,0x553C,0x5540,0x553D,0x8369, +0x0000,0x3247,0x553F,0x0000,0x2F7A,0x0000,0x0000,0x0000, +0x0000,0x3C3B,0x0000,0x553E,0x3779,0x0000,0x0000,0x0000, +0x554C,0x0000,0x0000,0x0000,0x0000,0x0000,0x5545,0x5542, +0x0000,0x0000,0x836A,0x0000,0x836B,0x0000,0x0000,0x0000, +0x836C,0x4364,0x0000,0x5541,0x0000,0x836D,0x5543,0x0000, +0x0000,0x5544,0x0000,0x0000,0x0000,0x0000,0x836F,0x0000, +0x836E,0x0000,0x0000,0x0000,0x0000,0x8370,0x0000,0x0000, +0x0000,0x0000,0x5546,0x5547,0x0000,0x0000,0x0000,0x0000, + +/* 5B00h */ +0x8371,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8372,0x3472,0x0000,0x5549,0x5548,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x554A,0x8373, +0x0000,0x2F7C,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x3E6E,0x0000,0x0000,0x2F7D,0x0000,0x0000, +0x0000,0x0000,0x554D,0x0000,0x445C,0x8375,0x0000,0x0000, +0x3145,0x0000,0x554B,0x0000,0x8374,0x0000,0x554E,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x554F,0x0000, +0x5552,0x4F55,0x0000,0x5550,0x0000,0x5551,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x8376,0x0000,0x0000,0x0000, +0x3B52,0x5553,0x8377,0x0000,0x3926,0x5554,0x4F56,0x3B7A, +0x4238,0x0000,0x5555,0x5556,0x3B5A,0x3927,0x0000,0x4C52, +0x0000,0x0000,0x0000,0x3528,0x3849,0x5557,0x3358,0x0000, +0x8378,0x5558,0x0000,0x4239,0x0000,0x0000,0x0000,0x8379, +0x5559,0x5623,0x0000,0x555A,0x0000,0x555B,0x0000,0x0000, +0x555C,0x0000,0x555E,0x0000,0x837A,0x4F57,0x0000,0x837B, +0x555F,0x837C,0x0000,0x5560,0x837D,0x4270,0x0000,0x3127, +0x3C69,0x3042,0x0000,0x4157,0x3430,0x3C35,0x0000,0x3928, +0x0000,0x0000,0x0000,0x4F58,0x0000,0x4566,0x8021,0x3D21, +0x3431,0x4368,0x446A,0x3038,0x3539,0x4A75,0x0000,0x3C42, +0x0000,0x0000,0x3552,0x406B,0x3C3C,0x4D28,0x5561,0x0000, +0x0000,0x0000,0x0000,0x0000,0x8022,0x0000,0x355C,0x0000, +0x3A4B,0x0000,0x0000,0x3332,0x3163,0x3E2C,0x3248,0x0000, +0x5562,0x4D46,0x0000,0x0000,0x0000,0x0000,0x0000,0x3D49, +0x8024,0x0000,0x3C64,0x5563,0x3473,0x4652,0x4C29,0x5564, +0x0000,0x5565,0x0000,0x0000,0x4959,0x0000,0x8026,0x0000, +0x5567,0x0000,0x3428,0x3677,0x5566,0x0000,0x8027,0x0000, +0x4F59,0x0000,0x0000,0x3432,0x0000,0x3F32,0x556B,0x3B21, +0x0000,0x3249,0x556A,0x0000,0x5568,0x556C,0x5569,0x472B, +0x5C4D,0x3F33,0x0000,0x556D,0x4F5A,0x0000,0x4E40,0x0000, +0x556E,0x802A,0x0000,0x5570,0x0000,0x437E,0x556F,0x0000, +0x4023,0x0000,0x3B7B,0x0000,0x0000,0x802B,0x4250,0x3C77, + +/* 5C00h */ +0x0000,0x4975,0x406C,0x802D,0x3C4D,0x5571,0x3E2D,0x5572, +0x5573,0x3053,0x423A,0x3F52,0x0000,0x5574,0x4633,0x3E2E, +0x0000,0x3E2F,0x4F5B,0x5575,0x0000,0x0000,0x406D,0x0000, +0x0000,0x0000,0x3E30,0x0000,0x0000,0x0000,0x4F5C,0x0000, +0x5576,0x0000,0x5577,0x4F5D,0x4C60,0x0000,0x0000,0x0000, +0x5578,0x802E,0x0000,0x4F5E,0x0000,0x3646,0x0000,0x0000, +0x802F,0x3D22,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5579,0x557A,0x3C5C,0x3F2C,0x4674,0x3F54,0x4878,0x4722, +0x3649,0x557B,0x0000,0x0000,0x0000,0x356F,0x557C,0x0000, +0x367E,0x0000,0x464F,0x3230,0x0000,0x3B53,0x557D,0x5622, +0x5621,0x367D,0x0000,0x557E,0x0000,0x4538,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7E7B,0x0000,0x0000,0x4230,0x8031, +0x454B,0x3C48,0x4F60,0x8032,0x4158,0x4D7A,0x0000,0x8033, +0x8034,0x8035,0x0000,0x0000,0x5624,0x0000,0x5625,0x4656, +0x8036,0x3B33,0x0000,0x0000,0x0000,0x0000,0x5627,0x0000, +0x0000,0x5628,0x4F64,0x0000,0x8039,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x803C,0x0000,0x803D,0x0000,0x5629,0x0000,0x0000,0x4F65, +0x3474,0x562A,0x0000,0x0000,0x562B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4F66, +0x8041,0x322C,0x8042,0x4F67,0x0000,0x0000,0x8043,0x8044, +0x413B,0x3464,0x4F68,0x562D,0x4C28,0x8046,0x0000,0x0000, +0x0000,0x4252,0x0000,0x3359,0x0000,0x8047,0x562F,0x5631, +0x345F,0x0000,0x4F69,0x562E,0x5630,0x0000,0x5633,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x5632,0x0000,0x5634, +0x0000,0x8049,0x0000,0x4F6A,0x0000,0x0000,0x0000,0x0000, +0x4F6B,0x0000,0x4F6C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x5635,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x463D,0x362E,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x3265,0x5636,0x563B,0x0000,0x0000,0x5639,0x0000,0x4A77, +0x4A76,0x0000,0x0000,0x0000,0x4F6D,0x0000,0x4567,0x0000, +0x0000,0x0000,0x5638,0x3D54,0x0000,0x5637,0x0000,0x0000, + +/* 5D00h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x804C,0x3F72, +0x0000,0x0000,0x0000,0x563C,0x0000,0x4F70,0x3A6A,0x0000, +0x804D,0x5642,0x0000,0x0000,0x5643,0x563D,0x3333,0x563E, +0x5647,0x5646,0x5645,0x5641,0x0000,0x804F,0x0000,0x5640, +0x8050,0x0000,0x5644,0x0000,0x8051,0x0000,0x8052,0x4F71, +0x0000,0x4A78,0x0000,0x804E,0x0000,0x0000,0x0000,0x0000, +0x0000,0x8053,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x8054,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x8055,0x0000,0x0000,0x0000,0x4F73,0x4F74, +0x0000,0x0000,0x4F76,0x564B,0x5648,0x0000,0x564A,0x0000, +0x4D72,0x0000,0x5649,0x4F75,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x563F,0x0000,0x0000,0x0000, +0x0000,0x8057,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3F73,0x8058,0x0000,0x564C,0x4F77,0x0000,0x3A37, +0x805A,0x0000,0x0000,0x564D,0x0000,0x0000,0x564E,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4F78,0x5651,0x0000,0x5650,0x0000,0x0000,0x564F, +0x805D,0x0000,0x0000,0x4568,0x563A,0x0000,0x0000,0x0000, +0x5657,0x0000,0x805F,0x0000,0x8060,0x0000,0x0000,0x8061, +0x0000,0x8062,0x0000,0x0000,0x0000,0x5653,0x0000,0x0000, +0x4F79,0x0000,0x5652,0x0000,0x4F7A,0x0000,0x0000,0x4F7B, +0x0000,0x0000,0x0000,0x0000,0x5654,0x0000,0x5655,0x0000, +0x8063,0x0000,0x8064,0x0000,0x8065,0x0000,0x0000,0x5658, +0x4F7C,0x8067,0x4E66,0x0000,0x5659,0x5656,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x565A,0x0000,0x4F7D,0x3460,0x565B,0x0000,0x0000, +0x0000,0x8068,0x565D,0x565C,0x0000,0x0000,0x565E,0x8069, +0x806A,0x0000,0x0000,0x565F,0x0000,0x406E,0x3D23,0x0000, +0x806B,0x3D64,0x7428,0x4163,0x806D,0x3929,0x3A38,0x392A, +0x3570,0x806E,0x0000,0x5660,0x0000,0x0000,0x3A39,0x0000, +0x0000,0x384A,0x5661,0x4C26,0x4743,0x5662,0x0000,0x392B, +0x0000,0x0000,0x0000,0x342C,0x0000,0x4327,0x3652,0x0000, + +/* 5E00h */ +0x8070,0x0000,0x3B54,0x495B,0x0000,0x0000,0x4841,0x0000, +0x0000,0x0000,0x0000,0x5663,0x3475,0x0000,0x0000,0x0000, +0x0000,0x5666,0x8072,0x0000,0x7429,0x8073,0x4421,0x0000, +0x742A,0x5665,0x5664,0x5667,0x0000,0x446B,0x0000,0x8075, +0x0000,0x0000,0x0000,0x0000,0x0000,0x3F63,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3B55,0x0000,0x404A,0x8076,0x4253, +0x3522,0x0000,0x0000,0x4422,0x0000,0x0000,0x5668,0x5669, +0x3E6F,0x0000,0x0000,0x0000,0x0000,0x4B39,0x8077,0x0000, +0x566C,0x0000,0x0000,0x566B,0x566A,0x497D,0x0000,0x5673, +0x0000,0x8078,0x0000,0x0000,0x4B5A,0x0000,0x566D,0x0000, +0x0000,0x0000,0x0000,0x0000,0x566F,0x4B6B,0x807A,0x566E, +0x742B,0x0000,0x0000,0x0000,0x0000,0x0000,0x742C,0x5670, +0x0000,0x4828,0x5671,0x4A3E,0x5672,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x807C,0x807D,0x807E,0x8421,0x0000, +0x0000,0x0000,0x3433,0x4A3F,0x472F,0x5674,0x5675,0x7E7C, +0x392C,0x3434,0x5676,0x3838,0x4D44,0x4D29,0x3476,0x5678, +0x0000,0x4423,0x0000,0x392D,0x3E31,0x0000,0x0000,0x485F, +0x0000,0x0000,0x3E32,0x0000,0x0000,0x0000,0x0000,0x3D78, +0x0000,0x0000,0x0000,0x0000,0x0000,0x446C,0x4A79,0x4539, +0x0000,0x0000,0x392E,0x0000,0x495C,0x0000,0x0000,0x0000, +0x5679,0x0000,0x0000,0x0000,0x0000,0x8423,0x4559,0x3A42, +0x0000,0x0000,0x8424,0x384B,0x8425,0x446D,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x3043,0x3D6E,0x392F, +0x4D47,0x8426,0x0000,0x0000,0x0000,0x0000,0x742D,0x8427, +0x0000,0x567A,0x567B,0x4751,0x0000,0x0000,0x8428,0x0000, +0x567C,0x4E77,0x4F2D,0x742F,0x0000,0x0000,0x0000,0x567E, +0x567D,0x0000,0x8429,0x3347,0x0000,0x0000,0x5721,0x0000, +0x0000,0x842A,0x5724,0x5725,0x0000,0x5723,0x0000,0x4940, +0x3E33,0x5727,0x5726,0x5722,0x0000,0x0000,0x0000,0x0000, +0x5728,0x5729,0x0000,0x0000,0x572A,0x0000,0x0000,0x0000, +0x572D,0x572B,0x0000,0x572C,0x572E,0x0000,0x3164,0x446E, +0x572F,0x7430,0x377A,0x3276,0x4736,0x842C,0x5730,0x467B, + +/* 5F00h */ +0x7431,0x4A5B,0x7432,0x5731,0x4F2E,0x0000,0x0000,0x7433, +0x842D,0x5732,0x4A40,0x5735,0x5021,0x5031,0x842E,0x3C30, +0x4675,0x5736,0x0000,0x355D,0x4424,0x307A,0x5737,0x4A26, +0x3930,0x0000,0x0000,0x4350,0x842F,0x7434,0x8431,0x446F, +0x0000,0x0000,0x0000,0x7435,0x0000,0x4C6F,0x3839,0x384C, +0x0000,0x5738,0x0000,0x0000,0x0000,0x5739,0x0000,0x573F, +0x0000,0x3C65,0x0000,0x0000,0x7436,0x4425,0x7437,0x362F, +0x573A,0x0000,0x0000,0x0000,0x492B,0x7438,0x4346,0x0000, +0x7439,0x573B,0x0000,0x0000,0x0000,0x743A,0x0000,0x8432, +0x573C,0x0000,0x3630,0x0000,0x573D,0x0000,0x573E,0x0000, +0x0000,0x5740,0x0000,0x4576,0x743B,0x0000,0x5741,0x5742, +0x743C,0x5743,0x0000,0x0000,0x5734,0x5733,0x0000,0x0000, +0x0000,0x5744,0x3741,0x8433,0x743D,0x0000,0x4927,0x743E, +0x0000,0x3A4C,0x4937,0x4426,0x494B,0x5745,0x0000,0x0000, +0x3E34,0x3146,0x8434,0x5746,0x0000,0x0000,0x0000,0x5747, +0x0000,0x4C72,0x0000,0x0000,0x4860,0x743F,0x8435,0x574A, +0x317D,0x402C,0x5749,0x5748,0x3742,0x4254,0x0000,0x574E, +0x574C,0x7440,0x574B,0x4E27,0x3865,0x0000,0x0000,0x8436, +0x3D79,0x574D,0x454C,0x3D3E,0x0000,0x0000,0x0000,0x4640, +0x5751,0x5750,0x0000,0x0000,0x7441,0x0000,0x574F,0x0000, +0x5752,0x3866,0x8437,0x0000,0x8438,0x0000,0x0000,0x7442, +0x5753,0x497C,0x3D5B,0x0000,0x0000,0x5754,0x4879,0x7443, +0x0000,0x0000,0x0000,0x4641,0x4427,0x7444,0x0000,0x7445, +0x8439,0x4530,0x0000,0x0000,0x5755,0x352B,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3F34,0x843A,0x492C,0x0000,0x843C, +0x0000,0x7446,0x0000,0x843D,0x3477,0x4726,0x0000,0x0000, +0x0000,0x0000,0x843E,0x843F,0x8440,0x0000,0x5756,0x3B56, +0x4B3A,0x4B3B,0x0000,0x0000,0x317E,0x575B,0x7447,0x0000, +0x4369,0x7448,0x8441,0x0000,0x5758,0x0000,0x0000,0x0000, +0x0000,0x7449,0x0000,0x3277,0x0000,0x0000,0x8442,0x8443, +0x582D,0x575A,0x0000,0x8444,0x0000,0x4730,0x0000,0x0000, +0x5759,0x0000,0x0000,0x5757,0x8445,0x397A,0x0000,0x575D, + +/* 6000h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x744A,0x5763,0x5769, +0x5761,0x0000,0x455C,0x0000,0x744B,0x5766,0x495D,0x8447, +0x744C,0x5760,0x0000,0x5765,0x4E67,0x3B57,0x0000,0x0000, +0x4255,0x575E,0x8448,0x0000,0x8449,0x355E,0x5768,0x402D, +0x3165,0x5762,0x3278,0x5767,0x0000,0x0000,0x0000,0x3631, +0x0000,0x5764,0x0000,0x744D,0x0000,0x744E,0x0000,0x0000, +0x0000,0x0000,0x576A,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x576C,0x5776,0x5774,0x0000,0x0000,0x5771,0x744F, +0x0000,0x0000,0x5770,0x4E78,0x844B,0x5772,0x0000,0x0000, +0x3632,0x0000,0x3931,0x0000,0x0000,0x3D7A,0x0000,0x0000, +0x0000,0x5779,0x576B,0x0000,0x0000,0x0000,0x0000,0x576F, +0x575F,0x0000,0x327A,0x5773,0x5775,0x4351,0x0000,0x0000, +0x3A28,0x3238,0x576D,0x5778,0x5777,0x3633,0x0000,0x4229, +0x3366,0x0000,0x0000,0x0000,0x0000,0x3743,0x0000,0x576E, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x844C, +0x0000,0x577A,0x0000,0x577D,0x5821,0x0000,0x0000,0x0000, +0x0000,0x3C3D,0x844D,0x5827,0x4470,0x577B,0x0000,0x0000, +0x0000,0x0000,0x5825,0x0000,0x3279,0x844E,0x5823,0x5824, +0x0000,0x0000,0x577E,0x5822,0x0000,0x7451,0x7452,0x3867, +0x4D2A,0x0000,0x0000,0x3435,0x0000,0x0000,0x3159,0x5826, +0x844F,0x473A,0x302D,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8451,0x8452,0x4861,0x575C,0x582C,0x5830,0x4C65,0x0000, +0x5829,0x0000,0x0000,0x0000,0x4569,0x582E,0x8453,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x3E70,0x582F,0x4657, +0x8454,0x0000,0x0000,0x7453,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4F47,0x0000,0x582B,0x7454,0x7455,0x0000,0x0000, +0x5831,0x8455,0x397B,0x8456,0x404B,0x7456,0x0000,0x3054, +0x582A,0x5828,0x0000,0x415A,0x0000,0x0000,0x0000,0x577C, +0x3B34,0x0000,0x0000,0x0000,0x0000,0x0000,0x8457,0x0000, +0x4246,0x583D,0x8458,0x415B,0x5838,0x8459,0x5835,0x5836, +0x7457,0x3C66,0x5839,0x583C,0x0000,0x0000,0x0000,0x0000, + +/* 6100h */ +0x5837,0x3D25,0x0000,0x583A,0x0000,0x0000,0x5834,0x0000, +0x4C7C,0x4C7B,0x0000,0x0000,0x0000,0x583E,0x583F,0x3055, +0x845A,0x0000,0x845B,0x845C,0x0000,0x5833,0x0000,0x0000, +0x0000,0x845D,0x3672,0x3026,0x7458,0x0000,0x845E,0x3436, +0x0000,0x583B,0x0000,0x0000,0x0000,0x0000,0x0000,0x5843, +0x5842,0x0000,0x0000,0x7459,0x5847,0x0000,0x0000,0x0000, +0x745A,0x0000,0x0000,0x0000,0x5848,0x0000,0x0000,0x745B, +0x0000,0x0000,0x845F,0x0000,0x5846,0x5849,0x5841,0x5845, +0x0000,0x8461,0x584A,0x0000,0x584B,0x0000,0x8462,0x5840, +0x3B7C,0x0000,0x5844,0x4256,0x3932,0x5832,0x3F35,0x0000, +0x0000,0x0000,0x0000,0x5858,0x0000,0x4A69,0x0000,0x0000, +0x584E,0x584F,0x5850,0x0000,0x0000,0x5857,0x0000,0x5856, +0x8463,0x0000,0x4B7D,0x3437,0x0000,0x5854,0x0000,0x3745, +0x3334,0x0000,0x0000,0x5851,0x0000,0x0000,0x4E38,0x5853, +0x3056,0x5855,0x0000,0x584C,0x5852,0x5859,0x3744,0x584D, +0x0000,0x0000,0x0000,0x0000,0x8464,0x0000,0x4D5D,0x0000, +0x0000,0x0000,0x4D2B,0x0000,0x0000,0x0000,0x0000,0x585C, +0x0000,0x0000,0x5860,0x0000,0x0000,0x745D,0x417E,0x0000, +0x4E79,0x5861,0x8466,0x8467,0x585E,0x0000,0x585B,0x8468, +0x8469,0x585A,0x585F,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x4A30,0x846A,0x0000,0x4634, +0x846B,0x3746,0x0000,0x5862,0x585D,0x846C,0x5863,0x0000, +0x0000,0x0000,0x377B,0x0000,0x0000,0x0000,0x3231,0x0000, +0x0000,0x7460,0x586B,0x0000,0x745F,0x0000,0x3438,0x0000, +0x0000,0x0000,0x0000,0x5869,0x0000,0x0000,0x586A,0x3A29, +0x5868,0x5866,0x5865,0x586C,0x5864,0x586E,0x0000,0x0000, +0x327B,0x0000,0x0000,0x0000,0x0000,0x846E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x846F,0x0000,0x8470, +0x0000,0x0000,0x0000,0x5870,0x0000,0x0000,0x586F,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4428,0x0000,0x5873,0x8471,0x5871,0x5867, +0x377C,0x0000,0x5872,0x0000,0x5876,0x5875,0x5877,0x5874, + +/* 6200h */ +0x5878,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5879,0x587A,0x4A6A,0x0000,0x587C,0x587B,0x3D3F,0x0000, +0x402E,0x3266,0x327C,0x0000,0x587D,0x8473,0x303F,0x0000, +0x0000,0x0000,0x404C,0x587E,0x0000,0x6C43,0x5921,0x3761, +0x0000,0x5922,0x7462,0x8474,0x0000,0x0000,0x406F,0x0000, +0x0000,0x8475,0x5923,0x0000,0x0000,0x0000,0x5924,0x353A, +0x5925,0x0000,0x5926,0x5927,0x4257,0x0000,0x0000,0x0000, +0x384D,0x0000,0x0000,0x4C61,0x0000,0x0000,0x7463,0x4B3C, +0x3D6A,0x5928,0x0000,0x7464,0x0000,0x0000,0x8476,0x4070, +0x6E3D,0x4862,0x0000,0x3C6A,0x8477,0x3A4D,0x5929,0x0000, +0x0000,0x8478,0x8479,0x4247,0x0000,0x4A27,0x7465,0x0000, +0x4271,0x0000,0x7466,0x592C,0x0000,0x0000,0x592A,0x0000, +0x592D,0x847A,0x0000,0x592B,0x847B,0x0000,0x0000,0x0000, +0x592E,0x0000,0x0000,0x0000,0x0000,0x847D,0x4A31,0x7467, +0x0000,0x3037,0x0000,0x847E,0x0000,0x0000,0x495E,0x0000, +0x0000,0x4863,0x0000,0x847C,0x592F,0x0000,0x5932,0x3E35, +0x353B,0x0000,0x5930,0x5937,0x3E36,0x7468,0x0000,0x0000, +0x0000,0x5931,0x4744,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4D5E,0x5933,0x5934,0x5938,0x456A,0x5935,0x3933, +0x405E,0x8521,0x0000,0x5946,0x4834,0x0000,0x4272,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x8522,0x0000, +0x0000,0x0000,0x0000,0x4864,0x5A2D,0x0000,0x0000,0x0000, +0x0000,0x4A7A,0x0000,0x0000,0x0000,0x4471,0x0000,0x0000, +0x0000,0x4B75,0x0000,0x593B,0x3221,0x436A,0x0000,0x0000, +0x0000,0x0000,0x5944,0x0000,0x7469,0x4334,0x593E,0x5945, +0x5940,0x5947,0x5943,0x0000,0x5942,0x476F,0x0000,0x593C, +0x327D,0x593A,0x3571,0x4273,0x5936,0x8523,0x746A,0x5939, +0x3934,0x405B,0x0000,0x3E37,0x5941,0x4752,0x0000,0x0000, +0x3572,0x3348,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x3367,0x3F21,0x5949,0x594E, +0x0000,0x594A,0x0000,0x377D,0x0000,0x594F,0x3B22,0x3969, +0x0000,0x0000,0x0000,0x0000,0x746B,0x8525,0x3D26,0x593D, + +/* 6300h */ +0x0000,0x3B7D,0x594C,0x8526,0x0000,0x0000,0x0000,0x3B58, +0x594D,0x3044,0x746C,0x0000,0x5948,0x8527,0x0000,0x0000, +0x8528,0x4429,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x746D,0x3573,0x0000,0x0000,0x0000,0x0000,0x0000,0x3634, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x594B, +0x3027,0x0000,0x0000,0x3A43,0x0000,0x0000,0x0000,0x3F36, +0x0000,0x0000,0x852B,0x0000,0x0000,0x852C,0x0000,0x0000, +0x0000,0x746E,0x4472,0x852D,0x852E,0x4854,0x5951,0x415E, +0x0000,0x852F,0x0000,0x746F,0x8530,0x0000,0x0000,0x0000, +0x0000,0x422A,0x0000,0x0000,0x3B2B,0x5952,0x8531,0x5954, +0x5950,0x0000,0x0000,0x0000,0x0000,0x4A61,0x0000,0x443D, +0x0000,0x8533,0x0000,0x0000,0x415C,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7470,0x0000,0x4A7B, +0x3C4E,0x5960,0x0000,0x595F,0x8536,0x0000,0x3F78,0x0000, +0x0000,0x0000,0x377E,0x0000,0x0000,0x0000,0x5959,0x3E39, +0x0000,0x0000,0x4668,0x4731,0x7471,0x0000,0x0000,0x0000, +0x5957,0x0000,0x0000,0x415D,0x8537,0x0000,0x0000,0x0000, +0x3C78,0x595C,0x0000,0x0000,0x3E38,0x0000,0x5956,0x595B, +0x0000,0x0000,0x4753,0x0000,0x853A,0x0000,0x5955,0x0000, +0x3721,0x8538,0x0000,0x335D,0x0000,0x0000,0x0000,0x595D, +0x4E2B,0x3A4E,0x4335,0x595A,0x0000,0x405C,0x0000,0x3935, +0x3F64,0x3166,0x413C,0x5958,0x3545,0x0000,0x0000,0x0000, +0x0000,0x0000,0x3747,0x0000,0x444F,0x595E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x415F,0x0000,0x853B,0x5961,0x0000, +0x5963,0x0000,0x0000,0x4237,0x5969,0x0000,0x5964,0x0000, +0x0000,0x5966,0x0000,0x0000,0x0000,0x0000,0x0000,0x4941, +0x4473,0x0000,0x5967,0x0000,0x853D,0x853E,0x4D2C,0x0000, +0x0000,0x0000,0x4D48,0x3439,0x853F,0x0000,0x0000,0x0000, +0x8540,0x302E,0x0000,0x5965,0x0000,0x7472,0x0000,0x0000, +0x0000,0x5962,0x0000,0x8541,0x8542,0x7473,0x3478,0x0000, +0x0000,0x0000,0x8543,0x0000,0x3167,0x7474,0x5968,0x853C, +0x0000,0x0000,0x4D49,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 6400h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x596C,0x0000, +0x0000,0x8544,0x0000,0x0000,0x0000,0x423B,0x0000,0x5973, +0x7475,0x0000,0x0000,0x596D,0x7476,0x0000,0x596A,0x5971, +0x0000,0x0000,0x0000,0x0000,0x5953,0x0000,0x8545,0x0000, +0x0000,0x0000,0x7477,0x0000,0x0000,0x8546,0x596E,0x0000, +0x5972,0x8547,0x0000,0x0000,0x4842,0x456B,0x0000,0x8548, +0x0000,0x0000,0x0000,0x0000,0x596B,0x0000,0x596F,0x0000, +0x0000,0x0000,0x3748,0x0000,0x0000,0x0000,0x3A71,0x0000, +0x0000,0x0000,0x405D,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5977,0x0000, +0x0000,0x7479,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4526,0x0000,0x8549,0x854A,0x0000,0x854B,0x0000,0x0000, +0x747A,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5974, +0x0000,0x4B60,0x0000,0x0000,0x0000,0x747B,0x0000,0x5975, +0x0000,0x0000,0x0000,0x854C,0x0000,0x0000,0x5976,0x0000, +0x4C4E,0x7478,0x4022,0x0000,0x0000,0x854D,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3762,0x0000,0x0000,0x0000,0x854E, +0x597D,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x854F,0x3B35,0x597A,0x0000,0x5979,0x0000,0x0000, +0x0000,0x0000,0x4732,0x0000,0x0000,0x8550,0x4635,0x8551, +0x0000,0x0000,0x0000,0x0000,0x4531,0x597B,0x0000,0x0000, +0x0000,0x597C,0x0000,0x496F,0x0000,0x4745,0x3B23,0x0000, +0x4071,0x0000,0x4B50,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3349,0x0000,0x5A25,0x597E,0x0000,0x747D,0x747E, +0x0000,0x4D4A,0x5A27,0x0000,0x7521,0x5A23,0x0000,0x5A24, +0x0000,0x0000,0x7522,0x8552,0x8553,0x4160,0x747C,0x0000, +0x7523,0x0000,0x5A22,0x0000,0x593F,0x8554,0x0000,0x8555, +0x5A26,0x0000,0x5A21,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5A2B,0x5A2C,0x4527,0x5A2E,0x8557,0x8558,0x3B24,0x5A29, +0x0000,0x0000,0x0000,0x0000,0x353C,0x0000,0x0000,0x5A2F, +0x0000,0x5A28,0x5A33,0x0000,0x5A32,0x0000,0x5A31,0x7524, +0x0000,0x0000,0x5A34,0x7525,0x0000,0x5A36,0x3E71,0x8559, + +/* 6500h */ +0x5A35,0x0000,0x0000,0x0000,0x855A,0x5A39,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x855C, +0x0000,0x0000,0x0000,0x0000,0x855D,0x0000,0x855E,0x0000, +0x5A37,0x0000,0x0000,0x0000,0x5A38,0x5970,0x8560,0x0000, +0x0000,0x0000,0x7526,0x5A3B,0x5A3A,0x0000,0x0000,0x0000, +0x0000,0x7527,0x5978,0x5A3C,0x5A30,0x0000,0x0000,0x3B59, +0x0000,0x0000,0x8561,0x0000,0x5A3D,0x5A3E,0x5A40,0x5A3F, +0x5A41,0x327E,0x0000,0x3936,0x0000,0x0000,0x4A7C,0x402F, +0x0000,0x0000,0x0000,0x0000,0x8562,0x384E,0x0000,0x0000, +0x5A43,0x0000,0x0000,0x0000,0x0000,0x5A46,0x0000,0x4952, +0x0000,0x355F,0x0000,0x0000,0x8563,0x5A45,0x5A44,0x4754, +0x5A47,0x3635,0x0000,0x0000,0x0000,0x5A49,0x5A48,0x0000, +0x0000,0x0000,0x343A,0x3B36,0x0000,0x0000,0x4658,0x7529, +0x0000,0x0000,0x0000,0x8564,0x3749,0x0000,0x0000,0x0000, +0x3F74,0x0000,0x5A4A,0x0000,0x4030,0x4528,0x0000,0x495F, +0x5A4B,0x0000,0x8565,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x8566,0x5A4C,0x5A4D,0x8567,0x8568,0x0000,0x4A38, +0x555D,0x4046,0x8569,0x0000,0x494C,0x0000,0x3A58,0x0000, +0x4865,0x4843,0x0000,0x0000,0x0000,0x0000,0x0000,0x454D, +0x0000,0x4E41,0x0000,0x5A4F,0x3C50,0x752A,0x0000,0x5A50, +0x0000,0x3036,0x0000,0x0000,0x3654,0x404D,0x0000,0x4960, +0x0000,0x0000,0x0000,0x5A51,0x3B42,0x4347,0x0000,0x3B5B, +0x3F37,0x0000,0x856A,0x0000,0x0000,0x856B,0x0000,0x5A52, +0x856C,0x4A7D,0x0000,0x0000,0x3177,0x3B5C,0x0000,0x856D, +0x0000,0x5A55,0x856E,0x5A53,0x5A56,0x4E39,0x5A54,0x0000, +0x0000,0x856F,0x0000,0x407B,0x5A57,0x0000,0x0000,0x4232, +0x0000,0x0000,0x5A58,0x0000,0x8570,0x0000,0x0000,0x347A, +0x0000,0x5A5A,0x0000,0x5A59,0x0000,0x0000,0x0000,0x0000, +0x5A5B,0x5A5C,0x347B,0x0000,0x0000,0x467C,0x4336,0x356C, +0x3B5D,0x4161,0x0000,0x0000,0x3D5C,0x3030,0x0000,0x0000, +0x0000,0x5A5D,0x8572,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x8573,0x3222,0x5A61,0x8574,0x0000,0x0000,0x0000, + +/* 6600h */ +0x752C,0x0000,0x3937,0x5A60,0x8575,0x0000,0x3A2B,0x3E3A, +0x8576,0x752D,0x5A5F,0x0000,0x3E3B,0x0000,0x4C40,0x3A2A, +0x0000,0x0000,0x0000,0x3057,0x404E,0x752E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x5A66,0x0000,0x752F,0x4031, +0x3147,0x8577,0x7531,0x0000,0x7532,0x3D55,0x0000,0x4B66, +0x3A72,0x0000,0x8578,0x7533,0x0000,0x3E3C,0x0000,0x4027, +0x7534,0x7535,0x0000,0x7536,0x5A65,0x5A63,0x5A64,0x0000, +0x0000,0x0000,0x7530,0x0000,0x436B,0x0000,0x0000,0x5B26, +0x0000,0x5A6A,0x3B7E,0x3938,0x5A68,0x8579,0x0000,0x0000, +0x7538,0x5A69,0x0000,0x3F38,0x7539,0x0000,0x857B,0x5A67, +0x0000,0x857A,0x3B2F,0x0000,0x0000,0x0000,0x0000,0x857E, +0x0000,0x753B,0x753C,0x8621,0x0000,0x5A6C,0x5A6B,0x5A70, +0x0000,0x753D,0x5A71,0x8622,0x5A6D,0x753E,0x3322,0x5A6E, +0x5A6F,0x4855,0x8625,0x8626,0x8627,0x8628,0x4961,0x374A, +0x5A72,0x0000,0x0000,0x753F,0x4032,0x0000,0x3E3D,0x7540, +0x7541,0x0000,0x4352,0x8629,0x0000,0x0000,0x0000,0x0000, +0x862A,0x3647,0x0000,0x5A73,0x5A77,0x0000,0x0000,0x324B, +0x5A74,0x5A76,0x0000,0x0000,0x0000,0x7542,0x5A75,0x0000, +0x862B,0x3D6B,0x862C,0x0000,0x0000,0x0000,0x4348,0x3045, +0x5A78,0x862D,0x0000,0x0000,0x0000,0x5A79,0x0000,0x0000, +0x7544,0x0000,0x442A,0x0000,0x0000,0x0000,0x4E71,0x0000, +0x0000,0x0000,0x0000,0x3B43,0x0000,0x862F,0x4A6B,0x0000, +0x0000,0x8630,0x7545,0x0000,0x4B3D,0x8631,0x0000,0x0000, +0x5B22,0x5A7B,0x0000,0x7546,0x5A7E,0x0000,0x5A7D,0x8633, +0x0000,0x5A7A,0x0000,0x0000,0x5B21,0x0000,0x7547,0x465E, +0x7548,0x5A7C,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5B23,0x0000, +0x0000,0x3D6C,0x5B24,0x754A,0x4D4B,0x4778,0x0000,0x0000, +0x5B25,0x0000,0x0000,0x0000,0x0000,0x0000,0x5B27,0x0000, +0x754B,0x5B28,0x0000,0x0000,0x8635,0x0000,0x0000,0x0000, +0x5B29,0x0000,0x364A,0x3148,0x3939,0x5B2A,0x0000,0x5B2B, +0x3D71,0x4162,0x754C,0x7537,0x5258,0x413E,0x413D,0x4258, + +/* 6700h */ +0x3A47,0x8637,0x0000,0x5072,0x0000,0x8638,0x0000,0x0000, +0x376E,0x4D2D,0x0000,0x4A7E,0x0000,0x497E,0x0000,0x5B2C, +0x0000,0x0000,0x8639,0x754D,0x3A73,0x443F,0x5B2D,0x4F2F, +0x0000,0x863B,0x0000,0x4B3E,0x0000,0x442B,0x5B2E,0x347C, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x5B2F,0x5B30, +0x4C5A,0x0000,0x4C24,0x4B76,0x4B5C,0x3B25,0x5B32,0x0000, +0x0000,0x3C6B,0x0000,0x754F,0x4B51,0x0000,0x5B34,0x5B37, +0x5B36,0x0000,0x3479,0x0000,0x0000,0x3560,0x0000,0x5B33, +0x0000,0x5B35,0x0000,0x0000,0x0000,0x0000,0x5B38,0x7551, +0x7552,0x3F79,0x0000,0x0000,0x863E,0x863F,0x4D7B,0x3049, +0x3A60,0x423C,0x0000,0x3C5D,0x8640,0x0000,0x3E73,0x0000, +0x0000,0x5B3B,0x0000,0x0000,0x454E,0x8641,0x5B39,0x422B, +0x5B3A,0x3E72,0x4C5D,0x5B3C,0x5B3D,0x4D68,0x7550,0x0000, +0x0000,0x0000,0x5B42,0x0000,0x0000,0x393A,0x0000,0x4755, +0x5B3F,0x456C,0x5A5E,0x5A62,0x8645,0x354F,0x8646,0x4747, +0x0000,0x0000,0x0000,0x7553,0x5B41,0x0000,0x3E3E,0x4844, +0x0000,0x7554,0x0000,0x0000,0x0000,0x5B47,0x0000,0x487A, +0x0000,0x5B3E,0x0000,0x5B44,0x5B43,0x0000,0x0000,0x0000, +0x404F,0x0000,0x8648,0x7555,0x0000,0x4B6D,0x0000,0x4E53, +0x7556,0x0000,0x4B67,0x7557,0x324C,0x3B5E,0x0000,0x0000, +0x4F48,0x5B46,0x3F75,0x0000,0x0000,0x0000,0x5B45,0x0000, +0x0000,0x5B40,0x0000,0x0000,0x0000,0x0000,0x0000,0x384F, +0x864C,0x0000,0x864D,0x5B4C,0x5B4A,0x0000,0x324D,0x5B48, +0x5B4E,0x5B54,0x0000,0x7558,0x0000,0x0000,0x0000,0x0000, +0x755A,0x4248,0x0000,0x864E,0x4A41,0x0000,0x5B56,0x0000, +0x864F,0x0000,0x4922,0x0000,0x0000,0x0000,0x5B55,0x4770, +0x4B3F,0x343B,0x8650,0x4077,0x3D40,0x0000,0x0000,0x755B, +0x4453,0x8651,0x4D2E,0x8652,0x0000,0x5B51,0x5B50,0x0000, +0x0000,0x0000,0x5B52,0x0000,0x5B4F,0x0000,0x0000,0x5B57, +0x0000,0x5B4D,0x0000,0x0000,0x5B4B,0x0000,0x5B53,0x5B49, +0x8653,0x436C,0x0000,0x4C78,0x3C46,0x3A74,0x0000,0x8654, +0x0000,0x7559,0x0000,0x3A3A,0x755C,0x0000,0x4B6F,0x3341, + +/* 6800h */ +0x0000,0x755D,0x444E,0x464A,0x3149,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x864B,0x0000,0x0000,0x4072,0x0000,0x0000,0x4034,0x372A, +0x8658,0x0000,0x0000,0x0000,0x0000,0x755F,0x5B59,0x8659, +0x0000,0x393B,0x337C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x5B5B,0x3374,0x5B61,0x7560,0x865A,0x0000,0x0000, +0x0000,0x7561,0x5B5E,0x865C,0x4073,0x0000,0x0000,0x0000, +0x334B,0x3A2C,0x0000,0x865D,0x334A,0x3A4F,0x865E,0x0000, +0x5B5C,0x3765,0x374B,0x456D,0x865F,0x8660,0x5B5A,0x0000, +0x3046,0x8661,0x0000,0x0000,0x8662,0x5B5D,0x5B5F,0x0000, +0x364D,0x372C,0x755E,0x343C,0x354B,0x8663,0x0000,0x8664, +0x0000,0x5B62,0x0000,0x7562,0x3A79,0x4B71,0x0000,0x3B37, +0x0000,0x0000,0x0000,0x5B63,0x0000,0x0000,0x0000,0x4930, +0x0000,0x0000,0x0000,0x8666,0x0000,0x0000,0x8667,0x0000, +0x0000,0x0000,0x7563,0x0000,0x5B6F,0x7564,0x3233,0x5B64, +0x0000,0x0000,0x8668,0x0000,0x8669,0x0000,0x5B75,0x5B65, +0x0000,0x4E42,0x866A,0x5B6C,0x0000,0x475F,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x5B74,0x0000,0x5B67, +0x866B,0x0000,0x0000,0x3034,0x5B69,0x0000,0x866C,0x393C, +0x866E,0x866F,0x8670,0x5B6B,0x8671,0x5B6A,0x0000,0x5B66, +0x5B71,0x0000,0x3E3F,0x7566,0x0000,0x7567,0x546D,0x3868, +0x4D7C,0x0000,0x8672,0x8673,0x0000,0x5B68,0x0000,0x4474, +0x3323,0x3A2D,0x7568,0x5B60,0x8674,0x5B70,0x3361,0x0000, +0x0000,0x5B6E,0x5B72,0x8675,0x456E,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x867A,0x347E,0x867B,0x5C32,0x0000, +0x7569,0x4C49,0x5B77,0x347D,0x867C,0x5B7E,0x0000,0x867D, +0x756A,0x0000,0x4B40,0x0000,0x5C21,0x5C23,0x867E,0x5C27, +0x5B79,0x8721,0x432A,0x0000,0x0000,0x0000,0x0000,0x456F, +0x5C2B,0x5B7C,0x0000,0x5C28,0x8722,0x8723,0x0000,0x5C22, +0x756B,0x0000,0x0000,0x0000,0x8724,0x756C,0x3F39,0x5C2C, +0x756D,0x756E,0x4033,0x0000,0x0000,0x0000,0x0000,0x8725, +0x0000,0x5C2A,0x343D,0x8676,0x756F,0x0000,0x0000,0x0000, + +/* 6900h */ +0x4F50,0x5B76,0x0000,0x8726,0x5C26,0x3058,0x0000,0x8727, +0x5B78,0x0000,0x7570,0x4C3A,0x5B7D,0x3F22,0x4447,0x5B73, +0x0000,0x0000,0x5C25,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3F7A,0x5C2F,0x3371,0x3821,0x0000,0x0000,0x0000, +0x0000,0x5C31,0x5B7A,0x5C30,0x0000,0x5C29,0x5B7B,0x0000, +0x5C2D,0x0000,0x5C2E,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5C3F,0x0000,0x0000,0x0000,0x464E,0x7573,0x5C24,0x0000, +0x0000,0x5C3B,0x0000,0x872B,0x0000,0x5C3D,0x0000,0x4458, +0x0000,0x0000,0x7574,0x0000,0x0000,0x0000,0x872D,0x0000, +0x0000,0x7571,0x4D4C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x4976,0x5C38,0x424A,0x0000,0x7575, +0x0000,0x5C3E,0x413F,0x0000,0x5C35,0x5C42,0x5C41,0x0000, +0x466F,0x5C40,0x466A,0x7576,0x7577,0x0000,0x0000,0x0000, +0x7578,0x872E,0x5C44,0x5C37,0x872F,0x3648,0x5C3A,0x3D5D, +0x0000,0x0000,0x8730,0x4760,0x5C3C,0x364B,0x0000,0x5C34, +0x5C36,0x5C33,0x8731,0x0000,0x4F30,0x335A,0x5C39,0x8732, +0x7579,0x5C43,0x3335,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x3A67,0x0000,0x0000,0x0000,0x315D,0x0000, +0x0000,0x5C54,0x8733,0x0000,0x4F31,0x5C57,0x8735,0x0000, +0x8736,0x0000,0x0000,0x3F3A,0x5C56,0x0000,0x0000,0x0000, +0x5C55,0x0000,0x0000,0x0000,0x0000,0x757B,0x8737,0x5C52, +0x0000,0x0000,0x0000,0x0000,0x0000,0x757C,0x5C46,0x0000, +0x8738,0x5C63,0x5C45,0x0000,0x5C58,0x0000,0x0000,0x8739, +0x0000,0x0000,0x873A,0x5C50,0x873B,0x0000,0x5C4B,0x5C48, +0x873C,0x5C49,0x0000,0x5C51,0x0000,0x0000,0x0000,0x7422, +0x0000,0x0000,0x5C4E,0x393D,0x4448,0x4164,0x5C4C,0x757D, +0x5C47,0x873D,0x0000,0x5C4A,0x0000,0x0000,0x873E,0x0000, +0x4D4D,0x4B6A,0x0000,0x0000,0x0000,0x5C4F,0x5C59,0x0000, +0x0000,0x0000,0x7622,0x8744,0x0000,0x0000,0x0000,0x5C61, +0x5C5A,0x7623,0x7624,0x5C67,0x0000,0x5C65,0x8745,0x8746, +0x0000,0x0000,0x5C60,0x8747,0x8749,0x7625,0x7626,0x0000, +0x0000,0x5C5F,0x0000,0x4450,0x0000,0x4165,0x874A,0x5C5D, + +/* 6A00h */ +0x0000,0x0000,0x5C5B,0x0000,0x0000,0x5C62,0x0000,0x0000, +0x0000,0x0000,0x5C68,0x4875,0x5C6E,0x0000,0x0000,0x7627, +0x0000,0x874B,0x5C69,0x5C6C,0x5C66,0x7628,0x0000,0x4374, +0x0000,0x4938,0x874C,0x5C5C,0x0000,0x874D,0x5C64,0x3E40, +0x0000,0x4C4F,0x5C78,0x5C6B,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3822,0x3223,0x335F,0x0000,0x0000,0x5C53,0x0000, +0x8741,0x0000,0x874F,0x8750,0x8751,0x3E41,0x5C70,0x0000, +0x5C77,0x3C79,0x3372,0x762A,0x0000,0x432E,0x762B,0x8752, +0x0000,0x0000,0x0000,0x0000,0x5C6D,0x762C,0x8753,0x5C72, +0x5C76,0x8754,0x0000,0x3636,0x0000,0x0000,0x8756,0x0000, +0x762D,0x0000,0x8757,0x0000,0x0000,0x0000,0x762E,0x0000, +0x354C,0x5C74,0x0000,0x762F,0x0000,0x0000,0x0000,0x3521, +0x0000,0x464B,0x5C73,0x0000,0x8758,0x0000,0x5C75,0x0000, +0x0000,0x0000,0x0000,0x7630,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x5C6F,0x7631,0x0000,0x0000,0x0000,0x0000, +0x5C71,0x0000,0x8755,0x0000,0x0000,0x0000,0x875A,0x3360, +0x4349,0x0000,0x0000,0x875B,0x5C7C,0x0000,0x0000,0x0000, +0x0000,0x7633,0x0000,0x875C,0x0000,0x5C7A,0x3869,0x0000, +0x5C79,0x875E,0x0000,0x0000,0x7634,0x0000,0x0000,0x5D21, +0x0000,0x0000,0x0000,0x0000,0x5B58,0x7635,0x7636,0x875F, +0x5C7B,0x8760,0x5C7D,0x5C7E,0x0000,0x7637,0x0000,0x0000, +0x0000,0x0000,0x5D2C,0x8762,0x5D28,0x0000,0x5B6D,0x0000, +0x0000,0x0000,0x0000,0x5D27,0x0000,0x0000,0x0000,0x0000, +0x5D26,0x0000,0x0000,0x5D23,0x0000,0x8763,0x0000,0x0000, +0x0000,0x5C6A,0x5D25,0x5D24,0x0000,0x0000,0x8764,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8766,0x5D2A,0x0000,0x4F26,0x8765,0x0000,0x0000,0x0000, +0x0000,0x0000,0x5D2D,0x367B,0x8767,0x8768,0x5D29,0x5D2B, +0x0000,0x0000,0x0000,0x0000,0x7638,0x0000,0x0000,0x7639, +0x4827,0x0000,0x5D2E,0x0000,0x876B,0x0000,0x0000,0x0000, +0x0000,0x876C,0x876D,0x876E,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x5D32,0x5D2F,0x0000,0x876F,0x0000,0x0000, + +/* 6B00h */ +0x0000,0x0000,0x0000,0x0000,0x4D73,0x5D30,0x0000,0x0000, +0x0000,0x0000,0x5C5E,0x8771,0x0000,0x0000,0x0000,0x8772, +0x8773,0x8774,0x5D33,0x0000,0x0000,0x0000,0x5D34,0x8776, +0x0000,0x0000,0x0000,0x763C,0x0000,0x3135,0x763D,0x5D36, +0x3767,0x3C21,0x0000,0x3655,0x0000,0x0000,0x0000,0x3224, +0x0000,0x0000,0x0000,0x0000,0x763E,0x0000,0x0000,0x8778, +0x0000,0x0000,0x4D5F,0x0000,0x0000,0x763F,0x0000,0x5D38, +0x5D37,0x5D3A,0x353D,0x0000,0x0000,0x3656,0x343E,0x0000, +0x0000,0x0000,0x0000,0x5D3D,0x0000,0x0000,0x7640,0x5D3C, +0x0000,0x5D3E,0x8779,0x0000,0x324E,0x0000,0x4337,0x0000, +0x5D3F,0x0000,0x0000,0x343F,0x5D41,0x0000,0x7641,0x0000, +0x877A,0x5D40,0x0000,0x5D42,0x0000,0x0000,0x0000,0x5D43, +0x7642,0x5D44,0x3B5F,0x4035,0x3A21,0x7643,0x4970,0x7644, +0x0000,0x4A62,0x4F44,0x0000,0x877B,0x0000,0x0000,0x3B75, +0x0000,0x0000,0x0000,0x3A50,0x4E72,0x877C,0x0000,0x7645, +0x5D45,0x5D46,0x877D,0x3B60,0x0000,0x0000,0x0000,0x5D47, +0x5D48,0x877E,0x7646,0x5D4A,0x5D49,0x0000,0x4B58,0x0000, +0x0000,0x3D5E,0x3C6C,0x3B44,0x0000,0x5D4B,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x5D4D,0x3F23,0x0000, +0x5D4C,0x0000,0x0000,0x8821,0x0000,0x0000,0x5D4E,0x0000, +0x0000,0x0000,0x0000,0x0000,0x5D4F,0x0000,0x0000,0x0000, +0x0000,0x7647,0x5D50,0x5D51,0x0000,0x7648,0x8822,0x5D52, +0x0000,0x5D54,0x5D53,0x5D55,0x3225,0x434A,0x0000,0x5D56, +0x0000,0x0000,0x3B26,0x334C,0x5D57,0x8824,0x8825,0x4542, +0x544C,0x0000,0x0000,0x0000,0x0000,0x3523,0x5D58,0x8826, +0x8827,0x8828,0x0000,0x5D59,0x0000,0x4A6C,0x4B68,0x764A, +0x0000,0x0000,0x4647,0x5D5A,0x4866,0x0000,0x764B,0x764C, +0x487B,0x0000,0x8829,0x4C53,0x0000,0x0000,0x0000,0x5D5B, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x882A,0x882B, +0x0000,0x0000,0x0000,0x5D5D,0x5D5C,0x0000,0x882C,0x5D5F, +0x0000,0x882D,0x0000,0x5D5E,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x764D, + +/* 6C00h */ +0x0000,0x0000,0x882E,0x0000,0x0000,0x764E,0x0000,0x0000, +0x5D61,0x0000,0x882F,0x0000,0x0000,0x0000,0x8830,0x3B61, +0x764F,0x4C31,0x0000,0x5D62,0x5D63,0x0000,0x0000,0x3524, +0x0000,0x0000,0x0000,0x5D64,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x5D66,0x5D65,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7650,0x3F65,0x8831,0x8832,0x4939, +0x314A,0x0000,0x8833,0x0000,0x0000,0x0000,0x4845,0x8835, +0x4475,0x3D41,0x3561,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x8836,0x4846,0x0000, +0x3C2E,0x0000,0x0000,0x0000,0x0000,0x5D68,0x0000,0x3440, +0x0000,0x7651,0x3178,0x8837,0x7652,0x4672,0x5D67,0x393E, +0x4353,0x0000,0x5D69,0x0000,0x0000,0x0000,0x0000,0x884F, +0x5D71,0x0000,0x5D6A,0x0000,0x0000,0x8838,0x0000,0x0000, +0x4241,0x0000,0x3562,0x5D72,0x7654,0x0000,0x7655,0x0000, +0x0000,0x0000,0x3768,0x0000,0x0000,0x3525,0x5D70,0x0000, +0x0000,0x5D6E,0x5D6B,0x4D60,0x8839,0x7656,0x7657,0x0000, +0x4440,0x883A,0x0000,0x0000,0x4659,0x5D6C,0x0000,0x0000, +0x5D74,0x0000,0x5D73,0x3723,0x883C,0x883D,0x322D,0x883E, +0x7658,0x3A3B,0x5D6D,0x5D6F,0x7659,0x0000,0x0000,0x0000, +0x0000,0x4B57,0x4274,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7653,0x4B77,0x0000,0x883F,0x5D7C,0x0000, +0x0000,0x5D7D,0x0000,0x324F,0x0000,0x0000,0x0000,0x0000, +0x4A28,0x4C7D,0x5E21,0x3C23,0x3E42,0x5D78,0x5D7E,0x3168, +0x0000,0x3637,0x8840,0x0000,0x5D75,0x5D7A,0x765B,0x0000, +0x0000,0x4074,0x4771,0x0000,0x4867,0x0000,0x0000,0x0000, +0x8841,0x0000,0x0000,0x5D77,0x765C,0x4B21,0x8843,0x5D79, +0x0000,0x5E24,0x8844,0x5E22,0x8845,0x5D7B,0x0000,0x0000, +0x765D,0x4B22,0x4748,0x3563,0x0000,0x4525,0x0000,0x0000, +0x436D,0x8846,0x5E25,0x765E,0x8847,0x8848,0x765F,0x5E23, +0x4259,0x5D76,0x0000,0x314B,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x765A,0x0000,0x0000,0x0000,0x0000, + +/* 6D00h */ +0x884A,0x0000,0x0000,0x0000,0x7661,0x0000,0x0000,0x0000, +0x0000,0x0000,0x884B,0x4D4E,0x5E30,0x0000,0x7662,0x0000, +0x0000,0x0000,0x5E2F,0x0000,0x0000,0x0000,0x0000,0x4076, +0x0000,0x5E2C,0x0000,0x4D6C,0x0000,0x0000,0x4636,0x5E26, +0x0000,0x0000,0x0000,0x0000,0x884C,0x4445,0x884D,0x884E, +0x0000,0x314C,0x393F,0x5E29,0x0000,0x0000,0x7663,0x8850, +0x0000,0x7664,0x3D27,0x5E2E,0x8865,0x5E2D,0x5E28,0x0000, +0x5E2B,0x7665,0x0000,0x3368,0x8851,0x5E2A,0x4749,0x7666, +0x0000,0x4E2E,0x0000,0x0000,0x3E74,0x4075,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7667,0x5E36,0x5E34,0x8852,0x494D,0x0000,0x8853,0x0000, +0x8854,0x0000,0x0000,0x5E31,0x5E33,0x7668,0x313A,0x0000, +0x0000,0x3940,0x4F32,0x0000,0x333D,0x0000,0x4962,0x0000, +0x8855,0x0000,0x0000,0x0000,0x4D61,0x0000,0x0000,0x3324, +0x3F3B,0x5E35,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8856,0x8857,0x766A,0x0000,0x0000,0x5E3A,0x0000,0x766B, +0x3E43,0x766C,0x8858,0x0000,0x4D30,0x8859,0x5E37,0x0000, +0x0000,0x885A,0x0000,0x5E32,0x766D,0x5E38,0x0000,0x0000, +0x885B,0x4E5E,0x0000,0x4573,0x4642,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x766E,0x8861,0x766F,0x0000,0x8862,0x3336, +0x0000,0x0000,0x3155,0x0000,0x8863,0x5E3E,0x0000,0x0000, +0x5E41,0x0000,0x0000,0x0000,0x4E43,0x0000,0x0000,0x7670, +0x4D64,0x0000,0x8864,0x0000,0x7671,0x5E48,0x5E42,0x5E3F, +0x8866,0x0000,0x0000,0x4E54,0x5E45,0x0000,0x8867,0x8868, +0x8869,0x3D4A,0x5E47,0x0000,0x0000,0x5E4C,0x7672,0x0000, +0x4571,0x5E4A,0x7673,0x7674,0x0000,0x7675,0x5E44,0x886A, +0x0000,0x4338,0x0000,0x0000,0x5E4B,0x0000,0x5E40,0x0000, +0x5E46,0x886B,0x5E4D,0x307C,0x5E43,0x0000,0x5E4E,0x0000, +0x0000,0x3F3C,0x0000,0x3D5F,0x0000,0x4A25,0x886C,0x3A2E, +0x0000,0x5E3B,0x5E49,0x453A,0x7676,0x0000,0x0000,0x0000, + +/* 6E00h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x4036,0x0000,0x3369, +0x3A51,0x3E44,0x5E3D,0x3D42,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x374C,0x0000,0x5E3C,0x0000,0x885D, +0x0000,0x5E52,0x3D6D,0x383A,0x0000,0x5E61,0x886E,0x5E5B, +0x3574,0x454F,0x886F,0x5E56,0x5E5F,0x302F,0x3132,0x8870, +0x0000,0x3239,0x0000,0x5E58,0x422C,0x5E4F,0x5E51,0x3941, +0x0000,0x0000,0x8872,0x0000,0x7678,0x0000,0x886D,0x0000, +0x5E62,0x0000,0x5E5D,0x0000,0x8873,0x0000,0x5E55,0x0000, +0x0000,0x0000,0x0000,0x5E5C,0x7679,0x0000,0x0000,0x0000, +0x8874,0x8875,0x4C2B,0x8876,0x8877,0x5E5A,0x5E5E,0x8878, +0x0000,0x8879,0x0000,0x887A,0x887B,0x0000,0x3850,0x887C, +0x3E45,0x0000,0x0000,0x4339,0x767A,0x0000,0x767B,0x5E54, +0x0000,0x0000,0x0000,0x887D,0x0000,0x0000,0x0000,0x4D2F, +0x0000,0x0000,0x0000,0x5E57,0x0000,0x0000,0x5E50,0x4572, +0x0000,0x0000,0x5E53,0x0000,0x0000,0x0000,0x5E59,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4F51,0x3C3E, +0x4B7E,0x0000,0x5E63,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x482E,0x0000,0x0000,0x5E6F, +0x383B,0x0000,0x0000,0x8921,0x0000,0x0000,0x3D60,0x0000, +0x5E65,0x0000,0x0000,0x0000,0x4E2F,0x3942,0x0000,0x5E72, +0x0000,0x0000,0x306E,0x0000,0x0000,0x5E70,0x0000,0x8922, +0x0000,0x0000,0x5E64,0x767C,0x0000,0x0000,0x0000,0x5E6A, +0x0000,0x767D,0x5E6C,0x0000,0x8923,0x0000,0x4D4F,0x5E67, +0x0000,0x0000,0x452E,0x0000,0x0000,0x5E69,0x0000,0x8924, +0x0000,0x767E,0x5E71,0x8925,0x5E6B,0x4C47,0x0000,0x7721, +0x0000,0x5E66,0x8926,0x3C22,0x5E7E,0x0000,0x7722,0x0000, +0x0000,0x336A,0x0000,0x5E68,0x5E6D,0x5E6E,0x0000,0x0000, +0x0000,0x8927,0x0000,0x0000,0x0000,0x426C,0x425A,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x8929,0x5E76,0x0000,0x0000,0x5E7C, +0x0000,0x0000,0x5E7A,0x0000,0x4529,0x0000,0x0000,0x5F23, +0x5E77,0x892A,0x0000,0x892B,0x0000,0x0000,0x5E78,0x5E60, + +/* 6F00h */ +0x0000,0x3579,0x493A,0x0000,0x0000,0x0000,0x3C3F,0x0000, +0x0000,0x3977,0x892C,0x0000,0x892D,0x0000,0x0000,0x4F33, +0x7723,0x5E74,0x0000,0x5F22,0x3169,0x4166,0x0000,0x0000, +0x892E,0x0000,0x7724,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4779,0x0000,0x3441,0x4E7A,0x0000,0x892F,0x0000,0x0000, +0x0000,0x0000,0x7726,0x4C21,0x4452,0x0000,0x0000,0x7727, +0x0000,0x5E7B,0x5E7D,0x7728,0x0000,0x8928,0x8930,0x0000, +0x4132,0x0000,0x0000,0x0000,0x8931,0x0000,0x5F21,0x5E79, +0x0000,0x5E73,0x0000,0x0000,0x0000,0x3443,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x7729,0x8933,0x0000,0x3769,0x0000,0x0000,0x8934, +0x5F2F,0x772A,0x8935,0x5F2A,0x4078,0x0000,0x772B,0x3363, +0x8936,0x772C,0x772D,0x0000,0x3D61,0x0000,0x5F33,0x0000, +0x8937,0x0000,0x0000,0x0000,0x0000,0x5F2C,0x442C,0x5F29, +0x4459,0x0000,0x0000,0x0000,0x5F4C,0x0000,0x0000,0x0000, +0x5F26,0x0000,0x5F25,0x0000,0x5F2E,0x8939,0x772E,0x0000, +0x5F28,0x5F27,0x5F2D,0x0000,0x4021,0x0000,0x5F24,0x0000, +0x772F,0x0000,0x0000,0x0000,0x7730,0x7731,0x5F30,0x0000, +0x893A,0x5F31,0x0000,0x0000,0x7732,0x0000,0x893B,0x3442, +0x8938,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x893D, +0x7733,0x5F36,0x0000,0x5F35,0x5F37,0x893E,0x0000,0x7734, +0x0000,0x0000,0x5F3A,0x0000,0x0000,0x0000,0x0000,0x893F, +0x0000,0x4543,0x0000,0x5F34,0x0000,0x8941,0x7735,0x0000, +0x0000,0x5F38,0x0000,0x0000,0x7736,0x0000,0x893C,0x0000, +0x3763,0x4279,0x5F32,0x473B,0x0000,0x0000,0x5F39,0x7737, +0x8942,0x8943,0x7738,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x5F3E,0x5F3C,0x0000,0x0000, +0x5F3F,0x0000,0x8944,0x5F42,0x0000,0x0000,0x8945,0x5F3B, +0x396A,0x4728,0x0000,0x0000,0x5E39,0x0000,0x0000,0x0000, +0x0000,0x8946,0x0000,0x4D74,0x5F3D,0x0000,0x5F41,0x4275, +0x773A,0x5F40,0x0000,0x5F2B,0x0000,0x773B,0x6F69,0x0000, +0x0000,0x7739,0x5F45,0x0000,0x8948,0x0000,0x5F49,0x0000, + +/* 7000h */ +0x8949,0x5F47,0x0000,0x0000,0x0000,0x773C,0x773D,0x894A, +0x0000,0x5F43,0x894B,0x5F44,0x0000,0x0000,0x0000,0x5F48, +0x0000,0x5F46,0x0000,0x0000,0x0000,0x494E,0x0000,0x0000, +0x5F4E,0x0000,0x5F4B,0x5F4A,0x0000,0x5F4D,0x4654,0x5F4F, +0x0000,0x0000,0x0000,0x894C,0x0000,0x0000,0x4375,0x426D, +0x773E,0x0000,0x0000,0x0000,0x4025,0x0000,0x0000,0x0000, +0x5F50,0x0000,0x5F52,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x894E,0x894F,0x0000,0x8950,0x0000,0x5F51,0x0000, +0x0000,0x0000,0x0000,0x8951,0x0000,0x0000,0x0000,0x8952, +0x0000,0x0000,0x773F,0x8953,0x5E75,0x0000,0x7742,0x0000, +0x0000,0x5F53,0x0000,0x0000,0x8955,0x0000,0x0000,0x0000, +0x4667,0x0000,0x0000,0x0000,0x0000,0x7740,0x7741,0x0000, +0x0000,0x0000,0x0000,0x5F54,0x7743,0x8956,0x0000,0x0000, +0x0000,0x8957,0x0000,0x3250,0x8958,0x0000,0x8959,0x4574, +0x3325,0x0000,0x0000,0x0000,0x0000,0x7744,0x895A,0x0000, +0x3564,0x0000,0x0000,0x0000,0x3C5E,0x3A52,0x895B,0x0000, +0x0000,0x895C,0x0000,0x0000,0x0000,0x7745,0x895D,0x0000, +0x0000,0x4F27,0x3F66,0x0000,0x0000,0x0000,0x316A,0x0000, +0x0000,0x0000,0x5F56,0x0000,0x0000,0x895E,0x0000,0x895F, +0x0000,0x5F55,0x0000,0x0000,0x0000,0x0000,0x0000,0x8962, +0x0000,0x0000,0x0000,0x0000,0x7746,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7747,0x5F59,0x433A,0x5F5C,0x5F57, +0x0000,0x8963,0x0000,0x5F5B,0x0000,0x0000,0x0000,0x7748, +0x5F5A,0x4540,0x3059,0x8960,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4E75,0x0000,0x8966,0x5F5E,0x0000,0x0000,0x0000,0x3128, +0x0000,0x8967,0x0000,0x8968,0x7749,0x0000,0x0000,0x0000, +0x774A,0x5F60,0x0000,0x0000,0x8969,0x5F5F,0x0000,0x5F5D, +0x0000,0x0000,0x0000,0x0000,0x774B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x8965,0x0000,0x0000,0x0000, +0x0000,0x5F58,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4B23,0x0000,0x0000,0x0000,0x5F62,0x0000,0x0000, + +/* 7100h */ +0x0000,0x0000,0x0000,0x896A,0x896B,0x0000,0x896C,0x896D, +0x896E,0x5F61,0x0000,0x0000,0x896F,0x0000,0x0000,0x774C, +0x0000,0x0000,0x0000,0x0000,0x316B,0x0000,0x0000,0x0000, +0x0000,0x5F64,0x4A32,0x0000,0x5F63,0x0000,0x774E,0x0000, +0x774F,0x4C35,0x0000,0x0000,0x0000,0x0000,0x3E47,0x0000, +0x0000,0x0000,0x0000,0x774D,0x0000,0x0000,0x7750,0x8971, +0x7751,0x8972,0x0000,0x0000,0x0000,0x0000,0x4133,0x0000, +0x0000,0x0000,0x0000,0x0000,0x3E46,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7752,0x7753, +0x0000,0x4E7B,0x8974,0x0000,0x5F6A,0x0000,0x4079,0x0000, +0x8973,0x7754,0x7756,0x8975,0x0000,0x5F66,0x5F6B,0x0000, +0x0000,0x316C,0x0000,0x0000,0x7757,0x0000,0x8976,0x0000, +0x7758,0x0000,0x5F69,0x0000,0x4761,0x5F65,0x5F68,0x3E48, +0x7759,0x4851,0x0000,0x0000,0x5F6C,0x0000,0x3C51,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x407A,0x0000,0x0000, +0x8979,0x0000,0x0000,0x0000,0x5F6F,0x775B,0x0000,0x775C, +0x5F67,0x0000,0x3727,0x0000,0x0000,0x0000,0x0000,0x5F6D, +0x0000,0x0000,0x775D,0x0000,0x4D50,0x5F70,0x8978,0x0000, +0x0000,0x7426,0x0000,0x897A,0x0000,0x0000,0x0000,0x3D4F, +0x897B,0x0000,0x897C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x5F71,0x0000,0x0000,0x0000,0x5F72,0x0000,0x897D,0x897E, +0x0000,0x472E,0x0000,0x8A21,0x0000,0x0000,0x0000,0x0000, +0x0000,0x5F74,0x775F,0x0000,0x0000,0x0000,0x5F75,0x0000, +0x0000,0x775E,0x0000,0x4733,0x7760,0x0000,0x0000,0x0000, +0x4575,0x5F77,0x0000,0x8A23,0x0000,0x0000,0x5F79,0x0000, +0x4E55,0x0000,0x5F76,0x8A24,0x5F78,0x316D,0x0000,0x5F73, +0x0000,0x8A25,0x0000,0x0000,0x8A26,0x0000,0x0000,0x535B, +0x5F7A,0x0000,0x0000,0x0000,0x0000,0x4167,0x3B38,0x5F7C, +0x0000,0x0000,0x0000,0x0000,0x5F7B,0x3F24,0x5259,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x5F7D,0x0000,0x0000, +0x0000,0x6021,0x0000,0x5F6E,0x5F7E,0x0000,0x7761,0x6022, + +/* 7200h */ +0x7762,0x0000,0x0000,0x0000,0x0000,0x0000,0x477A,0x8A27, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6023,0x0000,0x0000, +0x6024,0x0000,0x0000,0x0000,0x0000,0x7763,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6025,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6026,0x0000,0x445E,0x8A2A,0x6028,0x6027,0x0000,0x0000, +0x6029,0x0000,0x602A,0x0000,0x8A2B,0x3C5F,0x4963,0x0000, +0x8A2C,0x8A2D,0x4C6C,0x602B,0x602C,0x4156,0x3C24,0x602D, +0x602E,0x0000,0x8A2F,0x0000,0x0000,0x0000,0x602F,0x4A52, +0x4847,0x0000,0x0000,0x6030,0x4757,0x0000,0x0000,0x0000, +0x0000,0x0000,0x442D,0x8A30,0x0000,0x7764,0x7765,0x8A31, +0x6031,0x3267,0x0000,0x356D,0x0000,0x4C46,0x0000,0x4C36, +0x0000,0x3234,0x4F34,0x8A32,0x0000,0x0000,0x0000,0x4B52, +0x0000,0x4A2A,0x0000,0x0000,0x0000,0x0000,0x8A34,0x8A35, +0x0000,0x0000,0x4037,0x0000,0x6032,0x0000,0x0000,0x0000, +0x8A36,0x4643,0x0000,0x0000,0x0000,0x3823,0x6033,0x8A37, +0x3A54,0x6035,0x6034,0x0000,0x0000,0x0000,0x0000,0x6036, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7767,0x8A38,0x0000, +0x0000,0x0000,0x6037,0x0000,0x0000,0x0000,0x6038,0x0000, +0x0000,0x0000,0x0000,0x7768,0x0000,0x0000,0x0000,0x0000, +0x353E,0x0000,0x6039,0x0000,0x0000,0x0000,0x0000,0x603A, +0x0000,0x0000,0x0000,0x0000,0x3824,0x8A3A,0x8A3B,0x4848, +0x8A3C,0x8A3D,0x603C,0x0000,0x0000,0x0000,0x3E75,0x0000, +0x0000,0x603B,0x0000,0x0000,0x0000,0x0000,0x7769,0x0000, +0x776A,0x8A3E,0x3638,0x603D,0x603F,0x0000,0x603E,0x0000, +0x0000,0x0000,0x0000,0x0000,0x8A40,0x0000,0x6040,0x0000, +0x3851,0x0000,0x6041,0x0000,0x0000,0x0000,0x0000,0x3669, +0x0000,0x4140,0x0000,0x397D,0x0000,0x0000,0x0000,0x0000, +0x6043,0x6044,0x6042,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3C6D,0x0000,0x0000,0x4648,0x3639,0x0000,0x0000, +0x0000,0x0000,0x0000,0x8A43,0x0000,0x0000,0x0000,0x6046, +0x432C,0x6045,0x8A44,0x776B,0x4F35,0x4762,0x0000,0x0000, + +/* 7300h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x8A45, +0x0000,0x0000,0x6049,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x8A46,0x0000,0x0000,0x0000,0x604B,0x6048, +0x8A47,0x8A48,0x0000,0x4C54,0x604A,0x604C,0x0000,0x4E44, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6050,0x0000,0x776D, +0x776E,0x604F,0x4376,0x472D,0x8A4B,0x0000,0x3825,0x604E, +0x0000,0x8A4C,0x0000,0x8A4D,0x604D,0x0000,0x4D31,0x4D32, +0x0000,0x8A4A,0x0000,0x0000,0x0000,0x8A4E,0x6051,0x316E, +0x0000,0x0000,0x0000,0x0000,0x3976,0x3B62,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6052,0x6053, +0x7770,0x0000,0x8A4F,0x0000,0x0000,0x0000,0x0000,0x6055, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3D43,0x0000,0x0000,0x7771,0x0000, +0x6057,0x0000,0x6056,0x8A51,0x8A52,0x0000,0x8A54,0x8A55, +0x6058,0x8A56,0x334D,0x0000,0x0000,0x605A,0x0000,0x8A57, +0x6059,0x0000,0x605C,0x605B,0x7772,0x0000,0x0000,0x0000, +0x0000,0x8A58,0x0000,0x0000,0x383C,0x8A59,0x0000,0x4E28, +0x0000,0x364C,0x8A5A,0x3226,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x8A5B,0x7773,0x366A,0x0000, +0x8A5C,0x0000,0x0000,0x0000,0x8A5D,0x0000,0x8A5E,0x7774, +0x7775,0x0000,0x7776,0x0000,0x0000,0x8A5F,0x7777,0x0000, +0x8A60,0x3461,0x0000,0x7778,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4E68,0x605E,0x0000,0x8A61,0x0000,0x8A62, +0x0000,0x8A63,0x0000,0x6060,0x8A64,0x0000,0x0000,0x8A65, +0x6061,0x0000,0x3251,0x0000,0x0000,0x8A66,0x0000,0x0000, +0x605D,0x7779,0x3B39,0x8A67,0x0000,0x4441,0x605F,0x777A, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x777B,0x0000, +0x0000,0x777C,0x0000,0x0000,0x0000,0x0000,0x6064,0x0000, +0x3C6E,0x8A68,0x0000,0x777D,0x0000,0x6062,0x0000,0x8A69, +0x0000,0x777E,0x373E,0x0000,0x0000,0x4849,0x6063,0x0000, +0x0000,0x607E,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6069,0x8A6A,0x8A6C,0x0000,0x0000,0x0000,0x383D,0x0000, + +/* 7400h */ +0x0000,0x8A6D,0x0000,0x3565,0x0000,0x6066,0x4D7D,0x7821, +0x0000,0x4E30,0x7822,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x8A6B,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7823,0x7824,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4276,0x0000,0x8A6E,0x6068,0x7826,0x0000, +0x7827,0x0000,0x7828,0x7829,0x782A,0x0000,0x782B,0x782C, +0x782D,0x8A6F,0x606A,0x4E56,0x3657,0x487C,0x474A,0x0000, +0x0000,0x8A70,0x606B,0x0000,0x0000,0x0000,0x0000,0x606D, +0x8A72,0x6070,0x0000,0x8A73,0x782E,0x0000,0x782F,0x7830, +0x0000,0x0000,0x0000,0x7831,0x0000,0x8A74,0x0000,0x0000, +0x0000,0x0000,0x8A75,0x8A71,0x0000,0x606C,0x0000,0x7832, +0x0000,0x606F,0x386A,0x314D,0x6071,0x8A76,0x3F70,0x606E, +0x4E5C,0x0000,0x7833,0x6074,0x7424,0x0000,0x0000,0x0000, +0x0000,0x6072,0x6075,0x7834,0x0000,0x7835,0x0000,0x6067, +0x6073,0x8A77,0x0000,0x3A3C,0x0000,0x0000,0x6076,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6077,0x0000, +0x0000,0x8A78,0x0000,0x4D7E,0x0000,0x8A79,0x7836,0x7837, +0x8A7A,0x7838,0x0000,0x6078,0x0000,0x0000,0x0000,0x0000, +0x783D,0x0000,0x8A7C,0x0000,0x0000,0x0000,0x0000,0x8A7D, +0x7839,0x8A7E,0x0000,0x0000,0x783A,0x0000,0x6079,0x783B, +0x8B21,0x8B22,0x6065,0x783C,0x0000,0x8B23,0x783E,0x607A, +0x783F,0x7840,0x8B24,0x8B25,0x0000,0x0000,0x0000,0x0000, +0x3444,0x0000,0x0000,0x0000,0x0000,0x7841,0x0000,0x0000, +0x0000,0x8B26,0x8B28,0x8B27,0x0000,0x3C25,0x0000,0x7842, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7843,0x7844,0x607B,0x0000,0x0000,0x0000,0x0000,0x607C, +0x0000,0x0000,0x0000,0x0000,0x607D,0x0000,0x8B29,0x0000, +0x8B2A,0x0000,0x7845,0x0000,0x313B,0x0000,0x8B2B,0x0000, +0x6121,0x0000,0x493B,0x6122,0x0000,0x0000,0x3424,0x6123, +0x0000,0x6124,0x0000,0x8B2D,0x0000,0x0000,0x6125,0x8B2C, +0x6127,0x6128,0x6126,0x0000,0x0000,0x0000,0x4953,0x612A, +0x6129,0x0000,0x8B2F,0x0000,0x0000,0x0000,0x0000,0x7846, + +/* 7500h */ +0x0000,0x7847,0x0000,0x612C,0x612B,0x612D,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x612E,0x6130,0x612F,0x0000, +0x0000,0x3979,0x0000,0x6132,0x0000,0x6131,0x0000,0x7848, +0x3445,0x0000,0x3F53,0x0000,0x453C,0x0000,0x6133,0x4038, +0x8B31,0x0000,0x0000,0x3B3A,0x8B32,0x3179,0x6134,0x0000, +0x4D51,0x0000,0x8B33,0x4A63,0x6135,0x0000,0x0000,0x7849, +0x4544,0x4D33,0x3943,0x3F3D,0x0000,0x0000,0x0000,0x434B, +0x5234,0x0000,0x442E,0x3268,0x6136,0x8B36,0x8B37,0x0000, +0x8B38,0x0000,0x0000,0x0000,0x6137,0x0000,0x613C,0x0000, +0x8B39,0x613A,0x6139,0x5A42,0x3326,0x6138,0x8B3A,0x305A, +0x8B3B,0x482A,0x8B3C,0x0000,0x484A,0x0000,0x0000,0x0000, +0x0000,0x4E31,0x613D,0x613B,0x435C,0x4026,0x0000,0x0000, +0x482B,0x0000,0x492D,0x0000,0x613F,0x4E2C,0x374D,0x6140, +0x0000,0x613E,0x4856,0x6141,0x8B3D,0x6142,0x0000,0x784A, +0x305B,0x8B3F,0x8B3E,0x3E76,0x6147,0x0000,0x6144,0x466D, +0x6143,0x784B,0x8B40,0x0000,0x0000,0x8B41,0x8B42,0x3526, +0x0000,0x8B43,0x614A,0x0000,0x0000,0x0000,0x6145,0x6146, +0x0000,0x6149,0x6148,0x4925,0x8B45,0x0000,0x4142,0x4141, +0x0000,0x353F,0x784C,0x0000,0x614B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x614C,0x0000,0x0000,0x614D,0x0000,0x0000, +0x0000,0x0000,0x8B47,0x614F,0x0000,0x614E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3156,0x0000,0x0000,0x0000,0x0000, +0x8B49,0x6157,0x4868,0x6151,0x0000,0x6153,0x0000,0x8B4A, +0x6155,0x3F3E,0x0000,0x0000,0x6156,0x6154,0x3C40,0x8B4B, +0x8B4C,0x0000,0x6150,0x6152,0x0000,0x4942,0x8B4D,0x3E49, +0x0000,0x0000,0x6159,0x0000,0x0000,0x6158,0x784E,0x8B4E, +0x0000,0x0000,0x615A,0x8B4F,0x3C26,0x3A2F,0x0000,0x0000, +0x4577,0x615B,0x0000,0x444B,0x0000,0x8B50,0x615D,0x8B51, +0x8B52,0x0000,0x4E21,0x615C,0x784F,0x0000,0x0000,0x8B53, +0x0000,0x4169,0x0000,0x0000,0x8B54,0x0000,0x8B55,0x0000, +0x6162,0x8B56,0x6164,0x6165,0x4354,0x0000,0x0000,0x0000, +0x0000,0x8B57,0x6163,0x0000,0x6160,0x0000,0x615E,0x615F, + +/* 7600h */ +0x7850,0x6161,0x7851,0x8B58,0x0000,0x0000,0x0000,0x8B5A, +0x7852,0x6168,0x0000,0x6166,0x0000,0x6167,0x0000,0x8B5B, +0x0000,0x0000,0x0000,0x8B5E,0x0000,0x7853,0x7854,0x0000, +0x8B59,0x7855,0x0000,0x8B5F,0x8B60,0x0000,0x7856,0x6169, +0x616B,0x616C,0x616D,0x0000,0x616E,0x8B62,0x7E7D,0x616A, +0x8B63,0x0000,0x0000,0x0000,0x0000,0x7857,0x0000,0x0000, +0x6170,0x0000,0x0000,0x8B65,0x616F,0x7858,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6171,0x8B64,0x0000,0x0000,0x0000, +0x0000,0x8B68,0x4E45,0x7859,0x0000,0x0000,0x6174,0x6172, +0x6173,0x8B6A,0x0000,0x785A,0x3462,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4C7E,0x0000,0x0000,0x8B6B,0x4A4A,0x0000, +0x6176,0x0000,0x0000,0x0000,0x6175,0x0000,0x0000,0x0000, +0x0000,0x6177,0x6178,0x0000,0x785B,0x785C,0x0000,0x617C, +0x6179,0x617A,0x617B,0x0000,0x617D,0x785D,0x8B6D,0x785E, +0x617E,0x785F,0x6221,0x0000,0x0000,0x0000,0x6222,0x0000, +0x6223,0x0000,0x482F,0x4550,0x6224,0x4772,0x4934,0x0000, +0x6225,0x7860,0x0000,0x6226,0x452A,0x0000,0x3327,0x3944, +0x6227,0x0000,0x0000,0x6228,0x0000,0x0000,0x6229,0x0000, +0x3B29,0x0000,0x0000,0x622B,0x0000,0x8B6E,0x622A,0x0000, +0x0000,0x622C,0x622D,0x7861,0x8B6F,0x7862,0x7863,0x0000, +0x8B71,0x8B70,0x0000,0x0000,0x0000,0x0000,0x7864,0x8B72, +0x8B73,0x0000,0x7865,0x0000,0x0000,0x0000,0x4869,0x8B74, +0x622E,0x0000,0x0000,0x0000,0x622F,0x0000,0x7866,0x7369, +0x6230,0x6231,0x6232,0x0000,0x0000,0x0000,0x0000,0x3B2E, +0x0000,0x0000,0x6233,0x4756,0x0000,0x7867,0x4B5F,0x0000, +0x314E,0x8B76,0x3157,0x0000,0x7868,0x6234,0x7869,0x0000, +0x0000,0x0000,0x6236,0x0000,0x786A,0x0000,0x6235,0x4570, +0x0000,0x0000,0x0000,0x4039,0x5D39,0x0000,0x6237,0x4C41, +0x0000,0x6238,0x0000,0x3446,0x4857,0x6239,0x786B,0x623A, +0x8B78,0x0000,0x623B,0x0000,0x8B79,0x0000,0x4C5C,0x0000, +0x0000,0x786C,0x4C55,0x0000,0x443E,0x0000,0x0000,0x0000, +0x416A,0x0000,0x0000,0x623D,0x786D,0x0000,0x3D62,0x0000, + +/* 7700h */ +0x0000,0x3E4A,0x0000,0x0000,0x6240,0x0000,0x0000,0x623F, +0x623E,0x487D,0x786E,0x3447,0x3829,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x8B7B, +0x0000,0x786F,0x8B7C,0x6246,0x0000,0x0000,0x6243,0x3F3F, +0x4C32,0x0000,0x0000,0x0000,0x6242,0x6244,0x6245,0x0000, +0x0000,0x6241,0x0000,0x0000,0x0000,0x8B7D,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x7870,0x8B7E,0x7871,0x6247, +0x6248,0x0000,0x442F,0x0000,0x3463,0x0000,0x0000,0x0000, +0x4365,0x0000,0x0000,0x0000,0x0000,0x0000,0x7872,0x6249, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7873,0x7874,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8C25,0x0000,0x624A,0x624D,0x7875,0x0000,0x0000,0x7876, +0x8C26,0x3F67,0x7877,0x4644,0x0000,0x624E,0x4B53,0x0000, +0x624B,0x0000,0x8C27,0x624C,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x8C29,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6251,0x7878,0x0000,0x8C2A,0x8C2B,0x6250,0x624F, +0x7879,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6253,0x0000,0x0000,0x6252,0x0000, +0x0000,0x6254,0x0000,0x0000,0x787A,0x0000,0x0000,0x0000, +0x0000,0x0000,0x8C2E,0x0000,0x0000,0x0000,0x6256,0x8C2F, +0x6255,0x0000,0x8C30,0x0000,0x8C31,0x4A4D,0x0000,0x0000, +0x0000,0x8C32,0x787B,0x0000,0x3D56,0x4E46,0x0000,0x0000, +0x6257,0x0000,0x0000,0x4637,0x0000,0x0000,0x6258,0x0000, +0x0000,0x6259,0x0000,0x625D,0x625B,0x625C,0x0000,0x625A, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x625E, +0x0000,0x0000,0x0000,0x0000,0x0000,0x625F,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6260, +0x0000,0x0000,0x6261,0x4C37,0x6262,0x0000,0x8C33,0x8C34, +0x787C,0x0000,0x4C70,0x6263,0x8C35,0x434E,0x8C36,0x476A, +0x0000,0x366B,0x8C37,0x0000,0x8C38,0x433B,0x6264,0x363A, +0x8C3A,0x0000,0x0000,0x4050,0x8C3B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x8C3C,0x6265,0x0000,0x0000,0x0000, + +/* 7800h */ +0x0000,0x0000,0x3A3D,0x0000,0x0000,0x8C3E,0x8C3F,0x0000, +0x0000,0x8C40,0x0000,0x0000,0x6266,0x8C41,0x0000,0x0000, +0x0000,0x0000,0x6267,0x0000,0x3826,0x3A55,0x0000,0x0000, +0x0000,0x8C42,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6269,0x8C43,0x0000,0x0000,0x0000,0x4556,0x3A56,0x354E, +0x0000,0x0000,0x0000,0x0000,0x8C44,0x787D,0x0000,0x0000, +0x0000,0x0000,0x4B24,0x0000,0x474B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x4557,0x0000,0x0000,0x0000,0x0000,0x395C, +0x0000,0x0000,0x0000,0x7921,0x0000,0x626B,0x0000,0x8C45, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7922,0x7923, +0x0000,0x7924,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x3E4B,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x8C46,0x0000,0x0000,0x0000, +0x7925,0x0000,0x8C47,0x4E32,0x3945,0x0000,0x7926,0x3827, +0x0000,0x0000,0x4823,0x0000,0x626D,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x626F,0x0000,0x0000,0x0000, +0x0000,0x386B,0x0000,0x0000,0x0000,0x0000,0x626E,0x4476, +0x0000,0x0000,0x8C49,0x0000,0x6271,0x3337,0x626C,0x0000, +0x0000,0x486A,0x0000,0x3130,0x8C4A,0x3A6C,0x0000,0x4F52, +0x0000,0x0000,0x6270,0x0000,0x0000,0x8C4C,0x8C4D,0x8C4E, +0x0000,0x0000,0x0000,0x6272,0x8C4B,0x0000,0x0000,0x4A4B, +0x0000,0x4059,0x6274,0x0000,0x0000,0x792A,0x0000,0x6275, +0x7928,0x0000,0x0000,0x0000,0x0000,0x6273,0x0000,0x0000, +0x0000,0x0000,0x334E,0x8C4F,0x627B,0x0000,0x627A,0x0000, +0x0000,0x3C27,0x0000,0x0000,0x0000,0x627C,0x6277,0x0000, +0x8C50,0x0000,0x627D,0x6278,0x8C51,0x0000,0x8C52,0x0000, +0x4858,0x6276,0x0000,0x0000,0x6279,0x8C53,0x0000,0x0000, +0x0000,0x0000,0x6322,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8C54,0x8C55,0x0000,0x0000,0x792B,0x0000,0x8C56,0x6321, +0x4B61,0x0000,0x0000,0x0000,0x627E,0x0000,0x0000,0x306B, +0x0000,0x0000,0x792C,0x0000,0x6324,0x0000,0x0000,0x792E, +0x0000,0x8C57,0x8C58,0x8C59,0x0000,0x6323,0x8C5A,0x0000, + +/* 7900h */ +0x792D,0x3E4C,0x0000,0x0000,0x0000,0x0000,0x0000,0x6325, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4143,0x0000, +0x8C5C,0x6327,0x6326,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6328,0x0000,0x8C5D,0x792F,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x8C5F,0x6268,0x0000, +0x0000,0x0000,0x626A,0x632A,0x6329,0x0000,0x7930,0x0000, +0x8C5E,0x7931,0x0000,0x0000,0x7932,0x0000,0x0000,0x0000, +0x0000,0x0000,0x3C28,0x8C60,0x4E69,0x0000,0x3C52,0x0000, +0x632B,0x3737,0x0000,0x0000,0x0000,0x7935,0x7936,0x3540, +0x3527,0x3B63,0x8C61,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4D34,0x0000,0x0000,0x6331,0x0000,0x6330,0x4144,0x632D, +0x8C62,0x0000,0x632F,0x8C63,0x793A,0x3D4B,0x3F40,0x632E, +0x632C,0x0000,0x472A,0x0000,0x0000,0x3E4D,0x0000,0x8C65, +0x493C,0x0000,0x0000,0x0000,0x0000,0x3A57,0x0000,0x0000, +0x0000,0x0000,0x8C66,0x0000,0x0000,0x0000,0x0000,0x4578, +0x0000,0x793E,0x6332,0x0000,0x0000,0x0000,0x0000,0x6333, +0x6349,0x3658,0x0000,0x0000,0x4F3D,0x4135,0x0000,0x0000, +0x0000,0x0000,0x6334,0x0000,0x0000,0x3252,0x4477,0x4A21, +0x0000,0x0000,0x0000,0x0000,0x8C67,0x8C68,0x8C69,0x0000, +0x7942,0x0000,0x0000,0x8C6A,0x0000,0x6335,0x0000,0x0000, +0x0000,0x8C6B,0x0000,0x0000,0x0000,0x0000,0x357A,0x6336, +0x0000,0x8C6C,0x6338,0x0000,0x0000,0x0000,0x6339,0x0000, +0x4729,0x7943,0x0000,0x633A,0x8C6D,0x0000,0x0000,0x0000, +0x7944,0x633B,0x633C,0x8C6E,0x0000,0x3659,0x3253,0x4645, +0x3D28,0x3B64,0x8C6F,0x0000,0x0000,0x0000,0x0000,0x8C70, +0x7945,0x633D,0x7946,0x3D29,0x8C71,0x8C72,0x0000,0x0000, +0x0000,0x324A,0x4943,0x0000,0x7948,0x633E,0x8C73,0x0000, +0x486B,0x0000,0x0000,0x0000,0x0000,0x0000,0x7949,0x4145, +0x0000,0x6341,0x0000,0x6342,0x4769,0x0000,0x3F41,0x633F, +0x0000,0x4361,0x0000,0x794A,0x6340,0x794B,0x0000,0x0000, +0x3E4E,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x305C,0x0000,0x0000,0x0000,0x0000, + +/* 7A00h */ +0x3529,0x0000,0x0000,0x794C,0x0000,0x0000,0x0000,0x0000, +0x6343,0x0000,0x8C78,0x4478,0x0000,0x6344,0x4047,0x0000, +0x0000,0x8C79,0x0000,0x0000,0x4C2D,0x8C7A,0x0000,0x4923, +0x6345,0x6346,0x4355,0x8C7B,0x4E47,0x0000,0x8C7C,0x6348, +0x6347,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x8C7E,0x3C6F,0x0000, +0x0000,0x634A,0x3070,0x0000,0x0000,0x0000,0x0000,0x634D, +0x8D21,0x794E,0x0000,0x634B,0x3254,0x374E,0x634C,0x3946, +0x3972,0x0000,0x4A66,0x634E,0x0000,0x0000,0x4B54,0x8D22, +0x0000,0x6350,0x0000,0x0000,0x8D23,0x4051,0x314F,0x323A, +0x302C,0x0000,0x0000,0x0000,0x0000,0x0000,0x8D24,0x634F, +0x0000,0x8D25,0x0000,0x0000,0x8D26,0x794F,0x0000,0x8D27, +0x8D28,0x6351,0x6352,0x3E77,0x0000,0x0000,0x0000,0x8D29, +0x0000,0x6353,0x8D2A,0x334F,0x0000,0x7950,0x0000,0x0000, +0x6355,0x0000,0x0000,0x0000,0x376A,0x8D2B,0x3566,0x0000, +0x8D2C,0x6356,0x3675,0x0000,0x0000,0x6357,0x0000,0x407C, +0x0000,0x464D,0x8D2D,0x4060,0x3A75,0x7952,0x0000,0x0000, +0x6358,0x0000,0x8D2E,0x0000,0x0000,0x0000,0x0000,0x0000, +0x8D2F,0x0000,0x4362,0x416B,0x0000,0x635A,0x635C,0x6359, +0x635B,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3722, +0x7953,0x0000,0x0000,0x8D30,0x0000,0x0000,0x0000,0x0000, +0x0000,0x635D,0x3726,0x0000,0x8D31,0x0000,0x3567,0x4D52, +0x635F,0x0000,0x0000,0x7955,0x0000,0x0000,0x6360,0x0000, +0x0000,0x8D34,0x312E,0x7956,0x8D35,0x0000,0x8D36,0x6363, +0x0000,0x0000,0x0000,0x3376,0x6362,0x6361,0x0000,0x6365, +0x635E,0x0000,0x6366,0x4E29,0x8D38,0x6367,0x7957,0x6368, +0x0000,0x8D39,0x5474,0x636A,0x0000,0x6369,0x0000,0x0000, +0x0000,0x636B,0x636C,0x0000,0x4E35,0x636D,0x0000,0x706F, +0x3E4F,0x636E,0x636F,0x3D57,0x0000,0x4638,0x6370,0x8D3A, +0x8D3B,0x0000,0x4328,0x7958,0x0000,0x6371,0x0000,0x433C, +0x6372,0x0000,0x0000,0x0000,0x8D3C,0x0000,0x3625,0x0000, +0x513F,0x435D,0x3C33,0x0000,0x0000,0x7959,0x0000,0x3448, + +/* 7B00h */ +0x0000,0x0000,0x6373,0x0000,0x6422,0x0000,0x6376,0x8D3F, +0x3568,0x0000,0x6375,0x6424,0x0000,0x0000,0x0000,0x6374, +0x0000,0x3E50,0x795A,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6378,0x6379,0x0000,0x452B,0x0000,0x0000,0x637A,0x0000, +0x335E,0x0000,0x0000,0x0000,0x0000,0x3F5A,0x4964,0x8D42, +0x637C,0x0000,0x8D43,0x0000,0x4268,0x795B,0x8D44,0x8D45, +0x0000,0x8D46,0x0000,0x6377,0x0000,0x637B,0x637D,0x0000, +0x0000,0x3A7B,0x0000,0x795C,0x0000,0x8D41,0x0000,0x0000, +0x0000,0x8D4A,0x0000,0x0000,0x0000,0x6426,0x492E,0x795D, +0x4826,0x4579,0x0000,0x365A,0x6425,0x6423,0x795E,0x4835, +0x637E,0x435E,0x457B,0x0000,0x457A,0x8D4C,0x3A76,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6438,0x0000,0x0000, +0x795F,0x0000,0x0000,0x0000,0x8D4E,0x6428,0x8D4F,0x642A, +0x0000,0x8D50,0x0000,0x0000,0x642D,0x7960,0x642E,0x7961, +0x642B,0x642C,0x7962,0x8D51,0x6429,0x6427,0x0000,0x0000, +0x0000,0x8D4D,0x6421,0x0000,0x0000,0x0000,0x0000,0x8D49, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4A4F,0x3255, +0x0000,0x0000,0x0000,0x6435,0x0000,0x6432,0x0000,0x6437, +0x8D54,0x8D55,0x6436,0x0000,0x4773,0x4C27,0x0000,0x3B3B, +0x6430,0x6439,0x6434,0x8D56,0x6433,0x642F,0x7963,0x6431, +0x0000,0x3449,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x433D,0x0000,0x0000,0x407D,0x0000,0x8D58, +0x0000,0x4822,0x0000,0x0000,0x643E,0x8D59,0x0000,0x0000, +0x4824,0x0000,0x0000,0x0000,0x8D5A,0x0000,0x0000,0x0000, +0x4061,0x643B,0x0000,0x0000,0x484F,0x8D5B,0x643F,0x4A53, +0x0000,0x435B,0x8D5C,0x643A,0x643C,0x0000,0x0000,0x643D, +0x0000,0x0000,0x0000,0x0000,0x8D5F,0x0000,0x8D60,0x7965, +0x0000,0x7966,0x8D61,0x0000,0x0000,0x6440,0x0000,0x0000, +0x3C44,0x0000,0x0000,0x0000,0x4646,0x6445,0x6444,0x0000, +0x0000,0x6441,0x8D62,0x0000,0x0000,0x4F36,0x0000,0x0000, +0x8D63,0x0000,0x0000,0x644A,0x0000,0x0000,0x644E,0x644B, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 7C00h */ +0x6447,0x7967,0x0000,0x8D64,0x0000,0x0000,0x0000,0x6448, +0x0000,0x0000,0x0000,0x8D65,0x0000,0x644D,0x8D66,0x8D67, +0x0000,0x6442,0x5255,0x6449,0x6443,0x0000,0x0000,0x644C, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7969,0x6452, +0x796A,0x344A,0x0000,0x644F,0x0000,0x0000,0x8D68,0x6450, +0x0000,0x0000,0x6451,0x6454,0x0000,0x0000,0x0000,0x0000, +0x0000,0x7968,0x0000,0x796B,0x0000,0x0000,0x796C,0x6453, +0x4876,0x0000,0x0000,0x0000,0x0000,0x6455,0x4E7C,0x4A6D, +0x645A,0x0000,0x0000,0x6457,0x0000,0x8D69,0x0000,0x0000, +0x0000,0x0000,0x8D6A,0x0000,0x6456,0x4052,0x0000,0x6459, +0x645B,0x8D6B,0x0000,0x0000,0x6458,0x0000,0x645F,0x8D6C, +0x645C,0x796F,0x0000,0x0000,0x0000,0x0000,0x8D6D,0x645D, +0x6446,0x8D6E,0x0000,0x0000,0x645E,0x6460,0x0000,0x0000, +0x0000,0x8D6F,0x0000,0x0000,0x6461,0x7970,0x8D70,0x8D71, +0x8D72,0x0000,0x0000,0x4A46,0x0000,0x6462,0x0000,0x0000, +0x0000,0x7971,0x0000,0x0000,0x0000,0x0000,0x4C62,0x0000, +0x0000,0x364E,0x3729,0x6463,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4A34,0x0000,0x3F68,0x0000,0x4C30,0x0000,0x7972, +0x6464,0x0000,0x4E33,0x0000,0x7973,0x4774,0x0000,0x4146, +0x4734,0x0000,0x0000,0x3D4D,0x0000,0x0000,0x0000,0x3040, +0x7974,0x6469,0x6467,0x0000,0x6465,0x3421,0x8D76,0x3E51, +0x646A,0x0000,0x0000,0x6468,0x0000,0x6466,0x646E,0x0000, +0x0000,0x646D,0x646C,0x646B,0x0000,0x0000,0x8D78,0x8D79, +0x0000,0x646F,0x0000,0x0000,0x7975,0x6470,0x403A,0x8D7A, +0x6471,0x0000,0x6473,0x0000,0x8D7C,0x6472,0x0000,0x0000, +0x8D7E,0x0000,0x3852,0x0000,0x0000,0x8E21,0x4138,0x0000, +0x0000,0x0000,0x6475,0x0000,0x0000,0x7976,0x457C,0x8E23, +0x6474,0x7977,0x0000,0x0000,0x6476,0x7978,0x4A35,0x416C, +0x3947,0x0000,0x6477,0x0000,0x0000,0x0000,0x8E25,0x4E48, +0x0000,0x0000,0x0000,0x8E26,0x0000,0x0000,0x0000,0x6479, +0x0000,0x0000,0x647A,0x0000,0x647B,0x8E28,0x647C,0x0000, +0x3B65,0x0000,0x647D,0x374F,0x0000,0x0000,0x356A,0x0000, + +/* 7D00h */ +0x352A,0x0000,0x6521,0x8E29,0x4C73,0x3948,0x647E,0x7979, +0x797A,0x8E2A,0x6524,0x4C66,0x0000,0x473C,0x0000,0x0000, +0x4933,0x0000,0x8E2C,0x797B,0x3D63,0x6523,0x0000,0x3C53, +0x3949,0x3B66,0x3569,0x4A36,0x6522,0x797C,0x8E2D,0x0000, +0x4147,0x4B42,0x3A77,0x797D,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3B67,0x445D,0x0000,0x6527,0x4E5F, +0x3A59,0x797E,0x6528,0x3F42,0x0000,0x652A,0x0000,0x0000, +0x0000,0x3E52,0x3A30,0x0000,0x0000,0x8E30,0x8E31,0x6529, +0x8E32,0x7A21,0x3D2A,0x383E,0x4148,0x6525,0x652B,0x8E33, +0x7A22,0x0000,0x0000,0x6526,0x3750,0x0000,0x652E,0x6532, +0x376B,0x0000,0x0000,0x7A23,0x0000,0x0000,0x652D,0x0000, +0x0000,0x8E37,0x8E38,0x6536,0x7A24,0x0000,0x394A,0x0000, +0x0000,0x4D6D,0x303C,0x6533,0x0000,0x0000,0x356B,0x0000, +0x6530,0x0000,0x8E39,0x0000,0x0000,0x0000,0x6531,0x0000, +0x8E3A,0x457D,0x652F,0x652C,0x0000,0x3328,0x4064,0x0000, +0x0000,0x3828,0x7A25,0x0000,0x0000,0x6538,0x0000,0x8E3C, +0x0000,0x0000,0x0000,0x7A26,0x0000,0x0000,0x8E3E,0x0000, +0x8E3F,0x6535,0x0000,0x7A27,0x8E40,0x0000,0x0000,0x6537, +0x0000,0x0000,0x0000,0x6534,0x0000,0x0000,0x0000,0x8E41, +0x0000,0x3751,0x4233,0x6539,0x416E,0x8E43,0x0000,0x6546, +0x7A28,0x0000,0x6542,0x653C,0x0000,0x0000,0x7A29,0x8E44, +0x0000,0x0000,0x8E45,0x6540,0x3C7A,0x305D,0x653B,0x6543, +0x6547,0x394B,0x4C56,0x0000,0x4456,0x653D,0x8E46,0x8E47, +0x6545,0x0000,0x653A,0x433E,0x0000,0x653F,0x303D,0x4C4A, +0x8E48,0x0000,0x7A2A,0x0000,0x0000,0x0000,0x0000,0x653E, +0x0000,0x0000,0x365B,0x486C,0x7A2B,0x0000,0x0000,0x416D, +0x0000,0x4E50,0x3D6F,0x0000,0x0000,0x656E,0x7A2C,0x8E49, +0x6548,0x8E4A,0x407E,0x0000,0x6544,0x6549,0x654B,0x0000, +0x4479,0x654E,0x0000,0x7A2D,0x654A,0x0000,0x8E4B,0x0000, +0x4A54,0x344B,0x0000,0x0000,0x4C4B,0x0000,0x0000,0x305E, +0x0000,0x8E4C,0x654D,0x0000,0x4E7D,0x0000,0x0000,0x0000, +0x0000,0x8E4D,0x0000,0x654C,0x0000,0x0000,0x0000,0x0000, + +/* 7E00h */ +0x0000,0x316F,0x0000,0x0000,0x466C,0x654F,0x0000,0x0000, +0x7A30,0x6556,0x6550,0x6557,0x0000,0x0000,0x0000,0x0000, +0x8E51,0x7A31,0x6553,0x0000,0x0000,0x7A32,0x0000,0x8E52, +0x0000,0x0000,0x0000,0x477B,0x0000,0x8E53,0x3C4A,0x6555, +0x8E54,0x6552,0x6558,0x6551,0x0000,0x0000,0x3D44,0x8E55, +0x7A2F,0x0000,0x0000,0x4B25,0x8E56,0x0000,0x3D4C,0x0000, +0x0000,0x6554,0x6560,0x0000,0x0000,0x655C,0x0000,0x655F, +0x0000,0x655D,0x6561,0x655B,0x0000,0x6541,0x4053,0x0000, +0x0000,0x484B,0x0000,0x655E,0x0000,0x8E57,0x6559,0x7A34, +0x0000,0x0000,0x4121,0x3752,0x0000,0x3D2B,0x0000,0x0000, +0x0000,0x0000,0x7A35,0x0000,0x3F25,0x4136,0x6564,0x0000, +0x0000,0x6566,0x6567,0x0000,0x0000,0x6563,0x6565,0x0000, +0x0000,0x7A36,0x0000,0x0000,0x0000,0x0000,0x655A,0x6562, +0x0000,0x656A,0x6569,0x7E7E,0x0000,0x4B7A,0x0000,0x0000, +0x372B,0x0000,0x0000,0x8E58,0x0000,0x8E59,0x0000,0x0000, +0x0000,0x6568,0x0000,0x656C,0x656B,0x656F,0x8E5A,0x6571, +0x0000,0x0000,0x3B3C,0x656D,0x0000,0x0000,0x8E5B,0x8E5C, +0x6572,0x6573,0x7A37,0x0000,0x6574,0x7A38,0x657A,0x453B, +0x6576,0x8E5E,0x6575,0x6577,0x6578,0x0000,0x6579,0x0000, +0x8E5F,0x0000,0x8E60,0x657B,0x657C,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 7F00h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x344C,0x0000, +0x657D,0x0000,0x657E,0x8E63,0x8E62,0x0000,0x8E64,0x0000, +0x0000,0x0000,0x0000,0x8E65,0x8E66,0x6621,0x0000,0x7A39, +0x0000,0x0000,0x0000,0x0000,0x6622,0x6623,0x6624,0x8E67, +0x6625,0x6626,0x8E6A,0x0000,0x6628,0x6627,0x0000,0x0000, +0x6629,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x662A, +0x662B,0x8E6C,0x0000,0x8E6D,0x8E6E,0x0000,0x0000,0x662E, +0x662C,0x662D,0x3A61,0x3753,0x0000,0x8E6F,0x4356,0x0000, +0x4833,0x0000,0x3D70,0x0000,0x0000,0x474D,0x0000,0x486D, +0x662F,0x586D,0x0000,0x0000,0x0000,0x8E70,0x8E71,0x0000, +0x0000,0x0000,0x6630,0x6632,0x0000,0x4D65,0x6631,0x6634, +0x6633,0x0000,0x4D53,0x0000,0x6635,0x0000,0x487E,0x0000, +0x8E73,0x7A3B,0x0000,0x0000,0x6636,0x0000,0x8E76,0x7A3C, +0x0000,0x0000,0x6639,0x0000,0x8E77,0x6638,0x6637,0x0000, +0x0000,0x0000,0x0000,0x663A,0x3732,0x0000,0x0000,0x0000, +0x4122,0x3541,0x0000,0x0000,0x0000,0x8E78,0x663E,0x663B, +0x0000,0x0000,0x663C,0x0000,0x0000,0x0000,0x663F,0x0000, +0x6640,0x663D,0x0000,0x0000,0x0000,0x3129,0x0000,0x7A3D, +0x0000,0x3227,0x0000,0x8E7A,0x0000,0x6642,0x6643,0x0000, +0x0000,0x0000,0x6644,0x0000,0x4D62,0x0000,0x7A3E,0x8E7B, +0x0000,0x0000,0x3D2C,0x0000,0x6646,0x6645,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7A3F,0x0000,0x0000,0x0000,0x7A40, +0x3F69,0x6647,0x0000,0x8E7C,0x0000,0x8E7D,0x6648,0x0000, +0x0000,0x6649,0x0000,0x3465,0x7A41,0x0000,0x7A42,0x8E7E, +0x344D,0x0000,0x8F21,0x664A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x664B,0x7A43,0x4B5D,0x4D63,0x0000,0x0000,0x0000, + +/* 8000h */ +0x4D54,0x4F37,0x8F22,0x394D,0x664E,0x3C54,0x664D,0x0000, +0x8F24,0x0000,0x8F23,0x664F,0x3C29,0x0000,0x8F25,0x0000, +0x4251,0x8F26,0x6650,0x0000,0x7A45,0x394C,0x8F27,0x4C57, +0x6651,0x6652,0x0000,0x0000,0x6653,0x0000,0x0000,0x0000, +0x0000,0x6654,0x0000,0x0000,0x8F28,0x0000,0x7A46,0x0000, +0x6655,0x0000,0x0000,0x0000,0x8F29,0x0000,0x0000,0x0000, +0x8F2A,0x0000,0x0000,0x3C2A,0x0000,0x7A47,0x4C6D,0x7A48, +0x0000,0x0000,0x0000,0x6657,0x7A49,0x433F,0x0000,0x6656, +0x0000,0x0000,0x0000,0x8F2B,0x0000,0x0000,0x6659,0x0000, +0x0000,0x0000,0x6658,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x665A,0x0000,0x0000,0x0000,0x403B,0x0000, +0x665B,0x0000,0x665C,0x0000,0x0000,0x0000,0x4A39,0x665D, +0x0000,0x416F,0x665E,0x0000,0x0000,0x0000,0x8F2C,0x0000, +0x665F,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4E7E, +0x6662,0x8F2D,0x6661,0x6660,0x4430,0x8F2E,0x6663,0x3F26, +0x0000,0x6664,0x0000,0x8F2F,0x0000,0x6665,0x4F38,0x6666, +0x0000,0x0000,0x0000,0x0000,0x6667,0x6669,0x6668,0x4825, +0x0000,0x4679,0x0000,0x4F3E,0x4829,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x666B,0x0000,0x0000,0x3E53,0x0000, +0x492A,0x8F30,0x666C,0x666A,0x8F31,0x344E,0x0000,0x0000, +0x0000,0x3854,0x3B68,0x0000,0x8F32,0x486E,0x0000,0x8F33, +0x0000,0x382A,0x4B43,0x0000,0x666F,0x666D,0x0000,0x394E, +0x0000,0x394F,0x3069,0x0000,0x3A68,0x0000,0x0000,0x0000, +0x8F34,0x0000,0x4759,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x305F,0x6674,0x8F36,0x4340,0x0000, +0x0000,0x0000,0x7A4A,0x0000,0x4758,0x0000,0x425B,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x8F37,0x6676,0x7A4B, +0x8F38,0x6672,0x6675,0x6670,0x0000,0x6673,0x4B26,0x0000, +0x7A4C,0x3855,0x0000,0x0000,0x307D,0x6671,0x8F39,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6678, +0x0000,0x6679,0x0000,0x7A4D,0x4639,0x8F3C,0x0000,0x0000, +0x363B,0x0000,0x0000,0x8F3D,0x6726,0x473D,0x0000,0x0000, + +/* 8100h */ +0x0000,0x0000,0x3B69,0x0000,0x0000,0x363C,0x4048,0x4F46, +0x4C2E,0x6677,0x4054,0x0000,0x0000,0x8F3B,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x8F40,0x0000, +0x7A4E,0x0000,0x3553,0x667A,0x0000,0x0000,0x8F41,0x0000, +0x0000,0x0000,0x0000,0x667C,0x8F43,0x0000,0x0000,0x8F44, +0x0000,0x667B,0x0000,0x0000,0x8F45,0x0000,0x0000,0x667D, +0x0000,0x4326,0x0000,0x473E,0x0000,0x8F3F,0x0000,0x0000, +0x0000,0x4431,0x0000,0x0000,0x0000,0x8F47,0x6723,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6722,0x0000, +0x0000,0x0000,0x7A4F,0x667E,0x0000,0x0000,0x3F55,0x0000, +0x4965,0x6725,0x0000,0x6724,0x3950,0x4F53,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6735, +0x7A50,0x0000,0x0000,0x0000,0x0000,0x6729,0x672A,0x7A51, +0x7A52,0x8F49,0x0000,0x3C70,0x0000,0x7A53,0x6728,0x0000, +0x3978,0x6727,0x0000,0x0000,0x672B,0x0000,0x0000,0x0000, +0x4432,0x4A22,0x4123,0x0000,0x0000,0x0000,0x0000,0x425C, +0x672F,0x8F4B,0x6730,0x672C,0x8F4D,0x8F4E,0x0000,0x0000, +0x672D,0x0000,0x672E,0x0000,0x0000,0x0000,0x0000,0x3951, +0x0000,0x0000,0x0000,0x6736,0x0000,0x6732,0x0000,0x0000, +0x8F50,0x0000,0x4966,0x0000,0x4B6C,0x4928,0x0000,0x0000, +0x6731,0x0000,0x0000,0x6734,0x6733,0x0000,0x0000,0x0000, +0x4B44,0x6737,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6738,0x0000,0x8F51,0x4137,0x0000,0x6739,0x0000,0x0000, +0x673B,0x0000,0x673F,0x7A54,0x0000,0x673C,0x673A,0x473F, +0x673D,0x8F52,0x673E,0x8F53,0x0000,0x0000,0x3232,0x0000, +0x6745,0x6740,0x7A55,0x0000,0x0000,0x6741,0x0000,0x7A56, +0x0000,0x6742,0x0000,0x4221,0x0000,0x0000,0x8F54,0x7A57, +0x6744,0x6743,0x6746,0x8F55,0x0000,0x0000,0x0000,0x6747, +0x6748,0x0000,0x0000,0x3F43,0x8F57,0x3269,0x0000,0x6749, +0x4E57,0x0000,0x3C2B,0x0000,0x8F59,0x3D2D,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3B6A,0x4357,0x0000,0x0000,0x0000, +0x0000,0x0000,0x674A,0x674B,0x3131,0x8F5B,0x674C,0x8F5C, + +/* 8200h */ +0x0000,0x674D,0x674E,0x0000,0x8F5E,0x674F,0x0000,0x6750, +0x363D,0x5A2A,0x6751,0x0000,0x4065,0x6752,0x3C4B,0x0000, +0x6753,0x0000,0x5030,0x0000,0x0000,0x0000,0x6754,0x4A5E, +0x345C,0x8F60,0x0000,0x4124,0x3D58,0x0000,0x4971,0x3D2E, +0x0000,0x8F61,0x8F62,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6755,0x3952,0x6756,0x484C,0x0000,0x6764,0x0000, +0x0000,0x0000,0x8F64,0x6758,0x8F65,0x4249,0x4775,0x383F, +0x6757,0x4125,0x0000,0x0000,0x8F66,0x0000,0x0000,0x0000, +0x6759,0x0000,0x0000,0x0000,0x0000,0x8F69,0x8F67,0x447A, +0x0000,0x8F68,0x0000,0x8F6B,0x0000,0x0000,0x0000,0x8F6D, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x8F6F, +0x675B,0x675A,0x675D,0x0000,0x8F71,0x675C,0x0000,0x675E, +0x7A5B,0x0000,0x6760,0x8F72,0x675F,0x0000,0x344F,0x0000, +0x6761,0x0000,0x6762,0x6763,0x0000,0x0000,0x3A31,0x4E49, +0x0000,0x6765,0x3F27,0x0000,0x7A5C,0x0000,0x3170,0x6766, +0x6767,0x8F76,0x0000,0x0000,0x0000,0x8F78,0x6768,0x8F79, +0x0000,0x0000,0x0000,0x8F7A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x8F7B,0x3072,0x0000,0x6769,0x7A5E,0x0000, +0x0000,0x0000,0x676A,0x8F7C,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4967,0x0000,0x0000,0x0000,0x3C47,0x0000,0x676C, +0x0000,0x7A5F,0x0000,0x7A60,0x7A61,0x3329,0x3032,0x8F7D, +0x8F7E,0x7A62,0x0000,0x676B,0x676E,0x474E,0x7A63,0x3F44, +0x0000,0x3256,0x9021,0x4B27,0x9022,0x0000,0x0000,0x7A64, +0x375D,0x365C,0x9023,0x676D,0x9024,0x326A,0x7A65,0x7A66, +0x0000,0x0000,0x0000,0x0000,0x0000,0x3423,0x7A67,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3171,0x6772,0x4E6A,0x425D,0x7A68,0x0000,0x4944, +0x0000,0x677E,0x0000,0x3257,0x677C,0x0000,0x677A,0x6771, +0x0000,0x676F,0x9025,0x6770,0x0000,0x3C63,0x366C,0x4377, +0x9026,0x0000,0x0000,0x4651,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3151,0x0000,0x6774,0x6773,0x0000,0x0000,0x9027, +0x0000,0x6779,0x6775,0x6778,0x0000,0x7A69,0x7A6A,0x0000, + +/* 8300h */ +0x7A6B,0x7A6C,0x4C50,0x6777,0x3258,0x337D,0x677B,0x9028, +0x9029,0x677D,0x0000,0x0000,0x902A,0x0000,0x3754,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6823,0x682C, +0x682D,0x0000,0x0000,0x902C,0x302B,0x902D,0x0000,0x0000, +0x0000,0x0000,0x7A6E,0x6834,0x0000,0x0000,0x0000,0x0000, +0x3071,0x0000,0x0000,0x682B,0x0000,0x7A6F,0x0000,0x682A, +0x902E,0x6825,0x6824,0x0000,0x6822,0x6821,0x4363,0x0000, +0x427B,0x6827,0x7A70,0x0000,0x902F,0x0000,0x0000,0x0000, +0x6826,0x0000,0x0000,0x7A71,0x9030,0x6829,0x0000,0x7A72, +0x0000,0x4170,0x3755,0x0000,0x0000,0x0000,0x0000,0x3141, +0x6828,0x7A73,0x3953,0x0000,0x902B,0x7A74,0x0000,0x9031, +0x4171,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7A6D,0x864A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x683A,0x0000,0x683B,0x0000,0x3259, +0x0000,0x0000,0x0000,0x322E,0x6838,0x7A75,0x0000,0x9033, +0x0000,0x0000,0x0000,0x0000,0x0000,0x682E,0x7A76,0x6836, +0x0000,0x683D,0x6837,0x0000,0x0000,0x9036,0x6835,0x0000, +0x0000,0x0000,0x7A77,0x6776,0x9037,0x9038,0x6833,0x0000, +0x7A78,0x0000,0x682F,0x9039,0x0000,0x903A,0x3450,0x6831, +0x683C,0x0000,0x6832,0x0000,0x0000,0x0000,0x0000,0x7A79, +0x683E,0x7A7A,0x6830,0x477C,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4D69,0x0000,0x0000,0x0000,0x6839,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x684F,0x0000,0x7A7B, +0x7A7C,0x6847,0x0000,0x0000,0x0000,0x3F7B,0x0000,0x7A7D, +0x0000,0x903B,0x3546,0x0000,0x365D,0x0000,0x6842,0x7A7E, +0x903C,0x7B21,0x0000,0x325B,0x903D,0x0000,0x3E54,0x0000, +0x6845,0x0000,0x0000,0x0000,0x3A5A,0x903E,0x0000,0x4551, +0x684A,0x7B22,0x0000,0x0000,0x0000,0x903F,0x0000,0x0000, +0x0000,0x4A6E,0x7B23,0x6841,0x0000,0x0000,0x0000,0x325A, +0x3856,0x4929,0x684B,0x0000,0x683F,0x0000,0x0000,0x6848, +0x0000,0x9040,0x0000,0x6852,0x0000,0x6843,0x0000,0x0000, + +/* 8400h */ +0x0000,0x7B24,0x0000,0x6844,0x463A,0x0000,0x7B25,0x6849, +0x0000,0x0000,0x7B26,0x6846,0x4B28,0x684C,0x3060,0x9041, +0x0000,0x9042,0x0000,0x6840,0x0000,0x9043,0x0000,0x9045, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x684E,0x0000,0x684D,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x476B,0x6854,0x0000,0x685F,0x0000,0x0000,0x0000, +0x0000,0x337E,0x0000,0x0000,0x0000,0x6862,0x0000,0x0000, +0x6850,0x9046,0x0000,0x0000,0x6855,0x4D6E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x685E,0x0000, +0x7B28,0x4D55,0x9047,0x0000,0x0000,0x0000,0x4E2A,0x9048, +0x0000,0x9049,0x904A,0x0000,0x0000,0x0000,0x0000,0x4378, +0x0000,0x904B,0x904C,0x336B,0x904D,0x0000,0x0000,0x7B29, +0x0000,0x4972,0x6864,0x4621,0x0000,0x904F,0x3031,0x0000, +0x0000,0x685D,0x0000,0x6859,0x4172,0x6853,0x685B,0x6860, +0x7B2A,0x472C,0x0000,0x7B2B,0x0000,0x302A,0x9050,0x6858, +0x9051,0x6861,0x4978,0x0000,0x9052,0x0000,0x0000,0x0000, +0x0000,0x9053,0x685C,0x0000,0x6857,0x7B2C,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3E55,0x0000,0x0000,0x0000,0x0000, +0x3D2F,0x0000,0x0000,0x0000,0x3C2C,0x0000,0x0000,0x9056, +0x0000,0x4C58,0x0000,0x0000,0x4947,0x0000,0x7B2D,0x6867, +0x0000,0x6870,0x0000,0x0000,0x0000,0x0000,0x9057,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x685A,0x0000,0x7B2E, +0x0000,0x0000,0x3377,0x0000,0x7B2F,0x0000,0x0000,0x0000, +0x3E78,0x6865,0x7B30,0x686A,0x4173,0x0000,0x9058,0x6866, +0x7B31,0x686D,0x7B32,0x0000,0x435F,0x0000,0x686E,0x0000, +0x0000,0x4D56,0x6863,0x3338,0x0000,0x6869,0x905A,0x905B, +0x686C,0x4C2C,0x0000,0x905C,0x0000,0x0000,0x686F,0x0000, +0x0000,0x6868,0x686B,0x0000,0x9055,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x905E, +0x0000,0x0000,0x905F,0x0000,0x4B29,0x0000,0x4F21,0x9060, +0x9061,0x9062,0x0000,0x0000,0x6873,0x0000,0x0000,0x0000, +0x0000,0x0000,0x9063,0x0000,0x687A,0x9064,0x0000,0x6872, + +/* 8500h */ +0x3C43,0x0000,0x0000,0x0000,0x0000,0x0000,0x6851,0x0000, +0x0000,0x0000,0x0000,0x0000,0x9065,0x0000,0x0000,0x0000, +0x0000,0x4A4E,0x0000,0x4C22,0x6879,0x6878,0x0000,0x6874, +0x6875,0x0000,0x3136,0x9066,0x0000,0x0000,0x7B35,0x6877, +0x0000,0x6871,0x0000,0x7B36,0x9067,0x9068,0x4455,0x0000, +0x0000,0x0000,0x0000,0x9069,0x6876,0x307E,0x0000,0x7B37, +0x0000,0x0000,0x7B34,0x0000,0x906A,0x4222,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x4A43,0x906F,0x0000, +0x687B,0x6921,0x0000,0x4859,0x0000,0x0000,0x0000,0x0000, +0x687E,0x3E56,0x3C49,0x6923,0x0000,0x0000,0x363E,0x906B, +0x0000,0x9070,0x0000,0x9071,0x0000,0x6924,0x0000,0x4979, +0x687D,0x7B38,0x6856,0x0000,0x0000,0x0000,0x9072,0x0000, +0x0000,0x9073,0x9074,0x687C,0x7B39,0x0000,0x0000,0x0000, +0x4F4F,0x4622,0x4973,0x0000,0x0000,0x692B,0x0000,0x906C, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6931, +0x0000,0x0000,0x7B3C,0x9076,0x0000,0x9077,0x6932,0x9078, +0x6925,0x9079,0x0000,0x0000,0x4776,0x0000,0x907A,0x692F, +0x6927,0x0000,0x6929,0x0000,0x7B3D,0x0000,0x0000,0x7B3E, +0x6933,0x6928,0x0000,0x907B,0x692C,0x0000,0x0000,0x3172, +0x0000,0x4665,0x0000,0x692D,0x6930,0x907C,0x0000,0x907D, +0x0000,0x0000,0x7B3F,0x0000,0x6926,0x0000,0x4126,0x0000, +0x692A,0x3B27,0x3F45,0x3730,0x4C74,0x7B3B,0x4C79,0x3D72, +0x7B40,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x9123, +0x0000,0x6937,0x6935,0x0000,0x9124,0x0000,0x0000,0x0000, +0x0000,0x4F4E,0x0000,0x0000,0x0000,0x0000,0x0000,0x9125, +0x0000,0x6934,0x9126,0x7B41,0x0000,0x4D75,0x7B42,0x6936, +0x6938,0x0000,0x0000,0x0000,0x0000,0x6939,0x0000,0x0000, +0x9127,0x9128,0x0000,0x0000,0x693C,0x693A,0x0000,0x9129, +0x0000,0x912A,0x0000,0x0000,0x4623,0x693B,0x912B,0x0000, +0x0000,0x484D,0x692E,0x0000,0x0000,0x7B43,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x912C,0x3D73, +0x0000,0x693D,0x6942,0x4174,0x0000,0x0000,0x6941,0x7B45, + +/* 8600h */ +0x912D,0x0000,0x6922,0x0000,0x7B46,0x7B47,0x6943,0x4149, +0x0000,0x0000,0x693E,0x6940,0x0000,0x0000,0x0000,0x0000, +0x7B48,0x912E,0x7B44,0x693F,0x0000,0x0000,0x5D31,0x5D22, +0x7B4A,0x0000,0x6945,0x0000,0x0000,0x0000,0x912F,0x0000, +0x0000,0x9130,0x6944,0x0000,0x9131,0x0000,0x0000,0x9132, +0x0000,0x7B4B,0x0000,0x0000,0x0000,0x4D76,0x0000,0x623C, +0x6946,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7B4C,0x9134,0x0000,0x0000,0x9135,0x0000,0x0000,0x6947, +0x9137,0x2F68,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6948,0x3857,0x0000, +0x3554,0x0000,0x0000,0x9139,0x694A,0x515D,0x913A,0x7B4D, +0x0000,0x0000,0x3575,0x7B4E,0x4E3A,0x0000,0x3673,0x694B, +0x0000,0x0000,0x7B50,0x0000,0x0000,0x0000,0x0000,0x694C, +0x0000,0x0000,0x0000,0x436E,0x7B52,0x0000,0x0000,0x913B, +0x0000,0x694D,0x0000,0x0000,0x0000,0x7B53,0x0000,0x913C, +0x0000,0x467A,0x913D,0x303A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x913E, +0x0000,0x913F,0x3263,0x6952,0x6953,0x9140,0x0000,0x0000, +0x0000,0x9141,0x0000,0x694E,0x0000,0x3B3D,0x0000,0x0000, +0x7B54,0x0000,0x0000,0x0000,0x9142,0x9143,0x0000,0x0000, +0x0000,0x0000,0x0000,0x694F,0x4742,0x0000,0x0000,0x0000, +0x9144,0x6950,0x6951,0x695B,0x0000,0x0000,0x0000,0x6955, +0x6958,0x9146,0x0000,0x9147,0x0000,0x0000,0x6954,0x0000, +0x7B55,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x9148,0x0000,0x9149,0x6956,0x0000,0x6957,0x3C58, +0x0000,0x6959,0x0000,0x4341,0x0000,0x3756,0x3342,0x0000, +0x0000,0x914A,0x0000,0x0000,0x695C,0x914B,0x0000,0x914C, +0x0000,0x333F,0x0000,0x6961,0x0000,0x0000,0x695D,0x6960, +0x0000,0x0000,0x0000,0x914D,0x483A,0x0000,0x914E,0x0000, +0x0000,0x695E,0x0000,0x0000,0x695F,0x4948,0x485A,0x6962, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x427D,0x696C,0x7B56,0x6968,0x7B57,0x7B58,0x326B,0x0000, + +/* 8700h */ +0x6966,0x0000,0x4B2A,0x6967,0x0000,0x9150,0x6964,0x9151, +0x6965,0x696A,0x696D,0x7B59,0x0000,0x696B,0x9152,0x0000, +0x9153,0x6969,0x6963,0x9154,0x0000,0x0000,0x0000,0x0000, +0x4358,0x9155,0x6974,0x0000,0x4C2A,0x0000,0x0000,0x9156, +0x0000,0x9157,0x0000,0x9158,0x0000,0x6972,0x0000,0x0000, +0x0000,0x6973,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x9159,0x0000,0x0000,0x696E,0x0000,0x0000,0x6970, +0x0000,0x0000,0x915A,0x6971,0x0000,0x0000,0x915B,0x696F, +0x915C,0x0000,0x0000,0x915D,0x0000,0x0000,0x0000,0x0000, +0x0000,0x4066,0x0000,0x4F39,0x6978,0x0000,0x6979,0x0000, +0x0000,0x915E,0x0000,0x6A21,0x0000,0x3F2A,0x0000,0x697B, +0x915F,0x697E,0x0000,0x0000,0x0000,0x0000,0x0000,0x6976, +0x6975,0x0000,0x0000,0x6A22,0x9160,0x9161,0x325C,0x0000, +0x697C,0x0000,0x6A23,0x0000,0x0000,0x0000,0x697D,0x0000, +0x0000,0x7B5A,0x9162,0x0000,0x697A,0x0000,0x4433,0x0000, +0x6977,0x0000,0x0000,0x0000,0x9163,0x0000,0x0000,0x4768, +0x0000,0x0000,0x6A27,0x0000,0x0000,0x0000,0x0000,0x7B5B, +0x7B5C,0x9167,0x0000,0x9168,0x0000,0x4D3B,0x0000,0x0000, +0x0000,0x0000,0x0000,0x9169,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6A26, +0x916A,0x0000,0x6A25,0x0000,0x0000,0x0000,0x0000,0x9166, +0x0000,0x0000,0x0000,0x6A2E,0x7B5D,0x7B5E,0x0000,0x6A28, +0x0000,0x0000,0x0000,0x6A30,0x0000,0x7B5F,0x0000,0x0000, +0x0000,0x0000,0x4D66,0x6A33,0x0000,0x6A2A,0x916D,0x0000, +0x6A2B,0x916F,0x0000,0x0000,0x6A2F,0x0000,0x6A32,0x6A31, +0x0000,0x0000,0x0000,0x6A29,0x0000,0x0000,0x9170,0x0000, +0x6A2C,0x0000,0x6A3D,0x0000,0x0000,0x0000,0x7B61,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x9172, +0x6A36,0x0000,0x0000,0x9174,0x0000,0x9175,0x9176,0x0000, +0x0000,0x0000,0x9177,0x9178,0x7B62,0x9179,0x0000,0x6A34, +0x0000,0x0000,0x6A35,0x0000,0x0000,0x9171,0x6A3A,0x6A3B, +0x0000,0x332A,0x0000,0x3542,0x0000,0x0000,0x6A39,0x0000, + +/* 8800h */ +0x0000,0x917A,0x0000,0x917B,0x0000,0x6A24,0x7B63,0x0000, +0x0000,0x0000,0x7B64,0x917C,0x0000,0x6A38,0x6A3C,0x6A37, +0x7B65,0x6A3E,0x0000,0x917D,0x7B66,0x6A40,0x6A3F,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7B67, +0x0000,0x6A42,0x6A41,0x695A,0x0000,0x0000,0x0000,0x6A46, +0x917E,0x0000,0x0000,0x0000,0x0000,0x0000,0x9221,0x0000, +0x0000,0x6A43,0x9222,0x0000,0x0000,0x0000,0x6A44,0x0000, +0x0000,0x6A45,0x0000,0x6A47,0x9223,0x0000,0x0000,0x0000, +0x376C,0x0000,0x6A49,0x0000,0x6A48,0x0000,0x3D30,0x0000, +0x0000,0x0000,0x9225,0x0000,0x3954,0x5E27,0x0000,0x0000, +0x0000,0x0000,0x6A4A,0x3D51,0x0000,0x0000,0x0000,0x3339, +0x9226,0x6A4B,0x0000,0x3152,0x0000,0x3E57,0x6A4C,0x9227, +0x0000,0x3955,0x6A4D,0x3061,0x9228,0x0000,0x0000,0x0000, +0x493D,0x922B,0x0000,0x6A4E,0x0000,0x0000,0x0000,0x922D, +0x3F6A,0x0000,0x6A55,0x0000,0x0000,0x6A52,0x0000,0x436F, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6A53,0x6A50,0x365E, +0x0000,0x6A4F,0x6A56,0x0000,0x0000,0x0000,0x0000,0x0000, +0x3736,0x0000,0x0000,0x425E,0x0000,0x6A5C,0x0000,0x0000, +0x0000,0x0000,0x6A58,0x0000,0x0000,0x0000,0x4235,0x6A57, +0x7B68,0x6A5A,0x0000,0x0000,0x0000,0x0000,0x6A51,0x0000, +0x922E,0x0000,0x6A5B,0x0000,0x6A5D,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7B69,0x486F,0x0000,0x0000,0x6A59,0x0000, +0x6A5E,0x6A60,0x0000,0x0000,0x3853,0x6A54,0x0000,0x3041, +0x0000,0x0000,0x0000,0x0000,0x922F,0x9230,0x9231,0x6A5F, +0x9232,0x3A5B,0x4E76,0x6A61,0x6A62,0x4175,0x0000,0x0000, +0x0000,0x0000,0x7B6A,0x0000,0x0000,0x0000,0x7B6B,0x4E22, +0x0000,0x9235,0x9233,0x9236,0x6A63,0x4D35,0x0000,0x0000, +0x6A64,0x6A65,0x0000,0x9237,0x4A64,0x6A66,0x0000,0x3A40, +0x0000,0x4E23,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6A6B,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x9238,0x9239,0x6A6C,0x3E58,0x6A6A,0x7B6D,0x0000,0x0000, +0x4D67,0x6A67,0x0000,0x0000,0x6A69,0x403D,0x3F7E,0x0000, + +/* 8900h */ +0x0000,0x923B,0x6A68,0x0000,0x6A6D,0x0000,0x0000,0x4A23, +0x0000,0x0000,0x6A6F,0x0000,0x6A6E,0x0000,0x0000,0x0000, +0x336C,0x0000,0x4B2B,0x6A70,0x0000,0x0000,0x0000,0x0000, +0x7B70,0x7B71,0x7B72,0x0000,0x7B6E,0x6A7C,0x6A72,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6A73,0x0000,0x7B73, +0x0000,0x0000,0x6A74,0x6A75,0x0000,0x0000,0x0000,0x0000, +0x7B74,0x0000,0x7B75,0x0000,0x0000,0x0000,0x6A79,0x923D, +0x6A7A,0x7B76,0x0000,0x6A78,0x0000,0x0000,0x0000,0x0000, +0x7B77,0x6A76,0x923F,0x6A71,0x6A77,0x9240,0x0000,0x0000, +0x0000,0x9241,0x0000,0x0000,0x6A7B,0x7037,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3228,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6A7E,0x365F, +0x6A7D,0x0000,0x9244,0x0000,0x6B22,0x0000,0x6B21,0x0000, +0x0000,0x0000,0x6B24,0x0000,0x0000,0x6B23,0x0000,0x6B25, +0x0000,0x0000,0x3D31,0x0000,0x6B26,0x0000,0x0000,0x6B27, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6B28,0x403E, +0x9245,0x4D57,0x0000,0x6B29,0x0000,0x0000,0x4A24,0x4746, +0x6B2A,0x9246,0x6B2B,0x382B,0x0000,0x0000,0x0000,0x352C, +0x9247,0x0000,0x0000,0x6B2C,0x7B78,0x0000,0x3B6B,0x4741, +0x6B2D,0x0000,0x3350,0x0000,0x0000,0x0000,0x0000,0x9248, +0x0000,0x6B2E,0x0000,0x0000,0x0000,0x0000,0x6B30,0x4D77, +0x0000,0x6B2F,0x3F46,0x0000,0x6B31,0x0000,0x0000,0x6B32, +0x9249,0x0000,0x6B33,0x3451,0x0000,0x0000,0x0000,0x924A, +0x0000,0x0000,0x6B34,0x0000,0x0000,0x6B35,0x0000,0x6B36, +0x6B37,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x3351,0x0000,0x7B7A,0x0000,0x924B,0x0000, +0x924C,0x0000,0x6B38,0x0000,0x6B39,0x6B3A,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3272,0x0000,0x7B7B,0x3F28,0x6B3B, +0x0000,0x0000,0x0000,0x924D,0x0000,0x0000,0x0000,0x0000, +0x0000,0x924F,0x0000,0x9250,0x6B3C,0x0000,0x7B7C,0x0000, +0x6B3D,0x0000,0x0000,0x0000,0x0000,0x9251,0x0000,0x9252, + +/* 8A00h */ +0x3840,0x0000,0x447B,0x6B3E,0x0000,0x0000,0x0000,0x0000, +0x3757,0x0000,0x3F56,0x0000,0x6B41,0x0000,0x4624,0x0000, +0x6B40,0x9254,0x7B7D,0x3731,0x9255,0x7B7E,0x6B3F,0x4277, +0x352D,0x0000,0x0000,0x6B42,0x0000,0x6B43,0x0000,0x3E59, +0x0000,0x9257,0x7C21,0x376D,0x0000,0x6B44,0x0000,0x0000, +0x0000,0x0000,0x4B2C,0x0000,0x0000,0x405F,0x0000,0x0000, +0x0000,0x3576,0x0000,0x4C75,0x414A,0x9258,0x6B45,0x7C22, +0x0000,0x0000,0x3F47,0x4370,0x3E5A,0x0000,0x9259,0x0000, +0x0000,0x6B46,0x0000,0x0000,0x0000,0x925A,0x6B49,0x7C23, +0x6B4A,0x0000,0x0000,0x0000,0x0000,0x925B,0x7C24,0x0000, +0x3A3E,0x4242,0x6B48,0x0000,0x3E5B,0x493E,0x0000,0x0000, +0x925C,0x0000,0x0000,0x6B47,0x0000,0x7C25,0x3B6C,0x0000, +0x3153,0x7C26,0x6B4E,0x3758,0x0000,0x0000,0x3B6E,0x0000, +0x0000,0x3B6D,0x0000,0x4F4D,0x6B4D,0x6B4C,0x4127,0x0000, +0x354D,0x4F43,0x333A,0x3E5C,0x0000,0x7C27,0x0000,0x0000, +0x0000,0x7C28,0x0000,0x0000,0x6B4B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6B50,0x0000,0x6B51,0x6B4F,0x0000,0x3858, +0x0000,0x4D40,0x0000,0x0000,0x3B6F,0x4727,0x0000,0x0000, +0x925E,0x6B54,0x0000,0x4040,0x0000,0x4342,0x0000,0x0000, +0x4D36,0x0000,0x6B57,0x0000,0x0000,0x0000,0x386C,0x0000, +0x403F,0x6B53,0x0000,0x6B58,0x386D,0x6B55,0x6B56,0x7C29, +0x6B52,0x0000,0x0000,0x0000,0x4062,0x4649,0x925D,0x0000, +0x432F,0x0000,0x325D,0x0000,0x0000,0x0000,0x0000,0x925F, +0x0000,0x4870,0x0000,0x0000,0x3543,0x0000,0x9260,0x4434, +0x0000,0x0000,0x6B5B,0x0000,0x6B59,0x0000,0x0000,0x434C, +0x0000,0x0000,0x0000,0x4041,0x3452,0x6B5A,0x0000,0x3F5B, +0x7C2A,0x0000,0x4E4A,0x0000,0x0000,0x0000,0x4F40,0x9261, +0x0000,0x0000,0x6B5C,0x6B67,0x4435,0x0000,0x6B66,0x7C2B, +0x6B63,0x6B6B,0x6B64,0x0000,0x6B60,0x0000,0x447C,0x6B5F, +0x0000,0x0000,0x0000,0x6B5D,0x0000,0x4D21,0x3B70,0x0000, +0x0000,0x6B61,0x0000,0x6B5E,0x7C2C,0x0000,0x7C2D,0x6B65, +0x3D74,0x0000,0x3841,0x0000,0x9262,0x0000,0x427A,0x0000, + +/* 8B00h */ +0x4B45,0x315A,0x3062,0x0000,0x4625,0x9265,0x0000,0x6B69, +0x0000,0x0000,0x9264,0x0000,0x6B68,0x9266,0x4666,0x0000, +0x6B6D,0x0000,0x0000,0x0000,0x6B62,0x0000,0x6B6C,0x6B6E, +0x0000,0x382C,0x6B6A,0x3956,0x9267,0x3C55,0x0000,0x9268, +0x6B6F,0x4D58,0x0000,0x0000,0x0000,0x0000,0x6B72,0x0000, +0x6B75,0x0000,0x0000,0x6B73,0x4935,0x9269,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6B70,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3660,0x0000,0x0000,0x0000,0x0000,0x6B74,0x0000, +0x0000,0x6B76,0x0000,0x926A,0x0000,0x0000,0x7C31,0x0000, +0x0000,0x6B7A,0x0000,0x0000,0x6B77,0x0000,0x6B79,0x6B78, +0x0000,0x926C,0x0000,0x0000,0x7C32,0x0000,0x6B7B,0x0000, +0x3C31,0x7C33,0x6B7D,0x6B7C,0x4968,0x0000,0x926D,0x6C21, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3759,0x0000, +0x0000,0x7C34,0x0000,0x6B7E,0x6C22,0x0000,0x0000,0x6C23, +0x3544,0x6641,0x3E79,0x0000,0x6C24,0x0000,0x926E,0x386E, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6C25,0x0000,0x926F, +0x6C26,0x9270,0x0000,0x3B3E,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x5A4E,0x9271,0x6C27,0x0000,0x6C28,0x0000, +0x3D32,0x0000,0x6C29,0x6C2A,0x9272,0x9273,0x6C2B,0x0000, +0x0000,0x6C2C,0x6C2D,0x0000,0x9274,0x7C35,0x9275,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 8C00h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x432B, +0x0000,0x9276,0x6C2E,0x0000,0x0000,0x9278,0x0000,0x6C30, +0x0000,0x6C2F,0x0000,0x0000,0x0000,0x927B,0x4626,0x927C, +0x6C31,0x7C36,0x4B2D,0x0000,0x6C32,0x0000,0x6C33,0x927D, +0x6C34,0x0000,0x0000,0x0000,0x927E,0x6C35,0x0000,0x9321, +0x0000,0x0000,0x465A,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3E5D,0x6C36,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7C37,0x9322,0x396B,0x502E,0x6C37,0x9323,0x0000,0x0000, +0x0000,0x0000,0x0000,0x9324,0x0000,0x0000,0x0000,0x0000, +0x6C38,0x493F,0x6C39,0x0000,0x6C41,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6C3A,0x0000,0x0000,0x6C3C,0x0000,0x0000, +0x0000,0x6C3B,0x6C3D,0x0000,0x4B46,0x6C3E,0x6C3F,0x0000, +0x0000,0x0000,0x9327,0x9326,0x6C40,0x0000,0x0000,0x0000, +0x6C42,0x9328,0x0000,0x932A,0x0000,0x332D,0x4467,0x0000, +0x4969,0x3A62,0x3957,0x0000,0x932B,0x0000,0x0000,0x494F, +0x325F,0x484E,0x6C45,0x3453,0x4055,0x6C44,0x6C49,0x4379, +0x4C63,0x0000,0x6C47,0x6C48,0x352E,0x0000,0x6C4A,0x4763, +0x425F,0x0000,0x0000,0x4871,0x453D,0x6C46,0x0000,0x4B47, +0x326C,0x6C4C,0x4F28,0x4442,0x4F45,0x0000,0x0000,0x3B71, +0x6C4B,0x0000,0x4231,0x0000,0x0000,0x6C5C,0x4128,0x0000, +0x0000,0x4678,0x0000,0x4950,0x0000,0x932D,0x932C,0x0000, +0x0000,0x932E,0x6C4F,0x3B3F,0x3B72,0x0000,0x3E5E,0x0000, +0x4765,0x7C39,0x382D,0x6C4E,0x6C4D,0x0000,0x496A,0x0000, +0x0000,0x0000,0x3C41,0x0000,0x0000,0x4552,0x0000,0x0000, +0x9330,0x9331,0x0000,0x0000,0x7C3A,0x0000,0x0000,0x0000, +0x7C3B,0x0000,0x6C51,0x6C52,0x3958,0x6C50,0x7C3C,0x0000, + +/* 8D00h */ +0x0000,0x0000,0x0000,0x0000,0x6C53,0x6C54,0x0000,0x6C56, +0x4223,0x9333,0x6C55,0x3466,0x0000,0x6C58,0x9334,0x6C57, +0x6C59,0x0000,0x7C3E,0x6C5B,0x6C5D,0x0000,0x6C5E,0x0000, +0x0000,0x0000,0x0000,0x7C3F,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x4056,0x0000,0x3C4F,0x6C5F, +0x0000,0x0000,0x0000,0x3352,0x9335,0x6C60,0x0000,0x0000, +0x4176,0x6C61,0x0000,0x6C62,0x496B,0x0000,0x0000,0x352F, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6C63,0x0000,0x0000,0x9336,0x4436,0x0000,0x0000, +0x0000,0x0000,0x315B,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x9337,0x0000,0x0000, +0x0000,0x6C64,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3C71,0x0000,0x0000,0x9338,0x0000, +0x3F76,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7C40, +0x0000,0x0000,0x0000,0x422D,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6C67,0x0000,0x0000,0x0000,0x6C66,0x0000, +0x0000,0x0000,0x6C65,0x0000,0x0000,0x0000,0x933A,0x0000, +0x933B,0x0000,0x0000,0x6C6D,0x6C6B,0x0000,0x7C41,0x6C68, +0x0000,0x7C42,0x0000,0x0000,0x0000,0x0000,0x6C6A,0x7C43, +0x0000,0x933C,0x6C69,0x6C6C,0x0000,0x3577,0x0000,0x6C70, +0x0000,0x4057,0x0000,0x6C71,0x0000,0x0000,0x0000,0x0000, +0x3859,0x0000,0x6C6E,0x6C6F,0x933D,0x0000,0x0000,0x4F29, +0x0000,0x0000,0x0000,0x4437,0x0000,0x4129,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x6C72,0x9340,0x0000,0x6C75, + +/* 8E00h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x9341,0x0000, +0x6C73,0x6C74,0x4D59,0x0000,0x933E,0x0000,0x0000,0x4627, +0x6C78,0x0000,0x0000,0x0000,0x9343,0x0000,0x9344,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x6C76,0x6C77,0x6C79, +0x7C44,0x9345,0x9346,0x7C45,0x0000,0x0000,0x0000,0x9347, +0x0000,0x0000,0x6D29,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6C7C,0x0000,0x0000,0x0000,0x6C7D,0x6C7B,0x934A,0x0000, +0x0000,0x934B,0x0000,0x0000,0x0000,0x7C46,0x0000,0x0000, +0x0000,0x0000,0x6C7A,0x0000,0x447D,0x0000,0x0000,0x6D21, +0x6D25,0x6D22,0x6C7E,0x934C,0x6D23,0x0000,0x0000,0x0000, +0x6D24,0x0000,0x0000,0x0000,0x934D,0x6D2B,0x0000,0x0000, +0x0000,0x6D26,0x0000,0x0000,0x0000,0x0000,0x0000,0x4058, +0x6D28,0x0000,0x934E,0x6D2A,0x6D27,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x934F,0x9350,0x0000,0x9351, +0x7C47,0x0000,0x6D2D,0x0000,0x3D33,0x0000,0x6D2C,0x0000, +0x0000,0x0000,0x0000,0x7C48,0x6D2E,0x0000,0x0000,0x0000, +0x0000,0x6D2F,0x0000,0x0000,0x6D32,0x6D31,0x0000,0x6D30, +0x0000,0x0000,0x6D34,0x6D33,0x0000,0x4C76,0x0000,0x0000, +0x0000,0x6D36,0x0000,0x6D35,0x6D37,0x0000,0x0000,0x0000, +0x9352,0x6D38,0x0000,0x0000,0x0000,0x0000,0x9353,0x0000, +0x0000,0x6D3A,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6D39,0x3F48,0x6D3B,0x0000,0x9354,0x366D, +0x6D3C,0x6D3E,0x0000,0x9355,0x0000,0x9356,0x9357,0x0000, +0x0000,0x0000,0x0000,0x9358,0x0000,0x0000,0x6D3F,0x0000, +0x7C4A,0x0000,0x0000,0x0000,0x0000,0x6D40,0x6D3D,0x0000, +0x6D41,0x0000,0x3C56,0x6D42,0x3530,0x3733,0x0000,0x0000, +0x0000,0x935A,0x382E,0x0000,0x935B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6D43,0x0000,0x0000,0x0000,0x4670, +0x0000,0x0000,0x453E,0x6D44,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6D47,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x3C34,0x935D,0x7C4C,0x6D46,0x6D45,0x375A,0x6D48,0x0000, + +/* 8F00h */ +0x935F,0x0000,0x0000,0x3353,0x0000,0x6D4A,0x0000,0x0000, +0x9360,0x3A5C,0x6D49,0x0000,0x6D52,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6D4C,0x6D4E,0x4A65,0x6D4B,0x0000,0x9361, +0x0000,0x6D4D,0x0000,0x6D51,0x6D4F,0x3531,0x7C4D,0x6D50, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6D53,0x0000, +0x0000,0x475A,0x4E58,0x9362,0x0000,0x7C4E,0x0000,0x3D34, +0x0000,0x0000,0x0000,0x6D54,0x0000,0x0000,0x7C4F,0x0000, +0x4D22,0x6D56,0x0000,0x6D55,0x0000,0x0000,0x6D59,0x4D41, +0x9363,0x0000,0x6D58,0x0000,0x336D,0x6D57,0x6D5C,0x0000, +0x0000,0x6D5B,0x9364,0x0000,0x6D5A,0x4532,0x6D5D,0x0000, +0x0000,0x0000,0x0000,0x0000,0x7C50,0x0000,0x0000,0x6D5E, +0x9365,0x0000,0x0000,0x0000,0x6D5F,0x0000,0x0000,0x396C, +0x0000,0x3725,0x6D60,0x6D61,0x6D62,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3F49,0x6D63,0x0000,0x3C2D,0x6D64, +0x0000,0x0000,0x0000,0x6D65,0x9367,0x0000,0x7C52,0x5221, +0x517E,0x0000,0x0000,0x0000,0x0000,0x6D66,0x6570,0x6D67, +0x4324,0x3F2B,0x4740,0x0000,0x9368,0x7C53,0x936A,0x6D68, +0x0000,0x0000,0x4A55,0x4454,0x397E,0x0000,0x0000,0x4329, +0x0000,0x936C,0x312A,0x0000,0x4B78,0x3F57,0x936D,0x0000, +0x0000,0x0000,0x936F,0x0000,0x0000,0x9370,0x375E,0x0000, +0x0000,0x3661,0x0000,0x9371,0x4A56,0x9372,0x0000,0x0000, +0x0000,0x0000,0x6D69,0x0000,0x0000,0x0000,0x0000,0x0000, +0x9373,0x0000,0x6D6B,0x0000,0x7C54,0x6D6A,0x3260,0x0000, +0x7C55,0x4676,0x6D6C,0x4777,0x0000,0x4533,0x7C56,0x6D6D, +0x3D52,0x9374,0x0000,0x0000,0x6D6F,0x9375,0x0000,0x4C42, +0x6D7E,0x6D71,0x6D72,0x9376,0x0000,0x4449,0x0000,0x0000, + +/* 9000h */ +0x4260,0x4177,0x9377,0x4628,0x0000,0x6D70,0x3555,0x0000, +0x7C57,0x0000,0x0000,0x6D79,0x9378,0x6D76,0x6E25,0x4629, +0x4360,0x6D73,0x0000,0x447E,0x4553,0x6D74,0x6D78,0x3F60, +0x0000,0x4767,0x444C,0x0000,0x0000,0x4042,0x6D77,0x422E, +0x4224,0x6D75,0x3029,0x4F22,0x0000,0x0000,0x0000,0x6D7A, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7C58,0x4261,0x0000, +0x0000,0x3D35,0x3F4A,0x0000,0x0000,0x6D7C,0x6D7B,0x9379, +0x306F,0x6D7D,0x0000,0x0000,0x492F,0x0000,0x6E27,0x0000, +0x0000,0x465B,0x3F6B,0x937B,0x937C,0x4359,0x0000,0x3678, +0x0000,0x6E26,0x4D37,0x313F,0x0000,0x4A57,0x3261,0x6E21, +0x6E22,0x6E23,0x6E24,0x463B,0x4323,0x3063,0x6E28,0x0000, +0x6E29,0x7423,0x0000,0x0000,0x423D,0x937D,0x6E2A,0x0000, +0x3173,0x414C,0x0000,0x382F,0x0000,0x4D5A,0x0000,0x0000, +0x6E2B,0x452C,0x0000,0x0000,0x0000,0x4178,0x3C57,0x6E2C, +0x0000,0x0000,0x6E2F,0x0000,0x0000,0x3D65,0x6E2D,0x412B, +0x412A,0x0000,0x3064,0x0000,0x4E4B,0x6E31,0x0000,0x4872, +0x6E33,0x6E32,0x6E30,0x6364,0x3454,0x9422,0x0000,0x6D6E, +0x7C5A,0x6E35,0x6E34,0x0000,0x9423,0x0000,0x0000,0x6E36, +0x9424,0x4D38,0x0000,0x0000,0x0000,0x7C5B,0x0000,0x7C5C, +0x0000,0x7C5D,0x0000,0x7C5E,0x0000,0x0000,0x0000,0x0000, +0x0000,0x9426,0x7C5F,0x4661,0x0000,0x0000,0x4B2E,0x0000, +0x6E37,0x0000,0x3C59,0x0000,0x0000,0x0000,0x0000,0x6E38, +0x9428,0x6E39,0x0000,0x7C60,0x0000,0x6E3A,0x9429,0x0000, +0x4521,0x0000,0x0000,0x0000,0x0000,0x0000,0x7C61,0x0000, +0x0000,0x306A,0x0000,0x942A,0x7C62,0x7C63,0x0000,0x7C64, +0x942B,0x0000,0x3959,0x0000,0x0000,0x0000,0x4F3A,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7C65, +0x0000,0x0000,0x0000,0x6E3E,0x942D,0x7C66,0x7C67,0x942E, +0x0000,0x3734,0x6E3B,0x0000,0x6E3C,0x0000,0x0000,0x0000, +0x4974,0x0000,0x0000,0x9433,0x0000,0x3354,0x0000,0x7C68, +0x0000,0x0000,0x9431,0x0000,0x7C69,0x4D39,0x9430,0x363F, +0x0000,0x0000,0x0000,0x0000,0x0000,0x4554,0x9434,0x9435, + +/* 9100h */ +0x9432,0x0000,0x6E3F,0x0000,0x9436,0x0000,0x9437,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6E40,0x0000,0x7C6B,0x7C6C,0x7C6D,0x0000, +0x9438,0x6E41,0x0000,0x0000,0x9439,0x0000,0x943A,0x0000, +0x0000,0x0000,0x7C6E,0x7C6F,0x0000,0x0000,0x0000,0x7C70, +0x0000,0x0000,0x0000,0x0000,0x0000,0x4522,0x0000,0x7C71, +0x6E43,0x7C72,0x6E42,0x0000,0x7C73,0x0000,0x0000,0x943B, +0x0000,0x943C,0x943D,0x0000,0x0000,0x7C74,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x943E,0x943F, +0x7C75,0x4653,0x6E44,0x3D36,0x3C60,0x475B,0x4371,0x0000, +0x0000,0x0000,0x3C72,0x0000,0x3F6C,0x0000,0x6E45,0x9440, +0x6E46,0x9441,0x0000,0x7C76,0x0000,0x0000,0x0000,0x0000, +0x0000,0x9442,0x3F5D,0x6E47,0x9443,0x6E48,0x0000,0x0000, +0x0000,0x6E49,0x4D6F,0x0000,0x3D37,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6E4B,0x6E4A,0x9444,0x395A,0x0000,0x3973, +0x3B40,0x9445,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6E4E,0x7C77,0x0000,0x9446,0x0000,0x3D66, +0x0000,0x6E4D,0x0000,0x6E4C,0x0000,0x4269,0x9447,0x0000, +0x386F,0x0000,0x4043,0x0000,0x0000,0x0000,0x0000,0x4830, +0x0000,0x0000,0x0000,0x0000,0x3D39,0x0000,0x7C78,0x0000, +0x0000,0x0000,0x6E4F,0x0000,0x3E5F,0x0000,0x0000,0x0000, +0x9448,0x0000,0x6E52,0x6E50,0x7C79,0x0000,0x9449,0x6E51, +0x0000,0x7C7A,0x0000,0x944A,0x6E54,0x6E53,0x944B,0x0000, +0x3E7A,0x0000,0x6E55,0x0000,0x7C7B,0x0000,0x0000,0x0000, +0x6E56,0x6E57,0x0000,0x944C,0x944D,0x0000,0x4850,0x3A53, +0x3C61,0x6E58,0x0000,0x6E59,0x4E24,0x3D45,0x4C6E,0x4E4C, +0x6E5A,0x3662,0x0000,0x0000,0x0000,0x0000,0x6E5B,0x7C7C, +0x4523,0x0000,0x944E,0x6E5E,0x3378,0x3F4B,0x0000,0x6E5C, +0x0000,0x6E5D,0x0000,0x4460,0x7C7E,0x7D21,0x4B55,0x367C, +0x0000,0x0000,0x0000,0x0000,0x9451,0x7D22,0x9452,0x0000, +0x0000,0x7D23,0x0000,0x0000,0x0000,0x6E60,0x6E61,0x0000, +0x0000,0x0000,0x0000,0x7C7D,0x6E5F,0x0000,0x0000,0x6E63, + +/* 9200h */ +0x0000,0x9453,0x0000,0x0000,0x0000,0x0000,0x0000,0x7D24, +0x0000,0x0000,0x9454,0x0000,0x0000,0x465F,0x3343,0x0000, +0x7D25,0x6E67,0x0000,0x0000,0x6E64,0x6E66,0x9455,0x9456, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6E62,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6F4F,0x0000,0x0000,0x6E65,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x9458,0x4E6B,0x0000,0x0000,0x385A, +0x7D26,0x7D27,0x7D28,0x0000,0x7D29,0x0000,0x0000,0x6E6F, +0x7D2A,0x0000,0x9459,0x7D2B,0x4534,0x6E6A,0x0000,0x945A, +0x6E6D,0x6E6B,0x945B,0x6E70,0x0000,0x0000,0x945C,0x7D2C, +0x6E71,0x945D,0x0000,0x0000,0x0000,0x0000,0x945E,0x6E69, +0x0000,0x945F,0x6E76,0x3174,0x0000,0x0000,0x6E68,0x0000, +0x9460,0x9461,0x482D,0x0000,0x6E6C,0x9462,0x3E60,0x9463, +0x9464,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x395B,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7D2D,0x0000,0x0000,0x0000,0x9467,0x9468,0x4B48,0x9469, +0x3664,0x0000,0x0000,0x3D46,0x0000,0x463C,0x0000,0x0000, +0x7D2E,0x946A,0x0000,0x0000,0x0000,0x946B,0x0000,0x0000, +0x0000,0x412D,0x0000,0x6E74,0x0000,0x6E6E,0x6E73,0x946C, +0x4C43,0x946D,0x4438,0x6E75,0x6E72,0x0000,0x0000,0x946E, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x946F, +0x0000,0x0000,0x0000,0x9470,0x0000,0x412C,0x0000,0x0000, +0x0000,0x0000,0x9473,0x0000,0x0000,0x0000,0x0000,0x6E79, +0x0000,0x6E78,0x0000,0x0000,0x0000,0x0000,0x0000,0x9474, +0x9475,0x0000,0x7D2F,0x0000,0x0000,0x0000,0x9476,0x0000, +0x0000,0x0000,0x0000,0x7D30,0x7D31,0x0000,0x9477,0x6E77, +0x9478,0x0000,0x4B2F,0x7D32,0x0000,0x0000,0x0000,0x9479, +0x0000,0x947A,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7D33,0x0000,0x0000,0x0000,0x3D7B,0x947B,0x0000,0x947C, +0x0000,0x6E7A,0x4A5F,0x0000,0x0000,0x3154,0x0000,0x0000, +0x0000,0x0000,0x4946,0x4372,0x0000,0x0000,0x0000,0x9522, +0x3578,0x9523,0x6E7C,0x9524,0x395D,0x0000,0x0000,0x7D34, + +/* 9300h */ +0x0000,0x0000,0x9525,0x0000,0x7D35,0x0000,0x3B2C,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x9526,0x0000,0x6E7B, +0x3F6D,0x947D,0x0000,0x0000,0x0000,0x9527,0x0000,0x0000, +0x3F6E,0x6F21,0x6F23,0x0000,0x0000,0x9528,0x9529,0x7D36, +0x3E7B,0x7D37,0x6F22,0x6F24,0x0000,0x7D38,0x3653,0x952A, +0x4945,0x952B,0x0000,0x3C62,0x4F23,0x0000,0x6E7E,0x3A78, +0x0000,0x0000,0x4F3F,0x0000,0x0000,0x6F26,0x0000,0x0000, +0x0000,0x0000,0x6F25,0x6F27,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x6E7D,0x0000,0x0000,0x952E, +0x7D39,0x7D3A,0x7D3B,0x4669,0x0000,0x4555,0x0000,0x0000, +0x0000,0x952F,0x0000,0x0000,0x4457,0x0000,0x6F2C,0x9530, +0x0000,0x0000,0x9531,0x4343,0x6F28,0x0000,0x0000,0x0000, +0x6F29,0x0000,0x0000,0x0000,0x7D3C,0x7D3D,0x0000,0x0000, +0x0000,0x0000,0x7D3E,0x9532,0x372D,0x0000,0x6F2B,0x0000, +0x7D3F,0x9533,0x0000,0x9534,0x0000,0x3830,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x6F2A,0x0000,0x3E61,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x9538,0x0000,0x0000,0x9539,0x3379,0x0000,0x0000,0x953A, +0x0000,0x0000,0x0000,0x0000,0x6F30,0x0000,0x3A3F,0x4179, +0x0000,0x0000,0x444A,0x7D40,0x0000,0x0000,0x953B,0x0000, +0x0000,0x9535,0x0000,0x7D41,0x0000,0x0000,0x0000,0x333B, +0x0000,0x0000,0x0000,0x0000,0x6F2E,0x6F2F,0x4443,0x0000, +0x6F2D,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6F31,0x7D42,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x9540,0x0000,0x6F37,0x0000,0x0000,0x7D43,0x9541, +0x6F3A,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6F39,0x452D,0x0000,0x0000,0x0000,0x0000,0x6F32,0x6F33, +0x6F36,0x0000,0x0000,0x0000,0x9542,0x6F38,0x7D44,0x7D45, +0x0000,0x3640,0x9543,0x0000,0x6F3B,0x6F35,0x0000,0x9544, +0x6F34,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x953F,0x0000,0x0000,0x0000,0x953C,0x0000,0x0000, +0x0000,0x0000,0x0000,0x9549,0x0000,0x7D47,0x0000,0x0000, + +/* 9400h */ +0x0000,0x0000,0x0000,0x6F3F,0x7D46,0x0000,0x0000,0x6F40, +0x0000,0x9545,0x0000,0x0000,0x0000,0x0000,0x0000,0x9546, +0x6F41,0x0000,0x0000,0x6F3E,0x6F3D,0x0000,0x9547,0x9548, +0x3E62,0x462A,0x6F3C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6F45,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6F43,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x954A,0x7D48,0x954B,0x6F44,0x6F42,0x0000, +0x4278,0x0000,0x6F46,0x954C,0x0000,0x0000,0x0000,0x0000, +0x0000,0x6F47,0x0000,0x0000,0x6F49,0x954D,0x0000,0x0000, +0x0000,0x0000,0x7D49,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x3455,0x6F48,0x4C7A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6F54,0x6F4A,0x0000,0x0000,0x6F4D,0x0000, +0x6F4B,0x0000,0x6F4C,0x7D4A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x6F4E,0x7D4B,0x0000,0x9550,0x0000,0x9551, +0x6F50,0x7D4C,0x7D4D,0x0000,0x0000,0x6F51,0x0000,0x6F52, +0x0000,0x0000,0x0000,0x0000,0x6F55,0x6F53,0x6F56,0x6F58, +0x0000,0x6F57,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 9500h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4439, +0x9552,0x9553,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4C67,0x0000,0x6F59,0x412E,0x0000,0x0000,0x9554,0x6F5A, +0x0000,0x4A44,0x6F5B,0x332B,0x9555,0x9556,0x7D4E,0x313C, +0x0000,0x3457,0x0000,0x3456,0x6F5C,0x0000,0x6F5D,0x0000, +0x6F5E,0x6F5F,0x0000,0x0000,0x0000,0x0000,0x0000,0x7D4F, +0x6F60,0x0000,0x3458,0x3355,0x395E,0x4836,0x7D50,0x6F62, +0x6F61,0x7D51,0x0000,0x9558,0x7D52,0x6F63,0x0000,0x0000, +0x0000,0x0000,0x315C,0x0000,0x9559,0x0000,0x7D53,0x0000, +0x0000,0x6F66,0x0000,0x6F65,0x6F64,0x7D54,0x6F67,0x0000, +0x0000,0x0000,0x0000,0x6F6A,0x0000,0x0000,0x0000,0x3047, +0x955B,0x0000,0x6F68,0x7D55,0x6F6C,0x6F6B,0x0000,0x0000, +0x7D56,0x0000,0x0000,0x7D57,0x6F6E,0x6F6D,0x6F6F,0x0000, +0x462E,0x0000,0x7D59,0x0000,0x6F70,0x0000,0x7D5A,0x0000, +0x0000,0x6F71,0x6F73,0x0000,0x0000,0x6F72,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 9600h */ +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x496C,0x9425,0x0000,0x0000, +0x0000,0x6F74,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x6F75,0x0000,0x3A65,0x0000,0x955E,0x0000,0x6F76,0x6F77, +0x0000,0x0000,0x4B49,0x955F,0x9560,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x414B,0x9562,0x0000,0x0000,0x3024, +0x424B,0x9563,0x6F78,0x0000,0x496D,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6F7B,0x6F79,0x395F,0x0000,0x6F7A, +0x3842,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7D5B,0x0000,0x0000,0x4A45,0x6F7D,0x7021,0x6F7E,0x7022, +0x0000,0x9564,0x3121,0x3F58,0x3D7C,0x3459,0x7023,0x0000, +0x0000,0x0000,0x4766,0x0000,0x7025,0x0000,0x0000,0x0000, +0x3122,0x0000,0x7024,0x4444,0x0000,0x4E4D,0x462B,0x6F7C, +0x4E26,0x0000,0x3831,0x0000,0x0000,0x4D5B,0x0000,0x0000, +0x0000,0x0000,0x9566,0x0000,0x7D5C,0x3679,0x4E34,0x0000, +0x3728,0x0000,0x4262,0x6721,0x0000,0x7026,0x332C,0x3F6F, +0x0000,0x0000,0x0000,0x0000,0x3356,0x7028,0x0000,0x7029, +0x7027,0x3764,0x9568,0x3A5D,0x3E63,0x7D5E,0x0000,0x0000, +0x3123,0x0000,0x0000,0x4E59,0x7D5F,0x7D60,0x0000,0x702B, +0x6E2E,0x956B,0x702A,0x0000,0x0000,0x0000,0x0000,0x956C, +0x702E,0x702C,0x702D,0x956D,0x702F,0x0000,0x7030,0x4E6C, +0x7031,0x7032,0x956E,0x4049,0x483B,0x956F,0x0000,0x0000, +0x3F7D,0x3467,0x0000,0x0000,0x4D3A,0x326D,0x3D38,0x385B, +0x0000,0x7035,0x0000,0x7034,0x3B73,0x7036,0x7033,0x0000, +0x0000,0x3B28,0x7D61,0x0000,0x0000,0x703A,0x6A2D,0x0000, +0x9572,0x5256,0x9573,0x3F77,0x7038,0x9574,0x7D62,0x0000, +0x0000,0x0000,0x4E25,0x4671,0x0000,0x0000,0x0000,0x0000, +0x312B,0x7D64,0x4063,0x3C36,0x0000,0x0000,0x0000,0x7D65, +0x4A37,0x0000,0x3140,0x0000,0x0000,0x0000,0x4E6D,0x4D6B, +0x0000,0x703B,0x0000,0x4545,0x0000,0x0000,0x0000,0x0000, + +/* 9700h */ +0x3C7B,0x0000,0x0000,0x0000,0x703C,0x0000,0x703D,0x3F4C, +0x703E,0x0000,0x4E6E,0x0000,0x0000,0x7039,0x7040,0x7042, +0x0000,0x7041,0x0000,0x703F,0x9576,0x0000,0x7043,0x0000, +0x0000,0x7044,0x0000,0x0000,0x417A,0x0000,0x3262,0x0000, +0x0000,0x0000,0x0000,0x9577,0x7045,0x0000,0x0000,0x4C38, +0x0000,0x0000,0x7046,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7047,0x0000,0x4F2A,0x7D66,0x0000,0x0000,0x9579,0x0000, +0x5B31,0x7048,0x0000,0x7D67,0x0000,0x7049,0x704A,0x0000, +0x0000,0x957A,0x704E,0x0000,0x704B,0x0000,0x704C,0x957B, +0x704D,0x704F,0x0000,0x0000,0x0000,0x7D68,0x7D69,0x7D6A, +0x0000,0x0000,0x4044,0x0000,0x0000,0x957C,0x4C77,0x957D, +0x0000,0x4045,0x7D6B,0x957E,0x7050,0x0000,0x4873,0x0000, +0x7051,0x7353,0x4C4C,0x0000,0x7052,0x0000,0x7053,0x0000, +0x7054,0x3357,0x9621,0x7056,0x0000,0x3F59,0x7D6C,0x0000, +0x0000,0x7057,0x0000,0x7D6D,0x3724,0x0000,0x0000,0x0000, +0x0000,0x7058,0x705C,0x0000,0x705A,0x0000,0x0000,0x0000, +0x0000,0x705B,0x0000,0x0000,0x3373,0x7059,0x705D,0x0000, +0x0000,0x0000,0x0000,0x705E,0x0000,0x3048,0x0000,0x705F, +0x7060,0x0000,0x0000,0x0000,0x0000,0x7D6E,0x9624,0x0000, +0x3E64,0x0000,0x9625,0x0000,0x7061,0x0000,0x9626,0x0000, +0x3547,0x0000,0x9627,0x7064,0x0000,0x0000,0x7063,0x0000, +0x7062,0x0000,0x0000,0x6B71,0x0000,0x4A5C,0x7D6F,0x0000, +0x0000,0x9628,0x9629,0x7065,0x7066,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7D70,0x0000,0x0000,0x0000,0x962A,0x0000, +0x0000,0x7D71,0x0000,0x7067,0x0000,0x0000,0x7068,0x0000, +0x7069,0x7D72,0x0000,0x706A,0x962B,0x0000,0x0000,0x0000, +0x0000,0x962C,0x0000,0x345A,0x962D,0x0000,0x0000,0x0000, +0x962E,0x962F,0x0000,0x7D74,0x706B,0x0000,0x7D73,0x0000, +0x0000,0x9630,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x706C,0x4723,0x0000, +0x0000,0x9631,0x706E,0x323B,0x7D75,0x7071,0x7070,0x0000, +0x0000,0x0000,0x0000,0x3124,0x0000,0x0000,0x0000,0x3641, + +/* 9800h */ +0x0000,0x4A47,0x443A,0x3A22,0x9632,0x3960,0x3D67,0x0000, +0x3F5C,0x0000,0x7D77,0x0000,0x7073,0x9633,0x9634,0x7072, +0x4D42,0x3468,0x4852,0x465C,0x9635,0x0000,0x9636,0x3F7C, +0x4E4E,0x0000,0x375B,0x0000,0x0000,0x0000,0x7D78,0x0000, +0x0000,0x7076,0x0000,0x9639,0x7075,0x963C,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7D79,0x4B4B,0x462C,0x0000,0x0000, +0x7D7A,0x0000,0x963A,0x963B,0x3150,0x0000,0x0000,0x7077, +0x7074,0x0000,0x0000,0x4951,0x4D6A,0x7078,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7079,0x963D, +0x0000,0x0000,0x0000,0x707B,0x426A,0x335B,0x335C,0x707A, +0x0000,0x0000,0x7D7C,0x7D7D,0x3469,0x3832,0x7D7E,0x7E21, +0x346A,0x7E22,0x7E23,0x453F,0x0000,0x0000,0x4E60,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7E25,0x963E,0x385C, +0x0000,0x0000,0x0000,0x707C,0x7E26,0x0000,0x0000,0x707D, +0x707E,0x7121,0x0000,0x7123,0x7122,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4977,0x0000,0x7124,0x963F,0x0000,0x9640,0x0000,0x7125, +0x9641,0x7126,0x0000,0x0000,0x0000,0x0000,0x7127,0x9643, +0x9644,0x0000,0x7E27,0x9645,0x9646,0x0000,0x0000,0x9647, +0x0000,0x0000,0x9648,0x7129,0x7128,0x0000,0x712A,0x9649, +0x7E28,0x0000,0x0000,0x964A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x4874,0x664C,0x0000,0x0000,0x3F29, +0x964B,0x964D,0x3532,0x964E,0x0000,0x964F,0x0000,0x7E29, +0x0000,0x712B,0x9650,0x712C,0x0000,0x522C,0x5D3B,0x4853, +0x9651,0x9652,0x307B,0x9653,0x303B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x3B74,0x4B30,0x3E7E,0x0000, + +/* 9900h */ +0x0000,0x0000,0x0000,0x712D,0x0000,0x4C5F,0x0000,0x0000, +0x9654,0x712E,0x4D5C,0x0000,0x3142,0x0000,0x0000,0x0000, +0x3B41,0x0000,0x712F,0x326E,0x7130,0x0000,0x9657,0x9658, +0x7131,0x0000,0x965A,0x965B,0x965C,0x7133,0x7134,0x0000, +0x7136,0x7132,0x0000,0x0000,0x7135,0x0000,0x0000,0x0000, +0x345B,0x0000,0x0000,0x0000,0x7137,0x0000,0x7138,0x0000, +0x0000,0x965E,0x965F,0x9660,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x9661,0x9662,0x9663,0x7139,0x713A,0x0000, +0x9664,0x9665,0x713B,0x0000,0x0000,0x713D,0x9666,0x0000, +0x0000,0x713C,0x0000,0x713F,0x7142,0x9667,0x9668,0x0000, +0x713E,0x7140,0x7141,0x0000,0x0000,0x7143,0x0000,0x3642, +0x7E2A,0x0000,0x0000,0x0000,0x9669,0x0000,0x0000,0x966A, +0x966B,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x3C73,0x7144, +0x7145,0x3961,0x0000,0x0000,0x0000,0x0000,0x7E2B,0x0000, +0x0000,0x0000,0x0000,0x966C,0x0000,0x7146,0x966D,0x0000, +0x333E,0x0000,0x0000,0x0000,0x474F,0x7147,0x7148,0x0000, +0x0000,0x0000,0x0000,0x435A,0x466B,0x0000,0x0000,0x0000, +0x0000,0x966E,0x0000,0x0000,0x7149,0x966F,0x0000,0x9670, +0x0000,0x477D,0x0000,0x9671,0x424C,0x3158,0x366E,0x0000, +0x366F,0x9672,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x4373,0x714E,0x3670,0x0000,0x9673,0x326F,0x0000,0x0000, +0x714D,0x9674,0x0000,0x714B,0x0000,0x714C,0x9675,0x714A, +0x0000,0x0000,0x7158,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x714F,0x7150,0x0000, +0x9677,0x7151,0x7152,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7154,0x9678,0x0000,0x7153,0x9679,0x0000,0x0000,0x3D59, + +/* 9A00h */ +0x0000,0x7155,0x7E2C,0x7E2D,0x0000,0x7157,0x0000,0x0000, +0x0000,0x0000,0x967A,0x0000,0x0000,0x0000,0x3533,0x7156, +0x0000,0x967B,0x417B,0x3833,0x0000,0x0000,0x967C,0x0000, +0x0000,0x7159,0x967D,0x0000,0x0000,0x0000,0x0000,0x0000, +0x967E,0x0000,0x0000,0x0000,0x7E2E,0x0000,0x0000,0x0000, +0x424D,0x0000,0x0000,0x715A,0x0000,0x7E2F,0x7E30,0x0000, +0x462D,0x9721,0x0000,0x0000,0x0000,0x0000,0x9722,0x715B, +0x7E31,0x0000,0x0000,0x0000,0x0000,0x0000,0x7160,0x0000, +0x715E,0x0000,0x715D,0x715F,0x9723,0x715C,0x0000,0x0000, +0x0000,0x0000,0x7E32,0x0000,0x9724,0x7162,0x7E33,0x0000, +0x0000,0x0000,0x7E34,0x0000,0x0000,0x7161,0x0000,0x7164, +0x9725,0x0000,0x3643,0x7163,0x0000,0x0000,0x0000,0x7165, +0x0000,0x0000,0x7166,0x0000,0x7168,0x7167,0x0000,0x0000, +0x0000,0x7169,0x716B,0x716A,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x397C,0x0000,0x0000,0x0000,0x0000,0x716C,0x0000,0x9727, +0x716D,0x0000,0x0000,0x0000,0x0000,0x0000,0x7E35,0x9729, +0x333C,0x972B,0x0000,0x0000,0x716E,0x0000,0x0000,0x0000, +0x716F,0x7E36,0x0000,0x7E37,0x3F71,0x0000,0x972D,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7E38,0x7170, +0x972E,0x7171,0x972F,0x7172,0x7173,0x9730,0x7E39,0x0000, +0x3962,0x0000,0x0000,0x0000,0x9732,0x0000,0x7174,0x7175, +0x9733,0x0000,0x7176,0x7177,0x0000,0x9734,0x7178,0x0000, +0x0000,0x9735,0x4831,0x717A,0x0000,0x4926,0x717B,0x7179, +0x0000,0x717D,0x0000,0x0000,0x717C,0x0000,0x0000,0x717E, +0x0000,0x7E3A,0x0000,0x7221,0x0000,0x0000,0x0000,0x0000, + +/* 9B00h */ +0x0000,0x0000,0x7E3B,0x9736,0x0000,0x0000,0x7222,0x0000, +0x7E3C,0x0000,0x0000,0x0000,0x9737,0x0000,0x0000,0x0000, +0x9738,0x0000,0x9739,0x0000,0x0000,0x0000,0x973A,0x0000, +0x7223,0x0000,0x7224,0x0000,0x973B,0x0000,0x0000,0x7225, +0x7E3D,0x0000,0x7226,0x7227,0x0000,0x7228,0x0000,0x7229, +0x722A,0x722B,0x722C,0x973C,0x0000,0x7E3F,0x722D,0x722E, +0x0000,0x5D35,0x722F,0x973D,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x6478,0x3534,0x973E,0x0000,0x0000, +0x0000,0x3321,0x3A32,0x7231,0x7230,0x4C25,0x0000,0x0000, +0x0000,0x0000,0x0000,0x9740,0x0000,0x7233,0x7234,0x7232, +0x0000,0x7235,0x0000,0x0000,0x4B62,0x0000,0x0000,0x0000, +0x7236,0x0000,0x357B,0x0000,0x0000,0x0000,0x7E40,0x0000, +0x0000,0x0000,0x0000,0x9741,0x0000,0x9742,0x7E42,0x0000, +0x0000,0x0000,0x0000,0x9743,0x9744,0x0000,0x0000,0x4F25, +0x0000,0x0000,0x7E43,0x9745,0x7237,0x7E44,0x9746,0x9747, +0x0000,0x7E41,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x7239,0x7E45,0x0000,0x0000,0x0000, +0x0000,0x0000,0x7E46,0x0000,0x0000,0x0000,0x303E,0x7E47, +0x0000,0x723A,0x4A2B,0x7238,0x0000,0x0000,0x723B,0x723C, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7E48,0x723D, +0x723E,0x0000,0x0000,0x0000,0x0000,0x0000,0x9748,0x7E49, +0x723F,0x0000,0x4B6E,0x3B2D,0x9749,0x3A7A,0x412F,0x0000, +0x0000,0x974A,0x974D,0x0000,0x7240,0x0000,0x0000,0x0000, +0x974E,0x7243,0x0000,0x0000,0x0000,0x0000,0x974F,0x0000, +0x7241,0x7E4A,0x0000,0x0000,0x0000,0x0000,0x7244,0x9750, +0x0000,0x3871,0x7242,0x0000,0x0000,0x0000,0x7E4B,0x7245, +0x0000,0x7246,0x7247,0x0000,0x724B,0x0000,0x3B2A,0x0000, +0x9752,0x0000,0x0000,0x4264,0x0000,0x9753,0x0000,0x0000, +0x0000,0x724C,0x7249,0x7248,0x724A,0x7E4C,0x0000,0x9754, +0x375F,0x0000,0x9755,0x9756,0x0000,0x0000,0x9758,0x9757, +0x7250,0x724F,0x724E,0x9751,0x0000,0x3033,0x0000,0x975C, +0x7E4D,0x0000,0x975A,0x0000,0x0000,0x7E4E,0x0000,0x0000, + +/* 9C00h */ +0x7E4F,0x0000,0x0000,0x0000,0x725A,0x0000,0x7256,0x0000, +0x7257,0x7253,0x7259,0x0000,0x7255,0x3362,0x0000,0x0000, +0x4F4C,0x0000,0x7258,0x7254,0x7252,0x7251,0x975E,0x0000, +0x975F,0x9760,0x9761,0x725C,0x0000,0x9762,0x0000,0x0000, +0x0000,0x725F,0x9763,0x7E50,0x725E,0x725D,0x0000,0x9764, +0x0000,0x9765,0x9766,0x0000,0x0000,0x4949,0x725B,0x3073, +0x7260,0x9768,0x7262,0x0000,0x0000,0x0000,0x9769,0x976A, +0x0000,0x336F,0x724D,0x3137,0x0000,0x0000,0x7264,0x0000, +0x0000,0x7E51,0x0000,0x0000,0x0000,0x976B,0x7263,0x7261, +0x432D,0x976E,0x976F,0x0000,0x0000,0x0000,0x0000,0x7E52, +0x7E53,0x0000,0x4B70,0x7E54,0x9771,0x0000,0x0000,0x4E5A, +0x9772,0x0000,0x7265,0x9773,0x976C,0x9774,0x0000,0x9775, +0x7266,0x0000,0x0000,0x7E55,0x0000,0x7E56,0x0000,0x7267, +0x0000,0x9776,0x9777,0x9778,0x0000,0x9779,0x977A,0x0000, +0x977B,0x0000,0x977C,0x0000,0x0000,0x977D,0x7268,0x7E57, +0x7269,0x0000,0x977E,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x443B,0x9821,0x726A, +0x0000,0x4837,0x0000,0x726F,0x726B,0x0000,0x0000,0x0000, +0x726C,0x0000,0x9822,0x4B31,0x4C44,0x0000,0x4650,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + +/* 9D00h */ +0x0000,0x0000,0x9824,0x7270,0x0000,0x0000,0x7271,0x463E, +0x726E,0x726D,0x0000,0x9823,0x0000,0x0000,0x322A,0x0000, +0x0000,0x9826,0x7279,0x0000,0x0000,0x7278,0x0000,0x9827, +0x9828,0x0000,0x0000,0x3175,0x0000,0x7E58,0x7E59,0x7276, +0x0000,0x0000,0x0000,0x7275,0x0000,0x0000,0x7273,0x0000, +0x337B,0x0000,0x7272,0x3C32,0x3229,0x0000,0x0000,0x0000, +0x0000,0x0000,0x982C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x3963,0x0000,0x0000,0x727C,0x727B, +0x0000,0x727A,0x982E,0x7E5A,0x7277,0x0000,0x727D,0x7E5B, +0x727E,0x0000,0x982F,0x0000,0x0000,0x0000,0x0000,0x0000, +0x7325,0x7324,0x7E5C,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x7326,0x0000,0x0000,0x312D,0x7321,0x7322,0x9830, +0x3974,0x4C39,0x9831,0x7E5D,0x7323,0x0000,0x0000,0x0000, +0x0000,0x9833,0x0000,0x9834,0x4B32,0x0000,0x0000,0x732B, +0x7E5E,0x0000,0x7327,0x9836,0x0000,0x0000,0x9837,0x9838, +0x0000,0x0000,0x732C,0x0000,0x7E5F,0x0000,0x9839,0x0000, +0x0000,0x0000,0x0000,0x0000,0x983A,0x0000,0x0000,0x7329, +0x0000,0x7328,0x7E60,0x0000,0x0000,0x983B,0x0000,0x375C, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x7E61,0x0000, +0x0000,0x983C,0x732D,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x983D,0x0000,0x0000,0x732E,0x0000,0x0000,0x0000, +0x0000,0x732F,0x0000,0x732A,0x7E63,0x0000,0x0000,0x7274, +0x0000,0x0000,0x7330,0x0000,0x4461,0x983F,0x0000,0x0000, +0x7334,0x9840,0x7335,0x7333,0x7E64,0x9841,0x0000,0x983E, +0x7E62,0x7332,0x7338,0x9842,0x7331,0x0000,0x7336,0x9843, +0x0000,0x9844,0x0000,0x0000,0x0000,0x0000,0x0000,0x7337, +0x0000,0x0000,0x0000,0x733A,0x0000,0x0000,0x9845,0x7E65, +0x0000,0x7339,0x9846,0x0000,0x0000,0x0000,0x0000,0x9847, +0x9848,0x0000,0x0000,0x9849,0x0000,0x0000,0x733C,0x7E67, +0x0000,0x0000,0x0000,0x0000,0x0000,0x733D,0x0000,0x733E, +0x0000,0x0000,0x4F49,0x0000,0x984A,0x0000,0x0000,0x0000, +0x733B,0x426B,0x3A6D,0x0000,0x0000,0x733F,0x0000,0x0000, + +/* 9E00h */ +0x0000,0x0000,0x984D,0x0000,0x0000,0x0000,0x0000,0x7E68, +0x0000,0x0000,0x984C,0x0000,0x0000,0x984E,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7E69,0x0000,0x0000, +0x0000,0x984F,0x7340,0x7341,0x9850,0x9851,0x7342,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x7343,0x0000,0x0000, +0x3834,0x7344,0x0000,0x9852,0x7E6A,0x7345,0x0000,0x3C2F, +0x9854,0x7346,0x0000,0x0000,0x0000,0x9855,0x0000,0x0000, +0x7347,0x0000,0x0000,0x7348,0x7349,0x0000,0x0000,0x0000, +0x0000,0x734C,0x734A,0x4F3C,0x0000,0x734B,0x0000,0x4E6F, +0x0000,0x0000,0x0000,0x9856,0x0000,0x734D,0x7E6B,0x4E5B, +0x0000,0x0000,0x0000,0x0000,0x7E6C,0x734E,0x477E,0x0000, +0x9857,0x734F,0x7351,0x0000,0x7E6D,0x7352,0x0000,0x7E6E, +0x0000,0x0000,0x0000,0x0000,0x7E6F,0x7E70,0x0000,0x0000, +0x7350,0x396D,0x4C4D,0x4B63,0x5677,0x9859,0x5D60,0x4B7B, +0x0000,0x0000,0x0000,0x7E71,0x322B,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x7354,0x3550,0x7355,0x7356, +0x7357,0x7E72,0x3975,0x0000,0x7358,0x0000,0x0000,0x0000, +0x6054,0x4C5B,0x0000,0x4263,0x7359,0x735B,0x735A,0x985B, +0x735C,0x0000,0x0000,0x0000,0x0000,0x735D,0x0000,0x985C, +0x735E,0x0000,0x0000,0x0000,0x0000,0x0000,0x985D,0x735F, +0x0000,0x0000,0x0000,0x0000,0x7360,0x0000,0x7361,0x7362, +0x0000,0x7363,0x0000,0x7364,0x7365,0x7366,0x0000,0x985E, + +/* 9F00h */ +0x0000,0x0000,0x985F,0x9861,0x0000,0x0000,0x0000,0x7367, +0x7368,0x0000,0x0000,0x0000,0x0000,0x0000,0x4524,0x0000, +0x7E73,0x0000,0x0000,0x385D,0x0000,0x736A,0x0000,0x9862, +0x0000,0x9863,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x414D,0x736B,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x736C,0x0000,0x0000,0x9864, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x9865, +0x0000,0x7E74,0x9866,0x4921,0x0000,0x9867,0x736D,0x0000, +0x0000,0x9868,0x0000,0x0000,0x0000,0x9869,0x986A,0x0000, +0x0000,0x0000,0x736E,0x6337,0x0000,0x0000,0x6C5A,0x706D, +0x0000,0x0000,0x736F,0x986B,0x7370,0x986C,0x0000,0x7E75, +0x986D,0x0000,0x0000,0x0000,0x0000,0x986F,0x0000,0x7372, +0x7373,0x7374,0x4E70,0x7371,0x0000,0x0000,0x7375,0x7376, +0x0000,0x9871,0x7378,0x0000,0x7377,0x9873,0x0000,0x0000, +0x9874,0x0000,0x737A,0x0000,0x0000,0x9875,0x737B,0x7379, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x4E36,0x0000,0x0000, +0x7E76,0x0000,0x0000,0x0000,0x7E77,0x737C,0x0000,0x7E78, +0x0000,0x0000,0x0000,0x0000,0x737D,0x6354,0x0000,0x0000, +0x737E,0x0000,0x7E79,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +}; + +const int ucs_i_jisx0213_table_min = 0x4E00; +const int ucs_i_jisx0213_table_max = 0x4E00 + (sizeof(ucs_i_jisx0213_table)/ + sizeof(unsigned short)); + +const unsigned short ucs_r_jisx0213_table[] = { // 0xff00 - 0xffe5 + +/* FF00h */ +0x0000,0x212A,0x2230,0x2174,0x2170,0x2173,0x2175,0x222F, +0x214A,0x214B,0x2176,0x215C,0x2124,0x2231,0x2125,0x213F, +0x2330,0x2331,0x2332,0x2333,0x2334,0x2335,0x2336,0x2337, +0x2338,0x2339,0x2127,0x2128,0x2163,0x2161,0x2164,0x2129, +0x2177,0x2341,0x2342,0x2343,0x2344,0x2345,0x2346,0x2347, +0x2348,0x2349,0x234A,0x234B,0x234C,0x234D,0x234E,0x234F, +0x2350,0x2351,0x2352,0x2353,0x2354,0x2355,0x2356,0x2357, +0x2358,0x2359,0x235A,0x214E,0x2140,0x214F,0x2130,0x2132, +0x212E,0x2361,0x2362,0x2363,0x2364,0x2365,0x2366,0x2367, +0x2368,0x2369,0x236A,0x236B,0x236C,0x236D,0x236E,0x236F, +0x2370,0x2371,0x2372,0x2373,0x2374,0x2375,0x2376,0x2377, +0x2378,0x2379,0x237A,0x2150,0x2143,0x2151,0x2232,0x2256, +0x2257,0x00A1,0x00A2,0x00A3,0x00A4,0x00A5,0x00A6,0x00A7, +0x00A8,0x00A9,0x00AA,0x00AB,0x00AC,0x00AD,0x00AE,0x00AF, +0x00B0,0x00B1,0x00B2,0x00B3,0x00B4,0x00B5,0x00B6,0x00B7, +0x00B8,0x00B9,0x00BA,0x00BB,0x00BC,0x00BD,0x00BE,0x00BF, +0x00C0,0x00C1,0x00C2,0x00C3,0x00C4,0x00C5,0x00C6,0x00C7, +0x00C8,0x00C9,0x00CA,0x00CB,0x00CC,0x00CD,0x00CE,0x00CF, +0x00D0,0x00D1,0x00D2,0x00D3,0x00D4,0x00D5,0x00D6,0x00D7, +0x00D8,0x00D9,0x00DA,0x00DB,0x00DC,0x00DD,0x00DE,0x00DF, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2131,0x0000,0x216F,}; + +const int ucs_r_jisx0213_table_min = 0xFF00; +const int ucs_r_jisx0213_table_max = 0xFF00 + (sizeof(ucs_r_jisx0213_table)/ + sizeof(unsigned short)); + +const unsigned short ucs_r2_jisx0213_table[] = { // 0xfa0f - 0xfa6a +0x2F4B, +0x2F57,0x4F72,0x0000,0x8679,0x757A,0x775A,0x776F,0x0000, +0x0000,0x793C,0x793D,0x7941,0x0000,0x0000,0x0000,0x7B3A, +0x9138,0x9145,0x7C2E,0x0000,0x936E,0x0000,0x7C6A,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x2E38,0x2E49,0x2E50,0x2E63,0x2E68,0x2E6E,0x2F2C,0x2F2F, +0x2F36,0x2F5A,0x2F5E,0x4F61,0x4F62,0x7450,0x745C,0x745E, +0x7461,0x7528,0x752B,0x7543,0x7565,0x7669,0x7677,0x7725, +0x7755,0x8A29,0x7825,0x7927,0x7933,0x7934,0x7937,0x7938, +0x7939,0x793B,0x793F,0x7940,0x794D,0x7951,0x7964,0x7A2E, +0x8E50,0x7A33,0x7A3A,0x7A44,0x7A58,0x8F74,0x8F75,0x7B27, +0x7B6F,0x7B79,0x7C2F,0x7C30,0x7C38,0x7C3D,0x9369,0x7C59, +0x7D63,0x7D76,0x7D7B,}; + +const int ucs_r2_jisx0213_min = 0xFA0F; +const int ucs_r2_jisx0213_max = 0xFA6A; + +const unsigned short ucs_c1_jisx0213_tbl[] = { + // 0x1e00 - 0x4dff +0x1E3E,0x1E3F,0x1F70,0x1F71,0x1F72,0x1F73,0x2010,0x2010, +0x2013,0x2013,0x2014,0x2014,0x2016,0x2016,0x2018,0x2019, +0x201C,0x201D,0x2020,0x2021,0x2022,0x2022,0x2025,0x2025, +0x2026,0x2026,0x2030,0x2030,0x2032,0x2033,0x203B,0x203B, +0x203C,0x203C,0x203E,0x203E,0x203F,0x203F,0x2042,0x2042, +0x2047,0x2049,0x2051,0x2051,0x20AC,0x20AC,0x2103,0x2103, +0x210F,0x210F,0x2113,0x2113,0x2116,0x2116,0x2121,0x2121, +0x2127,0x2127,0x212B,0x212B,0x2135,0x2135,0x2153,0x2155, +0x2160,0x216A,0x216B,0x216B,0x2170,0x217B,0x2190,0x2191, +0x2192,0x2192,0x2193,0x2193,0x2194,0x2194,0x2196,0x2196, +0x2197,0x2198,0x2199,0x2199,0x21C4,0x21C4,0x21D2,0x21D2, +0x21D4,0x21D4,0x21E6,0x21E7,0x21E8,0x21E8,0x21E9,0x21E9, +0x2200,0x2200,0x2202,0x2202,0x2203,0x2203,0x2205,0x2205, +0x2207,0x2207,0x2208,0x2208,0x2209,0x2209,0x220B,0x220B, +0x2212,0x2212,0x2213,0x2213,0x221A,0x221A,0x221D,0x221D, +0x221E,0x221E,0x221F,0x221F,0x2220,0x2220,0x2225,0x2226, +0x2227,0x2228,0x2229,0x2229,0x222A,0x222A,0x222B,0x222C, +0x222E,0x222E,0x2234,0x2234,0x2235,0x2235,0x223D,0x223D, +0x2243,0x2243,0x2245,0x2245,0x2248,0x2248,0x2252,0x2252, +0x2260,0x2260,0x2261,0x2261,0x2262,0x2262,0x2266,0x2267, +0x226A,0x226B,0x2276,0x2277,0x2282,0x2283,0x2284,0x2285, +0x2286,0x2287,0x228A,0x228B,0x2295,0x2297,0x22A5,0x22A5, +0x22BF,0x22BF,0x22DA,0x22DB,0x2305,0x2306,0x2312,0x2312, +0x2318,0x2318,0x23BE,0x23CC,0x23CE,0x23CE,0x2423,0x2423, +0x2460,0x2473,0x24D0,0x24E9,0x24EB,0x24F4,0x24F5,0x24FE, +0x2500,0x2500,0x2501,0x2501,0x2502,0x2502,0x2503,0x2503, +0x250C,0x250C,0x250F,0x250F,0x2510,0x2510,0x2513,0x2513, +0x2514,0x2514,0x2517,0x2517,0x2518,0x2518,0x251B,0x251B, +0x251C,0x251C,0x251D,0x251D,0x2520,0x2520,0x2523,0x2523, +0x2524,0x2524,0x2525,0x2525,0x2528,0x2528,0x252B,0x252B, +0x252C,0x252C,0x252F,0x252F,0x2530,0x2530,0x2533,0x2533, +0x2534,0x2534,0x2537,0x2537,0x2538,0x2538,0x253B,0x253B, +0x253C,0x253C,0x253F,0x253F,0x2542,0x2542,0x254B,0x254B, +0x25A0,0x25A0,0x25A1,0x25A1,0x25B1,0x25B1,0x25B2,0x25B2, +0x25B3,0x25B3,0x25B6,0x25B6,0x25B7,0x25B7,0x25BC,0x25BC, +0x25BD,0x25BD,0x25C0,0x25C0,0x25C1,0x25C1,0x25C6,0x25C6, +0x25C7,0x25C7,0x25C9,0x25C9,0x25CB,0x25CB,0x25CE,0x25CE, +0x25CF,0x25CF,0x25D0,0x25D3,0x25E6,0x25E6,0x25EF,0x25EF, +0x2600,0x2603,0x2605,0x2605,0x2606,0x2606,0x260E,0x260E, +0x2616,0x2617,0x261E,0x261E,0x2640,0x2640,0x2642,0x2642, +0x2660,0x2660,0x2661,0x2661,0x2662,0x2662,0x2663,0x2663, +0x2664,0x2664,0x2665,0x2665,0x2666,0x2666,0x2667,0x2667, +0x2668,0x2668,0x2669,0x2669,0x266A,0x266A,0x266B,0x266C, +0x266D,0x266D,0x266E,0x266E,0x266F,0x266F,0x2713,0x2713, +0x2756,0x2756,0x2776,0x277F,0x2934,0x2935,0x29BF,0x29BF, +0x29FA,0x29FB,0x3000,0x3002,0x3003,0x3003,0x3005,0x3007, +0x3008,0x3011,0x3012,0x3012,0x3013,0x3013,0x3014,0x3015, +0x3016,0x3017,0x3018,0x3019,0x301C,0x301C,0x301D,0x301D, +0x301F,0x301F,0x3020,0x3020,0x3033,0x3035,0x303B,0x303C, +0x303D,0x303D,0x3041,0x3096,0x309B,0x309C,0x309D,0x309E, +0x309F,0x309F,0x30A0,0x30A0,0x30A1,0x30F6,0x30F7,0x30FA, +0x30FB,0x30FB,0x30FC,0x30FC,0x30FD,0x30FE,0x30FF,0x30FF, +0x31F0,0x31F9,0x31FA,0x31FF,0x3231,0x3232,0x3239,0x3239, +0x3251,0x325F,0x32A4,0x32A8,0x32B1,0x32BF,0x32D0,0x32E3, +0x32E5,0x32E5,0x32E9,0x32E9,0x32EC,0x32EC,0x32ED,0x32ED, +0x32FA,0x32FA,0x3303,0x3303,0x330D,0x330D,0x3314,0x3314, +0x3318,0x3318,0x3322,0x3322,0x3323,0x3323,0x3326,0x3326, +0x3327,0x3327,0x332B,0x332B,0x3336,0x3336,0x333B,0x333B, +0x3349,0x3349,0x334A,0x334A,0x334D,0x334D,0x3351,0x3351, +0x3357,0x3357,0x337B,0x337B,0x337C,0x337C,0x337D,0x337D, +0x337E,0x337E,0x338E,0x338F,0x339C,0x339E,0x33A1,0x33A1, +0x33C4,0x33C4,0x33CB,0x33CB,0x33CD,0x33CD,0x3402,0x3402, +0x3406,0x3406,0x342C,0x342C,0x342E,0x342E,0x3468,0x3468, +0x346A,0x346A,0x3492,0x3492,0x34B5,0x34B5,0x34BC,0x34BC, +0x34C1,0x34C1,0x34C7,0x34C7,0x34DB,0x34DB,0x351F,0x351F, +0x355D,0x355E,0x3563,0x3563,0x356E,0x356E,0x35A6,0x35A6, +0x35A8,0x35A8,0x35C5,0x35C5,0x35DA,0x35DA,0x35F4,0x35F4, +0x3605,0x3605,0x364A,0x364A,0x3691,0x3691,0x3696,0x3696, +0x3699,0x3699,0x36CF,0x36CF,0x3761,0x3761,0x3762,0x3762, +0x376B,0x376B,0x376C,0x376C,0x3775,0x3775,0x378D,0x378D, +0x37C1,0x37C1,0x37E2,0x37E2,0x37E8,0x37E8,0x37F4,0x37F4, +0x37FD,0x37FD,0x3800,0x3800,0x382F,0x382F,0x3836,0x3836, +0x3840,0x3840,0x385C,0x385C,0x3861,0x3861,0x38FA,0x38FA, +0x3917,0x3917,0x391A,0x391A,0x396F,0x396F,0x3A6E,0x3A6E, +0x3A73,0x3A73,0x3AD6,0x3AD6,0x3AD7,0x3AD7,0x3AEA,0x3AEA, +0x3B0E,0x3B0E,0x3B1A,0x3B1A,0x3B1C,0x3B1C,0x3B22,0x3B22, +0x3B6D,0x3B6D,0x3B77,0x3B77,0x3B87,0x3B88,0x3B8D,0x3B8D, +0x3BA4,0x3BA4,0x3BB6,0x3BB6,0x3BC3,0x3BC3,0x3BCD,0x3BCD, +0x3BF0,0x3BF0,0x3C0F,0x3C0F,0x3C26,0x3C26,0x3CC3,0x3CC3, +0x3CD2,0x3CD2,0x3D11,0x3D11,0x3D1E,0x3D1E,0x3D64,0x3D64, +0x3D9A,0x3D9A,0x3DC0,0x3DC0,0x3DD4,0x3DD4,0x3E05,0x3E05, +0x3E3F,0x3E3F,0x3E60,0x3E60,0x3E66,0x3E66,0x3E68,0x3E68, +0x3E83,0x3E83,0x3E94,0x3E94,0x3F57,0x3F57,0x3F72,0x3F72, +0x3F75,0x3F75,0x3F77,0x3F77,0x3FAE,0x3FAE,0x3FC9,0x3FC9, +0x3FD7,0x3FD7,0x4039,0x4039,0x4058,0x4058,0x4093,0x4093, +0x4105,0x4105,0x4148,0x4148,0x414F,0x414F,0x4163,0x4163, +0x41B4,0x41B4,0x41BF,0x41BF,0x41E6,0x41E6,0x41EE,0x41EE, +0x41F3,0x41F3,0x4207,0x4207,0x420E,0x420E,0x4264,0x4264, +0x42C6,0x42C6,0x42D6,0x42D6,0x42DD,0x42DD,0x4302,0x4302, +0x432B,0x432B,0x4343,0x4343,0x43EE,0x43EE,0x43F0,0x43F0, +0x4408,0x4408,0x4417,0x4417,0x441C,0x441C,0x4422,0x4422, +0x4453,0x4453,0x445B,0x445B,0x4476,0x4476,0x447A,0x447A, +0x4491,0x4491,0x44B3,0x44B3,0x44BE,0x44BE,0x44D4,0x44D4, +0x4508,0x4508,0x450D,0x450D,0x4525,0x4525,0x4543,0x4543, +0x459D,0x459D,0x45B8,0x45B8,0x45E5,0x45E5,0x45EA,0x45EA, +0x460F,0x460F,0x4641,0x4641,0x4665,0x4665,0x46A1,0x46A1, +0x46AF,0x46AF,0x470C,0x470C,0x4764,0x4764,0x47FD,0x47FD, +0x4816,0x4816,0x4844,0x4844,0x484E,0x484E,0x48B5,0x48B5, +0x49B0,0x49B0,0x49E7,0x49E7,0x49FA,0x49FA,0x4A04,0x4A04, +0x4A29,0x4A29,0x4ABC,0x4ABC,0x4B3B,0x4B3B,0x4BC2,0x4BC2, +0x4BCA,0x4BCA,0x4BD2,0x4BD2,0x4BE8,0x4BE8,0x4C17,0x4C17, +0x4C20,0x4C20,0x4CC4,0x4CC4,0x4CD1,0x4CD1,0x4D07,0x4D07, +0x4D77,0x4D77,}; + +const unsigned short ucs_c1_jisx0213_ofst[] = { +0x2872,0x2B46,0x2B50,0x213E,0x237C,0x213D,0x2142,0x2146, +0x2148,0x2277,0x2340,0x2145,0x2144,0x2273,0x216C,0x2228, +0x286B,0x007E,0x2B58,0x2C7E,0x286C,0x2C7D,0x2921,0x216E, +0x235D,0x235F,0x2D62,0x2D64,0x2360,0x2272,0x235C,0x2778, +0x2D35,0x2D57,0x2C35,0x222B,0x222A,0x222D,0x2271,0x2327, +0x2325,0x2328,0x2329,0x224D,0x224E,0x232B,0x232A,0x232D, +0x224F,0x225F,0x2250,0x2247,0x2260,0x223A,0x2246,0x223B, +0x215D,0x235B,0x2265,0x2267,0x2167,0x2D78,0x225C,0x2254, +0x224A,0x2241,0x2240,0x2269,0x2D73,0x2168,0x2268,0x2266, +0x226C,0x226D,0x226E,0x2262,0x2162,0x2261,0x226B,0x2165, +0x2263,0x226F,0x223E,0x2242,0x223C,0x2244,0x2251,0x225D, +0x2D79,0x2776,0x2248,0x225E,0x277C,0x2742,0x277E,0x277D, +0x2D21,0x2C41,0x2C2B,0x265A,0x2821,0x282C,0x2822,0x282D, +0x2823,0x282E,0x2824,0x282F,0x2826,0x2831,0x2825,0x2830, +0x2827,0x283C,0x2837,0x2832,0x2829,0x283E,0x2839,0x2834, +0x2828,0x2838,0x283D,0x2833,0x282A,0x283A,0x283F,0x2835, +0x282B,0x283B,0x2840,0x2836,0x2223,0x2222,0x266D,0x2225, +0x2224,0x2322,0x2321,0x2227,0x2226,0x2324,0x2323,0x2221, +0x217E,0x233B,0x217B,0x217D,0x217C,0x2867,0x233F,0x227E, +0x2668,0x217A,0x2179,0x2667,0x2664,0x2D7E,0x216A,0x2169, +0x263A,0x263D,0x263B,0x2640,0x2639,0x263E,0x263C,0x263F, +0x266C,0x227D,0x2276,0x227B,0x2275,0x227A,0x2274,0x277B, +0x2D7D,0x2C21,0x232E,0x233A,0x237D,0x2121,0x2137,0x2139, +0x2152,0x2229,0x222E,0x214C,0x225A,0x2258,0x2141,0x2D60, +0x2D61,0x2666,0x2233,0x2236,0x233C,0x2421,0x212B,0x2135, +0x2239,0x237B,0x2521,0x2772,0x2126,0x213C,0x2133,0x2238, +0x266E,0x2679,0x2D6A,0x2D6C,0x2841,0x2D65,0x2850,0x2C5B, +0x2C71,0x2C70,0x2C73,0x2C72,0x2C6F,0x2D46,0x2D4A,0x2D41, +0x2D44,0x2D42,0x2D4C,0x2D4B,0x2D45,0x2D4D,0x2D47,0x2D4F, +0x2D40,0x2D4E,0x2D43,0x2D48,0x2D49,0x2D5F,0x2D6F,0x2D6E, +0x2D6D,0x2D53,0x2D50,0x2D56,0x2D55,0x235E,0x2D63,0x2E23, +0x7F2D,0x7F32,0x7F33,0x7F5E,0x7F56,0x7F7E,0x2E53,0x812B, +0x8E68,0x812F,0x2E5B,0x8148,0x815D,0x8161,0x8167,0x8223, +0x8226,0x822F,0x8238,0x8242,0x824A,0x8279,0x833F,0x8343, +0x8341,0x8357,0x8023,0x8025,0x8029,0x8028,0x802C,0x4F5F, +0x803E,0x4F6F,0x8056,0x8059,0x805C,0x805E,0x806F,0x8071, +0x8074,0x8079,0x807B,0x843B,0x8446,0x844A,0x8460,0x855B, +0x855F,0x8571,0x8636,0x857C,0x862E,0x8632,0x8634,0x7549, +0x866D,0x8665,0x8728,0x872C,0x8734,0x757E,0x7621,0x8748, +0x875D,0x763A,0x8777,0x883B,0x8842,0x8871,0x887E,0x8940, +0x8954,0x8970,0x8977,0x8A28,0x7766,0x8A3F,0x8A41,0x8A42, +0x8A49,0x8A50,0x8B34,0x784D,0x8B46,0x8B48,0x8B5C,0x8B67, +0x8B6C,0x8C22,0x8C2D,0x8C39,0x8C64,0x8C74,0x8C77,0x8C7D, +0x8D33,0x8D37,0x8D47,0x8D4B,0x8D48,0x8D53,0x8D57,0x796D, +0x8E2B,0x8E36,0x8E3B,0x8E4E,0x8E5D,0x8E61,0x8F3E,0x8F42, +0x8F48,0x8F4A,0x8F4C,0x8F4F,0x7A59,0x7A5A,0x8F6C,0x8F6E, +0x8F77,0x9035,0x9032,0x9034,0x9059,0x9054,0x906D,0x906E, +0x7B51,0x914F,0x916C,0x7B60,0x9224,0x923A,0x9243,0x924E, +0x9253,0x926B,0x9329,0x933F,0x9349,0x7C4B,0x935C,0x9427, +0x7D58,0x956A,0x9570,0x9575,0x9578,0x9637,0x9655,0x9726, +0x9728,0x972A,0x9731,0x7E3E,0x973F,0x982A,0x982D,0x984B, +0x9860,}; + +const int ucs_c1_jisx0213_tbl_len = sizeof(ucs_c1_jisx0213_ofst)/sizeof(unsigned short); + +const int ucs_c1_jisx0213_min = 0x1E00; +const int ucs_c1_jisx0213_max = 0x4DFF; + +const unsigned short jisx0213_jis_u5_tbl[] = { +0x000B,0x123D,0x131B,0x146E,0x18BD,0x0B9F,0x16B4,0x1E34, +0x31C4,0x35C4,0x373F,0x3763,0x3CFE,0x47F1,0x548E,0x550E, +0x5771,0x59C4,0x5DA1,0x6AFF,0x6E40,0x70F4,0x7684,0x8277, +0x83CD,0xA190,0x0089,0x00A2,0x00A4,0x01A2,0x0213,0x032B, +0x0381,0x0371,0x1C56,0x1D2D,0x1D45,0x1D78,0x1D62,0x1DA1, +0x1D9C,0x1D92,0x1DB7,0x1DE0,0x1E33,0x1F1E,0x1F76,0x1FFA, +0x03F9,0x044A,0x0509,0x05D6,0x0628,0x074F,0x0807,0x083A, +0x08B9,0x097C,0x099D,0x0AD3,0x0B1D,0x0D45,0x0DE1,0x0E95, +0x0E6D,0x0E64,0x0F5F,0x1201,0x1255,0x127B,0x1274,0x12E4, +0x12D7,0x12FD,0x1336,0x1344,0x13C4,0x146D,0x15D7,0x6C29, +0x1647,0x1706,0x1742,0x19C3,0x217B,0x231E,0x23AD,0x26F3, +0x285B,0x28AB,0x298F,0x2AB8,0x2B4F,0x2B50,0x2B46,0x2C1D, +0x2BA6,0x2C24,0x2DE1,0x31C3,0x31F5,0x31B6,0x3372,0x33D3, +0x33D2,0x33D0,0x33E4,0x33D5,0x33DA,0x33DF,0x344A,0x3451, +0x344B,0x3465,0x34E4,0x355A,0x3594,0x3639,0x3647,0x3638, +0x363A,0x371C,0x370C,0x3764,0x37FF,0x37E7,0x3824,0x383D, +0x3A98,0x3C7F,0x3D00,0x3D40,0x3DFA,0x3DF9,0x3DD3,0x3F7E, +0x4096,0x4103,0x41C6,0x41FE,0x43BC,0x4629,0x46A5,0x4896, +0x4A4D,0x4B56,0x4B6F,0x4C16,0x4D14,0x4E0E,0x4E37,0x4E6A, +0x4E8B,0x504A,0x5055,0x5122,0x51A9,0x51E5,0x51CD,0x521E, +0x524C,0x542E,0x54D9,0x55A7,0x57A9,0x57B4,0x59D4,0x5AE4, +0x5AE3,0x5AF1,0x5BB2,0x5C4B,0x5C64,0x5E2E,0x5E56,0x5E65, +0x5E62,0x5ED8,0x5EC2,0x5EE8,0x5F23,0x5F5C,0x5FE0,0x5FD4, +0x600C,0x5FFB,0x6017,0x6060,0x60ED,0x6270,0x6286,0x634C, +0x3D0E,0x6402,0x667E,0x66B0,0x671D,0x68DD,0x68EA,0x6951, +0x696F,0x69DD,0x6A1E,0x6A58,0x6A8C,0x6AB7,0x6C73,0x6CDD, +0x6E65,0x6F94,0x6FF8,0x6FF6,0x6FF7,0x710D,0x7139,0x73DB, +0x73DA,0x73FE,0x7410,0x7449,0x7615,0x7614,0x7631,0x7693, +0x770E,0x7723,0x7752,0x7985,0x7A84,0x7BB3,0x7BBE,0x7BC7, +0x7CB8,0x7DA0,0x7E10,0x7FB7,0x808A,0x80BB,0x8282,0x82F3, +0x840C,0x8455,0x856B,0x85C8,0x85C9,0x86D7,0x86FA,0x8949, +0x8946,0x896B,0x8987,0x8988,0x89BA,0x89BB,0x8A1E,0x8A29, +0x8A71,0x8A43,0x8A99,0x8ACD,0x8AE4,0x8ADD,0x8BC1,0x8BEF, +0x8D10,0x8D71,0x8DFB,0x8E1F,0x8E36,0x8E89,0x8EEB,0x8F32, +0x8FF8,0x92A0,0x92B1,0x9490,0x95CF,0x967F,0x96F0,0x9719, +0x9750,0x98C6,0x9A72,0x9DDB,0x9E3D,0x9E15,0x9E8A,0x9E49, +0x9EC4,0x9EE9,0x9EDB,0x9FCE,0xA02F,0xA01A,0xA0F9,0xA082, +0x2218,0xA38C,0xA437,0xA5F1,0xA602,0xA61A,0xA6B2,}; + +const unsigned short jisx0213_jis_u5_key[] = { +0x2E22,0x2F42,0x2F4C,0x2F60,0x2F7B,0x4F54,0x4F63,0x4F6E, +0x753A,0x7572,0x7629,0x7632,0x7660,0x776C,0x787E,0x7929, +0x7947,0x7954,0x796E,0x7A5D,0x7B33,0x7B49,0x7B6C,0x7C49, +0x7C51,0x7E66,0x7F21,0x7F2B,0x7F2E,0x7F36,0x7F46,0x7F70, +0x7F77,0x7F79,0x8030,0x8037,0x8038,0x803A,0x803B,0x803F, +0x8040,0x8045,0x8048,0x804A,0x804B,0x805B,0x8066,0x806C, +0x8122,0x8125,0x8127,0x8131,0x8132,0x8138,0x813F,0x8141, +0x814A,0x8152,0x8153,0x8159,0x815C,0x8177,0x822A,0x8231, +0x8232,0x823A,0x823D,0x8259,0x825C,0x825E,0x8263,0x826A, +0x826B,0x8272,0x8274,0x8275,0x8325,0x8332,0x833E,0x8344, +0x8347,0x8355,0x8356,0x837E,0x8422,0x842B,0x8430,0x8450, +0x8465,0x846D,0x8472,0x8524,0x8529,0x852A,0x8532,0x8534, +0x8535,0x8539,0x8556,0x857D,0x8623,0x8624,0x863A,0x863C, +0x863D,0x8642,0x8643,0x8644,0x8647,0x8649,0x8655,0x8656, +0x8657,0x865B,0x8677,0x8678,0x872A,0x873F,0x8740,0x8742, +0x8743,0x874E,0x8759,0x8761,0x8769,0x876A,0x8770,0x8775, +0x8823,0x8834,0x8849,0x885C,0x885E,0x885F,0x8860,0x8932, +0x8947,0x894D,0x8961,0x8964,0x8A22,0x8A33,0x8A39,0x8A53, +0x8A7B,0x8B2E,0x8B30,0x8B35,0x8B44,0x8B5D,0x8B61,0x8B66, +0x8B69,0x8B75,0x8B77,0x8B7A,0x8C21,0x8C23,0x8C24,0x8C28, +0x8C2C,0x8C3D,0x8C48,0x8C5B,0x8C75,0x8C76,0x8D32,0x8D3D, +0x8D3E,0x8D40,0x8D52,0x8D5D,0x8D5E,0x8D73,0x8D74,0x8D75, +0x8D77,0x8D7B,0x8D7D,0x8E22,0x8E24,0x8E27,0x8E2E,0x8E2F, +0x8E34,0x8E35,0x8E3D,0x8E42,0x8E4F,0x8E69,0x8E6B,0x8E72, +0x8E75,0x8E79,0x8F35,0x8F3A,0x8F46,0x8F56,0x8F58,0x8F5A, +0x8F5D,0x8F5F,0x8F63,0x8F6A,0x8F70,0x8F73,0x9044,0x904E, +0x905D,0x9075,0x907E,0x9121,0x9122,0x9133,0x9136,0x9164, +0x9165,0x916B,0x916E,0x9173,0x9229,0x922A,0x922C,0x9234, +0x923C,0x923E,0x9242,0x9256,0x9263,0x9277,0x9279,0x927A, +0x9325,0x932F,0x9332,0x9339,0x9342,0x9348,0x9359,0x935E, +0x9366,0x936B,0x937A,0x937E,0x9421,0x942C,0x942F,0x944F, +0x9450,0x9457,0x9465,0x9466,0x9471,0x9472,0x947E,0x9521, +0x952C,0x952D,0x9536,0x9537,0x953D,0x953E,0x954E,0x954F, +0x9557,0x955A,0x955C,0x955D,0x9561,0x9565,0x9567,0x9569, +0x9571,0x9622,0x9623,0x9638,0x9642,0x964C,0x9656,0x9659, +0x965D,0x9676,0x972C,0x974B,0x974C,0x9759,0x975B,0x975D, +0x9767,0x976D,0x9770,0x9825,0x9829,0x982B,0x9832,0x9835, +0x9853,0x9858,0x985A,0x986E,0x9870,0x9872,0x9876,}; + +const unsigned short jisx0213_u5_jis_tbl[] = { +0x2E22,0x7F21,0x7F2B,0x7F2E,0x7F36,0x7F46,0x7F70,0x7F79, +0x7F77,0x8122,0x8125,0x8127,0x8131,0x8132,0x8138,0x813F, +0x8141,0x814A,0x8152,0x8153,0x8159,0x815C,0x4F54,0x8177, +0x822A,0x823A,0x8232,0x8231,0x823D,0x8259,0x2F42,0x825C, +0x8263,0x825E,0x826B,0x826A,0x8272,0x2F4C,0x8274,0x8275, +0x8325,0x8332,0x2F60,0x833E,0x8347,0x4F63,0x8355,0x8356, +0x2F7B,0x837E,0x8030,0x8037,0x8038,0x803B,0x803A,0x8045, +0x8040,0x803F,0x8048,0x804A,0x804B,0x4F6E,0x805B,0x8066, +0x806C,0x8422,0x9853,0x842B,0x8430,0x8450,0x8465,0x846D, +0x8472,0x8524,0x8532,0x8529,0x852A,0x8535,0x8534,0x8539, +0x8556,0x8624,0x857D,0x753A,0x8623,0x863A,0x8642,0x863D, +0x863C,0x8644,0x8647,0x8649,0x8643,0x8655,0x8657,0x8656, +0x865B,0x8677,0x8678,0x872A,0x7572,0x8742,0x873F,0x8743, +0x8740,0x8759,0x874E,0x7629,0x7632,0x8761,0x876A,0x8769, +0x8770,0x8775,0x8823,0x8834,0x7660,0x8849,0x8E75,0x885C, +0x8860,0x885F,0x885E,0x8932,0x8947,0x894D,0x8961,0x8964, +0x8A22,0x8A33,0x8A39,0x776C,0x8A53,0x8A7B,0x8B2E,0x8B30, +0x8B35,0x8B44,0x8B5D,0x8B61,0x8B66,0x8B69,0x8B75,0x8B77, +0x8B7A,0x8C21,0x8C24,0x8C23,0x8C28,0x8C2C,0x8C3D,0x787E, +0x8C48,0x7929,0x8C5B,0x7947,0x8C75,0x8C76,0x7954,0x8D32, +0x8D3E,0x8D3D,0x8D40,0x8D52,0x8D5D,0x8D5E,0x796E,0x8D73, +0x8D74,0x8D77,0x8D75,0x8D7D,0x8D7B,0x8E22,0x8E24,0x8E27, +0x8E2F,0x8E2E,0x8E35,0x8E34,0x8E3D,0x8E42,0x8E4F,0x8E69, +0x8E6B,0x8E72,0x8E79,0x8F35,0x8F3A,0x8F46,0x8F56,0x8F58, +0x8F5A,0x8F5D,0x8F5F,0x8F63,0x8F6A,0x8F70,0x8F73,0x7A5D, +0x8344,0x9044,0x904E,0x7B33,0x905D,0x9075,0x9121,0x9122, +0x907E,0x7B49,0x9133,0x9136,0x9165,0x9164,0x916B,0x916E, +0x9173,0x922A,0x9229,0x922C,0x7B6C,0x9234,0x923C,0x923E, +0x9242,0x9256,0x9263,0x9277,0x9279,0x927A,0x9325,0x932F, +0x9332,0x9339,0x9342,0x9348,0x7C49,0x9359,0x935E,0x7C51, +0x9366,0x936B,0x937A,0x937E,0x9421,0x942C,0x942F,0x9450, +0x944F,0x9457,0x9465,0x9466,0x9471,0x9472,0x947E,0x9521, +0x952D,0x952C,0x9536,0x9537,0x953E,0x953D,0x954E,0x954F, +0x9557,0x955A,0x955C,0x955D,0x9561,0x9565,0x9567,0x9569, +0x9571,0x9622,0x9623,0x9638,0x9642,0x964C,0x9656,0x9659, +0x965D,0x9676,0x972C,0x974B,0x9759,0x974C,0x975D,0x975B, +0x9767,0x9770,0x976D,0x9825,0x982B,0x9829,0x9835,0x9832, +0x7E66,0x9858,0x985A,0x986E,0x9870,0x9872,0x9876,}; + +const unsigned short jisx0213_u5_jis_key[] = { +0x000B,0x0089,0x00A2,0x00A4,0x01A2,0x0213,0x032B,0x0371, +0x0381,0x03F9,0x044A,0x0509,0x05D6,0x0628,0x074F,0x0807, +0x083A,0x08B9,0x097C,0x099D,0x0AD3,0x0B1D,0x0B9F,0x0D45, +0x0DE1,0x0E64,0x0E6D,0x0E95,0x0F5F,0x1201,0x123D,0x1255, +0x1274,0x127B,0x12D7,0x12E4,0x12FD,0x131B,0x1336,0x1344, +0x13C4,0x146D,0x146E,0x15D7,0x1647,0x16B4,0x1706,0x1742, +0x18BD,0x19C3,0x1C56,0x1D2D,0x1D45,0x1D62,0x1D78,0x1D92, +0x1D9C,0x1DA1,0x1DB7,0x1DE0,0x1E33,0x1E34,0x1F1E,0x1F76, +0x1FFA,0x217B,0x2218,0x231E,0x23AD,0x26F3,0x285B,0x28AB, +0x298F,0x2AB8,0x2B46,0x2B4F,0x2B50,0x2BA6,0x2C1D,0x2C24, +0x2DE1,0x31B6,0x31C3,0x31C4,0x31F5,0x3372,0x33D0,0x33D2, +0x33D3,0x33D5,0x33DA,0x33DF,0x33E4,0x344A,0x344B,0x3451, +0x3465,0x34E4,0x355A,0x3594,0x35C4,0x3638,0x3639,0x363A, +0x3647,0x370C,0x371C,0x373F,0x3763,0x3764,0x37E7,0x37FF, +0x3824,0x383D,0x3A98,0x3C7F,0x3CFE,0x3D00,0x3D0E,0x3D40, +0x3DD3,0x3DF9,0x3DFA,0x3F7E,0x4096,0x4103,0x41C6,0x41FE, +0x43BC,0x4629,0x46A5,0x47F1,0x4896,0x4A4D,0x4B56,0x4B6F, +0x4C16,0x4D14,0x4E0E,0x4E37,0x4E6A,0x4E8B,0x504A,0x5055, +0x5122,0x51A9,0x51CD,0x51E5,0x521E,0x524C,0x542E,0x548E, +0x54D9,0x550E,0x55A7,0x5771,0x57A9,0x57B4,0x59C4,0x59D4, +0x5AE3,0x5AE4,0x5AF1,0x5BB2,0x5C4B,0x5C64,0x5DA1,0x5E2E, +0x5E56,0x5E62,0x5E65,0x5EC2,0x5ED8,0x5EE8,0x5F23,0x5F5C, +0x5FD4,0x5FE0,0x5FFB,0x600C,0x6017,0x6060,0x60ED,0x6270, +0x6286,0x634C,0x6402,0x667E,0x66B0,0x671D,0x68DD,0x68EA, +0x6951,0x696F,0x69DD,0x6A1E,0x6A58,0x6A8C,0x6AB7,0x6AFF, +0x6C29,0x6C73,0x6CDD,0x6E40,0x6E65,0x6F94,0x6FF6,0x6FF7, +0x6FF8,0x70F4,0x710D,0x7139,0x73DA,0x73DB,0x73FE,0x7410, +0x7449,0x7614,0x7615,0x7631,0x7684,0x7693,0x770E,0x7723, +0x7752,0x7985,0x7A84,0x7BB3,0x7BBE,0x7BC7,0x7CB8,0x7DA0, +0x7E10,0x7FB7,0x808A,0x80BB,0x8277,0x8282,0x82F3,0x83CD, +0x840C,0x8455,0x856B,0x85C8,0x85C9,0x86D7,0x86FA,0x8946, +0x8949,0x896B,0x8987,0x8988,0x89BA,0x89BB,0x8A1E,0x8A29, +0x8A43,0x8A71,0x8A99,0x8ACD,0x8ADD,0x8AE4,0x8BC1,0x8BEF, +0x8D10,0x8D71,0x8DFB,0x8E1F,0x8E36,0x8E89,0x8EEB,0x8F32, +0x8FF8,0x92A0,0x92B1,0x9490,0x95CF,0x967F,0x96F0,0x9719, +0x9750,0x98C6,0x9A72,0x9DDB,0x9E15,0x9E3D,0x9E49,0x9E8A, +0x9EC4,0x9EDB,0x9EE9,0x9FCE,0xA01A,0xA02F,0xA082,0xA0F9, +0xA190,0xA38C,0xA437,0xA5F1,0xA602,0xA61A,0xA6B2,}; + +const int jisx0213_u5_tbl_min = 0x2000B; +const int jisx0213_u5_tbl_max = 0x2A6B2; +const int jisx0213_u5_tbl_len = sizeof(jisx0213_u5_jis_key)/sizeof(unsigned short); + +const unsigned short jisx0213_u2_key[] = { + 0x2477,0x2478,0x2479,0x247A,0x247B,0x2577,0x2578,0x2579, + 0x257A,0x257B,0x257C,0x257D,0x257E,0x2678,0x2B44,0x2B48, + 0x2B49,0x2B4A,0x2B4B,0x2B4C,0x2B4D,0x2B4E,0x2B4F,0x2B65, + 0x2B66}; + +const unsigned short jisx0213_u2_tbl[] = { + 0x304B,0x309A,0x304D,0x309A,0x304F,0x309A,0x3051,0x309A, + 0x3053,0x309A,0x30AB,0x309A,0x30AD,0x309A,0x30AF,0x309A, + 0x30B1,0x309A,0x30B3,0x309A,0x30BB,0x309A,0x30C4,0x309A, + 0x30C8,0x309A,0x31F7,0x309A,0x00E6,0x0300,0x0254,0x0300, + 0x0254,0x0301,0x028C,0x0300,0x028C,0x0301,0x0259,0x0300, + 0x0259,0x0301,0x025A,0x0300,0x025A,0x0301,0x02E9,0x02E5, + 0x02E5,0x02E9}; + +const unsigned short jisx0213_u2_fb_tbl[] = { + 0x242B,0x242D,0x242F,0x2431,0x2433,0x252B,0x252D,0x252F, + 0x2531,0x2533,0x253B,0x2544,0x2548,0x2675,0x295C,0x2B38, + 0x2B38,0x2B37,0x2B37,0x2B30,0x2B30,0x2B43,0x2B43,0x2B64, + 0x2B60}; + +const int jisx0213_u2_tbl_len = sizeof(jisx0213_u2_key)/sizeof(unsigned short); + +const unsigned short jisx0213_uni2sjis_cmap_key[] = { + 0xf91d,0xf928,0xf929,0xf936,0xf970,0xf9d0,0xf9dc, + 0xfe45,0xfe46,0xffe5, +}; + +const unsigned short jisx0213_uni2sjis_cmap_val[] = { + 0x763b,0x742e,0x754e,0x7b4f,0x7649,0x7e24,0x7d5d, + 0x233e,0x233d,0x216f, +}; + +const int jisx0213_uni2sjis_cmap_len = + sizeof(jisx0213_uni2sjis_cmap_key)/sizeof(unsigned short); + + +const unsigned short jisx0213_p2_ofst[] = { + 1, 8, 3, 4, 5, 12, 13, 14, 15, 78, 79, 80, 81, 82, + 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94}; + +const int jisx0213_p2_ofst_len = + sizeof(jisx0213_p2_ofst)/sizeof(unsigned short); + +#else + +extern const unsigned short jisx0213_ucs_table[]; +extern const unsigned short ucs_a1_jisx0213_table[]; +extern const unsigned short ucs_i_jisx0213_table[]; +extern const unsigned short ucs_r_jisx0213_table[]; +extern const unsigned short ucs_r2_jisx0213_table[]; + +extern const unsigned short ucs_c1_jisx0213_table[]; +extern const unsigned short ucs_c1_jisx0213_ofst[]; +extern const unsigned short jisx0213_jis_u5_tbl[]; +extern const unsigned short jisx0213_jis_u5_key[]; +extern const unsigned short jisx0213_u5_jis_tbl[]; +extern const unsigned short jisx0213_u5_jis_key[]; +extern const unsigned short jisx0213_u2_key[]; +extern const unsigned short jisx0213_u2_tbl[]; +extern const unsigned short jisx0213_u2_fb_tbl[]; +extern const unsigned short jisx0213_uni2sjis_cmap_key[]; +extern const unsigned short jisx0213_uni2sjis_cmap_val[]; + +extern const int jisx0213_ucs_table_size; +extern const int ucs_a1_jisx0213_table_min; +extern const int ucs_a1_jisx0213_table_max; +extern const int ucs_i_jisx0213_table_min; +extern const int ucs_i_jisx0213_table_max; +extern int ucs_r_jisx0213_table_min; +extern int ucs_r_jisx0213_table_max; +extern int ucs_r2_jisx0213_table_min; +extern int ucs_r2_jisx0213_table_max; + +extern const int ucs_c1_jisx0213_tbl_len; +extern const int jisx0213_u5_tbl_min; +extern const int jisx0213_u5_tbl_max; +extern const int jisx0213_u5_tbl_len; +extern const int jisx0213_u2_tbl_len; +extern const int jisx0213_uni2sjis_cmap_len; + +extern const unsigned short ucs_c1_jisx0213_tbl[]; + +extern const int ucs_c1_jisx0213_min; +extern const int ucs_c1_jisx0213_max; + +extern const unsigned short jisx0213_p2_ofst[]; +extern const int jisx0213_p2_ofst_len; + +#endif /* UNICODE_TABLE_JIS2004_DEF */ +#endif /* UNICODE_TABLE_JIS2004_H */ + diff --git a/ext/mbstring/libmbfl/mbfl/mbfilter.h b/ext/mbstring/libmbfl/mbfl/mbfilter.h index 496d1b12cac4f..6108f93195ec3 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfilter.h +++ b/ext/mbstring/libmbfl/mbfl/mbfilter.h @@ -103,7 +103,7 @@ */ #define MBFL_VERSION_MAJOR 1 #define MBFL_VERSION_MINOR 3 -#define MBFL_VERSION_TEENY 1 +#define MBFL_VERSION_TEENY 2 /* * convert filter diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_consts.h b/ext/mbstring/libmbfl/mbfl/mbfl_consts.h index 07c6296eea809..6a630c8fcd821 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_consts.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_consts.h @@ -51,6 +51,7 @@ #define MBFL_WCSPLANE_UTF32MAX 0x00110000 #define MBFL_WCSPLANE_SUPMIN 0x00010000 #define MBFL_WCSPLANE_SUPMAX 0x00200000 +#define MBFL_WCSPLANE_JIS0213 0x70e00000 /* JIS HEX : 2121h - 7E7Eh */ #define MBFL_WCSPLANE_JIS0208 0x70e10000 /* JIS HEX : 2121h - 7E7Eh */ #define MBFL_WCSPLANE_JIS0212 0x70e20000 /* JIS HEX : 2121h - 7E7Eh */ #define MBFL_WCSPLANE_WINCP932 0x70e30000 /* JIS HEX : 2121h - 9898h */ diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index e3ac774fd0531..d2d051e53edd2 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -52,12 +52,15 @@ #include "filters/mbfilter_iso2022_kr.h" #include "filters/mbfilter_sjis.h" #include "filters/mbfilter_sjis_open.h" +#include "filters/mbfilter_sjis_2004.h" #include "filters/mbfilter_sjis_mobile.h" #include "filters/mbfilter_sjis_mac.h" #include "filters/mbfilter_cp51932.h" #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" +#include "filters/mbfilter_iso2022jp_2004.h" #include "filters/mbfilter_euc_jp.h" +#include "filters/mbfilter_euc_jp_2004.h" #include "filters/mbfilter_euc_jp_win.h" #include "filters/mbfilter_gb18030.h" #include "filters/mbfilter_ascii.h" @@ -115,6 +118,8 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_sjis, &vtbl_sjis_open_wchar, &vtbl_wchar_sjis_open, + &vtbl_sjis2004_wchar, + &vtbl_wchar_sjis2004, &vtbl_cp51932_wchar, &vtbl_wchar_cp51932, &vtbl_jis_wchar, @@ -125,8 +130,12 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_2022jp, &vtbl_2022jpms_wchar, &vtbl_wchar_2022jpms, + &vtbl_2022jp_2004_wchar, + &vtbl_wchar_2022jp_2004, &vtbl_eucjpwin_wchar, &vtbl_wchar_eucjpwin, + &vtbl_eucjp2004_wchar, + &vtbl_wchar_eucjp2004, &vtbl_cp932_wchar, &vtbl_wchar_cp932, &vtbl_sjis_docomo_wchar, @@ -165,6 +174,8 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_euctw, &vtbl_big5_wchar, &vtbl_wchar_big5, + &vtbl_cp950_wchar, + &vtbl_wchar_cp950, &vtbl_euckr_wchar, &vtbl_wchar_euckr, &vtbl_uhc_wchar, @@ -484,9 +495,15 @@ mbfl_filt_conv_illegal_output(int c, mbfl_convert_filter *filter) case MBFL_WCSPLANE_JIS0212: ret = mbfl_convert_filter_strcat(filter, (const unsigned char *)"JIS2+"); break; + case MBFL_WCSPLANE_JIS0213: + ret = mbfl_convert_filter_strcat(filter, (const unsigned char *)"JIS3+"); + break; case MBFL_WCSPLANE_WINCP932: ret = mbfl_convert_filter_strcat(filter, (const unsigned char *)"W932+"); break; + case MBFL_WCSPLANE_GB18030: + ret = mbfl_convert_filter_strcat(filter, (const unsigned char *)"GB+"); + break; case MBFL_WCSPLANE_8859_1: ret = mbfl_convert_filter_strcat(filter, (const unsigned char *)"I8859_1+"); break; diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index 85c4339f283a4..58af1c58f0d46 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -60,11 +60,14 @@ #include "filters/mbfilter_sjis_open.h" #include "filters/mbfilter_sjis_mobile.h" #include "filters/mbfilter_sjis_mac.h" +#include "filters/mbfilter_sjis_2004.h" #include "filters/mbfilter_cp51932.h" #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" +#include "filters/mbfilter_iso2022jp_2004.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" +#include "filters/mbfilter_euc_jp_2004.h" #include "filters/mbfilter_gb18030.h" #include "filters/mbfilter_ascii.h" #include "filters/mbfilter_koi8r.h" @@ -159,6 +162,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_euc_jp, &mbfl_encoding_sjis, &mbfl_encoding_eucjp_win, + &mbfl_encoding_eucjp2004, &mbfl_encoding_sjis_open, &mbfl_encoding_sjis_docomo, &mbfl_encoding_sjis_kddi, @@ -168,6 +172,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_sjis_kddi_pua_b, &mbfl_encoding_sjis_sb_pua, &mbfl_encoding_sjis_mac, + &mbfl_encoding_sjis2004, &mbfl_encoding_utf8_docomo, &mbfl_encoding_utf8_kddi, &mbfl_encoding_utf8_kddi_b, @@ -199,6 +204,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_hz, &mbfl_encoding_euc_tw, &mbfl_encoding_big5, + &mbfl_encoding_cp950, &mbfl_encoding_euc_kr, &mbfl_encoding_uhc, &mbfl_encoding_2022kr, @@ -209,6 +215,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_armscii8, &mbfl_encoding_cp850, &mbfl_encoding_jis_ms, + &mbfl_encoding_2022jp_2004, &mbfl_encoding_cp50220, &mbfl_encoding_cp50220raw, &mbfl_encoding_cp50221, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index 1ac05757ce7b9..000c0a353ed48 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -70,6 +70,7 @@ enum mbfl_no_encoding { mbfl_no_encoding_utf7imap, mbfl_no_encoding_ascii, mbfl_no_encoding_euc_jp, + mbfl_no_encoding_eucjp2004, mbfl_no_encoding_sjis, mbfl_no_encoding_eucjp_win, mbfl_no_encoding_sjis_open, @@ -81,10 +82,12 @@ enum mbfl_no_encoding { mbfl_no_encoding_sjis_kddi_pua_b, mbfl_no_encoding_sjis_sb_pua, mbfl_no_encoding_sjis_mac, + mbfl_no_encoding_sjis2004, mbfl_no_encoding_cp932, mbfl_no_encoding_cp51932, mbfl_no_encoding_jis, mbfl_no_encoding_2022jp, + mbfl_no_encoding_2022jp_2004, mbfl_no_encoding_2022jpms, mbfl_no_encoding_gb18030, mbfl_no_encoding_cp1252, @@ -106,6 +109,7 @@ enum mbfl_no_encoding { mbfl_no_encoding_cp936, mbfl_no_encoding_euc_tw, mbfl_no_encoding_big5, + mbfl_no_encoding_cp950, mbfl_no_encoding_euc_kr, mbfl_no_encoding_2022kr, mbfl_no_encoding_uhc, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c index fdffc70471662..23c26190196df 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c @@ -54,8 +54,10 @@ #include "filters/mbfilter_sjis_mobile.h" #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" +#include "filters/mbfilter_iso2022jp_2004.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" +#include "filters/mbfilter_euc_jp_2004.h" #include "filters/mbfilter_utf8_mobile.h" #include "filters/mbfilter_ascii.h" #include "filters/mbfilter_koi8r.h" @@ -114,10 +116,12 @@ static const struct mbfl_identify_vtbl *mbfl_identify_filter_list[] = { &vtbl_identify_sjis, &vtbl_identify_sjis_open, &vtbl_identify_eucjpwin, + &vtbl_identify_eucjp2004, &vtbl_identify_cp932, &vtbl_identify_jis, &vtbl_identify_2022jp, &vtbl_identify_2022jpms, + &vtbl_identify_2022jp_2004, &vtbl_identify_cp51932, &vtbl_identify_sjis_docomo, &vtbl_identify_sjis_kddi, @@ -131,6 +135,7 @@ static const struct mbfl_identify_vtbl *mbfl_identify_filter_list[] = { &vtbl_identify_hz, &vtbl_identify_euctw, &vtbl_identify_big5, + &vtbl_identify_cp950, &vtbl_identify_euckr, &vtbl_identify_uhc, &vtbl_identify_2022kr, From 1fe350e271d5fcbeec65144caf1b352217c8936e Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 20 Aug 2011 07:27:48 +0000 Subject: [PATCH 0583/2394] update NEWS. --- NEWS | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/NEWS b/NEWS index ad32affa8f41c..f139262c02edf 100644 --- a/NEWS +++ b/NEWS @@ -170,10 +170,13 @@ PHP NEWS iarenuno@eteo.mondragon.edu, jeanseb@au-fil-du.net, remy.saissy@gmail.com) - Improved mbstring extension: - . Added Shift_JIS Emoji (pictograms) support. (rui) - . Ill-formed UTF-8 check for security enhancements. (rui) - . Added MacJapanese (Shift_JIS) and gb18030 encoding support. (rui) - . Added encode/decode in hex format to mb_[en|de]code_numericentity(). (rui) + . Added Shift_JIS/UTF-8 Emoji (pictograms) support. (Rui) + . Added JIS X0213:2004 (Shift_JIS-2004, EUC-JP-2004, ISO-2022-JP-2004) support. (Rui) + . Ill-formed UTF-8 check for security enhancements. (Rui) + . Added MacJapanese (Shift_JIS) and gb18030 encoding support. (Rui) + . Added encode/decode in hex format to mb_[en|de]code_numericentity(). (Rui) + . Added user JIS X0213:2004 (Shift_JIS-2004, EUC-JP-2004, ISO-2022-JP-2004) support. (Rui) + . Added the user user defined area for CP936 and CP950 (Rui). - Improved MySQL extensions: . MySQL: Deprecated mysql_list_dbs(). FR #50667. (Andrey) From dcf0dfb9ab99b99da5817c55aafa71a816337cb4 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 20 Aug 2011 08:27:57 +0000 Subject: [PATCH 0584/2394] removed SJIS-Mobile#*PUA. --- ext/mbstring/libmbfl/filters/Makefile.am | 4 +- .../libmbfl/filters/mbfilter_sjis_mobile.c | 189 ++---------------- .../libmbfl/filters/mbfilter_sjis_mobile.h | 17 -- ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 8 - ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 4 - ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 4 - 6 files changed, 24 insertions(+), 202 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/Makefile.am b/ext/mbstring/libmbfl/filters/Makefile.am index ad7beb5580fe3..4420b36621d29 100644 --- a/ext/mbstring/libmbfl/filters/Makefile.am +++ b/ext/mbstring/libmbfl/filters/Makefile.am @@ -55,7 +55,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_euc_kr.c \ mbfilter_uhc.c \ mbfilter_iso2022_jp_ms.c \ - mbfilter_iso2022_jp_2004.c \ + mbfilter_iso2022jp_2004.c \ mbfilter_gb18030.c \ mbfilter_iso2022_kr.c \ mbfilter_cp866.c \ @@ -90,7 +90,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_htmlent.h \ mbfilter_hz.h \ mbfilter_iso2022_jp_ms.h \ - mbfilter_iso2022_jp_2004.h \ + mbfilter_iso2022jp_2004.h \ mbfilter_iso2022_kr.h \ mbfilter_iso8859_1.h \ mbfilter_iso8859_10.h \ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c index 6da38db6fae3a..7bce1854548d0 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -70,42 +70,6 @@ const mbfl_encoding mbfl_encoding_sjis_sb = { MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE }; -const mbfl_encoding mbfl_encoding_sjis_docomo_pua = { - mbfl_no_encoding_sjis_docomo_pua, - "SJIS-Mobile#DOCOMO-PUA", - "Shift_JIS", - NULL, - mblen_table_sjis, - MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE -}; - -const mbfl_encoding mbfl_encoding_sjis_kddi_pua = { - mbfl_no_encoding_sjis_kddi_pua, - "SJIS-Mobile#KDDI-PUA", - "Shift_JIS", - NULL, - mblen_table_sjis, - MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE -}; - -const mbfl_encoding mbfl_encoding_sjis_kddi_pua_b = { - mbfl_no_encoding_sjis_kddi_pua_b, - "SJIS-Mobile#KDDI-PUA-B", - "Shift_JIS", - NULL, - mblen_table_sjis, - MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE -}; - -const mbfl_encoding mbfl_encoding_sjis_sb_pua = { - mbfl_no_encoding_sjis_sb_pua, - "SJIS-Mobile#SOFTBANK-PUA", - "Shift_JIS", - NULL, - mblen_table_sjis, - MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE -}; - const struct mbfl_identify_vtbl vtbl_identify_sjis_docomo = { mbfl_no_encoding_sjis_docomo, mbfl_filt_ident_common_ctor, @@ -181,78 +145,6 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb = { mbfl_filt_conv_sjis_mobile_flush }; -const struct mbfl_convert_vtbl vtbl_sjis_docomo_pua_wchar = { - mbfl_no_encoding_sjis_docomo_pua, - mbfl_no_encoding_wchar, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_sjis_mobile_wchar, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo_pua = { - mbfl_no_encoding_wchar, - mbfl_no_encoding_sjis_docomo_pua, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_wchar = { - mbfl_no_encoding_sjis_kddi_pua, - mbfl_no_encoding_wchar, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_sjis_mobile_wchar, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua = { - mbfl_no_encoding_wchar, - mbfl_no_encoding_sjis_kddi_pua, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_b_wchar = { - mbfl_no_encoding_sjis_kddi_pua_b, - mbfl_no_encoding_wchar, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_sjis_mobile_wchar, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua_b = { - mbfl_no_encoding_wchar, - mbfl_no_encoding_sjis_kddi_pua_b, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_sjis_sb_pua_wchar = { - mbfl_no_encoding_sjis_sb_pua, - mbfl_no_encoding_wchar, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_sjis_mobile_wchar, - mbfl_filt_conv_common_flush -}; - -const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua = { - mbfl_no_encoding_wchar, - mbfl_no_encoding_sjis_sb_pua, - mbfl_filt_conv_common_ctor, - mbfl_filt_conv_common_dtor, - mbfl_filt_conv_wchar_sjis_mobile, - mbfl_filt_conv_common_flush -}; - static const char nflags_s[10][2] = {"CN","DE","ES","FR","GB","IT","JP","KR","RU","US"}; static const int nflags_code_kddi[10] = {0x2549, 0x2546, 0x24c0, 0x2545, 0x2548, 0x2547, 0x2750, 0x254a, 0x24c1, 0x27f7}; static const int nflags_code_sb[10] = {0x2b0a, 0x2b05, 0x2b08, 0x2b04, 0x2b07, 0x2b06, 0x2b02, 0x2b0b, 0x2b09, 0x2b03}; @@ -293,7 +185,6 @@ const int mbfl_kddi2uni_pua_b[8][3] = { {0x27e7, 0x2863, 0xf080}, }; - #define NFLAGS(c) (0x1F1A5+(int)(c)) #define CK(statement) do { if ((statement) < 0) return (-1); } while (0) @@ -657,8 +548,7 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) switch (filter->status) { case 0: if (c >= 0 && c < 0x80) { /* latin */ - if ((filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || - filter->from->no_encoding == mbfl_no_encoding_sjis_sb) && c == 0x1b) { + if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb && c == 0x1b) { filter->cache = c; filter->status = 2; } else { @@ -720,14 +610,6 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) w = mbfilter_sjis_emoji_kddi2unicode(s, &snd); } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { w = mbfilter_sjis_emoji_sb2unicode(s, &snd); - } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi_pua) { - mbfilter_conv_map_tbl(s, &w, mbfl_kddi2uni_pua, 6); - } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b) { - mbfilter_conv_map_tbl(s, &w, mbfl_kddi2uni_pua_b, 8); - } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua) { - mbfilter_conv_map_tbl(s, &w, mbfl_sb2uni_pua, 6); - } else if (filter->from->no_encoding == mbfl_no_encoding_sjis_docomo_pua) { - mbfilter_conv_map_tbl(s, &w, mbfl_docomo2uni_pua, 4); } if (w > 0 && snd > 0) { @@ -751,8 +633,7 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) } break; case 2: - if ((filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || - filter->from->no_encoding == mbfl_no_encoding_sjis_sb) && + if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb && c == 0x24) { filter->cache = c; filter->status = 3; @@ -765,8 +646,7 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) case 3: /* Softbank Emoji: ESC $ [GEFOPQ] X 0x0f */ - if ((filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || - filter->from->no_encoding == mbfl_no_encoding_sjis_sb) && + if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb && ((c >= 0x45 && c <= 0x47) || (c >= 0x4f && c <= 0x51))) { filter->cache = c; filter->status = 4; @@ -781,8 +661,7 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) case 4: /* Softbank Emoji Web code: ESC $ [GEFOPQ] X 0x0f */ w = 0; - if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua || - filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { + if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { c1 = filter->cache; if (c == 0x0f) { @@ -790,40 +669,24 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) filter->cache = 0; filter->status = 0; } else { - if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb_pua) { - if (c1 == 0x47 && c >= 0x21 && c <= 0x7a) { - w = c - 0x0021 + 0xe001; - } else if (c1 == 0x45 && c >= 0x21 && c <= 0x7a) { - w = c - 0x0021 + 0xe101; - } else if (c1 == 0x46 && c >= 0x21 && c <= 0x7a) { - w = c - 0x0021 + 0xe201; - } else if (c1 == 0x4f && c >= 0x21 && c <= 0x6d) { - w = c - 0x0021 + 0xe301; - } else if (c1 == 0x50 && c >= 0x21 && c <= 0x6c) { - w = c - 0x0021 + 0xe401; - } else if (c1 == 0x51 && c >= 0x21 && c <= 0x5e) { - w = c - 0x0021 + 0xe501; - } - } else { - if (c1 == 0x47 && c >= 0x21 && c <= 0x7a) { - s1 = 0x91; s2 = c; - } else if (c1 == 0x45 && c >= 0x21 && c <= 0x7a) { - s1 = 0x8d; s2 = c; - } else if (c1 == 0x46 && c >= 0x21 && c <= 0x7a) { - s1 = 0x8e; s2 = c; - } else if (c1 == 0x4f && c >= 0x21 && c <= 0x6d) { - s1 = 0x92; s2 = c; - } else if (c1 == 0x50 && c >= 0x21 && c <= 0x6c) { - s1 = 0x95; s2 = c; - } else if (c1 == 0x51 && c >= 0x21 && c <= 0x5e) { - s1 = 0x96; s2 = c; - } - s = (s1 - 0x21)*94 + s2 - 0x21; - w = mbfilter_sjis_emoji_sb2unicode(s, &snd); - if (w > 0 && snd > 0) { - CK((*filter->output_function)(snd, filter->data)); - } + if (c1 == 0x47 && c >= 0x21 && c <= 0x7a) { + s1 = 0x91; s2 = c; + } else if (c1 == 0x45 && c >= 0x21 && c <= 0x7a) { + s1 = 0x8d; s2 = c; + } else if (c1 == 0x46 && c >= 0x21 && c <= 0x7a) { + s1 = 0x8e; s2 = c; + } else if (c1 == 0x4f && c >= 0x21 && c <= 0x6d) { + s1 = 0x92; s2 = c; + } else if (c1 == 0x50 && c >= 0x21 && c <= 0x6c) { + s1 = 0x95; s2 = c; + } else if (c1 == 0x51 && c >= 0x21 && c <= 0x5e) { + s1 = 0x96; s2 = c; } + s = (s1 - 0x21)*94 + s2 - 0x21; + w = mbfilter_sjis_emoji_sb2unicode(s, &snd); + if (w > 0 && snd > 0) { + CK((*filter->output_function)(snd, filter->data)); + } if (w > 0) { CK((*filter->output_function)(w, filter->data)); } @@ -953,15 +816,7 @@ mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter) (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi && mbfilter_unicode2sjis_emoji_kddi(c, &s1, filter) > 0) || (filter->to->no_encoding == mbfl_no_encoding_sjis_sb && - mbfilter_unicode2sjis_emoji_sb(c, &s1, filter) > 0 ) || - (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua && - mbfilter_conv_r_map_tbl(c, &s1, mbfl_kddi2uni_pua, 6) > 0) || - (filter->to->no_encoding == mbfl_no_encoding_sjis_docomo_pua && - mbfilter_conv_r_map_tbl(c, &s1, mbfl_docomo2uni_pua, 4) > 0) || - (filter->to->no_encoding == mbfl_no_encoding_sjis_kddi_pua_b && - mbfilter_conv_r_map_tbl(c, &s1, mbfl_kddi2uni_pua_b, 8) > 0) || - (filter->to->no_encoding == mbfl_no_encoding_sjis_sb_pua && - mbfilter_conv_r_map_tbl(c, &s1, mbfl_sb2uni_pua, 6) > 0)) { + mbfilter_unicode2sjis_emoji_sb(c, &s1, filter) > 0 )) { CODE2JIS(c1,c2,s1,s2); } diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h index 310ec7954b4da..9de8988c22858 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -35,10 +35,6 @@ extern const mbfl_encoding mbfl_encoding_sjis_docomo; extern const mbfl_encoding mbfl_encoding_sjis_kddi; extern const mbfl_encoding mbfl_encoding_sjis_sb; -extern const mbfl_encoding mbfl_encoding_sjis_docomo_pua; -extern const mbfl_encoding mbfl_encoding_sjis_kddi_pua; -extern const mbfl_encoding mbfl_encoding_sjis_kddi_pua_b; -extern const mbfl_encoding mbfl_encoding_sjis_sb_pua; extern const struct mbfl_identify_vtbl vtbl_identify_sjis_docomo; extern const struct mbfl_identify_vtbl vtbl_identify_sjis_kddi; @@ -51,15 +47,6 @@ extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi; extern const struct mbfl_convert_vtbl vtbl_sjis_sb_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb; -extern const struct mbfl_convert_vtbl vtbl_sjis_docomo_pua_wchar; -extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_docomo_pua; -extern const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_wchar; -extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua; -extern const struct mbfl_convert_vtbl vtbl_sjis_kddi_pua_b_wchar; -extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi_pua_b; -extern const struct mbfl_convert_vtbl vtbl_sjis_sb_pua_wchar; -extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb_pua; - int mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter); @@ -72,10 +59,6 @@ int mbfilter_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filt int mbfilter_unicode2sjis_emoji_kddi(int c, int *s1, mbfl_convert_filter *filter); int mbfilter_unicode2sjis_emoji_sb(int c, int *s1, mbfl_convert_filter *filter); -int mbfilter_unicode_pua2sjis_emoji_docomo( int c, int *s1, int *s2, int *c1, int *c2); -int mbfilter_unicode_pua2sjis_emoji_kddi(int c, int *s1, int *s2, int *c1, int *c2); -int mbfilter_unicode_pua2sjis_emoji(int c, int *s1, int *s2, int *c1, int *c2, int *sjis_encoded); - int mbfilter_conv_map_tbl(int c, int *w, const int map[][3], int n); int mbfilter_conv_r_map_tbl(int c, int *w, const int map[][3], int n); diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index d2d051e53edd2..f9238ceb3794a 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -144,14 +144,6 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_sjis_kddi, &vtbl_sjis_sb_wchar, &vtbl_wchar_sjis_sb, - &vtbl_sjis_docomo_pua_wchar, - &vtbl_wchar_sjis_docomo_pua, - &vtbl_sjis_kddi_pua_wchar, - &vtbl_wchar_sjis_kddi_pua, - &vtbl_sjis_kddi_pua_b_wchar, - &vtbl_wchar_sjis_kddi_pua_b, - &vtbl_sjis_sb_pua_wchar, - &vtbl_wchar_sjis_sb_pua, &vtbl_sjis_mac_wchar, &vtbl_wchar_sjis_mac, &vtbl_utf8_docomo_wchar, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index 58af1c58f0d46..31151d70ee4fb 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -167,10 +167,6 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_sjis_docomo, &mbfl_encoding_sjis_kddi, &mbfl_encoding_sjis_sb, - &mbfl_encoding_sjis_docomo_pua, - &mbfl_encoding_sjis_kddi_pua, - &mbfl_encoding_sjis_kddi_pua_b, - &mbfl_encoding_sjis_sb_pua, &mbfl_encoding_sjis_mac, &mbfl_encoding_sjis2004, &mbfl_encoding_utf8_docomo, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index 000c0a353ed48..625dd0ae2dd23 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -77,10 +77,6 @@ enum mbfl_no_encoding { mbfl_no_encoding_sjis_docomo, mbfl_no_encoding_sjis_kddi, mbfl_no_encoding_sjis_sb, - mbfl_no_encoding_sjis_docomo_pua, - mbfl_no_encoding_sjis_kddi_pua, - mbfl_no_encoding_sjis_kddi_pua_b, - mbfl_no_encoding_sjis_sb_pua, mbfl_no_encoding_sjis_mac, mbfl_no_encoding_sjis2004, mbfl_no_encoding_cp932, From e55522838e685d6bbf656d511a2c180b0745cc7f Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 20 Aug 2011 14:50:49 +0000 Subject: [PATCH 0585/2394] more code coverage --- ext/snmp/tests/generic_timeout_error.phpt | 5 +++++ ext/snmp/tests/snmp-object-errno-errstr.phpt | 2 ++ 2 files changed, 7 insertions(+) diff --git a/ext/snmp/tests/generic_timeout_error.phpt b/ext/snmp/tests/generic_timeout_error.phpt index 0f5101a43972c..c333a0d20b11f 100644 --- a/ext/snmp/tests/generic_timeout_error.phpt +++ b/ext/snmp/tests/generic_timeout_error.phpt @@ -15,8 +15,13 @@ snmp_set_quick_print(false); snmp_set_valueretrieval(SNMP_VALUE_PLAIN); var_dump(snmpget($hostname, 'timeout_community_432', '.1.3.6.1.2.1.1.1.0', $timeout, $retries)); +var_dump(snmpget($hostname, 'timeout_community_432', array('.1.3.6.1.2.1.1.1.0'), $timeout, $retries)); ?> --EXPECTF-- Warning: snmpget(): No response from %s in %s on line %d bool(false) + +Warning: snmpget(): No response from %s in %s on line %d +bool(false) + diff --git a/ext/snmp/tests/snmp-object-errno-errstr.phpt b/ext/snmp/tests/snmp-object-errno-errstr.phpt index 923fb856e07a3..427a754b08319 100644 --- a/ext/snmp/tests/snmp-object-errno-errstr.phpt +++ b/ext/snmp/tests/snmp-object-errno-errstr.phpt @@ -42,6 +42,7 @@ $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); var_dump(@$session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getErrno() == SNMP::ERRNO_GENERIC); var_dump($session->getError()); +var_dump(@$session->get(array('.1.3.6.1.2.1.1.1.0'))); $session->close(); ?> --EXPECTF-- @@ -61,3 +62,4 @@ SNMP::ERRNO_GENERIC bool(false) bool(true) %string|unicode%(%d) "Fatal error: Unknown user name" +bool(false) From 8c99efcdf011d7cf0fdf89744b13471a9fed4716 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 20 Aug 2011 15:53:44 +0000 Subject: [PATCH 0586/2394] Adding IPv6 support (FR #42918) --- ext/snmp/snmp.c | 80 +++++++++++++++++++++++++++--- ext/snmp/tests/README | 5 +- ext/snmp/tests/ipv6.phpt | 24 +++++++++ ext/snmp/tests/snmp_include.inc | 6 ++- ext/snmp/tests/wrong_hostname.phpt | 2 +- 5 files changed, 106 insertions(+), 11 deletions(-) create mode 100644 ext/snmp/tests/ipv6.phpt diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 67d6cebe36407..c0ab7f5f6afea 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -28,6 +28,7 @@ #endif #include "php.h" +#include "main/php_network.h" #include "ext/standard/info.h" #include "php_snmp.h" @@ -1090,9 +1091,13 @@ static int php_snmp_parse_oid(int st, struct objid_query *objid_query, zval **oi */ static int netsnmp_session_init(php_snmp_session **session_p, int version, char *hostname, char *community, int timeout, int retries TSRMLS_DC) { - int remote_port = SNMP_PORT; php_snmp_session *session; char *pptr; + char buf[MAX_NAME_LEN]; + int force_ipv6 = FALSE; + int n; + struct sockaddr **psal; + struct sockaddr **res; *session_p = (php_snmp_session *)emalloc(sizeof(php_snmp_session)); session = *session_p; @@ -1100,25 +1105,86 @@ static int netsnmp_session_init(php_snmp_session **session_p, int version, char php_error_docref(NULL TSRMLS_CC, E_WARNING, "emalloc() failed allocating session"); return (-1); } + memset(session, 0, sizeof(php_snmp_session)); + + strlcpy(buf, hostname, sizeof(buf)); snmp_sess_init(session); session->version = version; + session->remote_port = SNMP_PORT; session->peername = emalloc(MAX_NAME_LEN); - if(session->peername == NULL) { + if (session->peername == NULL) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "emalloc() failed while copying hostname"); - netsnmp_session_free(&session); return (-1); } + *(session->peername) = '\0'; /* Reading the hostname and its optional non-default port number */ - strlcpy(session->peername, hostname, MAX_NAME_LEN); - if ((pptr = strchr(session->peername, ':'))) { - remote_port = strtol(pptr + 1, NULL, 0); + if (*hostname == '[') { /* IPv6 address */ + force_ipv6 = TRUE; + hostname++; + if ((pptr = strchr(hostname, ']'))) { + if (pptr[1] == ':') { + session->remote_port = atoi(pptr + 2); + } + *pptr = '\0'; + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "mailformed IPv6 address, closing square bracket missing"); + return (-1); + } + } else { /* IPv4 address */ + if ((pptr = strchr(hostname, ':'))) { + session->remote_port = atoi(pptr + 1); + *pptr = '\0'; + } + } + + /* since Net-SNMP library requires 'udp6:' prefix for all IPv6 addresses (in FQDN form too) we need to + perform possible name resolution before running any SNMP queries */ + if ((n = php_network_getaddresses(hostname, SOCK_DGRAM, &psal, NULL TSRMLS_CC)) == 0) { /* some resover error */ + /* warnings sent, bailing out */ + return (-1); + } + + res = psal; + while (n-- > 0) { + pptr = session->peername; +#if HAVE_GETADDRINFO && HAVE_IPV6 && HAVE_INET_NTOP + if (force_ipv6 && (*res)->sa_family != AF_INET6) { + res++; + continue; + } + if ((*res)->sa_family == AF_INET6) { + strcpy(session->peername, "udp6:"); + pptr = session->peername + strlen(session->peername); + inet_ntop((*res)->sa_family, &(((struct sockaddr_in6*)(*res))->sin6_addr), pptr, MAX_NAME_LEN); + } else if ((*res)->sa_family == AF_INET) { + inet_ntop((*res)->sa_family, &(((struct sockaddr_in*)(*res))->sin_addr), pptr, MAX_NAME_LEN); + } else { + res++; + continue; + } +#else + if (res->sa_family != AF_INET) { + res++; + continue; + } + strcat(pptr, inet_ntoa(res)); +#endif + break; + } + + if (strlen(session->peername) == 0) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown failure while resolving '%s'", buf); + return (-1); } + /* XXX FIXME + There should be check for non-empty session->peername! + */ - session->remote_port = remote_port; + php_network_freeaddresses(psal); if (version == SNMP_VERSION_3) { /* Setting the security name. */ diff --git a/ext/snmp/tests/README b/ext/snmp/tests/README index d87d17ad1b8ba..74258ec27f279 100644 --- a/ext/snmp/tests/README +++ b/ext/snmp/tests/README @@ -9,7 +9,9 @@ To enable these tests, you must have : ** How to test ** You need to give credentials with environment vars if default ones are not sutable (see snmp_include.inc for more info): -SNMP_HOSTNAME : IP or IP:PORT to connect to +SNMP_HOSTNAME : IPv4 of remote SNMP agent +SNMP_HOSTNAME : IPv6 or remote SNMP agent +SNMP_PORT : SNMP port for queries SNMP_COMMUNITY : community name SNMP_COMMUNITY_WRITE : community used for write tests (snmpset()). SNMP_MIBDIR : Directory containing MIBS @@ -26,6 +28,7 @@ On Linux/FreeBSD ###### Config file ##### rocommunity public 127.0.0.1 +rocommunity6 public ::1 rwcommunity private 127.0.0.1 Do not enable them - being set here they make appropriate OID switch into r/o diff --git a/ext/snmp/tests/ipv6.phpt b/ext/snmp/tests/ipv6.phpt new file mode 100644 index 0000000000000..78119d1575190 --- /dev/null +++ b/ext/snmp/tests/ipv6.phpt @@ -0,0 +1,24 @@ +--TEST-- +IPv6 support +--CREDITS-- +Boris Lytochkin +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +%unicode|string%(%d) "%s" diff --git a/ext/snmp/tests/snmp_include.inc b/ext/snmp/tests/snmp_include.inc index c91499078da05..caa0721890f7f 100644 --- a/ext/snmp/tests/snmp_include.inc +++ b/ext/snmp/tests/snmp_include.inc @@ -6,9 +6,11 @@ requests and 'private' community for write requests. Default timeout is 1000ms and there will be one request performed. */ -$hostname = getenv('SNMP_HOSTNAME') ? getenv('SNMP_HOSTNAME') : '127.0.0.1'; +$hostname4 = getenv('SNMP_HOSTNAME') ? getenv('SNMP_HOSTNAME') : '127.0.0.1'; +$hostname6 = getenv('SNMP_HOSTNAME6') ? getenv('SNMP_HOSTNAME6') : '::1'; $port = getenv('SNMP_PORT') ? getenv('SNMP_PORT') : '161'; -$hostname .= ":$port"; +$hostname = "$hostname4:$port"; +$hostname6_port = "[$hostname6]:$port"; $community = getenv('SNMP_COMMUNITY') ? getenv('SNMP_COMMUNITY') : 'public'; $communityWrite = getenv('SNMP_COMMUNITY_WRITE')? getenv('SNMP_COMMUNITY_WRITE'):'private'; diff --git a/ext/snmp/tests/wrong_hostname.phpt b/ext/snmp/tests/wrong_hostname.phpt index e0bfa8a54d120..4ab087e41fc6e 100644 --- a/ext/snmp/tests/wrong_hostname.phpt +++ b/ext/snmp/tests/wrong_hostname.phpt @@ -18,5 +18,5 @@ var_dump(snmpget('192.168..6.1', 'community', '.1.3.6.1.2.1.1.1.0', $timeout, $r ?> --EXPECTF-- -Warning: snmpget(): Could not open snmp connection: Unknown host (192.168..6.1) (%s) in %s on line %d +Warning: snmpget(): php_network_getaddresses: getaddrinfo failed: hostname nor servname provided, or not known in %s on line %d bool(false) From c1b90f45f52a96b4838b53bd9af1ab3cd929d5d3 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 20 Aug 2011 20:56:02 +0000 Subject: [PATCH 0587/2394] IPv6 Support for SNMP. (FR #42918) --- NEWS | 1 + UPGRADING | 3 +++ 2 files changed, 4 insertions(+) diff --git a/NEWS b/NEWS index f139262c02edf..e7745192071ca 100644 --- a/NEWS +++ b/NEWS @@ -231,6 +231,7 @@ PHP NEWS . Allow ~infinite OIDs in GET/GETNEXT/SET queries. Autochunk them to max_oids upon request. . Introducing unit tests for extension with ~full coverage. + . IPv6 support. (FR #42918) . Way of representing OID value can now be changed when SNMP_VALUE_OBJECT is used for value output mode. Use or'ed SNMP_VALUE_LIBRARY(default if not specified) or SNMP_VALUE_PLAIN. (FR #54502) diff --git a/UPGRADING b/UPGRADING index 69a8eff903262..2739614a73a4a 100755 --- a/UPGRADING +++ b/UPGRADING @@ -302,6 +302,9 @@ UPGRADE NOTES - PHP X.Y - Added feature-rich OO API (SNMP class) - Dropped UCD-SNMP compatibility code. Consider upgrading to net-snmp v5.3+. Net-SNMP v5.4+ is required for Windows version. + - In sake of adding support for IPv6 DNS name resolution of + remote SNMP agent (peer) is done by extension now, not by Net-SNMP + library anymore. d. no longer possible to disable From 61dae0f7e3af8da1c5c71bca3f16f33a21500554 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 21 Aug 2011 02:22:53 +0000 Subject: [PATCH 0588/2394] speed improvement of jisx0213 conversion. --- .../libmbfl/filters/mbfilter_iso2022jp_2004.c | 46 +---- .../libmbfl/filters/mbfilter_sjis_2004.c | 117 ++++++++---- .../libmbfl/filters/unicode_table_jis2004.h | 178 +++++++++--------- 3 files changed, 173 insertions(+), 168 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c index fc807c5139fbb..d855374bf078e 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_2004.c @@ -39,8 +39,6 @@ #include "unicode_table_jis.h" extern int mbfl_filt_conv_any_jis_flush(mbfl_convert_filter *filter); - -static int mbfl_filt_conv_2022jp_2004_flush(mbfl_convert_filter *filter); static int mbfl_filt_ident_2022jp_2004(int c, mbfl_identify_filter *filter); const mbfl_encoding mbfl_encoding_2022jp_2004 = { @@ -74,51 +72,9 @@ const struct mbfl_convert_vtbl vtbl_wchar_2022jp_2004 = { mbfl_filt_conv_common_ctor, mbfl_filt_conv_common_dtor, mbfl_filt_conv_wchar_jis2004, - mbfl_filt_conv_2022jp_2004_flush + mbfl_filt_conv_jis2004_flush }; -#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) - -static int -mbfl_filt_conv_2022jp_2004_flush(mbfl_convert_filter *filter) -{ - int k, c1, c2, s1, s2; - - k = filter->cache; - - if ((filter->status & 0xf) == 1 && k >= 0 && k <= jisx0213_u2_tbl_len) { - s1 = jisx0213_u2_fb_tbl[k]; - c1 = (s1 >> 8) & 0x7f; - c2 = s1 & 0x7f; - - if ((filter->status & 0xff00) != 0x200) { - CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ - CK((*filter->output_function)(0x24, filter->data)); /* '$' */ - CK((*filter->output_function)(0x28, filter->data)); /* '(' */ - CK((*filter->output_function)(0x51, filter->data)); /* 'Q' */ - } - filter->status = 0x200; - CK((*filter->output_function)(c1, filter->data)); - CK((*filter->output_function)(c2, filter->data)); - } - filter->cache = 0; - - /* back to latin */ - if ((filter->status & 0xff00) != 0) { - CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ - CK((*filter->output_function)(0x28, filter->data)); /* '(' */ - CK((*filter->output_function)(0x42, filter->data)); /* 'B' */ - } - - filter->status &= 0xff; - - if (filter->flush_function != NULL) { - return (*filter->flush_function)(filter->data); - } - - return 0; -} - static int mbfl_filt_ident_2022jp_2004(int c, mbfl_identify_filter *filter) { retry: diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c index 58d8788629dfb..7cf9452f77a09 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c @@ -34,8 +34,6 @@ #include "mbfilter.h" #include "mbfilter_sjis_2004.h" -#define UNICODE_TABLE_JIS2004_DEF - #include "unicode_table_jis2004.h" #include "unicode_table_jis.h" @@ -43,20 +41,6 @@ extern const unsigned char mblen_table_sjis[]; static int mbfl_filt_ident_sjis2004(int c, mbfl_identify_filter *filter); -static const int uni2sjis_tbl_range[][2] = { - {0x0000, 0x045f}, - {0x4e00, 0x9fff}, - {0xff00, 0xffe5}, - {0xfa0f, 0xfa6a}, -}; - -static const unsigned short *uni2sjis_tbl[] = { - ucs_a1_jisx0213_table, - ucs_i_jisx0213_table, - ucs_r_jisx0213_table, - ucs_r2_jisx0213_table, -}; - extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); extern int mbfl_bisec_srch(int w, const unsigned short *tbl, int n); extern int mbfl_bisec_srch2(int w, const unsigned short tbl[], int n); @@ -236,7 +220,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) w1 = (s1 << 8) | s2; if (w1 >= 0x2121) { - + /* conversion for combining characters */ if ((w1 >= 0x2477 && w1 <= 0x2479) || (w1 >= 0x2479 && w1 <= 0x247B) || (w1 >= 0x2577 && w1 <= 0x257E) || w1 == 0x2678 || w1 == 0x2B44 || (w1 >= 0x2B48 && w1 <= 0x2B4F) || (w1 >= 0x2B65 && w1 <= 0x2B66)) { @@ -248,6 +232,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) } } + /* conversion for BMP */ if (w <= 0) { w1 = (s1 - 0x21)*94 + s2 - 0x21; if (w1 >= 0 && w1 < jisx0213_ucs_table_size) { @@ -255,6 +240,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) } } + /* conversion for CJK Unified Ideographs ext.B (U+2XXXX) */ if (w <= 0) { w1 = (s1 << 8) | s2; k = mbfl_bisec_srch2(w1, jisx0213_jis_u5_key, jisx0213_u5_tbl_len); @@ -285,7 +271,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) } break; - case 2: /* got 0x8e : EUC-JP-2004 */ + case 2: /* got 0x8e : EUC-JP-2004 kana */ filter->status = 0; if (c > 0xa0 && c < 0xe0) { w = 0xfec0 + c; @@ -300,41 +286,65 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) } break; - case 3: /* got 0x8f, X 0213 plane 2 first char : EUC-JP-2004 */ + case 3: /* X 0213 plane 2 first char : EUC-JP-2004 (0x8f), ISO-2022-JP-2004 */ if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ CK((*filter->output_function)(c, filter->data)); filter->status = 0; } else { - filter->status++; - filter->cache = c; + if (filter->from->no_encoding == mbfl_no_encoding_eucjp2004) { + s1 = c - 0x80; + } else { + s1 = c; + } + if (s1 > 0x20 && s1 < 0x80) { + filter->cache = s1; + filter->status++; + } else { + if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { + w = c | 0x8f00; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + } else { + w = c & 0x7f; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_JIS0213; + } + CK((*filter->output_function)(w, filter->data)); + } } break; - case 4: /* got 0x8f, X 0213 plane 2 second char */ + case 4: /* X 0213 plane 2 second char : EUC-JP-2004, ISO-2022-JP-2004 */ filter->status &= ~0xf; c1 = filter->cache; - c2 = c; if (filter->from->no_encoding == mbfl_no_encoding_eucjp2004) { - c1 -= 0x80; - c2 -= 0x80; + c2 = c - 0x80; + } else { + c2 = c; } s1 = c1 - 0x21; s2 = c2 - 0x21; - if (s1 >= 0 && s1 < 94 && s2 >= 0 && s2 < 94) { + if (((s1 >= 0 && s1 <= 4 && s1 != 1) || s1 == 7 || (s1 >= 11 && s1 <= 14) || + (s1 >= 77 && s1 < 94)) && s2 >= 0 && s2 < 94) { + /* calc offset from ku */ for (k = 0; k < jisx0213_p2_ofst_len; k++) { if (s1 == jisx0213_p2_ofst[k]-1) { break; } } k = k - (jisx0213_p2_ofst[k]-1); + + /* check for japanese chars in BMP */ s = (s1 + 94 + k)*94 + s2; if (s >= 0 && s < jisx0213_ucs_table_size) { w = jisx0213_ucs_table[s]; } else { w = 0; } + + /* check for japanese chars in CJK Unified Ideographs ext.B (U+2XXXX) */ if (w <= 0) { w1 = ((c1 + k + 94) << 8) | c2; k = mbfl_bisec_srch2(w1, jisx0213_jis_u5_key, jisx0213_u5_tbl_len); @@ -342,11 +352,13 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) w = jisx0213_jis_u5_tbl[k] + 0x20000; } } + if (w <= 0) { w = ((c1 & 0x7f) << 8) | (c2 & 0x7f); w &= MBFL_WCSPLANE_MASK; w |= MBFL_WCSPLANE_JIS0213; } + CK((*filter->output_function)(w, filter->data)); } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ CK((*filter->output_function)(c, filter->data)); @@ -365,7 +377,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) break; - case 5: /* X 0212 */ + case 5: /* X 0208 : ISO-2022-JP-2004 */ filter->status &= ~0xf; c1 = filter->cache; if (c > 0x20 && c < 0x7f) { @@ -382,7 +394,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(w, filter->data)); break; - /* ESC */ + /* ESC : ISO-2022-JP-2004 */ /* case 0x06: */ /* case 0x16: */ /* case 0x26: */ @@ -401,7 +413,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) } break; - /* ESC $ */ + /* ESC $ : ISO-2022-JP-2004 */ /* case 0x07: */ /* case 0x17: */ /* case 0x27: */ @@ -423,7 +435,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) break; - /* ESC $ ( */ + /* ESC $ ( : ISO-2022-JP-2004 */ /* case 0x08: */ /* case 0x18: */ /* case 0x28: */ @@ -444,7 +456,7 @@ mbfl_filt_conv_jis2004_wchar(int c, mbfl_convert_filter *filter) } break; - /* ESC ( */ + /* ESC ( : ISO-2022-JP-2004 */ /* case 0x09: */ /* case 0x19: */ /* case 0x29: */ @@ -476,8 +488,13 @@ mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { retry: - if ((filter->status & 0xf)== 0 && ( c == 0x00E6 || - (c >= 0x0254 && c <= 0x02E9) || (c >= 0x304B && c <= 0x31F7))) { + /* check for 1st char of combining characters */ + if ((filter->status & 0xf)== 0 && ( + c == 0x00E6 || + (c >= 0x0254 && c <= 0x02E9) || + (c >= 0x304B && c <= 0x3053) || + (c >= 0x30AB && c <= 0x30C8) || + c == 0x31F7)) { for (k=0;kstatus++; @@ -487,6 +504,7 @@ mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { } } + /* check for 2nd char of combining characters */ if ((filter->status & 0xf) == 1 && filter->cache >= 0 && filter->cache <= jisx0213_u2_tbl_len) { k = filter->cache; @@ -529,23 +547,26 @@ mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { } } + /* check for major japanese chars */ if (s1 <= 0) { - for (k=0; k= uni2sjis_tbl_range[k][0] && c <= uni2sjis_tbl_range[k][1]) { - s1 = uni2sjis_tbl[k][c-uni2sjis_tbl_range[k][0]]; + for (k=0; k < uni2jis_tbl_len ;k++) { + if (c >= uni2jis_tbl_range[k][0] && c <= uni2jis_tbl_range[k][1]) { + s1 = uni2jis_tbl[k][c-uni2jis_tbl_range[k][0]]; break; } } } - if (c >= ucs_c1_jisx0213_min && c <= ucs_c1_jisx0213_max) { + /* check for japanese chars in compressed area */ + if (s1 <= 0 && c >= ucs_c1_jisx0213_min && c <= ucs_c1_jisx0213_max) { k = mbfl_bisec_srch(c, ucs_c1_jisx0213_tbl, ucs_c1_jisx0213_tbl_len); if (k >= 0) { s1 = ucs_c1_jisx0213_ofst[k] + c - ucs_c1_jisx0213_tbl[2*k]; } } - if (c >= jisx0213_u5_tbl_min && c <= jisx0213_u5_tbl_max) { + /* check for japanese chars in CJK Unified Ideographs ext.B (U+2XXXX) */ + if (s1 <= 0 && c >= jisx0213_u5_tbl_min && c <= jisx0213_u5_tbl_max) { k = mbfl_bisec_srch2(c - 0x20000, jisx0213_u5_jis_key, jisx0213_u5_tbl_len); if (k >= 0) { s1 = jisx0213_u5_jis_tbl[k]; @@ -649,6 +670,7 @@ mbfl_filt_conv_jis2004_flush(mbfl_convert_filter *filter) int k, c1, c2, s1, s2; k = filter->cache; + filter->cache = 0; if (filter->status == 1 && k >= 0 && k <= jisx0213_u2_tbl_len) { s1 = jisx0213_u2_fb_tbl[k]; @@ -660,12 +682,29 @@ mbfl_filt_conv_jis2004_flush(mbfl_convert_filter *filter) } else if (filter->to->no_encoding == mbfl_no_encoding_eucjp2004) { s2 = (s1 & 0xff) | 0x80; s1 = ((s1 >> 8) & 0xff) | 0x80; + } else { + s2 = s1 & 0x7f; + s1 = (s1 >> 8) & 0x7f; + if ((filter->status & 0xff00) != 0x200) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x24, filter->data)); /* '$' */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x51, filter->data)); /* 'Q' */ + } + filter->status = 0x200; } CK((*filter->output_function)(s1, filter->data)); CK((*filter->output_function)(s2, filter->data)); } - filter->cache = 0; + + /* back to latin */ + if ((filter->status & 0xff00) != 0) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x42, filter->data)); /* 'B' */ + } + filter->status = 0; if (filter->flush_function != NULL) { diff --git a/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h b/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h index ddb161e79b51f..0039a6f92dfcc 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h @@ -24,13 +24,11 @@ #ifndef UNICODE_TABLE_JIS2004_H #define UNICODE_TABLE_JIS2004_H -#ifdef UNICODE_TABLE_JIS2004_DEF - /* * Unicode table */ -const unsigned short jisx0213_ucs_table[] = { // 0x0000 - 0x2C0F +static const unsigned short jisx0213_ucs_table[] = { // 0x0000 - 0x2C0F /* plane 1 ku 1 */ 0x3000,0x3001,0x3002,0xFF0C,0xFF0E,0x30FB,0xFF1A,0xFF1B, @@ -1593,10 +1591,10 @@ const unsigned short jisx0213_ucs_table[] = { // 0x0000 - 0x2C0F 0x9F69,0x0000,0x9F6D,0x9F70,0x9F75,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,}; -const int jisx0213_ucs_table_size = (sizeof(jisx0213_ucs_table)/sizeof(unsigned short)); +static const int jisx0213_ucs_table_size = (sizeof(jisx0213_ucs_table)/sizeof(unsigned short)); -const unsigned short ucs_a1_jisx0213_table[] = { // 0x0000 - 0x045f +static const unsigned short ucs_a1_jisx0213_table[] = { // 0x0000 - 0x045f /* 0000h */ 0x0000,0x0001,0x0002,0x0003,0x0004,0x0005,0x0006,0x0007, @@ -1749,11 +1747,50 @@ const unsigned short ucs_a1_jisx0213_table[] = { // 0x0000 - 0x045f 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, }; -const int ucs_a1_jisx0213_table_min = 0x0000; -const int ucs_a1_jisx0213_table_max = 0x0000 + +static const int ucs_a1_jisx0213_table_min = 0x0000; +static const int ucs_a1_jisx0213_table_max = 0x0000 + (sizeof(ucs_a1_jisx0213_table)/sizeof(unsigned short)); -const unsigned short ucs_i_jisx0213_table[] = { // 0x4e00 - 0x9fff +static const unsigned short ucs_hk_jisx0213_table[] = { // 0x3000 - 0x30ff +/* 3000h */ +0x2121,0x2122,0x2123,0x2137,0x0000,0x2139,0x213A,0x213B, +0x2152,0x2153,0x2154,0x2155,0x2156,0x2157,0x2158,0x2159, +0x215A,0x215B,0x2229,0x222E,0x214C,0x214D,0x225A,0x225B, +0x2258,0x2259,0x0000,0x0000,0x2141,0x2D60,0x0000,0x2D61, +0x2666,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2233,0x2234,0x2235,0x0000,0x0000, +0x0000,0x0000,0x0000,0x2236,0x2237,0x233C,0x0000,0x0000, +0x0000,0x2421,0x2422,0x2423,0x2424,0x2425,0x2426,0x2427, +0x2428,0x2429,0x242A,0x242B,0x242C,0x242D,0x242E,0x242F, +0x2430,0x2431,0x2432,0x2433,0x2434,0x2435,0x2436,0x2437, +0x2438,0x2439,0x243A,0x243B,0x243C,0x243D,0x243E,0x243F, +0x2440,0x2441,0x2442,0x2443,0x2444,0x2445,0x2446,0x2447, +0x2448,0x2449,0x244A,0x244B,0x244C,0x244D,0x244E,0x244F, +0x2450,0x2451,0x2452,0x2453,0x2454,0x2455,0x2456,0x2457, +0x2458,0x2459,0x245A,0x245B,0x245C,0x245D,0x245E,0x245F, +0x2460,0x2461,0x2462,0x2463,0x2464,0x2465,0x2466,0x2467, +0x2468,0x2469,0x246A,0x246B,0x246C,0x246D,0x246E,0x246F, +0x2470,0x2471,0x2472,0x2473,0x2474,0x2475,0x2476,0x0000, +0x0000,0x0000,0x0000,0x212B,0x212C,0x2135,0x2136,0x2239, +0x237B,0x2521,0x2522,0x2523,0x2524,0x2525,0x2526,0x2527, +0x2528,0x2529,0x252A,0x252B,0x252C,0x252D,0x252E,0x252F, +0x2530,0x2531,0x2532,0x2533,0x2534,0x2535,0x2536,0x2537, +0x2538,0x2539,0x253A,0x253B,0x253C,0x253D,0x253E,0x253F, +0x2540,0x2541,0x2542,0x2543,0x2544,0x2545,0x2546,0x2547, +0x2548,0x2549,0x254A,0x254B,0x254C,0x254D,0x254E,0x254F, +0x2550,0x2551,0x2552,0x2553,0x2554,0x2555,0x2556,0x2557, +0x2558,0x2559,0x255A,0x255B,0x255C,0x255D,0x255E,0x255F, +0x2560,0x2561,0x2562,0x2563,0x2564,0x2565,0x2566,0x2567, +0x2568,0x2569,0x256A,0x256B,0x256C,0x256D,0x256E,0x256F, +0x2570,0x2571,0x2572,0x2573,0x2574,0x2575,0x2576,0x2772, +0x2773,0x2774,0x2775,0x2126,0x213C,0x2133,0x2134,0x2238, +}; + +static const int ucs_hk_jisx0213_min = 0x3000; +static const int ucs_hk_jisx0213_max = 0x30FF; + +static const unsigned short ucs_i_jisx0213_table[] = { // 0x4e00 - 0x9fff /* 4E00h */ 0x306C,0x437A,0x7F22,0x3C37,0x0000,0x0000,0x0000,0x4B7C, @@ -4544,11 +4581,11 @@ const unsigned short ucs_i_jisx0213_table[] = { // 0x4e00 - 0x9fff 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, }; -const int ucs_i_jisx0213_table_min = 0x4E00; -const int ucs_i_jisx0213_table_max = 0x4E00 + (sizeof(ucs_i_jisx0213_table)/ +static const int ucs_i_jisx0213_table_min = 0x4E00; +static const int ucs_i_jisx0213_table_max = 0x4E00 + (sizeof(ucs_i_jisx0213_table)/ sizeof(unsigned short)); -const unsigned short ucs_r_jisx0213_table[] = { // 0xff00 - 0xffe5 +static const unsigned short ucs_r_jisx0213_table[] = { // 0xff00 - 0xffe5 /* FF00h */ 0x0000,0x212A,0x2230,0x2174,0x2170,0x2173,0x2175,0x222F, @@ -4581,11 +4618,11 @@ const unsigned short ucs_r_jisx0213_table[] = { // 0xff00 - 0xffe5 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, 0x0000,0x0000,0x0000,0x2131,0x0000,0x216F,}; -const int ucs_r_jisx0213_table_min = 0xFF00; -const int ucs_r_jisx0213_table_max = 0xFF00 + (sizeof(ucs_r_jisx0213_table)/ - sizeof(unsigned short)); +static const int ucs_r_jisx0213_table_min = 0xFF00; +static const int ucs_r_jisx0213_table_max = 0xFF00 + (sizeof(ucs_r_jisx0213_table)/ + sizeof(unsigned short)); -const unsigned short ucs_r2_jisx0213_table[] = { // 0xfa0f - 0xfa6a +static const unsigned short ucs_r2_jisx0213_table[] = { // 0xfa0f - 0xfa6a 0x2F4B, 0x2F57,0x4F72,0x0000,0x8679,0x757A,0x775A,0x776F,0x0000, 0x0000,0x793C,0x793D,0x7941,0x0000,0x0000,0x0000,0x7B3A, @@ -4600,10 +4637,10 @@ const unsigned short ucs_r2_jisx0213_table[] = { // 0xfa0f - 0xfa6a 0x7B6F,0x7B79,0x7C2F,0x7C30,0x7C38,0x7C3D,0x9369,0x7C59, 0x7D63,0x7D76,0x7D7B,}; -const int ucs_r2_jisx0213_min = 0xFA0F; -const int ucs_r2_jisx0213_max = 0xFA6A; +static const int ucs_r2_jisx0213_min = 0xFA0F; +static const int ucs_r2_jisx0213_max = 0xFA6A; -const unsigned short ucs_c1_jisx0213_tbl[] = { +static const unsigned short ucs_c1_jisx0213_tbl[] = { // 0x1e00 - 0x4dff 0x1E3E,0x1E3F,0x1F70,0x1F71,0x1F72,0x1F73,0x2010,0x2010, 0x2013,0x2013,0x2014,0x2014,0x2016,0x2016,0x2018,0x2019, @@ -4709,7 +4746,7 @@ const unsigned short ucs_c1_jisx0213_tbl[] = { 0x4C20,0x4C20,0x4CC4,0x4CC4,0x4CD1,0x4CD1,0x4D07,0x4D07, 0x4D77,0x4D77,}; -const unsigned short ucs_c1_jisx0213_ofst[] = { +static const unsigned short ucs_c1_jisx0213_ofst[] = { 0x2872,0x2B46,0x2B50,0x213E,0x237C,0x213D,0x2142,0x2146, 0x2148,0x2277,0x2340,0x2145,0x2144,0x2273,0x216C,0x2228, 0x286B,0x007E,0x2B58,0x2C7E,0x286C,0x2C7D,0x2921,0x216E, @@ -4763,12 +4800,13 @@ const unsigned short ucs_c1_jisx0213_ofst[] = { 0x9728,0x972A,0x9731,0x7E3E,0x973F,0x982A,0x982D,0x984B, 0x9860,}; -const int ucs_c1_jisx0213_tbl_len = sizeof(ucs_c1_jisx0213_ofst)/sizeof(unsigned short); +static const int ucs_c1_jisx0213_tbl_len = sizeof(ucs_c1_jisx0213_ofst)/sizeof(unsigned short); -const int ucs_c1_jisx0213_min = 0x1E00; -const int ucs_c1_jisx0213_max = 0x4DFF; +static const int ucs_c1_jisx0213_min = 0x1E00; +static const int ucs_c1_jisx0213_max = 0x4DFF; -const unsigned short jisx0213_jis_u5_tbl[] = { +/* CJK Unified ideographs Extension B: U+2XXXX */ +static const unsigned short jisx0213_jis_u5_tbl[] = { 0x000B,0x123D,0x131B,0x146E,0x18BD,0x0B9F,0x16B4,0x1E34, 0x31C4,0x35C4,0x373F,0x3763,0x3CFE,0x47F1,0x548E,0x550E, 0x5771,0x59C4,0x5DA1,0x6AFF,0x6E40,0x70F4,0x7684,0x8277, @@ -4808,7 +4846,7 @@ const unsigned short jisx0213_jis_u5_tbl[] = { 0x9EC4,0x9EE9,0x9EDB,0x9FCE,0xA02F,0xA01A,0xA0F9,0xA082, 0x2218,0xA38C,0xA437,0xA5F1,0xA602,0xA61A,0xA6B2,}; -const unsigned short jisx0213_jis_u5_key[] = { +static const unsigned short jisx0213_jis_u5_key[] = { 0x2E22,0x2F42,0x2F4C,0x2F60,0x2F7B,0x4F54,0x4F63,0x4F6E, 0x753A,0x7572,0x7629,0x7632,0x7660,0x776C,0x787E,0x7929, 0x7947,0x7954,0x796E,0x7A5D,0x7B33,0x7B49,0x7B6C,0x7C49, @@ -4848,7 +4886,7 @@ const unsigned short jisx0213_jis_u5_key[] = { 0x9767,0x976D,0x9770,0x9825,0x9829,0x982B,0x9832,0x9835, 0x9853,0x9858,0x985A,0x986E,0x9870,0x9872,0x9876,}; -const unsigned short jisx0213_u5_jis_tbl[] = { +static const unsigned short jisx0213_u5_jis_tbl[] = { 0x2E22,0x7F21,0x7F2B,0x7F2E,0x7F36,0x7F46,0x7F70,0x7F79, 0x7F77,0x8122,0x8125,0x8127,0x8131,0x8132,0x8138,0x813F, 0x8141,0x814A,0x8152,0x8153,0x8159,0x815C,0x4F54,0x8177, @@ -4888,7 +4926,7 @@ const unsigned short jisx0213_u5_jis_tbl[] = { 0x9767,0x9770,0x976D,0x9825,0x982B,0x9829,0x9835,0x9832, 0x7E66,0x9858,0x985A,0x986E,0x9870,0x9872,0x9876,}; -const unsigned short jisx0213_u5_jis_key[] = { +static const unsigned short jisx0213_u5_jis_key[] = { 0x000B,0x0089,0x00A2,0x00A4,0x01A2,0x0213,0x032B,0x0371, 0x0381,0x03F9,0x044A,0x0509,0x05D6,0x0628,0x074F,0x0807, 0x083A,0x08B9,0x097C,0x099D,0x0AD3,0x0B1D,0x0B9F,0x0D45, @@ -4928,17 +4966,17 @@ const unsigned short jisx0213_u5_jis_key[] = { 0x9EC4,0x9EDB,0x9EE9,0x9FCE,0xA01A,0xA02F,0xA082,0xA0F9, 0xA190,0xA38C,0xA437,0xA5F1,0xA602,0xA61A,0xA6B2,}; -const int jisx0213_u5_tbl_min = 0x2000B; -const int jisx0213_u5_tbl_max = 0x2A6B2; -const int jisx0213_u5_tbl_len = sizeof(jisx0213_u5_jis_key)/sizeof(unsigned short); +static const int jisx0213_u5_tbl_min = 0x2000B; +static const int jisx0213_u5_tbl_max = 0x2A6B2; +static const int jisx0213_u5_tbl_len = sizeof(jisx0213_u5_jis_key)/sizeof(unsigned short); -const unsigned short jisx0213_u2_key[] = { +static const unsigned short jisx0213_u2_key[] = { 0x2477,0x2478,0x2479,0x247A,0x247B,0x2577,0x2578,0x2579, 0x257A,0x257B,0x257C,0x257D,0x257E,0x2678,0x2B44,0x2B48, 0x2B49,0x2B4A,0x2B4B,0x2B4C,0x2B4D,0x2B4E,0x2B4F,0x2B65, 0x2B66}; -const unsigned short jisx0213_u2_tbl[] = { +static const unsigned short jisx0213_u2_tbl[] = { 0x304B,0x309A,0x304D,0x309A,0x304F,0x309A,0x3051,0x309A, 0x3053,0x309A,0x30AB,0x309A,0x30AD,0x309A,0x30AF,0x309A, 0x30B1,0x309A,0x30B3,0x309A,0x30BB,0x309A,0x30C4,0x309A, @@ -4947,80 +4985,52 @@ const unsigned short jisx0213_u2_tbl[] = { 0x0259,0x0301,0x025A,0x0300,0x025A,0x0301,0x02E9,0x02E5, 0x02E5,0x02E9}; -const unsigned short jisx0213_u2_fb_tbl[] = { +static const unsigned short jisx0213_u2_fb_tbl[] = { 0x242B,0x242D,0x242F,0x2431,0x2433,0x252B,0x252D,0x252F, 0x2531,0x2533,0x253B,0x2544,0x2548,0x2675,0x295C,0x2B38, 0x2B38,0x2B37,0x2B37,0x2B30,0x2B30,0x2B43,0x2B43,0x2B64, 0x2B60}; -const int jisx0213_u2_tbl_len = sizeof(jisx0213_u2_key)/sizeof(unsigned short); +static const int jisx0213_u2_tbl_len = sizeof(jisx0213_u2_key)/sizeof(unsigned short); -const unsigned short jisx0213_uni2sjis_cmap_key[] = { +static const unsigned short jisx0213_uni2sjis_cmap_key[] = { 0xf91d,0xf928,0xf929,0xf936,0xf970,0xf9d0,0xf9dc, 0xfe45,0xfe46,0xffe5, }; -const unsigned short jisx0213_uni2sjis_cmap_val[] = { +static const unsigned short jisx0213_uni2sjis_cmap_val[] = { 0x763b,0x742e,0x754e,0x7b4f,0x7649,0x7e24,0x7d5d, 0x233e,0x233d,0x216f, }; -const int jisx0213_uni2sjis_cmap_len = +static const int jisx0213_uni2sjis_cmap_len = sizeof(jisx0213_uni2sjis_cmap_key)/sizeof(unsigned short); -const unsigned short jisx0213_p2_ofst[] = { +static const unsigned short jisx0213_p2_ofst[] = { 1, 8, 3, 4, 5, 12, 13, 14, 15, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94}; -const int jisx0213_p2_ofst_len = +static const int jisx0213_p2_ofst_len = sizeof(jisx0213_p2_ofst)/sizeof(unsigned short); -#else - -extern const unsigned short jisx0213_ucs_table[]; -extern const unsigned short ucs_a1_jisx0213_table[]; -extern const unsigned short ucs_i_jisx0213_table[]; -extern const unsigned short ucs_r_jisx0213_table[]; -extern const unsigned short ucs_r2_jisx0213_table[]; - -extern const unsigned short ucs_c1_jisx0213_table[]; -extern const unsigned short ucs_c1_jisx0213_ofst[]; -extern const unsigned short jisx0213_jis_u5_tbl[]; -extern const unsigned short jisx0213_jis_u5_key[]; -extern const unsigned short jisx0213_u5_jis_tbl[]; -extern const unsigned short jisx0213_u5_jis_key[]; -extern const unsigned short jisx0213_u2_key[]; -extern const unsigned short jisx0213_u2_tbl[]; -extern const unsigned short jisx0213_u2_fb_tbl[]; -extern const unsigned short jisx0213_uni2sjis_cmap_key[]; -extern const unsigned short jisx0213_uni2sjis_cmap_val[]; - -extern const int jisx0213_ucs_table_size; -extern const int ucs_a1_jisx0213_table_min; -extern const int ucs_a1_jisx0213_table_max; -extern const int ucs_i_jisx0213_table_min; -extern const int ucs_i_jisx0213_table_max; -extern int ucs_r_jisx0213_table_min; -extern int ucs_r_jisx0213_table_max; -extern int ucs_r2_jisx0213_table_min; -extern int ucs_r2_jisx0213_table_max; - -extern const int ucs_c1_jisx0213_tbl_len; -extern const int jisx0213_u5_tbl_min; -extern const int jisx0213_u5_tbl_max; -extern const int jisx0213_u5_tbl_len; -extern const int jisx0213_u2_tbl_len; -extern const int jisx0213_uni2sjis_cmap_len; - -extern const unsigned short ucs_c1_jisx0213_tbl[]; - -extern const int ucs_c1_jisx0213_min; -extern const int ucs_c1_jisx0213_max; - -extern const unsigned short jisx0213_p2_ofst[]; -extern const int jisx0213_p2_ofst_len; - -#endif /* UNICODE_TABLE_JIS2004_DEF */ +static const int uni2jis_tbl_range[][2] = { + {0x0000, 0x045f}, + {0x3000, 0x30ff}, + {0x4e00, 0x9fff}, + {0xff00, 0xffe5}, + {0xfa0f, 0xfa6a}, +}; + +static const unsigned short *uni2jis_tbl[] = { + ucs_a1_jisx0213_table, + ucs_hk_jisx0213_table, + ucs_i_jisx0213_table, + ucs_r_jisx0213_table, + ucs_r2_jisx0213_table, +}; + +static const int uni2jis_tbl_len = sizeof(uni2jis_tbl_range)/(sizeof(int)*2); + #endif /* UNICODE_TABLE_JIS2004_H */ From a56532a4aefaa9ad9b6325cf126904d791233239 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 21 Aug 2011 05:02:21 +0000 Subject: [PATCH 0589/2394] cleanup jisx0213 table. --- .../libmbfl/filters/mbfilter_sjis_2004.c | 24 +++++--- .../libmbfl/filters/unicode_table_jis2004.h | 61 ++++++++++++++----- 2 files changed, 63 insertions(+), 22 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c index 7cf9452f77a09..4e1838f0601c5 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_2004.c @@ -547,7 +547,7 @@ mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { } } - /* check for major japanese chars */ + /* check for major japanese chars: U+4E00 - U+9FFF */ if (s1 <= 0) { for (k=0; k < uni2jis_tbl_len ;k++) { if (c >= uni2jis_tbl_range[k][0] && c <= uni2jis_tbl_range[k][1]) { @@ -557,7 +557,7 @@ mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { } } - /* check for japanese chars in compressed area */ + /* check for japanese chars in compressed mapping area: U+1E00 - U+4DBF */ if (s1 <= 0 && c >= ucs_c1_jisx0213_min && c <= ucs_c1_jisx0213_max) { k = mbfl_bisec_srch(c, ucs_c1_jisx0213_tbl, ucs_c1_jisx0213_tbl_len); if (k >= 0) { @@ -573,15 +573,25 @@ mbfl_filt_conv_wchar_jis2004(int c, mbfl_convert_filter *filter) { } } + if (s1 <= 0) { + /* CJK Compatibility Forms: U+FE30 - U+FE4F */ + if (c == 0xfe45) { + s1 = 0x233e; + } else if (c == 0xfe46) { + s1 = 0x233d; + } else if (c >= 0xf91d && c <= 0xf9dc) { + /* CJK Compatibility Ideographs: U+F900 - U+F92A */ + k = mbfl_bisec_srch2(c, ucs_r2b_jisx0213_cmap_key, ucs_r2b_jisx0213_cmap_len); + if (k >= 0) { + s1 = ucs_r2b_jisx0213_cmap_val[k]; + } + } + } + if (s1 <= 0) { c1 = c & ~MBFL_WCSPLANE_MASK; if (c1 == MBFL_WCSPLANE_JIS0213) { s1 = c & MBFL_WCSPLANE_MASK; - } else { - k = mbfl_bisec_srch2(c, jisx0213_uni2sjis_cmap_key, jisx0213_uni2sjis_cmap_len); - if (k >= 0) { - s1 = jisx0213_uni2sjis_cmap_val[k]; - } } if (c == 0) { s1 = 0; diff --git a/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h b/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h index 0039a6f92dfcc..5ae282e91ba44 100644 --- a/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h +++ b/ext/mbstring/libmbfl/filters/unicode_table_jis2004.h @@ -4585,6 +4585,7 @@ static const int ucs_i_jisx0213_table_min = 0x4E00; static const int ucs_i_jisx0213_table_max = 0x4E00 + (sizeof(ucs_i_jisx0213_table)/ sizeof(unsigned short)); +/* Halfwidth and Fullwidth Forms */ static const unsigned short ucs_r_jisx0213_table[] = { // 0xff00 - 0xffe5 /* FF00h */ @@ -4622,6 +4623,7 @@ static const int ucs_r_jisx0213_table_min = 0xFF00; static const int ucs_r_jisx0213_table_max = 0xFF00 + (sizeof(ucs_r_jisx0213_table)/ sizeof(unsigned short)); +/* CJK Compatibility Ideographs : U+F900 - U+FAFF */ static const unsigned short ucs_r2_jisx0213_table[] = { // 0xfa0f - 0xfa6a 0x2F4B, 0x2F57,0x4F72,0x0000,0x8679,0x757A,0x775A,0x776F,0x0000, @@ -4640,8 +4642,47 @@ static const unsigned short ucs_r2_jisx0213_table[] = { // 0xfa0f - 0xfa6a static const int ucs_r2_jisx0213_min = 0xFA0F; static const int ucs_r2_jisx0213_max = 0xFA6A; -static const unsigned short ucs_c1_jisx0213_tbl[] = { - // 0x1e00 - 0x4dff +/* + CJK Compatibility Ideographs: U+F900 - U+FAFF (seperate mapping for U+F9XX) +*/ +static const unsigned short ucs_r2b_jisx0213_cmap_key[] = { + 0xf91d,0xf928,0xf929,0xf936,0xf970,0xf9d0,0xf9dc}; + +static const unsigned short ucs_r2b_jisx0213_cmap_val[] = { + 0x763b,0x742e,0x754e,0x7b4f,0x7649,0x7e24,0x7d5d}; + +static const int ucs_r2b_jisx0213_cmap_len = + sizeof(ucs_r2b_jisx0213_cmap_key)/sizeof(unsigned short); + +/* + U+1E00 - U+4DBF in compresed mapping + + Latin Extended Additional: U+1E00 - U+1EFF + Greek Extended: U+1F00 - U+1FFF + General Punctuation: U+2000 - U+206F + Currency Symbols U+20A0 - U+20CF + Combining Diacritical Marks for Symbols: U+20D0 - 20FF + Number Forms: U+2150 - U+218F + Arrow : U+2190 - U+21FF + Mathematical Operations : U+2200 - U+22FF + Miscellaneous Technical : U+2300 - U+23FF + Enclosed Alphanumerics : U+2460 - U+24FF + Box Drawing: U+2500 - U+257F + Geometric Shapes: U+25A0 - U+25FF + Miscellanuous Symbols : U+2600 - U+26FF + Digbats : U+2700 - U+27BF + Supplemental Arrows-B: U+2900 - U+297F + Miscellaneous Mathematical Symbols-B: U+2980 - U+29FF + CJK Symbols and Punctution: U+3000 - U+303F + Hiragana (*1) : U+3040 - U+309F + Katakana (*1): U+30A0 - U+30FF + CJK Strokes: U+31C0-31EF + Katakana Phonetic Extensions : U+31F0 - U+31FF + CJK Unified Ideographs Extension A: U+3400 - U+4DBF + + *1 U+3000 - U+30FF is also defined in ucs_hk to optimize for speed. + */ +static const unsigned short ucs_c1_jisx0213_tbl[] = { // 0x1e00 - 0x4dff 0x1E3E,0x1E3F,0x1F70,0x1F71,0x1F72,0x1F73,0x2010,0x2010, 0x2013,0x2013,0x2014,0x2014,0x2016,0x2016,0x2018,0x2019, 0x201C,0x201D,0x2020,0x2021,0x2022,0x2022,0x2025,0x2025, @@ -4970,12 +5011,14 @@ static const int jisx0213_u5_tbl_min = 0x2000B; static const int jisx0213_u5_tbl_max = 0x2A6B2; static const int jisx0213_u5_tbl_len = sizeof(jisx0213_u5_jis_key)/sizeof(unsigned short); +/* combined chars in JIS X 0213 */ static const unsigned short jisx0213_u2_key[] = { 0x2477,0x2478,0x2479,0x247A,0x247B,0x2577,0x2578,0x2579, 0x257A,0x257B,0x257C,0x257D,0x257E,0x2678,0x2B44,0x2B48, 0x2B49,0x2B4A,0x2B4B,0x2B4C,0x2B4D,0x2B4E,0x2B4F,0x2B65, 0x2B66}; +/* combined pairs in Unicode */ static const unsigned short jisx0213_u2_tbl[] = { 0x304B,0x309A,0x304D,0x309A,0x304F,0x309A,0x3051,0x309A, 0x3053,0x309A,0x30AB,0x309A,0x30AD,0x309A,0x30AF,0x309A, @@ -4985,6 +5028,7 @@ static const unsigned short jisx0213_u2_tbl[] = { 0x0259,0x0301,0x025A,0x0300,0x025A,0x0301,0x02E9,0x02E5, 0x02E5,0x02E9}; +/* fallback chars for combined chars in Unicode */ static const unsigned short jisx0213_u2_fb_tbl[] = { 0x242B,0x242D,0x242F,0x2431,0x2433,0x252B,0x252D,0x252F, 0x2531,0x2533,0x253B,0x2544,0x2548,0x2675,0x295C,0x2B38, @@ -4993,19 +5037,6 @@ static const unsigned short jisx0213_u2_fb_tbl[] = { static const int jisx0213_u2_tbl_len = sizeof(jisx0213_u2_key)/sizeof(unsigned short); -static const unsigned short jisx0213_uni2sjis_cmap_key[] = { - 0xf91d,0xf928,0xf929,0xf936,0xf970,0xf9d0,0xf9dc, - 0xfe45,0xfe46,0xffe5, -}; - -static const unsigned short jisx0213_uni2sjis_cmap_val[] = { - 0x763b,0x742e,0x754e,0x7b4f,0x7649,0x7e24,0x7d5d, - 0x233e,0x233d,0x216f, -}; - -static const int jisx0213_uni2sjis_cmap_len = - sizeof(jisx0213_uni2sjis_cmap_key)/sizeof(unsigned short); - static const unsigned short jisx0213_p2_ofst[] = { 1, 8, 3, 4, 5, 12, 13, 14, 15, 78, 79, 80, 81, 82, From 9770f6041a92a195c55a6b5d68c7c22982217c2e Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 21 Aug 2011 11:51:00 +0000 Subject: [PATCH 0590/2394] - Fix bug #55471, fix zts build with dtrace (Laruense) --- Zend/zend_exceptions.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Zend/zend_exceptions.c b/Zend/zend_exceptions.c index 8db4c7633d7da..1ec8eece4ac81 100644 --- a/Zend/zend_exceptions.c +++ b/Zend/zend_exceptions.c @@ -89,7 +89,8 @@ void zend_throw_exception_internal(zval *exception TSRMLS_DC) /* {{{ */ int name_len; if (exception != NULL) { - zend_get_object_classname(exception, &classname, &name_len); + zend_get_object_classname(exception, &classname, &name_len TSRMLS_CC); + DTRACE_EXCEPTION_THROWN(classname); } else { DTRACE_EXCEPTION_THROWN(NULL); From 1429b430b5b2d8c2308a6ee66d5bf9b82d7e938b Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 21 Aug 2011 12:24:19 +0000 Subject: [PATCH 0591/2394] update NEWS. --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index e7745192071ca..9f2506b9461e2 100644 --- a/NEWS +++ b/NEWS @@ -247,5 +247,6 @@ PHP NEWS - Fixed PDO objects binary incompatibility. (Dmitry) - Fixed bug #52211 (iconv() returns part of string on error). (Felipe) - Fixed bug #55450 (Built in web server not accepting file uploads). (Laruence) +- Fixed bug #55471 (ZTS build broken with dtrace). (Laruence) <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From 7fbf19566d7f8c97d33b17de2f1920b2cfb42872 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sun, 21 Aug 2011 22:57:13 +0000 Subject: [PATCH 0592/2394] Debian/Ubuntu don't have any special CFLAGS listed here for gssapi which shouldn't break the build. --- acinclude.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/acinclude.m4 b/acinclude.m4 index 89d6c6f27b2ff..528278c1cb7a2 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2271,7 +2271,7 @@ AC_DEFUN([PHP_SETUP_KERBEROS],[ KERBEROS_LIBS=`$KRB5_CONFIG --libs gssapi` KERBEROS_CFLAGS=`$KRB5_CONFIG --cflags gssapi` - if test -n "$KERBEROS_LIBS" && test -n "$KERBEROS_CFLAGS"; then + if test -n "$KERBEROS_LIBS"; then found_kerberos=yes PHP_EVAL_LIBLINE($KERBEROS_LIBS, $1) PHP_EVAL_INCLINE($KERBEROS_CFLAGS) From 60dd9e0bd9c20988a64d1c5024d10840f5822dac Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 22 Aug 2011 07:39:09 +0000 Subject: [PATCH 0593/2394] - fix typo & build --- ext/mbstring/config.w32 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/config.w32 b/ext/mbstring/config.w32 index cf796b639c2ca..ddeb00d61b0a2 100644 --- a/ext/mbstring/config.w32 +++ b/ext/mbstring/config.w32 @@ -29,7 +29,7 @@ if (PHP_MBSTRING != "no") { mbfilter_iso8859_2.c mbfilter_iso8859_3.c mbfilter_iso8859_4.c \ mbfilter_iso8859_5.c mbfilter_iso8859_6.c mbfilter_iso8859_7.c \ mbfilter_iso8859_8.c mbfilter_iso8859_9.c mbfilter_jis.c \ - mbfilter_iso2022_jp_ms.c mbfilter_gb18030.c mbfiler_sjis_2004.c \ + mbfilter_iso2022_jp_ms.c mbfilter_gb18030.c mbfilter_sjis_2004.c \ mbfilter_koi8r.c mbfilter_qprint.c mbfilter_sjis.c mbfilter_ucs2.c \ mbfilter_ucs4.c mbfilter_uhc.c mbfilter_utf16.c mbfilter_utf32.c \ mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c mbfilter_utf8_mobile.c \ From 9baee858445278ea1efe45414440b4dd0566c922 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Mon, 22 Aug 2011 10:42:43 +0000 Subject: [PATCH 0594/2394] Fix Bug #55473 mysql_pconnect leaks file descriptors on reconnect The fix is for now in 5_4 and trunk, to be merged into 5_3 after 5.3.8 is packaged (expected today). The test case goes to all branches --- ext/mysql/tests/bug55473.phpt | 68 +++++++++++++++++++++++++++++++++++ ext/mysqlnd/mysqlnd_net.c | 11 ++++++ 2 files changed, 79 insertions(+) create mode 100644 ext/mysql/tests/bug55473.phpt diff --git a/ext/mysql/tests/bug55473.phpt b/ext/mysql/tests/bug55473.phpt new file mode 100644 index 0000000000000..8d42744fdfe25 --- /dev/null +++ b/ext/mysql/tests/bug55473.phpt @@ -0,0 +1,68 @@ +--TEST-- +Bug #5547 (mysql_pconnect leaks file descriptors on reconnect) +--SKIPIF-- + +--INI-- +mysql.max_persistent=30 +mysql.allow_persistent=1 +--FILE-- + +--EXPECTF-- +Warning: mysql_ping(): MySQL server has gone away in %s on line %d +reconnect +OK + +Warning: mysql_ping(): MySQL server has gone away in %s on line %d +reconnect +OK + +Warning: mysql_ping(): MySQL server has gone away in %s on line %d +reconnect +OK + +Warning: mysql_ping(): MySQL server has gone away in %s on line %d +reconnect +OK +done! \ No newline at end of file diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index 6821c5f205632..606d919e3bd1c 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -115,6 +115,17 @@ MYSQLND_METHOD(mysqlnd_net, connect)(MYSQLND_NET * net, const char * const schem net->packet_no = net->compressed_envelope_packet_no = 0; + if (net->stream) { + /* close before opening a new one */ + DBG_INF_FMT("Freeing stream. abstract=%p", net->stream->abstract); + if (net->persistent) { + php_stream_free(net->stream, PHP_STREAM_FREE_CLOSE_PERSISTENT | PHP_STREAM_FREE_RSRC_DTOR); + } else { + php_stream_free(net->stream, PHP_STREAM_FREE_CLOSE); + } + net->stream = NULL; + } + if (scheme_len > (sizeof("pipe://") - 1) && !memcmp(scheme, "pipe://", sizeof("pipe://") - 1)) { if (persistent) { streams_options |= STREAM_OPEN_PERSISTENT; From db3cc02dc95cacc32517823b187c3047d4d1a14a Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Mon, 22 Aug 2011 11:07:35 +0000 Subject: [PATCH 0595/2394] Don't run the test on windows, Unix specific --- ext/mysql/tests/bug55473.phpt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/mysql/tests/bug55473.phpt b/ext/mysql/tests/bug55473.phpt index 8d42744fdfe25..d492e68349b5a 100644 --- a/ext/mysql/tests/bug55473.phpt +++ b/ext/mysql/tests/bug55473.phpt @@ -4,6 +4,9 @@ Bug #5547 (mysql_pconnect leaks file descriptors on reconnect) --INI-- mysql.max_persistent=30 From 1e0e85ec1a7613623757ee5df52a322e5d8c3fad Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 22 Aug 2011 11:55:41 +0000 Subject: [PATCH 0596/2394] Fixed #55463 (cli-server missing _SERVER[REMOTE_ADDR]) --- NEWS | 1 + sapi/cli/php_cli_server.c | 14 ++++++++++++++ 2 files changed, 15 insertions(+) diff --git a/NEWS b/NEWS index 9f2506b9461e2..783318184704d 100644 --- a/NEWS +++ b/NEWS @@ -248,5 +248,6 @@ PHP NEWS - Fixed bug #52211 (iconv() returns part of string on error). (Felipe) - Fixed bug #55450 (Built in web server not accepting file uploads). (Laruence) - Fixed bug #55471 (ZTS build broken with dtrace). (Laruence) +- Fixed bug #55463 (cli-server missing _SERVER[REMOTE_ADDR]). (Laruence) <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 71d83e9051152..eefe2a131679e 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -496,6 +496,20 @@ static void sapi_cli_server_register_variables(zval *track_vars_array TSRMLS_DC) sapi_cli_server_register_variable(track_vars_array, "HTTP_REFERER", *val TSRMLS_CC); } } + { + char *tmp; + if ((tmp = strrchr(client->addr_str, ':'))) { + char addr[64], port[8]; + strncpy(port, tmp + 1, 8); + port[7] = '\0'; + strncpy(addr, client->addr_str, tmp - client->addr_str); + addr[tmp - client->addr_str] = '\0'; + sapi_cli_server_register_variable(track_vars_array, "REMOTE_ADDR", addr TSRMLS_CC); + sapi_cli_server_register_variable(track_vars_array, "REMOTE_PORT", port TSRMLS_CC); + } else { + sapi_cli_server_register_variable(track_vars_array, "REMOTE_ADDR", client->addr_str TSRMLS_CC); + } + } sapi_cli_server_register_variable(track_vars_array, "REQUEST_URI", client->request.request_uri TSRMLS_CC); sapi_cli_server_register_variable(track_vars_array, "REQUEST_METHOD", SG(request_info).request_method TSRMLS_CC); sapi_cli_server_register_variable(track_vars_array, "PHP_SELF", client->request.vpath TSRMLS_CC); From 143b2a8692829ebd774269e79205270ba71f5ceb Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Mon, 22 Aug 2011 14:47:12 +0000 Subject: [PATCH 0597/2394] Fix spring tests for dst/st transition second. --- ext/date/tests/DateTime_data-spring-type2-type2.inc | 8 ++++---- ext/date/tests/DateTime_data-spring-type2-type3.inc | 8 ++++---- ext/date/tests/DateTime_data-spring-type3-type2.inc | 8 ++++---- ext/date/tests/DateTime_data-spring-type3-type3.inc | 8 ++++---- ext/date/tests/DateTime_days-spring-type2-type2.phpt | 2 +- ext/date/tests/DateTime_days-spring-type2-type3.phpt | 2 +- ext/date/tests/DateTime_days-spring-type3-type2.phpt | 2 +- ext/date/tests/DateTime_days-spring-type3-type3.phpt | 2 +- 8 files changed, 20 insertions(+), 20 deletions(-) diff --git a/ext/date/tests/DateTime_data-spring-type2-type2.inc b/ext/date/tests/DateTime_data-spring-type2-type2.inc index 3556b207b382a..d9e07c31301cd 100644 --- a/ext/date/tests/DateTime_data-spring-type2-type2.inc +++ b/ext/date/tests/DateTime_data-spring-type2-type2.inc @@ -99,11 +99,11 @@ $start = new DateTime('2010-03-15 18:57:55 EDT'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); echo "test_time_spring_type2_stsec_type2_dtsec: "; -$end = new DateTime('2010-03-15 03:00:00 EDT'); // dtsec, zt2 -$start = new DateTime('2010-03-13 01:59:59 EST'); // stsec, zt2 +$end = new DateTime('2010-03-14 03:00:00 EDT'); // dtsec, zt2 +$start = new DateTime('2010-03-14 01:59:59 EST'); // stsec, zt2 examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); echo "test_time_spring_type2_dtsec_type2_stsec: "; -$end = new DateTime('2010-03-15 01:59:59 EST'); // stsec, zt2 -$start = new DateTime('2010-03-13 03:00:00 EDT'); // dtsec, zt2 +$end = new DateTime('2010-03-14 01:59:59 EST'); // stsec, zt2 +$start = new DateTime('2010-03-14 03:00:00 EDT'); // dtsec, zt2 examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-spring-type2-type3.inc b/ext/date/tests/DateTime_data-spring-type2-type3.inc index b06825837c71c..d66fc51778cb4 100644 --- a/ext/date/tests/DateTime_data-spring-type2-type3.inc +++ b/ext/date/tests/DateTime_data-spring-type2-type3.inc @@ -99,11 +99,11 @@ $start = new DateTime('2010-03-15 18:57:55 EDT'); // sp post, zt2 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); echo "test_time_spring_type2_stsec_type3_dtsec: "; -$end = new DateTime('2010-03-15 03:00:00'); // dtsec, zt3 -$start = new DateTime('2010-03-13 01:59:59 EST'); // stsec, zt2 +$end = new DateTime('2010-03-14 03:00:00'); // dtsec, zt3 +$start = new DateTime('2010-03-14 01:59:59 EST'); // stsec, zt2 examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); echo "test_time_spring_type2_dtsec_type3_stsec: "; -$end = new DateTime('2010-03-15 01:59:59'); // stsec, zt3 -$start = new DateTime('2010-03-13 03:00:00 EDT'); // dtsec, zt2 +$end = new DateTime('2010-03-14 01:59:59'); // stsec, zt3 +$start = new DateTime('2010-03-14 03:00:00 EDT'); // dtsec, zt2 examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-spring-type3-type2.inc b/ext/date/tests/DateTime_data-spring-type3-type2.inc index 244cd58819e29..92211f4b1a86c 100644 --- a/ext/date/tests/DateTime_data-spring-type3-type2.inc +++ b/ext/date/tests/DateTime_data-spring-type3-type2.inc @@ -99,11 +99,11 @@ $start = new DateTime('2010-03-15 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); echo "test_time_spring_type3_stsec_type2_dtsec: "; -$end = new DateTime('2010-03-15 03:00:00 EDT'); // dtsec, zt2 -$start = new DateTime('2010-03-13 01:59:59'); // stsec, zt3 +$end = new DateTime('2010-03-14 03:00:00 EDT'); // dtsec, zt2 +$start = new DateTime('2010-03-14 01:59:59'); // stsec, zt3 examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); echo "test_time_spring_type3_dtsec_type2_stsec: "; -$end = new DateTime('2010-03-15 01:59:59 EST'); // stsec, zt2 -$start = new DateTime('2010-03-13 03:00:00'); // dtsec, zt3 +$end = new DateTime('2010-03-14 01:59:59 EST'); // stsec, zt2 +$start = new DateTime('2010-03-14 03:00:00'); // dtsec, zt3 examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_data-spring-type3-type3.inc b/ext/date/tests/DateTime_data-spring-type3-type3.inc index d87373c5a4b40..de1dee12e620a 100644 --- a/ext/date/tests/DateTime_data-spring-type3-type3.inc +++ b/ext/date/tests/DateTime_data-spring-type3-type3.inc @@ -99,11 +99,11 @@ $start = new DateTime('2010-03-15 18:57:55'); // sp post, zt3 examine_diff($end, $start, 'P+0Y0M0DT1H2M4S', 0); echo "test_time_spring_type3_stsec_type3_dtsec: "; -$end = new DateTime('2010-03-15 03:00:00'); // dtsec, zt3 -$start = new DateTime('2010-03-13 01:59:59'); // stsec, zt3 +$end = new DateTime('2010-03-14 03:00:00'); // dtsec, zt3 +$start = new DateTime('2010-03-14 01:59:59'); // stsec, zt3 examine_diff($end, $start, 'P+0Y0M0DT0H0M1S', 0); echo "test_time_spring_type3_dtsec_type3_stsec: "; -$end = new DateTime('2010-03-15 01:59:59'); // stsec, zt3 -$start = new DateTime('2010-03-13 03:00:00'); // dtsec, zt3 +$end = new DateTime('2010-03-14 01:59:59'); // stsec, zt3 +$start = new DateTime('2010-03-14 03:00:00'); // dtsec, zt3 examine_diff($end, $start, 'P-0Y0M0DT0H0M1S', 0); diff --git a/ext/date/tests/DateTime_days-spring-type2-type2.phpt b/ext/date/tests/DateTime_days-spring-type2-type2.phpt index 3f9c353523ae7..3e702ace09a2c 100644 --- a/ext/date/tests/DateTime_days-spring-type2-type2.phpt +++ b/ext/date/tests/DateTime_days-spring-type2-type2.phpt @@ -27,5 +27,5 @@ test_time_spring_type2_post_type2_prev: DAYS: **2** test_time_spring_type2_post_type2_st: DAYS: **1** test_time_spring_type2_post_type2_dt: DAYS: **1** test_time_spring_type2_post_type2_post: DAYS: **0** -test_time_spring_type2_stsec_type2_dtsec: DAYS: **0** +test_time_spring_type2_stsec_type2_dtsec: DAYS: **0** test_time_spring_type2_dtsec_type2_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type2-type3.phpt b/ext/date/tests/DateTime_days-spring-type2-type3.phpt index 77ac5fdb6daf5..0e23ac3e2c4f4 100644 --- a/ext/date/tests/DateTime_days-spring-type2-type3.phpt +++ b/ext/date/tests/DateTime_days-spring-type2-type3.phpt @@ -27,5 +27,5 @@ test_time_spring_type2_post_type3_prev: DAYS: **2** test_time_spring_type2_post_type3_st: DAYS: **1** test_time_spring_type2_post_type3_dt: DAYS: **1** test_time_spring_type2_post_type3_post: DAYS: **0** -test_time_spring_type2_stsec_type3_dtsec: DAYS: **0** +test_time_spring_type2_stsec_type3_dtsec: DAYS: **0** test_time_spring_type2_dtsec_type3_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type3-type2.phpt b/ext/date/tests/DateTime_days-spring-type3-type2.phpt index 09aa8d9c1d7af..4fb9ba76d210f 100644 --- a/ext/date/tests/DateTime_days-spring-type3-type2.phpt +++ b/ext/date/tests/DateTime_days-spring-type3-type2.phpt @@ -27,5 +27,5 @@ test_time_spring_type3_post_type2_prev: DAYS: **2** test_time_spring_type3_post_type2_st: DAYS: **1** test_time_spring_type3_post_type2_dt: DAYS: **1** test_time_spring_type3_post_type2_post: DAYS: **0** -test_time_spring_type3_stsec_type2_dtsec: DAYS: **0** +test_time_spring_type3_stsec_type2_dtsec: DAYS: **0** test_time_spring_type3_dtsec_type2_stsec: DAYS: **0** diff --git a/ext/date/tests/DateTime_days-spring-type3-type3.phpt b/ext/date/tests/DateTime_days-spring-type3-type3.phpt index f947329dea9b3..df44925fbd1e6 100644 --- a/ext/date/tests/DateTime_days-spring-type3-type3.phpt +++ b/ext/date/tests/DateTime_days-spring-type3-type3.phpt @@ -27,5 +27,5 @@ test_time_spring_type3_post_type3_prev: DAYS: **2** test_time_spring_type3_post_type3_st: DAYS: **1** test_time_spring_type3_post_type3_dt: DAYS: **1** test_time_spring_type3_post_type3_post: DAYS: **0** -test_time_spring_type3_stsec_type3_dtsec: DAYS: **0** +test_time_spring_type3_stsec_type3_dtsec: DAYS: **0** test_time_spring_type3_dtsec_type3_stsec: DAYS: **0** From f7c6c67d1928a6f95895880107aaad10dc198aca Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 22 Aug 2011 15:51:49 +0000 Subject: [PATCH 0598/2394] Added _SERVER[SERVER_SOFTWARE] for built-in server --- sapi/cli/php_cli_server.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index eefe2a131679e..ff631ff87cdf0 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -509,6 +509,12 @@ static void sapi_cli_server_register_variables(zval *track_vars_array TSRMLS_DC) } else { sapi_cli_server_register_variable(track_vars_array, "REMOTE_ADDR", client->addr_str TSRMLS_CC); } + } + { + char *tmp; + spprintf(&tmp, 0, "PHP %s Development Server", PHP_VERSION); + sapi_cli_server_register_variable(track_vars_array, "SERVER_SOFTWARE", tmp TSRMLS_CC); + efree(tmp); } sapi_cli_server_register_variable(track_vars_array, "REQUEST_URI", client->request.request_uri TSRMLS_CC); sapi_cli_server_register_variable(track_vars_array, "REQUEST_METHOD", SG(request_info).request_method TSRMLS_CC); From f54e65c84389a861873ed65ff653fb026519388f Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Mon, 22 Aug 2011 18:06:08 +0000 Subject: [PATCH 0599/2394] Remove duplicated test --- ext/oci8/tests/bug51291.phpt | 434 ----------------------------------- 1 file changed, 434 deletions(-) delete mode 100644 ext/oci8/tests/bug51291.phpt diff --git a/ext/oci8/tests/bug51291.phpt b/ext/oci8/tests/bug51291.phpt deleted file mode 100644 index 75851d63b1251..0000000000000 --- a/ext/oci8/tests/bug51291.phpt +++ /dev/null @@ -1,434 +0,0 @@ ---TEST-- -Bug #51291 (oci_error() doesn't report last error when called two times) ---SKIPIF-- - ---FILE-- - -===DONE=== - ---EXPECTF-- -Test 1 - Parse -array(4) { - ["code"]=> - int(1756) - ["message"]=> - string(48) "ORA-01756: %s" - ["offset"]=> - int(0) - ["sqltext"]=> - string(0) "" -} -2nd call -array(4) { - ["code"]=> - int(1756) - ["message"]=> - string(48) "ORA-01756: %s" - ["offset"]=> - int(0) - ["sqltext"]=> - string(0) "" -} - -Test 2 - Parse - -Warning: oci_error() expects parameter 1 to be resource, boolean given in %sbug51291.php on line %d -bool(false) -array(4) { - ["code"]=> - int(1756) - ["message"]=> - string(48) "ORA-01756: %s" - ["offset"]=> - int(0) - ["sqltext"]=> - string(0) "" -} -NULL -2nd call - -Warning: oci_error() expects parameter 1 to be resource, boolean given in %sbug51291.php on line %d -bool(false) -array(4) { - ["code"]=> - int(1756) - ["message"]=> - string(48) "ORA-01756: %s" - ["offset"]=> - int(0) - ["sqltext"]=> - string(0) "" -} -NULL - -Test 3 - Execute -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -2nd call -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} - -Test 4 - Execute - consecutive oci_error calls of different kinds -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -2nd call -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} - -Test 5 - Execute - after oci_rollback -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -Rollback status is true -2nd call after oci_rollback -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} - -Test 6 - Execute - after successful 2nd query with new handle -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -Execute status is true -2nd call after successful execute -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -bool(false) - -Test 7 - Execute - after successful 2nd query with same handle -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -Execute status is true -2nd call after successful execute -bool(false) -bool(false) -bool(false) - -Test 8 - Execute - after unsuccessful 2nd query with new handle -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} - -Warning: oci_execute(): ORA-00904: "REALLYNOTHERE": %s in %sbug51291.php on line %d -Execute status is false -2nd call after unsuccessful execute -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(46) "ORA-00904: "REALLYNOTHERE": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(30) "select reallynothere from dual" -} - -Test 9 - Execute - after unsuccessful 2nd query with same handle -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(45) "ORA-00904: "DOESNOTEXIST": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(29) "select doesnotexist from dual" -} - -Warning: oci_execute(): ORA-00904: "REALLYNOTHERE": %s in %sbug51291.php on line %d -Execute status is false -2nd call after unsuccessful execute -bool(false) -bool(false) -array(4) { - ["code"]=> - int(904) - ["message"]=> - string(46) "ORA-00904: "REALLYNOTHERE": %s" - ["offset"]=> - int(7) - ["sqltext"]=> - string(30) "select reallynothere from dual" -} - -Test 10 - Execute - after successful 2nd query with same statement -bool(false) -bool(false) -array(4) { - ["code"]=> - int(6510) - ["message"]=> - string(72) "ORA-06510: PL/SQL: %s -ORA-06512: %s" - ["offset"]=> - int(0) - ["sqltext"]=> - string(64) "declare e exception; begin if :bv = 1 then raise e; end if; end;" -} -Execute status is true -2nd call after successful execute -bool(false) -bool(false) -bool(false) -===DONE=== From 981b9878d4454d090a7a1cff96a8700839cb7e33 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Mon, 22 Aug 2011 23:56:34 +0000 Subject: [PATCH 0600/2394] Sync date with actual PECL release date for correctness --- ext/oci8/package.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/oci8/package.xml b/ext/oci8/package.xml index 22c05c6ab6035..de4dbff813b2d 100644 --- a/ext/oci8/package.xml +++ b/ext/oci8/package.xml @@ -33,7 +33,7 @@ http://pear.php.net/dtd/package-2.0.xsd"> no - 2011-07-25 + 2011-08-22 From d05c878d10d0b27b77f556f85628bf3b0e346a19 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 23 Aug 2011 02:48:28 +0000 Subject: [PATCH 0601/2394] update NEWS --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index 783318184704d..9c4f389a80d3f 100644 --- a/NEWS +++ b/NEWS @@ -249,5 +249,6 @@ PHP NEWS - Fixed bug #55450 (Built in web server not accepting file uploads). (Laruence) - Fixed bug #55471 (ZTS build broken with dtrace). (Laruence) - Fixed bug #55463 (cli-server missing _SERVER[REMOTE_ADDR]). (Laruence) +- Fixed bug #55473 (mysql_pconnect leaks file descriptors on reconnect). (Andrey, Laruence) <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From 17fb5f539d5fb8cef58a8c1ec7ffa50aa6377da5 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 23 Aug 2011 10:00:18 +0000 Subject: [PATCH 0602/2394] Sync -development with -production --- php.ini-development | 2 -- 1 file changed, 2 deletions(-) diff --git a/php.ini-development b/php.ini-development index df35cad7873f0..6c38cc878f40c 100644 --- a/php.ini-development +++ b/php.ini-development @@ -871,14 +871,12 @@ default_socket_timeout = 60 ;extension=php_oci8_11g.dll ; Use with Oracle 11g Instant Client ;extension=php_openssl.dll ;extension=php_pdo_firebird.dll -;extension=php_pdo_mssql.dll ;extension=php_pdo_mysql.dll ;extension=php_pdo_oci.dll ;extension=php_pdo_odbc.dll ;extension=php_pdo_pgsql.dll ;extension=php_pdo_sqlite.dll ;extension=php_pgsql.dll -;extension=php_phar.dll ;extension=php_pspell.dll ;extension=php_shmop.dll From e7b173152cd685112af07f799df25fd98f32e8e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Tue, 23 Aug 2011 15:43:40 +0000 Subject: [PATCH 0603/2394] - Add a note to mention changeLog and downloads in the news entry --- README.RELEASE_PROCESS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.RELEASE_PROCESS b/README.RELEASE_PROCESS index 8576d062c4a45..1b5306243f489 100644 --- a/README.RELEASE_PROCESS +++ b/README.RELEASE_PROCESS @@ -228,7 +228,7 @@ announcement file should list in detail: 7. Add a short notice to phpweb stating that there is a new release, and highlight the major important things (security fixes) and when it is important -to upgrade. +to upgrade. Make sure the news entry links to the ChangeLog and downloads. a. Call php bin/createNewsEntry in your local phpweb checkout From 8131f04f9a0c8bcc9596b97d4837d41678e8a30d Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Tue, 23 Aug 2011 16:40:19 +0000 Subject: [PATCH 0604/2394] Fix differences in some sub() results that were causing tests to fail. --- ext/date/tests/DateTime_data-dates.inc | 2 ++ ext/date/tests/DateTime_data-february.inc | 9 +++++++++ ext/date/tests/DateTime_sub-dates.phpt | 4 ++-- ext/date/tests/DateTime_sub-february.phpt | 18 +++++++++--------- 4 files changed, 22 insertions(+), 11 deletions(-) diff --git a/ext/date/tests/DateTime_data-dates.inc b/ext/date/tests/DateTime_data-dates.inc index be608dfcba3f0..c6f04e16ccbbb 100644 --- a/ext/date/tests/DateTime_data-dates.inc +++ b/ext/date/tests/DateTime_data-dates.inc @@ -20,6 +20,7 @@ examine_diff('2007-02-07', '2000-02-07', 'P+7Y0M0DT0H0M0S', 2557); echo "test_years_positive__7_by_1_day: "; examine_diff('2007-02-08', '2000-02-07', 'P+7Y0M1DT0H0M0S', 2558); +// NOTE: sub() produces different answer. echo "test_years_positive__6_shy_1_day: "; examine_diff('2007-02-06', '2000-02-07', 'P+6Y11M30DT0H0M0S', 2556); @@ -48,6 +49,7 @@ examine_diff('2000-02-07', '2007-02-07', 'P-7Y0M0DT0H0M0S', 2557); echo "test_years_negative__7_by_1_day: "; examine_diff('2000-02-07', '2007-02-08', 'P-7Y0M1DT0H0M0S', 2558); +// NOTE: sub() produces different answer. echo "test_years_negative__6_shy_1_day: "; examine_diff('2000-02-07', '2007-02-06', 'P-6Y11M28DT0H0M0S', 2556); diff --git a/ext/date/tests/DateTime_data-february.inc b/ext/date/tests/DateTime_data-february.inc index 8c31ef69ac74b..cc9d85df07d1d 100644 --- a/ext/date/tests/DateTime_data-february.inc +++ b/ext/date/tests/DateTime_data-february.inc @@ -71,15 +71,19 @@ examine_diff('2010-03-01', '2010-01-01', 'P+0Y2M0DT0H0M0S', 59); echo "test_bug_49081__20: "; examine_diff('2010-03-01', '2010-01-31', 'P+0Y0M29DT0H0M0S', 29); +// NOTE: sub() produces different answer. echo "test_bug_49081__21: "; examine_diff('2010-03-27', '2010-01-31', 'P+0Y1M24DT0H0M0S', 55); +// NOTE: sub() produces different answer. echo "test_bug_49081__22: "; examine_diff('2010-03-28', '2010-01-31', 'P+0Y1M25DT0H0M0S', 56); +// NOTE: sub() produces different answer. echo "test_bug_49081__23: "; examine_diff('2010-03-29', '2010-01-31', 'P+0Y1M26DT0H0M0S', 57); +// NOTE: sub() produces different answer. echo "test_bug_49081__24: "; examine_diff('2010-03-30', '2010-01-31', 'P+0Y1M27DT0H0M0S', 58); @@ -168,18 +172,23 @@ examine_diff('2010-01-27', '2010-02-28', 'P-0Y1M1DT0H0M0S', 32); echo "test_bug_49081_negative__19: "; examine_diff('2010-01-01', '2010-03-01', 'P-0Y2M0DT0H0M0S', 59); +// NOTE: sub() produces different answer. echo "test_bug_49081_negative__20: "; examine_diff('2010-01-31', '2010-03-01', 'P-0Y1M1DT0H0M0S', 29); +// NOTE: sub() produces different answer. echo "test_bug_49081_negative__21: "; examine_diff('2010-01-31', '2010-03-27', 'P-0Y1M27DT0H0M0S', 55); +// NOTE: sub() produces different answer. echo "test_bug_49081_negative__22: "; examine_diff('2010-01-31', '2010-03-28', 'P-0Y1M28DT0H0M0S', 56); +// NOTE: sub() produces different answer. echo "test_bug_49081_negative__23: "; examine_diff('2010-01-31', '2010-03-29', 'P-0Y1M29DT0H0M0S', 57); +// NOTE: sub() produces different answer. echo "test_bug_49081_negative__24: "; examine_diff('2010-01-31', '2010-03-30', 'P-0Y1M30DT0H0M0S', 58); diff --git a/ext/date/tests/DateTime_sub-dates.phpt b/ext/date/tests/DateTime_sub-dates.phpt index 36ca25c167ac7..26f49ba838267 100644 --- a/ext/date/tests/DateTime_sub-dates.phpt +++ b/ext/date/tests/DateTime_sub-dates.phpt @@ -14,7 +14,7 @@ require 'DateTime_data-dates.inc'; test__7: SUB: 2009-01-14 00:00:00 EST - P+0Y0M7DT0H0M0S = **2009-01-07 00:00:00 EST** test_years_positive__7_by_0_day: SUB: 2007-02-07 00:00:00 EST - P+7Y0M0DT0H0M0S = **2000-02-07 00:00:00 EST** test_years_positive__7_by_1_day: SUB: 2007-02-08 00:00:00 EST - P+7Y0M1DT0H0M0S = **2000-02-07 00:00:00 EST** -test_years_positive__6_shy_1_day: SUB: 2007-02-06 00:00:00 EST - P+6Y11M30DT0H0M0S = **2000-02-07 00:00:00 EST** +test_years_positive__6_shy_1_day: SUB: 2007-02-06 00:00:00 EST - P+6Y11M30DT0H0M0S = **2000-02-05 00:00:00 EST** test_years_positive__7_by_1_month: SUB: 2007-03-07 00:00:00 EST - P+7Y1M0DT0H0M0S = **2000-02-07 00:00:00 EST** test_years_positive__6_shy_1_month: SUB: 2007-01-07 00:00:00 EST - P+6Y11M0DT0H0M0S = **2000-02-07 00:00:00 EST** test_years_positive__7_by_1_month_split_newyear: SUB: 2007-01-07 00:00:00 EST - P+7Y1M0DT0H0M0S = **1999-12-07 00:00:00 EST** @@ -22,7 +22,7 @@ test_years_positive__6_shy_1_month_split_newyear: SUB: 2006-12-07 00:00:00 EST - test_negative__7: SUB: 2009-01-07 00:00:00 EST - P-0Y0M7DT0H0M0S = **2009-01-14 00:00:00 EST** test_years_negative__7_by_0_day: SUB: 2000-02-07 00:00:00 EST - P-7Y0M0DT0H0M0S = **2007-02-07 00:00:00 EST** test_years_negative__7_by_1_day: SUB: 2000-02-07 00:00:00 EST - P-7Y0M1DT0H0M0S = **2007-02-08 00:00:00 EST** -test_years_negative__6_shy_1_day: SUB: 2000-02-07 00:00:00 EST - P-6Y11M28DT0H0M0S = **2007-02-06 00:00:00 EST** +test_years_negative__6_shy_1_day: SUB: 2000-02-07 00:00:00 EST - P-6Y11M28DT0H0M0S = **2007-02-04 00:00:00 EST** test_years_negative__7_by_1_month: SUB: 2000-02-07 00:00:00 EST - P-7Y1M0DT0H0M0S = **2007-03-07 00:00:00 EST** test_years_negative__6_shy_1_month: SUB: 2000-02-07 00:00:00 EST - P-6Y11M0DT0H0M0S = **2007-01-07 00:00:00 EST** test_years_negative__7_by_1_month_split_newyear: SUB: 1999-12-07 00:00:00 EST - P-7Y1M0DT0H0M0S = **2007-01-07 00:00:00 EST** diff --git a/ext/date/tests/DateTime_sub-february.phpt b/ext/date/tests/DateTime_sub-february.phpt index 89cba4bded5bb..23c8da4479123 100644 --- a/ext/date/tests/DateTime_sub-february.phpt +++ b/ext/date/tests/DateTime_sub-february.phpt @@ -31,10 +31,10 @@ test_bug_49081__17: SUB: 2010-02-28 00:00:00 EST - P+0Y1M0DT0H0M0S = **2010-01-2 test_bug_49081__18: SUB: 2010-02-28 00:00:00 EST - P+0Y1M1DT0H0M0S = **2010-01-27 00:00:00 EST** test_bug_49081__19: SUB: 2010-03-01 00:00:00 EST - P+0Y2M0DT0H0M0S = **2010-01-01 00:00:00 EST** test_bug_49081__20: SUB: 2010-03-01 00:00:00 EST - P+0Y0M29DT0H0M0S = **2010-01-31 00:00:00 EST** -test_bug_49081__21: SUB: 2010-03-27 00:00:00 EDT - P+0Y1M24DT0H0M0S = **2010-01-31 00:00:00 EST** -test_bug_49081__22: SUB: 2010-03-28 00:00:00 EDT - P+0Y1M25DT0H0M0S = **2010-01-31 00:00:00 EST** -test_bug_49081__23: SUB: 2010-03-29 00:00:00 EDT - P+0Y1M26DT0H0M0S = **2010-01-31 00:00:00 EST** -test_bug_49081__24: SUB: 2010-03-30 00:00:00 EDT - P+0Y1M27DT0H0M0S = **2010-01-31 00:00:00 EST** +test_bug_49081__21: SUB: 2010-03-27 00:00:00 EDT - P+0Y1M24DT0H0M0S = **2010-02-03 00:00:00 EST** +test_bug_49081__22: SUB: 2010-03-28 00:00:00 EDT - P+0Y1M25DT0H0M0S = **2010-02-03 00:00:00 EST** +test_bug_49081__23: SUB: 2010-03-29 00:00:00 EDT - P+0Y1M26DT0H0M0S = **2010-02-03 00:00:00 EST** +test_bug_49081__24: SUB: 2010-03-30 00:00:00 EDT - P+0Y1M27DT0H0M0S = **2010-02-03 00:00:00 EST** test_bug_49081__25: SUB: 2010-03-31 00:00:00 EDT - P+0Y2M0DT0H0M0S = **2010-01-31 00:00:00 EST** test_bug_49081__26: SUB: 2010-03-31 00:00:00 EDT - P+0Y2M1DT0H0M0S = **2010-01-30 00:00:00 EST** test_bug_49081__27: SUB: 2009-01-31 00:00:00 EST - P+0Y0M30DT0H0M0S = **2009-01-01 00:00:00 EST** @@ -62,11 +62,11 @@ test_bug_49081_negative__16: SUB: 2010-01-29 00:00:00 EST - P-0Y0M30DT0H0M0S = * test_bug_49081_negative__17: SUB: 2010-01-28 00:00:00 EST - P-0Y1M0DT0H0M0S = **2010-02-28 00:00:00 EST** test_bug_49081_negative__18: SUB: 2010-01-27 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-02-28 00:00:00 EST** test_bug_49081_negative__19: SUB: 2010-01-01 00:00:00 EST - P-0Y2M0DT0H0M0S = **2010-03-01 00:00:00 EST** -test_bug_49081_negative__20: SUB: 2010-01-31 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-03-01 00:00:00 EST** -test_bug_49081_negative__21: SUB: 2010-01-31 00:00:00 EST - P-0Y1M27DT0H0M0S = **2010-03-27 00:00:00 EDT** -test_bug_49081_negative__22: SUB: 2010-01-31 00:00:00 EST - P-0Y1M28DT0H0M0S = **2010-03-28 00:00:00 EDT** -test_bug_49081_negative__23: SUB: 2010-01-31 00:00:00 EST - P-0Y1M29DT0H0M0S = **2010-03-29 00:00:00 EDT** -test_bug_49081_negative__24: SUB: 2010-01-31 00:00:00 EST - P-0Y1M30DT0H0M0S = **2010-03-30 00:00:00 EDT** +test_bug_49081_negative__20: SUB: 2010-01-31 00:00:00 EST - P-0Y1M1DT0H0M0S = **2010-03-04 00:00:00 EST** +test_bug_49081_negative__21: SUB: 2010-01-31 00:00:00 EST - P-0Y1M27DT0H0M0S = **2010-03-30 00:00:00 EDT** +test_bug_49081_negative__22: SUB: 2010-01-31 00:00:00 EST - P-0Y1M28DT0H0M0S = **2010-03-31 00:00:00 EDT** +test_bug_49081_negative__23: SUB: 2010-01-31 00:00:00 EST - P-0Y1M29DT0H0M0S = **2010-04-01 00:00:00 EDT** +test_bug_49081_negative__24: SUB: 2010-01-31 00:00:00 EST - P-0Y1M30DT0H0M0S = **2010-04-02 00:00:00 EDT** test_bug_49081_negative__25: SUB: 2010-01-31 00:00:00 EST - P-0Y2M0DT0H0M0S = **2010-03-31 00:00:00 EDT** test_bug_49081_negative__26: SUB: 2010-01-30 00:00:00 EST - P-0Y2M1DT0H0M0S = **2010-03-31 00:00:00 EDT** test_bug_49081_negative__27: SUB: 2009-01-01 00:00:00 EST - P-0Y0M30DT0H0M0S = **2009-01-31 00:00:00 EST** From 048485587edd321ef0e9b2466801746e888c7204 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 23 Aug 2011 18:32:53 +0000 Subject: [PATCH 0605/2394] - ws --- main/php_variables.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main/php_variables.c b/main/php_variables.c index 8bd1b01c334b2..40ad26fc9de51 100644 --- a/main/php_variables.c +++ b/main/php_variables.c @@ -597,7 +597,7 @@ static void php_autoglobal_merge(HashTable *dest, HashTable *src TSRMLS_DC) || (key_type == HASH_KEY_IS_STRING && zend_hash_find(dest, string_key, string_key_len, (void **) &dest_entry) != SUCCESS) || (key_type == HASH_KEY_IS_LONG && zend_hash_index_find(dest, num_key, (void **)&dest_entry) != SUCCESS) || Z_TYPE_PP(dest_entry) != IS_ARRAY - ) { + ) { Z_ADDREF_PP(src_entry); if (key_type == HASH_KEY_IS_STRING) { if (!globals_check || string_key_len != sizeof("GLOBALS") || memcmp(string_key, "GLOBALS", sizeof("GLOBALS") - 1)) { @@ -662,7 +662,7 @@ static zend_bool php_auto_globals_create_post(char *name, uint name_len TSRMLS_D zval *vars; if (PG(variables_order) && - (strchr(PG(variables_order),'P') || strchr(PG(variables_order),'p')) && + (strchr(PG(variables_order),'P') || strchr(PG(variables_order),'p')) && !SG(headers_sent) && SG(request_info).request_method && !strcasecmp(SG(request_info).request_method, "POST")) { @@ -736,7 +736,7 @@ static zend_bool php_auto_globals_create_server(char *name, uint name_len TSRMLS zval **argc, **argv; if (zend_hash_find(&EG(symbol_table), "argc", sizeof("argc"), (void**)&argc) == SUCCESS && - zend_hash_find(&EG(symbol_table), "argv", sizeof("argv"), (void**)&argv) == SUCCESS) { + zend_hash_find(&EG(symbol_table), "argv", sizeof("argv"), (void**)&argv) == SUCCESS) { Z_ADDREF_PP(argc); Z_ADDREF_PP(argv); zend_hash_update(Z_ARRVAL_P(PG(http_globals)[TRACK_VARS_SERVER]), "argv", sizeof("argv"), argv, sizeof(zval *), NULL); From 1aed8a8c1cdcf4f18cf38c6f56e88e2232d0ff74 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Tue, 23 Aug 2011 19:13:49 +0000 Subject: [PATCH 0606/2394] apply docs fixes suggested in BR #55474 --- ext/snmp/tests/README | 41 +++++++-------------------------------- ext/snmp/tests/snmpd.conf | 25 ++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 34 deletions(-) create mode 100644 ext/snmp/tests/snmpd.conf diff --git a/ext/snmp/tests/README b/ext/snmp/tests/README index 74258ec27f279..a2cb794913d2c 100644 --- a/ext/snmp/tests/README +++ b/ext/snmp/tests/README @@ -21,44 +21,17 @@ SNMP_MIBDIR : Directory containing MIBS On Linux/FreeBSD -------- -- Install package net-snmpd (name may differ based on your distribution) -- Edit config file (by default this is /etc/snmp/snmpd.conf on Linux and - usr/local/etc/snmp/snmpd.conf on FreeBSD) and replace whole content - with following lines: +- Install package net-snmpd (name may differ based on your distribution). +- Replace config file (by default this is /etc/snmp/snmpd.conf on Linux and + /usr/local/etc/snmp/snmpd.conf on FreeBSD) with snmpd.conf supplied. -###### Config file ##### -rocommunity public 127.0.0.1 -rocommunity6 public ::1 -rwcommunity private 127.0.0.1 - -Do not enable them - being set here they make appropriate OID switch into r/o -#syslocation "Somewhere in the world" -#syscontact "root" - -#SNMPv3 credentials -rouser adminMD5 -rouser adminSHA -rwuser adminMD5AES -rouser adminMD5AES128 -rouser adminMD5DES -createUser adminMD5 MD5 test1234 -createUser adminSHA SHA test1234 -createUser adminMD5AES MD5 test1234 AES test1234 -createUser adminMD5AES128 MD5 test1234 AES test1234 -createUser adminMD5DES MD5 test1234 DES test1234 - -createUser noAuthUser -authuser read noAuthUser noauth -###### End ##### - Before launching daemon make sure that there is no file /var/net-snmp/snmpd.conf -Delete it if exists. Ingoring to to so will fail SNMPv3 tests +Delete it if exists. Ingoring to to so will fail SNMPv3 tests. -Make snmpd bind on localhost only. To do so, pass '127.0.0.1' into it's startup arguments -(see /etc/init.d/snmpd on Linux and set snmpd_flags="127.0.0.1" in rc.conf in FreeBSD). -Otherwise your SNMP daemon will answer SNMPv3 messages from remote clients. +- Launch snmpd (service snmpd start or /etc/init.d/snmpd start). + Alternatively you can start snmpd daemon using following command line: + sudo snmpd -C -c ./snmpd.conf -f -Le -- Launch snmpd (service snmpd start or /etc/init.d/snmpd start) On Windows ---------- diff --git a/ext/snmp/tests/snmpd.conf b/ext/snmp/tests/snmpd.conf new file mode 100644 index 0000000000000..3e91372944c94 --- /dev/null +++ b/ext/snmp/tests/snmpd.conf @@ -0,0 +1,25 @@ +# Listen for connections from the local system only +agentaddress udp:127.0.0.1:161,udp6:[::1]:161 + +rocommunity public 127.0.0.1 +rocommunity6 public ::1 +rwcommunity private 127.0.0.1 + +Do not enable them - being set here they make appropriate OID switch into r/o +#syslocation "Somewhere in the world" +#syscontact "root" + +#SNMPv3 credentials +rouser adminMD5 +rouser adminSHA +rwuser adminMD5AES +rouser adminMD5AES128 +rouser adminMD5DES +createUser adminMD5 MD5 test1234 +createUser adminSHA SHA test1234 +createUser adminMD5AES MD5 test1234 AES test1234 +createUser adminMD5AES128 MD5 test1234 AES test1234 +createUser adminMD5DES MD5 test1234 DES test1234 + +createUser noAuthUser +authuser read noAuthUser noauth From 7a280ee650299d7fdecd292996cab42a2d5b1cf7 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Tue, 23 Aug 2011 20:59:10 +0000 Subject: [PATCH 0607/2394] Update log, marking 5.4 and trunk as XFAIL due to bug #55496 --- sapi/cli/tests/016.phpt | 36 +++++++++++++++++++++++++++++------- 1 file changed, 29 insertions(+), 7 deletions(-) diff --git a/sapi/cli/tests/016.phpt b/sapi/cli/tests/016.phpt index adde106df00e1..31c1a40e4af9d 100644 --- a/sapi/cli/tests/016.phpt +++ b/sapi/cli/tests/016.phpt @@ -59,31 +59,45 @@ foreach ($codes as $key => $code) { echo "\nDone\n"; ?> +--XFAIL-- +https://bugs.php.net/bug.php?id=55496 --EXPECTF-- -------------- Snippet no. 1: -------------- Interactive shell -php > Hello world -php > +php > echo 'Hello world'; +Hello world +php > exit + -------------- Snippet no. 2: -------------- Interactive shell -php > php ' php ' multine +php > echo 'multine +php ' single +php ' quote'; +multine single quote -php > +php > exit + -------------- Snippet no. 3: -------------- Interactive shell -php > <<< > <<< > <<< > <<< > <<< > Here +php > echo << Here +<<< > comes +<<< > the +<<< > doc +<<< > HEREDOC; +Here comes the doc @@ -94,7 +108,11 @@ Snippet no. 4: -------------- Interactive shell -php > php { php { php > Done +php > if (0) { +php { echo "I'm not there"; +php { } +php > echo "Done"; +Done php > -------------- @@ -102,7 +120,11 @@ Snippet no. 5: -------------- Interactive shell -php > php { php { php > I was called! +php > function a_function_with_some_name() { +php { echo "I was called!"; +php { } +php > a_function_with_some_name(); +I was called! php > Done From 562d5ec4a2c822f9e1123d5e2523b8ff2e7c5c5e Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Wed, 24 Aug 2011 06:50:39 +0000 Subject: [PATCH 0608/2394] Fix typo in tests for ldap bug #42060 --- ext/ldap/tests/ldap_control_paged_results_variation2.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/ldap/tests/ldap_control_paged_results_variation2.phpt b/ext/ldap/tests/ldap_control_paged_results_variation2.phpt index 7cc6d9fc92ed3..fee43fc4d6c64 100644 --- a/ext/ldap/tests/ldap_control_paged_results_variation2.phpt +++ b/ext/ldap/tests/ldap_control_paged_results_variation2.phpt @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page with a pagesize=2) +ldap_ldap_control_paged_result() test (fetching the first page with a pagesize=2) --CREDITS-- Jean-Sebastien Hedde --SKIPIF-- @@ -17,7 +17,7 @@ insert_dummy_data($link); $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; var_dump( - ldap_control_paged_results($link, 2), + ldap_control_paged_result($link, 2), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); From d7e0ccbc5a3b8ad67e49d4183d27a311ca2a9537 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 24 Aug 2011 10:15:47 +0000 Subject: [PATCH 0609/2394] Eliminated compile warning "comparison is always false due to limited range of data type" Fixed test failed due to mysql_pconnect throw warning Fixed test failed when host mysql server doesn't listen on 3306 --- ext/mysql/tests/bug55473.phpt | 7 ++++++- ext/mysql/tests/mysql_pconn_kill.phpt | 2 +- ext/mysqlnd/mysqlnd_charset.c | 4 ++-- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ext/mysql/tests/bug55473.phpt b/ext/mysql/tests/bug55473.phpt index d492e68349b5a..3a145fd780dc3 100644 --- a/ext/mysql/tests/bug55473.phpt +++ b/ext/mysql/tests/bug55473.phpt @@ -18,6 +18,11 @@ mysql.allow_persistent=1 $tmp = NULL; $link = NULL; + if ($socket) + $host = sprintf("%s:%s", $host, $socket); + else if ($port) + $host = sprintf("%s:%s", $host, $port); + function connect($host, $user, $passwd) { $conn = mysql_pconnect($host, $user, $passwd); if (!$conn) @@ -68,4 +73,4 @@ OK Warning: mysql_ping(): MySQL server has gone away in %s on line %d reconnect OK -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_pconn_kill.phpt b/ext/mysql/tests/mysql_pconn_kill.phpt index 8543e39d6c2f8..efef4216045ee 100755 --- a/ext/mysql/tests/mysql_pconn_kill.phpt +++ b/ext/mysql/tests/mysql_pconn_kill.phpt @@ -64,7 +64,7 @@ mysql.max_persistent=2 mysql_close($plink); - if (!($plink = mysql_pconnect($myhost, $user, $passwd))) + if (!($plink = @mysql_pconnect($myhost, $user, $passwd))) printf("[009] Cannot create new persistent connection, [%d] %s\n", mysql_errno(), mysql_error()); mysql_select_db($db, $plink); diff --git a/ext/mysqlnd/mysqlnd_charset.c b/ext/mysqlnd/mysqlnd_charset.c index 6792229d10ca2..a87b2a1f4f522 100644 --- a/ext/mysqlnd/mysqlnd_charset.c +++ b/ext/mysqlnd/mysqlnd_charset.c @@ -126,8 +126,8 @@ static unsigned int check_mb_utf8_sequence(const char *start, const char *end) if (!((start[1] ^ 0x80) < 0x40 && (start[2] ^ 0x80) < 0x40 && (start[3] ^ 0x80) < 0x40 && - (c >= 0xf1 || start[1] >= 0x90) && - (c <= 0xf3 || start[1] <= 0x8F))) + (c >= 0xf1 || start[1] >= (char)0x90) && + (c <= 0xf3 || start[1] <= (char)0x8F))) { return 0; /* invalid utf8 character */ } From 4122ef275c964cbc1bdc56c665b0a75eddccc131 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Wed, 24 Aug 2011 15:28:44 +0000 Subject: [PATCH 0610/2394] added iso2022jp-mobile and emoji unsuppoted in unicode 6.0. --- ext/mbstring/config.m4 | 1 + ext/mbstring/config.w32 | 5 +- ext/mbstring/libmbfl/filters/Makefile.am | 2 + ext/mbstring/libmbfl/filters/emoji2uni.h | 1462 +++++++++-------- .../libmbfl/filters/mbfilter_iso2022_jp_ms.c | 4 +- .../filters/mbfilter_iso2022jp_mobile.c | 431 +++++ .../filters/mbfilter_iso2022jp_mobile.h | 43 + .../libmbfl/filters/mbfilter_sjis_mobile.c | 152 +- .../libmbfl/filters/mbfilter_sjis_mobile.h | 4 +- ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 3 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 2 + ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 1 + ext/mbstring/libmbfl/mbfl/mbfl_ident.c | 2 + 13 files changed, 1365 insertions(+), 747 deletions(-) create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c create mode 100644 ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.h diff --git a/ext/mbstring/config.m4 b/ext/mbstring/config.m4 index d27e68bfaff47..5d70d45b80446 100644 --- a/ext/mbstring/config.m4 +++ b/ext/mbstring/config.m4 @@ -246,6 +246,7 @@ AC_DEFUN([PHP_MBSTRING_SETUP_LIBMBFL], [ libmbfl/filters/mbfilter_hz.c libmbfl/filters/mbfilter_iso2022_jp_ms.c libmbfl/filters/mbfilter_iso2022jp_2004.c + libmbfl/filters/mbfilter_iso2022jp_mobile.c libmbfl/filters/mbfilter_iso2022_kr.c libmbfl/filters/mbfilter_iso8859_1.c libmbfl/filters/mbfilter_iso8859_10.c diff --git a/ext/mbstring/config.w32 b/ext/mbstring/config.w32 index ddeb00d61b0a2..6b7e05a3297f9 100644 --- a/ext/mbstring/config.w32 +++ b/ext/mbstring/config.w32 @@ -35,8 +35,9 @@ if (PHP_MBSTRING != "no") { mbfilter_utf7.c mbfilter_utf7imap.c mbfilter_utf8.c mbfilter_utf8_mobile.c \ mbfilter_koi8u.c mbfilter_cp1254.c mbfilter_euc_jp_2004.c \ mbfilter_uuencode.c mbfilter_armscii8.c mbfilter_cp850.c \ - mbfilter_cp5022x.c mbfilter_sjis_open.c mbfilter_sjis_mobile.c mbfilter_sjis_mac.c \ - mbfilter_iso2022jp_2004.c \ + mbfilter_cp5022x.c mbfilter_sjis_open.c mbfilter_sjis_mobile.c \ + mbfilter_sjis_mac.c \ + mbfilter_iso2022jp_2004.c mbfilter_iso2022jp_mobile.c \ mbfilter_tl_jisx0201_jisx0208.c", "mbstring"); ADD_SOURCES("ext/mbstring/libmbfl/mbfl", "mbfilter.c mbfilter_8bit.c \ diff --git a/ext/mbstring/libmbfl/filters/Makefile.am b/ext/mbstring/libmbfl/filters/Makefile.am index 4420b36621d29..33f9049ae946a 100644 --- a/ext/mbstring/libmbfl/filters/Makefile.am +++ b/ext/mbstring/libmbfl/filters/Makefile.am @@ -56,6 +56,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_uhc.c \ mbfilter_iso2022_jp_ms.c \ mbfilter_iso2022jp_2004.c \ + mbfilter_iso2022jp_mobile.c \ mbfilter_gb18030.c \ mbfilter_iso2022_kr.c \ mbfilter_cp866.c \ @@ -91,6 +92,7 @@ libmbfl_filters_la_SOURCES=mbfilter_cp936.c \ mbfilter_hz.h \ mbfilter_iso2022_jp_ms.h \ mbfilter_iso2022jp_2004.h \ + mbfilter_iso2022jp_mobile.h \ mbfilter_iso2022_kr.h \ mbfilter_iso8859_1.h \ mbfilter_iso8859_10.h \ diff --git a/ext/mbstring/libmbfl/filters/emoji2uni.h b/ext/mbstring/libmbfl/filters/emoji2uni.h index 99c7cc2d9d86c..756b409372dc2 100644 --- a/ext/mbstring/libmbfl/filters/emoji2uni.h +++ b/ext/mbstring/libmbfl/filters/emoji2uni.h @@ -1,424 +1,417 @@ -const int mb_tbl_code2uni_docomo1_min = 0x28c2; -const int mb_tbl_code2uni_docomo1_max = 0x29db; +static const int mb_tbl_code2uni_docomo1_min = 0x28c2; +static const int mb_tbl_code2uni_docomo1_max = 0x29db; -const int mb_tbl_code2uni_docomo1[] = { // 0x28c2 - 0x29db - 0x02600, 0x02601, 0x02614, 0x026c4, - 0x026a1, 0x1f300, 0x1f301, 0x1f302, - 0x02648, 0x02649, 0x0264a, 0x0264b, - 0x0264c, 0x0264d, 0x0264e, 0x0264f, - 0x02650, 0x02651, 0x02652, 0x02653, - 0x1f3bd, 0x026be, 0x026f3, 0x1f3be, - 0x026bd, 0x1f3bf, 0x1f3c0, 0x1f3c1, - 0x1f4df, 0x1f683, 0x024c2, 0x1f684, - 0x1f697, 0x1f699, 0x1f68c, 0x1f6a2, - 0x02708, 0x1f3e0, 0x1f3e2, 0x1f3e3, - 0x1f3e5, 0x1f3e6, 0x1f3e7, 0x1f3e8, - 0x1f3ea, 0x026fd, 0x1f17f, 0x1f6a5, - 0x1f6bb, 0x1f374, 0x02615, 0x1f378, - 0x1f37a, 0x1f354, 0x1f460, 0x02702, - 0x1f3a4, 0x1f3a5, 0x02197, 0x1f3a0, - 0x1f3a7, 0x1f3a8, 0x1f3a9, 0x1f3aa, - 0x1f3ab, 0x1f6ac, 0x1f6ad, 0x1f4f7, - 0x1f45c, 0x1f4d6, 0x1f380, 0x1f381, - 0x1f382, 0x0260e, 0x1f4f1, 0x1f4dd, - 0x1f4fa, 0x1f3ae, 0x1f4bf, 0x02665, - 0x02660, 0x02666, 0x02663, 0x1f440, - 0x1f442, 0x0270a, 0x0270c, 0x0270b, - 0x02198, 0x02196, 0x1f463, 0x1f45f, - 0x1f453, 0x0267f, 0x1f311, 0x1f314, - 0x1f313, 0x1f319, 0x1f315, 0x1f436, - 0x1f431, 0x026f5, 0x1f384, 0x02199, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x1f3ac, 0x1f45d, - 0x02712, 0x00000, 0x00000, 0x1f464, - 0x1f4ba, 0x1f303, 0x00000, 0x00000, - 0x00000, 0x1f51c, 0x1f51b, 0x1f51a, - 0x023f0, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x1f4f2, 0x1f4e9, 0x1f4e0, 0x00000, - 0x00000, 0x02709, 0x00000, 0x00000, - 0x1f4b4, 0x1f193, 0x1f194, 0x1f511, - 0x021a9, 0x1f191, 0x1f50d, 0x1f195, - 0x1f6a9, 0x00000, 0x00023, 0x00000, - 0x00031, 0x00032, 0x00033, 0x00034, - 0x00035, 0x00036, 0x00037, 0x00038, - 0x00039, 0x00030, 0x02764, 0x1f493, - 0x1f494, 0x1f495, 0x1f603, 0x1f620, - 0x1f61e, 0x1f616, 0x1f635, 0x02934, - 0x1f3b5, 0x02668, 0x1f4a0, 0x1f48b, - 0x02728, 0x1f4a1, 0x1f4a2, 0x1f44a, - 0x1f4a3, 0x1f3b6, 0x02935, 0x1f4a4, - 0x02757, 0x02049, 0x0203c, 0x1f4a5, - 0x1f4a6, 0x1f4a7, 0x1f4a8, 0x03030, - 0x027b0, 0x1f197, 0x00000, 0x00000, - 0x1f455, 0x1f45b, 0x1f484, 0x1f456, - 0x1f3c2, 0x1f514, 0x1f6aa, 0x1f4b0, - 0x1f4bb, 0x1f48c, 0x1f527, 0x0270f, - 0x1f451, 0x1f48d, 0x023f3, 0x1f6b2, - 0x1f375, 0x0231a, 0x1f614, 0x1f60c, - 0x1f605, 0x1f613, 0x1f621, 0x1f612, - 0x1f60d, 0x1f44d, 0x1f61c, 0x1f609, - 0x1f606, 0x1f623, 0x1f60f, 0x1f62d, - 0x1f622, 0x1f196, 0x1f4ce, 0x000a9, - 0x02122, 0x1f3c3, 0x03299, 0x0267b, - 0x000ae, 0x026a0, 0x1f232, 0x1f233, - 0x1f234, 0x1f235, 0x02194, 0x02195, - 0x1f3eb, 0x1f30a, 0x1f5fb, 0x1f340, - 0x1f352, 0x1f337, 0x1f34c, 0x1f34e, - 0x1f331, 0x1f341, 0x1f338, 0x1f359, - 0x1f370, 0x1f376, 0x1f35c, 0x1f35e, - 0x1f40c, 0x1f424, 0x1f427, 0x1f41f, - 0x1f60b, 0x1f601, 0x1f434, 0x1f437, - 0x1f377, 0x1f631, }; - -const int mb_tbl_code2uni_kddi1_min = 0x24b8; -const int mb_tbl_code2uni_kddi1_max = 0x25c0; +static const unsigned short mb_tbl_code2uni_docomo1[] = { // 0x28c2 - 0x29db + 0x2600, 0x2601, 0x2614, 0x26c4, + 0x26a1, 0xf300, 0xf301, 0xf302, + 0x2648, 0x2649, 0x264a, 0x264b, + 0x264c, 0x264d, 0x264e, 0x264f, + 0x2650, 0x2651, 0x2652, 0x2653, + 0xf3bd, 0x26be, 0x26f3, 0xf3be, + 0x26bd, 0xf3bf, 0xf3c0, 0xf3c1, + 0xf4df, 0xf683, 0x24c2, 0xf684, + 0xf697, 0xf699, 0xf68c, 0xf6a2, + 0x2708, 0xf3e0, 0xf3e2, 0xf3e3, + 0xf3e5, 0xf3e6, 0xf3e7, 0xf3e8, + 0xf3ea, 0x26fd, 0xf17f, 0xf6a5, + 0xf6bb, 0xf374, 0x2615, 0xf378, + 0xf37a, 0xf354, 0xf460, 0x2702, + 0xf3a4, 0xf3a5, 0x2197, 0xf3a0, + 0xf3a7, 0xf3a8, 0xf3a9, 0xf3aa, + 0xf3ab, 0xf6ac, 0xf6ad, 0xf4f7, + 0xf45c, 0xf4d6, 0xf380, 0xf381, + 0xf382, 0x260e, 0xf4f1, 0xf4dd, + 0xf4fa, 0xf3ae, 0xf4bf, 0x2665, + 0x2660, 0x2666, 0x2663, 0xf440, + 0xf442, 0x270a, 0x270c, 0x270b, + 0x2198, 0x2196, 0xf463, 0xf45f, + 0xf453, 0x267f, 0xf311, 0xf314, + 0xf313, 0xf319, 0xf315, 0xf436, + 0xf431, 0x26f5, 0xf384, 0x2199, + 0xEE16, 0xEE17, 0xEE18, 0xEE19, + 0xEE1A, 0xEE1B, 0xf3ac, 0xf45d, + 0x2712, 0xEE1C, 0xEE1D, 0xf464, + 0xf4ba, 0xf303, 0xEE1E, 0xEE1F, + 0xEE20, 0xf51c, 0xf51b, 0xf51a, + 0x23f0, 0xEE21, 0xEE22, 0xEE23, + 0xEE24, 0xEE25, 0xEE26, 0xEE27, + 0xEE28, 0xEE29, 0xEE2A, 0xEE2B, + 0xEE2C, 0xEE2D, 0xEE2E, 0xEE2F, + 0xEE30, 0xEE31, 0xEE32, 0xEE33, + 0xf4f2, 0xf4e9, 0xf4e0, 0xEE10, + 0xEE11, 0x2709, 0xEE12, 0xEE13, + 0xf4b4, 0xf193, 0xf194, 0xf511, + 0x21a9, 0xf191, 0xf50d, 0xf195, + 0xf6a9, 0x0000, 0x0023, 0xE82D, + 0x0031, 0x0032, 0x0033, 0x0034, + 0x0035, 0x0036, 0x0037, 0x0038, + 0x0039, 0x0030, 0x2764, 0xf493, + 0xf494, 0xf495, 0xf603, 0xf620, + 0xf61e, 0xf616, 0xf635, 0x2934, + 0xf3b5, 0x2668, 0xf4a0, 0xf48b, + 0x2728, 0xf4a1, 0xf4a2, 0xf44a, + 0xf4a3, 0xf3b6, 0x2935, 0xf4a4, + 0x2757, 0x2049, 0x203c, 0xf4a5, + 0xf4a6, 0xf4a7, 0xf4a8, 0x3030, + 0x27b0, 0xf197, 0xEE14, 0xEE15, + 0xf455, 0xf45b, 0xf484, 0xf456, + 0xf3c2, 0xf514, 0xf6aa, 0xf4b0, + 0xf4bb, 0xf48c, 0xf527, 0x270f, + 0xf451, 0xf48d, 0x23f3, 0xf6b2, + 0xf375, 0x231a, 0xf614, 0xf60c, + 0xf605, 0xf613, 0xf621, 0xf612, + 0xf60d, 0xf44d, 0xf61c, 0xf609, + 0xf606, 0xf623, 0xf60f, 0xf62d, + 0xf622, 0xf196, 0xf4ce, 0x00a9, + 0x2122, 0xf3c3, 0x3299, 0x267b, + 0x00ae, 0x26a0, 0xf232, 0xf233, + 0xf234, 0xf235, 0x2194, 0x2195, + 0xf3eb, 0xf30a, 0xf5fb, 0xf340, + 0xf352, 0xf337, 0xf34c, 0xf34e, + 0xf331, 0xf341, 0xf338, 0xf359, + 0xf370, 0xf376, 0xf35c, 0xf35e, + 0xf40c, 0xf424, 0xf427, 0xf41f, + 0xf60b, 0xf601, 0xf434, 0xf437, + 0xf377, 0xf631, }; +static const int mb_tbl_code2uni_kddi1_min = 0x24b8; +static const int mb_tbl_code2uni_kddi1_max = 0x25c6; -const int mb_tbl_code2uni_kddi1[] = { // 0x24b8 - 0x25c0 - 0x1f342, 0x1f4bc, 0x026f2, 0x026fa, - 0x1f004, 0x1f19a, 0x1f3c6, 0x1f422, - 0x1f1ea, 0x1f1f7, 0x1f6a7, 0x1f6c0, - 0x1f38c, 0x1f306, 0x1f423, 0x1f4b9, - 0x1f46e, 0x1f3e3, 0x1f3e5, 0x1f3eb, - 0x1f3e8, 0x1f6a2, 0x1f51e, 0x1f4f6, - 0x1f192, 0x1f239, 0x1f202, 0x1f194, - 0x1f235, 0x1f233, 0x1f22f, 0x1f23a, - 0x1f446, 0x1f447, 0x1f52e, 0x1f4f3, - 0x1f4f4, 0x1f4dd, 0x1f454, 0x1f33a, - 0x1f490, 0x1f335, 0x1f376, 0x1f37b, - 0x03297, 0x1f48a, 0x1f388, 0x1f389, - 0x00000, 0x1f452, 0x1f462, 0x1f485, - 0x1f487, 0x1f488, 0x1f458, 0x1f459, - 0x02665, 0x1f496, 0x1f499, 0x1f49a, - 0x1f49b, 0x1f49c, 0x02728, 0x1f3bf, - 0x02b55, 0x1f375, 0x1f35e, 0x1f366, - 0x1f35f, 0x1f361, 0x1f358, 0x1f35a, - 0x1f35d, 0x1f35b, 0x1f362, 0x1f363, - 0x1f34e, 0x1f34a, 0x1f345, 0x1f346, - 0x1f371, 0x1f372, 0x1f60f, 0x1f614, - 0x1f624, 0x1f623, 0x1f616, 0x1f62a, - 0x1f60c, 0x1f628, 0x1f637, 0x1f633, - 0x1f612, 0x1f632, 0x1f630, 0x1f3bc, - 0x1f60a, 0x1f61a, 0x1f618, 0x1f443, - 0x1f444, 0x1f64f, 0x1f44f, 0x1f44c, - 0x1f44e, 0x1f44b, 0x1f645, 0x1f646, - 0x1f647, 0x1f491, 0x1f46f, 0x1f3ba, - 0x1f3b1, 0x1f3ca, 0x1f692, 0x1f691, - 0x1f693, 0x1f3a2, 0x1f38d, 0x1f38e, - 0x1f393, 0x1f392, 0x1f38f, 0x1f302, - 0x1f470, 0x1f367, 0x1f387, 0x1f41a, - 0x1f390, 0x1f383, 0x1f391, 0x1f385, - 0x1f303, 0x1f308, 0x1f3e9, 0x1f305, - 0x1f3a9, 0x1f3ec, 0x1f3ef, 0x1f3f0, - 0x1f3ed, 0x1f1eb, 0x1f1e9, 0x1f1ee, - 0x1f1ec, 0x1f1e8, 0x1f1f0, 0x1f471, - 0x1f472, 0x1f473, 0x1f474, 0x1f475, - 0x1f476, 0x1f477, 0x1f478, 0x1f42c, - 0x1f483, 0x1f420, 0x1f41b, 0x1f418, - 0x1f428, 0x1f42e, 0x1f40d, 0x1f414, - 0x1f417, 0x1f42b, 0x1f170, 0x1f171, - 0x1f17e, 0x1f18e, 0x1f463, 0x1f45f, - 0x1f6a9, 0x02934, 0x02935, 0x02049, - 0x0203c, 0x027b0, 0x1f348, 0x1f34d, - 0x1f347, 0x1f34c, 0x1f33d, 0x1f344, - 0x1f330, 0x1f351, 0x1f360, 0x1f355, - 0x1f357, 0x1f38b, 0x1f379, 0x1f432, - 0x1f3b9, 0x1f3c4, 0x1f3a3, 0x1f3b3, - 0x1f479, 0x1f47a, 0x1f43c, 0x1f445, - 0x1f43d, 0x1f33c, 0x1f368, 0x1f369, - 0x1f36a, 0x1f36b, 0x1f36c, 0x1f36d, - 0x1f648, 0x1f64a, 0x1f649, 0x1f30b, - 0x1f49d, 0x1f524, 0x1f36e, 0x1f41d, - 0x1f41e, 0x1f36f, 0x1f34f, 0x1f4b8, - 0x1f4ab, 0x1f621, 0x1f63e, 0x1f30c, - 0x1f63d, 0x1f63a, 0x1f4e9, 0x1f639, - 0x1f602, 0x1f63b, 0x1f640, 0x1f629, - 0x1f63f, 0x1f622, 0x1f63c, 0x1f457, - 0x1f5ff, 0x1f689, 0x1f3b4, 0x1f0cf, - 0x1f364, 0x1f4e7, 0x1f6b6, 0x1f6a8, - 0x00000, 0x1f493, 0x1f425, 0x1f456, - 0x1f48c, 0x0267b, 0x02194, 0x02195, - 0x1f30a, 0x1f331, 0x1f40c, 0x1f638, - 0x1f601, 0x00000, 0x1f33f, 0x0270a, - 0x00023, 0x1f64b, 0x1f64c, 0x1f64d, - 0x1f64e, }; -const int mb_tbl_code2uni_kddi2_min = 0x26ec; -const int mb_tbl_code2uni_kddi2_max = 0x2863; +static const unsigned short mb_tbl_code2uni_kddi1[] = { // 0x24b8 - 0x25c6 + 0xf342, 0xf4bc, 0x26f2, 0x26fa, + 0xf004, 0xf19a, 0xf3c6, 0xf422, + 0xf1ea, 0xf1f7, 0xf6a7, 0xf6c0, + 0xf38c, 0xf306, 0xf423, 0xf4b9, + 0xf46e, 0xf3e3, 0xf3e5, 0xf3eb, + 0xf3e8, 0xf6a2, 0xf51e, 0xf4f6, + 0xf192, 0xf239, 0xf202, 0xf194, + 0xf235, 0xf233, 0xf22f, 0xf23a, + 0xf446, 0xf447, 0xf52e, 0xf4f3, + 0xf4f4, 0xf4dd, 0xf454, 0xf33a, + 0xf490, 0xf335, 0xf376, 0xf37b, + 0x3297, 0xf48a, 0xf388, 0xf389, + 0xEE42, 0xf452, 0xf462, 0xf485, + 0xf487, 0xf488, 0xf458, 0xf459, + 0x2665, 0xf496, 0xf499, 0xf49a, + 0xf49b, 0xf49c, 0x2728, 0xf3bf, + 0x2b55, 0xf375, 0xf35e, 0xf366, + 0xf35f, 0xf361, 0xf358, 0xf35a, + 0xf35d, 0xf35b, 0xf362, 0xf363, + 0xf34e, 0xf34a, 0xf345, 0xf346, + 0xf371, 0xf372, 0xf60f, 0xf614, + 0xf624, 0xf623, 0xf616, 0xf62a, + 0xf60c, 0xf628, 0xf637, 0xf633, + 0xf612, 0xf632, 0xf630, 0xf3bc, + 0xf60a, 0xf61a, 0xf618, 0xf443, + 0xf444, 0xf64f, 0xf44f, 0xf44c, + 0xf44e, 0xf44b, 0xf645, 0xf646, + 0xf647, 0xf491, 0xf46f, 0xf3ba, + 0xf3b1, 0xf3ca, 0xf692, 0xf691, + 0xf693, 0xf3a2, 0xf38d, 0xf38e, + 0xf393, 0xf392, 0xf38f, 0xf302, + 0xf470, 0xf367, 0xf387, 0xf41a, + 0xf390, 0xf383, 0xf391, 0xf385, + 0xf303, 0xf308, 0xf3e9, 0xf305, + 0xf3a9, 0xf3ec, 0xf3ef, 0xf3f0, + 0xf3ed, 0xf1eb, 0xf1e9, 0xf1ee, + 0xf1ec, 0xf1e8, 0xf1f0, 0xf471, + 0xf472, 0xf473, 0xf474, 0xf475, + 0xf476, 0xf477, 0xf478, 0xf42c, + 0xf483, 0xf420, 0xf41b, 0xf418, + 0xf428, 0xf42e, 0xf40d, 0xf414, + 0xf417, 0xf42b, 0xf170, 0xf171, + 0xf17e, 0xf18e, 0xf463, 0xf45f, + 0xf6a9, 0x2934, 0x2935, 0x2049, + 0x203c, 0x27b0, 0xf348, 0xf34d, + 0xf347, 0xf34c, 0xf33d, 0xf344, + 0xf330, 0xf351, 0xf360, 0xf355, + 0xf357, 0xf38b, 0xf379, 0xf432, + 0xf3b9, 0xf3c4, 0xf3a3, 0xf3b3, + 0xf479, 0xf47a, 0xf43c, 0xf445, + 0xf43d, 0xf33c, 0xf368, 0xf369, + 0xf36a, 0xf36b, 0xf36c, 0xf36d, + 0xf648, 0xf64a, 0xf649, 0xf30b, + 0xf49d, 0xf524, 0xf36e, 0xf41d, + 0xf41e, 0xf36f, 0xf34f, 0xf4b8, + 0xf4ab, 0xf621, 0xf63e, 0xf30c, + 0xf63d, 0xf63a, 0xf4e9, 0xf639, + 0xf602, 0xf63b, 0xf640, 0xf629, + 0xf63f, 0xf622, 0xf63c, 0xf457, + 0xf5ff, 0xf689, 0xf3b4, 0xf0cf, + 0xf364, 0xf4e7, 0xf6b6, 0xf6a8, + 0xEE43, 0xf493, 0xf425, 0xf456, + 0xf48c, 0x267b, 0x2194, 0x2195, + 0xf30a, 0xf331, 0xf40c, 0xf638, + 0xf601, 0xEE44, 0xf33f, 0x270a, + 0x0023, 0xf64b, 0xf64c, 0xf64d, + 0xf64e, 0xEE45, 0xEE46, 0xEE47, + 0xEE48, 0xEE49, 0xEE4A}; +static const int mb_tbl_code2uni_kddi2_min = 0x26ec; +static const int mb_tbl_code2uni_kddi2_max = 0x2863; -const int mb_tbl_code2uni_kddi2[] = { // 0x26ec - 0x2863 - 0x1f320, 0x1f300, 0x1f6a5, 0x1f3c3, - 0x02747, 0x1f3a1, 0x1f3b0, 0x1f38a, - 0x1f433, 0x1f603, 0x1f620, 0x1f62d, - 0x1f62b, 0x1f4a4, 0x1f4a1, 0x1f494, - 0x1f495, 0x02734, 0x1f4a3, 0x1f525, - 0x023f3, 0x1f6ac, 0x1f6ad, 0x0267f, - 0x1f530, 0x026a0, 0x02757, 0x02753, - 0x026d4, 0x026c4, 0x1f319, 0x026a1, - 0x02600, 0x1f31b, 0x02744, 0x02b50, - 0x02614, 0x02601, 0x026c5, 0x02648, - 0x02649, 0x0264a, 0x0264b, 0x0264c, - 0x0264d, 0x0264e, 0x0264f, 0x02650, - 0x02651, 0x02652, 0x02653, 0x026ce, - 0x1f45c, 0x1f4d4, 0x1f3ab, 0x1f4d6, - 0x1f4ce, 0x0270f, 0x1f4d0, 0x1f3e7, - 0x1f3ea, 0x1f6bb, 0x1f17f, 0x1f68f, - 0x1f4e1, 0x02693, 0x1f3e6, 0x1f3e0, - 0x1f374, 0x1f3e2, 0x1f6b2, 0x1f68c, - 0x1f685, 0x1f697, 0x1f69a, 0x02708, - 0x026f5, 0x1f683, 0x026bd, 0x1f3be, - 0x1f3c2, 0x1f3c1, 0x026be, 0x1f3c8, - 0x02668, 0x1f3ee, 0x1f3ac, 0x1f309, - 0x1f5fc, 0x1f377, 0x1f378, 0x1f37a, - 0x1f356, 0x1f3af, 0x1f3ae, 0x1f4b0, - 0x1f3b2, 0x1f384, 0x1f338, 0x1f47b, - 0x1f1ef, 0x1f349, 0x1f341, 0x1f381, - 0x1f370, 0x1f373, 0x1f352, 0x1f421, - 0x1f353, 0x1f359, 0x1f354, 0x1f430, - 0x1f434, 0x1f435, 0x1f438, 0x1f431, - 0x1f427, 0x1f41c, 0x1f437, 0x1f429, - 0x1f424, 0x1f436, 0x1f334, 0x1f33b, - 0x1f337, 0x1f4a2, 0x1f4a7, 0x1f61c, - 0x1f198, 0x1f4aa, 0x1f498, 0x1f48b, - 0x1f47e, 0x1f365, 0x1f43e, 0x1f47f, - 0x1f4ae, 0x03299, 0x1f4af, 0x1f44a, - 0x1f4a8, 0x1f4a9, 0x0261d, 0x1f250, - 0x1f480, 0x1f44d, 0x1f469, 0x0263a, - 0x1f468, 0x1f4ac, 0x1f453, 0x1f448, - 0x1f449, 0x1f46a, 0x1f4fa, 0x1f3a4, - 0x1f45b, 0x1f3b6, 0x1f3b8, 0x1f3bb, - 0x1f3a7, 0x1f484, 0x1f52b, 0x1f486, - 0x1f4bf, 0x1f45a, 0x1f47d, 0x1f199, - 0x1f489, 0x1f50a, 0x1f514, 0x1f340, - 0x1f48d, 0x1f4f7, 0x02702, 0x1f3a5, - 0x1f50d, 0x1f511, 0x1f460, 0x1f4ea, - 0x1f512, 0x1f4db, 0x1f4de, 0x1f4e6, - 0x1f4e0, 0x02709, 0x00031, 0x00032, - 0x00033, 0x00034, 0x00035, 0x00036, - 0x00037, 0x00038, 0x00039, 0x1f51f, - 0x00000, 0x025c0, 0x025b6, 0x023ea, - 0x023e9, 0x025ab, 0x025aa, 0x02139, - 0x025fd, 0x025fe, 0x1f538, 0x1f539, - 0x025fb, 0x025fc, 0x026aa, 0x026ab, - 0x02795, 0x02796, 0x02733, 0x02b06, - 0x02b07, 0x1f6ab, 0x1f53d, 0x1f53c, - 0x023ec, 0x023eb, 0x1f536, 0x1f537, - 0x02b1c, 0x02b1b, 0x1f534, 0x1f535, - 0x02196, 0x02198, 0x02122, 0x02716, - 0x0274c, 0x0274e, 0x027a1, 0x02b05, - 0x02797, 0x02197, 0x02199, 0x02714, - 0x000a9, 0x000ae, 0x1f53a, 0x1f53b, - 0x021aa, 0x021a9, 0x02705, 0x1f4dc, - 0x1f4cd, 0x1f4c3, 0x1f4be, 0x1f4c5, - 0x1f4cb, 0x1f4d7, 0x1f4d8, 0x1f4d9, - 0x1f4d5, 0x1f4c4, 0x1f4c6, 0x1f4d3, - 0x1f4c7, 0x1f4cc, 0x1f4d2, 0x1f4da, - 0x1f4cf, 0x026fd, 0x1f5fe, 0x1f1fa, - 0x1f4ca, 0x1f4c8, 0x1f4c9, 0x00000, - 0x1f193, 0x1f4b2, 0x0231a, 0x0231b, - 0x1f4b3, 0x1f4b4, 0x1f4f9, 0x1f52a, - 0x1f4fc, 0x1f529, 0x1f4bd, 0x1f526, - 0x1f50b, 0x1f4b5, 0x00000, 0x1f527, - 0x1f4f1, 0x1f50c, 0x1f517, 0x1f4f0, - 0x02003, 0x02002, 0x02005, 0x1f4c1, - 0x1f4c2, 0x1f4e8, 0x1f4e4, 0x1f4e5, - 0x023f0, 0x02764, 0x0260e, 0x02615, - 0x1f301, 0x026f3, 0x1f3c0, 0x1f4df, - 0x1f3a8, 0x1f3ad, 0x1f3aa, 0x1f380, - 0x1f382, 0x02660, 0x02666, 0x02663, - 0x1f440, 0x1f442, 0x0270c, 0x0270b, - 0x1f311, 0x1f314, 0x1f313, 0x1f191, - 0x00030, 0x1f197, 0x1f635, 0x1f49e, - 0x1f4a5, 0x1f4a6, 0x00000, 0x1f30f, - 0x1f35c, 0x00000, 0x1f510, 0x1f520, - 0x1f521, 0x1f522, 0x1f523, 0x1f251, - 0x02611, 0x02712, 0x1f518, 0x1f50e, - 0x1f519, 0x1f516, 0x1f4f2, 0x1f3e1, - 0x1f4eb, 0x1f4d1, 0x1f50f, 0x1f503, - 0x1f195, 0x1f455, 0x1f45e, 0x1f4bb, - 0x1f4fb, 0x1f339, 0x026ea, 0x1f687, - 0x1f5fb, 0x1f3b5, 0x1f47c, 0x1f42f, - 0x1f43b, 0x1f42d, 0x1f609, 0x1f60d, - 0x1f631, 0x1f613, 0x1f419, 0x1f680, - 0x1f451, 0x1f48f, 0x1f528, 0x1f386, +static const unsigned short mb_tbl_code2uni_kddi2[] = { // 0x26ec - 0x2863 + 0xf320, 0xf300, 0xf6a5, 0xf3c3, + 0x2747, 0xf3a1, 0xf3b0, 0xf38a, + 0xf433, 0xf603, 0xf620, 0xf62d, + 0xf62b, 0xf4a4, 0xf4a1, 0xf494, + 0xf495, 0x2734, 0xf4a3, 0xf525, + 0x23f3, 0xf6ac, 0xf6ad, 0x267f, + 0xf530, 0x26a0, 0x2757, 0x2753, + 0x26d4, 0x26c4, 0xf319, 0x26a1, + 0x2600, 0xf31b, 0x2744, 0x2b50, + 0x2614, 0x2601, 0x26c5, 0x2648, + 0x2649, 0x264a, 0x264b, 0x264c, + 0x264d, 0x264e, 0x264f, 0x2650, + 0x2651, 0x2652, 0x2653, 0x26ce, + 0xf45c, 0xf4d4, 0xf3ab, 0xf4d6, + 0xf4ce, 0x270f, 0xf4d0, 0xf3e7, + 0xf3ea, 0xf6bb, 0xf17f, 0xf68f, + 0xf4e1, 0x2693, 0xf3e6, 0xf3e0, + 0xf374, 0xf3e2, 0xf6b2, 0xf68c, + 0xf685, 0xf697, 0xf69a, 0x2708, + 0x26f5, 0xf683, 0x26bd, 0xf3be, + 0xf3c2, 0xf3c1, 0x26be, 0xf3c8, + 0x2668, 0xf3ee, 0xf3ac, 0xf309, + 0xf5fc, 0xf377, 0xf378, 0xf37a, + 0xf356, 0xf3af, 0xf3ae, 0xf4b0, + 0xf3b2, 0xf384, 0xf338, 0xf47b, + 0xf1ef, 0xf349, 0xf341, 0xf381, + 0xf370, 0xf373, 0xf352, 0xf421, + 0xf353, 0xf359, 0xf354, 0xf430, + 0xf434, 0xf435, 0xf438, 0xf431, + 0xf427, 0xf41c, 0xf437, 0xf429, + 0xf424, 0xf436, 0xf334, 0xf33b, + 0xf337, 0xf4a2, 0xf4a7, 0xf61c, + 0xf198, 0xf4aa, 0xf498, 0xf48b, + 0xf47e, 0xf365, 0xf43e, 0xf47f, + 0xf4ae, 0x3299, 0xf4af, 0xf44a, + 0xf4a8, 0xf4a9, 0x261d, 0xf250, + 0xf480, 0xf44d, 0xf469, 0x263a, + 0xf468, 0xf4ac, 0xf453, 0xf448, + 0xf449, 0xf46a, 0xf4fa, 0xf3a4, + 0xf45b, 0xf3b6, 0xf3b8, 0xf3bb, + 0xf3a7, 0xf484, 0xf52b, 0xf486, + 0xf4bf, 0xf45a, 0xf47d, 0xf199, + 0xf489, 0xf50a, 0xf514, 0xf340, + 0xf48d, 0xf4f7, 0x2702, 0xf3a5, + 0xf50d, 0xf511, 0xf460, 0xf4ea, + 0xf512, 0xf4db, 0xf4de, 0xf4e6, + 0xf4e0, 0x2709, 0x0031, 0x0032, + 0x0033, 0x0034, 0x0035, 0x0036, + 0x0037, 0x0038, 0x0039, 0xf51f, + 0xE82D, 0x25c0, 0x25b6, 0x23ea, + 0x23e9, 0x25ab, 0x25aa, 0x2139, + 0x25fd, 0x25fe, 0xf538, 0xf539, + 0x25fb, 0x25fc, 0x26aa, 0x26ab, + 0x2795, 0x2796, 0x2733, 0x2b06, + 0x2b07, 0xf6ab, 0xf53d, 0xf53c, + 0x23ec, 0x23eb, 0xf536, 0xf537, + 0x2b1c, 0x2b1b, 0xf534, 0xf535, + 0x2196, 0x2198, 0x2122, 0x2716, + 0x274c, 0x274e, 0x27a1, 0x2b05, + 0x2797, 0x2197, 0x2199, 0x2714, + 0x00a9, 0x00ae, 0xf53a, 0xf53b, + 0x21aa, 0x21a9, 0x2705, 0xf4dc, + 0xf4cd, 0xf4c3, 0xf4be, 0xf4c5, + 0xf4cb, 0xf4d7, 0xf4d8, 0xf4d9, + 0xf4d5, 0xf4c4, 0xf4c6, 0xf4d3, + 0xf4c7, 0xf4cc, 0xf4d2, 0xf4da, + 0xf4cf, 0x26fd, 0xf5fe, 0xf1fa, + 0xf4ca, 0xf4c8, 0xf4c9, 0xEE40, + 0xf193, 0xf4b2, 0x231a, 0x231b, + 0xf4b3, 0xf4b4, 0xf4f9, 0xf52a, + 0xf4fc, 0xf529, 0xf4bd, 0xf526, + 0xf50b, 0xf4b5, 0xE83C, 0xf527, + 0xf4f1, 0xf50c, 0xf517, 0xf4f0, + 0x2003, 0x2002, 0x2005, 0xf4c1, + 0xf4c2, 0xf4e8, 0xf4e4, 0xf4e5, + 0x23f0, 0x2764, 0x260e, 0x2615, + 0xf301, 0x26f3, 0xf3c0, 0xf4df, + 0xf3a8, 0xf3ad, 0xf3aa, 0xf380, + 0xf382, 0x2660, 0x2666, 0x2663, + 0xf440, 0xf442, 0x270c, 0x270b, + 0xf311, 0xf314, 0xf313, 0xf191, + 0x0030, 0xf197, 0xf635, 0xf49e, + 0xf4a5, 0xf4a6, 0xEE41, 0xf30f, + 0xf35c, 0xEB89, 0xf510, 0xf520, + 0xf521, 0xf522, 0xf523, 0xf251, + 0x2611, 0x2712, 0xf518, 0xf50e, + 0xf519, 0xf516, 0xf4f2, 0xf3e1, + 0xf4eb, 0xf4d1, 0xf50f, 0xf503, + 0xf195, 0xf455, 0xf45e, 0xf4bb, + 0xf4fb, 0xf339, 0x26ea, 0xf687, + 0xf5fb, 0xf3b5, 0xf47c, 0xf42f, + 0xf43b, 0xf42d, 0xf609, 0xf60d, + 0xf631, 0xf613, 0xf419, 0xf680, + 0xf451, 0xf48f, 0xf528, 0xf386, }; -const int mb_tbl_code2uni_sb1_min = 0x27a9; -const int mb_tbl_code2uni_sb1_max = 0x285a; +static const int mb_tbl_code2uni_sb1_min = 0x27a9; +static const int mb_tbl_code2uni_sb1_max = 0x2861; + +static const unsigned short mb_tbl_code2uni_sb1[] = { // 0x27a9 - 0x2861 + 0xf4eb, 0xf4ee, 0xf4e9, 0xf4f2, + 0xf61c, 0xf60d, 0xf631, 0xf613, + 0xf435, 0xf419, 0xf437, 0xf47d, + 0xf680, 0xf451, 0xf4a1, 0xf340, + 0xf48f, 0xf381, 0xf52b, 0xf50d, + 0xf3c3, 0xf528, 0xf386, 0xf341, + 0xf342, 0xf47f, 0xf47b, 0xf480, + 0xf525, 0xf4bc, 0xf4ba, 0xf354, + 0x26f2, 0x26fa, 0x2668, 0xf3a1, + 0xf3ab, 0xf4bf, 0xf4c0, 0xf4fb, + 0xf4fc, 0xf4fa, 0xf47e, 0x303d, + 0xf004, 0xf19a, 0xf4b0, 0xf3af, + 0xf3c6, 0xf3c1, 0xf3b0, 0xf40e, + 0xf6a4, 0xf6b2, 0xf6a7, 0xf6b9, + 0xf6ba, 0xf6bc, 0xf489, 0xf4a4, + 0x26a1, 0xf460, 0xf6c0, 0xf6bd, + 0xf50a, 0xf4e2, 0xf38c, 0xf512, + 0xf513, 0xf306, 0xf373, 0xf4d6, + 0xf4b1, 0xf4b9, 0xf4e1, 0xf4aa, + 0xf3e6, 0xf6a5, 0xf17f, 0xf68f, + 0xf6bb, 0xf46e, 0xf3e3, 0xf3e7, + 0xf3e5, 0xf3ea, 0xf3eb, 0xf3e8, + 0xf68c, 0xf695, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0xf6b6, + 0xf6a2, 0xf201, 0xf49f, 0x2734, + 0x2733, 0xf51e, 0xf6ad, 0xf530, + 0x267f, 0xf4f6, 0x2665, 0x2666, + 0x2660, 0x2663, 0x0023, 0x0000, + 0xf195, 0xf199, 0xf192, 0xf236, + 0xf21a, 0xf237, 0xf238, 0xf534, + 0xf532, 0xf533, 0x0031, 0x0032, + 0x0033, 0x0034, 0x0035, 0x0036, + 0x0037, 0x0038, 0x0039, 0x0030, + 0xf250, 0xf239, 0xf202, 0xf194, + 0xf235, 0xf233, 0xf22f, 0xf23a, + 0xf446, 0xf447, 0xf448, 0xf449, + 0x2b06, 0x2b07, 0x27a1, 0x2b05, + 0x2197, 0x2196, 0x2198, 0x2199, + 0x25b6, 0x25c0, 0x23e9, 0x23ea, + 0xf52f, 0x2648, 0x2649, 0x264a, + 0x264b, 0x264c, 0x264d, 0x264e, + 0x264f, 0x2650, 0x2651, 0x2652, + 0x2653, 0x26ce, 0xf51d, 0xf197, + 0x00a9, 0x00ae, 0xf4f3, 0xf4f4, + 0x26a0, 0xf481, 0xEE77, 0xEE78, + 0xEE79, 0xEE7A, 0xEE7B, 0xEE7C, + 0xEE7D}; -const int mb_tbl_code2uni_sb1[] = { // 0x27a9 - 0x285a - 0x1f4eb, 0x1f4ee, 0x1f4e9, 0x1f4f2, - 0x1f61c, 0x1f60d, 0x1f631, 0x1f613, - 0x1f435, 0x1f419, 0x1f437, 0x1f47d, - 0x1f680, 0x1f451, 0x1f4a1, 0x1f340, - 0x1f48f, 0x1f381, 0x1f52b, 0x1f50d, - 0x1f3c3, 0x1f528, 0x1f386, 0x1f341, - 0x1f342, 0x1f47f, 0x1f47b, 0x1f480, - 0x1f525, 0x1f4bc, 0x1f4ba, 0x1f354, - 0x026f2, 0x026fa, 0x02668, 0x1f3a1, - 0x1f3ab, 0x1f4bf, 0x1f4c0, 0x1f4fb, - 0x1f4fc, 0x1f4fa, 0x1f47e, 0x0303d, - 0x1f004, 0x1f19a, 0x1f4b0, 0x1f3af, - 0x1f3c6, 0x1f3c1, 0x1f3b0, 0x1f40e, - 0x1f6a4, 0x1f6b2, 0x1f6a7, 0x1f6b9, - 0x1f6ba, 0x1f6bc, 0x1f489, 0x1f4a4, - 0x026a1, 0x1f460, 0x1f6c0, 0x1f6bd, - 0x1f50a, 0x1f4e2, 0x1f38c, 0x1f512, - 0x1f513, 0x1f306, 0x1f373, 0x1f4d6, - 0x1f4b1, 0x1f4b9, 0x1f4e1, 0x1f4aa, - 0x1f3e6, 0x1f6a5, 0x1f17f, 0x1f68f, - 0x1f6bb, 0x1f46e, 0x1f3e3, 0x1f3e7, - 0x1f3e5, 0x1f3ea, 0x1f3eb, 0x1f3e8, - 0x1f68c, 0x1f695, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x1f6b6, - 0x1f6a2, 0x1f201, 0x1f49f, 0x02734, - 0x02733, 0x1f51e, 0x1f6ad, 0x1f530, - 0x0267f, 0x1f4f6, 0x02665, 0x02666, - 0x02660, 0x02663, 0x00023, 0x00000, - 0x1f195, 0x1f199, 0x1f192, 0x1f236, - 0x1f21a, 0x1f237, 0x1f238, 0x1f534, - 0x1f532, 0x1f533, 0x00031, 0x00032, - 0x00033, 0x00034, 0x00035, 0x00036, - 0x00037, 0x00038, 0x00039, 0x00030, - 0x1f250, 0x1f239, 0x1f202, 0x1f194, - 0x1f235, 0x1f233, 0x1f22f, 0x1f23a, - 0x1f446, 0x1f447, 0x1f448, 0x1f449, - 0x02b06, 0x02b07, 0x027a1, 0x02b05, - 0x02197, 0x02196, 0x02198, 0x02199, - 0x025b6, 0x025c0, 0x023e9, 0x023ea, - 0x1f52f, 0x02648, 0x02649, 0x0264a, - 0x0264b, 0x0264c, 0x0264d, 0x0264e, - 0x0264f, 0x02650, 0x02651, 0x02652, - 0x02653, 0x026ce, 0x1f51d, 0x1f197, - 0x000a9, 0x000ae, 0x1f4f3, 0x1f4f4, - 0x026a0, 0x1f481, }; -const int mb_tbl_code2uni_sb2_min = 0x2921; -const int mb_tbl_code2uni_sb2_max = 0x29cc; +static const int mb_tbl_code2uni_sb2_min = 0x2921; +static const int mb_tbl_code2uni_sb2_max = 0x29cc; -const int mb_tbl_code2uni_sb2[] = { // 0x2921 - 0x29cc - 0x1f466, 0x1f467, 0x1f48b, 0x1f468, - 0x1f469, 0x1f455, 0x1f45f, 0x1f4f7, - 0x0260e, 0x1f4f1, 0x1f4e0, 0x1f4bb, - 0x1f44a, 0x1f44d, 0x0261d, 0x0270a, - 0x0270c, 0x0270b, 0x1f3bf, 0x026f3, - 0x1f3be, 0x026be, 0x1f3c4, 0x026bd, - 0x1f41f, 0x1f434, 0x1f697, 0x026f5, - 0x02708, 0x1f683, 0x1f685, 0x02753, - 0x02757, 0x02764, 0x1f494, 0x1f550, - 0x1f551, 0x1f552, 0x1f553, 0x1f554, - 0x1f555, 0x1f556, 0x1f557, 0x1f558, - 0x1f559, 0x1f55a, 0x1f55b, 0x1f338, - 0x1f531, 0x1f339, 0x1f384, 0x1f48d, - 0x1f48e, 0x1f3e0, 0x026ea, 0x1f3e2, - 0x1f689, 0x026fd, 0x1f5fb, 0x1f3a4, - 0x1f3a5, 0x1f3b5, 0x1f511, 0x1f3b7, - 0x1f3b8, 0x1f3ba, 0x1f374, 0x1f378, - 0x02615, 0x1f370, 0x1f37a, 0x026c4, - 0x02601, 0x02600, 0x02614, 0x1f319, - 0x1f304, 0x1f47c, 0x1f431, 0x1f42f, - 0x1f43b, 0x1f436, 0x1f42d, 0x1f433, - 0x1f427, 0x1f60a, 0x1f603, 0x1f61e, - 0x1f620, 0x1f4a9, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x1f4dd, - 0x1f454, 0x1f33a, 0x1f337, 0x1f33b, - 0x1f490, 0x1f334, 0x1f335, 0x1f6be, - 0x1f3a7, 0x1f376, 0x1f37b, 0x03297, - 0x1f6ac, 0x1f48a, 0x1f388, 0x1f4a3, - 0x1f389, 0x02702, 0x1f380, 0x03299, - 0x1f4bd, 0x1f4e3, 0x1f452, 0x1f457, - 0x1f461, 0x1f462, 0x1f484, 0x1f485, - 0x1f486, 0x1f487, 0x1f488, 0x1f458, - 0x1f459, 0x1f45c, 0x1f3ac, 0x1f514, - 0x1f3b6, 0x1f493, 0x1f497, 0x1f498, - 0x1f499, 0x1f49a, 0x1f49b, 0x1f49c, - 0x02728, 0x02b50, 0x1f4a8, 0x1f4a6, - 0x02b55, 0x0274c, 0x1f4a2, 0x1f31f, - 0x02754, 0x02755, 0x1f375, 0x1f35e, - 0x1f366, 0x1f35f, 0x1f361, 0x1f358, - 0x1f35a, 0x1f35d, 0x1f35c, 0x1f35b, - 0x1f359, 0x1f362, 0x1f363, 0x1f34e, - 0x1f34a, 0x1f353, 0x1f349, 0x1f345, - 0x1f346, 0x1f382, 0x1f371, 0x1f372, +static const unsigned short mb_tbl_code2uni_sb2[] = { // 0x2921 - 0x29cc + 0xf466, 0xf467, 0xf48b, 0xf468, + 0xf469, 0xf455, 0xf45f, 0xf4f7, + 0x260e, 0xf4f1, 0xf4e0, 0xf4bb, + 0xf44a, 0xf44d, 0x261d, 0x270a, + 0x270c, 0x270b, 0xf3bf, 0x26f3, + 0xf3be, 0x26be, 0xf3c4, 0x26bd, + 0xf41f, 0xf434, 0xf697, 0x26f5, + 0x2708, 0xf683, 0xf685, 0x2753, + 0x2757, 0x2764, 0xf494, 0xf550, + 0xf551, 0xf552, 0xf553, 0xf554, + 0xf555, 0xf556, 0xf557, 0xf558, + 0xf559, 0xf55a, 0xf55b, 0xf338, + 0xf531, 0xf339, 0xf384, 0xf48d, + 0xf48e, 0xf3e0, 0x26ea, 0xf3e2, + 0xf689, 0x26fd, 0xf5fb, 0xf3a4, + 0xf3a5, 0xf3b5, 0xf511, 0xf3b7, + 0xf3b8, 0xf3ba, 0xf374, 0xf378, + 0x2615, 0xf370, 0xf37a, 0x26c4, + 0x2601, 0x2600, 0x2614, 0xf319, + 0xf304, 0xf47c, 0xf431, 0xf42f, + 0xf43b, 0xf436, 0xf42d, 0xf433, + 0xf427, 0xf60a, 0xf603, 0xf61e, + 0xf620, 0xf4a9, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0xf4dd, + 0xf454, 0xf33a, 0xf337, 0xf33b, + 0xf490, 0xf334, 0xf335, 0xf6be, + 0xf3a7, 0xf376, 0xf37b, 0x3297, + 0xf6ac, 0xf48a, 0xf388, 0xf4a3, + 0xf389, 0x2702, 0xf380, 0x3299, + 0xf4bd, 0xf4e3, 0xf452, 0xf457, + 0xf461, 0xf462, 0xf484, 0xf485, + 0xf486, 0xf487, 0xf488, 0xf458, + 0xf459, 0xf45c, 0xf3ac, 0xf514, + 0xf3b6, 0xf493, 0xf497, 0xf498, + 0xf499, 0xf49a, 0xf49b, 0xf49c, + 0x2728, 0x2b50, 0xf4a8, 0xf4a6, + 0x2b55, 0x274c, 0xf4a2, 0xf31f, + 0x2754, 0x2755, 0xf375, 0xf35e, + 0xf366, 0xf35f, 0xf361, 0xf358, + 0xf35a, 0xf35d, 0xf35c, 0xf35b, + 0xf359, 0xf362, 0xf363, 0xf34e, + 0xf34a, 0xf353, 0xf349, 0xf345, + 0xf346, 0xf382, 0xf371, 0xf372, }; -const int mb_tbl_code2uni_sb3_min = 0x2a99; -const int mb_tbl_code2uni_sb3_max = 0x2b2e; +static const int mb_tbl_code2uni_sb3_min = 0x2a99; +static const int mb_tbl_code2uni_sb3_max = 0x2b35; -const int mb_tbl_code2uni_sb3[] = { // 0x2a99 - 0x2b2e - 0x1f625, 0x1f60f, 0x1f614, 0x1f601, - 0x1f609, 0x1f623, 0x1f616, 0x1f62a, - 0x1f61d, 0x1f60c, 0x1f628, 0x1f637, - 0x1f633, 0x1f612, 0x1f630, 0x1f632, - 0x1f62d, 0x1f602, 0x1f622, 0x0263a, - 0x1f604, 0x1f621, 0x1f61a, 0x1f618, - 0x1f440, 0x1f443, 0x1f442, 0x1f444, - 0x1f64f, 0x1f44b, 0x1f44f, 0x1f44c, - 0x1f44e, 0x1f450, 0x1f645, 0x1f646, - 0x1f491, 0x1f647, 0x1f64c, 0x1f46b, - 0x1f46f, 0x1f3c0, 0x1f3c8, 0x1f3b1, - 0x1f3ca, 0x1f699, 0x1f69a, 0x1f692, - 0x1f691, 0x1f693, 0x1f3a2, 0x1f687, - 0x1f684, 0x1f38d, 0x1f49d, 0x1f38e, - 0x1f393, 0x1f392, 0x1f38f, 0x1f302, - 0x1f492, 0x1f30a, 0x1f367, 0x1f387, - 0x1f41a, 0x1f390, 0x1f300, 0x1f33e, - 0x1f383, 0x1f391, 0x1f343, 0x1f385, - 0x1f305, 0x1f307, 0x1f303, 0x1f308, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x00000, - 0x00000, 0x00000, 0x00000, 0x1f3e9, - 0x1f3a8, 0x1f3a9, 0x1f3ec, 0x1f3ef, - 0x1f3f0, 0x1f3a6, 0x1f3ed, 0x1f5fc, - 0x00000, 0x1f1ef, 0x1f1fa, 0x1f1eb, - 0x1f1e9, 0x1f1ee, 0x1f1ec, 0x1f1ea, - 0x1f1f7, 0x1f1e8, 0x1f1f0, 0x1f471, - 0x1f472, 0x1f473, 0x1f474, 0x1f475, - 0x1f476, 0x1f477, 0x1f478, 0x1f5fd, - 0x1f482, 0x1f483, 0x1f42c, 0x1f426, - 0x1f420, 0x1f424, 0x1f439, 0x1f41b, - 0x1f418, 0x1f428, 0x1f412, 0x1f411, - 0x1f43a, 0x1f42e, 0x1f430, 0x1f40d, - 0x1f414, 0x1f417, 0x1f42b, 0x1f438, - 0x1f170, 0x1f171, 0x1f18e, 0x1f17e, - 0x1f463, 0x02122, }; +static const unsigned short mb_tbl_code2uni_sb3[] = { // 0x2a99 - 0x2b35 + 0xf625, 0xf60f, 0xf614, 0xf601, + 0xf609, 0xf623, 0xf616, 0xf62a, + 0xf61d, 0xf60c, 0xf628, 0xf637, + 0xf633, 0xf612, 0xf630, 0xf632, + 0xf62d, 0xf602, 0xf622, 0x263a, + 0xf604, 0xf621, 0xf61a, 0xf618, + 0xf440, 0xf443, 0xf442, 0xf444, + 0xf64f, 0xf44b, 0xf44f, 0xf44c, + 0xf44e, 0xf450, 0xf645, 0xf646, + 0xf491, 0xf647, 0xf64c, 0xf46b, + 0xf46f, 0xf3c0, 0xf3c8, 0xf3b1, + 0xf3ca, 0xf699, 0xf69a, 0xf692, + 0xf691, 0xf693, 0xf3a2, 0xf687, + 0xf684, 0xf38d, 0xf49d, 0xf38e, + 0xf393, 0xf392, 0xf38f, 0xf302, + 0xf492, 0xf30a, 0xf367, 0xf387, + 0xf41a, 0xf390, 0xf300, 0xf33e, + 0xf383, 0xf391, 0xf343, 0xf385, + 0xf305, 0xf307, 0xf303, 0xf308, + 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0xf3e9, + 0xf3a8, 0xf3a9, 0xf3ec, 0xf3ef, + 0xf3f0, 0xf3a6, 0xf3ed, 0xf5fc, + 0xE4C5, 0xf1ef, 0xf1fa, 0xf1eb, + 0xf1e9, 0xf1ee, 0xf1ec, 0xf1ea, + 0xf1f7, 0xf1e8, 0xf1f0, 0xf471, + 0xf472, 0xf473, 0xf474, 0xf475, + 0xf476, 0xf477, 0xf478, 0xf5fd, + 0xf482, 0xf483, 0xf42c, 0xf426, + 0xf420, 0xf424, 0xf439, 0xf41b, + 0xf418, 0xf428, 0xf412, 0xf411, + 0xf43a, 0xf42e, 0xf430, 0xf40d, + 0xf414, 0xf417, 0xf42b, 0xf438, + 0xf170, 0xf171, 0xf18e, 0xf17e, + 0xf463, 0x2122, 0xEE70, 0xEE71, + 0xEE72, 0xEE73, 0xEE74, 0xEE75, + 0xEE76}; -const int mb_tbl_uni_docomo2code1_min = 0x0023; -const int mb_tbl_uni_docomo2code1_max = 0x00ae; +static const int mb_tbl_uni_docomo2code1_min = 0x0023; +static const int mb_tbl_uni_docomo2code1_max = 0x00ae; -const int mb_tbl_uni_docomo2code1_key[] = { // 0x0023 - 0x00ae +static const unsigned short mb_tbl_uni_docomo2code1_key[] = { // 0x0023 - 0x00ae 0x0023, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00a9, 0x00ae, }; -const int mb_tbl_uni_docomo2code1_value[] = { // 0x0023 - 0x00ae +static const unsigned short mb_tbl_uni_docomo2code1_value[] = { // 0x0023 - 0x00ae 0x2964, 0x296f, 0x2966, 0x2967, 0x2968, 0x2969, 0x296a, 0x296b, 0x296c, 0x296d, 0x296e, 0x29b5, 0x29ba, }; +static const int mb_tbl_uni_docomo2code1_len = sizeof(mb_tbl_uni_docomo2code1_key)/sizeof(unsigned short); +static const int mb_tbl_uni_docomo2code2_min = 0x203c; +static const int mb_tbl_uni_docomo2code2_max = 0x3299; - - - - - - - - - - - - -const int mb_tbl_uni_docomo2code2_min = 0x203c; -const int mb_tbl_uni_docomo2code2_max = 0x3299; - -const int mb_tbl_uni_docomo2code2_key[] = { // 0x203c - 0x3299 +static const unsigned short mb_tbl_uni_docomo2code2_key[] = { // 0x203c - 0x3299 0x203c, 0x2049, 0x2122, 0x2194, 0x2195, 0x2196, 0x2197, 0x2198, 0x2199, 0x21a9, 0x231a, 0x23f0, @@ -436,7 +429,7 @@ const int mb_tbl_uni_docomo2code2_key[] = { // 0x203c - 0x3299 0x2764, 0x27b0, 0x2934, 0x2935, 0x3030, 0x3299, }; -const int mb_tbl_uni_docomo2code2_value[] = { // 0x203c - 0x3299 +static const unsigned short mb_tbl_uni_docomo2code2_value[] = { // 0x203c - 0x3299 0x2988, 0x2987, 0x29b6, 0x29c0, 0x29c1, 0x291b, 0x28fc, 0x291a, 0x2929, 0x295e, 0x29a3, 0x293e, @@ -454,56 +447,57 @@ const int mb_tbl_uni_docomo2code2_value[] = { // 0x203c - 0x3299 0x2970, 0x298e, 0x2979, 0x2984, 0x298d, 0x29b8, }; +static const int mb_tbl_uni_docomo2code2_len = sizeof(mb_tbl_uni_docomo2code2_key)/sizeof(unsigned short); -const int mb_tbl_uni_docomo2code3_min = 0x1f17f; -const int mb_tbl_uni_docomo2code3_max = 0x1f6bb; +static const int mb_tbl_uni_docomo2code3_min = 0x1f17f; +static const int mb_tbl_uni_docomo2code3_max = 0x1f6bb; -const int mb_tbl_uni_docomo2code3_key[] = { // 0x1f17f - 0x1f6bb - 0x1f17f, 0x1f191, 0x1f193, 0x1f194, - 0x1f195, 0x1f196, 0x1f197, 0x1f232, - 0x1f233, 0x1f234, 0x1f235, 0x1f300, - 0x1f301, 0x1f302, 0x1f303, 0x1f30a, - 0x1f311, 0x1f313, 0x1f314, 0x1f315, - 0x1f319, 0x1f331, 0x1f337, 0x1f338, - 0x1f340, 0x1f341, 0x1f34c, 0x1f34e, - 0x1f352, 0x1f354, 0x1f359, 0x1f35c, - 0x1f35e, 0x1f370, 0x1f374, 0x1f375, - 0x1f376, 0x1f377, 0x1f378, 0x1f37a, - 0x1f380, 0x1f381, 0x1f382, 0x1f384, - 0x1f3a0, 0x1f3a4, 0x1f3a5, 0x1f3a7, - 0x1f3a8, 0x1f3a9, 0x1f3aa, 0x1f3ab, - 0x1f3ac, 0x1f3ae, 0x1f3b5, 0x1f3b6, - 0x1f3bd, 0x1f3be, 0x1f3bf, 0x1f3c0, - 0x1f3c1, 0x1f3c2, 0x1f3c3, 0x1f3e0, - 0x1f3e2, 0x1f3e3, 0x1f3e5, 0x1f3e6, - 0x1f3e7, 0x1f3e8, 0x1f3ea, 0x1f3eb, - 0x1f40c, 0x1f41f, 0x1f424, 0x1f427, - 0x1f431, 0x1f434, 0x1f436, 0x1f437, - 0x1f440, 0x1f442, 0x1f44a, 0x1f44d, - 0x1f451, 0x1f453, 0x1f455, 0x1f456, - 0x1f45b, 0x1f45c, 0x1f45d, 0x1f45f, - 0x1f460, 0x1f463, 0x1f464, 0x1f484, - 0x1f48b, 0x1f48c, 0x1f48d, 0x1f493, - 0x1f494, 0x1f495, 0x1f4a0, 0x1f4a1, - 0x1f4a2, 0x1f4a3, 0x1f4a4, 0x1f4a5, - 0x1f4a6, 0x1f4a7, 0x1f4a8, 0x1f4b0, - 0x1f4b4, 0x1f4ba, 0x1f4bb, 0x1f4bf, - 0x1f4ce, 0x1f4d6, 0x1f4dd, 0x1f4df, - 0x1f4e0, 0x1f4e9, 0x1f4f1, 0x1f4f2, - 0x1f4f7, 0x1f4fa, 0x1f50d, 0x1f511, - 0x1f514, 0x1f51a, 0x1f51b, 0x1f51c, - 0x1f527, 0x1f5fb, 0x1f601, 0x1f603, - 0x1f605, 0x1f606, 0x1f609, 0x1f60b, - 0x1f60c, 0x1f60d, 0x1f60f, 0x1f612, - 0x1f613, 0x1f614, 0x1f616, 0x1f61c, - 0x1f61e, 0x1f620, 0x1f621, 0x1f622, - 0x1f623, 0x1f62d, 0x1f631, 0x1f635, - 0x1f683, 0x1f684, 0x1f68c, 0x1f697, - 0x1f699, 0x1f6a2, 0x1f6a5, 0x1f6a9, - 0x1f6aa, 0x1f6ac, 0x1f6ad, 0x1f6b2, - 0x1f6bb, }; +static const unsigned short mb_tbl_uni_docomo2code3_key[] = { // 0x1f17f - 0x1f6bb + 0xf17f, 0xf191, 0xf193, 0xf194, + 0xf195, 0xf196, 0xf197, 0xf232, + 0xf233, 0xf234, 0xf235, 0xf300, + 0xf301, 0xf302, 0xf303, 0xf30a, + 0xf311, 0xf313, 0xf314, 0xf315, + 0xf319, 0xf331, 0xf337, 0xf338, + 0xf340, 0xf341, 0xf34c, 0xf34e, + 0xf352, 0xf354, 0xf359, 0xf35c, + 0xf35e, 0xf370, 0xf374, 0xf375, + 0xf376, 0xf377, 0xf378, 0xf37a, + 0xf380, 0xf381, 0xf382, 0xf384, + 0xf3a0, 0xf3a4, 0xf3a5, 0xf3a7, + 0xf3a8, 0xf3a9, 0xf3aa, 0xf3ab, + 0xf3ac, 0xf3ae, 0xf3b5, 0xf3b6, + 0xf3bd, 0xf3be, 0xf3bf, 0xf3c0, + 0xf3c1, 0xf3c2, 0xf3c3, 0xf3e0, + 0xf3e2, 0xf3e3, 0xf3e5, 0xf3e6, + 0xf3e7, 0xf3e8, 0xf3ea, 0xf3eb, + 0xf40c, 0xf41f, 0xf424, 0xf427, + 0xf431, 0xf434, 0xf436, 0xf437, + 0xf440, 0xf442, 0xf44a, 0xf44d, + 0xf451, 0xf453, 0xf455, 0xf456, + 0xf45b, 0xf45c, 0xf45d, 0xf45f, + 0xf460, 0xf463, 0xf464, 0xf484, + 0xf48b, 0xf48c, 0xf48d, 0xf493, + 0xf494, 0xf495, 0xf4a0, 0xf4a1, + 0xf4a2, 0xf4a3, 0xf4a4, 0xf4a5, + 0xf4a6, 0xf4a7, 0xf4a8, 0xf4b0, + 0xf4b4, 0xf4ba, 0xf4bb, 0xf4bf, + 0xf4ce, 0xf4d6, 0xf4dd, 0xf4df, + 0xf4e0, 0xf4e9, 0xf4f1, 0xf4f2, + 0xf4f7, 0xf4fa, 0xf50d, 0xf511, + 0xf514, 0xf51a, 0xf51b, 0xf51c, + 0xf527, 0xf5fb, 0xf601, 0xf603, + 0xf605, 0xf606, 0xf609, 0xf60b, + 0xf60c, 0xf60d, 0xf60f, 0xf612, + 0xf613, 0xf614, 0xf616, 0xf61c, + 0xf61e, 0xf620, 0xf621, 0xf622, + 0xf623, 0xf62d, 0xf631, 0xf635, + 0xf683, 0xf684, 0xf68c, 0xf697, + 0xf699, 0xf6a2, 0xf6a5, 0xf6a9, + 0xf6aa, 0xf6ac, 0xf6ad, 0xf6b2, + 0xf6bb, }; -const int mb_tbl_uni_docomo2code3_value[] = { // 0x1f17f - 0x1f6bb +static const unsigned short mb_tbl_uni_docomo2code3_value[] = { // 0x1f17f - 0x1f6bb 0x28f0, 0x295f, 0x295b, 0x295c, 0x2961, 0x29b3, 0x298f, 0x29bc, 0x29bd, 0x29be, 0x29bf, 0x28c7, @@ -548,27 +542,29 @@ const int mb_tbl_uni_docomo2code3_value[] = { // 0x1f17f - 0x1f6bb 0x2998, 0x2903, 0x2904, 0x29a1, 0x28f2, }; +static const int mb_tbl_uni_docomo2code3_len = sizeof(mb_tbl_uni_docomo2code3_key)/sizeof(unsigned short); +static const int mb_tbl_uni_kddi2code1_min = 0x0023; +static const int mb_tbl_uni_kddi2code1_max = 0x00ae; -const int mb_tbl_uni_kddi2code1_min = 0x0023; -const int mb_tbl_uni_kddi2code1_max = 0x00ae; - -const int mb_tbl_uni_kddi2code1_key[] = { // 0x0023 - 0x00ae +static const unsigned short mb_tbl_uni_kddi2code1_key[] = { // 0x0023 - 0x00ae 0x0023, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00a9, 0x00ae, }; -const int mb_tbl_uni_kddi2code1_value[] = { // 0x0023 - 0x00ae +static const unsigned short mb_tbl_uni_kddi2code1_value[] = { // 0x0023 - 0x00ae 0x25bc, 0x2830, 0x27a6, 0x27a7, 0x27a8, 0x27a9, 0x27aa, 0x27ab, 0x27ac, 0x27ad, 0x27ae, 0x27dc, 0x27dd, }; -const int mb_tbl_uni_kddi2code2_min = 0x2002; -const int mb_tbl_uni_kddi2code2_max = 0x3299; +static const int mb_tbl_uni_kddi2code1_len = sizeof(mb_tbl_uni_kddi2code1_key)/sizeof(unsigned short); -const int mb_tbl_uni_kddi2code2_key[] = { // 0x2002 - 0x3299 +static const int mb_tbl_uni_kddi2code2_min = 0x2002; +static const int mb_tbl_uni_kddi2code2_max = 0x3299; + +static const unsigned short mb_tbl_uni_kddi2code2_key[] = { // 0x2002 - 0x3299 0x2002, 0x2003, 0x2005, 0x203c, 0x2049, 0x2122, 0x2139, 0x2194, 0x2195, 0x2196, 0x2197, 0x2198, @@ -599,7 +595,7 @@ const int mb_tbl_uni_kddi2code2_key[] = { // 0x2002 - 0x3299 0x2b50, 0x2b55, 0x3297, 0x3299, }; -const int mb_tbl_uni_kddi2code2_value[] = { // 0x2002 - 0x3299 +static const unsigned short mb_tbl_uni_kddi2code2_value[] = { // 0x2002 - 0x3299 0x2811, 0x2810, 0x2812, 0x2568, 0x2567, 0x27d2, 0x27b7, 0x25b2, 0x25b3, 0x27d0, 0x27d9, 0x27d1, @@ -630,140 +626,142 @@ const int mb_tbl_uni_kddi2code2_value[] = { // 0x2002 - 0x3299 0x270f, 0x24f8, 0x24e4, 0x2775, }; -const int mb_tbl_uni_kddi2code3_min = 0x1f004; -const int mb_tbl_uni_kddi2code3_max = 0x1f6c0; +static const int mb_tbl_uni_kddi2code2_len = sizeof(mb_tbl_uni_kddi2code2_key)/sizeof(unsigned short); + +static const int mb_tbl_uni_kddi2code3_min = 0x1f004; +static const int mb_tbl_uni_kddi2code3_max = 0x1f6c0; -const int mb_tbl_uni_kddi2code3_key[] = { // 0x1f004 - 0x1f6c0 - 0x1f004, 0x1f0cf, 0x1f170, 0x1f171, - 0x1f17e, 0x1f17f, 0x1f18e, 0x1f191, - 0x1f192, 0x1f193, 0x1f194, 0x1f195, - 0x1f197, 0x1f198, 0x1f199, 0x1f19a, - 0x1f1e8, 0x1f1e9, 0x1f1ea, 0x1f1eb, - 0x1f1ec, 0x1f1ee, 0x1f1ef, 0x1f1f0, - 0x1f1f7, 0x1f1fa, 0x1f202, 0x1f22f, - 0x1f233, 0x1f235, 0x1f239, 0x1f23a, - 0x1f250, 0x1f251, 0x1f300, 0x1f301, - 0x1f302, 0x1f303, 0x1f305, 0x1f306, - 0x1f308, 0x1f309, 0x1f30a, 0x1f30b, - 0x1f30c, 0x1f30f, 0x1f311, 0x1f313, - 0x1f314, 0x1f319, 0x1f31b, 0x1f320, - 0x1f330, 0x1f331, 0x1f334, 0x1f335, - 0x1f337, 0x1f338, 0x1f339, 0x1f33a, - 0x1f33b, 0x1f33c, 0x1f33d, 0x1f33f, - 0x1f340, 0x1f341, 0x1f342, 0x1f344, - 0x1f345, 0x1f346, 0x1f347, 0x1f348, - 0x1f349, 0x1f34a, 0x1f34c, 0x1f34d, - 0x1f34e, 0x1f34f, 0x1f351, 0x1f352, - 0x1f353, 0x1f354, 0x1f355, 0x1f356, - 0x1f357, 0x1f358, 0x1f359, 0x1f35a, - 0x1f35b, 0x1f35c, 0x1f35d, 0x1f35e, - 0x1f35f, 0x1f360, 0x1f361, 0x1f362, - 0x1f363, 0x1f364, 0x1f365, 0x1f366, - 0x1f367, 0x1f368, 0x1f369, 0x1f36a, - 0x1f36b, 0x1f36c, 0x1f36d, 0x1f36e, - 0x1f36f, 0x1f370, 0x1f371, 0x1f372, - 0x1f373, 0x1f374, 0x1f375, 0x1f376, - 0x1f377, 0x1f378, 0x1f379, 0x1f37a, - 0x1f37b, 0x1f380, 0x1f381, 0x1f382, - 0x1f383, 0x1f384, 0x1f385, 0x1f386, - 0x1f387, 0x1f388, 0x1f389, 0x1f38a, - 0x1f38b, 0x1f38c, 0x1f38d, 0x1f38e, - 0x1f38f, 0x1f390, 0x1f391, 0x1f392, - 0x1f393, 0x1f3a1, 0x1f3a2, 0x1f3a3, - 0x1f3a4, 0x1f3a5, 0x1f3a7, 0x1f3a8, - 0x1f3a9, 0x1f3aa, 0x1f3ab, 0x1f3ac, - 0x1f3ad, 0x1f3ae, 0x1f3af, 0x1f3b0, - 0x1f3b1, 0x1f3b2, 0x1f3b3, 0x1f3b4, - 0x1f3b5, 0x1f3b6, 0x1f3b8, 0x1f3b9, - 0x1f3ba, 0x1f3bb, 0x1f3bc, 0x1f3be, - 0x1f3bf, 0x1f3c0, 0x1f3c1, 0x1f3c2, - 0x1f3c3, 0x1f3c4, 0x1f3c6, 0x1f3c8, - 0x1f3ca, 0x1f3e0, 0x1f3e1, 0x1f3e2, - 0x1f3e3, 0x1f3e5, 0x1f3e6, 0x1f3e7, - 0x1f3e8, 0x1f3e9, 0x1f3ea, 0x1f3eb, - 0x1f3ec, 0x1f3ed, 0x1f3ee, 0x1f3ef, - 0x1f3f0, 0x1f40c, 0x1f40d, 0x1f414, - 0x1f417, 0x1f418, 0x1f419, 0x1f41a, - 0x1f41b, 0x1f41c, 0x1f41d, 0x1f41e, - 0x1f420, 0x1f421, 0x1f422, 0x1f423, - 0x1f424, 0x1f425, 0x1f427, 0x1f428, - 0x1f429, 0x1f42b, 0x1f42c, 0x1f42d, - 0x1f42e, 0x1f42f, 0x1f430, 0x1f431, - 0x1f432, 0x1f433, 0x1f434, 0x1f435, - 0x1f436, 0x1f437, 0x1f438, 0x1f43b, - 0x1f43c, 0x1f43d, 0x1f43e, 0x1f440, - 0x1f442, 0x1f443, 0x1f444, 0x1f445, - 0x1f446, 0x1f447, 0x1f448, 0x1f449, - 0x1f44a, 0x1f44b, 0x1f44c, 0x1f44d, - 0x1f44e, 0x1f44f, 0x1f451, 0x1f452, - 0x1f453, 0x1f454, 0x1f455, 0x1f456, - 0x1f457, 0x1f458, 0x1f459, 0x1f45a, - 0x1f45b, 0x1f45c, 0x1f45e, 0x1f45f, - 0x1f460, 0x1f462, 0x1f463, 0x1f468, - 0x1f469, 0x1f46a, 0x1f46e, 0x1f46f, - 0x1f470, 0x1f471, 0x1f472, 0x1f473, - 0x1f474, 0x1f475, 0x1f476, 0x1f477, - 0x1f478, 0x1f479, 0x1f47a, 0x1f47b, - 0x1f47c, 0x1f47d, 0x1f47e, 0x1f47f, - 0x1f480, 0x1f483, 0x1f484, 0x1f485, - 0x1f486, 0x1f487, 0x1f488, 0x1f489, - 0x1f48a, 0x1f48b, 0x1f48c, 0x1f48d, - 0x1f48f, 0x1f490, 0x1f491, 0x1f493, - 0x1f494, 0x1f495, 0x1f496, 0x1f498, - 0x1f499, 0x1f49a, 0x1f49b, 0x1f49c, - 0x1f49d, 0x1f49e, 0x1f4a1, 0x1f4a2, - 0x1f4a3, 0x1f4a4, 0x1f4a5, 0x1f4a6, - 0x1f4a7, 0x1f4a8, 0x1f4a9, 0x1f4aa, - 0x1f4ab, 0x1f4ac, 0x1f4ae, 0x1f4af, - 0x1f4b0, 0x1f4b2, 0x1f4b3, 0x1f4b4, - 0x1f4b5, 0x1f4b8, 0x1f4b9, 0x1f4bb, - 0x1f4bc, 0x1f4bd, 0x1f4be, 0x1f4bf, - 0x1f4c1, 0x1f4c2, 0x1f4c3, 0x1f4c4, - 0x1f4c5, 0x1f4c6, 0x1f4c7, 0x1f4c8, - 0x1f4c9, 0x1f4ca, 0x1f4cb, 0x1f4cc, - 0x1f4cd, 0x1f4ce, 0x1f4cf, 0x1f4d0, - 0x1f4d1, 0x1f4d2, 0x1f4d3, 0x1f4d4, - 0x1f4d5, 0x1f4d6, 0x1f4d7, 0x1f4d8, - 0x1f4d9, 0x1f4da, 0x1f4db, 0x1f4dc, - 0x1f4dd, 0x1f4de, 0x1f4df, 0x1f4e0, - 0x1f4e1, 0x1f4e4, 0x1f4e5, 0x1f4e6, - 0x1f4e7, 0x1f4e8, 0x1f4e9, 0x1f4ea, - 0x1f4eb, 0x1f4f0, 0x1f4f1, 0x1f4f2, - 0x1f4f3, 0x1f4f4, 0x1f4f6, 0x1f4f7, - 0x1f4f9, 0x1f4fa, 0x1f4fb, 0x1f4fc, - 0x1f503, 0x1f50a, 0x1f50b, 0x1f50c, - 0x1f50d, 0x1f50e, 0x1f50f, 0x1f510, - 0x1f511, 0x1f512, 0x1f514, 0x1f516, - 0x1f517, 0x1f518, 0x1f519, 0x1f51e, - 0x1f51f, 0x1f520, 0x1f521, 0x1f522, - 0x1f523, 0x1f524, 0x1f525, 0x1f526, - 0x1f527, 0x1f528, 0x1f529, 0x1f52a, - 0x1f52b, 0x1f52e, 0x1f530, 0x1f534, - 0x1f535, 0x1f536, 0x1f537, 0x1f538, - 0x1f539, 0x1f53a, 0x1f53b, 0x1f53c, - 0x1f53d, 0x1f5fb, 0x1f5fc, 0x1f5fe, - 0x1f5ff, 0x1f601, 0x1f602, 0x1f603, - 0x1f609, 0x1f60a, 0x1f60c, 0x1f60d, - 0x1f60f, 0x1f612, 0x1f613, 0x1f614, - 0x1f616, 0x1f618, 0x1f61a, 0x1f61c, - 0x1f620, 0x1f621, 0x1f622, 0x1f623, - 0x1f624, 0x1f628, 0x1f629, 0x1f62a, - 0x1f62b, 0x1f62d, 0x1f630, 0x1f631, - 0x1f632, 0x1f633, 0x1f635, 0x1f637, - 0x1f638, 0x1f639, 0x1f63a, 0x1f63b, - 0x1f63c, 0x1f63d, 0x1f63e, 0x1f63f, - 0x1f640, 0x1f645, 0x1f646, 0x1f647, - 0x1f648, 0x1f649, 0x1f64a, 0x1f64b, - 0x1f64c, 0x1f64d, 0x1f64e, 0x1f64f, - 0x1f680, 0x1f683, 0x1f685, 0x1f687, - 0x1f689, 0x1f68c, 0x1f68f, 0x1f691, - 0x1f692, 0x1f693, 0x1f697, 0x1f69a, - 0x1f6a2, 0x1f6a5, 0x1f6a7, 0x1f6a8, - 0x1f6a9, 0x1f6ab, 0x1f6ac, 0x1f6ad, - 0x1f6b2, 0x1f6b6, 0x1f6bb, 0x1f6c0, +static const unsigned short mb_tbl_uni_kddi2code3_key[] = { // 0x1f004 - 0x1f6c0 + 0xf004, 0xf0cf, 0xf170, 0xf171, + 0xf17e, 0xf17f, 0xf18e, 0xf191, + 0xf192, 0xf193, 0xf194, 0xf195, + 0xf197, 0xf198, 0xf199, 0xf19a, + 0xf1e8, 0xf1e9, 0xf1ea, 0xf1eb, + 0xf1ec, 0xf1ee, 0xf1ef, 0xf1f0, + 0xf1f7, 0xf1fa, 0xf202, 0xf22f, + 0xf233, 0xf235, 0xf239, 0xf23a, + 0xf250, 0xf251, 0xf300, 0xf301, + 0xf302, 0xf303, 0xf305, 0xf306, + 0xf308, 0xf309, 0xf30a, 0xf30b, + 0xf30c, 0xf30f, 0xf311, 0xf313, + 0xf314, 0xf319, 0xf31b, 0xf320, + 0xf330, 0xf331, 0xf334, 0xf335, + 0xf337, 0xf338, 0xf339, 0xf33a, + 0xf33b, 0xf33c, 0xf33d, 0xf33f, + 0xf340, 0xf341, 0xf342, 0xf344, + 0xf345, 0xf346, 0xf347, 0xf348, + 0xf349, 0xf34a, 0xf34c, 0xf34d, + 0xf34e, 0xf34f, 0xf351, 0xf352, + 0xf353, 0xf354, 0xf355, 0xf356, + 0xf357, 0xf358, 0xf359, 0xf35a, + 0xf35b, 0xf35c, 0xf35d, 0xf35e, + 0xf35f, 0xf360, 0xf361, 0xf362, + 0xf363, 0xf364, 0xf365, 0xf366, + 0xf367, 0xf368, 0xf369, 0xf36a, + 0xf36b, 0xf36c, 0xf36d, 0xf36e, + 0xf36f, 0xf370, 0xf371, 0xf372, + 0xf373, 0xf374, 0xf375, 0xf376, + 0xf377, 0xf378, 0xf379, 0xf37a, + 0xf37b, 0xf380, 0xf381, 0xf382, + 0xf383, 0xf384, 0xf385, 0xf386, + 0xf387, 0xf388, 0xf389, 0xf38a, + 0xf38b, 0xf38c, 0xf38d, 0xf38e, + 0xf38f, 0xf390, 0xf391, 0xf392, + 0xf393, 0xf3a1, 0xf3a2, 0xf3a3, + 0xf3a4, 0xf3a5, 0xf3a7, 0xf3a8, + 0xf3a9, 0xf3aa, 0xf3ab, 0xf3ac, + 0xf3ad, 0xf3ae, 0xf3af, 0xf3b0, + 0xf3b1, 0xf3b2, 0xf3b3, 0xf3b4, + 0xf3b5, 0xf3b6, 0xf3b8, 0xf3b9, + 0xf3ba, 0xf3bb, 0xf3bc, 0xf3be, + 0xf3bf, 0xf3c0, 0xf3c1, 0xf3c2, + 0xf3c3, 0xf3c4, 0xf3c6, 0xf3c8, + 0xf3ca, 0xf3e0, 0xf3e1, 0xf3e2, + 0xf3e3, 0xf3e5, 0xf3e6, 0xf3e7, + 0xf3e8, 0xf3e9, 0xf3ea, 0xf3eb, + 0xf3ec, 0xf3ed, 0xf3ee, 0xf3ef, + 0xf3f0, 0xf40c, 0xf40d, 0xf414, + 0xf417, 0xf418, 0xf419, 0xf41a, + 0xf41b, 0xf41c, 0xf41d, 0xf41e, + 0xf420, 0xf421, 0xf422, 0xf423, + 0xf424, 0xf425, 0xf427, 0xf428, + 0xf429, 0xf42b, 0xf42c, 0xf42d, + 0xf42e, 0xf42f, 0xf430, 0xf431, + 0xf432, 0xf433, 0xf434, 0xf435, + 0xf436, 0xf437, 0xf438, 0xf43b, + 0xf43c, 0xf43d, 0xf43e, 0xf440, + 0xf442, 0xf443, 0xf444, 0xf445, + 0xf446, 0xf447, 0xf448, 0xf449, + 0xf44a, 0xf44b, 0xf44c, 0xf44d, + 0xf44e, 0xf44f, 0xf451, 0xf452, + 0xf453, 0xf454, 0xf455, 0xf456, + 0xf457, 0xf458, 0xf459, 0xf45a, + 0xf45b, 0xf45c, 0xf45e, 0xf45f, + 0xf460, 0xf462, 0xf463, 0xf468, + 0xf469, 0xf46a, 0xf46e, 0xf46f, + 0xf470, 0xf471, 0xf472, 0xf473, + 0xf474, 0xf475, 0xf476, 0xf477, + 0xf478, 0xf479, 0xf47a, 0xf47b, + 0xf47c, 0xf47d, 0xf47e, 0xf47f, + 0xf480, 0xf483, 0xf484, 0xf485, + 0xf486, 0xf487, 0xf488, 0xf489, + 0xf48a, 0xf48b, 0xf48c, 0xf48d, + 0xf48f, 0xf490, 0xf491, 0xf493, + 0xf494, 0xf495, 0xf496, 0xf498, + 0xf499, 0xf49a, 0xf49b, 0xf49c, + 0xf49d, 0xf49e, 0xf4a1, 0xf4a2, + 0xf4a3, 0xf4a4, 0xf4a5, 0xf4a6, + 0xf4a7, 0xf4a8, 0xf4a9, 0xf4aa, + 0xf4ab, 0xf4ac, 0xf4ae, 0xf4af, + 0xf4b0, 0xf4b2, 0xf4b3, 0xf4b4, + 0xf4b5, 0xf4b8, 0xf4b9, 0xf4bb, + 0xf4bc, 0xf4bd, 0xf4be, 0xf4bf, + 0xf4c1, 0xf4c2, 0xf4c3, 0xf4c4, + 0xf4c5, 0xf4c6, 0xf4c7, 0xf4c8, + 0xf4c9, 0xf4ca, 0xf4cb, 0xf4cc, + 0xf4cd, 0xf4ce, 0xf4cf, 0xf4d0, + 0xf4d1, 0xf4d2, 0xf4d3, 0xf4d4, + 0xf4d5, 0xf4d6, 0xf4d7, 0xf4d8, + 0xf4d9, 0xf4da, 0xf4db, 0xf4dc, + 0xf4dd, 0xf4de, 0xf4df, 0xf4e0, + 0xf4e1, 0xf4e4, 0xf4e5, 0xf4e6, + 0xf4e7, 0xf4e8, 0xf4e9, 0xf4ea, + 0xf4eb, 0xf4f0, 0xf4f1, 0xf4f2, + 0xf4f3, 0xf4f4, 0xf4f6, 0xf4f7, + 0xf4f9, 0xf4fa, 0xf4fb, 0xf4fc, + 0xf503, 0xf50a, 0xf50b, 0xf50c, + 0xf50d, 0xf50e, 0xf50f, 0xf510, + 0xf511, 0xf512, 0xf514, 0xf516, + 0xf517, 0xf518, 0xf519, 0xf51e, + 0xf51f, 0xf520, 0xf521, 0xf522, + 0xf523, 0xf524, 0xf525, 0xf526, + 0xf527, 0xf528, 0xf529, 0xf52a, + 0xf52b, 0xf52e, 0xf530, 0xf534, + 0xf535, 0xf536, 0xf537, 0xf538, + 0xf539, 0xf53a, 0xf53b, 0xf53c, + 0xf53d, 0xf5fb, 0xf5fc, 0xf5fe, + 0xf5ff, 0xf601, 0xf602, 0xf603, + 0xf609, 0xf60a, 0xf60c, 0xf60d, + 0xf60f, 0xf612, 0xf613, 0xf614, + 0xf616, 0xf618, 0xf61a, 0xf61c, + 0xf620, 0xf621, 0xf622, 0xf623, + 0xf624, 0xf628, 0xf629, 0xf62a, + 0xf62b, 0xf62d, 0xf630, 0xf631, + 0xf632, 0xf633, 0xf635, 0xf637, + 0xf638, 0xf639, 0xf63a, 0xf63b, + 0xf63c, 0xf63d, 0xf63e, 0xf63f, + 0xf640, 0xf645, 0xf646, 0xf647, + 0xf648, 0xf649, 0xf64a, 0xf64b, + 0xf64c, 0xf64d, 0xf64e, 0xf64f, + 0xf680, 0xf683, 0xf685, 0xf687, + 0xf689, 0xf68c, 0xf68f, 0xf691, + 0xf692, 0xf693, 0xf697, 0xf69a, + 0xf6a2, 0xf6a5, 0xf6a7, 0xf6a8, + 0xf6a9, 0xf6ab, 0xf6ac, 0xf6ad, + 0xf6b2, 0xf6b6, 0xf6bb, 0xf6c0, }; -const int mb_tbl_uni_kddi2code3_value[] = { // 0x1f004 - 0x1f6c0 +static const unsigned short mb_tbl_uni_kddi2code3_value[] = { // 0x1f004 - 0x1f6c0 0x24bc, 0x25a7, 0x255e, 0x255f, 0x2560, 0x272a, 0x2561, 0x282f, 0x24d0, 0x27fc, 0x24d3, 0x284c, @@ -893,27 +891,29 @@ const int mb_tbl_uni_kddi2code3_value[] = { // 0x1f004 - 0x1f6c0 0x2732, 0x25aa, 0x2729, 0x24c3, }; +static const int mb_tbl_uni_kddi2code3_len = sizeof(mb_tbl_uni_kddi2code3_key)/sizeof(unsigned short); +static const int mb_tbl_uni_sb2code1_min = 0x0023; +static const int mb_tbl_uni_sb2code1_max = 0x00ae; -const int mb_tbl_uni_sb2code1_min = 0x0023; -const int mb_tbl_uni_sb2code1_max = 0x00ae; - -const int mb_tbl_uni_sb2code1_key[] = { // 0x0023 - 0x00ae +static const unsigned short mb_tbl_uni_sb2code1_key[] = { // 0x0023 - 0x00ae 0x0023, 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x00a9, 0x00ae, }; -const int mb_tbl_uni_sb2code1_value[] = { // 0x0023 - 0x00ae +static const unsigned short mb_tbl_uni_sb2code1_value[] = { // 0x0023 - 0x00ae 0x2817, 0x282c, 0x2823, 0x2824, 0x2825, 0x2826, 0x2827, 0x2828, 0x2829, 0x282a, 0x282b, 0x2855, 0x2856, }; -const int mb_tbl_uni_sb2code2_min = 0x2122; -const int mb_tbl_uni_sb2code2_max = 0x3299; +static const int mb_tbl_uni_sb2code1_len = sizeof(mb_tbl_uni_sb2code1_key)/sizeof(unsigned short); -const int mb_tbl_uni_sb2code2_key[] = { // 0x2122 - 0x3299 +static const int mb_tbl_uni_sb2code2_min = 0x2122; +static const int mb_tbl_uni_sb2code2_max = 0x3299; + +static const unsigned short mb_tbl_uni_sb2code2_key[] = { // 0x2122 - 0x3299 0x2122, 0x2196, 0x2197, 0x2198, 0x2199, 0x23e9, 0x23ea, 0x25b6, 0x25c0, 0x2600, 0x2601, 0x260e, @@ -933,7 +933,7 @@ const int mb_tbl_uni_sb2code2_key[] = { // 0x2122 - 0x3299 0x2b50, 0x2b55, 0x303d, 0x3297, 0x3299, }; -const int mb_tbl_uni_sb2code2_value[] = { // 0x2122 - 0x3299 +static const unsigned short mb_tbl_uni_sb2code2_value[] = { // 0x2122 - 0x3299 0x2b2e, 0x283e, 0x283d, 0x283f, 0x2840, 0x2843, 0x2844, 0x2841, 0x2842, 0x296a, 0x2969, 0x2929, @@ -953,109 +953,111 @@ const int mb_tbl_uni_sb2code2_value[] = { // 0x2122 - 0x3299 0x29ae, 0x29b1, 0x27d4, 0x298c, 0x2994, }; -const int mb_tbl_uni_sb2code3_min = 0x1f004; -const int mb_tbl_uni_sb2code3_max = 0x1f6c0; +static const int mb_tbl_uni_sb2code2_len = sizeof(mb_tbl_uni_sb2code2_key)/sizeof(unsigned short); + +static const int mb_tbl_uni_sb2code3_min = 0x1f004; +static const int mb_tbl_uni_sb2code3_max = 0x1f6c0; -const int mb_tbl_uni_sb2code3_key[] = { // 0x1f004 - 0x1f6c0 - 0x1f004, 0x1f170, 0x1f171, 0x1f17e, - 0x1f17f, 0x1f18e, 0x1f192, 0x1f194, - 0x1f195, 0x1f197, 0x1f199, 0x1f19a, - 0x1f1e8, 0x1f1e9, 0x1f1ea, 0x1f1eb, - 0x1f1ec, 0x1f1ee, 0x1f1ef, 0x1f1f0, - 0x1f1f7, 0x1f1fa, 0x1f201, 0x1f202, - 0x1f21a, 0x1f22f, 0x1f233, 0x1f235, - 0x1f236, 0x1f237, 0x1f238, 0x1f239, - 0x1f23a, 0x1f250, 0x1f300, 0x1f302, - 0x1f303, 0x1f304, 0x1f305, 0x1f306, - 0x1f307, 0x1f308, 0x1f30a, 0x1f319, - 0x1f31f, 0x1f334, 0x1f335, 0x1f337, - 0x1f338, 0x1f339, 0x1f33a, 0x1f33b, - 0x1f33e, 0x1f340, 0x1f341, 0x1f342, - 0x1f343, 0x1f345, 0x1f346, 0x1f349, - 0x1f34a, 0x1f34e, 0x1f353, 0x1f354, - 0x1f358, 0x1f359, 0x1f35a, 0x1f35b, - 0x1f35c, 0x1f35d, 0x1f35e, 0x1f35f, - 0x1f361, 0x1f362, 0x1f363, 0x1f366, - 0x1f367, 0x1f370, 0x1f371, 0x1f372, - 0x1f373, 0x1f374, 0x1f375, 0x1f376, - 0x1f378, 0x1f37a, 0x1f37b, 0x1f380, - 0x1f381, 0x1f382, 0x1f383, 0x1f384, - 0x1f385, 0x1f386, 0x1f387, 0x1f388, - 0x1f389, 0x1f38c, 0x1f38d, 0x1f38e, - 0x1f38f, 0x1f390, 0x1f391, 0x1f392, - 0x1f393, 0x1f3a1, 0x1f3a2, 0x1f3a4, - 0x1f3a5, 0x1f3a6, 0x1f3a7, 0x1f3a8, - 0x1f3a9, 0x1f3ab, 0x1f3ac, 0x1f3af, - 0x1f3b0, 0x1f3b1, 0x1f3b5, 0x1f3b6, - 0x1f3b7, 0x1f3b8, 0x1f3ba, 0x1f3be, - 0x1f3bf, 0x1f3c0, 0x1f3c1, 0x1f3c3, - 0x1f3c4, 0x1f3c6, 0x1f3c8, 0x1f3ca, - 0x1f3e0, 0x1f3e2, 0x1f3e3, 0x1f3e5, - 0x1f3e6, 0x1f3e7, 0x1f3e8, 0x1f3e9, - 0x1f3ea, 0x1f3eb, 0x1f3ec, 0x1f3ed, - 0x1f3ef, 0x1f3f0, 0x1f40d, 0x1f40e, - 0x1f411, 0x1f412, 0x1f414, 0x1f417, - 0x1f418, 0x1f419, 0x1f41a, 0x1f41b, - 0x1f41f, 0x1f420, 0x1f424, 0x1f426, - 0x1f427, 0x1f428, 0x1f42b, 0x1f42c, - 0x1f42d, 0x1f42e, 0x1f42f, 0x1f430, - 0x1f431, 0x1f433, 0x1f434, 0x1f435, - 0x1f436, 0x1f437, 0x1f438, 0x1f439, - 0x1f43a, 0x1f43b, 0x1f440, 0x1f442, - 0x1f443, 0x1f444, 0x1f446, 0x1f447, - 0x1f448, 0x1f449, 0x1f44a, 0x1f44b, - 0x1f44c, 0x1f44d, 0x1f44e, 0x1f44f, - 0x1f450, 0x1f451, 0x1f452, 0x1f454, - 0x1f455, 0x1f457, 0x1f458, 0x1f459, - 0x1f45c, 0x1f45f, 0x1f460, 0x1f461, - 0x1f462, 0x1f463, 0x1f466, 0x1f467, - 0x1f468, 0x1f469, 0x1f46b, 0x1f46e, - 0x1f46f, 0x1f471, 0x1f472, 0x1f473, - 0x1f474, 0x1f475, 0x1f476, 0x1f477, - 0x1f478, 0x1f47b, 0x1f47c, 0x1f47d, - 0x1f47e, 0x1f47f, 0x1f480, 0x1f481, - 0x1f482, 0x1f483, 0x1f484, 0x1f485, - 0x1f486, 0x1f487, 0x1f488, 0x1f489, - 0x1f48a, 0x1f48b, 0x1f48d, 0x1f48e, - 0x1f48f, 0x1f490, 0x1f491, 0x1f492, - 0x1f493, 0x1f494, 0x1f497, 0x1f498, - 0x1f499, 0x1f49a, 0x1f49b, 0x1f49c, - 0x1f49d, 0x1f49f, 0x1f4a1, 0x1f4a2, - 0x1f4a3, 0x1f4a4, 0x1f4a6, 0x1f4a8, - 0x1f4a9, 0x1f4aa, 0x1f4b0, 0x1f4b1, - 0x1f4b9, 0x1f4ba, 0x1f4bb, 0x1f4bc, - 0x1f4bd, 0x1f4bf, 0x1f4c0, 0x1f4d6, - 0x1f4dd, 0x1f4e0, 0x1f4e1, 0x1f4e2, - 0x1f4e3, 0x1f4e9, 0x1f4eb, 0x1f4ee, - 0x1f4f1, 0x1f4f2, 0x1f4f3, 0x1f4f4, - 0x1f4f6, 0x1f4f7, 0x1f4fa, 0x1f4fb, - 0x1f4fc, 0x1f50a, 0x1f50d, 0x1f511, - 0x1f512, 0x1f513, 0x1f514, 0x1f51d, - 0x1f51e, 0x1f525, 0x1f528, 0x1f52b, - 0x1f52f, 0x1f530, 0x1f531, 0x1f532, - 0x1f533, 0x1f534, 0x1f550, 0x1f551, - 0x1f552, 0x1f553, 0x1f554, 0x1f555, - 0x1f556, 0x1f557, 0x1f558, 0x1f559, - 0x1f55a, 0x1f55b, 0x1f5fb, 0x1f5fc, - 0x1f5fd, 0x1f601, 0x1f602, 0x1f603, - 0x1f604, 0x1f609, 0x1f60a, 0x1f60c, - 0x1f60d, 0x1f60f, 0x1f612, 0x1f613, - 0x1f614, 0x1f616, 0x1f618, 0x1f61a, - 0x1f61c, 0x1f61d, 0x1f61e, 0x1f620, - 0x1f621, 0x1f622, 0x1f623, 0x1f625, - 0x1f628, 0x1f62a, 0x1f62d, 0x1f630, - 0x1f631, 0x1f632, 0x1f633, 0x1f637, - 0x1f645, 0x1f646, 0x1f647, 0x1f64c, - 0x1f64f, 0x1f680, 0x1f683, 0x1f684, - 0x1f685, 0x1f687, 0x1f689, 0x1f68c, - 0x1f68f, 0x1f691, 0x1f692, 0x1f693, - 0x1f695, 0x1f697, 0x1f699, 0x1f69a, - 0x1f6a2, 0x1f6a4, 0x1f6a5, 0x1f6a7, - 0x1f6ac, 0x1f6ad, 0x1f6b2, 0x1f6b6, - 0x1f6b9, 0x1f6ba, 0x1f6bb, 0x1f6bc, - 0x1f6bd, 0x1f6be, 0x1f6c0, }; +static const unsigned short mb_tbl_uni_sb2code3_key[] = { // 0x1f004 - 0x1f6c0 + 0xf004, 0xf170, 0xf171, 0xf17e, + 0xf17f, 0xf18e, 0xf192, 0xf194, + 0xf195, 0xf197, 0xf199, 0xf19a, + 0xf1e8, 0xf1e9, 0xf1ea, 0xf1eb, + 0xf1ec, 0xf1ee, 0xf1ef, 0xf1f0, + 0xf1f7, 0xf1fa, 0xf201, 0xf202, + 0xf21a, 0xf22f, 0xf233, 0xf235, + 0xf236, 0xf237, 0xf238, 0xf239, + 0xf23a, 0xf250, 0xf300, 0xf302, + 0xf303, 0xf304, 0xf305, 0xf306, + 0xf307, 0xf308, 0xf30a, 0xf319, + 0xf31f, 0xf334, 0xf335, 0xf337, + 0xf338, 0xf339, 0xf33a, 0xf33b, + 0xf33e, 0xf340, 0xf341, 0xf342, + 0xf343, 0xf345, 0xf346, 0xf349, + 0xf34a, 0xf34e, 0xf353, 0xf354, + 0xf358, 0xf359, 0xf35a, 0xf35b, + 0xf35c, 0xf35d, 0xf35e, 0xf35f, + 0xf361, 0xf362, 0xf363, 0xf366, + 0xf367, 0xf370, 0xf371, 0xf372, + 0xf373, 0xf374, 0xf375, 0xf376, + 0xf378, 0xf37a, 0xf37b, 0xf380, + 0xf381, 0xf382, 0xf383, 0xf384, + 0xf385, 0xf386, 0xf387, 0xf388, + 0xf389, 0xf38c, 0xf38d, 0xf38e, + 0xf38f, 0xf390, 0xf391, 0xf392, + 0xf393, 0xf3a1, 0xf3a2, 0xf3a4, + 0xf3a5, 0xf3a6, 0xf3a7, 0xf3a8, + 0xf3a9, 0xf3ab, 0xf3ac, 0xf3af, + 0xf3b0, 0xf3b1, 0xf3b5, 0xf3b6, + 0xf3b7, 0xf3b8, 0xf3ba, 0xf3be, + 0xf3bf, 0xf3c0, 0xf3c1, 0xf3c3, + 0xf3c4, 0xf3c6, 0xf3c8, 0xf3ca, + 0xf3e0, 0xf3e2, 0xf3e3, 0xf3e5, + 0xf3e6, 0xf3e7, 0xf3e8, 0xf3e9, + 0xf3ea, 0xf3eb, 0xf3ec, 0xf3ed, + 0xf3ef, 0xf3f0, 0xf40d, 0xf40e, + 0xf411, 0xf412, 0xf414, 0xf417, + 0xf418, 0xf419, 0xf41a, 0xf41b, + 0xf41f, 0xf420, 0xf424, 0xf426, + 0xf427, 0xf428, 0xf42b, 0xf42c, + 0xf42d, 0xf42e, 0xf42f, 0xf430, + 0xf431, 0xf433, 0xf434, 0xf435, + 0xf436, 0xf437, 0xf438, 0xf439, + 0xf43a, 0xf43b, 0xf440, 0xf442, + 0xf443, 0xf444, 0xf446, 0xf447, + 0xf448, 0xf449, 0xf44a, 0xf44b, + 0xf44c, 0xf44d, 0xf44e, 0xf44f, + 0xf450, 0xf451, 0xf452, 0xf454, + 0xf455, 0xf457, 0xf458, 0xf459, + 0xf45c, 0xf45f, 0xf460, 0xf461, + 0xf462, 0xf463, 0xf466, 0xf467, + 0xf468, 0xf469, 0xf46b, 0xf46e, + 0xf46f, 0xf471, 0xf472, 0xf473, + 0xf474, 0xf475, 0xf476, 0xf477, + 0xf478, 0xf47b, 0xf47c, 0xf47d, + 0xf47e, 0xf47f, 0xf480, 0xf481, + 0xf482, 0xf483, 0xf484, 0xf485, + 0xf486, 0xf487, 0xf488, 0xf489, + 0xf48a, 0xf48b, 0xf48d, 0xf48e, + 0xf48f, 0xf490, 0xf491, 0xf492, + 0xf493, 0xf494, 0xf497, 0xf498, + 0xf499, 0xf49a, 0xf49b, 0xf49c, + 0xf49d, 0xf49f, 0xf4a1, 0xf4a2, + 0xf4a3, 0xf4a4, 0xf4a6, 0xf4a8, + 0xf4a9, 0xf4aa, 0xf4b0, 0xf4b1, + 0xf4b9, 0xf4ba, 0xf4bb, 0xf4bc, + 0xf4bd, 0xf4bf, 0xf4c0, 0xf4d6, + 0xf4dd, 0xf4e0, 0xf4e1, 0xf4e2, + 0xf4e3, 0xf4e9, 0xf4eb, 0xf4ee, + 0xf4f1, 0xf4f2, 0xf4f3, 0xf4f4, + 0xf4f6, 0xf4f7, 0xf4fa, 0xf4fb, + 0xf4fc, 0xf50a, 0xf50d, 0xf511, + 0xf512, 0xf513, 0xf514, 0xf51d, + 0xf51e, 0xf525, 0xf528, 0xf52b, + 0xf52f, 0xf530, 0xf531, 0xf532, + 0xf533, 0xf534, 0xf550, 0xf551, + 0xf552, 0xf553, 0xf554, 0xf555, + 0xf556, 0xf557, 0xf558, 0xf559, + 0xf55a, 0xf55b, 0xf5fb, 0xf5fc, + 0xf5fd, 0xf601, 0xf602, 0xf603, + 0xf604, 0xf609, 0xf60a, 0xf60c, + 0xf60d, 0xf60f, 0xf612, 0xf613, + 0xf614, 0xf616, 0xf618, 0xf61a, + 0xf61c, 0xf61d, 0xf61e, 0xf620, + 0xf621, 0xf622, 0xf623, 0xf625, + 0xf628, 0xf62a, 0xf62d, 0xf630, + 0xf631, 0xf632, 0xf633, 0xf637, + 0xf645, 0xf646, 0xf647, 0xf64c, + 0xf64f, 0xf680, 0xf683, 0xf684, + 0xf685, 0xf687, 0xf689, 0xf68c, + 0xf68f, 0xf691, 0xf692, 0xf693, + 0xf695, 0xf697, 0xf699, 0xf69a, + 0xf6a2, 0xf6a4, 0xf6a5, 0xf6a7, + 0xf6ac, 0xf6ad, 0xf6b2, 0xf6b6, + 0xf6b9, 0xf6ba, 0xf6bb, 0xf6bc, + 0xf6bd, 0xf6be, 0xf6c0, }; -const int mb_tbl_uni_sb2code3_value[] = { // 0x1f004 - 0x1f6c0 +static const unsigned short mb_tbl_uni_sb2code3_value[] = { // 0x1f004 - 0x1f6c0 0x27d5, 0x2b29, 0x2b2a, 0x2b2c, 0x27f7, 0x2b2b, 0x281b, 0x2830, 0x2819, 0x2854, 0x281a, 0x27d6, @@ -1153,3 +1155,73 @@ const int mb_tbl_uni_sb2code3_value[] = { // 0x1f004 - 0x1f6c0 0x298d, 0x280f, 0x27de, 0x2808, 0x27e0, 0x27e1, 0x27f9, 0x27e2, 0x27e8, 0x2988, 0x27e7, }; + +static const int mb_tbl_uni_sb2code3_len = sizeof(mb_tbl_uni_sb2code3_key)/sizeof(unsigned short); + +/* unsupported in Unicode 6.0 */ + +static const int mb_tbl_uni_docomo2code5_min = 0xfe82d; +static const int mb_tbl_uni_docomo2code5_max = 0xfee33; + +static const unsigned short mb_tbl_uni_docomo2code5_key[] = { // 0xfe82d - 0xfee33 + 0xE82D, 0xEE10, 0xEE11, 0xEE12, + 0xEE13, 0xEE14, 0xEE15, 0xEE16, + 0xEE17, 0xEE18, 0xEE19, 0xEE1A, + 0xEE1B, 0xEE1C, 0xEE1D, 0xEE1E, + 0xEE1F, 0xEE20, 0xEE21, 0xEE22, + 0xEE23, 0xEE24, 0xEE25, 0xEE26, + 0xEE27, 0xEE28, 0xEE29, 0xEE2A, + 0xEE2B, 0xEE2C, 0xEE2D, 0xEE2E, + 0xEE2F, 0xEE30, 0xEE31, 0xEE32, + 0xEE33, }; + +static const unsigned short mb_tbl_uni_docomo2code5_val[] = { // 0xfe82d - 0xfee33 + 0x2965, 0x2955, 0x2956, 0x2958, + 0x2959, 0x2990, 0x2991, 0x292A, + 0x292B, 0x292C, 0x292D, 0x292E, + 0x292F, 0x2933, 0x2934, 0x2938, + 0x2939, 0x293A, 0x293F, 0x2940, + 0x2941, 0x2942, 0x2943, 0x2944, + 0x2945, 0x2946, 0x2947, 0x2948, + 0x2949, 0x294A, 0x294B, 0x294C, + 0x294D, 0x294E, 0x294F, 0x2950, + 0x2951, }; + +static const unsigned short mb_tbl_uni_docomo2code5_len = sizeof(mb_tbl_uni_docomo2code5_key)/sizeof(unsigned short); + + +static const int mb_tbl_uni_kddi2code5_min = 0xfe82d; +static const int mb_tbl_uni_kddi2code5_max = 0xfee4a; + +static const unsigned short mb_tbl_uni_kddi2code5_key[] = { // 0xfe82d - 0xfee4a + 0xE82D, 0xE83C, 0xEB89, 0xEE40, + 0xEE41, 0xEE42, 0xEE43, 0xEE44, + 0xEE45, 0xEE46, 0xEE47, 0xEE48, + 0xEE49, 0xEE4A, }; + +static const unsigned short mb_tbl_uni_kddi2code5_val[] = { // 0xfe82d - 0xfee4a + 0x27B0, 0x280A, 0x2839, 0x27FB, + 0x2836, 0x24E8, 0x25AC, 0x25B9, + 0x25C1, 0x25C2, 0x25C3, 0x25C4, + 0x25C5, 0x25C6, }; + +static const unsigned short mb_tbl_uni_kddi2code5_len = sizeof(mb_tbl_uni_kddi2code5_key)/sizeof(unsigned short); + + +static const int mb_tbl_uni_sb2code5_min = 0xfe4c5; +static const int mb_tbl_uni_sb2code5_max = 0xfee7d; + +static const unsigned short mb_tbl_uni_sb2code5_key[] = { // 0xfe4c5 - 0xfee7d + 0xE4C5, 0xEE70, 0xEE71, 0xEE72, + 0xEE73, 0xEE74, 0xEE75, 0xEE76, + 0xEE77, 0xEE78, 0xEE79, 0xEE7A, + 0xEE7B, 0xEE7C, 0xEE7D, }; + +static const unsigned short mb_tbl_uni_sb2code5_val[] = { // 0xfe4c5 - 0xfee7d + 0x2B01, 0x2B2F, 0x2B30, 0x2B31, + 0x2B32, 0x2B33, 0x2B34, 0x2B35, + 0x285B, 0x285C, 0x285D, 0x285E, + 0x285F, 0x2860, 0x2861, }; + +static const unsigned short mb_tbl_uni_sb2code5_len = sizeof(mb_tbl_uni_sb2code5_key)/sizeof(unsigned short); + diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022_jp_ms.c b/ext/mbstring/libmbfl/filters/mbfilter_iso2022_jp_ms.c index a93ee4e4bbd05..a7daf2b913da4 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_iso2022_jp_ms.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022_jp_ms.c @@ -38,7 +38,7 @@ #include "unicode_table_jis.h" #include "cp932_table.h" -static int mbfl_filt_ident_2022jpms(int c, mbfl_identify_filter *filter); +int mbfl_filt_ident_2022jpms(int c, mbfl_identify_filter *filter); static const char *mbfl_encoding_2022jpms_aliases[] = {"ISO2022JPMS", NULL}; @@ -433,7 +433,7 @@ mbfl_filt_conv_any_2022jpms_flush(mbfl_convert_filter *filter) return 0; } -static int mbfl_filt_ident_2022jpms(int c, mbfl_identify_filter *filter) +int mbfl_filt_ident_2022jpms(int c, mbfl_identify_filter *filter) { retry: switch (filter->status & 0xf) { diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c new file mode 100644 index 0000000000000..4c8d9747143a5 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c @@ -0,0 +1,431 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_iso2022_jp_ms.c + * by Rui Hirokawa on 25 July 2011. + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mbfilter.h" +#include "mbfilter_iso2022jp_mobile.h" +#include "mbfilter_sjis_mobile.h" + +#include "unicode_table_cp932_ext.h" +#include "unicode_table_jis.h" +#include "cp932_table.h" + +extern int mbfl_filt_conv_any_jis_flush(mbfl_convert_filter *filter); +extern int mbfl_filt_ident_2022jpms(int c, mbfl_identify_filter *filter); + +const mbfl_encoding mbfl_encoding_2022jp_kddi = { + mbfl_no_encoding_2022jp_kddi, + "ISO-2022-JP-MOBILE#KDDI", + "ISO-2022-JP", + NULL, + NULL, + MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_SHFTCODE | MBFL_ENCTYPE_GL_UNSAFE +}; + +const struct mbfl_identify_vtbl vtbl_identify_2022jp_kddi = { + mbfl_no_encoding_2022jp_kddi, + mbfl_filt_ident_common_ctor, + mbfl_filt_ident_common_dtor, + mbfl_filt_ident_2022jpms +}; + +const struct mbfl_convert_vtbl vtbl_2022jp_kddi_wchar = { + mbfl_no_encoding_2022jp_kddi, + mbfl_no_encoding_wchar, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_2022jp_mobile_wchar, + mbfl_filt_conv_common_flush +}; + +const struct mbfl_convert_vtbl vtbl_wchar_2022jp_kddi = { + mbfl_no_encoding_wchar, + mbfl_no_encoding_2022jp_kddi, + mbfl_filt_conv_common_ctor, + mbfl_filt_conv_common_dtor, + mbfl_filt_conv_wchar_2022jp_mobile, + mbfl_filt_conv_any_jis_flush +}; + +#define CK(statement) do { if ((statement) < 0) return (-1); } while (0) + +#define sjistoidx(c1, c2) \ + (((c1) > 0x9f) \ + ? (((c1) - 0xc1) * 188 + (c2) - (((c2) > 0x7e) ? 0x41 : 0x40)) \ + : (((c1) - 0x81) * 188 + (c2) - (((c2) > 0x7e) ? 0x41 : 0x40))) +#define idxtojis1(c) (((c) / 94) + 0x21) +#define idxtojis2(c) (((c) % 94) + 0x21) + +#define SJIS_ENCODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + s1--; \ + s1 >>= 1; \ + if ((c1) < 0x5f) { \ + s1 += 0x71; \ + } else { \ + s1 += 0xb1; \ + } \ + s2 = c2; \ + if ((c1) & 1) { \ + if ((c2) < 0x60) { \ + s2--; \ + } \ + s2 += 0x20; \ + } else { \ + s2 += 0x7e; \ + } \ + } while (0) + +#define SJIS_DECODE(c1,c2,s1,s2) \ + do { \ + s1 = c1; \ + if (s1 < 0xa0) { \ + s1 -= 0x81; \ + } else { \ + s1 -= 0xc1; \ + } \ + s1 <<= 1; \ + s1 += 0x21; \ + s2 = c2; \ + if (s2 < 0x9f) { \ + if (s2 < 0x7f) { \ + s2++; \ + } \ + s2 -= 0x20; \ + } else { \ + s1++; \ + s2 -= 0x7e; \ + } \ + } while (0) + +#define CODE2JIS(c1,c2,s1,s2) \ + c1 = (s1)/94+0x21; \ + c2 = (s1)-94*((c1)-0x21)+0x21; \ + s1 = ((c1) << 8) | (c2); \ + s2 = 1 + +/* + * ISO-2022-JP-Mobile => wchar + */ +int +mbfl_filt_conv_2022jp_mobile_wchar(int c, mbfl_convert_filter *filter) +{ + int c1, c2, s, w, s1, s2, snd; + +retry: + switch (filter->status & 0xf) { +/* case 0x00: ASCII */ +/* case 0x10: X 0201 latin */ +/* case 0x20: X 0201 kana */ +/* case 0x80: X 0208 */ + case 0: + if (c == 0x1b) { + filter->status += 2; + } else if (filter->status == 0x20 && c > 0x20 && c < 0x60) { /* kana */ + CK((*filter->output_function)(0xff40 + c, filter->data)); + } else if (filter->status == 0x80 && c > 0x20 && c < 0x80) { /* kanji first char */ + filter->cache = c; + filter->status += 1; + } else if (c >= 0 && c < 0x80) { /* latin, CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else if (c > 0xa0 && c < 0xe0) { /* GR kana */ + CK((*filter->output_function)(0xfec0 + c, filter->data)); + } else { + w = c & MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + +/* case 0x81: X 0208 second char */ + case 1: + w = 0; + filter->status &= ~0xf; + c1 = filter->cache; + if (c > 0x20 && c < 0x7f) { + s = (c1 - 0x21)*94 + c - 0x21; + + if (s <= 137) { + if (s == 31) { + w = 0xff3c; /* FULLWIDTH REVERSE SOLIDUS */ + } else if (s == 32) { + w = 0xff5e; /* FULLWIDTH TILDE */ + } else if (s == 33) { + w = 0x2225; /* PARALLEL TO */ + } else if (s == 60) { + w = 0xff0d; /* FULLWIDTH HYPHEN-MINUS */ + } else if (s == 80) { + w = 0xffe0; /* FULLWIDTH CENT SIGN */ + } else if (s == 81) { + w = 0xffe1; /* FULLWIDTH POUND SIGN */ + } else if (s == 137) { + w = 0xffe2; /* FULLWIDTH NOT SIGN */ + } + } + + if (w == 0) { + if (s >= cp932ext1_ucs_table_min && s < cp932ext1_ucs_table_max) { /* vendor ext1 (13ku) */ + w = cp932ext1_ucs_table[s - cp932ext1_ucs_table_min]; + } else if (s >= 0 && s < jisx0208_ucs_table_size) { + w = jisx0208_ucs_table[s]; + } else { + w = 0; + } + } + + if (s >= (84*94) && s < 91*94) { + s += 22*94; + if (filter->from->no_encoding == mbfl_no_encoding_2022jp_kddi) { + w = mbfilter_sjis_emoji_kddi2unicode(s, &snd); + } + if (w > 0 && snd > 0) { + CK((*filter->output_function)(snd, filter->data)); + } + } + + if (w <= 0) { + w = (c1 << 8) | c; + w &= MBFL_WCSPLANE_MASK; + w |= MBFL_WCSPLANE_JIS0208; + } + CK((*filter->output_function)(w, filter->data)); + } else if (c == 0x1b) { + filter->status += 2; + } else if ((c >= 0 && c < 0x21) || c == 0x7f) { /* CTLs */ + CK((*filter->output_function)(c, filter->data)); + } else { + w = (c1 << 8) | c; + w &= MBFL_WCSGROUP_MASK; + w |= MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + } + break; + + /* ESC */ +/* case 0x02: */ +/* case 0x12: */ +/* case 0x22: */ +/* case 0x82: */ + case 2: + if (c == 0x24) { /* '$' */ + filter->status++; + } else if (c == 0x28) { /* '(' */ + filter->status += 3; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + goto retry; + } + break; + + /* ESC $ */ +/* case 0x03: */ +/* case 0x13: */ +/* case 0x23: */ +/* case 0x83: */ + case 3: + if (c == 0x40 || c == 0x42) { /* '@' or 'B' */ + filter->status = 0x80; + } else if (c == 0x28) { /* '(' */ + filter->status++; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + goto retry; + } + break; + + /* ESC $ ( */ +/* case 0x04: */ +/* case 0x14: */ +/* case 0x24: */ +/* case 0x84: */ + case 4: + if (c == 0x40 || c == 0x42) { /* '@' or 'B' */ + filter->status = 0x80; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x24, filter->data)); + CK((*filter->output_function)(0x28, filter->data)); + goto retry; + } + break; + + /* ESC ( */ +/* case 0x05: */ +/* case 0x15: */ +/* case 0x25: */ +/* case 0x85: */ + case 5: + if (c == 0x42) { /* 'B' */ + filter->status = 0; + } else if (c == 0x4a) { /* 'J' */ + filter->status = 0; + } else if (c == 0x49) { /* 'I' */ + filter->status = 0x20; + } else { + filter->status &= ~0xf; + CK((*filter->output_function)(0x1b, filter->data)); + CK((*filter->output_function)(0x28, filter->data)); + goto retry; + } + break; + + default: + filter->status = 0; + break; + } + + return c; +} + +/* + * wchar => ISO-2022-JP-Mobile + */ +int +mbfl_filt_conv_wchar_2022jp_mobile(int c, mbfl_convert_filter *filter) +{ + int c1, c2, s1, s2; + + s1 = 0; + s2 = 0; + if (c >= ucs_a1_jis_table_min && c < ucs_a1_jis_table_max) { + s1 = ucs_a1_jis_table[c - ucs_a1_jis_table_min]; + } else if (c >= ucs_a2_jis_table_min && c < ucs_a2_jis_table_max) { + s1 = ucs_a2_jis_table[c - ucs_a2_jis_table_min]; + } else if (c >= ucs_i_jis_table_min && c < ucs_i_jis_table_max) { + s1 = ucs_i_jis_table[c - ucs_i_jis_table_min]; + } else if (c >= ucs_r_jis_table_min && c < ucs_r_jis_table_max) { + s1 = ucs_r_jis_table[c - ucs_r_jis_table_min]; + } else if (c >= 0xe000 && c < (0xe000 + 20*94)) { /* user (95ku - 114ku) */ + s1 = c - 0xe000; + c1 = s1/94 + 0x7f; + c2 = s1%94 + 0x21; + s1 = (c1 << 8) | c2; + } + if (s1 <= 0) { + c1 = c & ~MBFL_WCSPLANE_MASK; + if (c1 == MBFL_WCSPLANE_WINCP932) { + s1 = c & MBFL_WCSPLANE_MASK; + s2 = 1; + } else if (c1 == MBFL_WCSPLANE_JIS0208) { + s1 = c & MBFL_WCSPLANE_MASK; + } else if (c1 == MBFL_WCSPLANE_JIS0212) { + s1 = c & MBFL_WCSPLANE_MASK; + s1 |= 0x8080; + } else if (c == 0xa5) { /* YEN SIGN */ + s1 = 0x216f; /* FULLWIDTH YEN SIGN */ + } else if (c == 0x203e) { /* OVER LINE */ + s1 = 0x2131; /* FULLWIDTH MACRON */ + } else if (c == 0xff3c) { /* FULLWIDTH REVERSE SOLIDUS */ + s1 = 0x2140; + } else if (c == 0xff5e) { /* FULLWIDTH TILDE */ + s1 = 0x2141; + } else if (c == 0x2225) { /* PARALLEL TO */ + s1 = 0x2142; + } else if (c == 0xff0d) { /* FULLWIDTH HYPHEN-MINUS */ + s1 = 0x215d; + } else if (c == 0xffe0) { /* FULLWIDTH CENT SIGN */ + s1 = 0x2171; + } else if (c == 0xffe1) { /* FULLWIDTH POUND SIGN */ + s1 = 0x2172; + } else if (c == 0xffe2) { /* FULLWIDTH NOT SIGN */ + s1 = 0x224c; + } + } + + if ((s1 <= 0) || (s1 >= 0xa1a1 && s2 == 0)) { /* not found or X 0212 */ + s1 = -1; + c1 = 0; + c2 = cp932ext1_ucs_table_max - cp932ext1_ucs_table_min; + while (c1 < c2) { /* CP932 vendor ext1 (13ku) */ + if (c == cp932ext1_ucs_table[c1]) { + s1 = ((c1/94 + 0x2d) << 8) + (c1%94 + 0x21); + break; + } + c1++; + } + if (c == 0) { + s1 = 0; + } else if (s1 <= 0) { + s1 = -1; + } + } + + if (filter->to->no_encoding == mbfl_no_encoding_2022jp_kddi && + mbfilter_unicode2sjis_emoji_kddi(c, &s1, filter) > 0) { + CODE2JIS(c1,c2,s1,s2); + s1 -= 0x1600; + } + + if (filter->status == 1 && filter->cache > 0) { + return c; + } + + if (s1 >= 0) { + if (s1 < 0x80) { /* latin */ + if ((filter->status & 0xff00) != 0) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x42, filter->data)); /* 'B' */ + } + CK((*filter->output_function)(s1, filter->data)); + filter->status = 0; + } else if (s1 > 0xa0 && s1 < 0xe0) { /* kana */ + if ((filter->status & 0xff00) != 0x100) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x28, filter->data)); /* '(' */ + CK((*filter->output_function)(0x49, filter->data)); /* 'I' */ + } + filter->status = 0x100; + CK((*filter->output_function)(s1 & 0x7f, filter->data)); + } else if (s1 < 0x7e7f) { /* X 0208 */ + if ((filter->status & 0xff00) != 0x200) { + CK((*filter->output_function)(0x1b, filter->data)); /* ESC */ + CK((*filter->output_function)(0x24, filter->data)); /* '$' */ + CK((*filter->output_function)(0x42, filter->data)); /* 'B' */ + } + filter->status = 0x200; + CK((*filter->output_function)((s1 >> 8) & 0xff, filter->data)); + CK((*filter->output_function)(s1 & 0x7f, filter->data)); + } + } else { + if (filter->illegal_mode != MBFL_OUTPUTFILTER_ILLEGAL_MODE_NONE) { + CK(mbfl_filt_conv_illegal_output(c, filter)); + } + } + + return c; +} diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.h new file mode 100644 index 0000000000000..7ae1da2ddc1c9 --- /dev/null +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.h @@ -0,0 +1,43 @@ +/* + * "streamable kanji code filter and converter" + * Copyright (c) 1998-2002 HappySize, Inc. All rights reserved. + * + * LICENSE NOTICES + * + * This file is part of "streamable kanji code filter and converter", + * which is distributed under the terms of GNU Lesser General Public + * License (version 2) as published by the Free Software Foundation. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with "streamable kanji code filter and converter"; + * if not, write to the Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307 USA + * + * The author of this file: + * + */ +/* + * The source code included in this files was separated from mbfilter_iso2022_jp_ms.h + * by Rui Hirokawa on 25 July 2011. + * + */ + +#ifndef MBFL_MBFILTER_ISO2022_JP_MOBILE_H +#define MBFL_MBFILTER_ISO2022_JP_MOBILE_H + +#include "mbfilter.h" + +extern const mbfl_encoding mbfl_encoding_2022jp_kddi; +extern const struct mbfl_identify_vtbl vtbl_identify_2022jp_kddi; +extern const struct mbfl_convert_vtbl vtbl_2022jp_kddi_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_2022jp_kddi; + +int mbfl_filt_conv_2022jp_mobile_wchar(int c, mbfl_convert_filter *filter); +int mbfl_filt_conv_wchar_2022jp_mobile(int c, mbfl_convert_filter *filter); + +#endif /* MBFL_MBFILTER_ISO2022_JP_MOBILE_H */ diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c index 7bce1854548d0..37ea55e4b8e6f 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -40,6 +40,7 @@ #include "emoji2uni.h" +extern int mbfl_bisec_srch2(int w, const unsigned short tbl[], int n); extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); extern const unsigned char mblen_table_sjis[]; @@ -149,14 +150,14 @@ static const char nflags_s[10][2] = {"CN","DE","ES","FR","GB","IT","JP","KR","RU static const int nflags_code_kddi[10] = {0x2549, 0x2546, 0x24c0, 0x2545, 0x2548, 0x2547, 0x2750, 0x254a, 0x24c1, 0x27f7}; static const int nflags_code_sb[10] = {0x2b0a, 0x2b05, 0x2b08, 0x2b04, 0x2b07, 0x2b06, 0x2b02, 0x2b0b, 0x2b09, 0x2b03}; -const int mbfl_docomo2uni_pua[4][3] = { +const unsigned short mbfl_docomo2uni_pua[4][3] = { {0x28c2, 0x2929, 0xe63e}, {0x2930, 0x2932, 0xe6ac}, {0x2935, 0x293e, 0xe6b1}, {0x2952, 0x29db, 0xe6ce}, }; -const int mbfl_kddi2uni_pua[6][3] = { +const unsigned short mbfl_kddi2uni_pua[6][3] = { {0x26ec, 0x2838, 0xe468}, {0x284c, 0x2863, 0xe5b5}, {0x24b8, 0x24ca, 0xe5cd}, @@ -165,7 +166,7 @@ const int mbfl_kddi2uni_pua[6][3] = { {0x2546, 0x25c0, 0xeb0e}, }; -const int mbfl_sb2uni_pua[6][3] = { +const unsigned short mbfl_sb2uni_pua[6][3] = { {0x27a9, 0x2802, 0xe101}, {0x2808, 0x285a, 0xe201}, {0x2921, 0x297a, 0xe001}, @@ -174,7 +175,7 @@ const int mbfl_sb2uni_pua[6][3] = { {0x2af8, 0x2b2e, 0xe501}, }; -const int mbfl_kddi2uni_pua_b[8][3] = { +const unsigned short mbfl_kddi2uni_pua_b[8][3] = { {0x24b8, 0x24f6, 0xec40}, {0x24f7, 0x2573, 0xec80}, {0x2574, 0x25b2, 0xed40}, @@ -239,7 +240,7 @@ const int mbfl_kddi2uni_pua_b[8][3] = { s2 = 1 int -mbfilter_conv_map_tbl(int c, int *w, const int map[][3], int n) +mbfilter_conv_map_tbl(int c, int *w, const unsigned short map[][3], int n) { int i, match = 0; @@ -254,7 +255,7 @@ mbfilter_conv_map_tbl(int c, int *w, const int map[][3], int n) } int -mbfilter_conv_r_map_tbl(int c, int *w, const int map[][3], int n) +mbfilter_conv_r_map_tbl(int c, int *w, const unsigned short map[][3], int n) { int i, match = 0; @@ -268,21 +269,6 @@ mbfilter_conv_r_map_tbl(int c, int *w, const int map[][3], int n) return match; } -int -mbfilter_conv_seq_tbl(int c, int *w, const int *key, const int *val, int n) -{ - int i, match = 0; - for (i = 0; i< n; i++) { - if (c == key[i]) { - *w = val[i]; - match = 1; - break; - } - } - return match; -} - - int mbfilter_sjis_emoji_docomo2unicode(int s, int *snd) { @@ -293,14 +279,23 @@ mbfilter_sjis_emoji_docomo2unicode(int s, int *snd) s != mb_tbl_code2uni_docomo1_min + 0x00a3) { w = 0x20E3; *snd = mb_tbl_code2uni_docomo1[s - mb_tbl_code2uni_docomo1_min]; + if (*snd > 0xf000) { + *snd += 0x10000; + } } else { w = mb_tbl_code2uni_docomo1[s - mb_tbl_code2uni_docomo1_min]; + if (w > 0xf000) { + w += 0x10000; + } else if (w > 0xe000) { /* unsuported by Unicode 6.0 */ + w += 0xf0000; + } *snd = 0; if (!w) { w = s; } } } + return w; } @@ -324,6 +319,11 @@ mbfilter_sjis_emoji_kddi2unicode(int s, int *snd) *snd = 0x0023; w = 0x20E3; } else { w = mb_tbl_code2uni_kddi1[si]; + if (w > 0xf000) { + w += 0x10000; + } else if (w > 0xe000) { /* unsuported by Unicode 6.0 */ + w += 0xf0000; + } } } else if (s >= mb_tbl_code2uni_kddi2_min && s <= mb_tbl_code2uni_kddi2_max) { si = s - mb_tbl_code2uni_kddi2_min; @@ -337,6 +337,11 @@ mbfilter_sjis_emoji_kddi2unicode(int s, int *snd) *snd = 0x0030; w = 0x20E3; } else { w = mb_tbl_code2uni_kddi2[si]; + if (w > 0xf000) { + w += 0x10000; + } else if (w > 0xe000) { /* unsuported by Unicode 6.0 */ + w += 0xf0000; + } } } return w; @@ -353,13 +358,26 @@ mbfilter_sjis_emoji_sb2unicode(int s, int *snd) si = s - mb_tbl_code2uni_sb1_min; if (si == 0x006e || (si >= 0x007a && si <= 0x0083)) { *snd = mb_tbl_code2uni_sb1[si]; + if (*snd > 0xf000) { + *snd += 0x10000; + } w = 0x20E3; } else { w = mb_tbl_code2uni_sb1[si]; + if (w > 0xf000) { + w += 0x10000; + } else if (w > 0xe000) { /* unsuported by Unicode 6.0 */ + w += 0xf0000; + } } } else if (s >= mb_tbl_code2uni_sb2_min && s <= mb_tbl_code2uni_sb2_max) { si = s - mb_tbl_code2uni_sb2_min; w = mb_tbl_code2uni_sb2[si]; + if (w > 0xf000) { + w += 0x10000; + } else if (w > 0xe000) { /* unsuported by Unicode 6.0 */ + w += 0xf0000; + } } else if (s >= mb_tbl_code2uni_sb3_min && s <= mb_tbl_code2uni_sb3_max) { si = s - mb_tbl_code2uni_sb3_min; if (si >= 0x0069 && si <= 0x0072) { @@ -367,6 +385,11 @@ mbfilter_sjis_emoji_sb2unicode(int s, int *snd) *snd = NFLAGS(nflags_s[c][0]); w = NFLAGS(nflags_s[c][1]); } else { w = mb_tbl_code2uni_sb3[si]; + if (w > 0xf000) { + w += 0x10000; + } else if (w > 0xe000) { /* unsuported by Unicode 6.0 */ + w += 0xf0000; + } } } return w; @@ -408,11 +431,23 @@ mbfilter_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filter) } else if (c == 0x00AE) { *s1 = 0x29ba; match = 1; } else if (c >= mb_tbl_uni_docomo2code2_min && c <= mb_tbl_uni_docomo2code2_max) { - match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_docomo2code2_key, mb_tbl_uni_docomo2code2_value, - sizeof(mb_tbl_uni_docomo2code2_key)/sizeof(int)); + i = mbfl_bisec_srch2(c, mb_tbl_uni_docomo2code2_key, mb_tbl_uni_docomo2code2_len); + if (i >= 0) { + *s1 = mb_tbl_uni_docomo2code2_value[i]; + match = 1; + } } else if (c >= mb_tbl_uni_docomo2code3_min && c <= mb_tbl_uni_docomo2code3_max) { - match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_docomo2code3_key, mb_tbl_uni_docomo2code3_value, - sizeof(mb_tbl_uni_docomo2code3_key)/sizeof(int)); + i = mbfl_bisec_srch2(c - 0x10000, mb_tbl_uni_docomo2code3_key, mb_tbl_uni_docomo2code3_len); + if (i >= 0) { + *s1 = mb_tbl_uni_docomo2code3_value[i]; + match = 1; + } + } else if (c >= mb_tbl_uni_docomo2code5_min && c <= mb_tbl_uni_docomo2code5_max) { + i = mbfl_bisec_srch2(c - 0xf0000, mb_tbl_uni_docomo2code5_key, mb_tbl_uni_docomo2code5_len); + if (i >= 0) { + *s1 = mb_tbl_uni_docomo2code5_val[i]; + match = 1; + } } } @@ -467,12 +502,24 @@ mbfilter_unicode2sjis_emoji_kddi(int c, int *s1, mbfl_convert_filter *filter) } else if (c == 0x00AE) { *s1 = 0x27dd; match = 1; } else if (c >= mb_tbl_uni_kddi2code2_min && c <= mb_tbl_uni_kddi2code2_max) { - match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_kddi2code2_key, mb_tbl_uni_kddi2code2_value, - sizeof(mb_tbl_uni_kddi2code2_key)/sizeof(int)); + i = mbfl_bisec_srch2(c, mb_tbl_uni_kddi2code2_key, mb_tbl_uni_kddi2code2_len); + if (i >= 0) { + *s1 = mb_tbl_uni_kddi2code2_value[i]; + match = 1; + } } else if (c >= mb_tbl_uni_kddi2code3_min && c <= mb_tbl_uni_kddi2code3_max) { - match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_kddi2code3_key, mb_tbl_uni_kddi2code3_value, - sizeof(mb_tbl_uni_kddi2code3_key)/sizeof(int)); - } + i = mbfl_bisec_srch2(c - 0x10000, mb_tbl_uni_kddi2code3_key, mb_tbl_uni_kddi2code3_len); + if (i >= 0) { + *s1 = mb_tbl_uni_kddi2code3_value[i]; + match = 1; + } + } else if (c >= mb_tbl_uni_kddi2code5_min && c <= mb_tbl_uni_kddi2code5_max) { + i = mbfl_bisec_srch2(c - 0xf0000, mb_tbl_uni_kddi2code5_key, mb_tbl_uni_kddi2code5_len); + if (i >= 0) { + *s1 = mb_tbl_uni_kddi2code5_val[i]; + match = 1; + } + } } return match; @@ -525,14 +572,25 @@ mbfilter_unicode2sjis_emoji_sb(int c, int *s1, mbfl_convert_filter *filter) } else if (c == 0x00AE) { *s1 = 0x2856; match = 1; } else if (c >= mb_tbl_uni_sb2code2_min && c <= mb_tbl_uni_sb2code2_max) { - match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_sb2code2_key, mb_tbl_uni_sb2code2_value, - sizeof(mb_tbl_uni_sb2code2_key)/sizeof(int)); + i = mbfl_bisec_srch2(c, mb_tbl_uni_sb2code2_key, mb_tbl_uni_sb2code2_len); + if (i >= 0) { + *s1 = mb_tbl_uni_sb2code2_value[i]; + match = 1; + } } else if (c >= mb_tbl_uni_sb2code3_min && c <= mb_tbl_uni_sb2code3_max) { - match = mbfilter_conv_seq_tbl(c, s1, mb_tbl_uni_sb2code3_key, mb_tbl_uni_sb2code3_value, - sizeof(mb_tbl_uni_sb2code3_key)/sizeof(int)); - } + i = mbfl_bisec_srch2(c - 0x10000, mb_tbl_uni_sb2code3_key, mb_tbl_uni_sb2code3_len); + if (i >= 0) { + *s1 = mb_tbl_uni_sb2code3_value[i]; + match = 1; + } + } else if (c >= mb_tbl_uni_sb2code5_min && c <= mb_tbl_uni_sb2code5_max) { + i = mbfl_bisec_srch2(c - 0xf0000, mb_tbl_uni_sb2code5_key, mb_tbl_uni_sb2code5_len); + if (i >= 0) { + *s1 = mb_tbl_uni_sb2code5_val[i]; + match = 1; + } + } } - return match; } @@ -545,6 +603,7 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) int c1, s, s1, s2, w; int snd = 0; +retry: switch (filter->status) { case 0: if (c >= 0 && c < 0x80) { /* latin */ @@ -632,34 +691,37 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) CK((*filter->output_function)(w, filter->data)); } break; + /* ESC : Softbank Emoji */ case 2: if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb && c == 0x24) { filter->cache = c; - filter->status = 3; + filter->status++; } else { filter->cache = 0; filter->status = 0; CK((*filter->output_function)(0x1b, filter->data)); + goto retry; } break; + /* ESC $ : Softbank Emoji */ case 3: - /* Softbank Emoji: ESC $ [GEFOPQ] X 0x0f */ if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb && ((c >= 0x45 && c <= 0x47) || (c >= 0x4f && c <= 0x51))) { filter->cache = c; - filter->status = 4; + filter->status++; } else { filter->cache = 0; filter->status = 0; CK((*filter->output_function)(0x1b, filter->data)); CK((*filter->output_function)(0x24, filter->data)); + goto retry; } break; + /* ESC [GEFOPQ] : Softbank Emoji */ case 4: - /* Softbank Emoji Web code: ESC $ [GEFOPQ] X 0x0f */ w = 0; if (filter->from->no_encoding == mbfl_no_encoding_sjis_sb) { c1 = filter->cache; @@ -684,10 +746,10 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) } s = (s1 - 0x21)*94 + s2 - 0x21; w = mbfilter_sjis_emoji_sb2unicode(s, &snd); - if (w > 0 && snd > 0) { - CK((*filter->output_function)(snd, filter->data)); - } if (w > 0) { + if (snd > 0) { + CK((*filter->output_function)(snd, filter->data)); + } CK((*filter->output_function)(w, filter->data)); } } @@ -697,12 +759,10 @@ mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter) c1 = filter->cache; filter->cache = 0; filter->status = 0; - w = c & MBFL_WCSGROUP_MASK; - w |= MBFL_WCSGROUP_THROUGH; CK((*filter->output_function)(0x1b, filter->data)); CK((*filter->output_function)(0x24, filter->data)); CK((*filter->output_function)(c1 & 0xff, filter->data)); - CK((*filter->output_function)(w, filter->data)); + goto retry; } break; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h index 9de8988c22858..b230de528c5e1 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -59,7 +59,7 @@ int mbfilter_unicode2sjis_emoji_docomo(int c, int *s1, mbfl_convert_filter *filt int mbfilter_unicode2sjis_emoji_kddi(int c, int *s1, mbfl_convert_filter *filter); int mbfilter_unicode2sjis_emoji_sb(int c, int *s1, mbfl_convert_filter *filter); -int mbfilter_conv_map_tbl(int c, int *w, const int map[][3], int n); -int mbfilter_conv_r_map_tbl(int c, int *w, const int map[][3], int n); +int mbfilter_conv_map_tbl(int c, int *w, const unsigned short map[][3], int n); +int mbfilter_conv_r_map_tbl(int c, int *w, const unsigned short map[][3], int n); #endif /* MBFL_MBFILTER_SJIS_MOBILE_H */ diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index f9238ceb3794a..36c488af7ab9b 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -59,6 +59,7 @@ #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_iso2022jp_2004.h" +#include "filters/mbfilter_iso2022jp_mobile.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_2004.h" #include "filters/mbfilter_euc_jp_win.h" @@ -132,6 +133,8 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_2022jpms, &vtbl_2022jp_2004_wchar, &vtbl_wchar_2022jp_2004, + &vtbl_2022jp_kddi_wchar, + &vtbl_wchar_2022jp_kddi, &vtbl_eucjpwin_wchar, &vtbl_wchar_eucjpwin, &vtbl_eucjp2004_wchar, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index 31151d70ee4fb..df63e8ae196b9 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -65,6 +65,7 @@ #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_iso2022jp_2004.h" +#include "filters/mbfilter_iso2022jp_mobile.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" #include "filters/mbfilter_euc_jp_2004.h" @@ -212,6 +213,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_cp850, &mbfl_encoding_jis_ms, &mbfl_encoding_2022jp_2004, + &mbfl_encoding_2022jp_kddi, &mbfl_encoding_cp50220, &mbfl_encoding_cp50220raw, &mbfl_encoding_cp50221, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index 625dd0ae2dd23..8cb752d422560 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -84,6 +84,7 @@ enum mbfl_no_encoding { mbfl_no_encoding_jis, mbfl_no_encoding_2022jp, mbfl_no_encoding_2022jp_2004, + mbfl_no_encoding_2022jp_kddi, mbfl_no_encoding_2022jpms, mbfl_no_encoding_gb18030, mbfl_no_encoding_cp1252, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c index 23c26190196df..e2594d5667641 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c @@ -55,6 +55,7 @@ #include "filters/mbfilter_jis.h" #include "filters/mbfilter_iso2022_jp_ms.h" #include "filters/mbfilter_iso2022jp_2004.h" +#include "filters/mbfilter_iso2022jp_mobile.h" #include "filters/mbfilter_euc_jp.h" #include "filters/mbfilter_euc_jp_win.h" #include "filters/mbfilter_euc_jp_2004.h" @@ -122,6 +123,7 @@ static const struct mbfl_identify_vtbl *mbfl_identify_filter_list[] = { &vtbl_identify_2022jp, &vtbl_identify_2022jpms, &vtbl_identify_2022jp_2004, + &vtbl_identify_2022jp_kddi, &vtbl_identify_cp51932, &vtbl_identify_sjis_docomo, &vtbl_identify_sjis_kddi, From fa09c70704fd23ab83114cb67ab7d06ebd271d6f Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Thu, 25 Aug 2011 06:00:11 +0000 Subject: [PATCH 0611/2394] tune test's README more per FR #55474 --- ext/snmp/tests/README | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ext/snmp/tests/README b/ext/snmp/tests/README index a2cb794913d2c..819a50d8a20df 100644 --- a/ext/snmp/tests/README +++ b/ext/snmp/tests/README @@ -16,6 +16,13 @@ SNMP_COMMUNITY : community name SNMP_COMMUNITY_WRITE : community used for write tests (snmpset()). SNMP_MIBDIR : Directory containing MIBS +To run test suite you may use this command (presuming that you pwd is where +this README file is located): +> make -C ../../.. test TESTS="`cd ../../..; /bin/ls -1 ext/snmp/tests/*.phpt | xargs echo`" +Running run-tests.php directly will clear your environment and therefore +tests will fail if your SNMP configuration does not fit into default values +specified in snmp_include.inc. + ** Configuring the SNMPD server ** On Linux/FreeBSD From a70240637df40e38805da9c352f9ef18618be27a Mon Sep 17 00:00:00 2001 From: Sebastian Bergmann Date: Fri, 26 Aug 2011 07:40:31 +0000 Subject: [PATCH 0612/2394] Close #55490. --- ext/reflection/php_reflection.c | 23 +++++++++++++ ...onClass_newInstanceWithoutConstructor.phpt | 33 +++++++++++++++++++ .../tests/ReflectionClass_toString_001.phpt | 8 ++++- 3 files changed, 63 insertions(+), 1 deletion(-) create mode 100644 ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 3dfd2f276b7b9..1dd8d4a8a2488 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -4129,6 +4129,25 @@ ZEND_METHOD(reflection_class, newInstance) } /* }}} */ +/* {{{ proto public stdclass ReflectionClass::newInstanceWithoutConstructor() + Returns an instance of this class without invoking its constructor */ +ZEND_METHOD(reflection_class, newInstanceWithoutConstructor) +{ + zval *retval_ptr = NULL; + reflection_object *intern; + zend_class_entry *ce; + + METHOD_NOTSTATIC(reflection_class_ptr); + GET_REFLECTION_OBJECT_PTR(ce); + + if (ce->create_object != NULL) { + zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Class %s is an internal class that cannot be instantiated without invoking its constructor", ce->name); + } + + object_init_ex(return_value, ce); +} +/* }}} */ + /* {{{ proto public stdclass ReflectionClass::newInstanceArgs([array args]) Returns an instance of this class */ ZEND_METHOD(reflection_class, newInstanceArgs) @@ -5694,6 +5713,9 @@ ZEND_BEGIN_ARG_INFO(arginfo_reflection_class_newInstance, 0) ZEND_ARG_INFO(0, args) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_reflection_class_newInstanceWithoutConstructor, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_reflection_class_newInstanceArgs, 0, 0, 0) ZEND_ARG_ARRAY_INFO(0, args, 0) ZEND_END_ARG_INFO() @@ -5742,6 +5764,7 @@ static const zend_function_entry reflection_class_functions[] = { ZEND_ME(reflection_class, getModifiers, arginfo_reflection__void, 0) ZEND_ME(reflection_class, isInstance, arginfo_reflection_class_isInstance, 0) ZEND_ME(reflection_class, newInstance, arginfo_reflection_class_newInstance, 0) + ZEND_ME(reflection_class, newInstanceWithoutConstructor, arginfo_reflection_class_newInstanceWithoutConstructor, 0) ZEND_ME(reflection_class, newInstanceArgs, arginfo_reflection_class_newInstanceArgs, 0) ZEND_ME(reflection_class, getParentClass, arginfo_reflection__void, 0) ZEND_ME(reflection_class, isSubclassOf, arginfo_reflection_class_isSubclassOf, 0) diff --git a/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt b/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt new file mode 100644 index 0000000000000..fffddf4f62330 --- /dev/null +++ b/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt @@ -0,0 +1,33 @@ +--TEST-- +ReflectionClass::newInstanceWithoutConstructor() +--CREDITS-- +Sebastian Bergmann +--FILE-- +newInstanceWithoutConstructor()); + +$class = new ReflectionClass('StdClass'); +var_dump($class->newInstanceWithoutConstructor()); + +$class = new ReflectionClass('DateTime'); +var_dump($class->newInstanceWithoutConstructor()); +--EXPECTF-- +object(Foo)#%d (0) { +} +object(stdClass)#%d (0) { +} + +Fatal error: Uncaught exception 'ReflectionException' with message 'Class DateTime is an internal class that cannot be instantiated without invoking its constructor' in %s/tests/ReflectionClass_newInstanceWithoutConstructor.php:%d +Stack trace: +#0 %s/ReflectionClass_newInstanceWithoutConstructor.php(%d): ReflectionClass->newInstanceWithoutConstructor() +#1 {main} + thrown in %s/ReflectionClass_newInstanceWithoutConstructor.php on line %d diff --git a/ext/reflection/tests/ReflectionClass_toString_001.phpt b/ext/reflection/tests/ReflectionClass_toString_001.phpt index 8b74b65ead4e7..508530a5478fb 100644 --- a/ext/reflection/tests/ReflectionClass_toString_001.phpt +++ b/ext/reflection/tests/ReflectionClass_toString_001.phpt @@ -34,7 +34,7 @@ Class [ class ReflectionClass implements Reflector ] { Property [ public $name ] } - - Methods [48] { + - Methods [49] { Method [ final private method __clone ] { - Parameters [0] { @@ -250,6 +250,12 @@ Class [ class ReflectionClass implements Reflector ] { } } + Method [ public method newInstanceWithoutConstructor ] { + + - Parameters [0] { + } + } + Method [ public method newInstanceArgs ] { - Parameters [1] { From ee17839f209505657ad05762cae838bc0f0e3094 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 26 Aug 2011 12:14:31 +0000 Subject: [PATCH 0613/2394] fix valgrind warnings in debug builds --- ext/mysqlnd/mysqlnd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 80d315a1bd2a2..7f04d35517ebb 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -1523,7 +1523,7 @@ MYSQLND_METHOD(mysqlnd_conn, kill)(MYSQLND * conn, unsigned int pid TSRMLS_DC) zend_uchar buff[4]; DBG_ENTER("mysqlnd_conn::kill"); - DBG_INF_FMT("conn=%llu pid=%lu", conn->thread_id, pid); + DBG_INF_FMT("conn=%llu pid=%u", conn->thread_id, pid); int4store(buff, pid); From e20f46a43ee89e58b312e4f17a59899beac446f3 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 27 Aug 2011 00:07:20 +0000 Subject: [PATCH 0614/2394] update pua conversion tables. --- ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h | 5 +++++ ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c | 4 ---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h index b230de528c5e1..34de0e909979a 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.h @@ -47,6 +47,11 @@ extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_kddi; extern const struct mbfl_convert_vtbl vtbl_sjis_sb_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_sjis_sb; +extern const unsigned short mbfl_docomo2uni_pua[4][3]; +extern const unsigned short mbfl_kddi2uni_pua[6][3]; +extern const unsigned short mbfl_sb2uni_pua[6][3]; +extern const unsigned short mbfl_kddi2uni_pua_b[8][3]; + int mbfl_filt_conv_sjis_mobile_wchar(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_wchar_sjis_mobile(int c, mbfl_convert_filter *filter); int mbfl_filt_conv_sjis_mobile_flush(mbfl_convert_filter *filter); diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c index be0e6b080fa35..370a64594296b 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c @@ -37,10 +37,6 @@ #include "mbfilter_sjis_mobile.h" extern int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter); -extern const int mbfl_docomo2uni_pua[4][3]; -extern const int mbfl_kddi2uni_pua[6][3]; -extern const int mbfl_sb2uni_pua[6][3]; -extern const int mbfl_kddi2uni_pua_b[8][3]; extern const unsigned char mblen_table_utf8[]; From 60d5ac840ce16644ed4b069ef4fe41d8c6c561e0 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sat, 27 Aug 2011 01:25:10 +0000 Subject: [PATCH 0615/2394] corrected valid unicode area. --- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 2 +- ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index 26c57b4248532..41671344328dd 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -116,7 +116,7 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) filter->cache = 0; if ((status == 0x10 && s >= 0x80) || (status == 0x21 && s >= 0x800 && (s < 0xd800 || s > 0xdfff)) || - (status == 0x32 && s >= 0x10000 && s < 0x200000)) { + (status == 0x32 && s >= 0x10000 && s < 0x110000)) { CK((*filter->output_function)(s, filter->data)); } else { w = s & MBFL_WCSGROUP_MASK; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c index 370a64594296b..a5e2b0f2b47e6 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c @@ -207,7 +207,7 @@ int mbfl_filt_conv_utf8_mobile_wchar(int c, mbfl_convert_filter *filter) filter->cache = 0; if ((status == 0x10 && s >= 0x80) || (status == 0x21 && s >= 0x800 && (s < 0xd800 || s > 0xdfff)) || - (status == 0x32 && s >= 0x10000 && s < 0x200000)) { + (status == 0x32 && s >= 0x10000 && s < 0x110000)) { if (filter->from->no_encoding == mbfl_no_encoding_utf8_docomo && mbfilter_conv_r_map_tbl(s, &s1, mbfl_docomo2uni_pua, 4) > 0) { From 1464da907333d2b59c45e8c7f273961a42585b1f Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 27 Aug 2011 07:24:44 +0000 Subject: [PATCH 0616/2394] reformat OID parsing procedure, fail whole SNMP query on single OID parsing failure --- ext/snmp/snmp.c | 48 +++++++++++++++++++---------------- ext/snmp/tests/snmp2_get.phpt | 5 +--- ext/snmp/tests/snmpget.phpt | 5 +--- 3 files changed, 28 insertions(+), 30 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index c0ab7f5f6afea..e2a1b94803fd3 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -744,24 +744,28 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, while (keepwalking) { keepwalking = 0; - if (st & (SNMP_CMD_GET | SNMP_CMD_GETNEXT)) { - pdu = snmp_pdu_create((st & SNMP_CMD_GET) ? SNMP_MSG_GET : SNMP_MSG_GETNEXT); - for (count = 0; objid_query->offset < objid_query->count && count < objid_query->step; objid_query->offset++, count++){ - objid_query->vars[objid_query->offset].name_length = MAX_OID_LEN; - if (!snmp_parse_oid(objid_query->vars[objid_query->offset].oid, objid_query->vars[objid_query->offset].name, &(objid_query->vars[objid_query->offset].name_length))) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid object identifier: %s", objid_query->vars[objid_query->offset].oid); - } else { - snmp_add_null_var(pdu, objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length); - } + if (st & SNMP_CMD_WALK) { + if (session->version == SNMP_VERSION_1) { + pdu = snmp_pdu_create(SNMP_MSG_GETNEXT); + } else { + pdu = snmp_pdu_create(SNMP_MSG_GETBULK); + pdu->non_repeaters = objid_query->non_repeaters; + pdu->max_repetitions = objid_query->max_repetitions; } - if(pdu->variables == NULL){ - snmp_free_pdu(pdu); + snmp_add_null_var(pdu, name, name_length); + } else { + if (st & SNMP_CMD_GET) { + pdu = snmp_pdu_create(SNMP_MSG_GET); + } else if (st & SNMP_CMD_GETNEXT) { + pdu = snmp_pdu_create(SNMP_MSG_GETNEXT); + } else if (st & SNMP_CMD_SET) { + pdu = snmp_pdu_create(SNMP_MSG_SET); + } else { snmp_close(ss); + php_error_docref(NULL TSRMLS_CC, E_ERROR, "Unknown SNMP command (internals)"); RETVAL_FALSE; return; } - } else if (st & SNMP_CMD_SET) { - pdu = snmp_pdu_create(SNMP_MSG_SET); for (count = 0; objid_query->offset < objid_query->count && count < objid_query->step; objid_query->offset++, count++){ objid_query->vars[objid_query->offset].name_length = MAX_OID_LEN; if (!snmp_parse_oid(objid_query->vars[objid_query->offset].oid, objid_query->vars[objid_query->offset].name, &(objid_query->vars[objid_query->offset].name_length))) { @@ -770,7 +774,8 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, snmp_close(ss); RETVAL_FALSE; return; - } else { + } + if (st & SNMP_CMD_SET) { if ((snmp_errno = snmp_add_var(pdu, objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length, objid_query->vars[objid_query->offset].type, objid_query->vars[objid_query->offset].value))) { snprint_objid(buf, sizeof(buf), objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not add variable: OID='%s' type='%c' value='%s': %s", buf, objid_query->vars[objid_query->offset].type, objid_query->vars[objid_query->offset].value, snmp_api_errstring(snmp_errno)); @@ -779,17 +784,16 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, RETVAL_FALSE; return; } + } else { + snmp_add_null_var(pdu, objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length); } } - } else if (st & SNMP_CMD_WALK) { - if (session->version == SNMP_VERSION_1) { - pdu = snmp_pdu_create(SNMP_MSG_GETNEXT); - } else { - pdu = snmp_pdu_create(SNMP_MSG_GETBULK); - pdu->non_repeaters = objid_query->non_repeaters; - pdu->max_repetitions = objid_query->max_repetitions; + if(pdu->variables == NULL){ + snmp_free_pdu(pdu); + snmp_close(ss); + RETVAL_FALSE; + return; } - snmp_add_null_var(pdu, name, name_length); } retry: diff --git a/ext/snmp/tests/snmp2_get.phpt b/ext/snmp/tests/snmp2_get.phpt index cc192c9b5d5d2..b6b50cea90959 100644 --- a/ext/snmp/tests/snmp2_get.phpt +++ b/ext/snmp/tests/snmp2_get.phpt @@ -85,10 +85,7 @@ bool(false) Multiple OID Warning: snmp2_get(): Invalid object identifier: .1.3.6.1.2.1...1.1.0 in %s on line %d -array(1) { - ["%s"]=> - %unicode|string%(%d) "%d" -} +bool(false) noSuchName checks Single OID diff --git a/ext/snmp/tests/snmpget.phpt b/ext/snmp/tests/snmpget.phpt index c2fca2dce2fd3..e4514a2538508 100644 --- a/ext/snmp/tests/snmpget.phpt +++ b/ext/snmp/tests/snmpget.phpt @@ -87,10 +87,7 @@ bool(false) Multiple OID Warning: snmpget(): Invalid object identifier: .1.3.6.1.2.1...1.1.0 in %s on line %d -array(1) { - ["%s"]=> - %unicode|string%(%d) "%d" -} +bool(false) noSuchName checks Single OID From 5ab9e7b5db7aaef041e36f9611afb4acde189d1a Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Sat, 27 Aug 2011 08:16:32 +0000 Subject: [PATCH 0617/2394] export ERRNO_OID_PARSING_ERROR constant: raise it evry time OID parsing has failed --- ext/snmp/php_snmp.h | 2 +- ext/snmp/snmp.c | 10 +++-- ext/snmp/tests/snmp-object-errno-errstr.phpt | 46 ++++++++++++++++++++ 3 files changed, 53 insertions(+), 5 deletions(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index 81db1130c4ca6..543a48689c1aa 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -94,7 +94,7 @@ typedef struct _php_snmp_object { int oid_output_format; int snmp_errno; int oid_increasing_check; - char snmp_errstr[128]; + char snmp_errstr[256]; } php_snmp_object; diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index e2a1b94803fd3..2a812338fc69b 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -117,6 +117,7 @@ typedef struct snmp_session php_snmp_session; #define PHP_SNMP_ERRNO_TIMEOUT 2 #define PHP_SNMP_ERRNO_ERROR_IN_REPLY 3 #define PHP_SNMP_ERRNO_OID_NOT_INCREASING 4 +#define PHP_SNMP_ERRNO_OID_PARSING_ERROR 5 ZEND_DECLARE_MODULE_GLOBALS(snmp) static PHP_GINIT_FUNCTION(snmp); @@ -705,7 +706,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, if (st & SNMP_CMD_WALK) { if (objid_query->count > 1) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Multi OID walks are not supported!"); + php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Multi OID walks are not supported!"); RETURN_FALSE; } rootlen = MAX_NAME_LEN; @@ -713,7 +714,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, if (snmp_parse_oid(objid_query->vars[0].oid, root, &rootlen)) { gotroot = 1; } else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid object identifier: %s", objid_query->vars[0].oid); + php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Invalid object identifier: %s", objid_query->vars[0].oid); RETVAL_FALSE; return; } @@ -769,7 +770,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, for (count = 0; objid_query->offset < objid_query->count && count < objid_query->step; objid_query->offset++, count++){ objid_query->vars[objid_query->offset].name_length = MAX_OID_LEN; if (!snmp_parse_oid(objid_query->vars[objid_query->offset].oid, objid_query->vars[objid_query->offset].name, &(objid_query->vars[objid_query->offset].name_length))) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid object identifier: %s", objid_query->vars[objid_query->offset].oid); + php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Invalid object identifier: %s", objid_query->vars[objid_query->offset].oid); snmp_free_pdu(pdu); snmp_close(ss); RETVAL_FALSE; @@ -778,7 +779,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, if (st & SNMP_CMD_SET) { if ((snmp_errno = snmp_add_var(pdu, objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length, objid_query->vars[objid_query->offset].type, objid_query->vars[objid_query->offset].value))) { snprint_objid(buf, sizeof(buf), objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length); - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not add variable: OID='%s' type='%c' value='%s': %s", buf, objid_query->vars[objid_query->offset].type, objid_query->vars[objid_query->offset].value, snmp_api_errstring(snmp_errno)); + php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Could not add variable: OID='%s' type='%c' value='%s': %s", buf, objid_query->vars[objid_query->offset].type, objid_query->vars[objid_query->offset].value, snmp_api_errstring(snmp_errno)); snmp_free_pdu(pdu); snmp_close(ss); RETVAL_FALSE; @@ -2437,6 +2438,7 @@ PHP_MINIT_FUNCTION(snmp) REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_TIMEOUT", (long)PHP_SNMP_ERRNO_TIMEOUT); REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_ERROR_IN_REPLY", (long)PHP_SNMP_ERRNO_ERROR_IN_REPLY); REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_NOT_INCREASING", (long)PHP_SNMP_ERRNO_OID_NOT_INCREASING); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_PARSING_ERROR", (long)PHP_SNMP_ERRNO_OID_PARSING_ERROR); return SUCCESS; } diff --git a/ext/snmp/tests/snmp-object-errno-errstr.phpt b/ext/snmp/tests/snmp-object-errno-errstr.phpt index 427a754b08319..e6dfd603df5d3 100644 --- a/ext/snmp/tests/snmp-object-errno-errstr.phpt +++ b/ext/snmp/tests/snmp-object-errno-errstr.phpt @@ -30,12 +30,14 @@ var_dump(@$session->get('.1.3.6.1.2.1.1.1.0')); var_dump($session->getErrno() == SNMP::ERRNO_TIMEOUT); var_dump($session->getError()); $session->close(); + echo "SNMP::ERRNO_ERROR_IN_REPLY\n"; $session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); var_dump(@$session->get('.1.3.6.1.2.1.1.1.110')); var_dump($session->getErrno() == SNMP::ERRNO_ERROR_IN_REPLY); var_dump($session->getError()); $session->close(); + echo "SNMP::ERRNO_GENERIC\n"; $session = new SNMP(SNMP::VERSION_3, $hostname, 'somebogususer', $timeout, $retries); $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); @@ -44,6 +46,33 @@ var_dump($session->getErrno() == SNMP::ERRNO_GENERIC); var_dump($session->getError()); var_dump(@$session->get(array('.1.3.6.1.2.1.1.1.0'))); $session->close(); + +echo "SNMP::ERRNO_OID_PARSING_ERROR\n"; +echo "GET: Single wrong OID\n"; +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); +var_dump(@$session->get('.1.3.6.1.2..1.1.1.0')); +var_dump($session->getErrno() == SNMP::ERRNO_OID_PARSING_ERROR); +var_dump($session->getError()); +$session->close(); +echo "GET: Miltiple OID, one wrong\n"; +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); +var_dump(@$session->get(array('.1.3.6.1.2.1.1.1.0', '.1.3.6.1.2..1.1.1.0'))); +var_dump($session->getErrno() == SNMP::ERRNO_OID_PARSING_ERROR); +var_dump($session->getError()); +$session->close(); +echo "WALK: Single wrong OID\n"; +$session = new SNMP(SNMP::VERSION_2c, $hostname, $community, $timeout, $retries); +var_dump(@$session->walk('.1.3.6.1.2..1.1')); +var_dump($session->getErrno() == SNMP::ERRNO_OID_PARSING_ERROR); +var_dump($session->getError()); +$session->close(); +echo "SET: Wrong type\n"; +$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); +$session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); +$oid1 = 'SNMPv2-MIB::sysContact.0'; +var_dump(@$session->set($oid1, 'q', 'blah')); +var_dump($session->getErrno() == SNMP::ERRNO_OID_PARSING_ERROR); +var_dump($session->getError()); ?> --EXPECTF-- SNMP::ERRNO_NOERROR @@ -63,3 +92,20 @@ bool(false) bool(true) %string|unicode%(%d) "Fatal error: Unknown user name" bool(false) +SNMP::ERRNO_OID_PARSING_ERROR +GET: Single wrong OID +bool(false) +bool(true) +string(46) "Invalid object identifier: .1.3.6.1.2..1.1.1.0" +GET: Miltiple OID, one wrong +bool(false) +bool(true) +string(46) "Invalid object identifier: .1.3.6.1.2..1.1.1.0" +WALK: Single wrong OID +bool(false) +bool(true) +string(42) "Invalid object identifier: .1.3.6.1.2..1.1" +SET: Wrong type +bool(false) +bool(true) +string(129) "Could not add variable: OID='.iso.org.dod.internet.mgmt.mib-2.system.sysContact.0' type='q' value='blah': Bad variable type ("q")" \ No newline at end of file From 24f00c11d61dfceb58185f8cde821afd5653ad33 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Sat, 27 Aug 2011 19:00:59 +0000 Subject: [PATCH 0618/2394] - - +This gets echoed twice <%= $a%> From 30f0f5e41ce51b93a31f8bc9372b7bd02768a10a Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 28 Aug 2011 04:32:22 +0000 Subject: [PATCH 0619/2394] reduced footprint for sjis-mac --- .../libmbfl/filters/mbfilter_sjis_mac.c | 173 ++------ ext/mbstring/libmbfl/filters/sjis_mac2uni.h | 407 ++++++++++++------ 2 files changed, 295 insertions(+), 285 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c index 0fd01854ab02c..c134e5d585846 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mac.c @@ -37,6 +37,8 @@ #include "unicode_table_cp932_ext.h" #include "unicode_table_jis.h" +#include "sjis_mac2uni.h" + extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); extern const unsigned char mblen_table_sjis[]; @@ -123,134 +125,6 @@ const struct mbfl_convert_vtbl vtbl_wchar_sjis_mac = { } \ } while (0) -#include "sjis_mac2uni.h" - -static const int code_tbl[][3] = { - {0x02f0, 0x0303, 0x2460}, - {0x030e, 0x0321, 0x2474}, - {0x032c, 0x0334, 0x2776}, - {0x0341, 0x0349, 0x2488}, - {0x034e, 0x0359, 0x2160}, - {0x0362, 0x036d, 0x2170}, - {0x038a, 0x03a3, 0x249c}, -}; - -static const int code_ofst_tbl[] [2]= { - {0x03ac, 0x03c9}, - {0x0406, 0x0420}, - {0x0432, 0x0441}, - {0x0468, 0x0480}, - {0x04b8, 0x04e8}, - {0x050c, 0x0551}, - {0x1ed9, 0x1f18}, - {0x1ff2, 0x20a5}, -}; - -static const int *code_map[] = { - sjis_mac2wchar1, sjis_mac2wchar2, sjis_mac2wchar3, sjis_mac2wchar4, - sjis_mac2wchar5, sjis_mac2wchar6, sjis_mac2wchar7, sjis_mac2wchar8}; - -static const int code_tbl_m[][6] = { - {0x0340, 0xf860, 0x0030, 0x002e, 0x0000, 0x0000}, - {0x03c9, 0xf860, 0x0054, 0x0042, 0x0000, 0x0000}, - {0x035c, 0xf860, 0x0058, 0x0056, 0x0000, 0x0000}, - {0x0370, 0xf860, 0x0078, 0x0076, 0x0000, 0x0000}, - {0x0439, 0xf860, 0x2193, 0x2191, 0x0000, 0x0000}, - {0x0409, 0xf861, 0x0046, 0x0041, 0x0058, 0x0000}, - {0x035b, 0xf861, 0x0058, 0x0049, 0x0056, 0x0000}, - {0x036f, 0xf861, 0x0078, 0x0069, 0x0076, 0x0000}, - {0x035a, 0xf862, 0x0058, 0x0049, 0x0049, 0x0049}, - {0x036e, 0xf862, 0x0078, 0x0069, 0x0069, 0x0069}, - {0x0522, 0xf862, 0x6709, 0x9650, 0x4f1a, 0x793e}, - {0x0523, 0xf862, 0x8ca1, 0x56e3, 0x6cd5, 0x4eba}, -}; - -static const int s_form_tbl[] = { - 0x2010,0x2016,0x2026, - 0x3001,0x3002,0x301c,0x3041,0x3043,0x3045,0x3047,0x3049, - 0x3063,0x3083,0x3085,0x3087,0x308e,0x30a1,0x30a3,0x30a5, - 0x30a7,0x30a9,0x30c3,0x30e3,0x30e5,0x30e7,0x30ee,0x30f5, - 0x30f6,0x30fc,0xff1d,0xff3b,0xff3d,0xff5c,0xffe3, // vertical f87e (34) - 0x2026,0xff47,0xff4d, // halfwidth f87f (3) - 0x5927,0x5c0f,0x63a7, // enclosing circle 20dd (3) - 0x21e6,0x21e7,0x21e8,0x21e9, // black arrow f87a (4) -}; - -static const int s_form_sjis_tbl[] = { - 0xeb5d,0xeb61,0xeb63, - 0xeb41,0xeb42,0xeb60,0xec9f,0xeca1,0xeca3,0xeca5,0xeca7, - 0xecc1,0xece1,0xece3,0xece5,0xecec,0xed40,0xed42,0xed44, - 0xed46,0xed48,0xed62,0xed83,0xed85,0xed87,0xed8e,0xed95, - 0xed96,0xeb5b,0xeb81,0xeb6d,0xeb6e,0xeb62,0xeb50, // vertical - 0x00ff,0x864b,0x8645, // halfwidth - 0x8791,0x8792,0x879d, // enclosing circle - 0x86d4,0x86d5,0x86d3,0x86d6, // black arrow -}; - -static const int s_form_sjis_fallback_tbl[] = { - 0x815d,0x8161,0x8163, - 0x8141,0x8142,0x8160,0x829f,0x82a1,0x82a3,0x82a5,0x82a7, - 0x82c1,0x82e1,0x82e3,0x82e5,0x82ec,0x8340,0x8342,0x8344, - 0x8346,0x8348,0x8362,0x8383,0x8385,0x8387,0x838e,0x8395, - 0x8396,0x815b,0x8181,0x816d,0x816e,0x8162,0x8150, // vertical - 0x815d,0x8287,0x828d, // halfwidth - 0x91e5,0x8fac,0x8d54, // enclosing circle - 0x86d0,0x86d1,0x86cf,0x86d2, // arrow -}; - -static const int wchar2sjis_mac_r_tbl[][3] = { - {0x2160, 0x216b, 0x034e}, - {0x2170, 0x217b, 0x0362}, - {0x2460, 0x2473, 0x02f0}, - {0x2474, 0x2487, 0x030e}, - {0x2488, 0x2490, 0x0341}, - {0x249c, 0x24b5, 0x038a}, - {0x2776, 0x277e, 0x032c}, - {0x30f7, 0x30fa, 0x054e}, - {0x32a4, 0x32a9, 0x04ba}, -}; - -static const unsigned short wchar2sjis_mac_r_map[][2] = { - {0x2660, 0x2667}, - {0x322a, 0x3243}, - {0x3296, 0x329e}, - {0x3300, 0x33d4}, - {0xfe30, 0xfe44}, -}; - -static const int *wchar2sjis_mac_code_map[] = { - wchar2sjis_mac4, wchar2sjis_mac7, wchar2sjis_mac8, wchar2sjis_mac9, wchar2sjis_mac10}; - -static const int wchar2sjis_mac_wchar_tbl[][2] = { - {0x2109, 0x03c2}, - {0x2110, 0x21ef5}, - {0x2113, 0x03bc}, - {0x2116, 0x0406}, - {0x2121, 0x0408}, - {0x21c4, 0x0437}, - {0x21c5, 0x0438}, - {0x21c6, 0x0436}, - {0x21e6, 0x043b}, - {0x21e7, 0x043c}, - {0x21e8, 0x043a}, - {0x21e9, 0x043d}, - {0x221f, 0x0525}, - {0x222e, 0x0524}, - {0x22bf, 0x0526}, - {0x260e, 0x041f}, - {0x261c, 0x0433}, - {0x261d, 0x0434}, - {0x261e, 0x0432}, - {0x261f, 0x0435}, - {0x3004, 0x0420}, - {0x301d, 0x0538}, - {0x301f, 0x0539}, - {0x3020, 0x041e}, - {0x3094, 0x054c}, -}; - - - /* * SJIS-mac => wchar */ @@ -328,7 +202,7 @@ mbfl_filt_conv_sjis_mac_wchar(int c, mbfl_convert_filter *filter) if (w == 0) { - for (i=0; i<12; i++) { + for (i=0; i= code_ofst_tbl[i][0] && s <= code_ofst_tbl[i][1]) { w = code_map[i][s - code_ofst_tbl[i][0]]; - if (w >= 0x10000) { - CK((*filter->output_function)(w & 0xffff, filter->data)); - if (w & 0x10000) { - w = 0xf87a; - } else if (w & 0x20000) { - w = 0xf87e; - } else if (w & 0x40000) { - w = 0xf87f; - } else if (w & 0x80000) { - w = 0x20dd; - } else { - w = 0; - } + s2 = 0; + if (s >= 0x043e && s <= 0x0441) { + s2 = 0xf87a; + } else if (s == 0x03b1 || s == 0x03b7) { + s2 = 0xf87f; + } else if (s == 0x04b8 || s == 0x04b9 || s == 0x04c4) { + s2 = 0x20dd; + } else if (s == 0x1ed9 || s == 0x1eda || s == 0x1ee8 || s == 0x1ef3 || + (s >= 0x1ef5 && s <= 0x1efb) || s == 0x1f05 || s == 0x1f06 || + s == 0x1f18 || (s >= 0x1ff2 && s <= 0x20a5)) { + s2 = 0xf87e; + } + if (s2 > 0) { + CK((*filter->output_function)(w, filter->data)); + w = s2; } - break; } } @@ -471,7 +346,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) } if (s2 > 0) { - for (i=0;i= 0x2000) { - for (i=0;istatus = 1; filter->cache = c; @@ -556,7 +431,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) } if (s1 <= 0) { - for (i=0; i= wchar2sjis_mac_r_tbl[i][0] && c <= wchar2sjis_mac_r_tbl[i][1]) { s1 = c - wchar2sjis_mac_r_tbl[i][0] + wchar2sjis_mac_r_tbl[i][2]; break; @@ -564,7 +439,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) } if (s1 <= 0) { - for (i=0; i= wchar2sjis_mac_r_map[i][0] && c <= wchar2sjis_mac_r_map[i][1]) { s1 = wchar2sjis_mac_code_map[i][c-wchar2sjis_mac_r_map[i][0]]; break; @@ -573,7 +448,7 @@ mbfl_filt_conv_wchar_sjis_mac(int c, mbfl_convert_filter *filter) } if (s1 <= 0) { - for (i=0; istatus == 1 && filter->cache > 0) { c1 = filter->cache; - for (i=0;i Date: Mon, 29 Aug 2011 05:00:26 +0000 Subject: [PATCH 0620/2394] - Added libxml_set_external_entity_loader(). --- UPGRADING | 3 + ext/libxml/libxml.c | 177 +++++++++++++++++- ext/libxml/php_libxml.h | 5 + ...bxml_set_external_entity_loader_basic.phpt | 48 +++++ ...xml_set_external_entity_loader_error1.phpt | 39 ++++ ...set_external_entity_loader_variation1.phpt | 71 +++++++ ...set_external_entity_loader_variation2.phpt | 44 +++++ 7 files changed, 384 insertions(+), 3 deletions(-) create mode 100644 ext/libxml/tests/libxml_set_external_entity_loader_basic.phpt create mode 100644 ext/libxml/tests/libxml_set_external_entity_loader_error1.phpt create mode 100644 ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt create mode 100644 ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt diff --git a/UPGRADING b/UPGRADING index 2739614a73a4a..6ff8ad9f47e31 100755 --- a/UPGRADING +++ b/UPGRADING @@ -383,6 +383,9 @@ UPGRADE NOTES - PHP X.Y - stream_set_chunk_size() - socket_import_stream() + - libxml + - libxml_set_external_entity_loader() + f. New global constants - JSON_PRETTY_PRINT diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index 25988a6d6014c..9863043b5da88 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -70,6 +70,7 @@ static PHP_FUNCTION(libxml_use_internal_errors); static PHP_FUNCTION(libxml_get_last_error); static PHP_FUNCTION(libxml_clear_errors); static PHP_FUNCTION(libxml_get_errors); +static PHP_FUNCTION(libxml_set_external_entity_loader); static PHP_FUNCTION(libxml_disable_entity_loader); static zend_class_entry *libxmlerror_class_entry; @@ -111,6 +112,9 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_libxml_disable_entity_loader, 0, 0, 0) ZEND_ARG_INFO(0, disable) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_libxml_set_external_entity_loader, 0, 0, 1) + ZEND_ARG_INFO(0, resolver_function) +ZEND_END_ARG_INFO() /* }}} */ /* {{{ extension definition structures */ @@ -121,6 +125,7 @@ static const zend_function_entry libxml_functions[] = { PHP_FE(libxml_clear_errors, arginfo_libxml_clear_errors) PHP_FE(libxml_get_errors, arginfo_libxml_get_errors) PHP_FE(libxml_disable_entity_loader, arginfo_libxml_disable_entity_loader) + PHP_FE(libxml_set_external_entity_loader, arginfo_libxml_set_external_entity_loader) PHP_FE_END }; @@ -263,6 +268,19 @@ static PHP_GINIT_FUNCTION(libxml) libxml_globals->stream_context = NULL; libxml_globals->error_buffer.c = NULL; libxml_globals->error_list = NULL; + libxml_globals->defaultEntityLoader = NULL; + libxml_globals->entity_loader.fci.size = 0; +} + +static void _php_libxml_destroy_fci(zend_fcall_info *fci) +{ + if (fci->size > 0) { + zval_ptr_dtor(&fci->function_name); + if (fci->object_ptr != NULL) { + zval_ptr_dtor(&fci->object_ptr); + } + fci->size = 0; + } } /* Channel libxml file io layer through the PHP streams subsystem. @@ -280,8 +298,9 @@ static void *php_libxml_streams_IO_open_wrapper(const char *filename, const char TSRMLS_FETCH(); - uri = xmlParseURI((xmlChar *)filename); - if (uri && (uri->scheme == NULL || (xmlStrncmp(uri->scheme, "file", 4) == 0))) { + uri = xmlParseURI(filename); + if (uri && (uri->scheme == NULL || + (xmlStrncmp(BAD_CAST uri->scheme, BAD_CAST "file", 4) == 0))) { resolved_path = xmlURIUnescapeString(filename, 0, NULL); isescaped = 1; } else { @@ -669,7 +688,7 @@ static PHP_MINIT_FUNCTION(libxml) xmlParserInputBufferCreateFilenameDefault(php_libxml_input_buffer_create_filename); xmlOutputBufferCreateFilenameDefault(php_libxml_output_buffer_create_filename); } - + return SUCCESS; } @@ -723,6 +742,8 @@ static PHP_RSHUTDOWN_FUNCTION(libxml) LIBXML(error_list) = NULL; } xmlResetLastError(); + + _php_libxml_destroy_fci(&LIBXML(entity_loader).fci); return SUCCESS; } @@ -905,6 +926,156 @@ static PHP_FUNCTION(libxml_disable_entity_loader) } /* }}} */ +static xmlParserInputPtr _php_libxml_user_entity_loader(const char *URL, + const char *ID, xmlParserCtxtPtr context) +{ + xmlParserInputPtr ret = NULL; + const char *resource = NULL; + zval *public = NULL, + *system = NULL, + *ctxzv = NULL, + **params[] = {&public, &system, &ctxzv}, + *retval_ptr = NULL; + int retval; + TSRMLS_FETCH(); + zend_fcall_info *fci = &LIBXML(entity_loader).fci; + + ALLOC_INIT_ZVAL(public); + if (ID != NULL) { + ZVAL_STRING(public, ID, 1); + } + ALLOC_INIT_ZVAL(system); + if (URL != NULL) { + ZVAL_STRING(system, URL, 1); + } + MAKE_STD_ZVAL(ctxzv); + array_init_size(ctxzv, 4); + +#define ADD_NULL_OR_STRING_KEY(memb) \ + if (context->memb == NULL) { \ + add_assoc_null_ex(ctxzv, #memb, sizeof(#memb)); \ + } else { \ + add_assoc_string_ex(ctxzv, #memb, sizeof(#memb), \ + (char *)context->memb, 1); \ + } + + ADD_NULL_OR_STRING_KEY(directory) + ADD_NULL_OR_STRING_KEY(intSubName) + ADD_NULL_OR_STRING_KEY(extSubURI) + ADD_NULL_OR_STRING_KEY(extSubSystem) + +#undef ADD_NULL_OR_STRING_KEY + + fci->retval_ptr_ptr = &retval_ptr; + fci->params = params; + fci->param_count = sizeof(params)/sizeof(*params); + fci->no_separation = 1; + + retval = zend_call_function(fci, &LIBXML(entity_loader).fcc TSRMLS_CC); + if (retval != SUCCESS || fci->retval_ptr_ptr == NULL) { + php_libxml_ctx_error(context, + "Call to user entity loader callback '%s' has failed", + fci->function_name); + } else { + retval_ptr = *fci->retval_ptr_ptr; + if (retval_ptr == NULL) { + php_libxml_ctx_error(context, + "Call to user entity loader callback '%s' has failed; " + "probably it has thrown an exception", + fci->function_name); + } else if (Z_TYPE_P(retval_ptr) == IS_STRING) { +is_string: + resource = Z_STRVAL_P(retval_ptr); + } else if (Z_TYPE_P(retval_ptr) == IS_RESOURCE) { + php_stream *stream; + php_stream_from_zval_no_verify(stream, &retval_ptr); + if (stream == NULL) { + php_libxml_ctx_error(context, + "The user entity loader callback '%s' has returned a " + "resource, but it is not a stream", + fci->function_name); + } else { + /* TODO: allow storing the encoding in the stream context? */ + xmlCharEncoding enc = XML_CHAR_ENCODING_NONE; + xmlParserInputBufferPtr pib = xmlAllocParserInputBuffer(enc); + if (pib == NULL) { + php_libxml_ctx_error(context, "Could not allocate parser " + "input buffer"); + } else { + /* make stream not being closed when the zval is freed */ + zend_list_addref(stream->rsrc_id); + pib->context = stream; + pib->readcallback = php_libxml_streams_IO_read; + pib->closecallback = php_libxml_streams_IO_close; + + ret = xmlNewIOInputStream(context, pib, enc); + if (ret == NULL) { + xmlFreeParserInputBuffer(pib); + } + } + } + } else if (Z_TYPE_P(retval_ptr) != IS_NULL) { + /* retval not string nor resource nor null; convert to string */ + SEPARATE_ZVAL(&retval_ptr); + convert_to_string(retval_ptr); + goto is_string; + } /* else is null; don't try anything */ + } + + if (ret == NULL) { + if (resource == NULL) { + if (ID == NULL) { + ID = "NULL"; + } + php_libxml_ctx_error(context, + "Failed to load external entity \"%s\"\n", ID); + } else { + /* we got the resource in the form of a string; open it */ + ret = xmlNewInputFromFile(context, resource); + } + } + + zval_ptr_dtor(&public); + zval_ptr_dtor(&system); + zval_ptr_dtor(&ctxzv); + if (retval_ptr != NULL) { + zval_ptr_dtor(&retval_ptr); + } + return ret; +} + +/* {{{ proto void libxml_set_external_entity_loader(callback resolver_function) + Changes the default external entity loader */ +static PHP_FUNCTION(libxml_set_external_entity_loader) +{ + zend_fcall_info fci; + zend_fcall_info_cache fcc; + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "f!", &fci, &fcc) + == FAILURE) { + return; + } + + if (fci.size > 0) { /* argument not null */ + /* save for later invocations with NULL */ + if (LIBXML(defaultEntityLoader) == NULL) { + LIBXML(defaultEntityLoader) = xmlGetExternalEntityLoader(); + } + _php_libxml_destroy_fci(&LIBXML(entity_loader).fci); + LIBXML(entity_loader).fci = fci; + Z_ADDREF_P(fci.function_name); + if (fci.object_ptr != NULL) { + Z_ADDREF_P(fci.object_ptr); + } + LIBXML(entity_loader).fcc = fcc; + xmlSetExternalEntityLoader(_php_libxml_user_entity_loader); + } else { + xmlSetExternalEntityLoader(LIBXML(defaultEntityLoader)); + } + + RETURN_TRUE; +} +/* }}} */ + /* {{{ Common functions shared by extensions */ int php_libxml_xmlCheckUTF8(const unsigned char *s) { diff --git a/ext/libxml/php_libxml.h b/ext/libxml/php_libxml.h index fca992e22b686..8fe7fe4ad66a8 100644 --- a/ext/libxml/php_libxml.h +++ b/ext/libxml/php_libxml.h @@ -43,6 +43,11 @@ ZEND_BEGIN_MODULE_GLOBALS(libxml) zval *stream_context; smart_str error_buffer; zend_llist *error_list; + xmlExternalEntityLoader defaultEntityLoader; /* saved here to allow it restored */ + struct _php_libxml_entity_resolver { + zend_fcall_info fci; + zend_fcall_info_cache fcc; + } entity_loader; ZEND_END_MODULE_GLOBALS(libxml) typedef struct _libxml_doc_props { diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_basic.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_basic.phpt new file mode 100644 index 0000000000000..51ab7770528a4 --- /dev/null +++ b/ext/libxml/tests/libxml_set_external_entity_loader_basic.phpt @@ -0,0 +1,48 @@ +--TEST-- +libxml_set_external_entity_loader() basic test +--SKIPIF-- + +--FILE-- + +bar +XML; + +$dtd = << +DTD; + +libxml_set_external_entity_loader( + function ($public, $system, $context) use($dtd){ + var_dump($public); + var_dump($system); + var_dump($context); + $f = fopen("php://temp", "r+"); + fwrite($f, $dtd); + rewind($f); + return $f; + } +); + +$dd = new DOMDocument; +$r = $dd->loadXML($xml); +var_dump($dd->validate()); + +echo "Done.\n"; + +--EXPECT-- +string(10) "-//FOO/BAR" +string(25) "http://example.com/foobar" +array(4) { + ["directory"]=> + NULL + ["intSubName"]=> + NULL + ["extSubURI"]=> + NULL + ["extSubSystem"]=> + NULL +} +bool(true) +Done. diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_error1.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_error1.phpt new file mode 100644 index 0000000000000..5ed079d8dd1be --- /dev/null +++ b/ext/libxml/tests/libxml_set_external_entity_loader_error1.phpt @@ -0,0 +1,39 @@ +--TEST-- +libxml_set_external_entity_loader() error: bad arguments +--SKIPIF-- + +--FILE-- + +bar +XML; + +$dd = new DOMDocument; +$r = $dd->loadXML($xml); + +var_dump(libxml_set_external_entity_loader([])); +var_dump(libxml_set_external_entity_loader()); +var_dump(libxml_set_external_entity_loader(function() {}, 2)); + +var_dump(libxml_set_external_entity_loader(function($a, $b, $c, $d) {})); +var_dump($dd->validate()); + +echo "Done.\n"; + +--EXPECTF-- +Warning: libxml_set_external_entity_loader() expects parameter 1 to be a valid callback, array must have exactly two members in %s on line %d +NULL + +Warning: libxml_set_external_entity_loader() expects exactly 1 parameter, 0 given in %s on line %d +NULL + +Warning: libxml_set_external_entity_loader() expects exactly 1 parameter, 2 given in %s on line %d +NULL +bool(true) + +Warning: Missing argument 4 for {closure}() in %s on line %d + +Warning: DOMDocument::validate(): Could not load the external subset "http://example.com/foobar" in %s on line %d +bool(false) +Done. diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt new file mode 100644 index 0000000000000..1bb88d604eaeb --- /dev/null +++ b/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt @@ -0,0 +1,71 @@ +--TEST-- +libxml_set_external_entity_loader() variation: resolve externals and entities +--SKIPIF-- + +--FILE-- + +bar&fooz; +XML; + +$dtd = << + +%fooentity; +DTD; + +$entity = << +ENT; + +libxml_set_external_entity_loader( + function ($public, $system, $context) use($dtd,$entity){ + static $first = true; + var_dump($public); + var_dump($system); + var_dump($context); + $f = fopen("php://temp", "r+"); + fwrite($f, $first ? $dtd : $entity); + $first = false; + rewind($f); + return $f; + } +); + +$dd = new DOMDocument; +$dd->resolveExternals = true; +$r = $dd->loadXML($xml); +var_dump($dd->validate()); + +echo "Done.\n"; + +--EXPECTF-- +string(10) "-//FOO/BAR" +string(25) "http://example.com/foobar" +array(4) { + ["directory"]=> + string(36) "%s" + ["intSubName"]=> + string(3) "foo" + ["extSubURI"]=> + string(25) "http://example.com/foobar" + ["extSubSystem"]=> + string(10) "-//FOO/BAR" +} +string(13) "-//FOO/ENTITY" +string(32) "http://example.com/fooentity.ent" +array(4) { + ["directory"]=> + string(36) "%s" + ["intSubName"]=> + string(3) "foo" + ["extSubURI"]=> + string(25) "http://example.com/foobar" + ["extSubSystem"]=> + string(10) "-//FOO/BAR" +} +bool(true) +Done. diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt new file mode 100644 index 0000000000000..bec04aa7636ab --- /dev/null +++ b/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt @@ -0,0 +1,44 @@ +--TEST-- +libxml_set_external_entity_loader() variation: restore original handler; returning NULL +--SKIPIF-- + +--CLEAN-- + +bar +XML; + +$dtd = << +DTD; + + +libxml_set_external_entity_loader( + function ($public, $system, $context) { + var_dump($public,$system); + return null; + } +); + +$dd = new DOMDocument; +$r = $dd->loadXML($xml); +var_dump($dd->validate()); + +libxml_set_external_entity_loader(NULL); +file_put_contents(__DIR__ . "/foobar.dtd", $dtd); +var_dump($dd->validate()); + +echo "Done.\n"; + +--EXPECTF-- +string(10) "-//FOO/BAR" +string(46) "%sfoobar.dtd" + +Warning: DOMDocument::validate(): Could not load the external subset "foobar.dtd" in %s on line %d +bool(false) +bool(true) +Done. From bf3bb1efbe9e15f8cbe12180332fcde8022c1c28 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 29 Aug 2011 06:19:40 +0000 Subject: [PATCH 0621/2394] Fix another broken test. root can read 0200 files. --- ext/sqlite3/tests/sqlite3_15_open_error.phpt | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ext/sqlite3/tests/sqlite3_15_open_error.phpt b/ext/sqlite3/tests/sqlite3_15_open_error.phpt index 49168fd19b776..ea1ee429922d5 100644 --- a/ext/sqlite3/tests/sqlite3_15_open_error.phpt +++ b/ext/sqlite3/tests/sqlite3_15_open_error.phpt @@ -1,10 +1,15 @@ --TEST-- SQLite3::open error test --SKIPIF-- - + --FILE-- Date: Mon, 29 Aug 2011 06:47:07 +0000 Subject: [PATCH 0622/2394] The link error on an out-of-sync command doesn't start with 0 uwe/andrey please double-check --- ext/mysqli/tests/bug45289.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/bug45289.phpt b/ext/mysqli/tests/bug45289.phpt index 50775b55cc63f..2ddacf4fdd2ae 100644 --- a/ext/mysqli/tests/bug45289.phpt +++ b/ext/mysqli/tests/bug45289.phpt @@ -37,4 +37,4 @@ require_once('skipifconnectfailure.inc'); require_once("clean_table.inc"); ?> --EXPECTF-- -[004] [0%s +[004] [%s From 74d06b92c73019b1e3999b4d873f30feb06c8225 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 29 Aug 2011 08:21:42 +0000 Subject: [PATCH 0623/2394] Let's do more than hope (as per the comment in the test code) that we don't hit the memory limit, let's disable the limit for this test since the limit is getting hit by many people --- ext/mysqli/tests/mysqli_fetch_array_large.phpt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_fetch_array_large.phpt b/ext/mysqli/tests/mysqli_fetch_array_large.phpt index ae83b3f8b182b..3c6a0f03f3b9f 100644 --- a/ext/mysqli/tests/mysqli_fetch_array_large.phpt +++ b/ext/mysqli/tests/mysqli_fetch_array_large.phpt @@ -5,6 +5,8 @@ mysqli_fetch_array() - large packages (to test compression) require_once('skipif.inc'); require_once('skipifconnectfailure.inc'); ?> +--INI-- +memory_limit=-1 --FILE-- Date: Mon, 29 Aug 2011 10:10:05 +0000 Subject: [PATCH 0624/2394] - fix build, TSRMLS_FETCH must be the last declaration statement and init using TSRM cannot be done before either --- ext/libxml/libxml.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index 9863043b5da88..39f3ee2f11989 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -937,9 +937,11 @@ static xmlParserInputPtr _php_libxml_user_entity_loader(const char *URL, **params[] = {&public, &system, &ctxzv}, *retval_ptr = NULL; int retval; + zend_fcall_info *fci; TSRMLS_FETCH(); - zend_fcall_info *fci = &LIBXML(entity_loader).fci; - + + fci = &LIBXML(entity_loader).fci; + ALLOC_INIT_ZVAL(public); if (ID != NULL) { ZVAL_STRING(public, ID, 1); From fac70ca0f4ffba548875c336c4eb9a60db186ead Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 29 Aug 2011 14:17:41 +0000 Subject: [PATCH 0625/2394] The Phar class extends RecursiveDirectoryIterator, which has changed the way it ensures its ctor is called --- ext/phar/tests/phar_oo_001.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/phar/tests/phar_oo_001.phpt b/ext/phar/tests/phar_oo_001.phpt index f211394e56ee9..5a9e560e724be 100755 --- a/ext/phar/tests/phar_oo_001.phpt +++ b/ext/phar/tests/phar_oo_001.phpt @@ -30,14 +30,14 @@ try $phar = new MyPhar(); var_dump($phar->getVersion()); } -catch (BadMethodCallException $e) +catch (LogicException $e) { var_dump($e->getMessage()); } try { $phar = new Phar('test.phar'); $phar->__construct('oops'); -} catch (BadMethodCallException $e) +} catch (LogicException $e) { var_dump($e->getMessage()); } @@ -52,6 +52,6 @@ __halt_compiler(); --EXPECT-- string(5) "1.0.0" int(5) -string(50) "Cannot call method on an uninitialized Phar object" +string(103) "In the constructor of MyPhar, parent::__construct() must be called and its exceptions cannot be cleared" string(29) "Cannot call constructor twice" ===DONE=== From 3a5f7c63483fb2faafafd63d5610706fdfb17813 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 29 Aug 2011 14:19:54 +0000 Subject: [PATCH 0626/2394] Fixed bug#52013 (Unable to decompress files in a compressed phar) --- ext/phar/phar.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ext/phar/phar.c b/ext/phar/phar.c index 866eb41b188ba..c45efbf44171e 100644 --- a/ext/phar/phar.c +++ b/ext/phar/phar.c @@ -3101,9 +3101,7 @@ int phar_flush(phar_archive_data *phar, char *user_stub, long len, int convert, /* this will have changed for all files that have either changed compression or been modified */ entry->offset = entry->offset_abs = offset; offset += entry->compressed_filesize; - phar_stream_copy_to_stream(file, newfile, entry->compressed_filesize, &wrote); - - if (entry->compressed_filesize != wrote) { + if (phar_stream_copy_to_stream(file, newfile, entry->compressed_filesize, &wrote) == FAILURE) { if (closeoldfile) { php_stream_close(oldfile); } From 2c2c113b7799c986653a36821fb74c62257bc346 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 29 Aug 2011 14:29:40 +0000 Subject: [PATCH 0627/2394] Changed error messages --- ext/phar/tests/fatal_error_webphar.phpt | 2 +- ext/phar/tests/fgc_edgecases.phpt | 2 +- ext/phar/tests/readfile_edgecases.phpt | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/phar/tests/fatal_error_webphar.phpt b/ext/phar/tests/fatal_error_webphar.phpt index 80efaa9ed1d0f..9d0970d17833c 100644 --- a/ext/phar/tests/fatal_error_webphar.phpt +++ b/ext/phar/tests/fatal_error_webphar.phpt @@ -15,4 +15,4 @@ Content-type: text/html; charset=UTF-8 --EXPECTF-- string(9) "\Web\View" -Parse error: syntax error, unexpected T_ECHO, expecting T_FUNCTION in phar://%sfatal_error_webphar.php/Web/View.php on line 380 \ No newline at end of file +Parse error: syntax error, unexpected 'echo' (T_ECHO), expecting function (T_FUNCTION) in phar:///%sfatal_error_webphar.php/Web/View.php on line 380 diff --git a/ext/phar/tests/fgc_edgecases.phpt b/ext/phar/tests/fgc_edgecases.phpt index b943546963b1c..2699834eb0cd5 100644 --- a/ext/phar/tests/fgc_edgecases.phpt +++ b/ext/phar/tests/fgc_edgecases.phpt @@ -47,7 +47,7 @@ include $pname . '/foo/hi'; --EXPECTF-- -Warning: file_get_contents() expects parameter 1 to be string, array given in %sfgc_edgecases.php on line %d +Warning: file_get_contents() expects parameter 1 to be a valid path, array given in %sfgc_edgecases.php on line %d blah --EXPECTF-- -Warning: readfile() expects parameter 1 to be string, array given in %sreadfile_edgecases.php on line %d +Warning: readfile() expects parameter 1 to be a valid path, array given in %sreadfile_edgecases.php on line %d blah Warning: readfile(phar://%sreadfile_edgecases.phar.php/oops): failed to open stream: phar error: path "oops" is a directory in phar://%sreadfile_edgecases.phar.php/foo/hi on line %d -===DONE=== \ No newline at end of file +===DONE=== From a1501cf142381d6e1e9a285efd3cccdde5749357 Mon Sep 17 00:00:00 2001 From: Gwynne Raskind Date: Mon, 29 Aug 2011 14:56:19 +0000 Subject: [PATCH 0628/2394] Add unescaped Unicode encoding to json_encode(). Closes bug #53946. Patch by Irker and Gwynne. --- ext/json/json.c | 25 +++++++++++++++---------- ext/json/php_json.h | 1 + ext/json/tests/bug53946.phpt | 16 ++++++++++++++++ ext/json/utf8_to_utf16.c | 15 +++++++++------ ext/json/utf8_to_utf16.h | 2 +- 5 files changed, 42 insertions(+), 17 deletions(-) create mode 100644 ext/json/tests/bug53946.phpt diff --git a/ext/json/json.c b/ext/json/json.c index 39e3d4d7c98f3..3c20498aa8392 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -95,6 +95,7 @@ static PHP_MINIT_FUNCTION(json) REGISTER_LONG_CONSTANT("JSON_NUMERIC_CHECK", PHP_JSON_NUMERIC_CHECK, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("JSON_UNESCAPED_SLASHES", PHP_JSON_UNESCAPED_SLASHES, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("JSON_PRETTY_PRINT", PHP_JSON_PRETTY_PRINT, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("JSON_UNESCAPED_UNICODE", PHP_JSON_UNESCAPED_UNICODE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("JSON_ERROR_NONE", PHP_JSON_ERROR_NONE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("JSON_ERROR_DEPTH", PHP_JSON_ERROR_DEPTH, CONST_CS | CONST_PERSISTENT); @@ -346,7 +347,7 @@ static void json_encode_array(smart_str *buf, zval **val, int options TSRMLS_DC) static void json_escape_string(smart_str *buf, char *s, int len, int options TSRMLS_DC) /* {{{ */ { - int pos = 0; + int pos = 0, ulen = 0; unsigned short us; unsigned short *utf16; @@ -378,15 +379,14 @@ static void json_escape_string(smart_str *buf, char *s, int len, int options TSR } } - - utf16 = (unsigned short *) safe_emalloc(len, sizeof(unsigned short), 0); - - len = utf8_to_utf16(utf16, s, len); - if (len <= 0) { + + utf16 = (options & PHP_JSON_UNESCAPED_UNICODE) ? NULL : (unsigned short *) safe_emalloc(len, sizeof(unsigned short), 0); + ulen = utf8_to_utf16(utf16, s, len); + if (ulen <= 0) { if (utf16) { efree(utf16); } - if (len < 0) { + if (ulen < 0) { JSON_G(error_code) = PHP_JSON_ERROR_UTF8; if (!PG(display_errors)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid UTF-8 sequence in argument"); @@ -397,12 +397,15 @@ static void json_escape_string(smart_str *buf, char *s, int len, int options TSR } return; } + if (!(options & PHP_JSON_UNESCAPED_UNICODE)) { + len = ulen; + } smart_str_appendc(buf, '"'); while (pos < len) { - us = utf16[pos++]; + us = (options & PHP_JSON_UNESCAPED_UNICODE) ? s[pos++] : utf16[pos++]; switch (us) { @@ -479,7 +482,7 @@ static void json_escape_string(smart_str *buf, char *s, int len, int options TSR break; default: - if (us >= ' ' && (us & 127) == us) { + if (us >= ' ' && ((options & PHP_JSON_UNESCAPED_UNICODE) || (us & 127) == us)) { smart_str_appendc(buf, (unsigned char) us); } else { smart_str_appendl(buf, "\\u", 2); @@ -498,7 +501,9 @@ static void json_escape_string(smart_str *buf, char *s, int len, int options TSR } smart_str_appendc(buf, '"'); - efree(utf16); + if (utf16) { + efree(utf16); + } } /* }}} */ diff --git a/ext/json/php_json.h b/ext/json/php_json.h index 6feffd668d234..002bbe1f552c2 100644 --- a/ext/json/php_json.h +++ b/ext/json/php_json.h @@ -62,6 +62,7 @@ extern zend_class_entry *php_json_serializable_ce; #define PHP_JSON_NUMERIC_CHECK (1<<5) #define PHP_JSON_UNESCAPED_SLASHES (1<<6) #define PHP_JSON_PRETTY_PRINT (1<<7) +#define PHP_JSON_UNESCAPED_UNICODE (1<<8) /* Internal flags */ #define PHP_JSON_OUTPUT_ARRAY 0 diff --git a/ext/json/tests/bug53946.phpt b/ext/json/tests/bug53946.phpt new file mode 100644 index 0000000000000..abbb81238b83f --- /dev/null +++ b/ext/json/tests/bug53946.phpt @@ -0,0 +1,16 @@ +--TEST-- +bug #53946 (json_encode() with JSON_UNESCAPED_UNICODE) +--SKIPIF-- + +--FILE-- +ð„ž<")); +var_dump(json_encode("latin 1234 -/ russian мама мыла раму specialchars \x02 \x08 \n U+1D11E >ð„ž<", JSON_UNESCAPED_UNICODE)); +var_dump(json_encode("ab\xE0")); +var_dump(json_encode("ab\xE0", JSON_UNESCAPED_UNICODE)); +?> +--EXPECT-- +string(156) ""latin 1234 -\/ russian \u043c\u0430\u043c\u0430 \u043c\u044b\u043b\u0430 \u0440\u0430\u043c\u0443 specialchars \u0002 \b \n U+1D11E >\ud834\udd1e<"" +string(100) ""latin 1234 -\/ russian мама мыла раму specialchars \u0002 \b \n U+1D11E >ð„ž<"" +string(4) "null" +string(4) "null" diff --git a/ext/json/utf8_to_utf16.c b/ext/json/utf8_to_utf16.c index 599f0e13b48b2..508bc9368aebb 100644 --- a/ext/json/utf8_to_utf16.c +++ b/ext/json/utf8_to_utf16.c @@ -30,7 +30,7 @@ SOFTWARE. #include "utf8_decode.h" int -utf8_to_utf16(unsigned short w[], char p[], int length) +utf8_to_utf16(unsigned short *w, char p[], int length) { int c; int the_index = 0; @@ -43,14 +43,17 @@ utf8_to_utf16(unsigned short w[], char p[], int length) return (c == UTF8_END) ? the_index : UTF8_ERROR; } if (c < 0x10000) { - w[the_index] = (unsigned short)c; + if (w) { + w[the_index] = (unsigned short)c; + } the_index += 1; } else { c -= 0x10000; - w[the_index] = (unsigned short)(0xD800 | (c >> 10)); - the_index += 1; - w[the_index] = (unsigned short)(0xDC00 | (c & 0x3FF)); - the_index += 1; + if (w) { + w[the_index] = (unsigned short)(0xD800 | (c >> 10)); + w[the_index + 1] = (unsigned short)(0xDC00 | (c & 0x3FF)); + } + the_index += 2; } } } diff --git a/ext/json/utf8_to_utf16.h b/ext/json/utf8_to_utf16.h index 5aff0268bfcf0..5c9685a99128f 100644 --- a/ext/json/utf8_to_utf16.h +++ b/ext/json/utf8_to_utf16.h @@ -1,3 +1,3 @@ /* utf8_to_utf16.h */ -extern int utf8_to_utf16(unsigned short w[], char p[], int length); +extern int utf8_to_utf16(unsigned short *w, char p[], int length); From 1f4dfded592909a162f4b590a25edc681e6b338d Mon Sep 17 00:00:00 2001 From: Stefan Marr Date: Mon, 29 Aug 2011 15:53:46 +0000 Subject: [PATCH 0629/2394] Fixed bug #55524 Traits should not be able to extend a class # also used the Z_STRVAL where it seemed appropriate --- Zend/tests/traits/bug55524.phpt | 15 +++++++++++++++ Zend/zend_compile.c | 7 ++++++- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 Zend/tests/traits/bug55524.phpt diff --git a/Zend/tests/traits/bug55524.phpt b/Zend/tests/traits/bug55524.phpt new file mode 100644 index 0000000000000..1911cde130599 --- /dev/null +++ b/Zend/tests/traits/bug55524.phpt @@ -0,0 +1,15 @@ +--TEST-- +Bug #55524 Traits should not be able to extend a class +--FILE-- + +--EXPECTF-- +Fatal error: A trait (Foo) cannot extend a class in %s on line %d diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 9e673b854d4df..000942f9df3b6 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -4640,7 +4640,7 @@ void zend_do_begin_class_declaration(const znode *class_token, znode *class_name if (!(strcmp(lcname, "self") && strcmp(lcname, "parent"))) { efree(lcname); - zend_error(E_COMPILE_ERROR, "Cannot use '%s' as class name as it is reserved", class_name->u.constant.value.str.val); + zend_error(E_COMPILE_ERROR, "Cannot use '%s' as class name as it is reserved", Z_STRVAL(class_name->u.constant)); } /* Class name must not conflict with import names */ @@ -4707,6 +4707,11 @@ void zend_do_begin_class_declaration(const znode *class_token, znode *class_name opline->op2_type = IS_CONST; if (doing_inheritance) { + /* Make sure a trait does not try to extend a class */ + if ((new_class_entry->ce_flags & ZEND_ACC_TRAIT) == ZEND_ACC_TRAIT) { + zend_error(E_COMPILE_ERROR, "A trait (%s) cannot extend a class", new_class_entry->name); + } + opline->extended_value = parent_class_name->u.op.var; opline->opcode = ZEND_DECLARE_INHERITED_CLASS; } else { From 8e74e304119826ac7de28081a471482155e93bb4 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 29 Aug 2011 16:05:45 +0000 Subject: [PATCH 0630/2394] Fixed bug#53872 (internal corruption of phar) --- ext/phar/tests/bug53872.phpt | 23 +++++++++++++++++++++++ ext/phar/tests/bug53872/first.txt | 1 + ext/phar/tests/bug53872/second.txt | 0 ext/phar/tests/bug53872/third.txt | 1 + ext/phar/util.c | 10 ++++++---- 5 files changed, 31 insertions(+), 4 deletions(-) create mode 100644 ext/phar/tests/bug53872.phpt create mode 100644 ext/phar/tests/bug53872/first.txt create mode 100644 ext/phar/tests/bug53872/second.txt create mode 100644 ext/phar/tests/bug53872/third.txt diff --git a/ext/phar/tests/bug53872.phpt b/ext/phar/tests/bug53872.phpt new file mode 100644 index 0000000000000..490ae6fd4c34b --- /dev/null +++ b/ext/phar/tests/bug53872.phpt @@ -0,0 +1,23 @@ +--TEST-- +bug#53872 (internal corruption of phar) +--INI-- +phar.readonly=0 +--FILE-- +buildFromDirectory(__DIR__ . "/bug53872/"); +$p->setStub(''); +$p->compressFiles(Phar::GZ); + +print(file_get_contents('phar://bug53872-phar.phar/first.txt')); +print(file_get_contents('phar://bug53872-phar.phar/second.txt')); +print(file_get_contents('phar://bug53872-phar.phar/third.txt')); +?> +--CLEAN-- + +--EXPECT-- +content of first.txt +content of third.txt + diff --git a/ext/phar/tests/bug53872/first.txt b/ext/phar/tests/bug53872/first.txt new file mode 100644 index 0000000000000..90a4d1f0921fa --- /dev/null +++ b/ext/phar/tests/bug53872/first.txt @@ -0,0 +1 @@ +content of first.txt diff --git a/ext/phar/tests/bug53872/second.txt b/ext/phar/tests/bug53872/second.txt new file mode 100644 index 0000000000000..e69de29bb2d1d diff --git a/ext/phar/tests/bug53872/third.txt b/ext/phar/tests/bug53872/third.txt new file mode 100644 index 0000000000000..4f283cd78f48b --- /dev/null +++ b/ext/phar/tests/bug53872/third.txt @@ -0,0 +1 @@ +content of third.txt diff --git a/ext/phar/util.c b/ext/phar/util.c index 22403e8ff0b3b..22c99bb8d9ced 100644 --- a/ext/phar/util.c +++ b/ext/phar/util.c @@ -999,10 +999,12 @@ int phar_open_entry_fp(phar_entry_info *entry, char **error, int follow_links TS php_stream_filter_append(&ufp->writefilters, filter); php_stream_seek(phar_get_entrypfp(entry TSRMLS_CC), phar_get_fp_offset(entry TSRMLS_CC), SEEK_SET); - if (SUCCESS != phar_stream_copy_to_stream(phar_get_entrypfp(entry TSRMLS_CC), ufp, entry->compressed_filesize, NULL)) { - spprintf(error, 4096, "phar error: internal corruption of phar \"%s\" (actual filesize mismatch on file \"%s\")", phar->fname, entry->filename); - php_stream_filter_remove(filter, 1 TSRMLS_CC); - return FAILURE; + if (entry->uncompressed_filesize) { + if (SUCCESS != phar_stream_copy_to_stream(phar_get_entrypfp(entry TSRMLS_CC), ufp, entry->compressed_filesize, NULL)) { + spprintf(error, 4096, "phar error: internal corruption of phar \"%s\" (actual filesize mismatch on file \"%s\")", phar->fname, entry->filename); + php_stream_filter_remove(filter, 1 TSRMLS_CC); + return FAILURE; + } } php_stream_filter_flush(filter, 1); From a34e9efcfa02721f0c7270f52792cc7714b9947d Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 29 Aug 2011 16:37:56 +0000 Subject: [PATCH 0631/2394] - Updated to version 2011.9 (2011i) --- ext/date/lib/timezonedb.h | 1344 ++++++++++++++++++------------------- 1 file changed, 666 insertions(+), 678 deletions(-) diff --git a/ext/date/lib/timezonedb.h b/ext/date/lib/timezonedb.h index 7f2a3a0c6bdc9..89dd1a12aab9f 100644 --- a/ext/date/lib/timezonedb.h +++ b/ext/date/lib/timezonedb.h @@ -1,4 +1,4 @@ -const timelib_tzdb_index_entry timezonedb_idx_builtin[573] = { +const timelib_tzdb_index_entry timezonedb_idx_builtin[574] = { { "Africa/Abidjan" , 0x000000 }, { "Africa/Accra" , 0x000055 }, { "Africa/Addis_Ababa" , 0x0000FD }, @@ -25,556 +25,557 @@ const timelib_tzdb_index_entry timezonedb_idx_builtin[573] = { { "Africa/Gaborone" , 0x000FCC }, { "Africa/Harare" , 0x001027 }, { "Africa/Johannesburg" , 0x00107C }, - { "Africa/Kampala" , 0x0010EA }, - { "Africa/Khartoum" , 0x001169 }, - { "Africa/Kigali" , 0x00127C }, - { "Africa/Kinshasa" , 0x0012D1 }, - { "Africa/Lagos" , 0x00132C }, - { "Africa/Libreville" , 0x001381 }, - { "Africa/Lome" , 0x0013D6 }, - { "Africa/Luanda" , 0x00141A }, - { "Africa/Lubumbashi" , 0x00146F }, - { "Africa/Lusaka" , 0x0014CA }, - { "Africa/Malabo" , 0x00151F }, - { "Africa/Maputo" , 0x001585 }, - { "Africa/Maseru" , 0x0015DA }, - { "Africa/Mbabane" , 0x001642 }, - { "Africa/Mogadishu" , 0x001698 }, - { "Africa/Monrovia" , 0x0016F3 }, - { "Africa/Nairobi" , 0x001759 }, - { "Africa/Ndjamena" , 0x0017D8 }, - { "Africa/Niamey" , 0x001844 }, - { "Africa/Nouakchott" , 0x0018B7 }, - { "Africa/Ouagadougou" , 0x001922 }, - { "Africa/Porto-Novo" , 0x001977 }, - { "Africa/Sao_Tome" , 0x0019DD }, - { "Africa/Timbuktu" , 0x001A32 }, - { "Africa/Tripoli" , 0x001A9D }, - { "Africa/Tunis" , 0x001B97 }, - { "Africa/Windhoek" , 0x001CA9 }, - { "America/Adak" , 0x001EF0 }, - { "America/Anchorage" , 0x002266 }, - { "America/Anguilla" , 0x0025DA }, - { "America/Antigua" , 0x00262F }, - { "America/Araguaina" , 0x002695 }, - { "America/Argentina/Buenos_Aires" , 0x0027F0 }, - { "America/Argentina/Catamarca" , 0x00299E }, - { "America/Argentina/ComodRivadavia" , 0x002B5F }, - { "America/Argentina/Cordoba" , 0x002D05 }, - { "America/Argentina/Jujuy" , 0x002EDA }, - { "America/Argentina/La_Rioja" , 0x00308E }, - { "America/Argentina/Mendoza" , 0x003246 }, - { "America/Argentina/Rio_Gallegos" , 0x003406 }, - { "America/Argentina/Salta" , 0x0035BB }, - { "America/Argentina/San_Juan" , 0x003767 }, - { "America/Argentina/San_Luis" , 0x00391F }, - { "America/Argentina/Tucuman" , 0x003AE5 }, - { "America/Argentina/Ushuaia" , 0x003CA1 }, - { "America/Aruba" , 0x003E5C }, - { "America/Asuncion" , 0x003EC2 }, - { "America/Atikokan" , 0x0041A7 }, - { "America/Atka" , 0x00427D }, - { "America/Bahia" , 0x0045E3 }, - { "America/Bahia_Banderas" , 0x00476C }, - { "America/Barbados" , 0x0049E5 }, - { "America/Belem" , 0x004A7F }, - { "America/Belize" , 0x004B7A }, - { "America/Blanc-Sablon" , 0x004CF6 }, - { "America/Boa_Vista" , 0x004DAA }, - { "America/Bogota" , 0x004EB3 }, - { "America/Boise" , 0x004F1F }, - { "America/Buenos_Aires" , 0x0052B6 }, - { "America/Cambridge_Bay" , 0x00544F }, - { "America/Campo_Grande" , 0x005777 }, - { "America/Cancun" , 0x005A66 }, - { "America/Caracas" , 0x005CA8 }, - { "America/Catamarca" , 0x005D0F }, - { "America/Cayenne" , 0x005EB5 }, - { "America/Cayman" , 0x005F17 }, - { "America/Chicago" , 0x005F6C }, - { "America/Chihuahua" , 0x006483 }, - { "America/Coral_Harbour" , 0x0066EE }, - { "America/Cordoba" , 0x006780 }, - { "America/Costa_Rica" , 0x006926 }, - { "America/Cuiaba" , 0x0069B0 }, - { "America/Curacao" , 0x006C8E }, - { "America/Danmarkshavn" , 0x006CF4 }, - { "America/Dawson" , 0x006E38 }, - { "America/Dawson_Creek" , 0x007155 }, - { "America/Denver" , 0x00732F }, - { "America/Detroit" , 0x0076B5 }, - { "America/Dominica" , 0x007A14 }, - { "America/Edmonton" , 0x007A69 }, - { "America/Eirunepe" , 0x007E21 }, - { "America/El_Salvador" , 0x007F34 }, - { "America/Ensenada" , 0x007FA9 }, - { "America/Fort_Wayne" , 0x008450 }, - { "America/Fortaleza" , 0x008312 }, - { "America/Glace_Bay" , 0x0086BA }, - { "America/Godthab" , 0x008A31 }, - { "America/Goose_Bay" , 0x008CF5 }, - { "America/Grand_Turk" , 0x0091B2 }, - { "America/Grenada" , 0x009461 }, - { "America/Guadeloupe" , 0x0094B6 }, - { "America/Guatemala" , 0x00950B }, - { "America/Guayaquil" , 0x009594 }, - { "America/Guyana" , 0x0095F1 }, - { "America/Halifax" , 0x009672 }, - { "America/Havana" , 0x009B88 }, - { "America/Hermosillo" , 0x009EFB }, - { "America/Indiana/Indianapolis" , 0x009FD9 }, - { "America/Indiana/Knox" , 0x00A26A }, - { "America/Indiana/Marengo" , 0x00A601 }, - { "America/Indiana/Petersburg" , 0x00A8A7 }, - { "America/Indiana/Tell_City" , 0x00ADF4 }, - { "America/Indiana/Vevay" , 0x00B08D }, - { "America/Indiana/Vincennes" , 0x00B2C8 }, - { "America/Indiana/Winamac" , 0x00B57C }, - { "America/Indianapolis" , 0x00AB8A }, - { "America/Inuvik" , 0x00B835 }, - { "America/Iqaluit" , 0x00BB2C }, - { "America/Jamaica" , 0x00BE4E }, - { "America/Jujuy" , 0x00BF13 }, - { "America/Juneau" , 0x00C0BD }, - { "America/Kentucky/Louisville" , 0x00C43B }, - { "America/Kentucky/Monticello" , 0x00C859 }, - { "America/Knox_IN" , 0x00CBDE }, - { "America/Kralendijk" , 0x00CF4F }, - { "America/La_Paz" , 0x00CFB5 }, - { "America/Lima" , 0x00D01C }, - { "America/Los_Angeles" , 0x00D0C4 }, - { "America/Louisville" , 0x00D4D5 }, - { "America/Lower_Princes" , 0x00D8CA }, - { "America/Maceio" , 0x00D930 }, - { "America/Managua" , 0x00DA6A }, - { "America/Manaus" , 0x00DB1D }, - { "America/Marigot" , 0x00DC1F }, - { "America/Martinique" , 0x00DC74 }, - { "America/Matamoros" , 0x00DCE0 }, - { "America/Mazatlan" , 0x00DF39 }, - { "America/Mendoza" , 0x00E1A6 }, - { "America/Menominee" , 0x00E35A }, - { "America/Merida" , 0x00E6DB }, - { "America/Metlakatla" , 0x00E916 }, - { "America/Mexico_City" , 0x00EC74 }, - { "America/Miquelon" , 0x00EEEF }, - { "America/Moncton" , 0x00F161 }, - { "America/Monterrey" , 0x00F5F8 }, - { "America/Montevideo" , 0x00F85B }, - { "America/Montreal" , 0x00FB6D }, - { "America/Montserrat" , 0x010083 }, - { "America/Nassau" , 0x0100D8 }, - { "America/New_York" , 0x01041D }, - { "America/Nipigon" , 0x010928 }, - { "America/Nome" , 0x010C79 }, - { "America/Noronha" , 0x010FF7 }, - { "America/North_Dakota/Beulah" , 0x011127 }, - { "America/North_Dakota/Center" , 0x0114BB }, - { "America/North_Dakota/New_Salem" , 0x01184F }, - { "America/Ojinaga" , 0x011BF8 }, - { "America/Panama" , 0x011E59 }, - { "America/Pangnirtung" , 0x011EAE }, - { "America/Paramaribo" , 0x0121E4 }, - { "America/Phoenix" , 0x012276 }, - { "America/Port-au-Prince" , 0x012324 }, - { "America/Port_of_Spain" , 0x01253F }, - { "America/Porto_Acre" , 0x012440 }, - { "America/Porto_Velho" , 0x012594 }, - { "America/Puerto_Rico" , 0x01268A }, - { "America/Rainy_River" , 0x0126F5 }, - { "America/Rankin_Inlet" , 0x012A2D }, - { "America/Recife" , 0x012D13 }, - { "America/Regina" , 0x012E3D }, - { "America/Resolute" , 0x012FFB }, - { "America/Rio_Branco" , 0x0132F4 }, - { "America/Rosario" , 0x0133F7 }, - { "America/Santa_Isabel" , 0x01359D }, - { "America/Santarem" , 0x013940 }, - { "America/Santiago" , 0x013A45 }, - { "America/Santo_Domingo" , 0x013DEE }, - { "America/Sao_Paulo" , 0x013EB4 }, - { "America/Scoresbysund" , 0x0141C3 }, - { "America/Shiprock" , 0x0144B1 }, - { "America/Sitka" , 0x014840 }, - { "America/St_Barthelemy" , 0x014BC8 }, - { "America/St_Johns" , 0x014C1D }, - { "America/St_Kitts" , 0x015170 }, - { "America/St_Lucia" , 0x0151C5 }, - { "America/St_Thomas" , 0x01521A }, - { "America/St_Vincent" , 0x01526F }, - { "America/Swift_Current" , 0x0152C4 }, - { "America/Tegucigalpa" , 0x0153E5 }, - { "America/Thule" , 0x015464 }, - { "America/Thunder_Bay" , 0x0156AB }, - { "America/Tijuana" , 0x0159F4 }, - { "America/Toronto" , 0x015D8D }, - { "America/Tortola" , 0x0162A4 }, - { "America/Vancouver" , 0x0162F9 }, - { "America/Virgin" , 0x016736 }, - { "America/Whitehorse" , 0x01678B }, - { "America/Winnipeg" , 0x016AA8 }, - { "America/Yakutat" , 0x016EE8 }, - { "America/Yellowknife" , 0x017253 }, - { "Antarctica/Casey" , 0x017563 }, - { "Antarctica/Davis" , 0x0175EE }, - { "Antarctica/DumontDUrville" , 0x017685 }, - { "Antarctica/Macquarie" , 0x017717 }, - { "Antarctica/Mawson" , 0x017991 }, - { "Antarctica/McMurdo" , 0x017A0D }, - { "Antarctica/Palmer" , 0x017D0F }, - { "Antarctica/Rothera" , 0x01802B }, - { "Antarctica/South_Pole" , 0x0180A1 }, - { "Antarctica/Syowa" , 0x0183A9 }, - { "Antarctica/Vostok" , 0x018417 }, - { "Arctic/Longyearbyen" , 0x018488 }, - { "Asia/Aden" , 0x0187BA }, - { "Asia/Almaty" , 0x01880F }, - { "Asia/Amman" , 0x01898E }, - { "Asia/Anadyr" , 0x018C4E }, - { "Asia/Aqtau" , 0x018E33 }, - { "Asia/Aqtobe" , 0x019032 }, - { "Asia/Ashgabat" , 0x0191EA }, - { "Asia/Ashkhabad" , 0x019307 }, - { "Asia/Baghdad" , 0x019424 }, - { "Asia/Bahrain" , 0x019599 }, - { "Asia/Baku" , 0x0195FF }, - { "Asia/Bangkok" , 0x0198E7 }, - { "Asia/Beirut" , 0x01993C }, - { "Asia/Bishkek" , 0x019C49 }, - { "Asia/Brunei" , 0x019DF5 }, - { "Asia/Calcutta" , 0x019E57 }, - { "Asia/Choibalsan" , 0x019ED0 }, - { "Asia/Chongqing" , 0x01A049 }, - { "Asia/Chungking" , 0x01A138 }, - { "Asia/Colombo" , 0x01A1E7 }, - { "Asia/Dacca" , 0x01A283 }, - { "Asia/Damascus" , 0x01A329 }, - { "Asia/Dhaka" , 0x01A679 }, - { "Asia/Dili" , 0x01A71F }, - { "Asia/Dubai" , 0x01A7A8 }, - { "Asia/Dushanbe" , 0x01A7FD }, - { "Asia/Gaza" , 0x01A900 }, - { "Asia/Harbin" , 0x01AC49 }, - { "Asia/Ho_Chi_Minh" , 0x01AD30 }, - { "Asia/Hong_Kong" , 0x01ADA8 }, - { "Asia/Hovd" , 0x01AF6A }, - { "Asia/Irkutsk" , 0x01B0E2 }, - { "Asia/Istanbul" , 0x01B2C8 }, - { "Asia/Jakarta" , 0x01B6B5 }, - { "Asia/Jayapura" , 0x01B75F }, - { "Asia/Jerusalem" , 0x01B7FB }, - { "Asia/Kabul" , 0x01BB2A }, - { "Asia/Kamchatka" , 0x01BB7B }, - { "Asia/Karachi" , 0x01BD57 }, - { "Asia/Kashgar" , 0x01BE0C }, - { "Asia/Kathmandu" , 0x01BEDD }, - { "Asia/Katmandu" , 0x01BF43 }, - { "Asia/Kolkata" , 0x01BFA9 }, - { "Asia/Krasnoyarsk" , 0x01C022 }, - { "Asia/Kuala_Lumpur" , 0x01C20A }, - { "Asia/Kuching" , 0x01C2C7 }, - { "Asia/Kuwait" , 0x01C3B5 }, - { "Asia/Macao" , 0x01C40A }, - { "Asia/Macau" , 0x01C545 }, - { "Asia/Magadan" , 0x01C680 }, - { "Asia/Makassar" , 0x01C862 }, - { "Asia/Manila" , 0x01C926 }, - { "Asia/Muscat" , 0x01C9AB }, - { "Asia/Nicosia" , 0x01CA00 }, - { "Asia/Novokuznetsk" , 0x01CCE8 }, - { "Asia/Novosibirsk" , 0x01CEEA }, - { "Asia/Omsk" , 0x01D0D5 }, - { "Asia/Oral" , 0x01D2BC }, - { "Asia/Phnom_Penh" , 0x01D48C }, - { "Asia/Pontianak" , 0x01D504 }, - { "Asia/Pyongyang" , 0x01D5C5 }, - { "Asia/Qatar" , 0x01D632 }, - { "Asia/Qyzylorda" , 0x01D698 }, - { "Asia/Rangoon" , 0x01D86E }, - { "Asia/Riyadh" , 0x01D8E6 }, - { "Asia/Saigon" , 0x01D93B }, - { "Asia/Sakhalin" , 0x01D9B3 }, - { "Asia/Samarkand" , 0x01DBAA }, - { "Asia/Seoul" , 0x01DCE0 }, - { "Asia/Shanghai" , 0x01DD84 }, - { "Asia/Singapore" , 0x01DE64 }, - { "Asia/Taipei" , 0x01DF1B }, - { "Asia/Tashkent" , 0x01E033 }, - { "Asia/Tbilisi" , 0x01E164 }, - { "Asia/Tehran" , 0x01E31E }, - { "Asia/Tel_Aviv" , 0x01E58C }, - { "Asia/Thimbu" , 0x01E8BB }, - { "Asia/Thimphu" , 0x01E921 }, - { "Asia/Tokyo" , 0x01E987 }, - { "Asia/Ujung_Pandang" , 0x01EA10 }, - { "Asia/Ulaanbaatar" , 0x01EA8C }, - { "Asia/Ulan_Bator" , 0x01EBE7 }, - { "Asia/Urumqi" , 0x01ED34 }, - { "Asia/Vientiane" , 0x01EDFB }, - { "Asia/Vladivostok" , 0x01EE73 }, - { "Asia/Yakutsk" , 0x01F05F }, - { "Asia/Yekaterinburg" , 0x01F244 }, - { "Asia/Yerevan" , 0x01F44F }, - { "Atlantic/Azores" , 0x01F753 }, - { "Atlantic/Bermuda" , 0x01FC56 }, - { "Atlantic/Canary" , 0x01FF37 }, - { "Atlantic/Cape_Verde" , 0x02020D }, - { "Atlantic/Faeroe" , 0x020286 }, - { "Atlantic/Faroe" , 0x02052A }, - { "Atlantic/Jan_Mayen" , 0x0207CE }, - { "Atlantic/Madeira" , 0x020B00 }, - { "Atlantic/Reykjavik" , 0x021009 }, - { "Atlantic/South_Georgia" , 0x0211C2 }, - { "Atlantic/St_Helena" , 0x0214D0 }, - { "Atlantic/Stanley" , 0x021206 }, - { "Australia/ACT" , 0x021525 }, - { "Australia/Adelaide" , 0x021842 }, - { "Australia/Brisbane" , 0x021B6E }, - { "Australia/Broken_Hill" , 0x021C35 }, - { "Australia/Canberra" , 0x021F73 }, - { "Australia/Currie" , 0x022290 }, - { "Australia/Darwin" , 0x0225C3 }, - { "Australia/Eucla" , 0x022649 }, - { "Australia/Hobart" , 0x02271E }, - { "Australia/LHI" , 0x022A7C }, - { "Australia/Lindeman" , 0x022D17 }, - { "Australia/Lord_Howe" , 0x022DF8 }, - { "Australia/Melbourne" , 0x0230A3 }, - { "Australia/North" , 0x0233C8 }, - { "Australia/NSW" , 0x02343C }, - { "Australia/Perth" , 0x023759 }, - { "Australia/Queensland" , 0x023831 }, - { "Australia/South" , 0x0238DD }, - { "Australia/Sydney" , 0x023BFA }, - { "Australia/Tasmania" , 0x023F37 }, - { "Australia/Victoria" , 0x02427C }, - { "Australia/West" , 0x024599 }, - { "Australia/Yancowinna" , 0x02464F }, - { "Brazil/Acre" , 0x024971 }, - { "Brazil/DeNoronha" , 0x024A70 }, - { "Brazil/East" , 0x024B90 }, - { "Brazil/West" , 0x024E6D }, - { "Canada/Atlantic" , 0x024F65 }, - { "Canada/Central" , 0x02544D }, - { "Canada/East-Saskatchewan" , 0x025D57 }, - { "Canada/Eastern" , 0x025867 }, - { "Canada/Mountain" , 0x025EE0 }, - { "Canada/Newfoundland" , 0x026256 }, - { "Canada/Pacific" , 0x026781 }, - { "Canada/Saskatchewan" , 0x026B9A }, - { "Canada/Yukon" , 0x026D23 }, - { "CET" , 0x027026 }, - { "Chile/Continental" , 0x02732F }, - { "Chile/EasterIsland" , 0x0276CA }, - { "CST6CDT" , 0x027A0C }, - { "Cuba" , 0x027D5D }, - { "EET" , 0x0280D0 }, - { "Egypt" , 0x028383 }, - { "Eire" , 0x028646 }, - { "EST" , 0x028B57 }, - { "EST5EDT" , 0x028B9B }, - { "Etc/GMT" , 0x028EEC }, - { "Etc/GMT+0" , 0x028FB8 }, - { "Etc/GMT+1" , 0x029042 }, - { "Etc/GMT+10" , 0x0290CF }, - { "Etc/GMT+11" , 0x02915D }, - { "Etc/GMT+12" , 0x0291EB }, - { "Etc/GMT+2" , 0x029306 }, - { "Etc/GMT+3" , 0x029392 }, - { "Etc/GMT+4" , 0x02941E }, - { "Etc/GMT+5" , 0x0294AA }, - { "Etc/GMT+6" , 0x029536 }, - { "Etc/GMT+7" , 0x0295C2 }, - { "Etc/GMT+8" , 0x02964E }, - { "Etc/GMT+9" , 0x0296DA }, - { "Etc/GMT-0" , 0x028F74 }, - { "Etc/GMT-1" , 0x028FFC }, - { "Etc/GMT-10" , 0x029088 }, - { "Etc/GMT-11" , 0x029116 }, - { "Etc/GMT-12" , 0x0291A4 }, - { "Etc/GMT-13" , 0x029232 }, - { "Etc/GMT-14" , 0x029279 }, - { "Etc/GMT-2" , 0x0292C0 }, - { "Etc/GMT-3" , 0x02934C }, - { "Etc/GMT-4" , 0x0293D8 }, - { "Etc/GMT-5" , 0x029464 }, - { "Etc/GMT-6" , 0x0294F0 }, - { "Etc/GMT-7" , 0x02957C }, - { "Etc/GMT-8" , 0x029608 }, - { "Etc/GMT-9" , 0x029694 }, - { "Etc/GMT0" , 0x028F30 }, - { "Etc/Greenwich" , 0x029720 }, - { "Etc/UCT" , 0x029764 }, - { "Etc/Universal" , 0x0297A8 }, - { "Etc/UTC" , 0x0297EC }, - { "Etc/Zulu" , 0x029830 }, - { "Europe/Amsterdam" , 0x029874 }, - { "Europe/Andorra" , 0x029CB2 }, - { "Europe/Athens" , 0x029F2E }, - { "Europe/Belfast" , 0x02A271 }, - { "Europe/Belgrade" , 0x02A7A8 }, - { "Europe/Berlin" , 0x02AA71 }, - { "Europe/Bratislava" , 0x02ADC7 }, - { "Europe/Brussels" , 0x02B0F9 }, - { "Europe/Bucharest" , 0x02B530 }, - { "Europe/Budapest" , 0x02B85A }, - { "Europe/Chisinau" , 0x02BBCD }, - { "Europe/Copenhagen" , 0x02BF5B }, - { "Europe/Dublin" , 0x02C265 }, - { "Europe/Gibraltar" , 0x02C776 }, - { "Europe/Guernsey" , 0x02CBCD }, - { "Europe/Helsinki" , 0x02D104 }, - { "Europe/Isle_of_Man" , 0x02D3BA }, - { "Europe/Istanbul" , 0x02D8F1 }, - { "Europe/Jersey" , 0x02DCDE }, - { "Europe/Kaliningrad" , 0x02E215 }, - { "Europe/Kiev" , 0x02E477 }, - { "Europe/Lisbon" , 0x02E78E }, - { "Europe/Ljubljana" , 0x02EC92 }, - { "Europe/London" , 0x02EF5B }, - { "Europe/Luxembourg" , 0x02F492 }, - { "Europe/Madrid" , 0x02F8E8 }, - { "Europe/Malta" , 0x02FCAE }, - { "Europe/Mariehamn" , 0x030067 }, - { "Europe/Minsk" , 0x03031D }, - { "Europe/Monaco" , 0x030628 }, - { "Europe/Moscow" , 0x030A63 }, - { "Europe/Nicosia" , 0x030CB4 }, - { "Europe/Oslo" , 0x030F9C }, - { "Europe/Paris" , 0x0312CE }, - { "Europe/Podgorica" , 0x031714 }, - { "Europe/Prague" , 0x0319DD }, - { "Europe/Riga" , 0x031D0F }, - { "Europe/Rome" , 0x032054 }, - { "Europe/Samara" , 0x032417 }, - { "Europe/San_Marino" , 0x032647 }, - { "Europe/Sarajevo" , 0x032A0A }, - { "Europe/Simferopol" , 0x032CD3 }, - { "Europe/Skopje" , 0x032FFE }, - { "Europe/Sofia" , 0x0332C7 }, - { "Europe/Stockholm" , 0x0335CF }, - { "Europe/Tallinn" , 0x03387E }, - { "Europe/Tirane" , 0x033BB8 }, - { "Europe/Tiraspol" , 0x033EBE }, - { "Europe/Uzhgorod" , 0x03424C }, - { "Europe/Vaduz" , 0x034563 }, - { "Europe/Vatican" , 0x0347F6 }, - { "Europe/Vienna" , 0x034BB9 }, - { "Europe/Vilnius" , 0x034EE6 }, - { "Europe/Volgograd" , 0x035225 }, - { "Europe/Warsaw" , 0x035425 }, - { "Europe/Zagreb" , 0x035806 }, - { "Europe/Zaporozhye" , 0x035ACF }, - { "Europe/Zurich" , 0x035E10 }, - { "Factory" , 0x0360BF }, - { "GB" , 0x036130 }, - { "GB-Eire" , 0x036667 }, - { "GMT" , 0x036B9E }, - { "GMT+0" , 0x036C6A }, - { "GMT-0" , 0x036C26 }, - { "GMT0" , 0x036BE2 }, - { "Greenwich" , 0x036CAE }, - { "Hongkong" , 0x036CF2 }, - { "HST" , 0x036EB4 }, - { "Iceland" , 0x036EF8 }, - { "Indian/Antananarivo" , 0x0370B1 }, - { "Indian/Chagos" , 0x037125 }, - { "Indian/Christmas" , 0x037187 }, - { "Indian/Cocos" , 0x0371CB }, - { "Indian/Comoro" , 0x03720F }, - { "Indian/Kerguelen" , 0x037264 }, - { "Indian/Mahe" , 0x0372B9 }, - { "Indian/Maldives" , 0x03730E }, - { "Indian/Mauritius" , 0x037363 }, - { "Indian/Mayotte" , 0x0373D9 }, - { "Indian/Reunion" , 0x03742E }, - { "Iran" , 0x037483 }, - { "Israel" , 0x0376F1 }, - { "Jamaica" , 0x037A20 }, - { "Japan" , 0x037AE5 }, - { "Kwajalein" , 0x037B6E }, - { "Libya" , 0x037BD1 }, - { "MET" , 0x037CCB }, - { "Mexico/BajaNorte" , 0x037FD4 }, - { "Mexico/BajaSur" , 0x03833D }, - { "Mexico/General" , 0x038582 }, - { "MST" , 0x0387E0 }, - { "MST7MDT" , 0x038824 }, - { "Navajo" , 0x038B75 }, - { "NZ" , 0x038EEE }, - { "NZ-CHAT" , 0x03926C }, - { "Pacific/Apia" , 0x039554 }, - { "Pacific/Auckland" , 0x0395D2 }, - { "Pacific/Chatham" , 0x03995E }, - { "Pacific/Chuuk" , 0x039C55 }, - { "Pacific/Easter" , 0x039CAE }, - { "Pacific/Efate" , 0x03A00C }, - { "Pacific/Enderbury" , 0x03A0D2 }, - { "Pacific/Fakaofo" , 0x03A140 }, - { "Pacific/Fiji" , 0x03A184 }, - { "Pacific/Funafuti" , 0x03A20E }, - { "Pacific/Galapagos" , 0x03A252 }, - { "Pacific/Gambier" , 0x03A2CA }, - { "Pacific/Guadalcanal" , 0x03A32F }, - { "Pacific/Guam" , 0x03A384 }, - { "Pacific/Honolulu" , 0x03A3DA }, - { "Pacific/Johnston" , 0x03A451 }, - { "Pacific/Kiritimati" , 0x03A4A3 }, - { "Pacific/Kosrae" , 0x03A50E }, - { "Pacific/Kwajalein" , 0x03A56B }, - { "Pacific/Majuro" , 0x03A5D7 }, - { "Pacific/Marquesas" , 0x03A636 }, - { "Pacific/Midway" , 0x03A69D }, - { "Pacific/Nauru" , 0x03A727 }, - { "Pacific/Niue" , 0x03A79F }, - { "Pacific/Norfolk" , 0x03A7FD }, - { "Pacific/Noumea" , 0x03A852 }, - { "Pacific/Pago_Pago" , 0x03A8E2 }, - { "Pacific/Palau" , 0x03A96B }, - { "Pacific/Pitcairn" , 0x03A9AF }, - { "Pacific/Pohnpei" , 0x03AA04 }, - { "Pacific/Ponape" , 0x03AA59 }, - { "Pacific/Port_Moresby" , 0x03AA9E }, - { "Pacific/Rarotonga" , 0x03AAE2 }, - { "Pacific/Saipan" , 0x03ABBE }, - { "Pacific/Samoa" , 0x03AC21 }, - { "Pacific/Tahiti" , 0x03ACAA }, - { "Pacific/Tarawa" , 0x03AD0F }, - { "Pacific/Tongatapu" , 0x03AD63 }, - { "Pacific/Truk" , 0x03ADEF }, - { "Pacific/Wake" , 0x03AE34 }, - { "Pacific/Wallis" , 0x03AE84 }, - { "Pacific/Yap" , 0x03AEC8 }, - { "Poland" , 0x03AF0D }, - { "Portugal" , 0x03B2EE }, - { "PRC" , 0x03B7EA }, - { "PST8PDT" , 0x03B89B }, - { "ROC" , 0x03BBEC }, - { "ROK" , 0x03BD04 }, - { "Singapore" , 0x03BDA8 }, - { "Turkey" , 0x03BE5F }, - { "UCT" , 0x03C24C }, - { "Universal" , 0x03C290 }, - { "US/Alaska" , 0x03C2D4 }, - { "US/Aleutian" , 0x03C63D }, - { "US/Arizona" , 0x03C9A3 }, - { "US/Central" , 0x03CA31 }, - { "US/East-Indiana" , 0x03D43B }, - { "US/Eastern" , 0x03CF3C }, - { "US/Hawaii" , 0x03D6A5 }, - { "US/Indiana-Starke" , 0x03D716 }, - { "US/Michigan" , 0x03DA87 }, - { "US/Mountain" , 0x03DDBE }, - { "US/Pacific" , 0x03E137 }, - { "US/Pacific-New" , 0x03E53C }, - { "US/Samoa" , 0x03E941 }, - { "UTC" , 0x03E9CA }, - { "W-SU" , 0x03ECC1 }, - { "WET" , 0x03EA0E }, - { "Zulu" , 0x03EEFB }, + { "Africa/Juba" , 0x0010EA }, + { "Africa/Kampala" , 0x0011FD }, + { "Africa/Khartoum" , 0x00127C }, + { "Africa/Kigali" , 0x00138F }, + { "Africa/Kinshasa" , 0x0013E4 }, + { "Africa/Lagos" , 0x00143F }, + { "Africa/Libreville" , 0x001494 }, + { "Africa/Lome" , 0x0014E9 }, + { "Africa/Luanda" , 0x00152D }, + { "Africa/Lubumbashi" , 0x001582 }, + { "Africa/Lusaka" , 0x0015DD }, + { "Africa/Malabo" , 0x001632 }, + { "Africa/Maputo" , 0x001698 }, + { "Africa/Maseru" , 0x0016ED }, + { "Africa/Mbabane" , 0x001755 }, + { "Africa/Mogadishu" , 0x0017AB }, + { "Africa/Monrovia" , 0x001806 }, + { "Africa/Nairobi" , 0x00186C }, + { "Africa/Ndjamena" , 0x0018EB }, + { "Africa/Niamey" , 0x001957 }, + { "Africa/Nouakchott" , 0x0019CA }, + { "Africa/Ouagadougou" , 0x001A35 }, + { "Africa/Porto-Novo" , 0x001A8A }, + { "Africa/Sao_Tome" , 0x001AF0 }, + { "Africa/Timbuktu" , 0x001B45 }, + { "Africa/Tripoli" , 0x001BB0 }, + { "Africa/Tunis" , 0x001CAA }, + { "Africa/Windhoek" , 0x001DBC }, + { "America/Adak" , 0x002003 }, + { "America/Anchorage" , 0x002379 }, + { "America/Anguilla" , 0x0026ED }, + { "America/Antigua" , 0x002742 }, + { "America/Araguaina" , 0x0027A8 }, + { "America/Argentina/Buenos_Aires" , 0x002903 }, + { "America/Argentina/Catamarca" , 0x002AB1 }, + { "America/Argentina/ComodRivadavia" , 0x002C72 }, + { "America/Argentina/Cordoba" , 0x002E18 }, + { "America/Argentina/Jujuy" , 0x002FED }, + { "America/Argentina/La_Rioja" , 0x0031A1 }, + { "America/Argentina/Mendoza" , 0x003359 }, + { "America/Argentina/Rio_Gallegos" , 0x003519 }, + { "America/Argentina/Salta" , 0x0036CE }, + { "America/Argentina/San_Juan" , 0x00387A }, + { "America/Argentina/San_Luis" , 0x003A32 }, + { "America/Argentina/Tucuman" , 0x003BF8 }, + { "America/Argentina/Ushuaia" , 0x003DB4 }, + { "America/Aruba" , 0x003F6F }, + { "America/Asuncion" , 0x003FD5 }, + { "America/Atikokan" , 0x0042BA }, + { "America/Atka" , 0x004390 }, + { "America/Bahia" , 0x0046F6 }, + { "America/Bahia_Banderas" , 0x00487F }, + { "America/Barbados" , 0x004AF8 }, + { "America/Belem" , 0x004B92 }, + { "America/Belize" , 0x004C8D }, + { "America/Blanc-Sablon" , 0x004E09 }, + { "America/Boa_Vista" , 0x004EBD }, + { "America/Bogota" , 0x004FC6 }, + { "America/Boise" , 0x005032 }, + { "America/Buenos_Aires" , 0x0053C9 }, + { "America/Cambridge_Bay" , 0x005562 }, + { "America/Campo_Grande" , 0x00588A }, + { "America/Cancun" , 0x005B79 }, + { "America/Caracas" , 0x005DBB }, + { "America/Catamarca" , 0x005E22 }, + { "America/Cayenne" , 0x005FC8 }, + { "America/Cayman" , 0x00602A }, + { "America/Chicago" , 0x00607F }, + { "America/Chihuahua" , 0x006596 }, + { "America/Coral_Harbour" , 0x006801 }, + { "America/Cordoba" , 0x006893 }, + { "America/Costa_Rica" , 0x006A39 }, + { "America/Cuiaba" , 0x006AC3 }, + { "America/Curacao" , 0x006DA1 }, + { "America/Danmarkshavn" , 0x006E07 }, + { "America/Dawson" , 0x006F4B }, + { "America/Dawson_Creek" , 0x007268 }, + { "America/Denver" , 0x007442 }, + { "America/Detroit" , 0x0077C8 }, + { "America/Dominica" , 0x007B27 }, + { "America/Edmonton" , 0x007B7C }, + { "America/Eirunepe" , 0x007F34 }, + { "America/El_Salvador" , 0x008047 }, + { "America/Ensenada" , 0x0080BC }, + { "America/Fort_Wayne" , 0x008563 }, + { "America/Fortaleza" , 0x008425 }, + { "America/Glace_Bay" , 0x0087CD }, + { "America/Godthab" , 0x008B44 }, + { "America/Goose_Bay" , 0x008E08 }, + { "America/Grand_Turk" , 0x0092C5 }, + { "America/Grenada" , 0x009574 }, + { "America/Guadeloupe" , 0x0095C9 }, + { "America/Guatemala" , 0x00961E }, + { "America/Guayaquil" , 0x0096A7 }, + { "America/Guyana" , 0x009704 }, + { "America/Halifax" , 0x009785 }, + { "America/Havana" , 0x009C9B }, + { "America/Hermosillo" , 0x00A00E }, + { "America/Indiana/Indianapolis" , 0x00A0EC }, + { "America/Indiana/Knox" , 0x00A37D }, + { "America/Indiana/Marengo" , 0x00A714 }, + { "America/Indiana/Petersburg" , 0x00A9BA }, + { "America/Indiana/Tell_City" , 0x00AF07 }, + { "America/Indiana/Vevay" , 0x00B1A0 }, + { "America/Indiana/Vincennes" , 0x00B3DB }, + { "America/Indiana/Winamac" , 0x00B68F }, + { "America/Indianapolis" , 0x00AC9D }, + { "America/Inuvik" , 0x00B948 }, + { "America/Iqaluit" , 0x00BC3F }, + { "America/Jamaica" , 0x00BF61 }, + { "America/Jujuy" , 0x00C026 }, + { "America/Juneau" , 0x00C1D0 }, + { "America/Kentucky/Louisville" , 0x00C54E }, + { "America/Kentucky/Monticello" , 0x00C96C }, + { "America/Knox_IN" , 0x00CCF1 }, + { "America/Kralendijk" , 0x00D062 }, + { "America/La_Paz" , 0x00D0C8 }, + { "America/Lima" , 0x00D12F }, + { "America/Los_Angeles" , 0x00D1D7 }, + { "America/Louisville" , 0x00D5E8 }, + { "America/Lower_Princes" , 0x00D9DD }, + { "America/Maceio" , 0x00DA43 }, + { "America/Managua" , 0x00DB7D }, + { "America/Manaus" , 0x00DC30 }, + { "America/Marigot" , 0x00DD32 }, + { "America/Martinique" , 0x00DD87 }, + { "America/Matamoros" , 0x00DDF3 }, + { "America/Mazatlan" , 0x00E04C }, + { "America/Mendoza" , 0x00E2B9 }, + { "America/Menominee" , 0x00E46D }, + { "America/Merida" , 0x00E7EE }, + { "America/Metlakatla" , 0x00EA29 }, + { "America/Mexico_City" , 0x00EB63 }, + { "America/Miquelon" , 0x00EDDE }, + { "America/Moncton" , 0x00F050 }, + { "America/Monterrey" , 0x00F4E7 }, + { "America/Montevideo" , 0x00F74A }, + { "America/Montreal" , 0x00FA5C }, + { "America/Montserrat" , 0x00FF72 }, + { "America/Nassau" , 0x00FFC7 }, + { "America/New_York" , 0x01030C }, + { "America/Nipigon" , 0x010817 }, + { "America/Nome" , 0x010B68 }, + { "America/Noronha" , 0x010EE6 }, + { "America/North_Dakota/Beulah" , 0x011016 }, + { "America/North_Dakota/Center" , 0x0113AA }, + { "America/North_Dakota/New_Salem" , 0x01173E }, + { "America/Ojinaga" , 0x011AE7 }, + { "America/Panama" , 0x011D48 }, + { "America/Pangnirtung" , 0x011D9D }, + { "America/Paramaribo" , 0x0120D3 }, + { "America/Phoenix" , 0x012165 }, + { "America/Port-au-Prince" , 0x012213 }, + { "America/Port_of_Spain" , 0x01242E }, + { "America/Porto_Acre" , 0x01232F }, + { "America/Porto_Velho" , 0x012483 }, + { "America/Puerto_Rico" , 0x012579 }, + { "America/Rainy_River" , 0x0125E4 }, + { "America/Rankin_Inlet" , 0x01291C }, + { "America/Recife" , 0x012C02 }, + { "America/Regina" , 0x012D2C }, + { "America/Resolute" , 0x012EEA }, + { "America/Rio_Branco" , 0x0131DB }, + { "America/Rosario" , 0x0132DE }, + { "America/Santa_Isabel" , 0x013484 }, + { "America/Santarem" , 0x013827 }, + { "America/Santiago" , 0x01392C }, + { "America/Santo_Domingo" , 0x013CD5 }, + { "America/Sao_Paulo" , 0x013D9B }, + { "America/Scoresbysund" , 0x0140AA }, + { "America/Shiprock" , 0x014398 }, + { "America/Sitka" , 0x014727 }, + { "America/St_Barthelemy" , 0x014AAF }, + { "America/St_Johns" , 0x014B04 }, + { "America/St_Kitts" , 0x015057 }, + { "America/St_Lucia" , 0x0150AC }, + { "America/St_Thomas" , 0x015101 }, + { "America/St_Vincent" , 0x015156 }, + { "America/Swift_Current" , 0x0151AB }, + { "America/Tegucigalpa" , 0x0152CC }, + { "America/Thule" , 0x01534B }, + { "America/Thunder_Bay" , 0x015592 }, + { "America/Tijuana" , 0x0158DB }, + { "America/Toronto" , 0x015C74 }, + { "America/Tortola" , 0x01618B }, + { "America/Vancouver" , 0x0161E0 }, + { "America/Virgin" , 0x01661D }, + { "America/Whitehorse" , 0x016672 }, + { "America/Winnipeg" , 0x01698F }, + { "America/Yakutat" , 0x016DCF }, + { "America/Yellowknife" , 0x01713A }, + { "Antarctica/Casey" , 0x01744A }, + { "Antarctica/Davis" , 0x0174D5 }, + { "Antarctica/DumontDUrville" , 0x01756C }, + { "Antarctica/Macquarie" , 0x0175FE }, + { "Antarctica/Mawson" , 0x017878 }, + { "Antarctica/McMurdo" , 0x0178F4 }, + { "Antarctica/Palmer" , 0x017BF6 }, + { "Antarctica/Rothera" , 0x017F12 }, + { "Antarctica/South_Pole" , 0x017F88 }, + { "Antarctica/Syowa" , 0x018290 }, + { "Antarctica/Vostok" , 0x0182FE }, + { "Arctic/Longyearbyen" , 0x01836F }, + { "Asia/Aden" , 0x0186A1 }, + { "Asia/Almaty" , 0x0186F6 }, + { "Asia/Amman" , 0x018875 }, + { "Asia/Anadyr" , 0x018B35 }, + { "Asia/Aqtau" , 0x018D1A }, + { "Asia/Aqtobe" , 0x018F19 }, + { "Asia/Ashgabat" , 0x0190D1 }, + { "Asia/Ashkhabad" , 0x0191EE }, + { "Asia/Baghdad" , 0x01930B }, + { "Asia/Bahrain" , 0x019480 }, + { "Asia/Baku" , 0x0194E6 }, + { "Asia/Bangkok" , 0x0197CE }, + { "Asia/Beirut" , 0x019823 }, + { "Asia/Bishkek" , 0x019B30 }, + { "Asia/Brunei" , 0x019CDC }, + { "Asia/Calcutta" , 0x019D3E }, + { "Asia/Choibalsan" , 0x019DB7 }, + { "Asia/Chongqing" , 0x019F30 }, + { "Asia/Chungking" , 0x01A01F }, + { "Asia/Colombo" , 0x01A0CE }, + { "Asia/Dacca" , 0x01A16A }, + { "Asia/Damascus" , 0x01A210 }, + { "Asia/Dhaka" , 0x01A560 }, + { "Asia/Dili" , 0x01A606 }, + { "Asia/Dubai" , 0x01A68F }, + { "Asia/Dushanbe" , 0x01A6E4 }, + { "Asia/Gaza" , 0x01A7E7 }, + { "Asia/Harbin" , 0x01AB30 }, + { "Asia/Ho_Chi_Minh" , 0x01AC17 }, + { "Asia/Hong_Kong" , 0x01AC8F }, + { "Asia/Hovd" , 0x01AE51 }, + { "Asia/Irkutsk" , 0x01AFC9 }, + { "Asia/Istanbul" , 0x01B1AF }, + { "Asia/Jakarta" , 0x01B59C }, + { "Asia/Jayapura" , 0x01B646 }, + { "Asia/Jerusalem" , 0x01B6E2 }, + { "Asia/Kabul" , 0x01BA11 }, + { "Asia/Kamchatka" , 0x01BA62 }, + { "Asia/Karachi" , 0x01BC3E }, + { "Asia/Kashgar" , 0x01BCF3 }, + { "Asia/Kathmandu" , 0x01BDC4 }, + { "Asia/Katmandu" , 0x01BE2A }, + { "Asia/Kolkata" , 0x01BE90 }, + { "Asia/Krasnoyarsk" , 0x01BF09 }, + { "Asia/Kuala_Lumpur" , 0x01C0F1 }, + { "Asia/Kuching" , 0x01C1AE }, + { "Asia/Kuwait" , 0x01C29C }, + { "Asia/Macao" , 0x01C2F1 }, + { "Asia/Macau" , 0x01C42C }, + { "Asia/Magadan" , 0x01C567 }, + { "Asia/Makassar" , 0x01C749 }, + { "Asia/Manila" , 0x01C80D }, + { "Asia/Muscat" , 0x01C892 }, + { "Asia/Nicosia" , 0x01C8E7 }, + { "Asia/Novokuznetsk" , 0x01CBCF }, + { "Asia/Novosibirsk" , 0x01CDD1 }, + { "Asia/Omsk" , 0x01CFBC }, + { "Asia/Oral" , 0x01D1A3 }, + { "Asia/Phnom_Penh" , 0x01D373 }, + { "Asia/Pontianak" , 0x01D3EB }, + { "Asia/Pyongyang" , 0x01D4AC }, + { "Asia/Qatar" , 0x01D519 }, + { "Asia/Qyzylorda" , 0x01D57F }, + { "Asia/Rangoon" , 0x01D755 }, + { "Asia/Riyadh" , 0x01D7CD }, + { "Asia/Saigon" , 0x01D822 }, + { "Asia/Sakhalin" , 0x01D89A }, + { "Asia/Samarkand" , 0x01DA91 }, + { "Asia/Seoul" , 0x01DBC7 }, + { "Asia/Shanghai" , 0x01DC6B }, + { "Asia/Singapore" , 0x01DD4B }, + { "Asia/Taipei" , 0x01DE02 }, + { "Asia/Tashkent" , 0x01DF1A }, + { "Asia/Tbilisi" , 0x01E04B }, + { "Asia/Tehran" , 0x01E205 }, + { "Asia/Tel_Aviv" , 0x01E473 }, + { "Asia/Thimbu" , 0x01E7A2 }, + { "Asia/Thimphu" , 0x01E808 }, + { "Asia/Tokyo" , 0x01E86E }, + { "Asia/Ujung_Pandang" , 0x01E8F7 }, + { "Asia/Ulaanbaatar" , 0x01E973 }, + { "Asia/Ulan_Bator" , 0x01EACE }, + { "Asia/Urumqi" , 0x01EC1B }, + { "Asia/Vientiane" , 0x01ECE2 }, + { "Asia/Vladivostok" , 0x01ED5A }, + { "Asia/Yakutsk" , 0x01EF46 }, + { "Asia/Yekaterinburg" , 0x01F12B }, + { "Asia/Yerevan" , 0x01F336 }, + { "Atlantic/Azores" , 0x01F63A }, + { "Atlantic/Bermuda" , 0x01FB3D }, + { "Atlantic/Canary" , 0x01FE1E }, + { "Atlantic/Cape_Verde" , 0x0200F4 }, + { "Atlantic/Faeroe" , 0x02016D }, + { "Atlantic/Faroe" , 0x020411 }, + { "Atlantic/Jan_Mayen" , 0x0206B5 }, + { "Atlantic/Madeira" , 0x0209E7 }, + { "Atlantic/Reykjavik" , 0x020EF0 }, + { "Atlantic/South_Georgia" , 0x0210A9 }, + { "Atlantic/St_Helena" , 0x0213B7 }, + { "Atlantic/Stanley" , 0x0210ED }, + { "Australia/ACT" , 0x02140C }, + { "Australia/Adelaide" , 0x021729 }, + { "Australia/Brisbane" , 0x021A55 }, + { "Australia/Broken_Hill" , 0x021B1C }, + { "Australia/Canberra" , 0x021E5A }, + { "Australia/Currie" , 0x022177 }, + { "Australia/Darwin" , 0x0224AA }, + { "Australia/Eucla" , 0x022530 }, + { "Australia/Hobart" , 0x022605 }, + { "Australia/LHI" , 0x022963 }, + { "Australia/Lindeman" , 0x022BFE }, + { "Australia/Lord_Howe" , 0x022CDF }, + { "Australia/Melbourne" , 0x022F8A }, + { "Australia/North" , 0x0232AF }, + { "Australia/NSW" , 0x023323 }, + { "Australia/Perth" , 0x023640 }, + { "Australia/Queensland" , 0x023718 }, + { "Australia/South" , 0x0237C4 }, + { "Australia/Sydney" , 0x023AE1 }, + { "Australia/Tasmania" , 0x023E1E }, + { "Australia/Victoria" , 0x024163 }, + { "Australia/West" , 0x024480 }, + { "Australia/Yancowinna" , 0x024536 }, + { "Brazil/Acre" , 0x024858 }, + { "Brazil/DeNoronha" , 0x024957 }, + { "Brazil/East" , 0x024A77 }, + { "Brazil/West" , 0x024D54 }, + { "Canada/Atlantic" , 0x024E4C }, + { "Canada/Central" , 0x025334 }, + { "Canada/East-Saskatchewan" , 0x025C3E }, + { "Canada/Eastern" , 0x02574E }, + { "Canada/Mountain" , 0x025DC7 }, + { "Canada/Newfoundland" , 0x02613D }, + { "Canada/Pacific" , 0x026668 }, + { "Canada/Saskatchewan" , 0x026A81 }, + { "Canada/Yukon" , 0x026C0A }, + { "CET" , 0x026F0D }, + { "Chile/Continental" , 0x027216 }, + { "Chile/EasterIsland" , 0x0275B1 }, + { "CST6CDT" , 0x0278F3 }, + { "Cuba" , 0x027C44 }, + { "EET" , 0x027FB7 }, + { "Egypt" , 0x02826A }, + { "Eire" , 0x02852D }, + { "EST" , 0x028A3E }, + { "EST5EDT" , 0x028A82 }, + { "Etc/GMT" , 0x028DD3 }, + { "Etc/GMT+0" , 0x028E9F }, + { "Etc/GMT+1" , 0x028F29 }, + { "Etc/GMT+10" , 0x028FB6 }, + { "Etc/GMT+11" , 0x029044 }, + { "Etc/GMT+12" , 0x0290D2 }, + { "Etc/GMT+2" , 0x0291ED }, + { "Etc/GMT+3" , 0x029279 }, + { "Etc/GMT+4" , 0x029305 }, + { "Etc/GMT+5" , 0x029391 }, + { "Etc/GMT+6" , 0x02941D }, + { "Etc/GMT+7" , 0x0294A9 }, + { "Etc/GMT+8" , 0x029535 }, + { "Etc/GMT+9" , 0x0295C1 }, + { "Etc/GMT-0" , 0x028E5B }, + { "Etc/GMT-1" , 0x028EE3 }, + { "Etc/GMT-10" , 0x028F6F }, + { "Etc/GMT-11" , 0x028FFD }, + { "Etc/GMT-12" , 0x02908B }, + { "Etc/GMT-13" , 0x029119 }, + { "Etc/GMT-14" , 0x029160 }, + { "Etc/GMT-2" , 0x0291A7 }, + { "Etc/GMT-3" , 0x029233 }, + { "Etc/GMT-4" , 0x0292BF }, + { "Etc/GMT-5" , 0x02934B }, + { "Etc/GMT-6" , 0x0293D7 }, + { "Etc/GMT-7" , 0x029463 }, + { "Etc/GMT-8" , 0x0294EF }, + { "Etc/GMT-9" , 0x02957B }, + { "Etc/GMT0" , 0x028E17 }, + { "Etc/Greenwich" , 0x029607 }, + { "Etc/UCT" , 0x02964B }, + { "Etc/Universal" , 0x02968F }, + { "Etc/UTC" , 0x0296D3 }, + { "Etc/Zulu" , 0x029717 }, + { "Europe/Amsterdam" , 0x02975B }, + { "Europe/Andorra" , 0x029B99 }, + { "Europe/Athens" , 0x029E15 }, + { "Europe/Belfast" , 0x02A158 }, + { "Europe/Belgrade" , 0x02A68F }, + { "Europe/Berlin" , 0x02A958 }, + { "Europe/Bratislava" , 0x02ACAE }, + { "Europe/Brussels" , 0x02AFE0 }, + { "Europe/Bucharest" , 0x02B417 }, + { "Europe/Budapest" , 0x02B741 }, + { "Europe/Chisinau" , 0x02BAB4 }, + { "Europe/Copenhagen" , 0x02BE42 }, + { "Europe/Dublin" , 0x02C14C }, + { "Europe/Gibraltar" , 0x02C65D }, + { "Europe/Guernsey" , 0x02CAB4 }, + { "Europe/Helsinki" , 0x02CFEB }, + { "Europe/Isle_of_Man" , 0x02D2A1 }, + { "Europe/Istanbul" , 0x02D7D8 }, + { "Europe/Jersey" , 0x02DBC5 }, + { "Europe/Kaliningrad" , 0x02E0FC }, + { "Europe/Kiev" , 0x02E363 }, + { "Europe/Lisbon" , 0x02E67A }, + { "Europe/Ljubljana" , 0x02EB7E }, + { "Europe/London" , 0x02EE47 }, + { "Europe/Luxembourg" , 0x02F37E }, + { "Europe/Madrid" , 0x02F7D4 }, + { "Europe/Malta" , 0x02FB9A }, + { "Europe/Mariehamn" , 0x02FF53 }, + { "Europe/Minsk" , 0x030209 }, + { "Europe/Monaco" , 0x030514 }, + { "Europe/Moscow" , 0x03094F }, + { "Europe/Nicosia" , 0x030BA0 }, + { "Europe/Oslo" , 0x030E88 }, + { "Europe/Paris" , 0x0311BA }, + { "Europe/Podgorica" , 0x031600 }, + { "Europe/Prague" , 0x0318C9 }, + { "Europe/Riga" , 0x031BFB }, + { "Europe/Rome" , 0x031F40 }, + { "Europe/Samara" , 0x032303 }, + { "Europe/San_Marino" , 0x032533 }, + { "Europe/Sarajevo" , 0x0328F6 }, + { "Europe/Simferopol" , 0x032BBF }, + { "Europe/Skopje" , 0x032EEA }, + { "Europe/Sofia" , 0x0331B3 }, + { "Europe/Stockholm" , 0x0334BB }, + { "Europe/Tallinn" , 0x03376A }, + { "Europe/Tirane" , 0x033AA4 }, + { "Europe/Tiraspol" , 0x033DAA }, + { "Europe/Uzhgorod" , 0x034138 }, + { "Europe/Vaduz" , 0x03444F }, + { "Europe/Vatican" , 0x0346E2 }, + { "Europe/Vienna" , 0x034AA5 }, + { "Europe/Vilnius" , 0x034DD2 }, + { "Europe/Volgograd" , 0x035111 }, + { "Europe/Warsaw" , 0x035311 }, + { "Europe/Zagreb" , 0x0356F2 }, + { "Europe/Zaporozhye" , 0x0359BB }, + { "Europe/Zurich" , 0x035CFC }, + { "Factory" , 0x035FAB }, + { "GB" , 0x03601C }, + { "GB-Eire" , 0x036553 }, + { "GMT" , 0x036A8A }, + { "GMT+0" , 0x036B56 }, + { "GMT-0" , 0x036B12 }, + { "GMT0" , 0x036ACE }, + { "Greenwich" , 0x036B9A }, + { "Hongkong" , 0x036BDE }, + { "HST" , 0x036DA0 }, + { "Iceland" , 0x036DE4 }, + { "Indian/Antananarivo" , 0x036F9D }, + { "Indian/Chagos" , 0x037011 }, + { "Indian/Christmas" , 0x037073 }, + { "Indian/Cocos" , 0x0370B7 }, + { "Indian/Comoro" , 0x0370FB }, + { "Indian/Kerguelen" , 0x037150 }, + { "Indian/Mahe" , 0x0371A5 }, + { "Indian/Maldives" , 0x0371FA }, + { "Indian/Mauritius" , 0x03724F }, + { "Indian/Mayotte" , 0x0372C5 }, + { "Indian/Reunion" , 0x03731A }, + { "Iran" , 0x03736F }, + { "Israel" , 0x0375DD }, + { "Jamaica" , 0x03790C }, + { "Japan" , 0x0379D1 }, + { "Kwajalein" , 0x037A5A }, + { "Libya" , 0x037ABD }, + { "MET" , 0x037BB7 }, + { "Mexico/BajaNorte" , 0x037EC0 }, + { "Mexico/BajaSur" , 0x038229 }, + { "Mexico/General" , 0x03846E }, + { "MST" , 0x0386CC }, + { "MST7MDT" , 0x038710 }, + { "Navajo" , 0x038A61 }, + { "NZ" , 0x038DDA }, + { "NZ-CHAT" , 0x039158 }, + { "Pacific/Apia" , 0x039440 }, + { "Pacific/Auckland" , 0x0394CB }, + { "Pacific/Chatham" , 0x039857 }, + { "Pacific/Chuuk" , 0x039B4E }, + { "Pacific/Easter" , 0x039BA7 }, + { "Pacific/Efate" , 0x039F05 }, + { "Pacific/Enderbury" , 0x039FCB }, + { "Pacific/Fakaofo" , 0x03A039 }, + { "Pacific/Fiji" , 0x03A07D }, + { "Pacific/Funafuti" , 0x03A107 }, + { "Pacific/Galapagos" , 0x03A14B }, + { "Pacific/Gambier" , 0x03A1C3 }, + { "Pacific/Guadalcanal" , 0x03A228 }, + { "Pacific/Guam" , 0x03A27D }, + { "Pacific/Honolulu" , 0x03A2D3 }, + { "Pacific/Johnston" , 0x03A34A }, + { "Pacific/Kiritimati" , 0x03A39C }, + { "Pacific/Kosrae" , 0x03A407 }, + { "Pacific/Kwajalein" , 0x03A464 }, + { "Pacific/Majuro" , 0x03A4D0 }, + { "Pacific/Marquesas" , 0x03A52F }, + { "Pacific/Midway" , 0x03A596 }, + { "Pacific/Nauru" , 0x03A620 }, + { "Pacific/Niue" , 0x03A698 }, + { "Pacific/Norfolk" , 0x03A6F6 }, + { "Pacific/Noumea" , 0x03A74B }, + { "Pacific/Pago_Pago" , 0x03A7DB }, + { "Pacific/Palau" , 0x03A864 }, + { "Pacific/Pitcairn" , 0x03A8A8 }, + { "Pacific/Pohnpei" , 0x03A8FD }, + { "Pacific/Ponape" , 0x03A952 }, + { "Pacific/Port_Moresby" , 0x03A997 }, + { "Pacific/Rarotonga" , 0x03A9DB }, + { "Pacific/Saipan" , 0x03AAB7 }, + { "Pacific/Samoa" , 0x03AB1A }, + { "Pacific/Tahiti" , 0x03ABA3 }, + { "Pacific/Tarawa" , 0x03AC08 }, + { "Pacific/Tongatapu" , 0x03AC5C }, + { "Pacific/Truk" , 0x03ACE8 }, + { "Pacific/Wake" , 0x03AD2D }, + { "Pacific/Wallis" , 0x03AD7D }, + { "Pacific/Yap" , 0x03ADC1 }, + { "Poland" , 0x03AE06 }, + { "Portugal" , 0x03B1E7 }, + { "PRC" , 0x03B6E3 }, + { "PST8PDT" , 0x03B794 }, + { "ROC" , 0x03BAE5 }, + { "ROK" , 0x03BBFD }, + { "Singapore" , 0x03BCA1 }, + { "Turkey" , 0x03BD58 }, + { "UCT" , 0x03C145 }, + { "Universal" , 0x03C189 }, + { "US/Alaska" , 0x03C1CD }, + { "US/Aleutian" , 0x03C536 }, + { "US/Arizona" , 0x03C89C }, + { "US/Central" , 0x03C92A }, + { "US/East-Indiana" , 0x03D334 }, + { "US/Eastern" , 0x03CE35 }, + { "US/Hawaii" , 0x03D59E }, + { "US/Indiana-Starke" , 0x03D60F }, + { "US/Michigan" , 0x03D980 }, + { "US/Mountain" , 0x03DCB7 }, + { "US/Pacific" , 0x03E030 }, + { "US/Pacific-New" , 0x03E435 }, + { "US/Samoa" , 0x03E83A }, + { "UTC" , 0x03E8C3 }, + { "W-SU" , 0x03EBBA }, + { "WET" , 0x03E907 }, + { "Zulu" , 0x03EDF4 }, }; /* This is a generated file, do not modify */ -const unsigned char timelib_timezone_db_data_builtin[257855] = { +const unsigned char timelib_timezone_db_data_builtin[257592] = { /* Africa/Abidjan */ @@ -914,6 +915,26 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x00, 0x53, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x61, 0x46, 0x58, 0x01, 0x3D, 0x62, 0x00, 0x00, 0x00, 0x00, 0x00, +/* Africa/Juba */ +0x50, 0x48, 0x50, 0x31, 0x01, 0x53, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0xB6, 0xA3, 0xDA, 0xE0, +0x00, 0x9E, 0x17, 0xE0, 0x01, 0x7A, 0x34, 0x50, 0x02, 0x7D, 0xF9, 0xE0, 0x03, 0x5B, 0x67, 0xD0, +0x04, 0x60, 0x7E, 0xE0, 0x05, 0x3D, 0xEC, 0xD0, 0x06, 0x40, 0x60, 0xE0, 0x07, 0x1F, 0x20, 0x50, +0x08, 0x20, 0x42, 0xE0, 0x09, 0x00, 0x53, 0xD0, 0x0A, 0x00, 0x24, 0xE0, 0x0A, 0xE1, 0x87, 0x50, +0x0B, 0xE0, 0x06, 0xE0, 0x0C, 0xC4, 0x0C, 0x50, 0x0D, 0xBF, 0xE8, 0xE0, 0x0E, 0xA5, 0x3F, 0xD0, +0x0F, 0xA9, 0x05, 0x60, 0x10, 0x86, 0x73, 0x50, 0x11, 0x88, 0xE7, 0x60, 0x12, 0x67, 0xA6, 0xD0, +0x13, 0x68, 0xC9, 0x60, 0x14, 0x4A, 0x2B, 0xD0, 0x15, 0x48, 0xAB, 0x60, 0x16, 0x2B, 0x5F, 0x50, +0x17, 0x28, 0x8D, 0x60, 0x18, 0x0C, 0x92, 0xD0, 0x19, 0x08, 0x6F, 0x60, 0x19, 0xED, 0xC6, 0x50, +0x1A, 0xF1, 0x8B, 0xE0, 0x1B, 0xD0, 0x4B, 0x50, 0x1C, 0xD1, 0x6D, 0xE0, 0x1D, 0xB1, 0x7E, 0xD0, +0x38, 0x80, 0x45, 0x20, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, +0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, +0x02, 0x01, 0x02, 0x01, 0x02, 0x03, 0x00, 0x00, 0x1D, 0xA0, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, +0x01, 0x04, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x4C, 0x4D, +0x54, 0x00, 0x43, 0x41, 0x53, 0x54, 0x00, 0x43, 0x41, 0x54, 0x00, 0x45, 0x41, 0x54, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x90, 0xBA, 0xC8, 0x01, 0x42, 0xE0, 0x40, 0x00, +0x00, 0x00, 0x00, + /* Africa/Kampala */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x55, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, @@ -3160,20 +3181,20 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x42, 0x4F, 0x6A, 0x7C, 0x43, 0x64, 0x37, 0x6C, 0x44, 0x2F, 0x4C, 0x7C, 0x45, 0x44, 0x19, 0x6C, 0x45, 0xF3, 0x7E, 0xFC, 0x47, 0x2D, 0x35, 0xEC, 0x47, 0xD3, 0x60, 0xFC, 0x49, 0x0D, 0x17, 0xEC, 0x49, 0xB3, 0x42, 0xFC, 0x4A, 0xEC, 0xF9, 0xEC, 0x4B, 0x9C, 0x5F, 0x7C, 0x4C, 0xD6, 0x16, 0x6C, -0x4D, 0x7C, 0x41, 0x7C, 0x4E, 0xB5, 0xF8, 0x6C, 0x4F, 0x5C, 0x23, 0x7C, 0x50, 0x95, 0xDA, 0x6C, -0x51, 0x3C, 0x05, 0x7C, 0x52, 0x75, 0xBC, 0x6C, 0x53, 0x1B, 0xE7, 0x7C, 0x54, 0x55, 0x9E, 0x6C, -0x54, 0xFB, 0xC9, 0x7C, 0x56, 0x35, 0x80, 0x6C, 0x56, 0xE4, 0xE5, 0xFC, 0x58, 0x1E, 0x9C, 0xEC, -0x58, 0xC4, 0xC7, 0xFC, 0x59, 0xFE, 0x7E, 0xEC, 0x5A, 0xA4, 0xA9, 0xFC, 0x5B, 0xDE, 0x60, 0xEC, -0x5C, 0x84, 0x8B, 0xFC, 0x5D, 0xBE, 0x42, 0xEC, 0x5E, 0x64, 0x6D, 0xFC, 0x5F, 0x9E, 0x24, 0xEC, -0x60, 0x4D, 0x8A, 0x7C, 0x61, 0x87, 0x41, 0x6C, 0x62, 0x2D, 0x6C, 0x7C, 0x63, 0x67, 0x23, 0x6C, -0x64, 0x0D, 0x4E, 0x7C, 0x65, 0x47, 0x05, 0x6C, 0x65, 0xED, 0x30, 0x7C, 0x67, 0x26, 0xE7, 0x6C, -0x67, 0xCD, 0x12, 0x7C, 0x69, 0x06, 0xC9, 0x6C, 0x69, 0xAC, 0xF4, 0x7C, 0x6A, 0xE6, 0xAB, 0x6C, -0x6B, 0x96, 0x10, 0xFC, 0x6C, 0xCF, 0xC7, 0xEC, 0x6D, 0x75, 0xF2, 0xFC, 0x6E, 0xAF, 0xA9, 0xEC, -0x6F, 0x55, 0xD4, 0xFC, 0x70, 0x8F, 0x8B, 0xEC, 0x71, 0x35, 0xB6, 0xFC, 0x72, 0x6F, 0x6D, 0xEC, -0x73, 0x15, 0x98, 0xFC, 0x74, 0x4F, 0x4F, 0xEC, 0x74, 0xFE, 0xB5, 0x7C, 0x76, 0x38, 0x6C, 0x6C, -0x76, 0xDE, 0x97, 0x7C, 0x78, 0x18, 0x4E, 0x6C, 0x78, 0xBE, 0x79, 0x7C, 0x79, 0xF8, 0x30, 0x6C, -0x7A, 0x9E, 0x5B, 0x7C, 0x7B, 0xD8, 0x12, 0x6C, 0x7C, 0x7E, 0x3D, 0x7C, 0x7D, 0xB7, 0xF4, 0x6C, -0x7E, 0x5E, 0x1F, 0x7C, 0x7F, 0x97, 0xD6, 0x6C, 0x01, 0x00, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, +0x4D, 0x7C, 0x41, 0x7C, 0x4E, 0xB6, 0x14, 0x50, 0x4F, 0x5C, 0x3F, 0x60, 0x50, 0x95, 0xF6, 0x50, +0x51, 0x3C, 0x21, 0x60, 0x52, 0x75, 0xD8, 0x50, 0x53, 0x1C, 0x03, 0x60, 0x54, 0x55, 0xBA, 0x50, +0x54, 0xFB, 0xE5, 0x60, 0x56, 0x35, 0x9C, 0x50, 0x56, 0xE5, 0x01, 0xE0, 0x58, 0x1E, 0xB8, 0xD0, +0x58, 0xC4, 0xE3, 0xE0, 0x59, 0xFE, 0x9A, 0xD0, 0x5A, 0xA4, 0xC5, 0xE0, 0x5B, 0xDE, 0x7C, 0xD0, +0x5C, 0x84, 0xA7, 0xE0, 0x5D, 0xBE, 0x5E, 0xD0, 0x5E, 0x64, 0x89, 0xE0, 0x5F, 0x9E, 0x40, 0xD0, +0x60, 0x4D, 0xA6, 0x60, 0x61, 0x87, 0x5D, 0x50, 0x62, 0x2D, 0x88, 0x60, 0x63, 0x67, 0x3F, 0x50, +0x64, 0x0D, 0x6A, 0x60, 0x65, 0x47, 0x21, 0x50, 0x65, 0xED, 0x4C, 0x60, 0x67, 0x27, 0x03, 0x50, +0x67, 0xCD, 0x2E, 0x60, 0x69, 0x06, 0xE5, 0x50, 0x69, 0xAD, 0x10, 0x60, 0x6A, 0xE6, 0xC7, 0x50, +0x6B, 0x96, 0x2C, 0xE0, 0x6C, 0xCF, 0xE3, 0xD0, 0x6D, 0x76, 0x0E, 0xE0, 0x6E, 0xAF, 0xC5, 0xD0, +0x6F, 0x55, 0xF0, 0xE0, 0x70, 0x8F, 0xA7, 0xD0, 0x71, 0x35, 0xD2, 0xE0, 0x72, 0x6F, 0x89, 0xD0, +0x73, 0x15, 0xB4, 0xE0, 0x74, 0x4F, 0x6B, 0xD0, 0x74, 0xFE, 0xD1, 0x60, 0x76, 0x38, 0x88, 0x50, +0x76, 0xDE, 0xB3, 0x60, 0x78, 0x18, 0x6A, 0x50, 0x78, 0xBE, 0x95, 0x60, 0x79, 0xF8, 0x4C, 0x50, +0x7A, 0x9E, 0x77, 0x60, 0x7B, 0xD8, 0x2E, 0x50, 0x7C, 0x7E, 0x59, 0x60, 0x7D, 0xB8, 0x10, 0x50, +0x7E, 0x5E, 0x3B, 0x60, 0x7F, 0x97, 0xF2, 0x50, 0x01, 0x00, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x05, 0x04, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, @@ -4705,8 +4726,8 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { /* America/Metlakatla */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x55, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x8D, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x15, 0xCB, 0x89, 0x1A, 0xA0, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x21, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x15, 0xCB, 0x89, 0x1A, 0xA0, 0xD2, 0x23, 0xF4, 0x70, 0xD2, 0x61, 0x26, 0x10, 0xFE, 0xB8, 0x47, 0x20, 0xFF, 0xA8, 0x2A, 0x10, 0x00, 0x98, 0x29, 0x20, 0x01, 0x88, 0x0C, 0x10, 0x02, 0x78, 0x0B, 0x20, 0x03, 0x71, 0x28, 0x90, 0x04, 0x61, 0x27, 0xA0, 0x05, 0x51, 0x0A, 0x90, 0x06, 0x41, 0x09, 0xA0, 0x07, 0x30, 0xEC, 0x90, @@ -4715,49 +4736,15 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x0F, 0xA9, 0xAE, 0x20, 0x10, 0x99, 0x91, 0x10, 0x11, 0x89, 0x90, 0x20, 0x12, 0x79, 0x73, 0x10, 0x13, 0x69, 0x72, 0x20, 0x14, 0x59, 0x55, 0x10, 0x15, 0x49, 0x54, 0x20, 0x16, 0x39, 0x37, 0x10, 0x17, 0x29, 0x36, 0x20, 0x18, 0x22, 0x53, 0x90, 0x19, 0x09, 0x18, 0x20, 0x1A, 0x02, 0x35, 0x90, -0x1A, 0xF2, 0x34, 0xA0, 0x1B, 0xE2, 0x17, 0x90, 0x1C, 0xD2, 0x16, 0xA0, 0x1D, 0xC1, 0xF9, 0x90, -0x1E, 0xB1, 0xF8, 0xA0, 0x1F, 0xA1, 0xDB, 0x90, 0x20, 0x76, 0x2B, 0x20, 0x21, 0x81, 0xBD, 0x90, -0x22, 0x56, 0x0D, 0x20, 0x23, 0x6A, 0xDA, 0x10, 0x24, 0x35, 0xEF, 0x20, 0x25, 0x4A, 0xBC, 0x10, -0x26, 0x15, 0xD1, 0x20, 0x27, 0x2A, 0x9E, 0x10, 0x27, 0xFE, 0xED, 0xA0, 0x29, 0x0A, 0x80, 0x10, -0x29, 0xDE, 0xCF, 0xA0, 0x2A, 0xEA, 0x62, 0x10, 0x2B, 0xBE, 0xB1, 0xA0, 0x2C, 0xD3, 0x7E, 0x90, -0x2D, 0x9E, 0x93, 0xA0, 0x2E, 0xB3, 0x60, 0x90, 0x2F, 0x7E, 0x75, 0xA0, 0x30, 0x93, 0x42, 0x90, -0x31, 0x67, 0x92, 0x20, 0x32, 0x73, 0x24, 0x90, 0x33, 0x47, 0x74, 0x20, 0x34, 0x53, 0x06, 0x90, -0x35, 0x27, 0x56, 0x20, 0x36, 0x32, 0xE8, 0x90, 0x37, 0x07, 0x38, 0x20, 0x38, 0x1C, 0x05, 0x10, -0x38, 0xE7, 0x1A, 0x20, 0x39, 0xFB, 0xE7, 0x10, 0x3A, 0xC6, 0xFC, 0x20, 0x3B, 0xDB, 0xC9, 0x10, -0x3C, 0xB0, 0x18, 0xA0, 0x3D, 0xBB, 0xAB, 0x10, 0x3E, 0x8F, 0xFA, 0xA0, 0x3F, 0x9B, 0x8D, 0x10, -0x40, 0x6F, 0xDC, 0xA0, 0x41, 0x84, 0xA9, 0x90, 0x42, 0x4F, 0xBE, 0xA0, 0x43, 0x64, 0x8B, 0x90, -0x44, 0x2F, 0xA0, 0xA0, 0x45, 0x44, 0x6D, 0x90, 0x45, 0xF3, 0xD3, 0x20, 0x47, 0x2D, 0x8A, 0x10, -0x47, 0xD3, 0xB5, 0x20, 0x49, 0x0D, 0x6C, 0x10, 0x49, 0xB3, 0x97, 0x20, 0x4A, 0xED, 0x4E, 0x10, -0x4B, 0x9C, 0xB3, 0xA0, 0x4C, 0xD6, 0x6A, 0x90, 0x4D, 0x7C, 0x95, 0xA0, 0x4E, 0xB6, 0x4C, 0x90, -0x4F, 0x5C, 0x77, 0xA0, 0x50, 0x96, 0x2E, 0x90, 0x51, 0x3C, 0x59, 0xA0, 0x52, 0x76, 0x10, 0x90, -0x53, 0x1C, 0x3B, 0xA0, 0x54, 0x55, 0xF2, 0x90, 0x54, 0xFC, 0x1D, 0xA0, 0x56, 0x35, 0xD4, 0x90, -0x56, 0xE5, 0x3A, 0x20, 0x58, 0x1E, 0xF1, 0x10, 0x58, 0xC5, 0x1C, 0x20, 0x59, 0xFE, 0xD3, 0x10, -0x5A, 0xA4, 0xFE, 0x20, 0x5B, 0xDE, 0xB5, 0x10, 0x5C, 0x84, 0xE0, 0x20, 0x5D, 0xBE, 0x97, 0x10, -0x5E, 0x64, 0xC2, 0x20, 0x5F, 0x9E, 0x79, 0x10, 0x60, 0x4D, 0xDE, 0xA0, 0x61, 0x87, 0x95, 0x90, -0x62, 0x2D, 0xC0, 0xA0, 0x63, 0x67, 0x77, 0x90, 0x64, 0x0D, 0xA2, 0xA0, 0x65, 0x47, 0x59, 0x90, -0x65, 0xED, 0x84, 0xA0, 0x67, 0x27, 0x3B, 0x90, 0x67, 0xCD, 0x66, 0xA0, 0x69, 0x07, 0x1D, 0x90, -0x69, 0xAD, 0x48, 0xA0, 0x6A, 0xE6, 0xFF, 0x90, 0x6B, 0x96, 0x65, 0x20, 0x6C, 0xD0, 0x1C, 0x10, -0x6D, 0x76, 0x47, 0x20, 0x6E, 0xAF, 0xFE, 0x10, 0x6F, 0x56, 0x29, 0x20, 0x70, 0x8F, 0xE0, 0x10, -0x71, 0x36, 0x0B, 0x20, 0x72, 0x6F, 0xC2, 0x10, 0x73, 0x15, 0xED, 0x20, 0x74, 0x4F, 0xA4, 0x10, -0x74, 0xFF, 0x09, 0xA0, 0x76, 0x38, 0xC0, 0x90, 0x76, 0xDE, 0xEB, 0xA0, 0x78, 0x18, 0xA2, 0x90, -0x78, 0xBE, 0xCD, 0xA0, 0x79, 0xF8, 0x84, 0x90, 0x7A, 0x9E, 0xAF, 0xA0, 0x7B, 0xD8, 0x66, 0x90, -0x7C, 0x7E, 0x91, 0xA0, 0x7D, 0xB8, 0x48, 0x90, 0x7E, 0x5E, 0x73, 0xA0, 0x7F, 0x98, 0x2A, 0x90, 0x01, 0x02, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0xFF, 0xFF, 0x8F, -0x80, 0x00, 0x00, 0xFF, 0xFF, 0x9D, 0x90, 0x01, 0x04, 0xFF, 0xFF, 0x9D, 0x90, 0x01, 0x08, 0xFF, -0xFF, 0x9D, 0x90, 0x01, 0x0C, 0xFF, 0xFF, 0x8F, 0x80, 0x00, 0x10, 0xFF, 0xFF, 0x9D, 0x90, 0x01, -0x10, 0x50, 0x53, 0x54, 0x00, 0x50, 0x57, 0x54, 0x00, 0x50, 0x50, 0x54, 0x00, 0x50, 0x44, 0x54, -0x00, 0x4D, 0x65, 0x53, 0x54, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, -0x00, 0x00, 0x00, 0xDD, 0x72, 0x36, 0x00, 0x49, 0xE3, 0x79, 0x00, 0x00, 0x00, 0x20, 0x4D, 0x65, -0x74, 0x6C, 0x61, 0x6B, 0x61, 0x74, 0x6C, 0x61, 0x20, 0x54, 0x69, 0x6D, 0x65, 0x20, 0x2D, 0x20, -0x41, 0x6E, 0x6E, 0x65, 0x74, 0x74, 0x65, 0x20, 0x49, 0x73, 0x6C, 0x61, 0x6E, 0x64, +0x04, 0xFF, 0xFF, 0x8F, 0x80, 0x00, 0x00, 0xFF, 0xFF, 0x9D, 0x90, 0x01, 0x04, 0xFF, 0xFF, 0x9D, +0x90, 0x01, 0x08, 0xFF, 0xFF, 0x9D, 0x90, 0x01, 0x0C, 0xFF, 0xFF, 0x8F, 0x80, 0x00, 0x10, 0x50, +0x53, 0x54, 0x00, 0x50, 0x57, 0x54, 0x00, 0x50, 0x50, 0x54, 0x00, 0x50, 0x44, 0x54, 0x00, 0x4D, +0x65, 0x53, 0x54, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xDD, +0x72, 0x36, 0x00, 0x49, 0xE3, 0x79, 0x00, 0x00, 0x00, 0x20, 0x4D, 0x65, 0x74, 0x6C, 0x61, 0x6B, +0x61, 0x74, 0x6C, 0x61, 0x20, 0x54, 0x69, 0x6D, 0x65, 0x20, 0x2D, 0x20, 0x41, 0x6E, 0x6E, 0x65, +0x74, 0x74, 0x65, 0x20, 0x49, 0x73, 0x6C, 0x61, 0x6E, 0x64, /* America/Mexico_City */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x4D, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -5916,8 +5903,8 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { /* America/Resolute */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x43, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x77, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x15, 0xD5, 0xFB, 0x81, 0x80, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x77, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x15, 0xD5, 0xFB, 0x81, 0x80, 0xF7, 0x2F, 0x4C, 0x60, 0xF8, 0x28, 0x77, 0xE0, 0x13, 0x69, 0x56, 0x00, 0x14, 0x59, 0x38, 0xF0, 0x15, 0x49, 0x38, 0x00, 0x16, 0x39, 0x1A, 0xF0, 0x17, 0x29, 0x1A, 0x00, 0x18, 0x22, 0x37, 0x70, 0x19, 0x08, 0xFC, 0x00, 0x1A, 0x02, 0x19, 0x70, 0x1A, 0xF2, 0x18, 0x80, 0x1B, 0xE1, 0xFB, 0x70, @@ -5932,37 +5919,37 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x3A, 0xC6, 0xE0, 0x00, 0x3B, 0xDB, 0xAC, 0xF0, 0x3C, 0xAF, 0xFC, 0x80, 0x3D, 0xBB, 0x8E, 0xF0, 0x3E, 0x8F, 0xDE, 0x80, 0x3F, 0x9B, 0x70, 0xF0, 0x40, 0x6F, 0xC0, 0x80, 0x41, 0x84, 0x8D, 0x70, 0x42, 0x4F, 0xA2, 0x80, 0x43, 0x64, 0x6F, 0x70, 0x44, 0x2F, 0x84, 0x80, 0x45, 0x44, 0x51, 0x70, -0x45, 0xF3, 0xA8, 0xF0, 0x47, 0x2D, 0x6D, 0xF0, 0x47, 0xD3, 0x8A, 0xF0, 0x49, 0x0D, 0x4F, 0xF0, -0x49, 0xB3, 0x6C, 0xF0, 0x4A, 0xED, 0x31, 0xF0, 0x4B, 0x9C, 0x89, 0x70, 0x4C, 0xD6, 0x4E, 0x70, -0x4D, 0x7C, 0x6B, 0x70, 0x4E, 0xB6, 0x30, 0x70, 0x4F, 0x5C, 0x4D, 0x70, 0x50, 0x96, 0x12, 0x70, -0x51, 0x3C, 0x2F, 0x70, 0x52, 0x75, 0xF4, 0x70, 0x53, 0x1C, 0x11, 0x70, 0x54, 0x55, 0xD6, 0x70, -0x54, 0xFB, 0xF3, 0x70, 0x56, 0x35, 0xB8, 0x70, 0x56, 0xE5, 0x0F, 0xF0, 0x58, 0x1E, 0xD4, 0xF0, -0x58, 0xC4, 0xF1, 0xF0, 0x59, 0xFE, 0xB6, 0xF0, 0x5A, 0xA4, 0xD3, 0xF0, 0x5B, 0xDE, 0x98, 0xF0, -0x5C, 0x84, 0xB5, 0xF0, 0x5D, 0xBE, 0x7A, 0xF0, 0x5E, 0x64, 0x97, 0xF0, 0x5F, 0x9E, 0x5C, 0xF0, -0x60, 0x4D, 0xB4, 0x70, 0x61, 0x87, 0x79, 0x70, 0x62, 0x2D, 0x96, 0x70, 0x63, 0x67, 0x5B, 0x70, -0x64, 0x0D, 0x78, 0x70, 0x65, 0x47, 0x3D, 0x70, 0x65, 0xED, 0x5A, 0x70, 0x67, 0x27, 0x1F, 0x70, -0x67, 0xCD, 0x3C, 0x70, 0x69, 0x07, 0x01, 0x70, 0x69, 0xAD, 0x1E, 0x70, 0x6A, 0xE6, 0xE3, 0x70, -0x6B, 0x96, 0x3A, 0xF0, 0x6C, 0xCF, 0xFF, 0xF0, 0x6D, 0x76, 0x1C, 0xF0, 0x6E, 0xAF, 0xE1, 0xF0, -0x6F, 0x55, 0xFE, 0xF0, 0x70, 0x8F, 0xC3, 0xF0, 0x71, 0x35, 0xE0, 0xF0, 0x72, 0x6F, 0xA5, 0xF0, -0x73, 0x15, 0xC2, 0xF0, 0x74, 0x4F, 0x87, 0xF0, 0x74, 0xFE, 0xDF, 0x70, 0x76, 0x38, 0xA4, 0x70, -0x76, 0xDE, 0xC1, 0x70, 0x78, 0x18, 0x86, 0x70, 0x78, 0xBE, 0xA3, 0x70, 0x79, 0xF8, 0x68, 0x70, -0x7A, 0x9E, 0x85, 0x70, 0x7B, 0xD8, 0x4A, 0x70, 0x7C, 0x7E, 0x67, 0x70, 0x7D, 0xB8, 0x2C, 0x70, -0x7E, 0x5E, 0x49, 0x70, 0x7F, 0x98, 0x0E, 0x70, 0x02, 0x01, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, +0x45, 0xF3, 0xB7, 0x00, 0x47, 0x2D, 0x6D, 0xF0, 0x47, 0xD3, 0x99, 0x00, 0x49, 0x0D, 0x4F, 0xF0, +0x49, 0xB3, 0x7B, 0x00, 0x4A, 0xED, 0x31, 0xF0, 0x4B, 0x9C, 0x97, 0x80, 0x4C, 0xD6, 0x4E, 0x70, +0x4D, 0x7C, 0x79, 0x80, 0x4E, 0xB6, 0x30, 0x70, 0x4F, 0x5C, 0x5B, 0x80, 0x50, 0x96, 0x12, 0x70, +0x51, 0x3C, 0x3D, 0x80, 0x52, 0x75, 0xF4, 0x70, 0x53, 0x1C, 0x1F, 0x80, 0x54, 0x55, 0xD6, 0x70, +0x54, 0xFC, 0x01, 0x80, 0x56, 0x35, 0xB8, 0x70, 0x56, 0xE5, 0x1E, 0x00, 0x58, 0x1E, 0xD4, 0xF0, +0x58, 0xC5, 0x00, 0x00, 0x59, 0xFE, 0xB6, 0xF0, 0x5A, 0xA4, 0xE2, 0x00, 0x5B, 0xDE, 0x98, 0xF0, +0x5C, 0x84, 0xC4, 0x00, 0x5D, 0xBE, 0x7A, 0xF0, 0x5E, 0x64, 0xA6, 0x00, 0x5F, 0x9E, 0x5C, 0xF0, +0x60, 0x4D, 0xC2, 0x80, 0x61, 0x87, 0x79, 0x70, 0x62, 0x2D, 0xA4, 0x80, 0x63, 0x67, 0x5B, 0x70, +0x64, 0x0D, 0x86, 0x80, 0x65, 0x47, 0x3D, 0x70, 0x65, 0xED, 0x68, 0x80, 0x67, 0x27, 0x1F, 0x70, +0x67, 0xCD, 0x4A, 0x80, 0x69, 0x07, 0x01, 0x70, 0x69, 0xAD, 0x2C, 0x80, 0x6A, 0xE6, 0xE3, 0x70, +0x6B, 0x96, 0x49, 0x00, 0x6C, 0xCF, 0xFF, 0xF0, 0x6D, 0x76, 0x2B, 0x00, 0x6E, 0xAF, 0xE1, 0xF0, +0x6F, 0x56, 0x0D, 0x00, 0x70, 0x8F, 0xC3, 0xF0, 0x71, 0x35, 0xEF, 0x00, 0x72, 0x6F, 0xA5, 0xF0, +0x73, 0x15, 0xD1, 0x00, 0x74, 0x4F, 0x87, 0xF0, 0x74, 0xFE, 0xED, 0x80, 0x76, 0x38, 0xA4, 0x70, +0x76, 0xDE, 0xCF, 0x80, 0x78, 0x18, 0x86, 0x70, 0x78, 0xBE, 0xB1, 0x80, 0x79, 0xF8, 0x68, 0x70, +0x7A, 0x9E, 0x93, 0x80, 0x7B, 0xD8, 0x4A, 0x70, 0x7C, 0x7E, 0x75, 0x80, 0x7D, 0xB8, 0x2C, 0x70, +0x7E, 0x5E, 0x57, 0x80, 0x7F, 0x98, 0x0E, 0x70, 0x02, 0x01, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x04, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, -0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x00, +0x04, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, +0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x01, 0x04, 0xFF, 0xFF, 0xAB, 0xA0, 0x00, -0x09, 0xFF, 0xFF, 0xB9, 0xB0, 0x01, 0x0D, 0xFF, 0xFF, 0xB9, 0xB0, 0x00, 0x11, 0xFF, 0xFF, 0xB9, -0xB0, 0x00, 0x0D, 0x7A, 0x7A, 0x7A, 0x00, 0x43, 0x44, 0x44, 0x54, 0x00, 0x43, 0x53, 0x54, 0x00, -0x43, 0x44, 0x54, 0x00, 0x45, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0xFB, 0x4E, 0x33, 0x00, 0x81, 0xF5, 0xDB, 0x00, 0x00, 0x00, 0x29, -0x45, 0x61, 0x73, 0x74, 0x65, 0x72, 0x6E, 0x20, 0x53, 0x74, 0x61, 0x6E, 0x64, 0x61, 0x72, 0x64, -0x20, 0x54, 0x69, 0x6D, 0x65, 0x20, 0x2D, 0x20, 0x52, 0x65, 0x73, 0x6F, 0x6C, 0x75, 0x74, 0x65, -0x2C, 0x20, 0x4E, 0x75, 0x6E, 0x61, 0x76, 0x75, 0x74, +0x09, 0xFF, 0xFF, 0xB9, 0xB0, 0x01, 0x0D, 0xFF, 0xFF, 0xB9, 0xB0, 0x00, 0x11, 0x7A, 0x7A, 0x7A, +0x00, 0x43, 0x44, 0x44, 0x54, 0x00, 0x43, 0x53, 0x54, 0x00, 0x43, 0x44, 0x54, 0x00, 0x45, 0x53, +0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFB, 0x4E, 0x33, +0x00, 0x81, 0xF5, 0xDB, 0x00, 0x00, 0x00, 0x29, 0x43, 0x65, 0x6E, 0x74, 0x72, 0x61, 0x6C, 0x20, +0x53, 0x74, 0x61, 0x6E, 0x64, 0x61, 0x72, 0x64, 0x20, 0x54, 0x69, 0x6D, 0x65, 0x20, 0x2D, 0x20, +0x52, 0x65, 0x73, 0x6F, 0x6C, 0x75, 0x74, 0x65, 0x2C, 0x20, 0x4E, 0x75, 0x6E, 0x61, 0x76, 0x75, +0x74, /* America/Rio_Branco */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -6444,20 +6431,20 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x43, 0x64, 0x30, 0x64, 0x44, 0x2F, 0x45, 0x74, 0x45, 0x44, 0x12, 0x64, 0x45, 0xF3, 0x77, 0xF4, 0x47, 0x2D, 0x2E, 0xE4, 0x47, 0xD3, 0x59, 0xF4, 0x49, 0x0D, 0x10, 0xE4, 0x49, 0xB3, 0x3B, 0xF4, 0x4A, 0xEC, 0xF2, 0xE4, 0x4B, 0x9C, 0x58, 0x74, 0x4C, 0xD6, 0x0F, 0x64, 0x4D, 0x7C, 0x3A, 0x74, -0x4E, 0xB5, 0xF1, 0x64, 0x4F, 0x5C, 0x1C, 0x74, 0x50, 0x95, 0xD3, 0x64, 0x51, 0x3B, 0xFE, 0x74, -0x52, 0x75, 0xB5, 0x64, 0x53, 0x1B, 0xE0, 0x74, 0x54, 0x55, 0x97, 0x64, 0x54, 0xFB, 0xC2, 0x74, -0x56, 0x35, 0x79, 0x64, 0x56, 0xE4, 0xDE, 0xF4, 0x58, 0x1E, 0x95, 0xE4, 0x58, 0xC4, 0xC0, 0xF4, -0x59, 0xFE, 0x77, 0xE4, 0x5A, 0xA4, 0xA2, 0xF4, 0x5B, 0xDE, 0x59, 0xE4, 0x5C, 0x84, 0x84, 0xF4, -0x5D, 0xBE, 0x3B, 0xE4, 0x5E, 0x64, 0x66, 0xF4, 0x5F, 0x9E, 0x1D, 0xE4, 0x60, 0x4D, 0x83, 0x74, -0x61, 0x87, 0x3A, 0x64, 0x62, 0x2D, 0x65, 0x74, 0x63, 0x67, 0x1C, 0x64, 0x64, 0x0D, 0x47, 0x74, -0x65, 0x46, 0xFE, 0x64, 0x65, 0xED, 0x29, 0x74, 0x67, 0x26, 0xE0, 0x64, 0x67, 0xCD, 0x0B, 0x74, -0x69, 0x06, 0xC2, 0x64, 0x69, 0xAC, 0xED, 0x74, 0x6A, 0xE6, 0xA4, 0x64, 0x6B, 0x96, 0x09, 0xF4, -0x6C, 0xCF, 0xC0, 0xE4, 0x6D, 0x75, 0xEB, 0xF4, 0x6E, 0xAF, 0xA2, 0xE4, 0x6F, 0x55, 0xCD, 0xF4, -0x70, 0x8F, 0x84, 0xE4, 0x71, 0x35, 0xAF, 0xF4, 0x72, 0x6F, 0x66, 0xE4, 0x73, 0x15, 0x91, 0xF4, -0x74, 0x4F, 0x48, 0xE4, 0x74, 0xFE, 0xAE, 0x74, 0x76, 0x38, 0x65, 0x64, 0x76, 0xDE, 0x90, 0x74, -0x78, 0x18, 0x47, 0x64, 0x78, 0xBE, 0x72, 0x74, 0x79, 0xF8, 0x29, 0x64, 0x7A, 0x9E, 0x54, 0x74, -0x7B, 0xD8, 0x0B, 0x64, 0x7C, 0x7E, 0x36, 0x74, 0x7D, 0xB7, 0xED, 0x64, 0x7E, 0x5E, 0x18, 0x74, -0x7F, 0x97, 0xCF, 0x64, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, +0x4E, 0xB6, 0x0D, 0x48, 0x4F, 0x5C, 0x38, 0x58, 0x50, 0x95, 0xEF, 0x48, 0x51, 0x3C, 0x1A, 0x58, +0x52, 0x75, 0xD1, 0x48, 0x53, 0x1B, 0xFC, 0x58, 0x54, 0x55, 0xB3, 0x48, 0x54, 0xFB, 0xDE, 0x58, +0x56, 0x35, 0x95, 0x48, 0x56, 0xE4, 0xFA, 0xD8, 0x58, 0x1E, 0xB1, 0xC8, 0x58, 0xC4, 0xDC, 0xD8, +0x59, 0xFE, 0x93, 0xC8, 0x5A, 0xA4, 0xBE, 0xD8, 0x5B, 0xDE, 0x75, 0xC8, 0x5C, 0x84, 0xA0, 0xD8, +0x5D, 0xBE, 0x57, 0xC8, 0x5E, 0x64, 0x82, 0xD8, 0x5F, 0x9E, 0x39, 0xC8, 0x60, 0x4D, 0x9F, 0x58, +0x61, 0x87, 0x56, 0x48, 0x62, 0x2D, 0x81, 0x58, 0x63, 0x67, 0x38, 0x48, 0x64, 0x0D, 0x63, 0x58, +0x65, 0x47, 0x1A, 0x48, 0x65, 0xED, 0x45, 0x58, 0x67, 0x26, 0xFC, 0x48, 0x67, 0xCD, 0x27, 0x58, +0x69, 0x06, 0xDE, 0x48, 0x69, 0xAD, 0x09, 0x58, 0x6A, 0xE6, 0xC0, 0x48, 0x6B, 0x96, 0x25, 0xD8, +0x6C, 0xCF, 0xDC, 0xC8, 0x6D, 0x76, 0x07, 0xD8, 0x6E, 0xAF, 0xBE, 0xC8, 0x6F, 0x55, 0xE9, 0xD8, +0x70, 0x8F, 0xA0, 0xC8, 0x71, 0x35, 0xCB, 0xD8, 0x72, 0x6F, 0x82, 0xC8, 0x73, 0x15, 0xAD, 0xD8, +0x74, 0x4F, 0x64, 0xC8, 0x74, 0xFE, 0xCA, 0x58, 0x76, 0x38, 0x81, 0x48, 0x76, 0xDE, 0xAC, 0x58, +0x78, 0x18, 0x63, 0x48, 0x78, 0xBE, 0x8E, 0x58, 0x79, 0xF8, 0x45, 0x48, 0x7A, 0x9E, 0x70, 0x58, +0x7B, 0xD8, 0x27, 0x48, 0x7C, 0x7E, 0x52, 0x58, 0x7D, 0xB8, 0x09, 0x48, 0x7E, 0x5E, 0x34, 0x58, +0x7F, 0x97, 0xEB, 0x48, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x05, 0x04, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, @@ -11305,20 +11292,20 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x43, 0x64, 0x30, 0x64, 0x44, 0x2F, 0x45, 0x74, 0x45, 0x44, 0x12, 0x64, 0x45, 0xF3, 0x77, 0xF4, 0x47, 0x2D, 0x2E, 0xE4, 0x47, 0xD3, 0x59, 0xF4, 0x49, 0x0D, 0x10, 0xE4, 0x49, 0xB3, 0x3B, 0xF4, 0x4A, 0xEC, 0xF2, 0xE4, 0x4B, 0x9C, 0x58, 0x74, 0x4C, 0xD6, 0x0F, 0x64, 0x4D, 0x7C, 0x3A, 0x74, -0x4E, 0xB5, 0xF1, 0x64, 0x4F, 0x5C, 0x1C, 0x74, 0x50, 0x95, 0xD3, 0x64, 0x51, 0x3B, 0xFE, 0x74, -0x52, 0x75, 0xB5, 0x64, 0x53, 0x1B, 0xE0, 0x74, 0x54, 0x55, 0x97, 0x64, 0x54, 0xFB, 0xC2, 0x74, -0x56, 0x35, 0x79, 0x64, 0x56, 0xE4, 0xDE, 0xF4, 0x58, 0x1E, 0x95, 0xE4, 0x58, 0xC4, 0xC0, 0xF4, -0x59, 0xFE, 0x77, 0xE4, 0x5A, 0xA4, 0xA2, 0xF4, 0x5B, 0xDE, 0x59, 0xE4, 0x5C, 0x84, 0x84, 0xF4, -0x5D, 0xBE, 0x3B, 0xE4, 0x5E, 0x64, 0x66, 0xF4, 0x5F, 0x9E, 0x1D, 0xE4, 0x60, 0x4D, 0x83, 0x74, -0x61, 0x87, 0x3A, 0x64, 0x62, 0x2D, 0x65, 0x74, 0x63, 0x67, 0x1C, 0x64, 0x64, 0x0D, 0x47, 0x74, -0x65, 0x46, 0xFE, 0x64, 0x65, 0xED, 0x29, 0x74, 0x67, 0x26, 0xE0, 0x64, 0x67, 0xCD, 0x0B, 0x74, -0x69, 0x06, 0xC2, 0x64, 0x69, 0xAC, 0xED, 0x74, 0x6A, 0xE6, 0xA4, 0x64, 0x6B, 0x96, 0x09, 0xF4, -0x6C, 0xCF, 0xC0, 0xE4, 0x6D, 0x75, 0xEB, 0xF4, 0x6E, 0xAF, 0xA2, 0xE4, 0x6F, 0x55, 0xCD, 0xF4, -0x70, 0x8F, 0x84, 0xE4, 0x71, 0x35, 0xAF, 0xF4, 0x72, 0x6F, 0x66, 0xE4, 0x73, 0x15, 0x91, 0xF4, -0x74, 0x4F, 0x48, 0xE4, 0x74, 0xFE, 0xAE, 0x74, 0x76, 0x38, 0x65, 0x64, 0x76, 0xDE, 0x90, 0x74, -0x78, 0x18, 0x47, 0x64, 0x78, 0xBE, 0x72, 0x74, 0x79, 0xF8, 0x29, 0x64, 0x7A, 0x9E, 0x54, 0x74, -0x7B, 0xD8, 0x0B, 0x64, 0x7C, 0x7E, 0x36, 0x74, 0x7D, 0xB7, 0xED, 0x64, 0x7E, 0x5E, 0x18, 0x74, -0x7F, 0x97, 0xCF, 0x64, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, +0x4E, 0xB6, 0x0D, 0x48, 0x4F, 0x5C, 0x38, 0x58, 0x50, 0x95, 0xEF, 0x48, 0x51, 0x3C, 0x1A, 0x58, +0x52, 0x75, 0xD1, 0x48, 0x53, 0x1B, 0xFC, 0x58, 0x54, 0x55, 0xB3, 0x48, 0x54, 0xFB, 0xDE, 0x58, +0x56, 0x35, 0x95, 0x48, 0x56, 0xE4, 0xFA, 0xD8, 0x58, 0x1E, 0xB1, 0xC8, 0x58, 0xC4, 0xDC, 0xD8, +0x59, 0xFE, 0x93, 0xC8, 0x5A, 0xA4, 0xBE, 0xD8, 0x5B, 0xDE, 0x75, 0xC8, 0x5C, 0x84, 0xA0, 0xD8, +0x5D, 0xBE, 0x57, 0xC8, 0x5E, 0x64, 0x82, 0xD8, 0x5F, 0x9E, 0x39, 0xC8, 0x60, 0x4D, 0x9F, 0x58, +0x61, 0x87, 0x56, 0x48, 0x62, 0x2D, 0x81, 0x58, 0x63, 0x67, 0x38, 0x48, 0x64, 0x0D, 0x63, 0x58, +0x65, 0x47, 0x1A, 0x48, 0x65, 0xED, 0x45, 0x58, 0x67, 0x26, 0xFC, 0x48, 0x67, 0xCD, 0x27, 0x58, +0x69, 0x06, 0xDE, 0x48, 0x69, 0xAD, 0x09, 0x58, 0x6A, 0xE6, 0xC0, 0x48, 0x6B, 0x96, 0x25, 0xD8, +0x6C, 0xCF, 0xDC, 0xC8, 0x6D, 0x76, 0x07, 0xD8, 0x6E, 0xAF, 0xBE, 0xC8, 0x6F, 0x55, 0xE9, 0xD8, +0x70, 0x8F, 0xA0, 0xC8, 0x71, 0x35, 0xCB, 0xD8, 0x72, 0x6F, 0x82, 0xC8, 0x73, 0x15, 0xAD, 0xD8, +0x74, 0x4F, 0x64, 0xC8, 0x74, 0xFE, 0xCA, 0x58, 0x76, 0x38, 0x81, 0x48, 0x76, 0xDE, 0xAC, 0x58, +0x78, 0x18, 0x63, 0x48, 0x78, 0xBE, 0x8E, 0x58, 0x79, 0xF8, 0x45, 0x48, 0x7A, 0x9E, 0x70, 0x58, +0x7B, 0xD8, 0x27, 0x48, 0x7C, 0x7E, 0x52, 0x58, 0x7D, 0xB8, 0x09, 0x48, 0x7E, 0x5E, 0x34, 0x58, +0x7F, 0x97, 0xEB, 0x48, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x05, 0x04, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, @@ -13480,7 +13467,7 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { /* Europe/Kaliningrad */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x4D, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x1A, 0x9B, 0x0C, 0x17, 0x60, +0x00, 0x00, 0x00, 0x4D, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x00, 0x00, 0x1F, 0x9B, 0x0C, 0x17, 0x60, 0x9B, 0xD5, 0xDA, 0xF0, 0x9C, 0xD9, 0xAE, 0x90, 0x9D, 0xA4, 0xB5, 0x90, 0x9E, 0xB9, 0x90, 0x90, 0x9F, 0x84, 0x97, 0x90, 0xC8, 0x09, 0x71, 0x90, 0xCC, 0xE7, 0x4B, 0x10, 0xCD, 0xA9, 0x17, 0x90, 0xCE, 0xA2, 0x43, 0x10, 0xCF, 0x92, 0x34, 0x10, 0xD0, 0x82, 0x25, 0x10, 0xD0, 0xFA, 0x01, 0x70, @@ -13510,13 +13497,13 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x05, 0x00, 0x00, 0x38, 0x40, 0x01, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x0D, 0x00, 0x00, 0x38, 0x40, 0x01, 0x09, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x16, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x11, 0x00, 0x00, 0x1C, 0x20, 0x00, -0x16, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x16, 0x43, 0x45, 0x53, 0x54, 0x00, 0x43, 0x45, 0x54, 0x00, +0x16, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x1A, 0x43, 0x45, 0x53, 0x54, 0x00, 0x43, 0x45, 0x54, 0x00, 0x4D, 0x53, 0x44, 0x00, 0x4D, 0x53, 0x4B, 0x00, 0x45, 0x45, 0x53, 0x54, 0x00, 0x45, 0x45, 0x54, -0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x01, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0xDC, 0xD1, 0xF2, 0x01, 0x31, 0xF0, 0x50, 0x00, 0x00, 0x00, 0x17, 0x4D, 0x6F, 0x73, 0x63, 0x6F, -0x77, 0x2D, 0x30, 0x31, 0x20, 0x2D, 0x20, 0x4B, 0x61, 0x6C, 0x69, 0x6E, 0x69, 0x6E, 0x67, 0x72, -0x61, 0x64, +0x00, 0x4B, 0x41, 0x4C, 0x54, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, +0x01, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0xDC, 0xD1, 0xF2, 0x01, 0x31, 0xF0, 0x50, 0x00, 0x00, 0x00, 0x17, +0x4D, 0x6F, 0x73, 0x63, 0x6F, 0x77, 0x2D, 0x30, 0x31, 0x20, 0x2D, 0x20, 0x4B, 0x61, 0x6C, 0x69, +0x6E, 0x69, 0x6E, 0x67, 0x72, 0x61, 0x64, /* Europe/Kiev */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x55, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -16544,13 +16531,14 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { /* Pacific/Apia */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x57, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x12, 0x91, 0x05, 0xFC, 0x00, -0xDA, 0x62, 0x04, 0x38, 0x4C, 0x9F, 0x27, 0xB0, 0x4D, 0x97, 0x2B, 0xE0, 0x01, 0x02, 0x03, 0x02, -0xFF, 0xFF, 0x5F, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x5E, 0x48, 0x00, 0x04, 0xFF, 0xFF, 0x65, 0x50, -0x00, 0x09, 0xFF, 0xFF, 0x73, 0x60, 0x01, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x53, 0x41, 0x4D, 0x54, -0x00, 0x57, 0x53, 0x54, 0x00, 0x57, 0x53, 0x44, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x74, 0x38, 0x9A, 0x00, 0x0C, 0x9D, 0x2A, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x12, 0x91, 0x05, 0xFC, 0x00, +0xDA, 0x62, 0x04, 0x38, 0x4C, 0x9F, 0x27, 0xB0, 0x4D, 0x97, 0x2B, 0xE0, 0x4E, 0xFD, 0x99, 0xB0, +0x01, 0x02, 0x03, 0x02, 0x04, 0xFF, 0xFF, 0x5F, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x5E, 0x48, 0x00, +0x04, 0xFF, 0xFF, 0x65, 0x50, 0x00, 0x09, 0xFF, 0xFF, 0x73, 0x60, 0x01, 0x0D, 0x00, 0x00, 0xB6, +0xD0, 0x00, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x53, 0x41, 0x4D, 0x54, 0x00, 0x57, 0x53, 0x54, 0x00, +0x57, 0x53, 0x44, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, +0x74, 0x38, 0x9A, 0x00, 0x0C, 0x9D, 0x2A, 0x00, 0x00, 0x00, 0x00, /* Pacific/Auckland */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x4E, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -18157,4 +18145,4 @@ const unsigned char timelib_timezone_db_data_builtin[257855] = { 0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, }; -const timelib_tzdb timezonedb_builtin = { "2011.8", 573, timezonedb_idx_builtin, timelib_timezone_db_data_builtin }; +const timelib_tzdb timezonedb_builtin = { "2011.9", 574, timezonedb_idx_builtin, timelib_timezone_db_data_builtin }; From 4a6c2a8b449afa9d3e9d53e58813c441d4c04931 Mon Sep 17 00:00:00 2001 From: Arpad Ray Date: Mon, 29 Aug 2011 20:23:34 +0000 Subject: [PATCH 0632/2394] add support for SORT_NATURAL and SORT_FLAG_CASE in array sort functions --- NEWS | 2 + ext/standard/array.c | 15 +- ext/standard/php_array.h | 2 + ext/standard/php_string.h | 4 + ext/standard/string.c | 43 +++++ .../tests/array/array_multisort_basic1.phpt | 2 +- .../tests/array/array_multisort_basic2.phpt | 2 +- .../tests/array/array_multisort_case.phpt | 73 ++++++++ .../tests/array/array_multisort_error.phpt | 2 +- .../tests/array/array_multisort_incase.phpt | 73 ++++++++ .../tests/array/array_multisort_natural.phpt | 61 +++++++ .../array/array_multisort_natural_case.phpt | 73 ++++++++ .../array/array_multisort_natural_incase.phpt | 73 ++++++++ .../array/array_multisort_variation1.phpt | 2 +- .../array/array_multisort_variation10.phpt | 2 +- .../array/array_multisort_variation11.phpt | 2 +- .../array/array_multisort_variation2.phpt | 4 +- .../array/array_multisort_variation3.phpt | 2 +- .../array/array_multisort_variation4.phpt | 2 +- .../array/array_multisort_variation5.phpt | 2 +- .../array/array_multisort_variation6.phpt | 2 +- .../array/array_multisort_variation7.phpt | 2 +- .../array/array_multisort_variation8.phpt | 2 +- .../array/array_multisort_variation9.phpt | 2 +- ext/standard/tests/array/arsort_basic.phpt | 120 ++++++++++++- .../tests/array/arsort_variation2.phpt | 6 +- ext/standard/tests/array/asort_basic.phpt | 122 +++++++++++++- .../tests/array/asort_variation2.phpt | 4 +- ext/standard/tests/array/krsort_basic.phpt | 157 ++++++++++++++--- .../tests/array/krsort_variation2.phpt | 4 +- ext/standard/tests/array/ksort_basic.phpt | 158 +++++++++++++++--- .../tests/array/ksort_variation2.phpt | 4 +- ext/standard/tests/array/rsort_basic.phpt | 128 +++++++++++++- ext/standard/tests/array/sort_basic.phpt | 130 +++++++++++++- ext/standard/tests/array/sort_variation2.phpt | 4 +- 35 files changed, 1185 insertions(+), 101 deletions(-) create mode 100644 ext/standard/tests/array/array_multisort_case.phpt create mode 100644 ext/standard/tests/array/array_multisort_incase.phpt create mode 100644 ext/standard/tests/array/array_multisort_natural.phpt create mode 100644 ext/standard/tests/array/array_multisort_natural_case.phpt create mode 100644 ext/standard/tests/array/array_multisort_natural_incase.phpt diff --git a/NEWS b/NEWS index 9c4f389a80d3f..3430cd939675f 100644 --- a/NEWS +++ b/NEWS @@ -54,6 +54,8 @@ PHP NEWS one SAPI module the same time. FR #53271, FR #52410. (Jani) . Added optional argument to debug_backtrace() and debug_print_backtrace() to limit the amount of stack frames returned. (Sebastian, Patrick) + . Added support for SORT_NATURAL and SORT_FLAG_CASE in array sort functions: + sort, rsort, ksort, krsort, asort, arsort and array_multisort. Req #55158 (arpad) - Improved Zend Engine memory usage: (Dmitry) . Replaced zend_function.pass_rest_by_reference by diff --git a/ext/standard/array.c b/ext/standard/array.c index ed967e339580c..d189c7faefefb 100644 --- a/ext/standard/array.c +++ b/ext/standard/array.c @@ -118,6 +118,8 @@ PHP_MINIT_FUNCTION(array) /* {{{ */ REGISTER_LONG_CONSTANT("SORT_NUMERIC", PHP_SORT_NUMERIC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SORT_STRING", PHP_SORT_STRING, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SORT_LOCALE_STRING", PHP_SORT_LOCALE_STRING, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("SORT_NATURAL", PHP_SORT_NATURAL, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("SORT_FLAG_CASE", PHP_SORT_FLAG_CASE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("CASE_LOWER", CASE_LOWER, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("CASE_UPPER", CASE_UPPER, CONST_CS | CONST_PERSISTENT); @@ -141,13 +143,17 @@ PHP_MSHUTDOWN_FUNCTION(array) /* {{{ */ static void php_set_compare_func(int sort_type TSRMLS_DC) /* {{{ */ { - switch (sort_type) { + switch (sort_type & ~PHP_SORT_FLAG_CASE) { case PHP_SORT_NUMERIC: ARRAYG(compare_func) = numeric_compare_function; break; case PHP_SORT_STRING: - ARRAYG(compare_func) = string_compare_function; + ARRAYG(compare_func) = sort_type & PHP_SORT_FLAG_CASE ? string_case_compare_function : string_compare_function; + break; + + case PHP_SORT_NATURAL: + ARRAYG(compare_func) = sort_type & PHP_SORT_FLAG_CASE ? string_natural_case_compare_function : string_natural_compare_function; break; #if HAVE_STRCOLL @@ -3762,7 +3768,7 @@ PHPAPI int php_multisort_compare(const void *a, const void *b TSRMLS_DC) /* {{{ efree(args); \ RETURN_FALSE; -/* {{{ proto bool array_multisort(array ar1 [, SORT_ASC|SORT_DESC [, SORT_REGULAR|SORT_NUMERIC|SORT_STRING]] [, array ar2 [, SORT_ASC|SORT_DESC [, SORT_REGULAR|SORT_NUMERIC|SORT_STRING]], ...]) +/* {{{ proto bool array_multisort(array ar1 [, SORT_ASC|SORT_DESC [, SORT_REGULAR|SORT_NUMERIC|SORT_STRING|SORT_NATURAL|SORT_FLAG_CASE]] [, array ar2 [, SORT_ASC|SORT_DESC [, SORT_REGULAR|SORT_NUMERIC|SORT_STRING|SORT_NATURAL|SORT_FLAG_CASE]], ...]) Sort multiple arrays at once similar to how ORDER BY clause works in SQL */ PHP_FUNCTION(array_multisort) { @@ -3812,7 +3818,7 @@ PHP_FUNCTION(array_multisort) parse_state[k] = 1; } } else if (Z_TYPE_PP(args[i]) == IS_LONG) { - switch (Z_LVAL_PP(args[i])) { + switch (Z_LVAL_PP(args[i]) & ~PHP_SORT_FLAG_CASE) { case PHP_SORT_ASC: case PHP_SORT_DESC: /* flag allowed here */ @@ -3829,6 +3835,7 @@ PHP_FUNCTION(array_multisort) case PHP_SORT_REGULAR: case PHP_SORT_NUMERIC: case PHP_SORT_STRING: + case PHP_SORT_NATURAL: #if HAVE_STRCOLL case PHP_SORT_LOCALE_STRING: #endif diff --git a/ext/standard/php_array.h b/ext/standard/php_array.h index 07a38cfd916b2..779536e006d68 100644 --- a/ext/standard/php_array.h +++ b/ext/standard/php_array.h @@ -113,6 +113,8 @@ PHPAPI int php_multisort_compare(const void *a, const void *b TSRMLS_DC); #define PHP_SORT_DESC 3 #define PHP_SORT_ASC 4 #define PHP_SORT_LOCALE_STRING 5 +#define PHP_SORT_NATURAL 6 +#define PHP_SORT_FLAG_CASE 8 ZEND_BEGIN_MODULE_GLOBALS(array) int *multisort_flags[2]; diff --git a/ext/standard/php_string.h b/ext/standard/php_string.h index c6d916dbcc182..8284204c8902c 100644 --- a/ext/standard/php_string.h +++ b/ext/standard/php_string.h @@ -143,6 +143,10 @@ PHPAPI void php_explode(zval *delim, zval *str, zval *return_value, long limit); PHPAPI size_t php_strspn(char *s1, char *s2, char *s1_end, char *s2_end); PHPAPI size_t php_strcspn(char *s1, char *s2, char *s1_end, char *s2_end); +PHPAPI int string_natural_compare_function_ex(zval *result, zval *op1, zval *op2, zend_bool case_insensitive TSRMLS_DC); +PHPAPI int string_natural_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); +PHPAPI int string_natural_case_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); + #ifndef HAVE_STRERROR PHPAPI char *php_strerror(int errnum); #define strerror php_strerror diff --git a/ext/standard/string.c b/ext/standard/string.c index 1717b3b711593..62599d40196ce 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -4734,6 +4734,49 @@ static void php_strnatcmp(INTERNAL_FUNCTION_PARAMETERS, int fold_case) } /* }}} */ +PHPAPI int string_natural_compare_function_ex(zval *result, zval *op1, zval *op2, zend_bool case_insensitive TSRMLS_DC) /* {{{ */ +{ + zval op1_copy, op2_copy; + int use_copy1 = 0, use_copy2 = 0, sort_result; + + if (Z_TYPE_P(op1) != IS_STRING) { + zend_make_printable_zval(op1, &op1_copy, &use_copy1); + } + if (Z_TYPE_P(op2) != IS_STRING) { + zend_make_printable_zval(op2, &op2_copy, &use_copy2); + } + + if (use_copy1) { + op1 = &op1_copy; + } + if (use_copy2) { + op2 = &op2_copy; + } + + ZVAL_LONG(result, strnatcmp_ex(Z_STRVAL_P(op1), Z_STRLEN_P(op1), Z_STRVAL_P(op2), Z_STRLEN_P(op2), case_insensitive)); + + if (use_copy1) { + zval_dtor(op1); + } + if (use_copy2) { + zval_dtor(op2); + } + return SUCCESS; +} +/* }}} */ + +PHPAPI int string_natural_case_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ +{ + return string_natural_compare_function_ex(result, op1, op2, 1 TSRMLS_CC); +} +/* }}} */ + +PHPAPI int string_natural_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ +{ + return string_natural_compare_function_ex(result, op1, op2, 0 TSRMLS_CC); +} +/* }}} */ + /* {{{ proto int strnatcmp(string s1, string s2) Returns the result of string comparison using 'natural' algorithm */ PHP_FUNCTION(strnatcmp) diff --git a/ext/standard/tests/array/array_multisort_basic1.phpt b/ext/standard/tests/array/array_multisort_basic1.phpt index af5f8df4f32ac..ab7db944635f7 100644 --- a/ext/standard/tests/array/array_multisort_basic1.phpt +++ b/ext/standard/tests/array/array_multisort_basic1.phpt @@ -2,7 +2,7 @@ Test array_multisort() function : basic functionality --FILE-- +===DONE=== +--EXPECTF-- +*** Testing array_multisort() : case-sensitive +array(7) { + [0]=> + string(7) "First.3" + [1]=> + string(7) "First.2" + [2]=> + string(7) "First.1" + [3]=> + string(5) "Tenth" + [4]=> + string(6) "Second" + [5]=> + string(9) "Twentieth" + [6]=> + string(5) "Third" +} +array(7) { + [0]=> + string(6) "1 BB 3" + [1]=> + string(6) "1 bB 2" + [2]=> + string(6) "1 bb 1" + [3]=> + string(4) "10 d" + [4]=> + string(3) "2 a" + [5]=> + string(4) "20 c" + [6]=> + string(3) "3 e" +} +===DONE=== diff --git a/ext/standard/tests/array/array_multisort_error.phpt b/ext/standard/tests/array/array_multisort_error.phpt index 7cd95ec1698aa..5956630f845e8 100644 --- a/ext/standard/tests/array/array_multisort_error.phpt +++ b/ext/standard/tests/array/array_multisort_error.phpt @@ -2,7 +2,7 @@ Test array_multisort() function : error conditions --FILE-- +===DONE=== +--EXPECTF-- +*** Testing array_multisort() : case-insensitive +array(7) { + [0]=> + string(7) "First.1" + [1]=> + string(7) "First.2" + [2]=> + string(7) "First.3" + [3]=> + string(5) "Tenth" + [4]=> + string(6) "Second" + [5]=> + string(9) "Twentieth" + [6]=> + string(5) "Third" +} +array(7) { + [0]=> + string(6) "1 bb 1" + [1]=> + string(6) "1 bB 2" + [2]=> + string(6) "1 BB 3" + [3]=> + string(4) "10 d" + [4]=> + string(3) "2 a" + [5]=> + string(4) "20 c" + [6]=> + string(3) "3 e" +} +===DONE=== diff --git a/ext/standard/tests/array/array_multisort_natural.phpt b/ext/standard/tests/array/array_multisort_natural.phpt new file mode 100644 index 0000000000000..e7910882e4850 --- /dev/null +++ b/ext/standard/tests/array/array_multisort_natural.phpt @@ -0,0 +1,61 @@ +--TEST-- +Test array_multisort() function : natural sorting +--FILE-- + +===DONE=== +--EXPECTF-- +*** Testing array_multisort() : natural sorting +array(5) { + [0]=> + string(5) "First" + [1]=> + string(6) "Second" + [2]=> + string(5) "Third" + [3]=> + string(5) "Tenth" + [4]=> + string(9) "Twentieth" +} +array(5) { + [0]=> + string(3) "1 b" + [1]=> + string(3) "2 a" + [2]=> + string(3) "3 e" + [3]=> + string(4) "10 d" + [4]=> + string(4) "20 c" +} +===DONE=== diff --git a/ext/standard/tests/array/array_multisort_natural_case.phpt b/ext/standard/tests/array/array_multisort_natural_case.phpt new file mode 100644 index 0000000000000..d59e4931b6148 --- /dev/null +++ b/ext/standard/tests/array/array_multisort_natural_case.phpt @@ -0,0 +1,73 @@ +--TEST-- +Test array_multisort() function : natural sorting case-sensitive +--FILE-- + +===DONE=== +--EXPECTF-- +*** Testing array_multisort() : natural sorting case-sensitive +array(7) { + [0]=> + string(7) "First.3" + [1]=> + string(7) "First.2" + [2]=> + string(7) "First.1" + [3]=> + string(6) "Second" + [4]=> + string(5) "Third" + [5]=> + string(5) "Tenth" + [6]=> + string(9) "Twentieth" +} +array(7) { + [0]=> + string(6) "1 BB 3" + [1]=> + string(6) "1 bB 2" + [2]=> + string(6) "1 bb 1" + [3]=> + string(3) "2 a" + [4]=> + string(3) "3 e" + [5]=> + string(4) "10 d" + [6]=> + string(4) "20 c" +} +===DONE=== diff --git a/ext/standard/tests/array/array_multisort_natural_incase.phpt b/ext/standard/tests/array/array_multisort_natural_incase.phpt new file mode 100644 index 0000000000000..87514058a93bd --- /dev/null +++ b/ext/standard/tests/array/array_multisort_natural_incase.phpt @@ -0,0 +1,73 @@ +--TEST-- +Test array_multisort() function : natural sorting case-insensitive +--FILE-- + +===DONE=== +--EXPECTF-- +*** Testing array_multisort() : natural sorting case-insensitive +array(7) { + [0]=> + string(7) "First.1" + [1]=> + string(7) "First.2" + [2]=> + string(7) "First.3" + [3]=> + string(6) "Second" + [4]=> + string(5) "Third" + [5]=> + string(5) "Tenth" + [6]=> + string(9) "Twentieth" +} +array(7) { + [0]=> + string(6) "1 bb 1" + [1]=> + string(6) "1 bB 2" + [2]=> + string(6) "1 BB 3" + [3]=> + string(3) "2 a" + [4]=> + string(3) "3 e" + [5]=> + string(4) "10 d" + [6]=> + string(4) "20 c" +} +===DONE=== diff --git a/ext/standard/tests/array/array_multisort_variation1.phpt b/ext/standard/tests/array/array_multisort_variation1.phpt index 084addef406f5..93c265922e584 100644 --- a/ext/standard/tests/array/array_multisort_variation1.phpt +++ b/ext/standard/tests/array/array_multisort_variation1.phpt @@ -2,7 +2,7 @@ Test array_multisort() function : usage variation --FILE-- @$unset_var, ); -// loop through each element of the array for SORT_REGULAR|SORT_NUMERIC|SORT_STRING]] +// loop through each element of the array for SORT_REGULAR|SORT_NUMERIC|SORT_STRING|SORT_NATURAL|SORT_FLAG_CASE]] foreach($inputs as $key =>$value) { echo "\n--$key--\n"; diff --git a/ext/standard/tests/array/array_multisort_variation3.phpt b/ext/standard/tests/array/array_multisort_variation3.phpt index 534374c431618..b2cdb05ece333 100644 --- a/ext/standard/tests/array/array_multisort_variation3.phpt +++ b/ext/standard/tests/array/array_multisort_variation3.phpt @@ -2,7 +2,7 @@ Test array_multisort() function : usage variation --FILE-- "lemon", "o" => "orange", "b" => "banana" ); +$unsorted_strings = array( + "l" => "lemon", "o" => "orange", + "O" => "Orange", "O1" => "Orange1", "o2" => "orange2", "O3" => "Orange3", "o20" => "orange20", + "b" => "banana", +); // an array containing unsorted numeric values with indices $unsorted_numerics = array( 1 => 100, 2 => 33, 3 => 555, 4 => 22 ); @@ -49,6 +53,21 @@ $temp_array = $unsorted_strings; var_dump( arsort($temp_array, SORT_STRING) ); // expecting : bool(true) var_dump( $temp_array); +echo "\n-- Testing arsort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( arsort($temp_array, SORT_STRING|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing arsort() by supplying string array (natural), 'flag' = SORT_NATURAL --\n"; +$temp_array = $unsorted_strings; +var_dump( arsort($temp_array, SORT_NATURAL) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing arsort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( arsort($temp_array, SORT_NATURAL|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + echo "\n-- Testing arsort() by supplying numeric array, 'flag' = SORT_NUMERIC --\n"; $temp_array = $unsorted_numerics; var_dump( arsort($temp_array, SORT_NUMERIC) ); // expecting : bool(true) @@ -61,13 +80,23 @@ echo "Done\n"; -- Testing arsort() by supplying string array, 'flag' value is default -- bool(true) -array(3) { +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" ["o"]=> string(6) "orange" ["l"]=> string(5) "lemon" ["b"]=> string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" } -- Testing arsort() by supplying numeric array, 'flag' value is default -- @@ -85,13 +114,23 @@ array(4) { -- Testing arsort() by supplying string array, 'flag' = SORT_REGULAR -- bool(true) -array(3) { +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" ["o"]=> string(6) "orange" ["l"]=> string(5) "lemon" ["b"]=> string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" } -- Testing arsort() by supplying numeric array, 'flag' = SORT_REGULAR -- @@ -109,9 +148,82 @@ array(4) { -- Testing arsort() by supplying string array, 'flag' = SORT_STRING -- bool(true) -array(3) { +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["o"]=> + string(6) "orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" +} + +-- Testing arsort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE -- +bool(true) +array(8) { + ["O3"]=> + string(7) "Orange3" + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["O1"]=> + string(7) "Orange1" + ["o"]=> + string(6) "orange" + ["O"]=> + string(6) "Orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" +} + +-- Testing arsort() by supplying string array (natural), 'flag' = SORT_NATURAL -- +bool(true) +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["o"]=> + string(6) "orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" +} + +-- Testing arsort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE -- +bool(true) +array(8) { + ["o20"]=> + string(8) "orange20" + ["O3"]=> + string(7) "Orange3" + ["o2"]=> + string(7) "orange2" + ["O1"]=> + string(7) "Orange1" ["o"]=> string(6) "orange" + ["O"]=> + string(6) "Orange" ["l"]=> string(5) "lemon" ["b"]=> diff --git a/ext/standard/tests/array/arsort_variation2.phpt b/ext/standard/tests/array/arsort_variation2.phpt index ab04b4409945b..b85653052f730 100644 --- a/ext/standard/tests/array/arsort_variation2.phpt +++ b/ext/standard/tests/array/arsort_variation2.phpt @@ -104,10 +104,10 @@ bool(true) array(3) { [3]=> int(45) - [1]=> - int(10) [2]=> int(2) + [1]=> + int(10) } -- Iteration 3 -- bool(true) @@ -305,4 +305,4 @@ array(3) { [3]=> int(45) } -Done \ No newline at end of file +Done diff --git a/ext/standard/tests/array/asort_basic.phpt b/ext/standard/tests/array/asort_basic.phpt index 13fa4f794e8e0..b80d31d37f0e1 100644 --- a/ext/standard/tests/array/asort_basic.phpt +++ b/ext/standard/tests/array/asort_basic.phpt @@ -20,7 +20,11 @@ Test asort() function : basic functionality echo "*** Testing asort() : basic functionality ***\n"; // an array containing unsorted string values with indices -$unsorted_strings = array( "l" => "lemon", "o" => "orange", "b" => "banana" ); +$unsorted_strings = array( + "l" => "lemon", "o" => "orange", + "O" => "Orange", "O1" => "Orange1", "o2" => "orange2", "O3" => "Orange3", "o20" => "orange20", + "b" => "banana", +); // an array containing unsorted numeric values with indices $unsorted_numerics = array( 1 => 100, 2 => 33, 3 => 555, 4 => 22 ); @@ -49,6 +53,21 @@ $temp_array = $unsorted_strings; var_dump( asort($temp_array, SORT_STRING) ); // expecting : bool(true) var_dump( $temp_array); +echo "\n-- Testing asort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( asort($temp_array, SORT_STRING|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing asort() by supplying string array (natural), 'flag' = SORT_NATURAL --\n"; +$temp_array = $unsorted_strings; +var_dump( asort($temp_array, SORT_NATURAL) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing asort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( asort($temp_array, SORT_NATURAL|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + echo "\n-- Testing asort() by supplying numeric array, 'flag' = SORT_NUMERIC --\n"; $temp_array = $unsorted_numerics; var_dump( asort($temp_array, SORT_NUMERIC) ); // expecting : bool(true) @@ -61,13 +80,23 @@ echo "Done\n"; -- Testing asort() by supplying string array, 'flag' value is default -- bool(true) -array(3) { +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" ["b"]=> string(6) "banana" ["l"]=> string(5) "lemon" ["o"]=> string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" } -- Testing asort() by supplying numeric array, 'flag' value is default -- @@ -85,13 +114,23 @@ array(4) { -- Testing asort() by supplying string array, 'flag' = SORT_REGULAR -- bool(true) -array(3) { +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" ["b"]=> string(6) "banana" ["l"]=> string(5) "lemon" ["o"]=> string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" } -- Testing asort() by supplying numeric array, 'flag' = SORT_REGULAR -- @@ -109,13 +148,86 @@ array(4) { -- Testing asort() by supplying string array, 'flag' = SORT_STRING -- bool(true) -array(3) { +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" + ["b"]=> + string(6) "banana" + ["l"]=> + string(5) "lemon" + ["o"]=> + string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" +} + +-- Testing asort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE -- +bool(true) +array(8) { + ["b"]=> + string(6) "banana" + ["l"]=> + string(5) "lemon" + ["o"]=> + string(6) "orange" + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" + ["O3"]=> + string(7) "Orange3" +} + +-- Testing asort() by supplying string array (natural), 'flag' = SORT_NATURAL -- +bool(true) +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" + ["b"]=> + string(6) "banana" + ["l"]=> + string(5) "lemon" + ["o"]=> + string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" +} + +-- Testing asort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE -- +bool(true) +array(8) { ["b"]=> string(6) "banana" ["l"]=> string(5) "lemon" ["o"]=> string(6) "orange" + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["o2"]=> + string(7) "orange2" + ["O3"]=> + string(7) "Orange3" + ["o20"]=> + string(8) "orange20" } -- Testing asort() by supplying numeric array, 'flag' = SORT_NUMERIC -- @@ -130,4 +242,4 @@ array(4) { [3]=> int(555) } -Done +Done \ No newline at end of file diff --git a/ext/standard/tests/array/asort_variation2.phpt b/ext/standard/tests/array/asort_variation2.phpt index 07dfe9b81547e..6cce644331cdd 100644 --- a/ext/standard/tests/array/asort_variation2.phpt +++ b/ext/standard/tests/array/asort_variation2.phpt @@ -102,10 +102,10 @@ array(3) { -- Iteration 2 -- bool(true) array(3) { - [2]=> - int(2) [1]=> int(10) + [2]=> + int(2) [3]=> int(45) } diff --git a/ext/standard/tests/array/krsort_basic.phpt b/ext/standard/tests/array/krsort_basic.phpt index 913256897b6a9..27361eb96d482 100644 --- a/ext/standard/tests/array/krsort_basic.phpt +++ b/ext/standard/tests/array/krsort_basic.phpt @@ -20,6 +20,11 @@ echo "*** Testing krsort() : basic functionality ***\n"; // an array containing unsorted string values with indices $unsorted_strings = array( "lemon" => "l", "orange" => "o", "banana" => "b" ); +$unsorted_strings = array( + "l" => "lemon", "o" => "orange", + "O" => "Orange", "O1" => "Orange1", "o2" => "orange2", "O3" => "Orange3", "o20" => "orange20", + "b" => "banana", +); // an array containing unsorted numeric values with indices $unsorted_numerics = array( 100 => 4, 33 => 3, 555 => 2, 22 => 1 ); @@ -48,6 +53,21 @@ $temp_array = $unsorted_strings; var_dump( krsort($temp_array, SORT_STRING) ); // expecting : bool(true) var_dump( $temp_array); +echo "\n-- Testing krsort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( krsort($temp_array, SORT_STRING|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing krsort() by supplying string array (natural), 'flag' = SORT_NATURAL --\n"; +$temp_array = $unsorted_strings; +var_dump( krsort($temp_array, SORT_NATURAL) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing krsort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( krsort($temp_array, SORT_NATURAL|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + echo "\n-- Testing krsort() by supplying numeric array, 'flag' = SORT_NUMERIC --\n"; $temp_array = $unsorted_numerics; var_dump( krsort($temp_array, SORT_NUMERIC) ); // expecting : bool(true) @@ -60,13 +80,23 @@ echo "Done\n"; -- Testing krsort() by supplying string array, 'flag' value is defualt -- bool(true) -array(3) { - ["orange"]=> - string(1) "o" - ["lemon"]=> - string(1) "l" - ["banana"]=> - string(1) "b" +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["o"]=> + string(6) "orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" } -- Testing krsort() by supplying numeric array, 'flag' value is defualt -- @@ -84,13 +114,23 @@ array(4) { -- Testing krsort() by supplying string array, 'flag' = SORT_REGULAR -- bool(true) -array(3) { - ["orange"]=> - string(1) "o" - ["lemon"]=> - string(1) "l" - ["banana"]=> - string(1) "b" +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["o"]=> + string(6) "orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" } -- Testing krsort() by supplying numeric array, 'flag' = SORT_REGULAR -- @@ -108,13 +148,86 @@ array(4) { -- Testing krsort() by supplying string array, 'flag' = SORT_STRING -- bool(true) -array(3) { - ["orange"]=> - string(1) "o" - ["lemon"]=> - string(1) "l" - ["banana"]=> - string(1) "b" +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["o"]=> + string(6) "orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" +} + +-- Testing krsort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE -- +bool(true) +array(8) { + ["O3"]=> + string(7) "Orange3" + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["O1"]=> + string(7) "Orange1" + ["o"]=> + string(6) "orange" + ["O"]=> + string(6) "Orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" +} + +-- Testing krsort() by supplying string array (natural), 'flag' = SORT_NATURAL -- +bool(true) +array(8) { + ["o20"]=> + string(8) "orange20" + ["o2"]=> + string(7) "orange2" + ["o"]=> + string(6) "orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" + ["O3"]=> + string(7) "Orange3" + ["O1"]=> + string(7) "Orange1" + ["O"]=> + string(6) "Orange" +} + +-- Testing krsort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE -- +bool(true) +array(8) { + ["o20"]=> + string(8) "orange20" + ["O3"]=> + string(7) "Orange3" + ["o2"]=> + string(7) "orange2" + ["O1"]=> + string(7) "Orange1" + ["o"]=> + string(6) "orange" + ["O"]=> + string(6) "Orange" + ["l"]=> + string(5) "lemon" + ["b"]=> + string(6) "banana" } -- Testing krsort() by supplying numeric array, 'flag' = SORT_NUMERIC -- @@ -129,4 +242,4 @@ array(4) { [22]=> int(1) } -Done +Done \ No newline at end of file diff --git a/ext/standard/tests/array/krsort_variation2.phpt b/ext/standard/tests/array/krsort_variation2.phpt index c567f766cb614..13762024705eb 100644 --- a/ext/standard/tests/array/krsort_variation2.phpt +++ b/ext/standard/tests/array/krsort_variation2.phpt @@ -103,10 +103,10 @@ bool(true) array(3) { [45]=> int(45) - [10]=> - int(10) [2]=> int(2) + [10]=> + int(10) } -- Iteration 3 -- bool(true) diff --git a/ext/standard/tests/array/ksort_basic.phpt b/ext/standard/tests/array/ksort_basic.phpt index fdc8bd8dc69a0..dd9f7a2158223 100644 --- a/ext/standard/tests/array/ksort_basic.phpt +++ b/ext/standard/tests/array/ksort_basic.phpt @@ -18,7 +18,11 @@ Test ksort() function : basic functionality echo "*** Testing ksort() : basic functionality ***\n"; // an array containing unsorted string values with indices -$unsorted_strings = array( "lemon" => "l", "orange" => "o", "banana" => "b" ); +$unsorted_strings = array( + "l" => "lemon", "o" => "orange", + "O" => "Orange", "O1" => "Orange1", "o2" => "orange2", "O3" => "Orange3", "o20" => "orange20", + "b" => "banana", +); // an array containing unsorted numeric values with indices $unsorted_numerics = array( 100 => 4, 33 => 3, 555 => 2, 22 => 1 ); @@ -47,6 +51,21 @@ $temp_array = $unsorted_strings; var_dump( ksort($temp_array, SORT_STRING) ); // expecting : bool(true) var_dump( $temp_array); +echo "\n-- Testing ksort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( sort($temp_array, SORT_STRING|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing ksort() by supplying string array (natural), 'flag' = SORT_NATURAL --\n"; +$temp_array = $unsorted_strings; +var_dump( sort($temp_array, SORT_NATURAL) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing ksort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( sort($temp_array, SORT_NATURAL|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + echo "\n-- Testing ksort() by supplying numeric array, 'flag' = SORT_NUMERIC --\n"; $temp_array = $unsorted_numerics; var_dump( ksort($temp_array, SORT_NUMERIC) ); // expecting : bool(true) @@ -59,13 +78,23 @@ echo "Done\n"; -- Testing ksort() by supplying string array, 'flag' value is defualt -- bool(true) -array(3) { - ["banana"]=> - string(1) "b" - ["lemon"]=> - string(1) "l" - ["orange"]=> - string(1) "o" +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" + ["b"]=> + string(6) "banana" + ["l"]=> + string(5) "lemon" + ["o"]=> + string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" } -- Testing ksort() by supplying numeric array, 'flag' value is defualt -- @@ -83,13 +112,23 @@ array(4) { -- Testing ksort() by supplying string array, 'flag' = SORT_REGULAR -- bool(true) -array(3) { - ["banana"]=> - string(1) "b" - ["lemon"]=> - string(1) "l" - ["orange"]=> - string(1) "o" +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" + ["b"]=> + string(6) "banana" + ["l"]=> + string(5) "lemon" + ["o"]=> + string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" } -- Testing ksort() by supplying numeric array, 'flag' = SORT_REGULAR -- @@ -107,13 +146,86 @@ array(4) { -- Testing ksort() by supplying string array, 'flag' = SORT_STRING -- bool(true) -array(3) { - ["banana"]=> - string(1) "b" - ["lemon"]=> - string(1) "l" - ["orange"]=> - string(1) "o" +array(8) { + ["O"]=> + string(6) "Orange" + ["O1"]=> + string(7) "Orange1" + ["O3"]=> + string(7) "Orange3" + ["b"]=> + string(6) "banana" + ["l"]=> + string(5) "lemon" + ["o"]=> + string(6) "orange" + ["o2"]=> + string(7) "orange2" + ["o20"]=> + string(8) "orange20" +} + +-- Testing ksort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE -- +bool(true) +array(8) { + [0]=> + string(6) "banana" + [1]=> + string(5) "lemon" + [2]=> + string(6) "orange" + [3]=> + string(6) "Orange" + [4]=> + string(7) "Orange1" + [5]=> + string(7) "orange2" + [6]=> + string(8) "orange20" + [7]=> + string(7) "Orange3" +} + +-- Testing ksort() by supplying string array (natural), 'flag' = SORT_NATURAL -- +bool(true) +array(8) { + [0]=> + string(6) "Orange" + [1]=> + string(7) "Orange1" + [2]=> + string(7) "Orange3" + [3]=> + string(6) "banana" + [4]=> + string(5) "lemon" + [5]=> + string(6) "orange" + [6]=> + string(7) "orange2" + [7]=> + string(8) "orange20" +} + +-- Testing ksort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE -- +bool(true) +array(8) { + [0]=> + string(6) "banana" + [1]=> + string(5) "lemon" + [2]=> + string(6) "orange" + [3]=> + string(6) "Orange" + [4]=> + string(7) "Orange1" + [5]=> + string(7) "orange2" + [6]=> + string(7) "Orange3" + [7]=> + string(8) "orange20" } -- Testing ksort() by supplying numeric array, 'flag' = SORT_NUMERIC -- @@ -128,4 +240,4 @@ array(4) { [555]=> int(2) } -Done +Done \ No newline at end of file diff --git a/ext/standard/tests/array/ksort_variation2.phpt b/ext/standard/tests/array/ksort_variation2.phpt index f765977d21b13..4969844e759d2 100644 --- a/ext/standard/tests/array/ksort_variation2.phpt +++ b/ext/standard/tests/array/ksort_variation2.phpt @@ -101,10 +101,10 @@ array(3) { -- Iteration 2 -- bool(true) array(3) { - [2]=> - int(2) [10]=> int(10) + [2]=> + int(2) [45]=> int(45) } diff --git a/ext/standard/tests/array/rsort_basic.phpt b/ext/standard/tests/array/rsort_basic.phpt index 5495be92571a1..34fcbb7034f9e 100644 --- a/ext/standard/tests/array/rsort_basic.phpt +++ b/ext/standard/tests/array/rsort_basic.phpt @@ -14,7 +14,11 @@ Test rsort() function : basic functionality echo "*** Testing rsort() : basic functionality ***\n"; // associative array containing unsorted string values -$unsorted_strings = array( "l" => "lemon", "o" => "orange", "b" => "banana" ); +$unsorted_strings = array( + "l" => "lemon", "o" => "orange", + "O" => "Orange", "O1" => "Orange1", "o2" => "orange2", "O3" => "Orange3", "o20" => "orange20", + "b" => "banana", +); // array with default keys containing unsorted numeric values $unsorted_numerics = array( 100, 33, 555, 22 ); @@ -44,6 +48,21 @@ $temp_array = $unsorted_strings; var_dump( rsort($temp_array, SORT_STRING) ); var_dump( $temp_array); +echo "\n-- Testing rsort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( rsort($temp_array, SORT_STRING|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing rsort() by supplying string array (natural), 'flag' = SORT_NATURAL --\n"; +$temp_array = $unsorted_strings; +var_dump( rsort($temp_array, SORT_NATURAL) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing rsort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( rsort($temp_array, SORT_NATURAL|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + echo "\n-- Testing rsort() by supplying numeric array, 'flag' = SORT_NUMERIC --\n"; $temp_array = $unsorted_numerics; var_dump( rsort($temp_array, SORT_NUMERIC) ); @@ -57,13 +76,23 @@ echo "Done"; -- Testing rsort() by supplying string array, 'flag' value is defualt -- bool(true) -array(3) { +array(8) { [0]=> - string(6) "orange" + string(8) "orange20" [1]=> - string(5) "lemon" + string(7) "orange2" [2]=> + string(6) "orange" + [3]=> + string(5) "lemon" + [4]=> string(6) "banana" + [5]=> + string(7) "Orange3" + [6]=> + string(7) "Orange1" + [7]=> + string(6) "Orange" } -- Testing rsort() by supplying numeric array, 'flag' value is defualt -- @@ -81,13 +110,23 @@ array(4) { -- Testing rsort() by supplying string array, 'flag' = SORT_REGULAR -- bool(true) -array(3) { +array(8) { [0]=> - string(6) "orange" + string(8) "orange20" [1]=> - string(5) "lemon" + string(7) "orange2" [2]=> + string(6) "orange" + [3]=> + string(5) "lemon" + [4]=> string(6) "banana" + [5]=> + string(7) "Orange3" + [6]=> + string(7) "Orange1" + [7]=> + string(6) "Orange" } -- Testing rsort() by supplying numeric array, 'flag' = SORT_REGULAR -- @@ -105,12 +144,85 @@ array(4) { -- Testing rsort() by supplying string array, 'flag' = SORT_STRING -- bool(true) -array(3) { +array(8) { + [0]=> + string(8) "orange20" + [1]=> + string(7) "orange2" + [2]=> + string(6) "orange" + [3]=> + string(5) "lemon" + [4]=> + string(6) "banana" + [5]=> + string(7) "Orange3" + [6]=> + string(7) "Orange1" + [7]=> + string(6) "Orange" +} + +-- Testing rsort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE -- +bool(true) +array(8) { [0]=> + string(7) "Orange3" + [1]=> + string(8) "orange20" + [2]=> + string(7) "orange2" + [3]=> + string(7) "Orange1" + [4]=> string(6) "orange" + [5]=> + string(6) "Orange" + [6]=> + string(5) "lemon" + [7]=> + string(6) "banana" +} + +-- Testing rsort() by supplying string array (natural), 'flag' = SORT_NATURAL -- +bool(true) +array(8) { + [0]=> + string(8) "orange20" [1]=> + string(7) "orange2" + [2]=> + string(6) "orange" + [3]=> string(5) "lemon" + [4]=> + string(6) "banana" + [5]=> + string(7) "Orange3" + [6]=> + string(7) "Orange1" + [7]=> + string(6) "Orange" +} + +-- Testing rsort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE -- +bool(true) +array(8) { + [0]=> + string(8) "orange20" + [1]=> + string(7) "Orange3" [2]=> + string(7) "orange2" + [3]=> + string(7) "Orange1" + [4]=> + string(6) "orange" + [5]=> + string(6) "Orange" + [6]=> + string(5) "lemon" + [7]=> string(6) "banana" } diff --git a/ext/standard/tests/array/sort_basic.phpt b/ext/standard/tests/array/sort_basic.phpt index 3cf653f208926..460b572fc14c8 100644 --- a/ext/standard/tests/array/sort_basic.phpt +++ b/ext/standard/tests/array/sort_basic.phpt @@ -20,7 +20,11 @@ Test sort() function : basic functionality echo "*** Testing sort() : basic functionality ***\n"; // associative array containing unsorted string values -$unsorted_strings = array( "l" => "lemon", "o" => "orange", "b" => "banana" ); +$unsorted_strings = array( + "l" => "lemon", "o" => "orange", + "O" => "Orange", "O1" => "Orange1", "o2" => "orange2", "O3" => "Orange3", "o20" => "orange20", + "b" => "banana", +); // array with default keys containing unsorted numeric values $unsorted_numerics = array( 100, 33, 555, 22 ); @@ -50,6 +54,21 @@ $temp_array = $unsorted_strings; var_dump( sort($temp_array, SORT_STRING) ); // expecting : bool(true) var_dump( $temp_array); +echo "\n-- Testing sort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( sort($temp_array, SORT_STRING|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing sort() by supplying string array (natural), 'flag' = SORT_NATURAL --\n"; +$temp_array = $unsorted_strings; +var_dump( sort($temp_array, SORT_NATURAL) ); // expecting : bool(true) +var_dump( $temp_array); + +echo "\n-- Testing sort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE --\n"; +$temp_array = $unsorted_strings; +var_dump( sort($temp_array, SORT_NATURAL|SORT_FLAG_CASE) ); // expecting : bool(true) +var_dump( $temp_array); + echo "\n-- Testing sort() by supplying numeric array, 'flag' = SORT_NUMERIC --\n"; $temp_array = $unsorted_numerics; var_dump( sort($temp_array, SORT_NUMERIC) ); // expecting : bool(true) @@ -62,13 +81,23 @@ echo "Done\n"; -- Testing sort() by supplying string array, 'flag' value is defualt -- bool(true) -array(3) { +array(8) { [0]=> - string(6) "banana" + string(6) "Orange" [1]=> - string(5) "lemon" + string(7) "Orange1" [2]=> + string(7) "Orange3" + [3]=> + string(6) "banana" + [4]=> + string(5) "lemon" + [5]=> string(6) "orange" + [6]=> + string(7) "orange2" + [7]=> + string(8) "orange20" } -- Testing sort() by supplying numeric array, 'flag' value is defualt -- @@ -86,13 +115,23 @@ array(4) { -- Testing sort() by supplying string array, 'flag' = SORT_REGULAR -- bool(true) -array(3) { +array(8) { [0]=> - string(6) "banana" + string(6) "Orange" [1]=> - string(5) "lemon" + string(7) "Orange1" [2]=> + string(7) "Orange3" + [3]=> + string(6) "banana" + [4]=> + string(5) "lemon" + [5]=> string(6) "orange" + [6]=> + string(7) "orange2" + [7]=> + string(8) "orange20" } -- Testing sort() by supplying numeric array, 'flag' = SORT_REGULAR -- @@ -110,13 +149,86 @@ array(4) { -- Testing sort() by supplying string array, 'flag' = SORT_STRING -- bool(true) -array(3) { +array(8) { + [0]=> + string(6) "Orange" + [1]=> + string(7) "Orange1" + [2]=> + string(7) "Orange3" + [3]=> + string(6) "banana" + [4]=> + string(5) "lemon" + [5]=> + string(6) "orange" + [6]=> + string(7) "orange2" + [7]=> + string(8) "orange20" +} + +-- Testing sort() by supplying string array (case insensitive), 'flag' = SORT_STRING|SORT_FLAG_CASE -- +bool(true) +array(8) { [0]=> string(6) "banana" [1]=> string(5) "lemon" [2]=> string(6) "orange" + [3]=> + string(6) "Orange" + [4]=> + string(7) "Orange1" + [5]=> + string(7) "orange2" + [6]=> + string(8) "orange20" + [7]=> + string(7) "Orange3" +} + +-- Testing sort() by supplying string array (natural), 'flag' = SORT_NATURAL -- +bool(true) +array(8) { + [0]=> + string(6) "Orange" + [1]=> + string(7) "Orange1" + [2]=> + string(7) "Orange3" + [3]=> + string(6) "banana" + [4]=> + string(5) "lemon" + [5]=> + string(6) "orange" + [6]=> + string(7) "orange2" + [7]=> + string(8) "orange20" +} + +-- Testing sort() by supplying string array (natural, case insensitive), 'flag' = SORT_NATURAL|SORT_FLAG_CASE -- +bool(true) +array(8) { + [0]=> + string(6) "banana" + [1]=> + string(5) "lemon" + [2]=> + string(6) "orange" + [3]=> + string(6) "Orange" + [4]=> + string(7) "Orange1" + [5]=> + string(7) "orange2" + [6]=> + string(7) "Orange3" + [7]=> + string(8) "orange20" } -- Testing sort() by supplying numeric array, 'flag' = SORT_NUMERIC -- @@ -131,4 +243,4 @@ array(4) { [3]=> int(555) } -Done +Done \ No newline at end of file diff --git a/ext/standard/tests/array/sort_variation2.phpt b/ext/standard/tests/array/sort_variation2.phpt index 4304ecb7674e2..7cb8ed642a83a 100644 --- a/ext/standard/tests/array/sort_variation2.phpt +++ b/ext/standard/tests/array/sort_variation2.phpt @@ -106,9 +106,9 @@ array(3) { bool(true) array(3) { [0]=> - int(2) - [1]=> int(10) + [1]=> + int(2) [2]=> int(45) } From b0be27432422a16ab4b68de08761b0a6b33575d5 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 29 Aug 2011 20:24:09 +0000 Subject: [PATCH 0633/2394] - Zend engine part for bug #55158: Add SORT_NATURAL type to array_multisort (patch by Arpad Ray). --- Zend/zend_operators.c | 20 ++++++++++++++++++-- Zend/zend_operators.h | 2 ++ 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index 2f4905324c157..35a545145cdc7 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -1288,7 +1288,7 @@ ZEND_API int concat_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{ } /* }}} */ -ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ +ZEND_API int string_compare_function_ex(zval *result, zval *op1, zval *op2, zend_bool case_insensitive TSRMLS_DC) /* {{{ */ { zval op1_copy, op2_copy; int use_copy1 = 0, use_copy2 = 0; @@ -1307,7 +1307,11 @@ ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_D op2 = &op2_copy; } - ZVAL_LONG(result, zend_binary_zval_strcmp(op1, op2)); + if (case_insensitive) { + ZVAL_LONG(result, zend_binary_zval_strcasecmp(op1, op2)); + } else { + ZVAL_LONG(result, zend_binary_zval_strcmp(op1, op2)); + } if (use_copy1) { zval_dtor(op1); @@ -1319,6 +1323,18 @@ ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_D } /* }}} */ +ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ +{ + return string_compare_function_ex(result, op1, op2, 0); +} +/* }}} */ + +ZEND_API int string_case_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ +{ + return string_compare_function_ex(result, op1, op2, 1); +} +/* }}} */ + #if HAVE_STRCOLL ZEND_API int string_locale_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ { diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 9b0c790f8a1b1..fb0c39abc5b26 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -301,7 +301,9 @@ ZEND_API double zend_string_to_double(const char *number, zend_uint length); ZEND_API int zval_is_true(zval *op); ZEND_API int compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); ZEND_API int numeric_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); +ZEND_API int string_compare_function_ex(zval *result, zval *op1, zval *op2, zend_bool case_insensitive TSRMLS_DC); ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); +ZEND_API int string_case_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); #if HAVE_STRCOLL ZEND_API int string_locale_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC); #endif From 98b42d722de55313a0ce6cf5ae6b9ab68845db40 Mon Sep 17 00:00:00 2001 From: Arpad Ray Date: Mon, 29 Aug 2011 20:36:22 +0000 Subject: [PATCH 0634/2394] remove duplicate news entry --- NEWS | 2 -- 1 file changed, 2 deletions(-) diff --git a/NEWS b/NEWS index 3430cd939675f..9c4f389a80d3f 100644 --- a/NEWS +++ b/NEWS @@ -54,8 +54,6 @@ PHP NEWS one SAPI module the same time. FR #53271, FR #52410. (Jani) . Added optional argument to debug_backtrace() and debug_print_backtrace() to limit the amount of stack frames returned. (Sebastian, Patrick) - . Added support for SORT_NATURAL and SORT_FLAG_CASE in array sort functions: - sort, rsort, ksort, krsort, asort, arsort and array_multisort. Req #55158 (arpad) - Improved Zend Engine memory usage: (Dmitry) . Replaced zend_function.pass_rest_by_reference by From a912bd3c23ec6a5609cc3adc2ce69b467c34921c Mon Sep 17 00:00:00 2001 From: Arpad Ray Date: Mon, 29 Aug 2011 20:38:52 +0000 Subject: [PATCH 0635/2394] Fixed bug #55366: keys lost when using substr_replace an array --- ext/standard/string.c | 12 +++++++++++- .../tests/strings/substr_replace_array.phpt | 19 +++++++++++++++++++ 2 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 ext/standard/tests/strings/substr_replace_array.phpt diff --git a/ext/standard/string.c b/ext/standard/string.c index 62599d40196ce..dd43665525293 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -2398,6 +2398,10 @@ PHP_FUNCTION(substr_replace) RETURN_STRINGL(Z_STRVAL_PP(str), Z_STRLEN_PP(str), 1); } } else { /* str is array of strings */ + char *str_index = NULL; + uint str_index_len; + ulong num_index; + array_init(return_value); if (Z_TYPE_PP(from) == IS_ARRAY) { @@ -2533,7 +2537,13 @@ PHP_FUNCTION(substr_replace) } result[result_len] = '\0'; - add_next_index_stringl(return_value, result, result_len, 0); + + if (zend_hash_get_current_key_ex(Z_ARRVAL_PP(str), &str_index, &str_index_len, &num_index, 0, &pos_str) == HASH_KEY_IS_STRING) { + add_assoc_stringl_ex(return_value, str_index, str_index_len, result, result_len, 0); + } else { + add_index_stringl(return_value, num_index, result, result_len, 0); + } + if(Z_TYPE_PP(tmp_str) != IS_STRING) { zval_dtor(orig_str); } diff --git a/ext/standard/tests/strings/substr_replace_array.phpt b/ext/standard/tests/strings/substr_replace_array.phpt new file mode 100644 index 0000000000000..dbb8b1714701e --- /dev/null +++ b/ext/standard/tests/strings/substr_replace_array.phpt @@ -0,0 +1,19 @@ +--TEST-- +substr_replace() function - array +--FILE-- + 'llsskdkk','def' => 'llsskjkkdd', 4 => 'hello', 42 => 'world'); +$newarr = substr_replace($arr, 'zzz', 0, -2); + +print_r($newarr); + +?> +--EXPECTF-- +Array +( + [abc] => zzzkk + [def] => zzzdd + [4] => zzzlo + [42] => zzzld +) From 23b3468bc9e1f6a8c4eada6dc11e38122b568cdf Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 29 Aug 2011 20:50:33 +0000 Subject: [PATCH 0636/2394] Add missing session ini options "skeletons" until they become atleast documented --- php.ini-development | 7 +++++++ php.ini-production | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/php.ini-development b/php.ini-development index 6c38cc878f40c..522d06b801fc5 100644 --- a/php.ini-development +++ b/php.ini-development @@ -1557,6 +1557,13 @@ session.hash_bits_per_character = 5 ; http://php.net/url-rewriter.tags url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry" +;session.upload_progress.enabled = "1" +;session.upload_progress.cleanup = "1" +;session.upload_progress.prefix = "upload_progress_" +;session.upload_progress.name = "PHP_SESSION_UPLOAD_PROGRESS" +;session.upload_progress.freq = "1%" +;session.upload_progress.min_freq = "1" + [MSSQL] ; Allow or prevent persistent links. mssql.allow_persistent = On diff --git a/php.ini-production b/php.ini-production index d814d72ba227c..6890e85ded15e 100644 --- a/php.ini-production +++ b/php.ini-production @@ -1557,6 +1557,13 @@ session.hash_bits_per_character = 5 ; http://php.net/url-rewriter.tags url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry" +;session.upload_progress.enabled = "1" +;session.upload_progress.cleanup = "1" +;session.upload_progress.prefix = "upload_progress_" +;session.upload_progress.name = "PHP_SESSION_UPLOAD_PROGRESS" +;session.upload_progress.freq = "1%" +;session.upload_progress.min_freq = "1" + [MSSQL] ; Allow or prevent persistent links. mssql.allow_persistent = On From 53bfe7648949f64e90b2402d7ff5609a98cade51 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 29 Aug 2011 21:20:41 +0000 Subject: [PATCH 0637/2394] fixed bug #55267 - session_regenerate_id fails after header sent even if session.use_cookies = 0 --- ext/session/session.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/session/session.c b/ext/session/session.c index bc3b3487a08a7..89a3aca415c98 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -1670,7 +1670,7 @@ static PHP_FUNCTION(session_regenerate_id) return; } - if (SG(headers_sent)) { + if (SG(headers_sent) && PS(use_cookies)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot regenerate session id - headers already sent"); RETURN_FALSE; } From 1a2c15f912e05cbf673b9bfc091d77c857f5a31b Mon Sep 17 00:00:00 2001 From: Arpad Ray Date: Mon, 29 Aug 2011 21:29:26 +0000 Subject: [PATCH 0638/2394] Expose session status via new function, session_status (Req #52982) --- ext/session/session.c | 18 ++++++++++++++ ext/session/tests/session_status.phpt | 24 +++++++++++++++++++ .../tests/session_status_disabled.phpt | 17 +++++++++++++ 3 files changed, 59 insertions(+) create mode 100644 ext/session/tests/session_status.phpt create mode 100644 ext/session/tests/session_status_disabled.phpt diff --git a/ext/session/session.c b/ext/session/session.c index 89a3aca415c98..d511a462fe0d1 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -1830,6 +1830,18 @@ static PHP_FUNCTION(session_write_close) } /* }}} */ +/* {{{ proto int session_status(void) + Returns the current session status */ +static PHP_FUNCTION(session_status) +{ + if (zend_parse_parameters_none() == FAILURE) { + return; + } + + RETURN_LONG(PS(session_status)); +} +/* }}} */ + /* {{{ arginfo */ ZEND_BEGIN_ARG_INFO_EX(arginfo_session_name, 0, 0, 0) ZEND_ARG_INFO(0, name) @@ -1903,6 +1915,7 @@ static const zend_function_entry session_functions[] = { PHP_FE(session_set_cookie_params, arginfo_session_set_cookie_params) PHP_FE(session_get_cookie_params, arginfo_session_void) PHP_FE(session_write_close, arginfo_session_void) + PHP_FE(session_status, arginfo_session_void) PHP_FALIAS(session_commit, session_write_close, arginfo_session_void) PHP_FE_END }; @@ -2004,6 +2017,11 @@ static PHP_MINIT_FUNCTION(session) /* {{{ */ #endif php_session_rfc1867_orig_callback = php_rfc1867_callback; php_rfc1867_callback = php_session_rfc1867_callback; + + REGISTER_LONG_CONSTANT("PHP_SESSION_DISABLED", php_session_disabled, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("PHP_SESSION_NONE", php_session_none, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("PHP_SESSION_ACTIVE", php_session_active, CONST_CS | CONST_PERSISTENT); + return SUCCESS; } /* }}} */ diff --git a/ext/session/tests/session_status.phpt b/ext/session/tests/session_status.phpt new file mode 100644 index 0000000000000..d1f7e2f386516 --- /dev/null +++ b/ext/session/tests/session_status.phpt @@ -0,0 +1,24 @@ +--TEST-- +Test session_status() function : active, none +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +*** Testing session_status() : active, none +bool(true) +bool(true) +bool(true) diff --git a/ext/session/tests/session_status_disabled.phpt b/ext/session/tests/session_status_disabled.phpt new file mode 100644 index 0000000000000..24e0ecd7bf76d --- /dev/null +++ b/ext/session/tests/session_status_disabled.phpt @@ -0,0 +1,17 @@ +--TEST-- +Test session_status() function : disabled +--SKIPIF-- + +--INI-- +session.save_handler=non-existant +--FILE-- + +--EXPECTF-- +*** Testing session_status() : disabled +bool(true) From 88e36378ff1e89bbd2e10a6d7da8e5af58a8289f Mon Sep 17 00:00:00 2001 From: Arpad Ray Date: Mon, 29 Aug 2011 21:59:27 +0000 Subject: [PATCH 0639/2394] add friendly log messages (req #55109) --- php.ini-development | 4 + php.ini-production | 4 + sapi/cli/php_cli_server.c | 175 ++++++++++++++++++++++++++++++++++---- sapi/cli/php_cli_server.h | 10 +++ 4 files changed, 178 insertions(+), 15 deletions(-) diff --git a/php.ini-development b/php.ini-development index 522d06b801fc5..a0dad6431d3d5 100644 --- a/php.ini-development +++ b/php.ini-development @@ -898,6 +898,10 @@ default_socket_timeout = 60 ; Module Settings ; ;;;;;;;;;;;;;;;;;;; +[CLI Server] +; Whether the CLI web server uses ANSI color coding in its terminal output. +cli_server.color = On + [Date] ; Defines the default timezone used by the date functions ; http://php.net/date.timezone diff --git a/php.ini-production b/php.ini-production index 6890e85ded15e..37303cefb31c6 100644 --- a/php.ini-production +++ b/php.ini-production @@ -898,6 +898,10 @@ default_socket_timeout = 60 ; Module Settings ; ;;;;;;;;;;;;;;;;;;; +[CLI Server] +; Whether the CLI web server uses ANSI color coding in its terminal output. +cli_server.color = On + [Date] ; Defines the default timezone used by the date functions ; http://php.net/date.timezone diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index ff631ff87cdf0..65ed42d7d99cd 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -101,6 +101,11 @@ #include "php_network.h" #include "php_http_parser.h" +#include "php_cli_server.h" + +#define OUTPUT_NOT_CHECKED -1 +#define OUTPUT_IS_TTY 1 +#define OUTPUT_NOT_TTY 0 typedef struct php_cli_server_poller { fd_set rfds, wfds; @@ -260,10 +265,15 @@ static php_cli_server_ext_mime_type_pair mime_type_map[] = { { NULL, NULL } }; +static int php_cli_output_is_tty = OUTPUT_NOT_CHECKED; + static size_t php_cli_server_client_send_through(php_cli_server_client *client, const char *str, size_t str_len); static php_cli_server_chunk *php_cli_server_chunk_heap_new_self_contained(size_t len); static void php_cli_server_buffer_append(php_cli_server_buffer *buffer, php_cli_server_chunk *chunk); static void php_cli_server_logf(const char *format TSRMLS_DC, ...); +static void php_cli_server_log_response(php_cli_server_client *client, int status, const char *message TSRMLS_DC); + +ZEND_DECLARE_MODULE_GLOBALS(cli_server); static void char_ptr_dtor_p(char **p) /* {{{ */ { @@ -353,12 +363,55 @@ static const char *get_mime_type(const char *ext, size_t ext_len) /* {{{ */ return NULL; } /* }}} */ +/* {{{ cli_server module + */ + +static void cli_server_init_globals(zend_cli_server_globals *cg TSRMLS_DC) +{ + cg->color = 0; +} + +PHP_INI_BEGIN() + STD_PHP_INI_BOOLEAN("cli_server.color", "0", PHP_INI_ALL, OnUpdateBool, color, zend_cli_server_globals, cli_server_globals) +PHP_INI_END() + +static PHP_MINIT_FUNCTION(cli_server) +{ + ZEND_INIT_MODULE_GLOBALS(cli_server, cli_server_init_globals, NULL); + REGISTER_INI_ENTRIES(); + return SUCCESS; +} + +static PHP_MSHUTDOWN_FUNCTION(cli_server) +{ + UNREGISTER_INI_ENTRIES(); + return SUCCESS; +} + +static PHP_MINFO_FUNCTION(cli_server) +{ + DISPLAY_INI_ENTRIES(); +} + +zend_module_entry cli_server_module_entry = { + STANDARD_MODULE_HEADER, + "cli_server", + NULL, + PHP_MINIT(cli_server), + PHP_MSHUTDOWN(cli_server), + NULL, + NULL, + PHP_MINFO(cli_server), + PHP_VERSION, + STANDARD_MODULE_PROPERTIES +}; +/* }}} */ + static int sapi_cli_server_startup(sapi_module_struct *sapi_module) /* {{{ */ { - if (php_module_startup(sapi_module, NULL, 0) == FAILURE) { + if (php_module_startup(sapi_module, &cli_server_module_entry, 1) == FAILURE) { return FAILURE; } - return SUCCESS; } /* }}} */ @@ -901,20 +954,117 @@ static int php_cli_server_content_sender_pull(php_cli_server_content_sender *sen return 0; } /* }}} */ +#if HAVE_UNISTD_H +static int php_cli_is_output_tty() /* {{{ */ +{ + if (php_cli_output_is_tty == OUTPUT_NOT_CHECKED) { + php_cli_output_is_tty = isatty(STDOUT_FILENO); + } + return php_cli_output_is_tty; +} /* }}} */ +#endif + +static void php_cli_server_log_response(php_cli_server_client *client, int status, const char *message TSRMLS_DC) /* {{{ */ +{ + int color = 0, effective_status = status; + char *basic_buf, *message_buf = "", *error_buf = ""; + zend_bool append_error_message = 0; + + if (PG(last_error_message)) { + switch (PG(last_error_type)) { + case E_ERROR: + case E_CORE_ERROR: + case E_COMPILE_ERROR: + case E_USER_ERROR: + case E_PARSE: + if (status == 200) { + /* the status code isn't changed by a fatal error, so fake it */ + effective_status = 500; + } + + append_error_message = 1; + break; + } + } + +#if HAVE_UNISTD_H + if (CLI_SERVER_G(color) && php_cli_is_output_tty() == OUTPUT_IS_TTY) { + if (effective_status >= 500) { + /* server error: red */ + color = 1; + } else if (effective_status >= 400) { + /* client error: yellow */ + color = 3; + } else if (effective_status >= 200) { + /* success: green */ + color = 2; + } + } +#endif + + /* basic */ + spprintf(&basic_buf, 0, "%s [%d]: %s", client->addr_str, status, client->request.request_uri); + if (!basic_buf) { + return; + } + + /* message */ + if (message) { + spprintf(&message_buf, 0, " - %s", message); + if (!message_buf) { + efree(basic_buf); + return; + } + } + + /* error */ + if (append_error_message) { + spprintf(&error_buf, 0, " - %s in %s on line %d", PG(last_error_message), PG(last_error_file), PG(last_error_lineno)); + if (!error_buf) { + efree(basic_buf); + if (message) { + efree(message_buf); + } + return; + } + } + + if (color) { + php_cli_server_logf("\x1b[3%dm%s%s%s\x1b[0m" TSRMLS_CC, color, basic_buf, message_buf, error_buf); + } else { + php_cli_server_logf("%s%s%s" TSRMLS_CC, basic_buf, message_buf, error_buf); + } + + efree(basic_buf); + if (message) { + efree(message_buf); + } + if (append_error_message) { + efree(error_buf); + } +} /* }}} */ + static void php_cli_server_logf(const char *format TSRMLS_DC, ...) /* {{{ */ { - char buf[1024]; + char *buf = NULL; va_list ap; #ifdef ZTS va_start(ap, tsrm_ls); #else va_start(ap, format); #endif - vsnprintf(buf, sizeof(buf), format, ap); + vspprintf(&buf, 0, format, ap); va_end(ap); + + if (!buf) { + return; + } + if (sapi_module.log_message) { sapi_module.log_message(buf TSRMLS_CC); } + + efree(buf); } /* }}} */ static int php_network_listen_socket(const char *host, int *port, int socktype, int *af, socklen_t *socklen, char **errstr TSRMLS_DC) /* {{{ */ @@ -1511,6 +1661,7 @@ static int php_cli_server_send_error_page(php_cli_server *server, php_cli_server size_t escaped_request_uri_len; const char *status_string = get_status_string(status); const char *content_template = get_template_string(status); + char *errstr = get_last_error(); assert(status_string && content_template); php_cli_server_content_sender_ctor(&client->content_sender); @@ -1596,7 +1747,7 @@ static int php_cli_server_send_error_page(php_cli_server *server, php_cli_server php_cli_server_buffer_prepend(&client->content_sender.buffer, chunk); } - php_cli_server_logf("%s %s %s - Sending error page (%d)" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri, status); + php_cli_server_log_response(client, status, errstr ? errstr : "?" TSRMLS_CC); php_cli_server_poller_add(&server->poller, POLLOUT, client->sock); efree(escaped_request_uri); return SUCCESS; @@ -1638,8 +1789,7 @@ static int php_cli_server_dispatch_script(php_cli_server *server, php_cli_server } zend_end_try(); } - php_cli_server_logf("%s %s %s - Response sent successfully (%d)" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri, SG(sapi_headers).http_response_code); - + php_cli_server_log_response(client, SG(sapi_headers).http_response_code, NULL TSRMLS_CC); php_request_shutdown(0); php_cli_server_close_connection(server, client TSRMLS_CC); destroy_request_info(&SG(request_info)); @@ -1658,13 +1808,6 @@ static int php_cli_server_begin_send_static(php_cli_server *server, php_cli_serv fd = client->request.path_translated ? open(client->request.path_translated, O_RDONLY): -1; if (fd < 0) { - char *errstr = get_last_error(); - if (errstr) { - php_cli_server_logf("%s %s %s - %s" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri, errstr); - pefree(errstr, 1); - } else { - php_cli_server_logf("%s %s %s - ?" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri); - } return php_cli_server_send_error_page(server, client, 404 TSRMLS_CC); } @@ -1683,6 +1826,7 @@ static int php_cli_server_begin_send_static(php_cli_server *server, php_cli_serv append_http_status_line(&buffer, client->request.protocol_version, status, 1); if (!buffer.c) { /* out of memory */ + php_cli_server_log_response(client, 500, NULL TSRMLS_CC); return FAILURE; } append_essential_headers(&buffer, client, 1); @@ -1699,10 +1843,12 @@ static int php_cli_server_begin_send_static(php_cli_server *server, php_cli_serv chunk = php_cli_server_chunk_heap_new(buffer.c, buffer.c, buffer.len); if (!chunk) { smart_str_free_ex(&buffer, 1); + php_cli_server_log_response(client, 500, NULL TSRMLS_CC); return FAILURE; } php_cli_server_buffer_append(&client->content_sender.buffer, chunk); } + php_cli_server_log_response(client, 200, NULL TSRMLS_CC); php_cli_server_poller_add(&server->poller, POLLOUT, client->sock); return SUCCESS; } @@ -1939,7 +2085,6 @@ static int php_cli_server_recv_event_read_request(php_cli_server *server, php_cl php_cli_server_close_connection(server, client TSRMLS_CC); return FAILURE; } else if (status == 1) { - php_cli_server_logf("%s %s %s - Request read" TSRMLS_CC, client->addr_str, php_http_method_str(client->request.request_method), client->request.request_uri); php_cli_server_poller_remove(&server->poller, POLLIN, client->sock); php_cli_server_dispatch(server, client TSRMLS_CC); } else { diff --git a/sapi/cli/php_cli_server.h b/sapi/cli/php_cli_server.h index 8f9add0e5028c..7660f0a49fe3f 100644 --- a/sapi/cli/php_cli_server.h +++ b/sapi/cli/php_cli_server.h @@ -26,6 +26,16 @@ extern sapi_module_struct cli_server_sapi_module; extern int do_cli_server(int argc, char **argv TSRMLS_DC); +ZEND_BEGIN_MODULE_GLOBALS(cli_server) + short color; +ZEND_END_MODULE_GLOBALS(cli_server) + +#ifdef ZTS +#define CLI_SERVER_G(v) TSRMG(cli_server_globals_id, zend_cli_server_globals *, v) +#else +#define CLI_SERVER_G(v) (cli_server_globals.v) +#endif + #endif /* PHP_CLI_SERVER_H */ /* From 6affeb6b600bacd63a1249c22570bcee2aed9c4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Tue, 30 Aug 2011 01:08:22 +0000 Subject: [PATCH 0640/2394] - Turns out the external entity loader is not a per-thread global but a true global. Changed code accordingly; however, applications that embed PHP and also use libxml2 may be affected negatively. --- ext/libxml/libxml.c | 260 ++++++++++++++++++++-------------------- ext/libxml/php_libxml.h | 1 - 2 files changed, 131 insertions(+), 130 deletions(-) diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index 39f3ee2f11989..cd91570a9a37e 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -55,6 +55,7 @@ /* a true global for initialization */ static int _php_libxml_initialized = 0; static int _php_libxml_per_request_initialization = 1; +static xmlExternalEntityLoader _php_libxml_default_entity_loader; typedef struct _php_libxml_func_handler { php_libxml_export_node export_func; @@ -268,7 +269,6 @@ static PHP_GINIT_FUNCTION(libxml) libxml_globals->stream_context = NULL; libxml_globals->error_buffer.c = NULL; libxml_globals->error_list = NULL; - libxml_globals->defaultEntityLoader = NULL; libxml_globals->entity_loader.fci.size = 0; } @@ -549,6 +549,131 @@ static void php_libxml_internal_error_handler(int error_type, void *ctx, const c } } +static xmlParserInputPtr _php_libxml_external_entity_loader(const char *URL, + const char *ID, xmlParserCtxtPtr context) +{ + xmlParserInputPtr ret = NULL; + const char *resource = NULL; + zval *public = NULL, + *system = NULL, + *ctxzv = NULL, + **params[] = {&public, &system, &ctxzv}, + *retval_ptr = NULL; + int retval; + zend_fcall_info *fci; + TSRMLS_FETCH(); + + fci = &LIBXML(entity_loader).fci; + + if (fci->size == 0) { + /* no custom user-land callback set up; delegate to original loader */ + return _php_libxml_default_entity_loader(URL, ID, context); + } + + ALLOC_INIT_ZVAL(public); + if (ID != NULL) { + ZVAL_STRING(public, ID, 1); + } + ALLOC_INIT_ZVAL(system); + if (URL != NULL) { + ZVAL_STRING(system, URL, 1); + } + MAKE_STD_ZVAL(ctxzv); + array_init_size(ctxzv, 4); + +#define ADD_NULL_OR_STRING_KEY(memb) \ + if (context->memb == NULL) { \ + add_assoc_null_ex(ctxzv, #memb, sizeof(#memb)); \ + } else { \ + add_assoc_string_ex(ctxzv, #memb, sizeof(#memb), \ + (char *)context->memb, 1); \ + } + + ADD_NULL_OR_STRING_KEY(directory) + ADD_NULL_OR_STRING_KEY(intSubName) + ADD_NULL_OR_STRING_KEY(extSubURI) + ADD_NULL_OR_STRING_KEY(extSubSystem) + +#undef ADD_NULL_OR_STRING_KEY + + fci->retval_ptr_ptr = &retval_ptr; + fci->params = params; + fci->param_count = sizeof(params)/sizeof(*params); + fci->no_separation = 1; + + retval = zend_call_function(fci, &LIBXML(entity_loader).fcc TSRMLS_CC); + if (retval != SUCCESS || fci->retval_ptr_ptr == NULL) { + php_libxml_ctx_error(context, + "Call to user entity loader callback '%s' has failed", + fci->function_name); + } else { + retval_ptr = *fci->retval_ptr_ptr; + if (retval_ptr == NULL) { + php_libxml_ctx_error(context, + "Call to user entity loader callback '%s' has failed; " + "probably it has thrown an exception", + fci->function_name); + } else if (Z_TYPE_P(retval_ptr) == IS_STRING) { +is_string: + resource = Z_STRVAL_P(retval_ptr); + } else if (Z_TYPE_P(retval_ptr) == IS_RESOURCE) { + php_stream *stream; + php_stream_from_zval_no_verify(stream, &retval_ptr); + if (stream == NULL) { + php_libxml_ctx_error(context, + "The user entity loader callback '%s' has returned a " + "resource, but it is not a stream", + fci->function_name); + } else { + /* TODO: allow storing the encoding in the stream context? */ + xmlCharEncoding enc = XML_CHAR_ENCODING_NONE; + xmlParserInputBufferPtr pib = xmlAllocParserInputBuffer(enc); + if (pib == NULL) { + php_libxml_ctx_error(context, "Could not allocate parser " + "input buffer"); + } else { + /* make stream not being closed when the zval is freed */ + zend_list_addref(stream->rsrc_id); + pib->context = stream; + pib->readcallback = php_libxml_streams_IO_read; + pib->closecallback = php_libxml_streams_IO_close; + + ret = xmlNewIOInputStream(context, pib, enc); + if (ret == NULL) { + xmlFreeParserInputBuffer(pib); + } + } + } + } else if (Z_TYPE_P(retval_ptr) != IS_NULL) { + /* retval not string nor resource nor null; convert to string */ + SEPARATE_ZVAL(&retval_ptr); + convert_to_string(retval_ptr); + goto is_string; + } /* else is null; don't try anything */ + } + + if (ret == NULL) { + if (resource == NULL) { + if (ID == NULL) { + ID = "NULL"; + } + php_libxml_ctx_error(context, + "Failed to load external entity \"%s\"\n", ID); + } else { + /* we got the resource in the form of a string; open it */ + ret = xmlNewInputFromFile(context, resource); + } + } + + zval_ptr_dtor(&public); + zval_ptr_dtor(&system); + zval_ptr_dtor(&ctxzv); + if (retval_ptr != NULL) { + zval_ptr_dtor(&retval_ptr); + } + return ret; +} + PHP_LIBXML_API void php_libxml_ctx_error(void *ctx, const char *msg, ...) { va_list args; @@ -586,6 +711,9 @@ PHP_LIBXML_API void php_libxml_initialize(void) if (!_php_libxml_initialized) { /* we should be the only one's to ever init!! */ xmlInitParser(); + + _php_libxml_default_entity_loader = xmlGetExternalEntityLoader(); + xmlSetExternalEntityLoader(_php_libxml_external_entity_loader); zend_hash_init(&php_libxml_exports, 0, NULL, NULL, 1); @@ -926,126 +1054,6 @@ static PHP_FUNCTION(libxml_disable_entity_loader) } /* }}} */ -static xmlParserInputPtr _php_libxml_user_entity_loader(const char *URL, - const char *ID, xmlParserCtxtPtr context) -{ - xmlParserInputPtr ret = NULL; - const char *resource = NULL; - zval *public = NULL, - *system = NULL, - *ctxzv = NULL, - **params[] = {&public, &system, &ctxzv}, - *retval_ptr = NULL; - int retval; - zend_fcall_info *fci; - TSRMLS_FETCH(); - - fci = &LIBXML(entity_loader).fci; - - ALLOC_INIT_ZVAL(public); - if (ID != NULL) { - ZVAL_STRING(public, ID, 1); - } - ALLOC_INIT_ZVAL(system); - if (URL != NULL) { - ZVAL_STRING(system, URL, 1); - } - MAKE_STD_ZVAL(ctxzv); - array_init_size(ctxzv, 4); - -#define ADD_NULL_OR_STRING_KEY(memb) \ - if (context->memb == NULL) { \ - add_assoc_null_ex(ctxzv, #memb, sizeof(#memb)); \ - } else { \ - add_assoc_string_ex(ctxzv, #memb, sizeof(#memb), \ - (char *)context->memb, 1); \ - } - - ADD_NULL_OR_STRING_KEY(directory) - ADD_NULL_OR_STRING_KEY(intSubName) - ADD_NULL_OR_STRING_KEY(extSubURI) - ADD_NULL_OR_STRING_KEY(extSubSystem) - -#undef ADD_NULL_OR_STRING_KEY - - fci->retval_ptr_ptr = &retval_ptr; - fci->params = params; - fci->param_count = sizeof(params)/sizeof(*params); - fci->no_separation = 1; - - retval = zend_call_function(fci, &LIBXML(entity_loader).fcc TSRMLS_CC); - if (retval != SUCCESS || fci->retval_ptr_ptr == NULL) { - php_libxml_ctx_error(context, - "Call to user entity loader callback '%s' has failed", - fci->function_name); - } else { - retval_ptr = *fci->retval_ptr_ptr; - if (retval_ptr == NULL) { - php_libxml_ctx_error(context, - "Call to user entity loader callback '%s' has failed; " - "probably it has thrown an exception", - fci->function_name); - } else if (Z_TYPE_P(retval_ptr) == IS_STRING) { -is_string: - resource = Z_STRVAL_P(retval_ptr); - } else if (Z_TYPE_P(retval_ptr) == IS_RESOURCE) { - php_stream *stream; - php_stream_from_zval_no_verify(stream, &retval_ptr); - if (stream == NULL) { - php_libxml_ctx_error(context, - "The user entity loader callback '%s' has returned a " - "resource, but it is not a stream", - fci->function_name); - } else { - /* TODO: allow storing the encoding in the stream context? */ - xmlCharEncoding enc = XML_CHAR_ENCODING_NONE; - xmlParserInputBufferPtr pib = xmlAllocParserInputBuffer(enc); - if (pib == NULL) { - php_libxml_ctx_error(context, "Could not allocate parser " - "input buffer"); - } else { - /* make stream not being closed when the zval is freed */ - zend_list_addref(stream->rsrc_id); - pib->context = stream; - pib->readcallback = php_libxml_streams_IO_read; - pib->closecallback = php_libxml_streams_IO_close; - - ret = xmlNewIOInputStream(context, pib, enc); - if (ret == NULL) { - xmlFreeParserInputBuffer(pib); - } - } - } - } else if (Z_TYPE_P(retval_ptr) != IS_NULL) { - /* retval not string nor resource nor null; convert to string */ - SEPARATE_ZVAL(&retval_ptr); - convert_to_string(retval_ptr); - goto is_string; - } /* else is null; don't try anything */ - } - - if (ret == NULL) { - if (resource == NULL) { - if (ID == NULL) { - ID = "NULL"; - } - php_libxml_ctx_error(context, - "Failed to load external entity \"%s\"\n", ID); - } else { - /* we got the resource in the form of a string; open it */ - ret = xmlNewInputFromFile(context, resource); - } - } - - zval_ptr_dtor(&public); - zval_ptr_dtor(&system); - zval_ptr_dtor(&ctxzv); - if (retval_ptr != NULL) { - zval_ptr_dtor(&retval_ptr); - } - return ret; -} - /* {{{ proto void libxml_set_external_entity_loader(callback resolver_function) Changes the default external entity loader */ static PHP_FUNCTION(libxml_set_external_entity_loader) @@ -1057,21 +1065,15 @@ static PHP_FUNCTION(libxml_set_external_entity_loader) return; } + _php_libxml_destroy_fci(&LIBXML(entity_loader).fci); + if (fci.size > 0) { /* argument not null */ - /* save for later invocations with NULL */ - if (LIBXML(defaultEntityLoader) == NULL) { - LIBXML(defaultEntityLoader) = xmlGetExternalEntityLoader(); - } - _php_libxml_destroy_fci(&LIBXML(entity_loader).fci); LIBXML(entity_loader).fci = fci; Z_ADDREF_P(fci.function_name); if (fci.object_ptr != NULL) { Z_ADDREF_P(fci.object_ptr); } LIBXML(entity_loader).fcc = fcc; - xmlSetExternalEntityLoader(_php_libxml_user_entity_loader); - } else { - xmlSetExternalEntityLoader(LIBXML(defaultEntityLoader)); } RETURN_TRUE; diff --git a/ext/libxml/php_libxml.h b/ext/libxml/php_libxml.h index 8fe7fe4ad66a8..f1c8b7af69b61 100644 --- a/ext/libxml/php_libxml.h +++ b/ext/libxml/php_libxml.h @@ -43,7 +43,6 @@ ZEND_BEGIN_MODULE_GLOBALS(libxml) zval *stream_context; smart_str error_buffer; zend_llist *error_list; - xmlExternalEntityLoader defaultEntityLoader; /* saved here to allow it restored */ struct _php_libxml_entity_resolver { zend_fcall_info fci; zend_fcall_info_cache fcc; From cb74745d2fb5560e58579844d4f32272497801ac Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 30 Aug 2011 01:33:42 +0000 Subject: [PATCH 0641/2394] - Fixed ZTS build --- Zend/zend_operators.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index 35a545145cdc7..259d78005db12 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -1325,13 +1325,13 @@ ZEND_API int string_compare_function_ex(zval *result, zval *op1, zval *op2, zend ZEND_API int string_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ { - return string_compare_function_ex(result, op1, op2, 0); + return string_compare_function_ex(result, op1, op2, 0 TSRMLS_CC); } /* }}} */ ZEND_API int string_case_compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */ { - return string_compare_function_ex(result, op1, op2, 1); + return string_compare_function_ex(result, op1, op2, 1 TSRMLS_CC); } /* }}} */ From 361903fbce29dbc82842c0811757f476d41c1b22 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 30 Aug 2011 05:44:37 +0000 Subject: [PATCH 0642/2394] - ws --- ext/libxml/libxml.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index cd91570a9a37e..f488b38f425d4 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -236,9 +236,9 @@ static void php_libxml_node_free_list(xmlNodePtr node TSRMLS_DC) php_libxml_node_free_list((xmlNodePtr) node->properties TSRMLS_CC); break; case XML_ATTRIBUTE_NODE: - if ((node->doc != NULL) && (((xmlAttrPtr) node)->atype == XML_ATTRIBUTE_ID)) { - xmlRemoveID(node->doc, (xmlAttrPtr) node); - } + if ((node->doc != NULL) && (((xmlAttrPtr) node)->atype == XML_ATTRIBUTE_ID)) { + xmlRemoveID(node->doc, (xmlAttrPtr) node); + } case XML_ATTRIBUTE_DECL: case XML_DTD_NODE: case XML_DOCUMENT_TYPE_NODE: @@ -552,8 +552,8 @@ static void php_libxml_internal_error_handler(int error_type, void *ctx, const c static xmlParserInputPtr _php_libxml_external_entity_loader(const char *URL, const char *ID, xmlParserCtxtPtr context) { - xmlParserInputPtr ret = NULL; - const char *resource = NULL; + xmlParserInputPtr ret = NULL; + const char *resource = NULL; zval *public = NULL, *system = NULL, *ctxzv = NULL, @@ -647,7 +647,7 @@ static xmlParserInputPtr _php_libxml_external_entity_loader(const char *URL, } else if (Z_TYPE_P(retval_ptr) != IS_NULL) { /* retval not string nor resource nor null; convert to string */ SEPARATE_ZVAL(&retval_ptr); - convert_to_string(retval_ptr); + convert_to_string(retval_ptr); goto is_string; } /* else is null; don't try anything */ } @@ -671,7 +671,7 @@ static xmlParserInputPtr _php_libxml_external_entity_loader(const char *URL, if (retval_ptr != NULL) { zval_ptr_dtor(&retval_ptr); } - return ret; + return ret; } PHP_LIBXML_API void php_libxml_ctx_error(void *ctx, const char *msg, ...) From 3c1874143c0a75e098cc0db02328791d97af2ca8 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 30 Aug 2011 11:13:22 +0000 Subject: [PATCH 0643/2394] Fixed bug#55430, introduce the session.upload_progress family to the world --- php.ini-development | 42 ++++++++++++++++++++++++++++++++++++++++-- php.ini-production | 43 ++++++++++++++++++++++++++++++++++++++++--- 2 files changed, 80 insertions(+), 5 deletions(-) diff --git a/php.ini-development b/php.ini-development index a0dad6431d3d5..79895ecf2321c 100644 --- a/php.ini-development +++ b/php.ini-development @@ -1561,11 +1561,49 @@ session.hash_bits_per_character = 5 ; http://php.net/url-rewriter.tags url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry" -;session.upload_progress.enabled = "1" -;session.upload_progress.cleanup = "1" +; Enable upload procgress tracking in $_SESSION +; Default Value: On +; Development Value: On +; Production Value: On +; http://php.net/session.upload-progress.enabled +;session.upload_progress.enabled = On + +; Cleanup the progress information as soon as all POST data has been read +; (i.e. upload completed). +; Default Value: On +; Development Value: On +; Production Value: On +; http://php.net/session.upload-progress.cleanup +;session.upload_progress.cleanup = On + +; A prefix used for the upload progress key in $_SESSION +; Default Value: "upload_progress_" +; Development Value: "upload_progress_" +; Production Value: "upload_progress_" +; http://php.net/session.upload-progress.prefix ;session.upload_progress.prefix = "upload_progress_" + +; The index name (concatenated with the prefix) in $_SESSION +; containing the upload progress information +; Default Value: "PHP_SESSION_UPLOAD_PROGRESS" +; Development Value: "PHP_SESSION_UPLOAD_PROGRESS" +; Production Value: "PHP_SESSION_UPLOAD_PROGRESS" +; http://php.net/session.upload-progress.name ;session.upload_progress.name = "PHP_SESSION_UPLOAD_PROGRESS" + +; How frequently the upload progress should be updated. +; Given either in percentages (per-file), or in bytes +; Default Value: "1%" +; Development Value: "1%" +; Production Value: "1%" +; http://php.net/session.upload-progress.freq ;session.upload_progress.freq = "1%" + +; The minimum delay between updates, in seconds +; Default Value: 1 +; Development Value: 1 +; Production Value: 1 +; http://php.net/session.upload-progress.min-freq ;session.upload_progress.min_freq = "1" [MSSQL] diff --git a/php.ini-production b/php.ini-production index 37303cefb31c6..8a918e6fbe64f 100644 --- a/php.ini-production +++ b/php.ini-production @@ -1561,13 +1561,50 @@ session.hash_bits_per_character = 5 ; http://php.net/url-rewriter.tags url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry" -;session.upload_progress.enabled = "1" -;session.upload_progress.cleanup = "1" +; Enable upload procgress tracking in $_SESSION +; Default Value: On +; Development Value: On +; Production Value: On +; http://php.net/session.upload-progress.enabled +;session.upload_progress.enabled = On + +; Cleanup the progress information as soon as all POST data has been read +; (i.e. upload completed). +; Default Value: On +; Development Value: On +; Production Value: On +; http://php.net/session.upload-progress.cleanup +;session.upload_progress.cleanup = On + +; A prefix used for the upload progress key in $_SESSION +; Default Value: "upload_progress_" +; Development Value: "upload_progress_" +; Production Value: "upload_progress_" +; http://php.net/session.upload-progress.prefix ;session.upload_progress.prefix = "upload_progress_" + +; The index name (concatenated with the prefix) in $_SESSION +; containing the upload progress information +; Default Value: "PHP_SESSION_UPLOAD_PROGRESS" +; Development Value: "PHP_SESSION_UPLOAD_PROGRESS" +; Production Value: "PHP_SESSION_UPLOAD_PROGRESS" +; http://php.net/session.upload-progress.name ;session.upload_progress.name = "PHP_SESSION_UPLOAD_PROGRESS" + +; How frequently the upload progress should be updated. +; Given either in percentages (per-file), or in bytes +; Default Value: "1%" +; Development Value: "1%" +; Production Value: "1%" +; http://php.net/session.upload-progress.freq ;session.upload_progress.freq = "1%" -;session.upload_progress.min_freq = "1" +; The minimum delay between updates, in seconds +; Default Value: 1 +; Development Value: 1 +; Production Value: 1 +; http://php.net/session.upload-progress.min-freq +;session.upload_progress.min_freq = "1" [MSSQL] ; Allow or prevent persistent links. mssql.allow_persistent = On From 1f3536a019784a8565ca62431b5b71f83e87d3dc Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 30 Aug 2011 12:11:03 +0000 Subject: [PATCH 0644/2394] Fixed testing failed --- tests/basic/bug51709_1.phpt | 2 +- tests/basic/bug51709_2.phpt | 2 +- tests/lang/bug21820.phpt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/basic/bug51709_1.phpt b/tests/basic/bug51709_1.phpt index 19d298ad7d42d..e80e08ac73580 100644 --- a/tests/basic/bug51709_1.phpt +++ b/tests/basic/bug51709_1.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: syntax error, unexpected 'for' (T_FOR), expecting identifier (T_STRING) in %sbug51709_1.php on line %d +Parse error: syntax error, unexpected "for (T_FOR)", expecting "identifier (T_STRING)" in %sbug51709_1.php on line %d diff --git a/tests/basic/bug51709_2.phpt b/tests/basic/bug51709_2.phpt index c5e904df8307a..49b7fd28dad7e 100644 --- a/tests/basic/bug51709_2.phpt +++ b/tests/basic/bug51709_2.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: syntax error, unexpected 'goto' (T_GOTO), expecting identifier (T_STRING) in %sbug51709_2.php on line %d +Parse error: syntax error, unexpected "goto (T_GOTO)", expecting "identifier (T_STRING)" in %sbug51709_2.php on line %d diff --git a/tests/lang/bug21820.phpt b/tests/lang/bug21820.phpt index b862309e311c1..603416d9cdb93 100644 --- a/tests/lang/bug21820.phpt +++ b/tests/lang/bug21820.phpt @@ -10,4 +10,4 @@ echo "$arr['foo']"; ?> --EXPECTF-- -Parse error: syntax error, unexpected '' (T_ENCAPSED_AND_WHITESPACE), expecting identifier (T_STRING) or variable (T_VARIABLE) or number (T_NUM_STRING) in %sbug21820.php on line %d +Parse error: syntax error, unexpected "quoted-string and whitespace (T_ENCAPSED_AND_WHITESPACE)", expecting "identifier (T_STRING)" or "variable (T_VARIABLE)" or "number (T_NUM_STRING)" in %sbug21820.php on line %d From f41105f56faced00515af1dd348a2584afd3fbd4 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 30 Aug 2011 13:41:57 +0000 Subject: [PATCH 0645/2394] Fixed bug#48476 --- ext/date/php_date.c | 7 +++++++ ext/date/tests/bug48476.phpt | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 ext/date/tests/bug48476.phpt diff --git a/ext/date/php_date.c b/ext/date/php_date.c index c9a8465592bca..8cb289bef315b 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2045,6 +2045,9 @@ static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC) zend_object_value new_ov = date_object_new_date_ex(old_obj->std.ce, &new_obj TSRMLS_CC); zend_objects_clone_members(&new_obj->std, new_ov, &old_obj->std, Z_OBJ_HANDLE_P(this_ptr) TSRMLS_CC); + if (!old_obj->time) { + return new_ov; + } /* this should probably moved to a new `timelib_time *timelime_time_clone(timelib_time *)` */ new_obj->time = timelib_time_ctor(); @@ -2165,6 +2168,10 @@ static zend_object_value date_object_clone_timezone(zval *this_ptr TSRMLS_DC) zend_object_value new_ov = date_object_new_timezone_ex(old_obj->std.ce, &new_obj TSRMLS_CC); zend_objects_clone_members(&new_obj->std, new_ov, &old_obj->std, Z_OBJ_HANDLE_P(this_ptr) TSRMLS_CC); + if (!old_obj->initialized) { + return new_ov; + } + new_obj->type = old_obj->type; new_obj->initialized = 1; switch (new_obj->type) { diff --git a/ext/date/tests/bug48476.phpt b/ext/date/tests/bug48476.phpt new file mode 100644 index 0000000000000..4bf9503759e5f --- /dev/null +++ b/ext/date/tests/bug48476.phpt @@ -0,0 +1,33 @@ +--TEST-- +Bug#48476 (cloning extended DateTime class without calling parent::__constr crashed PHP) +--FILE-- +format("d")); +$x = clone $o; + +var_dump($x->format("d")); + +clone $o; + + +var_dump(timezone_location_get(clone new MyDateTimezone)); +?> +--EXPECTF-- +Warning: DateTime::format(): The DateTime object has not been correctly initialized by its constructor in %sbug48476.php on line 10 +bool(false) + +Warning: DateTime::format(): The DateTime object has not been correctly initialized by its constructor in %sbug48476.php on line 13 +bool(false) + +Warning: timezone_location_get(): The DateTimeZone object has not been correctly initialized by its constructor in %sbug48476.php on line 18 +bool(false) + + From eba373139c5cdc66b23f35b0a36915731be102aa Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 30 Aug 2011 13:46:24 +0000 Subject: [PATCH 0646/2394] Add skipifs for bug#54971 (patch by datibbaw@) --- ext/spl/tests/bug54971.phpt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/spl/tests/bug54971.phpt b/ext/spl/tests/bug54971.phpt index 166613b434e3e..07a4706274c14 100644 --- a/ext/spl/tests/bug54971.phpt +++ b/ext/spl/tests/bug54971.phpt @@ -1,5 +1,9 @@ --TEST-- Bug #54971 (Wrong result when using iterator_to_array with use_keys on true) +--SKIPIF-- + --FILE-- Date: Tue, 30 Aug 2011 14:01:03 +0000 Subject: [PATCH 0647/2394] Fixed a few false positives on gcov for ext/pgsql --- ext/pgsql/tests/09notice.phpt | 13 +++++++++++-- ext/pgsql/tests/22pg_fetch_object.phpt | 2 +- ext/pgsql/tests/80_bug32223.phpt | 7 +++++-- ext/pgsql/tests/80_bug32223b.phpt | 7 +++++-- ext/pgsql/tests/lcmess.inc | 21 +++++++++++++++++++++ ext/pgsql/tests/skipif.inc | 1 + 6 files changed, 44 insertions(+), 7 deletions(-) create mode 100644 ext/pgsql/tests/lcmess.inc diff --git a/ext/pgsql/tests/09notice.phpt b/ext/pgsql/tests/09notice.phpt index b7611b98c1145..316706916917f 100644 --- a/ext/pgsql/tests/09notice.phpt +++ b/ext/pgsql/tests/09notice.phpt @@ -1,16 +1,25 @@ --TEST-- PostgreSQL notice function --SKIPIF-- - + --INI-- pgsql.log_notice=1 pgsql.ignore_notices=0 --FILE-- diff --git a/ext/pgsql/tests/skipif.inc b/ext/pgsql/tests/skipif.inc index 74b27b3ad8e9b..7c5153e6f0822 100644 --- a/ext/pgsql/tests/skipif.inc +++ b/ext/pgsql/tests/skipif.inc @@ -7,6 +7,7 @@ // database include("config.inc"); +include("lcmess.inc"); if (!extension_loaded("pgsql")) { die("skip\n"); From 2459296ff50386b90df59d86a47599aeb2fb9d97 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 31 Aug 2011 04:24:48 +0000 Subject: [PATCH 0648/2394] fix tests --- ext/zlib/tests/gzencode_variation2.phpt | 2 +- ext/zlib/tests/ob_003.phpt | 6 ++---- ext/zlib/tests/ob_004.phpt | 5 ++--- ext/zlib/tests/ob_005.phpt | 3 ++- tests/security/open_basedir_linkinfo.phpt | 7 +++++-- tests/security/open_basedir_readlink.phpt | 6 ++---- 6 files changed, 14 insertions(+), 15 deletions(-) diff --git a/ext/zlib/tests/gzencode_variation2.phpt b/ext/zlib/tests/gzencode_variation2.phpt index e6fe7dd65cb5e..3234ccf395de5 100644 --- a/ext/zlib/tests/gzencode_variation2.phpt +++ b/ext/zlib/tests/gzencode_variation2.phpt @@ -1,7 +1,7 @@ --TEST-- Test gzencode() function : variation - verify header contents with all encoding modes --XFAIL-- -Test will fail until bug #47178 resolved; missing gzip headers whne FORCE_DEFLATE specified +Test will fail until bug #47178 resolved; missing gzip headers when FORCE_DEFLATE specified --SKIPIF-- --EXPECTF-- -%s +‹%s +--EXPECTHEADERS-- Content-Encoding: gzip Vary: Accept-Encoding -%s - -‹%s diff --git a/ext/zlib/tests/ob_004.phpt b/ext/zlib/tests/ob_004.phpt index 3d3be9df7be81..f5e6af552be71 100644 --- a/ext/zlib/tests/ob_004.phpt +++ b/ext/zlib/tests/ob_004.phpt @@ -17,9 +17,8 @@ ob_start("ob_gzhandler"); echo "hi\n"; ?> --EXPECTF-- -%s +‹%s +--EXPECTHEADERS-- Content-Encoding: gzip Vary: Accept-Encoding -%s -‹%s diff --git a/ext/zlib/tests/ob_005.phpt b/ext/zlib/tests/ob_005.phpt index c266cb71f3bf6..19793936f9009 100644 --- a/ext/zlib/tests/ob_005.phpt +++ b/ext/zlib/tests/ob_005.phpt @@ -18,4 +18,5 @@ ini_set("zlib.output_compression", 0); echo "hi\n"; ?> --EXPECTF-- -%shi +hi +--EXPECTHEADERS-- diff --git a/tests/security/open_basedir_linkinfo.phpt b/tests/security/open_basedir_linkinfo.phpt index ecbb00f74d43b..f8be45305e821 100644 --- a/tests/security/open_basedir_linkinfo.phpt +++ b/tests/security/open_basedir_linkinfo.phpt @@ -6,10 +6,13 @@ if (substr(PHP_OS, 0, 3) == 'WIN') { die('skip no symlinks on Windows'); } ?> ---INI-- -open_basedir=. +--XFAIL-- +BUG: open_basedir cannot delete symlink to prohibited file. See also +bugs 48111 and 52176. --FILE-- ---INI-- -open_basedir=. --FILE-- @@ -69,6 +68,5 @@ bool(false) Warning: readlink(): open_basedir restriction in effect. File(%s/test/ok/symlink.txt) is not within the allowed path(s): (.) in %s on line %d bool(false) -bool(true) *** Finished testing open_basedir configuration [readlink] *** From 1a9d43a807ae7176c4490c083d23f86845c62905 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 31 Aug 2011 05:45:02 +0000 Subject: [PATCH 0649/2394] - Less GCC warnings; code less readable, yay! - Fixed html_tables.h generaration in 64-bit archs. - Closes bug #55394 - Patch to suppress initialization warnings in html.c #signed/unsigned mismatches for another day #regenerated tables on another commit --- ext/standard/html.c | 12 ++-- ext/standard/html_tables/html_table_gen.php | 74 ++++++++++----------- 2 files changed, 43 insertions(+), 43 deletions(-) diff --git a/ext/standard/html.c b/ext/standard/html.c index 56b33d4fafd54..b9b4a977a7a9e 100644 --- a/ext/standard/html.c +++ b/ext/standard/html.c @@ -271,7 +271,7 @@ static inline unsigned int get_next_char( MB_FAILURE(pos, 2); } pos += 2; - } else if (c < 0x80 || c >= 0xA1 && c <= 0xDF) { + } else if (c < 0x80 || (c >= 0xA1 && c <= 0xDF)) { this_char = c; pos += 1; } else { @@ -787,8 +787,8 @@ static inline int process_numeric_entity(const char **buf, unsigned *code_point) /* strtol allows whitespace and other stuff in the beginning * we're not interested */ - if (hexadecimal && !isxdigit(**buf) || - !hexadecimal && !isdigit(**buf)) { + if ((hexadecimal && !isxdigit(**buf)) || + (!hexadecimal && !isdigit(**buf))) { return FAILURE; } @@ -821,9 +821,9 @@ static inline int process_named_entity_html(const char **buf, const char **start * sequence of 8-bit code units. If in the ranges below, it represents * necessarily a alpha character because none of the supported encodings * has an overlap with ASCII in the leading byte (only on the second one) */ - while (**buf >= 'a' && **buf <= 'z' || - **buf >= 'A' && **buf <= 'Z' || - **buf >= '0' && **buf <= '9') { + while ((**buf >= 'a' && **buf <= 'z') || + (**buf >= 'A' && **buf <= 'Z') || + (**buf >= '0' && **buf <= '9')) { (*buf)++; } diff --git a/ext/standard/html_tables/html_table_gen.php b/ext/standard/html_tables/html_table_gen.php index 05997f03754b3..7e7314fa3564f 100644 --- a/ext/standard/html_tables/html_table_gen.php +++ b/ext/standard/html_tables/html_table_gen.php @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2010 The PHP Group | + | Copyright (c) 1997-%s The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -119,7 +119,7 @@ enum entity_charset charset; CODE; -echo $t; +echo sprintf($t, date("Y")); $encodings = array( array( @@ -213,7 +213,7 @@ enum entity_charset charset; $s2tables_idents[$i] = $e["ident"]; echo "static const enc_to_uni_stage2 enc_to_uni_s2_{$e['ident']}_". - sprintf("%02X", $i << 6)." = {\n"; + sprintf("%02X", $i << 6)." = { {\n"; for ($j = 0; $j < 64; $j++) { if ($j == 0) echo "\t"; elseif ($j % 6 == 0) echo "\n\t"; @@ -223,7 +223,7 @@ enum entity_charset charset; else echo "0xFFFF,"; /* special value; indicates no mapping */ } - echo "\n};\n\n"; + echo "\n} };\n\n"; $prevStage2[] = $mstable[$i]; } @@ -235,11 +235,11 @@ enum entity_charset charset; "/* {{{ Stage 1 table for {$e['name']} */\n"; echo -"static const enc_to_uni enc_to_uni_{$e['ident']} = { +"static const enc_to_uni enc_to_uni_{$e['ident']} = { { \t&enc_to_uni_s2_{$s2tables_idents[0]}_00, \t&enc_to_uni_s2_{$s2tables_idents[1]}_40, \t&enc_to_uni_s2_{$s2tables_idents[2]}_80, -\t&enc_to_uni_s2_{$s2tables_idents[3]}_C0, +\t&enc_to_uni_s2_{$s2tables_idents[3]}_C0 } }; "; @@ -471,17 +471,17 @@ enum entity_charset charset; if (key_exists("default", $v)) { if ($v['default'] == 'GT') /* hack to make > translate to > not GT; */ $v['default'] = "gt"; - echo "\t{", sprintf("%02d", count($v) - 1), + echo "\t{ {", sprintf("%02d", count($v) - 1), ",\t\t", sprintf("\"%-21s", $v["default"].'",'), "\t", - sprintf("% 2d", strlen($v["default"])), '},', "\n"; + sprintf("% 2d", strlen($v["default"])), '} },', "\n"; } else { - echo "\t{", sprintf("%02d", count($v)), - ",\t\t", sprintf("%-22s", 'NULL'), ",\t0},\n"; + echo "\t{ {", sprintf("%02d", count($v)), + ",\t\t", sprintf("%-22s", 'NULL'), ",\t0} },\n"; } unset($v["default"]); foreach ($v as $l => $w) { - echo "\t{", sprintf("0x%05s", $l), ",\t", sprintf("\"%-21s", $w.'",'), "\t", - sprintf("% 2d", strlen($w)), '},', "\n"; + echo "\t{ {", sprintf("0x%05s", $l), ",\t", sprintf("\"%-21s", $w.'",'), "\t", + sprintf("% 2d", strlen($w)), '} },', "\n"; } echo "};\n"; } @@ -495,22 +495,22 @@ enum entity_charset charset; $t = << 0; $nKeyLength--) { - $hash = (int)(((int)(((int)($hash << 5)) + $hash)) + ord($str[$pos++])); + $hash = (int)(((int)(((int)($hash << 5)) + $hash)) + ord($str[$pos++])) + & 0xFFFFFFFF; } return $hash; @@ -762,7 +762,7 @@ function hashfun($str) $h[0], strlen($h[0]), hexdec($h[1])); } } - echo " {NULL} };\n"; + echo " {NULL, 0, 0, 0} };\n"; } echo "\n"; From f0abb3619293f415f2efa867437ca45f4c8e1fff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 31 Aug 2011 05:47:19 +0000 Subject: [PATCH 0650/2394] - html_tables.h regeneration. --- ext/standard/html_tables.h | 6648 ++++++++++++++++++------------------ 1 file changed, 3324 insertions(+), 3324 deletions(-) diff --git a/ext/standard/html_tables.h b/ext/standard/html_tables.h index 278b6db428b19..cc776b22b81f3 100644 --- a/ext/standard/html_tables.h +++ b/ext/standard/html_tables.h @@ -97,7 +97,7 @@ typedef struct { /* {{{ Stage 2 tables for ISO-8859-1 */ -static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_00 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_00 = { { 0x0000, 0x0001, 0x0002, 0x0003, 0x0004, 0x0005, 0x0006, 0x0007, 0x0008, 0x0009, 0x000A, 0x000B, 0x000C, 0x000D, 0x000E, 0x000F, 0x0010, 0x0011, @@ -109,9 +109,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_00 = { 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003A, 0x003B, 0x003C, 0x003D, 0x003E, 0x003F, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_40 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_40 = { { 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004A, 0x004B, 0x004C, 0x004D, 0x004E, 0x004F, 0x0050, 0x0051, @@ -123,9 +123,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_40 = { 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007A, 0x007B, 0x007C, 0x007D, 0x007E, 0x007F, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_80 = { { 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008A, 0x008B, 0x008C, 0x008D, 0x008E, 0x008F, 0x0090, 0x0091, @@ -137,9 +137,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_80 = { 0x00B0, 0x00B1, 0x00B2, 0x00B3, 0x00B4, 0x00B5, 0x00B6, 0x00B7, 0x00B8, 0x00B9, 0x00BA, 0x00BB, 0x00BC, 0x00BD, 0x00BE, 0x00BF, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_C0 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_C0 = { { 0x00C0, 0x00C1, 0x00C2, 0x00C3, 0x00C4, 0x00C5, 0x00C6, 0x00C7, 0x00C8, 0x00C9, 0x00CA, 0x00CB, 0x00CC, 0x00CD, 0x00CE, 0x00CF, 0x00D0, 0x00D1, @@ -151,16 +151,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso88591_C0 = { 0x00F0, 0x00F1, 0x00F2, 0x00F3, 0x00F4, 0x00F5, 0x00F6, 0x00F7, 0x00F8, 0x00F9, 0x00FA, 0x00FB, 0x00FC, 0x00FD, 0x00FE, 0x00FF, -}; +} }; /* end of stage 2 tables for ISO-8859-1 }}} */ /* {{{ Stage 1 table for ISO-8859-1 */ -static const enc_to_uni enc_to_uni_iso88591 = { +static const enc_to_uni enc_to_uni_iso88591 = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_iso88591_80, - &enc_to_uni_s2_iso88591_C0, + &enc_to_uni_s2_iso88591_C0 } }; /* end of stage 1 table for ISO-8859-1 }}} */ @@ -168,7 +168,7 @@ static const enc_to_uni enc_to_uni_iso88591 = { /* {{{ Stage 2 tables for ISO-8859-5 */ -static const enc_to_uni_stage2 enc_to_uni_s2_iso88595_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso88595_80 = { { 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008A, 0x008B, 0x008C, 0x008D, 0x008E, 0x008F, 0x0090, 0x0091, @@ -180,9 +180,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso88595_80 = { 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, 0x0418, 0x0419, 0x041A, 0x041B, 0x041C, 0x041D, 0x041E, 0x041F, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_iso88595_C0 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso88595_C0 = { { 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, 0x0428, 0x0429, 0x042A, 0x042B, 0x042C, 0x042D, 0x042E, 0x042F, 0x0430, 0x0431, @@ -194,16 +194,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso88595_C0 = { 0x2116, 0x0451, 0x0452, 0x0453, 0x0454, 0x0455, 0x0456, 0x0457, 0x0458, 0x0459, 0x045A, 0x045B, 0x045C, 0x00A7, 0x045E, 0x045F, -}; +} }; /* end of stage 2 tables for ISO-8859-5 }}} */ /* {{{ Stage 1 table for ISO-8859-5 */ -static const enc_to_uni enc_to_uni_iso88595 = { +static const enc_to_uni enc_to_uni_iso88595 = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_iso88595_80, - &enc_to_uni_s2_iso88595_C0, + &enc_to_uni_s2_iso88595_C0 } }; /* end of stage 1 table for ISO-8859-5 }}} */ @@ -211,7 +211,7 @@ static const enc_to_uni enc_to_uni_iso88595 = { /* {{{ Stage 2 tables for ISO-8859-15 */ -static const enc_to_uni_stage2 enc_to_uni_s2_iso885915_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_iso885915_80 = { { 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, 0x0089, 0x008A, 0x008B, 0x008C, 0x008D, 0x008E, 0x008F, 0x0090, 0x0091, @@ -223,16 +223,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_iso885915_80 = { 0x00B0, 0x00B1, 0x00B2, 0x00B3, 0x017D, 0x00B5, 0x00B6, 0x00B7, 0x017E, 0x00B9, 0x00BA, 0x00BB, 0x0152, 0x0153, 0x0178, 0x00BF, -}; +} }; /* end of stage 2 tables for ISO-8859-15 }}} */ /* {{{ Stage 1 table for ISO-8859-15 */ -static const enc_to_uni enc_to_uni_iso885915 = { +static const enc_to_uni enc_to_uni_iso885915 = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_iso885915_80, - &enc_to_uni_s2_iso88591_C0, + &enc_to_uni_s2_iso88591_C0 } }; /* end of stage 1 table for ISO-8859-15 }}} */ @@ -240,7 +240,7 @@ static const enc_to_uni enc_to_uni_iso885915 = { /* {{{ Stage 2 tables for Windows-1252 */ -static const enc_to_uni_stage2 enc_to_uni_s2_win1252_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_win1252_80 = { { 0x20AC, 0xFFFF, 0x201A, 0x0192, 0x201E, 0x2026, 0x2020, 0x2021, 0x02C6, 0x2030, 0x0160, 0x2039, 0x0152, 0xFFFF, 0x017D, 0xFFFF, 0xFFFF, 0x2018, @@ -252,16 +252,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_win1252_80 = { 0x00B0, 0x00B1, 0x00B2, 0x00B3, 0x00B4, 0x00B5, 0x00B6, 0x00B7, 0x00B8, 0x00B9, 0x00BA, 0x00BB, 0x00BC, 0x00BD, 0x00BE, 0x00BF, -}; +} }; /* end of stage 2 tables for Windows-1252 }}} */ /* {{{ Stage 1 table for Windows-1252 */ -static const enc_to_uni enc_to_uni_win1252 = { +static const enc_to_uni enc_to_uni_win1252 = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_win1252_80, - &enc_to_uni_s2_iso88591_C0, + &enc_to_uni_s2_iso88591_C0 } }; /* end of stage 1 table for Windows-1252 }}} */ @@ -269,7 +269,7 @@ static const enc_to_uni enc_to_uni_win1252 = { /* {{{ Stage 2 tables for Windows-1251 */ -static const enc_to_uni_stage2 enc_to_uni_s2_win1251_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_win1251_80 = { { 0x0402, 0x0403, 0x201A, 0x0453, 0x201E, 0x2026, 0x2020, 0x2021, 0x20AC, 0x2030, 0x0409, 0x2039, 0x040A, 0x040C, 0x040B, 0x040F, 0x0452, 0x2018, @@ -281,9 +281,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_win1251_80 = { 0x00B0, 0x00B1, 0x0406, 0x0456, 0x0491, 0x00B5, 0x00B6, 0x00B7, 0x0451, 0x2116, 0x0454, 0x00BB, 0x0458, 0x0405, 0x0455, 0x0457, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_win1251_C0 = { +static const enc_to_uni_stage2 enc_to_uni_s2_win1251_C0 = { { 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, 0x0418, 0x0419, 0x041A, 0x041B, 0x041C, 0x041D, 0x041E, 0x041F, 0x0420, 0x0421, @@ -295,16 +295,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_win1251_C0 = { 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, 0x0448, 0x0449, 0x044A, 0x044B, 0x044C, 0x044D, 0x044E, 0x044F, -}; +} }; /* end of stage 2 tables for Windows-1251 }}} */ /* {{{ Stage 1 table for Windows-1251 */ -static const enc_to_uni enc_to_uni_win1251 = { +static const enc_to_uni enc_to_uni_win1251 = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_win1251_80, - &enc_to_uni_s2_win1251_C0, + &enc_to_uni_s2_win1251_C0 } }; /* end of stage 1 table for Windows-1251 }}} */ @@ -312,7 +312,7 @@ static const enc_to_uni enc_to_uni_win1251 = { /* {{{ Stage 2 tables for KOI8-R */ -static const enc_to_uni_stage2 enc_to_uni_s2_koi8r_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_koi8r_80 = { { 0x2500, 0x2502, 0x250C, 0x2510, 0x2514, 0x2518, 0x251C, 0x2524, 0x252C, 0x2534, 0x253C, 0x2580, 0x2584, 0x2588, 0x258C, 0x2590, 0x2591, 0x2592, @@ -324,9 +324,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_koi8r_80 = { 0x255F, 0x2560, 0x2561, 0x0401, 0x2562, 0x2563, 0x2564, 0x2565, 0x2566, 0x2567, 0x2568, 0x2569, 0x256A, 0x256B, 0x256C, 0x00A9, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_koi8r_C0 = { +static const enc_to_uni_stage2 enc_to_uni_s2_koi8r_C0 = { { 0x044E, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, 0x0445, 0x0438, 0x0439, 0x043A, 0x043B, 0x043C, 0x043D, 0x043E, 0x043F, 0x044F, @@ -338,16 +338,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_koi8r_C0 = { 0x041F, 0x042F, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, 0x042C, 0x042B, 0x0417, 0x0428, 0x042D, 0x0429, 0x0427, 0x042A, -}; +} }; /* end of stage 2 tables for KOI8-R }}} */ /* {{{ Stage 1 table for KOI8-R */ -static const enc_to_uni enc_to_uni_koi8r = { +static const enc_to_uni enc_to_uni_koi8r = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_koi8r_80, - &enc_to_uni_s2_koi8r_C0, + &enc_to_uni_s2_koi8r_C0 } }; /* end of stage 1 table for KOI8-R }}} */ @@ -355,7 +355,7 @@ static const enc_to_uni enc_to_uni_koi8r = { /* {{{ Stage 2 tables for CP-866 */ -static const enc_to_uni_stage2 enc_to_uni_s2_cp866_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_cp866_80 = { { 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, 0x0418, 0x0419, 0x041A, 0x041B, 0x041C, 0x041D, 0x041E, 0x041F, 0x0420, 0x0421, @@ -367,9 +367,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_cp866_80 = { 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, 0x2555, 0x2563, 0x2551, 0x2557, 0x255D, 0x255C, 0x255B, 0x2510, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_cp866_C0 = { +static const enc_to_uni_stage2 enc_to_uni_s2_cp866_C0 = { { 0x2514, 0x2534, 0x252C, 0x251C, 0x2500, 0x253C, 0x255E, 0x255F, 0x255A, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256C, 0x2567, 0x2568, 0x2564, @@ -381,16 +381,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_cp866_C0 = { 0x0401, 0x0451, 0x0404, 0x0454, 0x0407, 0x0457, 0x040E, 0x045E, 0x00B0, 0x2219, 0x00B7, 0x221A, 0x2116, 0x00A4, 0x25A0, 0x00A0, -}; +} }; /* end of stage 2 tables for CP-866 }}} */ /* {{{ Stage 1 table for CP-866 */ -static const enc_to_uni enc_to_uni_cp866 = { +static const enc_to_uni enc_to_uni_cp866 = { { &enc_to_uni_s2_iso88591_00, &enc_to_uni_s2_iso88591_40, &enc_to_uni_s2_cp866_80, - &enc_to_uni_s2_cp866_C0, + &enc_to_uni_s2_cp866_C0 } }; /* end of stage 1 table for CP-866 }}} */ @@ -398,7 +398,7 @@ static const enc_to_uni enc_to_uni_cp866 = { /* {{{ Stage 2 tables for MacRoman */ -static const enc_to_uni_stage2 enc_to_uni_s2_macroman_00 = { +static const enc_to_uni_stage2 enc_to_uni_s2_macroman_00 = { { 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF, @@ -410,9 +410,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_macroman_00 = { 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x003A, 0x003B, 0x003C, 0x003D, 0x003E, 0x003F, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_macroman_40 = { +static const enc_to_uni_stage2 enc_to_uni_s2_macroman_40 = { { 0x0040, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004A, 0x004B, 0x004C, 0x004D, 0x004E, 0x004F, 0x0050, 0x0051, @@ -424,9 +424,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_macroman_40 = { 0x0070, 0x0071, 0x0072, 0x0073, 0x0074, 0x0075, 0x0076, 0x0077, 0x0078, 0x0079, 0x007A, 0x007B, 0x007C, 0x007D, 0x007E, 0xFFFF, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_macroman_80 = { +static const enc_to_uni_stage2 enc_to_uni_s2_macroman_80 = { { 0x00C4, 0x00C5, 0x00C7, 0x00C9, 0x00D1, 0x00D6, 0x00DC, 0x00E1, 0x00E0, 0x00E2, 0x00E4, 0x00E3, 0x00E5, 0x00E7, 0x00E9, 0x00E8, 0x00EA, 0x00EB, @@ -438,9 +438,9 @@ static const enc_to_uni_stage2 enc_to_uni_s2_macroman_80 = { 0x221E, 0x00B1, 0x2264, 0x2265, 0x00A5, 0x00B5, 0x2202, 0x2211, 0x220F, 0x03C0, 0x222B, 0x00AA, 0x00BA, 0x03A9, 0x00E6, 0x00F8, -}; +} }; -static const enc_to_uni_stage2 enc_to_uni_s2_macroman_C0 = { +static const enc_to_uni_stage2 enc_to_uni_s2_macroman_C0 = { { 0x00BF, 0x00A1, 0x00AC, 0x221A, 0x0192, 0x2248, 0x2206, 0x00AB, 0x00BB, 0x2026, 0x00A0, 0x00C0, 0x00C3, 0x00D5, 0x0152, 0x0153, 0x2013, 0x2014, @@ -452,16 +452,16 @@ static const enc_to_uni_stage2 enc_to_uni_s2_macroman_C0 = { 0xF8FF, 0x00D2, 0x00DA, 0x00DB, 0x00D9, 0x0131, 0x02C6, 0x02DC, 0x00AF, 0x02D8, 0x02D9, 0x02DA, 0x00B8, 0x02DD, 0x02DB, 0x02C7, -}; +} }; /* end of stage 2 tables for MacRoman }}} */ /* {{{ Stage 1 table for MacRoman */ -static const enc_to_uni enc_to_uni_macroman = { +static const enc_to_uni enc_to_uni_macroman = { { &enc_to_uni_s2_macroman_00, &enc_to_uni_s2_macroman_40, &enc_to_uni_s2_macroman_80, - &enc_to_uni_s2_macroman_C0, + &enc_to_uni_s2_macroman_C0 } }; /* end of stage 1 table for MacRoman }}} */ @@ -1142,258 +1142,258 @@ typedef struct { /* {{{ Start of double code point tables for HTML5 */ static const entity_multicodepoint_row multi_cp_html5_0003C[] = { - {01, "lt", 2}, - {0x020D2, "nvlt", 4}, + { {01, "lt", 2} }, + { {0x020D2, "nvlt", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_0003D[] = { - {01, "equals", 6}, - {0x020E5, "bne", 3}, + { {01, "equals", 6} }, + { {0x020E5, "bne", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_0003E[] = { - {01, "gt", 2}, - {0x020D2, "nvgt", 4}, + { {01, "gt", 2} }, + { {0x020D2, "nvgt", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_00066[] = { - {01, NULL , 0}, - {0x0006A, "fjlig", 5}, + { {01, NULL , 0} }, + { {0x0006A, "fjlig", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_0205F[] = { - {01, "MediumSpace", 11}, - {0x0200A, "ThickSpace", 10}, + { {01, "MediumSpace", 11} }, + { {0x0200A, "ThickSpace", 10} }, }; static const entity_multicodepoint_row multi_cp_html5_0219D[] = { - {01, "rarrw", 5}, - {0x00338, "nrarrw", 6}, + { {01, "rarrw", 5} }, + { {0x00338, "nrarrw", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_02202[] = { - {01, "part", 4}, - {0x00338, "npart", 5}, + { {01, "part", 4} }, + { {0x00338, "npart", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_02220[] = { - {01, "angle", 5}, - {0x020D2, "nang", 4}, + { {01, "angle", 5} }, + { {0x020D2, "nang", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_02229[] = { - {01, "cap", 3}, - {0x0FE00, "caps", 4}, + { {01, "cap", 3} }, + { {0x0FE00, "caps", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_0222A[] = { - {01, "cup", 3}, - {0x0FE00, "cups", 4}, + { {01, "cup", 3} }, + { {0x0FE00, "cups", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_0223C[] = { - {01, "sim", 3}, - {0x020D2, "nvsim", 5}, + { {01, "sim", 3} }, + { {0x020D2, "nvsim", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_0223D[] = { - {01, "bsim", 4}, - {0x00331, "race", 4}, + { {01, "bsim", 4} }, + { {0x00331, "race", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_0223E[] = { - {01, "ac", 2}, - {0x00333, "acE", 3}, + { {01, "ac", 2} }, + { {0x00333, "acE", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_02242[] = { - {01, "esim", 4}, - {0x00338, "nesim", 5}, + { {01, "esim", 4} }, + { {0x00338, "nesim", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_0224B[] = { - {01, "apid", 4}, - {0x00338, "napid", 5}, + { {01, "apid", 4} }, + { {0x00338, "napid", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_0224D[] = { - {01, "CupCap", 6}, - {0x020D2, "nvap", 4}, + { {01, "CupCap", 6} }, + { {0x020D2, "nvap", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_0224E[] = { - {01, "bump", 4}, - {0x00338, "nbump", 5}, + { {01, "bump", 4} }, + { {0x00338, "nbump", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_0224F[] = { - {01, "HumpEqual", 9}, - {0x00338, "nbumpe", 6}, + { {01, "HumpEqual", 9} }, + { {0x00338, "nbumpe", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_02250[] = { - {01, "esdot", 5}, - {0x00338, "nedot", 5}, + { {01, "esdot", 5} }, + { {0x00338, "nedot", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_02261[] = { - {01, "Congruent", 9}, - {0x020E5, "bnequiv", 7}, + { {01, "Congruent", 9} }, + { {0x020E5, "bnequiv", 7} }, }; static const entity_multicodepoint_row multi_cp_html5_02264[] = { - {01, "leq", 3}, - {0x020D2, "nvle", 4}, + { {01, "leq", 3} }, + { {0x020D2, "nvle", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_02265[] = { - {01, "ge", 2}, - {0x020D2, "nvge", 4}, + { {01, "ge", 2} }, + { {0x020D2, "nvge", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_02266[] = { - {01, "lE", 2}, - {0x00338, "nlE", 3}, + { {01, "lE", 2} }, + { {0x00338, "nlE", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_02267[] = { - {01, "geqq", 4}, - {0x00338, "NotGreaterFullEqual", 19}, + { {01, "geqq", 4} }, + { {0x00338, "NotGreaterFullEqual", 19} }, }; static const entity_multicodepoint_row multi_cp_html5_02268[] = { - {01, "lneqq", 5}, - {0x0FE00, "lvertneqq", 9}, + { {01, "lneqq", 5} }, + { {0x0FE00, "lvertneqq", 9} }, }; static const entity_multicodepoint_row multi_cp_html5_02269[] = { - {01, "gneqq", 5}, - {0x0FE00, "gvertneqq", 9}, + { {01, "gneqq", 5} }, + { {0x0FE00, "gvertneqq", 9} }, }; static const entity_multicodepoint_row multi_cp_html5_0226A[] = { - {02, "ll", 2}, - {0x00338, "nLtv", 4}, - {0x020D2, "nLt", 3}, + { {02, "ll", 2} }, + { {0x00338, "nLtv", 4} }, + { {0x020D2, "nLt", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_0226B[] = { - {02, "gg", 2}, - {0x00338, "NotGreaterGreater", 17}, - {0x020D2, "nGt", 3}, + { {02, "gg", 2} }, + { {0x00338, "NotGreaterGreater", 17} }, + { {0x020D2, "nGt", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_0227F[] = { - {01, "SucceedsTilde", 13}, - {0x00338, "NotSucceedsTilde", 16}, + { {01, "SucceedsTilde", 13} }, + { {0x00338, "NotSucceedsTilde", 16} }, }; static const entity_multicodepoint_row multi_cp_html5_02282[] = { - {01, "sub", 3}, - {0x020D2, "vnsub", 5}, + { {01, "sub", 3} }, + { {0x020D2, "vnsub", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_02283[] = { - {01, "sup", 3}, - {0x020D2, "nsupset", 7}, + { {01, "sup", 3} }, + { {0x020D2, "nsupset", 7} }, }; static const entity_multicodepoint_row multi_cp_html5_0228A[] = { - {01, "subsetneq", 9}, - {0x0FE00, "vsubne", 6}, + { {01, "subsetneq", 9} }, + { {0x0FE00, "vsubne", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_0228B[] = { - {01, "supsetneq", 9}, - {0x0FE00, "vsupne", 6}, + { {01, "supsetneq", 9} }, + { {0x0FE00, "vsupne", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_0228F[] = { - {01, "sqsub", 5}, - {0x00338, "NotSquareSubset", 15}, + { {01, "sqsub", 5} }, + { {0x00338, "NotSquareSubset", 15} }, }; static const entity_multicodepoint_row multi_cp_html5_02290[] = { - {01, "sqsupset", 8}, - {0x00338, "NotSquareSuperset", 17}, + { {01, "sqsupset", 8} }, + { {0x00338, "NotSquareSuperset", 17} }, }; static const entity_multicodepoint_row multi_cp_html5_02293[] = { - {01, "sqcap", 5}, - {0x0FE00, "sqcaps", 6}, + { {01, "sqcap", 5} }, + { {0x0FE00, "sqcaps", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_02294[] = { - {01, "sqcup", 5}, - {0x0FE00, "sqcups", 6}, + { {01, "sqcup", 5} }, + { {0x0FE00, "sqcups", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_022B4[] = { - {01, "LeftTriangleEqual", 17}, - {0x020D2, "nvltrie", 7}, + { {01, "LeftTriangleEqual", 17} }, + { {0x020D2, "nvltrie", 7} }, }; static const entity_multicodepoint_row multi_cp_html5_022B5[] = { - {01, "RightTriangleEqual", 18}, - {0x020D2, "nvrtrie", 7}, + { {01, "RightTriangleEqual", 18} }, + { {0x020D2, "nvrtrie", 7} }, }; static const entity_multicodepoint_row multi_cp_html5_022D8[] = { - {01, "Ll", 2}, - {0x00338, "nLl", 3}, + { {01, "Ll", 2} }, + { {0x00338, "nLl", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_022D9[] = { - {01, "Gg", 2}, - {0x00338, "nGg", 3}, + { {01, "Gg", 2} }, + { {0x00338, "nGg", 3} }, }; static const entity_multicodepoint_row multi_cp_html5_022DA[] = { - {01, "lesseqgtr", 9}, - {0x0FE00, "lesg", 4}, + { {01, "lesseqgtr", 9} }, + { {0x0FE00, "lesg", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_022DB[] = { - {01, "gtreqless", 9}, - {0x0FE00, "gesl", 4}, + { {01, "gtreqless", 9} }, + { {0x0FE00, "gesl", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_022F5[] = { - {01, "isindot", 7}, - {0x00338, "notindot", 8}, + { {01, "isindot", 7} }, + { {0x00338, "notindot", 8} }, }; static const entity_multicodepoint_row multi_cp_html5_022F9[] = { - {01, "isinE", 5}, - {0x00338, "notinE", 6}, + { {01, "isinE", 5} }, + { {0x00338, "notinE", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_02933[] = { - {01, "rarrc", 5}, - {0x00338, "nrarrc", 6}, + { {01, "rarrc", 5} }, + { {0x00338, "nrarrc", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_029CF[] = { - {01, "LeftTriangleBar", 15}, - {0x00338, "NotLeftTriangleBar", 18}, + { {01, "LeftTriangleBar", 15} }, + { {0x00338, "NotLeftTriangleBar", 18} }, }; static const entity_multicodepoint_row multi_cp_html5_029D0[] = { - {01, "RightTriangleBar", 16}, - {0x00338, "NotRightTriangleBar", 19}, + { {01, "RightTriangleBar", 16} }, + { {0x00338, "NotRightTriangleBar", 19} }, }; static const entity_multicodepoint_row multi_cp_html5_02A6D[] = { - {01, "congdot", 7}, - {0x00338, "ncongdot", 8}, + { {01, "congdot", 7} }, + { {0x00338, "ncongdot", 8} }, }; static const entity_multicodepoint_row multi_cp_html5_02A70[] = { - {01, "apE", 3}, - {0x00338, "napE", 4}, + { {01, "apE", 3} }, + { {0x00338, "napE", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_02A7D[] = { - {01, "les", 3}, - {0x00338, "nles", 4}, + { {01, "les", 3} }, + { {0x00338, "nles", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_02A7E[] = { - {01, "ges", 3}, - {0x00338, "nges", 4}, + { {01, "ges", 3} }, + { {0x00338, "nges", 4} }, }; static const entity_multicodepoint_row multi_cp_html5_02AA1[] = { - {01, "LessLess", 8}, - {0x00338, "NotNestedLessLess", 17}, + { {01, "LessLess", 8} }, + { {0x00338, "NotNestedLessLess", 17} }, }; static const entity_multicodepoint_row multi_cp_html5_02AA2[] = { - {01, "GreaterGreater", 14}, - {0x00338, "NotNestedGreaterGreater", 23}, + { {01, "GreaterGreater", 14} }, + { {0x00338, "NotNestedGreaterGreater", 23} }, }; static const entity_multicodepoint_row multi_cp_html5_02AAC[] = { - {01, "smte", 4}, - {0x0FE00, "smtes", 5}, + { {01, "smte", 4} }, + { {0x0FE00, "smtes", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_02AAD[] = { - {01, "late", 4}, - {0x0FE00, "lates", 5}, + { {01, "late", 4} }, + { {0x0FE00, "lates", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_02AAF[] = { - {01, "preceq", 6}, - {0x00338, "NotPrecedesEqual", 16}, + { {01, "preceq", 6} }, + { {0x00338, "NotPrecedesEqual", 16} }, }; static const entity_multicodepoint_row multi_cp_html5_02AB0[] = { - {01, "SucceedsEqual", 13}, - {0x00338, "NotSucceedsEqual", 16}, + { {01, "SucceedsEqual", 13} }, + { {0x00338, "NotSucceedsEqual", 16} }, }; static const entity_multicodepoint_row multi_cp_html5_02AC5[] = { - {01, "subE", 4}, - {0x00338, "nsubE", 5}, + { {01, "subE", 4} }, + { {0x00338, "nsubE", 5} }, }; static const entity_multicodepoint_row multi_cp_html5_02AC6[] = { - {01, "supseteqq", 9}, - {0x00338, "nsupseteqq", 10}, + { {01, "supseteqq", 9} }, + { {0x00338, "nsupseteqq", 10} }, }; static const entity_multicodepoint_row multi_cp_html5_02ACB[] = { - {01, "subsetneqq", 10}, - {0x0FE00, "vsubnE", 6}, + { {01, "subsetneqq", 10} }, + { {0x0FE00, "vsubnE", 6} }, }; static const entity_multicodepoint_row multi_cp_html5_02ACC[] = { - {01, "supnE", 5}, - {0x0FE00, "varsupsetneqq", 13}, + { {01, "supnE", 5} }, + { {0x0FE00, "varsupsetneqq", 13} }, }; static const entity_multicodepoint_row multi_cp_html5_02AFD[] = { - {01, NULL , 0}, - {0x0FE00, "varsupsetneqq", 13}, + { {01, NULL , 0} }, + { {0x0FE00, "varsupsetneqq", 13} }, }; /* End of double code point tables }}} */ @@ -1402,1066 +1402,1066 @@ static const entity_multicodepoint_row multi_cp_html5_02AFD[] = { static const entity_stage3_row empty_stage3_table[] = { /* 64 elements */ - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00000[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Tab", 3}, {0, "NewLine", 7}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "excl", 4}, {0, "quot", 4}, {0, "num", 3}, - {0, "dollar", 6}, {0, "percnt", 6}, {0, "amp", 3}, {0, "apos", 4}, - {0, "lpar", 4}, {0, "rpar", 4}, {0, "ast", 3}, {0, "plus", 4}, - {0, "comma", 5}, {0, NULL, 0}, {0, "period", 6}, {0, "sol", 3}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "colon", 5}, {0, "semi", 4}, - {1, (void*)multi_cp_html5_0003C}, {1, (void*)multi_cp_html5_0003D}, {1, (void*)multi_cp_html5_0003E}, {0, "quest", 5}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Tab", 3} } }, {0, { {"NewLine", 7} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"excl", 4} } }, {0, { {"quot", 4} } }, {0, { {"num", 3} } }, + {0, { {"dollar", 6} } }, {0, { {"percnt", 6} } }, {0, { {"amp", 3} } }, {0, { {"apos", 4} } }, + {0, { {"lpar", 4} } }, {0, { {"rpar", 4} } }, {0, { {"ast", 3} } }, {0, { {"plus", 4} } }, + {0, { {"comma", 5} } }, {0, { {NULL, 0} } }, {0, { {"period", 6} } }, {0, { {"sol", 3} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"colon", 5} } }, {0, { {"semi", 4} } }, + {1, { {(void *)multi_cp_html5_0003C} } }, {1, { {(void *)multi_cp_html5_0003D} } }, {1, { {(void *)multi_cp_html5_0003E} } }, {0, { {"quest", 5} } }, }; static const entity_stage3_row stage3_table_html5_00040[] = { - {0, "commat", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "lbrack", 6}, - {0, "bsol", 4}, {0, "rsqb", 4}, {0, "Hat", 3}, {0, "lowbar", 6}, - {0, "grave", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {1, (void*)multi_cp_html5_00066}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "lbrace", 6}, - {0, "vert", 4}, {0, "rcub", 4}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"commat", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lbrack", 6} } }, + {0, { {"bsol", 4} } }, {0, { {"rsqb", 4} } }, {0, { {"Hat", 3} } }, {0, { {"lowbar", 6} } }, + {0, { {"grave", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_00066} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lbrace", 6} } }, + {0, { {"vert", 4} } }, {0, { {"rcub", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00080[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "nbsp", 4}, {0, "iexcl", 5}, {0, "cent", 4}, {0, "pound", 5}, - {0, "curren", 6}, {0, "yen", 3}, {0, "brvbar", 6}, {0, "sect", 4}, - {0, "DoubleDot", 9}, {0, "copy", 4}, {0, "ordf", 4}, {0, "laquo", 5}, - {0, "not", 3}, {0, "shy", 3}, {0, "reg", 3}, {0, "macr", 4}, - {0, "deg", 3}, {0, "plusmn", 6}, {0, "sup2", 4}, {0, "sup3", 4}, - {0, "DiacriticalAcute", 16}, {0, "micro", 5}, {0, "para", 4}, {0, "CenterDot", 9}, - {0, "Cedilla", 7}, {0, "sup1", 4}, {0, "ordm", 4}, {0, "raquo", 5}, - {0, "frac14", 6}, {0, "half", 4}, {0, "frac34", 6}, {0, "iquest", 6}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"nbsp", 4} } }, {0, { {"iexcl", 5} } }, {0, { {"cent", 4} } }, {0, { {"pound", 5} } }, + {0, { {"curren", 6} } }, {0, { {"yen", 3} } }, {0, { {"brvbar", 6} } }, {0, { {"sect", 4} } }, + {0, { {"DoubleDot", 9} } }, {0, { {"copy", 4} } }, {0, { {"ordf", 4} } }, {0, { {"laquo", 5} } }, + {0, { {"not", 3} } }, {0, { {"shy", 3} } }, {0, { {"reg", 3} } }, {0, { {"macr", 4} } }, + {0, { {"deg", 3} } }, {0, { {"plusmn", 6} } }, {0, { {"sup2", 4} } }, {0, { {"sup3", 4} } }, + {0, { {"DiacriticalAcute", 16} } }, {0, { {"micro", 5} } }, {0, { {"para", 4} } }, {0, { {"CenterDot", 9} } }, + {0, { {"Cedilla", 7} } }, {0, { {"sup1", 4} } }, {0, { {"ordm", 4} } }, {0, { {"raquo", 5} } }, + {0, { {"frac14", 6} } }, {0, { {"half", 4} } }, {0, { {"frac34", 6} } }, {0, { {"iquest", 6} } }, }; static const entity_stage3_row stage3_table_html5_000C0[] = { - {0, "Agrave", 6}, {0, "Aacute", 6}, {0, "Acirc", 5}, {0, "Atilde", 6}, - {0, "Auml", 4}, {0, "Aring", 5}, {0, "AElig", 5}, {0, "Ccedil", 6}, - {0, "Egrave", 6}, {0, "Eacute", 6}, {0, "Ecirc", 5}, {0, "Euml", 4}, - {0, "Igrave", 6}, {0, "Iacute", 6}, {0, "Icirc", 5}, {0, "Iuml", 4}, - {0, "ETH", 3}, {0, "Ntilde", 6}, {0, "Ograve", 6}, {0, "Oacute", 6}, - {0, "Ocirc", 5}, {0, "Otilde", 6}, {0, "Ouml", 4}, {0, "times", 5}, - {0, "Oslash", 6}, {0, "Ugrave", 6}, {0, "Uacute", 6}, {0, "Ucirc", 5}, - {0, "Uuml", 4}, {0, "Yacute", 6}, {0, "THORN", 5}, {0, "szlig", 5}, - {0, "agrave", 6}, {0, "aacute", 6}, {0, "acirc", 5}, {0, "atilde", 6}, - {0, "auml", 4}, {0, "aring", 5}, {0, "aelig", 5}, {0, "ccedil", 6}, - {0, "egrave", 6}, {0, "eacute", 6}, {0, "ecirc", 5}, {0, "euml", 4}, - {0, "igrave", 6}, {0, "iacute", 6}, {0, "icirc", 5}, {0, "iuml", 4}, - {0, "eth", 3}, {0, "ntilde", 6}, {0, "ograve", 6}, {0, "oacute", 6}, - {0, "ocirc", 5}, {0, "otilde", 6}, {0, "ouml", 4}, {0, "divide", 6}, - {0, "oslash", 6}, {0, "ugrave", 6}, {0, "uacute", 6}, {0, "ucirc", 5}, - {0, "uuml", 4}, {0, "yacute", 6}, {0, "thorn", 5}, {0, "yuml", 4}, + {0, { {"Agrave", 6} } }, {0, { {"Aacute", 6} } }, {0, { {"Acirc", 5} } }, {0, { {"Atilde", 6} } }, + {0, { {"Auml", 4} } }, {0, { {"Aring", 5} } }, {0, { {"AElig", 5} } }, {0, { {"Ccedil", 6} } }, + {0, { {"Egrave", 6} } }, {0, { {"Eacute", 6} } }, {0, { {"Ecirc", 5} } }, {0, { {"Euml", 4} } }, + {0, { {"Igrave", 6} } }, {0, { {"Iacute", 6} } }, {0, { {"Icirc", 5} } }, {0, { {"Iuml", 4} } }, + {0, { {"ETH", 3} } }, {0, { {"Ntilde", 6} } }, {0, { {"Ograve", 6} } }, {0, { {"Oacute", 6} } }, + {0, { {"Ocirc", 5} } }, {0, { {"Otilde", 6} } }, {0, { {"Ouml", 4} } }, {0, { {"times", 5} } }, + {0, { {"Oslash", 6} } }, {0, { {"Ugrave", 6} } }, {0, { {"Uacute", 6} } }, {0, { {"Ucirc", 5} } }, + {0, { {"Uuml", 4} } }, {0, { {"Yacute", 6} } }, {0, { {"THORN", 5} } }, {0, { {"szlig", 5} } }, + {0, { {"agrave", 6} } }, {0, { {"aacute", 6} } }, {0, { {"acirc", 5} } }, {0, { {"atilde", 6} } }, + {0, { {"auml", 4} } }, {0, { {"aring", 5} } }, {0, { {"aelig", 5} } }, {0, { {"ccedil", 6} } }, + {0, { {"egrave", 6} } }, {0, { {"eacute", 6} } }, {0, { {"ecirc", 5} } }, {0, { {"euml", 4} } }, + {0, { {"igrave", 6} } }, {0, { {"iacute", 6} } }, {0, { {"icirc", 5} } }, {0, { {"iuml", 4} } }, + {0, { {"eth", 3} } }, {0, { {"ntilde", 6} } }, {0, { {"ograve", 6} } }, {0, { {"oacute", 6} } }, + {0, { {"ocirc", 5} } }, {0, { {"otilde", 6} } }, {0, { {"ouml", 4} } }, {0, { {"divide", 6} } }, + {0, { {"oslash", 6} } }, {0, { {"ugrave", 6} } }, {0, { {"uacute", 6} } }, {0, { {"ucirc", 5} } }, + {0, { {"uuml", 4} } }, {0, { {"yacute", 6} } }, {0, { {"thorn", 5} } }, {0, { {"yuml", 4} } }, }; static const entity_stage3_row stage3_table_html5_00100[] = { - {0, "Amacr", 5}, {0, "amacr", 5}, {0, "Abreve", 6}, {0, "abreve", 6}, - {0, "Aogon", 5}, {0, "aogon", 5}, {0, "Cacute", 6}, {0, "cacute", 6}, - {0, "Ccirc", 5}, {0, "ccirc", 5}, {0, "Cdot", 4}, {0, "cdot", 4}, - {0, "Ccaron", 6}, {0, "ccaron", 6}, {0, "Dcaron", 6}, {0, "dcaron", 6}, - {0, "Dstrok", 6}, {0, "dstrok", 6}, {0, "Emacr", 5}, {0, "emacr", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, "Edot", 4}, {0, "edot", 4}, - {0, "Eogon", 5}, {0, "eogon", 5}, {0, "Ecaron", 6}, {0, "ecaron", 6}, - {0, "Gcirc", 5}, {0, "gcirc", 5}, {0, "Gbreve", 6}, {0, "gbreve", 6}, - {0, "Gdot", 4}, {0, "gdot", 4}, {0, "Gcedil", 6}, {0, NULL, 0}, - {0, "Hcirc", 5}, {0, "hcirc", 5}, {0, "Hstrok", 6}, {0, "hstrok", 6}, - {0, "Itilde", 6}, {0, "itilde", 6}, {0, "Imacr", 5}, {0, "imacr", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, "Iogon", 5}, {0, "iogon", 5}, - {0, "Idot", 4}, {0, "inodot", 6}, {0, "IJlig", 5}, {0, "ijlig", 5}, - {0, "Jcirc", 5}, {0, "jcirc", 5}, {0, "Kcedil", 6}, {0, "kcedil", 6}, - {0, "kgreen", 6}, {0, "Lacute", 6}, {0, "lacute", 6}, {0, "Lcedil", 6}, - {0, "lcedil", 6}, {0, "Lcaron", 6}, {0, "lcaron", 6}, {0, "Lmidot", 6}, + {0, { {"Amacr", 5} } }, {0, { {"amacr", 5} } }, {0, { {"Abreve", 6} } }, {0, { {"abreve", 6} } }, + {0, { {"Aogon", 5} } }, {0, { {"aogon", 5} } }, {0, { {"Cacute", 6} } }, {0, { {"cacute", 6} } }, + {0, { {"Ccirc", 5} } }, {0, { {"ccirc", 5} } }, {0, { {"Cdot", 4} } }, {0, { {"cdot", 4} } }, + {0, { {"Ccaron", 6} } }, {0, { {"ccaron", 6} } }, {0, { {"Dcaron", 6} } }, {0, { {"dcaron", 6} } }, + {0, { {"Dstrok", 6} } }, {0, { {"dstrok", 6} } }, {0, { {"Emacr", 5} } }, {0, { {"emacr", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"Edot", 4} } }, {0, { {"edot", 4} } }, + {0, { {"Eogon", 5} } }, {0, { {"eogon", 5} } }, {0, { {"Ecaron", 6} } }, {0, { {"ecaron", 6} } }, + {0, { {"Gcirc", 5} } }, {0, { {"gcirc", 5} } }, {0, { {"Gbreve", 6} } }, {0, { {"gbreve", 6} } }, + {0, { {"Gdot", 4} } }, {0, { {"gdot", 4} } }, {0, { {"Gcedil", 6} } }, {0, { {NULL, 0} } }, + {0, { {"Hcirc", 5} } }, {0, { {"hcirc", 5} } }, {0, { {"Hstrok", 6} } }, {0, { {"hstrok", 6} } }, + {0, { {"Itilde", 6} } }, {0, { {"itilde", 6} } }, {0, { {"Imacr", 5} } }, {0, { {"imacr", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"Iogon", 5} } }, {0, { {"iogon", 5} } }, + {0, { {"Idot", 4} } }, {0, { {"inodot", 6} } }, {0, { {"IJlig", 5} } }, {0, { {"ijlig", 5} } }, + {0, { {"Jcirc", 5} } }, {0, { {"jcirc", 5} } }, {0, { {"Kcedil", 6} } }, {0, { {"kcedil", 6} } }, + {0, { {"kgreen", 6} } }, {0, { {"Lacute", 6} } }, {0, { {"lacute", 6} } }, {0, { {"Lcedil", 6} } }, + {0, { {"lcedil", 6} } }, {0, { {"Lcaron", 6} } }, {0, { {"lcaron", 6} } }, {0, { {"Lmidot", 6} } }, }; static const entity_stage3_row stage3_table_html5_00140[] = { - {0, "lmidot", 6}, {0, "Lstrok", 6}, {0, "lstrok", 6}, {0, "Nacute", 6}, - {0, "nacute", 6}, {0, "Ncedil", 6}, {0, "ncedil", 6}, {0, "Ncaron", 6}, - {0, "ncaron", 6}, {0, "napos", 5}, {0, "ENG", 3}, {0, "eng", 3}, - {0, "Omacr", 5}, {0, "omacr", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Odblac", 6}, {0, "odblac", 6}, {0, "OElig", 5}, {0, "oelig", 5}, - {0, "Racute", 6}, {0, "racute", 6}, {0, "Rcedil", 6}, {0, "rcedil", 6}, - {0, "Rcaron", 6}, {0, "rcaron", 6}, {0, "Sacute", 6}, {0, "sacute", 6}, - {0, "Scirc", 5}, {0, "scirc", 5}, {0, "Scedil", 6}, {0, "scedil", 6}, - {0, "Scaron", 6}, {0, "scaron", 6}, {0, "Tcedil", 6}, {0, "tcedil", 6}, - {0, "Tcaron", 6}, {0, "tcaron", 6}, {0, "Tstrok", 6}, {0, "tstrok", 6}, - {0, "Utilde", 6}, {0, "utilde", 6}, {0, "Umacr", 5}, {0, "umacr", 5}, - {0, "Ubreve", 6}, {0, "ubreve", 6}, {0, "Uring", 5}, {0, "uring", 5}, - {0, "Udblac", 6}, {0, "udblac", 6}, {0, "Uogon", 5}, {0, "uogon", 5}, - {0, "Wcirc", 5}, {0, "wcirc", 5}, {0, "Ycirc", 5}, {0, "ycirc", 5}, - {0, "Yuml", 4}, {0, "Zacute", 6}, {0, "zacute", 6}, {0, "Zdot", 4}, - {0, "zdot", 4}, {0, "Zcaron", 6}, {0, "zcaron", 6}, {0, NULL, 0}, + {0, { {"lmidot", 6} } }, {0, { {"Lstrok", 6} } }, {0, { {"lstrok", 6} } }, {0, { {"Nacute", 6} } }, + {0, { {"nacute", 6} } }, {0, { {"Ncedil", 6} } }, {0, { {"ncedil", 6} } }, {0, { {"Ncaron", 6} } }, + {0, { {"ncaron", 6} } }, {0, { {"napos", 5} } }, {0, { {"ENG", 3} } }, {0, { {"eng", 3} } }, + {0, { {"Omacr", 5} } }, {0, { {"omacr", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Odblac", 6} } }, {0, { {"odblac", 6} } }, {0, { {"OElig", 5} } }, {0, { {"oelig", 5} } }, + {0, { {"Racute", 6} } }, {0, { {"racute", 6} } }, {0, { {"Rcedil", 6} } }, {0, { {"rcedil", 6} } }, + {0, { {"Rcaron", 6} } }, {0, { {"rcaron", 6} } }, {0, { {"Sacute", 6} } }, {0, { {"sacute", 6} } }, + {0, { {"Scirc", 5} } }, {0, { {"scirc", 5} } }, {0, { {"Scedil", 6} } }, {0, { {"scedil", 6} } }, + {0, { {"Scaron", 6} } }, {0, { {"scaron", 6} } }, {0, { {"Tcedil", 6} } }, {0, { {"tcedil", 6} } }, + {0, { {"Tcaron", 6} } }, {0, { {"tcaron", 6} } }, {0, { {"Tstrok", 6} } }, {0, { {"tstrok", 6} } }, + {0, { {"Utilde", 6} } }, {0, { {"utilde", 6} } }, {0, { {"Umacr", 5} } }, {0, { {"umacr", 5} } }, + {0, { {"Ubreve", 6} } }, {0, { {"ubreve", 6} } }, {0, { {"Uring", 5} } }, {0, { {"uring", 5} } }, + {0, { {"Udblac", 6} } }, {0, { {"udblac", 6} } }, {0, { {"Uogon", 5} } }, {0, { {"uogon", 5} } }, + {0, { {"Wcirc", 5} } }, {0, { {"wcirc", 5} } }, {0, { {"Ycirc", 5} } }, {0, { {"ycirc", 5} } }, + {0, { {"Yuml", 4} } }, {0, { {"Zacute", 6} } }, {0, { {"zacute", 6} } }, {0, { {"Zdot", 4} } }, + {0, { {"zdot", 4} } }, {0, { {"Zcaron", 6} } }, {0, { {"zcaron", 6} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00180[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "fnof", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "imped", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"fnof", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"imped", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_001C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "gacute", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"gacute", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00200[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "jmath", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"jmath", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_002C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "circ", 4}, {0, "Hacek", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Breve", 5}, {0, "dot", 3}, {0, "ring", 4}, {0, "ogon", 4}, - {0, "DiacriticalTilde", 16}, {0, "DiacriticalDoubleAcute", 22}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"circ", 4} } }, {0, { {"Hacek", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Breve", 5} } }, {0, { {"dot", 3} } }, {0, { {"ring", 4} } }, {0, { {"ogon", 4} } }, + {0, { {"DiacriticalTilde", 16} } }, {0, { {"DiacriticalDoubleAcute", 22} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00300[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "DownBreve", 9}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"DownBreve", 9} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00380[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Alpha", 5}, {0, "Beta", 4}, {0, "Gamma", 5}, - {0, "Delta", 5}, {0, "Epsilon", 7}, {0, "Zeta", 4}, {0, "Eta", 3}, - {0, "Theta", 5}, {0, "Iota", 4}, {0, "Kappa", 5}, {0, "Lambda", 6}, - {0, "Mu", 2}, {0, "Nu", 2}, {0, "Xi", 2}, {0, "Omicron", 7}, - {0, "Pi", 2}, {0, "Rho", 3}, {0, NULL, 0}, {0, "Sigma", 5}, - {0, "Tau", 3}, {0, "Upsilon", 7}, {0, "Phi", 3}, {0, "Chi", 3}, - {0, "Psi", 3}, {0, "Omega", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "alpha", 5}, {0, "beta", 4}, {0, "gamma", 5}, - {0, "delta", 5}, {0, "epsi", 4}, {0, "zeta", 4}, {0, "eta", 3}, - {0, "theta", 5}, {0, "iota", 4}, {0, "kappa", 5}, {0, "lambda", 6}, - {0, "mu", 2}, {0, "nu", 2}, {0, "xi", 2}, {0, "omicron", 7}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Alpha", 5} } }, {0, { {"Beta", 4} } }, {0, { {"Gamma", 5} } }, + {0, { {"Delta", 5} } }, {0, { {"Epsilon", 7} } }, {0, { {"Zeta", 4} } }, {0, { {"Eta", 3} } }, + {0, { {"Theta", 5} } }, {0, { {"Iota", 4} } }, {0, { {"Kappa", 5} } }, {0, { {"Lambda", 6} } }, + {0, { {"Mu", 2} } }, {0, { {"Nu", 2} } }, {0, { {"Xi", 2} } }, {0, { {"Omicron", 7} } }, + {0, { {"Pi", 2} } }, {0, { {"Rho", 3} } }, {0, { {NULL, 0} } }, {0, { {"Sigma", 5} } }, + {0, { {"Tau", 3} } }, {0, { {"Upsilon", 7} } }, {0, { {"Phi", 3} } }, {0, { {"Chi", 3} } }, + {0, { {"Psi", 3} } }, {0, { {"Omega", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"alpha", 5} } }, {0, { {"beta", 4} } }, {0, { {"gamma", 5} } }, + {0, { {"delta", 5} } }, {0, { {"epsi", 4} } }, {0, { {"zeta", 4} } }, {0, { {"eta", 3} } }, + {0, { {"theta", 5} } }, {0, { {"iota", 4} } }, {0, { {"kappa", 5} } }, {0, { {"lambda", 6} } }, + {0, { {"mu", 2} } }, {0, { {"nu", 2} } }, {0, { {"xi", 2} } }, {0, { {"omicron", 7} } }, }; static const entity_stage3_row stage3_table_html5_003C0[] = { - {0, "pi", 2}, {0, "rho", 3}, {0, "sigmav", 6}, {0, "sigma", 5}, - {0, "tau", 3}, {0, "upsi", 4}, {0, "phi", 3}, {0, "chi", 3}, - {0, "psi", 3}, {0, "omega", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "thetasym", 8}, {0, "upsih", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, "straightphi", 11}, {0, "piv", 3}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Gammad", 6}, {0, "gammad", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "varkappa", 8}, {0, "rhov", 4}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "straightepsilon", 15}, {0, "backepsilon", 11}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"pi", 2} } }, {0, { {"rho", 3} } }, {0, { {"sigmav", 6} } }, {0, { {"sigma", 5} } }, + {0, { {"tau", 3} } }, {0, { {"upsi", 4} } }, {0, { {"phi", 3} } }, {0, { {"chi", 3} } }, + {0, { {"psi", 3} } }, {0, { {"omega", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"thetasym", 8} } }, {0, { {"upsih", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"straightphi", 11} } }, {0, { {"piv", 3} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Gammad", 6} } }, {0, { {"gammad", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"varkappa", 8} } }, {0, { {"rhov", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"straightepsilon", 15} } }, {0, { {"backepsilon", 11} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_00400[] = { - {0, NULL, 0}, {0, "IOcy", 4}, {0, "DJcy", 4}, {0, "GJcy", 4}, - {0, "Jukcy", 5}, {0, "DScy", 4}, {0, "Iukcy", 5}, {0, "YIcy", 4}, - {0, "Jsercy", 6}, {0, "LJcy", 4}, {0, "NJcy", 4}, {0, "TSHcy", 5}, - {0, "KJcy", 4}, {0, NULL, 0}, {0, "Ubrcy", 5}, {0, "DZcy", 4}, - {0, "Acy", 3}, {0, "Bcy", 3}, {0, "Vcy", 3}, {0, "Gcy", 3}, - {0, "Dcy", 3}, {0, "IEcy", 4}, {0, "ZHcy", 4}, {0, "Zcy", 3}, - {0, "Icy", 3}, {0, "Jcy", 3}, {0, "Kcy", 3}, {0, "Lcy", 3}, - {0, "Mcy", 3}, {0, "Ncy", 3}, {0, "Ocy", 3}, {0, "Pcy", 3}, - {0, "Rcy", 3}, {0, "Scy", 3}, {0, "Tcy", 3}, {0, "Ucy", 3}, - {0, "Fcy", 3}, {0, "KHcy", 4}, {0, "TScy", 4}, {0, "CHcy", 4}, - {0, "SHcy", 4}, {0, "SHCHcy", 6}, {0, "HARDcy", 6}, {0, "Ycy", 3}, - {0, "SOFTcy", 6}, {0, "Ecy", 3}, {0, "YUcy", 4}, {0, "YAcy", 4}, - {0, "acy", 3}, {0, "bcy", 3}, {0, "vcy", 3}, {0, "gcy", 3}, - {0, "dcy", 3}, {0, "iecy", 4}, {0, "zhcy", 4}, {0, "zcy", 3}, - {0, "icy", 3}, {0, "jcy", 3}, {0, "kcy", 3}, {0, "lcy", 3}, - {0, "mcy", 3}, {0, "ncy", 3}, {0, "ocy", 3}, {0, "pcy", 3}, + {0, { {NULL, 0} } }, {0, { {"IOcy", 4} } }, {0, { {"DJcy", 4} } }, {0, { {"GJcy", 4} } }, + {0, { {"Jukcy", 5} } }, {0, { {"DScy", 4} } }, {0, { {"Iukcy", 5} } }, {0, { {"YIcy", 4} } }, + {0, { {"Jsercy", 6} } }, {0, { {"LJcy", 4} } }, {0, { {"NJcy", 4} } }, {0, { {"TSHcy", 5} } }, + {0, { {"KJcy", 4} } }, {0, { {NULL, 0} } }, {0, { {"Ubrcy", 5} } }, {0, { {"DZcy", 4} } }, + {0, { {"Acy", 3} } }, {0, { {"Bcy", 3} } }, {0, { {"Vcy", 3} } }, {0, { {"Gcy", 3} } }, + {0, { {"Dcy", 3} } }, {0, { {"IEcy", 4} } }, {0, { {"ZHcy", 4} } }, {0, { {"Zcy", 3} } }, + {0, { {"Icy", 3} } }, {0, { {"Jcy", 3} } }, {0, { {"Kcy", 3} } }, {0, { {"Lcy", 3} } }, + {0, { {"Mcy", 3} } }, {0, { {"Ncy", 3} } }, {0, { {"Ocy", 3} } }, {0, { {"Pcy", 3} } }, + {0, { {"Rcy", 3} } }, {0, { {"Scy", 3} } }, {0, { {"Tcy", 3} } }, {0, { {"Ucy", 3} } }, + {0, { {"Fcy", 3} } }, {0, { {"KHcy", 4} } }, {0, { {"TScy", 4} } }, {0, { {"CHcy", 4} } }, + {0, { {"SHcy", 4} } }, {0, { {"SHCHcy", 6} } }, {0, { {"HARDcy", 6} } }, {0, { {"Ycy", 3} } }, + {0, { {"SOFTcy", 6} } }, {0, { {"Ecy", 3} } }, {0, { {"YUcy", 4} } }, {0, { {"YAcy", 4} } }, + {0, { {"acy", 3} } }, {0, { {"bcy", 3} } }, {0, { {"vcy", 3} } }, {0, { {"gcy", 3} } }, + {0, { {"dcy", 3} } }, {0, { {"iecy", 4} } }, {0, { {"zhcy", 4} } }, {0, { {"zcy", 3} } }, + {0, { {"icy", 3} } }, {0, { {"jcy", 3} } }, {0, { {"kcy", 3} } }, {0, { {"lcy", 3} } }, + {0, { {"mcy", 3} } }, {0, { {"ncy", 3} } }, {0, { {"ocy", 3} } }, {0, { {"pcy", 3} } }, }; static const entity_stage3_row stage3_table_html5_00440[] = { - {0, "rcy", 3}, {0, "scy", 3}, {0, "tcy", 3}, {0, "ucy", 3}, - {0, "fcy", 3}, {0, "khcy", 4}, {0, "tscy", 4}, {0, "chcy", 4}, - {0, "shcy", 4}, {0, "shchcy", 6}, {0, "hardcy", 6}, {0, "ycy", 3}, - {0, "softcy", 6}, {0, "ecy", 3}, {0, "yucy", 4}, {0, "yacy", 4}, - {0, NULL, 0}, {0, "iocy", 4}, {0, "djcy", 4}, {0, "gjcy", 4}, - {0, "jukcy", 5}, {0, "dscy", 4}, {0, "iukcy", 5}, {0, "yicy", 4}, - {0, "jsercy", 6}, {0, "ljcy", 4}, {0, "njcy", 4}, {0, "tshcy", 5}, - {0, "kjcy", 4}, {0, NULL, 0}, {0, "ubrcy", 5}, {0, "dzcy", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"rcy", 3} } }, {0, { {"scy", 3} } }, {0, { {"tcy", 3} } }, {0, { {"ucy", 3} } }, + {0, { {"fcy", 3} } }, {0, { {"khcy", 4} } }, {0, { {"tscy", 4} } }, {0, { {"chcy", 4} } }, + {0, { {"shcy", 4} } }, {0, { {"shchcy", 6} } }, {0, { {"hardcy", 6} } }, {0, { {"ycy", 3} } }, + {0, { {"softcy", 6} } }, {0, { {"ecy", 3} } }, {0, { {"yucy", 4} } }, {0, { {"yacy", 4} } }, + {0, { {NULL, 0} } }, {0, { {"iocy", 4} } }, {0, { {"djcy", 4} } }, {0, { {"gjcy", 4} } }, + {0, { {"jukcy", 5} } }, {0, { {"dscy", 4} } }, {0, { {"iukcy", 5} } }, {0, { {"yicy", 4} } }, + {0, { {"jsercy", 6} } }, {0, { {"ljcy", 4} } }, {0, { {"njcy", 4} } }, {0, { {"tshcy", 5} } }, + {0, { {"kjcy", 4} } }, {0, { {NULL, 0} } }, {0, { {"ubrcy", 5} } }, {0, { {"dzcy", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02000[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, "ensp", 4}, {0, "emsp", 4}, - {0, "emsp13", 6}, {0, "emsp14", 6}, {0, NULL, 0}, {0, "numsp", 5}, - {0, "puncsp", 6}, {0, "ThinSpace", 9}, {0, "hairsp", 6}, {0, "ZeroWidthSpace", 14}, - {0, "zwnj", 4}, {0, "zwj", 3}, {0, "lrm", 3}, {0, "rlm", 3}, - {0, "hyphen", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, "ndash", 5}, - {0, "mdash", 5}, {0, "horbar", 6}, {0, "Verbar", 6}, {0, NULL, 0}, - {0, "OpenCurlyQuote", 14}, {0, "rsquo", 5}, {0, "sbquo", 5}, {0, NULL, 0}, - {0, "OpenCurlyDoubleQuote", 20}, {0, "rdquo", 5}, {0, "bdquo", 5}, {0, NULL, 0}, - {0, "dagger", 6}, {0, "Dagger", 6}, {0, "bull", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, "nldr", 4}, {0, "hellip", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "permil", 6}, {0, "pertenk", 7}, {0, "prime", 5}, {0, "Prime", 5}, - {0, "tprime", 6}, {0, "backprime", 9}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "lsaquo", 6}, {0, "rsaquo", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "oline", 5}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"ensp", 4} } }, {0, { {"emsp", 4} } }, + {0, { {"emsp13", 6} } }, {0, { {"emsp14", 6} } }, {0, { {NULL, 0} } }, {0, { {"numsp", 5} } }, + {0, { {"puncsp", 6} } }, {0, { {"ThinSpace", 9} } }, {0, { {"hairsp", 6} } }, {0, { {"ZeroWidthSpace", 14} } }, + {0, { {"zwnj", 4} } }, {0, { {"zwj", 3} } }, {0, { {"lrm", 3} } }, {0, { {"rlm", 3} } }, + {0, { {"hyphen", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"ndash", 5} } }, + {0, { {"mdash", 5} } }, {0, { {"horbar", 6} } }, {0, { {"Verbar", 6} } }, {0, { {NULL, 0} } }, + {0, { {"OpenCurlyQuote", 14} } }, {0, { {"rsquo", 5} } }, {0, { {"sbquo", 5} } }, {0, { {NULL, 0} } }, + {0, { {"OpenCurlyDoubleQuote", 20} } }, {0, { {"rdquo", 5} } }, {0, { {"bdquo", 5} } }, {0, { {NULL, 0} } }, + {0, { {"dagger", 6} } }, {0, { {"Dagger", 6} } }, {0, { {"bull", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"nldr", 4} } }, {0, { {"hellip", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"permil", 6} } }, {0, { {"pertenk", 7} } }, {0, { {"prime", 5} } }, {0, { {"Prime", 5} } }, + {0, { {"tprime", 6} } }, {0, { {"backprime", 9} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"lsaquo", 6} } }, {0, { {"rsaquo", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"oline", 5} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02040[] = { - {0, NULL, 0}, {0, "caret", 5}, {0, NULL, 0}, {0, "hybull", 6}, - {0, "frasl", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "bsemi", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "qprime", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {1, (void*)multi_cp_html5_0205F}, - {0, "NoBreak", 7}, {0, "af", 2}, {0, "InvisibleTimes", 14}, {0, "ic", 2}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {"caret", 5} } }, {0, { {NULL, 0} } }, {0, { {"hybull", 6} } }, + {0, { {"frasl", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"bsemi", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"qprime", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_0205F} } }, + {0, { {"NoBreak", 7} } }, {0, { {"af", 2} } }, {0, { {"InvisibleTimes", 14} } }, {0, { {"ic", 2} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02080[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "euro", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"euro", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_020C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "TripleDot", 9}, - {0, "DotDot", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"TripleDot", 9} } }, + {0, { {"DotDot", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02100[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, "complexes", 9}, {0, NULL, 0}, - {0, NULL, 0}, {0, "incare", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "gscr", 4}, {0, "HilbertSpace", 12}, - {0, "Hfr", 3}, {0, "Hopf", 4}, {0, "planckh", 7}, {0, "planck", 6}, - {0, "imagline", 8}, {0, "Ifr", 3}, {0, "lagran", 6}, {0, "ell", 3}, - {0, NULL, 0}, {0, "naturals", 8}, {0, "numero", 6}, {0, "copysr", 6}, - {0, "wp", 2}, {0, "primes", 6}, {0, "rationals", 9}, {0, "realine", 7}, - {0, "Rfr", 3}, {0, "Ropf", 4}, {0, "rx", 2}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "trade", 5}, {0, NULL, 0}, - {0, "Zopf", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, "mho", 3}, - {0, "Zfr", 3}, {0, "iiota", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Bscr", 4}, {0, "Cfr", 3}, {0, NULL, 0}, {0, "escr", 4}, - {0, "expectation", 11}, {0, "Fouriertrf", 10}, {0, NULL, 0}, {0, "Mellintrf", 9}, - {0, "orderof", 7}, {0, "aleph", 5}, {0, "beth", 4}, {0, "gimel", 5}, - {0, "daleth", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"complexes", 9} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"incare", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"gscr", 4} } }, {0, { {"HilbertSpace", 12} } }, + {0, { {"Hfr", 3} } }, {0, { {"Hopf", 4} } }, {0, { {"planckh", 7} } }, {0, { {"planck", 6} } }, + {0, { {"imagline", 8} } }, {0, { {"Ifr", 3} } }, {0, { {"lagran", 6} } }, {0, { {"ell", 3} } }, + {0, { {NULL, 0} } }, {0, { {"naturals", 8} } }, {0, { {"numero", 6} } }, {0, { {"copysr", 6} } }, + {0, { {"wp", 2} } }, {0, { {"primes", 6} } }, {0, { {"rationals", 9} } }, {0, { {"realine", 7} } }, + {0, { {"Rfr", 3} } }, {0, { {"Ropf", 4} } }, {0, { {"rx", 2} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"trade", 5} } }, {0, { {NULL, 0} } }, + {0, { {"Zopf", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"mho", 3} } }, + {0, { {"Zfr", 3} } }, {0, { {"iiota", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Bscr", 4} } }, {0, { {"Cfr", 3} } }, {0, { {NULL, 0} } }, {0, { {"escr", 4} } }, + {0, { {"expectation", 11} } }, {0, { {"Fouriertrf", 10} } }, {0, { {NULL, 0} } }, {0, { {"Mellintrf", 9} } }, + {0, { {"orderof", 7} } }, {0, { {"aleph", 5} } }, {0, { {"beth", 4} } }, {0, { {"gimel", 5} } }, + {0, { {"daleth", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02140[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "CapitalDifferentialD", 20}, {0, "DifferentialD", 13}, {0, "exponentiale", 12}, - {0, "ImaginaryI", 10}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "frac13", 6}, - {0, "frac23", 6}, {0, "frac15", 6}, {0, "frac25", 6}, {0, "frac35", 6}, - {0, "frac45", 6}, {0, "frac16", 6}, {0, "frac56", 6}, {0, "frac18", 6}, - {0, "frac38", 6}, {0, "frac58", 6}, {0, "frac78", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"CapitalDifferentialD", 20} } }, {0, { {"DifferentialD", 13} } }, {0, { {"exponentiale", 12} } }, + {0, { {"ImaginaryI", 10} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"frac13", 6} } }, + {0, { {"frac23", 6} } }, {0, { {"frac15", 6} } }, {0, { {"frac25", 6} } }, {0, { {"frac35", 6} } }, + {0, { {"frac45", 6} } }, {0, { {"frac16", 6} } }, {0, { {"frac56", 6} } }, {0, { {"frac18", 6} } }, + {0, { {"frac38", 6} } }, {0, { {"frac58", 6} } }, {0, { {"frac78", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02180[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "larr", 4}, {0, "uarr", 4}, {0, "srarr", 5}, {0, "darr", 4}, - {0, "harr", 4}, {0, "UpDownArrow", 11}, {0, "nwarrow", 7}, {0, "UpperRightArrow", 15}, - {0, "LowerRightArrow", 15}, {0, "swarr", 5}, {0, "nleftarrow", 10}, {0, "nrarr", 5}, - {0, NULL, 0}, {1, (void*)multi_cp_html5_0219D}, {0, "Larr", 4}, {0, "Uarr", 4}, - {0, "twoheadrightarrow", 17}, {0, "Darr", 4}, {0, "larrtl", 6}, {0, "rarrtl", 6}, - {0, "LeftTeeArrow", 12}, {0, "UpTeeArrow", 10}, {0, "map", 3}, {0, "DownTeeArrow", 12}, - {0, NULL, 0}, {0, "larrhk", 6}, {0, "rarrhk", 6}, {0, "larrlp", 6}, - {0, "looparrowright", 14}, {0, "harrw", 5}, {0, "nleftrightarrow", 15}, {0, NULL, 0}, - {0, "Lsh", 3}, {0, "rsh", 3}, {0, "ldsh", 4}, {0, "rdsh", 4}, - {0, NULL, 0}, {0, "crarr", 5}, {0, "curvearrowleft", 14}, {0, "curarr", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, "olarr", 5}, {0, "orarr", 5}, - {0, "leftharpoonup", 13}, {0, "leftharpoondown", 15}, {0, "RightUpVector", 13}, {0, "uharl", 5}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"larr", 4} } }, {0, { {"uarr", 4} } }, {0, { {"srarr", 5} } }, {0, { {"darr", 4} } }, + {0, { {"harr", 4} } }, {0, { {"UpDownArrow", 11} } }, {0, { {"nwarrow", 7} } }, {0, { {"UpperRightArrow", 15} } }, + {0, { {"LowerRightArrow", 15} } }, {0, { {"swarr", 5} } }, {0, { {"nleftarrow", 10} } }, {0, { {"nrarr", 5} } }, + {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_0219D} } }, {0, { {"Larr", 4} } }, {0, { {"Uarr", 4} } }, + {0, { {"twoheadrightarrow", 17} } }, {0, { {"Darr", 4} } }, {0, { {"larrtl", 6} } }, {0, { {"rarrtl", 6} } }, + {0, { {"LeftTeeArrow", 12} } }, {0, { {"UpTeeArrow", 10} } }, {0, { {"map", 3} } }, {0, { {"DownTeeArrow", 12} } }, + {0, { {NULL, 0} } }, {0, { {"larrhk", 6} } }, {0, { {"rarrhk", 6} } }, {0, { {"larrlp", 6} } }, + {0, { {"looparrowright", 14} } }, {0, { {"harrw", 5} } }, {0, { {"nleftrightarrow", 15} } }, {0, { {NULL, 0} } }, + {0, { {"Lsh", 3} } }, {0, { {"rsh", 3} } }, {0, { {"ldsh", 4} } }, {0, { {"rdsh", 4} } }, + {0, { {NULL, 0} } }, {0, { {"crarr", 5} } }, {0, { {"curvearrowleft", 14} } }, {0, { {"curarr", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"olarr", 5} } }, {0, { {"orarr", 5} } }, + {0, { {"leftharpoonup", 13} } }, {0, { {"leftharpoondown", 15} } }, {0, { {"RightUpVector", 13} } }, {0, { {"uharl", 5} } }, }; static const entity_stage3_row stage3_table_html5_021C0[] = { - {0, "rharu", 5}, {0, "rhard", 5}, {0, "RightDownVector", 15}, {0, "dharl", 5}, - {0, "rightleftarrows", 15}, {0, "udarr", 5}, {0, "lrarr", 5}, {0, "llarr", 5}, - {0, "upuparrows", 10}, {0, "rrarr", 5}, {0, "downdownarrows", 14}, {0, "leftrightharpoons", 17}, - {0, "rightleftharpoons", 17}, {0, "nLeftarrow", 10}, {0, "nhArr", 5}, {0, "nrArr", 5}, - {0, "DoubleLeftArrow", 15}, {0, "DoubleUpArrow", 13}, {0, "Implies", 7}, {0, "Downarrow", 9}, - {0, "hArr", 4}, {0, "Updownarrow", 11}, {0, "nwArr", 5}, {0, "neArr", 5}, - {0, "seArr", 5}, {0, "swArr", 5}, {0, "lAarr", 5}, {0, "rAarr", 5}, - {0, NULL, 0}, {0, "zigrarr", 7}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "LeftArrowBar", 12}, {0, "RightArrowBar", 13}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "DownArrowUpArrow", 16}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "loarr", 5}, {0, "roarr", 5}, {0, "hoarr", 5}, + {0, { {"rharu", 5} } }, {0, { {"rhard", 5} } }, {0, { {"RightDownVector", 15} } }, {0, { {"dharl", 5} } }, + {0, { {"rightleftarrows", 15} } }, {0, { {"udarr", 5} } }, {0, { {"lrarr", 5} } }, {0, { {"llarr", 5} } }, + {0, { {"upuparrows", 10} } }, {0, { {"rrarr", 5} } }, {0, { {"downdownarrows", 14} } }, {0, { {"leftrightharpoons", 17} } }, + {0, { {"rightleftharpoons", 17} } }, {0, { {"nLeftarrow", 10} } }, {0, { {"nhArr", 5} } }, {0, { {"nrArr", 5} } }, + {0, { {"DoubleLeftArrow", 15} } }, {0, { {"DoubleUpArrow", 13} } }, {0, { {"Implies", 7} } }, {0, { {"Downarrow", 9} } }, + {0, { {"hArr", 4} } }, {0, { {"Updownarrow", 11} } }, {0, { {"nwArr", 5} } }, {0, { {"neArr", 5} } }, + {0, { {"seArr", 5} } }, {0, { {"swArr", 5} } }, {0, { {"lAarr", 5} } }, {0, { {"rAarr", 5} } }, + {0, { {NULL, 0} } }, {0, { {"zigrarr", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"LeftArrowBar", 12} } }, {0, { {"RightArrowBar", 13} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"DownArrowUpArrow", 16} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"loarr", 5} } }, {0, { {"roarr", 5} } }, {0, { {"hoarr", 5} } }, }; static const entity_stage3_row stage3_table_html5_02200[] = { - {0, "forall", 6}, {0, "comp", 4}, {1, (void*)multi_cp_html5_02202}, {0, "Exists", 6}, - {0, "nexist", 6}, {0, "empty", 5}, {0, NULL, 0}, {0, "nabla", 5}, - {0, "isinv", 5}, {0, "notin", 5}, {0, NULL, 0}, {0, "ReverseElement", 14}, - {0, "notniva", 7}, {0, NULL, 0}, {0, NULL, 0}, {0, "prod", 4}, - {0, "Coproduct", 9}, {0, "sum", 3}, {0, "minus", 5}, {0, "MinusPlus", 9}, - {0, "plusdo", 6}, {0, NULL, 0}, {0, "ssetmn", 6}, {0, "lowast", 6}, - {0, "compfn", 6}, {0, NULL, 0}, {0, "Sqrt", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, "prop", 4}, {0, "infin", 5}, {0, "angrt", 5}, - {1, (void*)multi_cp_html5_02220}, {0, "angmsd", 6}, {0, "angsph", 6}, {0, "mid", 3}, - {0, "nshortmid", 9}, {0, "shortparallel", 13}, {0, "nparallel", 9}, {0, "and", 3}, - {0, "or", 2}, {1, (void*)multi_cp_html5_02229}, {1, (void*)multi_cp_html5_0222A}, {0, "Integral", 8}, - {0, "Int", 3}, {0, "tint", 4}, {0, "ContourIntegral", 15}, {0, "DoubleContourIntegral", 21}, - {0, "Cconint", 7}, {0, "cwint", 5}, {0, "cwconint", 8}, {0, "awconint", 8}, - {0, "there4", 6}, {0, "Because", 7}, {0, "ratio", 5}, {0, "Colon", 5}, - {0, "minusd", 6}, {0, NULL, 0}, {0, "mDDot", 5}, {0, "homtht", 6}, - {1, (void*)multi_cp_html5_0223C}, {1, (void*)multi_cp_html5_0223D}, {1, (void*)multi_cp_html5_0223E}, {0, "acd", 3}, + {0, { {"forall", 6} } }, {0, { {"comp", 4} } }, {1, { {(void *)multi_cp_html5_02202} } }, {0, { {"Exists", 6} } }, + {0, { {"nexist", 6} } }, {0, { {"empty", 5} } }, {0, { {NULL, 0} } }, {0, { {"nabla", 5} } }, + {0, { {"isinv", 5} } }, {0, { {"notin", 5} } }, {0, { {NULL, 0} } }, {0, { {"ReverseElement", 14} } }, + {0, { {"notniva", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"prod", 4} } }, + {0, { {"Coproduct", 9} } }, {0, { {"sum", 3} } }, {0, { {"minus", 5} } }, {0, { {"MinusPlus", 9} } }, + {0, { {"plusdo", 6} } }, {0, { {NULL, 0} } }, {0, { {"ssetmn", 6} } }, {0, { {"lowast", 6} } }, + {0, { {"compfn", 6} } }, {0, { {NULL, 0} } }, {0, { {"Sqrt", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"prop", 4} } }, {0, { {"infin", 5} } }, {0, { {"angrt", 5} } }, + {1, { {(void *)multi_cp_html5_02220} } }, {0, { {"angmsd", 6} } }, {0, { {"angsph", 6} } }, {0, { {"mid", 3} } }, + {0, { {"nshortmid", 9} } }, {0, { {"shortparallel", 13} } }, {0, { {"nparallel", 9} } }, {0, { {"and", 3} } }, + {0, { {"or", 2} } }, {1, { {(void *)multi_cp_html5_02229} } }, {1, { {(void *)multi_cp_html5_0222A} } }, {0, { {"Integral", 8} } }, + {0, { {"Int", 3} } }, {0, { {"tint", 4} } }, {0, { {"ContourIntegral", 15} } }, {0, { {"DoubleContourIntegral", 21} } }, + {0, { {"Cconint", 7} } }, {0, { {"cwint", 5} } }, {0, { {"cwconint", 8} } }, {0, { {"awconint", 8} } }, + {0, { {"there4", 6} } }, {0, { {"Because", 7} } }, {0, { {"ratio", 5} } }, {0, { {"Colon", 5} } }, + {0, { {"minusd", 6} } }, {0, { {NULL, 0} } }, {0, { {"mDDot", 5} } }, {0, { {"homtht", 6} } }, + {1, { {(void *)multi_cp_html5_0223C} } }, {1, { {(void *)multi_cp_html5_0223D} } }, {1, { {(void *)multi_cp_html5_0223E} } }, {0, { {"acd", 3} } }, }; static const entity_stage3_row stage3_table_html5_02240[] = { - {0, "wr", 2}, {0, "NotTilde", 8}, {1, (void*)multi_cp_html5_02242}, {0, "simeq", 5}, - {0, "nsime", 5}, {0, "TildeFullEqual", 14}, {0, "simne", 5}, {0, "ncong", 5}, - {0, "approx", 6}, {0, "napprox", 7}, {0, "ape", 3}, {1, (void*)multi_cp_html5_0224B}, - {0, "bcong", 5}, {1, (void*)multi_cp_html5_0224D}, {1, (void*)multi_cp_html5_0224E}, {1, (void*)multi_cp_html5_0224F}, - {1, (void*)multi_cp_html5_02250}, {0, "doteqdot", 8}, {0, "fallingdotseq", 13}, {0, "risingdotseq", 12}, - {0, "coloneq", 7}, {0, "eqcolon", 7}, {0, "ecir", 4}, {0, "circeq", 6}, - {0, NULL, 0}, {0, "wedgeq", 6}, {0, "veeeq", 5}, {0, NULL, 0}, - {0, "triangleq", 9}, {0, NULL, 0}, {0, NULL, 0}, {0, "equest", 6}, - {0, "NotEqual", 8}, {1, (void*)multi_cp_html5_02261}, {0, "NotCongruent", 12}, {0, NULL, 0}, - {1, (void*)multi_cp_html5_02264}, {1, (void*)multi_cp_html5_02265}, {1, (void*)multi_cp_html5_02266}, {1, (void*)multi_cp_html5_02267}, - {1, (void*)multi_cp_html5_02268}, {1, (void*)multi_cp_html5_02269}, {1, (void*)multi_cp_html5_0226A}, {1, (void*)multi_cp_html5_0226B}, - {0, "between", 7}, {0, "NotCupCap", 9}, {0, "NotLess", 7}, {0, "ngtr", 4}, - {0, "NotLessEqual", 12}, {0, "ngeq", 4}, {0, "LessTilde", 9}, {0, "GreaterTilde", 12}, - {0, "nlsim", 5}, {0, "ngsim", 5}, {0, "lessgtr", 7}, {0, "gl", 2}, - {0, "ntlg", 4}, {0, "NotGreaterLess", 14}, {0, "prec", 4}, {0, "succ", 4}, - {0, "PrecedesSlantEqual", 18}, {0, "succcurlyeq", 11}, {0, "precsim", 7}, {1, (void*)multi_cp_html5_0227F}, + {0, { {"wr", 2} } }, {0, { {"NotTilde", 8} } }, {1, { {(void *)multi_cp_html5_02242} } }, {0, { {"simeq", 5} } }, + {0, { {"nsime", 5} } }, {0, { {"TildeFullEqual", 14} } }, {0, { {"simne", 5} } }, {0, { {"ncong", 5} } }, + {0, { {"approx", 6} } }, {0, { {"napprox", 7} } }, {0, { {"ape", 3} } }, {1, { {(void *)multi_cp_html5_0224B} } }, + {0, { {"bcong", 5} } }, {1, { {(void *)multi_cp_html5_0224D} } }, {1, { {(void *)multi_cp_html5_0224E} } }, {1, { {(void *)multi_cp_html5_0224F} } }, + {1, { {(void *)multi_cp_html5_02250} } }, {0, { {"doteqdot", 8} } }, {0, { {"fallingdotseq", 13} } }, {0, { {"risingdotseq", 12} } }, + {0, { {"coloneq", 7} } }, {0, { {"eqcolon", 7} } }, {0, { {"ecir", 4} } }, {0, { {"circeq", 6} } }, + {0, { {NULL, 0} } }, {0, { {"wedgeq", 6} } }, {0, { {"veeeq", 5} } }, {0, { {NULL, 0} } }, + {0, { {"triangleq", 9} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"equest", 6} } }, + {0, { {"NotEqual", 8} } }, {1, { {(void *)multi_cp_html5_02261} } }, {0, { {"NotCongruent", 12} } }, {0, { {NULL, 0} } }, + {1, { {(void *)multi_cp_html5_02264} } }, {1, { {(void *)multi_cp_html5_02265} } }, {1, { {(void *)multi_cp_html5_02266} } }, {1, { {(void *)multi_cp_html5_02267} } }, + {1, { {(void *)multi_cp_html5_02268} } }, {1, { {(void *)multi_cp_html5_02269} } }, {1, { {(void *)multi_cp_html5_0226A} } }, {1, { {(void *)multi_cp_html5_0226B} } }, + {0, { {"between", 7} } }, {0, { {"NotCupCap", 9} } }, {0, { {"NotLess", 7} } }, {0, { {"ngtr", 4} } }, + {0, { {"NotLessEqual", 12} } }, {0, { {"ngeq", 4} } }, {0, { {"LessTilde", 9} } }, {0, { {"GreaterTilde", 12} } }, + {0, { {"nlsim", 5} } }, {0, { {"ngsim", 5} } }, {0, { {"lessgtr", 7} } }, {0, { {"gl", 2} } }, + {0, { {"ntlg", 4} } }, {0, { {"NotGreaterLess", 14} } }, {0, { {"prec", 4} } }, {0, { {"succ", 4} } }, + {0, { {"PrecedesSlantEqual", 18} } }, {0, { {"succcurlyeq", 11} } }, {0, { {"precsim", 7} } }, {1, { {(void *)multi_cp_html5_0227F} } }, }; static const entity_stage3_row stage3_table_html5_02280[] = { - {0, "npr", 3}, {0, "NotSucceeds", 11}, {1, (void*)multi_cp_html5_02282}, {1, (void*)multi_cp_html5_02283}, - {0, "nsub", 4}, {0, "nsup", 4}, {0, "SubsetEqual", 11}, {0, "supe", 4}, - {0, "NotSubsetEqual", 14}, {0, "NotSupersetEqual", 16}, {1, (void*)multi_cp_html5_0228A}, {1, (void*)multi_cp_html5_0228B}, - {0, NULL, 0}, {0, "cupdot", 6}, {0, "UnionPlus", 9}, {1, (void*)multi_cp_html5_0228F}, - {1, (void*)multi_cp_html5_02290}, {0, "SquareSubsetEqual", 17}, {0, "SquareSupersetEqual", 19}, {1, (void*)multi_cp_html5_02293}, - {1, (void*)multi_cp_html5_02294}, {0, "CirclePlus", 10}, {0, "ominus", 6}, {0, "CircleTimes", 11}, - {0, "osol", 4}, {0, "CircleDot", 9}, {0, "ocir", 4}, {0, "oast", 4}, - {0, NULL, 0}, {0, "odash", 5}, {0, "boxplus", 7}, {0, "boxminus", 8}, - {0, "timesb", 6}, {0, "sdotb", 5}, {0, "vdash", 5}, {0, "dashv", 5}, - {0, "DownTee", 7}, {0, "perp", 4}, {0, NULL, 0}, {0, "models", 6}, - {0, "DoubleRightTee", 14}, {0, "Vdash", 5}, {0, "Vvdash", 6}, {0, "VDash", 5}, - {0, "nvdash", 6}, {0, "nvDash", 6}, {0, "nVdash", 6}, {0, "nVDash", 6}, - {0, "prurel", 6}, {0, NULL, 0}, {0, "vartriangleleft", 15}, {0, "vrtri", 5}, - {1, (void*)multi_cp_html5_022B4}, {1, (void*)multi_cp_html5_022B5}, {0, "origof", 6}, {0, "imof", 4}, - {0, "mumap", 5}, {0, "hercon", 6}, {0, "intcal", 6}, {0, "veebar", 6}, - {0, NULL, 0}, {0, "barvee", 6}, {0, "angrtvb", 7}, {0, "lrtri", 5}, + {0, { {"npr", 3} } }, {0, { {"NotSucceeds", 11} } }, {1, { {(void *)multi_cp_html5_02282} } }, {1, { {(void *)multi_cp_html5_02283} } }, + {0, { {"nsub", 4} } }, {0, { {"nsup", 4} } }, {0, { {"SubsetEqual", 11} } }, {0, { {"supe", 4} } }, + {0, { {"NotSubsetEqual", 14} } }, {0, { {"NotSupersetEqual", 16} } }, {1, { {(void *)multi_cp_html5_0228A} } }, {1, { {(void *)multi_cp_html5_0228B} } }, + {0, { {NULL, 0} } }, {0, { {"cupdot", 6} } }, {0, { {"UnionPlus", 9} } }, {1, { {(void *)multi_cp_html5_0228F} } }, + {1, { {(void *)multi_cp_html5_02290} } }, {0, { {"SquareSubsetEqual", 17} } }, {0, { {"SquareSupersetEqual", 19} } }, {1, { {(void *)multi_cp_html5_02293} } }, + {1, { {(void *)multi_cp_html5_02294} } }, {0, { {"CirclePlus", 10} } }, {0, { {"ominus", 6} } }, {0, { {"CircleTimes", 11} } }, + {0, { {"osol", 4} } }, {0, { {"CircleDot", 9} } }, {0, { {"ocir", 4} } }, {0, { {"oast", 4} } }, + {0, { {NULL, 0} } }, {0, { {"odash", 5} } }, {0, { {"boxplus", 7} } }, {0, { {"boxminus", 8} } }, + {0, { {"timesb", 6} } }, {0, { {"sdotb", 5} } }, {0, { {"vdash", 5} } }, {0, { {"dashv", 5} } }, + {0, { {"DownTee", 7} } }, {0, { {"perp", 4} } }, {0, { {NULL, 0} } }, {0, { {"models", 6} } }, + {0, { {"DoubleRightTee", 14} } }, {0, { {"Vdash", 5} } }, {0, { {"Vvdash", 6} } }, {0, { {"VDash", 5} } }, + {0, { {"nvdash", 6} } }, {0, { {"nvDash", 6} } }, {0, { {"nVdash", 6} } }, {0, { {"nVDash", 6} } }, + {0, { {"prurel", 6} } }, {0, { {NULL, 0} } }, {0, { {"vartriangleleft", 15} } }, {0, { {"vrtri", 5} } }, + {1, { {(void *)multi_cp_html5_022B4} } }, {1, { {(void *)multi_cp_html5_022B5} } }, {0, { {"origof", 6} } }, {0, { {"imof", 4} } }, + {0, { {"mumap", 5} } }, {0, { {"hercon", 6} } }, {0, { {"intcal", 6} } }, {0, { {"veebar", 6} } }, + {0, { {NULL, 0} } }, {0, { {"barvee", 6} } }, {0, { {"angrtvb", 7} } }, {0, { {"lrtri", 5} } }, }; static const entity_stage3_row stage3_table_html5_022C0[] = { - {0, "xwedge", 6}, {0, "xvee", 4}, {0, "bigcap", 6}, {0, "bigcup", 6}, - {0, "diamond", 7}, {0, "sdot", 4}, {0, "Star", 4}, {0, "divonx", 6}, - {0, "bowtie", 6}, {0, "ltimes", 6}, {0, "rtimes", 6}, {0, "lthree", 6}, - {0, "rthree", 6}, {0, "backsimeq", 9}, {0, "curlyvee", 8}, {0, "curlywedge", 10}, - {0, "Sub", 3}, {0, "Supset", 6}, {0, "Cap", 3}, {0, "Cup", 3}, - {0, "pitchfork", 9}, {0, "epar", 4}, {0, "lessdot", 7}, {0, "gtrdot", 6}, - {1, (void*)multi_cp_html5_022D8}, {1, (void*)multi_cp_html5_022D9}, {1, (void*)multi_cp_html5_022DA}, {1, (void*)multi_cp_html5_022DB}, - {0, NULL, 0}, {0, NULL, 0}, {0, "curlyeqprec", 11}, {0, "cuesc", 5}, - {0, "NotPrecedesSlantEqual", 21}, {0, "NotSucceedsSlantEqual", 21}, {0, "NotSquareSubsetEqual", 20}, {0, "NotSquareSupersetEqual", 22}, - {0, NULL, 0}, {0, NULL, 0}, {0, "lnsim", 5}, {0, "gnsim", 5}, - {0, "precnsim", 8}, {0, "scnsim", 6}, {0, "nltri", 5}, {0, "ntriangleright", 14}, - {0, "nltrie", 6}, {0, "NotRightTriangleEqual", 21}, {0, "vellip", 6}, {0, "ctdot", 5}, - {0, "utdot", 5}, {0, "dtdot", 5}, {0, "disin", 5}, {0, "isinsv", 6}, - {0, "isins", 5}, {1, (void*)multi_cp_html5_022F5}, {0, "notinvc", 7}, {0, "notinvb", 7}, - {0, NULL, 0}, {1, (void*)multi_cp_html5_022F9}, {0, "nisd", 4}, {0, "xnis", 4}, - {0, "nis", 3}, {0, "notnivc", 7}, {0, "notnivb", 7}, {0, NULL, 0}, + {0, { {"xwedge", 6} } }, {0, { {"xvee", 4} } }, {0, { {"bigcap", 6} } }, {0, { {"bigcup", 6} } }, + {0, { {"diamond", 7} } }, {0, { {"sdot", 4} } }, {0, { {"Star", 4} } }, {0, { {"divonx", 6} } }, + {0, { {"bowtie", 6} } }, {0, { {"ltimes", 6} } }, {0, { {"rtimes", 6} } }, {0, { {"lthree", 6} } }, + {0, { {"rthree", 6} } }, {0, { {"backsimeq", 9} } }, {0, { {"curlyvee", 8} } }, {0, { {"curlywedge", 10} } }, + {0, { {"Sub", 3} } }, {0, { {"Supset", 6} } }, {0, { {"Cap", 3} } }, {0, { {"Cup", 3} } }, + {0, { {"pitchfork", 9} } }, {0, { {"epar", 4} } }, {0, { {"lessdot", 7} } }, {0, { {"gtrdot", 6} } }, + {1, { {(void *)multi_cp_html5_022D8} } }, {1, { {(void *)multi_cp_html5_022D9} } }, {1, { {(void *)multi_cp_html5_022DA} } }, {1, { {(void *)multi_cp_html5_022DB} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"curlyeqprec", 11} } }, {0, { {"cuesc", 5} } }, + {0, { {"NotPrecedesSlantEqual", 21} } }, {0, { {"NotSucceedsSlantEqual", 21} } }, {0, { {"NotSquareSubsetEqual", 20} } }, {0, { {"NotSquareSupersetEqual", 22} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lnsim", 5} } }, {0, { {"gnsim", 5} } }, + {0, { {"precnsim", 8} } }, {0, { {"scnsim", 6} } }, {0, { {"nltri", 5} } }, {0, { {"ntriangleright", 14} } }, + {0, { {"nltrie", 6} } }, {0, { {"NotRightTriangleEqual", 21} } }, {0, { {"vellip", 6} } }, {0, { {"ctdot", 5} } }, + {0, { {"utdot", 5} } }, {0, { {"dtdot", 5} } }, {0, { {"disin", 5} } }, {0, { {"isinsv", 6} } }, + {0, { {"isins", 5} } }, {1, { {(void *)multi_cp_html5_022F5} } }, {0, { {"notinvc", 7} } }, {0, { {"notinvb", 7} } }, + {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_022F9} } }, {0, { {"nisd", 4} } }, {0, { {"xnis", 4} } }, + {0, { {"nis", 3} } }, {0, { {"notnivc", 7} } }, {0, { {"notnivb", 7} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02300[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "barwed", 6}, {0, "doublebarwedge", 14}, {0, NULL, 0}, - {0, "lceil", 5}, {0, "RightCeiling", 12}, {0, "LeftFloor", 9}, {0, "RightFloor", 10}, - {0, "drcrop", 6}, {0, "dlcrop", 6}, {0, "urcrop", 6}, {0, "ulcrop", 6}, - {0, "bnot", 4}, {0, NULL, 0}, {0, "profline", 8}, {0, "profsurf", 8}, - {0, NULL, 0}, {0, "telrec", 6}, {0, "target", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "ulcorner", 8}, {0, "urcorner", 8}, {0, "llcorner", 8}, {0, "drcorn", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, "frown", 5}, {0, "smile", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "cylcty", 6}, {0, "profalar", 8}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "topbot", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "ovbar", 5}, {0, NULL, 0}, {0, "solbar", 6}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"barwed", 6} } }, {0, { {"doublebarwedge", 14} } }, {0, { {NULL, 0} } }, + {0, { {"lceil", 5} } }, {0, { {"RightCeiling", 12} } }, {0, { {"LeftFloor", 9} } }, {0, { {"RightFloor", 10} } }, + {0, { {"drcrop", 6} } }, {0, { {"dlcrop", 6} } }, {0, { {"urcrop", 6} } }, {0, { {"ulcrop", 6} } }, + {0, { {"bnot", 4} } }, {0, { {NULL, 0} } }, {0, { {"profline", 8} } }, {0, { {"profsurf", 8} } }, + {0, { {NULL, 0} } }, {0, { {"telrec", 6} } }, {0, { {"target", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"ulcorner", 8} } }, {0, { {"urcorner", 8} } }, {0, { {"llcorner", 8} } }, {0, { {"drcorn", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"frown", 5} } }, {0, { {"smile", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"cylcty", 6} } }, {0, { {"profalar", 8} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"topbot", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"ovbar", 5} } }, {0, { {NULL, 0} } }, {0, { {"solbar", 6} } }, }; static const entity_stage3_row stage3_table_html5_02340[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "angzarr", 7}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"angzarr", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02380[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lmoust", 6}, {0, "rmoust", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, "OverBracket", 11}, {0, "bbrk", 4}, {0, "bbrktbrk", 8}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lmoust", 6} } }, {0, { {"rmoust", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"OverBracket", 11} } }, {0, { {"bbrk", 4} } }, {0, { {"bbrktbrk", 8} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_023C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "OverParenthesis", 15}, {0, "UnderParenthesis", 16}, {0, "OverBrace", 9}, {0, "UnderBrace", 10}, - {0, NULL, 0}, {0, NULL, 0}, {0, "trpezium", 8}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "elinters", 8}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"OverParenthesis", 15} } }, {0, { {"UnderParenthesis", 16} } }, {0, { {"OverBrace", 9} } }, {0, { {"UnderBrace", 10} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"trpezium", 8} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"elinters", 8} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02400[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "blank", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"blank", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_024C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "oS", 2}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"oS", 2} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02500[] = { - {0, "HorizontalLine", 14}, {0, NULL, 0}, {0, "boxv", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxdr", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxdl", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxur", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxul", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxvr", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxvl", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxhd", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxhu", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxvh", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"HorizontalLine", 14} } }, {0, { {NULL, 0} } }, {0, { {"boxv", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxdr", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxdl", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxur", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxul", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxvr", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxvl", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxhd", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxhu", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxvh", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02540[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "boxH", 4}, {0, "boxV", 4}, {0, "boxdR", 5}, {0, "boxDr", 5}, - {0, "boxDR", 5}, {0, "boxdL", 5}, {0, "boxDl", 5}, {0, "boxDL", 5}, - {0, "boxuR", 5}, {0, "boxUr", 5}, {0, "boxUR", 5}, {0, "boxuL", 5}, - {0, "boxUl", 5}, {0, "boxUL", 5}, {0, "boxvR", 5}, {0, "boxVr", 5}, - {0, "boxVR", 5}, {0, "boxvL", 5}, {0, "boxVl", 5}, {0, "boxVL", 5}, - {0, "boxHd", 5}, {0, "boxhD", 5}, {0, "boxHD", 5}, {0, "boxHu", 5}, - {0, "boxhU", 5}, {0, "boxHU", 5}, {0, "boxvH", 5}, {0, "boxVh", 5}, - {0, "boxVH", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"boxH", 4} } }, {0, { {"boxV", 4} } }, {0, { {"boxdR", 5} } }, {0, { {"boxDr", 5} } }, + {0, { {"boxDR", 5} } }, {0, { {"boxdL", 5} } }, {0, { {"boxDl", 5} } }, {0, { {"boxDL", 5} } }, + {0, { {"boxuR", 5} } }, {0, { {"boxUr", 5} } }, {0, { {"boxUR", 5} } }, {0, { {"boxuL", 5} } }, + {0, { {"boxUl", 5} } }, {0, { {"boxUL", 5} } }, {0, { {"boxvR", 5} } }, {0, { {"boxVr", 5} } }, + {0, { {"boxVR", 5} } }, {0, { {"boxvL", 5} } }, {0, { {"boxVl", 5} } }, {0, { {"boxVL", 5} } }, + {0, { {"boxHd", 5} } }, {0, { {"boxhD", 5} } }, {0, { {"boxHD", 5} } }, {0, { {"boxHu", 5} } }, + {0, { {"boxhU", 5} } }, {0, { {"boxHU", 5} } }, {0, { {"boxvH", 5} } }, {0, { {"boxVh", 5} } }, + {0, { {"boxVH", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02580[] = { - {0, "uhblk", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lhblk", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "block", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "blk14", 5}, {0, "blk12", 5}, {0, "blk34", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Square", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "squarf", 6}, {0, "EmptyVerySmallSquare", 20}, - {0, NULL, 0}, {0, "rect", 4}, {0, "marker", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, "fltns", 5}, {0, NULL, 0}, {0, "bigtriangleup", 13}, - {0, "blacktriangle", 13}, {0, "triangle", 8}, {0, NULL, 0}, {0, NULL, 0}, - {0, "blacktriangleright", 18}, {0, "rtri", 4}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "bigtriangledown", 15}, {0, "blacktriangledown", 17}, {0, "triangledown", 12}, + {0, { {"uhblk", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lhblk", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"block", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"blk14", 5} } }, {0, { {"blk12", 5} } }, {0, { {"blk34", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Square", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"squarf", 6} } }, {0, { {"EmptyVerySmallSquare", 20} } }, + {0, { {NULL, 0} } }, {0, { {"rect", 4} } }, {0, { {"marker", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"fltns", 5} } }, {0, { {NULL, 0} } }, {0, { {"bigtriangleup", 13} } }, + {0, { {"blacktriangle", 13} } }, {0, { {"triangle", 8} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"blacktriangleright", 18} } }, {0, { {"rtri", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"bigtriangledown", 15} } }, {0, { {"blacktriangledown", 17} } }, {0, { {"triangledown", 12} } }, }; static const entity_stage3_row stage3_table_html5_025C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, "blacktriangleleft", 17}, {0, "ltri", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "lozenge", 7}, {0, "cir", 3}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "tridot", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, "bigcirc", 7}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "ultri", 5}, {0, "urtri", 5}, {0, "lltri", 5}, {0, "EmptySmallSquare", 16}, - {0, "FilledSmallSquare", 17}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"blacktriangleleft", 17} } }, {0, { {"ltri", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lozenge", 7} } }, {0, { {"cir", 3} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"tridot", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"bigcirc", 7} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"ultri", 5} } }, {0, { {"urtri", 5} } }, {0, { {"lltri", 5} } }, {0, { {"EmptySmallSquare", 16} } }, + {0, { {"FilledSmallSquare", 17} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02600[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "starf", 5}, {0, "star", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "phone", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"starf", 5} } }, {0, { {"star", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"phone", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02640[] = { - {0, "female", 6}, {0, NULL, 0}, {0, "male", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "spadesuit", 9}, {0, NULL, 0}, {0, NULL, 0}, {0, "clubs", 5}, - {0, NULL, 0}, {0, "hearts", 6}, {0, "diamondsuit", 11}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "sung", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, "flat", 4}, {0, "natur", 5}, {0, "sharp", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"female", 6} } }, {0, { {NULL, 0} } }, {0, { {"male", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"spadesuit", 9} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"clubs", 5} } }, + {0, { {NULL, 0} } }, {0, { {"hearts", 6} } }, {0, { {"diamondsuit", 11} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"sung", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"flat", 4} } }, {0, { {"natur", 5} } }, {0, { {"sharp", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02700[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "check", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "cross", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "maltese", 7}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "sext", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"check", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"cross", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"maltese", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"sext", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02740[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "VerticalSeparator", 17}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "lbbrk", 5}, {0, "rbbrk", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"VerticalSeparator", 17} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lbbrk", 5} } }, {0, { {"rbbrk", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_027C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "bsolhsub", 8}, {0, "suphsol", 7}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "LeftDoubleBracket", 17}, {0, "RightDoubleBracket", 18}, - {0, "langle", 6}, {0, "RightAngleBracket", 17}, {0, "Lang", 4}, {0, "Rang", 4}, - {0, "loang", 5}, {0, "roang", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "longleftarrow", 13}, {0, "LongRightArrow", 14}, {0, "LongLeftRightArrow", 18}, - {0, "xlArr", 5}, {0, "DoubleLongRightArrow", 20}, {0, "xhArr", 5}, {0, NULL, 0}, - {0, "xmap", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, "dzigrarr", 8}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"bsolhsub", 8} } }, {0, { {"suphsol", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"LeftDoubleBracket", 17} } }, {0, { {"RightDoubleBracket", 18} } }, + {0, { {"langle", 6} } }, {0, { {"RightAngleBracket", 17} } }, {0, { {"Lang", 4} } }, {0, { {"Rang", 4} } }, + {0, { {"loang", 5} } }, {0, { {"roang", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"longleftarrow", 13} } }, {0, { {"LongRightArrow", 14} } }, {0, { {"LongLeftRightArrow", 18} } }, + {0, { {"xlArr", 5} } }, {0, { {"DoubleLongRightArrow", 20} } }, {0, { {"xhArr", 5} } }, {0, { {NULL, 0} } }, + {0, { {"xmap", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"dzigrarr", 8} } }, }; static const entity_stage3_row stage3_table_html5_02900[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, "nvlArr", 6}, {0, "nvrArr", 6}, - {0, "nvHarr", 6}, {0, "Map", 3}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lbarr", 5}, {0, "bkarow", 6}, {0, "lBarr", 5}, {0, "dbkarow", 7}, - {0, "drbkarow", 8}, {0, "DDotrahd", 8}, {0, "UpArrowBar", 10}, {0, "DownArrowBar", 12}, - {0, NULL, 0}, {0, NULL, 0}, {0, "Rarrtl", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, "latail", 6}, {0, "ratail", 6}, {0, "lAtail", 6}, - {0, "rAtail", 6}, {0, "larrfs", 6}, {0, "rarrfs", 6}, {0, "larrbfs", 7}, - {0, "rarrbfs", 7}, {0, NULL, 0}, {0, NULL, 0}, {0, "nwarhk", 6}, - {0, "nearhk", 6}, {0, "searhk", 6}, {0, "swarhk", 6}, {0, "nwnear", 6}, - {0, "toea", 4}, {0, "seswar", 6}, {0, "swnwar", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {1, (void*)multi_cp_html5_02933}, - {0, NULL, 0}, {0, "cudarrr", 7}, {0, "ldca", 4}, {0, "rdca", 4}, - {0, "cudarrl", 7}, {0, "larrpl", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, "curarrm", 7}, {0, "cularrp", 7}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"nvlArr", 6} } }, {0, { {"nvrArr", 6} } }, + {0, { {"nvHarr", 6} } }, {0, { {"Map", 3} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lbarr", 5} } }, {0, { {"bkarow", 6} } }, {0, { {"lBarr", 5} } }, {0, { {"dbkarow", 7} } }, + {0, { {"drbkarow", 8} } }, {0, { {"DDotrahd", 8} } }, {0, { {"UpArrowBar", 10} } }, {0, { {"DownArrowBar", 12} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"Rarrtl", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"latail", 6} } }, {0, { {"ratail", 6} } }, {0, { {"lAtail", 6} } }, + {0, { {"rAtail", 6} } }, {0, { {"larrfs", 6} } }, {0, { {"rarrfs", 6} } }, {0, { {"larrbfs", 7} } }, + {0, { {"rarrbfs", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"nwarhk", 6} } }, + {0, { {"nearhk", 6} } }, {0, { {"searhk", 6} } }, {0, { {"swarhk", 6} } }, {0, { {"nwnear", 6} } }, + {0, { {"toea", 4} } }, {0, { {"seswar", 6} } }, {0, { {"swnwar", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_02933} } }, + {0, { {NULL, 0} } }, {0, { {"cudarrr", 7} } }, {0, { {"ldca", 4} } }, {0, { {"rdca", 4} } }, + {0, { {"cudarrl", 7} } }, {0, { {"larrpl", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"curarrm", 7} } }, {0, { {"cularrp", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02940[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "rarrpl", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, "harrcir", 7}, {0, "Uarrocir", 8}, {0, "lurdshar", 8}, {0, "ldrushar", 8}, - {0, NULL, 0}, {0, NULL, 0}, {0, "LeftRightVector", 15}, {0, "RightUpDownVector", 17}, - {0, "DownLeftRightVector", 19}, {0, "LeftUpDownVector", 16}, {0, "LeftVectorBar", 13}, {0, "RightVectorBar", 14}, - {0, "RightUpVectorBar", 16}, {0, "RightDownVectorBar", 18}, {0, "DownLeftVectorBar", 17}, {0, "DownRightVectorBar", 18}, - {0, "LeftUpVectorBar", 15}, {0, "LeftDownVectorBar", 17}, {0, "LeftTeeVector", 13}, {0, "RightTeeVector", 14}, - {0, "RightUpTeeVector", 16}, {0, "RightDownTeeVector", 18}, {0, "DownLeftTeeVector", 17}, {0, "DownRightTeeVector", 18}, - {0, "LeftUpTeeVector", 15}, {0, "LeftDownTeeVector", 17}, {0, "lHar", 4}, {0, "uHar", 4}, - {0, "rHar", 4}, {0, "dHar", 4}, {0, "luruhar", 7}, {0, "ldrdhar", 7}, - {0, "ruluhar", 7}, {0, "rdldhar", 7}, {0, "lharul", 6}, {0, "llhard", 6}, - {0, "rharul", 6}, {0, "lrhard", 6}, {0, "udhar", 5}, {0, "ReverseUpEquilibrium", 20}, - {0, "RoundImplies", 12}, {0, "erarr", 5}, {0, "simrarr", 7}, {0, "larrsim", 7}, - {0, "rarrsim", 7}, {0, "rarrap", 6}, {0, "ltlarr", 6}, {0, NULL, 0}, - {0, "gtrarr", 6}, {0, "subrarr", 7}, {0, NULL, 0}, {0, "suplarr", 7}, - {0, "lfisht", 6}, {0, "rfisht", 6}, {0, "ufisht", 6}, {0, "dfisht", 6}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"rarrpl", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"harrcir", 7} } }, {0, { {"Uarrocir", 8} } }, {0, { {"lurdshar", 8} } }, {0, { {"ldrushar", 8} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"LeftRightVector", 15} } }, {0, { {"RightUpDownVector", 17} } }, + {0, { {"DownLeftRightVector", 19} } }, {0, { {"LeftUpDownVector", 16} } }, {0, { {"LeftVectorBar", 13} } }, {0, { {"RightVectorBar", 14} } }, + {0, { {"RightUpVectorBar", 16} } }, {0, { {"RightDownVectorBar", 18} } }, {0, { {"DownLeftVectorBar", 17} } }, {0, { {"DownRightVectorBar", 18} } }, + {0, { {"LeftUpVectorBar", 15} } }, {0, { {"LeftDownVectorBar", 17} } }, {0, { {"LeftTeeVector", 13} } }, {0, { {"RightTeeVector", 14} } }, + {0, { {"RightUpTeeVector", 16} } }, {0, { {"RightDownTeeVector", 18} } }, {0, { {"DownLeftTeeVector", 17} } }, {0, { {"DownRightTeeVector", 18} } }, + {0, { {"LeftUpTeeVector", 15} } }, {0, { {"LeftDownTeeVector", 17} } }, {0, { {"lHar", 4} } }, {0, { {"uHar", 4} } }, + {0, { {"rHar", 4} } }, {0, { {"dHar", 4} } }, {0, { {"luruhar", 7} } }, {0, { {"ldrdhar", 7} } }, + {0, { {"ruluhar", 7} } }, {0, { {"rdldhar", 7} } }, {0, { {"lharul", 6} } }, {0, { {"llhard", 6} } }, + {0, { {"rharul", 6} } }, {0, { {"lrhard", 6} } }, {0, { {"udhar", 5} } }, {0, { {"ReverseUpEquilibrium", 20} } }, + {0, { {"RoundImplies", 12} } }, {0, { {"erarr", 5} } }, {0, { {"simrarr", 7} } }, {0, { {"larrsim", 7} } }, + {0, { {"rarrsim", 7} } }, {0, { {"rarrap", 6} } }, {0, { {"ltlarr", 6} } }, {0, { {NULL, 0} } }, + {0, { {"gtrarr", 6} } }, {0, { {"subrarr", 7} } }, {0, { {NULL, 0} } }, {0, { {"suplarr", 7} } }, + {0, { {"lfisht", 6} } }, {0, { {"rfisht", 6} } }, {0, { {"ufisht", 6} } }, {0, { {"dfisht", 6} } }, }; static const entity_stage3_row stage3_table_html5_02980[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "lopar", 5}, {0, "ropar", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "lbrke", 5}, - {0, "rbrke", 5}, {0, "lbrkslu", 7}, {0, "rbrksld", 7}, {0, "lbrksld", 7}, - {0, "rbrkslu", 7}, {0, "langd", 5}, {0, "rangd", 5}, {0, "lparlt", 6}, - {0, "rpargt", 6}, {0, "gtlPar", 6}, {0, "ltrPar", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "vzigzag", 7}, {0, NULL, 0}, - {0, "vangrt", 6}, {0, "angrtvbd", 8}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "ange", 4}, {0, "range", 5}, {0, "dwangle", 7}, {0, "uwangle", 7}, - {0, "angmsdaa", 8}, {0, "angmsdab", 8}, {0, "angmsdac", 8}, {0, "angmsdad", 8}, - {0, "angmsdae", 8}, {0, "angmsdaf", 8}, {0, "angmsdag", 8}, {0, "angmsdah", 8}, - {0, "bemptyv", 7}, {0, "demptyv", 7}, {0, "cemptyv", 7}, {0, "raemptyv", 8}, - {0, "laemptyv", 8}, {0, "ohbar", 5}, {0, "omid", 4}, {0, "opar", 4}, - {0, NULL, 0}, {0, "operp", 5}, {0, NULL, 0}, {0, "olcross", 7}, - {0, "odsold", 6}, {0, NULL, 0}, {0, "olcir", 5}, {0, "ofcir", 5}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"lopar", 5} } }, {0, { {"ropar", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lbrke", 5} } }, + {0, { {"rbrke", 5} } }, {0, { {"lbrkslu", 7} } }, {0, { {"rbrksld", 7} } }, {0, { {"lbrksld", 7} } }, + {0, { {"rbrkslu", 7} } }, {0, { {"langd", 5} } }, {0, { {"rangd", 5} } }, {0, { {"lparlt", 6} } }, + {0, { {"rpargt", 6} } }, {0, { {"gtlPar", 6} } }, {0, { {"ltrPar", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"vzigzag", 7} } }, {0, { {NULL, 0} } }, + {0, { {"vangrt", 6} } }, {0, { {"angrtvbd", 8} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"ange", 4} } }, {0, { {"range", 5} } }, {0, { {"dwangle", 7} } }, {0, { {"uwangle", 7} } }, + {0, { {"angmsdaa", 8} } }, {0, { {"angmsdab", 8} } }, {0, { {"angmsdac", 8} } }, {0, { {"angmsdad", 8} } }, + {0, { {"angmsdae", 8} } }, {0, { {"angmsdaf", 8} } }, {0, { {"angmsdag", 8} } }, {0, { {"angmsdah", 8} } }, + {0, { {"bemptyv", 7} } }, {0, { {"demptyv", 7} } }, {0, { {"cemptyv", 7} } }, {0, { {"raemptyv", 8} } }, + {0, { {"laemptyv", 8} } }, {0, { {"ohbar", 5} } }, {0, { {"omid", 4} } }, {0, { {"opar", 4} } }, + {0, { {NULL, 0} } }, {0, { {"operp", 5} } }, {0, { {NULL, 0} } }, {0, { {"olcross", 7} } }, + {0, { {"odsold", 6} } }, {0, { {NULL, 0} } }, {0, { {"olcir", 5} } }, {0, { {"ofcir", 5} } }, }; static const entity_stage3_row stage3_table_html5_029C0[] = { - {0, "olt", 3}, {0, "ogt", 3}, {0, "cirscir", 7}, {0, "cirE", 4}, - {0, "solb", 4}, {0, "bsolb", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "boxbox", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "trisb", 5}, {0, "rtriltri", 8}, {1, (void*)multi_cp_html5_029CF}, - {1, (void*)multi_cp_html5_029D0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "iinfin", 6}, {0, "infintie", 8}, {0, "nvinfin", 7}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "eparsl", 6}, - {0, "smeparsl", 8}, {0, "eqvparsl", 8}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "lozf", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "RuleDelayed", 11}, {0, NULL, 0}, {0, "dsol", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"olt", 3} } }, {0, { {"ogt", 3} } }, {0, { {"cirscir", 7} } }, {0, { {"cirE", 4} } }, + {0, { {"solb", 4} } }, {0, { {"bsolb", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"boxbox", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"trisb", 5} } }, {0, { {"rtriltri", 8} } }, {1, { {(void *)multi_cp_html5_029CF} } }, + {1, { {(void *)multi_cp_html5_029D0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"iinfin", 6} } }, {0, { {"infintie", 8} } }, {0, { {"nvinfin", 7} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"eparsl", 6} } }, + {0, { {"smeparsl", 8} } }, {0, { {"eqvparsl", 8} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lozf", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"RuleDelayed", 11} } }, {0, { {NULL, 0} } }, {0, { {"dsol", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_02A00[] = { - {0, "xodot", 5}, {0, "bigoplus", 8}, {0, "bigotimes", 9}, {0, NULL, 0}, - {0, "biguplus", 8}, {0, NULL, 0}, {0, "bigsqcup", 8}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "iiiint", 6}, {0, "fpartint", 8}, {0, NULL, 0}, {0, NULL, 0}, - {0, "cirfnint", 8}, {0, "awint", 5}, {0, "rppolint", 8}, {0, "scpolint", 8}, - {0, "npolint", 7}, {0, "pointint", 8}, {0, "quatint", 7}, {0, "intlarhk", 8}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "pluscir", 7}, {0, "plusacir", 8}, - {0, "simplus", 7}, {0, "plusdu", 6}, {0, "plussim", 7}, {0, "plustwo", 7}, - {0, NULL, 0}, {0, "mcomma", 6}, {0, "minusdu", 7}, {0, NULL, 0}, - {0, NULL, 0}, {0, "loplus", 6}, {0, "roplus", 6}, {0, "Cross", 5}, - {0, "timesd", 6}, {0, "timesbar", 8}, {0, NULL, 0}, {0, "smashp", 6}, - {0, "lotimes", 7}, {0, "rotimes", 7}, {0, "otimesas", 8}, {0, "Otimes", 6}, - {0, "odiv", 4}, {0, "triplus", 7}, {0, "triminus", 8}, {0, "tritime", 7}, - {0, "iprod", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, "amalg", 5}, + {0, { {"xodot", 5} } }, {0, { {"bigoplus", 8} } }, {0, { {"bigotimes", 9} } }, {0, { {NULL, 0} } }, + {0, { {"biguplus", 8} } }, {0, { {NULL, 0} } }, {0, { {"bigsqcup", 8} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"iiiint", 6} } }, {0, { {"fpartint", 8} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"cirfnint", 8} } }, {0, { {"awint", 5} } }, {0, { {"rppolint", 8} } }, {0, { {"scpolint", 8} } }, + {0, { {"npolint", 7} } }, {0, { {"pointint", 8} } }, {0, { {"quatint", 7} } }, {0, { {"intlarhk", 8} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"pluscir", 7} } }, {0, { {"plusacir", 8} } }, + {0, { {"simplus", 7} } }, {0, { {"plusdu", 6} } }, {0, { {"plussim", 7} } }, {0, { {"plustwo", 7} } }, + {0, { {NULL, 0} } }, {0, { {"mcomma", 6} } }, {0, { {"minusdu", 7} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"loplus", 6} } }, {0, { {"roplus", 6} } }, {0, { {"Cross", 5} } }, + {0, { {"timesd", 6} } }, {0, { {"timesbar", 8} } }, {0, { {NULL, 0} } }, {0, { {"smashp", 6} } }, + {0, { {"lotimes", 7} } }, {0, { {"rotimes", 7} } }, {0, { {"otimesas", 8} } }, {0, { {"Otimes", 6} } }, + {0, { {"odiv", 4} } }, {0, { {"triplus", 7} } }, {0, { {"triminus", 8} } }, {0, { {"tritime", 7} } }, + {0, { {"iprod", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"amalg", 5} } }, }; static const entity_stage3_row stage3_table_html5_02A40[] = { - {0, "capdot", 6}, {0, NULL, 0}, {0, "ncup", 4}, {0, "ncap", 4}, - {0, "capand", 6}, {0, "cupor", 5}, {0, "cupcap", 6}, {0, "capcup", 6}, - {0, "cupbrcap", 8}, {0, "capbrcup", 8}, {0, "cupcup", 6}, {0, "capcap", 6}, - {0, "ccups", 5}, {0, "ccaps", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, "ccupssm", 7}, {0, NULL, 0}, {0, NULL, 0}, {0, "And", 3}, - {0, "Or", 2}, {0, "andand", 6}, {0, "oror", 4}, {0, "orslope", 7}, - {0, "andslope", 8}, {0, NULL, 0}, {0, "andv", 4}, {0, "orv", 3}, - {0, "andd", 4}, {0, "ord", 3}, {0, NULL, 0}, {0, "wedbar", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "sdote", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "simdot", 6}, {0, NULL, 0}, - {0, NULL, 0}, {1, (void*)multi_cp_html5_02A6D}, {0, "easter", 6}, {0, "apacir", 6}, - {1, (void*)multi_cp_html5_02A70}, {0, "eplus", 5}, {0, "pluse", 5}, {0, "Esim", 4}, - {0, "Colone", 6}, {0, "Equal", 5}, {0, NULL, 0}, {0, "ddotseq", 7}, - {0, "equivDD", 7}, {0, "ltcir", 5}, {0, "gtcir", 5}, {0, "ltquest", 7}, - {0, "gtquest", 7}, {1, (void*)multi_cp_html5_02A7D}, {1, (void*)multi_cp_html5_02A7E}, {0, "lesdot", 6}, + {0, { {"capdot", 6} } }, {0, { {NULL, 0} } }, {0, { {"ncup", 4} } }, {0, { {"ncap", 4} } }, + {0, { {"capand", 6} } }, {0, { {"cupor", 5} } }, {0, { {"cupcap", 6} } }, {0, { {"capcup", 6} } }, + {0, { {"cupbrcap", 8} } }, {0, { {"capbrcup", 8} } }, {0, { {"cupcup", 6} } }, {0, { {"capcap", 6} } }, + {0, { {"ccups", 5} } }, {0, { {"ccaps", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"ccupssm", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"And", 3} } }, + {0, { {"Or", 2} } }, {0, { {"andand", 6} } }, {0, { {"oror", 4} } }, {0, { {"orslope", 7} } }, + {0, { {"andslope", 8} } }, {0, { {NULL, 0} } }, {0, { {"andv", 4} } }, {0, { {"orv", 3} } }, + {0, { {"andd", 4} } }, {0, { {"ord", 3} } }, {0, { {NULL, 0} } }, {0, { {"wedbar", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"sdote", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"simdot", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_02A6D} } }, {0, { {"easter", 6} } }, {0, { {"apacir", 6} } }, + {1, { {(void *)multi_cp_html5_02A70} } }, {0, { {"eplus", 5} } }, {0, { {"pluse", 5} } }, {0, { {"Esim", 4} } }, + {0, { {"Colone", 6} } }, {0, { {"Equal", 5} } }, {0, { {NULL, 0} } }, {0, { {"ddotseq", 7} } }, + {0, { {"equivDD", 7} } }, {0, { {"ltcir", 5} } }, {0, { {"gtcir", 5} } }, {0, { {"ltquest", 7} } }, + {0, { {"gtquest", 7} } }, {1, { {(void *)multi_cp_html5_02A7D} } }, {1, { {(void *)multi_cp_html5_02A7E} } }, {0, { {"lesdot", 6} } }, }; static const entity_stage3_row stage3_table_html5_02A80[] = { - {0, "gesdot", 6}, {0, "lesdoto", 7}, {0, "gesdoto", 7}, {0, "lesdotor", 8}, - {0, "gesdotol", 8}, {0, "lap", 3}, {0, "gap", 3}, {0, "lne", 3}, - {0, "gne", 3}, {0, "lnap", 4}, {0, "gnap", 4}, {0, "lesseqqgtr", 10}, - {0, "gEl", 3}, {0, "lsime", 5}, {0, "gsime", 5}, {0, "lsimg", 5}, - {0, "gsiml", 5}, {0, "lgE", 3}, {0, "glE", 3}, {0, "lesges", 6}, - {0, "gesles", 6}, {0, "els", 3}, {0, "egs", 3}, {0, "elsdot", 6}, - {0, "egsdot", 6}, {0, "el", 2}, {0, "eg", 2}, {0, NULL, 0}, - {0, NULL, 0}, {0, "siml", 4}, {0, "simg", 4}, {0, "simlE", 5}, - {0, "simgE", 5}, {1, (void*)multi_cp_html5_02AA1}, {1, (void*)multi_cp_html5_02AA2}, {0, NULL, 0}, - {0, "glj", 3}, {0, "gla", 3}, {0, "ltcc", 4}, {0, "gtcc", 4}, - {0, "lescc", 5}, {0, "gescc", 5}, {0, "smt", 3}, {0, "lat", 3}, - {1, (void*)multi_cp_html5_02AAC}, {1, (void*)multi_cp_html5_02AAD}, {0, "bumpE", 5}, {1, (void*)multi_cp_html5_02AAF}, - {1, (void*)multi_cp_html5_02AB0}, {0, NULL, 0}, {0, NULL, 0}, {0, "prE", 3}, - {0, "scE", 3}, {0, "precneqq", 8}, {0, "scnE", 4}, {0, "precapprox", 10}, - {0, "succapprox", 10}, {0, "precnapprox", 11}, {0, "succnapprox", 11}, {0, "Pr", 2}, - {0, "Sc", 2}, {0, "subdot", 6}, {0, "supdot", 6}, {0, "subplus", 7}, + {0, { {"gesdot", 6} } }, {0, { {"lesdoto", 7} } }, {0, { {"gesdoto", 7} } }, {0, { {"lesdotor", 8} } }, + {0, { {"gesdotol", 8} } }, {0, { {"lap", 3} } }, {0, { {"gap", 3} } }, {0, { {"lne", 3} } }, + {0, { {"gne", 3} } }, {0, { {"lnap", 4} } }, {0, { {"gnap", 4} } }, {0, { {"lesseqqgtr", 10} } }, + {0, { {"gEl", 3} } }, {0, { {"lsime", 5} } }, {0, { {"gsime", 5} } }, {0, { {"lsimg", 5} } }, + {0, { {"gsiml", 5} } }, {0, { {"lgE", 3} } }, {0, { {"glE", 3} } }, {0, { {"lesges", 6} } }, + {0, { {"gesles", 6} } }, {0, { {"els", 3} } }, {0, { {"egs", 3} } }, {0, { {"elsdot", 6} } }, + {0, { {"egsdot", 6} } }, {0, { {"el", 2} } }, {0, { {"eg", 2} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"siml", 4} } }, {0, { {"simg", 4} } }, {0, { {"simlE", 5} } }, + {0, { {"simgE", 5} } }, {1, { {(void *)multi_cp_html5_02AA1} } }, {1, { {(void *)multi_cp_html5_02AA2} } }, {0, { {NULL, 0} } }, + {0, { {"glj", 3} } }, {0, { {"gla", 3} } }, {0, { {"ltcc", 4} } }, {0, { {"gtcc", 4} } }, + {0, { {"lescc", 5} } }, {0, { {"gescc", 5} } }, {0, { {"smt", 3} } }, {0, { {"lat", 3} } }, + {1, { {(void *)multi_cp_html5_02AAC} } }, {1, { {(void *)multi_cp_html5_02AAD} } }, {0, { {"bumpE", 5} } }, {1, { {(void *)multi_cp_html5_02AAF} } }, + {1, { {(void *)multi_cp_html5_02AB0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"prE", 3} } }, + {0, { {"scE", 3} } }, {0, { {"precneqq", 8} } }, {0, { {"scnE", 4} } }, {0, { {"precapprox", 10} } }, + {0, { {"succapprox", 10} } }, {0, { {"precnapprox", 11} } }, {0, { {"succnapprox", 11} } }, {0, { {"Pr", 2} } }, + {0, { {"Sc", 2} } }, {0, { {"subdot", 6} } }, {0, { {"supdot", 6} } }, {0, { {"subplus", 7} } }, }; static const entity_stage3_row stage3_table_html5_02AC0[] = { - {0, "supplus", 7}, {0, "submult", 7}, {0, "supmult", 7}, {0, "subedot", 7}, - {0, "supedot", 7}, {1, (void*)multi_cp_html5_02AC5}, {1, (void*)multi_cp_html5_02AC6}, {0, "subsim", 6}, - {0, "supsim", 6}, {0, NULL, 0}, {0, NULL, 0}, {1, (void*)multi_cp_html5_02ACB}, - {1, (void*)multi_cp_html5_02ACC}, {0, NULL, 0}, {0, NULL, 0}, {0, "csub", 4}, - {0, "csup", 4}, {0, "csube", 5}, {0, "csupe", 5}, {0, "subsup", 6}, - {0, "supsub", 6}, {0, "subsub", 6}, {0, "supsup", 6}, {0, "suphsub", 7}, - {0, "supdsub", 7}, {0, "forkv", 5}, {0, "topfork", 7}, {0, "mlcp", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Dashv", 5}, {0, NULL, 0}, {0, "Vdashl", 6}, {0, "Barv", 4}, - {0, "vBar", 4}, {0, "vBarv", 5}, {0, NULL, 0}, {0, "Vbar", 4}, - {0, "Not", 3}, {0, "bNot", 4}, {0, "rnmid", 5}, {0, "cirmid", 6}, - {0, "midcir", 6}, {0, "topcir", 6}, {0, "nhpar", 5}, {0, "parsim", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {1, (void*)multi_cp_html5_02AFD}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"supplus", 7} } }, {0, { {"submult", 7} } }, {0, { {"supmult", 7} } }, {0, { {"subedot", 7} } }, + {0, { {"supedot", 7} } }, {1, { {(void *)multi_cp_html5_02AC5} } }, {1, { {(void *)multi_cp_html5_02AC6} } }, {0, { {"subsim", 6} } }, + {0, { {"supsim", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_02ACB} } }, + {1, { {(void *)multi_cp_html5_02ACC} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"csub", 4} } }, + {0, { {"csup", 4} } }, {0, { {"csube", 5} } }, {0, { {"csupe", 5} } }, {0, { {"subsup", 6} } }, + {0, { {"supsub", 6} } }, {0, { {"subsub", 6} } }, {0, { {"supsup", 6} } }, {0, { {"suphsub", 7} } }, + {0, { {"supdsub", 7} } }, {0, { {"forkv", 5} } }, {0, { {"topfork", 7} } }, {0, { {"mlcp", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Dashv", 5} } }, {0, { {NULL, 0} } }, {0, { {"Vdashl", 6} } }, {0, { {"Barv", 4} } }, + {0, { {"vBar", 4} } }, {0, { {"vBarv", 5} } }, {0, { {NULL, 0} } }, {0, { {"Vbar", 4} } }, + {0, { {"Not", 3} } }, {0, { {"bNot", 4} } }, {0, { {"rnmid", 5} } }, {0, { {"cirmid", 6} } }, + {0, { {"midcir", 6} } }, {0, { {"topcir", 6} } }, {0, { {"nhpar", 5} } }, {0, { {"parsim", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {1, { {(void *)multi_cp_html5_02AFD} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_0FB00[] = { - {0, "fflig", 5}, {0, "filig", 5}, {0, "fllig", 5}, {0, "ffilig", 6}, - {0, "ffllig", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"fflig", 5} } }, {0, { {"filig", 5} } }, {0, { {"fllig", 5} } }, {0, { {"ffilig", 6} } }, + {0, { {"ffllig", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_1D480[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Ascr", 4}, {0, NULL, 0}, {0, "Cscr", 4}, {0, "Dscr", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, "Gscr", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Jscr", 4}, {0, "Kscr", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Nscr", 4}, {0, "Oscr", 4}, {0, "Pscr", 4}, - {0, "Qscr", 4}, {0, NULL, 0}, {0, "Sscr", 4}, {0, "Tscr", 4}, - {0, "Uscr", 4}, {0, "Vscr", 4}, {0, "Wscr", 4}, {0, "Xscr", 4}, - {0, "Yscr", 4}, {0, "Zscr", 4}, {0, "ascr", 4}, {0, "bscr", 4}, - {0, "cscr", 4}, {0, "dscr", 4}, {0, NULL, 0}, {0, "fscr", 4}, - {0, NULL, 0}, {0, "hscr", 4}, {0, "iscr", 4}, {0, "jscr", 4}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Ascr", 4} } }, {0, { {NULL, 0} } }, {0, { {"Cscr", 4} } }, {0, { {"Dscr", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"Gscr", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Jscr", 4} } }, {0, { {"Kscr", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Nscr", 4} } }, {0, { {"Oscr", 4} } }, {0, { {"Pscr", 4} } }, + {0, { {"Qscr", 4} } }, {0, { {NULL, 0} } }, {0, { {"Sscr", 4} } }, {0, { {"Tscr", 4} } }, + {0, { {"Uscr", 4} } }, {0, { {"Vscr", 4} } }, {0, { {"Wscr", 4} } }, {0, { {"Xscr", 4} } }, + {0, { {"Yscr", 4} } }, {0, { {"Zscr", 4} } }, {0, { {"ascr", 4} } }, {0, { {"bscr", 4} } }, + {0, { {"cscr", 4} } }, {0, { {"dscr", 4} } }, {0, { {NULL, 0} } }, {0, { {"fscr", 4} } }, + {0, { {NULL, 0} } }, {0, { {"hscr", 4} } }, {0, { {"iscr", 4} } }, {0, { {"jscr", 4} } }, }; static const entity_stage3_row stage3_table_html5_1D4C0[] = { - {0, "kscr", 4}, {0, "lscr", 4}, {0, "mscr", 4}, {0, "nscr", 4}, - {0, NULL, 0}, {0, "pscr", 4}, {0, "qscr", 4}, {0, "rscr", 4}, - {0, "sscr", 4}, {0, "tscr", 4}, {0, "uscr", 4}, {0, "vscr", 4}, - {0, "wscr", 4}, {0, "xscr", 4}, {0, "yscr", 4}, {0, "zscr", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"kscr", 4} } }, {0, { {"lscr", 4} } }, {0, { {"mscr", 4} } }, {0, { {"nscr", 4} } }, + {0, { {NULL, 0} } }, {0, { {"pscr", 4} } }, {0, { {"qscr", 4} } }, {0, { {"rscr", 4} } }, + {0, { {"sscr", 4} } }, {0, { {"tscr", 4} } }, {0, { {"uscr", 4} } }, {0, { {"vscr", 4} } }, + {0, { {"wscr", 4} } }, {0, { {"xscr", 4} } }, {0, { {"yscr", 4} } }, {0, { {"zscr", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_1D500[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Afr", 3}, {0, "Bfr", 3}, {0, NULL, 0}, {0, "Dfr", 3}, - {0, "Efr", 3}, {0, "Ffr", 3}, {0, "Gfr", 3}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Jfr", 3}, {0, "Kfr", 3}, {0, "Lfr", 3}, - {0, "Mfr", 3}, {0, "Nfr", 3}, {0, "Ofr", 3}, {0, "Pfr", 3}, - {0, "Qfr", 3}, {0, NULL, 0}, {0, "Sfr", 3}, {0, "Tfr", 3}, - {0, "Ufr", 3}, {0, "Vfr", 3}, {0, "Wfr", 3}, {0, "Xfr", 3}, - {0, "Yfr", 3}, {0, NULL, 0}, {0, "afr", 3}, {0, "bfr", 3}, - {0, "cfr", 3}, {0, "dfr", 3}, {0, "efr", 3}, {0, "ffr", 3}, - {0, "gfr", 3}, {0, "hfr", 3}, {0, "ifr", 3}, {0, "jfr", 3}, - {0, "kfr", 3}, {0, "lfr", 3}, {0, "mfr", 3}, {0, "nfr", 3}, - {0, "ofr", 3}, {0, "pfr", 3}, {0, "qfr", 3}, {0, "rfr", 3}, - {0, "sfr", 3}, {0, "tfr", 3}, {0, "ufr", 3}, {0, "vfr", 3}, - {0, "wfr", 3}, {0, "xfr", 3}, {0, "yfr", 3}, {0, "zfr", 3}, - {0, "Aopf", 4}, {0, "Bopf", 4}, {0, NULL, 0}, {0, "Dopf", 4}, - {0, "Eopf", 4}, {0, "Fopf", 4}, {0, "Gopf", 4}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Afr", 3} } }, {0, { {"Bfr", 3} } }, {0, { {NULL, 0} } }, {0, { {"Dfr", 3} } }, + {0, { {"Efr", 3} } }, {0, { {"Ffr", 3} } }, {0, { {"Gfr", 3} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Jfr", 3} } }, {0, { {"Kfr", 3} } }, {0, { {"Lfr", 3} } }, + {0, { {"Mfr", 3} } }, {0, { {"Nfr", 3} } }, {0, { {"Ofr", 3} } }, {0, { {"Pfr", 3} } }, + {0, { {"Qfr", 3} } }, {0, { {NULL, 0} } }, {0, { {"Sfr", 3} } }, {0, { {"Tfr", 3} } }, + {0, { {"Ufr", 3} } }, {0, { {"Vfr", 3} } }, {0, { {"Wfr", 3} } }, {0, { {"Xfr", 3} } }, + {0, { {"Yfr", 3} } }, {0, { {NULL, 0} } }, {0, { {"afr", 3} } }, {0, { {"bfr", 3} } }, + {0, { {"cfr", 3} } }, {0, { {"dfr", 3} } }, {0, { {"efr", 3} } }, {0, { {"ffr", 3} } }, + {0, { {"gfr", 3} } }, {0, { {"hfr", 3} } }, {0, { {"ifr", 3} } }, {0, { {"jfr", 3} } }, + {0, { {"kfr", 3} } }, {0, { {"lfr", 3} } }, {0, { {"mfr", 3} } }, {0, { {"nfr", 3} } }, + {0, { {"ofr", 3} } }, {0, { {"pfr", 3} } }, {0, { {"qfr", 3} } }, {0, { {"rfr", 3} } }, + {0, { {"sfr", 3} } }, {0, { {"tfr", 3} } }, {0, { {"ufr", 3} } }, {0, { {"vfr", 3} } }, + {0, { {"wfr", 3} } }, {0, { {"xfr", 3} } }, {0, { {"yfr", 3} } }, {0, { {"zfr", 3} } }, + {0, { {"Aopf", 4} } }, {0, { {"Bopf", 4} } }, {0, { {NULL, 0} } }, {0, { {"Dopf", 4} } }, + {0, { {"Eopf", 4} } }, {0, { {"Fopf", 4} } }, {0, { {"Gopf", 4} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html5_1D540[] = { - {0, "Iopf", 4}, {0, "Jopf", 4}, {0, "Kopf", 4}, {0, "Lopf", 4}, - {0, "Mopf", 4}, {0, NULL, 0}, {0, "Oopf", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "Sopf", 4}, {0, "Topf", 4}, - {0, "Uopf", 4}, {0, "Vopf", 4}, {0, "Wopf", 4}, {0, "Xopf", 4}, - {0, "Yopf", 4}, {0, NULL, 0}, {0, "aopf", 4}, {0, "bopf", 4}, - {0, "copf", 4}, {0, "dopf", 4}, {0, "eopf", 4}, {0, "fopf", 4}, - {0, "gopf", 4}, {0, "hopf", 4}, {0, "iopf", 4}, {0, "jopf", 4}, - {0, "kopf", 4}, {0, "lopf", 4}, {0, "mopf", 4}, {0, "nopf", 4}, - {0, "oopf", 4}, {0, "popf", 4}, {0, "qopf", 4}, {0, "ropf", 4}, - {0, "sopf", 4}, {0, "topf", 4}, {0, "uopf", 4}, {0, "vopf", 4}, - {0, "wopf", 4}, {0, "xopf", 4}, {0, "yopf", 4}, {0, "zopf", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"Iopf", 4} } }, {0, { {"Jopf", 4} } }, {0, { {"Kopf", 4} } }, {0, { {"Lopf", 4} } }, + {0, { {"Mopf", 4} } }, {0, { {NULL, 0} } }, {0, { {"Oopf", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"Sopf", 4} } }, {0, { {"Topf", 4} } }, + {0, { {"Uopf", 4} } }, {0, { {"Vopf", 4} } }, {0, { {"Wopf", 4} } }, {0, { {"Xopf", 4} } }, + {0, { {"Yopf", 4} } }, {0, { {NULL, 0} } }, {0, { {"aopf", 4} } }, {0, { {"bopf", 4} } }, + {0, { {"copf", 4} } }, {0, { {"dopf", 4} } }, {0, { {"eopf", 4} } }, {0, { {"fopf", 4} } }, + {0, { {"gopf", 4} } }, {0, { {"hopf", 4} } }, {0, { {"iopf", 4} } }, {0, { {"jopf", 4} } }, + {0, { {"kopf", 4} } }, {0, { {"lopf", 4} } }, {0, { {"mopf", 4} } }, {0, { {"nopf", 4} } }, + {0, { {"oopf", 4} } }, {0, { {"popf", 4} } }, {0, { {"qopf", 4} } }, {0, { {"ropf", 4} } }, + {0, { {"sopf", 4} } }, {0, { {"topf", 4} } }, {0, { {"uopf", 4} } }, {0, { {"vopf", 4} } }, + {0, { {"wopf", 4} } }, {0, { {"xopf", 4} } }, {0, { {"yopf", 4} } }, {0, { {"zopf", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; /* end of stage 3 Tables for HTML5 }}} */ @@ -2615,1683 +2615,1683 @@ typedef struct { const entity_ht_bucket *buckets; /* .num_elems elements */ } entity_ht; -static const entity_cp_map ht_bucket_empty[] = { NULL }; -static const entity_cp_map ht_bucket_html5_000[] = { {"realpart", 8, 0x0211C, 0}, {"varr", 4, 0x02195, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_001[] = { {"angrt", 5, 0x0221F, 0}, {"iogon", 5, 0x0012F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_003[] = { {"lessdot", 7, 0x022D6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_005[] = { {"simrarr", 7, 0x02972, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_007[] = { {"Zscr", 4, 0x1D4B5, 0}, {"midast", 6, 0x0002A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_00D[] = { {"copf", 4, 0x1D554, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_00F[] = { {"female", 6, 0x02640, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_017[] = { {"NegativeThickSpace", 18, 0x0200B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_020[] = { {"copy", 4, 0x000A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_022[] = { {"angst", 5, 0x000C5, 0}, {"searr", 5, 0x02198, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_024[] = { {"sqcups", 6, 0x02294, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_027[] = { {"Acirc", 5, 0x000C2, 0}, {"gtdot", 5, 0x022D7, 0}, {"varpi", 5, 0x003D6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_028[] = { {"UpTee", 5, 0x022A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_029[] = { {"TildeTilde", 10, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_02A[] = { {"mfr", 3, 0x1D52A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_02B[] = { {"RightVectorBar", 14, 0x02953, 0}, {"gesdot", 6, 0x02A80, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_02C[] = { {"Uarrocir", 8, 0x02949, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_02E[] = { {"RightTriangleBar", 16, 0x029D0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_030[] = { {"Ocy", 3, 0x0041E, 0}, {"int", 3, 0x0222B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_034[] = { {"preccurlyeq", 11, 0x0227C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_038[] = { {"sccue", 5, 0x0227D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_040[] = { {"DoubleContourIntegral", 21, 0x0222F, 0}, {"nexist", 6, 0x02204, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_047[] = { {"acirc", 5, 0x000E2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_04C[] = { {"setmn", 5, 0x02216, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_04E[] = { {"Dopf", 4, 0x1D53B, 0}, {"LeftTee", 7, 0x022A3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_051[] = { {"SquareSuperset", 14, 0x02290, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_059[] = { {"udhar", 5, 0x0296E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_05D[] = { {"Equal", 5, 0x02A75, 0}, {"pscr", 4, 0x1D4C5, 0}, {"xvee", 4, 0x022C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_05F[] = { {"approx", 6, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_060[] = { {"HARDcy", 6, 0x0042A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_061[] = { {"nGg", 3, 0x022D9, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_063[] = { {"yopf", 4, 0x1D56A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_064[] = { {"prcue", 5, 0x0227C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_065[] = { {"loarr", 5, 0x021FD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_069[] = { {"mho", 3, 0x02127, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_06A[] = { {"otimesas", 8, 0x02A36, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_06D[] = { {"capcap", 6, 0x02A4B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_06E[] = { {"eplus", 5, 0x02A71, 0}, {"nGt", 3, 0x0226B, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_06F[] = { {"Bumpeq", 6, 0x0224E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_071[] = { {"submult", 7, 0x02AC1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_073[] = { {"subplus", 7, 0x02ABF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_074[] = { {"auml", 4, 0x000E4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_07A[] = { {"RightDoubleBracket", 18, 0x027E7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_07B[] = { {"varkappa", 8, 0x003F0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_07C[] = { {"plusdo", 6, 0x02214, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_07F[] = { {"mid", 3, 0x02223, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_082[] = { {"plusdu", 6, 0x02A25, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_084[] = { {"notniva", 7, 0x0220C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_085[] = { {"notnivb", 7, 0x022FE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_086[] = { {"notnivc", 7, 0x022FD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_088[] = { {"varepsilon", 10, 0x003F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_089[] = { {"nspar", 5, 0x02226, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_08C[] = { {"Ofr", 3, 0x1D512, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_08E[] = { {"Omega", 5, 0x003A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_090[] = { {"equals", 6, 0x0003D, 0}, {"harrcir", 7, 0x02948, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_094[] = { {"Succeeds", 8, 0x0227B, 0}, {"cupdot", 6, 0x0228D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_097[] = { {"lsqb", 4, 0x0005B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_09E[] = { {"Qscr", 4, 0x1D4AC, 0}, {"urcorn", 6, 0x0231D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0A4[] = { {"Zopf", 4, 0x02124, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0A6[] = { {"triangleleft", 12, 0x025C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0AB[] = { {"supdsub", 7, 0x02AD8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0AC[] = { {"chcy", 4, 0x00447, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0AD[] = { {"sqsupset", 8, 0x02290, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0AE[] = { {"omega", 5, 0x003C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0AF[] = { {"rthree", 6, 0x022CC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0B0[] = { {"THORN", 5, 0x000DE, 0}, {"clubsuit", 8, 0x02663, 0}, {"filig", 5, 0x0FB01, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0B2[] = { {"ocir", 4, 0x0229A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0B8[] = { {"ShortDownArrow", 14, 0x02193, 0}, {"atilde", 6, 0x000E3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0B9[] = { {"DownLeftTeeVector", 17, 0x0295E, 0}, {"LeftTeeArrow", 12, 0x021A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0BA[] = { {"GreaterFullEqual", 16, 0x02267, 0}, {"emsp", 4, 0x02003, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0C0[] = { {"lozf", 4, 0x029EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0C4[] = { {"ThinSpace", 9, 0x02009, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0CE[] = { {"fnof", 4, 0x00192, 0}, {"multimap", 8, 0x022B8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0D1[] = { {"Zacute", 6, 0x00179, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0D2[] = { {"mdash", 5, 0x02014, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0D3[] = { {"minusb", 6, 0x0229F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0D5[] = { {"minusd", 6, 0x02238, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0DF[] = { {"varsigma", 8, 0x003C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0E5[] = { {"ntilde", 6, 0x000F1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0E6[] = { {"Lambda", 6, 0x0039B, 0}, {"integers", 8, 0x02124, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0E8[] = { {"gesles", 6, 0x02A94, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0EC[] = { {"NotSubset", 9, 0x02282, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0EF[] = { {"NotLeftTriangleEqual", 20, 0x022EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0F3[] = { {"LessLess", 8, 0x02AA1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0F4[] = { {"gscr", 4, 0x0210A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0FA[] = { {"popf", 4, 0x1D561, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0FB[] = { {"Agrave", 6, 0x000C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0FD[] = { {"nvinfin", 7, 0x029DE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_0FE[] = { {"gacute", 6, 0x001F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_100[] = { {"diam", 4, 0x022C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_101[] = { {"nesim", 5, 0x02242, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_103[] = { {"YIcy", 4, 0x00407, 0}, {"bcy", 3, 0x00431, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_105[] = { {"Exists", 6, 0x02203, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_106[] = { {"vert", 4, 0x0007C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_109[] = { {"ropar", 5, 0x02986, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_10A[] = { {"topfork", 7, 0x02ADA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_10B[] = { {"nLl", 3, 0x022D8, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_10D[] = { {"notin", 5, 0x02209, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_10E[] = { {"SucceedsSlantEqual", 18, 0x0227D, 0}, {"toea", 4, 0x02928, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_10F[] = { {"ImaginaryI", 10, 0x02148, 0}, {"srarr", 5, 0x02192, 0}, {"ulcorner", 8, 0x0231C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_110[] = { {"LeftArrowBar", 12, 0x021E4, 0}, {"ldsh", 4, 0x021B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_111[] = { {"DownBreve", 9, 0x00311, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_113[] = { {"nLt", 3, 0x0226A, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_116[] = { {"vltri", 5, 0x022B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_11B[] = { {"VDash", 5, 0x022AB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_11C[] = { {"Dstrok", 6, 0x00110, 0}, {"Intersection", 12, 0x022C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_11E[] = { {"lrhar", 5, 0x021CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_121[] = { {"RightTee", 8, 0x022A2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_124[] = { {"RightArrowLeftArrow", 19, 0x021C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_129[] = { {"Ccirc", 5, 0x00108, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_12A[] = { {"ntrianglelefteq", 15, 0x022EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_12C[] = { {"leftharpoonup", 13, 0x021BC, 0}, {"scap", 4, 0x02AB8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_12E[] = { {"darr", 4, 0x02193, 0}, {"qfr", 3, 0x1D52E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_12F[] = { {"cdot", 4, 0x0010B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_130[] = { {"supseteqq", 9, 0x02AC6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_134[] = { {"Scy", 3, 0x00421, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_135[] = { {"Hscr", 4, 0x0210B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_137[] = { {"LowerRightArrow", 15, 0x02198, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_13A[] = { {"divide", 6, 0x000F7, 0}, {"tcedil", 6, 0x00163, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_13B[] = { {"LeftArrow", 9, 0x02190, 0}, {"Qopf", 4, 0x0211A, 0}, {"vDash", 5, 0x022A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_145[] = { {"dash", 4, 0x02010, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_147[] = { {"oror", 4, 0x02A56, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_149[] = { {"ccirc", 5, 0x00109, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_14B[] = { {"LongLeftArrow", 13, 0x027F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_14C[] = { {"straightphi", 11, 0x003D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_14E[] = { {"xlarr", 5, 0x027F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_14F[] = { {"DJcy", 4, 0x00402, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_158[] = { {"nbsp", 4, 0x000A0, 0}, {"succcurlyeq", 11, 0x0227D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_159[] = { {"njcy", 4, 0x0045A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_15B[] = { {"Leftarrow", 9, 0x021D0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_15E[] = { {"dtrif", 5, 0x025BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_15F[] = { {"bfr", 3, 0x1D51F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_161[] = { {"GreaterTilde", 12, 0x02273, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_164[] = { {"hamilt", 6, 0x0210B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_165[] = { {"Dcy", 3, 0x00414, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_168[] = { {"LeftUpVector", 12, 0x021BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_16A[] = { {"bigoplus", 8, 0x02A01, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_170[] = { {"nwarhk", 6, 0x02923, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_173[] = { {"diams", 5, 0x02666, 0}, {"suphsol", 7, 0x027C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_17A[] = { {"boxminus", 8, 0x0229F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_17B[] = { {"leftarrow", 9, 0x02190, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_17C[] = { {"andd", 4, 0x02A5C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_17F[] = { {"NonBreakingSpace", 16, 0x000A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_181[] = { {"xutri", 5, 0x025B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_189[] = { {"Longleftrightarrow", 18, 0x027FA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_18B[] = { {"Longleftarrow", 13, 0x027F8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_18C[] = { {"gtrapprox", 9, 0x02A86, 0}, {"phmmat", 6, 0x02133, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_18E[] = { {"andv", 4, 0x02A5A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_18F[] = { {"equiv", 5, 0x02261, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_190[] = { {"Sfr", 3, 0x1D516, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_191[] = { {"gopf", 4, 0x1D558, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_193[] = { {"sqsub", 5, 0x0228F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_195[] = { {"approxeq", 8, 0x0224A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_19A[] = { {"Del", 3, 0x02207, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_19C[] = { {"nrightarrow", 11, 0x0219B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_19F[] = { {"SquareUnion", 11, 0x02294, 0}, {"strns", 5, 0x000AF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A0[] = { {"Itilde", 6, 0x00128, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A1[] = { {"sqsup", 5, 0x02290, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A2[] = { {"Ouml", 4, 0x000D6, 0}, {"PrecedesTilde", 13, 0x0227E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A3[] = { {"AMP", 3, 0x00026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A4[] = { {"plusmn", 6, 0x000B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A5[] = { {"xcup", 4, 0x022C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1A8[] = { {"radic", 5, 0x0221A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1AB[] = { {"longleftarrow", 13, 0x027F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1AC[] = { {"lrcorner", 8, 0x0231F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1AD[] = { {"notni", 5, 0x0220C, 0}, {"updownarrow", 11, 0x02195, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1AE[] = { {"szlig", 5, 0x000DF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1AF[] = { {"ugrave", 6, 0x000F9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1B0[] = { {"imof", 4, 0x022B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1B2[] = { {"csub", 4, 0x02ACF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1B5[] = { {"gsim", 4, 0x02273, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1B9[] = { {"leftleftarrows", 14, 0x021C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1BD[] = { {"backcong", 8, 0x0224C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1BE[] = { {"clubs", 5, 0x02663, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1C0[] = { {"csup", 4, 0x02AD0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1C1[] = { {"Dfr", 3, 0x1D507, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1C4[] = { {"profline", 8, 0x02312, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1C6[] = { {"Zdot", 4, 0x0017B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1C9[] = { {"ClockwiseContourIntegral", 24, 0x02232, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1CA[] = { {"roplus", 6, 0x02A2E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1CD[] = { {"Rang", 4, 0x027EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1CE[] = { {"bcong", 5, 0x0224C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D0[] = { {"tshcy", 5, 0x0045B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D1[] = { {"eDot", 4, 0x02251, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D2[] = { {"Hopf", 4, 0x0210D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D4[] = { {"lpar", 4, 0x00028, 0}, {"odash", 5, 0x0229D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D5[] = { {"capbrcup", 8, 0x02A49, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D6[] = { {"ucy", 3, 0x00443, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D8[] = { {"ofcir", 5, 0x029BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1D9[] = { {"Breve", 5, 0x002D8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1DA[] = { {"barvee", 6, 0x022BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1DF[] = { {"backsim", 7, 0x0223D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1E0[] = { {"ange", 4, 0x029A4, 0}, {"half", 4, 0x000BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1E1[] = { {"tscr", 4, 0x1D4C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1E5[] = { {"realine", 7, 0x0211B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1E6[] = { {"Oacute", 6, 0x000D3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1E7[] = { {"dfisht", 6, 0x0297F, 0}, {"swnwar", 6, 0x0292A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1E8[] = { {"tscy", 4, 0x00446, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1EB[] = { {"lsquor", 6, 0x0201A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1EF[] = { {"naturals", 8, 0x02115, 0}, {"utrif", 5, 0x025B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1F0[] = { {"DiacriticalTilde", 16, 0x002DC, 0}, {"RightUpVectorBar", 16, 0x02954, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1F2[] = { {"rHar", 4, 0x02964, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1F4[] = { {"curlyeqprec", 11, 0x022DE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1F8[] = { {"dtri", 4, 0x025BF, 0}, {"euml", 4, 0x000EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1F9[] = { {"breve", 5, 0x002D8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1FA[] = { {"Barwed", 6, 0x02306, 0}, {"nvlArr", 6, 0x02902, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1FC[] = { {"dcaron", 6, 0x0010F, 0}, {"natural", 7, 0x0266E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1FE[] = { {"nsupseteqq", 10, 0x02AC6, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_1FF[] = { {"nedot", 5, 0x02250, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_205[] = { {"bigtriangledown", 15, 0x025BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_207[] = { {"fcy", 3, 0x00444, 0}, {"marker", 6, 0x025AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_20E[] = { {"Union", 5, 0x022C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_212[] = { {"varpropto", 9, 0x0221D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_213[] = { {"CloseCurlyDoubleQuote", 21, 0x0201D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_219[] = { {"DoubleLongRightArrow", 20, 0x027F9, 0}, {"GreaterGreater", 14, 0x02AA2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_21D[] = { {"Umacr", 5, 0x0016A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_220[] = { {"Colon", 5, 0x02237, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_222[] = { {"Hat", 3, 0x0005E, 0}, {"Uscr", 4, 0x1D4B0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_227[] = { {"SHCHcy", 6, 0x00429, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_229[] = { {"nLeftarrow", 10, 0x021CD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_22B[] = { {"Ecirc", 5, 0x000CA, 0}, {"Jukcy", 5, 0x00404, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_22C[] = { {"nbumpe", 6, 0x0224F, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_22D[] = { {"NotLess", 7, 0x0226E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_22F[] = { {"gtlPar", 6, 0x02995, 0}, {"suphsub", 7, 0x02AD7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_230[] = { {"gtreqqless", 10, 0x02A8C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_232[] = { {"ufr", 3, 0x1D532, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_234[] = { {"cirscir", 7, 0x029C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_239[] = { {"LeftDownTeeVector", 17, 0x02961, 0}, {"duhar", 5, 0x0296F, 0}, {"nrtrie", 6, 0x022ED, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_23C[] = { {"llhard", 6, 0x0296B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_23D[] = { {"umacr", 5, 0x0016B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_23E[] = { {"lates", 5, 0x02AAD, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_240[] = { {"colon", 5, 0x0003A, 0}, {"iacute", 6, 0x000ED, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_241[] = { {"NotPrecedes", 11, 0x02280, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_242[] = { {"cirfnint", 8, 0x02A10, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_246[] = { {"barwedge", 8, 0x02305, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_249[] = { {"nleftarrow", 10, 0x0219A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_24A[] = { {"Ubrcy", 5, 0x0040E, 0}, {"leftthreetimes", 14, 0x022CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_24B[] = { {"andand", 6, 0x02A55, 0}, {"ecirc", 5, 0x000EA, 0}, {"jukcy", 5, 0x00454, 0}, {"quatint", 7, 0x02A16, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_24D[] = { {"lharul", 6, 0x0296A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_251[] = { {"smtes", 5, 0x02AAC, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_252[] = { {"UnionPlus", 9, 0x0228E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_257[] = { {"NotLeftTriangle", 15, 0x022EA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_25A[] = { {"bne", 3, 0x0003D, 0x020E5}, {NULL} }; -static const entity_cp_map ht_bucket_html5_25B[] = { {"gtrsim", 6, 0x02273, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_25C[] = { {"Rarr", 4, 0x021A0, 0}, {"ldquor", 6, 0x0201E, 0}, {"phiv", 4, 0x003D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_25D[] = { {"because", 7, 0x02235, 0}, {"gEl", 3, 0x02A8C, 0}, {"setminus", 8, 0x02216, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_263[] = { {"ffr", 3, 0x1D523, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_26A[] = { {"ubrcy", 5, 0x0045E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_26B[] = { {"elinters", 8, 0x023E7, 0}, {"plusb", 5, 0x0229E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_26E[] = { {"pluse", 5, 0x02A72, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_274[] = { {"CapitalDifferentialD", 20, 0x02145, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_277[] = { {"daleth", 6, 0x02138, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_278[] = { {"kscr", 4, 0x1D4C0, 0}, {"ogon", 4, 0x002DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_27C[] = { {"SHcy", 4, 0x00428, 0}, {"equest", 6, 0x0225F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_27E[] = { {"rbarr", 5, 0x0290D, 0}, {"topf", 4, 0x1D565, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_283[] = { {"tritime", 7, 0x02A3B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_28A[] = { {"bot", 3, 0x022A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_294[] = { {"Wfr", 3, 0x1D51A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_297[] = { {"HumpEqual", 9, 0x0224F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_298[] = { {"rightleftharpoons", 17, 0x021CC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_29D[] = { {"frasl", 5, 0x02044, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_29F[] = { {"UnderBracket", 12, 0x023B5, 0}, {"ovbar", 5, 0x0233D, 0}, {"upharpoonright", 14, 0x021BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2A0[] = { {"euro", 4, 0x020AC, 0}, {"nhArr", 5, 0x021CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2A9[] = { {"NotSupersetEqual", 16, 0x02289, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2AE[] = { {"cularr", 6, 0x021B6, 0}, {"scnE", 4, 0x02AB6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2B1[] = { {"napid", 5, 0x0224B, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2B2[] = { {"harr", 4, 0x02194, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2B3[] = { {"gdot", 4, 0x00121, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2B9[] = { {"Lscr", 4, 0x02112, 0}, {"zeta", 4, 0x003B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2BF[] = { {"ENG", 3, 0x0014A, 0}, {"Uopf", 4, 0x1D54C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2C4[] = { {"esdot", 5, 0x02250, 0}, {"scsim", 5, 0x0227F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2C5[] = { {"Hfr", 3, 0x0210C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2CE[] = { {"RightArrow", 10, 0x02192, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2CF[] = { {"Sqrt", 4, 0x0221A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2D3[] = { {"xodot", 5, 0x02A00, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2DA[] = { {"ycy", 3, 0x0044B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2DB[] = { {"hkswarow", 8, 0x02926, 0}, {"urtri", 5, 0x025F9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2DC[] = { {"roang", 5, 0x027ED, 0}, {"tosa", 4, 0x02929, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2E3[] = { {"CircleMinus", 11, 0x02296, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2E4[] = { {"Lcaron", 6, 0x0013D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2EB[] = { {"ShortLeftArrow", 14, 0x02190, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2EC[] = { {"Dot", 3, 0x000A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2EE[] = { {"Rightarrow", 10, 0x021D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2F0[] = { {"prsim", 5, 0x0227E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2F2[] = { {"notinE", 6, 0x022F9, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_2F8[] = { {"becaus", 6, 0x02235, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_300[] = { {"NotEqualTilde", 13, 0x02242, 0x00338}, {"nparallel", 9, 0x02226, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_301[] = { {"capcup", 6, 0x02A47, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_304[] = { {"simeq", 5, 0x02243, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_305[] = { {"forall", 6, 0x02200, 0}, {"straightepsilon", 15, 0x003F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_308[] = { {"ruluhar", 7, 0x02968, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_30B[] = { {"jcy", 3, 0x00439, 0}, {"ltcc", 4, 0x02AA6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_30F[] = { {"bscr", 4, 0x1D4B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_311[] = { {"ExponentialE", 12, 0x02147, 0}, {"weierp", 6, 0x02118, 0}, {"yen", 3, 0x000A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_313[] = { {"blacksquare", 11, 0x025AA, 0}, {"uml", 3, 0x000A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_315[] = { {"backsimeq", 9, 0x022CD, 0}, {"kopf", 4, 0x1D55C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_319[] = { {"NotPrecedesEqual", 16, 0x02AAF, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_31A[] = { {"simgE", 5, 0x02AA0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_31B[] = { {"tridot", 6, 0x025EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_326[] = { {"DoubleLongLeftArrow", 19, 0x027F8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_329[] = { {"models", 6, 0x022A7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_32A[] = { {"emptyv", 6, 0x02205, 0}, {"eqslantgtr", 10, 0x02A96, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_32D[] = { {"Gcirc", 5, 0x0011C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_330[] = { {"bernou", 6, 0x0212C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_331[] = { {"HumpDownHump", 12, 0x0224E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_336[] = { {"yfr", 3, 0x1D536, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_338[] = { {"blacktriangle", 13, 0x025B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_33B[] = { {"yacy", 4, 0x0044F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_33F[] = { {"lsime", 5, 0x02A8D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_340[] = { {"NotTildeEqual", 13, 0x02244, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_341[] = { {"lsimg", 5, 0x02A8F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_347[] = { {"ncap", 4, 0x02A43, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_34D[] = { {"DD", 2, 0x02145, 0}, {"gcirc", 5, 0x0011D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_350[] = { {"Cscr", 4, 0x1D49E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_356[] = { {"Lopf", 4, 0x1D543, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_358[] = { {"lBarr", 5, 0x0290E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_359[] = { {"Leftrightarrow", 14, 0x021D4, 0}, {"gtrdot", 6, 0x022D7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_35D[] = { {"NotSquareSubset", 15, 0x0228F, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_35F[] = { {"sqsubset", 8, 0x0228F, 0}, {"subsetneq", 9, 0x0228A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_361[] = { {"doublebarwedge", 14, 0x02306, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_363[] = { {"blacktriangleleft", 17, 0x025C2, 0}, {"hellip", 6, 0x02026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_365[] = { {"xscr", 4, 0x1D4CD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_367[] = { {"LessFullEqual", 13, 0x02266, 0}, {"jfr", 3, 0x1D527, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_369[] = { {"GreaterSlantEqual", 17, 0x02A7E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_36A[] = { {"Uring", 5, 0x0016E, 0}, {"VeryThinSpace", 13, 0x0200A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_36B[] = { {"roarr", 5, 0x021FE, 0}, {"scaron", 6, 0x00161, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_36D[] = { {"Lcy", 3, 0x0041B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_36E[] = { {"RightDownVector", 15, 0x021C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_36F[] = { {"Sub", 3, 0x022D0, 0}, {"pitchfork", 9, 0x022D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_372[] = { {"nvsim", 5, 0x0223C, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_374[] = { {"xrArr", 5, 0x027F9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_378[] = { {"CloseCurlyQuote", 15, 0x02019, 0}, {"uwangle", 7, 0x029A7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_37A[] = { {"Sum", 3, 0x02211, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_37C[] = { {"iuml", 4, 0x000EF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_37D[] = { {"Sup", 3, 0x022D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_37E[] = { {"planck", 6, 0x0210F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_37F[] = { {"Egrave", 6, 0x000C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_380[] = { {"curlywedge", 10, 0x022CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_382[] = { {"TildeFullEqual", 14, 0x02245, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_383[] = { {"searhk", 6, 0x02925, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_386[] = { {"ETH", 3, 0x000D0, 0}, {"napos", 5, 0x00149, 0}, {"upsi", 4, 0x003C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_387[] = { {"twoheadleftarrow", 16, 0x0219E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_38A[] = { {"Assign", 6, 0x02254, 0}, {"uring", 5, 0x0016F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_38D[] = { {"SquareIntersection", 18, 0x02293, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_38E[] = { {"lmidot", 6, 0x00140, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_391[] = { {"kcedil", 6, 0x00137, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_394[] = { {"curren", 6, 0x000A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_397[] = { {"acute", 5, 0x000B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_398[] = { {"curlyeqsucc", 11, 0x022DF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_39C[] = { {"Omicron", 7, 0x0039F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_39F[] = { {"uarr", 4, 0x02191, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3A0[] = { {"Hstrok", 6, 0x00126, 0}, {"UnderBrace", 10, 0x023DF, 0}, {"tdot", 4, 0x020DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3A1[] = { {"qint", 4, 0x02A0C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3A4[] = { {"sfrown", 6, 0x02322, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3A5[] = { {"trpezium", 8, 0x023E2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3A6[] = { {"Yscr", 4, 0x1D4B4, 0}, {"cedil", 5, 0x000B8, 0}, {"planckh", 7, 0x0210E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3A7[] = { {"lang", 4, 0x027E8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3AC[] = { {"bopf", 4, 0x1D553, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3B2[] = { {"lbbrk", 5, 0x02772, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3B4[] = { {"khcy", 4, 0x00445, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3BF[] = { {"Epsilon", 7, 0x00395, 0}, {"simlE", 5, 0x02A9F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3C0[] = { {"GT", 2, 0x0003E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3C4[] = { {"nap", 3, 0x02249, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3C9[] = { {"Lfr", 3, 0x1D50F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3CD[] = { {"succapprox", 10, 0x02AB8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3D0[] = { {"bsim", 4, 0x0223D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3D3[] = { {"Gg", 2, 0x022D9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3D9[] = { {"angrtvb", 7, 0x022BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3DE[] = { {"xcirc", 5, 0x025EF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3E0[] = { {"Gt", 2, 0x0226B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3E1[] = { {"LeftRightVector", 15, 0x0294E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3E3[] = { {"circledast", 10, 0x0229B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3E4[] = { {"telrec", 6, 0x02315, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3E6[] = { {"SucceedsTilde", 13, 0x0227F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3E9[] = { {"nLtv", 4, 0x0226A, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3ED[] = { {"Copf", 4, 0x02102, 0}, {"napprox", 7, 0x02249, 0}, {"nsupseteq", 9, 0x02289, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3F1[] = { {"VerticalTilde", 13, 0x02240, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3F2[] = { {"parallel", 8, 0x02225, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3F7[] = { {"precnapprox", 11, 0x02AB9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3FC[] = { {"oscr", 4, 0x02134, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_3FE[] = { {"supsetneqq", 10, 0x02ACC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_402[] = { {"xopf", 4, 0x1D569, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_405[] = { {"mumap", 5, 0x022B8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_407[] = { {"varsupsetneqq", 13, 0x02ACC, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_409[] = { {"ReverseEquilibrium", 18, 0x021CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_40E[] = { {"Ubreve", 6, 0x0016C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_40F[] = { {"YUcy", 4, 0x0042E, 0}, {"ncy", 3, 0x0043D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_413[] = { {"ltimes", 6, 0x022C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_41A[] = { {"UpperRightArrow", 15, 0x02197, 0}, {"nvap", 4, 0x0224D, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_41B[] = { {"Im", 2, 0x02111, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_421[] = { {"simne", 5, 0x02246, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_423[] = { {"ccups", 5, 0x02A4C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_424[] = { {"nlArr", 5, 0x021CD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_425[] = { {"rarrsim", 7, 0x02974, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_426[] = { {"Ncaron", 6, 0x00147, 0}, {"vsupnE", 6, 0x02ACC, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_429[] = { {"succeq", 6, 0x02AB0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_42C[] = { {"Gammad", 6, 0x003DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_42F[] = { {"Icirc", 5, 0x000CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_430[] = { {"backepsilon", 11, 0x003F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_432[] = { {"ddarr", 5, 0x021CA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_436[] = { {"larr", 4, 0x02190, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_439[] = { {"divideontimes", 13, 0x022C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_43C[] = { {"succsim", 7, 0x0227F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_43D[] = { {"Pscr", 4, 0x1D4AB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_43E[] = { {"puncsp", 6, 0x02008, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_43F[] = { {"gtreqless", 9, 0x022DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_440[] = { {"intcal", 6, 0x022BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_441[] = { {"nsime", 5, 0x02244, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_443[] = { {"Yopf", 4, 0x1D550, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_446[] = { {"angsph", 6, 0x02222, 0}, {"vsupne", 6, 0x0228B, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_447[] = { {"NotNestedLessLess", 17, 0x02AA1, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_44A[] = { {"PrecedesSlantEqual", 18, 0x0227C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_44F[] = { {"icirc", 5, 0x000EE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_450[] = { {"DownLeftVectorBar", 17, 0x02956, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_454[] = { {"Auml", 4, 0x000C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_457[] = { {"LJcy", 4, 0x00409, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_458[] = { {"sqsube", 6, 0x02291, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_45D[] = { {"nprec", 5, 0x02280, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_45F[] = { {"ngE", 3, 0x02267, 0x00338}, {"smile", 5, 0x02323, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_465[] = { {"LT", 2, 0x0003C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_466[] = { {"ldrdhar", 7, 0x02967, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_469[] = { {"utri", 4, 0x025B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_46A[] = { {"Sacute", 6, 0x0015A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_46B[] = { {"late", 4, 0x02AAD, 0}, {"nfr", 3, 0x1D52B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_46D[] = { {"NotNestedGreaterGreater", 23, 0x02AA2, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_46F[] = { {"nwarr", 5, 0x02196, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_470[] = { {"biguplus", 8, 0x02A04, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_471[] = { {"Pcy", 3, 0x0041F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_472[] = { {"bigtriangleup", 13, 0x025B3, 0}, {"rationals", 9, 0x0211A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_473[] = { {"congdot", 7, 0x02A6D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_475[] = { {"PlusMinus", 9, 0x000B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_479[] = { {"IOcy", 4, 0x00401, 0}, {"Scedil", 6, 0x0015E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_47C[] = { {"eqcirc", 6, 0x02256, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_47D[] = { {"Ll", 2, 0x022D8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_47F[] = { {"Cayleys", 7, 0x0212D, 0}, {"nge", 3, 0x02271, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_480[] = { {"NotGreater", 10, 0x0226F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_485[] = { {"Lt", 2, 0x0226A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_488[] = { {"rotimes", 7, 0x02A35, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_48C[] = { {"caps", 4, 0x02229, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_48E[] = { {"ngt", 3, 0x0226F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_48F[] = { {"Cross", 5, 0x02A2F, 0}, {"bumpeq", 6, 0x0224F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_490[] = { {"VerticalSeparator", 17, 0x02758, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_491[] = { {"plankv", 6, 0x0210F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_493[] = { {"fscr", 4, 0x1D4BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_495[] = { {"bsol", 4, 0x0005C, 0}, {"sqsubseteq", 10, 0x02291, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_496[] = { {"boxH", 4, 0x02550, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_498[] = { {"rightarrowtail", 14, 0x021A3, 0}, {"ufisht", 6, 0x0297E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_499[] = { {"oopf", 4, 0x1D560, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_49F[] = { {"lobrk", 5, 0x027E6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4A2[] = { {"Acy", 3, 0x00410, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4A4[] = { {"NotSubsetEqual", 14, 0x02288, 0}, {"boxV", 4, 0x02551, 0}, {"dHar", 4, 0x02965, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4A6[] = { {"precnsim", 8, 0x022E8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4A7[] = { {"Mu", 2, 0x0039C, 0}, {"aelig", 5, 0x000E6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4AA[] = { {"gescc", 5, 0x02AA9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4AB[] = { {"origof", 6, 0x022B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4AE[] = { {"upsih", 5, 0x003D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4AF[] = { {"cross", 5, 0x02717, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4B2[] = { {"LeftFloor", 9, 0x0230A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4B6[] = { {"boxh", 4, 0x02500, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4B8[] = { {"NotGreaterEqual", 15, 0x02271, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4BC[] = { {"profalar", 8, 0x0232E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4C0[] = { {"nsmid", 5, 0x02224, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4C2[] = { {"hbar", 4, 0x0210F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4C3[] = { {"udarr", 5, 0x021C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4C4[] = { {"boxv", 4, 0x02502, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4C5[] = { {"olarr", 5, 0x021BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4C8[] = { {"Nu", 2, 0x0039D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4CB[] = { {"NotCongruent", 12, 0x02262, 0}, {"bkarow", 6, 0x0290D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4CD[] = { {"Pfr", 3, 0x1D513, 0}, {"forkv", 5, 0x02AD9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4CF[] = { {"nis", 3, 0x022FC, 0}, {"trianglerighteq", 15, 0x022B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4D0[] = { {"ngeq", 4, 0x02271, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4D2[] = { {"cudarrl", 7, 0x02938, 0}, {"nges", 4, 0x02A7E, 0x00338}, {"niv", 3, 0x0220B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4D3[] = { {"SubsetEqual", 11, 0x02286, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4D4[] = { {"Gscr", 4, 0x1D4A2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4D5[] = { {"complexes", 9, 0x02102, 0}, {"eDDot", 5, 0x02A77, 0}, {"nvge", 4, 0x02265, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4D8[] = { {"cudarrr", 7, 0x02935, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4DA[] = { {"Popf", 4, 0x02119, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4DE[] = { {"LongRightArrow", 14, 0x027F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4DF[] = { {"supseteq", 8, 0x02287, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4E3[] = { {"dollar", 6, 0x00024, 0}, {"gnsim", 5, 0x022E7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4E4[] = { {"nvgt", 4, 0x0003E, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4E6[] = { {"Or", 2, 0x02A54, 0}, {"Vert", 4, 0x02016, 0}, {"lneqq", 5, 0x02268, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4E7[] = { {"nLeftrightarrow", 15, 0x021CE, 0}, {"nbump", 5, 0x0224E, 0x00338}, {"ntriangleright", 14, 0x022EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4E8[] = { {"ecir", 4, 0x02256, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4E9[] = { {"npolint", 7, 0x02A14, 0}, {"plus", 4, 0x0002B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4ED[] = { {"centerdot", 9, 0x000B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4F1[] = { {"zacute", 6, 0x0017A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4F7[] = { {"odiv", 4, 0x02A38, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4F9[] = { {"cap", 3, 0x02229, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4FB[] = { {"ensp", 4, 0x02002, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_4FE[] = { {"Afr", 3, 0x1D504, 0}, {"Pi", 2, 0x003A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_500[] = { {"iquest", 6, 0x000BF, 0}, {"ltri", 4, 0x025C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_504[] = { {"nlE", 3, 0x02266, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_506[] = { {"Phi", 3, 0x003A6, 0}, {"lambda", 6, 0x003BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_507[] = { {"Pr", 2, 0x02ABB, 0}, {"Vdashl", 6, 0x02AE6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_509[] = { {"SuchThat", 8, 0x0220B, 0}, {"Supset", 6, 0x022D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_50E[] = { {"Darr", 4, 0x021A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_50F[] = { {"Cdot", 4, 0x0010A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_513[] = { {"rcy", 3, 0x00440, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_516[] = { {"orderof", 7, 0x02134, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_518[] = { {"leqq", 4, 0x02266, 0}, {"precsim", 7, 0x0227E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_519[] = { {"RightTriangle", 13, 0x022B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_51B[] = { {"agrave", 6, 0x000E0, 0}, {"succnapprox", 11, 0x02ABA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_51C[] = { {"Tab", 3, 0x00009, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_524[] = { {"nle", 3, 0x02270, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_525[] = { {"spades", 6, 0x02660, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_526[] = { {"gtcc", 4, 0x02AA7, 0}, {"llcorner", 8, 0x0231E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_52F[] = { {"Oslash", 6, 0x000D8, 0}, {"Tau", 3, 0x003A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_530[] = { {"fopf", 4, 0x1D557, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_532[] = { {"Mellintrf", 9, 0x02133, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_533[] = { {"nlt", 3, 0x0226E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_534[] = { {"lparlt", 6, 0x02993, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_53B[] = { {"Ccaron", 6, 0x0010C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_53C[] = { {"Re", 2, 0x0211C, 0}, {"dstrok", 6, 0x00111, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_53F[] = { {"leftharpoondown", 15, 0x021BD, 0}, {"ssetmn", 6, 0x02216, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_542[] = { {"lrhard", 6, 0x0296D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_543[] = { {"reg", 3, 0x000AE, 0}, {"sharp", 5, 0x0266F, 0}, {"yicy", 4, 0x00457, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_545[] = { {"ShortUpArrow", 12, 0x02191, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_548[] = { {"plusacir", 8, 0x02A23, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_54F[] = { {"cent", 4, 0x000A2, 0}, {"natur", 5, 0x0266E, 0}, {"varphi", 6, 0x003D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_550[] = { {"lesg", 4, 0x022DA, 0x0FE00}, {"supnE", 5, 0x02ACC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_551[] = { {"ohbar", 5, 0x029B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_557[] = { {"NotLessGreater", 14, 0x02278, 0}, {"nleqslant", 9, 0x02A7D, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_55B[] = { {"Sc", 2, 0x02ABC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_55D[] = { {"NotSucceedsEqual", 16, 0x02AB0, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_55F[] = { {"DZcy", 4, 0x0040F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_564[] = { {"vartheta", 8, 0x003D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_565[] = { {"ltrie", 5, 0x022B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_566[] = { {"Otilde", 6, 0x000D5, 0}, {"ltrif", 5, 0x025C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_56C[] = { {"Lsh", 3, 0x021B0, 0}, {"hookleftarrow", 13, 0x021A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_56F[] = { {"rfr", 3, 0x1D52F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_570[] = { {"supne", 5, 0x0228B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_571[] = { {"Gopf", 4, 0x1D53E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_572[] = { {"UpEquilibrium", 13, 0x0296E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_575[] = { {"Tcy", 3, 0x00422, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_576[] = { {"ffilig", 6, 0x0FB03, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_577[] = { {"fork", 4, 0x022D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_578[] = { {"oplus", 5, 0x02295, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_57A[] = { {"nvle", 4, 0x02264, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_57B[] = { {"HilbertSpace", 12, 0x0210B, 0}, {"subedot", 7, 0x02AC3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_57C[] = { {"TripleDot", 9, 0x020DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_580[] = { {"sscr", 4, 0x1D4C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_582[] = { {"osol", 4, 0x02298, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_583[] = { {"plustwo", 7, 0x02A27, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_586[] = { {"LessGreater", 11, 0x02276, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_588[] = { {"lrarr", 5, 0x021C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_589[] = { {"nvlt", 4, 0x0003C, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_58D[] = { {"questeq", 7, 0x0225F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_58E[] = { {"LessTilde", 9, 0x02272, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_58F[] = { {"djcy", 4, 0x00452, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_590[] = { {"xoplus", 6, 0x02A01, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_595[] = { {"primes", 6, 0x02119, 0}, {"solb", 4, 0x029C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_596[] = { {"not", 3, 0x000AC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_59A[] = { {"angzarr", 7, 0x0237C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_59D[] = { {"nearr", 5, 0x02197, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_59F[] = { {"lowast", 6, 0x02217, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5A0[] = { {"cfr", 3, 0x1D520, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5A3[] = { {"ltcir", 5, 0x02A79, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5A6[] = { {"Ecy", 3, 0x0042D, 0}, {"gesdotol", 8, 0x02A84, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5A9[] = { {"longleftrightarrow", 18, 0x027F7, 0}, {"para", 4, 0x000B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5AC[] = { {"Uacute", 6, 0x000DA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5AD[] = { {"blank", 5, 0x02423, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5AE[] = { {"rho", 3, 0x003C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5B0[] = { {"dharl", 5, 0x021C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5B1[] = { {"rsquor", 6, 0x02019, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5B5[] = { {"NotSquareSubsetEqual", 20, 0x022E2, 0}, {"npr", 3, 0x02280, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5B6[] = { {"dharr", 5, 0x021C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5B7[] = { {"NewLine", 7, 0x0000A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5BB[] = { {"odot", 4, 0x02299, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5BC[] = { {"part", 4, 0x02202, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5BD[] = { {"cuvee", 5, 0x022CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5BF[] = { {"lesdoto", 7, 0x02A81, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5C0[] = { {"itilde", 6, 0x00129, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5C1[] = { {"Tscr", 4, 0x1D4AF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5C2[] = { {"nsubE", 5, 0x02AC5, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5C4[] = { {"ratio", 5, 0x02236, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5D0[] = { {"Conint", 6, 0x0222F, 0}, {"LeftDownVectorBar", 17, 0x02959, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5D1[] = { {"Tfr", 3, 0x1D517, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5D3[] = { {"fllig", 5, 0x0FB02, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5D5[] = { {"thksim", 6, 0x0223C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5D8[] = { {"Euml", 4, 0x000CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5D9[] = { {"chi", 3, 0x003C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5DB[] = { {"ncup", 4, 0x02A42, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5DD[] = { {"SOFTcy", 6, 0x0042C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5DF[] = { {"bnequiv", 7, 0x02261, 0x020E5}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5E2[] = { {"nsube", 5, 0x02288, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5E4[] = { {"mapstoleft", 10, 0x021A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5E7[] = { {"NotLessSlantEqual", 17, 0x02A7D, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5EA[] = { {"ldrushar", 8, 0x0294B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5ED[] = { {"Equilibrium", 11, 0x021CC, 0}, {"Uogon", 5, 0x00172, 0}, {"supsetneq", 9, 0x0228B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5F0[] = { {"Vbar", 4, 0x02AEB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5F3[] = { {"vnsub", 5, 0x02282, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5F6[] = { {"Square", 6, 0x025A1, 0}, {"lessapprox", 10, 0x02A85, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5F8[] = { {"And", 3, 0x02A53, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5FA[] = { {"gesdoto", 7, 0x02A82, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_5FD[] = { {"gap", 3, 0x02A86, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_601[] = { {"nsucc", 5, 0x02281, 0}, {"thicksim", 8, 0x0223C, 0}, {"vnsup", 5, 0x02283, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_602[] = { {"Efr", 3, 0x1D508, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_603[] = { {"Igrave", 6, 0x000CC, 0}, {"cir", 3, 0x025CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_606[] = { {"Xi", 2, 0x0039E, 0}, {"oacute", 6, 0x000F3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_609[] = { {"nsc", 3, 0x02281, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_60D[] = { {"uogon", 5, 0x00173, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_613[] = { {"rharul", 6, 0x0296C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_615[] = { {"RuleDelayed", 11, 0x029F4, 0}, {"apacir", 6, 0x02A6F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_617[] = { {"jscr", 4, 0x1D4BF, 0}, {"vcy", 3, 0x00432, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_61A[] = { {"barwed", 6, 0x02305, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_61D[] = { {"sopf", 4, 0x1D564, 0}, {"thkap", 5, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_61F[] = { {"lesseqgtr", 9, 0x022DA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_622[] = { {"rdquor", 6, 0x0201D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_624[] = { {"Lstrok", 6, 0x00141, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_626[] = { {"Product", 7, 0x0220F, 0}, {"sqsupe", 6, 0x02292, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_628[] = { {"awconint", 8, 0x02233, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_62C[] = { {"hearts", 6, 0x02665, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_630[] = { {"rlm", 3, 0x0200F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_632[] = { {"comma", 5, 0x0002C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_636[] = { {"PartialD", 8, 0x02202, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_63A[] = { {"wedbar", 6, 0x02A5F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_63C[] = { {"oline", 5, 0x0203E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_63D[] = { {"OverBracket", 11, 0x023B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_63E[] = { {"RBarr", 5, 0x02910, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_641[] = { {"uharl", 5, 0x021BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_642[] = { {"leftrightsquigarrow", 19, 0x021AD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_645[] = { {"RightFloor", 10, 0x0230B, 0}, {"intprod", 7, 0x02A3C, 0}, {"vee", 3, 0x02228, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_646[] = { {"zigrarr", 7, 0x021DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_647[] = { {"uharr", 5, 0x021BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_648[] = { {"gcy", 3, 0x00433, 0}, {"varsubsetneq", 12, 0x0228A, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_649[] = { {"leqslant", 8, 0x02A7D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_64A[] = { {"Odblac", 6, 0x00150, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_651[] = { {"minus", 5, 0x02212, 0}, {"scpolint", 8, 0x02A13, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_652[] = { {"lrtri", 5, 0x022BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_653[] = { {"DiacriticalGrave", 16, 0x00060, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_655[] = { {"num", 3, 0x00023, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_657[] = { {"quest", 5, 0x0003F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_658[] = { {"Kscr", 4, 0x1D4A6, 0}, {"UnderBar", 8, 0x0005F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_659[] = { {"lsquo", 5, 0x02018, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_65C[] = { {"rArr", 4, 0x021D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_65E[] = { {"Topf", 4, 0x1D54B, 0}, {"heartsuit", 9, 0x02665, 0}, {"rBarr", 5, 0x0290F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_660[] = { {"emptyset", 8, 0x02205, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_669[] = { {"UnderParenthesis", 16, 0x023DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_670[] = { {"dotplus", 7, 0x02214, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_671[] = { {"Psi", 3, 0x003A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_672[] = { {"GJcy", 4, 0x00403, 0}, {"exist", 5, 0x02203, 0}, {"simplus", 7, 0x02A24, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_673[] = { {"vfr", 3, 0x1D533, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_676[] = { {"tprime", 6, 0x02034, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_678[] = { {"leftrightharpoons", 17, 0x021CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_679[] = { {"rbrksld", 7, 0x0298E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_67D[] = { {"Ecaron", 6, 0x0011A, 0}, {"gel", 3, 0x022DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_680[] = { {"capdot", 6, 0x02A40, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_682[] = { {"geq", 3, 0x02265, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_684[] = { {"LowerLeftArrow", 14, 0x02199, 0}, {"ges", 3, 0x02A7E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_685[] = { {"Colone", 6, 0x02A74, 0}, {"NotLessEqual", 12, 0x02270, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_68A[] = { {"nrarr", 5, 0x0219B, 0}, {"rbrkslu", 7, 0x02990, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_68C[] = { {"flat", 4, 0x0266D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_691[] = { {"there4", 6, 0x02234, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_693[] = { {"Gdot", 4, 0x00120, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_694[] = { {"ijlig", 5, 0x00133, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_696[] = { {"blacklozenge", 12, 0x029EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_699[] = { {"Zeta", 4, 0x00396, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6A3[] = { {"duarr", 5, 0x021F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6A4[] = { {"DotEqual", 8, 0x02250, 0}, {"dtdot", 5, 0x022F1, 0}, {"gfr", 3, 0x1D524, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6A8[] = { {"cirE", 4, 0x029C3, 0}, {"period", 6, 0x0002E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6A9[] = { {"lmoust", 6, 0x023B0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6AA[] = { {"Icy", 3, 0x00418, 0}, {"Rcaron", 6, 0x00158, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6AB[] = { {"LeftCeiling", 11, 0x02308, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6AE[] = { {"ascr", 4, 0x1D4B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6B0[] = { {"boxtimes", 8, 0x022A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6B4[] = { {"jopf", 4, 0x1D55B, 0}, {"ntriangleleft", 13, 0x022EA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6B6[] = { {"eqcolon", 7, 0x02255, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6B8[] = { {"rbbrk", 5, 0x02773, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6B9[] = { {"homtht", 6, 0x0223B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6BA[] = { {"ggg", 3, 0x022D9, 0}, {"seswar", 6, 0x02929, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6BC[] = { {"perp", 4, 0x022A5, 0}, {"shcy", 4, 0x00448, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6BF[] = { {"phone", 5, 0x0260E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C0[] = { {"NotDoubleVerticalBar", 20, 0x02226, 0}, {"ngtr", 4, 0x0226F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C4[] = { {"ThickSpace", 10, 0x0205F, 0x0200A}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C5[] = { {"ForAll", 6, 0x02200, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C6[] = { {"circ", 4, 0x002C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C7[] = { {"Verbar", 6, 0x02016, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C8[] = { {"cire", 4, 0x02257, 0}, {"lesges", 6, 0x02A93, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6C9[] = { {"slarr", 5, 0x02190, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6CC[] = { {"RightDownTeeVector", 18, 0x0295D, 0}, {"triangleq", 9, 0x0225C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6CE[] = { {"checkmark", 9, 0x02713, 0}, {"quot", 4, 0x00022, 0}, {"suplarr", 7, 0x0297B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6D1[] = { {"Backslash", 9, 0x02216, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6D2[] = { {"fallingdotseq", 13, 0x02252, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6D4[] = { {"swArr", 5, 0x021D9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6D5[] = { {"Xfr", 3, 0x1D51B, 0}, {"lbrke", 5, 0x0298B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6D9[] = { {"jmath", 5, 0x00237, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6DA[] = { {"lmoustache", 10, 0x023B0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6DB[] = { {"DownTee", 7, 0x022A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6DC[] = { {"reals", 5, 0x0211D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6DE[] = { {"quaternions", 11, 0x0210D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6E7[] = { {"vzigzag", 7, 0x0299A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6EB[] = { {"pound", 5, 0x000A3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6EE[] = { {"permil", 6, 0x02030, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6EF[] = { {"Bscr", 4, 0x0212C, 0}, {"lfisht", 6, 0x0297C, 0}, {"vartriangleleft", 15, 0x022B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6F5[] = { {"Kopf", 4, 0x1D542, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6F7[] = { {"Tilde", 5, 0x0223C, 0}, {"gtrarr", 6, 0x02978, 0}, {"lAarr", 5, 0x021DA, 0}, {"opar", 4, 0x029B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_6FB[] = { {"triangle", 8, 0x025B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_704[] = { {"lcaron", 6, 0x0013E, 0}, {"wscr", 4, 0x1D4CC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_705[] = { {"asympeq", 7, 0x0224D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_706[] = { {"Ifr", 3, 0x02111, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_707[] = { {"DoubleDot", 9, 0x000A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_709[] = { {"nVdash", 6, 0x022AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_70C[] = { {"hairsp", 6, 0x0200A, 0}, {"leftrightarrows", 15, 0x021C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_70E[] = { {"lbrace", 6, 0x0007B, 0}, {"rightarrow", 10, 0x02192, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_70F[] = { {"Dagger", 6, 0x02021, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_712[] = { {"rsh", 3, 0x021B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_714[] = { {"eqslantless", 11, 0x02A95, 0}, {"gnapprox", 8, 0x02A8A, 0}, {"lbrack", 6, 0x0005B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_715[] = { {"uHar", 4, 0x02963, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_717[] = { {"tilde", 5, 0x002DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_719[] = { {"complement", 10, 0x02201, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_71B[] = { {"zcy", 3, 0x00437, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_71E[] = { {"boxDL", 5, 0x02557, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_71F[] = { {"micro", 5, 0x000B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_723[] = { {"horbar", 6, 0x02015, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_724[] = { {"boxDR", 5, 0x02554, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_727[] = { {"bsolhsub", 8, 0x027C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_729[] = { {"ac", 2, 0x0223E, 0}, {"nvdash", 6, 0x022AC, 0}, {"precapprox", 10, 0x02AB7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_72C[] = { {"af", 2, 0x02061, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_72D[] = { {"bullet", 6, 0x02022, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_72E[] = { {"demptyv", 7, 0x029B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_733[] = { {"geqq", 4, 0x02267, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_734[] = { {"uuarr", 5, 0x021C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_735[] = { {"Ocirc", 5, 0x000D4, 0}, {"utdot", 5, 0x022F0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_736[] = { {"ap", 2, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_738[] = { {"bNot", 4, 0x02AED, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_73B[] = { {"CirclePlus", 10, 0x02295, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_73D[] = { {"glE", 3, 0x02A92, 0}, {"midcir", 6, 0x02AF0, 0}, {"rppolint", 8, 0x02A12, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_73E[] = { {"boxDl", 5, 0x02556, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_73F[] = { {"sdot", 4, 0x022C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_744[] = { {"boxDr", 5, 0x02553, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_745[] = { {"Xscr", 4, 0x1D4B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_749[] = { {"dlcrop", 6, 0x0230D, 0}, {"gtrless", 7, 0x02277, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_74B[] = { {"aopf", 4, 0x1D552, 0}, {"operp", 5, 0x029B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_74C[] = { {"kcy", 3, 0x0043A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_74F[] = { {"larrfs", 6, 0x0291D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_751[] = { {"rcub", 4, 0x0007D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_754[] = { {"nrtri", 5, 0x022EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_755[] = { {"nparsl", 6, 0x02AFD, 0x020E5}, {"ocirc", 5, 0x000F4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_759[] = { {"gla", 3, 0x02AA5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_75C[] = { {"Iuml", 4, 0x000CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_75F[] = { {"mcomma", 6, 0x02A29, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_762[] = { {"glj", 3, 0x02AA4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_763[] = { {"Map", 3, 0x02905, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_765[] = { {"copysr", 6, 0x02117, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_766[] = { {"DownTeeArrow", 12, 0x021A7, 0}, {"Upsi", 4, 0x003D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_768[] = { {"awint", 5, 0x02A11, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_76E[] = { {"DownRightVector", 15, 0x021C1, 0}, {"NotEqual", 8, 0x02260, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_770[] = { {"gesl", 4, 0x022DB, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_772[] = { {"NotCupCap", 9, 0x0226D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_776[] = { {"blacktriangleright", 18, 0x025B8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_777[] = { {"zfr", 3, 0x1D537, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_779[] = { {"leftrightarrow", 14, 0x02194, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_77A[] = { {"Abreve", 6, 0x00102, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_77F[] = { {"Uarr", 4, 0x0219F, 0}, {"gnE", 3, 0x02269, 0}, {"supmult", 7, 0x02AC2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_781[] = { {"supplus", 7, 0x02AC0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_783[] = { {"nabla", 5, 0x02207, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_787[] = { {"Lang", 4, 0x027EA, 0}, {"laquo", 5, 0x000AB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_789[] = { {"larrhk", 6, 0x021A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_78C[] = { {"Bopf", 4, 0x1D539, 0}, {"lowbar", 6, 0x0005F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_78D[] = { {"cup", 3, 0x0222A, 0}, {"dd", 2, 0x02146, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_78E[] = { {"nsce", 4, 0x02AB0, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_790[] = { {"nshortparallel", 14, 0x02226, 0}, {"nsupE", 5, 0x02AC6, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_794[] = { {"OpenCurlyQuote", 14, 0x02018, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_797[] = { {"bsolb", 5, 0x029C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_798[] = { {"DScy", 4, 0x00405, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_79A[] = { {"boxHD", 5, 0x02566, 0}, {"ltrPar", 6, 0x02996, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_79B[] = { {"nscr", 4, 0x1D4C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_79D[] = { {"lEg", 3, 0x02A8B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_79F[] = { {"egrave", 6, 0x000E8, 0}, {"gne", 3, 0x02A88, 0}, {"larrsim", 7, 0x02973, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7A0[] = { {"COPY", 4, 0x000A9, 0}, {"bdquo", 5, 0x0201E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7A1[] = { {"wopf", 4, 0x1D568, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7A2[] = { {"NotRightTriangleEqual", 21, 0x022ED, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7A5[] = { {"robrk", 5, 0x027E7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7A8[] = { {"kfr", 3, 0x1D528, 0}, {"nlsim", 5, 0x02274, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7AA[] = { {"xhArr", 5, 0x027FA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7AB[] = { {"boxHU", 5, 0x02569, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7AC[] = { {"lHar", 4, 0x02962, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7AE[] = { {"Mcy", 3, 0x0041C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7AF[] = { {"ee", 2, 0x02147, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7B0[] = { {"nsupe", 5, 0x02289, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7B1[] = { {"eg", 2, 0x02A9A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7B5[] = { {"trade", 5, 0x02122, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7B6[] = { {"el", 2, 0x02A99, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7B7[] = { {"nsucceq", 7, 0x02AB0, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7B8[] = { {"langle", 6, 0x027E8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7BA[] = { {"boxHd", 5, 0x02564, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7BB[] = { {"Subset", 6, 0x022D0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7BD[] = { {"DownArrowBar", 12, 0x02913, 0}, {"topbot", 6, 0x02336, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7BE[] = { {"OverBrace", 9, 0x023DE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7BF[] = { {"Eta", 3, 0x00397, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7C0[] = { {"hstrok", 6, 0x00127, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7C1[] = { {"Hacek", 5, 0x002C7, 0}, {"diamond", 7, 0x022C4, 0}, {"isinsv", 6, 0x022F3, 0}, {"rtriltri", 8, 0x029CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7C9[] = { {"nvltrie", 7, 0x022B4, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7CB[] = { {"boxHu", 5, 0x02567, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7CD[] = { {"fpartint", 8, 0x02A0D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7CE[] = { {"Proportional", 12, 0x0221D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7D1[] = { {"NotSuperset", 11, 0x02283, 0x020D2}, {"gE", 2, 0x02267, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7D2[] = { {"scnsim", 6, 0x022E9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7D5[] = { {"uparrow", 7, 0x02191, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7D6[] = { {"ltlarr", 6, 0x02976, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7D9[] = { {"rtimes", 6, 0x022CA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7DA[] = { {"ncong", 5, 0x02247, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7DC[] = { {"Oscr", 4, 0x1D4AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7E0[] = { {"vArr", 4, 0x021D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7E2[] = { {"Xopf", 4, 0x1D54F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7E4[] = { {"notinva", 7, 0x02209, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7E5[] = { {"notinvb", 7, 0x022F7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7E6[] = { {"notinvc", 7, 0x022F6, 0}, {"nsqsube", 7, 0x022E2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7EC[] = { {"Tcaron", 6, 0x00164, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7EF[] = { {"upsilon", 7, 0x003C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7F1[] = { {"ge", 2, 0x02265, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7F3[] = { {"gg", 2, 0x0226B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7F6[] = { {"KJcy", 4, 0x0040C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7F8[] = { {"gl", 2, 0x02277, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7FB[] = { {"dblac", 5, 0x002DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_7FC[] = { {"lAtail", 6, 0x0291B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_800[] = { {"gt", 2, 0x0003E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_802[] = { {"lotimes", 7, 0x02A34, 0}, {"seArr", 5, 0x021D8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_803[] = { {"Lacute", 6, 0x00139, 0}, {"Laplacetrf", 10, 0x02112, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_808[] = { {"uuml", 4, 0x000FC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_809[] = { {"Amacr", 5, 0x00100, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_80A[] = { {"Mfr", 3, 0x1D510, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_810[] = { {"Int", 3, 0x0222C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_811[] = { {"Vvdash", 6, 0x022AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_812[] = { {"Lcedil", 6, 0x0013B, 0}, {"larrlp", 6, 0x021AB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_816[] = { {"Larr", 4, 0x0219E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_819[] = { {"CircleTimes", 11, 0x02297, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_81C[] = { {"NotReverseElement", 17, 0x0220C, 0}, {"latail", 6, 0x02919, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_81D[] = { {"ntrianglerighteq", 16, 0x022ED, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_821[] = { {"blk12", 5, 0x02592, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_822[] = { {"intlarhk", 8, 0x02A17, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_823[] = { {"blk14", 5, 0x02591, 0}, {"ccupssm", 7, 0x02A50, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_824[] = { {"hercon", 6, 0x022B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_828[] = { {"bigotimes", 9, 0x02A02, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_829[] = { {"amacr", 5, 0x00101, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_82D[] = { {"nrarrc", 6, 0x02933, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_82E[] = { {"ubreve", 6, 0x0016D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_830[] = { {"Yacute", 6, 0x000DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_831[] = { {"ic", 2, 0x02063, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_832[] = { {"escr", 4, 0x0212F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_837[] = { {"ii", 2, 0x02148, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_838[] = { {"DownArrowUpArrow", 16, 0x021F5, 0}, {"nopf", 4, 0x1D55F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_83C[] = { {"in", 2, 0x02208, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_83E[] = { {"bumpE", 5, 0x02AAE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_83F[] = { {"rightharpoonup", 14, 0x021C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_841[] = { {"nrarrw", 6, 0x0219D, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_842[] = { {"it", 2, 0x02062, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_846[] = { {"ncaron", 6, 0x00148, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_84A[] = { {"succnsim", 8, 0x022E9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_84C[] = { {"gammad", 6, 0x003DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_84F[] = { {"yucy", 4, 0x0044E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_850[] = { {"ocy", 3, 0x0043E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_855[] = { {"hybull", 6, 0x02043, 0}, {"rpargt", 6, 0x02994, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_857[] = { {"csube", 5, 0x02AD1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_85B[] = { {"iiota", 5, 0x02129, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_85C[] = { {"nsim", 4, 0x02241, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_85E[] = { {"LeftTriangleEqual", 17, 0x022B4, 0}, {"bumpe", 5, 0x0224F, 0}, {"nearhk", 6, 0x02924, 0}, {"nhpar", 5, 0x02AF2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_861[] = { {"risingdotseq", 12, 0x02253, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_865[] = { {"blk34", 5, 0x02593, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_866[] = { {"LeftTriangle", 12, 0x022B2, 0}, {"vBarv", 5, 0x02AE9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_867[] = { {"AElig", 5, 0x000C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_868[] = { {"DoubleUpDownArrow", 17, 0x021D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_86A[] = { {"cwint", 5, 0x02231, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_86B[] = { {"rtrie", 5, 0x022B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_86C[] = { {"rtrif", 5, 0x025B8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_873[] = { {"Fscr", 4, 0x02131, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_876[] = { {"lE", 2, 0x02266, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_879[] = { {"Oopf", 4, 0x1D546, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_87B[] = { {"spar", 4, 0x02225, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_87E[] = { {"uplus", 5, 0x0228E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_88A[] = { {"sacute", 6, 0x0015B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_88C[] = { {"fltns", 5, 0x025B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_88E[] = { {"rrarr", 5, 0x021C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_892[] = { {"larrpl", 6, 0x02939, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_895[] = { {"ultri", 5, 0x025F8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_896[] = { {"le", 2, 0x02264, 0}, {"xuplus", 6, 0x02A04, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_897[] = { {"ljcy", 4, 0x00459, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_898[] = { {"lg", 2, 0x02276, 0}, {"vsubnE", 6, 0x02ACB, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_899[] = { {"scedil", 6, 0x0015F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_89D[] = { {"ll", 2, 0x0226A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8A5[] = { {"lt", 2, 0x0003C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8AC[] = { {"ofr", 3, 0x1D52C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8B3[] = { {"nexists", 7, 0x02204, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8B6[] = { {"smallsetminus", 13, 0x02216, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8B7[] = { {"InvisibleComma", 14, 0x02063, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8B8[] = { {"dotminus", 8, 0x02238, 0}, {"vsubne", 6, 0x0228A, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8B9[] = { {"iocy", 4, 0x00451, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8BA[] = { {"gsime", 5, 0x02A8E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8BC[] = { {"Rarrtl", 6, 0x02916, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8BD[] = { {"cirmid", 6, 0x02AEF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8C0[] = { {"ominus", 6, 0x02296, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8C1[] = { {"gsiml", 5, 0x02A90, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8C2[] = { {"Prime", 5, 0x02033, 0}, {"mp", 2, 0x02213, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8C4[] = { {"tint", 4, 0x0222D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8C7[] = { {"mu", 2, 0x003BC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8CF[] = { {"dbkarow", 7, 0x0290F, 0}, {"eopf", 4, 0x1D556, 0}, {"ogt", 3, 0x029C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8D0[] = { {"Precedes", 8, 0x0227A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8D3[] = { {"UpTeeArrow", 10, 0x021A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8D6[] = { {"varsupsetneq", 12, 0x0228B, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8D8[] = { {"ne", 2, 0x02260, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8DC[] = { {"ni", 2, 0x0220B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8DD[] = { {"mDDot", 5, 0x0223A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8DE[] = { {"cularrp", 7, 0x0293D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8DF[] = { {"rnmid", 5, 0x02AEE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8E0[] = { {"hardcy", 6, 0x0044A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8E2[] = { {"prime", 5, 0x02032, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8E3[] = { {"Bcy", 3, 0x00411, 0}, {"REG", 3, 0x000AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8E7[] = { {"oS", 2, 0x024C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8E8[] = { {"nu", 2, 0x003BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8E9[] = { {"ohm", 3, 0x003A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8EB[] = { {"langd", 5, 0x02991, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8F3[] = { {"backprime", 9, 0x02035, 0}, {"esim", 4, 0x02242, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8FB[] = { {"veeeq", 5, 0x0225A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8FE[] = { {"RightCeiling", 12, 0x02309, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_8FF[] = { {"crarr", 5, 0x021B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_904[] = { {"eqsim", 5, 0x02242, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_906[] = { {"or", 2, 0x02228, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_907[] = { {"OverParenthesis", 15, 0x023DC, 0}, {"UpperLeftArrow", 14, 0x02196, 0}, {"nleftrightarrow", 15, 0x021AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_909[] = { {"expectation", 11, 0x02130, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_90C[] = { {"coprod", 6, 0x02210, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_90E[] = { {"Qfr", 3, 0x1D514, 0}, {"dArr", 4, 0x021D3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_910[] = { {"Fopf", 4, 0x1D53D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_913[] = { {"Cconint", 7, 0x02230, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_916[] = { {"larrtl", 6, 0x021A2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_918[] = { {"Aacute", 6, 0x000C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_919[] = { {"DownLeftRightVector", 19, 0x02950, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_91B[] = { {"circleddash", 11, 0x0229D, 0}, {"thinsp", 6, 0x02009, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_91E[] = { {"Longrightarrow", 14, 0x027F9, 0}, {"pi", 2, 0x003C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_91F[] = { {"hookrightarrow", 14, 0x021AA, 0}, {"rscr", 4, 0x1D4C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_920[] = { {"scE", 3, 0x02AB4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_922[] = { {"pm", 2, 0x000B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_923[] = { {"ZHcy", 4, 0x00416, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_927[] = { {"pr", 2, 0x0227A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_929[] = { {"LongLeftRightArrow", 18, 0x027F7, 0}, {"supset", 6, 0x02283, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_92A[] = { {"UpArrowBar", 10, 0x02912, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_92C[] = { {"Utilde", 6, 0x00168, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_92E[] = { {"xlArr", 5, 0x027F8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_930[] = { {"DoubleUpArrow", 13, 0x021D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_936[] = { {"alefsym", 7, 0x02135, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_939[] = { {"Scirc", 5, 0x0015C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_93B[] = { {"xotime", 6, 0x02A02, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_93F[] = { {"Bfr", 3, 0x1D505, 0}, {"rdca", 4, 0x02937, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_940[] = { {"sce", 3, 0x02AB0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_945[] = { {"Nacute", 6, 0x00143, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_947[] = { {"amalg", 5, 0x02A3F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_94D[] = { {"UpDownArrow", 11, 0x02195, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_94F[] = { {"EqualTilde", 10, 0x02242, 0}, {"boxUL", 5, 0x0255D, 0}, {"oslash", 6, 0x000F8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_950[] = { {"lnap", 4, 0x02A89, 0}, {"thorn", 5, 0x000FE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_952[] = { {"ssmile", 6, 0x02323, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_953[] = { {"ndash", 5, 0x02013, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_954[] = { {"Ncedil", 6, 0x00145, 0}, {"scy", 3, 0x00441, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_955[] = { {"boxUR", 5, 0x0255A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_956[] = { {"Aring", 5, 0x000C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_959[] = { {"scirc", 5, 0x0015D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_95B[] = { {"ccaron", 6, 0x0010D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_95D[] = { {"dotsquare", 9, 0x022A1, 0}, {"nshortmid", 9, 0x02224, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_95F[] = { {"rsquo", 5, 0x02019, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_960[] = { {"Sscr", 4, 0x1D4AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_963[] = { {"bigwedge", 8, 0x022C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_964[] = { {"Bernoullis", 10, 0x0212C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_969[] = { {"harrw", 5, 0x021AD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_96C[] = { {"SquareSubset", 12, 0x0228F, 0}, {"boxVH", 5, 0x0256C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_96F[] = { {"boxUl", 5, 0x0255C, 0}, {"rx", 2, 0x0211E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_970[] = { {"boxVL", 5, 0x02563, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_974[] = { {"olt", 3, 0x029C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_975[] = { {"boxUr", 5, 0x02559, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_976[] = { {"aring", 5, 0x000E5, 0}, {"boxVR", 5, 0x02560, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_97B[] = { {"sc", 2, 0x0227B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_97C[] = { {"NestedGreaterGreater", 20, 0x0226B, 0}, {"oast", 4, 0x0229B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_97F[] = { {"star", 4, 0x02606, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_981[] = { {"LeftTeeVector", 13, 0x0295A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_983[] = { {"bigsqcup", 8, 0x02A06, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_985[] = { {"dcy", 3, 0x00434, 0}, {"preceq", 6, 0x02AAF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_986[] = { {"otilde", 6, 0x000F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_988[] = { {"luruhar", 7, 0x02966, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_98C[] = { {"boxVh", 5, 0x0256B, 0}, {"capand", 6, 0x02A44, 0}, {"yuml", 4, 0x000FF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_98D[] = { {"Updownarrow", 11, 0x021D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_98F[] = { {"TildeEqual", 10, 0x02243, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_990[] = { {"boxVl", 5, 0x02562, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_996[] = { {"boxVr", 5, 0x0255F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_997[] = { {"HorizontalLine", 14, 0x02500, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_99B[] = { {"xmap", 4, 0x027FC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_99C[] = { {"sigmaf", 6, 0x003C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_99E[] = { {"EmptySmallSquare", 16, 0x025FB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_99F[] = { {"dzcy", 4, 0x0045F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9A0[] = { {"cups", 4, 0x0222A, 0x0FE00}, {"zwj", 3, 0x0200D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9A1[] = { {"beta", 4, 0x003B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9A6[] = { {"supsim", 6, 0x02AC8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9A8[] = { {"beth", 4, 0x02136, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9AA[] = { {"Iukcy", 5, 0x00406, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9AC[] = { {"eparsl", 6, 0x029E3, 0}, {"sigmav", 6, 0x003C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9B0[] = { {"lhard", 5, 0x021BD, 0}, {"sfr", 3, 0x1D530, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9B4[] = { {"nsqsupe", 7, 0x022E3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9B5[] = { {"Jsercy", 6, 0x00408, 0}, {"deg", 3, 0x000B0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9B6[] = { {"Ucy", 3, 0x00423, 0}, {"iscr", 4, 0x1D4BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9B7[] = { {"efDot", 5, 0x02252, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9BB[] = { {"uhblk", 5, 0x02580, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9BC[] = { {"ropf", 4, 0x1D563, 0}, {"vprop", 5, 0x0221D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9BD[] = { {"isinE", 5, 0x022F9, 0}, {"raemptyv", 8, 0x029B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9C1[] = { {"lharu", 5, 0x021BC, 0}, {"ncongdot", 8, 0x02A6D, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9C2[] = { {"subnE", 5, 0x02ACB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9C3[] = { {"ngsim", 5, 0x02275, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9C5[] = { {"starf", 5, 0x02605, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9C9[] = { {"Ograve", 6, 0x000D2, 0}, {"hksearow", 8, 0x02925, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9CA[] = { {"iukcy", 5, 0x00456, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9CC[] = { {"uacute", 6, 0x000FA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9CF[] = { {"asymp", 5, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9D5[] = { {"lneq", 4, 0x02A87, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9D6[] = { {"Otimes", 6, 0x02A37, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9DA[] = { {"NotTildeTilde", 13, 0x02249, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9DB[] = { {"Integral", 8, 0x0222B, 0}, {"rbrke", 5, 0x0298C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9DD[] = { {"nsub", 4, 0x02284, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9DE[] = { {"rlhar", 5, 0x021CC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9E1[] = { {"dfr", 3, 0x1D521, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9E2[] = { {"subne", 5, 0x0228A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9E5[] = { {"varnothing", 10, 0x02205, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9E7[] = { {"Fcy", 3, 0x00424, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9E9[] = { {"DoubleLeftTee", 13, 0x02AE4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9EB[] = { {"isins", 5, 0x022F4, 0}, {"nsup", 4, 0x02285, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9ED[] = { {"circlearrowleft", 15, 0x021BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9EE[] = { {"isinv", 5, 0x02208, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9EF[] = { {"IEcy", 4, 0x00415, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F0[] = { {"conint", 6, 0x0222E, 0}, {"vBar", 4, 0x02AE8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F1[] = { {"edot", 4, 0x00117, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F2[] = { {"Kappa", 5, 0x0039A, 0}, {"MediumSpace", 11, 0x0205F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F3[] = { {"lbrksld", 7, 0x0298F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F4[] = { {"sect", 4, 0x000A7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F5[] = { {"nldr", 4, 0x02025, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F7[] = { {"Jscr", 4, 0x1D4A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9F9[] = { {"shy", 3, 0x000AD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9FA[] = { {"ulcrop", 6, 0x0230F, 0}, {"veebar", 6, 0x022BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_9FD[] = { {"Sopf", 4, 0x1D54A, 0}, {"cuwed", 5, 0x022CF, 0}, {"rAarr", 5, 0x021DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A01[] = { {"erarr", 5, 0x02971, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A04[] = { {"lbrkslu", 7, 0x0298D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A05[] = { {"NotSucceeds", 11, 0x02281, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A06[] = { {"nsccue", 6, 0x022E1, 0}, {"subrarr", 7, 0x02979, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A08[] = { {"looparrowright", 14, 0x021AC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A0C[] = { {"wp", 2, 0x02118, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A0D[] = { {"Emacr", 5, 0x00112, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A0E[] = { {"sim", 3, 0x0223C, 0}, {"wr", 2, 0x02240, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A10[] = { {"Udblac", 6, 0x00170, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A12[] = { {"Ufr", 3, 0x1D518, 0}, {"kappa", 5, 0x003BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A14[] = { {"notindot", 8, 0x022F5, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A15[] = { {"nleq", 4, 0x02270, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A16[] = { {"NestedLessLess", 14, 0x0226A, 0}, {"square", 6, 0x025A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A17[] = { {"nles", 4, 0x02A7D, 0x00338}, {"squarf", 6, 0x025AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A21[] = { {"order", 5, 0x02134, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A23[] = { {"igrave", 6, 0x000EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A24[] = { {"precneqq", 8, 0x02AB5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A25[] = { {"csupe", 5, 0x02AD2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A26[] = { {"xi", 2, 0x003BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A28[] = { {"NotHumpEqual", 12, 0x0224F, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A2A[] = { {"ord", 3, 0x02A5D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A2D[] = { {"emacr", 5, 0x00113, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A30[] = { {"nwnear", 6, 0x02927, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A32[] = { {"nprcue", 6, 0x022E0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A36[] = { {"NotExists", 9, 0x02204, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A37[] = { {"die", 3, 0x000A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A39[] = { {"ddotseq", 7, 0x02A77, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A3B[] = { {"Dashv", 5, 0x02AE4, 0}, {"Ucirc", 5, 0x000DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A3C[] = { {"orv", 3, 0x02A5B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A3D[] = { {"Because", 7, 0x02235, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A41[] = { {"kgreen", 6, 0x00138, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A43[] = { {"Ffr", 3, 0x1D509, 0}, {"LeftVector", 10, 0x021BC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A44[] = { {"lstrok", 6, 0x00142, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A45[] = { {"twixt", 5, 0x0226C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A48[] = { {"compfn", 6, 0x02218, 0}, {"div", 3, 0x000F7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A4F[] = { {"drcrop", 6, 0x0230C, 0}, {"shortmid", 8, 0x02223, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A53[] = { {"iopf", 4, 0x1D55A, 0}, {"triangledown", 12, 0x025BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A54[] = { {"IJlig", 5, 0x00132, 0}, {"thetasym", 8, 0x003D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A56[] = { {"Sigma", 5, 0x003A3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A57[] = { {"equivDD", 7, 0x02A78, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A5A[] = { {"Cacute", 6, 0x00106, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A5B[] = { {"dashv", 5, 0x022A3, 0}, {"ucirc", 5, 0x000FB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A61[] = { {"gneqq", 5, 0x02269, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A62[] = { {"gvertneqq", 9, 0x02269, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A63[] = { {"RightDownVectorBar", 18, 0x02955, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A64[] = { {"NotLessLess", 11, 0x0226A, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A69[] = { {"Ccedil", 6, 0x000C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A6A[] = { {"odblac", 6, 0x00151, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A6B[] = { {"mstpos", 6, 0x0223E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A6D[] = { {"cemptyv", 7, 0x029B2, 0}, {"rarrap", 6, 0x02975, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A6F[] = { {"rmoust", 6, 0x023B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A70[] = { {"elsdot", 6, 0x02A97, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A76[] = { {"sigma", 5, 0x003C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A78[] = { {"Implies", 7, 0x021D2, 0}, {"isin", 4, 0x02208, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A7A[] = { {"bottom", 6, 0x022A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A7E[] = { {"ShortRightArrow", 15, 0x02192, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A81[] = { {"cupcap", 6, 0x02A46, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A82[] = { {"NotSquareSuperset", 17, 0x02290, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A84[] = { {"LeftArrowRightArrow", 19, 0x021C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A85[] = { {"FilledVerySmallSquare", 21, 0x025AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A86[] = { {"LeftUpTeeVector", 15, 0x02960, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A89[] = { {"DoubleRightArrow", 16, 0x021D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A8D[] = { {"raquo", 5, 0x000BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A8E[] = { {"Ascr", 4, 0x1D49C, 0}, {"ReverseUpEquilibrium", 20, 0x0296F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A92[] = { {"hArr", 4, 0x021D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A94[] = { {"Jopf", 4, 0x1D541, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A96[] = { {"npar", 4, 0x02226, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A98[] = { {"SupersetEqual", 13, 0x02287, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A99[] = { {"ffllig", 6, 0x0FB04, 0}, {"smt", 3, 0x02AAA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A9A[] = { {"twoheadrightarrow", 17, 0x021A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A9D[] = { {"ecaron", 6, 0x0011B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_A9F[] = { {"NotRightTriangleBar", 19, 0x029D0, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AA3[] = { {"apid", 4, 0x0224B, 0}, {"vscr", 4, 0x1D4CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AA4[] = { {"supdot", 6, 0x02ABE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AA5[] = { {"colone", 6, 0x02254, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AA7[] = { {"dwangle", 7, 0x029A6, 0}, {"shchcy", 6, 0x00449, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AAC[] = { {"ltdot", 5, 0x022D6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AB2[] = { {"downharpoonright", 16, 0x021C2, 0}, {"gjcy", 4, 0x00453, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AB4[] = { {"wfr", 3, 0x1D534, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AB5[] = { {"rfisht", 6, 0x0297D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ABA[] = { {"Ycy", 3, 0x0042B, 0}, {"swarrow", 7, 0x02199, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AC0[] = { {"nharr", 5, 0x021AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AC4[] = { {"frac12", 6, 0x000BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AC5[] = { {"frac13", 6, 0x02153, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AC6[] = { {"frac14", 6, 0x000BC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AC7[] = { {"GreaterEqual", 12, 0x02265, 0}, {"frac15", 6, 0x02155, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AC8[] = { {"Gamma", 5, 0x00393, 0}, {"frac16", 6, 0x02159, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ACA[] = { {"dzigrarr", 8, 0x027FF, 0}, {"frac18", 6, 0x0215B, 0}, {"rcaron", 6, 0x00159, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ACC[] = { {"DownRightTeeVector", 18, 0x0295F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ACF[] = { {"nvrtrie", 7, 0x022B5, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AD2[] = { {"iota", 4, 0x003B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AD3[] = { {"sol", 3, 0x0002F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AD4[] = { {"rbrace", 6, 0x0007D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ADA[] = { {"rbrack", 6, 0x0005D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ADD[] = { {"rsqb", 4, 0x0005D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ADF[] = { {"oint", 4, 0x0222E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AE4[] = { {"Wscr", 4, 0x1D4B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AE5[] = { {"hfr", 3, 0x1D525, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AE6[] = { {"frac23", 6, 0x02154, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AE7[] = { {"dlcorn", 6, 0x0231E, 0}, {"verbar", 6, 0x0007C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AE8[] = { {"frac25", 6, 0x02156, 0}, {"gamma", 5, 0x003B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AE9[] = { {"nVDash", 6, 0x022AF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AEB[] = { {"Jcy", 3, 0x00419, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AF5[] = { {"nwarrow", 7, 0x02196, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AF6[] = { {"OverBar", 7, 0x0203E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AF7[] = { {"rightsquigarrow", 15, 0x0219D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AFA[] = { {"iexcl", 5, 0x000A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AFD[] = { {"sqcap", 5, 0x02293, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_AFE[] = { {"pertenk", 7, 0x02031, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B08[] = { {"PrecedesEqual", 13, 0x02AAF, 0}, {"frac34", 6, 0x000BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B09[] = { {"Therefore", 9, 0x02234, 0}, {"frac35", 6, 0x02157, 0}, {"nvDash", 6, 0x022AD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B0A[] = { {"odsold", 6, 0x029BC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B0C[] = { {"dot", 3, 0x002D9, 0}, {"frac38", 6, 0x0215C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B10[] = { {"sqcaps", 6, 0x02293, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B11[] = { {"ZeroWidthSpace", 14, 0x0200B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B15[] = { {"rarrfs", 6, 0x0291E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B16[] = { {"Yfr", 3, 0x1D51C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B1E[] = { {"CircleDot", 9, 0x02299, 0}, {"gtcir", 5, 0x02A7A, 0}, {"squ", 3, 0x025A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B1F[] = { {"angmsd", 6, 0x02221, 0}, {"nsubseteq", 9, 0x02288, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B23[] = { {"iprod", 5, 0x02A3C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B24[] = { {"bprime", 6, 0x02035, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B27[] = { {"supsub", 6, 0x02AD4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B29[] = { {"SquareSupersetEqual", 19, 0x02292, 0}, {"therefore", 9, 0x02234, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B2A[] = { {"frac45", 6, 0x02158, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B2B[] = { {"Aopf", 4, 0x1D538, 0}, {"NotGreaterFullEqual", 19, 0x02267, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B2C[] = { {"Tstrok", 6, 0x00166, 0}, {"rightleftarrows", 15, 0x021C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B2D[] = { {"Fouriertrf", 10, 0x02131, 0}, {"epar", 4, 0x022D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B2E[] = { {"omid", 4, 0x029B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B2F[] = { {"OpenCurlyDoubleQuote", 20, 0x0201C, 0}, {"dagger", 6, 0x02020, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B33[] = { {"semi", 4, 0x0003B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B35[] = { {"supsup", 6, 0x02AD6, 0}, {"zeetrf", 6, 0x02128, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B36[] = { {"DifferentialD", 13, 0x02146, 0}, {"topcir", 6, 0x02AF1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B3A[] = { {"mscr", 4, 0x1D4C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B3D[] = { {"Wcirc", 5, 0x00174, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B3E[] = { {"boxdL", 5, 0x02555, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B40[] = { {"Gbreve", 6, 0x0011E, 0}, {"vopf", 4, 0x1D567, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B42[] = { {"lap", 3, 0x02A85, 0}, {"llarr", 5, 0x021C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B44[] = { {"boxdR", 5, 0x02552, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B46[] = { {"RightAngleBracket", 17, 0x027E9, 0}, {"lat", 3, 0x02AAB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B47[] = { {"Jfr", 3, 0x1D50D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B4C[] = { {"frac56", 6, 0x0215A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B4E[] = { {"frac58", 6, 0x0215D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B4F[] = { {"rarrhk", 6, 0x021AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B50[] = { {"lesdot", 6, 0x02A7F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B51[] = { {"ApplyFunction", 13, 0x02061, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B52[] = { {"NotGreaterTilde", 15, 0x02275, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B53[] = { {"Cedilla", 7, 0x000B8, 0}, {"curvearrowright", 15, 0x021B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B56[] = { {"rdsh", 4, 0x021B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B58[] = { {"larrb", 5, 0x021E4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B5C[] = { {"vrtri", 5, 0x022B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B5D[] = { {"nequiv", 6, 0x02262, 0}, {"wcirc", 5, 0x00175, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B5E[] = { {"boxdl", 5, 0x02510, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B63[] = { {"DoubleDownArrow", 15, 0x021D3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B64[] = { {"boxdr", 5, 0x0250C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B67[] = { {"pluscir", 7, 0x02A22, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B69[] = { {"longmapsto", 10, 0x027FC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B6B[] = { {"gnap", 4, 0x02A8A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B6D[] = { {"bigodot", 7, 0x02A00, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B72[] = { {"thickapprox", 11, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B73[] = { {"DotDot", 6, 0x020DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B77[] = { {"incare", 6, 0x02105, 0}, {"rarrbfs", 7, 0x02920, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B78[] = { {"apos", 4, 0x00027, 0}, {"tbrk", 4, 0x023B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B7A[] = { {"grave", 5, 0x00060, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B7B[] = { {"Nscr", 4, 0x1D4A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B7E[] = { {"rangle", 6, 0x027E9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B7F[] = { {"uArr", 4, 0x021D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B81[] = { {"Wopf", 4, 0x1D54E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B82[] = { {"doteq", 5, 0x02250, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B87[] = { {"times", 5, 0x000D7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B8D[] = { {"fflig", 5, 0x0FB00, 0}, {"lcy", 3, 0x0043B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B8F[] = { {"sub", 3, 0x02282, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B90[] = { {"frac78", 6, 0x0215E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B94[] = { {"xrarr", 5, 0x027F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B98[] = { {"UpArrowDownArrow", 16, 0x021C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B99[] = { {"bbrktbrk", 8, 0x023B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B9A[] = { {"abreve", 6, 0x00103, 0}, {"lsaquo", 6, 0x02039, 0}, {"sum", 3, 0x02211, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B9C[] = { {"Eacute", 6, 0x000C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_B9D[] = { {"sup", 3, 0x02283, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BA5[] = { {"ContourIntegral", 15, 0x0222E, 0}, {"DiacriticalDot", 14, 0x002D9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BA9[] = { {"trisb", 5, 0x029CD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BAE[] = { {"Hcirc", 5, 0x00124, 0}, {"lceil", 5, 0x02308, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BB2[] = { {"Zcaron", 6, 0x0017D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BB5[] = { {"looparrowleft", 13, 0x021AB, 0}, {"oelig", 5, 0x00153, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BB6[] = { {"LessSlantEqual", 14, 0x02A7D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BB7[] = { {"NegativeThinSpace", 17, 0x0200B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BBA[] = { {"boxhD", 5, 0x02565, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BBC[] = { {"omicron", 7, 0x003BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BBD[] = { {"leg", 3, 0x022DA, 0}, {"rightthreetimes", 15, 0x022CC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BBF[] = { {"NotSucceedsSlantEqual", 21, 0x022E1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC1[] = { {"angmsdaa", 8, 0x029A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC2[] = { {"angmsdab", 8, 0x029A9, 0}, {"rAtail", 6, 0x0291C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC3[] = { {"angmsdac", 8, 0x029AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC4[] = { {"angmsdad", 8, 0x029AB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC5[] = { {"angmsdae", 8, 0x029AC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC6[] = { {"angmsdaf", 8, 0x029AD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC7[] = { {"angmsdag", 8, 0x029AE, 0}, {"leq", 3, 0x02264, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC8[] = { {"angmsdah", 8, 0x029AF, 0}, {"solbar", 6, 0x0233F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BC9[] = { {"Racute", 6, 0x00154, 0}, {"les", 3, 0x02A7D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BCB[] = { {"boxhU", 5, 0x02568, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BCE[] = { {"hcirc", 5, 0x00125, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BD1[] = { {"dscr", 4, 0x1D4B9, 0}, {"smashp", 6, 0x02A33, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BD7[] = { {"mopf", 4, 0x1D55E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BD8[] = { {"Rcedil", 6, 0x00156, 0}, {"dscy", 4, 0x00455, 0}, {"prap", 4, 0x02AB7, 0}, {"rarrlp", 6, 0x021AC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BD9[] = { {"Aogon", 5, 0x00104, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BDA[] = { {"boxhd", 5, 0x0252C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BDB[] = { {"subset", 6, 0x02282, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BDD[] = { {"lgE", 3, 0x02A91, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BDF[] = { {"epsilon", 7, 0x003B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BE1[] = { {"curarrm", 7, 0x0293C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BE2[] = { {"ratail", 6, 0x0291A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BE4[] = { {"DoubleLongLeftRightArrow", 24, 0x027FA, 0}, {"rhov", 4, 0x003F1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BE7[] = { {"LeftDoubleBracket", 17, 0x027E6, 0}, {"Lleftarrow", 10, 0x021DA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BE8[] = { {"Uuml", 4, 0x000DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BE9[] = { {"lfr", 3, 0x1D529, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BEA[] = { {"minusdu", 7, 0x02A2A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BEB[] = { {"boxhu", 5, 0x02534, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BEF[] = { {"Ncy", 3, 0x0041D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BF0[] = { {"gneq", 4, 0x02A88, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BF1[] = { {"rangd", 5, 0x02992, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BF2[] = { {"range", 5, 0x029A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BF3[] = { {"lfloor", 6, 0x0230A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BF7[] = { {"NotSucceedsTilde", 16, 0x0227F, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BF9[] = { {"aogon", 5, 0x00105, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BFA[] = { {"NotGreaterSlantEqual", 20, 0x02A7E, 0x00338}, {"NotSquareSupersetEqual", 22, 0x022E3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_BFC[] = { {"profsurf", 8, 0x02313, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C02[] = { {"wedgeq", 6, 0x02259, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C0B[] = { {"Alpha", 5, 0x00391, 0}, {"DiacriticalDoubleAcute", 22, 0x002DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C0C[] = { {"lltri", 5, 0x025FA, 0}, {"tcaron", 6, 0x00165, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C11[] = { {"Imacr", 5, 0x0012A, 0}, {"subseteq", 8, 0x02286, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C12[] = { {"Escr", 4, 0x02130, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C16[] = { {"lArr", 4, 0x021D0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C18[] = { {"Nopf", 4, 0x02115, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C1A[] = { {"rpar", 4, 0x00029, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C1D[] = { {"divonx", 6, 0x022C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C1E[] = { {"olcir", 5, 0x029BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C23[] = { {"lacute", 6, 0x0013A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C27[] = { {"zscr", 4, 0x1D4CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C2B[] = { {"alpha", 5, 0x003B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C31[] = { {"imacr", 5, 0x0012B, 0}, {"vellip", 6, 0x022EE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C32[] = { {"lcedil", 6, 0x0013C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C33[] = { {"sime", 4, 0x02243, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C34[] = { {"empty", 5, 0x02205, 0}, {"imped", 5, 0x001B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C35[] = { {"simg", 4, 0x02A9E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C36[] = { {"kjcy", 4, 0x0045C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C3A[] = { {"siml", 4, 0x02A9D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C3E[] = { {"LessEqualGreater", 16, 0x022DA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C3F[] = { {"Ycirc", 5, 0x00176, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C40[] = { {"RoundImplies", 12, 0x02970, 0}, {"nvrArr", 6, 0x02903, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C43[] = { {"check", 5, 0x02713, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C44[] = { {"nlarr", 5, 0x0219A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C46[] = { {"middot", 6, 0x000B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C48[] = { {"par", 3, 0x02225, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C4A[] = { {"NotGreaterGreater", 17, 0x0226B, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C4B[] = { {"Nfr", 3, 0x1D511, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C4F[] = { {"nwArr", 5, 0x021D6, 0}, {"prec", 4, 0x0227A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C50[] = { {"Barv", 4, 0x02AE7, 0}, {"yacute", 6, 0x000FD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C54[] = { {"DoubleLeftRightArrow", 20, 0x021D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C58[] = { {"Coproduct", 9, 0x02210, 0}, {"rarrpl", 6, 0x02945, 0}, {"subsim", 6, 0x02AC7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C5A[] = { {"ntgl", 4, 0x02279, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C5B[] = { {"LeftTriangleBar", 15, 0x029CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C5F[] = { {"ycirc", 5, 0x00177, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C69[] = { {"doteqdot", 8, 0x02251, 0}, {"nang", 4, 0x02220, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C6B[] = { {"bigcap", 6, 0x022C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C6C[] = { {"CHcy", 4, 0x00427, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C6E[] = { {"dopf", 4, 0x1D555, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C72[] = { {"inodot", 6, 0x00131, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C76[] = { {"nvHarr", 6, 0x02904, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C77[] = { {"laemptyv", 8, 0x029B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C78[] = { {"bigcirc", 7, 0x025EF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C7A[] = { {"scnap", 5, 0x02ABA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C7B[] = { {"DownLeftVector", 14, 0x021BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C80[] = { {"race", 4, 0x0223D, 0x00331}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C82[] = { {"vartriangleright", 16, 0x022B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C89[] = { {"napE", 4, 0x02A70, 0x00338}, {"supedot", 7, 0x02AC4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C8E[] = { {"acE", 3, 0x0223E, 0x00333}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C91[] = { {"pcy", 3, 0x0043F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C93[] = { {"qprime", 6, 0x02057, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C94[] = { {"RightTeeVector", 14, 0x0295B, 0}, {"curlyvee", 8, 0x022CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C95[] = { {"swarhk", 6, 0x02926, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_C98[] = { {"Atilde", 6, 0x000C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CA6[] = { {"bbrk", 4, 0x023B5, 0}, {"prnap", 5, 0x02AB9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CA8[] = { {"image", 5, 0x02111, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CA9[] = { {"sext", 4, 0x02736, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CAA[] = { {"ldquo", 5, 0x0201C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CAC[] = { {"NotLeftTriangleBar", 18, 0x029CF, 0x00338}, {"epsiv", 5, 0x003F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CAD[] = { {"CenterDot", 9, 0x000B7, 0}, {"acd", 3, 0x0223F, 0}, {"upuparrows", 10, 0x021C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CAF[] = { {"Eopf", 4, 0x1D53C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CB0[] = { {"Jcirc", 5, 0x00134, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CB2[] = { {"smid", 4, 0x02223, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CB4[] = { {"bull", 4, 0x02022, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CB6[] = { {"rhard", 5, 0x021C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CB7[] = { {"nsupset", 7, 0x02283, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CBA[] = { {"npre", 4, 0x02AAF, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CBE[] = { {"qscr", 4, 0x1D4C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CC2[] = { {"acy", 3, 0x00430, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CC4[] = { {"lnE", 3, 0x02268, 0}, {"zopf", 4, 0x1D56B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CC5[] = { {"Ntilde", 6, 0x000D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CC7[] = { {"rharu", 5, 0x021C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CC8[] = { {"kappav", 6, 0x003F0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CC9[] = { {"timesb", 6, 0x022A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CCB[] = { {"iiiint", 6, 0x02A0C, 0}, {"timesd", 6, 0x02A30, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CD0[] = { {"jcirc", 5, 0x00135, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CD2[] = { {"nsimeq", 6, 0x02244, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CD3[] = { {"Esim", 4, 0x02A73, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CD9[] = { {"Cap", 3, 0x022D2, 0}, {"bump", 4, 0x0224E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CDA[] = { {"lvnE", 4, 0x02268, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CDC[] = { {"rarrtl", 6, 0x021A3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CE4[] = { {"lne", 3, 0x02A87, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CE6[] = { {"commat", 6, 0x00040, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CE8[] = { {"hslash", 6, 0x0210F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CE9[] = { {"lthree", 6, 0x022CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CED[] = { {"Gcedil", 6, 0x00122, 0}, {"pfr", 3, 0x1D52D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CF1[] = { {"RightTriangleEqual", 18, 0x022B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CF2[] = { {"ngeqslant", 9, 0x02A7E, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CF3[] = { {"Rcy", 3, 0x00420, 0}, {"gimel", 5, 0x02137, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CF4[] = { {"curarr", 6, 0x021B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CFA[] = { {"ntlg", 4, 0x02278, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_CFF[] = { {"Rscr", 4, 0x0211B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D00[] = { {"urcrop", 6, 0x0230E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D06[] = { {"Poincareplane", 13, 0x0210C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D07[] = { {"NoBreak", 7, 0x02060, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D0B[] = { {"lcub", 4, 0x0007B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D0E[] = { {"nltri", 5, 0x022EA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D10[] = { {"blacktriangledown", 17, 0x025BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D11[] = { {"fjlig", 5, 0x00066, 0x0006A}, {"percnt", 6, 0x00025, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D12[] = { {"rightharpoondown", 16, 0x021C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D13[] = { {"LeftAngleBracket", 16, 0x027E8, 0}, {"npreceq", 7, 0x02AAF, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D15[] = { {"cupcup", 6, 0x02A4A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D18[] = { {"LeftVectorBar", 13, 0x02952, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D19[] = { {"NJcy", 4, 0x0040A, 0}, {"triangleright", 13, 0x025B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D1A[] = { {"Tcedil", 6, 0x00162, 0}, {"loz", 3, 0x025CA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D1E[] = { {"afr", 3, 0x1D51E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D1F[] = { {"NotLessTilde", 12, 0x02274, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D20[] = { {"NotElement", 10, 0x02209, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D22[] = { {"NotHumpDownHump", 15, 0x0224E, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D24[] = { {"SquareSubsetEqual", 17, 0x02291, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D26[] = { {"nleqq", 5, 0x02266, 0x00338}, {"phi", 3, 0x003C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D2A[] = { {"NotRightTriangle", 16, 0x022EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D32[] = { {"lhblk", 5, 0x02584, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D34[] = { {"caret", 5, 0x02041, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D35[] = { {"bsemi", 5, 0x0204F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D38[] = { {"aacute", 6, 0x000E1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D39[] = { {"mapsto", 6, 0x021A6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D3A[] = { {"Congruent", 9, 0x02261, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D3B[] = { {"Vdash", 5, 0x022A9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D3E[] = { {"longrightarrow", 14, 0x027F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D42[] = { {"iinfin", 6, 0x029DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D44[] = { {"EmptyVerySmallSquare", 20, 0x025AB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D49[] = { {"real", 4, 0x0211C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D4C[] = { {"SucceedsEqual", 13, 0x02AB0, 0}, {"utilde", 6, 0x00169, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D4F[] = { {"Rfr", 3, 0x0211C, 0}, {"tau", 3, 0x003C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D51[] = { {"Wedge", 5, 0x022C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D54[] = { {"piv", 3, 0x003D6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D55[] = { {"hscr", 4, 0x1D4BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D56[] = { {"subdot", 6, 0x02ABD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D57[] = { {"dsol", 4, 0x029F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D5A[] = { {"prnE", 4, 0x02AB5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D5B[] = { {"qopf", 4, 0x1D562, 0}, {"vdash", 5, 0x022A2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D5F[] = { {"Star", 4, 0x022C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D63[] = { {"sqsupseteq", 10, 0x02292, 0}, {"zhcy", 4, 0x00436, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D65[] = { {"nacute", 6, 0x00144, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D69[] = { {"lessgtr", 7, 0x02276, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D6A[] = { {"nless", 5, 0x0226E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D6C[] = { {"RightTeeArrow", 13, 0x021A6, 0}, {"Yuml", 4, 0x00178, 0}, {"target", 6, 0x02316, 0}, {"upharpoonleft", 13, 0x021BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D6F[] = { {"between", 7, 0x0226C, 0}, {"boxuL", 5, 0x0255B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D70[] = { {"TSHcy", 5, 0x0040B, 0}, {"lrm", 3, 0x0200E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D71[] = { {"excl", 4, 0x00021, 0}, {"hyphen", 6, 0x02010, 0}, {"mlcp", 4, 0x02ADB, 0}, {"wedge", 5, 0x02227, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D74[] = { {"ncedil", 6, 0x00146, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D75[] = { {"boxuR", 5, 0x02558, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D76[] = { {"Not", 3, 0x02AEC, 0}, {"epsi", 4, 0x003B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D7C[] = { {"disin", 5, 0x022F2, 0}, {"nRightarrow", 11, 0x021CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D7D[] = { {"cylcty", 6, 0x0232D, 0}, {"neArr", 5, 0x021D7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D7E[] = { {"prnsim", 6, 0x022E8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D80[] = { {"Cfr", 3, 0x0212D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D81[] = { {"Beta", 4, 0x00392, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D85[] = { {"leftarrowtail", 13, 0x021A2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D87[] = { {"parsl", 5, 0x02AFD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D89[] = { {"xwedge", 6, 0x022C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D8A[] = { {"olcross", 7, 0x029BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D8C[] = { {"boxvH", 5, 0x0256A, 0}, {"lsh", 3, 0x021B0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D8D[] = { {"circledR", 8, 0x000AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D8E[] = { {"Rho", 3, 0x003A1, 0}, {"circledS", 8, 0x024C8, 0}, {"cupor", 5, 0x02A45, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D8F[] = { {"Ugrave", 6, 0x000D9, 0}, {"boxul", 5, 0x02518, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D90[] = { {"boxvL", 5, 0x02561, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D91[] = { {"sqcup", 5, 0x02294, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D93[] = { {"rect", 4, 0x025AD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D94[] = { {"mldr", 4, 0x02026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D95[] = { {"boxur", 5, 0x02514, 0}, {"digamma", 7, 0x003DD, 0}, {"tcy", 3, 0x00442, 0}, {"urcorner", 8, 0x0231D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D96[] = { {"DoubleLeftArrow", 15, 0x021D0, 0}, {"Iscr", 4, 0x02110, 0}, {"boxvR", 5, 0x0255E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D98[] = { {"ulcorn", 6, 0x0231C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D9A[] = { {"prod", 4, 0x0220F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_D9C[] = { {"Ropf", 4, 0x0211D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DA0[] = { {"rmoustache", 10, 0x023B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DA5[] = { {"NegativeMediumSpace", 19, 0x0200B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DA6[] = { {"prop", 4, 0x0221D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DA8[] = { {"TScy", 4, 0x00426, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DA9[] = { {"xsqcup", 6, 0x02A06, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DAC[] = { {"bemptyv", 7, 0x029B0, 0}, {"boxvh", 5, 0x0253C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DB0[] = { {"boxvl", 5, 0x02524, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DB3[] = { {"NotTildeFullEqual", 17, 0x02247, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DB4[] = { {"subE", 4, 0x02AC5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DB6[] = { {"boxvr", 5, 0x0251C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DB7[] = { {"bigvee", 6, 0x022C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DB9[] = { {"Chi", 3, 0x003A7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DBC[] = { {"circeq", 6, 0x02257, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DBE[] = { {"emsp13", 6, 0x02004, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DBF[] = { {"emsp14", 6, 0x02005, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DC2[] = { {"ouml", 4, 0x000F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DC3[] = { {"RightArrowBar", 13, 0x021E5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DC6[] = { {"ecy", 3, 0x0044D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DC8[] = { {"succneqq", 8, 0x02AB6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DCA[] = { {"npart", 5, 0x02202, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DCF[] = { {"Element", 7, 0x02208, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DD1[] = { {"Edot", 4, 0x00116, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DD3[] = { {"RightUpDownVector", 17, 0x0294F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DD4[] = { {"sube", 4, 0x02286, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DD5[] = { {"jsercy", 6, 0x00458, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DD7[] = { {"varrho", 6, 0x003F1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DD9[] = { {"subsub", 6, 0x02AD5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DDC[] = { {"Dcaron", 6, 0x0010E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DDD[] = { {"Eogon", 5, 0x00118, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DE4[] = { {"geqslant", 8, 0x02A7E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DE6[] = { {"rdldhar", 7, 0x02969, 0}, {"zdot", 4, 0x0017C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DE7[] = { {"subsup", 6, 0x02AD3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DE9[] = { {"ograve", 6, 0x000F2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DEB[] = { {"ReverseElement", 14, 0x0220B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DED[] = { {"drcorn", 6, 0x0231F, 0}, {"rang", 4, 0x027E9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DF1[] = { {"tfr", 3, 0x1D531, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DF2[] = { {"hopf", 4, 0x1D559, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DF3[] = { {"succ", 4, 0x0227B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DF6[] = { {"otimes", 6, 0x02297, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DF7[] = { {"Vcy", 3, 0x00412, 0}, {"ltquest", 7, 0x02A7B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DF9[] = { {"lozenge", 7, 0x025CA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DFB[] = { {"LeftDownVector", 14, 0x021C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_DFD[] = { {"eogon", 5, 0x00119, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E03[] = { {"amp", 3, 0x00026, 0}, {"lopar", 5, 0x02985, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E04[] = { {"loplus", 6, 0x02A2D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E08[] = { {"NotTilde", 8, 0x02241, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E09[] = { {"CounterClockwiseContourIntegral", 31, 0x02233, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E0C[] = { {"InvisibleTimes", 14, 0x02062, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E11[] = { {"lesdotor", 8, 0x02A83, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E18[] = { {"and", 3, 0x02227, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E1B[] = { {"RightUpVector", 13, 0x021BE, 0}, {"ang", 3, 0x02220, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E1C[] = { {"DoubleRightTee", 14, 0x022A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E1D[] = { {"LeftUpVectorBar", 15, 0x02958, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E1E[] = { {"smte", 4, 0x02AAC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E20[] = { {"Iacute", 6, 0x000CD, 0}, {"triminus", 8, 0x02A3A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E22[] = { {"efr", 3, 0x1D522, 0}, {"iiint", 5, 0x0222D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E23[] = { {"ctdot", 5, 0x022EF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E24[] = { {"mnplus", 6, 0x02213, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E25[] = { {"Vee", 3, 0x022C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E28[] = { {"Gcy", 3, 0x00413, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E2A[] = { {"lurdshar", 8, 0x0294A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E2C[] = { {"smeparsl", 8, 0x029E4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E2F[] = { {"DoubleVerticalBar", 17, 0x02225, 0}, {"iecy", 4, 0x00435, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E30[] = { {"udblac", 6, 0x00171, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E32[] = { {"gtquest", 7, 0x02A7C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E33[] = { {"Iopf", 4, 0x1D540, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E35[] = { {"bsime", 5, 0x022CD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E36[] = { {"RightVector", 11, 0x021C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E37[] = { {"NotGreaterLess", 14, 0x02279, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E3B[] = { {"apE", 3, 0x02A70, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E41[] = { {"CupCap", 6, 0x0224D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E42[] = { {"uscr", 4, 0x1D4CA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E43[] = { {"erDot", 5, 0x02253, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E44[] = { {"egs", 3, 0x02A96, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E48[] = { {"rlarr", 5, 0x021C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E4C[] = { {"prE", 3, 0x02AB3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E4E[] = { {"QUOT", 4, 0x00022, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E53[] = { {"Vfr", 3, 0x1D519, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E55[] = { {"cupbrcap", 8, 0x02A48, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E57[] = { {"intercal", 8, 0x022BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E58[] = { {"imath", 5, 0x00131, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E59[] = { {"RightUpTeeVector", 16, 0x0295C, 0}, {"trie", 4, 0x0225C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E5B[] = { {"ape", 3, 0x0224A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E5D[] = { {"softcy", 6, 0x0044C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E5E[] = { {"rarrb", 5, 0x021E5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E5F[] = { {"FilledSmallSquare", 17, 0x025FC, 0}, {"rarrc", 5, 0x02933, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E60[] = { {"Superset", 8, 0x02283, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E61[] = { {"hoarr", 5, 0x021FF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E63[] = { {"DownRightVectorBar", 18, 0x02957, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E64[] = { {"brvbar", 6, 0x000A6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E65[] = { {"ecolon", 6, 0x02255, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E66[] = { {"GreaterLess", 11, 0x02277, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E6A[] = { {"nrArr", 5, 0x021CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E6C[] = { {"pre", 3, 0x02AAF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E6F[] = { {"aleph", 5, 0x02135, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E70[] = { {"DiacriticalAcute", 16, 0x000B4, 0}, {"SmallCircle", 11, 0x02218, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E71[] = { {"parsim", 6, 0x02AF3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E73[] = { {"rarrw", 5, 0x0219D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E78[] = { {"caron", 5, 0x002C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E7A[] = { {"cacute", 6, 0x00107, 0}, {"lagran", 6, 0x02112, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E7C[] = { {"rarr", 4, 0x02192, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E80[] = { {"Rrightarrow", 11, 0x021DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E83[] = { {"Vscr", 4, 0x1D4B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E84[] = { {"Gfr", 3, 0x1D50A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E89[] = { {"ccedil", 6, 0x000E7, 0}, {"propto", 6, 0x0221D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E8E[] = { {"zwnj", 4, 0x0200C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E91[] = { {"psi", 3, 0x003C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E99[] = { {"infin", 5, 0x0221E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_E9C[] = { {"circledcirc", 11, 0x0229A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EA1[] = { {"Proportion", 10, 0x02237, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EA2[] = { {"subseteqq", 9, 0x02AC5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EA4[] = { {"nGtv", 4, 0x0226B, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EA8[] = { {"macr", 4, 0x000AF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EA9[] = { {"orslope", 7, 0x02A57, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EB1[] = { {"frown", 5, 0x02322, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EB2[] = { {"Iota", 4, 0x00399, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EB4[] = { {"rceil", 5, 0x02309, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EB7[] = { {"spadesuit", 9, 0x02660, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EB8[] = { {"sstarf", 6, 0x022C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ECA[] = { {"icy", 3, 0x00438, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ECD[] = { {"ast", 3, 0x0002A, 0}, {"nmid", 4, 0x02224, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ECF[] = { {"bowtie", 6, 0x022C8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ED1[] = { {"thetav", 6, 0x003D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ED7[] = { {"vangrt", 6, 0x0299C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ED8[] = { {"numsp", 5, 0x02007, 0}, {"triplus", 7, 0x02A39, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_ED9[] = { {"lscr", 4, 0x1D4C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EDA[] = { {"pointint", 8, 0x02A15, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EDB[] = { {"Theta", 5, 0x00398, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EDF[] = { {"rightrightarrows", 16, 0x021C9, 0}, {"uopf", 4, 0x1D566, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EE2[] = { {"ell", 3, 0x02113, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EE4[] = { {"cuepr", 5, 0x022DE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EE5[] = { {"NotVerticalBar", 14, 0x02224, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EE7[] = { {"xnis", 4, 0x022FB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EE9[] = { {"els", 3, 0x02A95, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EEF[] = { {"DDotrahd", 8, 0x02911, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EF1[] = { {"larrbfs", 7, 0x0291F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EF2[] = { {"Rsh", 3, 0x021B1, 0}, {"boxplus", 7, 0x0229E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EF4[] = { {"swarr", 5, 0x02199, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EF5[] = { {"gvnE", 4, 0x02269, 0x0FE00}, {"xfr", 3, 0x1D535, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EF9[] = { {"ldca", 4, 0x02936, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EFB[] = { {"NotPrecedesSlantEqual", 21, 0x022E0, 0}, {"YAcy", 4, 0x0042F, 0}, {"Zcy", 3, 0x00417, 0}, {"andslope", 8, 0x02A58, 0}, {"numero", 6, 0x02116, 0}, {"theta", 5, 0x003B8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EFE[] = { {"mapstoup", 8, 0x021A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_EFF[] = { {"bigcup", 6, 0x022C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F03[] = { {"nesear", 6, 0x02928, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F05[] = { {"lesssim", 7, 0x02272, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F08[] = { {"DownArrow", 9, 0x02193, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F0B[] = { {"orarr", 5, 0x021BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F0F[] = { {"ccaps", 5, 0x02A4D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F10[] = { {"xdtri", 5, 0x025BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F11[] = { {"xcap", 4, 0x022C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F13[] = { {"downdownarrows", 14, 0x021CA, 0}, {"nisd", 4, 0x022FA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F14[] = { {"VerticalBar", 11, 0x02223, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F15[] = { {"TRADE", 5, 0x02122, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F17[] = { {"Omacr", 5, 0x0014C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F18[] = { {"top", 3, 0x022A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F19[] = { {"LeftRightArrow", 14, 0x02194, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F1A[] = { {"Mscr", 4, 0x02133, 0}, {"iff", 3, 0x021D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F1F[] = { {"downharpoonleft", 15, 0x021C3, 0}, {"eng", 3, 0x0014B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F20[] = { {"Vopf", 4, 0x1D54D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F26[] = { {"ifr", 3, 0x1D526, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F28[] = { {"Downarrow", 9, 0x021D3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F2C[] = { {"Kcy", 3, 0x0041A, 0}, {"angle", 5, 0x02220, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F2F[] = { {"lescc", 5, 0x02AA8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F30[] = { {"lesseqqgtr", 10, 0x02A8B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F31[] = { {"bigstar", 7, 0x02605, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F33[] = { {"ddagger", 7, 0x02021, 0}, {"nltrie", 6, 0x022EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F37[] = { {"omacr", 5, 0x0014D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F38[] = { {"cuesc", 5, 0x022DF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F40[] = { {"circlearrowright", 16, 0x021BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F41[] = { {"ngeqq", 5, 0x02267, 0x00338}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F44[] = { {"squf", 4, 0x025AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F46[] = { {"rtri", 4, 0x025B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F47[] = { {"VerticalLine", 12, 0x0007C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F48[] = { {"downarrow", 9, 0x02193, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F4B[] = { {"Scaron", 6, 0x00160, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F4C[] = { {"tstrok", 6, 0x00167, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F50[] = { {"wreath", 6, 0x02240, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F51[] = { {"exponentiale", 12, 0x02147, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F55[] = { {"Idot", 4, 0x00130, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F57[] = { {"Zfr", 3, 0x02128, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F58[] = { {"bnot", 4, 0x02310, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F5B[] = { {"infintie", 8, 0x029DD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F5D[] = { {"angrtvbd", 8, 0x0299D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F5F[] = { {"prurel", 6, 0x022B0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F60[] = { {"gbreve", 6, 0x0011F, 0}, {"rsaquo", 6, 0x0203A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F62[] = { {"sung", 4, 0x0266A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F67[] = { {"lvertneqq", 9, 0x02268, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F68[] = { {"lnsim", 5, 0x022E6, 0}, {"searrow", 7, 0x02198, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F69[] = { {"nsubset", 7, 0x02282, 0x020D2}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F6D[] = { {"Cup", 3, 0x022D3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F6E[] = { {"Lmidot", 6, 0x0013F, 0}, {"sup1", 4, 0x000B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F6F[] = { {"Delta", 5, 0x00394, 0}, {"sbquo", 5, 0x0201A, 0}, {"sup2", 4, 0x000B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F70[] = { {"cscr", 4, 0x1D4B8, 0}, {"nsubseteqq", 10, 0x02AC5, 0x00338}, {"sup3", 4, 0x000B3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F71[] = { {"Kcedil", 6, 0x00136, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F72[] = { {"plussim", 7, 0x02A26, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F74[] = { {"KHcy", 4, 0x00425, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F75[] = { {"OElig", 5, 0x00152, 0}, {"simdot", 6, 0x02A6A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F76[] = { {"lopf", 4, 0x1D55D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F77[] = { {"boxbox", 6, 0x029C9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F78[] = { {"bepsi", 5, 0x003F6, 0}, {"lbarr", 5, 0x0290C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F79[] = { {"lnapprox", 8, 0x02A89, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F81[] = { {"sdotb", 5, 0x022A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F82[] = { {"measuredangle", 13, 0x02221, 0}, {"supE", 4, 0x02AC6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F83[] = { {"map", 3, 0x021A6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F84[] = { {"sdote", 5, 0x02A66, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F86[] = { {"diamondsuit", 11, 0x02666, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F88[] = { {"Kfr", 3, 0x1D50E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F8B[] = { {"imagline", 8, 0x02110, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F8F[] = { {"delta", 5, 0x003B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F91[] = { {"mapstodown", 10, 0x021A7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F93[] = { {"eqvparsl", 8, 0x029E5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F95[] = { {"UpArrow", 7, 0x02191, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F9A[] = { {"imagpart", 8, 0x02111, 0}, {"lsim", 4, 0x02272, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F9C[] = { {"trianglelefteq", 14, 0x022B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_F9F[] = { {"isindot", 7, 0x022F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FA0[] = { {"LeftUpDownVector", 16, 0x02951, 0}, {"curvearrowleft", 14, 0x021B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FA1[] = { {"Diamond", 7, 0x022C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FA2[] = { {"supe", 4, 0x02287, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FA3[] = { {"nearrow", 7, 0x02197, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FA9[] = { {"easter", 6, 0x02A6E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB0[] = { {"rdquo", 5, 0x0201D, 0}, {"subsetneqq", 10, 0x02ACB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB1[] = { {"Dscr", 4, 0x1D49F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB4[] = { {"comp", 4, 0x02201, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB5[] = { {"Uparrow", 7, 0x021D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB6[] = { {"coloneq", 7, 0x02254, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB7[] = { {"Mopf", 4, 0x1D544, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FB9[] = { {"rfloor", 6, 0x0230B, 0}, {"varsubsetneqq", 13, 0x02ACB, 0x0FE00}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FBC[] = { {"eacute", 6, 0x000E9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FC2[] = { {"shortparallel", 13, 0x02225, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FC4[] = { {"male", 4, 0x02642, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FC6[] = { {"yscr", 4, 0x1D4CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FCA[] = { {"xharr", 5, 0x027F7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FCC[] = { {"cong", 4, 0x02245, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FCE[] = { {"mcy", 3, 0x0043C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FCF[] = { {"Upsilon", 7, 0x003A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FD0[] = { {"block", 5, 0x02588, 0}, {"maltese", 7, 0x02720, 0}, {"ordf", 4, 0x000AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FD2[] = { {"zcaron", 6, 0x0017E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FD3[] = { {"malt", 4, 0x02720, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FD6[] = { {"loang", 5, 0x027EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FD7[] = { {"ordm", 4, 0x000BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FDD[] = { {"NegativeVeryThinSpace", 21, 0x0200B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FDF[] = { {"eta", 3, 0x003B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FE1[] = { {"Iogon", 5, 0x0012E, 0}, {"drbkarow", 8, 0x02910, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FE6[] = { {"eth", 3, 0x000F0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FE9[] = { {"racute", 6, 0x00155, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FEA[] = { {"cwconint", 8, 0x02232, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FEB[] = { {"egsdot", 6, 0x02A98, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FF5[] = { {"MinusPlus", 9, 0x02213, 0}, {"ring", 4, 0x002DA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FF8[] = { {"rcedil", 6, 0x00157, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FFC[] = { {"timesbar", 8, 0x02A31, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html5_FFE[] = { {"GreaterEqualLess", 16, 0x022DB, 0}, {NULL} }; +static const entity_cp_map ht_bucket_empty[] = { {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_000[] = { {"realpart", 8, 0x0211C, 0}, {"varr", 4, 0x02195, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_001[] = { {"angrt", 5, 0x0221F, 0}, {"iogon", 5, 0x0012F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_003[] = { {"lessdot", 7, 0x022D6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_005[] = { {"simrarr", 7, 0x02972, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_007[] = { {"Zscr", 4, 0x1D4B5, 0}, {"midast", 6, 0x0002A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_00D[] = { {"copf", 4, 0x1D554, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_00F[] = { {"female", 6, 0x02640, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_017[] = { {"NegativeThickSpace", 18, 0x0200B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_020[] = { {"copy", 4, 0x000A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_022[] = { {"angst", 5, 0x000C5, 0}, {"searr", 5, 0x02198, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_024[] = { {"sqcups", 6, 0x02294, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_027[] = { {"Acirc", 5, 0x000C2, 0}, {"gtdot", 5, 0x022D7, 0}, {"varpi", 5, 0x003D6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_028[] = { {"UpTee", 5, 0x022A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_029[] = { {"TildeTilde", 10, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_02A[] = { {"mfr", 3, 0x1D52A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_02B[] = { {"RightVectorBar", 14, 0x02953, 0}, {"gesdot", 6, 0x02A80, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_02C[] = { {"Uarrocir", 8, 0x02949, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_02E[] = { {"RightTriangleBar", 16, 0x029D0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_030[] = { {"Ocy", 3, 0x0041E, 0}, {"int", 3, 0x0222B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_034[] = { {"preccurlyeq", 11, 0x0227C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_038[] = { {"sccue", 5, 0x0227D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_040[] = { {"DoubleContourIntegral", 21, 0x0222F, 0}, {"nexist", 6, 0x02204, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_047[] = { {"acirc", 5, 0x000E2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_04C[] = { {"setmn", 5, 0x02216, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_04E[] = { {"Dopf", 4, 0x1D53B, 0}, {"LeftTee", 7, 0x022A3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_051[] = { {"SquareSuperset", 14, 0x02290, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_059[] = { {"udhar", 5, 0x0296E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_05D[] = { {"Equal", 5, 0x02A75, 0}, {"pscr", 4, 0x1D4C5, 0}, {"xvee", 4, 0x022C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_05F[] = { {"approx", 6, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_060[] = { {"HARDcy", 6, 0x0042A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_061[] = { {"nGg", 3, 0x022D9, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_063[] = { {"yopf", 4, 0x1D56A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_064[] = { {"prcue", 5, 0x0227C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_065[] = { {"loarr", 5, 0x021FD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_069[] = { {"mho", 3, 0x02127, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_06A[] = { {"otimesas", 8, 0x02A36, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_06D[] = { {"capcap", 6, 0x02A4B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_06E[] = { {"eplus", 5, 0x02A71, 0}, {"nGt", 3, 0x0226B, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_06F[] = { {"Bumpeq", 6, 0x0224E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_071[] = { {"submult", 7, 0x02AC1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_073[] = { {"subplus", 7, 0x02ABF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_074[] = { {"auml", 4, 0x000E4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_07A[] = { {"RightDoubleBracket", 18, 0x027E7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_07B[] = { {"varkappa", 8, 0x003F0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_07C[] = { {"plusdo", 6, 0x02214, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_07F[] = { {"mid", 3, 0x02223, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_082[] = { {"plusdu", 6, 0x02A25, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_084[] = { {"notniva", 7, 0x0220C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_085[] = { {"notnivb", 7, 0x022FE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_086[] = { {"notnivc", 7, 0x022FD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_088[] = { {"varepsilon", 10, 0x003F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_089[] = { {"nspar", 5, 0x02226, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_08C[] = { {"Ofr", 3, 0x1D512, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_08E[] = { {"Omega", 5, 0x003A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_090[] = { {"equals", 6, 0x0003D, 0}, {"harrcir", 7, 0x02948, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_094[] = { {"Succeeds", 8, 0x0227B, 0}, {"cupdot", 6, 0x0228D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_097[] = { {"lsqb", 4, 0x0005B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_09E[] = { {"Qscr", 4, 0x1D4AC, 0}, {"urcorn", 6, 0x0231D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0A4[] = { {"Zopf", 4, 0x02124, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0A6[] = { {"triangleleft", 12, 0x025C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0AB[] = { {"supdsub", 7, 0x02AD8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0AC[] = { {"chcy", 4, 0x00447, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0AD[] = { {"sqsupset", 8, 0x02290, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0AE[] = { {"omega", 5, 0x003C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0AF[] = { {"rthree", 6, 0x022CC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0B0[] = { {"THORN", 5, 0x000DE, 0}, {"clubsuit", 8, 0x02663, 0}, {"filig", 5, 0x0FB01, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0B2[] = { {"ocir", 4, 0x0229A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0B8[] = { {"ShortDownArrow", 14, 0x02193, 0}, {"atilde", 6, 0x000E3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0B9[] = { {"DownLeftTeeVector", 17, 0x0295E, 0}, {"LeftTeeArrow", 12, 0x021A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0BA[] = { {"GreaterFullEqual", 16, 0x02267, 0}, {"emsp", 4, 0x02003, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0C0[] = { {"lozf", 4, 0x029EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0C4[] = { {"ThinSpace", 9, 0x02009, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0CE[] = { {"fnof", 4, 0x00192, 0}, {"multimap", 8, 0x022B8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0D1[] = { {"Zacute", 6, 0x00179, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0D2[] = { {"mdash", 5, 0x02014, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0D3[] = { {"minusb", 6, 0x0229F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0D5[] = { {"minusd", 6, 0x02238, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0DF[] = { {"varsigma", 8, 0x003C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0E5[] = { {"ntilde", 6, 0x000F1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0E6[] = { {"Lambda", 6, 0x0039B, 0}, {"integers", 8, 0x02124, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0E8[] = { {"gesles", 6, 0x02A94, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0EC[] = { {"NotSubset", 9, 0x02282, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0EF[] = { {"NotLeftTriangleEqual", 20, 0x022EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0F3[] = { {"LessLess", 8, 0x02AA1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0F4[] = { {"gscr", 4, 0x0210A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0FA[] = { {"popf", 4, 0x1D561, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0FB[] = { {"Agrave", 6, 0x000C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0FD[] = { {"nvinfin", 7, 0x029DE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_0FE[] = { {"gacute", 6, 0x001F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_100[] = { {"diam", 4, 0x022C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_101[] = { {"nesim", 5, 0x02242, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_103[] = { {"YIcy", 4, 0x00407, 0}, {"bcy", 3, 0x00431, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_105[] = { {"Exists", 6, 0x02203, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_106[] = { {"vert", 4, 0x0007C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_109[] = { {"ropar", 5, 0x02986, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_10A[] = { {"topfork", 7, 0x02ADA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_10B[] = { {"nLl", 3, 0x022D8, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_10D[] = { {"notin", 5, 0x02209, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_10E[] = { {"SucceedsSlantEqual", 18, 0x0227D, 0}, {"toea", 4, 0x02928, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_10F[] = { {"ImaginaryI", 10, 0x02148, 0}, {"srarr", 5, 0x02192, 0}, {"ulcorner", 8, 0x0231C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_110[] = { {"LeftArrowBar", 12, 0x021E4, 0}, {"ldsh", 4, 0x021B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_111[] = { {"DownBreve", 9, 0x00311, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_113[] = { {"nLt", 3, 0x0226A, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_116[] = { {"vltri", 5, 0x022B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_11B[] = { {"VDash", 5, 0x022AB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_11C[] = { {"Dstrok", 6, 0x00110, 0}, {"Intersection", 12, 0x022C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_11E[] = { {"lrhar", 5, 0x021CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_121[] = { {"RightTee", 8, 0x022A2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_124[] = { {"RightArrowLeftArrow", 19, 0x021C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_129[] = { {"Ccirc", 5, 0x00108, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_12A[] = { {"ntrianglelefteq", 15, 0x022EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_12C[] = { {"leftharpoonup", 13, 0x021BC, 0}, {"scap", 4, 0x02AB8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_12E[] = { {"darr", 4, 0x02193, 0}, {"qfr", 3, 0x1D52E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_12F[] = { {"cdot", 4, 0x0010B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_130[] = { {"supseteqq", 9, 0x02AC6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_134[] = { {"Scy", 3, 0x00421, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_135[] = { {"Hscr", 4, 0x0210B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_137[] = { {"LowerRightArrow", 15, 0x02198, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_13A[] = { {"divide", 6, 0x000F7, 0}, {"tcedil", 6, 0x00163, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_13B[] = { {"LeftArrow", 9, 0x02190, 0}, {"Qopf", 4, 0x0211A, 0}, {"vDash", 5, 0x022A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_145[] = { {"dash", 4, 0x02010, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_147[] = { {"oror", 4, 0x02A56, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_149[] = { {"ccirc", 5, 0x00109, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_14B[] = { {"LongLeftArrow", 13, 0x027F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_14C[] = { {"straightphi", 11, 0x003D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_14E[] = { {"xlarr", 5, 0x027F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_14F[] = { {"DJcy", 4, 0x00402, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_158[] = { {"nbsp", 4, 0x000A0, 0}, {"succcurlyeq", 11, 0x0227D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_159[] = { {"njcy", 4, 0x0045A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_15B[] = { {"Leftarrow", 9, 0x021D0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_15E[] = { {"dtrif", 5, 0x025BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_15F[] = { {"bfr", 3, 0x1D51F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_161[] = { {"GreaterTilde", 12, 0x02273, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_164[] = { {"hamilt", 6, 0x0210B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_165[] = { {"Dcy", 3, 0x00414, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_168[] = { {"LeftUpVector", 12, 0x021BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_16A[] = { {"bigoplus", 8, 0x02A01, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_170[] = { {"nwarhk", 6, 0x02923, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_173[] = { {"diams", 5, 0x02666, 0}, {"suphsol", 7, 0x027C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_17A[] = { {"boxminus", 8, 0x0229F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_17B[] = { {"leftarrow", 9, 0x02190, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_17C[] = { {"andd", 4, 0x02A5C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_17F[] = { {"NonBreakingSpace", 16, 0x000A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_181[] = { {"xutri", 5, 0x025B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_189[] = { {"Longleftrightarrow", 18, 0x027FA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_18B[] = { {"Longleftarrow", 13, 0x027F8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_18C[] = { {"gtrapprox", 9, 0x02A86, 0}, {"phmmat", 6, 0x02133, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_18E[] = { {"andv", 4, 0x02A5A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_18F[] = { {"equiv", 5, 0x02261, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_190[] = { {"Sfr", 3, 0x1D516, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_191[] = { {"gopf", 4, 0x1D558, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_193[] = { {"sqsub", 5, 0x0228F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_195[] = { {"approxeq", 8, 0x0224A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_19A[] = { {"Del", 3, 0x02207, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_19C[] = { {"nrightarrow", 11, 0x0219B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_19F[] = { {"SquareUnion", 11, 0x02294, 0}, {"strns", 5, 0x000AF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A0[] = { {"Itilde", 6, 0x00128, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A1[] = { {"sqsup", 5, 0x02290, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A2[] = { {"Ouml", 4, 0x000D6, 0}, {"PrecedesTilde", 13, 0x0227E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A3[] = { {"AMP", 3, 0x00026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A4[] = { {"plusmn", 6, 0x000B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A5[] = { {"xcup", 4, 0x022C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1A8[] = { {"radic", 5, 0x0221A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1AB[] = { {"longleftarrow", 13, 0x027F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1AC[] = { {"lrcorner", 8, 0x0231F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1AD[] = { {"notni", 5, 0x0220C, 0}, {"updownarrow", 11, 0x02195, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1AE[] = { {"szlig", 5, 0x000DF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1AF[] = { {"ugrave", 6, 0x000F9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1B0[] = { {"imof", 4, 0x022B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1B2[] = { {"csub", 4, 0x02ACF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1B5[] = { {"gsim", 4, 0x02273, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1B9[] = { {"leftleftarrows", 14, 0x021C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1BD[] = { {"backcong", 8, 0x0224C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1BE[] = { {"clubs", 5, 0x02663, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1C0[] = { {"csup", 4, 0x02AD0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1C1[] = { {"Dfr", 3, 0x1D507, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1C4[] = { {"profline", 8, 0x02312, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1C6[] = { {"Zdot", 4, 0x0017B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1C9[] = { {"ClockwiseContourIntegral", 24, 0x02232, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1CA[] = { {"roplus", 6, 0x02A2E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1CD[] = { {"Rang", 4, 0x027EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1CE[] = { {"bcong", 5, 0x0224C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D0[] = { {"tshcy", 5, 0x0045B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D1[] = { {"eDot", 4, 0x02251, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D2[] = { {"Hopf", 4, 0x0210D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D4[] = { {"lpar", 4, 0x00028, 0}, {"odash", 5, 0x0229D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D5[] = { {"capbrcup", 8, 0x02A49, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D6[] = { {"ucy", 3, 0x00443, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D8[] = { {"ofcir", 5, 0x029BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1D9[] = { {"Breve", 5, 0x002D8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1DA[] = { {"barvee", 6, 0x022BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1DF[] = { {"backsim", 7, 0x0223D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1E0[] = { {"ange", 4, 0x029A4, 0}, {"half", 4, 0x000BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1E1[] = { {"tscr", 4, 0x1D4C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1E5[] = { {"realine", 7, 0x0211B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1E6[] = { {"Oacute", 6, 0x000D3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1E7[] = { {"dfisht", 6, 0x0297F, 0}, {"swnwar", 6, 0x0292A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1E8[] = { {"tscy", 4, 0x00446, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1EB[] = { {"lsquor", 6, 0x0201A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1EF[] = { {"naturals", 8, 0x02115, 0}, {"utrif", 5, 0x025B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1F0[] = { {"DiacriticalTilde", 16, 0x002DC, 0}, {"RightUpVectorBar", 16, 0x02954, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1F2[] = { {"rHar", 4, 0x02964, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1F4[] = { {"curlyeqprec", 11, 0x022DE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1F8[] = { {"dtri", 4, 0x025BF, 0}, {"euml", 4, 0x000EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1F9[] = { {"breve", 5, 0x002D8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1FA[] = { {"Barwed", 6, 0x02306, 0}, {"nvlArr", 6, 0x02902, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1FC[] = { {"dcaron", 6, 0x0010F, 0}, {"natural", 7, 0x0266E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1FE[] = { {"nsupseteqq", 10, 0x02AC6, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_1FF[] = { {"nedot", 5, 0x02250, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_205[] = { {"bigtriangledown", 15, 0x025BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_207[] = { {"fcy", 3, 0x00444, 0}, {"marker", 6, 0x025AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_20E[] = { {"Union", 5, 0x022C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_212[] = { {"varpropto", 9, 0x0221D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_213[] = { {"CloseCurlyDoubleQuote", 21, 0x0201D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_219[] = { {"DoubleLongRightArrow", 20, 0x027F9, 0}, {"GreaterGreater", 14, 0x02AA2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_21D[] = { {"Umacr", 5, 0x0016A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_220[] = { {"Colon", 5, 0x02237, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_222[] = { {"Hat", 3, 0x0005E, 0}, {"Uscr", 4, 0x1D4B0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_227[] = { {"SHCHcy", 6, 0x00429, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_229[] = { {"nLeftarrow", 10, 0x021CD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_22B[] = { {"Ecirc", 5, 0x000CA, 0}, {"Jukcy", 5, 0x00404, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_22C[] = { {"nbumpe", 6, 0x0224F, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_22D[] = { {"NotLess", 7, 0x0226E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_22F[] = { {"gtlPar", 6, 0x02995, 0}, {"suphsub", 7, 0x02AD7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_230[] = { {"gtreqqless", 10, 0x02A8C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_232[] = { {"ufr", 3, 0x1D532, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_234[] = { {"cirscir", 7, 0x029C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_239[] = { {"LeftDownTeeVector", 17, 0x02961, 0}, {"duhar", 5, 0x0296F, 0}, {"nrtrie", 6, 0x022ED, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_23C[] = { {"llhard", 6, 0x0296B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_23D[] = { {"umacr", 5, 0x0016B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_23E[] = { {"lates", 5, 0x02AAD, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_240[] = { {"colon", 5, 0x0003A, 0}, {"iacute", 6, 0x000ED, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_241[] = { {"NotPrecedes", 11, 0x02280, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_242[] = { {"cirfnint", 8, 0x02A10, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_246[] = { {"barwedge", 8, 0x02305, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_249[] = { {"nleftarrow", 10, 0x0219A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_24A[] = { {"Ubrcy", 5, 0x0040E, 0}, {"leftthreetimes", 14, 0x022CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_24B[] = { {"andand", 6, 0x02A55, 0}, {"ecirc", 5, 0x000EA, 0}, {"jukcy", 5, 0x00454, 0}, {"quatint", 7, 0x02A16, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_24D[] = { {"lharul", 6, 0x0296A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_251[] = { {"smtes", 5, 0x02AAC, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_252[] = { {"UnionPlus", 9, 0x0228E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_257[] = { {"NotLeftTriangle", 15, 0x022EA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_25A[] = { {"bne", 3, 0x0003D, 0x020E5}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_25B[] = { {"gtrsim", 6, 0x02273, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_25C[] = { {"Rarr", 4, 0x021A0, 0}, {"ldquor", 6, 0x0201E, 0}, {"phiv", 4, 0x003D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_25D[] = { {"because", 7, 0x02235, 0}, {"gEl", 3, 0x02A8C, 0}, {"setminus", 8, 0x02216, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_263[] = { {"ffr", 3, 0x1D523, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_26A[] = { {"ubrcy", 5, 0x0045E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_26B[] = { {"elinters", 8, 0x023E7, 0}, {"plusb", 5, 0x0229E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_26E[] = { {"pluse", 5, 0x02A72, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_274[] = { {"CapitalDifferentialD", 20, 0x02145, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_277[] = { {"daleth", 6, 0x02138, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_278[] = { {"kscr", 4, 0x1D4C0, 0}, {"ogon", 4, 0x002DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_27C[] = { {"SHcy", 4, 0x00428, 0}, {"equest", 6, 0x0225F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_27E[] = { {"rbarr", 5, 0x0290D, 0}, {"topf", 4, 0x1D565, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_283[] = { {"tritime", 7, 0x02A3B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_28A[] = { {"bot", 3, 0x022A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_294[] = { {"Wfr", 3, 0x1D51A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_297[] = { {"HumpEqual", 9, 0x0224F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_298[] = { {"rightleftharpoons", 17, 0x021CC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_29D[] = { {"frasl", 5, 0x02044, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_29F[] = { {"UnderBracket", 12, 0x023B5, 0}, {"ovbar", 5, 0x0233D, 0}, {"upharpoonright", 14, 0x021BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2A0[] = { {"euro", 4, 0x020AC, 0}, {"nhArr", 5, 0x021CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2A9[] = { {"NotSupersetEqual", 16, 0x02289, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2AE[] = { {"cularr", 6, 0x021B6, 0}, {"scnE", 4, 0x02AB6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2B1[] = { {"napid", 5, 0x0224B, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2B2[] = { {"harr", 4, 0x02194, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2B3[] = { {"gdot", 4, 0x00121, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2B9[] = { {"Lscr", 4, 0x02112, 0}, {"zeta", 4, 0x003B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2BF[] = { {"ENG", 3, 0x0014A, 0}, {"Uopf", 4, 0x1D54C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2C4[] = { {"esdot", 5, 0x02250, 0}, {"scsim", 5, 0x0227F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2C5[] = { {"Hfr", 3, 0x0210C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2CE[] = { {"RightArrow", 10, 0x02192, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2CF[] = { {"Sqrt", 4, 0x0221A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2D3[] = { {"xodot", 5, 0x02A00, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2DA[] = { {"ycy", 3, 0x0044B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2DB[] = { {"hkswarow", 8, 0x02926, 0}, {"urtri", 5, 0x025F9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2DC[] = { {"roang", 5, 0x027ED, 0}, {"tosa", 4, 0x02929, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2E3[] = { {"CircleMinus", 11, 0x02296, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2E4[] = { {"Lcaron", 6, 0x0013D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2EB[] = { {"ShortLeftArrow", 14, 0x02190, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2EC[] = { {"Dot", 3, 0x000A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2EE[] = { {"Rightarrow", 10, 0x021D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2F0[] = { {"prsim", 5, 0x0227E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2F2[] = { {"notinE", 6, 0x022F9, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_2F8[] = { {"becaus", 6, 0x02235, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_300[] = { {"NotEqualTilde", 13, 0x02242, 0x00338}, {"nparallel", 9, 0x02226, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_301[] = { {"capcup", 6, 0x02A47, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_304[] = { {"simeq", 5, 0x02243, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_305[] = { {"forall", 6, 0x02200, 0}, {"straightepsilon", 15, 0x003F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_308[] = { {"ruluhar", 7, 0x02968, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_30B[] = { {"jcy", 3, 0x00439, 0}, {"ltcc", 4, 0x02AA6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_30F[] = { {"bscr", 4, 0x1D4B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_311[] = { {"ExponentialE", 12, 0x02147, 0}, {"weierp", 6, 0x02118, 0}, {"yen", 3, 0x000A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_313[] = { {"blacksquare", 11, 0x025AA, 0}, {"uml", 3, 0x000A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_315[] = { {"backsimeq", 9, 0x022CD, 0}, {"kopf", 4, 0x1D55C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_319[] = { {"NotPrecedesEqual", 16, 0x02AAF, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_31A[] = { {"simgE", 5, 0x02AA0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_31B[] = { {"tridot", 6, 0x025EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_326[] = { {"DoubleLongLeftArrow", 19, 0x027F8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_329[] = { {"models", 6, 0x022A7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_32A[] = { {"emptyv", 6, 0x02205, 0}, {"eqslantgtr", 10, 0x02A96, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_32D[] = { {"Gcirc", 5, 0x0011C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_330[] = { {"bernou", 6, 0x0212C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_331[] = { {"HumpDownHump", 12, 0x0224E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_336[] = { {"yfr", 3, 0x1D536, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_338[] = { {"blacktriangle", 13, 0x025B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_33B[] = { {"yacy", 4, 0x0044F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_33F[] = { {"lsime", 5, 0x02A8D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_340[] = { {"NotTildeEqual", 13, 0x02244, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_341[] = { {"lsimg", 5, 0x02A8F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_347[] = { {"ncap", 4, 0x02A43, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_34D[] = { {"DD", 2, 0x02145, 0}, {"gcirc", 5, 0x0011D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_350[] = { {"Cscr", 4, 0x1D49E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_356[] = { {"Lopf", 4, 0x1D543, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_358[] = { {"lBarr", 5, 0x0290E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_359[] = { {"Leftrightarrow", 14, 0x021D4, 0}, {"gtrdot", 6, 0x022D7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_35D[] = { {"NotSquareSubset", 15, 0x0228F, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_35F[] = { {"sqsubset", 8, 0x0228F, 0}, {"subsetneq", 9, 0x0228A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_361[] = { {"doublebarwedge", 14, 0x02306, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_363[] = { {"blacktriangleleft", 17, 0x025C2, 0}, {"hellip", 6, 0x02026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_365[] = { {"xscr", 4, 0x1D4CD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_367[] = { {"LessFullEqual", 13, 0x02266, 0}, {"jfr", 3, 0x1D527, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_369[] = { {"GreaterSlantEqual", 17, 0x02A7E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_36A[] = { {"Uring", 5, 0x0016E, 0}, {"VeryThinSpace", 13, 0x0200A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_36B[] = { {"roarr", 5, 0x021FE, 0}, {"scaron", 6, 0x00161, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_36D[] = { {"Lcy", 3, 0x0041B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_36E[] = { {"RightDownVector", 15, 0x021C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_36F[] = { {"Sub", 3, 0x022D0, 0}, {"pitchfork", 9, 0x022D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_372[] = { {"nvsim", 5, 0x0223C, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_374[] = { {"xrArr", 5, 0x027F9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_378[] = { {"CloseCurlyQuote", 15, 0x02019, 0}, {"uwangle", 7, 0x029A7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_37A[] = { {"Sum", 3, 0x02211, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_37C[] = { {"iuml", 4, 0x000EF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_37D[] = { {"Sup", 3, 0x022D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_37E[] = { {"planck", 6, 0x0210F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_37F[] = { {"Egrave", 6, 0x000C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_380[] = { {"curlywedge", 10, 0x022CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_382[] = { {"TildeFullEqual", 14, 0x02245, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_383[] = { {"searhk", 6, 0x02925, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_386[] = { {"ETH", 3, 0x000D0, 0}, {"napos", 5, 0x00149, 0}, {"upsi", 4, 0x003C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_387[] = { {"twoheadleftarrow", 16, 0x0219E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_38A[] = { {"Assign", 6, 0x02254, 0}, {"uring", 5, 0x0016F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_38D[] = { {"SquareIntersection", 18, 0x02293, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_38E[] = { {"lmidot", 6, 0x00140, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_391[] = { {"kcedil", 6, 0x00137, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_394[] = { {"curren", 6, 0x000A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_397[] = { {"acute", 5, 0x000B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_398[] = { {"curlyeqsucc", 11, 0x022DF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_39C[] = { {"Omicron", 7, 0x0039F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_39F[] = { {"uarr", 4, 0x02191, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3A0[] = { {"Hstrok", 6, 0x00126, 0}, {"UnderBrace", 10, 0x023DF, 0}, {"tdot", 4, 0x020DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3A1[] = { {"qint", 4, 0x02A0C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3A4[] = { {"sfrown", 6, 0x02322, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3A5[] = { {"trpezium", 8, 0x023E2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3A6[] = { {"Yscr", 4, 0x1D4B4, 0}, {"cedil", 5, 0x000B8, 0}, {"planckh", 7, 0x0210E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3A7[] = { {"lang", 4, 0x027E8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3AC[] = { {"bopf", 4, 0x1D553, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3B2[] = { {"lbbrk", 5, 0x02772, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3B4[] = { {"khcy", 4, 0x00445, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3BF[] = { {"Epsilon", 7, 0x00395, 0}, {"simlE", 5, 0x02A9F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3C0[] = { {"GT", 2, 0x0003E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3C4[] = { {"nap", 3, 0x02249, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3C9[] = { {"Lfr", 3, 0x1D50F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3CD[] = { {"succapprox", 10, 0x02AB8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3D0[] = { {"bsim", 4, 0x0223D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3D3[] = { {"Gg", 2, 0x022D9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3D9[] = { {"angrtvb", 7, 0x022BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3DE[] = { {"xcirc", 5, 0x025EF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3E0[] = { {"Gt", 2, 0x0226B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3E1[] = { {"LeftRightVector", 15, 0x0294E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3E3[] = { {"circledast", 10, 0x0229B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3E4[] = { {"telrec", 6, 0x02315, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3E6[] = { {"SucceedsTilde", 13, 0x0227F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3E9[] = { {"nLtv", 4, 0x0226A, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3ED[] = { {"Copf", 4, 0x02102, 0}, {"napprox", 7, 0x02249, 0}, {"nsupseteq", 9, 0x02289, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3F1[] = { {"VerticalTilde", 13, 0x02240, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3F2[] = { {"parallel", 8, 0x02225, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3F7[] = { {"precnapprox", 11, 0x02AB9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3FC[] = { {"oscr", 4, 0x02134, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_3FE[] = { {"supsetneqq", 10, 0x02ACC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_402[] = { {"xopf", 4, 0x1D569, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_405[] = { {"mumap", 5, 0x022B8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_407[] = { {"varsupsetneqq", 13, 0x02ACC, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_409[] = { {"ReverseEquilibrium", 18, 0x021CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_40E[] = { {"Ubreve", 6, 0x0016C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_40F[] = { {"YUcy", 4, 0x0042E, 0}, {"ncy", 3, 0x0043D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_413[] = { {"ltimes", 6, 0x022C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_41A[] = { {"UpperRightArrow", 15, 0x02197, 0}, {"nvap", 4, 0x0224D, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_41B[] = { {"Im", 2, 0x02111, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_421[] = { {"simne", 5, 0x02246, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_423[] = { {"ccups", 5, 0x02A4C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_424[] = { {"nlArr", 5, 0x021CD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_425[] = { {"rarrsim", 7, 0x02974, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_426[] = { {"Ncaron", 6, 0x00147, 0}, {"vsupnE", 6, 0x02ACC, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_429[] = { {"succeq", 6, 0x02AB0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_42C[] = { {"Gammad", 6, 0x003DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_42F[] = { {"Icirc", 5, 0x000CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_430[] = { {"backepsilon", 11, 0x003F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_432[] = { {"ddarr", 5, 0x021CA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_436[] = { {"larr", 4, 0x02190, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_439[] = { {"divideontimes", 13, 0x022C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_43C[] = { {"succsim", 7, 0x0227F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_43D[] = { {"Pscr", 4, 0x1D4AB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_43E[] = { {"puncsp", 6, 0x02008, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_43F[] = { {"gtreqless", 9, 0x022DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_440[] = { {"intcal", 6, 0x022BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_441[] = { {"nsime", 5, 0x02244, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_443[] = { {"Yopf", 4, 0x1D550, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_446[] = { {"angsph", 6, 0x02222, 0}, {"vsupne", 6, 0x0228B, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_447[] = { {"NotNestedLessLess", 17, 0x02AA1, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_44A[] = { {"PrecedesSlantEqual", 18, 0x0227C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_44F[] = { {"icirc", 5, 0x000EE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_450[] = { {"DownLeftVectorBar", 17, 0x02956, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_454[] = { {"Auml", 4, 0x000C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_457[] = { {"LJcy", 4, 0x00409, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_458[] = { {"sqsube", 6, 0x02291, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_45D[] = { {"nprec", 5, 0x02280, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_45F[] = { {"ngE", 3, 0x02267, 0x00338}, {"smile", 5, 0x02323, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_465[] = { {"LT", 2, 0x0003C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_466[] = { {"ldrdhar", 7, 0x02967, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_469[] = { {"utri", 4, 0x025B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_46A[] = { {"Sacute", 6, 0x0015A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_46B[] = { {"late", 4, 0x02AAD, 0}, {"nfr", 3, 0x1D52B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_46D[] = { {"NotNestedGreaterGreater", 23, 0x02AA2, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_46F[] = { {"nwarr", 5, 0x02196, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_470[] = { {"biguplus", 8, 0x02A04, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_471[] = { {"Pcy", 3, 0x0041F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_472[] = { {"bigtriangleup", 13, 0x025B3, 0}, {"rationals", 9, 0x0211A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_473[] = { {"congdot", 7, 0x02A6D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_475[] = { {"PlusMinus", 9, 0x000B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_479[] = { {"IOcy", 4, 0x00401, 0}, {"Scedil", 6, 0x0015E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_47C[] = { {"eqcirc", 6, 0x02256, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_47D[] = { {"Ll", 2, 0x022D8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_47F[] = { {"Cayleys", 7, 0x0212D, 0}, {"nge", 3, 0x02271, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_480[] = { {"NotGreater", 10, 0x0226F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_485[] = { {"Lt", 2, 0x0226A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_488[] = { {"rotimes", 7, 0x02A35, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_48C[] = { {"caps", 4, 0x02229, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_48E[] = { {"ngt", 3, 0x0226F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_48F[] = { {"Cross", 5, 0x02A2F, 0}, {"bumpeq", 6, 0x0224F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_490[] = { {"VerticalSeparator", 17, 0x02758, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_491[] = { {"plankv", 6, 0x0210F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_493[] = { {"fscr", 4, 0x1D4BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_495[] = { {"bsol", 4, 0x0005C, 0}, {"sqsubseteq", 10, 0x02291, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_496[] = { {"boxH", 4, 0x02550, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_498[] = { {"rightarrowtail", 14, 0x021A3, 0}, {"ufisht", 6, 0x0297E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_499[] = { {"oopf", 4, 0x1D560, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_49F[] = { {"lobrk", 5, 0x027E6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4A2[] = { {"Acy", 3, 0x00410, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4A4[] = { {"NotSubsetEqual", 14, 0x02288, 0}, {"boxV", 4, 0x02551, 0}, {"dHar", 4, 0x02965, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4A6[] = { {"precnsim", 8, 0x022E8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4A7[] = { {"Mu", 2, 0x0039C, 0}, {"aelig", 5, 0x000E6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4AA[] = { {"gescc", 5, 0x02AA9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4AB[] = { {"origof", 6, 0x022B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4AE[] = { {"upsih", 5, 0x003D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4AF[] = { {"cross", 5, 0x02717, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4B2[] = { {"LeftFloor", 9, 0x0230A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4B6[] = { {"boxh", 4, 0x02500, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4B8[] = { {"NotGreaterEqual", 15, 0x02271, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4BC[] = { {"profalar", 8, 0x0232E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4C0[] = { {"nsmid", 5, 0x02224, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4C2[] = { {"hbar", 4, 0x0210F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4C3[] = { {"udarr", 5, 0x021C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4C4[] = { {"boxv", 4, 0x02502, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4C5[] = { {"olarr", 5, 0x021BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4C8[] = { {"Nu", 2, 0x0039D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4CB[] = { {"NotCongruent", 12, 0x02262, 0}, {"bkarow", 6, 0x0290D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4CD[] = { {"Pfr", 3, 0x1D513, 0}, {"forkv", 5, 0x02AD9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4CF[] = { {"nis", 3, 0x022FC, 0}, {"trianglerighteq", 15, 0x022B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4D0[] = { {"ngeq", 4, 0x02271, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4D2[] = { {"cudarrl", 7, 0x02938, 0}, {"nges", 4, 0x02A7E, 0x00338}, {"niv", 3, 0x0220B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4D3[] = { {"SubsetEqual", 11, 0x02286, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4D4[] = { {"Gscr", 4, 0x1D4A2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4D5[] = { {"complexes", 9, 0x02102, 0}, {"eDDot", 5, 0x02A77, 0}, {"nvge", 4, 0x02265, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4D8[] = { {"cudarrr", 7, 0x02935, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4DA[] = { {"Popf", 4, 0x02119, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4DE[] = { {"LongRightArrow", 14, 0x027F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4DF[] = { {"supseteq", 8, 0x02287, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4E3[] = { {"dollar", 6, 0x00024, 0}, {"gnsim", 5, 0x022E7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4E4[] = { {"nvgt", 4, 0x0003E, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4E6[] = { {"Or", 2, 0x02A54, 0}, {"Vert", 4, 0x02016, 0}, {"lneqq", 5, 0x02268, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4E7[] = { {"nLeftrightarrow", 15, 0x021CE, 0}, {"nbump", 5, 0x0224E, 0x00338}, {"ntriangleright", 14, 0x022EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4E8[] = { {"ecir", 4, 0x02256, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4E9[] = { {"npolint", 7, 0x02A14, 0}, {"plus", 4, 0x0002B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4ED[] = { {"centerdot", 9, 0x000B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4F1[] = { {"zacute", 6, 0x0017A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4F7[] = { {"odiv", 4, 0x02A38, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4F9[] = { {"cap", 3, 0x02229, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4FB[] = { {"ensp", 4, 0x02002, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_4FE[] = { {"Afr", 3, 0x1D504, 0}, {"Pi", 2, 0x003A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_500[] = { {"iquest", 6, 0x000BF, 0}, {"ltri", 4, 0x025C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_504[] = { {"nlE", 3, 0x02266, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_506[] = { {"Phi", 3, 0x003A6, 0}, {"lambda", 6, 0x003BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_507[] = { {"Pr", 2, 0x02ABB, 0}, {"Vdashl", 6, 0x02AE6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_509[] = { {"SuchThat", 8, 0x0220B, 0}, {"Supset", 6, 0x022D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_50E[] = { {"Darr", 4, 0x021A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_50F[] = { {"Cdot", 4, 0x0010A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_513[] = { {"rcy", 3, 0x00440, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_516[] = { {"orderof", 7, 0x02134, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_518[] = { {"leqq", 4, 0x02266, 0}, {"precsim", 7, 0x0227E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_519[] = { {"RightTriangle", 13, 0x022B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_51B[] = { {"agrave", 6, 0x000E0, 0}, {"succnapprox", 11, 0x02ABA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_51C[] = { {"Tab", 3, 0x00009, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_524[] = { {"nle", 3, 0x02270, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_525[] = { {"spades", 6, 0x02660, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_526[] = { {"gtcc", 4, 0x02AA7, 0}, {"llcorner", 8, 0x0231E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_52F[] = { {"Oslash", 6, 0x000D8, 0}, {"Tau", 3, 0x003A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_530[] = { {"fopf", 4, 0x1D557, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_532[] = { {"Mellintrf", 9, 0x02133, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_533[] = { {"nlt", 3, 0x0226E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_534[] = { {"lparlt", 6, 0x02993, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_53B[] = { {"Ccaron", 6, 0x0010C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_53C[] = { {"Re", 2, 0x0211C, 0}, {"dstrok", 6, 0x00111, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_53F[] = { {"leftharpoondown", 15, 0x021BD, 0}, {"ssetmn", 6, 0x02216, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_542[] = { {"lrhard", 6, 0x0296D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_543[] = { {"reg", 3, 0x000AE, 0}, {"sharp", 5, 0x0266F, 0}, {"yicy", 4, 0x00457, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_545[] = { {"ShortUpArrow", 12, 0x02191, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_548[] = { {"plusacir", 8, 0x02A23, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_54F[] = { {"cent", 4, 0x000A2, 0}, {"natur", 5, 0x0266E, 0}, {"varphi", 6, 0x003D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_550[] = { {"lesg", 4, 0x022DA, 0x0FE00}, {"supnE", 5, 0x02ACC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_551[] = { {"ohbar", 5, 0x029B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_557[] = { {"NotLessGreater", 14, 0x02278, 0}, {"nleqslant", 9, 0x02A7D, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_55B[] = { {"Sc", 2, 0x02ABC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_55D[] = { {"NotSucceedsEqual", 16, 0x02AB0, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_55F[] = { {"DZcy", 4, 0x0040F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_564[] = { {"vartheta", 8, 0x003D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_565[] = { {"ltrie", 5, 0x022B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_566[] = { {"Otilde", 6, 0x000D5, 0}, {"ltrif", 5, 0x025C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_56C[] = { {"Lsh", 3, 0x021B0, 0}, {"hookleftarrow", 13, 0x021A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_56F[] = { {"rfr", 3, 0x1D52F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_570[] = { {"supne", 5, 0x0228B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_571[] = { {"Gopf", 4, 0x1D53E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_572[] = { {"UpEquilibrium", 13, 0x0296E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_575[] = { {"Tcy", 3, 0x00422, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_576[] = { {"ffilig", 6, 0x0FB03, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_577[] = { {"fork", 4, 0x022D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_578[] = { {"oplus", 5, 0x02295, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_57A[] = { {"nvle", 4, 0x02264, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_57B[] = { {"HilbertSpace", 12, 0x0210B, 0}, {"subedot", 7, 0x02AC3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_57C[] = { {"TripleDot", 9, 0x020DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_580[] = { {"sscr", 4, 0x1D4C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_582[] = { {"osol", 4, 0x02298, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_583[] = { {"plustwo", 7, 0x02A27, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_586[] = { {"LessGreater", 11, 0x02276, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_588[] = { {"lrarr", 5, 0x021C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_589[] = { {"nvlt", 4, 0x0003C, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_58D[] = { {"questeq", 7, 0x0225F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_58E[] = { {"LessTilde", 9, 0x02272, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_58F[] = { {"djcy", 4, 0x00452, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_590[] = { {"xoplus", 6, 0x02A01, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_595[] = { {"primes", 6, 0x02119, 0}, {"solb", 4, 0x029C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_596[] = { {"not", 3, 0x000AC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_59A[] = { {"angzarr", 7, 0x0237C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_59D[] = { {"nearr", 5, 0x02197, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_59F[] = { {"lowast", 6, 0x02217, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5A0[] = { {"cfr", 3, 0x1D520, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5A3[] = { {"ltcir", 5, 0x02A79, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5A6[] = { {"Ecy", 3, 0x0042D, 0}, {"gesdotol", 8, 0x02A84, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5A9[] = { {"longleftrightarrow", 18, 0x027F7, 0}, {"para", 4, 0x000B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5AC[] = { {"Uacute", 6, 0x000DA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5AD[] = { {"blank", 5, 0x02423, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5AE[] = { {"rho", 3, 0x003C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5B0[] = { {"dharl", 5, 0x021C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5B1[] = { {"rsquor", 6, 0x02019, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5B5[] = { {"NotSquareSubsetEqual", 20, 0x022E2, 0}, {"npr", 3, 0x02280, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5B6[] = { {"dharr", 5, 0x021C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5B7[] = { {"NewLine", 7, 0x0000A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5BB[] = { {"odot", 4, 0x02299, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5BC[] = { {"part", 4, 0x02202, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5BD[] = { {"cuvee", 5, 0x022CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5BF[] = { {"lesdoto", 7, 0x02A81, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5C0[] = { {"itilde", 6, 0x00129, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5C1[] = { {"Tscr", 4, 0x1D4AF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5C2[] = { {"nsubE", 5, 0x02AC5, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5C4[] = { {"ratio", 5, 0x02236, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5D0[] = { {"Conint", 6, 0x0222F, 0}, {"LeftDownVectorBar", 17, 0x02959, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5D1[] = { {"Tfr", 3, 0x1D517, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5D3[] = { {"fllig", 5, 0x0FB02, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5D5[] = { {"thksim", 6, 0x0223C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5D8[] = { {"Euml", 4, 0x000CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5D9[] = { {"chi", 3, 0x003C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5DB[] = { {"ncup", 4, 0x02A42, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5DD[] = { {"SOFTcy", 6, 0x0042C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5DF[] = { {"bnequiv", 7, 0x02261, 0x020E5}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5E2[] = { {"nsube", 5, 0x02288, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5E4[] = { {"mapstoleft", 10, 0x021A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5E7[] = { {"NotLessSlantEqual", 17, 0x02A7D, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5EA[] = { {"ldrushar", 8, 0x0294B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5ED[] = { {"Equilibrium", 11, 0x021CC, 0}, {"Uogon", 5, 0x00172, 0}, {"supsetneq", 9, 0x0228B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5F0[] = { {"Vbar", 4, 0x02AEB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5F3[] = { {"vnsub", 5, 0x02282, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5F6[] = { {"Square", 6, 0x025A1, 0}, {"lessapprox", 10, 0x02A85, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5F8[] = { {"And", 3, 0x02A53, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5FA[] = { {"gesdoto", 7, 0x02A82, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_5FD[] = { {"gap", 3, 0x02A86, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_601[] = { {"nsucc", 5, 0x02281, 0}, {"thicksim", 8, 0x0223C, 0}, {"vnsup", 5, 0x02283, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_602[] = { {"Efr", 3, 0x1D508, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_603[] = { {"Igrave", 6, 0x000CC, 0}, {"cir", 3, 0x025CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_606[] = { {"Xi", 2, 0x0039E, 0}, {"oacute", 6, 0x000F3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_609[] = { {"nsc", 3, 0x02281, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_60D[] = { {"uogon", 5, 0x00173, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_613[] = { {"rharul", 6, 0x0296C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_615[] = { {"RuleDelayed", 11, 0x029F4, 0}, {"apacir", 6, 0x02A6F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_617[] = { {"jscr", 4, 0x1D4BF, 0}, {"vcy", 3, 0x00432, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_61A[] = { {"barwed", 6, 0x02305, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_61D[] = { {"sopf", 4, 0x1D564, 0}, {"thkap", 5, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_61F[] = { {"lesseqgtr", 9, 0x022DA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_622[] = { {"rdquor", 6, 0x0201D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_624[] = { {"Lstrok", 6, 0x00141, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_626[] = { {"Product", 7, 0x0220F, 0}, {"sqsupe", 6, 0x02292, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_628[] = { {"awconint", 8, 0x02233, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_62C[] = { {"hearts", 6, 0x02665, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_630[] = { {"rlm", 3, 0x0200F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_632[] = { {"comma", 5, 0x0002C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_636[] = { {"PartialD", 8, 0x02202, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_63A[] = { {"wedbar", 6, 0x02A5F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_63C[] = { {"oline", 5, 0x0203E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_63D[] = { {"OverBracket", 11, 0x023B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_63E[] = { {"RBarr", 5, 0x02910, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_641[] = { {"uharl", 5, 0x021BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_642[] = { {"leftrightsquigarrow", 19, 0x021AD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_645[] = { {"RightFloor", 10, 0x0230B, 0}, {"intprod", 7, 0x02A3C, 0}, {"vee", 3, 0x02228, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_646[] = { {"zigrarr", 7, 0x021DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_647[] = { {"uharr", 5, 0x021BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_648[] = { {"gcy", 3, 0x00433, 0}, {"varsubsetneq", 12, 0x0228A, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_649[] = { {"leqslant", 8, 0x02A7D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_64A[] = { {"Odblac", 6, 0x00150, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_651[] = { {"minus", 5, 0x02212, 0}, {"scpolint", 8, 0x02A13, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_652[] = { {"lrtri", 5, 0x022BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_653[] = { {"DiacriticalGrave", 16, 0x00060, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_655[] = { {"num", 3, 0x00023, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_657[] = { {"quest", 5, 0x0003F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_658[] = { {"Kscr", 4, 0x1D4A6, 0}, {"UnderBar", 8, 0x0005F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_659[] = { {"lsquo", 5, 0x02018, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_65C[] = { {"rArr", 4, 0x021D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_65E[] = { {"Topf", 4, 0x1D54B, 0}, {"heartsuit", 9, 0x02665, 0}, {"rBarr", 5, 0x0290F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_660[] = { {"emptyset", 8, 0x02205, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_669[] = { {"UnderParenthesis", 16, 0x023DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_670[] = { {"dotplus", 7, 0x02214, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_671[] = { {"Psi", 3, 0x003A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_672[] = { {"GJcy", 4, 0x00403, 0}, {"exist", 5, 0x02203, 0}, {"simplus", 7, 0x02A24, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_673[] = { {"vfr", 3, 0x1D533, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_676[] = { {"tprime", 6, 0x02034, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_678[] = { {"leftrightharpoons", 17, 0x021CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_679[] = { {"rbrksld", 7, 0x0298E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_67D[] = { {"Ecaron", 6, 0x0011A, 0}, {"gel", 3, 0x022DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_680[] = { {"capdot", 6, 0x02A40, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_682[] = { {"geq", 3, 0x02265, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_684[] = { {"LowerLeftArrow", 14, 0x02199, 0}, {"ges", 3, 0x02A7E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_685[] = { {"Colone", 6, 0x02A74, 0}, {"NotLessEqual", 12, 0x02270, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_68A[] = { {"nrarr", 5, 0x0219B, 0}, {"rbrkslu", 7, 0x02990, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_68C[] = { {"flat", 4, 0x0266D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_691[] = { {"there4", 6, 0x02234, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_693[] = { {"Gdot", 4, 0x00120, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_694[] = { {"ijlig", 5, 0x00133, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_696[] = { {"blacklozenge", 12, 0x029EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_699[] = { {"Zeta", 4, 0x00396, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6A3[] = { {"duarr", 5, 0x021F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6A4[] = { {"DotEqual", 8, 0x02250, 0}, {"dtdot", 5, 0x022F1, 0}, {"gfr", 3, 0x1D524, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6A8[] = { {"cirE", 4, 0x029C3, 0}, {"period", 6, 0x0002E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6A9[] = { {"lmoust", 6, 0x023B0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6AA[] = { {"Icy", 3, 0x00418, 0}, {"Rcaron", 6, 0x00158, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6AB[] = { {"LeftCeiling", 11, 0x02308, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6AE[] = { {"ascr", 4, 0x1D4B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6B0[] = { {"boxtimes", 8, 0x022A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6B4[] = { {"jopf", 4, 0x1D55B, 0}, {"ntriangleleft", 13, 0x022EA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6B6[] = { {"eqcolon", 7, 0x02255, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6B8[] = { {"rbbrk", 5, 0x02773, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6B9[] = { {"homtht", 6, 0x0223B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6BA[] = { {"ggg", 3, 0x022D9, 0}, {"seswar", 6, 0x02929, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6BC[] = { {"perp", 4, 0x022A5, 0}, {"shcy", 4, 0x00448, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6BF[] = { {"phone", 5, 0x0260E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C0[] = { {"NotDoubleVerticalBar", 20, 0x02226, 0}, {"ngtr", 4, 0x0226F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C4[] = { {"ThickSpace", 10, 0x0205F, 0x0200A}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C5[] = { {"ForAll", 6, 0x02200, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C6[] = { {"circ", 4, 0x002C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C7[] = { {"Verbar", 6, 0x02016, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C8[] = { {"cire", 4, 0x02257, 0}, {"lesges", 6, 0x02A93, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6C9[] = { {"slarr", 5, 0x02190, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6CC[] = { {"RightDownTeeVector", 18, 0x0295D, 0}, {"triangleq", 9, 0x0225C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6CE[] = { {"checkmark", 9, 0x02713, 0}, {"quot", 4, 0x00022, 0}, {"suplarr", 7, 0x0297B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6D1[] = { {"Backslash", 9, 0x02216, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6D2[] = { {"fallingdotseq", 13, 0x02252, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6D4[] = { {"swArr", 5, 0x021D9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6D5[] = { {"Xfr", 3, 0x1D51B, 0}, {"lbrke", 5, 0x0298B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6D9[] = { {"jmath", 5, 0x00237, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6DA[] = { {"lmoustache", 10, 0x023B0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6DB[] = { {"DownTee", 7, 0x022A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6DC[] = { {"reals", 5, 0x0211D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6DE[] = { {"quaternions", 11, 0x0210D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6E7[] = { {"vzigzag", 7, 0x0299A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6EB[] = { {"pound", 5, 0x000A3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6EE[] = { {"permil", 6, 0x02030, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6EF[] = { {"Bscr", 4, 0x0212C, 0}, {"lfisht", 6, 0x0297C, 0}, {"vartriangleleft", 15, 0x022B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6F5[] = { {"Kopf", 4, 0x1D542, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6F7[] = { {"Tilde", 5, 0x0223C, 0}, {"gtrarr", 6, 0x02978, 0}, {"lAarr", 5, 0x021DA, 0}, {"opar", 4, 0x029B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_6FB[] = { {"triangle", 8, 0x025B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_704[] = { {"lcaron", 6, 0x0013E, 0}, {"wscr", 4, 0x1D4CC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_705[] = { {"asympeq", 7, 0x0224D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_706[] = { {"Ifr", 3, 0x02111, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_707[] = { {"DoubleDot", 9, 0x000A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_709[] = { {"nVdash", 6, 0x022AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_70C[] = { {"hairsp", 6, 0x0200A, 0}, {"leftrightarrows", 15, 0x021C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_70E[] = { {"lbrace", 6, 0x0007B, 0}, {"rightarrow", 10, 0x02192, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_70F[] = { {"Dagger", 6, 0x02021, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_712[] = { {"rsh", 3, 0x021B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_714[] = { {"eqslantless", 11, 0x02A95, 0}, {"gnapprox", 8, 0x02A8A, 0}, {"lbrack", 6, 0x0005B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_715[] = { {"uHar", 4, 0x02963, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_717[] = { {"tilde", 5, 0x002DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_719[] = { {"complement", 10, 0x02201, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_71B[] = { {"zcy", 3, 0x00437, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_71E[] = { {"boxDL", 5, 0x02557, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_71F[] = { {"micro", 5, 0x000B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_723[] = { {"horbar", 6, 0x02015, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_724[] = { {"boxDR", 5, 0x02554, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_727[] = { {"bsolhsub", 8, 0x027C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_729[] = { {"ac", 2, 0x0223E, 0}, {"nvdash", 6, 0x022AC, 0}, {"precapprox", 10, 0x02AB7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_72C[] = { {"af", 2, 0x02061, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_72D[] = { {"bullet", 6, 0x02022, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_72E[] = { {"demptyv", 7, 0x029B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_733[] = { {"geqq", 4, 0x02267, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_734[] = { {"uuarr", 5, 0x021C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_735[] = { {"Ocirc", 5, 0x000D4, 0}, {"utdot", 5, 0x022F0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_736[] = { {"ap", 2, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_738[] = { {"bNot", 4, 0x02AED, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_73B[] = { {"CirclePlus", 10, 0x02295, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_73D[] = { {"glE", 3, 0x02A92, 0}, {"midcir", 6, 0x02AF0, 0}, {"rppolint", 8, 0x02A12, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_73E[] = { {"boxDl", 5, 0x02556, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_73F[] = { {"sdot", 4, 0x022C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_744[] = { {"boxDr", 5, 0x02553, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_745[] = { {"Xscr", 4, 0x1D4B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_749[] = { {"dlcrop", 6, 0x0230D, 0}, {"gtrless", 7, 0x02277, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_74B[] = { {"aopf", 4, 0x1D552, 0}, {"operp", 5, 0x029B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_74C[] = { {"kcy", 3, 0x0043A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_74F[] = { {"larrfs", 6, 0x0291D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_751[] = { {"rcub", 4, 0x0007D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_754[] = { {"nrtri", 5, 0x022EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_755[] = { {"nparsl", 6, 0x02AFD, 0x020E5}, {"ocirc", 5, 0x000F4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_759[] = { {"gla", 3, 0x02AA5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_75C[] = { {"Iuml", 4, 0x000CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_75F[] = { {"mcomma", 6, 0x02A29, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_762[] = { {"glj", 3, 0x02AA4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_763[] = { {"Map", 3, 0x02905, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_765[] = { {"copysr", 6, 0x02117, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_766[] = { {"DownTeeArrow", 12, 0x021A7, 0}, {"Upsi", 4, 0x003D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_768[] = { {"awint", 5, 0x02A11, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_76E[] = { {"DownRightVector", 15, 0x021C1, 0}, {"NotEqual", 8, 0x02260, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_770[] = { {"gesl", 4, 0x022DB, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_772[] = { {"NotCupCap", 9, 0x0226D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_776[] = { {"blacktriangleright", 18, 0x025B8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_777[] = { {"zfr", 3, 0x1D537, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_779[] = { {"leftrightarrow", 14, 0x02194, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_77A[] = { {"Abreve", 6, 0x00102, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_77F[] = { {"Uarr", 4, 0x0219F, 0}, {"gnE", 3, 0x02269, 0}, {"supmult", 7, 0x02AC2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_781[] = { {"supplus", 7, 0x02AC0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_783[] = { {"nabla", 5, 0x02207, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_787[] = { {"Lang", 4, 0x027EA, 0}, {"laquo", 5, 0x000AB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_789[] = { {"larrhk", 6, 0x021A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_78C[] = { {"Bopf", 4, 0x1D539, 0}, {"lowbar", 6, 0x0005F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_78D[] = { {"cup", 3, 0x0222A, 0}, {"dd", 2, 0x02146, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_78E[] = { {"nsce", 4, 0x02AB0, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_790[] = { {"nshortparallel", 14, 0x02226, 0}, {"nsupE", 5, 0x02AC6, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_794[] = { {"OpenCurlyQuote", 14, 0x02018, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_797[] = { {"bsolb", 5, 0x029C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_798[] = { {"DScy", 4, 0x00405, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_79A[] = { {"boxHD", 5, 0x02566, 0}, {"ltrPar", 6, 0x02996, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_79B[] = { {"nscr", 4, 0x1D4C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_79D[] = { {"lEg", 3, 0x02A8B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_79F[] = { {"egrave", 6, 0x000E8, 0}, {"gne", 3, 0x02A88, 0}, {"larrsim", 7, 0x02973, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7A0[] = { {"COPY", 4, 0x000A9, 0}, {"bdquo", 5, 0x0201E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7A1[] = { {"wopf", 4, 0x1D568, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7A2[] = { {"NotRightTriangleEqual", 21, 0x022ED, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7A5[] = { {"robrk", 5, 0x027E7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7A8[] = { {"kfr", 3, 0x1D528, 0}, {"nlsim", 5, 0x02274, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7AA[] = { {"xhArr", 5, 0x027FA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7AB[] = { {"boxHU", 5, 0x02569, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7AC[] = { {"lHar", 4, 0x02962, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7AE[] = { {"Mcy", 3, 0x0041C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7AF[] = { {"ee", 2, 0x02147, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7B0[] = { {"nsupe", 5, 0x02289, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7B1[] = { {"eg", 2, 0x02A9A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7B5[] = { {"trade", 5, 0x02122, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7B6[] = { {"el", 2, 0x02A99, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7B7[] = { {"nsucceq", 7, 0x02AB0, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7B8[] = { {"langle", 6, 0x027E8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7BA[] = { {"boxHd", 5, 0x02564, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7BB[] = { {"Subset", 6, 0x022D0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7BD[] = { {"DownArrowBar", 12, 0x02913, 0}, {"topbot", 6, 0x02336, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7BE[] = { {"OverBrace", 9, 0x023DE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7BF[] = { {"Eta", 3, 0x00397, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7C0[] = { {"hstrok", 6, 0x00127, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7C1[] = { {"Hacek", 5, 0x002C7, 0}, {"diamond", 7, 0x022C4, 0}, {"isinsv", 6, 0x022F3, 0}, {"rtriltri", 8, 0x029CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7C9[] = { {"nvltrie", 7, 0x022B4, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7CB[] = { {"boxHu", 5, 0x02567, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7CD[] = { {"fpartint", 8, 0x02A0D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7CE[] = { {"Proportional", 12, 0x0221D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7D1[] = { {"NotSuperset", 11, 0x02283, 0x020D2}, {"gE", 2, 0x02267, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7D2[] = { {"scnsim", 6, 0x022E9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7D5[] = { {"uparrow", 7, 0x02191, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7D6[] = { {"ltlarr", 6, 0x02976, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7D9[] = { {"rtimes", 6, 0x022CA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7DA[] = { {"ncong", 5, 0x02247, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7DC[] = { {"Oscr", 4, 0x1D4AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7E0[] = { {"vArr", 4, 0x021D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7E2[] = { {"Xopf", 4, 0x1D54F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7E4[] = { {"notinva", 7, 0x02209, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7E5[] = { {"notinvb", 7, 0x022F7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7E6[] = { {"notinvc", 7, 0x022F6, 0}, {"nsqsube", 7, 0x022E2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7EC[] = { {"Tcaron", 6, 0x00164, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7EF[] = { {"upsilon", 7, 0x003C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7F1[] = { {"ge", 2, 0x02265, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7F3[] = { {"gg", 2, 0x0226B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7F6[] = { {"KJcy", 4, 0x0040C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7F8[] = { {"gl", 2, 0x02277, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7FB[] = { {"dblac", 5, 0x002DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_7FC[] = { {"lAtail", 6, 0x0291B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_800[] = { {"gt", 2, 0x0003E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_802[] = { {"lotimes", 7, 0x02A34, 0}, {"seArr", 5, 0x021D8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_803[] = { {"Lacute", 6, 0x00139, 0}, {"Laplacetrf", 10, 0x02112, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_808[] = { {"uuml", 4, 0x000FC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_809[] = { {"Amacr", 5, 0x00100, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_80A[] = { {"Mfr", 3, 0x1D510, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_810[] = { {"Int", 3, 0x0222C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_811[] = { {"Vvdash", 6, 0x022AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_812[] = { {"Lcedil", 6, 0x0013B, 0}, {"larrlp", 6, 0x021AB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_816[] = { {"Larr", 4, 0x0219E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_819[] = { {"CircleTimes", 11, 0x02297, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_81C[] = { {"NotReverseElement", 17, 0x0220C, 0}, {"latail", 6, 0x02919, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_81D[] = { {"ntrianglerighteq", 16, 0x022ED, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_821[] = { {"blk12", 5, 0x02592, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_822[] = { {"intlarhk", 8, 0x02A17, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_823[] = { {"blk14", 5, 0x02591, 0}, {"ccupssm", 7, 0x02A50, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_824[] = { {"hercon", 6, 0x022B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_828[] = { {"bigotimes", 9, 0x02A02, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_829[] = { {"amacr", 5, 0x00101, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_82D[] = { {"nrarrc", 6, 0x02933, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_82E[] = { {"ubreve", 6, 0x0016D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_830[] = { {"Yacute", 6, 0x000DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_831[] = { {"ic", 2, 0x02063, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_832[] = { {"escr", 4, 0x0212F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_837[] = { {"ii", 2, 0x02148, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_838[] = { {"DownArrowUpArrow", 16, 0x021F5, 0}, {"nopf", 4, 0x1D55F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_83C[] = { {"in", 2, 0x02208, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_83E[] = { {"bumpE", 5, 0x02AAE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_83F[] = { {"rightharpoonup", 14, 0x021C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_841[] = { {"nrarrw", 6, 0x0219D, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_842[] = { {"it", 2, 0x02062, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_846[] = { {"ncaron", 6, 0x00148, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_84A[] = { {"succnsim", 8, 0x022E9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_84C[] = { {"gammad", 6, 0x003DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_84F[] = { {"yucy", 4, 0x0044E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_850[] = { {"ocy", 3, 0x0043E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_855[] = { {"hybull", 6, 0x02043, 0}, {"rpargt", 6, 0x02994, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_857[] = { {"csube", 5, 0x02AD1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_85B[] = { {"iiota", 5, 0x02129, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_85C[] = { {"nsim", 4, 0x02241, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_85E[] = { {"LeftTriangleEqual", 17, 0x022B4, 0}, {"bumpe", 5, 0x0224F, 0}, {"nearhk", 6, 0x02924, 0}, {"nhpar", 5, 0x02AF2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_861[] = { {"risingdotseq", 12, 0x02253, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_865[] = { {"blk34", 5, 0x02593, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_866[] = { {"LeftTriangle", 12, 0x022B2, 0}, {"vBarv", 5, 0x02AE9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_867[] = { {"AElig", 5, 0x000C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_868[] = { {"DoubleUpDownArrow", 17, 0x021D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_86A[] = { {"cwint", 5, 0x02231, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_86B[] = { {"rtrie", 5, 0x022B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_86C[] = { {"rtrif", 5, 0x025B8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_873[] = { {"Fscr", 4, 0x02131, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_876[] = { {"lE", 2, 0x02266, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_879[] = { {"Oopf", 4, 0x1D546, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_87B[] = { {"spar", 4, 0x02225, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_87E[] = { {"uplus", 5, 0x0228E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_88A[] = { {"sacute", 6, 0x0015B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_88C[] = { {"fltns", 5, 0x025B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_88E[] = { {"rrarr", 5, 0x021C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_892[] = { {"larrpl", 6, 0x02939, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_895[] = { {"ultri", 5, 0x025F8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_896[] = { {"le", 2, 0x02264, 0}, {"xuplus", 6, 0x02A04, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_897[] = { {"ljcy", 4, 0x00459, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_898[] = { {"lg", 2, 0x02276, 0}, {"vsubnE", 6, 0x02ACB, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_899[] = { {"scedil", 6, 0x0015F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_89D[] = { {"ll", 2, 0x0226A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8A5[] = { {"lt", 2, 0x0003C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8AC[] = { {"ofr", 3, 0x1D52C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8B3[] = { {"nexists", 7, 0x02204, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8B6[] = { {"smallsetminus", 13, 0x02216, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8B7[] = { {"InvisibleComma", 14, 0x02063, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8B8[] = { {"dotminus", 8, 0x02238, 0}, {"vsubne", 6, 0x0228A, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8B9[] = { {"iocy", 4, 0x00451, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8BA[] = { {"gsime", 5, 0x02A8E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8BC[] = { {"Rarrtl", 6, 0x02916, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8BD[] = { {"cirmid", 6, 0x02AEF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8C0[] = { {"ominus", 6, 0x02296, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8C1[] = { {"gsiml", 5, 0x02A90, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8C2[] = { {"Prime", 5, 0x02033, 0}, {"mp", 2, 0x02213, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8C4[] = { {"tint", 4, 0x0222D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8C7[] = { {"mu", 2, 0x003BC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8CF[] = { {"dbkarow", 7, 0x0290F, 0}, {"eopf", 4, 0x1D556, 0}, {"ogt", 3, 0x029C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8D0[] = { {"Precedes", 8, 0x0227A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8D3[] = { {"UpTeeArrow", 10, 0x021A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8D6[] = { {"varsupsetneq", 12, 0x0228B, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8D8[] = { {"ne", 2, 0x02260, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8DC[] = { {"ni", 2, 0x0220B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8DD[] = { {"mDDot", 5, 0x0223A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8DE[] = { {"cularrp", 7, 0x0293D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8DF[] = { {"rnmid", 5, 0x02AEE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8E0[] = { {"hardcy", 6, 0x0044A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8E2[] = { {"prime", 5, 0x02032, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8E3[] = { {"Bcy", 3, 0x00411, 0}, {"REG", 3, 0x000AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8E7[] = { {"oS", 2, 0x024C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8E8[] = { {"nu", 2, 0x003BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8E9[] = { {"ohm", 3, 0x003A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8EB[] = { {"langd", 5, 0x02991, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8F3[] = { {"backprime", 9, 0x02035, 0}, {"esim", 4, 0x02242, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8FB[] = { {"veeeq", 5, 0x0225A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8FE[] = { {"RightCeiling", 12, 0x02309, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_8FF[] = { {"crarr", 5, 0x021B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_904[] = { {"eqsim", 5, 0x02242, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_906[] = { {"or", 2, 0x02228, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_907[] = { {"OverParenthesis", 15, 0x023DC, 0}, {"UpperLeftArrow", 14, 0x02196, 0}, {"nleftrightarrow", 15, 0x021AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_909[] = { {"expectation", 11, 0x02130, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_90C[] = { {"coprod", 6, 0x02210, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_90E[] = { {"Qfr", 3, 0x1D514, 0}, {"dArr", 4, 0x021D3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_910[] = { {"Fopf", 4, 0x1D53D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_913[] = { {"Cconint", 7, 0x02230, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_916[] = { {"larrtl", 6, 0x021A2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_918[] = { {"Aacute", 6, 0x000C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_919[] = { {"DownLeftRightVector", 19, 0x02950, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_91B[] = { {"circleddash", 11, 0x0229D, 0}, {"thinsp", 6, 0x02009, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_91E[] = { {"Longrightarrow", 14, 0x027F9, 0}, {"pi", 2, 0x003C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_91F[] = { {"hookrightarrow", 14, 0x021AA, 0}, {"rscr", 4, 0x1D4C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_920[] = { {"scE", 3, 0x02AB4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_922[] = { {"pm", 2, 0x000B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_923[] = { {"ZHcy", 4, 0x00416, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_927[] = { {"pr", 2, 0x0227A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_929[] = { {"LongLeftRightArrow", 18, 0x027F7, 0}, {"supset", 6, 0x02283, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_92A[] = { {"UpArrowBar", 10, 0x02912, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_92C[] = { {"Utilde", 6, 0x00168, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_92E[] = { {"xlArr", 5, 0x027F8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_930[] = { {"DoubleUpArrow", 13, 0x021D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_936[] = { {"alefsym", 7, 0x02135, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_939[] = { {"Scirc", 5, 0x0015C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_93B[] = { {"xotime", 6, 0x02A02, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_93F[] = { {"Bfr", 3, 0x1D505, 0}, {"rdca", 4, 0x02937, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_940[] = { {"sce", 3, 0x02AB0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_945[] = { {"Nacute", 6, 0x00143, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_947[] = { {"amalg", 5, 0x02A3F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_94D[] = { {"UpDownArrow", 11, 0x02195, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_94F[] = { {"EqualTilde", 10, 0x02242, 0}, {"boxUL", 5, 0x0255D, 0}, {"oslash", 6, 0x000F8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_950[] = { {"lnap", 4, 0x02A89, 0}, {"thorn", 5, 0x000FE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_952[] = { {"ssmile", 6, 0x02323, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_953[] = { {"ndash", 5, 0x02013, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_954[] = { {"Ncedil", 6, 0x00145, 0}, {"scy", 3, 0x00441, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_955[] = { {"boxUR", 5, 0x0255A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_956[] = { {"Aring", 5, 0x000C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_959[] = { {"scirc", 5, 0x0015D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_95B[] = { {"ccaron", 6, 0x0010D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_95D[] = { {"dotsquare", 9, 0x022A1, 0}, {"nshortmid", 9, 0x02224, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_95F[] = { {"rsquo", 5, 0x02019, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_960[] = { {"Sscr", 4, 0x1D4AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_963[] = { {"bigwedge", 8, 0x022C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_964[] = { {"Bernoullis", 10, 0x0212C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_969[] = { {"harrw", 5, 0x021AD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_96C[] = { {"SquareSubset", 12, 0x0228F, 0}, {"boxVH", 5, 0x0256C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_96F[] = { {"boxUl", 5, 0x0255C, 0}, {"rx", 2, 0x0211E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_970[] = { {"boxVL", 5, 0x02563, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_974[] = { {"olt", 3, 0x029C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_975[] = { {"boxUr", 5, 0x02559, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_976[] = { {"aring", 5, 0x000E5, 0}, {"boxVR", 5, 0x02560, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_97B[] = { {"sc", 2, 0x0227B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_97C[] = { {"NestedGreaterGreater", 20, 0x0226B, 0}, {"oast", 4, 0x0229B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_97F[] = { {"star", 4, 0x02606, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_981[] = { {"LeftTeeVector", 13, 0x0295A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_983[] = { {"bigsqcup", 8, 0x02A06, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_985[] = { {"dcy", 3, 0x00434, 0}, {"preceq", 6, 0x02AAF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_986[] = { {"otilde", 6, 0x000F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_988[] = { {"luruhar", 7, 0x02966, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_98C[] = { {"boxVh", 5, 0x0256B, 0}, {"capand", 6, 0x02A44, 0}, {"yuml", 4, 0x000FF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_98D[] = { {"Updownarrow", 11, 0x021D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_98F[] = { {"TildeEqual", 10, 0x02243, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_990[] = { {"boxVl", 5, 0x02562, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_996[] = { {"boxVr", 5, 0x0255F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_997[] = { {"HorizontalLine", 14, 0x02500, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_99B[] = { {"xmap", 4, 0x027FC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_99C[] = { {"sigmaf", 6, 0x003C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_99E[] = { {"EmptySmallSquare", 16, 0x025FB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_99F[] = { {"dzcy", 4, 0x0045F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9A0[] = { {"cups", 4, 0x0222A, 0x0FE00}, {"zwj", 3, 0x0200D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9A1[] = { {"beta", 4, 0x003B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9A6[] = { {"supsim", 6, 0x02AC8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9A8[] = { {"beth", 4, 0x02136, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9AA[] = { {"Iukcy", 5, 0x00406, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9AC[] = { {"eparsl", 6, 0x029E3, 0}, {"sigmav", 6, 0x003C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9B0[] = { {"lhard", 5, 0x021BD, 0}, {"sfr", 3, 0x1D530, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9B4[] = { {"nsqsupe", 7, 0x022E3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9B5[] = { {"Jsercy", 6, 0x00408, 0}, {"deg", 3, 0x000B0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9B6[] = { {"Ucy", 3, 0x00423, 0}, {"iscr", 4, 0x1D4BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9B7[] = { {"efDot", 5, 0x02252, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9BB[] = { {"uhblk", 5, 0x02580, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9BC[] = { {"ropf", 4, 0x1D563, 0}, {"vprop", 5, 0x0221D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9BD[] = { {"isinE", 5, 0x022F9, 0}, {"raemptyv", 8, 0x029B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9C1[] = { {"lharu", 5, 0x021BC, 0}, {"ncongdot", 8, 0x02A6D, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9C2[] = { {"subnE", 5, 0x02ACB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9C3[] = { {"ngsim", 5, 0x02275, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9C5[] = { {"starf", 5, 0x02605, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9C9[] = { {"Ograve", 6, 0x000D2, 0}, {"hksearow", 8, 0x02925, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9CA[] = { {"iukcy", 5, 0x00456, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9CC[] = { {"uacute", 6, 0x000FA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9CF[] = { {"asymp", 5, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9D5[] = { {"lneq", 4, 0x02A87, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9D6[] = { {"Otimes", 6, 0x02A37, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9DA[] = { {"NotTildeTilde", 13, 0x02249, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9DB[] = { {"Integral", 8, 0x0222B, 0}, {"rbrke", 5, 0x0298C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9DD[] = { {"nsub", 4, 0x02284, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9DE[] = { {"rlhar", 5, 0x021CC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9E1[] = { {"dfr", 3, 0x1D521, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9E2[] = { {"subne", 5, 0x0228A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9E5[] = { {"varnothing", 10, 0x02205, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9E7[] = { {"Fcy", 3, 0x00424, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9E9[] = { {"DoubleLeftTee", 13, 0x02AE4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9EB[] = { {"isins", 5, 0x022F4, 0}, {"nsup", 4, 0x02285, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9ED[] = { {"circlearrowleft", 15, 0x021BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9EE[] = { {"isinv", 5, 0x02208, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9EF[] = { {"IEcy", 4, 0x00415, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F0[] = { {"conint", 6, 0x0222E, 0}, {"vBar", 4, 0x02AE8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F1[] = { {"edot", 4, 0x00117, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F2[] = { {"Kappa", 5, 0x0039A, 0}, {"MediumSpace", 11, 0x0205F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F3[] = { {"lbrksld", 7, 0x0298F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F4[] = { {"sect", 4, 0x000A7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F5[] = { {"nldr", 4, 0x02025, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F7[] = { {"Jscr", 4, 0x1D4A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9F9[] = { {"shy", 3, 0x000AD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9FA[] = { {"ulcrop", 6, 0x0230F, 0}, {"veebar", 6, 0x022BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_9FD[] = { {"Sopf", 4, 0x1D54A, 0}, {"cuwed", 5, 0x022CF, 0}, {"rAarr", 5, 0x021DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A01[] = { {"erarr", 5, 0x02971, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A04[] = { {"lbrkslu", 7, 0x0298D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A05[] = { {"NotSucceeds", 11, 0x02281, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A06[] = { {"nsccue", 6, 0x022E1, 0}, {"subrarr", 7, 0x02979, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A08[] = { {"looparrowright", 14, 0x021AC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A0C[] = { {"wp", 2, 0x02118, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A0D[] = { {"Emacr", 5, 0x00112, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A0E[] = { {"sim", 3, 0x0223C, 0}, {"wr", 2, 0x02240, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A10[] = { {"Udblac", 6, 0x00170, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A12[] = { {"Ufr", 3, 0x1D518, 0}, {"kappa", 5, 0x003BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A14[] = { {"notindot", 8, 0x022F5, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A15[] = { {"nleq", 4, 0x02270, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A16[] = { {"NestedLessLess", 14, 0x0226A, 0}, {"square", 6, 0x025A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A17[] = { {"nles", 4, 0x02A7D, 0x00338}, {"squarf", 6, 0x025AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A21[] = { {"order", 5, 0x02134, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A23[] = { {"igrave", 6, 0x000EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A24[] = { {"precneqq", 8, 0x02AB5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A25[] = { {"csupe", 5, 0x02AD2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A26[] = { {"xi", 2, 0x003BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A28[] = { {"NotHumpEqual", 12, 0x0224F, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A2A[] = { {"ord", 3, 0x02A5D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A2D[] = { {"emacr", 5, 0x00113, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A30[] = { {"nwnear", 6, 0x02927, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A32[] = { {"nprcue", 6, 0x022E0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A36[] = { {"NotExists", 9, 0x02204, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A37[] = { {"die", 3, 0x000A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A39[] = { {"ddotseq", 7, 0x02A77, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A3B[] = { {"Dashv", 5, 0x02AE4, 0}, {"Ucirc", 5, 0x000DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A3C[] = { {"orv", 3, 0x02A5B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A3D[] = { {"Because", 7, 0x02235, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A41[] = { {"kgreen", 6, 0x00138, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A43[] = { {"Ffr", 3, 0x1D509, 0}, {"LeftVector", 10, 0x021BC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A44[] = { {"lstrok", 6, 0x00142, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A45[] = { {"twixt", 5, 0x0226C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A48[] = { {"compfn", 6, 0x02218, 0}, {"div", 3, 0x000F7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A4F[] = { {"drcrop", 6, 0x0230C, 0}, {"shortmid", 8, 0x02223, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A53[] = { {"iopf", 4, 0x1D55A, 0}, {"triangledown", 12, 0x025BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A54[] = { {"IJlig", 5, 0x00132, 0}, {"thetasym", 8, 0x003D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A56[] = { {"Sigma", 5, 0x003A3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A57[] = { {"equivDD", 7, 0x02A78, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A5A[] = { {"Cacute", 6, 0x00106, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A5B[] = { {"dashv", 5, 0x022A3, 0}, {"ucirc", 5, 0x000FB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A61[] = { {"gneqq", 5, 0x02269, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A62[] = { {"gvertneqq", 9, 0x02269, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A63[] = { {"RightDownVectorBar", 18, 0x02955, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A64[] = { {"NotLessLess", 11, 0x0226A, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A69[] = { {"Ccedil", 6, 0x000C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A6A[] = { {"odblac", 6, 0x00151, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A6B[] = { {"mstpos", 6, 0x0223E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A6D[] = { {"cemptyv", 7, 0x029B2, 0}, {"rarrap", 6, 0x02975, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A6F[] = { {"rmoust", 6, 0x023B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A70[] = { {"elsdot", 6, 0x02A97, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A76[] = { {"sigma", 5, 0x003C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A78[] = { {"Implies", 7, 0x021D2, 0}, {"isin", 4, 0x02208, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A7A[] = { {"bottom", 6, 0x022A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A7E[] = { {"ShortRightArrow", 15, 0x02192, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A81[] = { {"cupcap", 6, 0x02A46, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A82[] = { {"NotSquareSuperset", 17, 0x02290, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A84[] = { {"LeftArrowRightArrow", 19, 0x021C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A85[] = { {"FilledVerySmallSquare", 21, 0x025AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A86[] = { {"LeftUpTeeVector", 15, 0x02960, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A89[] = { {"DoubleRightArrow", 16, 0x021D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A8D[] = { {"raquo", 5, 0x000BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A8E[] = { {"Ascr", 4, 0x1D49C, 0}, {"ReverseUpEquilibrium", 20, 0x0296F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A92[] = { {"hArr", 4, 0x021D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A94[] = { {"Jopf", 4, 0x1D541, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A96[] = { {"npar", 4, 0x02226, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A98[] = { {"SupersetEqual", 13, 0x02287, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A99[] = { {"ffllig", 6, 0x0FB04, 0}, {"smt", 3, 0x02AAA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A9A[] = { {"twoheadrightarrow", 17, 0x021A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A9D[] = { {"ecaron", 6, 0x0011B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_A9F[] = { {"NotRightTriangleBar", 19, 0x029D0, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AA3[] = { {"apid", 4, 0x0224B, 0}, {"vscr", 4, 0x1D4CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AA4[] = { {"supdot", 6, 0x02ABE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AA5[] = { {"colone", 6, 0x02254, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AA7[] = { {"dwangle", 7, 0x029A6, 0}, {"shchcy", 6, 0x00449, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AAC[] = { {"ltdot", 5, 0x022D6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AB2[] = { {"downharpoonright", 16, 0x021C2, 0}, {"gjcy", 4, 0x00453, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AB4[] = { {"wfr", 3, 0x1D534, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AB5[] = { {"rfisht", 6, 0x0297D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ABA[] = { {"Ycy", 3, 0x0042B, 0}, {"swarrow", 7, 0x02199, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AC0[] = { {"nharr", 5, 0x021AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AC4[] = { {"frac12", 6, 0x000BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AC5[] = { {"frac13", 6, 0x02153, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AC6[] = { {"frac14", 6, 0x000BC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AC7[] = { {"GreaterEqual", 12, 0x02265, 0}, {"frac15", 6, 0x02155, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AC8[] = { {"Gamma", 5, 0x00393, 0}, {"frac16", 6, 0x02159, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ACA[] = { {"dzigrarr", 8, 0x027FF, 0}, {"frac18", 6, 0x0215B, 0}, {"rcaron", 6, 0x00159, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ACC[] = { {"DownRightTeeVector", 18, 0x0295F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ACF[] = { {"nvrtrie", 7, 0x022B5, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AD2[] = { {"iota", 4, 0x003B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AD3[] = { {"sol", 3, 0x0002F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AD4[] = { {"rbrace", 6, 0x0007D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ADA[] = { {"rbrack", 6, 0x0005D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ADD[] = { {"rsqb", 4, 0x0005D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ADF[] = { {"oint", 4, 0x0222E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AE4[] = { {"Wscr", 4, 0x1D4B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AE5[] = { {"hfr", 3, 0x1D525, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AE6[] = { {"frac23", 6, 0x02154, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AE7[] = { {"dlcorn", 6, 0x0231E, 0}, {"verbar", 6, 0x0007C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AE8[] = { {"frac25", 6, 0x02156, 0}, {"gamma", 5, 0x003B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AE9[] = { {"nVDash", 6, 0x022AF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AEB[] = { {"Jcy", 3, 0x00419, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AF5[] = { {"nwarrow", 7, 0x02196, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AF6[] = { {"OverBar", 7, 0x0203E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AF7[] = { {"rightsquigarrow", 15, 0x0219D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AFA[] = { {"iexcl", 5, 0x000A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AFD[] = { {"sqcap", 5, 0x02293, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_AFE[] = { {"pertenk", 7, 0x02031, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B08[] = { {"PrecedesEqual", 13, 0x02AAF, 0}, {"frac34", 6, 0x000BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B09[] = { {"Therefore", 9, 0x02234, 0}, {"frac35", 6, 0x02157, 0}, {"nvDash", 6, 0x022AD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B0A[] = { {"odsold", 6, 0x029BC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B0C[] = { {"dot", 3, 0x002D9, 0}, {"frac38", 6, 0x0215C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B10[] = { {"sqcaps", 6, 0x02293, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B11[] = { {"ZeroWidthSpace", 14, 0x0200B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B15[] = { {"rarrfs", 6, 0x0291E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B16[] = { {"Yfr", 3, 0x1D51C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B1E[] = { {"CircleDot", 9, 0x02299, 0}, {"gtcir", 5, 0x02A7A, 0}, {"squ", 3, 0x025A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B1F[] = { {"angmsd", 6, 0x02221, 0}, {"nsubseteq", 9, 0x02288, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B23[] = { {"iprod", 5, 0x02A3C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B24[] = { {"bprime", 6, 0x02035, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B27[] = { {"supsub", 6, 0x02AD4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B29[] = { {"SquareSupersetEqual", 19, 0x02292, 0}, {"therefore", 9, 0x02234, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B2A[] = { {"frac45", 6, 0x02158, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B2B[] = { {"Aopf", 4, 0x1D538, 0}, {"NotGreaterFullEqual", 19, 0x02267, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B2C[] = { {"Tstrok", 6, 0x00166, 0}, {"rightleftarrows", 15, 0x021C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B2D[] = { {"Fouriertrf", 10, 0x02131, 0}, {"epar", 4, 0x022D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B2E[] = { {"omid", 4, 0x029B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B2F[] = { {"OpenCurlyDoubleQuote", 20, 0x0201C, 0}, {"dagger", 6, 0x02020, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B33[] = { {"semi", 4, 0x0003B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B35[] = { {"supsup", 6, 0x02AD6, 0}, {"zeetrf", 6, 0x02128, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B36[] = { {"DifferentialD", 13, 0x02146, 0}, {"topcir", 6, 0x02AF1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B3A[] = { {"mscr", 4, 0x1D4C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B3D[] = { {"Wcirc", 5, 0x00174, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B3E[] = { {"boxdL", 5, 0x02555, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B40[] = { {"Gbreve", 6, 0x0011E, 0}, {"vopf", 4, 0x1D567, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B42[] = { {"lap", 3, 0x02A85, 0}, {"llarr", 5, 0x021C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B44[] = { {"boxdR", 5, 0x02552, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B46[] = { {"RightAngleBracket", 17, 0x027E9, 0}, {"lat", 3, 0x02AAB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B47[] = { {"Jfr", 3, 0x1D50D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B4C[] = { {"frac56", 6, 0x0215A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B4E[] = { {"frac58", 6, 0x0215D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B4F[] = { {"rarrhk", 6, 0x021AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B50[] = { {"lesdot", 6, 0x02A7F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B51[] = { {"ApplyFunction", 13, 0x02061, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B52[] = { {"NotGreaterTilde", 15, 0x02275, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B53[] = { {"Cedilla", 7, 0x000B8, 0}, {"curvearrowright", 15, 0x021B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B56[] = { {"rdsh", 4, 0x021B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B58[] = { {"larrb", 5, 0x021E4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B5C[] = { {"vrtri", 5, 0x022B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B5D[] = { {"nequiv", 6, 0x02262, 0}, {"wcirc", 5, 0x00175, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B5E[] = { {"boxdl", 5, 0x02510, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B63[] = { {"DoubleDownArrow", 15, 0x021D3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B64[] = { {"boxdr", 5, 0x0250C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B67[] = { {"pluscir", 7, 0x02A22, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B69[] = { {"longmapsto", 10, 0x027FC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B6B[] = { {"gnap", 4, 0x02A8A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B6D[] = { {"bigodot", 7, 0x02A00, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B72[] = { {"thickapprox", 11, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B73[] = { {"DotDot", 6, 0x020DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B77[] = { {"incare", 6, 0x02105, 0}, {"rarrbfs", 7, 0x02920, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B78[] = { {"apos", 4, 0x00027, 0}, {"tbrk", 4, 0x023B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B7A[] = { {"grave", 5, 0x00060, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B7B[] = { {"Nscr", 4, 0x1D4A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B7E[] = { {"rangle", 6, 0x027E9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B7F[] = { {"uArr", 4, 0x021D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B81[] = { {"Wopf", 4, 0x1D54E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B82[] = { {"doteq", 5, 0x02250, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B87[] = { {"times", 5, 0x000D7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B8D[] = { {"fflig", 5, 0x0FB00, 0}, {"lcy", 3, 0x0043B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B8F[] = { {"sub", 3, 0x02282, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B90[] = { {"frac78", 6, 0x0215E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B94[] = { {"xrarr", 5, 0x027F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B98[] = { {"UpArrowDownArrow", 16, 0x021C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B99[] = { {"bbrktbrk", 8, 0x023B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B9A[] = { {"abreve", 6, 0x00103, 0}, {"lsaquo", 6, 0x02039, 0}, {"sum", 3, 0x02211, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B9C[] = { {"Eacute", 6, 0x000C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_B9D[] = { {"sup", 3, 0x02283, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BA5[] = { {"ContourIntegral", 15, 0x0222E, 0}, {"DiacriticalDot", 14, 0x002D9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BA9[] = { {"trisb", 5, 0x029CD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BAE[] = { {"Hcirc", 5, 0x00124, 0}, {"lceil", 5, 0x02308, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BB2[] = { {"Zcaron", 6, 0x0017D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BB5[] = { {"looparrowleft", 13, 0x021AB, 0}, {"oelig", 5, 0x00153, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BB6[] = { {"LessSlantEqual", 14, 0x02A7D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BB7[] = { {"NegativeThinSpace", 17, 0x0200B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BBA[] = { {"boxhD", 5, 0x02565, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BBC[] = { {"omicron", 7, 0x003BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BBD[] = { {"leg", 3, 0x022DA, 0}, {"rightthreetimes", 15, 0x022CC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BBF[] = { {"NotSucceedsSlantEqual", 21, 0x022E1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC1[] = { {"angmsdaa", 8, 0x029A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC2[] = { {"angmsdab", 8, 0x029A9, 0}, {"rAtail", 6, 0x0291C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC3[] = { {"angmsdac", 8, 0x029AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC4[] = { {"angmsdad", 8, 0x029AB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC5[] = { {"angmsdae", 8, 0x029AC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC6[] = { {"angmsdaf", 8, 0x029AD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC7[] = { {"angmsdag", 8, 0x029AE, 0}, {"leq", 3, 0x02264, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC8[] = { {"angmsdah", 8, 0x029AF, 0}, {"solbar", 6, 0x0233F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BC9[] = { {"Racute", 6, 0x00154, 0}, {"les", 3, 0x02A7D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BCB[] = { {"boxhU", 5, 0x02568, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BCE[] = { {"hcirc", 5, 0x00125, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BD1[] = { {"dscr", 4, 0x1D4B9, 0}, {"smashp", 6, 0x02A33, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BD7[] = { {"mopf", 4, 0x1D55E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BD8[] = { {"Rcedil", 6, 0x00156, 0}, {"dscy", 4, 0x00455, 0}, {"prap", 4, 0x02AB7, 0}, {"rarrlp", 6, 0x021AC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BD9[] = { {"Aogon", 5, 0x00104, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BDA[] = { {"boxhd", 5, 0x0252C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BDB[] = { {"subset", 6, 0x02282, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BDD[] = { {"lgE", 3, 0x02A91, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BDF[] = { {"epsilon", 7, 0x003B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BE1[] = { {"curarrm", 7, 0x0293C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BE2[] = { {"ratail", 6, 0x0291A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BE4[] = { {"DoubleLongLeftRightArrow", 24, 0x027FA, 0}, {"rhov", 4, 0x003F1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BE7[] = { {"LeftDoubleBracket", 17, 0x027E6, 0}, {"Lleftarrow", 10, 0x021DA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BE8[] = { {"Uuml", 4, 0x000DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BE9[] = { {"lfr", 3, 0x1D529, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BEA[] = { {"minusdu", 7, 0x02A2A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BEB[] = { {"boxhu", 5, 0x02534, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BEF[] = { {"Ncy", 3, 0x0041D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BF0[] = { {"gneq", 4, 0x02A88, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BF1[] = { {"rangd", 5, 0x02992, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BF2[] = { {"range", 5, 0x029A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BF3[] = { {"lfloor", 6, 0x0230A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BF7[] = { {"NotSucceedsTilde", 16, 0x0227F, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BF9[] = { {"aogon", 5, 0x00105, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BFA[] = { {"NotGreaterSlantEqual", 20, 0x02A7E, 0x00338}, {"NotSquareSupersetEqual", 22, 0x022E3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_BFC[] = { {"profsurf", 8, 0x02313, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C02[] = { {"wedgeq", 6, 0x02259, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C0B[] = { {"Alpha", 5, 0x00391, 0}, {"DiacriticalDoubleAcute", 22, 0x002DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C0C[] = { {"lltri", 5, 0x025FA, 0}, {"tcaron", 6, 0x00165, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C11[] = { {"Imacr", 5, 0x0012A, 0}, {"subseteq", 8, 0x02286, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C12[] = { {"Escr", 4, 0x02130, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C16[] = { {"lArr", 4, 0x021D0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C18[] = { {"Nopf", 4, 0x02115, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C1A[] = { {"rpar", 4, 0x00029, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C1D[] = { {"divonx", 6, 0x022C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C1E[] = { {"olcir", 5, 0x029BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C23[] = { {"lacute", 6, 0x0013A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C27[] = { {"zscr", 4, 0x1D4CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C2B[] = { {"alpha", 5, 0x003B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C31[] = { {"imacr", 5, 0x0012B, 0}, {"vellip", 6, 0x022EE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C32[] = { {"lcedil", 6, 0x0013C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C33[] = { {"sime", 4, 0x02243, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C34[] = { {"empty", 5, 0x02205, 0}, {"imped", 5, 0x001B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C35[] = { {"simg", 4, 0x02A9E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C36[] = { {"kjcy", 4, 0x0045C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C3A[] = { {"siml", 4, 0x02A9D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C3E[] = { {"LessEqualGreater", 16, 0x022DA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C3F[] = { {"Ycirc", 5, 0x00176, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C40[] = { {"RoundImplies", 12, 0x02970, 0}, {"nvrArr", 6, 0x02903, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C43[] = { {"check", 5, 0x02713, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C44[] = { {"nlarr", 5, 0x0219A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C46[] = { {"middot", 6, 0x000B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C48[] = { {"par", 3, 0x02225, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C4A[] = { {"NotGreaterGreater", 17, 0x0226B, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C4B[] = { {"Nfr", 3, 0x1D511, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C4F[] = { {"nwArr", 5, 0x021D6, 0}, {"prec", 4, 0x0227A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C50[] = { {"Barv", 4, 0x02AE7, 0}, {"yacute", 6, 0x000FD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C54[] = { {"DoubleLeftRightArrow", 20, 0x021D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C58[] = { {"Coproduct", 9, 0x02210, 0}, {"rarrpl", 6, 0x02945, 0}, {"subsim", 6, 0x02AC7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C5A[] = { {"ntgl", 4, 0x02279, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C5B[] = { {"LeftTriangleBar", 15, 0x029CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C5F[] = { {"ycirc", 5, 0x00177, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C69[] = { {"doteqdot", 8, 0x02251, 0}, {"nang", 4, 0x02220, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C6B[] = { {"bigcap", 6, 0x022C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C6C[] = { {"CHcy", 4, 0x00427, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C6E[] = { {"dopf", 4, 0x1D555, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C72[] = { {"inodot", 6, 0x00131, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C76[] = { {"nvHarr", 6, 0x02904, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C77[] = { {"laemptyv", 8, 0x029B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C78[] = { {"bigcirc", 7, 0x025EF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C7A[] = { {"scnap", 5, 0x02ABA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C7B[] = { {"DownLeftVector", 14, 0x021BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C80[] = { {"race", 4, 0x0223D, 0x00331}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C82[] = { {"vartriangleright", 16, 0x022B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C89[] = { {"napE", 4, 0x02A70, 0x00338}, {"supedot", 7, 0x02AC4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C8E[] = { {"acE", 3, 0x0223E, 0x00333}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C91[] = { {"pcy", 3, 0x0043F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C93[] = { {"qprime", 6, 0x02057, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C94[] = { {"RightTeeVector", 14, 0x0295B, 0}, {"curlyvee", 8, 0x022CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C95[] = { {"swarhk", 6, 0x02926, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_C98[] = { {"Atilde", 6, 0x000C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CA6[] = { {"bbrk", 4, 0x023B5, 0}, {"prnap", 5, 0x02AB9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CA8[] = { {"image", 5, 0x02111, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CA9[] = { {"sext", 4, 0x02736, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CAA[] = { {"ldquo", 5, 0x0201C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CAC[] = { {"NotLeftTriangleBar", 18, 0x029CF, 0x00338}, {"epsiv", 5, 0x003F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CAD[] = { {"CenterDot", 9, 0x000B7, 0}, {"acd", 3, 0x0223F, 0}, {"upuparrows", 10, 0x021C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CAF[] = { {"Eopf", 4, 0x1D53C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CB0[] = { {"Jcirc", 5, 0x00134, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CB2[] = { {"smid", 4, 0x02223, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CB4[] = { {"bull", 4, 0x02022, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CB6[] = { {"rhard", 5, 0x021C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CB7[] = { {"nsupset", 7, 0x02283, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CBA[] = { {"npre", 4, 0x02AAF, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CBE[] = { {"qscr", 4, 0x1D4C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CC2[] = { {"acy", 3, 0x00430, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CC4[] = { {"lnE", 3, 0x02268, 0}, {"zopf", 4, 0x1D56B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CC5[] = { {"Ntilde", 6, 0x000D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CC7[] = { {"rharu", 5, 0x021C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CC8[] = { {"kappav", 6, 0x003F0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CC9[] = { {"timesb", 6, 0x022A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CCB[] = { {"iiiint", 6, 0x02A0C, 0}, {"timesd", 6, 0x02A30, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CD0[] = { {"jcirc", 5, 0x00135, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CD2[] = { {"nsimeq", 6, 0x02244, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CD3[] = { {"Esim", 4, 0x02A73, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CD9[] = { {"Cap", 3, 0x022D2, 0}, {"bump", 4, 0x0224E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CDA[] = { {"lvnE", 4, 0x02268, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CDC[] = { {"rarrtl", 6, 0x021A3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CE4[] = { {"lne", 3, 0x02A87, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CE6[] = { {"commat", 6, 0x00040, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CE8[] = { {"hslash", 6, 0x0210F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CE9[] = { {"lthree", 6, 0x022CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CED[] = { {"Gcedil", 6, 0x00122, 0}, {"pfr", 3, 0x1D52D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CF1[] = { {"RightTriangleEqual", 18, 0x022B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CF2[] = { {"ngeqslant", 9, 0x02A7E, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CF3[] = { {"Rcy", 3, 0x00420, 0}, {"gimel", 5, 0x02137, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CF4[] = { {"curarr", 6, 0x021B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CFA[] = { {"ntlg", 4, 0x02278, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_CFF[] = { {"Rscr", 4, 0x0211B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D00[] = { {"urcrop", 6, 0x0230E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D06[] = { {"Poincareplane", 13, 0x0210C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D07[] = { {"NoBreak", 7, 0x02060, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D0B[] = { {"lcub", 4, 0x0007B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D0E[] = { {"nltri", 5, 0x022EA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D10[] = { {"blacktriangledown", 17, 0x025BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D11[] = { {"fjlig", 5, 0x00066, 0x0006A}, {"percnt", 6, 0x00025, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D12[] = { {"rightharpoondown", 16, 0x021C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D13[] = { {"LeftAngleBracket", 16, 0x027E8, 0}, {"npreceq", 7, 0x02AAF, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D15[] = { {"cupcup", 6, 0x02A4A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D18[] = { {"LeftVectorBar", 13, 0x02952, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D19[] = { {"NJcy", 4, 0x0040A, 0}, {"triangleright", 13, 0x025B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D1A[] = { {"Tcedil", 6, 0x00162, 0}, {"loz", 3, 0x025CA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D1E[] = { {"afr", 3, 0x1D51E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D1F[] = { {"NotLessTilde", 12, 0x02274, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D20[] = { {"NotElement", 10, 0x02209, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D22[] = { {"NotHumpDownHump", 15, 0x0224E, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D24[] = { {"SquareSubsetEqual", 17, 0x02291, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D26[] = { {"nleqq", 5, 0x02266, 0x00338}, {"phi", 3, 0x003C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D2A[] = { {"NotRightTriangle", 16, 0x022EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D32[] = { {"lhblk", 5, 0x02584, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D34[] = { {"caret", 5, 0x02041, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D35[] = { {"bsemi", 5, 0x0204F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D38[] = { {"aacute", 6, 0x000E1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D39[] = { {"mapsto", 6, 0x021A6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D3A[] = { {"Congruent", 9, 0x02261, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D3B[] = { {"Vdash", 5, 0x022A9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D3E[] = { {"longrightarrow", 14, 0x027F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D42[] = { {"iinfin", 6, 0x029DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D44[] = { {"EmptyVerySmallSquare", 20, 0x025AB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D49[] = { {"real", 4, 0x0211C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D4C[] = { {"SucceedsEqual", 13, 0x02AB0, 0}, {"utilde", 6, 0x00169, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D4F[] = { {"Rfr", 3, 0x0211C, 0}, {"tau", 3, 0x003C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D51[] = { {"Wedge", 5, 0x022C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D54[] = { {"piv", 3, 0x003D6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D55[] = { {"hscr", 4, 0x1D4BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D56[] = { {"subdot", 6, 0x02ABD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D57[] = { {"dsol", 4, 0x029F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D5A[] = { {"prnE", 4, 0x02AB5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D5B[] = { {"qopf", 4, 0x1D562, 0}, {"vdash", 5, 0x022A2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D5F[] = { {"Star", 4, 0x022C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D63[] = { {"sqsupseteq", 10, 0x02292, 0}, {"zhcy", 4, 0x00436, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D65[] = { {"nacute", 6, 0x00144, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D69[] = { {"lessgtr", 7, 0x02276, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D6A[] = { {"nless", 5, 0x0226E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D6C[] = { {"RightTeeArrow", 13, 0x021A6, 0}, {"Yuml", 4, 0x00178, 0}, {"target", 6, 0x02316, 0}, {"upharpoonleft", 13, 0x021BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D6F[] = { {"between", 7, 0x0226C, 0}, {"boxuL", 5, 0x0255B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D70[] = { {"TSHcy", 5, 0x0040B, 0}, {"lrm", 3, 0x0200E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D71[] = { {"excl", 4, 0x00021, 0}, {"hyphen", 6, 0x02010, 0}, {"mlcp", 4, 0x02ADB, 0}, {"wedge", 5, 0x02227, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D74[] = { {"ncedil", 6, 0x00146, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D75[] = { {"boxuR", 5, 0x02558, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D76[] = { {"Not", 3, 0x02AEC, 0}, {"epsi", 4, 0x003B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D7C[] = { {"disin", 5, 0x022F2, 0}, {"nRightarrow", 11, 0x021CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D7D[] = { {"cylcty", 6, 0x0232D, 0}, {"neArr", 5, 0x021D7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D7E[] = { {"prnsim", 6, 0x022E8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D80[] = { {"Cfr", 3, 0x0212D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D81[] = { {"Beta", 4, 0x00392, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D85[] = { {"leftarrowtail", 13, 0x021A2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D87[] = { {"parsl", 5, 0x02AFD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D89[] = { {"xwedge", 6, 0x022C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D8A[] = { {"olcross", 7, 0x029BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D8C[] = { {"boxvH", 5, 0x0256A, 0}, {"lsh", 3, 0x021B0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D8D[] = { {"circledR", 8, 0x000AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D8E[] = { {"Rho", 3, 0x003A1, 0}, {"circledS", 8, 0x024C8, 0}, {"cupor", 5, 0x02A45, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D8F[] = { {"Ugrave", 6, 0x000D9, 0}, {"boxul", 5, 0x02518, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D90[] = { {"boxvL", 5, 0x02561, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D91[] = { {"sqcup", 5, 0x02294, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D93[] = { {"rect", 4, 0x025AD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D94[] = { {"mldr", 4, 0x02026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D95[] = { {"boxur", 5, 0x02514, 0}, {"digamma", 7, 0x003DD, 0}, {"tcy", 3, 0x00442, 0}, {"urcorner", 8, 0x0231D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D96[] = { {"DoubleLeftArrow", 15, 0x021D0, 0}, {"Iscr", 4, 0x02110, 0}, {"boxvR", 5, 0x0255E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D98[] = { {"ulcorn", 6, 0x0231C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D9A[] = { {"prod", 4, 0x0220F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_D9C[] = { {"Ropf", 4, 0x0211D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DA0[] = { {"rmoustache", 10, 0x023B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DA5[] = { {"NegativeMediumSpace", 19, 0x0200B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DA6[] = { {"prop", 4, 0x0221D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DA8[] = { {"TScy", 4, 0x00426, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DA9[] = { {"xsqcup", 6, 0x02A06, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DAC[] = { {"bemptyv", 7, 0x029B0, 0}, {"boxvh", 5, 0x0253C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DB0[] = { {"boxvl", 5, 0x02524, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DB3[] = { {"NotTildeFullEqual", 17, 0x02247, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DB4[] = { {"subE", 4, 0x02AC5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DB6[] = { {"boxvr", 5, 0x0251C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DB7[] = { {"bigvee", 6, 0x022C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DB9[] = { {"Chi", 3, 0x003A7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DBC[] = { {"circeq", 6, 0x02257, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DBE[] = { {"emsp13", 6, 0x02004, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DBF[] = { {"emsp14", 6, 0x02005, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DC2[] = { {"ouml", 4, 0x000F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DC3[] = { {"RightArrowBar", 13, 0x021E5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DC6[] = { {"ecy", 3, 0x0044D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DC8[] = { {"succneqq", 8, 0x02AB6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DCA[] = { {"npart", 5, 0x02202, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DCF[] = { {"Element", 7, 0x02208, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DD1[] = { {"Edot", 4, 0x00116, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DD3[] = { {"RightUpDownVector", 17, 0x0294F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DD4[] = { {"sube", 4, 0x02286, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DD5[] = { {"jsercy", 6, 0x00458, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DD7[] = { {"varrho", 6, 0x003F1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DD9[] = { {"subsub", 6, 0x02AD5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DDC[] = { {"Dcaron", 6, 0x0010E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DDD[] = { {"Eogon", 5, 0x00118, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DE4[] = { {"geqslant", 8, 0x02A7E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DE6[] = { {"rdldhar", 7, 0x02969, 0}, {"zdot", 4, 0x0017C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DE7[] = { {"subsup", 6, 0x02AD3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DE9[] = { {"ograve", 6, 0x000F2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DEB[] = { {"ReverseElement", 14, 0x0220B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DED[] = { {"drcorn", 6, 0x0231F, 0}, {"rang", 4, 0x027E9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DF1[] = { {"tfr", 3, 0x1D531, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DF2[] = { {"hopf", 4, 0x1D559, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DF3[] = { {"succ", 4, 0x0227B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DF6[] = { {"otimes", 6, 0x02297, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DF7[] = { {"Vcy", 3, 0x00412, 0}, {"ltquest", 7, 0x02A7B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DF9[] = { {"lozenge", 7, 0x025CA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DFB[] = { {"LeftDownVector", 14, 0x021C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_DFD[] = { {"eogon", 5, 0x00119, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E03[] = { {"amp", 3, 0x00026, 0}, {"lopar", 5, 0x02985, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E04[] = { {"loplus", 6, 0x02A2D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E08[] = { {"NotTilde", 8, 0x02241, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E09[] = { {"CounterClockwiseContourIntegral", 31, 0x02233, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E0C[] = { {"InvisibleTimes", 14, 0x02062, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E11[] = { {"lesdotor", 8, 0x02A83, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E18[] = { {"and", 3, 0x02227, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E1B[] = { {"RightUpVector", 13, 0x021BE, 0}, {"ang", 3, 0x02220, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E1C[] = { {"DoubleRightTee", 14, 0x022A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E1D[] = { {"LeftUpVectorBar", 15, 0x02958, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E1E[] = { {"smte", 4, 0x02AAC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E20[] = { {"Iacute", 6, 0x000CD, 0}, {"triminus", 8, 0x02A3A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E22[] = { {"efr", 3, 0x1D522, 0}, {"iiint", 5, 0x0222D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E23[] = { {"ctdot", 5, 0x022EF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E24[] = { {"mnplus", 6, 0x02213, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E25[] = { {"Vee", 3, 0x022C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E28[] = { {"Gcy", 3, 0x00413, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E2A[] = { {"lurdshar", 8, 0x0294A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E2C[] = { {"smeparsl", 8, 0x029E4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E2F[] = { {"DoubleVerticalBar", 17, 0x02225, 0}, {"iecy", 4, 0x00435, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E30[] = { {"udblac", 6, 0x00171, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E32[] = { {"gtquest", 7, 0x02A7C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E33[] = { {"Iopf", 4, 0x1D540, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E35[] = { {"bsime", 5, 0x022CD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E36[] = { {"RightVector", 11, 0x021C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E37[] = { {"NotGreaterLess", 14, 0x02279, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E3B[] = { {"apE", 3, 0x02A70, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E41[] = { {"CupCap", 6, 0x0224D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E42[] = { {"uscr", 4, 0x1D4CA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E43[] = { {"erDot", 5, 0x02253, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E44[] = { {"egs", 3, 0x02A96, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E48[] = { {"rlarr", 5, 0x021C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E4C[] = { {"prE", 3, 0x02AB3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E4E[] = { {"QUOT", 4, 0x00022, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E53[] = { {"Vfr", 3, 0x1D519, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E55[] = { {"cupbrcap", 8, 0x02A48, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E57[] = { {"intercal", 8, 0x022BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E58[] = { {"imath", 5, 0x00131, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E59[] = { {"RightUpTeeVector", 16, 0x0295C, 0}, {"trie", 4, 0x0225C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E5B[] = { {"ape", 3, 0x0224A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E5D[] = { {"softcy", 6, 0x0044C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E5E[] = { {"rarrb", 5, 0x021E5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E5F[] = { {"FilledSmallSquare", 17, 0x025FC, 0}, {"rarrc", 5, 0x02933, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E60[] = { {"Superset", 8, 0x02283, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E61[] = { {"hoarr", 5, 0x021FF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E63[] = { {"DownRightVectorBar", 18, 0x02957, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E64[] = { {"brvbar", 6, 0x000A6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E65[] = { {"ecolon", 6, 0x02255, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E66[] = { {"GreaterLess", 11, 0x02277, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E6A[] = { {"nrArr", 5, 0x021CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E6C[] = { {"pre", 3, 0x02AAF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E6F[] = { {"aleph", 5, 0x02135, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E70[] = { {"DiacriticalAcute", 16, 0x000B4, 0}, {"SmallCircle", 11, 0x02218, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E71[] = { {"parsim", 6, 0x02AF3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E73[] = { {"rarrw", 5, 0x0219D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E78[] = { {"caron", 5, 0x002C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E7A[] = { {"cacute", 6, 0x00107, 0}, {"lagran", 6, 0x02112, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E7C[] = { {"rarr", 4, 0x02192, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E80[] = { {"Rrightarrow", 11, 0x021DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E83[] = { {"Vscr", 4, 0x1D4B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E84[] = { {"Gfr", 3, 0x1D50A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E89[] = { {"ccedil", 6, 0x000E7, 0}, {"propto", 6, 0x0221D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E8E[] = { {"zwnj", 4, 0x0200C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E91[] = { {"psi", 3, 0x003C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E99[] = { {"infin", 5, 0x0221E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_E9C[] = { {"circledcirc", 11, 0x0229A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EA1[] = { {"Proportion", 10, 0x02237, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EA2[] = { {"subseteqq", 9, 0x02AC5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EA4[] = { {"nGtv", 4, 0x0226B, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EA8[] = { {"macr", 4, 0x000AF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EA9[] = { {"orslope", 7, 0x02A57, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EB1[] = { {"frown", 5, 0x02322, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EB2[] = { {"Iota", 4, 0x00399, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EB4[] = { {"rceil", 5, 0x02309, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EB7[] = { {"spadesuit", 9, 0x02660, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EB8[] = { {"sstarf", 6, 0x022C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ECA[] = { {"icy", 3, 0x00438, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ECD[] = { {"ast", 3, 0x0002A, 0}, {"nmid", 4, 0x02224, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ECF[] = { {"bowtie", 6, 0x022C8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ED1[] = { {"thetav", 6, 0x003D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ED7[] = { {"vangrt", 6, 0x0299C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ED8[] = { {"numsp", 5, 0x02007, 0}, {"triplus", 7, 0x02A39, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_ED9[] = { {"lscr", 4, 0x1D4C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EDA[] = { {"pointint", 8, 0x02A15, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EDB[] = { {"Theta", 5, 0x00398, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EDF[] = { {"rightrightarrows", 16, 0x021C9, 0}, {"uopf", 4, 0x1D566, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EE2[] = { {"ell", 3, 0x02113, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EE4[] = { {"cuepr", 5, 0x022DE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EE5[] = { {"NotVerticalBar", 14, 0x02224, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EE7[] = { {"xnis", 4, 0x022FB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EE9[] = { {"els", 3, 0x02A95, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EEF[] = { {"DDotrahd", 8, 0x02911, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EF1[] = { {"larrbfs", 7, 0x0291F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EF2[] = { {"Rsh", 3, 0x021B1, 0}, {"boxplus", 7, 0x0229E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EF4[] = { {"swarr", 5, 0x02199, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EF5[] = { {"gvnE", 4, 0x02269, 0x0FE00}, {"xfr", 3, 0x1D535, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EF9[] = { {"ldca", 4, 0x02936, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EFB[] = { {"NotPrecedesSlantEqual", 21, 0x022E0, 0}, {"YAcy", 4, 0x0042F, 0}, {"Zcy", 3, 0x00417, 0}, {"andslope", 8, 0x02A58, 0}, {"numero", 6, 0x02116, 0}, {"theta", 5, 0x003B8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EFE[] = { {"mapstoup", 8, 0x021A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_EFF[] = { {"bigcup", 6, 0x022C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F03[] = { {"nesear", 6, 0x02928, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F05[] = { {"lesssim", 7, 0x02272, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F08[] = { {"DownArrow", 9, 0x02193, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F0B[] = { {"orarr", 5, 0x021BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F0F[] = { {"ccaps", 5, 0x02A4D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F10[] = { {"xdtri", 5, 0x025BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F11[] = { {"xcap", 4, 0x022C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F13[] = { {"downdownarrows", 14, 0x021CA, 0}, {"nisd", 4, 0x022FA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F14[] = { {"VerticalBar", 11, 0x02223, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F15[] = { {"TRADE", 5, 0x02122, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F17[] = { {"Omacr", 5, 0x0014C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F18[] = { {"top", 3, 0x022A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F19[] = { {"LeftRightArrow", 14, 0x02194, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F1A[] = { {"Mscr", 4, 0x02133, 0}, {"iff", 3, 0x021D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F1F[] = { {"downharpoonleft", 15, 0x021C3, 0}, {"eng", 3, 0x0014B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F20[] = { {"Vopf", 4, 0x1D54D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F26[] = { {"ifr", 3, 0x1D526, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F28[] = { {"Downarrow", 9, 0x021D3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F2C[] = { {"Kcy", 3, 0x0041A, 0}, {"angle", 5, 0x02220, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F2F[] = { {"lescc", 5, 0x02AA8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F30[] = { {"lesseqqgtr", 10, 0x02A8B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F31[] = { {"bigstar", 7, 0x02605, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F33[] = { {"ddagger", 7, 0x02021, 0}, {"nltrie", 6, 0x022EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F37[] = { {"omacr", 5, 0x0014D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F38[] = { {"cuesc", 5, 0x022DF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F40[] = { {"circlearrowright", 16, 0x021BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F41[] = { {"ngeqq", 5, 0x02267, 0x00338}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F44[] = { {"squf", 4, 0x025AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F46[] = { {"rtri", 4, 0x025B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F47[] = { {"VerticalLine", 12, 0x0007C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F48[] = { {"downarrow", 9, 0x02193, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F4B[] = { {"Scaron", 6, 0x00160, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F4C[] = { {"tstrok", 6, 0x00167, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F50[] = { {"wreath", 6, 0x02240, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F51[] = { {"exponentiale", 12, 0x02147, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F55[] = { {"Idot", 4, 0x00130, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F57[] = { {"Zfr", 3, 0x02128, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F58[] = { {"bnot", 4, 0x02310, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F5B[] = { {"infintie", 8, 0x029DD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F5D[] = { {"angrtvbd", 8, 0x0299D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F5F[] = { {"prurel", 6, 0x022B0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F60[] = { {"gbreve", 6, 0x0011F, 0}, {"rsaquo", 6, 0x0203A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F62[] = { {"sung", 4, 0x0266A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F67[] = { {"lvertneqq", 9, 0x02268, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F68[] = { {"lnsim", 5, 0x022E6, 0}, {"searrow", 7, 0x02198, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F69[] = { {"nsubset", 7, 0x02282, 0x020D2}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F6D[] = { {"Cup", 3, 0x022D3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F6E[] = { {"Lmidot", 6, 0x0013F, 0}, {"sup1", 4, 0x000B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F6F[] = { {"Delta", 5, 0x00394, 0}, {"sbquo", 5, 0x0201A, 0}, {"sup2", 4, 0x000B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F70[] = { {"cscr", 4, 0x1D4B8, 0}, {"nsubseteqq", 10, 0x02AC5, 0x00338}, {"sup3", 4, 0x000B3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F71[] = { {"Kcedil", 6, 0x00136, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F72[] = { {"plussim", 7, 0x02A26, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F74[] = { {"KHcy", 4, 0x00425, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F75[] = { {"OElig", 5, 0x00152, 0}, {"simdot", 6, 0x02A6A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F76[] = { {"lopf", 4, 0x1D55D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F77[] = { {"boxbox", 6, 0x029C9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F78[] = { {"bepsi", 5, 0x003F6, 0}, {"lbarr", 5, 0x0290C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F79[] = { {"lnapprox", 8, 0x02A89, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F81[] = { {"sdotb", 5, 0x022A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F82[] = { {"measuredangle", 13, 0x02221, 0}, {"supE", 4, 0x02AC6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F83[] = { {"map", 3, 0x021A6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F84[] = { {"sdote", 5, 0x02A66, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F86[] = { {"diamondsuit", 11, 0x02666, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F88[] = { {"Kfr", 3, 0x1D50E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F8B[] = { {"imagline", 8, 0x02110, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F8F[] = { {"delta", 5, 0x003B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F91[] = { {"mapstodown", 10, 0x021A7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F93[] = { {"eqvparsl", 8, 0x029E5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F95[] = { {"UpArrow", 7, 0x02191, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F9A[] = { {"imagpart", 8, 0x02111, 0}, {"lsim", 4, 0x02272, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F9C[] = { {"trianglelefteq", 14, 0x022B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_F9F[] = { {"isindot", 7, 0x022F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FA0[] = { {"LeftUpDownVector", 16, 0x02951, 0}, {"curvearrowleft", 14, 0x021B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FA1[] = { {"Diamond", 7, 0x022C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FA2[] = { {"supe", 4, 0x02287, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FA3[] = { {"nearrow", 7, 0x02197, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FA9[] = { {"easter", 6, 0x02A6E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB0[] = { {"rdquo", 5, 0x0201D, 0}, {"subsetneqq", 10, 0x02ACB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB1[] = { {"Dscr", 4, 0x1D49F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB4[] = { {"comp", 4, 0x02201, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB5[] = { {"Uparrow", 7, 0x021D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB6[] = { {"coloneq", 7, 0x02254, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB7[] = { {"Mopf", 4, 0x1D544, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FB9[] = { {"rfloor", 6, 0x0230B, 0}, {"varsubsetneqq", 13, 0x02ACB, 0x0FE00}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FBC[] = { {"eacute", 6, 0x000E9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FC2[] = { {"shortparallel", 13, 0x02225, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FC4[] = { {"male", 4, 0x02642, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FC6[] = { {"yscr", 4, 0x1D4CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FCA[] = { {"xharr", 5, 0x027F7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FCC[] = { {"cong", 4, 0x02245, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FCE[] = { {"mcy", 3, 0x0043C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FCF[] = { {"Upsilon", 7, 0x003A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FD0[] = { {"block", 5, 0x02588, 0}, {"maltese", 7, 0x02720, 0}, {"ordf", 4, 0x000AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FD2[] = { {"zcaron", 6, 0x0017E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FD3[] = { {"malt", 4, 0x02720, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FD6[] = { {"loang", 5, 0x027EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FD7[] = { {"ordm", 4, 0x000BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FDD[] = { {"NegativeVeryThinSpace", 21, 0x0200B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FDF[] = { {"eta", 3, 0x003B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FE1[] = { {"Iogon", 5, 0x0012E, 0}, {"drbkarow", 8, 0x02910, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FE6[] = { {"eth", 3, 0x000F0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FE9[] = { {"racute", 6, 0x00155, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FEA[] = { {"cwconint", 8, 0x02232, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FEB[] = { {"egsdot", 6, 0x02A98, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FF5[] = { {"MinusPlus", 9, 0x02213, 0}, {"ring", 4, 0x002DA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FF8[] = { {"rcedil", 6, 0x00157, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FFC[] = { {"timesbar", 8, 0x02A31, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html5_FFE[] = { {"GreaterEqualLess", 16, 0x022DB, 0}, {NULL, 0, 0, 0} }; static const entity_cp_map *const ht_buckets_html5[] = { ht_bucket_html5_000, ht_bucket_html5_001, ht_bucket_empty, ht_bucket_html5_003, @@ -5332,402 +5332,402 @@ static const entity_ht ent_ht_html5 = { /* {{{ Stage 3 Tables for HTML 4.01 */ static const entity_stage3_row stage3_table_html4_00000[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "quot", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "amp", 3}, {0, "#039", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lt", 2}, {0, NULL, 0}, {0, "gt", 2}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"quot", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"amp", 3} } }, {0, { {"#039", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lt", 2} } }, {0, { {NULL, 0} } }, {0, { {"gt", 2} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_00080[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "nbsp", 4}, {0, "iexcl", 5}, {0, "cent", 4}, {0, "pound", 5}, - {0, "curren", 6}, {0, "yen", 3}, {0, "brvbar", 6}, {0, "sect", 4}, - {0, "uml", 3}, {0, "copy", 4}, {0, "ordf", 4}, {0, "laquo", 5}, - {0, "not", 3}, {0, "shy", 3}, {0, "reg", 3}, {0, "macr", 4}, - {0, "deg", 3}, {0, "plusmn", 6}, {0, "sup2", 4}, {0, "sup3", 4}, - {0, "acute", 5}, {0, "micro", 5}, {0, "para", 4}, {0, "middot", 6}, - {0, "cedil", 5}, {0, "sup1", 4}, {0, "ordm", 4}, {0, "raquo", 5}, - {0, "frac14", 6}, {0, "frac12", 6}, {0, "frac34", 6}, {0, "iquest", 6}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"nbsp", 4} } }, {0, { {"iexcl", 5} } }, {0, { {"cent", 4} } }, {0, { {"pound", 5} } }, + {0, { {"curren", 6} } }, {0, { {"yen", 3} } }, {0, { {"brvbar", 6} } }, {0, { {"sect", 4} } }, + {0, { {"uml", 3} } }, {0, { {"copy", 4} } }, {0, { {"ordf", 4} } }, {0, { {"laquo", 5} } }, + {0, { {"not", 3} } }, {0, { {"shy", 3} } }, {0, { {"reg", 3} } }, {0, { {"macr", 4} } }, + {0, { {"deg", 3} } }, {0, { {"plusmn", 6} } }, {0, { {"sup2", 4} } }, {0, { {"sup3", 4} } }, + {0, { {"acute", 5} } }, {0, { {"micro", 5} } }, {0, { {"para", 4} } }, {0, { {"middot", 6} } }, + {0, { {"cedil", 5} } }, {0, { {"sup1", 4} } }, {0, { {"ordm", 4} } }, {0, { {"raquo", 5} } }, + {0, { {"frac14", 6} } }, {0, { {"frac12", 6} } }, {0, { {"frac34", 6} } }, {0, { {"iquest", 6} } }, }; static const entity_stage3_row stage3_table_html4_000C0[] = { - {0, "Agrave", 6}, {0, "Aacute", 6}, {0, "Acirc", 5}, {0, "Atilde", 6}, - {0, "Auml", 4}, {0, "Aring", 5}, {0, "AElig", 5}, {0, "Ccedil", 6}, - {0, "Egrave", 6}, {0, "Eacute", 6}, {0, "Ecirc", 5}, {0, "Euml", 4}, - {0, "Igrave", 6}, {0, "Iacute", 6}, {0, "Icirc", 5}, {0, "Iuml", 4}, - {0, "ETH", 3}, {0, "Ntilde", 6}, {0, "Ograve", 6}, {0, "Oacute", 6}, - {0, "Ocirc", 5}, {0, "Otilde", 6}, {0, "Ouml", 4}, {0, "times", 5}, - {0, "Oslash", 6}, {0, "Ugrave", 6}, {0, "Uacute", 6}, {0, "Ucirc", 5}, - {0, "Uuml", 4}, {0, "Yacute", 6}, {0, "THORN", 5}, {0, "szlig", 5}, - {0, "agrave", 6}, {0, "aacute", 6}, {0, "acirc", 5}, {0, "atilde", 6}, - {0, "auml", 4}, {0, "aring", 5}, {0, "aelig", 5}, {0, "ccedil", 6}, - {0, "egrave", 6}, {0, "eacute", 6}, {0, "ecirc", 5}, {0, "euml", 4}, - {0, "igrave", 6}, {0, "iacute", 6}, {0, "icirc", 5}, {0, "iuml", 4}, - {0, "eth", 3}, {0, "ntilde", 6}, {0, "ograve", 6}, {0, "oacute", 6}, - {0, "ocirc", 5}, {0, "otilde", 6}, {0, "ouml", 4}, {0, "divide", 6}, - {0, "oslash", 6}, {0, "ugrave", 6}, {0, "uacute", 6}, {0, "ucirc", 5}, - {0, "uuml", 4}, {0, "yacute", 6}, {0, "thorn", 5}, {0, "yuml", 4}, + {0, { {"Agrave", 6} } }, {0, { {"Aacute", 6} } }, {0, { {"Acirc", 5} } }, {0, { {"Atilde", 6} } }, + {0, { {"Auml", 4} } }, {0, { {"Aring", 5} } }, {0, { {"AElig", 5} } }, {0, { {"Ccedil", 6} } }, + {0, { {"Egrave", 6} } }, {0, { {"Eacute", 6} } }, {0, { {"Ecirc", 5} } }, {0, { {"Euml", 4} } }, + {0, { {"Igrave", 6} } }, {0, { {"Iacute", 6} } }, {0, { {"Icirc", 5} } }, {0, { {"Iuml", 4} } }, + {0, { {"ETH", 3} } }, {0, { {"Ntilde", 6} } }, {0, { {"Ograve", 6} } }, {0, { {"Oacute", 6} } }, + {0, { {"Ocirc", 5} } }, {0, { {"Otilde", 6} } }, {0, { {"Ouml", 4} } }, {0, { {"times", 5} } }, + {0, { {"Oslash", 6} } }, {0, { {"Ugrave", 6} } }, {0, { {"Uacute", 6} } }, {0, { {"Ucirc", 5} } }, + {0, { {"Uuml", 4} } }, {0, { {"Yacute", 6} } }, {0, { {"THORN", 5} } }, {0, { {"szlig", 5} } }, + {0, { {"agrave", 6} } }, {0, { {"aacute", 6} } }, {0, { {"acirc", 5} } }, {0, { {"atilde", 6} } }, + {0, { {"auml", 4} } }, {0, { {"aring", 5} } }, {0, { {"aelig", 5} } }, {0, { {"ccedil", 6} } }, + {0, { {"egrave", 6} } }, {0, { {"eacute", 6} } }, {0, { {"ecirc", 5} } }, {0, { {"euml", 4} } }, + {0, { {"igrave", 6} } }, {0, { {"iacute", 6} } }, {0, { {"icirc", 5} } }, {0, { {"iuml", 4} } }, + {0, { {"eth", 3} } }, {0, { {"ntilde", 6} } }, {0, { {"ograve", 6} } }, {0, { {"oacute", 6} } }, + {0, { {"ocirc", 5} } }, {0, { {"otilde", 6} } }, {0, { {"ouml", 4} } }, {0, { {"divide", 6} } }, + {0, { {"oslash", 6} } }, {0, { {"ugrave", 6} } }, {0, { {"uacute", 6} } }, {0, { {"ucirc", 5} } }, + {0, { {"uuml", 4} } }, {0, { {"yacute", 6} } }, {0, { {"thorn", 5} } }, {0, { {"yuml", 4} } }, }; static const entity_stage3_row stage3_table_html4_00140[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "OElig", 5}, {0, "oelig", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Scaron", 6}, {0, "scaron", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "Yuml", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"OElig", 5} } }, {0, { {"oelig", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Scaron", 6} } }, {0, { {"scaron", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"Yuml", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_00180[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "fnof", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"fnof", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_002C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "circ", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "tilde", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"circ", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"tilde", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_00380[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "Alpha", 5}, {0, "Beta", 4}, {0, "Gamma", 5}, - {0, "Delta", 5}, {0, "Epsilon", 7}, {0, "Zeta", 4}, {0, "Eta", 3}, - {0, "Theta", 5}, {0, "Iota", 4}, {0, "Kappa", 5}, {0, "Lambda", 6}, - {0, "Mu", 2}, {0, "Nu", 2}, {0, "Xi", 2}, {0, "Omicron", 7}, - {0, "Pi", 2}, {0, "Rho", 3}, {0, NULL, 0}, {0, "Sigma", 5}, - {0, "Tau", 3}, {0, "Upsilon", 7}, {0, "Phi", 3}, {0, "Chi", 3}, - {0, "Psi", 3}, {0, "Omega", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "alpha", 5}, {0, "beta", 4}, {0, "gamma", 5}, - {0, "delta", 5}, {0, "epsilon", 7}, {0, "zeta", 4}, {0, "eta", 3}, - {0, "theta", 5}, {0, "iota", 4}, {0, "kappa", 5}, {0, "lambda", 6}, - {0, "mu", 2}, {0, "nu", 2}, {0, "xi", 2}, {0, "omicron", 7}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"Alpha", 5} } }, {0, { {"Beta", 4} } }, {0, { {"Gamma", 5} } }, + {0, { {"Delta", 5} } }, {0, { {"Epsilon", 7} } }, {0, { {"Zeta", 4} } }, {0, { {"Eta", 3} } }, + {0, { {"Theta", 5} } }, {0, { {"Iota", 4} } }, {0, { {"Kappa", 5} } }, {0, { {"Lambda", 6} } }, + {0, { {"Mu", 2} } }, {0, { {"Nu", 2} } }, {0, { {"Xi", 2} } }, {0, { {"Omicron", 7} } }, + {0, { {"Pi", 2} } }, {0, { {"Rho", 3} } }, {0, { {NULL, 0} } }, {0, { {"Sigma", 5} } }, + {0, { {"Tau", 3} } }, {0, { {"Upsilon", 7} } }, {0, { {"Phi", 3} } }, {0, { {"Chi", 3} } }, + {0, { {"Psi", 3} } }, {0, { {"Omega", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"alpha", 5} } }, {0, { {"beta", 4} } }, {0, { {"gamma", 5} } }, + {0, { {"delta", 5} } }, {0, { {"epsilon", 7} } }, {0, { {"zeta", 4} } }, {0, { {"eta", 3} } }, + {0, { {"theta", 5} } }, {0, { {"iota", 4} } }, {0, { {"kappa", 5} } }, {0, { {"lambda", 6} } }, + {0, { {"mu", 2} } }, {0, { {"nu", 2} } }, {0, { {"xi", 2} } }, {0, { {"omicron", 7} } }, }; static const entity_stage3_row stage3_table_html4_003C0[] = { - {0, "pi", 2}, {0, "rho", 3}, {0, "sigmaf", 6}, {0, "sigma", 5}, - {0, "tau", 3}, {0, "upsilon", 7}, {0, "phi", 3}, {0, "chi", 3}, - {0, "psi", 3}, {0, "omega", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "thetasym", 8}, {0, "upsih", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "piv", 3}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"pi", 2} } }, {0, { {"rho", 3} } }, {0, { {"sigmaf", 6} } }, {0, { {"sigma", 5} } }, + {0, { {"tau", 3} } }, {0, { {"upsilon", 7} } }, {0, { {"phi", 3} } }, {0, { {"chi", 3} } }, + {0, { {"psi", 3} } }, {0, { {"omega", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"thetasym", 8} } }, {0, { {"upsih", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"piv", 3} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02000[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, "ensp", 4}, {0, "emsp", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "thinsp", 6}, {0, NULL, 0}, {0, NULL, 0}, - {0, "zwnj", 4}, {0, "zwj", 3}, {0, "lrm", 3}, {0, "rlm", 3}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "ndash", 5}, - {0, "mdash", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lsquo", 5}, {0, "rsquo", 5}, {0, "sbquo", 5}, {0, NULL, 0}, - {0, "ldquo", 5}, {0, "rdquo", 5}, {0, "bdquo", 5}, {0, NULL, 0}, - {0, "dagger", 6}, {0, "Dagger", 6}, {0, "bull", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "hellip", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "permil", 6}, {0, NULL, 0}, {0, "prime", 5}, {0, "Prime", 5}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "lsaquo", 6}, {0, "rsaquo", 6}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "oline", 5}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"ensp", 4} } }, {0, { {"emsp", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"thinsp", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"zwnj", 4} } }, {0, { {"zwj", 3} } }, {0, { {"lrm", 3} } }, {0, { {"rlm", 3} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"ndash", 5} } }, + {0, { {"mdash", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lsquo", 5} } }, {0, { {"rsquo", 5} } }, {0, { {"sbquo", 5} } }, {0, { {NULL, 0} } }, + {0, { {"ldquo", 5} } }, {0, { {"rdquo", 5} } }, {0, { {"bdquo", 5} } }, {0, { {NULL, 0} } }, + {0, { {"dagger", 6} } }, {0, { {"Dagger", 6} } }, {0, { {"bull", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"hellip", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"permil", 6} } }, {0, { {NULL, 0} } }, {0, { {"prime", 5} } }, {0, { {"Prime", 5} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"lsaquo", 6} } }, {0, { {"rsaquo", 6} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"oline", 5} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02040[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "frasl", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"frasl", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02080[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "euro", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"euro", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02100[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "image", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "weierp", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "real", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "trade", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "alefsym", 7}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"image", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"weierp", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"real", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"trade", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"alefsym", 7} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02180[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "larr", 4}, {0, "uarr", 4}, {0, "rarr", 4}, {0, "darr", 4}, - {0, "harr", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "crarr", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"larr", 4} } }, {0, { {"uarr", 4} } }, {0, { {"rarr", 4} } }, {0, { {"darr", 4} } }, + {0, { {"harr", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"crarr", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_021C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lArr", 4}, {0, "uArr", 4}, {0, "rArr", 4}, {0, "dArr", 4}, - {0, "hArr", 4}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lArr", 4} } }, {0, { {"uArr", 4} } }, {0, { {"rArr", 4} } }, {0, { {"dArr", 4} } }, + {0, { {"hArr", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02200[] = { - {0, "forall", 6}, {0, NULL, 0}, {0, "part", 4}, {0, "exist", 5}, - {0, NULL, 0}, {0, "empty", 5}, {0, NULL, 0}, {0, "nabla", 5}, - {0, "isin", 4}, {0, "notin", 5}, {0, NULL, 0}, {0, "ni", 2}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "prod", 4}, - {0, NULL, 0}, {0, "sum", 3}, {0, "minus", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "lowast", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, "radic", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, "prop", 4}, {0, "infin", 5}, {0, NULL, 0}, - {0, "ang", 3}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, "and", 3}, - {0, "or", 2}, {0, "cap", 3}, {0, "cup", 3}, {0, "int", 3}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "there4", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "sim", 3}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {"forall", 6} } }, {0, { {NULL, 0} } }, {0, { {"part", 4} } }, {0, { {"exist", 5} } }, + {0, { {NULL, 0} } }, {0, { {"empty", 5} } }, {0, { {NULL, 0} } }, {0, { {"nabla", 5} } }, + {0, { {"isin", 4} } }, {0, { {"notin", 5} } }, {0, { {NULL, 0} } }, {0, { {"ni", 2} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"prod", 4} } }, + {0, { {NULL, 0} } }, {0, { {"sum", 3} } }, {0, { {"minus", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"lowast", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"radic", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"prop", 4} } }, {0, { {"infin", 5} } }, {0, { {NULL, 0} } }, + {0, { {"ang", 3} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"and", 3} } }, + {0, { {"or", 2} } }, {0, { {"cap", 3} } }, {0, { {"cup", 3} } }, {0, { {"int", 3} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"there4", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"sim", 3} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02240[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "cong", 4}, {0, NULL, 0}, {0, NULL, 0}, - {0, "asymp", 5}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "ne", 2}, {0, "equiv", 5}, {0, NULL, 0}, {0, NULL, 0}, - {0, "le", 2}, {0, "ge", 2}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"cong", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"asymp", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"ne", 2} } }, {0, { {"equiv", 5} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"le", 2} } }, {0, { {"ge", 2} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02280[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, "sub", 3}, {0, "sup", 3}, - {0, "nsub", 4}, {0, NULL, 0}, {0, "sube", 4}, {0, "supe", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "oplus", 5}, {0, NULL, 0}, {0, "otimes", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "perp", 4}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"sub", 3} } }, {0, { {"sup", 3} } }, + {0, { {"nsub", 4} } }, {0, { {NULL, 0} } }, {0, { {"sube", 4} } }, {0, { {"supe", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"oplus", 5} } }, {0, { {NULL, 0} } }, {0, { {"otimes", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"perp", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_022C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "sdot", 4}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"sdot", 4} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02300[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lceil", 5}, {0, "rceil", 5}, {0, "lfloor", 6}, {0, "rfloor", 6}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, "lang", 4}, {0, "rang", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lceil", 5} } }, {0, { {"rceil", 5} } }, {0, { {"lfloor", 6} } }, {0, { {"rfloor", 6} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {"lang", 4} } }, {0, { {"rang", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_025C0[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "loz", 3}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"loz", 3} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; static const entity_stage3_row stage3_table_html4_02640[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "spades", 6}, {0, NULL, 0}, {0, NULL, 0}, {0, "clubs", 5}, - {0, NULL, 0}, {0, "hearts", 6}, {0, "diams", 5}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"spades", 6} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"clubs", 5} } }, + {0, { {NULL, 0} } }, {0, { {"hearts", 6} } }, {0, { {"diams", 5} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, }; /* end of stage 3 Tables for HTML 4.01 }}} */ @@ -5811,199 +5811,199 @@ static const entity_stage1_row entity_ms_table_html4[] = { /* {{{ HTML 4.01 hash table for entity -> codepoint */ -static const entity_cp_map ht_bucket_html4_000[] = { {"gt", 2, 0x0003E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_003[] = { {"Igrave", 6, 0x000CC, 0}, {"amp", 3, 0x00026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_006[] = { {"oacute", 6, 0x000F3, 0}, {"Xi", 2, 0x0039E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_008[] = { {"uuml", 4, 0x000FC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_00B[] = { {"Alpha", 5, 0x00391, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_00E[] = { {"sim", 3, 0x0223C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_012[] = { {"kappa", 5, 0x003BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_016[] = { {"lArr", 4, 0x021D0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_018[] = { {"and", 3, 0x02227, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_01B[] = { {"ang", 3, 0x02220, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_020[] = { {"copy", 4, 0x000A9, 0}, {"Iacute", 6, 0x000CD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_023[] = { {"igrave", 6, 0x000EC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_026[] = { {"xi", 2, 0x003BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_027[] = { {"Acirc", 5, 0x000C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_02B[] = { {"Ecirc", 5, 0x000CA, 0}, {"alpha", 5, 0x003B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_02C[] = { {"hearts", 6, 0x02665, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_02F[] = { {"Icirc", 5, 0x000CE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_030[] = { {"Yacute", 6, 0x000DD, 0}, {"int", 3, 0x0222B, 0}, {"rlm", 3, 0x0200F, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_034[] = { {"empty", 5, 0x02205, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_036[] = { {"larr", 4, 0x02190, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_03B[] = { {"Ucirc", 5, 0x000DB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_03C[] = { {"oline", 5, 0x0203E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_040[] = { {"iacute", 6, 0x000ED, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_046[] = { {"middot", 6, 0x000B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_047[] = { {"acirc", 5, 0x000E2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_04B[] = { {"ecirc", 5, 0x000EA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_04F[] = { {"icirc", 5, 0x000EE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_050[] = { {"yacute", 6, 0x000FD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_051[] = { {"minus", 5, 0x02212, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_054[] = { {"Auml", 4, 0x000C4, 0}, {"thetasym", 8, 0x003D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_056[] = { {"Sigma", 5, 0x003A3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_059[] = { {"lsquo", 5, 0x02018, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_05B[] = { {"ucirc", 5, 0x000FB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_05C[] = { {"rArr", 4, 0x021D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_064[] = { {"brvbar", 6, 0x000A6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_067[] = { {"AElig", 5, 0x000C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_069[] = { {"Ccedil", 6, 0x000C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_071[] = { {"Psi", 3, 0x003A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_072[] = { {"exist", 5, 0x02203, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_074[] = { {"auml", 4, 0x000E4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_076[] = { {"sigma", 5, 0x003C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_078[] = { {"isin", 4, 0x02208, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_07C[] = { {"rarr", 4, 0x02192, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_089[] = { {"ccedil", 6, 0x000E7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_08D[] = { {"raquo", 5, 0x000BB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_08E[] = { {"Omega", 5, 0x003A9, 0}, {"zwnj", 4, 0x0200C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_091[] = { {"psi", 3, 0x003C8, 0}, {"there4", 6, 0x02234, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_092[] = { {"hArr", 4, 0x021D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_096[] = { {"le", 2, 0x02264, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_098[] = { {"Atilde", 6, 0x000C3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_099[] = { {"Zeta", 4, 0x00396, 0}, {"infin", 5, 0x0221E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_09D[] = { {"frasl", 5, 0x02044, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0A0[] = { {"euro", 4, 0x020AC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0A5[] = { {"lt", 2, 0x0003C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0A7[] = { {"aelig", 5, 0x000E6, 0}, {"Mu", 2, 0x0039C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0A8[] = { {"macr", 4, 0x000AF, 0}, {"image", 5, 0x02111, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0AA[] = { {"ldquo", 5, 0x0201C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0AE[] = { {"omega", 5, 0x003C9, 0}, {"upsih", 5, 0x003D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0B0[] = { {"THORN", 5, 0x000DE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0B2[] = { {"Iota", 4, 0x00399, 0}, {"harr", 4, 0x02194, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0B4[] = { {"bull", 4, 0x02022, 0}, {"rceil", 5, 0x02309, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0B8[] = { {"atilde", 6, 0x000E3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0B9[] = { {"zeta", 4, 0x003B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0BA[] = { {"emsp", 4, 0x02003, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0BC[] = { {"perp", 4, 0x022A5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0C2[] = { {"Prime", 5, 0x02033, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0C4[] = { {"frac12", 6, 0x000BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0C5[] = { {"Ntilde", 6, 0x000D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0C6[] = { {"frac14", 6, 0x000BC, 0}, {"circ", 4, 0x002C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0C7[] = { {"mu", 2, 0x003BC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0C8[] = { {"Gamma", 5, 0x00393, 0}, {"Nu", 2, 0x0039D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0CE[] = { {"fnof", 4, 0x00192, 0}, {"quot", 4, 0x00022, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0D2[] = { {"iota", 4, 0x003B9, 0}, {"mdash", 5, 0x02014, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0D8[] = { {"ne", 2, 0x02260, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0DB[] = { {"Theta", 5, 0x00398, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0DC[] = { {"ni", 2, 0x0220B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0E2[] = { {"prime", 5, 0x02032, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0E5[] = { {"ntilde", 6, 0x000F1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0E6[] = { {"Lambda", 6, 0x0039B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0E8[] = { {"gamma", 5, 0x003B3, 0}, {"nu", 2, 0x003BD, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0EB[] = { {"pound", 5, 0x000A3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0EE[] = { {"permil", 6, 0x02030, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0F9[] = { {"cap", 3, 0x02229, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0FA[] = { {"iexcl", 5, 0x000A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0FB[] = { {"Agrave", 6, 0x000C0, 0}, {"theta", 5, 0x003B8, 0}, {"ensp", 4, 0x02002, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0FE[] = { {"Pi", 2, 0x003A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_0FF[] = { {"crarr", 5, 0x021B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_100[] = { {"iquest", 6, 0x000BF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_105[] = { {"forall", 6, 0x02200, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_106[] = { {"Phi", 3, 0x003A6, 0}, {"lambda", 6, 0x003BB, 0}, {"or", 2, 0x02228, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_108[] = { {"frac34", 6, 0x000BE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_10D[] = { {"notin", 5, 0x02209, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_10E[] = { {"dArr", 4, 0x021D3, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_10F[] = { {"Dagger", 6, 0x02021, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_111[] = { {"yen", 3, 0x000A5, 0}, {"weierp", 6, 0x02118, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_113[] = { {"uml", 3, 0x000A8, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_117[] = { {"tilde", 5, 0x002DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_118[] = { {"Aacute", 6, 0x000C1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_11A[] = { {"loz", 3, 0x025CA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_11B[] = { {"agrave", 6, 0x000E0, 0}, {"thinsp", 6, 0x02009, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_11E[] = { {"pi", 2, 0x003C0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_11F[] = { {"micro", 5, 0x000B5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_125[] = { {"spades", 6, 0x02660, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_126[] = { {"phi", 3, 0x003C6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_12E[] = { {"darr", 4, 0x02193, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_12F[] = { {"Oslash", 6, 0x000D8, 0}, {"Tau", 3, 0x003A4, 0}, {"dagger", 6, 0x02020, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_135[] = { {"Ocirc", 5, 0x000D4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_136[] = { {"alefsym", 7, 0x02135, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_138[] = { {"aacute", 6, 0x000E1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_13A[] = { {"divide", 6, 0x000F7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_13F[] = { {"sdot", 4, 0x022C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_143[] = { {"reg", 3, 0x000AE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_149[] = { {"real", 4, 0x0211C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_14B[] = { {"Scaron", 6, 0x00160, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_14F[] = { {"cent", 4, 0x000A2, 0}, {"oslash", 6, 0x000F8, 0}, {"tau", 3, 0x003C4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_150[] = { {"thorn", 5, 0x000FE, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_153[] = { {"ndash", 5, 0x02013, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_154[] = { {"piv", 3, 0x003D6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_155[] = { {"ocirc", 5, 0x000F4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_156[] = { {"Aring", 5, 0x000C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_158[] = { {"nbsp", 4, 0x000A0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_15C[] = { {"Iuml", 4, 0x000CF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_15F[] = { {"rsquo", 5, 0x02019, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_160[] = { {"rsaquo", 6, 0x0203A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_163[] = { {"hellip", 6, 0x02026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_166[] = { {"Otilde", 6, 0x000D5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_16B[] = { {"scaron", 6, 0x00161, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_16C[] = { {"Yuml", 4, 0x00178, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_16E[] = { {"sup1", 4, 0x000B9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_16F[] = { {"sup2", 4, 0x000B2, 0}, {"Delta", 5, 0x00394, 0}, {"sbquo", 5, 0x0201A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_170[] = { {"sup3", 4, 0x000B3, 0}, {"lrm", 3, 0x0200E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_173[] = { {"diams", 5, 0x02666, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_175[] = { {"OElig", 5, 0x00152, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_176[] = { {"aring", 5, 0x000E5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_178[] = { {"oplus", 5, 0x02295, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_17C[] = { {"iuml", 4, 0x000EF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_17F[] = { {"Egrave", 6, 0x000C8, 0}, {"uArr", 4, 0x021D1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_181[] = { {"Beta", 4, 0x00392, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_183[] = { {"nabla", 5, 0x02207, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_186[] = { {"ETH", 3, 0x000D0, 0}, {"otilde", 6, 0x000F5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_187[] = { {"laquo", 5, 0x000AB, 0}, {"times", 5, 0x000D7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_18C[] = { {"yuml", 4, 0x000FF, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_18D[] = { {"cup", 3, 0x0222A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_18E[] = { {"Rho", 3, 0x003A1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_18F[] = { {"Ugrave", 6, 0x000D9, 0}, {"delta", 5, 0x003B4, 0}, {"equiv", 5, 0x02261, 0}, {"sub", 3, 0x02282, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_194[] = { {"curren", 6, 0x000A4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_196[] = { {"not", 3, 0x000AC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_197[] = { {"acute", 5, 0x000B4, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_19A[] = { {"prod", 4, 0x0220F, 0}, {"sum", 3, 0x02211, 0}, {"lsaquo", 6, 0x02039, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_19C[] = { {"Eacute", 6, 0x000C9, 0}, {"Omicron", 7, 0x0039F, 0}, {"sigmaf", 6, 0x003C2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_19D[] = { {"sup", 3, 0x02283, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_19F[] = { {"egrave", 6, 0x000E8, 0}, {"uarr", 4, 0x02191, 0}, {"lowast", 6, 0x02217, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A0[] = { {"zwj", 3, 0x0200D, 0}, {"bdquo", 5, 0x0201E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A1[] = { {"beta", 4, 0x003B2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A2[] = { {"Ouml", 4, 0x000D6, 0}, {"supe", 4, 0x02287, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A4[] = { {"plusmn", 6, 0x000B1, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A6[] = { {"cedil", 5, 0x000B8, 0}, {"prop", 4, 0x0221D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A7[] = { {"lang", 4, 0x02329, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A8[] = { {"radic", 5, 0x0221A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1A9[] = { {"para", 4, 0x000B6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1AC[] = { {"Uacute", 6, 0x000DA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1AE[] = { {"szlig", 5, 0x000DF, 0}, {"rho", 3, 0x003C1, 0}, {"lceil", 5, 0x02308, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1AF[] = { {"ugrave", 6, 0x000F9, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1B0[] = { {"rdquo", 5, 0x0201D, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1B5[] = { {"deg", 3, 0x000B0, 0}, {"trade", 5, 0x02122, 0}, {"oelig", 5, 0x00153, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1B9[] = { {"Chi", 3, 0x003A7, 0}, {"rfloor", 6, 0x0230B, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1BC[] = { {"eacute", 6, 0x000E9, 0}, {"omicron", 7, 0x003BF, 0}, {"part", 4, 0x02202, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1BE[] = { {"clubs", 5, 0x02663, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1BF[] = { {"Epsilon", 7, 0x00395, 0}, {"Eta", 3, 0x00397, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1C2[] = { {"ouml", 4, 0x000F6, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1C4[] = { {"#039", 4, 0x00027, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1C9[] = { {"Ograve", 6, 0x000D2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1CC[] = { {"uacute", 6, 0x000FA, 0}, {"cong", 4, 0x02245, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1CF[] = { {"Upsilon", 7, 0x003A5, 0}, {"asymp", 5, 0x02248, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1D0[] = { {"ordf", 4, 0x000AA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1D4[] = { {"sube", 4, 0x02286, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1D7[] = { {"ordm", 4, 0x000BA, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1D8[] = { {"Euml", 4, 0x000CB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1D9[] = { {"chi", 3, 0x003C7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1DD[] = { {"nsub", 4, 0x02284, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1DF[] = { {"epsilon", 7, 0x003B5, 0}, {"eta", 3, 0x003B7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1E6[] = { {"Oacute", 6, 0x000D3, 0}, {"eth", 3, 0x000F0, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1E8[] = { {"Uuml", 4, 0x000DC, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1E9[] = { {"ograve", 6, 0x000F2, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1ED[] = { {"rang", 4, 0x0232A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1EF[] = { {"upsilon", 7, 0x003C5, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F1[] = { {"ge", 2, 0x02265, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F2[] = { {"Kappa", 5, 0x0039A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F3[] = { {"lfloor", 6, 0x0230A, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F4[] = { {"sect", 4, 0x000A7, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F6[] = { {"otimes", 6, 0x02297, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F8[] = { {"euml", 4, 0x000EB, 0}, {NULL} }; -static const entity_cp_map ht_bucket_html4_1F9[] = { {"shy", 3, 0x000AD, 0}, {NULL} }; +static const entity_cp_map ht_bucket_html4_000[] = { {"gt", 2, 0x0003E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_003[] = { {"Igrave", 6, 0x000CC, 0}, {"amp", 3, 0x00026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_006[] = { {"oacute", 6, 0x000F3, 0}, {"Xi", 2, 0x0039E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_008[] = { {"uuml", 4, 0x000FC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_00B[] = { {"Alpha", 5, 0x00391, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_00E[] = { {"sim", 3, 0x0223C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_012[] = { {"kappa", 5, 0x003BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_016[] = { {"lArr", 4, 0x021D0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_018[] = { {"and", 3, 0x02227, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_01B[] = { {"ang", 3, 0x02220, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_020[] = { {"copy", 4, 0x000A9, 0}, {"Iacute", 6, 0x000CD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_023[] = { {"igrave", 6, 0x000EC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_026[] = { {"xi", 2, 0x003BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_027[] = { {"Acirc", 5, 0x000C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_02B[] = { {"Ecirc", 5, 0x000CA, 0}, {"alpha", 5, 0x003B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_02C[] = { {"hearts", 6, 0x02665, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_02F[] = { {"Icirc", 5, 0x000CE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_030[] = { {"Yacute", 6, 0x000DD, 0}, {"int", 3, 0x0222B, 0}, {"rlm", 3, 0x0200F, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_034[] = { {"empty", 5, 0x02205, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_036[] = { {"larr", 4, 0x02190, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_03B[] = { {"Ucirc", 5, 0x000DB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_03C[] = { {"oline", 5, 0x0203E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_040[] = { {"iacute", 6, 0x000ED, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_046[] = { {"middot", 6, 0x000B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_047[] = { {"acirc", 5, 0x000E2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_04B[] = { {"ecirc", 5, 0x000EA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_04F[] = { {"icirc", 5, 0x000EE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_050[] = { {"yacute", 6, 0x000FD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_051[] = { {"minus", 5, 0x02212, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_054[] = { {"Auml", 4, 0x000C4, 0}, {"thetasym", 8, 0x003D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_056[] = { {"Sigma", 5, 0x003A3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_059[] = { {"lsquo", 5, 0x02018, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_05B[] = { {"ucirc", 5, 0x000FB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_05C[] = { {"rArr", 4, 0x021D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_064[] = { {"brvbar", 6, 0x000A6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_067[] = { {"AElig", 5, 0x000C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_069[] = { {"Ccedil", 6, 0x000C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_071[] = { {"Psi", 3, 0x003A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_072[] = { {"exist", 5, 0x02203, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_074[] = { {"auml", 4, 0x000E4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_076[] = { {"sigma", 5, 0x003C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_078[] = { {"isin", 4, 0x02208, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_07C[] = { {"rarr", 4, 0x02192, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_089[] = { {"ccedil", 6, 0x000E7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_08D[] = { {"raquo", 5, 0x000BB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_08E[] = { {"Omega", 5, 0x003A9, 0}, {"zwnj", 4, 0x0200C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_091[] = { {"psi", 3, 0x003C8, 0}, {"there4", 6, 0x02234, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_092[] = { {"hArr", 4, 0x021D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_096[] = { {"le", 2, 0x02264, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_098[] = { {"Atilde", 6, 0x000C3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_099[] = { {"Zeta", 4, 0x00396, 0}, {"infin", 5, 0x0221E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_09D[] = { {"frasl", 5, 0x02044, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0A0[] = { {"euro", 4, 0x020AC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0A5[] = { {"lt", 2, 0x0003C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0A7[] = { {"aelig", 5, 0x000E6, 0}, {"Mu", 2, 0x0039C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0A8[] = { {"macr", 4, 0x000AF, 0}, {"image", 5, 0x02111, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0AA[] = { {"ldquo", 5, 0x0201C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0AE[] = { {"omega", 5, 0x003C9, 0}, {"upsih", 5, 0x003D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0B0[] = { {"THORN", 5, 0x000DE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0B2[] = { {"Iota", 4, 0x00399, 0}, {"harr", 4, 0x02194, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0B4[] = { {"bull", 4, 0x02022, 0}, {"rceil", 5, 0x02309, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0B8[] = { {"atilde", 6, 0x000E3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0B9[] = { {"zeta", 4, 0x003B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0BA[] = { {"emsp", 4, 0x02003, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0BC[] = { {"perp", 4, 0x022A5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0C2[] = { {"Prime", 5, 0x02033, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0C4[] = { {"frac12", 6, 0x000BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0C5[] = { {"Ntilde", 6, 0x000D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0C6[] = { {"frac14", 6, 0x000BC, 0}, {"circ", 4, 0x002C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0C7[] = { {"mu", 2, 0x003BC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0C8[] = { {"Gamma", 5, 0x00393, 0}, {"Nu", 2, 0x0039D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0CE[] = { {"fnof", 4, 0x00192, 0}, {"quot", 4, 0x00022, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0D2[] = { {"iota", 4, 0x003B9, 0}, {"mdash", 5, 0x02014, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0D8[] = { {"ne", 2, 0x02260, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0DB[] = { {"Theta", 5, 0x00398, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0DC[] = { {"ni", 2, 0x0220B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0E2[] = { {"prime", 5, 0x02032, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0E5[] = { {"ntilde", 6, 0x000F1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0E6[] = { {"Lambda", 6, 0x0039B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0E8[] = { {"gamma", 5, 0x003B3, 0}, {"nu", 2, 0x003BD, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0EB[] = { {"pound", 5, 0x000A3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0EE[] = { {"permil", 6, 0x02030, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0F9[] = { {"cap", 3, 0x02229, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0FA[] = { {"iexcl", 5, 0x000A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0FB[] = { {"Agrave", 6, 0x000C0, 0}, {"theta", 5, 0x003B8, 0}, {"ensp", 4, 0x02002, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0FE[] = { {"Pi", 2, 0x003A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_0FF[] = { {"crarr", 5, 0x021B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_100[] = { {"iquest", 6, 0x000BF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_105[] = { {"forall", 6, 0x02200, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_106[] = { {"Phi", 3, 0x003A6, 0}, {"lambda", 6, 0x003BB, 0}, {"or", 2, 0x02228, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_108[] = { {"frac34", 6, 0x000BE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_10D[] = { {"notin", 5, 0x02209, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_10E[] = { {"dArr", 4, 0x021D3, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_10F[] = { {"Dagger", 6, 0x02021, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_111[] = { {"yen", 3, 0x000A5, 0}, {"weierp", 6, 0x02118, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_113[] = { {"uml", 3, 0x000A8, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_117[] = { {"tilde", 5, 0x002DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_118[] = { {"Aacute", 6, 0x000C1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_11A[] = { {"loz", 3, 0x025CA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_11B[] = { {"agrave", 6, 0x000E0, 0}, {"thinsp", 6, 0x02009, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_11E[] = { {"pi", 2, 0x003C0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_11F[] = { {"micro", 5, 0x000B5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_125[] = { {"spades", 6, 0x02660, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_126[] = { {"phi", 3, 0x003C6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_12E[] = { {"darr", 4, 0x02193, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_12F[] = { {"Oslash", 6, 0x000D8, 0}, {"Tau", 3, 0x003A4, 0}, {"dagger", 6, 0x02020, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_135[] = { {"Ocirc", 5, 0x000D4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_136[] = { {"alefsym", 7, 0x02135, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_138[] = { {"aacute", 6, 0x000E1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_13A[] = { {"divide", 6, 0x000F7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_13F[] = { {"sdot", 4, 0x022C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_143[] = { {"reg", 3, 0x000AE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_149[] = { {"real", 4, 0x0211C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_14B[] = { {"Scaron", 6, 0x00160, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_14F[] = { {"cent", 4, 0x000A2, 0}, {"oslash", 6, 0x000F8, 0}, {"tau", 3, 0x003C4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_150[] = { {"thorn", 5, 0x000FE, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_153[] = { {"ndash", 5, 0x02013, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_154[] = { {"piv", 3, 0x003D6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_155[] = { {"ocirc", 5, 0x000F4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_156[] = { {"Aring", 5, 0x000C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_158[] = { {"nbsp", 4, 0x000A0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_15C[] = { {"Iuml", 4, 0x000CF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_15F[] = { {"rsquo", 5, 0x02019, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_160[] = { {"rsaquo", 6, 0x0203A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_163[] = { {"hellip", 6, 0x02026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_166[] = { {"Otilde", 6, 0x000D5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_16B[] = { {"scaron", 6, 0x00161, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_16C[] = { {"Yuml", 4, 0x00178, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_16E[] = { {"sup1", 4, 0x000B9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_16F[] = { {"sup2", 4, 0x000B2, 0}, {"Delta", 5, 0x00394, 0}, {"sbquo", 5, 0x0201A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_170[] = { {"sup3", 4, 0x000B3, 0}, {"lrm", 3, 0x0200E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_173[] = { {"diams", 5, 0x02666, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_175[] = { {"OElig", 5, 0x00152, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_176[] = { {"aring", 5, 0x000E5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_178[] = { {"oplus", 5, 0x02295, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_17C[] = { {"iuml", 4, 0x000EF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_17F[] = { {"Egrave", 6, 0x000C8, 0}, {"uArr", 4, 0x021D1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_181[] = { {"Beta", 4, 0x00392, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_183[] = { {"nabla", 5, 0x02207, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_186[] = { {"ETH", 3, 0x000D0, 0}, {"otilde", 6, 0x000F5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_187[] = { {"laquo", 5, 0x000AB, 0}, {"times", 5, 0x000D7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_18C[] = { {"yuml", 4, 0x000FF, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_18D[] = { {"cup", 3, 0x0222A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_18E[] = { {"Rho", 3, 0x003A1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_18F[] = { {"Ugrave", 6, 0x000D9, 0}, {"delta", 5, 0x003B4, 0}, {"equiv", 5, 0x02261, 0}, {"sub", 3, 0x02282, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_194[] = { {"curren", 6, 0x000A4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_196[] = { {"not", 3, 0x000AC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_197[] = { {"acute", 5, 0x000B4, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_19A[] = { {"prod", 4, 0x0220F, 0}, {"sum", 3, 0x02211, 0}, {"lsaquo", 6, 0x02039, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_19C[] = { {"Eacute", 6, 0x000C9, 0}, {"Omicron", 7, 0x0039F, 0}, {"sigmaf", 6, 0x003C2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_19D[] = { {"sup", 3, 0x02283, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_19F[] = { {"egrave", 6, 0x000E8, 0}, {"uarr", 4, 0x02191, 0}, {"lowast", 6, 0x02217, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A0[] = { {"zwj", 3, 0x0200D, 0}, {"bdquo", 5, 0x0201E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A1[] = { {"beta", 4, 0x003B2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A2[] = { {"Ouml", 4, 0x000D6, 0}, {"supe", 4, 0x02287, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A4[] = { {"plusmn", 6, 0x000B1, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A6[] = { {"cedil", 5, 0x000B8, 0}, {"prop", 4, 0x0221D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A7[] = { {"lang", 4, 0x02329, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A8[] = { {"radic", 5, 0x0221A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1A9[] = { {"para", 4, 0x000B6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1AC[] = { {"Uacute", 6, 0x000DA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1AE[] = { {"szlig", 5, 0x000DF, 0}, {"rho", 3, 0x003C1, 0}, {"lceil", 5, 0x02308, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1AF[] = { {"ugrave", 6, 0x000F9, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1B0[] = { {"rdquo", 5, 0x0201D, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1B5[] = { {"deg", 3, 0x000B0, 0}, {"trade", 5, 0x02122, 0}, {"oelig", 5, 0x00153, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1B9[] = { {"Chi", 3, 0x003A7, 0}, {"rfloor", 6, 0x0230B, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1BC[] = { {"eacute", 6, 0x000E9, 0}, {"omicron", 7, 0x003BF, 0}, {"part", 4, 0x02202, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1BE[] = { {"clubs", 5, 0x02663, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1BF[] = { {"Epsilon", 7, 0x00395, 0}, {"Eta", 3, 0x00397, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1C2[] = { {"ouml", 4, 0x000F6, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1C4[] = { {"#039", 4, 0x00027, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1C9[] = { {"Ograve", 6, 0x000D2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1CC[] = { {"uacute", 6, 0x000FA, 0}, {"cong", 4, 0x02245, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1CF[] = { {"Upsilon", 7, 0x003A5, 0}, {"asymp", 5, 0x02248, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1D0[] = { {"ordf", 4, 0x000AA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1D4[] = { {"sube", 4, 0x02286, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1D7[] = { {"ordm", 4, 0x000BA, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1D8[] = { {"Euml", 4, 0x000CB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1D9[] = { {"chi", 3, 0x003C7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1DD[] = { {"nsub", 4, 0x02284, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1DF[] = { {"epsilon", 7, 0x003B5, 0}, {"eta", 3, 0x003B7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1E6[] = { {"Oacute", 6, 0x000D3, 0}, {"eth", 3, 0x000F0, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1E8[] = { {"Uuml", 4, 0x000DC, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1E9[] = { {"ograve", 6, 0x000F2, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1ED[] = { {"rang", 4, 0x0232A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1EF[] = { {"upsilon", 7, 0x003C5, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F1[] = { {"ge", 2, 0x02265, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F2[] = { {"Kappa", 5, 0x0039A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F3[] = { {"lfloor", 6, 0x0230A, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F4[] = { {"sect", 4, 0x000A7, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F6[] = { {"otimes", 6, 0x02297, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F8[] = { {"euml", 4, 0x000EB, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_html4_1F9[] = { {"shy", 3, 0x000AD, 0}, {NULL, 0, 0, 0} }; static const entity_cp_map *const ht_buckets_html4[] = { ht_bucket_html4_000, ht_bucket_empty, ht_bucket_empty, ht_bucket_html4_003, @@ -6146,31 +6146,31 @@ static const entity_ht ent_ht_html4 = { /* {{{ Start of Basic entities (no apos) table for codepoint -> entity */ static const entity_stage3_row stage3_table_be_noapos_00000[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "quot", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "amp", 3}, {0, "#039", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lt", 2}, {0, NULL, 0}, {0, "gt", 2}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"quot", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"amp", 3} } }, {0, { {"#039", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lt", 2} } }, {0, { {NULL, 0} } }, {0, { {"gt", 2} } }, {0, { {NULL, 0} } }, }; /* {{{ Basic entities (no apos) hash table for entity -> codepoint */ -static const entity_cp_map ht_bucket_be_noapos_000[] = { {"gt", 2, 0x0003E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_noapos_003[] = { {"amp", 3, 0x00026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_noapos_004[] = { {"#039", 4, 0x00027, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_noapos_005[] = { {"lt", 2, 0x0003C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_noapos_00E[] = { {"quot", 4, 0x00022, 0}, {NULL} }; +static const entity_cp_map ht_bucket_be_noapos_000[] = { {"gt", 2, 0x0003E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_noapos_003[] = { {"amp", 3, 0x00026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_noapos_004[] = { {"#039", 4, 0x00027, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_noapos_005[] = { {"lt", 2, 0x0003C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_noapos_00E[] = { {"quot", 4, 0x00022, 0}, {NULL, 0, 0, 0} }; static const entity_cp_map *const ht_buckets_be_noapos[] = { ht_bucket_be_noapos_000, ht_bucket_empty, ht_bucket_empty, ht_bucket_be_noapos_003, @@ -6189,31 +6189,31 @@ static const entity_ht ent_ht_be_noapos = { /* {{{ Start of Basic entities (with apos) table for codepoint -> entity */ static const entity_stage3_row stage3_table_be_apos_00000[] = { - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "quot", 4}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, "amp", 3}, {0, "apos", 4}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, {0, NULL, 0}, - {0, "lt", 2}, {0, NULL, 0}, {0, "gt", 2}, {0, NULL, 0}, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"quot", 4} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {"amp", 3} } }, {0, { {"apos", 4} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, {0, { {NULL, 0} } }, + {0, { {"lt", 2} } }, {0, { {NULL, 0} } }, {0, { {"gt", 2} } }, {0, { {NULL, 0} } }, }; /* {{{ Basic entities (with apos) hash table for entity -> codepoint */ -static const entity_cp_map ht_bucket_be_apos_000[] = { {"gt", 2, 0x0003E, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_apos_003[] = { {"amp", 3, 0x00026, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_apos_005[] = { {"lt", 2, 0x0003C, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_apos_008[] = { {"apos", 4, 0x00027, 0}, {NULL} }; -static const entity_cp_map ht_bucket_be_apos_00E[] = { {"quot", 4, 0x00022, 0}, {NULL} }; +static const entity_cp_map ht_bucket_be_apos_000[] = { {"gt", 2, 0x0003E, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_apos_003[] = { {"amp", 3, 0x00026, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_apos_005[] = { {"lt", 2, 0x0003C, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_apos_008[] = { {"apos", 4, 0x00027, 0}, {NULL, 0, 0, 0} }; +static const entity_cp_map ht_bucket_be_apos_00E[] = { {"quot", 4, 0x00022, 0}, {NULL, 0, 0, 0} }; static const entity_cp_map *const ht_buckets_be_apos[] = { ht_bucket_be_apos_000, ht_bucket_empty, ht_bucket_empty, ht_bucket_be_apos_003, From 5463f5f93a14c0cbf518350dc8d86c6ba2a857a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 31 Aug 2011 06:23:24 +0000 Subject: [PATCH 0651/2394] - Fixed tests when run from outside their directory. --- .../tests/libxml_set_external_entity_loader_variation1.phpt | 1 + .../tests/libxml_set_external_entity_loader_variation2.phpt | 1 + 2 files changed, 2 insertions(+) diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt index 1bb88d604eaeb..6310bb44c3281 100644 --- a/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt +++ b/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt @@ -4,6 +4,7 @@ libxml_set_external_entity_loader() variation: resolve externals and entities --FILE-- bar&fooz; diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt index bec04aa7636ab..d0fd066f390d1 100644 --- a/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt +++ b/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt @@ -7,6 +7,7 @@ libxml_set_external_entity_loader() variation: restore original handler; returni @unlink(__DIR__ . "/foobar.dtd"); --FILE-- bar From 6690258734dec66a41ba986cbd5e58f2c8ac2506 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 31 Aug 2011 06:32:05 +0000 Subject: [PATCH 0652/2394] - Fixed test htmlentities15.phpt. --- ext/standard/tests/strings/htmlentities15.phpt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ext/standard/tests/strings/htmlentities15.phpt b/ext/standard/tests/strings/htmlentities15.phpt index f45be118c3eba..54c1b060171fa 100644 --- a/ext/standard/tests/strings/htmlentities15.phpt +++ b/ext/standard/tests/strings/htmlentities15.phpt @@ -11,6 +11,9 @@ if (!$result || preg_match('/koi8/i', setlocale(LC_CTYPE, 0)) == 0) { die("skip setlocale() failed\n"); } ?> +--COMMENT-- +As of PHP 5.4, htmlentities() no longer makes replacements with numerical +entities. Hence, for this input there's no substitution. --FILE-- --EXPECT-- string(9) "ÒÏÓËÏÛÎÙÊ" -string(63) "роскошный" +string(9) "ÒÏÓËÏÛÎÙÊ" From 25031cd387913bcd759fbf340df57194007a8114 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 31 Aug 2011 07:10:17 +0000 Subject: [PATCH 0653/2394] test fixes on Darwin --- ext/date/tests/bug33532.phpt | 4 + ext/date/tests/gmstrftime_variation22.phpt | 13 ++- ext/date/tests/strftime_variation22.phpt | 13 ++- ext/standard/tests/math/bug45712.phpt | 2 + .../tests/strings/nl_langinfo_variation1.phpt | 104 +++--------------- ext/standard/tests/strings/strtolower.phpt | Bin 5049 -> 3889 bytes ext/standard/tests/strings/strtoupper1.phpt | Bin 5060 -> 3900 bytes 7 files changed, 34 insertions(+), 102 deletions(-) diff --git a/ext/date/tests/bug33532.phpt b/ext/date/tests/bug33532.phpt index 286ceb4cec018..5c88e73acde9b 100644 --- a/ext/date/tests/bug33532.phpt +++ b/ext/date/tests/bug33532.phpt @@ -3,6 +3,9 @@ Bug #33532 (Different output for strftime() and date()) --INI-- error_reporting=2047 date.timezone=UTC +--SKIPIF-- + --FILE-- @@ -21,7 +21,8 @@ echo "*** Testing gmstrftime() : usage variation ***\n"; // Initialise function arguments not being substituted (if any) $timestamp = gmmktime(8, 8, 8, 8, 8, 2008); -setlocale(LC_ALL, "en_US.utf8", "en_US"); +setlocale(LC_TIME, "POSIX"); +putenv("LC_TIME=POSIX"); date_default_timezone_set("Asia/Calcutta"); //array of values to iterate over @@ -46,13 +47,13 @@ foreach($inputs as $key =>$value) { --Preferred date and time representation-- string(2) "%c" -string(31) "Fri 08 Aug 2008 08:08:08 AM GMT" +string(24) "Fri Aug 8 08:08:08 2008" --Preferred date representation-- string(2) "%x" -string(10) "08/08/2008" +string(8) "08/08/08" --Preferred time representation-- string(2) "%X" -string(11) "08:08:08 AM" +string(8) "08:08:08" ===DONE=== diff --git a/ext/date/tests/strftime_variation22.phpt b/ext/date/tests/strftime_variation22.phpt index 151a7d20673a6..7b72ca51e1e40 100644 --- a/ext/date/tests/strftime_variation22.phpt +++ b/ext/date/tests/strftime_variation22.phpt @@ -5,8 +5,8 @@ Test strftime() function : usage variation - Checking Preferred date and time re if (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN') { die("skip Test is not valid for Windows"); } -if(!setlocale(LC_ALL, "en_US.utf8", "en_US")) { - die("skip Locale en_US.utf8 or en_US is needed by test and is not available"); +if(!setlocale(LC_ALL, "POSIX")) { + die("skip Locale POSIX is needed by test and is not available"); } ?> --FILE-- @@ -20,7 +20,8 @@ if(!setlocale(LC_ALL, "en_US.utf8", "en_US")) { echo "*** Testing strftime() : usage variation ***\n"; // Initialise function arguments not being substituted (if any) -setlocale(LC_ALL, "en_US.utf8", "en_US"); +setlocale(LC_ALL, "POSIX"); +putenv("LC_ALL=POSIX"); date_default_timezone_set("Asia/Calcutta"); $timestamp = mktime(8, 8, 8, 8, 8, 2008); @@ -46,13 +47,13 @@ foreach($inputs as $key =>$value) { --Preferred date and time representation-- string(2) "%c" -string(31) "Fri 08 Aug 2008 08:08:08 AM IST" +string(24) "Fri Aug 8 08:08:08 2008" --Preferred date representation-- string(2) "%x" -string(10) "08/08/2008" +string(8) "08/08/08" --Preferred time representation-- string(2) "%X" -string(11) "08:08:08 AM" +string(8) "08:08:08" ===DONE=== diff --git a/ext/standard/tests/math/bug45712.phpt b/ext/standard/tests/math/bug45712.phpt index 3ebc94c92e79c..e10d0e7ec398d 100644 --- a/ext/standard/tests/math/bug45712.phpt +++ b/ext/standard/tests/math/bug45712.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #45712 (NaN/INF comparison) +--XFAIL-- +Bug 45712 not fixed yet. --FILE-- @x@=>zuETv_3xLz-u^ni{`cEIZ_jnT{Q2RsuB@Bl#@ZAc z>#n%79*PHRSM01qaj>3>Cu=Dd%M`|Pg|k8ttW+ec6vaAQ)vQqrCXih*f$W9}WE&=s z-7$gefeB3@gOaFrN)y#V2~KiRkpBpVv-)V{ZK?~G7El?k{K>efz>O~9GMhnzV3)Ddi)JY4}MGMqT3)I61G}n`n zXl{%|voQkAoe^jrj6kz90?ok)G*3pLS&Tqqj6mazKog8WlZ-%9j6l=88;R!i^Y7o@ F{13j~6TScd diff --git a/ext/standard/tests/strings/strtoupper1.phpt b/ext/standard/tests/strings/strtoupper1.phpt index 2890c02ccdae7924e74937a526a8381f91c04efd..b83a8a3a5d4476fe05efc36956fca7622627a916 100644 GIT binary patch delta 38 qcmX@2zDI6D5)-qbk;UXpCOIH&zPXF3kOd^LnTfrdWizk9c4h$A^9oo1 delta 1238 zcmXZYJ!(~96op~928HDu!a)Lt+j#!Zw~03+vDv>E2#Rq4r_;jHi3k@vODAM&WwNk) ziw*l>{kr`9`iC8^_5Qvam$mcv`tZ3s9*^%nyt+YseCV#P?oRzpcXjvnG%m~e%i+_- zi~rZ>zt6v2?5*!kw_WSe2F8FkGDftCF`>KV>C2j2%0h!%@~H} z3`Yw_pzX;@v|<#5An73l$p9fpMhHPNK?sr=LXa#Ff@FmdBpZYvX%K=$AOwj*2oi(% z{`6HGLXiZ7AV~;8Qc!}lhZ3X%lpr0U1nC4NNM|TPxS=PR5d-{73c z8=N2)I6Y3 zNl-Q Date: Wed, 31 Aug 2011 07:19:20 +0000 Subject: [PATCH 0654/2394] Fix test. I have no idea why the test author didn't expect to get back latin2 when the test is setting it to latin2 here. Both PHP and MySQL are doing the right thing here. --- ext/pdo_mysql/tests/pdo_mysql___construct.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct.phpt index 46015533d4a05..dfef6a8eba6bd 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct.phpt @@ -297,4 +297,4 @@ MySQLPDOTest::skip(); [009] SQLSTATE[28000] [1045] Access denied for user 'dont%s'@'%s' (using password: YES), [n/a] n/a [010] SQLSTATE[28000] [1045] Access denied for user 'dont%s'@'%s' (using password: YES), [n/a] n/a [017] DSN=%s, SQLSTATE[%s] [%d] %s -[033] DSN = mysql:%s, character sets has not been set, @@character_set_connection reports 'latin1', expecting 'latin2'done! +done! From a84c0ab32bb08773f6593be2604969ba45b15370 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 31 Aug 2011 07:34:07 +0000 Subject: [PATCH 0655/2394] fix strptime tests for mac --- ext/standard/tests/time/strptime_basic.phpt | 1 + ext/standard/tests/time/strptime_parts.phpt | 76 +++++++++++++++++++++ 2 files changed, 77 insertions(+) create mode 100644 ext/standard/tests/time/strptime_parts.phpt diff --git a/ext/standard/tests/time/strptime_basic.phpt b/ext/standard/tests/time/strptime_basic.phpt index a3fa435d8cd54..194a78f82b235 100644 --- a/ext/standard/tests/time/strptime_basic.phpt +++ b/ext/standard/tests/time/strptime_basic.phpt @@ -5,6 +5,7 @@ Test strptime() function : basic functionality if (!function_exists('strptime')) { die("skip - strptime() function not available in this build"); } + if(PHP_OS == 'Darwin') die("skip - strptime() behaves differently on Darwin"); ?> --FILE-- diff --git a/ext/standard/tests/time/strptime_parts.phpt b/ext/standard/tests/time/strptime_parts.phpt new file mode 100644 index 0000000000000..fbe684b863c42 --- /dev/null +++ b/ext/standard/tests/time/strptime_parts.phpt @@ -0,0 +1,76 @@ +--TEST-- +Test strptime() function : basic functionality +--SKIPIF-- + + +--FILE-- + +===DONE=== +--EXPECT-- +*** Testing strptime() : basic functionality *** +int(20) +int(1) +int(10) +int(2) +int(6) +int(63) +int(20) +int(1) +int(10) +int(2) +int(6) +int(163) +int(0) +int(1) +int(10) +int(2) +int(6) +int(0) +===DONE=== From 8c93430a6a897441afb0e2c823b3568274ebf85b Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 31 Aug 2011 07:37:42 +0000 Subject: [PATCH 0656/2394] Fixed test failed, due to error message changed --- ext/standard/tests/general_functions/parse_ini_file.phpt | 6 ++---- .../tests/general_functions/parse_ini_string_002.phpt | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/ext/standard/tests/general_functions/parse_ini_file.phpt b/ext/standard/tests/general_functions/parse_ini_file.phpt index 8523c83cf098d..906e92169fa2a 100644 --- a/ext/standard/tests/general_functions/parse_ini_file.phpt +++ b/ext/standard/tests/general_functions/parse_ini_file.phpt @@ -137,11 +137,11 @@ array(1) { string(0) "" } -Warning: syntax error, unexpected '=' in %sparse_ini_file.dat on line 2 +Warning: syntax error, unexpected '=', expecting $end or TC_SECTION or TC_LABEL or TC_OFFSET in %sparse_ini_file.dat on line 2 in %sparse_ini_file.php on line 20 bool(false) -Warning: syntax error, unexpected '=' in %sparse_ini_file.dat on line 2 +Warning: syntax error, unexpected '=', expecting $end or TC_SECTION or TC_LABEL or TC_OFFSET in %sparse_ini_file.dat on line 2 in %sparse_ini_file.php on line 26 bool(false) array(1) { @@ -205,8 +205,6 @@ array(3) { ["foo_"]=> string(4) "bar3" } - -Deprecated: Comments starting with '#' are deprecated in %s array(3) { ["foo"]=> string(4) "bar1" diff --git a/ext/standard/tests/general_functions/parse_ini_string_002.phpt b/ext/standard/tests/general_functions/parse_ini_string_002.phpt index 0da959ab86cfe..f85814e3e6945 100644 --- a/ext/standard/tests/general_functions/parse_ini_string_002.phpt +++ b/ext/standard/tests/general_functions/parse_ini_string_002.phpt @@ -97,11 +97,11 @@ array(1) { %unicode|string%(0) "" } -Warning: syntax error, unexpected '=' in Unknown on line 2 +Warning: syntax error, unexpected '=', expecting $end or TC_SECTION or TC_LABEL or TC_OFFSET in Unknown on line 2 in %s bool(false) -Warning: syntax error, unexpected '=' in Unknown on line 2 +Warning: syntax error, unexpected '=', expecting $end or TC_SECTION or TC_LABEL or TC_OFFSET in Unknown on line 2 in %s bool(false) array(1) { From 190e36b47a204cbb3d5c9224cf413382c424b989 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Wed, 31 Aug 2011 07:38:19 +0000 Subject: [PATCH 0657/2394] MFB. fix xsl date tests --- ext/xsl/tests/exslt.xml | 6 +++ ext/xsl/tests/xslt010.phpt | 96 ++++++++++++++++++++++++++++++++++++-- 2 files changed, 99 insertions(+), 3 deletions(-) diff --git a/ext/xsl/tests/exslt.xml b/ext/xsl/tests/exslt.xml index 54913c6f5d83f..562e08e821618 100644 --- a/ext/xsl/tests/exslt.xml +++ b/ext/xsl/tests/exslt.xml @@ -6,4 +6,10 @@ + + + + + + diff --git a/ext/xsl/tests/xslt010.phpt b/ext/xsl/tests/xslt010.phpt index 75729c270fabb..96ef8c627510a 100644 --- a/ext/xsl/tests/xslt010.phpt +++ b/ext/xsl/tests/xslt010.phpt @@ -30,7 +30,7 @@ Test 10: EXSLT Support month-in-year : 12 month-name : December month-abbreviation : Dec - week-in-year : 53 + week-in-year : 1 day-in-year : 365 day-in-month : 31 day-of-week-in-month : 5 @@ -84,7 +84,7 @@ Test 10: EXSLT Support month-in-year : 12 month-name : December month-abbreviation : Dec - week-in-year : 53 + week-in-year : 1 day-in-year : 365 day-in-month : 31 day-of-week-in-month : 5 @@ -102,7 +102,7 @@ Test 10: EXSLT Support month-in-year : 2 month-name : February month-abbreviation : Feb - week-in-year : 10 + week-in-year : 9 day-in-year : 60 day-in-month : 29 day-of-week-in-month : 5 @@ -113,4 +113,94 @@ Test 10: EXSLT Support hour-in-day : NaN minute-in-hour : NaN second-in-minute : NaN + + Test Date : 1999-01-02 + year : 1999 + leap-year : false + month-in-year : 1 + month-name : January + month-abbreviation : Jan + week-in-year : 53 + day-in-year : 2 + day-in-month : 2 + day-of-week-in-month : 1 + day-in-week : 7 + day-name : Saturday + day-abbreviation : Sat + time : + hour-in-day : NaN + minute-in-hour : NaN + second-in-minute : NaN + + Test Date : 1999-01-03 + year : 1999 + leap-year : false + month-in-year : 1 + month-name : January + month-abbreviation : Jan + week-in-year : 53 + day-in-year : 3 + day-in-month : 3 + day-of-week-in-month : 1 + day-in-week : 1 + day-name : Sunday + day-abbreviation : Sun + time : + hour-in-day : NaN + minute-in-hour : NaN + second-in-minute : NaN + + Test Date : 2004-01-01 + year : 2004 + leap-year : true + month-in-year : 1 + month-name : January + month-abbreviation : Jan + week-in-year : 1 + day-in-year : 1 + day-in-month : 1 + day-of-week-in-month : 1 + day-in-week : 5 + day-name : Thursday + day-abbreviation : Thu + time : + hour-in-day : NaN + minute-in-hour : NaN + second-in-minute : NaN + + Test Date : 2006-01-01 + year : 2006 + leap-year : false + month-in-year : 1 + month-name : January + month-abbreviation : Jan + week-in-year : 52 + day-in-year : 1 + day-in-month : 1 + day-of-week-in-month : 1 + day-in-week : 1 + day-name : Sunday + day-abbreviation : Sun + time : + hour-in-day : NaN + minute-in-hour : NaN + second-in-minute : NaN + + Test Date : 2007-12-31 + year : 2007 + leap-year : false + month-in-year : 12 + month-name : December + month-abbreviation : Dec + week-in-year : 1 + day-in-year : 365 + day-in-month : 31 + day-of-week-in-month : 5 + day-in-week : 2 + day-name : Monday + day-abbreviation : Mon + time : + hour-in-day : NaN + minute-in-hour : NaN + second-in-minute : NaN From dd4e07b9b4d5e10a46b5182b5b581f5324d8764a Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Wed, 31 Aug 2011 07:43:58 +0000 Subject: [PATCH 0658/2394] Since we are creating this csv file locally this should obviously be a a LOCAL infile here for this to work reliably. For robustness this should probably have a check for the local-infile server setting as well. --- ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt b/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt index 37de557527767..b550cb8da3184 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_exec_load_data.phpt @@ -69,7 +69,7 @@ if (($tmp[1] !== 'localhost') && ($tmp[1] !== '127.0.0.1')) fwrite($fp, b"2;bar"); fclose($fp); - $sql = sprintf("LOAD DATA INFILE %s INTO TABLE test FIELDS TERMINATED BY ';' LINES TERMINATED BY '\n'", $db->quote($filename)); + $sql = sprintf("LOAD DATA LOCAL INFILE %s INTO TABLE test FIELDS TERMINATED BY ';' LINES TERMINATED BY '\n'", $db->quote($filename)); if (exec_and_count(4, $db, $sql, 2)) { @@ -105,4 +105,4 @@ $db = MySQLPDOTest::factory(); $db->exec('DROP TABLE IF EXISTS test'); ?> --EXPECTF-- -done! \ No newline at end of file +done! From 92e84dbe3f1006476e24e4bb9b65bbbf8d3b35fb Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 31 Aug 2011 07:49:52 +0000 Subject: [PATCH 0659/2394] Fixed test failed --- ext/standard/tests/general_functions/parse_ini_file.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/standard/tests/general_functions/parse_ini_file.phpt b/ext/standard/tests/general_functions/parse_ini_file.phpt index 906e92169fa2a..260c48b842519 100644 --- a/ext/standard/tests/general_functions/parse_ini_file.phpt +++ b/ext/standard/tests/general_functions/parse_ini_file.phpt @@ -205,6 +205,8 @@ array(3) { ["foo_"]=> string(4) "bar3" } + +Deprecated: Comments starting with '#' are deprecated in %s array(3) { ["foo"]=> string(4) "bar1" From b448bb5e0101f53c1ddb5b10598a323f7dc0ae46 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Wed, 31 Aug 2011 08:28:13 +0000 Subject: [PATCH 0660/2394] more tuning based on discussion in FR #40816: * parse all OIDs earlier, detect all wrong OIDs before any query is made (GET-operations) * introduce ERRNO_MULTIPLE_SET_QUERIES: warn if request contains more OIDs than max_oids and SET operation (and type&value checks) will be done in chunks. fix set method when request contains more OIDs than max_oids (2nd and subsequent chunk were ignored) --- ext/snmp/snmp.c | 92 +++++++++++++++++---------------- ext/snmp/tests/snmp-object.phpt | 29 +++++++++++ ext/snmp/tests/snmp3-error.phpt | 16 +++--- 3 files changed, 84 insertions(+), 53 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 2a812338fc69b..e8e6e8b3f6e8f 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -118,6 +118,7 @@ typedef struct snmp_session php_snmp_session; #define PHP_SNMP_ERRNO_ERROR_IN_REPLY 3 #define PHP_SNMP_ERRNO_OID_NOT_INCREASING 4 #define PHP_SNMP_ERRNO_OID_PARSING_ERROR 5 +#define PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES 6 ZEND_DECLARE_MODULE_GLOBALS(snmp) static PHP_GINIT_FUNCTION(snmp); @@ -685,11 +686,8 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, struct snmp_session *ss; struct snmp_pdu *pdu=NULL, *response; struct variable_list *vars; - oid name[MAX_NAME_LEN]; - size_t name_length; oid root[MAX_NAME_LEN]; size_t rootlen = 0; - int gotroot = 0; int status, count, found; char buf[2048]; char buf2[2048]; @@ -704,35 +702,10 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, /* reset errno and errstr */ php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_NOERROR, ""); - if (st & SNMP_CMD_WALK) { - if (objid_query->count > 1) { - php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Multi OID walks are not supported!"); - RETURN_FALSE; - } - rootlen = MAX_NAME_LEN; - if (strlen(objid_query->vars[0].oid)) { /* on a walk, an empty string means top of tree - no error */ - if (snmp_parse_oid(objid_query->vars[0].oid, root, &rootlen)) { - gotroot = 1; - } else { - php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Invalid object identifier: %s", objid_query->vars[0].oid); - RETVAL_FALSE; - return; - } - } - - if (!gotroot) { - memmove((char *) root, (char *) objid_mib, sizeof(objid_mib)); - rootlen = sizeof(objid_mib) / sizeof(oid); - gotroot = 1; - } - - memmove((char *)name, (char *)root, rootlen * sizeof(oid)); - name_length = rootlen; + if (st & SNMP_CMD_WALK) { /* remember root OID */ + memmove((char *)root, (char *)(objid_query->vars[0].name), (objid_query->vars[0].name_length) * sizeof(oid)); + rootlen = objid_query->vars[0].name_length; objid_query->offset = objid_query->count; - - memmove((char *)objid_query->vars[0].name, (char *)root, rootlen * sizeof(oid)); - objid_query->vars[0].name_length = rootlen; - } if ((ss = snmp_open(session)) == NULL) { @@ -743,6 +716,10 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, return; } + if ((st & SNMP_CMD_SET) && objid_query->count > objid_query->step) { + php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES, "Can not fit all OIDs for SET query into one packet, using multiple queries"); + } + while (keepwalking) { keepwalking = 0; if (st & SNMP_CMD_WALK) { @@ -753,7 +730,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, pdu->non_repeaters = objid_query->non_repeaters; pdu->max_repetitions = objid_query->max_repetitions; } - snmp_add_null_var(pdu, name, name_length); + snmp_add_null_var(pdu, objid_query->vars[0].name, objid_query->vars[0].name_length); } else { if (st & SNMP_CMD_GET) { pdu = snmp_pdu_create(SNMP_MSG_GET); @@ -768,14 +745,6 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, return; } for (count = 0; objid_query->offset < objid_query->count && count < objid_query->step; objid_query->offset++, count++){ - objid_query->vars[objid_query->offset].name_length = MAX_OID_LEN; - if (!snmp_parse_oid(objid_query->vars[objid_query->offset].oid, objid_query->vars[objid_query->offset].name, &(objid_query->vars[objid_query->offset].name_length))) { - php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Invalid object identifier: %s", objid_query->vars[objid_query->offset].oid); - snmp_free_pdu(pdu); - snmp_close(ss); - RETVAL_FALSE; - return; - } if (st & SNMP_CMD_SET) { if ((snmp_errno = snmp_add_var(pdu, objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length, objid_query->vars[objid_query->offset].type, objid_query->vars[objid_query->offset].value))) { snprint_objid(buf, sizeof(buf), objid_query->vars[objid_query->offset].name, objid_query->vars[objid_query->offset].name_length); @@ -802,6 +771,10 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, if (status == STAT_SUCCESS) { if (response->errstat == SNMP_ERR_NOERROR) { if (st & SNMP_CMD_SET) { + if (objid_query->offset < objid_query->count) { /* we have unprocessed OIDs */ + keepwalking = 1; + continue; + } snmp_free_pdu(response); snmp_close(ss); RETVAL_TRUE; @@ -885,13 +858,13 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, /* OID increase check */ if (st & SNMP_CMD_WALK) { - if (objid_query->oid_increasing_check == TRUE && snmp_oid_compare(name, name_length, vars->name, vars->name_length) >= 0) { + if (objid_query->oid_increasing_check == TRUE && snmp_oid_compare(objid_query->vars[0].name, objid_query->vars[0].name_length, vars->name, vars->name_length) >= 0) { snprint_objid(buf2, sizeof(buf2), vars->name, vars->name_length); php_snmp_error(getThis(), NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_NOT_INCREASING, "Error: OID not increasing: %s", buf2); keepwalking = 0; } else { - memmove((char *)name, (char *)vars->name, vars->name_length * sizeof(oid)); - name_length = vars->name_length; + memmove((char *)(objid_query->vars[0].name), (char *)vars->name, vars->name_length * sizeof(oid)); + objid_query->vars[0].name_length = vars->name_length; keepwalking = 1; } } @@ -965,7 +938,7 @@ static void php_snmp_internal(INTERNAL_FUNCTION_PARAMETERS, int st, * OID parser (and type, value for SNMP_SET command) */ -static int php_snmp_parse_oid(int st, struct objid_query *objid_query, zval **oid, zval **type, zval **value TSRMLS_DC) +static int php_snmp_parse_oid(zval *object, int st, struct objid_query *objid_query, zval **oid, zval **type, zval **value TSRMLS_DC) { char *pptr; HashPosition pos_oid, pos_type, pos_value; @@ -1085,6 +1058,34 @@ static int php_snmp_parse_oid(int st, struct objid_query *objid_query, zval **oi } } + /* now parse all OIDs */ + if (st & SNMP_CMD_WALK) { + if (objid_query->count > 1) { + php_snmp_error(object, NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Multi OID walks are not supported!"); + efree(objid_query->vars); + return FALSE; + } + objid_query->vars[0].name_length = MAX_NAME_LEN; + if (strlen(objid_query->vars[0].oid)) { /* on a walk, an empty string means top of tree - no error */ + if (!snmp_parse_oid(objid_query->vars[0].oid, objid_query->vars[0].name, &(objid_query->vars[0].name_length))) { + php_snmp_error(object, NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Invalid object identifier: %s", objid_query->vars[0].oid); + efree(objid_query->vars); + return FALSE; + } + } else { + memmove((char *)objid_query->vars[0].name, (char *)objid_mib, sizeof(objid_mib)); + objid_query->vars[0].name_length = sizeof(objid_mib) / sizeof(oid); + } + } else { + for (objid_query->offset = 0; objid_query->offset < objid_query->count; objid_query->offset++) { + objid_query->vars[objid_query->offset].name_length = MAX_OID_LEN; + if (!snmp_parse_oid(objid_query->vars[objid_query->offset].oid, objid_query->vars[objid_query->offset].name, &(objid_query->vars[objid_query->offset].name_length))) { + php_snmp_error(object, NULL TSRMLS_CC, PHP_SNMP_ERRNO_OID_PARSING_ERROR, "Invalid object identifier: %s", objid_query->vars[objid_query->offset].oid); + efree(objid_query->vars); + return FALSE; + } + } + } objid_query->offset = 0; objid_query->step = objid_query->count; return (objid_query->count > 0); @@ -1465,7 +1466,7 @@ static void php_snmp(INTERNAL_FUNCTION_PARAMETERS, int st, int version) } } - if (!php_snmp_parse_oid(st, &objid_query, oid, type, value TSRMLS_CC)) { + if (!php_snmp_parse_oid(getThis(), st, &objid_query, oid, type, value TSRMLS_CC)) { RETURN_FALSE; } @@ -2439,6 +2440,7 @@ PHP_MINIT_FUNCTION(snmp) REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_ERROR_IN_REPLY", (long)PHP_SNMP_ERRNO_ERROR_IN_REPLY); REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_NOT_INCREASING", (long)PHP_SNMP_ERRNO_OID_NOT_INCREASING); REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_PARSING_ERROR", (long)PHP_SNMP_ERRNO_OID_PARSING_ERROR); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_MULTIPLE_SET_QUERIES", (long)PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES); return SUCCESS; } diff --git a/ext/snmp/tests/snmp-object.phpt b/ext/snmp/tests/snmp-object.phpt index 7830ec2cd7481..06b6492bd7f96 100644 --- a/ext/snmp/tests/snmp-object.phpt +++ b/ext/snmp/tests/snmp-object.phpt @@ -122,6 +122,23 @@ var_dump($z); var_dump(($session->get($oid1) === $oldvalue1)); var_dump($session->close()); +echo "Multiple OID with max_oids = 1\n"; +$oid2 = 'SNMPv2-MIB::sysLocation.0'; +$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); +$session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); +$session->max_oids = 1; +$oldvalue2 = $session->get($oid2); +$newvalue2 = $oldvalue2 . '0'; +$z = $session->set(array($oid1, $oid2), array('s','s'), array($newvalue1, $newvalue2)); +var_dump($z); +var_dump(($session->get($oid1) === $newvalue1)); +var_dump(($session->get($oid2) === $newvalue2)); +$z = $session->set(array($oid1, $oid2), array('s','s'), array($oldvalue1, $oldvalue2)); +var_dump($z); +var_dump(($session->get($oid1) === $oldvalue1)); +var_dump(($session->get($oid2) === $oldvalue2)); +var_dump($session->close()); + echo "SNMPv3, setting contextEngineID (authPriv)\n"; $session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); $session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass, '', 'aeeeff'); @@ -200,6 +217,18 @@ bool(true) bool(true) bool(true) bool(true) +Multiple OID with max_oids = 1 + +Warning: SNMP::set(): Can not fit all OIDs for SET query into one packet, using multiple queries in %s on line %d +bool(true) +bool(true) +bool(true) + +Warning: SNMP::set(): Can not fit all OIDs for SET query into one packet, using multiple queries in %s on line %d +bool(true) +bool(true) +bool(true) +bool(true) SNMPv3, setting contextEngineID (authPriv) string(%d) "%S" bool(true) diff --git a/ext/snmp/tests/snmp3-error.phpt b/ext/snmp/tests/snmp3-error.phpt index b2e51da3f91bb..3c0c49922198b 100644 --- a/ext/snmp/tests/snmp3-error.phpt +++ b/ext/snmp/tests/snmp3-error.phpt @@ -17,14 +17,14 @@ echo "Checking error handling\n"; // string object_id [, int timeout [, int retries]]); var_dump(snmp3_get($hostname, $community, '', '', '', '', '')); -var_dump(snmp3_get($hostname, $community, '', '', '', '', '', '')); -var_dump(snmp3_get($hostname, $community, 'bugusPriv', '', '', '', '', '')); -var_dump(snmp3_get($hostname, $community, 'authNoPriv', 'TTT', '', '', '', '')); -var_dump(snmp3_get($hostname, $community, 'authNoPriv', 'MD5', '', '', '', '')); -var_dump(snmp3_get($hostname, $community, 'authNoPriv', 'MD5', 'te', '', '', '')); -var_dump(snmp3_get($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'BBB', '', '')); -var_dump(snmp3_get($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'AES', '', '')); -var_dump(snmp3_get($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'AES', 'ty', '')); +var_dump(snmp3_get($hostname, $community, '', '', '', '', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'bugusPriv', '', '', '', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'authNoPriv', 'TTT', '', '', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'authNoPriv', 'MD5', '', '', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'authNoPriv', 'MD5', 'te', '', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'BBB', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'AES', '', '.1.3.6.1.2.1.1.1.0')); +var_dump(snmp3_get($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'AES', 'ty', '.1.3.6.1.2.1.1.1.0')); var_dump(snmp3_get($hostname, 'somebogususer', 'authPriv', 'MD5', $auth_pass, 'AES', $priv_pass, '.1.3.6.1.2.1.1.1.0', $timeout, $retries)); var_dump(snmp3_set($hostname, $community, 'authPriv', 'MD5', $auth_pass, 'AES', $priv_pass, '', 's')); From f87065f3d19b9e49a7d0f51f0ff5e5203177d1ad Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 08:35:57 +0000 Subject: [PATCH 0661/2394] - force LF eol style as this test depends on it (size) From 43527a0f1cc376b01985100479e699a572a84692 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Wed, 31 Aug 2011 08:58:12 +0000 Subject: [PATCH 0662/2394] fixed libxml tests --- .../tests/libxml_set_external_entity_loader_variation1.phpt | 4 ++-- .../tests/libxml_set_external_entity_loader_variation2.phpt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt index 6310bb44c3281..c9c45940b9e9a 100644 --- a/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt +++ b/ext/libxml/tests/libxml_set_external_entity_loader_variation1.phpt @@ -48,7 +48,7 @@ string(10) "-//FOO/BAR" string(25) "http://example.com/foobar" array(4) { ["directory"]=> - string(36) "%s" + string(%d) "%s" ["intSubName"]=> string(3) "foo" ["extSubURI"]=> @@ -60,7 +60,7 @@ string(13) "-//FOO/ENTITY" string(32) "http://example.com/fooentity.ent" array(4) { ["directory"]=> - string(36) "%s" + string(%d) "%s" ["intSubName"]=> string(3) "foo" ["extSubURI"]=> diff --git a/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt b/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt index d0fd066f390d1..b6251bea6d079 100644 --- a/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt +++ b/ext/libxml/tests/libxml_set_external_entity_loader_variation2.phpt @@ -37,7 +37,7 @@ echo "Done.\n"; --EXPECTF-- string(10) "-//FOO/BAR" -string(46) "%sfoobar.dtd" +string(%d) "%sfoobar.dtd" Warning: DOMDocument::validate(): Could not load the external subset "foobar.dtd" in %s on line %d bool(false) From 01e115324aa579c729d61588121cbe2e4b27afde Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Wed, 31 Aug 2011 09:14:08 +0000 Subject: [PATCH 0663/2394] - Set an empty string and avoid warnings and stopping of the transformation process when a php function can't be called. - Fixed tests. --- .../xsltprocessor_registerPHPFunctions-funcnostring.phpt | 8 +------- .../xsltprocessor_registerPHPFunctions-funcundef.phpt | 8 +------- ext/xsl/xsltprocessor.c | 4 +++- 3 files changed, 5 insertions(+), 15 deletions(-) diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt index d9a70517e5e2a..90d9c68208c2d 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt @@ -25,13 +25,7 @@ var_dump($proc->transformToXml($dom)); NULL Warning: XSLTProcessor::transformToXml(): Handler name must be a string in %s on line %d - -Warning: XSLTProcessor::transformToXml(): xmlXPathCompiledEval: evaluation failed in %s on line %d - -Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element value-of in %s on line %d - -Warning: XSLTProcessor::transformToXml(): xsltValueOf: text copy failed in %s on line %d -bool(false) +NULL --CREDITS-- Christian Weiske, cweiske@php.net PHP Testfest Berlin 2009-05-09 diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt index a0ddf96a6aa69..a26c2103331dd 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt @@ -24,13 +24,7 @@ var_dump($proc->transformToXml($dom)); NULL Warning: XSLTProcessor::transformToXml(): Unable to call handler undefinedfunc() in %s on line %d - -Warning: XSLTProcessor::transformToXml(): xmlXPathCompiledEval: evaluation failed in %s on line %d - -Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element value-of in %s on line %d - -Warning: XSLTProcessor::transformToXml(): xsltValueOf: text copy failed in %s on line %d -bool(false) +NULL --CREDITS-- Christian Weiske, cweiske@php.net PHP Testfest Berlin 2009-05-09 diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index d0baa1fdcf2bb..32197c81583a9 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -302,6 +302,7 @@ static void xsl_ext_function_php(xmlXPathParserContextPtr ctxt, int nargs, int t if (obj->stringval == NULL) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Handler name must be a string"); xmlXPathFreeObject(obj); + valuePush(ctxt, xmlXPathNewString("")); if (fci.param_count > 0) { for (i = 0; i < nargs - 1; i++) { zval_ptr_dtor(&args[i]); @@ -323,7 +324,7 @@ static void xsl_ext_function_php(xmlXPathParserContextPtr ctxt, int nargs, int t /*fci.function_handler_cache = &function_ptr;*/ if (!zend_make_callable(&handler, &callable TSRMLS_CC)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to call handler %s()", callable); - + valuePush(ctxt, xmlXPathNewString("")); } else if ( intern->registerPhpFunctions == 2 && zend_hash_exists(intern->registered_phpfunctions, callable, strlen(callable) + 1) == 0) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Not allowed to call handler '%s()'", callable); /* Push an empty string, so that we at least have an xslt result... */ @@ -333,6 +334,7 @@ static void xsl_ext_function_php(xmlXPathParserContextPtr ctxt, int nargs, int t if (result == FAILURE) { if (Z_TYPE(handler) == IS_STRING) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to call handler %s()", Z_STRVAL_P(&handler)); + valuePush(ctxt, xmlXPathNewString("")); } /* retval is == NULL, when an exception occured, don't report anything, because PHP itself will handle that */ } else if (retval == NULL) { From fbb1663806050f200622edefdc9baf6899393538 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 10:05:54 +0000 Subject: [PATCH 0664/2394] - make it parser version independent --- Zend/tests/bug48693.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/tests/bug48693.phpt b/Zend/tests/bug48693.phpt index 7eabe00542e0c..e5f7ce8f45304 100644 --- a/Zend/tests/bug48693.phpt +++ b/Zend/tests/bug48693.phpt @@ -18,9 +18,9 @@ var_dump( ?> --EXPECTF-- -Parse error: syntax error, unexpected '}' in %s(%d) : runtime-created function on line 1 +Parse error: %s in %s(%d) : runtime-created function on line 1 -Parse error: syntax error, unexpected end of file in %s(%d) : runtime-created function on line 1 +Parse error: %s %s(%d) : runtime-created function on line 1 bool(false) int(2) bool(false) From b77e2647724bd3a45eb3f8a80e8560c75cd3dd10 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 10:08:55 +0000 Subject: [PATCH 0665/2394] - force LF eol style as this test depends on it (size) From 658c920e4c7e5ee451f6b0cf148f0e69e1b0c031 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 31 Aug 2011 10:09:54 +0000 Subject: [PATCH 0666/2394] Remove annoying extra newline on XFAIL summaries and sync text to trunk --- run-tests.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/run-tests.php b/run-tests.php index ddd1f5f494a42..ae65a43e65fdb 100755 --- a/run-tests.php +++ b/run-tests.php @@ -326,12 +326,10 @@ function save_or_mail_results() echo "\nYou may have found a problem in PHP."; } echo "\nThis report can be automatically sent to the PHP QA team at\n"; - echo QA_REPORTS_PAGE . "\n"; - echo "Reports for current versions of PHP will also appear on\n"; - echo "http://news.php.net/php.qa.reports\n"; + echo QA_REPORTS_PAGE . " and http://news.php.net/php.qa.reports\n"; echo "This gives us a better understanding of PHP's behavior.\n"; echo "If you don't want to send the report immediately you can choose\n"; - echo "option \"s\" to save it. You can then email this report to ". PHP_QA_EMAIL . " later.\n"; + echo "option \"s\" to save it. You can then email it to ". PHP_QA_EMAIL . " later.\n"; echo "Do you want to send this report now? [Yns]: "; flush(); @@ -1950,7 +1948,7 @@ function run_test($php, $file, $env) if (!$passed) { if (isset($section_text['XFAIL'])) { $restype[] = 'XFAIL'; - $info = ' XFAIL REASON: ' . $section_text['XFAIL']; + $info = ' XFAIL REASON: ' . rtrim($section_text['XFAIL']); } else { $restype[] = 'FAIL'; } From 6181baf15a0fe94aabab418466d521ad1b029be3 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 10:22:18 +0000 Subject: [PATCH 0667/2394] - use only test name --- Zend/tests/bug52041.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/bug52041.phpt b/Zend/tests/bug52041.phpt index 944baf4eddfec..c4b9f97ee568e 100644 --- a/Zend/tests/bug52041.phpt +++ b/Zend/tests/bug52041.phpt @@ -51,7 +51,7 @@ Notice: Undefined variable: x in %sbug52041.php on line 3 Notice: Undefined variable: x in %sbug52041.php on line 3 -Notice: Undefined variable: x in %stests/bug52041.php on line 3 +Notice: Undefined variable: x in %sbug52041.php on line 3 Notice: Undefined offset: 0 in %sbug52041.php on line 15 From f15d9278eb953a63ba0ea50593da4c3baf4ad037 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 10:30:39 +0000 Subject: [PATCH 0668/2394] - use only the test name --- Zend/tests/bug54262.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/tests/bug54262.phpt b/Zend/tests/bug54262.phpt index 24c7122fcd3d6..1b9d3513ccf38 100644 --- a/Zend/tests/bug54262.phpt +++ b/Zend/tests/bug54262.phpt @@ -11,7 +11,7 @@ echo "ok\n"; --EXPECTF-- bool(true) -Warning: Attempt to modify property of non-object in %s/Zend/tests/bug54262.php on line 4 +Warning: Attempt to modify property of non-object in %sbug54262.php on line 4 -Warning: Cannot use a scalar value as an array in %s/Zend/tests/bug54262.php on line 5 -ok \ No newline at end of file +Warning: Cannot use a scalar value as an array in %sbug54262.php on line 5 +ok From 54591710f01ac35f66ff2245c782868ddce1bfe5 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 10:43:39 +0000 Subject: [PATCH 0669/2394] - use only the test name --- Zend/tests/debug_backtrace_limit.phpt | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Zend/tests/debug_backtrace_limit.phpt b/Zend/tests/debug_backtrace_limit.phpt index 59e04019bc33d..985c2cccb3830 100644 --- a/Zend/tests/debug_backtrace_limit.phpt +++ b/Zend/tests/debug_backtrace_limit.phpt @@ -24,7 +24,7 @@ Array ( [0] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 7 [function] => c [args] => Array @@ -38,7 +38,7 @@ Array ( [0] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 7 [function] => c [args] => Array @@ -49,7 +49,7 @@ Array [1] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 3 [function] => b [args] => Array @@ -63,7 +63,7 @@ Array ( [0] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 7 [function] => c [args] => Array @@ -74,7 +74,7 @@ Array [1] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 3 [function] => b [args] => Array @@ -85,7 +85,7 @@ Array [2] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 17 [function] => a [args] => Array @@ -99,7 +99,7 @@ Array ( [0] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 7 [function] => c [args] => Array @@ -110,7 +110,7 @@ Array [1] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 3 [function] => b [args] => Array @@ -121,7 +121,7 @@ Array [2] => Array ( - [file] => %s/debug_backtrace_limit.php + [file] => %sdebug_backtrace_limit.php [line] => 17 [function] => a [args] => Array From 7f231eade73dba05acb0b8d63f7fe758d3f8cd9d Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 10:46:20 +0000 Subject: [PATCH 0670/2394] - use only the test name --- Zend/tests/debug_print_backtrace_limit.phpt | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Zend/tests/debug_print_backtrace_limit.phpt b/Zend/tests/debug_print_backtrace_limit.phpt index 2bafcc780080a..5100387bd6eed 100644 --- a/Zend/tests/debug_print_backtrace_limit.phpt +++ b/Zend/tests/debug_print_backtrace_limit.phpt @@ -20,12 +20,12 @@ function c() { a(); ?> --EXPECTF-- -#0 c() called at [%s/debug_print_backtrace_limit.php:7] -#0 c() called at [%s/debug_print_backtrace_limit.php:7] -#1 b() called at [%s/debug_print_backtrace_limit.php:3] -#0 c() called at [%s/debug_print_backtrace_limit.php:7] -#1 b() called at [%s/debug_print_backtrace_limit.php:3] -#2 a() called at [%s/debug_print_backtrace_limit.php:17] -#0 c() called at [%s/debug_print_backtrace_limit.php:7] -#1 b() called at [%s/debug_print_backtrace_limit.php:3] -#2 a() called at [%s/debug_print_backtrace_limit.php:17] +#0 c() called at [%sdebug_print_backtrace_limit.php:7] +#0 c() called at [%sdebug_print_backtrace_limit.php:7] +#1 b() called at [%sdebug_print_backtrace_limit.php:3] +#0 c() called at [%sdebug_print_backtrace_limit.php:7] +#1 b() called at [%sdebug_print_backtrace_limit.php:3] +#2 a() called at [%sdebug_print_backtrace_limit.php:17] +#0 c() called at [%sdebug_print_backtrace_limit.php:7] +#1 b() called at [%sdebug_print_backtrace_limit.php:3] +#2 a() called at [%sdebug_print_backtrace_limit.php:17] From 8cf651ad99ff5431e28e7c0c88c339416eea267e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 31 Aug 2011 11:11:08 +0000 Subject: [PATCH 0671/2394] - Fix Bug #55550 mysql.trace_mode miscounts result sets, fixes ext/mysql/tests/mysql_deprecated_api.phpt --- ext/mysql/php_mysql.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index 8a0d5434cfbbd..3f9a7d653a79b 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -1590,6 +1590,7 @@ PHP_FUNCTION(mysql_list_dbs) php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to save MySQL query result"); RETURN_FALSE; } + MySG(result_allocated)++; ZEND_REGISTER_RESOURCE(return_value, mysql_result, le_result); } /* }}} */ @@ -1627,6 +1628,7 @@ PHP_FUNCTION(mysql_list_tables) php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to save MySQL query result"); RETURN_FALSE; } + MySG(result_allocated)++; ZEND_REGISTER_RESOURCE(return_value, mysql_result, le_result); } /* }}} */ @@ -1664,6 +1666,7 @@ PHP_FUNCTION(mysql_list_fields) php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to save MySQL query result"); RETURN_FALSE; } + MySG(result_allocated)++; ZEND_REGISTER_RESOURCE(return_value, mysql_result, le_result); } /* }}} */ @@ -1696,6 +1699,7 @@ PHP_FUNCTION(mysql_list_processes) RETURN_FALSE; } + MySG(result_allocated)++; ZEND_REGISTER_RESOURCE(return_value, mysql_result, le_result); } /* }}} */ From 14866642e111863d30b8797c3ff806a6f7bf603a Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 11:16:25 +0000 Subject: [PATCH 0672/2394] - parser version independent --- Zend/tests/function_arguments_001.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/function_arguments_001.phpt b/Zend/tests/function_arguments_001.phpt index 747bd25766003..8e3d34d31dab0 100644 --- a/Zend/tests/function_arguments_001.phpt +++ b/Zend/tests/function_arguments_001.phpt @@ -5,5 +5,5 @@ Argument parsing error #001 function foo($arg1 string) {} ?> --EXPECTF-- -Parse error: syntax error, unexpected 'string' (T_STRING), expecting ')' in %sfunction_arguments_001.php on line %d +Parse error: %s error, %s)%s in %sfunction_arguments_001.php on line %d From 40e09c4b7aa8993996ea3cf26a63390facb3a6de Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 11:18:13 +0000 Subject: [PATCH 0673/2394] - parser version independent --- Zend/tests/function_arguments_002.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/function_arguments_002.phpt b/Zend/tests/function_arguments_002.phpt index 79dd31f3379ca..1b5b7bd908cf6 100644 --- a/Zend/tests/function_arguments_002.phpt +++ b/Zend/tests/function_arguments_002.phpt @@ -5,5 +5,5 @@ Argument parsing error #002 function foo($arg1/) {} ?> --EXPECTF-- -Parse error: syntax error, unexpected '/', expecting ')' in %sfunction_arguments_002.php on line %d +Parse error: %s error, %s)%s in %sfunction_arguments_002.php on line %d From e7158d35aba5f6f7f13efa258f43eca91cb65ba1 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 11:25:09 +0000 Subject: [PATCH 0674/2394] - force LF eol style as this test depends on it (size) From 9dd75489fe7c83548c79fc210188e8e3069ff378 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 11:27:36 +0000 Subject: [PATCH 0675/2394] - force LF eol style as this test depends on it (size) From 2ea8e386153bdd1769241f8fef13ebbf63651385 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Wed, 31 Aug 2011 11:44:22 +0000 Subject: [PATCH 0676/2394] simplexml->query returns empty array if no nodes were found and false if libxml thinks the xpath-expression was invalid. Behaves now the same like DomXPath and fixes Bug #48601 Adjusted a test to reflect that change --- ext/simplexml/simplexml.c | 5 ++--- ext/simplexml/tests/008.phpt | 9 +++++++++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index c7bada57c40ea..d05630c2c96f2 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -1294,8 +1294,9 @@ SXE_METHOD(xpath) result = retval->nodesetval; + array_init(return_value); + if (result != NULL) { - array_init(return_value); for (i = 0; i < result->nodeNr; ++i) { nodeptr = result->nodeTab[i]; if (nodeptr->type == XML_TEXT_NODE || nodeptr->type == XML_ELEMENT_NODE || nodeptr->type == XML_ATTRIBUTE_NODE) { @@ -1316,8 +1317,6 @@ SXE_METHOD(xpath) add_next_index_zval(return_value, value); } } - } else { - RETVAL_FALSE; } xmlXPathFreeObject(retval); diff --git a/ext/simplexml/tests/008.phpt b/ext/simplexml/tests/008.phpt index 4fda204a2fe30..8734ba4a46312 100644 --- a/ext/simplexml/tests/008.phpt +++ b/ext/simplexml/tests/008.phpt @@ -25,7 +25,10 @@ EOF; $sxe = simplexml_load_string($xml); var_dump($sxe->xpath("elem1/elem2/elem3/elem4")); +//valid expression var_dump($sxe->xpath("***")); +//invalid expression +var_dump($sxe->xpath("**")); ?> --EXPECTF-- array(1) { @@ -36,4 +39,10 @@ array(1) { } } } +array(0) { +} + +Warning: SimpleXMLElement::xpath(): Invalid expression in %s on line %d + +Warning: SimpleXMLElement::xpath(): xmlXPathEval: evaluation failed in %s on line %d bool(false) From 11f3294ee005579c30b090196bb35be552425451 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 12:26:55 +0000 Subject: [PATCH 0677/2394] - force LF eol style as this test depends on it (size) From d920185b9c635778efc7ea5e8e0433f118d42435 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Wed, 31 Aug 2011 12:58:25 +0000 Subject: [PATCH 0678/2394] Check if server supports LOAD DATA LOCAL INFILE to catch [1148] The used command is not allowed with this MySQL version during SKIPIF --- ext/mysqli/tests/061.phpt | 15 +++++++++++++++ ext/mysqli/tests/bug49442.phpt | 25 +++++++++++++++++++++++++ 2 files changed, 40 insertions(+) diff --git a/ext/mysqli/tests/061.phpt b/ext/mysqli/tests/061.phpt index 08b4cda2519c2..afe1b77d9defb 100644 --- a/ext/mysqli/tests/061.phpt +++ b/ext/mysqli/tests/061.phpt @@ -6,6 +6,21 @@ require_once('skipif.inc'); require_once('skipifconnectfailure.inc'); if (!function_exists('mysqli_set_local_infile_handler')) die("skip - function not available."); + +$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket); +if (!$link) + die(sprintf("skip Can't connect [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); + +if (!mysqli_query($link,"DROP TABLE IF EXISTS t_061")) + die(sprintf("skip Cannot drop table: [%d] %s\n", mysqli_errno($link), mysqli_error($link))); + +if (!mysqli_query($link,"CREATE TABLE t_061 (c1 varchar(10), c2 varchar(10))")) + die(sprintf("skip Cannot create table: [%d] %s\n", mysqli_errno($link), mysqli_error($link))); + +if (!mysqli_query($link, sprintf("LOAD DATA LOCAL INFILE '%s' INTO TABLE t_061 FIELDS TERMINATED BY ';'", mysqli_real_escape_string($link, $filename)))) + if (1148 == mysqli_errno($link)) + die(sprintf("skip Cannot test LOAD DATA LOCAL INFILE, [%d] %s", mysqli_errno($link), mysqli_error($link))); + ?> --FILE-- --INI-- mysqli.allow_local_infile=1 From ad24758ee9024197f4df78a6583846a401f8fad3 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Wed, 31 Aug 2011 13:18:44 +0000 Subject: [PATCH 0679/2394] added alias for *-mobile encodings. --- .../filters/mbfilter_iso2022jp_mobile.c | 4 ++- .../libmbfl/filters/mbfilter_sjis_mobile.c | 10 ++++-- .../libmbfl/filters/mbfilter_utf8_mobile.c | 32 +++++++++---------- .../libmbfl/filters/mbfilter_utf8_mobile.h | 8 ++--- ext/mbstring/libmbfl/mbfl/mbfl_convert.c | 4 +-- ext/mbstring/libmbfl/mbfl/mbfl_encoding.c | 2 +- ext/mbstring/libmbfl/mbfl/mbfl_encoding.h | 2 +- ext/mbstring/libmbfl/mbfl/mbfl_ident.c | 2 +- 8 files changed, 35 insertions(+), 29 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c index 4c8d9747143a5..aa4e6912a0c7a 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_iso2022jp_mobile.c @@ -42,11 +42,13 @@ extern int mbfl_filt_conv_any_jis_flush(mbfl_convert_filter *filter); extern int mbfl_filt_ident_2022jpms(int c, mbfl_identify_filter *filter); +static const char *mbfl_encoding_2022jp_kddi_aliases[] = {"ISO-2022-JP-KDDI", NULL}; + const mbfl_encoding mbfl_encoding_2022jp_kddi = { mbfl_no_encoding_2022jp_kddi, "ISO-2022-JP-MOBILE#KDDI", "ISO-2022-JP", - NULL, + mbfl_encoding_2022jp_kddi_aliases, NULL, MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_SHFTCODE | MBFL_ENCTYPE_GL_UNSAFE }; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c index 37ea55e4b8e6f..fee36bcaa06b2 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_sjis_mobile.c @@ -44,11 +44,15 @@ extern int mbfl_bisec_srch2(int w, const unsigned short tbl[], int n); extern int mbfl_filt_ident_sjis(int c, mbfl_identify_filter *filter); extern const unsigned char mblen_table_sjis[]; +static const char *mbfl_encoding_sjis_docomo_aliases[] = {"SJIS-DOCOMO", "shift_jis-imode", "x-sjis-emoji-docomo", NULL}; +static const char *mbfl_encoding_sjis_kddi_aliases[] = {"SJIS-KDDI", "shift_jis-kddi", "x-sjis-emoji-kddi", NULL}; +static const char *mbfl_encoding_sjis_sb_aliases[] = {"SJIS-SOFTBANK", "shift_jis-softbank", "x-sjis-emoji-softbank", NULL}; + const mbfl_encoding mbfl_encoding_sjis_docomo = { mbfl_no_encoding_sjis_docomo, "SJIS-Mobile#DOCOMO", "Shift_JIS", - NULL, + mbfl_encoding_sjis_docomo_aliases, mblen_table_sjis, MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE }; @@ -57,7 +61,7 @@ const mbfl_encoding mbfl_encoding_sjis_kddi = { mbfl_no_encoding_sjis_kddi, "SJIS-Mobile#KDDI", "Shift_JIS", - NULL, + mbfl_encoding_sjis_kddi_aliases, mblen_table_sjis, MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE }; @@ -66,7 +70,7 @@ const mbfl_encoding mbfl_encoding_sjis_sb = { mbfl_no_encoding_sjis_sb, "SJIS-Mobile#SOFTBANK", "Shift_JIS", - NULL, + mbfl_encoding_sjis_sb_aliases, mblen_table_sjis, MBFL_ENCTYPE_MBCS | MBFL_ENCTYPE_GL_UNSAFE }; diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c index a5e2b0f2b47e6..db96ea3729b70 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.c @@ -40,10 +40,10 @@ extern int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter); extern const unsigned char mblen_table_utf8[]; -static const char *mbfl_encoding_utf8_docomo_aliases[] = {"utf8-mobile#docomo", NULL}; -static const char *mbfl_encoding_utf8_kddi_aliases[] = {"utf8-mobile#kddi", NULL}; -static const char *mbfl_encoding_utf8_kddi_b_aliases[] = {"utf8-mobile#kddi-b", NULL}; -static const char *mbfl_encoding_utf8_sb_aliases[] = {"utf8-mobile#softbank", NULL}; +static const char *mbfl_encoding_utf8_docomo_aliases[] = {"UTF-8-DOCOMO", "UTF8-DOCOMO", NULL}; +static const char *mbfl_encoding_utf8_kddi_a_aliases[] = {"UTF-8-KDDI", "UTF8-KDDI", NULL}; +static const char *mbfl_encoding_utf8_kddi_b_aliases[] = {"UTF-8-Mobile#KDDI", "UTF-8-KDDI", "UTF8-KDDI", NULL}; +static const char *mbfl_encoding_utf8_sb_aliases[] = {"UTF-8-SOFTBANK", "UTF8-SOFTBANK", NULL}; const mbfl_encoding mbfl_encoding_utf8_docomo = { mbfl_no_encoding_utf8_docomo, @@ -54,11 +54,11 @@ const mbfl_encoding mbfl_encoding_utf8_docomo = { MBFL_ENCTYPE_MBCS }; -const mbfl_encoding mbfl_encoding_utf8_kddi = { - mbfl_no_encoding_utf8_kddi, - "UTF-8-Mobile#KDDI", +const mbfl_encoding mbfl_encoding_utf8_kddi_a = { + mbfl_no_encoding_utf8_kddi_a, + "UTF-8-Mobile#KDDI-A", "UTF-8", - (const char *(*)[])&mbfl_encoding_utf8_kddi_aliases, + (const char *(*)[])&mbfl_encoding_utf8_kddi_a_aliases, mblen_table_utf8, MBFL_ENCTYPE_MBCS }; @@ -88,8 +88,8 @@ const struct mbfl_identify_vtbl vtbl_identify_utf8_docomo = { mbfl_filt_ident_utf8 }; -const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi = { - mbfl_no_encoding_utf8_kddi, +const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi_a = { + mbfl_no_encoding_utf8_kddi_a, mbfl_filt_ident_common_ctor, mbfl_filt_ident_common_dtor, mbfl_filt_ident_utf8 @@ -127,8 +127,8 @@ const struct mbfl_convert_vtbl vtbl_wchar_utf8_docomo = { mbfl_filt_conv_common_flush }; -const struct mbfl_convert_vtbl vtbl_utf8_kddi_wchar = { - mbfl_no_encoding_utf8_kddi, +const struct mbfl_convert_vtbl vtbl_utf8_kddi_a_wchar = { + mbfl_no_encoding_utf8_kddi_a, mbfl_no_encoding_wchar, mbfl_filt_conv_common_ctor, mbfl_filt_conv_common_dtor, @@ -136,9 +136,9 @@ const struct mbfl_convert_vtbl vtbl_utf8_kddi_wchar = { mbfl_filt_conv_common_flush }; -const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi = { +const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi_a = { mbfl_no_encoding_wchar, - mbfl_no_encoding_utf8_kddi, + mbfl_no_encoding_utf8_kddi_a, mbfl_filt_conv_common_ctor, mbfl_filt_conv_common_dtor, mbfl_filt_conv_wchar_utf8_mobile, @@ -212,7 +212,7 @@ int mbfl_filt_conv_utf8_mobile_wchar(int c, mbfl_convert_filter *filter) if (filter->from->no_encoding == mbfl_no_encoding_utf8_docomo && mbfilter_conv_r_map_tbl(s, &s1, mbfl_docomo2uni_pua, 4) > 0) { s = mbfilter_sjis_emoji_docomo2unicode(s1, &snd); - } else if (filter->from->no_encoding == mbfl_no_encoding_utf8_kddi && + } else if (filter->from->no_encoding == mbfl_no_encoding_utf8_kddi_a && mbfilter_conv_r_map_tbl(s, &s1, mbfl_kddi2uni_pua, 6) > 0) { s = mbfilter_sjis_emoji_kddi2unicode(s1, &snd); } else if (filter->from->no_encoding == mbfl_no_encoding_utf8_kddi_b && @@ -320,7 +320,7 @@ int mbfl_filt_conv_wchar_utf8_mobile(int c, mbfl_convert_filter *filter) if ((filter->to->no_encoding == mbfl_no_encoding_utf8_docomo && mbfilter_unicode2sjis_emoji_docomo(c, &s1, filter) > 0 && mbfilter_conv_map_tbl(s1, &c1, mbfl_docomo2uni_pua, 4) > 0) || - (filter->to->no_encoding == mbfl_no_encoding_utf8_kddi && + (filter->to->no_encoding == mbfl_no_encoding_utf8_kddi_a && mbfilter_unicode2sjis_emoji_kddi(c, &s1, filter) > 0 && mbfilter_conv_map_tbl(s1, &c1, mbfl_kddi2uni_pua, 6) > 0) || (filter->to->no_encoding == mbfl_no_encoding_utf8_kddi_b && diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h index d8c411192be53..c127b184049e7 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8_mobile.h @@ -31,19 +31,19 @@ #define MBFL_MBFILTER_UTF8_MOBILE_H extern const mbfl_encoding mbfl_encoding_utf8_docomo; -extern const mbfl_encoding mbfl_encoding_utf8_kddi; +extern const mbfl_encoding mbfl_encoding_utf8_kddi_a; extern const mbfl_encoding mbfl_encoding_utf8_kddi_b; extern const mbfl_encoding mbfl_encoding_utf8_sb; extern const struct mbfl_identify_vtbl vtbl_identify_utf8_docomo; -extern const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi; +extern const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi_a; extern const struct mbfl_identify_vtbl vtbl_identify_utf8_kddi_b; extern const struct mbfl_identify_vtbl vtbl_identify_utf8_sb; extern const struct mbfl_convert_vtbl vtbl_utf8_docomo_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_docomo; -extern const struct mbfl_convert_vtbl vtbl_utf8_kddi_wchar; -extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi; +extern const struct mbfl_convert_vtbl vtbl_utf8_kddi_a_wchar; +extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi_a; extern const struct mbfl_convert_vtbl vtbl_utf8_kddi_b_wchar; extern const struct mbfl_convert_vtbl vtbl_wchar_utf8_kddi_b; extern const struct mbfl_convert_vtbl vtbl_utf8_sb_wchar; diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c index 36c488af7ab9b..ae8deb25fb40c 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_convert.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_convert.c @@ -151,8 +151,8 @@ const struct mbfl_convert_vtbl *mbfl_convert_filter_list[] = { &vtbl_wchar_sjis_mac, &vtbl_utf8_docomo_wchar, &vtbl_wchar_utf8_docomo, - &vtbl_utf8_kddi_wchar, - &vtbl_wchar_utf8_kddi, + &vtbl_utf8_kddi_a_wchar, + &vtbl_wchar_utf8_kddi_a, &vtbl_utf8_kddi_b_wchar, &vtbl_wchar_utf8_kddi_b, &vtbl_utf8_sb_wchar, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c index df63e8ae196b9..adf0c3ae876da 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.c @@ -171,7 +171,7 @@ static const mbfl_encoding *mbfl_encoding_ptr_list[] = { &mbfl_encoding_sjis_mac, &mbfl_encoding_sjis2004, &mbfl_encoding_utf8_docomo, - &mbfl_encoding_utf8_kddi, + &mbfl_encoding_utf8_kddi_a, &mbfl_encoding_utf8_kddi_b, &mbfl_encoding_utf8_sb, &mbfl_encoding_cp932, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h index 8cb752d422560..ca7717cb7bdc2 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h +++ b/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h @@ -63,7 +63,7 @@ enum mbfl_no_encoding { mbfl_no_encoding_utf16le, mbfl_no_encoding_utf8, mbfl_no_encoding_utf8_docomo, - mbfl_no_encoding_utf8_kddi, + mbfl_no_encoding_utf8_kddi_a, mbfl_no_encoding_utf8_kddi_b, mbfl_no_encoding_utf8_sb, mbfl_no_encoding_utf7, diff --git a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c index e2594d5667641..4d6283f4f21d9 100644 --- a/ext/mbstring/libmbfl/mbfl/mbfl_ident.c +++ b/ext/mbstring/libmbfl/mbfl/mbfl_ident.c @@ -129,7 +129,7 @@ static const struct mbfl_identify_vtbl *mbfl_identify_filter_list[] = { &vtbl_identify_sjis_kddi, &vtbl_identify_sjis_sb, &vtbl_identify_utf8_docomo, - &vtbl_identify_utf8_kddi, + &vtbl_identify_utf8_kddi_a, &vtbl_identify_utf8_kddi_b, &vtbl_identify_utf8_sb, &vtbl_identify_euccn, From 776d1e5ece64cb844c9011fd22f4e6496df42a88 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Wed, 31 Aug 2011 13:50:58 +0000 Subject: [PATCH 0680/2394] New utility function to check for '[1148] The used command is not allowed with this MySQL version' during SKIPIF --- ext/mysqli/tests/061.phpt | 15 ++--- ext/mysqli/tests/bug49442.phpt | 22 ++----- ext/mysqli/tests/local_infile_tools.inc | 57 +++++++++++++++++-- .../mysqli_query_local_infile_large.phpt | 10 ++++ .../mysqli_set_local_infile_default.phpt | 10 +++- .../mysqli_set_local_infile_handler.phpt | 13 +---- ...et_local_infile_handler_bad_character.phpt | 13 +---- ..._local_infile_handler_buffer_overflow.phpt | 13 +---- ...i_set_local_infile_handler_close_link.phpt | 13 +---- ...li_set_local_infile_handler_closefile.phpt | 13 +---- ...qli_set_local_infile_handler_closures.phpt | 13 +---- ...li_set_local_infile_handler_kill_link.phpt | 13 +---- ...set_local_infile_handler_negative_len.phpt | 13 +---- ..._set_local_infile_handler_nested_call.phpt | 13 +---- ...li_set_local_infile_handler_new_query.phpt | 13 +---- ...qli_set_local_infile_handler_nofileop.phpt | 13 +---- ..._set_local_infile_handler_openbasedir.phpt | 10 ++-- ...t_local_infile_handler_replace_buffer.phpt | 13 +---- ...li_set_local_infile_handler_short_len.phpt | 13 +---- ...i_set_local_infile_handler_unregister.phpt | 13 +---- 20 files changed, 125 insertions(+), 181 deletions(-) diff --git a/ext/mysqli/tests/061.phpt b/ext/mysqli/tests/061.phpt index afe1b77d9defb..5817d8230dfd0 100644 --- a/ext/mysqli/tests/061.phpt +++ b/ext/mysqli/tests/061.phpt @@ -9,18 +9,13 @@ if (!function_exists('mysqli_set_local_infile_handler')) $link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket); if (!$link) - die(sprintf("skip Can't connect [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); + die(sprintf("skip Can't connect [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); -if (!mysqli_query($link,"DROP TABLE IF EXISTS t_061")) - die(sprintf("skip Cannot drop table: [%d] %s\n", mysqli_errno($link), mysqli_error($link))); - -if (!mysqli_query($link,"CREATE TABLE t_061 (c1 varchar(10), c2 varchar(10))")) - die(sprintf("skip Cannot create table: [%d] %s\n", mysqli_errno($link), mysqli_error($link))); - -if (!mysqli_query($link, sprintf("LOAD DATA LOCAL INFILE '%s' INTO TABLE t_061 FIELDS TERMINATED BY ';'", mysqli_real_escape_string($link, $filename)))) - if (1148 == mysqli_errno($link)) - die(sprintf("skip Cannot test LOAD DATA LOCAL INFILE, [%d] %s", mysqli_errno($link), mysqli_error($link))); +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); +mysqli_close($link); ?> --FILE-- errno, $link->error)); -require_once("local_infile_tools.inc"); -$file = create_standard_csv(4); - -if (!@mysqli_query($link, sprintf("LOAD DATA LOCAL INFILE '%s' - INTO TABLE test - FIELDS TERMINATED BY ';' OPTIONALLY ENCLOSED BY '\'' - LINES TERMINATED BY '\n'", - mysqli_real_escape_string($link, $file)))) { - if (1148 == mysqli_errno($link)) - die(sprintf("skip Cannot test LOAD DATA LOCAL INFILE, [%d] %s\n", mysqli_errno($link), mysqli_error($link))); -} +mysqli_close($link); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/local_infile_tools.inc b/ext/mysqli/tests/local_infile_tools.inc index 04d6e8a12a505..bb9872f1abb93 100644 --- a/ext/mysqli/tests/local_infile_tools.inc +++ b/ext/mysqli/tests/local_infile_tools.inc @@ -6,11 +6,53 @@ } } - function create_standard_csv($offset) { + function check_local_infile_support($link, $engine, $table_name = 'test') { + + if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) + return "Cannot check if Server variable 'local_infile' is set to 'ON'"; + + $row = mysqli_fetch_assoc($res); + mysqli_free_result($res); + if ('ON' != $row['Value']) + return sprintf("Server variable 'local_infile' seems not set to 'ON', found '%s'", $row['Value']); + + if (!mysqli_query($link, sprintf('DROP TABLE IF EXISTS %s', $table_name))) { + return "Failed to drop old test table"; + } + + if (!mysqli_query($link, $sql = sprintf('CREATE TABLE %s(id INT, label CHAR(1), PRIMARY KEY(id)) ENGINE=%s', + $table_name, $engine))) + return "Failed to create test table: $sql"; + + $file = create_standard_csv(1, false); + if (!$file) { + mysqli_query($link, sprintf('DROP TABLE IF EXISTS %s', $table_name)); + return "Cannot create CSV file"; + } + + if (!@mysqli_query($link, sprintf("LOAD DATA LOCAL INFILE '%s' + INTO TABLE %s + FIELDS TERMINATED BY ';' OPTIONALLY ENCLOSED BY '\'' + LINES TERMINATED BY '\n'", + mysqli_real_escape_string($link, $file), + $table_name))) { + if (1148 == mysqli_errno($link)) { + mysqli_query($link, sprintf('DROP TABLE IF EXISTS %s', $table_name)); + return "Cannot test LOAD DATA LOCAL INFILE, [1148] The used command is not allowed with this MySQL version"; + } else if ($link->errno) { + return $link->error; + } + } + mysqli_query($link, sprintf('DROP TABLE IF EXISTS %s', $table_name)); + return ""; + } + + function create_standard_csv($offset, $verbose = true) { // create a CVS file $file = tempnam(sys_get_temp_dir(), 'mysqli_test'); if (!$fp = fopen($file, 'w')) { - printf("[%03d + 1] Cannot create CVS file '%s'\n", $offset, $file); + if ($verbose) + printf("[%03d + 1] Cannot create CVS file '%s'\n", $offset, $file); return NULL; } else { /* Looks ugly? No, handy if you have crashes... */ @@ -21,14 +63,16 @@ if (!fwrite($fp, (binary)"'97';'x';\n") || !fwrite($fp, (binary)"'98';'y';\n") || !fwrite($fp, (binary)"99;'z';\n")) { - printf("[%03d + 2] Cannot write CVS file '%s'\n", $offset, $file); + if ($verbose) + printf("[%03d + 2] Cannot write CVS file '%s'\n", $offset, $file); return NULL; } } else { if (!fwrite($fp, "97;'x';\n") || !fwrite($fp, "98;'y';\n") || !fwrite($fp, "99;'z';\n")) { - printf("[%03d + 3] Cannot write CVS file '%s'\n", $offset, $file); + if ($verbose) + printf("[%03d + 3] Cannot write CVS file '%s'\n", $offset, $file); return NULL; } } @@ -36,8 +80,9 @@ fclose($fp); if (!chmod($file, 0644)) { - printf("[%03d + 4] Cannot change the file perms of '%s' from 0600 to 0644, MySQL might not be able to read it\n", - $offset, $file); + if ($verbose) + printf("[%03d + 4] Cannot change the file perms of '%s' from 0600 to 0644, MySQL might not be able to read it\n", + $offset, $file); return NULL; } return $file; diff --git a/ext/mysqli/tests/mysqli_query_local_infile_large.phpt b/ext/mysqli/tests/mysqli_query_local_infile_large.phpt index 8b115a507dc41..76bc415d8bcbf 100644 --- a/ext/mysqli/tests/mysqli_query_local_infile_large.phpt +++ b/ext/mysqli/tests/mysqli_query_local_infile_large.phpt @@ -4,6 +4,16 @@ mysql_query(LOAD DATA LOCAL INFILE) with large data set (10MB) errno, $link->error)); + +mysqli_close($link); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_default.phpt b/ext/mysqli/tests/mysqli_set_local_infile_default.phpt index dd67bb32a33cc..0348b01f6af9b 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_default.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_default.phpt @@ -9,7 +9,15 @@ require_once('skipifconnectfailure.inc'); if (!function_exists('mysqli_set_local_infile_handler')) die("skip - function not available."); -require_once('connect.inc'); +$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket); +if (!$link) + die(sprintf("skip Can't connect [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); + +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); + +mysqli_close($link); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler.phpt index c8da0183be503..58f4c70351b58 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler.phpt @@ -13,18 +13,11 @@ require_once('connect.inc'); if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_bad_character.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_bad_character.phpt index ad0a3532f99d3..b8f51c214fb75 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_bad_character.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_bad_character.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_buffer_overflow.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_buffer_overflow.phpt index e7df96e5a46aa..a3c8801023866 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_buffer_overflow.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_buffer_overflow.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_close_link.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_close_link.phpt index c2ee87b34a628..408bb29ec4106 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_close_link.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_close_link.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_closefile.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_closefile.phpt index 4ebf8ded2eb64..168cbc1358856 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_closefile.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_closefile.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_closures.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_closures.phpt index 3d94a545d91b5..ad7ab32c1cbc4 100755 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_closures.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_closures.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_kill_link.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_kill_link.phpt index 09b4f90f6caf8..b2b42a22e5de7 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_kill_link.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_kill_link.phpt @@ -13,18 +13,11 @@ require_once('connect.inc'); if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_negative_len.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_negative_len.phpt index ca42705494327..16e38c5fa2759 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_negative_len.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_negative_len.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_nested_call.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_nested_call.phpt index 8b56deafac7d3..4663fe236e4f9 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_nested_call.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_nested_call.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_new_query.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_new_query.phpt index 1c47292e3b8ab..ca06435c5ea17 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_new_query.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_new_query.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_nofileop.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_nofileop.phpt index 6113abae67750..601a09e12cd9c 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_nofileop.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_nofileop.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt index 423ad834e6147..c9e5f19962038 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt @@ -18,13 +18,11 @@ if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); } -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); -mysqli_close($link); +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); +mysqli_close($link); ?> --INI-- open_basedir="." diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_replace_buffer.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_replace_buffer.phpt index 33dd5164ec4ce..0d4024e528b70 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_replace_buffer.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_replace_buffer.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_short_len.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_short_len.phpt index 9af9974e71274..b3144e430e5a5 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_short_len.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_short_len.phpt @@ -16,18 +16,11 @@ if (!$TEST_EXPERIMENTAL) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_unregister.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_unregister.phpt index e6dfecb7eb6ad..f287f4d8741dc 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_unregister.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_unregister.phpt @@ -13,18 +13,11 @@ require_once('connect.inc'); if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip Cannot connect to MySQL"); -if (!$res = mysqli_query($link, 'SHOW VARIABLES LIKE "local_infile"')) { - mysqli_close($link); - die("skip Cannot check if Server variable 'local_infile' is set to 'ON'"); -} +include_once("local_infile_tools.inc"); +if ($msg = check_local_infile_support($link, $engine)) + die(sprintf("skip %s, [%d] %s", $msg, $link->errno, $link->error)); -$row = mysqli_fetch_assoc($res); -mysqli_free_result($res); mysqli_close($link); - -if ('ON' != $row['Value']) - die(sprintf("skip Server variable 'local_infile' seems not set to 'ON', found '%s'", - $row['Value'])); ?> --INI-- mysqli.allow_local_infile=1 From af73e4aab6ca7bf5668103578fc0d7b80c214daa Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Wed, 31 Aug 2011 13:59:28 +0000 Subject: [PATCH 0681/2394] Please, whenever changing the mysqli API update the tests. Don't wait for me to catch up. --- ext/mysqli/tests/mysqli_constants.phpt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/mysqli/tests/mysqli_constants.phpt b/ext/mysqli/tests/mysqli_constants.phpt index ff92160a7421c..613dddfc85d5e 100644 --- a/ext/mysqli/tests/mysqli_constants.phpt +++ b/ext/mysqli/tests/mysqli_constants.phpt @@ -160,6 +160,9 @@ require_once('skipifconnectfailure.inc'); if (defined('MYSQLI_DATA_TRUNCATED')) $expected_constants["MYSQLI_DATA_TRUNCATED"] = true; + if (defined('MYSQLI_SERVER_PS_OUT_PARAMS')) + $expected_constants["MYSQLI_SERVER_PS_OUT_PARAMS"] = true; + if (!$IS_MYSQLND) { /* libmysql only */ From dd8f68ecb0ce0cce7b24677ccfe05599111e2bde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 31 Aug 2011 15:25:18 +0000 Subject: [PATCH 0682/2394] - Be less restrictive on the SQL state, some server versions might fool us --- ext/pdo_mysql/tests/pdo_mysql___construct.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct.phpt index dfef6a8eba6bd..c3f12df7a9649 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct.phpt @@ -294,7 +294,7 @@ MySQLPDOTest::skip(); [005] invalid data source name, [n/a] n/a [006] invalid data source name, [n/a] n/a [007] could not find driver, [n/a] n/a -[009] SQLSTATE[28000] [1045] Access denied for user 'dont%s'@'%s' (using password: YES), [n/a] n/a -[010] SQLSTATE[28000] [1045] Access denied for user 'dont%s'@'%s' (using password: YES), [n/a] n/a +[009] SQLSTATE[%s] [1045] Access denied for user 'dont%s'@'%s' (using password: YES), [n/a] n/a +[010] SQLSTATE[%s] [1045] Access denied for user 'dont%s'@'%s' (using password: YES), [n/a] n/a [017] DSN=%s, SQLSTATE[%s] [%d] %s done! From 833451320ef2c93742798af0f5d41d5d0a833786 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 15:42:42 +0000 Subject: [PATCH 0683/2394] - force LF eol style as this test depends on it From 4fb7afb0bf1ea8381a0922b3e5c3d7c0830a0eb8 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 15:44:01 +0000 Subject: [PATCH 0684/2394] - force LF eol style as this test depends on it From 35597286d69cf25635d148c351f9da208af2fb49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 31 Aug 2011 15:46:07 +0000 Subject: [PATCH 0685/2394] - Update PDO_mysql error mapping --- ext/pdo_mysql/get_error_codes.php | 4 +- ext/pdo_mysql/php_pdo_mysql_sqlstate.h | 774 ++++++++++++++++--------- 2 files changed, 518 insertions(+), 260 deletions(-) diff --git a/ext/pdo_mysql/get_error_codes.php b/ext/pdo_mysql/get_error_codes.php index 2785c93b993bb..a1ed85016cb8c 100644 --- a/ext/pdo_mysql/get_error_codes.php +++ b/ext/pdo_mysql/get_error_codes.php @@ -5,7 +5,7 @@ while (!feof(STDIN)) { $line = fgets(STDIN); - if (ereg('^(ER_.*),[[:space:]]+"(.*)",[[:space:]]+"(.*)"', $line, $matches)) { + if (ereg('^\{[[:space:]]+(ER_.*)[[:space:]]+,[[:space:]]*"(.*)",[[:space:]]*"(.*)"', $line, $matches)) { $codes[$matches[1]] = $matches[2]; $maxlen = max($maxlen, strlen($matches[1])); } @@ -24,4 +24,4 @@ } -?> \ No newline at end of file +?> diff --git a/ext/pdo_mysql/php_pdo_mysql_sqlstate.h b/ext/pdo_mysql/php_pdo_mysql_sqlstate.h index 97724b72e974b..70fc95ef74267 100644 --- a/ext/pdo_mysql/php_pdo_mysql_sqlstate.h +++ b/ext/pdo_mysql/php_pdo_mysql_sqlstate.h @@ -1,388 +1,646 @@ /* DO NOT EDIT THIS FILE!!! It is auto generated by get_error_codes.php */ -#ifdef ER_DUP_KEY - case ER_DUP_KEY : return "23000"; +#ifdef ER_DUP_KEY + case ER_DUP_KEY : return "23000"; #endif -#ifdef ER_OUTOFMEMORY - case ER_OUTOFMEMORY : return "HY001"; +#ifdef ER_OUTOFMEMORY + case ER_OUTOFMEMORY : return "HY001"; #endif -#ifdef ER_OUT_OF_SORTMEMORY - case ER_OUT_OF_SORTMEMORY : return "HY001"; +#ifdef ER_OUT_OF_SORTMEMORY + case ER_OUT_OF_SORTMEMORY : return "HY001"; #endif -#ifdef ER_CON_COUNT_ERROR - case ER_CON_COUNT_ERROR : return "08004"; +#ifdef ER_CON_COUNT_ERROR + case ER_CON_COUNT_ERROR : return "08004"; #endif -#ifdef ER_BAD_HOST_ERROR - case ER_BAD_HOST_ERROR : return "08S01"; +#ifdef ER_BAD_HOST_ERROR + case ER_BAD_HOST_ERROR : return "08S01"; #endif -#ifdef ER_HANDSHAKE_ERROR - case ER_HANDSHAKE_ERROR : return "08S01"; +#ifdef ER_HANDSHAKE_ERROR + case ER_HANDSHAKE_ERROR : return "08S01"; #endif -#ifdef ER_DBACCESS_DENIED_ERROR - case ER_DBACCESS_DENIED_ERROR : return "42000"; +#ifdef ER_DBACCESS_DENIED_ERROR + case ER_DBACCESS_DENIED_ERROR : return "42000"; #endif -#ifdef ER_ACCESS_DENIED_ERROR - case ER_ACCESS_DENIED_ERROR : return "28000"; +#ifdef ER_ACCESS_DENIED_ERROR + case ER_ACCESS_DENIED_ERROR : return "28000"; #endif -#ifdef ER_NO_DB_ERROR - case ER_NO_DB_ERROR : return "3D000"; +#ifdef ER_NO_DB_ERROR + case ER_NO_DB_ERROR : return "3D000"; #endif -#ifdef ER_UNKNOWN_COM_ERROR - case ER_UNKNOWN_COM_ERROR : return "08S01"; +#ifdef ER_UNKNOWN_COM_ERROR + case ER_UNKNOWN_COM_ERROR : return "08S01"; #endif -#ifdef ER_BAD_NULL_ERROR - case ER_BAD_NULL_ERROR : return "23000"; +#ifdef ER_BAD_NULL_ERROR + case ER_BAD_NULL_ERROR : return "23000"; #endif -#ifdef ER_BAD_DB_ERROR - case ER_BAD_DB_ERROR : return "42000"; +#ifdef ER_BAD_DB_ERROR + case ER_BAD_DB_ERROR : return "42000"; #endif -#ifdef ER_TABLE_EXISTS_ERROR - case ER_TABLE_EXISTS_ERROR : return "42S01"; +#ifdef ER_TABLE_EXISTS_ERROR + case ER_TABLE_EXISTS_ERROR : return "42S01"; #endif -#ifdef ER_BAD_TABLE_ERROR - case ER_BAD_TABLE_ERROR : return "42S02"; +#ifdef ER_BAD_TABLE_ERROR + case ER_BAD_TABLE_ERROR : return "42S02"; #endif -#ifdef ER_NON_UNIQ_ERROR - case ER_NON_UNIQ_ERROR : return "23000"; +#ifdef ER_NON_UNIQ_ERROR + case ER_NON_UNIQ_ERROR : return "23000"; #endif -#ifdef ER_SERVER_SHUTDOWN - case ER_SERVER_SHUTDOWN : return "08S01"; +#ifdef ER_SERVER_SHUTDOWN + case ER_SERVER_SHUTDOWN : return "08S01"; #endif -#ifdef ER_BAD_FIELD_ERROR - case ER_BAD_FIELD_ERROR : return "42S22"; +#ifdef ER_BAD_FIELD_ERROR + case ER_BAD_FIELD_ERROR : return "42S22"; #endif -#ifdef ER_WRONG_FIELD_WITH_GROUP - case ER_WRONG_FIELD_WITH_GROUP : return "42000"; +#ifdef ER_WRONG_FIELD_WITH_GROUP + case ER_WRONG_FIELD_WITH_GROUP : return "42000"; #endif -#ifdef ER_WRONG_GROUP_FIELD - case ER_WRONG_GROUP_FIELD : return "42000"; +#ifdef ER_WRONG_GROUP_FIELD + case ER_WRONG_GROUP_FIELD : return "42000"; #endif -#ifdef ER_WRONG_SUM_SELECT - case ER_WRONG_SUM_SELECT : return "42000"; +#ifdef ER_WRONG_SUM_SELECT + case ER_WRONG_SUM_SELECT : return "42000"; #endif -#ifdef ER_WRONG_VALUE_COUNT - case ER_WRONG_VALUE_COUNT : return "21S01"; +#ifdef ER_WRONG_VALUE_COUNT + case ER_WRONG_VALUE_COUNT : return "21S01"; #endif -#ifdef ER_TOO_LONG_IDENT - case ER_TOO_LONG_IDENT : return "42000"; +#ifdef ER_TOO_LONG_IDENT + case ER_TOO_LONG_IDENT : return "42000"; #endif -#ifdef ER_DUP_FIELDNAME - case ER_DUP_FIELDNAME : return "42S21"; +#ifdef ER_DUP_FIELDNAME + case ER_DUP_FIELDNAME : return "42S21"; #endif -#ifdef ER_DUP_KEYNAME - case ER_DUP_KEYNAME : return "42000"; +#ifdef ER_DUP_KEYNAME + case ER_DUP_KEYNAME : return "42000"; #endif -#ifdef ER_DUP_ENTRY - case ER_DUP_ENTRY : return "23000"; +#ifdef ER_DUP_ENTRY + case ER_DUP_ENTRY : return "23000"; #endif -#ifdef ER_WRONG_FIELD_SPEC - case ER_WRONG_FIELD_SPEC : return "42000"; +#ifdef ER_WRONG_FIELD_SPEC + case ER_WRONG_FIELD_SPEC : return "42000"; #endif -#ifdef ER_PARSE_ERROR - case ER_PARSE_ERROR : return "42000"; +#ifdef ER_PARSE_ERROR + case ER_PARSE_ERROR : return "42000"; #endif -#ifdef ER_NONUNIQ_TABLE - case ER_NONUNIQ_TABLE : return "42000"; +#ifdef ER_EMPTY_QUERY + case ER_EMPTY_QUERY : return "42000"; #endif -#ifdef ER_INVALID_DEFAULT - case ER_INVALID_DEFAULT : return "42000"; +#ifdef ER_NONUNIQ_TABLE + case ER_NONUNIQ_TABLE : return "42000"; #endif -#ifdef ER_MULTIPLE_PRI_KEY - case ER_MULTIPLE_PRI_KEY : return "42000"; +#ifdef ER_INVALID_DEFAULT + case ER_INVALID_DEFAULT : return "42000"; #endif -#ifdef ER_TOO_MANY_KEYS - case ER_TOO_MANY_KEYS : return "42000"; +#ifdef ER_MULTIPLE_PRI_KEY + case ER_MULTIPLE_PRI_KEY : return "42000"; #endif -#ifdef ER_TOO_MANY_KEY_PARTS - case ER_TOO_MANY_KEY_PARTS : return "42000"; +#ifdef ER_TOO_MANY_KEYS + case ER_TOO_MANY_KEYS : return "42000"; #endif -#ifdef ER_TOO_LONG_KEY - case ER_TOO_LONG_KEY : return "42000"; +#ifdef ER_TOO_MANY_KEY_PARTS + case ER_TOO_MANY_KEY_PARTS : return "42000"; #endif -#ifdef ER_KEY_COLUMN_DOES_NOT_EXITS - case ER_KEY_COLUMN_DOES_NOT_EXITS : return "42000"; +#ifdef ER_TOO_LONG_KEY + case ER_TOO_LONG_KEY : return "42000"; #endif -#ifdef ER_BLOB_USED_AS_KEY - case ER_BLOB_USED_AS_KEY : return "42000"; +#ifdef ER_KEY_COLUMN_DOES_NOT_EXITS + case ER_KEY_COLUMN_DOES_NOT_EXITS : return "42000"; #endif -#ifdef ER_TOO_BIG_FIELDLENGTH - case ER_TOO_BIG_FIELDLENGTH : return "42000"; +#ifdef ER_BLOB_USED_AS_KEY + case ER_BLOB_USED_AS_KEY : return "42000"; #endif -#ifdef ER_WRONG_AUTO_KEY - case ER_WRONG_AUTO_KEY : return "42000"; +#ifdef ER_TOO_BIG_FIELDLENGTH + case ER_TOO_BIG_FIELDLENGTH : return "42000"; #endif -#ifdef ER_FORCING_CLOSE - case ER_FORCING_CLOSE : return "08S01"; +#ifdef ER_WRONG_AUTO_KEY + case ER_WRONG_AUTO_KEY : return "42000"; #endif -#ifdef ER_IPSOCK_ERROR - case ER_IPSOCK_ERROR : return "08S01"; +#ifdef ER_FORCING_CLOSE + case ER_FORCING_CLOSE : return "08S01"; #endif -#ifdef ER_NO_SUCH_INDEX - case ER_NO_SUCH_INDEX : return "42S12"; +#ifdef ER_IPSOCK_ERROR + case ER_IPSOCK_ERROR : return "08S01"; #endif -#ifdef ER_WRONG_FIELD_TERMINATORS - case ER_WRONG_FIELD_TERMINATORS : return "42000"; +#ifdef ER_NO_SUCH_INDEX + case ER_NO_SUCH_INDEX : return "42S12"; #endif -#ifdef ER_BLOBS_AND_NO_TERMINATED - case ER_BLOBS_AND_NO_TERMINATED : return "42000"; +#ifdef ER_WRONG_FIELD_TERMINATORS + case ER_WRONG_FIELD_TERMINATORS : return "42000"; #endif -#ifdef ER_CANT_REMOVE_ALL_FIELDS - case ER_CANT_REMOVE_ALL_FIELDS : return "42000"; +#ifdef ER_BLOBS_AND_NO_TERMINATED + case ER_BLOBS_AND_NO_TERMINATED : return "42000"; #endif -#ifdef ER_CANT_DROP_FIELD_OR_KEY - case ER_CANT_DROP_FIELD_OR_KEY : return "42000"; +#ifdef ER_CANT_REMOVE_ALL_FIELDS + case ER_CANT_REMOVE_ALL_FIELDS : return "42000"; #endif -#ifdef ER_BLOB_CANT_HAVE_DEFAULT - case ER_BLOB_CANT_HAVE_DEFAULT : return "42000"; +#ifdef ER_CANT_DROP_FIELD_OR_KEY + case ER_CANT_DROP_FIELD_OR_KEY : return "42000"; #endif -#ifdef ER_WRONG_DB_NAME - case ER_WRONG_DB_NAME : return "42000"; +#ifdef ER_BLOB_CANT_HAVE_DEFAULT + case ER_BLOB_CANT_HAVE_DEFAULT : return "42000"; #endif -#ifdef ER_WRONG_TABLE_NAME - case ER_WRONG_TABLE_NAME : return "42000"; +#ifdef ER_WRONG_DB_NAME + case ER_WRONG_DB_NAME : return "42000"; #endif -#ifdef ER_TOO_BIG_SELECT - case ER_TOO_BIG_SELECT : return "42000"; +#ifdef ER_WRONG_TABLE_NAME + case ER_WRONG_TABLE_NAME : return "42000"; #endif -#ifdef ER_UNKNOWN_PROCEDURE - case ER_UNKNOWN_PROCEDURE : return "42000"; +#ifdef ER_TOO_BIG_SELECT + case ER_TOO_BIG_SELECT : return "42000"; #endif -#ifdef ER_WRONG_PARAMCOUNT_TO_PROCEDURE - case ER_WRONG_PARAMCOUNT_TO_PROCEDURE : return "42000"; +#ifdef ER_UNKNOWN_PROCEDURE + case ER_UNKNOWN_PROCEDURE : return "42000"; #endif -#ifdef ER_UNKNOWN_TABLE - case ER_UNKNOWN_TABLE : return "42S02"; +#ifdef ER_WRONG_PARAMCOUNT_TO_PROCEDURE + case ER_WRONG_PARAMCOUNT_TO_PROCEDURE : return "42000"; #endif -#ifdef ER_FIELD_SPECIFIED_TWICE - case ER_FIELD_SPECIFIED_TWICE : return "42000"; +#ifdef ER_UNKNOWN_TABLE + case ER_UNKNOWN_TABLE : return "42S02"; #endif -#ifdef ER_UNSUPPORTED_EXTENSION - case ER_UNSUPPORTED_EXTENSION : return "42000"; +#ifdef ER_FIELD_SPECIFIED_TWICE + case ER_FIELD_SPECIFIED_TWICE : return "42000"; #endif -#ifdef ER_TABLE_MUST_HAVE_COLUMNS - case ER_TABLE_MUST_HAVE_COLUMNS : return "42000"; +#ifdef ER_UNSUPPORTED_EXTENSION + case ER_UNSUPPORTED_EXTENSION : return "42000"; #endif -#ifdef ER_UNKNOWN_CHARACTER_SET - case ER_UNKNOWN_CHARACTER_SET : return "42000"; +#ifdef ER_TABLE_MUST_HAVE_COLUMNS + case ER_TABLE_MUST_HAVE_COLUMNS : return "42000"; #endif -#ifdef ER_TOO_BIG_ROWSIZE - case ER_TOO_BIG_ROWSIZE : return "42000"; +#ifdef ER_UNKNOWN_CHARACTER_SET + case ER_UNKNOWN_CHARACTER_SET : return "42000"; #endif -#ifdef ER_WRONG_OUTER_JOIN - case ER_WRONG_OUTER_JOIN : return "42000"; +#ifdef ER_TOO_BIG_ROWSIZE + case ER_TOO_BIG_ROWSIZE : return "42000"; #endif -#ifdef ER_NULL_COLUMN_IN_INDEX - case ER_NULL_COLUMN_IN_INDEX : return "42000"; +#ifdef ER_WRONG_OUTER_JOIN + case ER_WRONG_OUTER_JOIN : return "42000"; #endif -#ifdef ER_PASSWORD_ANONYMOUS_USER - case ER_PASSWORD_ANONYMOUS_USER : return "42000"; +#ifdef ER_NULL_COLUMN_IN_INDEX + case ER_NULL_COLUMN_IN_INDEX : return "42000"; #endif -#ifdef ER_PASSWORD_NOT_ALLOWED - case ER_PASSWORD_NOT_ALLOWED : return "42000"; +#ifdef ER_PASSWORD_ANONYMOUS_USER + case ER_PASSWORD_ANONYMOUS_USER : return "42000"; #endif -#ifdef ER_PASSWORD_NO_MATCH - case ER_PASSWORD_NO_MATCH : return "42000"; +#ifdef ER_PASSWORD_NOT_ALLOWED + case ER_PASSWORD_NOT_ALLOWED : return "42000"; #endif -#ifdef ER_WRONG_VALUE_COUNT_ON_ROW - case ER_WRONG_VALUE_COUNT_ON_ROW : return "21S01"; +#ifdef ER_PASSWORD_NO_MATCH + case ER_PASSWORD_NO_MATCH : return "42000"; #endif -#ifdef ER_INVALID_USE_OF_NULL - case ER_INVALID_USE_OF_NULL : return "42000"; +#ifdef ER_WRONG_VALUE_COUNT_ON_ROW + case ER_WRONG_VALUE_COUNT_ON_ROW : return "21S01"; #endif -#ifdef ER_REGEXP_ERROR - case ER_REGEXP_ERROR : return "42000"; +#ifdef ER_INVALID_USE_OF_NULL + case ER_INVALID_USE_OF_NULL : return "22004"; #endif -#ifdef ER_NONEXISTING_GRANT - case ER_NONEXISTING_GRANT : return "42000"; +#ifdef ER_REGEXP_ERROR + case ER_REGEXP_ERROR : return "42000"; #endif -#ifdef ER_TABLEACCESS_DENIED_ERROR - case ER_TABLEACCESS_DENIED_ERROR : return "42000"; +#ifdef ER_MIX_OF_GROUP_FUNC_AND_FIELDS + case ER_MIX_OF_GROUP_FUNC_AND_FIELDS : return "42000"; #endif -#ifdef ER_COLUMNACCESS_DENIED_ERROR - case ER_COLUMNACCESS_DENIED_ERROR : return "42000"; +#ifdef ER_NONEXISTING_GRANT + case ER_NONEXISTING_GRANT : return "42000"; #endif -#ifdef ER_ILLEGAL_GRANT_FOR_TABLE - case ER_ILLEGAL_GRANT_FOR_TABLE : return "42000"; +#ifdef ER_TABLEACCESS_DENIED_ERROR + case ER_TABLEACCESS_DENIED_ERROR : return "42000"; #endif -#ifdef ER_GRANT_WRONG_HOST_OR_USER - case ER_GRANT_WRONG_HOST_OR_USER : return "42000"; +#ifdef ER_COLUMNACCESS_DENIED_ERROR + case ER_COLUMNACCESS_DENIED_ERROR : return "42000"; #endif -#ifdef ER_NO_SUCH_TABLE - case ER_NO_SUCH_TABLE : return "42S02"; +#ifdef ER_ILLEGAL_GRANT_FOR_TABLE + case ER_ILLEGAL_GRANT_FOR_TABLE : return "42000"; #endif -#ifdef ER_NONEXISTING_TABLE_GRANT - case ER_NONEXISTING_TABLE_GRANT : return "42000"; +#ifdef ER_GRANT_WRONG_HOST_OR_USER + case ER_GRANT_WRONG_HOST_OR_USER : return "42000"; #endif -#ifdef ER_NOT_ALLOWED_COMMAND - case ER_NOT_ALLOWED_COMMAND : return "42000"; +#ifdef ER_NO_SUCH_TABLE + case ER_NO_SUCH_TABLE : return "42S02"; #endif -#ifdef ER_SYNTAX_ERROR - case ER_SYNTAX_ERROR : return "42000"; +#ifdef ER_NONEXISTING_TABLE_GRANT + case ER_NONEXISTING_TABLE_GRANT : return "42000"; #endif -#ifdef ER_ABORTING_CONNECTION - case ER_ABORTING_CONNECTION : return "08S01"; +#ifdef ER_NOT_ALLOWED_COMMAND + case ER_NOT_ALLOWED_COMMAND : return "42000"; #endif -#ifdef ER_NET_PACKET_TOO_LARGE - case ER_NET_PACKET_TOO_LARGE : return "08S01"; +#ifdef ER_SYNTAX_ERROR + case ER_SYNTAX_ERROR : return "42000"; #endif -#ifdef ER_NET_READ_ERROR_FROM_PIPE - case ER_NET_READ_ERROR_FROM_PIPE : return "08S01"; +#ifdef ER_ABORTING_CONNECTION + case ER_ABORTING_CONNECTION : return "08S01"; #endif -#ifdef ER_NET_FCNTL_ERROR - case ER_NET_FCNTL_ERROR : return "08S01"; +#ifdef ER_NET_PACKET_TOO_LARGE + case ER_NET_PACKET_TOO_LARGE : return "08S01"; #endif -#ifdef ER_NET_PACKETS_OUT_OF_ORDER - case ER_NET_PACKETS_OUT_OF_ORDER : return "08S01"; +#ifdef ER_NET_READ_ERROR_FROM_PIPE + case ER_NET_READ_ERROR_FROM_PIPE : return "08S01"; #endif -#ifdef ER_NET_UNCOMPRESS_ERROR - case ER_NET_UNCOMPRESS_ERROR : return "08S01"; +#ifdef ER_NET_FCNTL_ERROR + case ER_NET_FCNTL_ERROR : return "08S01"; #endif -#ifdef ER_NET_READ_ERROR - case ER_NET_READ_ERROR : return "08S01"; +#ifdef ER_NET_PACKETS_OUT_OF_ORDER + case ER_NET_PACKETS_OUT_OF_ORDER : return "08S01"; #endif -#ifdef ER_NET_READ_INTERRUPTED - case ER_NET_READ_INTERRUPTED : return "08S01"; +#ifdef ER_NET_UNCOMPRESS_ERROR + case ER_NET_UNCOMPRESS_ERROR : return "08S01"; #endif -#ifdef ER_NET_ERROR_ON_WRITE - case ER_NET_ERROR_ON_WRITE : return "08S01"; +#ifdef ER_NET_READ_ERROR + case ER_NET_READ_ERROR : return "08S01"; #endif -#ifdef ER_NET_WRITE_INTERRUPTED - case ER_NET_WRITE_INTERRUPTED : return "08S01"; +#ifdef ER_NET_READ_INTERRUPTED + case ER_NET_READ_INTERRUPTED : return "08S01"; #endif -#ifdef ER_TOO_LONG_STRING - case ER_TOO_LONG_STRING : return "42000"; +#ifdef ER_NET_ERROR_ON_WRITE + case ER_NET_ERROR_ON_WRITE : return "08S01"; #endif -#ifdef ER_TABLE_CANT_HANDLE_BLOB - case ER_TABLE_CANT_HANDLE_BLOB : return "42000"; +#ifdef ER_NET_WRITE_INTERRUPTED + case ER_NET_WRITE_INTERRUPTED : return "08S01"; #endif -#ifdef ER_TABLE_CANT_HANDLE_AUTO_INCREMENT - case ER_TABLE_CANT_HANDLE_AUTO_INCREMENT : return "42000"; +#ifdef ER_TOO_LONG_STRING + case ER_TOO_LONG_STRING : return "42000"; #endif -#ifdef ER_WRONG_COLUMN_NAME - case ER_WRONG_COLUMN_NAME : return "42000"; +#ifdef ER_TABLE_CANT_HANDLE_BLOB + case ER_TABLE_CANT_HANDLE_BLOB : return "42000"; #endif -#ifdef ER_WRONG_KEY_COLUMN - case ER_WRONG_KEY_COLUMN : return "42000"; +#ifdef ER_TABLE_CANT_HANDLE_AUTO_INCREMENT + case ER_TABLE_CANT_HANDLE_AUTO_INCREMENT : return "42000"; #endif -#ifdef ER_DUP_UNIQUE - case ER_DUP_UNIQUE : return "23000"; +#ifdef ER_WRONG_COLUMN_NAME + case ER_WRONG_COLUMN_NAME : return "42000"; #endif -#ifdef ER_BLOB_KEY_WITHOUT_LENGTH - case ER_BLOB_KEY_WITHOUT_LENGTH : return "42000"; +#ifdef ER_WRONG_KEY_COLUMN + case ER_WRONG_KEY_COLUMN : return "42000"; #endif -#ifdef ER_PRIMARY_CANT_HAVE_NULL - case ER_PRIMARY_CANT_HAVE_NULL : return "42000"; +#ifdef ER_DUP_UNIQUE + case ER_DUP_UNIQUE : return "23000"; #endif -#ifdef ER_TOO_MANY_ROWS - case ER_TOO_MANY_ROWS : return "42000"; +#ifdef ER_BLOB_KEY_WITHOUT_LENGTH + case ER_BLOB_KEY_WITHOUT_LENGTH : return "42000"; #endif -#ifdef ER_REQUIRES_PRIMARY_KEY - case ER_REQUIRES_PRIMARY_KEY : return "42000"; +#ifdef ER_PRIMARY_CANT_HAVE_NULL + case ER_PRIMARY_CANT_HAVE_NULL : return "42000"; #endif -#ifdef ER_CHECK_NO_SUCH_TABLE - case ER_CHECK_NO_SUCH_TABLE : return "42000"; +#ifdef ER_TOO_MANY_ROWS + case ER_TOO_MANY_ROWS : return "42000"; #endif -#ifdef ER_CHECK_NOT_IMPLEMENTED - case ER_CHECK_NOT_IMPLEMENTED : return "42000"; +#ifdef ER_REQUIRES_PRIMARY_KEY + case ER_REQUIRES_PRIMARY_KEY : return "42000"; #endif -#ifdef ER_CANT_DO_THIS_DURING_AN_TRANSACTION - case ER_CANT_DO_THIS_DURING_AN_TRANSACTION: return "25000"; +#ifdef ER_KEY_DOES_NOT_EXITS + case ER_KEY_DOES_NOT_EXITS : return "42000"; #endif -#ifdef ER_NEW_ABORTING_CONNECTION - case ER_NEW_ABORTING_CONNECTION : return "08S01"; +#ifdef ER_CHECK_NO_SUCH_TABLE + case ER_CHECK_NO_SUCH_TABLE : return "42000"; #endif -#ifdef ER_MASTER_NET_READ - case ER_MASTER_NET_READ : return "08S01"; +#ifdef ER_CHECK_NOT_IMPLEMENTED + case ER_CHECK_NOT_IMPLEMENTED : return "42000"; #endif -#ifdef ER_MASTER_NET_WRITE - case ER_MASTER_NET_WRITE : return "08S01"; +#ifdef ER_CANT_DO_THIS_DURING_AN_TRANSACTION + case ER_CANT_DO_THIS_DURING_AN_TRANSACTION : return "25000"; #endif -#ifdef ER_TOO_MANY_USER_CONNECTIONS - case ER_TOO_MANY_USER_CONNECTIONS : return "42000"; +#ifdef ER_NEW_ABORTING_CONNECTION + case ER_NEW_ABORTING_CONNECTION : return "08S01"; #endif -#ifdef ER_READ_ONLY_TRANSACTION - case ER_READ_ONLY_TRANSACTION : return "25000"; +#ifdef ER_MASTER_NET_READ + case ER_MASTER_NET_READ : return "08S01"; #endif -#ifdef ER_LOCK_DEADLOCK - case ER_LOCK_DEADLOCK : return "40001"; +#ifdef ER_MASTER_NET_WRITE + case ER_MASTER_NET_WRITE : return "08S01"; #endif -#ifdef ER_NO_REFERENCED_ROW - case ER_NO_REFERENCED_ROW : return "23000"; +#ifdef ER_TOO_MANY_USER_CONNECTIONS + case ER_TOO_MANY_USER_CONNECTIONS : return "42000"; #endif -#ifdef ER_ROW_IS_REFERENCED - case ER_ROW_IS_REFERENCED : return "23000"; +#ifdef ER_READ_ONLY_TRANSACTION + case ER_READ_ONLY_TRANSACTION : return "25000"; #endif -#ifdef ER_CONNECT_TO_MASTER - case ER_CONNECT_TO_MASTER : return "08S01"; +#ifdef ER_NO_PERMISSION_TO_CREATE_USER + case ER_NO_PERMISSION_TO_CREATE_USER : return "42000"; #endif -#ifdef ER_USER_LIMIT_REACHED - case ER_USER_LIMIT_REACHED : return "42000"; +#ifdef ER_LOCK_DEADLOCK + case ER_LOCK_DEADLOCK : return "40001"; #endif -#ifdef ER_NO_DEFAULT - case ER_NO_DEFAULT : return "42000"; +#ifdef ER_NO_REFERENCED_ROW + case ER_NO_REFERENCED_ROW : return "23000"; #endif -#ifdef ER_WRONG_VALUE_FOR_VAR - case ER_WRONG_VALUE_FOR_VAR : return "42000"; +#ifdef ER_ROW_IS_REFERENCED + case ER_ROW_IS_REFERENCED : return "23000"; #endif -#ifdef ER_WRONG_TYPE_FOR_VAR - case ER_WRONG_TYPE_FOR_VAR : return "42000"; +#ifdef ER_CONNECT_TO_MASTER + case ER_CONNECT_TO_MASTER : return "08S01"; #endif -#ifdef ER_CANT_USE_OPTION_HERE - case ER_CANT_USE_OPTION_HERE : return "42000"; +#ifdef ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT + case ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT : return "21000"; #endif -#ifdef ER_NOT_SUPPORTED_YET - case ER_NOT_SUPPORTED_YET : return "42000"; +#ifdef ER_USER_LIMIT_REACHED + case ER_USER_LIMIT_REACHED : return "42000"; #endif -#ifdef ER_WRONG_FK_DEF - case ER_WRONG_FK_DEF : return "42000"; +#ifdef ER_SPECIFIC_ACCESS_DENIED_ERROR + case ER_SPECIFIC_ACCESS_DENIED_ERROR : return "42000"; #endif -#ifdef ER_OPERAND_COLUMNS - case ER_OPERAND_COLUMNS : return "21000"; +#ifdef ER_NO_DEFAULT + case ER_NO_DEFAULT : return "42000"; #endif -#ifdef ER_SUBQUERY_NO_1_ROW - case ER_SUBQUERY_NO_1_ROW : return "21000"; +#ifdef ER_WRONG_VALUE_FOR_VAR + case ER_WRONG_VALUE_FOR_VAR : return "42000"; #endif -#ifdef ER_ILLEGAL_REFERENCE - case ER_ILLEGAL_REFERENCE : return "42S22"; +#ifdef ER_WRONG_TYPE_FOR_VAR + case ER_WRONG_TYPE_FOR_VAR : return "42000"; #endif -#ifdef ER_DERIVED_MUST_HAVE_ALIAS - case ER_DERIVED_MUST_HAVE_ALIAS : return "42000"; +#ifdef ER_CANT_USE_OPTION_HERE + case ER_CANT_USE_OPTION_HERE : return "42000"; #endif -#ifdef ER_SELECT_REDUCED - case ER_SELECT_REDUCED : return "01000"; +#ifdef ER_NOT_SUPPORTED_YET + case ER_NOT_SUPPORTED_YET : return "42000"; #endif -#ifdef ER_TABLENAME_NOT_ALLOWED_HERE - case ER_TABLENAME_NOT_ALLOWED_HERE : return "42000"; +#ifdef ER_WRONG_FK_DEF + case ER_WRONG_FK_DEF : return "42000"; #endif -#ifdef ER_NOT_SUPPORTED_AUTH_MODE - case ER_NOT_SUPPORTED_AUTH_MODE : return "08004"; +#ifdef ER_OPERAND_COLUMNS + case ER_OPERAND_COLUMNS : return "21000"; #endif -#ifdef ER_SPATIAL_CANT_HAVE_NULL - case ER_SPATIAL_CANT_HAVE_NULL : return "42000"; +#ifdef ER_SUBQUERY_NO_1_ROW + case ER_SUBQUERY_NO_1_ROW : return "21000"; #endif -#ifdef ER_COLLATION_CHARSET_MISMATCH - case ER_COLLATION_CHARSET_MISMATCH : return "42000"; +#ifdef ER_ILLEGAL_REFERENCE + case ER_ILLEGAL_REFERENCE : return "42S22"; #endif -#ifdef ER_WARN_TOO_FEW_RECORDS - case ER_WARN_TOO_FEW_RECORDS : return "01000"; +#ifdef ER_DERIVED_MUST_HAVE_ALIAS + case ER_DERIVED_MUST_HAVE_ALIAS : return "42000"; #endif -#ifdef ER_WARN_TOO_MANY_RECORDS - case ER_WARN_TOO_MANY_RECORDS : return "01000"; +#ifdef ER_SELECT_REDUCED + case ER_SELECT_REDUCED : return "01000"; #endif -#ifdef ER_WARN_NULL_TO_NOTNULL - case ER_WARN_NULL_TO_NOTNULL : return "01000"; +#ifdef ER_TABLENAME_NOT_ALLOWED_HERE + case ER_TABLENAME_NOT_ALLOWED_HERE : return "42000"; #endif -#ifdef ER_WARN_DATA_OUT_OF_RANGE - case ER_WARN_DATA_OUT_OF_RANGE : return "01000"; +#ifdef ER_NOT_SUPPORTED_AUTH_MODE + case ER_NOT_SUPPORTED_AUTH_MODE : return "08004"; #endif -#ifdef ER_WARN_DATA_TRUNCATED - case ER_WARN_DATA_TRUNCATED : return "01000"; +#ifdef ER_SPATIAL_CANT_HAVE_NULL + case ER_SPATIAL_CANT_HAVE_NULL : return "42000"; #endif -#ifdef ER_WRONG_NAME_FOR_INDEX - case ER_WRONG_NAME_FOR_INDEX : return "42000"; +#ifdef ER_COLLATION_CHARSET_MISMATCH + case ER_COLLATION_CHARSET_MISMATCH : return "42000"; #endif -#ifdef ER_WRONG_NAME_FOR_CATALOG - case ER_WRONG_NAME_FOR_CATALOG : return "42000"; +#ifdef ER_WARN_TOO_FEW_RECORDS + case ER_WARN_TOO_FEW_RECORDS : return "01000"; #endif -#ifdef ER_UNKNOWN_STORAGE_ENGINE - case ER_UNKNOWN_STORAGE_ENGINE : return "42000"; +#ifdef ER_WARN_TOO_MANY_RECORDS + case ER_WARN_TOO_MANY_RECORDS : return "01000"; +#endif +#ifdef ER_WARN_NULL_TO_NOTNULL + case ER_WARN_NULL_TO_NOTNULL : return "22004"; +#endif +#ifdef ER_WARN_DATA_OUT_OF_RANGE + case ER_WARN_DATA_OUT_OF_RANGE : return "22003"; +#endif +#ifdef ER_WRONG_NAME_FOR_INDEX + case ER_WRONG_NAME_FOR_INDEX : return "42000"; +#endif +#ifdef ER_WRONG_NAME_FOR_CATALOG + case ER_WRONG_NAME_FOR_CATALOG : return "42000"; +#endif +#ifdef ER_UNKNOWN_STORAGE_ENGINE + case ER_UNKNOWN_STORAGE_ENGINE : return "42000"; +#endif +#ifdef ER_TRUNCATED_WRONG_VALUE + case ER_TRUNCATED_WRONG_VALUE : return "22007"; +#endif +#ifdef ER_SP_NO_RECURSIVE_CREATE + case ER_SP_NO_RECURSIVE_CREATE : return "2F003"; +#endif +#ifdef ER_SP_ALREADY_EXISTS + case ER_SP_ALREADY_EXISTS : return "42000"; +#endif +#ifdef ER_SP_DOES_NOT_EXIST + case ER_SP_DOES_NOT_EXIST : return "42000"; +#endif +#ifdef ER_SP_LILABEL_MISMATCH + case ER_SP_LILABEL_MISMATCH : return "42000"; +#endif +#ifdef ER_SP_LABEL_REDEFINE + case ER_SP_LABEL_REDEFINE : return "42000"; +#endif +#ifdef ER_SP_LABEL_MISMATCH + case ER_SP_LABEL_MISMATCH : return "42000"; +#endif +#ifdef ER_SP_UNINIT_VAR + case ER_SP_UNINIT_VAR : return "01000"; +#endif +#ifdef ER_SP_BADSELECT + case ER_SP_BADSELECT : return "0A000"; +#endif +#ifdef ER_SP_BADRETURN + case ER_SP_BADRETURN : return "42000"; +#endif +#ifdef ER_SP_BADSTATEMENT + case ER_SP_BADSTATEMENT : return "0A000"; +#endif +#ifdef ER_UPDATE_LOG_DEPRECATED_IGNORED + case ER_UPDATE_LOG_DEPRECATED_IGNORED : return "42000"; +#endif +#ifdef ER_UPDATE_LOG_DEPRECATED_TRANSLATED + case ER_UPDATE_LOG_DEPRECATED_TRANSLATED : return "42000"; +#endif +#ifdef ER_QUERY_INTERRUPTED + case ER_QUERY_INTERRUPTED : return "70100"; +#endif +#ifdef ER_SP_WRONG_NO_OF_ARGS + case ER_SP_WRONG_NO_OF_ARGS : return "42000"; +#endif +#ifdef ER_SP_COND_MISMATCH + case ER_SP_COND_MISMATCH : return "42000"; +#endif +#ifdef ER_SP_NORETURN + case ER_SP_NORETURN : return "42000"; +#endif +#ifdef ER_SP_NORETURNEND + case ER_SP_NORETURNEND : return "2F005"; +#endif +#ifdef ER_SP_BAD_CURSOR_QUERY + case ER_SP_BAD_CURSOR_QUERY : return "42000"; +#endif +#ifdef ER_SP_BAD_CURSOR_SELECT + case ER_SP_BAD_CURSOR_SELECT : return "42000"; +#endif +#ifdef ER_SP_CURSOR_MISMATCH + case ER_SP_CURSOR_MISMATCH : return "42000"; +#endif +#ifdef ER_SP_CURSOR_ALREADY_OPEN + case ER_SP_CURSOR_ALREADY_OPEN : return "24000"; +#endif +#ifdef ER_SP_CURSOR_NOT_OPEN + case ER_SP_CURSOR_NOT_OPEN : return "24000"; +#endif +#ifdef ER_SP_UNDECLARED_VAR + case ER_SP_UNDECLARED_VAR : return "42000"; +#endif +#ifdef ER_SP_FETCH_NO_DATA + case ER_SP_FETCH_NO_DATA : return "02000"; +#endif +#ifdef ER_SP_DUP_PARAM + case ER_SP_DUP_PARAM : return "42000"; +#endif +#ifdef ER_SP_DUP_VAR + case ER_SP_DUP_VAR : return "42000"; +#endif +#ifdef ER_SP_DUP_COND + case ER_SP_DUP_COND : return "42000"; +#endif +#ifdef ER_SP_DUP_CURS + case ER_SP_DUP_CURS : return "42000"; +#endif +#ifdef ER_SP_SUBSELECT_NYI + case ER_SP_SUBSELECT_NYI : return "0A000"; +#endif +#ifdef ER_STMT_NOT_ALLOWED_IN_SF_OR_TRG + case ER_STMT_NOT_ALLOWED_IN_SF_OR_TRG : return "0A000"; +#endif +#ifdef ER_SP_VARCOND_AFTER_CURSHNDLR + case ER_SP_VARCOND_AFTER_CURSHNDLR : return "42000"; +#endif +#ifdef ER_SP_CURSOR_AFTER_HANDLER + case ER_SP_CURSOR_AFTER_HANDLER : return "42000"; +#endif +#ifdef ER_SP_CASE_NOT_FOUND + case ER_SP_CASE_NOT_FOUND : return "20000"; +#endif +#ifdef ER_DIVISION_BY_ZERO + case ER_DIVISION_BY_ZERO : return "22012"; +#endif +#ifdef ER_ILLEGAL_VALUE_FOR_TYPE + case ER_ILLEGAL_VALUE_FOR_TYPE : return "22007"; +#endif +#ifdef ER_PROCACCESS_DENIED_ERROR + case ER_PROCACCESS_DENIED_ERROR : return "42000"; +#endif +#ifdef ER_XAER_NOTA + case ER_XAER_NOTA : return "XAE04"; +#endif +#ifdef ER_XAER_INVAL + case ER_XAER_INVAL : return "XAE05"; +#endif +#ifdef ER_XAER_RMFAIL + case ER_XAER_RMFAIL : return "XAE07"; +#endif +#ifdef ER_XAER_OUTSIDE + case ER_XAER_OUTSIDE : return "XAE09"; +#endif +#ifdef ER_XAER_RMERR + case ER_XAER_RMERR : return "XAE03"; +#endif +#ifdef ER_XA_RBROLLBACK + case ER_XA_RBROLLBACK : return "XA100"; +#endif +#ifdef ER_NONEXISTING_PROC_GRANT + case ER_NONEXISTING_PROC_GRANT : return "42000"; +#endif +#ifdef ER_DATA_TOO_LONG + case ER_DATA_TOO_LONG : return "22001"; +#endif +#ifdef ER_SP_BAD_SQLSTATE + case ER_SP_BAD_SQLSTATE : return "42000"; +#endif +#ifdef ER_CANT_CREATE_USER_WITH_GRANT + case ER_CANT_CREATE_USER_WITH_GRANT : return "42000"; +#endif +#ifdef ER_SP_DUP_HANDLER + case ER_SP_DUP_HANDLER : return "42000"; +#endif +#ifdef ER_SP_NOT_VAR_ARG + case ER_SP_NOT_VAR_ARG : return "42000"; +#endif +#ifdef ER_SP_NO_RETSET + case ER_SP_NO_RETSET : return "0A000"; +#endif +#ifdef ER_CANT_CREATE_GEOMETRY_OBJECT + case ER_CANT_CREATE_GEOMETRY_OBJECT : return "22003"; +#endif +#ifdef ER_TOO_BIG_SCALE + case ER_TOO_BIG_SCALE : return "42000"; +#endif +#ifdef ER_TOO_BIG_PRECISION + case ER_TOO_BIG_PRECISION : return "42000"; +#endif +#ifdef ER_M_BIGGER_THAN_D + case ER_M_BIGGER_THAN_D : return "42000"; +#endif +#ifdef ER_TOO_LONG_BODY + case ER_TOO_LONG_BODY : return "42000"; +#endif +#ifdef ER_TOO_BIG_DISPLAYWIDTH + case ER_TOO_BIG_DISPLAYWIDTH : return "42000"; +#endif +#ifdef ER_XAER_DUPID + case ER_XAER_DUPID : return "XAE08"; +#endif +#ifdef ER_DATETIME_FUNCTION_OVERFLOW + case ER_DATETIME_FUNCTION_OVERFLOW : return "22008"; +#endif +#ifdef ER_ROW_IS_REFERENCED_2 + case ER_ROW_IS_REFERENCED_2 : return "23000"; +#endif +#ifdef ER_NO_REFERENCED_ROW_2 + case ER_NO_REFERENCED_ROW_2 : return "23000"; +#endif +#ifdef ER_SP_BAD_VAR_SHADOW + case ER_SP_BAD_VAR_SHADOW : return "42000"; +#endif +#ifdef ER_SP_WRONG_NAME + case ER_SP_WRONG_NAME : return "42000"; +#endif +#ifdef ER_SP_NO_AGGREGATE + case ER_SP_NO_AGGREGATE : return "42000"; +#endif +#ifdef ER_MAX_PREPARED_STMT_COUNT_REACHED + case ER_MAX_PREPARED_STMT_COUNT_REACHED : return "42000"; +#endif +#ifdef ER_NON_GROUPING_FIELD_USED + case ER_NON_GROUPING_FIELD_USED : return "42000"; +#endif +#ifdef ER_FOREIGN_DUPLICATE_KEY + case ER_FOREIGN_DUPLICATE_KEY : return "23000"; +#endif +#ifdef ER_CANT_CHANGE_TX_ISOLATION + case ER_CANT_CHANGE_TX_ISOLATION : return "25001"; +#endif +#ifdef ER_WRONG_PARAMCOUNT_TO_NATIVE_FCT + case ER_WRONG_PARAMCOUNT_TO_NATIVE_FCT : return "42000"; +#endif +#ifdef ER_WRONG_PARAMETERS_TO_NATIVE_FCT + case ER_WRONG_PARAMETERS_TO_NATIVE_FCT : return "42000"; +#endif +#ifdef ER_WRONG_PARAMETERS_TO_STORED_FCT + case ER_WRONG_PARAMETERS_TO_STORED_FCT : return "42000"; +#endif +#ifdef ER_DUP_ENTRY_WITH_KEY_NAME + case ER_DUP_ENTRY_WITH_KEY_NAME : return "23000"; +#endif +#ifdef ER_XA_RBTIMEOUT + case ER_XA_RBTIMEOUT : return "XA106"; +#endif +#ifdef ER_XA_RBDEADLOCK + case ER_XA_RBDEADLOCK : return "XA102"; +#endif +#ifdef ER_FUNC_INEXISTENT_NAME_COLLISION + case ER_FUNC_INEXISTENT_NAME_COLLISION : return "42000"; +#endif +#ifdef ER_DUP_SIGNAL_SET + case ER_DUP_SIGNAL_SET : return "42000"; +#endif +#ifdef ER_SIGNAL_WARN + case ER_SIGNAL_WARN : return "01000"; +#endif +#ifdef ER_SIGNAL_NOT_FOUND + case ER_SIGNAL_NOT_FOUND : return "02000"; +#endif +#ifdef ER_SIGNAL_EXCEPTION + case ER_SIGNAL_EXCEPTION : return "HY000"; +#endif +#ifdef ER_RESIGNAL_WITHOUT_ACTIVE_HANDLER + case ER_RESIGNAL_WITHOUT_ACTIVE_HANDLER : return "0K000"; +#endif +#ifdef ER_SPATIAL_MUST_HAVE_GEOM_COL + case ER_SPATIAL_MUST_HAVE_GEOM_COL : return "42000"; +#endif +#ifdef ER_DATA_OUT_OF_RANGE + case ER_DATA_OUT_OF_RANGE : return "22003"; #endif From 604fa1537a2e2e8556c8d78df27d601440577c32 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 31 Aug 2011 18:18:23 +0000 Subject: [PATCH 0686/2394] Fix valgrind error (sending of initialized bytes over the network). When the compression was successful the compressed data + uninitialized data at the end was sent to the server, because the length of the compressed payload wasn't correctly calculated (actually the length of the uncompressed payload as assumed). However, the uncompress() function has internally the length of the real payload and skips the binary trash at the end - thus no data damage occurs! --- ext/mysqlnd/mysqlnd_net.c | 8 +++++--- ext/mysqlnd/mysqlnd_structs.h | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index 606d919e3bd1c..15a539fdb99eb 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -272,7 +272,7 @@ MYSQLND_METHOD(mysqlnd_net, send)(MYSQLND * const conn, zend_uchar * const buf, STORE_HEADER_SIZE(safe_storage, uncompressed_payload); int3store(uncompressed_payload, to_be_sent); int1store(uncompressed_payload + 3, net->packet_no); - if (PASS == net->m.encode((compress_buf + COMPRESSED_HEADER_SIZE + MYSQLND_HEADER_SIZE), tmp_complen, + if (PASS == net->m.encode((compress_buf + COMPRESSED_HEADER_SIZE + MYSQLND_HEADER_SIZE), &tmp_complen, uncompressed_payload, to_be_sent + MYSQLND_HEADER_SIZE TSRMLS_CC)) { int3store(compress_buf + MYSQLND_HEADER_SIZE, to_be_sent + MYSQLND_HEADER_SIZE); @@ -498,20 +498,22 @@ MYSQLND_METHOD(mysqlnd_net, decode)(zend_uchar * uncompressed_data, size_t uncom /* {{{ mysqlnd_net::encode */ static enum_func_status -MYSQLND_METHOD(mysqlnd_net, encode)(zend_uchar * compress_buffer, size_t compress_buffer_len, +MYSQLND_METHOD(mysqlnd_net, encode)(zend_uchar * compress_buffer, size_t * compress_buffer_len, const zend_uchar * const uncompressed_data, size_t uncompressed_data_len TSRMLS_DC) { #ifdef MYSQLND_COMPRESSION_ENABLED int error; - uLongf tmp_complen = compress_buffer_len; + uLongf tmp_complen = *compress_buffer_len; DBG_ENTER("mysqlnd_net::encode"); error = compress(compress_buffer, &tmp_complen, uncompressed_data, uncompressed_data_len); if (error != Z_OK) { DBG_INF_FMT("compression NOT successful. error=%d Z_OK=%d Z_BUF_ERROR=%d Z_MEM_ERROR=%d", error, Z_OK, Z_BUF_ERROR, Z_MEM_ERROR); } else { + *compress_buffer_len = tmp_complen; DBG_INF_FMT("compression successful. compressed size=%lu", tmp_complen); } + DBG_RETURN(error == Z_OK? PASS:FAIL); #else DBG_ENTER("mysqlnd_net::encode"); diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 8c3762f9a4bfa..b0b4d9bd76b98 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -267,7 +267,7 @@ typedef enum_func_status (*func_mysqlnd_net__set_client_option)(MYSQLND_NET * co typedef enum_func_status (*func_mysqlnd_net__network_read)(MYSQLND * conn, zend_uchar * buffer, size_t count TSRMLS_DC); typedef size_t (*func_mysqlnd_net__network_write)(MYSQLND * const conn, const zend_uchar * const buf, size_t count TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_net__decode)(zend_uchar * uncompressed_data, size_t uncompressed_data_len, const zend_uchar * const compressed_data, size_t compressed_data_len TSRMLS_DC); -typedef enum_func_status (*func_mysqlnd_net__encode)(zend_uchar * compress_buffer, size_t compress_buffer_len, const zend_uchar * const uncompressed_data, size_t uncompressed_data_len TSRMLS_DC); +typedef enum_func_status (*func_mysqlnd_net__encode)(zend_uchar * compress_buffer, size_t * compress_buffer_len, const zend_uchar * const uncompressed_data, size_t uncompressed_data_len TSRMLS_DC); typedef size_t (*func_mysqlnd_net__consume_uneaten_data)(MYSQLND_NET * const net, enum php_mysqlnd_server_command cmd TSRMLS_DC); typedef void (*func_mysqlnd_net__free_contents)(MYSQLND_NET * net TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_net__enable_ssl)(MYSQLND_NET * const net TSRMLS_DC); From 892ac1fe588a38b20489bd6391adacda36382878 Mon Sep 17 00:00:00 2001 From: Tjerk Anne Meesters Date: Wed, 31 Aug 2011 18:26:23 +0000 Subject: [PATCH 0687/2394] Fixed expect format to ignore the textual error message from readlink(). Bug #55555 --- .../tests/file/readlink_realpath_variation3.phpt | 12 ++++++------ ext/standard/tests/file/readlink_variation1.phpt | 14 +++++++------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/ext/standard/tests/file/readlink_realpath_variation3.phpt b/ext/standard/tests/file/readlink_realpath_variation3.phpt index 70e8d0c949091..3766a5b43adf2 100644 --- a/ext/standard/tests/file/readlink_realpath_variation3.phpt +++ b/ext/standard/tests/file/readlink_realpath_variation3.phpt @@ -46,32 +46,32 @@ echo "Done\n"; *** Testing readlink() and realpath() with linkname as empty string, NULL and single space *** -- Iteration1 -- -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) %s -- Iteration2 -- -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) %s -- Iteration3 -- -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) string(%d) "%s" -- Iteration4 -- -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) string(%d) "%s" -- Iteration5 -- -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) string(%d) "%s" -- Iteration6 -- -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) string(%d) "%s" Done diff --git a/ext/standard/tests/file/readlink_variation1.phpt b/ext/standard/tests/file/readlink_variation1.phpt index 49dc6a540b391..1dae17cbd4952 100644 --- a/ext/standard/tests/file/readlink_variation1.phpt +++ b/ext/standard/tests/file/readlink_variation1.phpt @@ -50,28 +50,28 @@ unlink($file_path."/readlink_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) Warning: readlink() expects parameter 1 to be string, resource given in %s on line %d NULL -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) -Warning: readlink(): No such file or directory in %s on line %d +Warning: readlink(): %s in %s on line %d bool(false) *** Done *** From ce6b3f95f2bc2c8e2486a88df37912a3c105084f Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Wed, 31 Aug 2011 19:44:39 +0000 Subject: [PATCH 0688/2394] test coverage for SNMP::ERRNO_MULTIPLE_SET_QUERIES --- ext/snmp/tests/snmp-object-errno-errstr.phpt | 38 +++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/ext/snmp/tests/snmp-object-errno-errstr.phpt b/ext/snmp/tests/snmp-object-errno-errstr.phpt index e6dfd603df5d3..b6047af857f9b 100644 --- a/ext/snmp/tests/snmp-object-errno-errstr.phpt +++ b/ext/snmp/tests/snmp-object-errno-errstr.phpt @@ -73,6 +73,30 @@ $oid1 = 'SNMPv2-MIB::sysContact.0'; var_dump(@$session->set($oid1, 'q', 'blah')); var_dump($session->getErrno() == SNMP::ERRNO_OID_PARSING_ERROR); var_dump($session->getError()); + +echo "SNMP::ERRNO_MULTIPLE_SET_QUERIES\n"; +$oid1 = 'SNMPv2-MIB::sysContact.0'; +$oid2 = 'SNMPv2-MIB::sysLocation.0'; +$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries); +$session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass); +$session->max_oids = 1; +$oldvalue1 = $session->get($oid1); +$newvalue1 = $oldvalue1 . '0'; +$oldvalue2 = $session->get($oid2); +$newvalue2 = $oldvalue2 . '0'; +$z = @$session->set(array($oid1, $oid2), array('s','s'), array($newvalue1, $newvalue2)); +var_dump($z); +var_dump($session->getErrno() == SNMP::ERRNO_MULTIPLE_SET_QUERIES); +var_dump($session->getError()); +var_dump(($session->get($oid1) === $newvalue1)); +var_dump(($session->get($oid2) === $newvalue2)); +$z = @$session->set(array($oid1, $oid2), array('s','s'), array($oldvalue1, $oldvalue2)); +var_dump($z); +var_dump($session->getErrno() == SNMP::ERRNO_MULTIPLE_SET_QUERIES); +var_dump($session->getError()); +var_dump(($session->get($oid1) === $oldvalue1)); +var_dump(($session->get($oid2) === $oldvalue2)); +var_dump($session->close()); ?> --EXPECTF-- SNMP::ERRNO_NOERROR @@ -108,4 +132,16 @@ string(42) "Invalid object identifier: .1.3.6.1.2..1.1" SET: Wrong type bool(false) bool(true) -string(129) "Could not add variable: OID='.iso.org.dod.internet.mgmt.mib-2.system.sysContact.0' type='q' value='blah': Bad variable type ("q")" \ No newline at end of file +string(129) "Could not add variable: OID='.iso.org.dod.internet.mgmt.mib-2.system.sysContact.0' type='q' value='blah': Bad variable type ("q")" +SNMP::ERRNO_MULTIPLE_SET_QUERIES +bool(true) +bool(true) +string(74) "Can not fit all OIDs for SET query into one packet, using multiple queries" +bool(true) +bool(true) +bool(true) +bool(true) +string(74) "Can not fit all OIDs for SET query into one packet, using multiple queries" +bool(true) +bool(true) +bool(true) From b5152bcff2f56e9ee1ad2460e3126f4e34a703f1 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 20:07:44 +0000 Subject: [PATCH 0689/2394] - typo --- tests/basic/bug45986.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/basic/bug45986.phpt b/tests/basic/bug45986.phpt index 5745d272c4155..829f336022747 100644 --- a/tests/basic/bug45986.phpt +++ b/tests/basic/bug45986.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #45986 (wrong error messag for a non existant file on rename) +Bug #45986 (wrong error message for a non existant file on rename) --CREDITS-- Sebastian Schürmann sebs@php.net From 05afcc2b265e3f398da3492c3da263910a6b5114 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 20:10:22 +0000 Subject: [PATCH 0690/2394] - error msg may vary --- tests/basic/bug45986.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/basic/bug45986.phpt b/tests/basic/bug45986.phpt index 829f336022747..1c30f10403dc0 100644 --- a/tests/basic/bug45986.phpt +++ b/tests/basic/bug45986.phpt @@ -8,5 +8,5 @@ Testfest 2009 Munich ---EXPECTREGEX-- -.*No such.* +--EXPECTF-- +Warning: %s in %sbug45986.php on line 2 From 133b00040430388c841db66d8003e4d91225ec73 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 20:14:13 +0000 Subject: [PATCH 0691/2394] - error msg may vary (parser) --- tests/basic/bug51709_1.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/basic/bug51709_1.phpt b/tests/basic/bug51709_1.phpt index e80e08ac73580..49b529b388f02 100644 --- a/tests/basic/bug51709_1.phpt +++ b/tests/basic/bug51709_1.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: syntax error, unexpected "for (T_FOR)", expecting "identifier (T_STRING)" in %sbug51709_1.php on line %d +Parse error: %s error, %s(T_STRING)%s in %sbug51709_1.php on line %d From 2c5c7a2ef3fe1913ef71c4cd64720d8c7c12584e Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Wed, 31 Aug 2011 20:15:32 +0000 Subject: [PATCH 0692/2394] tune text align --- ext/snmp/snmp.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index e8e6e8b3f6e8f..b5f2df52f86db 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -112,13 +112,13 @@ typedef struct snmp_session php_snmp_session; } \ } -#define PHP_SNMP_ERRNO_NOERROR 0 -#define PHP_SNMP_ERRNO_GENERIC 1 -#define PHP_SNMP_ERRNO_TIMEOUT 2 -#define PHP_SNMP_ERRNO_ERROR_IN_REPLY 3 -#define PHP_SNMP_ERRNO_OID_NOT_INCREASING 4 -#define PHP_SNMP_ERRNO_OID_PARSING_ERROR 5 -#define PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES 6 +#define PHP_SNMP_ERRNO_NOERROR 0 +#define PHP_SNMP_ERRNO_GENERIC 1 +#define PHP_SNMP_ERRNO_TIMEOUT 2 +#define PHP_SNMP_ERRNO_ERROR_IN_REPLY 3 +#define PHP_SNMP_ERRNO_OID_NOT_INCREASING 4 +#define PHP_SNMP_ERRNO_OID_PARSING_ERROR 5 +#define PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES 6 ZEND_DECLARE_MODULE_GLOBALS(snmp) static PHP_GINIT_FUNCTION(snmp); From 7953b9b39ba6a88c05359b8701dd7e855694b78f Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 20:16:11 +0000 Subject: [PATCH 0693/2394] - error msg may vary (parser) --- tests/basic/bug51709_2.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/basic/bug51709_2.phpt b/tests/basic/bug51709_2.phpt index 49b7fd28dad7e..1d4440f5c345b 100644 --- a/tests/basic/bug51709_2.phpt +++ b/tests/basic/bug51709_2.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: syntax error, unexpected "goto (T_GOTO)", expecting "identifier (T_STRING)" in %sbug51709_2.php on line %d +Parse error: %s error, %s(T_STRING)%s in %sbug51709_2.php on line %d From 39b0be5126063008979a4fdb8175464cc10c1b46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 31 Aug 2011 20:30:08 +0000 Subject: [PATCH 0694/2394] - Register extensions using mysqlnd (mysql, myslqi, pdo_mysql) with mysqlnd --- ext/mysql/php_mysql.c | 29 +++++++++++++++++++++++++++++ ext/mysqli/mysqli.c | 29 +++++++++++++++++++++++++++++ ext/mysqlnd/mysqlnd.c | 38 ++++++++++++++++++++++++++++++++++++++ ext/mysqlnd/mysqlnd.h | 9 +++++++++ ext/mysqlnd/php_mysqlnd.c | 23 ++++++++++++++++++++++- ext/pdo_mysql/pdo_mysql.c | 28 ++++++++++++++++++++++++++++ 6 files changed, 155 insertions(+), 1 deletion(-) diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index 3f9a7d653a79b..89fe7b15ff832 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -529,6 +529,31 @@ static PHP_GINIT_FUNCTION(mysql) } /* }}} */ +#ifdef MYSQL_USE_MYSQLND +static MYSQLND *mysql_convert_zv_to_mysqlnd(zval *zv) +{ + php_mysql_conn *mysql; + + if (Z_TYPE_P(zv) != IS_RESOURCE) { + /* Might be nicer to check resource type, too, but ext/mysql is the only one using resources so emitting an error is not to bad, while usually this hook should be silent */ + return NULL; + } + + mysql = (php_mysql_conn *)zend_fetch_resource(&zv TSRMLS_CC, -1, "MySQL-Link", NULL, 2, le_link, le_plink); + + if (!mysql) { + return NULL; + } + + return mysql->conn; +} + +static mysqlnd_api_extension_t mysqlnd_api_ext = { + &mysql_module_entry, + mysql_convert_zv_to_mysqlnd +}; +#endif + /* {{{ PHP_MINIT_FUNCTION */ ZEND_MODULE_STARTUP_D(mysql) @@ -557,6 +582,10 @@ ZEND_MODULE_STARTUP_D(mysql) #endif #endif +#ifdef MYSQL_USE_MYSQLND + mysqlnd_register_api_extension(&mysqlnd_api_ext); +#endif + return SUCCESS; } /* }}} */ diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index 4ba13f5116639..c94ddd03db06c 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -30,6 +30,7 @@ #include "php_ini.h" #include "ext/standard/info.h" #include "ext/standard/php_string.h" +#include "php_mysqli.h" #include "php_mysqli_structs.h" #include "mysqli_priv.h" #include "zend_exceptions.h" @@ -526,6 +527,29 @@ PHP_MYSQLI_EXPORT(zend_object_value) mysqli_objects_new(zend_class_entry *class_ } /* }}} */ +#ifdef MYSQLI_USE_MYSQLND +static MYSQLND *mysqli_convert_zv_to_mysqlnd(zval *zv) +{ + if (Z_TYPE_P(zv) == IS_OBJECT && Z_OBJCE_P(zv) == mysqli_link_class_entry) { + MY_MYSQL *mysql; + MYSQLI_RESOURCE *my_res; + mysqli_object *intern = (mysqli_object *)zend_object_store_get_object(zv TSRMLS_CC); + if (!(my_res = (MYSQLI_RESOURCE *)intern->ptr)) { + /* We know that we have a mysqli object, so this failure should be emitted */ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Couldn't fetch %s", intern->zo.ce->name); + return NULL; + } + mysql = ((MY_MYSQL *)my_res->ptr)->mysql; + return mysql ? mysql->mysql : NULL; + } + return NULL; +} + +static mysqlnd_api_extension_t mysqli_api_ext = { + &mysqli_module_entry, + mysqli_convert_zv_to_mysqlnd +}; +#endif /* {{{ PHP_INI_BEGIN */ @@ -813,6 +837,11 @@ PHP_MINIT_FUNCTION(mysqli) REGISTER_LONG_CONSTANT("MYSQLI_REFRESH_BACKUP_LOG", REFRESH_BACKUP_LOG, CONST_CS | CONST_PERSISTENT); #endif + +#ifdef MYSQL_USE_MYSQLND + mysqlnd_register_api_extension(&mysqli_api_ext); +#endif + return SUCCESS; } /* }}} */ diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 7f04d35517ebb..5db03278dc35b 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -68,6 +68,7 @@ static struct st_mysqlnd_conn_methods *mysqlnd_conn_methods; static struct st_mysqlnd_plugin_core mysqlnd_plugin_core; +static HashTable mysqlnd_api_ext_ht; /* {{{ mysqlnd_error_list_pdtor */ static void @@ -92,6 +93,7 @@ PHPAPI void mysqlnd_library_end(TSRMLS_D) mysqlnd_stats_end(mysqlnd_global_stats); mysqlnd_global_stats = NULL; mysqlnd_library_initted = FALSE; + zend_hash_destroy(&mysqlnd_api_ext_ht); } } /* }}} */ @@ -2542,10 +2544,46 @@ PHPAPI void mysqlnd_library_init(TSRMLS_D) mysqlnd_example_plugin_register(TSRMLS_C); mysqlnd_debug_trace_plugin_register(TSRMLS_C); mysqlnd_register_builtin_authentication_plugins(TSRMLS_C); + + zend_hash_init(&mysqlnd_api_ext_ht, 3, NULL, NULL, 1); } } /* }}} */ +/* {{{ myslqnd_get_api_extensions */ +PHPAPI HashTable *mysqlnd_get_api_extensions() +{ + return &mysqlnd_api_ext_ht; +} +/* }}} */ + +/* {{{ mysqlnd_register_api_extension */ +PHPAPI void mysqlnd_register_api_extension(mysqlnd_api_extension_t *apiext) +{ + zend_hash_add(&mysqlnd_api_ext_ht, apiext->module->name, strlen(apiext->module->name)+1, &apiext, sizeof(mysqlnd_api_extension_t), NULL); +} +/* }}} */ + +/* {{{ zval_to_mysqlnd */ +PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv) +{ + MYSQLND* retval; + mysqlnd_api_extension_t **elem; + + for (zend_hash_internal_pointer_reset(&mysqlnd_api_ext_ht); + zend_hash_get_current_data(&mysqlnd_api_ext_ht, (void **)&elem) == SUCCESS; + zend_hash_move_forward(&mysqlnd_api_ext_ht)) { + if ((*elem)->conversion_cb) { + retval = (*elem)->conversion_cb(zv); + if (retval) { + return retval; + } + } + } + + return NULL; +} +/* }}} */ /* {{{ mysqlnd_conn_get_methods */ PHPAPI struct st_mysqlnd_conn_methods * mysqlnd_conn_get_methods() diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index ebd5cf40f7fde..760ee529f9dbe 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -310,6 +310,15 @@ PHPAPI ZEND_EXTERN_MODULE_GLOBALS(mysqlnd) PHPAPI void mysqlnd_minfo_print_hash(zval *values); +typedef struct { + zend_module_entry *module; + MYSQLND *(*conversion_cb)(zval *zv); +} mysqlnd_api_extension_t; + +PHPAPI HashTable *mysqlnd_get_api_extensions(); +PHPAPI void mysqlnd_register_api_extension(mysqlnd_api_extension_t *apiext); +PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv); + #endif /* MYSQLND_H */ diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index 5682bdeef86b3..2f477c6c953e5 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -133,6 +133,20 @@ mysqlnd_minfo_dump_loaded_plugins(void *pDest, void * buf TSRMLS_DC) } /* }}} */ +/* {{{ mysqlnd_minfo_dump_api_plugins */ +static int +mysqlnd_minfo_dump_api_plugins(void *pDest, void * buf TSRMLS_DC) +{ + smart_str * buffer = (smart_str *) buf; + mysqlnd_api_extension_t *ext = *(mysqlnd_api_extension_t **) pDest; + if (buffer->len) { + smart_str_appendc(buffer, ','); + } + smart_str_appends(buffer, ext->module->name); + return ZEND_HASH_APPLY_KEEP; +} +/* }}} */ + /* {{{ PHP_MINFO_FUNCTION */ @@ -165,7 +179,6 @@ PHP_MINFO_FUNCTION(mysqlnd) php_info_print_table_row(2, "Collecting memory statistics", MYSQLND_G(collect_memory_statistics)? "Yes":"No"); php_info_print_table_row(2, "Tracing", MYSQLND_G(debug)? MYSQLND_G(debug):"n/a"); - php_info_print_table_end(); /* loaded plugins */ { @@ -174,8 +187,16 @@ PHP_MINFO_FUNCTION(mysqlnd) smart_str_0(&tmp_str); php_info_print_table_row(2, "Loaded plugins", tmp_str.c); smart_str_free(&tmp_str); + + zend_hash_apply_with_argument(mysqlnd_get_api_extensions(), mysqlnd_minfo_dump_api_plugins, &tmp_str); + smart_str_0(&tmp_str); + php_info_print_table_row(2, "API Extensions", tmp_str.c); + smart_str_free(&tmp_str); } + php_info_print_table_end(); + + /* Print client stats */ mysqlnd_plugin_apply_with_argument(mysqlnd_minfo_dump_plugin_stats, NULL); } diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index 97cce4a1de05d..9bb9b1a684be8 100755 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -47,6 +47,29 @@ ZEND_DECLARE_MODULE_GLOBALS(pdo_mysql); # endif #endif +#ifdef PDO_USE_MYSQLND +static MYSQLND *pdo_mysql_convert_zv_to_mysqlnd(zval *zv) +{ + if (Z_TYPE_P(zv) == IS_OBJECT && Z_OBJCE_P(zv) == php_pdo_get_dbh_ce()) { + pdo_dbh_t *dbh = zend_object_store_get_object(zv TSRMLS_CC); + + if (!dbh || dbh->driver != &pdo_mysql_driver) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided PDO instance is not using MySQL but %s", dbh->driver->driver_name); + return NULL; + } + + return ((pdo_mysql_db_handle *)dbh)->server; + } + return NULL; +} + +static mysqlnd_api_extension_t pdo_mysql_api_ext = { + &pdo_mysql_module_entry, + pdo_mysql_convert_zv_to_mysqlnd +}; +#endif + + /* {{{ PHP_INI_BEGIN */ PHP_INI_BEGIN() @@ -84,6 +107,11 @@ static PHP_MINIT_FUNCTION(pdo_mysql) REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SSL_CA", (long)PDO_MYSQL_ATTR_SSL_CA); REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SSL_CAPATH", (long)PDO_MYSQL_ATTR_SSL_CAPATH); REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SSL_CIPHER", (long)PDO_MYSQL_ATTR_SSL_CIPHER); + +#ifdef PDO_USE_MYSQLND + mysqlnd_register_api_extension(&pdo_mysql_api_ext); +#endif + return php_pdo_register_driver(&pdo_mysql_driver); } /* }}} */ From a3a5b2197ce4f428200cdb7d5f5d334b44e58ffb Mon Sep 17 00:00:00 2001 From: Matteo Beccati Date: Wed, 31 Aug 2011 22:12:53 +0000 Subject: [PATCH 0695/2394] Fixed false positive failure on gcov --- ext/curl/tests/curl_setopt_basic002.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/curl/tests/curl_setopt_basic002.phpt b/ext/curl/tests/curl_setopt_basic002.phpt index 051703fb0874b..c9123297fd33d 100644 --- a/ext/curl/tests/curl_setopt_basic002.phpt +++ b/ext/curl/tests/curl_setopt_basic002.phpt @@ -26,7 +26,7 @@ $curl_content = curl_exec($ch); fclose($handle); unset($handle); -var_dump( file_get_contents($temp_file) ); +var_dump(preg_replace('/[\r\n]/', ' ', file_get_contents($temp_file))); @unlink($temp_file); ob_start(); // start output buffering @@ -38,7 +38,7 @@ ob_end_clean(); fclose($handle); unset($handle); -var_dump( file_get_contents($temp_file) ); +var_dump(preg_replace('/[\r\n]/', ' ', file_get_contents($temp_file))); @unlink($temp_file); curl_close($ch); From 03ef913497dd34478f039adb9b93c3a213d0a028 Mon Sep 17 00:00:00 2001 From: Matteo Beccati Date: Wed, 31 Aug 2011 22:38:20 +0000 Subject: [PATCH 0696/2394] Fixed test. Apparently it was already fixed on PHP_5_3 98% of the cases and the fix wasn't ported to trunk/PHP_5_4. However the very same test was failing on my FreeBSD 6.2 box, that appears to also decode the "ks_c_5601-1987" parts, so I've made the test more generic. --- ext/iconv/tests/bug52941.phpt | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/ext/iconv/tests/bug52941.phpt b/ext/iconv/tests/bug52941.phpt index 31aabd5e46eb7..b336d40c4b66e 100644 --- a/ext/iconv/tests/bug52941.phpt +++ b/ext/iconv/tests/bug52941.phpt @@ -28,14 +28,14 @@ var_dump($decoded['X-Foo']); var_dump($decoded['X-Bar']); var_dump($decoded['To']); ?> ---EXPECT-- +--EXPECTF-- string(17) "" -string(29) "=?ks_c_5601-1987?B?UkU6odk=?=" -string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" -string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" +string(%d) "%s" +string(%d) "%sFoo" +string(%d) "%sFoo" string(18) "" string(17) "" -string(29) "=?ks_c_5601-1987?B?UkU6odk=?=" -string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" -string(33) "=?ks_c_5601-1987?B?UkU6odk=?= Foo" +string(%d) "%s" +string(%d) "%sFoo" +string(%d) "%sFoo" string(18) "" From e44ad565f0ff5cab32344fc12ebd2714c61cc1a4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 31 Aug 2011 23:12:35 +0000 Subject: [PATCH 0697/2394] - error msg may vary (parser) --- tests/lang/bug21820.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/lang/bug21820.phpt b/tests/lang/bug21820.phpt index 603416d9cdb93..8d5cde1943cf9 100644 --- a/tests/lang/bug21820.phpt +++ b/tests/lang/bug21820.phpt @@ -10,4 +10,4 @@ echo "$arr['foo']"; ?> --EXPECTF-- -Parse error: syntax error, unexpected "quoted-string and whitespace (T_ENCAPSED_AND_WHITESPACE)", expecting "identifier (T_STRING)" or "variable (T_VARIABLE)" or "number (T_NUM_STRING)" in %sbug21820.php on line %d +Parse error: %s error, %s(T_STRING)%s(T_VARIABLE)%s(T_NUM_STRING)%s in %sbug21820.php on line %d From c2ca9678fa52c219dbab69b96fb32fc99f0559dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 31 Aug 2011 23:42:04 +0000 Subject: [PATCH 0698/2394] - Change PDO_oci connection defaults to match Oracle XE defaults, higher chance to work out of the box --- ext/pdo_oci/tests/common.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/pdo_oci/tests/common.phpt b/ext/pdo_oci/tests/common.phpt index 413b57bbf2c9a..5107828cee2ea 100644 --- a/ext/pdo_oci/tests/common.phpt +++ b/ext/pdo_oci/tests/common.phpt @@ -18,9 +18,9 @@ if (false !== getenv('PDO_OCI_TEST_DSN')) { $config['ENV']['PDOTEST_PASS'] = getenv('PDO_OCI_TEST_PASS'); $config['ENV']['PDOTEST_ATTR'] = getenv('PDO_OCI_TEST_ATTR'); } else { - $config['ENV']['PDOTEST_DSN'] = 'oci:dbname=test'; + $config['ENV']['PDOTEST_DSN'] = 'oci:dbname=localhost/xe;charset=WE8MSWIN1252'; $config['ENV']['PDOTEST_USER'] = 'SYSTEM'; - $config['ENV']['PDOTEST_PASS'] = 'PASSWORD'; + $config['ENV']['PDOTEST_PASS'] = 'oracle'; } return $config; From dff6510fc51a69ebb34db57225245c611588e3cf Mon Sep 17 00:00:00 2001 From: Matteo Beccati Date: Thu, 1 Sep 2011 00:45:56 +0000 Subject: [PATCH 0699/2394] Fixed test randomly failing due to different error messages. Also added a skip section in case "fakeURL" resolves to an IP address, as some empty error messages and HTML can be seen in the reports --- ext/curl/tests/curl_error_basic.phpt | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/ext/curl/tests/curl_error_basic.phpt b/ext/curl/tests/curl_error_basic.phpt index c9aa9ef8a0cdd..bd01847f006a8 100644 --- a/ext/curl/tests/curl_error_basic.phpt +++ b/ext/curl/tests/curl_error_basic.phpt @@ -4,7 +4,15 @@ curl_error() function - basic test for curl_error using a fake url Mattijs Hoitink mattijshoitink@gmail.com #Testfest Utrecht 2009 --SKIPIF-- - + --FILE-- ---EXPECT-- +--EXPECTF-- == Testing curl_error with a fake URL == -Error: Couldn't resolve host 'fakeURL' +string(%d) "%sfakeURL%s" From 5b0ae3069c272269279c39c14b850006644361fc Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 09:33:43 +0000 Subject: [PATCH 0700/2394] - force LF eol style as this test depends on it From d9d1fb0cee8702cc6d085747b0e6f71580730a03 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Thu, 1 Sep 2011 11:00:51 +0000 Subject: [PATCH 0701/2394] Seeing thousands of PASS tests flying by is meaningless. Add an option to only print certain result groups. --- run-tests.php | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/run-tests.php b/run-tests.php index ae65a43e65fdb..10154fb0eee10 100755 --- a/run-tests.php +++ b/run-tests.php @@ -207,6 +207,12 @@ function verify_config() $DETAILED = 0; } +if (getenv('SHOW_ONLY_GROUPS')) { + $SHOW_ONLY_GROUPS = explode(",", getenv('SHOW_ONLY_GROUPS')); +} else { + $SHOW_ONLY_GROUPS = array(); +} + // Check whether user test dirs are requested. if (getenv('TEST_PHP_USER')) { $user_tests = explode (',', getenv('TEST_PHP_USER')); @@ -560,6 +566,9 @@ function save_or_mail_results() case 'd': $ini_overwrites[] = $argv[++$i]; break; + case 'g': + $SHOW_ONLY_GROUPS = explode(",", $argv[++$i]);; + break; //case 'h' case '--keep-all': foreach($cfgfiles as $file) { @@ -675,6 +684,9 @@ function save_or_mail_results() -d foo=bar Pass -d option to the php binary (Define INI entry foo with value 'bar'). + -g Comma seperated list of groups to show during test run + (e.x. FAIL,SKIP). + -m Test for memory leaks with Valgrind. -p Specify PHP executable to run. @@ -2426,16 +2438,24 @@ function show_redirect_ends($tests, $tested, $tested_file) function show_test($test_idx, $shortname) { global $test_cnt; + global $line_length; - echo "TEST $test_idx/$test_cnt [$shortname]\r"; + $str = "TEST $test_idx/$test_cnt [$shortname]\r"; + $line_length = strlen($str); + echo $str; flush(); } function show_result($result, $tested, $tested_file, $extra = '', $temp_filenames = null) { - global $html_output, $html_file, $temp_target, $temp_urlbase; + global $html_output, $html_file, $temp_target, $temp_urlbase, $line_length, $SHOW_ONLY_GROUPS; - echo "$result $tested [$tested_file] $extra\n"; + if (!$SHOW_ONLY_GROUPS || in_array($result, $SHOW_ONLY_GROUPS)) { + echo "$result $tested [$tested_file] $extra\n"; + } else { + // Write over the last line to avoid random trailing chars on next echo + echo str_repeat(" ", $line_length), "\r"; + } if ($html_output) { From 48c1f47979682a211e8941d771aed43963f7bb36 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 11:27:14 +0000 Subject: [PATCH 0702/2394] Hack around http://bugs.mysql.com/62320 --- ext/mysqli/tests/mysqli_last_insert_id.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_last_insert_id.phpt b/ext/mysqli/tests/mysqli_last_insert_id.phpt index 353cb7a8a19eb..996c401f749b3 100644 --- a/ext/mysqli/tests/mysqli_last_insert_id.phpt +++ b/ext/mysqli/tests/mysqli_last_insert_id.phpt @@ -31,7 +31,7 @@ API vs. SQL LAST_INSERT_ID() $host, $user, $db, $port, $socket); if (!$link->query("DROP TABLE IF EXISTS test") || - !$link->query("CREATE TABLE test (id INT auto_increment, label varchar(10) not null, PRIMARY KEY (id))") || + !$link->query("CREATE TABLE test (id INT auto_increment, label varchar(10) not null, PRIMARY KEY (id)) ENGINE=MyISAM") || !$link->query("INSERT INTO test (id, label) VALUES (null, 'a')")) { printf("[002] [%d] %s\n", $link->errno, $link->error); } From d01632b499b74624ab4384926ae71fe75232f994 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 11:40:23 +0000 Subject: [PATCH 0703/2394] - consider that bison 2.x is used. updated our ci boxes accordingly (windows too), which were using 1.4 --- tests/basic/bug51709_1.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/basic/bug51709_1.phpt b/tests/basic/bug51709_1.phpt index 49b529b388f02..19d298ad7d42d 100644 --- a/tests/basic/bug51709_1.phpt +++ b/tests/basic/bug51709_1.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: %s error, %s(T_STRING)%s in %sbug51709_1.php on line %d +Parse error: syntax error, unexpected 'for' (T_FOR), expecting identifier (T_STRING) in %sbug51709_1.php on line %d From 6142c9b4b138e0169b0c7e659aacd68b570aa1fb Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 11:40:37 +0000 Subject: [PATCH 0704/2394] - consider that bison 2.x is used. updated our ci boxes accordingly (windows too), which were using 1.4 --- tests/basic/bug51709_2.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/basic/bug51709_2.phpt b/tests/basic/bug51709_2.phpt index 1d4440f5c345b..c5e904df8307a 100644 --- a/tests/basic/bug51709_2.phpt +++ b/tests/basic/bug51709_2.phpt @@ -13,4 +13,4 @@ class foo { ===DONE=== --EXPECTF-- -Parse error: %s error, %s(T_STRING)%s in %sbug51709_2.php on line %d +Parse error: syntax error, unexpected 'goto' (T_GOTO), expecting identifier (T_STRING) in %sbug51709_2.php on line %d From 426b388b743b73840432693e20a541dd78bde22b Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 11:48:18 +0000 Subject: [PATCH 0705/2394] Simplify mysqlnd debug trace marginally for debugging --- .../tests/mysqli_stmt_execute_stored_proc_next_result.phpt | 6 +++++- ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt index 1f92ca1f885e0..1469f658019df 100644 --- a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt +++ b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt @@ -15,7 +15,11 @@ if (mysqli_get_server_version($link) < 50503) { --FILE-- Date: Thu, 1 Sep 2011 12:04:54 +0000 Subject: [PATCH 0706/2394] - Fix TSRM build --- ext/mysql/php_mysql.c | 2 +- ext/mysqli/mysqli.c | 2 +- ext/mysqlnd/mysqlnd.c | 4 ++-- ext/mysqlnd/mysqlnd.h | 4 ++-- ext/mysqlnd/php_mysqlnd.c | 2 +- ext/pdo_mysql/pdo_mysql.c | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index 89fe7b15ff832..5a576248b5d05 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -530,7 +530,7 @@ static PHP_GINIT_FUNCTION(mysql) /* }}} */ #ifdef MYSQL_USE_MYSQLND -static MYSQLND *mysql_convert_zv_to_mysqlnd(zval *zv) +static MYSQLND *mysql_convert_zv_to_mysqlnd(zval *zv TSRMLS_DC) { php_mysql_conn *mysql; diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index c94ddd03db06c..e5f3907ddc8ec 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -528,7 +528,7 @@ PHP_MYSQLI_EXPORT(zend_object_value) mysqli_objects_new(zend_class_entry *class_ /* }}} */ #ifdef MYSQLI_USE_MYSQLND -static MYSQLND *mysqli_convert_zv_to_mysqlnd(zval *zv) +static MYSQLND *mysqli_convert_zv_to_mysqlnd(zval *zv TSRMLS_DC) { if (Z_TYPE_P(zv) == IS_OBJECT && Z_OBJCE_P(zv) == mysqli_link_class_entry) { MY_MYSQL *mysql; diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 5db03278dc35b..9b5cf46a87791 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2565,7 +2565,7 @@ PHPAPI void mysqlnd_register_api_extension(mysqlnd_api_extension_t *apiext) /* }}} */ /* {{{ zval_to_mysqlnd */ -PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv) +PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv TSRMLS_DC) { MYSQLND* retval; mysqlnd_api_extension_t **elem; @@ -2574,7 +2574,7 @@ PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv) zend_hash_get_current_data(&mysqlnd_api_ext_ht, (void **)&elem) == SUCCESS; zend_hash_move_forward(&mysqlnd_api_ext_ht)) { if ((*elem)->conversion_cb) { - retval = (*elem)->conversion_cb(zv); + retval = (*elem)->conversion_cb(zv TSRMLS_CC); if (retval) { return retval; } diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index 760ee529f9dbe..658b63062b648 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -312,12 +312,12 @@ PHPAPI void mysqlnd_minfo_print_hash(zval *values); typedef struct { zend_module_entry *module; - MYSQLND *(*conversion_cb)(zval *zv); + MYSQLND *(*conversion_cb)(zval *zv TSRMLS_DC); } mysqlnd_api_extension_t; PHPAPI HashTable *mysqlnd_get_api_extensions(); PHPAPI void mysqlnd_register_api_extension(mysqlnd_api_extension_t *apiext); -PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv); +PHPAPI MYSQLND* zval_to_mysqlnd(zval *zv TSRMLS_DC); #endif /* MYSQLND_H */ diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index 2f477c6c953e5..e687d1fc407fb 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -188,7 +188,7 @@ PHP_MINFO_FUNCTION(mysqlnd) php_info_print_table_row(2, "Loaded plugins", tmp_str.c); smart_str_free(&tmp_str); - zend_hash_apply_with_argument(mysqlnd_get_api_extensions(), mysqlnd_minfo_dump_api_plugins, &tmp_str); + zend_hash_apply_with_argument(mysqlnd_get_api_extensions(), mysqlnd_minfo_dump_api_plugins, &tmp_str TSRMLS_CC); smart_str_0(&tmp_str); php_info_print_table_row(2, "API Extensions", tmp_str.c); smart_str_free(&tmp_str); diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index 9bb9b1a684be8..a88a45736ceb5 100755 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -48,7 +48,7 @@ ZEND_DECLARE_MODULE_GLOBALS(pdo_mysql); #endif #ifdef PDO_USE_MYSQLND -static MYSQLND *pdo_mysql_convert_zv_to_mysqlnd(zval *zv) +static MYSQLND *pdo_mysql_convert_zv_to_mysqlnd(zval *zv TSRMLS_DC) { if (Z_TYPE_P(zv) == IS_OBJECT && Z_OBJCE_P(zv) == php_pdo_get_dbh_ce()) { pdo_dbh_t *dbh = zend_object_store_get_object(zv TSRMLS_CC); From 3b7cfc6d2c0f79e9ac9e93d099fd8dda3470bdf0 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 12:35:41 +0000 Subject: [PATCH 0707/2394] - force LF eol style as this test depends on it From 9cf971c7ff2fd097e2318559e7ed09d46972505b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 12:42:54 +0000 Subject: [PATCH 0708/2394] - win and nux work the same way --- tests/security/open_basedir_glob.phpt | 6 ------ 1 file changed, 6 deletions(-) diff --git a/tests/security/open_basedir_glob.phpt b/tests/security/open_basedir_glob.phpt index 591cd8f4f7e2e..602e48dfc4257 100644 --- a/tests/security/open_basedir_glob.phpt +++ b/tests/security/open_basedir_glob.phpt @@ -1,11 +1,5 @@ --TEST-- Test open_basedir configuration ---SKIPIF-- - --INI-- open_basedir=. --FILE-- From abeac6759dc4f81268e8d02a418f25656d7db325 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 12:43:12 +0000 Subject: [PATCH 0709/2394] - win and nux work the same way --- tests/security/open_basedir_glob-win32.phpt | 59 --------------------- 1 file changed, 59 deletions(-) delete mode 100644 tests/security/open_basedir_glob-win32.phpt diff --git a/tests/security/open_basedir_glob-win32.phpt b/tests/security/open_basedir_glob-win32.phpt deleted file mode 100644 index 3fa19afa365b2..0000000000000 --- a/tests/security/open_basedir_glob-win32.phpt +++ /dev/null @@ -1,59 +0,0 @@ ---TEST-- -Test open_basedir configuration ---SKIPIF-- - ---INI-- -open_basedir=. ---FILE-- - ---CLEAN-- - ---EXPECTF-- -*** Testing open_basedir configuration [glob] *** -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(false) -bool(false) -bool(false) -array(0) { -} -bool(false) -bool(false) -bool(false) -bool(false) -bool(false) -array(1) { - [0]=> - string(5) "../ok" -} -array(1) { - [0]=> - string(6) "ok.txt" -} -array(1) { - [0]=> - string(12) "../ok/ok.txt" -} -array(1) { - [0]=> - string(%d) "%s/test/ok/ok.txt" -} -array(1) { - [0]=> - string(%d) "%s/test/ok/../ok/ok.txt" -} -*** Finished testing open_basedir configuration [glob] *** - From 2449bd4a109316f64485b1c816d7538e28aadcef Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 1 Sep 2011 12:49:26 +0000 Subject: [PATCH 0710/2394] - fix test --- .../security/open_basedir_parse_ini_file.phpt | 49 ++++++++----------- 1 file changed, 21 insertions(+), 28 deletions(-) diff --git a/tests/security/open_basedir_parse_ini_file.phpt b/tests/security/open_basedir_parse_ini_file.phpt index 926c0777172c8..f47a8e5c856a2 100644 --- a/tests/security/open_basedir_parse_ini_file.phpt +++ b/tests/security/open_basedir_parse_ini_file.phpt @@ -37,46 +37,39 @@ bool(true) bool(true) bool(true) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test\bad) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 6 -Warning: parse_ini_file(%s\test\bad): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 6 +bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test\bad\bad.txt) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 7 -Warning: parse_ini_file(%s\test\bad\bad.txt): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 7 +bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 8 -Warning: parse_ini_file(%s\test): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 8 +bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 9 -Warning: parse_ini_file(%s\test): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 9 +bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test\bad) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 10 -Warning: parse_ini_file(%s\test\bad): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 10 +bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test\bad\bad.txt) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 11 -Warning: parse_ini_file(%s\test\bad\bad.txt): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 11 +bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(%s\test) is not within the allowed path(s): (.) in %s on line %d +Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 12 -Warning: parse_ini_file(%s\test): failed to open stream: %s in %s on line %d -array(0) { -} +Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 12 +bool(false) *** Finished testing open_basedir configuration [parse_ini_file] *** From 33fed1066cd6e5a76cc6e78d41567cbff699e4b1 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Thu, 1 Sep 2011 13:06:12 +0000 Subject: [PATCH 0711/2394] Move the XFAILED printout way up the list so we can actually notice the really failing ones --- run-tests.php | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/run-tests.php b/run-tests.php index 10154fb0eee10..2b584e49c6a56 100755 --- a/run-tests.php +++ b/run-tests.php @@ -2305,6 +2305,18 @@ function get_summary($show_ext_summary, $show_html) '; $failed_test_summary = ''; + if (count($PHP_FAILED_TESTS['XFAILED'])) { + $failed_test_summary .= ' +===================================================================== +EXPECTED FAILED TEST SUMMARY +--------------------------------------------------------------------- +'; + foreach ($PHP_FAILED_TESTS['XFAILED'] as $failed_test_data) { + $failed_test_summary .= $failed_test_data['test_name'] . $failed_test_data['info'] . "\n"; + } + $failed_test_summary .= "=====================================================================\n"; + } + if (count($PHP_FAILED_TESTS['BORKED'])) { $failed_test_summary .= ' ===================================================================== @@ -2329,18 +2341,6 @@ function get_summary($show_ext_summary, $show_html) } $failed_test_summary .= "=====================================================================\n"; } - if (count($PHP_FAILED_TESTS['XFAILED'])) { - $failed_test_summary .= ' -===================================================================== -EXPECTED FAILED TEST SUMMARY ---------------------------------------------------------------------- -'; - foreach ($PHP_FAILED_TESTS['XFAILED'] as $failed_test_data) { - $failed_test_summary .= $failed_test_data['test_name'] . $failed_test_data['info'] . "\n"; - } - $failed_test_summary .= "=====================================================================\n"; - } - if (count($PHP_FAILED_TESTS['WARNED'])) { $failed_test_summary .= ' ===================================================================== From 0c26509ff00bf74830ad58f5ed471263be0c4320 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 13:17:16 +0000 Subject: [PATCH 0712/2394] Check if MySQL server supports SSL and, if using mysqlnd, check if PHP streams will support SSL --- ext/mysqli/tests/bug51647.phpt | 29 +++++++++++++++++++++++++++++ ext/mysqli/tests/bug55283.phpt | 32 ++++++++++++++++++++++++++------ 2 files changed, 55 insertions(+), 6 deletions(-) diff --git a/ext/mysqli/tests/bug51647.phpt b/ext/mysqli/tests/bug51647.phpt index 833f8edbbb5db..b1c1e87a772d0 100644 --- a/ext/mysqli/tests/bug51647.phpt +++ b/ext/mysqli/tests/bug51647.phpt @@ -4,6 +4,35 @@ Bug #51647 (Certificate file without private key (pk in another file) doesn't wo query('SHOW VARIABLES LIKE "have_ssl"')) { + $row = $res->fetch_row(); +} else { + if ($link->errno == 1064 && ($res = $link->query("SHOW VARIABLES"))) { + while ($row = $res->fetch_row()) + if ($row[0] == 'have_ssl') + break; + } else { + die(sprintf("skip Failed to test for MySQL SSL support, [%d] %s", $link->errno, $link->error)); + } +} + + +if (empty($row)) + die(sprintf("skip Failed to test for MySQL SSL support, [%d] %s", $link->errno, $link->error)); + +if ($row[1] == 'NO') + die(sprintf("skip MySQL has no SSL support, [%d] %s", $link->errno, $link->error)); + +$link->close(); ?> --FILE-- query("SHOW STATUS LIKE 'Ssl_cipher'"); +require_once("connect.inc"); + +if ($IS_MYSQLND && !extension_loaded("openssl")) + die("skip PHP streams lack support for SSL. mysqli is compiled to use mysqlnd which uses PHP streams in turn."); + +if (!($link = @my_mysqli_connect($host, $user, $passwd, $db, $port, $socket))) + die(sprintf("skip Connect failed, [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); + +$row = NULL; +if ($res = $link->query('SHOW VARIABLES LIKE "have_ssl"')) { $row = $res->fetch_row(); - if ($row[1] === "") { - die('skip Server started without SSL support'); +} else { + if ($link->errno == 1064 && ($res = $link->query("SHOW VARIABLES"))) { + while ($row = $res->fetch_row()) + if ($row[0] == 'have_ssl') + break; + } else { + die(sprintf("skip Failed to test for MySQL SSL support, [%d] %s", $link->errno, $link->error)); } } + + +if (empty($row)) + die(sprintf("skip Failed to test for MySQL SSL support, [%d] %s", $link->errno, $link->error)); + +if ($row[1] == 'NO') + die(sprintf("skip MySQL has no SSL support, [%d] %s", $link->errno, $link->error)); + +$link->close(); ?> --FILE-- Date: Thu, 1 Sep 2011 13:28:00 +0000 Subject: [PATCH 0713/2394] - use %s, bad c/p --- .../security/open_basedir_parse_ini_file.phpt | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/tests/security/open_basedir_parse_ini_file.phpt b/tests/security/open_basedir_parse_ini_file.phpt index f47a8e5c856a2..d69adeb5e13ce 100644 --- a/tests/security/open_basedir_parse_ini_file.phpt +++ b/tests/security/open_basedir_parse_ini_file.phpt @@ -37,39 +37,39 @@ bool(true) bool(true) bool(true) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 6 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest\bad) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 6 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 6 +Warning: parse_ini_file(%stest\bad): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 6 bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 7 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest\bad\bad.txt) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 7 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 7 +Warning: parse_ini_file(%stest\bad\bad.txt): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 7 bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 8 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 8 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 8 +Warning: parse_ini_file(%stest): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 8 bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 9 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 9 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 9 +Warning: parse_ini_file(%stest): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 9 bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 10 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest\bad) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 10 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 10 +Warning: parse_ini_file(%stest\bad): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 10 bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 11 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest\bad\bad.txt) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 11 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test\bad\bad.txt): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 11 +Warning: parse_ini_file(%stest\bad\bad.txt): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 11 bool(false) -Warning: parse_ini_file(): open_basedir restriction in effect. File(G:\php-sdk\php-src\branches\PHP_5_4\test) is not within the allowed path(s): (.) in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 12 +Warning: parse_ini_file(): open_basedir restriction in effect. File(%stest) is not within the allowed path(s): (.) in %sopen_basedir_parse_ini_file.php on line 12 -Warning: parse_ini_file(G:\php-sdk\php-src\branches\PHP_5_4\test): failed to open stream: Operation not permitted in G:\php-sdk\php-src\branches\PHP_5_4\tests\security\open_basedir_parse_ini_file.php on line 12 +Warning: parse_ini_file(%stest): failed to open stream: Operation not permitted in %sopen_basedir_parse_ini_file.php on line 12 bool(false) *** Finished testing open_basedir configuration [parse_ini_file] *** From 7b9d93d18b7fafed03b971f6a0fd6c4ee4fa7f77 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 13:37:49 +0000 Subject: [PATCH 0714/2394] Fixing tests debug output --- ext/mysqli/tests/004.phpt | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/ext/mysqli/tests/004.phpt b/ext/mysqli/tests/004.phpt index ce222fea42f41..010d6e1960031 100644 --- a/ext/mysqli/tests/004.phpt +++ b/ext/mysqli/tests/004.phpt @@ -15,24 +15,27 @@ require_once('skipifconnectfailure.inc'); mysqli_select_db($link, $db); if (!mysqli_query($link,"DROP TABLE IF EXISTS test_bind_fetch")) - printf("[001] [%d] string\n", mysqli_errno($link), mysqli_error($link)); + printf("[001] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!mysqli_query($link,"CREATE TABLE test_bind_fetch(c1 char(10), c2 text) ENGINE=" . $engine)) - printf("[002] [%d] string\n", mysqli_errno($link), mysqli_error($link)); + printf("[002] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!mysqli_query($link, "INSERT INTO test_bind_fetch VALUES ('1234567890', 'this is a test0')")) - printf("[003] [%d] string\n", mysqli_errno($link), mysqli_error($link)); + printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!mysqli_query($link, "INSERT INTO test_bind_fetch VALUES ('1234567891', 'this is a test1')")) - printf("[004] [%d] string\n", mysqli_errno($link), mysqli_error($link)); + printf("[004] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!mysqli_query($link, "INSERT INTO test_bind_fetch VALUES ('1234567892', 'this is a test2')")) - printf("[005] [%d] string\n", mysqli_errno($link), mysqli_error($link)); + printf("[005] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); if (!mysqli_query($link, "INSERT INTO test_bind_fetch VALUES ('1234567893', 'this is a test3')")) - printf("[006] [%d] string\n", mysqli_errno($link), mysqli_error($link)); + printf("[006] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); - $stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch ORDER BY c1"); + if (!$stmt = mysqli_prepare($link, "SELECT * FROM test_bind_fetch ORDER BY c1")) + printf("[007] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); + + $c1 = $c2 = NULL; mysqli_stmt_bind_result($stmt, $c1, $c2); mysqli_stmt_execute($stmt); $i = 4; From ebc3b34fa0601e063371124dbc1ba03be062ee96 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 14:04:52 +0000 Subject: [PATCH 0715/2394] Fix test. First element within the parantheses is a SQL status code. Should please gcov --- ext/mysqli/tests/mysqli_select_db.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_select_db.phpt b/ext/mysqli/tests/mysqli_select_db.phpt index 7527a1313b506..ee04eacb6a447 100644 --- a/ext/mysqli/tests/mysqli_select_db.phpt +++ b/ext/mysqli/tests/mysqli_select_db.phpt @@ -98,7 +98,7 @@ require_once('skipifconnectfailure.inc'); --CLEAN-- --EXPECTF-- -Warning: mysqli_select_db(): (%d/%d): Unknown database '%s' in %s on line %d +Warning: mysqli_select_db(): (%s/%d): Unknown database '%s' in %s on line %d Warning: mysqli_select_db(): Couldn't fetch mysqli in %s on line %d done! \ No newline at end of file From 781db10c48ae2184d3c3880eed74e38baeb20545 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Thu, 1 Sep 2011 14:52:55 +0000 Subject: [PATCH 0716/2394] Improve speed of finding tests (no more CVS, we're on svn now) --- run-tests.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/run-tests.php b/run-tests.php index 2b584e49c6a56..84cf6e8e2ddae 100755 --- a/run-tests.php +++ b/run-tests.php @@ -866,7 +866,7 @@ function find_files($dir, $is_ext_dir = false, $ignore = false) while (($name = readdir($o)) !== false) { - if (is_dir("{$dir}/{$name}") && !in_array($name, array('.', '..', 'CVS'))) { + if (is_dir("{$dir}/{$name}") && !in_array($name, array('.', '..', '.svn'))) { $skip_ext = ($is_ext_dir && !in_array(strtolower($name), $exts_to_test)); if ($skip_ext) { $exts_skipped++; @@ -1239,7 +1239,7 @@ function run_test($php, $file, $env) } // Match the beginning of a section. - if (preg_match(b'/^--([_A-Z]+)--/', $line, $r)) { + if (preg_match('/^--([_A-Z]+)--/', $line, $r)) { $section = $r[1]; settype($section, STRING_TYPE); From 9996f5f13f65a03c610c1522979bd73f610928f0 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 15:25:15 +0000 Subject: [PATCH 0717/2394] Can't reproduce the server has gone away messages, Andrey. Please, have a look. I tried MySQL 5.1, 5.5 and 5.6. --- ext/mysql/tests/bug55473.phpt | 55 ++++++++++++++++++----------------- 1 file changed, 29 insertions(+), 26 deletions(-) diff --git a/ext/mysql/tests/bug55473.phpt b/ext/mysql/tests/bug55473.phpt index 3a145fd780dc3..df584bdef9ca3 100644 --- a/ext/mysql/tests/bug55473.phpt +++ b/ext/mysql/tests/bug55473.phpt @@ -7,6 +7,9 @@ require_once('skipifconnectfailure.inc'); if (defined('PHP_WINDOWS_VERSION_MAJOR')) { die("skip Test doesn't work on Windows"); } + +if (!($output = @exec("lsof -np " . getmypid()))) + die("skip Test can't find command line tool lsof"); ?> --INI-- mysql.max_persistent=30 @@ -25,52 +28,52 @@ mysql.allow_persistent=1 function connect($host, $user, $passwd) { $conn = mysql_pconnect($host, $user, $passwd); + if (!$conn) - die(mysql_error()."\n"); - mysql_query("set wait_timeout=1", $conn); + die(sprintf("[001] %s\n", mysql_error())); + + if (!mysql_query("set wait_timeout=1", $conn)) + printf("[002] [%d] %s\n", mysql_errno($conn), mysql_error($conn)); + return $conn; } $conn = connect($host, $user, $passwd); $opened_files = -1; - for($i = 0; $i < 4; $i++) { + + for ($i = 0; $i < 4; $i++) { /* wait while mysql closes connection */ sleep(3); if (!mysql_ping($conn)) { - echo "reconnect\n"; - $conn = connect($host, $user, $passwd); + printf("[003] reconnect %d\n", $i); + $conn = connect($host, $user, $passwd); } $r = mysql_query('select 1', $conn); - $error = $r ? 'OK' : mysql_error(); + if (!$r) + printf("[004] [%d] %s\n", mysql_errno($conn), mysql_error($conn)); + + if ($opened_files == -1) { $opened_files = trim(exec("lsof -np " . getmypid() . " | wc -l")); - echo "OK\n"; + printf("[005] Setting openened files...\n"); } else if (($tmp = trim(exec("lsof -np " . getmypid() . " | wc -l"))) != $opened_files) { - printf("[01] [%d] different number of opened_files : expected %d, got %d", $i, $opened_files, $tmp); + printf("[006] [%d] different number of opened_files : expected %d, got %d", $i, $opened_files, $tmp); } else { - echo "OK\n"; + printf("[007] Opened files as expected\n"); } } - print "done!"; ?> --EXPECTF-- -Warning: mysql_ping(): MySQL server has gone away in %s on line %d -reconnect -OK - -Warning: mysql_ping(): MySQL server has gone away in %s on line %d -reconnect -OK - -Warning: mysql_ping(): MySQL server has gone away in %s on line %d -reconnect -OK - -Warning: mysql_ping(): MySQL server has gone away in %s on line %d -reconnect -OK -done! +[003] reconnect 0 +[005] Setting openened files... +[003] reconnect 1 +[007] Opened files as expected +[003] reconnect 2 +[007] Opened files as expected +[003] reconnect 3 +[007] Opened files as expected +done! \ No newline at end of file From 67faaa1cae6ba8083fbc2eaa2e1ec9bcfbf4fc90 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 15:45:47 +0000 Subject: [PATCH 0718/2394] Fixing error handling. Skip if load data is not allowed --- ext/mysql/tests/bug53649.phpt | 36 ++++++++++++++++++++++++++--------- 1 file changed, 27 insertions(+), 9 deletions(-) diff --git a/ext/mysql/tests/bug53649.phpt b/ext/mysql/tests/bug53649.phpt index 126f34b738252..70bf9bed3630b 100644 --- a/ext/mysql/tests/bug53649.phpt +++ b/ext/mysql/tests/bug53649.phpt @@ -4,28 +4,46 @@ Bug #53649 (mysql_query with "load data" unable to save result set) --FILE-- errno, $link->error); + if (!mysql_query("DROP TABLE IF EXISTS test", $link)) { + printf("[002] [%d] %s\n", mysql_errno($link), mysql_error($link)); } - if (!mysql_query("CREATE TABLE tlocaldata (dump1 INT UNSIGNED NOT NULL PRIMARY KEY) ENGINE=" . $engine, $link)) { - printf("[003] [%d] %s\n", $link->errno, $link->error); + if (!mysql_query("CREATE TABLE test (dump1 INT UNSIGNED NOT NULL PRIMARY KEY) ENGINE=" . $engine, $link)) { + printf("[003] [%d] %s\n", mysql_errno($link), mysql_error($link)); } - file_put_contents('bug53649.data', "1\n2\n3\n"); + if (false === file_put_contents('bug53649.data', "1\n2\n3\n")) + printf("[004] Failed to create data file\n"); - mysql_query("SELECT 1 FROM DUAL", $link); + if (!mysql_query("SELECT 1 FROM DUAL", $link)) + printf("[005] [%d] %s\n", mysql_errno($link), mysql_error($link)); - if (!mysql_query("LOAD DATA LOCAL INFILE 'bug53649.data' INTO TABLE tlocaldata", $link)) { + if (!mysql_query("LOAD DATA LOCAL INFILE 'bug53649.data' INTO TABLE test", $link)) { + printf("[006] [%d] %s\n", mysql_errno($link), mysql_error($link)); echo "bug"; } else { echo "done"; @@ -41,7 +59,7 @@ if (!$link = my_mysql_connect($host, $user, $passwd, $db, $port, $socket)) { $host, $user, $db, $port, $socket); } -if (!mysql_query($link, 'DROP TABLE IF EXISTS tlocaldata', $link)) { +if (!mysql_query($link, 'DROP TABLE IF EXISTS test', $link)) { printf("[clean] Failed to drop old test table: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); } From 2ae90a11ea5ea85f3875943c235e5a248a82a524 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Thu, 1 Sep 2011 16:35:13 +0000 Subject: [PATCH 0719/2394] Check for LOAD DATA support during SKIPIF --- ext/mysqli/tests/bug53503.phpt | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/ext/mysqli/tests/bug53503.phpt b/ext/mysqli/tests/bug53503.phpt index 6b705524ebad5..339fce7a8e693 100644 --- a/ext/mysqli/tests/bug53503.phpt +++ b/ext/mysqli/tests/bug53503.phpt @@ -4,6 +4,16 @@ Bug #53503 (mysqli::query returns false after successful LOAD DATA query) errno, $link->error)); + +mysqli_close($link); + ?> --FILE-- query("DROP TABLE IF EXISTS tlocaldata")) { + if (!$link->query("DROP TABLE IF EXISTS test")) { printf("[002] [%d] %s\n", $link->errno, $link->error); } - if (!$link->query("CREATE TABLE tlocaldata (dump1 INT UNSIGNED NOT NULL PRIMARY KEY) ENGINE=" . $engine)) { + if (!$link->query("CREATE TABLE test (dump1 INT UNSIGNED NOT NULL PRIMARY KEY) ENGINE=" . $engine)) { printf("[003] [%d] %s\n", $link->errno, $link->error); } - file_put_contents('bug53503.data', "1\n2\n3\n"); + if (FALSE == file_put_contents('bug53503.data', "1\n2\n3\n")) + printf("[004] Failed to create CVS file\n"); - $link->query("SELECT 1 FROM DUAL"); + if (!$link->query("SELECT 1 FROM DUAL")) + printf("[005] [%d] %s\n", $link->errno, $link->error); - if (!$link->query("LOAD DATA LOCAL INFILE 'bug53503.data' INTO TABLE tlocaldata")) { + if (!$link->query("LOAD DATA LOCAL INFILE 'bug53503.data' INTO TABLE test")) { + printf("[006] [%d] %s\n", $link->errno, $link->error); echo "bug"; } else { echo "done"; @@ -41,7 +54,7 @@ if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) { $host, $user, $db, $port, $socket); } -if (!$link->query($link, 'DROP TABLE IF EXISTS tlocaldata')) { +if (!$link->query($link, 'DROP TABLE IF EXISTS test')) { printf("[clean] Failed to drop old test table: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); } From 375a31fed2225c41502fe372bd750e80c643611f Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Thu, 1 Sep 2011 19:01:37 +0000 Subject: [PATCH 0720/2394] Prevent the magic quotes fatal error causing a diff --- ext/dba/tests/dba_cdb_make.phpt | 3 --- 1 file changed, 3 deletions(-) diff --git a/ext/dba/tests/dba_cdb_make.phpt b/ext/dba/tests/dba_cdb_make.phpt index e3ff9662a8231..6a5f2dd9c361c 100644 --- a/ext/dba/tests/dba_cdb_make.phpt +++ b/ext/dba/tests/dba_cdb_make.phpt @@ -1,7 +1,5 @@ --TEST-- DBA CDB_MAKE handler test ---INI-- -magic_quotes_runtime=1 --SKIPIF-- --EXPECT-- -Deprecated: Directive 'magic_quotes_runtime' is deprecated in PHP 5.3 and greater in Unknown on line 0 database handler: cdb_make string(32) "12fc5ba2b9dcfef2480e5324eeb5f3e5" string(32) "12fc5ba2b9dcfef2480e5324eeb5f3e5" From d002d6d56d81b96d50978172c6ccd0b8dba6c8fe Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Thu, 1 Sep 2011 19:27:14 +0000 Subject: [PATCH 0721/2394] Unmatched %s was still diffing on Linux. Now it matches the whitespace at a minimum --- tests/lang/bug21820.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/lang/bug21820.phpt b/tests/lang/bug21820.phpt index 8d5cde1943cf9..cbf466eea7fc2 100644 --- a/tests/lang/bug21820.phpt +++ b/tests/lang/bug21820.phpt @@ -10,4 +10,4 @@ echo "$arr['foo']"; ?> --EXPECTF-- -Parse error: %s error, %s(T_STRING)%s(T_VARIABLE)%s(T_NUM_STRING)%s in %sbug21820.php on line %d +Parse error: %s error, %s(T_STRING)%s(T_VARIABLE)%s(T_NUM_STRING)%sin %sbug21820.php on line %d From 29b76e6de3ec0eb3a75e9470be3a96c400ce0100 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Fri, 2 Sep 2011 05:14:32 +0000 Subject: [PATCH 0722/2394] - Use our external entity loader only in the context of a PHP request. --- ext/libxml/libxml.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index f488b38f425d4..00f257c7dd405 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -674,6 +674,18 @@ static xmlParserInputPtr _php_libxml_external_entity_loader(const char *URL, return ret; } +static xmlParserInputPtr _php_libxml_pre_ext_ent_loader(const char *URL, + const char *ID, xmlParserCtxtPtr context) +{ + /* Check whether we're running in a PHP context, since the entity loader + * we've defined is an application level (true global) setting */ + if (xmlGenericError == php_libxml_error_handler) { + return _php_libxml_external_entity_loader(URL, ID, context); + } else { + return _php_libxml_default_entity_loader(URL, ID, context); + } +} + PHP_LIBXML_API void php_libxml_ctx_error(void *ctx, const char *msg, ...) { va_list args; @@ -713,7 +725,7 @@ PHP_LIBXML_API void php_libxml_initialize(void) xmlInitParser(); _php_libxml_default_entity_loader = xmlGetExternalEntityLoader(); - xmlSetExternalEntityLoader(_php_libxml_external_entity_loader); + xmlSetExternalEntityLoader(_php_libxml_pre_ext_ent_loader); zend_hash_init(&php_libxml_exports, 0, NULL, NULL, 1); @@ -729,6 +741,8 @@ PHP_LIBXML_API void php_libxml_shutdown(void) #endif xmlCleanupParser(); zend_hash_destroy(&php_libxml_exports); + + xmlSetExternalEntityLoader(_php_libxml_default_entity_loader); _php_libxml_initialized = 0; } } From 538d8a3f5252d2709c4d1f7e69257237d3f98020 Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Fri, 2 Sep 2011 08:07:58 +0000 Subject: [PATCH 0723/2394] remove php_snmp_get_ce() --- ext/snmp/php_snmp.h | 2 +- ext/snmp/snmp.c | 9 ++------- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index 543a48689c1aa..500d4f8df8d75 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -127,7 +127,7 @@ ZEND_END_MODULE_GLOBALS(snmp) #endif #define REGISTER_SNMP_CLASS_CONST_LONG(const_name, value) \ - zend_declare_class_constant_long(php_snmp_get_ce(), const_name, sizeof(const_name)-1, (long)value TSRMLS_CC); + zend_declare_class_constant_long(php_snmp_ce, const_name, sizeof(const_name)-1, (long)value TSRMLS_CC); #else diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index b5f2df52f86db..327b32e4044d6 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -132,12 +132,7 @@ static int le_snmp_session; static zend_object_handlers php_snmp_object_handlers; /* Class entries */ -zend_class_entry *php_snmp_class_entry; - -zend_class_entry *php_snmp_get_ce() -{ - return php_snmp_class_entry; -} +zend_class_entry *php_snmp_ce; /* Class object properties */ static HashTable php_snmp_properties; @@ -2399,7 +2394,7 @@ PHP_MINIT_FUNCTION(snmp) INIT_CLASS_ENTRY(ce, "SNMP", php_snmp_class_methods); ce.create_object = php_snmp_object_new; php_snmp_object_handlers.clone_obj = NULL; - php_snmp_class_entry = zend_register_internal_class(&ce TSRMLS_CC); + php_snmp_ce = zend_register_internal_class(&ce TSRMLS_CC); /* Register SNMP Class properties */ zend_hash_init(&php_snmp_properties, 0, NULL, NULL, 1); From 7e5d9ae1dd8e86b4718cc4041e775c4501ff99eb Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 2 Sep 2011 09:27:23 +0000 Subject: [PATCH 0724/2394] MySQL 5.6 update --- ext/mysqli/tests/mysqli_character_set.phpt | 3 ++- ext/mysqli/tests/mysqli_set_charset.phpt | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/tests/mysqli_character_set.phpt b/ext/mysqli/tests/mysqli_character_set.phpt index 191a163f247b6..1bfe9cbdaa06c 100644 --- a/ext/mysqli/tests/mysqli_character_set.phpt +++ b/ext/mysqli/tests/mysqli_character_set.phpt @@ -48,7 +48,8 @@ if (version_compare(PHP_VERSION, '5.9.9', '>') == 1) { $k = $charset['Charset']; /* The server currently 17.07.2007 can't handle data sent in ucs2 */ /* The server currently 16.08.2010 can't handle data sent in utf16 and utf32 */ - if ($charset['Charset'] == 'ucs2' || $charset['Charset'] == 'utf16' || $charset['Charset'] == 'utf32') { + /* The server currently 02.09.2011 can't handle data sent in utf16le */ + if ($charset['Charset'] == 'ucs2' || $charset['Charset'] == 'utf16' || $charset['Charset'] == 'utf32' || 'utf16le' == $charset['Charset']) { continue; } diff --git a/ext/mysqli/tests/mysqli_set_charset.phpt b/ext/mysqli/tests/mysqli_set_charset.phpt index 4cd6e6ec1d110..38fe56841bf66 100644 --- a/ext/mysqli/tests/mysqli_set_charset.phpt +++ b/ext/mysqli/tests/mysqli_set_charset.phpt @@ -102,7 +102,7 @@ if ((($res = mysqli_query($link, 'SHOW CHARACTER SET LIKE "latin1"', MYSQLI_STOR printf("[016] Cannot get list of character sets\n"); while ($tmp = mysqli_fetch_assoc($res)) { - if ('ucs2' == $tmp['Charset'] || 'utf16' == $tmp['Charset'] || 'utf32' == $tmp['Charset']) + if ('ucs2' == $tmp['Charset'] || 'utf16' == $tmp['Charset'] || 'utf32' == $tmp['Charset'] || 'utf16le' == $tmp['Charset']) continue; /* Uncomment to see where it hangs - var_dump($tmp); flush(); */ From d077fc321101f0bb212282783c9c667593a4383e Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Fri, 2 Sep 2011 10:04:19 +0000 Subject: [PATCH 0725/2394] added SNMPException class, enabling ability to throw exceptions when a known SNMP error has occured FR #55542 --- ext/snmp/php_snmp.h | 1 + ext/snmp/snmp.c | 115 +++++++++++++++++---- ext/snmp/tests/snmp-object-error.phpt | 32 +++++- ext/snmp/tests/snmp-object-properties.phpt | 8 ++ 4 files changed, 130 insertions(+), 26 deletions(-) diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index 500d4f8df8d75..46deeff3adfba 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -94,6 +94,7 @@ typedef struct _php_snmp_object { int oid_output_format; int snmp_errno; int oid_increasing_check; + int exceptions_enabled; char snmp_errstr[256]; } php_snmp_object; diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 327b32e4044d6..41906f8d552d9 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -34,6 +34,10 @@ #include "zend_exceptions.h" +#if HAVE_SPL +#include "ext/spl/spl_exceptions.h" +#endif + #if HAVE_SNMP #include @@ -113,12 +117,21 @@ typedef struct snmp_session php_snmp_session; } #define PHP_SNMP_ERRNO_NOERROR 0 -#define PHP_SNMP_ERRNO_GENERIC 1 -#define PHP_SNMP_ERRNO_TIMEOUT 2 -#define PHP_SNMP_ERRNO_ERROR_IN_REPLY 3 -#define PHP_SNMP_ERRNO_OID_NOT_INCREASING 4 -#define PHP_SNMP_ERRNO_OID_PARSING_ERROR 5 -#define PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES 6 +#define PHP_SNMP_ERRNO_GENERIC (1 << 1) +#define PHP_SNMP_ERRNO_TIMEOUT (1 << 2) +#define PHP_SNMP_ERRNO_ERROR_IN_REPLY (1 << 3) +#define PHP_SNMP_ERRNO_OID_NOT_INCREASING (1 << 4) +#define PHP_SNMP_ERRNO_OID_PARSING_ERROR (1 << 5) +#define PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES (1 << 6) +#define PHP_SNMP_ERRNO_ANY ( \ + PHP_SNMP_ERRNO_GENERIC | \ + PHP_SNMP_ERRNO_TIMEOUT | \ + PHP_SNMP_ERRNO_ERROR_IN_REPLY | \ + PHP_SNMP_ERRNO_OID_NOT_INCREASING | \ + PHP_SNMP_ERRNO_OID_PARSING_ERROR | \ + PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES | \ + PHP_SNMP_ERRNO_NOERROR \ + ) ZEND_DECLARE_MODULE_GLOBALS(snmp) static PHP_GINIT_FUNCTION(snmp); @@ -133,6 +146,7 @@ static zend_object_handlers php_snmp_object_handlers; /* Class entries */ zend_class_entry *php_snmp_ce; +zend_class_entry *php_snmp_exception_ce; /* Class object properties */ static HashTable php_snmp_properties; @@ -533,9 +547,13 @@ static void php_snmp_error(zval *object, const char *docref TSRMLS_DC, int type, return; } - va_start(args, format); - php_verror(docref, "", E_WARNING, format, args TSRMLS_CC); - va_end(args); + if (object && (snmp_object->exceptions_enabled & type)) { + zend_throw_exception_ex(php_snmp_exception_ce, type, snmp_object->snmp_errstr TSRMLS_CC); + } else { + va_start(args, format); + php_verror(docref, "", E_WARNING, format, args TSRMLS_CC); + va_end(args); + } } /* }}} */ @@ -1829,6 +1847,7 @@ PHP_METHOD(snmp, __construct) snmp_object->oid_output_format = netsnmp_ds_get_int(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_OID_OUTPUT_FORMAT); snmp_object->quick_print = netsnmp_ds_get_boolean(NETSNMP_DS_LIBRARY_ID, NETSNMP_DS_LIB_QUICK_PRINT); snmp_object->oid_increasing_check = TRUE; + snmp_object->exceptions_enabled = 0; } /* }}} */ @@ -2204,6 +2223,7 @@ PHP_SNMP_BOOL_PROPERTY_READER_FUNCTION(enum_print) PHP_SNMP_LONG_PROPERTY_READER_FUNCTION(valueretrieval) PHP_SNMP_LONG_PROPERTY_READER_FUNCTION(oid_output_format) +PHP_SNMP_LONG_PROPERTY_READER_FUNCTION(exceptions_enabled) /* {{{ */ static int php_snmp_write_info(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) @@ -2330,6 +2350,27 @@ static int php_snmp_write_oid_output_format(php_snmp_object *snmp_object, zval * } /* }}} */ +/* {{{ */ +static int php_snmp_write_exceptions_enabled(php_snmp_object *snmp_object, zval *newval TSRMLS_DC) +{ + zval ztmp; + int ret = SUCCESS; + if (Z_TYPE_P(newval) != IS_LONG) { + ztmp = *newval; + zval_copy_ctor(&ztmp); + convert_to_long(&ztmp); + newval = &ztmp; + } + + snmp_object->exceptions_enabled = Z_LVAL_P(newval); + + if (newval == &ztmp) { + zval_dtor(newval); + } + return ret; +} +/* }}} */ + /* {{{ php_snmp_class_methods[] */ static zend_function_entry php_snmp_class_methods[] = { PHP_ME(snmp, __construct, arginfo_snmp_create, ZEND_ACC_PUBLIC) @@ -2357,6 +2398,7 @@ const php_snmp_prop_handler php_snmp_property_entries[] = { PHP_SNMP_PROPERTY_ENTRY_RECORD(enum_print), PHP_SNMP_PROPERTY_ENTRY_RECORD(oid_output_format), PHP_SNMP_PROPERTY_ENTRY_RECORD(oid_increasing_check), + PHP_SNMP_PROPERTY_ENTRY_RECORD(exceptions_enabled), { NULL, 0, NULL, NULL} }; /* }}} */ @@ -2366,7 +2408,7 @@ const php_snmp_prop_handler php_snmp_property_entries[] = { PHP_MINIT_FUNCTION(snmp) { netsnmp_log_handler *logh; - zend_class_entry ce; + zend_class_entry ce, cex; le_snmp_session = zend_register_list_destructors_ex(php_snmp_session_destructor, NULL, PHP_SNMP_SESSION_RES_NAME, module_number); @@ -2424,18 +2466,27 @@ PHP_MINIT_FUNCTION(snmp) REGISTER_LONG_CONSTANT("SNMP_INTEGER", ASN_INTEGER, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SNMP_COUNTER64", ASN_COUNTER64, CONST_CS | CONST_PERSISTENT); - REGISTER_SNMP_CLASS_CONST_LONG("VERSION_1", (long)SNMP_VERSION_1); - REGISTER_SNMP_CLASS_CONST_LONG("VERSION_2c", (long)SNMP_VERSION_2c); - REGISTER_SNMP_CLASS_CONST_LONG("VERSION_2C", (long)SNMP_VERSION_2c); - REGISTER_SNMP_CLASS_CONST_LONG("VERSION_3", (long)SNMP_VERSION_3); - - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_NOERROR", (long)PHP_SNMP_ERRNO_NOERROR); - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_GENERIC", (long)PHP_SNMP_ERRNO_GENERIC); - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_TIMEOUT", (long)PHP_SNMP_ERRNO_TIMEOUT); - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_ERROR_IN_REPLY", (long)PHP_SNMP_ERRNO_ERROR_IN_REPLY); - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_NOT_INCREASING", (long)PHP_SNMP_ERRNO_OID_NOT_INCREASING); - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_PARSING_ERROR", (long)PHP_SNMP_ERRNO_OID_PARSING_ERROR); - REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_MULTIPLE_SET_QUERIES", (long)PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_1", SNMP_VERSION_1); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_2c", SNMP_VERSION_2c); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_2C", SNMP_VERSION_2c); + REGISTER_SNMP_CLASS_CONST_LONG("VERSION_3", SNMP_VERSION_3); + + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_NOERROR", PHP_SNMP_ERRNO_NOERROR); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_ANY", PHP_SNMP_ERRNO_ANY); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_GENERIC", PHP_SNMP_ERRNO_GENERIC); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_TIMEOUT", PHP_SNMP_ERRNO_TIMEOUT); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_ERROR_IN_REPLY", PHP_SNMP_ERRNO_ERROR_IN_REPLY); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_NOT_INCREASING", PHP_SNMP_ERRNO_OID_NOT_INCREASING); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_OID_PARSING_ERROR", PHP_SNMP_ERRNO_OID_PARSING_ERROR); + REGISTER_SNMP_CLASS_CONST_LONG("ERRNO_MULTIPLE_SET_QUERIES", PHP_SNMP_ERRNO_MULTIPLE_SET_QUERIES); + + /* Register SNMPException class */ + INIT_CLASS_ENTRY(cex, "SNMPException", NULL); +#ifdef HAVE_SPL + php_snmp_exception_ce = zend_register_internal_class_ex(&cex, spl_ce_RuntimeException, NULL TSRMLS_CC); +#else + php_snmp_exception_ce = zend_register_internal_class_ex(&cex, zend_exception_get_default(TSRMLS_C), NULL TSRMLS_CC); +#endif return SUCCESS; } @@ -2465,10 +2516,30 @@ PHP_MINFO_FUNCTION(snmp) } /* }}} */ +/* {{{ snmp_module_deps[] + */ +#if ZEND_MODULE_API_NO >= 20050922 +static const zend_module_dep snmp_module_deps[] = { +#ifdef HAVE_SPL + ZEND_MOD_REQUIRED("spl") +#endif + ZEND_MOD_END +}; +#endif + + +/* }}} */ + /* {{{ snmp_module_entry */ zend_module_entry snmp_module_entry = { +#if ZEND_MODULE_API_NO >= 20050922 + STANDARD_MODULE_HEADER_EX, + NULL, + snmp_module_deps, +#else STANDARD_MODULE_HEADER, +#endif "snmp", snmp_functions, PHP_MINIT(snmp), diff --git a/ext/snmp/tests/snmp-object-error.phpt b/ext/snmp/tests/snmp-object-error.phpt index 83ba2b72631c6..b2fed9f3734ea 100644 --- a/ext/snmp/tests/snmp-object-error.phpt +++ b/ext/snmp/tests/snmp-object-error.phpt @@ -17,24 +17,41 @@ snmp_set_valueretrieval(SNMP_VALUE_PLAIN); try { var_dump(new SNMP(SNMP::VERSION_1, $hostname)); } catch (Exception $e) { - print $e->getMessage() . "\n"; + print $e->getMessage() . "\n"; } try { var_dump(new SNMP(SNMP::VERSION_1, $hostname, $community, '')); } catch (Exception $e) { - print $e->getMessage() . "\n"; + print $e->getMessage() . "\n"; } try { var_dump(new SNMP(SNMP::VERSION_1, $hostname, $community, $timeout, '')); } catch (Exception $e) { - print $e->getMessage() . "\n"; + print $e->getMessage() . "\n"; } try { var_dump(new SNMP(7, $hostname, $community)); } catch (Exception $e) { - print $e->getMessage() . "\n"; + print $e->getMessage() . "\n"; } +echo "Exception handling\n"; +$session = new SNMP(SNMP::VERSION_3, $hostname, $user_noauth, $timeout, $retries); +try { + var_dump($session->get('.1.3.6.1.2.1.1.1..0')); +} catch (SNMPException $e) { + var_dump($e->getCode()); + var_dump($e->getMessage()); +} +$session->exceptions_enabled = SNMP::ERRNO_ANY; +try { + var_dump($session->get('.1.3.6.1.2.1.1.1..0')); +} catch (SNMPException $e) { + var_dump($e->getCode()); + var_dump($e->getMessage()); +} +var_dump($session->close()); + echo "Open normal session\n"; $session = new SNMP(SNMP::VERSION_3, $hostname, $user_noauth, $timeout, $retries); $session->valueretrieval = 67; @@ -62,6 +79,13 @@ SNMP::__construct() expects at least 3 parameters, 2 given SNMP::__construct() expects parameter 4 to be long, string given SNMP::__construct() expects parameter 5 to be long, string given Unknown SNMP protocol version +Exception handling + +Warning: SNMP::get(): Invalid object identifier: .1.3.6.1.2.1.1.1..0 in %s on line %d +bool(false) +int(32) +string(46) "Invalid object identifier: .1.3.6.1.2.1.1.1..0" +bool(true) Open normal session Warning: main(): Unknown SNMP value retrieval method '67' in %s on line %d diff --git a/ext/snmp/tests/snmp-object-properties.phpt b/ext/snmp/tests/snmp-object-properties.phpt index e4c0538a09c51..40b69683df49e 100644 --- a/ext/snmp/tests/snmp-object-properties.phpt +++ b/ext/snmp/tests/snmp-object-properties.phpt @@ -91,6 +91,8 @@ object(SNMP)#%d (%d) { int(3) ["oid_increasing_check"]=> bool(true) + ["exceptions_enabled"]=> + int(0) } object(SNMP)#%d (%d) { ["info"]=> @@ -116,6 +118,8 @@ object(SNMP)#%d (%d) { int(4) ["oid_increasing_check"]=> bool(false) + ["exceptions_enabled"]=> + int(0) } object(SNMP)#%d (%d) { ["info"]=> @@ -141,6 +145,8 @@ object(SNMP)#%d (%d) { int(3) ["oid_increasing_check"]=> bool(true) + ["exceptions_enabled"]=> + int(0) } bool(true) bool(true) @@ -169,6 +175,8 @@ object(SNMP)#%d (%d) { int(3) ["oid_increasing_check"]=> bool(true) + ["exceptions_enabled"]=> + int(0) ["123"]=> string(11) "param_value" } From a183c17b079b25ed2beb5f587c2566e59f1bd5ae Mon Sep 17 00:00:00 2001 From: Boris Lytochkin Date: Fri, 2 Sep 2011 10:07:01 +0000 Subject: [PATCH 0726/2394] remove extra white space --- ext/snmp/snmp.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 41906f8d552d9..4518a68e9ae16 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -2526,8 +2526,6 @@ static const zend_module_dep snmp_module_deps[] = { ZEND_MOD_END }; #endif - - /* }}} */ /* {{{ snmp_module_entry From 70b9029d9efcaaed9284035c50aeaf6a3f80a43a Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 2 Sep 2011 10:38:51 +0000 Subject: [PATCH 0727/2394] As of MySQL 5.6.1 the server variable have_innodb is no more. Updating InnoDB check... --- ext/mysqli/tests/014.phpt | 16 ++++--------- ext/mysqli/tests/015.phpt | 16 +++++-------- ext/mysqli/tests/connect.inc | 24 +++++++++++++++++++ ext/mysqli/tests/mysqli_autocommit.phpt | 13 ++-------- ext/mysqli/tests/mysqli_autocommit_oo.phpt | 15 ++---------- .../tests/mysqli_change_user_rollback.phpt | 13 ++++------ ext/mysqli/tests/mysqli_commit.phpt | 22 +++++------------ ext/mysqli/tests/mysqli_commit_oo.phpt | 23 ++++++------------ ext/mysqli/tests/mysqli_fork.phpt | 19 ++++----------- ext/mysqli/tests/mysqli_rollback.phpt | 20 ++++------------ 10 files changed, 64 insertions(+), 117 deletions(-) diff --git a/ext/mysqli/tests/014.phpt b/ext/mysqli/tests/014.phpt index 8fb8cceef65b7..da6a0052cc0ed 100644 --- a/ext/mysqli/tests/014.phpt +++ b/ext/mysqli/tests/014.phpt @@ -5,19 +5,13 @@ mysqli autocommit/commit/rollback require_once('skipif.inc'); require_once('skipifconnectfailure.inc'); require_once("connect.inc"); + $link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket); - if (!$result = mysqli_query($link, "SHOW VARIABLES LIKE 'have_innodb'")) { - die("skip Cannot check for required InnoDB suppot"); - } - if (!$row = mysqli_fetch_row($result)) - die("skip Cannot check for required InnoDB suppot"); + if (!$link) + die(sprintf("Cannot connect, [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); - mysqli_free_result($result); - mysqli_close($link); - if ($row[1] == "DISABLED" || $row[1] == "NO") { - printf ("skip innodb support is not installed or enabled."); - exit; - } + if (!have_innodb($link)) + die(sprintf("Needs InnoDB support, [%d] %s", $link->errno, $link->error)); ?> --FILE-- errno, $link->error)); ?> --FILE-- query("SHOW VARIABLES LIKE 'have_innodb'") && + $row = $res->fetch_row() && + !empty($row)) { + if ($row[1] == "DISABLED" || $row[1] == "NO") { + return false; + } + return true; + } else { + /* MySQL 5.6.1+ */ + if ($res = $link->query("SHOW ENGINES")) { + while ($row = $res->fetch_assoc()) { + if (('InnoDB' == $row['Engine']) && ('YES' == $row['Support'])) { + return true; + } + } + return false; + } else { + return false; + } + } + return false; + } + } else { printf("skip Eeeek/BUG/FIXME - connect.inc included twice! skipif bug?\n"); } diff --git a/ext/mysqli/tests/mysqli_autocommit.phpt b/ext/mysqli/tests/mysqli_autocommit.phpt index f1f63e7f33305..a93d89f101ece 100644 --- a/ext/mysqli/tests/mysqli_autocommit.phpt +++ b/ext/mysqli/tests/mysqli_autocommit.phpt @@ -12,17 +12,8 @@ mysqli_autocommit() $host, $user, $db, $port, $socket)); } - if (!$result = mysqli_query($link, "SHOW VARIABLES LIKE 'have_innodb'")) { - die("skip Cannot check for required InnoDB suppot"); - } - if (!$row = mysqli_fetch_row($result)) - die("skip Cannot check for required InnoDB suppot"); - - mysqli_free_result($result); - mysqli_close($link); - if ($row[1] == "DISABLED" || $row[1] == "NO") { - die(sprintf ("skip innodb support is not installed or enabled.")); - } + if (!have_innodb($link)) + die(sprintf("Needs InnoDB support, [%d] %s", $link->errno, $link->error)); ?> --FILE-- autocommit() exit(1); } - if (!$res = $mysqli->query("SHOW VARIABLES LIKE 'have_innodb'")) { - printf("skip Cannot fetch have_innodb variable\n"); - exit(1); - } - - $row = $res->fetch_row(); - $res->free_result(); - $mysqli->close(); - - if ($row[1] == "DISABLED" || $row[1] == "NO") { - printf ("skip Innodb support is not installed or enabled."); - exit(1); - } + if (!have_innodb($link)) + die(sprintf("Needs InnoDB support, [%d] %s", $link->errno, $link->error)); ?> --FILE-- errno, $link->error)); ?> --FILE-- errno, $link->error)); ?> --FILE-- query("SHOW VARIABLES LIKE 'have_innodb'")) { - die(sprintf("skip Cannot fetch have_innodb variable\n")); -} - -$row = $res->fetch_row(); -$res->free(); -$mysqli->close(); - -if ($row[1] == "DISABLED" || $row[1] == "NO") { - die(sprintf("skip Innodb support is not installed or enabled.")); -} + +require_once('connect.inc'); +if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) + die(sprintf("Cannot connect, [%d] %s", mysqli_connect_errno(), mysqli_connect_error())); + +if (!have_innodb($link)) + die(sprintf("Needs InnoDB support, [%d] %s", $link->errno, $link->error)); ?> --FILE-- errno, $link->error)); ?> --FILE-- errno, $link->error)); ?> --FILE-- Date: Fri, 2 Sep 2011 11:06:51 +0000 Subject: [PATCH 0728/2394] Hopefully, this is an even better way to check for InnoDB support as of MySQL 5.6.1 --- ext/mysqli/tests/connect.inc | 7 ++++++- ext/pdo_mysql/tests/mysql_pdo_test.inc | 11 +++++++++-- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/ext/mysqli/tests/connect.inc b/ext/mysqli/tests/connect.inc index ec837d64b3a04..ee1dce4640218 100644 --- a/ext/mysqli/tests/connect.inc +++ b/ext/mysqli/tests/connect.inc @@ -234,7 +234,12 @@ /* MySQL 5.6.1+ */ if ($res = $link->query("SHOW ENGINES")) { while ($row = $res->fetch_assoc()) { - if (('InnoDB' == $row['Engine']) && ('YES' == $row['Support'])) { + if (!isset($row['Engine']) || !isset($row['Support'])) + return false; + + if (('InnoDB' == $row['Engine']) && + (('YES' == $row['Support']) || ('DEFAULT' == $row['Support'])) + ) { return true; } } diff --git a/ext/pdo_mysql/tests/mysql_pdo_test.inc b/ext/pdo_mysql/tests/mysql_pdo_test.inc index 0af2e6df65f03..115aeadc5a658 100644 --- a/ext/pdo_mysql/tests/mysql_pdo_test.inc +++ b/ext/pdo_mysql/tests/mysql_pdo_test.inc @@ -141,12 +141,19 @@ class MySQLPDOTest extends PDOTest { } - static function detect_transactional_mysql_engine($db) { + static function detect_transactional_mysql_engine($db) { foreach ($db->query("show variables like 'have%'") as $row) { - if ($row[1] == 'YES' && ($row[0] == 'have_innodb' || $row[0] == 'have_bdb')) { + if (!empty($row) && $row[1] == 'YES' && ($row[0] == 'have_innodb' || $row[0] == 'have_bdb')) { return str_replace("have_", "", $row[0]); } } + /* MySQL 5.6.1+ */ + foreach ($db->query("SHOW ENGINES") as $row) { + if (isset($row['engine']) && isset($row['support'])) { + if ('InnoDB' == $row['engine'] && ('YES' == $row['support'] || 'DEFAULT' == $row['support'])) + return 'innodb'; + } + } return false; } From 2dbc61a2ff44d095a0fd02b71169adb43db20537 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 2 Sep 2011 11:22:41 +0000 Subject: [PATCH 0729/2394] function rename to comply with the schema of other callbacks --- ext/mysqlnd/mysqlnd_ps.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_ps.c b/ext/mysqlnd/mysqlnd_ps.c index e4688c15646d3..e18e0aa3b41ea 100644 --- a/ext/mysqlnd/mysqlnd_ps.c +++ b/ext/mysqlnd/mysqlnd_ps.c @@ -41,7 +41,7 @@ static struct st_mysqlnd_stmt_methods *mysqlnd_stmt_methods; /* Exported by mysqlnd_ps_codec.c */ enum_func_status mysqlnd_stmt_execute_generate_request(MYSQLND_STMT * const s, zend_uchar ** request, size_t *request_len, zend_bool * free_buffer TSRMLS_DC); -enum_func_status mysqlnd_fetch_stmt_row_buffered(MYSQLND_RES *result, void *param, +enum_func_status mysqlnd_stmt_fetch_row_buffered(MYSQLND_RES *result, void *param, unsigned int flags, zend_bool *fetched_anything TSRMLS_DC); @@ -112,7 +112,7 @@ MYSQLND_METHOD(mysqlnd_stmt, store_result)(MYSQLND_STMT * const s TSRMLS_DC) result = stmt->result; result->type = MYSQLND_RES_PS_BUF; - result->m.fetch_row = mysqlnd_fetch_stmt_row_buffered; + result->m.fetch_row = mysqlnd_stmt_fetch_row_buffered; result->m.fetch_lengths = NULL;/* makes no sense */ result->m.row_decoder = php_mysqlnd_rowp_read_binary_protocol; @@ -720,16 +720,16 @@ MYSQLND_METHOD(mysqlnd_stmt, execute)(MYSQLND_STMT * const s TSRMLS_DC) /* }}} */ -/* {{{ mysqlnd_fetch_stmt_row_buffered */ +/* {{{ mysqlnd_stmt_fetch_row_buffered */ enum_func_status -mysqlnd_fetch_stmt_row_buffered(MYSQLND_RES *result, void *param, unsigned int flags, zend_bool *fetched_anything TSRMLS_DC) +mysqlnd_stmt_fetch_row_buffered(MYSQLND_RES *result, void *param, unsigned int flags, zend_bool *fetched_anything TSRMLS_DC) { MYSQLND_STMT * s = (MYSQLND_STMT *) param; MYSQLND_STMT_DATA * stmt = s? s->data:NULL; MYSQLND_RES_BUFFERED *set = result->stored_data; unsigned int field_count = result->meta->field_count; - DBG_ENTER("mysqlnd_fetch_stmt_row_buffered"); + DBG_ENTER("mysqlnd_stmt_fetch_row_buffered"); *fetched_anything = FALSE; DBG_INF_FMT("stmt=%lu", stmt != NULL ? stmt->stmt_id : 0L); From 1f3e66cd5641405d8c4236d9304b41db84938561 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 2 Sep 2011 12:59:32 +0000 Subject: [PATCH 0730/2394] fix message --- ext/mysqlnd/config9.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqlnd/config9.m4 b/ext/mysqlnd/config9.m4 index 58ca3ebcf8601..d335a2af6cd2f 100644 --- a/ext/mysqlnd/config9.m4 +++ b/ext/mysqlnd/config9.m4 @@ -3,7 +3,7 @@ dnl $Id$ dnl config.m4 for mysqlnd driver -PHP_ARG_ENABLE(mysqlnd_compression_support, whether to enable compressed protocol support in mysqlnd, +PHP_ARG_ENABLE(mysqlnd_compression_support, whether to disable compressed protocol support in mysqlnd, [ --disable-mysqlnd-compression-support Disable support for the MySQL compressed protocol in mysqlnd], yes, no) From 66b7705da2e1f7f4fecde1da11eb39beee6588c8 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 2 Sep 2011 13:35:17 +0000 Subject: [PATCH 0731/2394] Coverage for bug#54704, of which I think it is bogus, thus no dedicated test. --- ext/mysql/tests/mysql_num_rows.phpt | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/ext/mysql/tests/mysql_num_rows.phpt b/ext/mysql/tests/mysql_num_rows.phpt index 1f68b4d609fc2..0f538c4a2b16d 100644 --- a/ext/mysql/tests/mysql_num_rows.phpt +++ b/ext/mysql/tests/mysql_num_rows.phpt @@ -54,6 +54,23 @@ if ($res = mysql_query('SELECT COUNT(id) AS num FROM test', $link)) { printf("[030] [%d] %s\n", mysql_errno($link), mysql_error($link)); } +if ($res = mysql_unbuffered_query('SELECT id, label FROM test')) { + + if (0 != mysql_num_rows($res)) + printf("[032] Expecting 0 rows got %d\n", mysql_num_rows($res)); + + $rows = 0; + while ($row = mysql_fetch_assoc($res)) + $rows++; + + if ($rows != mysql_num_rows($res)) + printf("[033] Expecting %d rows got %d\n", $rows, mysql_num_rows($res)); + + mysql_free_result($res); +} else { + printf("[034] [%d] %s\n", mysql_errno($link), mysql_error($link)); +} + mysql_close($link); print "done!"; ?> From 27a48f0b44e564d4126d202d742d8617a9b6ad7c Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 2 Sep 2011 13:53:41 +0000 Subject: [PATCH 0732/2394] Fix for Bug #54158 MYSQLND + PDO MySQL requires #define MYSQL_OPT_LOCAL_INFILE and a bunch of other small preprocessor fixes --- ext/pdo_mysql/mysql_driver.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/ext/pdo_mysql/mysql_driver.c b/ext/pdo_mysql/mysql_driver.c index 60d9eba1dc9c0..93c178eefccf9 100755 --- a/ext/pdo_mysql/mysql_driver.c +++ b/ext/pdo_mysql/mysql_driver.c @@ -36,7 +36,7 @@ #endif #include "zend_exceptions.h" -#if PDO_USE_MYSQLND +#if defined(PDO_USE_MYSQLND) # define pdo_mysql_init(persistent) mysqlnd_init(persistent) #else # define pdo_mysql_init(persistent) mysql_init(NULL) @@ -230,7 +230,7 @@ static int mysql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len, if (S->num_params) { S->params_given = 0; -#if PDO_USE_MYSQLND +#if defined(PDO_USE_MYSQLND) S->params = NULL; #else S->params = ecalloc(S->num_params, sizeof(MYSQL_BIND)); @@ -433,7 +433,7 @@ static int pdo_mysql_get_attribute(pdo_dbh_t *dbh, long attr, zval *return_value break; case PDO_ATTR_SERVER_INFO: { char *tmp; -#if PDO_USE_MYSQLND +#if defined(PDO_USE_MYSQLND) unsigned int tmp_len; if (mysqlnd_stat(H->server, &tmp, &tmp_len) == PASS) { @@ -555,7 +555,7 @@ static int pdo_mysql_handle_factory(pdo_dbh_t *dbh, zval *driver_options TSRMLS_ #endif ; -#if PDO_USE_MYSQLND +#if defined(PDO_USE_MYSQLND) int dbname_len = 0; int password_len = 0; #endif @@ -630,7 +630,7 @@ static int pdo_mysql_handle_factory(pdo_dbh_t *dbh, zval *driver_options TSRMLS_ { local_infile = 0; } -#ifdef MYSQL_OPT_LOCAL_INFILE +#if defined(MYSQL_OPT_LOCAL_INFILE) || defined(PDO_USE_MYSQLND) if (mysql_options(H->server, MYSQL_OPT_LOCAL_INFILE, (const char *)&local_infile)) { pdo_mysql_error(dbh); goto cleanup; @@ -638,7 +638,9 @@ static int pdo_mysql_handle_factory(pdo_dbh_t *dbh, zval *driver_options TSRMLS_ #endif #ifdef MYSQL_OPT_RECONNECT /* since 5.0.3, the default for this option is 0 if not specified. - * we want the old behaviour */ + * we want the old behaviour + * mysqlnd doesn't support reconnect, thus we don't have "|| defined(PDO_USE_MYSQLND)" + */ { long reconnect = 1; mysql_options(H->server, MYSQL_OPT_RECONNECT, (const char*)&reconnect); From a5f3b37b46215f73ba969cbb6c8b2b4358c65cdb Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Fri, 2 Sep 2011 17:41:39 +0000 Subject: [PATCH 0733/2394] Removed old (< 5.3) version of test and cleaned up the actual version. --- ext/zip/tests/bug38943.inc | 16 --------------- ext/zip/tests/bug38943.phpt | 24 ++++++++++++++++------ ext/zip/tests/bug38943_2.phpt | 38 ----------------------------------- 3 files changed, 18 insertions(+), 60 deletions(-) delete mode 100644 ext/zip/tests/bug38943.inc delete mode 100644 ext/zip/tests/bug38943_2.phpt diff --git a/ext/zip/tests/bug38943.inc b/ext/zip/tests/bug38943.inc deleted file mode 100644 index a6f45e8294eff..0000000000000 --- a/ext/zip/tests/bug38943.inc +++ /dev/null @@ -1,16 +0,0 @@ -testarray[] = 1; - var_dump($this->testarray); - } -} - -$z = new myZip; -$z->testp = "foobar"; -var_dump($z); - diff --git a/ext/zip/tests/bug38943.phpt b/ext/zip/tests/bug38943.phpt index 02985848dc2e3..c5e22847192ff 100644 --- a/ext/zip/tests/bug38943.phpt +++ b/ext/zip/tests/bug38943.phpt @@ -1,14 +1,26 @@ --TEST-- -#38943, properties in extended class cannot be set (< 5.3) +#38943, properties in extended class cannot be set (5.3+) --SKIPIF-- --FILE-- testarray[] = 1; + var_dump($this->testarray); + } +} + +$z = new myZip; +$z->testp = "foobar"; +var_dump($z); + ?> --EXPECTF-- array(1) { @@ -16,11 +28,11 @@ array(1) { int(1) } object(myZip)#1 (%d) { - ["test:private"]=> + ["test":"myZip":private]=> int(0) ["testp"]=> string(6) "foobar" - ["testarray:private"]=> + ["testarray":"myZip":private]=> array(1) { [0]=> int(1) diff --git a/ext/zip/tests/bug38943_2.phpt b/ext/zip/tests/bug38943_2.phpt deleted file mode 100644 index 8672d9d329138..0000000000000 --- a/ext/zip/tests/bug38943_2.phpt +++ /dev/null @@ -1,38 +0,0 @@ ---TEST-- -#38943, properties in extended class cannot be set (5.3) ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -array(1) { - [0]=> - int(1) -} -object(myZip)#1 (%d) { - ["test":"myZip":private]=> - int(0) - ["testp"]=> - string(6) "foobar" - ["testarray":"myZip":private]=> - array(1) { - [0]=> - int(1) - } - ["status"]=> - int(0) - ["statusSys"]=> - int(0) - ["numFiles"]=> - int(0) - ["filename"]=> - string(0) "" - ["comment"]=> - string(0) "" -} From 712628c47cf3bd7539a570ad442d4d9b8d9eef29 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Fri, 2 Sep 2011 18:01:20 +0000 Subject: [PATCH 0734/2394] Synchronized fixed tests from 5.3 branch. --- .../xsltprocessor_registerPHPFunctions-funcnostring.phpt | 7 +++++++ .../xsltprocessor_registerPHPFunctions-funcundef.phpt | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt index 90d9c68208c2d..d5d99f92245d6 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt @@ -21,10 +21,17 @@ if(!$phpfuncxsl) { $proc->importStylesheet($phpfuncxsl); var_dump($proc->registerPHPFunctions()); var_dump($proc->transformToXml($dom)); +?> --EXPECTF-- NULL Warning: XSLTProcessor::transformToXml(): Handler name must be a string in %s on line %d + +Warning: XSLTProcessor::transformToXml(): xmlXPathCompiledEval: evaluation failed in %s on line %d + +Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element value-of in %s on line %d + +Warning: XSLTProcessor::transformToXml(): XPath evaluation returned no result. in %s on line %d NULL --CREDITS-- Christian Weiske, cweiske@php.net diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt index a26c2103331dd..a91e6459dba9a 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt @@ -20,10 +20,17 @@ if(!$phpfuncxsl) { $proc->importStylesheet($phpfuncxsl); var_dump($proc->registerPHPFunctions()); var_dump($proc->transformToXml($dom)); +?> --EXPECTF-- NULL Warning: XSLTProcessor::transformToXml(): Unable to call handler undefinedfunc() in %s on line %d + +Warning: XSLTProcessor::transformToXml(): xmlXPathCompiledEval: evaluation failed in %s on line %d + +Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element value-of in %s on line %d + +Warning: XSLTProcessor::transformToXml(): XPath evaluation returned no result. in %s on line %d NULL --CREDITS-- Christian Weiske, cweiske@php.net From 38131641a06278cdb349a147f6efded3f76e2d6b Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Fri, 2 Sep 2011 20:28:39 +0000 Subject: [PATCH 0735/2394] pass an absolute path for the php binary to proc_open, without this the test would fail if ran with a relative TEST_DEV_EXECUTABLE --- ext/standard/tests/streams/bug46024.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/streams/bug46024.phpt b/ext/standard/tests/streams/bug46024.phpt index 3f2a5f836b542..fdfd03ee2ef97 100644 --- a/ext/standard/tests/streams/bug46024.phpt +++ b/ext/standard/tests/streams/bug46024.phpt @@ -4,7 +4,7 @@ Bug #46024 stream_select() doesn't return the correct number --FILE-- Date: Fri, 2 Sep 2011 22:19:03 +0000 Subject: [PATCH 0736/2394] gcov test fixes --- ext/pdo/tests/bug_34630.phpt | 2 -- ext/pdo/tests/bug_43130.phpt | 1 + ext/pdo/tests/bug_44861.phpt | 4 +++- ext/pdo/tests/pdo_016.phpt | 1 + ext/pdo/tests/pdo_016a.phpt | 1 + ext/pdo_oci/tests/bug46274.phpt | 2 ++ ext/pdo_oci/tests/bug46274_2.phpt | 2 ++ 7 files changed, 10 insertions(+), 3 deletions(-) diff --git a/ext/pdo/tests/bug_34630.phpt b/ext/pdo/tests/bug_34630.phpt index 22ad2e820a380..070217bafed1e 100644 --- a/ext/pdo/tests/bug_34630.phpt +++ b/ext/pdo/tests/bug_34630.phpt @@ -45,8 +45,6 @@ $db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, true); var_dump($db->query("SELECT * from test")->fetchAll(PDO::FETCH_ASSOC)); ?> ---XFAIL-- -This bug might be still open on aix5.2-ppc64 and hpux11.23-ia64 --EXPECT-- array(1) { [0]=> diff --git a/ext/pdo/tests/bug_43130.phpt b/ext/pdo/tests/bug_43130.phpt index bb40f894dd81d..a35138a07ff6f 100644 --- a/ext/pdo/tests/bug_43130.phpt +++ b/ext/pdo/tests/bug_43130.phpt @@ -7,6 +7,7 @@ $dir = getenv('REDIR_TEST_DIR'); if (false == $dir) die('skip no driver'); if (!strncasecmp(getenv('PDOTEST_DSN'), 'sqlite', strlen('sqlite'))) die('skip not relevant for sqlite driver'); if (!strncasecmp(getenv('PDOTEST_DSN'), 'pgsql', strlen('pgsql'))) die('skip not relevant for pgsql driver'); +if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))) die('skip not relevant for oci driver - Hyphen is not legal for bind names in Oracle DB'); require_once $dir . 'pdo_test.inc'; PDOTest::skip(); ?> diff --git a/ext/pdo/tests/bug_44861.phpt b/ext/pdo/tests/bug_44861.phpt index 3612561ed6a81..cb8e657e9bdd3 100644 --- a/ext/pdo/tests/bug_44861.phpt +++ b/ext/pdo/tests/bug_44861.phpt @@ -28,11 +28,13 @@ $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); if ($db->getAttribute(PDO::ATTR_DRIVER_NAME) == 'oci') { $from = 'FROM DUAL'; + $ob = '1'; } else { $from = ''; + $ob = 'r'; } -$query = "SELECT 'row1' AS r $from UNION SELECT 'row2' $from UNION SELECT 'row3' $from UNION SELECT 'row4' $from ORDER BY r"; +$query = "SELECT 'row1' AS r $from UNION SELECT 'row2' $from UNION SELECT 'row3' $from UNION SELECT 'row4' $from ORDER BY $ob"; $aParams = array(PDO::ATTR_CURSOR => PDO::CURSOR_SCROLL); $res = $db->prepare($query, $aParams); diff --git a/ext/pdo/tests/pdo_016.phpt b/ext/pdo/tests/pdo_016.phpt index f3aba13e0e382..12c95172338a8 100644 --- a/ext/pdo/tests/pdo_016.phpt +++ b/ext/pdo/tests/pdo_016.phpt @@ -5,6 +5,7 @@ PDO Common: PDO::FETCH_BOUND if (!extension_loaded('pdo')) die('skip'); $dir = getenv('REDIR_TEST_DIR'); if (false == $dir) die('skip no driver'); +if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))) die('skip not relevant for oci driver - cannot reexecute after closing cursors without reparse'); require_once $dir . 'pdo_test.inc'; PDOTest::skip(); ?> diff --git a/ext/pdo/tests/pdo_016a.phpt b/ext/pdo/tests/pdo_016a.phpt index 00b75aecade13..72f4b4224f191 100755 --- a/ext/pdo/tests/pdo_016a.phpt +++ b/ext/pdo/tests/pdo_016a.phpt @@ -6,6 +6,7 @@ if (!extension_loaded('pdo')) die('skip'); $dir = getenv('REDIR_TEST_DIR'); if (false == $dir) die('skip no driver'); require_once $dir . 'pdo_test.inc'; +if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))) die('skip not relevant for oci driver - cannot reexecute after closing cursors without reparse'); PDOTest::skip(); ?> --FILE-- diff --git a/ext/pdo_oci/tests/bug46274.phpt b/ext/pdo_oci/tests/bug46274.phpt index 23ee8ee20f7b7..77f2a01151254 100644 --- a/ext/pdo_oci/tests/bug46274.phpt +++ b/ext/pdo_oci/tests/bug46274.phpt @@ -56,6 +56,8 @@ var_dump($res->fetch()); $db->exec("DROP TABLE test_one_blob"); ?> +--XFAIL-- +Corrupts memory --EXPECTF-- array(2) { ["blob1"]=> diff --git a/ext/pdo_oci/tests/bug46274_2.phpt b/ext/pdo_oci/tests/bug46274_2.phpt index cbadcef4f8cb1..9e9225415f720 100644 --- a/ext/pdo_oci/tests/bug46274_2.phpt +++ b/ext/pdo_oci/tests/bug46274_2.phpt @@ -60,6 +60,8 @@ fclose($row[0]); $db->exec("DROP TABLE test_one_blob"); ?> +--XFAIL-- +Corrupts memory --EXPECTF-- array(2) { ["blob1"]=> From 1d50d1174c32365202fc2042be0c2436bbbd9699 Mon Sep 17 00:00:00 2001 From: Daniel Convissor Date: Sun, 4 Sep 2011 00:56:38 +0000 Subject: [PATCH 0737/2394] Make test work with database other than "test" (merge from 5.4). --- ext/mysqli/tests/mysqli_free_result.phpt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/mysqli/tests/mysqli_free_result.phpt b/ext/mysqli/tests/mysqli_free_result.phpt index a065e1482178d..28f338ac6d4cd 100644 --- a/ext/mysqli/tests/mysqli_free_result.phpt +++ b/ext/mysqli/tests/mysqli_free_result.phpt @@ -10,7 +10,6 @@ require_once('skipifconnectfailure.inc'); Date: Sun, 4 Sep 2011 04:57:01 +0000 Subject: [PATCH 0738/2394] test fixes --- ext/mbstring/tests/mb_internal_encoding_variation2.phpt | 4 ++-- ext/mysqli/tests/mysqli_options_openbasedir.phpt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/mbstring/tests/mb_internal_encoding_variation2.phpt b/ext/mbstring/tests/mb_internal_encoding_variation2.phpt index 3d2c5473136a9..755a954eff656 100644 --- a/ext/mbstring/tests/mb_internal_encoding_variation2.phpt +++ b/ext/mbstring/tests/mb_internal_encoding_variation2.phpt @@ -335,10 +335,10 @@ string(5) "BIG-5" -- Iteration 49 -- string(5) "BIG-5" bool(true) -string(5) "BIG-5" +string(5) "CP950" -- Iteration 50 -- -string(5) "BIG-5" +string(5) "CP950" bool(true) string(6) "EUC-KR" diff --git a/ext/mysqli/tests/mysqli_options_openbasedir.phpt b/ext/mysqli/tests/mysqli_options_openbasedir.phpt index 81d8ffef64deb..500baf3781335 100644 --- a/ext/mysqli/tests/mysqli_options_openbasedir.phpt +++ b/ext/mysqli/tests/mysqli_options_openbasedir.phpt @@ -7,10 +7,10 @@ require_once('skipifemb.inc'); require_once('skipifconnectfailure.inc'); ?> --INI-- -open_basedir="." --FILE-- Date: Sun, 4 Sep 2011 05:00:30 +0000 Subject: [PATCH 0739/2394] fix test --- ext/mbstring/tests/mb_internal_encoding_variation2.phpt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/mbstring/tests/mb_internal_encoding_variation2.phpt b/ext/mbstring/tests/mb_internal_encoding_variation2.phpt index 755a954eff656..914041c914997 100644 --- a/ext/mbstring/tests/mb_internal_encoding_variation2.phpt +++ b/ext/mbstring/tests/mb_internal_encoding_variation2.phpt @@ -330,15 +330,15 @@ string(6) "EUC-TW" -- Iteration 48 -- string(6) "EUC-TW" bool(true) -string(5) "BIG-5" +string(5) "CP950" -- Iteration 49 -- -string(5) "BIG-5" -bool(true) string(5) "CP950" +bool(true) +string(5) "BIG-5" -- Iteration 50 -- -string(5) "CP950" +string(5) "BIG-5" bool(true) string(6) "EUC-KR" From 9582b621118b7d5aa36b4db6ac6d0c457dbf9d60 Mon Sep 17 00:00:00 2001 From: Tjerk Anne Meesters Date: Sun, 4 Sep 2011 14:21:27 +0000 Subject: [PATCH 0740/2394] Patch to run two more mysql test cases that would usually be skipped. Replaced skipifdefaultconnectionfailure.inc by three additional ini_set() statements in connect.inc for the default connection settings Patch also includes a typo in connect.inc concerning mysql.default_socket --- ext/mysql/tests/connect.inc | 10 ++++++++-- ext/mysql/tests/mysql_affected_rows.phpt | 1 - ext/mysql/tests/mysql_insert_id.phpt | 1 - ext/mysql/tests/skipifdefaultconnectfailure.inc | 11 ----------- 4 files changed, 8 insertions(+), 15 deletions(-) delete mode 100755 ext/mysql/tests/skipifdefaultconnectfailure.inc diff --git a/ext/mysql/tests/connect.inc b/ext/mysql/tests/connect.inc index 97fed421465b8..5c2f93d8f03f4 100755 --- a/ext/mysql/tests/connect.inc +++ b/ext/mysql/tests/connect.inc @@ -64,13 +64,19 @@ $host = getenv("MYSQL_TEST_HOST") ? getenv("MYSQL_TEST_HOST") : "localhost"; $port = getenv("MYSQL_TEST_PORT") ? getenv("MYSQL_TEST_PORT") : 3306; $user = getenv("MYSQL_TEST_USER") ? getenv("MYSQL_TEST_USER") : "root"; $passwd = getenv("MYSQL_TEST_PASSWD") ? getenv("MYSQL_TEST_PASSWD") : ""; + +// added so that mysql_connect() without args works as well (required in some tests that rely on a default connection being opened implicitly) +ini_set('mysql.default_host', $host); +ini_set('mysql.default_user', $user); +ini_set('mysql.default_password', $passwd); + $db = getenv("MYSQL_TEST_DB") ? getenv("MYSQL_TEST_DB") : "test"; $engine = getenv("MYSQL_TEST_ENGINE") ? getenv("MYSQL_TEST_ENGINE") : "MyISAM"; $socket = getenv("MYSQL_TEST_SOCKET") ? getenv("MYSQL_TEST_SOCKET") : null; $skip_on_connect_failure = getenv("MYSQL_TEST_SKIP_CONNECT_FAILURE") ? getenv("MYSQL_TEST_SKIP_CONNECT_FAILURE") : true; $connect_flags = getenv("MYSQL_TEST_CONNECT_FLAGS") ? (int)getenv("MYSQL_TEST_CONNECT_FLAGS") : 0; if ($socket) { - ini_set('mysql.default_user', $socket); + ini_set('mysql.default_socket', $socket); } /* Development setting: test experimal features and/or feature requests that never worked before? */ $TEST_EXPERIMENTAL = (in_array(getenv("MYSQL_TEST_EXPERIMENTAL"), array(0, 1))) ? @@ -78,4 +84,4 @@ $TEST_EXPERIMENTAL = (in_array(getenv("MYSQL_TEST_EXPERIMENTAL"), array(0, 1))) false; $IS_MYSQLND = stristr(mysql_get_client_info(), "mysqlnd"); -?> \ No newline at end of file +?> diff --git a/ext/mysql/tests/mysql_affected_rows.phpt b/ext/mysql/tests/mysql_affected_rows.phpt index ce16a7748c397..42632bf8d7f65 100644 --- a/ext/mysql/tests/mysql_affected_rows.phpt +++ b/ext/mysql/tests/mysql_affected_rows.phpt @@ -4,7 +4,6 @@ mysql_affected_rows() --FILE-- --FILE-- From f1c31a5a15a703cb2df65233d3869c162f2e069f Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Sun, 4 Sep 2011 14:28:52 +0000 Subject: [PATCH 0741/2394] passing an invalid session.upload_progress.freq always generates an additional startup error --- ext/session/tests/rfc1867_invalid_settings.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/session/tests/rfc1867_invalid_settings.phpt b/ext/session/tests/rfc1867_invalid_settings.phpt index 29fe630509acc..173b95a025e38 100644 --- a/ext/session/tests/rfc1867_invalid_settings.phpt +++ b/ext/session/tests/rfc1867_invalid_settings.phpt @@ -9,5 +9,7 @@ session.upload_progress.freq=-1 var_dump(ini_get("session.upload_progress.freq")); ?> --EXPECTF-- +PHP Warning: PHP Startup: session.upload_progress.freq must be greater than or equal to zero in %s + Warning: PHP Startup: session.upload_progress.freq must be greater than or equal to zero in %s string(%d) "1%" From ccac1ad9b67af867908dfc2c6902fe7972793a70 Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Sun, 4 Sep 2011 15:02:08 +0000 Subject: [PATCH 0742/2394] passing an invalid session.upload_progress.freq always generates an additional startup error --- ext/session/tests/rfc1867_invalid_settings_2.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/session/tests/rfc1867_invalid_settings_2.phpt b/ext/session/tests/rfc1867_invalid_settings_2.phpt index bd35852c1dbfb..3028808107227 100644 --- a/ext/session/tests/rfc1867_invalid_settings_2.phpt +++ b/ext/session/tests/rfc1867_invalid_settings_2.phpt @@ -9,5 +9,7 @@ session.upload_progress.freq=200% var_dump(ini_get("session.upload_progress.freq")); ?> --EXPECTF-- +PHP Warning: PHP Startup: session.upload_progress.freq cannot be over 100% in %s + Warning: PHP Startup: session.upload_progress.freq cannot be over 100% in %s string(%d) "1%" From 678e8e28720ff25763d5f29ebbbe313318e6b856 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 4 Sep 2011 16:33:31 +0000 Subject: [PATCH 0743/2394] - wrong variable used (ended as non initiazed usage) --- ext/intl/formatter/formatter_attr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/intl/formatter/formatter_attr.c b/ext/intl/formatter/formatter_attr.c index b306bbedeb9f4..448a9db721d1b 100755 --- a/ext/intl/formatter/formatter_attr.c +++ b/ext/intl/formatter/formatter_attr.c @@ -77,11 +77,11 @@ PHP_FUNCTION( numfmt_get_attribute ) break; case UNUM_ROUNDING_INCREMENT: { - double value = unum_getDoubleAttribute(FORMATTER_OBJECT(nfo), attribute); - if(value == -1) { + double value_double = unum_getDoubleAttribute(FORMATTER_OBJECT(nfo), attribute); + if(value_double == -1) { INTL_DATA_ERROR_CODE(nfo) = U_UNSUPPORTED_ERROR; } else { - RETVAL_DOUBLE(value); + RETVAL_DOUBLE(value_double); } } break; From ae1af27e18930bdf7b3ac4972af5bac7e87c8642 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 4 Sep 2011 18:50:05 +0000 Subject: [PATCH 0744/2394] fix bug 55562 - make substr always return rest of the string if length is too long --- ext/intl/grapheme/grapheme_string.c | 14 +++++++++----- ext/intl/tests/bug55562.phpt | 13 +++++++++++++ 2 files changed, 22 insertions(+), 5 deletions(-) create mode 100644 ext/intl/tests/bug55562.phpt diff --git a/ext/intl/grapheme/grapheme_string.c b/ext/intl/grapheme/grapheme_string.c index 719015fe64be7..692e2f80b0d63 100755 --- a/ext/intl/grapheme/grapheme_string.c +++ b/ext/intl/grapheme/grapheme_string.c @@ -554,13 +554,17 @@ PHP_FUNCTION(grapheme_substr) length += iter_val; } - if ( UBRK_DONE == sub_str_end_pos && length < 0) { + if ( UBRK_DONE == sub_str_end_pos) { + if(length < 0) { - intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, "grapheme_substr: length not contained in string", 1 TSRMLS_CC ); + intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR, "grapheme_substr: length not contained in string", 1 TSRMLS_CC ); - efree(ustr); - ubrk_close(bi); - RETURN_FALSE; + efree(ustr); + ubrk_close(bi); + RETURN_FALSE; + } else { + sub_str_end_pos = ustr_len; + } } sub_str = NULL; diff --git a/ext/intl/tests/bug55562.phpt b/ext/intl/tests/bug55562.phpt new file mode 100644 index 0000000000000..dd053c0ee957c --- /dev/null +++ b/ext/intl/tests/bug55562.phpt @@ -0,0 +1,13 @@ +--TEST-- +grapheme_substr() - Bug55562 - grapheme_substr() returns false if length parameter is to large +--SKIPIF-- + +--FILE-- + Date: Sun, 4 Sep 2011 21:40:22 +0000 Subject: [PATCH 0745/2394] - fix test on win, does not use putenv to set the TZ but date_default_timezone_set (should be the case on all platforms actually...) --- ext/date/tests/date.phpt | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/ext/date/tests/date.phpt b/ext/date/tests/date.phpt index ccdb3cda946fe..089efb41545a6 100644 --- a/ext/date/tests/date.phpt +++ b/ext/date/tests/date.phpt @@ -3,14 +3,22 @@ date() function --FILE-- Date: Sun, 4 Sep 2011 21:48:22 +0000 Subject: [PATCH 0746/2394] - unify warning between win and unix and enable test --- ext/standard/dns_win32.c | 5 +++++ ext/standard/tests/network/bug41347.phpt | 6 ------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/ext/standard/dns_win32.c b/ext/standard/dns_win32.c index 7bded1cdafdba..2dbf3e2e1da70 100644 --- a/ext/standard/dns_win32.c +++ b/ext/standard/dns_win32.c @@ -103,6 +103,11 @@ PHP_FUNCTION(dns_check_record) return; } + if (hostname_len == 0) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host cannot be empty"); + RETURN_FALSE; + } + if (rectype) { if (!strcasecmp("A", rectype)) type = DNS_TYPE_A; else if (!strcasecmp("NS", rectype)) type = DNS_TYPE_NS; diff --git a/ext/standard/tests/network/bug41347.phpt b/ext/standard/tests/network/bug41347.phpt index 21fc002fa53eb..6ece098191de5 100644 --- a/ext/standard/tests/network/bug41347.phpt +++ b/ext/standard/tests/network/bug41347.phpt @@ -1,11 +1,5 @@ --TEST-- dns_check_record() segfault with empty host ---SKIPIF-- - --FILE-- Date: Sun, 4 Sep 2011 21:59:27 +0000 Subject: [PATCH 0747/2394] - skip on win, TZs differ with strftime --- ext/date/tests/bug27780.phpt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/date/tests/bug27780.phpt b/ext/date/tests/bug27780.phpt index bd3bc949bd2b9..af35b8fbf02cb 100644 --- a/ext/date/tests/bug27780.phpt +++ b/ext/date/tests/bug27780.phpt @@ -1,5 +1,10 @@ --TEST-- Bug #27780 (strtotime(+1 xxx) returns a wrong date/time) +--SKIPIF-- + Date: Sun, 4 Sep 2011 22:04:42 +0000 Subject: [PATCH 0748/2394] - skip on win, TZ cannot be set using putenv at runtime --- ext/date/tests/bug13142.phpt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/date/tests/bug13142.phpt b/ext/date/tests/bug13142.phpt index 60fc7e7f6eaed..dc02f68dad748 100644 --- a/ext/date/tests/bug13142.phpt +++ b/ext/date/tests/bug13142.phpt @@ -4,6 +4,11 @@ Bug #13142 (strtotime handling of "M d H:i:s Y" format) date.timezone=US/Eastern --SKIPIF-- Date: Sun, 4 Sep 2011 22:12:42 +0000 Subject: [PATCH 0749/2394] - force LF eol From c4d6b3d786290cf9e1c8dca4a81c068d7ccdee86 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Sun, 4 Sep 2011 22:21:58 +0000 Subject: [PATCH 0750/2394] - add skipif --- ext/filter/tests/bug44779.phpt | 2 ++ ext/filter/tests/bug46973.phpt | 2 ++ ext/filter/tests/bug47435.phpt | 2 ++ ext/filter/tests/bug47745.phpt | 2 ++ ext/filter/tests/bug48762.phpt | 2 ++ ext/filter/tests/bug50158.phpt | 2 ++ 6 files changed, 12 insertions(+) diff --git a/ext/filter/tests/bug44779.phpt b/ext/filter/tests/bug44779.phpt index 33a4fe4ffbc15..65a1e094ee73f 100644 --- a/ext/filter/tests/bug44779.phpt +++ b/ext/filter/tests/bug44779.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #44779 (filter returns NULL in CLI when it shouldn't) +--SKIPIF-- + --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- Date: Sun, 4 Sep 2011 22:36:33 +0000 Subject: [PATCH 0751/2394] - Fixed borked refactoring in r307437 (using SUCCESS/FAILURE return instead of out parameter). - Fixed signature of php_stream_copy_to_stream_ex to return int in 5.4/trunk instead of size_t, as the function only returns SUCCESS/FAILURE. --- main/php_streams.h | 2 +- main/streams/cast.c | 14 ++++++++------ main/streams/streams.c | 2 +- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/main/php_streams.h b/main/php_streams.h index b87cf1b86ef92..b1d70a84015a2 100755 --- a/main/php_streams.h +++ b/main/php_streams.h @@ -438,7 +438,7 @@ BEGIN_EXTERN_C() ZEND_ATTRIBUTE_DEPRECATED PHPAPI size_t _php_stream_copy_to_stream(php_stream *src, php_stream *dest, size_t maxlen STREAMS_DC TSRMLS_DC); #define php_stream_copy_to_stream(src, dest, maxlen) _php_stream_copy_to_stream((src), (dest), (maxlen) STREAMS_CC TSRMLS_CC) -PHPAPI size_t _php_stream_copy_to_stream_ex(php_stream *src, php_stream *dest, size_t maxlen, size_t *len STREAMS_DC TSRMLS_DC); +PHPAPI int _php_stream_copy_to_stream_ex(php_stream *src, php_stream *dest, size_t maxlen, size_t *len STREAMS_DC TSRMLS_DC); #define php_stream_copy_to_stream_ex(src, dest, maxlen, len) _php_stream_copy_to_stream_ex((src), (dest), (maxlen), (len) STREAMS_CC TSRMLS_CC) diff --git a/main/streams/cast.c b/main/streams/cast.c index 38eb1a987c009..305ee6e8aab98 100644 --- a/main/streams/cast.c +++ b/main/streams/cast.c @@ -271,15 +271,15 @@ PHPAPI int _php_stream_cast(php_stream *stream, int castas, void **ret, int show newstream = php_stream_fopen_tmpfile(); if (newstream) { - size_t retval = php_stream_copy_to_stream_ex(stream, newstream, PHP_STREAM_COPY_ALL, NULL); + int retcopy = php_stream_copy_to_stream_ex(stream, newstream, PHP_STREAM_COPY_ALL, NULL); - if (ret != SUCCESS) { + if (retcopy != SUCCESS) { php_stream_close(newstream); } else { - int retcode = php_stream_cast(newstream, castas | flags, (void **)ret, show_err); + int retcast = php_stream_cast(newstream, castas | flags, (void **)ret, show_err); - if (retcode == SUCCESS) { - rewind(*(FILE**)retval); + if (retcast == SUCCESS) { + rewind(*(FILE**)ret); } /* do some specialized cleanup */ @@ -287,7 +287,9 @@ PHPAPI int _php_stream_cast(php_stream *stream, int castas, void **ret, int show php_stream_free(stream, PHP_STREAM_FREE_CLOSE_CASTED); } - return retcode; + /* TODO: we probably should be setting .stdiocast and .fclose_stdiocast or + * we may be leaking the FILE*. Needs investigation, though. */ + return retcast; } } } diff --git a/main/streams/streams.c b/main/streams/streams.c index 15c1454547ac3..4679a97aa691c 100755 --- a/main/streams/streams.c +++ b/main/streams/streams.c @@ -1417,7 +1417,7 @@ PHPAPI size_t _php_stream_copy_to_mem(php_stream *src, char **buf, size_t maxlen } /* Returns SUCCESS/FAILURE and sets *len to the number of bytes moved */ -PHPAPI size_t _php_stream_copy_to_stream_ex(php_stream *src, php_stream *dest, size_t maxlen, size_t *len STREAMS_DC TSRMLS_DC) +PHPAPI int _php_stream_copy_to_stream_ex(php_stream *src, php_stream *dest, size_t maxlen, size_t *len STREAMS_DC TSRMLS_DC) { char buf[CHUNK_SIZE]; size_t readchunk; From ac20ab11f77b9ad409bb5cc4c7ac09aa10392175 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sun, 4 Sep 2011 23:00:47 +0000 Subject: [PATCH 0752/2394] - Fixed bug #55576: Cannot conditionally move uploaded file without race condition. --- ext/standard/basic_functions.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 9d7c0ca4936da..090364584d5c2 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -5764,7 +5764,6 @@ PHP_FUNCTION(move_uploaded_file) RETURN_FALSE; } - VCWD_UNLINK(new_path); if (VCWD_RENAME(path, new_path) == 0) { successful = 1; #ifndef PHP_WIN32 From 187b419b0473016f149c8f6dc3d8159b24ad9e73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Mon, 5 Sep 2011 00:39:39 +0000 Subject: [PATCH 0753/2394] - Fixed bad xor in signed types due to integer promotion. - Replaced undefined signed overflow with char -> unsigned char conversion. --- ext/mysqlnd/mysqlnd_charset.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_charset.c b/ext/mysqlnd/mysqlnd_charset.c index a87b2a1f4f522..0b7ce08236b46 100644 --- a/ext/mysqlnd/mysqlnd_charset.c +++ b/ext/mysqlnd/mysqlnd_charset.c @@ -123,11 +123,11 @@ static unsigned int check_mb_utf8_sequence(const char *start, const char *end) [F4][80..8F][80..BF][80..BF] */ - if (!((start[1] ^ 0x80) < 0x40 && - (start[2] ^ 0x80) < 0x40 && - (start[3] ^ 0x80) < 0x40 && - (c >= 0xf1 || start[1] >= (char)0x90) && - (c <= 0xf3 || start[1] <= (char)0x8F))) + if (!(((zend_uchar)start[1] ^ 0x80) < 0x40 && + ((zend_uchar)start[2] ^ 0x80) < 0x40 && + ((zend_uchar)start[3] ^ 0x80) < 0x40 && + (c >= 0xf1 || (zend_uchar)start[1] >= 0x90) && + (c <= 0xf3 || (zend_uchar)start[1] <= 0x8F))) { return 0; /* invalid utf8 character */ } From e07d1f0bbc3132eef18aff44f14f196ebe1d476b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 5 Sep 2011 00:49:03 +0000 Subject: [PATCH 0754/2394] fix tests --- ext/intl/tests/dateformat_parse.phpt | 98 ++++++++---- .../dateformat_parse_timestamp_parsepos.phpt | 119 +++++++++------ ext/intl/tests/locale_get_display_region.phpt | 12 +- ext/intl/tests/locale_get_region.phpt | 12 +- ext/intl/tests/locale_parse_locale.phpt | 143 +++++++++--------- 5 files changed, 220 insertions(+), 164 deletions(-) diff --git a/ext/intl/tests/dateformat_parse.phpt b/ext/intl/tests/dateformat_parse.phpt index b3be895e5950f..67ac42ce6aba5 100755 --- a/ext/intl/tests/dateformat_parse.phpt +++ b/ext/intl/tests/dateformat_parse.phpt @@ -2,6 +2,8 @@ datefmt_parse_code() --SKIPIF-- +--INI-- +date.timezone="America/Los_Angeles" --FILE-- --EXPECT-- -Input text :Sunday, September 18, 2039 4:06:40 PM PT ; Parsed text : 96000 ; parse_pos : 29 37 -Input text :Wednesday, December 17, 1969 6:40:00 PM PT ; Parsed text : 216000 ; parse_pos : 31 39 -Input text :Thursday, December 18, 1969 8:49:59 AM PST ; Parsed text : 208740 ; parse_pos : 30 38 -Input text :Thursday, December 18, 1969 8:49:59 PM PST ; Parsed text : 251940 ; parse_pos : 30 38 -Input text :December 18, 1969 8:49:59 AM PST ; Parsed text : 208740 ; parse_pos : 20 28 -Input text :12/18/69 8:49 AM ; Parsed text : 60540 ; parse_pos : 8 16 -Input text :19691218 08:49 AM ; Parsed text : 60540 ; parse_pos : 8 17 + +Input text : Sunday, September 18, 2039 4:06:40 PM PT ; DF = 0; TF = 0 +Parsed: 2200000000; parse_pos : 40 + +Input text : Wednesday, December 17, 1969 6:40:00 PM PT ; DF = 0; TF = 0 +Parsed: -1200000; parse_pos : 42 + +Input text : Thursday, December 18, 1969 8:49:59 PM PST ; DF = 0; TF = 0 +Parsed: -1105801; parse_pos : 42 + +Input text : December 18, 1969 8:49:59 AM PST ; DF = 1; TF = 0 +Parsed: -1149001; parse_pos : 32 + +Input text : 12/18/69 8:49 AM ; DF = 3; TF = 3 +Parsed: -1149060; parse_pos : 16 + +Input text : 19691218 08:49 AM ; DF = 3; TF = 3 +Error : Date parsing failed: U_PARSE_ERROR +Parsed: ; parse_pos : 8 + +Input text : Sunday, September 18, 2039 4:06:40 PM PT ; DF = 0; TF = -1 +Parsed: 2199942000; parse_pos : 26 + +Input text : Sunday, September 18, 2039 4:06:40 PM PT ; DF = 0; TF = 3 +Error : Date parsing failed: U_PARSE_ERROR +Parsed: ; parse_pos : 31 + +Input text : December 18, 1969 8:49:59 AM PST ; DF = 1; TF = -1 +Parsed: -1180800; parse_pos : 17 + +Input text : December 18, 1969 8:49:59 AM PST ; DF = 1; TF = 3 +Error : Date parsing failed: U_PARSE_ERROR +Parsed: ; parse_pos : 22 + +Input text : 12/18/69 8:49 AM ; DF = 3; TF = 1 +Error : Date parsing failed: U_PARSE_ERROR +Parsed: ; parse_pos : 13 + +Input text : 19691218 08:49 AM ; DF = 3; TF = 1 +Error : Date parsing failed: U_PARSE_ERROR +Parsed: ; parse_pos : 8 diff --git a/ext/intl/tests/dateformat_parse_timestamp_parsepos.phpt b/ext/intl/tests/dateformat_parse_timestamp_parsepos.phpt index b7e820388a325..040f72e47d8f2 100755 --- a/ext/intl/tests/dateformat_parse_timestamp_parsepos.phpt +++ b/ext/intl/tests/dateformat_parse_timestamp_parsepos.phpt @@ -2,6 +2,10 @@ datefmt_parse_timestamp_code() with parse pos --SKIPIF-- +--INI-- +datetime.timezone="America/Los_Angeles" +--ENV-- +TZ=America/Los_Angeles --FILE-- ---EXPECT-- +--EXPECTF-- uk-ua_CALIFORNIA@currency=;currency=GRN: region='UA' root: region='' uk@currency=EURO: region='' @@ -99,8 +99,8 @@ sr-Cyrl: region='' sr-Latn: region='' zh-Hans-CN: region='CN' sr-Latn-CS: region='CS' -sl-rozaj: region='' -sl-nedis: region='' +sl-rozaj: region='%r(ROZAJ)?%r' +sl-nedis: region='%r(NEDIS)?%r' de-CH-1901: region='CH' sl-IT-nedis: region='IT' sl-Latn-IT-nedis: region='IT' @@ -108,7 +108,7 @@ de-DE: region='DE' en-US: region='US' es-419: region='419' de-CH-x-phonebk: region='CH' -az-Arab-x-AZE-derbend: region='' +az-Arab-x-AZE-derbend: region='%r(X)?%r' zh-min: region='' zh-min-nan-Hant-CN: region='MIN' x-whatever: region='' @@ -117,7 +117,7 @@ sr-Latn-QM: region='QM' sr-Qaaa-CS: region='CS' en-US-u-islamCal: region='US' zh-CN-a-myExt-x-private: region='CN' -en-a-myExt-b-another: region='' +en-a-myExt-b-another: region='%r(A)?%r' de-419-DE: region='419' a-DE: region='DE' -ar-a-aaa-b-bbb-a-ccc: region='' +ar-a-aaa-b-bbb-a-ccc: region='%r(A)?%r' diff --git a/ext/intl/tests/locale_parse_locale.phpt b/ext/intl/tests/locale_parse_locale.phpt index e47f71830a62c..36637f0d818da 100755 --- a/ext/intl/tests/locale_parse_locale.phpt +++ b/ext/intl/tests/locale_parse_locale.phpt @@ -6,7 +6,7 @@ locale_parse_locale() $value){ $res_str .= "$key : '$value' , "; } + $res_str = rtrim($res_str); } else{ $res_str .= "No values found from Locale parsing."; @@ -93,109 +94,109 @@ include_once( 'ut_common.inc' ); ut_run(); ?> ---EXPECT-- +--EXPECTF-- --------------------- -uk-ua_CALIFORNIA@currency=;currency=GRN: -language : 'uk' , region : 'UA' , variant0 : 'CALIFORNIA' , +uk-ua_CALIFORNIA@currency=;currency=GRN: +language : 'uk' , region : 'UA' , variant0 : 'CALIFORNIA' , --------------------- -root: -language : 'root' , +root: +language : 'root' , --------------------- -uk@currency=EURO: -language : 'uk' , +uk@currency=EURO: +language : 'uk' , --------------------- -Hindi: -language : 'hindi' , +Hindi: +language : 'hindi' , --------------------- -de: -language : 'de' , +de: +language : 'de' , --------------------- -fr: -language : 'fr' , +fr: +language : 'fr' , --------------------- -ja: -language : 'ja' , +ja: +language : 'ja' , --------------------- -i-enochian: -grandfathered : 'i-enochian' , +i-enochian: +grandfathered : 'i-enochian' , --------------------- -zh-Hant: -language : 'zh' , script : 'Hant' , +zh-Hant: +language : 'zh' , script : 'Hant' , --------------------- -zh-Hans: -language : 'zh' , script : 'Hans' , +zh-Hans: +language : 'zh' , script : 'Hans' , --------------------- -sr-Cyrl: -language : 'sr' , script : 'Cyrl' , +sr-Cyrl: +language : 'sr' , script : 'Cyrl' , --------------------- -sr-Latn: -language : 'sr' , script : 'Latn' , +sr-Latn: +language : 'sr' , script : 'Latn' , --------------------- -zh-Hans-CN: -language : 'zh' , script : 'Hans' , region : 'CN' , +zh-Hans-CN: +language : 'zh' , script : 'Hans' , region : 'CN' , --------------------- -sr-Latn-CS: -language : 'sr' , script : 'Latn' , region : 'CS' , +sr-Latn-CS: +language : 'sr' , script : 'Latn' , region : 'CS' , --------------------- -sl-rozaj: -language : 'sl' , +sl-rozaj: +language : 'sl' ,%r( region : 'ROZAJ' ,)?%r --------------------- -sl-nedis: -language : 'sl' , +sl-nedis: +language : 'sl' ,%r( region : 'NEDIS' ,)?%r --------------------- -de-CH-1901: -language : 'de' , region : 'CH' , variant0 : '1901' , +de-CH-1901: +language : 'de' , region : 'CH' , variant0 : '1901' , --------------------- -sl-IT-nedis: -language : 'sl' , region : 'IT' , variant0 : 'NEDIS' , +sl-IT-nedis: +language : 'sl' , region : 'IT' , variant0 : 'NEDIS' , --------------------- -sl-Latn-IT-nedis: -language : 'sl' , script : 'Latn' , region : 'IT' , variant0 : 'NEDIS' , +sl-Latn-IT-nedis: +language : 'sl' , script : 'Latn' , region : 'IT' , variant0 : 'NEDIS' , --------------------- -de-DE: -language : 'de' , region : 'DE' , +de-DE: +language : 'de' , region : 'DE' , --------------------- -en-US: -language : 'en' , region : 'US' , +en-US: +language : 'en' , region : 'US' , --------------------- -es-419: -language : 'es' , region : '419' , +es-419: +language : 'es' , region : '419' , --------------------- -de-CH-x-phonebk: -language : 'de' , region : 'CH' , private0 : 'phonebk' , +de-CH-x-phonebk: +language : 'de' , region : 'CH' , private0 : 'phonebk' , --------------------- -az-Arab-x-AZE-derbend: -language : 'az' , script : 'Arab' , private0 : 'AZE' , private1 : 'derbend' , +az-Arab-x-AZE-derbend: +language : 'az' , script : 'Arab' , private0 : 'AZE' , private1 : 'derbend' , --------------------- -zh-min: -grandfathered : 'zh-min' , +zh-min: +grandfathered : 'zh-min' , --------------------- -zh-min-nan-Hant-CN: -language : 'zh' , region : 'MIN' , variant0 : 'NAN' , variant1 : 'HANT' , variant2 : 'CN' , +zh-min-nan-Hant-CN: +language : 'zh' , region : 'MIN' , variant0 : 'NAN' , variant1 : 'HANT' , variant2 : 'CN' , --------------------- -qaa-Qaaa-QM-x-southern: -language : 'qaa' , script : 'Qaaa' , region : 'QM' , private0 : 'southern' , +qaa-Qaaa-QM-x-southern: +language : 'qaa' , script : 'Qaaa' , region : 'QM' , private0 : 'southern' , --------------------- -sr-Latn-QM: -language : 'sr' , script : 'Latn' , region : 'QM' , +sr-Latn-QM: +language : 'sr' , script : 'Latn' , region : 'QM' , --------------------- -sr-Qaaa-CS: -language : 'sr' , script : 'Qaaa' , region : 'CS' , +sr-Qaaa-CS: +language : 'sr' , script : 'Qaaa' , region : 'CS' , --------------------- -en-US-u-islamCal: -language : 'en' , region : 'US' , +en-US-u-islamCal: +language : 'en' , region : 'US' , --------------------- -zh-CN-a-myExt-x-private: -language : 'zh' , region : 'CN' , private0 : 'private' , +zh-CN-a-myExt-x-private: +language : 'zh' , region : 'CN' , private0 : 'private' , --------------------- -en-a-myExt-b-another: -language : 'en' , +en-a-myExt-b-another: +language : 'en' , --------------------- -de-419-DE: -language : 'de' , region : '419' , variant0 : 'DE' , +de-419-DE: +language : 'de' , region : '419' , variant0 : 'DE' , --------------------- -a-DE: +a-DE: No values found from Locale parsing. --------------------- -ar-a-aaa-b-bbb-a-ccc: +ar-a-aaa-b-bbb-a-ccc: language : 'ar' , From 72d0abc8d3b74fc67f91984ebf3fabd3ebce1be5 Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Mon, 5 Sep 2011 08:27:47 +0000 Subject: [PATCH 0755/2394] Revert r316043, the tests are different on purpose --- .../xsltprocessor_registerPHPFunctions-funcnostring.phpt | 7 ------- .../xsltprocessor_registerPHPFunctions-funcundef.phpt | 7 ------- 2 files changed, 14 deletions(-) diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt index d5d99f92245d6..90d9c68208c2d 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcnostring.phpt @@ -21,17 +21,10 @@ if(!$phpfuncxsl) { $proc->importStylesheet($phpfuncxsl); var_dump($proc->registerPHPFunctions()); var_dump($proc->transformToXml($dom)); -?> --EXPECTF-- NULL Warning: XSLTProcessor::transformToXml(): Handler name must be a string in %s on line %d - -Warning: XSLTProcessor::transformToXml(): xmlXPathCompiledEval: evaluation failed in %s on line %d - -Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element value-of in %s on line %d - -Warning: XSLTProcessor::transformToXml(): XPath evaluation returned no result. in %s on line %d NULL --CREDITS-- Christian Weiske, cweiske@php.net diff --git a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt index a91e6459dba9a..a26c2103331dd 100644 --- a/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt +++ b/ext/xsl/tests/xsltprocessor_registerPHPFunctions-funcundef.phpt @@ -20,17 +20,10 @@ if(!$phpfuncxsl) { $proc->importStylesheet($phpfuncxsl); var_dump($proc->registerPHPFunctions()); var_dump($proc->transformToXml($dom)); -?> --EXPECTF-- NULL Warning: XSLTProcessor::transformToXml(): Unable to call handler undefinedfunc() in %s on line %d - -Warning: XSLTProcessor::transformToXml(): xmlXPathCompiledEval: evaluation failed in %s on line %d - -Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element value-of in %s on line %d - -Warning: XSLTProcessor::transformToXml(): XPath evaluation returned no result. in %s on line %d NULL --CREDITS-- Christian Weiske, cweiske@php.net From 8db93019b43164fdcaa30bed42949a5f25de6579 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 5 Sep 2011 09:27:23 +0000 Subject: [PATCH 0756/2394] Not all submodules have MINIT, but they have MINFO and need to be registered (cought by tyrael@) --- ext/standard/basic_functions.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 090364584d5c2..d5f2261e30570 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -3521,8 +3521,11 @@ PHPAPI double php_get_inf(void) /* {{{ */ #define BASIC_MINIT_SUBMODULE(module) \ if (PHP_MINIT(module)(INIT_FUNC_ARGS_PASSTHRU) == SUCCESS) {\ - zend_hash_add_empty_element(&basic_submodules, #module, strlen(#module)); \ + BASIC_ADD_SUBMODULE($module); \ } + +#define BASIC_ADD_SUBMODULE(module) \ + zend_hash_add_empty_element(&basic_submodules, #module, strlen(#module)); #define BASIC_RINIT_SUBMODULE(module) \ if (zend_hash_exists(&basic_submodules, #module, strlen(#module))) { \ @@ -3619,6 +3622,8 @@ PHP_MINIT_FUNCTION(basic) /* {{{ */ register_html_constants(INIT_FUNC_ARGS_PASSTHRU); register_string_constants(INIT_FUNC_ARGS_PASSTHRU); + BASIC_ADD_SUBMODULE(dl) + BASIC_ADD_SUBMODULE(mail) BASIC_MINIT_SUBMODULE(file) BASIC_MINIT_SUBMODULE(pack) BASIC_MINIT_SUBMODULE(browscap) From 22c4ca480f36beb15a178016b5cf117c1f1af205 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 5 Sep 2011 09:34:14 +0000 Subject: [PATCH 0757/2394] Interesting typo... --- ext/standard/basic_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index d5f2261e30570..9b704f1838b07 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -3521,7 +3521,7 @@ PHPAPI double php_get_inf(void) /* {{{ */ #define BASIC_MINIT_SUBMODULE(module) \ if (PHP_MINIT(module)(INIT_FUNC_ARGS_PASSTHRU) == SUCCESS) {\ - BASIC_ADD_SUBMODULE($module); \ + BASIC_ADD_SUBMODULE(module); \ } #define BASIC_ADD_SUBMODULE(module) \ From 69a1e5d3acc7ecbbe8746e339edae4e8b71ae2fe Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 10:14:13 +0000 Subject: [PATCH 0758/2394] - fix test --- ext/standard/tests/file/rename_variation7-win32.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/standard/tests/file/rename_variation7-win32.phpt b/ext/standard/tests/file/rename_variation7-win32.phpt index 7bef31f22f10c..369e8c2d43b28 100644 --- a/ext/standard/tests/file/rename_variation7-win32.phpt +++ b/ext/standard/tests/file/rename_variation7-win32.phpt @@ -26,11 +26,11 @@ var_dump(readlink($tmp_link2)); echo "Done\n"; ?> --EXPECTF-- -Warning: symlink(): Could not fetch file information(error 2) in %s on line %d +Warning: symlink(): Could not fetch file information(error 2) in %srename_variation7-win32.php on line %d -Warning: readlink(): Could not open file (error 2) in %s on line %d +Warning: readlink(): readlink failed to read the symbolic link (%srename_variation7-win32.php.tmp.link), error 2) in %srename_variation7-win32.php on line %d bool(false) -Warning: readlink(): Could not open file (error 2) in %s on line %d +Warning: readlink(): readlink failed to read the symbolic link (%srename_variation7-win32.php.tmp.link2), error 2) in %srename_variation7-win32.php on line %d bool(false) Done From 2ecaee20e9b595c7b7b20d6f7724df25f21a6ed5 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 10:29:12 +0000 Subject: [PATCH 0759/2394] - update test to the zeng arg path argument --- .../file_put_contents_variation8-win32.phpt | 6 +-- .../tests/file/glob_variation-win32.phpt | 37 ++++++++++-------- .../file/readfile_variation10-win32.phpt | 6 +-- .../tests/file/rename_variation13-win32.phpt | Bin 3947 -> 4094 bytes ext/standard/tests/file/stat_error-win32.phpt | 2 +- .../tests/file/tempnam_variation7-win32.phpt | 12 +++--- 6 files changed, 35 insertions(+), 28 deletions(-) diff --git a/ext/standard/tests/file/file_put_contents_variation8-win32.phpt b/ext/standard/tests/file/file_put_contents_variation8-win32.phpt index 1609b10e122fd..92fe7b3d6af6f 100644 --- a/ext/standard/tests/file/file_put_contents_variation8-win32.phpt +++ b/ext/standard/tests/file/file_put_contents_variation8-win32.phpt @@ -78,12 +78,12 @@ Failed to write data to: " " -- Filename: \0 -- -Warning: file_put_contents(): Filename cannot be empty in %s on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %s on line %d Failed to write data to: \0 -- Filename: array() -- -Warning: file_put_contents() expects parameter 1 to be string, array given in %s on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, array given in %s on line %d Failed to write data to: array() -- Filename: /no/such/file/dir -- @@ -95,4 +95,4 @@ Failed to write data to: /no/such/file/dir Warning: file_put_contents(php/php): failed to open stream: %s in %s on line %d Failed to write data to: php/php -===Done=== \ No newline at end of file +===Done=== diff --git a/ext/standard/tests/file/glob_variation-win32.phpt b/ext/standard/tests/file/glob_variation-win32.phpt index f3a3ff0e81289..5027ac03e634d 100644 --- a/ext/standard/tests/file/glob_variation-win32.phpt +++ b/ext/standard/tests/file/glob_variation-win32.phpt @@ -325,20 +325,24 @@ array(0) { } -- Iteration 8 -- -array(0) { -} -array(0) { -} -array(0) { -} -array(1) { - [0]=> - string(%d) "%s/glob_variation/WONDER5" -} -array(0) { -} -array(0) { -} + +Warning: glob() expects parameter 1 to be a valid path, string given %sglob_variation-win32.php on line %d +NULL + +Warning: glob() expects parameter 1 to be a valid path, string given %sglob_variation-win32.php on line %d +NULL + +Warning: glob() expects parameter 1 to be a valid path, string given %sglob_variation-win32.php on line %d +NULL + +Warning: glob() expects parameter 1 to be a valid path, string given %sglob_variation-win32.php on line %d +NULL + +Warning: glob() expects parameter 1 to be a valid path, string given %sglob_variation-win32.php on line %d +NULL + +Warning: glob() expects parameter 1 to be a valid path, string given %sglob_variation-win32.php on line %d +NULL -- Iteration 9 -- array(0) { @@ -441,8 +445,9 @@ array(1) { array(0) { } -- Iteration 8 -- -array(0) { -} + +Warning: glob() expects parameter 1 to be a valid path, string given in %sglob_variation-win32.php on line %d +NULL -- Iteration 9 -- array(0) { } diff --git a/ext/standard/tests/file/readfile_variation10-win32.phpt b/ext/standard/tests/file/readfile_variation10-win32.phpt index 6453b9808d381..61f6aba7a5ecb 100644 --- a/ext/standard/tests/file/readfile_variation10-win32.phpt +++ b/ext/standard/tests/file/readfile_variation10-win32.phpt @@ -71,11 +71,11 @@ Warning: readfile( ): failed to open stream: Permission denied in %s on line %d -- Filename: \0 -- -Warning: readfile(): Filename cannot be empty in %s on line %d +Warning: readfile() expects parameter 1 to be a valid path, string given in %s on line %d -- Filename: array() -- -Warning: readfile() expects parameter 1 to be string, array given in %s on line %d +Warning: readfile() expects parameter 1 to be a valid path, array given in %s on line %d -- Filename: /no/such/file/dir -- @@ -84,4 +84,4 @@ Warning: readfile(/no/such/file/dir): failed to open stream: No such file or dir -- Filename: php/php -- Warning: readfile(php/php): failed to open stream: No such file or directory in %s on line %d -===Done=== \ No newline at end of file +===Done=== diff --git a/ext/standard/tests/file/rename_variation13-win32.phpt b/ext/standard/tests/file/rename_variation13-win32.phpt index a86025889d31bedfad6b7214ff98c1a4cd9dcd62..c0388fd300ce5f88e81e58680942ac1eed3edeed 100644 GIT binary patch delta 158 zcmaDY_fLKU5BKDY+`1x(3T25onJEedi6t323dJQwnR)4x5Adi=*5@(8B`GnvjR&Vr g^~u|~J$R6foxGDr8)O{1pghPJ6v53qc{VWt0AUL^tpET3 delta 71 zcmew-|5|PX4>u#jH!%SKbLJS3 diff --git a/ext/standard/tests/file/stat_error-win32.phpt b/ext/standard/tests/file/stat_error-win32.phpt index c15ef58dd81b7..1b69da8bf5be4 100644 --- a/ext/standard/tests/file/stat_error-win32.phpt +++ b/ext/standard/tests/file/stat_error-win32.phpt @@ -49,7 +49,7 @@ bool(false) Warning: stat(): stat failed for 22 in %s on line %d bool(false) -Warning: stat() expects parameter 1 to be string, array given in %s on line %d +Warning: stat() expects parameter 1 to be a valid path, array given in %s on line %d NULL Done diff --git a/ext/standard/tests/file/tempnam_variation7-win32.phpt b/ext/standard/tests/file/tempnam_variation7-win32.phpt index 34e352a497bfe..2572f65d02de8 100644 --- a/ext/standard/tests/file/tempnam_variation7-win32.phpt +++ b/ext/standard/tests/file/tempnam_variation7-win32.phpt @@ -89,15 +89,17 @@ File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 6 -- -File name is => %s%et%s -File permissions are => 100666 -File created in => temp dir + +Warning: tempnam() expects parameter 1 to be a valid path, string given in %stempnam_variation7-win32.php on line %d +-- File is not created -- + +Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 7 -- -Warning: tempnam() expects parameter 1 to be string, array given in %s on line %d +Warning: tempnam() expects parameter 1 to be a valid path, array given in %s on line %d -- File is not created -- -Warning: unlink(): %s in %s on line %d +Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 8 -- File name is => %s%et%s File permissions are => 100666 From 5f7bbebd8e503e5804f84537a5f89437268ca059 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 5 Sep 2011 10:30:41 +0000 Subject: [PATCH 0760/2394] Fix test, one skipif is enough --- ext/date/tests/bug13142.phpt | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/date/tests/bug13142.phpt b/ext/date/tests/bug13142.phpt index dc02f68dad748..5254142baac68 100644 --- a/ext/date/tests/bug13142.phpt +++ b/ext/date/tests/bug13142.phpt @@ -7,8 +7,6 @@ date.timezone=US/Eastern if (defined('PHP_WINDOWS_VERSION_MAJOR')) { die("skip. set TZ env is not supported at runtime."); } ---SKIPIF-- - Date: Mon, 5 Sep 2011 10:52:01 +0000 Subject: [PATCH 0761/2394] - force LF From 3986046b6e2790ed4990be3567461a955966feb1 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 5 Sep 2011 10:55:07 +0000 Subject: [PATCH 0762/2394] Fix test to use microtime() as time() doesn't always catchup fast enough :] --- ext/standard/tests/misc/time_sleep_until_basic.phpt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ext/standard/tests/misc/time_sleep_until_basic.phpt b/ext/standard/tests/misc/time_sleep_until_basic.phpt index 956985a62a372..165526f0649f2 100644 --- a/ext/standard/tests/misc/time_sleep_until_basic.phpt +++ b/ext/standard/tests/misc/time_sleep_until_basic.phpt @@ -8,9 +8,10 @@ Michele Orselli mo@ideato.it #PHPTestFest Cesena Italia on 2009-06-20 --FILE-- = $time ); + $time = microtime(true) + 2; + var_dump(time_sleep_until( (int)$time )); + var_dump(microtime(true) >= (int)$time); ?> --EXPECT-- bool(true) +bool(true); From 372976e2aa8dccc4d74a635f334e27eebcc4eb18 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 10:59:26 +0000 Subject: [PATCH 0763/2394] - force LF and enable it on windows now From d1e7999d5baa93fd2c67300de6d3cd52763718b3 Mon Sep 17 00:00:00 2001 From: Shein Alexey Date: Mon, 5 Sep 2011 11:00:14 +0000 Subject: [PATCH 0764/2394] Make the test faster, what was done: 1) replaced multiple htmlentities calls with one call to get_html_translation table since they share the same code internally 2) reduced the upper range of the "for" loop to 0x2710 (10000), according to http://www.w3.org/TR/html4/sgml/entities.html it's enough 3) placed additional check to make sure all entities from get_html_translation_table were checked in the test --- .../tests/strings/htmlentities_html4.phpt | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/ext/standard/tests/strings/htmlentities_html4.phpt b/ext/standard/tests/strings/htmlentities_html4.phpt index d7bff707fdb45..22b0305ced162 100644 --- a/ext/standard/tests/strings/htmlentities_html4.phpt +++ b/ext/standard/tests/strings/htmlentities_html4.phpt @@ -1,9 +1,5 @@ --TEST-- htmlentities() conformance check (HTML 4) ---SKIPIF-- - --FILE-- = 0xd800 && $i < 0xe000) continue; $str = utf32_utf8($i); - $result = htmlentities($str, ENT_QUOTES, 'UTF-8'); - if ($str != $result) { - printf("%s\tU+%05X\n", $result, $i); - } + if (isset($table[$str])) { + printf("%s\tU+%05X\n", $table[$str], $i); + unset($table[$str]); + } } + +if (!empty($table)) { + echo "Not matched entities: "; + var_dump($table); +} + ?> --EXPECT-- " U+00022 From 42ca18e853f511d40223a2d1d55dcf15b48dc2bc Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 11:00:52 +0000 Subject: [PATCH 0765/2394] - not used anymore, one version to rule them all --- .../parse_ini_file-win32.phpt | 196 ------------------ 1 file changed, 196 deletions(-) delete mode 100644 ext/standard/tests/general_functions/parse_ini_file-win32.phpt diff --git a/ext/standard/tests/general_functions/parse_ini_file-win32.phpt b/ext/standard/tests/general_functions/parse_ini_file-win32.phpt deleted file mode 100644 index 7a1d63010d90c..0000000000000 --- a/ext/standard/tests/general_functions/parse_ini_file-win32.phpt +++ /dev/null @@ -1,196 +0,0 @@ ---TEST-- -parse_ini_file() multiple calls ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -Warning: parse_ini_file() expects at least 1 parameter, 0 given in %s on line 6 -bool(false) - -Warning: parse_ini_file() expects at most 3 parameters, 4 given in %s on line 7 -bool(false) - -Warning: parse_ini_file(%sparse_ini_file.dat): failed to open stream: No such file or directory in %s.php on line 8 -bool(false) - -Warning: parse_ini_file(%sparse_ini_file.dat): failed to open stream: No such file or directory in %s.php on line 9 -bool(false) -array(1) { - ["test"]=> - string(0) "" -} - -Warning: parse error in %s on line %d - in %s on line 20 -bool(false) - -Warning: parse error in %s on line %d - in %s on line 26 -bool(false) -array(1) { - ["test"]=> - string(8) "new -line" -} -array(1) { - ["test"]=> - string(16) "test const value" -} -array(1) { - ["section"]=> - array(1) { - ["test"]=> - string(5) "hello" - } -} -array(1) { - ["test"]=> - string(5) "hello" -} -array(1) { - ["section.test"]=> - string(5) "hello" -} -array(1) { - ["section"]=> - array(1) { - ["section.test"]=> - string(5) "hello" - } -} -array(1) { - ["section"]=> - array(1) { - [1]=> - string(1) "2" - } -} -array(1) { - [1]=> - string(1) "2" -} -array(1) { - ["test"]=> - string(5) "test4" -} -array(1) { - ["section1"]=> - array(1) { - ["name"]=> - string(5) "value" - } -} -array(3) { - ["foo"]=> - string(4) "bar1" - ["_foo"]=> - string(4) "bar2" - ["foo_"]=> - string(4) "bar3" -} -Done From e1ec448fe6cfb16b662e84b8e3a34954ea4c8123 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 5 Sep 2011 11:07:38 +0000 Subject: [PATCH 0766/2394] Fix the test in 5.4 and trunk. older libraries will emmit error here, while new won't. So lets just suppress it rather then making the test uselessly fail for random people. --- ext/iconv/tests/iconv_stream_filter.phpt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ext/iconv/tests/iconv_stream_filter.phpt b/ext/iconv/tests/iconv_stream_filter.phpt index 003c631846938..79f6ad5179940 100644 --- a/ext/iconv/tests/iconv_stream_filter.phpt +++ b/ext/iconv/tests/iconv_stream_filter.phpt @@ -22,7 +22,7 @@ fclose($fp); $fp = fopen(dirname(__FILE__).'/iconv_stream_filter.txt', 'rb'); stream_filter_append($fp, 'string.rot13'); // this will make conversion fail. stream_filter_append($fp, 'convert.iconv.ISO-2022-JP/EUC-JP'); -var_dump(bin2hex(fread($fp, 10)) != "a4b3a4f3a4cba4c1a4cf"); +var_dump(bin2hex(@fread($fp, 10)) != "a4b3a4f3a4cba4c1a4cf"); var_dump(bin2hex(fread($fp, 5)) != "69636f6e76"); var_dump(bin2hex(fread($fp, 1)) != "0a"); fclose($fp); @@ -34,8 +34,6 @@ string(2) "42" string(20) "a4b3a4f3a4cba4c1a4cf" string(10) "69636f6e76" string(2) "0a" - -Warning: fread(): iconv stream filter ("ISO-2022-JP"=>"EUC-JP"): invalid multibyte sequence in %s on line %d bool(true) bool(true) bool(true) From e2e8be545f2ccb096c87a4ead79825e49f5eabd2 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 11:46:05 +0000 Subject: [PATCH 0767/2394] - force LF From 81542639562e08499753fe91de2f7df9a426a301 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 5 Sep 2011 12:00:24 +0000 Subject: [PATCH 0768/2394] typo --- ext/standard/tests/misc/time_sleep_until_basic.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/misc/time_sleep_until_basic.phpt b/ext/standard/tests/misc/time_sleep_until_basic.phpt index 165526f0649f2..b9b359fab1592 100644 --- a/ext/standard/tests/misc/time_sleep_until_basic.phpt +++ b/ext/standard/tests/misc/time_sleep_until_basic.phpt @@ -14,4 +14,4 @@ Michele Orselli mo@ideato.it ?> --EXPECT-- bool(true) -bool(true); +bool(true) From 997a86ebb9918019572153bfefaeeaf517d94419 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 12:34:55 +0000 Subject: [PATCH 0769/2394] - other hostname can be defined or returned first --- ext/standard/tests/network/gethostbyaddr_basic1.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/tests/network/gethostbyaddr_basic1.phpt b/ext/standard/tests/network/gethostbyaddr_basic1.phpt index 2232d36265ca1..a20b4756c152d 100644 --- a/ext/standard/tests/network/gethostbyaddr_basic1.phpt +++ b/ext/standard/tests/network/gethostbyaddr_basic1.phpt @@ -14,5 +14,5 @@ echo gethostbyaddr("127.0.0.1")."\n"; ===DONE=== --EXPECTF-- *** Testing gethostbyaddr() : basic functionality *** -%rloopback|localhost(\.localdomain)?%r -===DONE=== \ No newline at end of file +%rloopback|localhost(\.localdomain)?|%s%r +===DONE=== From 5dc49bebaac00410dfb4ea6d6e3d099eeddfbced Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 13:04:12 +0000 Subject: [PATCH 0770/2394] - disable on win --- ext/standard/tests/network/ip2long_variation1.phpt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/standard/tests/network/ip2long_variation1.phpt b/ext/standard/tests/network/ip2long_variation1.phpt index ac3c9c81e19ec..3516beb0e8a69 100644 --- a/ext/standard/tests/network/ip2long_variation1.phpt +++ b/ext/standard/tests/network/ip2long_variation1.phpt @@ -1,5 +1,9 @@ --TEST-- Test ip2long() function : usage variation + --FILE-- Date: Mon, 5 Sep 2011 13:05:15 +0000 Subject: [PATCH 0771/2394] Fix #ifdef for mixed builds (ext/mysql using myslqnd, mysqli using libmysql) --- ext/mysqli/mysqli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index e5f3907ddc8ec..f0538617ff98e 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -838,7 +838,7 @@ PHP_MINIT_FUNCTION(mysqli) #endif -#ifdef MYSQL_USE_MYSQLND +#ifdef MYSQLI_USE_MYSQLND mysqlnd_register_api_extension(&mysqli_api_ext); #endif From ff0f1457681d37ee6c22886c08c1caa5b90ecdb4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 13:05:28 +0000 Subject: [PATCH 0772/2394] - disable on win --- ext/standard/tests/network/ip2long_variation1.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/standard/tests/network/ip2long_variation1.phpt b/ext/standard/tests/network/ip2long_variation1.phpt index 3516beb0e8a69..668b2ee9078b9 100644 --- a/ext/standard/tests/network/ip2long_variation1.phpt +++ b/ext/standard/tests/network/ip2long_variation1.phpt @@ -1,5 +1,6 @@ --TEST-- Test ip2long() function : usage variation +--SKIPIF-- Date: Mon, 5 Sep 2011 13:06:51 +0000 Subject: [PATCH 0773/2394] - stupid me. --- ext/standard/tests/network/ip2long_variation1.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/network/ip2long_variation1.phpt b/ext/standard/tests/network/ip2long_variation1.phpt index 668b2ee9078b9..ca67aa41a8e24 100644 --- a/ext/standard/tests/network/ip2long_variation1.phpt +++ b/ext/standard/tests/network/ip2long_variation1.phpt @@ -3,7 +3,7 @@ Test ip2long() function : usage variation --SKIPIF-- --FILE-- Date: Mon, 5 Sep 2011 13:13:37 +0000 Subject: [PATCH 0774/2394] - fix test, slash or back slash can be present --- ext/standard/tests/php_ini_loaded_file.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/php_ini_loaded_file.phpt b/ext/standard/tests/php_ini_loaded_file.phpt index 7958eb1274b27..6f4b7fe68a505 100644 --- a/ext/standard/tests/php_ini_loaded_file.phpt +++ b/ext/standard/tests/php_ini_loaded_file.phpt @@ -11,4 +11,4 @@ precision=12 var_dump(php_ini_loaded_file()); ?> --EXPECTF-- -string(%d) "%s/tmp-php.ini" +string(%d) "%stmp-php.ini" From 7947df24afa25e1fa32f941a788efb08f1b71b48 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 13:23:25 +0000 Subject: [PATCH 0775/2394] - sync&fix test with 5.3 --- ext/standard/tests/streams/bug54623.phpt | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/standard/tests/streams/bug54623.phpt b/ext/standard/tests/streams/bug54623.phpt index 63e907a5af2b4..cd83854f43222 100644 --- a/ext/standard/tests/streams/bug54623.phpt +++ b/ext/standard/tests/streams/bug54623.phpt @@ -14,6 +14,4 @@ fwrite($sock, "3"); int(%d) int(%d) -Notice: fwrite(): send of 1 bytes failed with errno=61 Connection refused in %s on line %d - Warning: fwrite(): %d is not a valid stream resource in %s on line %d From a2b6e6a3643a57e987a51b13cd0bc999ae366576 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 13:31:13 +0000 Subject: [PATCH 0776/2394] - close the stream before removing the file (win and other system may lock it) and use test dir for tmp data --- ext/standard/tests/streams/bug54946.phpt | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/ext/standard/tests/streams/bug54946.phpt b/ext/standard/tests/streams/bug54946.phpt index b3fa73df5ce23..b51d593a939d0 100644 --- a/ext/standard/tests/streams/bug54946.phpt +++ b/ext/standard/tests/streams/bug54946.phpt @@ -2,33 +2,32 @@ Bug#54946 stream_get_contents infinite loop --FILE-- ===DONE=== From fdf97717734dcacdfac8c4725336604199f72818 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 13:37:30 +0000 Subject: [PATCH 0777/2394] - use the same test on win --- ext/standard/tests/strings/006-win32.phpt | 23 ----------------------- ext/standard/tests/strings/006.phpt | 2 -- 2 files changed, 25 deletions(-) delete mode 100644 ext/standard/tests/strings/006-win32.phpt diff --git a/ext/standard/tests/strings/006-win32.phpt b/ext/standard/tests/strings/006-win32.phpt deleted file mode 100644 index b78fc1adaa990..0000000000000 --- a/ext/standard/tests/strings/006-win32.phpt +++ /dev/null @@ -1,23 +0,0 @@ ---TEST-- -highlight_file() and output buffer ---SKIPIF-- - ---INI-- -log_errors_max_len=4096 ---FILE-- - -===DONE=== ---EXPECTF-- -Warning: highlight_file(AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA): failed to open stream: No such file or directory in %s on line %d - -Warning: highlight_file(): Failed opening 'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA' for highlighting in %s on line %d -bool(false) -bool(false) -===DONE=== diff --git a/ext/standard/tests/strings/006.phpt b/ext/standard/tests/strings/006.phpt index fdfd58c027703..afb5d24dbf300 100644 --- a/ext/standard/tests/strings/006.phpt +++ b/ext/standard/tests/strings/006.phpt @@ -1,7 +1,5 @@ --TEST-- highlight_file() and output buffer ---SKIPIF-- - --INI-- log_errors_max_len=4096 --FILE-- From ad723096360a0f4ed805f3ffbfbbef5c7d5ab205 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 13:41:01 +0000 Subject: [PATCH 0778/2394] - add skipif --- ext/wddx/tests/bug48562.phpt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ext/wddx/tests/bug48562.phpt b/ext/wddx/tests/bug48562.phpt index d9ae376c56764..ebd2004e0a201 100644 --- a/ext/wddx/tests/bug48562.phpt +++ b/ext/wddx/tests/bug48562.phpt @@ -1,5 +1,11 @@ --TEST-- Bug #48562 (Reference recursion causes segfault when used in wddx_serialize_vars()) +--SKIPIF-- + --FILE-- Date: Mon, 5 Sep 2011 13:52:24 +0000 Subject: [PATCH 0779/2394] - add skipif --- ext/wddx/tests/bug52468.phpt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ext/wddx/tests/bug52468.phpt b/ext/wddx/tests/bug52468.phpt index 151c2363968a0..b0d8eb329d033 100644 --- a/ext/wddx/tests/bug52468.phpt +++ b/ext/wddx/tests/bug52468.phpt @@ -1,5 +1,11 @@ --TEST-- Bug #52468 (wddx_deserialize corrupts integer field value when left empty) +--SKIPIF-- + --FILE-- Date: Mon, 5 Sep 2011 14:43:08 +0000 Subject: [PATCH 0780/2394] Reduced timeout in this test to 1ms, no need to wait further. --- ext/standard/tests/file/fread_socket_variation1.phpt | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/ext/standard/tests/file/fread_socket_variation1.phpt b/ext/standard/tests/file/fread_socket_variation1.phpt index 50ee79bbf9ff3..a615d2f414c5c 100644 --- a/ext/standard/tests/file/fread_socket_variation1.phpt +++ b/ext/standard/tests/file/fread_socket_variation1.phpt @@ -1,15 +1,11 @@ --TEST-- Testing fread() on a TCP server socket ---SKIPIF-- - --FILE-- Date: Mon, 5 Sep 2011 15:02:21 +0000 Subject: [PATCH 0781/2394] Fixed compiler warning "incompatible pointer type" --- ext/filter/sanitizing_filters.c | 3 ++- ext/mysqlnd/mysqlnd_bt.c | 2 +- ext/pdo/pdo.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ext/filter/sanitizing_filters.c b/ext/filter/sanitizing_filters.c index b0348dbef56b6..dba4251b06cbc 100644 --- a/ext/filter/sanitizing_filters.c +++ b/ext/filter/sanitizing_filters.c @@ -250,7 +250,8 @@ void php_filter_special_chars(PHP_INPUT_FILTER_PARAM_DECL) void php_filter_full_special_chars(PHP_INPUT_FILTER_PARAM_DECL) { char *buf; - int len, quotes; + size_t len; + int quotes; if (!(flags & FILTER_FLAG_NO_ENCODE_QUOTES)) { quotes = ENT_QUOTES; diff --git a/ext/mysqlnd/mysqlnd_bt.c b/ext/mysqlnd/mysqlnd_bt.c index 536782063da05..dfc12be8f23b4 100644 --- a/ext/mysqlnd/mysqlnd_bt.c +++ b/ext/mysqlnd/mysqlnd_bt.c @@ -373,7 +373,7 @@ static int mysqlnd_build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list TRACE_APPEND_STR("Object("); - dupl = zend_get_object_classname(*arg, &class_name, &class_name_len TSRMLS_CC); + dupl = zend_get_object_classname(*arg, (const char **)&class_name, &class_name_len TSRMLS_CC); TRACE_APPEND_STRL(class_name, class_name_len); if (!dupl) { diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c index b654fea639948..8a634f2b1e962 100755 --- a/ext/pdo/pdo.c +++ b/ext/pdo/pdo.c @@ -277,7 +277,7 @@ PDO_API int php_pdo_parse_data_source(const char *data_source, parsed[j].optval = estrndup(data_source + valstart, semi - valstart - n_semicolumns); } else { int vlen = semi - valstart; - char *orig_val = data_source + valstart; + const char *orig_val = data_source + valstart; char *new_val = (char *) emalloc(vlen - n_semicolumns + 1); parsed[j].optval = new_val; From 67872cf7a90828e9424c2cca7271715e6c710339 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 5 Sep 2011 15:05:51 +0000 Subject: [PATCH 0782/2394] Fixed tests (due to error message changed) --- ext/phar/tests/fatal_error_webphar.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/phar/tests/fatal_error_webphar.phpt b/ext/phar/tests/fatal_error_webphar.phpt index 9d0970d17833c..84f94dc74ef76 100644 --- a/ext/phar/tests/fatal_error_webphar.phpt +++ b/ext/phar/tests/fatal_error_webphar.phpt @@ -15,4 +15,4 @@ Content-type: text/html; charset=UTF-8 --EXPECTF-- string(9) "\Web\View" -Parse error: syntax error, unexpected 'echo' (T_ECHO), expecting function (T_FUNCTION) in phar:///%sfatal_error_webphar.php/Web/View.php on line 380 +Parse error: syntax error, unexpected "echo (T_ECHO)", expecting "function (T_FUNCTION)" in phar:///%sfatal_error_webphar.php/Web/View.php on line 380 From 4325a8bffcf6768297a8fa186bbace4f879ba951 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Mon, 5 Sep 2011 15:29:45 +0000 Subject: [PATCH 0783/2394] Fix for Bug #55582 mysqli_num_rows() returns always 0 for unbuffered, when mysqlnd is used --- ext/mysqli/mysqli_api.c | 2 +- ext/mysqli/mysqli_libmysql.h | 1 + ext/mysqli/mysqli_mysqlnd.h | 1 + ext/mysqli/mysqli_result_iterator.c | 2 +- ext/mysqli/tests/bug55582.phpt | 41 +++++++++++++++++++++++++++++ ext/mysqlnd/mysqlnd_result.c | 5 ++-- 6 files changed, 47 insertions(+), 5 deletions(-) create mode 100644 ext/mysqli/tests/bug55582.phpt diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index 041875480cd4c..e20d963fbb496 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -1612,7 +1612,7 @@ PHP_FUNCTION(mysqli_num_rows) } MYSQLI_FETCH_RESOURCE(result, MYSQL_RES *, &mysql_result, "mysqli_result", MYSQLI_STATUS_VALID); - if (mysqli_result_is_unbuffered(result)) { + if (mysqli_result_is_unbuffered_and_not_everything_is_fetched(result)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Function cannot be used with MYSQL_USE_RESULT"); RETURN_LONG(0); } diff --git a/ext/mysqli/mysqli_libmysql.h b/ext/mysqli/mysqli_libmysql.h index 3ec06cdd0829f..98e18fcfcda4e 100644 --- a/ext/mysqli/mysqli_libmysql.h +++ b/ext/mysqli/mysqli_libmysql.h @@ -30,6 +30,7 @@ /* r->data should be always NULL, at least in recent libmysql versions, the status changes once data is read*/ #define mysqli_result_is_unbuffered(r) (((r)->handle && (r)->handle->status == MYSQL_STATUS_USE_RESULT) || ((r)->data == NULL)) +#define mysqli_result_is_unbuffered_and_not_everything_is_fetched(r) (((r)->handle && (r)->handle->status == MYSQL_STATUS_USE_RESULT) || ((r)->data == NULL)) #define mysqli_server_status(c) (c)->server_status #define mysqli_stmt_get_id(s) ((s)->stmt_id) #define mysqli_stmt_warning_count(s) mysql_warning_count((s)->mysql) diff --git a/ext/mysqli/mysqli_mysqlnd.h b/ext/mysqli/mysqli_mysqlnd.h index e4e06daeaa040..de10bb83ca429 100644 --- a/ext/mysqli/mysqli_mysqlnd.h +++ b/ext/mysqli/mysqli_mysqlnd.h @@ -31,6 +31,7 @@ #define MYSQLI_CLOSE_DISCONNECTED MYSQLND_CLOSE_DISCONNECTED #define mysqli_result_is_unbuffered(r) ((r)->unbuf) +#define mysqli_result_is_unbuffered_and_not_everything_is_fetched(r) ((r)->unbuf && !(r)->unbuf->eof_reached) #define mysqli_server_status(c) (c)->upsert_status.server_status #define mysqli_stmt_get_id(s) ((s)->data->stmt_id) #define mysqli_stmt_warning_count(s) mysqlnd_stmt_warning_count((s)) diff --git a/ext/mysqli/mysqli_result_iterator.c b/ext/mysqli/mysqli_result_iterator.c index e49cc5d1b7708..f1d4b68ed2330 100644 --- a/ext/mysqli/mysqli_result_iterator.c +++ b/ext/mysqli/mysqli_result_iterator.c @@ -133,7 +133,7 @@ static void php_mysqli_result_iterator_rewind(zend_object_iterator *iter TSRMLS_ if (mysqli_result_is_unbuffered(result)) { #if MYSQLI_USE_MYSQLND - if (result->unbuf && result->unbuf->eof_reached) { + if (result->unbuf->eof_reached) { #else if (result->eof) { #endif diff --git a/ext/mysqli/tests/bug55582.phpt b/ext/mysqli/tests/bug55582.phpt new file mode 100644 index 0000000000000..85fc7f6ce8630 --- /dev/null +++ b/ext/mysqli/tests/bug55582.phpt @@ -0,0 +1,41 @@ +--TEST-- +Bug #55582 mysqli_num_rows() returns always 0 for unbuffered, when mysqlnd is used +--SKIPIF-- + +--FILE-- +real_query("SELECT 1")); + $res = $link->use_result(); + var_dump(mysqli_num_rows($res)); + var_dump($res->fetch_assoc()); + var_dump(mysqli_num_rows($res)); + var_dump($res->fetch_assoc()); + var_dump(mysqli_num_rows($res)); + + $link->close(); + echo "done\n"; +?> +--EXPECTF-- +bool(true) + +Warning: mysqli_num_rows(): Function cannot be used with MYSQL_USE_RESULT in %s on line %d +int(0) +array(1) { + [1]=> + string(1) "1" +} + +Warning: mysqli_num_rows(): Function cannot be used with MYSQL_USE_RESULT in %s on line %d +int(0) +NULL +int(1) +done \ No newline at end of file diff --git a/ext/mysqlnd/mysqlnd_result.c b/ext/mysqlnd/mysqlnd_result.c index 6262793803bc4..d4ca9c49c8789 100644 --- a/ext/mysqlnd/mysqlnd_result.c +++ b/ext/mysqlnd/mysqlnd_result.c @@ -601,19 +601,18 @@ mysqlnd_fetch_lengths_buffered(MYSQLND_RES * const result TSRMLS_DC) static unsigned long * mysqlnd_fetch_lengths_unbuffered(MYSQLND_RES * const result TSRMLS_DC) { - return result->lengths; + /* simulate output of libmysql */ + return (!result->unbuf || result->unbuf->last_row_data || result->unbuf->eof_reached)? result->lengths:NULL; } /* }}} */ -#if !defined(MYSQLND_USE_OPTIMISATIONS) || MYSQLND_USE_OPTIMISATIONS == 0 /* {{{ mysqlnd_res::fetch_lengths */ PHPAPI unsigned long * _mysqlnd_fetch_lengths(MYSQLND_RES * const result TSRMLS_DC) { return result->m.fetch_lengths? result->m.fetch_lengths(result TSRMLS_CC) : NULL; } /* }}} */ -#endif /* {{{ mysqlnd_fetch_row_unbuffered_c */ From ac90fb42875ac1f1cfa2d6ecc2cebab414dc9df9 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 5 Sep 2011 16:24:40 +0000 Subject: [PATCH 0784/2394] No more test failure for libmysql, http://news.php.net/php.internals/55210 --- ext/mysqli/tests/mysqli_stmt_num_rows.phpt | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_stmt_num_rows.phpt b/ext/mysqli/tests/mysqli_stmt_num_rows.phpt index af81ca4e8ae6f..a1f5e89c7a846 100644 --- a/ext/mysqli/tests/mysqli_stmt_num_rows.phpt +++ b/ext/mysqli/tests/mysqli_stmt_num_rows.phpt @@ -82,7 +82,17 @@ require_once('skipifconnectfailure.inc'); $i++; } while (mysqli_stmt_fetch($stmt)); - if (7 !== ($tmp = mysqli_stmt_num_rows($stmt))) + /* NOTE to users + Behaviour with libmysql is UNDEFINED, see http://news.php.net/php.internals/55210 + Because it is undefined it is allowed to the mysqlnd DEVELOPER to implement + any behaviour they like, including the one checked for in this test. + What the test does is cover an implementation detail of the mysqlnd library. + This implementation detail may, at any time, change without prior notice. + On the contrary, the mysqlnd way is a reasonable one and, maybe, one fine + day, after Klingons visited earh, becomes the official one. Meanwhile do + not rely on it. + */ + if ($IS_MYSQLND && (7 !== ($tmp = mysqli_stmt_num_rows($stmt)))) printf("[54] Expecting int/7, got %s/%s\n", gettype($tmp), $tmp); } else { From 57d0b478fb2a0564de282cb1b5e94ac8ee717d09 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 5 Sep 2011 19:59:42 +0000 Subject: [PATCH 0785/2394] - add skipif --- ext/xmlrpc/tests/bug51288.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/xmlrpc/tests/bug51288.phpt b/ext/xmlrpc/tests/bug51288.phpt index d9bdef822ef0b..ba341369bc8a7 100644 --- a/ext/xmlrpc/tests/bug51288.phpt +++ b/ext/xmlrpc/tests/bug51288.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #51288 (CVE-2010-0397, NULL pointer deref when no in request) +--SKIPIF-- + --FILE-- Date: Tue, 6 Sep 2011 05:13:47 +0000 Subject: [PATCH 0786/2394] this tests looks mysqlnd only --- ext/mysqli/tests/bug55582.phpt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/mysqli/tests/bug55582.phpt b/ext/mysqli/tests/bug55582.phpt index 85fc7f6ce8630..5b38f3f803eda 100644 --- a/ext/mysqli/tests/bug55582.phpt +++ b/ext/mysqli/tests/bug55582.phpt @@ -5,6 +5,7 @@ Bug #55582 mysqli_num_rows() returns always 0 for unbuffered, when mysqlnd is us require_once('skipif.inc'); require_once('skipifconnectfailure.inc'); require_once("connect.inc"); +if(!$IS_MYSQLND) die("skip This bug is for mysqlnd only"); ?> --FILE-- Date: Tue, 6 Sep 2011 05:20:05 +0000 Subject: [PATCH 0787/2394] use DBUG_ON flag for checking debug # Some libmysql builds don't define DBUG_OFF and non-debug builds are more frequent --- ext/mysqli/mysqli.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index f0538617ff98e..b3b83958a1249 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -809,10 +809,10 @@ PHP_MINIT_FUNCTION(mysqli) #ifdef MYSQLI_USE_MYSQLND REGISTER_LONG_CONSTANT("MYSQLI_DEBUG_TRACE_ENABLED", MYSQLND_DBG_ENABLED, CONST_CS | CONST_PERSISTENT); #else -#ifndef DBUG_OFF - REGISTER_LONG_CONSTANT("MYSQLI_DEBUG_TRACE_ENABLED", 0, CONST_CS | CONST_PERSISTENT); -#else +#ifdef DBUG_ON REGISTER_LONG_CONSTANT("MYSQLI_DEBUG_TRACE_ENABLED", 1, CONST_CS | CONST_PERSISTENT); +#else + REGISTER_LONG_CONSTANT("MYSQLI_DEBUG_TRACE_ENABLED", 0, CONST_CS | CONST_PERSISTENT); #endif #endif From 22fbe247e3b67303ee6cfc84cf92007639989126 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 6 Sep 2011 05:20:51 +0000 Subject: [PATCH 0788/2394] fix test --- ext/mysql/tests/mysql_query_load_data_openbasedir.phpt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt index ff62f4227ea43..90849d1c8f156 100644 --- a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt +++ b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt @@ -25,11 +25,10 @@ if ($socket == "" && $host != NULL && $host != 'localhost' && $host != '.') { } } ?> ---INI-- -open_basedir="." --FILE-- Date: Tue, 6 Sep 2011 05:21:56 +0000 Subject: [PATCH 0789/2394] fix redirect when test run from different places --- ext/pdo_mysql/tests/common.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/pdo_mysql/tests/common.phpt b/ext/pdo_mysql/tests/common.phpt index 8179454cf76d1..f55d1f883b482 100644 --- a/ext/pdo_mysql/tests/common.phpt +++ b/ext/pdo_mysql/tests/common.phpt @@ -8,7 +8,7 @@ if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) print 'skip not # magic auto-configuration $config = array( - 'TESTS' => 'ext/pdo/tests' + 'TESTS' => __DIR__.'/ext/pdo/tests' ); if (false !== getenv('PDO_MYSQL_TEST_DSN')) { From 442e9c514857fa5cb868b2a78254c9803493d9a6 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 6 Sep 2011 05:28:25 +0000 Subject: [PATCH 0790/2394] allow user streams to override ch* on windows too --- ext/standard/filestat.c | 32 +++++++++++++++++++++----------- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 5c4c5d465ed8d..9b26c81946b1e 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -415,6 +415,7 @@ PHPAPI int php_get_gid_by_name(const char *name, gid_t *gid TSRMLS_DC) #endif return SUCCESS; } +#endif static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ { @@ -450,11 +451,18 @@ static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ RETURN_FALSE; } } else { +#if !defined(WINDOWS) +/* On Windows, we expect regular chgrp to fail silently by default */ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can not call chgrp() for a non-standard stream"); +#endif RETURN_FALSE; } } +#if defined(WINDOWS) + /* We have no native chgrp on Windows, nothing left to do if stream doesn't have own implementation */ + RETURN_FALSE; +#else if (Z_TYPE_P(group) == IS_LONG) { gid = (gid_t)Z_LVAL_P(group); } else if (Z_TYPE_P(group) == IS_STRING) { @@ -484,20 +492,16 @@ static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ RETURN_FALSE; } RETURN_TRUE; +#endif } /* }}} */ -#endif #ifndef NETWARE /* {{{ proto bool chgrp(string filename, mixed group) Change file group */ PHP_FUNCTION(chgrp) { -#if !defined(WINDOWS) php_do_chgrp(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0); -#else - RETURN_FALSE; -#endif } /* }}} */ @@ -546,6 +550,7 @@ PHPAPI uid_t php_get_uid_by_name(const char *name, uid_t *uid TSRMLS_DC) #endif return SUCCESS; } +#endif static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ { @@ -581,11 +586,19 @@ static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ RETURN_FALSE; } } else { +#if !defined(WINDOWS) +/* On Windows, we expect regular chown to fail silently by default */ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can not call chown() for a non-standard stream"); +#endif RETURN_FALSE; } } +#if defined(WINDOWS) + /* We have no native chown on Windows, nothing left to do if stream doesn't have own implementation */ + RETURN_FALSE; +#else + if (Z_TYPE_P(user) == IS_LONG) { uid = (uid_t)Z_LVAL_P(user); } else if (Z_TYPE_P(user) == IS_STRING) { @@ -614,21 +627,18 @@ static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", strerror(errno)); RETURN_FALSE; } + RETURN_TRUE; +#endif } /* }}} */ -#endif + #ifndef NETWARE /* {{{ proto bool chown (string filename, mixed user) Change file owner */ PHP_FUNCTION(chown) { -#if !defined(WINDOWS) - RETVAL_TRUE; php_do_chown(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0); -#else - RETURN_FALSE; -#endif } /* }}} */ From 75cf1e873034f815e14894e6a497394d94b254fb Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 6 Sep 2011 05:31:08 +0000 Subject: [PATCH 0791/2394] unused variables --- ext/standard/filestat.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 9b26c81946b1e..cad5ce429bab2 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -422,8 +422,10 @@ static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */ char *filename; int filename_len; zval *group; +#if !defined(WINDOWS) gid_t gid; int ret; +#endif php_stream_wrapper *wrapper; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pz/", &filename, &filename_len, &group) == FAILURE) { @@ -557,8 +559,10 @@ static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */ char *filename; int filename_len; zval *user; +#if !defined(WINDOWS) uid_t uid; int ret; +#endif php_stream_wrapper *wrapper; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "pz/", &filename, &filename_len, &user) == FAILURE) { From 58a96d5588ad21961fc627fb19a317a473a1263f Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 06:32:00 +0000 Subject: [PATCH 0792/2394] - WS --- Zend/zend_compile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 000942f9df3b6..16520336d48e0 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -5911,7 +5911,7 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token znode dummy, value_node; zend_bool assign_by_ref=0; - opline = &CG(active_op_array)->opcodes[as_token->u.op. opline_num]; + opline = &CG(active_op_array)->opcodes[as_token->u.op.opline_num]; if (key->op_type != IS_UNUSED) { znode *tmp; From 7f3ab56cecf29fa0063276a446ecdc4188ea9afa Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 06:32:42 +0000 Subject: [PATCH 0793/2394] - WS --- Zend/zend_exceptions.c | 1 - 1 file changed, 1 deletion(-) diff --git a/Zend/zend_exceptions.c b/Zend/zend_exceptions.c index 1ec8eece4ac81..2259a9cd990a2 100644 --- a/Zend/zend_exceptions.c +++ b/Zend/zend_exceptions.c @@ -90,7 +90,6 @@ void zend_throw_exception_internal(zval *exception TSRMLS_DC) /* {{{ */ if (exception != NULL) { zend_get_object_classname(exception, &classname, &name_len TSRMLS_CC); - DTRACE_EXCEPTION_THROWN(classname); } else { DTRACE_EXCEPTION_THROWN(NULL); From 710d46f38e46daf39d8a790aa14553b5089e6e52 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 06:34:36 +0000 Subject: [PATCH 0794/2394] - WS --- Zend/zend_hash.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index 506def0014a38..3aca2e7b928f0 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -197,7 +197,7 @@ ZEND_API int _zend_hash_add_or_update(HashTable *ht, const char *arKey, uint nKe ulong h; uint nIndex; Bucket *p; -#ifdef ZEND_SIGNALS +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif @@ -279,7 +279,7 @@ ZEND_API int _zend_hash_quick_add_or_update(HashTable *ht, const char *arKey, ui { uint nIndex; Bucket *p; -#ifdef ZEND_SIGNALS +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif @@ -368,7 +368,7 @@ ZEND_API int _zend_hash_index_update_or_next_insert(HashTable *ht, ulong h, void { uint nIndex; Bucket *p; -#ifdef ZEND_SIGNALS +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif @@ -440,7 +440,7 @@ ZEND_API int _zend_hash_index_update_or_next_insert(HashTable *ht, ulong h, void static int zend_hash_do_resize(HashTable *ht) { Bucket **t; -#ifdef ZEND_SIGNALS +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif @@ -487,7 +487,7 @@ ZEND_API int zend_hash_del_key_or_index(HashTable *ht, const char *arKey, uint n { uint nIndex; Bucket *p; -#ifdef ZEND_SIGNALS +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif @@ -610,7 +610,7 @@ ZEND_API void zend_hash_clean(HashTable *ht) static Bucket *zend_hash_apply_deleter(HashTable *ht, Bucket *p) { Bucket *retval; -#ifdef ZEND_SIGNALS +#ifdef ZEND_SIGNALS TSRMLS_FETCH(); #endif From ec1575fbb2612af3e74e194e0bdde1e754c60f39 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 06:42:11 +0000 Subject: [PATCH 0795/2394] - add skipif --- ext/iconv/tests/bug52211.phpt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/iconv/tests/bug52211.phpt b/ext/iconv/tests/bug52211.phpt index 152aab839b00f..9bf3329a4265a 100644 --- a/ext/iconv/tests/bug52211.phpt +++ b/ext/iconv/tests/bug52211.phpt @@ -1,5 +1,8 @@ --TEST-- Bug #52211 (iconv() returns part of string on error) + --FILE-- Date: Tue, 6 Sep 2011 06:44:59 +0000 Subject: [PATCH 0796/2394] - add skipif --- ext/mbstring/tests/bug52931.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/mbstring/tests/bug52931.phpt b/ext/mbstring/tests/bug52931.phpt index 9669d884cb9a3..52efd03de23aa 100644 --- a/ext/mbstring/tests/bug52931.phpt +++ b/ext/mbstring/tests/bug52931.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #52931 (strripos not overloaded with function overloading enabled) +--SKIPIF-- + --INI-- mbstring.func_overload = 7 mbstring.internal_encoding = utf-8 From 7921f410fc95ba41433ec5602a585759c4c0c95b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 06:47:12 +0000 Subject: [PATCH 0797/2394] - add skipif --- ext/mcrypt/tests/bug55169.phpt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/mcrypt/tests/bug55169.phpt b/ext/mcrypt/tests/bug55169.phpt index 7bddd50875ba6..bebcd675c8687 100644 --- a/ext/mcrypt/tests/bug55169.phpt +++ b/ext/mcrypt/tests/bug55169.phpt @@ -1,8 +1,9 @@ --TEST-- -mcrypt_create_iv -https://bugs.php.net/bug.php?id=55169 +mcrypt_create_iv https://bugs.php.net/bug.php?id=55169 --CREDIT-- Ryan Biesemeyer +--SKIPIF-- + --FILE-- Date: Tue, 6 Sep 2011 06:50:56 +0000 Subject: [PATCH 0798/2394] - add skipif --- ext/pdo/tests/pdo_036.phpt | 2 ++ ext/pdo/tests/pdorow.phpt | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/pdo/tests/pdo_036.phpt b/ext/pdo/tests/pdo_036.phpt index 6bd38cb06a8a0..94006c9e808b6 100644 --- a/ext/pdo/tests/pdo_036.phpt +++ b/ext/pdo/tests/pdo_036.phpt @@ -1,5 +1,7 @@ --TEST-- Testing PDORow and PDOStatement instances with Reflection +--SKIPIF-- + --FILE-- --FILE-- Date: Tue, 6 Sep 2011 06:52:26 +0000 Subject: [PATCH 0799/2394] - add skipif --- ext/phar/tests/bug53872.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/phar/tests/bug53872.phpt b/ext/phar/tests/bug53872.phpt index 490ae6fd4c34b..51e5cd49136ec 100644 --- a/ext/phar/tests/bug53872.phpt +++ b/ext/phar/tests/bug53872.phpt @@ -1,5 +1,7 @@ --TEST-- bug#53872 (internal corruption of phar) +--SKIPIF-- + --INI-- phar.readonly=0 --FILE-- From 3179ef674c6567338f7cfda93492cf5aed65545b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 06:57:53 +0000 Subject: [PATCH 0800/2394] - add skipif --- ext/posix/tests/posix_ttyname_error.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation1.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation2.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation3.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation4.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation5.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation6.phpt | 6 ++++++ ext/posix/tests/posix_ttyname_variation7.phpt | 6 ++++++ 8 files changed, 48 insertions(+) diff --git a/ext/posix/tests/posix_ttyname_error.phpt b/ext/posix/tests/posix_ttyname_error.phpt index e3ec695e5449b..f7b011e773617 100644 --- a/ext/posix/tests/posix_ttyname_error.phpt +++ b/ext/posix/tests/posix_ttyname_error.phpt @@ -4,6 +4,12 @@ Test function posix_ttyname() by calling it more than or less than its expected Marco Fabbri mrfabbri@gmail.com Francesco Fullone ff@ideato.it #PHPTestFest Cesena Italia on 2009-06-20 +--SKIPIF-- + --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- Date: Tue, 6 Sep 2011 07:00:05 +0000 Subject: [PATCH 0801/2394] - force LF From 67d0d0e8d2b5dc5112a673c9cf94cc5d617148cc Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:03:48 +0000 Subject: [PATCH 0802/2394] - force LF From b263273baaa9ebd175dda6bf4b0212670f8cc589 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:07:23 +0000 Subject: [PATCH 0803/2394] - don't test dir sep --- .../ReflectionClass_newInstanceWithoutConstructor.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt b/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt index fffddf4f62330..1932dbfaf1819 100644 --- a/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt +++ b/ext/reflection/tests/ReflectionClass_newInstanceWithoutConstructor.phpt @@ -26,8 +26,8 @@ object(Foo)#%d (0) { object(stdClass)#%d (0) { } -Fatal error: Uncaught exception 'ReflectionException' with message 'Class DateTime is an internal class that cannot be instantiated without invoking its constructor' in %s/tests/ReflectionClass_newInstanceWithoutConstructor.php:%d +Fatal error: Uncaught exception 'ReflectionException' with message 'Class DateTime is an internal class that cannot be instantiated without invoking its constructor' in %sReflectionClass_newInstanceWithoutConstructor.php:%d Stack trace: -#0 %s/ReflectionClass_newInstanceWithoutConstructor.php(%d): ReflectionClass->newInstanceWithoutConstructor() +#0 %sReflectionClass_newInstanceWithoutConstructor.php(%d): ReflectionClass->newInstanceWithoutConstructor() #1 {main} - thrown in %s/ReflectionClass_newInstanceWithoutConstructor.php on line %d + thrown in %sReflectionClass_newInstanceWithoutConstructor.php on line %d From 66a1d741bfdd7068837c2be9de39db3bfb0c73af Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:09:56 +0000 Subject: [PATCH 0804/2394] - add skipif --- ext/simplexml/tests/bug37076.phpt | 2 ++ ext/simplexml/tests/bug37076_1.phpt | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/simplexml/tests/bug37076.phpt b/ext/simplexml/tests/bug37076.phpt index a5b3801ccb983..c7f19b3cc2a3c 100644 --- a/ext/simplexml/tests/bug37076.phpt +++ b/ext/simplexml/tests/bug37076.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #37076 (SimpleXML ignores .=) +--SKIPIF-- + --FILE-- "); diff --git a/ext/simplexml/tests/bug37076_1.phpt b/ext/simplexml/tests/bug37076_1.phpt index d2260040c14dd..d4f4e03337bfd 100644 --- a/ext/simplexml/tests/bug37076_1.phpt +++ b/ext/simplexml/tests/bug37076_1.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #37076 (SimpleXML ignores .=) (appending to unnamed attribute) +--SKIPIF-- + --FILE-- "); From 80a2175c37c9ba42e5d6653cd3fd427b5a81664f Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:23:20 +0000 Subject: [PATCH 0805/2394] - skip on win, name.. name. are not valid names --- ext/spl/tests/DirectoryIterator_getExtension_basic.phpt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt b/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt index 20ef3bf36e8d7..6d5d5e62ce42a 100644 --- a/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt +++ b/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt @@ -1,5 +1,11 @@ --TEST-- SPL: DirectoryIterator::getExtension() basic test +--SKIPIF-- + --FILE-- Date: Tue, 6 Sep 2011 07:26:05 +0000 Subject: [PATCH 0806/2394] - use something we know it exists... --- ext/spl/tests/DirectoryIterator_by_reference.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/spl/tests/DirectoryIterator_by_reference.phpt b/ext/spl/tests/DirectoryIterator_by_reference.phpt index 5352a5df18eea..06127ec37b25f 100644 --- a/ext/spl/tests/DirectoryIterator_by_reference.phpt +++ b/ext/spl/tests/DirectoryIterator_by_reference.phpt @@ -5,10 +5,10 @@ Havard Eide #PHPTestFest2009 Norway 2009-06-09 \o/ --FILE-- --EXPECTF-- -Fatal error: An iterator cannot be used with foreach by reference in %s on line %d \ No newline at end of file +Fatal error: An iterator cannot be used with foreach by reference in %s on line %d From 95aefb01146fea3a52388feea2ee76df08009317 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:28:38 +0000 Subject: [PATCH 0807/2394] - add skipif --- ext/sqlite3/tests/bug53463.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/sqlite3/tests/bug53463.phpt b/ext/sqlite3/tests/bug53463.phpt index c9216e660f39d..dcfc13d5ba1b4 100644 --- a/ext/sqlite3/tests/bug53463.phpt +++ b/ext/sqlite3/tests/bug53463.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #53463 (sqlite3 columnName() segfaults on bad column_number) +--SKIPIF-- + --FILE-- Date: Tue, 6 Sep 2011 07:29:59 +0000 Subject: [PATCH 0808/2394] - add skipif --- ext/sqlite3/tests/sqlite3_prepare_001.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/sqlite3/tests/sqlite3_prepare_001.phpt b/ext/sqlite3/tests/sqlite3_prepare_001.phpt index 7cd4e4ccf82c4..f9e5fadce7ddd 100644 --- a/ext/sqlite3/tests/sqlite3_prepare_001.phpt +++ b/ext/sqlite3/tests/sqlite3_prepare_001.phpt @@ -1,5 +1,7 @@ --TEST-- SQLite3 - memory leak on SQLite3Result and SQLite3Stmt +--SKIPIF-- + --FILE-- Date: Tue, 6 Sep 2011 07:32:37 +0000 Subject: [PATCH 0809/2394] - skip on win --- ext/standard/tests/directory/open_basedir_001.phpt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/standard/tests/directory/open_basedir_001.phpt b/ext/standard/tests/directory/open_basedir_001.phpt index 092eac27f04a4..d44f048163236 100644 --- a/ext/standard/tests/directory/open_basedir_001.phpt +++ b/ext/standard/tests/directory/open_basedir_001.phpt @@ -1,5 +1,10 @@ --TEST-- openbase_dir runtime tightning +--SKIPIF-- + Date: Tue, 6 Sep 2011 07:44:43 +0000 Subject: [PATCH 0810/2394] - fix test --- .../tests/file/rename_variation13-win32.phpt | Bin 4094 -> 4755 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/standard/tests/file/rename_variation13-win32.phpt b/ext/standard/tests/file/rename_variation13-win32.phpt index c0388fd300ce5f88e81e58680942ac1eed3edeed..af4649d9aa99533a7812d1d7aa9e39ec6e95dea8 100644 GIT binary patch delta 1083 zcmew-KUsA{Guvcs_8^&})V##p)cCT*qRhmS%=|nijpotxHk>P&vXEi$>BM{F_|j}W0$p)~mbj~QWw?7Z%T z6@k*&KQ2BV26ctvlA_GKbOl}A$>+IM2g)rbJXyqe-yOdqcHRj53P9d2=d}Z+gvn=k s{Rk=6ob1de0?dcTlYjHd6H+WO`4FE8*koRQ7eb1Si8WPn@&|rC06!acV*mgE delta 572 zcmbQN`cHmCGaIA+XQ}tRVT}EYe2)8YqA8d$K)E`$jKjh zn~=oJCP(uN0>$0I^hY-7$&2}|A;CELGrvDnrQqat0cb1%BUpO!1VMSAjPzs`K|`q8 kEJ0V8TJD030(~Hcc^65C1V5LSmX?A`eqO2qkio?T0Dj=GG5`Po From ee9738077fd3626e0c937346a2f03a44c8fc0a41 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:47:20 +0000 Subject: [PATCH 0811/2394] - fix test --- ext/standard/tests/php_ini_loaded_file.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/php_ini_loaded_file.phpt b/ext/standard/tests/php_ini_loaded_file.phpt index 6f4b7fe68a505..747e0196f19f4 100644 --- a/ext/standard/tests/php_ini_loaded_file.phpt +++ b/ext/standard/tests/php_ini_loaded_file.phpt @@ -11,4 +11,4 @@ precision=12 var_dump(php_ini_loaded_file()); ?> --EXPECTF-- -string(%d) "%stmp-php.ini" +string(%d) "%sphp.ini" From 555a1381134c6a855d59de41cc4485e3927d1d5d Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 07:49:31 +0000 Subject: [PATCH 0812/2394] - add skipif --- ext/sysvshm/tests/001.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/sysvshm/tests/001.phpt b/ext/sysvshm/tests/001.phpt index ba45286af26cd..4b1525b69701e 100644 --- a/ext/sysvshm/tests/001.phpt +++ b/ext/sysvshm/tests/001.phpt @@ -1,5 +1,7 @@ --TEST-- ftok() tests +--SKIPIF-- + --FILE-- Date: Tue, 6 Sep 2011 08:11:37 +0000 Subject: [PATCH 0813/2394] add skipif --- ext/filter/tests/005.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/filter/tests/005.phpt b/ext/filter/tests/005.phpt index f44379153ea7f..b3735f5627f35 100644 --- a/ext/filter/tests/005.phpt +++ b/ext/filter/tests/005.phpt @@ -1,5 +1,7 @@ --TEST-- GET/REQUEST Test with fifa example data +--SKIPIF-- + --INI-- filter.default=stripped --GET-- From b1eaad7d1f84e75bbbfa95f043e1b6899b21880c Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 6 Sep 2011 09:17:12 +0000 Subject: [PATCH 0814/2394] Added skipif --- ext/intl/tests/resourcebundle_arrayaccess.phpt | 2 ++ ext/intl/tests/resourcebundle_individual.phpt | 2 ++ ext/intl/tests/resourcebundle_iterator.phpt | 2 ++ 3 files changed, 6 insertions(+) diff --git a/ext/intl/tests/resourcebundle_arrayaccess.phpt b/ext/intl/tests/resourcebundle_arrayaccess.phpt index ef2c0a8b9882e..d035a8d304072 100644 --- a/ext/intl/tests/resourcebundle_arrayaccess.phpt +++ b/ext/intl/tests/resourcebundle_arrayaccess.phpt @@ -1,5 +1,7 @@ --TEST-- Test ResourceBundle array access and count - existing/missing keys +--SKIPIF-- + --FILE-- --FILE-- --FILE-- Date: Tue, 6 Sep 2011 09:20:14 +0000 Subject: [PATCH 0815/2394] - fix skipif msg --- ext/standard/tests/directory/open_basedir_001.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/directory/open_basedir_001.phpt b/ext/standard/tests/directory/open_basedir_001.phpt index d44f048163236..e05861a81db50 100644 --- a/ext/standard/tests/directory/open_basedir_001.phpt +++ b/ext/standard/tests/directory/open_basedir_001.phpt @@ -3,7 +3,7 @@ openbase_dir runtime tightning --SKIPIF-- Date: Tue, 6 Sep 2011 09:23:10 +0000 Subject: [PATCH 0816/2394] - move it to the right place --- .../tests/directory => tests/security}/open_basedir_001.phpt | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename {ext/standard/tests/directory => tests/security}/open_basedir_001.phpt (100%) diff --git a/ext/standard/tests/directory/open_basedir_001.phpt b/tests/security/open_basedir_001.phpt similarity index 100% rename from ext/standard/tests/directory/open_basedir_001.phpt rename to tests/security/open_basedir_001.phpt From e06ea30795d99b4562c4cefa1aa4aa62a22d51a4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 09:28:23 +0000 Subject: [PATCH 0817/2394] - missing --SKIPIF-- --- ext/iconv/tests/bug52211.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/iconv/tests/bug52211.phpt b/ext/iconv/tests/bug52211.phpt index 9bf3329a4265a..c851cbad6af7c 100644 --- a/ext/iconv/tests/bug52211.phpt +++ b/ext/iconv/tests/bug52211.phpt @@ -1,5 +1,6 @@ --TEST-- Bug #52211 (iconv() returns part of string on error) +--SKIPIF-- From 899ee8e705329f8a06b17aaf1b9b0ad482e64203 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 6 Sep 2011 09:29:04 +0000 Subject: [PATCH 0818/2394] Add skipif --- ext/hash/tests/hash_copy_001.phpt | 2 ++ ext/hash/tests/hash_copy_002.phpt | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/hash/tests/hash_copy_001.phpt b/ext/hash/tests/hash_copy_001.phpt index 84d95945f7caa..6609a6f3bd502 100644 --- a/ext/hash/tests/hash_copy_001.phpt +++ b/ext/hash/tests/hash_copy_001.phpt @@ -1,5 +1,7 @@ --TEST-- hash_copy() basic tests +--SKIPIF-- + --FILE-- --FILE-- Date: Tue, 6 Sep 2011 09:45:21 +0000 Subject: [PATCH 0819/2394] move it to right place --- .../image_type_to_mime_type_variation3.phpt | 76 ------------------- .../image}/image_type_to_mime_type_basic.phpt | 0 .../image}/image_type_to_mime_type_error.phpt | 0 .../image_type_to_mime_type_variation1.phpt | 0 .../image_type_to_mime_type_variation2.phpt | 0 .../image_type_to_mime_type_variation4.phpt | 0 6 files changed, 76 deletions(-) delete mode 100644 ext/gd/tests/image_type_to_mime_type_variation3.phpt rename ext/{gd/tests => standard/tests/image}/image_type_to_mime_type_basic.phpt (100%) rename ext/{gd/tests => standard/tests/image}/image_type_to_mime_type_error.phpt (100%) rename ext/{gd/tests => standard/tests/image}/image_type_to_mime_type_variation1.phpt (100%) rename ext/{gd/tests => standard/tests/image}/image_type_to_mime_type_variation2.phpt (100%) rename ext/{gd/tests => standard/tests/image}/image_type_to_mime_type_variation4.phpt (100%) diff --git a/ext/gd/tests/image_type_to_mime_type_variation3.phpt b/ext/gd/tests/image_type_to_mime_type_variation3.phpt deleted file mode 100644 index 8383facb091a9..0000000000000 --- a/ext/gd/tests/image_type_to_mime_type_variation3.phpt +++ /dev/null @@ -1,76 +0,0 @@ ---TEST-- -Test image_type_to_mime_type() function : usage variations - Pass equivalent imagetype constant integer values ---FILE-- - -===DONE=== ---EXPECTREGEX-- -\*\*\* Testing image_type_to_mime_type\(\) : usage variations \*\*\* - --- Iteration 1 -- -string\(9\) "image\/gif" - --- Iteration 2 -- -string\(10\) "image\/jpeg" - --- Iteration 3 -- -string\(9\) "image\/png" - --- Iteration 4 -- -string\(29\) "application\/x-shockwave-flash" - --- Iteration 5 -- -string\(9\) "image\/psd" - --- Iteration 6 -- -string\(14\) "image\/x-ms-bmp" - --- Iteration 7 -- -string\(10\) "image\/tiff" - --- Iteration 8 -- -string\(10\) "image\/tiff" - --- Iteration 9 -- -string\(24\) "application\/octet-stream" - --- Iteration 10 -- -string\(9\) "image\/jp2" - --- Iteration 11 -- -string\(24\) "application\/octet-stream" - --- Iteration 12 -- -string\(24\) "application\/octet-stream" - --- Iteration 13 -- -string\(2[49]\) "application\/(x-shockwave-flash|octet-stream)" - --- Iteration 14 -- -string\(9\) "image\/iff" - --- Iteration 15 -- -string\(18\) "image\/vnd.wap.wbmp" - --- Iteration 16 -- -string\(9\) "image\/xbm" - --- Iteration 17 -- -string\(24\) "image\/vnd.microsoft.icon" -===DONE=== diff --git a/ext/gd/tests/image_type_to_mime_type_basic.phpt b/ext/standard/tests/image/image_type_to_mime_type_basic.phpt similarity index 100% rename from ext/gd/tests/image_type_to_mime_type_basic.phpt rename to ext/standard/tests/image/image_type_to_mime_type_basic.phpt diff --git a/ext/gd/tests/image_type_to_mime_type_error.phpt b/ext/standard/tests/image/image_type_to_mime_type_error.phpt similarity index 100% rename from ext/gd/tests/image_type_to_mime_type_error.phpt rename to ext/standard/tests/image/image_type_to_mime_type_error.phpt diff --git a/ext/gd/tests/image_type_to_mime_type_variation1.phpt b/ext/standard/tests/image/image_type_to_mime_type_variation1.phpt similarity index 100% rename from ext/gd/tests/image_type_to_mime_type_variation1.phpt rename to ext/standard/tests/image/image_type_to_mime_type_variation1.phpt diff --git a/ext/gd/tests/image_type_to_mime_type_variation2.phpt b/ext/standard/tests/image/image_type_to_mime_type_variation2.phpt similarity index 100% rename from ext/gd/tests/image_type_to_mime_type_variation2.phpt rename to ext/standard/tests/image/image_type_to_mime_type_variation2.phpt diff --git a/ext/gd/tests/image_type_to_mime_type_variation4.phpt b/ext/standard/tests/image/image_type_to_mime_type_variation4.phpt similarity index 100% rename from ext/gd/tests/image_type_to_mime_type_variation4.phpt rename to ext/standard/tests/image/image_type_to_mime_type_variation4.phpt From 57aaa1dca91a6fc4dd7c37d830997666a4a83f8f Mon Sep 17 00:00:00 2001 From: Florian Anderiasch Date: Tue, 6 Sep 2011 09:56:13 +0000 Subject: [PATCH 0820/2394] Fixed ext/sockets/tests/socket_strerror.phpt So it seems a missing ) killed the test. --- ext/sockets/tests/socket_strerror.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/sockets/tests/socket_strerror.phpt b/ext/sockets/tests/socket_strerror.phpt index 52e7a0a4816f6..7985fadbab4a7 100644 --- a/ext/sockets/tests/socket_strerror.phpt +++ b/ext/sockets/tests/socket_strerror.phpt @@ -5,11 +5,11 @@ Florian Anderiasch fa@php.net --SKIPIF-- --FILE-- From f2b8c5395ca9fa1a3fb770807d646cd3c83d88cf Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 11:24:21 +0000 Subject: [PATCH 0821/2394] - use a more portable name for the filename --- ext/spl/tests/SplFileObject_fputcsv.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/spl/tests/SplFileObject_fputcsv.phpt b/ext/spl/tests/SplFileObject_fputcsv.phpt index d70c304d96e90..2a42d57479b9c 100644 --- a/ext/spl/tests/SplFileObject_fputcsv.phpt +++ b/ext/spl/tests/SplFileObject_fputcsv.phpt @@ -2,7 +2,7 @@ SplFileObject::fputcsv(): functionality tests --FILE-- Date: Tue, 6 Sep 2011 11:28:34 +0000 Subject: [PATCH 0822/2394] Mention which library php is using --- ext/readline/readline_cli.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/readline/readline_cli.c b/ext/readline/readline_cli.c index cae160caaeb13..c7c5fabec6945 100644 --- a/ext/readline/readline_cli.c +++ b/ext/readline/readline_cli.c @@ -743,6 +743,11 @@ PHP_MSHUTDOWN_FUNCTION(cli_readline) PHP_MINFO_FUNCTION(cli_readline) { + php_info_print_table_start(); + php_info_print_table_header(2, "Readline Support", "enabled"); + php_info_print_table_row(2, "Readline library", (rl_library_version ? rl_library_version : "Unknown")); + php_info_print_table_end(); + DISPLAY_INI_ENTRIES(); } From 0572d9556892a0a99c65952c7c030cb4b0fbaa8c Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 12:24:16 +0000 Subject: [PATCH 0823/2394] - force LF From f7f2c8c209d9ff32f04d2c841287e2eaca2fbb41 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 12:30:47 +0000 Subject: [PATCH 0824/2394] - use only zlib function and reported the failure with base64 in #55620 --- ext/zlib/tests/003.phpt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/zlib/tests/003.phpt b/ext/zlib/tests/003.phpt index 2732d4cea651d..d9275d9f1f227 100644 --- a/ext/zlib/tests/003.phpt +++ b/ext/zlib/tests/003.phpt @@ -1,13 +1,13 @@ --TEST-- -gzencode()/base64_encode() +gzencode() --SKIPIF-- --FILE-- --EXPECT-- 118 36864 From 1a53d78b0c0042cf0887f23f06d5c8b6325fb70c Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 6 Sep 2011 12:58:01 +0000 Subject: [PATCH 0825/2394] Reverting to proper --INI-- section usage. Improve SKIPIF to skip test if open_basedir setting is too restrictive during test run for whatever reason. --- .../tests/mysql_query_load_data_openbasedir.phpt | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt index 90849d1c8f156..c2685a572e9df 100644 --- a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt +++ b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt @@ -2,9 +2,15 @@ LOAD DATA INFILE - open_basedir --SKIPIF-- +--INI-- +open_basedir="." --FILE-- Date: Tue, 6 Sep 2011 13:39:46 +0000 Subject: [PATCH 0826/2394] Prevent Notice --- ext/mysqli/tests/connect.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/connect.inc b/ext/mysqli/tests/connect.inc index ee1dce4640218..41bd1c1e9342b 100644 --- a/ext/mysqli/tests/connect.inc +++ b/ext/mysqli/tests/connect.inc @@ -223,7 +223,7 @@ } function have_innodb($link) { - if ($res = $link->query("SHOW VARIABLES LIKE 'have_innodb'") && + if (($res = $link->query("SHOW VARIABLES LIKE 'have_innodb'")) && $row = $res->fetch_row() && !empty($row)) { if ($row[1] == "DISABLED" || $row[1] == "NO") { From a4fcb5f1bbc2dd1078603f9d989158f998c64a3b Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 6 Sep 2011 13:50:45 +0000 Subject: [PATCH 0827/2394] Fix SKIPIF --- ext/mysqli/tests/mysqli_autocommit_oo.phpt | 2 +- .../mysqli_set_local_infile_handler_openbasedir.phpt | 11 +++++++---- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/ext/mysqli/tests/mysqli_autocommit_oo.phpt b/ext/mysqli/tests/mysqli_autocommit_oo.phpt index c3be58bc3ca4a..3a5a25779ddd4 100644 --- a/ext/mysqli/tests/mysqli_autocommit_oo.phpt +++ b/ext/mysqli/tests/mysqli_autocommit_oo.phpt @@ -7,7 +7,7 @@ mysqli->autocommit() require_once('skipifconnectfailure.inc'); require_once('connect.inc'); - if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket)) { + if (!$link = new my_mysqli($host, $user, $passwd, $db, $port, $socket)) { printf("skip Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n", $host, $user, $db, $port, $socket); exit(1); diff --git a/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt b/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt index c9e5f19962038..7163aca10dc31 100644 --- a/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt +++ b/ext/mysqli/tests/mysqli_set_local_infile_handler_openbasedir.phpt @@ -2,14 +2,17 @@ mysqli_set_local_infile_handler() - open basedir restrictions --SKIPIF-- Date: Tue, 6 Sep 2011 13:57:03 +0000 Subject: [PATCH 0828/2394] Fix SKIPIF --- ext/pdo_mysql/tests/pdo_mysql_interface.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql_interface.phpt b/ext/pdo_mysql/tests/pdo_mysql_interface.phpt index 9e13908a5ad1c..64a3cac1b82b7 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_interface.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_interface.phpt @@ -4,7 +4,7 @@ MySQL PDO class interface From ccd842f9122792bf9cbdeb290a87c8fdfd73f3c3 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 6 Sep 2011 14:47:57 +0000 Subject: [PATCH 0829/2394] BORK hunting - Fixing SKIPIF --- ext/mysqli/tests/mysqli_poll_reference.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_poll_reference.phpt b/ext/mysqli/tests/mysqli_poll_reference.phpt index 332f871afcfac..ab2ed2aee81e5 100644 --- a/ext/mysqli/tests/mysqli_poll_reference.phpt +++ b/ext/mysqli/tests/mysqli_poll_reference.phpt @@ -13,7 +13,7 @@ if (!$IS_MYSQLND) if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) die("skip cannot connect"); -if (mysqli_server_version($link) < 50012) +if (mysqli_get_server_version($link) < 50012) die("skip Test needs SQL function SLEEP() available as of MySQL 5.0.12"); ?> From 4f0b4031fe4b545bef934c13b20a931b3d7d9bcc Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 6 Sep 2011 14:48:43 +0000 Subject: [PATCH 0830/2394] add query information to the trace log --- ext/mysqlnd/mysqlnd_ps.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/mysqlnd/mysqlnd_ps.c b/ext/mysqlnd/mysqlnd_ps.c index e18e0aa3b41ea..c63fe9ffa87f0 100644 --- a/ext/mysqlnd/mysqlnd_ps.c +++ b/ext/mysqlnd/mysqlnd_ps.c @@ -385,6 +385,7 @@ MYSQLND_METHOD(mysqlnd_stmt, prepare)(MYSQLND_STMT * const s, const char * const DBG_RETURN(FAIL); } DBG_INF_FMT("stmt=%lu", stmt->stmt_id); + DBG_INF_FMT("query=%s", query); SET_ERROR_AFF_ROWS(stmt); SET_ERROR_AFF_ROWS(stmt->conn); From dc018f3d1085a4090568a2df8fef3ca154ebba0d Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 6 Sep 2011 15:07:24 +0000 Subject: [PATCH 0831/2394] Fixed bug#54450 (callback function when built against libedit) --- ext/readline/config.m4 | 21 +++++++++++++++++++++ ext/readline/readline.c | 5 +++++ 2 files changed, 26 insertions(+) diff --git a/ext/readline/config.m4 b/ext/readline/config.m4 index 729033b74f18d..b1cb0b67e823b 100644 --- a/ext/readline/config.m4 +++ b/ext/readline/config.m4 @@ -60,6 +60,13 @@ if test "$PHP_READLINE" && test "$PHP_READLINE" != "no"; then -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS ]) + PHP_CHECK_LIBRARY(edit, rl_on_new_line, + [ + AC_DEFINE(HAVE_RL_ON_NEW_LINE, 1, [ ]) + ],[],[ + -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS + ]) + AC_DEFINE(HAVE_LIBREADLINE, 1, [ ]) elif test "$PHP_LIBEDIT" != "no"; then @@ -93,6 +100,20 @@ elif test "$PHP_LIBEDIT" != "no"; then -L$READLINE_DIR/$PHP_LIBDIR ]) + PHP_CHECK_LIBRARY(edit, rl_callback_read_char, + [ + AC_DEFINE(HAVE_RL_CALLBACK_READ_CHAR, 1, [ ]) + ],[],[ + -L$READLINE_DIR/$PHP_LIBDIR + ]) + + PHP_CHECK_LIBRARY(edit, rl_on_new_line, + [ + AC_DEFINE(HAVE_RL_ON_NEW_LINE, 1, [ ]) + ],[],[ + -L$READLINE_DIR/$PHP_LIBDIR + ]) + AC_DEFINE(HAVE_LIBEDIT, 1, [ ]) fi diff --git a/ext/readline/readline.c b/ext/readline/readline.c index e9cdacb275a4c..ee23777f6bcc7 100644 --- a/ext/readline/readline.c +++ b/ext/readline/readline.c @@ -144,6 +144,8 @@ static const zend_function_entry php_readline_functions[] = { PHP_FE(readline_callback_read_char, arginfo_readline_callback_read_char) PHP_FE(readline_callback_handler_remove, arginfo_readline_callback_handler_remove) PHP_FE(readline_redisplay, arginfo_readline_redisplay) +#endif +#if HAVE_RL_ON_NEW_LINE PHP_FE(readline_on_new_line, arginfo_readline_on_new_line) #endif PHP_FE_END @@ -617,6 +619,9 @@ PHP_FUNCTION(readline_redisplay) } /* }}} */ +#endif + +#if HAVE_RL_ON_NEW_LINE /* {{{ proto void readline_on_new_line(void) Inform readline that the cursor has moved to a new line */ PHP_FUNCTION(readline_on_new_line) From f00b4a7d72ec6cc4e7d8e9855cbc9bba836fabbb Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Tue, 6 Sep 2011 15:09:15 +0000 Subject: [PATCH 0832/2394] Add a constant, READLINE_LIB, to be able to differenciate which lib is being used --- ext/readline/readline_cli.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ext/readline/readline_cli.c b/ext/readline/readline_cli.c index c7c5fabec6945..7476b417b1bd6 100644 --- a/ext/readline/readline_cli.c +++ b/ext/readline/readline_cli.c @@ -715,6 +715,12 @@ PHP_MINIT_FUNCTION(cli_readline) ZEND_INIT_MODULE_GLOBALS(cli_readline, cli_readline_init_globals, NULL); REGISTER_INI_ENTRIES(); +#if HAVE_LIBEDIT + REGISTER_STRING_CONSTANT("READLINE_LIB", "libedit", CONST_CS|CONST_PERSISTENT); +#else + REGISTER_STRING_CONSTANT("READLINE_LIB", "readline", CONST_CS|CONST_PERSISTENT); +#endif + GET_SHELL_CB(cb); if (cb) { cb->cli_shell_write = readline_shell_write; From 4e967d1bb1e821b9fac05f09cfd78cb0d03bad80 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 15:40:12 +0000 Subject: [PATCH 0833/2394] - fix skipif --- Zend/tests/bug31683.phpt | 2 -- 1 file changed, 2 deletions(-) diff --git a/Zend/tests/bug31683.phpt b/Zend/tests/bug31683.phpt index 4e0159d6c2108..205aca0746eb5 100644 --- a/Zend/tests/bug31683.phpt +++ b/Zend/tests/bug31683.phpt @@ -1,7 +1,5 @@ --TEST-- Bug #31683 (changes to $name in __get($name) override future parameters) ---SKIPIF-- - --FILE-- Date: Tue, 6 Sep 2011 15:49:28 +0000 Subject: [PATCH 0834/2394] - useless skipif --- ext/standard/tests/strings/sha1_file.phpt | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/ext/standard/tests/strings/sha1_file.phpt b/ext/standard/tests/strings/sha1_file.phpt index 3013adc34c721..574d384c2058c 100644 --- a/ext/standard/tests/strings/sha1_file.phpt +++ b/ext/standard/tests/strings/sha1_file.phpt @@ -1,17 +1,5 @@ --TEST-- Test sha1_file() function with ASCII output and raw binary output. Based on ext/standard/tests/strings/md5_file.phpt ---SKIPIF-- - Date: Tue, 6 Sep 2011 16:13:03 +0000 Subject: [PATCH 0835/2394] More parenthesis, credits to Nikita Popov --- ext/mysqli/tests/connect.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/connect.inc b/ext/mysqli/tests/connect.inc index 41bd1c1e9342b..3a9d8ec258c8c 100644 --- a/ext/mysqli/tests/connect.inc +++ b/ext/mysqli/tests/connect.inc @@ -224,7 +224,7 @@ function have_innodb($link) { if (($res = $link->query("SHOW VARIABLES LIKE 'have_innodb'")) && - $row = $res->fetch_row() && + ($row = $res->fetch_row()) && !empty($row)) { if ($row[1] == "DISABLED" || $row[1] == "NO") { return false; From 6277b2857a500f362e5e2873116e45951efba547 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 6 Sep 2011 16:30:53 +0000 Subject: [PATCH 0836/2394] Fixing SKIPIF fatal error. 6.0 is history, thus SKIPIF might need further updates? --- ext/phar/tests/fopen_edgecases2.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/phar/tests/fopen_edgecases2.phpt b/ext/phar/tests/fopen_edgecases2.phpt index 872aa289bc94c..d55c97d228bb0 100644 --- a/ext/phar/tests/fopen_edgecases2.phpt +++ b/ext/phar/tests/fopen_edgecases2.phpt @@ -2,7 +2,7 @@ Phar: test edge cases of fopen() function interception #2 --SKIPIF-- -=')) die('skip parameter parsing changed in 6.0'); ?> +=')) die('skip parameter parsing changed in 6.0'); ?> --INI-- phar.readonly=0 --FILE-- From 696a1bdc0737c5016d829493daf4fab72f169ca8 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 6 Sep 2011 16:37:45 +0000 Subject: [PATCH 0837/2394] Fixing SKIPIF --- ext/posix/tests/posix_getpgid_error.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/posix/tests/posix_getpgid_error.phpt b/ext/posix/tests/posix_getpgid_error.phpt index e703b8fdc15a2..b15a3c39b2a1c 100644 --- a/ext/posix/tests/posix_getpgid_error.phpt +++ b/ext/posix/tests/posix_getpgid_error.phpt @@ -2,7 +2,7 @@ Test posix_getpgid() function : error conditions --SKIPIF-- From fca3b40d7b9f41252c1c436f049de4bb01e07f02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Tue, 6 Sep 2011 16:38:22 +0000 Subject: [PATCH 0838/2394] - Fix bug #55609 (mysqlnd cannot be built shared) # This adds an option --enable-mysqlnd to explicitly built mysqlnd, like any # other extension it can be used with =shared to build mysqlnd shared; # mysqlnd will implicitly enabled when requested from another extension --- ext/mysqlnd/config9.m4 | 9 ++++++--- ext/mysqlnd/php_mysqlnd.c | 5 +++++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/ext/mysqlnd/config9.m4 b/ext/mysqlnd/config9.m4 index d335a2af6cd2f..1152dbce26972 100644 --- a/ext/mysqlnd/config9.m4 +++ b/ext/mysqlnd/config9.m4 @@ -2,6 +2,9 @@ dnl dnl $Id$ dnl config.m4 for mysqlnd driver +PHP_ARG_ENABLE(mysqlnd, whether to enable mysqlnd, + [ --enable-mysqlnd Enable mysqlnd expliciely, will be done implicitly + when required by other extensions], no, yes) PHP_ARG_ENABLE(mysqlnd_compression_support, whether to disable compressed protocol support in mysqlnd, [ --disable-mysqlnd-compression-support @@ -13,7 +16,7 @@ if test -z "$PHP_ZLIB_DIR"; then fi dnl If some extension uses mysqlnd it will get compiled in PHP core -if test "$PHP_MYSQLND_ENABLED" = "yes"; then +if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes"; then mysqlnd_ps_sources="mysqlnd_ps.c mysqlnd_ps_codec.c" mysqlnd_base_sources="mysqlnd.c mysqlnd_alloc.c mysqlnd_bt.c mysqlnd_charset.c mysqlnd_wireprotocol.c \ mysqlnd_loaddata.c mysqlnd_net.c \ @@ -28,12 +31,12 @@ if test "$PHP_MYSQLND_ENABLED" = "yes"; then AC_DEFINE([MYSQLND_SSL_SUPPORTED], 1, [Enable SSL support]) mysqlnd_sources="$mysqlnd_base_sources $mysqlnd_ps_sources" - PHP_NEW_EXTENSION(mysqlnd, $mysqlnd_sources, no) + PHP_NEW_EXTENSION(mysqlnd, $mysqlnd_sources, $ext_shared) PHP_ADD_BUILD_DIR([ext/mysqlnd], 1) PHP_INSTALL_HEADERS([ext/mysqlnd/]) fi -if test "$PHP_MYSQLND_ENABLED" = "yes" || test "$PHP_MYSQLI" != "no"; then +if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes" || test "$PHP_MYSQLI" != "no"; then PHP_ADD_BUILD_DIR([ext/mysqlnd], 1) dnl This creates a file so it has to be after above macros diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index e687d1fc407fb..7147e6f4a7373 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -366,6 +366,11 @@ zend_module_entry mysqlnd_module_entry = { }; /* }}} */ +/* {{{ COMPILE_DL_MYSQLND */ +#ifdef COMPILE_DL_MYSQLND +ZEND_GET_MODULE(mysqlnd) +#endif +/* }}} */ /* * Local variables: From 1c7a318421f2ba78e0977ce4f0817b167914a144 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Tue, 6 Sep 2011 16:39:55 +0000 Subject: [PATCH 0839/2394] Fixing SKIPIF --- ext/posix/tests/posix_getpgid_variation.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/posix/tests/posix_getpgid_variation.phpt b/ext/posix/tests/posix_getpgid_variation.phpt index 34a4beb0a9bef..e53d58f393df8 100644 --- a/ext/posix/tests/posix_getpgid_variation.phpt +++ b/ext/posix/tests/posix_getpgid_variation.phpt @@ -2,7 +2,7 @@ Test posix_getpgid() function : variation --SKIPIF-- From d37605a5f12cb0f0b395a8362d3a758f7e238e83 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 17:10:16 +0000 Subject: [PATCH 0840/2394] - useless skipif --- ext/standard/tests/strings/md5_file.phpt | Bin 3159 -> 2824 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/standard/tests/strings/md5_file.phpt b/ext/standard/tests/strings/md5_file.phpt index 879cd59aa33becb4cdc4abe55ac65adff4c3620f..f7c6297b019c4ba7be11b312b1101fe6b8356548 100644 GIT binary patch delta 21 dcmcaE(IGa$XLBFpD^5nP$-3-zlaFvu1^`$M2c!T1 delta 355 zcmZ9|ze>bF5C(7yEp7`-u^dC-61XU-{fFWOf>#K(LRgbovykkr$plY4y(=w+G`@zu zjL#ryZ|O#m3zpyPZ$EbSapP_CX)-@QjnCpJ2-x1C$qi$!;grKZWU^AcL@!CAcrs2B zf0wx#C!Ppdpgnhf;m)`;bQ{^xHciRtn{bIv?7g0m0=7KQ6~>CW&<2&atRBJeX6XAc zn?Xmqmj5LDGjPWMFwHeMT|K0_DKb!+;L?T)IbjB)994>dQ%O=?fv9u|gf*qSM#zpD z1kzwC3@W^CWGx9na9K1JUMRcJJril6YxJOdu>FNz47>aie+|}GURU22gXhoh;|GVa L_G9g!ZCLvQ720z# From eea14c09fcf7618e1301d75c6c482b004e92c9e9 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 6 Sep 2011 17:41:08 +0000 Subject: [PATCH 0841/2394] - fix #55622, mem corruption on large input --- ext/standard/basic_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 9b704f1838b07..b70939789e62e 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -5938,7 +5938,7 @@ PHP_FUNCTION(parse_ini_file) PHP_FUNCTION(parse_ini_string) { char *string = NULL, *str = NULL; - int str_len = 0; + size_t str_len = 0; zend_bool process_sections = 0; long scanner_mode = ZEND_INI_SCANNER_NORMAL; zend_ini_parser_cb_t ini_parser_cb; From a226fcc15e2aaff2e066d1fc16b2193f63fdfc8b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 6 Sep 2011 19:51:35 +0000 Subject: [PATCH 0842/2394] improve open_basedir handling --- ext/mysql/tests/mysql_query_load_data_openbasedir.phpt | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt index c2685a572e9df..339d36c934984 100644 --- a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt +++ b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt @@ -3,11 +3,6 @@ LOAD DATA INFILE - open_basedir --SKIPIF-- ---INI-- -open_basedir="." --FILE-- Date: Tue, 6 Sep 2011 19:52:19 +0000 Subject: [PATCH 0843/2394] Fix problems with the unbuffered set detection, for libmysql, which resulted in always true. Thanks Stas. --- ext/mysqli/mysqli_libmysql.h | 4 ++-- ext/mysqli/tests/bug55582.phpt | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/ext/mysqli/mysqli_libmysql.h b/ext/mysqli/mysqli_libmysql.h index 98e18fcfcda4e..c3f6de583b05f 100644 --- a/ext/mysqli/mysqli_libmysql.h +++ b/ext/mysqli/mysqli_libmysql.h @@ -29,8 +29,8 @@ #define MYSQLND_OPT_INT_AND_YEAR_AS_INT 201 /* r->data should be always NULL, at least in recent libmysql versions, the status changes once data is read*/ -#define mysqli_result_is_unbuffered(r) (((r)->handle && (r)->handle->status == MYSQL_STATUS_USE_RESULT) || ((r)->data == NULL)) -#define mysqli_result_is_unbuffered_and_not_everything_is_fetched(r) (((r)->handle && (r)->handle->status == MYSQL_STATUS_USE_RESULT) || ((r)->data == NULL)) +#define mysqli_result_is_unbuffered(r) ((r)->handle && (r)->handle->status == MYSQL_STATUS_USE_RESULT && (r)->data == NULL) +#define mysqli_result_is_unbuffered_and_not_everything_is_fetched(r) mysqli_result_is_unbuffered(r) #define mysqli_server_status(c) (c)->server_status #define mysqli_stmt_get_id(s) ((s)->stmt_id) #define mysqli_stmt_warning_count(s) mysql_warning_count((s)->mysql) diff --git a/ext/mysqli/tests/bug55582.phpt b/ext/mysqli/tests/bug55582.phpt index 5b38f3f803eda..393384514739b 100644 --- a/ext/mysqli/tests/bug55582.phpt +++ b/ext/mysqli/tests/bug55582.phpt @@ -5,7 +5,6 @@ Bug #55582 mysqli_num_rows() returns always 0 for unbuffered, when mysqlnd is us require_once('skipif.inc'); require_once('skipifconnectfailure.inc'); require_once("connect.inc"); -if(!$IS_MYSQLND) die("skip This bug is for mysqlnd only"); ?> --FILE-- Date: Wed, 7 Sep 2011 00:59:10 +0000 Subject: [PATCH 0844/2394] fix skipif description --- ext/spl/tests/DirectoryIterator_getExtension_basic.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt b/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt index 6d5d5e62ce42a..7398d4b9d2627 100644 --- a/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt +++ b/ext/spl/tests/DirectoryIterator_getExtension_basic.phpt @@ -3,7 +3,7 @@ SPL: DirectoryIterator::getExtension() basic test --SKIPIF-- --FILE-- From 0b16d13352af9ec9d532b5001c722a85f9032598 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 7 Sep 2011 05:14:54 +0000 Subject: [PATCH 0845/2394] Fixed Bug #55423(cli-server could not output correctly in some case) --- sapi/cli/php_cli_server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 65ed42d7d99cd..f8ce39a833ace 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1542,7 +1542,7 @@ static size_t php_cli_server_client_send_through(php_cli_server_client *client, struct timeval tv = { 10, 0 }; ssize_t nbytes_left = str_len; do { - ssize_t nbytes_sent = send(client->sock, str, str_len, 0); + ssize_t nbytes_sent = send(client->sock, str + str_len - nbytes_left, nbytes_left, 0); if (nbytes_sent < 0) { int err = php_socket_errno(); if (err == EAGAIN) { From 1f347459fb9047e7e21126ce7a34cde75785bf09 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 7 Sep 2011 05:19:12 +0000 Subject: [PATCH 0846/2394] update news --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index 9c4f389a80d3f..1ce640aa352d7 100644 --- a/NEWS +++ b/NEWS @@ -250,5 +250,6 @@ PHP NEWS - Fixed bug #55471 (ZTS build broken with dtrace). (Laruence) - Fixed bug #55463 (cli-server missing _SERVER[REMOTE_ADDR]). (Laruence) - Fixed bug #55473 (mysql_pconnect leaks file descriptors on reconnect). (Andrey, Laruence) +- Fixed bug #55423 (cli-server could not output correctly in some case). (Laruence, chobieee at gmail dot com) <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From a447acdcc6f12ea3a5dcd22416cb033e62995935 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Wed, 7 Sep 2011 06:46:27 +0000 Subject: [PATCH 0847/2394] Commit Gustavo's closure rebinding patch as desided by vote --- Zend/tests/closure_036.phpt | 4 +- Zend/tests/closure_038.phpt | 58 ++++++++++ Zend/tests/closure_039.phpt | 58 ++++++++++ Zend/tests/closure_040.phpt | 45 ++++++++ Zend/tests/closure_041.phpt | 106 ++++++++++++++++++ Zend/tests/closure_042.phpt | 29 +++++ Zend/tests/closure_043.phpt | 86 ++++++++++++++ Zend/tests/closure_044.phpt | 78 +++++++++++++ Zend/tests/closure_045.phpt | 19 ++++ Zend/tests/closure_046.phpt | 70 ++++++++++++ Zend/zend_closures.c | 89 ++++++++++----- ext/reflection/php_reflection.c | 22 ++++ ...flectionFunction_getClosureScopeClass.phpt | 31 +++++ 13 files changed, 668 insertions(+), 27 deletions(-) create mode 100644 Zend/tests/closure_038.phpt create mode 100644 Zend/tests/closure_039.phpt create mode 100644 Zend/tests/closure_040.phpt create mode 100644 Zend/tests/closure_041.phpt create mode 100644 Zend/tests/closure_042.phpt create mode 100644 Zend/tests/closure_043.phpt create mode 100644 Zend/tests/closure_044.phpt create mode 100644 Zend/tests/closure_045.phpt create mode 100644 Zend/tests/closure_046.phpt create mode 100644 ext/reflection/tests/ReflectionFunction_getClosureScopeClass.phpt diff --git a/Zend/tests/closure_036.phpt b/Zend/tests/closure_036.phpt index 0f8ccb1eda7c0..77d7ce6906bc7 100755 --- a/Zend/tests/closure_036.phpt +++ b/Zend/tests/closure_036.phpt @@ -1,5 +1,5 @@ --TEST-- -Closure 036: Rebinding closures +Closure 036: Rebinding closures, keep calling scope --FILE-- getIncrementor(); $cb = $ca->bindTo($b); -$cb2 = Closure::bind($b, $ca); +$cb2 = Closure::bind($ca, $b); var_dump($ca()); var_dump($cb()); diff --git a/Zend/tests/closure_038.phpt b/Zend/tests/closure_038.phpt new file mode 100644 index 0000000000000..fef0734786440 --- /dev/null +++ b/Zend/tests/closure_038.phpt @@ -0,0 +1,58 @@ +--TEST-- +Closure 038: Rebinding closures, change scope, different runtime type +--FILE-- +x = $v; + } + + public function getIncrementor() { + return function() { return ++$this->x; }; + } +} +class B extends A { + private $x; + public function __construct($v) { + parent::__construct($v); + $this->x = $v*2; + } +} + +$a = new A(0); +$b = new B(10); + +$ca = $a->getIncrementor(); +var_dump($ca()); + +echo "Testing with scope given as object", "\n"; + +$cb = $ca->bindTo($b, $b); +$cb2 = Closure::bind($ca, $b, $b); +var_dump($cb()); +var_dump($cb2()); + +echo "Testing with scope as string", "\n"; + +$cb = $ca->bindTo($b, 'B'); +$cb2 = Closure::bind($ca, $b, 'B'); +var_dump($cb()); +var_dump($cb2()); + +$cb = $ca->bindTo($b, NULL); +var_dump($cb()); + +?> +--EXPECTF-- +int(1) +Testing with scope given as object +int(21) +int(22) +Testing with scope as string +int(23) +int(24) + +Fatal error: Cannot access private property B::$x in %s on line %d diff --git a/Zend/tests/closure_039.phpt b/Zend/tests/closure_039.phpt new file mode 100644 index 0000000000000..c6a727c0fa539 --- /dev/null +++ b/Zend/tests/closure_039.phpt @@ -0,0 +1,58 @@ +--TEST-- +Closure 039: Rebinding closures, change scope, same runtime type +--FILE-- +x = $v; + } + + public function getIncrementor() { + return function() { return ++$this->x; }; + } +} +class B extends A { + private $x; + public function __construct($v) { + parent::__construct($v); + $this->x = $v*2; + } +} + +$a = new B(-5); +$b = new B(10); + +$ca = $a->getIncrementor(); +var_dump($ca()); + +echo "Testing with scope given as object", "\n"; + +$cb = $ca->bindTo($b, $b); +$cb2 = Closure::bind($ca, $b, $b); +var_dump($cb()); +var_dump($cb2()); + +echo "Testing with scope as string", "\n"; + +$cb = $ca->bindTo($b, 'B'); +$cb2 = Closure::bind($ca, $b, 'B'); +var_dump($cb()); +var_dump($cb2()); + +$cb = $ca->bindTo($b, NULL); +var_dump($cb()); + +?> +--EXPECTF-- +int(-4) +Testing with scope given as object +int(21) +int(22) +Testing with scope as string +int(23) +int(24) + +Fatal error: Cannot access private property B::$x in %s on line %d diff --git a/Zend/tests/closure_040.phpt b/Zend/tests/closure_040.phpt new file mode 100644 index 0000000000000..a1b6cd604af2d --- /dev/null +++ b/Zend/tests/closure_040.phpt @@ -0,0 +1,45 @@ +--TEST-- +Closure 040: Rebinding closures, bad arguments +--FILE-- +x = $v; + } + + public function getIncrementor() { + return function() { return ++$this->x; }; + } + public function getStaticIncrementor() { + return static function() { return ++static::$xs; }; + } +} + +$a = new A(20); + +$ca = $a->getIncrementor(); +$cas = $a->getStaticIncrementor(); + +$ca->bindTo($a, array()); +$ca->bindTo(array(), 'A'); +$ca->bindTo($a, array(), ""); +$ca->bindTo(); +$cas->bindTo($a, 'A'); + +?> +--EXPECTF-- +Notice: Array to string conversion in %s on line %d + +Warning: Class 'Array' not found in %s on line %d + +Warning: Closure::bindTo() expects parameter 1 to be object, array given in %s on line 25 + +Warning: Closure::bindTo() expects at most 2 parameters, 3 given in %s on line %d + +Warning: Closure::bindTo() expects at least 1 parameter, 0 given in %s on line %d + +Warning: Cannot bind an instance to a static closure in %s on line %d diff --git a/Zend/tests/closure_041.phpt b/Zend/tests/closure_041.phpt new file mode 100644 index 0000000000000..79cf9f3380c37 --- /dev/null +++ b/Zend/tests/closure_041.phpt @@ -0,0 +1,106 @@ +--TEST-- +Closure 041: Rebinding: preservation of previous scope when not given as arg unless impossible +--FILE-- +getStaticClosure(); +$nonstaticScoped = $a->getClosure(); + +echo "Before binding", "\n"; +$staticUnscoped(); echo "\n"; +$nonstaticUnscoped(); echo "\n"; +$staticScoped(); echo "\n"; +$nonstaticScoped(); echo "\n"; + +echo "After binding, no instance", "\n"; +$d = $staticUnscoped->bindTo(null); $d(); echo "\n"; +$d = $nonstaticUnscoped->bindTo(null); $d(); echo "\n"; +$d = $staticScoped->bindTo(null); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(null); $d(); echo "\n"; +//$d should have been turned to static +$d->bindTo($d); + +echo "After binding, with same-class instance for the bound ones", "\n"; +$d = $staticUnscoped->bindTo(new A); $d(); echo "\n"; +$d = $nonstaticUnscoped->bindTo(new A); $d(); echo " (should be scoped to dummy class)\n"; +$d = $staticScoped->bindTo(new A); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(new A); $d(); echo "\n"; + +echo "After binding, with different instance for the bound ones", "\n"; +$d = $nonstaticUnscoped->bindTo(new B); $d(); echo " (should be scoped to dummy class)\n"; +$d = $nonstaticScoped->bindTo(new B); $d(); echo "\n"; + +echo "Done.\n"; + +--EXPECTF-- +Before binding +scoped to A: bool(false) +bound: no +scoped to A: bool(false) +bound: no +scoped to A: bool(true) +bound: no +scoped to A: bool(true) +bound: A +After binding, no instance +scoped to A: bool(false) +bound: no +scoped to A: bool(false) +bound: no +scoped to A: bool(true) +bound: no +scoped to A: bool(true) +bound: no + +Warning: Cannot bind an instance to a static closure in %s on line %d +After binding, with same-class instance for the bound ones + +Warning: Cannot bind an instance to a static closure in %s on line %d +scoped to A: bool(false) +bound: no +scoped to A: bool(false) +bound: A (should be scoped to dummy class) + +Warning: Cannot bind an instance to a static closure in %s on line %d +scoped to A: bool(true) +bound: no +scoped to A: bool(true) +bound: A +After binding, with different instance for the bound ones +scoped to A: bool(false) +bound: B (should be scoped to dummy class) +scoped to A: bool(true) +bound: B +Done. \ No newline at end of file diff --git a/Zend/tests/closure_042.phpt b/Zend/tests/closure_042.phpt new file mode 100644 index 0000000000000..8969765bcd9c7 --- /dev/null +++ b/Zend/tests/closure_042.phpt @@ -0,0 +1,29 @@ +--TEST-- +Closure 042: Binding an instance to a non-scoped non-static closures gives it a dummy scope +--SKIPIF-- + +--FILE-- +bindTo(new stdClass); +$d(); +$rm = new ReflectionFunction($d); +var_dump($rm->getClosureScopeClass()->name); //dummy sope is Closure + +//should have the same effect +$d = $c->bindTo(new stdClass, NULL); +$d(); +$rm = new ReflectionFunction($d); +var_dump($rm->getClosureScopeClass()->name); //dummy sope is Closure + +echo "Done.\n"; + +--EXPECTF-- +object(stdClass)#%d (0) { +} +string(7) "Closure" +object(stdClass)#%d (0) { +} +string(7) "Closure" +Done. diff --git a/Zend/tests/closure_043.phpt b/Zend/tests/closure_043.phpt new file mode 100644 index 0000000000000..98c88fda39719 --- /dev/null +++ b/Zend/tests/closure_043.phpt @@ -0,0 +1,86 @@ +--TEST-- +Closure 043: Scope/bounding combination invariants; static closures +--FILE-- +bindTo(null, null); $d(); echo "\n"; +$d = $staticScoped->bindTo(null, null); $d(); echo "\n"; + +echo "After binding, null scope, with instance", "\n"; +$d = $staticUnscoped->bindTo(new A, null); $d(); echo "\n"; +$d = $staticScoped->bindTo(new A, null); $d(); echo "\n"; + +echo "After binding, with scope, no instance", "\n"; +$d = $staticUnscoped->bindTo(null, 'A'); $d(); echo "\n"; +$d = $staticScoped->bindTo(null, 'A'); $d(); echo "\n"; + +echo "After binding, with scope, with instance", "\n"; +$d = $staticUnscoped->bindTo(new A, 'A'); $d(); echo "\n"; +$d = $staticScoped->bindTo(new A, 'A'); $d(); echo "\n"; + +echo "Done.\n"; + +--EXPECTF-- +Before binding +bool(false) +bool(false) + +bool(true) +bool(false) + +After binding, null scope, no instance +bool(false) +bool(false) + +bool(false) +bool(false) + +After binding, null scope, with instance + +Warning: Cannot bind an instance to a static closure in %s on line %d +bool(false) +bool(false) + + +Warning: Cannot bind an instance to a static closure in %s on line %d +bool(false) +bool(false) + +After binding, with scope, no instance +bool(true) +bool(false) + +bool(true) +bool(false) + +After binding, with scope, with instance + +Warning: Cannot bind an instance to a static closure in %s on line %d +bool(true) +bool(false) + + +Warning: Cannot bind an instance to a static closure in %s on line %d +bool(true) +bool(false) + +Done. diff --git a/Zend/tests/closure_044.phpt b/Zend/tests/closure_044.phpt new file mode 100644 index 0000000000000..d2644c0401f5b --- /dev/null +++ b/Zend/tests/closure_044.phpt @@ -0,0 +1,78 @@ +--TEST-- +Closure 044: Scope/bounding combination invariants; non static closures +--FILE-- +getClosure(); + +echo "Before binding", "\n"; +$nonstaticUnscoped(); echo "\n"; +$nonstaticScoped(); echo "\n"; + +echo "After binding, null scope, no instance", "\n"; +$d = $nonstaticUnscoped->bindTo(null, null); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(null, null); $d(); echo "\n"; + +echo "After binding, null scope, with instance", "\n"; +$d = $nonstaticUnscoped->bindTo(new A, null); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(new A, null); $d(); echo "\n"; + +echo "After binding, with scope, no instance", "\n"; +$d = $nonstaticUnscoped->bindTo(null, 'A'); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(null, 'A'); $d(); echo "\n"; + +echo "After binding, with scope, with instance", "\n"; +$d = $nonstaticUnscoped->bindTo(new A, 'A'); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(new A, 'A'); $d(); echo "\n"; + +echo "Done.\n"; + +--EXPECTF-- +Before binding +bool(false) +bool(false) + +bool(true) +bool(true) + +After binding, null scope, no instance +bool(false) +bool(false) + +bool(false) +bool(false) + +After binding, null scope, with instance +bool(false) +bool(true) + +bool(false) +bool(true) + +After binding, with scope, no instance +bool(true) +bool(false) + +bool(true) +bool(false) + +After binding, with scope, with instance +bool(true) +bool(true) + +bool(true) +bool(true) + +Done. diff --git a/Zend/tests/closure_045.phpt b/Zend/tests/closure_045.phpt new file mode 100644 index 0000000000000..4115691761c93 --- /dev/null +++ b/Zend/tests/closure_045.phpt @@ -0,0 +1,19 @@ +--TEST-- +Closure 045: Closures created in static methods are static, even without the keyword +--FILE-- +bindTo(new A); + +echo "Done.\n"; + +--EXPECTF-- +Warning: Cannot bind an instance to a static closure in %s on line %d +Done. diff --git a/Zend/tests/closure_046.phpt b/Zend/tests/closure_046.phpt new file mode 100644 index 0000000000000..30a9d3e1b1022 --- /dev/null +++ b/Zend/tests/closure_046.phpt @@ -0,0 +1,70 @@ +--TEST-- +Closure 046: Rebinding: preservation of previous scope when "static" given as scope arg (same as closure #041) +--FILE-- +getClosure(); + +echo "Before binding", "\n"; +$nonstaticUnscoped(); echo "\n"; +$nonstaticScoped(); echo "\n"; + +echo "After binding, no instance", "\n"; +$d = $nonstaticUnscoped->bindTo(null, "static"); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(null, "static"); $d(); echo "\n"; +//$d should have been turned to static +$d->bindTo($d); + +echo "After binding, with same-class instance for the bound one", "\n"; +$d = $nonstaticUnscoped->bindTo(new A, "static"); $d(); echo "\n"; +$d = $nonstaticScoped->bindTo(new A, "static"); $d(); echo "\n"; + +echo "After binding, with different instance for the bound one", "\n"; +$d = $nonstaticScoped->bindTo(new B, "static"); $d(); echo "\n"; + +echo "Done.\n"; + +--EXPECTF-- +Before binding +bool(false) +bool(false) + +bool(true) +bool(true) + +After binding, no instance +bool(false) +bool(false) + +bool(true) +bool(false) + + +Warning: Cannot bind an instance to a static closure in %s on line %d +After binding, with same-class instance for the bound one +bool(false) +bool(true) + +bool(true) +bool(true) + +After binding, with different instance for the bound one +bool(true) +bool(true) + +Done. diff --git a/Zend/zend_closures.c b/Zend/zend_closures.c index 3ea3eba783e49..46f9c67036926 100644 --- a/Zend/zend_closures.c +++ b/Zend/zend_closures.c @@ -76,39 +76,67 @@ ZEND_METHOD(Closure, __invoke) /* {{{ */ } /* }}} */ -/* {{{ proto Closure Closure::bindTo(object $to) - Bind a closure to another object */ -ZEND_METHOD(Closure, bindTo) /* {{{ */ +/* {{{ proto Closure Closure::bind(Closure $old, object $to [, mixed $scope = "static" ] ) + Create a closure from another one and bind to another object and scope */ +ZEND_METHOD(Closure, bind) /* {{{ */ { - zval *newthis; - zend_closure *closure = (zend_closure *)zend_object_store_get_object(getThis() TSRMLS_CC); + zval *newthis, *zclosure, *scope_arg = NULL; + zend_closure *closure; + zend_class_entry *ce, **ce_p; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o!", &newthis) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oo!|z", &zclosure, zend_ce_closure, &newthis, &scope_arg) == FAILURE) { RETURN_NULL(); } - zend_create_closure(return_value, &closure->func, newthis?Z_OBJCE_P(newthis):NULL, newthis TSRMLS_CC); -} -/* }}} */ - -/* {{{ proto Closure Closure::bind(object $to, Closure $old) - Create a closure to with binding to another object */ -ZEND_METHOD(Closure, bind) /* {{{ */ -{ - zval *newthis, *zclosure; - zend_closure *closure; + closure = (zend_closure *)zend_object_store_get_object(zclosure TSRMLS_CC); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o!O", &newthis, &zclosure, zend_ce_closure) == FAILURE) { - RETURN_NULL(); + if ((newthis != NULL) && (closure->func.common.fn_flags & ZEND_ACC_STATIC)) { + zend_error(E_WARNING, "Cannot bind an instance to a static closure"); } - closure = (zend_closure *)zend_object_store_get_object(zclosure TSRMLS_CC); + if (scope_arg != NULL) { /* scope argument was given */ + if (IS_ZEND_STD_OBJECT(*scope_arg)) { + ce = Z_OBJCE_P(scope_arg); + } else if (Z_TYPE_P(scope_arg) == IS_NULL) { + ce = NULL; + } else { + char *class_name; + int class_name_len; + zval tmp_zval; + INIT_ZVAL(tmp_zval); + + if (Z_TYPE_P(scope_arg) == IS_STRING) { + class_name = Z_STRVAL_P(scope_arg); + class_name_len = Z_STRLEN_P(scope_arg); + } else { + tmp_zval = *scope_arg; + zval_copy_ctor(&tmp_zval); + convert_to_string(&tmp_zval); + class_name = Z_STRVAL(tmp_zval); + class_name_len = Z_STRLEN(tmp_zval); + } + + if ((class_name_len == sizeof("static") - 1) && + (memcmp("static", class_name, sizeof("static") - 1) == 0)) { + ce = closure->func.common.scope; + } + else if (zend_lookup_class_ex(class_name, class_name_len, NULL, 1, &ce_p TSRMLS_CC) == FAILURE) { + zend_error(E_WARNING, "Class '%s' not found", class_name); + zval_dtor(&tmp_zval); + RETURN_NULL(); + } else { + ce = *ce_p; + } + zval_dtor(&tmp_zval); + } + } else { /* scope argument not given; do not change the scope by default */ + ce = closure->func.common.scope; + } - zend_create_closure(return_value, &closure->func, newthis?Z_OBJCE_P(newthis):NULL, newthis TSRMLS_CC); + zend_create_closure(return_value, &closure->func, ce, newthis TSRMLS_CC); } /* }}} */ - static zend_function *zend_closure_get_constructor(zval *object TSRMLS_DC) /* {{{ */ { zend_error(E_RECOVERABLE_ERROR, "Instantiation of 'Closure' is not allowed"); @@ -356,19 +384,21 @@ ZEND_METHOD(Closure, __construct) } /* }}} */ -ZEND_BEGIN_ARG_INFO_EX(arginfo_closure_bindto, 0, 0, 0) +ZEND_BEGIN_ARG_INFO_EX(arginfo_closure_bindto, 0, 0, 1) ZEND_ARG_INFO(0, newthis) + ZEND_ARG_INFO(0, newscope) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_closure_bind, 0, 0, 0) - ZEND_ARG_INFO(0, newthis) +ZEND_BEGIN_ARG_INFO_EX(arginfo_closure_bind, 0, 0, 2) ZEND_ARG_INFO(0, closure) + ZEND_ARG_INFO(0, newthis) + ZEND_ARG_INFO(0, newscope) ZEND_END_ARG_INFO() static const zend_function_entry closure_functions[] = { ZEND_ME(Closure, __construct, NULL, ZEND_ACC_PRIVATE) - ZEND_ME(Closure, bindTo, arginfo_closure_bindto, ZEND_ACC_PUBLIC) ZEND_ME(Closure, bind, arginfo_closure_bind, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) + ZEND_MALIAS(Closure, bindTo, bind, arginfo_closure_bindto, ZEND_ACC_PUBLIC) {NULL, NULL, NULL} }; @@ -409,6 +439,12 @@ ZEND_API void zend_create_closure(zval *res, zend_function *func, zend_class_ent closure->func = *func; closure->func.common.prototype = NULL; + if ((scope == NULL) && (this_ptr != NULL)) { + /* use dummy scope if we're binding an object without specifying a scope */ + /* maybe it would be better to create one for this purpose */ + scope = zend_ce_closure; + } + if (closure->func.type == ZEND_USER_FUNCTION) { if (closure->func.op_array.static_variables) { HashTable *static_variables = closure->func.op_array.static_variables; @@ -439,6 +475,9 @@ ZEND_API void zend_create_closure(zval *res, zend_function *func, zend_class_ent } } + /* Invariants: + * If the closure is unscoped, it has no bound object. + * The the closure is scoped, it's either static or it's bound */ closure->func.common.scope = scope; if (scope) { closure->func.common.fn_flags |= ZEND_ACC_PUBLIC; diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 1dd8d4a8a2488..628f492a21503 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -1670,6 +1670,27 @@ ZEND_METHOD(reflection_function, getClosureThis) } /* }}} */ +/* {{{ proto public ReflectionClass ReflectionFunction::getClosureScopeClass() + Returns the scope associated to the closure */ +ZEND_METHOD(reflection_function, getClosureScopeClass) +{ + reflection_object *intern; + zend_function *fptr; + const zend_function *closure_func; + + if (zend_parse_parameters_none() == FAILURE) { + return; + } + GET_REFLECTION_OBJECT_PTR(fptr); + if (intern->obj) { + closure_func = zend_get_closure_method_def(intern->obj TSRMLS_CC); + if (closure_func && closure_func->common.scope) { + zend_reflection_class_factory(closure_func->common.scope, return_value TSRMLS_CC); + } + } +} +/* }}} */ + /* {{{ proto public mixed ReflectionFunction::getClosure() Returns a dynamically created closure for the function */ ZEND_METHOD(reflection_function, getClosure) @@ -5574,6 +5595,7 @@ static const zend_function_entry reflection_function_abstract_functions[] = { ZEND_ME(reflection_function, isInternal, arginfo_reflection__void, 0) ZEND_ME(reflection_function, isUserDefined, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getClosureThis, arginfo_reflection__void, 0) + ZEND_ME(reflection_function, getClosureScopeClass, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getDocComment, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getEndLine, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getExtension, arginfo_reflection__void, 0) diff --git a/ext/reflection/tests/ReflectionFunction_getClosureScopeClass.phpt b/ext/reflection/tests/ReflectionFunction_getClosureScopeClass.phpt new file mode 100644 index 0000000000000..f725dfd08893b --- /dev/null +++ b/ext/reflection/tests/ReflectionFunction_getClosureScopeClass.phpt @@ -0,0 +1,31 @@ +--TEST-- +Reflection::getClosureScopeClass() +--SKIPIF-- + +--FILE-- +getClosureScopeClass()); + +Class A { + public static function getClosure() { + return function($param) { return "this is a closure"; }; + } +} + +$closure = A::getClosure(); +$rf = new ReflectionFunction($closure); +var_dump($rf->getClosureScopeClass()); +echo "Done!\n"; +--EXPECTF-- +NULL +object(ReflectionClass)#%d (1) { + ["name"]=> + string(1) "A" +} +Done! From 3586902e6f5e144c012b0314a7fbab5d21b78503 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 07:51:37 +0000 Subject: [PATCH 0848/2394] - force LF From 8c38867dbaca44a766dff36776262edfe396b754 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 08:01:19 +0000 Subject: [PATCH 0849/2394] - force LF From e2ac1fc38653baa0edfc58fe8beac78fac16284b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 08:12:08 +0000 Subject: [PATCH 0850/2394] - add skipif for dom --- ext/simplexml/tests/bug51615.phpt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/simplexml/tests/bug51615.phpt b/ext/simplexml/tests/bug51615.phpt index e0229943131f3..c96b3ae7cad91 100644 --- a/ext/simplexml/tests/bug51615.phpt +++ b/ext/simplexml/tests/bug51615.phpt @@ -1,7 +1,9 @@ --TEST-- Bug #51615 (PHP crash with wrong HTML in SimpleXML) --SKIPIF-- - + --FILE-- Date: Wed, 7 Sep 2011 08:18:20 +0000 Subject: [PATCH 0851/2394] - force LF From f4ccae7206fb2699d308e864675163787409eab4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 08:41:59 +0000 Subject: [PATCH 0852/2394] - force LF From e63aa705a355b4cb6f0ebf12bff5e3b164ebf850 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 09:03:07 +0000 Subject: [PATCH 0853/2394] - fix test for OS where dir sep is \ --- ext/dom/tests/dom_xinclude.phpt | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ext/dom/tests/dom_xinclude.phpt b/ext/dom/tests/dom_xinclude.phpt index 686a9e81aac3f..5d8906e316c9a 100644 --- a/ext/dom/tests/dom_xinclude.phpt +++ b/ext/dom/tests/dom_xinclude.phpt @@ -10,10 +10,14 @@ in_array('compress.zlib', stream_get_wrappers()) or die('skip compress.zlib wrap $dom = new domdocument; $data = file_get_contents(dirname(__FILE__)."/xinclude.xml"); -$data = str_replace('compress.zlib://ext/dom/tests/','compress.zlib://'.dirname(__FILE__).'/', $data); +$reldir = str_replace(getcwd(),".",dirname(__FILE__)); +if (DIRECTORY_SEPARATOR == '\\') { + $reldir = str_replace('\\',"/", $reldir); +} +$data = str_replace('compress.zlib://ext/dom/tests/','compress.zlib://'.$reldir."/", $data); -$dom->loadXML($data); +$dom->loadXML($data); $dom->xinclude(); print $dom->saveXML()."\n"; foreach ($dom->documentElement->childNodes as $node) { From 5a14cd627d075a4cb41351e5aa0e634e682664a0 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 09:19:28 +0000 Subject: [PATCH 0854/2394] - fix test for OS where dir sep is \ --- ext/xmlreader/tests/012.phpt | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/ext/xmlreader/tests/012.phpt b/ext/xmlreader/tests/012.phpt index e420bb7a17a82..e0edeef2dd514 100755 --- a/ext/xmlreader/tests/012.phpt +++ b/ext/xmlreader/tests/012.phpt @@ -25,7 +25,9 @@ $xmlstring =<<XML($xmlstring); $reader->setParserProperty(XMLReader::DEFAULTATTRS, true); @@ -34,12 +36,15 @@ var_dump($reader->getAttribute('bar')); var_dump($reader->getAttribute('baz')); $reader->close(); -?> -===FILE=== -open(dirname(__FILE__) . '/012.xml'); +$file = dirname(__FILE__) . '/012.xml'; +if (DIRECTORY_SEPARATOR == '\\') { + $file = str_replace('\\',"/", $file); +} + +$reader->open($file); + //$reader->setParserProperty(XMLReader::DEFAULTATTRS, true); while($reader->read() && $reader->nodeType != XMLReader::ELEMENT); var_dump($reader->getAttribute('bar')); @@ -61,7 +66,8 @@ string(0) "" NULL string(0) "" string(0) "" -===FILE=== + +Using URI: string(0) "" NULL string(0) "" From 194e5fa60c90950a13627db5b95a9c9208dc5e85 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 09:37:56 +0000 Subject: [PATCH 0855/2394] - force LF From bbfc53d7be91a367088015af26388a1f5fadd64b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 09:41:54 +0000 Subject: [PATCH 0856/2394] - force LF From ecee2129db6bef4c2c138a1dd37b923a72da52c1 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 10:12:04 +0000 Subject: [PATCH 0857/2394] - force LF (svn prop and config) From e57b66393be0cac1884cf536aa367bc802c175f1 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 10:14:02 +0000 Subject: [PATCH 0858/2394] - force LF (svn prop and config) --- ext/tidy/tests/010.phpt | 12 ++++++------ ext/tidy/tests/012.phpt | 2 +- ext/tidy/tests/024.phpt | 3 ++- ext/tidy/tests/025.phpt | 6 +++--- 4 files changed, 12 insertions(+), 11 deletions(-) diff --git a/ext/tidy/tests/010.phpt b/ext/tidy/tests/010.phpt index eabbc0391ff80..9d5ab825a0bd0 100644 --- a/ext/tidy/tests/010.phpt +++ b/ext/tidy/tests/010.phpt @@ -4,12 +4,12 @@ Accessing root, body, html, and head nodes.. --FILE-- "); - var_dump($a->root()); - var_dump($a->body()); - var_dump($a->html()); - var_dump($a->head()); - +$a = tidy_parse_string("", array('newline' => 'LF')); +var_dump($a->root()); +var_dump($a->body()); +var_dump($a->html()); +var_dump($a->head()); + ?> --EXPECT-- object(tidyNode)#2 (8) { diff --git a/ext/tidy/tests/012.phpt b/ext/tidy/tests/012.phpt index 43fff38df589e..1205812333e89 100644 --- a/ext/tidy/tests/012.phpt +++ b/ext/tidy/tests/012.phpt @@ -25,7 +25,7 @@ Accessing children nodes } - $a = tidy_parse_string("HiByeTest"); + $a = tidy_parse_string("HiByeTest", array('newline' => 'LF')); $html = $a->html(); dump_nodes($html); diff --git a/ext/tidy/tests/024.phpt b/ext/tidy/tests/024.phpt index f69b962aee7d6..b09f5b4643482 100644 --- a/ext/tidy/tests/024.phpt +++ b/ext/tidy/tests/024.phpt @@ -18,7 +18,8 @@ $contents = ' '; $config = array( -'new-blocklevel-tags' => 'wps:block,wps:var,wps:value' +'new-blocklevel-tags' => 'wps:block,wps:var,wps:value', +'newline' => 'LF' ); $tidy = tidy_parse_string($contents, $config, 'utf8'); diff --git a/ext/tidy/tests/025.phpt b/ext/tidy/tests/025.phpt index 631ec2e5e9609..df9392eb2f58e 100644 --- a/ext/tidy/tests/025.phpt +++ b/ext/tidy/tests/025.phpt @@ -5,16 +5,16 @@ tidyNode tests --FILE-- '); +$tidy=tidy_parse_string('<% %>', array('newline' => 'LF')); var_dump($tidy->Root()->child[0]->isAsp()); -$tidy=tidy_parse_string('<# #>'); +$tidy=tidy_parse_string('<# #>', array('newline' => 'LF')); var_dump($tidy->Root()->child[0]->isJste()); $tidy=tidy_parse_string('text'); var_dump($tidy->Root()->child[0]->child[1]->child[0]->isText()); -$tidy=tidy_parse_string(''); +$tidy=tidy_parse_string('', array('newline' => 'LF')); $n = $tidy->Root()->child[0]->child[1]->child[0]; var_dump($n->isComment()); var_dump((string)$n); From 3f85bc95f7e9b449f61ca2940c93d1467382c764 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 7 Sep 2011 10:34:58 +0000 Subject: [PATCH 0859/2394] Update skipif message --- ext/curl/tests/curl_CURLOPT_READDATA.phpt | 2 +- ext/curl/tests/curl_basic_011.phpt | 3 ++- ext/curl/tests/curl_copy_handle_basic_001.phpt | 4 ++-- ext/curl/tests/curl_copy_handle_basic_002.phpt | 2 +- ext/curl/tests/curl_copy_handle_basic_004.phpt | 4 ++-- ext/curl/tests/curl_copy_handle_basic_005.phpt | 2 +- ext/curl/tests/curl_copy_handle_basic_006.phpt | 2 +- ext/curl/tests/curl_copy_handle_basic_007.phpt | 2 +- ext/curl/tests/curl_setopt_basic002.phpt | 2 +- ext/curl/tests/curl_setopt_basic003.phpt | 2 +- ext/curl/tests/curl_setopt_basic004.phpt | 2 +- ext/curl/tests/curl_version_error.phpt | 5 ++++- ext/curl/tests/curl_version_variation1.phpt | 7 +++++-- ext/curl/tests/curl_writeheader_callback.phpt | 9 ++++++++- 14 files changed, 31 insertions(+), 17 deletions(-) diff --git a/ext/curl/tests/curl_CURLOPT_READDATA.phpt b/ext/curl/tests/curl_CURLOPT_READDATA.phpt index 00f3ea95ab473..ea63d445ac4a6 100644 --- a/ext/curl/tests/curl_CURLOPT_READDATA.phpt +++ b/ext/curl/tests/curl_CURLOPT_READDATA.phpt @@ -4,7 +4,7 @@ Test CURLOPT_READDATA without a callback function Mattijs Hoitink mattijshoitink@gmail.com #Testfest Utrecht 2009 --SKIPIF-- - + --FILE-- --SKIPIF-- - + --FILE-- *** Testing curl with cookie *** string(3) "bar" ===DONE=== + diff --git a/ext/curl/tests/curl_copy_handle_basic_001.phpt b/ext/curl/tests/curl_copy_handle_basic_001.phpt index db4bf02332b11..f1b4db3ce5f43 100644 --- a/ext/curl/tests/curl_copy_handle_basic_001.phpt +++ b/ext/curl/tests/curl_copy_handle_basic_001.phpt @@ -4,7 +4,7 @@ Test curl_copy_handle() with simple get Rick Buitenman #testfest Utrecht 2009 --SKIPIF-- - + --FILE-- #testfest Utrecht 2009 --SKIPIF-- - + --FILE-- #testfest Utrecht 2009 --SKIPIF-- - + --FILE-- #testfest Utrecht 2009 --SKIPIF-- - + --FILE-- #testfest Utrecht 2009 --SKIPIF-- - + --FILE-- + --FILE-- + --FILE-- + --FILE-- + --FILE-- --FILE-- --FILE-- diff --git a/ext/curl/tests/curl_writeheader_callback.phpt b/ext/curl/tests/curl_writeheader_callback.phpt index ae0075c848d6c..fa27363a4151a 100644 --- a/ext/curl/tests/curl_writeheader_callback.phpt +++ b/ext/curl/tests/curl_writeheader_callback.phpt @@ -6,7 +6,14 @@ Dutch UG, TestFest 2009, Utrecht --DESCRIPTION-- Hit the host identified by PHP_CURL_HTTP_REMOTE_SERVER and determine that the headers are sent to the callback specified for CURLOPT_HEADERFUNCTION. Different test servers specified for PHP_CURL_HTTP_REMOTE_SERVER might return different sets of headers. Just test for HTTP/1.1 200 OK. --SKIPIF-- - + --FILE-- Date: Wed, 7 Sep 2011 10:38:53 +0000 Subject: [PATCH 0860/2394] Sync tests between branches and fix the getcontent test --- ext/curl/tests/curl_basic_011.phpt | 2 +- ext/curl/tests/curl_basic_012.phpt | 3 ++- ext/curl/tests/curl_basic_013.phpt | 3 ++- ext/curl/tests/curl_multi_getcontent_basic3.phpt | 3 ++- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/ext/curl/tests/curl_basic_011.phpt b/ext/curl/tests/curl_basic_011.phpt index 16e460e2203d5..10c90b123a96f 100644 --- a/ext/curl/tests/curl_basic_011.phpt +++ b/ext/curl/tests/curl_basic_011.phpt @@ -35,4 +35,4 @@ TestFest 2009 - AFUP - Xavier Gorse *** Testing curl with cookie *** string(3) "bar" ===DONE=== - + diff --git a/ext/curl/tests/curl_basic_012.phpt b/ext/curl/tests/curl_basic_012.phpt index 2cfa7b38ed4be..e4706fad46122 100644 --- a/ext/curl/tests/curl_basic_012.phpt +++ b/ext/curl/tests/curl_basic_012.phpt @@ -3,7 +3,7 @@ Test curl_opt() function with CURLOPT_HTTP_VERSION/CURL_HTTP_VERSION_1_0 --CREDITS-- TestFest 2009 - AFUP - Xavier Gorse --SKIPIF-- - + --FILE-- *** Testing curl with HTTP/1.0 *** string(8) "HTTP/1.0" ===DONE=== + \ No newline at end of file diff --git a/ext/curl/tests/curl_basic_013.phpt b/ext/curl/tests/curl_basic_013.phpt index bc396e11e79e4..c49d187be3117 100644 --- a/ext/curl/tests/curl_basic_013.phpt +++ b/ext/curl/tests/curl_basic_013.phpt @@ -3,7 +3,7 @@ Test curl_opt() function with CURLOPT_HTTP_VERSION/CURL_HTTP_VERSION_1_1 --CREDITS-- TestFest 2009 - AFUP - Xavier Gorse --SKIPIF-- - + --FILE-- *** Testing curl with HTTP/1.1 *** string(8) "HTTP/1.1" ===DONE=== + \ No newline at end of file diff --git a/ext/curl/tests/curl_multi_getcontent_basic3.phpt b/ext/curl/tests/curl_multi_getcontent_basic3.phpt index bf17ab6b606c0..0e448cd2e9d7f 100644 --- a/ext/curl/tests/curl_multi_getcontent_basic3.phpt +++ b/ext/curl/tests/curl_multi_getcontent_basic3.phpt @@ -5,7 +5,7 @@ Rein Velt (rein@velt.org) #TestFest Utrecht 20090509 --SKIPIF-- --FILE-- Date: Wed, 7 Sep 2011 10:39:55 +0000 Subject: [PATCH 0861/2394] Update skipif --- ext/imap/tests/imap_utf8_to_mutf7_basic.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/imap/tests/imap_utf8_to_mutf7_basic.phpt b/ext/imap/tests/imap_utf8_to_mutf7_basic.phpt index 6598be0d25f38..54b43efaeca29 100644 --- a/ext/imap/tests/imap_utf8_to_mutf7_basic.phpt +++ b/ext/imap/tests/imap_utf8_to_mutf7_basic.phpt @@ -1,8 +1,8 @@ --TEST-- imap_utf8_to_mutf7 --SKIPIF-- - - + + --FILE-- Date: Wed, 7 Sep 2011 10:41:38 +0000 Subject: [PATCH 0862/2394] The error message is different when built with zts --- ext/standard/tests/file/tempnam_variation7.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/tests/file/tempnam_variation7.phpt b/ext/standard/tests/file/tempnam_variation7.phpt index b21a123ab7774..b6f81caabcb84 100644 --- a/ext/standard/tests/file/tempnam_variation7.phpt +++ b/ext/standard/tests/file/tempnam_variation7.phpt @@ -98,13 +98,13 @@ File created in => temp dir Warning: tempnam() expects parameter 1 to be a valid path, string given in %s on line %d -- File is not created -- -Warning: unlink(): No such file or directory in %s on line %d +Warning: unlink(): %s in %s on line %d -- Iteration 7 -- Warning: tempnam() expects parameter 1 to be a valid path, array given in %s on line %d -- File is not created -- -Warning: unlink(): No such file or directory in %s on line %d +Warning: unlink(): %s in %s on line %d -- Iteration 8 -- File name is => %s/tempnam_variation3.tmp%s File permissions are => 100600 From a953f69ed622a8e541881d200c4bbcf374f7baed Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 7 Sep 2011 10:44:32 +0000 Subject: [PATCH 0863/2394] Remove bogus skipif and make adjust the tests --- Zend/tests/bug39304.phpt | 9 ++++++--- Zend/tests/isset_003.phpt | 6 ++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/Zend/tests/bug39304.phpt b/Zend/tests/bug39304.phpt index 03916fd0fa85e..ea068df75dfc6 100755 --- a/Zend/tests/bug39304.phpt +++ b/Zend/tests/bug39304.phpt @@ -1,13 +1,16 @@ --TEST-- Bug #39304 (Segmentation fault with list unpacking of string offset) ---SKIPIF-- -=')) die('skip ZendEngine 2.4 needed'); ?> --FILE-- --EXPECTF-- Notice: Uninitialized string offset: 0 in %sbug39304.php on line 3 -Fatal error: Cannot use string offset as an array in %sbug39304.php on line 3 +Notice: Uninitialized string offset: 1 in %sbug39304.php on line 3 + +Notice: Uninitialized string offset: 0 in %sbug39304.php on line 3 +I am alive + diff --git a/Zend/tests/isset_003.phpt b/Zend/tests/isset_003.phpt index 8232405bee9b4..4db42a933b6b7 100644 --- a/Zend/tests/isset_003.phpt +++ b/Zend/tests/isset_003.phpt @@ -1,7 +1,5 @@ --TEST-- Testing isset accessing undefined array itens and properties ---SKIPIF-- -=')) die('skip ZendEngine 2.3 or below needed'); ?> --FILE-- Date: Wed, 7 Sep 2011 11:26:59 +0000 Subject: [PATCH 0864/2394] - skip on win, diff TZ format --- ext/soap/tests/schema/schema064.phpt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/soap/tests/schema/schema064.phpt b/ext/soap/tests/schema/schema064.phpt index 53e1b257be909..899a2938fa8fd 100644 --- a/ext/soap/tests/schema/schema064.phpt +++ b/ext/soap/tests/schema/schema064.phpt @@ -1,7 +1,11 @@ --TEST-- SOAP XML Schema 64: standard date/time types --SKIPIF-- - + --FILE-- Date: Wed, 7 Sep 2011 12:05:19 +0000 Subject: [PATCH 0865/2394] Fix cleanup routines --- ext/spl/tests/SplFileInfo_getGroup_basic.phpt | 4 ++-- ext/spl/tests/SplFileInfo_getOwner_basic.phpt | 4 ++-- ext/spl/tests/SplFileObject_fputcsv.phpt | 3 ++- ext/standard/tests/file/bug55124.phpt | 2 +- ext/zip/tests/bug53885.phpt | 5 +++++ 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/ext/spl/tests/SplFileInfo_getGroup_basic.phpt b/ext/spl/tests/SplFileInfo_getGroup_basic.phpt index c5808c57d9edf..d279935637049 100644 --- a/ext/spl/tests/SplFileInfo_getGroup_basic.phpt +++ b/ext/spl/tests/SplFileInfo_getGroup_basic.phpt @@ -10,7 +10,7 @@ Jacopo Romei #Test Fest Cesena (Italy) on 2009-06-20 --FILE-- --CLEAN-- --EXPECTF-- diff --git a/ext/spl/tests/SplFileInfo_getOwner_basic.phpt b/ext/spl/tests/SplFileInfo_getOwner_basic.phpt index 790dcc69ba058..3df8e4858b1b4 100644 --- a/ext/spl/tests/SplFileInfo_getOwner_basic.phpt +++ b/ext/spl/tests/SplFileInfo_getOwner_basic.phpt @@ -10,7 +10,7 @@ Jacopo Romei #Test Fest Cesena (Italy) on 2009-06-20 --FILE-- --CLEAN-- --EXPECTF-- diff --git a/ext/spl/tests/SplFileObject_fputcsv.phpt b/ext/spl/tests/SplFileObject_fputcsv.phpt index 2a42d57479b9c..66fdbfd1b9be5 100644 --- a/ext/spl/tests/SplFileObject_fputcsv.phpt +++ b/ext/spl/tests/SplFileObject_fputcsv.phpt @@ -2,7 +2,7 @@ SplFileObject::fputcsv(): functionality tests --FILE-- --CLEAN-- --EXPECT-- diff --git a/ext/standard/tests/file/bug55124.phpt b/ext/standard/tests/file/bug55124.phpt index 892d4508d898f..1915b7f209761 100644 --- a/ext/standard/tests/file/bug55124.phpt +++ b/ext/standard/tests/file/bug55124.phpt @@ -8,7 +8,7 @@ mkdir('a/./b', 0755, true); if (is_dir('a/b')) { rmdir('a/b'); } -if (is_dir('/a')) { +if (is_dir('./a')) { rmdir('a'); } chdir($old_dir_path); diff --git a/ext/zip/tests/bug53885.phpt b/ext/zip/tests/bug53885.phpt index d59bf8f034139..1b3fcb9e4bcc4 100644 --- a/ext/zip/tests/bug53885.phpt +++ b/ext/zip/tests/bug53885.phpt @@ -15,5 +15,10 @@ $nx->locateName("a",ZIPARCHIVE::FL_UNCHANGED); $nx->statName("a",ZIPARCHIVE::FL_UNCHANGED); ?> ==DONE== +--CLEAN-- + --EXPECTF-- ==DONE== From 4efd9c43a93a749cc4f95400101728b1e88aed35 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 7 Sep 2011 12:06:21 +0000 Subject: [PATCH 0866/2394] Add skip message --- tests/lang/034.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/lang/034.phpt b/tests/lang/034.phpt index dcb5436e2fd8f..5d2c6109262e3 100644 --- a/tests/lang/034.phpt +++ b/tests/lang/034.phpt @@ -5,7 +5,7 @@ precision=14 --SKIPIF-- --FILE-- From 6b4717da8e0477030c9f7d0bb82032128f90347b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 7 Sep 2011 12:33:22 +0000 Subject: [PATCH 0867/2394] - reject paths with trainling spaces using the very good new zend arg --- Zend/zend_API.c | 8 ++++++ .../tests/file/005_variation2-win32.phpt | 20 +++++--------- .../tests/file/copy_variation3-win32.phpt | 26 ++++++++++++------- .../tests/file/file_exists_variation1.phpt | 6 +++-- .../file_get_contents_variation8-win32.phpt | 26 +++++++++---------- .../file_put_contents_variation8-win32.phpt | 16 ++++++------ .../tests/file/filegroup_variation2.phpt | 14 +++++----- .../tests/file/fileinode_variation2.phpt | 15 +++++------ .../tests/file/fileowner_variation2.phpt | 15 +++++------ .../tests/file/fileperms_variation2.phpt | 14 +++++----- .../tests/file/filesize_variation5.phpt | 6 ++--- .../tests/file/is_dir_variation3.phpt | 6 +++-- .../tests/file/is_file_variation3.phpt | 6 +++-- .../tests/file/is_readable_variation3.phpt | 6 +++-- .../tests/file/is_writable_variation3.phpt | 13 ++++++---- .../tests/file/lstat_stat_variation22.phpt | 14 +++++----- .../tests/file/mkdir_variation1-win32.phpt | 18 ++++++------- .../tests/file/popen_pclose_basic-win32.phpt | 7 ++++- .../file/readfile_variation10-win32.phpt | 21 ++++++++------- .../tests/file/realpath_variation-win32.phpt | 21 +++++++++------ .../tests/file/tempnam_variation7-win32.phpt | 25 ++++++++++-------- 21 files changed, 168 insertions(+), 135 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 5401483db7584..c83b3d0f0e121 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -438,6 +438,14 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha if (c == 'p' && CHECK_ZVAL_NULL_PATH(*arg)) { return "a valid path"; } +#ifdef PHP_WIN32 + if (c == 'p') { + /* do not allow trailing space (or single, */ + if (Z_STRVAL_PP(arg)[0] == ' ' || Z_STRVAL_PP(arg)[Z_STRLEN_PP(arg) - 1] == ' ') { + return "a valid path"; + } + } +#endif break; case IS_OBJECT: diff --git a/ext/standard/tests/file/005_variation2-win32.phpt b/ext/standard/tests/file/005_variation2-win32.phpt index 45dcbc5f071c3..3ae129ba75387 100644 --- a/ext/standard/tests/file/005_variation2-win32.phpt +++ b/ext/standard/tests/file/005_variation2-win32.phpt @@ -87,13 +87,13 @@ echo "Done"; -- File ' ' -- -- File access time is => -Warning: fileatime(): stat failed for in %s on line %d +Warning: fileatime() expects parameter 1 to be a valid path, string given in %s on line %d -- File modification time is => -Warning: filemtime(): stat failed for in %s on line %d +Warning: filemtime() expects parameter 1 to be a valid path, string given in %s on line %d -- inode change time is => -Warning: filectime(): stat failed for in %s on line %d +Warning: filectime() expects parameter 1 to be a valid path, string given in %s on line %d -- File '|' -- @@ -107,19 +107,13 @@ Warning: filemtime(): stat failed for | in %s on line %d Warning: filectime(): stat failed for | in %s on line %d -*** testing touch *** -Warning: touch(): %s in %s on line %d +*** testing touch ***bool(false) bool(false) - -Warning: touch(): %s in %s on line %d -bool(false) - -Warning: touch(): %s in %s on line %d bool(false) -Warning: touch(): %s in %s on line %d -bool(false) +Warning: touch() expects parameter 1 to be a valid path, string given in %s005_variation2-win32.php on line %d +NULL -Warning: touch(): %s in %s on line %d +Warning: touch(): Unable to create file | because Invalid argument in %s005_variation2-win32.php on line %d bool(false) Done diff --git a/ext/standard/tests/file/copy_variation3-win32.phpt b/ext/standard/tests/file/copy_variation3-win32.phpt index 68ce4a1680660..3972523778ddf 100644 --- a/ext/standard/tests/file/copy_variation3-win32.phpt +++ b/ext/standard/tests/file/copy_variation3-win32.phpt @@ -89,21 +89,29 @@ Size of source file => int(1500) Size of destination file => int(1500) -- Iteration 2 -- -Copy operation => bool(true) -Existence of destination file => bool(true) -Destination file name => copy_variation3.tmp -Size of source file => int(1500) -Size of destination file => int(1500) +Copy operation => +Warning: copy() expects parameter 2 to be a valid path, string given in %scopy_variation3-win32.php on line %d +NULL +Existence of destination file => +Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d +NULL + +Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d -- Iteration 3 -- Copy operation => -Warning: copy(%s): %s +Warning: copy(copy variation3.tmp): failed to open stream: Invalid argument in %scopy_variation3-win32.php on line %d bool(false) Existence of destination file => bool(false) -- Iteration 4 -- Copy operation => -Warning: copy(%s): %s -bool(false) -Existence of destination file => bool(false) +Warning: copy() expects parameter 2 to be a valid path, string given in %scopy_variation3-win32.php on line %d +NULL +Existence of destination file => +Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d +NULL + +Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d *** Done *** + diff --git a/ext/standard/tests/file/file_exists_variation1.phpt b/ext/standard/tests/file/file_exists_variation1.phpt index 35c86a2808b00..680d05ec777d5 100644 --- a/ext/standard/tests/file/file_exists_variation1.phpt +++ b/ext/standard/tests/file/file_exists_variation1.phpt @@ -25,6 +25,8 @@ echo "Done"; bool(false) bool(false) bool(false) + +Warning: file_exists() expects parameter 1 to be a valid path, string given in %sfile_exists_variation1.php on line %d +NULL bool(false) -bool(false) -Done \ No newline at end of file +Done diff --git a/ext/standard/tests/file/file_get_contents_variation8-win32.phpt b/ext/standard/tests/file/file_get_contents_variation8-win32.phpt index 43d742a67c8a9..eb7c74b7d8eef 100644 --- a/ext/standard/tests/file/file_get_contents_variation8-win32.phpt +++ b/ext/standard/tests/file/file_get_contents_variation8-win32.phpt @@ -47,51 +47,51 @@ foreach($names_arr as $key =>$value) { -- Filename: -1 -- -Warning: file_get_contents(-1): failed to open stream: No such file or directory in %s on line %d +Warning: file_get_contents(-1): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d bool(false) -- Filename: TRUE -- -Warning: file_get_contents(1): failed to open stream: No such file or directory in %s on line %d +Warning: file_get_contents(1): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d bool(false) -- Filename: FALSE -- -Warning: file_get_contents(): Filename cannot be empty in %s on line %d +Warning: file_get_contents(): Filename cannot be empty in %sfile_get_contents_variation8-win32.php on line %d bool(false) -- Filename: NULL -- -Warning: file_get_contents(): Filename cannot be empty in %s on line %d +Warning: file_get_contents(): Filename cannot be empty in %sfile_get_contents_variation8-win32.php on line %d bool(false) -- Filename: "" -- -Warning: file_get_contents(): Filename cannot be empty in %s on line %d +Warning: file_get_contents(): Filename cannot be empty in %sfile_get_contents_variation8-win32.php on line %d bool(false) -- Filename: " " -- -Warning: file_get_contents( ): failed to open stream: Permission denied in %s on line %d -bool(false) +Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %sfile_get_contents_variation8-win32.php on line %d +NULL -- Filename: \0 -- -Warning: file_get_contents(): Filename cannot be empty in %s on line %d -bool(false) +Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %sfile_get_contents_variation8-win32.php on line %d +NULL -- Filename: array() -- -Warning: file_get_contents() expects parameter 1 to be string, array given in %s on line %d +Warning: file_get_contents() expects parameter 1 to be a valid path, array given in %sfile_get_contents_variation8-win32.php on line %d NULL -- Filename: /no/such/file/dir -- -Warning: file_get_contents(/no/such/file/dir): failed to open stream: No such file or directory in %s on line %d +Warning: file_get_contents(/no/such/file/dir): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d bool(false) -- Filename: php/php -- -Warning: file_get_contents(php/php): failed to open stream: No such file or directory in %s on line %d +Warning: file_get_contents(php/php): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d bool(false) -===Done=== \ No newline at end of file +===Done=== diff --git a/ext/standard/tests/file/file_put_contents_variation8-win32.phpt b/ext/standard/tests/file/file_put_contents_variation8-win32.phpt index 92fe7b3d6af6f..8da6b3b851765 100644 --- a/ext/standard/tests/file/file_put_contents_variation8-win32.phpt +++ b/ext/standard/tests/file/file_put_contents_variation8-win32.phpt @@ -58,41 +58,41 @@ foreach($names_arr as $key =>$value) { -- Filename: FALSE -- -Warning: file_put_contents(): Filename cannot be empty in %s on line %d +Warning: file_put_contents(): Filename cannot be empty in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: FALSE -- Filename: NULL -- -Warning: file_put_contents(): Filename cannot be empty in %s on line %d +Warning: file_put_contents(): Filename cannot be empty in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: NULL -- Filename: "" -- -Warning: file_put_contents(): Filename cannot be empty in %s on line %d +Warning: file_put_contents(): Filename cannot be empty in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: "" -- Filename: " " -- -Warning: file_put_contents( ): failed to open stream: Permission denied in %s on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: " " -- Filename: \0 -- -Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %s on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: \0 -- Filename: array() -- -Warning: file_put_contents() expects parameter 1 to be a valid path, array given in %s on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, array given in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: array() -- Filename: /no/such/file/dir -- -Warning: file_put_contents(/no/such/file/dir): failed to open stream: %s in %s on line %d +Warning: file_put_contents(/no/such/file/dir): failed to open stream: No such file or directory in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: /no/such/file/dir -- Filename: php/php -- -Warning: file_put_contents(php/php): failed to open stream: %s in %s on line %d +Warning: file_put_contents(php/php): failed to open stream: No such file or directory in %sfile_put_contents_variation8-win32.php on line %d Failed to write data to: php/php ===Done=== diff --git a/ext/standard/tests/file/filegroup_variation2.phpt b/ext/standard/tests/file/filegroup_variation2.phpt index afac40c9ab029..6ccf7eb4ccb97 100644 --- a/ext/standard/tests/file/filegroup_variation2.phpt +++ b/ext/standard/tests/file/filegroup_variation2.phpt @@ -46,25 +46,25 @@ unlink($file_path."/filegroup_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: filegroup(): stat failed for -2.34555 in %s on line %d +Warning: filegroup(): stat failed for -2.34555 in %sfilegroup_variation2.php on line %d bool(false) -Warning: filegroup(): stat failed for in %s on line %d -bool(false) +Warning: filegroup() expects parameter 1 to be a valid path, string given in %sfilegroup_variation2.php on line %d +NULL bool(false) -Warning: filegroup(): stat failed for 1 in %s on line %d +Warning: filegroup(): stat failed for 1 in %sfilegroup_variation2.php on line %d bool(false) bool(false) bool(false) -Warning: filegroup() expects parameter 1 to be a valid path, resource given in %s on line %d +Warning: filegroup() expects parameter 1 to be a valid path, resource given in %sfilegroup_variation2.php on line %d NULL -Warning: filegroup(): stat failed for 1234 in %s on line %d +Warning: filegroup(): stat failed for 1234 in %sfilegroup_variation2.php on line %d bool(false) -Warning: filegroup(): stat failed for 0 in %s on line %d +Warning: filegroup(): stat failed for 0 in %sfilegroup_variation2.php on line %d bool(false) *** Done *** diff --git a/ext/standard/tests/file/fileinode_variation2.phpt b/ext/standard/tests/file/fileinode_variation2.phpt index e8e7af6a6e9a4..cb095773a9503 100644 --- a/ext/standard/tests/file/fileinode_variation2.phpt +++ b/ext/standard/tests/file/fileinode_variation2.phpt @@ -47,26 +47,25 @@ unlink($file_path."/fileinode_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: fileinode(): stat failed for -2.34555 in %s on line %d +Warning: fileinode(): stat failed for -2.34555 in %sfileinode_variation2.php on line %d bool(false) -Warning: fileinode(): stat failed for in %s on line %d -bool(false) +Warning: fileinode() expects parameter 1 to be a valid path, string given in %sfileinode_variation2.php on line %d +NULL bool(false) -Warning: fileinode(): stat failed for 1 in %s on line %d +Warning: fileinode(): stat failed for 1 in %sfileinode_variation2.php on line %d bool(false) bool(false) bool(false) -Warning: fileinode() expects parameter 1 to be a valid path, resource given in %s on line %d +Warning: fileinode() expects parameter 1 to be a valid path, resource given in %sfileinode_variation2.php on line %d NULL -Warning: fileinode(): stat failed for 1234 in %s on line %d +Warning: fileinode(): stat failed for 1234 in %sfileinode_variation2.php on line %d bool(false) -Warning: fileinode(): stat failed for 0 in %s on line %d +Warning: fileinode(): stat failed for 0 in %sfileinode_variation2.php on line %d bool(false) *** Done *** - diff --git a/ext/standard/tests/file/fileowner_variation2.phpt b/ext/standard/tests/file/fileowner_variation2.phpt index feff767879943..ed6b7e9021d92 100644 --- a/ext/standard/tests/file/fileowner_variation2.phpt +++ b/ext/standard/tests/file/fileowner_variation2.phpt @@ -47,26 +47,25 @@ unlink($file_path."/fileowner_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: fileowner(): stat failed for -2.34555 in %s on line %d +Warning: fileowner(): stat failed for -2.34555 in %sfileowner_variation2.php on line %d bool(false) -Warning: fileowner(): stat failed for in %s on line %d -bool(false) +Warning: fileowner() expects parameter 1 to be a valid path, string given in %sfileowner_variation2.php on line %d +NULL bool(false) -Warning: fileowner(): stat failed for 1 in %s on line %d +Warning: fileowner(): stat failed for 1 in %sfileowner_variation2.php on line %d bool(false) bool(false) bool(false) -Warning: fileowner() expects parameter 1 to be a valid path, resource given in %s on line %d +Warning: fileowner() expects parameter 1 to be a valid path, resource given in %sfileowner_variation2.php on line %d NULL -Warning: fileowner(): stat failed for 1234 in %s on line %d +Warning: fileowner(): stat failed for 1234 in %sfileowner_variation2.php on line %d bool(false) -Warning: fileowner(): stat failed for 0 in %s on line %d +Warning: fileowner(): stat failed for 0 in %sfileowner_variation2.php on line %d bool(false) *** Done *** - diff --git a/ext/standard/tests/file/fileperms_variation2.phpt b/ext/standard/tests/file/fileperms_variation2.phpt index 47c0c6593acfd..394cddcc85cf4 100644 --- a/ext/standard/tests/file/fileperms_variation2.phpt +++ b/ext/standard/tests/file/fileperms_variation2.phpt @@ -46,25 +46,25 @@ unlink($file_path."/fileperms_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: fileperms(): stat failed for -2.34555 in %s on line %d +Warning: fileperms(): stat failed for -2.34555 in %sfileperms_variation2.php on line %d bool(false) -Warning: fileperms(): stat failed for in %s on line %d -bool(false) +Warning: fileperms() expects parameter 1 to be a valid path, string given in %sfileperms_variation2.php on line %d +NULL bool(false) -Warning: fileperms(): stat failed for 1 in %s on line %d +Warning: fileperms(): stat failed for 1 in %sfileperms_variation2.php on line %d bool(false) bool(false) bool(false) -Warning: fileperms() expects parameter 1 to be a valid path, resource given in %s on line %d +Warning: fileperms() expects parameter 1 to be a valid path, resource given in %sfileperms_variation2.php on line %d NULL -Warning: fileperms(): stat failed for 1234 in %s on line %d +Warning: fileperms(): stat failed for 1234 in %sfileperms_variation2.php on line %d bool(false) -Warning: fileperms(): stat failed for 0 in %s on line %d +Warning: fileperms(): stat failed for 0 in %sfileperms_variation2.php on line %d bool(false) *** Done *** diff --git a/ext/standard/tests/file/filesize_variation5.phpt b/ext/standard/tests/file/filesize_variation5.phpt index 638f8ba8ed3d9..574dfe3a73558 100644 --- a/ext/standard/tests/file/filesize_variation5.phpt +++ b/ext/standard/tests/file/filesize_variation5.phpt @@ -26,9 +26,9 @@ bool(false) bool(false) bool(false) -Warning: filesize(): stat failed for in %s on line %d -bool(false) +Warning: filesize() expects parameter 1 to be a valid path, string given in %sfilesize_variation5.php on line %d +NULL -Warning: filesize(): stat failed for | in %s on line %d +Warning: filesize(): stat failed for | in %sfilesize_variation5.php on line %d bool(false) *** Done *** diff --git a/ext/standard/tests/file/is_dir_variation3.phpt b/ext/standard/tests/file/is_dir_variation3.phpt index 41826ad7ecd8c..c16059b6a02ab 100644 --- a/ext/standard/tests/file/is_dir_variation3.phpt +++ b/ext/standard/tests/file/is_dir_variation3.phpt @@ -40,9 +40,11 @@ bool(false) bool(false) bool(false) bool(false) -bool(false) -Warning: is_dir() expects parameter 1 to be a valid path, resource given in %s on line %d +%s: is_dir() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\is_dir_variation3.php on line %d +NULL + +%s: is_dir() expects parameter 1 to be a valid path, resource given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\is_dir_variation3.php on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/is_file_variation3.phpt b/ext/standard/tests/file/is_file_variation3.phpt index 2a13e4677924f..b80b715787192 100644 --- a/ext/standard/tests/file/is_file_variation3.phpt +++ b/ext/standard/tests/file/is_file_variation3.phpt @@ -45,13 +45,15 @@ unlink($file_path."/is_file_variation3.tmp"); --EXPECTF-- *** Testing Invalid file types *** bool(false) -bool(false) + +Warning: is_file() expects parameter 1 to be a valid path, string given in %sis_file_variation3.php on line %d +NULL bool(false) bool(false) bool(false) bool(false) -Warning: is_file() expects parameter 1 to be a valid path, resource given in %s on line %d +Warning: is_file() expects parameter 1 to be a valid path, resource given in %sis_file_variation3.php on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/is_readable_variation3.phpt b/ext/standard/tests/file/is_readable_variation3.phpt index dc4d3b16f394c..c9d96ef85a63b 100644 --- a/ext/standard/tests/file/is_readable_variation3.phpt +++ b/ext/standard/tests/file/is_readable_variation3.phpt @@ -59,9 +59,11 @@ bool(false) bool(false) bool(false) bool(false) -bool(false) -Warning: is_readable() expects parameter 1 to be a valid path, array given in %s on line %d +Warning: is_readable() expects parameter 1 to be a valid path, string given in %sis_readable_variation3.php on line %d +NULL + +Warning: is_readable() expects parameter 1 to be a valid path, array given in %sis_readable_variation3.php on line %d NULL bool(false) Done diff --git a/ext/standard/tests/file/is_writable_variation3.phpt b/ext/standard/tests/file/is_writable_variation3.phpt index 66a80abf1eece..986f076a83a1f 100644 --- a/ext/standard/tests/file/is_writable_variation3.phpt +++ b/ext/standard/tests/file/is_writable_variation3.phpt @@ -64,15 +64,18 @@ bool(false) bool(false) bool(false) bool(false) -bool(false) -bool(false) -Warning: is_writable() expects parameter 1 to be a valid path, array given in %s on line %d +Warning: is_writable() expects parameter 1 to be a valid path, string given in %sis_writable_variation3.php on line %d +NULL + +Warning: is_writeable() expects parameter 1 to be a valid path, string given in %sis_writable_variation3.php on line %d NULL -Warning: is_writeable() expects parameter 1 to be a valid path, array given in %s on line %d +Warning: is_writable() expects parameter 1 to be a valid path, array given in %sis_writable_variation3.php on line %d +NULL + +Warning: is_writeable() expects parameter 1 to be a valid path, array given in %sis_writable_variation3.php on line %d NULL bool(false) bool(false) Done - diff --git a/ext/standard/tests/file/lstat_stat_variation22.phpt b/ext/standard/tests/file/lstat_stat_variation22.phpt index c9072ce0131f0..332b651f1c8ad 100644 --- a/ext/standard/tests/file/lstat_stat_variation22.phpt +++ b/ext/standard/tests/file/lstat_stat_variation22.phpt @@ -31,19 +31,19 @@ bool(false) bool(false) bool(false) -Warning: stat(): stat failed for in %s on line %d -bool(false) +Warning: stat() expects parameter 1 to be a valid path, string given in %slstat_stat_variation22.php on line %d +NULL -Warning: stat(): stat failed for | in %s on line %d +Warning: stat(): stat failed for | in %slstat_stat_variation22.php on line %d bool(false) *** testing lstat *** bool(false) bool(false) bool(false) -Warning: lstat(): Lstat failed for in %s on line %d -bool(false) +Warning: lstat() expects parameter 1 to be a valid path, string given in %slstat_stat_variation22.php on line %d +NULL -Warning: lstat(): Lstat failed for | in %s on line %d +Warning: lstat(): Lstat failed for | in %slstat_stat_variation22.php on line %d bool(false) -Done \ No newline at end of file +Done diff --git a/ext/standard/tests/file/mkdir_variation1-win32.phpt b/ext/standard/tests/file/mkdir_variation1-win32.phpt index 17f54926cb5d6..dbb37319a9c6d 100644 --- a/ext/standard/tests/file/mkdir_variation1-win32.phpt +++ b/ext/standard/tests/file/mkdir_variation1-win32.phpt @@ -94,29 +94,29 @@ foreach($inputs as $key =>$value) { *** Testing mkdir() : usage variation *** --uppercase NULL-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --lowercase null-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --lowercase false-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --uppercase FALSE-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --empty string DQ-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --empty string SQ-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --undefined var-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --unset var-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) --single space-- -Error: 2 - mkdir(): %s, %s(%d) +Error: 2 - mkdir() expects parameter 1 to be a valid path, string given, %smkdir_variation1-win32.php(%d) ===DONE=== diff --git a/ext/standard/tests/file/popen_pclose_basic-win32.phpt b/ext/standard/tests/file/popen_pclose_basic-win32.phpt index 8c2ba4252d07b..b7eadabec1b34 100644 --- a/ext/standard/tests/file/popen_pclose_basic-win32.phpt +++ b/ext/standard/tests/file/popen_pclose_basic-win32.phpt @@ -47,7 +47,12 @@ echo "\n--- Done ---"; ?> --EXPECTF-- *** Testing popen(): reading from the pipe *** -Sample String + +Warning: popen() expects parameter 1 to be a valid path, string given in %spopen_pclose_basic-win32.php on line %d + +Warning: fpassthru() expects parameter 1 to be resource, null given in %spopen_pclose_basic-win32.php on line %d + +Warning: pclose() expects parameter 1 to be resource, null given in %spopen_pclose_basic-win32.php on line %d *** Testing popen(): writing to the pipe *** aaa ddd diff --git a/ext/standard/tests/file/readfile_variation10-win32.phpt b/ext/standard/tests/file/readfile_variation10-win32.phpt index 61f6aba7a5ecb..ac8869218e4c3 100644 --- a/ext/standard/tests/file/readfile_variation10-win32.phpt +++ b/ext/standard/tests/file/readfile_variation10-win32.phpt @@ -47,41 +47,42 @@ foreach($names_arr as $key => $value) { -- Filename: -1 -- -Warning: readfile(-1): failed to open stream: No such file or directory in %s on line %d +Warning: readfile(-1): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: TRUE -- -Warning: readfile(1): failed to open stream: No such file or directory in %s on line %d +Warning: readfile(1): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: FALSE -- -Warning: readfile(): Filename cannot be empty in %s on line %d +Warning: readfile(): Filename cannot be empty in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: NULL -- -Warning: readfile(): Filename cannot be empty in %s on line %d +Warning: readfile(): Filename cannot be empty in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: "" -- -Warning: readfile(): Filename cannot be empty in %s on line %d +Warning: readfile(): Filename cannot be empty in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: " " -- -Warning: readfile( ): failed to open stream: Permission denied in %s on line %d +Warning: readfile() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: \0 -- -Warning: readfile() expects parameter 1 to be a valid path, string given in %s on line %d +Warning: readfile() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: array() -- -Warning: readfile() expects parameter 1 to be a valid path, array given in %s on line %d +Warning: readfile() expects parameter 1 to be a valid path, array given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: /no/such/file/dir -- -Warning: readfile(/no/such/file/dir): failed to open stream: No such file or directory in %s on line %d +Warning: readfile(/no/such/file/dir): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 -- Filename: php/php -- -Warning: readfile(php/php): failed to open stream: No such file or directory in %s on line %d +Warning: readfile(php/php): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 ===Done=== + diff --git a/ext/standard/tests/file/realpath_variation-win32.phpt b/ext/standard/tests/file/realpath_variation-win32.phpt index 59db125fb9d2e..088ae108b131a 100644 --- a/ext/standard/tests/file/realpath_variation-win32.phpt +++ b/ext/standard/tests/file/realpath_variation-win32.phpt @@ -79,24 +79,29 @@ rmdir("$name_prefix/"); *** Testing realpath(): usage variations *** *** Testing realpath() with filename stored inside a object *** -string(%d) "%s\realpath_variation\home\tests\realpath_variation.tmp" +string(112) "G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation\home\tests\realpath_variation.tmp" bool(false) *** Testing realpath() with filename stored in an array *** -string(%d) "%s\realpath_variation\home\tests\realpath_variation.tmp" +string(112) "G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation\home\tests\realpath_variation.tmp" bool(false) *** Testing realpath() with filename as empty string, NULL and single space *** -- Iteration1 -- -bool(false) + +Warning: realpath() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation-win32.php on line 56 +NULL -- Iteration2 -- -bool(false) + +Warning: realpath() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation-win32.php on line 56 +NULL -- Iteration3 -- -string(%d) "%s" +string(35) "G:\php-sdk\php-src\branches\PHP_5_4" -- Iteration4 -- -string(%d) "%s" +string(35) "G:\php-sdk\php-src\branches\PHP_5_4" -- Iteration5 -- -string(%d) "%s" +string(35) "G:\php-sdk\php-src\branches\PHP_5_4" -- Iteration6 -- -string(%d) "%s" +string(35) "G:\php-sdk\php-src\branches\PHP_5_4" Done + diff --git a/ext/standard/tests/file/tempnam_variation7-win32.phpt b/ext/standard/tests/file/tempnam_variation7-win32.phpt index 2572f65d02de8..0194bd962443b 100644 --- a/ext/standard/tests/file/tempnam_variation7-win32.phpt +++ b/ext/standard/tests/file/tempnam_variation7-win32.phpt @@ -65,29 +65,31 @@ echo "\n*** Done ***\n"; --EXPECTF-- *** Testing tempnam() with invalid/non-existing directory names *** -- Iteration 0 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir -- Iteration 1 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir -- Iteration 2 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir -- Iteration 3 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir -- Iteration 4 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir -- Iteration 5 -- -File name is => %s%et%s -File permissions are => 100666 -File created in => temp dir + +Warning: tempnam() expects parameter 1 to be a valid path, string given in %stempnam_variation7-win32.php on line %d +-- File is not created -- + +Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 6 -- Warning: tempnam() expects parameter 1 to be a valid path, string given in %stempnam_variation7-win32.php on line %d @@ -96,18 +98,19 @@ Warning: tempnam() expects parameter 1 to be a valid path, string given in %stem Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 7 -- -Warning: tempnam() expects parameter 1 to be a valid path, array given in %s on line %d +Warning: tempnam() expects parameter 1 to be a valid path, array given in %stempnam_variation7-win32.php on line %d -- File is not created -- Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 8 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir -- Iteration 9 -- -File name is => %s%et%s +File name is => %s.tmp File permissions are => 100666 File created in => temp dir *** Done *** + From bea25b5e553147b39d9372be2d95c6a240b3dd6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 7 Sep 2011 13:33:56 +0000 Subject: [PATCH 0868/2394] - Use myslqnd by default when MySQL extensions are activated but no path given --- ext/mysql/config.m4 | 28 +++++++++++++--------------- ext/mysqli/config.m4 | 14 +++++--------- ext/pdo_mysql/config.m4 | 37 ++++++++++++++----------------------- 3 files changed, 32 insertions(+), 47 deletions(-) diff --git a/ext/mysql/config.m4 b/ext/mysql/config.m4 index 2babcee827dd0..fa7a46f8532f7 100644 --- a/ext/mysql/config.m4 +++ b/ext/mysql/config.m4 @@ -41,8 +41,8 @@ AC_DEFUN([PHP_MYSQL_SOCKET_SEARCH], [ PHP_ARG_WITH(mysql, for MySQL support, [ --with-mysql[=DIR] Include MySQL support. DIR is the MySQL base - directory. If mysqlnd is passed as DIR, - the MySQL native driver will be used [/usr/local]]) + directory, if no DIR is passed or the value is + mysqlnd the MySQL native driver will be used]) PHP_ARG_WITH(mysql-sock, for specified location of the MySQL UNIX socket, [ --with-mysql-sock[=DIR] MySQL/MySQLi/PDO_MYSQL: Location of the MySQL unix socket pointer. @@ -53,7 +53,7 @@ if test -z "$PHP_ZLIB_DIR"; then [ --with-zlib-dir[=DIR] MySQL: Set the path to libz install prefix], no, no) fi -if test "$PHP_MYSQL" = "mysqlnd"; then +if test "$PHP_MYSQL" = "yes" || test "$PHP_MYSQL" = "mysqlnd"; then dnl enables build of mysqnd library PHP_MYSQLND_ENABLED=yes @@ -61,17 +61,15 @@ elif test "$PHP_MYSQL" != "no"; then MYSQL_DIR= MYSQL_INC_DIR= - for i in $PHP_MYSQL /usr/local /usr; do - if test -r $i/include/mysql/mysql.h; then - MYSQL_DIR=$i - MYSQL_INC_DIR=$i/include/mysql - break - elif test -r $i/include/mysql.h; then - MYSQL_DIR=$i - MYSQL_INC_DIR=$i/include - break - fi - done + if test -r $PHP_MYSQL/include/mysql/mysql.h; then + MYSQL_DIR=$PHP_MYSQL + MYSQL_INC_DIR=$PHP_MYSQL/include/mysql + break + elif test -r $PHP_MYSQL/include/mysql.h; then + MYSQL_DIR=$PHP_MYSQL + MYSQL_INC_DIR=$PHP_MYSQL/include + break + fi if test -z "$MYSQL_DIR"; then AC_MSG_ERROR([Cannot find MySQL header files under $PHP_MYSQL. @@ -155,7 +153,7 @@ if test "$PHP_MYSQL" != "no"; then PHP_NEW_EXTENSION(mysql, php_mysql.c, $ext_shared) PHP_SUBST(MYSQL_SHARED_LIBADD) - if test "$PHP_MYSQL" = "mysqlnd"; then + if test "$PHP_MYSQL" = "yes" || test "$PHP_MYSQL" = "mysqlnd"; then PHP_ADD_EXTENSION_DEP(mysql, mysqlnd) AC_DEFINE([MYSQL_USE_MYSQLND], 1, [Whether mysqlnd is enabled]) fi diff --git a/ext/mysqli/config.m4 b/ext/mysqli/config.m4 index 12df1fa3f07c0..6ec9334639717 100644 --- a/ext/mysqli/config.m4 +++ b/ext/mysqli/config.m4 @@ -4,24 +4,20 @@ dnl config.m4 for extension mysqli PHP_ARG_WITH(mysqli, for MySQLi support, [ --with-mysqli[=FILE] Include MySQLi support. FILE is the path - to mysql_config. If mysqlnd is passed as FILE, - the MySQL native driver will be used [mysql_config]]) + to mysql_config. If no value or mysqlnd is passed + as FILE, the MySQL native driver will be used]) PHP_ARG_ENABLE(embedded_mysqli, whether to enable embedded MySQLi support, [ --enable-embedded-mysqli MYSQLi: Enable embedded support Note: Does not work with MySQL native driver!], no, no) -if test "$PHP_MYSQLI" = "mysqlnd"; then +if test "$PHP_MYSQLI" = "yes" || test "$PHP_MYSQLI" = "mysqlnd"; then dnl This needs to be set in any extension which wishes to use mysqlnd PHP_MYSQLND_ENABLED=yes elif test "$PHP_MYSQLI" != "no"; then - if test "$PHP_MYSQLI" = "yes"; then - MYSQL_CONFIG=`$php_shtool path mysql_config` - else - MYSQL_CONFIG=$PHP_MYSQLI - fi + MYSQL_CONFIG=$PHP_MYSQLI MYSQL_LIB_NAME='mysqlclient' if test "$PHP_EMBEDDED_MYSQLI" = "yes"; then @@ -82,7 +78,7 @@ if test "$PHP_MYSQLI" != "no"; then PHP_SUBST(MYSQLI_SHARED_LIBADD) PHP_INSTALL_HEADERS([ext/mysqli/php_mysqli_structs.h]) - if test "$PHP_MYSQLI" = "mysqlnd"; then + if test "$PHP_MYSQLI" = "yes" || test "$PHP_MYSQLI" = "mysqlnd"; then PHP_ADD_EXTENSION_DEP(mysqli, mysqlnd) AC_DEFINE([MYSQLI_USE_MYSQLND], 1, [Whether mysqlnd is enabled]) fi diff --git a/ext/pdo_mysql/config.m4 b/ext/pdo_mysql/config.m4 index 88742d2c8c379..a2ba2fdbdd583 100755 --- a/ext/pdo_mysql/config.m4 +++ b/ext/pdo_mysql/config.m4 @@ -4,8 +4,8 @@ dnl vim: se ts=2 sw=2 et: PHP_ARG_WITH(pdo-mysql, for MySQL support for PDO, [ --with-pdo-mysql[=DIR] PDO: MySQL support. DIR is the MySQL base directory - If mysqlnd is passed as DIR, the MySQL native - native driver will be used [/usr/local]]) + If no value or mysqlnd is passed as DIR, the + MySQL native driver will be used]) if test -z "$PHP_ZLIB_DIR"; then PHP_ARG_WITH(zlib-dir, for the location of libz, @@ -28,30 +28,21 @@ if test "$PHP_PDO_MYSQL" != "no"; then done ]) - if test -f $PHP_PDO_MYSQL && test -x $PHP_PDO_MYSQL ; then - PDO_MYSQL_CONFIG=$PHP_PDO_MYSQL - elif test "$PHP_PDO_MYSQL" != "yes"; then - if test -d "$PHP_PDO_MYSQL" ; then - if test -x "$PHP_PDO_MYSQL/bin/mysql_config" ; then - PDO_MYSQL_CONFIG="$PHP_PDO_MYSQL/bin/mysql_config" - else - PDO_MYSQL_DIR="$PHP_PDO_MYSQL" + if test "$PHP_PDO_MYSQL" != "yes" && test "$PHP_PDO_MYSQL" != "mysqlnd"; then + if test -f $PHP_PDO_MYSQL && test -x $PHP_PDO_MYSQL ; then + PDO_MYSQL_CONFIG=$PHP_PDO_MYSQL + else + if test -d "$PHP_PDO_MYSQL" ; then + if test -x "$PHP_PDO_MYSQL/bin/mysql_config" ; then + PDO_MYSQL_CONFIG="$PHP_PDO_MYSQL/bin/mysql_config" + else + PDO_MYSQL_DIR="$PHP_PDO_MYSQL" + fi fi fi - else - for i in /usr/local /usr ; do - if test -x "$i/bin/mysql_config" ; then - PDO_MYSQL_CONFIG="$i/bin/mysql_config" - break; - fi - if test -r $i/include/mysql/mysql.h || test -r $i/include/mysql.h ; then - PDO_MYSQL_DIR="$i" - break; - fi - done fi - - if test "$PHP_PDO_MYSQL" = "mysqlnd"; then + + if test "$PHP_PDO_MYSQL" = "yes" || test "$PHP_PDO_MYSQL" = "mysqlnd"; then dnl enables build of mysqnd library PHP_MYSQLND_ENABLED=yes AC_DEFINE([PDO_USE_MYSQLND], 1, [Whether pdo_mysql uses mysqlnd]) From a078c05513a2973ce4751d2fa66465723f4c641f Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 7 Sep 2011 13:46:45 +0000 Subject: [PATCH 0869/2394] Fix folding --- ext/standard/dl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/dl.c b/ext/standard/dl.c index b59cf58567483..80dae99e9b46e 100644 --- a/ext/standard/dl.c +++ b/ext/standard/dl.c @@ -97,9 +97,9 @@ PHPAPI PHP_FUNCTION(dl) #define USING_ZTS 0 #endif -/* {{{ php_dl +/* {{{ php_load_extension */ -PHPAPI int php_load_extension(char *filename, int type, int start_now TSRMLS_DC) /* {{{ */ +PHPAPI int php_load_extension(char *filename, int type, int start_now TSRMLS_DC) { void *handle; char *libpath; From 03d8301d7c57cbfafa1acb71efaebb375ee87d98 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 7 Sep 2011 13:47:31 +0000 Subject: [PATCH 0870/2394] Fix errormessage --- ext/pcntl/config.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/pcntl/config.m4 b/ext/pcntl/config.m4 index 636f50cc4e5dd..2ef07f140c0cb 100644 --- a/ext/pcntl/config.m4 +++ b/ext/pcntl/config.m4 @@ -7,7 +7,7 @@ PHP_ARG_ENABLE(pcntl, whether to enable pcntl support, if test "$PHP_PCNTL" != "no"; then AC_CHECK_FUNCS(fork, [ AC_DEFINE(HAVE_FORK,1,[ ]) ], [ AC_MSG_ERROR(pcntl: fork() not supported by this platform) ]) - AC_CHECK_FUNCS(waitpid, [ AC_DEFINE(HAVE_WAITPID,1,[ ]) ], [ AC_MSG_ERROR(pcntl: fork() not supported by this platform) ]) + AC_CHECK_FUNCS(waitpid, [ AC_DEFINE(HAVE_WAITPID,1,[ ]) ], [ AC_MSG_ERROR(pcntl: waitpid() not supported by this platform) ]) AC_CHECK_FUNCS(sigaction, [ AC_DEFINE(HAVE_SIGACTION,1,[ ]) ], [ AC_MSG_ERROR(pcntl: sigaction() not supported by this platform) ]) AC_CHECK_FUNCS([getpriority setpriority wait3 sigprocmask sigwaitinfo sigtimedwait]) PHP_NEW_EXTENSION(pcntl, pcntl.c php_signal.c, $ext_shared, cli) From 4e9a7658b8150e4bf1efa17f3e2720e163856e56 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Wed, 7 Sep 2011 13:50:18 +0000 Subject: [PATCH 0871/2394] Revert r316345 which fixes all the tests again --- Zend/zend_API.c | 8 ------ .../tests/file/005_variation2-win32.phpt | 20 +++++++++----- .../tests/file/copy_variation3-win32.phpt | 26 +++++++------------ .../tests/file/file_exists_variation1.phpt | 6 ++--- .../file_get_contents_variation8-win32.phpt | 26 +++++++++---------- .../file_put_contents_variation8-win32.phpt | 16 ++++++------ .../tests/file/filegroup_variation2.phpt | 14 +++++----- .../tests/file/fileinode_variation2.phpt | 15 ++++++----- .../tests/file/fileowner_variation2.phpt | 15 ++++++----- .../tests/file/fileperms_variation2.phpt | 14 +++++----- .../tests/file/filesize_variation5.phpt | 6 ++--- .../tests/file/is_dir_variation3.phpt | 6 ++--- .../tests/file/is_file_variation3.phpt | 6 ++--- .../tests/file/is_readable_variation3.phpt | 6 ++--- .../tests/file/is_writable_variation3.phpt | 13 ++++------ .../tests/file/lstat_stat_variation22.phpt | 14 +++++----- .../tests/file/mkdir_variation1-win32.phpt | 18 ++++++------- .../tests/file/popen_pclose_basic-win32.phpt | 7 +---- .../file/readfile_variation10-win32.phpt | 21 +++++++-------- .../tests/file/realpath_variation-win32.phpt | 21 ++++++--------- .../tests/file/tempnam_variation7-win32.phpt | 25 ++++++++---------- 21 files changed, 135 insertions(+), 168 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index c83b3d0f0e121..5401483db7584 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -438,14 +438,6 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha if (c == 'p' && CHECK_ZVAL_NULL_PATH(*arg)) { return "a valid path"; } -#ifdef PHP_WIN32 - if (c == 'p') { - /* do not allow trailing space (or single, */ - if (Z_STRVAL_PP(arg)[0] == ' ' || Z_STRVAL_PP(arg)[Z_STRLEN_PP(arg) - 1] == ' ') { - return "a valid path"; - } - } -#endif break; case IS_OBJECT: diff --git a/ext/standard/tests/file/005_variation2-win32.phpt b/ext/standard/tests/file/005_variation2-win32.phpt index 3ae129ba75387..45dcbc5f071c3 100644 --- a/ext/standard/tests/file/005_variation2-win32.phpt +++ b/ext/standard/tests/file/005_variation2-win32.phpt @@ -87,13 +87,13 @@ echo "Done"; -- File ' ' -- -- File access time is => -Warning: fileatime() expects parameter 1 to be a valid path, string given in %s on line %d +Warning: fileatime(): stat failed for in %s on line %d -- File modification time is => -Warning: filemtime() expects parameter 1 to be a valid path, string given in %s on line %d +Warning: filemtime(): stat failed for in %s on line %d -- inode change time is => -Warning: filectime() expects parameter 1 to be a valid path, string given in %s on line %d +Warning: filectime(): stat failed for in %s on line %d -- File '|' -- @@ -107,13 +107,19 @@ Warning: filemtime(): stat failed for | in %s on line %d Warning: filectime(): stat failed for | in %s on line %d -*** testing touch ***bool(false) +*** testing touch *** +Warning: touch(): %s in %s on line %d bool(false) + +Warning: touch(): %s in %s on line %d +bool(false) + +Warning: touch(): %s in %s on line %d bool(false) -Warning: touch() expects parameter 1 to be a valid path, string given in %s005_variation2-win32.php on line %d -NULL +Warning: touch(): %s in %s on line %d +bool(false) -Warning: touch(): Unable to create file | because Invalid argument in %s005_variation2-win32.php on line %d +Warning: touch(): %s in %s on line %d bool(false) Done diff --git a/ext/standard/tests/file/copy_variation3-win32.phpt b/ext/standard/tests/file/copy_variation3-win32.phpt index 3972523778ddf..68ce4a1680660 100644 --- a/ext/standard/tests/file/copy_variation3-win32.phpt +++ b/ext/standard/tests/file/copy_variation3-win32.phpt @@ -89,29 +89,21 @@ Size of source file => int(1500) Size of destination file => int(1500) -- Iteration 2 -- -Copy operation => -Warning: copy() expects parameter 2 to be a valid path, string given in %scopy_variation3-win32.php on line %d -NULL -Existence of destination file => -Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d -NULL - -Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d +Copy operation => bool(true) +Existence of destination file => bool(true) +Destination file name => copy_variation3.tmp +Size of source file => int(1500) +Size of destination file => int(1500) -- Iteration 3 -- Copy operation => -Warning: copy(copy variation3.tmp): failed to open stream: Invalid argument in %scopy_variation3-win32.php on line %d +Warning: copy(%s): %s bool(false) Existence of destination file => bool(false) -- Iteration 4 -- Copy operation => -Warning: copy() expects parameter 2 to be a valid path, string given in %scopy_variation3-win32.php on line %d -NULL -Existence of destination file => -Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d -NULL - -Warning: file_exists() expects parameter 1 to be a valid path, string given in %scopy_variation3-win32.php on line %d +Warning: copy(%s): %s +bool(false) +Existence of destination file => bool(false) *** Done *** - diff --git a/ext/standard/tests/file/file_exists_variation1.phpt b/ext/standard/tests/file/file_exists_variation1.phpt index 680d05ec777d5..35c86a2808b00 100644 --- a/ext/standard/tests/file/file_exists_variation1.phpt +++ b/ext/standard/tests/file/file_exists_variation1.phpt @@ -25,8 +25,6 @@ echo "Done"; bool(false) bool(false) bool(false) - -Warning: file_exists() expects parameter 1 to be a valid path, string given in %sfile_exists_variation1.php on line %d -NULL bool(false) -Done +bool(false) +Done \ No newline at end of file diff --git a/ext/standard/tests/file/file_get_contents_variation8-win32.phpt b/ext/standard/tests/file/file_get_contents_variation8-win32.phpt index eb7c74b7d8eef..43d742a67c8a9 100644 --- a/ext/standard/tests/file/file_get_contents_variation8-win32.phpt +++ b/ext/standard/tests/file/file_get_contents_variation8-win32.phpt @@ -47,51 +47,51 @@ foreach($names_arr as $key =>$value) { -- Filename: -1 -- -Warning: file_get_contents(-1): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(-1): failed to open stream: No such file or directory in %s on line %d bool(false) -- Filename: TRUE -- -Warning: file_get_contents(1): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(1): failed to open stream: No such file or directory in %s on line %d bool(false) -- Filename: FALSE -- -Warning: file_get_contents(): Filename cannot be empty in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(): Filename cannot be empty in %s on line %d bool(false) -- Filename: NULL -- -Warning: file_get_contents(): Filename cannot be empty in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(): Filename cannot be empty in %s on line %d bool(false) -- Filename: "" -- -Warning: file_get_contents(): Filename cannot be empty in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(): Filename cannot be empty in %s on line %d bool(false) -- Filename: " " -- -Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %sfile_get_contents_variation8-win32.php on line %d -NULL +Warning: file_get_contents( ): failed to open stream: Permission denied in %s on line %d +bool(false) -- Filename: \0 -- -Warning: file_get_contents() expects parameter 1 to be a valid path, string given in %sfile_get_contents_variation8-win32.php on line %d -NULL +Warning: file_get_contents(): Filename cannot be empty in %s on line %d +bool(false) -- Filename: array() -- -Warning: file_get_contents() expects parameter 1 to be a valid path, array given in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents() expects parameter 1 to be string, array given in %s on line %d NULL -- Filename: /no/such/file/dir -- -Warning: file_get_contents(/no/such/file/dir): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(/no/such/file/dir): failed to open stream: No such file or directory in %s on line %d bool(false) -- Filename: php/php -- -Warning: file_get_contents(php/php): failed to open stream: No such file or directory in %sfile_get_contents_variation8-win32.php on line %d +Warning: file_get_contents(php/php): failed to open stream: No such file or directory in %s on line %d bool(false) -===Done=== +===Done=== \ No newline at end of file diff --git a/ext/standard/tests/file/file_put_contents_variation8-win32.phpt b/ext/standard/tests/file/file_put_contents_variation8-win32.phpt index 8da6b3b851765..92fe7b3d6af6f 100644 --- a/ext/standard/tests/file/file_put_contents_variation8-win32.phpt +++ b/ext/standard/tests/file/file_put_contents_variation8-win32.phpt @@ -58,41 +58,41 @@ foreach($names_arr as $key =>$value) { -- Filename: FALSE -- -Warning: file_put_contents(): Filename cannot be empty in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents(): Filename cannot be empty in %s on line %d Failed to write data to: FALSE -- Filename: NULL -- -Warning: file_put_contents(): Filename cannot be empty in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents(): Filename cannot be empty in %s on line %d Failed to write data to: NULL -- Filename: "" -- -Warning: file_put_contents(): Filename cannot be empty in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents(): Filename cannot be empty in %s on line %d Failed to write data to: "" -- Filename: " " -- -Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents( ): failed to open stream: Permission denied in %s on line %d Failed to write data to: " " -- Filename: \0 -- -Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, string given in %s on line %d Failed to write data to: \0 -- Filename: array() -- -Warning: file_put_contents() expects parameter 1 to be a valid path, array given in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents() expects parameter 1 to be a valid path, array given in %s on line %d Failed to write data to: array() -- Filename: /no/such/file/dir -- -Warning: file_put_contents(/no/such/file/dir): failed to open stream: No such file or directory in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents(/no/such/file/dir): failed to open stream: %s in %s on line %d Failed to write data to: /no/such/file/dir -- Filename: php/php -- -Warning: file_put_contents(php/php): failed to open stream: No such file or directory in %sfile_put_contents_variation8-win32.php on line %d +Warning: file_put_contents(php/php): failed to open stream: %s in %s on line %d Failed to write data to: php/php ===Done=== diff --git a/ext/standard/tests/file/filegroup_variation2.phpt b/ext/standard/tests/file/filegroup_variation2.phpt index 6ccf7eb4ccb97..afac40c9ab029 100644 --- a/ext/standard/tests/file/filegroup_variation2.phpt +++ b/ext/standard/tests/file/filegroup_variation2.phpt @@ -46,25 +46,25 @@ unlink($file_path."/filegroup_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: filegroup(): stat failed for -2.34555 in %sfilegroup_variation2.php on line %d +Warning: filegroup(): stat failed for -2.34555 in %s on line %d bool(false) -Warning: filegroup() expects parameter 1 to be a valid path, string given in %sfilegroup_variation2.php on line %d -NULL +Warning: filegroup(): stat failed for in %s on line %d +bool(false) bool(false) -Warning: filegroup(): stat failed for 1 in %sfilegroup_variation2.php on line %d +Warning: filegroup(): stat failed for 1 in %s on line %d bool(false) bool(false) bool(false) -Warning: filegroup() expects parameter 1 to be a valid path, resource given in %sfilegroup_variation2.php on line %d +Warning: filegroup() expects parameter 1 to be a valid path, resource given in %s on line %d NULL -Warning: filegroup(): stat failed for 1234 in %sfilegroup_variation2.php on line %d +Warning: filegroup(): stat failed for 1234 in %s on line %d bool(false) -Warning: filegroup(): stat failed for 0 in %sfilegroup_variation2.php on line %d +Warning: filegroup(): stat failed for 0 in %s on line %d bool(false) *** Done *** diff --git a/ext/standard/tests/file/fileinode_variation2.phpt b/ext/standard/tests/file/fileinode_variation2.phpt index cb095773a9503..e8e7af6a6e9a4 100644 --- a/ext/standard/tests/file/fileinode_variation2.phpt +++ b/ext/standard/tests/file/fileinode_variation2.phpt @@ -47,25 +47,26 @@ unlink($file_path."/fileinode_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: fileinode(): stat failed for -2.34555 in %sfileinode_variation2.php on line %d +Warning: fileinode(): stat failed for -2.34555 in %s on line %d bool(false) -Warning: fileinode() expects parameter 1 to be a valid path, string given in %sfileinode_variation2.php on line %d -NULL +Warning: fileinode(): stat failed for in %s on line %d +bool(false) bool(false) -Warning: fileinode(): stat failed for 1 in %sfileinode_variation2.php on line %d +Warning: fileinode(): stat failed for 1 in %s on line %d bool(false) bool(false) bool(false) -Warning: fileinode() expects parameter 1 to be a valid path, resource given in %sfileinode_variation2.php on line %d +Warning: fileinode() expects parameter 1 to be a valid path, resource given in %s on line %d NULL -Warning: fileinode(): stat failed for 1234 in %sfileinode_variation2.php on line %d +Warning: fileinode(): stat failed for 1234 in %s on line %d bool(false) -Warning: fileinode(): stat failed for 0 in %sfileinode_variation2.php on line %d +Warning: fileinode(): stat failed for 0 in %s on line %d bool(false) *** Done *** + diff --git a/ext/standard/tests/file/fileowner_variation2.phpt b/ext/standard/tests/file/fileowner_variation2.phpt index ed6b7e9021d92..feff767879943 100644 --- a/ext/standard/tests/file/fileowner_variation2.phpt +++ b/ext/standard/tests/file/fileowner_variation2.phpt @@ -47,25 +47,26 @@ unlink($file_path."/fileowner_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: fileowner(): stat failed for -2.34555 in %sfileowner_variation2.php on line %d +Warning: fileowner(): stat failed for -2.34555 in %s on line %d bool(false) -Warning: fileowner() expects parameter 1 to be a valid path, string given in %sfileowner_variation2.php on line %d -NULL +Warning: fileowner(): stat failed for in %s on line %d +bool(false) bool(false) -Warning: fileowner(): stat failed for 1 in %sfileowner_variation2.php on line %d +Warning: fileowner(): stat failed for 1 in %s on line %d bool(false) bool(false) bool(false) -Warning: fileowner() expects parameter 1 to be a valid path, resource given in %sfileowner_variation2.php on line %d +Warning: fileowner() expects parameter 1 to be a valid path, resource given in %s on line %d NULL -Warning: fileowner(): stat failed for 1234 in %sfileowner_variation2.php on line %d +Warning: fileowner(): stat failed for 1234 in %s on line %d bool(false) -Warning: fileowner(): stat failed for 0 in %sfileowner_variation2.php on line %d +Warning: fileowner(): stat failed for 0 in %s on line %d bool(false) *** Done *** + diff --git a/ext/standard/tests/file/fileperms_variation2.phpt b/ext/standard/tests/file/fileperms_variation2.phpt index 394cddcc85cf4..47c0c6593acfd 100644 --- a/ext/standard/tests/file/fileperms_variation2.phpt +++ b/ext/standard/tests/file/fileperms_variation2.phpt @@ -46,25 +46,25 @@ unlink($file_path."/fileperms_variation2.tmp"); --EXPECTF-- *** Testing Invalid file types *** -Warning: fileperms(): stat failed for -2.34555 in %sfileperms_variation2.php on line %d +Warning: fileperms(): stat failed for -2.34555 in %s on line %d bool(false) -Warning: fileperms() expects parameter 1 to be a valid path, string given in %sfileperms_variation2.php on line %d -NULL +Warning: fileperms(): stat failed for in %s on line %d +bool(false) bool(false) -Warning: fileperms(): stat failed for 1 in %sfileperms_variation2.php on line %d +Warning: fileperms(): stat failed for 1 in %s on line %d bool(false) bool(false) bool(false) -Warning: fileperms() expects parameter 1 to be a valid path, resource given in %sfileperms_variation2.php on line %d +Warning: fileperms() expects parameter 1 to be a valid path, resource given in %s on line %d NULL -Warning: fileperms(): stat failed for 1234 in %sfileperms_variation2.php on line %d +Warning: fileperms(): stat failed for 1234 in %s on line %d bool(false) -Warning: fileperms(): stat failed for 0 in %sfileperms_variation2.php on line %d +Warning: fileperms(): stat failed for 0 in %s on line %d bool(false) *** Done *** diff --git a/ext/standard/tests/file/filesize_variation5.phpt b/ext/standard/tests/file/filesize_variation5.phpt index 574dfe3a73558..638f8ba8ed3d9 100644 --- a/ext/standard/tests/file/filesize_variation5.phpt +++ b/ext/standard/tests/file/filesize_variation5.phpt @@ -26,9 +26,9 @@ bool(false) bool(false) bool(false) -Warning: filesize() expects parameter 1 to be a valid path, string given in %sfilesize_variation5.php on line %d -NULL +Warning: filesize(): stat failed for in %s on line %d +bool(false) -Warning: filesize(): stat failed for | in %sfilesize_variation5.php on line %d +Warning: filesize(): stat failed for | in %s on line %d bool(false) *** Done *** diff --git a/ext/standard/tests/file/is_dir_variation3.phpt b/ext/standard/tests/file/is_dir_variation3.phpt index c16059b6a02ab..41826ad7ecd8c 100644 --- a/ext/standard/tests/file/is_dir_variation3.phpt +++ b/ext/standard/tests/file/is_dir_variation3.phpt @@ -40,11 +40,9 @@ bool(false) bool(false) bool(false) bool(false) +bool(false) -%s: is_dir() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\is_dir_variation3.php on line %d -NULL - -%s: is_dir() expects parameter 1 to be a valid path, resource given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\is_dir_variation3.php on line %d +Warning: is_dir() expects parameter 1 to be a valid path, resource given in %s on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/is_file_variation3.phpt b/ext/standard/tests/file/is_file_variation3.phpt index b80b715787192..2a13e4677924f 100644 --- a/ext/standard/tests/file/is_file_variation3.phpt +++ b/ext/standard/tests/file/is_file_variation3.phpt @@ -45,15 +45,13 @@ unlink($file_path."/is_file_variation3.tmp"); --EXPECTF-- *** Testing Invalid file types *** bool(false) - -Warning: is_file() expects parameter 1 to be a valid path, string given in %sis_file_variation3.php on line %d -NULL +bool(false) bool(false) bool(false) bool(false) bool(false) -Warning: is_file() expects parameter 1 to be a valid path, resource given in %sis_file_variation3.php on line %d +Warning: is_file() expects parameter 1 to be a valid path, resource given in %s on line %d NULL bool(false) bool(false) diff --git a/ext/standard/tests/file/is_readable_variation3.phpt b/ext/standard/tests/file/is_readable_variation3.phpt index c9d96ef85a63b..dc4d3b16f394c 100644 --- a/ext/standard/tests/file/is_readable_variation3.phpt +++ b/ext/standard/tests/file/is_readable_variation3.phpt @@ -59,11 +59,9 @@ bool(false) bool(false) bool(false) bool(false) +bool(false) -Warning: is_readable() expects parameter 1 to be a valid path, string given in %sis_readable_variation3.php on line %d -NULL - -Warning: is_readable() expects parameter 1 to be a valid path, array given in %sis_readable_variation3.php on line %d +Warning: is_readable() expects parameter 1 to be a valid path, array given in %s on line %d NULL bool(false) Done diff --git a/ext/standard/tests/file/is_writable_variation3.phpt b/ext/standard/tests/file/is_writable_variation3.phpt index 986f076a83a1f..66a80abf1eece 100644 --- a/ext/standard/tests/file/is_writable_variation3.phpt +++ b/ext/standard/tests/file/is_writable_variation3.phpt @@ -64,18 +64,15 @@ bool(false) bool(false) bool(false) bool(false) +bool(false) +bool(false) -Warning: is_writable() expects parameter 1 to be a valid path, string given in %sis_writable_variation3.php on line %d -NULL - -Warning: is_writeable() expects parameter 1 to be a valid path, string given in %sis_writable_variation3.php on line %d -NULL - -Warning: is_writable() expects parameter 1 to be a valid path, array given in %sis_writable_variation3.php on line %d +Warning: is_writable() expects parameter 1 to be a valid path, array given in %s on line %d NULL -Warning: is_writeable() expects parameter 1 to be a valid path, array given in %sis_writable_variation3.php on line %d +Warning: is_writeable() expects parameter 1 to be a valid path, array given in %s on line %d NULL bool(false) bool(false) Done + diff --git a/ext/standard/tests/file/lstat_stat_variation22.phpt b/ext/standard/tests/file/lstat_stat_variation22.phpt index 332b651f1c8ad..c9072ce0131f0 100644 --- a/ext/standard/tests/file/lstat_stat_variation22.phpt +++ b/ext/standard/tests/file/lstat_stat_variation22.phpt @@ -31,19 +31,19 @@ bool(false) bool(false) bool(false) -Warning: stat() expects parameter 1 to be a valid path, string given in %slstat_stat_variation22.php on line %d -NULL +Warning: stat(): stat failed for in %s on line %d +bool(false) -Warning: stat(): stat failed for | in %slstat_stat_variation22.php on line %d +Warning: stat(): stat failed for | in %s on line %d bool(false) *** testing lstat *** bool(false) bool(false) bool(false) -Warning: lstat() expects parameter 1 to be a valid path, string given in %slstat_stat_variation22.php on line %d -NULL +Warning: lstat(): Lstat failed for in %s on line %d +bool(false) -Warning: lstat(): Lstat failed for | in %slstat_stat_variation22.php on line %d +Warning: lstat(): Lstat failed for | in %s on line %d bool(false) -Done +Done \ No newline at end of file diff --git a/ext/standard/tests/file/mkdir_variation1-win32.phpt b/ext/standard/tests/file/mkdir_variation1-win32.phpt index dbb37319a9c6d..17f54926cb5d6 100644 --- a/ext/standard/tests/file/mkdir_variation1-win32.phpt +++ b/ext/standard/tests/file/mkdir_variation1-win32.phpt @@ -94,29 +94,29 @@ foreach($inputs as $key =>$value) { *** Testing mkdir() : usage variation *** --uppercase NULL-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --lowercase null-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --lowercase false-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --uppercase FALSE-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --empty string DQ-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --empty string SQ-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --undefined var-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --unset var-- -Error: 2 - mkdir(): Invalid argument, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) --single space-- -Error: 2 - mkdir() expects parameter 1 to be a valid path, string given, %smkdir_variation1-win32.php(%d) +Error: 2 - mkdir(): %s, %s(%d) ===DONE=== diff --git a/ext/standard/tests/file/popen_pclose_basic-win32.phpt b/ext/standard/tests/file/popen_pclose_basic-win32.phpt index b7eadabec1b34..8c2ba4252d07b 100644 --- a/ext/standard/tests/file/popen_pclose_basic-win32.phpt +++ b/ext/standard/tests/file/popen_pclose_basic-win32.phpt @@ -47,12 +47,7 @@ echo "\n--- Done ---"; ?> --EXPECTF-- *** Testing popen(): reading from the pipe *** - -Warning: popen() expects parameter 1 to be a valid path, string given in %spopen_pclose_basic-win32.php on line %d - -Warning: fpassthru() expects parameter 1 to be resource, null given in %spopen_pclose_basic-win32.php on line %d - -Warning: pclose() expects parameter 1 to be resource, null given in %spopen_pclose_basic-win32.php on line %d +Sample String *** Testing popen(): writing to the pipe *** aaa ddd diff --git a/ext/standard/tests/file/readfile_variation10-win32.phpt b/ext/standard/tests/file/readfile_variation10-win32.phpt index ac8869218e4c3..61f6aba7a5ecb 100644 --- a/ext/standard/tests/file/readfile_variation10-win32.phpt +++ b/ext/standard/tests/file/readfile_variation10-win32.phpt @@ -47,42 +47,41 @@ foreach($names_arr as $key => $value) { -- Filename: -1 -- -Warning: readfile(-1): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(-1): failed to open stream: No such file or directory in %s on line %d -- Filename: TRUE -- -Warning: readfile(1): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(1): failed to open stream: No such file or directory in %s on line %d -- Filename: FALSE -- -Warning: readfile(): Filename cannot be empty in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(): Filename cannot be empty in %s on line %d -- Filename: NULL -- -Warning: readfile(): Filename cannot be empty in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(): Filename cannot be empty in %s on line %d -- Filename: "" -- -Warning: readfile(): Filename cannot be empty in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(): Filename cannot be empty in %s on line %d -- Filename: " " -- -Warning: readfile() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile( ): failed to open stream: Permission denied in %s on line %d -- Filename: \0 -- -Warning: readfile() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile() expects parameter 1 to be a valid path, string given in %s on line %d -- Filename: array() -- -Warning: readfile() expects parameter 1 to be a valid path, array given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile() expects parameter 1 to be a valid path, array given in %s on line %d -- Filename: /no/such/file/dir -- -Warning: readfile(/no/such/file/dir): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(/no/such/file/dir): failed to open stream: No such file or directory in %s on line %d -- Filename: php/php -- -Warning: readfile(php/php): failed to open stream: No such file or directory in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\readfile_variation10-win32.php on line 30 +Warning: readfile(php/php): failed to open stream: No such file or directory in %s on line %d ===Done=== - diff --git a/ext/standard/tests/file/realpath_variation-win32.phpt b/ext/standard/tests/file/realpath_variation-win32.phpt index 088ae108b131a..59db125fb9d2e 100644 --- a/ext/standard/tests/file/realpath_variation-win32.phpt +++ b/ext/standard/tests/file/realpath_variation-win32.phpt @@ -79,29 +79,24 @@ rmdir("$name_prefix/"); *** Testing realpath(): usage variations *** *** Testing realpath() with filename stored inside a object *** -string(112) "G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation\home\tests\realpath_variation.tmp" +string(%d) "%s\realpath_variation\home\tests\realpath_variation.tmp" bool(false) *** Testing realpath() with filename stored in an array *** -string(112) "G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation\home\tests\realpath_variation.tmp" +string(%d) "%s\realpath_variation\home\tests\realpath_variation.tmp" bool(false) *** Testing realpath() with filename as empty string, NULL and single space *** -- Iteration1 -- - -Warning: realpath() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation-win32.php on line 56 -NULL +bool(false) -- Iteration2 -- - -Warning: realpath() expects parameter 1 to be a valid path, string given in G:\php-sdk\php-src\branches\PHP_5_4\ext\standard\tests\file\realpath_variation-win32.php on line 56 -NULL +bool(false) -- Iteration3 -- -string(35) "G:\php-sdk\php-src\branches\PHP_5_4" +string(%d) "%s" -- Iteration4 -- -string(35) "G:\php-sdk\php-src\branches\PHP_5_4" +string(%d) "%s" -- Iteration5 -- -string(35) "G:\php-sdk\php-src\branches\PHP_5_4" +string(%d) "%s" -- Iteration6 -- -string(35) "G:\php-sdk\php-src\branches\PHP_5_4" +string(%d) "%s" Done - diff --git a/ext/standard/tests/file/tempnam_variation7-win32.phpt b/ext/standard/tests/file/tempnam_variation7-win32.phpt index 0194bd962443b..2572f65d02de8 100644 --- a/ext/standard/tests/file/tempnam_variation7-win32.phpt +++ b/ext/standard/tests/file/tempnam_variation7-win32.phpt @@ -65,31 +65,29 @@ echo "\n*** Done ***\n"; --EXPECTF-- *** Testing tempnam() with invalid/non-existing directory names *** -- Iteration 0 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 1 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 2 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 3 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 4 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 5 -- - -Warning: tempnam() expects parameter 1 to be a valid path, string given in %stempnam_variation7-win32.php on line %d --- File is not created -- - -Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d +File name is => %s%et%s +File permissions are => 100666 +File created in => temp dir -- Iteration 6 -- Warning: tempnam() expects parameter 1 to be a valid path, string given in %stempnam_variation7-win32.php on line %d @@ -98,19 +96,18 @@ Warning: tempnam() expects parameter 1 to be a valid path, string given in %stem Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 7 -- -Warning: tempnam() expects parameter 1 to be a valid path, array given in %stempnam_variation7-win32.php on line %d +Warning: tempnam() expects parameter 1 to be a valid path, array given in %s on line %d -- File is not created -- Warning: unlink(): Invalid argument in %stempnam_variation7-win32.php on line %d -- Iteration 8 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir -- Iteration 9 -- -File name is => %s.tmp +File name is => %s%et%s File permissions are => 100666 File created in => temp dir *** Done *** - From 36378d34f8b3c89da782460db8d3919868e1dfc7 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Wed, 7 Sep 2011 14:30:06 +0000 Subject: [PATCH 0872/2394] fixed invalid utf-8 check. --- ext/mbstring/libmbfl/filters/mbfilter_utf8.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c index 41671344328dd..ec7fab356402f 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c @@ -101,10 +101,15 @@ int mbfl_filt_conv_utf8_wchar(int c, mbfl_convert_filter *filter) int s, c1, w = 0, flag = 0; if (c < 0x80) { + if (filter->status != 0) { + w = (filter->cache & MBFL_WCSGROUP_MASK) | MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(w, filter->data)); + filter->status = 0; + filter->cache = 0; + } if (c >= 0) { CK((*filter->output_function)(c, filter->data)); } - filter->status = 0; } else if (c < 0xc0) { int status = filter->status & 0xff; switch (status) { From 26a80c72afa5dd131b6b56f15d0c92cd20197cd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 7 Sep 2011 15:28:12 +0000 Subject: [PATCH 0873/2394] - Fixed doc bug #54657: Function parameters can no longer be named after superglobal variables. --- UPGRADING | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/UPGRADING b/UPGRADING index 6ff8ad9f47e31..bd73451a5fcd6 100755 --- a/UPGRADING +++ b/UPGRADING @@ -102,6 +102,10 @@ UPGRADE NOTES - PHP X.Y $test = new StdClass; $test->baz = 1; +- In previous versions, names of superglobals could be used for parameter + names, thereby shadowing the corresponding superglobal. This now causes a + fatal error such as "Cannot re-assign auto-global variable GLOBALS". + ===================================== 4. Changes made to existing functions ===================================== From 12e983e714e0d7ad9ad798eb91bfb664d5ba3998 Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Wed, 7 Sep 2011 15:31:48 +0000 Subject: [PATCH 0874/2394] Fixed tests (skip when catch-all DNS such as openDNS is being used) --- ext/curl/tests/curl_basic_008.phpt | 8 +++++++- ext/curl/tests/curl_basic_010.phpt | 8 +++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/ext/curl/tests/curl_basic_008.phpt b/ext/curl/tests/curl_basic_008.phpt index 32de4d0f5c9b2..29e3343707ebb 100755 --- a/ext/curl/tests/curl_basic_008.phpt +++ b/ext/curl/tests/curl_basic_008.phpt @@ -3,7 +3,13 @@ Test curl_error() & curl_errno() function with problematic host --CREDITS-- TestFest 2009 - AFUP - Perrick Penet --SKIPIF-- - + --FILE-- --SKIPIF-- - + --FILE-- Date: Wed, 7 Sep 2011 16:19:09 +0000 Subject: [PATCH 0875/2394] Fixed bug #55504 (Content-Type header is not parsed correctly on HTTP POST request --- main/rfc1867.c | 2 +- tests/basic/030.phpt | 20 ++++++++++++++++++++ tests/basic/031.phpt | 32 ++++++++++++++++++++++++++++++++ tests/basic/032.phpt | 20 ++++++++++++++++++++ 4 files changed, 73 insertions(+), 1 deletion(-) create mode 100644 tests/basic/030.phpt create mode 100644 tests/basic/031.phpt create mode 100644 tests/basic/032.phpt diff --git a/main/rfc1867.c b/main/rfc1867.c index f6dfae997bdcf..5c53cbb8a1a1d 100644 --- a/main/rfc1867.c +++ b/main/rfc1867.c @@ -738,7 +738,7 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler) /* {{{ */ } } else { /* search for the end of the boundary */ - boundary_end = strchr(boundary, ','); + boundary_end = strpbrk(boundary, ",;"); } if (boundary_end) { boundary_end[0] = '\0'; diff --git a/tests/basic/030.phpt b/tests/basic/030.phpt new file mode 100644 index 0000000000000..cf2a270d26955 --- /dev/null +++ b/tests/basic/030.phpt @@ -0,0 +1,20 @@ +--TEST-- +Bug#55504 (Content-Type header is not parsed correctly on HTTP POST request) +--INI-- +file_uploads=1 +--POST_RAW-- +Content-Type: multipart/form-data; boundary=BVoyv; charset=iso-8859-1 +--BVoyv +Content-Disposition: form-data; name="data" + +abc +--BVoyv-- +--FILE-- + +--EXPECT-- +array(1) { + ["data"]=> + string(3) "abc" +} diff --git a/tests/basic/031.phpt b/tests/basic/031.phpt new file mode 100644 index 0000000000000..12b83542874f5 --- /dev/null +++ b/tests/basic/031.phpt @@ -0,0 +1,32 @@ +--TEST-- +Bug#55504 (Content-Type header is not parsed correctly on HTTP POST request) +--INI-- +file_uploads=1 +--POST_RAW-- +Content-Type: multipart/form-data; boundary=BVoyv; charset=iso-8859-1 +--BVoyv +Content-Disposition: form-data; name="data" + +abc +--BVoyv +Content-Disposition: form-data; name="data2" + +more data +--BVoyv +Content-Disposition: form-data; name="data3" + +even more data +--BVoyv-- +--FILE-- + +--EXPECT-- +array(3) { + ["data"]=> + string(3) "abc" + ["data2"]=> + string(9) "more data" + ["data3"]=> + string(14) "even more data" +} diff --git a/tests/basic/032.phpt b/tests/basic/032.phpt new file mode 100644 index 0000000000000..a6aba5bb66bb0 --- /dev/null +++ b/tests/basic/032.phpt @@ -0,0 +1,20 @@ +--TEST-- +Bug#18792 (no form variables after multipart/form-data) +--INI-- +file_uploads=1 +--POST_RAW-- +Content-Type: multipart/form-data; boundary=BVoyv, charset=iso-8859-1 +--BVoyv +Content-Disposition: form-data; name="data" + +abc +--BVoyv-- +--FILE-- + +--EXPECT-- +array(1) { + ["data"]=> + string(3) "abc" +} From 331766c3bf324c30728d89c3d4b91bbb0fb194f0 Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Wed, 7 Sep 2011 18:09:34 +0000 Subject: [PATCH 0876/2394] This test was added to verify that bug 39322 was fixed, which the test does test for and this works. However, it consistently failed because it relied on a SIGHUP not terminating a sh -c /usr/bin/nohup sleep 50 process which doesn't work because the SIGHUP goes to the sh process not the nohup'ed sleep process. So, I have sped up the test and removed the nohup and instead of trying to SIGHUP I am just doing the equivalent of a kill 0 on it to verify that the resource sticks around. --- .../tests/general_functions/proc_open02.phpt | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/ext/standard/tests/general_functions/proc_open02.phpt b/ext/standard/tests/general_functions/proc_open02.phpt index 3406f6806c58c..d5d878ed241ba 100644 --- a/ext/standard/tests/general_functions/proc_open02.phpt +++ b/ext/standard/tests/general_functions/proc_open02.phpt @@ -3,7 +3,6 @@ proc_open --SKIPIF-- --FILE-- @@ -11,19 +10,19 @@ if (getenv('SKIP_SLOW_TESTS')) echo 'skip slow test'; $ds = array(array('pipe', 'r')); $cat = proc_open( - '/usr/bin/nohup /bin/sleep 50', + '/bin/sleep 2', $ds, $pipes ); -sleep(1); // let the OS run the nohup process before sending the signal +usleep(20000); // let the OS run the sleep process before sending the signal -var_dump(proc_terminate($cat, 1)); // send a SIGHUP -sleep(1); +var_dump(proc_terminate($cat, 0)); // status check +usleep(20000); var_dump(proc_get_status($cat)); var_dump(proc_terminate($cat)); // now really quit it -sleep(1); +usleep(20000); var_dump(proc_get_status($cat)); proc_close($cat); @@ -35,7 +34,7 @@ echo "Done!\n"; bool(true) array(8) { ["command"]=> - string(28) "/usr/bin/nohup /bin/sleep 50" + string(12) "/bin/sleep 2" ["pid"]=> int(%d) ["running"]=> @@ -54,7 +53,7 @@ array(8) { bool(true) array(8) { ["command"]=> - string(28) "/usr/bin/nohup /bin/sleep 50" + string(12) "/bin/sleep 2" ["pid"]=> int(%d) ["running"]=> From ca2234d18c89f7e631420e60448d56fa1dec2d9a Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Wed, 7 Sep 2011 18:48:17 +0000 Subject: [PATCH 0877/2394] Make timeouts work again for shutdown functions. Fixes the faling lang/045 test --- Zend/zend_execute_API.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 839621ea6b79d..2572f85b907c1 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -1328,6 +1328,13 @@ ZEND_API void zend_timeout(int dummy) /* {{{ */ TSRMLS_FETCH(); if (zend_on_timeout) { + /* + We got here because we got a timeout signal, so we are in a signal handler + at this point. However, we want to be able to timeout any user-supplied + shutdown functions, so pretend we are not in a signal handler while we are + calling these + */ + SIGG(running) = 0; zend_on_timeout(EG(timeout_seconds) TSRMLS_CC); } From 53cfca411b82cf4501c17409e1d775d03d43d7db Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Wed, 7 Sep 2011 19:19:00 +0000 Subject: [PATCH 0878/2394] Use unique object names to reduce potential clashes when testing in parallel --- ext/oci8/tests/bug42496_1.phpt | 14 +++++++------- ext/oci8/tests/bug42496_2.phpt | 14 +++++++------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/ext/oci8/tests/bug42496_1.phpt b/ext/oci8/tests/bug42496_1.phpt index abf6cc8c757b9..2b62267c73961 100644 --- a/ext/oci8/tests/bug42496_1.phpt +++ b/ext/oci8/tests/bug42496_1.phpt @@ -14,11 +14,11 @@ require dirname(__FILE__).'/connect.inc'; // Initialization $stmtarray = array( - "DROP table bug42496_tab", - "CREATE table bug42496_tab(c1 CLOB, c2 CLOB)", - "INSERT INTO bug42496_tab VALUES('test1', 'test1')", - "INSERT INTO bug42496_tab VALUES('test2', 'test2')", - "INSERT INTO bug42496_tab VALUES('test3', 'test3')" + "DROP table bug42496_1_tab", + "CREATE table bug42496_1_tab(c1 CLOB, c2 CLOB)", + "INSERT INTO bug42496_1_tab VALUES('test1', 'test1')", + "INSERT INTO bug42496_1_tab VALUES('test2', 'test2')", + "INSERT INTO bug42496_1_tab VALUES('test3', 'test3')" ); oci8_test_sql_execute($c, $stmtarray); @@ -28,7 +28,7 @@ oci8_test_sql_execute($c, $stmtarray); echo "Test 1\n"; for ($i = 0; $i < 15000; $i++) { - $s = oci_parse($c, "SELECT * from bug42496_tab"); + $s = oci_parse($c, "SELECT * from bug42496_1_tab"); oci_define_by_name($s, "C1", $col1); oci_define_by_name($s, "C2", $col2); if (oci_execute($s)) { @@ -46,7 +46,7 @@ echo "Done\n"; // Cleanup $stmtarray = array( - "DROP table bug42496_tab" + "DROP table bug42496_1_tab" ); oci8_test_sql_execute($c, $stmtarray); diff --git a/ext/oci8/tests/bug42496_2.phpt b/ext/oci8/tests/bug42496_2.phpt index 8c4b79141598f..195c00b7e73e7 100644 --- a/ext/oci8/tests/bug42496_2.phpt +++ b/ext/oci8/tests/bug42496_2.phpt @@ -14,11 +14,11 @@ require dirname(__FILE__).'/connect.inc'; // Initialization $stmtarray = array( - "DROP table bug42496_tab", - "CREATE table bug42496_tab(c1 CLOB, c2 CLOB)", - "INSERT INTO bug42496_tab VALUES('test1', 'test1')", - "INSERT INTO bug42496_tab VALUES('test2', 'test2')", - "INSERT INTO bug42496_tab VALUES('test3', 'test3')" + "DROP table bug42496_2_tab", + "CREATE table bug42496_2_tab(c1 CLOB, c2 CLOB)", + "INSERT INTO bug42496_2_tab VALUES('test1', 'test1')", + "INSERT INTO bug42496_2_tab VALUES('test2', 'test2')", + "INSERT INTO bug42496_2_tab VALUES('test3', 'test3')" ); oci8_test_sql_execute($c, $stmtarray); @@ -28,7 +28,7 @@ oci8_test_sql_execute($c, $stmtarray); echo "Test 2\n"; for ($i = 0; $i < 15000; $i++) { - $s = oci_parse($c, "SELECT * from bug42496_tab"); + $s = oci_parse($c, "SELECT * from bug42496_2_tab"); if (oci_execute($s)) { $arr = array(); while ($arr = oci_fetch_assoc($s)) { @@ -44,7 +44,7 @@ echo "Done\n"; // Cleanup $stmtarray = array( - "DROP table bug42496_tab" + "DROP table bug42496_2_tab" ); oci8_test_sql_execute($c, $stmtarray); From d566f0c88e1d3981c421e3fbad23ebe2b8420277 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 09:17:21 +0000 Subject: [PATCH 0879/2394] - fix build when no zend signal support --- Zend/zend_execute_API.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 2572f85b907c1..9d4cc799a234a 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -1328,6 +1328,7 @@ ZEND_API void zend_timeout(int dummy) /* {{{ */ TSRMLS_FETCH(); if (zend_on_timeout) { +#ifdef ZEND_SIGNALS /* We got here because we got a timeout signal, so we are in a signal handler at this point. However, we want to be able to timeout any user-supplied @@ -1335,6 +1336,7 @@ ZEND_API void zend_timeout(int dummy) /* {{{ */ calling these */ SIGG(running) = 0; +#endif zend_on_timeout(EG(timeout_seconds) TSRMLS_CC); } From cf11413db3326a5f1a578444907d251f55cb8aaa Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Thu, 8 Sep 2011 09:27:47 +0000 Subject: [PATCH 0880/2394] Fix the path to the .pem --- ext/openssl/tests/bug54992.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/openssl/tests/bug54992.phpt b/ext/openssl/tests/bug54992.phpt index d3a06310eb121..768b07378e3d5 100644 --- a/ext/openssl/tests/bug54992.phpt +++ b/ext/openssl/tests/bug54992.phpt @@ -8,7 +8,7 @@ if (!function_exists('pcntl_fork')) die("skip no fork"); array( 'verify_peer' => true, - 'cafile' => 'bug54992-ca.pem', + 'cafile' => __DIR__ . '/bug54992-ca.pem', 'CN_match' => 'buga_buga', ) ) From 0e05312d03a1691024ab0ee4207692f6fcbf4bef Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 10:00:47 +0000 Subject: [PATCH 0881/2394] - skip if no hash --- ext/mcrypt/tests/bug43143.phpt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/mcrypt/tests/bug43143.phpt b/ext/mcrypt/tests/bug43143.phpt index 4c390439e02bd..d9fccf3c85bd2 100644 --- a/ext/mcrypt/tests/bug43143.phpt +++ b/ext/mcrypt/tests/bug43143.phpt @@ -1,7 +1,8 @@ --TEST-- Bug #43143 (Warning about empty IV with MCRYPT_MODE_ECB) --SKIPIF-- - + --FILE-- Date: Thu, 8 Sep 2011 10:14:38 +0000 Subject: [PATCH 0882/2394] - force LF From 1fa1bc0d549d84656c61783b2180d24bdb302846 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 10:20:38 +0000 Subject: [PATCH 0883/2394] - force LF and fix... and blame me for not reading the code correctly, zlib tests pass now, linux/bsd/win 100% From 6f2cd0fcefa43ddfebeac16a364ee8f926f5ff0d Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 11:24:33 +0000 Subject: [PATCH 0884/2394] - fix test --- ext/standard/tests/file/005_variation2-win32.phpt | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/ext/standard/tests/file/005_variation2-win32.phpt b/ext/standard/tests/file/005_variation2-win32.phpt index 45dcbc5f071c3..8508ecf7fb753 100644 --- a/ext/standard/tests/file/005_variation2-win32.phpt +++ b/ext/standard/tests/file/005_variation2-win32.phpt @@ -107,14 +107,8 @@ Warning: filemtime(): stat failed for | in %s on line %d Warning: filectime(): stat failed for | in %s on line %d -*** testing touch *** -Warning: touch(): %s in %s on line %d -bool(false) - -Warning: touch(): %s in %s on line %d +*** testing touch ***bool(false) bool(false) - -Warning: touch(): %s in %s on line %d bool(false) Warning: touch(): %s in %s on line %d From f40fd8236e2b269296af6eaf79dfaf9239fa1ff9 Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Thu, 8 Sep 2011 11:30:58 +0000 Subject: [PATCH 0885/2394] skip these tests if can't connect to mysql --- ext/mysql/tests/001.phpt | 5 ++++- ext/mysql/tests/mysql_connect.phpt | 5 ++++- ext/mysql/tests/mysql_max_links.phpt | 1 + ext/mysql/tests/mysql_sql_safe_mode.phpt | 1 + 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ext/mysql/tests/001.phpt b/ext/mysql/tests/001.phpt index 6f2e284debeff..72b6614771e1a 100755 --- a/ext/mysql/tests/001.phpt +++ b/ext/mysql/tests/001.phpt @@ -1,7 +1,10 @@ --TEST-- mysql connect --SKIPIF-- - + --FILE-- + --FILE-- --INI-- mysql.max_links=2 diff --git a/ext/mysql/tests/mysql_sql_safe_mode.phpt b/ext/mysql/tests/mysql_sql_safe_mode.phpt index 6c652fb5796f3..4d8ca92e47c68 100644 --- a/ext/mysql/tests/mysql_sql_safe_mode.phpt +++ b/ext/mysql/tests/mysql_sql_safe_mode.phpt @@ -3,6 +3,7 @@ mysql_[p]connect() - safe_mode --SKIPIF-- Date: Thu, 8 Sep 2011 11:52:37 +0000 Subject: [PATCH 0886/2394] - fix test, again... --- .../tests/file/rename_variation13-win32.phpt | Bin 4755 -> 4547 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/standard/tests/file/rename_variation13-win32.phpt b/ext/standard/tests/file/rename_variation13-win32.phpt index af4649d9aa99533a7812d1d7aa9e39ec6e95dea8..a963b8e8898076f69106fcd943e3221dd8f44535 100644 GIT binary patch delta 441 zcmbQNdRTcwGuz}q_G~6ogUNr`JYmdz?ADX{xjdLmj3zVkicc=!;+ovR=?+qKl*0mt z%t=lw95Uy*EQ3^wHLVmvGEx=NGILV%5_3~^6jCyaQj<&aiz*c${QM$?vizLV+*E~} z#H7?5h2qM*lEeyy%wmPiyyW~MkYYUrjpY24R4WBTBjd>vfR0Sy6r_#Oc9Y9^BqpEc z7o0qgClL}3EleiHlRt77gTsn<4n)v*ax}jgM8XEl1cuRMe(%Yz_-kRI*B~Gb3|IBZ z69ipAT15mMCnpLP!(x^ATXHkI9;)O+b`PK~ z1%4gXViXg7INZUeE#lB7O+z22E@>KSxO67}=S~FLCONs1CznYzWpV?b&E)kw=3ob0 z=9Zq^#HTWOEw30<46Cv%-hQYFW|Q~unL$h`0-M0dZ-?q4d;VIWgu>)I{356lANaGu pIzP$lLG6oYh#6=W3X12KAFLG%gmX=!OGxa8-hDgYT=TmaK1hVK9X From 31d09c9c4c4ed4bef312aeea7f553f8495b83ef3 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Thu, 8 Sep 2011 14:37:18 +0000 Subject: [PATCH 0887/2394] Fixed bug#54798 Segfault when CURLOPT_STDERR file pointer is closed before calling curl_exec --- ext/curl/interface.c | 20 +++++++++++ ext/curl/tests/bug48203.phpt | 69 +++++++----------------------------- ext/curl/tests/bug54798.phpt | 66 ++++++++++++++++++++++++++++++++++ 3 files changed, 99 insertions(+), 56 deletions(-) create mode 100644 ext/curl/tests/bug54798.phpt diff --git a/ext/curl/interface.c b/ext/curl/interface.c index ff2aff07c1404..7efc3a89501f8 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -2209,6 +2209,26 @@ PHP_FUNCTION(curl_exec) _php_curl_cleanup_handle(ch); + if (ch->handlers->std_err) { + php_stream *stream; + stream = (php_stream*)zend_fetch_resource(&ch->handlers->std_err TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_STDERR resource has gone away, resetting to stderr"); + zval_ptr_dtor(&ch->handlers->std_err); + curl_easy_setopt(ch->cp, CURLOPT_STDERR, stderr); + } + } + if (ch->handlers->read && ch->handlers->read->stream) { + php_stream *stream; + stream = (php_stream*)zend_fetch_resource(&ch->handlers->read->stream TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_INFILE resource has gone away, resetting to default"); + zval_ptr_dtor(&ch->handlers->read->stream); + ch->handlers->read->fd = 0; + ch->handlers->read->fp = 0; + curl_easy_setopt(ch->cp, CURLOPT_INFILE, (void *) ch); + } + } error = curl_easy_perform(ch->cp); SAVE_CURL_ERROR(ch, error); /* CURLE_PARTIAL_FILE is returned by HEAD requests */ diff --git a/ext/curl/tests/bug48203.phpt b/ext/curl/tests/bug48203.phpt index 448ecbbc955c7..d8f4d2269fda3 100644 --- a/ext/curl/tests/bug48203.phpt +++ b/ext/curl/tests/bug48203.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #48203 (Crash when file pointers passed to curl are closed before calling curl_exec) +Bug #48203 (Crash when CURLOPT_STDERR is set to regular file) --SKIPIF-- --CLEAN-- --EXPECTF-- -Warning: curl_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_exec(): CURLOPT_STDERR handle is incorrect in %s on line %d -* About to connect() %a -* Closing connection #%d -Ok for CURLOPT_STDERR - -Warning: curl_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_exec(): CURLOPT_WRITEHEADER handle is incorrect in %s on line %d -Ok for CURLOPT_WRITEHEADER - -Warning: curl_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_exec(): CURLOPT_FILE handle is incorrect in %s on line %d -%a -Ok for CURLOPT_FILE - -Warning: curl_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_exec(): CURLOPT_INFILE handle is incorrect in %s on line %d -Ok for CURLOPT_INFILE +Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %sbug48203.php on line %d +%A +Ok diff --git a/ext/curl/tests/bug54798.phpt b/ext/curl/tests/bug54798.phpt new file mode 100644 index 0000000000000..eac9662d091ee --- /dev/null +++ b/ext/curl/tests/bug54798.phpt @@ -0,0 +1,66 @@ +--TEST-- +Bug #48203 (Crash when file pointers passed to curl are closed before calling curl_exec) +--SKIPIF-- + +--FILE-- + +--CLEAN-- + +--EXPECTF-- +Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %sbug48203_2.php on line %d +* About to connect() %a +* Closing connection #%d +Ok for CURLOPT_STDERR +Ok for CURLOPT_WRITEHEADER +Ok for CURLOPT_FILE + +Warning: curl_exec(): CURLOPT_INFILE resource has gone away, resetting to default in %sbug48203_2.php on line %d +Ok for CURLOPT_INFILE From 9103c93606daec1af7997d7dcb9baeaaeb468b01 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Thu, 8 Sep 2011 15:20:17 +0000 Subject: [PATCH 0888/2394] 2nd arguments is necessary in mb_parse_str because register_globals was removed in PHP 5.4. --- ext/mbstring/mbstring.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 886c2cdc92a74..75eb48f0a77d4 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -245,7 +245,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_preferred_mime_name, 0, 0, 1) ZEND_ARG_INFO(0, encoding) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_parse_str, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_parse_str, 0, 0, 2) ZEND_ARG_INFO(0, encoded_string) ZEND_ARG_INFO(1, result) ZEND_END_ARG_INFO() @@ -2025,7 +2025,7 @@ PHP_FUNCTION(mb_preferred_mime_name) #define IS_SJIS1(c) ((((c)>=0x81 && (c)<=0x9f) || ((c)>=0xe0 && (c)<=0xf5)) ? 1 : 0) #define IS_SJIS2(c) ((((c)>=0x40 && (c)<=0x7e) || ((c)>=0x80 && (c)<=0xfc)) ? 1 : 0) -/* {{{ proto bool mb_parse_str(string encoded_string [, array result]) +/* {{{ proto bool mb_parse_str(string encoded_string , array result) Parses GET/POST/COOKIE data and sets global variables */ PHP_FUNCTION(mb_parse_str) { @@ -2036,7 +2036,7 @@ PHP_FUNCTION(mb_parse_str) const mbfl_encoding *detected; track_vars_array = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|z", &encstr, &encstr_len, &track_vars_array) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz", &encstr, &encstr_len, &track_vars_array) == FAILURE) { return; } From 3afb143e65060879fbd410895834b6ed1e720119 Mon Sep 17 00:00:00 2001 From: Etienne Kneuss Date: Thu, 8 Sep 2011 15:52:59 +0000 Subject: [PATCH 0889/2394] SplFileObject does not accept directories. It did not check for that and blindly opened the directory, which works on linux but fails on windows. Now SplFileObject uses a stat() call to make sure it isn't a directory, if it is, it fails with an exception. Tests have been changed accordingly. --- ext/spl/spl_directory.c | 11 +++++ .../tests/SplFileObject_fflush_basic_001.phpt | 5 ++- .../SplFileObject_ftruncate_error_001.phpt | 3 ++ ext/spl/tests/fileobject_003.phpt | 43 ++++++++----------- 4 files changed, 35 insertions(+), 27 deletions(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 8870926942752..55697a6a8cbde 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -2223,6 +2223,7 @@ SPL_METHOD(SplFileObject, __construct) char *p1, *p2; char *tmp_path; int tmp_path_len; + zval tmp; zend_error_handling error_handling; zend_replace_error_handling(EH_THROW, spl_ce_RuntimeException, &error_handling TSRMLS_CC); @@ -2244,6 +2245,16 @@ SPL_METHOD(SplFileObject, __construct) intern->u.file.open_mode = "r"; intern->u.file.open_mode_len = 1; } + + php_stat(intern->file_name, intern->file_name_len, FS_IS_DIR, &tmp TSRMLS_CC); + + if (Z_LVAL(tmp)) { + zend_restore_error_handling(&error_handling TSRMLS_CC); + intern->u.file.open_mode = NULL; + intern->file_name = NULL; + zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Cannot use SplFileObject with directories"); + return; + } if (spl_filesystem_file_open(intern, use_include_path, 0 TSRMLS_CC) == SUCCESS) { tmp_path_len = strlen(intern->u.file.stream->orig_path); diff --git a/ext/spl/tests/SplFileObject_fflush_basic_001.phpt b/ext/spl/tests/SplFileObject_fflush_basic_001.phpt index baab156f68987..2d8a9c80444c1 100644 --- a/ext/spl/tests/SplFileObject_fflush_basic_001.phpt +++ b/ext/spl/tests/SplFileObject_fflush_basic_001.phpt @@ -17,9 +17,12 @@ class VariableStream { var $varname; function stream_open($path, $mode, $options, &$opened_path) - { + { return true; } + + function url_stat() { + } } stream_wrapper_register("SPLtest", "VariableStream"); $ftruncate_test = ""; diff --git a/ext/spl/tests/SplFileObject_ftruncate_error_001.phpt b/ext/spl/tests/SplFileObject_ftruncate_error_001.phpt index 90b27ec4162c4..a2eef604f19d2 100644 --- a/ext/spl/tests/SplFileObject_ftruncate_error_001.phpt +++ b/ext/spl/tests/SplFileObject_ftruncate_error_001.phpt @@ -12,6 +12,9 @@ class VariableStream { { return true; } + + function url_stat() { + } } stream_wrapper_register("SPLtest", "VariableStream"); $ftruncate_test = ""; diff --git a/ext/spl/tests/fileobject_003.phpt b/ext/spl/tests/fileobject_003.phpt index 6679673700354..886bc7fab6029 100755 --- a/ext/spl/tests/fileobject_003.phpt +++ b/ext/spl/tests/fileobject_003.phpt @@ -18,18 +18,21 @@ function test($name, $lc, $lp) var_dump($o == $c); var_dump($o->getPathname() == $c->getPathname()); - $f = new SplFileObject($name); - var_dump($name); - var_dump($f->getPathName()); - $l = substr($f->getPathName(), -1); - var_dump($l != '/' && $l != '\\' && $l == $lc); - var_dump($f->getFileName()); - $l = substr($f->getFileName(), -1); - var_dump($l != '/' && $l != '\\' && $l == $lc); - var_dump($f->getPath()); - $l = substr($f->getPath(), -1); - var_dump($l != '/' && $l != '\\' && $l == $lp); - + try { + $f = new SplFileObject($name); + var_dump($name); + var_dump($f->getPathName()); + $l = substr($f->getPathName(), -1); + var_dump($l != '/' && $l != '\\' && $l == $lc); + var_dump($f->getFileName()); + $l = substr($f->getFileName(), -1); + var_dump($l != '/' && $l != '\\' && $l == $lc); + var_dump($f->getPath()); + $l = substr($f->getPath(), -1); + var_dump($l != '/' && $l != '\\' && $l == $lp); + } catch (LogicException $e) { + echo "LogicException: ".$e->getMessage()."\n"; + } $fo = $o->openFile(); var_dump($fo->getPathName(), $fo->getFileName(), $fo->getPath()); } @@ -84,13 +87,7 @@ object(SplFileInfo)#%d (2) { bool(false) bool(true) bool(true) -%s(%d) "%stests/" -string(%d) "%stests" -bool(true) -string(5) "tests" -bool(true) -string(%d) "%sspl" -bool(true) +LogicException: Cannot use SplFileObject with directories string(%d) "%stests" string(%d) "tests" string(%d) "%sspl" @@ -110,13 +107,7 @@ object(SplFileInfo)#%d (2) { bool(false) bool(true) bool(true) -%s(%d) "%stests" -string(%d) "%stests" -bool(true) -string(%d) "tests" -bool(true) -string(%d) "%sspl" -bool(true) +LogicException: Cannot use SplFileObject with directories string(%d) "%stests" string(5) "tests" string(%d) "%sspl" From 59571f6fce6038872dd4f376d9a7d51ac5ec05b4 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 16:10:07 +0000 Subject: [PATCH 0890/2394] - force LF --- ext/spl/tests/SplFileObject_fputcsv_002.phpt | 2 +- ext/spl/tests/SplFileObject_fputcsv_error.phpt | 2 +- ext/spl/tests/SplFileObject_fputcsv_variation13.phpt | 2 +- ext/spl/tests/SplFileObject_fputcsv_variation14.phpt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/spl/tests/SplFileObject_fputcsv_002.phpt b/ext/spl/tests/SplFileObject_fputcsv_002.phpt index 1e8f4c319f4b4..ded467d7b747a 100644 --- a/ext/spl/tests/SplFileObject_fputcsv_002.phpt +++ b/ext/spl/tests/SplFileObject_fputcsv_002.phpt @@ -2,7 +2,7 @@ SplFileObject::fputcsv(): Checking data after calling the function --FILE-- fputcsv(array('water', 'fruit'), ',,', '"')); diff --git a/ext/spl/tests/SplFileObject_fputcsv_variation14.phpt b/ext/spl/tests/SplFileObject_fputcsv_variation14.phpt index aa828ca0c77e7..6d1cc58486ea1 100644 --- a/ext/spl/tests/SplFileObject_fputcsv_variation14.phpt +++ b/ext/spl/tests/SplFileObject_fputcsv_variation14.phpt @@ -8,7 +8,7 @@ Test fputcsv() : usage variations - with enclosure & delimiter of two chars echo "*** Testing fputcsv() : with enclosure & delimiter of two chars and file opened in read mode ***\n"; -$fo = new SplFileObject('SplFileObject::fputcsv.csv', 'w'); +$fo = new SplFileObject('SplFileObject_fputcsv.csv', 'w'); var_dump($fo->fputcsv(array('water', 'fruit'), ',,', '""')); From dd312dda4fc68351179f996154ea0bda376f475b Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 16:11:03 +0000 Subject: [PATCH 0891/2394] - force LF From 72ebf32b49423a721dcb274f77ab4edf0f99b81c Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Thu, 8 Sep 2011 16:57:41 +0000 Subject: [PATCH 0892/2394] - Updated to-do. --- ext/date/TODO | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/date/TODO b/ext/date/TODO index 4b1237c4a918a..a585b055167c0 100644 --- a/ext/date/TODO +++ b/ext/date/TODO @@ -1,6 +1,5 @@ - Port over my 200 test cases to .phpt format. - Write an error handler for unexpected characters while parsing dates. - Cache lookups for timezone information. -- Optimize parsing @ with a negative timestamp. - Make sure that date_default_timezone_set() validates the passed timezone identifier. From de264a62cf421f1370a387385d98aa3dafafe51c Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Thu, 8 Sep 2011 17:40:15 +0000 Subject: [PATCH 0893/2394] Fix skipifs to match other tests for the case when connection fails --- ext/mysqli/tests/mysqli_connect.phpt | 7 +++++-- ext/mysqli/tests/mysqli_connect_oo.phpt | 7 +++++-- ext/mysqli/tests/mysqli_connect_oo_defaults.phpt | 7 +++++-- ext/mysqli/tests/mysqli_debug_ini.phpt | 1 + 4 files changed, 16 insertions(+), 6 deletions(-) diff --git a/ext/mysqli/tests/mysqli_connect.phpt b/ext/mysqli/tests/mysqli_connect.phpt index e9d6ed543fa95..e14d88fe71193 100644 --- a/ext/mysqli/tests/mysqli_connect.phpt +++ b/ext/mysqli/tests/mysqli_connect.phpt @@ -1,8 +1,11 @@ --TEST-- mysqli_connect() --SKIPIF-- - - + --FILE-- - + --FILE-- - + --FILE-- Date: Thu, 8 Sep 2011 17:52:45 +0000 Subject: [PATCH 0894/2394] Fix skipifs --- ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt | 2 ++ ext/pdo_mysql/tests/pdo_mysql_interface.phpt | 1 + 2 files changed, 3 insertions(+) diff --git a/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt b/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt index ea25cdc321134..29b3c11f76b8f 100644 --- a/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql___construct_options.phpt @@ -3,6 +3,8 @@ MySQL PDO->__construct(), options --SKIPIF-- --FILE-- Date: Thu, 8 Sep 2011 20:13:32 +0000 Subject: [PATCH 0895/2394] Update SKIPIFs for test portability --- ext/pdo/tests/bug_36798.phpt | 6 ++++++ ext/pdo_oci/tests/pdo_oci_fread_1.phpt | 1 + ext/pdo_oci/tests/pdo_oci_stream_1.phpt | 1 + 3 files changed, 8 insertions(+) diff --git a/ext/pdo/tests/bug_36798.phpt b/ext/pdo/tests/bug_36798.phpt index 5a40bb78c7e9d..9da703e84ff8e 100644 --- a/ext/pdo/tests/bug_36798.phpt +++ b/ext/pdo/tests/bug_36798.phpt @@ -7,6 +7,12 @@ $dir = getenv('REDIR_TEST_DIR'); if (false == $dir) die('skip no driver'); require_once $dir . 'pdo_test.inc'; PDOTest::skip(); + +if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))){ + if (!strpos(strtolower(getenv('PDOTEST_DSN')), 'charset=we8mswin1252')) die('skip expected output valid for Oracle with WE8MSWIN1252 character set'); + +} + ?> --FILE-- --FILE-- diff --git a/ext/pdo_oci/tests/pdo_oci_stream_1.phpt b/ext/pdo_oci/tests/pdo_oci_stream_1.phpt index d054f88d4baf1..27a28b9bb83af 100644 --- a/ext/pdo_oci/tests/pdo_oci_stream_1.phpt +++ b/ext/pdo_oci/tests/pdo_oci_stream_1.phpt @@ -4,6 +4,7 @@ PDO_OCI: stream_get_contents length & offset test --FILE-- From 4ccef0b95068cd22aa0238cbdaafb8f4291049b9 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 23:07:48 +0000 Subject: [PATCH 0896/2394] - improve r316420 (SplFileObject cannot and should not accept directories) --- ext/spl/spl_directory.c | 13 ++++++++++++- ext/spl/tests/fileobject_003.phpt | 16 ++++++++-------- 2 files changed, 20 insertions(+), 9 deletions(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 55697a6a8cbde..209d2aeb07fb4 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -251,7 +251,18 @@ static void spl_filesystem_dir_open(spl_filesystem_object* intern, char *path TS static int spl_filesystem_file_open(spl_filesystem_object *intern, int use_include_path, int silent TSRMLS_DC) /* {{{ */ { + zval tmp; + intern->type = SPL_FS_FILE; + + php_stat(intern->file_name, intern->file_name_len, FS_IS_DIR, &tmp TSRMLS_CC); + if (Z_LVAL(tmp)) { + intern->u.file.open_mode = NULL; + intern->file_name = NULL; + zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Cannot use SplFileObject with directories"); + return; + } + intern->u.file.context = php_stream_context_from_zval(intern->u.file.zcontext, 0); intern->u.file.stream = php_stream_open_wrapper_ex(intern->file_name, intern->u.file.open_mode, (use_include_path ? USE_PATH : 0) | REPORT_ERRORS, NULL, intern->u.file.context); @@ -2255,7 +2266,7 @@ SPL_METHOD(SplFileObject, __construct) zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Cannot use SplFileObject with directories"); return; } - + if (spl_filesystem_file_open(intern, use_include_path, 0 TSRMLS_CC) == SUCCESS) { tmp_path_len = strlen(intern->u.file.stream->orig_path); diff --git a/ext/spl/tests/fileobject_003.phpt b/ext/spl/tests/fileobject_003.phpt index 886bc7fab6029..6cc650b7b5fd7 100755 --- a/ext/spl/tests/fileobject_003.phpt +++ b/ext/spl/tests/fileobject_003.phpt @@ -33,8 +33,12 @@ function test($name, $lc, $lp) } catch (LogicException $e) { echo "LogicException: ".$e->getMessage()."\n"; } - $fo = $o->openFile(); - var_dump($fo->getPathName(), $fo->getFileName(), $fo->getPath()); + try { + $fo = $o->openFile(); + var_dump($fo->getPathName(), $fo->getFileName(), $fo->getPath()); + } catch (LogicException $e) { + echo "LogicException: ".$e->getMessage()."\n"; + } } test(dirname(__FILE__) . '/' . 'fileobject_001a.txt', 't', substr(dirname(__FILE__),-1)); @@ -88,9 +92,7 @@ bool(false) bool(true) bool(true) LogicException: Cannot use SplFileObject with directories -string(%d) "%stests" -string(%d) "tests" -string(%d) "%sspl" +LogicException: Cannot use SplFileObject with directories ===2=== object(SplFileInfo)#%d (2) { ["pathName":"SplFileInfo":private]=> @@ -108,7 +110,5 @@ bool(false) bool(true) bool(true) LogicException: Cannot use SplFileObject with directories -string(%d) "%stests" -string(5) "tests" -string(%d) "%sspl" +LogicException: Cannot use SplFileObject with directories ===DONE=== From 6550af384febfae45a0bd2a6192e07d74cb5f8a9 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Thu, 8 Sep 2011 23:12:32 +0000 Subject: [PATCH 0897/2394] - improve r316420 (SplFileObject cannot and should not accept directories) --- ext/spl/spl_directory.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 209d2aeb07fb4..308a2b5817de9 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -2257,16 +2257,6 @@ SPL_METHOD(SplFileObject, __construct) intern->u.file.open_mode_len = 1; } - php_stat(intern->file_name, intern->file_name_len, FS_IS_DIR, &tmp TSRMLS_CC); - - if (Z_LVAL(tmp)) { - zend_restore_error_handling(&error_handling TSRMLS_CC); - intern->u.file.open_mode = NULL; - intern->file_name = NULL; - zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Cannot use SplFileObject with directories"); - return; - } - if (spl_filesystem_file_open(intern, use_include_path, 0 TSRMLS_CC) == SUCCESS) { tmp_path_len = strlen(intern->u.file.stream->orig_path); From ba07a1c72be0dca7144d5b948632ff42bb162906 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 9 Sep 2011 07:56:42 +0000 Subject: [PATCH 0898/2394] - improve r316420, function must return a value --- ext/spl/spl_directory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 308a2b5817de9..0a3b9abf67547 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -260,7 +260,7 @@ static int spl_filesystem_file_open(spl_filesystem_object *intern, int use_inclu intern->u.file.open_mode = NULL; intern->file_name = NULL; zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Cannot use SplFileObject with directories"); - return; + return FAILURE; } intern->u.file.context = php_stream_context_from_zval(intern->u.file.zcontext, 0); From c35d34a10d1d907d6ba9b9589bedda3c58e9da77 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 9 Sep 2011 07:57:29 +0000 Subject: [PATCH 0899/2394] - nuke unused var --- ext/spl/spl_directory.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index 0a3b9abf67547..b50e71a601a48 100755 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -2234,7 +2234,6 @@ SPL_METHOD(SplFileObject, __construct) char *p1, *p2; char *tmp_path; int tmp_path_len; - zval tmp; zend_error_handling error_handling; zend_replace_error_handling(EH_THROW, spl_ce_RuntimeException, &error_handling TSRMLS_CC); From 199118c2c4665a93ee46e70285df5f3fbdbb8451 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Fri, 9 Sep 2011 08:11:43 +0000 Subject: [PATCH 0900/2394] - force LF From 987c3941438664a859beda518dc26caed20b6ce4 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Fri, 9 Sep 2011 08:28:57 +0000 Subject: [PATCH 0901/2394] Being smart and cleanup/rename/modify tests seconds before committing isn't very smart. --- ext/curl/tests/bug54798.phpt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/curl/tests/bug54798.phpt b/ext/curl/tests/bug54798.phpt index eac9662d091ee..6fd85131d32b8 100644 --- a/ext/curl/tests/bug54798.phpt +++ b/ext/curl/tests/bug54798.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #48203 (Crash when file pointers passed to curl are closed before calling curl_exec) +Bug #54798 (Segfault when CURLOPT_STDERR file pointer is closed before calling curl_exec) --SKIPIF-- --CLEAN-- - + --EXPECTF-- -Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %sbug48203_2.php on line %d +Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %sbug54798.php on line %d * About to connect() %a * Closing connection #%d Ok for CURLOPT_STDERR Ok for CURLOPT_WRITEHEADER Ok for CURLOPT_FILE -Warning: curl_exec(): CURLOPT_INFILE resource has gone away, resetting to default in %sbug48203_2.php on line %d +Warning: curl_exec(): CURLOPT_INFILE resource has gone away, resetting to default in %sbug54798.php on line %d Ok for CURLOPT_INFILE From 6cb483cff8f9eaf7be72bc7686c2c452a942b490 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Fri, 9 Sep 2011 12:12:08 +0000 Subject: [PATCH 0902/2394] Bug #55653 --- ext/mysqli/tests/bug55653.phpt | 36 ++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 ext/mysqli/tests/bug55653.phpt diff --git a/ext/mysqli/tests/bug55653.phpt b/ext/mysqli/tests/bug55653.phpt new file mode 100644 index 0000000000000..f9cd297eba326 --- /dev/null +++ b/ext/mysqli/tests/bug55653.phpt @@ -0,0 +1,36 @@ +--TEST-- +Bug #55653 PS crash with libmysql when binding same variable as param and out +--SKIPIF-- + +--FILE-- +stmt_init())) + printf("[002] [%d] %s\n", $link->errno, $link->error); + + if (!($stmt->prepare("SELECT ?")) || + !($stmt->bind_param("s", $in_and_out)) || + !($stmt->execute()) || + !($stmt->bind_result($in_and_out))) + printf("[003] [%d] %s\n", $stmt->errno, $stmt->error); + + if (!$stmt->fetch()) + printf("[004] [%d] %s\n", $stmt->errno, $stmt->error); + + if ("a" !== $in_and_out) + printf("[005] Wrong result: '%s'\n", $in_and_out); + + echo "done!"; +?> +--EXPECT-- +done! \ No newline at end of file From 5e477ae1f899c6382f86f51ee309d7640ec598db Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 10 Sep 2011 03:51:16 +0000 Subject: [PATCH 0903/2394] Fixed Bug #55653(PS crash with libmysql when binding same variable as param and out) Actually this caused by attempt to efree a INTERNED string --- ext/mysqli/mysqli_api.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index e20d963fbb496..1649597c97c5a 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -887,7 +887,7 @@ void mysqli_stmt_fetch_libmysql(INTERNAL_FUNCTION_PARAMETERS) */ /* Even if the string is of length zero there is one byte alloced so efree() in all cases */ if (Z_TYPE_P(stmt->result.vars[i]) == IS_STRING) { - efree(stmt->result.vars[i]->value.str.val); + STR_FREE(stmt->result.vars[i]->value.str.val); } if (!stmt->result.is_null[i]) { switch (stmt->result.buf[i].type) { From 0fdeda6bf084f2c46c2fb1b6186786c1f7b59eca Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sat, 10 Sep 2011 05:29:29 +0000 Subject: [PATCH 0904/2394] revert bad test change --- ext/session/tests/rfc1867_invalid_settings.phpt | 2 -- ext/session/tests/rfc1867_invalid_settings_2.phpt | 2 -- 2 files changed, 4 deletions(-) diff --git a/ext/session/tests/rfc1867_invalid_settings.phpt b/ext/session/tests/rfc1867_invalid_settings.phpt index 173b95a025e38..29fe630509acc 100644 --- a/ext/session/tests/rfc1867_invalid_settings.phpt +++ b/ext/session/tests/rfc1867_invalid_settings.phpt @@ -9,7 +9,5 @@ session.upload_progress.freq=-1 var_dump(ini_get("session.upload_progress.freq")); ?> --EXPECTF-- -PHP Warning: PHP Startup: session.upload_progress.freq must be greater than or equal to zero in %s - Warning: PHP Startup: session.upload_progress.freq must be greater than or equal to zero in %s string(%d) "1%" diff --git a/ext/session/tests/rfc1867_invalid_settings_2.phpt b/ext/session/tests/rfc1867_invalid_settings_2.phpt index 3028808107227..bd35852c1dbfb 100644 --- a/ext/session/tests/rfc1867_invalid_settings_2.phpt +++ b/ext/session/tests/rfc1867_invalid_settings_2.phpt @@ -9,7 +9,5 @@ session.upload_progress.freq=200% var_dump(ini_get("session.upload_progress.freq")); ?> --EXPECTF-- -PHP Warning: PHP Startup: session.upload_progress.freq cannot be over 100% in %s - Warning: PHP Startup: session.upload_progress.freq cannot be over 100% in %s string(%d) "1%" From 2a6a890c465144ea7395e3f35edbb9bdac7a7c6e Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sat, 10 Sep 2011 05:36:14 +0000 Subject: [PATCH 0905/2394] Fix error message --- ext/phar/tests/fatal_error_webphar.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/phar/tests/fatal_error_webphar.phpt b/ext/phar/tests/fatal_error_webphar.phpt index 84f94dc74ef76..9d0970d17833c 100644 --- a/ext/phar/tests/fatal_error_webphar.phpt +++ b/ext/phar/tests/fatal_error_webphar.phpt @@ -15,4 +15,4 @@ Content-type: text/html; charset=UTF-8 --EXPECTF-- string(9) "\Web\View" -Parse error: syntax error, unexpected "echo (T_ECHO)", expecting "function (T_FUNCTION)" in phar:///%sfatal_error_webphar.php/Web/View.php on line 380 +Parse error: syntax error, unexpected 'echo' (T_ECHO), expecting function (T_FUNCTION) in phar:///%sfatal_error_webphar.php/Web/View.php on line 380 From 77a08e1601fb174f1b83e5c367fb64f23022ce4a Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 10 Sep 2011 13:02:00 +0000 Subject: [PATCH 0906/2394] - Fix test --- ext/snmp/tests/wrong_hostname.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/snmp/tests/wrong_hostname.phpt b/ext/snmp/tests/wrong_hostname.phpt index 4ab087e41fc6e..53c6b22cb01d4 100644 --- a/ext/snmp/tests/wrong_hostname.phpt +++ b/ext/snmp/tests/wrong_hostname.phpt @@ -18,5 +18,5 @@ var_dump(snmpget('192.168..6.1', 'community', '.1.3.6.1.2.1.1.1.0', $timeout, $r ?> --EXPECTF-- -Warning: snmpget(): php_network_getaddresses: getaddrinfo failed: hostname nor servname provided, or not known in %s on line %d +Warning: snmpget(): php_network_getaddresses:%snot known in %s on line %d bool(false) From e7fa9ffc2107ef7164c5467631c0515732951018 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 11 Sep 2011 02:16:34 +0000 Subject: [PATCH 0907/2394] removed test script which depends on the removed register_globals. --- ext/mbstring/tests/bug20087.phpt | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 ext/mbstring/tests/bug20087.phpt diff --git a/ext/mbstring/tests/bug20087.phpt b/ext/mbstring/tests/bug20087.phpt deleted file mode 100644 index bcd190185b115..0000000000000 --- a/ext/mbstring/tests/bug20087.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -Bug #20087 (Assertion failure) ---SKIPIF-- - ---XFAIL-- -register_globals calls killed the ability for mb_parse_str() to register into the global scope ---FILE-- - ---EXPECT-- -bool(true) -string(0) "" -bool(true) -string(3) "moo" - From efd856377746360b2fe61b025b57e6b15c97b94b Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 11 Sep 2011 03:57:31 +0000 Subject: [PATCH 0908/2394] revert previous commit. --- ext/mbstring/tests/bug20087.phpt | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 ext/mbstring/tests/bug20087.phpt diff --git a/ext/mbstring/tests/bug20087.phpt b/ext/mbstring/tests/bug20087.phpt new file mode 100644 index 0000000000000..bcd190185b115 --- /dev/null +++ b/ext/mbstring/tests/bug20087.phpt @@ -0,0 +1,22 @@ +--TEST-- +Bug #20087 (Assertion failure) +--SKIPIF-- + +--XFAIL-- +register_globals calls killed the ability for mb_parse_str() to register into the global scope +--FILE-- + +--EXPECT-- +bool(true) +string(0) "" +bool(true) +string(3) "moo" + From 01bb437b8568599bfb28aec198b6e16f00411fc1 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 11 Sep 2011 12:12:24 +0000 Subject: [PATCH 0909/2394] fixed test case failures. --- ext/mbstring/libmbfl/filters/mbfilter_utf32.c | 11 +- ext/mbstring/mbstring.c | 17 +- ext/mbstring/tests/bug20087.phpt | 2 +- ext/mbstring/tests/bug28220.phpt | 2 +- ext/mbstring/tests/bug49536.phpt | 2 +- .../tests/illformed_utf_sequences.phpt | 241 +++++++++++------- ext/mbstring/tests/mb_parse_str.phpt | 2 +- ext/mbstring/tests/mb_parse_str02.phpt | 2 +- 8 files changed, 183 insertions(+), 96 deletions(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf32.c b/ext/mbstring/libmbfl/filters/mbfilter_utf32.c index 56d6dd4c979f8..3cef6b051aeef 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_utf32.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_utf32.c @@ -173,6 +173,9 @@ int mbfl_filt_conv_utf32_wchar(int c, mbfl_convert_filter *filter) filter->status &= ~0xff; if (n < MBFL_WCSPLANE_UTF32MAX && (n < 0xd800 || n > 0xdfff)) { CK((*filter->output_function)(n, filter->data)); + } else { + n = (n & MBFL_WCSGROUP_MASK) | MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(n, filter->data)); } } break; @@ -205,6 +208,9 @@ int mbfl_filt_conv_utf32be_wchar(int c, mbfl_convert_filter *filter) n = (c & 0xff) | filter->cache; if (n < MBFL_WCSPLANE_UTF32MAX && (n < 0xd800 || n > 0xdfff)) { CK((*filter->output_function)(n, filter->data)); + } else { + n = (n & MBFL_WCSGROUP_MASK) | MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(n, filter->data)); } } return c; @@ -253,7 +259,10 @@ int mbfl_filt_conv_utf32le_wchar(int c, mbfl_convert_filter *filter) n = ((c & 0xff) << 24) | filter->cache; if (n < MBFL_WCSPLANE_UTF32MAX && (n < 0xd800 || n > 0xdfff)) { CK((*filter->output_function)(n, filter->data)); - } + } else { + n = (n & MBFL_WCSGROUP_MASK) | MBFL_WCSGROUP_THROUGH; + CK((*filter->output_function)(n, filter->data)); + } } return c; } diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 75eb48f0a77d4..af68c2b104776 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -2025,7 +2025,7 @@ PHP_FUNCTION(mb_preferred_mime_name) #define IS_SJIS1(c) ((((c)>=0x81 && (c)<=0x9f) || ((c)>=0xe0 && (c)<=0xf5)) ? 1 : 0) #define IS_SJIS2(c) ((((c)>=0x40 && (c)<=0x7e) || ((c)>=0x80 && (c)<=0xfc)) ? 1 : 0) -/* {{{ proto bool mb_parse_str(string encoded_string , array result) +/* {{{ proto bool mb_parse_str(string encoded_string [, array result]) Parses GET/POST/COOKIE data and sets global variables */ PHP_FUNCTION(mb_parse_str) { @@ -2036,12 +2036,12 @@ PHP_FUNCTION(mb_parse_str) const mbfl_encoding *detected; track_vars_array = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz", &encstr, &encstr_len, &track_vars_array) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|z", &encstr, &encstr_len, &track_vars_array) == FAILURE) { return; } - /* Clear out the array */ if (track_vars_array != NULL) { + /* Clear out the array */ zval_dtor(track_vars_array); array_init(track_vars_array); } @@ -2057,7 +2057,16 @@ PHP_FUNCTION(mb_parse_str) info.num_from_encodings = MBSTRG(http_input_list_size); info.from_language = MBSTRG(language); - detected = _php_mb_encoding_handler_ex(&info, track_vars_array, encstr TSRMLS_CC); + if (track_vars_array != NULL) { + detected = _php_mb_encoding_handler_ex(&info, track_vars_array, encstr TSRMLS_CC); + } else { + zval tmp; + if (!EG(active_symbol_table)) { + zend_rebuild_symbol_table(TSRMLS_C); + } + Z_ARRVAL(tmp) = EG(active_symbol_table); + detected = _php_mb_encoding_handler_ex(&info, &tmp, encstr TSRMLS_CC); + } MBSTRG(http_input_identify) = detected; diff --git a/ext/mbstring/tests/bug20087.phpt b/ext/mbstring/tests/bug20087.phpt index bcd190185b115..01bcc90388ea0 100644 --- a/ext/mbstring/tests/bug20087.phpt +++ b/ext/mbstring/tests/bug20087.phpt @@ -2,7 +2,7 @@ Bug #20087 (Assertion failure) --SKIPIF-- ---XFAIL-- +--FAIL-- register_globals calls killed the ability for mb_parse_str() to register into the global scope --FILE-- --EXPECT-- -8101 +8085 63 diff --git a/ext/mbstring/tests/bug49536.phpt b/ext/mbstring/tests/bug49536.phpt index 32685d22673c7..40328f79f038a 100644 --- a/ext/mbstring/tests/bug49536.phpt +++ b/ext/mbstring/tests/bug49536.phpt @@ -16,5 +16,5 @@ var_dump(mb_detect_encoding("\xc0\x00", "UTF-8", true)); --EXPECT-- string(4) "SJIS" bool(false) -string(5) "UTF-8" +bool(false) bool(false) diff --git a/ext/mbstring/tests/illformed_utf_sequences.phpt b/ext/mbstring/tests/illformed_utf_sequences.phpt index a462cd074538d..b5b9d94db8479 100644 --- a/ext/mbstring/tests/illformed_utf_sequences.phpt +++ b/ext/mbstring/tests/illformed_utf_sequences.phpt @@ -4,145 +4,214 @@ Unicode standard conformance test (ill-formed UTF sequences.) --FILE-- > 12), 0x80 | ($i >> 6) & 0x3f, 0x80 | $i & 0x3f), "UCS-4BE", "UTF-8"); + $s = chk_enc(pack('C3', 0xe0 | ($i >> 12), 0x80 | ($i >> 6) & 0x3f, 0x80 | $i & 0x3f), 2); + if ($s === false) { + $cnt++; + } else { + $out .= $s; + } } -var_dump(bin2hex($out)); +var_dump($cnt); +var_dump($out); echo "UTF-32 code range\n"; -var_dump(bin2hex(mb_convert_encoding("\x00\x11\x00\x00", "UCS-4BE", "UTF-32BE"))); -var_dump(bin2hex(mb_convert_encoding("\x00\x10\xff\xff", "UCS-4BE", "UTF-32BE"))); -var_dump(bin2hex(mb_convert_encoding("\x00\x00\x11\x00", "UCS-4BE", "UTF-32LE"))); -var_dump(bin2hex(mb_convert_encoding("\xff\xff\x10\x00", "UCS-4BE", "UTF-32LE"))); -var_dump(bin2hex(mb_convert_encoding("\x00\x11\x00\x00", "UCS-4BE", "UTF-32"))); -var_dump(bin2hex(mb_convert_encoding("\x00\x10\xff\xff", "UCS-4BE", "UTF-32"))); -var_dump(bin2hex(mb_convert_encoding("\x00\x00\xfe\xff\x00\x11\x00\x00", "UCS-4BE", "UTF-32"))); -var_dump(bin2hex(mb_convert_encoding("\x00\x00\xfe\xff\x00\x10\xff\xff", "UCS-4BE", "UTF-32"))); -var_dump(bin2hex(mb_convert_encoding("\xff\xfe\x00\x00\x00\x00\x11\x00", "UCS-4BE", "UTF-32"))); -var_dump(bin2hex(mb_convert_encoding("\xff\xfe\x00\x00\xff\xff\x10\x00", "UCS-4BE", "UTF-32"))); +var_dump(chk_enc("\x00\x11\x00\x00", 1, "UTF-32BE")); +var_dump(chk_enc("\x00\x10\xff\xff", 0, "UTF-32BE")); +var_dump(chk_enc("\x00\x00\x11\x00", 1, "UTF-32LE")); +var_dump(chk_enc("\xff\xff\x10\x00", 0, "UTF-32LE")); +var_dump(chk_enc("\x00\x11\x00\x00", 1, "UTF-32")); +var_dump(chk_enc("\x00\x10\xff\xff", 0, "UTF-32")); +var_dump(chk_enc("\x00\x00\xfe\xff\x00\x11\x00\x00", 0, "UTF-32")); +var_dump(chk_enc("\x00\x00\xfe\xff\x00\x10\xff\xff", 0, "UTF-32")); +var_dump(chk_enc("\xff\xfe\x00\x00\x00\x00\x11\x00", 0, "UTF-32")); +var_dump(chk_enc("\xff\xfe\x00\x00\xff\xff\x10\x00", 0, "UTF-32")); echo "UTF-32 and surrogates area\n"; $out = ''; +$cnt = 0; for ($i = 0xd7ff; $i <= 0xe000; ++$i) { - $out .= mb_convert_encoding(pack('C4', $i >> 24, ($i >> 16) & 0xff, ($i >> 8) & 0xff, $i & 0xff), "UCS-4BE", "UTF-32BE"); + $s = chk_enc(pack('C4', $i >> 24, ($i >> 16) & 0xff, ($i >> 8) & 0xff, $i & 0xff), 1, "UTF-32BE"); + if ($s === false) { + $cnt++; + } else { + $out .= $s; + } } -var_dump(bin2hex($out)); +var_dump($cnt); +var_dump($out); $out = ''; +$cnt = 0; for ($i = 0xd7ff; $i <= 0xe000; ++$i) { - $out .= mb_convert_encoding(pack('C4', $i & 0xff, ($i >> 8) & 0xff, ($i >> 16) & 0xff, ($i >> 24) & 0xff), "UCS-4BE", "UTF-32LE"); + $s = chk_enc(pack('C4', $i & 0xff, ($i >> 8) & 0xff, ($i >> 16) & 0xff, ($i >> 24) & 0xff), 1, "UTF-32LE"); + if ($s === false) { + $cnt++; + } else { + $out .= $s; + } } -var_dump(bin2hex($out)); +var_dump($cnt); +var_dump($out); $out = ''; +$cnt = 0; for ($i = 0xd7ff; $i <= 0xe000; ++$i) { - $out .= mb_convert_encoding(pack('C4', $i >> 24, ($i >> 16) & 0xff, ($i >> 8) & 0xff, $i & 0xff), "UCS-4BE", "UTF-32"); + $s = chk_enc(pack('C4', $i >> 24, ($i >> 16) & 0xff, ($i >> 8) & 0xff, $i & 0xff), 1, "UTF-32"); + if ($s === false) { + $cnt++; + } else { + $out .= $s; + } } -var_dump(bin2hex($out)); +var_dump($cnt); +var_dump($out); + +echo "UTF-32 and surrogates area with BOM\n"; $out = ''; +$cnt = 0; for ($i = 0xd7ff; $i <= 0xe000; ++$i) { - $out .= mb_convert_encoding("\x00\x00\xfe\xff". pack('C4', $i >> 24, ($i >> 16) & 0xff, ($i >> 8) & 0xff, $i & 0xff), "UCS-4BE", "UTF-32"); + $s = chk_enc("\x00\x00\xfe\xff". pack('C4', $i >> 24, ($i >> 16) & 0xff, ($i >> 8) & 0xff, $i & 0xff), + 1, "UTF-32", true); + if ($s === false) { + $cnt++; + } else { + $out .= $s; + } } -var_dump(bin2hex(str_replace("\x00\x00\xfe\xff", "", $out))); - +var_dump($cnt); +var_dump(str_replace("0000feff","",$out)); $out = ''; +$cnt = 0; for ($i = 0xd7ff; $i <= 0xe000; ++$i) { - $out .= mb_convert_encoding("\xff\xfe\x00\x00". pack('C4', $i & 0xff, ($i >> 8) & 0xff, ($i >> 16) & 0xff, ($i >> 24) & 0xff), "UCS-4BE", "UTF-32"); + $s = chk_enc("\xff\xfe\x00\x00". pack('C4', $i & 0xff, ($i >> 8) & 0xff, ($i >> 16) & 0xff, ($i >> 24) & 0xff), + 1, "UTF-32", true); + if ($s === false) { + $cnt++; + } else { + $out .= $s; + } } -var_dump(bin2hex(str_replace("\x00\x00\xfe\xff", "", $out))); +var_dump($cnt); +var_dump(str_replace("0000feff","",$out)); + ?> --EXPECT-- UTF-8 redundancy string(24) "000000310000003200000033" string(24) "000000410000004200000043" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) string(24) "000000a2000000a3000000a5" -string(0) "" -string(0) "" -string(0) "" -string(0) "" -string(0) "" +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) string(8) "00000080" string(8) "000007ff" -string(0) "" +bool(false) string(8) "00000800" string(8) "0000ffff" -string(0) "" +bool(false) string(8) "00010000" -string(8) "001fffff" -string(0) "" -string(8) "00200000" -string(8) "03ffffff" -string(0) "" -string(8) "04000000" -string(8) "6fffffff" -string(0) "" +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) UTF-8 and surrogates area +int(2048) string(16) "0000d7ff0000e000" UTF-32 code range -string(0) "" +bool(false) string(8) "0010ffff" -string(0) "" +bool(false) string(8) "0010ffff" -string(0) "" +bool(false) string(8) "0010ffff" -string(8) "0000feff" +string(16) "0000feff0000fffd" string(16) "0000feff0010ffff" -string(8) "0000feff" +string(16) "0000feff0000fffd" string(16) "0000feff0010ffff" UTF-32 and surrogates area +int(2048) string(16) "0000d7ff0000e000" +int(2048) string(16) "0000d7ff0000e000" +int(2048) string(16) "0000d7ff0000e000" +UTF-32 and surrogates area with BOM +int(2048) string(16) "0000d7ff0000e000" +int(2048) string(16) "0000d7ff0000e000" diff --git a/ext/mbstring/tests/mb_parse_str.phpt b/ext/mbstring/tests/mb_parse_str.phpt index f11b943c2628c..59d187bd05fc2 100644 --- a/ext/mbstring/tests/mb_parse_str.phpt +++ b/ext/mbstring/tests/mb_parse_str.phpt @@ -2,7 +2,7 @@ mb_parse_str() --SKIPIF-- ---XFAIL-- +--FAIL-- register_globals calls killed the ability for mb_parse_str() to register into the global scope --INI-- arg_separator.input=& diff --git a/ext/mbstring/tests/mb_parse_str02.phpt b/ext/mbstring/tests/mb_parse_str02.phpt index d9b5eb20d9380..f35699928e0f9 100644 --- a/ext/mbstring/tests/mb_parse_str02.phpt +++ b/ext/mbstring/tests/mb_parse_str02.phpt @@ -2,7 +2,7 @@ mb_parse_str() test 2 --SKIPIF-- ---XFAIL-- +--FAIL-- register_globals calls killed the ability for mb_parse_str() to register into the global scope --INI-- arg_separator.input=&# From 5ae70c757bb256d71dce611c8232bdce2ab25e26 Mon Sep 17 00:00:00 2001 From: Rui Hirokawa Date: Sun, 11 Sep 2011 12:29:00 +0000 Subject: [PATCH 0910/2394] fixed test case failures. --- ext/mbstring/tests/mb_ereg_search_pos.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/tests/mb_ereg_search_pos.phpt b/ext/mbstring/tests/mb_ereg_search_pos.phpt index fcd98e16c6848..08fcd7f87b636 100644 --- a/ext/mbstring/tests/mb_ereg_search_pos.phpt +++ b/ext/mbstring/tests/mb_ereg_search_pos.phpt @@ -6,7 +6,7 @@ if (!extension_loaded('mbstring')) die('skip mbstring not enabled'); ?> --FILE-- Date: Sun, 11 Sep 2011 13:04:21 +0000 Subject: [PATCH 0911/2394] fixed test failure on win32. --- ext/mbstring/tests/mb_send_mail01.phpt | 3 +++ ext/mbstring/tests/mb_send_mail02.phpt | 3 +++ ext/mbstring/tests/mb_send_mail03.phpt | 3 +++ ext/mbstring/tests/mb_send_mail04.phpt | 3 +++ ext/mbstring/tests/mb_send_mail05.phpt | 3 +++ ext/mbstring/tests/mb_send_mail06.phpt | 3 +++ ext/mbstring/tests/mb_send_mail07.phpt | 3 +++ 7 files changed, 21 insertions(+) diff --git a/ext/mbstring/tests/mb_send_mail01.phpt b/ext/mbstring/tests/mb_send_mail01.phpt index 28a401e3115bd..45ca0e60550c1 100644 --- a/ext/mbstring/tests/mb_send_mail01.phpt +++ b/ext/mbstring/tests/mb_send_mail01.phpt @@ -2,6 +2,9 @@ mb_send_mail() test 1 (lang=neutral) --SKIPIF-- Date: Sun, 11 Sep 2011 13:15:40 +0000 Subject: [PATCH 0912/2394] MFH: fixed test failure on win32. --- ext/mbstring/tests/bug52861.phpt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/mbstring/tests/bug52861.phpt b/ext/mbstring/tests/bug52861.phpt index 085f3ba29715d..dedd6eb2d09fc 100644 --- a/ext/mbstring/tests/bug52861.phpt +++ b/ext/mbstring/tests/bug52861.phpt @@ -2,6 +2,9 @@ Bug #52681 (mb_send_mail() appends an extra MIME-Version header) --SKIPIF-- Date: Mon, 12 Sep 2011 09:16:04 +0000 Subject: [PATCH 0913/2394] Fixed issues when streams were closed before curl read/write from them, or cleaning Closing a original handle after copying it now no longer cleans up all resources (fixes missing CURLOPT_POSTFIELDS values among others) --- ext/curl/interface.c | 106 +++++++++++++----- ext/curl/multi.c | 24 ++++ ext/curl/php_curl.h | 1 + ext/curl/tests/bug48203_multi.phpt | 38 ++----- ext/curl/tests/bug54798.phpt | 5 + .../tests/curl_copy_handle_basic_002.phpt | 2 - .../tests/curl_copy_handle_basic_005.phpt | 2 - .../curl_file_deleted_before_curl_close.phpt | 1 + ext/curl/tests/curl_setopt_basic002.phpt | 2 + 9 files changed, 124 insertions(+), 57 deletions(-) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 7efc3a89501f8..45e60cd366e29 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -150,6 +150,7 @@ static struct gcry_thread_cbs php_curl_gnutls_tsl = { static void _php_curl_close_ex(php_curl *ch TSRMLS_DC); static void _php_curl_close(zend_rsrc_list_entry *rsrc TSRMLS_DC); + #define SAVE_CURL_ERROR(__handle, __err) (__handle)->err.no = (int) __err; #define CAAL(s, v) add_assoc_long_ex(return_value, s, sizeof(s), (long) v); @@ -202,6 +203,72 @@ static int php_curl_option_url(php_curl *ch, const char *url, const int len TSRM } /* }}} */ +int _php_curl_verify_handlers(php_curl *ch, int reporterror TSRMLS_DC) /* {{{ */ +{ + php_stream *stream; + if (!ch || !ch->handlers) { + return 0; + } + + if (ch->handlers->std_err) { + stream = (php_stream *) zend_fetch_resource(&ch->handlers->std_err TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + if (reporterror) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_STDERR resource has gone away, resetting to stderr"); + } + zval_ptr_dtor(&ch->handlers->std_err); + ch->handlers->std_err = NULL; + + curl_easy_setopt(ch->cp, CURLOPT_STDERR, stderr); + } + } + if (ch->handlers->read && ch->handlers->read->stream) { + stream = (php_stream *) zend_fetch_resource(&ch->handlers->read->stream TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + if (reporterror) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_INFILE resource has gone away, resetting to default"); + } + zval_ptr_dtor(&ch->handlers->read->stream); + ch->handlers->read->fd = 0; + ch->handlers->read->fp = 0; + ch->handlers->read->stream = NULL; + + curl_easy_setopt(ch->cp, CURLOPT_INFILE, (void *) ch); + } + } + if (ch->handlers->write_header && ch->handlers->write_header->stream) { + stream = (php_stream *) zend_fetch_resource(&ch->handlers->write_header->stream TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + if (reporterror) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_WRITEHEADER resource has gone away, resetting to default"); + } + zval_ptr_dtor(&ch->handlers->write_header->stream); + ch->handlers->write_header->fp = 0; + ch->handlers->write_header->stream = NULL; + + ch->handlers->write_header->method = PHP_CURL_IGNORE; + curl_easy_setopt(ch->cp, CURLOPT_WRITEHEADER, (void *) ch); + } + } + if (ch->handlers->write && ch->handlers->write->stream) { + stream = (php_stream *) zend_fetch_resource(&ch->handlers->write->stream TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + if (reporterror) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_FILE resource has gone away, resetting to default"); + } + zval_ptr_dtor(&ch->handlers->write->stream); + ch->handlers->write->fp = 0; + ch->handlers->write->stream = NULL; + + ch->handlers->write->method = PHP_CURL_STDOUT; + ch->handlers->write->type = PHP_CURL_ASCII; + curl_easy_setopt(ch->cp, CURLOPT_FILE, (void *) ch); + } + } + return 1; +} +/* }}} */ + /* {{{ arginfo */ ZEND_BEGIN_ARG_INFO_EX(arginfo_curl_version, 0, 0, 0) ZEND_ARG_INFO(0, version) @@ -335,7 +402,6 @@ PHP_INI_BEGIN() PHP_INI_END() /* }}} */ -/* }}} */ /* {{{ PHP_MINFO_FUNCTION */ PHP_MINFO_FUNCTION(curl) @@ -1392,6 +1458,7 @@ static void split_certinfo(char *string, zval *hash) efree(org); } } +/* }}} */ /* {{{ create_certinfo */ @@ -1533,6 +1600,7 @@ PHP_FUNCTION(curl_copy_handle) dupch->cp = cp; dupch->uses = 0; + ch->uses++; if (ch->handlers->write->stream) { Z_ADDREF_P(dupch->handlers->write->stream); dupch->handlers->write->stream = ch->handlers->write->stream; @@ -2207,28 +2275,10 @@ PHP_FUNCTION(curl_exec) ZEND_FETCH_RESOURCE(ch, php_curl *, &zid, -1, le_curl_name, le_curl); + _php_curl_verify_handlers(ch, 1 TSRMLS_CC); + _php_curl_cleanup_handle(ch); - if (ch->handlers->std_err) { - php_stream *stream; - stream = (php_stream*)zend_fetch_resource(&ch->handlers->std_err TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); - if (stream == NULL) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_STDERR resource has gone away, resetting to stderr"); - zval_ptr_dtor(&ch->handlers->std_err); - curl_easy_setopt(ch->cp, CURLOPT_STDERR, stderr); - } - } - if (ch->handlers->read && ch->handlers->read->stream) { - php_stream *stream; - stream = (php_stream*)zend_fetch_resource(&ch->handlers->read->stream TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); - if (stream == NULL) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLOPT_INFILE resource has gone away, resetting to default"); - zval_ptr_dtor(&ch->handlers->read->stream); - ch->handlers->read->fd = 0; - ch->handlers->read->fp = 0; - curl_easy_setopt(ch->cp, CURLOPT_INFILE, (void *) ch); - } - } error = curl_easy_perform(ch->cp); SAVE_CURL_ERROR(ch, error); /* CURLE_PARTIAL_FILE is returned by HEAD requests */ @@ -2239,6 +2289,14 @@ PHP_FUNCTION(curl_exec) RETURN_FALSE; } + if (ch->handlers->std_err) { + php_stream *stream; + stream = (php_stream*)zend_fetch_resource(&ch->handlers->std_err TSRMLS_CC, -1, NULL, NULL, 2, php_file_le_stream(), php_file_le_pstream()); + if (stream) { + php_stream_flush(stream); + } + } + if (ch->handlers->write->method == PHP_CURL_RETURN && ch->handlers->write->buf.len > 0) { smart_str_0(&ch->handlers->write->buf); RETURN_STRINGL(ch->handlers->write->buf.c, ch->handlers->write->buf.len, 1); @@ -2543,11 +2601,7 @@ static void _php_curl_close_ex(php_curl *ch TSRMLS_DC) fprintf(stderr, "DTOR CALLED, ch = %x\n", ch); #endif - /* Prevent crash inside cURL if passed file has already been closed */ - if (ch->handlers->std_err && Z_REFCOUNT_P(ch->handlers->std_err) <= 0) { - curl_easy_setopt(ch->cp, CURLOPT_STDERR, stderr); - } - + _php_curl_verify_handlers(ch, 0 TSRMLS_CC); curl_easy_cleanup(ch->cp); zend_llist_clean(&ch->to_free.str); diff --git a/ext/curl/multi.c b/ext/curl/multi.c index edcf01397402a..1c498e7fb166c 100644 --- a/ext/curl/multi.c +++ b/ext/curl/multi.c @@ -211,6 +211,19 @@ PHP_FUNCTION(curl_multi_exec) ZEND_FETCH_RESOURCE(mh, php_curlm *, &z_mh, -1, le_curl_multi_handle_name, le_curl_multi_handle); + { + zend_llist_position pos; + php_curl *ch; + zval *pz_ch; + + for(pz_ch = (zval *)zend_llist_get_first_ex(&mh->easyh, &pos); pz_ch; + pz_ch = (zval *)zend_llist_get_next_ex(&mh->easyh, &pos)) { + + ZEND_FETCH_RESOURCE(ch, php_curl *, &pz_ch, -1, le_curl_name, le_curl); + _php_curl_verify_handlers(ch, 1 TSRMLS_CC); + } + } + convert_to_long_ex(&z_still_running); still_running = Z_LVAL_P(z_still_running); result = curl_multi_perform(mh->multi, &still_running); @@ -324,6 +337,17 @@ void _php_curl_multi_close(zend_rsrc_list_entry *rsrc TSRMLS_DC) /* {{{ */ { php_curlm *mh = (php_curlm *) rsrc->ptr; if (mh) { + zend_llist_position pos; + php_curl *ch; + zval *pz_ch; + + for(pz_ch = (zval *)zend_llist_get_first_ex(&mh->easyh, &pos); pz_ch; + pz_ch = (zval *)zend_llist_get_next_ex(&mh->easyh, &pos)) { + + ch = (php_curl *) zend_fetch_resource(&pz_ch TSRMLS_CC, -1, le_curl_name, NULL, 1, le_curl); + _php_curl_verify_handlers(ch, 0 TSRMLS_CC); + } + curl_multi_cleanup(mh->multi); zend_llist_clean(&mh->easyh); efree(mh); diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index d7cbb4051ae12..a50a2b82700a0 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -150,6 +150,7 @@ typedef struct { void _php_curl_cleanup_handle(php_curl *); void _php_curl_multi_cleanup_list(void *data); +int _php_curl_verify_handlers(php_curl *ch, int reporterror TSRMLS_DC); /* streams support */ diff --git a/ext/curl/tests/bug48203_multi.phpt b/ext/curl/tests/bug48203_multi.phpt index 0be5135948671..01dc3cdd27344 100644 --- a/ext/curl/tests/bug48203_multi.phpt +++ b/ext/curl/tests/bug48203_multi.phpt @@ -67,40 +67,24 @@ foreach($options_to_check as $option) { --CLEAN-- --EXPECTF-- -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d +Warning: curl_multi_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %sbug48203_multi.php on line 36 -Warning: curl_multi_exec(): CURLOPT_STDERR handle is incorrect in %s on line %d - -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_multi_exec(): CURLOPT_STDERR handle is incorrect in %s on line %d -%a +Warning: curl_multi_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr in %sbug48203_multi.php on line 36 +%A Ok for CURLOPT_STDERR -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_multi_exec(): CURLOPT_WRITEHEADER handle is incorrect in %s on line %d - -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d +Warning: curl_multi_exec(): CURLOPT_WRITEHEADER resource has gone away, resetting to default in %sbug48203_multi.php on line 36 -Warning: curl_multi_exec(): CURLOPT_WRITEHEADER handle is incorrect in %s on line %d -%AOk for CURLOPT_WRITEHEADER +Warning: curl_multi_exec(): CURLOPT_WRITEHEADER resource has gone away, resetting to default in %sbug48203_multi.php on line 36 +Ok for CURLOPT_WRITEHEADER -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d +Warning: curl_multi_exec(): CURLOPT_FILE resource has gone away, resetting to default in %sbug48203_multi.php on line 36 -Warning: curl_multi_exec(): CURLOPT_FILE handle is incorrect in %s on line %d - -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_multi_exec(): CURLOPT_FILE handle is incorrect in %s on line %d -%a +Warning: curl_multi_exec(): CURLOPT_FILE resource has gone away, resetting to default in %sbug48203_multi.php on line 36 +%A Ok for CURLOPT_FILE -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d - -Warning: curl_multi_exec(): CURLOPT_INFILE handle is incorrect in %s on line %d - -Warning: curl_multi_exec(): %d is not a valid stream resource in %s on line %d +Warning: curl_multi_exec(): CURLOPT_INFILE resource has gone away, resetting to default in %sbug48203_multi.php on line 36 -Warning: curl_multi_exec(): CURLOPT_INFILE handle is incorrect in %s on line %d +Warning: curl_multi_exec(): CURLOPT_INFILE resource has gone away, resetting to default in %sbug48203_multi.php on line 36 Ok for CURLOPT_INFILE diff --git a/ext/curl/tests/bug54798.phpt b/ext/curl/tests/bug54798.phpt index 6fd85131d32b8..390c2eebb1411 100644 --- a/ext/curl/tests/bug54798.phpt +++ b/ext/curl/tests/bug54798.phpt @@ -59,7 +59,12 @@ Warning: curl_exec(): CURLOPT_STDERR resource has gone away, resetting to stderr * About to connect() %a * Closing connection #%d Ok for CURLOPT_STDERR + +Warning: curl_exec(): CURLOPT_WRITEHEADER resource has gone away, resetting to default in %sbug54798.php on line 24 Ok for CURLOPT_WRITEHEADER + +Warning: curl_exec(): CURLOPT_FILE resource has gone away, resetting to default in %sbug54798.php on line 24 +%a Ok for CURLOPT_FILE Warning: curl_exec(): CURLOPT_INFILE resource has gone away, resetting to default in %sbug54798.php on line %d diff --git a/ext/curl/tests/curl_copy_handle_basic_002.phpt b/ext/curl/tests/curl_copy_handle_basic_002.phpt index 0ec58436eee92..9ab33635fb3ad 100644 --- a/ext/curl/tests/curl_copy_handle_basic_002.phpt +++ b/ext/curl/tests/curl_copy_handle_basic_002.phpt @@ -29,8 +29,6 @@ Rick Buitenman var_dump( $curl_content ); ?> ===DONE=== ---XFAIL-- -This test fails, the copy seems to be missing the CURLOPT_POSTFIELDS after the original is closed --EXPECTF-- *** Testing curl copy handle with simple POST *** string(163) "array(1) { diff --git a/ext/curl/tests/curl_copy_handle_basic_005.phpt b/ext/curl/tests/curl_copy_handle_basic_005.phpt index 9444961e8b8fc..aa9e2fa998c59 100644 --- a/ext/curl/tests/curl_copy_handle_basic_005.phpt +++ b/ext/curl/tests/curl_copy_handle_basic_005.phpt @@ -32,8 +32,6 @@ Rick Buitenman var_dump( $curl_content_copy ); ?> ===DONE=== ---XFAIL-- -This test fails, the output of the copy seems to be corrupted if the original is closed after exec() --EXPECTF-- *** Test curl_copy_handle() after exec() with POST *** string(163) "array(1) { diff --git a/ext/curl/tests/curl_file_deleted_before_curl_close.phpt b/ext/curl/tests/curl_file_deleted_before_curl_close.phpt index 680ae547ce7c3..592f110fbe80b 100644 --- a/ext/curl/tests/curl_file_deleted_before_curl_close.phpt +++ b/ext/curl/tests/curl_file_deleted_before_curl_close.phpt @@ -34,4 +34,5 @@ echo "Closed correctly\n"; unlink(dirname(__FILE__) . '/curl_file_deleted_before_curl_close.tmp'); ?> --EXPECTF-- +* Closing connection #%d Closed correctly diff --git a/ext/curl/tests/curl_setopt_basic002.phpt b/ext/curl/tests/curl_setopt_basic002.phpt index 328af0d906865..d90ecb7bd22f3 100644 --- a/ext/curl/tests/curl_setopt_basic002.phpt +++ b/ext/curl/tests/curl_setopt_basic002.phpt @@ -48,3 +48,5 @@ curl_close($ch); *** Testing curl_setopt with CURLOPT_STDERR string(%d) "%S" string(%d) "%S" +* Closing connection #%d + From 1eceefc53f359516bf67ef7366ab1ea7c1cf5a33 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 12 Sep 2011 09:16:19 +0000 Subject: [PATCH 0914/2394] - force LF From 5cb30970dcb83ac2d2b43929fb5fccd01c045d51 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 12 Sep 2011 09:27:03 +0000 Subject: [PATCH 0915/2394] - unused var --- ext/mbstring/libmbfl/filters/mbfilter_cp936.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/libmbfl/filters/mbfilter_cp936.c b/ext/mbstring/libmbfl/filters/mbfilter_cp936.c index cf609bf9cc833..a3baeabdfc8fb 100644 --- a/ext/mbstring/libmbfl/filters/mbfilter_cp936.c +++ b/ext/mbstring/libmbfl/filters/mbfilter_cp936.c @@ -191,7 +191,7 @@ int mbfl_filt_conv_wchar_cp936(int c, mbfl_convert_filter *filter) { int k, k1, k2; - int c1, s = 0, s1; + int c1, s = 0; if (c >= ucs_a1_cp936_table_min && c < ucs_a1_cp936_table_max) { /* U+0000 - U+0451 */ From 8b22751c24102c0b0a3aabc37667dbf6606d34e0 Mon Sep 17 00:00:00 2001 From: Popa Adrian Marius Date: Mon, 12 Sep 2011 09:41:02 +0000 Subject: [PATCH 0916/2394] fixes bug #55659 adn 006 test for firebird driver --- ext/interbase/tests/006.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/interbase/tests/006.phpt b/ext/interbase/tests/006.phpt index 8155c9f41e853..ad6120f393ab7 100644 --- a/ext/interbase/tests/006.phpt +++ b/ext/interbase/tests/006.phpt @@ -210,7 +210,7 @@ InterBase: binding (may take a while) out_result($res, "test6"); ibase_free_result($res); - $res = ibase_execute($query, "5", 7.5); + $res = ibase_execute($query, "5", 7.499); out_result($res, "test6"); ibase_free_result($res); From b16bb9582b8d60e9685da2101a7b57f299803af7 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 12 Sep 2011 10:13:54 +0000 Subject: [PATCH 0917/2394] Merge missing test from 5_4 --- Zend/tests/bug55137.phpt | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 Zend/tests/bug55137.phpt diff --git a/Zend/tests/bug55137.phpt b/Zend/tests/bug55137.phpt new file mode 100644 index 0000000000000..4a4e6e61a24d8 --- /dev/null +++ b/Zend/tests/bug55137.phpt @@ -0,0 +1,26 @@ +--TEST-- +Bug #55137 (Changing trait static method visibility) +--FILE-- + +--EXPECT-- +abc +def From c500bd35f3abd237071a4dbba05b9666a32847e4 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 12 Sep 2011 10:20:34 +0000 Subject: [PATCH 0918/2394] These are all in 5_4 --- NEWS | 251 +---------------------------------------------------------- 1 file changed, 2 insertions(+), 249 deletions(-) diff --git a/NEWS b/NEWS index 1ce640aa352d7..2e83f29921f18 100644 --- a/NEWS +++ b/NEWS @@ -1,255 +1,8 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 201?, PHP 5.3.99 -- Upgraded bundled Sqlite3 to version 3.7.4. (Ilia) -- Upgraded bundled PCRE to version 8.10. (Ilia) - -- Removed legacy features: - . break/continue $var syntax. (Dmitry) - . Safe mode and all related ini options. (Kalle) - . register_globals and register_long_arrays ini options. (Kalle) - . import_request_variables(). (Kalle) - . allow_call_time_pass_reference. (Pierrick) - . define_syslog_variables ini option and its associated function. (Kalle) - . highlight.bg ini option. (Kalle) - . Session bug compatibility mode (session.bug_compat42 and - session.bug_compat_warn ini options). (Kalle) - . session_is_registered(), session_register() and session_unregister() - functions. (Kalle) - . y2k_compliance ini option. (Kalle) - -- Moved extensions to PECL: (Johannes) - . ext/sqlite. (Note: the ext/sqlite3 and ext/pdo_sqlite extensions are - not affected) - -- Changed $_SERVER['REQUEST_TIME'] to include microsecond precision. (Ilia) -- Changed default value of "default_charset" php.ini option from ISO-8859-1 to - UTF-8. (Rasmus) -- Changed array_combine() to return empty array instead of FALSE when both - parameter arrays are empty. FR #34857. (joel.perras@gmail.com) -- Changed third parameter of preg_match_all() to optional. FR #53238. (Adam) -- Changed silent casting of null/''/false into an Object when adding - a property into a warning. (Scott) +?? ??? 201?, PHP 5.5.0 - General improvements: - . Added multibyte support by default. Previously php had to be compiled - with --enable-zend-multibyte. Now it can be enabled or disabled through - zend.multibyte directive in php.ini (Dmitry) - . Removed compile time dependency from ext/mbstring (Dmitry) - . Added scalar typehints to the parser and the reflection API. (Ilia, Derick) - . Added support for Traits. (Stefan) - . Added closure $this support back. (Stas) - . Added array dereferencing support. (Felipe) - . Added support for object references in recursive serialize() calls. - FR #36424. (Mike) - . Added http_response_code() function. FR #52555. (Paul Dragoonis, Kalle) - . Added header_register_callback() which is invoked immediately - prior to the sending of headers and after default headers have - been added. (Scott) - . Added DTrace support. (David Soria Parra) - . Improved output layer, see README.NEW-OUTPUT-API for internals. (Mike) - . Improved unserialize() performance. - (galaxy dot mipt at gmail dot com, Kalle) - . Improved unix build system to allow building multiple PHP binary SAPIs and - one SAPI module the same time. FR #53271, FR #52410. (Jani) - . Added optional argument to debug_backtrace() and debug_print_backtrace() - to limit the amount of stack frames returned. (Sebastian, Patrick) - -- Improved Zend Engine memory usage: (Dmitry) - . Replaced zend_function.pass_rest_by_reference by - ZEND_ACC_PASS_REST_BY_REFERENCE in zend_function.fn_flags. - . Replaced zend_function.return_reference by ZEND_ACC_RETURN_REFERENCE - in zend_function.fn_flags. - . Removed zend_arg_info.required_num_args as it was only needed for internal - functions. Now the first arg_info for internal functions (which has special - meaning) is represented by zend_internal_function_info structure. - . Moved zend_op_array.size, size_var, size_literal, current_brk_cont, - backpatch_count into CG(context) as they are used only during compilation. - . Moved zend_op_array.start_op into EG(start_op) as it's used only for - 'interactive' execution of single top-level op-array. - . Replaced zend_op_array.done_pass_two by ZEND_ACC_DONE_PASS_TWO in - zend_op_array.fn_flags. - . op_array.vars array is trimmed (reallocated) during pass_two. - . Replaced zend_class_entry.constants_updated by ZEND_ACC_CONSTANTS_UPDATED - in zend_class_entry.ce_flags. - . Reduced the size of zend_class_entry by sharing the same memory space - by different information for internal and user classes. - See zend_class_entry.info union. - . Reduced size of temp_variable. - -- Changed the structure of op_array.opcodes. The constant values are moved from - opcode operands into a separate literal table. (Dmitry) - -- Improved Zend Engine, performance tweaks and optimizations: (Dmitry) - . Inlined most probable code-paths for arithmetic operations directly into - executor - . Eliminated unnecessary iterations during request startup/shutdown. - . Changed $GLOBALS into a JIT autoglobal, so it's initialized only if used. - (this may affect opcode caches!) - . Improved performance of @ (silence) operator. - . Simplified string offset reading. $str[1][0] is now a legal construct. - . Added caches to eliminate repeatable run-time bindings of functions, - classes, constants, methods and properties. - . Added concept of interned strings. All strings constants known at compile - time are allocated in a single copy and never changed. - . Added an optimization which saves memory and emalloc/efree calls for empty - HashTables. (Stas, Dmitry) - . ZEND_RECV now always has IS_CV as its result. - . ZEND_CATCH now has to be used only with constant class names. - . ZEND_FETCH_DIM_? may fetch array and dimension operands in different order. - . Simplified ZEND_FETCH_*_R operations. They can't be used with the - EXT_TYPE_UNUSED flag any more. This is a very rare and useless case. - ZEND_FREE might be required after them instead. - . Split ZEND_RETURN into two new instructions ZEND_RETURN and - ZEND_RETURN_BY_REF. - . Optimized access to global constants using values with pre-calculated - hash_values from the literals table. - . Optimized access to static properties using executor specialization. - A constant class name may be used as a direct operand of ZEND_FETCH_* - instruction without previous ZEND_FETCH_CLASS. - . zend_stack and zend_ptr_stack allocation is delayed until actual usage. - -- Improved CLI SAPI: (Johannes) - . Added command line option --rz which shows information of the - named Zend extension. - . Interactive readline shell improvements: - . Added "cli.pager" php.ini setting to set a pager for output. - . Added "cli.prompt" php.ini setting to configure the shell prompt. - . Added shortcut #inisetting=value to change ini settings at run-time. - . Changed shell not to terminate on fatal errors. - . Interactive shell works with shared readline extension. FR #53878. - -- Improved FastCGI SAPI: (Dmitry) - . Added apache compatible functions: apache_child_terminate(), - getallheaders(), apache_request_headers() and apache_response_headers() - . Improved performance of FastCGI request parsing. - -- Improved core functions: - . number_format() no longer truncates multibyte decimal points and thousand - separators to the first byte. FR #53457. (Adam) - -- Improved CURL extension: - . Added support for CURLOPT_MAX_RECV_SPEED_LARGE and - CURLOPT_MAX_SEND_SPEED_LARGE. FR #51815. (Pierrick) - -- Improved Date extension: - . Added the + modifier to parseFromFormat to allow trailing text in the - string to parse without throwing an error. (Stas, Derick) - -- Improved DBA extension: - . Added Tokyo Cabinet abstract DB support. (Michael Maclean) - . Added Berkeley DB 5 support. (Johannes, Chris Jones) - -- Improved DOM extension: - . Added the ability to pass options to loadHTML (Chregu, fxmulder at gmail dot com) - -- Improved filesystem functions: - . scandir() now accepts SCANDIR_SORT_NONE as a possible sorting_order value. - FR #53407. (Adam) - -- Improved HASH extension: - . Added Jenkins's one-at-a-time hash support. (Martin Jansen) - . Added FNV-1 hash support. (Michael Maclean) - . Made Adler32 algorithm faster. FR #53213. (zavasek at yandex dot ru) - -- Improved intl extension: - . Added Spoofchecker, allows checking for visibly confusable characters and - other security issues. (Scott) - -- Improved JSON extension: - . Added JsonSerializable interface. (Sara) - . Added JSON_BIGINT_AS_STRING, extended json_decode() sig with $options. - (Sara) - . Added support for JSON_NUMERIC_CHECK option in json_encode() that converts - numeric strings to integers. (Ilia) - . Added new json_encode() option JSON_PRETTY_PRINT. FR #44331. (Adam) - . Added new json_encode() option JSON_UNESCAPED_SLASHES. FR #49366. (Adam) - -- Improved LDAP extension: - . Added paged results support. FR #42060. (ando@OpenLDAP.org, - iarenuno@eteo.mondragon.edu, jeanseb@au-fil-du.net, remy.saissy@gmail.com) - -- Improved mbstring extension: - . Added Shift_JIS/UTF-8 Emoji (pictograms) support. (Rui) - . Added JIS X0213:2004 (Shift_JIS-2004, EUC-JP-2004, ISO-2022-JP-2004) support. (Rui) - . Ill-formed UTF-8 check for security enhancements. (Rui) - . Added MacJapanese (Shift_JIS) and gb18030 encoding support. (Rui) - . Added encode/decode in hex format to mb_[en|de]code_numericentity(). (Rui) - . Added user JIS X0213:2004 (Shift_JIS-2004, EUC-JP-2004, ISO-2022-JP-2004) support. (Rui) - . Added the user user defined area for CP936 and CP950 (Rui). - -- Improved MySQL extensions: - . MySQL: Deprecated mysql_list_dbs(). FR #50667. (Andrey) - . mysqlnd: Added named pipes support. FR #48082. (Andrey) - . MySQLi: Added iterator support in MySQLi. mysqli_result implements - Traversable. (Andrey, Johannes) - . PDO_mysql: Removed support for linking with MySQL client libraries older - than 4.1. (Johannes) - -- Improved OpenSSL extension: - . Added AES support. FR #48632. (yonas dot y at gmail dot com, Pierre) - . Added a "no_ticket" SSL context option to disable the SessionTicket TLS - extension. FR #53447. (Adam) - -- Improved PDO DB-LIB: (Stanley) - . Added nextRowset support. - . Fixed bug #50755 (PDO DBLIB Fails with OOM). - -- Improved PostgreSQL extension: - . Added support for "extra" parameter for PGNotify(). - (r dot i dot k at free dot fr, Ilia) - -- Improved Reflection extension: (Johannes) - . Added ReflectionExtension::isTemporary() and - ReflectionExtension::isPersistent() methods. - . Added ReflectionZendExtension class. - . Added ReflectionClass::isCloneable(). (Felipe) - -- Improved Session extension: - . Added support for storing upload progress feedback in session data. (Arnaud) - . Changed session.entropy_file to default to /dev/urandom or /dev/arandom if - either is present at compile time. (Rasmus) - -- Improved SPL extension: - . Added RegexIterator::getRegex() method. (Joshua Thijssen) - . Added SplObjectStorage::getHash() hook. (Etienne) - . Added CallbackFilterIterator and RecursiveCallbackFilterIterator (Arnaud) - . Added missing class_uses(..) as pointed out by #55266 (Stefan) - -- Improved XSL extension: - . Added XsltProcessor::setSecurityPrefs($options) and getSecurityPrefs() to - define forbidden operations within XSLT stylesheets, default is not to - enable write operations from XSLT. Bug #54446 (Chregu, Nicolas Gregoire) - -- Improved ZLIB extension: - . Re-implemented non-file related functionality. (Mike) - -- Improved SNMP extension (Boris Lytochkin): - . Added OO API. FR #53594 (php-snmp rewrite). - . Sanitized return values of existing functions. Now it returns FALSE on - failure. - . Allow ~infinite OIDs in GET/GETNEXT/SET queries. Autochunk them to max_oids - upon request. - . Introducing unit tests for extension with ~full coverage. - . IPv6 support. (FR #42918) - . Way of representing OID value can now be changed when SNMP_VALUE_OBJECT - is used for value output mode. Use or'ed SNMP_VALUE_LIBRARY(default if - not specified) or SNMP_VALUE_PLAIN. (FR #54502) - . Fixed bugs - . #44193 (snmp v3 noAuthNoPriv doesn't work) - . #45893 (Snmp buffer limited to 2048 char) - . #46065 (snmp_set_quick_print() persists between requests) - . #51336 (snmprealwalk (snmp v1) does not handle end of OID tree correctly) - . #53862 (snmp_set_oid_output_format does not allow returning to default) - -## UNSORTED ## - -- Fixed PDO objects binary incompatibility. (Dmitry) -- Fixed bug #52211 (iconv() returns part of string on error). (Felipe) -- Fixed bug #55450 (Built in web server not accepting file uploads). (Laruence) -- Fixed bug #55471 (ZTS build broken with dtrace). (Laruence) -- Fixed bug #55463 (cli-server missing _SERVER[REMOTE_ADDR]). (Laruence) -- Fixed bug #55473 (mysql_pconnect leaks file descriptors on reconnect). (Andrey, Laruence) -- Fixed bug #55423 (cli-server could not output correctly in some case). (Laruence, chobieee at gmail dot com) + . World domination <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From d0dbb43935b4515043736eaaa0c05014cf0daac6 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 12 Sep 2011 10:24:27 +0000 Subject: [PATCH 0919/2394] Sync line ending with 5_4 --- ext/standard/crypt_blowfish.h | 64 +++++++++++++++++------------------ 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/ext/standard/crypt_blowfish.h b/ext/standard/crypt_blowfish.h index 34316854c8beb..da374730e9d05 100644 --- a/ext/standard/crypt_blowfish.h +++ b/ext/standard/crypt_blowfish.h @@ -1,32 +1,32 @@ -/* $Id$ */ -/* - * Written by Solar Designer in 2000-2011. - * No copyright is claimed, and the software is hereby placed in the public - * domain. In case this attempt to disclaim copyright and place the software - * in the public domain is deemed null and void, then the software is - * Copyright (c) 2000-2011 Solar Designer and it is hereby released to the - * general public under the following terms: - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted. - * - * There's ABSOLUTELY NO WARRANTY, express or implied. - * - * See crypt_blowfish.c for more information. - */ - -#ifndef _CRYPT_BLOWFISH_H -#define _CRYPT_BLOWFISH_H - -#if 0 -extern int _crypt_output_magic(const char *setting, char *output, int size); -#endif -extern char *php_crypt_blowfish_rn(const char *key, const char *setting, - char *output, int size); -#if 0 -extern char *_crypt_gensalt_blowfish_rn(const char *prefix, - unsigned long count, - const char *input, int size, char *output, int output_size); -#endif - -#endif +/* $Id$ */ +/* + * Written by Solar Designer in 2000-2011. + * No copyright is claimed, and the software is hereby placed in the public + * domain. In case this attempt to disclaim copyright and place the software + * in the public domain is deemed null and void, then the software is + * Copyright (c) 2000-2011 Solar Designer and it is hereby released to the + * general public under the following terms: + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted. + * + * There's ABSOLUTELY NO WARRANTY, express or implied. + * + * See crypt_blowfish.c for more information. + */ + +#ifndef _CRYPT_BLOWFISH_H +#define _CRYPT_BLOWFISH_H + +#if 0 +extern int _crypt_output_magic(const char *setting, char *output, int size); +#endif +extern char *php_crypt_blowfish_rn(const char *key, const char *setting, + char *output, int size); +#if 0 +extern char *_crypt_gensalt_blowfish_rn(const char *prefix, + unsigned long count, + const char *input, int size, char *output, int output_size); +#endif + +#endif From 17858fc78920fce3bf830c80627f4293f2818650 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 12 Sep 2011 10:57:26 +0000 Subject: [PATCH 0920/2394] Merge from branch, make things consistent --- ext/phar/stream.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/phar/stream.c b/ext/phar/stream.c index 2addae4db5b50..21358d1a230b7 100644 --- a/ext/phar/stream.c +++ b/ext/phar/stream.c @@ -403,7 +403,7 @@ static int phar_stream_seek(php_stream *stream, off_t offset, int whence, off_t phar_entry_data *data = (phar_entry_data *)stream->abstract; phar_entry_info *entry; int res; - off_t temp = 0; + off_t temp; if (data->internal_file->link) { entry = phar_get_link_source(data->internal_file TSRMLS_CC); @@ -421,6 +421,8 @@ static int phar_stream_seek(php_stream *stream, off_t offset, int whence, off_t case SEEK_SET : temp = data->zero + offset; break; + default: + temp = 0; } if (temp > data->zero + (off_t) entry->uncompressed_filesize) { *newoffset = -1; From 7bb31903c8baa07a71c797dfe1491056636a7c9c Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 12 Sep 2011 11:44:55 +0000 Subject: [PATCH 0921/2394] Ensure we are working with strings here --- ext/pcre/php_pcre.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index 41fdb32a7b4d3..4deb58cb3ead7 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -1013,6 +1013,7 @@ PHPAPI char *php_pcre_replace_impl(pcre_cache_entry *pce, char *subject, int sub return NULL; } } else { + convert_to_string_ex(&replace_val); replace = Z_STRVAL_P(replace_val); replace_len = Z_STRLEN_P(replace_val); replace_end = replace + replace_len; From 76879f2cce2cde4312333c23bf66c1c8b8fb38e1 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 12 Sep 2011 12:14:56 +0000 Subject: [PATCH 0922/2394] Those will fail with MySQL 5.5. Running them because they have unveiled a crash, which has been fixed already. Setting to XFAIL, need to be decide if and/or how the functionality shall be supported. --- .../tests/mysqli_stmt_execute_stored_proc_next_result.phpt | 2 ++ ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt index 1469f658019df..35433b136af4c 100644 --- a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt +++ b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_next_result.phpt @@ -123,6 +123,8 @@ if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) mysqli_close($link); ?> +--XFAIL-- +Unsupported and undefined, under development --EXPECTF-- [010] More results: yes [011] Next result: yes diff --git a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt index bd3592264c43e..8c7c799def25c 100644 --- a/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt +++ b/ext/mysqli/tests/mysqli_stmt_execute_stored_proc_out.phpt @@ -73,6 +73,8 @@ if (!$link = my_mysqli_connect($host, $user, $passwd, $db, $port, $socket)) mysqli_close($link); ?> +--XFAIL-- +Unsupported and undefined, under development --EXPECTF-- [008] More results: %s [009] Next results: %s From f8ffb5af1d62abf7640d2a6938b1e64a1c23cf4e Mon Sep 17 00:00:00 2001 From: Christian Stocker Date: Mon, 12 Sep 2011 12:44:49 +0000 Subject: [PATCH 0923/2394] Added test for XSL bug 54446 --- ext/xsl/tests/bug54446.phpt | 95 +++++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 ext/xsl/tests/bug54446.phpt diff --git a/ext/xsl/tests/bug54446.phpt b/ext/xsl/tests/bug54446.phpt new file mode 100644 index 0000000000000..f00b118ff8bc3 --- /dev/null +++ b/ext/xsl/tests/bug54446.phpt @@ -0,0 +1,95 @@ +--TEST-- +Bug #54446 (Arbitrary file creation via libxslt 'output' extension) +--SKIPIF-- + +--FILE-- + + + + + + + + + +EOT; + +$xsl->loadXML( $sXsl ); + +# START XSLT +$proc->importStylesheet( $xsl ); + +# TRASNFORM & PRINT +print $proc->transformToXML( $dom ); + + +if (file_exists($outputfile)) { + print "$outputfile exists, but shouldn't!\n"; +} else { + print "OK, no file created\n"; +} + +#SET NO SECURITY PREFS +$proc->setSecurityPrefs(XSL_SECPREF_NONE); + +# TRASNFORM & PRINT +print $proc->transformToXML( $dom ); + + +if (file_exists($outputfile)) { + print "OK, file exists\n"; +} else { + print "$outputfile doesn't exist, but should!\n"; +} + +unlink($outputfile); + +#SET SECURITY PREFS AGAIN +$proc->setSecurityPrefs( XSL_SECPREF_WRITE_FILE | XSL_SECPREF_WRITE_NETWORK | XSL_SECPREF_CREATE_DIRECTORY); + +# TRASNFORM & PRINT +print $proc->transformToXML( $dom ); + +if (file_exists($outputfile)) { + print "$outputfile exists, but shouldn't!\n"; +} else { + print "OK, no file created\n"; +} + + +--EXPECTF-- +Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %s element output in %s on line %d + +Warning: XSLTProcessor::transformToXml(): File write for %s/bug54446test.txt refused in %s on line %s + +Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element output in %s on line %d + +Warning: XSLTProcessor::transformToXml(): xsltDocumentElem: write rights for %s/bug54446test.txt denied in %s on line %d +OK, no file created +OK, file exists + +Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %s element output in %s on line %d + +Warning: XSLTProcessor::transformToXml(): File write for %s/bug54446test.txt refused in %s on line %s + +Warning: XSLTProcessor::transformToXml(): runtime error: file %s line %d element output in %s on line %d + +Warning: XSLTProcessor::transformToXml(): xsltDocumentElem: write rights for %s/bug54446test.txt denied in %s on line %d +OK, no file created +--CREDITS-- +Christian Stocker, chregu@php.net + From 4891b29d6b4ffcfa29073d3ddfb05c75c7f21e05 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 12 Sep 2011 12:59:52 +0000 Subject: [PATCH 0924/2394] - revert incorrect fix introduced in r316528 --- ext/pcre/php_pcre.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index 4deb58cb3ead7..41fdb32a7b4d3 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -1013,7 +1013,6 @@ PHPAPI char *php_pcre_replace_impl(pcre_cache_entry *pce, char *subject, int sub return NULL; } } else { - convert_to_string_ex(&replace_val); replace = Z_STRVAL_P(replace_val); replace_len = Z_STRLEN_P(replace_val); replace_end = replace + replace_len; From 49e693124f2e27113cde0f4b50252827245462e9 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 12 Sep 2011 13:14:16 +0000 Subject: [PATCH 0925/2394] Hits libmysql/MySQL bug, works with mysqlnd --- ext/mysqli/tests/mysqli_explain_metadata.phpt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/mysqli/tests/mysqli_explain_metadata.phpt b/ext/mysqli/tests/mysqli_explain_metadata.phpt index 5bfb001a1855d..fc1f9dbe49d5c 100644 --- a/ext/mysqli/tests/mysqli_explain_metadata.phpt +++ b/ext/mysqli/tests/mysqli_explain_metadata.phpt @@ -5,6 +5,9 @@ EXPLAIN - metadata require_once('skipif.inc'); require_once('skipifemb.inc'); require_once('skipifconnectfailure.inc'); +require_once("connect.inc"); +if (!$IS_MYSQLND) + die("skip Open libmysql/MySQL issue http://bugs.mysql.com/?id=62350"); ?> --FILE-- Date: Mon, 12 Sep 2011 13:20:05 +0000 Subject: [PATCH 0926/2394] fixed optional argument. --- ext/mbstring/mbstring.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index af68c2b104776..f2d10e0548521 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -245,7 +245,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_preferred_mime_name, 0, 0, 1) ZEND_ARG_INFO(0, encoding) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_parse_str, 0, 0, 2) +ZEND_BEGIN_ARG_INFO_EX(arginfo_mb_parse_str, 0, 0, 1) ZEND_ARG_INFO(0, encoded_string) ZEND_ARG_INFO(1, result) ZEND_END_ARG_INFO() From 4ff1539384ce52a3e70f724f52e3c09a715afceb Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 12 Sep 2011 13:21:57 +0000 Subject: [PATCH 0927/2394] Allow replacement to be any scalar value --- ext/spl/spl_iterators.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index 860cccee4d772..21755c7ea44e9 100755 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -1975,7 +1975,7 @@ SPL_METHOD(RegexIterator, accept) spl_dual_it_object *intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC); char *subject, tmp[32], *result; int subject_len, use_copy, count = 0, result_len; - zval subject_copy, zcount, *replacement; + zval subject_copy, zcount, *replacement, tmp_replacement; if (zend_parse_parameters_none() == FAILURE) { return; @@ -2042,6 +2042,12 @@ SPL_METHOD(RegexIterator, accept) case REGIT_MODE_REPLACE: replacement = zend_read_property(intern->std.ce, getThis(), "replacement", sizeof("replacement")-1, 1 TSRMLS_CC); + if (Z_TYPE_P(replacement) != IS_STRING) { + tmp_replacement = *replacement; + zval_copy_ctor(&tmp_replacement); + convert_to_string(&tmp_replacement); + replacement = &tmp_replacement; + } result = php_pcre_replace_impl(intern->u.regex.pce, subject, subject_len, replacement, 0, &result_len, -1, &count TSRMLS_CC); if (intern->u.regex.flags & REGIT_USE_KEY) { @@ -2056,6 +2062,10 @@ SPL_METHOD(RegexIterator, accept) MAKE_STD_ZVAL(intern->current.data); ZVAL_STRINGL(intern->current.data, result, result_len, 0); } + + if (replacement == &tmp_replacement) { + zval_dtor(replacement); + } RETVAL_BOOL(count > 0); } From 002423587485c95f1deff249cac4b3a1b6e9d9a9 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 12 Sep 2011 13:39:57 +0000 Subject: [PATCH 0928/2394] Minor issue. Seems to fail the same way on various PHP + MySQL combinations. Setting XFAIL until we fix it. --- ext/mysqli/tests/mysqli_poll_kill.phpt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ext/mysqli/tests/mysqli_poll_kill.phpt b/ext/mysqli/tests/mysqli_poll_kill.phpt index 800521aa7cdc0..b6d8da89af6c0 100644 --- a/ext/mysqli/tests/mysqli_poll_kill.phpt +++ b/ext/mysqli/tests/mysqli_poll_kill.phpt @@ -136,15 +136,14 @@ if (!$IS_MYSQLND) mysqli_kill(get_connection(), $thread_id); // Sleep 0.1s to ensure the KILL gets recognized usleep(100000); - if (false !== ($tmp = mysqli_query($link, "SELECT 1 AS 'processed beofre killed'", MYSQLI_ASYNC | MYSQLI_USE_RESULT))) + if (false !== ($tmp = mysqli_query($link, "SELECT 1 AS 'processed before killed'", MYSQLI_ASYNC | MYSQLI_USE_RESULT))) printf("[015] Expecting boolean/false got %s/%s\n", gettype($tmp), var_export($tmp, true)); $links = array($link); $errors = array($link); $reject = array($link); - // Yes, that is weird, right? Its the OK package we have to fetch - if (1 !== ($tmp = (mysqli_poll($links, $errors, $reject, 0, 10000)))) + if (0 !== ($tmp = (mysqli_poll($links, $errors, $reject, 0, 10000)))) printf("[016] Expecting int/0 got %s/%s\n", gettype($tmp), var_export($tmp, true)); if (!is_array($links) || empty($links)) @@ -172,6 +171,8 @@ if (!$IS_MYSQLND) mysqli_close($link); print "done!"; ?> +--XFAIL-- +To be fixed later. Minor issue about fetching error message from killed line --EXPECTF-- array(1) { [%u|b%"processed beofre killed"]=> From b5aad069eebf694679ec915edbbfea0730605e6d Mon Sep 17 00:00:00 2001 From: Popa Adrian Marius Date: Mon, 12 Sep 2011 13:46:03 +0000 Subject: [PATCH 0929/2394] fix gcov Warning: ibase_drop_db(): lock time-out on wait transaction object --- ext/pdo_firebird/tests/rowCount.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/pdo_firebird/tests/rowCount.phpt b/ext/pdo_firebird/tests/rowCount.phpt index 02029ceef9058..3d7f71c83b6e6 100644 --- a/ext/pdo_firebird/tests/rowCount.phpt +++ b/ext/pdo_firebird/tests/rowCount.phpt @@ -38,6 +38,7 @@ $dbh->commit(); $dbh->exec('DROP TABLE testz'); +unset($stmt); unset($dbh); ?> From 1c688e06ddf47c8db3bf7bdd0674a9164e3a2a90 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 12 Sep 2011 13:55:28 +0000 Subject: [PATCH 0930/2394] Fix typo. --- ext/mysqli/tests/mysqli_poll_kill.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqli/tests/mysqli_poll_kill.phpt b/ext/mysqli/tests/mysqli_poll_kill.phpt index b6d8da89af6c0..3ee863f433ced 100644 --- a/ext/mysqli/tests/mysqli_poll_kill.phpt +++ b/ext/mysqli/tests/mysqli_poll_kill.phpt @@ -175,7 +175,7 @@ if (!$IS_MYSQLND) To be fixed later. Minor issue about fetching error message from killed line --EXPECTF-- array(1) { - [%u|b%"processed beofre killed"]=> + [%u|b%"processed before killed"]=> %unicode|string%(1) "1" } Fetching from thread %d... From 7b1790bdfbbed54b523dc54cd53417ed2d729536 Mon Sep 17 00:00:00 2001 From: Tjerk Anne Meesters Date: Mon, 12 Sep 2011 14:35:45 +0000 Subject: [PATCH 0931/2394] Reverted changes in connect.inc based on Ulf's feedback - Moved the ini_set() entries into a separate script 'setupdefault.inc' - Let mysql_affected_rows and mysql_insert_id test cases use the newly created script With the ini_set() statements inside connect.inc, some test cases would be forced to 'undo' them in order to test other scenarios. Tested on all three dev lines with and without passing db credentials. No changes detected. --- ext/mysql/tests/connect.inc | 5 ----- ext/mysql/tests/mysql_affected_rows.phpt | 1 + ext/mysql/tests/mysql_insert_id.phpt | 1 + ext/mysql/tests/setupdefault.inc | 10 ++++++++++ 4 files changed, 12 insertions(+), 5 deletions(-) create mode 100644 ext/mysql/tests/setupdefault.inc diff --git a/ext/mysql/tests/connect.inc b/ext/mysql/tests/connect.inc index 5c2f93d8f03f4..0df5bc3aa0c7d 100755 --- a/ext/mysql/tests/connect.inc +++ b/ext/mysql/tests/connect.inc @@ -65,11 +65,6 @@ $port = getenv("MYSQL_TEST_PORT") ? getenv("MYSQL_TEST_PORT") : 3306; $user = getenv("MYSQL_TEST_USER") ? getenv("MYSQL_TEST_USER") : "root"; $passwd = getenv("MYSQL_TEST_PASSWD") ? getenv("MYSQL_TEST_PASSWD") : ""; -// added so that mysql_connect() without args works as well (required in some tests that rely on a default connection being opened implicitly) -ini_set('mysql.default_host', $host); -ini_set('mysql.default_user', $user); -ini_set('mysql.default_password', $passwd); - $db = getenv("MYSQL_TEST_DB") ? getenv("MYSQL_TEST_DB") : "test"; $engine = getenv("MYSQL_TEST_ENGINE") ? getenv("MYSQL_TEST_ENGINE") : "MyISAM"; $socket = getenv("MYSQL_TEST_SOCKET") ? getenv("MYSQL_TEST_SOCKET") : null; diff --git a/ext/mysql/tests/mysql_affected_rows.phpt b/ext/mysql/tests/mysql_affected_rows.phpt index 42632bf8d7f65..145e1f5c0b95a 100644 --- a/ext/mysql/tests/mysql_affected_rows.phpt +++ b/ext/mysql/tests/mysql_affected_rows.phpt @@ -8,6 +8,7 @@ require_once('skipifconnectfailure.inc'); --FILE-- From 0290718b001ddaa2a19cbfb1bc33f86696ed1501 Mon Sep 17 00:00:00 2001 From: Ulf Wendel Date: Mon, 12 Sep 2011 15:05:10 +0000 Subject: [PATCH 0932/2394] This should please gcov.php.net which hits error 1044 instead of 1049. --- ext/mysqli/tests/mysqli_select_db.phpt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/tests/mysqli_select_db.phpt b/ext/mysqli/tests/mysqli_select_db.phpt index ee04eacb6a447..f58a19bea34ca 100644 --- a/ext/mysqli/tests/mysqli_select_db.phpt +++ b/ext/mysqli/tests/mysqli_select_db.phpt @@ -70,7 +70,17 @@ require_once('skipifconnectfailure.inc'); mysqli_report(MYSQLI_REPORT_OFF); mysqli_select_db($link, 'I can not imagine that this database exists'); mysqli_report(MYSQLI_REPORT_ERROR); + + ob_start(); mysqli_select_db($link, 'I can not imagine that this database exists'); + $output = ob_get_contents(); + ob_end_clean(); + if (!stristr($output, "1049") && !stristr($output, "1044") && !stristr($output, "1045")) { + /* Error: 1049 SQLSTATE: 42000 (ER_BAD_DB_ERROR) Message: Unknown database '%s' */ + /* Error: 1044 SQLSTATE: 42000 (ER_DBACCESS_DENIED_ERROR) Message: Access denied for user '%s'@'%s' to database '%s' */ + /* Error: 1045 SQLSTATE: 28000 (ER_ACCESS_DENIED_ERROR) Message: Access denied for user '%s'@'%s' (using password: %s) */ + echo $output; + } if (!$res = mysqli_query($link, "SELECT DATABASE() AS dbname")) printf("[015] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); @@ -98,7 +108,5 @@ require_once('skipifconnectfailure.inc'); --CLEAN-- --EXPECTF-- -Warning: mysqli_select_db(): (%s/%d): Unknown database '%s' in %s on line %d - Warning: mysqli_select_db(): Couldn't fetch mysqli in %s on line %d done! \ No newline at end of file From 1e4dac2d585e249b299746a2ab1133f00c595ac8 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 12 Sep 2011 15:49:12 +0000 Subject: [PATCH 0933/2394] - Updated to version 2011.10 (2011j) --- ext/date/lib/timezonedb.h | 165 +++++++++++++++++++------------------- 1 file changed, 83 insertions(+), 82 deletions(-) diff --git a/ext/date/lib/timezonedb.h b/ext/date/lib/timezonedb.h index 89dd1a12aab9f..dfdb1ebbed505 100644 --- a/ext/date/lib/timezonedb.h +++ b/ext/date/lib/timezonedb.h @@ -505,77 +505,77 @@ const timelib_tzdb_index_entry timezonedb_idx_builtin[574] = { { "NZ" , 0x038DDA }, { "NZ-CHAT" , 0x039158 }, { "Pacific/Apia" , 0x039440 }, - { "Pacific/Auckland" , 0x0394CB }, - { "Pacific/Chatham" , 0x039857 }, - { "Pacific/Chuuk" , 0x039B4E }, - { "Pacific/Easter" , 0x039BA7 }, - { "Pacific/Efate" , 0x039F05 }, - { "Pacific/Enderbury" , 0x039FCB }, - { "Pacific/Fakaofo" , 0x03A039 }, - { "Pacific/Fiji" , 0x03A07D }, - { "Pacific/Funafuti" , 0x03A107 }, - { "Pacific/Galapagos" , 0x03A14B }, - { "Pacific/Gambier" , 0x03A1C3 }, - { "Pacific/Guadalcanal" , 0x03A228 }, - { "Pacific/Guam" , 0x03A27D }, - { "Pacific/Honolulu" , 0x03A2D3 }, - { "Pacific/Johnston" , 0x03A34A }, - { "Pacific/Kiritimati" , 0x03A39C }, - { "Pacific/Kosrae" , 0x03A407 }, - { "Pacific/Kwajalein" , 0x03A464 }, - { "Pacific/Majuro" , 0x03A4D0 }, - { "Pacific/Marquesas" , 0x03A52F }, - { "Pacific/Midway" , 0x03A596 }, - { "Pacific/Nauru" , 0x03A620 }, - { "Pacific/Niue" , 0x03A698 }, - { "Pacific/Norfolk" , 0x03A6F6 }, - { "Pacific/Noumea" , 0x03A74B }, - { "Pacific/Pago_Pago" , 0x03A7DB }, - { "Pacific/Palau" , 0x03A864 }, - { "Pacific/Pitcairn" , 0x03A8A8 }, - { "Pacific/Pohnpei" , 0x03A8FD }, - { "Pacific/Ponape" , 0x03A952 }, - { "Pacific/Port_Moresby" , 0x03A997 }, - { "Pacific/Rarotonga" , 0x03A9DB }, - { "Pacific/Saipan" , 0x03AAB7 }, - { "Pacific/Samoa" , 0x03AB1A }, - { "Pacific/Tahiti" , 0x03ABA3 }, - { "Pacific/Tarawa" , 0x03AC08 }, - { "Pacific/Tongatapu" , 0x03AC5C }, - { "Pacific/Truk" , 0x03ACE8 }, - { "Pacific/Wake" , 0x03AD2D }, - { "Pacific/Wallis" , 0x03AD7D }, - { "Pacific/Yap" , 0x03ADC1 }, - { "Poland" , 0x03AE06 }, - { "Portugal" , 0x03B1E7 }, - { "PRC" , 0x03B6E3 }, - { "PST8PDT" , 0x03B794 }, - { "ROC" , 0x03BAE5 }, - { "ROK" , 0x03BBFD }, - { "Singapore" , 0x03BCA1 }, - { "Turkey" , 0x03BD58 }, - { "UCT" , 0x03C145 }, - { "Universal" , 0x03C189 }, - { "US/Alaska" , 0x03C1CD }, - { "US/Aleutian" , 0x03C536 }, - { "US/Arizona" , 0x03C89C }, - { "US/Central" , 0x03C92A }, - { "US/East-Indiana" , 0x03D334 }, - { "US/Eastern" , 0x03CE35 }, - { "US/Hawaii" , 0x03D59E }, - { "US/Indiana-Starke" , 0x03D60F }, - { "US/Michigan" , 0x03D980 }, - { "US/Mountain" , 0x03DCB7 }, - { "US/Pacific" , 0x03E030 }, - { "US/Pacific-New" , 0x03E435 }, - { "US/Samoa" , 0x03E83A }, - { "UTC" , 0x03E8C3 }, - { "W-SU" , 0x03EBBA }, - { "WET" , 0x03E907 }, - { "Zulu" , 0x03EDF4 }, + { "Pacific/Auckland" , 0x0394DD }, + { "Pacific/Chatham" , 0x039869 }, + { "Pacific/Chuuk" , 0x039B60 }, + { "Pacific/Easter" , 0x039BB9 }, + { "Pacific/Efate" , 0x039F17 }, + { "Pacific/Enderbury" , 0x039FDD }, + { "Pacific/Fakaofo" , 0x03A04B }, + { "Pacific/Fiji" , 0x03A08F }, + { "Pacific/Funafuti" , 0x03A119 }, + { "Pacific/Galapagos" , 0x03A15D }, + { "Pacific/Gambier" , 0x03A1D5 }, + { "Pacific/Guadalcanal" , 0x03A23A }, + { "Pacific/Guam" , 0x03A28F }, + { "Pacific/Honolulu" , 0x03A2E5 }, + { "Pacific/Johnston" , 0x03A35C }, + { "Pacific/Kiritimati" , 0x03A3AE }, + { "Pacific/Kosrae" , 0x03A419 }, + { "Pacific/Kwajalein" , 0x03A476 }, + { "Pacific/Majuro" , 0x03A4E2 }, + { "Pacific/Marquesas" , 0x03A541 }, + { "Pacific/Midway" , 0x03A5A8 }, + { "Pacific/Nauru" , 0x03A632 }, + { "Pacific/Niue" , 0x03A6AA }, + { "Pacific/Norfolk" , 0x03A708 }, + { "Pacific/Noumea" , 0x03A75D }, + { "Pacific/Pago_Pago" , 0x03A7ED }, + { "Pacific/Palau" , 0x03A876 }, + { "Pacific/Pitcairn" , 0x03A8BA }, + { "Pacific/Pohnpei" , 0x03A90F }, + { "Pacific/Ponape" , 0x03A964 }, + { "Pacific/Port_Moresby" , 0x03A9A9 }, + { "Pacific/Rarotonga" , 0x03A9ED }, + { "Pacific/Saipan" , 0x03AAC9 }, + { "Pacific/Samoa" , 0x03AB2C }, + { "Pacific/Tahiti" , 0x03ABB5 }, + { "Pacific/Tarawa" , 0x03AC1A }, + { "Pacific/Tongatapu" , 0x03AC6E }, + { "Pacific/Truk" , 0x03ACFA }, + { "Pacific/Wake" , 0x03AD3F }, + { "Pacific/Wallis" , 0x03AD8F }, + { "Pacific/Yap" , 0x03ADD3 }, + { "Poland" , 0x03AE18 }, + { "Portugal" , 0x03B1F9 }, + { "PRC" , 0x03B6F5 }, + { "PST8PDT" , 0x03B7A6 }, + { "ROC" , 0x03BAF7 }, + { "ROK" , 0x03BC0F }, + { "Singapore" , 0x03BCB3 }, + { "Turkey" , 0x03BD6A }, + { "UCT" , 0x03C157 }, + { "Universal" , 0x03C19B }, + { "US/Alaska" , 0x03C1DF }, + { "US/Aleutian" , 0x03C548 }, + { "US/Arizona" , 0x03C8AE }, + { "US/Central" , 0x03C93C }, + { "US/East-Indiana" , 0x03D346 }, + { "US/Eastern" , 0x03CE47 }, + { "US/Hawaii" , 0x03D5B0 }, + { "US/Indiana-Starke" , 0x03D621 }, + { "US/Michigan" , 0x03D992 }, + { "US/Mountain" , 0x03DCC9 }, + { "US/Pacific" , 0x03E042 }, + { "US/Pacific-New" , 0x03E447 }, + { "US/Samoa" , 0x03E84C }, + { "UTC" , 0x03E8D5 }, + { "W-SU" , 0x03EBCC }, + { "WET" , 0x03E919 }, + { "Zulu" , 0x03EE06 }, }; /* This is a generated file, do not modify */ -const unsigned char timelib_timezone_db_data_builtin[257592] = { +const unsigned char timelib_timezone_db_data_builtin[257610] = { /* Africa/Abidjan */ @@ -841,8 +841,8 @@ const unsigned char timelib_timezone_db_data_builtin[257592] = { 0x50, 0x48, 0x50, 0x31, 0x01, 0x54, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0E, 0xB6, 0xA3, 0xD3, 0xAC, -0xD6, 0x9D, 0x7F, 0xD0, 0xEF, 0x12, 0x66, 0xE3, 0x01, 0x02, 0x01, 0x00, 0x00, 0x24, 0xD4, 0x00, -0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x26, 0x9D, 0x00, 0x08, 0x4C, 0x4D, 0x54, +0xD6, 0x9D, 0x7F, 0xD0, 0xEF, 0x12, 0x66, 0xD4, 0x01, 0x02, 0x01, 0x00, 0x00, 0x24, 0xD4, 0x00, +0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x26, 0xAC, 0x00, 0x08, 0x4C, 0x4D, 0x54, 0x00, 0x45, 0x41, 0x54, 0x00, 0x42, 0x45, 0x41, 0x55, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0xF4, 0x00, 0x01, 0x4E, 0x99, 0x8D, 0x00, 0x00, 0x00, 0x00, @@ -939,9 +939,9 @@ const unsigned char timelib_timezone_db_data_builtin[257592] = { 0x50, 0x48, 0x50, 0x31, 0x01, 0x55, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x13, 0xB1, 0xEE, 0xDF, 0x1C, -0xB4, 0xC2, 0x9A, 0xD0, 0xD6, 0x9D, 0x86, 0xD8, 0xE7, 0x8C, 0x47, 0x63, 0x01, 0x02, 0x03, 0x01, +0xB4, 0xC2, 0x9A, 0xD0, 0xD6, 0x9D, 0x86, 0xD8, 0xE7, 0x8C, 0x47, 0x54, 0x01, 0x02, 0x03, 0x01, 0x00, 0x00, 0x1E, 0x64, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x23, 0x28, -0x00, 0x08, 0x00, 0x00, 0x26, 0x9D, 0x00, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x45, 0x41, 0x54, 0x00, +0x00, 0x08, 0x00, 0x00, 0x26, 0xAC, 0x00, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x45, 0x41, 0x54, 0x00, 0x42, 0x45, 0x41, 0x54, 0x00, 0x42, 0x45, 0x41, 0x55, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0xCF, 0xF2, 0x01, 0x44, 0x1F, 0x42, 0x00, 0x00, 0x00, 0x00, @@ -1083,9 +1083,9 @@ const unsigned char timelib_timezone_db_data_builtin[257592] = { 0x50, 0x48, 0x50, 0x31, 0x01, 0x4B, 0x45, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x13, 0xB1, 0xEE, 0xDA, 0xFC, -0xB4, 0xC2, 0x9A, 0xD0, 0xC7, 0x91, 0x47, 0xD8, 0xED, 0x2F, 0xE1, 0xE3, 0x01, 0x02, 0x03, 0x01, +0xB4, 0xC2, 0x9A, 0xD0, 0xC7, 0x91, 0x47, 0xD8, 0xED, 0x2F, 0xE1, 0xD4, 0x01, 0x02, 0x03, 0x01, 0x00, 0x00, 0x22, 0x84, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x00, 0x04, 0x00, 0x00, 0x23, 0x28, -0x00, 0x08, 0x00, 0x00, 0x26, 0x9D, 0x00, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x45, 0x41, 0x54, 0x00, +0x00, 0x08, 0x00, 0x00, 0x26, 0xAC, 0x00, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x45, 0x41, 0x54, 0x00, 0x42, 0x45, 0x41, 0x54, 0x00, 0x42, 0x45, 0x41, 0x55, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x87, 0x5E, 0xF2, 0x01, 0x4A, 0xD6, 0x02, 0x00, 0x00, 0x00, 0x00, @@ -16531,14 +16531,15 @@ const unsigned char timelib_timezone_db_data_builtin[257592] = { /* Pacific/Apia */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x57, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, -0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x12, 0x91, 0x05, 0xFC, 0x00, -0xDA, 0x62, 0x04, 0x38, 0x4C, 0x9F, 0x27, 0xB0, 0x4D, 0x97, 0x2B, 0xE0, 0x4E, 0xFD, 0x99, 0xB0, -0x01, 0x02, 0x03, 0x02, 0x04, 0xFF, 0xFF, 0x5F, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x5E, 0x48, 0x00, -0x04, 0xFF, 0xFF, 0x65, 0x50, 0x00, 0x09, 0xFF, 0xFF, 0x73, 0x60, 0x01, 0x0D, 0x00, 0x00, 0xB6, +0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0x91, 0x05, 0xFC, 0x00, +0xDA, 0x62, 0x04, 0x38, 0x4C, 0x9F, 0x27, 0xB0, 0x4D, 0x97, 0x2B, 0xE0, 0x4E, 0x7D, 0xE2, 0x60, +0x4E, 0xFD, 0x8B, 0xA0, 0x4F, 0x77, 0x0D, 0xE0, 0x01, 0x02, 0x03, 0x02, 0x03, 0x04, 0x05, 0xFF, +0xFF, 0x5F, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x5E, 0x48, 0x00, 0x04, 0xFF, 0xFF, 0x65, 0x50, 0x00, +0x09, 0xFF, 0xFF, 0x73, 0x60, 0x01, 0x0D, 0x00, 0x00, 0xC4, 0xE0, 0x01, 0x0D, 0x00, 0x00, 0xB6, 0xD0, 0x00, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x53, 0x41, 0x4D, 0x54, 0x00, 0x57, 0x53, 0x54, 0x00, 0x57, 0x53, 0x44, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, -0x74, 0x38, 0x9A, 0x00, 0x0C, 0x9D, 0x2A, 0x00, 0x00, 0x00, 0x00, +0x00, 0x00, 0x74, 0x38, 0x9A, 0x00, 0x0C, 0x9D, 0x2A, 0x00, 0x00, 0x00, 0x00, /* Pacific/Auckland */ 0x50, 0x48, 0x50, 0x31, 0x01, 0x4E, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -18145,4 +18146,4 @@ const unsigned char timelib_timezone_db_data_builtin[257592] = { 0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, }; -const timelib_tzdb timezonedb_builtin = { "2011.9", 574, timezonedb_idx_builtin, timelib_timezone_db_data_builtin }; +const timelib_tzdb timezonedb_builtin = { "2011.10", 574, timezonedb_idx_builtin, timelib_timezone_db_data_builtin }; From 3d3a6a3b965fa059f30d52f8de6f4251af887f6a Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Mon, 12 Sep 2011 17:20:24 +0000 Subject: [PATCH 0934/2394] Fixed bug #55273 (base64_decode() with strict rejects whitespace after pad) --- ext/standard/base64.c | 8 ++++++++ ext/standard/tests/url/bug55273.phpt | 25 +++++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 ext/standard/tests/url/bug55273.phpt diff --git a/ext/standard/base64.c b/ext/standard/base64.c index 0f261468f4224..34fb4dd8a27c9 100644 --- a/ext/standard/base64.c +++ b/ext/standard/base64.c @@ -153,6 +153,14 @@ PHPAPI unsigned char *php_base64_decode_ex(const unsigned char *str, int length, while ((ch = *current++) != '\0' && length-- > 0) { if (ch == base64_pad) { if (*current != '=' && ((i % 4) == 1 || (strict && length > 0))) { + if ((i % 4) != 1) { + while (isspace(*(++current))) { + continue; + } + if (*current == '\0') { + continue; + } + } efree(result); return NULL; } diff --git a/ext/standard/tests/url/bug55273.phpt b/ext/standard/tests/url/bug55273.phpt new file mode 100644 index 0000000000000..1408506b42703 --- /dev/null +++ b/ext/standard/tests/url/bug55273.phpt @@ -0,0 +1,25 @@ +--TEST-- +Bug #55273 (base64_decode() with strict rejects whitespace after pad) +--FILE-- + +--EXPECT-- +string(6) "UEhQ +" +string(3) "PHP" +string(6) "UEg= +" +string(2) "PH" +string(6) "UA== +" +string(1) "P" From 4653534643e7762d25744c7c642727fdb4b799e6 Mon Sep 17 00:00:00 2001 From: Hannes Magnusson Date: Mon, 12 Sep 2011 17:20:44 +0000 Subject: [PATCH 0935/2394] Test for non-string replacement, bug#54304 --- ext/spl/tests/bug54304.phpt | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 ext/spl/tests/bug54304.phpt diff --git a/ext/spl/tests/bug54304.phpt b/ext/spl/tests/bug54304.phpt new file mode 100644 index 0000000000000..32cbe486a0511 --- /dev/null +++ b/ext/spl/tests/bug54304.phpt @@ -0,0 +1,26 @@ +--TEST-- +Bug #54304 (Setting replacement value for RegexIterator doesn't work) +--FILE-- +'test999')); + } +} + +$h = new foo; +$i = new RegexIterator($h, '/^test(.*)/', RegexIterator::REPLACE); +$i->replacement = 42; +var_dump($i->replacement); +foreach ($i as $name=>$value) { + var_dump($name, $value); +} +var_dump($i->replacement); +?> +--EXPECT-- +int(42) +string(5) "test3" +string(2) "42" +int(42) + From 1fbf9119050aee0867d0b276c3ed634e26c43b66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Mon, 12 Sep 2011 17:23:10 +0000 Subject: [PATCH 0936/2394] - Fixed bug #55646: textual data is returned in UTF-8, but is input in another encoding. 5.4 only as this implies a BC break. --- ext/openssl/openssl.c | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 89574eab3fd43..a6ec656540b84 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -2092,10 +2092,14 @@ static int php_openssl_make_REQ(struct php_x509_request * req, X509_REQ * csr, z nid = OBJ_txt2nid(strindex); if (nid != NID_undef) { - if (!X509_NAME_add_entry_by_NID(subj, nid, MBSTRING_ASC, + if (!X509_NAME_add_entry_by_NID(subj, nid, MBSTRING_UTF8, (unsigned char*)Z_STRVAL_PP(item), -1, -1, 0)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "dn: add_entry_by_NID %d -> %s (failed)", nid, Z_STRVAL_PP(item)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "dn: add_entry_by_NID %d -> %s (failed; check error" + " queue and value of string_mask OpenSSL option " + "if illegal characters are reported)", + nid, Z_STRVAL_PP(item)); return FAILURE; } } else { @@ -2144,7 +2148,7 @@ static int php_openssl_make_REQ(struct php_x509_request * req, X509_REQ * csr, z if (X509_NAME_get_index_by_NID(subj, nid, -1) >= 0) { continue; } - if (!X509_NAME_add_entry_by_txt(subj, type, MBSTRING_ASC, (unsigned char*)v->value, -1, -1, 0)) { + if (!X509_NAME_add_entry_by_txt(subj, type, MBSTRING_UTF8, (unsigned char*)v->value, -1, -1, 0)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "add_entry_by_txt %s -> %s (failed)", type, v->value); return FAILURE; } @@ -2168,7 +2172,7 @@ static int php_openssl_make_REQ(struct php_x509_request * req, X509_REQ * csr, z nid = OBJ_txt2nid(strindex); if (nid != NID_undef) { - if (!X509_NAME_add_entry_by_NID(subj, nid, MBSTRING_ASC, (unsigned char*)Z_STRVAL_PP(item), -1, -1, 0)) { + if (!X509_NAME_add_entry_by_NID(subj, nid, MBSTRING_UTF8, (unsigned char*)Z_STRVAL_PP(item), -1, -1, 0)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "attribs: add_entry_by_NID %d -> %s (failed)", nid, Z_STRVAL_PP(item)); return FAILURE; } @@ -2185,8 +2189,12 @@ static int php_openssl_make_REQ(struct php_x509_request * req, X509_REQ * csr, z if (X509_REQ_get_attr_by_NID(csr, nid, -1) >= 0) { continue; } - if (!X509_REQ_add1_attr_by_txt(csr, v->name, MBSTRING_ASC, (unsigned char*)v->value, -1)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "add1_attr_by_txt %s -> %s (failed)", v->name, v->value); + if (!X509_REQ_add1_attr_by_txt(csr, v->name, MBSTRING_UTF8, (unsigned char*)v->value, -1)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "add1_attr_by_txt %s -> %s (failed; check error queue " + "and value of string_mask OpenSSL option if illegal " + "characters are reported)", + v->name, v->value); return FAILURE; } } From ba04ba9c8293c740ea3f536e80dc37b7118e181b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 12 Sep 2011 17:50:42 +0000 Subject: [PATCH 0937/2394] MFB crypt fix --- ext/standard/crypt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index 3bac50f9e4712..700811b9e6596 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -179,6 +179,8 @@ PHP_FUNCTION(crypt) salt[2] = '\0'; #endif salt_in_len = strlen(salt); + } else { + salt_in_len = MIN(PHP_MAX_SALT_LEN, salt_in_len); } /* Windows (win32/crypt) has a stripped down version of libxcrypt and From d7c7fe3587b95b65317d5ccf5a2837ebda0030b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Mon, 12 Sep 2011 20:05:07 +0000 Subject: [PATCH 0938/2394] - Test for bug #55646. --- ext/openssl/tests/bug55646.phpt | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 ext/openssl/tests/bug55646.phpt diff --git a/ext/openssl/tests/bug55646.phpt b/ext/openssl/tests/bug55646.phpt new file mode 100644 index 0000000000000..b7118fc04d27e --- /dev/null +++ b/ext/openssl/tests/bug55646.phpt @@ -0,0 +1,32 @@ +--TEST-- +Bug #55646: textual input in openssl_csr_new() is not expected in UTF-8 +--SKIPIF-- + "sha1","x509_extensions" => "v3_ca","req_extensions" => "v3_req","private_key_bits" => 2048,"private_key_type" => OPENSSL_KEYTYPE_RSA,"encrypt_key" => false,); +$csr_info = array( + "countryName" => "US", + "stateOrProvinceName" => "Utah", + "localityName" => "Lindon", + "organizationName" => "Chinese", + "organizationalUnitName" => "IT \xe4\xba\x92", + "commonName" => "www.example.com",); +$private = openssl_pkey_new($config); +$csr_res = openssl_csr_new($csr_info, $private); +openssl_csr_export($csr_res, $csr); +$output = openssl_csr_get_subject($csr); + +echo "A: ".$csr_info["organizationalUnitName"]."\n"; +echo "B: ".stringAsHex($csr_info["organizationalUnitName"])."\n"; +echo "C: ".$output['OU']."\n"; +echo "D: ".stringAsHex($output['OU'])."\n"; +--EXPECT-- +A: IT 互 +B: 49 54 20 e4 ba 92 +C: IT 互 +D: 49 54 20 e4 ba 92 From 4262382199df2731511840b06ec20887134a82cf Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 12 Sep 2011 23:31:22 +0000 Subject: [PATCH 0939/2394] - skip on win, strftime uses system TZ --- ext/date/tests/bug32555.phpt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/date/tests/bug32555.phpt b/ext/date/tests/bug32555.phpt index a99d3e289072f..31fafbfd48777 100644 --- a/ext/date/tests/bug32555.phpt +++ b/ext/date/tests/bug32555.phpt @@ -1,5 +1,9 @@ --TEST-- Bug #32555 (strtotime("tomorrow") can return false) +--SKIPIF-- + --INI-- date.timezone=US/Eastern --FILE-- From b6173bee922363affe761bfaa1f7e7c678e8dd96 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 13 Sep 2011 07:01:46 +0000 Subject: [PATCH 0940/2394] Fixed bug #55509 (segfault on x86_64 using more than 2G memory). (Laruence) --- Zend/tests/bug55509.phpt | 33 +++++++++++++++++++++++++++++++++ Zend/zend_alloc.c | 2 +- 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 Zend/tests/bug55509.phpt diff --git a/Zend/tests/bug55509.phpt b/Zend/tests/bug55509.phpt new file mode 100644 index 0000000000000..86e5a087645b1 --- /dev/null +++ b/Zend/tests/bug55509.phpt @@ -0,0 +1,33 @@ +--TEST-- +Bug #55509 (segfault on x86_64 using more than 2G memory) +--SKIPIF-- + +--INI-- +memory_limit=3G +--FILE-- + +--EXPECTF-- +1 +2 +3 +4 +5 + +Fatal error: Allowed memory size of %d bytes exhausted (tried to allocate %d bytes) in %s/bug55509.php on line %d diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 2d8d26a99fbc4..3c3b579e7bf0f 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -515,7 +515,7 @@ static unsigned int _zend_mm_cookie = 0; #define ZEND_MM_IS_GUARD_BLOCK(b) (((b)->info._size & ZEND_MM_TYPE_MASK) == ZEND_MM_GUARD_BLOCK) #define ZEND_MM_NEXT_BLOCK(b) ZEND_MM_BLOCK_AT(b, ZEND_MM_BLOCK_SIZE(b)) -#define ZEND_MM_PREV_BLOCK(b) ZEND_MM_BLOCK_AT(b, -(int)((b)->info._prev & ~ZEND_MM_TYPE_MASK)) +#define ZEND_MM_PREV_BLOCK(b) ZEND_MM_BLOCK_AT(b, -(ssize_t)((b)->info._prev & ~ZEND_MM_TYPE_MASK)) #define ZEND_MM_PREV_BLOCK_IS_FREE(b) (!((b)->info._prev & ZEND_MM_USED_BLOCK)) From 4b1193a9cc705d5b989f308953ec796d67bb0f23 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 13 Sep 2011 07:07:06 +0000 Subject: [PATCH 0941/2394] Fixed Bug #55649 (Undefined function Bug()). (Laruence) --- Zend/zend_strtod.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Zend/zend_strtod.c b/Zend/zend_strtod.c index c43587eef30bb..d6e5ccf9604a7 100644 --- a/Zend/zend_strtod.c +++ b/Zend/zend_strtod.c @@ -445,6 +445,12 @@ static MUTEX_T pow5mult_mutex; #endif /* ZTS */ +#ifdef DEBUG +static void Bug(const char *message) { + fprintf(stderr, "%s\n", message); +} +#endif + ZEND_API int zend_startup_strtod(void) /* {{{ */ { #ifdef ZTS From 5a49af4253dadbb223b4cf36ae7c29c239db058d Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 13 Sep 2011 10:38:12 +0000 Subject: [PATCH 0942/2394] - do not display the crt warnings anymore by default. It is enough to simply fail from a user land pov as it is the case on posix platforms --- main/main.c | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/main/main.c b/main/main.c index 9caf5bc02afce..4a70b2b691fcb 100644 --- a/main/main.c +++ b/main/main.c @@ -502,6 +502,9 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("user_ini.filename", ".user.ini", PHP_INI_SYSTEM, OnUpdateString, user_ini_filename, php_core_globals, core_globals) STD_PHP_INI_ENTRY("user_ini.cache_ttl", "300", PHP_INI_SYSTEM, OnUpdateLong, user_ini_cache_ttl, php_core_globals, core_globals) STD_PHP_INI_BOOLEAN("exit_on_timeout", "0", PHP_INI_ALL, OnUpdateBool, exit_on_timeout, php_core_globals, core_globals) +#ifdef PHP_WIN32 + STD_PHP_INI_BOOLEAN("windows_show_crt_warning", "0", PHP_INI_ALL, OnUpdateBool, windows_show_crt_warning, php_core_globals, core_globals) +#endif PHP_INI_END() /* }}} */ @@ -1839,18 +1842,21 @@ void dummy_invalid_parameter_handler( int len; if (!called) { - called = 1; - if (function) { - if (file) { - len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws' (%ws:%d)", function, file, line); + TSRMLS_FETCH(); + if(PG(windows_show_crt_warning)) { + called = 1; + if (function) { + if (file) { + len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws' (%ws:%d)", function, file, line); + } else { + len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws'", function); + } } else { - len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws'", function); + len = _snprintf(buf, sizeof(buf)-1, "Invalid CRT parameter detected (function not known)"); } - } else { - len = _snprintf(buf, sizeof(buf)-1, "Invalid CRT parameters detected"); + zend_error(E_WARNING, "%s", buf); + called = 0; } - zend_error(E_WARNING, "%s", buf); - called = 0; } } #endif @@ -1869,9 +1875,6 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod void ***tsrm_ls; php_core_globals *core_globals; #endif -#ifdef PHP_WIN32 - char module_path[MAX_PATH]; -#endif #if defined(PHP_WIN32) || (defined(NETWARE) && defined(USE_WINSOCK)) WORD wVersionRequested = MAKEWORD(2, 0); From 3996135f685ed360891a56b165ba0e2fd3820eb6 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 13 Sep 2011 12:04:57 +0000 Subject: [PATCH 0943/2394] - fix test on win, putenv is not supported for TZ and ext/date --- ext/date/tests/bug33415-2.phpt | 144 +++++++++++++++++++++++++++------ 1 file changed, 120 insertions(+), 24 deletions(-) diff --git a/ext/date/tests/bug33415-2.phpt b/ext/date/tests/bug33415-2.phpt index 9ea537a9f8563..50fface88b268 100644 --- a/ext/date/tests/bug33415-2.phpt +++ b/ext/date/tests/bug33415-2.phpt @@ -5,7 +5,11 @@ Bug #33415 [2] (Possibly invalid non-one-hour DST or timezone shifts) print "TZ=Africa/Bujumbura - *Note*: Unexpected, as does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Africa/Bujumbura"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Africa/Bujumbura'); +} else { + putenv("TZ=Africa/Bujumbura"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Wednesday", $tStamp); @@ -13,7 +17,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Wednesday 00:00:00\n\n"; print "TZ=Asia/Thimbu - Is it OK for this to be 0:30 AM? yes\n"; -putenv("TZ=Asia/Thimbu"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Asia/Thimbu'); +} else { + putenv("TZ=Asia/Thimbu"); +} $tStamp = mktime (17, 17, 17, 1, 6476, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Thursday", $tStamp); @@ -22,7 +30,11 @@ print "wanted=Thursday 00:30:00\n\n"; print "TZ=Indian/Cocos - Is it OK for this to be 6:30 AM? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Indian/Cocos"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Indian/Cocos'); +} else { + putenv("TZ=Indian/Cocos"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Thursday", $tStamp); @@ -31,7 +43,11 @@ print "wanted=Thursday 00:00:00\n\n"; print "TZ=Africa/Lubumbashi - Is it OK for this to be 2 AM? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Africa/Lubumbashi"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Africa/Lubumbashi'); +} else { + putenv("TZ=Africa/Lubumbashi"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Saturday", $tStamp); @@ -39,7 +55,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Saturday 00:00:00\n\n"; print "TZ=Asia/Kashgar - Is it OK for this to be 3 AM? yes\n"; -putenv("TZ=Asia/Kashgar"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Asia/Kashgar'); +} else { + putenv("TZ=Asia/Kashgar"); +} $tStamp = mktime (17, 17, 17, 1, 3767, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Thursday", $tStamp); @@ -48,7 +68,11 @@ print "wanted=Thursday 03:00:00\n\n"; print "TZ=Indian/Christmas - Is it OK for this to be 7 AM? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Indian/Christmas"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Indian/Christmas'); +} else { + putenv("TZ=Indian/Christmas"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Sunday", $tStamp); @@ -56,7 +80,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Sunday 00:00:00\n\n"; print "TZ=America/Santo_Domingo - Is it OK for this to be 0:30 AM? yes\n"; -putenv("TZ=America/Santo_Domingo"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('America/Santo_Domingo'); +} else { + putenv("TZ=America/Santo_Domingo"); +} $tStamp = mktime (17, 17, 17, 1, 291, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Sunday", $tStamp); @@ -65,7 +93,11 @@ print "wanted=Sunday 00:30:00\n\n"; print "TZ=Pacific/Truk - Is it OK for this to be 10 AM? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Pacific/Truk"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Truk'); +} else { + putenv("TZ=Pacific/Truk"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Tuesday", $tStamp); @@ -74,7 +106,11 @@ print "wanted=Tuesday 00:00:00\n\n"; print "TZ=Pacific/Ponape - Is it OK for this to be 11 AM? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Pacific/Ponape"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Ponape'); +} else { + putenv("TZ=Pacific/Ponape"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Monday", $tStamp); @@ -82,7 +118,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Monday 00:00:00\n\n"; print "TZ=America/Scoresbysund - Is it OK for this to be 2 AM? yes\n"; -putenv("TZ=America/Scoresbysund"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('America/Scoresbysund'); +} else { + putenv("TZ=America/Scoresbysund"); +} $tStamp = mktime (17, 17, 17, 1, 4099, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Sunday", $tStamp); @@ -90,7 +130,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Sunday 02:00:00\n\n"; print "TZ=America/Guyana - Is it OK for this to be 0:45 AM? yes\n"; -putenv("TZ=America/Guyana"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('America/Guyana'); +} else { + putenv("TZ=America/Guyana"); +} $tStamp = mktime (17, 17, 17, 1, 2031, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Thursday", $tStamp); @@ -98,7 +142,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Thursday 00:45:00\n\n"; print "TZ=Asia/Tehran - Is it OK for this to be 0:30 AM? yes\n"; -putenv("TZ=Asia/Tehran"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Asia/Tehran'); +} else { + putenv("TZ=Asia/Tehran"); +} $tStamp = mktime (17, 17, 17, 1, 2855, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Tuesday", $tStamp); @@ -107,7 +155,11 @@ print "wanted=Tuesday 00:30:00\n\n"; print "TZ=Pacific/Tarawa - Is it OK for this to be Midday? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Pacific/Tarawa"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Tarawa'); +} else { + putenv("TZ=Pacific/Tarawa"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Monday", $tStamp); @@ -115,7 +167,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Monday 00:00:00\n\n"; print "TZ=Africa/Monrovia - Is it OK for this to be 00:44:30 AM? yes\n"; -putenv("TZ=Africa/Monrovia"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Africa/Monrovia'); +} else { + putenv("TZ=Africa/Monrovia"); +} $tStamp = mktime (17, 17, 17, 1, 845, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Monday", $tStamp); @@ -123,7 +179,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Monday 00:44:30\n\n"; print "TZ=Asia/Katmandu - Is it OK for this to 0:15 AM?. yes\n"; -putenv("TZ=Asia/Katmandu"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Asia/Katmandu'); +} else { + putenv("TZ=Asia/Katmandu"); +} $tStamp = mktime (17, 17, 17, 1, 5838, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Wednesday", $tStamp); @@ -131,7 +191,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Wednesday 00:15:00\n\n"; print "TZ=Pacific/Nauru - Is it OK for this to be 0:30? yes\n"; -putenv("TZ=Pacific/Nauru"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Nauru'); +} else { + putenv("TZ=Pacific/Nauru"); +} $tStamp = mktime (17, 17, 17, 1, 3401, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Tuesday", $tStamp); @@ -139,7 +203,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Tuesday 00:30:00\n\n"; print "TZ=Pacific/Niue - Is it OK for this to be 0:30 AM? yes\n"; -putenv("TZ=Pacific/Niue"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Niue'); +} else { + putenv("TZ=Pacific/Niue"); +} $tStamp = mktime (17, 17, 17, 1, 3189, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Sunday", $tStamp); @@ -148,7 +216,11 @@ print "wanted=Sunday 00:30:00\n\n"; print "TZ=Pacific/Port_Moresby - Is it OK for this to be 10 AM? No DST or timezone transition.\n"; -putenv("TZ=Pacific/Port_Moresby"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Port_Moresby'); +} else { + putenv("TZ=Pacific/Port_Moresby"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Thursday", $tStamp); @@ -156,7 +228,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Thursday 00:00:00\n\n"; print "TZ=America/Miquelon - Is it OK for this to be 1 AM ? yes\n"; -putenv("TZ=America/Miquelon"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('America/Miquelon'); +} else { + putenv("TZ=America/Miquelon"); +} $tStamp = mktime (17, 17, 17, 1, 3767, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Thursday", $tStamp); @@ -165,7 +241,11 @@ print "wanted=Thursday 01:00:00\n\n"; print "TZ=Pacific/Palau - Is it OK for this to be 9 AM? No DST or timezone transition.\n"; -putenv("TZ=Pacific/Palau"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Palau'); +} else { + putenv("TZ=Pacific/Palau"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Saturday", $tStamp); @@ -174,7 +254,11 @@ print "wanted=Saturday 00:00:00\n\n"; print "TZ=Pacific/Funafuti - Is it OK for this to be midday? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Pacific/Funafuti"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Funafuti'); +} else { + putenv("TZ=Pacific/Funafuti"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Wednesday", $tStamp); @@ -183,7 +267,11 @@ print "wanted=Wednesday 00:00:00\n\n"; print "TZ=Pacific/Wake - Is it OK for this to be midday? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Pacific/Wake"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Wake'); +} else { + putenv("TZ=Pacific/Wake"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Tuesday", $tStamp); @@ -192,7 +280,11 @@ print "wanted=Tuesday 00:00:00\n\n"; print "TZ=Pacific/Wallis - Is it OK for this to be midday? Note: does not appear to have a DST or timezone transition.\n"; -putenv("TZ=Pacific/Wallis"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('Pacific/Wallis'); +} else { + putenv("TZ=Pacific/Wallis"); +} $tStamp = mktime (17, 17, 17, 1, 1, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Tuesday", $tStamp); @@ -200,7 +292,11 @@ print "result=".date("l Y-m-d H:i:s T I", $strtotime_tstamp)."\n"; print "wanted=Tuesday 00:00:00\n\n"; print "TZ=America/Paramaribo - Is it OK for this to be 0:30 AM? yes\n"; -putenv("TZ=America/Paramaribo"); +if (defined('PHP_WINDOWS_VERSION_MAJOR')) { + date_default_timezone_set('America/Paramaribo'); +} else { + putenv("TZ=America/Paramaribo"); +} $tStamp = mktime (17, 17, 17, 1, 5381, 1970); print "tStamp=". date("l Y-m-d H:i:s T I", $tStamp). "\n"; $strtotime_tstamp = strtotime("next Monday", $tStamp); From 84c94e29c9bb7c3b27d7b4fb41c599fb774f4faf Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 13 Sep 2011 12:44:13 +0000 Subject: [PATCH 0944/2394] Fixed Bug #55674 (fgetcsv & str_getcsv skip empty fields in some tab-separated records) which was introduced by r311543 --- ext/standard/file.c | 2 +- ext/standard/tests/strings/bug55674.phpt | 50 ++++++++++++++++++++++++ 2 files changed, 51 insertions(+), 1 deletion(-) create mode 100644 ext/standard/tests/strings/bug55674.phpt diff --git a/ext/standard/file.c b/ext/standard/file.c index 3ef8980f24841..4240e74e8196d 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -2051,7 +2051,7 @@ PHPAPI void php_fgetcsv(php_stream *stream, char delimiter, char enclosure, char inc_len = (bptr < limit ? (*bptr == '\0' ? 1: php_mblen(bptr, limit - bptr)): 0); if (inc_len == 1) { char *tmp = bptr; - while (isspace((int)*(unsigned char *)tmp)) { + while ((*tmp != delimiter) && isspace((int)*(unsigned char *)tmp)) { tmp++; } if (*tmp == enclosure) { diff --git a/ext/standard/tests/strings/bug55674.phpt b/ext/standard/tests/strings/bug55674.phpt new file mode 100644 index 0000000000000..72ece642a73df --- /dev/null +++ b/ext/standard/tests/strings/bug55674.phpt @@ -0,0 +1,50 @@ +--TEST-- +Bug #55674 (fgetcsv & str_getcsv skip empty fields in some tab-separated records) +--FILE-- + +--EXPECT-- +array(3) { + [0]=> + string(1) "0" + [1]=> + string(0) "" + [2]=> + string(1) "2" +} +array(3) { + [0]=> + string(1) "0" + [1]=> + string(1) " " + [2]=> + string(1) "2" +} +array(5) { + [0]=> + string(0) "" + [1]=> + string(0) "" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(0) "" +} +array(5) { + [0]=> + string(1) " " + [1]=> + string(2) " " + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(1) " " +} From 9b881b680c4c6cc9cdb7de764527ace6f0b7a34e Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 13 Sep 2011 13:26:48 +0000 Subject: [PATCH 0945/2394] - skip on win, runtime TZ via putenv is not supported with ext/date --- ext/date/tests/bug33532.phpt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/date/tests/bug33532.phpt b/ext/date/tests/bug33532.phpt index 5c88e73acde9b..148630855d1ee 100644 --- a/ext/date/tests/bug33532.phpt +++ b/ext/date/tests/bug33532.phpt @@ -5,7 +5,8 @@ error_reporting=2047 date.timezone=UTC --SKIPIF-- --FILE-- Date: Tue, 13 Sep 2011 13:29:35 +0000 Subject: [PATCH 0946/2394] Fixed ZE specific compile warnings (Bug #55629) --- Zend/zend.c | 20 +++--- Zend/zend.h | 14 ++--- Zend/zend_API.c | 105 ++++++++++++++++---------------- Zend/zend_API.h | 60 +++++++++--------- Zend/zend_alloc.c | 8 +-- Zend/zend_alloc.h | 4 +- Zend/zend_builtin_functions.c | 46 +++++++------- Zend/zend_closures.c | 2 +- Zend/zend_compile.c | 44 ++++++------- Zend/zend_compile.h | 24 ++++---- Zend/zend_constants.c | 7 ++- Zend/zend_exceptions.c | 4 +- Zend/zend_execute.c | 4 +- Zend/zend_execute.h | 8 +-- Zend/zend_execute_API.c | 23 +++---- Zend/zend_gc.h | 2 +- Zend/zend_hash.c | 18 +++--- Zend/zend_hash.h | 4 +- Zend/zend_highlight.c | 18 +++--- Zend/zend_indent.c | 8 +-- Zend/zend_interfaces.c | 2 +- Zend/zend_interfaces.h | 2 +- Zend/zend_iterators.c | 4 +- Zend/zend_language_scanner.h | 2 +- Zend/zend_language_scanner.l | 27 ++++---- Zend/zend_list.c | 4 +- Zend/zend_object_handlers.c | 12 ++-- Zend/zend_object_handlers.h | 12 ++-- Zend/zend_opcode.c | 30 ++++----- Zend/zend_stream.c | 2 +- Zend/zend_stream.h | 2 +- Zend/zend_string.c | 2 +- Zend/zend_string.h | 4 +- Zend/zend_types.h | 2 +- Zend/zend_vm_def.h | 10 +-- Zend/zend_vm_execute.h | 10 +-- ext/dom/node.c | 2 +- ext/pdo/pdo_dbh.c | 2 +- ext/pdo/pdo_stmt.c | 4 +- ext/phar/func_interceptors.c | 14 ++--- ext/phar/phar.c | 6 +- ext/phar/phar_object.c | 8 +-- ext/phar/util.c | 6 +- ext/reflection/php_reflection.c | 24 ++++---- ext/session/session.c | 4 +- ext/soap/php_encoding.c | 4 +- ext/standard/array.c | 4 +- ext/standard/assert.c | 2 +- ext/standard/head.c | 2 +- ext/standard/http.c | 10 +-- ext/standard/mail.c | 2 +- ext/standard/php_string.h | 4 +- ext/standard/string.c | 12 ++-- ext/standard/user_filters.c | 3 +- ext/standard/var.c | 22 +++---- ext/wddx/wddx.c | 4 +- main/SAPI.c | 2 +- main/fopen_wrappers.c | 4 +- main/main.c | 8 +-- main/output.c | 2 +- main/php_output.h | 4 +- main/php_variables.c | 20 +++--- main/streams/plain_wrapper.c | 2 +- sapi/cli/php_cli.c | 6 +- 64 files changed, 371 insertions(+), 366 deletions(-) diff --git a/Zend/zend.c b/Zend/zend.c index 333ff693b41e9..d222e262894fc 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -63,7 +63,7 @@ ZEND_API char *(*zend_resolve_path)(const char *filename, int filename_len TSRML void (*zend_on_timeout)(int seconds TSRMLS_DC); -static void (*zend_message_dispatcher_p)(long message, void *data TSRMLS_DC); +static void (*zend_message_dispatcher_p)(long message, const void *data TSRMLS_DC); static int (*zend_get_configuration_directive_p)(const char *name, uint name_length, zval *contents); static ZEND_INI_MH(OnUpdateErrorReporting) /* {{{ */ @@ -157,7 +157,7 @@ static void print_hash(zend_write_func_t write_func, HashTable *ht, int indent, switch (zend_hash_get_current_key_ex(ht, &string_key, &str_len, &num_key, 0, &iterator)) { case HASH_KEY_IS_STRING: if (is_object) { - char *prop_name, *class_name; + const char *prop_name, *class_name; int mangled = zend_unmangle_property_name(string_key, str_len - 1, &class_name, &prop_name); ZEND_PUTS_EX(prop_name); @@ -349,7 +349,7 @@ ZEND_API void zend_print_flat_zval_r(zval *expr TSRMLS_DC) /* {{{ */ case IS_OBJECT: { HashTable *properties = NULL; - char *class_name = NULL; + const char *class_name = NULL; zend_uint clen; if (Z_OBJ_HANDLER_P(expr, get_class_name)) { @@ -361,7 +361,7 @@ ZEND_API void zend_print_flat_zval_r(zval *expr TSRMLS_DC) /* {{{ */ zend_printf("%s Object (", "Unknown Class"); } if (class_name) { - efree(class_name); + efree((char*)class_name); } if (Z_OBJ_HANDLER_P(expr, get_properties)) { properties = Z_OBJPROP_P(expr); @@ -407,7 +407,7 @@ ZEND_API void zend_print_zval_r_ex(zend_write_func_t write_func, zval *expr, int case IS_OBJECT: { HashTable *properties; - char *class_name = NULL; + const char *class_name = NULL; zend_uint clen; int is_temp; @@ -421,7 +421,7 @@ ZEND_API void zend_print_zval_r_ex(zend_write_func_t write_func, zval *expr, int } ZEND_PUTS_EX(" Object\n"); if (class_name) { - efree(class_name); + efree((char*)class_name); } if ((properties = Z_OBJDEBUG_P(expr, is_temp)) == NULL) { break; @@ -616,7 +616,7 @@ static void php_scanner_globals_ctor(zend_php_scanner_globals *scanner_globals_p void zend_init_opcodes_handlers(void); -static zend_bool php_auto_globals_create_globals(char *name, uint name_len TSRMLS_DC) /* {{{ */ +static zend_bool php_auto_globals_create_globals(const char *name, uint name_len TSRMLS_DC) /* {{{ */ { zval *globals; @@ -956,7 +956,7 @@ void zend_deactivate(TSRMLS_D) /* {{{ */ /* }}} */ BEGIN_EXTERN_C() -ZEND_API void zend_message_dispatcher(long message, void *data TSRMLS_DC) /* {{{ */ +ZEND_API void zend_message_dispatcher(long message, const void *data TSRMLS_DC) /* {{{ */ { if (zend_message_dispatcher_p) { zend_message_dispatcher_p(message, data TSRMLS_CC); @@ -999,7 +999,7 @@ ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */ zval ***params; zval *retval; zval *z_error_type, *z_error_message, *z_error_filename, *z_error_lineno, *z_context; - char *error_filename; + const char *error_filename; uint error_lineno; zval *orig_user_error_handler; zend_bool in_compilation; @@ -1307,7 +1307,7 @@ ZEND_API int zend_execute_scripts(int type TSRMLS_DC, zval **retval, int file_co ZEND_API char *zend_make_compiled_string_description(const char *name TSRMLS_DC) /* {{{ */ { - char *cur_filename; + const char *cur_filename; int cur_lineno; char *compiled_string_description; diff --git a/Zend/zend.h b/Zend/zend.h index 4e1290a5c0c86..5c092dbc6dc7f 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -422,12 +422,12 @@ typedef struct _zend_serialize_data zend_serialize_data; typedef struct _zend_unserialize_data zend_unserialize_data; struct _zend_trait_method_reference { - char* method_name; + const char* method_name; unsigned int mname_len; zend_class_entry *ce; - char* class_name; + const char* class_name; unsigned int cname_len; }; typedef struct _zend_trait_method_reference zend_trait_method_reference; @@ -447,7 +447,7 @@ struct _zend_trait_alias { /** * name for method to be added */ - char* alias; + const char* alias; unsigned int alias_len; /** @@ -511,10 +511,10 @@ struct _zend_class_entry { union { struct { - char *filename; + const char *filename; zend_uint line_start; zend_uint line_end; - char *doc_comment; + const char *doc_comment; zend_uint doc_comment_len; } user; struct { @@ -530,7 +530,7 @@ typedef struct _zend_utility_functions { int (*printf_function)(const char *format, ...) ZEND_ATTRIBUTE_PTR_FORMAT(printf, 1, 2); int (*write_function)(const char *str, uint str_length); FILE *(*fopen_function)(const char *filename, char **opened_path TSRMLS_DC); - void (*message_handler)(long message, void *data TSRMLS_DC); + void (*message_handler)(long message, const void *data TSRMLS_DC); #ifndef ZEND_SIGNALS void (*block_interruptions)(void); void (*unblock_interruptions)(void); @@ -714,7 +714,7 @@ END_EXTERN_C() #endif BEGIN_EXTERN_C() -ZEND_API void zend_message_dispatcher(long message, void *data TSRMLS_DC); +ZEND_API void zend_message_dispatcher(long message, const void *data TSRMLS_DC); ZEND_API int zend_get_configuration_directive(const char *name, uint name_length, zval *contents); END_EXTERN_C() diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 5401483db7584..ed2f6d6e38562 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -192,8 +192,8 @@ ZEND_API int zend_copy_parameters_array(int param_count, zval *argument_array TS ZEND_API void zend_wrong_param_count(TSRMLS_D) /* {{{ */ { - char *space; - char *class_name = get_active_class_name(&space TSRMLS_CC); + const char *space; + const char *class_name = get_active_class_name(&space TSRMLS_CC); zend_error(E_WARNING, "Wrong parameter count for %s%s%s()", class_name, space, get_active_function_name(TSRMLS_C)); } @@ -299,7 +299,7 @@ static int parse_arg_object_to_string(zval **arg, char **p, int *pl, int type TS } /* }}} */ -static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const char **spec, char **error, int *severity TSRMLS_DC) /* {{{ */ +static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const char **spec, char **error, int *severity TSRMLS_DC) /* {{{ */ { const char *spec_walk = *spec; char c = *spec_walk++; @@ -665,14 +665,15 @@ static char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, const cha static int zend_parse_arg(int arg_num, zval **arg, va_list *va, const char **spec, int quiet TSRMLS_DC) /* {{{ */ { - char *expected_type = NULL, *error = NULL; + const char *expected_type = NULL; + char *error = NULL; int severity = E_WARNING; expected_type = zend_parse_arg_impl(arg_num, arg, va, spec, &error, &severity TSRMLS_CC); if (expected_type) { if (!quiet && (*expected_type || error)) { - char *space; - char *class_name = get_active_class_name(&space TSRMLS_CC); + const char *space; + const char *class_name = get_active_class_name(&space TSRMLS_CC); if (error) { zend_error(severity, "%s%s%s() expects parameter %d %s", @@ -735,7 +736,7 @@ static int zend_parse_va_args(int num_args, const char *type_spec, va_list *va, if (have_varargs) { if (!quiet) { zend_function *active_function = EG(current_execute_data)->function_state.function; - char *class_name = active_function->common.scope ? active_function->common.scope->name : ""; + const char *class_name = active_function->common.scope ? active_function->common.scope->name : ""; zend_error(E_WARNING, "%s%s%s(): only one varargs specifier (* or +) is permitted", class_name, class_name[0] ? "::" : "", @@ -755,7 +756,7 @@ static int zend_parse_va_args(int num_args, const char *type_spec, va_list *va, default: if (!quiet) { zend_function *active_function = EG(current_execute_data)->function_state.function; - char *class_name = active_function->common.scope ? active_function->common.scope->name : ""; + const char *class_name = active_function->common.scope ? active_function->common.scope->name : ""; zend_error(E_WARNING, "%s%s%s(): bad type specifier while parsing parameters", class_name, class_name[0] ? "::" : "", @@ -778,7 +779,7 @@ static int zend_parse_va_args(int num_args, const char *type_spec, va_list *va, if (num_args < min_num_args || (num_args > max_num_args && max_num_args > 0)) { if (!quiet) { zend_function *active_function = EG(current_execute_data)->function_state.function; - char *class_name = active_function->common.scope ? active_function->common.scope->name : ""; + const char *class_name = active_function->common.scope ? active_function->common.scope->name : ""; zend_error(E_WARNING, "%s%s%s() expects %s %d parameter%s, %d given", class_name, class_name[0] ? "::" : "", @@ -856,8 +857,8 @@ static int zend_parse_va_args(int num_args, const char *type_spec, va_list *va, int __num_args = (num_args); \ \ if (0 == (type_spec)[0] && 0 != __num_args && !(quiet)) { \ - char *__space; \ - char * __class_name = get_active_class_name(&__space TSRMLS_CC); \ + const char *__space; \ + const char * __class_name = get_active_class_name(&__space TSRMLS_CC); \ zend_error(E_WARNING, "%s%s%s() expects exactly 0 parameters, %d given", \ __class_name, __space, \ get_active_function_name(TSRMLS_C), __num_args); \ @@ -1004,7 +1005,7 @@ static int zend_merge_property(zval **value TSRMLS_DC, int num_args, va_list arg * because it may call __set from the uninitialized object otherwise. */ ZEND_API void zend_merge_properties(zval *obj, HashTable *properties, int destroy_ht TSRMLS_DC) /* {{{ */ { - zend_object_handlers *obj_ht = Z_OBJ_HT_P(obj); + const zend_object_handlers *obj_ht = Z_OBJ_HT_P(obj); zend_class_entry *old_scope = EG(scope); EG(scope) = Z_OBJCE_P(obj); @@ -1924,7 +1925,7 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio HashTable *target_function_table = function_table; int error_type; zend_function *ctor = NULL, *dtor = NULL, *clone = NULL, *__get = NULL, *__set = NULL, *__unset = NULL, *__isset = NULL, *__call = NULL, *__callstatic = NULL, *__tostring = NULL; - char *lowercase_name; + const char *lowercase_name; int fname_len; const char *lc_class_name = NULL; int class_name_len = 0; @@ -2011,13 +2012,13 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio } } else { if (scope && (scope->ce_flags & ZEND_ACC_INTERFACE)) { - efree(lc_class_name); + efree((char*)lc_class_name); zend_error(error_type, "Interface %s cannot contain non abstract method %s()", scope->name, ptr->fname); return FAILURE; } if (!internal_function->handler) { if (scope) { - efree(lc_class_name); + efree((char*)lc_class_name); } zend_error(error_type, "Method %s%s%s() cannot be a NULL function", scope ? scope->name : "", scope ? "::" : "", ptr->fname); zend_unregister_functions(functions, count, target_function_table TSRMLS_CC); @@ -2079,7 +2080,7 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio } if (unload) { /* before unloading, display all remaining bad function in the module */ if (scope) { - efree(lc_class_name); + efree((char*)lc_class_name); } while (ptr->fname) { fname_len = strlen(ptr->fname); @@ -2087,7 +2088,7 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio if (zend_hash_exists(target_function_table, lowercase_name, fname_len+1)) { zend_error(error_type, "Function registration failed - duplicate name - %s%s%s", scope ? scope->name : "", scope ? "::" : "", ptr->fname); } - efree(lowercase_name); + efree((char*)lowercase_name); ptr++; } zend_unregister_functions(functions, count, target_function_table TSRMLS_CC); @@ -2167,7 +2168,7 @@ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_functio } __isset->common.fn_flags &= ~ZEND_ACC_ALLOW_STATIC; } - efree(lc_class_name); + efree((char*)lc_class_name); } return SUCCESS; } @@ -2394,7 +2395,7 @@ static zend_class_entry *do_register_internal_class(zend_class_entry *orig_class } zend_str_tolower_copy(lowercase_name, orig_class_entry->name, class_entry->name_length); - lowercase_name = zend_new_interned_string(lowercase_name, class_entry->name_length + 1, 1 TSRMLS_CC); + lowercase_name = (char*)zend_new_interned_string(lowercase_name, class_entry->name_length + 1, 1 TSRMLS_CC); if (IS_INTERNED(lowercase_name)) { zend_hash_quick_update(CG(class_table), lowercase_name, class_entry->name_length+1, INTERNED_HASH(lowercase_name), &class_entry, sizeof(zend_class_entry *), NULL); } else { @@ -2768,7 +2769,7 @@ static int zend_is_callable_check_func(int check_flags, zval *callable, zend_fca !instanceof_function(ce_org, fcc->function_handler->common.scope TSRMLS_CC))) { if ((fcc->function_handler->common.fn_flags & ZEND_ACC_CALL_VIA_HANDLER) != 0) { if (fcc->function_handler->type != ZEND_OVERLOADED_FUNCTION) { - efree(fcc->function_handler->common.function_name); + efree((char*)fcc->function_handler->common.function_name); } efree(fcc->function_handler); } @@ -2944,7 +2945,7 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, zval *object_ptr, uint ch fcc->function_handler->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY || fcc->function_handler->type == ZEND_OVERLOADED_FUNCTION)) { if (fcc->function_handler->type != ZEND_OVERLOADED_FUNCTION) { - efree(fcc->function_handler->common.function_name); + efree((char*)fcc->function_handler->common.function_name); } efree(fcc->function_handler); } @@ -3022,7 +3023,7 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, zval *object_ptr, uint ch fcc->function_handler->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY || fcc->function_handler->type == ZEND_OVERLOADED_FUNCTION)) { if (fcc->function_handler->type != ZEND_OVERLOADED_FUNCTION) { - efree(fcc->function_handler->common.function_name); + efree((char*)fcc->function_handler->common.function_name); } efree(fcc->function_handler); } @@ -3100,7 +3101,7 @@ ZEND_API zend_bool zend_make_callable(zval *callable, char **callable_name TSRML fcc.function_handler->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY || fcc.function_handler->type == ZEND_OVERLOADED_FUNCTION)) { if (fcc.function_handler->type != ZEND_OVERLOADED_FUNCTION) { - efree(fcc.function_handler->common.function_name); + efree((char*)fcc.function_handler->common.function_name); } efree(fcc.function_handler); } @@ -3286,10 +3287,10 @@ ZEND_API const char *zend_get_module_version(const char *module_name) /* {{{ */ } /* }}} */ -ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, int name_length, zval *property, int access_type, char *doc_comment, int doc_comment_len TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, int name_length, zval *property, int access_type, const char *doc_comment, int doc_comment_len TSRMLS_DC) /* {{{ */ { zend_property_info property_info, *property_info_ptr; - char *interned_name; + const char *interned_name; ulong h = zend_get_hash_value(name, name_length+1); if (!(access_type & ZEND_ACC_PPP_MASK)) { @@ -3365,9 +3366,9 @@ ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, in interned_name = zend_new_interned_string(property_info.name, property_info.name_length+1, 0 TSRMLS_CC); if (interned_name != property_info.name) { if (ce->type == ZEND_USER_CLASS) { - efree(property_info.name); + efree((char*)property_info.name); } else { - free(property_info.name); + free((char*)property_info.name); } property_info.name = interned_name; } @@ -3386,13 +3387,13 @@ ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, in } /* }}} */ -ZEND_API int zend_declare_property(zend_class_entry *ce, char *name, int name_length, zval *property, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property(zend_class_entry *ce, const char *name, int name_length, zval *property, int access_type TSRMLS_DC) /* {{{ */ { return zend_declare_property_ex(ce, name, name_length, property, access_type, NULL, 0 TSRMLS_CC); } /* }}} */ -ZEND_API int zend_declare_property_null(zend_class_entry *ce, char *name, int name_length, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_null(zend_class_entry *ce, const char *name, int name_length, int access_type TSRMLS_DC) /* {{{ */ { zval *property; @@ -3406,7 +3407,7 @@ ZEND_API int zend_declare_property_null(zend_class_entry *ce, char *name, int na } /* }}} */ -ZEND_API int zend_declare_property_bool(zend_class_entry *ce, char *name, int name_length, long value, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_bool(zend_class_entry *ce, const char *name, int name_length, long value, int access_type TSRMLS_DC) /* {{{ */ { zval *property; @@ -3421,7 +3422,7 @@ ZEND_API int zend_declare_property_bool(zend_class_entry *ce, char *name, int na } /* }}} */ -ZEND_API int zend_declare_property_long(zend_class_entry *ce, char *name, int name_length, long value, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_long(zend_class_entry *ce, const char *name, int name_length, long value, int access_type TSRMLS_DC) /* {{{ */ { zval *property; @@ -3436,7 +3437,7 @@ ZEND_API int zend_declare_property_long(zend_class_entry *ce, char *name, int na } /* }}} */ -ZEND_API int zend_declare_property_double(zend_class_entry *ce, char *name, int name_length, double value, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_double(zend_class_entry *ce, const char *name, int name_length, double value, int access_type TSRMLS_DC) /* {{{ */ { zval *property; @@ -3451,7 +3452,7 @@ ZEND_API int zend_declare_property_double(zend_class_entry *ce, char *name, int } /* }}} */ -ZEND_API int zend_declare_property_string(zend_class_entry *ce, char *name, int name_length, const char *value, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_string(zend_class_entry *ce, const char *name, int name_length, const char *value, int access_type TSRMLS_DC) /* {{{ */ { zval *property; int len = strlen(value); @@ -3468,7 +3469,7 @@ ZEND_API int zend_declare_property_string(zend_class_entry *ce, char *name, int } /* }}} */ -ZEND_API int zend_declare_property_stringl(zend_class_entry *ce, char *name, int name_length, const char *value, int value_len, int access_type TSRMLS_DC) /* {{{ */ +ZEND_API int zend_declare_property_stringl(zend_class_entry *ce, const char *name, int name_length, const char *value, int value_len, int access_type TSRMLS_DC) /* {{{ */ { zval *property; @@ -3572,7 +3573,7 @@ ZEND_API int zend_declare_class_constant_string(zend_class_entry *ce, const char } /* }}} */ -ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, char *name, int name_length, zval *value TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, const char *name, int name_length, zval *value TSRMLS_DC) /* {{{ */ { zval *property; zend_class_entry *old_scope = EG(scope); @@ -3580,7 +3581,7 @@ ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, char * EG(scope) = scope; if (!Z_OBJ_HT_P(object)->write_property) { - char *class_name; + const char *class_name; zend_uint class_name_len; zend_get_object_classname(object, &class_name, &class_name_len TSRMLS_CC); @@ -3596,7 +3597,7 @@ ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, char * } /* }}} */ -ZEND_API void zend_update_property_null(zend_class_entry *scope, zval *object, char *name, int name_length TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property_null(zend_class_entry *scope, zval *object, const char *name, int name_length TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3608,7 +3609,7 @@ ZEND_API void zend_update_property_null(zend_class_entry *scope, zval *object, c } /* }}} */ -ZEND_API void zend_update_property_bool(zend_class_entry *scope, zval *object, char *name, int name_length, long value TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property_bool(zend_class_entry *scope, zval *object, const char *name, int name_length, long value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3620,7 +3621,7 @@ ZEND_API void zend_update_property_bool(zend_class_entry *scope, zval *object, c } /* }}} */ -ZEND_API void zend_update_property_long(zend_class_entry *scope, zval *object, char *name, int name_length, long value TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property_long(zend_class_entry *scope, zval *object, const char *name, int name_length, long value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3632,7 +3633,7 @@ ZEND_API void zend_update_property_long(zend_class_entry *scope, zval *object, c } /* }}} */ -ZEND_API void zend_update_property_double(zend_class_entry *scope, zval *object, char *name, int name_length, double value TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property_double(zend_class_entry *scope, zval *object, const char *name, int name_length, double value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3644,7 +3645,7 @@ ZEND_API void zend_update_property_double(zend_class_entry *scope, zval *object, } /* }}} */ -ZEND_API void zend_update_property_string(zend_class_entry *scope, zval *object, char *name, int name_length, const char *value TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property_string(zend_class_entry *scope, zval *object, const char *name, int name_length, const char *value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3656,7 +3657,7 @@ ZEND_API void zend_update_property_string(zend_class_entry *scope, zval *object, } /* }}} */ -ZEND_API void zend_update_property_stringl(zend_class_entry *scope, zval *object, char *name, int name_length, const char *value, int value_len TSRMLS_DC) /* {{{ */ +ZEND_API void zend_update_property_stringl(zend_class_entry *scope, zval *object, const char *name, int name_length, const char *value, int value_len TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3668,7 +3669,7 @@ ZEND_API void zend_update_property_stringl(zend_class_entry *scope, zval *object } /* }}} */ -ZEND_API int zend_update_static_property(zend_class_entry *scope, char *name, int name_length, zval *value TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property(zend_class_entry *scope, const char *name, int name_length, zval *value TSRMLS_DC) /* {{{ */ { zval **property; zend_class_entry *old_scope = EG(scope); @@ -3703,7 +3704,7 @@ ZEND_API int zend_update_static_property(zend_class_entry *scope, char *name, in } /* }}} */ -ZEND_API int zend_update_static_property_null(zend_class_entry *scope, char *name, int name_length TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property_null(zend_class_entry *scope, const char *name, int name_length TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3715,7 +3716,7 @@ ZEND_API int zend_update_static_property_null(zend_class_entry *scope, char *nam } /* }}} */ -ZEND_API int zend_update_static_property_bool(zend_class_entry *scope, char *name, int name_length, long value TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property_bool(zend_class_entry *scope, const char *name, int name_length, long value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3727,7 +3728,7 @@ ZEND_API int zend_update_static_property_bool(zend_class_entry *scope, char *nam } /* }}} */ -ZEND_API int zend_update_static_property_long(zend_class_entry *scope, char *name, int name_length, long value TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property_long(zend_class_entry *scope, const char *name, int name_length, long value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3739,7 +3740,7 @@ ZEND_API int zend_update_static_property_long(zend_class_entry *scope, char *nam } /* }}} */ -ZEND_API int zend_update_static_property_double(zend_class_entry *scope, char *name, int name_length, double value TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property_double(zend_class_entry *scope, const char *name, int name_length, double value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3751,7 +3752,7 @@ ZEND_API int zend_update_static_property_double(zend_class_entry *scope, char *n } /* }}} */ -ZEND_API int zend_update_static_property_string(zend_class_entry *scope, char *name, int name_length, const char *value TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property_string(zend_class_entry *scope, const char *name, int name_length, const char *value TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3763,7 +3764,7 @@ ZEND_API int zend_update_static_property_string(zend_class_entry *scope, char *n } /* }}} */ -ZEND_API int zend_update_static_property_stringl(zend_class_entry *scope, char *name, int name_length, const char *value, int value_len TSRMLS_DC) /* {{{ */ +ZEND_API int zend_update_static_property_stringl(zend_class_entry *scope, const char *name, int name_length, const char *value, int value_len TSRMLS_DC) /* {{{ */ { zval *tmp; @@ -3775,7 +3776,7 @@ ZEND_API int zend_update_static_property_stringl(zend_class_entry *scope, char * } /* }}} */ -ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, char *name, int name_length, zend_bool silent TSRMLS_DC) /* {{{ */ +ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, const char *name, int name_length, zend_bool silent TSRMLS_DC) /* {{{ */ { zval *property, *value; zend_class_entry *old_scope = EG(scope); @@ -3783,7 +3784,7 @@ ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, char *n EG(scope) = scope; if (!Z_OBJ_HT_P(object)->read_property) { - char *class_name; + const char *class_name; zend_uint class_name_len; zend_get_object_classname(object, &class_name, &class_name_len TSRMLS_CC); @@ -3800,7 +3801,7 @@ ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, char *n } /* }}} */ -ZEND_API zval *zend_read_static_property(zend_class_entry *scope, char *name, int name_length, zend_bool silent TSRMLS_DC) /* {{{ */ +ZEND_API zval *zend_read_static_property(zend_class_entry *scope, const char *name, int name_length, zend_bool silent TSRMLS_DC) /* {{{ */ { zval **property; zend_class_entry *old_scope = EG(scope); diff --git a/Zend/zend_API.h b/Zend/zend_API.h index 487356e575efb..a4477ffab2c7f 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -295,14 +295,14 @@ ZEND_API zend_bool zend_is_callable(zval *callable, uint check_flags, char **cal ZEND_API zend_bool zend_make_callable(zval *callable, char **callable_name TSRMLS_DC); ZEND_API const char *zend_get_module_version(const char *module_name); ZEND_API int zend_get_module_started(const char *module_name); -ZEND_API int zend_declare_property(zend_class_entry *ce, char *name, int name_length, zval *property, int access_type TSRMLS_DC); -ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, int name_length, zval *property, int access_type, char *doc_comment, int doc_comment_len TSRMLS_DC); -ZEND_API int zend_declare_property_null(zend_class_entry *ce, char *name, int name_length, int access_type TSRMLS_DC); -ZEND_API int zend_declare_property_bool(zend_class_entry *ce, char *name, int name_length, long value, int access_type TSRMLS_DC); -ZEND_API int zend_declare_property_long(zend_class_entry *ce, char *name, int name_length, long value, int access_type TSRMLS_DC); -ZEND_API int zend_declare_property_double(zend_class_entry *ce, char *name, int name_length, double value, int access_type TSRMLS_DC); -ZEND_API int zend_declare_property_string(zend_class_entry *ce, char *name, int name_length, const char *value, int access_type TSRMLS_DC); -ZEND_API int zend_declare_property_stringl(zend_class_entry *ce, char *name, int name_length, const char *value, int value_len, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property(zend_class_entry *ce, const char *name, int name_length, zval *property, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property_ex(zend_class_entry *ce, const char *name, int name_length, zval *property, int access_type, const char *doc_comment, int doc_comment_len TSRMLS_DC); +ZEND_API int zend_declare_property_null(zend_class_entry *ce, const char *name, int name_length, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property_bool(zend_class_entry *ce, const char *name, int name_length, long value, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property_long(zend_class_entry *ce, const char *name, int name_length, long value, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property_double(zend_class_entry *ce, const char *name, int name_length, double value, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property_string(zend_class_entry *ce, const char *name, int name_length, const char *value, int access_type TSRMLS_DC); +ZEND_API int zend_declare_property_stringl(zend_class_entry *ce, const char *name, int name_length, const char *value, int value_len, int access_type TSRMLS_DC); ZEND_API int zend_declare_class_constant(zend_class_entry *ce, const char *name, size_t name_length, zval *value TSRMLS_DC); ZEND_API int zend_declare_class_constant_null(zend_class_entry *ce, const char *name, size_t name_length TSRMLS_DC); @@ -313,25 +313,25 @@ ZEND_API int zend_declare_class_constant_stringl(zend_class_entry *ce, const cha ZEND_API int zend_declare_class_constant_string(zend_class_entry *ce, const char *name, size_t name_length, const char *value TSRMLS_DC); ZEND_API void zend_update_class_constants(zend_class_entry *class_type TSRMLS_DC); -ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, char *name, int name_length, zval *value TSRMLS_DC); -ZEND_API void zend_update_property_null(zend_class_entry *scope, zval *object, char *name, int name_length TSRMLS_DC); -ZEND_API void zend_update_property_bool(zend_class_entry *scope, zval *object, char *name, int name_length, long value TSRMLS_DC); -ZEND_API void zend_update_property_long(zend_class_entry *scope, zval *object, char *name, int name_length, long value TSRMLS_DC); -ZEND_API void zend_update_property_double(zend_class_entry *scope, zval *object, char *name, int name_length, double value TSRMLS_DC); -ZEND_API void zend_update_property_string(zend_class_entry *scope, zval *object, char *name, int name_length, const char *value TSRMLS_DC); -ZEND_API void zend_update_property_stringl(zend_class_entry *scope, zval *object, char *name, int name_length, const char *value, int value_length TSRMLS_DC); - -ZEND_API int zend_update_static_property(zend_class_entry *scope, char *name, int name_length, zval *value TSRMLS_DC); -ZEND_API int zend_update_static_property_null(zend_class_entry *scope, char *name, int name_length TSRMLS_DC); -ZEND_API int zend_update_static_property_bool(zend_class_entry *scope, char *name, int name_length, long value TSRMLS_DC); -ZEND_API int zend_update_static_property_long(zend_class_entry *scope, char *name, int name_length, long value TSRMLS_DC); -ZEND_API int zend_update_static_property_double(zend_class_entry *scope, char *name, int name_length, double value TSRMLS_DC); -ZEND_API int zend_update_static_property_string(zend_class_entry *scope, char *name, int name_length, const char *value TSRMLS_DC); -ZEND_API int zend_update_static_property_stringl(zend_class_entry *scope, char *name, int name_length, const char *value, int value_length TSRMLS_DC); - -ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, char *name, int name_length, zend_bool silent TSRMLS_DC); - -ZEND_API zval *zend_read_static_property(zend_class_entry *scope, char *name, int name_length, zend_bool silent TSRMLS_DC); +ZEND_API void zend_update_property(zend_class_entry *scope, zval *object, const char *name, int name_length, zval *value TSRMLS_DC); +ZEND_API void zend_update_property_null(zend_class_entry *scope, zval *object, const char *name, int name_length TSRMLS_DC); +ZEND_API void zend_update_property_bool(zend_class_entry *scope, zval *object, const char *name, int name_length, long value TSRMLS_DC); +ZEND_API void zend_update_property_long(zend_class_entry *scope, zval *object, const char *name, int name_length, long value TSRMLS_DC); +ZEND_API void zend_update_property_double(zend_class_entry *scope, zval *object, const char *name, int name_length, double value TSRMLS_DC); +ZEND_API void zend_update_property_string(zend_class_entry *scope, zval *object, const char *name, int name_length, const char *value TSRMLS_DC); +ZEND_API void zend_update_property_stringl(zend_class_entry *scope, zval *object, const char *name, int name_length, const char *value, int value_length TSRMLS_DC); + +ZEND_API int zend_update_static_property(zend_class_entry *scope, const char *name, int name_length, zval *value TSRMLS_DC); +ZEND_API int zend_update_static_property_null(zend_class_entry *scope, const char *name, int name_length TSRMLS_DC); +ZEND_API int zend_update_static_property_bool(zend_class_entry *scope, const char *name, int name_length, long value TSRMLS_DC); +ZEND_API int zend_update_static_property_long(zend_class_entry *scope, const char *name, int name_length, long value TSRMLS_DC); +ZEND_API int zend_update_static_property_double(zend_class_entry *scope, const char *name, int name_length, double value TSRMLS_DC); +ZEND_API int zend_update_static_property_string(zend_class_entry *scope, const char *name, int name_length, const char *value TSRMLS_DC); +ZEND_API int zend_update_static_property_stringl(zend_class_entry *scope, const char *name, int name_length, const char *value, int value_length TSRMLS_DC); + +ZEND_API zval *zend_read_property(zend_class_entry *scope, zval *object, const char *name, int name_length, zend_bool silent TSRMLS_DC); + +ZEND_API zval *zend_read_static_property(zend_class_entry *scope, const char *name, int name_length, zend_bool silent TSRMLS_DC); ZEND_API zend_class_entry *zend_get_class_entry(const zval *zobject TSRMLS_DC); ZEND_API int zend_get_object_classname(const zval *object, const char **class_name, zend_uint *class_name_len TSRMLS_DC); @@ -502,11 +502,11 @@ ZEND_API int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci ZEND_API int zend_set_hash_symbol(zval *symbol, const char *name, int name_length, zend_bool is_ref, int num_symbol_tables, ...); -ZEND_API void zend_delete_variable(zend_execute_data *ex, HashTable *ht, char *name, int name_len, ulong hash_value TSRMLS_DC); +ZEND_API void zend_delete_variable(zend_execute_data *ex, HashTable *ht, const char *name, int name_len, ulong hash_value TSRMLS_DC); -ZEND_API int zend_delete_global_variable(char *name, int name_len TSRMLS_DC); +ZEND_API int zend_delete_global_variable(const char *name, int name_len TSRMLS_DC); -ZEND_API int zend_delete_global_variable_ex(char *name, int name_len, ulong hash_value TSRMLS_DC); +ZEND_API int zend_delete_global_variable_ex(const char *name, int name_len, ulong hash_value TSRMLS_DC); ZEND_API void zend_reset_all_cv(HashTable *symbol_table TSRMLS_DC); diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 3c3b579e7bf0f..963529d998aee 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -344,9 +344,9 @@ typedef struct _zend_mm_block_info { #if ZEND_DEBUG typedef struct _zend_mm_debug_info { - char *filename; + const char *filename; uint lineno; - char *orig_filename; + const char *orig_filename; uint orig_lineno; size_t size; #if ZEND_MM_HEAP_PROTECTION @@ -460,7 +460,7 @@ struct _zend_mm_heap { sizeof(zend_mm_free_block*) * 2 - \ sizeof(zend_mm_small_free_block)) -#define ZEND_MM_REST_BLOCK ((zend_mm_free_block*)(zend_uintptr_t)(1)) +#define ZEND_MM_REST_BLOCK ((zend_mm_free_block**)(zend_uintptr_t)(1)) #define ZEND_MM_MAX_REST_BLOCKS 16 @@ -1750,7 +1750,7 @@ static void zend_mm_safe_error(zend_mm_heap *heap, heap->reserve = NULL; } if (heap->overflow == 0) { - char *error_filename; + const char *error_filename; uint error_lineno; TSRMLS_FETCH(); if (zend_is_compiling(TSRMLS_C)) { diff --git a/Zend/zend_alloc.h b/Zend/zend_alloc.h index 8cbfefb585657..9a09f4cda6b25 100644 --- a/Zend/zend_alloc.h +++ b/Zend/zend_alloc.h @@ -44,9 +44,9 @@ typedef struct _zend_leak_info { void *addr; size_t size; - char *filename; + const char *filename; uint lineno; - char *orig_filename; + const char *orig_filename; uint orig_lineno; } zend_leak_info; diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 3232bfa0d4a17..6e069b6f74499 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -744,7 +744,7 @@ ZEND_FUNCTION(defined) ZEND_FUNCTION(get_class) { zval *obj = NULL; - char *name = ""; + const char *name = ""; zend_uint name_len = 0; int dup; @@ -792,7 +792,7 @@ ZEND_FUNCTION(get_parent_class) { zval *arg; zend_class_entry *ce = NULL; - char *name; + const char *name; zend_uint name_length; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|z", &arg) == FAILURE) { @@ -974,7 +974,8 @@ ZEND_FUNCTION(get_object_vars) zval **value; HashTable *properties; HashPosition pos; - char *key, *prop_name, *class_name; + char *key; + const char *prop_name, *class_name; uint key_len; ulong num_index; zend_object *zobj; @@ -1120,7 +1121,7 @@ ZEND_FUNCTION(method_exists) && memcmp(lcname, ZEND_INVOKE_FUNC_NAME, sizeof(ZEND_INVOKE_FUNC_NAME)-1) == 0) ? 1 : 0); efree(lcname); - efree(((zend_internal_function*)func)->function_name); + efree((char*)((zend_internal_function*)func)->function_name); efree(func); return; } @@ -1450,6 +1451,7 @@ ZEND_FUNCTION(crash) ZEND_FUNCTION(get_included_files) { char *entry; + if (zend_parse_parameters_none() == FAILURE) { return; } @@ -1854,7 +1856,7 @@ ZEND_FUNCTION(zend_thread_id) Get the resource type name for a given resource */ ZEND_FUNCTION(get_resource_type) { - char *resource_type; + const char *resource_type; zval *z_resource_type; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &z_resource_type) == FAILURE) { @@ -2037,11 +2039,11 @@ ZEND_FUNCTION(debug_print_backtrace) { zend_execute_data *ptr, *skip; int lineno, frameno = 0; - char *function_name; - char *filename; + const char *function_name; + const char *filename; const char *class_name = NULL; char *call_type; - char *include_filename = NULL; + const char *include_filename = NULL; zval *arg_array = NULL; int indent = 0; long options = 0; @@ -2148,7 +2150,7 @@ ZEND_FUNCTION(debug_print_backtrace) if (build_filename_arg && include_filename) { MAKE_STD_ZVAL(arg_array); array_init(arg_array); - add_next_index_string(arg_array, include_filename, 1); + add_next_index_string(arg_array, (char*)include_filename, 1); } call_type = NULL; } @@ -2187,7 +2189,7 @@ ZEND_FUNCTION(debug_print_backtrace) ptr = skip->prev_execute_data; ++indent; if (free_class_name) { - efree(free_class_name); + efree((char*)free_class_name); } } } @@ -2198,10 +2200,10 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int { zend_execute_data *ptr, *skip; int lineno, frameno = 0; - char *function_name; - char *filename; - char *class_name; - char *include_filename = NULL; + const char *function_name; + const char *filename; + const char *class_name; + const char *include_filename = NULL; zval *stack_frame; ptr = EG(current_execute_data); @@ -2237,7 +2239,7 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int if (skip->op_array) { filename = skip->op_array->filename; lineno = skip->opline->lineno; - add_assoc_string_ex(stack_frame, "file", sizeof("file"), filename, 1); + add_assoc_string_ex(stack_frame, "file", sizeof("file"), (char*)filename, 1); add_assoc_long_ex(stack_frame, "line", sizeof("line"), lineno); /* try to fetch args only if an FCALL was just made - elsewise we're in the middle of a function @@ -2254,7 +2256,7 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int break; } if (prev->op_array) { - add_assoc_string_ex(stack_frame, "file", sizeof("file"), prev->op_array->filename, 1); + add_assoc_string_ex(stack_frame, "file", sizeof("file"), (char*)prev->op_array->filename, 1); add_assoc_long_ex(stack_frame, "line", sizeof("line"), prev->opline->lineno); break; } @@ -2266,17 +2268,17 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int function_name = ptr->function_state.function->common.function_name; if (function_name) { - add_assoc_string_ex(stack_frame, "function", sizeof("function"), function_name, 1); + add_assoc_string_ex(stack_frame, "function", sizeof("function"), (char*)function_name, 1); if (ptr->object && Z_TYPE_P(ptr->object) == IS_OBJECT) { if (ptr->function_state.function->common.scope) { - add_assoc_string_ex(stack_frame, "class", sizeof("class"), ptr->function_state.function->common.scope->name, 1); + add_assoc_string_ex(stack_frame, "class", sizeof("class"), (char*)ptr->function_state.function->common.scope->name, 1); } else { zend_uint class_name_len; int dup; dup = zend_get_object_classname(ptr->object, &class_name, &class_name_len TSRMLS_CC); - add_assoc_string_ex(stack_frame, "class", sizeof("class"), class_name, dup); + add_assoc_string_ex(stack_frame, "class", sizeof("class"), (char*)class_name, dup); } if ((options & DEBUG_BACKTRACE_PROVIDE_OBJECT) != 0) { @@ -2286,7 +2288,7 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int add_assoc_string_ex(stack_frame, "type", sizeof("type"), "->", 1); } else if (ptr->function_state.function->common.scope) { - add_assoc_string_ex(stack_frame, "class", sizeof("class"), ptr->function_state.function->common.scope->name, 1); + add_assoc_string_ex(stack_frame, "class", sizeof("class"), (char*)ptr->function_state.function->common.scope->name, 1); add_assoc_string_ex(stack_frame, "type", sizeof("type"), "::", 1); } @@ -2340,11 +2342,11 @@ ZEND_API void zend_fetch_debug_backtrace(zval *return_value, int skip_last, int if we have called include in the frame above - this is the file we have included. */ - add_next_index_string(arg_array, include_filename, 1); + add_next_index_string(arg_array, (char*)include_filename, 1); add_assoc_zval_ex(stack_frame, "args", sizeof("args"), arg_array); } - add_assoc_string_ex(stack_frame, "function", sizeof("function"), function_name, 1); + add_assoc_string_ex(stack_frame, "function", sizeof("function"), (char*)function_name, 1); } add_next_index_zval(return_value, stack_frame); diff --git a/Zend/zend_closures.c b/Zend/zend_closures.c index 46f9c67036926..344e6002d50e8 100644 --- a/Zend/zend_closures.c +++ b/Zend/zend_closures.c @@ -71,7 +71,7 @@ ZEND_METHOD(Closure, __invoke) /* {{{ */ efree(arguments); /* destruct the function also, then - we have allocated it in get_method */ - efree(func->internal_function.function_name); + efree((char*)func->internal_function.function_name); efree(func); } /* }}} */ diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 16520336d48e0..da49a99f23489 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -129,7 +129,7 @@ static void zend_destroy_property_info(zend_property_info *property_info) /* {{{ { str_efree(property_info->name); if (property_info->doc_comment) { - efree(property_info->doc_comment); + efree((char*)property_info->doc_comment); } } /* }}} */ @@ -137,7 +137,7 @@ static void zend_destroy_property_info(zend_property_info *property_info) /* {{{ static void zend_destroy_property_info_internal(zend_property_info *property_info) /* {{{ */ { - str_free(property_info->name); + str_free((char*)property_info->name); } /* }}} */ @@ -145,7 +145,7 @@ static void build_runtime_defined_function_key(zval *result, const char *name, i { char char_pos_buf[32]; uint char_pos_len; - char *filename; + const char *filename; char_pos_len = zend_sprintf(char_pos_buf, "%p", LANG_SCNG(yy_text)); if (CG(active_op_array)->filename) { @@ -344,7 +344,7 @@ static inline void zend_insert_literal(zend_op_array *op_array, const zval *zv, { if (Z_TYPE_P(zv) == IS_STRING || Z_TYPE_P(zv) == IS_CONSTANT) { zval *z = (zval*)zv; - Z_STRVAL_P(z) = zend_new_interned_string(Z_STRVAL_P(zv), Z_STRLEN_P(zv) + 1, 1 TSRMLS_CC); + Z_STRVAL_P(z) = (char*)zend_new_interned_string(Z_STRVAL_P(zv), Z_STRLEN_P(zv) + 1, 1 TSRMLS_CC); } CONSTANT_EX(op_array, literal_position) = *zv; Z_SET_REFCOUNT(CONSTANT_EX(op_array, literal_position), 2); @@ -412,7 +412,8 @@ int zend_add_func_name_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC int zend_add_ns_func_name_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC) /* {{{ */ { int ret; - char *lc_name, *ns_separator; + char *lc_name; + const char *ns_separator; int lc_len; zval c; int lc_literal; @@ -431,7 +432,7 @@ int zend_add_ns_func_name_literal(zend_op_array *op_array, const zval *zv TSRMLS lc_literal = zend_add_literal(CG(active_op_array), &c TSRMLS_CC); CALCULATE_LITERAL_HASH(lc_literal); - ns_separator = (char *) zend_memrchr(Z_STRVAL_P(zv), '\\', Z_STRLEN_P(zv)) + 1; + ns_separator = zend_memrchr(Z_STRVAL_P(zv), '\\', Z_STRLEN_P(zv)) + 1; lc_len = Z_STRLEN_P(zv) - (ns_separator - Z_STRVAL_P(zv)); lc_name = zend_str_tolower_dup(ns_separator, lc_len); ZVAL_STRINGL(&c, lc_name, lc_len, 0); @@ -479,7 +480,8 @@ int zend_add_class_name_literal(zend_op_array *op_array, const zval *zv TSRMLS_D int zend_add_const_name_literal(zend_op_array *op_array, const zval *zv, int unqualified TSRMLS_DC) /* {{{ */ { int ret, tmp_literal; - char *name, *tmp_name, *ns_separator; + char *name, *tmp_name; + const char *ns_separator; int name_len, ns_len; zval c; @@ -678,7 +680,7 @@ void fetch_simple_variable_ex(znode *result, znode *varname, int bp, zend_uchar CG(active_op_array)->opcodes[CG(active_op_array)->last-1].opcode != ZEND_BEGIN_SILENCE)) { result->op_type = IS_CV; result->u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len, hash TSRMLS_CC); - varname->u.constant.value.str.val = CG(active_op_array)->vars[result->u.op.var].name; + varname->u.constant.value.str.val = (char*)CG(active_op_array)->vars[result->u.op.var].name; result->EA = 0; return; } @@ -1536,7 +1538,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n int name_len = function_name->u.constant.value.str.len; int function_begin_line = function_token->u.op.opline_num; zend_uint fn_flags; - char *lcname; + const char *lcname; zend_bool orig_interactive; ALLOCA_FLAG(use_heap) @@ -1852,7 +1854,7 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con } else { var.op_type = IS_CV; var.u.op.var = lookup_cv(CG(active_op_array), varname->u.constant.value.str.val, varname->u.constant.value.str.len, 0 TSRMLS_CC); - varname->u.constant.value.str.val = CG(active_op_array)->vars[var.u.op.var].name; + Z_STRVAL(varname->u.constant) = (char*)CG(active_op_array)->vars[var.u.op.var].name; var.EA = 0; if (CG(active_op_array)->vars[var.u.op.var].hash_value == THIS_HASHVAL && Z_STRLEN(varname->u.constant) == sizeof("this")-1 && @@ -1913,7 +1915,7 @@ void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, con if (ZEND_FETCH_CLASS_DEFAULT == zend_get_class_fetch_type(Z_STRVAL(class_type->u.constant), Z_STRLEN(class_type->u.constant))) { zend_resolve_class_name(class_type, opline->extended_value, 1 TSRMLS_CC); } - class_type->u.constant.value.str.val = zend_new_interned_string(class_type->u.constant.value.str.val, class_type->u.constant.value.str.len + 1, 1 TSRMLS_CC); + Z_STRVAL(class_type->u.constant) = (char*)zend_new_interned_string(class_type->u.constant.value.str.val, class_type->u.constant.value.str.len + 1, 1 TSRMLS_CC); cur_arg_info->class_name = class_type->u.constant.value.str.val; cur_arg_info->class_name_len = class_type->u.constant.value.str.len; if (op == ZEND_RECV_INIT) { @@ -2749,7 +2751,7 @@ void zend_do_begin_catch(znode *try_token, znode *class_name, znode *catch_var, opline->op1.constant = zend_add_class_name_literal(CG(active_op_array), &catch_class.u.constant TSRMLS_CC); opline->op2_type = IS_CV; opline->op2.var = lookup_cv(CG(active_op_array), catch_var->u.constant.value.str.val, catch_var->u.constant.value.str.len, 0 TSRMLS_CC); - catch_var->u.constant.value.str.val = CG(active_op_array)->vars[opline->op2.var].name; + Z_STRVAL(catch_var->u.constant) = (char*)CG(active_op_array)->vars[opline->op2.var].name; opline->result.num = 0; /* 1 means it's the last catch in the block */ try_token->u.op.opline_num = catch_op_number; @@ -2964,7 +2966,7 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c } if (fe->common.arg_info[i].class_name && strcasecmp(fe->common.arg_info[i].class_name, proto->common.arg_info[i].class_name)!=0) { - char *colon; + const char *colon; if (fe->common.type != ZEND_USER_FUNCTION) { return 0; @@ -3935,7 +3937,7 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ free(resulting_table); } -static zend_class_entry* find_first_definition(zend_class_entry *ce, size_t current_trait, char* prop_name, int prop_name_length, ulong prop_hash, zend_class_entry *coliding_ce) /* {{{ */ +static zend_class_entry* find_first_definition(zend_class_entry *ce, size_t current_trait, const char* prop_name, int prop_name_length, ulong prop_hash, zend_class_entry *coliding_ce) /* {{{ */ { size_t i; zend_property_info *coliding_prop; @@ -3955,10 +3957,10 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { zend_property_info *property_info; zend_property_info *coliding_prop; zval compare_result; - char* prop_name; + const char* prop_name; int prop_name_length; ulong prop_hash; - char* class_name_unused; + const char* class_name_unused; zend_bool prop_found; zend_bool not_compatible; zval* prop_value; @@ -4890,7 +4892,7 @@ static int zend_strnlen(const char* s, int maxlen) /* {{{ */ } /* }}} */ -ZEND_API int zend_unmangle_property_name(char *mangled_property, int len, char **class_name, char **prop_name) /* {{{ */ +ZEND_API int zend_unmangle_property_name(const char *mangled_property, int len, const char **class_name, const char **prop_name) /* {{{ */ { int class_name_len; @@ -4965,7 +4967,7 @@ void zend_do_declare_property(const znode *var_name, const znode *value, zend_ui void zend_do_declare_class_constant(znode *var_name, const znode *value TSRMLS_DC) /* {{{ */ { zval *property; - char *cname = NULL; + const char *cname = NULL; int result; if(Z_TYPE(value->u.constant) == IS_CONSTANT_ARRAY) { @@ -6047,7 +6049,7 @@ void zend_do_declare_stmt(znode *var, znode *val TSRMLS_DC) /* {{{ */ } if (CG(multibyte)) { - zend_encoding *new_encoding, *old_encoding; + const zend_encoding *new_encoding, *old_encoding; zend_encoding_filter old_input_filter; CG(encoding_declared) = 1; @@ -6464,7 +6466,7 @@ int zend_get_class_fetch_type(const char *class_name, uint class_name_len) /* {{ } /* }}} */ -ZEND_API char* zend_get_compiled_variable_name(const zend_op_array *op_array, zend_uint var, int* name_len) /* {{{ */ +ZEND_API const char* zend_get_compiled_variable_name(const zend_op_array *op_array, zend_uint var, int* name_len) /* {{{ */ { if (name_len) { *name_len = op_array->vars[var].name_len; @@ -6595,7 +6597,7 @@ void zend_do_use(znode *ns_name, znode *new_name, int is_global TSRMLS_DC) /* {{ if (new_name) { name = &new_name->u.constant; } else { - char *p; + const char *p; /* The form "use A\B" is eqivalent to "use A\B as B". So we extract the last part of compound name to use as a new_name */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index a3802e469d197..1266a1c477067 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -209,11 +209,11 @@ char *zend_visibility_string(zend_uint fn_flags); typedef struct _zend_property_info { zend_uint flags; - char *name; + const char *name; int name_length; ulong h; int offset; - char *doc_comment; + const char *doc_comment; int doc_comment_len; zend_class_entry *ce; } zend_property_info; @@ -244,7 +244,7 @@ typedef struct _zend_internal_function_info { } zend_internal_function_info; typedef struct _zend_compiled_variable { - char *name; + const char *name; int name_len; ulong hash_value; } zend_compiled_variable; @@ -252,7 +252,7 @@ typedef struct _zend_compiled_variable { struct _zend_op_array { /* Common elements */ zend_uchar type; - char *function_name; + const char *function_name; zend_class_entry *scope; zend_uint fn_flags; union _zend_function *prototype; @@ -282,10 +282,10 @@ struct _zend_op_array { zend_uint this_var; - char *filename; + const char *filename; zend_uint line_start; zend_uint line_end; - char *doc_comment; + const char *doc_comment; zend_uint doc_comment_len; zend_uint early_binding; /* the linked list of delayed declarations */ @@ -305,7 +305,7 @@ struct _zend_op_array { typedef struct _zend_internal_function { /* Common elements */ zend_uchar type; - char * function_name; + const char * function_name; zend_class_entry *scope; zend_uint fn_flags; union _zend_function *prototype; @@ -325,7 +325,7 @@ typedef union _zend_function { struct { zend_uchar type; /* never used */ - char *function_name; + const char *function_name; zend_class_entry *scope; zend_uint fn_flags; union _zend_function *prototype; @@ -415,7 +415,7 @@ ZEND_API size_t zend_get_scanned_file_offset(TSRMLS_D); void zend_resolve_non_class_name(znode *element_name, zend_bool check_namespace TSRMLS_DC); void zend_resolve_class_name(znode *class_name, ulong fetch_type, int check_ns_name TSRMLS_DC); -ZEND_API char* zend_get_compiled_variable_name(const zend_op_array *op_array, zend_uint var, int* name_len); +ZEND_API const char* zend_get_compiled_variable_name(const zend_op_array *op_array, zend_uint var, int* name_len); #ifdef ZTS const char *zend_get_zendtext(TSRMLS_D); @@ -650,7 +650,7 @@ ZEND_API void destroy_zend_class(zend_class_entry **pce); void zend_class_add_ref(zend_class_entry **ce); ZEND_API void zend_mangle_property_name(char **dest, int *dest_length, const char *src1, int src1_length, const char *src2, int src2_length, int internal); -ZEND_API int zend_unmangle_property_name(char *mangled_property, int mangled_property_len, char **class_name, char **prop_name); +ZEND_API int zend_unmangle_property_name(const char *mangled_property, int mangled_property_len, const char **class_name, const char **prop_name); #define ZEND_FUNCTION_DTOR (void (*)(void *)) zend_function_dtor #define ZEND_CLASS_DTOR (void (*)(void *)) destroy_zend_class @@ -670,9 +670,9 @@ ZEND_API char *zend_make_compiled_string_description(const char *name TSRMLS_DC) ZEND_API void zend_initialize_class_data(zend_class_entry *ce, zend_bool nullify_handlers TSRMLS_DC); int zend_get_class_fetch_type(const char *class_name, uint class_name_len); -typedef zend_bool (*zend_auto_global_callback)(char *name, uint name_len TSRMLS_DC); +typedef zend_bool (*zend_auto_global_callback)(const char *name, uint name_len TSRMLS_DC); typedef struct _zend_auto_global { - char *name; + const char *name; uint name_len; zend_auto_global_callback auto_global_callback; zend_bool jit; diff --git a/Zend/zend_constants.c b/Zend/zend_constants.c index 58cc495ebbf8b..2e8b1c729f9da 100644 --- a/Zend/zend_constants.c +++ b/Zend/zend_constants.c @@ -233,7 +233,8 @@ static int zend_get_halt_offset_constant(const char *name, uint name_len, zend_c return 0; } else if (name_len == sizeof("__COMPILER_HALT_OFFSET__")-1 && !memcmp(name, "__COMPILER_HALT_OFFSET__", sizeof("__COMPILER_HALT_OFFSET__")-1)) { - char *cfilename, *haltname; + const char *cfilename; + char *haltname; int len, clen; cfilename = zend_get_executed_filename(TSRMLS_C); @@ -462,7 +463,7 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC) /* keep in mind that c->name_len already contains the '\0' */ lowercase_name = estrndup(c->name, c->name_len-1); zend_str_tolower(lowercase_name, c->name_len-1); - lowercase_name = zend_new_interned_string(lowercase_name, c->name_len, 1 TSRMLS_CC); + lowercase_name = (char*)zend_new_interned_string(lowercase_name, c->name_len, 1 TSRMLS_CC); name = lowercase_name; chash = IS_INTERNED(lowercase_name) ? INTERNED_HASH(lowercase_name) : 0; } else { @@ -470,7 +471,7 @@ ZEND_API int zend_register_constant(zend_constant *c TSRMLS_DC) if(slash) { lowercase_name = estrndup(c->name, c->name_len-1); zend_str_tolower(lowercase_name, slash-c->name); - lowercase_name = zend_new_interned_string(lowercase_name, c->name_len, 1 TSRMLS_CC); + lowercase_name = (char*)zend_new_interned_string(lowercase_name, c->name_len, 1 TSRMLS_CC); name = lowercase_name; chash = IS_INTERNED(lowercase_name) ? INTERNED_HASH(lowercase_name) : 0; diff --git a/Zend/zend_exceptions.c b/Zend/zend_exceptions.c index 2259a9cd990a2..9545570b75422 100644 --- a/Zend/zend_exceptions.c +++ b/Zend/zend_exceptions.c @@ -430,7 +430,7 @@ static int _build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, z TRACE_APPEND_STR("Array, "); break; case IS_OBJECT: { - char *class_name; + const char *class_name; zend_uint class_name_len; int dup; @@ -440,7 +440,7 @@ static int _build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, z TRACE_APPEND_STRL(class_name, class_name_len); if(!dup) { - efree(class_name); + efree((char*)class_name); } TRACE_APPEND_STR("), "); diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 2fc9f119fe69c..20d21402edde0 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -574,10 +574,10 @@ ZEND_API char * zend_verify_arg_class_kind(const zend_arg_info *cur_arg_info, ul } } -ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, char *given_kind TSRMLS_DC) +ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, const char *given_kind TSRMLS_DC) { zend_execute_data *ptr = EG(current_execute_data)->prev_execute_data; - char *fname = zf->common.function_name; + const char *fname = zf->common.function_name; char *fsep; const char *fclass; diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 95c239ae0479f..a050d0237710b 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -75,7 +75,7 @@ ZEND_API int zend_eval_string_ex(char *str, zval *retval_ptr, char *string_name, ZEND_API int zend_eval_stringl_ex(char *str, int str_len, zval *retval_ptr, char *string_name, int handle_exceptions TSRMLS_DC); ZEND_API char * zend_verify_arg_class_kind(const zend_arg_info *cur_arg_info, ulong fetch_type, const char **class_name, zend_class_entry **pce TSRMLS_DC); -ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, char *given_kind TSRMLS_DC); +ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, const char *given_kind TSRMLS_DC); static zend_always_inline void i_zval_ptr_dtor(zval *zval_ptr ZEND_FILE_LINE_DC) { @@ -377,9 +377,9 @@ void execute_new_code(TSRMLS_D); /* services */ -ZEND_API char *get_active_class_name(char **space TSRMLS_DC); -ZEND_API char *get_active_function_name(TSRMLS_D); -ZEND_API char *zend_get_executed_filename(TSRMLS_D); +ZEND_API const char *get_active_class_name(const char **space TSRMLS_DC); +ZEND_API const char *get_active_function_name(TSRMLS_D); +ZEND_API const char *zend_get_executed_filename(TSRMLS_D); ZEND_API uint zend_get_executed_lineno(TSRMLS_D); ZEND_API zend_bool zend_is_executing(TSRMLS_D); diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 9d4cc799a234a..5ae15f40e0a9b 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -341,7 +341,7 @@ void shutdown_executor(TSRMLS_D) /* {{{ */ /* }}} */ /* return class name and "::" or "". */ -ZEND_API char *get_active_class_name(char **space TSRMLS_DC) /* {{{ */ +ZEND_API const char *get_active_class_name(const char **space TSRMLS_DC) /* {{{ */ { if (!zend_is_executing(TSRMLS_C)) { if (space) { @@ -369,14 +369,14 @@ ZEND_API char *get_active_class_name(char **space TSRMLS_DC) /* {{{ */ } /* }}} */ -ZEND_API char *get_active_function_name(TSRMLS_D) /* {{{ */ +ZEND_API const char *get_active_function_name(TSRMLS_D) /* {{{ */ { if (!zend_is_executing(TSRMLS_C)) { return NULL; } switch (EG(current_execute_data)->function_state.function->type) { case ZEND_USER_FUNCTION: { - char *function_name = ((zend_op_array *) EG(current_execute_data)->function_state.function)->function_name; + const char *function_name = ((zend_op_array *) EG(current_execute_data)->function_state.function)->function_name; if (function_name) { return function_name; @@ -394,7 +394,7 @@ ZEND_API char *get_active_function_name(TSRMLS_D) /* {{{ */ } /* }}} */ -ZEND_API char *zend_get_executed_filename(TSRMLS_D) /* {{{ */ +ZEND_API const char *zend_get_executed_filename(TSRMLS_D) /* {{{ */ { if (EG(active_op_array)) { return EG(active_op_array)->filename; @@ -515,7 +515,7 @@ ZEND_API int zval_update_constant_ex(zval **pp, void *arg, zend_class_entry *sco if (!zend_get_constant_ex(p->value.str.val, p->value.str.len, &const_value, scope, Z_REAL_TYPE_P(p) TSRMLS_CC)) { char *actual = Z_STRVAL_P(p); - if ((colon = zend_memrchr(Z_STRVAL_P(p), ':', Z_STRLEN_P(p)))) { + if ((colon = (char*)zend_memrchr(Z_STRVAL_P(p), ':', Z_STRLEN_P(p)))) { zend_error(E_ERROR, "Undefined class constant '%s'", Z_STRVAL_P(p)); Z_STRLEN_P(p) -= ((colon - Z_STRVAL_P(p)) + 1); if (inline_change) { @@ -615,8 +615,9 @@ ZEND_API int zval_update_constant_ex(zval **pp, void *arg, zend_class_entry *sco continue; } if (!zend_get_constant_ex(str_index, str_index_len - 3, &const_value, scope, str_index[str_index_len - 2] TSRMLS_CC)) { - char *actual, *save = str_index; - if ((colon = zend_memrchr(str_index, ':', str_index_len - 3))) { + char *actual; + const char *save = str_index; + if ((colon = (char*)zend_memrchr(str_index, ':', str_index_len - 3))) { zend_error(E_ERROR, "Undefined class constant '%s'", str_index); str_index_len -= ((colon - str_index) + 1); str_index = colon; @@ -1003,7 +1004,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS } if (EX(function_state).function->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY) { - efree(EX(function_state).function->common.function_name); + efree((char*)EX(function_state).function->common.function_name); } efree(EX(function_state).function); @@ -1686,7 +1687,7 @@ ZEND_API void zend_reset_all_cv(HashTable *symbol_table TSRMLS_DC) /* {{{ */ } /* }}} */ -ZEND_API void zend_delete_variable(zend_execute_data *ex, HashTable *ht, char *name, int name_len, ulong hash_value TSRMLS_DC) /* {{{ */ +ZEND_API void zend_delete_variable(zend_execute_data *ex, HashTable *ht, const char *name, int name_len, ulong hash_value TSRMLS_DC) /* {{{ */ { if (zend_hash_quick_del(ht, name, name_len, hash_value) == SUCCESS) { name_len--; @@ -1709,7 +1710,7 @@ ZEND_API void zend_delete_variable(zend_execute_data *ex, HashTable *ht, char *n } /* }}} */ -ZEND_API int zend_delete_global_variable_ex(char *name, int name_len, ulong hash_value TSRMLS_DC) /* {{{ */ +ZEND_API int zend_delete_global_variable_ex(const char *name, int name_len, ulong hash_value TSRMLS_DC) /* {{{ */ { zend_execute_data *ex; @@ -1734,7 +1735,7 @@ ZEND_API int zend_delete_global_variable_ex(char *name, int name_len, ulong hash } /* }}} */ -ZEND_API int zend_delete_global_variable(char *name, int name_len TSRMLS_DC) /* {{{ */ +ZEND_API int zend_delete_global_variable(const char *name, int name_len TSRMLS_DC) /* {{{ */ { return zend_delete_global_variable_ex(name, name_len, zend_inline_hash_func(name, name_len + 1) TSRMLS_CC); } diff --git a/Zend/zend_gc.h b/Zend/zend_gc.h index 6a0b7aa7f3850..8ed037c7dd03d 100644 --- a/Zend/zend_gc.h +++ b/Zend/zend_gc.h @@ -84,7 +84,7 @@ typedef struct _gc_root_buffer { zend_object_handle handle; /* must be 0 for zval */ union { zval *pz; - zend_object_handlers *handlers; + const zend_object_handlers *handlers; } u; } gc_root_buffer; diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index 3aca2e7b928f0..ad3f46a08d29f 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -248,14 +248,14 @@ ZEND_API int _zend_hash_add_or_update(HashTable *ht, const char *arKey, uint nKe if (!p) { return FAILURE; } - p->arKey = (char*)arKey; + p->arKey = arKey; } else { p = (Bucket *) pemalloc(sizeof(Bucket) + nKeyLength, ht->persistent); if (!p) { return FAILURE; } - p->arKey = (char*)(p + 1); - memcpy(p->arKey, arKey, nKeyLength); + p->arKey = (const char*)(p + 1); + memcpy((char*)p->arKey, arKey, nKeyLength); } p->nKeyLength = nKeyLength; INIT_DATA(ht, p, pData, nDataSize); @@ -325,14 +325,14 @@ ZEND_API int _zend_hash_quick_add_or_update(HashTable *ht, const char *arKey, ui if (!p) { return FAILURE; } - p->arKey = (char*)arKey; + p->arKey = arKey; } else { p = (Bucket *) pemalloc(sizeof(Bucket) + nKeyLength, ht->persistent); if (!p) { return FAILURE; } - p->arKey = (char*)(p + 1); - memcpy(p->arKey, arKey, nKeyLength); + p->arKey = (const char*)(p + 1); + memcpy((char*)p->arKey, arKey, nKeyLength); } p->nKeyLength = nKeyLength; @@ -1157,7 +1157,7 @@ ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, char **str_index, if (duplicate) { *str_index = estrndup(p->arKey, p->nKeyLength - 1); } else { - *str_index = p->arKey; + *str_index = (char*)p->arKey; } if (str_length) { *str_length = p->nKeyLength; @@ -1402,8 +1402,8 @@ ZEND_API int zend_hash_update_current_key_ex(HashTable *ht, int key_type, const if (IS_INTERNED(str_index)) { p->arKey = str_index; } else { - p->arKey = (char*)(p+1); - memcpy(p->arKey, str_index, str_length); + p->arKey = (const char*)(p+1); + memcpy((char*)p->arKey, str_index, str_length); } } diff --git a/Zend/zend_hash.h b/Zend/zend_hash.h index 3d13c3322b5c5..8aa1286e26a23 100644 --- a/Zend/zend_hash.h +++ b/Zend/zend_hash.h @@ -60,7 +60,7 @@ typedef struct bucket { struct bucket *pListLast; struct bucket *pNext; struct bucket *pLast; - char *arKey; + const char *arKey; } Bucket; typedef struct _hashtable { @@ -83,7 +83,7 @@ typedef struct _hashtable { typedef struct _zend_hash_key { - char *arKey; + const char *arKey; uint nKeyLength; ulong h; } zend_hash_key; diff --git a/Zend/zend_highlight.c b/Zend/zend_highlight.c index d829ed87890ec..5c2f8be31bcb3 100644 --- a/Zend/zend_highlight.c +++ b/Zend/zend_highlight.c @@ -56,12 +56,12 @@ ZEND_API void zend_html_putc(char c) ZEND_API void zend_html_puts(const char *s, uint len TSRMLS_DC) { - const char *ptr=s, *end=s+len; - char *filtered; - int filtered_len; + const unsigned char *ptr = (const unsigned char*)s, *end = ptr + len; + unsigned char *filtered; + size_t filtered_len; if (LANG_SCNG(output_filter)) { - LANG_SCNG(output_filter)(&filtered, &filtered_len, s, len TSRMLS_CC); + LANG_SCNG(output_filter)(&filtered, &filtered_len, ptr, len TSRMLS_CC); ptr = filtered; end = filtered + filtered_len; } @@ -115,7 +115,7 @@ ZEND_API void zend_highlight(zend_syntax_highlighter_ini *syntax_highlighter_ini next_color = syntax_highlighter_ini->highlight_string; break; case T_WHITESPACE: - zend_html_puts(LANG_SCNG(yy_text), LANG_SCNG(yy_leng) TSRMLS_CC); /* no color needed */ + zend_html_puts((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng) TSRMLS_CC); /* no color needed */ token.type = 0; continue; break; @@ -138,7 +138,7 @@ ZEND_API void zend_highlight(zend_syntax_highlighter_ini *syntax_highlighter_ini } } - zend_html_puts(LANG_SCNG(yy_text), LANG_SCNG(yy_leng) TSRMLS_CC); + zend_html_puts((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng) TSRMLS_CC); if (token.type == IS_STRING) { switch (token_type) { @@ -187,11 +187,11 @@ ZEND_API void zend_strip(TSRMLS_D) continue; case T_END_HEREDOC: - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); efree(token.value.str.val); /* read the following character, either newline or ; */ if (lex_scan(&token TSRMLS_CC) != T_WHITESPACE) { - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); } zend_write("\n", sizeof("\n") - 1); prev_space = 1; @@ -199,7 +199,7 @@ ZEND_API void zend_strip(TSRMLS_D) continue; default: - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); break; } diff --git a/Zend/zend_indent.c b/Zend/zend_indent.c index b8432a0be3699..03c572b9a3d8b 100644 --- a/Zend/zend_indent.c +++ b/Zend/zend_indent.c @@ -64,7 +64,7 @@ ZEND_API void zend_indent() while ((token_type=lex_scan(&token TSRMLS_CC))) { switch (token_type) { case T_INLINE_HTML: - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); break; case T_WHITESPACE: { token.type = 0; @@ -118,16 +118,16 @@ ZEND_API void zend_indent() } else { handle_whitespace(emit_whitespace); } - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); break; } } else { handle_whitespace(emit_whitespace); if (in_string) { - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); /* a part of a string */ } else { - zend_write(LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); + zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); } } break; diff --git a/Zend/zend_interfaces.c b/Zend/zend_interfaces.c index d2828b087f8c5..d504cab6dcd69 100755 --- a/Zend/zend_interfaces.c +++ b/Zend/zend_interfaces.c @@ -31,7 +31,7 @@ ZEND_API zend_class_entry *zend_ce_serializable; /* {{{ zend_call_method Only returns the returned zval if retval_ptr != NULL */ -ZEND_API zval* zend_call_method(zval **object_pp, zend_class_entry *obj_ce, zend_function **fn_proxy, char *function_name, int function_name_len, zval **retval_ptr_ptr, int param_count, zval* arg1, zval* arg2 TSRMLS_DC) +ZEND_API zval* zend_call_method(zval **object_pp, zend_class_entry *obj_ce, zend_function **fn_proxy, const char *function_name, int function_name_len, zval **retval_ptr_ptr, int param_count, zval* arg1, zval* arg2 TSRMLS_DC) { int result; zend_fcall_info fci; diff --git a/Zend/zend_interfaces.h b/Zend/zend_interfaces.h index 6c14c8920ccc2..2cb3b7f152e8d 100755 --- a/Zend/zend_interfaces.h +++ b/Zend/zend_interfaces.h @@ -38,7 +38,7 @@ typedef struct _zend_user_iterator { zval *value; } zend_user_iterator; -ZEND_API zval* zend_call_method(zval **object_pp, zend_class_entry *obj_ce, zend_function **fn_proxy, char *function_name, int function_name_len, zval **retval_ptr_ptr, int param_count, zval* arg1, zval* arg2 TSRMLS_DC); +ZEND_API zval* zend_call_method(zval **object_pp, zend_class_entry *obj_ce, zend_function **fn_proxy, const char *function_name, int function_name_len, zval **retval_ptr_ptr, int param_count, zval* arg1, zval* arg2 TSRMLS_DC); #define zend_call_method_with_0_params(obj, obj_ce, fn_proxy, function_name, retval) \ zend_call_method(obj, obj_ce, fn_proxy, function_name, sizeof(function_name)-1, retval, 0, NULL, NULL TSRMLS_CC) diff --git a/Zend/zend_iterators.c b/Zend/zend_iterators.c index c8827aecae437..fe707555581ca 100755 --- a/Zend/zend_iterators.c +++ b/Zend/zend_iterators.c @@ -51,9 +51,7 @@ static zend_object_handlers iterator_object_handlers = { ZEND_API void zend_register_iterator_wrapper(TSRMLS_D) { INIT_CLASS_ENTRY(zend_iterator_class_entry, "__iterator_wrapper", NULL); - if (!IS_INTERNED(zend_iterator_class_entry.name)) { - free(zend_iterator_class_entry.name); - } + str_free(zend_iterator_class_entry.name); zend_iterator_class_entry.name = "__iterator_wrapper"; } diff --git a/Zend/zend_language_scanner.h b/Zend/zend_language_scanner.h index 02a82efc8fad6..447e8dc7f65ce 100644 --- a/Zend/zend_language_scanner.h +++ b/Zend/zend_language_scanner.h @@ -56,7 +56,7 @@ int zend_compare_file_handles(zend_file_handle *fh1, zend_file_handle *fh2); ZEND_API void zend_save_lexical_state(zend_lex_state *lex_state TSRMLS_DC); ZEND_API void zend_restore_lexical_state(zend_lex_state *lex_state TSRMLS_DC); ZEND_API int zend_prepare_string_for_scanning(zval *str, char *filename TSRMLS_DC); -ZEND_API void zend_multibyte_yyinput_again(zend_encoding_filter old_input_filter, zend_encoding *old_encoding TSRMLS_DC); +ZEND_API void zend_multibyte_yyinput_again(zend_encoding_filter old_input_filter, const zend_encoding *old_encoding TSRMLS_DC); ZEND_API int zend_multibyte_set_filter(const zend_encoding *onetime_encoding TSRMLS_DC); END_EXTERN_C() diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 827b7bf3d7281..1dd509e090b2a 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -469,7 +469,8 @@ ZEND_API int zend_multibyte_set_filter(const zend_encoding *onetime_encoding TSR ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC) { - char *file_path = NULL, *buf; + const char *file_path = NULL; + char *buf; size_t size, offset = 0; /* The shebang line was read, get the current position to obtain the buffer start */ @@ -497,7 +498,7 @@ ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC) if (size != -1) { if (CG(multibyte)) { - SCNG(script_org) = buf; + SCNG(script_org) = (unsigned char*)buf; SCNG(script_org_size) = size; SCNG(script_filtered) = NULL; @@ -508,7 +509,7 @@ ZEND_API int open_file_for_scanning(zend_file_handle *file_handle TSRMLS_DC) zend_error_noreturn(E_COMPILE_ERROR, "Could not convert the script from the detected " "encoding \"%s\" to a compatible encoding", zend_multibyte_get_encoding_name(LANG_SCNG(script_encoding))); } - buf = SCNG(script_filtered); + buf = (char*)SCNG(script_filtered); size = SCNG(script_filtered_size); } } @@ -663,7 +664,7 @@ ZEND_API int zend_prepare_string_for_scanning(zval *str, char *filename TSRMLS_D size = str->value.str.len; if (CG(multibyte)) { - SCNG(script_org) = buf; + SCNG(script_org) = (unsigned char*)buf; SCNG(script_org_size) = size; SCNG(script_filtered) = NULL; @@ -674,7 +675,7 @@ ZEND_API int zend_prepare_string_for_scanning(zval *str, char *filename TSRMLS_D zend_error_noreturn(E_COMPILE_ERROR, "Could not convert the script from the detected " "encoding \"%s\" to a compatible encoding", zend_multibyte_get_encoding_name(LANG_SCNG(script_encoding))); } - buf = SCNG(script_filtered); + buf = (char*)SCNG(script_filtered); size = SCNG(script_filtered_size); } } @@ -820,7 +821,7 @@ int highlight_string(zval *str, zend_syntax_highlighter_ini *syntax_highlighter_ return SUCCESS; } -ZEND_API void zend_multibyte_yyinput_again(zend_encoding_filter old_input_filter, zend_encoding *old_encoding TSRMLS_DC) +ZEND_API void zend_multibyte_yyinput_again(zend_encoding_filter old_input_filter, const zend_encoding *old_encoding TSRMLS_DC) { size_t length; unsigned char *new_yy_start; @@ -1552,7 +1553,7 @@ NEWLINE ("\r"|"\n"|"\r\n") } "__CLASS__" { - char *class_name = NULL; + const char *class_name = NULL; if (CG(active_class_entry) && (ZEND_ACC_TRAIT == @@ -1579,7 +1580,7 @@ NEWLINE ("\r"|"\n"|"\r\n") } "__TRAIT__" { - char *trait_name = NULL; + const char *trait_name = NULL; if (CG(active_class_entry) && (ZEND_ACC_TRAIT == @@ -1599,7 +1600,7 @@ NEWLINE ("\r"|"\n"|"\r\n") } "__FUNCTION__" { - char *func_name = NULL; + const char *func_name = NULL; if (CG(active_op_array)) { func_name = CG(active_op_array)->function_name; @@ -1615,8 +1616,8 @@ NEWLINE ("\r"|"\n"|"\r\n") } "__METHOD__" { - char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; - char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; + const char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; + const char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; size_t len = 0; if (class_name) { @@ -1691,7 +1692,7 @@ NEWLINE ("\r"|"\n"|"\r\n") } "" { - YYCTYPE *bracket = zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); + YYCTYPE *bracket = (YYCTYPE*)zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); if (bracket != SCNG(yy_text)) { /* Handle previously scanned HTML, as possible \n"); + php_info_print("

"); php_info_print("PHP Credits"); php_info_print("

\n"); + php_info_print("
\n"); + php_print_credits(PHP_CREDITS_ALL, TSRMLS_C); + php_info_print("
\n"); } zend_ini_sort_entries(TSRMLS_C); @@ -1191,77 +1198,6 @@ PHP_FUNCTION(phpcredits) } /* }}} */ -/* {{{ php_logo_guid - */ -PHPAPI char *php_logo_guid(void) -{ - char *logo_guid; - - time_t the_time; - struct tm *ta, tmbuf; - - the_time = time(NULL); - ta = php_localtime_r(&the_time, &tmbuf); - - if (ta && (ta->tm_mon==3) && (ta->tm_mday==1)) { - logo_guid = PHP_EGG_LOGO_GUID; - } else { - logo_guid = PHP_LOGO_GUID; - } - - return estrdup(logo_guid); - -} -/* }}} */ - -/* {{{ proto string php_logo_guid(void) - Return the special ID used to request the PHP logo in phpinfo screens*/ -PHP_FUNCTION(php_logo_guid) -{ - if (zend_parse_parameters_none() == FAILURE) { - return; - } - - RETURN_STRING(php_logo_guid(), 0); -} -/* }}} */ - -/* {{{ proto string php_real_logo_guid(void) - Return the special ID used to request the PHP logo in phpinfo screens*/ -PHP_FUNCTION(php_real_logo_guid) -{ - if (zend_parse_parameters_none() == FAILURE) { - return; - } - - RETURN_STRINGL(PHP_LOGO_GUID, sizeof(PHP_LOGO_GUID)-1, 1); -} -/* }}} */ - -/* {{{ proto string php_egg_logo_guid(void) - Return the special ID used to request the PHP logo in phpinfo screens*/ -PHP_FUNCTION(php_egg_logo_guid) -{ - if (zend_parse_parameters_none() == FAILURE) { - return; - } - - RETURN_STRINGL(PHP_EGG_LOGO_GUID, sizeof(PHP_EGG_LOGO_GUID)-1, 1); -} -/* }}} */ - -/* {{{ proto string zend_logo_guid(void) - Return the special ID used to request the Zend logo in phpinfo screens*/ -PHP_FUNCTION(zend_logo_guid) -{ - if (zend_parse_parameters_none() == FAILURE) { - return; - } - - RETURN_STRINGL(ZEND_LOGO_GUID, sizeof(ZEND_LOGO_GUID)-1, 1); -} -/* }}} */ - /* {{{ proto string php_sapi_name(void) Return the current SAPI module name */ PHP_FUNCTION(php_sapi_name) diff --git a/ext/standard/info.h b/ext/standard/info.h index fadde75eb6a89..98185936649c8 100644 --- a/ext/standard/info.h +++ b/ext/standard/info.h @@ -50,19 +50,14 @@ #endif /* HAVE_CREDITS_DEFS */ -#define PHP_LOGO_GUID "PHPE9568F34-D428-11d2-A769-00AA001ACF42" -#define PHP_EGG_LOGO_GUID "PHPE9568F36-D428-11d2-A769-00AA001ACF42" -#define ZEND_LOGO_GUID "PHPE9568F35-D428-11d2-A769-00AA001ACF42" -#define PHP_CREDITS_GUID "PHPB8B5F2A0-3C92-11d3-A3A9-4C7B08C10000" +#define PHP_LOGO_DATA_URI "data:image/gif;base64,R0lGODlheABDAOZqAH+CuDk3RyglKszN4qGky9PV57K01ENCWIOGuYKDs1JScpCSwsLE3qqs0ExLY1tcg93e7Ds4PG5xpWptnWFjjXV5sXt+teXm8JmcxoyNwbm62Wtrkk5Oa3F0qXp6o4iLvXJ0o3RzmI6QwVpbfuLj73t9raSl0G1wonJ2rJWWyLu92XR4roWIu5KVw9jZ6pKSxGRmkmtun6WozpSWxS4rL1NRaLO012xqjFxbdoqNv2ZolmhqmpyfyDEuOa6w05yczVVWeJ6hypaZxYGCr2dplz89ULy+2l5giZiZyIyOv4mKuldYfLa319XX6CIeIGxvns7Q5L/A3Hd7tHZ4p19efZmZzG5vmHN3riIeH////5COj1lWV8fGx+7u9dXU1fb2+oKAgayqq3Ryc/Hw8Z6cnePi40tISbm4uWdkZYmJtgD/AEdGX9/g7ZuczGlrnG9zp4yMuri52bi615qbzKeqz9vc65qcyWZkhGhniaeo0m5woIuLucbH4MfJ4WlsnJeYyyH5BAEAAGoALAAAAAB4AEMAAAf/gGqCg4SFhoeIiYqLjI2Oj5CRkpOUlZaXlm0/bXOYnp+gP3l5Nj4acUwaGkwGPj4NMgRBPBhCLQtJIjkfGTkiLymgwqENGgx9TQVQUAN9fAxRUSpyrK90sbNCMy26HwgAFhYVVyglFgkZwcPrjCZxfC5sbBAQdS7JA9QysyIf/iwAEQgEQLDgN4LhpKxA8UbCCT87nkwZkoSdRTVBbAxgQ+KCRxIk8jUQskCKyZMoU6pceXJcBwkTduiAQeEIBStDRFzEFIQJFI4eL7gwQqcFy6NIk6K88iYGjCNHHoxYcsSDzp2Qfmh0AYEjBCMEWCgdSzbplRM6HiwBokDBiCkz/7AuMqGhQBMXdQoYSFK2r1+kHWAsUcCBgwM8CeQayhNlAJQCA3zk+LtyAYbLmDF8oJz0DQUFDtasUeBBsZo8Rvj0GcBkBueVH7JwmU2bS5fXSt0sWXPggIMQO91FYcCgAQLcKzFwwcK8uZnbyJN22F2kyJrSw374kGNEBQ8L0VeqINO8uZgC4ZVeeXAgQAAOcECZMMBEDgEA6VcWEFOeORkV+Sn1hgLu9XAHJnPQ4YMBMhwXoEpdmNEfFlwQ8KBSMazRQw8H7FHJDzI00EBJF6YEQBYTYpHFZiUm9UAAGwInSRsE7ONgiycpN6EZX+ColB9F0EADFZHYEQQBM4CH1P8HmTXZJItHqRDGhGJc0CSJLDHp5Jb4jYWCAzQIUMMjSGAQBJRHffBFFmy26eabWXRRQANdolQAGBOSAWebFwxg4UkL7Ckom10M0IBSQAgggAONzCAEBmIpRcByKVZqBhhcfAEgSl1sUWmKNGyhRRldkGjAlJ9OuAUYXnRxKFIjCOAEo4psI8SNSY2X6qdbeAFBlyfu+ikYY2AgxQB4CqtqGQMkNYITTuCQSAoitIBmUhDwp2yKYUBgEgZebJsiGrdd4Km45dHgRbNIrQEtdoX84ctkZX0hIbr9eQGglPjm2wCK/TZHQxl/HhWAEwIsYEg/9JIVW8DlbdHjnRAzp8X/BeFWjIUY0B3VgaxjEpICAh/UOdakO8I5xhnaTugFAZ1OyMWbY3CBRopaZIFqxHCWcca5E5aBJUsKQJsGId7gOpau/YnhLUoLNNAFeRNqwQDA/a2IEgYNfBFB1VloUTW7gBrwRbL9hWGAUjTMOsgfACCgZFnZ5rmpiVl83XQWGZfH40oQAN1czoIzd8baKn0wBs53H7UEtAqrIYIFJpNlr8wFpxS4qjpT+XRKMfd3RhY0BG3sSqGXp0XjLHUA7Q2CsJBQXw9POMa1J23eHxpZoN3cfyoFG3QZE9KQxVGpD846S0W4rUY4c5OFcn8R9MjS5f0RjrlK4BafxRmqXnAU/9blAa8UB070IEgFlDFdHhqfp1R72uQ3d7tK/Pa3Rdhjs4QB8dtTCgWgJYgVUKZu2VueSQwAvqD1rTnV04/vmAOGLBQOC4djCQOo1p/7CZCAKbgC+/yCvfJUiCXJY04EOre7+J0khVgIA+lMtxIAeG1C5CLLAJ0gCBQYsC/C6yDujkWp7PWuassLYnm8AMB0HU8/HCxPGBS4kh0KogMoGCFZdES9J6LkAwXwQun6Q4MxfOGCJ0xJ9yb0vfBxDwJinFD1KncUK6phIVpcWhSZQy4V+FEFEOjCGLQwRtENoH7M8SBK8sczsWWvC38EZBfK4EiZUXEl6FPf8zpwhb7sR/9VWghlKMVwrxSJ4QsEeKAKvWinCWKhghcUlSi1QMphia8szaPVB97Qgb5ESGNo+MICToVDF5rEXBOSYSEDdsqhSed1gkiBBN7wQ6UosV/NPJYrrbYSRGKBiRoDgzD78jgnRO55EujlWNbYLxqcYZxSQGZ/uPCqramSOW0MWATOcAFnss15gnjBCSTQSaUwUlxmIMMYBlCnGXbQn8TUH//wZQYZMoCOSSmaE45GiCGc4A1joZj+ZjlLMnBhDIVCU6BIGkpWnkQFXGDp6C4oBpaG0qQoZcAQpQMyQ6TgBCdQJ1JgyIUL0IMeBfgjAfxpEkAe9aiZA9QAnkqPQy6TOV7/MOpRk+pHAux0LAdL2CGSEIMToAAp10wkU30khQU0sTxZwChy3OUEeBkiAWUtaHLuuUK2sqQBDYxYx/JTTmkpogR5ZclB+WhMv0qBAZVsDhjQE6By0moRiDWrBKvGAMeqRHdSvCRlNHpZRpRgAjHoQB6lQNR6etYkeXPZ6aLTgQNAq7SNSABqJaDFtGJhDGv10QIWx0a5+oUIPYCWYSOhhCdMQLNS+N8Wpktd3r3WntSlLhgG+xoFyEoAMprEC0DghxjwFgAFoCo9EHddKaBXvRBwLWWIcDAnRICjlkiAG1D7htW2168nsK1yQfGCKfgBtar9r19RwAFZOaEI+AWF/xL04IYD91fBJTrBGhzcg/CygwUUPrAEzorh8BzhAIoSQA9gpxgWgGAHbnBDDKhZYsr4gQMBCJMAAsBi0wgiCSUgwg5gPAEa1zgpEyBQD4QkJrv6eBApSIAedEAEIbshqP7F8BuOgOMNLbkIeHjBkxfxAinr4Mxn3sFHSXzdHRxBAe2B0YYOcAMPjfkRL0DAFIgAgz77mQh++KhQ8zMBIjwANNVxj6JxEAI735kSIhjCnilA6UpT+gh9rnCg38BpTkvg058GKlCJcGm2iKY3B6hOEQJwABxsIDGPFkYKPlACEFgBKlB5gK53PZUlrAUIbGkLYQpjmNCcujdFUAAVbjgwBDHHWjEpUAICPOCBDWwgLb4GdrDbQmzDcIAKIxiBFaxQgmY/+9yLEEEaEHAVdLv73fCOd7wDAQA7AA==" +#define PHP_EGG_LOGO_DATA_URI "data:image/gif;base64,R0lGODlheABDAOf/ABIZISAeIhwhLA8jRwYlVSUoLyIpNSkoKwkvbR4tRBUwVDMuNysxOx87Yg89gDo3RTI5SgBCkDg6PDY7RyBCcTxBQz9BVD9ETxxPkQ9SoktIYkROVkpNWDJSeilVhkxObEZTZQVevgBfxVZQZRxcn1BUYFNTc1FXWRZht1ZYVQBm0ghlzBhksVVafyNlqSpkn1hcZwBr2EVfhABs0lRdcF5adRJpyWBcaVlgYl5dh15efh5q0gdw3iFsxhBy2Rtxxhhx0Ttsn2BkigB45SxwtDFwq0dslGNoc1pqfRtz6GRmkypzwFZuiQl772psaWlpiiF25Ax94zB10BB+3iV44BR96yN71TJ5vit7zih73GluoDt6tk53nix66QOG+nBwl0l7r3F2cjOAzSKB9guI9SKC8HF1lW90pm93jTCC3SaE6zWC12F8knR6fHV5gzaC5SmH6ESC3y6H9kGGyiqJ8UuDzXx5oWV9v1aA0nl6qWmAnXl6tHJ8tV6AyVGGuS6K/EyHwyKO/D6J5T+K2SGQ9zqL3ziN9jaP6jmP8WaHwYGCsHqIkC6U/C2V9naFv0GS50mS2IGFuYeHnEWU4iyZ/16P2ISIr1iSz4mLiF2SxV+TvImLlmiSsnqPrIeLvzmc/kOa9Uaa74aNtHWRyXiSvk+a6YyNvIGQwo6OsImTnFib3lKd5l2d2kKi/WSd0k2h9zeo/1Gi8ZSUw5GVyn+czE2m/46bsY2ZyHugwUmr/12n8GCn6pieoGWn5Hekzpueq26n25yby1ms/ICk25ejrlGy/56iymav+V2y+2yv7Wex9KaopWG2/1e5/5Wu2H216265/HW3/qus0aavxWe+/66wvYy33YC4+Hi7+bO0uHPB/aq3wa6112vF/4e/9pfA27u31YDF/XnK/5PG77y/25TI/MDBxYbN/qvH7LfH2qPP+47V/57T/cPN2abT9c3M5Jna/77S7LrU57HV+KLg/7zd+tbb3dbb6a7l/sbh99Hi+Lrp++Pm7+Hx/P3//P///yH5BAEKAP8ALAAAAAB4AEMAAAj+AP8JHEiwoMGDCBMqXMiwocOHECNKnEixosWLFoNpDIaxo8ePwaRJ4yaNHDhw5EySFCnNmEtjt2TJMmXKk01PpmbN+sgTZEly7+7de0eUaMqj4FaKfBlzps1IkfZI3cMnzx5Fnnb23MrQGLig/PgJHTvUZEtjNZ9CXcu2bVSpfPicOaOlrpY8ikxx3fvPGLd3YQOHfUdOWkw+jkaNEjVtquPHkCNLnVtXieUcSr7k5YvRK2DB9wrLctSnUi9dxYpRo6atEy/JsGM7pqskh+0WLXLY0csZYrC/QsOGNubplrNkxWq1Wp6rObNu53y5kU2dupbaLUxob5FHVu+Fxsj+kb3HzdTUc/TonWtWrLnqXMWaiQvnC031+7LPKMn+4YOGJ4p8Z1BJRA0ljSeQ1XMOPOt00wx7xYhDjWrinDNOEFzQwgd+HEamnwkahGiCHQL+QyBR4MgSWzjw0CNOM+4xKN868FhjhB/PqIMON844c8spp6zlSSSexIXYUx06pkULGlhggQZfcObVUdK8FRs70NCzDnvNUeNgN+vQ4w4XfvSizDHIQAMNM8LooosyaWqDDTbhhOPNnc9g88www/RIHH5nMOmkBiT2FNJRxuBXjzAMTghLK/IVAyY843TgAhaHIKIpIXDQgUgjhwjySCijllLKKrqssssuqaqaTDL+e57CYQ4WPPDAB7x15BdKxlgp2zi9JBPLOetQkwsssBTTYDPwwMMOBSRYgQghdMhRxrVl0AHHG9xuO0UWghRSyCOlTCJuIZNAoq4qwMh63xkm2LrAExiFNFKV96GzyyOICPNIOfRQs9wnucCjTTf07OMOBREAQQcZZXhRxcTYUmExFVFEkUUWaXTscRqhlDuIGGJA0ssoHGqhwQILWJCrRPZKo+J9z5xpCBnUNtrKJwTjc4426bHTQQQzVHFtFU00AUUXEw8BxRBUDBHFtnAIksYUVpOLzDGpTjLIIJA40mEOD7AcJczGtORrbJ48E8orn8jhhRyv4AMPMrBQAkv+M14ijI/QRHeBLdJdMA3F0jzwAIUPb2iKCBwbTwHHI6PqEoub6c6xYcoWHHCADhEF49LM1UWyCyigEMIIIYY0EY56xeycCzO5NAP0PoDPEDG2XSR9eBeHQ8GDD3CUk4862AgD+cZZwAHHIY/EEssqkGjeIR8aeD7CQ6L/eZ8jlWg6hxVkQFxFi8bunOze4tCDzzgNOFB0E9c2UcUYSRd++BA++JCFPm5wwjLKcQjnZcEHQJjcuB6BKl2oQmwdMoHnNNAQWdyiV/iJRB2yoAY1vOEFVbBWFegBD3HkYjmtaI+X4PG++PmgfnKIobXKEDWnDWF4abgHBwzgBG/AQXL+kANCGg6RBitYAQtrgMQqVgFBDrXgAAGgoEJkcou1xeYWdZjCFKKghiqQQAr4o0N61hG7T+gtF+IQBz7wYQ0FEG0M12IEz0DBM001QlNU8EEa2nEBA7QBG5ATxLeAgMRChGINP0jkD7AghkQ08T4tCEAAapCQWZhCFgi6zyjWIAhr2MIFQ5DaD4bQBUS4Dx7NeJQZYQGdfdDjGQOIQAzo14h5yCMf+ahHPfIhj3ZsQx7QgMMg2jEBAbQBecd4xSOIuIZmkguJWFDkJWiRJA1IslAFmQVOMkmdSFxiDYfQhz/8gYQodMFpwAsFPlzZjJ0xohVoPMc+4OEKAkSACnL+IMQxsnGBC3DgnyXgwAYusIFslGMV1SjmAU6AAzfwIh3YCMUkelEKcj0CXWuI5hzmYA0ryuYBATiAdwqSlvvwQRVYyMI8xumPVKTBaEgrwzHWCI/YMeKdxdBG+9jBBQJkoAqBQAQ2NlECGJSABjCgwVEDygBzeGMTEyiAAUrQTwYUIAzeCIUtiPGNZ+jCVI9Iww/EcAlX+OIWHDoDFLdHkFkQyaORuURKB5GCaoxTD4gog7WaMAZvjJE9rUjWg9JTKQKggAyMaEQ53FDUauAyl/r4RQkY0AZ+HOECASBGNX7BWAEAYBGlYAJBcRAGTGBiG8oQK1kzwQpSbK46JpD+5MuGBFfI3AELQKBCEAxQgHbYwwWNKB+22JEeF7WHldQIEzy8kQAEZOETO5sHDU5Qgm08QxiNgEMhzFGCAlTgHiWYgATycad52KKYJ3gGCATAgA1woJ8GwEQpevCDQQACEHMwqzPuA0Up/sOttX0MH3oAhBn4wAPTOAANNpEFMuyVfuxoETy6cSxJSXgdroglHGbXCnnQwA1HSIcyJhaFQqSjuwzYBgcYcIRywCENkPhFAQBwAmJ+Nh7TIAYaeAsMIPRADHPwwxKuAAhXkOIUpJNMJAMwUvMEeCoDtsEKVjADEhQgAAIggRrIUIXCNYEM7KARPNIHC3Gs48zhkIH+YUEhDIGlgwM3cIMtjlEFKrzhEe1Y8QIka4BFxEINgngGGjy7iGp4Fhe64Fo8DAAATkyhB1iYQxBcsAQiXGELW8iENcwjmTNIkl7/ePJUPLEEKatABTsAAgUSgAE43OxavVMDO85h5mZANxfJPbM3GoCANLyiGMyAxDQ4AINNWEMYhEDEIdTxiwsU4AhouIAAqoEINWTBGRAAAAC2MWgGJEOZj7hEAgDAhTSgAAtXeIELWMBuEpCACJl2RqIiY4EoCsSkgOjBCmIQgx34GwiF4CAhhHutRqwjjetABnRhQawzZ2IAGXiFMNqjilT8MxvooAYzoMGObBxhAgywBxL++oiODmahE4xmQDuyvQFtvCIUhfCDZzlxiB8sYQ5bIAG7WeBuF5CgCGDwAy6SLJUPBGAB967OKbBggx3wIAYq4PcOfBAFOljdwVXwAjPCcY5uSCgXyulGs8rRAQLUgRlsyoU30MCBEpjjHubYBjGcQGwIpOIeMJjABp5BBzVYAQmePcI0ZkwMbQgjFpDoxKHhIIYrXKEIL3gBEdTtbgz8HNOcgIwSJCmQ18LGE3MAwgpUwIMh8LvfPqBCsgcOMTLQ6WDnmBB75lOODDsgFhpnRivmAYK2X4AGE7hA8IvqhnhUY8Vt8IYa6FAHC2h7G0gAwAbkMQ49pYMGAJAAKwT+MYgrECEIHog8vOHt7hcUYQuZf8zmA/Df6owCC1OOOg/KUIWnx2AIjYCbIT5BBkNwHRoVcg7MkFPUcA7eUHZigAy0Iwy5IA8QAGdHAGJHAAMw4AbbMA+PIAkcMAG8UA5UoAaJwGgXkA7ZJgG8cIK8AAOYlQrmMgiWFgQyAAZbQAQu4AKRB35BEARbgAvqx3n/EBeyUQdSIAKoFgM+MARkoAZPFwWH8AqtMC37Bw3noCZmdg51Uid+AHG6gAwMWAu5sA0TcAMlwA+5VA/zEA/qcAyIUArtQAzEcA/XQAVwgAsW0Ge2IAEAwADvBVAX0AbPUAhgA29GgAZ2wARgAHn+JPACYLAhlsAFXOAr6ycQZ+B5kDEKPzADoxcDw/OBZaAGqfcKyAAKzNEKwhAOycMiB5cM4QAMCuAAk6ANtOOF0PALxOYG/XAMn9B3VmcI1vYK0VAO0QAKQwAH4xAP98APSMBb9rANqbAIbpAK1gU9I+MCWyADViEVXAAGL+ABMiAKsBGJP0iJjnEKYtB0UcdvPEAFj1MGQ6AGsRAO0KANasIMyKAM2nAMUpgMu6AKl0ABCPADCrgzlNAKi1UCJbAJ/SAMhlAG+1M+VJAtjUAIVMADnggEVkAKHCAAOOANwrAL3lAOyhAKhyAujQdvLeAYkZAJWwAGRgAGcGV0SPf+D3twBrBBCz+wbzvQb5rYjocACogQCsKgDcmgDXUiDtCADLrQC7twCYDgARRAAAhgA8sBC59wU69QDzTQdsSQD7kgQkNQBWRAB1FTOFUwAxTpAzbQA53AAABADNAACj8EB8o2koUwB5dABGBwkpDhB2DABeIoFfUmRZ4wF5FhCnNgAyIweudYenCgBqUQC6FwDMpwCZcQDuIgj/QoBhjgAAiAABGAAoeAQq1ACYxACbnQD8SQCr/AD+wACnJgOF0gB0l4Q1BABTuAhFQABGswaAXwDcIACm8ABEAgOWmALqswB98nBJEBhJ32aQIxC3MhjqfwAzbgA5mYOFDzBnD+AIqxIAzQoApqgg0AGA7FgJRr0ANWIIrKwTNVeVOtcA7lwA7qUA6toFdlADwhlIRwIDw8MAO46QOq4EvtgA1PSAVU9i1TAIjdRwQyQJMdsmQjJZOE+RiJgJgr4G85eYRcBAehoAxvogtzIJnHsHU/U570CAqUMJDtGQgsGghyEAipwQgLKTiFwwP0Y3VUUAVQwG/0wz9AEAq6IAwF6gMxMAPDmQZYMDLw9gFJsgf91VZa4KCOIQYhMGX+dkOpJwiv0ITSswu9sAXKoAxrwnVT2Aq0U5Us6gVj4AV/4AVuOgayWQZKMzFQwJD2Uwaf0nemN0sMOQPVyYSgoAZRMAT+MzADWWBESep9QWACSRJbAfAy/6AIUeoYjrAEISACiTkDVAAFHVQ1QJoqqpAJXHAJpRCPxGKFDLgzaKqmY7Cmc+OirZo099llWVcGhNAIPlkFQ5CTE8MDK2ADUfAKjaAGX9mffmoDRyQGRFAEMpAkahUAbAWlkyoVpmCpU9ZviVMFzgMKoTA9quAHIAABMgAJukAnVmh4yqGqjOCmavoHbeqmMeQFhuAFSUM/clAFt5o6N6QCsUkGUGCkbNYKXMY/MxACBktfiiql+AFSInUQplAXm3MLV2ChM8BvnKpsoCA9q8AKIBB8MNAJvYCU0BAOsEg7N0WagcCmf7CmcqP+pl4AMU3AA0nQBHNDBqCAq4SgBjwKMTxgA3Bws2QQCOwIBDZgsCGAAijAAkSgBNV0TQkhqVowFXOgb5m4A3KIOofQravgCv2EBlFxCqzwJtigDfIopGj6B4HgroHACHLQpoaAPxGTOE0gm4QgiohQBToLBS/bBf0JBy5KCOzoA/SFAkeLtCwQBEmyZJSkEHlQF1LhCjeZiUaoBoggCC9WCKWgCRNgBo7BB6OwC8rAdfLoTmzrru46BmjLqknjBUkws0GLq69QbVRQNLLZBLs6BNlSBVNjBT2AtL7LAi7AtE4kSf7FuHWRB7TAdIrJb4VKdVlwCLqgCRcQGZ+rU/D+eEJoOgaBsKauCqdkUK/1ijOgkAtwmUcvVD4xW3p0ADxRAASYerRLkAEZcLgRRLwP0bhaUK02UKinJzwW8wbQK72SMQracK4Tdyw8Q7ot6qJyUK9dVgafAAqxCwdRcIQvS69OYzQ8oAJWWqg2sAQukAFXcI3VcQb1Zm8QIamKMLGYuJMTmXocmgycML2S8QxXCA0a1x7tWQvIgAyyA13r6gVlkITQlSkV/JDcGzx1+nSh5KOEdAUukAj4oQQLIEmLGxGm8AWQ0AP7u2+lJ4eI8AqSKcCScQrnYIXUIAxww6JoGwitADe31go3VZVPyK2QY2CqI1zAMwR0QH+h9IH+U1CckxBk3ghbUHQAZzMRwcAKkXuhBna1r/AmmUDDNUyy2oAMuVCVbfsHhCAHhvAHMbS2awu7W3oIUmADWYAIrdAImlwGjdAIgWAIA2d1zyNRG8uD1KEEIBUAEgCpEjEOa4CJ+5Z6VysM9QgMG/CXUvEM2kANOCwMtcAIaXtT0iw3oMyilEAwuRAKoVBEaTC+ckzNN5VPrEctcNAIo7IKyYDLsKEFJzxJHjEIUubFX6nKbaIMwEADlgAbySMMbCIM0tyiN+WibhrL7vnGsaAMkDAIsXAMwgCUzQE30izN5UMHyQYqDJQMvgAbfPABUBQALvMRqmAFhXqbH6jKDo3+DL2ABJIgGXygDasskC1qCIbwogu8ttCVQuWpDZegCvdYCkRZtlXpYMJl0VGgbJfTC8DwGKjAByrz0QuQyB6RDGlQqM2rBuf8CpezC5xwBPy8xmRwzS4a0HLzou7phWhXjy/ACspQCshAlOGgxmgaCLOJt3J4CKai1L5CK55zAPPCFX/opzPgb1RXy6WwC5oAA9z0GL0Qzg7WtgtsCGlr0+8kDJYdJx6wBazQCw7NDNpQC+tJCSwqm4aAMbU8CaowCuahBR/wAH39AKC2F5NAtBc6dVQXBYJwKq4AA5bwl6uQOgHNrnJQzaBs1gMZ0bmgDcrQAAPgAZcgppg5MIb+cFMQcy1yuAZ9cAd7oAXxsgB9PQLYxBeQUGAVW7H9EwVTcNjAUAJfYBdS6gmlgAhBG7RuSgij3bY2nc21wIC58ArQoAsNoAAYAAbQIJ7Q0B7qKt9VkAXYLRc50Nos490W8ARa8R2qQJ3XqpPEk9DJgARmYBkgXheTeAd9sAZxoAbWPDdqet9yBE8nlAv/TQEUcAWqMLbNDM2fQDl4kN3bnQMmUCtlwzIT7su9AbnzvLw+MAXKgA3JwAZu4FZ5AOJSrgQifgYk3gd4YOLc4jgRLJqX45R2yQp8MgqOsCHX4eNNAuS28gA18AVEXiLleKmJqQIGlgXlus4wQBCmoAjAUT7lII4ZVO7eczHohG4X13EZ2hEiTrLotWIBbR4gJaIQl0C4mBp/SV4KSQkMOIAQ2pQHefAFthHqop4DuIEb2nHq2tEf/REirM7oJqADAFLhkc4QlI6pdH6kupAMu+0QlhQJdmAHX/AF2JEdqJ7qqq4BH6ADuBHseCHrs/4QkEu4iJlqFrkGk8AKrrABPEETkfDmz94RgEC4IWCkVpAG4eKlmiAB377uFeEKS4ACNvADQpQG5LILwMAE7J7vAhEQADs=" +#define ZEND_LOGO_DATA_URI "data:image/gif;base64,R0lGODlhcQBIANUAAA0NDgEDBgIFCS5EXhUdJwUPGgQKER0rOgABAgkZKiZpqxhDbQ0kOwobLQkZKSNgnSBXjh1PghpGchQ2Vx1NfAoaKiJYjQoYJgsaKQECAzdQaS0/UTE1OQUPGAkaKh5ViiFclRpJdQocLSBZjh5UhhpIcw8qQxc+YwwgMwcVIQkaKQgXIwcZJTM6PwIEBRkaGjEyMv9mAP///8zMzMfHx7+/v6urq5KSknNzc1VVVTw8PDc3NyYmJgcHBwMDAwAAACwAAAAAcQBIAAAG/8CZcEgsGo/IpHJ5/DGf0KiU+Ks6p9Kr0KrFer9GbReM7IrJ6O95Zt262durUy5uD8/rtL58h7vlf3+AcHlsdoR7iU12eIhzbXVVfpOTgGOKiWNrkpKUhZ99iJijl4d5kFSdXKmdb6OvsFOXsbS1oba4ubq7vL1DNjg6ODW+xVg3OTw/AisCOMbQSsA6AD8FDAsjIwwv0d5DNcnLIhMU2uclPzbf3jwC2Ofx585MwTfssD8n8vwjKDpLcggo8OMZPkw8GPSTN6HKCxg5hhHJ8WOCv4IHFeEwsDAeiQULJjBYUQXGM4oWtTU0mDGNjR/mOi48gcJKynMrW+oBcFNmP/8SJnri/JFDJ5kaL0T4XLqwYVGjWGy8MFCCqVWGRKFKsQGgAImrYIc+1bqEq9ewaEc0vEc2CdKzacOmY9vWxjoiMAx81Sajr9+/MhaE2Iu2hAAexPraJUbGxo3HkB/f/XKjCgBhwH5kOwcYsAoU5dKSMIBYSN8cOSZvxRGjtevXOnREZDwFhogSE1AYqKIwXl8VBlKoUNHXgAEUJwhfJVGgtGkZsek+Afa6uvUY0bFUjEdhgnJtIUwwmLDAb4cU3tM2pz2jb/YnN67Lr/4eSuWYPkmEGDyiL4MODITgm1+CkdBZgSh00xkMOkiHRHzWxSahDvNJyN4SG6HV1wSfJcf/GWAMdObfCQv8IOILDUoj34QTrhgbS0zAgEJYfqGgQnp8yXACA8N9NkFfHQRX4wl+6cADDH2h6KBdz7jIYosRShjFdmD5B6CAH/JIHkgh9JUCeuXJAOBpPDTYF4MO4mDCAU5KmMMNxNDAWpSx2QdTlTJwiNxeIhbYnwzDZeMlcTLAAAOc7qVIxAsVsrjkdRNCkeFVNd5ImIgqmCDgbyoICiihZd5gQ189KDoDDTcYcN1lE+JAgxE2QCrlEzLi+V+Af+4XpnHCafpnoL8SWugNOwD5gqg4oMbDCtahkAGD9RUBIX2xjbUElUyJ6BcDJoQJ2AldfuppoCJe0IEOB5hw/wIEKFRQnQgesJrDhUTI+iJ8d2arbXGdjhDub6BxOm6nJvzVwMEMSCDBAw+AwIAHr3kgQgdl5vAqEjXYq4NqSeAgAFjd2djjyL7qJ9JwDCQXnq/+mqBpCQXsWIEHKVPwQcMgOOyAaw4k0EAKGCmhsbVKVLbCBFUtte+GC+ylH5df6cffCFIbKAMJJ5A4GARcdz2BA2CH3YAIDABA7y8aO1g0NeOEttDSgLJMowwuh9D13VwDFTbYCZjQMEBIDO3FNACY0NFvwY3M72ZoLWCACRTgLfnXYTPwAQgKmFAUDjjQ1SbHtfXWz29gggSSSHKHRcIKJkAAguR4R/C1CJFD8P+AAiykABoCQrQJoxc4FHC4uPLod+DUfxI4mF8O/AhYgXj/JdjNEUSgwAMY1ECDxjpcDEZl330IrDzapvyViCn7FUD5yXXdWcqXg3D7CdPCNqHaWNSA7YDPIw+kkH1BTo3OA6QA9UUAIvhfCoZEAgj0ZUdhA03tRvAAEvhuDzpQCj8wJTcvgamAVgqYDIQTpgIkcIQfFFOAHCgDBjTPdFvj2gPaRDQy4CBf5JMBr4bTQeINinTe+U0BCiYDBzSgL2BbAAtT4IA+xbBrIODe2cDwghltEIVb8p8PPyWwPxlAAERsgAeQ6AAlklFEDtAUFKNIp9iADlXJQs2bbuA9Jdz/ED/i69eHwgUsTvkFPVb7QQUk0BcPNLGIZWRhEsPFqzTazXUzbKOphBCrNnaujkUwS/jgFqItkqszCKDdGRFpRlJa7VuDiaQliVBJ7t0LVl0JX/K0ZYAuCuyUfrEGBUaZREUmEgL/KiJoIqBKagljCPUz5pN+N4MaxLIj4RmZNINSN/BUE2s86gsADBABEJSgbit7ZDjzFgKRgC1lEJgPdiw2g2Ta70lvOkINeACXhTzNdPgUDAX24zR+asN4MjiSAS73AX5WjZxPhMA9Q/ABdbYGVY1aJuiGsBFZxqUjhhFGDlwgP4aN4HWwC2nXLOjQiLJIInbUy0Wt4pQa2IUH/ydQwARmKr8RiDSkJW3T/TCJMXpadKX/ZEBWKEqAFgDgBjCYgAJAetO75VSZjuKpEuYpgKQBlR8lYqZdhsCBhTG1qSR96pMkREcvUNWq/CBPXOixBA5QIGdN5dpTsTPWBkk1CmftR0N+YACkhUUEgJOGD0jwVa7l7LCvy2ld33TXKeQ1HiuxQQ5eUIUVoEBdS5kAAJ7gghM84G45Y9jtSgCCCHjAA2PzwGHqOqF4KuKxagkaJTmngxcIzycU+AH+iFADFCwVtCAgTwRQEIALQEAEIlBBB15QJtbKZrdpqAEMqhrbGiIThx0pgHWJgAMJ/NawDxhADzj3DBioSwQGAIfADpyLUloIpCbbHQJPlsIAGCxhBxa4HcM6at865qCcRFlsWXORA5MwIYMyWQADBBBfIdzgBRpAwVtvpzkjhCM1lHQMZKb4DY/xozsiEMAPeNDeJNDAMT/YwAkkwICJcpgsL9mMgglyGRxMlAmiAoCN2zIFeoZ4xK6NLo+nYIMX3XjISNZKEAAAOw==" BEGIN_EXTERN_C() PHP_FUNCTION(phpversion); PHP_FUNCTION(phpinfo); PHP_FUNCTION(phpcredits); -PHP_FUNCTION(php_logo_guid); -PHP_FUNCTION(php_real_logo_guid); -PHP_FUNCTION(zend_logo_guid); -PHP_FUNCTION(php_egg_logo_guid); PHP_FUNCTION(php_sapi_name); PHP_FUNCTION(php_uname); PHP_FUNCTION(php_ini_scanned_files); @@ -83,7 +78,6 @@ PHPAPI void php_info_print_box_start(int bg); PHPAPI void php_info_print_box_end(void); PHPAPI void php_info_print_hr(void); PHPAPI void php_info_print_module(zend_module_entry *module TSRMLS_DC); -PHPAPI char *php_logo_guid(void); PHPAPI char *php_get_uname(char mode); void register_phpinfo_constants(INIT_FUNC_ARGS); diff --git a/ext/standard/tests/php_logo_guid.phpt b/ext/standard/tests/php_logo_guid.phpt deleted file mode 100644 index c644b2893bb89..0000000000000 --- a/ext/standard/tests/php_logo_guid.phpt +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -Check the output of the php_logo_guid() function ---CREDITS-- -Sebastian Schürmann -sschuermann@chip.de -Testfest 2009 Munich ---FILE-- - ---EXPECT-- -PHPE9568F34-D428-11d2-A769-00AA001ACF42 - diff --git a/ext/standard/tests/php_real_logo_guid.phpt b/ext/standard/tests/php_real_logo_guid.phpt deleted file mode 100644 index a9fa7d35d51a8..0000000000000 --- a/ext/standard/tests/php_real_logo_guid.phpt +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Testing the undocumented function php_real_logo_guid() ---CREDITS-- -Sebastian Schürmann -sschuermann@chip.de -Testfest 2009 Munich ---FILE-- - ---EXPECT-- -PHPE9568F34-D428-11d2-A769-00AA001ACF42 diff --git a/ext/standard/tests/zend_logo_guid.phpt b/ext/standard/tests/zend_logo_guid.phpt deleted file mode 100644 index d26ed45e9e33f..0000000000000 --- a/ext/standard/tests/zend_logo_guid.phpt +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Checking the zend_logo_guid() functio ---CREDITS-- -Sebastian Schürmann -sschuermann@chip.de -Testfest 2009 Munich ---FILE-- - ---EXPECT-- -PHPE9568F35-D428-11d2-A769-00AA001ACF42 diff --git a/main/logos.h b/main/logos.h deleted file mode 100644 index 3b65cbbcf32c5..0000000000000 --- a/main/logos.h +++ /dev/null @@ -1,1080 +0,0 @@ -/* - +----------------------------------------------------------------------+ - | PHP Version 5 | - +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | - +----------------------------------------------------------------------+ - | This source file is subject to version 3.01 of the PHP license, | - | that is bundled with this package in the file LICENSE, and is | - | available through the world-wide-web at the following url: | - | http://www.php.net/license/3_01.txt | - | If you did not receive a copy of the PHP license and are unable to | - | obtain it through the world-wide-web, please send a note to | - | license@php.net so we can mail you a copy immediately. | - +----------------------------------------------------------------------+ - | Author: | - +----------------------------------------------------------------------+ -*/ - -/* $Id$ */ - -#define CONTEXT_TYPE_IMAGE_GIF "Content-Type: image/gif" - -static const unsigned char zend_logo[] = { - 71, 73, 70, 56, 57, 97, 113, 0, 72, 0, - 213, 0, 0, 13, 13, 14, 1, 3, 6, 2, - 5, 9, 46, 68, 94, 21, 29, 39, 5, 15, - 26, 4, 10, 17, 29, 43, 58, 0, 1, 2, - 9, 25, 42, 38, 105, 171, 24, 67, 109, 13, - 36, 59, 10, 27, 45, 9, 25, 41, 35, 96, - 157, 32, 87, 142, 29, 79, 130, 26, 70, 114, - 20, 54, 87, 29, 77, 124, 10, 26, 42, 34, - 88, 141, 10, 24, 38, 11, 26, 41, 1, 2, - 3, 55, 80, 105, 45, 63, 81, 49, 53, 57, - 5, 15, 24, 9, 26, 42, 30, 85, 138, 33, - 92, 149, 26, 73, 117, 10, 28, 45, 32, 89, - 142, 30, 84, 134, 26, 72, 115, 15, 42, 67, - 23, 62, 99, 12, 32, 51, 7, 21, 33, 9, - 26, 41, 8, 23, 35, 7, 25, 37, 51, 58, - 63, 2, 4, 5, 25, 26, 26, 49, 50, 50, - 255, 102, 0, 255, 255, 255, 204, 204, 204, 199, - 199, 199, 191, 191, 191, 171, 171, 171, 146, 146, - 146, 115, 115, 115, 85, 85, 85, 60, 60, 60, - 55, 55, 55, 38, 38, 38, 7, 7, 7, 3, - 3, 3, 0, 0, 0, 44, 0, 0, 0, 0, - 113, 0, 72, 0, 0, 6, 255, 192, 153, 112, - 72, 44, 26, 143, 200, 164, 114, 121, 252, 49, - 159, 208, 168, 148, 248, 171, 58, 167, 210, 171, - 208, 170, 197, 122, 191, 70, 109, 23, 140, 236, - 138, 201, 232, 239, 121, 102, 221, 186, 217, 219, - 171, 83, 46, 110, 15, 207, 235, 180, 190, 124, - 135, 187, 229, 127, 127, 128, 112, 121, 108, 118, - 132, 123, 137, 77, 118, 120, 136, 115, 109, 117, - 85, 126, 147, 147, 128, 99, 138, 137, 99, 107, - 146, 146, 148, 133, 159, 125, 136, 152, 163, 151, - 135, 121, 144, 84, 157, 92, 169, 157, 111, 163, - 175, 176, 83, 151, 177, 180, 181, 161, 182, 184, - 185, 186, 187, 188, 189, 67, 54, 56, 58, 56, - 53, 190, 197, 88, 55, 57, 60, 63, 2, 43, - 2, 56, 198, 208, 74, 192, 58, 0, 63, 5, - 12, 11, 35, 35, 12, 47, 209, 222, 67, 53, - 201, 203, 34, 19, 20, 218, 231, 37, 63, 54, - 223, 222, 60, 2, 216, 231, 241, 231, 206, 76, - 193, 55, 236, 176, 63, 39, 242, 252, 35, 40, - 58, 75, 114, 8, 40, 240, 227, 25, 62, 76, - 60, 24, 244, 147, 55, 161, 202, 11, 24, 57, - 134, 17, 201, 241, 99, 130, 191, 130, 7, 21, - 225, 48, 176, 48, 30, 137, 5, 11, 38, 48, - 88, 81, 5, 198, 51, 138, 22, 181, 53, 52, - 152, 49, 141, 141, 31, 230, 58, 46, 60, 129, - 194, 74, 202, 115, 43, 91, 234, 1, 112, 83, - 102, 63, 255, 18, 38, 122, 226, 252, 145, 67, - 39, 153, 26, 47, 68, 248, 92, 186, 176, 97, - 81, 163, 88, 108, 188, 48, 80, 130, 169, 85, - 134, 68, 161, 74, 177, 1, 160, 0, 137, 171, - 96, 135, 62, 213, 186, 132, 171, 215, 176, 104, - 71, 52, 188, 71, 54, 9, 210, 179, 105, 195, - 166, 99, 219, 214, 198, 58, 34, 48, 12, 124, - 213, 38, 163, 175, 223, 191, 50, 22, 132, 216, - 139, 182, 132, 0, 30, 196, 250, 218, 37, 70, - 198, 198, 141, 199, 144, 31, 223, 253, 114, 163, - 10, 0, 97, 192, 126, 100, 59, 7, 24, 176, - 10, 20, 229, 210, 146, 48, 128, 88, 72, 223, - 28, 57, 38, 111, 197, 17, 163, 181, 235, 215, - 58, 116, 68, 100, 60, 5, 134, 136, 18, 19, - 80, 24, 168, 162, 48, 94, 95, 21, 6, 82, - 168, 80, 209, 215, 128, 1, 20, 39, 8, 95, - 37, 81, 160, 180, 105, 25, 177, 233, 62, 1, - 246, 186, 186, 245, 24, 209, 177, 84, 140, 71, - 97, 130, 114, 109, 33, 76, 48, 152, 176, 192, - 111, 135, 20, 222, 211, 54, 167, 61, 163, 111, - 246, 39, 55, 174, 203, 175, 254, 30, 74, 229, - 152, 62, 73, 132, 24, 60, 162, 47, 131, 14, - 12, 132, 224, 155, 95, 130, 145, 208, 89, 129, - 40, 116, 211, 25, 12, 58, 72, 135, 68, 124, - 214, 197, 38, 161, 14, 243, 73, 200, 222, 18, - 27, 161, 213, 215, 4, 159, 37, 199, 255, 25, - 96, 12, 116, 230, 223, 9, 11, 252, 32, 226, - 11, 13, 74, 35, 223, 132, 19, 174, 24, 27, - 75, 76, 192, 128, 66, 88, 126, 161, 160, 66, - 122, 124, 201, 112, 2, 3, 195, 125, 54, 65, - 95, 29, 4, 87, 227, 9, 126, 233, 192, 3, - 12, 125, 161, 232, 160, 93, 207, 184, 200, 98, - 139, 17, 74, 24, 197, 118, 96, 249, 7, 160, - 128, 31, 242, 72, 30, 72, 33, 244, 149, 2, - 122, 229, 201, 0, 224, 105, 60, 52, 216, 23, - 131, 14, 226, 96, 194, 1, 78, 74, 152, 195, - 13, 196, 208, 192, 90, 148, 177, 217, 7, 83, - 149, 50, 112, 136, 220, 94, 34, 22, 216, 159, - 12, 195, 101, 227, 37, 113, 50, 192, 0, 3, - 156, 238, 165, 72, 196, 11, 21, 178, 184, 228, - 117, 19, 66, 145, 225, 85, 53, 222, 72, 152, - 136, 42, 152, 32, 224, 111, 42, 8, 10, 40, - 161, 101, 222, 96, 67, 95, 61, 40, 58, 3, - 13, 55, 24, 112, 221, 101, 19, 226, 64, 131, - 17, 54, 64, 42, 229, 19, 50, 226, 249, 95, - 128, 127, 238, 23, 166, 113, 194, 105, 250, 103, - 160, 191, 18, 90, 232, 13, 59, 0, 249, 130, - 168, 56, 160, 198, 195, 10, 214, 161, 144, 1, - 131, 245, 21, 1, 33, 125, 177, 141, 181, 4, - 149, 76, 137, 232, 23, 3, 38, 132, 9, 216, - 9, 93, 126, 234, 105, 160, 34, 94, 208, 129, - 14, 7, 152, 112, 255, 2, 4, 40, 84, 80, - 157, 8, 30, 176, 154, 195, 133, 68, 200, 250, - 34, 124, 119, 102, 171, 109, 113, 157, 142, 16, - 238, 111, 160, 113, 58, 110, 167, 38, 252, 213, - 192, 193, 12, 72, 32, 193, 3, 15, 128, 192, - 128, 7, 175, 121, 32, 66, 7, 101, 230, 240, - 42, 18, 53, 216, 171, 131, 106, 73, 224, 32, - 0, 88, 221, 217, 216, 227, 200, 190, 234, 39, - 210, 112, 12, 36, 23, 158, 175, 254, 154, 160, - 105, 9, 5, 236, 88, 129, 7, 41, 83, 240, - 65, 195, 32, 56, 236, 128, 107, 14, 36, 208, - 64, 10, 24, 41, 161, 177, 181, 74, 84, 182, - 194, 4, 85, 45, 181, 239, 134, 11, 236, 165, - 31, 151, 95, 233, 199, 223, 8, 82, 27, 40, - 3, 9, 39, 144, 56, 24, 4, 92, 119, 61, - 129, 3, 96, 135, 221, 128, 8, 12, 0, 64, - 239, 47, 26, 59, 88, 52, 53, 227, 132, 182, - 208, 210, 128, 178, 76, 163, 12, 46, 135, 208, - 245, 221, 92, 3, 21, 54, 216, 9, 152, 208, - 48, 64, 72, 12, 237, 197, 52, 0, 152, 208, - 209, 111, 193, 141, 204, 239, 102, 104, 45, 96, - 128, 9, 20, 224, 45, 249, 215, 97, 51, 240, - 1, 8, 10, 152, 80, 20, 14, 56, 208, 213, - 38, 199, 181, 245, 214, 207, 111, 96, 130, 4, - 146, 72, 114, 135, 69, 194, 10, 38, 64, 0, - 130, 228, 120, 71, 240, 181, 8, 145, 67, 240, - 255, 128, 2, 44, 164, 0, 26, 2, 66, 180, - 9, 163, 23, 56, 20, 112, 184, 184, 242, 232, - 119, 224, 212, 127, 18, 56, 152, 95, 14, 252, - 8, 88, 129, 120, 255, 37, 216, 205, 17, 68, - 160, 192, 3, 24, 212, 64, 131, 198, 58, 92, - 12, 70, 101, 223, 125, 8, 172, 60, 218, 166, - 252, 149, 136, 41, 251, 21, 64, 249, 201, 117, - 221, 89, 202, 151, 131, 112, 251, 9, 211, 194, - 54, 161, 218, 88, 212, 128, 237, 128, 207, 35, - 15, 164, 144, 125, 65, 78, 141, 206, 3, 164, - 0, 245, 69, 0, 34, 248, 95, 10, 134, 68, - 2, 8, 244, 101, 71, 97, 3, 77, 237, 70, - 240, 0, 18, 248, 110, 15, 58, 80, 10, 63, - 48, 37, 55, 47, 129, 169, 128, 86, 10, 152, - 12, 132, 19, 166, 2, 36, 112, 132, 31, 20, - 83, 128, 28, 40, 3, 6, 52, 207, 116, 91, - 227, 218, 3, 218, 68, 52, 50, 224, 32, 95, - 228, 147, 1, 175, 134, 211, 65, 226, 13, 138, - 116, 222, 249, 77, 1, 10, 38, 3, 7, 52, - 160, 47, 96, 91, 0, 11, 83, 224, 128, 62, - 197, 176, 107, 32, 224, 222, 217, 192, 240, 130, - 25, 109, 16, 133, 91, 242, 159, 15, 63, 37, - 176, 63, 25, 64, 0, 68, 108, 128, 7, 144, - 232, 0, 37, 146, 81, 68, 14, 208, 20, 20, - 163, 72, 167, 216, 128, 14, 85, 201, 66, 205, - 155, 110, 224, 61, 37, 220, 255, 16, 63, 226, - 235, 215, 135, 194, 5, 44, 78, 249, 5, 61, - 86, 251, 65, 5, 36, 208, 23, 15, 52, 177, - 136, 101, 100, 97, 18, 195, 197, 171, 52, 218, - 205, 117, 51, 108, 163, 169, 132, 16, 171, 54, - 118, 174, 142, 69, 48, 75, 248, 224, 22, 162, - 45, 146, 171, 51, 8, 160, 221, 25, 17, 105, - 70, 82, 90, 237, 91, 131, 137, 164, 37, 137, - 80, 73, 238, 221, 11, 86, 93, 9, 95, 242, - 180, 101, 128, 46, 10, 236, 148, 126, 177, 6, - 5, 70, 153, 68, 69, 38, 18, 2, 255, 42, - 34, 104, 34, 160, 74, 106, 9, 99, 8, 245, - 51, 230, 147, 126, 55, 131, 26, 196, 178, 35, - 225, 25, 153, 52, 131, 82, 55, 240, 84, 19, - 107, 60, 234, 11, 0, 12, 16, 1, 16, 148, - 160, 110, 43, 123, 100, 56, 243, 22, 2, 145, - 128, 45, 101, 16, 152, 15, 118, 44, 54, 131, - 100, 218, 239, 73, 111, 58, 66, 13, 120, 0, - 151, 133, 60, 205, 116, 248, 20, 12, 5, 246, - 227, 52, 126, 106, 195, 120, 50, 56, 146, 1, - 46, 247, 1, 126, 86, 141, 156, 79, 132, 192, - 61, 67, 240, 1, 117, 182, 6, 85, 141, 90, - 38, 232, 134, 176, 17, 89, 198, 165, 35, 134, - 17, 70, 14, 92, 32, 63, 134, 141, 224, 117, - 176, 11, 105, 215, 44, 232, 208, 136, 178, 72, - 34, 118, 212, 203, 69, 173, 226, 148, 26, 216, - 133, 7, 255, 39, 80, 192, 4, 102, 42, 191, - 17, 136, 52, 164, 37, 109, 211, 253, 48, 137, - 49, 122, 90, 116, 165, 255, 100, 64, 86, 40, - 74, 128, 22, 0, 224, 6, 48, 152, 128, 2, - 64, 122, 211, 187, 229, 84, 153, 142, 226, 169, - 18, 230, 41, 128, 164, 1, 149, 31, 37, 98, - 166, 93, 134, 192, 129, 133, 49, 181, 169, 36, - 125, 234, 147, 36, 68, 71, 47, 80, 213, 170, - 252, 32, 79, 92, 232, 177, 4, 14, 80, 32, - 103, 77, 229, 218, 83, 177, 51, 214, 6, 73, - 53, 10, 103, 237, 71, 67, 126, 96, 0, 164, - 133, 69, 4, 128, 147, 134, 15, 72, 240, 85, - 174, 229, 236, 176, 175, 203, 105, 93, 223, 116, - 215, 41, 228, 53, 30, 43, 177, 65, 14, 94, - 80, 133, 21, 160, 64, 93, 75, 153, 0, 0, - 158, 224, 130, 19, 60, 224, 110, 57, 99, 216, - 237, 74, 0, 130, 8, 120, 192, 3, 99, 243, - 192, 97, 234, 58, 161, 120, 42, 226, 177, 106, - 9, 26, 37, 57, 167, 131, 23, 8, 207, 39, - 20, 248, 1, 254, 136, 80, 3, 20, 44, 21, - 180, 32, 32, 79, 4, 80, 16, 128, 11, 64, - 64, 4, 34, 80, 65, 7, 94, 80, 38, 214, - 202, 102, 183, 105, 168, 1, 12, 170, 26, 219, - 26, 34, 19, 135, 29, 41, 128, 117, 137, 128, - 3, 9, 252, 214, 176, 15, 24, 64, 15, 56, - 247, 12, 24, 168, 75, 4, 6, 0, 135, 192, - 14, 156, 139, 82, 90, 8, 164, 38, 219, 29, - 2, 79, 150, 194, 0, 24, 44, 97, 7, 22, - 184, 29, 195, 58, 106, 223, 58, 230, 160, 156, - 68, 89, 108, 89, 115, 145, 3, 147, 48, 33, - 131, 50, 89, 0, 3, 4, 16, 95, 33, 220, - 224, 5, 26, 64, 193, 91, 111, 167, 57, 35, - 132, 35, 53, 148, 116, 12, 100, 166, 248, 13, - 143, 241, 163, 59, 34, 16, 192, 15, 120, 208, - 222, 36, 208, 192, 49, 63, 216, 192, 9, 36, - 192, 128, 137, 114, 152, 44, 47, 217, 140, 130, - 9, 114, 25, 28, 76, 148, 9, 162, 2, 128, - 141, 219, 50, 5, 122, 134, 120, 196, 174, 141, - 46, 143, 167, 96, 131, 23, 221, 120, 200, 72, - 214, 74, 16, 0, 0, 59 }; - -static const unsigned char php_logo[] = { - 71, 73, 70, 56, 57, 97, 120, 0, 67, 0, - 230, 106, 0, 127, 130, 184, 57, 55, 71, 40, - 37, 42, 204, 205, 226, 161, 164, 203, 211, 213, - 231, 178, 180, 212, 67, 66, 88, 131, 134, 185, - 130, 131, 179, 82, 82, 114, 144, 146, 194, 194, - 196, 222, 170, 172, 208, 76, 75, 99, 91, 92, - 131, 221, 222, 236, 59, 56, 60, 110, 113, 165, - 106, 109, 157, 97, 99, 141, 117, 121, 177, 123, - 126, 181, 229, 230, 240, 153, 156, 198, 140, 141, - 193, 185, 186, 217, 107, 107, 146, 78, 78, 107, - 113, 116, 169, 122, 122, 163, 136, 139, 189, 114, - 116, 163, 116, 115, 152, 142, 144, 193, 90, 91, - 126, 226, 227, 239, 123, 125, 173, 164, 165, 208, - 109, 112, 162, 114, 118, 172, 149, 150, 200, 187, - 189, 217, 116, 120, 174, 133, 136, 187, 146, 149, - 195, 216, 217, 234, 146, 146, 196, 100, 102, 146, - 107, 110, 159, 165, 168, 206, 148, 150, 197, 46, - 43, 47, 83, 81, 104, 179, 180, 215, 108, 106, - 140, 92, 91, 118, 138, 141, 191, 102, 104, 150, - 104, 106, 154, 156, 159, 200, 49, 46, 57, 174, - 176, 211, 156, 156, 205, 85, 86, 120, 158, 161, - 202, 150, 153, 197, 129, 130, 175, 103, 105, 151, - 63, 61, 80, 188, 190, 218, 94, 96, 137, 152, - 153, 200, 140, 142, 191, 137, 138, 186, 87, 88, - 124, 182, 183, 215, 213, 215, 232, 34, 30, 32, - 108, 111, 158, 206, 208, 228, 191, 192, 220, 119, - 123, 180, 118, 120, 167, 95, 94, 125, 153, 153, - 204, 110, 111, 152, 115, 119, 174, 34, 30, 31, - 255, 255, 255, 144, 142, 143, 89, 86, 87, 199, - 198, 199, 238, 238, 245, 213, 212, 213, 246, 246, - 250, 130, 128, 129, 172, 170, 171, 116, 114, 115, - 241, 240, 241, 158, 156, 157, 227, 226, 227, 75, - 72, 73, 185, 184, 185, 103, 100, 101, 137, 137, - 182, 0, 255, 0, 71, 70, 95, 223, 224, 237, - 155, 156, 204, 105, 107, 156, 111, 115, 167, 140, - 140, 186, 184, 185, 217, 184, 186, 215, 154, 155, - 204, 167, 170, 207, 219, 220, 235, 154, 156, 201, - 102, 100, 132, 104, 103, 137, 167, 168, 210, 110, - 112, 160, 139, 139, 185, 198, 199, 224, 199, 201, - 225, 105, 108, 156, 151, 152, 203, 33, 249, 4, - 1, 0, 0, 106, 0, 44, 0, 0, 0, 0, - 120, 0, 67, 0, 0, 7, 255, 128, 106, 130, - 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, - 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, - 151, 150, 109, 63, 109, 115, 152, 158, 159, 160, - 63, 121, 121, 54, 62, 26, 113, 76, 26, 26, - 76, 6, 62, 62, 13, 50, 4, 65, 60, 24, - 66, 45, 11, 73, 34, 57, 31, 25, 57, 34, - 47, 41, 160, 194, 161, 13, 26, 12, 125, 77, - 5, 80, 80, 3, 125, 124, 12, 81, 81, 42, - 114, 172, 175, 116, 177, 179, 66, 51, 45, 186, - 31, 8, 0, 22, 22, 21, 87, 40, 37, 22, - 9, 25, 193, 195, 235, 140, 38, 113, 124, 46, - 108, 108, 16, 16, 117, 46, 201, 3, 212, 50, - 179, 34, 31, 254, 44, 0, 17, 8, 4, 64, - 176, 224, 55, 130, 225, 164, 172, 64, 241, 70, - 194, 9, 63, 59, 158, 76, 25, 146, 132, 157, - 69, 53, 65, 108, 12, 96, 67, 226, 130, 71, - 18, 36, 242, 53, 16, 178, 64, 138, 201, 147, - 40, 83, 170, 92, 121, 114, 92, 7, 9, 19, - 118, 232, 128, 65, 225, 8, 5, 43, 67, 68, - 92, 196, 20, 132, 9, 20, 142, 30, 47, 184, - 48, 66, 167, 5, 203, 163, 72, 147, 162, 188, - 242, 38, 6, 140, 35, 71, 30, 140, 88, 114, - 196, 131, 206, 157, 144, 126, 104, 116, 1, 129, - 35, 4, 35, 4, 88, 40, 29, 75, 54, 233, - 149, 19, 58, 30, 44, 1, 162, 64, 193, 136, - 41, 51, 255, 176, 46, 50, 161, 161, 64, 19, - 23, 117, 10, 24, 72, 82, 182, 175, 95, 164, - 29, 96, 44, 81, 192, 129, 131, 3, 60, 9, - 228, 26, 202, 19, 101, 0, 148, 2, 3, 124, - 228, 248, 187, 114, 1, 134, 203, 152, 49, 124, - 160, 156, 244, 13, 5, 5, 14, 214, 172, 81, - 224, 65, 177, 154, 60, 70, 248, 244, 25, 192, - 100, 6, 231, 149, 31, 178, 112, 153, 77, 155, - 75, 151, 215, 74, 221, 44, 89, 115, 224, 128, - 131, 16, 59, 221, 69, 97, 192, 160, 1, 2, - 220, 43, 49, 112, 193, 194, 188, 185, 153, 219, - 200, 147, 118, 216, 93, 164, 200, 154, 210, 195, - 126, 248, 144, 99, 68, 5, 15, 11, 209, 87, - 170, 32, 211, 188, 185, 152, 2, 225, 149, 94, - 121, 112, 32, 64, 0, 14, 112, 64, 153, 48, - 192, 68, 14, 1, 0, 233, 87, 22, 16, 83, - 158, 57, 25, 21, 249, 41, 245, 134, 2, 238, - 245, 112, 7, 38, 115, 208, 225, 131, 1, 50, - 28, 23, 160, 74, 93, 152, 209, 31, 22, 92, - 16, 240, 160, 82, 49, 172, 209, 67, 15, 7, - 236, 81, 201, 15, 50, 52, 208, 64, 73, 23, - 166, 4, 64, 22, 19, 98, 145, 197, 102, 37, - 38, 245, 64, 0, 27, 2, 39, 73, 27, 4, - 236, 227, 96, 139, 39, 41, 55, 161, 25, 95, - 224, 168, 148, 31, 69, 208, 64, 3, 21, 145, - 216, 17, 4, 1, 51, 128, 135, 212, 255, 7, - 153, 53, 217, 36, 139, 71, 169, 16, 198, 132, - 98, 92, 208, 36, 137, 44, 49, 233, 228, 150, - 248, 141, 133, 130, 3, 52, 8, 80, 195, 35, - 72, 96, 16, 4, 148, 71, 125, 240, 69, 22, - 108, 182, 233, 230, 155, 89, 116, 81, 64, 3, - 93, 162, 84, 0, 24, 19, 146, 1, 103, 155, - 23, 12, 96, 225, 73, 11, 236, 41, 40, 155, - 93, 12, 208, 128, 82, 64, 8, 32, 128, 3, - 141, 204, 32, 4, 6, 98, 41, 69, 192, 114, - 41, 86, 106, 6, 24, 92, 124, 1, 32, 74, - 93, 108, 81, 105, 138, 52, 108, 161, 69, 25, - 93, 144, 104, 192, 148, 159, 78, 184, 5, 24, - 94, 116, 113, 40, 82, 35, 8, 224, 4, 163, - 138, 108, 35, 196, 141, 73, 141, 151, 234, 167, - 91, 120, 1, 65, 151, 39, 238, 250, 41, 24, - 99, 96, 32, 197, 0, 120, 10, 171, 106, 25, - 3, 36, 53, 130, 19, 78, 224, 144, 72, 10, - 34, 180, 128, 102, 82, 16, 240, 167, 108, 138, - 97, 64, 96, 18, 6, 94, 108, 155, 34, 26, - 183, 93, 224, 169, 184, 229, 209, 224, 69, 179, - 72, 173, 1, 45, 118, 133, 252, 225, 203, 100, - 101, 125, 33, 33, 186, 253, 121, 1, 160, 148, - 248, 230, 219, 0, 138, 253, 54, 71, 67, 25, - 127, 30, 21, 128, 19, 2, 44, 96, 72, 63, - 244, 146, 21, 91, 192, 229, 109, 209, 227, 157, - 16, 51, 167, 197, 255, 5, 225, 86, 140, 133, - 24, 208, 29, 213, 129, 172, 99, 18, 146, 2, - 2, 31, 212, 57, 214, 164, 59, 194, 57, 198, - 25, 218, 78, 232, 5, 1, 157, 78, 200, 197, - 155, 99, 112, 129, 70, 138, 90, 100, 129, 106, - 196, 112, 150, 113, 198, 185, 19, 150, 129, 37, - 75, 10, 64, 155, 6, 33, 222, 224, 58, 150, - 174, 253, 137, 225, 45, 74, 11, 52, 208, 5, - 121, 19, 106, 193, 0, 192, 253, 173, 136, 18, - 6, 13, 124, 17, 65, 213, 89, 104, 81, 53, - 187, 128, 26, 240, 69, 178, 253, 133, 97, 128, - 82, 52, 204, 58, 200, 31, 0, 32, 160, 100, - 89, 217, 230, 185, 169, 137, 89, 124, 221, 116, - 22, 25, 151, 199, 227, 74, 16, 0, 221, 92, - 206, 130, 51, 119, 198, 218, 42, 125, 48, 6, - 206, 119, 31, 181, 4, 180, 10, 171, 33, 130, - 5, 38, 147, 101, 175, 204, 5, 167, 20, 184, - 170, 58, 83, 249, 116, 74, 49, 247, 119, 70, - 22, 52, 4, 109, 236, 74, 161, 151, 167, 69, - 227, 44, 117, 0, 237, 13, 130, 176, 144, 80, - 95, 15, 79, 56, 198, 181, 39, 109, 222, 31, - 26, 89, 160, 221, 220, 127, 42, 5, 27, 116, - 25, 19, 210, 144, 197, 81, 169, 15, 206, 58, - 75, 69, 184, 173, 70, 56, 115, 147, 133, 114, - 127, 17, 244, 200, 210, 229, 253, 17, 142, 185, - 74, 224, 22, 159, 197, 25, 170, 94, 112, 20, - 255, 214, 229, 1, 175, 20, 7, 78, 244, 32, - 72, 5, 148, 49, 93, 30, 26, 159, 167, 84, - 123, 218, 228, 55, 119, 187, 74, 252, 246, 183, - 69, 216, 99, 179, 132, 1, 241, 219, 83, 10, - 5, 160, 37, 136, 21, 80, 166, 110, 217, 91, - 158, 73, 12, 0, 190, 160, 245, 173, 57, 213, - 211, 143, 239, 152, 3, 134, 44, 20, 14, 11, - 135, 99, 9, 3, 168, 214, 159, 251, 9, 144, - 128, 41, 184, 2, 251, 252, 130, 189, 242, 84, - 136, 37, 201, 99, 78, 4, 58, 183, 187, 248, - 157, 36, 133, 88, 8, 3, 233, 76, 183, 18, - 0, 120, 109, 66, 228, 34, 203, 0, 157, 32, - 8, 20, 24, 176, 47, 194, 235, 32, 238, 142, - 69, 169, 236, 245, 174, 106, 203, 11, 98, 121, - 188, 0, 192, 116, 29, 79, 63, 28, 44, 79, - 24, 20, 184, 146, 29, 10, 162, 3, 40, 24, - 33, 89, 116, 68, 189, 39, 162, 228, 3, 5, - 240, 66, 233, 250, 67, 131, 49, 124, 225, 130, - 39, 76, 73, 247, 38, 244, 189, 240, 113, 15, - 2, 98, 156, 80, 245, 42, 119, 20, 43, 170, - 97, 33, 90, 92, 90, 20, 153, 67, 46, 21, - 248, 81, 5, 16, 232, 194, 24, 180, 48, 70, - 209, 13, 160, 126, 204, 241, 32, 74, 242, 199, - 51, 177, 101, 175, 11, 127, 4, 100, 23, 202, - 224, 72, 153, 81, 113, 37, 232, 83, 223, 243, - 58, 112, 133, 190, 236, 71, 255, 85, 90, 8, - 101, 40, 197, 112, 175, 20, 137, 225, 11, 4, - 120, 160, 10, 189, 104, 167, 9, 98, 161, 130, - 23, 20, 149, 40, 181, 64, 202, 97, 137, 175, - 44, 205, 163, 213, 7, 222, 208, 129, 190, 68, - 72, 99, 104, 248, 194, 2, 78, 133, 67, 23, - 154, 196, 92, 19, 146, 97, 33, 3, 118, 202, - 161, 73, 231, 117, 130, 72, 129, 4, 222, 240, - 67, 165, 40, 177, 95, 205, 60, 150, 43, 173, - 182, 18, 68, 98, 129, 137, 26, 3, 131, 48, - 251, 242, 56, 39, 68, 238, 121, 18, 232, 229, - 88, 214, 216, 47, 26, 156, 97, 156, 82, 64, - 102, 127, 184, 240, 170, 173, 169, 146, 57, 109, - 12, 88, 4, 206, 112, 1, 103, 178, 205, 121, - 130, 120, 193, 9, 36, 208, 73, 165, 48, 82, - 92, 102, 32, 195, 24, 6, 80, 167, 25, 118, - 208, 159, 196, 212, 31, 255, 240, 101, 6, 25, - 50, 128, 142, 73, 41, 154, 19, 142, 70, 136, - 33, 156, 224, 13, 99, 161, 152, 254, 102, 57, - 75, 50, 112, 97, 12, 133, 66, 83, 160, 72, - 26, 74, 86, 158, 68, 5, 92, 96, 233, 232, - 46, 40, 6, 150, 134, 210, 164, 40, 101, 192, - 16, 165, 3, 50, 67, 164, 224, 4, 39, 80, - 39, 82, 96, 200, 133, 11, 208, 131, 30, 5, - 248, 35, 1, 252, 105, 18, 64, 30, 245, 168, - 153, 3, 212, 0, 158, 74, 143, 67, 46, 147, - 57, 94, 255, 48, 234, 81, 147, 234, 71, 2, - 236, 116, 44, 7, 75, 216, 33, 146, 16, 131, - 19, 160, 0, 41, 215, 76, 36, 83, 125, 36, - 133, 5, 52, 177, 60, 89, 192, 40, 114, 220, - 229, 4, 120, 25, 34, 1, 101, 45, 104, 114, - 238, 185, 66, 182, 178, 164, 1, 13, 140, 88, - 199, 242, 83, 78, 105, 41, 162, 4, 121, 101, - 201, 65, 249, 104, 76, 191, 74, 129, 1, 149, - 108, 14, 24, 208, 19, 160, 114, 210, 106, 17, - 136, 53, 171, 4, 171, 198, 0, 199, 170, 68, - 119, 82, 188, 36, 101, 52, 122, 89, 70, 148, - 96, 2, 49, 232, 64, 30, 165, 64, 212, 122, - 122, 214, 36, 121, 115, 217, 233, 162, 211, 129, - 3, 64, 171, 180, 141, 72, 0, 106, 37, 160, - 197, 180, 98, 97, 12, 107, 245, 209, 2, 22, - 199, 70, 185, 250, 133, 8, 61, 128, 150, 97, - 35, 161, 132, 39, 76, 64, 179, 82, 248, 223, - 22, 166, 75, 93, 222, 189, 214, 158, 212, 165, - 46, 24, 6, 251, 26, 5, 200, 74, 0, 50, - 154, 196, 11, 64, 224, 135, 24, 240, 22, 0, - 5, 160, 42, 61, 16, 119, 93, 41, 160, 87, - 189, 16, 112, 45, 101, 136, 112, 48, 39, 68, - 128, 163, 150, 72, 128, 27, 80, 251, 134, 213, - 182, 215, 175, 39, 176, 173, 114, 65, 241, 130, - 41, 248, 1, 181, 170, 253, 175, 95, 81, 192, - 1, 89, 57, 161, 8, 248, 5, 133, 255, 18, - 244, 224, 134, 3, 247, 87, 193, 37, 58, 193, - 26, 28, 220, 131, 240, 178, 131, 5, 20, 62, - 176, 4, 206, 138, 225, 240, 28, 225, 0, 138, - 18, 64, 15, 96, 167, 24, 22, 128, 96, 7, - 110, 112, 67, 12, 168, 89, 98, 202, 248, 129, - 3, 1, 8, 147, 0, 2, 192, 98, 211, 8, - 34, 9, 37, 32, 194, 14, 96, 60, 1, 26, - 215, 56, 41, 19, 32, 80, 15, 132, 36, 38, - 187, 250, 120, 16, 41, 72, 128, 30, 116, 64, - 4, 33, 187, 33, 168, 254, 197, 240, 27, 142, - 128, 227, 13, 45, 185, 8, 120, 120, 193, 147, - 23, 241, 2, 41, 235, 224, 204, 103, 222, 193, - 71, 73, 124, 221, 29, 28, 65, 1, 237, 129, - 209, 134, 14, 112, 3, 15, 141, 249, 17, 47, - 64, 192, 20, 136, 0, 131, 62, 251, 153, 8, - 126, 248, 168, 80, 243, 51, 1, 34, 60, 0, - 52, 213, 113, 143, 162, 113, 16, 2, 59, 223, - 153, 18, 34, 24, 194, 158, 41, 64, 233, 74, - 83, 250, 8, 125, 174, 112, 160, 223, 192, 105, - 78, 75, 224, 211, 159, 6, 42, 80, 137, 112, - 105, 182, 136, 166, 55, 7, 168, 78, 17, 2, - 112, 0, 28, 108, 32, 49, 143, 22, 70, 10, - 62, 80, 2, 16, 88, 1, 42, 80, 121, 128, - 174, 119, 61, 149, 37, 172, 5, 8, 108, 105, - 11, 97, 10, 99, 152, 208, 156, 186, 55, 69, - 80, 0, 21, 110, 56, 48, 4, 49, 199, 90, - 49, 41, 80, 2, 2, 60, 224, 129, 13, 108, - 32, 45, 190, 6, 118, 176, 219, 66, 108, 195, - 112, 128, 10, 35, 24, 129, 21, 172, 80, 130, - 102, 63, 251, 220, 139, 16, 65, 26, 16, 112, - 21, 116, 187, 251, 221, 240, 142, 119, 188, 3, - 1, 0, 59, 0 }; - -static const unsigned char php_egg_logo[] = { - 71, 73, 70, 56, 57, 97, 120, 0, 67, 0, - 231, 255, 0, 18, 25, 33, 32, 30, 34, 28, - 33, 44, 15, 35, 71, 6, 37, 85, 37, 40, - 47, 34, 41, 53, 41, 40, 43, 9, 47, 109, - 30, 45, 68, 21, 48, 84, 51, 46, 55, 43, - 49, 59, 31, 59, 98, 15, 61, 128, 58, 55, - 69, 50, 57, 74, 0, 66, 144, 56, 58, 60, - 54, 59, 71, 32, 66, 113, 60, 65, 67, 63, - 65, 84, 63, 68, 79, 28, 79, 145, 15, 82, - 162, 75, 72, 98, 68, 78, 86, 74, 77, 88, - 50, 82, 122, 41, 85, 134, 76, 78, 108, 70, - 83, 101, 5, 94, 190, 0, 95, 197, 86, 80, - 101, 28, 92, 159, 80, 84, 96, 83, 83, 115, - 81, 87, 89, 22, 97, 183, 86, 88, 85, 0, - 102, 210, 8, 101, 204, 24, 100, 177, 85, 90, - 127, 35, 101, 169, 42, 100, 159, 88, 92, 103, - 0, 107, 216, 69, 95, 132, 0, 108, 210, 84, - 93, 112, 94, 90, 117, 18, 105, 201, 96, 92, - 105, 89, 96, 98, 94, 93, 135, 94, 94, 126, - 30, 106, 210, 7, 112, 222, 33, 108, 198, 16, - 114, 217, 27, 113, 198, 24, 113, 209, 59, 108, - 159, 96, 100, 138, 0, 120, 229, 44, 112, 180, - 49, 112, 171, 71, 108, 148, 99, 104, 115, 90, - 106, 125, 27, 115, 232, 100, 102, 147, 42, 115, - 192, 86, 110, 137, 9, 123, 239, 106, 108, 105, - 105, 105, 138, 33, 118, 228, 12, 125, 227, 48, - 117, 208, 16, 126, 222, 37, 120, 224, 20, 125, - 235, 35, 123, 213, 50, 121, 190, 43, 123, 206, - 40, 123, 220, 105, 110, 160, 59, 122, 182, 78, - 119, 158, 44, 122, 233, 3, 134, 250, 112, 112, - 151, 73, 123, 175, 113, 118, 114, 51, 128, 205, - 34, 129, 246, 11, 136, 245, 34, 130, 240, 113, - 117, 149, 111, 116, 166, 111, 119, 141, 48, 130, - 221, 38, 132, 235, 53, 130, 215, 97, 124, 146, - 116, 122, 124, 117, 121, 131, 54, 130, 229, 41, - 135, 232, 68, 130, 223, 46, 135, 246, 65, 134, - 202, 42, 137, 241, 75, 131, 205, 124, 121, 161, - 101, 125, 191, 86, 128, 210, 121, 122, 169, 105, - 128, 157, 121, 122, 180, 114, 124, 181, 94, 128, - 201, 81, 134, 185, 46, 138, 252, 76, 135, 195, - 34, 142, 252, 62, 137, 229, 63, 138, 217, 33, - 144, 247, 58, 139, 223, 56, 141, 246, 54, 143, - 234, 57, 143, 241, 102, 135, 193, 129, 130, 176, - 122, 136, 144, 46, 148, 252, 45, 149, 246, 118, - 133, 191, 65, 146, 231, 73, 146, 216, 129, 133, - 185, 135, 135, 156, 69, 148, 226, 44, 153, 255, - 94, 143, 216, 132, 136, 175, 88, 146, 207, 137, - 139, 136, 93, 146, 197, 95, 147, 188, 137, 139, - 150, 104, 146, 178, 122, 143, 172, 135, 139, 191, - 57, 156, 254, 67, 154, 245, 70, 154, 239, 134, - 141, 180, 117, 145, 201, 120, 146, 190, 79, 154, - 233, 140, 141, 188, 129, 144, 194, 142, 142, 176, - 137, 147, 156, 88, 155, 222, 82, 157, 230, 93, - 157, 218, 66, 162, 253, 100, 157, 210, 77, 161, - 247, 55, 168, 255, 81, 162, 241, 148, 148, 195, - 145, 149, 202, 127, 156, 204, 77, 166, 255, 142, - 155, 177, 141, 153, 200, 123, 160, 193, 73, 171, - 255, 93, 167, 240, 96, 167, 234, 152, 158, 160, - 101, 167, 228, 119, 164, 206, 155, 158, 171, 110, - 167, 219, 156, 155, 203, 89, 172, 252, 128, 164, - 219, 151, 163, 174, 81, 178, 255, 158, 162, 202, - 102, 175, 249, 93, 178, 251, 108, 175, 237, 103, - 177, 244, 166, 168, 165, 97, 182, 255, 87, 185, - 255, 149, 174, 216, 125, 181, 235, 110, 185, 252, - 117, 183, 254, 171, 172, 209, 166, 175, 197, 103, - 190, 255, 174, 176, 189, 140, 183, 221, 128, 184, - 248, 120, 187, 249, 179, 180, 184, 115, 193, 253, - 170, 183, 193, 174, 181, 215, 107, 197, 255, 135, - 191, 246, 151, 192, 219, 187, 183, 213, 128, 197, - 253, 121, 202, 255, 147, 198, 239, 188, 191, 219, - 148, 200, 252, 192, 193, 197, 134, 205, 254, 171, - 199, 236, 183, 199, 218, 163, 207, 251, 142, 213, - 255, 158, 211, 253, 195, 205, 217, 166, 211, 245, - 205, 204, 228, 153, 218, 255, 190, 210, 236, 186, - 212, 231, 177, 213, 248, 162, 224, 255, 188, 221, - 250, 214, 219, 221, 214, 219, 233, 174, 229, 254, - 198, 225, 247, 209, 226, 248, 186, 233, 251, 227, - 230, 239, 225, 241, 252, 253, 255, 252, 255, 255, - 255, 33, 249, 4, 1, 10, 0, 255, 0, 44, - 0, 0, 0, 0, 120, 0, 67, 0, 0, 8, - 254, 0, 255, 9, 28, 72, 176, 160, 193, 131, - 8, 19, 42, 92, 200, 176, 161, 195, 135, 16, - 35, 74, 156, 72, 177, 162, 197, 139, 22, 131, - 105, 12, 134, 177, 163, 199, 143, 193, 164, 73, - 227, 38, 141, 28, 56, 112, 228, 76, 146, 20, - 41, 205, 152, 75, 99, 183, 100, 201, 50, 101, - 202, 147, 77, 79, 166, 102, 205, 250, 200, 19, - 100, 73, 114, 239, 238, 221, 123, 71, 148, 104, - 202, 163, 224, 86, 138, 124, 25, 115, 166, 205, - 72, 145, 246, 72, 221, 195, 39, 207, 30, 69, - 158, 118, 246, 220, 202, 208, 24, 184, 160, 252, - 248, 9, 29, 59, 212, 100, 75, 99, 53, 159, - 66, 93, 203, 182, 109, 84, 169, 124, 248, 156, - 57, 163, 165, 174, 150, 60, 138, 76, 113, 221, - 251, 207, 24, 183, 119, 97, 3, 135, 125, 71, - 78, 90, 76, 62, 142, 70, 141, 18, 53, 109, - 170, 227, 199, 144, 35, 75, 157, 91, 87, 137, - 229, 28, 74, 190, 228, 229, 139, 209, 43, 96, - 193, 247, 10, 203, 114, 212, 167, 82, 47, 93, - 197, 138, 81, 163, 166, 173, 19, 47, 201, 176, - 99, 59, 166, 171, 36, 135, 237, 22, 45, 114, - 216, 209, 203, 25, 98, 176, 191, 66, 195, 134, - 54, 230, 233, 150, 179, 100, 197, 106, 181, 90, - 158, 171, 57, 179, 110, 231, 124, 185, 145, 77, - 157, 186, 150, 218, 45, 76, 104, 111, 145, 71, - 86, 239, 133, 198, 200, 254, 145, 189, 199, 205, - 212, 212, 115, 244, 232, 157, 107, 86, 172, 185, - 234, 92, 197, 154, 137, 11, 231, 11, 77, 245, - 251, 178, 207, 40, 201, 254, 225, 131, 134, 39, - 138, 124, 103, 80, 73, 68, 13, 37, 141, 39, - 144, 213, 115, 14, 60, 235, 116, 211, 12, 123, - 197, 136, 67, 141, 106, 226, 156, 51, 78, 16, - 92, 208, 194, 7, 126, 28, 70, 166, 159, 9, - 26, 132, 104, 130, 29, 2, 254, 67, 32, 81, - 224, 200, 18, 91, 56, 240, 208, 35, 78, 51, - 238, 49, 40, 223, 58, 240, 88, 99, 132, 31, - 207, 168, 131, 14, 55, 206, 56, 115, 203, 41, - 167, 172, 229, 73, 36, 158, 196, 133, 216, 83, - 29, 58, 166, 69, 11, 26, 88, 96, 129, 6, - 95, 112, 230, 213, 81, 210, 188, 21, 27, 59, - 208, 208, 179, 14, 123, 205, 81, 227, 96, 55, - 235, 208, 227, 14, 23, 126, 244, 162, 204, 49, - 200, 64, 3, 13, 51, 194, 232, 162, 139, 50, - 105, 106, 131, 13, 54, 225, 132, 227, 205, 157, - 207, 96, 243, 204, 48, 195, 244, 72, 28, 126, - 103, 48, 233, 164, 6, 36, 246, 20, 210, 81, - 198, 224, 87, 143, 48, 12, 78, 8, 75, 43, - 242, 21, 3, 38, 60, 227, 116, 224, 2, 22, - 135, 32, 162, 41, 33, 112, 208, 129, 72, 35, - 135, 8, 242, 72, 40, 163, 150, 82, 202, 42, - 186, 172, 178, 203, 46, 169, 170, 154, 76, 50, - 254, 123, 158, 194, 97, 14, 22, 60, 240, 192, - 7, 188, 117, 228, 23, 74, 198, 88, 41, 219, - 56, 189, 36, 19, 203, 57, 235, 80, 147, 11, - 44, 176, 20, 211, 96, 51, 240, 192, 195, 14, - 5, 36, 88, 129, 8, 33, 116, 200, 81, 198, - 181, 101, 208, 1, 199, 27, 220, 110, 59, 69, - 22, 130, 20, 82, 200, 35, 165, 76, 34, 110, - 33, 147, 64, 162, 174, 42, 192, 200, 122, 223, - 25, 38, 216, 186, 192, 19, 24, 133, 52, 82, - 149, 247, 161, 179, 203, 35, 136, 8, 243, 72, - 57, 244, 80, 179, 220, 39, 185, 192, 163, 77, - 55, 244, 236, 227, 14, 5, 17, 0, 65, 7, - 25, 101, 120, 81, 197, 196, 216, 82, 97, 49, - 21, 81, 68, 145, 69, 22, 105, 116, 236, 113, - 26, 161, 148, 59, 136, 24, 98, 64, 210, 203, - 40, 28, 106, 161, 193, 2, 11, 88, 144, 171, - 68, 246, 74, 163, 226, 125, 207, 156, 105, 8, - 25, 212, 54, 218, 202, 39, 4, 227, 115, 142, - 54, 233, 177, 211, 65, 4, 51, 84, 113, 109, - 21, 77, 52, 1, 69, 23, 19, 15, 1, 197, - 16, 84, 12, 17, 197, 182, 112, 8, 146, 198, - 20, 86, 147, 139, 204, 49, 169, 78, 50, 200, - 32, 144, 56, 210, 97, 14, 15, 176, 28, 37, - 204, 198, 180, 228, 107, 108, 158, 60, 19, 202, - 43, 159, 200, 225, 133, 28, 175, 224, 3, 15, - 50, 176, 80, 2, 75, 254, 51, 94, 34, 140, - 143, 208, 68, 119, 129, 45, 210, 93, 48, 13, - 197, 210, 60, 240, 0, 133, 15, 111, 104, 138, - 8, 28, 27, 79, 1, 199, 35, 163, 234, 18, - 139, 155, 233, 206, 177, 97, 202, 22, 28, 112, - 128, 14, 17, 5, 227, 210, 204, 213, 69, 178, - 11, 40, 160, 16, 194, 8, 33, 134, 52, 17, - 142, 122, 197, 236, 156, 11, 51, 185, 52, 3, - 244, 62, 128, 207, 16, 49, 182, 93, 36, 125, - 120, 23, 135, 67, 193, 131, 15, 112, 148, 147, - 143, 58, 216, 8, 3, 249, 198, 89, 192, 1, - 199, 33, 143, 196, 18, 203, 42, 144, 104, 222, - 33, 31, 26, 120, 62, 194, 67, 162, 255, 121, - 159, 35, 149, 104, 58, 135, 21, 100, 64, 92, - 69, 139, 198, 238, 156, 236, 222, 226, 208, 131, - 207, 56, 13, 56, 80, 116, 19, 215, 54, 81, - 197, 24, 73, 23, 126, 248, 16, 62, 248, 144, - 133, 62, 110, 112, 194, 50, 202, 113, 8, 231, - 101, 193, 7, 64, 152, 220, 184, 30, 129, 42, - 93, 168, 66, 108, 29, 50, 129, 231, 52, 208, - 16, 89, 220, 162, 87, 248, 137, 68, 29, 178, - 160, 6, 53, 188, 225, 5, 85, 176, 86, 21, - 232, 1, 15, 113, 228, 98, 57, 173, 104, 143, - 151, 224, 241, 190, 248, 249, 160, 126, 114, 136, - 161, 181, 202, 16, 53, 167, 13, 97, 120, 105, - 184, 7, 7, 12, 224, 4, 111, 192, 65, 114, - 254, 144, 3, 66, 26, 14, 145, 6, 43, 88, - 1, 11, 107, 128, 196, 42, 86, 1, 65, 14, - 181, 224, 0, 1, 160, 160, 66, 100, 114, 139, - 181, 197, 230, 22, 117, 152, 194, 20, 162, 160, - 134, 42, 144, 64, 10, 248, 163, 67, 122, 214, - 17, 187, 79, 232, 45, 23, 226, 16, 7, 62, - 240, 97, 13, 5, 16, 109, 12, 215, 98, 4, - 207, 64, 193, 51, 77, 53, 66, 83, 84, 240, - 65, 26, 218, 113, 1, 3, 180, 1, 27, 144, - 19, 196, 183, 128, 128, 196, 66, 132, 98, 13, - 63, 72, 228, 15, 176, 32, 134, 68, 52, 241, - 62, 45, 8, 64, 0, 106, 144, 144, 89, 152, - 66, 22, 8, 186, 207, 40, 214, 32, 8, 107, - 216, 194, 5, 67, 144, 218, 15, 134, 208, 5, - 68, 184, 15, 30, 205, 120, 148, 25, 97, 1, - 157, 125, 208, 227, 25, 3, 136, 64, 12, 232, - 215, 136, 121, 200, 35, 31, 249, 168, 71, 61, - 242, 33, 143, 118, 108, 67, 30, 208, 128, 195, - 32, 218, 49, 1, 1, 180, 1, 121, 199, 120, - 197, 35, 136, 184, 134, 102, 146, 11, 137, 88, - 80, 228, 37, 104, 145, 36, 13, 72, 178, 80, - 5, 153, 5, 78, 50, 73, 157, 72, 92, 98, - 13, 135, 208, 135, 63, 252, 129, 132, 40, 116, - 193, 105, 192, 11, 5, 62, 92, 217, 140, 157, - 49, 162, 21, 104, 60, 199, 62, 224, 225, 10, - 2, 68, 128, 10, 114, 254, 32, 196, 49, 178, - 113, 129, 11, 112, 224, 159, 37, 224, 192, 6, - 46, 176, 129, 108, 148, 99, 21, 213, 40, 230, - 1, 78, 128, 3, 55, 240, 34, 29, 216, 8, - 197, 36, 122, 81, 10, 114, 61, 2, 93, 107, - 136, 230, 28, 230, 96, 13, 43, 202, 230, 1, - 1, 56, 128, 119, 10, 146, 150, 251, 240, 65, - 21, 88, 200, 194, 60, 198, 233, 143, 84, 164, - 193, 104, 72, 43, 195, 49, 214, 8, 143, 216, - 49, 226, 157, 197, 208, 70, 251, 216, 193, 5, - 2, 100, 160, 10, 129, 64, 4, 54, 54, 81, - 2, 24, 148, 128, 6, 48, 160, 193, 81, 3, - 202, 0, 115, 120, 99, 19, 19, 40, 128, 1, - 74, 208, 79, 6, 20, 32, 12, 222, 8, 133, - 45, 136, 241, 141, 103, 232, 194, 84, 143, 72, - 195, 15, 196, 112, 9, 87, 248, 226, 22, 28, - 58, 3, 20, 183, 71, 144, 89, 16, 201, 163, - 145, 185, 68, 74, 7, 145, 130, 106, 140, 83, - 15, 136, 40, 131, 181, 154, 48, 6, 111, 140, - 145, 61, 173, 72, 214, 131, 210, 83, 41, 2, - 160, 128, 12, 140, 104, 68, 57, 220, 80, 212, - 106, 224, 50, 151, 250, 248, 69, 9, 24, 208, - 6, 126, 28, 225, 2, 1, 32, 70, 53, 126, - 193, 88, 1, 0, 96, 17, 165, 96, 2, 65, - 113, 16, 6, 76, 96, 98, 27, 202, 16, 43, - 89, 51, 193, 10, 82, 108, 174, 58, 38, 144, - 254, 228, 203, 134, 4, 87, 200, 220, 1, 11, - 64, 160, 66, 16, 12, 80, 128, 118, 216, 195, - 5, 141, 40, 31, 182, 216, 145, 30, 23, 181, - 135, 149, 212, 8, 19, 60, 188, 145, 0, 4, - 100, 225, 19, 59, 155, 7, 13, 78, 80, 130, - 109, 60, 67, 24, 141, 128, 67, 33, 204, 81, - 130, 2, 84, 224, 30, 37, 152, 128, 4, 242, - 113, 167, 121, 216, 162, 152, 39, 120, 6, 8, - 4, 192, 128, 13, 112, 160, 159, 6, 192, 68, - 41, 122, 240, 131, 65, 0, 2, 16, 115, 48, - 171, 51, 238, 3, 69, 41, 254, 195, 173, 181, - 125, 12, 31, 122, 0, 132, 25, 248, 192, 3, - 211, 56, 0, 13, 54, 145, 5, 50, 236, 149, - 126, 236, 104, 17, 60, 186, 113, 44, 73, 73, - 120, 29, 174, 136, 37, 28, 102, 215, 10, 121, - 208, 192, 13, 71, 72, 135, 50, 38, 22, 133, - 66, 164, 163, 187, 12, 216, 6, 7, 24, 112, - 132, 114, 192, 33, 13, 144, 248, 69, 1, 0, - 112, 2, 98, 126, 54, 30, 211, 32, 6, 26, - 120, 11, 12, 32, 244, 64, 12, 115, 240, 195, - 18, 174, 0, 8, 87, 144, 226, 20, 164, 147, - 76, 36, 3, 48, 82, 243, 4, 120, 42, 3, - 182, 193, 10, 86, 48, 3, 18, 20, 32, 0, - 2, 32, 129, 26, 200, 80, 133, 194, 53, 129, - 12, 236, 160, 17, 60, 210, 7, 11, 113, 172, - 227, 204, 225, 144, 129, 254, 97, 65, 33, 12, - 129, 165, 131, 3, 55, 112, 131, 45, 142, 81, - 5, 42, 188, 225, 17, 237, 88, 241, 2, 36, - 107, 128, 69, 196, 66, 13, 130, 120, 6, 26, - 60, 187, 136, 106, 120, 22, 23, 186, 224, 90, - 60, 12, 0, 0, 78, 76, 161, 7, 88, 152, - 67, 16, 92, 176, 4, 34, 92, 97, 11, 91, - 200, 132, 53, 204, 35, 153, 51, 72, 146, 94, - 255, 120, 242, 84, 60, 177, 4, 41, 171, 64, - 5, 59, 0, 2, 5, 18, 128, 1, 56, 220, - 236, 90, 189, 83, 3, 59, 206, 97, 230, 102, - 64, 55, 23, 201, 61, 179, 55, 26, 128, 128, - 52, 188, 162, 24, 204, 128, 196, 52, 56, 0, - 131, 77, 88, 67, 24, 132, 64, 196, 33, 212, - 241, 139, 11, 20, 224, 8, 104, 184, 128, 0, - 170, 129, 8, 53, 100, 193, 25, 16, 0, 0, - 0, 182, 49, 104, 6, 36, 67, 153, 143, 184, - 68, 2, 0, 192, 133, 52, 160, 0, 11, 87, - 120, 129, 11, 88, 192, 110, 18, 144, 128, 8, - 153, 118, 70, 162, 34, 99, 129, 40, 10, 196, - 164, 128, 232, 193, 10, 98, 16, 131, 29, 248, - 27, 8, 133, 224, 32, 33, 132, 123, 173, 70, - 172, 35, 141, 235, 64, 6, 116, 97, 65, 172, - 51, 103, 98, 0, 25, 120, 133, 48, 218, 163, - 138, 84, 252, 51, 27, 232, 160, 6, 51, 160, - 193, 142, 108, 28, 97, 2, 12, 176, 7, 18, - 254, 250, 136, 142, 14, 102, 161, 19, 140, 102, - 64, 59, 178, 189, 1, 109, 188, 34, 20, 133, - 240, 131, 103, 57, 113, 136, 31, 44, 97, 14, - 91, 32, 1, 187, 89, 224, 110, 23, 144, 160, - 8, 96, 240, 3, 46, 146, 44, 149, 15, 4, - 96, 1, 247, 174, 206, 41, 176, 96, 131, 29, - 240, 32, 6, 42, 224, 247, 14, 124, 16, 5, - 58, 88, 221, 193, 85, 240, 2, 51, 194, 113, - 142, 110, 72, 40, 23, 202, 233, 70, 179, 202, - 209, 1, 2, 212, 129, 25, 108, 202, 133, 55, - 208, 192, 129, 18, 152, 227, 30, 230, 216, 6, - 49, 156, 64, 108, 8, 164, 226, 30, 48, 152, - 192, 6, 158, 65, 7, 53, 88, 1, 9, 158, - 61, 194, 52, 102, 76, 12, 109, 8, 35, 22, - 144, 232, 196, 161, 225, 32, 134, 43, 92, 161, - 8, 47, 120, 1, 17, 212, 237, 110, 12, 252, - 28, 211, 156, 128, 140, 18, 36, 41, 144, 215, - 194, 198, 19, 115, 0, 194, 10, 84, 192, 131, - 33, 240, 187, 223, 62, 160, 66, 178, 7, 14, - 49, 50, 208, 233, 96, 231, 152, 16, 123, 230, - 83, 142, 12, 59, 32, 22, 26, 103, 70, 43, - 230, 1, 130, 182, 95, 128, 6, 19, 184, 64, - 240, 139, 234, 134, 120, 84, 99, 197, 109, 240, - 134, 26, 232, 80, 7, 11, 104, 123, 27, 72, - 0, 192, 6, 228, 49, 14, 61, 165, 131, 6, - 0, 144, 0, 43, 4, 254, 49, 136, 43, 16, - 33, 8, 30, 136, 60, 188, 225, 237, 238, 23, - 20, 97, 11, 153, 127, 204, 230, 3, 240, 223, - 234, 140, 2, 11, 83, 142, 58, 15, 202, 80, - 133, 167, 199, 96, 8, 141, 128, 155, 33, 62, - 65, 6, 67, 112, 29, 26, 21, 114, 14, 204, - 144, 83, 212, 112, 14, 222, 80, 118, 98, 128, - 12, 180, 35, 12, 185, 32, 15, 16, 0, 103, - 71, 0, 98, 71, 0, 3, 48, 224, 6, 219, - 48, 15, 143, 32, 9, 28, 48, 1, 188, 80, - 14, 84, 160, 6, 137, 192, 104, 23, 144, 14, - 217, 38, 1, 188, 112, 130, 188, 0, 3, 152, - 149, 10, 230, 50, 8, 150, 22, 4, 50, 0, - 6, 91, 64, 4, 46, 224, 2, 145, 7, 126, - 65, 16, 4, 91, 128, 11, 234, 199, 121, 255, - 16, 23, 178, 81, 7, 82, 32, 2, 168, 22, - 3, 62, 48, 4, 100, 160, 6, 79, 23, 5, - 135, 240, 10, 173, 48, 45, 251, 7, 13, 231, - 160, 38, 102, 118, 14, 117, 82, 39, 126, 0, - 113, 186, 128, 12, 12, 88, 11, 185, 176, 13, - 19, 112, 3, 37, 192, 15, 185, 84, 15, 243, - 16, 15, 234, 112, 12, 136, 80, 10, 237, 64, - 12, 196, 112, 15, 215, 64, 5, 112, 128, 11, - 22, 208, 103, 182, 32, 1, 0, 192, 0, 239, - 5, 80, 23, 208, 6, 207, 80, 8, 96, 3, - 111, 70, 128, 6, 118, 192, 4, 96, 0, 121, - 254, 36, 240, 2, 96, 176, 33, 150, 192, 5, - 92, 224, 43, 235, 39, 16, 103, 224, 121, 144, - 49, 10, 63, 48, 3, 163, 23, 3, 195, 243, - 129, 101, 160, 6, 169, 247, 10, 200, 0, 10, - 204, 209, 10, 194, 16, 14, 201, 195, 34, 7, - 151, 12, 225, 0, 12, 10, 224, 0, 147, 160, - 13, 180, 227, 133, 208, 240, 11, 196, 230, 6, - 253, 112, 12, 159, 208, 119, 86, 103, 8, 214, - 246, 10, 209, 80, 14, 209, 0, 10, 67, 0, - 7, 227, 16, 15, 247, 192, 15, 72, 192, 91, - 246, 176, 13, 169, 176, 8, 110, 144, 10, 214, - 5, 61, 35, 227, 2, 91, 32, 3, 86, 33, - 21, 92, 0, 6, 47, 224, 1, 50, 32, 10, - 176, 17, 137, 63, 72, 137, 142, 113, 10, 98, - 208, 116, 81, 199, 111, 60, 64, 5, 143, 83, - 6, 67, 160, 6, 177, 16, 14, 208, 160, 13, - 106, 194, 12, 200, 160, 12, 218, 112, 12, 82, - 152, 12, 187, 160, 10, 151, 64, 1, 8, 240, - 3, 10, 184, 51, 148, 208, 10, 139, 85, 2, - 37, 176, 9, 253, 32, 12, 134, 80, 6, 251, - 83, 62, 84, 144, 45, 141, 64, 8, 84, 192, - 3, 158, 8, 4, 86, 64, 10, 28, 32, 0, - 56, 224, 13, 194, 176, 11, 222, 80, 14, 202, - 16, 10, 135, 32, 46, 141, 7, 111, 45, 224, - 24, 145, 144, 9, 91, 0, 6, 70, 0, 6, - 112, 101, 116, 72, 247, 254, 15, 123, 112, 6, - 176, 65, 11, 63, 176, 111, 59, 208, 111, 154, - 216, 142, 135, 0, 10, 136, 16, 10, 194, 160, - 13, 201, 160, 13, 117, 34, 14, 208, 128, 12, - 186, 208, 11, 187, 112, 9, 128, 224, 1, 20, - 64, 0, 8, 96, 3, 203, 1, 11, 159, 112, - 83, 175, 80, 15, 52, 208, 118, 196, 144, 15, - 185, 32, 66, 67, 80, 5, 100, 64, 7, 81, - 83, 56, 85, 48, 3, 20, 233, 3, 54, 208, - 3, 157, 192, 0, 0, 64, 12, 208, 0, 10, - 63, 4, 7, 202, 54, 146, 133, 48, 7, 151, - 64, 4, 96, 112, 146, 144, 225, 7, 96, 192, - 5, 226, 40, 21, 245, 38, 69, 158, 48, 23, - 145, 97, 10, 115, 96, 3, 34, 48, 122, 231, - 88, 122, 112, 160, 6, 165, 16, 11, 161, 112, - 12, 202, 112, 9, 151, 16, 14, 226, 32, 143, - 244, 40, 6, 24, 224, 0, 8, 128, 0, 17, - 128, 2, 135, 128, 66, 173, 64, 9, 140, 64, - 9, 185, 208, 15, 196, 144, 10, 191, 192, 15, - 236, 0, 10, 114, 96, 56, 93, 32, 7, 73, - 120, 67, 80, 64, 5, 59, 128, 132, 84, 0, - 4, 107, 48, 104, 5, 240, 13, 194, 0, 10, - 111, 0, 4, 64, 32, 57, 105, 128, 46, 171, - 48, 7, 223, 39, 4, 145, 1, 132, 157, 246, - 105, 2, 49, 11, 115, 33, 142, 167, 240, 3, - 54, 224, 3, 153, 152, 56, 80, 243, 6, 112, - 254, 0, 138, 177, 32, 12, 208, 160, 10, 106, - 130, 13, 0, 24, 14, 197, 128, 148, 107, 208, - 3, 86, 32, 138, 202, 193, 51, 85, 121, 83, - 173, 112, 14, 229, 192, 14, 234, 80, 14, 173, - 160, 87, 101, 0, 60, 33, 148, 132, 112, 32, - 60, 60, 48, 3, 184, 233, 3, 170, 224, 75, - 237, 128, 13, 79, 72, 5, 84, 246, 45, 83, - 0, 136, 221, 71, 4, 50, 64, 147, 29, 178, - 100, 35, 37, 147, 132, 249, 24, 137, 128, 152, - 43, 224, 111, 57, 121, 132, 92, 4, 7, 161, - 160, 12, 111, 162, 11, 115, 32, 153, 199, 176, - 117, 63, 83, 158, 244, 8, 10, 148, 48, 144, - 237, 25, 8, 44, 26, 8, 114, 16, 8, 169, - 193, 8, 11, 41, 56, 133, 195, 3, 244, 99, - 117, 84, 80, 5, 80, 192, 111, 244, 195, 63, - 64, 16, 10, 186, 32, 12, 5, 234, 3, 49, - 48, 3, 195, 153, 6, 88, 48, 50, 240, 246, - 1, 73, 178, 7, 253, 213, 86, 90, 224, 160, - 142, 33, 6, 33, 48, 101, 254, 118, 67, 169, - 39, 8, 175, 208, 132, 210, 179, 11, 189, 176, - 5, 202, 160, 12, 107, 194, 117, 83, 216, 10, - 180, 83, 149, 44, 234, 5, 99, 224, 5, 127, - 224, 5, 110, 58, 6, 178, 89, 6, 74, 51, - 49, 80, 192, 144, 246, 83, 6, 159, 210, 119, - 166, 55, 75, 12, 57, 3, 213, 201, 132, 160, - 160, 6, 81, 48, 4, 254, 51, 48, 3, 89, - 96, 68, 73, 234, 125, 65, 96, 2, 73, 18, - 91, 1, 240, 50, 255, 160, 8, 81, 234, 24, - 142, 176, 4, 33, 32, 2, 137, 57, 3, 84, - 0, 5, 29, 84, 53, 64, 154, 42, 170, 144, - 9, 92, 112, 9, 165, 16, 143, 196, 98, 133, - 12, 184, 51, 104, 170, 166, 99, 176, 166, 115, - 227, 162, 173, 154, 52, 247, 217, 101, 89, 87, - 6, 132, 208, 8, 62, 89, 5, 67, 144, 147, - 19, 195, 3, 43, 96, 3, 81, 240, 10, 141, - 160, 6, 95, 217, 159, 126, 106, 3, 71, 36, - 6, 68, 80, 4, 50, 144, 36, 106, 21, 0, - 108, 5, 165, 147, 42, 21, 166, 96, 169, 83, - 214, 111, 137, 83, 5, 206, 3, 10, 161, 48, - 61, 170, 224, 7, 32, 0, 1, 50, 0, 9, - 186, 64, 39, 86, 104, 120, 202, 161, 170, 140, - 224, 166, 106, 250, 7, 109, 234, 166, 49, 228, - 5, 134, 224, 5, 73, 67, 63, 114, 80, 5, - 183, 154, 58, 55, 164, 2, 177, 73, 6, 80, - 96, 164, 108, 214, 10, 92, 198, 63, 51, 16, - 2, 6, 75, 95, 138, 42, 165, 248, 1, 82, - 34, 117, 16, 166, 80, 23, 155, 115, 11, 87, - 96, 161, 51, 192, 111, 156, 170, 108, 160, 32, - 61, 171, 192, 10, 32, 16, 124, 48, 208, 9, - 189, 128, 148, 208, 16, 14, 176, 72, 59, 55, - 69, 154, 129, 192, 166, 127, 176, 166, 114, 163, - 254, 166, 94, 0, 49, 77, 192, 3, 73, 208, - 4, 115, 67, 6, 160, 128, 171, 132, 160, 6, - 60, 10, 49, 60, 96, 3, 112, 112, 179, 100, - 16, 8, 236, 8, 4, 54, 96, 176, 33, 128, - 2, 40, 192, 2, 68, 160, 4, 213, 116, 77, - 9, 33, 169, 90, 48, 21, 115, 160, 111, 153, - 184, 3, 114, 136, 58, 135, 208, 173, 171, 224, - 10, 253, 132, 6, 81, 113, 10, 172, 240, 38, - 216, 160, 13, 242, 40, 164, 104, 250, 7, 129, - 224, 174, 129, 192, 8, 114, 208, 166, 134, 128, - 63, 17, 147, 56, 77, 32, 155, 132, 32, 138, - 136, 80, 5, 58, 11, 5, 47, 219, 5, 253, - 9, 7, 46, 74, 8, 236, 232, 3, 244, 133, - 2, 71, 139, 180, 44, 16, 4, 73, 178, 100, - 148, 164, 16, 121, 80, 23, 82, 225, 10, 55, - 153, 137, 70, 168, 6, 136, 32, 8, 47, 86, - 8, 165, 160, 9, 19, 96, 6, 142, 193, 7, - 163, 176, 11, 202, 192, 117, 242, 232, 78, 108, - 235, 174, 238, 58, 6, 104, 203, 170, 73, 227, - 5, 73, 48, 179, 65, 139, 171, 175, 80, 109, - 84, 80, 52, 178, 217, 4, 187, 58, 4, 217, - 82, 5, 83, 99, 5, 61, 128, 180, 190, 203, - 2, 46, 192, 180, 78, 36, 73, 254, 197, 184, - 117, 145, 7, 180, 192, 116, 138, 201, 111, 133, - 74, 117, 89, 112, 8, 186, 160, 9, 23, 16, - 25, 159, 171, 83, 240, 254, 120, 66, 104, 58, - 6, 129, 176, 166, 174, 10, 167, 100, 80, 175, - 245, 138, 51, 160, 144, 11, 112, 153, 71, 47, - 84, 62, 49, 91, 122, 116, 0, 60, 81, 0, - 4, 152, 122, 180, 75, 144, 1, 25, 112, 184, - 17, 68, 188, 15, 209, 184, 90, 80, 173, 54, - 80, 168, 167, 39, 60, 22, 243, 6, 208, 43, - 189, 146, 49, 10, 218, 112, 174, 19, 119, 44, - 60, 67, 186, 45, 234, 162, 114, 80, 175, 93, - 86, 6, 159, 0, 10, 177, 11, 7, 81, 112, - 132, 47, 75, 175, 78, 99, 52, 60, 160, 2, - 86, 90, 168, 54, 176, 4, 46, 144, 1, 87, - 112, 141, 213, 113, 6, 245, 102, 111, 16, 33, - 169, 138, 48, 177, 152, 184, 147, 19, 153, 122, - 28, 154, 12, 156, 48, 189, 146, 241, 12, 87, - 8, 13, 26, 215, 30, 237, 89, 11, 200, 128, - 12, 178, 3, 93, 235, 234, 5, 101, 144, 132, - 208, 149, 41, 21, 252, 144, 220, 27, 60, 117, - 250, 116, 161, 228, 163, 132, 116, 5, 46, 144, - 8, 248, 161, 4, 11, 32, 73, 139, 27, 17, - 166, 240, 5, 144, 208, 3, 251, 187, 111, 165, - 39, 135, 136, 240, 10, 146, 41, 192, 146, 113, - 10, 231, 96, 133, 212, 32, 12, 112, 195, 162, - 104, 27, 8, 173, 0, 55, 183, 214, 10, 55, - 85, 149, 79, 200, 173, 144, 99, 96, 170, 35, - 92, 192, 51, 4, 116, 64, 127, 161, 244, 129, - 254, 83, 80, 156, 147, 16, 100, 222, 8, 91, - 80, 116, 0, 103, 51, 17, 193, 192, 10, 145, - 123, 161, 6, 118, 181, 175, 240, 38, 153, 64, - 195, 53, 76, 178, 218, 128, 12, 185, 80, 149, - 109, 251, 7, 132, 32, 7, 134, 240, 7, 49, - 180, 182, 107, 11, 187, 91, 122, 8, 82, 96, - 3, 89, 128, 8, 173, 208, 8, 154, 92, 6, - 141, 208, 8, 129, 96, 8, 3, 103, 117, 207, - 35, 81, 27, 203, 131, 212, 161, 4, 32, 21, - 0, 18, 0, 169, 18, 49, 14, 107, 128, 137, - 251, 150, 122, 87, 43, 12, 245, 8, 12, 27, - 240, 151, 82, 241, 12, 218, 64, 13, 56, 44, - 12, 181, 192, 8, 105, 123, 83, 210, 44, 55, - 160, 204, 162, 148, 64, 48, 185, 16, 10, 161, - 80, 68, 105, 48, 190, 114, 76, 205, 55, 149, - 79, 172, 71, 45, 112, 208, 8, 163, 178, 10, - 201, 128, 203, 176, 161, 5, 39, 60, 73, 30, - 49, 8, 82, 230, 197, 95, 169, 202, 109, 162, - 12, 192, 64, 3, 150, 0, 27, 201, 35, 12, - 108, 34, 12, 210, 220, 162, 55, 229, 162, 110, - 26, 203, 238, 249, 198, 177, 160, 12, 144, 48, - 8, 177, 112, 12, 194, 0, 148, 205, 1, 55, - 210, 44, 205, 229, 67, 7, 201, 6, 42, 12, - 148, 12, 190, 0, 27, 124, 240, 1, 80, 20, - 0, 46, 243, 17, 170, 96, 5, 133, 122, 155, - 31, 168, 202, 14, 141, 254, 12, 189, 128, 4, - 146, 32, 25, 124, 160, 13, 171, 44, 144, 45, - 106, 8, 134, 240, 162, 11, 188, 182, 208, 149, - 66, 229, 169, 13, 151, 160, 10, 247, 88, 10, - 68, 89, 182, 85, 233, 96, 194, 101, 209, 81, - 160, 108, 151, 211, 11, 192, 240, 24, 168, 192, - 7, 42, 243, 209, 11, 144, 200, 30, 145, 12, - 105, 80, 168, 205, 171, 6, 231, 252, 10, 151, - 179, 11, 156, 112, 4, 252, 188, 198, 100, 112, - 205, 46, 26, 208, 114, 243, 162, 238, 233, 133, - 104, 87, 143, 47, 192, 10, 202, 80, 10, 200, - 64, 148, 225, 160, 198, 104, 26, 8, 179, 137, - 183, 114, 120, 8, 166, 162, 212, 190, 66, 43, - 158, 115, 0, 243, 194, 21, 127, 232, 167, 51, - 224, 111, 84, 87, 203, 165, 176, 11, 154, 0, - 3, 220, 244, 24, 189, 16, 206, 14, 214, 182, - 11, 108, 8, 105, 107, 211, 239, 36, 12, 150, - 29, 39, 30, 176, 5, 172, 208, 11, 14, 205, - 12, 218, 80, 11, 235, 73, 9, 44, 42, 155, - 134, 128, 49, 181, 60, 9, 170, 48, 10, 230, - 161, 5, 31, 240, 0, 125, 253, 0, 160, 182, - 23, 147, 64, 180, 23, 58, 117, 84, 23, 5, - 130, 112, 42, 174, 0, 3, 150, 240, 151, 171, - 144, 58, 1, 205, 174, 114, 80, 205, 160, 108, - 214, 3, 25, 209, 185, 160, 13, 202, 208, 0, - 3, 224, 1, 151, 32, 166, 152, 57, 48, 134, - 254, 112, 83, 16, 115, 45, 114, 184, 6, 125, - 112, 7, 123, 160, 5, 241, 178, 0, 125, 61, - 2, 216, 196, 23, 144, 80, 96, 21, 91, 177, - 253, 19, 5, 83, 112, 216, 192, 80, 2, 95, - 96, 23, 82, 234, 9, 165, 128, 8, 65, 27, - 180, 110, 74, 8, 163, 221, 182, 54, 157, 205, - 181, 192, 128, 185, 240, 10, 208, 160, 11, 13, - 160, 0, 24, 0, 6, 208, 32, 158, 208, 208, - 30, 234, 42, 223, 85, 144, 5, 216, 45, 23, - 57, 208, 218, 44, 227, 221, 22, 240, 4, 90, - 241, 29, 170, 64, 157, 215, 170, 147, 196, 147, - 208, 201, 128, 4, 102, 96, 25, 32, 94, 23, - 147, 120, 7, 125, 176, 6, 113, 160, 6, 214, - 60, 55, 106, 122, 223, 114, 4, 79, 39, 148, - 11, 255, 77, 1, 20, 112, 5, 170, 48, 182, - 205, 12, 205, 159, 64, 57, 120, 144, 221, 219, - 157, 3, 38, 80, 43, 101, 195, 50, 19, 238, - 203, 189, 1, 185, 243, 188, 188, 62, 48, 5, - 202, 128, 13, 201, 192, 6, 110, 224, 86, 121, - 0, 226, 82, 174, 4, 34, 126, 6, 36, 222, - 7, 120, 96, 226, 220, 226, 56, 17, 44, 154, - 151, 227, 148, 118, 201, 10, 124, 50, 10, 142, - 176, 33, 215, 225, 227, 77, 2, 228, 182, 242, - 0, 53, 240, 5, 68, 94, 34, 229, 120, 169, - 137, 169, 2, 6, 150, 5, 229, 186, 206, 48, - 64, 16, 166, 160, 8, 192, 81, 62, 229, 32, - 142, 25, 84, 238, 222, 115, 49, 232, 132, 110, - 23, 215, 113, 25, 218, 17, 34, 78, 178, 232, - 181, 98, 1, 109, 30, 32, 37, 162, 16, 151, - 64, 184, 152, 26, 127, 73, 94, 10, 73, 9, - 12, 56, 128, 16, 218, 148, 7, 121, 240, 5, - 182, 17, 234, 162, 158, 3, 184, 129, 27, 218, - 113, 234, 218, 209, 31, 253, 17, 34, 172, 206, - 232, 38, 160, 3, 0, 82, 225, 145, 206, 16, - 148, 142, 169, 116, 126, 164, 186, 144, 12, 187, - 237, 16, 150, 20, 9, 118, 96, 7, 95, 240, - 5, 216, 145, 29, 168, 158, 234, 170, 174, 1, - 31, 160, 3, 184, 17, 236, 120, 33, 235, 179, - 254, 16, 144, 75, 184, 136, 153, 106, 22, 185, - 6, 147, 192, 10, 174, 176, 1, 60, 65, 19, - 145, 240, 230, 207, 222, 17, 128, 64, 184, 33, - 96, 164, 86, 144, 6, 225, 226, 165, 154, 32, - 1, 223, 190, 238, 21, 225, 10, 75, 128, 2, - 54, 240, 3, 66, 148, 6, 228, 178, 11, 192, - 192, 4, 236, 158, 239, 2, 17, 16, 0, 59}; - diff --git a/main/main.c b/main/main.c index cc04b1317e991..5eb9947fe7a5c 100644 --- a/main/main.c +++ b/main/main.c @@ -86,7 +86,6 @@ #include "php_content_types.h" #include "php_ticks.h" -#include "php_logos.h" #include "php_streams.h" #include "php_open_temporary_file.h" @@ -2157,14 +2156,6 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod return FAILURE; } - /* initialize registry for images to be used in phpinfo() - (this uses configuration parameters from php.ini) - */ - if (php_init_info_logos() == FAILURE) { - php_printf("PHP: Unable to initialize info phpinfo logos.\n"); - return FAILURE; - } - zuv.html_errors = 1; zuv.import_use_extension = ".php"; php_startup_auto_globals(TSRMLS_C); @@ -2348,7 +2339,6 @@ void php_module_shutdown(TSRMLS_D) /* Destroys filter & transport registries too */ php_shutdown_stream_wrappers(module_number TSRMLS_CC); - php_shutdown_info_logos(); UNREGISTER_INI_ENTRIES(); /* close down the ini config */ @@ -2396,10 +2386,6 @@ PHPAPI int php_execute_script(zend_file_handle *primary_file TSRMLS_DC) int retval = 0; EG(exit_status) = 0; - if (php_handle_special_queries(TSRMLS_C)) { - zend_file_handle_dtor(primary_file TSRMLS_CC); - return 0; - } #ifndef HAVE_BROKEN_GETCWD # define OLD_CWD_SIZE 4096 old_cwd = do_alloca(OLD_CWD_SIZE, use_heap); diff --git a/main/php_logos.c b/main/php_logos.c deleted file mode 100644 index 3689f71e9533f..0000000000000 --- a/main/php_logos.c +++ /dev/null @@ -1,99 +0,0 @@ -/* - +----------------------------------------------------------------------+ - | PHP Version 5 | - +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | - +----------------------------------------------------------------------+ - | This source file is subject to version 3.01 of the PHP license, | - | that is bundled with this package in the file LICENSE, and is | - | available through the world-wide-web at the following url: | - | http://www.php.net/license/3_01.txt | - | If you did not receive a copy of the PHP license and are unable to | - | obtain it through the world-wide-web, please send a note to | - | license@php.net so we can mail you a copy immediately. | - +----------------------------------------------------------------------+ - | Author: Hartmut Holzgraefe | - +----------------------------------------------------------------------+ -*/ - -/* $Id$ */ - -#include "php.h" -#include "logos.h" -#include "php_logos.h" -#include "ext/standard/info.h" -#include "SAPI.h" - -typedef struct _php_info_logo { - const char *mimetype; - int mimelen; - const unsigned char *data; - int size; -} php_info_logo; - -static HashTable phpinfo_logo_hash; - -PHPAPI int php_register_info_logo(char *logo_string, const char *mimetype, const unsigned char *data, int size) -{ - php_info_logo info_logo; - - info_logo.mimetype = mimetype; - info_logo.mimelen = strlen(mimetype); - info_logo.data = data; - info_logo.size = size; - - return zend_hash_add(&phpinfo_logo_hash, logo_string, strlen(logo_string), &info_logo, sizeof(php_info_logo), NULL); -} - -PHPAPI int php_unregister_info_logo(char *logo_string) -{ - return zend_hash_del(&phpinfo_logo_hash, logo_string, strlen(logo_string)); -} - -int php_init_info_logos(void) -{ - if(zend_hash_init(&phpinfo_logo_hash, 0, NULL, NULL, 1)==FAILURE) - return FAILURE; - - php_register_info_logo(PHP_LOGO_GUID , "image/gif", php_logo , sizeof(php_logo)); - php_register_info_logo(PHP_EGG_LOGO_GUID, "image/gif", php_egg_logo, sizeof(php_egg_logo)); - php_register_info_logo(ZEND_LOGO_GUID , "image/gif", zend_logo , sizeof(zend_logo)); - - return SUCCESS; -} - -int php_shutdown_info_logos(void) -{ - zend_hash_destroy(&phpinfo_logo_hash); - return SUCCESS; -} - -#define CONTENT_TYPE_HEADER "Content-Type: " -int php_info_logos(const char *logo_string TSRMLS_DC) -{ - php_info_logo *logo_image; - char *content_header; - int len; - - if(FAILURE==zend_hash_find(&phpinfo_logo_hash, (char *) logo_string, strlen(logo_string), (void **)&logo_image)) - return 0; - - len = sizeof(CONTENT_TYPE_HEADER) - 1 + logo_image->mimelen; - content_header = emalloc(len + 1); - memcpy(content_header, CONTENT_TYPE_HEADER, sizeof(CONTENT_TYPE_HEADER) - 1); - memcpy(content_header + sizeof(CONTENT_TYPE_HEADER) - 1 , logo_image->mimetype, logo_image->mimelen); - content_header[len] = '\0'; - sapi_add_header(content_header, len, 0); - - PHPWRITE((char*)logo_image->data, logo_image->size); - return 1; -} - -/* - * Local variables: - * tab-width: 4 - * c-basic-offset: 4 - * End: - * vim600: sw=4 ts=4 fdm=marker - * vim<600: sw=4 ts=4 - */ diff --git a/main/php_logos.h b/main/php_logos.h deleted file mode 100644 index b9e1144c03123..0000000000000 --- a/main/php_logos.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - +----------------------------------------------------------------------+ - | PHP Version 5 | - +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | - +----------------------------------------------------------------------+ - | This source file is subject to version 3.01 of the PHP license, | - | that is bundled with this package in the file LICENSE, and is | - | available through the world-wide-web at the following url: | - | http://www.php.net/license/3_01.txt | - | If you did not receive a copy of the PHP license and are unable to | - | obtain it through the world-wide-web, please send a note to | - | license@php.net so we can mail you a copy immediately. | - +----------------------------------------------------------------------+ - | Author: | - +----------------------------------------------------------------------+ -*/ - -/* $Id$ */ - - -#ifndef _PHP_LOGOS_H -#define _PHP_LOGOS_H - -BEGIN_EXTERN_C() -PHPAPI int php_register_info_logo(char *logo_string, const char *mimetype, const unsigned char *data, int size); -PHPAPI int php_unregister_info_logo(char *logo_string); -END_EXTERN_C() - -int php_init_info_logos(void); -int php_shutdown_info_logos(void); -int php_info_logos(const char *logo_string TSRMLS_DC); - -#endif /* _PHP_LOGOS_H */ diff --git a/main/php_variables.c b/main/php_variables.c index 427966170c8f3..9952bd80bc8d6 100644 --- a/main/php_variables.c +++ b/main/php_variables.c @@ -27,7 +27,6 @@ #include "php_globals.h" #include "php_content_types.h" #include "SAPI.h" -#include "php_logos.h" #include "zend_globals.h" /* for systems that need to override reading of environment variables */ @@ -532,22 +531,6 @@ static void php_build_argv(char *s, zval *track_vars_array TSRMLS_DC) } /* }}} */ -/* {{{ php_handle_special_queries - */ -PHPAPI int php_handle_special_queries(TSRMLS_D) -{ - if (PG(expose_php) && SG(request_info).query_string && SG(request_info).query_string[0] == '=') { - if (php_info_logos(SG(request_info).query_string + 1 TSRMLS_CC)) { - return 1; - } else if (!strcmp(SG(request_info).query_string + 1, PHP_CREDITS_GUID)) { - php_print_credits(PHP_CREDITS_ALL TSRMLS_CC); - return 1; - } - } - return 0; -} -/* }}} */ - /* {{{ php_register_server_variables */ static inline void php_register_server_variables(TSRMLS_D) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 876c57a34d491..05c2cdabc321e 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -1944,40 +1944,38 @@ static int php_cli_server_request_shutdown(php_cli_server *server, php_cli_serve static int php_cli_server_dispatch_router(php_cli_server *server, php_cli_server_client *client TSRMLS_DC) /* {{{ */ { int decline = 0; - if (!php_handle_special_queries(TSRMLS_C)) { - zend_file_handle zfd; - char *old_cwd; - - ALLOCA_FLAG(use_heap) - old_cwd = do_alloca(MAXPATHLEN, use_heap); - old_cwd[0] = '\0'; - php_ignore_value(VCWD_GETCWD(old_cwd, MAXPATHLEN - 1)); - - zfd.type = ZEND_HANDLE_FILENAME; - zfd.filename = server->router; - zfd.handle.fp = NULL; - zfd.free_filename = 0; - zfd.opened_path = NULL; - - zend_try { - zval *retval = NULL; - if (SUCCESS == zend_execute_scripts(ZEND_REQUIRE TSRMLS_CC, &retval, 1, &zfd)) { - if (retval) { - decline = Z_TYPE_P(retval) == IS_BOOL && !Z_LVAL_P(retval); - zval_ptr_dtor(&retval); - } - } else { - decline = 1; + zend_file_handle zfd; + char *old_cwd; + + ALLOCA_FLAG(use_heap) + old_cwd = do_alloca(MAXPATHLEN, use_heap); + old_cwd[0] = '\0'; + php_ignore_value(VCWD_GETCWD(old_cwd, MAXPATHLEN - 1)); + + zfd.type = ZEND_HANDLE_FILENAME; + zfd.filename = server->router; + zfd.handle.fp = NULL; + zfd.free_filename = 0; + zfd.opened_path = NULL; + + zend_try { + zval *retval = NULL; + if (SUCCESS == zend_execute_scripts(ZEND_REQUIRE TSRMLS_CC, &retval, 1, &zfd)) { + if (retval) { + decline = Z_TYPE_P(retval) == IS_BOOL && !Z_LVAL_P(retval); + zval_ptr_dtor(&retval); } - } zend_end_try(); - - if (old_cwd[0] != '\0') { - php_ignore_value(VCWD_CHDIR(old_cwd)); + } else { + decline = 1; } + } zend_end_try(); - free_alloca(old_cwd, use_heap); + if (old_cwd[0] != '\0') { + php_ignore_value(VCWD_CHDIR(old_cwd)); } + free_alloca(old_cwd, use_heap); + return decline; } /* }}} */ diff --git a/sapi/cli/tests/php_cli_server_011.phpt b/sapi/cli/tests/php_cli_server_011.phpt deleted file mode 100644 index a957a8ed4c0c3..0000000000000 --- a/sapi/cli/tests/php_cli_server_011.phpt +++ /dev/null @@ -1,41 +0,0 @@ ---TEST-- -Bug #60180 ($_SERVER["PHP_SELF"] incorrect) ---SKIPIF-- - ---FILE-- - ---EXPECTF-- -okey diff --git a/tests/basic/php_egg_logo_guid.phpt b/tests/basic/php_egg_logo_guid.phpt deleted file mode 100644 index b3c5d7bdfd2e4..0000000000000 --- a/tests/basic/php_egg_logo_guid.phpt +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -Testing php_egg_logo_guid() function ---FILE-- - ---EXPECT-- -PHPE9568F36-D428-11d2-A769-00AA001ACF42 - ---CREDITS-- -Jason Easter -PHPUG Würzburg -Testfest 2009 2009-06-20 \ No newline at end of file diff --git a/tests/basic/php_logo_guid.phpt b/tests/basic/php_logo_guid.phpt deleted file mode 100644 index b5724a96abe10..0000000000000 --- a/tests/basic/php_logo_guid.phpt +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Testing php_logo_guid() function ---FILE-- - ---EXPECT-- -PHPE9568F34-D428-11d2-A769-00AA001ACF42 ---CREDITS-- -Testfest 2009 2009-06-20 \ No newline at end of file diff --git a/tests/basic/php_real_logo_guid.phpt b/tests/basic/php_real_logo_guid.phpt deleted file mode 100644 index 2b9003a35066f..0000000000000 --- a/tests/basic/php_real_logo_guid.phpt +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -Testing php_real_logo_guid() function ---FILE-- - ---EXPECT-- -PHPE9568F34-D428-11d2-A769-00AA001ACF42 ---CREDITS-- -Jason Easter -PHPUG Würzburg -Testfest 2009 2009-06-20 \ No newline at end of file diff --git a/tests/basic/zend_logo_guid.phpt b/tests/basic/zend_logo_guid.phpt deleted file mode 100644 index 23ca0165ae64a..0000000000000 --- a/tests/basic/zend_logo_guid.phpt +++ /dev/null @@ -1,13 +0,0 @@ ---TEST-- -Testing zend_logo_guid() function ---FILE-- - ---EXPECT-- -PHPE9568F35-D428-11d2-A769-00AA001ACF42 - ---CREDITS-- -Jason Easter -PHPUG Würzburg -Testfest 2009 2009-06-20 \ No newline at end of file diff --git a/win32/build/config.w32 b/win32/build/config.w32 index 1a4b834be425d..be9402a3fec65 100644 --- a/win32/build/config.w32 +++ b/win32/build/config.w32 @@ -368,7 +368,7 @@ if (VCVERS == 1200) { ADD_SOURCES("main", "main.c snprintf.c spprintf.c getopt.c fopen_wrappers.c \ php_scandir.c php_ini.c SAPI.c rfc1867.c php_content_types.c strlcpy.c \ strlcat.c mergesort.c reentrancy.c php_variables.c php_ticks.c network.c \ - php_open_temporary_file.c php_logos.c output.c internal_functions.c php_sprintf.c"); + php_open_temporary_file.c output.c internal_functions.c php_sprintf.c"); ADD_SOURCES("win32", "inet.c fnmatch.c sockets.c"); // Newer versions have it diff --git a/win32/php5dll.dsp b/win32/php5dll.dsp index 2216d7dfe6e0a..cc56f538af1c9 100644 --- a/win32/php5dll.dsp +++ b/win32/php5dll.dsp @@ -164,10 +164,6 @@ SOURCE=..\main\php_ini.c # End Source File # Begin Source File -SOURCE=..\main\php_logos.c -# End Source File -# Begin Source File - SOURCE=..\main\php_open_temporary_file.c # End Source File # Begin Source File @@ -288,10 +284,6 @@ SOURCE=..\main\php_ini.h # End Source File # Begin Source File -SOURCE=..\main\php_logos.h -# End Source File -# Begin Source File - SOURCE=..\main\php_open_temporary_file.h # End Source File # Begin Source File diff --git a/win32/php5dllts.dsp b/win32/php5dllts.dsp index a8e93ec5e778c..3755ea79f9696 100644 --- a/win32/php5dllts.dsp +++ b/win32/php5dllts.dsp @@ -201,10 +201,6 @@ SOURCE=..\main\php_ini.c # End Source File # Begin Source File -SOURCE=..\main\php_logos.c -# End Source File -# Begin Source File - SOURCE=..\main\php_open_temporary_file.c # End Source File # Begin Source File @@ -317,10 +313,6 @@ SOURCE=..\main\php_ini.h # End Source File # Begin Source File -SOURCE=..\main\php_logos.h -# End Source File -# Begin Source File - SOURCE=..\main\php_main.h # End Source File # Begin Source File From 92d2aeb234146978ef1175767579ce3eb30d37fd Mon Sep 17 00:00:00 2001 From: Andrew Faulds Date: Sat, 14 Jul 2012 21:55:11 +0100 Subject: [PATCH 1932/2394] Fixed small misalignment in prev commit --- ext/standard/info.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/info.c b/ext/standard/info.c index 4f61b58d1faa0..b27468e3ebb96 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -809,7 +809,7 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) php_info_print(" document.getElementById('credits').style.display = 'block';\n"); php_info_print(" document.getElementById('revealcredits').style.display = 'none';\n"); php_info_print(" };\n"); - php_info_print(" };\n"); + php_info_print(" };\n"); php_info_print("}());\n"); php_info_print("

"); php_info_print("PHP Credits"); From 582514d4c7b216dbdc7a8429962cf3e5776206f0 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 10 Jul 2012 18:12:13 -0700 Subject: [PATCH 1933/2394] fix for bug#18556 - use simple tolower() function for internal things --- Zend/zend_operators.c | 92 ++++++++++++++++++++++++++++++++++++++++--- ext/standard/string.c | 6 +-- 2 files changed, 89 insertions(+), 9 deletions(-) diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index f9686251fef27..8805eb21e5692 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -42,6 +42,43 @@ static _locale_t current_locale = NULL; #define TYPE_PAIR(t1,t2) (((t1) << 4) | (t2)) +static unsigned char tolower_map[256] = { +0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f, +0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f, +0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,0x2f, +0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f, +0x40,0x61,0x62,0x63,0x64,0x65,0x66,0x67,0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x6f, +0x70,0x71,0x72,0x73,0x74,0x75,0x76,0x77,0x78,0x79,0x7a,0x5b,0x5c,0x5d,0x5e,0x5f, +0x60,0x61,0x62,0x63,0x64,0x65,0x66,0x67,0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x6f, +0x70,0x71,0x72,0x73,0x74,0x75,0x76,0x77,0x78,0x79,0x7a,0x7b,0x7c,0x7d,0x7e,0x7f, +0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f, +0x90,0x91,0x92,0x93,0x94,0x95,0x96,0x97,0x98,0x99,0x9a,0x9b,0x9c,0x9d,0x9e,0x9f, +0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf, +0xb0,0xb1,0xb2,0xb3,0xb4,0xb5,0xb6,0xb7,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,0xbe,0xbf, +0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf, +0xd0,0xd1,0xd2,0xd3,0xd4,0xd5,0xd6,0xd7,0xd8,0xd9,0xda,0xdb,0xdc,0xdd,0xde,0xdf, +0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,0xe8,0xe9,0xea,0xeb,0xec,0xed,0xee,0xef, +0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,0xfe,0xff +}; + +#define zend_tolower_ascii(c) (tolower_map[(c)]) + +/** + * Functions using locale lowercase: + zend_binary_strncasecmp_l + zend_binary_strcasecmp_l + zend_binary_zval_strcasecmp + zend_binary_zval_strncasecmp + string_compare_function_ex + string_case_compare_function + * Functions using ascii lowercase: + zend_str_tolower_copy + zend_str_tolower_dup + zend_str_tolower + zend_binary_strcasecmp + zend_binary_strncasecmp + */ + ZEND_API int zend_atoi(const char *str, int str_len) /* {{{ */ { int retval; @@ -1908,7 +1945,7 @@ ZEND_API char *zend_str_tolower_copy(char *dest, const char *source, unsigned in register unsigned char *end = str + length; while (str < end) { - *result++ = zend_tolower((int)*str++); + *result++ = zend_tolower_ascii((int)*str++); } *result = '\0'; @@ -1928,7 +1965,7 @@ ZEND_API void zend_str_tolower(char *str, unsigned int length) /* {{{ */ register unsigned char *end = p + length; while (p < end) { - *p = zend_tolower((int)*p); + *p = zend_tolower_ascii((int)*p); p++; } } @@ -1975,6 +2012,49 @@ ZEND_API int zend_binary_strcasecmp(const char *s1, uint len1, const char *s2, u return 0; } + len = MIN(len1, len2); + while (len--) { + c1 = zend_tolower_ascii((int)*(unsigned char *)s1++); + c2 = zend_tolower_ascii((int)*(unsigned char *)s2++); + if (c1 != c2) { + return c1 - c2; + } + } + + return len1 - len2; +} +/* }}} */ + +ZEND_API int zend_binary_strncasecmp(const char *s1, uint len1, const char *s2, uint len2, uint length) /* {{{ */ +{ + int len; + int c1, c2; + + if (s1 == s2) { + return 0; + } + len = MIN(length, MIN(len1, len2)); + while (len--) { + c1 = zend_tolower_ascii((int)*(unsigned char *)s1++); + c2 = zend_tolower_ascii((int)*(unsigned char *)s2++); + if (c1 != c2) { + return c1 - c2; + } + } + + return MIN(length, len1) - MIN(length, len2); +} +/* }}} */ + +ZEND_API int zend_binary_strcasecmp_l(const char *s1, uint len1, const char *s2, uint len2) /* {{{ */ +{ + int len; + int c1, c2; + + if (s1 == s2) { + return 0; + } + len = MIN(len1, len2); while (len--) { c1 = zend_tolower((int)*(unsigned char *)s1++); @@ -1988,7 +2068,7 @@ ZEND_API int zend_binary_strcasecmp(const char *s1, uint len1, const char *s2, u } /* }}} */ -ZEND_API int zend_binary_strncasecmp(const char *s1, uint len1, const char *s2, uint len2, uint length) /* {{{ */ +ZEND_API int zend_binary_strncasecmp_l(const char *s1, uint len1, const char *s2, uint len2, uint length) /* {{{ */ { int len; int c1, c2; @@ -2023,13 +2103,13 @@ ZEND_API int zend_binary_zval_strncmp(zval *s1, zval *s2, zval *s3) /* {{{ */ ZEND_API int zend_binary_zval_strcasecmp(zval *s1, zval *s2) /* {{{ */ { - return zend_binary_strcasecmp(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2)); + return zend_binary_strcasecmp_l(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2)); } /* }}} */ ZEND_API int zend_binary_zval_strncasecmp(zval *s1, zval *s2, zval *s3) /* {{{ */ { - return zend_binary_strncasecmp(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2), Z_LVAL_P(s3)); + return zend_binary_strncasecmp_l(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2), Z_LVAL_P(s3)); } /* }}} */ @@ -2064,7 +2144,7 @@ ZEND_API void zendi_smart_strcmp(zval *result, zval *s1, zval *s2) /* {{{ */ } else if (ret2!=IS_DOUBLE) { if (oflow1) { ZVAL_LONG(result, oflow1); - return; + return; } dval2 = (double) lval2; } else if (dval1 == dval2 && !zend_finite(dval1)) { diff --git a/ext/standard/string.c b/ext/standard/string.c index 9a64376c27e50..e5da0a4fb970a 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -13,7 +13,7 @@ | license@php.net so we can mail you a copy immediately. | +----------------------------------------------------------------------+ | Authors: Rasmus Lerdorf | - | Stig Sæther Bakken | + | Stig S�ther Bakken | | Zeev Suraski | +----------------------------------------------------------------------+ */ @@ -132,7 +132,7 @@ static char *php_bin2hex(const unsigned char *old, const size_t oldlen, size_t * size_t i, j; result = (unsigned char *) safe_emalloc(oldlen, 2 * sizeof(char), 1); - + for (i = j = 0; i < oldlen; i++) { result[j++] = hexconvtab[old[i] >> 4]; result[j++] = hexconvtab[old[i] & 15]; @@ -5376,7 +5376,7 @@ PHP_FUNCTION(substr_compare) if (!cs) { RETURN_LONG(zend_binary_strncmp(s1 + offset, (s1_len - offset), s2, s2_len, cmp_len)); } else { - RETURN_LONG(zend_binary_strncasecmp(s1 + offset, (s1_len - offset), s2, s2_len, cmp_len)); + RETURN_LONG(zend_binary_strncasecmp_l(s1 + offset, (s1_len - offset), s2, s2_len, cmp_len)); } } /* }}} */ From c164e6b5a37b668a016846060d8e039d6af32ae5 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 10 Jul 2012 21:47:56 -0700 Subject: [PATCH 1934/2394] add test --- Zend/tests/bug18556.phpt | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 Zend/tests/bug18556.phpt diff --git a/Zend/tests/bug18556.phpt b/Zend/tests/bug18556.phpt new file mode 100644 index 0000000000000..a9fbb592285aa --- /dev/null +++ b/Zend/tests/bug18556.phpt @@ -0,0 +1,36 @@ +--TEST-- +Bug #18556 (Setting locale to 'tr_TR' lowercases class names) +--FILE-- +foo = "Foo"; + } +} + +echo "Instantiating an infoBlob with a lowercase i\n"; +$foobar = new infoBlob(); +echo $foobar->foo; +echo "\nInstantiating an InfoBlob with an uppercase I\n"; +$foobar = new InfoBlob(); +echo $foobar->foo; +echo "\n"; +setlocale(LC_ALL, "tr_TR.utf8"); +foreach(get_declared_classes() as $class) +{ + if(!class_exists($class)) + echo "$class No Longer Exists!\n"; +} +echo "Done.\n"; +?> +--EXPECT-- +Instantiating an infoBlob with a lowercase i +Foo +Instantiating an InfoBlob with an uppercase I +Foo +Done. From 3b0573363a187e75414df72a0f3fe5c6f6c1be03 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 10 Jul 2012 22:31:24 -0700 Subject: [PATCH 1935/2394] fix comment --- ext/standard/string.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/string.c b/ext/standard/string.c index e5da0a4fb970a..6cc7659edd860 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -13,7 +13,7 @@ | license@php.net so we can mail you a copy immediately. | +----------------------------------------------------------------------+ | Authors: Rasmus Lerdorf | - | Stig S�ther Bakken | + | Stig Sæther Bakken | | Zeev Suraski | +----------------------------------------------------------------------+ */ @@ -132,7 +132,7 @@ static char *php_bin2hex(const unsigned char *old, const size_t oldlen, size_t * size_t i, j; result = (unsigned char *) safe_emalloc(oldlen, 2 * sizeof(char), 1); - + for (i = j = 0; i < oldlen; i++) { result[j++] = hexconvtab[old[i] >> 4]; result[j++] = hexconvtab[old[i] & 15]; From bd340b729622d74205ab6847d8009aa879c5529b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sat, 14 Jul 2012 15:03:51 -0700 Subject: [PATCH 1936/2394] add NEWS/UPGRADING --- NEWS | 1 + UPGRADING | 2 ++ UPGRADING.INTERNALS | 29 ++++++++++++++++++++++++++++- Zend/tests/bug18556.phpt | 1 + 4 files changed, 32 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 37e443d25e9f5..eb4b7dfe7bd7c 100644 --- a/NEWS +++ b/NEWS @@ -13,6 +13,7 @@ PHP NEWS - Core: . Added boolval(). (Jille Timmermans). + . Fixed bug #18556 (Engine uses locale rules to handle class names). (Stas) . Fixed bug #61681 (Malformed grammar). (Nikita Popov, Etienne, Laruence). . Fixed bug #61038 (unpack("a5", "str\0\0") does not work as expected). (srgoogleguy, Gustavo) diff --git a/UPGRADING b/UPGRADING index 8b52be26d75c0..d598996f30d26 100755 --- a/UPGRADING +++ b/UPGRADING @@ -21,6 +21,8 @@ PHP X.Y UPGRADE NOTES ======================================== - Drop Windows XP and 2003 support. (Pierre) +- All internal case insensitivity handling for class, fucntion and constant + names is done according to ASCII rules, current locale settings are ignored. ======================================== 2. New Features diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index 015c752ad0620..90c7a4394fd5d 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -4,6 +4,7 @@ UPGRADE NOTES - PHP X.Y 1. Internal API changes a. Streams pooling API + b. Lowercasing and locales 2. Build system changes a. Unix build system changes @@ -26,6 +27,32 @@ PHPAPI int php_stream_context_set_link(php_stream_context *context, PHPAPI int php_stream_context_del_link(php_stream_context *context, php_stream *stream); + b. Lowercasing and locales + +The lowercasing functions in zend_operators.c were split into those that do +lowercasing according to locale rules and those that do ASCII lowercasing. +ASCII: + + zend_str_tolower_copy + zend_str_tolower_dup + zend_str_tolower + zend_binary_strcasecmp + zend_binary_strncasecmp + +Locale-based: + zend_binary_strncasecmp_l + zend_binary_strcasecmp_l + zend_binary_zval_strcasecmp + zend_binary_zval_strncasecmp + string_compare_function_ex + string_case_compare_function + +Internal engine lowercasing will be using ASCII-only rules. User-facing functions, +such as strcasecmp, will be using locale rules. + +Two new functions - zend_binary_strncasecmp_l and zend_binary_strcasecmp_l - added as +locale-based counterparts to zend_binary_strcasecmp and zend_binary_strncasecmp. + ======================== 2. Build system changes ======================== @@ -34,5 +61,5 @@ PHPAPI int php_stream_context_del_link(php_stream_context *context, - b. Windows build system changes - - + - Drop Windows XP and 2003 support. diff --git a/Zend/tests/bug18556.phpt b/Zend/tests/bug18556.phpt index a9fbb592285aa..036abb2ada873 100644 --- a/Zend/tests/bug18556.phpt +++ b/Zend/tests/bug18556.phpt @@ -25,6 +25,7 @@ foreach(get_declared_classes() as $class) { if(!class_exists($class)) echo "$class No Longer Exists!\n"; + } echo "Done.\n"; ?> From ee6540ad092ce2f2aedb2e677b292b58acdca9be Mon Sep 17 00:00:00 2001 From: Andrew Faulds Date: Sat, 14 Jul 2012 23:20:45 +0100 Subject: [PATCH 1937/2394] Removed now-unnecessary expose_php checks for logo --- ext/standard/info.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ext/standard/info.c b/ext/standard/info.c index b27468e3ebb96..a63fd4c5c513b 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -652,7 +652,6 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) { char **env, *tmp1, *tmp2; char *php_uname; - int expose_php = INI_INT("expose_php"); if (!sapi_module.phpinfo_as_text) { php_print_info_htmlhead(TSRMLS_C); @@ -670,7 +669,7 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) php_info_print_box_start(1); } - if (expose_php && !sapi_module.phpinfo_as_text) { + if (!sapi_module.phpinfo_as_text) { time_t the_time; struct tm *ta, tmbuf; @@ -783,7 +782,7 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) /* Zend Engine */ php_info_print_box_start(0); - if (expose_php && !sapi_module.phpinfo_as_text) { + if (!sapi_module.phpinfo_as_text) { php_info_print("\"Zend\n"); } @@ -798,7 +797,7 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) efree(php_uname); } - if ((flag & PHP_INFO_CREDITS) && expose_php && !sapi_module.phpinfo_as_text) { + if ((flag & PHP_INFO_CREDITS) && !sapi_module.phpinfo_as_text) { php_info_print_hr(); php_info_print("\n"); From 626effcf1736f7f14e1c01ec52d62a55cf70cd9d Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 15 Jul 2012 15:35:16 -0700 Subject: [PATCH 1940/2394] typo --- UPGRADING | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UPGRADING b/UPGRADING index d598996f30d26..6cfd47bfaf753 100755 --- a/UPGRADING +++ b/UPGRADING @@ -21,7 +21,7 @@ PHP X.Y UPGRADE NOTES ======================================== - Drop Windows XP and 2003 support. (Pierre) -- All internal case insensitivity handling for class, fucntion and constant +- All internal case insensitivity handling for class, function and constant names is done according to ASCII rules, current locale settings are ignored. ======================================== From 85f077cea13b3cb4927453b8a2f8ce51a9461bbb Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Tue, 17 Jul 2012 13:24:27 +0200 Subject: [PATCH 1941/2394] Add support by yielding by-reference --- ...n_ref_generator_iterated_by_ref_error.phpt | 13 + .../errors/yield_const_by_ref_error.phpt | 16 + ...ld_non_ref_function_call_by_ref_error.phpt | 20 + .../generators/generator_method_by_ref.phpt | 44 + Zend/tests/generators/yield_by_reference.phpt | 32 + .../yield_ref_function_call_by_reference.phpt | 24 + Zend/zend_compile.c | 12 +- Zend/zend_generators.c | 8 +- Zend/zend_vm_def.h | 81 +- Zend/zend_vm_execute.h | 1935 +++++++++++++---- 10 files changed, 1746 insertions(+), 439 deletions(-) create mode 100644 Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt create mode 100644 Zend/tests/generators/errors/yield_const_by_ref_error.phpt create mode 100644 Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt create mode 100644 Zend/tests/generators/generator_method_by_ref.phpt create mode 100644 Zend/tests/generators/yield_by_reference.phpt create mode 100644 Zend/tests/generators/yield_ref_function_call_by_reference.phpt diff --git a/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt b/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt new file mode 100644 index 0000000000000..5d1a9e34841c1 --- /dev/null +++ b/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt @@ -0,0 +1,13 @@ +--TEST-- +Non-ref generators cannot be iterated by-ref +--FILE-- + +--EXPECTF-- +Fatal error: You can only iterate a generator by-reference if it declared that it yields by-reference in %s on line %d diff --git a/Zend/tests/generators/errors/yield_const_by_ref_error.phpt b/Zend/tests/generators/errors/yield_const_by_ref_error.phpt new file mode 100644 index 0000000000000..37ce1450db14b --- /dev/null +++ b/Zend/tests/generators/errors/yield_const_by_ref_error.phpt @@ -0,0 +1,16 @@ +--TEST-- +A notice is thrown when yielding a constant value by reference +--FILE-- +current()); + +?> +--EXPECTF-- +Notice: Only variable references should be yielded by reference in %s on line %d +string(3) "foo" diff --git a/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt b/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt new file mode 100644 index 0000000000000..2487149eefa5a --- /dev/null +++ b/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt @@ -0,0 +1,20 @@ +--TEST-- +Yielding the result of a non-ref function call throw a notice +--FILE-- +current()); + +?> +--EXPECTF-- +Notice: Only variable references should be yielded by reference in %s on line %d +string(3) "bar" diff --git a/Zend/tests/generators/generator_method_by_ref.phpt b/Zend/tests/generators/generator_method_by_ref.phpt new file mode 100644 index 0000000000000..108c2133f63e6 --- /dev/null +++ b/Zend/tests/generators/generator_method_by_ref.phpt @@ -0,0 +1,44 @@ +--TEST-- +Generator methods can yield by reference +--FILE-- +data = $data; + } + + public function getData() { + return $this->data; + } + + public function *&getIterator() { + foreach ($this->data as $key => &$value) { + yield $key => $value; + } + } +} + +$test = new Test([1, 2, 3, 4, 5]); +foreach ($test as &$value) { + $value *= -1; +} + +var_dump($test->getData()); + +?> +--EXPECT-- +array(5) { + [0]=> + int(-1) + [1]=> + int(-2) + [2]=> + int(-3) + [3]=> + int(-4) + [4]=> + &int(-5) +} diff --git a/Zend/tests/generators/yield_by_reference.phpt b/Zend/tests/generators/yield_by_reference.phpt new file mode 100644 index 0000000000000..86dd419bd64f0 --- /dev/null +++ b/Zend/tests/generators/yield_by_reference.phpt @@ -0,0 +1,32 @@ +--TEST-- +Generators can yield by-reference +--FILE-- + &$value) { + yield $key => $value; + } +} + +$array = [1, 2, 3, 4, 5]; +$iter = iter($array); +foreach ($iter as &$value) { + $value *= -1; +} +var_dump($array); + +?> +--EXPECT-- +array(5) { + [0]=> + int(-1) + [1]=> + int(-2) + [2]=> + int(-3) + [3]=> + int(-4) + [4]=> + &int(-5) +} diff --git a/Zend/tests/generators/yield_ref_function_call_by_reference.phpt b/Zend/tests/generators/yield_ref_function_call_by_reference.phpt new file mode 100644 index 0000000000000..88f72eabd126f --- /dev/null +++ b/Zend/tests/generators/yield_ref_function_call_by_reference.phpt @@ -0,0 +1,24 @@ +--TEST-- +The result of a by-ref function call can be yielded just fine +--FILE-- + +--EXPECT-- +string(3) "bar" diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 35ff2bbf52235..9264fde8e2953 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2615,12 +2615,16 @@ void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC) /* {{{ */ zend_op *opline; int start_op_number, end_op_number; + /* For generators the & modifier applies to the yielded values, not the + * return value. */ + zend_bool returns_reference = (CG(active_op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) && !(CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR); + if ((CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) && expr != NULL) { zend_error(E_COMPILE_ERROR, "Generators cannot return values using \"return\""); } if (do_end_vparse) { - if ((CG(active_op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) && !zend_is_function_or_method_call(expr)) { + if (returns_reference && !zend_is_function_or_method_call(expr)) { zend_do_end_variable_parse(expr, BP_VAR_W, 0 TSRMLS_CC); } else { zend_do_end_variable_parse(expr, BP_VAR_R, 0 TSRMLS_CC); @@ -2645,7 +2649,7 @@ void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC) /* {{{ */ opline = get_next_op(CG(active_op_array) TSRMLS_CC); - opline->opcode = (CG(active_op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) ? ZEND_RETURN_BY_REF : ZEND_RETURN; + opline->opcode = returns_reference ? ZEND_RETURN_BY_REF : ZEND_RETURN; if (expr) { SET_NODE(opline->op1, expr); @@ -2676,6 +2680,10 @@ void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC if (value) { SET_NODE(opline->op1, value); + + if (zend_is_function_or_method_call(value)) { + opline->extended_value = ZEND_RETURNS_FUNCTION; + } } else { SET_UNUSED(opline->op1); } diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index bccbb48ca4173..20ab9b16c68fe 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -661,12 +661,12 @@ zend_object_iterator *zend_generator_get_iterator(zend_class_entry *ce, zval *ob zend_generator_iterator *iterator; zend_generator *generator; - if (by_ref) { - zend_error(E_ERROR, "By reference iteration of generators is currently not supported"); - } - generator = (zend_generator *) zend_object_store_get_object(object TSRMLS_CC); + if (by_ref && !(generator->execute_data->op_array->fn_flags & ZEND_ACC_RETURN_REFERENCE)) { + zend_error(E_ERROR, "You can only iterate a generator by-reference if it declared that it yields by-reference"); + } + iterator = emalloc(sizeof(zend_generator_iterator)); iterator->intern.funcs = &zend_generator_iterator_functions; iterator->intern.data = (void *) generator; diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 015263f52f5ef..4be644a332793 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5316,6 +5316,7 @@ ZEND_VM_HANDLER(159, ZEND_SUSPEND_AND_RETURN_GENERATOR, ANY, ANY) ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -5332,30 +5333,74 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE /* Set the new yielded value */ if (OP1_TYPE != IS_UNUSED) { - zend_free_op free_op1; - zval *value = GET_OP1_ZVAL_PTR(BP_VAR_R); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (OP1_TYPE == IS_CONST || OP1_TYPE == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (OP1_TYPE == IS_CONST || OP1_TYPE == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = GET_OP1_ZVAL_PTR(BP_VAR_R); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!IS_OP1_TMP_FREE()) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!IS_OP1_TMP_FREE()) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = GET_OP1_ZVAL_PTR_PTR(BP_VAR_W); - generator->value = copy; + if (OP1_TYPE == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (OP1_TYPE == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + FREE_OP1_IF_VAR(); + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = GET_OP1_ZVAL_PTR(BP_VAR_R); - FREE_OP1_IF_VAR(); + /* Consts, temporary variables and references need copying */ + if (OP1_TYPE == IS_CONST || OP1_TYPE == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!IS_OP1_TMP_FREE()) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + FREE_OP1_IF_VAR(); + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 29b6d7c500c4b..b1bcd74d2332b 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -4118,6 +4118,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -4133,29 +4134,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { + zval *value, *copy; - zval *value = opline->op1.zv; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = opline->op1.zv; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_CONST == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CONST == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = opline->op1.zv; + /* Consts, temporary variables and references need copying */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -4759,6 +4803,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -4774,29 +4819,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { + zval *value, *copy; - zval *value = opline->op1.zv; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = opline->op1.zv; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_CONST == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CONST == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = opline->op1.zv; + + /* Consts, temporary variables and references need copying */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -5725,6 +5813,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -5740,29 +5829,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { + zval *value, *copy; - zval *value = opline->op1.zv; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = opline->op1.zv; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; - generator->value = copy; + if (IS_CONST == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CONST == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = opline->op1.zv; + /* Consts, temporary variables and references need copying */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -6386,6 +6518,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -6401,29 +6534,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { + zval *value, *copy; - zval *value = opline->op1.zv; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = opline->op1.zv; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_CONST == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CONST == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = opline->op1.zv; + + /* Consts, temporary variables and references need copying */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -7086,6 +7262,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -7101,29 +7278,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { + zval *value, *copy; - zval *value = opline->op1.zv; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = opline->op1.zv; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; - generator->value = copy; + if (IS_CONST == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CONST == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = opline->op1.zv; + + /* Consts, temporary variables and references need copying */ + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -9093,6 +9313,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -9109,29 +9330,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!1) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_TMP_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_TMP_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -9734,6 +9998,7 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDL static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -9750,29 +10015,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!1) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_TMP_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_TMP_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -10700,6 +11008,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -10716,29 +11025,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!1) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_TMP_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_TMP_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -11227,6 +11579,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OP static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -11243,29 +11596,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!1) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_TMP_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_TMP_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -11865,6 +12261,7 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLE static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -11881,29 +12278,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!1) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } - generator->value = copy; + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_TMP_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_TMP_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!1) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -15729,6 +16169,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER(ZEN static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -15745,30 +16186,74 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - generator->value = copy; + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + /* Consts, temporary variables and references need copying */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -17757,6 +18242,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -17773,30 +18259,74 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - generator->value = copy; + if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + /* Consts, temporary variables and references need copying */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -20165,6 +20695,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -20181,30 +20712,74 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - generator->value = copy; + if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + /* Consts, temporary variables and references need copying */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -21252,6 +21827,7 @@ static int ZEND_FASTCALL ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAND static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -21268,30 +21844,74 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + /* Consts, temporary variables and references need copying */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -23329,6 +23949,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER(ZEND_O static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE + zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -23345,30 +23966,74 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { - zend_free_op free_op1; - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { + zval *value, *copy; - /* Consts, temporary variables and references need copying */ - if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + + if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_VAR == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + /* Consts, temporary variables and references need copying */ + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -24766,6 +25431,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -24781,29 +25447,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR) { + zval *value, *copy; - zval *value = NULL; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = NULL; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_UNUSED == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } - generator->value = copy; + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_UNUSED == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = NULL; + + /* Consts, temporary variables and references need copying */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -26025,6 +26734,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -26040,29 +26750,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR) { + zval *value, *copy; - zval *value = NULL; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = NULL; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; - generator->value = copy; + if (IS_UNUSED == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_UNUSED == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = NULL; + + /* Consts, temporary variables and references need copying */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -27284,6 +28037,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -27299,29 +28053,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR) { + zval *value, *copy; - zval *value = NULL; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = NULL; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; - generator->value = copy; + if (IS_UNUSED == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_UNUSED == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = NULL; + /* Consts, temporary variables and references need copying */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -27655,6 +28452,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -27670,29 +28468,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR) { + zval *value, *copy; - zval *value = NULL; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = NULL; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_UNUSED == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_UNUSED == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = NULL; + /* Consts, temporary variables and references need copying */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -28911,6 +29752,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -28926,29 +29768,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR) { + zval *value, *copy; - zval *value = NULL; + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = NULL; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = NULL; + + if (IS_UNUSED == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } - generator->value = copy; + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_UNUSED == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = NULL; + + /* Consts, temporary variables and references need copying */ + if (IS_UNUSED == IS_CONST || IS_UNUSED == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -32376,6 +33261,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -32391,29 +33277,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { + zval *value, *copy; - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + + if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CV == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -34274,6 +35203,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -34289,29 +35219,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { + zval *value, *copy; - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + + if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CV == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -36551,6 +37524,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -36566,29 +37540,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { + zval *value, *copy; - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + + if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CV == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -37498,6 +38515,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -37513,29 +38531,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { + zval *value, *copy; - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + + if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CV == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - generator->value = copy; + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } + + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); @@ -39444,6 +40505,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS { USE_OPLINE + /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -39459,29 +40521,72 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { + /* Constants and temporary variables aren't yieldable by reference, + * but we still allow them with a notice. */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { + zval *value, *copy; - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - /* Consts, temporary variables and references need copying */ - if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR - || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) - ) { - zval *copy; + value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); - ALLOC_ZVAL(copy); - INIT_PZVAL_COPY(copy, value); + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } - /* Temporary variables don't need ctor copying */ - if (!0) { - zval_copy_ctor(copy); - } + generator->value = copy; + } else { + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + + if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { + zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); + } + + /* If a function call result is yielded and the function did + * not return by reference we throw a notice. */ + if (IS_CV == IS_VAR && !Z_ISREF_PP(value_ptr) + && !(opline->extended_value == ZEND_RETURNS_FUNCTION + && EX_T(opline->op1.var).var.fcall_returned_reference) + && EX_T(opline->op1.var).var.ptr_ptr == &EX_T(opline->op1.var).var.ptr) { + zend_error(E_NOTICE, "Only variable references should be yielded by reference"); + + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } else { + SEPARATE_ZVAL_TO_MAKE_IS_REF(value_ptr); + Z_ADDREF_PP(value_ptr); + generator->value = *value_ptr; + } - generator->value = copy; + } } else { - Z_ADDREF_P(value); - generator->value = value; - } + zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + + /* Consts, temporary variables and references need copying */ + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR + || (PZVAL_IS_REF(value) && Z_REFCOUNT_P(value) > 0) + ) { + zval *copy; + ALLOC_ZVAL(copy); + INIT_PZVAL_COPY(copy, value); + + /* Temporary variables don't need ctor copying */ + if (!0) { + zval_copy_ctor(copy); + } + + generator->value = copy; + } else { + Z_ADDREF_P(value); + generator->value = value; + } + + } } else { /* If no value was specified yield null */ Z_ADDREF(EG(uninitialized_zval)); From cea3f0f3635179c052ba2d13d889a82b5a327ddb Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 18 Jul 2012 18:50:42 +0800 Subject: [PATCH 1942/2394] fix test All input characters that are not a-z, A-Z or 0-9 will be converted to their "URL escaped" version see http://curl.haxx.se/libcurl/c/curl_escape.html --- ext/curl/tests/curl_escape.phpt | Bin 553 -> 557 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/curl/tests/curl_escape.phpt b/ext/curl/tests/curl_escape.phpt index 7c90fb98883249b398707037da94d7ad8dd3db4f..9a11e61b82581c0aad8673d3b3dce639066abbff 100644 GIT binary patch delta 42 vcmZ3vXW)PDMl${Gff4hjFOT9Rbxk0BR3!_FE7_C$SBa8{DRRH0Op$vB>(^b From 8238c6a4c815220045322ac3c524b98613639f97 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 18 Jul 2012 19:19:31 +0800 Subject: [PATCH 1943/2394] test script for bug #61697 --- ext/spl/tests/bug61697.phpt | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 ext/spl/tests/bug61697.phpt diff --git a/ext/spl/tests/bug61697.phpt b/ext/spl/tests/bug61697.phpt new file mode 100644 index 0000000000000..d95caef978595 --- /dev/null +++ b/ext/spl/tests/bug61697.phpt @@ -0,0 +1,26 @@ +--TEST-- +Bug #61697 (spl_autoload_functions returns lambda functions incorrectly) +--XFAIL-- +Bug #61697 not fixed yet +--FILE-- + +--EXPECTF-- +Array +( +) From 94a0f8722b1f480f2cd8c0fc044cff40f2418607 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 18 Jul 2012 22:35:03 +0800 Subject: [PATCH 1944/2394] Revert "fix test" This reverts commit cea3f0f3635179c052ba2d13d889a82b5a327ddb. seems the behavior is different between certain versions --- ext/curl/tests/curl_escape.phpt | Bin 557 -> 553 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/curl/tests/curl_escape.phpt b/ext/curl/tests/curl_escape.phpt index 9a11e61b82581c0aad8673d3b3dce639066abbff..7c90fb98883249b398707037da94d7ad8dd3db4f 100644 GIT binary patch delta 38 scmZ3>vXW)PDMl${Gff4hjFOT9Rbxk0BR3!_FE7_C$SBa8{DRRH0Op$vB>(^b delta 42 vcmZ3 Date: Wed, 18 Jul 2012 21:42:36 +0200 Subject: [PATCH 1945/2394] zend_parse_parameters: allow ! for non pointers This commit allows getting information about whether a certain value was a NULL value by using the ! modifier together with the l/L, d and b. Example: long l; zend_bool is_null; zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l!", &l, &is_null) For the specifiers l/L, d and b, NULL values are reported as 0, 0., or false. But sometimes one wants to distinguish NULL from those other values -- for instance, to give NULL the same effect as the argument not having been passed. The usual way this problem is handled is by fetching the parameter with 'z' or 'Z', check if it is NULL and if not use convert_to_long_ex()/convert_to_double_ex(), etc. Unfortunately, this is not equivalent. convert_to_long_ex() does a cast, while zpp() is stricter. For instance, zpp will not accept 'foo' for a long argument, and it will emit a notice when encountering '5foo'. In fact, the only way to otherwise zpp semantics (without duplicating its logic) is to fetch the raw zval from the stack and check whether it's NULL (with zpp itself or its relatives) and then run zpp again. That is not an elegant solution. --- Zend/zend_API.c | 44 ++++++++++++++++++++++++++++++-------------- 1 file changed, 30 insertions(+), 14 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 98a33e544508f..d7170eb2cc720 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -306,16 +306,14 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con { const char *spec_walk = *spec; char c = *spec_walk++; - int return_null = 0; + int check_null = 0; /* scan through modifiers */ while (1) { if (*spec_walk == '/') { SEPARATE_ZVAL_IF_NOT_REF(arg); } else if (*spec_walk == '!') { - if (Z_TYPE_PP(arg) == IS_NULL) { - return_null = 1; - } + check_null = 1; } else { break; } @@ -327,6 +325,12 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'L': { long *p = va_arg(*va, long *); + + if (check_null) { + zend_bool *p = va_arg(*va, zend_bool *); + *p = (Z_TYPE_PP(arg) == IS_NULL); + } + switch (Z_TYPE_PP(arg)) { case IS_STRING: { @@ -380,6 +384,12 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'd': { double *p = va_arg(*va, double *); + + if (check_null) { + zend_bool *p = va_arg(*va, zend_bool *); + *p = (Z_TYPE_PP(arg) == IS_NULL); + } + switch (Z_TYPE_PP(arg)) { case IS_STRING: { @@ -418,7 +428,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con int *pl = va_arg(*va, int *); switch (Z_TYPE_PP(arg)) { case IS_NULL: - if (return_null) { + if (check_null) { *p = NULL; *pl = 0; break; @@ -462,6 +472,12 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'b': { zend_bool *p = va_arg(*va, zend_bool *); + + if (check_null) { + zend_bool *p = va_arg(*va, zend_bool *); + *p = (Z_TYPE_PP(arg) == IS_NULL); + } + switch (Z_TYPE_PP(arg)) { case IS_NULL: case IS_STRING: @@ -484,7 +500,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'r': { zval **p = va_arg(*va, zval **); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; break; } @@ -499,7 +515,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'a': { zval **p = va_arg(*va, zval **); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; break; } @@ -514,7 +530,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'h': { HashTable **p = va_arg(*va, HashTable **); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; break; } @@ -534,7 +550,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'o': { zval **p = va_arg(*va, zval **); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; break; } @@ -551,7 +567,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con zval **p = va_arg(*va, zval **); zend_class_entry *ce = va_arg(*va, zend_class_entry *); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; break; } @@ -573,7 +589,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con zend_class_entry **lookup, **pce = va_arg(*va, zend_class_entry **); zend_class_entry *ce_base = *pce; - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *pce = NULL; break; } @@ -607,7 +623,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con zend_fcall_info_cache *fcc = va_arg(*va, zend_fcall_info_cache *); char *is_callable_error = NULL; - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { fci->size = 0; fcc->initialized = 0; break; @@ -637,7 +653,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'z': { zval **p = va_arg(*va, zval **); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; } else { *p = *arg; @@ -648,7 +664,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval **arg, va_list *va, con case 'Z': { zval ***p = va_arg(*va, zval ***); - if (return_null) { + if (check_null && Z_TYPE_PP(arg) == IS_NULL) { *p = NULL; } else { *p = arg; From 13f1d53b689480776d70e256ebd3fc44fd2e253d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 18 Jul 2012 22:05:42 +0200 Subject: [PATCH 1946/2394] Expose zend_parse_arg() as zend_parse_parameter() Sometimes, one wants to accept several types for a given parameter. zpp has special functionality for detecting the NULL type, since the NULL type is frequently used to skip parameters. However, supporting several types is otherwise very tedious. There are many cases where this situation arises -- for instance one may want to accept an arbitrary number of integer and expect them in an array, but allow a bare integer too; one may want to accept something that will be used as an array key (which can be either and int or a string); one may want to accept integer and double numbers. A search for IS_LONG reveals many situations where this need arises. The usual solution is to fetch the argument with 'z'/'Z', check its type, and then convert the argument, e.g. with convert_to_long_ex(). As explain in the last commit, this has different behavior and generates inconsistency. Another -- even more flawed strategy --, is to try zpp with a specific format, forcing it quiet, and if it fails retrying with another form. But because zpp changes the arguments directly in the stack (for instance, using "l" converts the zval in the stack to IS_LONG), the arguments may look different after the first zpp, leaving subtle bugs. This commit also allows more complex scenarios, for instance where the expected type of one parameter depends on other parameters. --- Zend/zend_API.c | 13 +++++++++++++ Zend/zend_API.h | 2 ++ 2 files changed, 15 insertions(+) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index d7170eb2cc720..22acb70125582 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -713,6 +713,19 @@ static int zend_parse_arg(int arg_num, zval **arg, va_list *va, const char **spe } /* }}} */ +int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...) +{ + va_list va; + int ret; + int quiet = flags & ZEND_PARSE_PARAMS_QUIET; + + va_start(va, spec); + ret = zend_parse_arg(arg_num, arg, &va, &spec, quiet TSRMLS_CC); + va_end(va); + + return ret; +} + static int zend_parse_va_args(int num_args, const char *type_spec, va_list *va, int flags TSRMLS_DC) /* {{{ */ { const char *spec_walk; diff --git a/Zend/zend_API.h b/Zend/zend_API.h index f54db7f2e87cc..f65fb172c5be5 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -253,6 +253,8 @@ ZEND_API char *zend_zval_type_name(const zval *arg); ZEND_API int zend_parse_method_parameters(int num_args TSRMLS_DC, zval *this_ptr, const char *type_spec, ...); ZEND_API int zend_parse_method_parameters_ex(int flags, int num_args TSRMLS_DC, zval *this_ptr, const char *type_spec, ...); +int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...); + /* End of parameter parsing API -- andrei */ ZEND_API int zend_register_functions(zend_class_entry *scope, const zend_function_entry *functions, HashTable *function_table, int type TSRMLS_DC); From c9709bfbd7a71a42e0472abaf9c7d30598e264bf Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 20 Jul 2012 00:49:50 +0200 Subject: [PATCH 1947/2394] Remove asterix modifier (*) for generators Generators are now automatically detected by the presence of a `yield` expression in their body. This removes the ZEND_SUSPEND_AND_RETURN_GENERATOR opcode. Instead additional checks for ZEND_ACC_GENERATOR are added to the fcall_common helper and zend_call_function. This also adds a new function zend_generator_create_zval, which handles the actual creation of the generator zval from an op array. I feel like I should deglobalize the zend_create_execute_data_from_op_array code a bit. It currently changes EG(current_execute_data) and EG(opline_ptr) which is somewhat confusing (given the name). --- .../generators/auto_incrementing_keys.phpt | 2 +- Zend/tests/generators/backtrace.phpt | 3 +- Zend/tests/generators/clone.phpt | 2 +- Zend/tests/generators/clone_with_foreach.phpt | 2 +- Zend/tests/generators/clone_with_stack.phpt | 2 +- .../generators/clone_with_symbol_table.phpt | 2 +- Zend/tests/generators/clone_with_this.phpt | 4 +- .../generators/close_inside_generator.phpt | 2 +- Zend/tests/generators/dynamic_call.phpt | 2 +- .../errors/generator_cannot_return_error.phpt | 3 +- ...n_ref_generator_iterated_by_ref_error.phpt | 2 +- .../errors/yield_const_by_ref_error.phpt | 2 +- .../yield_in_normal_function_error.phpt | 12 - ...ld_non_ref_function_call_by_ref_error.phpt | 2 +- .../errors/yield_outside_function_error.phpt | 2 +- Zend/tests/generators/func_get_args.phpt | 3 +- Zend/tests/generators/generator_close.phpt | 2 +- Zend/tests/generators/generator_method.phpt | 2 +- .../generators/generator_method_by_ref.phpt | 2 +- .../generator_returns_generator.phpt | 6 +- Zend/tests/generators/generator_send.phpt | 2 +- ...nerator_throwing_during_function_call.phpt | 2 +- .../generator_throwing_exception.phpt | 2 +- .../tests/generators/generator_with_keys.phpt | 2 +- .../generators/no_foreach_var_leaks.phpt | 2 +- Zend/tests/generators/send_after_close.phpt | 8 +- .../generators/send_returns_current.phpt | 2 +- .../tests/generators/unused_return_value.phpt | 2 +- Zend/tests/generators/xrange.phpt | 2 +- Zend/tests/generators/yield_by_reference.phpt | 2 +- .../yield_during_function_call.phpt | 2 +- .../generators/yield_during_method_call.phpt | 2 +- .../yield_ref_function_call_by_reference.phpt | 2 +- .../tests/generators/yield_without_value.phpt | 2 +- Zend/zend_compile.c | 38 +-- Zend/zend_compile.h | 5 +- Zend/zend_execute.h | 1 + Zend/zend_execute_API.c | 9 +- Zend/zend_generators.c | 53 +++- Zend/zend_generators.h | 1 + Zend/zend_language_parser.y | 27 +-- Zend/zend_vm_def.h | 109 +-------- Zend/zend_vm_execute.h | 228 ++++++++---------- Zend/zend_vm_execute.skl | 2 +- Zend/zend_vm_opcodes.h | 5 +- 45 files changed, 247 insertions(+), 324 deletions(-) delete mode 100644 Zend/tests/generators/errors/yield_in_normal_function_error.phpt diff --git a/Zend/tests/generators/auto_incrementing_keys.phpt b/Zend/tests/generators/auto_incrementing_keys.phpt index 623f2d813d453..acfb2f2ce00bb 100644 --- a/Zend/tests/generators/auto_incrementing_keys.phpt +++ b/Zend/tests/generators/auto_incrementing_keys.phpt @@ -3,7 +3,7 @@ Generator keys are auto-incrementing by default --FILE-- 'rab'; diff --git a/Zend/tests/generators/backtrace.phpt b/Zend/tests/generators/backtrace.phpt index 77976f9324466..5f665b7e4ac17 100644 --- a/Zend/tests/generators/backtrace.phpt +++ b/Zend/tests/generators/backtrace.phpt @@ -7,8 +7,9 @@ function f1() { debug_print_backtrace(); } -function *f2($arg1, $arg2) { +function f2($arg1, $arg2) { f1(); + yield; // force generator } function f3($gen) { diff --git a/Zend/tests/generators/clone.phpt b/Zend/tests/generators/clone.phpt index 94c4c6364e7df..36811dfe6e744 100644 --- a/Zend/tests/generators/clone.phpt +++ b/Zend/tests/generators/clone.phpt @@ -3,7 +3,7 @@ Generators can be cloned --FILE-- foo = 'bar'; yield; // interrupt var_dump($this->foo); diff --git a/Zend/tests/generators/close_inside_generator.phpt b/Zend/tests/generators/close_inside_generator.phpt index 41a91c9fc7b9e..1df64bf6b1abe 100644 --- a/Zend/tests/generators/close_inside_generator.phpt +++ b/Zend/tests/generators/close_inside_generator.phpt @@ -3,7 +3,7 @@ Calling close() during the exectution of the generator --FILE-- ---EXPECTF-- -Fatal error: The "yield" expression can only be used inside a generator function in %s on line %d diff --git a/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt b/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt index 2487149eefa5a..4b8563331c673 100644 --- a/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt +++ b/Zend/tests/generators/errors/yield_non_ref_function_call_by_ref_error.phpt @@ -7,7 +7,7 @@ function foo() { return "bar"; } -function *&gen() { +function &gen() { yield foo(); } diff --git a/Zend/tests/generators/errors/yield_outside_function_error.phpt b/Zend/tests/generators/errors/yield_outside_function_error.phpt index 5f47e75366563..f999c1c03bf48 100644 --- a/Zend/tests/generators/errors/yield_outside_function_error.phpt +++ b/Zend/tests/generators/errors/yield_outside_function_error.phpt @@ -7,4 +7,4 @@ yield "Test"; ?> --EXPECTF-- -Fatal error: The "yield" expression can only be used inside a generator function in %s on line %d +Fatal error: The "yield" expression can only be used inside a function in %s on line %d diff --git a/Zend/tests/generators/func_get_args.phpt b/Zend/tests/generators/func_get_args.phpt index 7ce7fb002f0a5..f8d3fa7c146e7 100644 --- a/Zend/tests/generators/func_get_args.phpt +++ b/Zend/tests/generators/func_get_args.phpt @@ -3,8 +3,9 @@ func_get_args() can be used inside generator functions --FILE-- close() --FILE-- data = $data; } - public function *getIterator() { + public function getIterator() { foreach ($this->data as $value) { yield $value; } diff --git a/Zend/tests/generators/generator_method_by_ref.phpt b/Zend/tests/generators/generator_method_by_ref.phpt index 108c2133f63e6..cfe52fe67ff82 100644 --- a/Zend/tests/generators/generator_method_by_ref.phpt +++ b/Zend/tests/generators/generator_method_by_ref.phpt @@ -14,7 +14,7 @@ class Test implements IteratorAggregate { return $this->data; } - public function *&getIterator() { + public function &getIterator() { foreach ($this->data as $key => &$value) { yield $key => $value; } diff --git a/Zend/tests/generators/generator_returns_generator.phpt b/Zend/tests/generators/generator_returns_generator.phpt index a3e2b29468ff9..ad332a3be9246 100644 --- a/Zend/tests/generators/generator_returns_generator.phpt +++ b/Zend/tests/generators/generator_returns_generator.phpt @@ -3,12 +3,14 @@ A generator function returns a Generator object --FILE-- diff --git a/Zend/tests/generators/generator_send.phpt b/Zend/tests/generators/generator_send.phpt index 11ac37f846e00..074d815389711 100644 --- a/Zend/tests/generators/generator_send.phpt +++ b/Zend/tests/generators/generator_send.phpt @@ -3,7 +3,7 @@ Values can be sent back to the generator --FILE-- current($array); diff --git a/Zend/tests/generators/no_foreach_var_leaks.phpt b/Zend/tests/generators/no_foreach_var_leaks.phpt index 36ab91bb15a66..62743895ebcbd 100644 --- a/Zend/tests/generators/no_foreach_var_leaks.phpt +++ b/Zend/tests/generators/no_foreach_var_leaks.phpt @@ -3,7 +3,7 @@ foreach() (and other) variables aren't leaked on premature close --FILE-- send("Test"); +$gen->send('foo'); +$gen->send('bar'); ?> -===DONE=== --EXPECT-- -===DONE=== +string(3) "foo" diff --git a/Zend/tests/generators/send_returns_current.phpt b/Zend/tests/generators/send_returns_current.phpt index d3a4afd53a375..fc260c0af0c41 100644 --- a/Zend/tests/generators/send_returns_current.phpt +++ b/Zend/tests/generators/send_returns_current.phpt @@ -3,7 +3,7 @@ $generator->send() returns the yielded value --FILE-- &$value) { yield $key => $value; } diff --git a/Zend/tests/generators/yield_during_function_call.phpt b/Zend/tests/generators/yield_during_function_call.phpt index 9727b8fd33e0a..21071f9fb4af6 100644 --- a/Zend/tests/generators/yield_during_function_call.phpt +++ b/Zend/tests/generators/yield_during_function_call.phpt @@ -3,7 +3,7 @@ --FILE-- b(yield); } diff --git a/Zend/tests/generators/yield_ref_function_call_by_reference.phpt b/Zend/tests/generators/yield_ref_function_call_by_reference.phpt index 88f72eabd126f..e371affd92c8e 100644 --- a/Zend/tests/generators/yield_ref_function_call_by_reference.phpt +++ b/Zend/tests/generators/yield_ref_function_call_by_reference.phpt @@ -7,7 +7,7 @@ function &nop(&$var) { return $var; } -function *&gen(&$var) { +function &gen(&$var) { yield nop($var); } diff --git a/Zend/tests/generators/yield_without_value.phpt b/Zend/tests/generators/yield_without_value.phpt index dc467a83bd136..510c755bd3fe9 100644 --- a/Zend/tests/generators/yield_without_value.phpt +++ b/Zend/tests/generators/yield_without_value.phpt @@ -3,7 +3,7 @@ yield can be used without a value --FILE-- u.constant.value.str.val; @@ -1553,9 +1553,6 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n CG(interactive) = orig_interactive; op_array.function_name = name; - if (is_generator) { - op_array.fn_flags |= ZEND_ACC_GENERATOR; - } if (return_reference) { op_array.fn_flags |= ZEND_ACC_RETURN_REFERENCE; } @@ -1754,7 +1751,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n } /* }}} */ -void zend_do_begin_lambda_function_declaration(znode *result, znode *function_token, int is_generator, int return_reference, int is_static TSRMLS_DC) /* {{{ */ +void zend_do_begin_lambda_function_declaration(znode *result, znode *function_token, int return_reference, int is_static TSRMLS_DC) /* {{{ */ { znode function_name; zend_op_array *current_op_array = CG(active_op_array); @@ -1764,7 +1761,7 @@ void zend_do_begin_lambda_function_declaration(znode *result, znode *function_to function_name.op_type = IS_CONST; ZVAL_STRINGL(&function_name.u.constant, "{closure}", sizeof("{closure}")-1, 1); - zend_do_begin_function_declaration(function_token, &function_name, 0, is_generator, return_reference, NULL TSRMLS_CC); + zend_do_begin_function_declaration(function_token, &function_name, 0, return_reference, NULL TSRMLS_CC); result->op_type = IS_TMP_VAR; result->u.op.var = get_temporary_variable(current_op_array); @@ -2670,10 +2667,12 @@ void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC { zend_op *opline; - if ((CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) == 0) { - zend_error(E_COMPILE_ERROR, "The \"yield\" expression can only be used inside a generator function"); + if (!CG(active_op_array)->function_name) { + zend_error(E_COMPILE_ERROR, "The \"yield\" expression can only be used inside a function"); } + CG(active_op_array)->fn_flags |= ZEND_ACC_GENERATOR; + opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_YIELD; @@ -2704,10 +2703,12 @@ void zend_do_delegate_yield(znode *result, const znode *value TSRMLS_DC) /* {{{ { zend_op *opline; - if ((CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) == 0) { - zend_error(E_COMPILE_ERROR, "The \"yield*\" expression can only be used inside a generator function"); + if (!CG(active_op_array)->function_name) { + zend_error(E_COMPILE_ERROR, "The \"yield*\" expression can only be used inside a function"); } + CG(active_op_array)->fn_flags |= ZEND_ACC_GENERATOR; + opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_DELEGATE_YIELD; @@ -2721,23 +2722,6 @@ void zend_do_delegate_yield(znode *result, const znode *value TSRMLS_DC) /* {{{ } /* }}} */ -void zend_do_suspend_if_generator(TSRMLS_D) /* {{{ */ -{ - zend_op *opline; - - // we only suspend execution if the current function is a generator - if ((CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) == 0) { - return; - } - - opline = get_next_op(CG(active_op_array) TSRMLS_CC); - - opline->opcode = ZEND_SUSPEND_AND_RETURN_GENERATOR; - SET_UNUSED(opline->op1); - SET_UNUSED(opline->op2); -} -/* }}} */ - static int zend_add_try_element(zend_uint try_op TSRMLS_DC) /* {{{ */ { int try_catch_offset = CG(active_op_array)->last_try_catch++; diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index d0587d1faa4db..c4355e0dde0ed 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -478,7 +478,7 @@ void zend_do_add_string(znode *result, const znode *op1, znode *op2 TSRMLS_DC); void zend_do_add_variable(znode *result, const znode *op1, const znode *op2 TSRMLS_DC); int zend_do_verify_access_types(const znode *current_access_type, const znode *new_modifier); -void zend_do_begin_function_declaration(znode *function_token, znode *function_name, int is_method, int is_generator, int return_reference, znode *fn_flags_znode TSRMLS_DC); +void zend_do_begin_function_declaration(znode *function_token, znode *function_name, int is_method, int return_reference, znode *fn_flags_znode TSRMLS_DC); void zend_do_end_function_declaration(const znode *function_token TSRMLS_DC); void zend_do_receive_arg(zend_uchar op, znode *varname, const znode *offset, const znode *initialization, znode *class_type, zend_bool pass_by_reference TSRMLS_DC); int zend_do_begin_function_call(znode *function_name, zend_bool check_namespace TSRMLS_DC); @@ -492,10 +492,9 @@ void zend_do_end_function_call(znode *function_name, znode *result, const znode void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC); void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC); void zend_do_delegate_yield(znode *result, const znode *value TSRMLS_DC); -void zend_do_suspend_if_generator(TSRMLS_D); void zend_do_handle_exception(TSRMLS_D); -void zend_do_begin_lambda_function_declaration(znode *result, znode *function_token, int is_generator, int return_reference, int is_static TSRMLS_DC); +void zend_do_begin_lambda_function_declaration(znode *result, znode *function_token, int return_reference, int is_static TSRMLS_DC); void zend_do_fetch_lexical_variable(znode *varname, zend_bool is_ref TSRMLS_DC); void zend_do_try(znode *try_token TSRMLS_DC); diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 92160b54eb0a5..4cfc52b6a3b69 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -55,6 +55,7 @@ ZEND_API extern void (*zend_execute_internal)(zend_execute_data *execute_data_pt void init_executor(TSRMLS_D); void shutdown_executor(TSRMLS_D); void shutdown_destructors(TSRMLS_D); +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC); ZEND_API void execute(zend_op_array *op_array TSRMLS_DC); ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC); ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC); diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 1deee2a86c89e..fb0c18b27cc3f 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -31,6 +31,7 @@ #include "zend_extensions.h" #include "zend_exceptions.h" #include "zend_closures.h" +#include "zend_generators.h" #include "zend_vm.h" #include "zend_float.h" #ifdef HAVE_SYS_TIME_H @@ -955,7 +956,13 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS EG(return_value_ptr_ptr) = fci->retval_ptr_ptr; EG(active_op_array) = (zend_op_array *) EX(function_state).function; original_opline_ptr = EG(opline_ptr); - zend_execute(EG(active_op_array) TSRMLS_CC); + + if (EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) { + *fci->retval_ptr_ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); + } else { + zend_execute(EG(active_op_array) TSRMLS_CC); + } + if (!fci->symbol_table && EG(active_symbol_table)) { if (EG(symtable_cache_ptr)>=EG(symtable_cache_limit)) { zend_hash_destroy(EG(active_symbol_table)); diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 20ab9b16c68fe..b164fb835e53b 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -315,6 +315,56 @@ static zend_object_value zend_generator_create(zend_class_entry *class_type TSRM } /* }}} */ +/* Requires globals EG(scope), EG(current_scope), EG(This), + * EG(active_symbol_table) and EG(current_execute_data). */ +zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ +{ + zval *return_value; + zend_generator *generator; + + /* Create new execution context. We have to back up and restore + * EG(current_execute_data) and EG(opline_ptr) here because the function + * modifies it. */ + zend_execute_data *current_execute_data = EG(current_execute_data); + zend_op **opline_ptr = EG(opline_ptr); + zend_execute_data *execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); + EG(current_execute_data) = current_execute_data; + EG(opline_ptr) = opline_ptr; + + ALLOC_INIT_ZVAL(return_value); + object_init_ex(return_value, zend_ce_generator); + + if (EG(This)) { + Z_ADDREF_P(EG(This)); + } + + /* Back up executor globals. */ + execute_data->current_scope = EG(scope); + execute_data->current_called_scope = EG(called_scope); + execute_data->symbol_table = EG(active_symbol_table); + execute_data->current_this = EG(This); + + /* Save execution context in generator object. */ + generator = (zend_generator *) zend_object_store_get_object(return_value TSRMLS_CC); + generator->execute_data = execute_data; + + /* We have to add another stack frame so the generator function shows + * up in backtraces and func_get_all() can access the function + * arguments. */ + execute_data->prev_execute_data = emalloc(sizeof(zend_execute_data)); + if (EG(current_execute_data)) { + memcpy(execute_data->prev_execute_data, EG(current_execute_data), sizeof(zend_execute_data)); + execute_data->prev_execute_data->function_state.arguments = zend_copy_arguments(EG(current_execute_data)->function_state.arguments); + } else { + memset(execute_data->prev_execute_data, 0, sizeof(zend_execute_data)); + execute_data->prev_execute_data->function_state.function = (zend_function *) op_array; + execute_data->prev_execute_data->function_state.arguments = NULL; + } + + return return_value; +} +/* }}} */ + static zend_function *zend_generator_get_constructor(zval *object TSRMLS_DC) /* {{{ */ { zend_error(E_RECOVERABLE_ERROR, "The \"Generator\" class is reserved for internal use and cannot be manually instantiated"); @@ -377,9 +427,6 @@ static void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ * set the prev_execute_data of that prev_execute_data :) */ generator->execute_data->prev_execute_data->prev_execute_data = original_execute_data; - /* Go to next opcode (we don't want to run the last one again) */ - generator->execute_data->opline++; - /* Resume execution */ execute_ex(generator->execute_data TSRMLS_CC); diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index 73d85287a7055..d67ea4137bf88 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -55,6 +55,7 @@ typedef struct _zend_generator { extern ZEND_API zend_class_entry *zend_ce_generator; void zend_register_generator_ce(TSRMLS_D); +zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_CC); void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC); END_EXTERN_C() diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 02aa694c6eb6d..b705d60d9a530 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -360,11 +360,6 @@ class_declaration_statement: unticked_class_declaration_statement { DO_TICKS(); } ; -is_generator: - /* empty */ { $$.op_type = 0; } - | '*' { $$.op_type = 1; } -; - is_reference: /* empty */ { $$.op_type = ZEND_RETURN_VAL; } | '&' { $$.op_type = ZEND_RETURN_REF; } @@ -372,8 +367,8 @@ is_reference: unticked_function_declaration_statement: - function is_generator is_reference T_STRING { zend_do_begin_function_declaration(&$1, &$4, 0, $2.op_type, $3.op_type, NULL TSRMLS_CC); } - '(' parameter_list ')' { zend_do_suspend_if_generator(TSRMLS_C); } + function is_reference T_STRING { zend_do_begin_function_declaration(&$1, &$3, 0, $2.op_type, NULL TSRMLS_CC); } + '(' parameter_list ')' '{' inner_statement_list '}' { zend_do_end_function_declaration(&$1 TSRMLS_CC); } ; @@ -584,9 +579,9 @@ class_statement: variable_modifiers { CG(access_type) = Z_LVAL($1.u.constant); } class_variable_declaration ';' | class_constant_declaration ';' | trait_use_statement - | method_modifiers function is_generator is_reference T_STRING { zend_do_begin_function_declaration(&$2, &$5, 1, $3.op_type, $4.op_type, &$1 TSRMLS_CC); } - '(' parameter_list ')' { zend_do_suspend_if_generator(TSRMLS_C); } - method_body { zend_do_abstract_method(&$5, &$1, &$11 TSRMLS_CC); zend_do_end_function_declaration(&$2 TSRMLS_CC); } + | method_modifiers function is_reference T_STRING { zend_do_begin_function_declaration(&$2, &$4, 1, $3.op_type, &$1 TSRMLS_CC); } + '(' parameter_list ')' + method_body { zend_do_abstract_method(&$4, &$1, &$9 TSRMLS_CC); zend_do_end_function_declaration(&$2 TSRMLS_CC); } ; trait_use_statement: @@ -805,12 +800,12 @@ expr_without_variable: | T_YIELD { zend_do_yield(&$$, NULL, NULL TSRMLS_CC); } | T_YIELD expr { zend_do_yield(&$$, &$2, NULL TSRMLS_CC); } | T_YIELD '*' expr { zend_do_delegate_yield(&$$, &$3 TSRMLS_CC); } - | function is_generator is_reference { zend_do_begin_lambda_function_declaration(&$$, &$1, $2.op_type, $3.op_type, 0 TSRMLS_CC); } - '(' parameter_list ')' lexical_vars { zend_do_suspend_if_generator(TSRMLS_C); } - '{' inner_statement_list '}' { zend_do_end_function_declaration(&$1 TSRMLS_CC); $$ = $4; } - | T_STATIC function is_generator is_reference { zend_do_begin_lambda_function_declaration(&$$, &$2, $3.op_type, $4.op_type, 1 TSRMLS_CC); } - '(' parameter_list ')' lexical_vars { zend_do_suspend_if_generator(TSRMLS_C); } - '{' inner_statement_list '}' { zend_do_end_function_declaration(&$2 TSRMLS_CC); $$ = $5; } + | function is_reference { zend_do_begin_lambda_function_declaration(&$$, &$1, $2.op_type, 0 TSRMLS_CC); } + '(' parameter_list ')' lexical_vars + '{' inner_statement_list '}' { zend_do_end_function_declaration(&$1 TSRMLS_CC); $$ = $3; } + | T_STATIC function is_reference { zend_do_begin_lambda_function_declaration(&$$, &$2, $3.op_type, 1 TSRMLS_CC); } + '(' parameter_list ')' lexical_vars + '{' inner_statement_list '}' { zend_do_end_function_declaration(&$2 TSRMLS_CC); $$ = $4; } ; combined_scalar_offset: diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 4be644a332793..e8b89a6db5b36 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2705,7 +2705,11 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; } - if (EXPECTED(zend_execute == execute)) { + if (EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) { + if (RETURN_VALUE_USED(opline)) { + EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); + } + } else if (EXPECTED(zend_execute == execute)) { if (EXPECTED(EG(exception) == NULL)) { ZEND_VM_ENTER(); } @@ -5218,102 +5222,7 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(159, ZEND_SUSPEND_AND_RETURN_GENERATOR, ANY, ANY) -{ - zend_bool nested = EX(nested); - zend_execute_data *prev_execute_data = EX(prev_execute_data); - - if (EG(return_value_ptr_ptr)) { - zval *return_value; - zend_generator *generator; - - ALLOC_INIT_ZVAL(return_value); - object_init_ex(return_value, zend_ce_generator); - - *EG(return_value_ptr_ptr) = return_value; - - /* back up some executor globals */ - SAVE_OPLINE(); - - EX(current_scope) = EG(scope); - EX(current_called_scope) = EG(called_scope); - - if (EG(This)) { - Z_ADDREF_P(EG(This)); - } - EX(current_this) = EG(This); - - /* back up the execution context */ - generator = (zend_generator *) zend_object_store_get_object(return_value TSRMLS_CC); - generator->execute_data = execute_data; - - /* We have to add another stack frame so the generator function shows - * up in backtraces and func_get_all() can access the function - * arguments. */ - EX(prev_execute_data) = emalloc(sizeof(zend_execute_data)); - if (prev_execute_data) { - memcpy(EX(prev_execute_data), prev_execute_data, sizeof(zend_execute_data)); - EX(prev_execute_data)->function_state.arguments = zend_copy_arguments(prev_execute_data->function_state.arguments); - } else { - memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); - EX(prev_execute_data)->function_state.function = (zend_function *) EX(op_array); - EX(prev_execute_data)->function_state.arguments = NULL; - } - } - - /* restore the previous execution context */ - EG(current_execute_data) = prev_execute_data; - - /* if there is no return value pointer we are responsible for freeing the - * execution data */ - if (!EG(return_value_ptr_ptr)) { - if (!EG(active_symbol_table)) { - zend_free_compiled_variables(EX_CVs(), execute_data->op_array->last_var); - } else { - zend_clean_and_cache_symbol_table(EG(active_symbol_table) TSRMLS_CC); - } - efree(execute_data); - } - - - /* Happens whenever the function is invoked using call_user_function, - * e.g. when doing a dynamic function call using call_user_func(). */ - if (!nested) { - EG(opline_ptr) = NULL; - ZEND_VM_RETURN(); - } - - /* Free $this and stack arguments */ - if (EG(This)) { - zval_ptr_dtor(&EG(This)); - } - - zend_vm_stack_clear_multiple(TSRMLS_C); - - /* Bring back the previous execution context */ - execute_data = EG(current_execute_data); - - EG(opline_ptr) = &EX(opline); - EG(active_op_array) = EX(op_array); - EG(return_value_ptr_ptr) = EX(original_return_value); - EG(active_symbol_table) = EX(symbol_table); - EG(This) = EX(current_this); - EG(scope) = EX(current_scope); - EG(called_scope) = EX(current_called_scope); - - EX(function_state).function = (zend_function *) EX(op_array); - EX(function_state).arguments = NULL; - - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); - - LOAD_REGS(); - LOAD_OPLINE(); - ZEND_VM_INC_OPCODE(); - ZEND_VM_LEAVE(); -} - -ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) +ZEND_VM_HANDLER(159, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) { USE_OPLINE zend_free_op free_op1; @@ -5454,6 +5363,10 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -5461,7 +5374,7 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE ZEND_VM_RETURN(); } -ZEND_VM_HANDLER(161, ZEND_DELEGATE_YIELD, CONST|TMP|VAR|CV, ANY) +ZEND_VM_HANDLER(160, ZEND_DELEGATE_YIELD, CONST|TMP|VAR|CV, ANY) { ZEND_VM_NEXT_OPCODE(); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index b1bcd74d2332b..0fcae113baa45 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -339,7 +339,7 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #define EX_Ts() EX(Ts) -static zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) { +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) { zend_execute_data *execute_data; /* @@ -689,7 +689,11 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; } - if (EXPECTED(zend_execute == execute)) { + if (EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) { + if (RETURN_VALUE_USED(opline)) { + EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); + } + } else if (EXPECTED(zend_execute == execute)) { if (EXPECTED(EG(exception) == NULL)) { ZEND_VM_ENTER(); } @@ -1201,101 +1205,6 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } -static int ZEND_FASTCALL ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - zend_bool nested = EX(nested); - zend_execute_data *prev_execute_data = EX(prev_execute_data); - - if (EG(return_value_ptr_ptr)) { - zval *return_value; - zend_generator *generator; - - ALLOC_INIT_ZVAL(return_value); - object_init_ex(return_value, zend_ce_generator); - - *EG(return_value_ptr_ptr) = return_value; - - /* back up some executor globals */ - SAVE_OPLINE(); - - EX(current_scope) = EG(scope); - EX(current_called_scope) = EG(called_scope); - - if (EG(This)) { - Z_ADDREF_P(EG(This)); - } - EX(current_this) = EG(This); - - /* back up the execution context */ - generator = (zend_generator *) zend_object_store_get_object(return_value TSRMLS_CC); - generator->execute_data = execute_data; - - /* We have to add another stack frame so the generator function shows - * up in backtraces and func_get_all() can access the function - * arguments. */ - EX(prev_execute_data) = emalloc(sizeof(zend_execute_data)); - if (prev_execute_data) { - memcpy(EX(prev_execute_data), prev_execute_data, sizeof(zend_execute_data)); - EX(prev_execute_data)->function_state.arguments = zend_copy_arguments(prev_execute_data->function_state.arguments); - } else { - memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); - EX(prev_execute_data)->function_state.function = (zend_function *) EX(op_array); - EX(prev_execute_data)->function_state.arguments = NULL; - } - } - - /* restore the previous execution context */ - EG(current_execute_data) = prev_execute_data; - - /* if there is no return value pointer we are responsible for freeing the - * execution data */ - if (!EG(return_value_ptr_ptr)) { - if (!EG(active_symbol_table)) { - zend_free_compiled_variables(EX_CVs(), execute_data->op_array->last_var); - } else { - zend_clean_and_cache_symbol_table(EG(active_symbol_table) TSRMLS_CC); - } - efree(execute_data); - } - - - /* Happens whenever the function is invoked using call_user_function, - * e.g. when doing a dynamic function call using call_user_func(). */ - if (!nested) { - EG(opline_ptr) = NULL; - ZEND_VM_RETURN(); - } - - /* Free $this and stack arguments */ - if (EG(This)) { - zval_ptr_dtor(&EG(This)); - } - - zend_vm_stack_clear_multiple(TSRMLS_C); - - /* Bring back the previous execution context */ - execute_data = EG(current_execute_data); - - EG(opline_ptr) = &EX(opline); - EG(active_op_array) = EX(op_array); - EG(return_value_ptr_ptr) = EX(original_return_value); - EG(active_symbol_table) = EX(symbol_table); - EG(This) = EX(current_this); - EG(scope) = EX(current_scope); - EG(called_scope) = EX(current_called_scope); - - EX(function_state).function = (zend_function *) EX(op_array); - EX(function_state).arguments = NULL; - - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); - - LOAD_REGS(); - LOAD_OPLINE(); - ZEND_VM_INC_OPCODE(); - ZEND_VM_LEAVE(); -} - static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -4252,6 +4161,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -4937,6 +4850,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -5948,6 +5865,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -6652,6 +6573,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -7396,6 +7321,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -9448,6 +9377,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -10133,6 +10066,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -11144,6 +11081,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -11714,6 +11655,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -12396,6 +12341,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -16306,6 +16255,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -18379,6 +18332,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -20833,6 +20790,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -21964,6 +21925,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -24086,6 +24051,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -25565,6 +25534,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -26868,6 +26841,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -28172,6 +28149,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -28586,6 +28567,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -29886,6 +29871,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -33395,6 +33384,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -35337,6 +35330,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -37659,6 +37656,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -38649,6 +38650,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -40639,6 +40644,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS Z_ADDREF(EG(uninitialized_zval)); AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + /* We increment to the next op, so we are at the correct position when the + * generator is resumed. */ + ZEND_VM_INC_OPCODE(); + /* The GOTO VM uses a local opline variable. We need to set the opline * variable in execute_data so we don't resume at an old position. */ SAVE_OPLINE(); @@ -44630,31 +44639,6 @@ void zend_init_opcodes_handlers(void) ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, - ZEND_SUSPEND_AND_RETURN_GENERATOR_SPEC_HANDLER, ZEND_YIELD_SPEC_CONST_CONST_HANDLER, ZEND_YIELD_SPEC_CONST_TMP_HANDLER, ZEND_YIELD_SPEC_CONST_VAR_HANDLER, diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index e77c7cb3c63be..909ec8ad7a734 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -1,6 +1,6 @@ {%DEFINES%} -static zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) { +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) { zend_execute_data *execute_data; /* diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 46a711d179314..87fabfc2acc10 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -159,6 +159,5 @@ #define ZEND_SEPARATE 156 #define ZEND_QM_ASSIGN_VAR 157 #define ZEND_JMP_SET_VAR 158 -#define ZEND_SUSPEND_AND_RETURN_GENERATOR 159 -#define ZEND_YIELD 160 -#define ZEND_DELEGATE_YIELD 161 +#define ZEND_YIELD 159 +#define ZEND_DELEGATE_YIELD 160 From 612c2490b7973d71d472860ade48d7ab342b5911 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 20 Jul 2012 17:38:39 +0200 Subject: [PATCH 1948/2394] Move a variable --- Zend/zend_vm_def.h | 3 +- Zend/zend_vm_execute.h | 75 ++++++++++++++++++++++++++++-------------- 2 files changed, 52 insertions(+), 26 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index e8b89a6db5b36..6b8425558c984 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5225,7 +5225,6 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_HANDLER(159, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -5242,6 +5241,8 @@ ZEND_VM_HANDLER(159, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE /* Set the new yielded value */ if (OP1_TYPE != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 0fcae113baa45..9a9917fede26b 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -4027,7 +4027,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -4043,6 +4042,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -4716,7 +4717,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -4732,6 +4732,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -5730,7 +5732,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -5746,6 +5747,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -6439,7 +6442,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -6455,6 +6457,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -7187,7 +7191,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -7203,6 +7206,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A /* Set the new yielded value */ if (IS_CONST != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -9242,7 +9247,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -9259,6 +9263,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -9931,7 +9937,6 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDL static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -9948,6 +9953,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -10945,7 +10952,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -10962,6 +10968,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -11520,7 +11528,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OP static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -11537,6 +11544,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -12206,7 +12215,6 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLE static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -12223,6 +12231,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_TMP_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -16118,7 +16128,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER(ZEN static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -16135,6 +16144,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -18195,7 +18206,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -18212,6 +18222,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -20652,7 +20664,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -20669,6 +20680,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -21788,7 +21801,6 @@ static int ZEND_FASTCALL ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAND static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -21805,6 +21817,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -23914,7 +23928,6 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER(ZEND_O static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_free_op free_op1; /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -23931,6 +23944,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_VAR != IS_UNUSED) { + zend_free_op free_op1; + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -25400,7 +25415,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -25416,6 +25430,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -26707,7 +26723,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -26723,6 +26738,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -28014,7 +28031,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -28030,6 +28046,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -28433,7 +28451,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -28449,6 +28466,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -29737,7 +29756,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -29753,6 +29771,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_UNUSED != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -33250,7 +33270,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -33266,6 +33285,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -35196,7 +35217,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -35212,6 +35232,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -37521,7 +37543,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -37537,6 +37558,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -38516,7 +38539,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -38532,6 +38554,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ @@ -40510,7 +40534,6 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS { USE_OPLINE - /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -40526,6 +40549,8 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* Set the new yielded value */ if (IS_CV != IS_UNUSED) { + + if (EX(op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) { /* Constants and temporary variables aren't yieldable by reference, * but we still allow them with a notice. */ From 1f70a4c5fea97aa577aa5d9ee5f33d91d70e690d Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 20 Jul 2012 17:40:04 +0200 Subject: [PATCH 1949/2394] Add some more tests --- Zend/tests/generators/fibonacci.phpt | 36 +++++++++++++++++++ Zend/tests/generators/generator_closure.phpt | 20 +++++++++++ .../generator_closure_with_this.phpt | 20 +++++++++++ .../generators/generator_static_method.phpt | 29 +++++++++++++++ 4 files changed, 105 insertions(+) create mode 100644 Zend/tests/generators/fibonacci.phpt create mode 100644 Zend/tests/generators/generator_closure.phpt create mode 100644 Zend/tests/generators/generator_closure_with_this.phpt create mode 100644 Zend/tests/generators/generator_static_method.phpt diff --git a/Zend/tests/generators/fibonacci.phpt b/Zend/tests/generators/fibonacci.phpt new file mode 100644 index 0000000000000..35b31352ff3e7 --- /dev/null +++ b/Zend/tests/generators/fibonacci.phpt @@ -0,0 +1,36 @@ +--TEST-- +Creating an infinite fibonacci list using a generator +--FILE-- + 1000) break; + + var_dump($n); +} + +?> +--EXPECT-- +int(1) +int(2) +int(3) +int(5) +int(8) +int(13) +int(21) +int(34) +int(55) +int(89) +int(144) +int(233) +int(377) +int(610) +int(987) diff --git a/Zend/tests/generators/generator_closure.phpt b/Zend/tests/generators/generator_closure.phpt new file mode 100644 index 0000000000000..bf80066015f5e --- /dev/null +++ b/Zend/tests/generators/generator_closure.phpt @@ -0,0 +1,20 @@ +--TEST-- +Closures can be generators +--FILE-- + +--EXPECT-- +int(1) +int(2) +int(3) diff --git a/Zend/tests/generators/generator_closure_with_this.phpt b/Zend/tests/generators/generator_closure_with_this.phpt new file mode 100644 index 0000000000000..d5a4861e80461 --- /dev/null +++ b/Zend/tests/generators/generator_closure_with_this.phpt @@ -0,0 +1,20 @@ +--TEST-- +Non-static closures can be generators +--FILE-- +getGenFactory(); +var_dump($genFactory()->current()); + +?> +--EXPECT-- +object(Test)#1 (0) { +} diff --git a/Zend/tests/generators/generator_static_method.phpt b/Zend/tests/generators/generator_static_method.phpt new file mode 100644 index 0000000000000..cd9b450a76caf --- /dev/null +++ b/Zend/tests/generators/generator_static_method.phpt @@ -0,0 +1,29 @@ +--TEST-- +A static method can be a generator +--FILE-- + +--EXPECT-- +string(4) "Test" +string(12) "ExtendedTest" +int(1) +int(2) +int(3) From 80748631aa1c4193cbc68f8854d82e7a57817fe2 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 21 Jul 2012 21:05:46 +0200 Subject: [PATCH 1950/2394] Require parenthesis around yield expressions If yield is used in an expression context parenthesis are now required. This ensures that the code is unambiguos. Yield statements can still be used without parenthesis (which should be the most common case). Also yield expressions without value can be used without parenthesis, too (this should be the most common case for coroutines). If the yield expression is used in a context where parenthesis are required anyway, no additional parenthesis have to be inserted. Examples: // Statements don't need parenthesis yield $foo; yield $foo => $bar; // Yield without value doesn't need parenthesis either $data = yield; // Parentheses don't have to be duplicated foo(yield $bar); if (yield $bar) { ... } // But we have to use parentheses here $foo = (yield $bar); This commit also fixes an issue with by-ref passing of $foo[0] like variables. They previously weren't properly fetched for write. Additionally this fixes valgrind warnings which were caused by access to uninitialized memory in zend_is_function_or_method_call(). --- .../generators/send_returns_current.phpt | 2 +- .../generators/yield_array_offset_by_ref.phpt | 26 ++++++ .../generators/yield_in_parenthesis.phpt | 23 +++++ Zend/zend_compile.c | 12 ++- Zend/zend_compile.h | 2 +- Zend/zend_language_parser.y | 91 ++++++++++--------- 6 files changed, 109 insertions(+), 47 deletions(-) create mode 100644 Zend/tests/generators/yield_array_offset_by_ref.phpt create mode 100644 Zend/tests/generators/yield_in_parenthesis.phpt diff --git a/Zend/tests/generators/send_returns_current.phpt b/Zend/tests/generators/send_returns_current.phpt index fc260c0af0c41..27ba74bc1bd86 100644 --- a/Zend/tests/generators/send_returns_current.phpt +++ b/Zend/tests/generators/send_returns_current.phpt @@ -6,7 +6,7 @@ $generator->send() returns the yielded value function reverseEchoGenerator() { $data = yield; while (true) { - $data = yield strrev($data); + $data = (yield strrev($data)); } } diff --git a/Zend/tests/generators/yield_array_offset_by_ref.phpt b/Zend/tests/generators/yield_array_offset_by_ref.phpt new file mode 100644 index 0000000000000..544108e64d89b --- /dev/null +++ b/Zend/tests/generators/yield_array_offset_by_ref.phpt @@ -0,0 +1,26 @@ +--TEST-- +Array offsets can be yielded by reference +--FILE-- + +--EXPECT-- +array(3) { + [0]=> + &int(-1) + [1]=> + int(2) + [2]=> + int(3) +} diff --git a/Zend/tests/generators/yield_in_parenthesis.phpt b/Zend/tests/generators/yield_in_parenthesis.phpt new file mode 100644 index 0000000000000..4a603f4cc1a50 --- /dev/null +++ b/Zend/tests/generators/yield_in_parenthesis.phpt @@ -0,0 +1,23 @@ +--TEST-- +No additional parenthesis are required around yield if they are already present +--FILE-- +func(yield $foo); + new Foo(yield $foo); +} + +echo "Done"; + +?> +--EXPECT-- +Done diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index e030f94c78b40..51fc8c3e5be3b 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2663,7 +2663,7 @@ void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC) /* {{{ */ } /* }}} */ -void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC) /* {{{ */ +void zend_do_yield(znode *result, znode *value, const znode *key, zend_bool is_variable TSRMLS_DC) /* {{{ */ { zend_op *opline; @@ -2673,6 +2673,14 @@ void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC CG(active_op_array)->fn_flags |= ZEND_ACC_GENERATOR; + if (is_variable) { + if ((CG(active_op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) && !zend_is_function_or_method_call(value)) { + zend_do_end_variable_parse(value, BP_VAR_W, 0 TSRMLS_CC); + } else { + zend_do_end_variable_parse(value, BP_VAR_R, 0 TSRMLS_CC); + } + } + opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_YIELD; @@ -2680,7 +2688,7 @@ void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC if (value) { SET_NODE(opline->op1, value); - if (zend_is_function_or_method_call(value)) { + if (is_variable && zend_is_function_or_method_call(value)) { opline->extended_value = ZEND_RETURNS_FUNCTION; } } else { diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index c4355e0dde0ed..1972f85c66785 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -490,7 +490,7 @@ void zend_do_build_full_name(znode *result, znode *prefix, znode *name, int is_c int zend_do_begin_class_member_function_call(znode *class_name, znode *method_name TSRMLS_DC); void zend_do_end_function_call(znode *function_name, znode *result, const znode *argument_list, int is_method, int is_dynamic_fcall TSRMLS_DC); void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC); -void zend_do_yield(znode *result, const znode *value, const znode *key TSRMLS_DC); +void zend_do_yield(znode *result, znode *value, const znode *key, zend_bool is_variable TSRMLS_DC); void zend_do_delegate_yield(znode *result, const znode *value TSRMLS_DC); void zend_do_handle_exception(TSRMLS_D); diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index b705d60d9a530..e5f31b5d149a8 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -278,10 +278,10 @@ statement: unticked_statement: '{' inner_statement_list '}' - | T_IF '(' expr ')' { zend_do_if_cond(&$3, &$4 TSRMLS_CC); } statement { zend_do_if_after_statement(&$4, 1 TSRMLS_CC); } elseif_list else_single { zend_do_if_end(TSRMLS_C); } - | T_IF '(' expr ')' ':' { zend_do_if_cond(&$3, &$4 TSRMLS_CC); } inner_statement_list { zend_do_if_after_statement(&$4, 1 TSRMLS_CC); } new_elseif_list new_else_single T_ENDIF ';' { zend_do_if_end(TSRMLS_C); } - | T_WHILE '(' { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); } expr ')' { zend_do_while_cond(&$4, &$5 TSRMLS_CC); } while_statement { zend_do_while_end(&$1, &$5 TSRMLS_CC); } - | T_DO { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); zend_do_do_while_begin(TSRMLS_C); } statement T_WHILE '(' { $5.u.op.opline_num = get_next_op_number(CG(active_op_array)); } expr ')' ';' { zend_do_do_while_end(&$1, &$5, &$7 TSRMLS_CC); } + | T_IF parenthesis_expr { zend_do_if_cond(&$2, &$1 TSRMLS_CC); } statement { zend_do_if_after_statement(&$1, 1 TSRMLS_CC); } elseif_list else_single { zend_do_if_end(TSRMLS_C); } + | T_IF parenthesis_expr ':' { zend_do_if_cond(&$2, &$1 TSRMLS_CC); } inner_statement_list { zend_do_if_after_statement(&$1, 1 TSRMLS_CC); } new_elseif_list new_else_single T_ENDIF ';' { zend_do_if_end(TSRMLS_C); } + | T_WHILE { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); } parenthesis_expr { zend_do_while_cond(&$3, &$$ TSRMLS_CC); } while_statement { zend_do_while_end(&$1, &$4 TSRMLS_CC); } + | T_DO { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); zend_do_do_while_begin(TSRMLS_C); } statement T_WHILE { $4.u.op.opline_num = get_next_op_number(CG(active_op_array)); } parenthesis_expr ';' { zend_do_do_while_end(&$1, &$4, &$6 TSRMLS_CC); } | T_FOR '(' for_expr @@ -291,7 +291,7 @@ unticked_statement: for_expr ')' { zend_do_free(&$9 TSRMLS_CC); zend_do_for_before_statement(&$4, &$7 TSRMLS_CC); } for_statement { zend_do_for_end(&$7 TSRMLS_CC); } - | T_SWITCH '(' expr ')' { zend_do_switch_cond(&$3 TSRMLS_CC); } switch_case_list { zend_do_switch_end(&$6 TSRMLS_CC); } + | T_SWITCH parenthesis_expr { zend_do_switch_cond(&$2 TSRMLS_CC); } switch_case_list { zend_do_switch_end(&$4 TSRMLS_CC); } | T_BREAK ';' { zend_do_brk_cont(ZEND_BRK, NULL TSRMLS_CC); } | T_BREAK expr ';' { zend_do_brk_cont(ZEND_BRK, &$2 TSRMLS_CC); } | T_CONTINUE ';' { zend_do_brk_cont(ZEND_CONT, NULL TSRMLS_CC); } @@ -299,7 +299,7 @@ unticked_statement: | T_RETURN ';' { zend_do_return(NULL, 0 TSRMLS_CC); } | T_RETURN expr_without_variable ';' { zend_do_return(&$2, 0 TSRMLS_CC); } | T_RETURN variable ';' { zend_do_return(&$2, 1 TSRMLS_CC); } - | T_YIELD expr T_DOUBLE_ARROW expr ';' { zend_do_yield(&$$, &$4, &$2 TSRMLS_CC); } + | yield_expr ';' { $$ = $1; } | T_GLOBAL global_var_list ';' | T_STATIC static_var_list ';' | T_ECHO echo_expr_list ';' @@ -484,13 +484,13 @@ while_statement: elseif_list: /* empty */ - | elseif_list T_ELSEIF '(' expr ')' { zend_do_if_cond(&$4, &$5 TSRMLS_CC); } statement { zend_do_if_after_statement(&$5, 0 TSRMLS_CC); } + | elseif_list T_ELSEIF parenthesis_expr { zend_do_if_cond(&$3, &$2 TSRMLS_CC); } statement { zend_do_if_after_statement(&$2, 0 TSRMLS_CC); } ; new_elseif_list: /* empty */ - | new_elseif_list T_ELSEIF '(' expr ')' ':' { zend_do_if_cond(&$4, &$5 TSRMLS_CC); } inner_statement_list { zend_do_if_after_statement(&$5, 0 TSRMLS_CC); } + | new_elseif_list T_ELSEIF parenthesis_expr ':' { zend_do_if_cond(&$3, &$2 TSRMLS_CC); } inner_statement_list { zend_do_if_after_statement(&$2, 0 TSRMLS_CC); } ; @@ -533,8 +533,9 @@ optional_class_type: function_call_parameter_list: - non_empty_function_call_parameter_list { $$ = $1; } - | /* empty */ { Z_LVAL($$.u.constant) = 0; } + '(' ')' { Z_LVAL($$.u.constant) = 0; } + | '(' non_empty_function_call_parameter_list ')' { $$ = $2; } + | '(' yield_expr ')' { Z_LVAL($$.u.constant) = 1; zend_do_pass_param(&$2, ZEND_SEND_VAL, Z_LVAL($$.u.constant) TSRMLS_CC); } ; @@ -774,7 +775,7 @@ expr_without_variable: | expr '>' expr { zend_do_binary_op(ZEND_IS_SMALLER, &$$, &$3, &$1 TSRMLS_CC); } | expr T_IS_GREATER_OR_EQUAL expr { zend_do_binary_op(ZEND_IS_SMALLER_OR_EQUAL, &$$, &$3, &$1 TSRMLS_CC); } | expr T_INSTANCEOF class_name_reference { zend_do_instanceof(&$$, &$1, &$3, 0 TSRMLS_CC); } - | '(' expr ')' { $$ = $2; } + | parenthesis_expr { $$ = $1; } | new_expr { $$ = $1; } | '(' new_expr ')' { $$ = $2; } instance_call { $$ = $5; } | expr '?' { zend_do_begin_qm_op(&$1, &$2 TSRMLS_CC); } @@ -797,8 +798,9 @@ expr_without_variable: | combined_scalar { $$ = $1; } | '`' backticks_expr '`' { zend_do_shell_exec(&$$, &$2 TSRMLS_CC); } | T_PRINT expr { zend_do_print(&$$, &$2 TSRMLS_CC); } - | T_YIELD { zend_do_yield(&$$, NULL, NULL TSRMLS_CC); } - | T_YIELD expr { zend_do_yield(&$$, &$2, NULL TSRMLS_CC); } + | T_YIELD { zend_do_yield(&$$, NULL, NULL, 0 TSRMLS_CC); } + /*| T_YIELD expr_without_variable { zend_do_yield(&$$, &$2, NULL, 0 TSRMLS_CC); } + | T_YIELD variable { zend_do_yield(&$$, &$2, NULL, 1 TSRMLS_CC); }*/ | T_YIELD '*' expr { zend_do_delegate_yield(&$$, &$3 TSRMLS_CC); } | function is_reference { zend_do_begin_lambda_function_declaration(&$$, &$1, $2.op_type, 0 TSRMLS_CC); } '(' parameter_list ')' lexical_vars @@ -808,6 +810,13 @@ expr_without_variable: '{' inner_statement_list '}' { zend_do_end_function_declaration(&$2 TSRMLS_CC); $$ = $4; } ; +yield_expr: + T_YIELD expr_without_variable { zend_do_yield(&$$, &$2, NULL, 0 TSRMLS_CC); } + | T_YIELD variable { zend_do_yield(&$$, &$2, NULL, 1 TSRMLS_CC); } + | T_YIELD expr T_DOUBLE_ARROW expr_without_variable { zend_do_yield(&$$, &$4, &$2, 0 TSRMLS_CC); } + | T_YIELD expr T_DOUBLE_ARROW variable { zend_do_yield(&$$, &$4, &$2, 1 TSRMLS_CC); } +; + combined_scalar_offset: combined_scalar '[' dim_offset ']' { zend_do_begin_variable_parse(TSRMLS_C); fetch_array_dim(&$$, &$1, &$3 TSRMLS_CC); } | combined_scalar_offset '[' dim_offset ']' { fetch_array_dim(&$$, &$1, &$3 TSRMLS_CC); } @@ -834,30 +843,22 @@ lexical_var_list: ; function_call: - namespace_name '(' { $2.u.op.opline_num = zend_do_begin_function_call(&$1, 1 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call(&$1, &$$, &$4, 0, $2.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } - | T_NAMESPACE T_NS_SEPARATOR namespace_name '(' { $1.op_type = IS_CONST; ZVAL_EMPTY_STRING(&$1.u.constant); zend_do_build_namespace_name(&$1, &$1, &$3 TSRMLS_CC); $4.u.op.opline_num = zend_do_begin_function_call(&$1, 0 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call(&$1, &$$, &$6, 0, $4.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } - | T_NS_SEPARATOR namespace_name '(' { $3.u.op.opline_num = zend_do_begin_function_call(&$2, 0 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call(&$2, &$$, &$5, 0, $3.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } - | class_name T_PAAMAYIM_NEKUDOTAYIM variable_name '(' { $4.u.op.opline_num = zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call($4.u.op.opline_num?NULL:&$3, &$$, &$6, $4.u.op.opline_num, $4.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} - | class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects '(' { zend_do_end_variable_parse(&$3, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} - | variable_class_name T_PAAMAYIM_NEKUDOTAYIM variable_name '(' { zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} - | variable_class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects '(' { zend_do_end_variable_parse(&$3, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } - function_call_parameter_list - ')' { zend_do_end_function_call(NULL, &$$, &$6, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} - | variable_without_objects '(' { zend_do_end_variable_parse(&$1, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_dynamic_function_call(&$1, 0 TSRMLS_CC); } - function_call_parameter_list ')' - { zend_do_end_function_call(&$1, &$$, &$4, 0, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} + namespace_name { $$.u.op.opline_num = zend_do_begin_function_call(&$1, 1 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(&$1, &$$, &$3, 0, $2.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } + | T_NAMESPACE T_NS_SEPARATOR namespace_name { $1.op_type = IS_CONST; ZVAL_EMPTY_STRING(&$1.u.constant); zend_do_build_namespace_name(&$1, &$1, &$3 TSRMLS_CC); $$.u.op.opline_num = zend_do_begin_function_call(&$1, 0 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(&$1, &$$, &$5, 0, $4.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } + | T_NS_SEPARATOR namespace_name { $$.u.op.opline_num = zend_do_begin_function_call(&$2, 0 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(&$2, &$$, &$4, 0, $3.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } + | class_name T_PAAMAYIM_NEKUDOTAYIM variable_name { $$.u.op.opline_num = zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call($4.u.op.opline_num?NULL:&$3, &$$, &$5, $4.u.op.opline_num, $4.u.op.opline_num TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} + | class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects { zend_do_end_variable_parse(&$3, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(NULL, &$$, &$5, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} + | variable_class_name T_PAAMAYIM_NEKUDOTAYIM variable_name { zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(NULL, &$$, &$5, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} + | variable_class_name T_PAAMAYIM_NEKUDOTAYIM variable_without_objects { zend_do_end_variable_parse(&$3, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_class_member_function_call(&$1, &$3 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(NULL, &$$, &$5, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} + | variable_without_objects { zend_do_end_variable_parse(&$1, BP_VAR_R, 0 TSRMLS_CC); zend_do_begin_dynamic_function_call(&$1, 0 TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(&$1, &$$, &$3, 0, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C);} ; class_name: @@ -902,7 +903,7 @@ dynamic_class_name_variable_property: exit_expr: /* empty */ { memset(&$$, 0, sizeof(znode)); $$.op_type = IS_UNUSED; } | '(' ')' { memset(&$$, 0, sizeof(znode)); $$.op_type = IS_UNUSED; } - | '(' expr ')' { $$ = $2; } + | parenthesis_expr { $$ = $1; } ; backticks_expr: @@ -913,8 +914,8 @@ backticks_expr: ctor_arguments: - /* empty */ { Z_LVAL($$.u.constant)=0; } - | '(' function_call_parameter_list ')' { $$ = $2; } + /* empty */ { Z_LVAL($$.u.constant) = 0; } + | function_call_parameter_list { $$ = $1; } ; @@ -986,6 +987,11 @@ expr: | expr_without_variable { $$ = $1; } ; +parenthesis_expr: + '(' expr ')' { $$ = $2; } + | '(' yield_expr ')' { $$ = $2; } +; + r_variable: variable { zend_do_end_variable_parse(&$1, BP_VAR_R, 0 TSRMLS_CC); $$ = $1; } @@ -1025,9 +1031,8 @@ array_method_dereference: ; method: - '(' { zend_do_pop_object(&$1 TSRMLS_CC); zend_do_begin_method_call(&$1 TSRMLS_CC); } - function_call_parameter_list ')' - { zend_do_end_function_call(&$1, &$$, &$3, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } + { zend_do_pop_object(&$$ TSRMLS_CC); zend_do_begin_method_call(&$$ TSRMLS_CC); } + function_call_parameter_list { zend_do_end_function_call(&$1, &$$, &$2, 1, 1 TSRMLS_CC); zend_do_extended_fcall_end(TSRMLS_C); } ; method_or_not: From 29a0efccef0ea3843e1b68546bdc255d5b901746 Mon Sep 17 00:00:00 2001 From: Sherif Ramadan Date: Sat, 21 Jul 2012 19:38:03 -0400 Subject: [PATCH 1951/2394] Fixes mcrypt_ecb not issuing an E_DEPRECATED level notice, despite having been deprecated for some time. Please reference bug #62374 as well. --- ext/mcrypt/mcrypt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c index c5739395891d5..20a0f73b187d6 100644 --- a/ext/mcrypt/mcrypt.c +++ b/ext/mcrypt/mcrypt.c @@ -238,7 +238,7 @@ ZEND_END_ARG_INFO() /* }}} */ const zend_function_entry mcrypt_functions[] = { /* {{{ */ - PHP_FE(mcrypt_ecb, arginfo_mcrypt_ecb) + PHP_DEP_FE(mcrypt_ecb, arginfo_mcrypt_ecb) PHP_FE(mcrypt_cbc, arginfo_mcrypt_cbc) PHP_FE(mcrypt_cfb, arginfo_mcrypt_cfb) PHP_FE(mcrypt_ofb, arginfo_mcrypt_ofb) From 2f0775b999e7859275c614a3d2d8edd1506e0d68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sun, 22 Jul 2012 03:54:03 +0200 Subject: [PATCH 1952/2394] Added IntlDateFormatter::formatObject(). Refactor To better support IntlCalendar, added this function: string IntlDateFormatter::formatObject(IntlCalendar|DateTime $obj [, array|int|string $format = null [, string $locale = null). $format is either of the constants IntlDateFormatter::FULL, etc., in which case this format applies to both the date and the time, an array in the form array($dateFormat, $timeFormat), or a string with the SimpleDateFormat pattern. This uses both the Calendar type and the timezone of the passed object to configure the formatter (a GregorianCalendar is forced for DateTime). Some stuff was moved around and slighlt modified to allow for more code reuse. --- ext/intl/calendar/calendar_methods.cpp | 3 + ext/intl/common/common_date.cpp | 206 ++++++++++++++-- ext/intl/common/common_date.h | 13 +- ext/intl/config.m4 | 1 + ext/intl/config.w32 | 1 + ext/intl/dateformat/dateformat_class.c | 8 + ext/intl/dateformat/dateformat_format.c | 9 +- .../dateformat/dateformat_format_object.cpp | 230 ++++++++++++++++++ .../dateformat/dateformat_format_object.h | 19 ++ ext/intl/msgformat/msgformat_helpers.cpp | 10 +- ext/intl/php_intl.c | 9 + ext/intl/tests/dateformat_format.phpt | 10 +- .../dateformat_formatObject_calendar.phpt | 41 ++++ .../dateformat_formatObject_datetime.phpt | 34 +++ .../tests/dateformat_formatObject_error.phpt | 74 ++++++ ext/intl/tests/msgfmt_format_error5.phpt | 1 + ext/intl/timezone/timezone_class.cpp | 75 +----- ext/intl/timezone/timezone_class.h | 1 - ext/intl/timezone/timezone_methods.cpp | 3 + 19 files changed, 633 insertions(+), 115 deletions(-) create mode 100644 ext/intl/dateformat/dateformat_format_object.cpp create mode 100644 ext/intl/dateformat/dateformat_format_object.h create mode 100644 ext/intl/tests/dateformat_formatObject_calendar.phpt create mode 100644 ext/intl/tests/dateformat_formatObject_datetime.phpt create mode 100644 ext/intl/tests/dateformat_formatObject_error.phpt diff --git a/ext/intl/calendar/calendar_methods.cpp b/ext/intl/calendar/calendar_methods.cpp index 8562a2d69eaf4..f59edaa25e333 100644 --- a/ext/intl/calendar/calendar_methods.cpp +++ b/ext/intl/calendar/calendar_methods.cpp @@ -23,7 +23,10 @@ #include #include #include + #include "../intl_convertcpp.h" +#include "../common/common_date.h" + extern "C" { #define USE_TIMEZONE_POINTER 1 #include "../timezone/timezone_class.h" diff --git a/ext/intl/common/common_date.cpp b/ext/intl/common/common_date.cpp index 812a196ed0fef..ee998818d989f 100644 --- a/ext/intl/common/common_date.cpp +++ b/ext/intl/common/common_date.cpp @@ -25,13 +25,162 @@ extern "C" { #include } -U_CFUNC double intl_zval_to_millis(zval *z, UErrorCode *status TSRMLS_DC) +#ifndef INFINITY +#define INFINITY (DBL_MAX+DBL_MAX) +#endif + +#ifndef NAN +#define NAN (INFINITY-INFINITY) +#endif + +/* {{{ timezone_convert_datetimezone + * The timezone in DateTime and DateTimeZone is not unified. */ +U_CFUNC TimeZone *timezone_convert_datetimezone(int type, + void *object, + int is_datetime, + intl_error *outside_error, + const char *func TSRMLS_DC) { - double rv = NAN; - long lv; - int type; + char *id = NULL, + offset_id[] = "GMT+00:00"; + int id_len = 0; + char *message; + TimeZone *timeZone; + + switch (type) { + case TIMELIB_ZONETYPE_ID: + id = is_datetime + ? ((php_date_obj*)object)->time->tz_info->name + : ((php_timezone_obj*)object)->tzi.tz->name; + id_len = strlen(id); + break; + case TIMELIB_ZONETYPE_OFFSET: { + int offset_mins = is_datetime + ? -((php_date_obj*)object)->time->z + : -(int)((php_timezone_obj*)object)->tzi.utc_offset, + hours = offset_mins / 60, + minutes = offset_mins - hours * 60; + minutes *= minutes > 0 ? 1 : -1; + + if (offset_mins <= -24 * 60 || offset_mins >= 24 * 60) { + spprintf(&message, 0, "%s: object has an time zone offset " + "that's too large", func); + intl_errors_set(outside_error, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); + return NULL; + } - if (U_FAILURE(*status)) { + id = offset_id; + id_len = slprintf(id, sizeof(offset_id), "GMT%+03d:%02d", + hours, minutes); + break; + } + case TIMELIB_ZONETYPE_ABBR: + id = is_datetime + ? ((php_date_obj*)object)->time->tz_abbr + : ((php_timezone_obj*)object)->tzi.z.abbr; + id_len = strlen(id); + break; + } + + UnicodeString s = UnicodeString(id, id_len, US_INV); + timeZone = TimeZone::createTimeZone(s); +#if U_ICU_VERSION_MAJOR_NUM >= 49 + if (*timeZone == TimeZone::getUnknown()) { +#else + UnicodeString resultingId; + timeZone->getID(resultingId); + if (resultingId == UnicodeString("Etc/Unknown", -1, US_INV) + || resultingId == UnicodeString("GMT", -1, US_INV)) { +#endif + spprintf(&message, 0, "%s: time zone id '%s' " + "extracted from ext/date DateTimeZone not recognized", func, id); + intl_errors_set(outside_error, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); + delete timeZone; + return NULL; + } + return timeZone; +} +/* }}} */ + +U_CFUNC int intl_datetime_decompose(zval *z, double *millis, TimeZone **tz, + intl_error *err, const char *func TSRMLS_DC) +{ + zval retval; + zval *zfuncname; + char *message; + + if (err && U_FAILURE(err->code)) { + return FAILURE; + } + + if (millis) { + *millis = NAN; + } + if (tz) { + *tz = NULL; + } + + if (millis) { + INIT_ZVAL(retval); + MAKE_STD_ZVAL(zfuncname); + ZVAL_STRING(zfuncname, "getTimestamp", 1); + if (call_user_function(NULL, &(z), zfuncname, &retval, 0, NULL TSRMLS_CC) + != SUCCESS || Z_TYPE(retval) != IS_LONG) { + spprintf(&message, 0, "%s: error calling ::getTimeStamp() on the " + "object", func); + intl_errors_set(err, U_INTERNAL_PROGRAM_ERROR, + message, 1 TSRMLS_CC); + efree(message); + zval_ptr_dtor(&zfuncname); + return FAILURE; + } + + *millis = U_MILLIS_PER_SECOND * (double)Z_LVAL(retval); + zval_ptr_dtor(&zfuncname); + } + + if (tz) { + php_date_obj *datetime; + datetime = (php_date_obj*)zend_object_store_get_object(z TSRMLS_CC); + if (!datetime->time) { + spprintf(&message, 0, "%s: the DateTime object is not properly " + "initialized", func); + intl_errors_set(err, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); + return FAILURE; + } + if (!datetime->time->is_localtime) { + *tz = TimeZone::getGMT()->clone(); + } else { + *tz = timezone_convert_datetimezone(datetime->time->zone_type, + datetime, 1, NULL, func TSRMLS_CC); + if (*tz == NULL) { + spprintf(&message, 0, "%s: could not convert DateTime's " + "time zone", func); + intl_errors_set(err, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); + return FAILURE; + } + } + } + + return SUCCESS; +} + +U_CFUNC double intl_zval_to_millis(zval *z, intl_error *err, const char *func TSRMLS_DC) +{ + double rv = NAN; + long lv; + int type; + char *message; + + if (err && U_FAILURE(err->code)) { return NAN; } @@ -43,7 +192,12 @@ U_CFUNC double intl_zval_to_millis(zval *z, UErrorCode *status TSRMLS_DC) } else if (type == IS_LONG) { rv = U_MILLIS_PER_SECOND * (double)lv; } else { - *status = U_ILLEGAL_ARGUMENT_ERROR; + spprintf(&message, 0, "%s: string '%s' is not numeric, " + "which would be required for it to be a valid date", func, + Z_STRVAL_P(z)); + intl_errors_set(err, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); } break; case IS_LONG: @@ -54,33 +208,41 @@ U_CFUNC double intl_zval_to_millis(zval *z, UErrorCode *status TSRMLS_DC) break; case IS_OBJECT: if (instanceof_function(Z_OBJCE_P(z), php_date_get_date_ce() TSRMLS_CC)) { - zval retval; - zval *zfuncname; - INIT_ZVAL(retval); - MAKE_STD_ZVAL(zfuncname); - ZVAL_STRING(zfuncname, "getTimestamp", 1); - if (call_user_function(NULL, &(z), zfuncname, &retval, 0, NULL TSRMLS_CC) - != SUCCESS || Z_TYPE(retval) != IS_LONG) { - *status = U_INTERNAL_PROGRAM_ERROR; - } else { - rv = U_MILLIS_PER_SECOND * (double)Z_LVAL(retval); - } - zval_ptr_dtor(&zfuncname); + intl_datetime_decompose(z, &rv, NULL, err, func TSRMLS_CC); } else if (instanceof_function(Z_OBJCE_P(z), Calendar_ce_ptr TSRMLS_CC)) { Calendar_object *co = (Calendar_object *) zend_object_store_get_object(z TSRMLS_CC ); if (co->ucal == NULL) { - *status = U_ILLEGAL_ARGUMENT_ERROR; + spprintf(&message, 0, "%s: IntlCalendar object is not properly " + "constructed", func); + intl_errors_set(err, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); } else { - rv = (double)co->ucal->getTime(*status); + UErrorCode status = UErrorCode(); + rv = (double)co->ucal->getTime(status); + if (U_FAILURE(status)) { + spprintf(&message, 0, "%s: call to internal " + "Calendar::getTime() has failed", func); + intl_errors_set(err, status, message, 1 TSRMLS_CC); + efree(message); + } } } else { /* TODO: try with cast(), get() to obtain a number */ - *status = U_ILLEGAL_ARGUMENT_ERROR; + spprintf(&message, 0, "%s: invalid object type for date/time " + "(only IntlCalendar and DateTime permitted)", func); + intl_errors_set(err, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); } break; default: - *status = U_ILLEGAL_ARGUMENT_ERROR; + spprintf(&message, 0, "%s: invalid PHP type for date", func); + intl_errors_set(err, U_ILLEGAL_ARGUMENT_ERROR, + message, 1 TSRMLS_CC); + efree(message); + break; } return rv; diff --git a/ext/intl/common/common_date.h b/ext/intl/common/common_date.h index cfa14d1a58384..d2396cbf5afa6 100644 --- a/ext/intl/common/common_date.h +++ b/ext/intl/common/common_date.h @@ -21,9 +21,20 @@ U_CDECL_BEGIN #include +#include "../intl_error.h" U_CDECL_END -U_CFUNC double intl_zval_to_millis(zval *z, UErrorCode *status TSRMLS_DC); +#ifdef __cplusplus + +#include + +U_CFUNC TimeZone *timezone_convert_datetimezone(int type, void *object, int is_datetime, intl_error *outside_error, const char *func TSRMLS_DC); +U_CFUNC int intl_datetime_decompose(zval *z, double *millis, TimeZone **tz, + intl_error *err, const char *func TSRMLS_DC); + +#endif + +U_CFUNC double intl_zval_to_millis(zval *z, intl_error *err, const char *func TSRMLS_DC); #endif /* COMMON_DATE_H */ diff --git a/ext/intl/config.m4 b/ext/intl/config.m4 index 8598161e2b887..c33f47fbdc0a3 100755 --- a/ext/intl/config.m4 +++ b/ext/intl/config.m4 @@ -52,6 +52,7 @@ if test "$PHP_INTL" != "no"; then dateformat/dateformat_attr.c \ dateformat/dateformat_data.c \ dateformat/dateformat_format.c \ + dateformat/dateformat_format_object.cpp \ dateformat/dateformat_parse.c \ dateformat/dateformat_create.cpp \ dateformat/dateformat_attrcpp.cpp \ diff --git a/ext/intl/config.w32 b/ext/intl/config.w32 index d57c7f3a334e9..851436480d935 100755 --- a/ext/intl/config.w32 +++ b/ext/intl/config.w32 @@ -62,6 +62,7 @@ if (PHP_INTL != "no") { dateformat_class.c \ dateformat_attr.c \ dateformat_format.c \ + dateformat_format_object.cpp \ dateformat_parse.c \ dateformat_data.c \ dateformat_attrcpp.cpp \ diff --git a/ext/intl/dateformat/dateformat_class.c b/ext/intl/dateformat/dateformat_class.c index fda67f1b70003..809a1c60c9b3e 100755 --- a/ext/intl/dateformat/dateformat_class.c +++ b/ext/intl/dateformat/dateformat_class.c @@ -19,6 +19,7 @@ #include "php_intl.h" #include "dateformat_data.h" #include "dateformat_format.h" +#include "dateformat_format_object.h" #include "dateformat_parse.h" #include "dateformat.h" #include "dateformat_attr.h" @@ -120,6 +121,12 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_intldateformatter_format, 0, 0, 0) ZEND_ARG_INFO(0, array) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_intldateformatter_format_object, 0, 0, 1) + ZEND_ARG_INFO(0, object) + ZEND_ARG_INFO(0, format) + ZEND_ARG_INFO(0, locale) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO(arginfo_intldateformatter_getdatetype, 0) ZEND_END_ARG_INFO() @@ -170,6 +177,7 @@ static zend_function_entry IntlDateFormatter_class_functions[] = { PHP_NAMED_FE( setLenient, ZEND_FN( datefmt_set_lenient ), arginfo_intldateformatter_setlenient ) PHP_NAMED_FE( isLenient, ZEND_FN( datefmt_is_lenient ), arginfo_intldateformatter_getdatetype ) PHP_NAMED_FE( format, ZEND_FN( datefmt_format ), arginfo_intldateformatter_format ) + PHP_ME_MAPPING( formatObject, datefmt_format_object, arginfo_intldateformatter_format_object, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) PHP_NAMED_FE( parse, ZEND_FN( datefmt_parse), datefmt_parse_args ) PHP_NAMED_FE( localtime, ZEND_FN( datefmt_localtime ), datefmt_parse_args ) PHP_NAMED_FE( getErrorCode, ZEND_FN( datefmt_get_error_code ), arginfo_intldateformatter_getdatetype ) diff --git a/ext/intl/dateformat/dateformat_format.c b/ext/intl/dateformat/dateformat_format.c index 468a3d7748d3b..d5a17f91cd399 100755 --- a/ext/intl/dateformat/dateformat_format.c +++ b/ext/intl/dateformat/dateformat_format.c @@ -175,10 +175,11 @@ PHP_FUNCTION(datefmt_format) timestamp = internal_get_timestamp(dfo, hash_arr TSRMLS_CC); INTL_METHOD_CHECK_STATUS(dfo, "datefmt_format: date formatting failed") } else { - timestamp = intl_zval_to_millis(zarg, - &INTL_DATA_ERROR_CODE(dfo) TSRMLS_CC); - INTL_METHOD_CHECK_STATUS(dfo, "datefmt_format: could not convert input " - "into a date") + timestamp = intl_zval_to_millis(zarg, INTL_DATA_ERROR_P(dfo), + "datefmt_format" TSRMLS_CC); + if (U_FAILURE(INTL_DATA_ERROR_CODE(dfo))) { + RETURN_FALSE; + } } internal_format( dfo, timestamp, return_value TSRMLS_CC); diff --git a/ext/intl/dateformat/dateformat_format_object.cpp b/ext/intl/dateformat/dateformat_format_object.cpp new file mode 100644 index 0000000000000..e8981faa2676f --- /dev/null +++ b/ext/intl/dateformat/dateformat_format_object.cpp @@ -0,0 +1,230 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Gustavo Lopes | + +----------------------------------------------------------------------+ +*/ + +#include "../intl_cppshims.h" + +#include +#include +#include +#include +#include + +#include "../intl_convertcpp.h" + +extern "C" { +#include "../php_intl.h" +#include "../locale/locale.h" +#define USE_CALENDAR_POINTER 1 +#include "../calendar/calendar_class.h" +#include +#include "../common/common_date.h" +} + +static const DateFormat::EStyle valid_styles[] = { + DateFormat::kNone, + DateFormat::kFull, + DateFormat::kLong, + DateFormat::kMedium, + DateFormat::kShort, + DateFormat::kFullRelative, + DateFormat::kLongRelative, + DateFormat::kMediumRelative, + DateFormat::kShortRelative, +}; + +static bool valid_format(zval **z) { + if (Z_TYPE_PP(z) == IS_LONG) { + long lval = Z_LVAL_PP(z); + for (int i = 0; i < sizeof(valid_styles) / sizeof(*valid_styles); i++) { + if ((long)valid_styles[i] == lval) { + return true; + } + } + } + + return false; +} + +U_CFUNC PHP_FUNCTION(datefmt_format_object) +{ + zval *object, + **format = NULL; + const char *locale_str = NULL; + int locale_len; + bool pattern = false; + UDate date; + TimeZone *timeZone = NULL; + UErrorCode status = U_ZERO_ERROR; + DateFormat *df = NULL; + Calendar *cal = NULL; + DateFormat::EStyle dateStyle = DateFormat::kDefault, + timeStyle = DateFormat::kDefault; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o|Zs!", + &object, &format, &locale_str, &locale_len) == FAILURE) { + RETURN_FALSE; + } + + if (!locale_str) { + locale_str = intl_locale_get_default(TSRMLS_C); + } + + if (format == NULL || Z_TYPE_PP(format) == IS_NULL) { + //nothing + } else if (Z_TYPE_PP(format) == IS_ARRAY) { + HashTable *ht = Z_ARRVAL_PP(format); + HashPosition pos = {0}; + zval **z; + if (zend_hash_num_elements(ht) != 2) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "datefmt_format_object: bad format; if array, it must have " + "two elements", 0 TSRMLS_CC); + RETURN_FALSE; + } + + zend_hash_internal_pointer_reset_ex(ht, &pos); + zend_hash_get_current_data_ex(ht, (void**)&z, &pos); + if (!valid_format(z)) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "datefmt_format_object: bad format; the date format (first " + "element of the array) is not valid", 0 TSRMLS_CC); + RETURN_FALSE; + } + dateStyle = (DateFormat::EStyle)Z_LVAL_PP(z); + + zend_hash_move_forward_ex(ht, &pos); + zend_hash_get_current_data_ex(ht, (void**)&z, &pos); + if (!valid_format(z)) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "datefmt_format_object: bad format; the time format (" + "second element of the array) is not valid", 0 TSRMLS_CC); + RETURN_FALSE; + } + timeStyle = (DateFormat::EStyle)Z_LVAL_PP(z); + } else if (Z_TYPE_PP(format) == IS_LONG) { + if (!valid_format(format)) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "datefmt_format_object: the date/time format type is invalid", + 0 TSRMLS_CC); + RETURN_FALSE; + } + dateStyle = timeStyle = (DateFormat::EStyle)Z_LVAL_PP(format); + } else { + convert_to_string_ex(format); + if (Z_STRLEN_PP(format) == 0) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "datefmt_format_object: the format is empty", 0 TSRMLS_CC); + RETURN_FALSE; + } + pattern = true; + } + + //there's no support for relative time in ICU yet + timeStyle = (DateFormat::EStyle)(timeStyle & ~DateFormat::kRelative); + + zend_class_entry *instance_ce = Z_OBJCE_P(object); + if (instanceof_function(instance_ce, Calendar_ce_ptr TSRMLS_CC)) { + Calendar *obj_cal = calendar_fetch_native_calendar(object TSRMLS_CC); + if (obj_cal == NULL) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "datefmt_format_object: bad IntlCalendar instance: " + "not initialized properly", 0 TSRMLS_CC); + RETURN_FALSE; + } + timeZone = obj_cal->getTimeZone().clone(); + date = obj_cal->getTime(status); + if (U_FAILURE(status)) { + intl_error_set(NULL, status, + "datefmt_format_object: error obtaining instant from " + "IntlCalendar", 0 TSRMLS_CC); + RETVAL_FALSE; + goto cleanup; + } + cal = obj_cal->clone(); + } else if (instanceof_function(instance_ce, php_date_get_date_ce() TSRMLS_CC)) { + if (intl_datetime_decompose(object, &date, &timeZone, NULL, + "datefmt_format_object" TSRMLS_CC) == FAILURE) { + RETURN_FALSE; + } + cal = new GregorianCalendar(Locale::createFromName(locale_str), status); + if (U_FAILURE(status)) { + intl_error_set(NULL, status, + "datefmt_format_object: could not create GregorianCalendar", + 0 TSRMLS_CC); + RETVAL_FALSE; + goto cleanup; + } + } else { + intl_error_set(NULL, status, "datefmt_format_object: the passed object " + "must be an instance of either IntlCalendar or DateTime", + 0 TSRMLS_CC); + RETURN_FALSE; + } + + if (pattern) { + df = new SimpleDateFormat( + UnicodeString(Z_STRVAL_PP(format), Z_STRLEN_PP(format), + UnicodeString::kInvariant), + Locale::createFromName(locale_str), + status); + + if (U_FAILURE(status)) { + intl_error_set(NULL, status, + "datefmt_format_object: could not create SimpleDateFormat", + 0 TSRMLS_CC); + RETVAL_FALSE; + goto cleanup; + } + } else { + df = DateFormat::createDateTimeInstance(dateStyle, timeStyle, + Locale::createFromName(locale_str)); + + if (df == NULL) { /* according to ICU sources, this should never happen */ + intl_error_set(NULL, status, + "datefmt_format_object: could not create DateFormat", + 0 TSRMLS_CC); + RETVAL_FALSE; + goto cleanup; + } + } + + //must be in this order (or have the cal adopt the tz) + df->adoptCalendar(cal); + cal = NULL; + df->adoptTimeZone(timeZone); + timeZone = NULL; + + { + UnicodeString result = UnicodeString(); + df->format(date, result); + + Z_TYPE_P(return_value) = IS_STRING; + if (intl_charFromString(result, &Z_STRVAL_P(return_value), + &Z_STRLEN_P(return_value), &status) == FAILURE) { + intl_error_set(NULL, status, + "datefmt_format_object: error converting result to UTF-8", + 0 TSRMLS_CC); + RETVAL_FALSE; + goto cleanup; + } + } + + +cleanup: + delete df; + delete timeZone; + delete cal; +} diff --git a/ext/intl/dateformat/dateformat_format_object.h b/ext/intl/dateformat/dateformat_format_object.h new file mode 100644 index 0000000000000..d80ea87e0f813 --- /dev/null +++ b/ext/intl/dateformat/dateformat_format_object.h @@ -0,0 +1,19 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Gustavo Lopes | + +----------------------------------------------------------------------+ + */ + +#include + +PHP_FUNCTION(datefmt_format_object); diff --git a/ext/intl/msgformat/msgformat_helpers.cpp b/ext/intl/msgformat/msgformat_helpers.cpp index c8223190784a0..9ee1cdcfb0d17 100755 --- a/ext/intl/msgformat/msgformat_helpers.cpp +++ b/ext/intl/msgformat/msgformat_helpers.cpp @@ -43,14 +43,6 @@ extern "C" { #include "../timezone/timezone_class.h" } -#ifndef INFINITY -#define INFINITY (DBL_MAX+DBL_MAX) -#endif - -#ifndef NAN -#define NAN (INFINITY-INFINITY) -#endif - #if U_ICU_VERSION_MAJOR_NUM * 10 + U_ICU_VERSION_MINOR_NUM >= 48 #define HAS_MESSAGE_PATTERN 1 #endif @@ -549,7 +541,7 @@ U_CFUNC void umsg_format_helper(MessageFormatter_object *mfo, } case Formattable::kDate: { - double dd = intl_zval_to_millis(*elem, &err.code TSRMLS_CC); + double dd = intl_zval_to_millis(*elem, &err, "msgfmt_format" TSRMLS_CC); if (U_FAILURE(err.code)) { char *message, *key_char; int key_len; diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index 59272db71271d..f314870ac6f56 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -62,6 +62,7 @@ #include "dateformat/dateformat_attr.h" #include "dateformat/dateformat_attrcpp.h" #include "dateformat/dateformat_format.h" +#include "dateformat/dateformat_format_object.h" #include "dateformat/dateformat_parse.h" #include "dateformat/dateformat_data.h" @@ -339,6 +340,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_format, 0, 0, 0) ZEND_ARG_INFO(0, array) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_format_object, 0, 0, 1) + ZEND_ARG_INFO(0, object) + ZEND_ARG_INFO(0, format) + ZEND_ARG_INFO(0, locale) +ZEND_END_ARG_INFO() + + ZEND_BEGIN_ARG_INFO_EX(arginfo_datefmt_create, 0, 0, 3) ZEND_ARG_INFO(0, locale) ZEND_ARG_INFO(0, date_type) @@ -695,6 +703,7 @@ zend_function_entry intl_functions[] = { PHP_FE( datefmt_is_lenient, arginfo_msgfmt_get_locale ) PHP_FE( datefmt_set_lenient, arginfo_msgfmt_get_locale ) PHP_FE( datefmt_format, arginfo_datefmt_format ) + PHP_FE( datefmt_format_object, arginfo_datefmt_format_object ) PHP_FE( datefmt_parse, datefmt_parse_args ) PHP_FE( datefmt_localtime , datefmt_parse_args ) PHP_FE( datefmt_get_error_code, arginfo_msgfmt_get_error_code ) diff --git a/ext/intl/tests/dateformat_format.phpt b/ext/intl/tests/dateformat_format.phpt index d09de0e439614..8664eea319888 100755 --- a/ext/intl/tests/dateformat_format.phpt +++ b/ext/intl/tests/dateformat_format.phpt @@ -399,24 +399,24 @@ Formatted DateTime is : 20001230 05:04 PM Date is: stdClass::__set_state(array( )) ------------ -Error while formatting as: 'datefmt_format: could not convert input into a date: U_ILLEGAL_ARGUMENT_ERROR' +Error while formatting as: 'datefmt_format: invalid object type for date/time (only IntlCalendar and DateTime permitted): U_ILLEGAL_ARGUMENT_ERROR' ------------ Date is: stdClass::__set_state(array( )) ------------ -Error while formatting as: 'datefmt_format: could not convert input into a date: U_ILLEGAL_ARGUMENT_ERROR' +Error while formatting as: 'datefmt_format: invalid object type for date/time (only IntlCalendar and DateTime permitted): U_ILLEGAL_ARGUMENT_ERROR' ------------ Date is: stdClass::__set_state(array( )) ------------ -Error while formatting as: 'datefmt_format: could not convert input into a date: U_ILLEGAL_ARGUMENT_ERROR' +Error while formatting as: 'datefmt_format: invalid object type for date/time (only IntlCalendar and DateTime permitted): U_ILLEGAL_ARGUMENT_ERROR' ------------ Date is: stdClass::__set_state(array( )) ------------ -Error while formatting as: 'datefmt_format: could not convert input into a date: U_ILLEGAL_ARGUMENT_ERROR' +Error while formatting as: 'datefmt_format: invalid object type for date/time (only IntlCalendar and DateTime permitted): U_ILLEGAL_ARGUMENT_ERROR' ------------ Date is: stdClass::__set_state(array( )) ------------ -Error while formatting as: 'datefmt_format: could not convert input into a date: U_ILLEGAL_ARGUMENT_ERROR' +Error while formatting as: 'datefmt_format: invalid object type for date/time (only IntlCalendar and DateTime permitted): U_ILLEGAL_ARGUMENT_ERROR' diff --git a/ext/intl/tests/dateformat_formatObject_calendar.phpt b/ext/intl/tests/dateformat_formatObject_calendar.phpt new file mode 100644 index 0000000000000..03371a91ab68f --- /dev/null +++ b/ext/intl/tests/dateformat_formatObject_calendar.phpt @@ -0,0 +1,41 @@ +--TEST-- +IntlDateFormatter::formatObject(): IntlCalendar tests +--SKIPIF-- +setTime(strtotime('2012-01-01 00:00:00')*1000.); +echo IntlDateFormatter::formatObject($cal), "\n"; +echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\n"; + +?> +==DONE== + +--EXPECT-- +01/01/2012 00:00:00 +Domingo, 1 de Janeiro de 2012 0:00:00 Hora Padrão da Europa Ocidental +Jan 1, 2012 12:00:00 AM +1/1/12 12:00:00 AM Western European Standard Time +Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon) +Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00 +06/02/1433 00:00:00 +Sunday, Safar 6, 1433 12:00:00 AM Western European Standard Time +==DONE== + diff --git a/ext/intl/tests/dateformat_formatObject_datetime.phpt b/ext/intl/tests/dateformat_formatObject_datetime.phpt new file mode 100644 index 0000000000000..bfc26cb80c9ab --- /dev/null +++ b/ext/intl/tests/dateformat_formatObject_datetime.phpt @@ -0,0 +1,34 @@ +--TEST-- +IntlDateFormatter::formatObject(): DateTime tests +--SKIPIF-- + +==DONE== + +--EXPECT-- +01/01/2012 00:00:00 +Domingo, 1 de Janeiro de 2012 0:00:00 Hora Padrão da Europa Ocidental +Jan 1, 2012 12:00:00 AM +1/1/12 12:00:00 AM Western European Standard Time +Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon) +Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00 +==DONE== + diff --git a/ext/intl/tests/dateformat_formatObject_error.phpt b/ext/intl/tests/dateformat_formatObject_error.phpt new file mode 100644 index 0000000000000..7aaf69e54e644 --- /dev/null +++ b/ext/intl/tests/dateformat_formatObject_error.phpt @@ -0,0 +1,74 @@ +--TEST-- +IntlDateFormatter::formatObject(): error conditions +--SKIPIF-- + +==DONE== + +--EXPECTF-- + +Warning: IntlDateFormatter::formatObject() expects at least 1 parameter, 0 given in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject() expects parameter 1 to be object, integer given in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: the passed object must be an instance of either IntlCalendar or DateTime in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: bad IntlCalendar instance: not initialized properly in %s on line %d +bool(false) + +Warning: DateTime::getTimestamp(): The DateTime object has not been correctly initialized by its constructor in %s on line %d + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: error calling ::getTimeStamp() on the object in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: the date/time format type is invalid in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: bad format; if array, it must have two elements in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: bad format; if array, it must have two elements in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: bad format; the date format (first element of the array) is not valid in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: bad format; the time format (second element of the array) is not valid in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject(): datefmt_format_object: the format is empty in %s on line %d +bool(false) + +Warning: IntlDateFormatter::formatObject() expects parameter 3 to be string, array given in %s on line %d +bool(false) +==DONE== + diff --git a/ext/intl/tests/msgfmt_format_error5.phpt b/ext/intl/tests/msgfmt_format_error5.phpt index 052d0efd116ff..ebbd4550e8f46 100644 --- a/ext/intl/tests/msgfmt_format_error5.phpt +++ b/ext/intl/tests/msgfmt_format_error5.phpt @@ -20,6 +20,7 @@ $mf = new MessageFormatter('en_US', $fmt); var_dump($mf->format(array("foo" => new stdclass()))); --EXPECTF-- +Warning: MessageFormatter::format(): msgfmt_format: invalid object type for date/time (only IntlCalendar and DateTime permitted) in %s on line %d Warning: MessageFormatter::format(): The argument for key 'foo' cannot be used as a date or time in %s on line %d bool(false) diff --git a/ext/intl/timezone/timezone_class.cpp b/ext/intl/timezone/timezone_class.cpp index 6e62c34f6d3d7..27cf41a4cf4e9 100644 --- a/ext/intl/timezone/timezone_class.cpp +++ b/ext/intl/timezone/timezone_class.cpp @@ -25,6 +25,8 @@ #include #include "../intl_convertcpp.h" +#include "../common/common_date.h" + extern "C" { #include "../intl_convert.h" #define USE_TIMEZONE_POINTER 1 @@ -54,79 +56,6 @@ U_CFUNC void timezone_object_construct(const TimeZone *zone, zval *object, int o } /* }}} */ -/* {{{ timezone_convert_datetimezone - * The timezone in DateTime and DateTimeZone is not unified. */ -U_CFUNC TimeZone *timezone_convert_datetimezone(int type, - void *object, - int is_datetime, - intl_error *outside_error, - const char *func TSRMLS_DC) -{ - char *id = NULL, - offset_id[] = "GMT+00:00"; - int id_len = 0; - char *message; - TimeZone *timeZone; - - switch (type) { - case TIMELIB_ZONETYPE_ID: - id = is_datetime - ? ((php_date_obj*)object)->time->tz_info->name - : ((php_timezone_obj*)object)->tzi.tz->name; - id_len = strlen(id); - break; - case TIMELIB_ZONETYPE_OFFSET: { - int offset_mins = is_datetime - ? -((php_date_obj*)object)->time->z - : -(int)((php_timezone_obj*)object)->tzi.utc_offset, - hours = offset_mins / 60, - minutes = offset_mins - hours * 60; - minutes *= minutes > 0 ? 1 : -1; - - if (offset_mins <= -24 * 60 || offset_mins >= 24 * 60) { - spprintf(&message, 0, "%s: object has an time zone offset " - "that's too large", func); - intl_errors_set(outside_error, U_ILLEGAL_ARGUMENT_ERROR, - message, 1 TSRMLS_CC); - efree(message); - return NULL; - } - - id = offset_id; - id_len = slprintf(id, sizeof(offset_id), "GMT%+03d:%02d", - hours, minutes); - break; - } - case TIMELIB_ZONETYPE_ABBR: - id = is_datetime - ? ((php_date_obj*)object)->time->tz_abbr - : ((php_timezone_obj*)object)->tzi.z.abbr; - id_len = strlen(id); - break; - } - - UnicodeString s = UnicodeString(id, id_len, US_INV); - timeZone = TimeZone::createTimeZone(s); -#if U_ICU_VERSION_MAJOR_NUM >= 49 - if (*timeZone == TimeZone::getUnknown()) { -#else - UnicodeString resultingId; - timeZone->getID(resultingId); - if (resultingId == UnicodeString("Etc/Unknown", -1, US_INV) - || resultingId == UnicodeString("GMT", -1, US_INV)) { -#endif - spprintf(&message, 0, "%s: time zone id '%s' " - "extracted from ext/date DateTimeZone not recognized", func, id); - intl_errors_set(outside_error, U_ILLEGAL_ARGUMENT_ERROR, - message, 1 TSRMLS_CC); - efree(message); - delete timeZone; - return NULL; - } - return timeZone; -} -/* }}} */ - /* {{{ timezone_convert_to_datetimezone * Convert from TimeZone to DateTimeZone object */ U_CFUNC zval *timezone_convert_to_datetimezone(const TimeZone *timeZone, diff --git a/ext/intl/timezone/timezone_class.h b/ext/intl/timezone/timezone_class.h index 0d3c0edde4721..a638f6dbf49ef 100644 --- a/ext/intl/timezone/timezone_class.h +++ b/ext/intl/timezone/timezone_class.h @@ -59,7 +59,6 @@ typedef struct { RETURN_FALSE; \ } -TimeZone *timezone_convert_datetimezone(int type, void *object, int is_datetime, intl_error *outside_error, const char *func TSRMLS_DC); zval *timezone_convert_to_datetimezone(const TimeZone *timeZone, intl_error *outside_error, const char *func TSRMLS_DC); TimeZone *timezone_process_timezone_argument(zval **zv_timezone, intl_error *error, const char *func TSRMLS_DC); diff --git a/ext/intl/timezone/timezone_methods.cpp b/ext/intl/timezone/timezone_methods.cpp index 1435679fe743c..c35f0b87217fa 100644 --- a/ext/intl/timezone/timezone_methods.cpp +++ b/ext/intl/timezone/timezone_methods.cpp @@ -24,6 +24,9 @@ #include #include #include "intl_convertcpp.h" + +#include "../common/common_date.h" + extern "C" { #define USE_TIMEZONE_POINTER 1 #include "timezone_class.h" From 2498c90c71980168b5b9ac2fa006340b9460b1f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sun, 22 Jul 2012 04:13:17 +0200 Subject: [PATCH 1953/2394] Readded accidentally removed line --- ext/intl/dateformat/dateformat.h | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/intl/dateformat/dateformat.h b/ext/intl/dateformat/dateformat.h index a5a747328f7b7..f11918b79f142 100755 --- a/ext/intl/dateformat/dateformat.h +++ b/ext/intl/dateformat/dateformat.h @@ -40,5 +40,6 @@ These are not necessary at this point of time #define CALENDAR_YEAR "tm_year" #define CALENDAR_WDAY "tm_wday" #define CALENDAR_YDAY "tm_yday" +#define CALENDAR_ISDST "tm_isdst" #endif // DATE_FORMATTER_H From 4203e0a5dfe83631b75c40c469224e7c94ec8c68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Sun, 22 Jul 2012 04:26:49 +0200 Subject: [PATCH 1954/2394] Reflect changes made in merge 99e48d3 --- UPGRADING | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/UPGRADING b/UPGRADING index 6cfd47bfaf753..7d37f760002da 100755 --- a/UPGRADING +++ b/UPGRADING @@ -91,6 +91,8 @@ PHP X.Y UPGRADE NOTES - IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone() instead. +- IntlDateFormatter::format() and datefmt_format() now also accept an + IntlCalendar object for formatting. ======================================== 5. New Functions @@ -103,6 +105,7 @@ PHP X.Y UPGRADE NOTES - hash_pbkdf2() - Intl: + - datefmt_format_object() - datefmt_get_calendar_object() - datefmt_get_timezone() - datefmt_set_timezone() @@ -178,6 +181,7 @@ PHP X.Y UPGRADE NOTES - intltz_get_error_code() - intltz_get_error_message() + - IntlDateFormatter::formatObject() - IntlDateFormatter::getCalendarObject() - IntlDateFormatter::getTimeZone() - IntlDateFormatter::setTimeZone() From de80e3ce4b5b7a9ec0cfdd0778e77027a7ebfcc2 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 22 Jul 2012 14:33:25 +0200 Subject: [PATCH 1955/2394] Remove reference restrictions from foreach foreach only allowed variables to be traversed by reference. This never really made sense because a) Expressions like array(&$a, &$b) can be meaningfully iterated by-ref b) Function calls can return by-ref (so they can also be meaningfully iterated) c) Iterators could at least in theory also be iterated by-ref (not sure if any iterator makes use of this) With by-ref generators the restriction makes even less sense, so I removed it altogether. --- Zend/tests/errmsg_043.phpt | 12 ---------- .../foreach_temp_array_expr_with_refs.phpt | 18 ++++++++++++++ Zend/tests/generators/yield_by_reference.phpt | 24 +++++++++++++------ Zend/zend_compile.c | 4 +--- Zend/zend_language_parser.y | 2 +- tests/lang/foreachLoop.008.phpt | 10 -------- 6 files changed, 37 insertions(+), 33 deletions(-) delete mode 100644 Zend/tests/errmsg_043.phpt create mode 100644 Zend/tests/foreach_temp_array_expr_with_refs.phpt delete mode 100644 tests/lang/foreachLoop.008.phpt diff --git a/Zend/tests/errmsg_043.phpt b/Zend/tests/errmsg_043.phpt deleted file mode 100644 index 3de8bc2062e9c..0000000000000 --- a/Zend/tests/errmsg_043.phpt +++ /dev/null @@ -1,12 +0,0 @@ ---TEST-- -errmsg: cannot create references to temp array ---FILE-- -&$v) { -} - -echo "Done\n"; -?> ---EXPECTF-- -Fatal error: Cannot create references to elements of a temporary array expression in %s on line %d diff --git a/Zend/tests/foreach_temp_array_expr_with_refs.phpt b/Zend/tests/foreach_temp_array_expr_with_refs.phpt new file mode 100644 index 0000000000000..8978b7b011419 --- /dev/null +++ b/Zend/tests/foreach_temp_array_expr_with_refs.phpt @@ -0,0 +1,18 @@ +--TEST-- +Temporary array expressions can be iterated by reference +--FILE-- + +--EXPECT-- +string(5) "a-foo" +string(5) "b-foo" diff --git a/Zend/tests/generators/yield_by_reference.phpt b/Zend/tests/generators/yield_by_reference.phpt index 5a6c169b3e239..dba0791c0d495 100644 --- a/Zend/tests/generators/yield_by_reference.phpt +++ b/Zend/tests/generators/yield_by_reference.phpt @@ -9,24 +9,34 @@ function &iter(array &$array) { } } -$array = [1, 2, 3, 4, 5]; +$array = [1, 2, 3]; $iter = iter($array); foreach ($iter as &$value) { $value *= -1; } var_dump($array); +$array = [1, 2, 3]; +foreach (iter($array) as &$value) { + $value *= -1; +} +var_dump($array); + ?> --EXPECT-- -array(5) { +array(3) { + [0]=> + int(-1) + [1]=> + int(-2) + [2]=> + &int(-3) +} +array(3) { [0]=> int(-1) [1]=> int(-2) [2]=> - int(-3) - [3]=> - int(-4) - [4]=> - &int(-5) + &int(-3) } diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 51fc8c3e5be3b..f0648a2d977fa 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6317,9 +6317,7 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token if (value->EA & ZEND_PARSED_REFERENCE_VARIABLE) { assign_by_ref = 1; - if (!(opline-1)->extended_value) { - zend_error(E_COMPILE_ERROR, "Cannot create references to elements of a temporary array expression"); - } + /* Mark extended_value for assign-by-reference */ opline->extended_value |= ZEND_FE_FETCH_BYREF; CG(active_op_array)->opcodes[foreach_token->u.op.opline_num].extended_value |= ZEND_FE_RESET_REFERENCE; diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index e5f31b5d149a8..4221752dbab06 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -312,7 +312,7 @@ unticked_statement: foreach_statement { zend_do_foreach_end(&$1, &$4 TSRMLS_CC); } | T_FOREACH '(' expr_without_variable T_AS { zend_do_foreach_begin(&$1, &$2, &$3, &$4, 0 TSRMLS_CC); } - variable foreach_optional_arg ')' { zend_check_writable_variable(&$6); zend_do_foreach_cont(&$1, &$2, &$4, &$6, &$7 TSRMLS_CC); } + foreach_variable foreach_optional_arg ')' { zend_do_foreach_cont(&$1, &$2, &$4, &$6, &$7 TSRMLS_CC); } foreach_statement { zend_do_foreach_end(&$1, &$4 TSRMLS_CC); } | T_DECLARE { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); zend_do_declare_begin(TSRMLS_C); } '(' declare_list ')' declare_statement { zend_do_declare_end(&$1 TSRMLS_CC); } | ';' /* empty statement */ diff --git a/tests/lang/foreachLoop.008.phpt b/tests/lang/foreachLoop.008.phpt deleted file mode 100644 index 787f43b88375b..0000000000000 --- a/tests/lang/foreachLoop.008.phpt +++ /dev/null @@ -1,10 +0,0 @@ ---TEST-- -Foreach loop tests - error case: reference to constant array, with key. ---FILE-- -&$v) { - var_dump($v); -} -?> ---EXPECTF-- -Fatal error: Cannot create references to elements of a temporary array expression in %s on line 2 From 94b2ccae9ce95c4c71bb8db8ce75dcdf26df7d7a Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 22 Jul 2012 17:46:46 +0200 Subject: [PATCH 1956/2394] Fix throwing of exceptions within a generator If a generator threw an exception and was iterated using foreach (i.e. not manually) an infinite loop was triggered. The reason was that the exception was not properly rethrown using zend_throw_exception_internal. --- Zend/tests/generators/backtrace.phpt | 2 +- .../generator_throwing_in_foreach.phpt | 20 +++++++++++++++++++ Zend/zend_generators.c | 12 ++++++++--- Zend/zend_vm_def.h | 2 +- Zend/zend_vm_execute.h | 2 +- 5 files changed, 32 insertions(+), 6 deletions(-) create mode 100644 Zend/tests/generators/generator_throwing_in_foreach.phpt diff --git a/Zend/tests/generators/backtrace.phpt b/Zend/tests/generators/backtrace.phpt index 5f665b7e4ac17..5fed1d467e676 100644 --- a/Zend/tests/generators/backtrace.phpt +++ b/Zend/tests/generators/backtrace.phpt @@ -22,6 +22,6 @@ f3($gen); ?> --EXPECTF-- #0 f1() called at [%s:%d] -#1 f2(foo, bar) called at [%s:%d] +#1 f2(foo, bar) #2 Generator->rewind() called at [%s:%d] #3 f3(Generator Object ()) called at [%s:%d] diff --git a/Zend/tests/generators/generator_throwing_in_foreach.phpt b/Zend/tests/generators/generator_throwing_in_foreach.phpt new file mode 100644 index 0000000000000..dbf20c2ca1c65 --- /dev/null +++ b/Zend/tests/generators/generator_throwing_in_foreach.phpt @@ -0,0 +1,20 @@ +--TEST-- +Exceptions throwing by generators during foreach iteration are properly handled +--FILE-- + +--EXPECTF-- +Fatal error: Uncaught exception 'Exception' with message 'foo' in %s:%d +Stack trace: +#0 %s(%d): gen() +#1 {main} + thrown in %s on line %d + diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index b164fb835e53b..d7ffb3055a6a5 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -21,6 +21,7 @@ #include "zend.h" #include "zend_API.h" #include "zend_interfaces.h" +#include "zend_exceptions.h" #include "zend_generators.h" ZEND_API zend_class_entry *zend_ce_generator; @@ -352,12 +353,11 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ * up in backtraces and func_get_all() can access the function * arguments. */ execute_data->prev_execute_data = emalloc(sizeof(zend_execute_data)); + memset(execute_data->prev_execute_data, 0, sizeof(zend_execute_data)); + execute_data->prev_execute_data->function_state.function = (zend_function *) op_array; if (EG(current_execute_data)) { - memcpy(execute_data->prev_execute_data, EG(current_execute_data), sizeof(zend_execute_data)); execute_data->prev_execute_data->function_state.arguments = zend_copy_arguments(EG(current_execute_data)->function_state.arguments); } else { - memset(execute_data->prev_execute_data, 0, sizeof(zend_execute_data)); - execute_data->prev_execute_data->function_state.function = (zend_function *) op_array; execute_data->prev_execute_data->function_state.arguments = NULL; } @@ -450,6 +450,12 @@ static void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ memcpy(generator->backed_up_stack, generator->original_stack_top, generator->backed_up_stack_size); zend_vm_stack_free(generator->original_stack_top TSRMLS_CC); } + + /* If an exception was thrown in the generator we have to internally + * rethrow it in the parent scope. */ + if (UNEXPECTED(EG(exception) != NULL)) { + zend_throw_exception_internal(NULL TSRMLS_CC); + } } } /* }}} */ diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 6b8425558c984..03768e8bd74fe 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5088,7 +5088,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) EX(old_error_reporting) = NULL; if (!catched) { - /* For generators skip the leave handler return directly */ + /* For generators skip the leave handler and return directly */ if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 9a9917fede26b..5ded3e39c7e21 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1151,7 +1151,7 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER EX(old_error_reporting) = NULL; if (!catched) { - /* For generators skip the leave handler return directly */ + /* For generators skip the leave handler and return directly */ if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); From 134089372b94de2e3e8c2a1aba4cbc415c803d67 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 22 Jul 2012 20:11:09 +0200 Subject: [PATCH 1957/2394] Throw error also for return occuring before yield Previously only an error was thrown when return occured after yield. Also returns before the first yield would fail for by-ref generators. Now the error message is handled in pass_two, so all returns are checked. --- .../generator_cannot_return_before_yield_error.phpt | 13 +++++++++++++ .../errors/generator_cannot_return_error.phpt | 2 +- Zend/zend_compile.c | 9 ++------- Zend/zend_opcode.c | 12 ++++++++++++ 4 files changed, 28 insertions(+), 8 deletions(-) create mode 100644 Zend/tests/generators/errors/generator_cannot_return_before_yield_error.phpt diff --git a/Zend/tests/generators/errors/generator_cannot_return_before_yield_error.phpt b/Zend/tests/generators/errors/generator_cannot_return_before_yield_error.phpt new file mode 100644 index 0000000000000..ad618d20ba2d4 --- /dev/null +++ b/Zend/tests/generators/errors/generator_cannot_return_before_yield_error.phpt @@ -0,0 +1,13 @@ +--TEST-- +Generators cannot return values (even before yield) +--FILE-- + +--EXPECTF-- +Fatal error: Generators cannot return values using "return" in %s on line 4 diff --git a/Zend/tests/generators/errors/generator_cannot_return_error.phpt b/Zend/tests/generators/errors/generator_cannot_return_error.phpt index 9a46bff5e6664..51149062a7ed6 100644 --- a/Zend/tests/generators/errors/generator_cannot_return_error.phpt +++ b/Zend/tests/generators/errors/generator_cannot_return_error.phpt @@ -10,4 +10,4 @@ function gen() { ?> --EXPECTF-- -Fatal error: Generators cannot return values using "return" in %s on line %d +Fatal error: Generators cannot return values using "return" in %s on line 5 diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index f0648a2d977fa..483ff30ddc7fd 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2611,14 +2611,9 @@ void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC) /* {{{ */ { zend_op *opline; int start_op_number, end_op_number; + zend_bool returns_reference = (CG(active_op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; - /* For generators the & modifier applies to the yielded values, not the - * return value. */ - zend_bool returns_reference = (CG(active_op_array)->fn_flags & ZEND_ACC_RETURN_REFERENCE) && !(CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR); - - if ((CG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) && expr != NULL) { - zend_error(E_COMPILE_ERROR, "Generators cannot return values using \"return\""); - } + /* The error for use of return inside a generator is thrown in pass_two. */ if (do_end_vparse) { if (returns_reference && !zend_is_function_or_method_call(expr)) { diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 65fa85185ef86..0042c37299778 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -532,6 +532,18 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) case ZEND_JMP_SET_VAR: opline->op2.jmp_addr = &op_array->opcodes[opline->op2.opline_num]; break; + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + if (op_array->fn_flags & ZEND_ACC_GENERATOR) { + if (opline->op1_type != IS_CONST || Z_TYPE_P(opline->op1.zv) != IS_NULL) { + CG(zend_lineno) = opline->lineno; + zend_error(E_COMPILE_ERROR, "Generators cannot return values using \"return\""); + } + if (opline->opcode == ZEND_RETURN_BY_REF) { + opline->opcode = ZEND_RETURN; + } + } + break; } ZEND_VM_SET_OPCODE_HANDLER(opline); opline++; From 99f93dd9a846e3d615ec61c734aca2e7ee256600 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 22 Jul 2012 20:19:07 +0200 Subject: [PATCH 1958/2394] Add T_YIELD in tokenizer_data.c Also had to fix up some tokenizer tests that were affected by the token number changes. --- .../tests/token_get_all_variation11.phpt | 4 ++-- .../tests/token_get_all_variation13.phpt | 2 +- .../tests/token_get_all_variation17.phpt | 2 +- .../tests/token_get_all_variation4.phpt | 4 ++-- .../tests/token_get_all_variation5.phpt | 22 +++++++++---------- .../tests/token_get_all_variation6.phpt | 4 ++-- .../tests/token_get_all_variation8.phpt | 2 +- ext/tokenizer/tokenizer_data.c | 2 ++ 8 files changed, 22 insertions(+), 20 deletions(-) diff --git a/ext/tokenizer/tests/token_get_all_variation11.phpt b/ext/tokenizer/tests/token_get_all_variation11.phpt index ecc86177a4dfb..98d89961b77bd 100644 --- a/ext/tokenizer/tests/token_get_all_variation11.phpt +++ b/ext/tokenizer/tests/token_get_all_variation11.phpt @@ -130,7 +130,7 @@ array(49) { [6]=> array(3) { [0]=> - int(283) + int(%d) [1]=> string(2) "==" [2]=> @@ -273,7 +273,7 @@ array(49) { [27]=> array(3) { [0]=> - int(283) + int(%d) [1]=> string(2) "==" [2]=> diff --git a/ext/tokenizer/tests/token_get_all_variation13.phpt b/ext/tokenizer/tests/token_get_all_variation13.phpt index 9b2f3bc94fb61..6f85492a99a7f 100644 --- a/ext/tokenizer/tests/token_get_all_variation13.phpt +++ b/ext/tokenizer/tests/token_get_all_variation13.phpt @@ -1005,7 +1005,7 @@ array(145) { [122]=> array(3) { [0]=> - int(288) + int(%d) [1]=> string(10) "instanceof" [2]=> diff --git a/ext/tokenizer/tests/token_get_all_variation17.phpt b/ext/tokenizer/tests/token_get_all_variation17.phpt index dccc4c9c23dd9..f71444bc1e84d 100644 --- a/ext/tokenizer/tests/token_get_all_variation17.phpt +++ b/ext/tokenizer/tests/token_get_all_variation17.phpt @@ -145,7 +145,7 @@ array(81) { [14]=> array(3) { [0]=> - int(283) + int(%d) [1]=> string(2) "==" [2]=> diff --git a/ext/tokenizer/tests/token_get_all_variation4.phpt b/ext/tokenizer/tests/token_get_all_variation4.phpt index 45e6f8afbdefe..6bc111efbac25 100644 --- a/ext/tokenizer/tests/token_get_all_variation4.phpt +++ b/ext/tokenizer/tests/token_get_all_variation4.phpt @@ -339,7 +339,7 @@ array(89) { [38]=> array(3) { [0]=> - int(279) + int(%d) [1]=> string(2) "&&" [2]=> @@ -518,7 +518,7 @@ array(89) { [60]=> array(3) { [0]=> - int(278) + int(%d) [1]=> string(2) "||" [2]=> diff --git a/ext/tokenizer/tests/token_get_all_variation5.phpt b/ext/tokenizer/tests/token_get_all_variation5.phpt index 0068f2866fb36..681fb48e573ff 100644 --- a/ext/tokenizer/tests/token_get_all_variation5.phpt +++ b/ext/tokenizer/tests/token_get_all_variation5.phpt @@ -181,7 +181,7 @@ array(94) { [18]=> array(3) { [0]=> - int(277) + int(%d) [1]=> string(2) "+=" [2]=> @@ -238,7 +238,7 @@ array(94) { [25]=> array(3) { [0]=> - int(276) + int(%d) [1]=> string(2) "-=" [2]=> @@ -295,7 +295,7 @@ array(94) { [32]=> array(3) { [0]=> - int(275) + int(%d) [1]=> string(2) "*=" [2]=> @@ -352,7 +352,7 @@ array(94) { [39]=> array(3) { [0]=> - int(274) + int(%d) [1]=> string(2) "/=" [2]=> @@ -409,7 +409,7 @@ array(94) { [46]=> array(3) { [0]=> - int(272) + int(%d) [1]=> string(2) "%=" [2]=> @@ -466,7 +466,7 @@ array(94) { [53]=> array(3) { [0]=> - int(271) + int(%d) [1]=> string(2) "&=" [2]=> @@ -523,7 +523,7 @@ array(94) { [60]=> array(3) { [0]=> - int(270) + int(%d) [1]=> string(2) "|=" [2]=> @@ -580,7 +580,7 @@ array(94) { [67]=> array(3) { [0]=> - int(269) + int(%d) [1]=> string(2) "^=" [2]=> @@ -637,7 +637,7 @@ array(94) { [74]=> array(3) { [0]=> - int(267) + int(%d) [1]=> string(3) ">>=" [2]=> @@ -694,7 +694,7 @@ array(94) { [81]=> array(3) { [0]=> - int(268) + int(%d) [1]=> string(3) "<<=" [2]=> @@ -751,7 +751,7 @@ array(94) { [88]=> array(3) { [0]=> - int(273) + int(%d) [1]=> string(2) ".=" [2]=> diff --git a/ext/tokenizer/tests/token_get_all_variation6.phpt b/ext/tokenizer/tests/token_get_all_variation6.phpt index 54936d0c89ac3..6213dab9d0522 100644 --- a/ext/tokenizer/tests/token_get_all_variation6.phpt +++ b/ext/tokenizer/tests/token_get_all_variation6.phpt @@ -191,7 +191,7 @@ array(50) { [21]=> array(3) { [0]=> - int(287) + int(%d) [1]=> string(2) "<<" [2]=> @@ -277,7 +277,7 @@ array(50) { [32]=> array(3) { [0]=> - int(286) + int(%d) [1]=> string(2) ">>" [2]=> diff --git a/ext/tokenizer/tests/token_get_all_variation8.phpt b/ext/tokenizer/tests/token_get_all_variation8.phpt index 0cf1d63471127..c80a5d0f04d5a 100644 --- a/ext/tokenizer/tests/token_get_all_variation8.phpt +++ b/ext/tokenizer/tests/token_get_all_variation8.phpt @@ -794,7 +794,7 @@ array(108) { [103]=> array(3) { [0]=> - int(289) + int(%d) [1]=> string(7) "(unset)" [2]=> diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index 85822f1994085..85fa343db1e8f 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -108,6 +108,7 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_FUNCTION", T_FUNCTION, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CONST", T_CONST, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_RETURN", T_RETURN, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("T_YIELD", T_YIELD, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_TRY", T_TRY, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CATCH", T_CATCH, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_THROW", T_THROW, CONST_CS | CONST_PERSISTENT); @@ -242,6 +243,7 @@ char *get_token_type_name(int token_type) case T_FUNCTION: return "T_FUNCTION"; case T_CONST: return "T_CONST"; case T_RETURN: return "T_RETURN"; + case T_YIELD: return "T_YIELD"; case T_TRY: return "T_TRY"; case T_CATCH: return "T_CATCH"; case T_THROW: return "T_THROW"; From b1a997e2a25d1f1422a237e12cff19a70a8eb317 Mon Sep 17 00:00:00 2001 From: Andrew Faulds Date: Mon, 23 Jul 2012 00:11:00 +0100 Subject: [PATCH 1959/2394] OK, bye bye JavaScript, let's just include credits before license --- ext/standard/info.c | 33 +++++++-------------------------- 1 file changed, 7 insertions(+), 26 deletions(-) diff --git a/ext/standard/info.c b/ext/standard/info.c index 83126c13778bc..11da06801260a 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -797,32 +797,6 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) efree(php_uname); } - if ((flag & PHP_INFO_CREDITS) && !sapi_module.phpinfo_as_text) { - php_info_print_hr(); - php_info_print("\n"); - php_info_print("

"); - php_info_print("PHP Credits"); - php_info_print("

\n"); - php_info_print("
\n"); - php_print_credits(PHP_CREDITS_ALL, TSRMLS_C); - php_info_print("
\n"); - } - zend_ini_sort_entries(TSRMLS_C); if (flag & PHP_INFO_CONFIGURATION) { @@ -904,6 +878,12 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) php_info_print_table_end(); } + + if ((flag & PHP_INFO_CREDITS) && !sapi_module.phpinfo_as_text) { + php_info_print_hr(); + php_print_credits(PHP_CREDITS_ALL, TSRMLS_C); + } + if (flag & PHP_INFO_LICENSE) { if (!sapi_module.phpinfo_as_text) { SECTION("PHP License"); @@ -937,6 +917,7 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) php_info_print("questions about PHP licensing, please contact license@php.net.\n"); } } + if (!sapi_module.phpinfo_as_text) { php_info_print(""); } From 0dfcc3e798cd54714f792bf7507c37b96146ee1b Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 23 Jul 2012 16:36:24 +0200 Subject: [PATCH 1960/2394] Add ini setting intl.explicit_cleanup This is to help with looking for leaks. If set to true, this ini setting forces a call to u_cleanup() on module shutdown. --- ext/intl/php_intl.c | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index d7ed9dc6e5931..41a1d1c0af760 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -96,6 +96,7 @@ #include "common/common_enum.h" #include +#include #include #include "php_ini.h" @@ -852,16 +853,39 @@ zend_function_entry intl_functions[] = { }; /* }}} */ +static zend_bool explicit_cleanup = 0; + +static ZEND_INI_MH(OnExplicitCleanupUpdate) +{ + if (stage == PHP_INI_STAGE_STARTUP) { + if (new_value_length == 2 && strcasecmp("on", new_value) == 0) { + explicit_cleanup = (zend_bool)1; + } + else if (new_value_length == 3 && strcasecmp("yes", new_value) == 0) { + explicit_cleanup = (zend_bool)1; + } + else if (new_value_length == 4 && strcasecmp("true", new_value) == 0) { + explicit_cleanup = (zend_bool)1; + } + else { + explicit_cleanup = (zend_bool)atoi(new_value); + } + return SUCCESS; + } else { + return FAILURE; + } +} + /* {{{ INI Settings */ PHP_INI_BEGIN() STD_PHP_INI_ENTRY(LOCALE_INI_NAME, NULL, PHP_INI_ALL, OnUpdateStringUnempty, default_locale, zend_intl_globals, intl_globals) STD_PHP_INI_ENTRY("intl.error_level", "0", PHP_INI_ALL, OnUpdateLong, error_level, zend_intl_globals, intl_globals) STD_PHP_INI_ENTRY("intl.use_exceptions", "0", PHP_INI_ALL, OnUpdateBool, use_exceptions, zend_intl_globals, intl_globals) + PHP_INI_ENTRY_EX("intl.explicit_cleanup", "0", 0, OnExplicitCleanupUpdate, zend_ini_boolean_displayer_cb) PHP_INI_END() /* }}} */ - static PHP_GINIT_FUNCTION(intl); /* {{{ intl_module_entry */ @@ -1003,6 +1027,10 @@ PHP_MSHUTDOWN_FUNCTION( intl ) /* For the default locale php.ini setting */ UNREGISTER_INI_ENTRIES(); + if (explicit_cleanup) { + u_cleanup(); + } + return SUCCESS; } /* }}} */ From c052b9c99ac09069d3f7c8ca5904c499ec842336 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 23 Jul 2012 16:38:27 +0200 Subject: [PATCH 1961/2394] Do not fetch default locale once on minit or rinit The default locale is now requested to ICU when it's needed by using intl_get_default_locale(). --- ext/intl/collator/collator_create.c | 2 +- ext/intl/dateformat/dateformat_create.cpp | 4 ++-- ext/intl/formatter/formatter_main.c | 2 +- ext/intl/locale/locale_methods.c | 16 ++++++++-------- ext/intl/msgformat/msgformat.c | 2 +- ext/intl/msgformat/msgformat_format.c | 2 +- ext/intl/msgformat/msgformat_parse.c | 2 +- ext/intl/php_intl.c | 9 --------- 8 files changed, 15 insertions(+), 24 deletions(-) diff --git a/ext/intl/collator/collator_create.c b/ext/intl/collator/collator_create.c index 0f0cc193e4c34..a3b70159f2a0e 100755 --- a/ext/intl/collator/collator_create.c +++ b/ext/intl/collator/collator_create.c @@ -48,7 +48,7 @@ static void collator_ctor(INTERNAL_FUNCTION_PARAMETERS) co = (Collator_object *) zend_object_store_get_object( object TSRMLS_CC ); if(locale_len == 0) { - locale = INTL_G(default_locale); + locale = intl_locale_get_default(TSRMLS_C); } /* Open ICU collator. */ diff --git a/ext/intl/dateformat/dateformat_create.cpp b/ext/intl/dateformat/dateformat_create.cpp index fef93e93d95b9..7fefbe7449c67 100644 --- a/ext/intl/dateformat/dateformat_create.cpp +++ b/ext/intl/dateformat/dateformat_create.cpp @@ -40,7 +40,7 @@ static void datefmt_ctor(INTERNAL_FUNCTION_PARAMETERS) { zval *object; - char *locale_str; + const char *locale_str; int locale_len = 0; Locale locale; long date_type = 0; @@ -72,7 +72,7 @@ static void datefmt_ctor(INTERNAL_FUNCTION_PARAMETERS) INTL_CHECK_LOCALE_LEN_OBJ(locale_len, return_value); if (locale_len == 0) { - locale_str = INTL_G(default_locale); + locale_str = intl_locale_get_default(TSRMLS_C); } locale = Locale::createFromName(locale_str); diff --git a/ext/intl/formatter/formatter_main.c b/ext/intl/formatter/formatter_main.c index 8fa17560b8957..96f1bcf2e3104 100755 --- a/ext/intl/formatter/formatter_main.c +++ b/ext/intl/formatter/formatter_main.c @@ -56,7 +56,7 @@ static void numfmt_ctor(INTERNAL_FUNCTION_PARAMETERS) } if(locale_len == 0) { - locale = INTL_G(default_locale); + locale = intl_locale_get_default(TSRMLS_C); } /* Create an ICU number formatter. */ diff --git a/ext/intl/locale/locale_methods.c b/ext/intl/locale/locale_methods.c index 936e3142ad96c..d1a86d8ee27f4 100755 --- a/ext/intl/locale/locale_methods.c +++ b/ext/intl/locale/locale_methods.c @@ -390,7 +390,7 @@ static void get_icu_value_src_php( char* tag_name, INTERNAL_FUNCTION_PARAMETERS) } if(loc_name_len == 0) { - loc_name = INTL_G(default_locale); + loc_name = intl_locale_get_default(TSRMLS_C); } /* Call ICU get */ @@ -496,7 +496,7 @@ static void get_icu_disp_value_src_php( char* tag_name, INTERNAL_FUNCTION_PARAME } 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 ){ @@ -518,7 +518,7 @@ static void get_icu_disp_value_src_php( char* tag_name, INTERNAL_FUNCTION_PARAME /* Check if disp_loc_name passed , if not use default locale */ if( !disp_loc_name){ - disp_loc_name = estrdup(INTL_G(default_locale)); + disp_loc_name = estrdup(intl_locale_get_default(TSRMLS_C)); free_loc_name = 1; } @@ -690,7 +690,7 @@ PHP_FUNCTION( locale_get_keywords ) } if(loc_name_len == 0) { - loc_name = INTL_G(default_locale); + loc_name = intl_locale_get_default(TSRMLS_C); } /* Get the keywords */ @@ -1097,7 +1097,7 @@ PHP_FUNCTION(locale_parse) } if(loc_name_len == 0) { - loc_name = INTL_G(default_locale); + loc_name = intl_locale_get_default(TSRMLS_C); } array_init( return_value ); @@ -1145,7 +1145,7 @@ PHP_FUNCTION(locale_get_all_variants) } if(loc_name_len == 0) { - loc_name = INTL_G(default_locale); + loc_name = intl_locale_get_default(TSRMLS_C); } @@ -1251,7 +1251,7 @@ PHP_FUNCTION(locale_filter_matches) } if(loc_range_len == 0) { - loc_range = INTL_G(default_locale); + loc_range = intl_locale_get_default(TSRMLS_C); } if( strcmp(loc_range,"*")==0){ @@ -1537,7 +1537,7 @@ PHP_FUNCTION(locale_lookup) } if(loc_range_len == 0) { - loc_range = INTL_G(default_locale); + loc_range = intl_locale_get_default(TSRMLS_C); } hash_arr = HASH_OF(arr); diff --git a/ext/intl/msgformat/msgformat.c b/ext/intl/msgformat/msgformat.c index 0a01204fae90d..45e5c7158b949 100755 --- a/ext/intl/msgformat/msgformat.c +++ b/ext/intl/msgformat/msgformat.c @@ -61,7 +61,7 @@ static void msgfmt_ctor(INTERNAL_FUNCTION_PARAMETERS) } if(locale_len == 0) { - locale = INTL_G(default_locale); + locale = intl_locale_get_default(TSRMLS_C); } #ifdef MSG_FORMAT_QUOTE_APOS diff --git a/ext/intl/msgformat/msgformat_format.c b/ext/intl/msgformat/msgformat_format.c index 39652327b981f..4b81cfe2b454c 100755 --- a/ext/intl/msgformat/msgformat_format.c +++ b/ext/intl/msgformat/msgformat_format.c @@ -134,7 +134,7 @@ PHP_FUNCTION( msgfmt_format_message ) } if(slocale_len == 0) { - slocale = INTL_G(default_locale); + slocale = intl_locale_get_default(TSRMLS_C); } #ifdef MSG_FORMAT_QUOTE_APOS diff --git a/ext/intl/msgformat/msgformat_parse.c b/ext/intl/msgformat/msgformat_parse.c index f540b1d0c4a4a..413d3b1f15d89 100755 --- a/ext/intl/msgformat/msgformat_parse.c +++ b/ext/intl/msgformat/msgformat_parse.c @@ -126,7 +126,7 @@ PHP_FUNCTION( msgfmt_parse_message ) } if(slocale_len == 0) { - slocale = INTL_G(default_locale); + slocale = intl_locale_get_default(TSRMLS_C); } #ifdef MSG_FORMAT_QUOTE_APOS diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index 41a1d1c0af760..38175ca54ccac 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -1011,11 +1011,6 @@ PHP_MINIT_FUNCTION( intl ) /* Global error handling. */ intl_error_init( NULL TSRMLS_CC ); - /* Set the default_locale value */ - if( INTL_G(default_locale) == NULL ) { - INTL_G(default_locale) = pestrdup(uloc_getDefault(), 1) ; - } - return SUCCESS; } /* }}} */ @@ -1039,10 +1034,6 @@ PHP_MSHUTDOWN_FUNCTION( intl ) */ PHP_RINIT_FUNCTION( intl ) { - /* Set the default_locale value */ - if( INTL_G(default_locale) == NULL ) { - INTL_G(default_locale) = pestrdup(uloc_getDefault(), 1) ; - } return SUCCESS; } /* }}} */ From d8d5f9a9f50a98e3a44218f8672a6516a9e8dfe7 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 23 Jul 2012 16:46:28 +0200 Subject: [PATCH 1962/2394] Fixed function name --- ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp b/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp index f2a39ba022553..61fb574682932 100644 --- a/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp +++ b/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp @@ -29,7 +29,7 @@ static inline RuleBasedBreakIterator *fetch_rbbi(BreakIterator_object *bio) { return (RuleBasedBreakIterator*)bio->biter; } -static void _php_intlgregcal_constructor_body(INTERNAL_FUNCTION_PARAMETERS) +static void _php_intlrbbi_constructor_body(INTERNAL_FUNCTION_PARAMETERS) { zval *object = getThis(); char *rules; @@ -96,7 +96,7 @@ U_CFUNC PHP_METHOD(IntlRuleBasedBreakIterator, __construct) return_value = getThis(); //changes this to IS_NULL (without first destroying) if there's an error - _php_intlgregcal_constructor_body(INTERNAL_FUNCTION_PARAM_PASSTHRU); + _php_intlrbbi_constructor_body(INTERNAL_FUNCTION_PARAM_PASSTHRU); if (Z_TYPE_P(return_value) == IS_NULL) { zend_object_store_ctor_failed(&orig_this TSRMLS_CC); From 01004c6abb53ee235f7d76295c48c3082c998a5b Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 23 Jul 2012 16:51:28 +0200 Subject: [PATCH 1963/2394] Fixed leak in RuleBasedBreakIterator constructor The leak occurred in case of error. --- ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp b/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp index 61fb574682932..454e5249fde96 100644 --- a/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp +++ b/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp @@ -70,6 +70,7 @@ static void _php_intlrbbi_constructor_body(INTERNAL_FUNCTION_PARAMETERS) smart_str_free(&parse_error_str); intl_error_set_custom_msg(NULL, msg, 1 TSRMLS_CC); efree(msg); + delete rbbi; RETURN_NULL(); } } else { // compiled @@ -78,6 +79,7 @@ static void _php_intlrbbi_constructor_body(INTERNAL_FUNCTION_PARAMETERS) if (U_FAILURE(status)) { intl_error_set(NULL, status, "rbbi_create_instance: unable to " "create instance from compiled rules", 0 TSRMLS_CC); + delete rbbi; RETURN_NULL(); } #else From ae3a827bf9b14c88bb7d52a19ad74bf0f074dc73 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 23 Jul 2012 17:00:52 +0200 Subject: [PATCH 1964/2394] Leak caused by wrong and unreachable cleanup --- ext/intl/dateformat/dateformat_format.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/intl/dateformat/dateformat_format.c b/ext/intl/dateformat/dateformat_format.c index d5a17f91cd399..ffae15518b08e 100755 --- a/ext/intl/dateformat/dateformat_format.c +++ b/ext/intl/dateformat/dateformat_format.c @@ -108,6 +108,7 @@ static UDate internal_get_timestamp(IntlDateFormatter_object *dfo, second, mday; UCalendar *pcal; + UDate result; intl_error *err = &dfo->datef_data.error; #define INTL_GET_ELEM(elem) \ @@ -137,10 +138,11 @@ static UDate internal_get_timestamp(IntlDateFormatter_object *dfo, /* set the incoming values for the calendar */ ucal_setDateTime(pcal, year, month, mday, hour, minute, second, &INTL_DATA_ERROR_CODE(dfo)); /* actually, ucal_setDateTime cannot fail */ - + /* Fetch the timestamp from the UCalendar */ - return ucal_getMillis(pcal, &INTL_DATA_ERROR_CODE(dfo)); - udat_close(pcal); + result = ucal_getMillis(pcal, &INTL_DATA_ERROR_CODE(dfo)); + ucal_close(pcal); + return result; } From 6126ac44b5348dc7aac9d2c67f8e927211dfee2f Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 24 Jul 2012 13:39:46 +0800 Subject: [PATCH 1965/2394] correct the author name introduced in bb685512 --- ext/zlib/zlib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index a0bec9c4c6b2b..eac757bbc58d0 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -13,7 +13,7 @@ | license@php.net so we can mail you a copy immediately. | +----------------------------------------------------------------------+ | Authors: Rasmus Lerdorf | - | Stefan R�hrich | + | Stefan Röhrich | | Zeev Suraski | | Jade Nicoletti | | Michael Wallner | From 45d596ea1e32792c7b7b7f28be220dea861b6708 Mon Sep 17 00:00:00 2001 From: Florian Anderiasch Date: Tue, 24 Jul 2012 13:15:16 +0200 Subject: [PATCH 1966/2394] Add optional depth parameter to json_encode #62369 --- ext/json/json.c | 10 +++++++++- ext/json/php_json.h | 1 + ext/json/tests/bug62369.phpt | 34 ++++++++++++++++++++++++++++++++++ 3 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 ext/json/tests/bug62369.phpt diff --git a/ext/json/json.c b/ext/json/json.c index 96690477c94de..dab423084c416 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -47,6 +47,7 @@ ZEND_DECLARE_MODULE_GLOBALS(json) ZEND_BEGIN_ARG_INFO_EX(arginfo_json_encode, 0, 0, 1) ZEND_ARG_INFO(0, value) ZEND_ARG_INFO(0, options) + ZEND_ARG_INFO(0, depth) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_json_decode, 0, 0, 1) @@ -126,6 +127,7 @@ static PHP_GINIT_FUNCTION(json) { json_globals->encoder_depth = 0; json_globals->error_code = 0; + json_globals->encode_max_depth = 0; } /* }}} */ @@ -341,6 +343,9 @@ static void json_encode_array(smart_str *buf, zval **val, int options TSRMLS_DC) } } + if (JSON_G(encoder_depth) > JSON_G(encode_max_depth)) { + JSON_G(error_code) = PHP_JSON_ERROR_DEPTH; + } --JSON_G(encoder_depth); json_pretty_print_char(buf, options, '\n' TSRMLS_CC); json_pretty_print_indent(buf, options TSRMLS_CC); @@ -702,13 +707,16 @@ static PHP_FUNCTION(json_encode) zval *parameter; smart_str buf = {0}; long options = 0; + long depth = JSON_PARSER_DEFAULT_DEPTH; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|l", ¶meter, &options) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|ll", ¶meter, &options, &depth) == FAILURE) { return; } JSON_G(error_code) = PHP_JSON_ERROR_NONE; + JSON_G(encode_max_depth) = depth; + php_json_encode(&buf, parameter, options TSRMLS_CC); if (JSON_G(error_code) != PHP_JSON_ERROR_NONE && !(options & PHP_JSON_PARTIAL_OUTPUT_ON_ERROR)) { diff --git a/ext/json/php_json.h b/ext/json/php_json.h index afeff3f6cc855..2b3cf5868ad4f 100644 --- a/ext/json/php_json.h +++ b/ext/json/php_json.h @@ -40,6 +40,7 @@ extern zend_module_entry json_module_entry; ZEND_BEGIN_MODULE_GLOBALS(json) int encoder_depth; int error_code; + int encode_max_depth; ZEND_END_MODULE_GLOBALS(json) #ifdef ZTS diff --git a/ext/json/tests/bug62369.phpt b/ext/json/tests/bug62369.phpt new file mode 100644 index 0000000000000..a5efd802c5ee6 --- /dev/null +++ b/ext/json/tests/bug62369.phpt @@ -0,0 +1,34 @@ +--TEST-- +FR #62369 (Segfault on json_encode(deeply_nested_array) +--SKIPIF-- + +--FILE-- + Date: Tue, 24 Jul 2012 15:13:02 +0200 Subject: [PATCH 1967/2394] ini intl.explicit_cleanup -> INTL_EXPLICIT_CLEANUP Added an environment variable and removed the ini setting intl.explicit_cleanup for calling u_cleanup() --- ext/intl/php_intl.c | 31 +++++-------------------------- 1 file changed, 5 insertions(+), 26 deletions(-) diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index 38175ca54ccac..78da0f5e32b0c 100755 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -853,36 +853,11 @@ zend_function_entry intl_functions[] = { }; /* }}} */ -static zend_bool explicit_cleanup = 0; - -static ZEND_INI_MH(OnExplicitCleanupUpdate) -{ - if (stage == PHP_INI_STAGE_STARTUP) { - if (new_value_length == 2 && strcasecmp("on", new_value) == 0) { - explicit_cleanup = (zend_bool)1; - } - else if (new_value_length == 3 && strcasecmp("yes", new_value) == 0) { - explicit_cleanup = (zend_bool)1; - } - else if (new_value_length == 4 && strcasecmp("true", new_value) == 0) { - explicit_cleanup = (zend_bool)1; - } - else { - explicit_cleanup = (zend_bool)atoi(new_value); - } - return SUCCESS; - } else { - return FAILURE; - } -} - - /* {{{ INI Settings */ PHP_INI_BEGIN() STD_PHP_INI_ENTRY(LOCALE_INI_NAME, NULL, PHP_INI_ALL, OnUpdateStringUnempty, default_locale, zend_intl_globals, intl_globals) STD_PHP_INI_ENTRY("intl.error_level", "0", PHP_INI_ALL, OnUpdateLong, error_level, zend_intl_globals, intl_globals) STD_PHP_INI_ENTRY("intl.use_exceptions", "0", PHP_INI_ALL, OnUpdateBool, use_exceptions, zend_intl_globals, intl_globals) - PHP_INI_ENTRY_EX("intl.explicit_cleanup", "0", 0, OnExplicitCleanupUpdate, zend_ini_boolean_displayer_cb) PHP_INI_END() /* }}} */ @@ -1015,14 +990,18 @@ PHP_MINIT_FUNCTION( intl ) } /* }}} */ +#define EXPLICIT_CLEANUP_ENV_VAR "INTL_EXPLICIT_CLEANUP" + /* {{{ PHP_MSHUTDOWN_FUNCTION */ PHP_MSHUTDOWN_FUNCTION( intl ) { + const char *cleanup; /* For the default locale php.ini setting */ UNREGISTER_INI_ENTRIES(); - if (explicit_cleanup) { + cleanup = getenv(EXPLICIT_CLEANUP_ENV_VAR); + if (cleanup != NULL && !(cleanup[0] == '0' && cleanup[1] == '\0')) { u_cleanup(); } From 0fbc8561e687689f796d95584cea1fa959eee83b Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Tue, 24 Jul 2012 16:28:49 -0700 Subject: [PATCH 1968/2394] Fix bug #62654 --- sapi/fpm/fpm/fpm_sockets.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sapi/fpm/fpm/fpm_sockets.c b/sapi/fpm/fpm/fpm_sockets.c index d24dcccc9af5f..f56b9cfbd1493 100644 --- a/sapi/fpm/fpm/fpm_sockets.c +++ b/sapi/fpm/fpm/fpm_sockets.c @@ -455,11 +455,11 @@ int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) #endif -int fpm_socket_unix_test_connect(struct sockaddr_un *sun, size_t socklen) /* {{{ */ +int fpm_socket_unix_test_connect(struct sockaddr_un *sock, size_t socklen) /* {{{ */ { int fd; - if (!sun || sun->sun_family != AF_UNIX) { + if (!sock || sock->sun_family != AF_UNIX) { return -1; } @@ -467,7 +467,7 @@ int fpm_socket_unix_test_connect(struct sockaddr_un *sun, size_t socklen) /* {{{ return -1; } - if (connect(fd, (struct sockaddr *)sun, socklen) == -1) { + if (connect(fd, (struct sockaddr *)sock, socklen) == -1) { return -1; } From ba568aaebb3f3c788a5551c016c0afafd7a5502e Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Thu, 26 Jul 2012 00:29:39 +0800 Subject: [PATCH 1969/2394] Fixed invalid read in CONST_STRING dereference, reported by Nikic --- Zend/zend_language_parser.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index e397fe138b9f7..c88e9a7c004e8 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -802,7 +802,7 @@ expr_without_variable: combined_scalar_offset: combined_scalar '[' dim_offset ']' { zend_do_begin_variable_parse(TSRMLS_C); fetch_array_dim(&$$, &$1, &$3 TSRMLS_CC); } | combined_scalar_offset '[' dim_offset ']' { fetch_array_dim(&$$, &$1, &$3 TSRMLS_CC); } - | T_CONSTANT_ENCAPSED_STRING '[' dim_offset ']' { zend_do_begin_variable_parse(TSRMLS_C); fetch_array_dim(&$$, &$1, &$3 TSRMLS_CC); } + | T_CONSTANT_ENCAPSED_STRING '[' dim_offset ']' { $1.EA = 0; zend_do_begin_variable_parse(TSRMLS_C); fetch_array_dim(&$$, &$1, &$3 TSRMLS_CC); } combined_scalar: T_ARRAY '(' array_pair_list ')' { $$ = $3; } From 268740d9848d435054ce73a8cfe36b2b732cd1f7 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 26 Jul 2012 17:07:24 +0200 Subject: [PATCH 1970/2394] Fix implementation of Iterator interface It looks like you have to implement the Iterator interface *before* assigning get_iterator. Otherwise the structure for user iterators isn't correctly zeroed out. Additionaly I'm setting class_entry->iterator_funcs.funcs now. Not sure if this is strictly necessary, but better safe than sorry ;) --- .../generator_in_multipleiterator.phpt | 37 +++++++++++++++++++ Zend/zend_generators.c | 4 +- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 Zend/tests/generators/generator_in_multipleiterator.phpt diff --git a/Zend/tests/generators/generator_in_multipleiterator.phpt b/Zend/tests/generators/generator_in_multipleiterator.phpt new file mode 100644 index 0000000000000..611dbc9652743 --- /dev/null +++ b/Zend/tests/generators/generator_in_multipleiterator.phpt @@ -0,0 +1,37 @@ +--TEST-- +Generators work properly in MultipleIterator +--FILE-- +attachIterator(gen1()); +$it->attachIterator(gen2()); + +foreach ($it as $values) { + var_dump($values); +} + +?> +--EXPECT-- +array(2) { + [0]=> + string(1) "a" + [1]=> + string(1) "b" +} +array(2) { + [0]=> + string(2) "aa" + [1]=> + string(2) "bb" +} diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index d7ffb3055a6a5..716b0a782edd1 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -759,9 +759,11 @@ void zend_register_generator_ce(TSRMLS_D) /* {{{ */ zend_ce_generator = zend_register_internal_class(&ce TSRMLS_CC); zend_ce_generator->ce_flags |= ZEND_ACC_FINAL_CLASS; zend_ce_generator->create_object = zend_generator_create; - zend_ce_generator->get_iterator = zend_generator_get_iterator; + /* get_iterator has to be assigned *after* implementing the inferface */ zend_class_implements(zend_ce_generator TSRMLS_CC, 1, zend_ce_iterator); + zend_ce_generator->get_iterator = zend_generator_get_iterator; + zend_ce_generator->iterator_funcs.funcs = &zend_generator_iterator_functions; memcpy(&zend_generator_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); zend_generator_handlers.get_constructor = zend_generator_get_constructor; From edece6ec84484690d7ddf8fe971a48747059ba60 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Thu, 26 Jul 2012 19:13:42 -0400 Subject: [PATCH 1971/2394] Fixed bug #62615 (test ext/curl/tests/curl_escape.phpt failed). curl_easy_escape was modified in 5.21.2 to not escape "unreserved" characters so this test will fail on version older than 5.21.2 --- ext/curl/tests/curl_escape.phpt | Bin 553 -> 688 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/curl/tests/curl_escape.phpt b/ext/curl/tests/curl_escape.phpt index 7c90fb98883249b398707037da94d7ad8dd3db4f..e759144c8ac876d734a5a4ddd5c6be231f75b61a 100644 GIT binary patch delta 146 zcmZ3|%xdyqroP0k%TH&Q`%( S&&ZHn&qxVqOYO#c-i!bOZ828> delta 11 ScmdnMx{_tW{mp5NUW@=7w*)r; From 594397993dcbbf2fd90f6df23a2124c0239ec73e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Thu, 26 Jul 2012 23:37:02 +0200 Subject: [PATCH 1972/2394] Fix bug #62651: source level BC break Break for C++ extensions that don't wrap the includes of PHP libraries in extern "C" {. --- Zend/zend_string.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Zend/zend_string.h b/Zend/zend_string.h index a61d2fb30d2a8..0a4738466d7a8 100644 --- a/Zend/zend_string.h +++ b/Zend/zend_string.h @@ -23,12 +23,14 @@ #include "zend.h" +BEGIN_EXTERN_C() ZEND_API extern const char *(*zend_new_interned_string)(const char *str, int len, int free_src TSRMLS_DC); ZEND_API extern void (*zend_interned_strings_snapshot)(TSRMLS_D); ZEND_API extern void (*zend_interned_strings_restore)(TSRMLS_D); void zend_interned_strings_init(TSRMLS_D); void zend_interned_strings_dtor(TSRMLS_D); +END_EXTERN_C() #ifndef ZTS From f8559194db82a231bbed547bd15f077e343914e4 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 29 Jul 2012 23:35:06 +0800 Subject: [PATCH 1973/2394] Fix test failed due to new feature introduced in 45d596ea --- ext/json/json.c | 2 +- ext/json/tests/json_encode_error.phpt | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/ext/json/json.c b/ext/json/json.c index dab423084c416..e4bb8a5d4be24 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -700,7 +700,7 @@ PHP_JSON_API void php_json_decode_ex(zval *return_value, char *str, int str_len, /* }}} */ -/* {{{ proto string json_encode(mixed data [, int options]) +/* {{{ proto string json_encode(mixed data [, int options[, int depth]]) Returns the JSON representation of a value */ static PHP_FUNCTION(json_encode) { diff --git a/ext/json/tests/json_encode_error.phpt b/ext/json/tests/json_encode_error.phpt index d130dd960c5b7..547c8bef17bf5 100644 --- a/ext/json/tests/json_encode_error.phpt +++ b/ext/json/tests/json_encode_error.phpt @@ -34,7 +34,5 @@ Warning: json_encode() expects at least 1 parameter, 0 given in %s on line %d NULL -- Testing json_encode() function with more than expected no. of arguments -- - -Warning: json_encode() expects at most 2 parameters, 3 given in %s on line %d -NULL +string(5) ""abc"" ===Done=== From 79c6c93e0d7ed360e8b1f0209c5f3e10692309ac Mon Sep 17 00:00:00 2001 From: andrey Date: Mon, 30 Jul 2012 21:50:13 +0300 Subject: [PATCH 1974/2394] Fix crashes with filenames that don't contain directory separator - generated files like scanners/parsers. --- ext/mysqlnd/mysqlnd_alloc.c | 54 +++++++++++++++++++++++++++---------- 1 file changed, 40 insertions(+), 14 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_alloc.c b/ext/mysqlnd/mysqlnd_alloc.c index 65423e44fa2fd..e681d338568a9 100644 --- a/ext/mysqlnd/mysqlnd_alloc.c +++ b/ext/mysqlnd/mysqlnd_alloc.c @@ -81,9 +81,11 @@ void * _mysqlnd_emalloc(size_t size MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = &MYSQLND_G(debug_emalloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_emalloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); #if PHP_DEBUG /* -1 is also "true" */ @@ -116,9 +118,10 @@ void * _mysqlnd_pemalloc(size_t size, zend_bool persistent MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = persistent? &MYSQLND_G(debug_malloc_fail_threshold):&MYSQLND_G(debug_emalloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_pemalloc_name); TRACE_ALLOC_INF_FMT("file=%-15s line=%4d persistent=%u", - strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno,persistent); + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno, persistent); #if PHP_DEBUG /* -1 is also "true" */ @@ -154,8 +157,10 @@ void * _mysqlnd_ecalloc(unsigned int nmemb, size_t size MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = &MYSQLND_G(debug_ecalloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_ecalloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("before: %lu", zend_memory_usage(FALSE TSRMLS_CC)); #if PHP_DEBUG @@ -189,9 +194,10 @@ void * _mysqlnd_pecalloc(unsigned int nmemb, size_t size, zend_bool persistent M #if PHP_DEBUG long * threshold = persistent? &MYSQLND_G(debug_calloc_fail_threshold):&MYSQLND_G(debug_ecalloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_pecalloc_name); TRACE_ALLOC_INF_FMT("file=%-15s line=%4d persistent=%u", - strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno, persistent); + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno, persistent); #if PHP_DEBUG /* -1 is also "true" */ @@ -228,8 +234,10 @@ void * _mysqlnd_erealloc(void *ptr, size_t new_size MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = &MYSQLND_G(debug_erealloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_erealloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p old_size=%lu, new_size=%lu", ptr, old_size, new_size); #if PHP_DEBUG @@ -263,8 +271,10 @@ void * _mysqlnd_perealloc(void *ptr, size_t new_size, zend_bool persistent MYSQL #if PHP_DEBUG long * threshold = persistent? &MYSQLND_G(debug_realloc_fail_threshold):&MYSQLND_G(debug_erealloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_perealloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p old_size=%lu new_size=%lu persistent=%u", ptr, old_size, new_size, persistent); #if PHP_DEBUG @@ -297,8 +307,10 @@ void _mysqlnd_efree(void *ptr MYSQLND_MEM_D) { size_t free_amount = 0; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_efree_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p", ptr); if (ptr) { @@ -322,8 +334,10 @@ void _mysqlnd_pefree(void *ptr, zend_bool persistent MYSQLND_MEM_D) { size_t free_amount = 0; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_pefree_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p persistent=%u", ptr, persistent); if (ptr) { @@ -351,8 +365,10 @@ void * _mysqlnd_malloc(size_t size MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = &MYSQLND_G(debug_malloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_malloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); #if PHP_DEBUG /* -1 is also "true" */ @@ -384,8 +400,10 @@ void * _mysqlnd_calloc(unsigned int nmemb, size_t size MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = &MYSQLND_G(debug_calloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_calloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); #if PHP_DEBUG /* -1 is also "true" */ @@ -417,8 +435,10 @@ void * _mysqlnd_realloc(void *ptr, size_t new_size MYSQLND_MEM_D) #if PHP_DEBUG long * threshold = &MYSQLND_G(debug_realloc_fail_threshold); #endif + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_realloc_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p new_size=%lu ", new_size, ptr); TRACE_ALLOC_INF_FMT("before: %lu", zend_memory_usage(TRUE TSRMLS_CC)); @@ -450,8 +470,10 @@ void _mysqlnd_free(void *ptr MYSQLND_MEM_D) { size_t free_amount = 0; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_free_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p", ptr); if (ptr) { @@ -479,8 +501,10 @@ char * _mysqlnd_pestrndup(const char * const ptr, size_t length, zend_bool persi { char * ret; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_pestrndup_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p", ptr); ret = (persistent) ? __zend_malloc(REAL_SIZE(length + 1)) : _emalloc(REAL_SIZE(length + 1) ZEND_FILE_LINE_CC ZEND_FILE_LINE_ORIG_RELAY_CC); @@ -511,8 +535,10 @@ char * _mysqlnd_pestrdup(const char * const ptr, zend_bool persistent MYSQLND_ME smart_str tmp_str = {0, 0, 0}; const char * p = ptr; zend_bool collect_memory_statistics = MYSQLND_G(collect_memory_statistics); + char * fn = NULL; TRACE_ALLOC_ENTER(mysqlnd_pestrdup_name); - TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR) + 1, __zend_orig_lineno); + TRACE_ALLOC_INF_FMT("file=%-15s line=%4d", + (fn = strrchr(__zend_orig_filename, PHP_DIR_SEPARATOR))? fn + 1:__zend_orig_filename, __zend_orig_lineno); TRACE_ALLOC_INF_FMT("ptr=%p", ptr); do { smart_str_appendc(&tmp_str, *p); From 81369bcc2027f455d3ff8ead6d884159f2194cfd Mon Sep 17 00:00:00 2001 From: Nuno Lopes Date: Thu, 2 Aug 2012 11:44:15 +0100 Subject: [PATCH 1975/2394] make default_exception_ce and error_exception_ce static --- Zend/zend_exceptions.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/zend_exceptions.c b/Zend/zend_exceptions.c index 7bb7792a4c805..787e66bfe991d 100644 --- a/Zend/zend_exceptions.c +++ b/Zend/zend_exceptions.c @@ -29,8 +29,8 @@ #include "zend_vm.h" #include "zend_dtrace.h" -zend_class_entry *default_exception_ce; -zend_class_entry *error_exception_ce; +static zend_class_entry *default_exception_ce; +static zend_class_entry *error_exception_ce; static zend_object_handlers default_exception_handlers; ZEND_API void (*zend_throw_exception_hook)(zval *ex TSRMLS_DC); From a6a7787cf25af0cf5b5672b677e20d9d40963137 Mon Sep 17 00:00:00 2001 From: Dmitri Iouchtchenko Date: Sun, 29 Jul 2012 13:41:40 -0400 Subject: [PATCH 1976/2394] Fix #61642: modify("+5 weekdays") returns Sunday Adding a non-zero multiple of 5 weekdays to any Friday, Saturday, or Sunday would result in a Sunday instead of the correct date. This patch provides an implementation of do_adjust_special_weekday() which does not suffer from this issue. --- ext/date/lib/tm2unixtime.c | 75 +++++++++++++++++------------------- ext/date/tests/bug61642.phpt | 62 +++++++++++++++++++++++++++++ 2 files changed, 98 insertions(+), 39 deletions(-) create mode 100644 ext/date/tests/bug61642.phpt diff --git a/ext/date/lib/tm2unixtime.c b/ext/date/lib/tm2unixtime.c index c4830bbef0c7b..9055fee203f54 100644 --- a/ext/date/lib/tm2unixtime.c +++ b/ext/date/lib/tm2unixtime.c @@ -220,55 +220,52 @@ static void do_adjust_relative(timelib_time* time) static void do_adjust_special_weekday(timelib_time* time) { - timelib_sll current_dow, count; + timelib_sll count, dow, rem; count = time->relative.special.amount; + dow = timelib_day_of_week(time->y, time->m, time->d); - current_dow = timelib_day_of_week(time->y, time->m, time->d); - if (count == 0) { - /* skip over saturday and sunday */ - if (current_dow == 6) { - time->d += 2; - } - /* skip over sunday */ - if (current_dow == 0) { - time->d += 1; - } - } else if (count > 0) { - /* skip over saturday and sunday */ - if (current_dow == 5) { - time->d += 2; - } - /* skip over sunday */ - if (current_dow == 6) { + /* Add increments of 5 weekdays as a week, leaving the DOW unchanged. */ + time->d += (count / 5) * 7; + + /* Deal with the remainder. */ + rem = (count % 5); + + if (count > 0) { + if (rem == 0) { + /* Head back to Friday if we stop on the weekend. */ + if (dow == 0) { + time->d -= 2; + } else if (dow == 6) { + time->d -= 1; + } + } else if (dow == 6) { + /* We ended up on Saturday, but there's still work to do, so move + * to Sunday and continue from there. */ time->d += 1; - } - /* add increments of 5 weekdays as a week */ - time->d += (count / 5) * 7; - /* if current DOW plus the remainder > 5, add two days */ - current_dow = timelib_day_of_week(time->y, time->m, time->d); - time->d += (count % 5); - if ((count % 5) + current_dow > 5) { + } else if (dow + rem > 5) { + /* We're on a weekday, but we're going past Friday, so skip right + * over the weekend. */ time->d += 2; } - } else if (count < 0) { - /* skip over sunday and saturday */ - if (current_dow == 1) { - time->d -= 2; - } - /* skip over satruday */ - if (current_dow == 0 ) { + } else { + /* Completely mirror the forward direction. This also covers the 0 + * case, since if we start on the weekend, we want to move forward as + * if we stopped there while going backwards. */ + if (rem == 0) { + if (dow == 6) { + time->d += 2; + } else if (dow == 0) { + time->d += 1; + } + } else if (dow == 0) { time->d -= 1; - } - /* subtract increments of 5 weekdays as a week */ - time->d += (count / 5) * 7; - /* if current DOW minus the remainder < 0, subtract two days */ - current_dow = timelib_day_of_week(time->y, time->m, time->d); - time->d += (count % 5); - if ((count % 5) + current_dow < 1) { + } else if (dow + rem < 1) { time->d -= 2; } } + + time->d += rem; } static void do_adjust_special(timelib_time* time) diff --git a/ext/date/tests/bug61642.phpt b/ext/date/tests/bug61642.phpt new file mode 100644 index 0000000000000..d03a814d88279 --- /dev/null +++ b/ext/date/tests/bug61642.phpt @@ -0,0 +1,62 @@ +--TEST-- +Bug #61642 (modify("+5 weekdays") returns Sunday) +--INI-- +date.timezone=UTC +--FILE-- +format('Y-m-d D'); +} + +echo '### ', implode(' ', $header), "\n\n"; + +foreach ($weekdays as $days) { + $line = array(); + + printf('%+3d ', $days); + + foreach ($dates as $startdate) { + $date = new DateTime($startdate); + $date->modify("{$days} weekdays"); + + $line[] = $date->format('Y-m-d D'); + } + + echo implode(' ', $line), "\n"; +} +?> +--EXPECTF-- +### 2012-03-29 Thu 2012-03-30 Fri 2012-03-31 Sat 2012-04-01 Sun 2012-04-02 Mon 2012-04-03 Tue 2012-04-04 Wed 2012-04-05 Thu + +-11 2012-03-14 Wed 2012-03-15 Thu 2012-03-16 Fri 2012-03-16 Fri 2012-03-16 Fri 2012-03-19 Mon 2012-03-20 Tue 2012-03-21 Wed +-10 2012-03-15 Thu 2012-03-16 Fri 2012-03-19 Mon 2012-03-19 Mon 2012-03-19 Mon 2012-03-20 Tue 2012-03-21 Wed 2012-03-22 Thu + -9 2012-03-16 Fri 2012-03-19 Mon 2012-03-20 Tue 2012-03-20 Tue 2012-03-20 Tue 2012-03-21 Wed 2012-03-22 Thu 2012-03-23 Fri + -8 2012-03-19 Mon 2012-03-20 Tue 2012-03-21 Wed 2012-03-21 Wed 2012-03-21 Wed 2012-03-22 Thu 2012-03-23 Fri 2012-03-26 Mon + -7 2012-03-20 Tue 2012-03-21 Wed 2012-03-22 Thu 2012-03-22 Thu 2012-03-22 Thu 2012-03-23 Fri 2012-03-26 Mon 2012-03-27 Tue + -6 2012-03-21 Wed 2012-03-22 Thu 2012-03-23 Fri 2012-03-23 Fri 2012-03-23 Fri 2012-03-26 Mon 2012-03-27 Tue 2012-03-28 Wed + -5 2012-03-22 Thu 2012-03-23 Fri 2012-03-26 Mon 2012-03-26 Mon 2012-03-26 Mon 2012-03-27 Tue 2012-03-28 Wed 2012-03-29 Thu + -4 2012-03-23 Fri 2012-03-26 Mon 2012-03-27 Tue 2012-03-27 Tue 2012-03-27 Tue 2012-03-28 Wed 2012-03-29 Thu 2012-03-30 Fri + -3 2012-03-26 Mon 2012-03-27 Tue 2012-03-28 Wed 2012-03-28 Wed 2012-03-28 Wed 2012-03-29 Thu 2012-03-30 Fri 2012-04-02 Mon + -2 2012-03-27 Tue 2012-03-28 Wed 2012-03-29 Thu 2012-03-29 Thu 2012-03-29 Thu 2012-03-30 Fri 2012-04-02 Mon 2012-04-03 Tue + -1 2012-03-28 Wed 2012-03-29 Thu 2012-03-30 Fri 2012-03-30 Fri 2012-03-30 Fri 2012-04-02 Mon 2012-04-03 Tue 2012-04-04 Wed + +0 2012-03-29 Thu 2012-03-30 Fri 2012-04-02 Mon 2012-04-02 Mon 2012-04-02 Mon 2012-04-03 Tue 2012-04-04 Wed 2012-04-05 Thu + +1 2012-03-30 Fri 2012-04-02 Mon 2012-04-02 Mon 2012-04-02 Mon 2012-04-03 Tue 2012-04-04 Wed 2012-04-05 Thu 2012-04-06 Fri + +2 2012-04-02 Mon 2012-04-03 Tue 2012-04-03 Tue 2012-04-03 Tue 2012-04-04 Wed 2012-04-05 Thu 2012-04-06 Fri 2012-04-09 Mon + +3 2012-04-03 Tue 2012-04-04 Wed 2012-04-04 Wed 2012-04-04 Wed 2012-04-05 Thu 2012-04-06 Fri 2012-04-09 Mon 2012-04-10 Tue + +4 2012-04-04 Wed 2012-04-05 Thu 2012-04-05 Thu 2012-04-05 Thu 2012-04-06 Fri 2012-04-09 Mon 2012-04-10 Tue 2012-04-11 Wed + +5 2012-04-05 Thu 2012-04-06 Fri 2012-04-06 Fri 2012-04-06 Fri 2012-04-09 Mon 2012-04-10 Tue 2012-04-11 Wed 2012-04-12 Thu + +6 2012-04-06 Fri 2012-04-09 Mon 2012-04-09 Mon 2012-04-09 Mon 2012-04-10 Tue 2012-04-11 Wed 2012-04-12 Thu 2012-04-13 Fri + +7 2012-04-09 Mon 2012-04-10 Tue 2012-04-10 Tue 2012-04-10 Tue 2012-04-11 Wed 2012-04-12 Thu 2012-04-13 Fri 2012-04-16 Mon + +8 2012-04-10 Tue 2012-04-11 Wed 2012-04-11 Wed 2012-04-11 Wed 2012-04-12 Thu 2012-04-13 Fri 2012-04-16 Mon 2012-04-17 Tue + +9 2012-04-11 Wed 2012-04-12 Thu 2012-04-12 Thu 2012-04-12 Thu 2012-04-13 Fri 2012-04-16 Mon 2012-04-17 Tue 2012-04-18 Wed ++10 2012-04-12 Thu 2012-04-13 Fri 2012-04-13 Fri 2012-04-13 Fri 2012-04-16 Mon 2012-04-17 Tue 2012-04-18 Wed 2012-04-19 Thu ++11 2012-04-13 Fri 2012-04-16 Mon 2012-04-16 Mon 2012-04-16 Mon 2012-04-17 Tue 2012-04-18 Wed 2012-04-19 Thu 2012-04-20 Fri From 54b1414be00a7ea8a6ae87c7e45d6a9d405578d2 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 5 Aug 2012 19:25:15 -0700 Subject: [PATCH 1977/2394] add #61642 --- NEWS | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index eb4b7dfe7bd7c..56a947764f5a0 100644 --- a/NEWS +++ b/NEWS @@ -40,9 +40,13 @@ PHP NEWS CURLOPT_TRANSFER_ENCODING, CURLOPT_DNS_SERVERS and CURLOPT_USE_SSL. (Pierrick) . Fixed bug #55635 (CURLOPT_BINARYTRANSFER no longer used. The constant - still exists for backward compatibility but is doing nothing). (Pierrick) + still exists for backward compatibility but is doing nothing). (Pierrick) . Fixed bug #54995 (Missing CURLINFO_RESPONSE_CODE support). (Pierrick) +- Datetime + . Fixed bug #61642 (modify("+5 weekdays") returns Sunday). + (Dmitri Iouchtchenko) + - Hash . Added support for PBKDF2 via hash_pbkdf2(). (Anthony Ferrara) From 4a2d41a5bbcac465f4f8ec616ce25196326df7b4 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 5 Aug 2012 20:41:14 -0700 Subject: [PATCH 1978/2394] add note for mcrypt_ecb --- UPGRADING | 1 + 1 file changed, 1 insertion(+) diff --git a/UPGRADING b/UPGRADING index 7d37f760002da..7aea61f642f51 100755 --- a/UPGRADING +++ b/UPGRADING @@ -93,6 +93,7 @@ PHP X.Y UPGRADE NOTES instead. - IntlDateFormatter::format() and datefmt_format() now also accept an IntlCalendar object for formatting. +- Deprecated mcrypt_ecb() made to produce E_DEPRECATED. ======================================== 5. New Functions From ad545949d027f39dad783d9cec1f4e4b58cd3680 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sat, 14 Jul 2012 21:25:55 -0700 Subject: [PATCH 1979/2394] fix for display of Jewish month names --- ext/calendar/calendar.c | 23 ++++++++++++------ ext/calendar/jewish.c | 52 ++++++++++++++++++++++++++++++++++++----- 2 files changed, 62 insertions(+), 13 deletions(-) diff --git a/ext/calendar/calendar.c b/ext/calendar/calendar.c index 7926fad6714ad..1ab1f1652ebee 100644 --- a/ext/calendar/calendar.c +++ b/ext/calendar/calendar.c @@ -140,7 +140,7 @@ const zend_function_entry calendar_functions[] = { PHP_FE(frenchtojd, arginfo_frenchtojd) PHP_FE(jddayofweek, arginfo_jddayofweek) PHP_FE(jdmonthname, arginfo_jdmonthname) - PHP_FE(easter_date, arginfo_easter_date) + PHP_FE(easter_date, arginfo_easter_date) PHP_FE(easter_days, arginfo_easter_days) PHP_FE(unixtojd, arginfo_unixtojd) PHP_FE(jdtounix, arginfo_jdtounix) @@ -199,11 +199,14 @@ static struct cal_entry_t cal_conversion_table[CAL_NUM_CALS] = { {"Julian", "CAL_JULIAN", JulianToSdn, SdnToJulian, 12, 31, MonthNameShort, MonthNameLong}, {"Jewish", "CAL_JEWISH", JewishToSdn, SdnToJewish, 13, 30, - JewishMonthName, JewishMonthName}, + JewishMonthNameLeap, JewishMonthNameLeap}, {"French", "CAL_FRENCH", FrenchToSdn, SdnToFrench, 13, 30, FrenchMonthName, FrenchMonthName} }; +#define JEWISH_MONTH_NAME(year) ((monthsPerYear[(year) % 19] == 13)?JewishMonthNameLeap:JewishMonthName) +#define JEWISH_HEB_MONTH_NAME(year) ((monthsPerYear[(year) % 19] == 13)?JewishMonthHebNameLeap:JewishMonthHebName) + /* For jddayofweek */ enum { CAL_DOW_DAYNO, CAL_DOW_SHORT, CAL_DOW_LONG }; @@ -288,7 +291,7 @@ static void _php_cal_info(int cal, zval **ret) PHP_FUNCTION(cal_info) { long cal = -1; - + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &cal) == FAILURE) { RETURN_FALSE; @@ -418,8 +421,14 @@ PHP_FUNCTION(cal_from_jd) add_assoc_string(return_value, "abbrevdayname", DayNameShort[dow], 1); add_assoc_string(return_value, "dayname", DayNameLong[dow], 1); /* month name */ - add_assoc_string(return_value, "abbrevmonth", calendar->month_name_short[month], 1); - add_assoc_string(return_value, "monthname", calendar->month_name_long[month], 1); + if(cal == CAL_JEWISH) { + /* special case for Jewish calendar */ + add_assoc_string(return_value, "abbrevmonth", JEWISH_MONTH_NAME(year)[month], 1); + add_assoc_string(return_value, "monthname", JEWISH_MONTH_NAME(year)[month], 1); + } else { + add_assoc_string(return_value, "abbrevmonth", calendar->month_name_short[month], 1); + add_assoc_string(return_value, "monthname", calendar->month_name_long[month], 1); + } } /* }}} */ @@ -608,7 +617,7 @@ PHP_FUNCTION(jdtojewish) RETURN_FALSE; } - snprintf(hebdate, sizeof(hebdate), "%s %s %s", heb_number_to_chars(day, fl, &dayp), JewishMonthHebName[month], heb_number_to_chars(year, fl, &yearp)); + snprintf(hebdate, sizeof(hebdate), "%s %s %s", heb_number_to_chars(day, fl, &dayp), JEWISH_HEB_MONTH_NAME(year)[month], heb_number_to_chars(year, fl, &yearp)); if (dayp) { efree(dayp); @@ -728,7 +737,7 @@ PHP_FUNCTION(jdmonthname) break; case CAL_MONTH_JEWISH: /* jewish month */ SdnToJewish(julday, &year, &month, &day); - monthname = JewishMonthName[month]; + monthname = JEWISH_MONTH_NAME(year)[month]; break; case CAL_MONTH_FRENCH: /* french month */ SdnToFrench(julday, &year, &month, &day); diff --git a/ext/calendar/jewish.c b/ext/calendar/jewish.c index f4dc7c35ae57c..ac256c9860605 100644 --- a/ext/calendar/jewish.c +++ b/ext/calendar/jewish.c @@ -297,9 +297,10 @@ static int yearOffset[19] = 136, 148, 160, 173, 185, 197, 210, 222 }; -char *JewishMonthName[14] = +/* names for leap (13-month) year */ +char *JewishMonthNameLeap[14] = { - "", + "", "Tishri", "Heshvan", "Kislev", @@ -315,15 +316,35 @@ char *JewishMonthName[14] = "Elul" }; -char *JewishMonthHebName[14] = +/* names for regular year */ +char *JewishMonthName[14] = { + "", + "Tishri", + "Heshvan", + "Kislev", + "Tevet", + "Shevat", "", + "Adar", + "Nisan", + "Iyyar", + "Sivan", + "Tammuz", + "Av", + "Elul" +}; + +/* names for leap (13-month) year */ +char *JewishMonthHebNameLeap[14] = +{ + "", "úùøé", "çùåï", "ëñìå", "èáú", "ùáè", - "àãø", + "'àãø ø", "'àãø á", "ðéñï", "àééø", @@ -333,6 +354,25 @@ char *JewishMonthHebName[14] = "àìåì" }; +/* names for regular year */ +char *JewishMonthHebName[14] = +{ + "", + "úùøé", + "çùåï", + "ëñìå", + "èáú", + "ùáè", + "", + "àãø", + "ðéñï", + "àééø", + "ñéåï", + "úîåæ", + "àá", + "àìåì" +}; + /************************************************************************ * Given the year within the 19 year metonic cycle and the time of a molad * (new moon) which starts that year, this routine will calculate what day @@ -587,11 +627,11 @@ void SdnToJewish( (*pMonth)--; (*pDay) += 30; } else { - *pMonth = 6; + *pMonth = 7; *pDay = inputDay - tishri1 + 207; if (*pDay > 0) return; - (*pMonth)--; + (*pMonth) -= 2; (*pDay) += 30; } if (*pDay > 0) From e1489c579389bfa820aa0f4eb20d12ef575c3afc Mon Sep 17 00:00:00 2001 From: Eitan Mosenkis Date: Sun, 15 Jul 2012 20:36:34 -0400 Subject: [PATCH 1980/2394] Update documentation to reflect fix of 54254 --- ext/calendar/jewish.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/calendar/jewish.c b/ext/calendar/jewish.c index ac256c9860605..494d065962346 100644 --- a/ext/calendar/jewish.c +++ b/ext/calendar/jewish.c @@ -85,8 +85,8 @@ * 3 Kislev 29 30 30 29 30 30 (variable) * 4 Tevet 29 29 29 29 29 29 * 5 Shevat 30 30 30 30 30 30 - * 6 Adar I 29 29 29 30 30 30 (variable) - * 7 Adar II -- -- -- 29 29 29 (optional) + * 6 Adar I -- -- -- 30 30 30 (optional) + * 7 Adar II 29 29 29 29 29 29 * 8 Nisan 30 30 30 30 30 30 * 9 Iyyar 29 29 29 29 29 29 * 10 Sivan 30 30 30 30 30 30 @@ -100,8 +100,8 @@ * have multiple possible spellings in the Roman character set. I have * chosen to use the spellings found in the Encyclopedia Judaica. * - * Adar II, the month added for leap years, is sometimes referred to as - * the 13th month, but I have chosen to assign it the number 7 to keep + * Adar I, the month added for leap years, is sometimes referred to as + * the 13th month, but I have chosen to assign it the number 6 to keep * the months in chronological order. This may not be consistent with * other numbering schemes. * From dedc8f2682b14187782d9ff230529a049ffe8079 Mon Sep 17 00:00:00 2001 From: Eitan Mosenkis Date: Thu, 19 Jul 2012 08:54:30 -0400 Subject: [PATCH 1981/2394] Add test for interoperability of jdtojewish and cal_days_in_month --- ext/calendar/tests/bug54254.phpt | 59 ++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 ext/calendar/tests/bug54254.phpt diff --git a/ext/calendar/tests/bug54254.phpt b/ext/calendar/tests/bug54254.phpt new file mode 100644 index 0000000000000..df9362320c0a6 --- /dev/null +++ b/ext/calendar/tests/bug54254.phpt @@ -0,0 +1,59 @@ +--TEST-- +Bug #54254 (cal_days_in_month incompatible with jdtojewish in non-leap-years) +--SKIPIF-- + +--FILE-- + Date: Sun, 5 Aug 2012 20:15:21 -0700 Subject: [PATCH 1982/2394] some fixes for bug#54254 --- ext/calendar/calendar.c | 4 ++-- ext/calendar/jewish.c | 4 ++-- ext/calendar/sdncal.h | 3 +++ ext/calendar/tests/jdmonthname.phpt | 4 ++-- ext/calendar/tests/jdtojewish.phpt | 8 +++++--- 5 files changed, 14 insertions(+), 9 deletions(-) diff --git a/ext/calendar/calendar.c b/ext/calendar/calendar.c index 1ab1f1652ebee..5947aabc986b9 100644 --- a/ext/calendar/calendar.c +++ b/ext/calendar/calendar.c @@ -204,8 +204,8 @@ static struct cal_entry_t cal_conversion_table[CAL_NUM_CALS] = { FrenchMonthName, FrenchMonthName} }; -#define JEWISH_MONTH_NAME(year) ((monthsPerYear[(year) % 19] == 13)?JewishMonthNameLeap:JewishMonthName) -#define JEWISH_HEB_MONTH_NAME(year) ((monthsPerYear[(year) % 19] == 13)?JewishMonthHebNameLeap:JewishMonthHebName) +#define JEWISH_MONTH_NAME(year) ((monthsPerYear[((year)-1) % 19] == 13)?JewishMonthNameLeap:JewishMonthName) +#define JEWISH_HEB_MONTH_NAME(year) ((monthsPerYear[((year)-1) % 19] == 13)?JewishMonthHebNameLeap:JewishMonthHebName) /* For jddayofweek */ enum { CAL_DOW_DAYNO, CAL_DOW_SHORT, CAL_DOW_LONG }; diff --git a/ext/calendar/jewish.c b/ext/calendar/jewish.c index 494d065962346..a5849a7d7690c 100644 --- a/ext/calendar/jewish.c +++ b/ext/calendar/jewish.c @@ -86,7 +86,7 @@ * 4 Tevet 29 29 29 29 29 29 * 5 Shevat 30 30 30 30 30 30 * 6 Adar I -- -- -- 30 30 30 (optional) - * 7 Adar II 29 29 29 29 29 29 + * 7 Adar (II) 29 29 29 29 29 29 * 8 Nisan 30 30 30 30 30 30 * 9 Iyyar 29 29 29 29 29 29 * 10 Sivan 30 30 30 30 30 30 @@ -286,7 +286,7 @@ #define AM3_11_20 ((9 * HALAKIM_PER_HOUR) + 204) #define AM9_32_43 ((15 * HALAKIM_PER_HOUR) + 589) -static int monthsPerYear[19] = +int monthsPerYear[19] = { 12, 12, 13, 12, 12, 13, 12, 13, 12, 12, 13, 12, 12, 13, 12, 12, 13, 12, 13 }; diff --git a/ext/calendar/sdncal.h b/ext/calendar/sdncal.h index 81328d1369cf5..c0463c80d45e6 100644 --- a/ext/calendar/sdncal.h +++ b/ext/calendar/sdncal.h @@ -79,7 +79,10 @@ long int JulianToSdn(int year, int month, int day); void SdnToJewish(long int sdn, int *pYear, int *pMonth, int *pDay); long int JewishToSdn(int year, int month, int day); extern char *JewishMonthName[14]; +extern char *JewishMonthNameLeap[14]; extern char *JewishMonthHebName[14]; +extern char *JewishMonthHebNameLeap[14]; +extern int monthsPerYear[19]; /* French republic calendar conversions. */ void SdnToFrench(long int sdn, int *pYear, int *pMonth, int *pDay); diff --git a/ext/calendar/tests/jdmonthname.phpt b/ext/calendar/tests/jdmonthname.phpt index d05d3c595efca..207d320162b7b 100644 --- a/ext/calendar/tests/jdmonthname.phpt +++ b/ext/calendar/tests/jdmonthname.phpt @@ -178,7 +178,7 @@ Heshvan Kislev Tevet Shevat -AdarI +Adar Nisan Iyyar Sivan @@ -279,7 +279,7 @@ Heshvan Kislev Tevet Shevat -AdarI +Adar Nisan Iyyar Sivan diff --git a/ext/calendar/tests/jdtojewish.phpt b/ext/calendar/tests/jdtojewish.phpt index 484b95749cca9..bc0ecbdd88ec2 100644 --- a/ext/calendar/tests/jdtojewish.phpt +++ b/ext/calendar/tests/jdtojewish.phpt @@ -14,10 +14,11 @@ var_dump(jdtojewish(gregoriantojd(10,28,2002))."\r\n". jdtojewish(gregoriantojd(10,8,2002),true, CAL_JEWISH_ADD_GERESHAYIM)."\r\n". jdtojewish(gregoriantojd(10,8,2002),true, CAL_JEWISH_ADD_GERESHAYIM+CAL_JEWISH_ADD_ALAFIM_GERESH)."\r\n". jdtojewish(gregoriantojd(10,8,2002),true, CAL_JEWISH_ADD_GERESHAYIM+CAL_JEWISH_ADD_ALAFIM)."\r\n". - jdtojewish(gregoriantojd(10,8,2002),true, CAL_JEWISH_ADD_GERESHAYIM+CAL_JEWISH_ADD_ALAFIM+CAL_JEWISH_ADD_ALAFIM_GERESH)."\r\n"); + jdtojewish(gregoriantojd(10,8,2002),true, CAL_JEWISH_ADD_GERESHAYIM+CAL_JEWISH_ADD_ALAFIM+CAL_JEWISH_ADD_ALAFIM_GERESH)."\r\n". + jdtojewish(gregoriantojd(3,10,2007))."\r\n"); ?> ---EXPECT-- -string(184) "2/22/5763 +--EXPECTF-- +string(%d) "2/22/5763 ëá çùåï äúùñâ ëá çùåï ä'úùñâ ëá çùåï ä àìôéí úùñâ @@ -27,4 +28,5 @@ string(184) "2/22/5763 á' çùåï ä'úùñ"â á' çùåï ä àìôéí úùñ"â á' çùåï ä' àìôéí úùñ"â +7/20/5767 " From a15459b2916b3ebbbe574f616529b31c2d9fbfe4 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 7 Aug 2012 01:17:17 -0700 Subject: [PATCH 1983/2394] text fixes from emosenkis --- ext/calendar/jewish.c | 8 ++++---- ext/calendar/tests/cal_info.phpt | 8 ++++---- ext/calendar/tests/jdmonthname.phpt | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/ext/calendar/jewish.c b/ext/calendar/jewish.c index a5849a7d7690c..9e5b0beced7ab 100644 --- a/ext/calendar/jewish.c +++ b/ext/calendar/jewish.c @@ -306,8 +306,8 @@ char *JewishMonthNameLeap[14] = "Kislev", "Tevet", "Shevat", - "AdarI", - "AdarII", + "Adar I", + "Adar II", "Nisan", "Iyyar", "Sivan", @@ -344,8 +344,8 @@ char *JewishMonthHebNameLeap[14] = "ëñìå", "èáú", "ùáè", - "'àãø ø", - "'àãø á", + "àãø à'", + "àãø á'", "ðéñï", "àééø", "ñéåï", diff --git a/ext/calendar/tests/cal_info.phpt b/ext/calendar/tests/cal_info.phpt index 2e3e612925c07..7edb4ce67ca79 100644 --- a/ext/calendar/tests/cal_info.phpt +++ b/ext/calendar/tests/cal_info.phpt @@ -100,8 +100,8 @@ Array [3] => Kislev [4] => Tevet [5] => Shevat - [6] => AdarI - [7] => AdarII + [6] => Adar I + [7] => Adar II [8] => Nisan [9] => Iyyar [10] => Sivan @@ -117,8 +117,8 @@ Array [3] => Kislev [4] => Tevet [5] => Shevat - [6] => AdarI - [7] => AdarII + [6] => Adar I + [7] => Adar II [8] => Nisan [9] => Iyyar [10] => Sivan diff --git a/ext/calendar/tests/jdmonthname.phpt b/ext/calendar/tests/jdmonthname.phpt index 207d320162b7b..07ed1161b1753 100644 --- a/ext/calendar/tests/jdmonthname.phpt +++ b/ext/calendar/tests/jdmonthname.phpt @@ -75,8 +75,8 @@ December --- mode 4 --- Tevet Shevat -AdarI -AdarII +Adar I +Adar II Nisan Iyyar Sivan From 1190bc440be0ab8ef6703dc9cb1dc4d64bf538f0 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 7 Aug 2012 01:47:50 -0700 Subject: [PATCH 1984/2394] bug #54254 --- NEWS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/NEWS b/NEWS index 56a947764f5a0..0c177ddb267e4 100644 --- a/NEWS +++ b/NEWS @@ -11,6 +11,10 @@ PHP NEWS other expressions (https://wiki.php.net/rfc/empty_isset_exprs). (Nikita Popov) +- Calendar: + . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) + (Stas, Eitan Mosenkis). + - Core: . Added boolval(). (Jille Timmermans). . Fixed bug #18556 (Engine uses locale rules to handle class names). (Stas) From 3d4169d751d443313da9f6299d1aff3d9fdc7ed0 Mon Sep 17 00:00:00 2001 From: Reeze Xia Date: Thu, 9 Aug 2012 21:43:59 +0800 Subject: [PATCH 1985/2394] Fix phpcredits() BC after remove Logo GUIDs This test was affected: ext/standard/tests/general_functions/phpcredits2.phpt see https://github.com/php/php-src/pull/132/files#diff-3 This makes constant PHP_CREDITS_FULLPAGE didn't functional anymore. --- ext/standard/credits.c | 8 ++++++++ ext/standard/info.c | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ext/standard/credits.c b/ext/standard/credits.c index 0f5d6d735119f..e87cdcad8be99 100644 --- a/ext/standard/credits.c +++ b/ext/standard/credits.c @@ -27,6 +27,10 @@ PHPAPI void php_print_credits(int flag TSRMLS_DC) /* {{{ */ { + if (!sapi_module.phpinfo_as_text && flag & PHP_CREDITS_FULLPAGE) { + php_print_info_htmlhead(TSRMLS_C); + } + if (!sapi_module.phpinfo_as_text) { PUTS("

PHP Credits

\n"); } else { @@ -119,6 +123,10 @@ PHPAPI void php_print_credits(int flag TSRMLS_DC) /* {{{ */ CREDIT_LINE("Windows Infrastructure", "Alex Schoenmaker"); php_info_print_table_end(); } + + if (!sapi_module.phpinfo_as_text && flag & PHP_CREDITS_FULLPAGE) { + PUTS("\n"); + } } /* }}} */ diff --git a/ext/standard/info.c b/ext/standard/info.c index 089f515d95b9b..beb147797d91d 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -881,7 +881,7 @@ PHPAPI void php_print_info(int flag TSRMLS_DC) if ((flag & PHP_INFO_CREDITS) && !sapi_module.phpinfo_as_text) { php_info_print_hr(); - php_print_credits(PHP_CREDITS_ALL TSRMLS_CC); + php_print_credits(PHP_CREDITS_ALL & ~PHP_CREDITS_FULLPAGE TSRMLS_CC); } if (flag & PHP_INFO_LICENSE) { From a5dfd414941953c282bb68f6b08685252ca93a1a Mon Sep 17 00:00:00 2001 From: Leigh Date: Fri, 10 Aug 2012 11:09:25 +0100 Subject: [PATCH 1986/2394] zend_make_printable_zval choses cast_object over __toString https://bugs.php.net/bug.php?id=62328 Added a check to see if the object implements a __toString magic method. This should be called instead of the cast_object method of built-in classes when defined. --- Zend/zend.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Zend/zend.c b/Zend/zend.c index 18c4f11604c9d..be30e92e7ddd7 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -258,6 +258,12 @@ ZEND_API void zend_make_printable_zval(zval *expr, zval *expr_copy, int *use_cop { TSRMLS_FETCH(); + if (Z_OBJCE_P(expr)->__tostring) { + if (zend_std_cast_object_tostring(expr, expr_copy, IS_STRING TSRMLS_CC) == SUCCESS) { + break; + } + } + if (Z_OBJ_HANDLER_P(expr, cast_object)) { zval *val; From 222ab9da1aa086a47279d29c16a8ebea514257fe Mon Sep 17 00:00:00 2001 From: Leigh Date: Fri, 10 Aug 2012 11:43:53 +0100 Subject: [PATCH 1987/2394] Test for bug 62328 --- Zend/tests/bug62328.phpt | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Zend/tests/bug62328.phpt diff --git a/Zend/tests/bug62328.phpt b/Zend/tests/bug62328.phpt new file mode 100644 index 0000000000000..c56ddc2c69f50 --- /dev/null +++ b/Zend/tests/bug62328.phpt @@ -0,0 +1,22 @@ +--TEST-- +Bug #62328 (cast_object takes precedence over __toString) +--FILE-- +__toString() . PHP_EOL; + +?> +--EXPECT-- +__toString +__toString From 32c1c5a19fab5c1471a5902a54efcd0875fe7e79 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 12 Aug 2012 12:02:02 +0800 Subject: [PATCH 1988/2394] Revert "Test for bug 62328" This reverts commit 222ab9da1aa086a47279d29c16a8ebea514257fe. --- Zend/tests/bug62328.phpt | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 Zend/tests/bug62328.phpt diff --git a/Zend/tests/bug62328.phpt b/Zend/tests/bug62328.phpt deleted file mode 100644 index c56ddc2c69f50..0000000000000 --- a/Zend/tests/bug62328.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -Bug #62328 (cast_object takes precedence over __toString) ---FILE-- -__toString() . PHP_EOL; - -?> ---EXPECT-- -__toString -__toString From 75f6c8d42cfcf856d7a12f67c3981f3ad62660e9 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 12 Aug 2012 12:02:06 +0800 Subject: [PATCH 1989/2394] Revert "zend_make_printable_zval choses cast_object over __toString" This reverts commit a5dfd414941953c282bb68f6b08685252ca93a1a. --- Zend/zend.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/Zend/zend.c b/Zend/zend.c index be30e92e7ddd7..18c4f11604c9d 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -258,12 +258,6 @@ ZEND_API void zend_make_printable_zval(zval *expr, zval *expr_copy, int *use_cop { TSRMLS_FETCH(); - if (Z_OBJCE_P(expr)->__tostring) { - if (zend_std_cast_object_tostring(expr, expr_copy, IS_STRING TSRMLS_CC) == SUCCESS) { - break; - } - } - if (Z_OBJ_HANDLER_P(expr, cast_object)) { zval *val; From 80d5ae3cea4c6fdd85789edfde0e2da721a0741b Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 13 Aug 2012 21:48:39 +0800 Subject: [PATCH 1990/2394] Implemented 'finally' keywords for php RFC: https://wiki.php.net/rfc/finally FR: https://bugs.php.net/bug.php?id=32100 and I have got some improvment ideas(performance), will implemented later. thanks --- NEWS | 1 + UPGRADING | 2 + Zend/tests/catch_finally_001.phpt | 32 + Zend/tests/catch_finally_002.phpt | 21 + Zend/tests/catch_finally_003.phpt | 40 + Zend/tests/catch_finally_004.phpt | 41 + Zend/tests/catch_finally_005.phpt | 21 + Zend/tests/catch_finally_006.phpt | 28 + Zend/tests/try_catch_finally_001.phpt | 36 + Zend/tests/try_catch_finally_002.phpt | 42 + Zend/tests/try_catch_finally_003.phpt | 38 + Zend/tests/try_catch_finally_004.phpt | 30 + Zend/tests/try_finally_001.phpt | 23 + Zend/tests/try_finally_002.phpt | 23 + Zend/tests/try_finally_003.phpt | 27 + Zend/zend_compile.c | 49 +- Zend/zend_compile.h | 6 +- Zend/zend_language_parser.y | 22 +- Zend/zend_language_scanner.c | 1299 +++++++++++++------------ Zend/zend_language_scanner.l | 4 + Zend/zend_language_scanner_defs.h | 2 +- Zend/zend_vm_def.h | 195 +++- Zend/zend_vm_execute.h | 532 +++++++++- Zend/zend_vm_execute.skl | 1 + Zend/zend_vm_opcodes.h | 1 + 25 files changed, 1830 insertions(+), 686 deletions(-) create mode 100644 Zend/tests/catch_finally_001.phpt create mode 100644 Zend/tests/catch_finally_002.phpt create mode 100644 Zend/tests/catch_finally_003.phpt create mode 100644 Zend/tests/catch_finally_004.phpt create mode 100644 Zend/tests/catch_finally_005.phpt create mode 100644 Zend/tests/catch_finally_006.phpt create mode 100644 Zend/tests/try_catch_finally_001.phpt create mode 100644 Zend/tests/try_catch_finally_002.phpt create mode 100644 Zend/tests/try_catch_finally_003.phpt create mode 100644 Zend/tests/try_catch_finally_004.phpt create mode 100644 Zend/tests/try_finally_001.phpt create mode 100644 Zend/tests/try_finally_002.phpt create mode 100644 Zend/tests/try_finally_003.phpt diff --git a/NEWS b/NEWS index 0c177ddb267e4..58eeabd37f2bc 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,7 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) . Drop Windows XP and 2003 support. (Pierre) . World domination . Improve set_exception_handler while doing reset.(Laruence) diff --git a/UPGRADING b/UPGRADING index 4fac7a88f5741..f95ab4962b176 100755 --- a/UPGRADING +++ b/UPGRADING @@ -31,6 +31,8 @@ PHP X.Y UPGRADE NOTES 2. New Features ======================================== +- Support finally keyword. (Laruence) + (wiki.php.net/rfc/finally) - Support constant array/string dereferencing. (Laruence) (https://wiki.php.net/rfc/constdereference) - Add support for using empty() on the result of function calls and diff --git a/Zend/tests/catch_finally_001.phpt b/Zend/tests/catch_finally_001.phpt new file mode 100644 index 0000000000000..2b58fa713267c --- /dev/null +++ b/Zend/tests/catch_finally_001.phpt @@ -0,0 +1,32 @@ +--TEST-- +Try catch finally +--FILE-- + +--EXPECTF-- +try +finally +end + +try +catch +finally +end diff --git a/Zend/tests/catch_finally_002.phpt b/Zend/tests/catch_finally_002.phpt new file mode 100644 index 0000000000000..5f36ae2aa8b48 --- /dev/null +++ b/Zend/tests/catch_finally_002.phpt @@ -0,0 +1,21 @@ +--TEST-- +Try catch finally return +--FILE-- + +--EXPECTF-- +try +finally +int(1) diff --git a/Zend/tests/catch_finally_003.phpt b/Zend/tests/catch_finally_003.phpt new file mode 100644 index 0000000000000..a47c6f0f2c3c5 --- /dev/null +++ b/Zend/tests/catch_finally_003.phpt @@ -0,0 +1,40 @@ +--TEST-- +Try catch finally multi-return +--FILE-- + +--EXPECTF-- +string(3) "try" +string(7) "finally" +string(7) "finally" +try +string(4) "para" diff --git a/Zend/tests/catch_finally_004.phpt b/Zend/tests/catch_finally_004.phpt new file mode 100644 index 0000000000000..be32a435c3aff --- /dev/null +++ b/Zend/tests/catch_finally_004.phpt @@ -0,0 +1,41 @@ +--TEST-- +Nesting try catch finally +--FILE-- +getMessage()); +} while ($ex = $ex->getPrevious()); +?> +--EXPECT-- +123432int(1) +string(7) "finally" +string(5) "catch" diff --git a/Zend/tests/catch_finally_005.phpt b/Zend/tests/catch_finally_005.phpt new file mode 100644 index 0000000000000..d8573bd4e28c2 --- /dev/null +++ b/Zend/tests/catch_finally_005.phpt @@ -0,0 +1,21 @@ +--TEST-- +Try catch finally with return +--FILE-- + +--EXPECTF-- +int(3) diff --git a/Zend/tests/catch_finally_006.phpt b/Zend/tests/catch_finally_006.phpt new file mode 100644 index 0000000000000..48937c40d44d2 --- /dev/null +++ b/Zend/tests/catch_finally_006.phpt @@ -0,0 +1,28 @@ +--TEST-- +Try catch finally: re-throw exception in catch block +--FILE-- +getMessage()); +} +?> +--EXPECT-- +string(4) "para" +string(7) "finally" +string(2) "ex" diff --git a/Zend/tests/try_catch_finally_001.phpt b/Zend/tests/try_catch_finally_001.phpt new file mode 100644 index 0000000000000..3d478f461aeca --- /dev/null +++ b/Zend/tests/try_catch_finally_001.phpt @@ -0,0 +1,36 @@ +--TEST-- +Try catch finally +--FILE-- + +--EXPECTF-- +1234int(1) diff --git a/Zend/tests/try_catch_finally_002.phpt b/Zend/tests/try_catch_finally_002.phpt new file mode 100644 index 0000000000000..94143f6fd1eca --- /dev/null +++ b/Zend/tests/try_catch_finally_002.phpt @@ -0,0 +1,42 @@ +--TEST-- +Try catch finally +--FILE-- + +--EXPECTF-- +123456int(7) diff --git a/Zend/tests/try_catch_finally_003.phpt b/Zend/tests/try_catch_finally_003.phpt new file mode 100644 index 0000000000000..78b37be1248d2 --- /dev/null +++ b/Zend/tests/try_catch_finally_003.phpt @@ -0,0 +1,38 @@ +--TEST-- +Try catch finally +--FILE-- + +--EXPECTF-- +1234int(4) diff --git a/Zend/tests/try_catch_finally_004.phpt b/Zend/tests/try_catch_finally_004.phpt new file mode 100644 index 0000000000000..c6946012d9c4d --- /dev/null +++ b/Zend/tests/try_catch_finally_004.phpt @@ -0,0 +1,30 @@ +--TEST-- +Try catch finally +--CREDITS-- +adoy +--FILE-- + +--EXPECTF-- +string(3) "try" +string(7) "finally" +string(8) "finally2" diff --git a/Zend/tests/try_finally_001.phpt b/Zend/tests/try_finally_001.phpt new file mode 100644 index 0000000000000..1c168da275cdd --- /dev/null +++ b/Zend/tests/try_finally_001.phpt @@ -0,0 +1,23 @@ +--TEST-- +Try finally +--FILE-- + +--EXPECTF-- +string(7) "finally" + +Fatal error: Uncaught exception 'Exception' with message 'ex' %s +Stack trace: +#0 %stry_finally_001.php(%d): foo('finally') +#1 {main} + thrown in %stry_finally_001.php on line %d + diff --git a/Zend/tests/try_finally_002.phpt b/Zend/tests/try_finally_002.phpt new file mode 100644 index 0000000000000..44676966fe259 --- /dev/null +++ b/Zend/tests/try_finally_002.phpt @@ -0,0 +1,23 @@ +--TEST-- +Try finally +--FILE-- +getMessage()); + } while ($e = $e->getPrevious()); +} +?> +--EXPECT-- +string(7) "finally" +string(3) "try" diff --git a/Zend/tests/try_finally_003.phpt b/Zend/tests/try_finally_003.phpt new file mode 100644 index 0000000000000..c5a380995ab26 --- /dev/null +++ b/Zend/tests/try_finally_003.phpt @@ -0,0 +1,27 @@ +--TEST-- +Try finally +--FILE-- + +--EXPECTF-- +1234 +Fatal error: Uncaught exception 'Exception' with message 'ex' %s +Stack trace: +#0 %stry_finally_003.php(%d): foo() +#1 {main} + thrown in %stry_finally_003.php on line %d diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index f8b8941e79546..1e995b6738a01 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2661,6 +2661,7 @@ static int zend_add_try_element(zend_uint try_op TSRMLS_DC) /* {{{ */ CG(active_op_array)->try_catch_array = erealloc(CG(active_op_array)->try_catch_array, sizeof(zend_try_catch_element)*CG(active_op_array)->last_try_catch); CG(active_op_array)->try_catch_array[try_catch_offset].try_op = try_op; + CG(active_op_array)->try_catch_array[try_catch_offset].finally_op = 0; return try_catch_offset; } /* }}} */ @@ -2677,7 +2678,7 @@ void zend_do_first_catch(znode *open_parentheses TSRMLS_DC) /* {{{ */ } /* }}} */ -void zend_initialize_try_catch_element(const znode *try_token TSRMLS_DC) /* {{{ */ +void zend_initialize_try_catch_element(znode *catch_token TSRMLS_DC) /* {{{ */ { int jmp_op_number = get_next_op_number(CG(active_op_array)); zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); @@ -2694,7 +2695,7 @@ void zend_initialize_try_catch_element(const znode *try_token TSRMLS_DC) /* {{{ zend_stack_top(&CG(bp_stack), (void **) &jmp_list_ptr); zend_llist_add_element(jmp_list_ptr, &jmp_op_number); - zend_add_catch_element(try_token->u.op.opline_num, get_next_op_number(CG(active_op_array)) TSRMLS_CC); + catch_token->EA = get_next_op_number(CG(active_op_array)); } /* }}} */ @@ -2720,7 +2721,11 @@ void zend_do_try(znode *try_token TSRMLS_DC) /* {{{ */ } /* }}} */ -void zend_do_begin_catch(znode *try_token, znode *class_name, znode *catch_var, znode *first_catch TSRMLS_DC) /* {{{ */ +void zend_do_finally(znode *finally_token TSRMLS_DC) /* {{{ */ { + finally_token->u.op.opline_num = get_next_op_number(CG(active_op_array)); +} /* }}} */ + +void zend_do_begin_catch(znode *catch_token, znode *class_name, znode *catch_var, znode *first_catch TSRMLS_DC) /* {{{ */ { long catch_op_number; zend_op *opline; @@ -2748,11 +2753,11 @@ void zend_do_begin_catch(znode *try_token, znode *class_name, znode *catch_var, Z_STRVAL(catch_var->u.constant) = (char*)CG(active_op_array)->vars[opline->op2.var].name; opline->result.num = 0; /* 1 means it's the last catch in the block */ - try_token->u.op.opline_num = catch_op_number; + catch_token->u.op.opline_num = catch_op_number; } /* }}} */ -void zend_do_end_catch(const znode *try_token TSRMLS_DC) /* {{{ */ +void zend_do_end_catch(znode *catch_token TSRMLS_DC) /* {{{ */ { int jmp_op_number = get_next_op_number(CG(active_op_array)); zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); @@ -2766,7 +2771,39 @@ void zend_do_end_catch(const znode *try_token TSRMLS_DC) /* {{{ */ zend_stack_top(&CG(bp_stack), (void **) &jmp_list_ptr); zend_llist_add_element(jmp_list_ptr, &jmp_op_number); - CG(active_op_array)->opcodes[try_token->u.op.opline_num].extended_value = get_next_op_number(CG(active_op_array)); + CG(active_op_array)->opcodes[catch_token->u.op.opline_num].extended_value = get_next_op_number(CG(active_op_array)); +} +/* }}} */ + +void zend_do_bind_catch(znode *try_token, znode *catch_token TSRMLS_DC) /* {{{ */ { + if (catch_token->op_type != IS_UNUSED) { + zend_add_catch_element(try_token->u.op.opline_num, catch_token->EA TSRMLS_CC); + } +} +/* }}} */ + + +void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_token TSRMLS_DC) /* {{{ */ +{ + zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); + + if (catch_token->op_type == IS_UNUSED && finally_token->op_type == IS_UNUSED) { + zend_error(E_COMPILE_ERROR, "Cannot use try without catch or finally"); + } + if (finally_token->op_type != IS_UNUSED) { + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; + //try_token->u.op.opline_num = catch_token->u.op.opline_num; + + opline->opcode = ZEND_LEAVE; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + } + if (catch_token->op_type == IS_UNUSED) { + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].catch_op = 0; + } //else { + // try_token->u.op.opline_num = catch_token->u.op.opline_num; + //} + } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index f164122785b8b..f604de4699cf5 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -132,6 +132,7 @@ typedef struct _zend_label { typedef struct _zend_try_catch_element { zend_uint try_op; zend_uint catch_op; /* ketchup! */ + zend_uint finally_op; } zend_try_catch_element; #if SIZEOF_LONG == 8 @@ -381,6 +382,7 @@ struct _zend_execute_data { zend_class_entry *current_called_scope; zval *current_this; zval *current_object; + zend_bool leaving; }; #define EX(element) execute_data.element @@ -496,7 +498,7 @@ void zend_do_fetch_lexical_variable(znode *varname, zend_bool is_ref TSRMLS_DC); void zend_do_try(znode *try_token TSRMLS_DC); void zend_do_begin_catch(znode *try_token, znode *catch_class, znode *catch_var, znode *first_catch TSRMLS_DC); -void zend_do_end_catch(const znode *try_token TSRMLS_DC); +void zend_do_end_catch(znode *catch_token TSRMLS_DC); void zend_do_throw(const znode *expr TSRMLS_DC); ZEND_API int do_bind_function(const zend_op_array *op_array, zend_op *opline, HashTable *function_table, zend_bool compile_time); @@ -662,7 +664,7 @@ void print_op_array(zend_op_array *op_array, int optimizations); ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC); zend_brk_cont_element *get_next_brk_cont_element(zend_op_array *op_array); void zend_do_first_catch(znode *open_parentheses TSRMLS_DC); -void zend_initialize_try_catch_element(const znode *try_token TSRMLS_DC); +void zend_initialize_try_catch_element(znode *catch_token TSRMLS_DC); void zend_do_mark_last_catch(const znode *first_catch, const znode *last_additional_catch TSRMLS_DC); ZEND_API zend_bool zend_is_compiling(TSRMLS_D); ZEND_API char *zend_make_compiled_string_description(const char *name TSRMLS_DC); diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index c88e9a7c004e8..80760a5a54305 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -160,6 +160,7 @@ static YYSIZE_T zend_yytnamerr(char*, const char*); %token T_RETURN "return (T_RETURN)" %token T_TRY "try (T_TRY)" %token T_CATCH "catch (T_CATCH)" +%token T_FINALLY "finally (T_FINALLY)" %token T_THROW "throw (T_THROW)" %token T_USE "use (T_USE)" %token T_INSTEADOF "insteadof (T_INSTEADOF)" @@ -314,15 +315,24 @@ unticked_statement: | T_DECLARE { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); zend_do_declare_begin(TSRMLS_C); } '(' declare_list ')' declare_statement { zend_do_declare_end(&$1 TSRMLS_CC); } | ';' /* empty statement */ | T_TRY { zend_do_try(&$1 TSRMLS_CC); } '{' inner_statement_list '}' - T_CATCH '(' { zend_initialize_try_catch_element(&$1 TSRMLS_CC); } - fully_qualified_class_name { zend_do_first_catch(&$7 TSRMLS_CC); } - T_VARIABLE ')' { zend_do_begin_catch(&$1, &$9, &$11, &$7 TSRMLS_CC); } - '{' inner_statement_list '}' { zend_do_end_catch(&$1 TSRMLS_CC); } - additional_catches { zend_do_mark_last_catch(&$7, &$18 TSRMLS_CC); } + catch_statement { zend_do_bind_catch(&$1, &$6 TSRMLS_CC); } + finally_statement { zend_do_end_finally(&$1, &$6, &$8 TSRMLS_CC); } | T_THROW expr ';' { zend_do_throw(&$2 TSRMLS_CC); } | T_GOTO T_STRING ';' { zend_do_goto(&$2 TSRMLS_CC); } ; +catch_statement: + /* empty */ { $$.op_type = IS_UNUSED; } + | T_CATCH '(' { zend_initialize_try_catch_element(&$1 TSRMLS_CC); } + fully_qualified_class_name { zend_do_first_catch(&$2 TSRMLS_CC); } + T_VARIABLE ')' { zend_do_begin_catch(&$1, &$4, &$6, &$2 TSRMLS_CC); } + '{' inner_statement_list '}' { zend_do_end_catch(&$1 TSRMLS_CC); } + additional_catches { zend_do_mark_last_catch(&$2, &$13 TSRMLS_CC); $$ = $1;} + +finally_statement: + /* empty */ { $$.op_type = IS_UNUSED; } + | T_FINALLY { zend_do_finally(&$1 TSRMLS_CC); } '{' inner_statement_list '}' { $$ = $1; } +; additional_catches: non_empty_additional_catches { $$ = $1; } @@ -334,12 +344,10 @@ non_empty_additional_catches: | non_empty_additional_catches additional_catch { $$ = $2; } ; - additional_catch: T_CATCH '(' fully_qualified_class_name { $$.u.op.opline_num = get_next_op_number(CG(active_op_array)); } T_VARIABLE ')' { zend_do_begin_catch(&$1, &$3, &$5, NULL TSRMLS_CC); } '{' inner_statement_list '}' { zend_do_end_catch(&$1 TSRMLS_CC); } ; - unset_variables: unset_variable | unset_variables ',' unset_variable diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 0bfbac99750e9..f4289c3800026 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon Apr 30 15:56:25 2012 */ +/* Generated by re2c 0.13.5 on Tue Jul 24 17:16:42 2012 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ @@ -1097,7 +1097,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy3: YYDEBUG(3, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1791 "Zend/zend_language_scanner.l" +#line 1795 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1175,7 +1175,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy6: YYDEBUG(6, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1779 "Zend/zend_language_scanner.l" +#line 1783 "Zend/zend_language_scanner.l" { if (CG(short_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1194,7 +1194,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy43; YYDEBUG(8, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1756 "Zend/zend_language_scanner.l" +#line 1760 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1392,7 +1392,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(38, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1716 "Zend/zend_language_scanner.l" +#line 1720 "Zend/zend_language_scanner.l" { YYCTYPE *bracket = (YYCTYPE*)zend_memrchr(yytext, '<', yyleng - (sizeof("script language=php>") - 1)); @@ -1436,7 +1436,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(44, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1734 "Zend/zend_language_scanner.l" +#line 1738 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { zendlval->value.str.val = yytext; /* no copying - intentional */ @@ -1454,7 +1454,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(46, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1747 "Zend/zend_language_scanner.l" +#line 1751 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1489,7 +1489,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy51: YYDEBUG(51, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1769 "Zend/zend_language_scanner.l" +#line 1773 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -1569,7 +1569,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy56: YYDEBUG(56, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2242 "Zend/zend_language_scanner.l" +#line 2246 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -1621,7 +1621,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(59, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2186 "Zend/zend_language_scanner.l" +#line 2190 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '`'; @@ -1636,7 +1636,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(62, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2173 "Zend/zend_language_scanner.l" +#line 2177 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1659,7 +1659,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy65: YYDEBUG(65, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1873 "Zend/zend_language_scanner.l" +#line 1877 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1671,7 +1671,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(67, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1449 "Zend/zend_language_scanner.l" +#line 1453 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -1690,7 +1690,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(71, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1865 "Zend/zend_language_scanner.l" +#line 1869 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1716,7 +1716,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(74, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1855 "Zend/zend_language_scanner.l" +#line 1859 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1792,7 +1792,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy78: YYDEBUG(78, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2192 "Zend/zend_language_scanner.l" +#line 2196 "Zend/zend_language_scanner.l" { if (GET_DOUBLE_QUOTES_SCANNED_LENGTH()) { YYCURSOR += GET_DOUBLE_QUOTES_SCANNED_LENGTH() - 1; @@ -1852,7 +1852,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(81, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2181 "Zend/zend_language_scanner.l" +#line 2185 "Zend/zend_language_scanner.l" { BEGIN(ST_IN_SCRIPTING); return '"'; @@ -1867,7 +1867,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(84, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2173 "Zend/zend_language_scanner.l" +#line 2177 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -1890,7 +1890,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy87: YYDEBUG(87, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1873 "Zend/zend_language_scanner.l" +#line 1877 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -1902,7 +1902,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(89, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1449 "Zend/zend_language_scanner.l" +#line 1453 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -1921,7 +1921,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(93, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1865 "Zend/zend_language_scanner.l" +#line 1869 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -1947,7 +1947,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(96, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1855 "Zend/zend_language_scanner.l" +#line 1859 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -1966,7 +1966,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(100, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2160 "Zend/zend_language_scanner.l" +#line 2164 "Zend/zend_language_scanner.l" { YYCURSOR += CG(heredoc_len) - 1; yyleng = CG(heredoc_len); @@ -2040,7 +2040,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy104: YYDEBUG(104, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2284 "Zend/zend_language_scanner.l" +#line 2288 "Zend/zend_language_scanner.l" { int newline = 0; @@ -2126,7 +2126,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(108, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2173 "Zend/zend_language_scanner.l" +#line 2177 "Zend/zend_language_scanner.l" { zendlval->value.lval = (long) '{'; yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); @@ -2149,7 +2149,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy111: YYDEBUG(111, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1873 "Zend/zend_language_scanner.l" +#line 1877 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -2161,7 +2161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(113, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1449 "Zend/zend_language_scanner.l" +#line 1453 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_VARNAME TSRMLS_CC); return T_DOLLAR_OPEN_CURLY_BRACES; @@ -2180,7 +2180,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(117, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1865 "Zend/zend_language_scanner.l" +#line 1869 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); yy_push_state(ST_VAR_OFFSET TSRMLS_CC); @@ -2206,7 +2206,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(120, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1855 "Zend/zend_language_scanner.l" +#line 1859 "Zend/zend_language_scanner.l" { yyless(yyleng - 3); yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); @@ -2379,23 +2379,23 @@ int lex_scan(zval *zendlval TSRMLS_DC) YYDEBUG(-1, yych); switch ((yych = *YYCURSOR)) { case 'C': - case 'c': goto yy726; + case 'c': goto yy729; case 'L': - case 'l': goto yy727; + case 'l': goto yy730; case 'M': - case 'm': goto yy728; + case 'm': goto yy731; case 'N': - case 'n': goto yy729; + case 'n': goto yy732; case 'V': - case 'v': goto yy730; + case 'v': goto yy733; case 'X': - case 'x': goto yy731; + case 'x': goto yy734; default: goto yy186; } yy124: YYDEBUG(124, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1896 "Zend/zend_language_scanner.l" +#line 1900 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; @@ -2407,20 +2407,20 @@ int lex_scan(zval *zendlval TSRMLS_DC) yych = *++YYCURSOR; if (yych <= 'O') { if (yych <= 'H') { - if (yych == 'E') goto yy708; + if (yych == 'E') goto yy711; goto yy186; } else { - if (yych <= 'I') goto yy709; + if (yych <= 'I') goto yy712; if (yych <= 'N') goto yy186; - goto yy710; + goto yy713; } } else { if (yych <= 'h') { - if (yych == 'e') goto yy708; + if (yych == 'e') goto yy711; goto yy186; } else { - if (yych <= 'i') goto yy709; - if (yych == 'o') goto yy710; + if (yych <= 'i') goto yy712; + if (yych == 'o') goto yy713; goto yy186; } } @@ -2627,7 +2627,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy138: YYDEBUG(138, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1438 "Zend/zend_language_scanner.l" +#line 1442 "Zend/zend_language_scanner.l" { return yytext[0]; } @@ -2640,7 +2640,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy140: YYDEBUG(140, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1169 "Zend/zend_language_scanner.l" +#line 1173 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -2659,7 +2659,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(143, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1198 "Zend/zend_language_scanner.l" +#line 1202 "Zend/zend_language_scanner.l" { return T_NS_SEPARATOR; } @@ -2891,7 +2891,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(168, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1443 "Zend/zend_language_scanner.l" +#line 1447 "Zend/zend_language_scanner.l" { yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return '{'; @@ -2902,7 +2902,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(170, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1455 "Zend/zend_language_scanner.l" +#line 1459 "Zend/zend_language_scanner.l" { RESET_DOC_COMMENT(); if (!zend_stack_is_empty(&SCNG(state_stack))) { @@ -2938,7 +2938,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy172: YYDEBUG(172, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1506 "Zend/zend_language_scanner.l" +#line 1510 "Zend/zend_language_scanner.l" { if (yyleng < MAX_LENGTH_OF_LONG - 1) { /* Won't overflow */ zendlval->value.lval = strtol(yytext, NULL, 0); @@ -2987,7 +2987,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy176: YYDEBUG(176, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1903 "Zend/zend_language_scanner.l" +#line 1907 "Zend/zend_language_scanner.l" { while (YYCURSOR < YYLIMIT) { switch (*YYCURSOR++) { @@ -3028,7 +3028,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy178: YYDEBUG(178, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1994 "Zend/zend_language_scanner.l" +#line 1998 "Zend/zend_language_scanner.l" { register char *s, *t; char *end; @@ -3103,7 +3103,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy180: YYDEBUG(180, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2063 "Zend/zend_language_scanner.l" +#line 2067 "Zend/zend_language_scanner.l" { int bprefix = (yytext[0] != '"') ? 1 : 0; @@ -3150,7 +3150,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(182, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2154 "Zend/zend_language_scanner.l" +#line 2158 "Zend/zend_language_scanner.l" { BEGIN(ST_BACKQUOTE); return '`'; @@ -3161,7 +3161,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(184, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2412 "Zend/zend_language_scanner.l" +#line 2416 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -3197,7 +3197,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy189: YYDEBUG(189, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1571 "Zend/zend_language_scanner.l" +#line 1575 "Zend/zend_language_scanner.l" { zendlval->value.dval = zend_strtod(yytext, NULL); zendlval->type = IS_DOUBLE; @@ -3295,7 +3295,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(201, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1481 "Zend/zend_language_scanner.l" +#line 1485 "Zend/zend_language_scanner.l" { char *bin = yytext + 2; /* Skip "0b" */ int len = yyleng - 2; @@ -3332,7 +3332,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(204, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1527 "Zend/zend_language_scanner.l" +#line 1531 "Zend/zend_language_scanner.l" { char *hex = yytext + 2; /* Skip "0x" */ int len = yyleng - 2; @@ -3366,7 +3366,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy206: YYDEBUG(206, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1971 "Zend/zend_language_scanner.l" +#line 1975 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -3408,7 +3408,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy211: YYDEBUG(211, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1873 "Zend/zend_language_scanner.l" +#line 1877 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; @@ -3428,7 +3428,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(214, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1426 "Zend/zend_language_scanner.l" +#line 1430 "Zend/zend_language_scanner.l" { return T_LOGICAL_XOR; } @@ -3441,7 +3441,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(216, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1418 "Zend/zend_language_scanner.l" +#line 1422 "Zend/zend_language_scanner.l" { return T_LOGICAL_OR; } @@ -3451,7 +3451,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(218, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1406 "Zend/zend_language_scanner.l" +#line 1410 "Zend/zend_language_scanner.l" { return T_XOR_EQUAL; } @@ -3461,7 +3461,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(220, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1410 "Zend/zend_language_scanner.l" +#line 1414 "Zend/zend_language_scanner.l" { return T_BOOLEAN_OR; } @@ -3471,7 +3471,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(222, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1402 "Zend/zend_language_scanner.l" +#line 1406 "Zend/zend_language_scanner.l" { return T_OR_EQUAL; } @@ -3481,7 +3481,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(224, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1414 "Zend/zend_language_scanner.l" +#line 1418 "Zend/zend_language_scanner.l" { return T_BOOLEAN_AND; } @@ -3491,7 +3491,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(226, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1398 "Zend/zend_language_scanner.l" +#line 1402 "Zend/zend_language_scanner.l" { return T_AND_EQUAL; } @@ -3504,7 +3504,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy228: YYDEBUG(228, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1980 "Zend/zend_language_scanner.l" +#line 1984 "Zend/zend_language_scanner.l" { if (CG(asp_tags)) { BEGIN(INITIAL); @@ -3523,7 +3523,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(230, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1386 "Zend/zend_language_scanner.l" +#line 1390 "Zend/zend_language_scanner.l" { return T_MOD_EQUAL; } @@ -3558,7 +3558,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(236, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1382 "Zend/zend_language_scanner.l" +#line 1386 "Zend/zend_language_scanner.l" { return T_CONCAT_EQUAL; } @@ -3571,7 +3571,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy238: YYDEBUG(238, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1937 "Zend/zend_language_scanner.l" +#line 1941 "Zend/zend_language_scanner.l" { int doc_com; @@ -3615,7 +3615,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(241, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1378 "Zend/zend_language_scanner.l" +#line 1382 "Zend/zend_language_scanner.l" { return T_DIV_EQUAL; } @@ -3642,7 +3642,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(246, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1374 "Zend/zend_language_scanner.l" +#line 1378 "Zend/zend_language_scanner.l" { return T_MUL_EQUAL; } @@ -3653,7 +3653,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy251; YYDEBUG(248, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1434 "Zend/zend_language_scanner.l" +#line 1438 "Zend/zend_language_scanner.l" { return T_SR; } @@ -3663,7 +3663,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(250, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1362 "Zend/zend_language_scanner.l" +#line 1366 "Zend/zend_language_scanner.l" { return T_IS_GREATER_OR_EQUAL; } @@ -3673,7 +3673,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(252, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1394 "Zend/zend_language_scanner.l" +#line 1398 "Zend/zend_language_scanner.l" { return T_SR_EQUAL; } @@ -3688,7 +3688,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy254: YYDEBUG(254, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1430 "Zend/zend_language_scanner.l" +#line 1434 "Zend/zend_language_scanner.l" { return T_SL; } @@ -3704,7 +3704,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(257, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1358 "Zend/zend_language_scanner.l" +#line 1362 "Zend/zend_language_scanner.l" { return T_IS_SMALLER_OR_EQUAL; } @@ -3715,7 +3715,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy259: YYDEBUG(259, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1354 "Zend/zend_language_scanner.l" +#line 1358 "Zend/zend_language_scanner.l" { return T_IS_NOT_EQUAL; } @@ -3770,7 +3770,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(268, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1390 "Zend/zend_language_scanner.l" +#line 1394 "Zend/zend_language_scanner.l" { return T_SL_EQUAL; } @@ -3879,7 +3879,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy279: YYDEBUG(279, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2105 "Zend/zend_language_scanner.l" +#line 2109 "Zend/zend_language_scanner.l" { char *s; int bprefix = (yytext[0] != '<') ? 1 : 0; @@ -3967,7 +3967,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(285, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1346 "Zend/zend_language_scanner.l" +#line 1350 "Zend/zend_language_scanner.l" { return T_IS_NOT_IDENTICAL; } @@ -3977,7 +3977,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(287, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1366 "Zend/zend_language_scanner.l" +#line 1370 "Zend/zend_language_scanner.l" { return T_PLUS_EQUAL; } @@ -3987,7 +3987,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(289, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1334 "Zend/zend_language_scanner.l" +#line 1338 "Zend/zend_language_scanner.l" { return T_INC; } @@ -4010,7 +4010,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(293, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1322 "Zend/zend_language_scanner.l" +#line 1326 "Zend/zend_language_scanner.l" { return T_LIST; } @@ -4021,7 +4021,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) if ((yych = *YYCURSOR) == '=') goto yy298; YYDEBUG(295, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1350 "Zend/zend_language_scanner.l" +#line 1354 "Zend/zend_language_scanner.l" { return T_IS_EQUAL; } @@ -4031,7 +4031,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(297, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1318 "Zend/zend_language_scanner.l" +#line 1322 "Zend/zend_language_scanner.l" { return T_DOUBLE_ARROW; } @@ -4041,7 +4041,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(299, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1342 "Zend/zend_language_scanner.l" +#line 1346 "Zend/zend_language_scanner.l" { return T_IS_IDENTICAL; } @@ -4175,7 +4175,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(319, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1706 "Zend/zend_language_scanner.l" +#line 1710 "Zend/zend_language_scanner.l" { if (CG(current_namespace)) { *zendlval = *CG(current_namespace); @@ -4205,7 +4205,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(324, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1679 "Zend/zend_language_scanner.l" +#line 1683 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); const size_t filename_len = strlen(filename); @@ -4257,7 +4257,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(330, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1661 "Zend/zend_language_scanner.l" +#line 1665 "Zend/zend_language_scanner.l" { zendlval->value.lval = CG(zend_lineno); zendlval->type = IS_LONG; @@ -4298,7 +4298,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(338, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1640 "Zend/zend_language_scanner.l" +#line 1644 "Zend/zend_language_scanner.l" { const char *class_name = CG(active_class_entry) ? CG(active_class_entry)->name : NULL; const char *func_name = CG(active_op_array)? CG(active_op_array)->function_name : NULL; @@ -4370,7 +4370,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(349, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1624 "Zend/zend_language_scanner.l" +#line 1628 "Zend/zend_language_scanner.l" { const char *func_name = NULL; @@ -4406,7 +4406,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(354, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1667 "Zend/zend_language_scanner.l" +#line 1671 "Zend/zend_language_scanner.l" { char *filename = zend_get_compiled_filename(TSRMLS_C); @@ -4448,7 +4448,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(361, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1604 "Zend/zend_language_scanner.l" +#line 1608 "Zend/zend_language_scanner.l" { const char *trait_name = NULL; @@ -4498,7 +4498,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(368, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1577 "Zend/zend_language_scanner.l" +#line 1581 "Zend/zend_language_scanner.l" { const char *class_name = NULL; @@ -4587,7 +4587,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(381, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1286 "Zend/zend_language_scanner.l" +#line 1290 "Zend/zend_language_scanner.l" { return T_HALT_COMPILER; } @@ -4611,7 +4611,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(385, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1266 "Zend/zend_language_scanner.l" +#line 1270 "Zend/zend_language_scanner.l" { return T_USE; } @@ -4634,7 +4634,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(389, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1314 "Zend/zend_language_scanner.l" +#line 1318 "Zend/zend_language_scanner.l" { return T_UNSET; } @@ -4810,7 +4810,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(407, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1214 "Zend/zend_language_scanner.l" +#line 1218 "Zend/zend_language_scanner.l" { return T_INT_CAST; } @@ -4858,7 +4858,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(416, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1218 "Zend/zend_language_scanner.l" +#line 1222 "Zend/zend_language_scanner.l" { return T_DOUBLE_CAST; } @@ -4932,7 +4932,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(430, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1222 "Zend/zend_language_scanner.l" +#line 1226 "Zend/zend_language_scanner.l" { return T_STRING_CAST; } @@ -4969,7 +4969,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(437, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1226 "Zend/zend_language_scanner.l" +#line 1230 "Zend/zend_language_scanner.l" { return T_ARRAY_CAST; } @@ -5011,7 +5011,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(445, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1230 "Zend/zend_language_scanner.l" +#line 1234 "Zend/zend_language_scanner.l" { return T_OBJECT_CAST; } @@ -5056,7 +5056,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(453, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1234 "Zend/zend_language_scanner.l" +#line 1238 "Zend/zend_language_scanner.l" { return T_BOOL_CAST; } @@ -5120,7 +5120,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(465, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1238 "Zend/zend_language_scanner.l" +#line 1242 "Zend/zend_language_scanner.l" { return T_UNSET_CAST; } @@ -5138,7 +5138,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(468, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1210 "Zend/zend_language_scanner.l" +#line 1214 "Zend/zend_language_scanner.l" { return T_VAR; } @@ -5162,7 +5162,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(472, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1202 "Zend/zend_language_scanner.l" +#line 1206 "Zend/zend_language_scanner.l" { return T_NEW; } @@ -5205,7 +5205,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(480, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1262 "Zend/zend_language_scanner.l" +#line 1266 "Zend/zend_language_scanner.l" { return T_NAMESPACE; } @@ -5215,7 +5215,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(482, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1194 "Zend/zend_language_scanner.l" +#line 1198 "Zend/zend_language_scanner.l" { return T_PAAMAYIM_NEKUDOTAYIM; } @@ -5241,7 +5241,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(486, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1370 "Zend/zend_language_scanner.l" +#line 1374 "Zend/zend_language_scanner.l" { return T_MINUS_EQUAL; } @@ -5251,7 +5251,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(488, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1338 "Zend/zend_language_scanner.l" +#line 1342 "Zend/zend_language_scanner.l" { return T_DEC; } @@ -5261,7 +5261,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) ++YYCURSOR; YYDEBUG(490, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1164 "Zend/zend_language_scanner.l" +#line 1168 "Zend/zend_language_scanner.l" { yy_push_state(ST_LOOKING_FOR_PROPERTY TSRMLS_CC); return T_OBJECT_OPERATOR; @@ -5311,7 +5311,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(497, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1310 "Zend/zend_language_scanner.l" +#line 1314 "Zend/zend_language_scanner.l" { return T_PUBLIC; } @@ -5370,7 +5370,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(506, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1306 "Zend/zend_language_scanner.l" +#line 1310 "Zend/zend_language_scanner.l" { return T_PROTECTED; } @@ -5404,7 +5404,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(512, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1302 "Zend/zend_language_scanner.l" +#line 1306 "Zend/zend_language_scanner.l" { return T_PRIVATE; } @@ -5417,7 +5417,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(514, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1140 "Zend/zend_language_scanner.l" +#line 1144 "Zend/zend_language_scanner.l" { return T_PRINT; } @@ -5446,7 +5446,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(519, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1132 "Zend/zend_language_scanner.l" +#line 1136 "Zend/zend_language_scanner.l" { return T_GOTO; } @@ -5474,7 +5474,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(524, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1274 "Zend/zend_language_scanner.l" +#line 1278 "Zend/zend_language_scanner.l" { return T_GLOBAL; } @@ -5515,7 +5515,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(532, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1124 "Zend/zend_language_scanner.l" +#line 1128 "Zend/zend_language_scanner.l" { return T_BREAK; } @@ -5559,7 +5559,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(540, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1108 "Zend/zend_language_scanner.l" +#line 1112 "Zend/zend_language_scanner.l" { return T_SWITCH; } @@ -5587,7 +5587,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(545, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1290 "Zend/zend_language_scanner.l" +#line 1294 "Zend/zend_language_scanner.l" { return T_STATIC; } @@ -5618,7 +5618,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(550, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1104 "Zend/zend_language_scanner.l" +#line 1108 "Zend/zend_language_scanner.l" { return T_AS; } @@ -5641,7 +5641,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(554, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1326 "Zend/zend_language_scanner.l" +#line 1330 "Zend/zend_language_scanner.l" { return T_ARRAY; } @@ -5654,7 +5654,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(556, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1422 "Zend/zend_language_scanner.l" +#line 1426 "Zend/zend_language_scanner.l" { return T_LOGICAL_AND; } @@ -5692,7 +5692,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(563, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1294 "Zend/zend_language_scanner.l" +#line 1298 "Zend/zend_language_scanner.l" { return T_ABSTRACT; } @@ -5720,7 +5720,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(568, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1064 "Zend/zend_language_scanner.l" +#line 1068 "Zend/zend_language_scanner.l" { return T_WHILE; } @@ -5733,7 +5733,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(570, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1048 "Zend/zend_language_scanner.l" +#line 1052 "Zend/zend_language_scanner.l" { return T_IF; } @@ -5789,7 +5789,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(577, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1278 "Zend/zend_language_scanner.l" +#line 1282 "Zend/zend_language_scanner.l" { return T_ISSET; } @@ -5847,7 +5847,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy585: YYDEBUG(585, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1246 "Zend/zend_language_scanner.l" +#line 1250 "Zend/zend_language_scanner.l" { return T_INCLUDE; } @@ -5880,7 +5880,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(591, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1250 "Zend/zend_language_scanner.l" +#line 1254 "Zend/zend_language_scanner.l" { return T_INCLUDE_ONCE; } @@ -5918,7 +5918,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(598, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1148 "Zend/zend_language_scanner.l" +#line 1152 "Zend/zend_language_scanner.l" { return T_INTERFACE; } @@ -5972,7 +5972,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(606, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1270 "Zend/zend_language_scanner.l" +#line 1274 "Zend/zend_language_scanner.l" { return T_INSTEADOF; } @@ -6005,7 +6005,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(612, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1100 "Zend/zend_language_scanner.l" +#line 1104 "Zend/zend_language_scanner.l" { return T_INSTANCEOF; } @@ -6053,7 +6053,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(621, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1160 "Zend/zend_language_scanner.l" +#line 1164 "Zend/zend_language_scanner.l" { return T_IMPLEMENTS; } @@ -6108,7 +6108,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(629, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1152 "Zend/zend_language_scanner.l" +#line 1156 "Zend/zend_language_scanner.l" { return T_TRAIT; } @@ -6131,7 +6131,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(633, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1044 "Zend/zend_language_scanner.l" +#line 1048 "Zend/zend_language_scanner.l" { return T_THROW; } @@ -6196,7 +6196,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy641: YYDEBUG(641, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1254 "Zend/zend_language_scanner.l" +#line 1258 "Zend/zend_language_scanner.l" { return T_REQUIRE; } @@ -6229,7 +6229,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(647, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1258 "Zend/zend_language_scanner.l" +#line 1262 "Zend/zend_language_scanner.l" { return T_REQUIRE_ONCE; } @@ -6346,7 +6346,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(662, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1128 "Zend/zend_language_scanner.l" +#line 1132 "Zend/zend_language_scanner.l" { return T_CONTINUE; } @@ -6388,7 +6388,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(669, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1206 "Zend/zend_language_scanner.l" +#line 1210 "Zend/zend_language_scanner.l" { return T_CLONE; } @@ -6406,7 +6406,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(672, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1144 "Zend/zend_language_scanner.l" +#line 1148 "Zend/zend_language_scanner.l" { return T_CLASS; } @@ -6456,7 +6456,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(681, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1330 "Zend/zend_language_scanner.l" +#line 1334 "Zend/zend_language_scanner.l" { return T_CALLABLE; } @@ -6469,7 +6469,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(683, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1116 "Zend/zend_language_scanner.l" +#line 1120 "Zend/zend_language_scanner.l" { return T_CASE; } @@ -6570,7 +6570,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy698: YYDEBUG(698, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1076 "Zend/zend_language_scanner.l" +#line 1080 "Zend/zend_language_scanner.l" { return T_FOR; } @@ -6598,7 +6598,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) } YYDEBUG(703, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1084 "Zend/zend_language_scanner.l" +#line 1088 "Zend/zend_language_scanner.l" { return T_FOREACH; } @@ -6616,557 +6616,590 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy706: YYDEBUG(706, *YYCURSOR); ++YYCURSOR; - if (yybm[0+(yych = *YYCURSOR)] & 4) { - goto yy185; + if ((yych = *YYCURSOR) <= '^') { + if (yych <= '@') { + if (yych <= '/') goto yy707; + if (yych <= '9') goto yy185; + } else { + if (yych == 'L') goto yy708; + if (yych <= 'Z') goto yy185; + } + } else { + if (yych <= 'k') { + if (yych != '`') goto yy185; + } else { + if (yych <= 'l') goto yy708; + if (yych <= 'z') goto yy185; + if (yych >= 0x7F) goto yy185; + } } +yy707: YYDEBUG(707, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1298 "Zend/zend_language_scanner.l" +#line 1302 "Zend/zend_language_scanner.l" { return T_FINAL; } -#line 6629 "Zend/zend_language_scanner.c" +#line 6644 "Zend/zend_language_scanner.c" yy708: YYDEBUG(708, *YYCURSOR); yych = *++YYCURSOR; + if (yych == 'Y') goto yy709; + if (yych != 'y') goto yy186; +yy709: + YYDEBUG(709, *YYCURSOR); + ++YYCURSOR; + if (yybm[0+(yych = *YYCURSOR)] & 4) { + goto yy185; + } + YYDEBUG(710, *YYCURSOR); + yyleng = YYCURSOR - SCNG(yy_text); +#line 1044 "Zend/zend_language_scanner.l" + { + return T_FINALLY; +} +#line 6662 "Zend/zend_language_scanner.c" +yy711: + YYDEBUG(711, *YYCURSOR); + yych = *++YYCURSOR; if (yych <= 'F') { - if (yych == 'C') goto yy714; + if (yych == 'C') goto yy717; if (yych <= 'E') goto yy186; - goto yy715; + goto yy718; } else { if (yych <= 'c') { if (yych <= 'b') goto yy186; - goto yy714; + goto yy717; } else { - if (yych == 'f') goto yy715; + if (yych == 'f') goto yy718; goto yy186; } } -yy709: - YYDEBUG(709, *YYCURSOR); +yy712: + YYDEBUG(712, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy712; - if (yych == 'e') goto yy712; + if (yych == 'E') goto yy715; + if (yych == 'e') goto yy715; goto yy186; -yy710: - YYDEBUG(710, *YYCURSOR); +yy713: + YYDEBUG(713, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(711, *YYCURSOR); + YYDEBUG(714, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1072 "Zend/zend_language_scanner.l" +#line 1076 "Zend/zend_language_scanner.l" { return T_DO; } -#line 6664 "Zend/zend_language_scanner.c" -yy712: - YYDEBUG(712, *YYCURSOR); +#line 6697 "Zend/zend_language_scanner.c" +yy715: + YYDEBUG(715, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(713, *YYCURSOR); + YYDEBUG(716, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1020 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6677 "Zend/zend_language_scanner.c" -yy714: - YYDEBUG(714, *YYCURSOR); +#line 6710 "Zend/zend_language_scanner.c" +yy717: + YYDEBUG(717, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy721; - if (yych == 'l') goto yy721; + if (yych == 'L') goto yy724; + if (yych == 'l') goto yy724; goto yy186; -yy715: - YYDEBUG(715, *YYCURSOR); +yy718: + YYDEBUG(718, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy716; + if (yych == 'A') goto yy719; if (yych != 'a') goto yy186; -yy716: - YYDEBUG(716, *YYCURSOR); +yy719: + YYDEBUG(719, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'U') goto yy717; + if (yych == 'U') goto yy720; if (yych != 'u') goto yy186; -yy717: - YYDEBUG(717, *YYCURSOR); +yy720: + YYDEBUG(720, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy718; + if (yych == 'L') goto yy721; if (yych != 'l') goto yy186; -yy718: - YYDEBUG(718, *YYCURSOR); +yy721: + YYDEBUG(721, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy719; + if (yych == 'T') goto yy722; if (yych != 't') goto yy186; -yy719: - YYDEBUG(719, *YYCURSOR); +yy722: + YYDEBUG(722, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(720, *YYCURSOR); + YYDEBUG(723, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1120 "Zend/zend_language_scanner.l" +#line 1124 "Zend/zend_language_scanner.l" { return T_DEFAULT; } -#line 6716 "Zend/zend_language_scanner.c" -yy721: - YYDEBUG(721, *YYCURSOR); +#line 6749 "Zend/zend_language_scanner.c" +yy724: + YYDEBUG(724, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy722; + if (yych == 'A') goto yy725; if (yych != 'a') goto yy186; -yy722: - YYDEBUG(722, *YYCURSOR); +yy725: + YYDEBUG(725, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy723; + if (yych == 'R') goto yy726; if (yych != 'r') goto yy186; -yy723: - YYDEBUG(723, *YYCURSOR); +yy726: + YYDEBUG(726, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy724; + if (yych == 'E') goto yy727; if (yych != 'e') goto yy186; -yy724: - YYDEBUG(724, *YYCURSOR); +yy727: + YYDEBUG(727, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(725, *YYCURSOR); + YYDEBUG(728, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1092 "Zend/zend_language_scanner.l" +#line 1096 "Zend/zend_language_scanner.l" { return T_DECLARE; } -#line 6744 "Zend/zend_language_scanner.c" -yy726: - YYDEBUG(726, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'H') goto yy788; - if (yych == 'h') goto yy788; - goto yy186; -yy727: - YYDEBUG(727, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'S') goto yy782; - if (yych == 's') goto yy782; - goto yy186; -yy728: - YYDEBUG(728, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'P') goto yy778; - if (yych == 'p') goto yy778; - goto yy186; +#line 6777 "Zend/zend_language_scanner.c" yy729: YYDEBUG(729, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy744; - if (yych == 'd') goto yy744; + if (yych == 'H') goto yy791; + if (yych == 'h') goto yy791; goto yy186; yy730: YYDEBUG(730, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy741; - if (yych == 'a') goto yy741; + if (yych == 'S') goto yy785; + if (yych == 's') goto yy785; goto yy186; yy731: YYDEBUG(731, *YYCURSOR); yych = *++YYCURSOR; - if (yych <= 'T') { - if (yych == 'I') goto yy732; - if (yych <= 'S') goto yy186; - goto yy733; - } else { - if (yych <= 'i') { - if (yych <= 'h') goto yy186; - } else { - if (yych == 't') goto yy733; - goto yy186; - } - } + if (yych == 'P') goto yy781; + if (yych == 'p') goto yy781; + goto yy186; yy732: YYDEBUG(732, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy739; - if (yych == 't') goto yy739; + if (yych == 'D') goto yy747; + if (yych == 'd') goto yy747; goto yy186; yy733: YYDEBUG(733, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy734; - if (yych != 'e') goto yy186; + if (yych == 'A') goto yy744; + if (yych == 'a') goto yy744; + goto yy186; yy734: YYDEBUG(734, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'N') goto yy735; - if (yych != 'n') goto yy186; + if (yych <= 'T') { + if (yych == 'I') goto yy735; + if (yych <= 'S') goto yy186; + goto yy736; + } else { + if (yych <= 'i') { + if (yych <= 'h') goto yy186; + } else { + if (yych == 't') goto yy736; + goto yy186; + } + } yy735: YYDEBUG(735, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'D') goto yy736; - if (yych != 'd') goto yy186; + if (yych == 'T') goto yy742; + if (yych == 't') goto yy742; + goto yy186; yy736: YYDEBUG(736, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'S') goto yy737; - if (yych != 's') goto yy186; + if (yych == 'E') goto yy737; + if (yych != 'e') goto yy186; yy737: YYDEBUG(737, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'N') goto yy738; + if (yych != 'n') goto yy186; +yy738: + YYDEBUG(738, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'D') goto yy739; + if (yych != 'd') goto yy186; +yy739: + YYDEBUG(739, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'S') goto yy740; + if (yych != 's') goto yy186; +yy740: + YYDEBUG(740, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(738, *YYCURSOR); + YYDEBUG(741, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1156 "Zend/zend_language_scanner.l" +#line 1160 "Zend/zend_language_scanner.l" { return T_EXTENDS; } -#line 6828 "Zend/zend_language_scanner.c" -yy739: - YYDEBUG(739, *YYCURSOR); +#line 6861 "Zend/zend_language_scanner.c" +yy742: + YYDEBUG(742, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(740, *YYCURSOR); + YYDEBUG(743, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); #line 1016 "Zend/zend_language_scanner.l" { return T_EXIT; } -#line 6841 "Zend/zend_language_scanner.c" -yy741: - YYDEBUG(741, *YYCURSOR); +#line 6874 "Zend/zend_language_scanner.c" +yy744: + YYDEBUG(744, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy742; + if (yych == 'L') goto yy745; if (yych != 'l') goto yy186; -yy742: - YYDEBUG(742, *YYCURSOR); +yy745: + YYDEBUG(745, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(743, *YYCURSOR); + YYDEBUG(746, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1242 "Zend/zend_language_scanner.l" +#line 1246 "Zend/zend_language_scanner.l" { return T_EVAL; } -#line 6859 "Zend/zend_language_scanner.c" -yy744: - YYDEBUG(744, *YYCURSOR); +#line 6892 "Zend/zend_language_scanner.c" +yy747: + YYDEBUG(747, *YYCURSOR); yych = *++YYCURSOR; YYDEBUG(-1, yych); switch (yych) { case 'D': - case 'd': goto yy745; + case 'd': goto yy748; case 'F': - case 'f': goto yy746; + case 'f': goto yy749; case 'I': - case 'i': goto yy747; + case 'i': goto yy750; case 'S': - case 's': goto yy748; + case 's': goto yy751; case 'W': - case 'w': goto yy749; + case 'w': goto yy752; default: goto yy186; } -yy745: - YYDEBUG(745, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'E') goto yy771; - if (yych == 'e') goto yy771; - goto yy186; -yy746: - YYDEBUG(746, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'O') goto yy763; - if (yych == 'o') goto yy763; - goto yy186; -yy747: - YYDEBUG(747, *YYCURSOR); - yych = *++YYCURSOR; - if (yych == 'F') goto yy761; - if (yych == 'f') goto yy761; - goto yy186; yy748: YYDEBUG(748, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'W') goto yy755; - if (yych == 'w') goto yy755; + if (yych == 'E') goto yy774; + if (yych == 'e') goto yy774; goto yy186; yy749: YYDEBUG(749, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy750; - if (yych != 'h') goto yy186; + if (yych == 'O') goto yy766; + if (yych == 'o') goto yy766; + goto yy186; yy750: YYDEBUG(750, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy751; - if (yych != 'i') goto yy186; + if (yych == 'F') goto yy764; + if (yych == 'f') goto yy764; + goto yy186; yy751: YYDEBUG(751, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy752; - if (yych != 'l') goto yy186; + if (yych == 'W') goto yy758; + if (yych == 'w') goto yy758; + goto yy186; yy752: YYDEBUG(752, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy753; - if (yych != 'e') goto yy186; + if (yych == 'H') goto yy753; + if (yych != 'h') goto yy186; yy753: YYDEBUG(753, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'I') goto yy754; + if (yych != 'i') goto yy186; +yy754: + YYDEBUG(754, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'L') goto yy755; + if (yych != 'l') goto yy186; +yy755: + YYDEBUG(755, *YYCURSOR); + yych = *++YYCURSOR; + if (yych == 'E') goto yy756; + if (yych != 'e') goto yy186; +yy756: + YYDEBUG(756, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(754, *YYCURSOR); + YYDEBUG(757, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1068 "Zend/zend_language_scanner.l" +#line 1072 "Zend/zend_language_scanner.l" { return T_ENDWHILE; } -#line 6933 "Zend/zend_language_scanner.c" -yy755: - YYDEBUG(755, *YYCURSOR); +#line 6966 "Zend/zend_language_scanner.c" +yy758: + YYDEBUG(758, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'I') goto yy756; + if (yych == 'I') goto yy759; if (yych != 'i') goto yy186; -yy756: - YYDEBUG(756, *YYCURSOR); +yy759: + YYDEBUG(759, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy757; + if (yych == 'T') goto yy760; if (yych != 't') goto yy186; -yy757: - YYDEBUG(757, *YYCURSOR); +yy760: + YYDEBUG(760, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy758; + if (yych == 'C') goto yy761; if (yych != 'c') goto yy186; -yy758: - YYDEBUG(758, *YYCURSOR); +yy761: + YYDEBUG(761, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy759; + if (yych == 'H') goto yy762; if (yych != 'h') goto yy186; -yy759: - YYDEBUG(759, *YYCURSOR); +yy762: + YYDEBUG(762, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(760, *YYCURSOR); + YYDEBUG(763, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1112 "Zend/zend_language_scanner.l" +#line 1116 "Zend/zend_language_scanner.l" { return T_ENDSWITCH; } -#line 6966 "Zend/zend_language_scanner.c" -yy761: - YYDEBUG(761, *YYCURSOR); +#line 6999 "Zend/zend_language_scanner.c" +yy764: + YYDEBUG(764, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(762, *YYCURSOR); + YYDEBUG(765, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1056 "Zend/zend_language_scanner.l" +#line 1060 "Zend/zend_language_scanner.l" { return T_ENDIF; } -#line 6979 "Zend/zend_language_scanner.c" -yy763: - YYDEBUG(763, *YYCURSOR); +#line 7012 "Zend/zend_language_scanner.c" +yy766: + YYDEBUG(766, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy764; + if (yych == 'R') goto yy767; if (yych != 'r') goto yy186; -yy764: - YYDEBUG(764, *YYCURSOR); +yy767: + YYDEBUG(767, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy765; + if (yych <= '/') goto yy768; if (yych <= '9') goto yy185; } else { - if (yych == 'E') goto yy766; + if (yych == 'E') goto yy769; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'd') { if (yych != '`') goto yy185; } else { - if (yych <= 'e') goto yy766; + if (yych <= 'e') goto yy769; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy765: - YYDEBUG(765, *YYCURSOR); +yy768: + YYDEBUG(768, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1080 "Zend/zend_language_scanner.l" +#line 1084 "Zend/zend_language_scanner.l" { return T_ENDFOR; } -#line 7012 "Zend/zend_language_scanner.c" -yy766: - YYDEBUG(766, *YYCURSOR); +#line 7045 "Zend/zend_language_scanner.c" +yy769: + YYDEBUG(769, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy767; + if (yych == 'A') goto yy770; if (yych != 'a') goto yy186; -yy767: - YYDEBUG(767, *YYCURSOR); +yy770: + YYDEBUG(770, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy768; + if (yych == 'C') goto yy771; if (yych != 'c') goto yy186; -yy768: - YYDEBUG(768, *YYCURSOR); +yy771: + YYDEBUG(771, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'H') goto yy769; + if (yych == 'H') goto yy772; if (yych != 'h') goto yy186; -yy769: - YYDEBUG(769, *YYCURSOR); +yy772: + YYDEBUG(772, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(770, *YYCURSOR); + YYDEBUG(773, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1088 "Zend/zend_language_scanner.l" +#line 1092 "Zend/zend_language_scanner.l" { return T_ENDFOREACH; } -#line 7040 "Zend/zend_language_scanner.c" -yy771: - YYDEBUG(771, *YYCURSOR); +#line 7073 "Zend/zend_language_scanner.c" +yy774: + YYDEBUG(774, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'C') goto yy772; + if (yych == 'C') goto yy775; if (yych != 'c') goto yy186; -yy772: - YYDEBUG(772, *YYCURSOR); +yy775: + YYDEBUG(775, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'L') goto yy773; + if (yych == 'L') goto yy776; if (yych != 'l') goto yy186; -yy773: - YYDEBUG(773, *YYCURSOR); +yy776: + YYDEBUG(776, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'A') goto yy774; + if (yych == 'A') goto yy777; if (yych != 'a') goto yy186; -yy774: - YYDEBUG(774, *YYCURSOR); +yy777: + YYDEBUG(777, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'R') goto yy775; + if (yych == 'R') goto yy778; if (yych != 'r') goto yy186; -yy775: - YYDEBUG(775, *YYCURSOR); +yy778: + YYDEBUG(778, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy776; + if (yych == 'E') goto yy779; if (yych != 'e') goto yy186; -yy776: - YYDEBUG(776, *YYCURSOR); +yy779: + YYDEBUG(779, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(777, *YYCURSOR); + YYDEBUG(780, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1096 "Zend/zend_language_scanner.l" +#line 1100 "Zend/zend_language_scanner.l" { return T_ENDDECLARE; } -#line 7078 "Zend/zend_language_scanner.c" -yy778: - YYDEBUG(778, *YYCURSOR); +#line 7111 "Zend/zend_language_scanner.c" +yy781: + YYDEBUG(781, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'T') goto yy779; + if (yych == 'T') goto yy782; if (yych != 't') goto yy186; -yy779: - YYDEBUG(779, *YYCURSOR); +yy782: + YYDEBUG(782, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'Y') goto yy780; + if (yych == 'Y') goto yy783; if (yych != 'y') goto yy186; -yy780: - YYDEBUG(780, *YYCURSOR); +yy783: + YYDEBUG(783, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(781, *YYCURSOR); + YYDEBUG(784, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1282 "Zend/zend_language_scanner.l" +#line 1286 "Zend/zend_language_scanner.l" { return T_EMPTY; } -#line 7101 "Zend/zend_language_scanner.c" -yy782: - YYDEBUG(782, *YYCURSOR); +#line 7134 "Zend/zend_language_scanner.c" +yy785: + YYDEBUG(785, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'E') goto yy783; + if (yych == 'E') goto yy786; if (yych != 'e') goto yy186; -yy783: - YYDEBUG(783, *YYCURSOR); +yy786: + YYDEBUG(786, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '^') { if (yych <= '@') { - if (yych <= '/') goto yy784; + if (yych <= '/') goto yy787; if (yych <= '9') goto yy185; } else { - if (yych == 'I') goto yy785; + if (yych == 'I') goto yy788; if (yych <= 'Z') goto yy185; } } else { if (yych <= 'h') { if (yych != '`') goto yy185; } else { - if (yych <= 'i') goto yy785; + if (yych <= 'i') goto yy788; if (yych <= 'z') goto yy185; if (yych >= 0x7F) goto yy185; } } -yy784: - YYDEBUG(784, *YYCURSOR); +yy787: + YYDEBUG(787, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1060 "Zend/zend_language_scanner.l" +#line 1064 "Zend/zend_language_scanner.l" { return T_ELSE; } -#line 7134 "Zend/zend_language_scanner.c" -yy785: - YYDEBUG(785, *YYCURSOR); +#line 7167 "Zend/zend_language_scanner.c" +yy788: + YYDEBUG(788, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'F') goto yy786; + if (yych == 'F') goto yy789; if (yych != 'f') goto yy186; -yy786: - YYDEBUG(786, *YYCURSOR); +yy789: + YYDEBUG(789, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(787, *YYCURSOR); + YYDEBUG(790, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1052 "Zend/zend_language_scanner.l" +#line 1056 "Zend/zend_language_scanner.l" { return T_ELSEIF; } -#line 7152 "Zend/zend_language_scanner.c" -yy788: - YYDEBUG(788, *YYCURSOR); +#line 7185 "Zend/zend_language_scanner.c" +yy791: + YYDEBUG(791, *YYCURSOR); yych = *++YYCURSOR; - if (yych == 'O') goto yy789; + if (yych == 'O') goto yy792; if (yych != 'o') goto yy186; -yy789: - YYDEBUG(789, *YYCURSOR); +yy792: + YYDEBUG(792, *YYCURSOR); ++YYCURSOR; if (yybm[0+(yych = *YYCURSOR)] & 4) { goto yy185; } - YYDEBUG(790, *YYCURSOR); + YYDEBUG(793, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1136 "Zend/zend_language_scanner.l" +#line 1140 "Zend/zend_language_scanner.l" { return T_ECHO; } -#line 7170 "Zend/zend_language_scanner.c" +#line 7203 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_LOOKING_FOR_PROPERTY: @@ -7205,41 +7238,41 @@ int lex_scan(zval *zendlval TSRMLS_DC) 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, }; - YYDEBUG(791, *YYCURSOR); + YYDEBUG(794, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '-') { if (yych <= '\r') { - if (yych <= 0x08) goto yy799; - if (yych <= '\n') goto yy793; - if (yych <= '\f') goto yy799; + if (yych <= 0x08) goto yy802; + if (yych <= '\n') goto yy796; + if (yych <= '\f') goto yy802; } else { - if (yych == ' ') goto yy793; - if (yych <= ',') goto yy799; - goto yy795; + if (yych == ' ') goto yy796; + if (yych <= ',') goto yy802; + goto yy798; } } else { if (yych <= '_') { - if (yych <= '@') goto yy799; - if (yych <= 'Z') goto yy797; - if (yych <= '^') goto yy799; - goto yy797; + if (yych <= '@') goto yy802; + if (yych <= 'Z') goto yy800; + if (yych <= '^') goto yy802; + goto yy800; } else { - if (yych <= '`') goto yy799; - if (yych <= 'z') goto yy797; - if (yych <= '~') goto yy799; - goto yy797; + if (yych <= '`') goto yy802; + if (yych <= 'z') goto yy800; + if (yych <= '~') goto yy802; + goto yy800; } } -yy793: - YYDEBUG(793, *YYCURSOR); +yy796: + YYDEBUG(796, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy805; -yy794: - YYDEBUG(794, *YYCURSOR); + goto yy808; +yy797: + YYDEBUG(797, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1169 "Zend/zend_language_scanner.l" +#line 1173 "Zend/zend_language_scanner.l" { zendlval->value.str.val = yytext; /* no copying - intentional */ zendlval->value.str.len = yyleng; @@ -7247,73 +7280,73 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng); return T_WHITESPACE; } -#line 7251 "Zend/zend_language_scanner.c" -yy795: - YYDEBUG(795, *YYCURSOR); +#line 7284 "Zend/zend_language_scanner.c" +yy798: + YYDEBUG(798, *YYCURSOR); ++YYCURSOR; - if ((yych = *YYCURSOR) == '>') goto yy802; -yy796: - YYDEBUG(796, *YYCURSOR); + if ((yych = *YYCURSOR) == '>') goto yy805; +yy799: + YYDEBUG(799, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1188 "Zend/zend_language_scanner.l" +#line 1192 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); goto restart; } -#line 7265 "Zend/zend_language_scanner.c" -yy797: - YYDEBUG(797, *YYCURSOR); +#line 7298 "Zend/zend_language_scanner.c" +yy800: + YYDEBUG(800, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy801; -yy798: - YYDEBUG(798, *YYCURSOR); + goto yy804; +yy801: + YYDEBUG(801, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1181 "Zend/zend_language_scanner.l" +#line 1185 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7281 "Zend/zend_language_scanner.c" -yy799: - YYDEBUG(799, *YYCURSOR); +#line 7314 "Zend/zend_language_scanner.c" +yy802: + YYDEBUG(802, *YYCURSOR); yych = *++YYCURSOR; - goto yy796; -yy800: - YYDEBUG(800, *YYCURSOR); + goto yy799; +yy803: + YYDEBUG(803, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy801: - YYDEBUG(801, *YYCURSOR); +yy804: + YYDEBUG(804, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy800; + goto yy803; } - goto yy798; -yy802: - YYDEBUG(802, *YYCURSOR); + goto yy801; +yy805: + YYDEBUG(805, *YYCURSOR); ++YYCURSOR; - YYDEBUG(803, *YYCURSOR); + YYDEBUG(806, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1177 "Zend/zend_language_scanner.l" +#line 1181 "Zend/zend_language_scanner.l" { return T_OBJECT_OPERATOR; } -#line 7306 "Zend/zend_language_scanner.c" -yy804: - YYDEBUG(804, *YYCURSOR); +#line 7339 "Zend/zend_language_scanner.c" +yy807: + YYDEBUG(807, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy805: - YYDEBUG(805, *YYCURSOR); +yy808: + YYDEBUG(808, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy804; + goto yy807; } - goto yy794; + goto yy797; } /* *********************************** */ yyc_ST_LOOKING_FOR_VARNAME: @@ -7352,74 +7385,74 @@ int lex_scan(zval *zendlval TSRMLS_DC) 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128, }; - YYDEBUG(806, *YYCURSOR); + YYDEBUG(809, *YYCURSOR); YYFILL(2); yych = *YYCURSOR; if (yych <= '_') { - if (yych <= '@') goto yy810; - if (yych <= 'Z') goto yy808; - if (yych <= '^') goto yy810; + if (yych <= '@') goto yy813; + if (yych <= 'Z') goto yy811; + if (yych <= '^') goto yy813; } else { - if (yych <= '`') goto yy810; - if (yych <= 'z') goto yy808; - if (yych <= '~') goto yy810; + if (yych <= '`') goto yy813; + if (yych <= 'z') goto yy811; + if (yych <= '~') goto yy813; } -yy808: - YYDEBUG(808, *YYCURSOR); +yy811: + YYDEBUG(811, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= '_') { if (yych <= '@') { - if (yych <= '/') goto yy809; - if (yych <= '9') goto yy812; + if (yych <= '/') goto yy812; + if (yych <= '9') goto yy815; } else { - if (yych <= '[') goto yy812; - if (yych >= '_') goto yy812; + if (yych <= '[') goto yy815; + if (yych >= '_') goto yy815; } } else { if (yych <= '|') { - if (yych <= '`') goto yy809; - if (yych <= 'z') goto yy812; + if (yych <= '`') goto yy812; + if (yych <= 'z') goto yy815; } else { - if (yych != '~') goto yy812; + if (yych != '~') goto yy815; } } -yy809: - YYDEBUG(809, *YYCURSOR); +yy812: + YYDEBUG(812, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1474 "Zend/zend_language_scanner.l" +#line 1478 "Zend/zend_language_scanner.l" { yyless(0); yy_pop_state(TSRMLS_C); yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); goto restart; } -#line 7398 "Zend/zend_language_scanner.c" -yy810: - YYDEBUG(810, *YYCURSOR); +#line 7431 "Zend/zend_language_scanner.c" +yy813: + YYDEBUG(813, *YYCURSOR); yych = *++YYCURSOR; - goto yy809; -yy811: - YYDEBUG(811, *YYCURSOR); + goto yy812; +yy814: + YYDEBUG(814, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy812: - YYDEBUG(812, *YYCURSOR); +yy815: + YYDEBUG(815, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy811; + goto yy814; } - if (yych == '[') goto yy814; - if (yych == '}') goto yy814; - YYDEBUG(813, *YYCURSOR); + if (yych == '[') goto yy817; + if (yych == '}') goto yy817; + YYDEBUG(816, *YYCURSOR); YYCURSOR = YYMARKER; - goto yy809; -yy814: - YYDEBUG(814, *YYCURSOR); + goto yy812; +yy817: + YYDEBUG(817, *YYCURSOR); ++YYCURSOR; - YYDEBUG(815, *YYCURSOR); + YYDEBUG(818, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1464 "Zend/zend_language_scanner.l" +#line 1468 "Zend/zend_language_scanner.l" { yyless(yyleng - 1); zend_copy_value(zendlval, yytext, yyleng); @@ -7428,18 +7461,18 @@ int lex_scan(zval *zendlval TSRMLS_DC) yy_push_state(ST_IN_SCRIPTING TSRMLS_CC); return T_STRING_VARNAME; } -#line 7432 "Zend/zend_language_scanner.c" +#line 7465 "Zend/zend_language_scanner.c" } /* *********************************** */ yyc_ST_NOWDOC: - YYDEBUG(816, *YYCURSOR); + YYDEBUG(819, *YYCURSOR); YYFILL(1); yych = *YYCURSOR; - YYDEBUG(818, *YYCURSOR); + YYDEBUG(821, *YYCURSOR); ++YYCURSOR; - YYDEBUG(819, *YYCURSOR); + YYDEBUG(822, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2356 "Zend/zend_language_scanner.l" +#line 2360 "Zend/zend_language_scanner.l" { int newline = 0; @@ -7494,7 +7527,7 @@ int lex_scan(zval *zendlval TSRMLS_DC) HANDLE_NEWLINES(yytext, yyleng - newline); return T_ENCAPSED_AND_WHITESPACE; } -#line 7498 "Zend/zend_language_scanner.c" +#line 7531 "Zend/zend_language_scanner.c" /* *********************************** */ yyc_ST_VAR_OFFSET: { @@ -7532,76 +7565,76 @@ int lex_scan(zval *zendlval TSRMLS_DC) 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, }; - YYDEBUG(820, *YYCURSOR); + YYDEBUG(823, *YYCURSOR); YYFILL(3); yych = *YYCURSOR; if (yych <= '/') { if (yych <= ' ') { if (yych <= '\f') { - if (yych <= 0x08) goto yy834; - if (yych <= '\n') goto yy830; - goto yy834; + if (yych <= 0x08) goto yy837; + if (yych <= '\n') goto yy833; + goto yy837; } else { - if (yych <= '\r') goto yy830; - if (yych <= 0x1F) goto yy834; - goto yy830; + if (yych <= '\r') goto yy833; + if (yych <= 0x1F) goto yy837; + goto yy833; } } else { if (yych <= '$') { - if (yych <= '"') goto yy829; - if (yych <= '#') goto yy830; - goto yy825; + if (yych <= '"') goto yy832; + if (yych <= '#') goto yy833; + goto yy828; } else { - if (yych == '\'') goto yy830; - goto yy829; + if (yych == '\'') goto yy833; + goto yy832; } } } else { if (yych <= '\\') { if (yych <= '@') { - if (yych <= '0') goto yy822; - if (yych <= '9') goto yy824; - goto yy829; + if (yych <= '0') goto yy825; + if (yych <= '9') goto yy827; + goto yy832; } else { - if (yych <= 'Z') goto yy832; - if (yych <= '[') goto yy829; - goto yy830; + if (yych <= 'Z') goto yy835; + if (yych <= '[') goto yy832; + goto yy833; } } else { if (yych <= '_') { - if (yych <= ']') goto yy827; - if (yych <= '^') goto yy829; - goto yy832; + if (yych <= ']') goto yy830; + if (yych <= '^') goto yy832; + goto yy835; } else { - if (yych <= '`') goto yy829; - if (yych <= 'z') goto yy832; - if (yych <= '~') goto yy829; - goto yy832; + if (yych <= '`') goto yy832; + if (yych <= 'z') goto yy835; + if (yych <= '~') goto yy832; + goto yy835; } } } -yy822: - YYDEBUG(822, *YYCURSOR); +yy825: + YYDEBUG(825, *YYCURSOR); yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); if (yych <= 'W') { if (yych <= '9') { - if (yych >= '0') goto yy846; + if (yych >= '0') goto yy849; } else { - if (yych == 'B') goto yy843; + if (yych == 'B') goto yy846; } } else { if (yych <= 'b') { - if (yych <= 'X') goto yy845; - if (yych >= 'b') goto yy843; + if (yych <= 'X') goto yy848; + if (yych >= 'b') goto yy846; } else { - if (yych == 'x') goto yy845; + if (yych == 'x') goto yy848; } } -yy823: - YYDEBUG(823, *YYCURSOR); +yy826: + YYDEBUG(826, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1552 "Zend/zend_language_scanner.l" +#line 1556 "Zend/zend_language_scanner.l" { /* Offset could be treated as a long */ if (yyleng < MAX_LENGTH_OF_LONG - 1 || (yyleng == MAX_LENGTH_OF_LONG - 1 && strcmp(yytext, long_min_digits) < 0)) { zendlval->value.lval = strtol(yytext, NULL, 10); @@ -7613,81 +7646,81 @@ int lex_scan(zval *zendlval TSRMLS_DC) } return T_NUM_STRING; } -#line 7617 "Zend/zend_language_scanner.c" -yy824: - YYDEBUG(824, *YYCURSOR); +#line 7650 "Zend/zend_language_scanner.c" +yy827: + YYDEBUG(827, *YYCURSOR); yych = *++YYCURSOR; - goto yy842; -yy825: - YYDEBUG(825, *YYCURSOR); + goto yy845; +yy828: + YYDEBUG(828, *YYCURSOR); ++YYCURSOR; if ((yych = *YYCURSOR) <= '_') { - if (yych <= '@') goto yy826; - if (yych <= 'Z') goto yy838; - if (yych >= '_') goto yy838; + if (yych <= '@') goto yy829; + if (yych <= 'Z') goto yy841; + if (yych >= '_') goto yy841; } else { - if (yych <= '`') goto yy826; - if (yych <= 'z') goto yy838; - if (yych >= 0x7F) goto yy838; + if (yych <= '`') goto yy829; + if (yych <= 'z') goto yy841; + if (yych >= 0x7F) goto yy841; } -yy826: - YYDEBUG(826, *YYCURSOR); +yy829: + YYDEBUG(829, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1884 "Zend/zend_language_scanner.l" +#line 1888 "Zend/zend_language_scanner.l" { /* Only '[' can be valid, but returning other tokens will allow a more explicit parse error */ return yytext[0]; } -#line 7642 "Zend/zend_language_scanner.c" -yy827: - YYDEBUG(827, *YYCURSOR); +#line 7675 "Zend/zend_language_scanner.c" +yy830: + YYDEBUG(830, *YYCURSOR); ++YYCURSOR; - YYDEBUG(828, *YYCURSOR); + YYDEBUG(831, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1879 "Zend/zend_language_scanner.l" +#line 1883 "Zend/zend_language_scanner.l" { yy_pop_state(TSRMLS_C); return ']'; } -#line 7653 "Zend/zend_language_scanner.c" -yy829: - YYDEBUG(829, *YYCURSOR); +#line 7686 "Zend/zend_language_scanner.c" +yy832: + YYDEBUG(832, *YYCURSOR); yych = *++YYCURSOR; - goto yy826; -yy830: - YYDEBUG(830, *YYCURSOR); + goto yy829; +yy833: + YYDEBUG(833, *YYCURSOR); ++YYCURSOR; - YYDEBUG(831, *YYCURSOR); + YYDEBUG(834, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1889 "Zend/zend_language_scanner.l" +#line 1893 "Zend/zend_language_scanner.l" { /* Invalid rule to return a more explicit parse error with proper line number */ yyless(0); yy_pop_state(TSRMLS_C); return T_ENCAPSED_AND_WHITESPACE; } -#line 7670 "Zend/zend_language_scanner.c" -yy832: - YYDEBUG(832, *YYCURSOR); +#line 7703 "Zend/zend_language_scanner.c" +yy835: + YYDEBUG(835, *YYCURSOR); ++YYCURSOR; yych = *YYCURSOR; - goto yy837; -yy833: - YYDEBUG(833, *YYCURSOR); + goto yy840; +yy836: + YYDEBUG(836, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1896 "Zend/zend_language_scanner.l" +#line 1900 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, yytext, yyleng); zendlval->type = IS_STRING; return T_STRING; } -#line 7685 "Zend/zend_language_scanner.c" -yy834: - YYDEBUG(834, *YYCURSOR); +#line 7718 "Zend/zend_language_scanner.c" +yy837: + YYDEBUG(837, *YYCURSOR); ++YYCURSOR; - YYDEBUG(835, *YYCURSOR); + YYDEBUG(838, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 2412 "Zend/zend_language_scanner.l" +#line 2416 "Zend/zend_language_scanner.l" { if (YYCURSOR > YYLIMIT) { return 0; @@ -7696,118 +7729,118 @@ int lex_scan(zval *zendlval TSRMLS_DC) zend_error(E_COMPILE_WARNING,"Unexpected character in input: '%c' (ASCII=%d) state=%d", yytext[0], yytext[0], YYSTATE); goto restart; } -#line 7700 "Zend/zend_language_scanner.c" -yy836: - YYDEBUG(836, *YYCURSOR); +#line 7733 "Zend/zend_language_scanner.c" +yy839: + YYDEBUG(839, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy837: - YYDEBUG(837, *YYCURSOR); +yy840: + YYDEBUG(840, *YYCURSOR); if (yybm[0+yych] & 16) { - goto yy836; + goto yy839; } - goto yy833; -yy838: - YYDEBUG(838, *YYCURSOR); + goto yy836; +yy841: + YYDEBUG(841, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(839, *YYCURSOR); + YYDEBUG(842, *YYCURSOR); if (yych <= '^') { if (yych <= '9') { - if (yych >= '0') goto yy838; + if (yych >= '0') goto yy841; } else { - if (yych <= '@') goto yy840; - if (yych <= 'Z') goto yy838; + if (yych <= '@') goto yy843; + if (yych <= 'Z') goto yy841; } } else { if (yych <= '`') { - if (yych <= '_') goto yy838; + if (yych <= '_') goto yy841; } else { - if (yych <= 'z') goto yy838; - if (yych >= 0x7F) goto yy838; + if (yych <= 'z') goto yy841; + if (yych >= 0x7F) goto yy841; } } -yy840: - YYDEBUG(840, *YYCURSOR); +yy843: + YYDEBUG(843, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1873 "Zend/zend_language_scanner.l" +#line 1877 "Zend/zend_language_scanner.l" { zend_copy_value(zendlval, (yytext+1), (yyleng-1)); zendlval->type = IS_STRING; return T_VARIABLE; } -#line 7742 "Zend/zend_language_scanner.c" -yy841: - YYDEBUG(841, *YYCURSOR); +#line 7775 "Zend/zend_language_scanner.c" +yy844: + YYDEBUG(844, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; -yy842: - YYDEBUG(842, *YYCURSOR); +yy845: + YYDEBUG(845, *YYCURSOR); if (yybm[0+yych] & 32) { - goto yy841; + goto yy844; } - goto yy823; -yy843: - YYDEBUG(843, *YYCURSOR); + goto yy826; +yy846: + YYDEBUG(846, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 128) { - goto yy851; + goto yy854; } -yy844: - YYDEBUG(844, *YYCURSOR); +yy847: + YYDEBUG(847, *YYCURSOR); YYCURSOR = YYMARKER; - goto yy823; -yy845: - YYDEBUG(845, *YYCURSOR); + goto yy826; +yy848: + YYDEBUG(848, *YYCURSOR); yych = *++YYCURSOR; if (yybm[0+yych] & 64) { - goto yy849; + goto yy852; } - goto yy844; -yy846: - YYDEBUG(846, *YYCURSOR); + goto yy847; +yy849: + YYDEBUG(849, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(847, *YYCURSOR); - if (yych <= '/') goto yy848; - if (yych <= '9') goto yy846; -yy848: - YYDEBUG(848, *YYCURSOR); + YYDEBUG(850, *YYCURSOR); + if (yych <= '/') goto yy851; + if (yych <= '9') goto yy849; +yy851: + YYDEBUG(851, *YYCURSOR); yyleng = YYCURSOR - SCNG(yy_text); -#line 1564 "Zend/zend_language_scanner.l" +#line 1568 "Zend/zend_language_scanner.l" { /* Offset must be treated as a string */ zendlval->value.str.val = (char *)estrndup(yytext, yyleng); zendlval->value.str.len = yyleng; zendlval->type = IS_STRING; return T_NUM_STRING; } -#line 7789 "Zend/zend_language_scanner.c" -yy849: - YYDEBUG(849, *YYCURSOR); +#line 7822 "Zend/zend_language_scanner.c" +yy852: + YYDEBUG(852, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(850, *YYCURSOR); + YYDEBUG(853, *YYCURSOR); if (yybm[0+yych] & 64) { - goto yy849; + goto yy852; } - goto yy848; -yy851: - YYDEBUG(851, *YYCURSOR); + goto yy851; +yy854: + YYDEBUG(854, *YYCURSOR); ++YYCURSOR; YYFILL(1); yych = *YYCURSOR; - YYDEBUG(852, *YYCURSOR); + YYDEBUG(855, *YYCURSOR); if (yybm[0+yych] & 128) { - goto yy851; + goto yy854; } - goto yy848; + goto yy851; } } -#line 2421 "Zend/zend_language_scanner.l" +#line 2425 "Zend/zend_language_scanner.l" } diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index c73f39aedb9fc..1104c6ac27e5e 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1041,6 +1041,10 @@ NEWLINE ("\r"|"\n"|"\r\n") return T_CATCH; } +"finally" { + return T_FINALLY; +} + "throw" { return T_THROW; } diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index 5ef78a9faf30b..519d415e74ac0 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon Apr 30 15:56:25 2012 */ +/* Generated by re2c 0.13.5 on Tue Jul 24 17:16:42 2012 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 5480698d9f544..ad9301d975b3f 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2133,7 +2133,9 @@ ZEND_VM_HANDLER(109, ZEND_FETCH_CLASS, ANY, CONST|TMP|VAR|UNUSED|CV) USE_OPLINE SAVE_OPLINE(); - EG(exception) = NULL; + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (OP2_TYPE == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -2833,7 +2835,7 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) USE_OPLINE zval *retval_ptr; zend_free_op free_op1; - + SAVE_OPLINE(); retval_ptr = GET_OP1_ZVAL_PTR(BP_VAR_R); @@ -2842,6 +2844,9 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) FREE_OP1(); } } else if (!IS_OP1_TMP_FREE()) { /* Not a temp var */ + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (OP1_TYPE == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -2863,12 +2868,59 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) } else { zval *ret; + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } FREE_OP1_IF_VAR(); - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + + if (!(EG(active_op_array)->last_try_catch)) { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } } ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) @@ -2881,6 +2933,10 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) SAVE_OPLINE(); do { + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + if (OP1_TYPE == IS_CONST || OP1_TYPE == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); @@ -2936,7 +2992,50 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) } while (0); FREE_OP1_IF_VAR(); - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + + if (!(EG(active_op_array)->last_try_catch)) { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } } ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) @@ -4997,8 +5096,8 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) { zend_uint op_num = EG(opline_before_exception)-EG(active_op_array)->opcodes; int i; - zend_uint catch_op_num = 0; - int catched = 0; + zend_uint catch_op_num = 0, finally_op_num = 0; + int catched = 0, finally = 0; zval restored_error_reporting; void **stack_frame = (void**)(((char*)EX_Ts()) + @@ -5013,10 +5112,15 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { /* further blocks will not be relevant... */ break; - } else if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + } + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; - catched = 1; + catched = i + 1; } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; + finally = i + 1; + } } while (EX(fbc)) { @@ -5073,12 +5177,29 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) } EX(old_error_reporting) = NULL; - if (!catched) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } else { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } + if (catched && finally) { + if (finally_op_num > catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catched) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally) { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } } ZEND_VM_HANDLER(146, ZEND_VERIFY_ABSTRACT_CLASS, ANY, ANY) @@ -5196,4 +5317,50 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_NEXT_OPCODE(); } +ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) { +{ + USE_OPLINE; + SAVE_OPLINE(); + zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + + zend_exception_restore(TSRMLS_C); + if (EX(leaving)) { + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(exception)) { + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } else { + ZEND_VM_NEXT_OPCODE(); + } +} + ZEND_VM_EXPORT_HELPER(zend_do_fcall, zend_do_fcall_common_helper) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 5cedfbe343829..df7c94f5ed479 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -372,6 +372,7 @@ ZEND_API void execute(zend_op_array *op_array TSRMLS_DC) EX(prev_execute_data) = EG(current_execute_data); EG(current_execute_data) = execute_data; EX(nested) = nested; + EX(leaving) = 0; nested = 1; LOAD_REGS(); @@ -1033,8 +1034,8 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER { zend_uint op_num = EG(opline_before_exception)-EG(active_op_array)->opcodes; int i; - zend_uint catch_op_num = 0; - int catched = 0; + zend_uint catch_op_num = 0, finally_op_num = 0; + int catched = 0, finally = 0; zval restored_error_reporting; void **stack_frame = (void**)(((char*)EX_Ts()) + @@ -1049,10 +1050,15 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { /* further blocks will not be relevant... */ break; - } else if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + } + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; - catched = 1; + catched = i + 1; } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; + finally = i + 1; + } } while (EX(fbc)) { @@ -1109,12 +1115,29 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER } EX(old_error_reporting) = NULL; - if (!catched) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } + if (catched && finally) { + if (finally_op_num > catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catched) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally) { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } } static int ZEND_FASTCALL ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1152,12 +1175,60 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } +static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + USE_OPLINE; + SAVE_OPLINE(); + zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + + zend_exception_restore(TSRMLS_C); + if (EX(leaving)) { + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(exception)) { + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } else { + ZEND_VM_NEXT_OPCODE(); + } +} + static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE SAVE_OPLINE(); - EG(exception) = NULL; + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_CONST == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1458,7 +1529,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ USE_OPLINE SAVE_OPLINE(); - EG(exception) = NULL; + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_TMP_VAR == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1622,7 +1695,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ USE_OPLINE SAVE_OPLINE(); - EG(exception) = NULL; + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_VAR == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1786,7 +1861,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDL USE_OPLINE SAVE_OPLINE(); - EG(exception) = NULL; + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_UNUSED == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1820,7 +1897,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A USE_OPLINE SAVE_OPLINE(); - EG(exception) = NULL; + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_CV == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -2233,6 +2312,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG } } else if (!0) { /* Not a temp var */ + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_CONST == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -2254,12 +2336,58 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG } else { zval *ret; + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2272,6 +2400,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); do { + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); @@ -2326,7 +2458,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -6766,6 +6940,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval_dtor(free_op1.var); } } else if (!1) { /* Not a temp var */ + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_TMP_VAR == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -6787,12 +6964,58 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } else { zval *ret; + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -6805,6 +7028,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); do { + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); @@ -6859,7 +7086,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11204,6 +11473,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else if (!0) { /* Not a temp var */ + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_VAR == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -11225,12 +11497,59 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } else { zval *ret; + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11243,6 +11562,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); do { + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); @@ -11298,7 +11621,50 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE } while (0); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27205,6 +27571,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } } else if (!0) { /* Not a temp var */ + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_CV == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -27226,12 +27595,58 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } else { zval *ret; + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27244,6 +27659,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); do { + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } + if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); @@ -27298,7 +27717,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -40794,6 +41255,31 @@ void zend_init_opcodes_handlers(void) ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, + ZEND_LEAVE_SPEC_HANDLER, ZEND_NULL_HANDLER }; zend_opcode_handlers = (opcode_handler_t*)labels; diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index 426f689795fc9..f5d0b7879a9fa 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -35,6 +35,7 @@ zend_vm_enter: EX(prev_execute_data) = EG(current_execute_data); EG(current_execute_data) = execute_data; EX(nested) = nested; + EX(leaving) = 0; nested = 1; LOAD_REGS(); diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 680778c2a2873..69603d1d13889 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -159,3 +159,4 @@ #define ZEND_SEPARATE 156 #define ZEND_QM_ASSIGN_VAR 157 #define ZEND_JMP_SET_VAR 158 +#define ZEND_LEAVE 159 From ae716939eb500f962336d37b96069cb7452c25df Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 13 Aug 2012 17:17:18 +0200 Subject: [PATCH 1991/2394] Support trivial finally in generators (no yield, no return) The finally clause is now properly run when an exception is thrown in the try-block. It is not yet run on `return` and also not run when the generator is claused within a try block. I'll add those two things as soon as laruence refactored the finally code. --- Zend/zend_vm_def.h | 24 ++++++++++++------------ Zend/zend_vm_execute.h | 24 ++++++++++++------------ 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 83ae5c5ba43f9..49ee3148e3d03 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2513,6 +2513,18 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) zend_bool nested; zend_op_array *op_array = EX(op_array); + /* Generators go throw a different cleanup process */ + if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { + /* The generator object is stored in return_value_ptr_ptr */ + zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + + /* Close the generator to free up resources */ + zend_generator_close(generator, 1 TSRMLS_CC); + + /* Pass execution back to handling code */ + ZEND_VM_RETURN(); + } + EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { @@ -5213,18 +5225,6 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } else { - /* For generators skip the leave handler and return directly */ - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 495b520ecb22f..94c2a7cf166b4 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -496,6 +496,18 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) zend_bool nested; zend_op_array *op_array = EX(op_array); + /* Generators go throw a different cleanup process */ + if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { + /* The generator object is stored in return_value_ptr_ptr */ + zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + + /* Close the generator to free up resources */ + zend_generator_close(generator, 1 TSRMLS_CC); + + /* Pass execution back to handling code */ + ZEND_VM_RETURN(); + } + EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { @@ -1177,18 +1189,6 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } else { - /* For generators skip the leave handler and return directly */ - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } From f3192ea6e4405dded21cc81a6587374b019a6173 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 13 Aug 2012 18:42:16 +0200 Subject: [PATCH 1992/2394] Fix 64bit JSON test --- ext/json/tests/pass001.1_64bit.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/json/tests/pass001.1_64bit.phpt b/ext/json/tests/pass001.1_64bit.phpt index 9c3e669952899..ff2714436d056 100644 --- a/ext/json/tests/pass001.1_64bit.phpt +++ b/ext/json/tests/pass001.1_64bit.phpt @@ -90,10 +90,10 @@ $arr = json_decode($test, true); var_dump($arr); echo "ENCODE: FROM OBJECT\n"; -$obj_enc = json_encode($obj); +$obj_enc = json_encode($obj, JSON_PARTIAL_OUTPUT_ON_ERROR); echo $obj_enc . "\n"; echo "ENCODE: FROM ARRAY\n"; -$arr_enc = json_encode($arr); +$arr_enc = json_encode($arr, JSON_PARTIAL_OUTPUT_ON_ERROR); echo $arr_enc . "\n"; echo "DECODE AGAIN: AS OBJECT\n"; From 7195a5b3768e519b8f50d131a8c7041a0b57959e Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 13 Aug 2012 19:24:44 +0200 Subject: [PATCH 1993/2394] Forgot to add test --- .../generators/finally_uninterrupted.phpt | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 Zend/tests/generators/finally_uninterrupted.phpt diff --git a/Zend/tests/generators/finally_uninterrupted.phpt b/Zend/tests/generators/finally_uninterrupted.phpt new file mode 100644 index 0000000000000..64c94382aa010 --- /dev/null +++ b/Zend/tests/generators/finally_uninterrupted.phpt @@ -0,0 +1,28 @@ +--TEST-- +Use of finally in generator without interrupt +--FILE-- +rewind(); // force run + +?> +--EXPECTF-- +finally run + +Fatal error: Uncaught exception 'Exception' in %s:%d +Stack trace: +#0 [internal function]: gen() +#1 %s(%d): Generator->rewind() +#2 {main} + thrown in %s on line %d From baea290b6c0843afb23bf9ea2979a8de15a406ce Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Mon, 13 Aug 2012 19:44:45 +0200 Subject: [PATCH 1994/2394] fix windows build --- Zend/zend_vm_def.h | 4 ++-- Zend/zend_vm_execute.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index ad9301d975b3f..1aded4e4a2c28 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5319,10 +5319,10 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) { { - USE_OPLINE; - SAVE_OPLINE(); + USE_OPLINE zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + SAVE_OPLINE(); zend_exception_restore(TSRMLS_C); if (EX(leaving)) { zend_uint catch_op_num = 0, finally_op_num = 0; diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index df7c94f5ed479..c4fe9a92d8c7e 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1177,10 +1177,10 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - USE_OPLINE; - SAVE_OPLINE(); + USE_OPLINE zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + SAVE_OPLINE(); zend_exception_restore(TSRMLS_C); if (EX(leaving)) { zend_uint catch_op_num = 0, finally_op_num = 0; From 544f5ad35bfe8351ea3f0821a61d83ce9300457d Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 13 Aug 2012 20:29:55 +0200 Subject: [PATCH 1995/2394] Fix mcrypt_ecb tests after deprecation --- ext/mcrypt/tests/mcrypt_ecb.phpt | 6 ++++++ ext/mcrypt/tests/mcrypt_ecb_3des_decrypt.phpt | 4 +++- ext/mcrypt/tests/mcrypt_ecb_3des_encrypt.phpt | 2 ++ ext/mcrypt/tests/mcrypt_ecb_error.phpt | 2 ++ ext/mcrypt/tests/mcrypt_ecb_variation1.phpt | 4 +++- ext/mcrypt/tests/mcrypt_ecb_variation2.phpt | 4 +++- ext/mcrypt/tests/mcrypt_ecb_variation3.phpt | 4 +++- ext/mcrypt/tests/mcrypt_ecb_variation4.phpt | 4 +++- ext/mcrypt/tests/mcrypt_ecb_variation5.phpt | 4 +++- 9 files changed, 28 insertions(+), 6 deletions(-) diff --git a/ext/mcrypt/tests/mcrypt_ecb.phpt b/ext/mcrypt/tests/mcrypt_ecb.phpt index e75d9fa6cde2b..b6d0a227865ab 100644 --- a/ext/mcrypt/tests/mcrypt_ecb.phpt +++ b/ext/mcrypt/tests/mcrypt_ecb.phpt @@ -18,4 +18,10 @@ echo trim(mcrypt_ecb($cipher, $key, $enc_data, MCRYPT_DECRYPT, $iv)) . "\n"; mcrypt_ecb($cipher, $key, $enc_data, MCRYPT_DECRYPT); --EXPECTF-- + +Deprecated: Function mcrypt_ecb() is deprecated in %s on line %d + +Deprecated: Function mcrypt_ecb() is deprecated in %s on line %d PHP Testfest 2008 + +Deprecated: Function mcrypt_ecb() is deprecated in %s on line %d diff --git a/ext/mcrypt/tests/mcrypt_ecb_3des_decrypt.phpt b/ext/mcrypt/tests/mcrypt_ecb_3des_decrypt.phpt index 7a5cc27f4433c..82f9608da8d1b 100644 --- a/ext/mcrypt/tests/mcrypt_ecb_3des_decrypt.phpt +++ b/ext/mcrypt/tests/mcrypt_ecb_3des_decrypt.phpt @@ -8,6 +8,8 @@ if (!extension_loaded("mcrypt")) { ?> --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- --FILE-- Date: Tue, 14 Aug 2012 08:59:40 +0800 Subject: [PATCH 1996/2394] Add functions declarations, use tabs --- Zend/zend_compile.c | 38 +- Zend/zend_compile.h | 2 + Zend/zend_language_parser.y | 16 +- Zend/zend_vm_def.h | 368 +++++------ Zend/zend_vm_execute.h | 1222 +++++++++++++++++------------------ 5 files changed, 822 insertions(+), 824 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 1e995b6738a01..48b85f0b7091c 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2722,7 +2722,7 @@ void zend_do_try(znode *try_token TSRMLS_DC) /* {{{ */ /* }}} */ void zend_do_finally(znode *finally_token TSRMLS_DC) /* {{{ */ { - finally_token->u.op.opline_num = get_next_op_number(CG(active_op_array)); + finally_token->u.op.opline_num = get_next_op_number(CG(active_op_array)); } /* }}} */ void zend_do_begin_catch(znode *catch_token, znode *class_name, znode *catch_var, znode *first_catch TSRMLS_DC) /* {{{ */ @@ -2776,34 +2776,30 @@ void zend_do_end_catch(znode *catch_token TSRMLS_DC) /* {{{ */ /* }}} */ void zend_do_bind_catch(znode *try_token, znode *catch_token TSRMLS_DC) /* {{{ */ { - if (catch_token->op_type != IS_UNUSED) { - zend_add_catch_element(try_token->u.op.opline_num, catch_token->EA TSRMLS_CC); - } + if (catch_token->op_type != IS_UNUSED) { + zend_add_catch_element(try_token->u.op.opline_num, catch_token->EA TSRMLS_CC); + } } /* }}} */ - void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_token TSRMLS_DC) /* {{{ */ { zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); - if (catch_token->op_type == IS_UNUSED && finally_token->op_type == IS_UNUSED) { - zend_error(E_COMPILE_ERROR, "Cannot use try without catch or finally"); - } - if (finally_token->op_type != IS_UNUSED) { - CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; - //try_token->u.op.opline_num = catch_token->u.op.opline_num; - - opline->opcode = ZEND_LEAVE; - SET_UNUSED(opline->op1); - SET_UNUSED(opline->op2); - } - if (catch_token->op_type == IS_UNUSED) { - CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].catch_op = 0; - } //else { - // try_token->u.op.opline_num = catch_token->u.op.opline_num; - //} + if (catch_token->op_type == IS_UNUSED && finally_token->op_type == IS_UNUSED) { + zend_error(E_COMPILE_ERROR, "Cannot use try without catch or finally"); + } + if (finally_token->op_type != IS_UNUSED) { + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; + //try_token->u.op.opline_num = catch_token->u.op.opline_num; + opline->opcode = ZEND_LEAVE; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + } + if (catch_token->op_type == IS_UNUSED) { + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].catch_op = 0; + } } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index f604de4699cf5..550fb0e9318dc 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -499,6 +499,8 @@ void zend_do_fetch_lexical_variable(znode *varname, zend_bool is_ref TSRMLS_DC); void zend_do_try(znode *try_token TSRMLS_DC); void zend_do_begin_catch(znode *try_token, znode *catch_class, znode *catch_var, znode *first_catch TSRMLS_DC); void zend_do_end_catch(znode *catch_token TSRMLS_DC); +void zend_do_finally(znode *finally_token TSRMLS_DC); +void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_token TSRMLS_DC); void zend_do_throw(const znode *expr TSRMLS_DC); ZEND_API int do_bind_function(const zend_op_array *op_array, zend_op *opline, HashTable *function_table, zend_bool compile_time); diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 80760a5a54305..a508fc736292f 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -315,23 +315,23 @@ unticked_statement: | T_DECLARE { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); zend_do_declare_begin(TSRMLS_C); } '(' declare_list ')' declare_statement { zend_do_declare_end(&$1 TSRMLS_CC); } | ';' /* empty statement */ | T_TRY { zend_do_try(&$1 TSRMLS_CC); } '{' inner_statement_list '}' - catch_statement { zend_do_bind_catch(&$1, &$6 TSRMLS_CC); } - finally_statement { zend_do_end_finally(&$1, &$6, &$8 TSRMLS_CC); } + catch_statement { zend_do_bind_catch(&$1, &$6 TSRMLS_CC); } + finally_statement { zend_do_end_finally(&$1, &$6, &$8 TSRMLS_CC); } | T_THROW expr ';' { zend_do_throw(&$2 TSRMLS_CC); } | T_GOTO T_STRING ';' { zend_do_goto(&$2 TSRMLS_CC); } ; catch_statement: - /* empty */ { $$.op_type = IS_UNUSED; } - | T_CATCH '(' { zend_initialize_try_catch_element(&$1 TSRMLS_CC); } - fully_qualified_class_name { zend_do_first_catch(&$2 TSRMLS_CC); } - T_VARIABLE ')' { zend_do_begin_catch(&$1, &$4, &$6, &$2 TSRMLS_CC); } + /* empty */ { $$.op_type = IS_UNUSED; } + | T_CATCH '(' { zend_initialize_try_catch_element(&$1 TSRMLS_CC); } + fully_qualified_class_name { zend_do_first_catch(&$2 TSRMLS_CC); } + T_VARIABLE ')' { zend_do_begin_catch(&$1, &$4, &$6, &$2 TSRMLS_CC); } '{' inner_statement_list '}' { zend_do_end_catch(&$1 TSRMLS_CC); } additional_catches { zend_do_mark_last_catch(&$2, &$13 TSRMLS_CC); $$ = $1;} finally_statement: - /* empty */ { $$.op_type = IS_UNUSED; } - | T_FINALLY { zend_do_finally(&$1 TSRMLS_CC); } '{' inner_statement_list '}' { $$ = $1; } + /* empty */ { $$.op_type = IS_UNUSED; } + | T_FINALLY { zend_do_finally(&$1 TSRMLS_CC); } '{' inner_statement_list '}' { $$ = $1; } ; additional_catches: diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 1aded4e4a2c28..17dfb5fd81b56 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1187,18 +1187,18 @@ ZEND_VM_HANDLER(81, ZEND_FETCH_DIM_R, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) EX_T(opline->op1.var).var.ptr_ptr) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - - if (OP1_TYPE == IS_TMP_VAR || OP1_TYPE == IS_CONST) { - zval *container = GET_OP1_ZVAL_PTR(BP_VAR_R); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); - FREE_OP2(); - FREE_OP1(); - } else { - container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_R); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); - FREE_OP2(); - FREE_OP1_VAR_PTR(); - } + + if (OP1_TYPE == IS_TMP_VAR || OP1_TYPE == IS_CONST) { + zval *container = GET_OP1_ZVAL_PTR(BP_VAR_R); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); + FREE_OP2(); + FREE_OP1(); + } else { + container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_R); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, GET_OP2_ZVAL_PTR(BP_VAR_R), OP2_TYPE, BP_VAR_R TSRMLS_CC); + FREE_OP2(); + FREE_OP1_VAR_PTR(); + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -2133,9 +2133,9 @@ ZEND_VM_HANDLER(109, ZEND_FETCH_CLASS, ANY, CONST|TMP|VAR|UNUSED|CV) USE_OPLINE SAVE_OPLINE(); - if (EG(exception)) { - zend_exception_save(TSRMLS_C); - } + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (OP2_TYPE == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -2835,7 +2835,7 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) USE_OPLINE zval *retval_ptr; zend_free_op free_op1; - + SAVE_OPLINE(); retval_ptr = GET_OP1_ZVAL_PTR(BP_VAR_R); @@ -2844,9 +2844,9 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) FREE_OP1(); } } else if (!IS_OP1_TMP_FREE()) { /* Not a temp var */ - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (OP1_TYPE == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -2868,9 +2868,9 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) } else { zval *ret; - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); @@ -2878,49 +2878,49 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) } FREE_OP1_IF_VAR(); - if (!(EG(active_op_array)->last_try_catch)) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } } ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) @@ -2933,9 +2933,9 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) SAVE_OPLINE(); do { - if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (OP1_TYPE == IS_CONST || OP1_TYPE == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ @@ -2993,49 +2993,49 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) FREE_OP1_IF_VAR(); - if (!(EG(active_op_array)->last_try_catch)) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } } ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) @@ -3816,7 +3816,7 @@ ZEND_VM_HANDLER(73, ZEND_INCLUDE_OR_EVAL, CONST|TMP|VAR|CV, ANY) zend_op_array *new_op_array=NULL; zend_free_op free_op1; zval *inc_filename; - zval *tmp_inc_filename = NULL; + zval *tmp_inc_filename = NULL; zend_bool failure_retval=0; SAVE_OPLINE(); @@ -5113,14 +5113,14 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) /* further blocks will not be relevant... */ break; } - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; catched = i + 1; } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - finally = i + 1; - } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; + finally = i + 1; + } } while (EX(fbc)) { @@ -5178,28 +5178,28 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) EX(old_error_reporting) = NULL; if (catched && finally) { - if (finally_op_num > catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else { - zend_exception_save(TSRMLS_C); - EX(leaving) = finally; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catched) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally) { - zend_exception_save(TSRMLS_C); - EX(leaving) = finally; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } + if (finally_op_num > catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catched) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally) { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } } ZEND_VM_HANDLER(146, ZEND_VERIFY_ABSTRACT_CLASS, ANY, ANY) @@ -5304,8 +5304,8 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) SAVE_OPLINE(); var_ptr = EX_T(opline->op1.var).var.ptr; if (Z_TYPE_P(var_ptr) != IS_OBJECT && - !PZVAL_IS_REF(var_ptr) && - Z_REFCOUNT_P(var_ptr) > 1) { + !PZVAL_IS_REF(var_ptr) && + Z_REFCOUNT_P(var_ptr) > 1) { Z_DELREF_P(var_ptr); ALLOC_ZVAL(new_zv); @@ -5318,49 +5318,49 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) } ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) { -{ - USE_OPLINE - zend_uint i, op_num = opline - EG(active_op_array)->opcodes; - - SAVE_OPLINE(); - zend_exception_restore(TSRMLS_C); - if (EX(leaving)) { - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(exception)) { - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } else { - ZEND_VM_NEXT_OPCODE(); - } + { + USE_OPLINE + zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + + SAVE_OPLINE(); + zend_exception_restore(TSRMLS_C); + if (EX(leaving)) { + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(exception)) { + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } else { + ZEND_VM_NEXT_OPCODE(); + } } ZEND_VM_EXPORT_HELPER(zend_do_fcall, zend_do_fcall_common_helper) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index c4fe9a92d8c7e..6fd7f0790dc63 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1051,14 +1051,14 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER /* further blocks will not be relevant... */ break; } - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; catched = i + 1; } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - finally = i + 1; - } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; + finally = i + 1; + } } while (EX(fbc)) { @@ -1116,28 +1116,28 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER EX(old_error_reporting) = NULL; if (catched && finally) { - if (finally_op_num > catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else { - zend_exception_save(TSRMLS_C); - EX(leaving) = finally; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catched) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally) { - zend_exception_save(TSRMLS_C); - EX(leaving) = finally; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } + if (finally_op_num > catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catched) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally) { + zend_exception_save(TSRMLS_C); + EX(leaving) = finally; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } } static int ZEND_FASTCALL ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1176,49 +1176,49 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - USE_OPLINE - zend_uint i, op_num = opline - EG(active_op_array)->opcodes; - - SAVE_OPLINE(); - zend_exception_restore(TSRMLS_C); - if (EX(leaving)) { - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(exception)) { - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } else { - ZEND_VM_NEXT_OPCODE(); - } + { + USE_OPLINE + zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + + SAVE_OPLINE(); + zend_exception_restore(TSRMLS_C); + if (EX(leaving)) { + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(exception)) { + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } else { + ZEND_VM_NEXT_OPCODE(); + } } static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1226,9 +1226,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLE USE_OPLINE SAVE_OPLINE(); - if (EG(exception)) { - zend_exception_save(TSRMLS_C); - } + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_CONST == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1529,9 +1529,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ USE_OPLINE SAVE_OPLINE(); - if (EG(exception)) { - zend_exception_save(TSRMLS_C); - } + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_TMP_VAR == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1695,9 +1695,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ USE_OPLINE SAVE_OPLINE(); - if (EG(exception)) { - zend_exception_save(TSRMLS_C); - } + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_VAR == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1861,9 +1861,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDL USE_OPLINE SAVE_OPLINE(); - if (EG(exception)) { - zend_exception_save(TSRMLS_C); - } + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_UNUSED == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -1897,9 +1897,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A USE_OPLINE SAVE_OPLINE(); - if (EG(exception)) { - zend_exception_save(TSRMLS_C); - } + if (EG(exception)) { + zend_exception_save(TSRMLS_C); + } if (IS_CV == IS_UNUSED) { EX_T(opline->result.var).class_entry = zend_fetch_class(NULL, 0, opline->extended_value TSRMLS_CC); CHECK_EXCEPTION(); @@ -2312,9 +2312,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG } } else if (!0) { /* Not a temp var */ - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_CONST == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -2336,58 +2336,58 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG } else { zval *ret; - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2400,9 +2400,9 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); do { - if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_CONST == IS_CONST || IS_CONST == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ @@ -2458,49 +2458,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2700,7 +2700,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HA zend_op_array *new_op_array=NULL; zval *inc_filename; - zval *tmp_inc_filename = NULL; + zval *tmp_inc_filename = NULL; zend_bool failure_retval=0; SAVE_OPLINE(); @@ -3562,17 +3562,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_ PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { - zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { + zval *container = opline->op1.zv; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -4418,17 +4418,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HA PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { - zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); + if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { + zval *container = opline->op1.zv; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -5122,17 +5122,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HA PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { - zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { + zval *container = opline->op1.zv; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -6382,17 +6382,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAN PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { - zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { + zval *container = opline->op1.zv; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -6940,9 +6940,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval_dtor(free_op1.var); } } else if (!1) { /* Not a temp var */ - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_TMP_VAR == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -6964,58 +6964,58 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } else { zval *ret; - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7028,9 +7028,9 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); do { - if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ @@ -7086,49 +7086,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7329,7 +7329,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND zend_op_array *new_op_array=NULL; zend_free_op free_op1; zval *inc_filename; - zval *tmp_inc_filename = NULL; + zval *tmp_inc_filename = NULL; zend_bool failure_retval=0; SAVE_OPLINE(); @@ -8243,17 +8243,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HA PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { + zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op1.var); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op1.var); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -8967,17 +8967,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAND PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); - zval_dtor(free_op1.var); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); + if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { + zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); + zval_dtor(free_op1.var); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -9671,17 +9671,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAND PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - zval_dtor(free_op1.var); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { + zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + zval_dtor(free_op1.var); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -10797,17 +10797,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDL PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { + zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op1.var); - } else { - container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op1.var); + } else { + container = NULL; + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -11473,9 +11473,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else if (!0) { /* Not a temp var */ - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_VAR == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -11497,9 +11497,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } else { zval *ret; - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); @@ -11507,49 +11507,49 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11562,9 +11562,9 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); do { - if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ @@ -11622,49 +11622,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11974,7 +11974,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND zend_op_array *new_op_array=NULL; zend_free_op free_op1; zval *inc_filename; - zval *tmp_inc_filename = NULL; + zval *tmp_inc_filename = NULL; zend_bool failure_retval=0; SAVE_OPLINE(); @@ -13465,17 +13465,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { + zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } else { + container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -15642,17 +15642,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } + if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { + zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } else { + container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -17733,17 +17733,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } + if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { + zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } else { + container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -20094,8 +20094,8 @@ static int ZEND_FASTCALL ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); var_ptr = EX_T(opline->op1.var).var.ptr; if (Z_TYPE_P(var_ptr) != IS_OBJECT && - !PZVAL_IS_REF(var_ptr) && - Z_REFCOUNT_P(var_ptr) > 1) { + !PZVAL_IS_REF(var_ptr) && + Z_REFCOUNT_P(var_ptr) > 1) { Z_DELREF_P(var_ptr); ALLOC_ZVAL(new_zv); @@ -20859,17 +20859,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { + zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } else { + container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - } + if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -27571,9 +27571,9 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } } else if (!0) { /* Not a temp var */ - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_CV == IS_CONST || (PZVAL_IS_REF(retval_ptr) && Z_REFCOUNT_P(retval_ptr) > 0)) { zval *ret; @@ -27595,58 +27595,58 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } else { zval *ret; - if (*EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (*EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } ALLOC_ZVAL(ret); INIT_PZVAL_COPY(ret, retval_ptr); *EG(return_value_ptr_ptr) = ret; } - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27659,9 +27659,9 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); do { - if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { - zval_ptr_dtor(EG(return_value_ptr_ptr)); - } + if (EG(return_value_ptr_ptr) && *EG(return_value_ptr_ptr)) { + zval_ptr_dtor(EG(return_value_ptr_ptr)); + } if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR) { /* Not supposed to happen, but we'll allow it */ @@ -27717,49 +27717,49 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (!(EG(active_op_array)->last_try_catch)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (EG(prev_exception)) { + /* leaving */ + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } + + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); + } else if (finally_op_num) { + EX(leaving) = 1; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + ZEND_VM_CONTINUE(); + } else if (EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } } static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -28057,7 +28057,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL zend_op_array *new_op_array=NULL; zval *inc_filename; - zval *tmp_inc_filename = NULL; + zval *tmp_inc_filename = NULL; zend_bool failure_retval=0; SAVE_OPLINE(); @@ -29401,17 +29401,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { + zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); + } else { + container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -31357,17 +31357,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); + if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { + zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); - } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); - zval_dtor(free_op2.var); + } else { + container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval_dtor(free_op2.var); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -33319,17 +33319,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { + zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); - if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + } else { + container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -36176,17 +36176,17 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); } - if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { + zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + } else { + container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); - } + } CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); From f82be0550b573027b1fb8ef106e7c8efc78878e1 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 14 Aug 2012 14:08:38 +0800 Subject: [PATCH 1997/2394] add test for alone try block, and update test scripts summary --- Zend/tests/try_catch_finally_002.phpt | 2 +- Zend/tests/try_catch_finally_003.phpt | 2 +- Zend/tests/try_catch_finally_004.phpt | 2 +- Zend/tests/try_finally_004.phpt | 14 ++++++++++++++ 4 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 Zend/tests/try_finally_004.phpt diff --git a/Zend/tests/try_catch_finally_002.phpt b/Zend/tests/try_catch_finally_002.phpt index 94143f6fd1eca..79efcb3de8cc4 100644 --- a/Zend/tests/try_catch_finally_002.phpt +++ b/Zend/tests/try_catch_finally_002.phpt @@ -1,5 +1,5 @@ --TEST-- -Try catch finally +Try catch finally catch(multi catch blocks) --FILE-- +--EXPECTF-- +Fatal error: Cannot use try without catch or finally in %stry_finally_004.php on line %d From 154fe7486d55b5bd71dc9ecbac369a48596a3325 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 14 Aug 2012 14:17:27 +0800 Subject: [PATCH 1998/2394] typo --- Zend/tests/try_catch_finally_003.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/tests/try_catch_finally_003.phpt b/Zend/tests/try_catch_finally_003.phpt index e605538c8692f..784063b749025 100644 --- a/Zend/tests/try_catch_finally_003.phpt +++ b/Zend/tests/try_catch_finally_003.phpt @@ -1,5 +1,5 @@ --TEST-- -Try catch finally (multi catch blcoks with return) +Try catch finally (multi catch blocks with return) --FILE-- Date: Wed, 15 Aug 2012 01:03:56 +0800 Subject: [PATCH 1999/2394] Fix intl tests failed because of missing skipif section --- ext/intl/tests/breakiter___construct.phpt | 1 + ext/intl/tests/breakiter_clone_basic.phpt | 4 ++++ ext/intl/tests/breakiter_current_basic.phpt | 4 ++++ ext/intl/tests/breakiter_factories_basic.phpt | 1 + ext/intl/tests/breakiter_factories_error.phpt | 4 ++++ ext/intl/tests/breakiter_first_basic.phpt | 1 + .../tests/breakiter_first_last_previous_current_error.phpt | 4 ++++ ext/intl/tests/breakiter_following_basic.phpt | 4 ++++ .../tests/breakiter_following_preceding_isBoundary_error.phpt | 4 ++++ ext/intl/tests/breakiter_getLocale_basic.phpt | 4 ++++ ext/intl/tests/breakiter_getLocale_error.phpt | 4 ++++ ext/intl/tests/breakiter_getPartsIterator_basic.phpt | 4 ++++ ext/intl/tests/breakiter_getText_basic.phpt | 1 + ext/intl/tests/breakiter_getText_error.phpt | 4 ++++ ext/intl/tests/breakiter_isBoundary_basic.phpt | 4 ++++ ext/intl/tests/breakiter_last_basic.phpt | 1 + ext/intl/tests/breakiter_next_basic.phpt | 4 ++++ ext/intl/tests/breakiter_next_error.phpt | 4 ++++ ext/intl/tests/breakiter_preceding_basic.phpt | 4 ++++ ext/intl/tests/breakiter_previous_basic.phpt | 4 ++++ ext/intl/tests/breakiter_setText_basic.phpt | 1 + ext/intl/tests/breakiter_setText_error.phpt | 4 ++++ ext/intl/tests/dateformat___construct_bad_tz_cal.phpt | 4 ++++ ext/intl/tests/dateformat_create_cal_arg.phpt | 4 ++++ ext/intl/tests/dateformat_getCalendarObject_error.phpt | 4 ++++ ext/intl/tests/dateformat_getTimeZone_error.phpt | 4 ++++ ext/intl/tests/dateformat_get_set_calendar.phpt | 4 ++++ ext/intl/tests/dateformat_get_set_timezone.phpt | 4 ++++ ext/intl/tests/dateformat_setTimeZoneID_deprecation.phpt | 4 ++++ ext/intl/tests/dateformat_setTimeZone_error.phpt | 4 ++++ ext/intl/tests/dateformat_timezone_arg_variations.phpt | 4 ++++ ext/intl/tests/rbbiter___construct_basic.phpt | 4 ++++ ext/intl/tests/rbbiter_getRuleStatusVec_basic.phpt | 4 ++++ ext/intl/tests/rbbiter_getRuleStatus_basic.phpt | 4 ++++ ext/intl/tests/rbbiter_getRules_basic.phpt | 4 ++++ 35 files changed, 122 insertions(+) diff --git a/ext/intl/tests/breakiter___construct.phpt b/ext/intl/tests/breakiter___construct.phpt index 9ea6a9cf11838..a818075a30c2a 100644 --- a/ext/intl/tests/breakiter___construct.phpt +++ b/ext/intl/tests/breakiter___construct.phpt @@ -1,6 +1,7 @@ --TEST-- IntlBreakIterator::__construct() should not be callable --SKIPIF-- + Date: Wed, 15 Aug 2012 14:47:00 +0200 Subject: [PATCH 2000/2394] Try to fix mysqli_field tests Those tests seem to fail when people have a different default collation, so try to fix by specifying utf8_general_ci explicitely. --- ext/mysqli/tests/table.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/tests/table.inc b/ext/mysqli/tests/table.inc index aa1207af444bb..2700c5a5e2419 100644 --- a/ext/mysqli/tests/table.inc +++ b/ext/mysqli/tests/table.inc @@ -12,7 +12,7 @@ if (!mysqli_query($link, 'DROP TABLE IF EXISTS test')) { exit(1); } -if (!mysqli_query($link, 'CREATE TABLE test(id INT, label CHAR(1), PRIMARY KEY(id)) ENGINE=' . $engine)) { +if (!mysqli_query($link, 'CREATE TABLE test(id INT, label CHAR(1) COLLATE utf8_general_ci, PRIMARY KEY(id)) ENGINE=' . $engine)) { printf("Failed to create test table: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); exit(1); } @@ -20,4 +20,4 @@ if (!mysqli_query($link, 'CREATE TABLE test(id INT, label CHAR(1), PRIMARY KEY(i if (!mysqli_query($link, "INSERT INTO test(id, label) VALUES (1, 'a'), (2, 'b'), (3, 'c'), (4, 'd'), (5, 'e'), (6, 'f')")) { printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); } -?> \ No newline at end of file +?> From 0312d0a262e4e15ce49dddaa1b10492aba08ec38 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Thu, 16 Aug 2012 18:17:26 +0800 Subject: [PATCH 2001/2394] Prevents `goto` out of a finally block --- Zend/tests/try_finally_005.phpt | 17 +++++++++++++++++ Zend/tests/try_finally_006.phpt | 18 ++++++++++++++++++ Zend/zend_compile.c | 19 +++++++++++++++++++ 3 files changed, 54 insertions(+) create mode 100644 Zend/tests/try_finally_005.phpt create mode 100644 Zend/tests/try_finally_006.phpt diff --git a/Zend/tests/try_finally_005.phpt b/Zend/tests/try_finally_005.phpt new file mode 100644 index 0000000000000..e0937f1b16b5a --- /dev/null +++ b/Zend/tests/try_finally_005.phpt @@ -0,0 +1,17 @@ +--TEST-- +Finally with long goto +--FILE-- + +--EXPECTF-- +Fatal error: 'goto' out of a finally block is disallowed in %stry_finally_005.php on line %d diff --git a/Zend/tests/try_finally_006.phpt b/Zend/tests/try_finally_006.phpt new file mode 100644 index 0000000000000..ba1c183eb4b3b --- /dev/null +++ b/Zend/tests/try_finally_006.phpt @@ -0,0 +1,18 @@ +--TEST-- +Finally with near goto +--FILE-- + +--EXPECTF-- +label diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 48b85f0b7091c..378cf17bffabf 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2277,6 +2277,25 @@ void zend_resolve_goto_label(zend_op_array *op_array, zend_op *opline, int pass2 zval_dtor(label); Z_TYPE_P(label) = IS_NULL; + if (op_array->last_try_catch) { + zend_uint i, op_num = opline - CG(active_op_array)->opcodes; + for (i=0; ilast_try_catch; i++) { + if (op_array->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num >= op_array->try_catch_array[i].finally_op) { + zend_op *p, *end; + p = opline; + end = op_array->opcodes + opline->op1.opline_num; + while (++p < end) { + if (p->opcode == ZEND_LEAVE) { + zend_error(E_COMPILE_ERROR, "'goto' out of a finally block is disallowed"); + } + } + } + } + } + /* Check that we are not moving into loop or switch */ current = opline->extended_value; for (distance = 0; current != dest->brk_cont; distance++) { From 7014a0eb6d1611151a286c0ff4f2238f92c120d6 Mon Sep 17 00:00:00 2001 From: Sherif Ramadan Date: Thu, 16 Aug 2012 10:21:22 -0400 Subject: [PATCH 2002/2394] Fixed Mcrypt deprecated functions and related tests --- ext/mcrypt/mcrypt.c | 6 ++-- ext/mcrypt/tests/mcrypt_cbc.phpt | 6 ++++ ext/mcrypt/tests/mcrypt_cbc_3des_decrypt.phpt | 14 ++++++++++ ext/mcrypt/tests/mcrypt_cbc_3des_encrypt.phpt | 14 ++++++++++ ext/mcrypt/tests/mcrypt_cbc_error.phpt | 4 +++ ext/mcrypt/tests/mcrypt_cbc_variation1.phpt | 26 +++++++++++++++++ ext/mcrypt/tests/mcrypt_cbc_variation2.phpt | 27 +++++++++++++++++- ext/mcrypt/tests/mcrypt_cbc_variation3.phpt | 27 +++++++++++++++++- ext/mcrypt/tests/mcrypt_cbc_variation4.phpt | 28 ++++++++++++++++++- ext/mcrypt/tests/mcrypt_cbc_variation5.phpt | 26 +++++++++++++++++ ext/mcrypt/tests/mcrypt_cfb.phpt | 6 ++++ ext/mcrypt/tests/mcrypt_ofb.phpt | 10 +++++-- .../tests/mcrypt_rijndael128_128BitKey.phpt | 20 ++++++++++++- 13 files changed, 205 insertions(+), 9 deletions(-) diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c index 20a0f73b187d6..dcac776d024c1 100644 --- a/ext/mcrypt/mcrypt.c +++ b/ext/mcrypt/mcrypt.c @@ -239,9 +239,9 @@ ZEND_END_ARG_INFO() const zend_function_entry mcrypt_functions[] = { /* {{{ */ PHP_DEP_FE(mcrypt_ecb, arginfo_mcrypt_ecb) - PHP_FE(mcrypt_cbc, arginfo_mcrypt_cbc) - PHP_FE(mcrypt_cfb, arginfo_mcrypt_cfb) - PHP_FE(mcrypt_ofb, arginfo_mcrypt_ofb) + PHP_DEP_FE(mcrypt_cbc, arginfo_mcrypt_cbc) + PHP_DEP_FE(mcrypt_cfb, arginfo_mcrypt_cfb) + PHP_DEP_FE(mcrypt_ofb, arginfo_mcrypt_ofb) PHP_FE(mcrypt_get_key_size, arginfo_mcrypt_get_key_size) PHP_FE(mcrypt_get_block_size, arginfo_mcrypt_get_block_size) PHP_FE(mcrypt_get_cipher_name, arginfo_mcrypt_get_cipher_name) diff --git a/ext/mcrypt/tests/mcrypt_cbc.phpt b/ext/mcrypt/tests/mcrypt_cbc.phpt index f9160db011b7b..27cc5b2224404 100644 --- a/ext/mcrypt/tests/mcrypt_cbc.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc.phpt @@ -18,6 +18,12 @@ echo trim(mcrypt_cbc($cipher, $key, $enc_data, MCRYPT_DECRYPT, $iv)) . "\n"; mcrypt_cbc($cipher, $key, $enc_data, MCRYPT_DECRYPT); --EXPECTF-- + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d PHP Testfest 2008 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): Attempt to use an empty IV, which is NOT recommend in %s on line %d diff --git a/ext/mcrypt/tests/mcrypt_cbc_3des_decrypt.phpt b/ext/mcrypt/tests/mcrypt_cbc_3des_decrypt.phpt index 6df3079935306..67799a3fdd976 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_3des_decrypt.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_3des_decrypt.phpt @@ -72,16 +72,24 @@ function special_var_dump($str) { --- testing different key lengths key length=8 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(32) "736563726574206d6573736167650000" key length=20 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(32) "736563726574206d6573736167650000" key length=24 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(32) "736563726574206d6573736167650000" key length=26 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): Size of key is too large for this algorithm in %s on line %d string(32) "736563726574206d6573736167650000" @@ -89,14 +97,20 @@ string(32) "736563726574206d6573736167650000" iv length=4 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(32) "736563726574206d6573736167650000" iv length=8 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(32) "736563726574206d6573736167650000" iv length=9 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(32) "736563726574206d6573736167650000" ===DONE=== diff --git a/ext/mcrypt/tests/mcrypt_cbc_3des_encrypt.phpt b/ext/mcrypt/tests/mcrypt_cbc_3des_encrypt.phpt index 35fabd9aca770..1af094c27b04c 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_3des_encrypt.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_3des_encrypt.phpt @@ -55,16 +55,24 @@ foreach ($ivs as $iv) { --- testing different key lengths key length=8 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(112) "082b437d039d09418e20dc9de1dafa7ed6da5c6335b78950968441da1faf40c1f886e04da8ca177b80b376811e138c1bf51cb48dae2e7939" key length=20 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(112) "0627351e0f8a082bf7981ae2c700a43fd3d44b270ac67b00fded1c5796eea935be0fef2a23da0b3f5e243929e62ac957bf0bf463aa90fc4f" key length=24 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(112) "b85e21072239d60c63a80e7c9ae493cb741a1cd407e52f451c5f43a0d103f55a7b62617eb2e44213c2d44462d388bc0b8f119384b12c84ac" key length=26 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): Size of key is too large for this algorithm in %s on line %d string(112) "b85e21072239d60c63a80e7c9ae493cb741a1cd407e52f451c5f43a0d103f55a7b62617eb2e44213c2d44462d388bc0b8f119384b12c84ac" @@ -72,14 +80,20 @@ string(112) "b85e21072239d60c63a80e7c9ae493cb741a1cd407e52f451c5f43a0d103f55a7b6 iv length=4 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(112) "440a6f54601969b127aad3c217ce7583c7f7b29989693130645569301db0020b29a34a3dcd104b2d0e3ba19d6cbd8a33d352b9c27cc34ef1" iv length=8 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(112) "bac347506bf092c5557c4363c301745d78f047028e2953e84fd66b30aeb6005812dadbe8baa871b83278341599b0c448ddaaa52b5a378ce5" iv length=9 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(112) "440a6f54601969b127aad3c217ce7583c7f7b29989693130645569301db0020b29a34a3dcd104b2d0e3ba19d6cbd8a33d352b9c27cc34ef1" ===DONE=== diff --git a/ext/mcrypt/tests/mcrypt_cbc_error.phpt b/ext/mcrypt/tests/mcrypt_cbc_error.phpt index ec3912b03fc39..3c221802147e4 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_error.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_error.phpt @@ -41,11 +41,15 @@ var_dump( mcrypt_cbc($cipher, $key, $data) ); -- Testing mcrypt_cbc() function with more than expected no. of arguments -- +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc() expects at most 5 parameters, 6 given in %s on line %d NULL -- Testing mcrypt_cbc() function with less than expected no. of arguments -- +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc() expects at least 4 parameters, 3 given in %s on line %d NULL ===DONE=== diff --git a/ext/mcrypt/tests/mcrypt_cbc_variation1.phpt b/ext/mcrypt/tests/mcrypt_cbc_variation1.phpt index 5482de3e20ace..eb233e3f92e90 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_variation1.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_variation1.phpt @@ -124,106 +124,132 @@ fclose($fp); *** Testing mcrypt_cbc() : usage variation *** --int 0-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --int 1-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --int 12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --int -12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --float 10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --float -10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --float 12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --float -12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --float .5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --empty array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 1 to be string, array given, %s(%d) NULL --int indexed array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 1 to be string, array given, %s(%d) NULL --associative array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 1 to be string, array given, %s(%d) NULL --nested arrays-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 1 to be string, array given, %s(%d) NULL --uppercase NULL-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --lowercase null-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --lowercase true-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --lowercase false-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --uppercase TRUE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --uppercase FALSE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --empty string DQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --empty string SQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --instance of classWithToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --instance of classWithoutToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 1 to be string, object given, %s(%d) NULL --undefined var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --unset var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): Module initialization failed, %s(%d) bool(false) --resource-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 1 to be string, resource given, %s(%d) NULL ===DONE=== diff --git a/ext/mcrypt/tests/mcrypt_cbc_variation2.phpt b/ext/mcrypt/tests/mcrypt_cbc_variation2.phpt index f49e80ee9379c..3d2a0614722d4 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_variation2.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_variation2.phpt @@ -124,87 +124,112 @@ fclose($fp); *** Testing mcrypt_cbc() : usage variation *** --int 0-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "bc27b3a4e33b531d5983fc7df693cd09" --int 1-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "bc27b3a4e33b531d5983fc7df693cd09" --int 12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "d109b7973383127002474ae731c4b3a8" --int -12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "3e82a931cedb03a38b91a637ff8c9f9e" --float 10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "de71833586c1d7132a289960ebeeca7a" --float -10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "7d0489dd2e99ae910ecc015573f3dd16" --float 12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "978055b42c0506a8947e3c3c8d994baf" --float -12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "4aa84ba400c2b8ef467d4d98372b4f4e" --float .5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "e731dc5059b84e0c8774ac490f77d6e6" --empty array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 2 to be string, array given, %s(%d) string(0) "" --int indexed array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 2 to be string, array given, %s(%d) string(0) "" --associative array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 2 to be string, array given, %s(%d) string(0) "" --nested arrays-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 2 to be string, array given, %s(%d) string(0) "" --uppercase NULL-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --lowercase null-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --lowercase true-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "bc27b3a4e33b531d5983fc7df693cd09" --lowercase false-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --uppercase TRUE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "bc27b3a4e33b531d5983fc7df693cd09" --uppercase FALSE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --empty string DQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --empty string SQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --instance of classWithToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "19420fa26f561ee82ed84abbcd2d284b" --instance of classWithoutToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 2 to be string, object given, %s(%d) string(0) "" --undefined var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --unset var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "be722a5ffc361d721fbcab1eacc6acf5" --resource-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 2 to be string, resource given, %s(%d) string(0) "" ===DONE=== - diff --git a/ext/mcrypt/tests/mcrypt_cbc_variation3.phpt b/ext/mcrypt/tests/mcrypt_cbc_variation3.phpt index 5b2398ddbda2f..9a1464b1122cc 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_variation3.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_variation3.phpt @@ -124,87 +124,112 @@ fclose($fp); *** Testing mcrypt_cbc() : usage variation *** --int 0-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "ce5fcfe737859795" --int 1-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "84df495f6cd82dd9" --int 12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "905ab1ae27ee9991" --int -12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "5835174e9c67c3e7" --float 10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "28ff0601ad9e47fa" --float -10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "ce9f2b6e2fc3d9f7" --float 12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "24eb882ce9763e4018fba9b7f01b0c3e" --float -12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5eed30e428f32de1d7a7064d0ed4d3eb" --float .5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "bebf2a13676e1e30" --empty array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 3 to be string, array given, %s(%d) string(0) "" --int indexed array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 3 to be string, array given, %s(%d) string(0) "" --associative array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 3 to be string, array given, %s(%d) string(0) "" --nested arrays-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 3 to be string, array given, %s(%d) string(0) "" --uppercase NULL-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --lowercase null-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --lowercase true-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "84df495f6cd82dd9" --lowercase false-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --uppercase TRUE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "84df495f6cd82dd9" --uppercase FALSE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --empty string DQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --empty string SQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --instance of classWithToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "7c91cdf8f8c51485034a9ee528eb016b" --instance of classWithoutToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 3 to be string, object given, %s(%d) string(0) "" --undefined var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --unset var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(16) "206f6d3617a5ab32" --resource-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 3 to be string, resource given, %s(%d) string(0) "" ===DONE=== - diff --git a/ext/mcrypt/tests/mcrypt_cbc_variation4.phpt b/ext/mcrypt/tests/mcrypt_cbc_variation4.phpt index f9a511f390083..a3dd29ba41b05 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_variation4.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_variation4.phpt @@ -124,82 +124,108 @@ fclose($fp); *** Testing mcrypt_cbc() : usage variation *** --float 10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --float -10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --float 12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --float -12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --float .5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --empty array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --int indexed array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --associative array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --nested arrays-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --uppercase NULL-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --lowercase null-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --lowercase true-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --lowercase false-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --uppercase TRUE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --uppercase FALSE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --empty string DQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --empty string SQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --string DQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --string SQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --mixed case string-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --heredoc-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --instance of classWithToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 8 - Object of class classWithToString could not be converted to int, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --instance of classWithoutToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 8 - Object of class classWithoutToString could not be converted to int, %s(%d) string(32) "983d5edc5f77fe42e2372a0339dc22b0" --undefined var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --unset var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) string(32) "5f781523f696d596e4b809d72197a0cc" --resource-- -string(%d) %s +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) +string(32) "983d5edc5f77fe42e2372a0339dc22b0" ===DONE=== diff --git a/ext/mcrypt/tests/mcrypt_cbc_variation5.phpt b/ext/mcrypt/tests/mcrypt_cbc_variation5.phpt index 7d49db853d36f..0c75c97934104 100644 --- a/ext/mcrypt/tests/mcrypt_cbc_variation5.phpt +++ b/ext/mcrypt/tests/mcrypt_cbc_variation5.phpt @@ -124,106 +124,132 @@ fclose($fp); *** Testing mcrypt_cbc() : usage variation *** --int 0-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --int 1-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --int 12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --int -12345-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --float 10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --float -10.5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --float 12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --float -12.3456789000e10-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --float .5-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --empty array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 5 to be string, array given, %s(%d) string(0) "" --int indexed array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 5 to be string, array given, %s(%d) string(0) "" --associative array-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 5 to be string, array given, %s(%d) string(0) "" --nested arrays-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 5 to be string, array given, %s(%d) string(0) "" --uppercase NULL-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --lowercase null-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --lowercase true-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --lowercase false-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --uppercase TRUE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --uppercase FALSE-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --empty string DQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --empty string SQ-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --instance of classWithToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --instance of classWithoutToString-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 5 to be string, object given, %s(%d) string(0) "" --undefined var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --unset var-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc(): The IV parameter must be as long as the blocksize, %s(%d) string(32) "6438db90653c4d3080c3ceab43618c05" --resource-- +Error: 8192 - Function mcrypt_cbc() is deprecated, %s(%d) Error: 2 - mcrypt_cbc() expects parameter 5 to be string, resource given, %s(%d) string(0) "" ===DONE=== diff --git a/ext/mcrypt/tests/mcrypt_cfb.phpt b/ext/mcrypt/tests/mcrypt_cfb.phpt index 54919c858971c..11120633a5e82 100644 --- a/ext/mcrypt/tests/mcrypt_cfb.phpt +++ b/ext/mcrypt/tests/mcrypt_cfb.phpt @@ -18,6 +18,12 @@ echo trim(mcrypt_cfb($cipher, $key, $enc_data, MCRYPT_DECRYPT, $iv)) . "\n"; mcrypt_cfb($cipher, $key, $enc_data, MCRYPT_DECRYPT); --EXPECTF-- + +Deprecated: Function mcrypt_cfb() is deprecated in %s on line %d + +Deprecated: Function mcrypt_cfb() is deprecated in %s on line %d PHP Testfest 2008 +Deprecated: Function mcrypt_cfb() is deprecated in %s on line %d + Warning: mcrypt_cfb(): Attempt to use an empty IV, which is NOT recommend in %s on line %d diff --git a/ext/mcrypt/tests/mcrypt_ofb.phpt b/ext/mcrypt/tests/mcrypt_ofb.phpt index 1532c4cf29f82..942035306035a 100644 --- a/ext/mcrypt/tests/mcrypt_ofb.phpt +++ b/ext/mcrypt/tests/mcrypt_ofb.phpt @@ -17,5 +17,11 @@ echo trim(mcrypt_ofb($cipher, $key, $enc_data, MCRYPT_DECRYPT, $iv)) . "\n"; // a warning must be issued if we don't use a IV on a AES cipher, that usually requires an IV mcrypt_ofb($cipher, $key, $enc_data, MCRYPT_DECRYPT, $iv); ---EXPECT-- -PHP Testfest 2008 \ No newline at end of file +--EXPECTF-- + +Deprecated: Function mcrypt_ofb() is deprecated in %s on line %d + +Deprecated: Function mcrypt_ofb() is deprecated in %s on line %d +PHP Testfest 2008 + +Deprecated: Function mcrypt_ofb() is deprecated in %s on line %d diff --git a/ext/mcrypt/tests/mcrypt_rijndael128_128BitKey.phpt b/ext/mcrypt/tests/mcrypt_rijndael128_128BitKey.phpt index 100352a1c7e34..e450a69047e1d 100644 --- a/ext/mcrypt/tests/mcrypt_rijndael128_128BitKey.phpt +++ b/ext/mcrypt/tests/mcrypt_rijndael128_128BitKey.phpt @@ -76,24 +76,34 @@ foreach ($ivs as $iv) { key length=0 string(128) "4fbf24aaa789f5194260ade1acd9499402c1845cc517e8fe43cfb5b90a0df294db33ecd1a836c47d6bf6d8600512ba415e17008a1e1991f81056258d82099397" + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" key length=0 string(128) "4fbf24aaa789f5194260ade1acd9499402c1845cc517e8fe43cfb5b90a0df294db33ecd1a836c47d6bf6d8600512ba415e17008a1e1991f81056258d82099397" + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" key length=8 string(128) "d6a3042b278fa5816dc6f46152acbe5fd7d1813c3808c27cd969d8e10a64d0238724edfda0322f4512308f22d142df0e92bed861c2b732f7650e234df59183dc" + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" key length=16 string(128) "dc8f957ec530acf10cd95ba7da7b6405380fe19a2941e9a8de54680512f18491bc374e5464885ae6c2ae2aa7a6cdd2fbe12a06bbc4bd59dbbfaa15f09044f101" + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" --- testing different iv lengths iv length=0 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(128) "c082b3fabaae4c8c410eb8dba64bae10e48d79b5241fb8f24462cad43bd0b35ad2746b00817e9dcbc636b44df0ec60b46a57e7a310a308a0947724e3817a13b4" @@ -102,6 +112,8 @@ string(128) "546869732069732074686520736563726574206d657373616765207768696368206 iv length=0 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(128) "c082b3fabaae4c8c410eb8dba64bae10e48d79b5241fb8f24462cad43bd0b35ad2746b00817e9dcbc636b44df0ec60b46a57e7a310a308a0947724e3817a13b4" @@ -110,6 +122,8 @@ string(128) "546869732069732074686520736563726574206d657373616765207768696368206 iv length=8 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(128) "c082b3fabaae4c8c410eb8dba64bae10e48d79b5241fb8f24462cad43bd0b35ad2746b00817e9dcbc636b44df0ec60b46a57e7a310a308a0947724e3817a13b4" @@ -117,14 +131,18 @@ Warning: mcrypt_decrypt(): The IV parameter must be as long as the blocksize in string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" iv length=16 + +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d string(128) "dc8f957ec530acf10cd95ba7da7b6405380fe19a2941e9a8de54680512f18491bc374e5464885ae6c2ae2aa7a6cdd2fbe12a06bbc4bd59dbbfaa15f09044f101" string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" iv length=17 +Deprecated: Function mcrypt_cbc() is deprecated in %s on line %d + Warning: mcrypt_cbc(): The IV parameter must be as long as the blocksize in %s on line %d string(128) "c082b3fabaae4c8c410eb8dba64bae10e48d79b5241fb8f24462cad43bd0b35ad2746b00817e9dcbc636b44df0ec60b46a57e7a310a308a0947724e3817a13b4" Warning: mcrypt_decrypt(): The IV parameter must be as long as the blocksize in %s on line %d string(128) "546869732069732074686520736563726574206d657373616765207768696368206d75737420626520656e637279707465640000000000000000000000000000" -===DONE=== \ No newline at end of file +===DONE=== From acd402d4e78ce25e80d19aa564bed1329dcc4ddc Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Thu, 16 Aug 2012 23:01:58 +0800 Subject: [PATCH 2003/2394] typo --- Zend/zend_compile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 378cf17bffabf..d7ca6eab33f6f 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2278,7 +2278,7 @@ void zend_resolve_goto_label(zend_op_array *op_array, zend_op *opline, int pass2 Z_TYPE_P(label) = IS_NULL; if (op_array->last_try_catch) { - zend_uint i, op_num = opline - CG(active_op_array)->opcodes; + zend_uint i, op_num = opline - op_array->opcodes; for (i=0; ilast_try_catch; i++) { if (op_array->try_catch_array[i].try_op > op_num) { break; From fc26aa7f3e223ab8e3d5c07b4b0c6dd3cf09cb83 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 16 Aug 2012 17:10:05 +0200 Subject: [PATCH 2004/2394] Adjust UPGRADING/NEWS for additional mcrypt deprecations --- NEWS | 4 ++++ UPGRADING | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 58eeabd37f2bc..b71945087ff11 100644 --- a/NEWS +++ b/NEWS @@ -55,6 +55,10 @@ PHP NEWS - Hash . Added support for PBKDF2 via hash_pbkdf2(). (Anthony Ferrara) +- MCrypt + . mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw + E_DEPRECATED. (GoogleGuy) + - MySQLi . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. Known for stability problems. (Andrey) diff --git a/UPGRADING b/UPGRADING index f95ab4962b176..aeab14b48fce9 100755 --- a/UPGRADING +++ b/UPGRADING @@ -98,7 +98,9 @@ PHP X.Y UPGRADE NOTES instead. - IntlDateFormatter::format() and datefmt_format() now also accept an IntlCalendar object for formatting. -- Deprecated mcrypt_ecb() made to produce E_DEPRECATED. +- mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw + E_DEPRECATED. Their use was already previously discouraged in the docs, + but that predated the existence of E_DEPRECATED. - php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and zend_logo_guid() have been removed From 9a38bd66c87e8f6e1ac8e28014bb42686d5742d3 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 16 Aug 2012 17:46:34 +0200 Subject: [PATCH 2005/2394] Fix php_ini_loaded_file() test If running ./run-tests.php directly there isn't necessarily an ini file, so the function can also return false. --- ext/standard/tests/php_ini_loaded_file.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/tests/php_ini_loaded_file.phpt b/ext/standard/tests/php_ini_loaded_file.phpt index 747e0196f19f4..7d441582eeb17 100644 --- a/ext/standard/tests/php_ini_loaded_file.phpt +++ b/ext/standard/tests/php_ini_loaded_file.phpt @@ -10,5 +10,5 @@ precision=12 ---EXPECTF-- -string(%d) "%sphp.ini" +--EXPECTREGEX-- +string\(\d+\) ".*php\.ini"|bool\(false\) From b5305d267b6c3b1b09ab0ba4ecf4f66edc5d4077 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 16 Aug 2012 19:02:39 +0200 Subject: [PATCH 2006/2394] Fix curl_basic_022.phpt Some curl versions seem to have issues handling dates beyond Thu, 31-Dec-2037 23:59:59 GMT (dates after this are just clamped to MAX_INT). --- ext/curl/tests/curl_basic_022.phpt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/curl/tests/curl_basic_022.phpt b/ext/curl/tests/curl_basic_022.phpt index 6a611af590c2c..d4277a3f89966 100644 --- a/ext/curl/tests/curl_basic_022.phpt +++ b/ext/curl/tests/curl_basic_022.phpt @@ -11,15 +11,15 @@ if ($curl_version['version_number'] < 0x070e01) { --EXPECT-- array(2) { [0]=> - string(38) ".php.net TRUE / FALSE 2147368447 C1 v1" + string(38) ".php.net TRUE / FALSE 2145916799 C1 v1" [1]=> - string(38) ".php.net TRUE / FALSE 2147368447 C2 v2" + string(38) ".php.net TRUE / FALSE 2145916799 C2 v2" } From 8cccc5c37d0113a0560410435126cb3032dd22a7 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 16 Aug 2012 21:30:58 +0200 Subject: [PATCH 2007/2394] Revert "Try to fix mysqli_field tests" This reverts commit 018395efafeb8cbce0b8864ca4a1eac232db1cbb. This change didn't really make sense in hindsight. Looking for some other fix. --- ext/mysqli/tests/table.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqli/tests/table.inc b/ext/mysqli/tests/table.inc index 2700c5a5e2419..aa1207af444bb 100644 --- a/ext/mysqli/tests/table.inc +++ b/ext/mysqli/tests/table.inc @@ -12,7 +12,7 @@ if (!mysqli_query($link, 'DROP TABLE IF EXISTS test')) { exit(1); } -if (!mysqli_query($link, 'CREATE TABLE test(id INT, label CHAR(1) COLLATE utf8_general_ci, PRIMARY KEY(id)) ENGINE=' . $engine)) { +if (!mysqli_query($link, 'CREATE TABLE test(id INT, label CHAR(1), PRIMARY KEY(id)) ENGINE=' . $engine)) { printf("Failed to create test table: [%d] %s\n", mysqli_errno($link), mysqli_error($link)); exit(1); } @@ -20,4 +20,4 @@ if (!mysqli_query($link, 'CREATE TABLE test(id INT, label CHAR(1) COLLATE utf8_g if (!mysqli_query($link, "INSERT INTO test(id, label) VALUES (1, 'a'), (2, 'b'), (3, 'c'), (4, 'd'), (5, 'e'), (6, 'f')")) { printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); } -?> +?> \ No newline at end of file From 24493652382c985b13a9ed94aae5fffae16a6895 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 17 Aug 2012 21:18:20 +0800 Subject: [PATCH 2008/2394] Fixed context info in error message --- Zend/zend_compile.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index d7ca6eab33f6f..bad9411a2f46f 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2289,6 +2289,11 @@ void zend_resolve_goto_label(zend_op_array *op_array, zend_op *opline, int pass2 end = op_array->opcodes + opline->op1.opline_num; while (++p < end) { if (p->opcode == ZEND_LEAVE) { + if (pass2) { + CG(in_compilation) = 1; + CG(active_op_array) = op_array; + CG(zend_lineno) = opline->lineno; + } zend_error(E_COMPILE_ERROR, "'goto' out of a finally block is disallowed"); } } From f2a8912e618d4bd8ff5be266e37f2b6e2280e994 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 18 Aug 2012 00:16:34 +0800 Subject: [PATCH 2009/2394] Refactor examing of jumping out of finally block --- Zend/tests/try_finally_005.phpt | 2 +- Zend/tests/try_finally_006.phpt | 14 +++++++++++--- Zend/tests/try_finally_007.phpt | 22 ++++++++++++++++++++++ Zend/tests/try_finally_008.phpt | 24 ++++++++++++++++++++++++ Zend/zend_compile.c | 30 +++--------------------------- Zend/zend_compile.h | 3 ++- Zend/zend_opcode.c | 17 +++++++++++++++++ 7 files changed, 80 insertions(+), 32 deletions(-) create mode 100644 Zend/tests/try_finally_007.phpt create mode 100644 Zend/tests/try_finally_008.phpt diff --git a/Zend/tests/try_finally_005.phpt b/Zend/tests/try_finally_005.phpt index e0937f1b16b5a..2c6c2c9e6ce45 100644 --- a/Zend/tests/try_finally_005.phpt +++ b/Zend/tests/try_finally_005.phpt @@ -14,4 +14,4 @@ label: foo(); ?> --EXPECTF-- -Fatal error: 'goto' out of a finally block is disallowed in %stry_finally_005.php on line %d +Fatal error: jump out of a finally block is disallowed in %stry_finally_005.php on line %d diff --git a/Zend/tests/try_finally_006.phpt b/Zend/tests/try_finally_006.phpt index ba1c183eb4b3b..2bfa4caea9c39 100644 --- a/Zend/tests/try_finally_006.phpt +++ b/Zend/tests/try_finally_006.phpt @@ -3,12 +3,19 @@ Finally with near goto --FILE-- --EXPECTF-- label +okey diff --git a/Zend/tests/try_finally_007.phpt b/Zend/tests/try_finally_007.phpt new file mode 100644 index 0000000000000..b13bd59e508bb --- /dev/null +++ b/Zend/tests/try_finally_007.phpt @@ -0,0 +1,22 @@ +--TEST-- +Finally with goto previous label +--FILE-- + +--EXPECTF-- +Fatal error: jump out of a finally block is disallowed in %stry_finally_007.php on line %d diff --git a/Zend/tests/try_finally_008.phpt b/Zend/tests/try_finally_008.phpt new file mode 100644 index 0000000000000..77ecf4fdeeece --- /dev/null +++ b/Zend/tests/try_finally_008.phpt @@ -0,0 +1,24 @@ +--TEST-- +Finally with jmp (do while) +--FILE-- + +--EXPECTF-- +Fatal error: jump out of a finally block is disallowed in %stry_finally_008.php on line %d diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index bad9411a2f46f..6a501f78a5df5 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2277,30 +2277,6 @@ void zend_resolve_goto_label(zend_op_array *op_array, zend_op *opline, int pass2 zval_dtor(label); Z_TYPE_P(label) = IS_NULL; - if (op_array->last_try_catch) { - zend_uint i, op_num = opline - op_array->opcodes; - for (i=0; ilast_try_catch; i++) { - if (op_array->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num >= op_array->try_catch_array[i].finally_op) { - zend_op *p, *end; - p = opline; - end = op_array->opcodes + opline->op1.opline_num; - while (++p < end) { - if (p->opcode == ZEND_LEAVE) { - if (pass2) { - CG(in_compilation) = 1; - CG(active_op_array) = op_array; - CG(zend_lineno) = opline->lineno; - } - zend_error(E_COMPILE_ERROR, "'goto' out of a finally block is disallowed"); - } - } - } - } - } - /* Check that we are not moving into loop or switch */ current = opline->extended_value; for (distance = 0; current != dest->brk_cont; distance++) { @@ -2686,6 +2662,7 @@ static int zend_add_try_element(zend_uint try_op TSRMLS_DC) /* {{{ */ CG(active_op_array)->try_catch_array = erealloc(CG(active_op_array)->try_catch_array, sizeof(zend_try_catch_element)*CG(active_op_array)->last_try_catch); CG(active_op_array)->try_catch_array[try_catch_offset].try_op = try_op; CG(active_op_array)->try_catch_array[try_catch_offset].finally_op = 0; + CG(active_op_array)->try_catch_array[try_catch_offset].finally_end = 0; return try_catch_offset; } /* }}} */ @@ -2808,14 +2785,13 @@ void zend_do_bind_catch(znode *try_token, znode *catch_token TSRMLS_DC) /* {{{ * void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_token TSRMLS_DC) /* {{{ */ { - zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); - if (catch_token->op_type == IS_UNUSED && finally_token->op_type == IS_UNUSED) { zend_error(E_COMPILE_ERROR, "Cannot use try without catch or finally"); } if (finally_token->op_type != IS_UNUSED) { + zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; - //try_token->u.op.opline_num = catch_token->u.op.opline_num; + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_end = get_next_op_number(CG(active_op_array)); opline->opcode = ZEND_LEAVE; SET_UNUSED(opline->op1); diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 550fb0e9318dc..a06c985a97901 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -132,7 +132,8 @@ typedef struct _zend_label { typedef struct _zend_try_catch_element { zend_uint try_op; zend_uint catch_op; /* ketchup! */ - zend_uint finally_op; + zend_uint finally_op; + zend_uint finally_end; } zend_try_catch_element; #if SIZEOF_LONG == 8 diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 19fd71e763d09..8cccfe637684c 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -528,6 +528,23 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) } /* break omitted intentionally */ case ZEND_JMP: + if (op_array->last_try_catch) { + zend_uint i, op_num = opline - op_array->opcodes; + for (i=0; i < op_array->last_try_catch; i++) { + if (op_array->try_catch_array[i].try_op > op_num) { + break; + } + if ((op_num >= op_array->try_catch_array[i].finally_op + && op_num < op_array->try_catch_array[i].finally_end) + && (opline->op1.opline_num >= op_array->try_catch_array[i].finally_end + || opline->op1.opline_num < op_array->try_catch_array[i].finally_op)) { + CG(in_compilation) = 1; + CG(active_op_array) = op_array; + CG(zend_lineno) = opline->lineno; + zend_error(E_COMPILE_ERROR, "jump out of a finally block is disallowed"); + } + } + } opline->op1.jmp_addr = &op_array->opcodes[opline->op1.opline_num]; break; case ZEND_JMPZ: From 294e7c295fe55372fb93d4dbbf3ccb7ac785cb4a Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 17 Aug 2012 15:17:29 +0200 Subject: [PATCH 2010/2394] Annother attempt at fixing the mysqli_fetch_field tests Instead of character set detection (which doesn't always work correctly) fetch the character set info using mysqli_get_charset(). To make sure that the returned info applies to all of client, connection and result explicitely set utf8 as charset using mysqli_set_charset() before. I'm not sure whether that last part is really necessary, but included it to be safe. --- ext/mysqli/tests/connect.inc | 93 ------------------- ext/mysqli/tests/mysqli_fetch_field.phpt | 22 +++-- ext/mysqli/tests/mysqli_fetch_field_oo.phpt | 21 +++-- ext/mysqli/tests/mysqli_fetch_fields.phpt | 20 ++-- ext/mysqli/tests/mysqli_field_seek.phpt | 22 +++-- ..._stmt_get_result_metadata_fetch_field.phpt | 21 +++-- 6 files changed, 64 insertions(+), 135 deletions(-) diff --git a/ext/mysqli/tests/connect.inc b/ext/mysqli/tests/connect.inc index 3a9d8ec258c8c..4acc20cb9195c 100644 --- a/ext/mysqli/tests/connect.inc +++ b/ext/mysqli/tests/connect.inc @@ -129,99 +129,6 @@ } } - function my_get_charsets($link) { - - /* Those tree are set by SET NAMES */ - $charsets = array( - 'client' => NULL, - 'results' => NULL, - 'connection' => NULL, - ); - - if (!($res = mysqli_query($link, "SHOW VARIABLES LIKE '%character%'"))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - - $names = array(); - while ($row = mysqli_fetch_assoc($res)) { - $names[$row['Variable_name']] = $row['Value']; - } - mysqli_free_result($res); - - if (!($res = mysqli_query($link, sprintf("SHOW CHARACTER SET LIKE '%s'", $names['character_set_client']))) || - !($details = mysqli_fetch_assoc($res))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - mysqli_free_result($res); - - $charsets['client'] = array( - 'charset' => $details['Charset'], - 'desc' => $details['Description'], - 'collation' => $details['Default collation'], - 'maxlen' => $details['Maxlen'], - 'nr' => NULL, - ); - - if (!($res = mysqli_query($link, sprintf("SHOW COLLATION LIKE '%s'", $details['Default collation']))) || - !($collation = mysqli_fetch_assoc($res))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - mysqli_free_result($res); - $charsets['client']['nr'] = $collation['Id']; - - if (!($res = mysqli_query($link, sprintf("SHOW CHARACTER SET LIKE '%s'", $names['character_set_results']))) || - !($details = mysqli_fetch_assoc($res))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - mysqli_free_result($res); - - $charsets['results'] = array( - 'charset' => $details['Charset'], - 'desc' => $details['Description'], - 'collation' => $details['Default collation'], - 'maxlen' => $details['Maxlen'], - 'nr' => NULL, - ); - - if (!($res = mysqli_query($link, sprintf("SHOW COLLATION LIKE '%s'", $details['Default collation']))) || - !($collation = mysqli_fetch_assoc($res))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - mysqli_free_result($res); - $charsets['results']['nr'] = $collation['Id']; - - - if (!($res = mysqli_query($link, sprintf("SHOW CHARACTER SET LIKE '%s'", $names['character_set_connection']))) || - !($details = mysqli_fetch_assoc($res))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - mysqli_free_result($res); - - $charsets['connection'] = array( - 'charset' => $details['Charset'], - 'desc' => $details['Description'], - 'collation' => $details['Default collation'], - 'maxlen' => $details['Maxlen'], - 'nr' => NULL, - ); - - if (!($res = mysqli_query($link, sprintf("SHOW COLLATION LIKE '%s'", $details['Default collation']))) || - !($collation = mysqli_fetch_assoc($res))) { - printf("[%d] %s\n", mysqli_errno($link), mysqli_error($link)); - return $charsets; - } - mysqli_free_result($res); - $charsets['connection']['nr'] = $collation['Id']; - - return $charsets; - } - function have_innodb($link) { if (($res = $link->query("SHOW VARIABLES LIKE 'have_innodb'")) && ($row = $res->fetch_row()) && diff --git a/ext/mysqli/tests/mysqli_fetch_field.phpt b/ext/mysqli/tests/mysqli_fetch_field.phpt index d1d358b342183..2b9108072b413 100644 --- a/ext/mysqli/tests/mysqli_fetch_field.phpt +++ b/ext/mysqli/tests/mysqli_fetch_field.phpt @@ -22,7 +22,13 @@ require_once('skipifconnectfailure.inc'); require('table.inc'); - $charsets = my_get_charsets($link); + // Make sure that client, connection and result charsets are all the + // same. Not sure whether this is strictly necessary. + if (!mysqli_set_charset($link, 'utf8')) + printf("[%d] %s\n", mysqli_errno($link), mysqli_errno($link)); + + $charsetInfo = mysqli_get_charset($link); + if (!$res = mysqli_query($link, "SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 1")) { printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); } @@ -34,19 +40,17 @@ require_once('skipifconnectfailure.inc'); /* label column, result set charset */ $tmp = mysqli_fetch_field($res); var_dump($tmp); - if ($tmp->charsetnr != $charsets['results']['nr']) { + if ($tmp->charsetnr != $charsetInfo->number) { printf("[004] Expecting charset %s/%d got %d\n", - $charsets['results']['charset'], - $charsets['results']['nr'], $tmp->charsetnr); + $charsetInfo->charset, $charsetInfo->number, $tmp->charsetnr); } - if ($tmp->length != (1 * $charsets['results']['maxlen'])) { + if ($tmp->length != $charsetInfo->max_length) { printf("[005] Expecting length %d got %d\n", - $charsets['results']['maxlen'], - $tmp->max_length); + $charsetInfo->max_length, $tmp->max_length); } if ($tmp->db != $db) { printf("011] Expecting database '%s' got '%s'\n", - $db, $tmp->db); + $db, $tmp->db); } var_dump(mysqli_fetch_field($res)); @@ -174,4 +178,4 @@ object(stdClass)#%d (13) { [%u|b%"decimals"]=> int(0) } -done! \ No newline at end of file +done! diff --git a/ext/mysqli/tests/mysqli_fetch_field_oo.phpt b/ext/mysqli/tests/mysqli_fetch_field_oo.phpt index 2d5ad261b1315..8c5609b163d2e 100644 --- a/ext/mysqli/tests/mysqli_fetch_field_oo.phpt +++ b/ext/mysqli/tests/mysqli_fetch_field_oo.phpt @@ -27,7 +27,12 @@ require_once('skipifconnectfailure.inc'); if (!is_null($tmp = @$res->fetch_field($link))) printf("[003] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp); - $charsets = my_get_charsets($link); + // Make sure that client, connection and result charsets are all the + // same. Not sure whether this is strictly necessary. + if (!$mysqli->set_charset('utf8')) + printf("[%d] %s\n", $mysqli->errno, $mysqli->errno); + + $charsetInfo = $mysqli->get_charset(); if (!$res = $mysqli->query("SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 1")) { printf("[004] [%d] %s\n", $mysqli->errno, $mysqli->error); @@ -37,18 +42,16 @@ require_once('skipifconnectfailure.inc'); $tmp = $res->fetch_field(); var_dump($tmp); - if ($tmp->charsetnr != $charsets['results']['nr']) { + if ($tmp->charsetnr != $charsetInfo->number) { printf("[005] Expecting charset %s/%d got %d\n", - $charsets['results']['charset'], - $charsets['results']['nr'], $tmp->charsetnr); + $charsetInfo->charset, $charsetInfo->number, $tmp->charsetnr); } - if ($tmp->length != (1 * $charsets['results']['maxlen'])) { + if ($tmp->length != $charsetInfo->max_length) { printf("[006] Expecting length %d got %d\n", - $charsets['results']['maxlen'], - $tmp->max_length); + $charsetInfo->max_length, $tmp->max_length); } if ($tmp->db != $db) { - printf("008] Expecting database '%s' got '%s'\n", + printf("[007] Expecting database '%s' got '%s'\n", $db, $tmp->db); } @@ -126,4 +129,4 @@ object(stdClass)#%d (13) { bool(false) Warning: mysqli_result::fetch_field(): Couldn't fetch mysqli_result in %s on line %d -done! \ No newline at end of file +done! diff --git a/ext/mysqli/tests/mysqli_fetch_fields.phpt b/ext/mysqli/tests/mysqli_fetch_fields.phpt index 479c71cbbc5a8..6b66d6f231f33 100644 --- a/ext/mysqli/tests/mysqli_fetch_fields.phpt +++ b/ext/mysqli/tests/mysqli_fetch_fields.phpt @@ -21,7 +21,13 @@ require_once('skipifconnectfailure.inc'); printf("[002] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp); require('table.inc'); - $charsets = my_get_charsets($link); + + // Make sure that client, connection and result charsets are all the + // same. Not sure whether this is strictly necessary. + if (!mysqli_set_charset($link, 'utf8')) + printf("[%d] %s\n", mysqli_errno($link), mysqli_errno($link)); + + $charsetInfo = mysqli_get_charset($link); if (!$res = mysqli_query($link, "SELECT id AS ID, label FROM test AS TEST ORDER BY id LIMIT 1")) { printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); @@ -33,14 +39,14 @@ require_once('skipifconnectfailure.inc'); switch ($k) { case 1: /* label column, result set charset */ - if ($field->charsetnr != $charsets['results']['nr']) { + if ($field->charsetnr != $charsetInfo->number) { printf("[004] Expecting charset %s/%d got %d\n", - $charsets['results']['charset'], - $charsets['results']['nr'], $field->charsetnr); + $charsetInfo->charset, + $charsetInfo->number, $field->charsetnr); } - if ($field->length != (1 * $charsets['results']['maxlen'])) { + if ($field->length != $charsetInfo->max_length) { printf("[005] Expecting length %d got %d\n", - $charsets['results']['maxlen'], + $charsetInfo->max_length, $field->max_length); } break; @@ -118,4 +124,4 @@ object(stdClass)#%d (13) { } Warning: mysqli_fetch_fields(): Couldn't fetch mysqli_result in %s on line %d -done! \ No newline at end of file +done! diff --git a/ext/mysqli/tests/mysqli_field_seek.phpt b/ext/mysqli/tests/mysqli_field_seek.phpt index a747bdfa019a3..449d2f90d4155 100644 --- a/ext/mysqli/tests/mysqli_field_seek.phpt +++ b/ext/mysqli/tests/mysqli_field_seek.phpt @@ -66,7 +66,13 @@ require_once('skipifconnectfailure.inc'); printf("[002] Expecting NULL, got %s/%s\n", gettype($tmp), $tmp); require('table.inc'); - $charsets = my_get_charsets($link); + + // Make sure that client, connection and result charsets are all the + // same. Not sure whether this is strictly necessary. + if (!mysqli_set_charset($link, 'utf8')) + printf("[%d] %s\n", mysqli_errno($link), mysqli_errno($link)); + + $charsetInfo = mysqli_get_charset($link); if (!$res = mysqli_query($link, "SELECT id, label FROM test ORDER BY id LIMIT 1", MYSQLI_USE_RESULT)) { printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); @@ -81,15 +87,13 @@ require_once('skipifconnectfailure.inc'); $field = mysqli_fetch_field($res); var_dump($field); /* label column, result set charset */ - if ($field->charsetnr != $charsets['results']['nr']) { + if ($field->charsetnr != $charsetInfo->number) { printf("[004] Expecting charset %s/%d got %d\n", - $charsets['results']['charset'], - $charsets['results']['nr'], $field->charsetnr); + $charsetInfo->charset, $charsetInfo->number, $field->charsetnr); } - if ($field->length != (1 * $charsets['results']['maxlen'])) { + if ($field->length != $charsetInfo->max_length) { printf("[005] Expecting length %d got %d\n", - $charsets['results']['maxlen'], - $field->max_length); + $charsetInfo->max_length, $field->max_length); } var_dump(mysqli_field_tell($res)); @@ -217,7 +221,7 @@ bool(false) Warning: mysqli_field_seek(): Invalid field offset in %s on line %d bool(false) bool(true) -object(stdClass)#3 (13) { +object(stdClass)#%d (13) { [%u|b%"name"]=> %unicode|string%(5) "_null" [%u|b%"orgname"]=> @@ -248,4 +252,4 @@ object(stdClass)#3 (13) { Warning: mysqli_field_seek(): Couldn't fetch mysqli_result in %s on line %d NULL -done! \ No newline at end of file +done! diff --git a/ext/mysqli/tests/mysqli_stmt_get_result_metadata_fetch_field.phpt b/ext/mysqli/tests/mysqli_stmt_get_result_metadata_fetch_field.phpt index afaccaf3c7a53..739bf56ea150d 100644 --- a/ext/mysqli/tests/mysqli_stmt_get_result_metadata_fetch_field.phpt +++ b/ext/mysqli/tests/mysqli_stmt_get_result_metadata_fetch_field.phpt @@ -12,7 +12,13 @@ if (!function_exists('mysqli_stmt_get_result')) --FILE-- charsetnr != $charsets['results']['nr']) { + if ($field->charsetnr != $charsetInfo->number) { printf("[004] Expecting charset %s/%d got %d\n", - $charsets['results']['charset'], - $charsets['results']['nr'], $field->charsetnr); + $charsetInfo->charset, + $charsetInfo->number, $field->charsetnr); } - if ($field->length != (1 * $charsets['results']['maxlen'])) { + if ($field->length != $charsetInfo->max_length) { printf("[005] Expecting length %d got %d\n", - $charsets['results']['maxlen'], - $field->max_length); + $charsetInfo->max_length, $field->max_length); } } } @@ -173,4 +178,4 @@ object(stdClass)#%d (13) { [%u|b%"decimals"]=> int(31) } -done! \ No newline at end of file +done! From 72b9b8f380690357fc29efdfcba183b8a8a81268 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 18 Aug 2012 11:44:09 +0800 Subject: [PATCH 2011/2394] Make the codes clearer, and also check continue statement --- Zend/tests/try_finally_008.phpt | 5 +--- Zend/tests/try_finally_009.phpt | 23 +++++++++++++++ Zend/zend_opcode.c | 52 ++++++++++++++++++++++++--------- Zend/zend_vm_def.h | 6 ++-- Zend/zend_vm_execute.h | 4 +-- 5 files changed, 67 insertions(+), 23 deletions(-) create mode 100644 Zend/tests/try_finally_009.phpt diff --git a/Zend/tests/try_finally_008.phpt b/Zend/tests/try_finally_008.phpt index 77ecf4fdeeece..9025d8824dac3 100644 --- a/Zend/tests/try_finally_008.phpt +++ b/Zend/tests/try_finally_008.phpt @@ -7,15 +7,12 @@ function foo () { try { try { } finally { - goto label; - echo "dummy"; + break; } } catch (Exception $e) { } finally { } } while (0); -label: - echo "label"; } foo(); diff --git a/Zend/tests/try_finally_009.phpt b/Zend/tests/try_finally_009.phpt new file mode 100644 index 0000000000000..7c3da6760b6ae --- /dev/null +++ b/Zend/tests/try_finally_009.phpt @@ -0,0 +1,23 @@ +--TEST-- +Finally with jmp (for continue) +--FILE-- + +--EXPECTF-- +Fatal error: jump out of a finally block is disallowed in %stry_finally_009.php on line %d diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 8cccfe637684c..86144d60e18ff 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -485,6 +485,24 @@ static void zend_extension_op_array_handler(zend_extension *extension, zend_op_a } } +static void zend_check_finally_breakout(zend_op_array *op_array, zend_op *opline, zend_uint dst_num TSRMLS_DC) { + zend_uint i, op_num = opline - op_array->opcodes; + for (i=0; i < op_array->last_try_catch; i++) { + if (op_array->try_catch_array[i].try_op > op_num) { + break; + } + if ((op_num >= op_array->try_catch_array[i].finally_op + && op_num < op_array->try_catch_array[i].finally_end) + && (dst_num >= op_array->try_catch_array[i].finally_end + || dst_num < op_array->try_catch_array[i].finally_op)) { + CG(in_compilation) = 1; + CG(active_op_array) = op_array; + CG(zend_lineno) = opline->lineno; + zend_error(E_COMPILE_ERROR, "jump out of a finally block is disallowed"); + } + } +} + ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) { zend_op *opline, *end; @@ -528,24 +546,30 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) } /* break omitted intentionally */ case ZEND_JMP: + if (op_array->last_try_catch) { + zend_check_finally_breakout(op_array, opline, opline->op1.opline_num TSRMLS_CC); + } + opline->op1.jmp_addr = &op_array->opcodes[opline->op1.opline_num]; + break; + case ZEND_BRK: + case ZEND_CONT: if (op_array->last_try_catch) { zend_uint i, op_num = opline - op_array->opcodes; - for (i=0; i < op_array->last_try_catch; i++) { - if (op_array->try_catch_array[i].try_op > op_num) { - break; + int nest_levels, array_offset; + zend_brk_cont_element *jmp_to; + + nest_levels = Z_LVAL_P(opline->op2.zv); + array_offset = opline->op1.opline_num; + do { + jmp_to = &op_array->brk_cont_array[array_offset]; + if (nest_levels > 1) { + array_offset = jmp_to->parent; } - if ((op_num >= op_array->try_catch_array[i].finally_op - && op_num < op_array->try_catch_array[i].finally_end) - && (opline->op1.opline_num >= op_array->try_catch_array[i].finally_end - || opline->op1.opline_num < op_array->try_catch_array[i].finally_op)) { - CG(in_compilation) = 1; - CG(active_op_array) = op_array; - CG(zend_lineno) = opline->lineno; - zend_error(E_COMPILE_ERROR, "jump out of a finally block is disallowed"); - } - } + } while (--nest_levels > 0); + if (op_array->last_try_catch) { + zend_check_finally_breakout(op_array, opline, jmp_to->brk TSRMLS_CC); + } } - opline->op1.jmp_addr = &op_array->opcodes[opline->op1.opline_num]; break; case ZEND_JMPZ: case ZEND_JMPNZ: diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 17dfb5fd81b56..1da4c12440a38 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5317,10 +5317,10 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) { - { +ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) +{ USE_OPLINE - zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + zend_uint i, op_num = opline - EG(active_op_array)->opcodes; SAVE_OPLINE(); zend_exception_restore(TSRMLS_C); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 6fd7f0790dc63..b5a649d0a2732 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1176,9 +1176,9 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) - { +{ USE_OPLINE - zend_uint i, op_num = opline - EG(active_op_array)->opcodes; + zend_uint i, op_num = opline - EG(active_op_array)->opcodes; SAVE_OPLINE(); zend_exception_restore(TSRMLS_C); From 57e7c7bd49dae25f2d3ec935b5e264d0fb62b6b3 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 18 Aug 2012 11:57:53 +0800 Subject: [PATCH 2012/2394] tab --- Zend/zend_compile.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index a06c985a97901..8919fdc6b802b 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -80,7 +80,7 @@ typedef union _znode_op { zend_op *jmp_addr; zval *zv; zend_literal *literal; - void *ptr; /* Used for passing pointers from the compile to execution phase, currently used for traits */ + void *ptr; /* Used for passing pointers from the compile to execution phase, currently used for traits */ } znode_op; typedef struct _znode { /* used only during compilation */ From b2a74b5bdb5fe66a59969cb2aa87931958ca56d3 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 18 Aug 2012 11:28:00 -0300 Subject: [PATCH 2013/2394] - Remove unused vars --- Zend/zend_opcode.c | 1 - 1 file changed, 1 deletion(-) diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 86144d60e18ff..7cbc15b0b089b 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -554,7 +554,6 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) case ZEND_BRK: case ZEND_CONT: if (op_array->last_try_catch) { - zend_uint i, op_num = opline - op_array->opcodes; int nest_levels, array_offset; zend_brk_cont_element *jmp_to; From 2b685075b57cd0d0ed83d0566a97c81824f95063 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 19 Aug 2012 11:35:18 -0300 Subject: [PATCH 2014/2394] - Remove unused variable --- ext/standard/pack.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ext/standard/pack.c b/ext/standard/pack.c index 61228a63df783..9894746f7767f 100644 --- a/ext/standard/pack.c +++ b/ext/standard/pack.c @@ -676,7 +676,6 @@ PHP_FUNCTION(unpack) switch ((int) type) { case 'a': { /* a will not strip any trailing whitespace or null padding */ - char pad = ' '; int len = inputlen - inputpos; /* Remaining string */ /* If size was given take minimum of len and size */ From 5ee3bf16474bd94f4813714491742fb17e258d18 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 19 Aug 2012 21:43:16 -0700 Subject: [PATCH 2015/2394] add finally --- ext/tokenizer/tokenizer_data.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index 85822f1994085..a915bb8eacca0 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -21,7 +21,7 @@ /* DO NOT EDIT THIS FILE! This file is generated using tokenizer_data_gen.sh -*/ +*/ #include "php.h" #include "zend.h" @@ -110,6 +110,7 @@ void tokenizer_register_constants(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("T_RETURN", T_RETURN, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_TRY", T_TRY, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_CATCH", T_CATCH, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("T_FINALLY", T_FINALLY, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_THROW", T_THROW, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_USE", T_USE, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("T_INSTEADOF", T_INSTEADOF, CONST_CS | CONST_PERSISTENT); @@ -244,6 +245,7 @@ char *get_token_type_name(int token_type) case T_RETURN: return "T_RETURN"; case T_TRY: return "T_TRY"; case T_CATCH: return "T_CATCH"; + case T_FINALLY: return "T_FINALLY"; case T_THROW: return "T_THROW"; case T_USE: return "T_USE"; case T_INSTEADOF: return "T_INSTEADOF"; From 591c59d9bf09ead5605e30d71db6ff1351fa0d50 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 19 Aug 2012 21:46:29 -0700 Subject: [PATCH 2016/2394] add heredoc parsing fix --- NEWS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/NEWS b/NEWS index b71945087ff11..f4df4463fa782 100644 --- a/NEWS +++ b/NEWS @@ -70,6 +70,9 @@ PHP NEWS - pgsql . Added pg_escape_literal() and pg_escape_identifier() (Yasuo) +- Tokenizer: + . Fixed bug #60097 (token_get_all fails to lex nested heredoc). (Nikita Popov) + - Zip: . Upgraded libzip to 0.10.1 (Anatoliy) From 05f10480c556ebe52bbef52cb2da5a0aca8ee070 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 20 Aug 2012 12:53:18 +0200 Subject: [PATCH 2017/2394] Drop Generator::close() method --- Zend/tests/generators/clone_with_foreach.phpt | 2 +- Zend/tests/generators/clone_with_stack.phpt | 2 +- .../generators/clone_with_symbol_table.phpt | 2 +- Zend/tests/generators/clone_with_this.phpt | 2 +- .../generators/close_inside_generator.phpt | 22 ------------- Zend/tests/generators/generator_close.phpt | 32 ------------------- .../generators/yield_during_method_call.phpt | 4 +-- Zend/zend_generators.c | 30 ----------------- Zend/zend_generators.h | 4 --- 9 files changed, 6 insertions(+), 94 deletions(-) delete mode 100644 Zend/tests/generators/close_inside_generator.phpt delete mode 100644 Zend/tests/generators/generator_close.phpt diff --git a/Zend/tests/generators/clone_with_foreach.phpt b/Zend/tests/generators/clone_with_foreach.phpt index b887338036562..b05ed073120dc 100644 --- a/Zend/tests/generators/clone_with_foreach.phpt +++ b/Zend/tests/generators/clone_with_foreach.phpt @@ -20,7 +20,7 @@ $g2->next(); var_dump($g1->current()); var_dump($g2->current()); -$g1->close(); +unset($g1); $g2->next(); var_dump($g2->current()); diff --git a/Zend/tests/generators/clone_with_stack.phpt b/Zend/tests/generators/clone_with_stack.phpt index 673c0e5d1e7eb..5a8e6d842ca8e 100644 --- a/Zend/tests/generators/clone_with_stack.phpt +++ b/Zend/tests/generators/clone_with_stack.phpt @@ -10,7 +10,7 @@ function gen() { $g1 = gen(); $g1->rewind(); $g2 = clone $g1; -$g1->close(); +unset($g1); $g2->send(10); ?> diff --git a/Zend/tests/generators/clone_with_symbol_table.phpt b/Zend/tests/generators/clone_with_symbol_table.phpt index 0d1bd4ec3c426..e1fefebd8fa42 100644 --- a/Zend/tests/generators/clone_with_symbol_table.phpt +++ b/Zend/tests/generators/clone_with_symbol_table.phpt @@ -19,7 +19,7 @@ function gen() { $g1 = gen(); $g1->rewind(); $g2 = clone $g1; -$g1->close(); +unset($g1); $g2->next(); ?> diff --git a/Zend/tests/generators/clone_with_this.phpt b/Zend/tests/generators/clone_with_this.phpt index 66efd02987d77..b242d851ebec5 100644 --- a/Zend/tests/generators/clone_with_this.phpt +++ b/Zend/tests/generators/clone_with_this.phpt @@ -16,7 +16,7 @@ class Test { $g1 = (new Test)->gen(); $g1->rewind(); // goto yield $g2 = clone $g1; -$g1->close(); +unset($g1); $g2->next(); ?> diff --git a/Zend/tests/generators/close_inside_generator.phpt b/Zend/tests/generators/close_inside_generator.phpt deleted file mode 100644 index 1df64bf6b1abe..0000000000000 --- a/Zend/tests/generators/close_inside_generator.phpt +++ /dev/null @@ -1,22 +0,0 @@ ---TEST-- -Calling close() during the exectution of the generator ---FILE-- -close(); - - echo "Still running"; -} - -$gen = gen(); -$gen->send($gen); - -?> ---EXPECTF-- -Warning: A generator cannot be closed while it is running in %s on line %d -Still running diff --git a/Zend/tests/generators/generator_close.phpt b/Zend/tests/generators/generator_close.phpt deleted file mode 100644 index 3dec285409ff2..0000000000000 --- a/Zend/tests/generators/generator_close.phpt +++ /dev/null @@ -1,32 +0,0 @@ ---TEST-- -Generator can be closed by calling ->close() ---FILE-- -close(); - } -} - -?> ---EXPECT-- -int(0) -int(1) -int(2) -int(3) -int(4) -int(5) -int(6) -int(7) -int(8) -int(9) diff --git a/Zend/tests/generators/yield_during_method_call.phpt b/Zend/tests/generators/yield_during_method_call.phpt index e8859ac0c27ed..5fbe84fff559b 100644 --- a/Zend/tests/generators/yield_during_method_call.phpt +++ b/Zend/tests/generators/yield_during_method_call.phpt @@ -20,13 +20,13 @@ $gen->send('foo'); // test resource cleanup $gen = gen(); $gen->rewind(); -$gen->close(); +unset($gen); // test cloning $g1 = gen(); $g1->rewind(); $g2 = clone $g1; -$g1->close(); +unset($g1); $g2->send('bar'); ?> diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 716b0a782edd1..41c6dfcd946be 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -301,8 +301,6 @@ static zend_object_value zend_generator_create(zend_class_entry *class_type TSRM /* The key will be incremented on first use, so it'll start at 0 */ generator->largest_used_integer_key = -1; - generator->is_currently_running = 0; - zend_object_std_init(&generator->std, class_type TSRMLS_CC); object.handle = zend_objects_store_put(generator, NULL, @@ -391,8 +389,6 @@ static void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ zend_class_entry *original_scope = EG(scope); zend_class_entry *original_called_scope = EG(called_scope); - zend_bool original_is_currently_running = generator->is_currently_running; - /* Remember the current stack position so we can back up pushed args */ generator->original_stack_top = zend_vm_stack_top(TSRMLS_C); @@ -417,8 +413,6 @@ static void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ EG(scope) = generator->execute_data->current_scope; EG(called_scope) = generator->execute_data->current_called_scope; - generator->is_currently_running = 1; - /* We want the backtrace to look as if the generator function was * called from whatever method we are current running (e.g. next()). * The first prev_execute_data contains an additional stack frame, @@ -440,8 +434,6 @@ static void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ EG(scope) = original_scope; EG(called_scope) = original_called_scope; - generator->is_currently_running = original_is_currently_running; - /* The stack top before and after the execution differ, i.e. there are * arguments pushed to the stack. */ if (generator->original_stack_top != zend_vm_stack_top(TSRMLS_C)) { @@ -598,27 +590,6 @@ ZEND_METHOD(Generator, send) } } -/* {{{ proto void Generator::close() - * Closes the generator */ -ZEND_METHOD(Generator, close) -{ - zend_generator *generator; - - if (zend_parse_parameters_none() == FAILURE) { - return; - } - - generator = (zend_generator *) zend_object_store_get_object(getThis() TSRMLS_CC); - - if (generator->is_currently_running) { - zend_error(E_WARNING, "A generator cannot be closed while it is running"); - return; - } - - zend_generator_close(generator, 0 TSRMLS_CC); -} -/* }}} */ - /* get_iterator implementation */ typedef struct _zend_generator_iterator { @@ -747,7 +718,6 @@ static const zend_function_entry generator_functions[] = { ZEND_ME(Generator, key, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_ME(Generator, next, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_ME(Generator, send, arginfo_generator_send, ZEND_ACC_PUBLIC) - ZEND_ME(Generator, close, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_FE_END }; diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index d67ea4137bf88..f58dafdb1f0c3 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -46,10 +46,6 @@ typedef struct _zend_generator { temp_variable *send_target; /* Largest used integer key for auto-incrementing keys */ long largest_used_integer_key; - - /* We need to know whether the generator is currently executed to avoid it - * being closed while still running */ - zend_bool is_currently_running; } zend_generator; extern ZEND_API zend_class_entry *zend_ce_generator; From 9003cd142553384c3d271b12407186d5352868ad Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 20 Aug 2012 13:28:36 +0200 Subject: [PATCH 2018/2394] Fix zts build (typo) --- Zend/zend_generators.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index f58dafdb1f0c3..f5f4926e353f2 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -51,7 +51,7 @@ typedef struct _zend_generator { extern ZEND_API zend_class_entry *zend_ce_generator; void zend_register_generator_ce(TSRMLS_D); -zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_CC); +zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC); void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC); END_EXTERN_C() From f45a0f31c8354947c0e2b9ea44a63fc0a2c23a01 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 20 Aug 2012 16:01:16 +0200 Subject: [PATCH 2019/2394] Disallow serialization and unserialization --- .../errors/serialize_unserialize_error.phpt | 46 +++++++++++++++++++ Zend/zend_generators.c | 32 ++++++++++--- 2 files changed, 72 insertions(+), 6 deletions(-) create mode 100644 Zend/tests/generators/errors/serialize_unserialize_error.phpt diff --git a/Zend/tests/generators/errors/serialize_unserialize_error.phpt b/Zend/tests/generators/errors/serialize_unserialize_error.phpt new file mode 100644 index 0000000000000..a8470b0a63ab8 --- /dev/null +++ b/Zend/tests/generators/errors/serialize_unserialize_error.phpt @@ -0,0 +1,46 @@ +--TEST-- +Generators can't be serialized or unserialized +--FILE-- + +--EXPECTF-- +exception 'Exception' with message 'Serialization of 'Generator' is not allowed' in %s:%d +Stack trace: +#0 %s(%d): serialize(Object(Generator)) +#1 {main} + +exception 'Exception' with message 'Unserialization of 'Generator' is not allowed' in %s:%d +Stack trace: +#0 [internal function]: Generator->__wakeup() +#1 %s(%d): unserialize('O:9:"Generator"...') +#2 {main} + + +Notice: unserialize(): Error at offset 19 of 20 bytes in %s on line %d +exception 'Exception' with message 'Unserialization of 'Generator' is not allowed' in %s:%d +Stack trace: +#0 %s(%d): unserialize('C:9:"Generator"...') +#1 {main} diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 41c6dfcd946be..b4d8932b6bbfd 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -590,6 +590,23 @@ ZEND_METHOD(Generator, send) } } + +/* {{{ proto void Generator::__wakeup + * Throws an Exception as generators can't be serialized */ +ZEND_METHOD(Generator, __wakeup) +{ + /* Just specifying the zend_class_unserialize_deny handler is not enough, + * because it is only invoked for C unserialization. For O the error has + * to be thrown in __wakeup. */ + + if (zend_parse_parameters_none() == FAILURE) { + return; + } + + zend_throw_exception(NULL, "Unserialization of 'Generator' is not allowed", 0 TSRMLS_CC); +} +/* }}} */ + /* get_iterator implementation */ typedef struct _zend_generator_iterator { @@ -712,12 +729,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_generator_send, 0, 0, 1) ZEND_END_ARG_INFO() static const zend_function_entry generator_functions[] = { - ZEND_ME(Generator, rewind, arginfo_generator_void, ZEND_ACC_PUBLIC) - ZEND_ME(Generator, valid, arginfo_generator_void, ZEND_ACC_PUBLIC) - ZEND_ME(Generator, current, arginfo_generator_void, ZEND_ACC_PUBLIC) - ZEND_ME(Generator, key, arginfo_generator_void, ZEND_ACC_PUBLIC) - ZEND_ME(Generator, next, arginfo_generator_void, ZEND_ACC_PUBLIC) - ZEND_ME(Generator, send, arginfo_generator_send, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, rewind, arginfo_generator_void, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, valid, arginfo_generator_void, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, current, arginfo_generator_void, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, key, arginfo_generator_void, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, next, arginfo_generator_void, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, send, arginfo_generator_send, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, __wakeup, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_FE_END }; @@ -729,6 +747,8 @@ void zend_register_generator_ce(TSRMLS_D) /* {{{ */ zend_ce_generator = zend_register_internal_class(&ce TSRMLS_CC); zend_ce_generator->ce_flags |= ZEND_ACC_FINAL_CLASS; zend_ce_generator->create_object = zend_generator_create; + zend_ce_generator->serialize = zend_class_serialize_deny; + zend_ce_generator->unserialize = zend_class_unserialize_deny; /* get_iterator has to be assigned *after* implementing the inferface */ zend_class_implements(zend_ce_generator TSRMLS_CC, 1, zend_ce_iterator); From 33d872d9f3fff72f496a018a19e02ab632ccadbb Mon Sep 17 00:00:00 2001 From: Popa Marius Adrian Date: Mon, 20 Aug 2012 17:25:56 +0300 Subject: [PATCH 2020/2394] skip test for bug 43130 on firebird , not relevant --- ext/pdo/tests/bug_43130.phpt | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/pdo/tests/bug_43130.phpt b/ext/pdo/tests/bug_43130.phpt index a35138a07ff6f..70f8887111c1f 100644 --- a/ext/pdo/tests/bug_43130.phpt +++ b/ext/pdo/tests/bug_43130.phpt @@ -8,6 +8,7 @@ if (false == $dir) die('skip no driver'); if (!strncasecmp(getenv('PDOTEST_DSN'), 'sqlite', strlen('sqlite'))) die('skip not relevant for sqlite driver'); if (!strncasecmp(getenv('PDOTEST_DSN'), 'pgsql', strlen('pgsql'))) die('skip not relevant for pgsql driver'); if (!strncasecmp(getenv('PDOTEST_DSN'), 'oci', strlen('oci'))) die('skip not relevant for oci driver - Hyphen is not legal for bind names in Oracle DB'); +if (!strncasecmp(getenv('PDOTEST_DSN'), 'firebird', strlen('firebird'))) die('skip not relevant for firebird driver'); require_once $dir . 'pdo_test.inc'; PDOTest::skip(); ?> From 18bb426587d62f93c54c40bf8535eb8416603629 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Mon, 20 Aug 2012 23:42:31 +0200 Subject: [PATCH 2021/2394] Bug 62462: Prevent multibyte characters from being split between the lines Merged from https://github.com/php/php-src/pull/120 --- ext/standard/quot_print.c | 7 +++++-- ext/standard/tests/strings/bug62462.phpt | 17 +++++++++++++++++ 2 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 ext/standard/tests/strings/bug62462.phpt diff --git a/ext/standard/quot_print.c b/ext/standard/quot_print.c index 1ce7eff05284c..4eb69d7ef212d 100644 --- a/ext/standard/quot_print.c +++ b/ext/standard/quot_print.c @@ -162,7 +162,10 @@ PHPAPI unsigned char *php_quot_print_encode(const unsigned char *str, size_t len lp = 0; } else { if (iscntrl (c) || (c == 0x7f) || (c & 0x80) || (c == '=') || ((c == ' ') && (*str == '\015'))) { - if ((lp += 3) > PHP_QPRINT_MAXL) { + if ((((lp+= 3) > PHP_QPRINT_MAXL) && (c <= 0x7f)) + || ((c > 0x7f) && (c <= 0xdf) && ((lp + 3) > PHP_QPRINT_MAXL)) + || ((c > 0xdf) && (c <= 0xef) && ((lp + 6) > PHP_QPRINT_MAXL)) + || ((c > 0xef) && (c <= 0xf4) && ((lp + 9) > PHP_QPRINT_MAXL))) { *d++ = '='; *d++ = '\015'; *d++ = '\012'; @@ -283,4 +286,4 @@ PHP_FUNCTION(quoted_printable_encode) * End: * vim600: sw=4 ts=4 fdm=marker * vim<600: sw=4 ts=4 - */ + */ \ No newline at end of file diff --git a/ext/standard/tests/strings/bug62462.phpt b/ext/standard/tests/strings/bug62462.phpt new file mode 100644 index 0000000000000..c6eb41a543ef5 --- /dev/null +++ b/ext/standard/tests/strings/bug62462.phpt @@ -0,0 +1,17 @@ +--TEST-- +Multibyte characters shouldn't be split by soft line break added by quoted_printable_encode - 4 byte character test +--FILE-- + + +==DONE== +--EXPECT-- +=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85= +=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85= +=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85= +=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85= +=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85= +=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85=C4=85= +=C4=85=C4=85=C4=85=C4=85=C4=85 +==DONE== From a45e81d093e830c25aed13480091049c901c38ec Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Tue, 21 Aug 2012 10:08:46 +0200 Subject: [PATCH 2022/2394] Bug 62462: adjusting test --- .../strings/quoted_printable_encode_002.phpt | Bin 7290 -> 7292 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/ext/standard/tests/strings/quoted_printable_encode_002.phpt b/ext/standard/tests/strings/quoted_printable_encode_002.phpt index 5380eb0bffe85046be0654f80a2cdd91897cb739..aaf5608f333402cf06b3657cd8fedd4d941e1877 100644 GIT binary patch delta 401 zcmexm@yBArSw<#Z-OU#n!5GG)6M@`|LJpJHvvUGj2RWQ3%Y*eg y@B@_?0u6O!2PsM9bDV6z%?@Ne5OD@72AOh!3#ueh7^Gx4JLn;o`sN%lJ~jYGmuqnV delta 308 zcmexk@ylYvSw Date: Tue, 21 Aug 2012 13:36:58 +0200 Subject: [PATCH 2023/2394] Bump version. --- Zend/zend.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend.h b/Zend/zend.h index 39bf5be512fcf..de2a2e595e89b 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -22,7 +22,7 @@ #ifndef ZEND_H #define ZEND_H -#define ZEND_VERSION "2.4.0" +#define ZEND_VERSION "2.5.0-dev" #define ZEND_ENGINE_2 From 703a4e390de277afb85d722a0792912d0b2d2d46 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 22 Aug 2012 13:51:44 +0800 Subject: [PATCH 2024/2394] stash --- Zend/zend_compile.c | 1 + Zend/zend_compile.h | 4 +- Zend/zend_opcode.c | 1 + Zend/zend_vm_def.h | 292 ++++++++++++--------- Zend/zend_vm_execute.h | 572 ++++++++++++++--------------------------- 5 files changed, 362 insertions(+), 508 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 33d1d377ca66e..2ae8cc510f390 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2792,6 +2792,7 @@ void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_to zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_end = get_next_op_number(CG(active_op_array)); + CG(active_op_array)->has_finally_block = 1; opline->opcode = ZEND_LEAVE; SET_UNUSED(opline->op1); diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 8919fdc6b802b..80e02ab3098b8 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -281,6 +281,7 @@ struct _zend_op_array { zend_try_catch_element *try_catch_array; int last_try_catch; + zend_bool has_finally_block; /* static variables support */ HashTable *static_variables; @@ -383,7 +384,8 @@ struct _zend_execute_data { zend_class_entry *current_called_scope; zval *current_this; zval *current_object; - zend_bool leaving; + zend_uint leaving; + zend_uint leaving_dest; }; #define EX(element) execute_data.element diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 7cbc15b0b089b..2552d2ebd64ab 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -87,6 +87,7 @@ void init_op_array(zend_op_array *op_array, zend_uchar type, int initial_ops_siz op_array->static_variables = NULL; op_array->last_try_catch = 0; + op_array->has_finally_block = 0; op_array->this_var = -1; diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 1da4c12440a38..d921f81efc607 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2878,49 +2878,10 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) } FREE_OP1_IF_VAR(); - if (!(EG(active_op_array)->last_try_catch)) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } + if (EG(active_op_array)->has_finally_block) { + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); + } + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) @@ -2993,49 +2954,10 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) FREE_OP1_IF_VAR(); - if (!(EG(active_op_array)->last_try_catch)) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } + if (EG(active_op_array)->has_finally_block) { + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN_BY_REF); + } + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) @@ -3370,6 +3292,93 @@ ZEND_VM_HANDLER(52, ZEND_BOOL, CONST|TMP|VAR|CV, ANY) ZEND_VM_NEXT_OPCODE(); } +ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) +{ + USE_OPLINE + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + + SAVE_OPLINE(); + + switch (type) { + case ZEND_THROW: + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + { + if (EG(prev_exception)) { + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } else { + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + } + + if (catch_op_num && finally_op_num) { + /* EG(exception) || EG(prev_exception) */ + if (catch_op_num > finally_op_num) { + EX(leaving) = ZEND_THROW; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } + } else if (catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } else if (finally_op_num) { + EX(leaving) = type; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else if (EX(leaving)) { + /* leave it to ZEND_LEAVE */ + ZEND_VM_NEXT_OPCODE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } + break; + case ZEND_BRK: + case ZEND_CONT: + case ZEND_GOTO: + { + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op + && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op + || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + + if (finally_op_num) { + EX(leaving) = type; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); + } + } + break; + } + ZEND_VM_CONTINUE(); +} + ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) { USE_OPLINE @@ -3379,6 +3388,10 @@ ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); + if (EG(active_op_array)->has_finally_block) { + EX(leaving_dest) = el->brk; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_BRK); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } @@ -3391,6 +3404,10 @@ ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); + if (EG(active_op_array)->has_finally_block) { + EX(leaving_dest) = el->cont; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_CONT); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } @@ -3418,6 +3435,10 @@ ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) } break; } + if ((EG(active_op_array)->has_finally_block)) { + EX(leaving_dest) = opline->op1.jmp_addr - EG(active_op_array)->opcodes; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_GOTO); + } ZEND_VM_JMP(opline->op1.jmp_addr); } @@ -5184,7 +5205,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) ZEND_VM_CONTINUE(); } else { zend_exception_save(TSRMLS_C); - EX(leaving) = finally; + EX(leaving) = ZEND_THROW; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } @@ -5194,7 +5215,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) ZEND_VM_CONTINUE(); } else if (finally) { zend_exception_save(TSRMLS_C); - EX(leaving) = finally; + EX(leaving) = ZEND_THROW; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } else { @@ -5284,7 +5305,7 @@ ZEND_VM_HANDLER(153, ZEND_DECLARE_LAMBDA_FUNCTION, CONST, UNUSED) zend_function *op_array; SAVE_OPLINE(); - + if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), Z_HASH_P(opline->op1.zv), (void *) &op_array) == FAILURE) || UNEXPECTED(op_array->type != ZEND_USER_FUNCTION)) { zend_error_noreturn(E_ERROR, "Base lambda function for closure not found"); @@ -5320,47 +5341,68 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) { USE_OPLINE - zend_uint i, op_num = opline - EG(active_op_array)->opcodes; - - SAVE_OPLINE(); zend_exception_restore(TSRMLS_C); - if (EX(leaving)) { + + if (!EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; zend_uint catch_op_num = 0, finally_op_num = 0; - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(exception)) { - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } + switch (EX(leaving)) { + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + case ZEND_THROW: + { + if (EG(exception)) { + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } else { + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + } - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = ZEND_THROW; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } + } else if (catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } else if (finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } + break; + case ZEND_BRK: + case ZEND_CONT: + case ZEND_GOTO: + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, EX(leaving)); + break; } - } else { - ZEND_VM_NEXT_OPCODE(); } + + ZEND_VM_CONTINUE(); } ZEND_VM_EXPORT_HELPER(zend_do_fcall, zend_do_fcall_common_helper) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index b5a649d0a2732..9818583334c6e 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -794,6 +794,93 @@ static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } +static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE_HANDLER_ARGS) +{ + USE_OPLINE + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; + + SAVE_OPLINE(); + + switch (type) { + case ZEND_THROW: + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + { + if (EG(prev_exception)) { + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } else { + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + } + + if (catch_op_num && finally_op_num) { + /* EG(exception) || EG(prev_exception) */ + if (catch_op_num > finally_op_num) { + EX(leaving) = ZEND_THROW; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } + } else if (catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } else if (finally_op_num) { + EX(leaving) = type; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else if (EX(leaving)) { + /* leave it to ZEND_LEAVE */ + ZEND_VM_NEXT_OPCODE(); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } + break; + case ZEND_BRK: + case ZEND_CONT: + case ZEND_GOTO: + { + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op + && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op + || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + + if (finally_op_num) { + EX(leaving) = type; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); + } + } + break; + } + ZEND_VM_CONTINUE(); +} + static int ZEND_FASTCALL ZEND_NEW_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1122,7 +1209,7 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_CONTINUE(); } else { zend_exception_save(TSRMLS_C); - EX(leaving) = finally; + EX(leaving) = ZEND_THROW; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } @@ -1132,7 +1219,7 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_CONTINUE(); } else if (finally) { zend_exception_save(TSRMLS_C); - EX(leaving) = finally; + EX(leaving) = ZEND_THROW; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } else { @@ -1178,47 +1265,68 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - zend_uint i, op_num = opline - EG(active_op_array)->opcodes; - - SAVE_OPLINE(); zend_exception_restore(TSRMLS_C); - if (EX(leaving)) { + + if (!EX(leaving)) { + ZEND_VM_NEXT_OPCODE(); + } else { + zend_uint i, op_num = opline - EX(op_array)->opcodes; zend_uint catch_op_num = 0, finally_op_num = 0; - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(exception)) { - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } + switch (EX(leaving)) { + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + case ZEND_THROW: + { + if (EG(exception)) { + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { + catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + } + } + } else { + for (i = 0; i < EX(leaving); i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + } - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (catch_op_num && finally_op_num) { + if (catch_op_num > finally_op_num) { + EX(leaving) = ZEND_THROW; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } + } else if (catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } else if (finally_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + } + break; + case ZEND_BRK: + case ZEND_CONT: + case ZEND_GOTO: + return zend_finally_handler_leaving_SPEC(EX(leaving), ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + break; } - } else { - ZEND_VM_NEXT_OPCODE(); } + + ZEND_VM_CONTINUE(); } static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1455,6 +1563,10 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); + if (EG(active_op_array)->has_finally_block) { + EX(leaving_dest) = el->brk; + return zend_finally_handler_leaving_SPEC(ZEND_BRK, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } @@ -1467,6 +1579,10 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); + if (EG(active_op_array)->has_finally_block) { + EX(leaving_dest) = el->cont; + return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } @@ -1494,6 +1610,10 @@ static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } break; } + if ((EG(active_op_array)->has_finally_block)) { + EX(leaving_dest) = opline->op1.jmp_addr - EG(active_op_array)->opcodes; + return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } ZEND_VM_JMP(opline->op1.jmp_addr); } @@ -2345,49 +2465,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG *EG(return_value_ptr_ptr) = ret; } - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2458,49 +2539,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -6973,49 +7015,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7086,49 +7089,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11507,49 +11471,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11622,49 +11547,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27604,49 +27490,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27717,49 +27564,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - if (!(EG(active_op_array)->last_try_catch)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (EG(prev_exception)) { - /* leaving */ - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catch_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally_op_num) { - EX(leaving) = 1; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } else if (EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } + if (EG(active_op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) From 60a29791e4b66844e5dfff698141074d48fc3da8 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 22 Aug 2012 18:32:03 +0800 Subject: [PATCH 2025/2394] Fixed bug that jmp in try block jmp over finally block Refactor the implemention, make codes clear --- Zend/tests/catch_finally_001.phpt | 2 +- Zend/tests/catch_finally_002.phpt | 2 +- Zend/tests/catch_finally_003.phpt | 2 +- Zend/tests/catch_finally_004.phpt | 2 +- Zend/tests/catch_finally_005.phpt | 2 +- Zend/tests/catch_finally_006.phpt | 2 +- Zend/tests/try_catch_finally_005.phpt | 52 + Zend/tests/try_catch_finally_006.phpt | 39 + Zend/tests/try_catch_finally_007.phpt | 46 + Zend/tests/try_finally_001.phpt | 3 +- Zend/tests/try_finally_002.phpt | 2 +- Zend/tests/try_finally_003.phpt | 2 +- Zend/tests/try_finally_004.phpt | 2 +- Zend/tests/try_finally_005.phpt | 2 +- Zend/tests/try_finally_006.phpt | 2 +- Zend/tests/try_finally_007.phpt | 2 +- Zend/tests/try_finally_008.phpt | 2 +- Zend/tests/try_finally_009.phpt | 2 +- Zend/zend_compile.c | 24 +- Zend/zend_compile.h | 6 +- Zend/zend_opcode.c | 6 +- Zend/zend_vm_def.h | 1363 ++++++++++++------------- Zend/zend_vm_execute.h | 363 +++---- 23 files changed, 1000 insertions(+), 930 deletions(-) create mode 100644 Zend/tests/try_catch_finally_005.phpt create mode 100644 Zend/tests/try_catch_finally_006.phpt create mode 100644 Zend/tests/try_catch_finally_007.phpt diff --git a/Zend/tests/catch_finally_001.phpt b/Zend/tests/catch_finally_001.phpt index 2b58fa713267c..0c3f597a0a5a2 100644 --- a/Zend/tests/catch_finally_001.phpt +++ b/Zend/tests/catch_finally_001.phpt @@ -1,5 +1,5 @@ --TEST-- -Try catch finally +Try catch finally (basic test) --FILE-- +--EXPECTF-- +string(5) "break" +string(9) "continue1" +string(9) "continue1" +string(9) "continue2" +string(7) "finally" +string(9) "continue2" +string(8) "cactched" +string(7) "finally" +string(9) "continue2" +string(7) "finally" diff --git a/Zend/tests/try_catch_finally_006.phpt b/Zend/tests/try_catch_finally_006.phpt new file mode 100644 index 0000000000000..dab6af6a58156 --- /dev/null +++ b/Zend/tests/try_catch_finally_006.phpt @@ -0,0 +1,39 @@ +--TEST-- +Try catch finally (goto in try/catch block) +--CREDITS-- +adoy +--FILE-- + +--EXPECTF-- +string(8) "finally1" +string(8) "finally2" +string(5) "label" +string(7) "return2" +string(8) "finally1" +string(7) "catched" +string(8) "finally2" +string(7) "return1" diff --git a/Zend/tests/try_catch_finally_007.phpt b/Zend/tests/try_catch_finally_007.phpt new file mode 100644 index 0000000000000..ad33c68131706 --- /dev/null +++ b/Zend/tests/try_catch_finally_007.phpt @@ -0,0 +1,46 @@ +--TEST-- +Try catch finally (goto in try/catch block) +--CREDITS-- +adoy +--FILE-- + +--EXPECTF-- +string(8) "finally1" +string(7) "catched" +string(8) "finally2" +string(5) "label" +NULL +string(8) "finally1" +string(7) "catched" +string(8) "finally2" +string(6) "return" diff --git a/Zend/tests/try_finally_001.phpt b/Zend/tests/try_finally_001.phpt index 1c168da275cdd..0f740872c2acd 100644 --- a/Zend/tests/try_finally_001.phpt +++ b/Zend/tests/try_finally_001.phpt @@ -1,5 +1,5 @@ --TEST-- -Try finally +Try finally (basic test) --FILE-- EA = get_next_op_number(CG(active_op_array)); + catch_token->EA = get_next_op_number(CG(active_op_array)); } /* }}} */ @@ -2792,7 +2792,7 @@ void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_to zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_end = get_next_op_number(CG(active_op_array)); - CG(active_op_array)->has_finally_block = 1; + CG(active_op_array)->has_finally_block = 1; opline->opcode = ZEND_LEAVE; SET_UNUSED(opline->op1); @@ -4059,9 +4059,9 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* /** And, ensure that the referenced method is resolvable, too. */ lcname = zend_str_tolower_dup(cur_method_ref->method_name, - cur_method_ref->mname_len); + cur_method_ref->mname_len); method_exists = zend_hash_exists(&cur_method_ref->ce->function_table, - lcname, cur_method_ref->mname_len + 1); + lcname, cur_method_ref->mname_len + 1); efree(lcname); if (!method_exists) { @@ -5043,11 +5043,11 @@ void zend_do_begin_class_declaration(const znode *class_token, znode *class_name opline->op2_type = IS_CONST; if (doing_inheritance) { - /* Make sure a trait does not try to extend a class */ - if ((new_class_entry->ce_flags & ZEND_ACC_TRAIT) == ZEND_ACC_TRAIT) { - zend_error(E_COMPILE_ERROR, "A trait (%s) cannot extend a class. Traits can only be composed from other traits with the 'use' keyword. Error", new_class_entry->name); - } - + /* Make sure a trait does not try to extend a class */ + if ((new_class_entry->ce_flags & ZEND_ACC_TRAIT) == ZEND_ACC_TRAIT) { + zend_error(E_COMPILE_ERROR, "A trait (%s) cannot extend a class. Traits can only be composed from other traits with the 'use' keyword. Error", new_class_entry->name); + } + opline->extended_value = parent_class_name->u.op.var; opline->opcode = ZEND_DECLARE_INHERITED_CLASS; } else { @@ -6998,9 +6998,9 @@ void zend_do_use(znode *ns_name, znode *new_name, int is_global TSRMLS_DC) /* {{ lcname = zend_str_tolower_dup(Z_STRVAL_P(name), Z_STRLEN_P(name)); if (((Z_STRLEN_P(name) == sizeof("self")-1) && - !memcmp(lcname, "self", sizeof("self")-1)) || - ((Z_STRLEN_P(name) == sizeof("parent")-1) && - !memcmp(lcname, "parent", sizeof("parent")-1))) { + !memcmp(lcname, "self", sizeof("self")-1)) || + ((Z_STRLEN_P(name) == sizeof("parent")-1) && + !memcmp(lcname, "parent", sizeof("parent")-1))) { zend_error(E_COMPILE_ERROR, "Cannot use %s as %s because '%s' is a special class name", Z_STRVAL_P(ns), Z_STRVAL_P(name), Z_STRVAL_P(name)); } diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 80e02ab3098b8..971860602eeaf 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -281,7 +281,7 @@ struct _zend_op_array { zend_try_catch_element *try_catch_array; int last_try_catch; - zend_bool has_finally_block; + zend_bool has_finally_block; /* static variables support */ HashTable *static_variables; @@ -384,8 +384,8 @@ struct _zend_execute_data { zend_class_entry *current_called_scope; zval *current_this; zval *current_object; - zend_uint leaving; - zend_uint leaving_dest; + zend_uint leaving; + zend_uint leaving_dest; }; #define EX(element) execute_data.element diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 2552d2ebd64ab..6c15829100431 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -87,7 +87,7 @@ void init_op_array(zend_op_array *op_array, zend_uchar type, int initial_ops_siz op_array->static_variables = NULL; op_array->last_try_catch = 0; - op_array->has_finally_block = 0; + op_array->has_finally_block = 0; op_array->this_var = -1; @@ -552,8 +552,8 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) } opline->op1.jmp_addr = &op_array->opcodes[opline->op1.opline_num]; break; - case ZEND_BRK: - case ZEND_CONT: + case ZEND_BRK: + case ZEND_CONT: if (op_array->last_try_catch) { int nest_levels, array_offset; zend_brk_cont_element *jmp_to; diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index d921f81efc607..ce1674e4f3834 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1840,240 +1840,630 @@ ZEND_VM_HANDLER(39, ZEND_ASSIGN_REF, VAR|CV, VAR|CV) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(42, ZEND_JMP, ANY, ANY) +ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) { - USE_OPLINE + zend_bool nested; + zend_op_array *op_array = EX(op_array); -#if DEBUG_ZEND>=2 - printf("Jumping to %d\n", opline->op1.opline_num); -#endif - ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); - ZEND_VM_CONTINUE(); /* CHECK_ME */ -} + EG(current_execute_data) = EX(prev_execute_data); + EG(opline_ptr) = NULL; + if (!EG(active_symbol_table)) { + zval ***cv = EX_CVs(); + zval ***end = cv + op_array->last_var; + while (cv != end) { + if (*cv) { + zval_ptr_dtor(*cv); + } + cv++; + } + } -ZEND_VM_HANDLER(43, ZEND_JMPZ, CONST|TMP|VAR|CV, ANY) -{ - USE_OPLINE - zend_free_op free_op1; - zval *val; - int ret; + if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { + zval_ptr_dtor((zval**)&op_array->prototype); + } - SAVE_OPLINE(); - val = GET_OP1_ZVAL_PTR(BP_VAR_R); + nested = EX(nested); - if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { - ret = Z_LVAL_P(val); - } else { - ret = i_zend_is_true(val); - FREE_OP1(); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } - } - if (!ret) { -#if DEBUG_ZEND>=2 - printf("Conditional jmp to %d\n", opline->op2.opline_num); -#endif - ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); - ZEND_VM_CONTINUE(); + zend_vm_stack_free(execute_data TSRMLS_CC); + + if (nested) { + execute_data = EG(current_execute_data); } + if (nested) { + USE_OPLINE - ZEND_VM_NEXT_OPCODE(); -} + LOAD_REGS(); + LOAD_OPLINE(); + if (UNEXPECTED(opline->opcode == ZEND_INCLUDE_OR_EVAL)) { -ZEND_VM_HANDLER(44, ZEND_JMPNZ, CONST|TMP|VAR|CV, ANY) -{ - USE_OPLINE - zend_free_op free_op1; - zval *val; - int ret; + EX(function_state).function = (zend_function *) EX(op_array); + EX(function_state).arguments = NULL; + EX(object) = EX(current_object); - SAVE_OPLINE(); - val = GET_OP1_ZVAL_PTR(BP_VAR_R); + EG(opline_ptr) = &EX(opline); + EG(active_op_array) = EX(op_array); + EG(return_value_ptr_ptr) = EX(original_return_value); + destroy_op_array(op_array TSRMLS_CC); + efree(op_array); + if (UNEXPECTED(EG(exception) != NULL)) { + zend_throw_exception_internal(NULL TSRMLS_CC); + HANDLE_EXCEPTION_LEAVE(); + } else if (RETURN_VALUE_USED(opline)) { + if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ + zval *retval; - if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { - ret = Z_LVAL_P(val); - } else { - ret = i_zend_is_true(val); - FREE_OP1(); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } - } - if (ret) { -#if DEBUG_ZEND>=2 - printf("Conditional jmp to %d\n", opline->op2.opline_num); -#endif - ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); - ZEND_VM_CONTINUE(); - } + ALLOC_ZVAL(retval); + ZVAL_BOOL(retval, 1); + INIT_PZVAL(retval); + EX_T(opline->result.var).var.ptr = retval; + } + } - ZEND_VM_NEXT_OPCODE(); -} + ZEND_VM_INC_OPCODE(); + ZEND_VM_LEAVE(); + } else { -ZEND_VM_HANDLER(45, ZEND_JMPZNZ, CONST|TMP|VAR|CV, ANY) -{ - USE_OPLINE - zend_free_op free_op1; - zval *val; - int retval; + EG(opline_ptr) = &EX(opline); + EG(active_op_array) = EX(op_array); + EG(return_value_ptr_ptr) = EX(original_return_value); + if (EG(active_symbol_table)) { + if (EG(symtable_cache_ptr)>=EG(symtable_cache_limit)) { + zend_hash_destroy(EG(active_symbol_table)); + FREE_HASHTABLE(EG(active_symbol_table)); + } else { + /* clean before putting into the cache, since clean + could call dtors, which could use cached hash */ + zend_hash_clean(EG(active_symbol_table)); + *(++EG(symtable_cache_ptr)) = EG(active_symbol_table); + } + } + EG(active_symbol_table) = EX(symbol_table); - SAVE_OPLINE(); - val = GET_OP1_ZVAL_PTR(BP_VAR_R); + EX(function_state).function = (zend_function *) EX(op_array); + EX(function_state).arguments = NULL; - if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { - retval = Z_LVAL_P(val); - } else { - retval = i_zend_is_true(val); - FREE_OP1(); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); + if (EG(This)) { + if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { + if (IS_CTOR_USED(EX(called_scope))) { + Z_DELREF_P(EG(This)); + } + if (Z_REFCOUNT_P(EG(This)) == 1) { + zend_object_store_ctor_failed(EG(This) TSRMLS_CC); + } + } + zval_ptr_dtor(&EG(This)); + } + EG(This) = EX(current_this); + EG(scope) = EX(current_scope); + EG(called_scope) = EX(current_called_scope); + + EX(object) = EX(current_object); + EX(called_scope) = DECODE_CTOR(EX(called_scope)); + + zend_vm_stack_clear_multiple(TSRMLS_C); + + if (UNEXPECTED(EG(exception) != NULL)) { + zend_throw_exception_internal(NULL TSRMLS_CC); + if (RETURN_VALUE_USED(opline) && EX_T(opline->result.var).var.ptr) { + zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); + } + HANDLE_EXCEPTION_LEAVE(); + } + + ZEND_VM_INC_OPCODE(); + ZEND_VM_LEAVE(); } } - if (EXPECTED(retval != 0)) { -#if DEBUG_ZEND>=2 - printf("Conditional jmp on true to %d\n", opline->extended_value); -#endif - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->extended_value]); - ZEND_VM_CONTINUE(); /* CHECK_ME */ - } else { -#if DEBUG_ZEND>=2 - printf("Conditional jmp on false to %d\n", opline->op2.opline_num); -#endif - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); - ZEND_VM_CONTINUE(); /* CHECK_ME */ - } + ZEND_VM_RETURN(); } -ZEND_VM_HANDLER(46, ZEND_JMPZ_EX, CONST|TMP|VAR|CV, ANY) +ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) { USE_OPLINE - zend_free_op free_op1; - zval *val; - int retval; + zend_bool should_change_scope = 0; + zend_function *fbc = EX(function_state).function; SAVE_OPLINE(); - val = GET_OP1_ZVAL_PTR(BP_VAR_R); + if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { + if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { + zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ + } + if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { + zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", + fbc->common.scope ? fbc->common.scope->name : "", + fbc->common.scope ? "::" : "", + fbc->common.function_name); + } + } + if (fbc->common.scope && + !(fbc->common.fn_flags & ZEND_ACC_STATIC) && + !EX(object)) { - if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { - retval = Z_LVAL_P(val); - } else { - retval = i_zend_is_true(val); - FREE_OP1(); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); + if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + /* FIXME: output identifiers properly */ + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); + } else { + /* FIXME: output identifiers properly */ + /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically", fbc->common.scope->name, fbc->common.function_name); } } - Z_LVAL(EX_T(opline->result.var).tmp_var) = retval; - Z_TYPE(EX_T(opline->result.var).tmp_var) = IS_BOOL; - if (!retval) { -#if DEBUG_ZEND>=2 - printf("Conditional jmp to %d\n", opline->op2.opline_num); -#endif - ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); - ZEND_VM_CONTINUE(); + + if (fbc->type == ZEND_USER_FUNCTION || fbc->common.scope) { + should_change_scope = 1; + EX(current_this) = EG(This); + EX(current_scope) = EG(scope); + EX(current_called_scope) = EG(called_scope); + EG(This) = EX(object); + EG(scope) = (fbc->type == ZEND_USER_FUNCTION || !EX(object)) ? fbc->common.scope : NULL; + EG(called_scope) = EX(called_scope); } - ZEND_VM_NEXT_OPCODE(); -} -ZEND_VM_HANDLER(47, ZEND_JMPNZ_EX, CONST|TMP|VAR|CV, ANY) -{ - USE_OPLINE - zend_free_op free_op1; - zval *val; - int retval; + zend_arg_types_stack_3_pop(&EG(arg_types_stack), &EX(called_scope), &EX(current_object), &EX(fbc)); + EX(function_state).arguments = zend_vm_stack_push_args(opline->extended_value TSRMLS_CC); + LOAD_OPLINE(); - SAVE_OPLINE(); - val = GET_OP1_ZVAL_PTR(BP_VAR_R); + if (fbc->type == ZEND_INTERNAL_FUNCTION) { + temp_variable *ret = &EX_T(opline->result.var); - if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { - retval = Z_LVAL_P(val); - } else { - retval = i_zend_is_true(val); - FREE_OP1(); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); + MAKE_STD_ZVAL(ret->var.ptr); + ZVAL_NULL(ret->var.ptr); + ret->var.ptr_ptr = &ret->var.ptr; + ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; + + if (fbc->common.arg_info) { + zend_uint i=0; + zval **p = (zval**)EX(function_state).arguments; + ulong arg_count = opline->extended_value; + + while (arg_count>0) { + zend_verify_arg_type(fbc, ++i, *(p-arg_count), 0 TSRMLS_CC); + arg_count--; + } + } + + if (!zend_execute_internal) { + /* saves one function call if zend_execute_internal is not used */ + fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); + } else { + zend_execute_internal(EXECUTE_DATA, RETURN_VALUE_USED(opline) TSRMLS_CC); + } + + if (!RETURN_VALUE_USED(opline)) { + zval_ptr_dtor(&ret->var.ptr); + } + } else if (fbc->type == ZEND_USER_FUNCTION) { + EX(original_return_value) = EG(return_value_ptr_ptr); + EG(active_symbol_table) = NULL; + EG(active_op_array) = &fbc->op_array; + EG(return_value_ptr_ptr) = NULL; + if (RETURN_VALUE_USED(opline)) { + temp_variable *ret = &EX_T(opline->result.var); + + ret->var.ptr = NULL; + EG(return_value_ptr_ptr) = &ret->var.ptr; + ret->var.ptr_ptr = &ret->var.ptr; + ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; + } + + if (EXPECTED(zend_execute == execute)) { + if (EXPECTED(EG(exception) == NULL)) { + ZEND_VM_ENTER(); + } + } else { + zend_execute(EG(active_op_array) TSRMLS_CC); + } + + EG(opline_ptr) = &EX(opline); + EG(active_op_array) = EX(op_array); + EG(return_value_ptr_ptr) = EX(original_return_value); + if (EG(active_symbol_table)) { + if (EG(symtable_cache_ptr)>=EG(symtable_cache_limit)) { + zend_hash_destroy(EG(active_symbol_table)); + FREE_HASHTABLE(EG(active_symbol_table)); + } else { + /* clean before putting into the cache, since clean + could call dtors, which could use cached hash */ + zend_hash_clean(EG(active_symbol_table)); + *(++EG(symtable_cache_ptr)) = EG(active_symbol_table); + } + } + EG(active_symbol_table) = EX(symbol_table); + } else { /* ZEND_OVERLOADED_FUNCTION */ + MAKE_STD_ZVAL(EX_T(opline->result.var).var.ptr); + ZVAL_NULL(EX_T(opline->result.var).var.ptr); + + /* Not sure what should be done here if it's a static method */ + if (EXPECTED(EX(object) != NULL)) { + Z_OBJ_HT_P(EX(object))->call_method(fbc->common.function_name, opline->extended_value, EX_T(opline->result.var).var.ptr, &EX_T(opline->result.var).var.ptr, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); + } else { + zend_error_noreturn(E_ERROR, "Cannot call overloaded function for non-object"); + } + + if (fbc->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY) { + efree((char*)fbc->common.function_name); + } + efree(fbc); + + if (!RETURN_VALUE_USED(opline)) { + zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); + } else { + Z_UNSET_ISREF_P(EX_T(opline->result.var).var.ptr); + Z_SET_REFCOUNT_P(EX_T(opline->result.var).var.ptr, 1); + EX_T(opline->result.var).var.fcall_returned_reference = 0; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; } } - Z_LVAL(EX_T(opline->result.var).tmp_var) = retval; - Z_TYPE(EX_T(opline->result.var).tmp_var) = IS_BOOL; - if (retval) { -#if DEBUG_ZEND>=2 - printf("Conditional jmp to %d\n", opline->op2.opline_num); -#endif - ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); - ZEND_VM_CONTINUE(); + + EX(function_state).function = (zend_function *) EX(op_array); + EX(function_state).arguments = NULL; + + if (should_change_scope) { + if (EG(This)) { + if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { + if (IS_CTOR_USED(EX(called_scope))) { + Z_DELREF_P(EG(This)); + } + if (Z_REFCOUNT_P(EG(This)) == 1) { + zend_object_store_ctor_failed(EG(This) TSRMLS_CC); + } + } + zval_ptr_dtor(&EG(This)); + } + EG(This) = EX(current_this); + EG(scope) = EX(current_scope); + EG(called_scope) = EX(current_called_scope); + } + + EX(object) = EX(current_object); + EX(called_scope) = DECODE_CTOR(EX(called_scope)); + + zend_vm_stack_clear_multiple(TSRMLS_C); + + if (UNEXPECTED(EG(exception) != NULL)) { + zend_throw_exception_internal(NULL TSRMLS_CC); + if (RETURN_VALUE_USED(opline) && EX_T(opline->result.var).var.ptr) { + zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); + } + HANDLE_EXCEPTION(); } + ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(70, ZEND_FREE, TMP|VAR, ANY) +ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) { USE_OPLINE + zend_uint i, op_num = opline - EX(op_array)->opcodes; + zend_uint catch_op_num = 0, finally_op_num = 0; SAVE_OPLINE(); - if (OP1_TYPE == IS_TMP_VAR) { - zendi_zval_dtor(EX_T(opline->op1.var).tmp_var); - } else { - zval_ptr_dtor(&EX_T(opline->op1.var).var.ptr); + + switch (type) { + case ZEND_THROW: + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + case ZEND_LEAVE: + { + if (EG(prev_exception) || (type == ZEND_LEAVE && EG(exception))) { + for (i=0; ilast_try_catch; i++) { + if (EX(op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EX(op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; + } + if (op_num < EX(op_array)->try_catch_array[i].catch_op) { + catch_op_num = EX(op_array)->try_catch_array[i].catch_op; + } + } + } else { + for (i=0; ilast_try_catch; i++) { + if (EX(op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EX(op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; + } + } + } + + if (catch_op_num && finally_op_num) { + /* EG(exception) || EG(prev_exception) */ + if (catch_op_num > finally_op_num) { + EX(leaving) = ZEND_THROW; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } + } else if (catch_op_num) { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + } else if (finally_op_num) { + if (type != ZEND_LEAVE) { + EX(leaving) = type; + } + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else if (EX(leaving) && type != ZEND_LEAVE) { + /* leave it to ZEND_LEAVE */ + EX(leaving) = type; + ZEND_VM_NEXT_OPCODE(); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } + break; + case ZEND_JMP: + case ZEND_BRK: + case ZEND_CONT: + case ZEND_GOTO: + { + /* these can not occurred in exception context */ + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op + && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op + || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + + if (finally_op_num) { + EX(leaving) = type; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); + } + } + break; } - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); + ZEND_VM_CONTINUE(); } -ZEND_VM_HANDLER(53, ZEND_INIT_STRING, ANY, ANY) +ZEND_VM_HANDLER(42, ZEND_JMP, ANY, ANY) { USE_OPLINE - zval *tmp = &EX_T(opline->result.var).tmp_var; - SAVE_OPLINE(); - tmp->value.str.val = emalloc(1); - tmp->value.str.val[0] = 0; - tmp->value.str.len = 0; - Z_SET_REFCOUNT_P(tmp, 1); - tmp->type = IS_STRING; - Z_UNSET_ISREF_P(tmp); - /*CHECK_EXCEPTION();*/ - ZEND_VM_NEXT_OPCODE(); +#if DEBUG_ZEND>=2 + printf("Jumping to %d\n", opline->op1.opline_num); +#endif + if (EX(op_array)->has_finally_block) { + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_JMP); + } + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); /* CHECK_ME */ } -ZEND_VM_HANDLER(54, ZEND_ADD_CHAR, TMP|UNUSED, CONST) +ZEND_VM_HANDLER(43, ZEND_JMPZ, CONST|TMP|VAR|CV, ANY) { USE_OPLINE - zval *str = &EX_T(opline->result.var).tmp_var; + zend_free_op free_op1; + zval *val; + int ret; SAVE_OPLINE(); + val = GET_OP1_ZVAL_PTR(BP_VAR_R); - if (OP1_TYPE == IS_UNUSED) { - /* Initialize for erealloc in add_char_to_string */ - Z_STRVAL_P(str) = NULL; - Z_STRLEN_P(str) = 0; - Z_TYPE_P(str) = IS_STRING; - - INIT_PZVAL(str); + if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { + ret = Z_LVAL_P(val); + } else { + ret = i_zend_is_true(val); + FREE_OP1(); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } + if (!ret) { +#if DEBUG_ZEND>=2 + printf("Conditional jmp to %d\n", opline->op2.opline_num); +#endif + ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); + ZEND_VM_CONTINUE(); } - add_char_to_string(str, str, opline->op2.zv); - - /* FREE_OP is missing intentionally here - we're always working on the same temporary variable */ - /*CHECK_EXCEPTION();*/ ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(55, ZEND_ADD_STRING, TMP|UNUSED, CONST) +ZEND_VM_HANDLER(44, ZEND_JMPNZ, CONST|TMP|VAR|CV, ANY) { USE_OPLINE - zval *str = &EX_T(opline->result.var).tmp_var; + zend_free_op free_op1; + zval *val; + int ret; SAVE_OPLINE(); + val = GET_OP1_ZVAL_PTR(BP_VAR_R); - if (OP1_TYPE == IS_UNUSED) { - /* Initialize for erealloc in add_string_to_string */ - Z_STRVAL_P(str) = NULL; - Z_STRLEN_P(str) = 0; - Z_TYPE_P(str) = IS_STRING; - - INIT_PZVAL(str); + if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { + ret = Z_LVAL_P(val); + } else { + ret = i_zend_is_true(val); + FREE_OP1(); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } + if (ret) { +#if DEBUG_ZEND>=2 + printf("Conditional jmp to %d\n", opline->op2.opline_num); +#endif + ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); + ZEND_VM_CONTINUE(); + } + + ZEND_VM_NEXT_OPCODE(); +} + +ZEND_VM_HANDLER(45, ZEND_JMPZNZ, CONST|TMP|VAR|CV, ANY) +{ + USE_OPLINE + zend_free_op free_op1; + zval *val; + int retval; + + SAVE_OPLINE(); + val = GET_OP1_ZVAL_PTR(BP_VAR_R); + + if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { + retval = Z_LVAL_P(val); + } else { + retval = i_zend_is_true(val); + FREE_OP1(); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } + if (EXPECTED(retval != 0)) { +#if DEBUG_ZEND>=2 + printf("Conditional jmp on true to %d\n", opline->extended_value); +#endif + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->extended_value]); + ZEND_VM_CONTINUE(); /* CHECK_ME */ + } else { +#if DEBUG_ZEND>=2 + printf("Conditional jmp on false to %d\n", opline->op2.opline_num); +#endif + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); /* CHECK_ME */ + } +} + +ZEND_VM_HANDLER(46, ZEND_JMPZ_EX, CONST|TMP|VAR|CV, ANY) +{ + USE_OPLINE + zend_free_op free_op1; + zval *val; + int retval; + + SAVE_OPLINE(); + val = GET_OP1_ZVAL_PTR(BP_VAR_R); + + if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { + retval = Z_LVAL_P(val); + } else { + retval = i_zend_is_true(val); + FREE_OP1(); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } + Z_LVAL(EX_T(opline->result.var).tmp_var) = retval; + Z_TYPE(EX_T(opline->result.var).tmp_var) = IS_BOOL; + if (!retval) { +#if DEBUG_ZEND>=2 + printf("Conditional jmp to %d\n", opline->op2.opline_num); +#endif + ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); + ZEND_VM_CONTINUE(); + } + ZEND_VM_NEXT_OPCODE(); +} + +ZEND_VM_HANDLER(47, ZEND_JMPNZ_EX, CONST|TMP|VAR|CV, ANY) +{ + USE_OPLINE + zend_free_op free_op1; + zval *val; + int retval; + + SAVE_OPLINE(); + val = GET_OP1_ZVAL_PTR(BP_VAR_R); + + if (OP1_TYPE == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { + retval = Z_LVAL_P(val); + } else { + retval = i_zend_is_true(val); + FREE_OP1(); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } + Z_LVAL(EX_T(opline->result.var).tmp_var) = retval; + Z_TYPE(EX_T(opline->result.var).tmp_var) = IS_BOOL; + if (retval) { +#if DEBUG_ZEND>=2 + printf("Conditional jmp to %d\n", opline->op2.opline_num); +#endif + ZEND_VM_SET_OPCODE(opline->op2.jmp_addr); + ZEND_VM_CONTINUE(); + } + ZEND_VM_NEXT_OPCODE(); +} + +ZEND_VM_HANDLER(70, ZEND_FREE, TMP|VAR, ANY) +{ + USE_OPLINE + + SAVE_OPLINE(); + if (OP1_TYPE == IS_TMP_VAR) { + zendi_zval_dtor(EX_T(opline->op1.var).tmp_var); + } else { + zval_ptr_dtor(&EX_T(opline->op1.var).var.ptr); + } + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); +} + +ZEND_VM_HANDLER(53, ZEND_INIT_STRING, ANY, ANY) +{ + USE_OPLINE + zval *tmp = &EX_T(opline->result.var).tmp_var; + + SAVE_OPLINE(); + tmp->value.str.val = emalloc(1); + tmp->value.str.val[0] = 0; + tmp->value.str.len = 0; + Z_SET_REFCOUNT_P(tmp, 1); + tmp->type = IS_STRING; + Z_UNSET_ISREF_P(tmp); + /*CHECK_EXCEPTION();*/ + ZEND_VM_NEXT_OPCODE(); +} + +ZEND_VM_HANDLER(54, ZEND_ADD_CHAR, TMP|UNUSED, CONST) +{ + USE_OPLINE + zval *str = &EX_T(opline->result.var).tmp_var; + + SAVE_OPLINE(); + + if (OP1_TYPE == IS_UNUSED) { + /* Initialize for erealloc in add_char_to_string */ + Z_STRVAL_P(str) = NULL; + Z_STRLEN_P(str) = 0; + Z_TYPE_P(str) = IS_STRING; + + INIT_PZVAL(str); + } + + add_char_to_string(str, str, opline->op2.zv); + + /* FREE_OP is missing intentionally here - we're always working on the same temporary variable */ + /*CHECK_EXCEPTION();*/ + ZEND_VM_NEXT_OPCODE(); +} + +ZEND_VM_HANDLER(55, ZEND_ADD_STRING, TMP|UNUSED, CONST) +{ + USE_OPLINE + zval *str = &EX_T(opline->result.var).tmp_var; + + SAVE_OPLINE(); + + if (OP1_TYPE == IS_UNUSED) { + /* Initialize for erealloc in add_string_to_string */ + Z_STRVAL_P(str) = NULL; + Z_STRLEN_P(str) = 0; + Z_TYPE_P(str) = IS_STRING; + + INIT_PZVAL(str); } add_string_to_string(str, str, opline->op2.zv); @@ -2408,396 +2798,103 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) EX(fbc)->common.fn_flags & ZEND_ACC_CLOSURE) { /* Delay closure destruction until its invocation */ EX(fbc)->common.prototype = (zend_function*)function_name; - } else { - FREE_OP2(); - } - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); - } else if (OP2_TYPE != IS_CONST && - EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && - zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { - zend_class_entry *ce; - zval **method = NULL; - zval **obj = NULL; - - zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); - zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); - - if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { - zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); - } - - if (Z_TYPE_PP(method) != IS_STRING) { - zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); - } - - if (Z_TYPE_PP(obj) == IS_STRING) { - ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); - if (UNEXPECTED(ce == NULL)) { - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); - } - EX(called_scope) = ce; - EX(object) = NULL; - - if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); - } else { - EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - } - } else { - EX(object) = *obj; - ce = EX(called_scope) = Z_OBJCE_PP(obj); - - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); - } - - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; - } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ - } else { - zval *this_ptr; - ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); - zval_copy_ctor(this_ptr); - EX(object) = this_ptr; - } - } - } - - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); - } - FREE_OP2(); - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); - } else { - zend_error_noreturn(E_ERROR, "Function name must be a string"); - } - } -} - - -ZEND_VM_HANDLER(69, ZEND_INIT_NS_FCALL_BY_NAME, ANY, CONST) -{ - USE_OPLINE - zend_literal *func_name; - - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); - - func_name = opline->op2.literal + 1; - if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE) { - func_name++; - if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE)) { - SAVE_OPLINE(); - zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); - } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); - } - } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); - } - - EX(object) = NULL; - ZEND_VM_NEXT_OPCODE(); -} - -ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) -{ - zend_bool nested; - zend_op_array *op_array = EX(op_array); - - EG(current_execute_data) = EX(prev_execute_data); - EG(opline_ptr) = NULL; - if (!EG(active_symbol_table)) { - zval ***cv = EX_CVs(); - zval ***end = cv + op_array->last_var; - while (cv != end) { - if (*cv) { - zval_ptr_dtor(*cv); - } - cv++; - } - } - - if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { - zval_ptr_dtor((zval**)&op_array->prototype); - } - - nested = EX(nested); - - zend_vm_stack_free(execute_data TSRMLS_CC); - - if (nested) { - execute_data = EG(current_execute_data); - } - if (nested) { - USE_OPLINE - - LOAD_REGS(); - LOAD_OPLINE(); - if (UNEXPECTED(opline->opcode == ZEND_INCLUDE_OR_EVAL)) { - - EX(function_state).function = (zend_function *) EX(op_array); - EX(function_state).arguments = NULL; - EX(object) = EX(current_object); - - EG(opline_ptr) = &EX(opline); - EG(active_op_array) = EX(op_array); - EG(return_value_ptr_ptr) = EX(original_return_value); - destroy_op_array(op_array TSRMLS_CC); - efree(op_array); - if (UNEXPECTED(EG(exception) != NULL)) { - zend_throw_exception_internal(NULL TSRMLS_CC); - HANDLE_EXCEPTION_LEAVE(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } - } - - ZEND_VM_INC_OPCODE(); - ZEND_VM_LEAVE(); - } else { - - EG(opline_ptr) = &EX(opline); - EG(active_op_array) = EX(op_array); - EG(return_value_ptr_ptr) = EX(original_return_value); - if (EG(active_symbol_table)) { - if (EG(symtable_cache_ptr)>=EG(symtable_cache_limit)) { - zend_hash_destroy(EG(active_symbol_table)); - FREE_HASHTABLE(EG(active_symbol_table)); - } else { - /* clean before putting into the cache, since clean - could call dtors, which could use cached hash */ - zend_hash_clean(EG(active_symbol_table)); - *(++EG(symtable_cache_ptr)) = EG(active_symbol_table); - } - } - EG(active_symbol_table) = EX(symbol_table); - - EX(function_state).function = (zend_function *) EX(op_array); - EX(function_state).arguments = NULL; - - if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { - Z_DELREF_P(EG(This)); - } - if (Z_REFCOUNT_P(EG(This)) == 1) { - zend_object_store_ctor_failed(EG(This) TSRMLS_CC); - } - } - zval_ptr_dtor(&EG(This)); - } - EG(This) = EX(current_this); - EG(scope) = EX(current_scope); - EG(called_scope) = EX(current_called_scope); - - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); - - zend_vm_stack_clear_multiple(TSRMLS_C); - - if (UNEXPECTED(EG(exception) != NULL)) { - zend_throw_exception_internal(NULL TSRMLS_CC); - if (RETURN_VALUE_USED(opline) && EX_T(opline->result.var).var.ptr) { - zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); - } - HANDLE_EXCEPTION_LEAVE(); - } - - ZEND_VM_INC_OPCODE(); - ZEND_VM_LEAVE(); - } - } - ZEND_VM_RETURN(); -} - -ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) -{ - USE_OPLINE - zend_bool should_change_scope = 0; - zend_function *fbc = EX(function_state).function; - - SAVE_OPLINE(); - if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { - if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { - zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); /* Never reached */ - } - if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { - zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", - fbc->common.scope ? fbc->common.scope->name : "", - fbc->common.scope ? "::" : "", - fbc->common.function_name); - } - } - if (fbc->common.scope && - !(fbc->common.fn_flags & ZEND_ACC_STATIC) && - !EX(object)) { - - if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - /* FIXME: output identifiers properly */ - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); - } else { - /* FIXME: output identifiers properly */ - /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically", fbc->common.scope->name, fbc->common.function_name); - } - } - - if (fbc->type == ZEND_USER_FUNCTION || fbc->common.scope) { - should_change_scope = 1; - EX(current_this) = EG(This); - EX(current_scope) = EG(scope); - EX(current_called_scope) = EG(called_scope); - EG(This) = EX(object); - EG(scope) = (fbc->type == ZEND_USER_FUNCTION || !EX(object)) ? fbc->common.scope : NULL; - EG(called_scope) = EX(called_scope); - } - - zend_arg_types_stack_3_pop(&EG(arg_types_stack), &EX(called_scope), &EX(current_object), &EX(fbc)); - EX(function_state).arguments = zend_vm_stack_push_args(opline->extended_value TSRMLS_CC); - LOAD_OPLINE(); - - if (fbc->type == ZEND_INTERNAL_FUNCTION) { - temp_variable *ret = &EX_T(opline->result.var); - - MAKE_STD_ZVAL(ret->var.ptr); - ZVAL_NULL(ret->var.ptr); - ret->var.ptr_ptr = &ret->var.ptr; - ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; - - if (fbc->common.arg_info) { - zend_uint i=0; - zval **p = (zval**)EX(function_state).arguments; - ulong arg_count = opline->extended_value; - - while (arg_count>0) { - zend_verify_arg_type(fbc, ++i, *(p-arg_count), 0 TSRMLS_CC); - arg_count--; + } else { + FREE_OP2(); } - } - - if (!zend_execute_internal) { - /* saves one function call if zend_execute_internal is not used */ - fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); - } else { - zend_execute_internal(EXECUTE_DATA, RETURN_VALUE_USED(opline) TSRMLS_CC); - } - - if (!RETURN_VALUE_USED(opline)) { - zval_ptr_dtor(&ret->var.ptr); - } - } else if (fbc->type == ZEND_USER_FUNCTION) { - EX(original_return_value) = EG(return_value_ptr_ptr); - EG(active_symbol_table) = NULL; - EG(active_op_array) = &fbc->op_array; - EG(return_value_ptr_ptr) = NULL; - if (RETURN_VALUE_USED(opline)) { - temp_variable *ret = &EX_T(opline->result.var); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); + } else if (OP2_TYPE != IS_CONST && + EXPECTED(Z_TYPE_P(function_name) == IS_ARRAY) && + zend_hash_num_elements(Z_ARRVAL_P(function_name)) == 2) { + zend_class_entry *ce; + zval **method = NULL; + zval **obj = NULL; - ret->var.ptr = NULL; - EG(return_value_ptr_ptr) = &ret->var.ptr; - ret->var.ptr_ptr = &ret->var.ptr; - ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; - } + zend_hash_index_find(Z_ARRVAL_P(function_name), 0, (void **) &obj); + zend_hash_index_find(Z_ARRVAL_P(function_name), 1, (void **) &method); - if (EXPECTED(zend_execute == execute)) { - if (EXPECTED(EG(exception) == NULL)) { - ZEND_VM_ENTER(); + if (Z_TYPE_PP(obj) != IS_STRING && Z_TYPE_PP(obj) != IS_OBJECT) { + zend_error_noreturn(E_ERROR, "First array member is not a valid class name or object"); } - } else { - zend_execute(EG(active_op_array) TSRMLS_CC); - } - EG(opline_ptr) = &EX(opline); - EG(active_op_array) = EX(op_array); - EG(return_value_ptr_ptr) = EX(original_return_value); - if (EG(active_symbol_table)) { - if (EG(symtable_cache_ptr)>=EG(symtable_cache_limit)) { - zend_hash_destroy(EG(active_symbol_table)); - FREE_HASHTABLE(EG(active_symbol_table)); - } else { - /* clean before putting into the cache, since clean - could call dtors, which could use cached hash */ - zend_hash_clean(EG(active_symbol_table)); - *(++EG(symtable_cache_ptr)) = EG(active_symbol_table); + if (Z_TYPE_PP(method) != IS_STRING) { + zend_error_noreturn(E_ERROR, "Second array member is not a valid method"); } - } - EG(active_symbol_table) = EX(symbol_table); - } else { /* ZEND_OVERLOADED_FUNCTION */ - MAKE_STD_ZVAL(EX_T(opline->result.var).var.ptr); - ZVAL_NULL(EX_T(opline->result.var).var.ptr); - - /* Not sure what should be done here if it's a static method */ - if (EXPECTED(EX(object) != NULL)) { - Z_OBJ_HT_P(EX(object))->call_method(fbc->common.function_name, opline->extended_value, EX_T(opline->result.var).var.ptr, &EX_T(opline->result.var).var.ptr, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); - } else { - zend_error_noreturn(E_ERROR, "Cannot call overloaded function for non-object"); - } - - if (fbc->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY) { - efree((char*)fbc->common.function_name); - } - efree(fbc); - if (!RETURN_VALUE_USED(opline)) { - zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); - } else { - Z_UNSET_ISREF_P(EX_T(opline->result.var).var.ptr); - Z_SET_REFCOUNT_P(EX_T(opline->result.var).var.ptr, 1); - EX_T(opline->result.var).var.fcall_returned_reference = 0; - EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; - } - } + if (Z_TYPE_PP(obj) == IS_STRING) { + ce = zend_fetch_class_by_name(Z_STRVAL_PP(obj), Z_STRLEN_PP(obj), NULL, 0 TSRMLS_CC); + if (UNEXPECTED(ce == NULL)) { + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); + } + EX(called_scope) = ce; + EX(object) = NULL; - EX(function_state).function = (zend_function *) EX(op_array); - EX(function_state).arguments = NULL; + if (ce->get_static_method) { + EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + } else { + EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + } + } else { + EX(object) = *obj; + ce = EX(called_scope) = Z_OBJCE_PP(obj); - if (should_change_scope) { - if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { - Z_DELREF_P(EG(This)); + EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); } - if (Z_REFCOUNT_P(EG(This)) == 1) { - zend_object_store_ctor_failed(EG(This) TSRMLS_CC); + + if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { + EX(object) = NULL; + } else { + if (!PZVAL_IS_REF(EX(object))) { + Z_ADDREF_P(EX(object)); /* For $this pointer */ + } else { + zval *this_ptr; + ALLOC_ZVAL(this_ptr); + INIT_PZVAL_COPY(this_ptr, EX(object)); + zval_copy_ctor(this_ptr); + EX(object) = this_ptr; + } } } - zval_ptr_dtor(&EG(This)); + + if (UNEXPECTED(EX(fbc) == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); + } + FREE_OP2(); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); + } else { + zend_error_noreturn(E_ERROR, "Function name must be a string"); } - EG(This) = EX(current_this); - EG(scope) = EX(current_scope); - EG(called_scope) = EX(current_called_scope); } +} - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); - zend_vm_stack_clear_multiple(TSRMLS_C); +ZEND_VM_HANDLER(69, ZEND_INIT_NS_FCALL_BY_NAME, ANY, CONST) +{ + USE_OPLINE + zend_literal *func_name; - if (UNEXPECTED(EG(exception) != NULL)) { - zend_throw_exception_internal(NULL TSRMLS_CC); - if (RETURN_VALUE_USED(opline) && EX_T(opline->result.var).var.ptr) { - zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); + zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + + func_name = opline->op2.literal + 1; + if (CACHED_PTR(opline->op2.literal->cache_slot)) { + EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE) { + func_name++; + if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE)) { + SAVE_OPLINE(); + zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); + } else { + CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); } - HANDLE_EXCEPTION(); + } else { + CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); } + EX(object) = NULL; ZEND_VM_NEXT_OPCODE(); } @@ -2878,10 +2975,10 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) } FREE_OP1_IF_VAR(); - if (EG(active_op_array)->has_finally_block) { - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); - } - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + if (EX(op_array)->has_finally_block) { + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); + } + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) @@ -2954,10 +3051,10 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) FREE_OP1_IF_VAR(); - if (EG(active_op_array)->has_finally_block) { - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN_BY_REF); - } - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + if (EX(op_array)->has_finally_block) { + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN_BY_REF); + } + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) @@ -3292,93 +3389,6 @@ ZEND_VM_HANDLER(52, ZEND_BOOL, CONST|TMP|VAR|CV, ANY) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) -{ - USE_OPLINE - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - - SAVE_OPLINE(); - - switch (type) { - case ZEND_THROW: - case ZEND_RETURN: - case ZEND_RETURN_BY_REF: - { - if (EG(prev_exception)) { - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } else { - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - } - - if (catch_op_num && finally_op_num) { - /* EG(exception) || EG(prev_exception) */ - if (catch_op_num > finally_op_num) { - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } - } else if (catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } else if (finally_op_num) { - EX(leaving) = type; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else if (EX(leaving)) { - /* leave it to ZEND_LEAVE */ - ZEND_VM_NEXT_OPCODE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } - break; - case ZEND_BRK: - case ZEND_CONT: - case ZEND_GOTO: - { - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op - && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op - || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - - if (finally_op_num) { - EX(leaving) = type; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); - } - } - break; - } - ZEND_VM_CONTINUE(); -} - ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) { USE_OPLINE @@ -3388,10 +3398,10 @@ ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); - if (EG(active_op_array)->has_finally_block) { - EX(leaving_dest) = el->brk; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_BRK); - } + if (EX(op_array)->has_finally_block) { + EX(leaving_dest) = el->brk; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_BRK); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } @@ -3404,10 +3414,10 @@ ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); - if (EG(active_op_array)->has_finally_block) { - EX(leaving_dest) = el->cont; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_CONT); - } + if (EG(active_op_array)->has_finally_block) { + EX(leaving_dest) = el->cont; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_CONT); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } @@ -3435,10 +3445,10 @@ ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) } break; } - if ((EG(active_op_array)->has_finally_block)) { - EX(leaving_dest) = opline->op1.jmp_addr - EG(active_op_array)->opcodes; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_GOTO); - } + if (EX(op_array)->has_finally_block) { + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_GOTO); + } ZEND_VM_JMP(opline->op1.jmp_addr); } @@ -5305,7 +5315,7 @@ ZEND_VM_HANDLER(153, ZEND_DECLARE_LAMBDA_FUNCTION, CONST, UNUSED) zend_function *op_array; SAVE_OPLINE(); - + if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(opline->op1.zv), Z_STRLEN_P(opline->op1.zv), Z_HASH_P(opline->op1.zv), (void *) &op_array) == FAILURE) || UNEXPECTED(op_array->type != ZEND_USER_FUNCTION)) { zend_error_noreturn(E_ERROR, "Base lambda function for closure not found"); @@ -5340,64 +5350,21 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) { - USE_OPLINE zend_exception_restore(TSRMLS_C); - if (!EX(leaving)) { ZEND_VM_NEXT_OPCODE(); } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - switch (EX(leaving)) { + zend_uint leaving = EX(leaving); + switch (leaving) { case ZEND_RETURN: case ZEND_RETURN_BY_REF: case ZEND_THROW: - { - if (EG(exception)) { - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } else { - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } - } else if (catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } else if (finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } - break; + leaving = ZEND_LEAVE; + case ZEND_JMP: case ZEND_BRK: case ZEND_CONT: case ZEND_GOTO: - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, EX(leaving)); + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, leaving); break; } } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 9818583334c6e..bd19124574131 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -427,33 +427,6 @@ ZEND_API void execute(zend_op_array *op_array TSRMLS_DC) zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); } -static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - USE_OPLINE - -#if DEBUG_ZEND>=2 - printf("Jumping to %d\n", opline->op1.opline_num); -#endif - ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); - ZEND_VM_CONTINUE(); /* CHECK_ME */ -} - -static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - USE_OPLINE - zval *tmp = &EX_T(opline->result.var).tmp_var; - - SAVE_OPLINE(); - tmp->value.str.val = emalloc(1); - tmp->value.str.val[0] = 0; - tmp->value.str.len = 0; - Z_SET_REFCOUNT_P(tmp, 1); - tmp->type = IS_STRING; - Z_UNSET_ISREF_P(tmp); - /*CHECK_EXCEPTION();*/ - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) { zend_bool nested; @@ -747,53 +720,6 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - EX(function_state).function = EX(fbc); - return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); -} - -static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - USE_OPLINE - zend_uint arg_num = opline->op1.num; - zval **param = zend_vm_stack_get_arg(arg_num TSRMLS_CC); - - SAVE_OPLINE(); - if (UNEXPECTED(param == NULL)) { - if (zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, NULL, opline->extended_value TSRMLS_CC)) { - const char *space; - const char *class_name; - zend_execute_data *ptr; - - if (EG(active_op_array)->scope) { - class_name = EG(active_op_array)->scope->name; - space = "::"; - } else { - class_name = space = ""; - } - ptr = EX(prev_execute_data); - - if(ptr && ptr->op_array) { - zend_error(E_WARNING, "Missing argument %u for %s%s%s(), called in %s on line %d and defined", opline->op1.num, class_name, space, get_active_function_name(TSRMLS_C), ptr->op_array->filename, ptr->opline->lineno); - } else { - zend_error(E_WARNING, "Missing argument %u for %s%s%s()", opline->op1.num, class_name, space, get_active_function_name(TSRMLS_C)); - } - } - } else { - zval **var_ptr; - - zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, *param, opline->extended_value TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); - Z_DELREF_PP(var_ptr); - *var_ptr = *param; - Z_ADDREF_PP(var_ptr); - } - - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -806,26 +732,27 @@ static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE case ZEND_THROW: case ZEND_RETURN: case ZEND_RETURN_BY_REF: + case ZEND_LEAVE: { - if (EG(prev_exception)) { - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + if (EG(prev_exception) || (type == ZEND_LEAVE && EG(exception))) { + for (i=0; ilast_try_catch; i++) { + if (EX(op_array)->try_catch_array[i].try_op > op_num) { break; } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + if (op_num < EX(op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; } - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; + if (op_num < EX(op_array)->try_catch_array[i].catch_op) { + catch_op_num = EX(op_array)->try_catch_array[i].catch_op; } } } else { - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + for (i=0; ilast_try_catch; i++) { + if (EX(op_array)->try_catch_array[i].try_op > op_num) { break; } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + if (op_num < EX(op_array)->try_catch_array[i].finally_op) { + finally_op_num = EX(op_array)->try_catch_array[i].finally_op; } } } @@ -843,44 +770,127 @@ static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE EX(leaving) = 0; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); } else if (finally_op_num) { - EX(leaving) = type; + if (type != ZEND_LEAVE) { + EX(leaving) = type; + } ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else if (EX(leaving)) { + } else if (EX(leaving) && type != ZEND_LEAVE) { /* leave it to ZEND_LEAVE */ + EX(leaving) = type; ZEND_VM_NEXT_OPCODE(); } else { return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } break; + case ZEND_JMP: case ZEND_BRK: case ZEND_CONT: case ZEND_GOTO: { - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op - && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op - || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - - if (finally_op_num) { - EX(leaving) = type; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); - } - } + /* these can not occurred in exception context */ + for (i=0; ilast_try_catch; i++) { + if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op + && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op + || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { + finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; + } + } + + if (finally_op_num) { + EX(leaving) = type; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); + } else { + EX(leaving) = 0; + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); + } + } break; } ZEND_VM_CONTINUE(); } +static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + USE_OPLINE + +#if DEBUG_ZEND>=2 + printf("Jumping to %d\n", opline->op1.opline_num); +#endif + if (EX(op_array)->has_finally_block) { + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + return zend_finally_handler_leaving_SPEC(ZEND_JMP, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); /* CHECK_ME */ +} + +static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + USE_OPLINE + zval *tmp = &EX_T(opline->result.var).tmp_var; + + SAVE_OPLINE(); + tmp->value.str.val = emalloc(1); + tmp->value.str.val[0] = 0; + tmp->value.str.len = 0; + Z_SET_REFCOUNT_P(tmp, 1); + tmp->type = IS_STRING; + Z_UNSET_ISREF_P(tmp); + /*CHECK_EXCEPTION();*/ + ZEND_VM_NEXT_OPCODE(); +} + +static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + EX(function_state).function = EX(fbc); + return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); +} + +static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + USE_OPLINE + zend_uint arg_num = opline->op1.num; + zval **param = zend_vm_stack_get_arg(arg_num TSRMLS_CC); + + SAVE_OPLINE(); + if (UNEXPECTED(param == NULL)) { + if (zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, NULL, opline->extended_value TSRMLS_CC)) { + const char *space; + const char *class_name; + zend_execute_data *ptr; + + if (EG(active_op_array)->scope) { + class_name = EG(active_op_array)->scope->name; + space = "::"; + } else { + class_name = space = ""; + } + ptr = EX(prev_execute_data); + + if(ptr && ptr->op_array) { + zend_error(E_WARNING, "Missing argument %u for %s%s%s(), called in %s on line %d and defined", opline->op1.num, class_name, space, get_active_function_name(TSRMLS_C), ptr->op_array->filename, ptr->opline->lineno); + } else { + zend_error(E_WARNING, "Missing argument %u for %s%s%s()", opline->op1.num, class_name, space, get_active_function_name(TSRMLS_C)); + } + } + } else { + zval **var_ptr; + + zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, *param, opline->extended_value TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); + Z_DELREF_PP(var_ptr); + *var_ptr = *param; + Z_ADDREF_PP(var_ptr); + } + + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); +} + static int ZEND_FASTCALL ZEND_NEW_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1264,64 +1274,21 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - USE_OPLINE zend_exception_restore(TSRMLS_C); - if (!EX(leaving)) { ZEND_VM_NEXT_OPCODE(); } else { - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - switch (EX(leaving)) { + zend_uint leaving = EX(leaving); + switch (leaving) { case ZEND_RETURN: case ZEND_RETURN_BY_REF: case ZEND_THROW: - { - if (EG(exception)) { - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { - catch_op_num = EG(active_op_array)->try_catch_array[i].catch_op; - } - } - } else { - for (i = 0; i < EX(leaving); i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - } - - if (catch_op_num && finally_op_num) { - if (catch_op_num > finally_op_num) { - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } - } else if (catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } else if (finally_op_num) { - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } - break; + leaving = ZEND_LEAVE; + case ZEND_JMP: case ZEND_BRK: case ZEND_CONT: case ZEND_GOTO: - return zend_finally_handler_leaving_SPEC(EX(leaving), ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(leaving, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; } } @@ -1563,10 +1530,10 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); - if (EG(active_op_array)->has_finally_block) { - EX(leaving_dest) = el->brk; - return zend_finally_handler_leaving_SPEC(ZEND_BRK, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } + if (EX(op_array)->has_finally_block) { + EX(leaving_dest) = el->brk; + return zend_finally_handler_leaving_SPEC(ZEND_BRK, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } @@ -1579,10 +1546,10 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); - if (EG(active_op_array)->has_finally_block) { - EX(leaving_dest) = el->cont; - return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } + if (EG(active_op_array)->has_finally_block) { + EX(leaving_dest) = el->cont; + return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } @@ -1610,10 +1577,10 @@ static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } break; } - if ((EG(active_op_array)->has_finally_block)) { - EX(leaving_dest) = opline->op1.jmp_addr - EG(active_op_array)->opcodes; - return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } + if (EX(op_array)->has_finally_block) { + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + return zend_finally_handler_leaving_SPEC(ZEND_GOTO, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } ZEND_VM_JMP(opline->op1.jmp_addr); } @@ -2465,10 +2432,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG *EG(return_value_ptr_ptr) = ret; } - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2539,10 +2506,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7015,10 +6982,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7089,10 +7056,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11471,10 +11438,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11547,10 +11514,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27490,10 +27457,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27564,10 +27531,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - if (EG(active_op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) From a90170e6f803f283d6c8e4e8d6b7bd8b7bd011a4 Mon Sep 17 00:00:00 2001 From: Sebastian Bergmann Date: Wed, 22 Aug 2012 11:19:29 +0200 Subject: [PATCH 2026/2394] WTF? --- NEWS | 1 - 1 file changed, 1 deletion(-) diff --git a/NEWS b/NEWS index f4df4463fa782..00f8ec6be9ec0 100644 --- a/NEWS +++ b/NEWS @@ -5,7 +5,6 @@ PHP NEWS - General improvements: . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) . Drop Windows XP and 2003 support. (Pierre) - . World domination . Improve set_exception_handler while doing reset.(Laruence) . Support constant array/string dereferencing. (Laruence) . Add support for using empty() on the result of function calls and From 815874c646468f73d4bba3619543ab047873b5e7 Mon Sep 17 00:00:00 2001 From: andrey Date: Wed, 22 Aug 2012 20:04:42 +0200 Subject: [PATCH 2027/2394] plug a leak when the server ask the client for a auth protocol, that the client doesn't understand. This is 5.5 specific bug, as a result of a refactoring in 5.5 --- ext/mysqlnd/mysqlnd.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 9a907a5644d81..d7462f77a54b6 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -622,19 +622,19 @@ mysqlnd_run_authentication( } DBG_INF_FMT("conn->error_info->error_no = %d", conn->error_info->error_no); } while (ret == FAIL && conn->error_info->error_no == 0 && switch_to_auth_protocol != NULL); - if (plugin_data) { - mnd_efree(plugin_data); - } if (ret == PASS) { DBG_INF_FMT("saving requested_protocol=%s", requested_protocol); conn->m->set_client_option(conn, MYSQLND_OPT_AUTH_PROTOCOL, requested_protocol TSRMLS_CC); } - +end: + if (plugin_data) { + mnd_efree(plugin_data); + } if (requested_protocol) { mnd_efree(requested_protocol); } -end: + DBG_RETURN(ret); } /* }}} */ @@ -838,6 +838,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, connect)(MYSQLND_CONN_DATA * conn, MYSQLND_NET * net = conn->net; DBG_ENTER("mysqlnd_conn_data::connect"); + DBG_INF_FMT("conn=%p", conn); if (PASS != conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { goto err; @@ -1149,7 +1150,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, query)(MYSQLND_CONN_DATA * conn, const char * size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, query); enum_func_status ret = FAIL; DBG_ENTER("mysqlnd_conn_data::query"); - DBG_INF_FMT("conn=%llu query=%s", conn->thread_id, query); + DBG_INF_FMT("conn=%p conn=%llu query=%s", conn, conn->thread_id, query); if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { if (PASS == conn->m->send_query(conn, query, query_len TSRMLS_CC) && @@ -1883,10 +1884,10 @@ MYSQLND_METHOD(mysqlnd_conn_data, send_close)(MYSQLND_CONN_DATA * const conn TSR Fall-through */ CONN_SET_STATE(conn, CONN_QUIT_SENT); - net->data->m.close_stream(net, conn->stats, conn->error_info TSRMLS_CC); /* Fall-through */ case CONN_QUIT_SENT: /* The user has killed its own connection */ + net->data->m.close_stream(net, conn->stats, conn->error_info TSRMLS_CC); break; } @@ -2446,7 +2447,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, store_result)(MYSQLND_CONN_DATA * const conn T MYSQLND_RES * result = NULL; DBG_ENTER("mysqlnd_conn_data::store_result"); - DBG_INF_FMT("conn=%llu", conn->thread_id); + DBG_INF_FMT("conn=%llu conn=%p", conn->thread_id, conn); if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { do { From b9eae3d67c10ccaf83e85e36777704f276f0ffae Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 21 Aug 2012 23:21:59 +0200 Subject: [PATCH 2028/2394] Fix handling of several uinitialized intl objects Master specific changes. Not having this in the merge commit helps porting to pecl/intl --- ext/intl/dateformat/dateformat_create.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/intl/dateformat/dateformat_create.cpp b/ext/intl/dateformat/dateformat_create.cpp index 7fefbe7449c67..a2899f7974618 100644 --- a/ext/intl/dateformat/dateformat_create.cpp +++ b/ext/intl/dateformat/dateformat_create.cpp @@ -76,7 +76,7 @@ static void datefmt_ctor(INTERNAL_FUNCTION_PARAMETERS) } locale = Locale::createFromName(locale_str); - DATE_FORMAT_METHOD_FETCH_OBJECT; + DATE_FORMAT_METHOD_FETCH_OBJECT_NO_CHECK; if (DATE_FORMAT_OBJECT(dfo) != NULL) { intl_errors_set(INTL_DATA_ERROR_P(dfo), U_ILLEGAL_ARGUMENT_ERROR, From 68c1e1cfe95b026086cacf40a005ea8f399e9595 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 24 Aug 2012 13:51:39 +0200 Subject: [PATCH 2029/2394] Add dedicated opcode for returns from a generator Generators don't have a return value, so it doesn't make sense to have a shared implementation here. --- Zend/zend_opcode.c | 5 ++- Zend/zend_vm_def.h | 19 +++++------ Zend/zend_vm_execute.h | 77 ++++++++++++++++++------------------------ Zend/zend_vm_opcodes.h | 1 + 4 files changed, 44 insertions(+), 58 deletions(-) diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 0f39b8a41d817..5c4b20fd34820 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -586,9 +586,8 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) CG(zend_lineno) = opline->lineno; zend_error(E_COMPILE_ERROR, "Generators cannot return values using \"return\""); } - if (opline->opcode == ZEND_RETURN_BY_REF) { - opline->opcode = ZEND_RETURN; - } + + opline->opcode = ZEND_GENERATOR_RETURN; } break; } diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 975a2a70717a2..216cd59bdbc4e 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2931,17 +2931,6 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) zval *retval_ptr; zend_free_op free_op1; - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - SAVE_OPLINE(); retval_ptr = GET_OP1_ZVAL_PTR(BP_VAR_R); @@ -3066,6 +3055,14 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } +ZEND_VM_HANDLER(162, ZEND_GENERATOR_RETURN, ANY, ANY) +{ + if (EX(op_array)->has_finally_block) { + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); + } + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); +} + ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) { USE_OPLINE diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 402442f23a6be..ebc0fb9c49cc3 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -885,6 +885,14 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } +static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + if (EX(op_array)->has_finally_block) { + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); +} + static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2443,17 +2451,6 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG zval *retval_ptr; - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - SAVE_OPLINE(); retval_ptr = opline->op1.zv; @@ -7760,17 +7757,6 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *retval_ptr; zend_free_op free_op1; - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - SAVE_OPLINE(); retval_ptr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); @@ -12982,17 +12968,6 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *retval_ptr; zend_free_op free_op1; - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - SAVE_OPLINE(); retval_ptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); @@ -30530,17 +30505,6 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *retval_ptr; - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - SAVE_OPLINE(); retval_ptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); @@ -44986,6 +44950,31 @@ void zend_init_opcodes_handlers(void) ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, ZEND_NULL_HANDLER }; zend_opcode_handlers = (opcode_handler_t*)labels; diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 0a9cf008e3ef5..0b4903ac3651a 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -162,3 +162,4 @@ #define ZEND_LEAVE 159 #define ZEND_YIELD 160 #define ZEND_DELEGATE_YIELD 161 +#define ZEND_GENERATOR_RETURN 162 From 7cdf6367a51a54fce8676aeb6fd32bf91b00f84b Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 24 Aug 2012 13:52:16 +0200 Subject: [PATCH 2030/2394] Finally with return now works in generators too --- .../tests/generators/finally_with_return.phpt | 33 +++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 Zend/tests/generators/finally_with_return.phpt diff --git a/Zend/tests/generators/finally_with_return.phpt b/Zend/tests/generators/finally_with_return.phpt new file mode 100644 index 0000000000000..b26a49f32fa3b --- /dev/null +++ b/Zend/tests/generators/finally_with_return.phpt @@ -0,0 +1,33 @@ +--TEST-- +Use of finally in generator with return +--FILE-- +rewind(); // force run + +?> +--EXPECTF-- +before return +before return in inner finally +outer finally run From 4d8edda341efef1901365f10213c027e745ac7ab Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 24 Aug 2012 15:50:53 +0200 Subject: [PATCH 2031/2394] Run finally if generator is closed before finishing --- .../generators/finally_ran_on_close.phpt | 25 +++++++++++++ Zend/zend_generators.c | 35 ++++++++++++++++++- Zend/zend_generators.h | 1 + 3 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 Zend/tests/generators/finally_ran_on_close.phpt diff --git a/Zend/tests/generators/finally_ran_on_close.phpt b/Zend/tests/generators/finally_ran_on_close.phpt new file mode 100644 index 0000000000000..44a84fae5c799 --- /dev/null +++ b/Zend/tests/generators/finally_ran_on_close.phpt @@ -0,0 +1,25 @@ +--TEST-- +finally is run even if a generator is closed mid-execution +--FILE-- +rewind(); +unset($gen); + +?> +--EXPECT-- +before yield +finally run diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index b4d8932b6bbfd..3170ec9c33d69 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -32,6 +32,39 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio if (generator->execute_data) { zend_execute_data *execute_data = generator->execute_data; + if (!finished_execution) { + zend_op_array *op_array = execute_data->op_array; + if (op_array->has_finally_block) { + zend_uint op_num = execute_data->opline - op_array->opcodes; + zend_uint finally_op_num = 0; + + /* Find next finally block */ + int i; + for (i = 0; i < op_array->last_try_catch; i++) { + zend_try_catch_element *try_catch = &op_array->try_catch_array[i]; + + if (op_num < try_catch->try_op) { + break; + } + + if (op_num < try_catch->finally_op) { + finally_op_num = try_catch->finally_op; + } + } + + /* If a finally block was found we jump directly to it and + * resume the generator. Furthermore we abort this close call + * because the generator will already be closed somewhere in + * the resume. */ + if (finally_op_num) { + execute_data->opline = &op_array->opcodes[finally_op_num]; + execute_data->leaving = ZEND_RETURN; + zend_generator_resume(generator TSRMLS_CC); + return; + } + } + } + if (!execute_data->symbol_table) { zend_free_compiled_variables(execute_data->CVs, execute_data->op_array->last_var); } else { @@ -371,7 +404,7 @@ static zend_function *zend_generator_get_constructor(zval *object TSRMLS_DC) /* } /* }}} */ -static void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ +void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ { /* The generator is already closed, thus can't resume */ if (!generator->execute_data) { diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index f5f4926e353f2..37ffbbd6ccbb9 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -53,6 +53,7 @@ extern ZEND_API zend_class_entry *zend_ce_generator; void zend_register_generator_ce(TSRMLS_D); zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC); void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC); +void zend_generator_resume(zend_generator *generator TSRMLS_DC); END_EXTERN_C() From e5ff3f18f5706a0bdf26bf0a68cfa22607d006ff Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Fri, 24 Aug 2012 18:04:16 -0400 Subject: [PATCH 2032/2394] Update bad versions for cURL constants This was updated according to the cURL symbol tables located here : http://curl.haxx.se/libcurl/c/symbols-in-versions.html --- ext/curl/interface.c | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 8050351d948c6..c31bce468e865 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -925,7 +925,11 @@ PHP_MINIT_FUNCTION(curl) #endif #if LIBCURL_VERSION_NUM >= 0x071001 /* Available since 7.16.1 */ + REGISTER_CURL_CONSTANT(CURLE_SSH); REGISTER_CURL_CONSTANT(CURLOPT_FTP_SSL_CCC); + REGISTER_CURL_CONSTANT(CURLOPT_SSH_AUTH_TYPES); + REGISTER_CURL_CONSTANT(CURLOPT_SSH_PRIVATE_KEYFILE); + REGISTER_CURL_CONSTANT(CURLOPT_SSH_PUBLIC_KEYFILE); REGISTER_CURL_CONSTANT(CURLFTPSSL_CCC_ACTIVE); REGISTER_CURL_CONSTANT(CURLFTPSSL_CCC_NONE); REGISTER_CURL_CONSTANT(CURLFTPSSL_CCC_PASSIVE); @@ -940,13 +944,13 @@ PHP_MINIT_FUNCTION(curl) #if LIBCURL_VERSION_NUM >= 0x071004 /* Available since 7.16.4 */ REGISTER_CURL_CONSTANT(CURLOPT_KRBLEVEL); + REGISTER_CURL_CONSTANT(CURLOPT_NEW_DIRECTORY_PERMS); + REGISTER_CURL_CONSTANT(CURLOPT_NEW_FILE_PERMS); #endif #if LIBCURL_VERSION_NUM >= 0x071100 /* Available since 7.17.0 */ REGISTER_CURL_CONSTANT(CURLOPT_APPEND); REGISTER_CURL_CONSTANT(CURLOPT_DIRLISTONLY); - REGISTER_CURL_CONSTANT(CURLOPT_NEW_DIRECTORY_PERMS); - REGISTER_CURL_CONSTANT(CURLOPT_NEW_FILE_PERMS); REGISTER_CURL_CONSTANT(CURLOPT_USE_SSL); /* Curl SSL Constants */ REGISTER_CURL_CONSTANT(CURLUSESSL_ALL); @@ -955,6 +959,10 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLUSESSL_TRY); #endif +#if LIBCURL_VERSION_NUM >= 0x071101 /* Available since 7.17.1 */ + REGISTER_CURL_CONSTANT(CURLOPT_SSH_HOST_PUBLIC_KEY_MD5); +#endif + #if LIBCURL_VERSION_NUM >= 0x071200 /* Available since 7.18.0 */ REGISTER_CURL_CONSTANT(CURLOPT_PROXY_TRANSFER_MODE); #endif @@ -964,7 +972,6 @@ PHP_MINIT_FUNCTION(curl) #endif #if LIBCURL_VERSION_NUM >= 0x071300 /* Available since 7.19.0 */ - REGISTER_CURL_CONSTANT(CURLE_SSH); REGISTER_CURL_CONSTANT(CURLINFO_APPCONNECT_TIME); REGISTER_CURL_CONSTANT(CURLINFO_PRIMARY_IP); @@ -972,10 +979,6 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_CRLFILE); REGISTER_CURL_CONSTANT(CURLOPT_ISSUERCERT); REGISTER_CURL_CONSTANT(CURLOPT_KEYPASSWD); - REGISTER_CURL_CONSTANT(CURLOPT_SSH_AUTH_TYPES); - REGISTER_CURL_CONSTANT(CURLOPT_SSH_HOST_PUBLIC_KEY_MD5); - REGISTER_CURL_CONSTANT(CURLOPT_SSH_PRIVATE_KEYFILE); - REGISTER_CURL_CONSTANT(CURLOPT_SSH_PUBLIC_KEYFILE); REGISTER_CURL_CONSTANT(CURLSSH_AUTH_ANY); REGISTER_CURL_CONSTANT(CURLSSH_AUTH_DEFAULT); @@ -2085,6 +2088,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #endif #if LIBCURL_VERSION_NUM >= 0x071001 /* Available since 7.16.1 */ case CURLOPT_FTP_SSL_CCC: + case CURLOPT_SSH_AUTH_TYPES: #endif #if LIBCURL_VERSION_NUM >= 0x071002 /* Available since 7.16.2 */ case CURLOPT_CONNECTTIMEOUT_MS: @@ -2092,6 +2096,10 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_HTTP_TRANSFER_DECODING: case CURLOPT_TIMEOUT_MS: #endif +#if LIBCURL_VERSION_NUM >= 0x071004 /* Available since 7.16.4 */ + case CURLOPT_NEW_DIRECTORY_PERMS: + case CURLOPT_NEW_FILE_PERMS: +#endif #if LIBCURL_VERSION_NUM >= 0x071100 /* Available since 7.17.0 */ case CURLOPT_USE_SSL: #elif LIBCURL_VERSION_NUM >= 0x070b00 /* Available since 7.11.0 */ @@ -2100,8 +2108,6 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #if LIBCURL_VERSION_NUM >= 0x071100 /* Available since 7.17.0 */ case CURLOPT_APPEND: case CURLOPT_DIRLISTONLY: - case CURLOPT_NEW_DIRECTORY_PERMS: - case CURLOPT_NEW_FILE_PERMS: #else case CURLOPT_FTPAPPEND: case CURLOPT_FTPLISTONLY: @@ -2111,7 +2117,6 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #endif #if LIBCURL_VERSION_NUM >= 0x071300 /* Available since 7.19.0 */ case CURLOPT_ADDRESS_SCOPE: - case CURLOPT_SSH_AUTH_TYPES: #endif #if LIBCURL_VERSION_NUM > 0x071301 /* Available since 7.19.1 */ case CURLOPT_CERTINFO: @@ -2187,7 +2192,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #else case CURLOPT_KRB4LEVEL: #endif -#if LIBCURL_VERSION_NUM >= 0x071300 /* Available since 7.19.0 */ +#if LIBCURL_VERSION_NUM >= 0x071101 /* Available since 7.17.1 */ case CURLOPT_SSH_HOST_PUBLIC_KEY_MD5: #endif #if LIBCURL_VERSION_NUM >= 0x071301 /* Available since 7.19.1 */ @@ -2631,11 +2636,13 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #if LIBCURL_VERSION_NUM >= 0x070b00 /* Available since 7.11.0 */ case CURLOPT_NETRC_FILE: #endif +#if LIBCURL_VERSION_NUM >= 0x071001 /* Available since 7.16.1 */ + case CURLOPT_SSH_PRIVATE_KEYFILE: + case CURLOPT_SSH_PUBLIC_KEYFILE: +#endif #if LIBCURL_VERSION_NUM >= 0x071300 /* Available since 7.19.0 */ case CURLOPT_CRLFILE: case CURLOPT_ISSUERCERT: - case CURLOPT_SSH_PRIVATE_KEYFILE: - case CURLOPT_SSH_PUBLIC_KEYFILE: #endif #if LIBCURL_VERSION_NUM >= 0x071306 /* Available since 7.19.6 */ case CURLOPT_SSH_KNOWNHOSTS: From 9ab45d3edbafa3ee751472c3f8d1fb3f51f38cf1 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sat, 25 Aug 2012 01:21:17 -0400 Subject: [PATCH 2033/2394] Add missing constants in cURL --- ext/curl/interface.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index c31bce468e865..899ea603c13ba 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -638,7 +638,6 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_QUOTE); REGISTER_CURL_CONSTANT(CURLOPT_RANDOM_FILE); REGISTER_CURL_CONSTANT(CURLOPT_RANGE); - REGISTER_CURL_CONSTANT(CURLOPT_READDATA); REGISTER_CURL_CONSTANT(CURLOPT_READFUNCTION); REGISTER_CURL_CONSTANT(CURLOPT_REFERER); REGISTER_CURL_CONSTANT(CURLOPT_RESUME_FROM); @@ -681,6 +680,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLE_ABORTED_BY_CALLBACK); REGISTER_CURL_CONSTANT(CURLE_BAD_CALLING_ORDER); REGISTER_CURL_CONSTANT(CURLE_BAD_CONTENT_ENCODING); + REGISTER_CURL_CONSTANT(CURLE_BAD_DOWNLOAD_RESUME); REGISTER_CURL_CONSTANT(CURLE_BAD_FUNCTION_ARGUMENT); REGISTER_CURL_CONSTANT(CURLE_BAD_PASSWORD_ENTERED); REGISTER_CURL_CONSTANT(CURLE_COULDNT_CONNECT); @@ -713,12 +713,14 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLE_HTTP_PORT_FAILED); REGISTER_CURL_CONSTANT(CURLE_HTTP_POST_ERROR); REGISTER_CURL_CONSTANT(CURLE_HTTP_RANGE_ERROR); + REGISTER_CURL_CONSTANT(CURLE_HTTP_RETURNED_ERROR); REGISTER_CURL_CONSTANT(CURLE_LDAP_CANNOT_BIND); REGISTER_CURL_CONSTANT(CURLE_LDAP_SEARCH_FAILED); REGISTER_CURL_CONSTANT(CURLE_LIBRARY_NOT_FOUND); REGISTER_CURL_CONSTANT(CURLE_MALFORMAT_USER); REGISTER_CURL_CONSTANT(CURLE_OBSOLETE); REGISTER_CURL_CONSTANT(CURLE_OK); + REGISTER_CURL_CONSTANT(CURLE_OPERATION_TIMEDOUT); REGISTER_CURL_CONSTANT(CURLE_OPERATION_TIMEOUTED); REGISTER_CURL_CONSTANT(CURLE_OUT_OF_MEMORY); REGISTER_CURL_CONSTANT(CURLE_PARTIAL_FILE); @@ -751,6 +753,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLINFO_HEADER_OUT); REGISTER_CURL_CONSTANT(CURLINFO_HEADER_SIZE); REGISTER_CURL_CONSTANT(CURLINFO_HTTP_CODE); + REGISTER_CURL_CONSTANT(CURLINFO_LASTONE); REGISTER_CURL_CONSTANT(CURLINFO_NAMELOOKUP_TIME); REGISTER_CURL_CONSTANT(CURLINFO_PRETRANSFER_TIME); REGISTER_CURL_CONSTANT(CURLINFO_PRIVATE); From 326aa087532d7eaecc8fefff58bb2a0b008b5ac8 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 25 Aug 2012 21:14:51 +0800 Subject: [PATCH 2034/2394] Prefer no finally block for most situations --- Zend/zend_vm_def.h | 48 ++++++++++++------------ Zend/zend_vm_execute.h | 84 +++++++++++++++++++++--------------------- 2 files changed, 68 insertions(+), 64 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index ce1674e4f3834..92c5fcf40fe7f 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2173,6 +2173,7 @@ ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) if (catch_op_num && finally_op_num) { /* EG(exception) || EG(prev_exception) */ if (catch_op_num > finally_op_num) { + zend_exception_save(TSRMLS_C); EX(leaving) = ZEND_THROW; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); } else { @@ -2183,6 +2184,7 @@ ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) EX(leaving) = 0; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); } else if (finally_op_num) { + zend_exception_save(TSRMLS_C); if (type != ZEND_LEAVE) { EX(leaving) = type; } @@ -2233,12 +2235,12 @@ ZEND_VM_HANDLER(42, ZEND_JMP, ANY, ANY) #if DEBUG_ZEND>=2 printf("Jumping to %d\n", opline->op1.opline_num); #endif - if (EX(op_array)->has_finally_block) { - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_JMP); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); /* CHECK_ME */ } - ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); - ZEND_VM_CONTINUE(); /* CHECK_ME */ + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_JMP); } ZEND_VM_HANDLER(43, ZEND_JMPZ, CONST|TMP|VAR|CV, ANY) @@ -2975,10 +2977,10 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) } FREE_OP1_IF_VAR(); - if (EX(op_array)->has_finally_block) { - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); } ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) @@ -3051,10 +3053,10 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) FREE_OP1_IF_VAR(); - if (EX(op_array)->has_finally_block) { - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN_BY_REF); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN_BY_REF); } ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) @@ -3398,11 +3400,11 @@ ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); - if (EX(op_array)->has_finally_block) { - EX(leaving_dest) = el->brk; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_BRK); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } - ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); + EX(leaving_dest) = el->brk; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_BRK); } ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) @@ -3414,11 +3416,11 @@ ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); - if (EG(active_op_array)->has_finally_block) { - EX(leaving_dest) = el->cont; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_CONT); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } - ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); + EX(leaving_dest) = el->cont; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_CONT); } ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) @@ -3445,11 +3447,11 @@ ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) } break; } - if (EX(op_array)->has_finally_block) { - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_GOTO); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_JMP(opline->op1.jmp_addr); } - ZEND_VM_JMP(opline->op1.jmp_addr); + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_GOTO); } ZEND_VM_HANDLER(48, ZEND_CASE, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index bd19124574131..1e0b2b50a98d4 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -760,6 +760,7 @@ static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE if (catch_op_num && finally_op_num) { /* EG(exception) || EG(prev_exception) */ if (catch_op_num > finally_op_num) { + zend_exception_save(TSRMLS_C); EX(leaving) = ZEND_THROW; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); } else { @@ -770,6 +771,7 @@ static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE EX(leaving) = 0; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); } else if (finally_op_num) { + zend_exception_save(TSRMLS_C); if (type != ZEND_LEAVE) { EX(leaving) = type; } @@ -820,12 +822,12 @@ static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) #if DEBUG_ZEND>=2 printf("Jumping to %d\n", opline->op1.opline_num); #endif - if (EX(op_array)->has_finally_block) { - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - return zend_finally_handler_leaving_SPEC(ZEND_JMP, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); /* CHECK_ME */ } - ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); - ZEND_VM_CONTINUE(); /* CHECK_ME */ + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + return zend_finally_handler_leaving_SPEC(ZEND_JMP, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1530,11 +1532,11 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); - if (EX(op_array)->has_finally_block) { - EX(leaving_dest) = el->brk; - return zend_finally_handler_leaving_SPEC(ZEND_BRK, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } - ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); + EX(leaving_dest) = el->brk; + return zend_finally_handler_leaving_SPEC(ZEND_BRK, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1546,11 +1548,11 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); - if (EG(active_op_array)->has_finally_block) { - EX(leaving_dest) = el->cont; - return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } - ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); + EX(leaving_dest) = el->cont; + return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1577,11 +1579,11 @@ static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } break; } - if (EX(op_array)->has_finally_block) { - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - return zend_finally_handler_leaving_SPEC(ZEND_GOTO, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + ZEND_VM_JMP(opline->op1.jmp_addr); } - ZEND_VM_JMP(opline->op1.jmp_addr); + EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; + return zend_finally_handler_leaving_SPEC(ZEND_GOTO, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2432,10 +2434,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG *EG(return_value_ptr_ptr) = ret; } - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2506,10 +2508,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -6982,10 +6984,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7056,10 +7058,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11438,10 +11440,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -11514,10 +11516,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27457,10 +27459,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -27531,10 +27533,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (EXPECTED(!EX(op_array)->has_finally_block)) { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) From 35951d4be0bd27c85519995a95429bd0d0a76a00 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 25 Aug 2012 22:23:14 +0800 Subject: [PATCH 2035/2394] Support list in foreach RFC: https://wiki.php.net/rfc/foreachlist --- NEWS | 1 + UPGRADING | 2 ++ Zend/tests/foreach_list.phpt | 43 +++++++++++++++++++++++++++++++++ Zend/zend_compile.c | 17 ++++++++----- Zend/zend_compile.h | 1 + Zend/zend_language_parser.y | 4 +-- tests/lang/foreachLoop.007.phpt | 2 +- 7 files changed, 61 insertions(+), 9 deletions(-) create mode 100644 Zend/tests/foreach_list.phpt diff --git a/NEWS b/NEWS index 00f8ec6be9ec0..28b89baaac379 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,7 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Support list in foreach (https://wiki.php.net/rfc/foreachlist). (Laruence) . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) . Drop Windows XP and 2003 support. (Pierre) . Improve set_exception_handler while doing reset.(Laruence) diff --git a/UPGRADING b/UPGRADING index aeab14b48fce9..ba556357ed489 100755 --- a/UPGRADING +++ b/UPGRADING @@ -31,6 +31,8 @@ PHP X.Y UPGRADE NOTES 2. New Features ======================================== +- Support list in foreach. (Laruence) + (wiki.php.net/rfc/foreachlist) - Support finally keyword. (Laruence) (wiki.php.net/rfc/finally) - Support constant array/string dereferencing. (Laruence) diff --git a/Zend/tests/foreach_list.phpt b/Zend/tests/foreach_list.phpt new file mode 100644 index 0000000000000..a318f1aad955a --- /dev/null +++ b/Zend/tests/foreach_list.phpt @@ -0,0 +1,43 @@ +--TEST-- +foreach with list syntax +--FILE-- + list(list($a, $b), list($c, $d))) { + var_dump($key . $a . $b . $c . $d); +} + + +?> +--EXPECT-- +string(2) "12" +string(2) "34" +string(2) "ab" +string(2) "cd" +string(4) "1234" +string(4) "5678" +string(5) "01234" +string(5) "15678" diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 2665870ab4f7c..b87b1908b6bde 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6320,13 +6320,18 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token GET_NODE(&value_node, opline->result); - if (assign_by_ref) { - zend_do_end_variable_parse(value, BP_VAR_W, 0 TSRMLS_CC); - /* Mark FE_FETCH as IS_VAR as it holds the data directly as a value */ - zend_do_assign_ref(NULL, value, &value_node TSRMLS_CC); - } else { - zend_do_assign(&dummy, value, &value_node TSRMLS_CC); + if (value->EA & ZEND_PARSED_LIST_EXPR) { + zend_do_list_end(&dummy, &value_node TSRMLS_CC); zend_do_free(&dummy TSRMLS_CC); + } else { + if (assign_by_ref) { + zend_do_end_variable_parse(value, BP_VAR_W, 0 TSRMLS_CC); + /* Mark FE_FETCH as IS_VAR as it holds the data directly as a value */ + zend_do_assign_ref(NULL, value, &value_node TSRMLS_CC); + } else { + zend_do_assign(&dummy, value, &value_node TSRMLS_CC); + zend_do_free(&dummy TSRMLS_CC); + } } if (key->op_type != IS_UNUSED) { diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 971860602eeaf..15c2ab7bc7998 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -725,6 +725,7 @@ int zend_add_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC); #define ZEND_PARSED_VARIABLE (1<<4) #define ZEND_PARSED_REFERENCE_VARIABLE (1<<5) #define ZEND_PARSED_NEW (1<<6) +#define ZEND_PARSED_LIST_EXPR (1<<7) /* unset types */ diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index cef82e3353227..32f35fa25250d 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -310,7 +310,7 @@ unticked_statement: foreach_statement { zend_do_foreach_end(&$1, &$4 TSRMLS_CC); } | T_FOREACH '(' expr_without_variable T_AS { zend_do_foreach_begin(&$1, &$2, &$3, &$4, 0 TSRMLS_CC); } - variable foreach_optional_arg ')' { zend_check_writable_variable(&$6); zend_do_foreach_cont(&$1, &$2, &$4, &$6, &$7 TSRMLS_CC); } + foreach_variable foreach_optional_arg ')' { zend_check_writable_variable(&$6); zend_do_foreach_cont(&$1, &$2, &$4, &$6, &$7 TSRMLS_CC); } foreach_statement { zend_do_foreach_end(&$1, &$4 TSRMLS_CC); } | T_DECLARE { $1.u.op.opline_num = get_next_op_number(CG(active_op_array)); zend_do_declare_begin(TSRMLS_C); } '(' declare_list ')' declare_statement { zend_do_declare_end(&$1 TSRMLS_CC); } | ';' /* empty statement */ @@ -429,10 +429,10 @@ foreach_optional_arg: | T_DOUBLE_ARROW foreach_variable { $$ = $2; } ; - foreach_variable: variable { zend_check_writable_variable(&$1); $$ = $1; } | '&' variable { zend_check_writable_variable(&$2); $$ = $2; $$.EA |= ZEND_PARSED_REFERENCE_VARIABLE; } + | T_LIST '(' { zend_do_list_init(TSRMLS_C); } assignment_list ')' { $$ = $1; $$.EA = ZEND_PARSED_LIST_EXPR; } ; for_statement: diff --git a/tests/lang/foreachLoop.007.phpt b/tests/lang/foreachLoop.007.phpt index f47fdc735fa36..269286d02427d 100644 --- a/tests/lang/foreachLoop.007.phpt +++ b/tests/lang/foreachLoop.007.phpt @@ -8,4 +8,4 @@ foreach (array(1,2) as &$v) { } ?> --EXPECTF-- -Parse error: %s on line 3 +Fatal error: Cannot create references to elements of a temporary array expression in %sforeachLoop.007.php on line %d From f53225a99ebae56c7a20d6e3ad4efe6772dda3f9 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 25 Aug 2012 17:40:08 +0200 Subject: [PATCH 2036/2394] Fix several issues and allow rewind only at/before first yield * Trying to resume a generator while it is already running now throws a fatal error. * Trying to use yield in finally while the generator is being force-closed (by GC) throws a fatal error. * Rewinding after the first yield now throws an Exception --- .../resume_running_generator_error.phpt | 17 +++ .../yield_in_force_closed_finally_error.phpt | 29 +++++ Zend/tests/generators/generator_rewind.phpt | 43 ++++++++ Zend/tests/generators/yield_in_finally.phpt | 29 +++++ Zend/zend_generators.c | 49 +++++++-- Zend/zend_generators.h | 11 +- Zend/zend_vm_def.h | 4 + Zend/zend_vm_execute.h | 100 ++++++++++++++++++ 8 files changed, 269 insertions(+), 13 deletions(-) create mode 100644 Zend/tests/generators/errors/resume_running_generator_error.phpt create mode 100644 Zend/tests/generators/errors/yield_in_force_closed_finally_error.phpt create mode 100644 Zend/tests/generators/generator_rewind.phpt create mode 100644 Zend/tests/generators/yield_in_finally.phpt diff --git a/Zend/tests/generators/errors/resume_running_generator_error.phpt b/Zend/tests/generators/errors/resume_running_generator_error.phpt new file mode 100644 index 0000000000000..567d72f3f9483 --- /dev/null +++ b/Zend/tests/generators/errors/resume_running_generator_error.phpt @@ -0,0 +1,17 @@ +--TEST-- +It is not possible to resume an already running generator +--FILE-- +next(); +} + +$gen = gen(); +$gen->send($gen); +$gen->next(); + +?> +--EXPECTF-- +Fatal error: Cannot resume an already running generator in %s on line %d diff --git a/Zend/tests/generators/errors/yield_in_force_closed_finally_error.phpt b/Zend/tests/generators/errors/yield_in_force_closed_finally_error.phpt new file mode 100644 index 0000000000000..aada676a68e8e --- /dev/null +++ b/Zend/tests/generators/errors/yield_in_force_closed_finally_error.phpt @@ -0,0 +1,29 @@ +--TEST-- +yield cannot be used in a finally block when the generator is force-closed +--FILE-- +rewind(); +unset($gen); + +?> +--EXPECTF-- +before yield +before yield in finally + +Fatal error: Cannot yield from finally in a force-closed generator in %s on line %d diff --git a/Zend/tests/generators/generator_rewind.phpt b/Zend/tests/generators/generator_rewind.phpt new file mode 100644 index 0000000000000..3224f6a9b6d82 --- /dev/null +++ b/Zend/tests/generators/generator_rewind.phpt @@ -0,0 +1,43 @@ +--TEST-- +A generator can only be rewinded before or at the first yield +--FILE-- +rewind(); +$gen->rewind(); +$gen->next(); + +try { + $gen->rewind(); +} catch (Exception $e) { + echo "\n", $e, "\n\n"; +} + +function gen2() { + echo "in generator\n"; + + if (false) yield; +} + +$gen = gen2(); +$gen->rewind(); + +?> +--EXPECTF-- +before yield +after yield + +exception 'Exception' with message 'Cannot rewind a generator that was already run' in %s:%d +Stack trace: +#0 %s(%d): Generator->rewind() +#1 {main} + +in generator diff --git a/Zend/tests/generators/yield_in_finally.phpt b/Zend/tests/generators/yield_in_finally.phpt new file mode 100644 index 0000000000000..805484ad1d150 --- /dev/null +++ b/Zend/tests/generators/yield_in_finally.phpt @@ -0,0 +1,29 @@ +--TEST-- +yield can be used in finally (apart from forced closes) +--FILE-- +current()); +$gen->next(); + +?> +--EXPECTF-- +before return +before yield +string(%d) "yielded value" +after yield diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 3170ec9c33d69..03294f7f0ea47 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -31,11 +31,13 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio { if (generator->execute_data) { zend_execute_data *execute_data = generator->execute_data; + zend_op_array *op_array = execute_data->op_array; if (!finished_execution) { - zend_op_array *op_array = execute_data->op_array; if (op_array->has_finally_block) { - zend_uint op_num = execute_data->opline - op_array->opcodes; + /* -1 required because we want the last run opcode, not the + * next to-be-run one. */ + zend_uint op_num = execute_data->opline - op_array->opcodes - 1; zend_uint finally_op_num = 0; /* Find next finally block */ @@ -59,6 +61,7 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio if (finally_op_num) { execute_data->opline = &op_array->opcodes[finally_op_num]; execute_data->leaving = ZEND_RETURN; + generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; zend_generator_resume(generator TSRMLS_CC); return; } @@ -66,7 +69,7 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio } if (!execute_data->symbol_table) { - zend_free_compiled_variables(execute_data->CVs, execute_data->op_array->last_var); + zend_free_compiled_variables(execute_data->CVs, op_array->last_var); } else { zend_clean_and_cache_symbol_table(execute_data->symbol_table TSRMLS_CC); } @@ -83,8 +86,9 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio * a return statement) we have to free loop variables manually, as * we don't know whether the SWITCH_FREE / FREE opcodes have run */ if (!finished_execution) { - zend_op_array *op_array = execute_data->op_array; - zend_uint op_num = execute_data->opline - op_array->opcodes; + /* -1 required because we want the last run opcode, not the + * next to-be-run one. */ + zend_uint op_num = execute_data->opline - op_array->opcodes - 1; int i; for (i = 0; i < op_array->last_brk_cont; ++i) { @@ -411,6 +415,13 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ return; } + if (generator->flags & ZEND_GENERATOR_CURRENTLY_RUNNING) { + zend_error(E_ERROR, "Cannot resume an already running generator"); + } + + /* Drop the AT_FIRST_YIELD flag */ + generator->flags &= ~ZEND_GENERATOR_AT_FIRST_YIELD; + { /* Backup executor globals */ zval **original_return_value_ptr_ptr = EG(return_value_ptr_ptr); @@ -455,7 +466,9 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ generator->execute_data->prev_execute_data->prev_execute_data = original_execute_data; /* Resume execution */ + generator->flags |= ZEND_GENERATOR_CURRENTLY_RUNNING; execute_ex(generator->execute_data TSRMLS_CC); + generator->flags &= ~ZEND_GENERATOR_CURRENTLY_RUNNING; /* Restore executor globals */ EG(return_value_ptr_ptr) = original_return_value_ptr_ptr; @@ -489,6 +502,17 @@ static void zend_generator_ensure_initialized(zend_generator *generator TSRMLS_D { if (!generator->value) { zend_generator_resume(generator TSRMLS_CC); + generator->flags |= ZEND_GENERATOR_AT_FIRST_YIELD; + } +} +/* }}} */ + +static void zend_generator_rewind(zend_generator *generator TSRMLS_DC) /* {{{ */ +{ + zend_generator_ensure_initialized(generator TSRMLS_CC); + + if (!(generator->flags & ZEND_GENERATOR_AT_FIRST_YIELD)) { + zend_throw_exception(NULL, "Cannot rewind a generator that was already run", 0 TSRMLS_CC); } } /* }}} */ @@ -505,10 +529,7 @@ ZEND_METHOD(Generator, rewind) generator = (zend_generator *) zend_object_store_get_object(getThis() TSRMLS_CC); - zend_generator_ensure_initialized(generator TSRMLS_CC); - - /* Generators aren't rewindable, so rewind() only has to make sure that - * the generator is initialized, nothing more */ + zend_generator_rewind(generator TSRMLS_CC); } /* }}} */ @@ -721,13 +742,21 @@ static void zend_generator_iterator_move_forward(zend_object_iterator *iterator } /* }}} */ +static void zend_generator_iterator_rewind(zend_object_iterator *iterator TSRMLS_DC) /* {{{ */ +{ + zend_generator *generator = (zend_generator *) iterator->data; + + zend_generator_rewind(generator TSRMLS_CC); +} +/* }}} */ + static zend_object_iterator_funcs zend_generator_iterator_functions = { zend_generator_iterator_dtor, zend_generator_iterator_valid, zend_generator_iterator_get_data, zend_generator_iterator_get_key, zend_generator_iterator_move_forward, - NULL + zend_generator_iterator_rewind }; zend_object_iterator *zend_generator_get_iterator(zend_class_entry *ce, zval *object, int by_ref TSRMLS_DC) /* {{{ */ diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index 37ffbbd6ccbb9..e47b7ad885f8e 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -22,6 +22,8 @@ #define ZEND_GENERATORS_H BEGIN_EXTERN_C() +extern ZEND_API zend_class_entry *zend_ce_generator; +END_EXTERN_C() typedef struct _zend_generator { zend_object std; @@ -46,17 +48,20 @@ typedef struct _zend_generator { temp_variable *send_target; /* Largest used integer key for auto-incrementing keys */ long largest_used_integer_key; + + /* ZEND_GENERATOR_* flags */ + zend_uchar flags; } zend_generator; -extern ZEND_API zend_class_entry *zend_ce_generator; +static const zend_uchar ZEND_GENERATOR_CURRENTLY_RUNNING = 0x1; +static const zend_uchar ZEND_GENERATOR_FORCED_CLOSE = 0x2; +static const zend_uchar ZEND_GENERATOR_AT_FIRST_YIELD = 0x4; void zend_register_generator_ce(TSRMLS_D); zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC); void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC); void zend_generator_resume(zend_generator *generator TSRMLS_DC); -END_EXTERN_C() - #endif /* diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 216cd59bdbc4e..19031bc18dd5b 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5402,6 +5402,10 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index ebc0fb9c49cc3..6a5e2fff1202e 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -4209,6 +4209,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -4899,6 +4903,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -5914,6 +5922,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -6624,6 +6636,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -7373,6 +7389,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -9436,6 +9456,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -10126,6 +10150,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -11141,6 +11169,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -11717,6 +11749,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -12404,6 +12440,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -16326,6 +16366,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -18405,6 +18449,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -20864,6 +20912,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -22001,6 +22053,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -24129,6 +24185,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -25616,6 +25676,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -26925,6 +26989,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -28234,6 +28302,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -28654,6 +28726,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -29960,6 +30036,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -33481,6 +33561,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -35429,6 +35513,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -37756,6 +37844,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -38752,6 +38844,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); @@ -40748,6 +40844,10 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + if (generator->flags & ZEND_GENERATOR_FORCED_CLOSE) { + zend_error_noreturn(E_ERROR, "Cannot yield from finally in a force-closed generator"); + } + /* Destroy the previously yielded value */ if (generator->value) { zval_ptr_dtor(&generator->value); From bd70d155885fdc087afba912c1b290615b864e2f Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 25 Aug 2012 19:03:23 +0200 Subject: [PATCH 2037/2394] Remove implementation stubs for yield delegation I decided to leave out yield delegation for an initial proposal, so remove the stubs for it too. --- Zend/zend_compile.c | 23 ------------------- Zend/zend_compile.h | 1 - Zend/zend_language_parser.y | 3 --- Zend/zend_vm_def.h | 7 +----- Zend/zend_vm_execute.h | 45 ------------------------------------- Zend/zend_vm_opcodes.h | 3 +-- 6 files changed, 2 insertions(+), 80 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 563069118e43f..d4201059b2e72 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2702,29 +2702,6 @@ void zend_do_yield(znode *result, znode *value, const znode *key, zend_bool is_v } /* }}} */ -void zend_do_delegate_yield(znode *result, const znode *value TSRMLS_DC) /* {{{ */ -{ - zend_op *opline; - - if (!CG(active_op_array)->function_name) { - zend_error(E_COMPILE_ERROR, "The \"yield*\" expression can only be used inside a function"); - } - - CG(active_op_array)->fn_flags |= ZEND_ACC_GENERATOR; - - opline = get_next_op(CG(active_op_array) TSRMLS_CC); - - opline->opcode = ZEND_DELEGATE_YIELD; - - SET_NODE(opline->op1, value); - SET_UNUSED(opline->op2); - - opline->result_type = IS_VAR; - opline->result.var = get_temporary_variable(CG(active_op_array)); - GET_NODE(result, opline->result); -} -/* }}} */ - static int zend_add_try_element(zend_uint try_op TSRMLS_DC) /* {{{ */ { int try_catch_offset = CG(active_op_array)->last_try_catch++; diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index acff761f88a01..42f3ed405d475 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -496,7 +496,6 @@ int zend_do_begin_class_member_function_call(znode *class_name, znode *method_na void zend_do_end_function_call(znode *function_name, znode *result, const znode *argument_list, int is_method, int is_dynamic_fcall TSRMLS_DC); void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC); void zend_do_yield(znode *result, znode *value, const znode *key, zend_bool is_variable TSRMLS_DC); -void zend_do_delegate_yield(znode *result, const znode *value TSRMLS_DC); void zend_do_handle_exception(TSRMLS_D); void zend_do_begin_lambda_function_declaration(znode *result, znode *function_token, int return_reference, int is_static TSRMLS_DC); diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 29012b769ba72..8b0f500895bca 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -807,9 +807,6 @@ expr_without_variable: | '`' backticks_expr '`' { zend_do_shell_exec(&$$, &$2 TSRMLS_CC); } | T_PRINT expr { zend_do_print(&$$, &$2 TSRMLS_CC); } | T_YIELD { zend_do_yield(&$$, NULL, NULL, 0 TSRMLS_CC); } - /*| T_YIELD expr_without_variable { zend_do_yield(&$$, &$2, NULL, 0 TSRMLS_CC); } - | T_YIELD variable { zend_do_yield(&$$, &$2, NULL, 1 TSRMLS_CC); }*/ - | T_YIELD '*' expr { zend_do_delegate_yield(&$$, &$3 TSRMLS_CC); } | function is_reference { zend_do_begin_lambda_function_declaration(&$$, &$1, $2.op_type, 0 TSRMLS_CC); } '(' parameter_list ')' lexical_vars '{' inner_statement_list '}' { zend_do_end_function_declaration(&$1 TSRMLS_CC); $$ = $3; } diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 19031bc18dd5b..101667957be9d 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -3055,7 +3055,7 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } -ZEND_VM_HANDLER(162, ZEND_GENERATOR_RETURN, ANY, ANY) +ZEND_VM_HANDLER(161, ZEND_GENERATOR_RETURN, ANY, ANY) { if (EX(op_array)->has_finally_block) { ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); @@ -5552,9 +5552,4 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE ZEND_VM_RETURN(); } -ZEND_VM_HANDLER(161, ZEND_DELEGATE_YIELD, CONST|TMP|VAR|CV, ANY) -{ - ZEND_VM_NEXT_OPCODE(); -} - ZEND_VM_EXPORT_HELPER(zend_do_fcall, zend_do_fcall_common_helper) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 6a5e2fff1202e..a6439674d5c2b 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -3177,11 +3177,6 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DELEGATE_YIELD_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -8556,11 +8551,6 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DELEGATE_YIELD_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -14014,11 +14004,6 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DELEGATE_YIELD_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31430,11 +31415,6 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -45025,31 +45005,6 @@ void zend_init_opcodes_handlers(void) ZEND_YIELD_SPEC_CV_VAR_HANDLER, ZEND_YIELD_SPEC_CV_UNUSED_HANDLER, ZEND_YIELD_SPEC_CV_CV_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CONST_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CONST_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CONST_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CONST_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CONST_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_TMP_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_TMP_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_TMP_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_TMP_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_TMP_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_VAR_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_VAR_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_VAR_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_VAR_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, - ZEND_DELEGATE_YIELD_SPEC_CV_HANDLER, ZEND_GENERATOR_RETURN_SPEC_HANDLER, ZEND_GENERATOR_RETURN_SPEC_HANDLER, ZEND_GENERATOR_RETURN_SPEC_HANDLER, diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 0b4903ac3651a..7f9434995483e 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -161,5 +161,4 @@ #define ZEND_JMP_SET_VAR 158 #define ZEND_LEAVE 159 #define ZEND_YIELD 160 -#define ZEND_DELEGATE_YIELD 161 -#define ZEND_GENERATOR_RETURN 162 +#define ZEND_GENERATOR_RETURN 161 From 7c60aeef857f288661a6f95cf3aa45d6a6feff9b Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 26 Aug 2012 11:37:05 +0800 Subject: [PATCH 2038/2394] Fixed bug #62931 & #62932 --- Zend/zend_compile.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index b87b1908b6bde..6efc1e17bb670 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6283,8 +6283,13 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token opline->extended_value |= ZEND_FE_FETCH_WITH_KEY; } - if ((key->op_type != IS_UNUSED) && (key->EA & ZEND_PARSED_REFERENCE_VARIABLE)) { + if ((key->op_type != IS_UNUSED)) { + if (key->EA & ZEND_PARSED_REFERENCE_VARIABLE) { zend_error(E_COMPILE_ERROR, "Key element cannot be a reference"); + } + if (key->EA & ZEND_PARSED_LIST_EXPR) { + zend_error(E_COMPILE_ERROR, "Cannot use list as Key element"); + } } if (value->EA & ZEND_PARSED_REFERENCE_VARIABLE) { From c6a5d192c8f23ce54c253decb8be727bddc4f3bf Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 26 Aug 2012 12:27:10 +0800 Subject: [PATCH 2039/2394] tabs --- Zend/zend_compile.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 6efc1e17bb670..d8257927fded8 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6284,12 +6284,12 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token } if ((key->op_type != IS_UNUSED)) { - if (key->EA & ZEND_PARSED_REFERENCE_VARIABLE) { - zend_error(E_COMPILE_ERROR, "Key element cannot be a reference"); - } - if (key->EA & ZEND_PARSED_LIST_EXPR) { - zend_error(E_COMPILE_ERROR, "Cannot use list as Key element"); - } + if (key->EA & ZEND_PARSED_REFERENCE_VARIABLE) { + zend_error(E_COMPILE_ERROR, "Key element cannot be a reference"); + } + if (key->EA & ZEND_PARSED_LIST_EXPR) { + zend_error(E_COMPILE_ERROR, "Cannot use list as Key element"); + } } if (value->EA & ZEND_PARSED_REFERENCE_VARIABLE) { From 5ebbdecfeaaea1bc78450a2bb6d5ee280bf18dbd Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 26 Aug 2012 13:05:33 +0800 Subject: [PATCH 2040/2394] Fixed bug #62930, and more tests --- ...oreach_list.phpt => foreach_list_001.phpt} | 0 Zend/tests/foreach_list_002.phpt | 26 +++++++++++++++++++ Zend/tests/foreach_list_003.phpt | 13 ++++++++++ Zend/tests/foreach_list_004.phpt | 13 ++++++++++ Zend/zend_compile.c | 5 +++- 5 files changed, 56 insertions(+), 1 deletion(-) rename Zend/tests/{foreach_list.phpt => foreach_list_001.phpt} (100%) create mode 100644 Zend/tests/foreach_list_002.phpt create mode 100644 Zend/tests/foreach_list_003.phpt create mode 100644 Zend/tests/foreach_list_004.phpt diff --git a/Zend/tests/foreach_list.phpt b/Zend/tests/foreach_list_001.phpt similarity index 100% rename from Zend/tests/foreach_list.phpt rename to Zend/tests/foreach_list_001.phpt diff --git a/Zend/tests/foreach_list_002.phpt b/Zend/tests/foreach_list_002.phpt new file mode 100644 index 0000000000000..251870ba099ea --- /dev/null +++ b/Zend/tests/foreach_list_002.phpt @@ -0,0 +1,26 @@ +--TEST-- +foreach with freak lists +--FILE-- + +--EXPECTF-- +int(1) +int(3) +string(1) "b" + +Notice: Uninitialized string offset: 1 in %sforeach_list_002.php on line %d +string(0) "" + +Notice: Uninitialized string offset: 1 in %sforeach_list_002.php on line %d +string(0) "" diff --git a/Zend/tests/foreach_list_003.phpt b/Zend/tests/foreach_list_003.phpt new file mode 100644 index 0000000000000..8674ecd754ffb --- /dev/null +++ b/Zend/tests/foreach_list_003.phpt @@ -0,0 +1,13 @@ +--TEST-- +foreach with list key +--FILE-- + list(list(), $a)) { +} + +?> +--EXPECTF-- +Fatal error: Cannot use list as key element in %sforeach_list_003.php on line %d diff --git a/Zend/tests/foreach_list_004.phpt b/Zend/tests/foreach_list_004.phpt new file mode 100644 index 0000000000000..fd48e8a1f34ba --- /dev/null +++ b/Zend/tests/foreach_list_004.phpt @@ -0,0 +1,13 @@ +--TEST-- +foreach with empty list +--FILE-- + list()) { +} + +?> +--EXPECTF-- +Fatal error: Cannot use empty list in %sforeach_list_004.php on line %d diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index d8257927fded8..704db107cac4a 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -6288,7 +6288,7 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token zend_error(E_COMPILE_ERROR, "Key element cannot be a reference"); } if (key->EA & ZEND_PARSED_LIST_EXPR) { - zend_error(E_COMPILE_ERROR, "Cannot use list as Key element"); + zend_error(E_COMPILE_ERROR, "Cannot use list as key element"); } } @@ -6326,6 +6326,9 @@ void zend_do_foreach_cont(znode *foreach_token, const znode *open_brackets_token GET_NODE(&value_node, opline->result); if (value->EA & ZEND_PARSED_LIST_EXPR) { + if (!CG(list_llist).head) { + zend_error(E_COMPILE_ERROR, "Cannot use empty list"); + } zend_do_list_end(&dummy, &value_node TSRMLS_CC); zend_do_free(&dummy TSRMLS_CC); } else { From 101fd2d3fde0d963f9658b2fc11ac0e7e27258d9 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 26 Aug 2012 09:03:45 -0400 Subject: [PATCH 2041/2394] Fix bad version for CURLINFO_CERTINFO CURLINFO_CERTINFO is available since 7.19.1. The cURL extension allow to use it since this same version but the internal function create_certinfo used internally for CURLINFO_CERTINFO usage is only usable for version greater than 7.19.1 which will cause problem if the user is using the 7.19.1 cURL version --- ext/curl/interface.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 899ea603c13ba..7f865fe95868b 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -786,6 +786,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLPROXY_SOCKS5); /* Curl Share constants */ + REGISTER_CURL_CONSTANT(CURLSHOPT_NONE); REGISTER_CURL_CONSTANT(CURLSHOPT_SHARE); REGISTER_CURL_CONSTANT(CURLSHOPT_UNSHARE); @@ -814,6 +815,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURL_TIMECOND_IFMODSINCE); REGISTER_CURL_CONSTANT(CURL_TIMECOND_IFUNMODSINCE); REGISTER_CURL_CONSTANT(CURL_TIMECOND_LASTMOD); + REGISTER_CURL_CONSTANT(CURL_TIMECOND_NONE); /* Curl version constants */ REGISTER_CURL_CONSTANT(CURL_VERSION_IPV6); @@ -1743,7 +1745,7 @@ static void alloc_curl_handle(php_curl **ch) } /* }}} */ -#if LIBCURL_VERSION_NUM > 0x071301 +#if LIBCURL_VERSION_NUM >= 0x071301 /* Available since 7.19.1 */ /* {{{ split_certinfo */ static void split_certinfo(char *string, zval *hash) From e7a714b35ecaf5760b1af7bd97eb2f0c613aa9f3 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 26 Aug 2012 17:02:39 +0200 Subject: [PATCH 2042/2394] Merging PR 121 to add support for slow request counting on the PHP-FPM status page --- sapi/fpm/fpm/fpm_php_trace.c | 2 ++ sapi/fpm/fpm/fpm_process_ctl.c | 8 ++++---- sapi/fpm/fpm/fpm_request.c | 4 ++-- sapi/fpm/fpm/fpm_scoreboard.c | 5 ++++- sapi/fpm/fpm/fpm_scoreboard.h | 3 ++- sapi/fpm/fpm/fpm_sockets.c | 2 +- sapi/fpm/fpm/fpm_status.c | 13 +++++++++---- 7 files changed, 24 insertions(+), 13 deletions(-) diff --git a/sapi/fpm/fpm/fpm_php_trace.c b/sapi/fpm/fpm/fpm_php_trace.c index cd97aebb3347a..d95d66a754c3e 100644 --- a/sapi/fpm/fpm/fpm_php_trace.c +++ b/sapi/fpm/fpm/fpm_php_trace.c @@ -26,6 +26,7 @@ #include "fpm_children.h" #include "fpm_worker_pool.h" #include "fpm_process_ctl.h" +#include "fpm_scoreboard.h" #include "zlog.h" @@ -137,6 +138,7 @@ static int fpm_php_trace_dump(struct fpm_child_s *child, FILE *slowlog TSRMLS_DC void fpm_php_trace(struct fpm_child_s *child) /* {{{ */ { TSRMLS_FETCH(); + fpm_scoreboard_update(0, 0, 0, 0, 0, 0, 1, FPM_SCOREBOARD_ACTION_SET, child->wp->scoreboard); FILE *slowlog; zlog(ZLOG_NOTICE, "about to trace %d", (int) child->pid); diff --git a/sapi/fpm/fpm/fpm_process_ctl.c b/sapi/fpm/fpm/fpm_process_ctl.c index 7840d17f8b9c5..76ea4d358e67d 100644 --- a/sapi/fpm/fpm/fpm_process_ctl.c +++ b/sapi/fpm/fpm/fpm_process_ctl.c @@ -353,7 +353,7 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ #endif } } - fpm_scoreboard_update(idle, active, cur_lq, -1, -1, -1, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); + fpm_scoreboard_update(idle, active, cur_lq, -1, -1, -1, 0, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); /* this is specific to PM_STYLE_ONDEMAND */ if (wp->config->pm == PM_STYLE_ONDEMAND) { @@ -388,7 +388,7 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ if (idle < wp->config->pm_min_spare_servers) { if (wp->running_children >= wp->config->pm_max_children) { if (!wp->warn_max_children) { - fpm_scoreboard_update(0, 0, 0, 0, 0, 1, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); + fpm_scoreboard_update(0, 0, 0, 0, 0, 1, 0, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); zlog(ZLOG_WARNING, "[pool %s] server reached pm.max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); wp->warn_max_children = 1; } @@ -407,7 +407,7 @@ static void fpm_pctl_perform_idle_server_maintenance(struct timeval *now) /* {{{ children_to_fork = MIN(children_to_fork, wp->config->pm_max_children - wp->running_children); if (children_to_fork <= 0) { if (!wp->warn_max_children) { - fpm_scoreboard_update(0, 0, 0, 0, 0, 1, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); + fpm_scoreboard_update(0, 0, 0, 0, 0, 1, 0, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); zlog(ZLOG_WARNING, "[pool %s] server reached pm.max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); wp->warn_max_children = 1; } @@ -511,7 +511,7 @@ void fpm_pctl_on_socket_accept(struct fpm_event_s *ev, short which, void *arg) / if (wp->running_children >= wp->config->pm_max_children) { if (!wp->warn_max_children) { - fpm_scoreboard_update(0, 0, 0, 0, 0, 1, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); + fpm_scoreboard_update(0, 0, 0, 0, 0, 1, 0, FPM_SCOREBOARD_ACTION_INC, wp->scoreboard); zlog(ZLOG_WARNING, "[pool %s] server reached max_children setting (%d), consider raising it", wp->config->name, wp->config->pm_max_children); wp->warn_max_children = 1; } diff --git a/sapi/fpm/fpm/fpm_request.c b/sapi/fpm/fpm/fpm_request.c index 28332d0a92621..bf431a08d0366 100644 --- a/sapi/fpm/fpm/fpm_request.c +++ b/sapi/fpm/fpm/fpm_request.c @@ -54,7 +54,7 @@ void fpm_request_accepting() /* {{{ */ fpm_scoreboard_proc_release(proc); /* idle++, active-- */ - fpm_scoreboard_update(1, -1, 0, 0, 0, 0, FPM_SCOREBOARD_ACTION_INC, NULL); + fpm_scoreboard_update(1, -1, 0, 0, 0, 0, 0, FPM_SCOREBOARD_ACTION_INC, NULL); } /* }}} */ @@ -98,7 +98,7 @@ void fpm_request_reading_headers() /* {{{ */ fpm_scoreboard_proc_release(proc); /* idle--, active++, request++ */ - fpm_scoreboard_update(-1, 1, 0, 0, 1, 0, FPM_SCOREBOARD_ACTION_INC, NULL); + fpm_scoreboard_update(-1, 1, 0, 0, 1, 0, 0, FPM_SCOREBOARD_ACTION_INC, NULL); } /* }}} */ diff --git a/sapi/fpm/fpm/fpm_scoreboard.c b/sapi/fpm/fpm/fpm_scoreboard.c index 4222f6037c765..24463a90dddfd 100644 --- a/sapi/fpm/fpm/fpm_scoreboard.c +++ b/sapi/fpm/fpm/fpm_scoreboard.c @@ -73,7 +73,7 @@ int fpm_scoreboard_init_main() /* {{{ */ } /* }}} */ -void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int requests, int max_children_reached, int action, struct fpm_scoreboard_s *scoreboard) /* {{{ */ +void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int requests, int max_children_reached, int slow_rq, int action, struct fpm_scoreboard_s *scoreboard) /* {{{ */ { if (!scoreboard) { scoreboard = fpm_scoreboard; @@ -110,6 +110,9 @@ void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int request if (max_children_reached >= 0) { scoreboard->max_children_reached = max_children_reached; } + if (slow_rq > 0) { + scoreboard->slow_rq += slow_rq; + } } else { if (scoreboard->idle + idle > 0) { scoreboard->idle += idle; diff --git a/sapi/fpm/fpm/fpm_scoreboard.h b/sapi/fpm/fpm/fpm_scoreboard.h index 136ea481a4a5e..f58a28737dff9 100644 --- a/sapi/fpm/fpm/fpm_scoreboard.h +++ b/sapi/fpm/fpm/fpm_scoreboard.h @@ -64,13 +64,14 @@ struct fpm_scoreboard_s { unsigned int lq_len; unsigned int nprocs; int free_proc; + unsigned long int slow_rq; struct fpm_scoreboard_proc_s *procs[]; }; int fpm_scoreboard_init_main(); int fpm_scoreboard_init_child(struct fpm_worker_pool_s *wp); -void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int requests, int max_children_reached, int action, struct fpm_scoreboard_s *scoreboard); +void fpm_scoreboard_update(int idle, int active, int lq, int lq_len, int requests, int max_children_reached, int slow_rq, int action, struct fpm_scoreboard_s *scoreboard); struct fpm_scoreboard_s *fpm_scoreboard_get(); struct fpm_scoreboard_proc_s *fpm_scoreboard_proc_get(struct fpm_scoreboard_s *scoreboard, int child_index); diff --git a/sapi/fpm/fpm/fpm_sockets.c b/sapi/fpm/fpm/fpm_sockets.c index f56b9cfbd1493..76759e7f25bf6 100644 --- a/sapi/fpm/fpm/fpm_sockets.c +++ b/sapi/fpm/fpm/fpm_sockets.c @@ -356,7 +356,7 @@ int fpm_sockets_init_main() /* {{{ */ } if (wp->listen_address_domain == FPM_AF_INET && fpm_socket_get_listening_queue(wp->listening_socket, NULL, &lq_len) >= 0) { - fpm_scoreboard_update(-1, -1, -1, (int)lq_len, -1, -1, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); + fpm_scoreboard_update(-1, -1, -1, (int)lq_len, -1, -1, 0, FPM_SCOREBOARD_ACTION_SET, wp->scoreboard); } } diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index 5f2c852c7d787..b9b9a8c0b6f1b 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -158,6 +158,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "total processes%d\n" "max active processes%d\n" "max children reached%u\n" + "slow requests%lu\n" "\n"; if (!full) { @@ -228,7 +229,8 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "%d\n" "%d\n" "%d\n" - "%u\n"; + "%u\n" + "%lu\n"; if (!full) { short_post = ""; @@ -277,7 +279,8 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "\"active processes\":%d," "\"total processes\":%d," "\"max active processes\":%d," - "\"max children reached\":%u"; + "\"max children reached\":%u," + "\"slow requests\":%lu"; if (!full) { short_post = "}"; @@ -326,7 +329,8 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "active processes: %d\n" "total processes: %d\n" "max active processes: %d\n" - "max children reached: %u\n"; + "max children reached: %u\n" + "slow requests: %lu\n"; if (full) { full_syntax = @@ -367,7 +371,8 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ scoreboard.active, scoreboard.idle + scoreboard.active, scoreboard.active_max, - scoreboard.max_children_reached); + scoreboard.max_children_reached, + scoreboard.slow_rq); PUTS(buffer); efree(buffer); From e3ef84c59bf669a7dfc717af26ed1872bab397c9 Mon Sep 17 00:00:00 2001 From: Stuart Langley Date: Tue, 7 Aug 2012 13:06:13 +1000 Subject: [PATCH 2043/2394] Strong types for the result codes SUCCESS & FAILURE. These are common symbol names and using #defines can cause conflicts. --- Zend/zend.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Zend/zend.h b/Zend/zend.h index de2a2e595e89b..2c86f05cfa827 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -276,10 +276,10 @@ static const char long_min_digits[] = "9223372036854775808"; #define MAX_LENGTH_OF_DOUBLE 32 -#undef SUCCESS -#undef FAILURE -#define SUCCESS 0 -#define FAILURE -1 /* this MUST stay a negative number, or it may affect functions! */ +typedef enum { + SUCCESS = 0, + FAILURE = -1, /* this MUST stay a negative number, or it may affect functions! */ +} RESULT_CODE; #include "zend_hash.h" #include "zend_ts_hash.h" From 48f40969179d3db8dade1e64a273a26b8aa2e2a1 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 26 Aug 2012 17:46:01 +0200 Subject: [PATCH 2044/2394] Travis: Silence configure and make The large compile logs are hurting the poor browsers. This also drops two bogus configure options. --- travis/compile.sh | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/travis/compile.sh b/travis/compile.sh index a0fc167a15bf7..b48bfe8e24eea 100755 --- a/travis/compile.sh +++ b/travis/compile.sh @@ -1,6 +1,6 @@ #!/bin/bash ./buildconf -./configure \ +./configure --quiet \ --with-pdo-mysql \ --with-mysql \ --with-mysqli \ @@ -33,7 +33,5 @@ --with-gettext \ --enable-sockets \ --with-bz2 \ ---enable-bcmath \ ---enable-fastcgi \ ---with-mime-magic -make \ No newline at end of file +--enable-bcmath +make --quiet From 8831b000cab7103e25fc2acf224d0009ef0646d4 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sat, 25 Aug 2012 19:00:34 +0200 Subject: [PATCH 2045/2394] Require ICU >= 4.0 in configure --- acinclude.m4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index adb9599ce4887..98e98f2af37a9 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2235,8 +2235,8 @@ AC_DEFUN([PHP_SETUP_ICU],[ icu_version=`expr [$]1 \* 1000 + [$]2` AC_MSG_RESULT([found $icu_version_full]) - if test "$icu_version" -lt "3004"; then - AC_MSG_ERROR([ICU version 3.4 or later is required]) + if test "$icu_version" -lt "4000"; then + AC_MSG_ERROR([ICU version 4.0 or later is required]) fi ICU_VERSION=$icu_version From 3d0857938d86b279e932de0558c3f4877e49bcec Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 26 Aug 2012 19:44:05 +0200 Subject: [PATCH 2046/2394] zend_binary_strncasecmp_l used w/out declaration --- Zend/zend_operators.h | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index d28140e9e5bb9..08a6b19bd44b9 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -340,6 +340,7 @@ ZEND_API int zend_binary_strcmp(const char *s1, uint len1, const char *s2, uint ZEND_API int zend_binary_strncmp(const char *s1, uint len1, const char *s2, uint len2, uint length); ZEND_API int zend_binary_strcasecmp(const char *s1, uint len1, const char *s2, uint len2); ZEND_API int zend_binary_strncasecmp(const char *s1, uint len1, const char *s2, uint len2, uint length); +ZEND_API int zend_binary_strncasecmp_l(const char *s1, uint len1, const char *s2, uint len2, uint length); ZEND_API void zendi_smart_strcmp(zval *result, zval *s1, zval *s2); ZEND_API void zend_compare_symbol_tables(zval *result, HashTable *ht1, HashTable *ht2 TSRMLS_DC); From 8788cddfb36480cd4f0cb5c3aeec69134764ecfc Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 26 Aug 2012 20:06:47 +0200 Subject: [PATCH 2047/2394] Prefix RESULT_CODE enum with ZEND_ --- Zend/zend.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend.h b/Zend/zend.h index 2c86f05cfa827..d2a4ef6957868 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -279,7 +279,7 @@ static const char long_min_digits[] = "9223372036854775808"; typedef enum { SUCCESS = 0, FAILURE = -1, /* this MUST stay a negative number, or it may affect functions! */ -} RESULT_CODE; +} ZEND_RESULT_CODE; #include "zend_hash.h" #include "zend_ts_hash.h" From e95ad46186068cfe95cf54bc2f0085f393b62e58 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 26 Aug 2012 20:42:18 +0200 Subject: [PATCH 2048/2394] Relax 4 dateformat tests for ICU 4.8 --- ext/intl/tests/dateformat_create_cal_arg.phpt | 16 ++++++++-------- .../tests/dateformat_formatObject_calendar.phpt | 8 ++++---- .../tests/dateformat_formatObject_datetime.phpt | 6 +++--- ext/intl/tests/dateformat_get_set_timezone.phpt | 10 +++++----- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/ext/intl/tests/dateformat_create_cal_arg.phpt b/ext/intl/tests/dateformat_create_cal_arg.phpt index 7490ecef492c0..53fb084af95e6 100644 --- a/ext/intl/tests/dateformat_create_cal_arg.phpt +++ b/ext/intl/tests/dateformat_create_cal_arg.phpt @@ -42,12 +42,12 @@ echo $df->format($ts), "\n"; ?> ==DONE== ---EXPECT-- -domingo, 1 de enero de 2012 00:00:00 GMT -domingo, 8 de Safar de 1433 00:00:00 GMT -domingo, 1 de enero de 2012 01:00:00 Hora estándar de Europa Central -sábado, 31 de diciembre de 2011 d.C. 23:00:00 Hora estándar de las Azores -sábado, 7 de Safar de 1433 AH 23:00:00 Hora estándar de las Azores -domingo, 8 de Safar de 1433 AH 00:00:00 GMT -domingo, 1 de enero de 2012 00:00:00 GMT +--EXPECTF-- +domingo%S 1 de enero de 2012 00:00:00 GMT +domingo%S 8 de Safar de 1433 00:00:00 GMT +domingo%S 1 de enero de 2012 01:00:00 Hora estándar de Europa Central +sábado%S 31 de diciembre de 2011 d.C. 23:00:00 Hora %Sde las Azores +sábado%S 7 de Safar de 1433 AH 23:00:00 Hora %Sde las Azores +domingo%S 8 de Safar de 1433 AH 00:00:00 GMT +domingo%S 1 de enero de 2012 00:00:00 GMT ==DONE== diff --git a/ext/intl/tests/dateformat_formatObject_calendar.phpt b/ext/intl/tests/dateformat_formatObject_calendar.phpt index 03371a91ab68f..0c61e4f2d0059 100644 --- a/ext/intl/tests/dateformat_formatObject_calendar.phpt +++ b/ext/intl/tests/dateformat_formatObject_calendar.phpt @@ -28,14 +28,14 @@ echo IntlDateFormatter::formatObject($cal, IntlDateFormatter::FULL, "en-US"), "\ ?> ==DONE== ---EXPECT-- +--EXPECTF-- 01/01/2012 00:00:00 -Domingo, 1 de Janeiro de 2012 0:00:00 Hora Padrão da Europa Ocidental +Domingo, 1 de Janeiro de 2012 0:00:00 Hora %Sda Europa Ocidental Jan 1, 2012 12:00:00 AM -1/1/12 12:00:00 AM Western European Standard Time +1/1/12 12:00:00 AM Western European %STime Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon) Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00 06/02/1433 00:00:00 -Sunday, Safar 6, 1433 12:00:00 AM Western European Standard Time +Sunday, Safar 6, 1433 12:00:00 AM Western European %STime ==DONE== diff --git a/ext/intl/tests/dateformat_formatObject_datetime.phpt b/ext/intl/tests/dateformat_formatObject_datetime.phpt index bfc26cb80c9ab..6427ad5a988c6 100644 --- a/ext/intl/tests/dateformat_formatObject_datetime.phpt +++ b/ext/intl/tests/dateformat_formatObject_datetime.phpt @@ -23,11 +23,11 @@ echo IntlDateFormatter::formatObject($dt, IntlDateFormatter::FULL), "\n"; ?> ==DONE== ---EXPECT-- +--EXPECTF-- 01/01/2012 00:00:00 -Domingo, 1 de Janeiro de 2012 0:00:00 Hora Padrão da Europa Ocidental +Domingo, 1 de Janeiro de 2012 0:00:00 Hora %Sda Europa Ocidental Jan 1, 2012 12:00:00 AM -1/1/12 12:00:00 AM Western European Standard Time +1/1/12 12:00:00 AM Western European %STime Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon) Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00 ==DONE== diff --git a/ext/intl/tests/dateformat_get_set_timezone.phpt b/ext/intl/tests/dateformat_get_set_timezone.phpt index b66653d8d04f9..41aa35b9cf3c6 100644 --- a/ext/intl/tests/dateformat_get_set_timezone.phpt +++ b/ext/intl/tests/dateformat_get_set_timezone.phpt @@ -38,24 +38,24 @@ d($df); ?> ==DONE== ---EXPECT-- +--EXPECTF-- Domingo, 1 de Janeiro de 2012 3:00:00 GMT+03:00 string(12) "Europe/Minsk" string(12) "Europe/Minsk" -Sábado, 31 de Dezembro de 2011 23:00:00 Hora Padrão dos Açores +Sábado, 31 de Dezembro de 2011 23:00:00 Hor%s %Sdos Açores string(15) "Atlantic/Azores" string(15) "Atlantic/Azores" -Domingo, 1 de Janeiro de 2012 1:00:00 Hora Padrão da Europa Central +Domingo, 1 de Janeiro de 2012 1:00:00 Hor%s %Sda Europa Central string(13) "Europe/Madrid" string(13) "Europe/Madrid" -Domingo, 1 de Janeiro de 2012 1:00:00 Hora Padrão da Europa Central +Domingo, 1 de Janeiro de 2012 1:00:00 Hor%s %Sda Europa Central string(12) "Europe/Paris" string(12) "Europe/Paris" -Domingo, 1 de Janeiro de 2012 1:00:00 Hora Padrão da Europa Central +Domingo, 1 de Janeiro de 2012 1:00:00 Hor%s %Sda Europa Central string(16) "Europe/Amsterdam" string(16) "Europe/Amsterdam" From 011af74b23fd419b34d4aee85cac39ffdd217665 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 26 Aug 2012 23:12:41 +0200 Subject: [PATCH 2049/2394] Fix version in check message --- acinclude.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/acinclude.m4 b/acinclude.m4 index 98e98f2af37a9..ad4f7474b385a 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2226,7 +2226,7 @@ AC_DEFUN([PHP_SETUP_ICU],[ AC_MSG_RESULT([$icu_install_prefix]) dnl Check ICU version - AC_MSG_CHECKING([for ICU 3.4 or greater]) + AC_MSG_CHECKING([for ICU 4.0 or greater]) icu_version_full=`$ICU_CONFIG --version` ac_IFS=$IFS IFS="." From dacd11ea8989a442032b9fdbece581cf9d299904 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 26 Aug 2012 23:44:54 +0200 Subject: [PATCH 2050/2394] Fixed cloning in ext/intl classes; master specific --- ext/intl/tests/bug62915.phpt | 24 ++++++++++++++++++++++++ ext/intl/timezone/timezone_class.cpp | 2 +- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 ext/intl/tests/bug62915.phpt diff --git a/ext/intl/tests/bug62915.phpt b/ext/intl/tests/bug62915.phpt new file mode 100644 index 0000000000000..e541d72d637ee --- /dev/null +++ b/ext/intl/tests/bug62915.phpt @@ -0,0 +1,24 @@ +--TEST-- +Bug #62915: incomplete cloning of IntlTimeZone objects +--SKIPIF-- +getMessage()); +} +--EXPECT-- +string(39) "Cannot clone unconstructed IntlTimeZone" diff --git a/ext/intl/timezone/timezone_class.cpp b/ext/intl/timezone/timezone_class.cpp index 27cf41a4cf4e9..374b1638512d3 100644 --- a/ext/intl/timezone/timezone_class.cpp +++ b/ext/intl/timezone/timezone_class.cpp @@ -225,7 +225,7 @@ static zend_object_value TimeZone_clone_obj(zval *object TSRMLS_DC) to_orig = (TimeZone_object*)zend_object_store_get_object(object TSRMLS_CC); intl_error_reset(TIMEZONE_ERROR_P(to_orig) TSRMLS_CC); - ret_val = TimeZone_ce_ptr->create_object(TimeZone_ce_ptr TSRMLS_CC); + ret_val = TimeZone_ce_ptr->create_object(Z_OBJCE_P(object) TSRMLS_CC); to_new = (TimeZone_object*)zend_object_store_get_object_by_handle( ret_val.handle TSRMLS_CC); From cec1786911eea3d515c044a407e22e9b162d7080 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 27 Aug 2012 10:23:23 +0800 Subject: [PATCH 2051/2394] Fixed bug #62938 (zend_do_bind_catch() used without declaration) --- Zend/zend_compile.h | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 15c2ab7bc7998..3a6f94270ba7b 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -501,6 +501,7 @@ void zend_do_fetch_lexical_variable(znode *varname, zend_bool is_ref TSRMLS_DC); void zend_do_try(znode *try_token TSRMLS_DC); void zend_do_begin_catch(znode *try_token, znode *catch_class, znode *catch_var, znode *first_catch TSRMLS_DC); +void zend_do_bind_catch(znode *try_token, znode *catch_token TSRMLS_DC); void zend_do_end_catch(znode *catch_token TSRMLS_DC); void zend_do_finally(znode *finally_token TSRMLS_DC); void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_token TSRMLS_DC); From dd9478e6c871418a7e130e5f6cacc7eaa8d92cf4 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Mon, 27 Aug 2012 08:56:54 -0300 Subject: [PATCH 2052/2394] - Fixed compiler warnings --- ext/curl/interface.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 7f865fe95868b..523bc1c6a0df7 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -2691,7 +2691,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_SHARE: { php_curlsh *sh = NULL; - ZEND_FETCH_RESOURCE(sh, php_curlsh *, zvalue, -1, le_curl_share_handle_name, le_curl_share_handle); + ZEND_FETCH_RESOURCE_NO_RETURN(sh, php_curlsh *, zvalue, -1, le_curl_share_handle_name, le_curl_share_handle); if (sh) { curl_easy_setopt(ch->cp, CURLOPT_SHARE, sh->share); } @@ -3215,7 +3215,7 @@ static void _php_curl_close(zend_rsrc_list_entry *rsrc TSRMLS_DC) #if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ /* {{{ _php_curl_reset_handlers() Reset all handlers of a given php_curl */ -static _php_curl_reset_handlers(php_curl *ch) +static void _php_curl_reset_handlers(php_curl *ch) { if (ch->handlers->write->stream) { Z_DELREF_P(ch->handlers->write->stream); @@ -3306,7 +3306,7 @@ PHP_FUNCTION(curl_escape) ZEND_FETCH_RESOURCE(ch, php_curl *, &zid, -1, le_curl_name, le_curl); - if (res = curl_easy_escape(ch->cp, str, str_len)) { + if ((res = curl_easy_escape(ch->cp, str, str_len))) { RETVAL_STRING(res, 1); free(res); } else { @@ -3330,7 +3330,7 @@ PHP_FUNCTION(curl_unescape) ZEND_FETCH_RESOURCE(ch, php_curl *, &zid, -1, le_curl_name, le_curl); - if (out = curl_easy_unescape(ch->cp, str, str_len, &out_len)) { + if ((out = curl_easy_unescape(ch->cp, str, str_len, &out_len))) { RETVAL_STRINGL(out, out_len, 1); free(out); } else { From 6b1073a3a7030d70a684638f098dbf22affb5c63 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Tue, 28 Aug 2012 14:06:18 +0200 Subject: [PATCH 2053/2394] Bug #62956: fixing private method signature validation In inheritance, if both methods are private, don not enforce the same signature. --- Zend/tests/bug61761.phpt | 3 ++- Zend/tests/bug62956.phpt | 20 ++++++++++++++++++++ Zend/zend_compile.c | 5 +++++ 3 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 Zend/tests/bug62956.phpt diff --git a/Zend/tests/bug61761.phpt b/Zend/tests/bug61761.phpt index 631f566eaa35a..24c69ae792e30 100755 --- a/Zend/tests/bug61761.phpt +++ b/Zend/tests/bug61761.phpt @@ -14,5 +14,6 @@ class B extends A } ?> +==DONE== --EXPECTF-- -Strict Standards: Declaration of B::test() should be compatible with A::test($a) in %sbug61761.php on line %d +==DONE== diff --git a/Zend/tests/bug62956.phpt b/Zend/tests/bug62956.phpt new file mode 100644 index 0000000000000..c8694d5beaa5d --- /dev/null +++ b/Zend/tests/bug62956.phpt @@ -0,0 +1,20 @@ +--TEST-- +Bug #62956: "incompatible" signatures for private methods should not cause E_STRICT +--FILE-- + +==DONE== +--EXPECT-- +==DONE== diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 704db107cac4a..f7b638f90cff3 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2969,6 +2969,11 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c return 1; } + /* If both methods are private do not enforce a signature */ + if ((fe->common.fn_flags & ZEND_ACC_PRIVATE) && (proto->common.fn_flags & ZEND_ACC_PRIVATE)) { + return 1; + } + /* check number of arguments */ if (proto->common.required_num_args < fe->common.required_num_args || proto->common.num_args > fe->common.num_args) { From e05413ca594ff10fd93d40429cb598c2e109edf4 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Tue, 28 Aug 2012 11:24:33 -0400 Subject: [PATCH 2054/2394] Remove password_make_salt() from the implementation --- ext/standard/basic_functions.c | 6 --- ext/standard/password.c | 34 ---------------- ext/standard/php_password.h | 1 - .../tests/password/password_make_salt.phpt | 40 ------------------- .../password/password_make_salt_error.phpt | 37 ----------------- 5 files changed, 118 deletions(-) delete mode 100644 ext/standard/tests/password/password_make_salt.phpt delete mode 100644 ext/standard/tests/password/password_make_salt_error.phpt diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index e6b155979fbcb..1f1b3d366db95 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -1884,10 +1884,6 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_password_verify, 0, 0, 2) ZEND_ARG_INFO(0, password) ZEND_ARG_INFO(0, hash) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_password_make_salt, 0, 0, 1) - ZEND_ARG_INFO(0, length) - ZEND_ARG_INFO(0, raw_output) -ZEND_END_ARG_INFO() /* }}} */ /* {{{ proc_open.c */ #ifdef PHP_CAN_SUPPORT_PROC_OPEN @@ -2907,8 +2903,6 @@ const zend_function_entry basic_functions[] = { /* {{{ */ PHP_FE(password_get_info, arginfo_password_get_info) PHP_FE(password_needs_rehash, arginfo_password_needs_rehash) PHP_FE(password_verify, arginfo_password_verify) - PHP_FE(password_make_salt, arginfo_password_make_salt) - PHP_FE(convert_uuencode, arginfo_convert_uuencode) PHP_FE(convert_uudecode, arginfo_convert_uudecode) diff --git a/ext/standard/password.c b/ext/standard/password.c index 2e5d62acecaea..4f8ef5dcab7ca 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -40,9 +40,6 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ REGISTER_LONG_CONSTANT("PASSWORD_DEFAULT", PHP_PASSWORD_DEFAULT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT", PHP_PASSWORD_BCRYPT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("PASSWORD_SALT_RAW", PHP_PASSWORD_SALT_RAW, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("PASSWORD_SALT_BCRYPT", PHP_PASSWORD_SALT_BCRYPT, CONST_CS | CONST_PERSISTENT); - return SUCCESS; } /* }}} */ @@ -95,8 +92,6 @@ static int php_password_salt_to64(const char *str, const int str_len, const int } /* }}} */ -#define PHP_PASSWORD_FUNCTION_EXISTS(func, func_len) (zend_hash_find(EG(function_table), (func), (func_len) + 1, (void **) &func_ptr) == SUCCESS && func_ptr->type == ZEND_INTERNAL_FUNCTION && func_ptr->internal_function.handler != zif_display_disabled_function) - static int php_password_make_salt(long length, int salt_type, char *ret TSRMLS_DC) /* {{{ */ { int buffer_valid = 0; @@ -277,35 +272,6 @@ PHP_FUNCTION(password_verify) } /* }}} */ -/* {{{ proto string password_make_salt(int length, int salt_type = PASSWORD_SALT_BCRYPT) -Make a new random salt */ -PHP_FUNCTION(password_make_salt) -{ - char *salt; - long length = 0, salt_type = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l|l", &length, &salt_type) == FAILURE) { - RETURN_NULL(); - } - if (length <= 0) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length cannot be less than or equal zero: %ld", length); - RETURN_NULL(); - } else if (length > (LONG_MAX / 3)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length is too large to safely generate"); - RETURN_NULL(); - } - - if (!salt_type) { - salt_type = PHP_PASSWORD_SALT_BCRYPT; - } - salt = safe_emalloc(length, 1, 1); - if (php_password_make_salt(length, (int) salt_type, salt TSRMLS_CC) == FAILURE) { - efree(salt); - RETURN_FALSE; - } - RETURN_STRINGL(salt, length, 0); -} -/* }}} */ - /* {{{ proto string password_hash(string password, int algo, array options = array()) Hash a password */ PHP_FUNCTION(password_hash) diff --git a/ext/standard/php_password.h b/ext/standard/php_password.h index 8211ae175331f..d99c061c008bf 100644 --- a/ext/standard/php_password.h +++ b/ext/standard/php_password.h @@ -23,7 +23,6 @@ PHP_FUNCTION(password_hash); PHP_FUNCTION(password_verify); -PHP_FUNCTION(password_make_salt); PHP_FUNCTION(password_needs_rehash); PHP_FUNCTION(password_get_info); diff --git a/ext/standard/tests/password/password_make_salt.phpt b/ext/standard/tests/password/password_make_salt.phpt deleted file mode 100644 index c7aa51455ed84..0000000000000 --- a/ext/standard/tests/password/password_make_salt.phpt +++ /dev/null @@ -1,40 +0,0 @@ ---TEST-- -Test normal operation of password_make_salt() ---FILE-- - ---EXPECT-- -1 -2 -3 -4 -5 - -1 -2 -3 -4 -5 - -bool(true) -OK! diff --git a/ext/standard/tests/password/password_make_salt_error.phpt b/ext/standard/tests/password/password_make_salt_error.phpt deleted file mode 100644 index 92df53ad0fef3..0000000000000 --- a/ext/standard/tests/password/password_make_salt_error.phpt +++ /dev/null @@ -1,37 +0,0 @@ ---TEST-- -Test error operation of password_make_salt() ---FILE-- - ---EXPECTF-- -Warning: password_make_salt() expects at least 1 parameter, 0 given in %s on line %d -NULL - -Warning: password_make_salt() expects parameter 1 to be long, string given in %s on line %d -NULL - -Warning: password_make_salt(): Length cannot be less than or equal zero: -1 in %s on line %d -NULL - -Warning: password_make_salt(): Length is too large to safely generate in %s on line %d -NULL - -Warning: password_make_salt(): Length is too large to safely generate in %s on line %d -NULL - -Warning: password_make_salt(): Unknown salt type paramter in %s on line %d -bool(false) From cc07038fa9b2a59893c52fb0c515a1fb03e56d5c Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 29 Aug 2012 20:31:34 +0200 Subject: [PATCH 2055/2394] Make sure that exception is thrown on rewind() after closing too --- Zend/tests/generators/generator_rewind.phpt | 16 ++++++++++++++++ Zend/zend_generators.c | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/Zend/tests/generators/generator_rewind.phpt b/Zend/tests/generators/generator_rewind.phpt index 3224f6a9b6d82..af885ef38203d 100644 --- a/Zend/tests/generators/generator_rewind.phpt +++ b/Zend/tests/generators/generator_rewind.phpt @@ -21,6 +21,14 @@ try { echo "\n", $e, "\n\n"; } +$gen = gen(); +foreach ($gen as $v) { } +try { + foreach ($gen as $v) { } +} catch (Exception $e) { + echo "\n", $e, "\n\n"; +} + function gen2() { echo "in generator\n"; @@ -40,4 +48,12 @@ Stack trace: #0 %s(%d): Generator->rewind() #1 {main} +before yield +after yield + +exception 'Exception' with message 'Cannot rewind a generator that was already run' in %s:%d +Stack trace: +#0 %s(%d): unknown() +#1 {main} + in generator diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 03294f7f0ea47..0eb17d02937bb 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -500,7 +500,7 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ static void zend_generator_ensure_initialized(zend_generator *generator TSRMLS_DC) /* {{{ */ { - if (!generator->value) { + if (generator->execute_data && !generator->value) { zend_generator_resume(generator TSRMLS_CC); generator->flags |= ZEND_GENERATOR_AT_FIRST_YIELD; } From bef79588d543db996d092191ac498751a1cc161f Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 29 Aug 2012 20:46:56 +0200 Subject: [PATCH 2056/2394] Fix segfault when traversing a by-ref generator twice If you try to traverse an already closed generator an exception will now be thrown. Furthermore this changes the error for traversing a by-val generator by-ref from an E_ERROR to an Exception. --- ...n_ref_generator_iterated_by_ref_error.phpt | 7 ++++++- Zend/tests/generators/generator_rewind.phpt | 19 +++++++++++-------- Zend/zend_generators.c | 8 +++++++- 3 files changed, 24 insertions(+), 10 deletions(-) diff --git a/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt b/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt index 9c618d2515612..de5b22f6ba63e 100644 --- a/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt +++ b/Zend/tests/generators/errors/non_ref_generator_iterated_by_ref_error.phpt @@ -10,4 +10,9 @@ foreach ($gen as &$value) { } ?> --EXPECTF-- -Fatal error: You can only iterate a generator by-reference if it declared that it yields by-reference in %s on line %d +Fatal error: Uncaught exception 'Exception' with message 'You can only iterate a generator by-reference if it declared that it yields by-reference' in %s:%d +Stack trace: +#0 %s(%d): unknown() +#1 {main} + thrown in %s on line %d + diff --git a/Zend/tests/generators/generator_rewind.phpt b/Zend/tests/generators/generator_rewind.phpt index af885ef38203d..c4b5bbbdf4944 100644 --- a/Zend/tests/generators/generator_rewind.phpt +++ b/Zend/tests/generators/generator_rewind.phpt @@ -21,21 +21,27 @@ try { echo "\n", $e, "\n\n"; } -$gen = gen(); +function &gen2() { + $foo = 'bar'; + yield $foo; + yield $foo; +} + +$gen = gen2(); foreach ($gen as $v) { } try { foreach ($gen as $v) { } } catch (Exception $e) { - echo "\n", $e, "\n\n"; + echo $e, "\n\n"; } -function gen2() { +function gen3() { echo "in generator\n"; if (false) yield; } -$gen = gen2(); +$gen = gen3(); $gen->rewind(); ?> @@ -48,10 +54,7 @@ Stack trace: #0 %s(%d): Generator->rewind() #1 {main} -before yield -after yield - -exception 'Exception' with message 'Cannot rewind a generator that was already run' in %s:%d +exception 'Exception' with message 'Cannot traverse an already closed generator' in %s:%d Stack trace: #0 %s(%d): unknown() #1 {main} diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 0eb17d02937bb..60fa8b64911fd 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -766,8 +766,14 @@ zend_object_iterator *zend_generator_get_iterator(zend_class_entry *ce, zval *ob generator = (zend_generator *) zend_object_store_get_object(object TSRMLS_CC); + if (!generator->execute_data) { + zend_throw_exception(NULL, "Cannot traverse an already closed generator", 0 TSRMLS_CC); + return NULL; + } + if (by_ref && !(generator->execute_data->op_array->fn_flags & ZEND_ACC_RETURN_REFERENCE)) { - zend_error(E_ERROR, "You can only iterate a generator by-reference if it declared that it yields by-reference"); + zend_throw_exception(NULL, "You can only iterate a generator by-reference if it declared that it yields by-reference", 0 TSRMLS_CC); + return NULL; } iterator = emalloc(sizeof(zend_generator_iterator)); From dbc7809b1746ef5dd895e6cd369134cb5270ae0b Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 29 Aug 2012 20:49:14 +0200 Subject: [PATCH 2057/2394] Fix typos --- Zend/zend_generators.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 60fa8b64911fd..c22d745bc362d 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -301,7 +301,7 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** Z_ADDREF_P(execute_data->object); } - /* Prev execute data contains an additional stack frame (for proper) + /* Prev execute data contains an additional stack frame (for proper * backtraces) which has to be copied. */ clone->execute_data->prev_execute_data = emalloc(sizeof(zend_execute_data)); memcpy(clone->execute_data->prev_execute_data, execute_data->prev_execute_data, sizeof(zend_execute_data)); @@ -643,9 +643,9 @@ ZEND_METHOD(Generator, send) RETURN_ZVAL(generator->value, 1, 0); } } +/* }}} */ - -/* {{{ proto void Generator::__wakeup +/* {{{ proto void Generator::__wakeup() * Throws an Exception as generators can't be serialized */ ZEND_METHOD(Generator, __wakeup) { From 167108d73cf7f37efb75bc32cef38ea4602ea229 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Fri, 31 Aug 2012 18:55:43 +0200 Subject: [PATCH 2058/2394] assert() user message Added 2nd, optional, param to assert. When passed in it will be added to the printed warnings and passed as a 4th param to a callback. PR 150 by Lonny Kapelushnik --- NEWS | 2 + ext/standard/assert.c | 48 +++++++++++++++----- ext/standard/tests/assert/assert04.phpt | 5 +- ext/standard/tests/assert/assert_error1.phpt | 11 +++-- 4 files changed, 47 insertions(+), 19 deletions(-) diff --git a/NEWS b/NEWS index 28b89baaac379..1ee977974a58b 100644 --- a/NEWS +++ b/NEWS @@ -24,6 +24,8 @@ PHP NEWS (srgoogleguy, Gustavo) . Implemented FR #60738 (Allow 'set_error_handler' to handle NULL). (Laruence, Nikita Popov) + . Added optional second argument for assert() to specify custom message. Patch + by Lonny Kapelushnik (lonny@lonnylot.com). (Lars) - cURL: . Added support for CURLOPT_FTP_RESPONSE_TIMEOUT, CURLOPT_APPEND, diff --git a/ext/standard/assert.c b/ext/standard/assert.c index a2c50d5cb6772..0ff3f9b7ef124 100644 --- a/ext/standard/assert.c +++ b/ext/standard/assert.c @@ -136,20 +136,20 @@ PHP_MINFO_FUNCTION(assert) /* {{{ */ } /* }}} */ -/* {{{ proto int assert(string|bool assertion) +/* {{{ proto int assert(string|bool assertion[, string description]) Checks if assertion is false */ PHP_FUNCTION(assert) { zval **assertion; - int val; + int val, description_len = 0; char *myeval = NULL; - char *compiled_string_description; + char *compiled_string_description, *description; if (! ASSERTG(active)) { RETURN_TRUE; } - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Z", &assertion) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Z|s", &assertion, &description, &description_len) == FAILURE) { return; } @@ -167,7 +167,11 @@ PHP_FUNCTION(assert) compiled_string_description = zend_make_compiled_string_description("assert code" TSRMLS_CC); if (zend_eval_stringl(myeval, Z_STRLEN_PP(assertion), &retval, compiled_string_description TSRMLS_CC) == FAILURE) { efree(compiled_string_description); - php_error_docref(NULL TSRMLS_CC, E_RECOVERABLE_ERROR, "Failure evaluating code: %s%s", PHP_EOL, myeval); + if (description_len == 0) { + php_error_docref(NULL TSRMLS_CC, E_RECOVERABLE_ERROR, "Failure evaluating code: %s%s", PHP_EOL, myeval); + } else { + php_error_docref(NULL TSRMLS_CC, E_RECOVERABLE_ERROR, "Failure evaluating code: %s%s:\"%s\"", PHP_EOL, description, myeval); + } if (ASSERTG(bail)) { zend_bailout(); } @@ -196,7 +200,7 @@ PHP_FUNCTION(assert) } if (ASSERTG(callback)) { - zval *args[3]; + zval **args = safe_emalloc(description_len == 0 ? 3 : 4, sizeof(zval **), 0); zval *retval; int i; uint lineno = zend_get_executed_lineno(TSRMLS_C); @@ -214,19 +218,38 @@ PHP_FUNCTION(assert) ZVAL_FALSE(retval); /* XXX do we want to check for error here? */ - call_user_function(CG(function_table), NULL, ASSERTG(callback), retval, 3, args TSRMLS_CC); + if (description_len == 0) { + call_user_function(CG(function_table), NULL, ASSERTG(callback), retval, 3, args TSRMLS_CC); + for (i = 0; i <= 2; i++) { + zval_ptr_dtor(&(args[i])); + } + } else { + MAKE_STD_ZVAL(args[3]); + ZVAL_STRINGL(args[3], SAFE_STRING(description), description_len, 1); - for (i = 0; i <= 2; i++) { - zval_ptr_dtor(&(args[i])); + call_user_function(CG(function_table), NULL, ASSERTG(callback), retval, 4, args TSRMLS_CC); + for (i = 0; i <= 3; i++) { + zval_ptr_dtor(&(args[i])); + } } + + efree(args); zval_ptr_dtor(&retval); } if (ASSERTG(warning)) { - if (myeval) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Assertion \"%s\" failed", myeval); + if (description_len == 0) { + if (myeval) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Assertion \"%s\" failed", myeval); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Assertion failed"); + } } else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Assertion failed"); + if (myeval) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s: \"%s\" failed", description, myeval); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s failed", description); + } } } @@ -321,3 +344,4 @@ PHP_FUNCTION(assert_options) * vim600: sw=4 ts=4 fdm=marker * vim<600: sw=4 ts=4 */ + diff --git a/ext/standard/tests/assert/assert04.phpt b/ext/standard/tests/assert/assert04.phpt index 0da23186e6432..bffadcb97c6e7 100644 --- a/ext/standard/tests/assert/assert04.phpt +++ b/ext/standard/tests/assert/assert04.phpt @@ -15,7 +15,7 @@ assert(1); /* Wrong parameter count in assert */ assert_options(ASSERT_ACTIVE, 1); -assert(2,3); +assert(2, "failure", 3); /* Wrong parameter count in assert_options */ assert_options(ASSERT_ACTIVE, 0, 2); @@ -36,7 +36,7 @@ echo "not reached\n"; ?> --EXPECTF-- -Warning: assert() expects exactly 1 parameter, 2 given in %s on line %d +Warning: assert() expects at most 2 parameters, 3 given in %s on line %d Warning: assert_options() expects at most 2 parameters, 3 given in %s on line %d @@ -45,3 +45,4 @@ Warning: assert_options() expects parameter 1 to be long, %unicode_string_option Warning: assert(): Assertion failed in %s on line %d Warning: assert(): Assertion failed in %s on line %d + diff --git a/ext/standard/tests/assert/assert_error1.phpt b/ext/standard/tests/assert/assert_error1.phpt index 6211f1c918b16..657b411f67e2d 100644 --- a/ext/standard/tests/assert/assert_error1.phpt +++ b/ext/standard/tests/assert/assert_error1.phpt @@ -20,19 +20,19 @@ function handler($errno, $errstr) { //Wrong number of parameters for assert_options() assert_options(ASSERT_WARNING, 1); -var_dump($rao=assert_options(ASSERT_CALLBACK,"f1",1)); +var_dump($rao = assert_options(ASSERT_CALLBACK, "f1", 1)); //Unknown option for assert_options() -var_dump($rao=assert_options("F1","f1")); +var_dump($rao=assert_options("F1", "f1")); //Wrong number of parameters for assert() $sa="0 != 0"; -var_dump($r2=assert($sa,1)); +var_dump($r2 = assert($sa, "message", 1)); //Catch recoverable error with handler -var_dump($rc=assert('aa=sd+as+safsafasfaçsafçsafç')); +var_dump($rc = assert('aa=sd+as+safsafasfaçsafçsafç')); --EXPECTF-- Warning: assert_options() expects at most 2 parameters, 3 given in %s on line %d NULL @@ -40,5 +40,6 @@ NULL Warning: assert_options() expects parameter 1 to be long, string given in %s on line %d NULL -Warning: assert() expects exactly 1 parameter, 2 given in %s on line %d +Warning: assert() expects at most 2 parameters, 3 given in %s on line %d NULL + From 64c168efc5fad8e9761b23dd02a99f5e5a1b46c2 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Fri, 31 Aug 2012 19:01:57 +0200 Subject: [PATCH 2059/2394] Tests for the previous assert() with user message --- ext/standard/tests/assert/assert_basic6.phpt | 26 +++++++++++++++++ ext/standard/tests/assert/assert_error2.phpt | 30 ++++++++++++++++++++ ext/standard/tests/assert/assert_error3.phpt | 21 ++++++++++++++ ext/standard/tests/assert/assert_error4.phpt | 21 ++++++++++++++ 4 files changed, 98 insertions(+) create mode 100644 ext/standard/tests/assert/assert_basic6.phpt create mode 100644 ext/standard/tests/assert/assert_error2.phpt create mode 100644 ext/standard/tests/assert/assert_error3.phpt create mode 100644 ext/standard/tests/assert/assert_error4.phpt diff --git a/ext/standard/tests/assert/assert_basic6.phpt b/ext/standard/tests/assert/assert_basic6.phpt new file mode 100644 index 0000000000000..2a73713437e0f --- /dev/null +++ b/ext/standard/tests/assert/assert_basic6.phpt @@ -0,0 +1,26 @@ +--TEST-- +assert() - basic - Test that bailout works +--INI-- +assert.active = 1 +assert.warning = 1 +assert.callback = f1 +assert.quiet_eval = 1 +assert.bail = 0 +--FILE-- + Date: Sat, 1 Sep 2012 20:10:12 +0200 Subject: [PATCH 2060/2394] Drop obsolete test --- tests/lang/foreachLoop.007.phpt | 11 ----------- 1 file changed, 11 deletions(-) delete mode 100644 tests/lang/foreachLoop.007.phpt diff --git a/tests/lang/foreachLoop.007.phpt b/tests/lang/foreachLoop.007.phpt deleted file mode 100644 index 269286d02427d..0000000000000 --- a/tests/lang/foreachLoop.007.phpt +++ /dev/null @@ -1,11 +0,0 @@ ---TEST-- -Foreach loop tests - error case: reference to constant array. ---FILE-- - ---EXPECTF-- -Fatal error: Cannot create references to elements of a temporary array expression in %sforeachLoop.007.php on line %d From dffffdeb3df0b05e79213e52667f3061dc9d635e Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 1 Sep 2012 20:31:40 +0200 Subject: [PATCH 2061/2394] Fix leak when yielding array as key The code was copy-pasted and I forgot to change OP1 to OP2 in that one place. --- Zend/tests/generators/yield_array_key.phpt | 18 ++++++++++++++++++ Zend/zend_vm_def.h | 2 +- Zend/zend_vm_execute.h | 16 ++++++++-------- 3 files changed, 27 insertions(+), 9 deletions(-) create mode 100644 Zend/tests/generators/yield_array_key.phpt diff --git a/Zend/tests/generators/yield_array_key.phpt b/Zend/tests/generators/yield_array_key.phpt new file mode 100644 index 0000000000000..5afba00de830a --- /dev/null +++ b/Zend/tests/generators/yield_array_key.phpt @@ -0,0 +1,18 @@ +--TEST-- +Array keys can be yielded from generators +--FILE-- + 1; +} + +$gen = gen(); +var_dump($gen->key()); +var_dump($gen->current()); + +?> +--EXPECT-- +array(0) { +} +int(1) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index ffd81b0378502..f683ff29727a6 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5511,7 +5511,7 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!IS_OP1_TMP_FREE()) { + if (!IS_OP2_TMP_FREE()) { zval_copy_ctor(copy); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index b0e05b1296aa9..f8a8905040008 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -5005,7 +5005,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!0) { + if (!1) { zval_copy_ctor(copy); } @@ -9553,7 +9553,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!1) { + if (!0) { zval_copy_ctor(copy); } @@ -11266,7 +11266,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!1) { + if (!0) { zval_copy_ctor(copy); } @@ -11846,7 +11846,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!1) { + if (!0) { zval_copy_ctor(copy); } @@ -12537,7 +12537,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!1) { + if (!0) { zval_copy_ctor(copy); } @@ -18543,7 +18543,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!0) { + if (!1) { zval_copy_ctor(copy); } @@ -27081,7 +27081,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!0) { + if (!1) { zval_copy_ctor(copy); } @@ -35600,7 +35600,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG INIT_PZVAL_COPY(copy, key); /* Temporary variables don't need ctor copying */ - if (!0) { + if (!1) { zval_copy_ctor(copy); } From 4e84f725544153d5b6fff99adc274d11f79b9079 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 2 Sep 2012 13:15:23 +0800 Subject: [PATCH 2062/2394] Fix test failed due to new Token T_YIELD --- ext/tokenizer/tests/bug60097.phpt | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/ext/tokenizer/tests/bug60097.phpt b/ext/tokenizer/tests/bug60097.phpt index e9f1bd6f6c929..2116866c93434 100644 --- a/ext/tokenizer/tests/bug60097.phpt +++ b/ext/tokenizer/tests/bug60097.phpt @@ -17,7 +17,7 @@ array(14) { [0]=> array(3) { [0]=> - int(373) + int(374) [1]=> string(6) " array(3) { [0]=> - int(377) + int(378) [1]=> string(8) "<< array(3) { [0]=> - int(380) + int(381) [1]=> string(1) "{" [2]=> @@ -46,7 +46,7 @@ array(14) { [3]=> array(3) { [0]=> - int(309) + int(310) [1]=> string(2) "$s" [2]=> @@ -57,7 +57,7 @@ array(14) { [5]=> array(3) { [0]=> - int(377) + int(378) [1]=> string(8) "<< array(3) { [0]=> - int(378) + int(379) [1]=> string(4) "DOC2" [2]=> @@ -76,7 +76,7 @@ array(14) { [7]=> array(3) { [0]=> - int(376) + int(377) [1]=> string(1) " " @@ -90,7 +90,7 @@ array(14) { [10]=> array(3) { [0]=> - int(314) + int(315) [1]=> string(1) " " @@ -100,7 +100,7 @@ array(14) { [11]=> array(3) { [0]=> - int(378) + int(379) [1]=> string(4) "DOC1" [2]=> @@ -111,7 +111,7 @@ array(14) { [13]=> array(3) { [0]=> - int(376) + int(377) [1]=> string(1) " " From e212de4a4492cd9dce8e45133604aa87083a0a92 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 2 Sep 2012 08:01:18 +0200 Subject: [PATCH 2063/2394] Initializing optional argument description in assert() --- ext/standard/assert.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/assert.c b/ext/standard/assert.c index 0ff3f9b7ef124..15fbefd51ce5b 100644 --- a/ext/standard/assert.c +++ b/ext/standard/assert.c @@ -143,7 +143,7 @@ PHP_FUNCTION(assert) zval **assertion; int val, description_len = 0; char *myeval = NULL; - char *compiled_string_description, *description; + char *compiled_string_description, *description = NULL; if (! ASSERTG(active)) { RETURN_TRUE; From 352a1956b60059f9792cac840d57b184c7305667 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 2 Sep 2012 14:52:05 +0200 Subject: [PATCH 2064/2394] Allow null as a default value for length in mb_substr() and mb_strcut() --- ext/mbstring/mbstring.c | 16 +++++++--- .../tests/mb_str_functions_opt-parameter.phpt | 30 +++++++++++++++++++ 2 files changed, 42 insertions(+), 4 deletions(-) create mode 100644 ext/mbstring/tests/mb_str_functions_opt-parameter.phpt diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 47f5fa4defa70..0861fa64812d2 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -2715,9 +2715,10 @@ PHP_FUNCTION(mb_substr) char *str, *encoding; long from, len; int mblen, str_len, encoding_len; + zval **z_len = NULL; mbfl_string string, result, *ret; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|ls", &str, &str_len, &from, &len, &encoding, &encoding_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|Zs", &str, &str_len, &from, &z_len, &encoding, &encoding_len) == FAILURE) { return; } @@ -2736,8 +2737,11 @@ PHP_FUNCTION(mb_substr) string.val = (unsigned char *)str; string.len = str_len; - if (argc < 3) { + if (argc < 3 || Z_TYPE_PP(z_len) == IS_NULL) { len = str_len; + } else { + convert_to_long_ex(z_len); + len = Z_LVAL_PP(z_len); } /* measures length */ @@ -2788,13 +2792,14 @@ PHP_FUNCTION(mb_strcut) char *encoding; long from, len; int encoding_len; + zval **z_len = NULL; mbfl_string string, result, *ret; mbfl_string_init(&string); string.no_language = MBSTRG(language); string.no_encoding = MBSTRG(current_internal_encoding)->no_encoding; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|ls", (char **)&string.val, (int **)&string.len, &from, &len, &encoding, &encoding_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|Zs", (char **)&string.val, (int **)&string.len, &from, &z_len, &encoding, &encoding_len) == FAILURE) { return; } @@ -2806,8 +2811,11 @@ PHP_FUNCTION(mb_strcut) } } - if (argc < 3) { + if (argc < 3 || Z_TYPE_PP(z_len) == IS_NULL) { len = string.len; + } else { + convert_to_long_ex(z_len); + len = Z_LVAL_PP(z_len); } /* if "from" position is negative, count start position from the end diff --git a/ext/mbstring/tests/mb_str_functions_opt-parameter.phpt b/ext/mbstring/tests/mb_str_functions_opt-parameter.phpt new file mode 100644 index 0000000000000..5fb642f9b2ef3 --- /dev/null +++ b/ext/mbstring/tests/mb_str_functions_opt-parameter.phpt @@ -0,0 +1,30 @@ +--TEST-- +Optional long parameter might be null +--FILE-- + +==DONE== +--EXPECT-- +1 +2 +1 +2 +barbaz +baz +barbaz +baz +baz +baz +foo +==DONE== From ad0da9ae60c8ed4c4331346fc6bf8343374049c9 Mon Sep 17 00:00:00 2001 From: Reeze Xia Date: Sun, 2 Sep 2012 23:29:56 +0800 Subject: [PATCH 2065/2394] Implemented ReflectionFunction::isGenerator() --- ext/reflection/php_reflection.c | 9 ++++ .../ReflectionFunction_isGenerator_basic.phpt | 52 +++++++++++++++++++ 2 files changed, 61 insertions(+) create mode 100644 ext/reflection/tests/ReflectionFunction_isGenerator_basic.phpt diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 7c9981924ded1..deabcbe7a43d5 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -3086,6 +3086,14 @@ ZEND_METHOD(reflection_function, isDeprecated) } /* }}} */ +/* {{{ proto public bool ReflectionFunction::isGenerator() + Returns whether this function is a generator */ +ZEND_METHOD(reflection_function, isGenerator) +{ + _function_check_flag(INTERNAL_FUNCTION_PARAM_PASSTHRU, ZEND_ACC_GENERATOR); +} +/* }}} */ + /* {{{ proto public bool ReflectionFunction::inNamespace() Returns whether this function is defined in namespace */ ZEND_METHOD(reflection_function, inNamespace) @@ -5696,6 +5704,7 @@ static const zend_function_entry reflection_function_abstract_functions[] = { ZEND_ME(reflection_function, isDeprecated, arginfo_reflection__void, 0) ZEND_ME(reflection_function, isInternal, arginfo_reflection__void, 0) ZEND_ME(reflection_function, isUserDefined, arginfo_reflection__void, 0) + ZEND_ME(reflection_function, isGenerator, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getClosureThis, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getClosureScopeClass, arginfo_reflection__void, 0) ZEND_ME(reflection_function, getDocComment, arginfo_reflection__void, 0) diff --git a/ext/reflection/tests/ReflectionFunction_isGenerator_basic.phpt b/ext/reflection/tests/ReflectionFunction_isGenerator_basic.phpt new file mode 100644 index 0000000000000..c4889b12bc59a --- /dev/null +++ b/ext/reflection/tests/ReflectionFunction_isGenerator_basic.phpt @@ -0,0 +1,52 @@ +--TEST-- +ReflectionFunction::isGenerator() +--FILE-- +isGenerator()); + +$rf2 = new ReflectionFunction($closure2); +var_dump($rf2->isGenerator()); + +function func1() { + return 'func1'; +} + +function func2() { + yield 'func2'; +} + +$rf1 = new ReflectionFunction('func1'); +var_dump($rf1->isGenerator()); + +$rf2 = new ReflectionFunction('func2'); +var_dump($rf2->isGenerator()); + + +class Foo { + public function f1() { + } + + public function f2() { + yield; + } +} + +$rc = new ReflectionClass('Foo'); +foreach($rc->getMethods() as $m) { + var_dump($m->isGenerator()); +} +?> +--EXPECTF-- +bool(false) +bool(true) +bool(false) +bool(true) +bool(false) +bool(true) From 4cca6241e03f0abd442fd867f397b14b3be9d0bd Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 3 Sep 2012 11:38:08 +0400 Subject: [PATCH 2066/2394] Fixed bug #50997 (SOAP Error when trying to submit 2nd Element of a choice) --- ext/soap/tests/bugs/bug50997.phpt | 16 +++++++++ ext/soap/tests/bugs/bug50997.wsdl | 54 +++++++++++++++++++++++++++++++ 2 files changed, 70 insertions(+) create mode 100644 ext/soap/tests/bugs/bug50997.phpt create mode 100644 ext/soap/tests/bugs/bug50997.wsdl diff --git a/ext/soap/tests/bugs/bug50997.phpt b/ext/soap/tests/bugs/bug50997.phpt new file mode 100644 index 0000000000000..0508aaccdcb8e --- /dev/null +++ b/ext/soap/tests/bugs/bug50997.phpt @@ -0,0 +1,16 @@ +--TEST-- +Bug #50997 (SOAP Error when trying to submit 2nd Element of a choice) +--SKIPIF-- + +--INI-- +soap.wsdl_cache_enabled=0 +--FILE-- + 1, 'exceptions'=>0)); +$params = array('code'=>'foo'); +$soapClient->newOperation($params); +echo $soapClient->__getLastRequest(); +?> +--EXPECT-- + +foo diff --git a/ext/soap/tests/bugs/bug50997.wsdl b/ext/soap/tests/bugs/bug50997.wsdl new file mode 100644 index 0000000000000..16c6d36752388 --- /dev/null +++ b/ext/soap/tests/bugs/bug50997.wsdl @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 2659f5e88e9e76594aff0d0c27500514dfef2cb2 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Mon, 3 Sep 2012 11:52:42 +0400 Subject: [PATCH 2067/2394] Fixed bug #50997 (SOAP Error when trying to submit 2nd Element of a choice) --- ext/soap/php_encoding.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ext/soap/php_encoding.c b/ext/soap/php_encoding.c index 84d603b591027..5addec4ff2d08 100644 --- a/ext/soap/php_encoding.c +++ b/ext/soap/php_encoding.c @@ -1818,11 +1818,12 @@ static int model_to_xml_object(xmlNodePtr node, sdlContentModelPtr model, zval * zend_hash_internal_pointer_reset_ex(model->u.content, &pos); while (zend_hash_get_current_data_ex(model->u.content, (void**)&tmp, &pos) == SUCCESS) { - if (!model_to_xml_object(node, *tmp, object, style, (*tmp)->min_occurs > 0 TSRMLS_CC)) { - if ((*tmp)->min_occurs > 0) { + if (!model_to_xml_object(node, *tmp, object, style, strict && ((*tmp)->min_occurs > 0) TSRMLS_CC)) { + if (!strict || (*tmp)->min_occurs > 0) { return 0; } } + strict = 1; zend_hash_move_forward_ex(model->u.content, &pos); } return 1; @@ -1845,7 +1846,7 @@ static int model_to_xml_object(xmlNodePtr node, sdlContentModelPtr model, zval * return ret; } case XSD_CONTENT_GROUP: { - return model_to_xml_object(node, model->u.group->model, object, style, model->min_occurs > 0 TSRMLS_CC); + return model_to_xml_object(node, model->u.group->model, object, style, strict && model->min_occurs > 0 TSRMLS_CC); } default: break; From db41f9fe60d863041fb53a273c2f64b6925f5ad0 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Tue, 4 Sep 2012 11:34:00 -0400 Subject: [PATCH 2068/2394] Refactoring to use size_t instead of int most places --- ext/standard/password.c | 150 +++++++++++++++++++++--------------- ext/standard/php_password.h | 3 - 2 files changed, 90 insertions(+), 63 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 4f8ef5dcab7ca..d3dc45742864c 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -44,7 +44,17 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ } /* }}} */ -static long php_password_determine_algo(const char *hash, const int len) +static char* php_password_get_algo_name(const int algo) +{ + switch (algo) { + case PHP_PASSWORD_BCRYPT: + return "bcrypt"; + default: + return "unknown"; + } +} + +static int php_password_determine_algo(const char *hash, const size_t len) { if (len < 3) { return 0; @@ -56,27 +66,33 @@ static long php_password_determine_algo(const char *hash, const int len) return 0; } -static int php_password_salt_is_alphabet(const char *str, const int len, const int salt_type) /* {{{ */ +static int php_password_salt_is_alphabet(const char *str, const size_t len) /* {{{ */ { - int i = 0; + size_t i = 0; - if (salt_type == PHP_PASSWORD_SALT_BCRYPT) { - for (i = 0; i < len; i++) { - if (!((str[i] >= 'A' && str[i] <= 'Z') || (str[i] >= 'a' && str[i] <= 'z') || (str[i] >= '0' && str[i] <= '9') || str[i] == '.' || str[i] == '/')) { - return 0; - } + for (i = 0; i < len; i++) { + if (!((str[i] >= 'A' && str[i] <= 'Z') || (str[i] >= 'a' && str[i] <= 'z') || (str[i] >= '0' && str[i] <= '9') || str[i] == '.' || str[i] == '/')) { + return 0; } } - return 1; } /* }}} */ -static int php_password_salt_to64(const char *str, const int str_len, const int out_len, char *ret) /* {{{ */ +static int php_password_salt_to64(const char *str, const size_t str_len, const size_t out_len, char *ret) /* {{{ */ { - int pos = 0; + size_t pos = 0; + size_t ret_len = 0; unsigned char *buffer; - buffer = php_base64_encode((unsigned char*) str, str_len, NULL); + if ((int) str_len < 0) { + return FAILURE; + } + buffer = php_base64_encode((unsigned char*) str, (int) str_len, (int*) &ret_len); + if (ret_len < out_len) { + /* Too short of an encoded string generated */ + efree(buffer); + return FAILURE; + } for (pos = 0; pos < out_len; pos++) { if (buffer[pos] == '+') { ret[pos] = '.'; @@ -92,30 +108,26 @@ static int php_password_salt_to64(const char *str, const int str_len, const int } /* }}} */ -static int php_password_make_salt(long length, int salt_type, char *ret TSRMLS_DC) /* {{{ */ +static int php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */ { int buffer_valid = 0; - long i, raw_length; + size_t i, raw_length; char *buffer; + char *result; - if (salt_type == PHP_PASSWORD_SALT_RAW) { - raw_length = length; - } else if (salt_type == PHP_PASSWORD_SALT_BCRYPT) { - if (length > (LONG_MAX / 3)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length is too large to safely generate"); - return FAILURE; - } - raw_length = length * 3 / 4 + 1; - } else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown salt type paramter"); + if (length > (INT_MAX / 3)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length is too large to safely generate"); return FAILURE; } + + raw_length = length * 3 / 4 + 1; + buffer = (char *) safe_emalloc(raw_length, 1, 1); #if PHP_WIN32 { BYTE *iv_b = (BYTE *) buffer; - if (php_win32_get_random_bytes(iv_b, (size_t) raw_length) == SUCCESS) { + if (php_win32_get_random_bytes(iv_b, raw_length) == SUCCESS) { buffer_valid = 1; } } @@ -130,11 +142,11 @@ static int php_password_make_salt(long length, int salt_type, char *ret TSRMLS_D if (n < 0) { break; } - read_bytes += n; + read_bytes += (size_t) n; } close(fd); } - if (read_bytes == raw_length) { + if (read_bytes >= raw_length) { buffer_valid = 1; } } @@ -145,22 +157,16 @@ static int php_password_make_salt(long length, int salt_type, char *ret TSRMLS_D } } - if (salt_type == PHP_PASSWORD_SALT_BCRYPT) { - char *result; - result = safe_emalloc(length, 1, 1); - if (php_password_salt_to64(buffer, raw_length, length, result) == FAILURE) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Generated salt too short"); - efree(buffer); - efree(result); - return FAILURE; - } else { - memcpy(ret, result, length); - efree(result); - } + result = safe_emalloc(length, 1, 1); + if (php_password_salt_to64(buffer, raw_length, length, result) == FAILURE) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Generated salt too short"); + efree(buffer); + efree(result); + return FAILURE; } else { - /* PHP_PASSWORD_SALT_RAW */ - memcpy(ret, buffer, length); + memcpy(ret, result, (int) length); } + efree(result); efree(buffer); ret[length] = 0; return SUCCESS; @@ -171,17 +177,23 @@ PHP_FUNCTION(password_get_info) { long algo; int hash_len; - char *hash; + char *hash, *algoName; zval *options; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &hash, &hash_len) == FAILURE) { RETURN_NULL(); } + if (hash_len < 0 || (size_t) hash_len < 0) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied Password Hash Too Long To Safely Identify"); + RETURN_FALSE; + } + ALLOC_INIT_ZVAL(options); array_init(options); - algo = php_password_determine_algo(hash, hash_len); + algo = php_password_determine_algo(hash, (size_t) hash_len); + algoName = php_password_get_algo_name(algo); switch (algo) { case PHP_PASSWORD_BCRYPT: @@ -196,6 +208,7 @@ PHP_FUNCTION(password_get_info) array_init(return_value); add_assoc_long(return_value, "algo", algo); + add_assoc_string(return_value, "algoName", algoName, 1); add_assoc_zval(return_value, "options", options); } @@ -210,7 +223,13 @@ PHP_FUNCTION(password_needs_rehash) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|H", &hash, &hash_len, &new_algo, &options) == FAILURE) { RETURN_NULL(); } - algo = php_password_determine_algo(hash, hash_len); + + if (hash_len < 0) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied Password Hash Too Long To Safely Identify"); + RETURN_FALSE; + } + + algo = php_password_determine_algo(hash, (size_t) hash_len); if (algo != new_algo) { RETURN_TRUE; @@ -252,7 +271,7 @@ PHP_FUNCTION(password_verify) RETURN_FALSE; } - if (strlen(ret) != hash_len) { + if (strlen(ret) != hash_len || hash_len < 13) { efree(ret); RETURN_FALSE; } @@ -278,7 +297,8 @@ PHP_FUNCTION(password_hash) { char *hash_format, *hash, *salt, *password, *result; long algo = 0; - int salt_len = 0, required_salt_len = 0, hash_format_len, password_len; + int password_len = 0, hash_len; + size_t salt_len = 0, required_salt_len = 0, hash_format_len; HashTable *options = 0; zval **option_buffer; @@ -289,7 +309,7 @@ PHP_FUNCTION(password_hash) switch (algo) { case PHP_PASSWORD_BCRYPT: { - int cost = PHP_PASSWORD_BCRYPT_COST; + long cost = PHP_PASSWORD_BCRYPT_COST; if (options && zend_symtable_find(options, "cost", 5, (void **) &option_buffer) == SUCCESS) { convert_to_long_ex(option_buffer); @@ -298,13 +318,13 @@ PHP_FUNCTION(password_hash) } if (cost < 4 || cost > 31) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid bcrypt cost parameter specified: %d", cost); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid bcrypt cost parameter specified: %ld", cost); RETURN_NULL(); } required_salt_len = 22; hash_format = emalloc(8); - sprintf(hash_format, "$2y$%02d$", cost); + sprintf(hash_format, "$2y$%02ld$", cost); hash_format_len = 7; } break; @@ -315,7 +335,8 @@ PHP_FUNCTION(password_hash) if (options && zend_symtable_find(options, "salt", 5, (void**) &option_buffer) == SUCCESS) { char *buffer; - int buffer_len; + int buffer_len_int; + size_t buffer_len; switch (Z_TYPE_PP(option_buffer)) { case IS_NULL: case IS_STRING: @@ -326,7 +347,13 @@ PHP_FUNCTION(password_hash) convert_to_string_ex(option_buffer); if (Z_TYPE_PP(option_buffer) == IS_STRING) { buffer = Z_STRVAL_PP(option_buffer); - buffer_len = Z_STRLEN_PP(option_buffer); + buffer_len_int = Z_STRLEN_PP(option_buffer); + if (buffer_len_int < 0) { + zval_ptr_dtor(option_buffer); + efree(hash_format); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied salt is too long"); + } + buffer_len = (size_t) buffer_len_int; break; } case IS_RESOURCE: @@ -340,27 +367,27 @@ PHP_FUNCTION(password_hash) if (buffer_len < required_salt_len) { efree(hash_format); zval_ptr_dtor(option_buffer); - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %d expecting %d", buffer_len, required_salt_len); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu expecting %lu", (unsigned long) buffer_len, (unsigned long) required_salt_len); RETURN_NULL(); - } else if (0 == php_password_salt_is_alphabet(buffer, buffer_len, PHP_PASSWORD_SALT_BCRYPT)) { - salt = emalloc(required_salt_len + 1); + } else if (0 == php_password_salt_is_alphabet(buffer, buffer_len)) { + salt = safe_emalloc(required_salt_len, 1, 1); if (php_password_salt_to64(buffer, buffer_len, required_salt_len, salt) == FAILURE) { efree(hash_format); efree(salt); zval_ptr_dtor(option_buffer); - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %d", salt_len); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu", (unsigned long) buffer_len); RETURN_NULL(); } salt_len = required_salt_len; } else { - salt = emalloc(required_salt_len + 1); - memcpy(salt, buffer, required_salt_len); + salt = safe_emalloc(required_salt_len, 1, 1); + memcpy(salt, buffer, (int) required_salt_len); salt_len = required_salt_len; } zval_ptr_dtor(option_buffer); } else { - salt = emalloc(required_salt_len + 1); - if (php_password_make_salt((long) required_salt_len, PHP_PASSWORD_SALT_BCRYPT, salt TSRMLS_CC) == FAILURE) { + salt = safe_emalloc(required_salt_len, 1, 1); + if (php_password_make_salt(required_salt_len, salt TSRMLS_CC) == FAILURE) { efree(hash_format); efree(salt); RETURN_FALSE; @@ -377,7 +404,10 @@ PHP_FUNCTION(password_hash) efree(hash_format); efree(salt); - if (php_crypt(password, password_len, hash, hash_format_len + salt_len, &result) == FAILURE) { + /* This cast is safe, since both values are defined here in code and cannot overflow */ + hash_len = (int) (hash_format_len + salt_len); + + if (php_crypt(password, password_len, hash, hash_len, &result) == FAILURE) { efree(hash); RETURN_FALSE; } diff --git a/ext/standard/php_password.h b/ext/standard/php_password.h index d99c061c008bf..db7747a3db6b9 100644 --- a/ext/standard/php_password.h +++ b/ext/standard/php_password.h @@ -31,9 +31,6 @@ PHP_MINIT_FUNCTION(password); #define PHP_PASSWORD_DEFAULT 1 #define PHP_PASSWORD_BCRYPT 1 -#define PHP_PASSWORD_SALT_RAW 1 -#define PHP_PASSWORD_SALT_BCRYPT 2 - #define PHP_PASSWORD_BCRYPT_COST 10 #endif From 72473962a9722ee0a8107909f32c145d3b44f906 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 5 Sep 2012 09:50:55 +0400 Subject: [PATCH 2069/2394] Fixed bug #62991 (Segfault with generator and closure) --- Zend/tests/bug62991.phpt | 50 ++++++++++++++++++++++++++++++++++++++++ Zend/zend_generators.c | 14 +++++++++++ 2 files changed, 64 insertions(+) create mode 100644 Zend/tests/bug62991.phpt diff --git a/Zend/tests/bug62991.phpt b/Zend/tests/bug62991.phpt new file mode 100644 index 0000000000000..cb4ff933591b6 --- /dev/null +++ b/Zend/tests/bug62991.phpt @@ -0,0 +1,50 @@ +--TEST-- +Bug #62991 (Segfault with generator and closure) +--FILE-- + +--EXPECT-- +Array +( + [0] => 1 + [1] => 2 + [2] => 3 +) +Array +( + [0] => 1 + [1] => 2 + [2] => 3 +) +okey diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index c22d745bc362d..3d4fdd2c5ff1c 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -154,6 +154,12 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio efree(prev_execute_data); } + /* Free a clone of closure */ + if (op_array->fn_flags & ZEND_ACC_CLOSURE) { + destroy_op_array(op_array TSRMLS_CC); + efree(op_array); + } + efree(execute_data); generator->execute_data = NULL; } @@ -358,6 +364,14 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ zval *return_value; zend_generator *generator; + /* Create a clone of closure, because it may be destroyed */ + if (op_array->fn_flags & ZEND_ACC_CLOSURE) { + zend_op_array *op_array_copy = (zend_op_array*)emalloc(sizeof(zend_op_array)); + *op_array_copy = *op_array; + function_add_ref(op_array_copy); + op_array = op_array_copy; + } + /* Create new execution context. We have to back up and restore * EG(current_execute_data) and EG(opline_ptr) here because the function * modifies it. */ From 4a7d1b4ed8987188c3a628601ad9a027bf88b7eb Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Wed, 5 Sep 2012 12:53:29 +0200 Subject: [PATCH 2070/2394] - fix build, declarations must be 1st in a contextgit checkout -f master --- Zend/zend_generators.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 3d4fdd2c5ff1c..83025eacd161f 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -363,6 +363,9 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ { zval *return_value; zend_generator *generator; + zend_execute_data *current_execute_data; + zend_op **opline_ptr; + zend_execute_data *execute_data; /* Create a clone of closure, because it may be destroyed */ if (op_array->fn_flags & ZEND_ACC_CLOSURE) { @@ -375,9 +378,9 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ /* Create new execution context. We have to back up and restore * EG(current_execute_data) and EG(opline_ptr) here because the function * modifies it. */ - zend_execute_data *current_execute_data = EG(current_execute_data); - zend_op **opline_ptr = EG(opline_ptr); - zend_execute_data *execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); + current_execute_data = EG(current_execute_data); + opline_ptr = EG(opline_ptr); + execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); EG(current_execute_data) = current_execute_data; EG(opline_ptr) = opline_ptr; From dabe89c6f36a03117e1614546dd90de80b9e90d4 Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 8 Sep 2012 18:46:33 +0200 Subject: [PATCH 2071/2394] -enable VC11 (vc2012) --- win32/build/config.w32 | 9 +++++++-- win32/build/confutils.js | 2 ++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/win32/build/config.w32 b/win32/build/config.w32 index 92347e76b5308..cca70540bf0b7 100644 --- a/win32/build/config.w32 +++ b/win32/build/config.w32 @@ -163,8 +163,13 @@ if (VCVERS >= 1500 && PHP_MP != 'disable') { } // General link flags -DEFINE("LDFLAGS", "/nologo /version:" + - PHP_VERSION + "." + PHP_MINOR_VERSION + "." + PHP_RELEASE_VERSION); + +if (VCVERS >= 1700) { + DEFINE("LDFLAGS", "/nologo "); +} else { + DEFINE("LDFLAGS", "/nologo /version:" + + PHP_VERSION + "." + PHP_MINOR_VERSION + "." + PHP_RELEASE_VERSION); +} // General DLL link flags DEFINE("DLL_LDFLAGS", "/dll "); diff --git a/win32/build/confutils.js b/win32/build/confutils.js index d1f7eca57d3e6..1362e63ead6e9 100644 --- a/win32/build/confutils.js +++ b/win32/build/confutils.js @@ -46,6 +46,7 @@ VC_VERSIONS[1310] = 'MSVC7.1 (Visual C++ 2003)'; VC_VERSIONS[1400] = 'MSVC8 (Visual C++ 2005)'; VC_VERSIONS[1500] = 'MSVC9 (Visual C++ 2008)'; VC_VERSIONS[1600] = 'MSVC10 (Visual C++ 2010)'; +VC_VERSIONS[1700] = 'MSVC11 (Visual C++ 2012)'; var VC_VERSIONS_SHORT = new Array(); VC_VERSIONS_SHORT[1200] = 'VC6'; @@ -54,6 +55,7 @@ VC_VERSIONS_SHORT[1310] = 'VC7.1'; VC_VERSIONS_SHORT[1400] = 'VC8'; VC_VERSIONS_SHORT[1500] = 'VC9'; VC_VERSIONS_SHORT[1600] = 'VC10'; +VC_VERSIONS_SHORT[1700] = 'VC11'; if (PROGRAM_FILES == null) { PROGRAM_FILES = "C:\\Program Files"; From e06c47ca2ab482ab5e6ba47a9249a9b9417cb1b4 Mon Sep 17 00:00:00 2001 From: Simon Welsh Date: Tue, 11 Sep 2012 21:14:51 +1200 Subject: [PATCH 2072/2394] Provide a specific error message if date.timezone value is invalid. --- ext/date/php_date.c | 7 ++++++- ext/date/tests/date_default_timezone_get-4.phpt | 11 +++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 ext/date/tests/date_default_timezone_get-4.phpt diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 7c4e7820bb54d..eac6ca505fb03 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -862,9 +862,14 @@ static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC) } } else if (*DATEG(default_timezone) && timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) { return DATEG(default_timezone); + } else if (*DATEG(default_timezone)) { + /* Invalid date.timezone value */ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "date.timezone value '%s' is invalid. We selected the timezone 'UTC' for now.", DATEG(default_timezone)); + } else { + /* No date.timezone value */ + php_error_docref(NULL TSRMLS_CC, E_WARNING, DATE_TZ_ERRMSG "We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone."); } /* Fallback to UTC */ - php_error_docref(NULL TSRMLS_CC, E_WARNING, DATE_TZ_ERRMSG "We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone."); return "UTC"; } diff --git a/ext/date/tests/date_default_timezone_get-4.phpt b/ext/date/tests/date_default_timezone_get-4.phpt new file mode 100644 index 0000000000000..e76d4e3ed26bd --- /dev/null +++ b/ext/date/tests/date_default_timezone_get-4.phpt @@ -0,0 +1,11 @@ +--TEST-- +date_default_timezone_get() function [4] +--INI-- +date.timezone=Incorrect/Zone +--FILE-- + +--EXPECTF-- +Warning: date_default_timezone_get(): date.timezone value 'Incorrect/Zone' is invalid. We selected the timezone 'UTC' for now. in %sdate_default_timezone_get-4.php on line %d +UTC From 79e6635cb66a9efd47d48012bafe00f2897b0814 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 11 Sep 2012 18:02:19 +0800 Subject: [PATCH 2073/2394] Rearrange the codes, remove empty lines --- ext/date/php_date.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index eac6ca505fb03..e43ff19a5bec2 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -738,7 +738,6 @@ PHP_RSHUTDOWN_FUNCTION(date) #define SUNFUNCS_RET_STRING 1 #define SUNFUNCS_RET_DOUBLE 2 - /* {{{ PHP_MINIT_FUNCTION */ PHP_MINIT_FUNCTION(date) { @@ -860,9 +859,10 @@ static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC) timelib_timezone_id_is_valid(Z_STRVAL(ztz), tzdb)) { return Z_STRVAL(ztz); } - } else if (*DATEG(default_timezone) && timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) { - return DATEG(default_timezone); } else if (*DATEG(default_timezone)) { + if (timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) { + return DATEG(default_timezone); + } /* Invalid date.timezone value */ php_error_docref(NULL TSRMLS_CC, E_WARNING, "date.timezone value '%s' is invalid. We selected the timezone 'UTC' for now.", DATEG(default_timezone)); } else { @@ -887,7 +887,6 @@ PHPAPI timelib_tzinfo *get_timezone_info(TSRMLS_D) } /* }}} */ - /* {{{ date() and gmdate() data */ #include "ext/standard/php_smart_str.h" @@ -1323,7 +1322,6 @@ PHPAPI signed long php_parse_date(char *string, signed long *now) } /* }}} */ - /* {{{ proto int strtotime(string time [, int now ]) Convert string representation of date and time to a timestamp */ PHP_FUNCTION(strtotime) @@ -1384,7 +1382,6 @@ PHP_FUNCTION(strtotime) } /* }}} */ - /* {{{ php_mktime - (gm)mktime helper */ PHPAPI void php_mktime(INTERNAL_FUNCTION_PARAMETERS, int gmt) { @@ -1493,7 +1490,6 @@ PHP_FUNCTION(gmmktime) } /* }}} */ - /* {{{ proto bool checkdate(int month, int day, int year) Returns true(1) if it is a valid date in gregorian calendar */ PHP_FUNCTION(checkdate) From f6000a01e286f855a7f40fcad738a1f9b00aa81e Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 11 Sep 2012 18:09:47 +0800 Subject: [PATCH 2074/2394] Capitalize the warning message --- ext/date/php_date.c | 2 +- ext/date/tests/date_default_timezone_get-4.phpt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index e43ff19a5bec2..765da9ec4580e 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -864,7 +864,7 @@ static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC) return DATEG(default_timezone); } /* Invalid date.timezone value */ - php_error_docref(NULL TSRMLS_CC, E_WARNING, "date.timezone value '%s' is invalid. We selected the timezone 'UTC' for now.", DATEG(default_timezone)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid date.timezone value '%s', we selected the timezone 'UTC' for now.", DATEG(default_timezone)); } else { /* No date.timezone value */ php_error_docref(NULL TSRMLS_CC, E_WARNING, DATE_TZ_ERRMSG "We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone."); diff --git a/ext/date/tests/date_default_timezone_get-4.phpt b/ext/date/tests/date_default_timezone_get-4.phpt index e76d4e3ed26bd..6d1982bc13d1b 100644 --- a/ext/date/tests/date_default_timezone_get-4.phpt +++ b/ext/date/tests/date_default_timezone_get-4.phpt @@ -7,5 +7,5 @@ date.timezone=Incorrect/Zone echo date_default_timezone_get(), "\n"; ?> --EXPECTF-- -Warning: date_default_timezone_get(): date.timezone value 'Incorrect/Zone' is invalid. We selected the timezone 'UTC' for now. in %sdate_default_timezone_get-4.php on line %d +Warning: date_default_timezone_get(): Invalid date.timezone value 'Incorrect/Zone', we selected the timezone 'UTC' for now. in %sdate_default_timezone_get-4.php on line %d UTC From 5246d6f02e52798e343bd5208692f1a5ed89b9d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gustavo=20Andr=C3=A9=20dos=20Santos=20Lopes?= Date: Wed, 12 Sep 2012 09:05:28 +0100 Subject: [PATCH 2075/2394] Generators & UPGRADING --- UPGRADING | 2 ++ 1 file changed, 2 insertions(+) diff --git a/UPGRADING b/UPGRADING index ba556357ed489..59dfbb436acd2 100755 --- a/UPGRADING +++ b/UPGRADING @@ -40,6 +40,8 @@ PHP X.Y UPGRADE NOTES - Add support for using empty() on the result of function calls and other expressions. Thus it is now possible to write empty(getArray()), for example. (https://wiki.php.net/rfc/empty_isset_exprs) +- Added generators. + (https://wiki.php.net/rfc/generators) ======================================== 2. Changes in SAPI modules From e8b7f5b35da46a2bc414c922e8e1a7093d963899 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Wed, 12 Sep 2012 11:21:08 -0400 Subject: [PATCH 2076/2394] Add tests for password_get_info and password_needs_rehash --- .../tests/password/password_get_info.phpt | 58 +++++++++++++++++++ .../password/password_get_info_error.phpt | 17 ++++++ .../tests/password/password_needs_rehash.phpt | 39 +++++++++++++ .../password/password_needs_rehash_error.phpt | 33 +++++++++++ 4 files changed, 147 insertions(+) create mode 100644 ext/standard/tests/password/password_get_info.phpt create mode 100644 ext/standard/tests/password/password_get_info_error.phpt create mode 100644 ext/standard/tests/password/password_needs_rehash.phpt create mode 100644 ext/standard/tests/password/password_needs_rehash_error.phpt diff --git a/ext/standard/tests/password/password_get_info.phpt b/ext/standard/tests/password/password_get_info.phpt new file mode 100644 index 0000000000000..4c8dc04ff802e --- /dev/null +++ b/ext/standard/tests/password/password_get_info.phpt @@ -0,0 +1,58 @@ +--TEST-- +Test normal operation of password_get_info() +--FILE-- + +--EXPECT-- +array(3) { + ["algo"]=> + int(1) + ["algoName"]=> + string(6) "bcrypt" + ["options"]=> + array(1) { + ["cost"]=> + int(10) + } +} +array(3) { + ["algo"]=> + int(1) + ["algoName"]=> + string(6) "bcrypt" + ["options"]=> + array(1) { + ["cost"]=> + int(11) + } +} +array(3) { + ["algo"]=> + int(0) + ["algoName"]=> + string(7) "unknown" + ["options"]=> + array(0) { + } +} +array(3) { + ["algo"]=> + int(0) + ["algoName"]=> + string(7) "unknown" + ["options"]=> + array(0) { + } +} +OK! diff --git a/ext/standard/tests/password/password_get_info_error.phpt b/ext/standard/tests/password/password_get_info_error.phpt new file mode 100644 index 0000000000000..af676744c8b30 --- /dev/null +++ b/ext/standard/tests/password/password_get_info_error.phpt @@ -0,0 +1,17 @@ +--TEST-- +Test error operation of password_get_info() +--FILE-- + +--EXPECTF-- +Warning: password_get_info() expects exactly 1 parameter, 0 given in %s on line %d +NULL + +Warning: password_get_info() expects parameter 1 to be string, array given in %s on line %d +NULL +OK! diff --git a/ext/standard/tests/password/password_needs_rehash.phpt b/ext/standard/tests/password/password_needs_rehash.phpt new file mode 100644 index 0000000000000..0c03d88b4d440 --- /dev/null +++ b/ext/standard/tests/password/password_needs_rehash.phpt @@ -0,0 +1,39 @@ +--TEST-- +Test normal operation of password_needs_rehash() +--FILE-- + 10))); + +// Valid with cost the same, additional params +var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT, array('cost' => 10, 'foo' => 3))); + +// Invalid, different (lower) cost +var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT, array('cost' => 09))); + +// Invalid, different (higher) cost +var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT, array('cost' => 11))); + +// Valid with cost the default (may need to be updated as the default cost increases) +var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT)); + + +echo "OK!"; +?> +--EXPECT-- +bool(true) +bool(false) +bool(false) +bool(false) +bool(true) +bool(true) +bool(false) +OK! diff --git a/ext/standard/tests/password/password_needs_rehash_error.phpt b/ext/standard/tests/password/password_needs_rehash_error.phpt new file mode 100644 index 0000000000000..e25ef8db3f4dd --- /dev/null +++ b/ext/standard/tests/password/password_needs_rehash_error.phpt @@ -0,0 +1,33 @@ +--TEST-- +Test error operation of password_needs_rehash() +--FILE-- + +--EXPECTF-- +Warning: password_needs_rehash() expects at least 2 parameters, 0 given in %s on line %d +NULL + +Warning: password_needs_rehash() expects at least 2 parameters, 1 given in %s on line %d +NULL + +Warning: password_needs_rehash() expects parameter 2 to be long, string given in %s on line %d +NULL + +Warning: password_needs_rehash() expects parameter 1 to be string, array given in %s on line %d +NULL + +Warning: password_needs_rehash() expects parameter 3 to be array, string given in %s on line %d +NULL +OK! From e9a7bde829b3e43e2c61455752801e31ea88974f Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Wed, 12 Sep 2012 11:37:56 -0400 Subject: [PATCH 2077/2394] Switch test to using strict comparison for crypt fallback --- ext/standard/tests/password/password_hash.phpt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/tests/password/password_hash.phpt b/ext/standard/tests/password/password_hash.phpt index ff48b29b169a9..f59d3d5e488ab 100644 --- a/ext/standard/tests/password/password_hash.phpt +++ b/ext/standard/tests/password/password_hash.phpt @@ -8,7 +8,7 @@ var_dump(strlen(password_hash("foo", PASSWORD_BCRYPT))); $hash = password_hash("foo", PASSWORD_BCRYPT); -var_dump($hash == crypt("foo", $hash)); +var_dump($hash === crypt("foo", $hash)); var_dump(password_hash("rasmuslerdorf", PASSWORD_BCRYPT, array("cost" => 7, "salt" => "usesomesillystringforsalt"))); From ebe0bd5dee07bebd8444d9e7c28864ba17efeef8 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Wed, 12 Sep 2012 11:44:03 -0400 Subject: [PATCH 2078/2394] Remove bcrypt_cost ini entry from declaration --- main/main.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/main/main.c b/main/main.c index 2f40dc91b7df2..5eb9947fe7a5c 100644 --- a/main/main.c +++ b/main/main.c @@ -539,8 +539,6 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("error_append_string", NULL, PHP_INI_ALL, OnUpdateString, error_append_string, php_core_globals, core_globals) STD_PHP_INI_ENTRY("error_prepend_string", NULL, PHP_INI_ALL, OnUpdateString, error_prepend_string, php_core_globals, core_globals) - PHP_INI_ENTRY("password.bcrypt_cost", "11", PHP_INI_ALL, NULL) - PHP_INI_ENTRY("SMTP", "localhost",PHP_INI_ALL, NULL) PHP_INI_ENTRY("smtp_port", "25", PHP_INI_ALL, NULL) STD_PHP_INI_BOOLEAN("mail.add_x_header", "0", PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateBool, mail_x_header, php_core_globals, core_globals) From 76f3295cdfd6a3106297352e73b9691084582211 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Wed, 12 Sep 2012 11:47:50 -0400 Subject: [PATCH 2079/2394] Expose PASSWORD_BCRYPT_DEFAULT_COST constant and update test to use it --- ext/standard/password.c | 2 ++ ext/standard/tests/password/password_needs_rehash.phpt | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index d3dc45742864c..9b1bb8cccaf5b 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -40,6 +40,8 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ REGISTER_LONG_CONSTANT("PASSWORD_DEFAULT", PHP_PASSWORD_DEFAULT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT", PHP_PASSWORD_BCRYPT, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT_DEFAULT_COST", PHP_PASSWORD_BCRYPT_COST, CONST_CS | CONST_PERSISTENT); + return SUCCESS; } /* }}} */ diff --git a/ext/standard/tests/password/password_needs_rehash.phpt b/ext/standard/tests/password/password_needs_rehash.phpt index 0c03d88b4d440..2fc3983980165 100644 --- a/ext/standard/tests/password/password_needs_rehash.phpt +++ b/ext/standard/tests/password/password_needs_rehash.phpt @@ -22,9 +22,9 @@ var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9H // Invalid, different (higher) cost var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT, array('cost' => 11))); -// Valid with cost the default (may need to be updated as the default cost increases) -var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT)); - +// Valid with cost the default +$cost = str_pad(PASSWORD_BCRYPT_DEFAULT_COST, 2, '0', STR_PAD_LEFT); +var_dump(password_needs_rehash('$2y$'.$cost.'$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT)); echo "OK!"; ?> From 7161c3d2cfde54ce218f20d03684f2a58e1c7627 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Wed, 12 Sep 2012 11:56:12 -0400 Subject: [PATCH 2080/2394] Add news entry for password API --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index 1ee977974a58b..08045fc23a185 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,8 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Add simplified password hashing API + (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) . Support list in foreach (https://wiki.php.net/rfc/foreachlist). (Laruence) . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) . Drop Windows XP and 2003 support. (Pierre) From 7ec80e1a139ca7f43c02728f3fe2424cef0138b6 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Wed, 12 Sep 2012 12:15:33 -0400 Subject: [PATCH 2081/2394] Fix incorrect arg info required param count for password_hash --- ext/standard/basic_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index ece64f375f4e9..cf2266c31dd85 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -1855,7 +1855,7 @@ ZEND_BEGIN_ARG_INFO(arginfo_getlastmod, 0) ZEND_END_ARG_INFO() /* }}} */ /* {{{ password.c */ -ZEND_BEGIN_ARG_INFO_EX(arginfo_password_hash, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_password_hash, 0, 0, 2) ZEND_ARG_INFO(0, password) ZEND_ARG_INFO(0, algo) ZEND_ARG_INFO(0, options) From 83cfff4593bd3bd7791f32795e9b5bda446cd8e2 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Thu, 13 Sep 2012 10:32:54 -0400 Subject: [PATCH 2082/2394] Switch to using an ENUM for algorithms instead of a constant --- ext/standard/password.c | 38 ++++++++++++++++++++----------------- ext/standard/php_password.h | 8 ++++++-- 2 files changed, 27 insertions(+), 19 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 9b1bb8cccaf5b..0dd8fed645565 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -38,7 +38,7 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ { REGISTER_LONG_CONSTANT("PASSWORD_DEFAULT", PHP_PASSWORD_DEFAULT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT", PHP_PASSWORD_BCRYPT, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT", PASSWORD_BCRYPT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT_DEFAULT_COST", PHP_PASSWORD_BCRYPT_COST, CONST_CS | CONST_PERSISTENT); @@ -46,29 +46,26 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ } /* }}} */ -static char* php_password_get_algo_name(const int algo) +static char* php_password_get_algo_name(const php_password_algos algo) { switch (algo) { - case PHP_PASSWORD_BCRYPT: + case PASSWORD_BCRYPT: return "bcrypt"; default: return "unknown"; } } -static int php_password_determine_algo(const char *hash, const size_t len) +static php_password_algos php_password_determine_algo(const char *hash, const size_t len) { - if (len < 3) { - return 0; - } - if (hash[0] == '$' && hash[1] == '2' && hash[2] == 'y' && len == 60) { - return PHP_PASSWORD_BCRYPT; + if (len > 3 && hash[0] == '$' && hash[1] == '2' && hash[2] == 'y' && len == 60) { + return PASSWORD_BCRYPT; } - return 0; + return PASSWORD_UNKNOWN; } -static int php_password_salt_is_alphabet(const char *str, const size_t len) /* {{{ */ +static zend_bool php_password_salt_is_alphabet(const char *str, const size_t len) /* {{{ */ { size_t i = 0; @@ -177,7 +174,7 @@ static int php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */ PHP_FUNCTION(password_get_info) { - long algo; + php_password_algos algo; int hash_len; char *hash, *algoName; zval *options; @@ -198,13 +195,16 @@ PHP_FUNCTION(password_get_info) algoName = php_password_get_algo_name(algo); switch (algo) { - case PHP_PASSWORD_BCRYPT: + case PASSWORD_BCRYPT: { long cost = PHP_PASSWORD_BCRYPT_COST; sscanf(hash, "$2y$%ld$", &cost); add_assoc_long(options, "cost", cost); } - break; + break; + case PASSWORD_UNKNOWN: + default: + break; } array_init(return_value); @@ -216,7 +216,8 @@ PHP_FUNCTION(password_get_info) PHP_FUNCTION(password_needs_rehash) { - long new_algo = 0, algo = 0; + long new_algo = 0; + php_password_algos algo; int hash_len; char *hash; HashTable *options = 0; @@ -238,7 +239,7 @@ PHP_FUNCTION(password_needs_rehash) } switch (algo) { - case PHP_PASSWORD_BCRYPT: + case PASSWORD_BCRYPT: { int newCost = PHP_PASSWORD_BCRYPT_COST, cost = 0; @@ -254,6 +255,9 @@ PHP_FUNCTION(password_needs_rehash) } } break; + case PASSWORD_UNKNOWN: + default: + break; } RETURN_FALSE; } @@ -309,7 +313,7 @@ PHP_FUNCTION(password_hash) } switch (algo) { - case PHP_PASSWORD_BCRYPT: + case PASSWORD_BCRYPT: { long cost = PHP_PASSWORD_BCRYPT_COST; diff --git a/ext/standard/php_password.h b/ext/standard/php_password.h index db7747a3db6b9..c812e2c492ae5 100644 --- a/ext/standard/php_password.h +++ b/ext/standard/php_password.h @@ -28,11 +28,15 @@ PHP_FUNCTION(password_get_info); PHP_MINIT_FUNCTION(password); -#define PHP_PASSWORD_DEFAULT 1 -#define PHP_PASSWORD_BCRYPT 1 +#define PHP_PASSWORD_DEFAULT PASSWORD_BCRYPT #define PHP_PASSWORD_BCRYPT_COST 10 +typedef enum { + PASSWORD_UNKNOWN, + PASSWORD_BCRYPT +} php_password_algos; + #endif From fb03ce93d3829b4e7378b2d3522da6fb2db12205 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 16 Sep 2012 21:48:57 +0200 Subject: [PATCH 2083/2394] Fix invalid read / remove useless code Generators follow a different cleanup path, so the extra check for freeing the execute_data is unnecessary there. It actually caused problems because op_array->fn_flags could be in freed memory at that time (in case op_array came from a closure in an ArrayAccess container). This fixes the valgrind warning in Zend/tests/bug54367.phpt. --- Zend/zend_vm_def.h | 8 +------- Zend/zend_vm_execute.h | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index f683ff29727a6..be2021ab7cdef 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1869,13 +1869,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) nested = EX(nested); - /* For generators the execute_data is stored on the heap, for everything - * else it is stored on the VM stack. */ - if (op_array->fn_flags & ZEND_ACC_GENERATOR) { - efree(execute_data); - } else { - zend_vm_stack_free(execute_data TSRMLS_CC); - } + zend_vm_stack_free(execute_data TSRMLS_CC); if (nested) { execute_data = EG(current_execute_data); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index f8a8905040008..bde11ead61a34 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -493,13 +493,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) nested = EX(nested); - /* For generators the execute_data is stored on the heap, for everything - * else it is stored on the VM stack. */ - if (op_array->fn_flags & ZEND_ACC_GENERATOR) { - efree(execute_data); - } else { - zend_vm_stack_free(execute_data TSRMLS_CC); - } + zend_vm_stack_free(execute_data TSRMLS_CC); if (nested) { execute_data = EG(current_execute_data); From 526db7db14f73c652a6b1a80149ede114ddd024c Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 16 Sep 2012 21:54:48 +0200 Subject: [PATCH 2084/2394] Replace code with zend_clean_and_cache_symbol_table() call I replaced other instances of this code with the function call, but missed this one. --- Zend/zend_execute_API.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index fb0c18b27cc3f..ddf86e8008436 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -964,15 +964,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS } if (!fci->symbol_table && EG(active_symbol_table)) { - if (EG(symtable_cache_ptr)>=EG(symtable_cache_limit)) { - zend_hash_destroy(EG(active_symbol_table)); - FREE_HASHTABLE(EG(active_symbol_table)); - } else { - /* clean before putting into the cache, since clean - could call dtors, which could use cached hash */ - zend_hash_clean(EG(active_symbol_table)); - *(++EG(symtable_cache_ptr)) = EG(active_symbol_table); - } + zend_clean_and_cache_symbol_table(EG(active_symbol_table) TSRMLS_CC); } EG(active_symbol_table) = calling_symbol_table; EG(active_op_array) = original_op_array; From a47c11a13d005afb1b9b8382eb8f34f8dd632039 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 16 Sep 2012 22:01:07 +0200 Subject: [PATCH 2085/2394] Fix two op_array -> function cast warnings --- Zend/zend_generators.c | 2 +- Zend/zend_vm_def.h | 2 +- Zend/zend_vm_execute.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 83025eacd161f..01b33a3a3cb2b 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -371,7 +371,7 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ if (op_array->fn_flags & ZEND_ACC_CLOSURE) { zend_op_array *op_array_copy = (zend_op_array*)emalloc(sizeof(zend_op_array)); *op_array_copy = *op_array; - function_add_ref(op_array_copy); + function_add_ref((zend_function *) op_array_copy); op_array = op_array_copy; } diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index be2021ab7cdef..e0fc1bfc5b826 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5340,7 +5340,7 @@ ZEND_VM_HANDLER(153, ZEND_DECLARE_LAMBDA_FUNCTION, CONST, UNUSED) zend_error_noreturn(E_ERROR, "Base lambda function for closure not found"); } - zend_create_closure(&EX_T(opline->result.var).tmp_var, op_array, EG(scope), EG(This) TSRMLS_CC); + zend_create_closure(&EX_T(opline->result.var).tmp_var, (zend_function *) op_array, EG(scope), EG(This) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index bde11ead61a34..b8dac02cbad16 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -6614,7 +6614,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER zend_error_noreturn(E_ERROR, "Base lambda function for closure not found"); } - zend_create_closure(&EX_T(opline->result.var).tmp_var, op_array, EG(scope), EG(This) TSRMLS_CC); + zend_create_closure(&EX_T(opline->result.var).tmp_var, (zend_function *) op_array, EG(scope), EG(This) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); From f163c70feae301ff259aca8eb0929f3a4b70a1c1 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sun, 16 Sep 2012 22:02:47 +0200 Subject: [PATCH 2086/2394] Add NEWS for generators --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index 1ee977974a58b..d54cc1c18ea4d 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,8 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Add generators and coroutines (https://wiki.php.net/rfc/generators). + (Nikita Popov) . Support list in foreach (https://wiki.php.net/rfc/foreachlist). (Laruence) . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) . Drop Windows XP and 2003 support. (Pierre) From e034a46bdc36fb82957f5e503fa730776dfbba11 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Mon, 17 Sep 2012 10:52:07 -0400 Subject: [PATCH 2087/2394] A bunch of naming convention fixes. No functionality changes --- ext/standard/password.c | 40 +++++++++++++++++++------------------ ext/standard/php_password.h | 8 ++++---- 2 files changed, 25 insertions(+), 23 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 0dd8fed645565..6c2a9af3aa3ae 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -38,7 +38,7 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ { REGISTER_LONG_CONSTANT("PASSWORD_DEFAULT", PHP_PASSWORD_DEFAULT, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT", PASSWORD_BCRYPT, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT", PHP_PASSWORD_BCRYPT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PASSWORD_BCRYPT_DEFAULT_COST", PHP_PASSWORD_BCRYPT_COST, CONST_CS | CONST_PERSISTENT); @@ -46,23 +46,24 @@ PHP_MINIT_FUNCTION(password) /* {{{ */ } /* }}} */ -static char* php_password_get_algo_name(const php_password_algos algo) +static char* php_password_get_algo_name(const php_password_algo algo) { switch (algo) { - case PASSWORD_BCRYPT: + case PHP_PASSWORD_BCRYPT: return "bcrypt"; + case PHP_PASSWORD_UNKNOWN: default: return "unknown"; } } -static php_password_algos php_password_determine_algo(const char *hash, const size_t len) +static php_password_algo php_password_determine_algo(const char *hash, const size_t len) { if (len > 3 && hash[0] == '$' && hash[1] == '2' && hash[2] == 'y' && len == 60) { - return PASSWORD_BCRYPT; + return PHP_PASSWORD_BCRYPT; } - return PASSWORD_UNKNOWN; + return PHP_PASSWORD_UNKNOWN; } static zend_bool php_password_salt_is_alphabet(const char *str, const size_t len) /* {{{ */ @@ -174,13 +175,13 @@ static int php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */ PHP_FUNCTION(password_get_info) { - php_password_algos algo; + php_password_algo algo; int hash_len; - char *hash, *algoName; + char *hash, *algo_name; zval *options; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &hash, &hash_len) == FAILURE) { - RETURN_NULL(); + return; } if (hash_len < 0 || (size_t) hash_len < 0) { @@ -192,17 +193,17 @@ PHP_FUNCTION(password_get_info) array_init(options); algo = php_password_determine_algo(hash, (size_t) hash_len); - algoName = php_password_get_algo_name(algo); + algo_name = php_password_get_algo_name(algo); switch (algo) { - case PASSWORD_BCRYPT: + case PHP_PASSWORD_BCRYPT: { long cost = PHP_PASSWORD_BCRYPT_COST; sscanf(hash, "$2y$%ld$", &cost); add_assoc_long(options, "cost", cost); } break; - case PASSWORD_UNKNOWN: + case PHP_PASSWORD_UNKNOWN: default: break; } @@ -210,21 +211,21 @@ PHP_FUNCTION(password_get_info) array_init(return_value); add_assoc_long(return_value, "algo", algo); - add_assoc_string(return_value, "algoName", algoName, 1); + add_assoc_string(return_value, "algoName", algo_name, 1); add_assoc_zval(return_value, "options", options); } PHP_FUNCTION(password_needs_rehash) { long new_algo = 0; - php_password_algos algo; + php_password_algo algo; int hash_len; char *hash; HashTable *options = 0; zval **option_buffer; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|H", &hash, &hash_len, &new_algo, &options) == FAILURE) { - RETURN_NULL(); + return; } if (hash_len < 0) { @@ -239,7 +240,7 @@ PHP_FUNCTION(password_needs_rehash) } switch (algo) { - case PASSWORD_BCRYPT: + case PHP_PASSWORD_BCRYPT: { int newCost = PHP_PASSWORD_BCRYPT_COST, cost = 0; @@ -255,7 +256,7 @@ PHP_FUNCTION(password_needs_rehash) } } break; - case PASSWORD_UNKNOWN: + case PHP_PASSWORD_UNKNOWN: default: break; } @@ -309,11 +310,11 @@ PHP_FUNCTION(password_hash) zval **option_buffer; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sl|H", &password, &password_len, &algo, &options) == FAILURE) { - RETURN_NULL(); + return; } switch (algo) { - case PASSWORD_BCRYPT: + case PHP_PASSWORD_BCRYPT: { long cost = PHP_PASSWORD_BCRYPT_COST; @@ -334,6 +335,7 @@ PHP_FUNCTION(password_hash) hash_format_len = 7; } break; + case PHP_PASSWORD_UNKNOWN: default: php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown password hashing algorithm: %ld", algo); RETURN_NULL(); diff --git a/ext/standard/php_password.h b/ext/standard/php_password.h index c812e2c492ae5..079f187703879 100644 --- a/ext/standard/php_password.h +++ b/ext/standard/php_password.h @@ -28,14 +28,14 @@ PHP_FUNCTION(password_get_info); PHP_MINIT_FUNCTION(password); -#define PHP_PASSWORD_DEFAULT PASSWORD_BCRYPT +#define PHP_PASSWORD_DEFAULT PHP_PASSWORD_BCRYPT #define PHP_PASSWORD_BCRYPT_COST 10 typedef enum { - PASSWORD_UNKNOWN, - PASSWORD_BCRYPT -} php_password_algos; + PHP_PASSWORD_UNKNOWN, + PHP_PASSWORD_BCRYPT +} php_password_algo; #endif From 44c2624f8c7d6bc00f46bc69c77791c2a334cc9a Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Mon, 17 Sep 2012 10:59:51 -0400 Subject: [PATCH 2088/2394] Fix ucwords error casing --- ext/standard/password.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 6c2a9af3aa3ae..8e9d8941b578c 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -185,7 +185,7 @@ PHP_FUNCTION(password_get_info) } if (hash_len < 0 || (size_t) hash_len < 0) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied Password Hash Too Long To Safely Identify"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied password hash too long to safely identify"); RETURN_FALSE; } @@ -229,7 +229,7 @@ PHP_FUNCTION(password_needs_rehash) } if (hash_len < 0) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied Password Hash Too Long To Safely Identify"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied password hash too long to safely identify"); RETURN_FALSE; } From 6fd5ba5c8d70ecbd80175a488160f57380d8afee Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Mon, 17 Sep 2012 11:10:59 -0400 Subject: [PATCH 2089/2394] Fix arg info for required params passed to needs_rehash --- ext/standard/basic_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index cf2266c31dd85..a30579e14352a 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -1863,7 +1863,7 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_password_get_info, 0, 0, 1) ZEND_ARG_INFO(0, hash) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_password_needs_rehash, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_password_needs_rehash, 0, 0, 2) ZEND_ARG_INFO(0, hash) ZEND_ARG_INFO(0, algo) ZEND_ARG_INFO(0, options) From 8bd79d180716fc521a3f5cae4bbfa96eb6397925 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Mon, 17 Sep 2012 11:43:47 -0400 Subject: [PATCH 2090/2394] Refactor slightly to enable cleaner readability --- ext/standard/password.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 8e9d8941b578c..e8762690bb5b6 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -242,16 +242,16 @@ PHP_FUNCTION(password_needs_rehash) switch (algo) { case PHP_PASSWORD_BCRYPT: { - int newCost = PHP_PASSWORD_BCRYPT_COST, cost = 0; + long new_cost = PHP_PASSWORD_BCRYPT_COST, cost = 0; - if (options && zend_symtable_find(options, "cost", 5, (void **) &option_buffer) == SUCCESS) { + if (options && zend_symtable_find(options, "cost", sizeof("cost"), (void **) &option_buffer) == SUCCESS) { convert_to_long_ex(option_buffer); - newCost = Z_LVAL_PP(option_buffer); + new_cost = Z_LVAL_PP(option_buffer); zval_ptr_dtor(option_buffer); } - sscanf(hash, "$2y$%d$", &cost); - if (cost != newCost) { + sscanf(hash, "$2y$%ld$", &cost); + if (cost != new_cost) { RETURN_TRUE; } } From fa5477d9d45f076f4b4a6c50252668e2a437230b Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Thu, 20 Sep 2012 14:24:55 -0400 Subject: [PATCH 2091/2394] Fix folding --- main/main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/main/main.c b/main/main.c index 5eb9947fe7a5c..3e31a8d0b734a 100644 --- a/main/main.c +++ b/main/main.c @@ -596,6 +596,7 @@ PHPAPI int php_get_module_initialized(void) { return module_initialized; } +/* }}} */ /* {{{ php_log_err */ From bf19838c874de166ea01de33a38b14cbaf8b3a76 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 20 Sep 2012 23:31:10 +0200 Subject: [PATCH 2092/2394] Do not disable RFC3678 multicast API on Windows The API is supported since Windows Vista and requires targeting Vista when compiling PHP. Pierre had asked to disable this by default, even when targeting Vista/Windows Server 2008. Since XP will not be supported anymore on php-next, any rationale for this option will not apply anymore. --- ext/sockets/multicast.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ext/sockets/multicast.h b/ext/sockets/multicast.h index 5619c9c7fb293..9470a39ca2561 100644 --- a/ext/sockets/multicast.h +++ b/ext/sockets/multicast.h @@ -18,9 +18,7 @@ /* $Id$ */ -#if defined(MCAST_JOIN_GROUP) && \ - (!defined(PHP_WIN32) || (_WIN32_WINNT >= 0x600 && SOCKETS_ENABLE_VISTA_API)) && \ - !defined(__APPLE__) +#if defined(MCAST_JOIN_GROUP) && !defined(__APPLE__) #define RFC3678_API 1 /* has block/unblock and source membership, in this case for both IPv4 and IPv6 */ #define HAS_MCAST_EXT 1 From 70713a27b69962126a8e75caf01c88db96a542e3 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sat, 22 Sep 2012 10:04:51 -0400 Subject: [PATCH 2093/2394] Add CURLOPT_READDATA which was removed by mistake I did a check and this is the only one which was removed by mistake. No other constants are available in 5.4 branch and not in master --- ext/curl/interface.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 523bc1c6a0df7..d9abece5fc0b3 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -638,6 +638,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_QUOTE); REGISTER_CURL_CONSTANT(CURLOPT_RANDOM_FILE); REGISTER_CURL_CONSTANT(CURLOPT_RANGE); + REGISTER_CURL_CONSTANT(CURLOPT_READDATA); REGISTER_CURL_CONSTANT(CURLOPT_READFUNCTION); REGISTER_CURL_CONSTANT(CURLOPT_REFERER); REGISTER_CURL_CONSTANT(CURLOPT_RESUME_FROM); From a31fa55b44bcb342c00e9ab2f4a851d054897a39 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 22 Sep 2012 19:12:21 +0200 Subject: [PATCH 2094/2394] Fixed bug #63132 EG(arg_types_stack) is now also backed up when generators are used. This allows the use of yield in nested method calls. This commit adds two new functions to the zend_ptr_stack API: zend_ptr_stack_push_from_memory zend_ptr_stack_pop_into_memory both taking the following arguments: zend_ptr_stack *stack, int count, void **pointers --- .../tests/generators/nested_method_calls.phpt | 39 +++++++++++++ Zend/zend_generators.c | 57 +++++++++++++++++++ Zend/zend_generators.h | 5 ++ Zend/zend_ptr_stack.c | 16 ++++++ Zend/zend_ptr_stack.h | 2 + 5 files changed, 119 insertions(+) create mode 100644 Zend/tests/generators/nested_method_calls.phpt diff --git a/Zend/tests/generators/nested_method_calls.phpt b/Zend/tests/generators/nested_method_calls.phpt new file mode 100644 index 0000000000000..98aee2e60b09d --- /dev/null +++ b/Zend/tests/generators/nested_method_calls.phpt @@ -0,0 +1,39 @@ +--TEST-- +Yield can be used in nested method calls +--FILE-- +foo($obj->foo(yield)); +} + +$g1 = gen(new A); +$g1->current(); + +$g2 = gen(new B); +$g2->current(); + +$g1->next(); + +$g3 = clone $g2; +unset($g2); +$g3->next(); + +?> +--EXPECT-- +Called A::foo +Called A::foo +Called B::foo +Called B::foo diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 01b33a3a3cb2b..fba62dd83aacf 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -132,6 +132,21 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio efree(generator->backed_up_stack); } + if (generator->backed_up_arg_types_stack) { + /* The arg types stack contains three elements per call: fbc, object + * and called_scope. Here we traverse the stack from top to bottom + * and dtor the object. */ + int i = generator->backed_up_arg_types_stack_count / 3; + while (i--) { + zval *object = (zval *) generator->backed_up_arg_types_stack[3*i + 1]; + if (object) { + zval_ptr_dtor(&object); + } + } + + efree(generator->backed_up_arg_types_stack); + } + /* We have added an additional stack frame in prev_execute_data, so we * have to free it. It also contains the arguments passed to the * generator (for func_get_args) so those have to be freed too. */ @@ -288,6 +303,25 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** } } + if (orig->backed_up_arg_types_stack) { + size_t stack_size = orig->backed_up_arg_types_stack_count * sizeof(void *); + + clone->backed_up_arg_types_stack = emalloc(stack_size); + memcpy(clone->backed_up_arg_types_stack, orig->backed_up_arg_types_stack, stack_size); + + /* We have to add refs to the objects in the arg types stack (the + * object is always the second element of a three-pack. */ + { + int i, stack_frames = clone->backed_up_arg_types_stack_count / 3; + for (i = 0; i < stack_frames; i++) { + zval *object = (zval *) clone->backed_up_arg_types_stack[3*i + 1]; + if (object) { + Z_ADDREF_P(object); + } + } + } + } + /* Update the send_target to use the temporary variable with the same * offset as the original generator, but in our temporary variable * memory segment. */ @@ -449,6 +483,7 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ zval *original_This = EG(This); zend_class_entry *original_scope = EG(scope); zend_class_entry *original_called_scope = EG(called_scope); + int original_arg_types_stack_count = EG(arg_types_stack).top; /* Remember the current stack position so we can back up pushed args */ generator->original_stack_top = zend_vm_stack_top(TSRMLS_C); @@ -461,6 +496,16 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ generator->backed_up_stack = NULL; } + if (generator->backed_up_arg_types_stack) { + zend_ptr_stack_push_from_memory( + &EG(arg_types_stack), + generator->backed_up_arg_types_stack_count, + generator->backed_up_arg_types_stack + ); + efree(generator->backed_up_arg_types_stack); + generator->backed_up_arg_types_stack = NULL; + } + /* We (mis)use the return_value_ptr_ptr to provide the generator object * to the executor, so YIELD will be able to set the yielded value */ EG(return_value_ptr_ptr) = (zval **) generator; @@ -506,6 +551,18 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ zend_vm_stack_free(generator->original_stack_top TSRMLS_CC); } + if (original_arg_types_stack_count != EG(arg_types_stack).top) { + generator->backed_up_arg_types_stack_count = + EG(arg_types_stack).top - original_arg_types_stack_count; + + generator->backed_up_arg_types_stack = emalloc(generator->backed_up_arg_types_stack_count * sizeof(void *)); + zend_ptr_stack_pop_into_memory( + &EG(arg_types_stack), + generator->backed_up_arg_types_stack_count, + generator->backed_up_arg_types_stack + ); + } + /* If an exception was thrown in the generator we have to internally * rethrow it in the parent scope. */ if (UNEXPECTED(EG(exception) != NULL)) { diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index e47b7ad885f8e..3dc3e6fecdd63 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -36,6 +36,11 @@ typedef struct _zend_generator { void *backed_up_stack; size_t backed_up_stack_size; + /* For method calls PHP also pushes various type information on a second + * stack, which also needs to be backed up. */ + void **backed_up_arg_types_stack; + int backed_up_arg_types_stack_count; + /* The original stack top before resuming the generator. This is required * for proper cleanup during exception handling. */ void **original_stack_top; diff --git a/Zend/zend_ptr_stack.c b/Zend/zend_ptr_stack.c index aefa91f73d2da..d178cc0184527 100644 --- a/Zend/zend_ptr_stack.c +++ b/Zend/zend_ptr_stack.c @@ -111,6 +111,22 @@ ZEND_API int zend_ptr_stack_num_elements(zend_ptr_stack *stack) return stack->top; } +ZEND_API void zend_ptr_stack_push_from_memory(zend_ptr_stack *stack, int count, void **pointers) +{ + ZEND_PTR_STACK_RESIZE_IF_NEEDED(stack, count); + + memcpy(stack->top_element, pointers, count * sizeof(void *)); + stack->top_element += count; + stack->top += count; +} + +ZEND_API void zend_ptr_stack_pop_into_memory(zend_ptr_stack *stack, int count, void **pointers) +{ + memcpy(pointers, stack->top_element - count, count * sizeof(void *)); + stack->top_element -= count; + stack->top -= count; +} + /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_ptr_stack.h b/Zend/zend_ptr_stack.h index 9f6fc13161a8b..fe93e93b5a86d 100644 --- a/Zend/zend_ptr_stack.h +++ b/Zend/zend_ptr_stack.h @@ -41,6 +41,8 @@ ZEND_API void zend_ptr_stack_destroy(zend_ptr_stack *stack); ZEND_API void zend_ptr_stack_apply(zend_ptr_stack *stack, void (*func)(void *)); ZEND_API void zend_ptr_stack_clean(zend_ptr_stack *stack, void (*func)(void *), zend_bool free_elements); ZEND_API int zend_ptr_stack_num_elements(zend_ptr_stack *stack); +ZEND_API void zend_ptr_stack_push_from_memory(zend_ptr_stack *stack, int count, void **pointers); +ZEND_API void zend_ptr_stack_pop_into_memory(zend_ptr_stack *stack, int count, void **pointers); END_EXTERN_C() #define ZEND_PTR_STACK_RESIZE_IF_NEEDED(stack, count) \ From 4954aba2edbc4e29b8b18837298016b435ff7968 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 22 Sep 2012 21:41:51 +0200 Subject: [PATCH 2095/2394] Revert error/exception handler changes This reverts the following two commits: * 6ba2e662e447f369c6e7686e8b39dde033fd5334 * d8f8e98d8e0493adf1fae622595bd3435bdbf835 Laruence already did some partial changes to set_error_handler and set_exception_handler. I'm reverting those modifications to apply the full set of changes. (The modifications changed the code structure in a way that would lead to more duplication with the new behavior.) --- Zend/tests/bug60738.phpt | 17 ------- Zend/zend_builtin_functions.c | 93 +++++++++++++++++------------------ 2 files changed, 45 insertions(+), 65 deletions(-) delete mode 100644 Zend/tests/bug60738.phpt diff --git a/Zend/tests/bug60738.phpt b/Zend/tests/bug60738.phpt deleted file mode 100644 index e0c9793fedf27..0000000000000 --- a/Zend/tests/bug60738.phpt +++ /dev/null @@ -1,17 +0,0 @@ ---TEST-- -Bug #60738 Allow 'set_error_handler' to handle NULL ---FILE-- - ---EXPECTF-- -Intercepted error! - -Notice: Error! in %s on line %d diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index f8d467478c7f5..eab98ed944e77 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1512,6 +1512,7 @@ ZEND_FUNCTION(trigger_error) ZEND_FUNCTION(set_error_handler) { zval *error_handler; + zend_bool had_orig_error_handler=0; char *error_handler_name = NULL; long error_type = E_ALL; @@ -1519,41 +1520,38 @@ ZEND_FUNCTION(set_error_handler) return; } - if (IS_NULL != Z_TYPE_P(error_handler)) { - zend_bool had_orig_error_handler = 0; - if (!zend_is_callable(error_handler, 0, &error_handler_name TSRMLS_CC)) { - zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback", - get_active_function_name(TSRMLS_C), error_handler_name?error_handler_name:"unknown"); - efree(error_handler_name); - return; - } + if (!zend_is_callable(error_handler, 0, &error_handler_name TSRMLS_CC)) { + zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback", + get_active_function_name(TSRMLS_C), error_handler_name?error_handler_name:"unknown"); efree(error_handler_name); + return; + } + efree(error_handler_name); - if (EG(user_error_handler)) { - had_orig_error_handler = 1; - *return_value = *EG(user_error_handler); - zval_copy_ctor(return_value); - INIT_PZVAL(return_value); - zend_stack_push(&EG(user_error_handlers_error_reporting), &EG(user_error_handler_error_reporting), sizeof(EG(user_error_handler_error_reporting))); - zend_ptr_stack_push(&EG(user_error_handlers), EG(user_error_handler)); - } - - ALLOC_ZVAL(EG(user_error_handler)); - EG(user_error_handler_error_reporting) = (int)error_type; - MAKE_COPY_ZVAL(&error_handler, EG(user_error_handler)); - - if (!had_orig_error_handler) { - RETURN_NULL(); - } - } else { /* unset user-defined handler */ - if (EG(user_error_handler)) { - zend_stack_push(&EG(user_error_handlers_error_reporting), &EG(user_error_handler_error_reporting), sizeof(EG(user_error_handler_error_reporting))); - zend_ptr_stack_push(&EG(user_error_handlers), EG(user_error_handler)); - } + if (EG(user_error_handler)) { + had_orig_error_handler = 1; + *return_value = *EG(user_error_handler); + zval_copy_ctor(return_value); + INIT_PZVAL(return_value); + zend_stack_push(&EG(user_error_handlers_error_reporting), &EG(user_error_handler_error_reporting), sizeof(EG(user_error_handler_error_reporting))); + zend_ptr_stack_push(&EG(user_error_handlers), EG(user_error_handler)); + } + ALLOC_ZVAL(EG(user_error_handler)); + if (!zend_is_true(error_handler)) { /* unset user-defined handler */ + FREE_ZVAL(EG(user_error_handler)); EG(user_error_handler) = NULL; RETURN_TRUE; } + + EG(user_error_handler_error_reporting) = (int)error_type; + *EG(user_error_handler) = *error_handler; + zval_copy_ctor(EG(user_error_handler)); + INIT_PZVAL(EG(user_error_handler)); + + if (!had_orig_error_handler) { + RETURN_NULL(); + } } /* }}} */ @@ -1587,42 +1585,41 @@ ZEND_FUNCTION(set_exception_handler) { zval *exception_handler; char *exception_handler_name = NULL; + zend_bool had_orig_exception_handler=0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z", &exception_handler) == FAILURE) { return; } if (Z_TYPE_P(exception_handler) != IS_NULL) { /* NULL == unset */ - zend_bool had_orig_exception_handler = 0; - if (!zend_is_callable(exception_handler, 0, &exception_handler_name TSRMLS_CC)) { zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback", - get_active_function_name(TSRMLS_C), exception_handler_name?exception_handler_name:"unknown"); + get_active_function_name(TSRMLS_C), exception_handler_name?exception_handler_name:"unknown"); efree(exception_handler_name); return; } efree(exception_handler_name); + } - if (EG(user_exception_handler)) { - had_orig_exception_handler = 1; - *return_value = *EG(user_exception_handler); - zval_copy_ctor(return_value); - zend_ptr_stack_push(&EG(user_exception_handlers), EG(user_exception_handler)); - } - - ALLOC_ZVAL(EG(user_exception_handler)); - MAKE_COPY_ZVAL(&exception_handler, EG(user_exception_handler)); + if (EG(user_exception_handler)) { + had_orig_exception_handler = 1; + *return_value = *EG(user_exception_handler); + zval_copy_ctor(return_value); + zend_ptr_stack_push(&EG(user_exception_handlers), EG(user_exception_handler)); + } + ALLOC_ZVAL(EG(user_exception_handler)); - if (!had_orig_exception_handler) { - RETURN_NULL(); - } - } else { - if (EG(user_exception_handler)) { - zend_ptr_stack_push(&EG(user_exception_handlers), EG(user_exception_handler)); - } + if (Z_TYPE_P(exception_handler) == IS_NULL) { /* unset user-defined handler */ + FREE_ZVAL(EG(user_exception_handler)); EG(user_exception_handler) = NULL; RETURN_TRUE; } + + MAKE_COPY_ZVAL(&exception_handler, EG(user_exception_handler)) + + if (!had_orig_exception_handler) { + RETURN_NULL(); + } } /* }}} */ From c815dd74bc42c8f36ba35b910f45e85a645d7e3d Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 24 Mar 2012 12:52:15 +0100 Subject: [PATCH 2096/2394] Allow resetting the error handler This allows the error handler to be reset using set_error_handler(null). As the code suggests this behavior was already previously intended, but the callback check was done too strictly. --- Zend/tests/bug60738.phpt | 17 +++++++++++++++++ Zend/zend_builtin_functions.c | 14 ++++++++------ 2 files changed, 25 insertions(+), 6 deletions(-) create mode 100644 Zend/tests/bug60738.phpt diff --git a/Zend/tests/bug60738.phpt b/Zend/tests/bug60738.phpt new file mode 100644 index 0000000000000..e0c9793fedf27 --- /dev/null +++ b/Zend/tests/bug60738.phpt @@ -0,0 +1,17 @@ +--TEST-- +Bug #60738 Allow 'set_error_handler' to handle NULL +--FILE-- + +--EXPECTF-- +Intercepted error! + +Notice: Error! in %s on line %d diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index eab98ed944e77..204c7d3d0b889 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1520,13 +1520,15 @@ ZEND_FUNCTION(set_error_handler) return; } - if (!zend_is_callable(error_handler, 0, &error_handler_name TSRMLS_CC)) { - zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback", - get_active_function_name(TSRMLS_C), error_handler_name?error_handler_name:"unknown"); + if (Z_TYPE_P(error_handler) != IS_NULL) { /* NULL == unset */ + if (!zend_is_callable(error_handler, 0, &error_handler_name TSRMLS_CC)) { + zend_error(E_WARNING, "%s() expects the argument (%s) to be a valid callback", + get_active_function_name(TSRMLS_C), error_handler_name?error_handler_name:"unknown"); + efree(error_handler_name); + return; + } efree(error_handler_name); - return; } - efree(error_handler_name); if (EG(user_error_handler)) { had_orig_error_handler = 1; @@ -1538,7 +1540,7 @@ ZEND_FUNCTION(set_error_handler) } ALLOC_ZVAL(EG(user_error_handler)); - if (!zend_is_true(error_handler)) { /* unset user-defined handler */ + if (Z_TYPE_P(error_handler) == IS_NULL) { /* unset user-defined handler */ FREE_ZVAL(EG(user_error_handler)); EG(user_error_handler) = NULL; RETURN_TRUE; From f28c128b207ae2c6ea4d8f6c2e66f5b709210a23 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 24 Mar 2012 13:10:51 +0100 Subject: [PATCH 2097/2394] Return previous error handler when resetting the error handler set_error_handler(null) and set_exception_handler(null) now return the previous error/exception handler instead of just returning bool(true). This is consistent with the behavior of these functions with non-null values. --- Zend/tests/bug60738.phpt | 9 +++++++-- Zend/tests/bug60738_variation.phpt | 23 +++++++++++++++++++++++ Zend/zend_builtin_functions.c | 4 ++-- 3 files changed, 32 insertions(+), 4 deletions(-) create mode 100644 Zend/tests/bug60738_variation.phpt diff --git a/Zend/tests/bug60738.phpt b/Zend/tests/bug60738.phpt index e0c9793fedf27..e4080715ec72a 100644 --- a/Zend/tests/bug60738.phpt +++ b/Zend/tests/bug60738.phpt @@ -3,15 +3,20 @@ Bug #60738 Allow 'set_error_handler' to handle NULL --FILE-- --EXPECTF-- +NULL Intercepted error! +object(Closure)#1 (0) { +} Notice: Error! in %s on line %d diff --git a/Zend/tests/bug60738_variation.phpt b/Zend/tests/bug60738_variation.phpt new file mode 100644 index 0000000000000..d7cf00ecdbc48 --- /dev/null +++ b/Zend/tests/bug60738_variation.phpt @@ -0,0 +1,23 @@ +--TEST-- +Bug #60738 Allow 'set_error_handler' to handle NULL +--FILE-- + +--EXPECTF-- +NULL +object(Closure)#1 (0) { +} + +Fatal error: Uncaught exception 'Exception' with message 'Exception!' in %s:%d +Stack trace: +#0 {main} + thrown in %s on line %d + diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 204c7d3d0b889..fdfe3db8f83b9 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1543,7 +1543,7 @@ ZEND_FUNCTION(set_error_handler) if (Z_TYPE_P(error_handler) == IS_NULL) { /* unset user-defined handler */ FREE_ZVAL(EG(user_error_handler)); EG(user_error_handler) = NULL; - RETURN_TRUE; + return; } EG(user_error_handler_error_reporting) = (int)error_type; @@ -1614,7 +1614,7 @@ ZEND_FUNCTION(set_exception_handler) if (Z_TYPE_P(exception_handler) == IS_NULL) { /* unset user-defined handler */ FREE_ZVAL(EG(user_exception_handler)); EG(user_exception_handler) = NULL; - RETURN_TRUE; + return; } MAKE_COPY_ZVAL(&exception_handler, EG(user_exception_handler)) From 5c7dd7811ef34c8cbe8bdad333678809f649d383 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 24 Mar 2012 13:48:11 +0100 Subject: [PATCH 2098/2394] Simplify set_error_handler/set_exception_handler code --- Zend/zend_builtin_functions.c | 31 +++++++------------------------ 1 file changed, 7 insertions(+), 24 deletions(-) diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index fdfe3db8f83b9..698ef72e544be 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -1512,7 +1512,6 @@ ZEND_FUNCTION(trigger_error) ZEND_FUNCTION(set_error_handler) { zval *error_handler; - zend_bool had_orig_error_handler=0; char *error_handler_name = NULL; long error_type = E_ALL; @@ -1531,29 +1530,20 @@ ZEND_FUNCTION(set_error_handler) } if (EG(user_error_handler)) { - had_orig_error_handler = 1; - *return_value = *EG(user_error_handler); - zval_copy_ctor(return_value); - INIT_PZVAL(return_value); + RETVAL_ZVAL(EG(user_error_handler), 1, 0); + zend_stack_push(&EG(user_error_handlers_error_reporting), &EG(user_error_handler_error_reporting), sizeof(EG(user_error_handler_error_reporting))); zend_ptr_stack_push(&EG(user_error_handlers), EG(user_error_handler)); } - ALLOC_ZVAL(EG(user_error_handler)); if (Z_TYPE_P(error_handler) == IS_NULL) { /* unset user-defined handler */ - FREE_ZVAL(EG(user_error_handler)); EG(user_error_handler) = NULL; return; } + ALLOC_ZVAL(EG(user_error_handler)); + MAKE_COPY_ZVAL(&error_handler, EG(user_error_handler)); EG(user_error_handler_error_reporting) = (int)error_type; - *EG(user_error_handler) = *error_handler; - zval_copy_ctor(EG(user_error_handler)); - INIT_PZVAL(EG(user_error_handler)); - - if (!had_orig_error_handler) { - RETURN_NULL(); - } } /* }}} */ @@ -1587,7 +1577,6 @@ ZEND_FUNCTION(set_exception_handler) { zval *exception_handler; char *exception_handler_name = NULL; - zend_bool had_orig_exception_handler=0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z", &exception_handler) == FAILURE) { return; @@ -1604,24 +1593,18 @@ ZEND_FUNCTION(set_exception_handler) } if (EG(user_exception_handler)) { - had_orig_exception_handler = 1; - *return_value = *EG(user_exception_handler); - zval_copy_ctor(return_value); + RETVAL_ZVAL(EG(user_exception_handler), 1, 0); + zend_ptr_stack_push(&EG(user_exception_handlers), EG(user_exception_handler)); } - ALLOC_ZVAL(EG(user_exception_handler)); if (Z_TYPE_P(exception_handler) == IS_NULL) { /* unset user-defined handler */ - FREE_ZVAL(EG(user_exception_handler)); EG(user_exception_handler) = NULL; return; } + ALLOC_ZVAL(EG(user_exception_handler)); MAKE_COPY_ZVAL(&exception_handler, EG(user_exception_handler)) - - if (!had_orig_exception_handler) { - RETURN_NULL(); - } } /* }}} */ From 5de79f9f0717d147b02033e270bea20561707db8 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 22 Sep 2012 21:54:59 +0200 Subject: [PATCH 2099/2394] Add NEWS/UPGRADING for previous change --- NEWS | 2 ++ UPGRADING | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/NEWS b/NEWS index d54cc1c18ea4d..00a2dd67ead3d 100644 --- a/NEWS +++ b/NEWS @@ -26,6 +26,8 @@ PHP NEWS (srgoogleguy, Gustavo) . Implemented FR #60738 (Allow 'set_error_handler' to handle NULL). (Laruence, Nikita Popov) + . Return previous handler when passing NULL to set_error_handler and + set_exception_handler. (Nikita Popov) . Added optional second argument for assert() to specify custom message. Patch by Lonny Kapelushnik (lonny@lonnylot.com). (Lars) diff --git a/UPGRADING b/UPGRADING index 59dfbb436acd2..bc5773cfa89f8 100755 --- a/UPGRADING +++ b/UPGRADING @@ -107,6 +107,10 @@ PHP X.Y UPGRADE NOTES but that predated the existence of E_DEPRECATED. - php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and zend_logo_guid() have been removed +- set_error_handler(NULL) can now be used to reset the error handler. + Furthermore both set_error_handler(NULL) and set_exception_handler(NULL) will + now return the previously defined error/exception handler. Previously + bool(true) was returned. ======================================== 5. New Functions From 571b46bff68925f15f578147278b43c6f88083f0 Mon Sep 17 00:00:00 2001 From: andrey Date: Tue, 25 Sep 2012 14:04:36 +0200 Subject: [PATCH 2100/2394] Add SHA256 authentication support - password hashing to mysqlnd Automatic switchover to SSL with plain-text password is not part of this --- ext/mysqli/mysqli_nonapi.c | 2 +- ext/mysqlnd/config9.m4 | 12 +- ext/mysqlnd/mysqlnd.c | 11 +- ext/mysqlnd/mysqlnd.h | 1 + ext/mysqlnd/mysqlnd_auth.c | 188 ++++++++++++++++++++++++++++- ext/mysqlnd/mysqlnd_enum_n_def.h | 3 + ext/mysqlnd/mysqlnd_structs.h | 18 ++- ext/mysqlnd/mysqlnd_wireprotocol.c | 134 +++++++++++++++++++- ext/mysqlnd/mysqlnd_wireprotocol.h | 12 ++ ext/mysqlnd/php_mysqlnd.c | 10 +- 10 files changed, 374 insertions(+), 17 deletions(-) diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index 5e9c01378a2a1..2b6a1af0edfd0 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -728,7 +728,7 @@ static int mysqlnd_dont_poll_zval_array_from_mysqlnd_array(MYSQLND **in_array, z int ret = 0; ALLOC_HASHTABLE(new_hash); - zend_hash_init(new_hash, zend_hash_num_elements(Z_ARRVAL_P(in_zval_array)), NULL, ZVAL_PTR_DTOR, 0); + zend_hash_init(new_hash, in_zval_array? zend_hash_num_elements(Z_ARRVAL_P(in_zval_array)):0, NULL, ZVAL_PTR_DTOR, 0); if (in_array) { for (zend_hash_internal_pointer_reset(Z_ARRVAL_P(in_zval_array)); zend_hash_get_current_data(Z_ARRVAL_P(in_zval_array), (void **) &elem) == SUCCESS; diff --git a/ext/mysqlnd/config9.m4 b/ext/mysqlnd/config9.m4 index 2c15c34e8d39c..3fc767b231d68 100644 --- a/ext/mysqlnd/config9.m4 +++ b/ext/mysqlnd/config9.m4 @@ -28,7 +28,17 @@ if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes"; then if test "$PHP_MYSQLND_COMPRESSION_SUPPORT" != "no"; then AC_DEFINE([MYSQLND_COMPRESSION_WANTED], 1, [Enable compressed protocol support]) fi - AC_DEFINE([MYSQLND_SSL_SUPPORTED], 1, [Enable SSL support]) + + AC_DEFINE([MYSQLND_SSL_SUPPORTED], 1, [Enable core mysqlnd SSL code]) + + test -z "$PHP_OPENSSL" && PHP_OPENSSL=no + + if test "$PHP_OPENSSL" != "no" || test "$PHP_OPENSSL_DIR" != "no"; then + AC_CHECK_LIB(ssl, DSA_get_default_method, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later])) + AC_CHECK_LIB(crypto, X509_free, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later])) + + PHP_SETUP_OPENSSL(MYSQLND_SHARED_LIBADD, [AC_DEFINE(MYSQLND_HAVE_SSL,1,[Enable mysqlnd code that uses OpenSSL directly])]) + fi mysqlnd_sources="$mysqlnd_base_sources $mysqlnd_ps_sources" PHP_NEW_EXTENSION(mysqlnd, $mysqlnd_sources, $ext_shared) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index d7462f77a54b6..f7f3245a2c42d 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -581,12 +581,14 @@ mysqlnd_run_authentication( } memcpy(conn->auth_plugin_data, plugin_data, plugin_data_len); - DBG_INF_FMT("salt=[%*.s]", plugin_data_len - 1, plugin_data); + DBG_INF_FMT("salt(%d)=[%.*s]", plugin_data_len, plugin_data_len, plugin_data); /* The data should be allocated with malloc() */ scrambled_data = auth_plugin->methods.get_auth_data(NULL, &scrambled_data_len, conn, user, passwd, passwd_len, - plugin_data, plugin_data_len, options, mysql_flags TSRMLS_CC); - + plugin_data, plugin_data_len, options, &conn->net->data->options, mysql_flags TSRMLS_CC); + if (!scrambled_data || conn->error_info->error_no) { + goto end; + } if (FALSE == is_change_user) { ret = mysqlnd_auth_handshake(conn, user, passwd, passwd_len, db, db_len, options, mysql_flags, charset_no, @@ -1334,13 +1336,12 @@ _mysqlnd_poll(MYSQLND **r_array, MYSQLND **e_array, MYSQLND ***dont_poll, long s DBG_RETURN(FAIL); } - *dont_poll = mysqlnd_stream_array_check_for_readiness(r_array TSRMLS_CC); - FD_ZERO(&rfds); FD_ZERO(&wfds); FD_ZERO(&efds); if (r_array != NULL) { + *dont_poll = mysqlnd_stream_array_check_for_readiness(r_array TSRMLS_CC); set_count = mysqlnd_stream_array_to_fd_set(r_array, &rfds, &max_fd TSRMLS_CC); if (set_count > max_set_count) { max_set_count = set_count; diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index 30d425780236e..b0db48f5f71b4 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -277,6 +277,7 @@ ZEND_BEGIN_MODULE_GLOBALS(mysqlnd) long debug_malloc_fail_threshold; long debug_calloc_fail_threshold; long debug_realloc_fail_threshold; + char * sha256_server_public_key; ZEND_END_MODULE_GLOBALS(mysqlnd) PHPAPI ZEND_EXTERN_MODULE_GLOBALS(mysqlnd) diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index 10c932a9683c3..295b6a338bb28 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -360,7 +360,9 @@ mysqlnd_native_auth_get_auth_data(struct st_mysqlnd_authentication_plugin * self size_t * auth_data_len, MYSQLND_CONN_DATA * conn, const char * const user, const char * const passwd, const size_t passwd_len, zend_uchar * auth_plugin_data, size_t auth_plugin_data_len, - const MYSQLND_OPTIONS * const options, unsigned long mysql_flags + const MYSQLND_OPTIONS * const options, + const MYSQLND_NET_OPTIONS * const net_options, + unsigned long mysql_flags TSRMLS_DC) { zend_uchar * ret = NULL; @@ -418,7 +420,9 @@ mysqlnd_pam_auth_get_auth_data(struct st_mysqlnd_authentication_plugin * self, size_t * auth_data_len, MYSQLND_CONN_DATA * conn, const char * const user, const char * const passwd, const size_t passwd_len, zend_uchar * auth_plugin_data, size_t auth_plugin_data_len, - const MYSQLND_OPTIONS * const options, unsigned long mysql_flags + const MYSQLND_OPTIONS * const options, + const MYSQLND_NET_OPTIONS * const net_options, + unsigned long mysql_flags TSRMLS_DC) { zend_uchar * ret = NULL; @@ -442,7 +446,7 @@ static struct st_mysqlnd_authentication_plugin mysqlnd_pam_authentication_plugin MYSQLND_VERSION_ID, MYSQLND_VERSION, "PHP License 3.01", - "Andrey Hristov , Ulf Wendel , Georg Richter ", + "Andrey Hristov , Ulf Wendel , Georg Richter ", { NULL, /* no statistics , will be filled later if there are some */ NULL, /* no statistics */ @@ -457,12 +461,190 @@ static struct st_mysqlnd_authentication_plugin mysqlnd_pam_authentication_plugin }; +/******************************************* SHA256 Password ***********************************/ +#ifdef MYSQLND_HAVE_SSL +static void +mysqlnd_xor_string(char * dst, const size_t dst_len, const char * xor_str, const size_t xor_str_len) +{ + unsigned int i; + for (i = 0; i <= dst_len; ++i) { + dst[i] ^= xor_str[i % xor_str_len]; + } +} + + +#include +#include +#include + + +/* {{{ mysqlnd_sha256_get_rsa_key */ +static RSA * +mysqlnd_sha256_get_rsa_key(MYSQLND_CONN_DATA * conn, + const MYSQLND_OPTIONS * const options, + const MYSQLND_NET_OPTIONS * const net_options + TSRMLS_DC) +{ + RSA * ret = NULL; + int len; + const char * fname = (net_options->sha256_server_public_key && net_options->sha256_server_public_key[0] != '\0')? + net_options->sha256_server_public_key: + MYSQLND_G(sha256_server_public_key); + php_stream * stream; + DBG_ENTER("mysqlnd_sha256_get_rsa_key"); + + if (!fname || fname[0] == '\0') { + MYSQLND_PACKET_SHA256_PK_REQUEST * pk_req_packet = NULL; + MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE * pk_resp_packet = NULL; + + do { + DBG_INF("requesting the public key from the server"); + pk_req_packet = conn->protocol->m.get_sha256_pk_request_packet(conn->protocol, FALSE TSRMLS_CC); + if (!pk_req_packet) { + SET_OOM_ERROR(*conn->error_info); + break; + } + pk_resp_packet = conn->protocol->m.get_sha256_pk_request_response_packet(conn->protocol, FALSE TSRMLS_CC); + if (!pk_resp_packet) { + SET_OOM_ERROR(*conn->error_info); + PACKET_FREE(pk_req_packet); + break; + } + + if (! PACKET_WRITE(pk_req_packet, conn)) { + DBG_ERR_FMT("Error while sending public key request packet"); + php_error(E_WARNING, "Error while sending public key request packet. PID=%d", getpid()); + CONN_SET_STATE(conn, CONN_QUIT_SENT); + break; + } + if (FAIL == PACKET_READ(pk_resp_packet, conn) || NULL == pk_resp_packet->public_key) { + DBG_ERR_FMT("Error while receiving public key"); + php_error(E_WARNING, "Error while receiving public key. PID=%d", getpid()); + CONN_SET_STATE(conn, CONN_QUIT_SENT); + break; + } + DBG_INF_FMT("Public key(%d):\n%s", pk_resp_packet->public_key_len, pk_resp_packet->public_key); + /* now extract the public key */ + { + BIO * bio = BIO_new_mem_buf(pk_resp_packet->public_key, pk_resp_packet->public_key_len); + ret = PEM_read_bio_RSA_PUBKEY(bio, NULL, NULL, NULL); + BIO_free(bio); + } + } while (0); + PACKET_FREE(pk_req_packet); + PACKET_FREE(pk_resp_packet); + + DBG_INF_FMT("ret=%p", ret); + DBG_RETURN(ret); + + SET_CLIENT_ERROR(*conn->error_info, CR_UNKNOWN_ERROR, UNKNOWN_SQLSTATE, + "sha256_server_public_key is not set for the connection or as mysqlnd.sha256_server_public_key"); + DBG_ERR("server_public_key is not set"); + DBG_RETURN(NULL); + } else { + char * key_str = NULL; + stream = php_stream_open_wrapper((char *) fname, "rb", REPORT_ERRORS, NULL); + + if (stream) { + if ((len = php_stream_copy_to_mem(stream, &key_str, PHP_STREAM_COPY_ALL, 0)) >= 0 ) { + BIO * bio = BIO_new_mem_buf(key_str, len); + ret = PEM_read_bio_RSA_PUBKEY(bio, NULL, NULL, NULL); + BIO_free(bio); + } + if (key_str) { + DBG_INF_FMT("Public key:%*.s", len, key_str); + efree(key_str); + } + } + php_stream_free(stream, PHP_STREAM_FREE_CLOSE); + } + DBG_RETURN(ret) +} +/* }}} */ + + +/* {{{ mysqlnd_sha256_auth_get_auth_data */ +static zend_uchar * +mysqlnd_sha256_auth_get_auth_data(struct st_mysqlnd_authentication_plugin * self, + size_t * auth_data_len, + MYSQLND_CONN_DATA * conn, const char * const user, const char * const passwd, + const size_t passwd_len, zend_uchar * auth_plugin_data, size_t auth_plugin_data_len, + const MYSQLND_OPTIONS * const options, + const MYSQLND_NET_OPTIONS * const net_options, + unsigned long mysql_flags + TSRMLS_DC) +{ + RSA * server_public_key; + zend_uchar * ret = NULL; + DBG_ENTER("mysqlnd_sha256_auth_get_auth_data"); + DBG_INF_FMT("salt(%d)=[%.*s]", auth_plugin_data_len, auth_plugin_data_len, auth_plugin_data); + + *auth_data_len = 0; + + server_public_key = mysqlnd_sha256_get_rsa_key(conn, options, net_options TSRMLS_CC); + + if (server_public_key) { + int server_public_key_len; + char xor_str[passwd_len + 1]; + memcpy(xor_str, passwd, passwd_len); + xor_str[passwd_len] = '\0'; + mysqlnd_xor_string(xor_str, passwd_len, (char *) auth_plugin_data, auth_plugin_data_len); + + server_public_key_len = RSA_size(server_public_key); + /* + Because RSA_PKCS1_OAEP_PADDING is used there is a restriction on the passwd_len. + RSA_PKCS1_OAEP_PADDING is recommended for new applications. See more here: + http://www.openssl.org/docs/crypto/RSA_public_encrypt.html + */ + if ((size_t) server_public_key_len - 41 <= passwd_len) { + /* password message is to long */ + SET_CLIENT_ERROR(*conn->error_info, CR_UNKNOWN_ERROR, UNKNOWN_SQLSTATE, "password is too long"); + DBG_ERR("password is too long"); + DBG_RETURN(NULL); + } + + *auth_data_len = server_public_key_len; + ret = malloc(*auth_data_len); + RSA_public_encrypt(passwd_len + 1, (zend_uchar *) xor_str, ret, server_public_key, RSA_PKCS1_OAEP_PADDING); + } + + DBG_RETURN(ret); +} +/* }}} */ + + +static struct st_mysqlnd_authentication_plugin mysqlnd_sha256_authentication_plugin = +{ + { + MYSQLND_PLUGIN_API_VERSION, + "auth_plugin_sha256_password", + MYSQLND_VERSION_ID, + MYSQLND_VERSION, + "PHP License 3.01", + "Andrey Hristov , Ulf Wendel ", + { + NULL, /* no statistics , will be filled later if there are some */ + NULL, /* no statistics */ + }, + { + NULL /* plugin shutdown */ + } + }, + {/* methods */ + mysqlnd_sha256_auth_get_auth_data + } +}; +#endif + /* {{{ mysqlnd_register_builtin_authentication_plugins */ void mysqlnd_register_builtin_authentication_plugins(TSRMLS_D) { mysqlnd_plugin_register_ex((struct st_mysqlnd_plugin_header *) &mysqlnd_native_auth_plugin TSRMLS_CC); mysqlnd_plugin_register_ex((struct st_mysqlnd_plugin_header *) &mysqlnd_pam_authentication_plugin TSRMLS_CC); +#ifdef MYSQLND_HAVE_SSL + mysqlnd_plugin_register_ex((struct st_mysqlnd_plugin_header *) &mysqlnd_sha256_authentication_plugin TSRMLS_CC); +#endif } /* }}} */ diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h index c8daa0c79bf58..60e53b3c60b4d 100644 --- a/ext/mysqlnd/mysqlnd_enum_n_def.h +++ b/ext/mysqlnd/mysqlnd_enum_n_def.h @@ -166,6 +166,7 @@ typedef enum mysqlnd_option MYSQL_OPT_SSL_VERIFY_SERVER_CERT, MYSQL_PLUGIN_DIR, MYSQL_DEFAULT_AUTH, + MYSQL_SERVER_PUBLIC_KEY, #if MYSQLND_UNICODE MYSQLND_OPT_NUMERIC_AND_DATETIME_AS_UNICODE = 200, #endif @@ -537,6 +538,8 @@ enum mysqlnd_packet_type PROT_STATS_PACKET, PROT_PREPARE_RESP_PACKET, PROT_CHG_USER_RESP_PACKET, + PROT_SHA256_PK_REQUEST_PACKET, + PROT_SHA256_PK_REQUEST_RESPONSE_PACKET, PROT_LAST /* should always be last */ }; diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 856ebd2ead9aa..511a168b56497 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -207,6 +207,13 @@ typedef struct st_mysqlnd_net_options char *ssl_passphrase; zend_bool ssl_verify_peer; uint64_t flags; + + char * sha256_server_public_key; + + char * unused1; + char * unused2; + char * unused3; + char * unused4; } MYSQLND_NET_OPTIONS; @@ -341,6 +348,8 @@ struct st_mysqlnd_packet_stats; struct st_mysqlnd_packet_prepare_response; struct st_mysqlnd_packet_chg_user_resp; struct st_mysqlnd_packet_auth_pam; +struct st_mysqlnd_packet_sha256_pk_request; +struct st_mysqlnd_packet_sha256_pk_request_response; typedef struct st_mysqlnd_packet_greet * (*func_mysqlnd_protocol__get_greet_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); typedef struct st_mysqlnd_packet_auth * (*func_mysqlnd_protocol__get_auth_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); @@ -355,6 +364,8 @@ typedef struct st_mysqlnd_packet_row * (*func_mysqlnd_protocol__get_row_packet typedef struct st_mysqlnd_packet_stats * (*func_mysqlnd_protocol__get_stats_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); typedef struct st_mysqlnd_packet_prepare_response *(*func_mysqlnd_protocol__get_prepare_response_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); typedef struct st_mysqlnd_packet_chg_user_resp*(*func_mysqlnd_protocol__get_change_user_response_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); +typedef struct st_mysqlnd_packet_sha256_pk_request *(*func_mysqlnd_protocol__get_sha256_pk_request_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); +typedef struct st_mysqlnd_packet_sha256_pk_request_response *(*func_mysqlnd_protocol__get_sha256_pk_request_response_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC); struct st_mysqlnd_protocol_methods { @@ -371,12 +382,12 @@ struct st_mysqlnd_protocol_methods func_mysqlnd_protocol__get_stats_packet get_stats_packet; func_mysqlnd_protocol__get_prepare_response_packet get_prepare_response_packet; func_mysqlnd_protocol__get_change_user_response_packet get_change_user_response_packet; + func_mysqlnd_protocol__get_sha256_pk_request_packet get_sha256_pk_request_packet; + func_mysqlnd_protocol__get_sha256_pk_request_response_packet get_sha256_pk_request_response_packet; void * unused1; void * unused2; void * unused3; - void * unused4; - void * unused5; }; @@ -1098,7 +1109,8 @@ typedef zend_uchar * (*func_auth_plugin__get_auth_data)(struct st_mysqlnd_authen size_t * auth_data_len, MYSQLND_CONN_DATA * conn, const char * const user, const char * const passwd, const size_t passwd_len, zend_uchar * auth_plugin_data, size_t auth_plugin_data_len, - const MYSQLND_OPTIONS * const options, unsigned long mysql_flags + const MYSQLND_OPTIONS * const options, + const MYSQLND_NET_OPTIONS * const net_options, unsigned long mysql_flags TSRMLS_DC); struct st_mysqlnd_authentication_plugin diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c index 3551c027cdf9e..e41c771a8a089 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.c +++ b/ext/mysqlnd/mysqlnd_wireprotocol.c @@ -623,7 +623,7 @@ php_mysqlnd_auth_response_read(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_D memcpy(packet->new_auth_protocol_data, p, packet->new_auth_protocol_data_len); } DBG_INF_FMT("The server requested switching auth plugin to : %s", packet->new_auth_protocol); - DBG_INF_FMT("Server salt : [%*s]", packet->new_auth_protocol_data_len, packet->new_auth_protocol_data); + DBG_INF_FMT("Server salt : [%d][%.*s]", packet->new_auth_protocol_data_len, packet->new_auth_protocol_data_len, packet->new_auth_protocol_data); } } else { /* Everything was fine! */ @@ -2078,6 +2078,89 @@ php_mysqlnd_chg_user_free_mem(void * _packet, zend_bool stack_allocation TSRMLS_ /* }}} */ +/* {{{ php_mysqlnd_sha256_pk_request_write */ +static +size_t php_mysqlnd_sha256_pk_request_write(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC) +{ + zend_uchar buffer[MYSQLND_HEADER_SIZE + 1]; + size_t sent; + + DBG_ENTER("php_mysqlnd_sha256_pk_request_write"); + + int1store(buffer + MYSQLND_HEADER_SIZE, '\1'); + sent = conn->net->data->m.send_ex(conn->net, buffer, 1, conn->stats, conn->error_info TSRMLS_CC); + + DBG_RETURN(sent); +} +/* }}} */ + + +/* {{{ php_mysqlnd_sha256_pk_request_free_mem */ +static +void php_mysqlnd_sha256_pk_request_free_mem(void * _packet, zend_bool stack_allocation TSRMLS_DC) +{ + if (!stack_allocation) { + MYSQLND_PACKET_SHA256_PK_REQUEST * p = (MYSQLND_PACKET_SHA256_PK_REQUEST *) _packet; + mnd_pefree(p, p->header.persistent); + } +} +/* }}} */ + + +#define SHA256_PK_REQUEST_RESP_BUFFER_SIZE 2048 + +/* {{{ php_mysqlnd_sha256_pk_request_response_read */ +static enum_func_status +php_mysqlnd_sha256_pk_request_response_read(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC) +{ + zend_uchar buf[SHA256_PK_REQUEST_RESP_BUFFER_SIZE]; + zend_uchar *p = buf; + zend_uchar *begin = buf; + MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE * packet= (MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE *) _packet; + + DBG_ENTER("php_mysqlnd_sha256_pk_request_response_read"); + + /* leave space for terminating safety \0 */ + PACKET_READ_HEADER_AND_BODY(packet, conn, buf, sizeof(buf), "SHA256_PK_REQUEST_RESPONSE", PROT_SHA256_PK_REQUEST_RESPONSE_PACKET); + BAIL_IF_NO_MORE_DATA; + + p++; + BAIL_IF_NO_MORE_DATA; + + packet->public_key_len = packet->header.size - (p - buf); + packet->public_key = mnd_emalloc(packet->public_key_len + 1); + memcpy(packet->public_key, p, packet->public_key_len); + packet->public_key[packet->public_key_len] = '\0'; + + DBG_RETURN(PASS); + +premature_end: + DBG_ERR_FMT("OK packet %d bytes shorter than expected", p - begin - packet->header.size); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "SHA256_PK_REQUEST_RESPONSE packet "MYSQLND_SZ_T_SPEC" bytes shorter than expected", + p - begin - packet->header.size); + DBG_RETURN(FAIL); +} +/* }}} */ + + +/* {{{ php_mysqlnd_sha256_pk_request_response_free_mem */ +static void +php_mysqlnd_sha256_pk_request_response_free_mem(void * _packet, zend_bool stack_allocation TSRMLS_DC) +{ + MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE * p = (MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE *) _packet; + if (p->public_key) { + mnd_efree(p->public_key); + p->public_key = NULL; + } + p->public_key_len = 0; + + if (!stack_allocation) { + mnd_pefree(p, p->header.persistent); + } +} +/* }}} */ + + /* {{{ packet_methods */ static mysqlnd_packet_methods packet_methods[PROT_LAST] = @@ -2159,7 +2242,19 @@ mysqlnd_packet_methods packet_methods[PROT_LAST] = php_mysqlnd_chg_user_read, /* read */ NULL, /* write */ php_mysqlnd_chg_user_free_mem, - } /* PROT_CHG_USER_RESP_PACKET */ + }, /* PROT_CHG_USER_RESP_PACKET */ + { + sizeof(MYSQLND_PACKET_SHA256_PK_REQUEST), + NULL, /* read */ + php_mysqlnd_sha256_pk_request_write, + php_mysqlnd_sha256_pk_request_free_mem, + }, /* PROT_SHA256_PK_REQUEST_PACKET */ + { + sizeof(MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE), + php_mysqlnd_sha256_pk_request_response_read, + NULL, /* write */ + php_mysqlnd_sha256_pk_request_response_free_mem, + } /* PROT_SHA256_PK_REQUEST_RESPONSE_PACKET */ }; /* }}} */ @@ -2359,6 +2454,37 @@ MYSQLND_METHOD(mysqlnd_protocol, get_change_user_response_packet)(MYSQLND_PROTOC /* }}} */ +/* {{{ mysqlnd_protocol::get_sha256_pk_request_packet */ +static struct st_mysqlnd_packet_sha256_pk_request * +MYSQLND_METHOD(mysqlnd_protocol, get_sha256_pk_request_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC) +{ + struct st_mysqlnd_packet_sha256_pk_request * packet = mnd_pecalloc(1, packet_methods[PROT_SHA256_PK_REQUEST_PACKET].struct_size, persistent); + DBG_ENTER("mysqlnd_protocol::get_sha256_pk_request_packet"); + if (packet) { + packet->header.m = &packet_methods[PROT_SHA256_PK_REQUEST_PACKET]; + packet->header.persistent = persistent; + } + DBG_RETURN(packet); +} +/* }}} */ + + +/* {{{ mysqlnd_protocol::get_sha256_pk_request_response_packet */ +static struct st_mysqlnd_packet_sha256_pk_request_response * +MYSQLND_METHOD(mysqlnd_protocol, get_sha256_pk_request_response_packet)(MYSQLND_PROTOCOL * const protocol, zend_bool persistent TSRMLS_DC) +{ + struct st_mysqlnd_packet_sha256_pk_request_response * packet = mnd_pecalloc(1, packet_methods[PROT_SHA256_PK_REQUEST_RESPONSE_PACKET].struct_size, persistent); + DBG_ENTER("mysqlnd_protocol::get_sha256_pk_request_response_packet"); + if (packet) { + packet->header.m = &packet_methods[PROT_SHA256_PK_REQUEST_RESPONSE_PACKET]; + packet->header.persistent = persistent; + } + DBG_RETURN(packet); +} +/* }}} */ + + + MYSQLND_CLASS_METHODS_START(mysqlnd_protocol) MYSQLND_METHOD(mysqlnd_protocol, get_greet_packet), MYSQLND_METHOD(mysqlnd_protocol, get_auth_packet), @@ -2372,7 +2498,9 @@ MYSQLND_CLASS_METHODS_START(mysqlnd_protocol) MYSQLND_METHOD(mysqlnd_protocol, get_row_packet), MYSQLND_METHOD(mysqlnd_protocol, get_stats_packet), MYSQLND_METHOD(mysqlnd_protocol, get_prepare_response_packet), - MYSQLND_METHOD(mysqlnd_protocol, get_change_user_response_packet) + MYSQLND_METHOD(mysqlnd_protocol, get_change_user_response_packet), + MYSQLND_METHOD(mysqlnd_protocol, get_sha256_pk_request_packet), + MYSQLND_METHOD(mysqlnd_protocol, get_sha256_pk_request_response_packet) MYSQLND_CLASS_METHODS_END; diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.h b/ext/mysqlnd/mysqlnd_wireprotocol.h index 96322d706026a..e5008e6db559c 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.h +++ b/ext/mysqlnd/mysqlnd_wireprotocol.h @@ -286,6 +286,18 @@ typedef struct st_mysqlnd_packet_chg_user_resp { } MYSQLND_PACKET_CHG_USER_RESPONSE; +/* Command packet */ +typedef struct st_mysqlnd_packet_sha256_pk_request { + MYSQLND_PACKET_HEADER header; +} MYSQLND_PACKET_SHA256_PK_REQUEST; + +typedef struct st_mysqlnd_packet_sha256_pk_request_response { + MYSQLND_PACKET_HEADER header; + zend_uchar *public_key; + size_t public_key_len; +} MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE; + + PHPAPI void php_mysqlnd_scramble(zend_uchar * const buffer, const zend_uchar * const scramble, const zend_uchar * const pass, size_t pass_len); unsigned long php_mysqlnd_net_field_length(zend_uchar **packet); diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index 0a8fd609086c2..8dccf37c4b3cd 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -170,11 +170,17 @@ PHP_MINFO_FUNCTION(mysqlnd) #else "not supported"); #endif - php_info_print_table_row(2, "SSL", + php_info_print_table_row(2, "core SSL", #ifdef MYSQLND_SSL_SUPPORTED "supported"); #else "not supported"); +#endif + php_info_print_table_row(2, "extended SSL", +#ifdef MYSQLND_HAVE_SSL + "supported"); +#else + "not supported"); #endif snprintf(buf, sizeof(buf), "%ld", MYSQLND_G(net_cmd_buffer_size)); php_info_print_table_row(2, "Command buffer size", buf); @@ -234,6 +240,7 @@ static PHP_GINIT_FUNCTION(mysqlnd) mysqlnd_globals->debug_malloc_fail_threshold = -1; mysqlnd_globals->debug_calloc_fail_threshold = -1; mysqlnd_globals->debug_realloc_fail_threshold = -1; + mysqlnd_globals->sha256_server_public_key = NULL; } /* }}} */ @@ -261,6 +268,7 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("mysqlnd.net_read_timeout", "31536000", PHP_INI_SYSTEM, OnUpdateLong, net_read_timeout, zend_mysqlnd_globals, mysqlnd_globals) STD_PHP_INI_ENTRY("mysqlnd.log_mask", "0", PHP_INI_ALL, OnUpdateLong, log_mask, zend_mysqlnd_globals, mysqlnd_globals) STD_PHP_INI_ENTRY("mysqlnd.mempool_default_size","16000", PHP_INI_ALL, OnUpdateLong, mempool_default_size, zend_mysqlnd_globals, mysqlnd_globals) + STD_PHP_INI_ENTRY("mysqlnd.sha256_server_public_key",NULL, PHP_INI_SYSTEM, OnUpdateString, sha256_server_public_key, zend_mysqlnd_globals, mysqlnd_globals) #if PHP_DEBUG STD_PHP_INI_ENTRY("mysqlnd.debug_emalloc_fail_threshold","-1", PHP_INI_SYSTEM, OnUpdateLong, debug_emalloc_fail_threshold, zend_mysqlnd_globals, mysqlnd_globals) From 6074df91c6ab80a1fae7c7e8ff5be1c1db342af0 Mon Sep 17 00:00:00 2001 From: andrey Date: Tue, 25 Sep 2012 16:36:21 +0200 Subject: [PATCH 2101/2394] remove old unicode code, that is was compiled out by using a macro --- ext/mysqlnd/mysqlnd.c | 16 -- ext/mysqlnd/mysqlnd_auth.c | 4 - ext/mysqlnd/mysqlnd_bt.c | 256 +---------------------------- ext/mysqlnd/mysqlnd_enum_n_def.h | 4 +- ext/mysqlnd/mysqlnd_priv.h | 25 +-- ext/mysqlnd/mysqlnd_ps.c | 20 +-- ext/mysqlnd/mysqlnd_ps_codec.c | 173 ++++++------------- ext/mysqlnd/mysqlnd_result.c | 31 ---- ext/mysqlnd/mysqlnd_result_meta.c | 82 --------- ext/mysqlnd/mysqlnd_statistics.c | 12 -- ext/mysqlnd/mysqlnd_structs.h | 10 +- ext/mysqlnd/mysqlnd_wireprotocol.c | 70 ++------ ext/mysqlnd/mysqlnd_wireprotocol.h | 10 +- ext/mysqlnd/php_mysqlnd.c | 36 +--- 14 files changed, 80 insertions(+), 669 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index f7f3245a2c42d..65f6a1836cb05 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -456,11 +456,7 @@ mysqlnd_switch_to_ssl_if_needed( if (options->charset_name && (charset = mysqlnd_find_charset_name(options->charset_name))) { auth_packet->charset_no = charset->nr; } else { -#if MYSQLND_UNICODE - auth_packet->charset_no = 200;/* utf8 - swedish collation, check mysqlnd_charset.c */ -#else auth_packet->charset_no = greet_packet->charset_no; -#endif } #ifdef MYSQLND_SSL_SUPPORTED @@ -1030,13 +1026,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, connect)(MYSQLND_CONN_DATA * conn, mysqlnd_local_infile_default(conn); -#if MYSQLND_UNICODE - { - unsigned int as_unicode = 1; - conn->m->set_client_option(conn, MYSQLND_OPT_NUMERIC_AND_DATETIME_AS_UNICODE, (char *)&as_unicode TSRMLS_CC); - DBG_INF("unicode set"); - } -#endif if (FAIL == conn->m->execute_init_commands(conn TSRMLS_CC)) { goto err; } @@ -2283,11 +2272,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c case MYSQLND_OPT_NET_READ_BUFFER_SIZE: ret = conn->net->data->m.set_client_option(conn->net, option, value TSRMLS_CC); break; -#if MYSQLND_UNICODE - case MYSQLND_OPT_NUMERIC_AND_DATETIME_AS_UNICODE: - conn->options->numeric_and_datetime_as_unicode = *(unsigned int*) value; - break; -#endif #ifdef MYSQLND_STRING_TO_INT_CONVERSION case MYSQLND_OPT_INT_AND_FLOAT_NATIVE: conn->options->int_and_float_native = *(unsigned int*) value; diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index 295b6a338bb28..d4373cf6484e4 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -88,11 +88,7 @@ mysqlnd_auth_handshake(MYSQLND_CONN_DATA * conn, if (options->charset_name && (charset = mysqlnd_find_charset_name(options->charset_name))) { auth_packet->charset_no = charset->nr; } else { -#if MYSQLND_UNICODE - auth_packet->charset_no = 200;/* utf8 - swedish collation, check mysqlnd_charset.c */ -#else auth_packet->charset_no = server_charset_no; -#endif } auth_packet->send_auth_data = TRUE; diff --git a/ext/mysqlnd/mysqlnd_bt.c b/ext/mysqlnd/mysqlnd_bt.c index 937518405a383..73cf1f5a617ee 100644 --- a/ext/mysqlnd/mysqlnd_bt.c +++ b/ext/mysqlnd/mysqlnd_bt.c @@ -25,252 +25,6 @@ /* Follows code borrowed from zend_builtin_functions.c because the functions there are static */ -#if MYSQLND_UNICODE -/* {{{ gettraceasstring() macros */ -#define TRACE_APPEND_CHR(chr) \ - *str = (char*)erealloc(*str, *len + 1 + 1); \ - (*str)[(*len)++] = chr - -#define TRACE_APPEND_STRL(val, vallen) \ - { \ - int l = vallen; \ - *str = (char*)erealloc(*str, *len + l + 1); \ - memcpy((*str) + *len, val, l); \ - *len += l; \ - } - -#define TRACE_APPEND_USTRL(val, vallen) \ - { \ - zval tmp, copy; \ - int use_copy; \ - ZVAL_UNICODEL(&tmp, val, vallen, 1); \ - zend_make_printable_zval(&tmp, ©, &use_copy); \ - TRACE_APPEND_STRL(Z_STRVAL(copy), Z_STRLEN(copy)); \ - zval_dtor(©); \ - zval_dtor(&tmp); \ - } - -#define TRACE_APPEND_ZVAL(zv) \ - if (Z_TYPE_P((zv)) == IS_UNICODE) { \ - zval copy; \ - int use_copy; \ - zend_make_printable_zval((zv), ©, &use_copy); \ - TRACE_APPEND_STRL(Z_STRVAL(copy), Z_STRLEN(copy)); \ - zval_dtor(©); \ - } else { \ - TRACE_APPEND_STRL(Z_STRVAL_P((zv)), Z_STRLEN_P((zv))); \ - } - -#define TRACE_APPEND_STR(val) \ - TRACE_APPEND_STRL(val, sizeof(val)-1) - -#define TRACE_APPEND_KEY(key) \ - if (zend_ascii_hash_find(ht, key, sizeof(key), (void**)&tmp) == SUCCESS) { \ - if (Z_TYPE_PP(tmp) == IS_UNICODE) { \ - zval copy; \ - int use_copy; \ - zend_make_printable_zval(*tmp, ©, &use_copy); \ - TRACE_APPEND_STRL(Z_STRVAL(copy), Z_STRLEN(copy)); \ - zval_dtor(©); \ - } else { \ - TRACE_APPEND_STRL(Z_STRVAL_PP(tmp), Z_STRLEN_PP(tmp)); \ - } \ - } -/* }}} */ - - -/* {{{ mysqlnd_build_trace_args */ -static int mysqlnd_build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) -{ - char **str; - int *len; - - str = va_arg(args, char**); - len = va_arg(args, int*); - - /* the trivial way would be to do: - * conver_to_string_ex(arg); - * append it and kill the now tmp arg. - * but that could cause some E_NOTICE and also damn long lines. - */ - - switch (Z_TYPE_PP(arg)) { - case IS_NULL: - TRACE_APPEND_STR("NULL, "); - break; - case IS_STRING: { - int l_added; - TRACE_APPEND_CHR('\''); - if (Z_STRLEN_PP(arg) > 15) { - TRACE_APPEND_STRL(Z_STRVAL_PP(arg), 15); - TRACE_APPEND_STR("...', "); - l_added = 15 + 6 + 1; /* +1 because of while (--l_added) */ - } else { - l_added = Z_STRLEN_PP(arg); - TRACE_APPEND_STRL(Z_STRVAL_PP(arg), l_added); - TRACE_APPEND_STR("', "); - l_added += 3 + 1; - } - while (--l_added) { - if ((unsigned char)(*str)[*len - l_added] < 32) { - (*str)[*len - l_added] = '?'; - } - } - break; - } - case IS_UNICODE: { - int l_added; - - /* - * We do not want to apply current error mode here, since - * zend_make_printable_zval() uses output encoding converter. - * Temporarily set output encoding converter to escape offending - * chars with \uXXXX notation. - */ - zend_set_converter_error_mode(ZEND_U_CONVERTER(UG(output_encoding_conv)), ZEND_FROM_UNICODE, ZEND_CONV_ERROR_ESCAPE_JAVA); - TRACE_APPEND_CHR('\''); - if (Z_USTRLEN_PP(arg) > 15) { - TRACE_APPEND_USTRL(Z_USTRVAL_PP(arg), 15); - TRACE_APPEND_STR("...', "); - l_added = 15 + 6 + 1; /* +1 because of while (--l_added) */ - } else { - l_added = Z_USTRLEN_PP(arg); - TRACE_APPEND_USTRL(Z_USTRVAL_PP(arg), l_added); - TRACE_APPEND_STR("', "); - l_added += 3 + 1; - } - /* - * Reset output encoding converter error mode. - */ - zend_set_converter_error_mode(ZEND_U_CONVERTER(UG(output_encoding_conv)), ZEND_FROM_UNICODE, UG(from_error_mode)); - while (--l_added) { - if ((unsigned char)(*str)[*len - l_added] < 32) { - (*str)[*len - l_added] = '?'; - } - } - break; - } - case IS_BOOL: - if (Z_LVAL_PP(arg)) { - TRACE_APPEND_STR("true, "); - } else { - TRACE_APPEND_STR("false, "); - } - break; - case IS_RESOURCE: - TRACE_APPEND_STR("Resource id #"); - /* break; */ - case IS_LONG: { - long lval = Z_LVAL_PP(arg); - char s_tmp[MAX_LENGTH_OF_LONG + 1]; - int l_tmp = zend_sprintf(s_tmp, "%ld", lval); /* SAFE */ - TRACE_APPEND_STRL(s_tmp, l_tmp); - TRACE_APPEND_STR(", "); - break; - } - case IS_DOUBLE: { - double dval = Z_DVAL_PP(arg); - char *s_tmp; - int l_tmp; - - s_tmp = emalloc(MAX_LENGTH_OF_DOUBLE + EG(precision) + 1); - l_tmp = zend_sprintf(s_tmp, "%.*G", (int) EG(precision), dval); /* SAFE */ - TRACE_APPEND_STRL(s_tmp, l_tmp); - /* %G already handles removing trailing zeros from the fractional part, yay */ - efree(s_tmp); - TRACE_APPEND_STR(", "); - break; - } - case IS_ARRAY: - TRACE_APPEND_STR("Array, "); - break; - case IS_OBJECT: { - zval tmp; - zstr class_name; - zend_uint class_name_len; - int dup; - - TRACE_APPEND_STR("Object("); - - dup = zend_get_object_classname(*arg, &class_name, &class_name_len TSRMLS_CC); - - ZVAL_UNICODEL(&tmp, class_name.u, class_name_len, 1); - convert_to_string_with_converter(&tmp, ZEND_U_CONVERTER(UG(output_encoding_conv))); - TRACE_APPEND_STRL(Z_STRVAL(tmp), Z_STRLEN(tmp)); - zval_dtor(&tmp); - - if(!dup) { - efree(class_name.v); - } - - TRACE_APPEND_STR("), "); - break; - } - default: - break; - } - return ZEND_HASH_APPLY_KEEP; -} -/* }}} */ - - -static int mysqlnd_build_trace_string(zval **frame TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ -{ - char *s_tmp, **str; - int *len, *num; - long line; - HashTable *ht = Z_ARRVAL_PP(frame); - zval **file, **tmp; - uint * level; - - level = va_arg(args, uint *); - str = va_arg(args, char**); - len = va_arg(args, int*); - num = va_arg(args, int*); - - if (!*level) { - return ZEND_HASH_APPLY_KEEP; - } - --*level; - - s_tmp = emalloc(1 + MAX_LENGTH_OF_LONG + 1 + 1); - sprintf(s_tmp, "#%d ", (*num)++); - TRACE_APPEND_STRL(s_tmp, strlen(s_tmp)); - efree(s_tmp); - if (zend_ascii_hash_find(ht, "file", sizeof("file"), (void**)&file) == SUCCESS) { - if (zend_ascii_hash_find(ht, "line", sizeof("line"), (void**)&tmp) == SUCCESS) { - line = Z_LVAL_PP(tmp); - } else { - line = 0; - } - TRACE_APPEND_ZVAL(*file); - s_tmp = emalloc(MAX_LENGTH_OF_LONG + 2 + 1); - sprintf(s_tmp, "(%ld): ", line); - TRACE_APPEND_STRL(s_tmp, strlen(s_tmp)); - efree(s_tmp); - } else { - TRACE_APPEND_STR("[internal function]: "); - } - TRACE_APPEND_KEY("class"); - TRACE_APPEND_KEY("type"); - TRACE_APPEND_KEY("function"); - TRACE_APPEND_CHR('('); - if (zend_ascii_hash_find(ht, "args", sizeof("args"), (void**)&tmp) == SUCCESS) { - int last_len = *len; - zend_hash_apply_with_arguments(Z_ARRVAL_PP(tmp) TSRMLS_CC, (apply_func_args_t)mysqlnd_build_trace_args, 2, str, len); - if (last_len != *len) { - *len -= 2; /* remove last ', ' */ - } - } - TRACE_APPEND_STR(")\n"); - return ZEND_HASH_APPLY_KEEP; -} -/* }}} */ - - -#else /* PHP 5*/ - - /* {{{ gettraceasstring() macros */ #define TRACE_APPEND_CHR(chr) \ *str = (char*)erealloc(*str, *len + 1 + 1); \ @@ -295,7 +49,8 @@ static int mysqlnd_build_trace_string(zval **frame TSRMLS_DC, int num_args, va_l /* }}} */ -static int mysqlnd_build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ +static int +mysqlnd_build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { char **str; int *len; @@ -391,7 +146,8 @@ static int mysqlnd_build_trace_args(zval **arg TSRMLS_DC, int num_args, va_list } /* }}} */ -static int mysqlnd_build_trace_string(zval **frame TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ +static int +mysqlnd_build_trace_string(zval **frame TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { char *s_tmp, **str; int *len, *num; @@ -442,10 +198,10 @@ static int mysqlnd_build_trace_string(zval **frame TSRMLS_DC, int num_args, va_l return ZEND_HASH_APPLY_KEEP; } /* }}} */ -#endif -PHPAPI char * mysqlnd_get_backtrace(uint max_levels, size_t * length TSRMLS_DC) +PHPAPI char * +mysqlnd_get_backtrace(uint max_levels, size_t * length TSRMLS_DC) { zval *trace; char *res = estrdup(""), **str = &res, *s_tmp; diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h index 60e53b3c60b4d..26ad8815c16d6 100644 --- a/ext/mysqlnd/mysqlnd_enum_n_def.h +++ b/ext/mysqlnd/mysqlnd_enum_n_def.h @@ -167,9 +167,7 @@ typedef enum mysqlnd_option MYSQL_PLUGIN_DIR, MYSQL_DEFAULT_AUTH, MYSQL_SERVER_PUBLIC_KEY, -#if MYSQLND_UNICODE - MYSQLND_OPT_NUMERIC_AND_DATETIME_AS_UNICODE = 200, -#endif + MYSQLND_DEPRECATED_ENUM1 = 200, #ifdef MYSQLND_STRING_TO_INT_CONVERSION MYSQLND_OPT_INT_AND_FLOAT_NATIVE = 201, #endif diff --git a/ext/mysqlnd/mysqlnd_priv.h b/ext/mysqlnd/mysqlnd_priv.h index 0d5aef55d4e8b..8fe74cb75813a 100644 --- a/ext/mysqlnd/mysqlnd_priv.h +++ b/ext/mysqlnd/mysqlnd_priv.h @@ -33,12 +33,6 @@ #define Z_DELREF_PP(ppz) Z_DELREF_P(*(ppz)) #endif -#if PHP_MAJOR_VERSION >= 6 -#define MYSQLND_UNICODE 1 -#else -#define MYSQLND_UNICODE 0 -#endif - #ifdef ZTS #include "TSRM.h" #endif @@ -47,21 +41,12 @@ #define pestrndup(s, length, persistent) ((persistent)?zend_strndup((s),(length)):estrndup((s),(length))) #endif -#if MYSQLND_UNICODE -#define mysqlnd_array_init(arg, field_count) \ -{ \ - ALLOC_HASHTABLE_REL(Z_ARRVAL_P(arg));\ - zend_u_hash_init(Z_ARRVAL_P(arg), (field_count), NULL, ZVAL_PTR_DTOR, 0, 0);\ - Z_TYPE_P(arg) = IS_ARRAY;\ -} -#else #define mysqlnd_array_init(arg, field_count) \ { \ ALLOC_HASHTABLE_REL(Z_ARRVAL_P(arg));\ zend_hash_init(Z_ARRVAL_P(arg), (field_count), NULL, ZVAL_PTR_DTOR, 0); \ Z_TYPE_P(arg) = IS_ARRAY;\ } -#endif #define MYSQLND_STR_W_LEN(str) str, (sizeof(str) - 1) @@ -174,9 +159,7 @@ #define CONN_SET_STATE(c, s) (c)->m->set_state((c), (s) TSRMLS_CC) /* PS stuff */ -typedef void (*ps_field_fetch_func)(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool everything_as_unicode TSRMLS_DC); +typedef void (*ps_field_fetch_func)(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC); struct st_mysqlnd_perm_bind { ps_field_fetch_func func; /* should be signed int */ @@ -200,16 +183,14 @@ PHPAPI extern MYSQLND_CLASS_METHOD_TABLE_NAME_FORWARD(mysqlnd_res); PHPAPI extern MYSQLND_CLASS_METHOD_TABLE_NAME_FORWARD(mysqlnd_protocol); PHPAPI extern MYSQLND_CLASS_METHOD_TABLE_NAME_FORWARD(mysqlnd_net); -enum_func_status mysqlnd_handle_local_infile(MYSQLND_CONN_DATA * conn, const char *filename, zend_bool *is_warning TSRMLS_DC); +enum_func_status mysqlnd_handle_local_infile(MYSQLND_CONN_DATA * conn, const char * filename, zend_bool * is_warning TSRMLS_DC); void _mysqlnd_init_ps_subsystem();/* This one is private, mysqlnd_library_init() will call it */ void _mysqlnd_init_ps_fetch_subsystem(); -void ps_fetch_from_1_to_8_bytes(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, zend_bool as_unicode, - unsigned int byte_count TSRMLS_DC); +void ps_fetch_from_1_to_8_bytes(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row, unsigned int byte_count TSRMLS_DC); void mysqlnd_plugin_subsystem_init(TSRMLS_D); void mysqlnd_plugin_subsystem_end(TSRMLS_D); diff --git a/ext/mysqlnd/mysqlnd_ps.c b/ext/mysqlnd/mysqlnd_ps.c index 1b48ba1d7b23c..d5e7d3ffba886 100644 --- a/ext/mysqlnd/mysqlnd_ps.c +++ b/ext/mysqlnd/mysqlnd_ps.c @@ -734,7 +734,6 @@ mysqlnd_stmt_fetch_row_buffered(MYSQLND_RES *result, void *param, unsigned int f current_row, meta->field_count, meta->fields, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC); if (PASS != rc) { @@ -853,7 +852,6 @@ mysqlnd_stmt_fetch_row_unbuffered(MYSQLND_RES *result, void *param, unsigned int result->unbuf->last_row_data, row_packet->field_count, row_packet->fields_metadata, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC)) { @@ -871,14 +869,7 @@ mysqlnd_stmt_fetch_row_unbuffered(MYSQLND_RES *result, void *param, unsigned int zval_dtor(stmt->result_bind[i].zv); #endif if (IS_NULL != (Z_TYPE_P(stmt->result_bind[i].zv) = Z_TYPE_P(data)) ) { - if ( - (Z_TYPE_P(data) == IS_STRING -#if MYSQLND_UNICODE - || Z_TYPE_P(data) == IS_UNICODE -#endif - ) - && (result->meta->fields[i].max_length < (unsigned long) Z_STRLEN_P(data))) - { + if ((Z_TYPE_P(data) == IS_STRING) && (result->meta->fields[i].max_length < (unsigned long) Z_STRLEN_P(data))) { result->meta->fields[i].max_length = Z_STRLEN_P(data); } stmt->result_bind[i].zv->value = data->value; @@ -1037,7 +1028,6 @@ mysqlnd_fetch_stmt_row_cursor(MYSQLND_RES *result, void *param, unsigned int fla result->unbuf->last_row_data, row_packet->field_count, row_packet->fields_metadata, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC)) { @@ -1058,13 +1048,7 @@ mysqlnd_fetch_stmt_row_cursor(MYSQLND_RES *result, void *param, unsigned int fla DBG_INF_FMT("i=%u bound_var=%p type=%u refc=%u", i, stmt->result_bind[i].zv, Z_TYPE_P(data), Z_REFCOUNT_P(stmt->result_bind[i].zv)); if (IS_NULL != (Z_TYPE_P(stmt->result_bind[i].zv) = Z_TYPE_P(data))) { - if ((Z_TYPE_P(data) == IS_STRING -#if MYSQLND_UNICODE - || Z_TYPE_P(data) == IS_UNICODE -#endif - ) - && (result->meta->fields[i].max_length < (unsigned long) Z_STRLEN_P(data))) - { + if ((Z_TYPE_P(data) == IS_STRING) && (result->meta->fields[i].max_length < (unsigned long) Z_STRLEN_P(data))) { result->meta->fields[i].max_length = Z_STRLEN_P(data); } stmt->result_bind[i].zv->value = data->value; diff --git a/ext/mysqlnd/mysqlnd_ps_codec.c b/ext/mysqlnd/mysqlnd_ps_codec.c index ce0736fdffaea..95945cf670185 100644 --- a/ext/mysqlnd/mysqlnd_ps_codec.c +++ b/ext/mysqlnd/mysqlnd_ps_codec.c @@ -53,9 +53,9 @@ struct st_mysqlnd_perm_bind mysqlnd_ps_fetch_functions[MYSQL_TYPE_LAST + 1]; #define MYSQLND_PS_SKIP_RESULT_STR -2 /* {{{ ps_fetch_from_1_to_8_bytes */ -void ps_fetch_from_1_to_8_bytes(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, zend_bool as_unicode, - unsigned int byte_count TSRMLS_DC) +void +ps_fetch_from_1_to_8_bytes(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, + zend_uchar ** row, unsigned int byte_count TSRMLS_DC) { char tmp[22]; size_t tmp_len = 0; @@ -117,16 +117,7 @@ void ps_fetch_from_1_to_8_bytes(zval *zv, const MYSQLND_FIELD * const field, } if (tmp_len) { -#if MYSQLND_UNICODE - if (as_unicode) { - DBG_INF("stringify"); - ZVAL_UTF8_STRINGL(zv, tmp, tmp_len, ZSTR_DUPLICATE); - } else -#endif - { - DBG_INF("stringify"); - ZVAL_STRINGL(zv, tmp, tmp_len, 1); - } + ZVAL_STRINGL(zv, tmp, tmp_len, 1); } (*row)+= byte_count; DBG_VOID_RETURN; @@ -135,10 +126,8 @@ void ps_fetch_from_1_to_8_bytes(zval *zv, const MYSQLND_FIELD * const field, /* {{{ ps_fetch_null */ -static -void ps_fetch_null(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_null(zval *zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { ZVAL_NULL(zv); } @@ -146,54 +135,44 @@ void ps_fetch_null(zval *zv, const MYSQLND_FIELD * const field, /* {{{ ps_fetch_int8 */ -static -void ps_fetch_int8(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_int8(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { - ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, as_unicode, 1 TSRMLS_CC); + ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, 1 TSRMLS_CC); } /* }}} */ /* {{{ ps_fetch_int16 */ -static -void ps_fetch_int16(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_int16(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { - ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, as_unicode, 2 TSRMLS_CC); + ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, 2 TSRMLS_CC); } /* }}} */ /* {{{ ps_fetch_int32 */ -static -void ps_fetch_int32(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_int32(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { - ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, as_unicode, 4 TSRMLS_CC); + ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, 4 TSRMLS_CC); } /* }}} */ /* {{{ ps_fetch_int64 */ -static -void ps_fetch_int64(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_int64(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { - ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, as_unicode, 8 TSRMLS_CC); + ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, 8 TSRMLS_CC); } /* }}} */ /* {{{ ps_fetch_float */ -static -void ps_fetch_float(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_float(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { float value; DBG_ENTER("ps_fetch_float"); @@ -207,10 +186,8 @@ void ps_fetch_float(zval *zv, const MYSQLND_FIELD * const field, /* {{{ ps_fetch_double */ -static -void ps_fetch_double(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_double(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { double value; DBG_ENTER("ps_fetch_double"); @@ -224,18 +201,16 @@ void ps_fetch_double(zval *zv, const MYSQLND_FIELD * const field, /* {{{ ps_fetch_time */ -static -void ps_fetch_time(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_time(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { struct st_mysqlnd_time t; - unsigned int length; /* First byte encodes the length*/ + unsigned long length; /* First byte encodes the length*/ char * value; DBG_ENTER("ps_fetch_time"); if ((length = php_mysqlnd_net_field_length(row))) { - zend_uchar *to= *row; + zend_uchar * to= *row; t.time_type = MYSQLND_TIMESTAMP_TIME; t.neg = (zend_bool) to[0]; @@ -261,29 +236,19 @@ void ps_fetch_time(zval *zv, const MYSQLND_FIELD * const field, length = mnd_sprintf(&value, 0, "%s%02u:%02u:%02u", (t.neg ? "-" : ""), t.hour, t.minute, t.second); DBG_INF_FMT("%s", value); -#if MYSQLND_UNICODE - if (!as_unicode) { -#endif - ZVAL_STRINGL(zv, value, length, 1); - mnd_sprintf_free(value); -#if MYSQLND_UNICODE - } else { - ZVAL_UTF8_STRINGL(zv, value, length, ZSTR_AUTOFREE); - } -#endif + ZVAL_STRINGL(zv, value, length, 1); + mnd_sprintf_free(value); DBG_VOID_RETURN; } /* }}} */ /* {{{ ps_fetch_date */ -static -void ps_fetch_date(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_date(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { struct st_mysqlnd_time t = {0}; - unsigned int length; /* First byte encodes the length*/ + unsigned long length; /* First byte encodes the length*/ char * value; DBG_ENTER("ps_fetch_date"); @@ -308,34 +273,24 @@ void ps_fetch_date(zval *zv, const MYSQLND_FIELD * const field, length = mnd_sprintf(&value, 0, "%04u-%02u-%02u", t.year, t.month, t.day); DBG_INF_FMT("%s", value); -#if MYSQLND_UNICODE - if (!as_unicode) { -#endif - ZVAL_STRINGL(zv, value, length, 1); - mnd_sprintf_free(value); -#if MYSQLND_UNICODE - } else { - ZVAL_UTF8_STRINGL(zv, value, length, ZSTR_AUTOFREE); - } -#endif + ZVAL_STRINGL(zv, value, length, 1); + mnd_sprintf_free(value); DBG_VOID_RETURN; } /* }}} */ /* {{{ ps_fetch_datetime */ -static -void ps_fetch_datetime(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_datetime(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { struct st_mysqlnd_time t; - unsigned int length; /* First byte encodes the length*/ + unsigned long length; /* First byte encodes the length*/ char * value; DBG_ENTER("ps_fetch_datetime"); if ((length = php_mysqlnd_net_field_length(row))) { - zend_uchar *to= *row; + zend_uchar * to = *row; t.time_type = MYSQLND_TIMESTAMP_DATETIME; t.neg = 0; @@ -362,46 +317,26 @@ void ps_fetch_datetime(zval *zv, const MYSQLND_FIELD * const field, length = mnd_sprintf(&value, 0, "%04u-%02u-%02u %02u:%02u:%02u", t.year, t.month, t.day, t.hour, t.minute, t.second); DBG_INF_FMT("%s", value); -#if MYSQLND_UNICODE - if (!as_unicode) { -#endif - ZVAL_STRINGL(zv, value, length, 1); - mnd_sprintf_free(value); -#if MYSQLND_UNICODE - } else { - ZVAL_UTF8_STRINGL(zv, to, length, ZSTR_AUTOFREE); - } -#endif + ZVAL_STRINGL(zv, value, length, 1); + mnd_sprintf_free(value); DBG_VOID_RETURN; } /* }}} */ /* {{{ ps_fetch_string */ -static -void ps_fetch_string(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_string(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { /* For now just copy, before we make it possible to write \0 to the row buffer */ - unsigned long length = php_mysqlnd_net_field_length(row); + const unsigned long length = php_mysqlnd_net_field_length(row); DBG_ENTER("ps_fetch_string"); DBG_INF_FMT("len = %lu", length); -#if MYSQLND_UNICODE - if (field->charsetnr == MYSQLND_BINARY_CHARSET_NR) { - DBG_INF("Binary charset"); - ZVAL_STRINGL(zv, (char *)*row, length, 1); - } else { - DBG_INF_FMT("copying from the row buffer"); - ZVAL_UTF8_STRINGL(zv, (char*)*row, length, ZSTR_DUPLICATE); - } -#else DBG_INF("copying from the row buffer"); ZVAL_STRINGL(zv, (char *)*row, length, 1); -#endif (*row) += length; DBG_VOID_RETURN; @@ -410,13 +345,11 @@ void ps_fetch_string(zval *zv, const MYSQLND_FIELD * const field, /* {{{ ps_fetch_bit */ -static -void ps_fetch_bit(zval *zv, const MYSQLND_FIELD * const field, - unsigned int pack_len, zend_uchar **row, - zend_bool as_unicode TSRMLS_DC) +static void +ps_fetch_bit(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_len, zend_uchar ** row TSRMLS_DC) { - unsigned long length= php_mysqlnd_net_field_length(row); - ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, as_unicode, length TSRMLS_CC); + unsigned long length = php_mysqlnd_net_field_length(row); + ps_fetch_from_1_to_8_bytes(zv, field, pack_len, row, length TSRMLS_CC); } /* }}} */ @@ -566,7 +499,7 @@ void _mysqlnd_init_ps_fetch_subsystem() /* {{{ mysqlnd_stmt_copy_it */ static enum_func_status -mysqlnd_stmt_copy_it(zval *** copies, zval *original, unsigned int param_count, unsigned int current TSRMLS_DC) +mysqlnd_stmt_copy_it(zval *** copies, zval * original, unsigned int param_count, unsigned int current TSRMLS_DC) { if (!*copies) { *copies = mnd_ecalloc(param_count, sizeof(zval *)); @@ -786,12 +719,7 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar case MYSQL_TYPE_VAR_STRING: use_string: data_size += 8; /* max 8 bytes for size */ -#if MYSQLND_UNICODE - if (Z_TYPE_P(the_var) != IS_STRING || Z_TYPE_P(the_var) == IS_UNICODE) -#else - if (Z_TYPE_P(the_var) != IS_STRING) -#endif - { + if (Z_TYPE_P(the_var) != IS_STRING) { if (!copies || !copies[i]) { if (PASS != mysqlnd_stmt_copy_it(&copies, the_var, stmt->param_count, i TSRMLS_CC)) { SET_OOM_ERROR(*stmt->error_info); @@ -799,11 +727,6 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar } } the_var = copies[i]; -#if MYSQLND_UNICODE - if (Z_TYPE_P(the_var) == IS_UNICODE) { - zval_unicode_to_string_ex(the_var, UG(utf8_conv) TSRMLS_CC); - } -#endif } convert_to_string_ex(&the_var); data_size += Z_STRLEN_P(the_var); diff --git a/ext/mysqlnd/mysqlnd_result.c b/ext/mysqlnd/mysqlnd_result.c index 8ae2665ba76f7..3dd06edb34e3e 100644 --- a/ext/mysqlnd/mysqlnd_result.c +++ b/ext/mysqlnd/mysqlnd_result.c @@ -55,7 +55,6 @@ MYSQLND_METHOD(mysqlnd_res, initialize_result_set_rest)(MYSQLND_RES * const resu data_cursor, result->meta->field_count, result->meta->fields, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC); if (rc != PASS) { @@ -106,16 +105,6 @@ mysqlnd_rset_zval_ptr_dtor(zval **zv, enum_mysqlnd_res_type type, zend_bool * co /* Not a prepared statement, then we have to call copy_ctor and then zval_ptr_dtor() - - In Unicode mode the destruction of the zvals should not call - zval_copy_ctor() because then we will leak. - I suppose we can use UG(unicode) in mysqlnd.c when freeing a result set - to check if we need to call copy_ctor(). - - If the type is IS_UNICODE, which can happen with PHP6, then we don't - need to copy_ctor, as the data doesn't point to our internal buffers. - If it's string (in PHP5 always) and in PHP6 if data is binary, then - it still points to internal buffers and has to be copied. */ if (Z_TYPE_PP(zv) == IS_STRING) { zval_copy_ctor(*zv); @@ -669,7 +658,6 @@ mysqlnd_fetch_row_unbuffered_c(MYSQLND_RES * result TSRMLS_DC) result->unbuf->last_row_data, row_packet->field_count, row_packet->fields_metadata, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC); if (PASS != rc) { @@ -784,7 +772,6 @@ mysqlnd_fetch_row_unbuffered(MYSQLND_RES * result, void *param, unsigned int fla result->unbuf->last_row_data, field_count, row_packet->fields_metadata, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC); if (PASS != rc) { @@ -812,19 +799,11 @@ mysqlnd_fetch_row_unbuffered(MYSQLND_RES * result, void *param, unsigned int fla */ Z_ADDREF_P(data); if (hash_key->is_numeric == FALSE) { -#if MYSQLND_UNICODE - zend_u_hash_quick_update(Z_ARRVAL_P(row), IS_UNICODE, - hash_key->ustr, - hash_key->ulen + 1, - hash_key->key, - (void *) &data, sizeof(zval *), NULL); -#else zend_hash_quick_update(Z_ARRVAL_P(row), field->name, field->name_length + 1, hash_key->key, (void *) &data, sizeof(zval *), NULL); -#endif } else { zend_hash_index_update(Z_ARRVAL_P(row), hash_key->key, @@ -950,7 +929,6 @@ mysqlnd_fetch_row_buffered_c(MYSQLND_RES * result TSRMLS_DC) current_row, result->meta->field_count, result->meta->fields, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC); if (rc != PASS) { @@ -1023,7 +1001,6 @@ mysqlnd_fetch_row_buffered(MYSQLND_RES * result, void *param, unsigned int flags current_row, result->meta->field_count, result->meta->fields, - result->conn->options->numeric_and_datetime_as_unicode, result->conn->options->int_and_float_native, result->conn->stats TSRMLS_CC); if (rc != PASS) { @@ -1062,19 +1039,11 @@ mysqlnd_fetch_row_buffered(MYSQLND_RES * result, void *param, unsigned int flags */ Z_ADDREF_P(data); if (hash_key->is_numeric == FALSE) { -#if MYSQLND_UNICODE - zend_u_hash_quick_update(Z_ARRVAL_P(row), IS_UNICODE, - hash_key->ustr, - hash_key->ulen + 1, - hash_key->key, - (void *) &data, sizeof(zval *), NULL); -#else zend_hash_quick_update(Z_ARRVAL_P(row), field->name, field->name_length + 1, hash_key->key, (void *) &data, sizeof(zval *), NULL); -#endif } else { zend_hash_index_update(Z_ARRVAL_P(row), hash_key->key, diff --git a/ext/mysqlnd/mysqlnd_result_meta.c b/ext/mysqlnd/mysqlnd_result_meta.c index 9469ceaf111d7..53368a8fb8fa7 100644 --- a/ext/mysqlnd/mysqlnd_result_meta.c +++ b/ext/mysqlnd/mysqlnd_result_meta.c @@ -92,60 +92,12 @@ mysqlnd_is_key_numeric(const char * key, size_t length, long *idx) /* }}} */ -#if MYSQLND_UNICODE -/* {{{ mysqlnd_unicode_is_key_numeric */ -static zend_bool -mysqlnd_unicode_is_key_numeric(UChar *key, size_t length, long *idx) -{ - register UChar * tmp=key; - - if (*tmp==0x2D /*'-'*/) { - tmp++; - } - if ((*tmp>=0x30 /*'0'*/ && *tmp<=0x39 /*'9'*/)) { /* possibly a numeric index */ - do { - UChar *end=key+length-1; - - if (*tmp++==0x30 && length>2) { /* don't accept numbers with leading zeros */ - break; - } - while (tmp=0x30 /*'0'*/ && *tmp<=0x39 /*'9'*/)) { - break; - } - tmp++; - } - if (tmp==end && *tmp==0) { /* a numeric index */ - if (*key==0x2D /*'-'*/) { - *idx = zend_u_strtol(key, NULL, 10); - if (*idx!=LONG_MIN) { - return TRUE; - } - } else { - *idx = zend_u_strtol(key, NULL, 10); - if (*idx!=LONG_MAX) { - return TRUE; - } - } - } - } while (0); - } - return FALSE; -} -/* }}} */ -#endif - - /* {{{ mysqlnd_res_meta::read_metadata */ static enum_func_status MYSQLND_METHOD(mysqlnd_res_meta, read_metadata)(MYSQLND_RES_METADATA * const meta, MYSQLND_CONN_DATA * conn TSRMLS_DC) { unsigned int i = 0; MYSQLND_PACKET_RES_FIELD * field_packet; -#if MYSQLND_UNICODE - UChar *ustr; - int ulen; -#endif DBG_ENTER("mysqlnd_res_meta::read_metadata"); @@ -226,21 +178,6 @@ MYSQLND_METHOD(mysqlnd_res_meta, read_metadata)(MYSQLND_RES_METADATA * const met } } -#if MYSQLND_UNICODE - zend_string_to_unicode(UG(utf8_conv), &ustr, &ulen, - meta->fields[i].name, - meta->fields[i].name_length TSRMLS_CC); - if ((meta->zend_hash_keys[i].is_numeric = - mysqlnd_unicode_is_key_numeric(ustr, ulen + 1, &idx))) - { - meta->zend_hash_keys[i].key = idx; - mnd_efree(ustr); - } else { - meta->zend_hash_keys[i].ustr.u = ustr; - meta->zend_hash_keys[i].ulen = ulen; - meta->zend_hash_keys[i].key = zend_u_get_hash_value(IS_UNICODE, ZSTR(ustr), ulen + 1); - } -#else /* For BC we have to check whether the key is numeric and use it like this */ if ((meta->zend_hash_keys[i].is_numeric = mysqlnd_is_key_numeric(field_packet->metadata->name, @@ -253,7 +190,6 @@ MYSQLND_METHOD(mysqlnd_res_meta, read_metadata)(MYSQLND_RES_METADATA * const met zend_get_hash_value(field_packet->metadata->name, field_packet->metadata->name_length + 1); } -#endif } PACKET_FREE(field_packet); @@ -283,15 +219,6 @@ MYSQLND_METHOD(mysqlnd_res_meta, free)(MYSQLND_RES_METADATA * meta TSRMLS_DC) if (meta->zend_hash_keys) { DBG_INF("Freeing zend_hash_keys"); -#if MYSQLND_UNICODE - if (UG(unicode)) { - for (i = 0; i < meta->field_count; i++) { - if (meta->zend_hash_keys[i].ustr.v) { - mnd_pefree(meta->zend_hash_keys[i].ustr.v, meta->persistent); - } - } - } -#endif mnd_pefree(meta->zend_hash_keys, meta->persistent); meta->zend_hash_keys = NULL; } @@ -379,15 +306,6 @@ MYSQLND_METHOD(mysqlnd_res_meta, clone_metadata)(const MYSQLND_RES_METADATA * co /* copy the trailing \0 too */ memcpy(new_fields[i].def, orig_fields[i].def, orig_fields[i].def_length + 1); } -#if MYSQLND_UNICODE - if (new_meta->zend_hash_keys[i].ustr.u) { - new_meta->zend_hash_keys[i].ustr.u = - eustrndup(new_meta->zend_hash_keys[i].ustr.u, new_meta->zend_hash_keys[i].ulen); - if (!new_meta->zend_hash_keys[i].ustr.u) { - goto oom; - } - } -#endif } new_meta->current_field = 0; new_meta->field_count = meta->field_count; diff --git a/ext/mysqlnd/mysqlnd_statistics.c b/ext/mysqlnd/mysqlnd_statistics.c index bb00a9192dfef..00145a3dbce82 100644 --- a/ext/mysqlnd/mysqlnd_statistics.c +++ b/ext/mysqlnd/mysqlnd_statistics.c @@ -203,22 +203,10 @@ mysqlnd_fill_stats_hash(const MYSQLND_STATS * const stats, const MYSQLND_STRING mysqlnd_array_init(return_value, stats->count); for (i = 0; i < stats->count; i++) { -#if MYSQLND_UNICODE - UChar *ustr, *tstr; - int ulen, tlen; -#endif char tmp[25]; sprintf((char *)&tmp, MYSQLND_LLU_SPEC, stats->values[i]); -#if MYSQLND_UNICODE - zend_string_to_unicode(UG(utf8_conv), &ustr, &ulen, names[i].s, names[i].l + 1 TSRMLS_CC); - zend_string_to_unicode(UG(utf8_conv), &tstr, &tlen, tmp, strlen(tmp) + 1 TSRMLS_CC); - add_u_assoc_unicode_ex(return_value, IS_UNICODE, ZSTR(ustr), ulen, tstr, 1); - efree(ustr); - efree(tstr); -#else add_assoc_string_ex(return_value, names[i].s, names[i].l + 1, tmp, 1); -#endif } } /* }}} */ diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 511a168b56497..16092e987c590 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -183,7 +183,6 @@ typedef struct st_mysqlnd_options /* maximum allowed packet size for communication */ ulong max_allowed_packet; - zend_bool numeric_and_datetime_as_unicode; #ifdef MYSQLND_STRING_TO_INT_CONVERSION zend_bool int_and_float_native; #endif @@ -625,9 +624,8 @@ typedef void (*func_mysqlnd_res__unbuffered_free_last_data)(MYSQLND_RES *resu /* for decoding - binary or text protocol */ typedef enum_func_status (*func_mysqlnd_res__row_decoder)(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields, - unsigned int field_count, MYSQLND_FIELD *fields_metadata, - zend_bool as_unicode, zend_bool as_int_or_float, - MYSQLND_STATS * stats TSRMLS_DC); + unsigned int field_count, const MYSQLND_FIELD * fields_metadata, + zend_bool as_int_or_float, MYSQLND_STATS * stats TSRMLS_DC); typedef MYSQLND_RES_METADATA * (*func_mysqlnd_res__result_meta_init)(unsigned int field_count, zend_bool persistent TSRMLS_DC); @@ -932,10 +930,6 @@ struct mysqlnd_field_hash_key { zend_bool is_numeric; unsigned long key; -#if MYSQLND_UNICODE - zstr ustr; - unsigned int ulen; -#endif }; diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c index e41c771a8a089..4697a01a66091 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.c +++ b/ext/mysqlnd/mysqlnd_wireprotocol.c @@ -1411,9 +1411,8 @@ php_mysqlnd_read_row_ex(MYSQLND_CONN_DATA * conn, MYSQLND_MEMORY_POOL * result_s /* {{{ php_mysqlnd_rowp_read_binary_protocol */ enum_func_status php_mysqlnd_rowp_read_binary_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields, - unsigned int field_count, MYSQLND_FIELD *fields_metadata, - zend_bool as_unicode, zend_bool as_int_or_float, - MYSQLND_STATS * stats TSRMLS_DC) + unsigned int field_count, const MYSQLND_FIELD * fields_metadata, + zend_bool as_int_or_float, MYSQLND_STATS * stats TSRMLS_DC) { unsigned int i; zend_uchar * p = row_buffer->ptr; @@ -1446,17 +1445,17 @@ php_mysqlnd_rowp_read_binary_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zv enum_mysqlnd_collected_stats statistic; zend_uchar * orig_p = p; - DBG_INF_FMT("Into zval=%p decoding column %u [%s.%s.%s] type=%u field->flags&unsigned=%u flags=%u is_bit=%u as_unicode=%u", + DBG_INF_FMT("Into zval=%p decoding column %u [%s.%s.%s] type=%u field->flags&unsigned=%u flags=%u is_bit=%u", *current_field, i, fields_metadata[i].db, fields_metadata[i].table, fields_metadata[i].name, fields_metadata[i].type, - fields_metadata[i].flags & UNSIGNED_FLAG, fields_metadata[i].flags, fields_metadata[i].type == MYSQL_TYPE_BIT, as_unicode); + fields_metadata[i].flags & UNSIGNED_FLAG, fields_metadata[i].flags, fields_metadata[i].type == MYSQL_TYPE_BIT); if (*null_ptr & bit) { DBG_INF("It's null"); ZVAL_NULL(*current_field); statistic = STAT_BINARY_TYPE_FETCHED_NULL; } else { enum_mysqlnd_field_types type = fields_metadata[i].type; - mysqlnd_ps_fetch_functions[type].func(*current_field, &fields_metadata[i], 0, &p, as_unicode TSRMLS_CC); + mysqlnd_ps_fetch_functions[type].func(*current_field, &fields_metadata[i], 0, &p TSRMLS_CC); if (MYSQLND_G(collect_statistics)) { switch (fields_metadata[i].type) { @@ -1510,9 +1509,8 @@ php_mysqlnd_rowp_read_binary_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zv /* {{{ php_mysqlnd_rowp_read_text_protocol */ enum_func_status php_mysqlnd_rowp_read_text_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields, - unsigned int field_count, MYSQLND_FIELD *fields_metadata, - zend_bool as_unicode, zend_bool as_int_or_float, - MYSQLND_STATS * stats TSRMLS_DC) + unsigned int field_count, const MYSQLND_FIELD * fields_metadata, + zend_bool as_int_or_float, MYSQLND_STATS * stats TSRMLS_DC) { unsigned int i; zend_bool last_field_was_string = FALSE; @@ -1564,7 +1562,7 @@ php_mysqlnd_rowp_read_text_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ZVAL_NULL(*current_field); last_field_was_string = FALSE; } else { -#if MYSQLND_UNICODE || defined(MYSQLND_STRING_TO_INT_CONVERSION) +#if defined(MYSQLND_STRING_TO_INT_CONVERSION) struct st_mysqlnd_perm_bind perm_bind = mysqlnd_ps_fetch_functions[fields_metadata[i].type]; #endif @@ -1660,7 +1658,7 @@ php_mysqlnd_rowp_read_text_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval Definitely not nice, _hackish_ :(, but works. */ zend_uchar *start = bit_area; - ps_fetch_from_1_to_8_bytes(*current_field, &(fields_metadata[i]), 0, &p, as_unicode, len TSRMLS_CC); + ps_fetch_from_1_to_8_bytes(*current_field, &(fields_metadata[i]), 0, &p, len TSRMLS_CC); /* We have advanced in ps_fetch_from_1_to_8_bytes. We should go back because later in this function there will be an advancement. @@ -1668,60 +1666,16 @@ php_mysqlnd_rowp_read_text_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval p -= len; if (Z_TYPE_PP(current_field) == IS_LONG) { bit_area += 1 + sprintf((char *)start, "%ld", Z_LVAL_PP(current_field)); -#if MYSQLND_UNICODE - if (as_unicode) { - ZVAL_UTF8_STRINGL(*current_field, start, bit_area - start - 1, 0); - } else -#endif - { - ZVAL_STRINGL(*current_field, (char *) start, bit_area - start - 1, 0); - } + ZVAL_STRINGL(*current_field, (char *) start, bit_area - start - 1, 0); } else if (Z_TYPE_PP(current_field) == IS_STRING){ memcpy(bit_area, Z_STRVAL_PP(current_field), Z_STRLEN_PP(current_field)); bit_area += Z_STRLEN_PP(current_field); *bit_area++ = '\0'; zval_dtor(*current_field); -#if MYSQLND_UNICODE - if (as_unicode) { - ZVAL_UTF8_STRINGL(*current_field, start, bit_area - start - 1, 0); - } else -#endif - { - ZVAL_STRINGL(*current_field, (char *) start, bit_area - start - 1, 0); - } + ZVAL_STRINGL(*current_field, (char *) start, bit_area - start - 1, 0); } - /* - IS_UNICODE should not be specially handled. In unicode mode - the buffers are not referenced - everything is copied. - */ } else -#if MYSQLND_UNICODE == 0 - { - ZVAL_STRINGL(*current_field, (char *)p, len, 0); - } -#else - /* - Here we have to convert to UTF16, which means not reusing the buffer. - Which in turn means that we can free the buffers once we have - stored the result set, if we use store_result(). - - Also the destruction of the zvals should not call zval_copy_ctor() - because then we will leak. - - XXX: Keep in mind that up there there is an open `else` in - #ifdef MYSQLND_STRING_TO_INT_CONVERSION - which will make with this `if` an `else if`. - */ - if ((perm_bind.is_possibly_blob == TRUE && - fields_metadata[i].charsetnr == MYSQLND_BINARY_CHARSET_NR) || - (!as_unicode && perm_bind.can_ret_as_str_in_uni == TRUE)) - { - /* BLOB - no conversion please */ - ZVAL_STRINGL(*current_field, (char *)p, len, 0); - } else { - ZVAL_UTF8_STRINGL(*current_field, (char *)p, len, 0); - } -#endif + ZVAL_STRINGL(*current_field, (char *)p, len, 0); p += len; last_field_was_string = TRUE; } diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.h b/ext/mysqlnd/mysqlnd_wireprotocol.h index e5008e6db559c..92c8e502de36f 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.h +++ b/ext/mysqlnd/mysqlnd_wireprotocol.h @@ -307,15 +307,13 @@ PHPAPI const extern char * const mysqlnd_empty_string; enum_func_status php_mysqlnd_rowp_read_binary_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields, - unsigned int field_count, MYSQLND_FIELD *fields_metadata, - zend_bool as_unicode, zend_bool as_int_or_float, - MYSQLND_STATS * stats TSRMLS_DC); + unsigned int field_count, const MYSQLND_FIELD * fields_metadata, + zend_bool as_int_or_float, MYSQLND_STATS * stats TSRMLS_DC); enum_func_status php_mysqlnd_rowp_read_text_protocol(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields, - unsigned int field_count, MYSQLND_FIELD *fields_metadata, - zend_bool as_unicode, zend_bool as_int_or_float, - MYSQLND_STATS * stats TSRMLS_DC); + unsigned int field_count, const MYSQLND_FIELD * fields_metadata, + zend_bool as_int_or_float, MYSQLND_STATS * stats TSRMLS_DC); PHPAPI MYSQLND_PROTOCOL * mysqlnd_protocol_init(zend_bool persistent TSRMLS_DC); diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index 8dccf37c4b3cd..f2f7ab98ebdfb 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -40,39 +40,8 @@ static zend_function_entry mysqlnd_functions[] = { /* {{{ mysqlnd_minfo_print_hash */ -#if MYSQLND_UNICODE -PHPAPI void mysqlnd_minfo_print_hash(zval *values) -{ - zval **values_entry; - HashPosition pos_values; - - zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(values), &pos_values); - while (zend_hash_get_current_data_ex(Z_ARRVAL_P(values), - (void **)&values_entry, &pos_values) == SUCCESS) { - zstr string_key; - uint string_key_len; - ulong num_key; - int s_len; - char *s = NULL; - - TSRMLS_FETCH(); - zend_hash_get_current_key_ex(Z_ARRVAL_P(values), &string_key, &string_key_len, &num_key, 0, &pos_values); - - convert_to_string(*values_entry); - - if (zend_unicode_to_string(ZEND_U_CONVERTER(UG(runtime_encoding_conv)), - &s, &s_len, string_key.u, string_key_len TSRMLS_CC) == SUCCESS) { - php_info_print_table_row(2, s, Z_STRVAL_PP(values_entry)); - } - if (s) { - mnd_efree(s); - } - - zend_hash_move_forward_ex(Z_ARRVAL_P(values), &pos_values); - } -} -#else -PHPAPI void mysqlnd_minfo_print_hash(zval *values) +PHPAPI void +mysqlnd_minfo_print_hash(zval *values) { zval **values_entry; HashPosition pos_values; @@ -91,7 +60,6 @@ PHPAPI void mysqlnd_minfo_print_hash(zval *values) zend_hash_move_forward_ex(Z_ARRVAL_P(values), &pos_values); } } -#endif /* }}} */ From 263b37bee1ea92e30791b15af710b509da4b8ca8 Mon Sep 17 00:00:00 2001 From: andrey Date: Tue, 25 Sep 2012 18:26:02 +0200 Subject: [PATCH 2102/2394] change public key setting to PERDIR and finish code that allows to set the key file programatically per mysqli_options() --- ext/mysqli/mysqli.c | 2 ++ ext/mysqli/mysqli_api.c | 9 +++++---- ext/mysqlnd/mysqlnd.c | 1 + ext/mysqlnd/mysqlnd_auth.c | 6 +++++- ext/mysqlnd/mysqlnd_net.c | 9 +++++++++ ext/mysqlnd/php_mysqlnd.c | 2 +- 6 files changed, 23 insertions(+), 6 deletions(-) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index 0e7e048763d73..9eaac249cc309 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -699,6 +699,8 @@ PHP_MINIT_FUNCTION(mysqli) REGISTER_LONG_CONSTANT("MYSQLI_OPT_SSL_VERIFY_SERVER_CERT", MYSQL_OPT_SSL_VERIFY_SERVER_CERT, CONST_CS | CONST_PERSISTENT); #endif + REGISTER_LONG_CONSTANT("MYSQLI_SERVER_PUBLIC_KEY", MYSQL_SERVER_PUBLIC_KEY, CONST_CS | CONST_PERSISTENT); + /* mysqli_real_connect flags */ REGISTER_LONG_CONSTANT("MYSQLI_CLIENT_SSL", CLIENT_SSL, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MYSQLI_CLIENT_COMPRESS",CLIENT_COMPRESS, CONST_CS | CONST_PERSISTENT); diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index 22eae7ee1ce32..dbdda9bc5e68f 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -1587,10 +1587,10 @@ static int mysqli_options_get_option_zval_type(int option) #endif /* MYSQLI_USE_MYSQLND */ case MYSQL_OPT_CONNECT_TIMEOUT: #ifdef MYSQL_REPORT_DATA_TRUNCATION - case MYSQL_REPORT_DATA_TRUNCATION: + case MYSQL_REPORT_DATA_TRUNCATION: #endif - case MYSQL_OPT_LOCAL_INFILE: - case MYSQL_OPT_NAMED_PIPE: + case MYSQL_OPT_LOCAL_INFILE: + case MYSQL_OPT_NAMED_PIPE: #ifdef MYSQL_OPT_PROTOCOL case MYSQL_OPT_PROTOCOL: #endif /* MySQL 4.1.0 */ @@ -1606,7 +1606,7 @@ static int mysqli_options_get_option_zval_type(int option) case MYSQL_OPT_RECONNECT: #endif /* MySQL 5.0.13 */ #ifdef MYSQL_OPT_SSL_VERIFY_SERVER_CERT - case MYSQL_OPT_SSL_VERIFY_SERVER_CERT: + case MYSQL_OPT_SSL_VERIFY_SERVER_CERT: #endif /* MySQL 5.0.23 */ #ifdef MYSQL_OPT_COMPRESS case MYSQL_OPT_COMPRESS: @@ -1627,6 +1627,7 @@ static int mysqli_options_get_option_zval_type(int option) case MYSQL_INIT_COMMAND: case MYSQL_SET_CHARSET_NAME: case MYSQL_SET_CHARSET_DIR: + case MYSQL_SERVER_PUBLIC_KEY: return IS_STRING; default: diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 65f6a1836cb05..3fa9d11a28488 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2270,6 +2270,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c case MYSQL_OPT_CONNECT_TIMEOUT: case MYSQLND_OPT_NET_CMD_BUFFER_SIZE: case MYSQLND_OPT_NET_READ_BUFFER_SIZE: + case MYSQL_SERVER_PUBLIC_KEY: ret = conn->net->data->m.set_client_option(conn->net, option, value TSRMLS_CC); break; #ifdef MYSQLND_STRING_TO_INT_CONVERSION diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index d4373cf6484e4..ce03be4447ab2 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -488,7 +488,9 @@ mysqlnd_sha256_get_rsa_key(MYSQLND_CONN_DATA * conn, MYSQLND_G(sha256_server_public_key); php_stream * stream; DBG_ENTER("mysqlnd_sha256_get_rsa_key"); - + DBG_INF_FMT("options_s256_pk=[%s] MYSQLND_G(sha256_server_public_key)=[%s]", + net_options->sha256_server_public_key? net_options->sha256_server_public_key:"n/a", + MYSQLND_G(sha256_server_public_key)? MYSQLND_G(sha256_server_public_key):"n/a"); if (!fname || fname[0] == '\0') { MYSQLND_PACKET_SHA256_PK_REQUEST * pk_req_packet = NULL; MYSQLND_PACKET_SHA256_PK_REQUEST_RESPONSE * pk_resp_packet = NULL; @@ -539,6 +541,7 @@ mysqlnd_sha256_get_rsa_key(MYSQLND_CONN_DATA * conn, DBG_RETURN(NULL); } else { char * key_str = NULL; + DBG_INF_FMT("Key in a file. [%s]", fname); stream = php_stream_open_wrapper((char *) fname, "rb", REPORT_ERRORS, NULL); if (stream) { @@ -546,6 +549,7 @@ mysqlnd_sha256_get_rsa_key(MYSQLND_CONN_DATA * conn, BIO * bio = BIO_new_mem_buf(key_str, len); ret = PEM_read_bio_RSA_PUBKEY(bio, NULL, NULL, NULL); BIO_free(bio); + DBG_INF("Successfully loaded"); } if (key_str) { DBG_INF_FMT("Public key:%*.s", len, key_str); diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index 7458f76528db6..b3d97447e9514 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -781,6 +781,15 @@ MYSQLND_METHOD(mysqlnd_net, set_client_option)(MYSQLND_NET * const net, enum mys case MYSQL_OPT_COMPRESS: net->data->options.flags |= MYSQLND_NET_FLAG_USE_COMPRESSION; break; + case MYSQL_SERVER_PUBLIC_KEY: + { + zend_bool pers = net->persistent; + if (net->data->options.sha256_server_public_key) { + mnd_pefree(net->data->options.sha256_server_public_key, pers); + } + net->data->options.sha256_server_public_key = value? mnd_pestrdup(value, pers) : NULL; + break; + } default: DBG_RETURN(FAIL); } diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c index f2f7ab98ebdfb..9bc6b8fb5b159 100644 --- a/ext/mysqlnd/php_mysqlnd.c +++ b/ext/mysqlnd/php_mysqlnd.c @@ -236,7 +236,7 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("mysqlnd.net_read_timeout", "31536000", PHP_INI_SYSTEM, OnUpdateLong, net_read_timeout, zend_mysqlnd_globals, mysqlnd_globals) STD_PHP_INI_ENTRY("mysqlnd.log_mask", "0", PHP_INI_ALL, OnUpdateLong, log_mask, zend_mysqlnd_globals, mysqlnd_globals) STD_PHP_INI_ENTRY("mysqlnd.mempool_default_size","16000", PHP_INI_ALL, OnUpdateLong, mempool_default_size, zend_mysqlnd_globals, mysqlnd_globals) - STD_PHP_INI_ENTRY("mysqlnd.sha256_server_public_key",NULL, PHP_INI_SYSTEM, OnUpdateString, sha256_server_public_key, zend_mysqlnd_globals, mysqlnd_globals) + STD_PHP_INI_ENTRY("mysqlnd.sha256_server_public_key",NULL, PHP_INI_PERDIR, OnUpdateString, sha256_server_public_key, zend_mysqlnd_globals, mysqlnd_globals) #if PHP_DEBUG STD_PHP_INI_ENTRY("mysqlnd.debug_emalloc_fail_threshold","-1", PHP_INI_SYSTEM, OnUpdateLong, debug_emalloc_fail_threshold, zend_mysqlnd_globals, mysqlnd_globals) From da96aa848fc4845399d4d7a7c396fa31ffb9ffba Mon Sep 17 00:00:00 2001 From: andrey Date: Wed, 26 Sep 2012 17:13:46 +0200 Subject: [PATCH 2103/2394] compile out example plugin in a release build --- ext/mysqlnd/mysqlnd_auth.c | 2 +- ext/mysqlnd/mysqlnd_driver.c | 2 ++ ext/mysqlnd/mysqlnd_plugin.c | 4 ++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index ce03be4447ab2..72b25326e05e6 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -558,7 +558,7 @@ mysqlnd_sha256_get_rsa_key(MYSQLND_CONN_DATA * conn, } php_stream_free(stream, PHP_STREAM_FREE_CLOSE); } - DBG_RETURN(ret) + DBG_RETURN(ret); } /* }}} */ diff --git a/ext/mysqlnd/mysqlnd_driver.c b/ext/mysqlnd/mysqlnd_driver.c index e55a0bc2eea05..93f3d3fc953f4 100644 --- a/ext/mysqlnd/mysqlnd_driver.c +++ b/ext/mysqlnd/mysqlnd_driver.c @@ -81,7 +81,9 @@ PHPAPI void mysqlnd_library_init(TSRMLS_D) mysqlnd_plugin_core.plugin_header.plugin_stats.values = mysqlnd_global_stats; mysqlnd_plugin_register_ex((struct st_mysqlnd_plugin_header *) &mysqlnd_plugin_core TSRMLS_CC); } +#if defined(MYSQLND_DBG_ENABLED) && MYSQLND_DBG_ENABLED == 1 mysqlnd_example_plugin_register(TSRMLS_C); +#endif mysqlnd_debug_trace_plugin_register(TSRMLS_C); mysqlnd_register_builtin_authentication_plugins(TSRMLS_C); diff --git a/ext/mysqlnd/mysqlnd_plugin.c b/ext/mysqlnd/mysqlnd_plugin.c index 2dbb57d1c8d5a..61ab1974f81a8 100644 --- a/ext/mysqlnd/mysqlnd_plugin.c +++ b/ext/mysqlnd/mysqlnd_plugin.c @@ -26,7 +26,7 @@ #include "mysqlnd_debug.h" /*--------------------------------------------------------------------*/ - +#if defined(MYSQLND_DBG_ENABLED) && MYSQLND_DBG_ENABLED == 1 static enum_func_status mysqlnd_example_plugin_end(void * p TSRMLS_DC); static MYSQLND_STATS * mysqlnd_plugin_example_stats = NULL; @@ -87,7 +87,7 @@ mysqlnd_example_plugin_register(TSRMLS_D) mysqlnd_plugin_register_ex((struct st_mysqlnd_plugin_header *) &mysqlnd_example_plugin TSRMLS_CC); } /* }}} */ - +#endif /* defined(MYSQLND_DBG_ENABLED) && MYSQLND_DBG_ENABLED == 1 */ /*--------------------------------------------------------------------*/ static HashTable mysqlnd_registered_plugins; From c8b7ea0f57819e675fa2e8c1dfebabb8b3f62ca6 Mon Sep 17 00:00:00 2001 From: Jerome Loyet Date: Fri, 28 Sep 2012 00:55:06 +0200 Subject: [PATCH 2104/2394] - fix merge (fucking git merging system ... :( ) --- sapi/fpm/config.m4 | 653 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 653 insertions(+) diff --git a/sapi/fpm/config.m4 b/sapi/fpm/config.m4 index e69de29bb2d1d..3a2690ee2277f 100644 --- a/sapi/fpm/config.m4 +++ b/sapi/fpm/config.m4 @@ -0,0 +1,653 @@ +dnl +dnl $Id$ +dnl + +PHP_ARG_ENABLE(fpm,, +[ --enable-fpm Enable building of the fpm SAPI executable], no, no) + +dnl configure checks {{{ +AC_DEFUN([AC_FPM_STDLIBS], +[ + AC_CHECK_FUNCS(setenv clearenv setproctitle) + + AC_SEARCH_LIBS(socket, socket) + AC_SEARCH_LIBS(inet_addr, nsl) + + AC_CHECK_HEADERS([errno.h fcntl.h stdio.h stdlib.h unistd.h sys/uio.h]) + AC_CHECK_HEADERS([sys/select.h sys/socket.h sys/time.h]) + AC_CHECK_HEADERS([arpa/inet.h netinet/in.h]) + AC_CHECK_HEADERS([sysexits.h]) +]) + +AC_DEFUN([AC_FPM_PRCTL], +[ + AC_MSG_CHECKING([for prctl]) + + AC_TRY_COMPILE([ #include ], [prctl(0, 0, 0, 0, 0);], [ + AC_DEFINE([HAVE_PRCTL], 1, [do we have prctl?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) + +AC_DEFUN([AC_FPM_CLOCK], +[ + have_clock_gettime=no + + AC_MSG_CHECKING([for clock_gettime]) + + AC_TRY_LINK([ #include ], [struct timespec ts; clock_gettime(CLOCK_MONOTONIC, &ts);], [ + have_clock_gettime=yes + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) + + if test "$have_clock_gettime" = "no"; then + AC_MSG_CHECKING([for clock_gettime in -lrt]) + + SAVED_LIBS="$LIBS" + LIBS="$LIBS -lrt" + + AC_TRY_LINK([ #include ], [struct timespec ts; clock_gettime(CLOCK_MONOTONIC, &ts);], [ + have_clock_gettime=yes + AC_MSG_RESULT([yes]) + ], [ + LIBS="$SAVED_LIBS" + AC_MSG_RESULT([no]) + ]) + fi + + if test "$have_clock_gettime" = "yes"; then + AC_DEFINE([HAVE_CLOCK_GETTIME], 1, [do we have clock_gettime?]) + fi + + have_clock_get_time=no + + if test "$have_clock_gettime" = "no"; then + AC_MSG_CHECKING([for clock_get_time]) + + AC_TRY_RUN([ #include + #include + #include + + int main() + { + kern_return_t ret; clock_serv_t aClock; mach_timespec_t aTime; + ret = host_get_clock_service(mach_host_self(), REALTIME_CLOCK, &aClock); + + if (ret != KERN_SUCCESS) { + return 1; + } + + ret = clock_get_time(aClock, &aTime); + if (ret != KERN_SUCCESS) { + return 2; + } + + return 0; + } + ], [ + have_clock_get_time=yes + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) + fi + + if test "$have_clock_get_time" = "yes"; then + AC_DEFINE([HAVE_CLOCK_GET_TIME], 1, [do we have clock_get_time?]) + fi +]) + +AC_DEFUN([AC_FPM_TRACE], +[ + have_ptrace=no + have_broken_ptrace=no + + AC_MSG_CHECKING([for ptrace]) + + AC_TRY_COMPILE([ + #include + #include ], [ptrace(0, 0, (void *) 0, 0);], [ + have_ptrace=yes + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) + + if test "$have_ptrace" = "yes"; then + AC_MSG_CHECKING([whether ptrace works]) + + AC_TRY_RUN([ + #include + #include + #include + #include + #include + #include + + #if !defined(PTRACE_ATTACH) && defined(PT_ATTACH) + #define PTRACE_ATTACH PT_ATTACH + #endif + + #if !defined(PTRACE_DETACH) && defined(PT_DETACH) + #define PTRACE_DETACH PT_DETACH + #endif + + #if !defined(PTRACE_PEEKDATA) && defined(PT_READ_D) + #define PTRACE_PEEKDATA PT_READ_D + #endif + + int main() + { + long v1 = (unsigned int) -1; /* copy will fail if sizeof(long) == 8 and we've got "int ptrace()" */ + long v2; + pid_t child; + int status; + + if ( (child = fork()) ) { /* parent */ + int ret = 0; + + if (0 > ptrace(PTRACE_ATTACH, child, 0, 0)) { + return 2; + } + + waitpid(child, &status, 0); + + #ifdef PT_IO + struct ptrace_io_desc ptio = { + .piod_op = PIOD_READ_D, + .piod_offs = &v1, + .piod_addr = &v2, + .piod_len = sizeof(v1) + }; + + if (0 > ptrace(PT_IO, child, (void *) &ptio, 0)) { + ret = 3; + } + #else + errno = 0; + + v2 = ptrace(PTRACE_PEEKDATA, child, (void *) &v1, 0); + + if (errno) { + ret = 4; + } + #endif + ptrace(PTRACE_DETACH, child, (void *) 1, 0); + + kill(child, SIGKILL); + + return ret ? ret : (v1 != v2); + } + else { /* child */ + sleep(10); + return 0; + } + } + ], [ + AC_MSG_RESULT([yes]) + ], [ + have_ptrace=no + have_broken_ptrace=yes + AC_MSG_RESULT([no]) + ], [ + AC_MSG_RESULT([skipped (cross compiling)]) + ]) + fi + + if test "$have_ptrace" = "yes"; then + AC_DEFINE([HAVE_PTRACE], 1, [do we have ptrace?]) + fi + + have_mach_vm_read=no + + if test "$have_broken_ptrace" = "yes"; then + AC_MSG_CHECKING([for mach_vm_read]) + + AC_TRY_COMPILE([ #include + #include + ], [ + mach_vm_read((vm_map_t)0, (mach_vm_address_t)0, (mach_vm_size_t)0, (vm_offset_t *)0, (mach_msg_type_number_t*)0); + ], [ + have_mach_vm_read=yes + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) + fi + + if test "$have_mach_vm_read" = "yes"; then + AC_DEFINE([HAVE_MACH_VM_READ], 1, [do we have mach_vm_read?]) + fi + + proc_mem_file="" + + if test -r /proc/$$/mem ; then + proc_mem_file="mem" + else + if test -r /proc/$$/as ; then + proc_mem_file="as" + fi + fi + + if test -n "$proc_mem_file" ; then + AC_MSG_CHECKING([for proc mem file]) + + AC_TRY_RUN([ + #define _GNU_SOURCE + #define _FILE_OFFSET_BITS 64 + #include + #include + #include + #include + #include + #include + int main() + { + long v1 = (unsigned int) -1, v2 = 0; + char buf[128]; + int fd; + sprintf(buf, "/proc/%d/$proc_mem_file", getpid()); + fd = open(buf, O_RDONLY); + if (0 > fd) { + return 1; + } + if (sizeof(long) != pread(fd, &v2, sizeof(long), (uintptr_t) &v1)) { + close(fd); + return 1; + } + close(fd); + return v1 != v2; + } + ], [ + AC_MSG_RESULT([$proc_mem_file]) + ], [ + proc_mem_file="" + AC_MSG_RESULT([no]) + ], [ + AC_MSG_RESULT([skipped (cross compiling)]) + ]) + fi + + if test -n "$proc_mem_file"; then + AC_DEFINE_UNQUOTED([PROC_MEM_FILE], "$proc_mem_file", [/proc/pid/mem interface]) + fi + + fpm_trace_type="" + + if test "$have_ptrace" = "yes"; then + fpm_trace_type=ptrace + + elif test -n "$proc_mem_file"; then + fpm_trace_type=pread + + elif test "$have_mach_vm_read" = "yes" ; then + fpm_trace_type=mach + + else + AC_MSG_WARN([FPM Trace - ptrace, pread, or mach: could not be found]) + fi + +]) + +AC_DEFUN([AC_FPM_BUILTIN_ATOMIC], +[ + AC_MSG_CHECKING([if gcc supports __sync_bool_compare_and_swap]) + AC_TRY_LINK(, + [ + int variable = 1; + return (__sync_bool_compare_and_swap(&variable, 1, 2) + && __sync_add_and_fetch(&variable, 1)) ? 1 : 0; + ], + [ + AC_MSG_RESULT([yes]) + AC_DEFINE(HAVE_BUILTIN_ATOMIC, 1, [Define to 1 if gcc supports __sync_bool_compare_and_swap() a.o.]) + ], + [ + AC_MSG_RESULT([no]) + ]) +]) + +AC_DEFUN([AC_FPM_LQ], +[ + have_lq=no + + AC_MSG_CHECKING([for TCP_INFO]) + + AC_TRY_COMPILE([ #include ], [struct tcp_info ti; int x = TCP_INFO;], [ + have_lq=tcp_info + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) + + if test "$have_lq" = "tcp_info"; then + AC_DEFINE([HAVE_LQ_TCP_INFO], 1, [do we have TCP_INFO?]) + fi + + if test "$have_lq" = "no" ; then + AC_MSG_CHECKING([for SO_LISTENQLEN]) + + AC_TRY_COMPILE([ #include ], [int x = SO_LISTENQLIMIT; int y = SO_LISTENQLEN;], [ + have_lq=so_listenq + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) + + if test "$have_lq" = "tcp_info"; then + AC_DEFINE([HAVE_LQ_SO_LISTENQ], 1, [do we have SO_LISTENQxxx?]) + fi + fi +]) +dnl }}} + +AC_DEFUN([AC_FPM_SYSCONF], +[ + AC_MSG_CHECKING([for sysconf]) + + AC_TRY_COMPILE([ #include ], [sysconf(_SC_CLK_TCK);], [ + AC_DEFINE([HAVE_SYSCONF], 1, [do we have sysconf?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_TIMES], +[ + AC_MSG_CHECKING([for times]) + + AC_TRY_COMPILE([ #include ], [struct tms t; times(&t);], [ + AC_DEFINE([HAVE_TIMES], 1, [do we have times?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_KQUEUE], +[ + AC_MSG_CHECKING([for kqueue]) + + AC_TRY_COMPILE( + [ + #include + #include + #include + ], [ + int kfd; + struct kevent k; + kfd = kqueue(); + /* 0 -> STDIN_FILENO */ + EV_SET(&k, 0, EVFILT_READ , EV_ADD | EV_CLEAR, 0, 0, NULL); + ], [ + AC_DEFINE([HAVE_KQUEUE], 1, [do we have kqueue?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_PORT], +[ + AC_MSG_CHECKING([for port framework]) + + AC_TRY_COMPILE( + [ + #include + ], [ + int port; + + port = port_create(); + if (port < 0) { + return 1; + } + ], [ + AC_DEFINE([HAVE_PORT], 1, [do we have port framework?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_DEVPOLL], +[ + AC_MSG_CHECKING([for /dev/poll]) + + AC_TRY_COMPILE( + [ + #include + #include + ], [ + int n, dp; + struct dvpoll dvp; + dp = 0; + dvp.dp_fds = NULL; + dvp.dp_nfds = 0; + dvp.dp_timeout = 0; + n = ioctl(dp, DP_POLL, &dvp) + ], [ + AC_DEFINE([HAVE_DEVPOLL], 1, [do we have /dev/poll?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_EPOLL], +[ + AC_MSG_CHECKING([for epoll]) + + AC_TRY_COMPILE( + [ + #include + ], [ + int epollfd; + struct epoll_event e; + + epollfd = epoll_create(1); + if (epollfd < 0) { + return 1; + } + + e.events = EPOLLIN | EPOLLET; + e.data.fd = 0; + + if (epoll_ctl(epollfd, EPOLL_CTL_ADD, 0, &e) == -1) { + return 1; + } + + e.events = 0; + if (epoll_wait(epollfd, &e, 1, 1) < 0) { + return 1; + } + ], [ + AC_DEFINE([HAVE_EPOLL], 1, [do we have epoll?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_POLL], +[ + AC_MSG_CHECKING([for poll]) + + AC_TRY_COMPILE( + [ + #include + ], [ + struct pollfd fds[2]; + + fds[0].fd = 0; + fds[0].events = POLLIN; + + fds[1].fd = 0; + fds[1].events = POLLIN; + + poll(fds, 2, 1); + ], [ + AC_DEFINE([HAVE_POLL], 1, [do we have poll?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + +AC_DEFUN([AC_FPM_SELECT], +[ + AC_MSG_CHECKING([for select]) + + AC_TRY_COMPILE( + [ + /* According to POSIX.1-2001 */ + #include + + /* According to earlier standards */ + #include + #include + #include + ], [ + fd_set fds; + struct timeval t; + t.tv_sec = 0; + t.tv_usec = 42; + FD_ZERO(&fds); + /* 0 -> STDIN_FILENO */ + FD_SET(0, &fds); + select(FD_SETSIZE, &fds, NULL, NULL, &t); + ], [ + AC_DEFINE([HAVE_SELECT], 1, [do we have select?]) + AC_MSG_RESULT([yes]) + ], [ + AC_MSG_RESULT([no]) + ]) +]) +dnl }}} + + +AC_MSG_CHECKING(for FPM build) +if test "$PHP_FPM" != "no"; then + AC_MSG_RESULT($PHP_FPM) + + AC_FPM_STDLIBS + AC_FPM_PRCTL + AC_FPM_CLOCK + AC_FPM_TRACE + AC_FPM_BUILTIN_ATOMIC + AC_FPM_LQ + AC_FPM_SYSCONF + AC_FPM_TIMES + AC_FPM_KQUEUE + AC_FPM_PORT + AC_FPM_DEVPOLL + AC_FPM_EPOLL + AC_FPM_POLL + AC_FPM_SELECT + + PHP_ARG_WITH(fpm-user,, + [ --with-fpm-user[=USER] Set the user for php-fpm to run as. (default: nobody)], nobody, no) + + PHP_ARG_WITH(fpm-group,, + [ --with-fpm-group[=GRP] Set the group for php-fpm to run as. For a system user, this + should usually be set to match the fpm username (default: nobody)], nobody, no) + + if test -z "$PHP_FPM_USER" -o "$PHP_FPM_USER" = "yes" -o "$PHP_FPM_USER" = "no"; then + php_fpm_user="nobody" + else + php_fpm_user="$PHP_FPM_USER" + fi + + if test -z "$PHP_FPM_GROUP" -o "$PHP_FPM_GROUP" = "yes" -o "$PHP_FPM_GROUP" = "no"; then + php_fpm_group="nobody" + else + php_fpm_group="$PHP_FPM_GROUP" + fi + + PHP_SUBST_OLD(php_fpm_user) + PHP_SUBST_OLD(php_fpm_group) + php_fpm_sysconfdir=`eval echo $sysconfdir` + PHP_SUBST_OLD(php_fpm_sysconfdir) + php_fpm_localstatedir=`eval echo $localstatedir` + PHP_SUBST_OLD(php_fpm_localstatedir) + php_fpm_prefix=`eval echo $prefix` + PHP_SUBST_OLD(php_fpm_prefix) + + AC_DEFINE_UNQUOTED(PHP_FPM_USER, "$php_fpm_user", [fpm user name]) + AC_DEFINE_UNQUOTED(PHP_FPM_GROUP, "$php_fpm_group", [fpm group name]) + + PHP_ADD_BUILD_DIR(sapi/fpm/fpm) + PHP_ADD_BUILD_DIR(sapi/fpm/fpm/events) + PHP_OUTPUT(sapi/fpm/php-fpm.conf sapi/fpm/init.d.php-fpm sapi/fpm/php-fpm.service sapi/fpm/php-fpm.8 sapi/fpm/status.html) + PHP_ADD_MAKEFILE_FRAGMENT([$abs_srcdir/sapi/fpm/Makefile.frag]) + + SAPI_FPM_PATH=sapi/fpm/php-fpm + + if test "$fpm_trace_type" && test -f "$abs_srcdir/sapi/fpm/fpm/fpm_trace_$fpm_trace_type.c"; then + PHP_FPM_TRACE_FILES="fpm/fpm_trace.c fpm/fpm_trace_$fpm_trace_type.c" + fi + + PHP_FPM_CFLAGS="-I$abs_srcdir/sapi/fpm" + + PHP_FPM_FILES="fpm/fastcgi.c \ + fpm/fpm.c \ + fpm/fpm_children.c \ + fpm/fpm_cleanup.c \ + fpm/fpm_clock.c \ + fpm/fpm_conf.c \ + fpm/fpm_env.c \ + fpm/fpm_events.c \ + fpm/fpm_log.c \ + fpm/fpm_main.c \ + fpm/fpm_php.c \ + fpm/fpm_php_trace.c \ + fpm/fpm_process_ctl.c \ + fpm/fpm_request.c \ + fpm/fpm_shm.c \ + fpm/fpm_scoreboard.c \ + fpm/fpm_signals.c \ + fpm/fpm_sockets.c \ + fpm/fpm_status.c \ + fpm/fpm_stdio.c \ + fpm/fpm_unix.c \ + fpm/fpm_worker_pool.c \ + fpm/zlog.c \ + fpm/events/select.c \ + fpm/events/poll.c \ + fpm/events/epoll.c \ + fpm/events/kqueue.c \ + fpm/events/devpoll.c \ + fpm/events/port.c \ + " + + PHP_SELECT_SAPI(fpm, program, $PHP_FPM_FILES $PHP_FPM_TRACE_FILES, $PHP_FPM_CFLAGS, '$(SAPI_FPM_PATH)') + + case $host_alias in + *aix*) + BUILD_FPM="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg \`echo \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_FPM_OBJS) | sed 's/\([A-Za-z0-9_]*\)\.lo/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") || (\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) { print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_FPM_OBJS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" + ;; + *darwin*) + BUILD_FPM="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" + ;; + *) + BUILD_FPM="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_FPM_OBJS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" + ;; + esac + + PHP_SUBST(SAPI_FPM_PATH) + PHP_SUBST(BUILD_FPM) + +else + AC_MSG_RESULT(no) +fi From 9ed421e3d7333bf68c0252000b98400cc6bc0cbf Mon Sep 17 00:00:00 2001 From: Jerome Loyet Date: Fri, 28 Sep 2012 01:09:31 +0200 Subject: [PATCH 2105/2394] - Fixed bug #62947 (Unneccesary warnings on FPM) --- sapi/fpm/fpm/fpm_unix.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sapi/fpm/fpm/fpm_unix.c b/sapi/fpm/fpm/fpm_unix.c index 1a7594495a01e..48249e8a49488 100644 --- a/sapi/fpm/fpm/fpm_unix.c +++ b/sapi/fpm/fpm/fpm_unix.c @@ -121,16 +121,16 @@ static int fpm_unix_conf_wp(struct fpm_worker_pool_s *wp) /* {{{ */ } } else { /* not root */ if (wp->config->user && *wp->config->user) { - zlog(ZLOG_WARNING, "[pool %s] 'user' directive is ignored when FPM is not running as root", wp->config->name); + zlog(ZLOG_NOTICE, "[pool %s] 'user' directive is ignored when FPM is not running as root", wp->config->name); } if (wp->config->group && *wp->config->group) { - zlog(ZLOG_WARNING, "[pool %s] 'group' directive is ignored when FPM is not running as root", wp->config->name); + zlog(ZLOG_NOTICE, "[pool %s] 'group' directive is ignored when FPM is not running as root", wp->config->name); } if (wp->config->chroot && *wp->config->chroot) { - zlog(ZLOG_WARNING, "[pool %s] 'chroot' directive is ignored when FPM is not running as root", wp->config->name); + zlog(ZLOG_NOTICE, "[pool %s] 'chroot' directive is ignored when FPM is not running as root", wp->config->name); } if (wp->config->process_priority != 64) { - zlog(ZLOG_WARNING, "[pool %s] 'process.priority' directive is ignored when FPM is not running as root", wp->config->name); + zlog(ZLOG_NOTICE, "[pool %s] 'process.priority' directive is ignored when FPM is not running as root", wp->config->name); } /* set up HOME and USER anyway */ @@ -350,7 +350,7 @@ int fpm_unix_init_main() /* {{{ */ return -1; } } else { - zlog(ZLOG_WARNING, "'process.priority' directive is ignored when FPM is not running as root"); + zlog(ZLOG_NOTICE, "'process.priority' directive is ignored when FPM is not running as root"); } } From 68eb608f3c639b2f03304e5794cd99f1074b67c0 Mon Sep 17 00:00:00 2001 From: Jerome Loyet Date: Fri, 28 Sep 2012 01:26:20 +0200 Subject: [PATCH 2106/2394] - Fixed bug #62887 (Only /status?plain&full gives "last request cpu") --- sapi/fpm/fpm/fpm_status.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/sapi/fpm/fpm/fpm_status.c b/sapi/fpm/fpm/fpm_status.c index b9b9a8c0b6f1b..2363b57f8011d 100644 --- a/sapi/fpm/fpm/fpm_status.c +++ b/sapi/fpm/fpm/fpm_status.c @@ -148,7 +148,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "start time%s\n" "start since%lu\n" "accepted conn%lu\n" -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "listen queue%u\n" "max listen queue%u\n" "listen queue len%d\n" @@ -178,7 +178,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "content length" "user" "script" -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "last request cpu" #endif "last request memory" @@ -197,7 +197,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "%zu" "%s" "%s" -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "%.2f" #endif "%zu" @@ -220,7 +220,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "%s\n" "%lu\n" "%lu\n" -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "%u\n" "%u\n" "%d\n" @@ -249,7 +249,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "%zu" "%s" "" -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "%.2f" #endif "%zu" @@ -270,7 +270,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "\"start time\":%s," "\"start since\":%lu," "\"accepted conn\":%lu," -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "\"listen queue\":%u," "\"max listen queue\":%u," "\"listen queue len\":%d," @@ -300,7 +300,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "\"content length\":%zu," "\"user\":\"%s\"," "\"script\":\"%s\"," -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "\"last request cpu\":%.2f," #endif "\"last request memory\":%zu" @@ -320,7 +320,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ "start time: %s\n" "start since: %lu\n" "accepted conn: %lu\n" -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ "listen queue: %u\n" "max listen queue: %u\n" "listen queue len: %d\n" @@ -362,7 +362,7 @@ int fpm_status_handle_request(TSRMLS_D) /* {{{ */ time_buffer, now_epoch - scoreboard.start_epoch, scoreboard.requests, -#if HAVE_FPM_LQ +#ifdef HAVE_FPM_LQ scoreboard.lq, scoreboard.lq_max, scoreboard.lq_len, From c540fe2064d23e7e9de665f12d5452ce914991ff Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 28 Sep 2012 11:58:41 +0200 Subject: [PATCH 2107/2394] fix login failure with empty password. This is 5.5 specific - new code --- ext/mysqlnd/mysqlnd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 3fa9d11a28488..557924cdaf272 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -582,8 +582,8 @@ mysqlnd_run_authentication( scrambled_data = auth_plugin->methods.get_auth_data(NULL, &scrambled_data_len, conn, user, passwd, passwd_len, plugin_data, plugin_data_len, options, &conn->net->data->options, mysql_flags TSRMLS_CC); - if (!scrambled_data || conn->error_info->error_no) { - goto end; + if (conn->error_info->error_no) { + goto end; } if (FALSE == is_change_user) { ret = mysqlnd_auth_handshake(conn, user, passwd, passwd_len, db, db_len, options, mysql_flags, From a2098ca9eb0176a18cfdbf3b5b597f461d21ad8a Mon Sep 17 00:00:00 2001 From: ULF WENDEL Date: Sat, 29 Sep 2012 09:47:23 +0200 Subject: [PATCH 2108/2394] SHA256 authentication tests --- ext/mysqli/tests/mysqli_pam_sha256.phpt | 113 +++++++++++ .../mysqli_pam_sha256_public_key_ini.phpt | 129 ++++++++++++ .../mysqli_pam_sha256_public_key_option.phpt | 132 +++++++++++++ ..._pam_sha256_public_key_option_invalid.phpt | 186 ++++++++++++++++++ 4 files changed, 560 insertions(+) create mode 100644 ext/mysqli/tests/mysqli_pam_sha256.phpt create mode 100644 ext/mysqli/tests/mysqli_pam_sha256_public_key_ini.phpt create mode 100644 ext/mysqli/tests/mysqli_pam_sha256_public_key_option.phpt create mode 100644 ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt diff --git a/ext/mysqli/tests/mysqli_pam_sha256.phpt b/ext/mysqli/tests/mysqli_pam_sha256.phpt new file mode 100644 index 0000000000000..3016e200d727b --- /dev/null +++ b/ext/mysqli/tests/mysqli_pam_sha256.phpt @@ -0,0 +1,113 @@ +--TEST-- +PAM: SHA-256 +--SKIPIF-- +query("SHOW PLUGINS"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +$found = false; +while ($row = $res->fetch_assoc()) { + if (($row['Name'] == 'sha256_password') && ($row['Status'] == 'ACTIVE')) { + $found = true; + break; + } +} +if (!$found) + die("skip SHA-256 server plugin unavailable"); + +if (!($res = $link->query("SHOW STATUS LIKE 'Rsa_public_key'"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +if (!($row = $res->fetch_assoc())) { + die(sprintf("skip Failed to check RSA pub key, [%d] %s\n", $link->errno, $link->error)); +} + +if (strlen($row['Value']) < 100) { + die(sprintf("skip Server misconfiguration? RSA pub key is suspicious, [%d] %s\n", $link->errno, $link->error)); +} + +if (!$link->query("SET @@session.old_passwords=2")) { + die(sprintf("skip Cannot set @@session.old_passwords=2 [%d] %s", $link->errno, $link->error)); +} + +$link->query('DROP USER shatest'); +$link->query("DROP USER shatest@localhost"); + + +if (!$link->query('CREATE USER shatest@"%" IDENTIFIED WITH sha256_password') || + !$link->query('CREATE USER shatest@"localhost" IDENTIFIED WITH sha256_password')) { + die(sprintf("skip CREATE USER failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query('SET PASSWORD FOR shatest@"%" = PASSWORD("shatest")') || + !$link->query('SET PASSWORD FOR shatest@"localhost" = PASSWORD("shatest")')) { + die(sprintf("skip SET PASSWORD failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query("DROP TABLE IF EXISTS test") || + !$link->query("CREATE TABLE test (id INT)") || + !$link->query("INSERT INTO test(id) VALUES (1), (2), (3)")) + die(sprintf("SKIP [%d] %s\n", $link->errno, $link->error)); + + +if (!$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'%%'", $db)) || + !$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'localhost'", $db))) { + die(sprintf("skip Cannot grant SELECT to user [%d] %s", mysqli_errno($link), mysqli_error($link))); +} + +$link->close(); +?> +--FILE-- +query("SELECT id FROM test WHERE id = 1")) + printf("[002] [%d] %s\n", $link->errno, $link->error); + + if (!$row = mysqli_fetch_assoc($res)) { + printf("[003] [%d] %s\n", $link->errno, $link->error); + } + + if ($row['id'] != 1) { + printf("[004] Expecting 1 got %s/'%s'", gettype($row['id']), $row['id']); + } + + $res->close(); + $link->close(); + } + + print "done!"; +?> +--CLEAN-- +query('DROP USER shatest'); + $link->query('DROP USER shatest@localhost'); +?> +--EXPECTF-- +done! \ No newline at end of file diff --git a/ext/mysqli/tests/mysqli_pam_sha256_public_key_ini.phpt b/ext/mysqli/tests/mysqli_pam_sha256_public_key_ini.phpt new file mode 100644 index 0000000000000..27bbed138ceee --- /dev/null +++ b/ext/mysqli/tests/mysqli_pam_sha256_public_key_ini.phpt @@ -0,0 +1,129 @@ +--TEST-- +PAM: SHA-256, mysqlnd.sha256_server_public_key +--SKIPIF-- +query("SHOW PLUGINS"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +$found = false; +while ($row = $res->fetch_assoc()) { + if (($row['Name'] == 'sha256_password') && ($row['Status'] == 'ACTIVE')) { + $found = true; + break; + } +} +if (!$found) + die("skip SHA-256 server plugin unavailable"); + +if (!($res = $link->query("SHOW STATUS LIKE 'Rsa_public_key'"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +if (!($row = $res->fetch_assoc())) { + die(sprintf("skip Failed to check RSA pub key, [%d] %s\n", $link->errno, $link->error)); +} + +$key = $row['Value']; +if (strlen($key) < 100) { + die(sprintf("skip Server misconfiguration? RSA pub key is suspicious, [%d] %s\n", $link->errno, $link->error)); +} + +/* date changes may give false positive */ +$file = "test_sha256_ini"; +if ((file_exists($file) && !unlink($file)) || !($fp = @fopen($file, "w"))) { + die(sprintf("skip Cannot create RSA pub key file '%s'", $file)); +} +$key = str_replace("A", "a", $key); +$key = str_replace("M", "m", $key); +if (strlen($key) != fwrite($fp, $key)) { + die(sprintf("skip Failed to create pub key file")); +} + + +if (!$link->query("SET @@session.old_passwords=2")) { + die(sprintf("skip Cannot set @@session.old_passwords=2 [%d] %s", $link->errno, $link->error)); +} + +$link->query('DROP USER shatest'); +$link->query("DROP USER shatest@localhost"); + + +if (!$link->query('CREATE USER shatest@"%" IDENTIFIED WITH sha256_password') || + !$link->query('CREATE USER shatest@"localhost" IDENTIFIED WITH sha256_password')) { + die(sprintf("skip CREATE USER failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query('SET PASSWORD FOR shatest@"%" = PASSWORD("shatest")') || + !$link->query('SET PASSWORD FOR shatest@"localhost" = PASSWORD("shatest")')) { + die(sprintf("skip SET PASSWORD failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query("DROP TABLE IF EXISTS test") || + !$link->query("CREATE TABLE test (id INT)") || + !$link->query("INSERT INTO test(id) VALUES (1), (2), (3)")) + die(sprintf("SKIP [%d] %s\n", $link->errno, $link->error)); + + +if (!$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'%%'", $db)) || + !$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'localhost'", $db))) { + die(sprintf("skip Cannot grant SELECT to user [%d] %s", mysqli_errno($link), mysqli_error($link))); +} + +$link->close(); +?> +--INI-- +mysqlnd.sha256_server_public_key="test_sha256_ini" +--FILE-- +connect_errno) { + printf("[001] [%d] %s\n", $link->connect_errno, $link->connect_error); + } else { + if (!$res = $link->query("SELECT id FROM test WHERE id = 1")) + printf("[002] [%d] %s\n", $link->errno, $link->error); + + if (!$row = mysqli_fetch_assoc($res)) { + printf("[003] [%d] %s\n", $link->errno, $link->error); + } + + if ($row['id'] != 1) { + printf("[004] Expecting 1 got %s/'%s'", gettype($row['id']), $row['id']); + } + } + print "done!"; +?> +--CLEAN-- +query('DROP USER shatest'); + $link->query('DROP USER shatest@localhost'); + $file = "test_sha256_ini"; + @unlink($file); +?> +--EXPECTF-- + +Warning: mysqli::mysqli(): (HY000/1045): %s in %s on line %d +[001] [1045] %s +done! \ No newline at end of file diff --git a/ext/mysqli/tests/mysqli_pam_sha256_public_key_option.phpt b/ext/mysqli/tests/mysqli_pam_sha256_public_key_option.phpt new file mode 100644 index 0000000000000..afed773b017d0 --- /dev/null +++ b/ext/mysqli/tests/mysqli_pam_sha256_public_key_option.phpt @@ -0,0 +1,132 @@ +--TEST-- +PAM: SHA-256, option: MYSQLI_SERVER_PUBLIC_KEY +--SKIPIF-- +query("SHOW PLUGINS"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +$found = false; +while ($row = $res->fetch_assoc()) { + if (($row['Name'] == 'sha256_password') && ($row['Status'] == 'ACTIVE')) { + $found = true; + break; + } +} +if (!$found) + die("skip SHA-256 server plugin unavailable"); + +if (!($res = $link->query("SHOW STATUS LIKE 'Rsa_public_key'"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +if (!($row = $res->fetch_assoc())) { + die(sprintf("skip Failed to check RSA pub key, [%d] %s\n", $link->errno, $link->error)); +} + +if (strlen($row['Value']) < 100) { + die(sprintf("skip Server misconfiguration? RSA pub key is suspicious, [%d] %s\n", $link->errno, $link->error)); +} + +/* date changes may give false positive */ +$file = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_" , @date("Ymd")); +if ((file_exists($file) && !unlink($file)) || !($fp = @fopen($file, "w"))) { + die(sprintf("skip Cannot create RSA pub key file '%s'", $file)); +} +if (strlen($row['Value']) != fwrite($fp, $row['Value'])) { + die(sprintf("skip Failed to create pub key file")); +} + + +if (!$link->query("SET @@session.old_passwords=2")) { + die(sprintf("skip Cannot set @@session.old_passwords=2 [%d] %s", $link->errno, $link->error)); +} + +$link->query('DROP USER shatest'); +$link->query("DROP USER shatest@localhost"); + + +if (!$link->query('CREATE USER shatest@"%" IDENTIFIED WITH sha256_password') || + !$link->query('CREATE USER shatest@"localhost" IDENTIFIED WITH sha256_password')) { + die(sprintf("skip CREATE USER failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query('SET PASSWORD FOR shatest@"%" = PASSWORD("shatest")') || + !$link->query('SET PASSWORD FOR shatest@"localhost" = PASSWORD("shatest")')) { + die(sprintf("skip SET PASSWORD failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query("DROP TABLE IF EXISTS test") || + !$link->query("CREATE TABLE test (id INT)") || + !$link->query("INSERT INTO test(id) VALUES (1), (2), (3)")) + die(sprintf("SKIP [%d] %s\n", $link->errno, $link->error)); + + +if (!$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'%%'", $db)) || + !$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'localhost'", $db))) { + die(sprintf("skip Cannot grant SELECT to user [%d] %s", mysqli_errno($link), mysqli_error($link))); +} + +$link->close(); +?> +--FILE-- +options(MYSQLI_SERVER_PUBLIC_KEY, $file))) { + printf("[001] mysqli_options failed, [%d] %s\n", $link->errno, $link->error); + } + + if (!$link->real_connect($host, 'shatest', 'shatest', $db, $port, $socket)) { + printf("[002] [%d] %s\n", $link->connect_errno, $link->connect_error); + } + + if (!$res = $link->query("SELECT id FROM test WHERE id = 1")) + printf("[003] [%d] %s\n", $link->errno, $link->error); + + if (!$row = mysqli_fetch_assoc($res)) { + printf("[004] [%d] %s\n", $link->errno, $link->error); + } + + if ($row['id'] != 1) { + printf("[005] Expecting 1 got %s/'%s'", gettype($row['id']), $row['id']); + } + + $res->close(); + $link->close(); + } + + print "done!"; +?> +--CLEAN-- +query('DROP USER shatest'); + $link->query('DROP USER shatest@localhost'); + $file = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_" , @date("Ymd")); + @unlink($file); +?> +--EXPECTF-- +done! \ No newline at end of file diff --git a/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt b/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt new file mode 100644 index 0000000000000..960f08ad48122 --- /dev/null +++ b/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt @@ -0,0 +1,186 @@ +--TEST-- +PAM: SHA-256, option: MYSQLI_SERVER_PUBLIC_KEY (invalid) +--SKIPIF-- +query("SHOW PLUGINS"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +$found = false; +while ($row = $res->fetch_assoc()) { + if (($row['Name'] == 'sha256_password') && ($row['Status'] == 'ACTIVE')) { + $found = true; + break; + } +} +if (!$found) + die("skip SHA-256 server plugin unavailable"); + +if (!($res = $link->query("SHOW STATUS LIKE 'Rsa_public_key'"))) { + die(sprintf("skip [%d] %s\n", $link->errno, $link->error)); +} + +if (!($row = $res->fetch_assoc())) { + die(sprintf("skip Failed to check RSA pub key, [%d] %s\n", $link->errno, $link->error)); +} + +if (strlen($row['Value']) < 100) { + die(sprintf("skip Server misconfiguration? RSA pub key is suspicious, [%d] %s\n", $link->errno, $link->error)); +} + +/* date changes may give false positive */ +$file = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_" , @date("Ymd")); +if ((file_exists($file) && !unlink($file)) || !($fp = @fopen($file, "w"))) { + die(sprintf("skip Cannot create RSA pub key file '%s'", $file)); +} +if (strlen($row['Value']) != fwrite($fp, $row['Value'])) { + die(sprintf("skip Failed to create pub key file")); +} + + +if (!$link->query("SET @@session.old_passwords=2")) { + die(sprintf("skip Cannot set @@session.old_passwords=2 [%d] %s", $link->errno, $link->error)); +} + +$link->query('DROP USER shatest'); +$link->query("DROP USER shatest@localhost"); + + +if (!$link->query('CREATE USER shatest@"%" IDENTIFIED WITH sha256_password') || + !$link->query('CREATE USER shatest@"localhost" IDENTIFIED WITH sha256_password')) { + die(sprintf("skip CREATE USER failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query('SET PASSWORD FOR shatest@"%" = PASSWORD("shatest")') || + !$link->query('SET PASSWORD FOR shatest@"localhost" = PASSWORD("shatest")')) { + die(sprintf("skip SET PASSWORD failed [%d] %s", $link->errno, $link->error)); +} + +if (!$link->query("DROP TABLE IF EXISTS test") || + !$link->query("CREATE TABLE test (id INT)") || + !$link->query("INSERT INTO test(id) VALUES (1), (2), (3)")) + die(sprintf("SKIP [%d] %s\n", $link->errno, $link->error)); + + +if (!$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'%%'", $db)) || + !$link->query(sprintf("GRANT SELECT ON TABLE %s.test TO shatest@'localhost'", $db))) { + die(sprintf("skip Cannot grant SELECT to user [%d] %s", mysqli_errno($link), mysqli_error($link))); +} + +$link->close(); +?> +--FILE-- +options(MYSQLI_SERVER_PUBLIC_KEY, $file))) { + printf("[%03d + 001] mysqli_options failed, [%d] %s\n", $offset, $link->errno, $link->error); + return false; + } + + if (!$link->real_connect($host, 'shatest', 'shatest', $db, $port, $socket)) { + printf("[%03d + 002] [%d] %s\n", $offset, $link->connect_errno, $link->connect_error); + return false; + } + + if (!$res = $link->query("SELECT id FROM test WHERE id = 1")) + printf("[%03d + 003] [%d] %s\n", $offset, $link->errno, $link->error); + return false; + + if (!$row = mysqli_fetch_assoc($res)) { + printf("[%03d + 004] [%d] %s\n", $offset, $link->errno, $link->error); + return false; + } + + if ($row['id'] != 1) { + printf("[%03d + 005] Expecting 1 got %s/'%s'", $offset, gettype($row['id']), $row['id']); + return false; + } + + $res->close(); + $link->close(); + return true; + } + + $file = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_" , @date("Ymd")); + if (file_exists($file) && is_readable($file)) { + + /* valid key */ + sha_connect(100, $host, $db, $port, $socket, $file); + + /* invalid key */ + $file_wrong = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_wrong" , @date("Ymd")); + + $key = file_get_contents($file); + $key = str_replace("A", "a", $key); + $key = str_replace("M", "m", $key); + @unlink($file_wrong); + if (!($fp = fopen($file_wrong, "w"))) { + printf("[002] Can't write public key file."); + } else { + fwrite($fp, $key); + fclose($fp); + sha_connect(200, $host, $db, $port, $socket, $file_wrong); + } + + /* empty file */ + @unlink($file_wrong); + if (!($fp = fopen($file_wrong, "w"))) { + printf("[003] Can't write public key file."); + } else { + fwrite($fp, ""); + fclose($fp); + sha_connect(300, $host, $db, $port, $socket, $file_wrong); + } + + /* file does not exist */ + @unlink($file_wrong); + sha_connect(400, $host, $db, $port, $socket, $file_wrong); + + } else { + printf("[001] Cannot read public key file."); + } + + print "done!"; +?> +--CLEAN-- +query('DROP USER shatest'); + $link->query('DROP USER shatest@localhost'); + $file = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_" , @date("Ymd")); + @unlink($file); + $file_wrong = sprintf("%s%s%s_%s", sys_get_temp_dir(), DIRECTORY_SEPARATOR, "test_sha256_wrong" , @date("Ymd")); + @unlink($file_wrong); +?> +--EXPECTF-- +Warning: mysqli::real_connect(): (HY000/1045): %s in %s on line %d +[200 + 002] [1045] %s + +Warning: mysqli::real_connect(): (HY000/1045): %s in %s on line %d +[300 + 002] [1045] %s + +Warning: mysqli::real_connect(%sest_sha256_wrong_%d): failed to open stream: No such file or directory in %s on line %d +[400 + 002] [1045] %s +done! \ No newline at end of file From 225792c5db2306727710d232effb86a3abf09feb Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 12 Oct 2012 10:20:09 +0200 Subject: [PATCH 2109/2394] constify --- ext/mysqlnd/mysqlnd.c | 2 +- ext/mysqlnd/mysqlnd_auth.c | 1 + ext/mysqlnd/mysqlnd_structs.h | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index f5fe075c50e0a..ad91212f2a954 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -1924,7 +1924,7 @@ MYSQLND_METHOD_PRIVATE(mysqlnd_conn_data, free_reference)(MYSQLND_CONN_DATA * co /* {{{ mysqlnd_conn_data::get_state */ static enum mysqlnd_connection_state -MYSQLND_METHOD_PRIVATE(mysqlnd_conn_data, get_state)(MYSQLND_CONN_DATA * const conn TSRMLS_DC) +MYSQLND_METHOD_PRIVATE(mysqlnd_conn_data, get_state)(const MYSQLND_CONN_DATA * const conn TSRMLS_DC) { DBG_ENTER("mysqlnd_conn_data::get_state"); DBG_RETURN(conn->state); diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index f2c5adcc4df2a..3cae693de4ef3 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -581,6 +581,7 @@ mysqlnd_sha256_auth_get_auth_data(struct st_mysqlnd_authentication_plugin * self if (conn->net->data->ssl) { + DBG_INF("simple clear text under SSL"); /* clear text under SSL */ *auth_data_len = passwd_len; ret = malloc(passwd_len); diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 7f512b7211f7d..28def72599f32 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -463,7 +463,7 @@ typedef enum_func_status (*func_mysqlnd_conn_data__query_read_result_set_header) typedef MYSQLND_CONN_DATA * (*func_mysqlnd_conn_data__get_reference)(MYSQLND_CONN_DATA * const conn TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__free_reference)(MYSQLND_CONN_DATA * const conn TSRMLS_DC); -typedef enum mysqlnd_connection_state (*func_mysqlnd_conn_data__get_state)(MYSQLND_CONN_DATA * const conn TSRMLS_DC); +typedef enum mysqlnd_connection_state (*func_mysqlnd_conn_data__get_state)(const MYSQLND_CONN_DATA * const conn TSRMLS_DC); typedef void (*func_mysqlnd_conn_data__set_state)(MYSQLND_CONN_DATA * const conn, enum mysqlnd_connection_state new_state TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__simple_command)(MYSQLND_CONN_DATA * conn, enum php_mysqlnd_server_command command, const zend_uchar * const arg, size_t arg_len, enum mysqlnd_packet_type ok_packet, zend_bool silent, zend_bool ignore_upsert_status TSRMLS_DC); From 6fbcf693750d682b223660d3299a0b6864915acc Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 12 Oct 2012 10:35:45 +0200 Subject: [PATCH 2110/2394] fix test --- ext/mysqli/tests/mysqli_constants.phpt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ext/mysqli/tests/mysqli_constants.phpt b/ext/mysqli/tests/mysqli_constants.phpt index 613dddfc85d5e..0f87187216fef 100644 --- a/ext/mysqli/tests/mysqli_constants.phpt +++ b/ext/mysqli/tests/mysqli_constants.phpt @@ -125,6 +125,12 @@ require_once('skipifconnectfailure.inc'); $expected_constants['MYSQLI_SERVER_QUERY_WAS_SLOW'] = true; } + + /* First introduced in MySQL 6.0, backported to MySQL 5.5 */ + if ($version >= 50606 || $IS_MYSQLND) { + $expected_constants['MYSQLI_SERVER_PUBLIC_KEY'] = true; + } + if ($version > 50002) { $expected_constants = array_merge($expected_constants, array( "MYSQLI_TYPE_NEWDECIMAL" => true, From 22611b8d3774cff379cc51666842ab4b8a2eaf7f Mon Sep 17 00:00:00 2001 From: George Wang Date: Fri, 12 Oct 2012 13:04:22 -0400 Subject: [PATCH 2111/2394] sapi/litespeed/lsapi_main.c: Fix bug #63228 Fix compiling error at line 606 (error: format not a string literal and no format arguments [-Werror=format-security] --- sapi/litespeed/lsapi_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sapi/litespeed/lsapi_main.c b/sapi/litespeed/lsapi_main.c index bb532d83620f3..70583426c4679 100644 --- a/sapi/litespeed/lsapi_main.c +++ b/sapi/litespeed/lsapi_main.c @@ -603,7 +603,7 @@ static void cli_usage( TSRMLS_D ) " args... Arguments passed to script.\n"; php_output_startup(); php_output_activate(TSRMLS_C); - php_printf( usage ); + php_printf( "%s", usage ); #ifdef PHP_OUTPUT_NEWAPI php_output_end_all(TSRMLS_C); #else From 4a7d18c79ef956022090cf7e8159ca6d50ae2339 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Fri, 5 Oct 2012 15:31:58 -0400 Subject: [PATCH 2112/2394] Fix some double free issues, and more cleanup work --- ext/standard/password.c | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index e8762690bb5b6..87fc2c2a227e1 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -79,7 +79,7 @@ static zend_bool php_password_salt_is_alphabet(const char *str, const size_t len } /* }}} */ -static int php_password_salt_to64(const char *str, const size_t str_len, const size_t out_len, char *ret) /* {{{ */ +static zend_bool php_password_salt_to64(const char *str, const size_t str_len, const size_t out_len, char *ret) /* {{{ */ { size_t pos = 0; size_t ret_len = 0; @@ -108,7 +108,7 @@ static int php_password_salt_to64(const char *str, const size_t str_len, const s } /* }}} */ -static int php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */ +static zend_bool php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */ { int buffer_valid = 0; size_t i, raw_length; @@ -163,9 +163,8 @@ static int php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */ efree(buffer); efree(result); return FAILURE; - } else { - memcpy(ret, result, (int) length); } + memcpy(ret, result, (int) length); efree(result); efree(buffer); ret[length] = 0; @@ -245,9 +244,13 @@ PHP_FUNCTION(password_needs_rehash) long new_cost = PHP_PASSWORD_BCRYPT_COST, cost = 0; if (options && zend_symtable_find(options, "cost", sizeof("cost"), (void **) &option_buffer) == SUCCESS) { - convert_to_long_ex(option_buffer); - new_cost = Z_LVAL_PP(option_buffer); - zval_ptr_dtor(option_buffer); + if (Z_TYPE_PP(option_buffer) != IS_LONG) { + convert_to_long_ex(option_buffer); + new_cost = Z_LVAL_PP(option_buffer); + zval_ptr_dtor(option_buffer); + } else { + new_cost = Z_LVAL_PP(option_buffer); + } } sscanf(hash, "$2y$%ld$", &cost); @@ -319,9 +322,13 @@ PHP_FUNCTION(password_hash) long cost = PHP_PASSWORD_BCRYPT_COST; if (options && zend_symtable_find(options, "cost", 5, (void **) &option_buffer) == SUCCESS) { - convert_to_long_ex(option_buffer); - cost = Z_LVAL_PP(option_buffer); - zval_ptr_dtor(option_buffer); + if (Z_TYPE_PP(option_buffer) != IS_LONG) { + convert_to_long_ex(option_buffer); + cost = Z_LVAL_PP(option_buffer); + zval_ptr_dtor(option_buffer); + } else { + cost = Z_LVAL_PP(option_buffer); + } } if (cost < 4 || cost > 31) { @@ -367,14 +374,12 @@ PHP_FUNCTION(password_hash) case IS_RESOURCE: case IS_ARRAY: default: - zval_ptr_dtor(option_buffer); efree(hash_format); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Non-string salt parameter supplied"); RETURN_NULL(); } if (buffer_len < required_salt_len) { efree(hash_format); - zval_ptr_dtor(option_buffer); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu expecting %lu", (unsigned long) buffer_len, (unsigned long) required_salt_len); RETURN_NULL(); } else if (0 == php_password_salt_is_alphabet(buffer, buffer_len)) { @@ -382,7 +387,6 @@ PHP_FUNCTION(password_hash) if (php_password_salt_to64(buffer, buffer_len, required_salt_len, salt) == FAILURE) { efree(hash_format); efree(salt); - zval_ptr_dtor(option_buffer); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu", (unsigned long) buffer_len); RETURN_NULL(); } @@ -392,7 +396,6 @@ PHP_FUNCTION(password_hash) memcpy(salt, buffer, (int) required_salt_len); salt_len = required_salt_len; } - zval_ptr_dtor(option_buffer); } else { salt = safe_emalloc(required_salt_len, 1, 1); if (php_password_make_salt(required_salt_len, salt TSRMLS_CC) == FAILURE) { From 25b2d364e995fc070ae16ee34f60d25148413769 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Fri, 5 Oct 2012 15:53:40 -0400 Subject: [PATCH 2113/2394] Fix issue with possible memory leak --- ext/standard/password.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 87fc2c2a227e1..af42a6f5b9671 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -350,7 +350,7 @@ PHP_FUNCTION(password_hash) if (options && zend_symtable_find(options, "salt", 5, (void**) &option_buffer) == SUCCESS) { char *buffer; - int buffer_len_int; + int buffer_len_int = 0; size_t buffer_len; switch (Z_TYPE_PP(option_buffer)) { case IS_NULL: @@ -359,17 +359,20 @@ PHP_FUNCTION(password_hash) case IS_DOUBLE: case IS_BOOL: case IS_OBJECT: - convert_to_string_ex(option_buffer); if (Z_TYPE_PP(option_buffer) == IS_STRING) { buffer = Z_STRVAL_PP(option_buffer); buffer_len_int = Z_STRLEN_PP(option_buffer); - if (buffer_len_int < 0) { + break; + } else { + SEPARATE_ZVAL(option_buffer); + convert_to_string_ex(option_buffer); + if (Z_TYPE_PP(option_buffer) == IS_STRING) { + buffer = Z_STRVAL_PP(option_buffer); + buffer_len_int = Z_STRLEN_PP(option_buffer); zval_ptr_dtor(option_buffer); - efree(hash_format); - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied salt is too long"); + break; } - buffer_len = (size_t) buffer_len_int; - break; + zval_ptr_dtor(option_buffer); } case IS_RESOURCE: case IS_ARRAY: @@ -378,6 +381,11 @@ PHP_FUNCTION(password_hash) php_error_docref(NULL TSRMLS_CC, E_WARNING, "Non-string salt parameter supplied"); RETURN_NULL(); } + if (buffer_len_int < 0) { + efree(hash_format); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied salt is too long"); + } + buffer_len = (size_t) buffer_len_int; if (buffer_len < required_salt_len) { efree(hash_format); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu expecting %lu", (unsigned long) buffer_len, (unsigned long) required_salt_len); From 1751d5fabeff466f08da560caa6f92222ade5a82 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Sat, 6 Oct 2012 10:38:41 -0400 Subject: [PATCH 2114/2394] Really fix leaks, add test cases to prove it... --- ext/standard/password.c | 54 +++++++++++-------- .../password/password_bcrypt_errors.phpt | 11 ++++ .../tests/password/password_hash_error.phpt | 5 ++ .../tests/password/password_needs_rehash.phpt | 6 +++ 4 files changed, 54 insertions(+), 22 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index af42a6f5b9671..9667fdcade375 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -245,9 +245,12 @@ PHP_FUNCTION(password_needs_rehash) if (options && zend_symtable_find(options, "cost", sizeof("cost"), (void **) &option_buffer) == SUCCESS) { if (Z_TYPE_PP(option_buffer) != IS_LONG) { - convert_to_long_ex(option_buffer); - new_cost = Z_LVAL_PP(option_buffer); - zval_ptr_dtor(option_buffer); + zval *cast_option_buffer; + ALLOC_ZVAL(cast_option_buffer); + INIT_PZVAL_COPY(cast_option_buffer, *option_buffer); + convert_to_long(cast_option_buffer); + new_cost = Z_LVAL_P(cast_option_buffer); + zval_dtor(cast_option_buffer); } else { new_cost = Z_LVAL_PP(option_buffer); } @@ -323,9 +326,12 @@ PHP_FUNCTION(password_hash) if (options && zend_symtable_find(options, "cost", 5, (void **) &option_buffer) == SUCCESS) { if (Z_TYPE_PP(option_buffer) != IS_LONG) { - convert_to_long_ex(option_buffer); - cost = Z_LVAL_PP(option_buffer); - zval_ptr_dtor(option_buffer); + zval *cast_option_buffer; + ALLOC_ZVAL(cast_option_buffer); + INIT_PZVAL_COPY(cast_option_buffer, *option_buffer); + convert_to_long(cast_option_buffer); + cost = Z_LVAL_P(cast_option_buffer); + zval_dtor(cast_option_buffer); } else { cost = Z_LVAL_PP(option_buffer); } @@ -353,27 +359,27 @@ PHP_FUNCTION(password_hash) int buffer_len_int = 0; size_t buffer_len; switch (Z_TYPE_PP(option_buffer)) { - case IS_NULL: case IS_STRING: + buffer = estrndup(Z_STRVAL_PP(option_buffer), Z_STRLEN_PP(option_buffer)); + buffer_len_int = Z_STRLEN_PP(option_buffer); + break; case IS_LONG: case IS_DOUBLE: - case IS_BOOL: - case IS_OBJECT: - if (Z_TYPE_PP(option_buffer) == IS_STRING) { - buffer = Z_STRVAL_PP(option_buffer); - buffer_len_int = Z_STRLEN_PP(option_buffer); + case IS_OBJECT: { + zval *cast_option_buffer; + ALLOC_ZVAL(cast_option_buffer); + INIT_PZVAL_COPY(cast_option_buffer, *option_buffer); + convert_to_string(cast_option_buffer); + if (Z_TYPE_P(cast_option_buffer) == IS_STRING) { + buffer = estrndup(Z_STRVAL_P(cast_option_buffer), Z_STRLEN_P(cast_option_buffer)); + buffer_len_int = Z_STRLEN_P(cast_option_buffer); + zval_dtor(cast_option_buffer); break; - } else { - SEPARATE_ZVAL(option_buffer); - convert_to_string_ex(option_buffer); - if (Z_TYPE_PP(option_buffer) == IS_STRING) { - buffer = Z_STRVAL_PP(option_buffer); - buffer_len_int = Z_STRLEN_PP(option_buffer); - zval_ptr_dtor(option_buffer); - break; - } - zval_ptr_dtor(option_buffer); } + zval_dtor(cast_option_buffer); + } + case IS_BOOL: + case IS_NULL: case IS_RESOURCE: case IS_ARRAY: default: @@ -383,17 +389,20 @@ PHP_FUNCTION(password_hash) } if (buffer_len_int < 0) { efree(hash_format); + efree(buffer); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied salt is too long"); } buffer_len = (size_t) buffer_len_int; if (buffer_len < required_salt_len) { efree(hash_format); + efree(buffer); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu expecting %lu", (unsigned long) buffer_len, (unsigned long) required_salt_len); RETURN_NULL(); } else if (0 == php_password_salt_is_alphabet(buffer, buffer_len)) { salt = safe_emalloc(required_salt_len, 1, 1); if (php_password_salt_to64(buffer, buffer_len, required_salt_len, salt) == FAILURE) { efree(hash_format); + efree(buffer); efree(salt); php_error_docref(NULL TSRMLS_CC, E_WARNING, "Provided salt is too short: %lu", (unsigned long) buffer_len); RETURN_NULL(); @@ -404,6 +413,7 @@ PHP_FUNCTION(password_hash) memcpy(salt, buffer, (int) required_salt_len); salt_len = required_salt_len; } + efree(buffer); } else { salt = safe_emalloc(required_salt_len, 1, 1); if (php_password_make_salt(required_salt_len, salt TSRMLS_CC) == FAILURE) { diff --git a/ext/standard/tests/password/password_bcrypt_errors.phpt b/ext/standard/tests/password/password_bcrypt_errors.phpt index f36d11f694185..2548c9accb805 100644 --- a/ext/standard/tests/password/password_bcrypt_errors.phpt +++ b/ext/standard/tests/password/password_bcrypt_errors.phpt @@ -12,6 +12,10 @@ var_dump(password_hash("foo", PASSWORD_BCRYPT, array("salt" => "foo"))); var_dump(password_hash("foo", PASSWORD_BCRYPT, array("salt" => "123456789012345678901"))); +var_dump(password_hash("foo", PASSWORD_BCRYPT, array("salt" => 123))); + +var_dump(password_hash("foo", PASSWORD_BCRYPT, array("cost" => "foo"))); + ?> --EXPECTF-- Warning: password_hash(): Invalid bcrypt cost parameter specified: 3 in %s on line %d @@ -26,3 +30,10 @@ NULL Warning: password_hash(): Provided salt is too short: 21 expecting 22 in %s on line %d NULL +Warning: password_hash(): Provided salt is too short: 3 expecting 22 in %s on line %d +NULL + +Warning: password_hash(): Invalid bcrypt cost parameter specified: 0 in %s on line %d +NULL + + diff --git a/ext/standard/tests/password/password_hash_error.phpt b/ext/standard/tests/password/password_hash_error.phpt index 695a6c479ad51..952250cb309b0 100644 --- a/ext/standard/tests/password/password_hash_error.phpt +++ b/ext/standard/tests/password/password_hash_error.phpt @@ -18,6 +18,9 @@ var_dump(password_hash(array(), PASSWORD_BCRYPT)); var_dump(password_hash("123", PASSWORD_BCRYPT, array("salt" => array()))); +/* Non-string salt, checking for memory leaks */ +var_dump(password_hash('123', PASSWORD_BCRYPT, array('salt' => 1234))); + ?> --EXPECTF-- Warning: password_hash() expects at least 2 parameters, 0 given in %s on line %d @@ -41,3 +44,5 @@ NULL Warning: password_hash(): Non-string salt parameter supplied in %s on line %d NULL +Warning: password_hash(): Provided salt is too short: 4 expecting 22 in %s on line %d +NULL diff --git a/ext/standard/tests/password/password_needs_rehash.phpt b/ext/standard/tests/password/password_needs_rehash.phpt index 2fc3983980165..734729e63d705 100644 --- a/ext/standard/tests/password/password_needs_rehash.phpt +++ b/ext/standard/tests/password/password_needs_rehash.phpt @@ -26,6 +26,11 @@ var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9H $cost = str_pad(PASSWORD_BCRYPT_DEFAULT_COST, 2, '0', STR_PAD_LEFT); var_dump(password_needs_rehash('$2y$'.$cost.'$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT)); +// Should Issue Needs Rehash, Since Foo is cast to 0... +var_dump(password_needs_rehash('$2y$10$MTIzNDU2Nzg5MDEyMzQ1Nej0NmcAWSLR.oP7XOR9HD/vjUuOj100y', PASSWORD_BCRYPT, array('cost' => 'foo'))); + + + echo "OK!"; ?> --EXPECT-- @@ -36,4 +41,5 @@ bool(false) bool(true) bool(true) bool(false) +bool(true) OK! From 76e83f769ff5929b45cf0ac666335ce68ada166f Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Sat, 6 Oct 2012 12:33:48 -0400 Subject: [PATCH 2115/2394] fix allocation and copy issue --- ext/standard/password.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 9667fdcade375..70004a9bc8898 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -247,7 +247,7 @@ PHP_FUNCTION(password_needs_rehash) if (Z_TYPE_PP(option_buffer) != IS_LONG) { zval *cast_option_buffer; ALLOC_ZVAL(cast_option_buffer); - INIT_PZVAL_COPY(cast_option_buffer, *option_buffer); + MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); convert_to_long(cast_option_buffer); new_cost = Z_LVAL_P(cast_option_buffer); zval_dtor(cast_option_buffer); @@ -328,7 +328,7 @@ PHP_FUNCTION(password_hash) if (Z_TYPE_PP(option_buffer) != IS_LONG) { zval *cast_option_buffer; ALLOC_ZVAL(cast_option_buffer); - INIT_PZVAL_COPY(cast_option_buffer, *option_buffer); + MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); convert_to_long(cast_option_buffer); cost = Z_LVAL_P(cast_option_buffer); zval_dtor(cast_option_buffer); @@ -368,7 +368,7 @@ PHP_FUNCTION(password_hash) case IS_OBJECT: { zval *cast_option_buffer; ALLOC_ZVAL(cast_option_buffer); - INIT_PZVAL_COPY(cast_option_buffer, *option_buffer); + MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); convert_to_string(cast_option_buffer); if (Z_TYPE_P(cast_option_buffer) == IS_STRING) { buffer = estrndup(Z_STRVAL_P(cast_option_buffer), Z_STRLEN_P(cast_option_buffer)); From 37b2207f66ac1cebdc3ff3f7f88ec319ee893292 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Sun, 7 Oct 2012 05:12:02 -0400 Subject: [PATCH 2116/2394] Clean up unreported memory leak by switching to zval_ptr_dtor --- ext/standard/password.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 70004a9bc8898..3507183c2a58e 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -250,7 +250,7 @@ PHP_FUNCTION(password_needs_rehash) MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); convert_to_long(cast_option_buffer); new_cost = Z_LVAL_P(cast_option_buffer); - zval_dtor(cast_option_buffer); + zval_ptr_dtor(&cast_option_buffer); } else { new_cost = Z_LVAL_PP(option_buffer); } @@ -331,7 +331,7 @@ PHP_FUNCTION(password_hash) MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); convert_to_long(cast_option_buffer); cost = Z_LVAL_P(cast_option_buffer); - zval_dtor(cast_option_buffer); + zval_ptr_dtor(&cast_option_buffer); } else { cost = Z_LVAL_PP(option_buffer); } @@ -373,10 +373,10 @@ PHP_FUNCTION(password_hash) if (Z_TYPE_P(cast_option_buffer) == IS_STRING) { buffer = estrndup(Z_STRVAL_P(cast_option_buffer), Z_STRLEN_P(cast_option_buffer)); buffer_len_int = Z_STRLEN_P(cast_option_buffer); - zval_dtor(cast_option_buffer); + zval_ptr_dtor(&cast_option_buffer); break; } - zval_dtor(cast_option_buffer); + zval_ptr_dtor(&cast_option_buffer); } case IS_BOOL: case IS_NULL: From 0bc9ca39ced4128c3b9fb1ba2ac797d342e7eef2 Mon Sep 17 00:00:00 2001 From: Anthony Ferrara Date: Sun, 7 Oct 2012 05:42:08 -0400 Subject: [PATCH 2117/2394] Refactor to using a stack based zval instead of dynamic allocation --- ext/standard/password.c | 39 ++++++++++++++++++--------------------- 1 file changed, 18 insertions(+), 21 deletions(-) diff --git a/ext/standard/password.c b/ext/standard/password.c index 3507183c2a58e..266ad0a42174a 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -245,12 +245,11 @@ PHP_FUNCTION(password_needs_rehash) if (options && zend_symtable_find(options, "cost", sizeof("cost"), (void **) &option_buffer) == SUCCESS) { if (Z_TYPE_PP(option_buffer) != IS_LONG) { - zval *cast_option_buffer; - ALLOC_ZVAL(cast_option_buffer); - MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); - convert_to_long(cast_option_buffer); - new_cost = Z_LVAL_P(cast_option_buffer); - zval_ptr_dtor(&cast_option_buffer); + zval cast_option_buffer; + MAKE_COPY_ZVAL(option_buffer, &cast_option_buffer); + convert_to_long(&cast_option_buffer); + new_cost = Z_LVAL(cast_option_buffer); + zval_dtor(&cast_option_buffer); } else { new_cost = Z_LVAL_PP(option_buffer); } @@ -326,12 +325,11 @@ PHP_FUNCTION(password_hash) if (options && zend_symtable_find(options, "cost", 5, (void **) &option_buffer) == SUCCESS) { if (Z_TYPE_PP(option_buffer) != IS_LONG) { - zval *cast_option_buffer; - ALLOC_ZVAL(cast_option_buffer); - MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); - convert_to_long(cast_option_buffer); - cost = Z_LVAL_P(cast_option_buffer); - zval_ptr_dtor(&cast_option_buffer); + zval cast_option_buffer; + MAKE_COPY_ZVAL(option_buffer, &cast_option_buffer); + convert_to_long(&cast_option_buffer); + cost = Z_LVAL(cast_option_buffer); + zval_dtor(&cast_option_buffer); } else { cost = Z_LVAL_PP(option_buffer); } @@ -366,17 +364,16 @@ PHP_FUNCTION(password_hash) case IS_LONG: case IS_DOUBLE: case IS_OBJECT: { - zval *cast_option_buffer; - ALLOC_ZVAL(cast_option_buffer); - MAKE_COPY_ZVAL(option_buffer, cast_option_buffer); - convert_to_string(cast_option_buffer); - if (Z_TYPE_P(cast_option_buffer) == IS_STRING) { - buffer = estrndup(Z_STRVAL_P(cast_option_buffer), Z_STRLEN_P(cast_option_buffer)); - buffer_len_int = Z_STRLEN_P(cast_option_buffer); - zval_ptr_dtor(&cast_option_buffer); + zval cast_option_buffer; + MAKE_COPY_ZVAL(option_buffer, &cast_option_buffer); + convert_to_string(&cast_option_buffer); + if (Z_TYPE(cast_option_buffer) == IS_STRING) { + buffer = estrndup(Z_STRVAL(cast_option_buffer), Z_STRLEN(cast_option_buffer)); + buffer_len_int = Z_STRLEN(cast_option_buffer); + zval_dtor(&cast_option_buffer); break; } - zval_ptr_dtor(&cast_option_buffer); + zval_dtor(&cast_option_buffer); } case IS_BOOL: case IS_NULL: From 7eba512b5170fc57dc3d4a6b93f98a0e0acc7721 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Tue, 16 Oct 2012 11:14:43 +0200 Subject: [PATCH 2118/2394] updated NEWS --- NEWS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/NEWS b/NEWS index 2ad1fa7920e22..c2e3444cc524b 100644 --- a/NEWS +++ b/NEWS @@ -86,4 +86,8 @@ PHP NEWS - Zip: . Upgraded libzip to 0.10.1 (Anatoliy) +- Fileinfo: + . Fixed bug #63248 (Load multiple magic files from a directory under Windows). + (Anatoliy) + <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From 917639d4631b456f8ffd959a3c523071c3e9c8b5 Mon Sep 17 00:00:00 2001 From: ULF WENDEL Date: Sat, 29 Sep 2012 17:42:00 +0200 Subject: [PATCH 2119/2394] Updating expected output in anticipation of mysqlnd_auth.c path --- .../tests/mysqli_pam_sha256_public_key_option_invalid.phpt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt b/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt index 960f08ad48122..e2626240d826c 100644 --- a/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt +++ b/ext/mysqli/tests/mysqli_pam_sha256_public_key_option_invalid.phpt @@ -182,5 +182,7 @@ Warning: mysqli::real_connect(): (HY000/1045): %s in %s on line %d [300 + 002] [1045] %s Warning: mysqli::real_connect(%sest_sha256_wrong_%d): failed to open stream: No such file or directory in %s on line %d + +Warning: mysqli::real_connect(): (HY000/1045): %s in %s on line %d [400 + 002] [1045] %s done! \ No newline at end of file From 4c9e222f99731a851e20c6c0972246d079719095 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 3 Oct 2012 14:02:33 +0200 Subject: [PATCH 2120/2394] if ssl has been switched on transmit clear-text password --- ext/mysqlnd/mysqlnd.c | 3 ++ ext/mysqlnd/mysqlnd_auth.c | 55 ++++++++++++++++++++--------------- ext/mysqlnd/mysqlnd_net.c | 1 + ext/mysqlnd/mysqlnd_structs.h | 1 + 4 files changed, 36 insertions(+), 24 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 557924cdaf272..f5fe075c50e0a 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -874,6 +874,9 @@ MYSQLND_METHOD(mysqlnd_conn_data, connect)(MYSQLND_CONN_DATA * conn, saved_compression = TRUE; net->data->compressed = FALSE; } + if (net->data->ssl) { + net->data->ssl = FALSE; + } } else { unsigned int max_allowed_size = MYSQLND_ASSEMBLED_PACKET_MAX_SIZE; conn->m->set_client_option(conn, MYSQLND_OPT_MAX_ALLOWED_PACKET, (char *)&max_allowed_size TSRMLS_CC); diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index 72b25326e05e6..f2c5adcc4df2a 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -579,33 +579,40 @@ mysqlnd_sha256_auth_get_auth_data(struct st_mysqlnd_authentication_plugin * self DBG_ENTER("mysqlnd_sha256_auth_get_auth_data"); DBG_INF_FMT("salt(%d)=[%.*s]", auth_plugin_data_len, auth_plugin_data_len, auth_plugin_data); - *auth_data_len = 0; - - server_public_key = mysqlnd_sha256_get_rsa_key(conn, options, net_options TSRMLS_CC); - if (server_public_key) { - int server_public_key_len; - char xor_str[passwd_len + 1]; - memcpy(xor_str, passwd, passwd_len); - xor_str[passwd_len] = '\0'; - mysqlnd_xor_string(xor_str, passwd_len, (char *) auth_plugin_data, auth_plugin_data_len); + if (conn->net->data->ssl) { + /* clear text under SSL */ + *auth_data_len = passwd_len; + ret = malloc(passwd_len); + memcpy(ret, passwd, passwd_len); + } else { + *auth_data_len = 0; + server_public_key = mysqlnd_sha256_get_rsa_key(conn, options, net_options TSRMLS_CC); + + if (server_public_key) { + int server_public_key_len; + char xor_str[passwd_len + 1]; + memcpy(xor_str, passwd, passwd_len); + xor_str[passwd_len] = '\0'; + mysqlnd_xor_string(xor_str, passwd_len, (char *) auth_plugin_data, auth_plugin_data_len); + + server_public_key_len = RSA_size(server_public_key); + /* + Because RSA_PKCS1_OAEP_PADDING is used there is a restriction on the passwd_len. + RSA_PKCS1_OAEP_PADDING is recommended for new applications. See more here: + http://www.openssl.org/docs/crypto/RSA_public_encrypt.html + */ + if ((size_t) server_public_key_len - 41 <= passwd_len) { + /* password message is to long */ + SET_CLIENT_ERROR(*conn->error_info, CR_UNKNOWN_ERROR, UNKNOWN_SQLSTATE, "password is too long"); + DBG_ERR("password is too long"); + DBG_RETURN(NULL); + } - server_public_key_len = RSA_size(server_public_key); - /* - Because RSA_PKCS1_OAEP_PADDING is used there is a restriction on the passwd_len. - RSA_PKCS1_OAEP_PADDING is recommended for new applications. See more here: - http://www.openssl.org/docs/crypto/RSA_public_encrypt.html - */ - if ((size_t) server_public_key_len - 41 <= passwd_len) { - /* password message is to long */ - SET_CLIENT_ERROR(*conn->error_info, CR_UNKNOWN_ERROR, UNKNOWN_SQLSTATE, "password is too long"); - DBG_ERR("password is too long"); - DBG_RETURN(NULL); + *auth_data_len = server_public_key_len; + ret = malloc(*auth_data_len); + RSA_public_encrypt(passwd_len + 1, (zend_uchar *) xor_str, ret, server_public_key, RSA_PKCS1_OAEP_PADDING); } - - *auth_data_len = server_public_key_len; - ret = malloc(*auth_data_len); - RSA_public_encrypt(passwd_len + 1, (zend_uchar *) xor_str, ret, server_public_key, RSA_PKCS1_OAEP_PADDING); } DBG_RETURN(ret); diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index b3d97447e9514..4f55ddb8925bc 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -908,6 +908,7 @@ MYSQLND_METHOD(mysqlnd_net, enable_ssl)(MYSQLND_NET * const net TSRMLS_DC) php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot connect to MySQL by using SSL"); DBG_RETURN(FAIL); } + net->data->ssl = TRUE; /* get rid of the context. we are persistent and if this is a real pconn used by mysql/mysqli, then the context would not survive cleaning of EG(regular_list), where it is registered, as a diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 16092e987c590..7f512b7211f7d 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -797,6 +797,7 @@ struct st_mysqlnd_net_data { php_stream *stream; zend_bool compressed; + zend_bool ssl; #ifdef MYSQLND_DO_WIRE_CHECK_BEFORE_COMMAND zend_uchar last_command; #else From 06dfb96bf5a532e2af4a714f60b48a6874b9637a Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 3 Oct 2012 14:14:59 +0200 Subject: [PATCH 2121/2394] add a check for libmysql --- ext/mysqli/mysqli.c | 2 ++ ext/mysqli/mysqli_api.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index 9eaac249cc309..81bae23a5fd66 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -699,7 +699,9 @@ PHP_MINIT_FUNCTION(mysqli) REGISTER_LONG_CONSTANT("MYSQLI_OPT_SSL_VERIFY_SERVER_CERT", MYSQL_OPT_SSL_VERIFY_SERVER_CERT, CONST_CS | CONST_PERSISTENT); #endif +#if MYSQL_VERSION_ID > 50605 || defined(MYSQLI_USE_MYSQLND) REGISTER_LONG_CONSTANT("MYSQLI_SERVER_PUBLIC_KEY", MYSQL_SERVER_PUBLIC_KEY, CONST_CS | CONST_PERSISTENT); +#endif /* mysqli_real_connect flags */ REGISTER_LONG_CONSTANT("MYSQLI_CLIENT_SSL", CLIENT_SSL, CONST_CS | CONST_PERSISTENT); diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index dbdda9bc5e68f..394073610c4dc 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -1627,7 +1627,9 @@ static int mysqli_options_get_option_zval_type(int option) case MYSQL_INIT_COMMAND: case MYSQL_SET_CHARSET_NAME: case MYSQL_SET_CHARSET_DIR: +#if MYSQL_VERSION_ID > 50605 || defined(MYSQLI_USE_MYSQLND) case MYSQL_SERVER_PUBLIC_KEY: +#endif return IS_STRING; default: From 713a3fc58c12fae381c1e2fa81cd70ac05d4e86c Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 4 Oct 2012 13:40:23 +0200 Subject: [PATCH 2122/2394] update --- NEWS | 2 ++ UPGRADING | 7 ++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 00a2dd67ead3d..41ab1bb7f0de2 100644 --- a/NEWS +++ b/NEWS @@ -68,6 +68,8 @@ PHP NEWS - MySQLi . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. Known for stability problems. (Andrey) + . Added support for SHA256 authentication available with MySQL 5.6.6+. (Andrey) + - PCRE: . Deprecated the /e modifier diff --git a/UPGRADING b/UPGRADING index bc5773cfa89f8..0e497f743db93 100755 --- a/UPGRADING +++ b/UPGRADING @@ -236,11 +236,16 @@ PHP X.Y UPGRADE NOTES ======================================== 9. New Global Constants ======================================== - +- mysqli + - Added MYSQLI_SERVER_PUBLIC_KEY constant to be used with mysqli_options() ======================================== 10. Changes to INI File Handling ======================================== +- mysqlnd + - Added mysqlnd.sha256_server_public_key INI PERDIR setting that affects all + APIs which use(are built) for mysqlnd. This allows ext/mysqli to be used + with the new auth protocol, although at coarser level. ======================================== From bda93f54059f99752d03c1d27a6128d6b4264858 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 22 Jul 2012 14:25:00 -0700 Subject: [PATCH 2123/2394] use zend_execute_internal --- Zend/zend_execute_API.c | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index ddf86e8008436..271d7532478a9 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -407,7 +407,7 @@ ZEND_API const char *zend_get_executed_filename(TSRMLS_D) /* {{{ */ ZEND_API uint zend_get_executed_lineno(TSRMLS_D) /* {{{ */ { - if(EG(exception) && EG(opline_ptr) && active_opline->opcode == ZEND_HANDLE_EXCEPTION && + if(EG(exception) && EG(opline_ptr) && active_opline->opcode == ZEND_HANDLE_EXCEPTION && active_opline->lineno == 0 && EG(opline_before_exception)) { return EG(opline_before_exception)->lineno; } @@ -601,7 +601,7 @@ ZEND_API int zval_update_constant_ex(zval **pp, void *arg, zend_class_entry *sco zend_hash_init(tmp_ht, zend_hash_num_elements(Z_ARRVAL_P(p)), NULL, ZVAL_PTR_DTOR, 0); zend_hash_copy(tmp_ht, Z_ARRVAL_P(p), (copy_ctor_func_t) zval_deep_copy, (void *) &tmp, sizeof(zval *)); Z_ARRVAL_P(p) = tmp_ht; - } + } /* First go over the array and see if there are any constant indices */ zend_hash_internal_pointer_reset(Z_ARRVAL_P(p)); @@ -976,7 +976,15 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS if (EX(function_state).function->common.scope) { EG(scope) = EX(function_state).function->common.scope; } - ((zend_internal_function *) EX(function_state).function)->handler(fci->param_count, *fci->retval_ptr_ptr, fci->retval_ptr_ptr, fci->object_ptr, 1 TSRMLS_CC); + + if (!zend_execute_internal) { + /* saves one function call if zend_execute_internal is not used */ + ((zend_internal_function *) EX(function_state).function)->handler(fci->param_count, *fci->retval_ptr_ptr, fci->retval_ptr_ptr, fci->object_ptr, 1 TSRMLS_CC); + } else { + zend_execute_internal(&execute_data, 1 TSRMLS_CC); + } + + /* We shouldn't fix bad extensions here, because it can break proper ones (Bug #34045) if (!EX(function_state).function->common.return_reference) @@ -1311,9 +1319,9 @@ void execute_new_code(TSRMLS_D) /* {{{ */ ZEND_VM_SET_OPCODE_HANDLER(opline); opline++; } - + zend_release_labels(TSRMLS_C); - + EG(return_value_ptr_ptr) = NULL; EG(active_op_array) = CG(active_op_array); orig_interactive = CG(interactive); @@ -1336,11 +1344,11 @@ ZEND_API void zend_timeout(int dummy) /* {{{ */ if (zend_on_timeout) { #ifdef ZEND_SIGNALS - /* + /* We got here because we got a timeout signal, so we are in a signal handler at this point. However, we want to be able to timeout any user-supplied shutdown functions, so pretend we are not in a signal handler while we are - calling these + calling these */ SIGG(running) = 0; #endif @@ -1589,7 +1597,7 @@ zend_class_entry *zend_fetch_class(const char *class_name, uint class_name_len, zend_error(E_ERROR, "Trait '%s' not found", class_name); } else { zend_error(E_ERROR, "Class '%s' not found", class_name); - } + } } } return NULL; @@ -1612,7 +1620,7 @@ zend_class_entry *zend_fetch_class_by_name(const char *class_name, uint class_na zend_error(E_ERROR, "Trait '%s' not found", class_name); } else { zend_error(E_ERROR, "Class '%s' not found", class_name); - } + } } } return NULL; @@ -1753,7 +1761,7 @@ ZEND_API void zend_rebuild_symbol_table(TSRMLS_D) /* {{{ */ zend_execute_data *ex; if (!EG(active_symbol_table)) { - + /* Search for last called user function */ ex = EG(current_execute_data); while (ex && !ex->op_array) { From 531e2533dd2baf5cf10e8de7074ca0b94386dba4 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Fri, 5 Oct 2012 08:14:20 +0200 Subject: [PATCH 2124/2394] Use zend_execute_internal always to call internal functions --- Zend/zend_dtrace.c | 4 ++-- Zend/zend_dtrace.h | 4 ++-- Zend/zend_execute.c | 16 ++++++++++++---- Zend/zend_execute.h | 13 +++++++------ Zend/zend_execute_API.c | 9 +++------ Zend/zend_vm_def.h | 14 +++++++------- Zend/zend_vm_execute.h | 2 +- 7 files changed, 34 insertions(+), 28 deletions(-) diff --git a/Zend/zend_dtrace.c b/Zend/zend_dtrace.c index 5b2d0d2dfed21..3d109deabd96d 100644 --- a/Zend/zend_dtrace.c +++ b/Zend/zend_dtrace.c @@ -83,7 +83,7 @@ ZEND_API void dtrace_execute(zend_op_array *op_array TSRMLS_DC) } } -ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC) +ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC) { int lineno; char *filename; @@ -96,7 +96,7 @@ ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, int r DTRACE_EXECUTE_ENTRY(filename, lineno); } - execute_internal(execute_data_ptr, return_value_used TSRMLS_CC); + execute_internal(execute_data_ptr, fci, return_value_used TSRMLS_CC); if (DTRACE_EXECUTE_RETURN_ENABLED()) { DTRACE_EXECUTE_RETURN(filename, lineno); diff --git a/Zend/zend_dtrace.h b/Zend/zend_dtrace.h index 65d19ef346a85..49388e562f7ff 100644 --- a/Zend/zend_dtrace.h +++ b/Zend/zend_dtrace.h @@ -32,11 +32,11 @@ extern "C" { #ifdef HAVE_DTRACE ZEND_API zend_op_array *(*zend_dtrace_compile_file)(zend_file_handle *file_handle, int type TSRMLS_DC); ZEND_API void (*zend_dtrace_execute)(zend_op_array *op_array TSRMLS_DC); -ZEND_API void (*zend_dtrace_execute_internal)(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC); +ZEND_API void (*zend_dtrace_execute_internal)(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int type TSRMLS_DC); ZEND_API void dtrace_execute(zend_op_array *op_array TSRMLS_DC); -ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC); +ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); #include #endif /* HAVE_DTRACE */ diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 149b91233cc79..361afc6f13e76 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1475,10 +1475,18 @@ static int zend_check_symbol(zval **pz TSRMLS_DC) ZEND_API opcode_handler_t *zend_opcode_handlers; -ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC) +ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC) { - zval **return_value_ptr = &(*(temp_variable *)((char *) execute_data_ptr->Ts + execute_data_ptr->opline->result.var)).var.ptr; - ((zend_internal_function *) execute_data_ptr->function_state.function)->handler(execute_data_ptr->opline->extended_value, *return_value_ptr, (execute_data_ptr->function_state.function->common.fn_flags & ZEND_ACC_RETURN_REFERENCE)?return_value_ptr:NULL, execute_data_ptr->object, return_value_used TSRMLS_CC); + if(fci != NULL) { + ((zend_internal_function *) execute_data_ptr->function_state.function)->handler(fci->param_count, + *fci->retval_ptr_ptr, fci->retval_ptr_ptr, fci->object_ptr, 1 TSRMLS_CC); + + } else { + zval **return_value_ptr = &(*(temp_variable *)((char *) execute_data_ptr->Ts + execute_data_ptr->opline->result.var)).var.ptr; + ((zend_internal_function *) execute_data_ptr->function_state.function)->handler(execute_data_ptr->opline->extended_value, *return_value_ptr, + (execute_data_ptr->function_state.function->common.fn_flags & ZEND_ACC_RETURN_REFERENCE)?return_value_ptr:NULL, + execute_data_ptr->object, return_value_used TSRMLS_CC); + } } #define ZEND_VM_NEXT_OPCODE() \ @@ -1513,7 +1521,7 @@ ZEND_API int zend_set_user_opcode_handler(zend_uchar opcode, user_opcode_handler { if (opcode != ZEND_USER_OPCODE) { if (handler == NULL) { - /* restore the original handler */ + /* restore the original handler */ zend_user_opcodes[opcode] = opcode; } else { zend_user_opcodes[opcode] = ZEND_USER_OPCODE; diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 4cfc52b6a3b69..4594eba9eff7c 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -5,7 +5,7 @@ | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | - | that is bundled with this package in the file LICENSE, and is | + | that is bundled with this package in the file LICENSE, and is | | available through the world-wide-web at the following url: | | http://www.zend.com/license/2_00.txt. | | If you did not receive a copy of the Zend license and are unable to | @@ -49,8 +49,9 @@ typedef union _temp_variable { BEGIN_EXTERN_C() +struct _zend_fcall_info; ZEND_API extern void (*zend_execute)(zend_op_array *op_array TSRMLS_DC); -ZEND_API extern void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC); +ZEND_API extern void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, struct _zend_fcall_info *fci, int return_value_used TSRMLS_DC); void init_executor(TSRMLS_D); void shutdown_executor(TSRMLS_D); @@ -58,7 +59,7 @@ void shutdown_destructors(TSRMLS_D); zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC); ZEND_API void execute(zend_op_array *op_array TSRMLS_DC); ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC); -ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC); +ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, struct _zend_fcall_info *fci, int return_value_used TSRMLS_DC); ZEND_API int zend_is_true(zval *op); #define safe_free_zval_ptr(p) safe_free_zval_ptr_rel(p ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC) static zend_always_inline void safe_free_zval_ptr_rel(zval *p ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) @@ -272,7 +273,7 @@ static zend_always_inline void *zend_vm_stack_alloc(size_t size TSRMLS_DC) } static zend_always_inline void zend_vm_stack_free_int(void *ptr TSRMLS_DC) -{ +{ if (UNEXPECTED(ZEND_VM_STACK_ELEMETS(EG(argument_stack)) == (void**)ptr)) { zend_vm_stack p = EG(argument_stack); @@ -284,7 +285,7 @@ static zend_always_inline void zend_vm_stack_free_int(void *ptr TSRMLS_DC) } static zend_always_inline void zend_vm_stack_free(void *ptr TSRMLS_DC) -{ +{ if (UNEXPECTED(ZEND_VM_STACK_ELEMETS(EG(argument_stack)) == (void**)ptr)) { zend_vm_stack p = EG(argument_stack); @@ -304,7 +305,7 @@ static zend_always_inline void zend_vm_stack_free(void *ptr TSRMLS_DC) static zend_always_inline void** zend_vm_stack_push_args(int count TSRMLS_DC) { - if (UNEXPECTED(EG(argument_stack)->top - ZEND_VM_STACK_ELEMETS(EG(argument_stack)) < count) || + if (UNEXPECTED(EG(argument_stack)->top - ZEND_VM_STACK_ELEMETS(EG(argument_stack)) < count) || UNEXPECTED(EG(argument_stack)->top == EG(argument_stack)->end)) { zend_vm_stack p = EG(argument_stack); diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 271d7532478a9..9787966f275ab 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -39,7 +39,7 @@ #endif ZEND_API void (*zend_execute)(zend_op_array *op_array TSRMLS_DC); -ZEND_API void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, int return_value_used TSRMLS_DC); +ZEND_API void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); /* true globals */ ZEND_API const zend_fcall_info empty_fcall_info = { 0, NULL, NULL, NULL, NULL, 0, NULL, NULL, 0 }; @@ -976,15 +976,12 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS if (EX(function_state).function->common.scope) { EG(scope) = EX(function_state).function->common.scope; } - - if (!zend_execute_internal) { + if(EXPECTED(zend_execute_internal == NULL)) { /* saves one function call if zend_execute_internal is not used */ ((zend_internal_function *) EX(function_state).function)->handler(fci->param_count, *fci->retval_ptr_ptr, fci->retval_ptr_ptr, fci->object_ptr, 1 TSRMLS_CC); } else { - zend_execute_internal(&execute_data, 1 TSRMLS_CC); + zend_execute_internal(&execute_data, fci, 1 TSRMLS_CC); } - - /* We shouldn't fix bad extensions here, because it can break proper ones (Bug #34045) if (!EX(function_state).function->common.return_reference) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index ab5102f1480a3..b06c09f483a34 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2024,7 +2024,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) /* saves one function call if zend_execute_internal is not used */ fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); } else { - zend_execute_internal(EXECUTE_DATA, RETURN_VALUE_USED(opline) TSRMLS_CC); + zend_execute_internal(EXECUTE_DATA, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC); } if (!RETURN_VALUE_USED(opline)) { @@ -2143,7 +2143,7 @@ ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) for (i=0; ilast_try_catch; i++) { if (EX(op_array)->try_catch_array[i].try_op > op_num) { break; - } + } if (op_num < EX(op_array)->try_catch_array[i].finally_op) { finally_op_num = EX(op_array)->try_catch_array[i].finally_op; } @@ -2155,7 +2155,7 @@ ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) for (i=0; ilast_try_catch; i++) { if (EX(op_array)->try_catch_array[i].try_op > op_num) { break; - } + } if (op_num < EX(op_array)->try_catch_array[i].finally_op) { finally_op_num = EX(op_array)->try_catch_array[i].finally_op; } @@ -2199,8 +2199,8 @@ ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) for (i=0; ilast_try_catch; i++) { if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op + } + if (op_num < EG(active_op_array)->try_catch_array[i].finally_op && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; @@ -5164,7 +5164,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { /* further blocks will not be relevant... */ break; - } + } if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; catched = i + 1; @@ -5242,7 +5242,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); } - } else if (catched) { + } else if (catched) { EX(leaving) = 0; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); ZEND_VM_CONTINUE(); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 258a85fe7f4b7..8c4b594d0000a 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -648,7 +648,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR /* saves one function call if zend_execute_internal is not used */ fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); } else { - zend_execute_internal(execute_data, RETURN_VALUE_USED(opline) TSRMLS_CC); + zend_execute_internal(execute_data, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC); } if (!RETURN_VALUE_USED(opline)) { From b17039c737e2700ec7aa2216bfbe7470d1abb51e Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 10 Oct 2012 10:32:58 +0800 Subject: [PATCH 2125/2394] Remove executable permission on phpt --- ext/date/tests/bug60236.phpt | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 ext/date/tests/bug60236.phpt diff --git a/ext/date/tests/bug60236.phpt b/ext/date/tests/bug60236.phpt old mode 100755 new mode 100644 From b0e8fb6489f7aa65aeaae6198a3dd81574f1ebcd Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 16 Oct 2012 15:06:02 +0200 Subject: [PATCH 2126/2394] fix newly introduced segfault --- ext/mysqlnd/mysqlnd_auth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index 3cae693de4ef3..cdbdf6d7edf7e 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -555,8 +555,8 @@ mysqlnd_sha256_get_rsa_key(MYSQLND_CONN_DATA * conn, DBG_INF_FMT("Public key:%*.s", len, key_str); efree(key_str); } + php_stream_free(stream, PHP_STREAM_FREE_CLOSE); } - php_stream_free(stream, PHP_STREAM_FREE_CLOSE); } DBG_RETURN(ret); } From d62702851ca7012cf4b635e6379cb4de383dc7ac Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 17 Oct 2012 16:35:36 +0200 Subject: [PATCH 2127/2394] fix build with libmysql on Ubuntu 12.04 x64 probably other mixed 32/64 systems --- ext/mysql/config.m4 | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ext/mysql/config.m4 b/ext/mysql/config.m4 index fa7a46f8532f7..5968c43346aed 100644 --- a/ext/mysql/config.m4 +++ b/ext/mysql/config.m4 @@ -96,6 +96,13 @@ Note that the MySQL client library is not bundled anymore!]) MYSQL_LIB_CHK($i) done + if test -z "$MYSQL_LIB_DIR"; then + MYSQL_LIB_CHK(lib/x86_64-linux-gnu) + fi + if test -z "$MYSQL_LIB_DIR"; then + MYSQL_LIB_CHK(lib/i386-linux-gnu) + fi + if test -z "$MYSQL_LIB_DIR"; then AC_MSG_ERROR([Cannot find lib$MYSQL_LIBNAME under $MYSQL_DIR. Note that the MySQL client library is not bundled anymore!]) From 967a1ebe5147e3892559f029a95514fd449e0c6a Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 18 Oct 2012 15:09:17 +0200 Subject: [PATCH 2128/2394] add protection against core dumps if the underlying library returns 0x0 for some reason --- ext/mysqli/mysqli_api.c | 47 +++++++++++++++---- .../tests/mysqli_class_mysqli_interface.phpt | 2 +- ext/mysqli/tests/mysqli_info.phpt | 8 ++-- 3 files changed, 42 insertions(+), 15 deletions(-) diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index 394073610c4dc..1ac9173eec462 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -566,14 +566,17 @@ PHP_FUNCTION(mysqli_character_set_name) { MY_MYSQL *mysql; zval *mysql_link; + const char *cs_name; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - - RETURN_STRING((char *)mysql_character_set_name(mysql->mysql), 1); + cs_name = mysql_character_set_name(mysql->mysql); + if (cs_name) { + RETURN_STRING(cs_name, 1); + } } /* }}} */ @@ -732,12 +735,16 @@ PHP_FUNCTION(mysqli_error) { MY_MYSQL *mysql; zval *mysql_link; + const char *err; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - RETURN_STRING((char *)mysql_error(mysql->mysql),1); + err = mysql_error(mysql->mysql); + if (err) { + RETURN_STRING(err, 1); + } } /* }}} */ @@ -1268,7 +1275,10 @@ PHP_FUNCTION(mysqli_free_result) Get MySQL client info */ PHP_FUNCTION(mysqli_get_client_info) { - RETURN_STRING((char *)mysql_get_client_info(), 1); + const char * info = mysql_get_client_info(); + if (info) { + RETURN_STRING(info, 1); + } } /* }}} */ @@ -1320,15 +1330,18 @@ PHP_FUNCTION(mysqli_get_server_info) { MY_MYSQL *mysql; zval *mysql_link = NULL; + const char *info; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - RETURN_STRING((char *)mysql_get_server_info(mysql->mysql), 1); + info = mysql_get_server_info(mysql->mysql); + if (info) { + RETURN_STRING(info, 1); + } } - /* }}} */ /* {{{ proto int mysqli_get_server_version(object link) @@ -1361,7 +1374,9 @@ PHP_FUNCTION(mysqli_info) MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); info = mysql_info(mysql->mysql); - RETURN_STRING((info) ? (char *)info : "", 1); + if (info) { + RETURN_STRING(info, 1); + } } /* }}} */ @@ -2096,12 +2111,16 @@ PHP_FUNCTION(mysqli_sqlstate) { MY_MYSQL *mysql; zval *mysql_link; + const char *state; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - RETURN_STRING((char *)mysql_sqlstate(mysql->mysql),1); + state = mysql_sqlstate(mysql->mysql); + if (state) { + RETURN_STRING(state, 1); + } } /* }}} */ @@ -2279,13 +2298,17 @@ PHP_FUNCTION(mysqli_stmt_error) { MY_STMT *stmt; zval *mysql_stmt; + const char * err; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_stmt, mysqli_stmt_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_STMT(stmt, &mysql_stmt, MYSQLI_STATUS_INITIALIZED); - RETURN_STRING((char *)mysql_stmt_error(stmt->stmt),1); + err = mysql_stmt_error(stmt->stmt); + if (err) { + RETURN_STRING(err, 1); + } } /* }}} */ @@ -2424,13 +2447,17 @@ PHP_FUNCTION(mysqli_stmt_sqlstate) { MY_STMT *stmt; zval *mysql_stmt; + const char * state; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_stmt, mysqli_stmt_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_STMT(stmt, &mysql_stmt, MYSQLI_STATUS_VALID); - RETURN_STRING((char *)mysql_stmt_sqlstate(stmt->stmt),1); + state = mysql_stmt_sqlstate(stmt->stmt); + if (state) { + RETURN_STRING(state, 1); + } } /* }}} */ diff --git a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt index 1865943f08cd9..19ba0086fb259 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt @@ -295,7 +295,7 @@ mysqli->insert_id = '0'/integer ('0'/integer) mysqli->sqlstate = '00000'/%unicode|string% ('00000'/%unicode|string%) mysqli->stat = 'Uptime: %d Threads: %d Questions: %d Slow queries: %d Opens: %d Flush tables: %d Open tables: %d Queries per second avg: %d.%d'/string ('Uptime: %d Threads: %d Questions: %d Slow queries: %d Opens: %d Flush tables: %d Open tables: %d Queries per second avg: %d.%d'/string) mysqli->host_info = '%s'/%unicode|string% ('%s'/%unicode|string%) -mysqli->info = ''/NULL (''/%unicode|string%) +mysqli->info = ''/NULL (''/NULL) mysqli->thread_id = '%d'/integer ('%d'/integer) mysqli->protocol_version = '%d'/integer ('%d'/integer) mysqli->server_info = '%s'/%unicode|string% ('%s'/%unicode|string%) diff --git a/ext/mysqli/tests/mysqli_info.phpt b/ext/mysqli/tests/mysqli_info.phpt index 2d5004fe6e38e..6bb5d215e034e 100644 --- a/ext/mysqli/tests/mysqli_info.phpt +++ b/ext/mysqli/tests/mysqli_info.phpt @@ -21,8 +21,8 @@ require_once('skipifconnectfailure.inc'); printf("[003] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); // NOTE: empty string, no multiple insert syntax - if (!is_string($tmp = mysqli_info($link)) || ('' != $tmp)) - printf("[004] Expecting string/empty, got %s/%s\n", gettype($tmp), $tmp); + if (!is_null($tmp = mysqli_info($link)) || ('' != $tmp)) + printf("[004] Expecting null, got %s/%s\n", gettype($tmp), $tmp); if (!$res = mysqli_query($link, "INSERT INTO test(id, label) VALUES (101, 'a'), (102, 'b')")) printf("[005] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); @@ -54,8 +54,8 @@ require_once('skipifconnectfailure.inc'); if (!$res = mysqli_query($link, "SELECT 1")) printf("[013] [%d] %s\n", mysqli_errno($link), mysqli_error($link)); - if (!is_string($tmp = mysqli_info($link)) || ('' != $tmp)) - printf("[014] Expecting string/empty, got %s/%s\n", gettype($tmp), $tmp); + if (!is_null($tmp = mysqli_info($link)) || ('' != $tmp)) + printf("[014] Expecting null, got %s/%s\n", gettype($tmp), $tmp); mysqli_free_result($res); // NOTE: no LOAD DATA INFILE test From df82bf8a124145ec4defb132d423c15ac1c366e6 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Fri, 19 Oct 2012 10:02:37 +0200 Subject: [PATCH 2129/2394] updated NEWS --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index c2e3444cc524b..ca21853331678 100644 --- a/NEWS +++ b/NEWS @@ -76,6 +76,7 @@ PHP NEWS - PCRE: . Deprecated the /e modifier (https://wiki.php.net/rfc/remove_preg_replace_eval_modifier). (Nikita Popov) + . Fixed bug #63284 (Upgrade PCRE to 8.31). (Anatoliy) - pgsql . Added pg_escape_literal() and pg_escape_identifier() (Yasuo) From 27e0999843f40efd3c9e725866ffb3a93b22c53f Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Mon, 22 Oct 2012 14:35:35 +0200 Subject: [PATCH 2130/2394] fix crashes in newly introduced macros when normal trace is disabled but memory traced is enabled. --- ext/mysqlnd/mysqlnd_debug.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_debug.h b/ext/mysqlnd/mysqlnd_debug.h index 272cdb20e5ca5..37fbb8036061d 100644 --- a/ext/mysqlnd/mysqlnd_debug.h +++ b/ext/mysqlnd/mysqlnd_debug.h @@ -96,10 +96,10 @@ PHPAPI char * mysqlnd_get_backtrace(uint max_levels, size_t * length TSRMLS_DC); #define DBG_PROFILE_END_TIME(duration) #endif -#define DBG_INF_EX(dbg_obj, msg) do { if (dbg_skip_trace == FALSE) (dbg_obj)->m->log((dbg_obj), __LINE__, __FILE__, -1, "info : ", (msg)); } while (0) -#define DBG_ERR_EX(dbg_obj, msg) do { if (dbg_skip_trace == FALSE) (dbg_obj)->m->log((dbg_obj), __LINE__, __FILE__, -1, "error: ", (msg)); } while (0) -#define DBG_INF_FMT_EX(dbg_obj, ...) do { if (dbg_skip_trace == FALSE) (dbg_obj)->m->log_va((dbg_obj), __LINE__, __FILE__, -1, "info : ", __VA_ARGS__); } while (0) -#define DBG_ERR_FMT_EX(dbg_obj, ...) do { if (dbg_skip_trace == FALSE) (dbg_obj)->m->log_va((dbg_obj), __LINE__, __FILE__, -1, "error: ", __VA_ARGS__); } while (0) +#define DBG_INF_EX(dbg_obj, msg) do { if (dbg_skip_trace == FALSE && (dbg_obj)) (dbg_obj)->m->log((dbg_obj), __LINE__, __FILE__, -1, "info : ", (msg)); } while (0) +#define DBG_ERR_EX(dbg_obj, msg) do { if (dbg_skip_trace == FALSE && (dbg_obj)) (dbg_obj)->m->log((dbg_obj), __LINE__, __FILE__, -1, "error: ", (msg)); } while (0) +#define DBG_INF_FMT_EX(dbg_obj, ...) do { if (dbg_skip_trace == FALSE && (dbg_obj)) (dbg_obj)->m->log_va((dbg_obj), __LINE__, __FILE__, -1, "info : ", __VA_ARGS__); } while (0) +#define DBG_ERR_FMT_EX(dbg_obj, ...) do { if (dbg_skip_trace == FALSE && (dbg_obj)) (dbg_obj)->m->log_va((dbg_obj), __LINE__, __FILE__, -1, "error: ", __VA_ARGS__); } while (0) #define DBG_BLOCK_ENTER_EX(dbg_obj, block_name) DBG_BLOCK_ENTER_EX2((dbg_obj), NULL, (block_name)) #define DBG_BLOCK_LEAVE_EX(dbg_obj) DBG_BLOCK_LEAVE_EX2((dbg_obj)) @@ -124,7 +124,7 @@ PHPAPI char * mysqlnd_get_backtrace(uint max_levels, size_t * length TSRMLS_DC); dbg_skip_trace = !(dbg_obj1)->m->func_enter((dbg_obj1), __LINE__, __FILE__, func_name, strlen(func_name)); \ } \ if ((dbg_obj2)) { \ - dbg_skip_trace = !(dbg_obj2)->m->func_enter((dbg_obj2), __LINE__, __FILE__, func_name, strlen(func_name)); \ + dbg_skip_trace |= !(dbg_obj2)->m->func_enter((dbg_obj2), __LINE__, __FILE__, func_name, strlen(func_name)); \ } \ if (dbg_skip_trace); /* shut compiler's mouth */\ do { \ From e7e57aea0a2b3d5bb0ca518c98231951980654d6 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 23 Oct 2012 11:50:56 +0200 Subject: [PATCH 2131/2394] Use if_nametoindex in Vista I missed this instance in bf19838c. --- ext/sockets/sockets.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 0d1714257dbc7..4adb09f188aa7 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -57,7 +57,7 @@ # define h_errno WSAGetLastError() # define set_errno(a) WSASetLastError(a) # define close(a) closesocket(a) -# if _WIN32_WINNT >= 0x0600 && SOCKETS_ENABLE_VISTA_API +# if _WIN32_WINNT >= 0x0600 # define HAVE_IF_NAMETOINDEX 1 # endif #else From e7fc671dc0ad335cba9ff2a564387612e32b68e1 Mon Sep 17 00:00:00 2001 From: ULF WENDEL Date: Tue, 23 Oct 2012 12:02:58 +0200 Subject: [PATCH 2132/2394] Deprecating undocumented function alias, related to bug #63295 --- ext/mysql/php_mysql.c | 40 +- .../tests/mysql_reflection_extension.phpt | 105 +++++ .../tests/mysql_reflection_functions.phpt | 387 ++++++++++++++++++ 3 files changed, 512 insertions(+), 20 deletions(-) create mode 100644 ext/mysql/tests/mysql_reflection_extension.phpt create mode 100644 ext/mysql/tests/mysql_reflection_functions.phpt diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index d6a0c946778fd..f1aab94f8a2e2 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -297,27 +297,27 @@ static const zend_function_entry mysql_functions[] = { PHP_FE(mysql_set_charset, arginfo_mysql_set_charset) #endif /* for downwards compatability */ - PHP_FALIAS(mysql, mysql_db_query, arginfo_mysql_db_query) - PHP_FALIAS(mysql_fieldname, mysql_field_name, arginfo_mysql_field_name) - PHP_FALIAS(mysql_fieldtable, mysql_field_table, arginfo_mysql_field_seek) - PHP_FALIAS(mysql_fieldlen, mysql_field_len, arginfo_mysql_field_seek) - PHP_FALIAS(mysql_fieldtype, mysql_field_type, arginfo_mysql_field_seek) - PHP_FALIAS(mysql_fieldflags, mysql_field_flags, arginfo_mysql_field_seek) - PHP_FALIAS(mysql_selectdb, mysql_select_db, arginfo_mysql_select_db) + PHP_DEP_FALIAS(mysql, mysql_db_query, arginfo_mysql_db_query) + PHP_DEP_FALIAS(mysql_fieldname, mysql_field_name, arginfo_mysql_field_name) + PHP_DEP_FALIAS(mysql_fieldtable, mysql_field_table, arginfo_mysql_field_seek) + PHP_DEP_FALIAS(mysql_fieldlen, mysql_field_len, arginfo_mysql_field_seek) + PHP_DEP_FALIAS(mysql_fieldtype, mysql_field_type, arginfo_mysql_field_seek) + PHP_DEP_FALIAS(mysql_fieldflags, mysql_field_flags, arginfo_mysql_field_seek) + PHP_DEP_FALIAS(mysql_selectdb, mysql_select_db, arginfo_mysql_select_db) #ifndef NETWARE /* The below two functions not supported on NetWare */ #if MYSQL_VERSION_ID < 40000 PHP_DEP_FALIAS(mysql_createdb, mysql_create_db, arginfo_mysql_select_db) PHP_DEP_FALIAS(mysql_dropdb, mysql_drop_db, arginfo_mysql_select_db) #endif #endif /* NETWARE */ - PHP_FALIAS(mysql_freeresult, mysql_free_result, arginfo__result_mysql_arg) - PHP_FALIAS(mysql_numfields, mysql_num_fields, arginfo__result_mysql_arg) - PHP_FALIAS(mysql_numrows, mysql_num_rows, arginfo__result_mysql_arg) - PHP_FALIAS(mysql_listdbs, mysql_list_dbs, arginfo__optional_mysql_link) + PHP_DEP_FALIAS(mysql_freeresult, mysql_free_result, arginfo__result_mysql_arg) + PHP_DEP_FALIAS(mysql_numfields, mysql_num_fields, arginfo__result_mysql_arg) + PHP_DEP_FALIAS(mysql_numrows, mysql_num_rows, arginfo__result_mysql_arg) + PHP_DEP_FALIAS(mysql_listdbs, mysql_list_dbs, arginfo__optional_mysql_link) PHP_DEP_FALIAS(mysql_listtables,mysql_list_tables, arginfo_mysql_select_db) - PHP_FALIAS(mysql_listfields, mysql_list_fields, arginfo_mysql_list_fields) + PHP_DEP_FALIAS(mysql_listfields, mysql_list_fields, arginfo_mysql_list_fields) PHP_FALIAS(mysql_db_name, mysql_result, arginfo_mysql_result) - PHP_FALIAS(mysql_dbname, mysql_result, arginfo_mysql_result) + PHP_DEP_FALIAS(mysql_dbname, mysql_result, arginfo_mysql_result) PHP_FALIAS(mysql_tablename, mysql_result, arginfo_mysql_result) PHP_FALIAS(mysql_table_name, mysql_result, arginfo_mysql_result) PHP_FE_END @@ -1989,16 +1989,16 @@ Q: String or long first? if (sql_row[field_offset]) { Z_TYPE_P(return_value) = IS_STRING; -#if PHP_API_VERSION < 20100412 +#if PHP_API_VERSION < 20100412 if (PG(magic_quotes_runtime)) { Z_STRVAL_P(return_value) = php_addslashes(sql_row[field_offset], sql_row_lengths[field_offset],&Z_STRLEN_P(return_value), 0 TSRMLS_CC); } else { -#endif +#endif Z_STRLEN_P(return_value) = sql_row_lengths[field_offset]; Z_STRVAL_P(return_value) = (char *) safe_estrndup(sql_row[field_offset], Z_STRLEN_P(return_value)); #if PHP_API_VERSION < 20100412 } -#endif +#endif } else { Z_TYPE_P(return_value) = IS_NULL; } @@ -2116,16 +2116,16 @@ static void php_mysql_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, long result_type, MAKE_STD_ZVAL(data); -#if PHP_API_VERSION < 20100412 +#if PHP_API_VERSION < 20100412 if (PG(magic_quotes_runtime)) { Z_TYPE_P(data) = IS_STRING; Z_STRVAL_P(data) = php_addslashes(mysql_row[i], mysql_row_lengths[i], &Z_STRLEN_P(data), 0 TSRMLS_CC); } else { -#endif +#endif ZVAL_STRINGL(data, mysql_row[i], mysql_row_lengths[i], 1); -#if PHP_API_VERSION < 20100412 +#if PHP_API_VERSION < 20100412 } -#endif +#endif if (result_type & MYSQL_NUM) { add_index_zval(return_value, i, data); diff --git a/ext/mysql/tests/mysql_reflection_extension.phpt b/ext/mysql/tests/mysql_reflection_extension.phpt new file mode 100644 index 0000000000000..169036cd5486a --- /dev/null +++ b/ext/mysql/tests/mysql_reflection_extension.phpt @@ -0,0 +1,105 @@ +--TEST-- +ReflectionExtension basics to check API +--SKIPIF-- + +--FILE-- +name); + printf("Version: %s\n", $r->getVersion()); + $classes = $r->getClasses(); + if (!empty($classes)) { + printf("[002] Expecting no class\n"); + asort($classes); + var_dump($classes); + } + + $ignore = array(); + + $functions = $r->getFunctions(); + asort($functions); + printf("Functions:\n"); + foreach ($functions as $func) { + if (isset($ignore[$func->name])) { + unset($ignore[$func->name]); + } else { + printf(" %s\n", $func->name); + } + } + if (!empty($ignore)) { + printf("Dumping version dependent and missing functions\n"); + var_dump($ignore); + } + + + print "done!"; +?> +--EXPECTF-- +Name: mysql +Version: 1.0 +Functions: + mysql + mysql_affected_rows + mysql_client_encoding + mysql_close + mysql_connect + mysql_data_seek + mysql_db_name + mysql_db_query + mysql_dbname + mysql_errno + mysql_error + mysql_escape_string + mysql_fetch_array + mysql_fetch_assoc + mysql_fetch_field + mysql_fetch_lengths + mysql_fetch_object + mysql_fetch_row + mysql_field_flags + mysql_field_len + mysql_field_name + mysql_field_seek + mysql_field_table + mysql_field_type + mysql_fieldflags + mysql_fieldlen + mysql_fieldname + mysql_fieldtable + mysql_fieldtype + mysql_free_result + mysql_freeresult + mysql_get_client_info + mysql_get_host_info + mysql_get_proto_info + mysql_get_server_info + mysql_info + mysql_insert_id + mysql_list_dbs + mysql_list_fields + mysql_list_processes + mysql_list_tables + mysql_listdbs + mysql_listfields + mysql_listtables + mysql_num_fields + mysql_num_rows + mysql_numfields + mysql_numrows + mysql_pconnect + mysql_ping + mysql_query + mysql_real_escape_string + mysql_result + mysql_select_db + mysql_selectdb + mysql_set_charset + mysql_stat + mysql_table_name + mysql_tablename + mysql_thread_id + mysql_unbuffered_query +done! \ No newline at end of file diff --git a/ext/mysql/tests/mysql_reflection_functions.phpt b/ext/mysql/tests/mysql_reflection_functions.phpt new file mode 100644 index 0000000000000..4f2710d806fab --- /dev/null +++ b/ext/mysql/tests/mysql_reflection_functions.phpt @@ -0,0 +1,387 @@ +--TEST-- +ReflectionFunction to check API +--SKIPIF-- + +--FILE-- +getFunctions(); + asort($functions); + printf("Functions:\n"); + foreach ($functions as $func) { + if (isset($ignore[$func->name])) + continue; + + printf(" %s\n", $func->name); + $rf = new ReflectionFunction($func->name); + printf(" Deprecated: %s\n", $rf->isDeprecated() ? "yes" : "no"); + printf(" Accepted parameters: %d\n", $rf->getNumberOfParameters()); + printf(" Required parameters: %d\n", $rf->getNumberOfRequiredParameters()); + foreach( $rf->getParameters() as $param ) { + printf(" %s\n", $param); + } + } + + print "done!"; +?> +--EXPECTF-- +Functions: + mysql + Deprecated: yes + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $database_name ] + Parameter #1 [ $query ] + Parameter #2 [ $link_identifier ] + mysql_affected_rows + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_client_encoding + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_close + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_connect + Deprecated: no + Accepted parameters: 5 + Required parameters: 0 + Parameter #0 [ $hostname ] + Parameter #1 [ $username ] + Parameter #2 [ $password ] + Parameter #3 [ $new ] + Parameter #4 [ $flags ] + mysql_data_seek + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $row_number ] + mysql_db_name + Deprecated: no + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $row ] + Parameter #2 [ $field ] + mysql_db_query + Deprecated: yes + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $database_name ] + Parameter #1 [ $query ] + Parameter #2 [ $link_identifier ] + mysql_dbname + Deprecated: yes + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $row ] + Parameter #2 [ $field ] + mysql_errno + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_error + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_escape_string + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $string ] + mysql_fetch_array + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $result ] + Parameter #1 [ $result_type ] + mysql_fetch_assoc + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_fetch_field + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_fetch_lengths + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_fetch_object + Deprecated: no + Accepted parameters: 3 + Required parameters: 1 + Parameter #0 [ $result ] + Parameter #1 [ $class_name ] + Parameter #2 [ $ctor_params ] + mysql_fetch_row + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_field_flags + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_field_len + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_field_name + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_index ] + mysql_field_seek + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_field_table + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_field_type + Deprecated: no + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_fieldflags + Deprecated: yes + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_fieldlen + Deprecated: yes + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_fieldname + Deprecated: yes + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_index ] + mysql_fieldtable + Deprecated: yes + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_fieldtype + Deprecated: yes + Accepted parameters: 2 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $field_offset ] + mysql_free_result + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_freeresult + Deprecated: yes + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_get_client_info + Deprecated: no + Accepted parameters: 0 + Required parameters: 0 + mysql_get_host_info + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_get_proto_info + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_get_server_info + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_info + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_insert_id + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_list_dbs + Deprecated: yes + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_list_fields + Deprecated: no + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $database_name ] + Parameter #1 [ $table_name ] + Parameter #2 [ $link_identifier ] + mysql_list_processes + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_list_tables + Deprecated: yes + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $database_name ] + Parameter #1 [ $link_identifier ] + mysql_listdbs + Deprecated: yes + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_listfields + Deprecated: yes + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $database_name ] + Parameter #1 [ $table_name ] + Parameter #2 [ $link_identifier ] + mysql_listtables + Deprecated: yes + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $database_name ] + Parameter #1 [ $link_identifier ] + mysql_num_fields + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_num_rows + Deprecated: no + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_numfields + Deprecated: yes + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_numrows + Deprecated: yes + Accepted parameters: 1 + Required parameters: 1 + Parameter #0 [ $result ] + mysql_pconnect + Deprecated: no + Accepted parameters: 4 + Required parameters: 0 + Parameter #0 [ $hostname ] + Parameter #1 [ $username ] + Parameter #2 [ $password ] + Parameter #3 [ $flags ] + mysql_ping + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_query + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $query ] + Parameter #1 [ $link_identifier ] + mysql_real_escape_string + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $string ] + Parameter #1 [ $link_identifier ] + mysql_result + Deprecated: no + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $row ] + Parameter #2 [ $field ] + mysql_select_db + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $database_name ] + Parameter #1 [ $link_identifier ] + mysql_selectdb + Deprecated: yes + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $database_name ] + Parameter #1 [ $link_identifier ] + mysql_set_charset + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $charset_name ] + Parameter #1 [ $link_identifier ] + mysql_stat + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_table_name + Deprecated: no + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $row ] + Parameter #2 [ $field ] + mysql_tablename + Deprecated: no + Accepted parameters: 3 + Required parameters: 2 + Parameter #0 [ $result ] + Parameter #1 [ $row ] + Parameter #2 [ $field ] + mysql_thread_id + Deprecated: no + Accepted parameters: 1 + Required parameters: 0 + Parameter #0 [ $link_identifier ] + mysql_unbuffered_query + Deprecated: no + Accepted parameters: 2 + Required parameters: 1 + Parameter #0 [ $query ] + Parameter #1 [ $link_identifier ] +done! \ No newline at end of file From 240f8d06def8d84021605d21d932adeeaeebbbda Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Thu, 25 Oct 2012 17:11:13 +0200 Subject: [PATCH 2133/2394] commented out the HHC_LOCATION line, as there are no easy to use alternatives for hhc.exe on linux. we should either run the chm build on a windows box(maybe on the replacement of oti1), or look into running it through wine see http://cweiske.de/tagebuch/Generating%20CHM%20files%20with%20Wine%20on%20a%20Linux%20server,%20and%20a%20bit%20about%20PEAR's%20PhD%20transition.htm for details. I also set DOT_CLEANUP to NO as the doc generation was spitting out errors regarding some dot file cannot be found. --- ext/spl/doxygen.cfg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/spl/doxygen.cfg b/ext/spl/doxygen.cfg index 4b71787238795..5c7025a9ad31f 100755 --- a/ext/spl/doxygen.cfg +++ b/ext/spl/doxygen.cfg @@ -111,7 +111,7 @@ HTML_STYLESHEET = HTML_ALIGN_MEMBERS = YES GENERATE_HTMLHELP = YES CHM_FILE = ../spl.chm -HHC_LOCATION = hhc.exe +#HHC_LOCATION = hhc.exe GENERATE_CHI = NO BINARY_TOC = NO TOC_EXPAND = NO @@ -210,7 +210,7 @@ MAX_DOT_GRAPH_WIDTH = 1200 MAX_DOT_GRAPH_HEIGHT = 1024 MAX_DOT_GRAPH_DEPTH = 0 GENERATE_LEGEND = YES -DOT_CLEANUP = YES +DOT_CLEANUP = NO #--------------------------------------------------------------------------- # Configuration::additions related to the search engine #--------------------------------------------------------------------------- From 7e2c87bf2b0ebade118a503f23fcb00d2b9a14ca Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 24 Oct 2012 10:34:44 +0800 Subject: [PATCH 2134/2394] Add missed file --- sapi/fpm/php-fpm.service.in | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 sapi/fpm/php-fpm.service.in diff --git a/sapi/fpm/php-fpm.service.in b/sapi/fpm/php-fpm.service.in new file mode 100644 index 0000000000000..396a88d66f1a0 --- /dev/null +++ b/sapi/fpm/php-fpm.service.in @@ -0,0 +1,12 @@ +[Unit] +Description=The PHP FastCGI Process Manager +After=syslog.target network.target + +[Service] +PIDFile=@localstatedir@/run/php-fpm.pid +ExecStart=@sbindir@/php-fpm --nodaemonize --fpm-config @sysconfdir@/php-fpm.conf +ExecReload=/bin/kill -USR2 $MAINPID + +[Install] +WantedBy=multi-user.target + From 3b85d09de7347b16024530579e46f89d587a2e18 Mon Sep 17 00:00:00 2001 From: "John Jawed (JJ)" Date: Wed, 24 Oct 2012 21:47:47 -0700 Subject: [PATCH 2135/2394] Notice if CURLOPT_SSL_VERIFYHOST is set to true --- ext/curl/interface.c | 5 ++++- ext/curl/tests/bug63363.phpt | 29 +++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 ext/curl/tests/bug63363.phpt diff --git a/ext/curl/interface.c b/ext/curl/interface.c index d9abece5fc0b3..eb7ed8d2025dc 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -2014,6 +2014,10 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu switch (option) { /* Long options */ + case CURLOPT_SSL_VERIFYHOST: + if(Z_TYPE_PP(zvalue)==IS_BOOL && Z_BVAL_PP(zvalue)) { + php_error_docref(NULL TSRMLS_CC, E_NOTICE, "CURLOPT_SSL_VERIFYHOST set to true which disables common name validation (setting CURLOPT_SSL_VERIFYHOST to 2 enables common name validation)"); + } case CURLOPT_AUTOREFERER: case CURLOPT_BUFFERSIZE: case CURLOPT_CLOSEPOLICY: @@ -2048,7 +2052,6 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_PUT: case CURLOPT_RESUME_FROM: case CURLOPT_SSLVERSION: - case CURLOPT_SSL_VERIFYHOST: case CURLOPT_SSL_VERIFYPEER: case CURLOPT_TIMECONDITION: case CURLOPT_TIMEOUT: diff --git a/ext/curl/tests/bug63363.phpt b/ext/curl/tests/bug63363.phpt new file mode 100644 index 0000000000000..43deaa2346e4e --- /dev/null +++ b/ext/curl/tests/bug63363.phpt @@ -0,0 +1,29 @@ +--TEST-- +Bug #63363 (CURL silently accepts boolean value for SSL_VERIFYHOST) +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +bool(true) + +Notice: curl_setopt(): CURLOPT_SSL_VERIFYHOST set to true which disables common name validation (setting CURLOPT_SSL_VERIFYHOST to 2 enables common name validation) in %s on line %d +bool(true) +bool(true) +bool(true) +bool(true) From 01dee2c4b009d052f0fdfa07f35c181a1ac4aca0 Mon Sep 17 00:00:00 2001 From: Antony Dovgal Date: Fri, 26 Oct 2012 16:36:47 +0400 Subject: [PATCH 2136/2394] fix bug #63369 (un)serialize() leaves dangling pointers, causes crashes --- ext/standard/basic_functions.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index a30579e14352a..d6377df84d682 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -3732,6 +3732,11 @@ PHP_MSHUTDOWN_FUNCTION(basic) /* {{{ */ PHP_RINIT_FUNCTION(basic) /* {{{ */ { memset(BG(strtok_table), 0, 256); + + BG(serialize_lock) = 0; + memset(&BG(serialize), 0, sizeof(BG(serialize))); + memset(&BG(unserialize), 0, sizeof(BG(unserialize))); + BG(strtok_string) = NULL; BG(strtok_zval) = NULL; BG(strtok_last) = NULL; From 65399be52787288d387b0a4dd0a4298b86843d88 Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Mon, 29 Oct 2012 10:44:13 +1100 Subject: [PATCH 2137/2394] server-tests.php improvements: * Fixed use of deprecated functions ereg(), split(), etc. * Fixed notice due to _sendHTTP() declared return by reference but not returning anything. * Fixed interpretation of EXPECTF, copying from run-tests.php --- server-tests.php | 111 ++++++++++++++++++++++++++++++++++------------- 1 file changed, 82 insertions(+), 29 deletions(-) diff --git a/server-tests.php b/server-tests.php index 051a1cfa0819e..ca39b198b8c8b 100755 --- a/server-tests.php +++ b/server-tests.php @@ -138,7 +138,7 @@ function generate_diff($wanted,$output) } function mkpath($path,$mode = 0777) { - $dirs = split('[\\/]',$path); + $dirs = preg_split('/[\\/]/',$path); $path = $dirs[0]; for($i = 1;$i < count($dirs);$i++) { $path .= '/'.$dirs[$i]; @@ -358,7 +358,7 @@ function &_getRequest() return $this->outgoing_payload; } - function &_sendHTTP() + function _sendHTTP() { $this->_getRequest(); $host = $this->urlparts['host']; @@ -555,7 +555,7 @@ function getInstalledExtensions() { // get the list of installed extensions $out = $this->runscript(PHP_EXTENSIONS_SCRIPT,true); - $this->exts_to_test = split(":",$out); + $this->exts_to_test = explode(":",$out); sort($this->exts_to_test); $this->exts_tested = count($this->exts_to_test); } @@ -716,9 +716,9 @@ function setTestPaths() if (@$this->conf['TEST_PATHS']) { $this->test_dirs = array(); if ($this->iswin32) { - $paths = split(';',$this->conf['TEST_PATHS']); + $paths = explode(';',$this->conf['TEST_PATHS']); } else { - $paths = split(':|;',$this->conf['TEST_PATHS']); + $paths = explode(':|;',$this->conf['TEST_PATHS']); } foreach($paths as $path) { $this->test_dirs[] = realpath($path); @@ -1152,7 +1152,7 @@ function getSectionText($file) while (!feof($fp)) { $line = fgets($fp); // Match the beginning of a section. - if (ereg('^--([A-Z]+)--',$line,$r)) { + if (preg_match('/^--([A-Z]+)--/',$line,$r)) { $section = $r[1]; $section_text[$section] = ''; continue; @@ -1211,14 +1211,14 @@ function getSkipReason($file,&$section_text,$docgi=false) if (!$output) return NULL; if ($this->conf['TEST_PHP_DETAILED'] > 2) print "SKIPIF: [$output]\n"; - if (eregi("^skip", $output)){ + if (preg_match("/^skip/i", $output)){ - $reason = (ereg("^skip[[:space:]]*(.+)\$", $output)) ? ereg_replace("^skip[[:space:]]*(.+)\$", "\\1", $output) : FALSE; + $reason = (preg_match("/^skip\s*(.+)\$/", $output)) ? preg_replace("/^skip\s*(.+)\$/", "\\1", $output) : FALSE; $this->showstatus($section_text['TEST'], 'SKIPPED', $reason); return 'SKIPPED'; } - if (eregi("^info", $output)) { - $reason = (ereg("^info[[:space:]]*(.+)\$", $output)) ? ereg_replace("^info[[:space:]]*(.+)\$", "\\1", $output) : FALSE; + if (preg_match("/^info/i", $output)) { + $reason = (preg_match("/^info\s*(.+)\$/", $output)) ? preg_replace("/^info\s*(.+)\$/", "\\1", $output) : FALSE; if ($reason) { $tested .= " (info: $reason)"; } @@ -1244,19 +1244,19 @@ function run_test($file) $tested = $section_text['TEST']." [$shortname]"; if ($this->conf['TEST_WEB']) { - $tmp_file = ereg_replace('\.phpt$','.'.$this->conf['TEST_WEB_EXT'],$file); + $tmp_file = preg_replace('/\.phpt$/','.'.$this->conf['TEST_WEB_EXT'],$file); $uri = $this->conf['TEST_BASE_SCRIPT_NAME'].str_replace($this->conf['TEST_BASE_PATH'], '', $tmp_file); $uri = str_replace('\\', '/', $uri); } else { - $tmp_file = ereg_replace('\.phpt$','.php',$file); + $tmp_file = preg_replace('/\.phpt$/','.php',$file); } @unlink($tmp_file); // unlink old test results - @unlink(ereg_replace('\.phpt$','.diff',$file)); - @unlink(ereg_replace('\.phpt$','.log',$file)); - @unlink(ereg_replace('\.phpt$','.exp',$file)); - @unlink(ereg_replace('\.phpt$','.out',$file)); + @unlink(preg_replace('/\.phpt$/','.diff',$file)); + @unlink(preg_replace('/\.phpt$/','.log',$file)); + @unlink(preg_replace('/\.phpt$/','.exp',$file)); + @unlink(preg_replace('/\.phpt$/','.out',$file)); if (!$this->conf['TEST_WEB']) { // Reset environment from any previous test. @@ -1425,15 +1425,68 @@ function run_test($file) } $wanted_re = preg_replace('/\r\n/',"\n",$wanted); if (isset($section_text['EXPECTF'])) { - $wanted_re = preg_quote($wanted_re, '/'); + // do preg_quote, but miss out any %r delimited sections + $temp = ""; + $r = "%r"; + $startOffset = 0; + $length = strlen($wanted_re); + while($startOffset < $length) { + $start = strpos($wanted_re, $r, $startOffset); + if ($start !== false) { + // we have found a start tag + $end = strpos($wanted_re, $r, $start+2); + if ($end === false) { + // unbalanced tag, ignore it. + $end = $start = $length; + } + } else { + // no more %r sections + $start = $end = $length; + } + // quote a non re portion of the string + $temp = $temp . preg_quote(substr($wanted_re, $startOffset, ($start - $startOffset)), '/'); + // add the re unquoted. + if ($end > $start) { + $temp = $temp . '(' . substr($wanted_re, $start+2, ($end - $start-2)). ')'; + } + $startOffset = $end + 2; + } + $wanted_re = $temp; + + $wanted_re = str_replace( + array('%binary_string_optional%'), + 'string', + $wanted_re + ); + $wanted_re = str_replace( + array('%unicode_string_optional%'), + 'string', + $wanted_re + ); + $wanted_re = str_replace( + array('%unicode\|string%', '%string\|unicode%'), + 'string', + $wanted_re + ); + $wanted_re = str_replace( + array('%u\|b%', '%b\|u%'), + '', + $wanted_re + ); // Stick to basics - $wanted_re = str_replace("%s", ".+?", $wanted_re); //not greedy - $wanted_re = str_replace("%i", "[+\-]?[0-9]+", $wanted_re); - $wanted_re = str_replace("%d", "[0-9]+", $wanted_re); - $wanted_re = str_replace("%x", "[0-9a-fA-F]+", $wanted_re); - $wanted_re = str_replace("%f", "[+\-]?\.?[0-9]+\.?[0-9]*(E-?[0-9]+)?", $wanted_re); - $wanted_re = str_replace("%c", ".", $wanted_re); + $wanted_re = str_replace('%e', '\\' . DIRECTORY_SEPARATOR, $wanted_re); + $wanted_re = str_replace('%s', '[^\r\n]+', $wanted_re); + $wanted_re = str_replace('%S', '[^\r\n]*', $wanted_re); + $wanted_re = str_replace('%a', '.+', $wanted_re); + $wanted_re = str_replace('%A', '.*', $wanted_re); + $wanted_re = str_replace('%w', '\s*', $wanted_re); + $wanted_re = str_replace('%i', '[+-]?\d+', $wanted_re); + $wanted_re = str_replace('%d', '\d+', $wanted_re); + $wanted_re = str_replace('%x', '[0-9a-fA-F]+', $wanted_re); + $wanted_re = str_replace('%f', '[+-]?\.?\d+\.?\d*(?:[Ee][+-]?\d+)?', $wanted_re); + $wanted_re = str_replace('%c', '.', $wanted_re); // %f allows two points "-.0.0" but that is the best *simple* expression + } /* DEBUG YOUR REGEX HERE var_dump($wanted_re); @@ -1489,8 +1542,8 @@ function run_test($file) $this->failed_tests[] = array( 'name' => $file, 'test_name' => $tested, - 'output' => ereg_replace('\.phpt$','.log', $file), - 'diff' => ereg_replace('\.phpt$','.diff', $file) + 'output' => preg_replace('/\.phpt$/','.log', $file), + 'diff' => preg_replace('/\.phpt$/','.diff', $file) ); if ($this->conf['TEST_PHP_DETAILED']) @@ -1498,25 +1551,25 @@ function run_test($file) // write .exp if (strpos($this->conf['TEST_PHP_LOG_FORMAT'],'E') !== FALSE) { - $logname = ereg_replace('\.phpt$','.exp',$file); + $logname = preg_replace('/\.phpt$/','.exp',$file); file_put_contents($logname,$wanted); } // write .out if (strpos($this->conf['TEST_PHP_LOG_FORMAT'],'O') !== FALSE) { - $logname = ereg_replace('\.phpt$','.out',$file); + $logname = preg_replace('/\.phpt$/','.out',$file); file_put_contents($logname,$output); } // write .diff if (strpos($this->conf['TEST_PHP_LOG_FORMAT'],'D') !== FALSE) { - $logname = ereg_replace('\.phpt$','.diff',$file); + $logname = preg_replace('/\.phpt$/','.diff',$file); file_put_contents($logname,generate_diff($wanted,$output)); } // write .log if (strpos($this->conf['TEST_PHP_LOG_FORMAT'],'L') !== FALSE) { - $logname = ereg_replace('\.phpt$','.log',$file); + $logname = preg_replace('/\.phpt$/','.log',$file); file_put_contents($logname, "\n---- EXPECTED OUTPUT\n$wanted\n". "---- ACTUAL OUTPUT\n$output\n". From d62bc53a4fb2058a06f356b5779a0db88f6e207c Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 31 Oct 2012 15:54:45 +0100 Subject: [PATCH 2138/2394] cosmetics --- ext/mysqlnd/mysqlnd_net.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index 4f55ddb8925bc..b04c4eee13f83 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -527,7 +527,7 @@ MYSQLND_METHOD(mysqlnd_net, read_compressed_packet_from_stream_and_fill_read_buf enum_func_status retval = PASS; zend_uchar * compressed_data = NULL; zend_uchar comp_header[COMPRESSED_HEADER_SIZE]; - DBG_ENTER("mysqlnd_net::read_compressed_packet_from_stream_and_fill_read_buffe"); + DBG_ENTER("mysqlnd_net::read_compressed_packet_from_stream_and_fill_read_buffer"); /* Read the compressed header */ if (FAIL == net->data->m.network_read_ex(net, comp_header, COMPRESSED_HEADER_SIZE, conn_stats, error_info TSRMLS_CC)) { @@ -631,13 +631,13 @@ MYSQLND_METHOD(mysqlnd_net, receive_ex)(MYSQLND_NET * const net, zend_uchar * co if (net->data->compressed) { if (net->uncompressed_data) { size_t to_read_from_buffer = MIN(net->uncompressed_data->bytes_left(net->uncompressed_data), to_read); - DBG_INF_FMT("reading %u from uncompressed_data buffer", to_read_from_buffer); + DBG_INF_FMT("reading "MYSQLND_SZ_T_SPEC" from uncompressed_data buffer", to_read_from_buffer); if (to_read_from_buffer) { net->uncompressed_data->read(net->uncompressed_data, to_read_from_buffer, (zend_uchar *) p); p += to_read_from_buffer; to_read -= to_read_from_buffer; } - DBG_INF_FMT("left %u to read", to_read); + DBG_INF_FMT("left "MYSQLND_SZ_T_SPEC" to read", to_read); if (TRUE == net->uncompressed_data->is_empty(net->uncompressed_data)) { /* Everything was consumed. This should never happen here, but for security */ net->uncompressed_data->free_buffer(&net->uncompressed_data TSRMLS_CC); @@ -697,7 +697,7 @@ MYSQLND_METHOD(mysqlnd_net, set_client_option)(MYSQLND_NET * const net, enum mys DBG_RETURN(FAIL); } net->cmd_buffer.length = *(unsigned int*) value; - DBG_INF_FMT("new_length=%u", net->cmd_buffer.length); + DBG_INF_FMT("new_length="MYSQLND_SZ_T_SPEC, net->cmd_buffer.length); if (!net->cmd_buffer.buffer) { net->cmd_buffer.buffer = mnd_pemalloc(net->cmd_buffer.length, net->persistent); } else { @@ -707,7 +707,7 @@ MYSQLND_METHOD(mysqlnd_net, set_client_option)(MYSQLND_NET * const net, enum mys case MYSQLND_OPT_NET_READ_BUFFER_SIZE: DBG_INF("MYSQLND_OPT_NET_READ_BUFFER_SIZE"); net->data->options.net_read_buffer_size = *(unsigned int*) value; - DBG_INF_FMT("new_length=%u", net->data->options.net_read_buffer_size); + DBG_INF_FMT("new_length="MYSQLND_SZ_T_SPEC, net->data->options.net_read_buffer_size); break; case MYSQL_OPT_CONNECT_TIMEOUT: DBG_INF("MYSQL_OPT_CONNECT_TIMEOUT"); From a0a34f5bcaf1b3d7b567a7d6646cfb1f75156092 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 31 Oct 2012 16:13:00 +0100 Subject: [PATCH 2139/2394] plug recent leak --- ext/mysqlnd/mysqlnd_net.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index b04c4eee13f83..5e9f404233ca6 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -978,6 +978,10 @@ MYSQLND_METHOD(mysqlnd_net, free_contents)(MYSQLND_NET * net TSRMLS_DC) mnd_pefree(net->data->options.ssl_cipher, pers); net->data->options.ssl_cipher = NULL; } + if (net->data->options.sha256_server_public_key) { + mnd_pefree(net->data->options.sha256_server_public_key, pers); + net->data->options.sha256_server_public_key = NULL; + } DBG_VOID_RETURN; } From 44b1a07d851c267bb0c0c47857629ef3f790215a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Schl=C3=BCter?= Date: Wed, 31 Oct 2012 16:54:11 +0100 Subject: [PATCH 2140/2394] Allow setting SHA256 auth public key as option --- ext/pdo_mysql/mysql_driver.c | 16 +++++++++++++++- ext/pdo_mysql/pdo_mysql.c | 4 ++++ ext/pdo_mysql/php_pdo_mysql_int.h | 5 ++++- 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/ext/pdo_mysql/mysql_driver.c b/ext/pdo_mysql/mysql_driver.c index aa7109b51651c..527cb1c3b8d49 100644 --- a/ext/pdo_mysql/mysql_driver.c +++ b/ext/pdo_mysql/mysql_driver.c @@ -138,7 +138,7 @@ static int pdo_mysql_fetch_error_func(pdo_dbh_t *dbh, pdo_stmt_t *stmt, zval *in /* }}} */ /* {{{ mysql_handle_closer */ -static int mysql_handle_closer(pdo_dbh_t *dbh TSRMLS_DC) /* {{{ */ +static int mysql_handle_closer(pdo_dbh_t *dbh TSRMLS_DC) { pdo_mysql_db_handle *H = (pdo_mysql_db_handle *)dbh->driver_data; @@ -709,6 +709,20 @@ static int pdo_mysql_handle_factory(pdo_dbh_t *dbh, zval *driver_options TSRMLS_ efree(ssl_cipher); } } + +#if MYSQL_VERSION_ID > 50605 || defined(MYSQLI_USE_MYSQLND) + { + char *public_key = pdo_attr_strval(driver_options, PDO_MYSQL_ATTR_SERVER_PUBLIC_KEY, NULL TSRMLS_CC); + if (public_key) { + if (mysql_options(H->server, MYSQL_SERVER_PUBLIC_KEY, public_key)) { + pdo_mysql_error(dbh); + efree(public_key); + goto cleanup; + } + efree(public_key); + } + } +#endif } #ifdef PDO_MYSQL_HAS_CHARSET diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index ea69c3c11b1d2..b5a8058da4c52 100644 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -118,6 +118,10 @@ static PHP_MINIT_FUNCTION(pdo_mysql) REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SSL_CA", (long)PDO_MYSQL_ATTR_SSL_CA); REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SSL_CAPATH", (long)PDO_MYSQL_ATTR_SSL_CAPATH); REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SSL_CIPHER", (long)PDO_MYSQL_ATTR_SSL_CIPHER); +#if MYSQL_VERSION_ID > 50605 || defined(MYSQLI_USE_MYSQLND) + REGISTER_PDO_CLASS_CONST_LONG("MYSQL_ATTR_SERVER_PUBLIC_KEY", (long)PDO_MYSQL_ATTR_SERVER_PUBLIC_KEY); +#endif + #ifdef PDO_USE_MYSQLND mysqlnd_reverse_api_register_api(&pdo_mysql_reverse_api TSRMLS_CC); diff --git a/ext/pdo_mysql/php_pdo_mysql_int.h b/ext/pdo_mysql/php_pdo_mysql_int.h index 0b6d7752d33d1..32cf0391525a3 100644 --- a/ext/pdo_mysql/php_pdo_mysql_int.h +++ b/ext/pdo_mysql/php_pdo_mysql_int.h @@ -170,7 +170,10 @@ enum { PDO_MYSQL_ATTR_SSL_CERT, PDO_MYSQL_ATTR_SSL_CA, PDO_MYSQL_ATTR_SSL_CAPATH, - PDO_MYSQL_ATTR_SSL_CIPHER + PDO_MYSQL_ATTR_SSL_CIPHER, +#if MYSQL_VERSION_ID > 50605 || defined(MYSQLI_USE_MYSQLND) + PDO_MYSQL_ATTR_SERVER_PUBLIC_KEY +#endif }; #endif From 3c6b0db05285d2374abc392360d6540c32f6ed66 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 4 Nov 2012 00:53:45 +0800 Subject: [PATCH 2141/2394] The /e modifier is deprecated --- Zend/zend_vm_gen.php | 73 ++++++++++++++++++++++++++------------------ 1 file changed, 44 insertions(+), 29 deletions(-) diff --git a/Zend/zend_vm_gen.php b/Zend/zend_vm_gen.php index ee2b0b2f2da27..bd5f2dede5386 100644 --- a/Zend/zend_vm_gen.php +++ b/Zend/zend_vm_gen.php @@ -387,52 +387,67 @@ function gen_code($f, $spec, $kind, $export, $code, $op1, $op2, $name) { // Updating code according to selected threading model switch($kind) { case ZEND_VM_KIND_CALL: - $code = preg_replace( + $code = preg_replace_callback( array( "/EXECUTE_DATA/m", "/ZEND_VM_DISPATCH_TO_HANDLER\(\s*([A-Z_]*)\s*\)/m", - "/ZEND_VM_DISPATCH_TO_HELPER\(\s*([A-Za-z_]*)\s*\)/me", - "/ZEND_VM_DISPATCH_TO_HELPER_EX\(\s*([A-Za-z_]*)\s*,\s*[A-Za-z_]*\s*,\s*(.*)\s*\);/me", - ), - array( - "execute_data", - "return \\1".($spec?"_SPEC":"").$prefix[$op1].$prefix[$op2]."_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU)", - "'return '.helper_name('\\1',$spec,'$op1','$op2').'(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU)'", - "'return '.helper_name('\\1',$spec,'$op1','$op2').'(\\2, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);'", + "/ZEND_VM_DISPATCH_TO_HELPER\(\s*([A-Za-z_]*)\s*\)/m", + "/ZEND_VM_DISPATCH_TO_HELPER_EX\(\s*([A-Za-z_]*)\s*,\s*[A-Za-z_]*\s*,\s*(.*)\s*\);/m", ), + function($matches) use ($spec, $prefix, $op1, $op2) { + if (strncasecmp($matches[0], "EXECUTE_DATA", strlen("EXECUTE_DATA")) == 0) { + return "execute_data"; + } else if (strncasecmp($matches[0], "ZEND_VM_DISPATCH_TO_HANDLER", strlen("ZEND_VM_DISPATCH_TO_HANDLER")) == 0) { + return "return " . $matches[1] . ($spec?"_SPEC":"") . $prefix[$op1] . $prefix[$op2] . "_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU)"; + } else if (strncasecmp($matches[0], "ZEND_VM_DISPATCH_TO_HELPER_EX", strlen("ZEND_VM_DISPATCH_TO_HELPER_EX")) == 0) { + return "return " . helper_name($matches[1], $spec, $op1, $op2) . "(" . $matches[2]. ", ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);"; + } else { + return "return " . helper_name($matches[1], $spec, $op1, $op2) . "(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU)"; + } + }, $code); break; case ZEND_VM_KIND_SWITCH: - $code = preg_replace( + $code = preg_replace_callback( array( "/EXECUTE_DATA/m", "/ZEND_VM_DISPATCH_TO_HANDLER\(\s*([A-Z_]*)\s*\)/m", - "/ZEND_VM_DISPATCH_TO_HELPER\(\s*([A-Za-z_]*)\s*\)/me", - "/ZEND_VM_DISPATCH_TO_HELPER_EX\(\s*([A-Za-z_]*)\s*,\s*([A-Za-z_]*)\s*,\s*(.*)\s*\);/me", + "/ZEND_VM_DISPATCH_TO_HELPER\(\s*([A-Za-z_]*)\s*\)/m", + "/ZEND_VM_DISPATCH_TO_HELPER_EX\(\s*([A-Za-z_]*)\s*,\s*([A-Za-z_]*)\s*,\s*(.*)\s*\);/m", ), - array( - "execute_data", - "goto \\1".($spec?"_SPEC":"").$prefix[$op1].$prefix[$op2]."_LABEL", - "'goto '.helper_name('\\1',$spec,'$op1','$op2')", - "'\\2 = \\3; goto '.helper_name('\\1',$spec,'$op1','$op2').';'", - ), - $code); + function($matches) use ($spec, $prefix, $op1, $op2) { + if (strncasecmp($matches[0], "EXECUTE_DATA", strlen("EXECUTE_DATA")) == 0) { + return "execute_data"; + } else if (strncasecmp($matches[0], "ZEND_VM_DISPATCH_TO_HANDLER", strlen("ZEND_VM_DISPATCH_TO_HANDLER")) == 0) { + return "goto " . $matches[1] . ($spec?"_SPEC":"") . $prefix[$op1] . $prefix[$op2] . "_LABEL"; + } else if (strncasecmp($matches[0], "ZEND_VM_DISPATCH_TO_HELPER_EX", strlen("ZEND_VM_DISPATCH_TO_HELPER_EX")) == 0) { + return $matches[2] . " = " . $matches[3] . "; goto " . helper_name($matches[1], $spec, $op1, $op2) . ";"; + } else { + return "goto " . helper_name($matches[1], $spec, $op1, $op2); + } + }, + $code); break; case ZEND_VM_KIND_GOTO: - $code = preg_replace( + $code = preg_replace_callback( array( "/EXECUTE_DATA/m", "/ZEND_VM_DISPATCH_TO_HANDLER\(\s*([A-Z_]*)\s*\)/m", - "/ZEND_VM_DISPATCH_TO_HELPER\(\s*([A-Za-z_]*)\s*\)/me", - "/ZEND_VM_DISPATCH_TO_HELPER_EX\(\s*([A-Za-z_]*)\s*,\s*([A-Za-z_]*)\s*,\s*(.*)\s*\);/me", - ), - array( - "execute_data", - "goto \\1".($spec?"_SPEC":"").$prefix[$op1].$prefix[$op2]."_HANDLER", - "'goto '.helper_name('\\1',$spec,'$op1','$op2')", - "'\\2 = \\3; goto '.helper_name('\\1',$spec,'$op1','$op2').';'", + "/ZEND_VM_DISPATCH_TO_HELPER\(\s*([A-Za-z_]*)\s*\)/m", + "/ZEND_VM_DISPATCH_TO_HELPER_EX\(\s*([A-Za-z_]*)\s*,\s*([A-Za-z_]*)\s*,\s*(.*)\s*\);/m", ), - $code); + function($matches) use ($spec, $prefix, $op1, $op2) { + if (strncasecmp($matches[0], "EXECUTE_DATA", strlen("EXECUTE_DATA")) == 0) { + return "execute_data"; + } else if (strncasecmp($matches[0], "ZEND_VM_DISPATCH_TO_HANDLER", strlen("ZEND_VM_DISPATCH_TO_HANDLER")) == 0) { + return "goto " . $matches[1] . ($spec?"_SPEC":"") . $prefix[$op1] . $prefix[$op2] . "_HANDLER"; + } else if (strncasecmp($matches[0], "ZEND_VM_DISPATCH_TO_HELPER_EX", strlen("ZEND_VM_DISPATCH_TO_HELPER_EX")) == 0) { + return $matches[2] . " = " . $matches[3] . "; goto " . helper_name($matches[1], $spec, $op1, $op2) . ";"; + } else { + return "goto " . helper_name($matches[1], $spec, $op1, $op2); + } + }, + $code); break; } From 7bcb8780e0ed042888f88c78919b7726be9ea931 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 4 Nov 2012 12:48:35 +0800 Subject: [PATCH 2142/2394] Fixed bug #63428 (The behavior of execute() changed) --- Zend/zend_generators.c | 4 ++++ Zend/zend_vm_execute.h | 11 ++++------- Zend/zend_vm_execute.skl | 11 ++++------- 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index fba62dd83aacf..87f0644e81e5f 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -461,6 +461,10 @@ static zend_function *zend_generator_get_constructor(zval *object TSRMLS_DC) /* void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ { + if (EG(exception)) { + return; + } + /* The generator is already closed, thus can't resume */ if (!generator->execute_data) { return; diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 8c4b594d0000a..7a2cfc88d90de 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -419,10 +419,6 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) - if (EG(exception)) { - return; - } - original_in_execution = EG(in_execution); EG(in_execution) = 1; @@ -459,9 +455,10 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) ZEND_API void execute(zend_op_array *op_array TSRMLS_DC) { - zend_execute_data *execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); - - execute_ex(execute_data TSRMLS_CC); + if (EG(exception)) { + return; + } + execute_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index 58e5631c953c6..2a6fd71ecb5a4 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -82,10 +82,6 @@ ZEND_API void {%EXECUTOR_NAME%}_ex(zend_execute_data *execute_data TSRMLS_DC) {%INTERNAL_LABELS%} - if (EG(exception)) { - return; - } - original_in_execution = EG(in_execution); EG(in_execution) = 1; @@ -110,9 +106,10 @@ ZEND_API void {%EXECUTOR_NAME%}_ex(zend_execute_data *execute_data TSRMLS_DC) ZEND_API void {%EXECUTOR_NAME%}(zend_op_array *op_array TSRMLS_DC) { - zend_execute_data *execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); - - {%EXECUTOR_NAME%}_ex(execute_data TSRMLS_CC); + if (EG(exception)) { + return; + } + {%EXECUTOR_NAME%}_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } {%EXTERNAL_EXECUTOR%} From 261e32f6236429fcccf61e80262c9df9589d494c Mon Sep 17 00:00:00 2001 From: Rasmus Lerdorf Date: Mon, 5 Nov 2012 20:56:19 -0800 Subject: [PATCH 2143/2394] These need to be volatile in order to prevent leaking after the longjmp in the error handler --- ext/gd/libgd/gd_png.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/gd/libgd/gd_png.c b/ext/gd/libgd/gd_png.c index 49f7cb0777228..bdbb7ee7d3ebd 100644 --- a/ext/gd/libgd/gd_png.c +++ b/ext/gd/libgd/gd_png.c @@ -127,8 +127,8 @@ gdImagePtr gdImageCreateFromPngCtx (gdIOCtx * infile) png_color_16p trans_gray_rgb; png_color_16p trans_color_rgb; png_bytep trans; - png_bytep image_data = NULL; - png_bytepp row_pointers = NULL; + volatile png_bytep image_data = NULL; + volatile png_bytepp row_pointers = NULL; gdImagePtr im = NULL; int i, j, *open = NULL; volatile int transparent = -1; From 4029475e82552a3ceddbdd343bdb5641eb269c50 Mon Sep 17 00:00:00 2001 From: Antony Dovgal Date: Sun, 11 Nov 2012 22:37:04 +0400 Subject: [PATCH 2144/2394] fix invalid read when trimming empty string --- ext/filter/filter_private.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/filter/filter_private.h b/ext/filter/filter_private.h index 2ec2f62fae733..0f76d7a032a71 100644 --- a/ext/filter/filter_private.h +++ b/ext/filter/filter_private.h @@ -109,8 +109,10 @@ if (len < 1 && return_if_empty) { \ RETURN_VALIDATION_FAILED \ } \ - while (p[len-1] == ' ' || p[len-1] == '\t' || p[len-1] == '\r' || p[len-1] == '\v' || p[len-1] == '\n') { \ - len--; \ + if (len > 0) { \ + while (p[len-1] == ' ' || p[len-1] == '\t' || p[len-1] == '\r' || p[len-1] == '\v' || p[len-1] == '\n') { \ + len--; \ + } \ } \ } From 180767373d03238431103c02a93de19df49c14dc Mon Sep 17 00:00:00 2001 From: "Bernhard K. Weisshuhn" Date: Sun, 11 Nov 2012 20:11:06 +0100 Subject: [PATCH 2145/2394] make failed tests fail the test target I don't see any reason to ignore failed tests. This makes it unnecessarily difficult to use ci, also for module builds. --- Makefile.global | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile.global b/Makefile.global index b30c318fc4d94..eaf651e8e2ab7 100644 --- a/Makefile.global +++ b/Makefile.global @@ -86,7 +86,7 @@ PHP_TEST_SHARED_EXTENSIONS = ` \ PHP_DEPRECATED_DIRECTIVES_REGEX = '^(magic_quotes_(gpc|runtime|sybase)?|(zend_)?extension(_debug)?(_ts)?)[\t\ ]*=' test: all - -@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \ + @if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \ INI_FILE=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \ if test "$$INI_FILE"; then \ $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \ From acbc6d182b3a9b13cd2dab06f631852d741fabc5 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 12 Nov 2012 19:16:12 +0100 Subject: [PATCH 2146/2394] List ext/intl changes also in NEWS --- NEWS | 83 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) diff --git a/NEWS b/NEWS index ca21853331678..568ae659f1e5a 100644 --- a/NEWS +++ b/NEWS @@ -63,6 +63,89 @@ PHP NEWS - Hash . Added support for PBKDF2 via hash_pbkdf2(). (Anthony Ferrara) +- Intl + . The intl extension now requires ICU 4.0+. + . Added intl.use_exceptions INI directive, which controls what happens when + global errors are set together with intl.error_level. (Gustavo) + . MessageFormatter::format() and related functions now accepted named + arguments and mixed numeric/named arguments in ICU 4.8+. (Gustavo) + . MessageFormatter::format() and related functions now don't error out when + an insufficient argument count is provided. Instead, the placeholders will + remain unsubstituted. (Gustavo) + . MessageFormatter::parse() and MessageFormat::format() (and their static + equivalents) don't throw away better than second precision in the arguments. + (Gustavo) + . IntlDateFormatter::__construct and datefmt_create() now accept for the + $timezone argument time zone identifiers, IntlTimeZone objects, DateTimeZone + objects and NULL. (Gustavo) + . IntlDateFormatter::__construct and datefmt_create() no longer accept invalid + timezone identifiers or empty strings. (Gustavo) + . The default time zone used in IntlDateFormatter::__construct and + datefmt_create() (when the corresponding argument is not passed or NULL is + passed) is now the one given by date_default_timezone_get(), not the + default ICU time zone. (Gustavo) + . The time zone passed to the IntlDateFormatter is ignored if it is NULL and + if the calendar passed is an IntlCalendar object -- in this case, the + IntlCalendar's time zone will be used instead. Otherwise, the time zone + specified in the $timezone argument is used instead. This does not affect + old code, as IntlCalendar was introduced in this version. (Gustavo) + . IntlDateFormatter::__construct and datefmt_create() now accept for the + $calendar argument also IntlCalendar objects. (Gustavo) + . IntlDateFormatter::getCalendar() and datefmt_get_calendar() return false + if the IntlDateFormatter was set up with an IntlCalendar instead of the + constants IntlDateFormatter::GREGORIAN/TRADITIONAL. IntlCalendar did not + exist before this version. (Gustavo) + . IntlDateFormatter::setCalendar() and datefmt_set_calendar() now also accept + an IntlCalendar object, in which case its time zone is taken. Passing a + constant is still allowed, and still keeps the time zone. (Gustavo) + . IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are + deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone() + instead. (Gustavo) + . IntlDateFormatter::format() and datefmt_format() now also accept an + IntlCalendar object for formatting. (Gustavo) + . Added the classes: IntlCalendar, IntlGregorianCalendar, IntlTimeZone, + IntlBreakIterator, IntlRuleBasedBreakIterator and + IntlCodePointBreakIterator. (Gustavo) + . Added the functions: intlcal_get_keyword_values_for_locale(), + intlcal_get_now(), intlcal_get_available_locales(), intlcal_get(), + intlcal_get_time(), intlcal_set_time(), intlcal_add(), + intlcal_set_time_zone(), intlcal_after(), intlcal_before(), intlcal_set(), + intlcal_roll(), intlcal_clear(), intlcal_field_difference(), + intlcal_get_actual_maximum(), intlcal_get_actual_minimum(), + intlcal_get_day_of_week_type(), intlcal_get_first_day_of_week(), + intlcal_get_greatest_minimum(), intlcal_get_least_maximum(), + intlcal_get_locale(), intlcal_get_maximum(), + intlcal_get_minimal_days_in_first_week(), intlcal_get_minimum(), + intlcal_get_time_zone(), intlcal_get_type(), + intlcal_get_weekend_transition(), intlcal_in_daylight_time(), + intlcal_is_equivalent_to(), intlcal_is_lenient(), intlcal_is_set(), + intlcal_is_weekend(), intlcal_set_first_day_of_week(), + intlcal_set_lenient(), intlcal_equals(), + intlcal_get_repeated_wall_time_option(), + intlcal_get_skipped_wall_time_option(), + intlcal_set_repeated_wall_time_option(), + intlcal_set_skipped_wall_time_option(), intlcal_from_date_time(), + intlcal_to_date_time(), intlcal_get_error_code(), + intlcal_get_error_message(), intlgregcal_create_instance(), + intlgregcal_set_gregorian_change(), intlgregcal_get_gregorian_change() and + intlgregcal_is_leap_year(). (Gustavo) + . Added the functions: intltz_create_time_zone(), intltz_create_default(), + intltz_get_id(), intltz_get_gmt(), intltz_get_unknown(), + intltz_create_enumeration(), intltz_count_equivalent_ids(), + intltz_create_time_zone_id_enumeration(), intltz_get_canonical_id(), + intltz_get_region(), intltz_get_tz_data_version(), + intltz_get_equivalent_id(), intltz_use_daylight_time(), intltz_get_offset(), + intltz_get_raw_offset(), intltz_has_same_rules(), intltz_get_display_name(), + intltz_get_dst_savings(), intltz_from_date_time_zone(), + intltz_to_date_time_zone(), intltz_get_error_code(), + intltz_get_error_message(). (Gustavo) + . Added the methods: IntlDateFormatter::formatObject(), + IntlDateFormatter::getCalendarObject(), IntlDateFormatter::getTimeZone(), + IntlDateFormatter::setTimeZone(). (Gustavo) + . Added the functions: datefmt_format_object(), datefmt_get_calendar_object(), + datefmt_get_timezone(), datefmt_set_timezone(), + datefmt_get_calendar_object(), intlcal_create_instance(). (Gustavo) + - MCrypt . mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw E_DEPRECATED. (GoogleGuy) From d0727b58da9e76f24f69f42e5418960c1e85e5f0 Mon Sep 17 00:00:00 2001 From: "Bryan Hanks, PMP" Date: Mon, 12 Nov 2012 13:04:32 -0600 Subject: [PATCH 2147/2394] Corrected grammar/spelling of text in php.ini files There are no actual code changes here; I corrected grammar and spelling errors in the php.ini-production and php.ini-development files. I also rewrote some sentences to make them less cumbersome. --- php.ini-development | 52 +++++++++++++++++++++++--------------------- php.ini-production | 53 ++++++++++++++++++++++++--------------------- 2 files changed, 55 insertions(+), 50 deletions(-) diff --git a/php.ini-development b/php.ini-development index a97cd0f9dad94..c29f3c19883a3 100644 --- a/php.ini-development +++ b/php.ini-development @@ -78,11 +78,13 @@ ; compatibility with older or less security conscience applications. We ; recommending using the production ini in production and testing environments. -; php.ini-development is very similar to its production variant, except it's -; much more verbose when it comes to errors. We recommending using the -; development version only in development environments as errors shown to +; php.ini-development is very similar to its production variant, except it is +; much more verbose when it comes to errors. We recommend using the +; development version only in development environments, as errors shown to ; application users can inadvertently leak otherwise secure information. +; This is php.ini-development INI file. + ;;;;;;;;;;;;;;;;;;; ; Quick Reference ; ;;;;;;;;;;;;;;;;;;; @@ -197,13 +199,13 @@ engine = On ; This directive determines whether or not PHP will recognize code between -; tags as PHP source which should be processed as such. It's been -; recommended for several years that you not use the short tag "short cut" and -; instead to use the full tag combination. With the wide spread use +; tags as PHP source which should be processed as such. For several +; years we recommended that you not use the short tag "short cut" and +; instead to use the full tag combination. With the widespread use ; of XML and use of these tags by other languages, the server can become easily -; confused and end up parsing the wrong code in the wrong context. But because -; this short cut has been a feature for such a long time, it's currently still -; supported for backwards compatibility, but we recommend you don't use them. +; confused and end up parsing the wrong code in the wrong context. +; This shortcut is still supported for backwards compatibility, but we +; recommend against its use. ; Default Value: On ; Development Value: Off ; Production Value: Off @@ -432,7 +434,7 @@ memory_limit = 128M ; E_NOTICE - run-time notices (these are warnings which often result ; from a bug in your code, but it's possible that it was ; intentional (e.g., using an uninitialized variable and -; relying on the fact it's automatically initialized to an +; relying on the fact it is automatically initialized to an ; empty string) ; E_STRICT - run-time notices, enable to have PHP suggest changes ; to your code which will ensure the best interoperability @@ -465,8 +467,8 @@ error_reporting = E_ALL ; it could be very dangerous in production environments. Depending on the code ; which is triggering the error, sensitive information could potentially leak ; out of your application such as database usernames and passwords or worse. -; It's recommended that errors be logged on production servers rather than -; having the errors sent to STDOUT. +; For production environments, we recommend logging errors rather than +; sending them to STDOUT. ; Possible Values: ; Off = Do not display any errors ; stderr = Display errors to STDERR (affects only CGI/CLI binaries!) @@ -480,8 +482,8 @@ display_errors = On ; The display of errors which occur during PHP's startup sequence are handled ; separately from display_errors. PHP's default behavior is to suppress those ; errors from clients. Turning the display of startup errors on can be useful in -; debugging configuration problems. But, it's strongly recommended that you -; leave this setting off on production servers. +; debugging configuration problems. We strongly recommend you +; set this to 'off' for production servers. ; Default Value: Off ; Development Value: On ; Production Value: Off @@ -775,8 +777,8 @@ enable_dl = Off ;fastcgi.logging = 0 ; cgi.rfc2616_headers configuration option tells PHP what type of headers to -; use when sending HTTP response code. If it's set 0 PHP sends Status: header that -; is supported by Apache. When this option is set to 1 PHP will send +; use when sending HTTP response code. If set to 0, PHP sends Status: header that +; is supported by Apache. When this option is set to 1, PHP will send ; RFC2616 compliant header. ; Default is zero. ; http://php.net/cgi.rfc2616-headers @@ -1376,9 +1378,9 @@ session.save_handler = files ; ; where N is an integer. Instead of storing all the session files in ; /path, what this will do is use subdirectories N-levels deep, and -; store the session data in those directories. This is useful if you -; or your OS have problems with lots of files in one directory, and is -; a more efficient layout for servers that handle lots of sessions. +; store the session data in those directories. This is useful if +; your OS has problems with many files in one directory, and is +; a more efficient layout for servers that handle many sessions. ; ; NOTE 1: PHP will not create this directory structure automatically. ; You can use the script in the ext/session dir for that purpose. @@ -1405,7 +1407,7 @@ session.use_cookies = 1 ; This option forces PHP to fetch and use a cookie for storing and maintaining ; the session id. We encourage this operation as it's very helpful in combating ; session hijacking when not specifying and managing your own session id. It is -; not the end all be all of session hijacking defense, but it's a good start. +; not the be-all and end-all of session hijacking defense, but it's a good start. ; http://php.net/session.use-only-cookies session.use_only_cookies = 1 @@ -1478,14 +1480,14 @@ session.gc_maxlifetime = 1440 ; PHP 4.2 and less have an undocumented feature/bug that allows you to ; to initialize a session variable in the global scope. -; PHP 4.3 and later will warn you, if this feature is used. +; PHP 4.3 and later will warn you if this feature is used. ; You can disable the feature and the warning separately. At this time, ; the warning is only displayed, if bug_compat_42 is enabled. This feature -; introduces some serious security problems if not handled correctly. It's -; recommended that you do not use this feature on production servers. But you +; introduces some serious security problems if not handled correctly. We +; recommend you not use this feature on production servers. You ; should enable this on development servers and enable the warning as well. If you ; do not enable the feature on development servers, you won't be warned when it's -; used and debugging errors caused by this can be difficult to track down. +; used, so debugging errors caused by this can be difficult to track down. ; Default Value: On ; Development Value: On ; Production Value: Off @@ -1530,7 +1532,7 @@ session.cache_limiter = nocache session.cache_expire = 180 ; trans sid support is disabled by default. -; Use of trans sid may risk your users security. +; Use of trans sid may risk your users' security. ; Use this option with caution. ; - User may send URL contains active session ID ; to other person via. email/irc/etc. diff --git a/php.ini-production b/php.ini-production index dce8fc970ccff..37fee997b2f0c 100644 --- a/php.ini-production +++ b/php.ini-production @@ -78,11 +78,13 @@ ; compatibility with older or less security conscience applications. We ; recommending using the production ini in production and testing environments. -; php.ini-development is very similar to its production variant, except it's -; much more verbose when it comes to errors. We recommending using the -; development version only in development environments as errors shown to +; php.ini-development is very similar to its production variant, except it is +; much more verbose when it comes to errors. We recommend using the +; development version only in development environments, as errors shown to ; application users can inadvertently leak otherwise secure information. +; This is php.ini-production INI file. + ;;;;;;;;;;;;;;;;;;; ; Quick Reference ; ;;;;;;;;;;;;;;;;;;; @@ -197,13 +199,14 @@ engine = On ; This directive determines whether or not PHP will recognize code between -; tags as PHP source which should be processed as such. It's been -; recommended for several years that you not use the short tag "short cut" and -; instead to use the full tag combination. With the wide spread use +; tags as PHP source which should be processed as such. For several +; years we recommended that you not use the short tag "short cut" and +; instead to use the full tag combination. With the widespread use ; of XML and use of these tags by other languages, the server can become easily -; confused and end up parsing the wrong code in the wrong context. But because -; this short cut has been a feature for such a long time, it's currently still -; supported for backwards compatibility, but we recommend you don't use them. +; confused and end up parsing the wrong code in the wrong context. +; This shortcut is still supported for backwards compatibility, but we +; recommend against its use. +; Default Value: On ; Default Value: On ; Development Value: Off ; Production Value: Off @@ -432,7 +435,7 @@ memory_limit = 128M ; E_NOTICE - run-time notices (these are warnings which often result ; from a bug in your code, but it's possible that it was ; intentional (e.g., using an uninitialized variable and -; relying on the fact it's automatically initialized to an +; relying on the fact it is automatically initialized to an ; empty string) ; E_STRICT - run-time notices, enable to have PHP suggest changes ; to your code which will ensure the best interoperability @@ -465,8 +468,8 @@ error_reporting = E_ALL & ~E_DEPRECATED & ~E_STRICT ; it could be very dangerous in production environments. Depending on the code ; which is triggering the error, sensitive information could potentially leak ; out of your application such as database usernames and passwords or worse. -; It's recommended that errors be logged on production servers rather than -; having the errors sent to STDOUT. +; For production environments, we recommend logging errors rather than +; sending them to STDOUT. ; Possible Values: ; Off = Do not display any errors ; stderr = Display errors to STDERR (affects only CGI/CLI binaries!) @@ -480,8 +483,8 @@ display_errors = Off ; The display of errors which occur during PHP's startup sequence are handled ; separately from display_errors. PHP's default behavior is to suppress those ; errors from clients. Turning the display of startup errors on can be useful in -; debugging configuration problems. But, it's strongly recommended that you -; leave this setting off on production servers. +; debugging configuration problems. We strongly recommend you +; set this to 'off' for production servers. ; Default Value: Off ; Development Value: On ; Production Value: Off @@ -775,8 +778,8 @@ enable_dl = Off ;fastcgi.logging = 0 ; cgi.rfc2616_headers configuration option tells PHP what type of headers to -; use when sending HTTP response code. If it's set 0 PHP sends Status: header that -; is supported by Apache. When this option is set to 1 PHP will send +; use when sending HTTP response code. If set to 0, PHP sends Status: header that +; is supported by Apache. When this option is set to 1, PHP will send ; RFC2616 compliant header. ; Default is zero. ; http://php.net/cgi.rfc2616-headers @@ -1376,9 +1379,9 @@ session.save_handler = files ; ; where N is an integer. Instead of storing all the session files in ; /path, what this will do is use subdirectories N-levels deep, and -; store the session data in those directories. This is useful if you -; or your OS have problems with lots of files in one directory, and is -; a more efficient layout for servers that handle lots of sessions. +; store the session data in those directories. This is useful if +; your OS has problems with many files in one directory, and is +; a more efficient layout for servers that handle many sessions. ; ; NOTE 1: PHP will not create this directory structure automatically. ; You can use the script in the ext/session dir for that purpose. @@ -1405,7 +1408,7 @@ session.use_cookies = 1 ; This option forces PHP to fetch and use a cookie for storing and maintaining ; the session id. We encourage this operation as it's very helpful in combating ; session hijacking when not specifying and managing your own session id. It is -; not the end all be all of session hijacking defense, but it's a good start. +; not the be-all and end-all of session hijacking defense, but it's a good start. ; http://php.net/session.use-only-cookies session.use_only_cookies = 1 @@ -1478,14 +1481,14 @@ session.gc_maxlifetime = 1440 ; PHP 4.2 and less have an undocumented feature/bug that allows you to ; to initialize a session variable in the global scope. -; PHP 4.3 and later will warn you, if this feature is used. +; PHP 4.3 and later will warn you if this feature is used. ; You can disable the feature and the warning separately. At this time, ; the warning is only displayed, if bug_compat_42 is enabled. This feature -; introduces some serious security problems if not handled correctly. It's -; recommended that you do not use this feature on production servers. But you +; introduces some serious security problems if not handled correctly. We +; recommend you not use this feature on production servers. You ; should enable this on development servers and enable the warning as well. If you ; do not enable the feature on development servers, you won't be warned when it's -; used and debugging errors caused by this can be difficult to track down. +; used, so debugging errors caused by this can be difficult to track down. ; Default Value: On ; Development Value: On ; Production Value: Off @@ -1530,7 +1533,7 @@ session.cache_limiter = nocache session.cache_expire = 180 ; trans sid support is disabled by default. -; Use of trans sid may risk your users security. +; Use of trans sid may risk your users' security. ; Use this option with caution. ; - User may send URL contains active session ID ; to other person via. email/irc/etc. From e7f8f7c01cedfa0583913721f67b33cdbe6a2cf2 Mon Sep 17 00:00:00 2001 From: "Bryan Hanks, PMP" Date: Mon, 12 Nov 2012 13:12:13 -0600 Subject: [PATCH 2148/2394] Corrected spelling of 'shortcut' --- php.ini-development | 2 +- php.ini-production | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/php.ini-development b/php.ini-development index c29f3c19883a3..ddba771a166cb 100644 --- a/php.ini-development +++ b/php.ini-development @@ -200,7 +200,7 @@ engine = On ; This directive determines whether or not PHP will recognize code between ; tags as PHP source which should be processed as such. For several -; years we recommended that you not use the short tag "short cut" and +; years we recommended that you not use the short tag shortcut and ; instead to use the full tag combination. With the widespread use ; of XML and use of these tags by other languages, the server can become easily ; confused and end up parsing the wrong code in the wrong context. diff --git a/php.ini-production b/php.ini-production index 37fee997b2f0c..86c0e8f1c03e3 100644 --- a/php.ini-production +++ b/php.ini-production @@ -200,7 +200,7 @@ engine = On ; This directive determines whether or not PHP will recognize code between ; tags as PHP source which should be processed as such. For several -; years we recommended that you not use the short tag "short cut" and +; years we recommended that you not use the short tag shortcut and ; instead to use the full tag combination. With the widespread use ; of XML and use of these tags by other languages, the server can become easily ; confused and end up parsing the wrong code in the wrong context. From bc9f8030c7511b13ee151a7af15aaa5bd7ae42b5 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Tue, 13 Nov 2012 14:53:32 +0100 Subject: [PATCH 2149/2394] Fixed sockets ext build on win --- ext/sockets/multicast.c | 3 +++ ext/sockets/sockets.c | 1 + 2 files changed, 4 insertions(+) diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index 670d29f7ad522..e29106087e10c 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -38,6 +38,9 @@ # define NTDDI_XP NTDDI_WINXP /* bug in SDK */ # include # undef NTDDI_XP +# if _WIN32_WINNT >= 0x0600 +# define HAVE_IF_NAMETOINDEX 1 +# endif #else #include #include diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 4adb09f188aa7..1eee7a6202c3f 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -57,6 +57,7 @@ # define h_errno WSAGetLastError() # define set_errno(a) WSASetLastError(a) # define close(a) closesocket(a) +# include # if _WIN32_WINNT >= 0x0600 # define HAVE_IF_NAMETOINDEX 1 # endif From 7e565acca1e721e32fe5072d61c00daa17bed9f7 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Mon, 12 Nov 2012 13:45:15 +0100 Subject: [PATCH 2150/2394] Add missing parts from UPGRADING to NEWS --- NEWS | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 568ae659f1e5a..8cb15f43cf5c7 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,7 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Added support for generators. (Nikita Popov) . Add simplified password hashing API (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) . Add generators and coroutines (https://wiki.php.net/rfc/generators). @@ -15,6 +16,8 @@ PHP NEWS . Add support for using empty() on the result of function calls and other expressions (https://wiki.php.net/rfc/empty_isset_exprs). (Nikita Popov) + . Remove php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), + zend_logo_guid(). (Adnrew Faulds) - Calendar: . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) @@ -22,16 +25,17 @@ PHP NEWS - Core: . Added boolval(). (Jille Timmermans). + . Added "Z" option to pack/unpack. (Gustavo) + . Implemented FR #60738 (Allow 'set_error_handler' to handle NULL). + (Laruence, Nikita Popov) + . Added optional second argument for assert() to specify custom message. Patch + by Lonny Kapelushnik (lonny@lonnylot.com). (Lars) . Fixed bug #18556 (Engine uses locale rules to handle class names). (Stas) . Fixed bug #61681 (Malformed grammar). (Nikita Popov, Etienne, Laruence). . Fixed bug #61038 (unpack("a5", "str\0\0") does not work as expected). (srgoogleguy, Gustavo) - . Implemented FR #60738 (Allow 'set_error_handler' to handle NULL). - (Laruence, Nikita Popov) . Return previous handler when passing NULL to set_error_handler and set_exception_handler. (Nikita Popov) - . Added optional second argument for assert() to specify custom message. Patch - by Lonny Kapelushnik (lonny@lonnylot.com). (Lars) - cURL: . Added support for CURLOPT_FTP_RESPONSE_TIMEOUT, CURLOPT_APPEND, @@ -154,7 +158,6 @@ PHP NEWS . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. Known for stability problems. (Andrey) . Added support for SHA256 authentication available with MySQL 5.6.6+. (Andrey) - - PCRE: . Deprecated the /e modifier @@ -164,6 +167,10 @@ PHP NEWS - pgsql . Added pg_escape_literal() and pg_escape_identifier() (Yasuo) +- SPL + . Fix bug #60560 (SplFixedArray un-/serialize, getSize(), count() return 0, + keys are strings). (Adam) + - Tokenizer: . Fixed bug #60097 (token_get_all fails to lex nested heredoc). (Nikita Popov) From 727b6775efc33f15ecd8049ab35a042f7cc81b3f Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Mon, 12 Nov 2012 13:45:30 +0100 Subject: [PATCH 2151/2394] PHP-5.5 is open --- README.GIT-RULES | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.GIT-RULES b/README.GIT-RULES index 289a4e743f07e..90e0d83cbed42 100644 --- a/README.GIT-RULES +++ b/README.GIT-RULES @@ -45,14 +45,16 @@ Currently we have the following branches in use:: master The active development branch. - PHP-5.4 Is used to release the PHP 5.4.x series. It still allows for - larger enhancements. + PHP-5.5 Is used to release the PHP 5.5.x series. It allows for larger + enhancements. + + PHP-5.4 Is used to release the PHP 5.4.x series. This is current + stable version and is open for bugfixes only. PHP-5.3 Is used to release the PHP 5.3.x series. This is current stable version and is open for bugfixes only. - PHP-5.2 Is used to release the PHP 5.2.x series. It is closed for - changes now. + PHP-5.2 This branch is closed. PHP-5.1 This branch is closed. From f4512d01a0020574d367cb3099984fcd0a04e8bb Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Mon, 12 Nov 2012 14:29:32 +0100 Subject: [PATCH 2152/2394] NEWS: remove dots at the end of the NEWS file --- NEWS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/NEWS b/NEWS index 8cb15f43cf5c7..41f2d2ad3171b 100644 --- a/NEWS +++ b/NEWS @@ -21,17 +21,17 @@ PHP NEWS - Calendar: . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) - (Stas, Eitan Mosenkis). + (Stas, Eitan Mosenkis) - Core: - . Added boolval(). (Jille Timmermans). + . Added boolval(). (Jille Timmermans) . Added "Z" option to pack/unpack. (Gustavo) . Implemented FR #60738 (Allow 'set_error_handler' to handle NULL). (Laruence, Nikita Popov) . Added optional second argument for assert() to specify custom message. Patch by Lonny Kapelushnik (lonny@lonnylot.com). (Lars) . Fixed bug #18556 (Engine uses locale rules to handle class names). (Stas) - . Fixed bug #61681 (Malformed grammar). (Nikita Popov, Etienne, Laruence). + . Fixed bug #61681 (Malformed grammar). (Nikita Popov, Etienne, Laruence) . Fixed bug #61038 (unpack("a5", "str\0\0") does not work as expected). (srgoogleguy, Gustavo) . Return previous handler when passing NULL to set_error_handler and From 217020788a96781d062cf338e515b584eeb5b3a5 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Mon, 12 Nov 2012 17:47:15 +0100 Subject: [PATCH 2153/2394] Build .xz archive during makedist --- makedist | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/makedist b/makedist index bfc8fcc44a239..bce40a9488035 100755 --- a/makedist +++ b/makedist @@ -119,8 +119,14 @@ tar cf $ARCHIVE php-$VER || exit 10 bzip2 -9 $ARCHIVE || exit 11 echo "" +$ECHO_N "makedist: making xz2zipped tar archive...$ECHO_C" +rm -f $ARCHIVE.xz +tar cf $ARCHIVE php-$VER || exit 10 +xz -9 $ARCHIVE || exit 12 +echo "" + $ECHO_N "makedist: cleaning up...$ECHO_C" -rm -rf $DIRPATH || exit 12 +rm -rf $DIRPATH || exit 13 echo "" exit 0 From 012519839a0d3bb4775e53b739c85ade198cacdc Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 13 Nov 2012 17:42:01 +0100 Subject: [PATCH 2154/2394] Bump version to 5.5.99 and reset NEWS --- NEWS | 181 +-------------------------------------------- configure.in | 2 +- main/php_version.h | 6 +- 3 files changed, 5 insertions(+), 184 deletions(-) diff --git a/NEWS b/NEWS index 41f2d2ad3171b..0163102cc5598 100644 --- a/NEWS +++ b/NEWS @@ -1,184 +1,5 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 201?, PHP 5.5.0 - -- General improvements: - . Added support for generators. (Nikita Popov) - . Add simplified password hashing API - (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) - . Add generators and coroutines (https://wiki.php.net/rfc/generators). - (Nikita Popov) - . Support list in foreach (https://wiki.php.net/rfc/foreachlist). (Laruence) - . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) - . Drop Windows XP and 2003 support. (Pierre) - . Improve set_exception_handler while doing reset.(Laruence) - . Support constant array/string dereferencing. (Laruence) - . Add support for using empty() on the result of function calls and - other expressions (https://wiki.php.net/rfc/empty_isset_exprs). - (Nikita Popov) - . Remove php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), - zend_logo_guid(). (Adnrew Faulds) - -- Calendar: - . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) - (Stas, Eitan Mosenkis) - -- Core: - . Added boolval(). (Jille Timmermans) - . Added "Z" option to pack/unpack. (Gustavo) - . Implemented FR #60738 (Allow 'set_error_handler' to handle NULL). - (Laruence, Nikita Popov) - . Added optional second argument for assert() to specify custom message. Patch - by Lonny Kapelushnik (lonny@lonnylot.com). (Lars) - . Fixed bug #18556 (Engine uses locale rules to handle class names). (Stas) - . Fixed bug #61681 (Malformed grammar). (Nikita Popov, Etienne, Laruence) - . Fixed bug #61038 (unpack("a5", "str\0\0") does not work as expected). - (srgoogleguy, Gustavo) - . Return previous handler when passing NULL to set_error_handler and - set_exception_handler. (Nikita Popov) - -- cURL: - . Added support for CURLOPT_FTP_RESPONSE_TIMEOUT, CURLOPT_APPEND, - CURLOPT_DIRLISTONLY, CURLOPT_NEW_DIRECTORY_PERMS, CURLOPT_NEW_FILE_PERMS, - CURLOPT_NETRC_FILE, CURLOPT_PREQUOTE, CURLOPT_KRBLEVEL, CURLOPT_MAXFILESIZE, - CURLOPT_FTP_ACCOUNT, CURLOPT_COOKIELIST, CURLOPT_IGNORE_CONTENT_LENGTH, - CURLOPT_CONNECT_ONLY, CURLOPT_LOCALPORT, CURLOPT_LOCALPORTRANGE, - CURLOPT_FTP_ALTERNATIVE_TO_USER, CURLOPT_SSL_SESSIONID_CACHE, - CURLOPT_FTP_SSL_CCC, CURLOPT_HTTP_CONTENT_DECODING, - CURLOPT_HTTP_TRANSFER_DECODING, CURLOPT_PROXY_TRANSFER_MODE, - CURLOPT_ADDRESS_SCOPE, CURLOPT_CRLFILE, CURLOPT_ISSUERCERT, - CURLOPT_USERNAME, CURLOPT_PASSWORD, CURLOPT_PROXYUSERNAME, - CURLOPT_PROXYPASSWORD, CURLOPT_NOPROXY, CURLOPT_SOCKS5_GSSAPI_NEC, - CURLOPT_SOCKS5_GSSAPI_SERVICE, CURLOPT_TFTP_BLKSIZE, - CURLOPT_SSH_KNOWNHOSTS, CURLOPT_FTP_USE_PRET, CURLOPT_MAIL_FROM, - CURLOPT_MAIL_RCPT, CURLOPT_RTSP_CLIENT_CSEQ, CURLOPT_RTSP_SERVER_CSEQ, - CURLOPT_RTSP_SESSION_ID, CURLOPT_RTSP_STREAM_URI, CURLOPT_RTSP_TRANSPORT, - CURLOPT_RTSP_REQUEST, CURLOPT_RESOLVE, CURLOPT_ACCEPT_ENCODING, - CURLOPT_TRANSFER_ENCODING, CURLOPT_DNS_SERVERS and CURLOPT_USE_SSL. - (Pierrick) - . Fixed bug #55635 (CURLOPT_BINARYTRANSFER no longer used. The constant - still exists for backward compatibility but is doing nothing). (Pierrick) - . Fixed bug #54995 (Missing CURLINFO_RESPONSE_CODE support). (Pierrick) - -- Datetime - . Fixed bug #61642 (modify("+5 weekdays") returns Sunday). - (Dmitri Iouchtchenko) - -- Hash - . Added support for PBKDF2 via hash_pbkdf2(). (Anthony Ferrara) - -- Intl - . The intl extension now requires ICU 4.0+. - . Added intl.use_exceptions INI directive, which controls what happens when - global errors are set together with intl.error_level. (Gustavo) - . MessageFormatter::format() and related functions now accepted named - arguments and mixed numeric/named arguments in ICU 4.8+. (Gustavo) - . MessageFormatter::format() and related functions now don't error out when - an insufficient argument count is provided. Instead, the placeholders will - remain unsubstituted. (Gustavo) - . MessageFormatter::parse() and MessageFormat::format() (and their static - equivalents) don't throw away better than second precision in the arguments. - (Gustavo) - . IntlDateFormatter::__construct and datefmt_create() now accept for the - $timezone argument time zone identifiers, IntlTimeZone objects, DateTimeZone - objects and NULL. (Gustavo) - . IntlDateFormatter::__construct and datefmt_create() no longer accept invalid - timezone identifiers or empty strings. (Gustavo) - . The default time zone used in IntlDateFormatter::__construct and - datefmt_create() (when the corresponding argument is not passed or NULL is - passed) is now the one given by date_default_timezone_get(), not the - default ICU time zone. (Gustavo) - . The time zone passed to the IntlDateFormatter is ignored if it is NULL and - if the calendar passed is an IntlCalendar object -- in this case, the - IntlCalendar's time zone will be used instead. Otherwise, the time zone - specified in the $timezone argument is used instead. This does not affect - old code, as IntlCalendar was introduced in this version. (Gustavo) - . IntlDateFormatter::__construct and datefmt_create() now accept for the - $calendar argument also IntlCalendar objects. (Gustavo) - . IntlDateFormatter::getCalendar() and datefmt_get_calendar() return false - if the IntlDateFormatter was set up with an IntlCalendar instead of the - constants IntlDateFormatter::GREGORIAN/TRADITIONAL. IntlCalendar did not - exist before this version. (Gustavo) - . IntlDateFormatter::setCalendar() and datefmt_set_calendar() now also accept - an IntlCalendar object, in which case its time zone is taken. Passing a - constant is still allowed, and still keeps the time zone. (Gustavo) - . IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are - deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone() - instead. (Gustavo) - . IntlDateFormatter::format() and datefmt_format() now also accept an - IntlCalendar object for formatting. (Gustavo) - . Added the classes: IntlCalendar, IntlGregorianCalendar, IntlTimeZone, - IntlBreakIterator, IntlRuleBasedBreakIterator and - IntlCodePointBreakIterator. (Gustavo) - . Added the functions: intlcal_get_keyword_values_for_locale(), - intlcal_get_now(), intlcal_get_available_locales(), intlcal_get(), - intlcal_get_time(), intlcal_set_time(), intlcal_add(), - intlcal_set_time_zone(), intlcal_after(), intlcal_before(), intlcal_set(), - intlcal_roll(), intlcal_clear(), intlcal_field_difference(), - intlcal_get_actual_maximum(), intlcal_get_actual_minimum(), - intlcal_get_day_of_week_type(), intlcal_get_first_day_of_week(), - intlcal_get_greatest_minimum(), intlcal_get_least_maximum(), - intlcal_get_locale(), intlcal_get_maximum(), - intlcal_get_minimal_days_in_first_week(), intlcal_get_minimum(), - intlcal_get_time_zone(), intlcal_get_type(), - intlcal_get_weekend_transition(), intlcal_in_daylight_time(), - intlcal_is_equivalent_to(), intlcal_is_lenient(), intlcal_is_set(), - intlcal_is_weekend(), intlcal_set_first_day_of_week(), - intlcal_set_lenient(), intlcal_equals(), - intlcal_get_repeated_wall_time_option(), - intlcal_get_skipped_wall_time_option(), - intlcal_set_repeated_wall_time_option(), - intlcal_set_skipped_wall_time_option(), intlcal_from_date_time(), - intlcal_to_date_time(), intlcal_get_error_code(), - intlcal_get_error_message(), intlgregcal_create_instance(), - intlgregcal_set_gregorian_change(), intlgregcal_get_gregorian_change() and - intlgregcal_is_leap_year(). (Gustavo) - . Added the functions: intltz_create_time_zone(), intltz_create_default(), - intltz_get_id(), intltz_get_gmt(), intltz_get_unknown(), - intltz_create_enumeration(), intltz_count_equivalent_ids(), - intltz_create_time_zone_id_enumeration(), intltz_get_canonical_id(), - intltz_get_region(), intltz_get_tz_data_version(), - intltz_get_equivalent_id(), intltz_use_daylight_time(), intltz_get_offset(), - intltz_get_raw_offset(), intltz_has_same_rules(), intltz_get_display_name(), - intltz_get_dst_savings(), intltz_from_date_time_zone(), - intltz_to_date_time_zone(), intltz_get_error_code(), - intltz_get_error_message(). (Gustavo) - . Added the methods: IntlDateFormatter::formatObject(), - IntlDateFormatter::getCalendarObject(), IntlDateFormatter::getTimeZone(), - IntlDateFormatter::setTimeZone(). (Gustavo) - . Added the functions: datefmt_format_object(), datefmt_get_calendar_object(), - datefmt_get_timezone(), datefmt_set_timezone(), - datefmt_get_calendar_object(), intlcal_create_instance(). (Gustavo) - -- MCrypt - . mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw - E_DEPRECATED. (GoogleGuy) - -- MySQLi - . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. - Known for stability problems. (Andrey) - . Added support for SHA256 authentication available with MySQL 5.6.6+. (Andrey) - -- PCRE: - . Deprecated the /e modifier - (https://wiki.php.net/rfc/remove_preg_replace_eval_modifier). (Nikita Popov) - . Fixed bug #63284 (Upgrade PCRE to 8.31). (Anatoliy) - -- pgsql - . Added pg_escape_literal() and pg_escape_identifier() (Yasuo) - -- SPL - . Fix bug #60560 (SplFixedArray un-/serialize, getSize(), count() return 0, - keys are strings). (Adam) - -- Tokenizer: - . Fixed bug #60097 (token_get_all fails to lex nested heredoc). (Nikita Popov) - -- Zip: - . Upgraded libzip to 0.10.1 (Anatoliy) - -- Fileinfo: - . Fixed bug #63248 (Load multiple magic files from a directory under Windows). - (Anatoliy) +?? ??? 201?, PHP 5.5.99 <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> diff --git a/configure.in b/configure.in index 704801ec32f37..987619230df34 100644 --- a/configure.in +++ b/configure.in @@ -119,7 +119,7 @@ int zend_sprintf(char *buffer, const char *format, ...); PHP_MAJOR_VERSION=5 PHP_MINOR_VERSION=5 -PHP_RELEASE_VERSION=0 +PHP_RELEASE_VERSION=99 PHP_EXTRA_VERSION="-dev" PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION" PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION` diff --git a/main/php_version.h b/main/php_version.h index 1995834e03426..a2b18829b47e0 100644 --- a/main/php_version.h +++ b/main/php_version.h @@ -2,7 +2,7 @@ /* edit configure.in to change version number */ #define PHP_MAJOR_VERSION 5 #define PHP_MINOR_VERSION 5 -#define PHP_RELEASE_VERSION 0 +#define PHP_RELEASE_VERSION 99 #define PHP_EXTRA_VERSION "-dev" -#define PHP_VERSION "5.5.0-dev" -#define PHP_VERSION_ID 50500 +#define PHP_VERSION "5.5.99-dev" +#define PHP_VERSION_ID 50599 From d71577d2df5c27dee4e476cda3369a937acd82a0 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 13 Nov 2012 20:43:08 +0100 Subject: [PATCH 2155/2394] Bump version to 5.6.0 --- NEWS | 2 +- configure.in | 4 ++-- main/php_version.h | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/NEWS b/NEWS index 0163102cc5598..f753a83ba80c3 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,5 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 201?, PHP 5.5.99 +?? ??? 201?, PHP 5.6.0 <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> diff --git a/configure.in b/configure.in index 987619230df34..9811236f12dd8 100644 --- a/configure.in +++ b/configure.in @@ -118,8 +118,8 @@ int zend_sprintf(char *buffer, const char *format, ...); ]) PHP_MAJOR_VERSION=5 -PHP_MINOR_VERSION=5 -PHP_RELEASE_VERSION=99 +PHP_MINOR_VERSION=6 +PHP_RELEASE_VERSION=0 PHP_EXTRA_VERSION="-dev" PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION" PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION` diff --git a/main/php_version.h b/main/php_version.h index a2b18829b47e0..d48bf13c6f7ff 100644 --- a/main/php_version.h +++ b/main/php_version.h @@ -1,8 +1,8 @@ /* automatically generated by configure */ /* edit configure.in to change version number */ #define PHP_MAJOR_VERSION 5 -#define PHP_MINOR_VERSION 5 -#define PHP_RELEASE_VERSION 99 +#define PHP_MINOR_VERSION 6 +#define PHP_RELEASE_VERSION 0 #define PHP_EXTRA_VERSION "-dev" -#define PHP_VERSION "5.5.99-dev" -#define PHP_VERSION_ID 50599 +#define PHP_VERSION "5.6.0-dev" +#define PHP_VERSION_ID 50600 From ad4a87f798a43642ca7686df61a010a5b988684c Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 13 Nov 2012 20:56:17 +0100 Subject: [PATCH 2156/2394] Bump API versions --- Zend/zend_extensions.h | 2 +- Zend/zend_modules.h | 2 +- main/php.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_extensions.h b/Zend/zend_extensions.h index b3f510ac127bf..703e03c3f64e8 100644 --- a/Zend/zend_extensions.h +++ b/Zend/zend_extensions.h @@ -28,7 +28,7 @@ /* The first number is the engine version and the rest is the date. * This way engine 2/3 API no. is always greater than engine 1 API no.. */ -#define ZEND_EXTENSION_API_NO 220100525 +#define ZEND_EXTENSION_API_NO 220121113 typedef struct _zend_extension_version_info { int zend_extension_api_no; diff --git a/Zend/zend_modules.h b/Zend/zend_modules.h index ad15a96624a9e..442535bc68408 100644 --- a/Zend/zend_modules.h +++ b/Zend/zend_modules.h @@ -33,7 +33,7 @@ #define ZEND_MODULE_INFO_FUNC_ARGS zend_module_entry *zend_module TSRMLS_DC #define ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU zend_module TSRMLS_CC -#define ZEND_MODULE_API_NO 20100525 +#define ZEND_MODULE_API_NO 20121113 #ifdef ZTS #define USING_ZTS 1 #else diff --git a/main/php.h b/main/php.h index 192635200a669..1c1ffa3a612c8 100644 --- a/main/php.h +++ b/main/php.h @@ -26,7 +26,7 @@ #include #endif -#define PHP_API_VERSION 20100412 +#define PHP_API_VERSION 20121113 #define PHP_HAVE_STREAMS #define YYDEBUG 0 From e73beb82dfec93e4e196604107355b21bb2f166e Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Wed, 14 Nov 2012 10:15:42 +0100 Subject: [PATCH 2157/2394] Updated NEWS --- NEWS | 3 +++ UPGRADING | 11 +++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 41f2d2ad3171b..cc4cb1d6d13fc 100644 --- a/NEWS +++ b/NEWS @@ -181,4 +181,7 @@ PHP NEWS . Fixed bug #63248 (Load multiple magic files from a directory under Windows). (Anatoliy) +- Apache2 Handler SAPI: + . Enabled Apache 2.4 configure option for Windows (Pierre, Anatoliy) + <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> diff --git a/UPGRADING b/UPGRADING index 0e497f743db93..e6362becf7917 100755 --- a/UPGRADING +++ b/UPGRADING @@ -13,7 +13,8 @@ PHP X.Y UPGRADE NOTES 8. Other Changes to Extensions 9. New Global Constants 10. Changes to INI File Handling -11. Other Changes +11. Windows Support +12. Other Changes ======================================== @@ -247,9 +248,15 @@ PHP X.Y UPGRADE NOTES APIs which use(are built) for mysqlnd. This allows ext/mysqli to be used with the new auth protocol, although at coarser level. +======================================== +11. Windows Support +======================================== + +- Apache 2.4 handler is supported as of PHP 5.5.0 + ======================================== -11. Other Changes +12. Other Changes ======================================== - Logo GUIDs will no longer work From 79726be67d891f2b0e09c9839347191e60581df2 Mon Sep 17 00:00:00 2001 From: Sebastian Bergmann Date: Wed, 14 Nov 2012 16:50:33 +0100 Subject: [PATCH 2158/2394] Leftover: Bump version to 5.6.0 --- Zend/zend.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend.h b/Zend/zend.h index d2a4ef6957868..0f98aad0dcbc6 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -22,7 +22,7 @@ #ifndef ZEND_H #define ZEND_H -#define ZEND_VERSION "2.5.0-dev" +#define ZEND_VERSION "2.6.0-dev" #define ZEND_ENGINE_2 From f85ae48f4f06af3cf20e96e51cf7a86afcd3670f Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Wed, 14 Nov 2012 21:18:16 +0100 Subject: [PATCH 2159/2394] Fixed ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt There is a constant now which only is there when mysqli with mysqlnd and pdo_mysql was compiled at the same time, or when libmysql version > 50605. So checking for that dynamically, will fail only if there is no mysqli and no connection. --- ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt index 17fa5d6059353..2545307cfbc3c 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt @@ -29,6 +29,14 @@ require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); $expected['MYSQL_ATTR_READ_DEFAULT_GROUP'] = true; } + if (extension_loaded('mysqli') && stristr(mysqli_get_client_info(), "mysqlnd") + || MySQLPDOTest::getClientVersion(MySQLPDOTest::factory()) > 50605) { + /* XXX the MySQL client library version isn't exposed with any + constants, the single possibility is to use the PDO::getAttribute(). + This however will fail with no connection. */ + $expected['MYSQL_ATTR_SERVER_PUBLIC_KEY'] = true; + } + /* TODO From 36fadde72c577577bba88a31d1d399fcf3998a01 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Thu, 15 Nov 2012 14:31:55 +0100 Subject: [PATCH 2160/2394] Fixed ext/intl/tests/timezone_createDefault_basic.phpt Timezone offsets can be negative --- ext/intl/tests/timezone_createDefault_basic.phpt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/intl/tests/timezone_createDefault_basic.phpt b/ext/intl/tests/timezone_createDefault_basic.phpt index a18899fc4f9ce..1988d3b9e5464 100644 --- a/ext/intl/tests/timezone_createDefault_basic.phpt +++ b/ext/intl/tests/timezone_createDefault_basic.phpt @@ -18,14 +18,14 @@ IntlTimeZone Object ( [valid] => 1 [id] => %s - [rawOffset] => %d - [currentOffset] => %d + [rawOffset] => %i + [currentOffset] => %i ) IntlTimeZone Object ( [valid] => 1 [id] => %s - [rawOffset] => %d - [currentOffset] => %d + [rawOffset] => %i + [currentOffset] => %i ) -==DONE== \ No newline at end of file +==DONE== From ab4c270ccf71060f98b209852f2b73f2c134900d Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Fri, 16 Nov 2012 04:33:17 +0000 Subject: [PATCH 2161/2394] Move the deprecated functions up to the Deprecated Functionality section so they're more visible. --- UPGRADING | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/UPGRADING b/UPGRADING index e6362becf7917..c0f1f9bcf9f31 100755 --- a/UPGRADING +++ b/UPGRADING @@ -56,6 +56,12 @@ PHP X.Y UPGRADE NOTES - The preg_replace /e modifier is now deprecated. Use preg_replace_callback instead. (https://wiki.php.net/rfc/remove_preg_replace_eval_modifier) +- IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are + deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone() + instead. +- mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw + E_DEPRECATED. Their use was already previously discouraged in the docs, + but that predated the existence of E_DEPRECATED. ======================================== 4. Changed Functions @@ -98,14 +104,8 @@ PHP X.Y UPGRADE NOTES - IntlDateFormatter::setCalendar() and datefmt_set_calendar() now also accept an IntlCalendar object, in which case its time zone is taken. Passing a constant is still allowed, and still keeps the time zone. -- IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are - deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone() - instead. - IntlDateFormatter::format() and datefmt_format() now also accept an IntlCalendar object for formatting. -- mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw - E_DEPRECATED. Their use was already previously discouraged in the docs, - but that predated the existence of E_DEPRECATED. - php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and zend_logo_guid() have been removed - set_error_handler(NULL) can now be used to reset the error handler. From d207e6551b11e5fb0a0fad154048203ac73f8fe2 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Fri, 16 Nov 2012 04:34:10 +0000 Subject: [PATCH 2162/2394] Put the new php.ini directives together. (And make colon usage more consistent.) --- UPGRADING | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/UPGRADING b/UPGRADING index c0f1f9bcf9f31..41ec330e11076 100755 --- a/UPGRADING +++ b/UPGRADING @@ -231,19 +231,23 @@ PHP X.Y UPGRADE NOTES - Intl: - This extension now requires ICU 4.0+. - - Added intl.use_exceptions INI directive, which controls what happens when - global errors are set together with intl.error_level. ======================================== 9. New Global Constants ======================================== -- mysqli + +- mysqli: - Added MYSQLI_SERVER_PUBLIC_KEY constant to be used with mysqli_options() ======================================== 10. Changes to INI File Handling ======================================== -- mysqlnd + +- Intl: + - Added intl.use_exceptions INI directive, which controls what happens when + global errors are set together with intl.error_level. + +- mysqlnd: - Added mysqlnd.sha256_server_public_key INI PERDIR setting that affects all APIs which use(are built) for mysqlnd. This allows ext/mysqli to be used with the new auth protocol, although at coarser level. From ca418b233ca41ee12c80770925cc55e6c96dda4c Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Sun, 18 Nov 2012 14:28:26 -0800 Subject: [PATCH 2163/2394] Remove PHP 5.5 changes from master UPGRADING --- UPGRADING | 179 ------------------------------------------------------ 1 file changed, 179 deletions(-) diff --git a/UPGRADING b/UPGRADING index 0e497f743db93..79b855ad90989 100755 --- a/UPGRADING +++ b/UPGRADING @@ -20,28 +20,11 @@ PHP X.Y UPGRADE NOTES 1. Backward Incompatible Changes ======================================== -- Drop Windows XP and 2003 support. (Pierre) -- All internal case insensitivity handling for class, function and constant - names is done according to ASCII rules, current locale settings are ignored. -- php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and - zend_logo_guid() have been removed -- Removal of Logo GUIDs ======================================== 2. New Features ======================================== -- Support list in foreach. (Laruence) - (wiki.php.net/rfc/foreachlist) -- Support finally keyword. (Laruence) - (wiki.php.net/rfc/finally) -- Support constant array/string dereferencing. (Laruence) - (https://wiki.php.net/rfc/constdereference) -- Add support for using empty() on the result of function calls and - other expressions. Thus it is now possible to write empty(getArray()), - for example. (https://wiki.php.net/rfc/empty_isset_exprs) -- Added generators. - (https://wiki.php.net/rfc/generators) ======================================== 2. Changes in SAPI modules @@ -52,172 +35,21 @@ PHP X.Y UPGRADE NOTES 3. Deprecated Functionality ======================================== -- The preg_replace /e modifier is now deprecated. Use - preg_replace_callback instead. - (https://wiki.php.net/rfc/remove_preg_replace_eval_modifier) ======================================== 4. Changed Functions ======================================== -- pack()/unpack() had the following changes, which bring it more in line - with Perl's behavior: - - Implemented format character "Z": NUL-padded string - - "a" now does not remove trailing NUL characters on unpack() anymore - - "A" will now strip all trailing ASCII whitespace on unpack() (it used to - remove only trailing spaces). -- MessageFormatter::format() and related functions now accepted named arguments - and mixed numeric/named arguments in ICU 4.8+. -- MessageFormatter::format() and related functions now don't error out when - an insufficient argument count is provided. Instead, the placeholders will - remain unsubstituted. -- MessageFormatter::parse() and MessageFormat::format() (and their static - equivalents) now don't throw away better than second precision in the - arguments. -- IntlDateFormatter::__construct and datefmt_create() now accept for the - $timezone argument time zone identifiers, IntlTimeZone objects, DateTimeZone - objects and NULL. It used to accept only time zone identifiers and NULL. - Invalid time zone identifiers are no longer accepted. Emptry strings are - no longer accepted. -- The default time zone used in IntlDateFormatter::__construct and - datefmt_create() (when the corresponding argument is not passed or NULL is - passed) is now the one given by date_default_timezone_get(), not the - default ICU time zone. -- The time zone passed to the IntlDateFormatter is ignored if it is NULL and if - the calendar passed is an IntlCalendar object -- in this case, the - IntlCalendar's time zone will be used instead. Otherwise, the time zone - specified in the $timezone argument is used instead. This does not affect - old code, as IntlCalendar was introduced in this version. -- IntlDateFormatter::__construct and datefmt_create() now accept for the - $calendar argument also IntlCalendar objects. -- IntlDateFormatter::getCalendar() and datefmt_get_calendar() return false - if the IntlDateFormatter was set up with an IntlCalendar instead of the - constants IntlDateFormatter::GREGORIAN/TRADITIONAL. IntlCalendar did not - exist before this version. -- IntlDateFormatter::setCalendar() and datefmt_set_calendar() now also accept - an IntlCalendar object, in which case its time zone is taken. Passing a - constant is still allowed, and still keeps the time zone. -- IntlDateFormatter::setTimeZoneID() and datefmt_set_timezone_id() are - deprecated. Use IntlDateFormatter::setTimeZone() or datefmt_set_timezone() - instead. -- IntlDateFormatter::format() and datefmt_format() now also accept an - IntlCalendar object for formatting. -- mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw - E_DEPRECATED. Their use was already previously discouraged in the docs, - but that predated the existence of E_DEPRECATED. -- php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and - zend_logo_guid() have been removed -- set_error_handler(NULL) can now be used to reset the error handler. - Furthermore both set_error_handler(NULL) and set_exception_handler(NULL) will - now return the previously defined error/exception handler. Previously - bool(true) was returned. ======================================== 5. New Functions ======================================== -- Core: - - boolval() - -- Hash: - - hash_pbkdf2() - -- Intl: - - datefmt_format_object() - - datefmt_get_calendar_object() - - datefmt_get_timezone() - - datefmt_set_timezone() - - datefmt_get_calendar_object() - - intlcal_create_instance() - - intlcal_get_keyword_values_for_locale() - - intlcal_get_now() - - intlcal_get_available_locales() - - intlcal_get() - - intlcal_get_time() - - intlcal_set_time() - - intlcal_add() - - intlcal_set_time_zone() - - intlcal_after() - - intlcal_before() - - intlcal_set() - - intlcal_roll() - - intlcal_clear() - - intlcal_field_difference() - - intlcal_get_actual_maximum() - - intlcal_get_actual_minimum() - - intlcal_get_day_of_week_type() - - intlcal_get_first_day_of_week() - - intlcal_get_greatest_minimum() - - intlcal_get_least_maximum() - - intlcal_get_locale() - - intlcal_get_maximum() - - intlcal_get_minimal_days_in_first_week() - - intlcal_get_minimum() - - intlcal_get_time_zone() - - intlcal_get_type() - - intlcal_get_weekend_transition() - - intlcal_in_daylight_time() - - intlcal_is_equivalent_to() - - intlcal_is_lenient() - - intlcal_is_set() - - intlcal_is_weekend() - - intlcal_set_first_day_of_week() - - intlcal_set_lenient() - - intlcal_equals() - - intlcal_get_repeated_wall_time_option() - - intlcal_get_skipped_wall_time_option() - - intlcal_set_repeated_wall_time_option() - - intlcal_set_skipped_wall_time_option() - - intlcal_from_date_time() - - intlcal_to_date_time() - - intlcal_get_error_code() - - intlcal_get_error_message() - - intlgregcal_create_instance() - - intlgregcal_set_gregorian_change() - - intlgregcal_get_gregorian_change() - - intlgregcal_is_leap_year() - - intltz_create_time_zone() - - intltz_create_default() - - intltz_get_id() - - intltz_get_gmt() - - intltz_get_unknown() - - intltz_create_enumeration() - - intltz_count_equivalent_ids() - - intltz_create_time_zone_id_enumeration() - - intltz_get_canonical_id() - - intltz_get_region() - - intltz_get_tz_data_version() - - intltz_get_equivalent_id() - - intltz_use_daylight_time() - - intltz_get_offset() - - intltz_get_raw_offset() - - intltz_has_same_rules() - - intltz_get_display_name() - - intltz_get_dst_savings() - - intltz_from_date_time_zone() - - intltz_to_date_time_zone() - - intltz_get_error_code() - - intltz_get_error_message() - - - IntlDateFormatter::formatObject() - - IntlDateFormatter::getCalendarObject() - - IntlDateFormatter::getTimeZone() - - IntlDateFormatter::setTimeZone() - -- SPL: - - SplFixedArray::__wakeup() ======================================== 6. New Classes and Interfaces ======================================== -- Intl: - - IntlCalendar - - IntlGregorianCalendar - - IntlTimeZone - - IntlBreakIterator - - IntlRuleBasedBreakIterator - - IntlCodePointBreakIterator ======================================== 7. Removed Extensions @@ -228,28 +60,17 @@ PHP X.Y UPGRADE NOTES 8. Other Changes to Extensions ======================================== -- Intl: - - This extension now requires ICU 4.0+. - - Added intl.use_exceptions INI directive, which controls what happens when - global errors are set together with intl.error_level. ======================================== 9. New Global Constants ======================================== -- mysqli - - Added MYSQLI_SERVER_PUBLIC_KEY constant to be used with mysqli_options() ======================================== 10. Changes to INI File Handling ======================================== -- mysqlnd - - Added mysqlnd.sha256_server_public_key INI PERDIR setting that affects all - APIs which use(are built) for mysqlnd. This allows ext/mysqli to be used - with the new auth protocol, although at coarser level. ======================================== 11. Other Changes ======================================== -- Logo GUIDs will no longer work From 885a4562ab335a5592b4a4afe0413ca7d892ce44 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Sun, 18 Nov 2012 14:43:26 -0800 Subject: [PATCH 2164/2394] Add actual branch version number to UPGRADING --- UPGRADING | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UPGRADING b/UPGRADING index 41ec330e11076..f7f88ac7d9ce2 100755 --- a/UPGRADING +++ b/UPGRADING @@ -1,6 +1,6 @@ $Id$ -PHP X.Y UPGRADE NOTES +PHP 5.5 UPGRADE NOTES 1. Backward Incompatible Changes 2. New Features From f909e058352aa2b725bc4cb2053c6e3ef8e98c14 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Wed, 21 Nov 2012 09:25:05 +0800 Subject: [PATCH 2165/2394] Add the new password functions to UPGRADING. As a public service announcement on behalf of the documentation team, please remember to update UPGRADING as well as NEWS when adding features to master or an alpha branch. :) --- UPGRADING | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/UPGRADING b/UPGRADING index f7f88ac7d9ce2..18ab6bf22ecc0 100755 --- a/UPGRADING +++ b/UPGRADING @@ -119,6 +119,10 @@ PHP 5.5 UPGRADE NOTES - Core: - boolval() + - password_get_info() + - password_hash() + - password_needs_rehash() + - password_verify() - Hash: - hash_pbkdf2() From aba80d09e6462a5799208deb70b82222d4671360 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Wed, 21 Nov 2012 12:17:41 +0800 Subject: [PATCH 2166/2394] Update credits for 5.5 --- ext/standard/credits_ext.h | 8 ++++---- ext/standard/credits_sapi.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/standard/credits_ext.h b/ext/standard/credits_ext.h index 22ac8225278f4..382e70e7d7fc3 100644 --- a/ext/standard/credits_ext.h +++ b/ext/standard/credits_ext.h @@ -42,12 +42,12 @@ CREDIT_LINE("MS SQL", "Frank M. Kromann"); CREDIT_LINE("Multibyte String Functions", "Tsukada Takuya, Rui Hirokawa"); CREDIT_LINE("MySQL driver for PDO", "George Schlossnagle, Wez Furlong, Ilia Alshanetsky, Johannes Schlueter"); CREDIT_LINE("MySQLi", "Zak Greant, Georg Richter, Andrey Hristov, Ulf Wendel"); -CREDIT_LINE("MySQLnd", "Georg Richter, Andrey Hristov, Ulf Wendel"); +CREDIT_LINE("MySQLnd", "Andrey Hristov, Ulf Wendel, Georg Richter"); CREDIT_LINE("MySQL", "Zeev Suraski, Zak Greant, Georg Richter"); CREDIT_LINE("OCI8", "Stig Bakken, Thies C. Arntzen, Andy Sautins, David Benson, Maxim Maletsky, Harald Radi, Antony Dovgal, Andi Gutmans, Wez Furlong, Christopher Jones, Oracle Corporation"); CREDIT_LINE("ODBC driver for PDO", "Wez Furlong"); CREDIT_LINE("ODBC", "Stig Bakken, Andreas Karajannis, Frank M. Kromann, Daniel R. Kalowsky"); -CREDIT_LINE("OpenSSL", "Stig Venaas, Wez Furlong, Sascha Kettler"); +CREDIT_LINE("OpenSSL", "Stig Venaas, Wez Furlong, Sascha Kettler, Scott MacVicar"); CREDIT_LINE("Oracle (OCI) driver for PDO", "Wez Furlong"); CREDIT_LINE("pcntl", "Jason Greene, Arnaud Le Blanc"); CREDIT_LINE("Perl Compatible Regexps", "Andrei Zmievski"); @@ -64,11 +64,11 @@ CREDIT_LINE("Reflection", "Marcus Boerger, Timm Friebe, George Schlossnagle, And CREDIT_LINE("Sessions", "Sascha Schumann, Andrei Zmievski"); CREDIT_LINE("Shared Memory Operations", "Slava Poliakov, Ilia Alshanetsky"); CREDIT_LINE("SimpleXML", "Sterling Hughes, Marcus Boerger, Rob Richards"); -CREDIT_LINE("SNMP", "Rasmus Lerdorf, Harrie Hazewinkel, Mike Jackson, Steven Lawrance, Johann Hanne"); +CREDIT_LINE("SNMP", "Rasmus Lerdorf, Harrie Hazewinkel, Mike Jackson, Steven Lawrance, Johann Hanne, Boris Lytochkin"); CREDIT_LINE("SOAP", "Brad Lafountain, Shane Caraveo, Dmitry Stogov"); CREDIT_LINE("Sockets", "Chris Vandomelen, Sterling Hughes, Daniel Beulshausen, Jason Greene"); CREDIT_LINE("SPL", "Marcus Boerger, Etienne Kneuss"); -CREDIT_LINE("SQLite3", "Scott MacVicar, Ilia Alshanetsky"); +CREDIT_LINE("SQLite3", "Scott MacVicar, Ilia Alshanetsky, Brad Dewar"); CREDIT_LINE("SQLite 3.x driver for PDO", "Wez Furlong"); CREDIT_LINE("Sybase-CT", "Zeev Suraski, Tom May, Timm Friebe"); CREDIT_LINE("System V Message based IPC", "Wez Furlong"); diff --git a/ext/standard/credits_sapi.h b/ext/standard/credits_sapi.h index 9cc7e6e224f2d..d147d8deae221 100644 --- a/ext/standard/credits_sapi.h +++ b/ext/standard/credits_sapi.h @@ -17,7 +17,7 @@ CREDIT_LINE("Apache 2.0 Filter", "Sascha Schumann, Aaron Bannert"); CREDIT_LINE("Apache 2.0 Handler", "Ian Holsman, Justin Erenkrantz (based on Apache 2.0 Filter code)"); CREDIT_LINE("Caudium / Roxen", "David Hedbor"); CREDIT_LINE("CGI / FastCGI", "Rasmus Lerdorf, Stig Bakken, Shane Caraveo, Dmitry Stogov"); -CREDIT_LINE("CLI", "Edin Kadribasic, Marcus Boerger, Johannes Schlueter"); +CREDIT_LINE("CLI", "Edin Kadribasic, Marcus Boerger, Johannes Schlueter, Moriyoshi Koizumi, Xinchen Hui"); CREDIT_LINE("Continuity", "Alex Leigh (based on nsapi code)"); CREDIT_LINE("Embed", "Edin Kadribasic"); CREDIT_LINE("FastCGI Process Manager", "Andrei Nigmatulin, dreamcat4, Antony Dovgal, Jerome Loyet"); From c733f28bd9f151490c7b388540a19b47cef333f9 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 21 Nov 2012 18:42:01 +0100 Subject: [PATCH 2167/2394] Add myself to QA --- ext/standard/credits.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/credits.c b/ext/standard/credits.c index e87cdcad8be99..695c06ead814f 100644 --- a/ext/standard/credits.c +++ b/ext/standard/credits.c @@ -105,7 +105,7 @@ PHPAPI void php_print_credits(int flag TSRMLS_DC) /* {{{ */ if (flag & PHP_CREDITS_QA) { php_info_print_table_start(); php_info_print_table_header(1, "PHP Quality Assurance Team"); - php_info_print_table_row(1, "Ilia Alshanetsky, Joerg Behrens, Antony Dovgal, Stefan Esser, Moriyoshi Koizumi, Magnus Maatta, Sebastian Nohn, Derick Rethans, Melvyn Sopacua, Jani Taskinen, Pierre-Alain Joye, Dmitry Stogov, Felipe Pena"); + php_info_print_table_row(1, "Ilia Alshanetsky, Joerg Behrens, Antony Dovgal, Stefan Esser, Moriyoshi Koizumi, Magnus Maatta, Sebastian Nohn, Derick Rethans, Melvyn Sopacua, Jani Taskinen, Pierre-Alain Joye, Dmitry Stogov, Felipe Pena, David Soria Parra"); php_info_print_table_end(); } From eb4825b50b1f4d20b574d8f66acf26e35180e7e6 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 22 Nov 2012 15:17:05 +0400 Subject: [PATCH 2168/2394] Improved "finally" im[plementation --- Zend/zend_compile.c | 34 +++- Zend/zend_compile.h | 6 +- Zend/zend_generators.c | 1 - Zend/zend_opcode.c | 182 ++++++++++++++++---- Zend/zend_vm_def.h | 231 +++++++------------------- Zend/zend_vm_execute.h | 350 +++++++++++++++------------------------ Zend/zend_vm_execute.skl | 1 - Zend/zend_vm_opcodes.h | 3 +- 8 files changed, 375 insertions(+), 433 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index c9714e5a0d26d..de77068db55fe 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2709,6 +2709,7 @@ static int zend_add_try_element(zend_uint try_op TSRMLS_DC) /* {{{ */ CG(active_op_array)->try_catch_array = erealloc(CG(active_op_array)->try_catch_array, sizeof(zend_try_catch_element)*CG(active_op_array)->last_try_catch); CG(active_op_array)->try_catch_array[try_catch_offset].try_op = try_op; + CG(active_op_array)->try_catch_array[try_catch_offset].catch_op = 0; CG(active_op_array)->try_catch_array[try_catch_offset].finally_op = 0; CG(active_op_array)->try_catch_array[try_catch_offset].finally_end = 0; return try_catch_offset; @@ -2770,9 +2771,25 @@ void zend_do_try(znode *try_token TSRMLS_DC) /* {{{ */ } /* }}} */ -void zend_do_finally(znode *finally_token TSRMLS_DC) /* {{{ */ { +void zend_do_finally(znode *finally_token TSRMLS_DC) /* {{{ */ +{ + zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); + finally_token->u.op.opline_num = get_next_op_number(CG(active_op_array)); -} /* }}} */ + /* call the the "finally" block */ + opline->opcode = ZEND_FAST_CALL; + SET_UNUSED(opline->op1); + opline->op1.opline_num = finally_token->u.op.opline_num + 1; + SET_UNUSED(opline->op2); + /* jump to code after the "finally" block, + * the actual jump address is going to be set in zend_do_end_finally() + */ + opline = get_next_op(CG(active_op_array) TSRMLS_CC); + opline->opcode = ZEND_JMP; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); +} +/* }}} */ void zend_do_begin_catch(znode *catch_token, znode *class_name, znode *catch_var, znode *first_catch TSRMLS_DC) /* {{{ */ { @@ -2837,18 +2854,19 @@ void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_to zend_error(E_COMPILE_ERROR, "Cannot use try without catch or finally"); } if (finally_token->op_type != IS_UNUSED) { - zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); - CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num; + zend_op *opline; + + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num + 1; CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_end = get_next_op_number(CG(active_op_array)); CG(active_op_array)->has_finally_block = 1; - opline->opcode = ZEND_LEAVE; + opline = get_next_op(CG(active_op_array) TSRMLS_CC); + opline->opcode = ZEND_FAST_RET; SET_UNUSED(opline->op1); SET_UNUSED(opline->op2); + + CG(active_op_array)->opcodes[finally_token->u.op.opline_num].op1.opline_num = get_next_op_number(CG(active_op_array)); } - if (catch_token->op_type == IS_UNUSED) { - CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].catch_op = 0; - } } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 77809dae5aaad..e46c1a39ce764 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -387,8 +387,7 @@ struct _zend_execute_data { zend_class_entry *current_called_scope; zval *current_this; zval *current_object; - zend_uint leaving; - zend_uint leaving_dest; + struct _zend_op *fast_ret; /* used by FAST_CALL/FAST_RET (finally keyword) */ }; #define EX(element) execute_data.element @@ -826,6 +825,9 @@ int zend_add_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC); #define ZEND_RETURNS_FUNCTION 1<<0 #define ZEND_RETURNS_NEW 1<<1 +#define ZEND_FAST_RET_TO_CATCH 1 +#define ZEND_FAST_RET_TO_FINALLY 2 + END_EXTERN_C() #define ZEND_CLONE_FUNC_NAME "__clone" diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 87f0644e81e5f..516ff0b6ebb19 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -60,7 +60,6 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio * the resume. */ if (finally_op_num) { execute_data->opline = &op_array->opcodes[finally_op_num]; - execute_data->leaving = ZEND_RETURN; generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; zend_generator_resume(generator TSRMLS_CC); return; diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 224c7a209bb64..563c84301daa1 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -499,24 +499,168 @@ static void zend_extension_op_array_handler(zend_extension *extension, zend_op_a } } -static void zend_check_finally_breakout(zend_op_array *op_array, zend_op *opline, zend_uint dst_num TSRMLS_DC) { - zend_uint i, op_num = opline - op_array->opcodes; - for (i=0; i < op_array->last_try_catch; i++) { +static void zend_check_finally_breakout(zend_op_array *op_array, zend_uint op_num, zend_uint dst_num TSRMLS_DC) +{ + zend_uint i; + + for (i = 0; i < op_array->last_try_catch; i++) { if (op_array->try_catch_array[i].try_op > op_num) { break; } if ((op_num >= op_array->try_catch_array[i].finally_op - && op_num < op_array->try_catch_array[i].finally_end) - && (dst_num >= op_array->try_catch_array[i].finally_end + && op_num <= op_array->try_catch_array[i].finally_end) + && (dst_num > op_array->try_catch_array[i].finally_end || dst_num < op_array->try_catch_array[i].finally_op)) { CG(in_compilation) = 1; CG(active_op_array) = op_array; - CG(zend_lineno) = opline->lineno; + CG(zend_lineno) = op_array->opcodes[op_num].lineno; zend_error(E_COMPILE_ERROR, "jump out of a finally block is disallowed"); } } } +static void zend_resolve_finally_call(zend_op_array *op_array, zend_uint op_num, zend_uint dst_num TSRMLS_DC) +{ + zend_uint start_op; + zend_op *opline; + zend_uint i = op_array->last_try_catch; + + if (dst_num != (zend_uint)-1) { + zend_check_finally_breakout(op_array, op_num, dst_num TSRMLS_CC); + } + + /* the backward order is mater */ + while (i > 0) { + i--; + if (op_array->try_catch_array[i].finally_op && + op_num >= op_array->try_catch_array[i].try_op && + op_num < op_array->try_catch_array[i].finally_op - 1 && + (dst_num < op_array->try_catch_array[i].try_op || + dst_num > op_array->try_catch_array[i].finally_end)) { + /* we have a jump out of try block that needs executing finally */ + + /* generate a FAST_CALL to finaly block */ + start_op = get_next_op_number(op_array); + opline = get_next_op(op_array TSRMLS_CC); + opline->opcode = ZEND_FAST_CALL; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + opline->op1.opline_num = op_array->try_catch_array[i].finally_op; + if (op_array->try_catch_array[i].catch_op) { + opline->extended_value = 1; + opline->op2.opline_num = op_array->try_catch_array[i].catch_op; + } + + /* generate a sequence of FAST_CALL to upward finaly block */ + while (i > 0) { + i--; + if (op_array->try_catch_array[i].finally_op && + op_num >= op_array->try_catch_array[i].try_op && + op_num < op_array->try_catch_array[i].finally_op - 1 && + (dst_num < op_array->try_catch_array[i].try_op || + dst_num > op_array->try_catch_array[i].finally_end)) { + + opline = get_next_op(op_array TSRMLS_CC); + opline->opcode = ZEND_FAST_CALL; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + opline->op1.opline_num = op_array->try_catch_array[i].finally_op; + } + } + + /* Finish the sequence with original opcode */ + opline = get_next_op(op_array TSRMLS_CC); + *opline = op_array->opcodes[op_num]; + + /* Replace original opcode with jump to this sequence */ + opline = op_array->opcodes + op_num; + opline->opcode = ZEND_JMP; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + opline->op1.opline_num = start_op; + + break; + } + } +} + +static void zend_resolve_finally_ret(zend_op_array *op_array, zend_uint op_num TSRMLS_DC) +{ + int i; + zend_uint catch_op_num = 0, finally_op_num = 0; + + for (i = 0; i < op_array->last_try_catch; i++) { + if (op_array->try_catch_array[i].try_op > op_num) { + break; + } + if (op_num < op_array->try_catch_array[i].finally_op) { + finally_op_num = op_array->try_catch_array[i].finally_op; + } + if (op_num < op_array->try_catch_array[i].catch_op) { + catch_op_num = op_array->try_catch_array[i].catch_op; + } + } + + if (finally_op_num && (!catch_op_num || catch_op_num >= finally_op_num)) { + /* in case of unhandled exception return to upward finally block */ + op_array->opcodes[op_num].extended_value = ZEND_FAST_RET_TO_FINALLY; + op_array->opcodes[op_num].op2.opline_num = finally_op_num; + } else if (catch_op_num) { + /* in case of unhandled exception return to upward catch block */ + op_array->opcodes[op_num].extended_value = ZEND_FAST_RET_TO_CATCH; + op_array->opcodes[op_num].op2.opline_num = catch_op_num; + } +} + +static void zend_resolve_finally_calls(zend_op_array *op_array TSRMLS_DC) +{ + zend_uint i; + zend_op *opline; + + for (i = 0; i < op_array->last; i++) { + opline = op_array->opcodes + i; + switch (opline->opcode) { + case ZEND_RETURN: + case ZEND_RETURN_BY_REF: + zend_resolve_finally_call(op_array, i, (zend_uint)-1 TSRMLS_CC); + break; + case ZEND_BRK: + case ZEND_CONT: + { + int nest_levels, array_offset; + zend_brk_cont_element *jmp_to; + + nest_levels = Z_LVAL(op_array->literals[opline->op2.constant].constant); + array_offset = opline->op1.opline_num; + do { + jmp_to = &op_array->brk_cont_array[array_offset]; + if (nest_levels > 1) { + array_offset = jmp_to->parent; + } + } while (--nest_levels > 0); + zend_resolve_finally_call(op_array, i, opline->opcode == ZEND_BRK ? jmp_to->brk : jmp_to->cont TSRMLS_CC); + break; + } + case ZEND_GOTO: + if (Z_TYPE(op_array->literals[opline->op2.constant].constant) != IS_LONG) { + zend_uint num = opline->op2.constant; + opline->op2.zv = &op_array->literals[opline->op2.constant].constant; + zend_resolve_goto_label(op_array, opline, 1 TSRMLS_CC); + opline->op2.constant = num; + } + /* break omitted intentionally */ + case ZEND_JMP: + zend_resolve_finally_call(op_array, i, opline->op1.opline_num TSRMLS_CC); + break; + case ZEND_FAST_RET: + zend_resolve_finally_ret(op_array, i TSRMLS_CC); + break; + default: + break; + } + } +} + ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) { zend_op *opline, *end; @@ -524,6 +668,9 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) if (op_array->type!=ZEND_USER_FUNCTION && op_array->type!=ZEND_EVAL_CODE) { return 0; } + if (op_array->has_finally_block) { + zend_resolve_finally_calls(op_array TSRMLS_CC); + } if (CG(compiler_options) & ZEND_COMPILE_EXTENDED_INFO) { zend_update_extended_info(op_array TSRMLS_CC); } @@ -560,30 +707,9 @@ ZEND_API int pass_two(zend_op_array *op_array TSRMLS_DC) } /* break omitted intentionally */ case ZEND_JMP: - if (op_array->last_try_catch) { - zend_check_finally_breakout(op_array, opline, opline->op1.opline_num TSRMLS_CC); - } + case ZEND_FAST_CALL: opline->op1.jmp_addr = &op_array->opcodes[opline->op1.opline_num]; break; - case ZEND_BRK: - case ZEND_CONT: - if (op_array->last_try_catch) { - int nest_levels, array_offset; - zend_brk_cont_element *jmp_to; - - nest_levels = Z_LVAL_P(opline->op2.zv); - array_offset = opline->op1.opline_num; - do { - jmp_to = &op_array->brk_cont_array[array_offset]; - if (nest_levels > 1) { - array_offset = jmp_to->parent; - } - } while (--nest_levels > 0); - if (op_array->last_try_catch) { - zend_check_finally_breakout(op_array, opline, jmp_to->brk TSRMLS_CC); - } - } - break; case ZEND_JMPZ: case ZEND_JMPNZ: case ZEND_JMPZ_EX: diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index b06c09f483a34..4ae4ca1267592 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1845,6 +1845,12 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) zend_bool nested; zend_op_array *op_array = EX(op_array); + if (EXPECTED(EG(exception) == NULL) && + UNEXPECTED(EG(prev_exception) != NULL)) { + /* return from finally block called because of unhandled exception */ + zend_exception_restore(TSRMLS_C); + } + /* Generators go throw a different cleanup process */ if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { /* The generator object is stored in return_value_ptr_ptr */ @@ -2125,101 +2131,6 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HELPER_EX(zend_finally_handler_leaving, ANY, ANY, int type) -{ - USE_OPLINE - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - - SAVE_OPLINE(); - - switch (type) { - case ZEND_THROW: - case ZEND_RETURN: - case ZEND_RETURN_BY_REF: - case ZEND_LEAVE: - { - if (EG(prev_exception) || (type == ZEND_LEAVE && EG(exception))) { - for (i=0; ilast_try_catch; i++) { - if (EX(op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EX(op_array)->try_catch_array[i].finally_op) { - finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - } - if (op_num < EX(op_array)->try_catch_array[i].catch_op) { - catch_op_num = EX(op_array)->try_catch_array[i].catch_op; - } - } - } else { - for (i=0; ilast_try_catch; i++) { - if (EX(op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EX(op_array)->try_catch_array[i].finally_op) { - finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - } - } - } - - if (catch_op_num && finally_op_num) { - /* EG(exception) || EG(prev_exception) */ - if (catch_op_num > finally_op_num) { - zend_exception_save(TSRMLS_C); - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } - } else if (catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } else if (finally_op_num) { - zend_exception_save(TSRMLS_C); - if (type != ZEND_LEAVE) { - EX(leaving) = type; - } - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else if (EX(leaving) && type != ZEND_LEAVE) { - /* leave it to ZEND_LEAVE */ - EX(leaving) = type; - ZEND_VM_NEXT_OPCODE(); - } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - } - break; - case ZEND_JMP: - case ZEND_BRK: - case ZEND_CONT: - case ZEND_GOTO: - { - /* these can not occurred in exception context */ - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op - && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op - || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - - if (finally_op_num) { - EX(leaving) = type; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); - } - } - break; - } - ZEND_VM_CONTINUE(); -} - ZEND_VM_HANDLER(42, ZEND_JMP, ANY, ANY) { USE_OPLINE @@ -2227,12 +2138,8 @@ ZEND_VM_HANDLER(42, ZEND_JMP, ANY, ANY) #if DEBUG_ZEND>=2 printf("Jumping to %d\n", opline->op1.opline_num); #endif - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); - ZEND_VM_CONTINUE(); /* CHECK_ME */ - } - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_JMP); + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); } ZEND_VM_HANDLER(43, ZEND_JMPZ, CONST|TMP|VAR|CV, ANY) @@ -2972,11 +2879,7 @@ ZEND_VM_HANDLER(62, ZEND_RETURN, CONST|TMP|VAR|CV, ANY) *EG(return_value_ptr_ptr) = ret; } FREE_OP1_IF_VAR(); - - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) @@ -3048,18 +2951,11 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) } while (0); FREE_OP1_IF_VAR(); - - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); - } - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN_BY_REF); + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } ZEND_VM_HANDLER(161, ZEND_GENERATOR_RETURN, ANY, ANY) { - if (EX(op_array)->has_finally_block) { - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_RETURN); - } ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } @@ -3404,11 +3300,7 @@ ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); - } - EX(leaving_dest) = el->brk; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_BRK); + ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) @@ -3420,11 +3312,7 @@ ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); FREE_OP2(); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); - } - EX(leaving_dest) = el->cont; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_CONT); + ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) @@ -3451,11 +3339,7 @@ ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) } break; } - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_JMP(opline->op1.jmp_addr); - } - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, ZEND_GOTO); + ZEND_VM_JMP(opline->op1.jmp_addr); } ZEND_VM_HANDLER(48, ZEND_CASE, CONST|TMP|VAR|CV, CONST|TMP|VAR|CV) @@ -5134,7 +5018,6 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) zend_uint op_num = EG(opline_before_exception)-EG(active_op_array)->opcodes; int i; zend_uint catch_op_num = 0, finally_op_num = 0; - int catched = 0, finally = 0; void **stack_frame; /* Figure out where the next stack frame (which maybe contains pushed @@ -5167,11 +5050,9 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) } if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; - catched = i + 1; } if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - finally = i + 1; } } @@ -5199,7 +5080,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) /* further blocks will not be relevant... */ break; } else if (op_num < EX(op_array)->brk_cont_array[i].brk) { - if (!catched || + if (!catch_op_num || catch_op_num >= EX(op_array)->brk_cont_array[i].brk) { zend_op *brk_opline = &EX(op_array)->opcodes[EX(op_array)->brk_cont_array[i].brk]; @@ -5231,26 +5112,14 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) } EX(old_error_reporting) = NULL; - if (catched && finally) { - if (finally_op_num > catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else { - zend_exception_save(TSRMLS_C); - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catched) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally) { + if (finally_op_num && (!catch_op_num || catch_op_num >= finally_op_num)) { zend_exception_save(TSRMLS_C); - EX(leaving) = ZEND_THROW; + EX(fast_ret) = NULL; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); } else { ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); } @@ -5371,30 +5240,6 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(159, ZEND_LEAVE, ANY, ANY) -{ - zend_exception_restore(TSRMLS_C); - if (!EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); - } else { - zend_uint leaving = EX(leaving); - switch (leaving) { - case ZEND_RETURN: - case ZEND_RETURN_BY_REF: - case ZEND_THROW: - leaving = ZEND_LEAVE; - case ZEND_JMP: - case ZEND_BRK: - case ZEND_CONT: - case ZEND_GOTO: - ZEND_VM_DISPATCH_TO_HELPER_EX(zend_finally_handler_leaving, type, leaving); - break; - } - } - - ZEND_VM_CONTINUE(); -} - ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) { USE_OPLINE @@ -5552,4 +5397,42 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE ZEND_VM_RETURN(); } +ZEND_VM_HANDLER(162, ZEND_FAST_CALL, ANY, ANY) +{ + USE_OPLINE + + if (opline->extended_value && + UNEXPECTED(EG(prev_exception) != NULL)) { + /* in case of unhandled exception jump to catch block instead of finally */ + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); + } + EX(fast_ret) = opline + 1; + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); +} + +ZEND_VM_HANDLER(163, ZEND_FAST_RET, ANY, ANY) +{ + if (EX(fast_ret)) { + ZEND_VM_SET_OPCODE(EX(fast_ret)); + ZEND_VM_CONTINUE(); + } else { + /* special case for unhandled exceptions */ + USE_OPLINE + + if (opline->extended_value == ZEND_FAST_RET_TO_FINALLY) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); + } else if (opline->extended_value == ZEND_FAST_RET_TO_CATCH) { + zend_exception_restore(TSRMLS_C); + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); + } else { + zend_exception_restore(TSRMLS_C); + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } + } +} + ZEND_VM_EXPORT_HELPER(zend_do_fcall, zend_do_fcall_common_helper) diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 7a2cfc88d90de..582962cfcf5bb 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -385,7 +385,6 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra EX(prev_execute_data) = EG(current_execute_data); EG(current_execute_data) = execute_data; EX(nested) = nested; - EX(leaving) = 0; if (!op_array->run_time_cache && op_array->last_cache_slot) { op_array->run_time_cache = ecalloc(op_array->last_cache_slot, sizeof(void*)); @@ -466,6 +465,12 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) zend_bool nested; zend_op_array *op_array = EX(op_array); + if (EXPECTED(EG(exception) == NULL) && + UNEXPECTED(EG(prev_exception) != NULL)) { + /* return from finally block called because of unhandled exception */ + zend_exception_restore(TSRMLS_C); + } + /* Generators go throw a different cleanup process */ if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { /* The generator object is stored in return_value_ptr_ptr */ @@ -746,101 +751,6 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_finally_handler_leaving_SPEC(int type, ZEND_OPCODE_HANDLER_ARGS) -{ - USE_OPLINE - zend_uint i, op_num = opline - EX(op_array)->opcodes; - zend_uint catch_op_num = 0, finally_op_num = 0; - - SAVE_OPLINE(); - - switch (type) { - case ZEND_THROW: - case ZEND_RETURN: - case ZEND_RETURN_BY_REF: - case ZEND_LEAVE: - { - if (EG(prev_exception) || (type == ZEND_LEAVE && EG(exception))) { - for (i=0; ilast_try_catch; i++) { - if (EX(op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EX(op_array)->try_catch_array[i].finally_op) { - finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - } - if (op_num < EX(op_array)->try_catch_array[i].catch_op) { - catch_op_num = EX(op_array)->try_catch_array[i].catch_op; - } - } - } else { - for (i=0; ilast_try_catch; i++) { - if (EX(op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EX(op_array)->try_catch_array[i].finally_op) { - finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - } - } - } - - if (catch_op_num && finally_op_num) { - /* EG(exception) || EG(prev_exception) */ - if (catch_op_num > finally_op_num) { - zend_exception_save(TSRMLS_C); - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } - } else if (catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - } else if (finally_op_num) { - zend_exception_save(TSRMLS_C); - if (type != ZEND_LEAVE) { - EX(leaving) = type; - } - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else if (EX(leaving) && type != ZEND_LEAVE) { - /* leave it to ZEND_LEAVE */ - EX(leaving) = type; - ZEND_VM_NEXT_OPCODE(); - } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - } - break; - case ZEND_JMP: - case ZEND_BRK: - case ZEND_CONT: - case ZEND_GOTO: - { - /* these can not occurred in exception context */ - for (i=0; ilast_try_catch; i++) { - if (EG(active_op_array)->try_catch_array[i].try_op > op_num) { - break; - } - if (op_num < EG(active_op_array)->try_catch_array[i].finally_op - && (EX(leaving_dest) < EG(active_op_array)->try_catch_array[i].try_op - || EX(leaving_dest) >= EG(active_op_array)->try_catch_array[i].finally_end)) { - finally_op_num = EG(active_op_array)->try_catch_array[i].finally_op; - } - } - - if (finally_op_num) { - EX(leaving) = type; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - } else { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[EX(leaving_dest)]); - } - } - break; - } - ZEND_VM_CONTINUE(); -} - static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -848,12 +758,8 @@ static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) #if DEBUG_ZEND>=2 printf("Jumping to %d\n", opline->op1.opline_num); #endif - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); - ZEND_VM_CONTINUE(); /* CHECK_ME */ - } - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - return zend_finally_handler_leaving_SPEC(ZEND_JMP, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); } static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -880,9 +786,6 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - if (EX(op_array)->has_finally_block) { - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -1168,7 +1071,6 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER zend_uint op_num = EG(opline_before_exception)-EG(active_op_array)->opcodes; int i; zend_uint catch_op_num = 0, finally_op_num = 0; - int catched = 0, finally = 0; void **stack_frame; /* Figure out where the next stack frame (which maybe contains pushed @@ -1201,11 +1103,9 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER } if (op_num < EG(active_op_array)->try_catch_array[i].catch_op) { catch_op_num = EX(op_array)->try_catch_array[i].catch_op; - catched = i + 1; } if (op_num < EG(active_op_array)->try_catch_array[i].finally_op) { finally_op_num = EX(op_array)->try_catch_array[i].finally_op; - finally = i + 1; } } @@ -1233,7 +1133,7 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER /* further blocks will not be relevant... */ break; } else if (op_num < EX(op_array)->brk_cont_array[i].brk) { - if (!catched || + if (!catch_op_num || catch_op_num >= EX(op_array)->brk_cont_array[i].brk) { zend_op *brk_opline = &EX(op_array)->opcodes[EX(op_array)->brk_cont_array[i].brk]; @@ -1265,26 +1165,14 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER } EX(old_error_reporting) = NULL; - if (catched && finally) { - if (finally_op_num > catch_op_num) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else { - zend_exception_save(TSRMLS_C); - EX(leaving) = ZEND_THROW; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); - ZEND_VM_CONTINUE(); - } - } else if (catched) { - EX(leaving) = 0; - ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); - ZEND_VM_CONTINUE(); - } else if (finally) { + if (finally_op_num && (!catch_op_num || catch_op_num >= finally_op_num)) { zend_exception_save(TSRMLS_C); - EX(leaving) = ZEND_THROW; + EX(fast_ret) = NULL; ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[finally_op_num]); ZEND_VM_CONTINUE(); + } else if (catch_op_num) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); + ZEND_VM_CONTINUE(); } else { return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -1325,28 +1213,42 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } -static int ZEND_FASTCALL ZEND_LEAVE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - zend_exception_restore(TSRMLS_C); - if (!EX(leaving)) { - ZEND_VM_NEXT_OPCODE(); + USE_OPLINE + + if (opline->extended_value && + UNEXPECTED(EG(prev_exception) != NULL)) { + /* in case of unhandled exception jump to catch block instead of finally */ + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); + } + EX(fast_ret) = opline + 1; + ZEND_VM_SET_OPCODE(opline->op1.jmp_addr); + ZEND_VM_CONTINUE(); +} + +static int ZEND_FASTCALL ZEND_FAST_RET_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + if (EX(fast_ret)) { + ZEND_VM_SET_OPCODE(EX(fast_ret)); + ZEND_VM_CONTINUE(); } else { - zend_uint leaving = EX(leaving); - switch (leaving) { - case ZEND_RETURN: - case ZEND_RETURN_BY_REF: - case ZEND_THROW: - leaving = ZEND_LEAVE; - case ZEND_JMP: - case ZEND_BRK: - case ZEND_CONT: - case ZEND_GOTO: - return zend_finally_handler_leaving_SPEC(leaving, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - break; + /* special case for unhandled exceptions */ + USE_OPLINE + + if (opline->extended_value == ZEND_FAST_RET_TO_FINALLY) { + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); + } else if (opline->extended_value == ZEND_FAST_RET_TO_CATCH) { + zend_exception_restore(TSRMLS_C); + ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); + ZEND_VM_CONTINUE(); + } else { + zend_exception_restore(TSRMLS_C); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } - - ZEND_VM_CONTINUE(); } static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1587,11 +1489,7 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); - } - EX(leaving_dest) = el->brk; - return zend_finally_handler_leaving_SPEC(ZEND_BRK, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1603,11 +1501,7 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, EX(op_array), EX_Ts() TSRMLS_CC); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); - } - EX(leaving_dest) = el->cont; - return zend_finally_handler_leaving_SPEC(ZEND_CONT, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1634,11 +1528,7 @@ static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } break; } - if (EXPECTED(!EX(op_array)->has_finally_block)) { - ZEND_VM_JMP(opline->op1.jmp_addr); - } - EX(leaving_dest) = opline->op1.jmp_addr - EX(op_array)->opcodes; - return zend_finally_handler_leaving_SPEC(ZEND_GOTO, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + ZEND_VM_JMP(opline->op1.jmp_addr); } static int ZEND_FASTCALL ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2501,10 +2391,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG *EG(return_value_ptr_ptr) = ret; } - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -2575,10 +2462,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7822,10 +7706,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -7896,10 +7777,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -13048,11 +12926,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -13124,11 +12998,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE } while (0); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -30620,10 +30490,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -30694,10 +30561,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - if (EXPECTED(!EX(op_array)->has_finally_block)) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - } - return zend_finally_handler_leaving_SPEC(ZEND_RETURN_BY_REF, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -44964,31 +44828,31 @@ void zend_init_opcodes_handlers(void) ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, - ZEND_LEAVE_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, ZEND_YIELD_SPEC_CONST_CONST_HANDLER, ZEND_YIELD_SPEC_CONST_TMP_HANDLER, ZEND_YIELD_SPEC_CONST_VAR_HANDLER, @@ -45039,6 +44903,56 @@ void zend_init_opcodes_handlers(void) ZEND_GENERATOR_RETURN_SPEC_HANDLER, ZEND_GENERATOR_RETURN_SPEC_HANDLER, ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, ZEND_NULL_HANDLER }; zend_opcode_handlers = (opcode_handler_t*)labels; diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index 2a6fd71ecb5a4..e2d5dd12b039b 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -46,7 +46,6 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra EX(prev_execute_data) = EG(current_execute_data); EG(current_execute_data) = execute_data; EX(nested) = nested; - EX(leaving) = 0; if (!op_array->run_time_cache && op_array->last_cache_slot) { op_array->run_time_cache = ecalloc(op_array->last_cache_slot, sizeof(void*)); diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 7f9434995483e..52f6cde59e71f 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -159,6 +159,7 @@ #define ZEND_SEPARATE 156 #define ZEND_QM_ASSIGN_VAR 157 #define ZEND_JMP_SET_VAR 158 -#define ZEND_LEAVE 159 #define ZEND_YIELD 160 #define ZEND_GENERATOR_RETURN 161 +#define ZEND_FAST_CALL 162 +#define ZEND_FAST_RET 163 From 60871e51ada0644f258c991d67adba22d38f8a7b Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Sat, 24 Nov 2012 18:21:11 +0100 Subject: [PATCH 2169/2394] Fix bug #63596: finally in generators segfaults EX(fast_ret) wasn't initialized in this case so the code ended up dereferencing an invalid pointer after the jump. --- Zend/tests/generators/finally_ran_on_close.phpt | 17 +++++++++++------ Zend/zend_generators.c | 1 + 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/Zend/tests/generators/finally_ran_on_close.phpt b/Zend/tests/generators/finally_ran_on_close.phpt index 44a84fae5c799..04a0561c87993 100644 --- a/Zend/tests/generators/finally_ran_on_close.phpt +++ b/Zend/tests/generators/finally_ran_on_close.phpt @@ -5,14 +5,18 @@ finally is run even if a generator is closed mid-execution function gen() { try { - echo "before yield\n"; - yield; - echo "after yield\n"; + try { + echo "before yield\n"; + yield; + echo "after yield\n"; + } finally { + echo "finally run\n"; + } + echo "code after finally\n"; } finally { - echo "finally run\n"; + echo "second finally run\n"; } - - echo "code after finally\n"; + echo "code after second finally\n"; } $gen = gen(); @@ -23,3 +27,4 @@ unset($gen); --EXPECT-- before yield finally run +second finally run diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 516ff0b6ebb19..1895305875323 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -60,6 +60,7 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio * the resume. */ if (finally_op_num) { execute_data->opline = &op_array->opcodes[finally_op_num]; + execute_data->fast_ret = NULL; generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; zend_generator_resume(generator TSRMLS_CC); return; From f03a91226e525ab48aa9049eaa2d8202ac4113d1 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 25 Nov 2012 11:45:36 +0800 Subject: [PATCH 2170/2394] let make test report the run-test result (patch by reeze.xia@gmail.com) --- Makefile.global | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile.global b/Makefile.global index eaf651e8e2ab7..5118de83fe453 100644 --- a/Makefile.global +++ b/Makefile.global @@ -102,7 +102,9 @@ test: all TEST_PHP_SRCDIR=$(top_srcdir) \ CC="$(CC)" \ $(PHP_EXECUTABLE) -n -c $(top_builddir)/tmp-php.ini $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n -c $(top_builddir)/tmp-php.ini -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \ + TEST_RESULT_EXIT_CODE=$$?; \ rm $(top_builddir)/tmp-php.ini; \ + exit $$TEST_RESULT_EXIT_CODE; \ else \ echo "ERROR: Cannot run tests without CLI sapi."; \ fi From 20d7ef43f751f5044909257d0baef963c8ea451a Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 25 Nov 2012 11:46:35 +0800 Subject: [PATCH 2171/2394] XFAIL test should not be considered as failed --- run-tests.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/run-tests.php b/run-tests.php index 8527df8d4bd94..43470d0d8ad57 100755 --- a/run-tests.php +++ b/run-tests.php @@ -821,7 +821,7 @@ function save_or_mail_results() junit_save_xml(); - if (getenv('REPORT_EXIT_STATUS') == 1 and preg_match('/FAILED(?: |$)/', implode(' ', $test_results))) { + if (getenv('REPORT_EXIT_STATUS') == 1 and preg_match('/ FAILED(?: |$)/', implode(' ', $test_results))) { exit(1); } From 4d804aa52d8c74ddcbdb07694b75b38c5eba8004 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 25 Nov 2012 11:45:36 +0800 Subject: [PATCH 2172/2394] let make test report the run-test result --- Makefile.global | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile.global b/Makefile.global index eaf651e8e2ab7..5118de83fe453 100644 --- a/Makefile.global +++ b/Makefile.global @@ -102,7 +102,9 @@ test: all TEST_PHP_SRCDIR=$(top_srcdir) \ CC="$(CC)" \ $(PHP_EXECUTABLE) -n -c $(top_builddir)/tmp-php.ini $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n -c $(top_builddir)/tmp-php.ini -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \ + TEST_RESULT_EXIT_CODE=$$?; \ rm $(top_builddir)/tmp-php.ini; \ + exit $$TEST_RESULT_EXIT_CODE; \ else \ echo "ERROR: Cannot run tests without CLI sapi."; \ fi From 11c946e594a218143a6dafb302c70f2adade96d7 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 25 Nov 2012 11:46:35 +0800 Subject: [PATCH 2173/2394] XFAIL test should not be considered as failed --- run-tests.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/run-tests.php b/run-tests.php index 8527df8d4bd94..43470d0d8ad57 100755 --- a/run-tests.php +++ b/run-tests.php @@ -821,7 +821,7 @@ function save_or_mail_results() junit_save_xml(); - if (getenv('REPORT_EXIT_STATUS') == 1 and preg_match('/FAILED(?: |$)/', implode(' ', $test_results))) { + if (getenv('REPORT_EXIT_STATUS') == 1 and preg_match('/ FAILED(?: |$)/', implode(' ', $test_results))) { exit(1); } From 16efc77608789234c92c1cad906417d06ec3428d Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 25 Nov 2012 16:18:20 +0800 Subject: [PATCH 2174/2394] count($test_files) already be checked above : if ($test_cnt) thus we can use $sum_results instead of the preg_match --- run-tests.php | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/run-tests.php b/run-tests.php index 43470d0d8ad57..8b7fa7f8be556 100755 --- a/run-tests.php +++ b/run-tests.php @@ -802,14 +802,12 @@ function save_or_mail_results() fclose($failed_tests_file); } - if (count($test_files) || count($test_results)) { - compute_summary(); - if ($html_output) { - fwrite($html_file, "
\n" . get_summary(false, true)); - } - echo "====================================================================="; - echo get_summary(false, false); + compute_summary(); + if ($html_output) { + fwrite($html_file, "
\n" . get_summary(false, true)); } + echo "====================================================================="; + echo get_summary(false, false); if ($html_output) { fclose($html_file); @@ -821,7 +819,7 @@ function save_or_mail_results() junit_save_xml(); - if (getenv('REPORT_EXIT_STATUS') == 1 and preg_match('/ FAILED(?: |$)/', implode(' ', $test_results))) { + if (getenv('REPORT_EXIT_STATUS') == 1 and $sum_results['FAILED']) { exit(1); } From ca240f5b2259ea7d915e4b3182b0ee55d32572cb Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Tue, 27 Nov 2012 16:59:27 +0100 Subject: [PATCH 2175/2394] updated NEWS --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index cc4cb1d6d13fc..f64dec7716d32 100644 --- a/NEWS +++ b/NEWS @@ -180,6 +180,8 @@ PHP NEWS - Fileinfo: . Fixed bug #63248 (Load multiple magic files from a directory under Windows). (Anatoliy) + . Fixed bug #63590 (Different results in TS and NTS under Windows). + (Anatoliy) - Apache2 Handler SAPI: . Enabled Apache 2.4 configure option for Windows (Pierre, Anatoliy) From 3c1888f58468ff0fd7f6c20f3fd7701ed7273647 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 29 Nov 2012 13:06:12 +0400 Subject: [PATCH 2176/2394] Fixed bug #63635 (Segfault in gc_collect_cycles) --- Zend/tests/bug63635.phpt | 58 ++++++++++++++++++++++++++++++++++++++++ Zend/zend_gc.c | 6 +++-- 2 files changed, 62 insertions(+), 2 deletions(-) create mode 100644 Zend/tests/bug63635.phpt diff --git a/Zend/tests/bug63635.phpt b/Zend/tests/bug63635.phpt new file mode 100644 index 0000000000000..6f6fc6a44f46e --- /dev/null +++ b/Zend/tests/bug63635.phpt @@ -0,0 +1,58 @@ +--TEST-- +Bug #63635 (Segfault in gc_collect_cycles) +--FILE-- +childs[] = $this; + } + $this->childs[] = $this; + } + + function __destruct() { + $this->childs = NULL; + } +} + +define("MAX", 16); + +for ($n = 0; $n < 20; $n++) { + $top = new Node(); + for ($i=0 ; $ibuffered == (gc_root_buffer*)GC_WHITE) { - GC_SET_BLACK(obj->buffered); + /* PURPLE instead of BLACK to prevent buffering in nested gc calls */ + GC_SET_PURPLE(obj->buffered); if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid && (get_gc = Z_OBJ_HANDLER_P(pz, get_gc)) != NULL)) { @@ -715,7 +716,8 @@ static void zobj_collect_white(zval *pz TSRMLS_DC) struct _store_object *obj = &EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].bucket.obj; if (obj->buffered == (gc_root_buffer*)GC_WHITE) { - GC_SET_BLACK(obj->buffered); + /* PURPLE instead of BLACK to prevent buffering in nested gc calls */ + GC_SET_PURPLE(obj->buffered); if (EXPECTED(EG(objects_store).object_buckets[Z_OBJ_HANDLE_P(pz)].valid && (get_gc = Z_OBJ_HANDLER_P(pz, get_gc)) != NULL)) { From bf6fea6ba06ee670e55ce06a190e82440e2fa9ce Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 29 Nov 2012 14:41:20 +0400 Subject: [PATCH 2177/2394] Fixed bug #61557 (Crasher in tt-rss backend.php) --- ext/libxml/libxml.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index c97ee6724d43a..06de013858cb8 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -860,7 +860,6 @@ static PHP_MSHUTDOWN_FUNCTION(libxml) { if (!_php_libxml_per_request_initialization) { xmlSetGenericErrorFunc(NULL, NULL); - xmlSetStructuredErrorFunc(NULL, NULL); xmlParserInputBufferCreateFilenameDefault(NULL); xmlOutputBufferCreateFilenameDefault(NULL); @@ -876,11 +875,11 @@ static int php_libxml_post_deactivate() /* reset libxml generic error handling */ if (_php_libxml_per_request_initialization) { xmlSetGenericErrorFunc(NULL, NULL); - xmlSetStructuredErrorFunc(NULL, NULL); xmlParserInputBufferCreateFilenameDefault(NULL); xmlOutputBufferCreateFilenameDefault(NULL); } + xmlSetStructuredErrorFunc(NULL, NULL); if (LIBXML(stream_context)) { /* the steam_context resource will be released by resource list destructor */ From 9e1d3cfdabf8665aec4d121bafa31cddd6ca7231 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 29 Nov 2012 16:44:19 +0400 Subject: [PATCH 2178/2394] Fixed bug #63271 (SOAP wsdl cache is not enabled after initial requests) --- ext/soap/soap.c | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/ext/soap/soap.c b/ext/soap/soap.c index abeab53b9e7a9..cd45ec68535ae 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -463,19 +463,6 @@ zend_module_entry soap_module_entry = { ZEND_GET_MODULE(soap) #endif -ZEND_INI_MH(OnUpdateCacheEnabled) -{ - if (OnUpdateBool(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC) == FAILURE) { - return FAILURE; - } - if (SOAP_GLOBAL(cache_enabled)) { - SOAP_GLOBAL(cache) = SOAP_GLOBAL(cache_mode); - } else { - SOAP_GLOBAL(cache) = 0; - } - return SUCCESS; -} - ZEND_INI_MH(OnUpdateCacheMode) { char *p; @@ -489,16 +476,11 @@ ZEND_INI_MH(OnUpdateCacheMode) *p = (char)atoi(new_value); - if (SOAP_GLOBAL(cache_enabled)) { - SOAP_GLOBAL(cache) = SOAP_GLOBAL(cache_mode); - } else { - SOAP_GLOBAL(cache) = 0; - } return SUCCESS; } PHP_INI_BEGIN() -STD_PHP_INI_ENTRY("soap.wsdl_cache_enabled", "1", PHP_INI_ALL, OnUpdateCacheEnabled, +STD_PHP_INI_ENTRY("soap.wsdl_cache_enabled", "1", PHP_INI_ALL, OnUpdateBool, cache_enabled, zend_soap_globals, soap_globals) STD_PHP_INI_ENTRY("soap.wsdl_cache_dir", "/tmp", PHP_INI_ALL, OnUpdateString, cache_dir, zend_soap_globals, soap_globals) @@ -1102,7 +1084,7 @@ PHP_METHOD(SoapServer, SoapServer) memset(service, 0, sizeof(soapService)); service->send_errors = 1; - cache_wsdl = SOAP_GLOBAL(cache); + cache_wsdl = SOAP_GLOBAL(cache_enabled) ? SOAP_GLOBAL(cache_mode) : 0; if (options != NULL) { HashTable *ht = Z_ARRVAL_P(options); @@ -2318,7 +2300,7 @@ PHP_METHOD(SoapClient, SoapClient) php_error_docref(NULL TSRMLS_CC, E_ERROR, "$wsdl must be string or null"); } - cache_wsdl = SOAP_GLOBAL(cache); + cache_wsdl = SOAP_GLOBAL(cache_enabled) ? SOAP_GLOBAL(cache_mode) : 0; if (options != NULL) { HashTable *ht = Z_ARRVAL_P(options); From 70f83f35d089d0cafae12ae231a38541f5c8e41c Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Fri, 30 Nov 2012 13:39:23 +0400 Subject: [PATCH 2179/2394] . The VM stacks for passing function arguments and syntaticaly nested calls were merged into a single stack. The stack size needed for op_array execution is calculated at compile time and preallocated at once. As result all the stack push operatins don't require checks for stack overflow any more. . Generators implementation was improved using the new VM stack. Now it's a bit more clear and faster. --- NEWS | 5 + UPGRADING | 21 + Zend/zend.c | 4 +- Zend/zend_compile.c | 48 +- Zend/zend_compile.h | 18 +- Zend/zend_execute.c | 19 - Zend/zend_execute.h | 84 +- Zend/zend_execute_API.c | 14 +- Zend/zend_extensions.h | 2 +- Zend/zend_generators.c | 304 +++---- Zend/zend_generators.h | 25 +- Zend/zend_globals.h | 2 - Zend/zend_modules.h | 2 +- Zend/zend_opcode.c | 21 + Zend/zend_ptr_stack.c | 17 - Zend/zend_ptr_stack.h | 2 - Zend/zend_vm_def.h | 294 ++++--- Zend/zend_vm_execute.h | 1799 +++++++++++++++++++++----------------- Zend/zend_vm_execute.skl | 102 ++- Zend/zend_vm_opcodes.h | 1 + 20 files changed, 1477 insertions(+), 1307 deletions(-) diff --git a/NEWS b/NEWS index f64dec7716d32..350729c3ec4e9 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,11 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . The VM stacks for passing function arguments and syntaticaly nested calls + were merged into a single stack. The stack size needed for op_array + execution is calculated at compile time and preallocated at once. As result + all the stack push operatins don't require checks for stack overflow + any more. (Dmitry) . Added support for generators. (Nikita Popov) . Add simplified password hashing API (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) diff --git a/UPGRADING b/UPGRADING index 18ab6bf22ecc0..f8cb6fa2ed933 100755 --- a/UPGRADING +++ b/UPGRADING @@ -28,6 +28,27 @@ PHP 5.5 UPGRADE NOTES zend_logo_guid() have been removed - Removal of Logo GUIDs +- extensions can't override zend_execute() any more, they should override + zend_execute_ex() instead. The EG(current_execute_data) is already + initialized in zend_execute_ex(), so for compatibility extensions + may need to use EG(current_execute_data)->prev_execute_data instead. +- removed EG(arg_types_stack), EX(fbc), EX(called_scope), EX(current_object) +- added op_array->nested_calls. It's calculated at compile time. +- added EX(call_slots). It is an array to store information about syntaticaly + nested calls (e.g. foo(bar())). It's preallocated together with execute_data. +- added EX(call) - pointer to a current calling function. Actually an + element of EX(call_slots) +- opcodes INIT_METHOD_CALL, ZEND_INIT_STATIC_METHOD_CALL, + ZEND_INIT_FCALL_BY_NAME, ZEND_INIT_NS_FCALL_BY_NAME use result.num as + an index in EX(call_slots) +- opcode ZEND_NEW uses extended_vallue as an index in EX(call_slots) +- opcoes ZEND_DO_FCALL and ZEND_DO_FCALL_BY_NAME use op2.num as + an index in EX(call_slots) +- added op_array->used_stack. It's calculated at compile time and the + corresponding stack space is preallocated together with execute_data. + ZEND_SEND* and ZEND_DO_FCALL* don't need to check for stack overflow + anymore. + ======================================== 2. New Features ======================================== diff --git a/Zend/zend.c b/Zend/zend.c index 9ab879a2a4070..fc6aed08cc37e 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -683,11 +683,11 @@ int zend_startup(zend_utility_functions *utility_functions, char **extensions TS #if HAVE_DTRACE /* build with dtrace support */ zend_compile_file = dtrace_compile_file; - zend_execute = dtrace_execute; + zend_execute_ex = dtrace_execute_ex; zend_execute_internal = dtrace_execute_internal; #else zend_compile_file = compile_file; - zend_execute = execute; + zend_execute_ex = execute_ex; zend_execute_internal = NULL; #endif /* HAVE_SYS_SDT_H */ zend_compile_string = compile_string; diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index de77068db55fe..e768996272b79 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -179,6 +179,8 @@ void zend_init_compiler_context(TSRMLS_D) /* {{{ */ CG(context).literals_size = 0; CG(context).current_brk_cont = -1; CG(context).backpatch_count = 0; + CG(context).nested_calls = 0; + CG(context).used_stack = 0; CG(context).labels = NULL; } /* }}} */ @@ -1950,6 +1952,9 @@ int zend_do_begin_function_call(znode *function_name, zend_bool check_namespace function_name->u.constant.value.str.val = lcname; zend_stack_push(&CG(function_call_stack), (void *) &function, sizeof(zend_function *)); + if (CG(context).nested_calls + 1 > CG(active_op_array)->nested_calls) { + CG(active_op_array)->nested_calls = CG(context).nested_calls + 1; + } zend_do_extended_fcall_begin(TSRMLS_C); return 0; } @@ -1988,11 +1993,13 @@ void zend_do_begin_method_call(znode *left_bracket TSRMLS_DC) /* {{{ */ GET_POLYMORPHIC_CACHE_SLOT(last_op->op2.constant); } last_op->opcode = ZEND_INIT_METHOD_CALL; - SET_UNUSED(last_op->result); + last_op->result_type = IS_UNUSED; + last_op->result.num = CG(context).nested_calls; Z_LVAL(left_bracket->u.constant) = ZEND_INIT_FCALL_BY_NAME; } else { zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_INIT_FCALL_BY_NAME; + opline->result.num = CG(context).nested_calls; SET_UNUSED(opline->op1); if (left_bracket->op_type == IS_CONST) { opline->op2_type = IS_CONST; @@ -2004,6 +2011,9 @@ void zend_do_begin_method_call(znode *left_bracket TSRMLS_DC) /* {{{ */ } zend_stack_push(&CG(function_call_stack), (void *) &ptr, sizeof(zend_function *)); + if (++CG(context).nested_calls > CG(active_op_array)->nested_calls) { + CG(active_op_array)->nested_calls = CG(context).nested_calls; + } zend_do_extended_fcall_begin(TSRMLS_C); } /* }}} */ @@ -2031,12 +2041,14 @@ void zend_do_begin_dynamic_function_call(znode *function_name, int ns_call TSRML /* In run-time PHP will check for function with full name and internal function with short name */ opline->opcode = ZEND_INIT_NS_FCALL_BY_NAME; + opline->result.num = CG(context).nested_calls; SET_UNUSED(opline->op1); opline->op2_type = IS_CONST; opline->op2.constant = zend_add_ns_func_name_literal(CG(active_op_array), &function_name->u.constant TSRMLS_CC); GET_CACHE_SLOT(opline->op2.constant); } else { opline->opcode = ZEND_INIT_FCALL_BY_NAME; + opline->result.num = CG(context).nested_calls; SET_UNUSED(opline->op1); if (function_name->op_type == IS_CONST) { opline->op2_type = IS_CONST; @@ -2048,6 +2060,9 @@ void zend_do_begin_dynamic_function_call(znode *function_name, int ns_call TSRML } zend_stack_push(&CG(function_call_stack), (void *) &ptr, sizeof(zend_function *)); + if (++CG(context).nested_calls > CG(active_op_array)->nested_calls) { + CG(active_op_array)->nested_calls = CG(context).nested_calls; + } zend_do_extended_fcall_begin(TSRMLS_C); } /* }}} */ @@ -2395,6 +2410,7 @@ int zend_do_begin_class_member_function_call(znode *class_name, znode *method_na opline->extended_value = class_node.EA ; } opline->opcode = ZEND_INIT_STATIC_METHOD_CALL; + opline->result.num = CG(context).nested_calls; if (class_node.op_type == IS_CONST) { opline->op1_type = IS_CONST; opline->op1.constant = @@ -2416,6 +2432,9 @@ int zend_do_begin_class_member_function_call(znode *class_name, znode *method_na } zend_stack_push(&CG(function_call_stack), (void *) &ptr, sizeof(zend_function *)); + if (++CG(context).nested_calls > CG(active_op_array)->nested_calls) { + CG(active_op_array)->nested_calls = CG(context).nested_calls; + } zend_do_extended_fcall_begin(TSRMLS_C); return 1; /* Dynamic */ } @@ -2436,21 +2455,29 @@ void zend_do_end_function_call(znode *function_name, znode *result, const znode if (!is_method && !is_dynamic_fcall && function_name->op_type==IS_CONST) { opline->opcode = ZEND_DO_FCALL; SET_NODE(opline->op1, function_name); + SET_UNUSED(opline->op2); + opline->op2.num = CG(context).nested_calls; CALCULATE_LITERAL_HASH(opline->op1.constant); GET_CACHE_SLOT(opline->op1.constant); } else { opline->opcode = ZEND_DO_FCALL_BY_NAME; SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + opline->op2.num = --CG(context).nested_calls; } } opline->result.var = get_temporary_variable(CG(active_op_array)); opline->result_type = IS_VAR; - GET_NODE(result, opline->result) ; - SET_UNUSED(opline->op2); + GET_NODE(result, opline->result); zend_stack_del_top(&CG(function_call_stack)); opline->extended_value = Z_LVAL(argument_list->u.constant); + + if (CG(context).used_stack + 1 > CG(active_op_array)->used_stack) { + CG(active_op_array)->used_stack = CG(context).used_stack + 1; + } + CG(context).used_stack -= Z_LVAL(argument_list->u.constant); } /* }}} */ @@ -2558,6 +2585,10 @@ void zend_do_pass_param(znode *param, zend_uchar op, int offset TSRMLS_DC) /* {{ SET_NODE(opline->op1, param); opline->op2.opline_num = offset; SET_UNUSED(opline->op2); + + if (++CG(context).used_stack > CG(active_op_array)->used_stack) { + CG(active_op_array)->used_stack = CG(context).used_stack; + } } /* }}} */ @@ -5547,12 +5578,16 @@ void zend_do_begin_new_object(znode *new_token, znode *class_type TSRMLS_DC) /* new_token->u.op.opline_num = get_next_op_number(CG(active_op_array)); opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = ZEND_NEW; + opline->extended_value = CG(context).nested_calls; opline->result_type = IS_VAR; opline->result.var = get_temporary_variable(CG(active_op_array)); SET_NODE(opline->op1, class_type); SET_UNUSED(opline->op2); zend_stack_push(&CG(function_call_stack), (void *) &ptr, sizeof(unsigned char *)); + if (++CG(context).nested_calls > CG(active_op_array)->nested_calls) { + CG(active_op_array)->nested_calls = CG(context).nested_calls; + } } /* }}} */ @@ -5765,6 +5800,13 @@ void zend_do_shell_exec(znode *result, const znode *cmd TSRMLS_DC) /* {{{ */ opline->extended_value = 1; SET_UNUSED(opline->op2); GET_NODE(result, opline->result); + + if (CG(context).nested_calls + 1 > CG(active_op_array)->nested_calls) { + CG(active_op_array)->nested_calls = CG(context).nested_calls + 1; + } + if (CG(context).used_stack + 2 > CG(active_op_array)->used_stack) { + CG(active_op_array)->used_stack = CG(context).used_stack + 2; + } } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index e46c1a39ce764..def634175a8d1 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -59,6 +59,8 @@ typedef struct _zend_compiler_context { int literals_size; int current_brk_cont; int backpatch_count; + int nested_calls; + int used_stack; HashTable *labels; } zend_compiler_context; @@ -279,6 +281,9 @@ struct _zend_op_array { zend_uint T; + zend_uint nested_calls; + zend_uint used_stack; + zend_brk_cont_element *brk_cont_array; int last_brk_cont; @@ -369,11 +374,17 @@ typedef struct _list_llist_element { union _temp_variable; +typedef struct _call_slot { + zend_function *fbc; + zval *object; + zend_class_entry *called_scope; + zend_bool is_ctor_call; + zend_bool is_ctor_result_used; +} call_slot; + struct _zend_execute_data { struct _zend_op *opline; zend_function_state function_state; - zend_function *fbc; /* Function Being Called */ - zend_class_entry *called_scope; zend_op_array *op_array; zval *object; union _temp_variable *Ts; @@ -386,8 +397,9 @@ struct _zend_execute_data { zend_class_entry *current_scope; zend_class_entry *current_called_scope; zval *current_this; - zval *current_object; struct _zend_op *fast_ret; /* used by FAST_CALL/FAST_RET (finally keyword) */ + call_slot *call_slots; + call_slot *call; }; #define EX(element) execute_data.element diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 361afc6f13e76..5f04ba7465e36 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1570,25 +1570,6 @@ void zend_free_compiled_variables(zval ***CVs, int num) /* {{{ */ } /* }}} */ -void** zend_copy_arguments(void **arguments_end) /* {{{ */ -{ - int arguments_count = (int) (zend_uintptr_t) *arguments_end; - size_t arguments_size = (arguments_count + 1) * sizeof(void **); - void **arguments_start = arguments_end - arguments_count; - void **copied_arguments_start = emalloc(arguments_size); - void **copied_arguments_end = copied_arguments_start + arguments_count; - int i; - - memcpy(copied_arguments_start, arguments_start, arguments_size); - - for (i = 0; i < arguments_count; i++) { - Z_ADDREF_P((zval *) arguments_start[i]); - } - - return copied_arguments_end; -} -/* }}} */ - /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 4594eba9eff7c..fdd9f5697db13 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -50,14 +50,14 @@ typedef union _temp_variable { BEGIN_EXTERN_C() struct _zend_fcall_info; -ZEND_API extern void (*zend_execute)(zend_op_array *op_array TSRMLS_DC); +ZEND_API extern void (*zend_execute_ex)(zend_execute_data *execute_data TSRMLS_DC); ZEND_API extern void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, struct _zend_fcall_info *fci, int return_value_used TSRMLS_DC); void init_executor(TSRMLS_D); void shutdown_executor(TSRMLS_D); void shutdown_destructors(TSRMLS_D); zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC); -ZEND_API void execute(zend_op_array *op_array TSRMLS_DC); +ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC); ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC); ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, struct _zend_fcall_info *fci, int return_value_used TSRMLS_DC); ZEND_API int zend_is_true(zval *op); @@ -221,12 +221,6 @@ static zend_always_inline void **zend_vm_stack_top(TSRMLS_D) } static zend_always_inline void zend_vm_stack_push(void *ptr TSRMLS_DC) -{ - ZEND_VM_STACK_GROW_IF_NEEDED(1); - *(EG(argument_stack)->top++) = ptr; -} - -static zend_always_inline void zend_vm_stack_push_nocheck(void *ptr TSRMLS_DC) { *(EG(argument_stack)->top++) = ptr; } @@ -235,11 +229,6 @@ static zend_always_inline void *zend_vm_stack_pop(TSRMLS_D) { void *el = *(--EG(argument_stack)->top); - if (UNEXPECTED(EG(argument_stack)->top == ZEND_VM_STACK_ELEMETS(EG(argument_stack)))) { - zend_vm_stack p = EG(argument_stack); - EG(argument_stack) = p->prev; - efree(p); - } return el; } @@ -272,6 +261,12 @@ static zend_always_inline void *zend_vm_stack_alloc(size_t size TSRMLS_DC) return ret; } +static zend_always_inline void** zend_vm_stack_frame_base(zend_execute_data *ex) +{ + return (void**)((char*)ex->call_slots + + ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * ex->op_array->nested_calls); +} + static zend_always_inline void zend_vm_stack_free_int(void *ptr TSRMLS_DC) { if (UNEXPECTED(ZEND_VM_STACK_ELEMETS(EG(argument_stack)) == (void**)ptr)) { @@ -302,35 +297,6 @@ static zend_always_inline void zend_vm_stack_free(void *ptr TSRMLS_DC) } } -static zend_always_inline void** zend_vm_stack_push_args(int count TSRMLS_DC) -{ - - if (UNEXPECTED(EG(argument_stack)->top - ZEND_VM_STACK_ELEMETS(EG(argument_stack)) < count) || - UNEXPECTED(EG(argument_stack)->top == EG(argument_stack)->end)) { - zend_vm_stack p = EG(argument_stack); - - zend_vm_stack_extend(count + 1 TSRMLS_CC); - - EG(argument_stack)->top += count; - *(EG(argument_stack)->top) = (void*)(zend_uintptr_t)count; - while (count-- > 0) { - void *data = *(--p->top); - - if (UNEXPECTED(p->top == ZEND_VM_STACK_ELEMETS(p))) { - zend_vm_stack r = p; - - EG(argument_stack)->prev = p->prev; - p = p->prev; - efree(r); - } - *(ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + count) = data; - } - return EG(argument_stack)->top++; - } - *(EG(argument_stack)->top) = (void*)(zend_uintptr_t)count; - return EG(argument_stack)->top++; -} - static zend_always_inline void zend_vm_stack_clear_multiple(TSRMLS_D) { void **p = EG(argument_stack)->top - 1; @@ -344,9 +310,19 @@ static zend_always_inline void zend_vm_stack_clear_multiple(TSRMLS_D) zend_vm_stack_free_int(p TSRMLS_CC); } -static zend_always_inline zval** zend_vm_stack_get_arg(int requested_arg TSRMLS_DC) +static zend_always_inline int zend_vm_stack_get_args_count_ex(zend_execute_data *ex) +{ + if (ex) { + void **p = ex->function_state.arguments; + return (int)(zend_uintptr_t) *p; + } else { + return 0; + } +} + +static zend_always_inline zval** zend_vm_stack_get_arg_ex(zend_execute_data *ex, int requested_arg) { - void **p = EG(current_execute_data)->prev_execute_data->function_state.arguments; + void **p = ex->function_state.arguments; int arg_count = (int)(zend_uintptr_t) *p; if (UNEXPECTED(requested_arg > arg_count)) { @@ -355,25 +331,14 @@ static zend_always_inline zval** zend_vm_stack_get_arg(int requested_arg TSRMLS_ return (zval**)p - arg_count + requested_arg - 1; } -static zend_always_inline void zend_arg_types_stack_2_pop(zend_ptr_stack *stack, zval **object, zend_function **fbc) +static zend_always_inline int zend_vm_stack_get_args_count(TSRMLS_D) { - void *a, *b; - - zend_ptr_stack_2_pop(stack, &a, &b); - - *object = (zval *) a; - *fbc = (zend_function *) b; + return zend_vm_stack_get_args_count_ex(EG(current_execute_data)->prev_execute_data); } -static zend_always_inline void zend_arg_types_stack_3_pop(zend_ptr_stack *stack, zend_class_entry **called_scope, zval **object, zend_function **fbc) +static zend_always_inline zval** zend_vm_stack_get_arg(int requested_arg TSRMLS_DC) { - void *a, *b, *c; - - zend_ptr_stack_3_pop(stack, &a, &b, &c); - - *called_scope = (zend_class_entry *) a; - *object = (zval *) b; - *fbc = (zend_function *) c; + return zend_vm_stack_get_arg_ex(EG(current_execute_data)->prev_execute_data, requested_arg); } void execute_new_code(TSRMLS_D); @@ -436,7 +401,6 @@ ZEND_API int zend_do_fcall(ZEND_OPCODE_HANDLER_ARGS); void zend_clean_and_cache_symbol_table(HashTable *symbol_table TSRMLS_DC); void zend_free_compiled_variables(zval ***CVs, int num); -void **zend_copy_arguments(void **arguments_end); #define CACHED_PTR(num) \ EG(active_op_array)->run_time_cache[(num)] diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 9787966f275ab..3df0ca2396788 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -38,7 +38,7 @@ #include #endif -ZEND_API void (*zend_execute)(zend_op_array *op_array TSRMLS_DC); +ZEND_API void (*zend_execute_ex)(zend_execute_data *execute_data TSRMLS_DC); ZEND_API void (*zend_execute_internal)(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); /* true globals */ @@ -137,7 +137,6 @@ void init_executor(TSRMLS_D) /* {{{ */ INIT_ZVAL(EG(error_zval)); EG(uninitialized_zval_ptr)=&EG(uninitialized_zval); EG(error_zval_ptr)=&EG(error_zval); - zend_ptr_stack_init(&EG(arg_types_stack)); /* destroys stack frame, therefore makes core dumps worthless */ #if 0&&ZEND_DEBUG original_sigsegv_handler = signal(SIGSEGV, zend_handle_sigsegv); @@ -293,10 +292,10 @@ void shutdown_executor(TSRMLS_D) /* {{{ */ } zend_end_try(); zend_try { - zend_vm_stack_destroy(TSRMLS_C); - zend_objects_store_free_object_storage(&EG(objects_store) TSRMLS_CC); + zend_vm_stack_destroy(TSRMLS_C); + /* Destroy all op arrays */ if (EG(full_tables_cleanup)) { zend_hash_reverse_apply(EG(function_table), (apply_func_t) clean_non_persistent_function_full TSRMLS_CC); @@ -324,7 +323,6 @@ void shutdown_executor(TSRMLS_D) /* {{{ */ zend_hash_destroy(&EG(included_files)); - zend_ptr_stack_destroy(&EG(arg_types_stack)); zend_stack_destroy(&EG(user_error_handlers_error_reporting)); zend_ptr_stack_destroy(&EG(user_error_handlers)); zend_ptr_stack_destroy(&EG(user_exception_handlers)); @@ -862,7 +860,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS !ARG_MAY_BE_SENT_BY_REF(EX(function_state).function, i + 1)) { if (i || UNEXPECTED(ZEND_VM_STACK_ELEMETS(EG(argument_stack)) == (EG(argument_stack)->top))) { /* hack to clean up the stack */ - zend_vm_stack_push_nocheck((void *) (zend_uintptr_t)i TSRMLS_CC); + zend_vm_stack_push((void *) (zend_uintptr_t)i TSRMLS_CC); zend_vm_stack_clear_multiple(TSRMLS_C); } @@ -899,11 +897,11 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS *param = **(fci->params[i]); INIT_PZVAL(param); } - zend_vm_stack_push_nocheck(param TSRMLS_CC); + zend_vm_stack_push(param TSRMLS_CC); } EX(function_state).arguments = zend_vm_stack_top(TSRMLS_C); - zend_vm_stack_push_nocheck((void*)(zend_uintptr_t)fci->param_count TSRMLS_CC); + zend_vm_stack_push((void*)(zend_uintptr_t)fci->param_count TSRMLS_CC); current_scope = EG(scope); EG(scope) = calling_scope; diff --git a/Zend/zend_extensions.h b/Zend/zend_extensions.h index 703e03c3f64e8..17804cb740e2b 100644 --- a/Zend/zend_extensions.h +++ b/Zend/zend_extensions.h @@ -28,7 +28,7 @@ /* The first number is the engine version and the rest is the date. * This way engine 2/3 API no. is always greater than engine 1 API no.. */ -#define ZEND_EXTENSION_API_NO 220121113 +#define ZEND_EXTENSION_API_NO 220121128 typedef struct _zend_extension_version_info { int zend_extension_api_no; diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 1895305875323..493e99dd0eb86 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -32,41 +32,7 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio if (generator->execute_data) { zend_execute_data *execute_data = generator->execute_data; zend_op_array *op_array = execute_data->op_array; - - if (!finished_execution) { - if (op_array->has_finally_block) { - /* -1 required because we want the last run opcode, not the - * next to-be-run one. */ - zend_uint op_num = execute_data->opline - op_array->opcodes - 1; - zend_uint finally_op_num = 0; - - /* Find next finally block */ - int i; - for (i = 0; i < op_array->last_try_catch; i++) { - zend_try_catch_element *try_catch = &op_array->try_catch_array[i]; - - if (op_num < try_catch->try_op) { - break; - } - - if (op_num < try_catch->finally_op) { - finally_op_num = try_catch->finally_op; - } - } - - /* If a finally block was found we jump directly to it and - * resume the generator. Furthermore we abort this close call - * because the generator will already be closed somewhere in - * the resume. */ - if (finally_op_num) { - execute_data->opline = &op_array->opcodes[finally_op_num]; - execute_data->fast_ret = NULL; - generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; - zend_generator_resume(generator TSRMLS_CC); - return; - } - } - } + void **stack_frame; if (!execute_data->symbol_table) { zend_free_compiled_variables(execute_data->CVs, op_array->last_var); @@ -78,10 +44,6 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio zval_ptr_dtor(&execute_data->current_this); } - if (execute_data->object) { - zval_ptr_dtor(&execute_data->object); - } - /* If the generator is closed before it can finish execution (reach * a return statement) we have to free loop variables manually, as * we don't know whether the SWITCH_FREE / FREE opcodes have run */ @@ -120,32 +82,20 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio } /* Clear any backed up stack arguments */ - if (generator->backed_up_stack) { - zval **zvals = (zval **) generator->backed_up_stack; - size_t zval_num = generator->backed_up_stack_size / sizeof(zval *); - int i; - - for (i = 0; i < zval_num; i++) { - zval_ptr_dtor(&zvals[i]); + if (generator->stack != EG(argument_stack)) { + stack_frame = zend_vm_stack_frame_base(execute_data); + while (generator->stack->top != stack_frame) { + zval_ptr_dtor((zval**)stack_frame); + stack_frame++; } - - efree(generator->backed_up_stack); } - if (generator->backed_up_arg_types_stack) { - /* The arg types stack contains three elements per call: fbc, object - * and called_scope. Here we traverse the stack from top to bottom - * and dtor the object. */ - int i = generator->backed_up_arg_types_stack_count / 3; - while (i--) { - zval *object = (zval *) generator->backed_up_arg_types_stack[3*i + 1]; - if (object) { - zval_ptr_dtor(&object); - } + while (execute_data->call >= execute_data->call_slots) { + if (execute_data->call->object) { + zval_ptr_dtor(&execute_data->call->object); } - - efree(generator->backed_up_arg_types_stack); - } + execute_data->call--; + } /* We have added an additional stack frame in prev_execute_data, so we * have to free it. It also contains the arguments passed to the @@ -162,11 +112,7 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio for (i = 0; i < arguments_count; ++i) { zval_ptr_dtor(arguments_start + i); } - - efree(arguments_start); } - - efree(prev_execute_data); } /* Free a clone of closure */ @@ -175,7 +121,11 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio efree(op_array); } - efree(execute_data); + efree(generator->stack); + if (generator->stack == EG(argument_stack)) { + /* abnormal exit for running generator */ + EG(argument_stack) = NULL; + } generator->execute_data = NULL; } @@ -210,27 +160,39 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** zend_execute_data *execute_data = orig->execute_data; zend_op_array *op_array = execute_data->op_array; HashTable *symbol_table = execute_data->symbol_table; - - /* Alloc separate execution context, as well as separate sections for - * compiled variables and temporary variables */ - size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); - size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (symbol_table ? 1 : 2)); - size_t Ts_size = ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T; - size_t total_size = execute_data_size + CVs_size + Ts_size; - - clone->execute_data = emalloc(total_size); - - /* Copy the zend_execute_data struct */ - memcpy(clone->execute_data, execute_data, execute_data_size); - - /* Set the pointers to the memory segments for the compiled and - * temporary variables (which are located after the execute_data) */ - clone->execute_data->CVs = (zval ***) ((char *) clone->execute_data + execute_data_size); - clone->execute_data->Ts = (temp_variable *) ((char *) clone->execute_data->CVs + CVs_size); - - /* Zero out the compiled variables section */ - memset(clone->execute_data->CVs, 0, sizeof(zval **) * op_array->last_var); - + zend_execute_data *current_execute_data; + zend_op **opline_ptr; + HashTable *current_symbol_table; + zend_vm_stack current_stack; + zval *current_this; + void **stack_frame, **orig_stack_frame; + + /* Create new execution context. We have to back up and restore + * EG(current_execute_data), EG(opline_ptr), EG(active_symbol_table) + * and EG(This) here because the function modifies or uses them */ + current_execute_data = EG(current_execute_data); + EG(current_execute_data) = execute_data->prev_execute_data; + opline_ptr = EG(opline_ptr); + current_symbol_table = EG(active_symbol_table); + EG(active_symbol_table) = execute_data->symbol_table; + current_this = EG(This); + EG(This) = NULL; + current_stack = EG(argument_stack); + clone->execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); + clone->stack = EG(argument_stack); + EG(argument_stack) = current_stack; + EG(This) = current_this; + EG(active_symbol_table) = current_symbol_table; + EG(current_execute_data) = current_execute_data; + EG(opline_ptr) = opline_ptr; + + /* copy */ + clone->execute_data->opline = execute_data->opline; + clone->execute_data->function_state = execute_data->function_state; + clone->execute_data->current_scope = execute_data->current_scope; + clone->execute_data->current_called_scope = execute_data->current_called_scope; + clone->execute_data->fast_ret = execute_data->fast_ret; + if (!symbol_table) { int i; @@ -238,7 +200,7 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** for (i = 0; i < op_array->last_var; i++) { if (execute_data->CVs[i]) { clone->execute_data->CVs[i] = (zval **) clone->execute_data->CVs + op_array->last_var + i; - *clone->execute_data->CVs[i] = (zval *) orig->execute_data->CVs[op_array->last_var + i]; + *clone->execute_data->CVs[i] = (zval *) execute_data->CVs[op_array->last_var + i]; Z_ADDREF_PP(clone->execute_data->CVs[i]); } } @@ -259,8 +221,39 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** } } + /* Copy nested-calls stack */ + if (execute_data->call) { + clone->execute_data->call = clone->execute_data->call_slots + + (execute_data->call - execute_data->call_slots); + } else { + clone->execute_data->call = NULL; + } + memcpy(clone->execute_data->call_slots, execute_data->call_slots, sizeof(call_slot) * op_array->nested_calls); + if (clone->execute_data->call >= clone->execute_data->call_slots) { + call_slot *call = clone->execute_data->call; + + while (call >= clone->execute_data->call_slots) { + if (call->object) { + Z_ADDREF_P(call->object); + } + call--; + } + } + /* Copy the temporary variables */ - memcpy(clone->execute_data->Ts, orig->execute_data->Ts, Ts_size); + memcpy(clone->execute_data->Ts, execute_data->Ts, sizeof(temp_variable) * op_array->T); + + /* Copy arguments passed on stack */ + stack_frame = zend_vm_stack_frame_base(clone->execute_data); + orig_stack_frame = zend_vm_stack_frame_base(execute_data); + clone->stack->top = stack_frame + (orig->stack->top - orig_stack_frame); + if (clone->stack->top != stack_frame) { + memcpy(stack_frame, orig_stack_frame, sizeof(zval*) * (orig->stack->top - orig_stack_frame)); + while (clone->stack->top != stack_frame) { + Z_ADDREF_PP((zval**)stack_frame); + stack_frame++; + } + } /* Add references to loop variables */ { @@ -286,42 +279,6 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** } } - if (orig->backed_up_stack) { - /* Copy backed up stack */ - clone->backed_up_stack = emalloc(orig->backed_up_stack_size); - memcpy(clone->backed_up_stack, orig->backed_up_stack, orig->backed_up_stack_size); - - /* Add refs to stack variables */ - { - zval **zvals = (zval **) orig->backed_up_stack; - size_t zval_num = orig->backed_up_stack_size / sizeof(zval *); - int i; - - for (i = 0; i < zval_num; i++) { - Z_ADDREF_P(zvals[i]); - } - } - } - - if (orig->backed_up_arg_types_stack) { - size_t stack_size = orig->backed_up_arg_types_stack_count * sizeof(void *); - - clone->backed_up_arg_types_stack = emalloc(stack_size); - memcpy(clone->backed_up_arg_types_stack, orig->backed_up_arg_types_stack, stack_size); - - /* We have to add refs to the objects in the arg types stack (the - * object is always the second element of a three-pack. */ - { - int i, stack_frames = clone->backed_up_arg_types_stack_count / 3; - for (i = 0; i < stack_frames; i++) { - zval *object = (zval *) clone->backed_up_arg_types_stack[3*i + 1]; - if (object) { - Z_ADDREF_P(object); - } - } - } - } - /* Update the send_target to use the temporary variable with the same * offset as the original generator, but in our temporary variable * memory segment. */ @@ -334,24 +291,14 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** } if (execute_data->current_this) { + clone->execute_data->current_this = execute_data->current_this; Z_ADDREF_P(execute_data->current_this); } if (execute_data->object) { + clone->execute_data->object = execute_data->object; Z_ADDREF_P(execute_data->object); } - - /* Prev execute data contains an additional stack frame (for proper - * backtraces) which has to be copied. */ - clone->execute_data->prev_execute_data = emalloc(sizeof(zend_execute_data)); - memcpy(clone->execute_data->prev_execute_data, execute_data->prev_execute_data, sizeof(zend_execute_data)); - - /* It also contains the arguments passed to the generator, which also - * have to be copied */ - if (execute_data->prev_execute_data->function_state.arguments) { - clone->execute_data->prev_execute_data->function_state.arguments - = zend_copy_arguments(execute_data->prev_execute_data->function_state.arguments); - } } /* The value and key are known not to be references, so simply add refs */ @@ -399,7 +346,9 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ zend_generator *generator; zend_execute_data *current_execute_data; zend_op **opline_ptr; + HashTable *current_symbol_table; zend_execute_data *execute_data; + zend_vm_stack current_stack = EG(argument_stack); /* Create a clone of closure, because it may be destroyed */ if (op_array->fn_flags & ZEND_ACC_CLOSURE) { @@ -410,11 +359,14 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ } /* Create new execution context. We have to back up and restore - * EG(current_execute_data) and EG(opline_ptr) here because the function - * modifies it. */ + * EG(current_execute_data), EG(opline_ptr) and EG(active_symbol_table) + * here because the function modifies or uses them */ current_execute_data = EG(current_execute_data); opline_ptr = EG(opline_ptr); + current_symbol_table = EG(active_symbol_table); + EG(active_symbol_table) = NULL; execute_data = zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC); + EG(active_symbol_table) = current_symbol_table; EG(current_execute_data) = current_execute_data; EG(opline_ptr) = opline_ptr; @@ -434,18 +386,8 @@ zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ /* Save execution context in generator object. */ generator = (zend_generator *) zend_object_store_get_object(return_value TSRMLS_CC); generator->execute_data = execute_data; - - /* We have to add another stack frame so the generator function shows - * up in backtraces and func_get_all() can access the function - * arguments. */ - execute_data->prev_execute_data = emalloc(sizeof(zend_execute_data)); - memset(execute_data->prev_execute_data, 0, sizeof(zend_execute_data)); - execute_data->prev_execute_data->function_state.function = (zend_function *) op_array; - if (EG(current_execute_data)) { - execute_data->prev_execute_data->function_state.arguments = zend_copy_arguments(EG(current_execute_data)->function_state.arguments); - } else { - execute_data->prev_execute_data->function_state.arguments = NULL; - } + generator->stack = EG(argument_stack); + EG(argument_stack) = current_stack; return return_value; } @@ -487,28 +429,7 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ zval *original_This = EG(This); zend_class_entry *original_scope = EG(scope); zend_class_entry *original_called_scope = EG(called_scope); - int original_arg_types_stack_count = EG(arg_types_stack).top; - - /* Remember the current stack position so we can back up pushed args */ - generator->original_stack_top = zend_vm_stack_top(TSRMLS_C); - - /* If there is a backed up stack copy it to the VM stack */ - if (generator->backed_up_stack) { - void *stack = zend_vm_stack_alloc(generator->backed_up_stack_size TSRMLS_CC); - memcpy(stack, generator->backed_up_stack, generator->backed_up_stack_size); - efree(generator->backed_up_stack); - generator->backed_up_stack = NULL; - } - - if (generator->backed_up_arg_types_stack) { - zend_ptr_stack_push_from_memory( - &EG(arg_types_stack), - generator->backed_up_arg_types_stack_count, - generator->backed_up_arg_types_stack - ); - efree(generator->backed_up_arg_types_stack); - generator->backed_up_arg_types_stack = NULL; - } + zend_vm_stack original_stack = EG(argument_stack); /* We (mis)use the return_value_ptr_ptr to provide the generator object * to the executor, so YIELD will be able to set the yielded value */ @@ -522,6 +443,7 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ EG(This) = generator->execute_data->current_this; EG(scope) = generator->execute_data->current_scope; EG(called_scope) = generator->execute_data->current_called_scope; + EG(argument_stack) = generator->stack; /* We want the backtrace to look as if the generator function was * called from whatever method we are current running (e.g. next()). @@ -533,7 +455,7 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ /* Resume execution */ generator->flags |= ZEND_GENERATOR_CURRENTLY_RUNNING; - execute_ex(generator->execute_data TSRMLS_CC); + zend_execute_ex(generator->execute_data TSRMLS_CC); generator->flags &= ~ZEND_GENERATOR_CURRENTLY_RUNNING; /* Restore executor globals */ @@ -545,27 +467,7 @@ void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ EG(This) = original_This; EG(scope) = original_scope; EG(called_scope) = original_called_scope; - - /* The stack top before and after the execution differ, i.e. there are - * arguments pushed to the stack. */ - if (generator->original_stack_top != zend_vm_stack_top(TSRMLS_C)) { - generator->backed_up_stack_size = (zend_vm_stack_top(TSRMLS_C) - generator->original_stack_top) * sizeof(void *); - generator->backed_up_stack = emalloc(generator->backed_up_stack_size); - memcpy(generator->backed_up_stack, generator->original_stack_top, generator->backed_up_stack_size); - zend_vm_stack_free(generator->original_stack_top TSRMLS_CC); - } - - if (original_arg_types_stack_count != EG(arg_types_stack).top) { - generator->backed_up_arg_types_stack_count = - EG(arg_types_stack).top - original_arg_types_stack_count; - - generator->backed_up_arg_types_stack = emalloc(generator->backed_up_arg_types_stack_count * sizeof(void *)); - zend_ptr_stack_pop_into_memory( - &EG(arg_types_stack), - generator->backed_up_arg_types_stack_count, - generator->backed_up_arg_types_stack - ); - } + EG(argument_stack) = original_stack; /* If an exception was thrown in the generator we have to internally * rethrow it in the parent scope. */ @@ -741,21 +643,11 @@ ZEND_METHOD(Generator, __wakeup) /* get_iterator implementation */ -typedef struct _zend_generator_iterator { - zend_object_iterator intern; - - /* The generator object zval has to be stored, because the iterator is - * holding a ref to it, which has to be dtored. */ - zval *object; -} zend_generator_iterator; - static void zend_generator_iterator_dtor(zend_object_iterator *iterator TSRMLS_DC) /* {{{ */ { zval *object = ((zend_generator_iterator *) iterator)->object; zval_ptr_dtor(&object); - - efree(iterator); } /* }}} */ @@ -854,7 +746,7 @@ zend_object_iterator *zend_generator_get_iterator(zend_class_entry *ce, zval *ob return NULL; } - iterator = emalloc(sizeof(zend_generator_iterator)); + iterator = &generator->iterator; iterator->intern.funcs = &zend_generator_iterator_functions; iterator->intern.data = (void *) generator; diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index 3dc3e6fecdd63..90f8160f710b1 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -25,25 +25,24 @@ BEGIN_EXTERN_C() extern ZEND_API zend_class_entry *zend_ce_generator; END_EXTERN_C() +typedef struct _zend_generator_iterator { + zend_object_iterator intern; + + /* The generator object zval has to be stored, because the iterator is + * holding a ref to it, which has to be dtored. */ + zval *object; +} zend_generator_iterator; + typedef struct _zend_generator { zend_object std; + zend_generator_iterator iterator; + /* The suspended execution context. */ zend_execute_data *execute_data; - /* If the execution is suspended during a function call there may be - * arguments pushed to the stack, so it has to be backed up. */ - void *backed_up_stack; - size_t backed_up_stack_size; - - /* For method calls PHP also pushes various type information on a second - * stack, which also needs to be backed up. */ - void **backed_up_arg_types_stack; - int backed_up_arg_types_stack_count; - - /* The original stack top before resuming the generator. This is required - * for proper cleanup during exception handling. */ - void **original_stack_top; + /* The separate stack used by generator */ + zend_vm_stack stack; /* Current value */ zval *value; diff --git a/Zend/zend_globals.h b/Zend/zend_globals.h index e5aba0df6783d..6ad9768086f51 100644 --- a/Zend/zend_globals.h +++ b/Zend/zend_globals.h @@ -167,8 +167,6 @@ struct _zend_executor_globals { zval error_zval; zval *error_zval_ptr; - zend_ptr_stack arg_types_stack; - /* symbol table cache */ HashTable *symtable_cache[SYMTABLE_CACHE_SIZE]; HashTable **symtable_cache_limit; diff --git a/Zend/zend_modules.h b/Zend/zend_modules.h index 442535bc68408..bfea3e0d225e7 100644 --- a/Zend/zend_modules.h +++ b/Zend/zend_modules.h @@ -33,7 +33,7 @@ #define ZEND_MODULE_INFO_FUNC_ARGS zend_module_entry *zend_module TSRMLS_DC #define ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU zend_module TSRMLS_CC -#define ZEND_MODULE_API_NO 20121113 +#define ZEND_MODULE_API_NO 20121128 #ifdef ZTS #define USING_ZTS 1 #else diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 563c84301daa1..2fd8f529ef1f8 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -70,6 +70,9 @@ void init_op_array(zend_op_array *op_array, zend_uchar type, int initial_ops_siz op_array->T = 0; + op_array->nested_calls = 0; + op_array->used_stack = 0; + op_array->function_name = NULL; op_array->filename = zend_get_compiled_filename(TSRMLS_C); op_array->doc_comment = NULL; @@ -541,6 +544,15 @@ static void zend_resolve_finally_call(zend_op_array *op_array, zend_uint op_num, /* generate a FAST_CALL to finaly block */ start_op = get_next_op_number(op_array); + + if (op_array->opcodes[op_num].opcode == ZEND_YIELD) { + /* Disable yield in finally block */ + opline = get_next_op(op_array TSRMLS_CC); + opline->opcode = ZEND_GENERATOR_FLAG; + opline->extended_value = 1; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + } opline = get_next_op(op_array TSRMLS_CC); opline->opcode = ZEND_FAST_CALL; SET_UNUSED(opline->op1); @@ -567,6 +579,14 @@ static void zend_resolve_finally_call(zend_op_array *op_array, zend_uint op_num, opline->op1.opline_num = op_array->try_catch_array[i].finally_op; } } + if (op_array->opcodes[op_num].opcode == ZEND_YIELD) { + /* Re-enable yield */ + opline = get_next_op(op_array TSRMLS_CC); + opline->opcode = ZEND_GENERATOR_FLAG; + opline->extended_value = 0; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + } /* Finish the sequence with original opcode */ opline = get_next_op(op_array TSRMLS_CC); @@ -622,6 +642,7 @@ static void zend_resolve_finally_calls(zend_op_array *op_array TSRMLS_DC) switch (opline->opcode) { case ZEND_RETURN: case ZEND_RETURN_BY_REF: + case ZEND_YIELD: zend_resolve_finally_call(op_array, i, (zend_uint)-1 TSRMLS_CC); break; case ZEND_BRK: diff --git a/Zend/zend_ptr_stack.c b/Zend/zend_ptr_stack.c index d178cc0184527..9d82bba4750a9 100644 --- a/Zend/zend_ptr_stack.c +++ b/Zend/zend_ptr_stack.c @@ -110,23 +110,6 @@ ZEND_API int zend_ptr_stack_num_elements(zend_ptr_stack *stack) { return stack->top; } - -ZEND_API void zend_ptr_stack_push_from_memory(zend_ptr_stack *stack, int count, void **pointers) -{ - ZEND_PTR_STACK_RESIZE_IF_NEEDED(stack, count); - - memcpy(stack->top_element, pointers, count * sizeof(void *)); - stack->top_element += count; - stack->top += count; -} - -ZEND_API void zend_ptr_stack_pop_into_memory(zend_ptr_stack *stack, int count, void **pointers) -{ - memcpy(pointers, stack->top_element - count, count * sizeof(void *)); - stack->top_element -= count; - stack->top -= count; -} - /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_ptr_stack.h b/Zend/zend_ptr_stack.h index fe93e93b5a86d..9f6fc13161a8b 100644 --- a/Zend/zend_ptr_stack.h +++ b/Zend/zend_ptr_stack.h @@ -41,8 +41,6 @@ ZEND_API void zend_ptr_stack_destroy(zend_ptr_stack *stack); ZEND_API void zend_ptr_stack_apply(zend_ptr_stack *stack, void (*func)(void *)); ZEND_API void zend_ptr_stack_clean(zend_ptr_stack *stack, void (*func)(void *), zend_bool free_elements); ZEND_API int zend_ptr_stack_num_elements(zend_ptr_stack *stack); -ZEND_API void zend_ptr_stack_push_from_memory(zend_ptr_stack *stack, int count, void **pointers); -ZEND_API void zend_ptr_stack_pop_into_memory(zend_ptr_stack *stack, int count, void **pointers); END_EXTERN_C() #define ZEND_PTR_STACK_RESIZE_IF_NEEDED(stack, count) \ diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 4ae4ca1267592..966827d5b4b5b 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1161,7 +1161,7 @@ ZEND_VM_HANDLER(92, ZEND_FETCH_FUNC_ARG, CONST|TMP|VAR|CV, UNUSED|CONST|VAR) USE_OPLINE ZEND_VM_DISPATCH_TO_HELPER_EX(zend_fetch_var_address_helper, type, - ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R); + ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R); } ZEND_VM_HANDLER(95, ZEND_FETCH_UNSET, CONST|TMP|VAR|CV, UNUSED|CONST|VAR) @@ -1283,7 +1283,7 @@ ZEND_VM_HANDLER(93, ZEND_FETCH_DIM_FUNC_ARG, VAR|CV, CONST|TMP|VAR|UNUSED|CV) SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = GET_OP1_ZVAL_PTR_PTR(BP_VAR_W); if (OP1_TYPE == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -1519,7 +1519,7 @@ ZEND_VM_HANDLER(94, ZEND_FETCH_OBJ_FUNC_ARG, VAR|UNUSED|CV, CONST|TMP|VAR|CV) { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -1889,7 +1889,6 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) EX(function_state).function = (zend_function *) EX(op_array); EX(function_state).arguments = NULL; - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -1925,8 +1924,8 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) EX(function_state).arguments = NULL; if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { + if (UNEXPECTED(EG(exception) != NULL) && EX(call)->is_ctor_call) { + if (EX(call)->is_ctor_result_used) { Z_DELREF_P(EG(This)); } if (Z_REFCOUNT_P(EG(This)) == 1) { @@ -1939,8 +1938,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) EG(scope) = EX(current_scope); EG(called_scope) = EX(current_called_scope); - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); + EX(call)--; zend_vm_stack_clear_multiple(TSRMLS_C); @@ -1966,6 +1964,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) zend_function *fbc = EX(function_state).function; SAVE_OPLINE(); + EX(object) = EX(call)->object; if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); @@ -2000,11 +1999,11 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) EX(current_called_scope) = EG(called_scope); EG(This) = EX(object); EG(scope) = (fbc->type == ZEND_USER_FUNCTION || !EX(object)) ? fbc->common.scope : NULL; - EG(called_scope) = EX(called_scope); + EG(called_scope) = EX(call)->called_scope; } - zend_arg_types_stack_3_pop(&EG(arg_types_stack), &EX(called_scope), &EX(current_object), &EX(fbc)); - EX(function_state).arguments = zend_vm_stack_push_args(opline->extended_value TSRMLS_CC); + EX(function_state).arguments = zend_vm_stack_top(TSRMLS_C); + zend_vm_stack_push((void*)(zend_uintptr_t)opline->extended_value TSRMLS_CC); LOAD_OPLINE(); if (fbc->type == ZEND_INTERNAL_FUNCTION) { @@ -2054,7 +2053,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (RETURN_VALUE_USED(opline)) { EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); } - } else if (EXPECTED(zend_execute == execute)) { + } else if (EXPECTED(zend_execute_ex == execute_ex)) { if (EXPECTED(EG(exception) == NULL)) { ZEND_VM_ENTER(); } @@ -2100,8 +2099,8 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (should_change_scope) { if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { + if (UNEXPECTED(EG(exception) != NULL) && EX(call)->is_ctor_call) { + if (EX(call)->is_ctor_result_used) { Z_DELREF_P(EG(This)); } if (Z_REFCOUNT_P(EG(This)) == 1) { @@ -2115,8 +2114,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) EG(called_scope) = EX(current_called_scope); } - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); + EX(call)--; zend_vm_stack_clear_multiple(TSRMLS_C); @@ -2463,9 +2461,9 @@ ZEND_VM_HANDLER(112, ZEND_INIT_METHOD_CALL, TMP|VAR|UNUSED|CV, CONST|TMP|VAR|CV) char *function_name_strval; int function_name_strlen; zend_free_op free_op1, free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = GET_OP2_ZVAL_PTR(BP_VAR_R); @@ -2477,49 +2475,51 @@ ZEND_VM_HANDLER(112, ZEND_INIT_METHOD_CALL, TMP|VAR|UNUSED|CV, CONST|TMP|VAR|CV) function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = GET_OP1_OBJ_ZVAL_PTR(BP_VAR_R); + call->object = GET_OP1_OBJ_ZVAL_PTR(BP_VAR_R); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (OP2_TYPE != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((OP2_TYPE == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((OP2_TYPE == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (OP2_TYPE == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; FREE_OP2(); FREE_OP1_IF_VAR(); @@ -2533,9 +2533,9 @@ ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CONST|VAR, CONST|TMP|VAR|UNUS USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (OP1_TYPE == IS_CONST) { /* no function found. try a static method in class */ @@ -2549,24 +2549,24 @@ ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CONST|VAR, CONST|TMP|VAR|UNUS } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (OP1_TYPE == IS_CONST && OP2_TYPE == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (OP1_TYPE != IS_CONST && OP2_TYPE == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (OP2_TYPE != IS_UNUSED) { char *function_name_strval = NULL; @@ -2589,20 +2589,20 @@ ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CONST|VAR, CONST|TMP|VAR|UNUS if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((OP2_TYPE == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((OP2_TYPE == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (OP2_TYPE == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (OP1_TYPE == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -2616,29 +2616,31 @@ ZEND_VM_HANDLER(113, ZEND_INIT_STATIC_METHOD_CALL, CONST|VAR, CONST|TMP|VAR|UNUS if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -2648,19 +2650,21 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) { USE_OPLINE zval *function_name; - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; if (OP2_TYPE == IS_CONST) { function_name = (zval*)(opline->op2.literal+1); if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &EX(fbc)) == FAILURE)) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &call->fbc) == FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; /*CHECK_EXCEPTION();*/ ZEND_VM_NEXT_OPCODE(); } else { @@ -2680,28 +2684,32 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) } else { lcname = zend_str_tolower_dup(function_name_strval, function_name_strlen); } - if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &EX(fbc)) == FAILURE)) { + if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &call->fbc) == FAILURE)) { zend_error_noreturn(E_ERROR, "Call to undefined function %s()", function_name_strval); } efree(lcname); FREE_OP2(); - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (OP2_TYPE != IS_CONST && OP2_TYPE != IS_TMP_VAR && EXPECTED(Z_TYPE_P(function_name) == IS_OBJECT) && Z_OBJ_HANDLER_P(function_name, get_closure) && - Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &EX(called_scope), &EX(fbc), &EX(object) TSRMLS_CC) == SUCCESS) { - if (EX(object)) { - Z_ADDREF_P(EX(object)); + Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &call->called_scope, &call->fbc, &call->object TSRMLS_CC) == SUCCESS) { + if (call->object) { + Z_ADDREF_P(call->object); } if (OP2_TYPE == IS_VAR && OP2_FREE && - EX(fbc)->common.fn_flags & ZEND_ACC_CLOSURE) { + call->fbc->common.fn_flags & ZEND_ACC_CLOSURE) { /* Delay closure destruction until its invocation */ - EX(fbc)->common.prototype = (zend_function*)function_name; + call->fbc->common.prototype = (zend_function*)function_name; } else { FREE_OP2(); } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (OP2_TYPE != IS_CONST && @@ -2732,41 +2740,43 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } - EX(called_scope) = ce; - EX(object) = NULL; + call->called_scope = ce; + call->object = NULL; if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + call->fbc = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); } } else { - EX(object) = *obj; - ce = EX(called_scope) = Z_OBJCE_PP(obj); + call->object = *obj; + ce = call->called_scope = Z_OBJCE_PP(obj); - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), Z_STRVAL_PP(method)); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); } + call->is_ctor_call = 0; + EX(call) = call; FREE_OP2(); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -2781,31 +2791,32 @@ ZEND_VM_HANDLER(69, ZEND_INIT_NS_FCALL_BY_NAME, ANY, CONST) { USE_OPLINE zend_literal *func_name; - - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; func_name = opline->op2.literal + 1; if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &call->fbc)==FAILURE) { func_name++; - if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE)) { + if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &call->fbc)==FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; ZEND_VM_NEXT_OPCODE(); } ZEND_VM_HANDLER(61, ZEND_DO_FCALL_BY_NAME, ANY, ANY) { - EX(function_state).function = EX(fbc); + EX(function_state).function = EX(call)->fbc; ZEND_VM_DISPATCH_TO_HELPER(zend_do_fcall_common_helper); } @@ -2814,8 +2825,7 @@ ZEND_VM_HANDLER(60, ZEND_DO_FCALL, CONST, ANY) USE_OPLINE zend_free_op free_op1; zval *fname = GET_OP1_ZVAL_PTR(BP_VAR_R); - - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->op2.num; if (CACHED_PTR(opline->op1.literal->cache_slot)) { EX(function_state).function = CACHED_PTR(opline->op1.literal->cache_slot); @@ -2825,7 +2835,10 @@ ZEND_VM_HANDLER(60, ZEND_DO_FCALL, CONST, ANY) } else { CACHE_PTR(opline->op1.literal->cache_slot, EX(function_state).function); } - EX(object) = NULL; + call->fbc = EX(function_state).function; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; FREE_OP1(); @@ -3052,7 +3065,7 @@ ZEND_VM_HANDLER(65, ZEND_SEND_VAL, CONST|TMP, ANY) SAVE_OPLINE(); if (opline->extended_value==ZEND_DO_FCALL_BY_NAME - && ARG_MUST_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + && ARG_MUST_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { zend_error_noreturn(E_ERROR, "Cannot pass parameter %d by reference", opline->op2.opline_num); } { @@ -3113,7 +3126,7 @@ ZEND_VM_HANDLER(106, ZEND_SEND_VAR_NO_REF, VAR|CV, ANY) if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { ZEND_VM_DISPATCH_TO_HELPER(zend_send_by_var_helper); } - } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { ZEND_VM_DISPATCH_TO_HELPER(zend_send_by_var_helper); } @@ -3139,7 +3152,7 @@ ZEND_VM_HANDLER(106, ZEND_SEND_VAR_NO_REF, VAR|CV, ANY) if ((opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) ? !(opline->extended_value & ZEND_ARG_SEND_SILENT) : - !ARG_MAY_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + !ARG_MAY_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { zend_error(E_STRICT, "Only variables should be passed by reference"); } ALLOC_ZVAL(valptr); @@ -3175,7 +3188,7 @@ ZEND_VM_HANDLER(67, ZEND_SEND_REF, VAR|CV, ANY) ZEND_VM_NEXT_OPCODE(); } - if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { ZEND_VM_DISPATCH_TO_HELPER(zend_send_by_var_helper); } @@ -3194,7 +3207,7 @@ ZEND_VM_HANDLER(66, ZEND_SEND_VAR, VAR|CV, ANY) USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) - && ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { ZEND_VM_DISPATCH_TO_HANDLER(ZEND_SEND_REF); } SAVE_OPLINE(); @@ -3400,17 +3413,20 @@ ZEND_VM_HANDLER(68, ZEND_NEW, ANY, ANY) } ZEND_VM_JMP(EX(op_array)->opcodes + opline->op2.opline_num); } else { + call_slot *call = EX(call_slots) + opline->extended_value; + if (RETURN_VALUE_USED(opline)) { PZVAL_LOCK(object_zval); AI_SET_PTR(&EX_T(opline->result.var), object_zval); } - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), ENCODE_CTOR(EX(called_scope), RETURN_VALUE_USED(opline))); - /* We are not handling overloaded classes right now */ - EX(object) = object_zval; - EX(fbc) = constructor; - EX(called_scope) = EX_T(opline->op1.var).class_entry; + call->fbc = constructor; + call->object = object_zval; + call->called_scope = EX_T(opline->op1.var).class_entry; + call->is_ctor_call = 1; + call->is_ctor_result_used = RETURN_VALUE_USED(opline); + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -3829,8 +3845,6 @@ ZEND_VM_HANDLER(73, ZEND_INCLUDE_OR_EVAL, CONST|TMP|VAR|CV, ANY) EG(return_value_ptr_ptr) = NULL; } - EX(current_object) = EX(object); - EX(function_state).function = (zend_function *) new_op_array; EX(object) = NULL; @@ -3838,14 +3852,13 @@ ZEND_VM_HANDLER(73, ZEND_INCLUDE_OR_EVAL, CONST|TMP|VAR|CV, ANY) zend_rebuild_symbol_table(TSRMLS_C); } - if (EXPECTED(zend_execute == execute)) { + if (EXPECTED(zend_execute_ex == execute_ex)) { ZEND_VM_ENTER(); } else { zend_execute(new_op_array TSRMLS_CC); } EX(function_state).function = (zend_function *) EX(op_array); - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -5022,19 +5035,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) /* Figure out where the next stack frame (which maybe contains pushed * arguments that have to be dtor'ed) starts */ - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* For generators the next stack frame is conveniently stored in the - * generator object. */ - stack_frame = generator->original_stack_top; - } else { - /* In all other cases the next stack frame starts after the temporary - * variables section of the current execution context */ - stack_frame = (void **) ((char *) EX_Ts() + - ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * EX(op_array)->T); - } + stack_frame = zend_vm_stack_frame_base(EXECUTE_DATA); /* If the exception was thrown during a function call there might be * arguments pushed to the stack that have to be dtor'ed. */ @@ -5056,21 +5057,23 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) } } - while (EX(fbc)) { - EX(called_scope) = (zend_class_entry*)zend_ptr_stack_pop(&EG(arg_types_stack)); - if (EX(object)) { - if (IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { - Z_DELREF_P(EX(object)); - } - if (Z_REFCOUNT_P(EX(object)) == 1) { - zend_object_store_ctor_failed(EX(object) TSRMLS_CC); + if (EX(call) >= EX(call_slots)) { + call_slot *call = EX(call); + do { + if (call->object) { + if (call->is_ctor_call) { + if (call->is_ctor_result_used) { + Z_DELREF_P(call->object); + } + if (Z_REFCOUNT_P(call->object) == 1) { + zend_object_store_ctor_failed(call->object TSRMLS_CC); + } } + zval_ptr_dtor(&call->object); } - zval_ptr_dtor(&EX(object)); - } - EX(called_scope) = DECODE_CTOR(EX(called_scope)); - zend_arg_types_stack_2_pop(&EG(arg_types_stack), &EX(object), &EX(fbc)); + call--; + } while (call >= EX(call_slots)); + EX(call) = NULL; } for (i=0; ilast_brk_cont; i++) { @@ -5240,6 +5243,19 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_NEXT_OPCODE(); } +ZEND_VM_HANDLER(159, ZEND_GENERATOR_FLAG, ANY, ANY) +{ + USE_OPLINE + zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + + if (opline->extended_value) { + generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; + } else { + generator->flags &= ~ZEND_GENERATOR_FORCED_CLOSE; + } + ZEND_VM_NEXT_OPCODE(); +} + ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) { USE_OPLINE diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 582962cfcf5bb..921ece228bbce 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -339,7 +339,50 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #define EX_Ts() EX(Ts) -zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) { +/* + * Stack Frame Layout (the whole stack frame is allocated at once) + * ================== + * + * +========================================+ + * | zend_execute_data |<---+ + * | EX(function_state).arguments |--+ | + * | ... | | | + * | ARGUMENT [1] | | | + * | ... | | | + * | ARGUMENT [ARGS_NUMBER] | | | + * | ARGS_NUMBER |<-+ | + * +========================================+ | + * | + * +========================================+ | + * EG(current_execute_data) -> | zend_execute_data | | + * | EX(prev_execute_data) |----+ + * +----------------------------------------+ + * EX(Ts) ---------> | EX(Ts)[0] | + * | ... | + * | EX(Tx)[op_arrat->T] | + * +----------------------------------------+ + * EX(CVs) --------> | EX(CVs)[0] |--+ + * | ... | | + * | EX(CVs)[op_array->last_var] | | + * +----------------------------------------+ | + * | Optional slot for CV[0] zval* |<-+ + * | ... | + * | ... for CV [op_array->last_var] zval* | + * +----------------------------------------+ + * EX(call_slots) -> | EX(call_slots)[0] | + * | ... | + * | EX(call_slots)[op_array->nested_calls] | + * +----------------------------------------+ + * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | + * | ... | + * zend_vm_stack_top --------> | ... | + * | ... | + * | ARGUMENTS STACK [op_array->used_stack] | + * +----------------------------------------+ + */ + +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) +{ zend_execute_data *execute_data; /* @@ -354,7 +397,9 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (EG(active_symbol_table) ? 1 : 2)); size_t Ts_size = ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T; - size_t total_size = execute_data_size + CVs_size + Ts_size; + size_t call_slots_size = ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * op_array->nested_calls; + size_t stack_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * op_array->used_stack; + size_t total_size = execute_data_size + Ts_size + CVs_size + call_slots_size + stack_size; /* * Normally the execute_data is allocated on the VM stack (because it does @@ -366,23 +411,58 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra * by replacing a pointer. */ if (op_array->fn_flags & ZEND_ACC_GENERATOR) { - execute_data = emalloc(total_size); + /* Prepend the regular stack frame with copy on prev_execute_data + * and passed arguments + */ + int args_count = zend_vm_stack_get_args_count_ex(EG(current_execute_data)); + size_t args_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (args_count + 1); + + total_size += args_size + execute_data_size; + + EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); + EG(argument_stack)->prev = NULL; + execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size); + + /* copy prev_execute_data */ + EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); + memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); + EX(prev_execute_data)->function_state.function = (zend_function*)op_array; + EX(prev_execute_data)->function_state.arguments = (void**)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * args_count); + + /* copy arguemnts */ + *EX(prev_execute_data)->function_state.arguments = (void*)(zend_uintptr_t)args_count; + if (args_count > 0) { + zval **arg_src = (zval**)zend_vm_stack_get_arg_ex(EG(current_execute_data), 1); + zval **arg_dst = (zval**)zend_vm_stack_get_arg_ex(EX(prev_execute_data), 1); + int i; + + for (i = 0; i < args_count; i++) { + arg_dst[i] = arg_src[i]; + Z_ADDREF_P(arg_dst[i]); + } + } } else { execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); + EX(prev_execute_data) = EG(current_execute_data); } - EX(CVs) = (zval ***) ((char *) execute_data + execute_data_size); + EX(Ts) = (temp_variable *) ((char *) execute_data + execute_data_size); + + EX(CVs) = (zval ***) ((char *) EX(Ts) + Ts_size); memset(EX(CVs), 0, sizeof(zval **) * op_array->last_var); - EX(Ts) = (temp_variable *) ((char *) EX(CVs) + CVs_size); + EX(call_slots) = (call_slot*)((char *) EX(CVs) + CVs_size); + + + EX(op_array) = op_array; + + EG(argument_stack)->top = zend_vm_stack_frame_base(execute_data); - EX(fbc) = NULL; - EX(called_scope) = NULL; EX(object) = NULL; + EX(current_this) = NULL; EX(old_error_reporting) = NULL; - EX(op_array) = op_array; EX(symbol_table) = EG(active_symbol_table); - EX(prev_execute_data) = EG(current_execute_data); + EX(call) = NULL; EG(current_execute_data) = execute_data; EX(nested) = nested; @@ -452,12 +532,12 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); } -ZEND_API void execute(zend_op_array *op_array TSRMLS_DC) +ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) { if (EG(exception)) { return; } - execute_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); + zend_execute_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) @@ -509,7 +589,6 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) EX(function_state).function = (zend_function *) EX(op_array); EX(function_state).arguments = NULL; - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -545,8 +624,8 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) EX(function_state).arguments = NULL; if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { + if (UNEXPECTED(EG(exception) != NULL) && EX(call)->is_ctor_call) { + if (EX(call)->is_ctor_result_used) { Z_DELREF_P(EG(This)); } if (Z_REFCOUNT_P(EG(This)) == 1) { @@ -559,8 +638,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) EG(scope) = EX(current_scope); EG(called_scope) = EX(current_called_scope); - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); + EX(call)--; zend_vm_stack_clear_multiple(TSRMLS_C); @@ -586,6 +664,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR zend_function *fbc = EX(function_state).function; SAVE_OPLINE(); + EX(object) = EX(call)->object; if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); @@ -620,11 +699,11 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR EX(current_called_scope) = EG(called_scope); EG(This) = EX(object); EG(scope) = (fbc->type == ZEND_USER_FUNCTION || !EX(object)) ? fbc->common.scope : NULL; - EG(called_scope) = EX(called_scope); + EG(called_scope) = EX(call)->called_scope; } - zend_arg_types_stack_3_pop(&EG(arg_types_stack), &EX(called_scope), &EX(current_object), &EX(fbc)); - EX(function_state).arguments = zend_vm_stack_push_args(opline->extended_value TSRMLS_CC); + EX(function_state).arguments = zend_vm_stack_top(TSRMLS_C); + zend_vm_stack_push((void*)(zend_uintptr_t)opline->extended_value TSRMLS_CC); LOAD_OPLINE(); if (fbc->type == ZEND_INTERNAL_FUNCTION) { @@ -674,7 +753,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR if (RETURN_VALUE_USED(opline)) { EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); } - } else if (EXPECTED(zend_execute == execute)) { + } else if (EXPECTED(zend_execute_ex == execute_ex)) { if (EXPECTED(EG(exception) == NULL)) { ZEND_VM_ENTER(); } @@ -720,8 +799,8 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR if (should_change_scope) { if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { + if (UNEXPECTED(EG(exception) != NULL) && EX(call)->is_ctor_call) { + if (EX(call)->is_ctor_result_used) { Z_DELREF_P(EG(This)); } if (Z_REFCOUNT_P(EG(This)) == 1) { @@ -735,8 +814,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR EG(called_scope) = EX(current_called_scope); } - EX(object) = EX(current_object); - EX(called_scope) = DECODE_CTOR(EX(called_scope)); + EX(call)--; zend_vm_stack_clear_multiple(TSRMLS_C); @@ -780,7 +858,7 @@ static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - EX(function_state).function = EX(fbc); + EX(function_state).function = EX(call)->fbc; return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -860,17 +938,20 @@ static int ZEND_FASTCALL ZEND_NEW_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } ZEND_VM_JMP(EX(op_array)->opcodes + opline->op2.opline_num); } else { + call_slot *call = EX(call_slots) + opline->extended_value; + if (RETURN_VALUE_USED(opline)) { PZVAL_LOCK(object_zval); AI_SET_PTR(&EX_T(opline->result.var), object_zval); } - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), ENCODE_CTOR(EX(called_scope), RETURN_VALUE_USED(opline))); - /* We are not handling overloaded classes right now */ - EX(object) = object_zval; - EX(fbc) = constructor; - EX(called_scope) = EX_T(opline->op1.var).class_entry; + call->fbc = constructor; + call->object = object_zval; + call->called_scope = EX_T(opline->op1.var).class_entry; + call->is_ctor_call = 1; + call->is_ctor_result_used = RETURN_VALUE_USED(opline); + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -1075,19 +1156,7 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER /* Figure out where the next stack frame (which maybe contains pushed * arguments that have to be dtor'ed) starts */ - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* For generators the next stack frame is conveniently stored in the - * generator object. */ - stack_frame = generator->original_stack_top; - } else { - /* In all other cases the next stack frame starts after the temporary - * variables section of the current execution context */ - stack_frame = (void **) ((char *) EX_Ts() + - ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * EX(op_array)->T); - } + stack_frame = zend_vm_stack_frame_base(execute_data); /* If the exception was thrown during a function call there might be * arguments pushed to the stack that have to be dtor'ed. */ @@ -1109,21 +1178,23 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER } } - while (EX(fbc)) { - EX(called_scope) = (zend_class_entry*)zend_ptr_stack_pop(&EG(arg_types_stack)); - if (EX(object)) { - if (IS_CTOR_CALL(EX(called_scope))) { - if (IS_CTOR_USED(EX(called_scope))) { - Z_DELREF_P(EX(object)); - } - if (Z_REFCOUNT_P(EX(object)) == 1) { - zend_object_store_ctor_failed(EX(object) TSRMLS_CC); + if (EX(call) >= EX(call_slots)) { + call_slot *call = EX(call); + do { + if (call->object) { + if (call->is_ctor_call) { + if (call->is_ctor_result_used) { + Z_DELREF_P(call->object); + } + if (Z_REFCOUNT_P(call->object) == 1) { + zend_object_store_ctor_failed(call->object TSRMLS_CC); + } } + zval_ptr_dtor(&call->object); } - zval_ptr_dtor(&EX(object)); - } - EX(called_scope) = DECODE_CTOR(EX(called_scope)); - zend_arg_types_stack_2_pop(&EG(arg_types_stack), &EX(object), &EX(fbc)); + call--; + } while (call >= EX(call_slots)); + EX(call) = NULL; } for (i=0; ilast_brk_cont; i++) { @@ -1213,6 +1284,19 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } +static int ZEND_FASTCALL ZEND_GENERATOR_FLAG_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + USE_OPLINE + zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + + if (opline->extended_value) { + generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; + } else { + generator->flags &= ~ZEND_GENERATOR_FORCED_CLOSE; + } + ZEND_VM_NEXT_OPCODE(); +} + static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1291,19 +1375,21 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE { USE_OPLINE zval *function_name; - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; if (IS_CONST == IS_CONST) { function_name = (zval*)(opline->op2.literal+1); if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &EX(fbc)) == FAILURE)) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &call->fbc) == FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; /*CHECK_EXCEPTION();*/ ZEND_VM_NEXT_OPCODE(); } else { @@ -1323,28 +1409,32 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE } else { lcname = zend_str_tolower_dup(function_name_strval, function_name_strlen); } - if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &EX(fbc)) == FAILURE)) { + if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &call->fbc) == FAILURE)) { zend_error_noreturn(E_ERROR, "Call to undefined function %s()", function_name_strval); } efree(lcname); - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_CONST != IS_CONST && IS_CONST != IS_TMP_VAR && EXPECTED(Z_TYPE_P(function_name) == IS_OBJECT) && Z_OBJ_HANDLER_P(function_name, get_closure) && - Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &EX(called_scope), &EX(fbc), &EX(object) TSRMLS_CC) == SUCCESS) { - if (EX(object)) { - Z_ADDREF_P(EX(object)); + Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &call->called_scope, &call->fbc, &call->object TSRMLS_CC) == SUCCESS) { + if (call->object) { + Z_ADDREF_P(call->object); } if (IS_CONST == IS_VAR && 0 && - EX(fbc)->common.fn_flags & ZEND_ACC_CLOSURE) { + call->fbc->common.fn_flags & ZEND_ACC_CLOSURE) { /* Delay closure destruction until its invocation */ - EX(fbc)->common.prototype = (zend_function*)function_name; + call->fbc->common.prototype = (zend_function*)function_name; } else { } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_CONST != IS_CONST && @@ -1375,41 +1465,43 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } - EX(called_scope) = ce; - EX(object) = NULL; + call->called_scope = ce; + call->object = NULL; if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + call->fbc = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); } } else { - EX(object) = *obj; - ce = EX(called_scope) = Z_OBJCE_PP(obj); + call->object = *obj; + ce = call->called_scope = Z_OBJCE_PP(obj); - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), Z_STRVAL_PP(method)); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -1424,25 +1516,26 @@ static int ZEND_FASTCALL ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPC { USE_OPLINE zend_literal *func_name; - - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; func_name = opline->op2.literal + 1; if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &call->fbc)==FAILURE) { func_name++; - if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &EX(fbc))==FAILURE)) { + if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL(func_name->constant), Z_STRLEN(func_name->constant)+1, func_name->hash_value, (void **) &call->fbc)==FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; ZEND_VM_NEXT_OPCODE(); } @@ -1599,19 +1692,21 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H { USE_OPLINE zval *function_name; - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; if (IS_TMP_VAR == IS_CONST) { function_name = (zval*)(opline->op2.literal+1); if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &EX(fbc)) == FAILURE)) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &call->fbc) == FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; /*CHECK_EXCEPTION();*/ ZEND_VM_NEXT_OPCODE(); } else { @@ -1631,28 +1726,32 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H } else { lcname = zend_str_tolower_dup(function_name_strval, function_name_strlen); } - if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &EX(fbc)) == FAILURE)) { + if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &call->fbc) == FAILURE)) { zend_error_noreturn(E_ERROR, "Call to undefined function %s()", function_name_strval); } efree(lcname); zval_dtor(free_op2.var); - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_TMP_VAR != IS_CONST && IS_TMP_VAR != IS_TMP_VAR && EXPECTED(Z_TYPE_P(function_name) == IS_OBJECT) && Z_OBJ_HANDLER_P(function_name, get_closure) && - Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &EX(called_scope), &EX(fbc), &EX(object) TSRMLS_CC) == SUCCESS) { - if (EX(object)) { - Z_ADDREF_P(EX(object)); + Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &call->called_scope, &call->fbc, &call->object TSRMLS_CC) == SUCCESS) { + if (call->object) { + Z_ADDREF_P(call->object); } if (IS_TMP_VAR == IS_VAR && 1 && - EX(fbc)->common.fn_flags & ZEND_ACC_CLOSURE) { + call->fbc->common.fn_flags & ZEND_ACC_CLOSURE) { /* Delay closure destruction until its invocation */ - EX(fbc)->common.prototype = (zend_function*)function_name; + call->fbc->common.prototype = (zend_function*)function_name; } else { zval_dtor(free_op2.var); } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_TMP_VAR != IS_CONST && @@ -1683,41 +1782,43 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } - EX(called_scope) = ce; - EX(object) = NULL; + call->called_scope = ce; + call->object = NULL; if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + call->fbc = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); } } else { - EX(object) = *obj; - ce = EX(called_scope) = Z_OBJCE_PP(obj); + call->object = *obj; + ce = call->called_scope = Z_OBJCE_PP(obj); - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), Z_STRVAL_PP(method)); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); } + call->is_ctor_call = 0; + EX(call) = call; zval_dtor(free_op2.var); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -1769,19 +1870,21 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H { USE_OPLINE zval *function_name; - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; if (IS_VAR == IS_CONST) { function_name = (zval*)(opline->op2.literal+1); if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &EX(fbc)) == FAILURE)) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &call->fbc) == FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; /*CHECK_EXCEPTION();*/ ZEND_VM_NEXT_OPCODE(); } else { @@ -1801,28 +1904,32 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H } else { lcname = zend_str_tolower_dup(function_name_strval, function_name_strlen); } - if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &EX(fbc)) == FAILURE)) { + if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &call->fbc) == FAILURE)) { zend_error_noreturn(E_ERROR, "Call to undefined function %s()", function_name_strval); } efree(lcname); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_VAR != IS_CONST && IS_VAR != IS_TMP_VAR && EXPECTED(Z_TYPE_P(function_name) == IS_OBJECT) && Z_OBJ_HANDLER_P(function_name, get_closure) && - Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &EX(called_scope), &EX(fbc), &EX(object) TSRMLS_CC) == SUCCESS) { - if (EX(object)) { - Z_ADDREF_P(EX(object)); + Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &call->called_scope, &call->fbc, &call->object TSRMLS_CC) == SUCCESS) { + if (call->object) { + Z_ADDREF_P(call->object); } if (IS_VAR == IS_VAR && (free_op2.var != NULL) && - EX(fbc)->common.fn_flags & ZEND_ACC_CLOSURE) { + call->fbc->common.fn_flags & ZEND_ACC_CLOSURE) { /* Delay closure destruction until its invocation */ - EX(fbc)->common.prototype = (zend_function*)function_name; + call->fbc->common.prototype = (zend_function*)function_name; } else { if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_VAR != IS_CONST && @@ -1853,41 +1960,43 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } - EX(called_scope) = ce; - EX(object) = NULL; + call->called_scope = ce; + call->object = NULL; if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + call->fbc = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); } } else { - EX(object) = *obj; - ce = EX(called_scope) = Z_OBJCE_PP(obj); + call->object = *obj; + ce = call->called_scope = Z_OBJCE_PP(obj); - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), Z_STRVAL_PP(method)); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); } + call->is_ctor_call = 0; + EX(call) = call; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -1974,19 +2083,21 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA { USE_OPLINE zval *function_name; - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->result.num; if (IS_CV == IS_CONST) { function_name = (zval*)(opline->op2.literal+1); if (CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); - } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &EX(fbc)) == FAILURE)) { + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); + } else if (UNEXPECTED(zend_hash_quick_find(EG(function_table), Z_STRVAL_P(function_name), Z_STRLEN_P(function_name)+1, Z_HASH_P(function_name), (void **) &call->fbc) == FAILURE)) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Call to undefined function %s()", Z_STRVAL_P(opline->op2.zv)); } else { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; /*CHECK_EXCEPTION();*/ ZEND_VM_NEXT_OPCODE(); } else { @@ -2006,28 +2117,32 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA } else { lcname = zend_str_tolower_dup(function_name_strval, function_name_strlen); } - if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &EX(fbc)) == FAILURE)) { + if (UNEXPECTED(zend_hash_find(EG(function_table), lcname, function_name_strlen+1, (void **) &call->fbc) == FAILURE)) { zend_error_noreturn(E_ERROR, "Call to undefined function %s()", function_name_strval); } efree(lcname); - EX(object) = NULL; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_CV != IS_CONST && IS_CV != IS_TMP_VAR && EXPECTED(Z_TYPE_P(function_name) == IS_OBJECT) && Z_OBJ_HANDLER_P(function_name, get_closure) && - Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &EX(called_scope), &EX(fbc), &EX(object) TSRMLS_CC) == SUCCESS) { - if (EX(object)) { - Z_ADDREF_P(EX(object)); + Z_OBJ_HANDLER_P(function_name, get_closure)(function_name, &call->called_scope, &call->fbc, &call->object TSRMLS_CC) == SUCCESS) { + if (call->object) { + Z_ADDREF_P(call->object); } if (IS_CV == IS_VAR && 0 && - EX(fbc)->common.fn_flags & ZEND_ACC_CLOSURE) { + call->fbc->common.fn_flags & ZEND_ACC_CLOSURE) { /* Delay closure destruction until its invocation */ - EX(fbc)->common.prototype = (zend_function*)function_name; + call->fbc->common.prototype = (zend_function*)function_name; } else { } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else if (IS_CV != IS_CONST && @@ -2058,41 +2173,43 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } - EX(called_scope) = ce; - EX(object) = NULL; + call->called_scope = ce; + call->object = NULL; if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); + call->fbc = ce->get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method) TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); } } else { - EX(object) = *obj; - ce = EX(called_scope) = Z_OBJCE_PP(obj); + call->object = *obj; + ce = call->called_scope = Z_OBJCE_PP(obj); - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), Z_STRVAL_PP(method)); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, Z_STRVAL_PP(method), Z_STRLEN_PP(method), NULL TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), Z_STRVAL_PP(method)); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, Z_STRVAL_PP(method)); } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -2328,8 +2445,7 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A USE_OPLINE zval *fname = opline->op1.zv; - - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); + call_slot *call = EX(call_slots) + opline->op2.num; if (CACHED_PTR(opline->op1.literal->cache_slot)) { EX(function_state).function = CACHED_PTR(opline->op1.literal->cache_slot); @@ -2339,7 +2455,10 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A } else { CACHE_PTR(opline->op1.literal->cache_slot, EX(function_state).function); } - EX(object) = NULL; + call->fbc = EX(function_state).function; + call->object = NULL; + call->is_ctor_call = 0; + EX(call) = call; return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -2498,7 +2617,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); if (opline->extended_value==ZEND_DO_FCALL_BY_NAME - && ARG_MUST_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + && ARG_MUST_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { zend_error_noreturn(E_ERROR, "Cannot pass parameter %d by reference", opline->op2.opline_num); } { @@ -2754,8 +2873,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HA EG(return_value_ptr_ptr) = NULL; } - EX(current_object) = EX(object); - EX(function_state).function = (zend_function *) new_op_array; EX(object) = NULL; @@ -2763,14 +2880,13 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HA zend_rebuild_symbol_table(TSRMLS_C); } - if (EXPECTED(zend_execute == execute)) { + if (EXPECTED(zend_execute_ex == execute_ex)) { ZEND_VM_ENTER(); } else { zend_execute(new_op_array TSRMLS_CC); } EX(function_state).function = (zend_function *) EX(op_array); - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -3497,7 +3613,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER(ZEND_OPCO { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CONST_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_CONST_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -3569,9 +3685,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER( USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_CONST == IS_CONST) { /* no function found. try a static method in class */ @@ -3585,24 +3701,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER( } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_CONST == IS_CONST && IS_CONST == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_CONST != IS_CONST && IS_CONST == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_CONST != IS_UNUSED) { char *function_name_strval = NULL; @@ -3625,20 +3741,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER( if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_CONST == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_CONST == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -3652,29 +3768,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER( if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -4555,9 +4673,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_CONST == IS_CONST) { /* no function found. try a static method in class */ @@ -4571,24 +4689,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_CONST == IS_CONST && IS_TMP_VAR == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_CONST != IS_CONST && IS_TMP_VAR == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_TMP_VAR != IS_UNUSED) { char *function_name_strval = NULL; @@ -4611,20 +4729,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_TMP_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_CONST == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -4638,29 +4756,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -5365,7 +5485,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CONST_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_CONST_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -5413,9 +5533,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_CONST == IS_CONST) { /* no function found. try a static method in class */ @@ -5429,24 +5549,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_CONST == IS_CONST && IS_VAR == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_CONST != IS_CONST && IS_VAR == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_VAR != IS_UNUSED) { char *function_name_strval = NULL; @@ -5469,20 +5589,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_CONST == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -5496,29 +5616,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -6109,7 +6231,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER(ZEND_OPC { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -6127,9 +6249,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_CONST == IS_CONST) { /* no function found. try a static method in class */ @@ -6143,24 +6265,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_CONST == IS_CONST && IS_UNUSED == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_CONST != IS_CONST && IS_UNUSED == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_UNUSED != IS_UNUSED) { char *function_name_strval = NULL; @@ -6183,20 +6305,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_UNUSED == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_UNUSED == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_UNUSED == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_CONST == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -6210,29 +6332,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -6982,9 +7106,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_CONST == IS_CONST) { /* no function found. try a static method in class */ @@ -6998,24 +7122,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_CONST == IS_CONST && IS_CV == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_CONST != IS_CONST && IS_CV == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_CV != IS_UNUSED) { char *function_name_strval = NULL; @@ -7038,20 +7162,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_CV == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_CONST == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -7065,29 +7189,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -7813,7 +7939,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); if (opline->extended_value==ZEND_DO_FCALL_BY_NAME - && ARG_MUST_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + && ARG_MUST_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { zend_error_noreturn(E_ERROR, "Cannot pass parameter %d by reference", opline->op2.opline_num); } { @@ -8070,8 +8196,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND EG(return_value_ptr_ptr) = NULL; } - EX(current_object) = EX(object); - EX(function_state).function = (zend_function *) new_op_array; EX(object) = NULL; @@ -8079,14 +8203,13 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND zend_rebuild_symbol_table(TSRMLS_C); } - if (EXPECTED(zend_execute == execute)) { + if (EXPECTED(zend_execute_ex == execute_ex)) { ZEND_VM_ENTER(); } else { zend_execute(new_op_array TSRMLS_CC); } EX(function_state).function = (zend_function *) EX(op_array); - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -8865,7 +8988,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_TMP_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_TMP_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -8985,9 +9108,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO char *function_name_strval; int function_name_strlen; zend_free_op free_op1; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = opline->op2.zv; @@ -8999,49 +9122,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CONST != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CONST == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); @@ -9838,9 +9963,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE char *function_name_strval; int function_name_strlen; zend_free_op free_op1, free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -9852,49 +9977,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_TMP_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_TMP_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; zval_dtor(free_op2.var); @@ -10601,7 +10728,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_H { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_TMP_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_TMP_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -10696,9 +10823,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE char *function_name_strval; int function_name_strlen; zend_free_op free_op1, free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -10710,49 +10837,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -11345,7 +11474,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCOD { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -12130,9 +12259,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ char *function_name_strval; int function_name_strlen; zend_free_op free_op1; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); @@ -12144,49 +12273,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CV != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CV == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); @@ -13067,7 +13198,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -13093,7 +13224,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND if ((opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) ? !(opline->extended_value & ZEND_ARG_SEND_SILENT) : - !ARG_MAY_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + !ARG_MAY_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { zend_error(E_STRICT, "Only variables should be passed by reference"); } ALLOC_ZVAL(valptr); @@ -13129,7 +13260,7 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } - if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -13148,7 +13279,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) - && ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { return ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } SAVE_OPLINE(); @@ -13400,8 +13531,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND EG(return_value_ptr_ptr) = NULL; } - EX(current_object) = EX(object); - EX(function_state).function = (zend_function *) new_op_array; EX(object) = NULL; @@ -13409,14 +13538,13 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND zend_rebuild_symbol_table(TSRMLS_C); } - if (EXPECTED(zend_execute == execute)) { + if (EXPECTED(zend_execute_ex == execute_ex)) { ZEND_VM_ENTER(); } else { zend_execute(new_op_array TSRMLS_CC); } EX(function_state).function = (zend_function *) EX(op_array); - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -14772,7 +14900,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_VAR_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_VAR_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -14894,7 +15022,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -15130,7 +15258,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1; zval *property; @@ -15378,9 +15506,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO char *function_name_strval; int function_name_strlen; zend_free_op free_op1; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = opline->op2.zv; @@ -15392,49 +15520,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CONST != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CONST == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15447,9 +15577,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZE USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_VAR == IS_CONST) { /* no function found. try a static method in class */ @@ -15463,24 +15593,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZE } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_VAR == IS_CONST && IS_CONST == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_VAR != IS_CONST && IS_CONST == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_CONST != IS_UNUSED) { char *function_name_strval = NULL; @@ -15503,20 +15633,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZE if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_CONST == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_VAR == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -15530,29 +15660,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZE if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -17227,7 +17359,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -17463,7 +17595,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -17712,9 +17844,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE char *function_name_strval; int function_name_strlen; zend_free_op free_op1, free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -17726,49 +17858,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_TMP_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_TMP_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; zval_dtor(free_op2.var); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -17782,9 +17916,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_VAR == IS_CONST) { /* no function found. try a static method in class */ @@ -17798,24 +17932,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_VAR == IS_CONST && IS_TMP_VAR == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_VAR != IS_CONST && IS_TMP_VAR == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_TMP_VAR != IS_UNUSED) { char *function_name_strval = NULL; @@ -17838,20 +17972,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_TMP_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_VAR == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -17865,29 +17999,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -19352,7 +19488,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_H { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_VAR_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_VAR_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -19474,7 +19610,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -19710,7 +19846,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -20014,9 +20150,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE char *function_name_strval; int function_name_strlen; zend_free_op free_op1, free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -20028,49 +20164,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -20084,9 +20222,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_VAR == IS_CONST) { /* no function found. try a static method in class */ @@ -20100,24 +20238,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_VAR == IS_CONST && IS_VAR == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_VAR != IS_CONST && IS_VAR == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_VAR != IS_UNUSED) { char *function_name_strval = NULL; @@ -20140,20 +20278,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_VAR == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -20167,29 +20305,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -21333,7 +21473,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCOD { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -21410,7 +21550,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_O SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -21517,9 +21657,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(Z USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_VAR == IS_CONST) { /* no function found. try a static method in class */ @@ -21533,24 +21673,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(Z } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_VAR == IS_CONST && IS_UNUSED == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_VAR != IS_CONST && IS_UNUSED == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_UNUSED != IS_UNUSED) { char *function_name_strval = NULL; @@ -21573,20 +21713,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(Z if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_UNUSED == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_UNUSED == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_UNUSED == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_VAR == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -21600,29 +21740,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(Z if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -22913,7 +23055,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -23149,7 +23291,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1; zval *property; @@ -23450,9 +23592,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ char *function_name_strval; int function_name_strlen; zend_free_op free_op1; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); @@ -23464,49 +23606,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CV != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CV == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -23519,9 +23663,9 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_ USE_OPLINE zval *function_name; zend_class_entry *ce; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); if (IS_VAR == IS_CONST) { /* no function found. try a static method in class */ @@ -23535,24 +23679,24 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_ } CACHE_PTR(opline->op1.literal->cache_slot, ce); } - EX(called_scope) = ce; + call->called_scope = ce; } else { ce = EX_T(opline->op1.var).class_entry; if (opline->extended_value == ZEND_FETCH_CLASS_PARENT || opline->extended_value == ZEND_FETCH_CLASS_SELF) { - EX(called_scope) = EG(called_scope); + call->called_scope = EG(called_scope); } else { - EX(called_scope) = ce; + call->called_scope = ce; } } if (IS_VAR == IS_CONST && IS_CV == IS_CONST && CACHED_PTR(opline->op2.literal->cache_slot)) { - EX(fbc) = CACHED_PTR(opline->op2.literal->cache_slot); + call->fbc = CACHED_PTR(opline->op2.literal->cache_slot); } else if (IS_VAR != IS_CONST && IS_CV == IS_CONST && - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce))) { /* do nothing */ } else if (IS_CV != IS_UNUSED) { char *function_name_strval = NULL; @@ -23575,20 +23719,20 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_ if (function_name_strval) { if (ce->get_static_method) { - EX(fbc) = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); + call->fbc = ce->get_static_method(ce, function_name_strval, function_name_strlen TSRMLS_CC); } else { - EX(fbc) = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + call->fbc = zend_std_get_static_method(ce, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); } - if (UNEXPECTED(EX(fbc) == NULL)) { + if (UNEXPECTED(call->fbc == NULL)) { zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", ce->name, function_name_strval); } if (IS_CV == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0)) { if (IS_VAR == IS_CONST) { - CACHE_PTR(opline->op2.literal->cache_slot, EX(fbc)); + CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } else { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, EX(fbc)); + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, ce, call->fbc); } } } @@ -23602,29 +23746,31 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_ if (EG(This) && Z_OBJCE_P(EG(This)) != ce->constructor->common.scope && (ce->constructor->common.fn_flags & ZEND_ACC_PRIVATE)) { zend_error_noreturn(E_ERROR, "Cannot call private %s::__construct()", ce->name); } - EX(fbc) = ce->constructor; + call->fbc = ce->constructor; } - if (EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) { - EX(object) = NULL; + if (call->fbc->common.fn_flags & ZEND_ACC_STATIC) { + call->object = NULL; } else { if (EG(This) && Z_OBJ_HT_P(EG(This))->get_class_entry && !instanceof_function(Z_OBJCE_P(EG(This)), ce TSRMLS_CC)) { /* We are calling method of the other (incompatible) class, but passing $this. This is done for compatibility with php-4. */ - if (EX(fbc)->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + if (call->fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", EX(fbc)->common.scope->name, EX(fbc)->common.function_name); + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically, assuming $this from incompatible context", call->fbc->common.scope->name, call->fbc->common.function_name); } } - if ((EX(object) = EG(This))) { - Z_ADDREF_P(EX(object)); - EX(called_scope) = Z_OBJCE_P(EX(object)); + if ((call->object = EG(This))) { + Z_ADDREF_P(call->object); + call->called_scope = Z_OBJCE_P(call->object); } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -24915,7 +25061,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER(ZEND { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1; zval *property; @@ -25073,9 +25219,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER(ZEND_O char *function_name_strval; int function_name_strlen; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = opline->op2.zv; @@ -25087,49 +25233,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER(ZEND_O function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_obj_zval_ptr_unused(TSRMLS_C); + call->object = _get_obj_zval_ptr_unused(TSRMLS_C); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CONST != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CONST == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); @@ -26320,7 +26468,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER(ZEND_O { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -26477,9 +26625,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPC char *function_name_strval; int function_name_strlen; zend_free_op free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -26491,49 +26639,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPC function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_obj_zval_ptr_unused(TSRMLS_C); + call->object = _get_obj_zval_ptr_unused(TSRMLS_C); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_TMP_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_TMP_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; zval_dtor(free_op2.var); @@ -27633,7 +27783,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER(ZEND_O { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -27790,9 +27940,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPC char *function_name_strval; int function_name_strlen; zend_free_op free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -27804,49 +27954,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPC function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_obj_zval_ptr_unused(TSRMLS_C); + call->object = _get_obj_zval_ptr_unused(TSRMLS_C); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -29369,7 +29521,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER(ZEND_OP { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1; zval *property; @@ -29525,9 +29677,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCO char *function_name_strval; int function_name_strlen; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); @@ -29539,49 +29691,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCO function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_obj_zval_ptr_unused(TSRMLS_C); + call->object = _get_obj_zval_ptr_unused(TSRMLS_C); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CV != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CV == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); @@ -30630,7 +30784,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } - } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -30656,7 +30810,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL if ((opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) ? !(opline->extended_value & ZEND_ARG_SEND_SILENT) : - !ARG_MAY_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + !ARG_MAY_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { zend_error(E_STRICT, "Only variables should be passed by reference"); } ALLOC_ZVAL(valptr); @@ -30692,7 +30846,7 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } - if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } @@ -30710,7 +30864,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) - && ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->op2.opline_num)) { + && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { return ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } SAVE_OPLINE(); @@ -30951,8 +31105,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL EG(return_value_ptr_ptr) = NULL; } - EX(current_object) = EX(object); - EX(function_state).function = (zend_function *) new_op_array; EX(object) = NULL; @@ -30960,14 +31112,13 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL zend_rebuild_symbol_table(TSRMLS_C); } - if (EXPECTED(zend_execute == execute)) { + if (EXPECTED(zend_execute_ex == execute_ex)) { ZEND_VM_ENTER(); } else { zend_execute(new_op_array TSRMLS_CC); } EX(function_state).function = (zend_function *) EX(op_array); - EX(object) = EX(current_object); EG(opline_ptr) = &EX(opline); EG(active_op_array) = EX(op_array); @@ -32176,7 +32327,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CV_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_CV_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -32297,7 +32448,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -32530,7 +32681,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1; zval *property; @@ -32775,9 +32926,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD char *function_name_strval; int function_name_strlen; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = opline->op2.zv; @@ -32789,49 +32940,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CONST != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CONST == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CONST == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); @@ -34407,7 +34560,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -34640,7 +34793,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -34886,9 +35039,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ char *function_name_strval; int function_name_strlen; zend_free_op free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -34900,49 +35053,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_TMP_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_TMP_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_TMP_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; zval_dtor(free_op2.var); @@ -36402,7 +36557,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HA { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CV_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_CV_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -36523,7 +36678,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -36756,7 +36911,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1, free_op2; zval *property; @@ -37056,9 +37211,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ char *function_name_strval; int function_name_strlen; zend_free_op free_op2; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); @@ -37070,49 +37225,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_VAR != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_VAR == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_VAR == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -38251,7 +38408,7 @@ static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -38327,7 +38484,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OP SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -39689,7 +39846,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE SAVE_OPLINE(); - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -39922,7 +40079,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE { USE_OPLINE - if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), (opline->extended_value & ZEND_FETCH_ARG_MASK))) { + if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { /* Behave like FETCH_OBJ_W */ zend_free_op free_op1; zval *property; @@ -40219,9 +40376,9 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H char *function_name_strval; int function_name_strlen; + call_slot *call = EX(call_slots) + opline->result.num; SAVE_OPLINE(); - zend_ptr_stack_3_push(&EG(arg_types_stack), EX(fbc), EX(object), EX(called_scope)); function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); @@ -40233,49 +40390,51 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - EX(object) = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - if (EXPECTED(EX(object) != NULL) && - EXPECTED(Z_TYPE_P(EX(object)) == IS_OBJECT)) { - EX(called_scope) = Z_OBJCE_P(EX(object)); + if (EXPECTED(call->object != NULL) && + EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { + call->called_scope = Z_OBJCE_P(call->object); if (IS_CV != IS_CONST || - (EX(fbc) = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope))) == NULL) { - zval *object = EX(object); + (call->fbc = CACHED_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope)) == NULL) { + zval *object = call->object; - if (UNEXPECTED(Z_OBJ_HT_P(EX(object))->get_method == NULL)) { + if (UNEXPECTED(Z_OBJ_HT_P(call->object)->get_method == NULL)) { zend_error_noreturn(E_ERROR, "Object does not support method calls"); } /* First, locate the function. */ - EX(fbc) = Z_OBJ_HT_P(EX(object))->get_method(&EX(object), function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); - if (UNEXPECTED(EX(fbc) == NULL)) { - zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(EX(object)), function_name_strval); + call->fbc = Z_OBJ_HT_P(call->object)->get_method(&call->object, function_name_strval, function_name_strlen, ((IS_CV == IS_CONST) ? (opline->op2.literal + 1) : NULL) TSRMLS_CC); + if (UNEXPECTED(call->fbc == NULL)) { + zend_error_noreturn(E_ERROR, "Call to undefined method %s::%s()", Z_OBJ_CLASS_NAME_P(call->object), function_name_strval); } if (IS_CV == IS_CONST && - EXPECTED(EX(fbc)->type <= ZEND_USER_FUNCTION) && - EXPECTED((EX(fbc)->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && - EXPECTED(EX(object) == object)) { - CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, EX(called_scope), EX(fbc)); + EXPECTED(call->fbc->type <= ZEND_USER_FUNCTION) && + EXPECTED((call->fbc->common.fn_flags & (ZEND_ACC_CALL_VIA_HANDLER|ZEND_ACC_NEVER_CACHE)) == 0) && + EXPECTED(call->object == object)) { + CACHE_POLYMORPHIC_PTR(opline->op2.literal->cache_slot, call->called_scope, call->fbc); } } } else { zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } - if ((EX(fbc)->common.fn_flags & ZEND_ACC_STATIC) != 0) { - EX(object) = NULL; + if ((call->fbc->common.fn_flags & ZEND_ACC_STATIC) != 0) { + call->object = NULL; } else { - if (!PZVAL_IS_REF(EX(object))) { - Z_ADDREF_P(EX(object)); /* For $this pointer */ + if (!PZVAL_IS_REF(call->object)) { + Z_ADDREF_P(call->object); /* For $this pointer */ } else { zval *this_ptr; ALLOC_ZVAL(this_ptr); - INIT_PZVAL_COPY(this_ptr, EX(object)); + INIT_PZVAL_COPY(this_ptr, call->object); zval_copy_ctor(this_ptr); - EX(object) = this_ptr; + call->object = this_ptr; } } + call->is_ctor_call = 0; + EX(call) = call; CHECK_EXCEPTION(); @@ -44828,31 +44987,31 @@ void zend_init_opcodes_handlers(void) ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_GENERATOR_FLAG_SPEC_HANDLER, ZEND_YIELD_SPEC_CONST_CONST_HANDLER, ZEND_YIELD_SPEC_CONST_TMP_HANDLER, ZEND_YIELD_SPEC_CONST_VAR_HANDLER, diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index e2d5dd12b039b..85d3dfb04f180 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -1,6 +1,49 @@ {%DEFINES%} -zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) { +/* + * Stack Frame Layout (the whole stack frame is allocated at once) + * ================== + * + * +========================================+ + * | zend_execute_data |<---+ + * | EX(function_state).arguments |--+ | + * | ... | | | + * | ARGUMENT [1] | | | + * | ... | | | + * | ARGUMENT [ARGS_NUMBER] | | | + * | ARGS_NUMBER |<-+ | + * +========================================+ | + * | + * +========================================+ | + * EG(current_execute_data) -> | zend_execute_data | | + * | EX(prev_execute_data) |----+ + * +----------------------------------------+ + * EX(Ts) ---------> | EX(Ts)[0] | + * | ... | + * | EX(Tx)[op_arrat->T] | + * +----------------------------------------+ + * EX(CVs) --------> | EX(CVs)[0] |--+ + * | ... | | + * | EX(CVs)[op_array->last_var] | | + * +----------------------------------------+ | + * | Optional slot for CV[0] zval* |<-+ + * | ... | + * | ... for CV [op_array->last_var] zval* | + * +----------------------------------------+ + * EX(call_slots) -> | EX(call_slots)[0] | + * | ... | + * | EX(call_slots)[op_array->nested_calls] | + * +----------------------------------------+ + * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | + * | ... | + * zend_vm_stack_top --------> | ... | + * | ... | + * | ARGUMENTS STACK [op_array->used_stack] | + * +----------------------------------------+ + */ + +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) +{ zend_execute_data *execute_data; /* @@ -15,7 +58,9 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (EG(active_symbol_table) ? 1 : 2)); size_t Ts_size = ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T; - size_t total_size = execute_data_size + CVs_size + Ts_size; + size_t call_slots_size = ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * op_array->nested_calls; + size_t stack_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * op_array->used_stack; + size_t total_size = execute_data_size + Ts_size + CVs_size + call_slots_size + stack_size; /* * Normally the execute_data is allocated on the VM stack (because it does @@ -27,23 +72,58 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra * by replacing a pointer. */ if (op_array->fn_flags & ZEND_ACC_GENERATOR) { - execute_data = emalloc(total_size); + /* Prepend the regular stack frame with copy on prev_execute_data + * and passed arguments + */ + int args_count = zend_vm_stack_get_args_count_ex(EG(current_execute_data)); + size_t args_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (args_count + 1); + + total_size += args_size + execute_data_size; + + EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); + EG(argument_stack)->prev = NULL; + execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size); + + /* copy prev_execute_data */ + EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); + memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); + EX(prev_execute_data)->function_state.function = (zend_function*)op_array; + EX(prev_execute_data)->function_state.arguments = (void**)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * args_count); + + /* copy arguemnts */ + *EX(prev_execute_data)->function_state.arguments = (void*)(zend_uintptr_t)args_count; + if (args_count > 0) { + zval **arg_src = (zval**)zend_vm_stack_get_arg_ex(EG(current_execute_data), 1); + zval **arg_dst = (zval**)zend_vm_stack_get_arg_ex(EX(prev_execute_data), 1); + int i; + + for (i = 0; i < args_count; i++) { + arg_dst[i] = arg_src[i]; + Z_ADDREF_P(arg_dst[i]); + } + } } else { execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); + EX(prev_execute_data) = EG(current_execute_data); } - EX(CVs) = (zval ***) ((char *) execute_data + execute_data_size); + EX(Ts) = (temp_variable *) ((char *) execute_data + execute_data_size); + + EX(CVs) = (zval ***) ((char *) EX(Ts) + Ts_size); memset(EX(CVs), 0, sizeof(zval **) * op_array->last_var); - EX(Ts) = (temp_variable *) ((char *) EX(CVs) + CVs_size); + EX(call_slots) = (call_slot*)((char *) EX(CVs) + CVs_size); + + + EX(op_array) = op_array; + + EG(argument_stack)->top = zend_vm_stack_frame_base(execute_data); - EX(fbc) = NULL; - EX(called_scope) = NULL; EX(object) = NULL; + EX(current_this) = NULL; EX(old_error_reporting) = NULL; - EX(op_array) = op_array; EX(symbol_table) = EG(active_symbol_table); - EX(prev_execute_data) = EG(current_execute_data); + EX(call) = NULL; EG(current_execute_data) = execute_data; EX(nested) = nested; @@ -103,12 +183,12 @@ ZEND_API void {%EXECUTOR_NAME%}_ex(zend_execute_data *execute_data TSRMLS_DC) zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); } -ZEND_API void {%EXECUTOR_NAME%}(zend_op_array *op_array TSRMLS_DC) +ZEND_API void zend_{%EXECUTOR_NAME%}(zend_op_array *op_array TSRMLS_DC) { if (EG(exception)) { return; } - {%EXECUTOR_NAME%}_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); + zend_{%EXECUTOR_NAME%}_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } {%EXTERNAL_EXECUTOR%} diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 52f6cde59e71f..fcf7960b8e413 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -159,6 +159,7 @@ #define ZEND_SEPARATE 156 #define ZEND_QM_ASSIGN_VAR 157 #define ZEND_JMP_SET_VAR 158 +#define ZEND_GENERATOR_FLAG 159 #define ZEND_YIELD 160 #define ZEND_GENERATOR_RETURN 161 #define ZEND_FAST_CALL 162 From 66b8ece02a9592fb70d1ca2990614004858c4e8b Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Fri, 30 Nov 2012 14:14:36 +0400 Subject: [PATCH 2180/2394] Fixed bug #63066 (Calling an undefined method in a generator results in a seg fault) (fixed with previous commit). --- Zend/tests/generators/bug63066.phpt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 Zend/tests/generators/bug63066.phpt diff --git a/Zend/tests/generators/bug63066.phpt b/Zend/tests/generators/bug63066.phpt new file mode 100644 index 0000000000000..8c4c8b4a84d3a --- /dev/null +++ b/Zend/tests/generators/bug63066.phpt @@ -0,0 +1,16 @@ +--TEST-- +Bug #63066 (Calling an undefined method in a generator results in a seg fault) +--FILE-- +fatalError(); +} + +foreach(gen(new stdClass()) as $value) + echo $value, "\n"; +--EXPECTF-- +foo + +Fatal error: Call to undefined method stdClass::fatalError() in %sbug63066.php on line 5 From 5db372fbdc30005d831d1ef197aeb6a553177197 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 30 Nov 2012 09:07:35 -0200 Subject: [PATCH 2181/2394] - Fixed ZTS build --- Zend/zend_generators.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 493e99dd0eb86..4450374486c3f 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -150,7 +150,7 @@ static void zend_generator_free_storage(zend_generator *generator TSRMLS_DC) /* } /* }}} */ -static void zend_generator_clone_storage(zend_generator *orig, zend_generator **clone_ptr) /* {{{ */ +static void zend_generator_clone_storage(zend_generator *orig, zend_generator **clone_ptr TSRMLS_DC) /* {{{ */ { zend_generator *clone = emalloc(sizeof(zend_generator)); memcpy(clone, orig, sizeof(zend_generator)); From 869e6508b3489f25c78d51ef335edda0b052e135 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 3 Dec 2012 13:35:26 +0100 Subject: [PATCH 2182/2394] use php_stream_copy_to_stream_ex instead of deprecated php_stream_copy_to_stream --- ext/dba/libinifile/inifile.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/dba/libinifile/inifile.c b/ext/dba/libinifile/inifile.c index cd53f4adf0f7f..a0c7c69e58d93 100644 --- a/ext/dba/libinifile/inifile.c +++ b/ext/dba/libinifile/inifile.c @@ -402,7 +402,7 @@ static int inifile_copy_to(inifile *dba, size_t pos_start, size_t pos_end, inifi return FAILURE; } php_stream_seek(dba->fp, pos_start, SEEK_SET); - if (!php_stream_copy_to_stream(dba->fp, fp, pos_end - pos_start)) { + if (!php_stream_copy_to_stream_ex(dba->fp, fp, pos_end - pos_start, NULL)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy group [%zu - %zu] to temporary stream", pos_start, pos_end); return FAILURE; } @@ -427,7 +427,7 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML pos_curr = php_stream_tell(from->fp); if (pos_start != pos_next) { php_stream_seek(from->fp, pos_start, SEEK_SET); - if (!php_stream_copy_to_stream(from->fp, dba->fp, pos_next - pos_start)) { + if (!php_stream_copy_to_stream_ex(from->fp, dba->fp, pos_next - pos_start, NULL)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy [%zu - %zu] from temporary stream", pos_next, pos_start); ret = FAILURE; } @@ -446,7 +446,7 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML } if (pos_start != pos_next) { php_stream_seek(from->fp, pos_start, SEEK_SET); - if (!php_stream_copy_to_stream(from->fp, dba->fp, pos_next - pos_start)) { + if (!php_stream_copy_to_stream_ex(from->fp, dba->fp, pos_next - pos_start, NULL)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy [%zu - %zu] from temporary stream", pos_next, pos_start); ret = FAILURE; } @@ -497,7 +497,7 @@ static int inifile_delete_replace_append(inifile *dba, const key_type *key, cons php_stream_seek(dba->fp, 0, SEEK_END); if (pos_grp_next != (size_t)php_stream_tell(dba->fp)) { php_stream_seek(dba->fp, pos_grp_next, SEEK_SET); - if (!php_stream_copy_to_stream(dba->fp, fp_tmp, PHP_STREAM_COPY_ALL)) { + if (!php_stream_copy_to_stream_ex(dba->fp, fp_tmp, PHP_STREAM_COPY_ALL, NULL)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not copy remainder to temporary stream"); ret = FAILURE; } @@ -538,7 +538,7 @@ static int inifile_delete_replace_append(inifile *dba, const key_type *key, cons if (fp_tmp && php_stream_tell(fp_tmp)) { php_stream_seek(fp_tmp, 0, SEEK_SET); php_stream_seek(dba->fp, 0, SEEK_END); - if (!php_stream_copy_to_stream(fp_tmp, dba->fp, PHP_STREAM_COPY_ALL)) { + if (!php_stream_copy_to_stream_ex(fp_tmp, dba->fp, PHP_STREAM_COPY_ALL, NULL)) { php_error_docref(NULL TSRMLS_CC, E_RECOVERABLE_ERROR, "Could not copy from temporary stream - ini file truncated"); ret = FAILURE; } From e3aad69cccfed957f1ba01a0083aac2fb7174338 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 3 Dec 2012 13:38:12 +0100 Subject: [PATCH 2183/2394] Fix inifile.c:419:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] Please check this minor change. Avoid, warning: 'pos_grp_start' may be used uninitialized in this function [-Wmaybe-uninitialized] --- ext/dba/libinifile/inifile.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/dba/libinifile/inifile.c b/ext/dba/libinifile/inifile.c index a0c7c69e58d93..b94c49b61d381 100644 --- a/ext/dba/libinifile/inifile.c +++ b/ext/dba/libinifile/inifile.c @@ -452,7 +452,7 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML } } inifile_line_free(&ln); - return SUCCESS; + return ret; } /* }}} */ @@ -460,7 +460,7 @@ static int inifile_filter(inifile *dba, inifile *from, const key_type *key TSRML */ static int inifile_delete_replace_append(inifile *dba, const key_type *key, const val_type *value, int append TSRMLS_DC) { - size_t pos_grp_start, pos_grp_next; + size_t pos_grp_start=0, pos_grp_next; inifile *ini_tmp = NULL; php_stream *fp_tmp = NULL; int ret; From 784850211ed9e0bd50c2dac6e26746c0e9a347b7 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 3 Dec 2012 15:32:52 +0100 Subject: [PATCH 2184/2394] Reduce case where this test will fails: - no connection AND no mysqli extension So, will succeed when no configured connection, but mysqli available. --- ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt index 2545307cfbc3c..e52e4b54e7cba 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt @@ -29,7 +29,8 @@ require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'skipif.inc'); $expected['MYSQL_ATTR_READ_DEFAULT_GROUP'] = true; } - if (extension_loaded('mysqli') && stristr(mysqli_get_client_info(), "mysqlnd") + if (extension_loaded('mysqli') + && (stristr(mysqli_get_client_info(), "mysqlnd") || mysqli_get_client_version() > 50605) || MySQLPDOTest::getClientVersion(MySQLPDOTest::factory()) > 50605) { /* XXX the MySQL client library version isn't exposed with any constants, the single possibility is to use the PDO::getAttribute(). From 7651d64556ebe223261c73325620c9d4b8d68aff Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 4 Dec 2012 10:14:39 +0400 Subject: [PATCH 2185/2394] Optimized access to temporary and compiled VM variables --- NEWS | 2 + UPGRADING | 11 + Zend/zend_compile.c | 2 +- Zend/zend_compile.h | 7 +- Zend/zend_execute.c | 129 +- Zend/zend_execute.h | 6 +- Zend/zend_execute_API.c | 18 +- Zend/zend_generators.c | 32 +- Zend/zend_vm_def.h | 36 +- Zend/zend_vm_execute.h | 2521 +++++++++++++++++++------------------- Zend/zend_vm_execute.skl | 34 +- Zend/zend_vm_gen.php | 98 +- 12 files changed, 1429 insertions(+), 1467 deletions(-) diff --git a/NEWS b/NEWS index 350729c3ec4e9..d8646f1684f2d 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,8 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Optimized access to temporary and compiled VM variables. 8% less memory + reads. (Dmitry) . The VM stacks for passing function arguments and syntaticaly nested calls were merged into a single stack. The stack size needed for op_array execution is calculated at compile time and preallocated at once. As result diff --git a/UPGRADING b/UPGRADING index f8cb6fa2ed933..170c6de51da5b 100755 --- a/UPGRADING +++ b/UPGRADING @@ -48,6 +48,17 @@ PHP 5.5 UPGRADE NOTES corresponding stack space is preallocated together with execute_data. ZEND_SEND* and ZEND_DO_FCALL* don't need to check for stack overflow anymore. +- Removed execute_data->Ts field. The VM temporary variables always allocated + immediately before execute_data structure. Now they are accessed by offset + from the execute_data base pointer (instead of execute_data->Ts). Compiler + stores new offsets in op_array->opcodes[*].op?.num. You can use macros + EX_TMP_VAR() and EX_TMP_VAR_NUM() to access temp_variable by offset or + number. You can convert number to offset using EX_TMP_VAR_NUM(0, num) or + offset to number (EX_TMP_VAR(0,offset)-EX_TMP_VAR_NUM(0,0)). +- Removed execute_data->CVs field. The VM compiled variables always allocated + immediately after execute_data structure. Now they are accessed by offset + from the execute_data base pointer (instead of execute_data->CVs). You can + use macros EX_CV_NUM() to access compiled variables by number. ======================================== 2. New Features diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index e768996272b79..109949a40c097 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -287,7 +287,7 @@ ZEND_API zend_bool zend_is_compiling(TSRMLS_D) /* {{{ */ static zend_uint get_temporary_variable(zend_op_array *op_array) /* {{{ */ { - return (op_array->T)++ * ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)); + return EX_TMP_VAR_NUM(0, (op_array->T)++); } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index def634175a8d1..da0a49bd511f5 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -387,8 +387,6 @@ struct _zend_execute_data { zend_function_state function_state; zend_op_array *op_array; zval *object; - union _temp_variable *Ts; - zval ***CVs; HashTable *symbol_table; struct _zend_execute_data *prev_execute_data; zval *old_error_reporting; @@ -404,6 +402,11 @@ struct _zend_execute_data { #define EX(element) execute_data.element +#define EX_TMP_VAR(ex, n) ((temp_variable*)(((char*)(ex)) + ((int)(n)))) +#define EX_TMP_VAR_NUM(ex, n) (EX_TMP_VAR(ex, 0) - (1 + (n))) + +#define EX_CV_NUM(ex, n) (((zval***)(((char*)(ex))+ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data))))+(n)) + #define IS_CONST (1<<0) #define IS_TMP_VAR (1<<1) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 5f04ba7465e36..e5198ebfcb7cc 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -50,10 +50,10 @@ typedef int (*incdec_t)(zval *); -#define get_zval_ptr(op_type, node, Ts, should_free, type) _get_zval_ptr(op_type, node, Ts, should_free, type TSRMLS_CC) -#define get_zval_ptr_ptr(op_type, node, Ts, should_free, type) _get_zval_ptr_ptr(op_type, node, Ts, should_free, type TSRMLS_CC) -#define get_obj_zval_ptr(op_type, node, Ts, should_free, type) _get_obj_zval_ptr(op_type, node, Ts, should_free, type TSRMLS_CC) -#define get_obj_zval_ptr_ptr(op_type, node, Ts, should_free, type) _get_obj_zval_ptr_ptr(op_type, node, Ts, should_free, type TSRMLS_CC) +#define get_zval_ptr(op_type, node, ex, should_free, type) _get_zval_ptr(op_type, node, ex, should_free, type TSRMLS_CC) +#define get_zval_ptr_ptr(op_type, node, ex, should_free, type) _get_zval_ptr_ptr(op_type, node, ex, should_free, type TSRMLS_CC) +#define get_obj_zval_ptr(op_type, node, ex, should_free, type) _get_obj_zval_ptr(op_type, node, ex, should_free, type TSRMLS_CC) +#define get_obj_zval_ptr_ptr(op_type, node, ex, should_free, type) _get_obj_zval_ptr_ptr(op_type, node, ex, should_free, type TSRMLS_CC) /* Prototypes */ static void zend_extension_statement_handler(const zend_extension *extension, zend_op_array *op_array TSRMLS_DC); @@ -62,8 +62,8 @@ static void zend_extension_fcall_end_handler(const zend_extension *extension, ze #define RETURN_VALUE_USED(opline) (!((opline)->result_type & EXT_TYPE_UNUSED)) -#define T(offset) (*(temp_variable *)((char *) Ts + offset)) -#define CV(var) CVs[var] +#define EX_T(offset) (*EX_TMP_VAR(execute_data, offset)) +#define EX_CV(var) (*EX_CV_NUM(execute_data, var)) #define TEMP_VAR_STACK_LIMIT 2000 @@ -154,7 +154,6 @@ static zend_always_inline void zend_pzval_unlock_free_func(zval *z TSRMLS_DC) /* End of zend_execute_locks.h */ -#define CV_OF(i) (EG(current_execute_data)->CVs[i]) #define CV_DEF_OF(i) (EG(active_op_array)->vars[i]) #define CTOR_CALL_BIT 0x1 @@ -168,19 +167,19 @@ static zend_always_inline void zend_pzval_unlock_free_func(zval *z TSRMLS_DC) #define DECODE_CTOR(ce) \ ((zend_class_entry*)(((zend_uintptr_t)(ce)) & ~(CTOR_CALL_BIT|CTOR_USED_BIT))) -ZEND_API zval** zend_get_compiled_variable_value(const zend_execute_data *execute_data_ptr, zend_uint var) +ZEND_API zval** zend_get_compiled_variable_value(const zend_execute_data *execute_data, zend_uint var) { - return execute_data_ptr->CVs[var]; + return EX_CV(var); } -static zend_always_inline zval *_get_zval_ptr_tmp(zend_uint var, const temp_variable *Ts, zend_free_op *should_free TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_tmp(zend_uint var, const zend_execute_data *execute_data, zend_free_op *should_free TSRMLS_DC) { - return should_free->var = &T(var).tmp_var; + return should_free->var = &EX_T(var).tmp_var; } -static zend_always_inline zval *_get_zval_ptr_var(zend_uint var, const temp_variable *Ts, zend_free_op *should_free TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_var(zend_uint var, const zend_execute_data *execute_data, zend_free_op *should_free TSRMLS_DC) { - zval *ptr = T(var).var.ptr; + zval *ptr = EX_T(var).var.ptr; PZVAL_UNLOCK(ptr, should_free); return ptr; @@ -206,7 +205,7 @@ static zend_never_inline zval **_get_zval_cv_lookup(zval ***ptr, zend_uint var, case BP_VAR_W: Z_ADDREF(EG(uninitialized_zval)); if (!EG(active_symbol_table)) { - *ptr = (zval**)EG(current_execute_data)->CVs + (EG(active_op_array)->last_var + var); + *ptr = (zval**)EX_CV_NUM(EG(current_execute_data), EG(active_op_array)->last_var + var); **ptr = &EG(uninitialized_zval); } else { zend_hash_quick_update(EG(active_symbol_table), cv->name, cv->name_len+1, cv->hash_value, &EG(uninitialized_zval_ptr), sizeof(zval *), (void **)ptr); @@ -258,7 +257,7 @@ static zend_never_inline zval **_get_zval_cv_lookup_BP_VAR_RW(zval ***ptr, zend_ if (!EG(active_symbol_table)) { Z_ADDREF(EG(uninitialized_zval)); - *ptr = (zval**)EG(current_execute_data)->CVs + (EG(active_op_array)->last_var + var); + *ptr = (zval**)EX_CV_NUM(EG(current_execute_data), EG(active_op_array)->last_var + var); **ptr = &EG(uninitialized_zval); zend_error(E_NOTICE, "Undefined variable: %s", cv->name); } else if (zend_hash_quick_find(EG(active_symbol_table), cv->name, cv->name_len+1, cv->hash_value, (void **)ptr)==FAILURE) { @@ -275,7 +274,7 @@ static zend_never_inline zval **_get_zval_cv_lookup_BP_VAR_W(zval ***ptr, zend_u if (!EG(active_symbol_table)) { Z_ADDREF(EG(uninitialized_zval)); - *ptr = (zval**)EG(current_execute_data)->CVs + (EG(active_op_array)->last_var + var); + *ptr = (zval**)EX_CV_NUM(EG(current_execute_data), EG(active_op_array)->last_var + var); **ptr = &EG(uninitialized_zval); } else if (zend_hash_quick_find(EG(active_symbol_table), cv->name, cv->name_len+1, cv->hash_value, (void **)ptr)==FAILURE) { Z_ADDREF(EG(uninitialized_zval)); @@ -286,7 +285,7 @@ static zend_never_inline zval **_get_zval_cv_lookup_BP_VAR_W(zval ***ptr, zend_u static zend_always_inline zval *_get_zval_ptr_cv(zend_uint var, int type TSRMLS_DC) { - zval ***ptr = &CV_OF(var); + zval ***ptr = EX_CV_NUM(EG(current_execute_data), var); if (UNEXPECTED(*ptr == NULL)) { return *_get_zval_cv_lookup(ptr, var, type TSRMLS_CC); @@ -294,9 +293,9 @@ static zend_always_inline zval *_get_zval_ptr_cv(zend_uint var, int type TSRMLS_ return **ptr; } -static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_R(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_R(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return *_get_zval_cv_lookup_BP_VAR_R(ptr, var TSRMLS_CC); @@ -304,9 +303,9 @@ static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_R(zval ***CVs, zend_uint return **ptr; } -static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_UNSET(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_UNSET(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return *_get_zval_cv_lookup_BP_VAR_UNSET(ptr, var TSRMLS_CC); @@ -314,9 +313,9 @@ static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_UNSET(zval ***CVs, zend_ return **ptr; } -static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_IS(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_IS(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return *_get_zval_cv_lookup_BP_VAR_IS(ptr, var TSRMLS_CC); @@ -324,9 +323,9 @@ static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_IS(zval ***CVs, zend_uin return **ptr; } -static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_RW(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_RW(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return *_get_zval_cv_lookup_BP_VAR_RW(ptr, var TSRMLS_CC); @@ -334,9 +333,9 @@ static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_RW(zval ***CVs, zend_uin return **ptr; } -static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_W(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_W(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return *_get_zval_cv_lookup_BP_VAR_W(ptr, var TSRMLS_CC); @@ -344,7 +343,7 @@ static zend_always_inline zval *_get_zval_ptr_cv_BP_VAR_W(zval ***CVs, zend_uint return **ptr; } -static inline zval *_get_zval_ptr(int op_type, const znode_op *node, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC) +static inline zval *_get_zval_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { /* should_free->is_var = 0; */ switch (op_type) { @@ -353,11 +352,11 @@ static inline zval *_get_zval_ptr(int op_type, const znode_op *node, const temp_ return node->zv; break; case IS_TMP_VAR: - should_free->var = TMP_FREE(&T(node->var).tmp_var); - return &T(node->var).tmp_var; + should_free->var = TMP_FREE(&EX_T(node->var).tmp_var); + return &EX_T(node->var).tmp_var; break; case IS_VAR: - return _get_zval_ptr_var(node->var, Ts, should_free TSRMLS_CC); + return _get_zval_ptr_var(node->var, execute_data, should_free TSRMLS_CC); break; case IS_UNUSED: should_free->var = 0; @@ -372,22 +371,22 @@ static inline zval *_get_zval_ptr(int op_type, const znode_op *node, const temp_ return NULL; } -static zend_always_inline zval **_get_zval_ptr_ptr_var(zend_uint var, const temp_variable *Ts, zend_free_op *should_free TSRMLS_DC) +static zend_always_inline zval **_get_zval_ptr_ptr_var(zend_uint var, const zend_execute_data *execute_data, zend_free_op *should_free TSRMLS_DC) { - zval** ptr_ptr = T(var).var.ptr_ptr; + zval** ptr_ptr = EX_T(var).var.ptr_ptr; if (EXPECTED(ptr_ptr != NULL)) { PZVAL_UNLOCK(*ptr_ptr, should_free); } else { /* string offset */ - PZVAL_UNLOCK(T(var).str_offset.str, should_free); + PZVAL_UNLOCK(EX_T(var).str_offset.str, should_free); } return ptr_ptr; } static zend_always_inline zval **_get_zval_ptr_ptr_cv(zend_uint var, int type TSRMLS_DC) { - zval ***ptr = &CV_OF(var); + zval ***ptr = EX_CV_NUM(EG(current_execute_data), var); if (UNEXPECTED(*ptr == NULL)) { return _get_zval_cv_lookup(ptr, var, type TSRMLS_CC); @@ -395,9 +394,9 @@ static zend_always_inline zval **_get_zval_ptr_ptr_cv(zend_uint var, int type TS return *ptr; } -static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_R(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_R(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return _get_zval_cv_lookup_BP_VAR_R(ptr, var TSRMLS_CC); @@ -405,9 +404,9 @@ static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_R(zval ***CVs, zend return *ptr; } -static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_UNSET(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_UNSET(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return _get_zval_cv_lookup_BP_VAR_UNSET(ptr, var TSRMLS_CC); @@ -415,9 +414,9 @@ static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_UNSET(zval ***CVs, return *ptr; } -static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_IS(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_IS(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return _get_zval_cv_lookup_BP_VAR_IS(ptr, var TSRMLS_CC); @@ -425,9 +424,9 @@ static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_IS(zval ***CVs, zen return *ptr; } -static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_RW(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_RW(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return _get_zval_cv_lookup_BP_VAR_RW(ptr, var TSRMLS_CC); @@ -435,9 +434,9 @@ static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_RW(zval ***CVs, zen return *ptr; } -static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_W(zval ***CVs, zend_uint var TSRMLS_DC) +static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_W(const zend_execute_data *execute_data, zend_uint var TSRMLS_DC) { - zval ***ptr = &CV(var); + zval ***ptr = EX_CV_NUM(execute_data, var); if (UNEXPECTED(*ptr == NULL)) { return _get_zval_cv_lookup_BP_VAR_W(ptr, var TSRMLS_CC); @@ -445,13 +444,13 @@ static zend_always_inline zval **_get_zval_ptr_ptr_cv_BP_VAR_W(zval ***CVs, zend return *ptr; } -static inline zval **_get_zval_ptr_ptr(int op_type, const znode_op *node, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC) +static inline zval **_get_zval_ptr_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { if (op_type == IS_CV) { should_free->var = 0; return _get_zval_ptr_ptr_cv(node->var, type TSRMLS_CC); } else if (op_type == IS_VAR) { - return _get_zval_ptr_ptr_var(node->var, Ts, should_free TSRMLS_CC); + return _get_zval_ptr_ptr_var(node->var, execute_data, should_free TSRMLS_CC); } else { should_free->var = 0; return NULL; @@ -468,7 +467,7 @@ static zend_always_inline zval *_get_obj_zval_ptr_unused(TSRMLS_D) } } -static inline zval **_get_obj_zval_ptr_ptr(int op_type, const znode_op *op, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC) +static inline zval **_get_obj_zval_ptr_ptr(int op_type, const znode_op *op, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { if (op_type == IS_UNUSED) { if (EXPECTED(EG(This) != NULL)) { @@ -480,7 +479,7 @@ static inline zval **_get_obj_zval_ptr_ptr(int op_type, const znode_op *op, cons zend_error_noreturn(E_ERROR, "Using $this when not in object context"); } } - return get_zval_ptr_ptr(op_type, op, Ts, should_free, type); + return get_zval_ptr_ptr(op_type, op, execute_data, should_free, type); } static zend_always_inline zval **_get_obj_zval_ptr_ptr_unused(TSRMLS_D) @@ -493,7 +492,7 @@ static zend_always_inline zval **_get_obj_zval_ptr_ptr_unused(TSRMLS_D) } } -static inline zval *_get_obj_zval_ptr(int op_type, znode_op *op, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC) +static inline zval *_get_obj_zval_ptr(int op_type, znode_op *op, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { if (op_type == IS_UNUSED) { if (EXPECTED(EG(This) != NULL)) { @@ -503,7 +502,7 @@ static inline zval *_get_obj_zval_ptr(int op_type, znode_op *op, const temp_vari zend_error_noreturn(E_ERROR, "Using $this when not in object context"); } } - return get_zval_ptr(op_type, op, Ts, should_free, type); + return get_zval_ptr(op_type, op, execute_data, should_free, type); } static void zend_assign_to_variable_reference(zval **variable_ptr_ptr, zval **value_ptr_ptr TSRMLS_DC) @@ -654,11 +653,11 @@ static inline int zend_verify_arg_type(zend_function *zf, zend_uint arg_num, zva return 1; } -static inline void zend_assign_to_object(zval **retval, zval **object_ptr, zval *property_name, int value_type, znode_op *value_op, const temp_variable *Ts, int opcode, const zend_literal *key TSRMLS_DC) +static inline void zend_assign_to_object(zval **retval, zval **object_ptr, zval *property_name, int value_type, znode_op *value_op, const zend_execute_data *execute_data, int opcode, const zend_literal *key TSRMLS_DC) { zval *object = *object_ptr; zend_free_op free_value; - zval *value = get_zval_ptr(value_type, value_op, Ts, &free_value, BP_VAR_R); + zval *value = get_zval_ptr(value_type, value_op, execute_data, &free_value, BP_VAR_R); if (Z_TYPE_P(object) != IS_OBJECT) { if (object == &EG(error_zval)) { @@ -1410,7 +1409,7 @@ static void zend_fetch_property_address(temp_variable *result, zval **container_ } } -static inline zend_brk_cont_element* zend_brk_cont(int nest_levels, int array_offset, const zend_op_array *op_array, const temp_variable *Ts TSRMLS_DC) +static inline zend_brk_cont_element* zend_brk_cont(int nest_levels, int array_offset, const zend_op_array *op_array, const zend_execute_data *execute_data TSRMLS_DC) { int original_nest_levels = nest_levels; zend_brk_cont_element *jmp_to; @@ -1426,12 +1425,12 @@ static inline zend_brk_cont_element* zend_brk_cont(int nest_levels, int array_of switch (brk_opline->opcode) { case ZEND_SWITCH_FREE: if (!(brk_opline->extended_value & EXT_TYPE_FREE_ON_RETURN)) { - zval_ptr_dtor(&T(brk_opline->op1.var).var.ptr); + zval_ptr_dtor(&EX_T(brk_opline->op1.var).var.ptr); } break; case ZEND_FREE: if (!(brk_opline->extended_value & EXT_TYPE_FREE_ON_RETURN)) { - zendi_zval_dtor(T(brk_opline->op1.var).tmp_var); + zendi_zval_dtor(EX_T(brk_opline->op1.var).tmp_var); } break; } @@ -1482,7 +1481,7 @@ ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_i *fci->retval_ptr_ptr, fci->retval_ptr_ptr, fci->object_ptr, 1 TSRMLS_CC); } else { - zval **return_value_ptr = &(*(temp_variable *)((char *) execute_data_ptr->Ts + execute_data_ptr->opline->result.var)).var.ptr; + zval **return_value_ptr = &EX_TMP_VAR(execute_data_ptr, execute_data_ptr->opline->result.var)->var.ptr; ((zend_internal_function *) execute_data_ptr->function_state.function)->handler(execute_data_ptr->opline->extended_value, *return_value_ptr, (execute_data_ptr->function_state.function->common.fn_flags & ZEND_ACC_RETURN_REFERENCE)?return_value_ptr:NULL, execute_data_ptr->object, return_value_used TSRMLS_CC); @@ -1537,12 +1536,12 @@ ZEND_API user_opcode_handler_t zend_get_user_opcode_handler(zend_uchar opcode) return zend_user_opcode_handlers[opcode]; } -ZEND_API zval *zend_get_zval_ptr(int op_type, const znode_op *node, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC) { - return get_zval_ptr(op_type, node, Ts, should_free, type); +ZEND_API zval *zend_get_zval_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { + return get_zval_ptr(op_type, node, execute_data, should_free, type); } -ZEND_API zval **zend_get_zval_ptr_ptr(int op_type, const znode_op *node, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC) { - return get_zval_ptr_ptr(op_type, node, Ts, should_free, type); +ZEND_API zval **zend_get_zval_ptr_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { + return get_zval_ptr_ptr(op_type, node, execute_data, should_free, type); } void zend_clean_and_cache_symbol_table(HashTable *symbol_table TSRMLS_DC) /* {{{ */ @@ -1559,12 +1558,12 @@ void zend_clean_and_cache_symbol_table(HashTable *symbol_table TSRMLS_DC) /* {{{ } /* }}} */ -void zend_free_compiled_variables(zval ***CVs, int num) /* {{{ */ +void zend_free_compiled_variables(zend_execute_data *execute_data) /* {{{ */ { int i; - for (i = 0; i < num; ++i) { - if (CVs[i]) { - zval_ptr_dtor(CVs[i]); + for (i = 0; i < EX(op_array)->last_var; ++i) { + if (EX_CV(i)) { + zval_ptr_dtor(EX_CV(i)); } } } diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index fdd9f5697db13..963decde2a831 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -394,13 +394,13 @@ typedef struct _zend_free_op { /* int is_var; */ } zend_free_op; -ZEND_API zval *zend_get_zval_ptr(int op_type, const znode_op *node, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC); -ZEND_API zval **zend_get_zval_ptr_ptr(int op_type, const znode_op *node, const temp_variable *Ts, zend_free_op *should_free, int type TSRMLS_DC); +ZEND_API zval *zend_get_zval_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC); +ZEND_API zval **zend_get_zval_ptr_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC); ZEND_API int zend_do_fcall(ZEND_OPCODE_HANDLER_ARGS); void zend_clean_and_cache_symbol_table(HashTable *symbol_table TSRMLS_DC); -void zend_free_compiled_variables(zval ***CVs, int num); +void zend_free_compiled_variables(zend_execute_data *execute_data); #define CACHED_PTR(num) \ EG(active_op_array)->run_time_cache[(num)] diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 3df0ca2396788..4a635b230d9d1 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -1689,7 +1689,7 @@ ZEND_API void zend_reset_all_cv(HashTable *symbol_table TSRMLS_DC) /* {{{ */ for (ex = EG(current_execute_data); ex; ex = ex->prev_execute_data) { if (ex->op_array && ex->symbol_table == symbol_table) { for (i = 0; i < ex->op_array->last_var; i++) { - ex->CVs[i] = NULL; + *EX_CV_NUM(ex, i) = NULL; } } } @@ -1708,7 +1708,7 @@ ZEND_API void zend_delete_variable(zend_execute_data *ex, HashTable *ht, const c if (ex->op_array->vars[i].hash_value == hash_value && ex->op_array->vars[i].name_len == name_len && !memcmp(ex->op_array->vars[i].name, name, name_len)) { - ex->CVs[i] = NULL; + *EX_CV_NUM(ex, i) = NULL; break; } } @@ -1732,7 +1732,7 @@ ZEND_API int zend_delete_global_variable_ex(const char *name, int name_len, ulon ex->op_array->vars[i].name_len == name_len && !memcmp(ex->op_array->vars[i].name, name, name_len) ) { - ex->CVs[i] = NULL; + *EX_CV_NUM(ex, i) = NULL; break; } } @@ -1779,20 +1779,20 @@ ZEND_API void zend_rebuild_symbol_table(TSRMLS_D) /* {{{ */ ex->symbol_table = EG(active_symbol_table); if (ex->op_array->this_var != -1 && - !ex->CVs[ex->op_array->this_var] && + !*EX_CV_NUM(ex, ex->op_array->this_var) && EG(This)) { - ex->CVs[ex->op_array->this_var] = (zval**)ex->CVs + ex->op_array->last_var + ex->op_array->this_var; - *ex->CVs[ex->op_array->this_var] = EG(This); + *EX_CV_NUM(ex, ex->op_array->this_var) = (zval**)EX_CV_NUM(ex, ex->op_array->last_var + ex->op_array->this_var); + **EX_CV_NUM(ex, ex->op_array->this_var) = EG(This); } for (i = 0; i < ex->op_array->last_var; i++) { - if (ex->CVs[i]) { + if (*EX_CV_NUM(ex, i)) { zend_hash_quick_update(EG(active_symbol_table), ex->op_array->vars[i].name, ex->op_array->vars[i].name_len + 1, ex->op_array->vars[i].hash_value, - (void**)ex->CVs[i], + (void**)*EX_CV_NUM(ex, i), sizeof(zval*), - (void**)&ex->CVs[i]); + (void**)EX_CV_NUM(ex, i)); } } } diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 4450374486c3f..dc7ae1479b41e 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -35,7 +35,7 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio void **stack_frame; if (!execute_data->symbol_table) { - zend_free_compiled_variables(execute_data->CVs, op_array->last_var); + zend_free_compiled_variables(execute_data); } else { zend_clean_and_cache_symbol_table(execute_data->symbol_table TSRMLS_CC); } @@ -66,13 +66,13 @@ void zend_generator_close(zend_generator *generator, zend_bool finished_executio switch (brk_opline->opcode) { case ZEND_SWITCH_FREE: { - temp_variable *var = (temp_variable *) ((char *) execute_data->Ts + brk_opline->op1.var); + temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var); zval_ptr_dtor(&var->var.ptr); } break; case ZEND_FREE: { - temp_variable *var = (temp_variable *) ((char *) execute_data->Ts + brk_opline->op1.var); + temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var); zval_dtor(&var->tmp_var); } break; @@ -198,10 +198,10 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** /* Copy compiled variables */ for (i = 0; i < op_array->last_var; i++) { - if (execute_data->CVs[i]) { - clone->execute_data->CVs[i] = (zval **) clone->execute_data->CVs + op_array->last_var + i; - *clone->execute_data->CVs[i] = (zval *) execute_data->CVs[op_array->last_var + i]; - Z_ADDREF_PP(clone->execute_data->CVs[i]); + if (*EX_CV_NUM(execute_data, i)) { + *EX_CV_NUM(clone->execute_data, i) = (zval **) EX_CV_NUM(clone->execute_data, op_array->last_var + i); + **EX_CV_NUM(clone->execute_data, i) = *(zval **) EX_CV_NUM(execute_data, op_array->last_var + i); + Z_ADDREF_PP(*EX_CV_NUM(clone->execute_data, i)); } } } else { @@ -214,8 +214,8 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** { int i; for (i = 0; i < op_array->last_var; i++) { - if (zend_hash_quick_find(clone->execute_data->symbol_table, op_array->vars[i].name, op_array->vars[i].name_len + 1, op_array->vars[i].hash_value, (void **) &clone->execute_data->CVs[i]) == FAILURE) { - clone->execute_data->CVs[i] = NULL; + if (zend_hash_quick_find(clone->execute_data->symbol_table, op_array->vars[i].name, op_array->vars[i].name_len + 1, op_array->vars[i].hash_value, (void **) EX_CV_NUM(clone->execute_data, i)) == FAILURE) { + *EX_CV_NUM(clone->execute_data, i) = NULL; } } } @@ -228,7 +228,7 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** } else { clone->execute_data->call = NULL; } - memcpy(clone->execute_data->call_slots, execute_data->call_slots, sizeof(call_slot) * op_array->nested_calls); + memcpy(clone->execute_data->call_slots, execute_data->call_slots, ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * op_array->nested_calls); if (clone->execute_data->call >= clone->execute_data->call_slots) { call_slot *call = clone->execute_data->call; @@ -241,14 +241,14 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** } /* Copy the temporary variables */ - memcpy(clone->execute_data->Ts, execute_data->Ts, sizeof(temp_variable) * op_array->T); + memcpy(EX_TMP_VAR_NUM(clone->execute_data, op_array->T-1), EX_TMP_VAR_NUM(execute_data, op_array->T-1), ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T); /* Copy arguments passed on stack */ stack_frame = zend_vm_stack_frame_base(clone->execute_data); orig_stack_frame = zend_vm_stack_frame_base(execute_data); clone->stack->top = stack_frame + (orig->stack->top - orig_stack_frame); if (clone->stack->top != stack_frame) { - memcpy(stack_frame, orig_stack_frame, sizeof(zval*) * (orig->stack->top - orig_stack_frame)); + memcpy(stack_frame, orig_stack_frame, ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (orig->stack->top - orig_stack_frame)); while (clone->stack->top != stack_frame) { Z_ADDREF_PP((zval**)stack_frame); stack_frame++; @@ -271,7 +271,7 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** zend_op *brk_opline = op_array->opcodes + brk_cont->brk; if (brk_opline->opcode == ZEND_SWITCH_FREE) { - temp_variable *var = (temp_variable *) ((char *) execute_data->Ts + brk_opline->op1.var); + temp_variable *var = EX_TMP_VAR(execute_data, brk_opline->op1.var); Z_ADDREF_P(var->var.ptr); } @@ -283,10 +283,8 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** * offset as the original generator, but in our temporary variable * memory segment. */ if (orig->send_target) { - size_t offset = (char *) orig->send_target - (char *) execute_data->Ts; - clone->send_target = (temp_variable *) ( - (char *) clone->execute_data->Ts + offset - ); + size_t offset = (char *) orig->send_target - (char *)execute_data; + clone->send_target = EX_TMP_VAR(clone->execute_data, offset); Z_ADDREF_P(clone->send_target->var.ptr); } diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 966827d5b4b5b..c309ca05def52 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -334,7 +334,7 @@ ZEND_VM_HELPER_EX(zend_binary_assign_op_obj_helper, VAR|UNUSED|CV, CONST|TMP|VAR zval **object_ptr = GET_OP1_OBJ_ZVAL_PTR_PTR(BP_VAR_RW); zval *object; zval *property = GET_OP2_ZVAL_PTR(BP_VAR_R); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (OP1_TYPE == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -465,8 +465,8 @@ ZEND_VM_HELPER_EX(zend_binary_assign_op_helper, VAR|UNUSED|CV, CONST|TMP|VAR|UNU zval *dim = GET_OP2_ZVAL_PTR(BP_VAR_R); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, OP2_TYPE, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; @@ -1636,7 +1636,7 @@ ZEND_VM_HANDLER(136, ZEND_ASSIGN_OBJ, VAR|UNUSED|CV, CONST|TMP|VAR|CV) if (OP1_TYPE == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((OP2_TYPE == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((OP2_TYPE == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (IS_OP2_TMP_FREE()) { zval_ptr_dtor(&property_name); } else { @@ -1668,7 +1668,7 @@ ZEND_VM_HANDLER(147, ZEND_ASSIGN_DIM, VAR|CV, CONST|TMP|VAR|UNUSED|CV) if (IS_OP2_TMP_FREE()) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((OP2_TYPE == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((OP2_TYPE == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (IS_OP2_TMP_FREE()) { zval_ptr_dtor(&property_name); } else { @@ -1683,8 +1683,8 @@ ZEND_VM_HANDLER(147, ZEND_ASSIGN_DIM, VAR|CV, CONST|TMP|VAR|UNUSED|CV) zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, OP2_TYPE, BP_VAR_W TSRMLS_CC); FREE_OP2(); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -1866,7 +1866,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { - zend_free_compiled_variables(EX_CVs(), op_array->last_var); + zend_free_compiled_variables(execute_data); } if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { @@ -1875,7 +1875,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) nested = EX(nested); - zend_vm_stack_free(execute_data TSRMLS_CC); + zend_vm_stack_free((char*)execute_data - (ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T) TSRMLS_CC); if (nested) { execute_data = EG(current_execute_data); @@ -2029,7 +2029,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) /* saves one function call if zend_execute_internal is not used */ fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); } else { - zend_execute_internal(EXECUTE_DATA, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC); + zend_execute_internal(execute_data, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC); } if (!RETURN_VALUE_USED(opline)) { @@ -3043,7 +3043,7 @@ ZEND_VM_HANDLER(107, ZEND_CATCH, CONST, CV) if (EX_CV(opline->op2.var)) { zval_ptr_dtor(EX_CV(opline->op2.var)); } - EX_CV(opline->op2.var) = (zval**)EX_CVs() + (EX(op_array)->last_var + opline->op2.var); + EX_CV(opline->op2.var) = (zval**)EX_CV_NUM(execute_data, EX(op_array)->last_var + opline->op2.var); *EX_CV(opline->op2.var) = EG(exception); } else { zend_compiled_variable *cv = &CV_DEF_OF(opline->op2.var); @@ -3245,7 +3245,7 @@ ZEND_VM_HANDLER(63, ZEND_RECV, ANY, ANY) zval **var_ptr; zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, *param, opline->extended_value TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->result.var TSRMLS_CC); Z_DELREF_PP(var_ptr); *var_ptr = *param; Z_ADDREF_PP(var_ptr); @@ -3281,7 +3281,7 @@ ZEND_VM_HANDLER(64, ZEND_RECV_INIT, ANY, CONST) } zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, assignment_value, opline->extended_value TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->result.var TSRMLS_CC); Z_DELREF_PP(var_ptr); *var_ptr = assignment_value; @@ -3311,7 +3311,7 @@ ZEND_VM_HANDLER(50, ZEND_BRK, ANY, CONST) SAVE_OPLINE(); el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, - EX(op_array), EX_Ts() TSRMLS_CC); + EX(op_array), execute_data TSRMLS_CC); FREE_OP2(); ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } @@ -3323,7 +3323,7 @@ ZEND_VM_HANDLER(51, ZEND_CONT, ANY, CONST) SAVE_OPLINE(); el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, - EX(op_array), EX_Ts() TSRMLS_CC); + EX(op_array), execute_data TSRMLS_CC); FREE_OP2(); ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } @@ -3336,7 +3336,7 @@ ZEND_VM_HANDLER(100, ZEND_GOTO, ANY, CONST) SAVE_OPLINE(); el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->extended_value, - EX(op_array), EX_Ts() TSRMLS_CC); + EX(op_array), execute_data TSRMLS_CC); brk_opline = EX(op_array)->opcodes + el->brk; @@ -3953,7 +3953,7 @@ ZEND_VM_HANDLER(74, ZEND_UNSET_VAR, CONST|TMP|VAR|CV, UNUSED|CONST|VAR) ulong hash_value = zend_inline_hash_func(varname->value.str.val, varname->value.str.len+1); target_symbol_table = zend_get_target_symbol_table(opline->extended_value & ZEND_FETCH_TYPE_MASK TSRMLS_CC); - zend_delete_variable(EXECUTE_DATA, target_symbol_table, varname->value.str.val, varname->value.str.len+1, hash_value TSRMLS_CC); + zend_delete_variable(execute_data, target_symbol_table, varname->value.str.val, varname->value.str.len+1, hash_value TSRMLS_CC); } if (OP1_TYPE != IS_CONST && varname == &tmp) { @@ -5035,7 +5035,7 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) /* Figure out where the next stack frame (which maybe contains pushed * arguments that have to be dtor'ed) starts */ - stack_frame = zend_vm_stack_frame_base(EXECUTE_DATA); + stack_frame = zend_vm_stack_frame_base(execute_data); /* If the exception was thrown during a function call there might be * arguments pushed to the stack that have to be dtor'ed. */ diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 921ece228bbce..eeb6a058efc94 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -329,15 +329,6 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #undef EX #define EX(element) execute_data->element -#undef EX_CV -#define EX_CV(var) EX(CVs)[var] -#undef EX_CVs -#define EX_CVs() EX(CVs) -#undef EX_T -#define EX_T(offset) (*(temp_variable *)((char *) EX(Ts) + offset)) -#undef EX_Ts -#define EX_Ts() EX(Ts) - /* * Stack Frame Layout (the whole stack frame is allocated at once) @@ -354,24 +345,24 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o * +========================================+ | * | * +========================================+ | + * | TMP_VAR[op_arrat->T-1] | | + * | ... | | + * EX_TMP_VAR_NUM(0) ----> | TMP_VAR[0] | | + * +----------------------------------------+ | * EG(current_execute_data) -> | zend_execute_data | | * | EX(prev_execute_data) |----+ * +----------------------------------------+ - * EX(Ts) ---------> | EX(Ts)[0] | - * | ... | - * | EX(Tx)[op_arrat->T] | - * +----------------------------------------+ - * EX(CVs) --------> | EX(CVs)[0] |--+ + * EX_CV_NUM(0) ---------> | CV[0] |--+ * | ... | | - * | EX(CVs)[op_array->last_var] | | + * | CV[op_array->last_var-1] | | * +----------------------------------------+ | * | Optional slot for CV[0] zval* |<-+ * | ... | - * | ... for CV [op_array->last_var] zval* | + * | ...for CV [op_array->last_var-1] zval* | * +----------------------------------------+ - * EX(call_slots) -> | EX(call_slots)[0] | + * EX(call_slots) -> | CALL_SLOT[0] | * | ... | - * | EX(call_slots)[op_array->nested_calls] | + * | CALL_SLOT[op_array->nested_calls-1] | * +----------------------------------------+ * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | * | ... | @@ -421,7 +412,7 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); EG(argument_stack)->prev = NULL; - execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size); + execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size + Ts_size); /* copy prev_execute_data */ EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); @@ -443,15 +434,13 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra } } else { execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); + execute_data = (zend_execute_data*)((char*)execute_data + Ts_size); EX(prev_execute_data) = EG(current_execute_data); } - EX(Ts) = (temp_variable *) ((char *) execute_data + execute_data_size); - - EX(CVs) = (zval ***) ((char *) EX(Ts) + Ts_size); - memset(EX(CVs), 0, sizeof(zval **) * op_array->last_var); + memset(EX_CV_NUM(execute_data, 0), 0, sizeof(zval **) * op_array->last_var); - EX(call_slots) = (call_slot*)((char *) EX(CVs) + CVs_size); + EX(call_slots) = (call_slot*)((char *)execute_data + execute_data_size + CVs_size); EX(op_array) = op_array; @@ -473,10 +462,10 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra if (op_array->this_var != -1 && EG(This)) { Z_ADDREF_P(EG(This)); /* For $this pointer */ if (!EG(active_symbol_table)) { - EX(CVs)[op_array->this_var] = (zval **) EX(CVs) + op_array->last_var + op_array->this_var; - *EX(CVs)[op_array->this_var] = EG(This); + EX_CV(op_array->this_var) = (zval **) EX_CV_NUM(execute_data, op_array->last_var + op_array->this_var); + *EX_CV(op_array->this_var) = EG(This); } else { - if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) &EX(CVs)[op_array->this_var])==FAILURE) { + if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) EX_CV_NUM(execute_data, op_array->this_var))==FAILURE) { Z_DELREF_P(EG(This)); } } @@ -566,7 +555,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { - zend_free_compiled_variables(EX_CVs(), op_array->last_var); + zend_free_compiled_variables(execute_data); } if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { @@ -575,7 +564,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) nested = EX(nested); - zend_vm_stack_free(execute_data TSRMLS_CC); + zend_vm_stack_free((char*)execute_data - (ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T) TSRMLS_CC); if (nested) { execute_data = EG(current_execute_data); @@ -898,7 +887,7 @@ static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval **var_ptr; zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, *param, opline->extended_value TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->result.var TSRMLS_CC); Z_DELREF_PP(var_ptr); *var_ptr = *param; Z_ADDREF_PP(var_ptr); @@ -1565,7 +1554,7 @@ static int ZEND_FASTCALL ZEND_RECV_INIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ } zend_verify_arg_type((zend_function *) EG(active_op_array), arg_num, assignment_value, opline->extended_value TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->result.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->result.var TSRMLS_CC); Z_DELREF_PP(var_ptr); *var_ptr = assignment_value; @@ -1580,7 +1569,7 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, - EX(op_array), EX_Ts() TSRMLS_CC); + EX(op_array), execute_data TSRMLS_CC); ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } @@ -1592,7 +1581,7 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->op1.opline_num, - EX(op_array), EX_Ts() TSRMLS_CC); + EX(op_array), execute_data TSRMLS_CC); ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } @@ -1605,7 +1594,7 @@ static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); el = zend_brk_cont(Z_LVAL_P(opline->op2.zv), opline->extended_value, - EX(op_array), EX_Ts() TSRMLS_CC); + EX(op_array), execute_data TSRMLS_CC); brk_opline = EX(op_array)->opcodes + el->brk; @@ -1665,7 +1654,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_op2; - zval *class_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *class_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR == IS_CONST) { if (CACHED_PTR(opline->op2.literal->cache_slot)) { @@ -1715,7 +1704,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H zend_free_op free_op2; SAVE_OPLINE(); - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (EXPECTED(Z_TYPE_P(function_name) == IS_STRING)) { function_name_strval = Z_STRVAL_P(function_name); @@ -1843,7 +1832,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_op2; - zval *class_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *class_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_CONST) { if (CACHED_PTR(opline->op2.literal->cache_slot)) { @@ -1893,7 +1882,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H zend_free_op free_op2; SAVE_OPLINE(); - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (EXPECTED(Z_TYPE_P(function_name) == IS_STRING)) { function_name_strval = Z_STRVAL_P(function_name); @@ -2057,7 +2046,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } else { - zval *class_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *class_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV == IS_CONST) { if (CACHED_PTR(opline->op2.literal->cache_slot)) { @@ -2106,7 +2095,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (EXPECTED(Z_TYPE_P(function_name) == IS_STRING)) { function_name_strval = Z_STRVAL_P(function_name); @@ -4370,7 +4359,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4385,7 +4374,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4400,7 +4389,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4415,7 +4404,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4430,7 +4419,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4445,7 +4434,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4460,7 +4449,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4475,7 +4464,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4490,7 +4479,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4506,7 +4495,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCO SAVE_OPLINE(); is_identical_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); zval_dtor(free_op2.var); @@ -4523,7 +4512,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4539,7 +4528,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4555,7 +4544,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4571,7 +4560,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_O SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4586,7 +4575,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4601,7 +4590,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4616,7 +4605,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4631,7 +4620,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4654,12 +4643,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HA if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); } else { container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); } @@ -4717,7 +4706,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE function_name_strval = Z_STRVAL_P(opline->op2.zv); function_name_strlen = Z_STRLEN_P(opline->op2.zv); } else { - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { zend_error_noreturn(E_ERROR, "Function name must be a string"); @@ -4797,7 +4786,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_A } is_equal_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -4842,7 +4831,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPC if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -5004,7 +4993,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded key */ if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -5066,7 +5055,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5081,7 +5070,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5096,7 +5085,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5111,7 +5100,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5126,7 +5115,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5141,7 +5130,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5156,7 +5145,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5171,7 +5160,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5186,7 +5175,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5202,7 +5191,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCO SAVE_OPLINE(); is_identical_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -5219,7 +5208,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5235,7 +5224,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5251,7 +5240,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5267,7 +5256,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_O SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5282,7 +5271,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5297,7 +5286,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5312,7 +5301,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5327,7 +5316,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5514,12 +5503,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HA if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; } else { container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; } @@ -5577,7 +5566,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE function_name_strval = Z_STRVAL_P(opline->op2.zv); function_name_strlen = Z_STRLEN_P(opline->op2.zv); } else { - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { zend_error_noreturn(E_ERROR, "Function name must be a string"); @@ -5657,7 +5646,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_A } is_equal_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -5702,7 +5691,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPC if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -6025,7 +6014,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded key */ if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -6803,7 +6792,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6818,7 +6807,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6833,7 +6822,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6848,7 +6837,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6863,7 +6852,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6878,7 +6867,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6893,7 +6882,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6908,7 +6897,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6923,7 +6912,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -6939,7 +6928,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCOD SAVE_OPLINE(); is_identical_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); @@ -6956,7 +6945,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -6972,7 +6961,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -6988,7 +6977,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -7004,7 +6993,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OP SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -7019,7 +7008,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -7034,7 +7023,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -7049,7 +7038,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -7064,7 +7053,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -7087,12 +7076,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAN if (IS_CONST == IS_TMP_VAR || IS_CONST == IS_CONST) { zval *container = opline->op1.zv; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } else { container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } @@ -7150,7 +7139,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN function_name_strval = Z_STRVAL_P(opline->op2.zv); function_name_strlen = Z_STRLEN_P(opline->op2.zv); } else { - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { zend_error_noreturn(E_ERROR, "Function name must be a string"); @@ -7263,7 +7252,7 @@ static int ZEND_FASTCALL ZEND_CATCH_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A if (EX_CV(opline->op2.var)) { zval_ptr_dtor(EX_CV(opline->op2.var)); } - EX_CV(opline->op2.var) = (zval**)EX_CVs() + (EX(op_array)->last_var + opline->op2.var); + EX_CV(opline->op2.var) = (zval**)EX_CV_NUM(execute_data, EX(op_array)->last_var + opline->op2.var); *EX_CV(opline->op2.var) = EG(exception); } else { zend_compiled_variable *cv = &CV_DEF_OF(opline->op2.var); @@ -7290,7 +7279,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_AR } is_equal_function(&EX_T(opline->result.var).tmp_var, opline->op1.zv, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -7334,7 +7323,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCO if (IS_CV != IS_UNUSED) { - zval *offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -7496,7 +7485,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A /* Set the new yielded key */ if (IS_CV != IS_UNUSED) { - zval *key = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *key = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -7557,7 +7546,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); bitwise_not_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -7570,7 +7559,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); boolean_not_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -7584,7 +7573,7 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *z; SAVE_OPLINE(); - z = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + z = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && @@ -7623,7 +7612,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int ret; SAVE_OPLINE(); - val = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { ret = Z_LVAL_P(val); @@ -7653,7 +7642,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int ret; SAVE_OPLINE(); - val = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { ret = Z_LVAL_P(val); @@ -7683,7 +7672,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int retval; SAVE_OPLINE(); - val = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -7717,7 +7706,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS int retval; SAVE_OPLINE(); - val = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -7748,7 +7737,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG int retval; SAVE_OPLINE(); - val = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -7792,7 +7781,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - retval_ptr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + retval_ptr = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (!EG(return_value_ptr_ptr)) { if (IS_TMP_VAR == IS_TMP_VAR) { @@ -7853,7 +7842,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); - retval_ptr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + retval_ptr = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (!EG(return_value_ptr_ptr)) { if (IS_TMP_VAR == IS_TMP_VAR) { zval_dtor(free_op1.var); @@ -7914,7 +7903,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_CONST || UNEXPECTED(Z_TYPE_P(value) != IS_OBJECT)) { zend_error_noreturn(E_ERROR, "Can only throw objects"); @@ -7947,7 +7936,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG zval *value; zend_free_op free_op1; - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(valptr); INIT_PZVAL_COPY(valptr, value); @@ -7969,7 +7958,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); /* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */ - ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC))); + ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC))); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -7986,7 +7975,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_object_clone_obj_t clone_call; SAVE_OPLINE(); - obj = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + obj = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_CONST || UNEXPECTED(Z_TYPE_P(obj) != IS_OBJECT)) { @@ -8047,7 +8036,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - expr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (opline->extended_value != IS_STRING) { ZVAL_COPY_VALUE(result, expr); @@ -8108,7 +8097,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND zend_bool failure_retval=0; SAVE_OPLINE(); - inc_filename = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + inc_filename = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (inc_filename->type!=IS_STRING) { MAKE_STD_ZVAL(tmp_inc_filename); @@ -8282,7 +8271,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG Z_ADDREF_P(array_ptr); } } else { - array_ptr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + array_ptr = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { /* IS_TMP_VAR */ zval *tmp; @@ -8391,7 +8380,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op1; - zval *ptr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *ptr = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (Z_TYPE_P(ptr) == IS_LONG) { EG(exit_status) = Z_LVAL_P(ptr); @@ -8441,7 +8430,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval *value; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (i_zend_is_true(value)) { ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value); @@ -8467,7 +8456,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ zval *value, *ret; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (i_zend_is_true(value)) { if (IS_TMP_VAR == IS_VAR || IS_TMP_VAR == IS_CV) { @@ -8502,7 +8491,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zval *value; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value); if (!1) { @@ -8520,7 +8509,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE zval *value, *ret; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR == IS_VAR || IS_TMP_VAR == IS_CV) { Z_ADDREF_P(value); @@ -8548,7 +8537,7 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_A zend_bool result; SAVE_OPLINE(); - expr = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (Z_TYPE_P(expr) == IS_OBJECT && Z_OBJ_HT_P(expr)->get_class_entry) { result = instanceof_function(Z_OBJCE_P(expr), EX_T(opline->op2.var).class_entry TSRMLS_CC); @@ -8568,7 +8557,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8583,7 +8572,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8598,7 +8587,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8613,7 +8602,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8628,7 +8617,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8643,7 +8632,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8658,7 +8647,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8673,7 +8662,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8688,7 +8677,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8704,7 +8693,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); zval_dtor(free_op1.var); @@ -8721,7 +8710,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); @@ -8737,7 +8726,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); @@ -8753,7 +8742,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); @@ -8769,7 +8758,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_O SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); zval_dtor(free_op1.var); @@ -8784,7 +8773,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8799,7 +8788,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8814,7 +8803,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8829,7 +8818,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); zval_dtor(free_op1.var); @@ -8848,7 +8837,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_CONST(int type, ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -9016,7 +9005,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HA } if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *container = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); zval_dtor(free_op1.var); @@ -9038,7 +9027,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC zval *container; SAVE_OPLINE(); - container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_ARRAY)) { PZVAL_LOCK(&EG(uninitialized_zval)); @@ -9122,7 +9111,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -9183,7 +9172,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_A PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); CHECK_EXCEPTION(); @@ -9207,7 +9196,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPC expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { /* temporary variable */ zval *new_expr; @@ -9314,7 +9303,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -9390,7 +9379,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC } else { HashTable *target_symbol_table; zend_free_op free_op1; - zval tmp, *varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -9484,7 +9473,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -9519,7 +9508,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ } } else { - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -9612,8 +9601,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9627,8 +9616,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9642,8 +9631,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9657,8 +9646,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9672,8 +9661,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9687,8 +9676,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9702,8 +9691,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9717,8 +9706,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9732,8 +9721,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9748,8 +9737,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); zval_dtor(free_op1.var); zval_dtor(free_op2.var); @@ -9765,8 +9754,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9781,8 +9770,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9797,8 +9786,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9813,8 +9802,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPC SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9828,8 +9817,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9843,8 +9832,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9858,8 +9847,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9873,8 +9862,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -9896,13 +9885,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAND } if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); zval_dtor(free_op1.var); } else { container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); } @@ -9921,7 +9910,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ int use_copy = 0; SAVE_OPLINE(); - var = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + var = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR == IS_UNUSED) { /* Initialize for erealloc in add_string_to_string */ @@ -9967,7 +9956,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE SAVE_OPLINE(); - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -9977,7 +9966,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -10039,8 +10028,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -10064,7 +10053,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCOD expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { /* temporary variable */ zval *new_expr; @@ -10085,7 +10074,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCOD if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -10180,7 +10169,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -10215,7 +10204,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR } } else { - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -10247,7 +10236,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded key */ if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -10308,8 +10297,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10323,8 +10312,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10338,8 +10327,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10353,8 +10342,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10368,8 +10357,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10383,8 +10372,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10398,8 +10387,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10413,8 +10402,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10428,8 +10417,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10444,8 +10433,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -10461,8 +10450,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10477,8 +10466,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10493,8 +10482,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10509,8 +10498,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPC SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10524,8 +10513,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10539,8 +10528,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10554,8 +10543,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10569,8 +10558,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10588,7 +10577,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_VAR(int type, ZE ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -10756,13 +10745,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAND } if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; zval_dtor(free_op1.var); } else { container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; } @@ -10781,7 +10770,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ int use_copy = 0; SAVE_OPLINE(); - var = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + var = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR == IS_UNUSED) { /* Initialize for erealloc in add_string_to_string */ @@ -10827,7 +10816,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE SAVE_OPLINE(); - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -10837,7 +10826,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -10899,8 +10888,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -10924,7 +10913,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { /* temporary variable */ zval *new_expr; @@ -10945,7 +10934,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -11031,7 +11020,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -11107,7 +11096,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD } else { HashTable *target_symbol_table; zend_free_op free_op1; - zval tmp, *varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -11201,7 +11190,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -11236,7 +11225,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR } } else { - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -11268,7 +11257,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded key */ if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -11334,7 +11323,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_UNUSED(int type, ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -11504,7 +11493,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OP expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { /* temporary variable */ zval *new_expr; @@ -11611,7 +11600,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -11687,7 +11676,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OP } else { HashTable *target_symbol_table; zend_free_op free_op1; - zval tmp, *varname = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -11781,7 +11770,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -11816,7 +11805,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER } } else { - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -11909,8 +11898,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -11924,8 +11913,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -11939,8 +11928,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -11954,8 +11943,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -11969,8 +11958,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -11984,8 +11973,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -11999,8 +11988,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12014,8 +12003,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12029,8 +12018,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12045,8 +12034,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); zval_dtor(free_op1.var); @@ -12062,8 +12051,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12078,8 +12067,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12094,8 +12083,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12110,8 +12099,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCO SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12125,8 +12114,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12140,8 +12129,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12155,8 +12144,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12170,8 +12159,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op1.var); CHECK_EXCEPTION(); @@ -12193,13 +12182,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDL } if (IS_TMP_VAR == IS_TMP_VAR || IS_TMP_VAR == IS_CONST) { - zval *container = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); zval_dtor(free_op1.var); } else { container = NULL; - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } @@ -12218,7 +12207,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_A int use_copy = 0; SAVE_OPLINE(); - var = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + var = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_TMP_VAR == IS_UNUSED) { /* Initialize for erealloc in add_string_to_string */ @@ -12263,7 +12252,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -12273,7 +12262,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -12334,8 +12323,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -12358,7 +12347,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { /* temporary variable */ zval *new_expr; @@ -12379,7 +12368,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE if (IS_CV != IS_UNUSED) { - zval *offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -12474,7 +12463,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -12509,7 +12498,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG } } else { - zval *value = _get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -12541,7 +12530,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded key */ if (IS_CV != IS_UNUSED) { - zval *key = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *key = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -12602,7 +12591,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); bitwise_not_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -12615,7 +12604,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); boolean_not_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -12628,7 +12617,7 @@ static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval **var_ptr; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -12675,7 +12664,7 @@ static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval **var_ptr; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -12722,7 +12711,7 @@ static int ZEND_FASTCALL ZEND_POST_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG zval **var_ptr, *retval; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -12765,7 +12754,7 @@ static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG zval **var_ptr, *retval; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -12809,7 +12798,7 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *z; SAVE_OPLINE(); - z = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + z = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && @@ -12848,7 +12837,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int ret; SAVE_OPLINE(); - val = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { ret = Z_LVAL_P(val); @@ -12878,7 +12867,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int ret; SAVE_OPLINE(); - val = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { ret = Z_LVAL_P(val); @@ -12908,7 +12897,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int retval; SAVE_OPLINE(); - val = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -12942,7 +12931,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS int retval; SAVE_OPLINE(); - val = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -12973,7 +12962,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG int retval; SAVE_OPLINE(); - val = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + val = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -13017,7 +13006,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - retval_ptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + retval_ptr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (!EG(return_value_ptr_ptr)) { if (IS_VAR == IS_TMP_VAR) { @@ -13078,7 +13067,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); - retval_ptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + retval_ptr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (!EG(return_value_ptr_ptr)) { if (IS_VAR == IS_TMP_VAR) { if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -13100,7 +13089,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE break; } - retval_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + retval_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(retval_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot return string offsets by reference"); @@ -13140,7 +13129,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_free_op free_op1; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CONST || UNEXPECTED(Z_TYPE_P(value) != IS_OBJECT)) { zend_error_noreturn(E_ERROR, "Can only throw objects"); @@ -13164,7 +13153,7 @@ static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_AR USE_OPLINE zval *varptr; zend_free_op free_op1; - varptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varptr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (varptr == &EG(uninitialized_zval)) { ALLOC_ZVAL(varptr); @@ -13209,7 +13198,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND varptr = EX_T(opline->op1.var).var.ptr; PZVAL_UNLOCK_EX(varptr, &free_op1, 0); } else { - varptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varptr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); } if ((!(opline->extended_value & ZEND_ARG_SEND_FUNCTION) || EX_T(opline->op1.var).var.fcall_returned_reference) && @@ -13247,7 +13236,7 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG zval *varptr; SAVE_OPLINE(); - varptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(varptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Only variables can be passed by reference"); @@ -13294,7 +13283,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); /* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */ - ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC))); + ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC))); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -13321,7 +13310,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_object_clone_obj_t clone_call; SAVE_OPLINE(); - obj = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + obj = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CONST || UNEXPECTED(Z_TYPE_P(obj) != IS_OBJECT)) { @@ -13382,7 +13371,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - expr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (opline->extended_value != IS_STRING) { ZVAL_COPY_VALUE(result, expr); @@ -13443,7 +13432,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND zend_bool failure_retval=0; SAVE_OPLINE(); - inc_filename = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + inc_filename = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (inc_filename->type!=IS_STRING) { MAKE_STD_ZVAL(tmp_inc_filename); @@ -13590,7 +13579,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG if ((IS_VAR == IS_CV || IS_VAR == IS_VAR) && (opline->extended_value & ZEND_FE_RESET_VARIABLE)) { - array_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + array_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (array_ptr_ptr == NULL || array_ptr_ptr == &EG(uninitialized_zval_ptr)) { MAKE_STD_ZVAL(array_ptr); ZVAL_NULL(array_ptr); @@ -13617,7 +13606,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG Z_ADDREF_P(array_ptr); } } else { - array_ptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + array_ptr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { /* IS_TMP_VAR */ zval *tmp; @@ -13869,7 +13858,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); if (IS_VAR != IS_UNUSED) { zend_free_op free_op1; - zval *ptr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *ptr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (Z_TYPE_P(ptr) == IS_LONG) { EG(exit_status) = Z_LVAL_P(ptr); @@ -13890,7 +13879,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval *value; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (i_zend_is_true(value)) { ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value); @@ -13916,7 +13905,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ zval *value, *ret; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (i_zend_is_true(value)) { if (IS_VAR == IS_VAR || IS_VAR == IS_CV) { @@ -13951,7 +13940,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zval *value; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value); if (!0) { @@ -13969,7 +13958,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE zval *value, *ret; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR || IS_VAR == IS_CV) { Z_ADDREF_P(value); @@ -13998,7 +13987,7 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_A zend_bool result; SAVE_OPLINE(); - expr = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (Z_TYPE_P(expr) == IS_OBJECT && Z_OBJ_HT_P(expr)->get_class_entry) { result = instanceof_function(Z_OBJCE_P(expr), EX_T(opline->op2.var).class_entry TSRMLS_CC); @@ -14018,7 +14007,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14033,7 +14022,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14048,7 +14037,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14063,7 +14052,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14078,7 +14067,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14093,7 +14082,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14108,7 +14097,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14123,7 +14112,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14138,7 +14127,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14154,7 +14143,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14171,7 +14160,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14187,7 +14176,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14203,7 +14192,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14219,7 +14208,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_O SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14234,7 +14223,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14249,7 +14238,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14264,7 +14253,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14279,7 +14268,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14291,10 +14280,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(int (*b { USE_OPLINE zend_free_op free_op1, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zval *object; zval *property = opline->op2.zv; - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -14412,7 +14401,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binar return zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -14425,14 +14414,14 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binar zval *dim = opline->op2.zv; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_CONST, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: value = opline->op2.zv; - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* do nothing */ break; } @@ -14554,7 +14543,7 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CONST(incdec_t int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); property = opline->op2.zv; retval = &EX_T(opline->result.var).var.ptr; @@ -14658,7 +14647,7 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CONST(incdec_ int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); property = opline->op2.zv; retval = &EX_T(opline->result.var).tmp_var; @@ -14760,7 +14749,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_CONST(int type, ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -14928,12 +14917,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA } if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -14950,7 +14939,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -14984,7 +14973,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -15006,7 +14995,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_IS TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -15023,7 +15012,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } @@ -15035,7 +15024,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP if (IS_CONST == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); } @@ -15051,7 +15040,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCOD zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -15093,7 +15082,7 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CONST( zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); offset = opline->op2.zv; if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || @@ -15150,7 +15139,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA if (0) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -15190,7 +15179,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); property = opline->op2.zv; - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -15221,7 +15210,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); offset = opline->op2.zv; if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || @@ -15266,7 +15255,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP SAVE_OPLINE(); property = opline->op2.zv; - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -15299,7 +15288,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCOD zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); property = opline->op2.zv; if (IS_VAR == IS_CV) { @@ -15342,7 +15331,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); property_name = opline->op2.zv; if (0) { @@ -15351,7 +15340,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -15371,7 +15360,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -15383,7 +15372,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -15397,8 +15386,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_CONST, BP_VAR_W TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -15453,7 +15442,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); value = opline->op2.zv; - variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_CONST TSRMLS_CC)) { @@ -15520,7 +15509,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -15700,7 +15689,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_A PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), opline->op2.zv TSRMLS_CC); CHECK_EXCEPTION(); @@ -15807,7 +15796,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPC SAVE_OPLINE(); if ((IS_VAR == IS_VAR || IS_VAR == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -15816,7 +15805,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPC expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -15923,7 +15912,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -15984,7 +15973,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } @@ -16083,7 +16072,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); offset = opline->op2.zv; if (IS_VAR != IS_VAR || container) { @@ -16140,7 +16129,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPC } else { HashTable *target_symbol_table; zend_free_op free_op1; - zval tmp, *varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -16212,7 +16201,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST( zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); offset = opline->op2.zv; @@ -16388,7 +16377,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -16399,7 +16388,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -16424,7 +16413,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else { - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -16518,8 +16507,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16533,8 +16522,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16548,8 +16537,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16563,8 +16552,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16578,8 +16567,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16593,8 +16582,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16608,8 +16597,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16623,8 +16612,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16638,8 +16627,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16654,8 +16643,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); @@ -16671,8 +16660,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16687,8 +16676,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16703,8 +16692,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16719,8 +16708,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPC SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16734,8 +16723,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16749,8 +16738,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16764,8 +16753,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16779,8 +16768,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -16791,10 +16780,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(int (*bin { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zval *object; - zval *property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -16912,7 +16901,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_ return zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -16922,17 +16911,17 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_ } return zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* do nothing */ break; } @@ -17055,8 +17044,8 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_TMP(incdec_t i int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -17159,8 +17148,8 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_TMP(incdec_t int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -17265,13 +17254,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND } if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } @@ -17287,12 +17276,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); zval_dtor(free_op2.var); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -17321,12 +17310,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); zval_dtor(free_op2.var); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -17343,8 +17332,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_IS TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_IS TSRMLS_CC); zval_dtor(free_op2.var); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -17360,11 +17349,11 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); } @@ -17372,8 +17361,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO if (IS_TMP_VAR == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); } zval_dtor(free_op2.var); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -17388,7 +17377,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_ zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -17398,7 +17387,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_ if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_UNSET TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_UNSET TSRMLS_CC); zval_dtor(free_op2.var); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -17430,8 +17419,8 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZE zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -17477,7 +17466,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -17487,7 +17476,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND if (1) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -17526,8 +17515,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property); @@ -17558,8 +17547,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -17602,8 +17591,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property); @@ -17636,8 +17625,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_ zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -17679,8 +17668,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property_name); @@ -17688,7 +17677,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (1) { zval_ptr_dtor(&property_name); } else { @@ -17708,19 +17697,19 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } if (Z_TYPE_PP(object_ptr) == IS_OBJECT) { zend_free_op free_op2; - zval *property_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *property_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (1) { zval_ptr_dtor(&property_name); } else { @@ -17729,14 +17718,14 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL } else { zend_free_op free_op2, free_op_data1, free_op_data2; zval *value; - zval *dim = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zval **variable_ptr_ptr; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_TMP_VAR, BP_VAR_W TSRMLS_CC); zval_dtor(free_op2.var); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -17790,8 +17779,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A zval **variable_ptr_ptr; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_TMP_VAR TSRMLS_CC)) { @@ -17848,7 +17837,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE SAVE_OPLINE(); - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -17858,7 +17847,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -17960,7 +17949,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND function_name_strval = Z_STRVAL_P(opline->op2.zv); function_name_strlen = Z_STRLEN_P(opline->op2.zv); } else { - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { zend_error_noreturn(E_ERROR, "Function name must be a string"); @@ -18039,8 +18028,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -18055,7 +18044,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCOD SAVE_OPLINE(); if ((IS_VAR == IS_VAR || IS_VAR == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -18064,7 +18053,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCOD expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -18085,7 +18074,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCOD if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -18156,11 +18145,11 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -18255,8 +18244,8 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_VAR || container) { if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -18299,9 +18288,9 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(in zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -18475,7 +18464,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -18486,7 +18475,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -18511,7 +18500,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else { - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -18544,7 +18533,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded key */ if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -18605,8 +18594,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18620,8 +18609,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18635,8 +18624,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18650,8 +18639,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18665,8 +18654,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18680,8 +18669,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18695,8 +18684,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18710,8 +18699,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18725,8 +18714,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18741,8 +18730,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -18758,8 +18747,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18774,8 +18763,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18790,8 +18779,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18806,8 +18795,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPC SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18821,8 +18810,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18836,8 +18825,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18851,8 +18840,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18866,8 +18855,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -18878,10 +18867,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(int (*bin { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zval *object; - zval *property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -18999,7 +18988,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_ return zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -19009,17 +18998,17 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_ } return zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_VAR, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* do nothing */ break; } @@ -19142,8 +19131,8 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_VAR(incdec_t i int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -19246,8 +19235,8 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_VAR(incdec_t int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -19348,7 +19337,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_VAR(int type, ZE ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -19516,13 +19505,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND } if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } @@ -19538,12 +19527,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -19572,12 +19561,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_RW TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_RW TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -19594,8 +19583,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_IS TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_IS TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -19611,11 +19600,11 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); } @@ -19623,8 +19612,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO if (IS_VAR == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); } if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -19639,7 +19628,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_ zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -19649,7 +19638,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_ if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_UNSET TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_UNSET TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -19681,8 +19670,8 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZE zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -19728,7 +19717,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -19738,7 +19727,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND if (0) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -19777,8 +19766,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -19809,8 +19798,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -19853,8 +19842,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -19887,8 +19876,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_ zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -19930,8 +19919,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); @@ -19939,7 +19928,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -19959,19 +19948,19 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } if (Z_TYPE_PP(object_ptr) == IS_OBJECT) { zend_free_op free_op2; - zval *property_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *property_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -19980,14 +19969,14 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL } else { zend_free_op free_op2, free_op_data1, free_op_data2; zval *value; - zval *dim = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zval **variable_ptr_ptr; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_VAR, BP_VAR_W TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -20041,8 +20030,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A zval **variable_ptr_ptr; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_VAR TSRMLS_CC)) { @@ -20097,7 +20086,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL zval **value_ptr_ptr; SAVE_OPLINE(); - value_ptr_ptr = _get_zval_ptr_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + value_ptr_ptr = _get_zval_ptr_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_VAR && value_ptr_ptr && @@ -20120,7 +20109,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL zend_error_noreturn(E_ERROR, "Cannot assign by reference to overloaded object"); } - variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if ((IS_VAR == IS_VAR && UNEXPECTED(value_ptr_ptr == NULL)) || (IS_VAR == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL))) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets nor overloaded objects"); @@ -20154,7 +20143,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE SAVE_OPLINE(); - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -20164,7 +20153,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -20266,7 +20255,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND function_name_strval = Z_STRVAL_P(opline->op2.zv); function_name_strlen = Z_STRLEN_P(opline->op2.zv); } else { - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { zend_error_noreturn(E_ERROR, "Function name must be a string"); @@ -20345,8 +20334,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -20361,7 +20350,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD SAVE_OPLINE(); if ((IS_VAR == IS_VAR || IS_VAR == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -20370,7 +20359,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -20391,7 +20380,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -20477,7 +20466,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -20538,11 +20527,11 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -20637,8 +20626,8 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_VAR || container) { if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -20694,7 +20683,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD } else { HashTable *target_symbol_table; zend_free_op free_op1; - zval tmp, *varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -20766,9 +20755,9 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(in zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -20942,7 +20931,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -20953,7 +20942,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -20978,7 +20967,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else { - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -21011,7 +21000,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR /* Set the new yielded key */ if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -21070,10 +21059,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(int (* { USE_OPLINE zend_free_op free_op1, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zval *object; zval *property = NULL; - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -21191,7 +21180,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*bina return zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -21204,14 +21193,14 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*bina zval *dim = NULL; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_UNUSED, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: value = NULL; - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* do nothing */ break; } @@ -21333,7 +21322,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_UNUSED(int type, ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -21493,7 +21482,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -21527,7 +21516,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_ zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -21551,7 +21540,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_O SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } @@ -21563,7 +21552,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_O if (IS_UNUSED == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, NULL, IS_UNUSED, BP_VAR_R TSRMLS_CC); } @@ -21579,7 +21568,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HA zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -21591,7 +21580,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HA if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_UNUSED == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_UNUSED == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -21605,8 +21594,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HA zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_UNUSED, BP_VAR_W TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -21778,7 +21767,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OP SAVE_OPLINE(); if ((IS_VAR == IS_VAR || IS_VAR == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -21787,7 +21776,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OP expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -21894,7 +21883,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -21970,7 +21959,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OP } else { HashTable *target_symbol_table; zend_free_op free_op1; - zval tmp, *varname = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -22085,7 +22074,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -22096,7 +22085,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -22121,7 +22110,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else { - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -22215,8 +22204,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22230,8 +22219,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22245,8 +22234,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22260,8 +22249,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22275,8 +22264,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22290,8 +22279,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22305,8 +22294,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22320,8 +22309,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22335,8 +22324,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22351,8 +22340,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -22368,8 +22357,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22384,8 +22373,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22400,8 +22389,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22416,8 +22405,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCO SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22431,8 +22420,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22446,8 +22435,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22461,8 +22450,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22476,8 +22465,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -22488,10 +22477,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CV(int (*bina { USE_OPLINE zend_free_op free_op1, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); zval *object; - zval *property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -22609,7 +22598,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_o return zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -22619,17 +22608,17 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_o } return zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_CV, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* do nothing */ break; } @@ -22751,8 +22740,8 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CV(incdec_t in int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -22855,8 +22844,8 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CV(incdec_t i int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -22961,13 +22950,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL } if (IS_VAR == IS_TMP_VAR || IS_VAR == IS_CONST) { - zval *container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } else { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } @@ -22983,12 +22972,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -23017,12 +23006,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_RW TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_RW TSRMLS_CC); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -23039,8 +23028,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_IS TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_IS TSRMLS_CC); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; CHECK_EXCEPTION(); @@ -23056,11 +23045,11 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); } @@ -23068,8 +23057,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD if (IS_CV == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; @@ -23084,7 +23073,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -23094,7 +23083,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_H if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_UNSET TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_UNSET TSRMLS_CC); if (IS_VAR == IS_VAR && (free_op1.var != NULL) && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -23126,8 +23115,8 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEN zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -23173,7 +23162,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_VAR == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -23183,7 +23172,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL if (0) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -23222,8 +23211,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -23254,8 +23243,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -23298,8 +23287,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -23332,8 +23321,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_H zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_VAR == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -23375,8 +23364,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - property_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + property_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); @@ -23384,7 +23373,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -23404,19 +23393,19 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } if (Z_TYPE_PP(object_ptr) == IS_OBJECT) { - zval *property_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *property_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -23425,13 +23414,13 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE } else { zend_free_op free_op_data1, free_op_data2; zval *value; - zval *dim = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); zval **variable_ptr_ptr; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_CV, BP_VAR_W TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -23485,8 +23474,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR zval **variable_ptr_ptr; SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_CV TSRMLS_CC)) { @@ -23540,7 +23529,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE zval **value_ptr_ptr; SAVE_OPLINE(); - value_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op2.var TSRMLS_CC); + value_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV == IS_VAR && value_ptr_ptr && @@ -23563,7 +23552,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE zend_error_noreturn(E_ERROR, "Cannot assign by reference to overloaded object"); } - variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if ((IS_CV == IS_VAR && UNEXPECTED(value_ptr_ptr == NULL)) || (IS_VAR == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL))) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets nor overloaded objects"); @@ -23596,7 +23585,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -23606,7 +23595,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + call->object = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -23707,7 +23696,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_ function_name_strval = Z_STRVAL_P(opline->op2.zv); function_name_strlen = Z_STRLEN_P(opline->op2.zv); } else { - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { zend_error_noreturn(E_ERROR, "Function name must be a string"); @@ -23786,8 +23775,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -23801,7 +23790,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE SAVE_OPLINE(); if ((IS_VAR == IS_VAR || IS_VAR == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -23810,7 +23799,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + expr_ptr=_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -23831,7 +23820,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE if (IS_CV != IS_UNUSED) { - zval *offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -23902,11 +23891,11 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_VAR != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -24001,8 +23990,8 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_VAR != IS_VAR || container) { if (IS_VAR == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -24045,9 +24034,9 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -24221,7 +24210,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -24232,7 +24221,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); if (IS_VAR == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -24257,7 +24246,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; } } else { - zval *value = _get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC); + zval *value = _get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -24290,7 +24279,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded key */ if (IS_CV != IS_UNUSED) { - zval *key = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *key = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -24436,7 +24425,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(int zval **object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); zval *object; zval *property = opline->op2.zv; - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -24566,8 +24555,8 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CONST(int (*bi zval *dim = opline->op2.zv; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_CONST, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; @@ -25153,7 +25142,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_ if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -25841,8 +25830,8 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(int (* zend_free_op free_op2, free_op_data1; zval **object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); zval *object; - zval *property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -25969,16 +25958,16 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_TMP(int (*bina } return zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); var_ptr = NULL; /* do nothing */ break; @@ -26103,7 +26092,7 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(incdec_ SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -26207,7 +26196,7 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_TMP(incdec SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -26307,7 +26296,7 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP SAVE_OPLINE(); container = _get_obj_zval_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -26352,7 +26341,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -26400,7 +26389,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_ zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); if (1) { @@ -26433,7 +26422,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); container = _get_obj_zval_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -26475,7 +26464,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER(ZEND_O zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); if (1) { @@ -26510,7 +26499,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCO SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -26552,7 +26541,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property_name); @@ -26560,7 +26549,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HA if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (1) { zval_ptr_dtor(&property_name); } else { @@ -26583,7 +26572,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDL int use_copy = 0; SAVE_OPLINE(); - var = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + var = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED == IS_UNUSED) { /* Initialize for erealloc in add_string_to_string */ @@ -26629,7 +26618,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPC SAVE_OPLINE(); - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -26718,7 +26707,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN if (IS_UNUSED == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -26813,7 +26802,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED != IS_VAR || container) { if (IS_UNUSED == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -26857,7 +26846,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -27096,7 +27085,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded key */ if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -27156,8 +27145,8 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(int (* zend_free_op free_op2, free_op_data1; zval **object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); zval *object; - zval *property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -27284,16 +27273,16 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_VAR(int (*bina } return zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_VAR, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + value = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); var_ptr = NULL; /* do nothing */ break; @@ -27418,7 +27407,7 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(incdec_ SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -27522,7 +27511,7 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_VAR(incdec SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -27622,7 +27611,7 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR SAVE_OPLINE(); container = _get_obj_zval_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -27667,7 +27656,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -27715,7 +27704,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_ zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); if (0) { @@ -27748,7 +27737,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); container = _get_obj_zval_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -27790,7 +27779,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER(ZEND_O zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); if (0) { @@ -27825,7 +27814,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCO SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -27867,7 +27856,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); @@ -27875,7 +27864,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HA if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -27898,7 +27887,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDL int use_copy = 0; SAVE_OPLINE(); - var = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + var = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED == IS_UNUSED) { /* Initialize for erealloc in add_string_to_string */ @@ -27944,7 +27933,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPC SAVE_OPLINE(); - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -28033,7 +28022,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN if (IS_UNUSED == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -28128,7 +28117,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_UNUSED != IS_VAR || container) { if (IS_UNUSED == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -28172,7 +28161,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -28411,7 +28400,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER /* Set the new yielded key */ if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -28473,7 +28462,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(int zval **object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); zval *object; zval *property = NULL; - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -28603,8 +28592,8 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(int (*b zval *dim = NULL; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_UNUSED, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; @@ -28895,8 +28884,8 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(int (*b zend_free_op free_op_data1; zval **object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); zval *object; - zval *property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -29023,16 +29012,16 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CV(int (*binar } return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_CV, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); var_ptr = NULL; /* do nothing */ break; @@ -29156,7 +29145,7 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CV(incdec_t SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -29260,7 +29249,7 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CV(incdec_ SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -29360,7 +29349,7 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CV( SAVE_OPLINE(); container = _get_obj_zval_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -29405,7 +29394,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HA zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_UNUSED == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -29453,7 +29442,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); if (0) { @@ -29486,7 +29475,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); container = _get_obj_zval_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -29528,7 +29517,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER(ZEND_OP zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); if (0) { @@ -29563,7 +29552,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER(ZEND_OPCOD SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_UNUSED == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -29605,7 +29594,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAN SAVE_OPLINE(); object_ptr = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - property_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); @@ -29613,7 +29602,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAN if (IS_UNUSED == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -29636,7 +29625,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLE int use_copy = 0; SAVE_OPLINE(); - var = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + var = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_UNUSED == IS_UNUSED) { /* Initialize for erealloc in add_string_to_string */ @@ -29681,7 +29670,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCO SAVE_OPLINE(); - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -29769,7 +29758,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND if (IS_UNUSED == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_UNUSED != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -29864,7 +29853,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_UNUSED != IS_VAR || container) { if (IS_UNUSED == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -29908,7 +29897,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV( SAVE_OPLINE(); container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -30147,7 +30136,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ /* Set the new yielded key */ if (IS_CV != IS_UNUSED) { - zval *key = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *key = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -30208,7 +30197,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); bitwise_not_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -30221,7 +30210,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); boolean_not_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -30234,7 +30223,7 @@ static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval **var_ptr; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -30280,7 +30269,7 @@ static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval **var_ptr; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -30326,7 +30315,7 @@ static int ZEND_FASTCALL ZEND_POST_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval **var_ptr, *retval; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -30368,7 +30357,7 @@ static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval **var_ptr, *retval; SAVE_OPLINE(); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(var_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot increment/decrement overloaded objects nor string offsets"); @@ -30411,7 +30400,7 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *z; SAVE_OPLINE(); - z = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + z = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(z) == IS_OBJECT) && @@ -30449,7 +30438,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int ret; SAVE_OPLINE(); - val = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + val = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { ret = Z_LVAL_P(val); @@ -30479,7 +30468,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int ret; SAVE_OPLINE(); - val = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + val = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { ret = Z_LVAL_P(val); @@ -30509,7 +30498,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int retval; SAVE_OPLINE(); - val = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + val = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -30543,7 +30532,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) int retval; SAVE_OPLINE(); - val = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + val = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -30574,7 +30563,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS int retval; SAVE_OPLINE(); - val = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + val = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_TMP_VAR && EXPECTED(Z_TYPE_P(val) == IS_BOOL)) { retval = Z_LVAL_P(val); @@ -30604,7 +30593,7 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - retval_ptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + retval_ptr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (!EG(return_value_ptr_ptr)) { if (IS_CV == IS_TMP_VAR) { @@ -30665,7 +30654,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER /* Not supposed to happen, but we'll allow it */ zend_error(E_NOTICE, "Only variable references should be returned by reference"); - retval_ptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + retval_ptr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (!EG(return_value_ptr_ptr)) { if (IS_CV == IS_TMP_VAR) { @@ -30687,7 +30676,7 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER break; } - retval_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + retval_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(retval_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot return string offsets by reference"); @@ -30726,7 +30715,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CONST || UNEXPECTED(Z_TYPE_P(value) != IS_OBJECT)) { zend_error_noreturn(E_ERROR, "Can only throw objects"); @@ -30750,7 +30739,7 @@ static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARG USE_OPLINE zval *varptr; - varptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varptr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (varptr == &EG(uninitialized_zval)) { ALLOC_ZVAL(varptr); @@ -30795,7 +30784,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL varptr = EX_T(opline->op1.var).var.ptr; PZVAL_UNLOCK_EX(varptr, &free_op1, 0); } else { - varptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varptr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); } if ((!(opline->extended_value & ZEND_ARG_SEND_FUNCTION) || EX_T(opline->op1.var).var.fcall_returned_reference) && @@ -30833,7 +30822,7 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS zval *varptr; SAVE_OPLINE(); - varptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + varptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(varptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Only variables can be passed by reference"); @@ -30879,7 +30868,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); /* PHP 3.0 returned "" for false and 1 for true, here we use 0 and 1 for now */ - ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC))); + ZVAL_BOOL(retval, i_zend_is_true(_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC))); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -30895,7 +30884,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_object_clone_obj_t clone_call; SAVE_OPLINE(); - obj = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + obj = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CONST || UNEXPECTED(Z_TYPE_P(obj) != IS_OBJECT)) { @@ -30956,7 +30945,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *result = &EX_T(opline->result.var).tmp_var; SAVE_OPLINE(); - expr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (opline->extended_value != IS_STRING) { ZVAL_COPY_VALUE(result, expr); @@ -31017,7 +31006,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL zend_bool failure_retval=0; SAVE_OPLINE(); - inc_filename = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + inc_filename = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (inc_filename->type!=IS_STRING) { MAKE_STD_ZVAL(tmp_inc_filename); @@ -31164,7 +31153,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS if ((IS_CV == IS_CV || IS_CV == IS_VAR) && (opline->extended_value & ZEND_FE_RESET_VARIABLE)) { - array_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + array_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (array_ptr_ptr == NULL || array_ptr_ptr == &EG(uninitialized_zval_ptr)) { MAKE_STD_ZVAL(array_ptr); ZVAL_NULL(array_ptr); @@ -31191,7 +31180,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS Z_ADDREF_P(array_ptr); } } else { - array_ptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + array_ptr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (0) { /* IS_TMP_VAR */ zval *tmp; @@ -31300,7 +31289,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); if (IS_CV != IS_UNUSED) { - zval *ptr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *ptr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (Z_TYPE_P(ptr) == IS_LONG) { EG(exit_status) = Z_LVAL_P(ptr); @@ -31321,7 +31310,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zval *value; SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (i_zend_is_true(value)) { ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value); @@ -31346,7 +31335,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A zval *value, *ret; SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (i_zend_is_true(value)) { if (IS_CV == IS_VAR || IS_CV == IS_CV) { @@ -31380,7 +31369,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG zval *value; SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, value); if (!0) { @@ -31398,7 +31387,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER zval *value, *ret; SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR || IS_CV == IS_CV) { Z_ADDREF_P(value); @@ -31426,7 +31415,7 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_AR zend_bool result; SAVE_OPLINE(); - expr = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (Z_TYPE_P(expr) == IS_OBJECT && Z_OBJ_HT_P(expr)->get_class_entry) { result = instanceof_function(Z_OBJCE_P(expr), EX_T(opline->op2.var).class_entry TSRMLS_CC); @@ -31446,7 +31435,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31461,7 +31450,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31476,7 +31465,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31491,7 +31480,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31506,7 +31495,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31521,7 +31510,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31536,7 +31525,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31551,7 +31540,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31566,7 +31555,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31582,7 +31571,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); @@ -31599,7 +31588,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC)); @@ -31615,7 +31604,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC)); @@ -31631,7 +31620,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC)); @@ -31647,7 +31636,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OP SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC)); @@ -31662,7 +31651,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31677,7 +31666,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31692,7 +31681,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31707,7 +31696,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); @@ -31719,10 +31708,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CONST(int (*bi { USE_OPLINE zend_free_op free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); zval *object; zval *property = opline->op2.zv; - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -31839,7 +31828,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary return zend_binary_assign_op_obj_helper_SPEC_CV_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -31852,14 +31841,14 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary zval *dim = opline->op2.zv; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_CONST, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: value = opline->op2.zv; - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); /* do nothing */ break; } @@ -31981,7 +31970,7 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CONST(incdec_t int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); property = opline->op2.zv; retval = &EX_T(opline->result.var).var.ptr; @@ -32085,7 +32074,7 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CONST(incdec_t int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); property = opline->op2.zv; retval = &EX_T(opline->result.var).tmp_var; @@ -32187,7 +32176,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_CONST(int type, Z ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varname = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -32355,12 +32344,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN } if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); @@ -32377,7 +32366,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -32410,7 +32399,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -32432,7 +32421,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_IS TSRMLS_CC); @@ -32449,7 +32438,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } @@ -32461,7 +32450,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC if (IS_CONST == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, opline->op2.zv, IS_CONST, BP_VAR_R TSRMLS_CC); } @@ -32477,7 +32466,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -32519,7 +32508,7 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CONST(Z zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); offset = opline->op2.zv; if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || @@ -32575,7 +32564,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN if (0) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -32614,7 +32603,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA SAVE_OPLINE(); property = opline->op2.zv; - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -32645,7 +32634,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); offset = opline->op2.zv; if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || @@ -32689,7 +32678,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC SAVE_OPLINE(); property = opline->op2.zv; - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -32722,7 +32711,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); property = opline->op2.zv; if (IS_CV == IS_CV) { @@ -32764,7 +32753,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); property_name = opline->op2.zv; if (0) { @@ -32773,7 +32762,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -32793,7 +32782,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -32805,7 +32794,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_CONST == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -32819,8 +32808,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_CONST, BP_VAR_W TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -32875,7 +32864,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); value = opline->op2.zv; - variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_CONST TSRMLS_CC)) { @@ -32940,7 +32929,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -33001,7 +32990,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), opline->op2.zv TSRMLS_CC); CHECK_EXCEPTION(); @@ -33016,7 +33005,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCO SAVE_OPLINE(); if ((IS_CV == IS_VAR || IS_CV == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -33025,7 +33014,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCO expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr_ptr=_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -33132,7 +33121,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varname = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -33193,7 +33182,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } @@ -33291,7 +33280,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); offset = opline->op2.zv; if (IS_CV != IS_VAR || container) { @@ -33347,7 +33336,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCO } else { HashTable *target_symbol_table; - zval tmp, *varname = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -33419,7 +33408,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(i zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); offset = opline->op2.zv; @@ -33593,7 +33582,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -33604,7 +33593,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -33628,7 +33617,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A } } else { - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -33721,8 +33710,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33736,8 +33725,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33751,8 +33740,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33766,8 +33755,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33781,8 +33770,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33796,8 +33785,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33811,8 +33800,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33826,8 +33815,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33841,8 +33830,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33857,8 +33846,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); zval_dtor(free_op2.var); @@ -33874,8 +33863,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33890,8 +33879,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33906,8 +33895,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33922,8 +33911,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCO SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33937,8 +33926,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33952,8 +33941,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33967,8 +33956,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33982,8 +33971,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -33994,10 +33983,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_TMP(int (*bina { USE_OPLINE zend_free_op free_op2, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); zval *object; - zval *property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -34114,7 +34103,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_o return zend_binary_assign_op_obj_helper_SPEC_CV_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -34124,17 +34113,17 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_o } return zend_binary_assign_op_obj_helper_SPEC_CV_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); /* do nothing */ break; } @@ -34257,8 +34246,8 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_TMP(incdec_t in int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -34361,8 +34350,8 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_TMP(incdec_t i int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -34467,13 +34456,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL } if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); zval_dtor(free_op2.var); } @@ -34489,12 +34478,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); zval_dtor(free_op2.var); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -34522,12 +34511,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_RW TSRMLS_CC); zval_dtor(free_op2.var); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -34544,8 +34533,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_IS TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_IS TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -34561,11 +34550,11 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_W TSRMLS_CC); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); } @@ -34573,8 +34562,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD if (IS_TMP_VAR == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_R TSRMLS_CC); } zval_dtor(free_op2.var); @@ -34589,7 +34578,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -34599,7 +34588,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_H if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_UNSET TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_TMP_VAR, BP_VAR_UNSET TSRMLS_CC); zval_dtor(free_op2.var); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -34631,8 +34620,8 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEN zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -34677,7 +34666,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -34687,7 +34676,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL if (1) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -34725,8 +34714,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property); @@ -34757,8 +34746,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -34800,8 +34789,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property); @@ -34834,8 +34823,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_H zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -34876,8 +34865,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); - property_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); + property_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property_name); @@ -34885,7 +34874,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (1) { zval_ptr_dtor(&property_name); } else { @@ -34905,19 +34894,19 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } if (Z_TYPE_PP(object_ptr) == IS_OBJECT) { zend_free_op free_op2; - zval *property_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *property_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (1) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_TMP_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (1) { zval_ptr_dtor(&property_name); } else { @@ -34926,14 +34915,14 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE } else { zend_free_op free_op2, free_op_data1, free_op_data2; zval *value; - zval *dim = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zval **variable_ptr_ptr; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_TMP_VAR, BP_VAR_W TSRMLS_CC); zval_dtor(free_op2.var); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -34987,8 +34976,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR zval **variable_ptr_ptr; SAVE_OPLINE(); - value = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_TMP_VAR TSRMLS_CC)) { @@ -35043,7 +35032,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); - function_name = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_TMP_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -35053,7 +35042,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -35115,8 +35104,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); zval_dtor(free_op2.var); CHECK_EXCEPTION(); @@ -35131,7 +35120,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE SAVE_OPLINE(); if ((IS_CV == IS_VAR || IS_CV == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -35140,7 +35129,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr_ptr=_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -35161,7 +35150,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -35232,11 +35221,11 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -35330,8 +35319,8 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV != IS_VAR || container) { if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -35373,9 +35362,9 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -35547,7 +35536,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -35558,7 +35547,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -35582,7 +35571,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG } } else { - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -35614,7 +35603,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded key */ if (IS_TMP_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_TMP_VAR == IS_CONST || IS_TMP_VAR == IS_TMP_VAR @@ -35675,8 +35664,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35690,8 +35679,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35705,8 +35694,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35720,8 +35709,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35735,8 +35724,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35750,8 +35739,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35765,8 +35754,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35780,8 +35769,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35795,8 +35784,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35811,8 +35800,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -35828,8 +35817,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35844,8 +35833,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35860,8 +35849,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35876,8 +35865,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCO SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC)); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35891,8 +35880,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35906,8 +35895,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35921,8 +35910,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35936,8 +35925,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -35948,10 +35937,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_VAR(int (*bina { USE_OPLINE zend_free_op free_op2, free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); zval *object; - zval *property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -36068,7 +36057,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_o return zend_binary_assign_op_obj_helper_SPEC_CV_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -36078,17 +36067,17 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_o } return zend_binary_assign_op_obj_helper_SPEC_CV_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_VAR, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); /* do nothing */ break; } @@ -36211,8 +36200,8 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_VAR(incdec_t in int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -36315,8 +36304,8 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_VAR(incdec_t i int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -36417,7 +36406,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_VAR(int type, ZEN ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varname = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -36585,13 +36574,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL } if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; } @@ -36607,12 +36596,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -36640,12 +36629,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_RW TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_RW TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -36662,8 +36651,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_IS TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_IS TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -36679,11 +36668,11 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_W TSRMLS_CC); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); } @@ -36691,8 +36680,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD if (IS_VAR == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_R TSRMLS_CC); } if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; @@ -36707,7 +36696,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -36717,7 +36706,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_H if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_UNSET TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC), IS_VAR, BP_VAR_UNSET TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -36749,8 +36738,8 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEN zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -36795,7 +36784,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -36805,7 +36794,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL if (0) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -36843,8 +36832,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -36875,8 +36864,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -36918,8 +36907,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -36952,8 +36941,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_H zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -36994,8 +36983,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); - property_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); + property_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); @@ -37003,7 +36992,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -37023,19 +37012,19 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } if (Z_TYPE_PP(object_ptr) == IS_OBJECT) { zend_free_op free_op2; - zval *property_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *property_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_VAR == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -37044,14 +37033,14 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE } else { zend_free_op free_op2, free_op_data1, free_op_data2; zval *value; - zval *dim = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); zval **variable_ptr_ptr; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_VAR, BP_VAR_W TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -37105,8 +37094,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR zval **variable_ptr_ptr; SAVE_OPLINE(); - value = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); - variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_VAR TSRMLS_CC)) { @@ -37159,7 +37148,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE zval **value_ptr_ptr; SAVE_OPLINE(); - value_ptr_ptr = _get_zval_ptr_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + value_ptr_ptr = _get_zval_ptr_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR == IS_VAR && value_ptr_ptr && @@ -37182,7 +37171,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE zend_error_noreturn(E_ERROR, "Cannot assign by reference to overloaded object"); } - variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if ((IS_VAR == IS_VAR && UNEXPECTED(value_ptr_ptr == NULL)) || (IS_CV == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL))) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets nor overloaded objects"); @@ -37215,7 +37204,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); - function_name = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + function_name = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_VAR != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -37225,7 +37214,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -37287,8 +37276,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC) TSRMLS_CC); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; CHECK_EXCEPTION(); @@ -37303,7 +37292,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE SAVE_OPLINE(); if ((IS_CV == IS_VAR || IS_CV == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -37312,7 +37301,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr_ptr=_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -37333,7 +37322,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -37419,7 +37408,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varname = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -37480,11 +37469,11 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -37578,8 +37567,8 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (IS_CV != IS_VAR || container) { if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -37634,7 +37623,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE } else { HashTable *target_symbol_table; - zval tmp, *varname = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -37706,9 +37695,9 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + offset = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -37880,7 +37869,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -37891,7 +37880,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -37915,7 +37904,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG } } else { - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -37947,7 +37936,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG /* Set the new yielded key */ if (IS_VAR != IS_UNUSED) { zend_free_op free_op2; - zval *key = _get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC); + zval *key = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_VAR == IS_CONST || IS_VAR == IS_TMP_VAR @@ -38006,10 +37995,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(int (*b { USE_OPLINE zend_free_op free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); zval *object; zval *property = NULL; - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -38126,7 +38115,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binar return zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -38139,14 +38128,14 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binar zval *dim = NULL; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_UNUSED, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: value = NULL; - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); /* do nothing */ break; } @@ -38268,7 +38257,7 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_UNUSED(int type, ulong hash_value; SAVE_OPLINE(); - varname = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varname = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(varname) != IS_STRING)) { ZVAL_COPY_VALUE(&tmp_varname, varname); @@ -38428,7 +38417,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HA zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -38461,7 +38450,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_H zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -38485,7 +38474,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OP SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } @@ -38497,7 +38486,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OP if (IS_UNUSED == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, NULL, IS_UNUSED, BP_VAR_R TSRMLS_CC); } @@ -38513,7 +38502,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAN zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -38525,7 +38514,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAN if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_UNUSED == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_UNUSED == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -38539,8 +38528,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAN zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_UNUSED, BP_VAR_W TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -38594,7 +38583,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPC SAVE_OPLINE(); if ((IS_CV == IS_VAR || IS_CV == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -38603,7 +38592,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPC expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr_ptr=_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -38710,7 +38699,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } - varname = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + varname = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -38786,7 +38775,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPC } else { HashTable *target_symbol_table; - zval tmp, *varname = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + zval tmp, *varname = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV != IS_CONST && Z_TYPE_P(varname) != IS_STRING) { ZVAL_COPY_VALUE(&tmp, varname); @@ -38880,7 +38869,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -38891,7 +38880,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -38915,7 +38904,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ } } else { - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -39008,8 +38997,8 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_add_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39023,8 +39012,8 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_sub_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39038,8 +39027,8 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mul_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39053,8 +39042,8 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_div_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39068,8 +39057,8 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); fast_mod_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39083,8 +39072,8 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_left_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39098,8 +39087,8 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) SAVE_OPLINE(); shift_right_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39113,8 +39102,8 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); concat_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39128,8 +39117,8 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); is_identical_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39144,8 +39133,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); is_identical_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); Z_LVAL_P(result) = !Z_LVAL_P(result); @@ -39161,8 +39150,8 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); ZVAL_BOOL(result, fast_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -39177,8 +39166,8 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); ZVAL_BOOL(result, fast_not_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -39193,8 +39182,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -39209,8 +39198,8 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCOD SAVE_OPLINE(); ZVAL_BOOL(result, fast_is_smaller_or_equal_function(result, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC)); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC)); CHECK_EXCEPTION(); @@ -39224,8 +39213,8 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS SAVE_OPLINE(); bitwise_or_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39239,8 +39228,8 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); bitwise_and_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39254,8 +39243,8 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG SAVE_OPLINE(); bitwise_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39269,8 +39258,8 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_A SAVE_OPLINE(); boolean_xor_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); @@ -39281,10 +39270,10 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CV(int (*binar { USE_OPLINE zend_free_op free_op_data1; - zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); zval *object; - zval *property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); + zval *property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + zval *value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); int have_get_ptr = 0; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -39401,7 +39390,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op return zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { - zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); @@ -39411,17 +39400,17 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op } return zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - zval *dim = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), container, dim, IS_CV, BP_VAR_RW TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + var_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); } } break; default: - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + var_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); /* do nothing */ break; } @@ -39543,8 +39532,8 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CV(incdec_t inc int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); retval = &EX_T(opline->result.var).var.ptr; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -39647,8 +39636,8 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CV(incdec_t in int have_get_ptr = 0; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); retval = &EX_T(opline->result.var).tmp_var; if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { @@ -39753,13 +39742,13 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE } if (IS_CV == IS_TMP_VAR || IS_CV == IS_CONST) { - zval *container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + zval *container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), &container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } else { - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } @@ -39775,12 +39764,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -39808,12 +39797,12 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_RW TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_RW TSRMLS_CC); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -39830,8 +39819,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_IS TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_IS TSRMLS_CC); CHECK_EXCEPTION(); @@ -39847,11 +39836,11 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE SAVE_OPLINE(); if (ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))) { - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_W TSRMLS_CC); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); } @@ -39859,8 +39848,8 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE if (IS_CV == IS_UNUSED) { zend_error_noreturn(E_ERROR, "Cannot use [] for reading"); } - container = _get_zval_ptr_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + zend_fetch_dimension_address_read(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_R TSRMLS_CC); } @@ -39875,7 +39864,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HA zval **container; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -39885,7 +39874,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HA if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_UNSET TSRMLS_CC); + zend_fetch_dimension_address(&EX_T(opline->result.var), container, _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC), IS_CV, BP_VAR_UNSET TSRMLS_CC); if (IS_CV == IS_VAR && 0 && READY_TO_DESTROY(free_op1.var)) { EXTRACT_ZVAL_PTR(&EX_T(opline->result.var)); @@ -39917,8 +39906,8 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -39963,7 +39952,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.var).var.ptr_ptr); @@ -39973,7 +39962,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE if (0) { MAKE_REAL_ZVAL_PTR(property); } - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(container == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an object"); } @@ -40011,8 +40000,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - container = _get_zval_ptr_ptr_cv_BP_VAR_RW(EX_CVs(), opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -40043,8 +40032,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (UNEXPECTED(Z_TYPE_P(container) != IS_OBJECT) || UNEXPECTED(Z_OBJ_HT_P(container)->read_property == NULL)) { @@ -40086,8 +40075,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE zval **container; SAVE_OPLINE(); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - container = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property); @@ -40120,8 +40109,8 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HA zval *property; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); - property = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); + property = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV == IS_CV) { if (container != &EG(uninitialized_zval_ptr)) { @@ -40162,8 +40151,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER zval *property_name; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); - property_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); + property_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); @@ -40171,7 +40160,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_OBJ, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_OBJ, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -40191,19 +40180,19 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER zval **object_ptr; SAVE_OPLINE(); - object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + object_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(object_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot use string offset as an array"); } if (Z_TYPE_PP(object_ptr) == IS_OBJECT) { - zval *property_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *property_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (0) { MAKE_REAL_ZVAL_PTR(property_name); } - zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), ZEND_ASSIGN_DIM, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); + zend_assign_to_object(RETURN_VALUE_USED(opline)?&EX_T(opline->result.var).var.ptr:NULL, object_ptr, property_name, (opline+1)->op1_type, &(opline+1)->op1, execute_data, ZEND_ASSIGN_DIM, ((IS_CV == IS_CONST) ? opline->op2.literal : NULL) TSRMLS_CC); if (0) { zval_ptr_dtor(&property_name); } else { @@ -40212,13 +40201,13 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER } else { zend_free_op free_op_data1, free_op_data2; zval *value; - zval *dim = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); zval **variable_ptr_ptr; zend_fetch_dimension_address(&EX_T((opline+1)->op2.var), object_ptr, dim, IS_CV, BP_VAR_W TSRMLS_CC); - value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, EX_Ts(), &free_op_data1, BP_VAR_R); - variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, EX_Ts(), &free_op_data2 TSRMLS_CC); + value = get_zval_ptr((opline+1)->op1_type, &(opline+1)->op1, execute_data, &free_op_data1, BP_VAR_R); + variable_ptr_ptr = _get_zval_ptr_ptr_var((opline+1)->op2.var, execute_data, &free_op_data2 TSRMLS_CC); if (UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T((opline+1)->op2.var), value, (opline+1)->op1_type TSRMLS_CC)) { if (RETURN_VALUE_USED(opline)) { @@ -40272,8 +40261,8 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG zval **variable_ptr_ptr; SAVE_OPLINE(); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); - variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL)) { if (zend_assign_to_string_offset(&EX_T(opline->op1.var), value, IS_CV TSRMLS_CC)) { @@ -40325,7 +40314,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER zval **value_ptr_ptr; SAVE_OPLINE(); - value_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op2.var TSRMLS_CC); + value_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV == IS_VAR && value_ptr_ptr && @@ -40348,7 +40337,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER zend_error_noreturn(E_ERROR, "Cannot assign by reference to overloaded object"); } - variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + variable_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if ((IS_CV == IS_VAR && UNEXPECTED(value_ptr_ptr == NULL)) || (IS_CV == IS_VAR && UNEXPECTED(variable_ptr_ptr == NULL))) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets nor overloaded objects"); @@ -40380,7 +40369,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H SAVE_OPLINE(); - function_name = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + function_name = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV != IS_CONST && UNEXPECTED(Z_TYPE_P(function_name) != IS_STRING)) { @@ -40390,7 +40379,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H function_name_strval = Z_STRVAL_P(function_name); function_name_strlen = Z_STRLEN_P(function_name); - call->object = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + call->object = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (EXPECTED(call->object != NULL) && EXPECTED(Z_TYPE_P(call->object) == IS_OBJECT)) { @@ -40451,8 +40440,8 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) PZVAL_LOCK(EX_T(opline->op1.var).var.ptr); } is_equal_function(&EX_T(opline->result.var).tmp_var, - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC), - _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC) TSRMLS_CC); + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC), + _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC) TSRMLS_CC); CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); @@ -40466,7 +40455,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_ SAVE_OPLINE(); if ((IS_CV == IS_VAR || IS_CV == IS_CV) && opline->extended_value) { - zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **expr_ptr_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(expr_ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot create references to/from string offsets"); @@ -40475,7 +40464,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_ expr_ptr = *expr_ptr_ptr; Z_ADDREF_P(expr_ptr); } else { - expr_ptr=_get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + expr_ptr=_get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); if (0) { /* temporary variable */ zval *new_expr; @@ -40496,7 +40485,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_ if (IS_CV != IS_UNUSED) { - zval *offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); ulong hval; switch (Z_TYPE_P(offset)) { @@ -40567,11 +40556,11 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ ulong hval; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { SEPARATE_ZVAL_IF_NOT_REF(container); } - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV != IS_VAR || container) { switch (Z_TYPE_PP(container)) { @@ -40665,8 +40654,8 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(EX_CVs(), opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_UNSET(execute_data, opline->op1.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (IS_CV != IS_VAR || container) { if (IS_CV == IS_CV && container != &EG(uninitialized_zval_ptr)) { @@ -40708,9 +40697,9 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int zval *offset; SAVE_OPLINE(); - container = _get_zval_ptr_ptr_cv_BP_VAR_IS(EX_CVs(), opline->op1.var TSRMLS_CC); + container = _get_zval_ptr_ptr_cv_BP_VAR_IS(execute_data, opline->op1.var TSRMLS_CC); - offset = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + offset = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) { HashTable *ht; @@ -40882,7 +40871,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS zend_error(E_NOTICE, "Only variable references should be yielded by reference"); - value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); ALLOC_ZVAL(copy); INIT_PZVAL_COPY(copy, value); @@ -40893,7 +40882,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS generator->value = copy; } else { - zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(EX_CVs(), opline->op1.var TSRMLS_CC); + zval **value_ptr = _get_zval_ptr_ptr_cv_BP_VAR_W(execute_data, opline->op1.var TSRMLS_CC); if (IS_CV == IS_VAR && UNEXPECTED(value_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot yield string offsets by reference"); @@ -40917,7 +40906,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } else { - zval *value = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op1.var TSRMLS_CC); + zval *value = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op1.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR @@ -40949,7 +40938,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS /* Set the new yielded key */ if (IS_CV != IS_UNUSED) { - zval *key = _get_zval_ptr_cv_BP_VAR_R(EX_CVs(), opline->op2.var TSRMLS_CC); + zval *key = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); /* Consts, temporary variables and references need copying */ if (IS_CV == IS_CONST || IS_CV == IS_TMP_VAR diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index 85d3dfb04f180..63f83491127af 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -15,24 +15,24 @@ * +========================================+ | * | * +========================================+ | + * | TMP_VAR[op_arrat->T-1] | | + * | ... | | + * EX_TMP_VAR_NUM(0) ----> | TMP_VAR[0] | | + * +----------------------------------------+ | * EG(current_execute_data) -> | zend_execute_data | | * | EX(prev_execute_data) |----+ * +----------------------------------------+ - * EX(Ts) ---------> | EX(Ts)[0] | - * | ... | - * | EX(Tx)[op_arrat->T] | - * +----------------------------------------+ - * EX(CVs) --------> | EX(CVs)[0] |--+ + * EX_CV_NUM(0) ---------> | CV[0] |--+ * | ... | | - * | EX(CVs)[op_array->last_var] | | + * | CV[op_array->last_var-1] | | * +----------------------------------------+ | * | Optional slot for CV[0] zval* |<-+ * | ... | - * | ... for CV [op_array->last_var] zval* | + * | ...for CV [op_array->last_var-1] zval* | * +----------------------------------------+ - * EX(call_slots) -> | EX(call_slots)[0] | + * EX(call_slots) -> | CALL_SLOT[0] | * | ... | - * | EX(call_slots)[op_array->nested_calls] | + * | CALL_SLOT[op_array->nested_calls-1] | * +----------------------------------------+ * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | * | ... | @@ -82,7 +82,7 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); EG(argument_stack)->prev = NULL; - execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size); + execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size + Ts_size); /* copy prev_execute_data */ EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); @@ -104,15 +104,13 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra } } else { execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); + execute_data = (zend_execute_data*)((char*)execute_data + Ts_size); EX(prev_execute_data) = EG(current_execute_data); } - EX(Ts) = (temp_variable *) ((char *) execute_data + execute_data_size); - - EX(CVs) = (zval ***) ((char *) EX(Ts) + Ts_size); - memset(EX(CVs), 0, sizeof(zval **) * op_array->last_var); + memset(EX_CV_NUM(execute_data, 0), 0, sizeof(zval **) * op_array->last_var); - EX(call_slots) = (call_slot*)((char *) EX(CVs) + CVs_size); + EX(call_slots) = (call_slot*)((char *)execute_data + execute_data_size + CVs_size); EX(op_array) = op_array; @@ -134,10 +132,10 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra if (op_array->this_var != -1 && EG(This)) { Z_ADDREF_P(EG(This)); /* For $this pointer */ if (!EG(active_symbol_table)) { - EX(CVs)[op_array->this_var] = (zval **) EX(CVs) + op_array->last_var + op_array->this_var; - *EX(CVs)[op_array->this_var] = EG(This); + EX_CV(op_array->this_var) = (zval **) EX_CV_NUM(execute_data, op_array->last_var + op_array->this_var); + *EX_CV(op_array->this_var) = EG(This); } else { - if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) &EX(CVs)[op_array->this_var])==FAILURE) { + if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) EX_CV_NUM(execute_data, op_array->this_var))==FAILURE) { Z_DELREF_P(EG(This)); } } diff --git a/Zend/zend_vm_gen.php b/Zend/zend_vm_gen.php index bd5f2dede5386..6c9dcafba7213 100644 --- a/Zend/zend_vm_gen.php +++ b/Zend/zend_vm_gen.php @@ -118,75 +118,75 @@ ); $op1_get_zval_ptr = array( - "ANY" => "get_zval_ptr(opline->op1_type, &opline->op1, EX_Ts(), &free_op1, \\1)", - "TMP" => "_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC)", - "VAR" => "_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC)", + "ANY" => "get_zval_ptr(opline->op1_type, &opline->op1, execute_data, &free_op1, \\1)", + "TMP" => "_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)", "CONST" => "opline->op1.zv", "UNUSED" => "NULL", - "CV" => "_get_zval_ptr_cv_\\1(EX_CVs(), opline->op1.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_cv_\\1(execute_data, opline->op1.var TSRMLS_CC)", ); $op2_get_zval_ptr = array( - "ANY" => "get_zval_ptr(opline->op2_type, &opline->op2, EX_Ts(), &free_op2, \\1)", - "TMP" => "_get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC)", - "VAR" => "_get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC)", + "ANY" => "get_zval_ptr(opline->op2_type, &opline->op2, execute_data, &free_op2, \\1)", + "TMP" => "_get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC)", "CONST" => "opline->op2.zv", "UNUSED" => "NULL", - "CV" => "_get_zval_ptr_cv_\\1(EX_CVs(), opline->op2.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_cv_\\1(execute_data, opline->op2.var TSRMLS_CC)", ); $op1_get_zval_ptr_ptr = array( - "ANY" => "get_zval_ptr_ptr(opline->op1_type, &opline->op1, EX_Ts(), &free_op1, \\1)", + "ANY" => "get_zval_ptr_ptr(opline->op1_type, &opline->op1, execute_data, &free_op1, \\1)", "TMP" => "NULL", - "VAR" => "_get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)", "CONST" => "NULL", "UNUSED" => "NULL", - "CV" => "_get_zval_ptr_ptr_cv_\\1(EX_CVs(), opline->op1.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_ptr_cv_\\1(execute_data, opline->op1.var TSRMLS_CC)", ); $op2_get_zval_ptr_ptr = array( - "ANY" => "get_zval_ptr_ptr(opline->op2_type, &opline->op2, EX_Ts(), &free_op2, \\1)", + "ANY" => "get_zval_ptr_ptr(opline->op2_type, &opline->op2, execute_data, &free_op2, \\1)", "TMP" => "NULL", - "VAR" => "_get_zval_ptr_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC)", "CONST" => "NULL", "UNUSED" => "NULL", - "CV" => "_get_zval_ptr_ptr_cv_\\1(EX_CVs(), opline->op2.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_ptr_cv_\\1(execute_data, opline->op2.var TSRMLS_CC)", ); $op1_get_obj_zval_ptr = array( - "ANY" => "get_obj_zval_ptr(opline->op1_type, &opline->op1, EX_Ts(), &free_op1, \\1)", - "TMP" => "_get_zval_ptr_tmp(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC)", - "VAR" => "_get_zval_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC)", + "ANY" => "get_obj_zval_ptr(opline->op1_type, &opline->op1, execute_data, &free_op1, \\1)", + "TMP" => "_get_zval_ptr_tmp(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)", "CONST" => "opline->op1.zv", "UNUSED" => "_get_obj_zval_ptr_unused(TSRMLS_C)", - "CV" => "_get_zval_ptr_cv_\\1(EX_CVs(), opline->op1.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_cv_\\1(execute_data, opline->op1.var TSRMLS_CC)", ); $op2_get_obj_zval_ptr = array( - "ANY" => "get_obj_zval_ptr(opline->op2_type, &opline->op2, EX_Ts(), &free_op2, \\1)", - "TMP" => "_get_zval_ptr_tmp(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC)", - "VAR" => "_get_zval_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC)", + "ANY" => "get_obj_zval_ptr(opline->op2_type, &opline->op2, execute_data, &free_op2, \\1)", + "TMP" => "_get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC)", "CONST" => "opline->op2.zv", "UNUSED" => "_get_obj_zval_ptr_unused(TSRMLS_C)", - "CV" => "_get_zval_ptr_cv_\\1(EX_CVs(), opline->op2.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_cv_\\1(execute_data, opline->op2.var TSRMLS_CC)", ); $op1_get_obj_zval_ptr_ptr = array( - "ANY" => "get_obj_zval_ptr_ptr(opline->op1_type, &opline->op1, EX_Ts(), &free_op1, \\1)", + "ANY" => "get_obj_zval_ptr_ptr(opline->op1_type, &opline->op1, execute_data, &free_op1, \\1)", "TMP" => "NULL", - "VAR" => "_get_zval_ptr_ptr_var(opline->op1.var, EX_Ts(), &free_op1 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC)", "CONST" => "NULL", "UNUSED" => "_get_obj_zval_ptr_ptr_unused(TSRMLS_C)", - "CV" => "_get_zval_ptr_ptr_cv_\\1(EX_CVs(), opline->op1.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_ptr_cv_\\1(execute_data, opline->op1.var TSRMLS_CC)", ); $op2_get_obj_zval_ptr_ptr = array( - "ANY" => "get_obj_zval_ptr_ptr(opline->op2_type, &opline->op2, EX_Ts(), &free_op2, \\1)", + "ANY" => "get_obj_zval_ptr_ptr(opline->op2_type, &opline->op2, execute_data, &free_op2, \\1)", "TMP" => "NULL", - "VAR" => "_get_zval_ptr_ptr_var(opline->op2.var, EX_Ts(), &free_op2 TSRMLS_CC)", + "VAR" => "_get_zval_ptr_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC)", "CONST" => "NULL", "UNUSED" => "_get_obj_zval_ptr_ptr_unused(TSRMLS_C)", - "CV" => "_get_zval_ptr_ptr_cv_\\1(EX_CVs(), opline->op2.var TSRMLS_CC)", + "CV" => "_get_zval_ptr_ptr_cv_\\1(execute_data, opline->op2.var TSRMLS_CC)", ); $op1_is_tmp_free = array( @@ -841,14 +841,6 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC\n"); out($f,"#undef EX\n"); out($f,"#define EX(element) execute_data->element\n\n"); - out($f,"#undef EX_CV\n"); - out($f,"#define EX_CV(var) EX(CVs)[var]\n"); - out($f,"#undef EX_CVs\n"); - out($f,"#define EX_CVs() EX(CVs)\n"); - out($f,"#undef EX_T\n"); - out($f,"#define EX_T(offset) (*(temp_variable *)((char *) EX(Ts) + offset))\n"); - out($f,"#undef EX_Ts\n"); - out($f,"#define EX_Ts() EX(Ts)\n\n"); break; case ZEND_VM_KIND_SWITCH: out($f,"\n"); @@ -868,7 +860,7 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define CHECK_EXCEPTION() LOAD_OPLINE()\n"); out($f,"#define HANDLE_EXCEPTION() LOAD_OPLINE(); ZEND_VM_CONTINUE()\n"); out($f,"#define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE()\n"); - out($f,"#define LOAD_REGS() do {Ts = EX(Ts); CVs = EX(CVs);} while (0)\n"); + out($f,"#define LOAD_REGS()\n"); out($f,"#define ZEND_VM_CONTINUE() goto zend_vm_continue\n"); out($f,"#define ZEND_VM_RETURN() EG(in_execution) = original_in_execution; return\n"); out($f,"#define ZEND_VM_ENTER() execute_data = zend_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); LOAD_REGS(); LOAD_OPLINE(); ZEND_VM_CONTINUE()\n"); @@ -877,14 +869,6 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC\n"); out($f,"#undef EX\n"); out($f,"#define EX(element) execute_data->element\n\n"); - out($f,"#undef EX_CV\n"); - out($f,"#define EX_CV(var) CVs[var]\n"); - out($f,"#undef EX_CVs\n"); - out($f,"#define EX_CVs() CVs\n"); - out($f,"#undef EX_T\n"); - out($f,"#define EX_T(offset) T(offset)\n"); - out($f,"#undef EX_Ts\n"); - out($f,"#define EX_Ts() Ts\n\n"); break; case ZEND_VM_KIND_GOTO: out($f,"\n"); @@ -904,7 +888,7 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define CHECK_EXCEPTION() if (UNEXPECTED(EG(exception) != NULL)) goto ZEND_HANDLE_EXCEPTION_SPEC_HANDLER\n"); out($f,"#define HANDLE_EXCEPTION() goto ZEND_HANDLE_EXCEPTION_SPEC_HANDLER\n"); out($f,"#define HANDLE_EXCEPTION_LEAVE() goto ZEND_HANDLE_EXCEPTION_SPEC_HANDLER\n"); - out($f,"#define LOAD_REGS() do {Ts = EX(Ts); CVs = EX(CVs);} while (0)\n"); + out($f,"#define LOAD_REGS()\n"); out($f,"#define ZEND_VM_CONTINUE() goto *(void**)(OPLINE->handler)\n"); out($f,"#define ZEND_VM_RETURN() EG(in_execution) = original_in_execution; return\n"); out($f,"#define ZEND_VM_ENTER() execute_data = zend_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); LOAD_REGS(); LOAD_OPLINE(); ZEND_VM_CONTINUE()\n"); @@ -913,14 +897,6 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC\n"); out($f,"#undef EX\n"); out($f,"#define EX(element) execute_data->element\n\n"); - out($f,"#undef EX_CV\n"); - out($f,"#define EX_CV(var) CVs[var]\n"); - out($f,"#undef EX_CVs\n"); - out($f,"#define EX_CVs() CVs\n"); - out($f,"#undef EX_T\n"); - out($f,"#define EX_T(offset) T(offset)\n\n"); - out($f,"#undef EX_Ts\n"); - out($f,"#define EX_Ts() Ts\n\n"); break; } break; @@ -929,8 +905,6 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, break; case "HELPER_VARS": if ($kind != ZEND_VM_KIND_CALL) { - out($f,$m[1]."temp_variable *Ts;\n"); - out($f,$m[1]."zval ***CVs;\n"); if ($kind == ZEND_VM_KIND_SWITCH) { out($f,$m[1]."opcode_handler_t dispatch_handler;\n"); } @@ -1243,12 +1217,6 @@ function gen_vm($def, $skel) { out($f,"\n/* Old executor */\n\n"); out($f,"#undef EX\n"); out($f,"#define EX(element) execute_data.element\n\n"); - out($f,"#undef EX_CV\n"); - out($f,"#define EX_CV(var) EX(CVs)[var]\n"); - out($f,"#undef EX_CVs\n"); - out($f,"#define EX_CVs() EX(CVs)\n"); - out($f,"#undef EX_T\n"); - out($f,"#define EX_T(offset) (*(temp_variable *)((char *) EX(Ts) + offset))\n\n"); out($f,"#undef ZEND_VM_CONTINUE\n\n"); out($f,"#undef ZEND_VM_RETURN\n\n"); out($f,"#undef ZEND_VM_ENTER\n\n"); @@ -1323,12 +1291,6 @@ function gen_vm($def, $skel) { out($f,"#define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE()\n"); out($f,"#undef EX\n"); out($f,"#define EX(element) execute_data->element\n\n"); - out($f,"#undef EX_CV\n"); - out($f,"#define EX_CV(var) EX(CVs)[var]\n"); - out($f,"#undef EX_CVs\n"); - out($f,"#define EX_CVs() EX(CVs)\n"); - out($f,"#undef EX_T\n"); - out($f,"#define EX_T(offset) (*(temp_variable *)((char *) EX(Ts) + offset))\n\n"); out($f,"#undef ZEND_VM_CONTINUE\n"); out($f,"#undef ZEND_VM_RETURN\n"); out($f,"#undef ZEND_VM_ENTER\n"); From 61dbf35cfced88201050484a31785183209e1b4f Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 4 Dec 2012 10:42:19 +0400 Subject: [PATCH 2186/2394] Moved zend_create_execute_data_from_op_array() implementation from zend_vm_execute.skl to zend_execute.c --- Zend/zend_execute.c | 151 +++++++++++++++++++++++++++++++++++++++ Zend/zend_vm_execute.h | 150 -------------------------------------- Zend/zend_vm_execute.skl | 150 -------------------------------------- 3 files changed, 151 insertions(+), 300 deletions(-) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index e5198ebfcb7cc..1c8e61cc3add9 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1569,6 +1569,157 @@ void zend_free_compiled_variables(zend_execute_data *execute_data) /* {{{ */ } /* }}} */ +/* + * Stack Frame Layout (the whole stack frame is allocated at once) + * ================== + * + * +========================================+ + * | zend_execute_data |<---+ + * | EX(function_state).arguments |--+ | + * | ... | | | + * | ARGUMENT [1] | | | + * | ... | | | + * | ARGUMENT [ARGS_NUMBER] | | | + * | ARGS_NUMBER |<-+ | + * +========================================+ | + * | + * +========================================+ | + * | TMP_VAR[op_arrat->T-1] | | + * | ... | | + * EX_TMP_VAR_NUM(0) ----> | TMP_VAR[0] | | + * +----------------------------------------+ | + * EG(current_execute_data) -> | zend_execute_data | | + * | EX(prev_execute_data) |----+ + * +----------------------------------------+ + * EX_CV_NUM(0) ---------> | CV[0] |--+ + * | ... | | + * | CV[op_array->last_var-1] | | + * +----------------------------------------+ | + * | Optional slot for CV[0] zval* |<-+ + * | ... | + * | ...for CV [op_array->last_var-1] zval* | + * +----------------------------------------+ + * EX(call_slots) -> | CALL_SLOT[0] | + * | ... | + * | CALL_SLOT[op_array->nested_calls-1] | + * +----------------------------------------+ + * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | + * | ... | + * zend_vm_stack_top --------> | ... | + * | ... | + * | ARGUMENTS STACK [op_array->used_stack] | + * +----------------------------------------+ + */ + +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) /* {{{ */ +{ + zend_execute_data *execute_data; + + /* + * When allocating the execute_data, memory for compiled variables and + * temporary variables is also allocated after the actual zend_execute_data + * struct. op_array->last_var specifies the number of compiled variables and + * op_array->T is the number of temporary variables. If there is no symbol + * table, then twice as much memory is allocated for compiled variables. + * In that case the first half contains zval**s and the second half the + * actual zval*s (which would otherwise be in the symbol table). + */ + size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); + size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (EG(active_symbol_table) ? 1 : 2)); + size_t Ts_size = ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T; + size_t call_slots_size = ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * op_array->nested_calls; + size_t stack_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * op_array->used_stack; + size_t total_size = execute_data_size + Ts_size + CVs_size + call_slots_size + stack_size; + + /* + * Normally the execute_data is allocated on the VM stack (because it does + * not actually do any allocation and thus is faster). For generators + * though this behavior would be suboptimal, because the (rather large) + * structure would have to be copied back and forth every time execution is + * suspended or resumed. That's why for generators the execution context + * is allocated using emalloc, thus allowing to save and restore it simply + * by replacing a pointer. + */ + if (op_array->fn_flags & ZEND_ACC_GENERATOR) { + /* Prepend the regular stack frame with copy on prev_execute_data + * and passed arguments + */ + int args_count = zend_vm_stack_get_args_count_ex(EG(current_execute_data)); + size_t args_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (args_count + 1); + + total_size += args_size + execute_data_size; + + EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); + EG(argument_stack)->prev = NULL; + execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size + Ts_size); + + /* copy prev_execute_data */ + EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); + memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); + EX(prev_execute_data)->function_state.function = (zend_function*)op_array; + EX(prev_execute_data)->function_state.arguments = (void**)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * args_count); + + /* copy arguemnts */ + *EX(prev_execute_data)->function_state.arguments = (void*)(zend_uintptr_t)args_count; + if (args_count > 0) { + zval **arg_src = (zval**)zend_vm_stack_get_arg_ex(EG(current_execute_data), 1); + zval **arg_dst = (zval**)zend_vm_stack_get_arg_ex(EX(prev_execute_data), 1); + int i; + + for (i = 0; i < args_count; i++) { + arg_dst[i] = arg_src[i]; + Z_ADDREF_P(arg_dst[i]); + } + } + } else { + execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); + execute_data = (zend_execute_data*)((char*)execute_data + Ts_size); + EX(prev_execute_data) = EG(current_execute_data); + } + + memset(EX_CV_NUM(execute_data, 0), 0, sizeof(zval **) * op_array->last_var); + + EX(call_slots) = (call_slot*)((char *)execute_data + execute_data_size + CVs_size); + + + EX(op_array) = op_array; + + EG(argument_stack)->top = zend_vm_stack_frame_base(execute_data); + + EX(object) = NULL; + EX(current_this) = NULL; + EX(old_error_reporting) = NULL; + EX(symbol_table) = EG(active_symbol_table); + EX(call) = NULL; + EG(current_execute_data) = execute_data; + EX(nested) = nested; + + if (!op_array->run_time_cache && op_array->last_cache_slot) { + op_array->run_time_cache = ecalloc(op_array->last_cache_slot, sizeof(void*)); + } + + if (op_array->this_var != -1 && EG(This)) { + Z_ADDREF_P(EG(This)); /* For $this pointer */ + if (!EG(active_symbol_table)) { + EX_CV(op_array->this_var) = (zval **) EX_CV_NUM(execute_data, op_array->last_var + op_array->this_var); + *EX_CV(op_array->this_var) = EG(This); + } else { + if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) EX_CV_NUM(execute_data, op_array->this_var))==FAILURE) { + Z_DELREF_P(EG(This)); + } + } + } + + EX(opline) = UNEXPECTED((op_array->fn_flags & ZEND_ACC_INTERACTIVE) != 0) && EG(start_op) ? EG(start_op) : op_array->opcodes; + EG(opline_ptr) = &EX(opline); + + EX(function_state).function = (zend_function *) op_array; + EX(function_state).arguments = NULL; + + return execute_data; +} +/* }}} */ + /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index eeb6a058efc94..bce82ac4e5aef 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -330,156 +330,6 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #define EX(element) execute_data->element -/* - * Stack Frame Layout (the whole stack frame is allocated at once) - * ================== - * - * +========================================+ - * | zend_execute_data |<---+ - * | EX(function_state).arguments |--+ | - * | ... | | | - * | ARGUMENT [1] | | | - * | ... | | | - * | ARGUMENT [ARGS_NUMBER] | | | - * | ARGS_NUMBER |<-+ | - * +========================================+ | - * | - * +========================================+ | - * | TMP_VAR[op_arrat->T-1] | | - * | ... | | - * EX_TMP_VAR_NUM(0) ----> | TMP_VAR[0] | | - * +----------------------------------------+ | - * EG(current_execute_data) -> | zend_execute_data | | - * | EX(prev_execute_data) |----+ - * +----------------------------------------+ - * EX_CV_NUM(0) ---------> | CV[0] |--+ - * | ... | | - * | CV[op_array->last_var-1] | | - * +----------------------------------------+ | - * | Optional slot for CV[0] zval* |<-+ - * | ... | - * | ...for CV [op_array->last_var-1] zval* | - * +----------------------------------------+ - * EX(call_slots) -> | CALL_SLOT[0] | - * | ... | - * | CALL_SLOT[op_array->nested_calls-1] | - * +----------------------------------------+ - * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | - * | ... | - * zend_vm_stack_top --------> | ... | - * | ... | - * | ARGUMENTS STACK [op_array->used_stack] | - * +----------------------------------------+ - */ - -zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) -{ - zend_execute_data *execute_data; - - /* - * When allocating the execute_data, memory for compiled variables and - * temporary variables is also allocated after the actual zend_execute_data - * struct. op_array->last_var specifies the number of compiled variables and - * op_array->T is the number of temporary variables. If there is no symbol - * table, then twice as much memory is allocated for compiled variables. - * In that case the first half contains zval**s and the second half the - * actual zval*s (which would otherwise be in the symbol table). - */ - size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); - size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (EG(active_symbol_table) ? 1 : 2)); - size_t Ts_size = ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T; - size_t call_slots_size = ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * op_array->nested_calls; - size_t stack_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * op_array->used_stack; - size_t total_size = execute_data_size + Ts_size + CVs_size + call_slots_size + stack_size; - - /* - * Normally the execute_data is allocated on the VM stack (because it does - * not actually do any allocation and thus is faster). For generators - * though this behavior would be suboptimal, because the (rather large) - * structure would have to be copied back and forth every time execution is - * suspended or resumed. That's why for generators the execution context - * is allocated using emalloc, thus allowing to save and restore it simply - * by replacing a pointer. - */ - if (op_array->fn_flags & ZEND_ACC_GENERATOR) { - /* Prepend the regular stack frame with copy on prev_execute_data - * and passed arguments - */ - int args_count = zend_vm_stack_get_args_count_ex(EG(current_execute_data)); - size_t args_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (args_count + 1); - - total_size += args_size + execute_data_size; - - EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); - EG(argument_stack)->prev = NULL; - execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size + Ts_size); - - /* copy prev_execute_data */ - EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); - memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); - EX(prev_execute_data)->function_state.function = (zend_function*)op_array; - EX(prev_execute_data)->function_state.arguments = (void**)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * args_count); - - /* copy arguemnts */ - *EX(prev_execute_data)->function_state.arguments = (void*)(zend_uintptr_t)args_count; - if (args_count > 0) { - zval **arg_src = (zval**)zend_vm_stack_get_arg_ex(EG(current_execute_data), 1); - zval **arg_dst = (zval**)zend_vm_stack_get_arg_ex(EX(prev_execute_data), 1); - int i; - - for (i = 0; i < args_count; i++) { - arg_dst[i] = arg_src[i]; - Z_ADDREF_P(arg_dst[i]); - } - } - } else { - execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); - execute_data = (zend_execute_data*)((char*)execute_data + Ts_size); - EX(prev_execute_data) = EG(current_execute_data); - } - - memset(EX_CV_NUM(execute_data, 0), 0, sizeof(zval **) * op_array->last_var); - - EX(call_slots) = (call_slot*)((char *)execute_data + execute_data_size + CVs_size); - - - EX(op_array) = op_array; - - EG(argument_stack)->top = zend_vm_stack_frame_base(execute_data); - - EX(object) = NULL; - EX(current_this) = NULL; - EX(old_error_reporting) = NULL; - EX(symbol_table) = EG(active_symbol_table); - EX(call) = NULL; - EG(current_execute_data) = execute_data; - EX(nested) = nested; - - if (!op_array->run_time_cache && op_array->last_cache_slot) { - op_array->run_time_cache = ecalloc(op_array->last_cache_slot, sizeof(void*)); - } - - if (op_array->this_var != -1 && EG(This)) { - Z_ADDREF_P(EG(This)); /* For $this pointer */ - if (!EG(active_symbol_table)) { - EX_CV(op_array->this_var) = (zval **) EX_CV_NUM(execute_data, op_array->last_var + op_array->this_var); - *EX_CV(op_array->this_var) = EG(This); - } else { - if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) EX_CV_NUM(execute_data, op_array->this_var))==FAILURE) { - Z_DELREF_P(EG(This)); - } - } - } - - EX(opline) = UNEXPECTED((op_array->fn_flags & ZEND_ACC_INTERACTIVE) != 0) && EG(start_op) ? EG(start_op) : op_array->opcodes; - EG(opline_ptr) = &EX(opline); - - EX(function_state).function = (zend_function *) op_array; - EX(function_state).arguments = NULL; - - return execute_data; -} - ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) { DCL_OPLINE diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index 63f83491127af..eb18580b21948 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -1,155 +1,5 @@ {%DEFINES%} -/* - * Stack Frame Layout (the whole stack frame is allocated at once) - * ================== - * - * +========================================+ - * | zend_execute_data |<---+ - * | EX(function_state).arguments |--+ | - * | ... | | | - * | ARGUMENT [1] | | | - * | ... | | | - * | ARGUMENT [ARGS_NUMBER] | | | - * | ARGS_NUMBER |<-+ | - * +========================================+ | - * | - * +========================================+ | - * | TMP_VAR[op_arrat->T-1] | | - * | ... | | - * EX_TMP_VAR_NUM(0) ----> | TMP_VAR[0] | | - * +----------------------------------------+ | - * EG(current_execute_data) -> | zend_execute_data | | - * | EX(prev_execute_data) |----+ - * +----------------------------------------+ - * EX_CV_NUM(0) ---------> | CV[0] |--+ - * | ... | | - * | CV[op_array->last_var-1] | | - * +----------------------------------------+ | - * | Optional slot for CV[0] zval* |<-+ - * | ... | - * | ...for CV [op_array->last_var-1] zval* | - * +----------------------------------------+ - * EX(call_slots) -> | CALL_SLOT[0] | - * | ... | - * | CALL_SLOT[op_array->nested_calls-1] | - * +----------------------------------------+ - * zend_vm_stack_frame_base -> | ARGUMENTS STACK [0] | - * | ... | - * zend_vm_stack_top --------> | ... | - * | ... | - * | ARGUMENTS STACK [op_array->used_stack] | - * +----------------------------------------+ - */ - -zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) -{ - zend_execute_data *execute_data; - - /* - * When allocating the execute_data, memory for compiled variables and - * temporary variables is also allocated after the actual zend_execute_data - * struct. op_array->last_var specifies the number of compiled variables and - * op_array->T is the number of temporary variables. If there is no symbol - * table, then twice as much memory is allocated for compiled variables. - * In that case the first half contains zval**s and the second half the - * actual zval*s (which would otherwise be in the symbol table). - */ - size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); - size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (EG(active_symbol_table) ? 1 : 2)); - size_t Ts_size = ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T; - size_t call_slots_size = ZEND_MM_ALIGNED_SIZE(sizeof(call_slot)) * op_array->nested_calls; - size_t stack_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * op_array->used_stack; - size_t total_size = execute_data_size + Ts_size + CVs_size + call_slots_size + stack_size; - - /* - * Normally the execute_data is allocated on the VM stack (because it does - * not actually do any allocation and thus is faster). For generators - * though this behavior would be suboptimal, because the (rather large) - * structure would have to be copied back and forth every time execution is - * suspended or resumed. That's why for generators the execution context - * is allocated using emalloc, thus allowing to save and restore it simply - * by replacing a pointer. - */ - if (op_array->fn_flags & ZEND_ACC_GENERATOR) { - /* Prepend the regular stack frame with copy on prev_execute_data - * and passed arguments - */ - int args_count = zend_vm_stack_get_args_count_ex(EG(current_execute_data)); - size_t args_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (args_count + 1); - - total_size += args_size + execute_data_size; - - EG(argument_stack) = zend_vm_stack_new_page((total_size + (sizeof(void*) - 1)) / sizeof(void*)); - EG(argument_stack)->prev = NULL; - execute_data = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size + execute_data_size + Ts_size); - - /* copy prev_execute_data */ - EX(prev_execute_data) = (zend_execute_data*)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + args_size); - memset(EX(prev_execute_data), 0, sizeof(zend_execute_data)); - EX(prev_execute_data)->function_state.function = (zend_function*)op_array; - EX(prev_execute_data)->function_state.arguments = (void**)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * args_count); - - /* copy arguemnts */ - *EX(prev_execute_data)->function_state.arguments = (void*)(zend_uintptr_t)args_count; - if (args_count > 0) { - zval **arg_src = (zval**)zend_vm_stack_get_arg_ex(EG(current_execute_data), 1); - zval **arg_dst = (zval**)zend_vm_stack_get_arg_ex(EX(prev_execute_data), 1); - int i; - - for (i = 0; i < args_count; i++) { - arg_dst[i] = arg_src[i]; - Z_ADDREF_P(arg_dst[i]); - } - } - } else { - execute_data = zend_vm_stack_alloc(total_size TSRMLS_CC); - execute_data = (zend_execute_data*)((char*)execute_data + Ts_size); - EX(prev_execute_data) = EG(current_execute_data); - } - - memset(EX_CV_NUM(execute_data, 0), 0, sizeof(zval **) * op_array->last_var); - - EX(call_slots) = (call_slot*)((char *)execute_data + execute_data_size + CVs_size); - - - EX(op_array) = op_array; - - EG(argument_stack)->top = zend_vm_stack_frame_base(execute_data); - - EX(object) = NULL; - EX(current_this) = NULL; - EX(old_error_reporting) = NULL; - EX(symbol_table) = EG(active_symbol_table); - EX(call) = NULL; - EG(current_execute_data) = execute_data; - EX(nested) = nested; - - if (!op_array->run_time_cache && op_array->last_cache_slot) { - op_array->run_time_cache = ecalloc(op_array->last_cache_slot, sizeof(void*)); - } - - if (op_array->this_var != -1 && EG(This)) { - Z_ADDREF_P(EG(This)); /* For $this pointer */ - if (!EG(active_symbol_table)) { - EX_CV(op_array->this_var) = (zval **) EX_CV_NUM(execute_data, op_array->last_var + op_array->this_var); - *EX_CV(op_array->this_var) = EG(This); - } else { - if (zend_hash_add(EG(active_symbol_table), "this", sizeof("this"), &EG(This), sizeof(zval *), (void **) EX_CV_NUM(execute_data, op_array->this_var))==FAILURE) { - Z_DELREF_P(EG(This)); - } - } - } - - EX(opline) = UNEXPECTED((op_array->fn_flags & ZEND_ACC_INTERACTIVE) != 0) && EG(start_op) ? EG(start_op) : op_array->opcodes; - EG(opline_ptr) = &EX(opline); - - EX(function_state).function = (zend_function *) op_array; - EX(function_state).arguments = NULL; - - return execute_data; -} - ZEND_API void {%EXECUTOR_NAME%}_ex(zend_execute_data *execute_data TSRMLS_DC) { DCL_OPLINE From 9e39a636da13dbe6e42a01df1c9be1a55534e720 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 4 Dec 2012 10:48:09 +0400 Subject: [PATCH 2187/2394] Increased version numbers --- Zend/zend_extensions.h | 2 +- Zend/zend_modules.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/zend_extensions.h b/Zend/zend_extensions.h index 17804cb740e2b..5be6be62a6b66 100644 --- a/Zend/zend_extensions.h +++ b/Zend/zend_extensions.h @@ -28,7 +28,7 @@ /* The first number is the engine version and the rest is the date. * This way engine 2/3 API no. is always greater than engine 1 API no.. */ -#define ZEND_EXTENSION_API_NO 220121128 +#define ZEND_EXTENSION_API_NO 220121204 typedef struct _zend_extension_version_info { int zend_extension_api_no; diff --git a/Zend/zend_modules.h b/Zend/zend_modules.h index bfea3e0d225e7..b4ad648c795ee 100644 --- a/Zend/zend_modules.h +++ b/Zend/zend_modules.h @@ -33,7 +33,7 @@ #define ZEND_MODULE_INFO_FUNC_ARGS zend_module_entry *zend_module TSRMLS_DC #define ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU zend_module TSRMLS_CC -#define ZEND_MODULE_API_NO 20121128 +#define ZEND_MODULE_API_NO 20121204 #ifdef ZTS #define USING_ZTS 1 #else From 3de00bc6152cec1c017877aca75bc92e4a034585 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Mon, 3 Dec 2012 12:21:32 +0100 Subject: [PATCH 2188/2394] Enable dtrace probes on linux as they are compatible with systemtap You can build php with dtrace probes enabled on linux if you have systemtap with uprobes. --- acinclude.m4 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/acinclude.m4 b/acinclude.m4 index ad4f7474b385a..2085f0bb5b88a 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2932,6 +2932,9 @@ dnl Add providerdesc.o into global objects when needed *solaris*) PHP_GLOBAL_OBJS="[$]PHP_GLOBAL_OBJS [$]ac_bdir[$]ac_provsrc.o" ;; + *linux*) + PHP_GLOBAL_OBJS="[$]PHP_GLOBAL_OBJS [$]ac_bdir[$]ac_provsrc.o" + ;; esac dnl DTrace objects From 15a251a424918e0242fb868a063353e250d8f89f Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 4 Dec 2012 21:01:32 +0100 Subject: [PATCH 2189/2394] Overwrite execute_ex instead of execute in dtrace_execute --- Zend/zend_dtrace.c | 4 ++-- Zend/zend_dtrace.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_dtrace.c b/Zend/zend_dtrace.c index 3d109deabd96d..4e857a1862844 100644 --- a/Zend/zend_dtrace.c +++ b/Zend/zend_dtrace.c @@ -44,7 +44,7 @@ ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int t } /* We wrap the execute function to have fire the execute-entry/return and function-entry/return probes */ -ZEND_API void dtrace_execute(zend_op_array *op_array TSRMLS_DC) +ZEND_API void dtrace_execute_ex(zend_op_array *op_array TSRMLS_DC) { int lineno; char *scope, *filename, *funcname, *classname; @@ -72,7 +72,7 @@ ZEND_API void dtrace_execute(zend_op_array *op_array TSRMLS_DC) DTRACE_FUNCTION_ENTRY(funcname, filename, lineno, classname, scope); } - execute(op_array TSRMLS_CC); + execute_ex(op_array TSRMLS_CC); if (DTRACE_FUNCTION_RETURN_ENABLED() && funcname != NULL) { DTRACE_FUNCTION_RETURN(funcname, filename, lineno, classname, scope); diff --git a/Zend/zend_dtrace.h b/Zend/zend_dtrace.h index 49388e562f7ff..73c884528137c 100644 --- a/Zend/zend_dtrace.h +++ b/Zend/zend_dtrace.h @@ -35,7 +35,7 @@ ZEND_API void (*zend_dtrace_execute)(zend_op_array *op_array TSRMLS_DC); ZEND_API void (*zend_dtrace_execute_internal)(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int type TSRMLS_DC); -ZEND_API void dtrace_execute(zend_op_array *op_array TSRMLS_DC); +ZEND_API void dtrace_execute_ex(zend_op_array *op_array TSRMLS_DC); ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); #include From 288f8734f6eeae88ce9201295c22a7848d14e2ca Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 5 Dec 2012 00:45:23 +0100 Subject: [PATCH 2190/2394] Pass zend_execute_data instead of zend_op_array --- Zend/zend_dtrace.c | 4 ++-- Zend/zend_dtrace.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_dtrace.c b/Zend/zend_dtrace.c index 4e857a1862844..165172ad1eb4f 100644 --- a/Zend/zend_dtrace.c +++ b/Zend/zend_dtrace.c @@ -44,7 +44,7 @@ ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int t } /* We wrap the execute function to have fire the execute-entry/return and function-entry/return probes */ -ZEND_API void dtrace_execute_ex(zend_op_array *op_array TSRMLS_DC) +ZEND_API void dtrace_execute_ex(zend_execute_data *execute_data TSRMLS_DC) { int lineno; char *scope, *filename, *funcname, *classname; @@ -72,7 +72,7 @@ ZEND_API void dtrace_execute_ex(zend_op_array *op_array TSRMLS_DC) DTRACE_FUNCTION_ENTRY(funcname, filename, lineno, classname, scope); } - execute_ex(op_array TSRMLS_CC); + execute_ex(execute_data TSRMLS_CC); if (DTRACE_FUNCTION_RETURN_ENABLED() && funcname != NULL) { DTRACE_FUNCTION_RETURN(funcname, filename, lineno, classname, scope); diff --git a/Zend/zend_dtrace.h b/Zend/zend_dtrace.h index 73c884528137c..26008afb6b36a 100644 --- a/Zend/zend_dtrace.h +++ b/Zend/zend_dtrace.h @@ -35,7 +35,7 @@ ZEND_API void (*zend_dtrace_execute)(zend_op_array *op_array TSRMLS_DC); ZEND_API void (*zend_dtrace_execute_internal)(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); ZEND_API zend_op_array *dtrace_compile_file(zend_file_handle *file_handle, int type TSRMLS_DC); -ZEND_API void dtrace_execute_ex(zend_op_array *op_array TSRMLS_DC); +ZEND_API void dtrace_execute_ex(zend_execute_data *execute_data TSRMLS_DC); ZEND_API void dtrace_execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_info *fci, int return_value_used TSRMLS_DC); #include From 86bf83dcf2dcb4a8b89519997765d2b0674247f9 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 5 Dec 2012 00:54:36 +0100 Subject: [PATCH 2191/2394] News for enabling systemtap support on linux --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index d8646f1684f2d..984b2bf5abd41 100644 --- a/NEWS +++ b/NEWS @@ -25,6 +25,8 @@ PHP NEWS (Nikita Popov) . Remove php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), zend_logo_guid(). (Adnrew Faulds) + . Add systemtap support by enabling systemtap compatible dtrace probes on + linux. (David Soria Parra) - Calendar: . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) From fa30e4754bea0d0c6a048ca029c543ddcaf3b84f Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 5 Dec 2012 13:23:37 +0400 Subject: [PATCH 2192/2394] Slight performance improvement --- UPGRADING | 2 +- Zend/zend_execute.c | 143 ++++++++++++++++++++++----------------- Zend/zend_vm_def.h | 4 +- Zend/zend_vm_execute.h | 16 +++-- Zend/zend_vm_execute.skl | 7 +- Zend/zend_vm_gen.php | 16 +---- 6 files changed, 101 insertions(+), 87 deletions(-) diff --git a/UPGRADING b/UPGRADING index 170c6de51da5b..b01a399697b39 100755 --- a/UPGRADING +++ b/UPGRADING @@ -54,7 +54,7 @@ PHP 5.5 UPGRADE NOTES stores new offsets in op_array->opcodes[*].op?.num. You can use macros EX_TMP_VAR() and EX_TMP_VAR_NUM() to access temp_variable by offset or number. You can convert number to offset using EX_TMP_VAR_NUM(0, num) or - offset to number (EX_TMP_VAR(0,offset)-EX_TMP_VAR_NUM(0,0)). + offset to number (EX_TMP_VAR_NUM(0,0)-EX_TMP_VAR(0,offset)). - Removed execute_data->CVs field. The VM compiled variables always allocated immediately after execute_data structure. Now they are accessed by offset from the execute_data base pointer (instead of execute_data->CVs). You can diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 1c8e61cc3add9..d260953bd7ac4 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -167,6 +167,9 @@ static zend_always_inline void zend_pzval_unlock_free_func(zval *z TSRMLS_DC) #define DECODE_CTOR(ce) \ ((zend_class_entry*)(((zend_uintptr_t)(ce)) & ~(CTOR_CALL_BIT|CTOR_USED_BIT))) +#undef EX +#define EX(element) execute_data->element + ZEND_API zval** zend_get_compiled_variable_value(const zend_execute_data *execute_data, zend_uint var) { return EX_CV(var); @@ -1488,62 +1491,6 @@ ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, zend_fcall_i } } -#define ZEND_VM_NEXT_OPCODE() \ - CHECK_SYMBOL_TABLES() \ - ZEND_VM_INC_OPCODE(); \ - ZEND_VM_CONTINUE() - -#define ZEND_VM_SET_OPCODE(new_op) \ - CHECK_SYMBOL_TABLES() \ - OPLINE = new_op - -#define ZEND_VM_JMP(new_op) \ - if (EXPECTED(!EG(exception))) { \ - ZEND_VM_SET_OPCODE(new_op); \ - } else { \ - LOAD_OPLINE(); \ - } \ - ZEND_VM_CONTINUE() - -#define ZEND_VM_INC_OPCODE() \ - OPLINE++ - -#ifdef __GNUC__ -# define ZEND_VM_GUARD(name) __asm__("#" #name) -#else -# define ZEND_VM_GUARD(name) -#endif - -#include "zend_vm_execute.h" - -ZEND_API int zend_set_user_opcode_handler(zend_uchar opcode, user_opcode_handler_t handler) -{ - if (opcode != ZEND_USER_OPCODE) { - if (handler == NULL) { - /* restore the original handler */ - zend_user_opcodes[opcode] = opcode; - } else { - zend_user_opcodes[opcode] = ZEND_USER_OPCODE; - } - zend_user_opcode_handlers[opcode] = handler; - return SUCCESS; - } - return FAILURE; -} - -ZEND_API user_opcode_handler_t zend_get_user_opcode_handler(zend_uchar opcode) -{ - return zend_user_opcode_handlers[opcode]; -} - -ZEND_API zval *zend_get_zval_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { - return get_zval_ptr(op_type, node, execute_data, should_free, type); -} - -ZEND_API zval **zend_get_zval_ptr_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { - return get_zval_ptr_ptr(op_type, node, execute_data, should_free, type); -} - void zend_clean_and_cache_symbol_table(HashTable *symbol_table TSRMLS_DC) /* {{{ */ { if (EG(symtable_cache_ptr) >= EG(symtable_cache_limit)) { @@ -1558,14 +1505,22 @@ void zend_clean_and_cache_symbol_table(HashTable *symbol_table TSRMLS_DC) /* {{{ } /* }}} */ -void zend_free_compiled_variables(zend_execute_data *execute_data) /* {{{ */ +static zend_always_inline void i_free_compiled_variables(zend_execute_data *execute_data) /* {{{ */ { - int i; - for (i = 0; i < EX(op_array)->last_var; ++i) { - if (EX_CV(i)) { - zval_ptr_dtor(EX_CV(i)); + zval ***cv = EX_CV_NUM(execute_data, 0); + zval ***end = cv + EX(op_array)->last_var; + while (cv != end) { + if (*cv) { + zval_ptr_dtor(*cv); } - } + cv++; + } +} +/* }}} */ + +void zend_free_compiled_variables(zend_execute_data *execute_data) /* {{{ */ +{ + i_free_compiled_variables(execute_data); } /* }}} */ @@ -1611,7 +1566,7 @@ void zend_free_compiled_variables(zend_execute_data *execute_data) /* {{{ */ * +----------------------------------------+ */ -zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) /* {{{ */ +static zend_always_inline zend_execute_data *i_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) /* {{{ */ { zend_execute_data *execute_data; @@ -1720,6 +1675,68 @@ zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_arra } /* }}} */ +zend_execute_data *zend_create_execute_data_from_op_array(zend_op_array *op_array, zend_bool nested TSRMLS_DC) /* {{{ */ +{ + return i_create_execute_data_from_op_array(op_array, nested TSRMLS_CC); +} +/* }}} */ + +#define ZEND_VM_NEXT_OPCODE() \ + CHECK_SYMBOL_TABLES() \ + ZEND_VM_INC_OPCODE(); \ + ZEND_VM_CONTINUE() + +#define ZEND_VM_SET_OPCODE(new_op) \ + CHECK_SYMBOL_TABLES() \ + OPLINE = new_op + +#define ZEND_VM_JMP(new_op) \ + if (EXPECTED(!EG(exception))) { \ + ZEND_VM_SET_OPCODE(new_op); \ + } else { \ + LOAD_OPLINE(); \ + } \ + ZEND_VM_CONTINUE() + +#define ZEND_VM_INC_OPCODE() \ + OPLINE++ + +#ifdef __GNUC__ +# define ZEND_VM_GUARD(name) __asm__("#" #name) +#else +# define ZEND_VM_GUARD(name) +#endif + +#include "zend_vm_execute.h" + +ZEND_API int zend_set_user_opcode_handler(zend_uchar opcode, user_opcode_handler_t handler) +{ + if (opcode != ZEND_USER_OPCODE) { + if (handler == NULL) { + /* restore the original handler */ + zend_user_opcodes[opcode] = opcode; + } else { + zend_user_opcodes[opcode] = ZEND_USER_OPCODE; + } + zend_user_opcode_handlers[opcode] = handler; + return SUCCESS; + } + return FAILURE; +} + +ZEND_API user_opcode_handler_t zend_get_user_opcode_handler(zend_uchar opcode) +{ + return zend_user_opcode_handlers[opcode]; +} + +ZEND_API zval *zend_get_zval_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { + return get_zval_ptr(op_type, node, execute_data, should_free, type); +} + +ZEND_API zval **zend_get_zval_ptr_ptr(int op_type, const znode_op *node, const zend_execute_data *execute_data, zend_free_op *should_free, int type TSRMLS_DC) { + return get_zval_ptr_ptr(op_type, node, execute_data, should_free, type); +} + /* * Local variables: * tab-width: 4 diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index c309ca05def52..2b65275fa6ba6 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1852,7 +1852,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) } /* Generators go throw a different cleanup process */ - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { + if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -1866,7 +1866,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { - zend_free_compiled_variables(execute_data); + i_free_compiled_variables(execute_data); } if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index bce82ac4e5aef..5971cc9047218 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -326,9 +326,6 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #define ZEND_VM_DISPATCH(opcode, opline) return zend_vm_get_opcode_handler(opcode, opline)(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC -#undef EX -#define EX(element) execute_data->element - ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) { @@ -340,6 +337,11 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) original_in_execution = EG(in_execution); EG(in_execution) = 1; + if (0) { +zend_vm_enter: + execute_data = i_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); + } + LOAD_REGS(); LOAD_OPLINE(); @@ -357,7 +359,7 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) EG(in_execution) = original_in_execution; return; case 2: - execute_data = zend_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); + goto zend_vm_enter; break; case 3: execute_data = EG(current_execute_data); @@ -376,7 +378,7 @@ ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) if (EG(exception)) { return; } - zend_execute_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); + zend_execute_ex(i_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) @@ -391,7 +393,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) } /* Generators go throw a different cleanup process */ - if (EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) { + if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -405,7 +407,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { - zend_free_compiled_variables(execute_data); + i_free_compiled_variables(execute_data); } if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { diff --git a/Zend/zend_vm_execute.skl b/Zend/zend_vm_execute.skl index eb18580b21948..13fd88e2d881b 100644 --- a/Zend/zend_vm_execute.skl +++ b/Zend/zend_vm_execute.skl @@ -12,6 +12,11 @@ ZEND_API void {%EXECUTOR_NAME%}_ex(zend_execute_data *execute_data TSRMLS_DC) original_in_execution = EG(in_execution); EG(in_execution) = 1; + if (0) { +zend_vm_enter: + execute_data = i_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); + } + LOAD_REGS(); LOAD_OPLINE(); @@ -36,7 +41,7 @@ ZEND_API void zend_{%EXECUTOR_NAME%}(zend_op_array *op_array TSRMLS_DC) if (EG(exception)) { return; } - zend_{%EXECUTOR_NAME%}_ex(zend_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); + zend_{%EXECUTOR_NAME%}_ex(i_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } {%EXTERNAL_EXECUTOR%} diff --git a/Zend/zend_vm_gen.php b/Zend/zend_vm_gen.php index 6c9dcafba7213..b56dd70f40120 100644 --- a/Zend/zend_vm_gen.php +++ b/Zend/zend_vm_gen.php @@ -839,8 +839,6 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define ZEND_VM_LEAVE() return 3\n"); out($f,"#define ZEND_VM_DISPATCH(opcode, opline) return zend_vm_get_opcode_handler(opcode, opline)(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU);\n\n"); out($f,"#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC\n"); - out($f,"#undef EX\n"); - out($f,"#define EX(element) execute_data->element\n\n"); break; case ZEND_VM_KIND_SWITCH: out($f,"\n"); @@ -863,12 +861,10 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define LOAD_REGS()\n"); out($f,"#define ZEND_VM_CONTINUE() goto zend_vm_continue\n"); out($f,"#define ZEND_VM_RETURN() EG(in_execution) = original_in_execution; return\n"); - out($f,"#define ZEND_VM_ENTER() execute_data = zend_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); LOAD_REGS(); LOAD_OPLINE(); ZEND_VM_CONTINUE()\n"); + out($f,"#define ZEND_VM_ENTER() goto zend_vm_enter\n"); out($f,"#define ZEND_VM_LEAVE() ZEND_VM_CONTINUE()\n"); out($f,"#define ZEND_VM_DISPATCH(opcode, opline) dispatch_handler = zend_vm_get_opcode_handler(opcode, opline); goto zend_vm_dispatch;\n\n"); out($f,"#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC\n"); - out($f,"#undef EX\n"); - out($f,"#define EX(element) execute_data->element\n\n"); break; case ZEND_VM_KIND_GOTO: out($f,"\n"); @@ -891,12 +887,10 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, out($f,"#define LOAD_REGS()\n"); out($f,"#define ZEND_VM_CONTINUE() goto *(void**)(OPLINE->handler)\n"); out($f,"#define ZEND_VM_RETURN() EG(in_execution) = original_in_execution; return\n"); - out($f,"#define ZEND_VM_ENTER() execute_data = zend_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC); LOAD_REGS(); LOAD_OPLINE(); ZEND_VM_CONTINUE()\n"); + out($f,"#define ZEND_VM_ENTER() goto zend_vm_enter\n"); out($f,"#define ZEND_VM_LEAVE() ZEND_VM_CONTINUE()\n"); out($f,"#define ZEND_VM_DISPATCH(opcode, opline) goto *(void**)(zend_vm_get_opcode_handler(opcode, opline));\n\n"); out($f,"#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC\n"); - out($f,"#undef EX\n"); - out($f,"#define EX(element) execute_data->element\n\n"); break; } break; @@ -965,7 +959,7 @@ function gen_executor($f, $skl, $spec, $kind, $executor_name, $initializer_name, $m[1]."\t\tEG(in_execution) = original_in_execution;\n". $m[1]."\t\treturn;\n". $m[1]."\tcase 2:\n" . - $m[1]."\t\texecute_data = zend_create_execute_data_from_op_array(EG(active_op_array), 1 TSRMLS_CC);\n". + $m[1]."\t\tgoto zend_vm_enter;\n". $m[1]."\t\tbreak;\n" . $m[1]."\tcase 3:\n" . $m[1]."\t\texecute_data = EG(current_execute_data);\n". @@ -1215,8 +1209,6 @@ function gen_vm($def, $skel) { // Generate un-specialized executor if (ZEND_VM_OLD_EXECUTOR) { out($f,"\n/* Old executor */\n\n"); - out($f,"#undef EX\n"); - out($f,"#define EX(element) execute_data.element\n\n"); out($f,"#undef ZEND_VM_CONTINUE\n\n"); out($f,"#undef ZEND_VM_RETURN\n\n"); out($f,"#undef ZEND_VM_ENTER\n\n"); @@ -1289,8 +1281,6 @@ function gen_vm($def, $skel) { out($f,"#define CHECK_EXCEPTION() LOAD_OPLINE()\n"); out($f,"#define HANDLE_EXCEPTION() LOAD_OPLINE(); ZEND_VM_CONTINUE()\n"); out($f,"#define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE()\n"); - out($f,"#undef EX\n"); - out($f,"#define EX(element) execute_data->element\n\n"); out($f,"#undef ZEND_VM_CONTINUE\n"); out($f,"#undef ZEND_VM_RETURN\n"); out($f,"#undef ZEND_VM_ENTER\n"); From 27528b601f4a290ba50b202376a0064f17348027 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 5 Dec 2012 16:02:47 +0400 Subject: [PATCH 2193/2394] Fixed comments --- Zend/zend_execute.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index d260953bd7ac4..1098c9efaf6b5 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1572,12 +1572,14 @@ static zend_always_inline zend_execute_data *i_create_execute_data_from_op_array /* * When allocating the execute_data, memory for compiled variables and - * temporary variables is also allocated after the actual zend_execute_data - * struct. op_array->last_var specifies the number of compiled variables and - * op_array->T is the number of temporary variables. If there is no symbol - * table, then twice as much memory is allocated for compiled variables. - * In that case the first half contains zval**s and the second half the - * actual zval*s (which would otherwise be in the symbol table). + * temporary variables is also allocated before and after the actual + * zend_execute_data struct. In addition we also allocate space to store + * information about syntactically nested called functions and actual + * parameters. op_array->last_var specifies the number of compiled + * variables and op_array->T is the number of temporary variables. If there + * is no symbol table, then twice as much memory is allocated for compiled + * variables. In that case the first half contains zval**s and the second + * half the actual zval*s (which would otherwise be in the symbol table). */ size_t execute_data_size = ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data)); size_t CVs_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval **) * op_array->last_var * (EG(active_symbol_table) ? 1 : 2)); @@ -1592,8 +1594,9 @@ static zend_always_inline zend_execute_data *i_create_execute_data_from_op_array * though this behavior would be suboptimal, because the (rather large) * structure would have to be copied back and forth every time execution is * suspended or resumed. That's why for generators the execution context - * is allocated using emalloc, thus allowing to save and restore it simply - * by replacing a pointer. + * is allocated using a separate VM stack, thus allowing to save and + * restore it simply by replacing a pointer. The same segment also keeps + * a copy of previous execute_data and passed parameters. */ if (op_array->fn_flags & ZEND_ACC_GENERATOR) { /* Prepend the regular stack frame with copy on prev_execute_data From 5ac35770f45e295cab1ed3c166131d11c27655f6 Mon Sep 17 00:00:00 2001 From: Sara Golemon Date: Wed, 5 Dec 2012 15:07:36 -0800 Subject: [PATCH 2194/2394] Add UConverter class (ICU's UConverter API) RFC at http://wiki.php.net/rfc/uconverter --- ext/intl/config.m4 | 2 + ext/intl/config.w32 | 3 + ext/intl/converter/converter.c | 1104 +++++++++++++++++ ext/intl/converter/converter.h | 28 + ext/intl/php_intl.c | 5 + ext/intl/tests/uconverter_enum.phpt | 21 + ext/intl/tests/uconverter_func_basic.phpt | 17 + ext/intl/tests/uconverter_func_subst.phpt | 31 + ext/intl/tests/uconverter_oop_algo.phpt | 18 + ext/intl/tests/uconverter_oop_basic.phpt | 21 + ext/intl/tests/uconverter_oop_callback.phpt | 52 + .../tests/uconverter_oop_callback_return.phpt | 40 + ext/intl/tests/uconverter_oop_subst.phpt | 24 + 13 files changed, 1366 insertions(+) create mode 100644 ext/intl/converter/converter.c create mode 100644 ext/intl/converter/converter.h create mode 100644 ext/intl/tests/uconverter_enum.phpt create mode 100644 ext/intl/tests/uconverter_func_basic.phpt create mode 100644 ext/intl/tests/uconverter_func_subst.phpt create mode 100644 ext/intl/tests/uconverter_oop_algo.phpt create mode 100644 ext/intl/tests/uconverter_oop_basic.phpt create mode 100644 ext/intl/tests/uconverter_oop_callback.phpt create mode 100644 ext/intl/tests/uconverter_oop_callback_return.phpt create mode 100644 ext/intl/tests/uconverter_oop_subst.phpt diff --git a/ext/intl/config.m4 b/ext/intl/config.m4 index 7c95c130f2135..4630a302ef891 100644 --- a/ext/intl/config.m4 +++ b/ext/intl/config.m4 @@ -34,6 +34,7 @@ if test "$PHP_INTL" != "no"; then common/common_error.c \ common/common_enum.cpp \ common/common_date.cpp \ + converter/converter.c \ formatter/formatter.c \ formatter/formatter_main.c \ formatter/formatter_class.c \ @@ -86,6 +87,7 @@ if test "$PHP_INTL" != "no"; then idn/idn.c \ $icu_spoof_src, $ext_shared,,$ICU_INCS -Wno-write-strings) PHP_ADD_BUILD_DIR($ext_builddir/collator) + PHP_ADD_BUILD_DIR($ext_builddir/converter) PHP_ADD_BUILD_DIR($ext_builddir/common) PHP_ADD_BUILD_DIR($ext_builddir/formatter) PHP_ADD_BUILD_DIR($ext_builddir/normalizer) diff --git a/ext/intl/config.w32 b/ext/intl/config.w32 index a49918794c576..bb1dca8124a5a 100644 --- a/ext/intl/config.w32 +++ b/ext/intl/config.w32 @@ -26,6 +26,9 @@ if (PHP_INTL != "no") { common_enum.cpp \ common_date.cpp \ ", "intl"); + ADD_SOURCES(configure_module_dirname + "/converter", "\ + converter.c \ + ", "intl"); ADD_SOURCES(configure_module_dirname + "/formatter", "\ formatter.c \ formatter_attr.c \ diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c new file mode 100644 index 0000000000000..6be8698cbf588 --- /dev/null +++ b/ext/intl/converter/converter.c @@ -0,0 +1,1104 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Sara Golemon | + +----------------------------------------------------------------------+ + */ + +#include "converter.h" +#include "zend_exceptions.h" + +#include +#include +#include + +#include "ext/intl/intl_error.h" + +typedef struct _php_converter_object { + zend_object obj; +#ifdef ZTS + void ***tsrm_ls; +#endif + UConverter *src, *dest; + zend_fcall_info to_cb, from_cb; + zend_fcall_info_cache to_cache, from_cache; + intl_error error; +} php_converter_object; + +static zend_class_entry *php_converter_ce; +static zend_object_handlers php_converter_object_handlers; + +#define CONV_GET(pzv) ((php_converter_object*)zend_objects_get_address((pzv) TSRMLS_CC)) +#define THROW_UFAILURE(obj, fname, error) php_converter_throw_failure(obj, error TSRMLS_CC, \ + fname "() returned error %ld: %s", (long)error, u_errorName(error)) + +/* {{{ php_converter_throw_failure */ +static inline void php_converter_throw_failure(php_converter_object *objval, UErrorCode error TSRMLS_DC, const char *format, ...) { + intl_error *err = objval ? &(objval->error) : NULL; + char message[1024]; + va_list vargs; + + va_start(vargs, format); + vsnprintf(message, sizeof(message), format, vargs); + va_end(vargs); + + intl_error_set_code(err, error TSRMLS_CC); + intl_error_set_custom_msg(err, message, 1 TSRMLS_CC); +} +/* }}} */ + +/* {{{ php_converter_default_callback */ +static void php_converter_default_callback(zval *return_value, zval *zobj, long reason, zval *error TSRMLS_DC) { + /* Basic functionality so children can call parent::toUCallback() */ + switch (reason) { + case UCNV_UNASSIGNED: + case UCNV_ILLEGAL: + case UCNV_IRREGULAR: + { + php_converter_object *objval = (php_converter_object*)CONV_GET(zobj); + char chars[127]; + int8_t chars_len = sizeof(chars); + UErrorCode error = U_ZERO_ERROR; + + /* Yes, this is fairly wasteful at first glance, + * but considering that the alternative is to store + * what's sent into setSubstChars() and the fact + * that this is an extremely unlikely codepath + * I'd rather take the CPU hit here, than waste time + * storing a value I'm unlikely to use. + */ + ucnv_getSubstChars(objval->src, chars, &chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getSubstChars", error); + chars[0] = 0x1A; + chars[1] = 0; + chars_len = 1; + } + RETVAL_STRINGL(chars, chars_len, 1); + } + } + zval_dtor(error); + ZVAL_LONG(error, U_ZERO_ERROR); +} +/* }}} */ + +/* {{{ proto void UConverter::toUCallback(long $reason, + string $source, string $codeUnits, + long &$error) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_toUCallback_arginfo, 0, ZEND_RETURN_VALUE, 5) + ZEND_ARG_INFO(0, reason) + ZEND_ARG_INFO(0, source) + ZEND_ARG_INFO(0, codeUnits) + ZEND_ARG_INFO(1, error) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, toUCallback) { + long reason; + zval *source, *codeUnits, *error; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lzzz", + &reason, &source, &codeUnits, &error) == FAILURE) { + return; + } + + php_converter_default_callback(return_value, getThis(), reason, error TSRMLS_CC); +} +/* }}} */ + +/* {{{ proto void UConverter::fromUCallback(long $reason, + Array $source, long $codePoint, + long &$error) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_fromUCallback_arginfo, 0, ZEND_RETURN_VALUE, 5) + ZEND_ARG_INFO(0, reason) + ZEND_ARG_INFO(0, source) + ZEND_ARG_INFO(0, codePoint) + ZEND_ARG_INFO(1, error) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, fromUCallback) { + long reason; + zval *source, *codePoint, *error; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lzzz", + &reason, &source, &codePoint, &error) == FAILURE) { + return; + } + + php_converter_default_callback(return_value, getThis(), reason, error TSRMLS_CC); +} +/* }}} */ + +/* {{{ php_converter_check_limits */ +static inline zend_bool php_converter_check_limits(php_converter_object *objval, long available, long needed TSRMLS_DC) { + if (available < needed) { + php_converter_throw_failure(objval, U_BUFFER_OVERFLOW_ERROR TSRMLS_CC, "Buffer overrun %ld bytes needed, %ld available", needed, available); + return 0; + } + return 1; +} +/* }}} */ + +#define TARGET_CHECK(cnvargs, needed) php_converter_check_limits(objval, cnvargs->targetLimit - cnvargs->target, needed TSRMLS_CC) + +/* {{{ php_converter_append_toUnicode_target */ +static void php_converter_append_toUnicode_target(zval *val, UConverterToUnicodeArgs *args, php_converter_object *objval TSRMLS_DC) { + switch (Z_TYPE_P(val)) { + case IS_NULL: + /* Code unit is being skipped */ + return; + case IS_LONG: + { + long lval = Z_LVAL_P(val); + if ((lval < 0) || (lval > 0x10FFFF)) { + php_converter_throw_failure(objval, U_ILLEGAL_ARGUMENT_ERROR TSRMLS_CC, "Invalid codepoint U+%04lx", lval); + return; + } + if (lval > 0xFFFF) { + /* Supplemental planes U+010000 - U+10FFFF */ + if (TARGET_CHECK(args, 2)) { + /* TODO: Find the ICU call which does this properly */ + *(args->target++) = (UChar)(((lval - 0x10000) >> 10) | 0xD800); + *(args->target++) = (UChar)(((lval - 0x10000) & 0x3FF) | 0xDC00); + } + return; + } + /* Non-suggogate BMP codepoint */ + if (TARGET_CHECK(args, 1)) { + *(args->target++) = (UChar)lval; + } + return; + } + case IS_STRING: + { + const char *strval = Z_STRVAL_P(val); + int i = 0, strlen = Z_STRLEN_P(val); + + while((i != strlen) && TARGET_CHECK(args, 1)) { + UChar c; + U8_NEXT(strval, i, strlen, c); + *(args->target++) = c; + } + return; + } + case IS_ARRAY: + { + HashTable *ht = Z_ARRVAL_P(val); + HashPosition pos; + zval **tmpzval; + + for(zend_hash_internal_pointer_reset_ex(ht, &pos); + zend_hash_get_current_data_ex(ht, (void**)&tmpzval, &pos) == SUCCESS; + zend_hash_move_forward_ex(ht, &pos)) { + php_converter_append_toUnicode_target(*tmpzval, args, objval TSRMLS_CC); + } + return; + } + default: + php_converter_throw_failure(objval, U_ILLEGAL_ARGUMENT_ERROR TSRMLS_CC, + "toUCallback() specified illegal type for substitution character"); + } +} +/* }}} */ + +/* {{{ php_converter_to_u_callback */ +static void php_converter_to_u_callback(const void *context, + UConverterToUnicodeArgs *args, + const char *codeUnits, int32_t length, + UConverterCallbackReason reason, + UErrorCode *pErrorCode) { + php_converter_object *objval = (php_converter_object*)context; + zval *zreason, *zsource, *zcodeunits, *zerror, *retval = NULL; + zval **zargs[4]; +#ifdef ZTS + TSRMLS_D = objval->tsrm_ls; +#endif + + MAKE_STD_ZVAL(zreason); + ZVAL_LONG(zreason, reason); + zargs[0] = &zreason; + + MAKE_STD_ZVAL(zsource); + ZVAL_STRINGL(zsource, args->source, args->sourceLimit - args->source, 1); + zargs[1] = &zsource; + + MAKE_STD_ZVAL(zcodeunits); + ZVAL_STRINGL(zcodeunits, codeUnits, length, 1); + zargs[2] = &zcodeunits; + + MAKE_STD_ZVAL(zerror); + ZVAL_LONG(zerror, *pErrorCode); + zargs[3] = &zerror; + + objval->to_cb.param_count = 4; + objval->to_cb.params = zargs; + objval->to_cb.retval_ptr_ptr = &retval; + objval->to_cb.no_separation = 0; + if (zend_call_function(&(objval->to_cb), &(objval->to_cache) TSRMLS_CC) == FAILURE) { + /* Unlikely */ + php_converter_throw_failure(objval, U_INTERNAL_PROGRAM_ERROR TSRMLS_CC, "Unexpected failure calling toUCallback()"); + } else if (retval) { + php_converter_append_toUnicode_target(retval, args, objval TSRMLS_CC); + zval_ptr_dtor(&retval); + } + + if (Z_TYPE_P(zerror) == IS_LONG) { + *pErrorCode = Z_LVAL_P(zerror); + } + + zval_ptr_dtor(&zreason); + zval_ptr_dtor(&zsource); + zval_ptr_dtor(&zcodeunits); + zval_ptr_dtor(&zerror); +} +/* }}} */ + +/* {{{ php_converter_append_fromUnicode_target */ +static void php_converter_append_fromUnicode_target(zval *val, UConverterFromUnicodeArgs *args, php_converter_object *objval TSRMLS_DC) { + switch (Z_TYPE_P(val)) { + case IS_NULL: + /* Ignore */ + return; + case IS_LONG: + if (TARGET_CHECK(args, 1)) { + *(args->target++) = Z_LVAL_P(val); + } + return; + case IS_STRING: + { + int vallen = Z_STRLEN_P(val); + if (TARGET_CHECK(args, vallen)) { + memcpy(args->target, Z_STRVAL_P(val), vallen); + args->target += vallen; + } + return; + } + case IS_ARRAY: + { + HashTable *ht = Z_ARRVAL_P(val); + HashPosition pos; + zval **tmpzval; + for(zend_hash_internal_pointer_reset_ex(ht, &pos); + zend_hash_get_current_data_ex(ht, (void**)&tmpzval, &pos) == SUCCESS; + zend_hash_move_forward_ex(ht, &pos)) { + php_converter_append_fromUnicode_target(*tmpzval, args, objval TSRMLS_CC); + } + return; + } + default: + php_converter_throw_failure(objval, U_ILLEGAL_ARGUMENT_ERROR TSRMLS_CC, "fromUCallback() specified illegal type for substitution character"); + } +} +/* }}} */ + +/* {{{ php_converter_from_u_callback */ +static void php_converter_from_u_callback(const void *context, + UConverterFromUnicodeArgs *args, + const UChar *codeUnits, int32_t length, UChar32 codePoint, + UConverterCallbackReason reason, + UErrorCode *pErrorCode) { + php_converter_object *objval = (php_converter_object*)context; + zval *zreason, *zsource, *zcodepoint, *zerror, *retval = NULL; + zval **zargs[4]; + int i; +#ifdef ZTS + TSRMLS_D = objval->tsrm_ls; +#endif + + MAKE_STD_ZVAL(zreason); + ZVAL_LONG(zreason, reason); + zargs[0] = &zreason; + + MAKE_STD_ZVAL(zsource); + array_init(zsource); + i = 0; + while (i < length) { + UChar32 c; + U16_NEXT(codeUnits, i, length, c); + add_next_index_long(zsource, c); + } + zargs[1] = &zsource; + + MAKE_STD_ZVAL(zcodepoint); + ZVAL_LONG(zcodepoint, codePoint); + zargs[2] = &zcodepoint; + + MAKE_STD_ZVAL(zerror); + ZVAL_LONG(zerror, *pErrorCode); + zargs[3] = &zerror; + + objval->from_cb.param_count = 4; + objval->from_cb.params = zargs; + objval->from_cb.retval_ptr_ptr = &retval; + objval->from_cb.no_separation = 0; + if (zend_call_function(&(objval->from_cb), &(objval->from_cache) TSRMLS_CC) == FAILURE) { + /* Unlikely */ + php_converter_throw_failure(objval, U_INTERNAL_PROGRAM_ERROR TSRMLS_CC, "Unexpected failure calling fromUCallback()"); + } else if (retval) { + php_converter_append_fromUnicode_target(retval, args, objval TSRMLS_CC); + zval_ptr_dtor(&retval); + } + + if (Z_TYPE_P(zerror) == IS_LONG) { + *pErrorCode = Z_LVAL_P(zerror); + } + + zval_ptr_dtor(&zreason); + zval_ptr_dtor(&zsource); + zval_ptr_dtor(&zcodepoint); + zval_ptr_dtor(&zerror); +} +/* }}} */ + +/* {{{ php_converter_set_callbacks */ +static inline zend_bool php_converter_set_callbacks(php_converter_object *objval, UConverter *cnv TSRMLS_DC) { + zend_bool ret = 1; + UErrorCode error = U_ZERO_ERROR; + + if (objval->obj.ce == php_converter_ce) { + /* Short-circuit having to go through method calls and data marshalling + * when we're using default behavior + */ + return 1; + } + + ucnv_setToUCallBack(cnv, (UConverterToUCallback)php_converter_to_u_callback, (const void*)objval, + NULL, NULL, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setToUCallBack", error); + ret = 0; + } + + error = U_ZERO_ERROR; + ucnv_setFromUCallBack(cnv, (UConverterFromUCallback)php_converter_from_u_callback, (const void*)objval, + NULL, NULL, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setFromUCallBack", error); + ret = 0; + } + return ret; +} +/* }}} */ + +/* {{{ php_converter_set_encoding */ +static zend_bool php_converter_set_encoding(php_converter_object *objval, + UConverter **pcnv, + const char *enc, int enc_len + TSRMLS_DC) { + UErrorCode error = U_ZERO_ERROR; + UConverter *cnv = ucnv_open(enc, &error); + + if (error == U_AMBIGUOUS_ALIAS_WARNING) { + UErrorCode getname_error = U_ZERO_ERROR; + const char *actual_encoding = ucnv_getName(cnv, &getname_error); + if (U_FAILURE(getname_error)) { + /* Should never happen */ + actual_encoding = "(unknown)"; + } + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Ambiguous encoding specified, using %s", actual_encoding); + } else if (U_FAILURE(error)) { + if (objval) { + THROW_UFAILURE(objval, "ucnv_open", error); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Error setting encoding: %d - %s", (int)error, u_errorName(error)); + } + return 0; + } + + if (objval && !php_converter_set_callbacks(objval, cnv TSRMLS_CC)) { + return 0; + } + + if (*pcnv) { + ucnv_close(*pcnv); + } + *pcnv = cnv; + return 1; +} +/* }}} */ + +/* {{{ php_converter_do_set_encoding */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_set_encoding_arginfo, 0, ZEND_RETURN_VALUE, 1) + ZEND_ARG_INFO(0, encoding) +ZEND_END_ARG_INFO(); +static void php_converter_do_set_encoding(UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { + php_converter_object *objval = CONV_GET(getThis()); + char *enc; + int enc_len; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &enc, &enc_len) == FAILURE) { + return; + } + + RETURN_BOOL(php_converter_set_encoding(objval, &(objval->src), enc, enc_len TSRMLS_CC)); +} +/* }}} */ + +/* {{{ proto bool UConverter::setSourceEncoding(string encoding) */ +static PHP_METHOD(UConverter, setSourceEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_set_encoding(objval->src, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto bool UConverter::setDestinationEncoding(string encoding) */ +static PHP_METHOD(UConverter, setDestinationEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_set_encoding(objval->dest, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ php_converter_do_get_encoding */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_get_encoding_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static void php_converter_do_get_encoding(php_converter_object *objval, UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { + UErrorCode error = U_ZERO_ERROR; + const char *name; + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + if (!cnv) { + RETURN_NULL(); + } + + name = ucnv_getName(cnv, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getName()", error); + RETURN_NULL(); + } + + RETURN_STRING(name, 1); +} +/* }}} */ + +/* {{{ proto string UConverter::getSourceEncoding() */ +static PHP_METHOD(UConverter, getSourceEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_encoding(objval, objval->src, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string UConverter::getDestinationEncoding() */ +static PHP_METHOD(UConverter, getDestinationEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_encoding(objval, objval->dest, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ php_converter_do_get_type */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_get_type_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static void php_converter_do_get_type(php_converter_object *objval, UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { + UErrorCode error = U_ZERO_ERROR; + UConverterType t; + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + if (!cnv) { + RETURN_NULL(); + } + + t = ucnv_getType(cnv); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getType", error); + RETURN_NULL(); + } + + RETURN_LONG(t); +} +/* }}} */ + +/* {{{ proto long UConverter::getSourceType() */ +static PHP_METHOD(UConverter, getSourceType) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_type(objval, objval->src, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto long UConverter::getDestinationType() */ +static PHP_METHOD(UConverter, getDestinationType) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_type(objval, objval->dest, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ php_converter_resolve_callback */ +static void php_converter_resolve_callback(zval *zobj, + php_converter_object *objval, + const char *callback_name, + zend_fcall_info *finfo, + zend_fcall_info_cache *fcache TSRMLS_DC) { + char *errstr = NULL; + zval caller; + + array_init(&caller); + Z_ADDREF_P(zobj); + add_index_zval(&caller, 0, zobj); + add_index_string(&caller, 1, callback_name, 1); + if (zend_fcall_info_init(&caller, 0, finfo, fcache, NULL, &errstr TSRMLS_CC) == FAILURE) { + php_converter_throw_failure(objval, U_INTERNAL_PROGRAM_ERROR TSRMLS_CC, "Error setting converter callback: %s", errstr); + } + zval_dtor(&caller); + if (errstr) { + efree(errstr); + } +} +/* }}} */ + +/* {{{ proto void UConverter::__construct([string dest = 'utf-8',[string src = 'utf-8']]) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_arginfo, 0, ZEND_RETURN_VALUE, 0) + ZEND_ARG_INFO(0, destination_encoding) + ZEND_ARG_INFO(0, source_encoding) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, __construct) { + php_converter_object *objval = CONV_GET(getThis()); + char *src = "utf-8"; + int src_len = sizeof("utf-8") - 1; + char *dest = src; + int dest_len = src_len; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!s!", + &dest, &dest_len, &src, &src_len) == FAILURE) { + return; + } + + php_converter_set_encoding(objval, &(objval->src), src, src_len TSRMLS_CC); + php_converter_set_encoding(objval, &(objval->dest), dest, dest_len TSRMLS_CC); + php_converter_resolve_callback(getThis(), objval, "toUCallback", &(objval->to_cb), &(objval->to_cache) TSRMLS_CC); + php_converter_resolve_callback(getThis(), objval, "fromUCallback", &(objval->from_cb), &(objval->from_cache) TSRMLS_CC); +} +/* }}} */ + +/* {{{ proto bool UConverter::setSubstChars(string $chars) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_setSubstChars_arginfo, 0, ZEND_RETURN_VALUE, 1) + ZEND_ARG_INFO(0, chars) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, setSubstChars) { + php_converter_object *objval = CONV_GET(getThis()); + char *chars; + int chars_len, ret = 1; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &chars, &chars_len) == FAILURE) { + return; + } + + if (objval->src) { + UErrorCode error = U_ZERO_ERROR; + ucnv_setSubstChars(objval->src, chars, chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setSubstChars", error); + ret = 0; + } + } else { + php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, "Source Converter has not been initialized yet"); + } + + if (objval->dest) { + UErrorCode error = U_ZERO_ERROR; + ucnv_setSubstChars(objval->dest, chars, chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setSubstChars", error); + ret = 0; + } + } else { + php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, "Destination Converter has not been initialized yet"); + } + + RETURN_BOOL(ret); +} +/* }}} */ + +/* {{{ proto string UConverter::getSubstChars() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getSubstChars_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, getSubstChars) { + php_converter_object *objval = CONV_GET(getThis()); + char chars[127]; + int8_t chars_len = sizeof(chars); + UErrorCode error = U_ZERO_ERROR; + + if (!objval->src) { + RETURN_NULL(); + } + + /* src and dest get the same subst chars set, + * so it doesn't really matter which one we read from + */ + ucnv_getSubstChars(objval->src, chars, &chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getSubstChars", error); + RETURN_NULL(); + } + + RETURN_STRINGL(chars, chars_len, 1); +} +/* }}} */ + +/* {{{ php_converter_do_convert */ +static zend_bool php_converter_do_convert(UConverter *dest_cnv, char **pdest, int32_t *pdest_len, + UConverter *src_cnv, const char *src, int32_t src_len, + php_converter_object *objval + TSRMLS_DC) { + UErrorCode error = U_ZERO_ERROR; + int32_t dest_len; + char *dest; + + if (!src_cnv || !dest_cnv) { + php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, + "Internal converters not initialized"); + return 0; + } + + /* Get necessary buffer size first */ + int32_t temp_len = 1 + ucnv_toUChars(src_cnv, NULL, 0, src, src_len, &error); + if (U_FAILURE(error) && error != U_BUFFER_OVERFLOW_ERROR) { + THROW_UFAILURE(objval, "ucnv_toUChars", error); + return 0; + } + UChar *temp = safe_emalloc(sizeof(UChar), temp_len, sizeof(UChar)); + + /* Convert to intermediate UChar* array */ + error = U_ZERO_ERROR; + temp_len = ucnv_toUChars(src_cnv, temp, temp_len, src, src_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_toUChars", error); + efree(temp); + return 0; + } + temp[temp_len] = 0; + + /* Get necessary output buffer size */ + dest_len = 1 + ucnv_fromUChars(dest_cnv, NULL, 0, temp, temp_len, &error); + if (U_FAILURE(error) && error != U_BUFFER_OVERFLOW_ERROR) { + THROW_UFAILURE(objval, "ucnv_fromUChars", error); + efree(temp); + return 0; + } + dest = safe_emalloc(sizeof(char), dest_len, sizeof(char)); + + /* Convert to final encoding */ + error = U_ZERO_ERROR; + dest_len = ucnv_fromUChars(dest_cnv, dest, dest_len, temp, temp_len, &error); + efree(temp); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_fromUChars", error); + efree(dest); + return 0; + } + + *pdest = dest; + if (pdest_len) { + *pdest_len = dest_len; + } + + return 1; +} +/* }}} */ + +/* {{{ proto string UConverter::reasonText(long reason) */ +#define UCNV_REASON_CASE(v) case (UCNV_ ## v) : RETURN_STRINGL( "REASON_" #v , sizeof( "REASON_" #v ) - 1, 1); +ZEND_BEGIN_ARG_INFO_EX(php_converter_reasontext_arginfo, 0, ZEND_RETURN_VALUE, 0) + ZEND_ARG_INFO(0, reason) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, reasonText) { + long reason; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &reason) == FAILURE) { + return; + } + + switch (reason) { + UCNV_REASON_CASE(UNASSIGNED) + UCNV_REASON_CASE(ILLEGAL) + UCNV_REASON_CASE(IRREGULAR) + UCNV_REASON_CASE(RESET) + UCNV_REASON_CASE(CLOSE) + UCNV_REASON_CASE(CLONE) + default: + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown UConverterCallbackReason: %ld", reason); + RETURN_NULL(); + } +} +/* }}} */ + +/* {{{ proto string UConverter::convert(string str[, bool reverse]) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_convert_arginfo, 0, ZEND_RETURN_VALUE, 1) + ZEND_ARG_INFO(0, str) + ZEND_ARG_INFO(0, reverse) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, convert) { + php_converter_object *objval = CONV_GET(getThis()); + char *str, *dest; + int str_len, dest_len; + zend_bool reverse = 0; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b!", + &str, &str_len, &reverse) == FAILURE) { + return; + } + + if (php_converter_do_convert(reverse ? objval->src : objval->dest, + &dest, &dest_len, + reverse ? objval->dest : objval->src, + str, str_len, + objval TSRMLS_CC)) { + RETURN_STRINGL(dest, dest_len, 0); + } else { + RETURN_NULL(); + } +} +/* }}} */ + +/* {{{ proto string UConverter::transcode(string $str, string $toEncoding, string $fromEncoding[, Array $options = array()]) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_transcode_arginfo, 0, ZEND_RETURN_VALUE, 3) + ZEND_ARG_INFO(0, str) + ZEND_ARG_INFO(0, toEncoding) + ZEND_ARG_INFO(0, fromEncoding) + ZEND_ARG_ARRAY_INFO(0, options, 1) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, transcode) { + char *str, *src, *dest; + int str_len, src_len, dest_len; + zval *options = NULL; + UConverter *src_cnv = NULL, *dest_cnv = NULL; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|a!", + &str, &str_len, &dest, &dest_len, &src, &src_len, &options) == FAILURE) { + return; + } + + if (php_converter_set_encoding(NULL, &src_cnv, src, src_len TSRMLS_CC) && + php_converter_set_encoding(NULL, &dest_cnv, dest, dest_len TSRMLS_CC)) { + char *out = NULL; + int out_len = 0; + UErrorCode error = U_ZERO_ERROR; + + if (options && zend_hash_num_elements(Z_ARRVAL_P(options))) { + zval **tmpzval; + + if (U_SUCCESS(error) && + zend_hash_find(Z_ARRVAL_P(options), "from_subst", sizeof("from_subst"), (void**)&tmpzval) == SUCCESS && + Z_TYPE_PP(tmpzval) == IS_STRING) { + error = U_ZERO_ERROR; + ucnv_setSubstChars(src_cnv, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval) & 0x7F, &error); + } + if (U_SUCCESS(error) && + zend_hash_find(Z_ARRVAL_P(options), "to_subst", sizeof("to_subst"), (void**)&tmpzval) == SUCCESS && + Z_TYPE_PP(tmpzval) == IS_STRING) { + error = U_ZERO_ERROR; + ucnv_setSubstChars(dest_cnv, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval) & 0x7F, &error); + } + } + + if (U_SUCCESS(error) && + php_converter_do_convert(dest_cnv, &out, &out_len, src_cnv, str, str_len, NULL TSRMLS_CC)) { + RETVAL_STRINGL(out, out_len, 0); + } + + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "transcode", error); + } + } + + if (src_cnv) { + ucnv_close(src_cnv); + } + if (dest_cnv) { + ucnv_close(dest_cnv); + } +} +/* }}} */ + +/* {{{ proto int UConverter::getErrorCode() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_geterrorcode_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getErrorCode) { + php_converter_object *objval = CONV_GET(getThis()); + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + RETURN_LONG(intl_error_get_code(&(objval->error) TSRMLS_CC)); +} +/* }}} */ + +/* {{{ proto string UConverter::getErrorMessage() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_geterrormsg_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getErrorMessage) { + php_converter_object *objval = CONV_GET(getThis()); + char *message = intl_error_get_message(&(objval->error) TSRMLS_CC); + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + if (message) { + RETURN_STRING(message, 1); + } else { + RETURN_NULL(); + } +} +/* }}} */ + +/* {{{ proto array UConverter::getAvailable() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getavailable_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getAvailable) { + int32_t i, count = ucnv_countAvailable(); + + array_init(return_value); + for(i = 0; i < count; i++) { + const char *name = ucnv_getAvailableName(i); + add_next_index_string(return_value, name, 1); + } +} +/* }}} */ + +/* {{{ proto array UConverter::getAliases(string name) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getaliases_arginfo, 0, ZEND_RETURN_VALUE, 0) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getAliases) { + char *name; + int name_len; + UErrorCode error = U_ZERO_ERROR; + uint16_t i, count; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name, &name_len) == FAILURE) { + return; + } + + count = ucnv_countAliases(name, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "ucnv_countAliases", error); + return; + } + + array_init(return_value); + for(i = 0; i < count; i++) { + error = U_ZERO_ERROR; + const char *alias = ucnv_getAlias(name, i, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "ucnv_getAlias", error); + zval_dtor(return_value); + RETURN_NULL(); + } + add_next_index_string(return_value, alias, 1); + } +} +/* }}} */ + +/* {{{ proto array UConverter::getStandards() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getstandards_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getStandards) { + uint16_t i, count; + + array_init(return_value); + count = ucnv_countStandards(); + for(i = 0; i < count; i++) { + UErrorCode error = U_ZERO_ERROR; + const char *name = ucnv_getStandard(i, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "ucnv_getStandard", error); + zval_dtor(return_value); + RETURN_NULL(); + } + add_next_index_string(return_value, name, 1); + } +} +/* }}} */ + +static zend_function_entry php_converter_methods[] = { + PHP_ME(UConverter, __construct, php_converter_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_CTOR) + + /* Encoding selection */ + PHP_ME(UConverter, setSourceEncoding, php_converter_set_encoding_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, setDestinationEncoding, php_converter_set_encoding_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getSourceEncoding, php_converter_get_encoding_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getDestinationEncoding, php_converter_get_encoding_arginfo, ZEND_ACC_PUBLIC) + + /* Introspection for algorithmic converters */ + PHP_ME(UConverter, getSourceType, php_converter_get_type_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getDestinationType, php_converter_get_type_arginfo, ZEND_ACC_PUBLIC) + + /* Basic codeunit error handling */ + PHP_ME(UConverter, getSubstChars, php_converter_getSubstChars_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, setSubstChars, php_converter_setSubstChars_arginfo, ZEND_ACC_PUBLIC) + + /* Default callback handlers */ + PHP_ME(UConverter, toUCallback, php_converter_toUCallback_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, fromUCallback, php_converter_fromUCallback_arginfo, ZEND_ACC_PUBLIC) + + /* Core conversion workhorses */ + PHP_ME(UConverter, convert, php_converter_convert_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, transcode, php_converter_transcode_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + + /* Error inspection */ + PHP_ME(UConverter, getErrorCode, php_converter_geterrorcode_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getErrorMessage, php_converter_geterrormsg_arginfo, ZEND_ACC_PUBLIC) + + /* Ennumeration and lookup */ + PHP_ME(UConverter, reasonText, php_converter_reasontext_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + PHP_ME(UConverter, getAvailable, php_converter_getavailable_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + PHP_ME(UConverter, getAliases, php_converter_getaliases_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + PHP_ME(UConverter, getStandards, php_converter_getstandards_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + { NULL, NULL, NULL } +}; + +/* {{{ Converter create/clone/destroy */ +static void php_converter_free_object(php_converter_object *objval TSRMLS_DC) { + if (objval->src) { + ucnv_close(objval->src); + } + + if (objval->dest) { + ucnv_close(objval->dest); + } + + intl_error_reset(&(objval->error) TSRMLS_CC); + zend_object_std_dtor(&(objval->obj) TSRMLS_CC); + + efree(objval); +} + +static zend_object_value php_converter_object_ctor(zend_class_entry *ce, php_converter_object **pobjval TSRMLS_DC) { + php_converter_object *objval; + zend_object_value retval; + + objval = ecalloc(1, sizeof(php_converter_object)); + objval->obj.ce = ce; + +#ifdef ZTS + objval->tsrm_ls = TSRMLS_C; +#endif + intl_error_init(&(objval->error) TSRMLS_CC); + + retval.handle = zend_objects_store_put(objval, NULL, (zend_objects_free_object_storage_t)php_converter_free_object, NULL TSRMLS_CC); + retval.handlers = &php_converter_object_handlers; + *pobjval = objval; + + return retval; +} + +static zend_object_value php_converter_create_object(zend_class_entry *ce TSRMLS_DC) { + php_converter_object *objval = NULL; + zend_object_value retval = php_converter_object_ctor(ce, &objval TSRMLS_CC); + + object_properties_init(&(objval->obj), ce); + + return retval; +} + +static zend_object_value php_converter_clone_object(zval *object TSRMLS_DC) { + php_converter_object *objval, *oldobj = (php_converter_object*)zend_objects_get_address(object TSRMLS_CC); + zend_object_value retval = php_converter_object_ctor(Z_OBJCE_P(object), &objval TSRMLS_CC); + UErrorCode error = U_ZERO_ERROR; + objval->src = ucnv_safeClone(oldobj->src, NULL, NULL, &error); + if (U_SUCCESS(error)) { + error = U_ZERO_ERROR; + objval->dest = ucnv_safeClone(oldobj->dest, NULL, NULL, &error); + } + if (U_FAILURE(error)) { + THROW_UFAILURE(oldobj, "ucnv_safeClone", error); + } + + /* Update contexts for converter error handlers */ + php_converter_set_callbacks(objval, objval->src TSRMLS_CC); + php_converter_set_callbacks(objval, objval->dest TSRMLS_CC); + + zend_objects_clone_members(&(objval->obj), retval, &(oldobj->obj), Z_OBJ_HANDLE_P(object) TSRMLS_CC); + + /* Newly cloned object deliberately does not inherit error state from original object */ + + return retval; +} +/* }}} */ + +#define CONV_REASON_CONST(v) zend_declare_class_constant_long(php_converter_ce, "REASON_" #v, sizeof("REASON_" #v) - 1, UCNV_ ## v TSRMLS_CC) +#define CONV_TYPE_CONST(v) zend_declare_class_constant_long(php_converter_ce, #v , sizeof(#v) - 1, UCNV_ ## v TSRMLS_CC) + +/* {{{ php_converter_minit */ +int php_converter_minit(INIT_FUNC_ARGS) { + zend_class_entry ce; + + INIT_CLASS_ENTRY(ce, "UConverter", php_converter_methods); + php_converter_ce = zend_register_internal_class(&ce TSRMLS_CC); + php_converter_ce->create_object = php_converter_create_object; + memcpy(&php_converter_object_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); + php_converter_object_handlers.clone_obj = php_converter_clone_object; + + /* enum UConverterCallbackReason */ + CONV_REASON_CONST(UNASSIGNED); + CONV_REASON_CONST(ILLEGAL); + CONV_REASON_CONST(IRREGULAR); + CONV_REASON_CONST(RESET); + CONV_REASON_CONST(CLOSE); + CONV_REASON_CONST(CLONE); + + /* enum UConverterType */ + CONV_TYPE_CONST(UNSUPPORTED_CONVERTER); + CONV_TYPE_CONST(SBCS); + CONV_TYPE_CONST(DBCS); + CONV_TYPE_CONST(MBCS); + CONV_TYPE_CONST(LATIN_1); + CONV_TYPE_CONST(UTF8); + CONV_TYPE_CONST(UTF16_BigEndian); + CONV_TYPE_CONST(UTF16_LittleEndian); + CONV_TYPE_CONST(UTF32_BigEndian); + CONV_TYPE_CONST(UTF32_LittleEndian); + CONV_TYPE_CONST(EBCDIC_STATEFUL); + CONV_TYPE_CONST(ISO_2022); + CONV_TYPE_CONST(LMBCS_1); + CONV_TYPE_CONST(LMBCS_2); + CONV_TYPE_CONST(LMBCS_3); + CONV_TYPE_CONST(LMBCS_4); + CONV_TYPE_CONST(LMBCS_5); + CONV_TYPE_CONST(LMBCS_6); + CONV_TYPE_CONST(LMBCS_8); + CONV_TYPE_CONST(LMBCS_11); + CONV_TYPE_CONST(LMBCS_16); + CONV_TYPE_CONST(LMBCS_17); + CONV_TYPE_CONST(LMBCS_18); + CONV_TYPE_CONST(LMBCS_19); + CONV_TYPE_CONST(LMBCS_LAST); + CONV_TYPE_CONST(HZ); + CONV_TYPE_CONST(SCSU); + CONV_TYPE_CONST(ISCII); + CONV_TYPE_CONST(US_ASCII); + CONV_TYPE_CONST(UTF7); + CONV_TYPE_CONST(BOCU1); + CONV_TYPE_CONST(UTF16); + CONV_TYPE_CONST(UTF32); + CONV_TYPE_CONST(CESU8); + CONV_TYPE_CONST(IMAP_MAILBOX); + + return SUCCESS; +} +/* }}} */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/ext/intl/converter/converter.h b/ext/intl/converter/converter.h new file mode 100644 index 0000000000000..bd316fcf983ad --- /dev/null +++ b/ext/intl/converter/converter.h @@ -0,0 +1,28 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Sara Golemon | + +----------------------------------------------------------------------+ +*/ + +#ifndef PHP_INTL_CONVERTER_H +#define PHP_INTL_CONVERTER_H + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "php.h" + +int php_converter_minit(INIT_FUNC_ARGS); + +#endif /* PHP_INTL_CONVERTER_H */ diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index d3d477c97159d..a2c4d77651d4b 100644 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -34,6 +34,8 @@ #include "collator/collator_create.h" #include "collator/collator_error.h" +#include "converter/converter.h" + #include "formatter/formatter.h" #include "formatter/formatter_class.h" #include "formatter/formatter_attr.h" @@ -986,6 +988,9 @@ PHP_MINIT_FUNCTION( intl ) /* Global error handling. */ intl_error_init( NULL TSRMLS_CC ); + /* 'Converter' class for codepage conversions */ + php_converter_minit(INIT_FUNC_ARGS_PASSTHRU); + return SUCCESS; } /* }}} */ diff --git a/ext/intl/tests/uconverter_enum.phpt b/ext/intl/tests/uconverter_enum.phpt new file mode 100644 index 0000000000000..67e02c9d75470 --- /dev/null +++ b/ext/intl/tests/uconverter_enum.phpt @@ -0,0 +1,21 @@ +--TEST-- +UConverter Enumerations +--SKIPIF-- + +--FILE-- + 100); +var_dump(in_array('UTF-7', $avail)); +var_dump(in_array('CESU-8', $avail)); +var_dump(in_array('ISO-8859-1', $avail)); + +$latin1 = UConverter::getAliases('latin1'); +var_dump(in_array('ISO-8859-1', $latin1)); + +--EXPECT-- +bool(true) +bool(true) +bool(true) +bool(true) +bool(true) diff --git a/ext/intl/tests/uconverter_func_basic.phpt b/ext/intl/tests/uconverter_func_basic.phpt new file mode 100644 index 0000000000000..da8956beae128 --- /dev/null +++ b/ext/intl/tests/uconverter_func_basic.phpt @@ -0,0 +1,17 @@ +--TEST-- +Basic UConverter::transcode() usage +--SKIPIF-- + +--FILE-- + +--INI-- +intl.use_exceptions=false +--FILE-- + $subst); + $ret = UConverter::transcode("This is an ascii string", 'ascii', 'utf-8', $opts); + if ($ret === NULL) { + echo "Error: ", intl_get_error_message(), "\n"; + } else { + var_dump($ret); + } + $ret = UConverter::transcode("Snowman: (\xE2\x98\x83)", 'ascii', 'utf-8', $opts); + if ($ret === NULL) { + echo "Error: ", intl_get_error_message(), "\n"; + } else { + var_dump($ret); + } +} + +--EXPECTF-- +string(23) "This is an ascii string" +string(12) "Snowman: (?)" +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR diff --git a/ext/intl/tests/uconverter_oop_algo.phpt b/ext/intl/tests/uconverter_oop_algo.phpt new file mode 100644 index 0000000000000..349182ce32c0f --- /dev/null +++ b/ext/intl/tests/uconverter_oop_algo.phpt @@ -0,0 +1,18 @@ +--TEST-- +UConverter Algorithmic converters +--SKIPIF-- + +--FILE-- +getSourceType()); +var_dump(UConverter::UTF8 === $c->getDestinationType()); + +$c = new UConverter('koi8-r', 'utf-32be'); +var_dump(UConverter::UTF32_BigEndian === $c->getSourceType()); +var_dump(UConverter::SBCS === $c->getDestinationType()); +--EXPECT-- +bool(true) +bool(true) +bool(true) +bool(true) diff --git a/ext/intl/tests/uconverter_oop_basic.phpt b/ext/intl/tests/uconverter_oop_basic.phpt new file mode 100644 index 0000000000000..2b8909ff31e71 --- /dev/null +++ b/ext/intl/tests/uconverter_oop_basic.phpt @@ -0,0 +1,21 @@ +--TEST-- +Basic UConverter::convert() usage +--SKIPIF-- + +--FILE-- +convert("This is an ascii string")); +// urlencode so that non-ascii shows up parsable in phpt file +var_dump(urlencode($c->convert("Espa\xF1ol"))); // U+00F1 LATIN SMALL LETTER N WITH TILDE +var_dump(urlencode($c->convert("Stra\xDFa"))); // U+00DF LATIN SMALL LETTER SHARP S +var_dump(urlencode($c->convert("Stra\xC3\x9Fa", true))); // Reverse prior op + +$k = new UConverter('utf-8', 'koi8-r'); +var_dump(bin2hex($k->convert("\xE4"))); // U+0414 CYRILLIC CAPITAL LETTER DE +--EXPECT-- +string(23) "This is an ascii string" +string(12) "Espa%C3%B1ol" +string(11) "Stra%C3%9Fa" +string(8) "Stra%DFa" +string(4) "d094" diff --git a/ext/intl/tests/uconverter_oop_callback.phpt b/ext/intl/tests/uconverter_oop_callback.phpt new file mode 100644 index 0000000000000..47daf4330586c --- /dev/null +++ b/ext/intl/tests/uconverter_oop_callback.phpt @@ -0,0 +1,52 @@ +--TEST-- +UConverter::convert() w/ Callback Reasons +--SKIPIF-- + +--FILE-- +convert($word); +} +--EXPECT-- +toUCallback(REASON_RESET, ...) +toUCallback(REASON_RESET, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_RESET, ...) +toUCallback(REASON_RESET, ...) +toUCallback(REASON_ILLEGAL, ...) +toUCallback(REASON_RESET, ...) +toUCallback(REASON_ILLEGAL, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +toUCallback(REASON_RESET, ...) +toUCallback(REASON_RESET, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +toUCallback(REASON_CLOSE, ...) +fromUCallback(REASON_CLOSE, ...) +toUCallback(REASON_CLOSE, ...) +fromUCallback(REASON_CLOSE, ...) diff --git a/ext/intl/tests/uconverter_oop_callback_return.phpt b/ext/intl/tests/uconverter_oop_callback_return.phpt new file mode 100644 index 0000000000000..cd7e7a5834fd5 --- /dev/null +++ b/ext/intl/tests/uconverter_oop_callback_return.phpt @@ -0,0 +1,40 @@ +--TEST-- +UConverter::convert() w/ Callback Return Values +--SKIPIF-- + +--FILE-- +convert("\x80\x81\x82\x83")); +// This line will trigger fromUCallback +var_dump($c->convert("\xC3\xB1\xC3\xB2\xC3\xB3\xC3\xB4")); +--EXPECT-- +string(3) "abc" +string(3) "ABC" diff --git a/ext/intl/tests/uconverter_oop_subst.phpt b/ext/intl/tests/uconverter_oop_subst.phpt new file mode 100644 index 0000000000000..d21d95f8d0a12 --- /dev/null +++ b/ext/intl/tests/uconverter_oop_subst.phpt @@ -0,0 +1,24 @@ +--TEST-- +Basic UConverter::convert() w/ Subsitution +--SKIPIF-- + +--INI-- +intl.use_exceptions=false +--FILE-- +') as $subst) { + if (!$c->setSubstChars($subst)) { + echo "**Disallowed\n"; + continue; + } + var_dump($c->convert("This is an ascii string")); + var_dump($c->convert("Snowman: (\xE2\x98\x83)")); +} + +--EXPECT-- +string(23) "This is an ascii string" +string(12) "Snowman: (?)" +**Disallowed +**Disallowed From eab14993febbd3d083c1d45715af122baac140eb Mon Sep 17 00:00:00 2001 From: Sebastian Bergmann Date: Thu, 6 Dec 2012 09:28:35 +0100 Subject: [PATCH 2195/2394] Invoke re2c with --no-generation-date to prevent unintentional / unnecessary changes in generated files. --- Makefile.frag | 4 ++-- Zend/Makefile.am | 4 ++-- ext/date/lib/parse_date.c | 2 +- ext/date/lib/parse_iso_intervals.c | 2 +- ext/pdo/Makefile.frag | 2 +- ext/pdo/pdo_sql_parser.c | 2 +- ext/phar/Makefile.frag | 2 +- ext/phar/phar_path_check.c | 2 +- ext/standard/Makefile.frag | 4 ++-- ext/standard/url_scanner_ex.c | 2 +- ext/standard/var_unserializer.c | 2 +- win32/build/Makefile | 4 ++-- 12 files changed, 16 insertions(+), 16 deletions(-) diff --git a/Makefile.frag b/Makefile.frag index c8b3cb2d8062a..12646c20add75 100644 --- a/Makefile.frag +++ b/Makefile.frag @@ -7,7 +7,7 @@ $(builddir)/zend_language_scanner.lo: $(srcdir)/zend_language_parser.h $(builddir)/zend_ini_scanner.lo: $(srcdir)/zend_ini_parser.h $(srcdir)/zend_language_scanner.c: $(srcdir)/zend_language_scanner.l - @(cd $(top_srcdir); $(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c Zend/zend_language_scanner.l) + @(cd $(top_srcdir); $(RE2C) $(RE2C_FLAGS) --no-generation-date --case-inverted -cbdFt Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c Zend/zend_language_scanner.l) $(srcdir)/zend_language_parser.h: $(srcdir)/zend_language_parser.c $(srcdir)/zend_language_parser.c: $(srcdir)/zend_language_parser.y @@ -18,6 +18,6 @@ $(srcdir)/zend_ini_parser.c: $(srcdir)/zend_ini_parser.y @$(YACC) -p ini_ -v -d $(srcdir)/zend_ini_parser.y -o $@ $(srcdir)/zend_ini_scanner.c: $(srcdir)/zend_ini_scanner.l - @(cd $(top_srcdir); $(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l) + @(cd $(top_srcdir); $(RE2C) $(RE2C_FLAGS) --no-generation-date --case-inverted -cbdFt Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l) $(builddir)/zend_indent.lo $(builddir)/zend_highlight.lo $(builddir)/zend_compile.lo: $(srcdir)/zend_language_parser.h diff --git a/Zend/Makefile.am b/Zend/Makefile.am index e5757fac56d04..6417f3eb141ed 100644 --- a/Zend/Makefile.am +++ b/Zend/Makefile.am @@ -32,7 +32,7 @@ zend_ini_scanner.lo: zend_ini_parser.h # Language parser/scanner rules zend_language_scanner.c: $(srcdir)/zend_language_scanner.l - $(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt $(srcdir)/zend_language_scanner_defs.h -o$@ $(srcdir)/zend_language_scanner.l + $(RE2C) $(RE2C_FLAGS) --no-generation-date --case-inverted -cbdFt $(srcdir)/zend_language_scanner_defs.h -o$@ $(srcdir)/zend_language_scanner.l zend_language_parser.h: zend_language_parser.c zend_language_parser.c: $(srcdir)/zend_language_parser.y @@ -44,7 +44,7 @@ zend_ini_parser.c: $(srcdir)/zend_ini_parser.y $(YACC) -p ini_ -v -d $(srcdir)/zend_ini_parser.y -o zend_ini_parser.c zend_ini_scanner.c: $(srcdir)/zend_ini_scanner.l - $(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt $(srcdir)/zend_ini_scanner_defs.h -o$@ $(srcdir)/zend_ini_scanner.l + $(RE2C) $(RE2C_FLAGS) --no-generation-date --case-inverted -cbdFt $(srcdir)/zend_ini_scanner_defs.h -o$@ $(srcdir)/zend_ini_scanner.l zend_ini_parser.h: zend_ini_parser.c diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index 4829da6c9155c..1ccddd2ad801b 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Sep 30 20:14:42 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "ext/date/lib/parse_date.re" /* +----------------------------------------------------------------------+ diff --git a/ext/date/lib/parse_iso_intervals.c b/ext/date/lib/parse_iso_intervals.c index 6be5bf18f39be..fce91cfa4f94b 100644 --- a/ext/date/lib/parse_iso_intervals.c +++ b/ext/date/lib/parse_iso_intervals.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Mon Dec 5 22:02:35 2011 */ +/* Generated by re2c 0.13.5 */ #line 1 "ext/date/lib/parse_iso_intervals.re" /* +----------------------------------------------------------------------+ diff --git a/ext/pdo/Makefile.frag b/ext/pdo/Makefile.frag index 98f5c5f2ad7dd..5ba5f80840ec6 100644 --- a/ext/pdo/Makefile.frag +++ b/ext/pdo/Makefile.frag @@ -6,7 +6,7 @@ PDO_HEADER_FILES= \ $(srcdir)/pdo_sql_parser.c: $(srcdir)/pdo_sql_parser.re - (cd $(top_srcdir); $(RE2C) -o ext/pdo/pdo_sql_parser.c ext/pdo/pdo_sql_parser.re) + (cd $(top_srcdir); $(RE2C) --no-generation-date -o ext/pdo/pdo_sql_parser.c ext/pdo/pdo_sql_parser.re) install-pdo-headers: @echo "Installing PDO headers: $(INSTALL_ROOT)$(phpincludedir)/ext/pdo/" diff --git a/ext/pdo/pdo_sql_parser.c b/ext/pdo/pdo_sql_parser.c index 0267d15454595..365b02284464f 100644 --- a/ext/pdo/pdo_sql_parser.c +++ b/ext/pdo/pdo_sql_parser.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Thu Apr 19 12:42:11 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "ext/pdo/pdo_sql_parser.re" /* +----------------------------------------------------------------------+ diff --git a/ext/phar/Makefile.frag b/ext/phar/Makefile.frag index b1c820f276faa..e2b016d846ffb 100644 --- a/ext/phar/Makefile.frag +++ b/ext/phar/Makefile.frag @@ -1,5 +1,5 @@ $(srcdir)/phar_path_check.c: $(srcdir)/phar_path_check.re - @(cd $(top_srcdir); $(RE2C) -b -o ext/phar/phar_path_check.c ext/phar/phar_path_check.re) + @(cd $(top_srcdir); $(RE2C) --no-generation-date -b -o ext/phar/phar_path_check.c ext/phar/phar_path_check.re) pharcmd: $(builddir)/phar.php $(builddir)/phar.phar diff --git a/ext/phar/phar_path_check.c b/ext/phar/phar_path_check.c index 7a8ea6089f3c3..d03a2b3f28ef2 100644 --- a/ext/phar/phar_path_check.c +++ b/ext/phar/phar_path_check.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jan 1 10:36:11 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "ext/phar/phar_path_check.re" /* +----------------------------------------------------------------------+ diff --git a/ext/standard/Makefile.frag b/ext/standard/Makefile.frag index 4e949621838b6..8b6e3e233ab17 100644 --- a/ext/standard/Makefile.frag +++ b/ext/standard/Makefile.frag @@ -1,9 +1,9 @@ $(srcdir)/var_unserializer.c: $(srcdir)/var_unserializer.re - @(cd $(top_srcdir); $(RE2C) -b -o ext/standard/var_unserializer.c ext/standard/var_unserializer.re) + @(cd $(top_srcdir); $(RE2C) --no-generation-date -b -o ext/standard/var_unserializer.c ext/standard/var_unserializer.re) $(srcdir)/url_scanner_ex.c: $(srcdir)/url_scanner_ex.re - @(cd $(top_srcdir); $(RE2C) -b -o ext/standard/url_scanner_ex.c ext/standard/url_scanner_ex.re) + @(cd $(top_srcdir); $(RE2C) --no-generation-date -b -o ext/standard/url_scanner_ex.c ext/standard/url_scanner_ex.re) $(builddir)/info.lo: $(builddir)/../../main/build-defs.h diff --git a/ext/standard/url_scanner_ex.c b/ext/standard/url_scanner_ex.c index a034c3be40a11..f66b56220643e 100644 --- a/ext/standard/url_scanner_ex.c +++ b/ext/standard/url_scanner_ex.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Tue May 15 13:07:17 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "ext/standard/url_scanner_ex.re" /* +----------------------------------------------------------------------+ diff --git a/ext/standard/var_unserializer.c b/ext/standard/var_unserializer.c index 21f99582a797c..59995fb1a4a4e 100644 --- a/ext/standard/var_unserializer.c +++ b/ext/standard/var_unserializer.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Sun Jan 1 10:36:31 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "ext/standard/var_unserializer.re" /* +----------------------------------------------------------------------+ diff --git a/win32/build/Makefile b/win32/build/Makefile index e2d62545b8c78..057b5845499d8 100644 --- a/win32/build/Makefile +++ b/win32/build/Makefile @@ -55,10 +55,10 @@ Zend\zend_language_parser.c Zend\zend_language_parser.h: Zend\zend_language_pars !if $(RE2C) != "" Zend\zend_ini_scanner.c: Zend\zend_ini_scanner.l - $(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l + $(RE2C) $(RE2C_FLAGS) --no-generation-date --case-inverted -cbdFt Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l Zend\zend_language_scanner.c: Zend\zend_language_scanner.l - $(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c Zend/zend_language_scanner.l + $(RE2C) $(RE2C_FLAGS) --no-generation-date --case-inverted -cbdFt Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c Zend/zend_language_scanner.l !endif !if $(PGOMGR) != "" From 8ca4288fd2432cf3eab1aeb3992ae4d53468c15c Mon Sep 17 00:00:00 2001 From: Sebastian Bergmann Date: Thu, 6 Dec 2012 09:43:27 +0100 Subject: [PATCH 2196/2394] Leftover: Invoke re2c with --no-generation-date to prevent unintentional / unnecessary changes in generated files. --- Zend/zend_ini_scanner.c | 2 +- Zend/zend_ini_scanner_defs.h | 2 +- Zend/zend_language_scanner.c | 2 +- Zend/zend_language_scanner_defs.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Zend/zend_ini_scanner.c b/Zend/zend_ini_scanner.c index 1c7f306fe399a..cb5f62ccf1868 100644 --- a/Zend/zend_ini_scanner.c +++ b/Zend/zend_ini_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Fri Nov 16 18:27:25 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "Zend/zend_ini_scanner.l" /* +----------------------------------------------------------------------+ diff --git a/Zend/zend_ini_scanner_defs.h b/Zend/zend_ini_scanner_defs.h index b985f3404a35f..287d7bc1fbb9f 100644 --- a/Zend/zend_ini_scanner_defs.h +++ b/Zend/zend_ini_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Fri Nov 16 18:27:25 2012 */ +/* Generated by re2c 0.13.5 */ #line 3 "Zend/zend_ini_scanner_defs.h" enum YYCONDTYPE { diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 48be8eaf7de3f..248f6185fa02b 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Wed Nov 14 17:50:16 2012 */ +/* Generated by re2c 0.13.5 */ #line 1 "Zend/zend_language_scanner.l" /* +----------------------------------------------------------------------+ diff --git a/Zend/zend_language_scanner_defs.h b/Zend/zend_language_scanner_defs.h index de220af71bb57..5926e3c61d971 100644 --- a/Zend/zend_language_scanner_defs.h +++ b/Zend/zend_language_scanner_defs.h @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.5 on Wed Nov 14 17:50:16 2012 */ +/* Generated by re2c 0.13.5 */ #line 3 "Zend/zend_language_scanner_defs.h" enum YYCONDTYPE { From e3b2a5cf744d6d6dc8e4587cd081b9f1b662cd5a Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 6 Dec 2012 13:14:31 +0400 Subject: [PATCH 2197/2394] Generatirs are going to be used less than regular functions --- Zend/zend_execute.c | 2 +- Zend/zend_vm_def.h | 2 +- Zend/zend_vm_execute.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 1098c9efaf6b5..e6034ba2030da 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1598,7 +1598,7 @@ static zend_always_inline zend_execute_data *i_create_execute_data_from_op_array * restore it simply by replacing a pointer. The same segment also keeps * a copy of previous execute_data and passed parameters. */ - if (op_array->fn_flags & ZEND_ACC_GENERATOR) { + if (UNEXPECTED((op_array->fn_flags & ZEND_ACC_GENERATOR) != 0)) { /* Prepend the regular stack frame with copy on prev_execute_data * and passed arguments */ diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 2b65275fa6ba6..edbffe12c9902 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2049,7 +2049,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; } - if (EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) { + if (UNEXPECTED((EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { if (RETURN_VALUE_USED(opline)) { EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 5971cc9047218..80967bdfb3c8e 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -590,7 +590,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; } - if (EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) { + if (UNEXPECTED((EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { if (RETURN_VALUE_USED(opline)) { EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); } From 16ec6fa2064d243a89e3f551ac1c85f45ee4a996 Mon Sep 17 00:00:00 2001 From: Sebastian Bergmann Date: Thu, 6 Dec 2012 11:03:37 +0100 Subject: [PATCH 2198/2394] Cleanup NEWS --- NEWS | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/NEWS b/NEWS index 984b2bf5abd41..98d54b28016a1 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,23 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 - General improvements: + . Added generators and coroutines (https://wiki.php.net/rfc/generators). + (Nikita Popov) + . Added "finally" keyword (https://wiki.php.net/rfc/finally). (Laruence) + . Added simplified password hashing API + (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) + . Added systemtap support by enabling systemtap compatible dtrace probes on + linux. (David Soria Parra) + . Added support for list in foreach (https://wiki.php.net/rfc/foreachlist). + (Laruence) + . Added support for using empty() on the result of function calls and + other expressions (https://wiki.php.net/rfc/empty_isset_exprs). + (Nikita Popov) + . Added support for constant array/string dereferencing. (Laruence) + . Improved set_exception_handler while doing reset.(Laruence) + . Removed php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), + zend_logo_guid(). (Adnrew Faulds) + . Dropped support for Windows XP and 2003. (Pierre) . Optimized access to temporary and compiled VM variables. 8% less memory reads. (Dmitry) . The VM stacks for passing function arguments and syntaticaly nested calls @@ -10,23 +27,6 @@ PHP NEWS execution is calculated at compile time and preallocated at once. As result all the stack push operatins don't require checks for stack overflow any more. (Dmitry) - . Added support for generators. (Nikita Popov) - . Add simplified password hashing API - (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) - . Add generators and coroutines (https://wiki.php.net/rfc/generators). - (Nikita Popov) - . Support list in foreach (https://wiki.php.net/rfc/foreachlist). (Laruence) - . Implemented 'finally' keyword (https://wiki.php.net/rfc/finally). (Laruence) - . Drop Windows XP and 2003 support. (Pierre) - . Improve set_exception_handler while doing reset.(Laruence) - . Support constant array/string dereferencing. (Laruence) - . Add support for using empty() on the result of function calls and - other expressions (https://wiki.php.net/rfc/empty_isset_exprs). - (Nikita Popov) - . Remove php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), - zend_logo_guid(). (Adnrew Faulds) - . Add systemtap support by enabling systemtap compatible dtrace probes on - linux. (David Soria Parra) - Calendar: . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) From b7091aaf0137d97cf4aa4a402ec50b3946d369c0 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Mon, 10 Dec 2012 22:12:09 +0800 Subject: [PATCH 2199/2394] Deprecate ext/mysql. Per https://wiki.php.net/rfc/mysql_deprecation, connecting to a MySQL database via ext/mysql now generates an E_DEPRECATED error. This commit includes the minimal EXPECTF updates required for the test suite to pass: it may be preferable to refactor some of the tests to suppress deprecation errors in situations where no other error is expected from mysql_[p]connect(), but I'm not enough of a MySQL expert to want to get my hands that dirty in a long standing test suite. --- NEWS | 5 +++++ UPGRADING | 4 ++++ ext/mysql/php_mysql.c | 4 ++++ ext/mysql/tests/001.phpt | 3 +++ ext/mysql/tests/002.phpt | 1 + ext/mysql/tests/003.phpt | 1 + ext/mysql/tests/bug47438.phpt | 3 ++- ext/mysql/tests/bug48754.phpt | 8 ++++++++ ext/mysql/tests/bug51242.phpt | 1 + ext/mysql/tests/bug53649.phpt | 5 +++-- ext/mysql/tests/bug55473.phpt | 11 +++++++++- ext/mysql/tests/mysql_affected_rows.phpt | 1 + ext/mysql/tests/mysql_client_encoding.phpt | 1 + ext/mysql/tests/mysql_close.phpt | 1 + ext/mysql/tests/mysql_connect.phpt | 20 +++++++++++++++++++ ext/mysql/tests/mysql_constants.phpt | 3 ++- ext/mysql/tests/mysql_create_db.phpt | 3 +++ ext/mysql/tests/mysql_data_seek.phpt | 2 ++ ext/mysql/tests/mysql_db_name.phpt | 2 ++ ext/mysql/tests/mysql_db_query.phpt | 1 + ext/mysql/tests/mysql_deprecated_api.phpt | 3 ++- ext/mysql/tests/mysql_drop_db.phpt | 3 ++- ext/mysql/tests/mysql_errno.phpt | 1 + ext/mysql/tests/mysql_error.phpt | 2 ++ ext/mysql/tests/mysql_fetch_array.phpt | 1 + ext/mysql/tests/mysql_fetch_assoc.phpt | 3 +++ ext/mysql/tests/mysql_fetch_field.phpt | 1 + ext/mysql/tests/mysql_fetch_lengths.phpt | 1 + ext/mysql/tests/mysql_fetch_object.phpt | 1 + ext/mysql/tests/mysql_fetch_row.phpt | 3 ++- ext/mysql/tests/mysql_field_flags.phpt | 2 ++ ext/mysql/tests/mysql_field_len.phpt | 2 ++ ext/mysql/tests/mysql_field_name.phpt | 2 ++ ext/mysql/tests/mysql_field_seek.phpt | 2 ++ ext/mysql/tests/mysql_field_table.phpt | 2 ++ ext/mysql/tests/mysql_field_type.phpt | 2 ++ ext/mysql/tests/mysql_free_result.phpt | 1 + ext/mysql/tests/mysql_get_host_info.phpt | 1 + ext/mysql/tests/mysql_get_proto_info.phpt | 1 + ext/mysql/tests/mysql_get_server_info.phpt | 1 + ext/mysql/tests/mysql_info.phpt | 3 ++- ext/mysql/tests/mysql_insert_id.phpt | 2 ++ ext/mysql/tests/mysql_list_dbs.phpt | 3 ++- ext/mysql/tests/mysql_list_fields.phpt | 1 + ext/mysql/tests/mysql_list_processes.phpt | 3 ++- ext/mysql/tests/mysql_list_tables.phpt | 1 + ext/mysql/tests/mysql_max_links.phpt | 12 ++++++++++- ext/mysql/tests/mysql_max_persistent.phpt | 8 +++++++- .../mysql_mysqlnd_read_timeout_long.phpt | 3 ++- ext/mysql/tests/mysql_num_fields.phpt | 2 ++ ext/mysql/tests/mysql_num_rows.phpt | 2 ++ ext/mysql/tests/mysql_pconn_disable.phpt | 9 ++++++++- ext/mysql/tests/mysql_pconn_kill.phpt | 7 +++++++ ext/mysql/tests/mysql_pconn_max_links.phpt | 5 +++++ ext/mysql/tests/mysql_pconn_reuse.phpt | 11 +++++++++- ext/mysql/tests/mysql_pconnect.phpt | 12 +++++++++++ ext/mysql/tests/mysql_ping.phpt | 1 + ext/mysql/tests/mysql_query.phpt | 1 + .../mysql_query_load_data_openbasedir.phpt | 3 +++ ext/mysql/tests/mysql_real_escape_string.phpt | 1 + ext/mysql/tests/mysql_result.phpt | 2 ++ ext/mysql/tests/mysql_select_db.phpt | 1 + ext/mysql/tests/mysql_set_charset.phpt | 1 + ext/mysql/tests/mysql_stat.phpt | 2 ++ ext/mysql/tests/mysql_tablename.phpt | 2 ++ ext/mysql/tests/mysql_thread_id.phpt | 4 +++- ext/mysql/tests/mysql_trace_mode.phpt | 1 + ext/mysql/tests/mysql_unbuffered_query.phpt | 1 + 68 files changed, 202 insertions(+), 17 deletions(-) diff --git a/NEWS b/NEWS index 98d54b28016a1..ce5f08cc0bd6e 100644 --- a/NEWS +++ b/NEWS @@ -163,6 +163,11 @@ PHP NEWS . mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw E_DEPRECATED. (GoogleGuy) +- MySQL + . This extension is now deprecated, and deprecation warnings will be generated + when connections are established to databases via mysql_connect(), + mysql_pconnect(), or through implicit connection. (Adam) + - MySQLi . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. Known for stability problems. (Andrey) diff --git a/UPGRADING b/UPGRADING index b01a399697b39..f65e8687049ca 100755 --- a/UPGRADING +++ b/UPGRADING @@ -85,6 +85,10 @@ PHP 5.5 UPGRADE NOTES 3. Deprecated Functionality ======================================== +- The original MySQL extension is now deprecated, and will generate deprecation + warnings when connecting to a database through mysql_connect(), + mysql_pconnect() or by establishing an implicit connection. Use MySQLi or PDO + instead. - The preg_replace /e modifier is now deprecated. Use preg_replace_callback instead. (https://wiki.php.net/rfc/remove_preg_replace_eval_modifier) diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index f1aab94f8a2e2..dc7f108b5d76a 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -731,6 +731,10 @@ static void php_mysql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent) zend_bool free_host=0, new_link=0; long connect_timeout; + php_error_docref(NULL TSRMLS_CC, + E_DEPRECATED, + "The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead"); + #if !defined(MYSQL_USE_MYSQLND) if ((MYSQL_VERSION_ID / 100) != (mysql_get_client_version() / 100)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, diff --git a/ext/mysql/tests/001.phpt b/ext/mysql/tests/001.phpt index 72b6614771e1a..8782fd125271a 100644 --- a/ext/mysql/tests/001.phpt +++ b/ext/mysql/tests/001.phpt @@ -29,5 +29,8 @@ var_dump($test); print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d %unicode|string%(2) "11" done! diff --git a/ext/mysql/tests/002.phpt b/ext/mysql/tests/002.phpt index 8355c5f11ea29..8f53f4d724f6a 100644 --- a/ext/mysql/tests/002.phpt +++ b/ext/mysql/tests/002.phpt @@ -37,6 +37,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d resource(%d) of type (mysql link) bool(true) bool(true) diff --git a/ext/mysql/tests/003.phpt b/ext/mysql/tests/003.phpt index 2d0b68b9f8c1c..365abc20e99a7 100644 --- a/ext/mysql/tests/003.phpt +++ b/ext/mysql/tests/003.phpt @@ -57,6 +57,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d ==stdClass== object(stdClass)#%d (1) { [%u|b%"a"]=> diff --git a/ext/mysql/tests/bug47438.phpt b/ext/mysql/tests/bug47438.phpt index 11f0ff33b8552..fa7b3e6a2bdff 100644 --- a/ext/mysql/tests/bug47438.phpt +++ b/ext/mysql/tests/bug47438.phpt @@ -46,7 +46,8 @@ if (!mysql_select_db($db, $link) || mysql_close($link); ?> ---EXPECT-- +--EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d 0.a 1.b 2.c diff --git a/ext/mysql/tests/bug48754.phpt b/ext/mysql/tests/bug48754.phpt index fb322f4615716..b461db3320637 100644 --- a/ext/mysql/tests/bug48754.phpt +++ b/ext/mysql/tests/bug48754.phpt @@ -68,6 +68,8 @@ var_dump($link); ?> --EXPECTF-- Explicit connection on close + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d Expect same thread id for $link and default conn: bool(true) resource(%d) of type (mysql link) resource(%d) of type (Unknown) @@ -75,18 +77,24 @@ resource(%d) of type (Unknown) Warning: mysql_close(): no MySQL-Link resource supplied in %s on line %d Closing default link + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d Expect same thread id for $link and default conn but not the previous: bool(true) resource(%d) of type (mysql link) resource(%d) of type (mysql link) resource(%d) of type (Unknown) Explicit resource and pconnect + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d resource(%d) of type (mysql link persistent) resource(%d) of type (Unknown) Warning: mysql_close(): no MySQL-Link resource supplied in %s on line %d Default link and pconnect + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d resource(%d) of type (mysql link persistent) resource(%d) of type (mysql link persistent) resource(%d) of type (Unknown) diff --git a/ext/mysql/tests/bug51242.phpt b/ext/mysql/tests/bug51242.phpt index 9b62cdb4cd473..6801d3021f3dd 100644 --- a/ext/mysql/tests/bug51242.phpt +++ b/ext/mysql/tests/bug51242.phpt @@ -35,4 +35,5 @@ if ($link = my_mysql_connect($host, $user, $passwd, $db, null, $socket)) { } ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d resource(%d) of type (mysql link) diff --git a/ext/mysql/tests/bug53649.phpt b/ext/mysql/tests/bug53649.phpt index 70bf9bed3630b..7ccdf08e5f46f 100644 --- a/ext/mysql/tests/bug53649.phpt +++ b/ext/mysql/tests/bug53649.phpt @@ -67,5 +67,6 @@ mysql_close($link); unlink('bug53649.data'); ?> ---EXPECT-- -done \ No newline at end of file +--EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done diff --git a/ext/mysql/tests/bug55473.phpt b/ext/mysql/tests/bug55473.phpt index df584bdef9ca3..1cc2dc928251c 100644 --- a/ext/mysql/tests/bug55473.phpt +++ b/ext/mysql/tests/bug55473.phpt @@ -68,12 +68,21 @@ mysql.allow_persistent=1 print "done!"; ?> --EXPECTF-- +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [003] reconnect 0 + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [005] Setting openened files... [003] reconnect 1 + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [007] Opened files as expected [003] reconnect 2 + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [007] Opened files as expected [003] reconnect 3 + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [007] Opened files as expected -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_affected_rows.phpt b/ext/mysql/tests/mysql_affected_rows.phpt index 145e1f5c0b95a..2449ac416e2a3 100644 --- a/ext/mysql/tests/mysql_affected_rows.phpt +++ b/ext/mysql/tests/mysql_affected_rows.phpt @@ -122,4 +122,5 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_client_encoding.phpt b/ext/mysql/tests/mysql_client_encoding.phpt index 8aa67a03ac0b0..5b21765ddb29a 100644 --- a/ext/mysql/tests/mysql_client_encoding.phpt +++ b/ext/mysql/tests/mysql_client_encoding.phpt @@ -67,4 +67,5 @@ if (false !== ($tmp = @mysql_client_encoding($link))) print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_close.phpt b/ext/mysql/tests/mysql_close.phpt index 8f305ba7801a7..e676511961c25 100644 --- a/ext/mysql/tests/mysql_close.phpt +++ b/ext/mysql/tests/mysql_close.phpt @@ -36,4 +36,5 @@ if (false !== ($tmp = @mysql_query("SELECT 1", $link))) print "done!\n"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_connect.phpt b/ext/mysql/tests/mysql_connect.phpt index 715824804076d..2b73092375da8 100644 --- a/ext/mysql/tests/mysql_connect.phpt +++ b/ext/mysql/tests/mysql_connect.phpt @@ -104,5 +104,25 @@ if (!ini_get('sql.safe_mode')) { print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_connect(): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_constants.phpt b/ext/mysql/tests/mysql_constants.phpt index 1346100209553..e68774503c18e 100644 --- a/ext/mysql/tests/mysql_constants.phpt +++ b/ext/mysql/tests/mysql_constants.phpt @@ -62,4 +62,5 @@ if (!empty($expected_constants)) { print "done!"; ?> --EXPECTF-- -done! \ No newline at end of file +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_create_db.phpt b/ext/mysql/tests/mysql_create_db.phpt index bc91964f5032d..0b6d58a09e745 100644 --- a/ext/mysql/tests/mysql_create_db.phpt +++ b/ext/mysql/tests/mysql_create_db.phpt @@ -53,4 +53,7 @@ if (!mysql_query("DROP DATABASE IF EXISTS mysqlcreatedb", $link)) mysql_close($link); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_data_seek.phpt b/ext/mysql/tests/mysql_data_seek.phpt index 46a0f86bdeaf7..72d3e6327405f 100644 --- a/ext/mysql/tests/mysql_data_seek.phpt +++ b/ext/mysql/tests/mysql_data_seek.phpt @@ -67,6 +67,8 @@ print "done!\n"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_data_seek(): Offset 4 is invalid for MySQL result index %d (or the query data is unbuffered) in %s on line %d Warning: mysql_data_seek(): Offset -1 is invalid for MySQL result index %d (or the query data is unbuffered) in %s on line %d diff --git a/ext/mysql/tests/mysql_db_name.phpt b/ext/mysql/tests/mysql_db_name.phpt index b7f9042209f3d..92878e994dc1c 100644 --- a/ext/mysql/tests/mysql_db_name.phpt +++ b/ext/mysql/tests/mysql_db_name.phpt @@ -58,6 +58,8 @@ mysql_close($link); print "done!\n"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_db_name(): Unable to jump to row -1 on MySQL result index %d in %s on line %d Warning: mysql_db_name(): Unable to jump to row %d on MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_db_query.phpt b/ext/mysql/tests/mysql_db_query.phpt index bb837dd6c01dc..291fbfaac61d3 100644 --- a/ext/mysql/tests/mysql_db_query.phpt +++ b/ext/mysql/tests/mysql_db_query.phpt @@ -62,4 +62,5 @@ print "done!\n"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_deprecated_api.phpt b/ext/mysql/tests/mysql_deprecated_api.phpt index d54307ca0eff5..ebf72375cf626 100644 --- a/ext/mysql/tests/mysql_deprecated_api.phpt +++ b/ext/mysql/tests/mysql_deprecated_api.phpt @@ -75,4 +75,5 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- -done! \ No newline at end of file +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_drop_db.phpt b/ext/mysql/tests/mysql_drop_db.phpt index bd729e7ab85ac..3281b8a333f0f 100644 --- a/ext/mysql/tests/mysql_drop_db.phpt +++ b/ext/mysql/tests/mysql_drop_db.phpt @@ -52,4 +52,5 @@ if (!mysql_query("DROP DATABASE IF EXISTS mysqldropdb", $link)) mysql_close($link); ?> --EXPECTF-- -done! \ No newline at end of file +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_errno.phpt b/ext/mysql/tests/mysql_errno.phpt index 8cfa7bd33bfd0..c9c2956290bf6 100644 --- a/ext/mysql/tests/mysql_errno.phpt +++ b/ext/mysql/tests/mysql_errno.phpt @@ -55,6 +55,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d int(0) int(%d) diff --git a/ext/mysql/tests/mysql_error.phpt b/ext/mysql/tests/mysql_error.phpt index aae4480174f73..a2cf7e003430a 100644 --- a/ext/mysql/tests/mysql_error.phpt +++ b/ext/mysql/tests/mysql_error.phpt @@ -62,6 +62,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_error(): %d is not a valid MySQL-Link resource in %s on line %d bool(false) done! diff --git a/ext/mysql/tests/mysql_fetch_array.phpt b/ext/mysql/tests/mysql_fetch_array.phpt index 362cf99ddc672..8ccefd0242694 100644 --- a/ext/mysql/tests/mysql_fetch_array.phpt +++ b/ext/mysql/tests/mysql_fetch_array.phpt @@ -281,6 +281,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [005] array(4) { [0]=> diff --git a/ext/mysql/tests/mysql_fetch_assoc.phpt b/ext/mysql/tests/mysql_fetch_assoc.phpt index 3c5ca79b2d93d..048613a6be402 100644 --- a/ext/mysql/tests/mysql_fetch_assoc.phpt +++ b/ext/mysql/tests/mysql_fetch_assoc.phpt @@ -63,6 +63,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [005] array(2) { [%u|b%"id"]=> @@ -87,6 +88,8 @@ array(5) { } Warning: mysql_fetch_assoc(): %d is not a valid MySQL result resource in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [010] array(5) { [%u|b%"id"]=> diff --git a/ext/mysql/tests/mysql_fetch_field.phpt b/ext/mysql/tests/mysql_fetch_field.phpt index ef03279087154..85c1fd6f7ef0e 100644 --- a/ext/mysql/tests/mysql_fetch_field.phpt +++ b/ext/mysql/tests/mysql_fetch_field.phpt @@ -156,6 +156,7 @@ require_once('skipifconnectfailure.inc'); require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d object(stdClass)#%d (13) { [%u|b%"name"]=> %unicode|string%(2) "ID" diff --git a/ext/mysql/tests/mysql_fetch_lengths.phpt b/ext/mysql/tests/mysql_fetch_lengths.phpt index 4793e2649bae0..f0fbbb7bb875f 100644 --- a/ext/mysql/tests/mysql_fetch_lengths.phpt +++ b/ext/mysql/tests/mysql_fetch_lengths.phpt @@ -39,6 +39,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(2) { [0]=> int(1) diff --git a/ext/mysql/tests/mysql_fetch_object.phpt b/ext/mysql/tests/mysql_fetch_object.phpt index c11631e04cac6..666d0ee821a0a 100644 --- a/ext/mysql/tests/mysql_fetch_object.phpt +++ b/ext/mysql/tests/mysql_fetch_object.phpt @@ -82,6 +82,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d object(stdClass)#%d (2) { [%u|b%"ID"]=> %unicode|string%(1) "1" diff --git a/ext/mysql/tests/mysql_fetch_row.phpt b/ext/mysql/tests/mysql_fetch_row.phpt index 8d6b9585beea2..0ed932e2c082a 100644 --- a/ext/mysql/tests/mysql_fetch_row.phpt +++ b/ext/mysql/tests/mysql_fetch_row.phpt @@ -41,6 +41,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [004] array(2) { [0]=> @@ -53,4 +54,4 @@ bool(false) Warning: mysql_fetch_row(): %d is not a valid MySQL result resource in %s on line %d bool(false) -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_field_flags.phpt b/ext/mysql/tests/mysql_field_flags.phpt index e07e041d2a38b..7f1b366d5cb1b 100644 --- a/ext/mysql/tests/mysql_field_flags.phpt +++ b/ext/mysql/tests/mysql_field_flags.phpt @@ -144,6 +144,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_field_flags() expects exactly 2 parameters, 1 given in %s on line %d Warning: mysql_field_flags(): Field -1 is invalid for MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_field_len.phpt b/ext/mysql/tests/mysql_field_len.phpt index a740c62439dd1..119d3521646c9 100644 --- a/ext/mysql/tests/mysql_field_len.phpt +++ b/ext/mysql/tests/mysql_field_len.phpt @@ -47,6 +47,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_field_len() expects exactly 2 parameters, 1 given in %s on line %d Warning: mysql_field_len(): Field -1 is invalid for MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_field_name.phpt b/ext/mysql/tests/mysql_field_name.phpt index c87ac188f7546..85f6c42d93aff 100644 --- a/ext/mysql/tests/mysql_field_name.phpt +++ b/ext/mysql/tests/mysql_field_name.phpt @@ -46,6 +46,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_field_name() expects exactly 2 parameters, 1 given in %s on line %d Warning: mysql_field_name(): Field -1 is invalid for MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_field_seek.phpt b/ext/mysql/tests/mysql_field_seek.phpt index 7e8b313c879e7..8487493a88093 100644 --- a/ext/mysql/tests/mysql_field_seek.phpt +++ b/ext/mysql/tests/mysql_field_seek.phpt @@ -44,6 +44,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_field_seek(): Field -1 is invalid for MySQL result index %d in %s on line %d bool(false) object(stdClass)#%d (13) { diff --git a/ext/mysql/tests/mysql_field_table.phpt b/ext/mysql/tests/mysql_field_table.phpt index 707d1df987ee2..826651a855d03 100644 --- a/ext/mysql/tests/mysql_field_table.phpt +++ b/ext/mysql/tests/mysql_field_table.phpt @@ -46,6 +46,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_field_table() expects exactly 2 parameters, 1 given in %s on line %d Warning: mysql_field_table(): Field -1 is invalid for MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_field_type.phpt b/ext/mysql/tests/mysql_field_type.phpt index c737b4e3f2c68..c767cab6f14bd 100644 --- a/ext/mysql/tests/mysql_field_type.phpt +++ b/ext/mysql/tests/mysql_field_type.phpt @@ -46,6 +46,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_field_type() expects exactly 2 parameters, 1 given in %s on line %d Warning: mysql_field_type(): Field -1 is invalid for MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_free_result.phpt b/ext/mysql/tests/mysql_free_result.phpt index fe132d8c2d3c5..90498bd59a276 100644 --- a/ext/mysql/tests/mysql_free_result.phpt +++ b/ext/mysql/tests/mysql_free_result.phpt @@ -44,6 +44,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d bool(true) Warning: mysql_free_result(): %d is not a valid MySQL result resource in %s on line %d diff --git a/ext/mysql/tests/mysql_get_host_info.phpt b/ext/mysql/tests/mysql_get_host_info.phpt index 443910c319041..4b21ddbb41ef9 100644 --- a/ext/mysql/tests/mysql_get_host_info.phpt +++ b/ext/mysql/tests/mysql_get_host_info.phpt @@ -41,4 +41,5 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_get_proto_info.phpt b/ext/mysql/tests/mysql_get_proto_info.phpt index 043fb62043a80..3e1481121e104 100644 --- a/ext/mysql/tests/mysql_get_proto_info.phpt +++ b/ext/mysql/tests/mysql_get_proto_info.phpt @@ -31,4 +31,5 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_get_server_info.phpt b/ext/mysql/tests/mysql_get_server_info.phpt index e806335e29c11..ad192e4722cf8 100644 --- a/ext/mysql/tests/mysql_get_server_info.phpt +++ b/ext/mysql/tests/mysql_get_server_info.phpt @@ -36,4 +36,5 @@ if (NULL !== ($tmp = @mysql_get_server_info('too many', 'just too many'))) print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_info.phpt b/ext/mysql/tests/mysql_info.phpt index 464578c8a568a..c478679042404 100644 --- a/ext/mysql/tests/mysql_info.phpt +++ b/ext/mysql/tests/mysql_info.phpt @@ -70,4 +70,5 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- -done! \ No newline at end of file +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_insert_id.phpt b/ext/mysql/tests/mysql_insert_id.phpt index 460d9f3f4d6b6..b69a96ae9ba38 100644 --- a/ext/mysql/tests/mysql_insert_id.phpt +++ b/ext/mysql/tests/mysql_insert_id.phpt @@ -66,6 +66,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_insert_id(): %d is not a valid MySQL-Link resource in %s on line %d bool(false) done! diff --git a/ext/mysql/tests/mysql_list_dbs.phpt b/ext/mysql/tests/mysql_list_dbs.phpt index 054e02ef98066..402161aa63366 100644 --- a/ext/mysql/tests/mysql_list_dbs.phpt +++ b/ext/mysql/tests/mysql_list_dbs.phpt @@ -51,4 +51,5 @@ print "done!\n"; require_once("clean_table.inc"); ?> --EXPECTF-- -done! \ No newline at end of file +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_list_fields.phpt b/ext/mysql/tests/mysql_list_fields.phpt index e0b3fd5e39368..259a94a39963e 100644 --- a/ext/mysql/tests/mysql_list_fields.phpt +++ b/ext/mysql/tests/mysql_list_fields.phpt @@ -64,6 +64,7 @@ if (!mysql_query("DROP TABLE IF EXISTS test2", $link)) mysql_close($link); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [006] [%d] %s bool(false) Field Offset 0 diff --git a/ext/mysql/tests/mysql_list_processes.phpt b/ext/mysql/tests/mysql_list_processes.phpt index b0c71ad1b41d3..7838a6f98adc9 100644 --- a/ext/mysql/tests/mysql_list_processes.phpt +++ b/ext/mysql/tests/mysql_list_processes.phpt @@ -49,4 +49,5 @@ mysql_close($link); print "done!\n"; ?> --EXPECTF-- -done! \ No newline at end of file +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_list_tables.phpt b/ext/mysql/tests/mysql_list_tables.phpt index cf0b1a636d40c..3b753ae37ab44 100644 --- a/ext/mysql/tests/mysql_list_tables.phpt +++ b/ext/mysql/tests/mysql_list_tables.phpt @@ -82,4 +82,5 @@ print "done!\n"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_max_links.phpt b/ext/mysql/tests/mysql_max_links.phpt index 52ecd0ac08336..32096c426e34b 100644 --- a/ext/mysql/tests/mysql_max_links.phpt +++ b/ext/mysql/tests/mysql_max_links.phpt @@ -54,9 +54,19 @@ mysql_close($links[1]); print "done!\n"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_connect(): Too many open links (2) in %s on line %s [030] Cannot connect using host '%s', user '%s', password '****', [0] 0 +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_connect(): Too many open links (2) in %s on line %s [060] Cannot connect using host '%s', user '%s', password '****', [0] 0 array(3) { @@ -67,4 +77,4 @@ array(3) { [2]=> bool(false) } -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_max_persistent.phpt b/ext/mysql/tests/mysql_max_persistent.phpt index ac35cd178badd..36f2266665de2 100644 --- a/ext/mysql/tests/mysql_max_persistent.phpt +++ b/ext/mysql/tests/mysql_max_persistent.phpt @@ -90,10 +90,16 @@ if (!$link = my_mysql_connect($host, $user, $passwd, $db, $port, $socket)) { mysql_close($link); ?> --EXPECTF-- +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_pconnect(): Too many open persistent links (1) in %s on line %d [020] Cannot connect using host '%s', user '%s', password '****', [0] 0 + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(1) { [0]=> resource(%d) of type (mysql link persistent) } -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt b/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt index d54cb50708b01..2c67e64878d61 100644 --- a/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt +++ b/ext/mysql/tests/mysql_mysqlnd_read_timeout_long.phpt @@ -30,8 +30,9 @@ max_execution_time=12 print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(1) { [%u|b%"SLEEP(6)"]=> %unicode|string%(1) "0" } -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_num_fields.phpt b/ext/mysql/tests/mysql_num_fields.phpt index 0dad5f771d075..4621dc91f83c0 100644 --- a/ext/mysql/tests/mysql_num_fields.phpt +++ b/ext/mysql/tests/mysql_num_fields.phpt @@ -52,5 +52,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_num_fields(): %d is not a valid MySQL result resource in %s on line %d done! diff --git a/ext/mysql/tests/mysql_num_rows.phpt b/ext/mysql/tests/mysql_num_rows.phpt index 0f538c4a2b16d..5a803d41f9166 100644 --- a/ext/mysql/tests/mysql_num_rows.phpt +++ b/ext/mysql/tests/mysql_num_rows.phpt @@ -79,6 +79,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in %s on line %d Warning: mysql_free_result() expects parameter 1 to be resource, boolean given in %s on line %d diff --git a/ext/mysql/tests/mysql_pconn_disable.phpt b/ext/mysql/tests/mysql_pconn_disable.phpt index 532e2e5788555..6997e5970f56b 100644 --- a/ext/mysql/tests/mysql_pconn_disable.phpt +++ b/ext/mysql/tests/mysql_pconn_disable.phpt @@ -49,6 +49,13 @@ mysql.max_links=2 require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [001] Can connect to the server. [002] Can fetch data using persistent connection! Data = '1' -done! \ No newline at end of file + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d +done! diff --git a/ext/mysql/tests/mysql_pconn_kill.phpt b/ext/mysql/tests/mysql_pconn_kill.phpt index efef4216045ee..eb1feb7b85622 100644 --- a/ext/mysql/tests/mysql_pconn_kill.phpt +++ b/ext/mysql/tests/mysql_pconn_kill.phpt @@ -106,5 +106,12 @@ mysql.max_persistent=2 require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d bool(true) + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_pconn_max_links.phpt b/ext/mysql/tests/mysql_pconn_max_links.phpt index 3eca0e534a833..ced94b3dbf5e8 100644 --- a/ext/mysql/tests/mysql_pconn_max_links.phpt +++ b/ext/mysql/tests/mysql_pconn_max_links.phpt @@ -191,12 +191,17 @@ $host = substr($row['_user'], strrpos($row['_user'], "@") + 1, strlen($row['_use mysql_close($link); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(2) { [%u|b%"id"]=> %unicode|string%(1) "1" [%u|b%"label"]=> %unicode|string%(1) "a" } + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(2) { [%u|b%"id"]=> %unicode|string%(1) "1" diff --git a/ext/mysql/tests/mysql_pconn_reuse.phpt b/ext/mysql/tests/mysql_pconn_reuse.phpt index ffa5f75f1ba18..26b4ca5f49dab 100644 --- a/ext/mysql/tests/mysql_pconn_reuse.phpt +++ b/ext/mysql/tests/mysql_pconn_reuse.phpt @@ -59,8 +59,17 @@ mysql.max_links=2 print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [001] Can connect to the server. [002] Can fetch data using persistent connection! Data = '1' +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_connect(): Too many open links (2) in %s on line %d -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_pconnect.phpt b/ext/mysql/tests/mysql_pconnect.phpt index 5a7db93ab3044..ec28d2ea8a27e 100644 --- a/ext/mysql/tests/mysql_pconnect.phpt +++ b/ext/mysql/tests/mysql_pconnect.phpt @@ -81,5 +81,17 @@ mysql.allow_persistent=1 print "done!"; ?> --EXPECTF-- +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_pconnect(): Access denied for user '%s'@'%s' (using password: YES) in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_pconnect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_ping.phpt b/ext/mysql/tests/mysql_ping.phpt index edf18c4391a6e..0308df3396f65 100644 --- a/ext/mysql/tests/mysql_ping.phpt +++ b/ext/mysql/tests/mysql_ping.phpt @@ -42,6 +42,7 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d bool(true) bool(true) bool(true) diff --git a/ext/mysql/tests/mysql_query.phpt b/ext/mysql/tests/mysql_query.phpt index a5978a6c11817..01b14ee28452c 100644 --- a/ext/mysql/tests/mysql_query.phpt +++ b/ext/mysql/tests/mysql_query.phpt @@ -113,6 +113,7 @@ if (!mysql_query('DROP TABLE IF EXISTS test', $link)) { mysql_close($link); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(1) { [%u|b%"valid"]=> %unicode|string%(30) "this is sql but with semicolon" diff --git a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt index aa15f5ca12612..c2cb41e0260f0 100644 --- a/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt +++ b/ext/mysql/tests/mysql_query_load_data_openbasedir.phpt @@ -111,6 +111,9 @@ unlink("./simple.csv"); print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d [006] [1148] %s [007] [0] '' [008] LOAD DATA not run? diff --git a/ext/mysql/tests/mysql_real_escape_string.phpt b/ext/mysql/tests/mysql_real_escape_string.phpt index 2789ad276c71c..4fdedf7b37389 100644 --- a/ext/mysql/tests/mysql_real_escape_string.phpt +++ b/ext/mysql/tests/mysql_real_escape_string.phpt @@ -33,6 +33,7 @@ assert($tmp === mysql_real_escape_string("foo" . chr(0) . "bar")); print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d %unicode|string%(31) "Am I a unicode string in PHP 6?" %unicode|string%(2) "\\" %unicode|string%(2) "\"" diff --git a/ext/mysql/tests/mysql_result.phpt b/ext/mysql/tests/mysql_result.phpt index 2c7c618547e66..0a58b9b88340a 100644 --- a/ext/mysql/tests/mysql_result.phpt +++ b/ext/mysql/tests/mysql_result.phpt @@ -65,6 +65,8 @@ print "done!"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_result(): Unable to jump to row -1 on MySQL result index %d in %s on line %d bool(false) diff --git a/ext/mysql/tests/mysql_select_db.phpt b/ext/mysql/tests/mysql_select_db.phpt index 211e34222ea16..e9bc99aa736d9 100644 --- a/ext/mysql/tests/mysql_select_db.phpt +++ b/ext/mysql/tests/mysql_select_db.phpt @@ -66,6 +66,7 @@ if (false !== ($tmp = mysql_select_db($db, $link))) print "done!\n"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d %unicode|string%(%d) "%s" bool(false) diff --git a/ext/mysql/tests/mysql_set_charset.phpt b/ext/mysql/tests/mysql_set_charset.phpt index 953323b49c39d..a0bccd8c31ad6 100644 --- a/ext/mysql/tests/mysql_set_charset.phpt +++ b/ext/mysql/tests/mysql_set_charset.phpt @@ -58,4 +58,5 @@ mysql_close($link); print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d done! diff --git a/ext/mysql/tests/mysql_stat.phpt b/ext/mysql/tests/mysql_stat.phpt index 30a840a2a15db..d6a34df581add 100644 --- a/ext/mysql/tests/mysql_stat.phpt +++ b/ext/mysql/tests/mysql_stat.phpt @@ -44,5 +44,7 @@ if (false !== ($tmp = mysql_stat($link))) print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_stat(): %d is not a valid MySQL-Link resource in %s on line %d done! diff --git a/ext/mysql/tests/mysql_tablename.phpt b/ext/mysql/tests/mysql_tablename.phpt index 2415e4fda0f00..4bbe54d443c3e 100644 --- a/ext/mysql/tests/mysql_tablename.phpt +++ b/ext/mysql/tests/mysql_tablename.phpt @@ -42,6 +42,8 @@ mysql_close($link); print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_tablename() expects at least 2 parameters, 1 given in %s on line %d Warning: mysql_tablename(): Unable to jump to row -1 on MySQL result index %d in %s on line %d diff --git a/ext/mysql/tests/mysql_thread_id.phpt b/ext/mysql/tests/mysql_thread_id.phpt index b05bb3ed1c01a..aa95d319449a2 100644 --- a/ext/mysql/tests/mysql_thread_id.phpt +++ b/ext/mysql/tests/mysql_thread_id.phpt @@ -35,5 +35,7 @@ if (false !== ($tmp = mysql_thread_id($link))) print "done!"; ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d + Warning: mysql_thread_id(): %d is not a valid MySQL-Link resource in %s on line %d -done! \ No newline at end of file +done! diff --git a/ext/mysql/tests/mysql_trace_mode.phpt b/ext/mysql/tests/mysql_trace_mode.phpt index 2b6c61d27bb1b..7655975d70c65 100644 --- a/ext/mysql/tests/mysql_trace_mode.phpt +++ b/ext/mysql/tests/mysql_trace_mode.phpt @@ -29,6 +29,7 @@ print "done!\n"; require_once("clean_table.inc"); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d I don\'t mind character sets, do I?\n Warning: mysql_query(): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'BOGUS_SQL' at line 1 in %s on line %d done! diff --git a/ext/mysql/tests/mysql_unbuffered_query.phpt b/ext/mysql/tests/mysql_unbuffered_query.phpt index ad9b4fbc5240a..8754b58b59069 100644 --- a/ext/mysql/tests/mysql_unbuffered_query.phpt +++ b/ext/mysql/tests/mysql_unbuffered_query.phpt @@ -107,6 +107,7 @@ if (!mysql_query('DROP TABLE IF EXISTS test', $link)) { mysql_close($link); ?> --EXPECTF-- +Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in %s on line %d array(1) { [%u|b%"valid"]=> %unicode|string%(30) "this is sql but with semicolon" From ec83534d88da4c96777b86d8db7fd20a52ed012e Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Tue, 11 Dec 2012 09:08:07 +0800 Subject: [PATCH 2200/2394] Tinker with the wording of the MySQL deprecation news post. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit I know that in general NEWS is a very punchy "this is what happened" log, but Chris e-mailed me off-list to ask if it could be added to avoid any FUD — this merely brings the NEWS post into line with UPGRADING, the migration guide, and every other piece of advice we're giving out. I also forgot to add the RFC URL last night, so added that. --- NEWS | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index ce5f08cc0bd6e..40fab8a740b6b 100644 --- a/NEWS +++ b/NEWS @@ -166,7 +166,8 @@ PHP NEWS - MySQL . This extension is now deprecated, and deprecation warnings will be generated when connections are established to databases via mysql_connect(), - mysql_pconnect(), or through implicit connection. (Adam) + mysql_pconnect(), or through implicit connection: use MySQLi or PDO_MySQL + instead (https://wiki.php.net/rfc/mysql_deprecation). (Adam) - MySQLi . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. From a9a5f7aca61d4bec9ce2cf5dc967bb7c0ed651cd Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 11 Dec 2012 17:25:32 +0400 Subject: [PATCH 2201/2394] - generators API exported for extensions - improved RETURN sequence to avoid redundant check if op_array is a generator --- Zend/zend_generators.c | 6 +++--- Zend/zend_generators.h | 6 +++--- Zend/zend_vm_def.h | 42 +++++++++++++++++++++++++++--------------- Zend/zend_vm_execute.h | 42 +++++++++++++++++++++++++++--------------- 4 files changed, 60 insertions(+), 36 deletions(-) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index dc7ae1479b41e..1844be86d5a5e 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -27,7 +27,7 @@ ZEND_API zend_class_entry *zend_ce_generator; static zend_object_handlers zend_generator_handlers; -void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC) /* {{{ */ +ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC) /* {{{ */ { if (generator->execute_data) { zend_execute_data *execute_data = generator->execute_data; @@ -338,7 +338,7 @@ static zend_object_value zend_generator_create(zend_class_entry *class_type TSRM /* Requires globals EG(scope), EG(current_scope), EG(This), * EG(active_symbol_table) and EG(current_execute_data). */ -zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ +ZEND_API zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC) /* {{{ */ { zval *return_value; zend_generator *generator; @@ -399,7 +399,7 @@ static zend_function *zend_generator_get_constructor(zval *object TSRMLS_DC) /* } /* }}} */ -void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ +ZEND_API void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ { if (EG(exception)) { return; diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index 90f8160f710b1..7e6da1371f841 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -62,9 +62,9 @@ static const zend_uchar ZEND_GENERATOR_FORCED_CLOSE = 0x2; static const zend_uchar ZEND_GENERATOR_AT_FIRST_YIELD = 0x4; void zend_register_generator_ce(TSRMLS_D); -zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC); -void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC); -void zend_generator_resume(zend_generator *generator TSRMLS_DC); +ZEND_API zval *zend_generator_create_zval(zend_op_array *op_array TSRMLS_DC); +ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC); +ZEND_API void zend_generator_resume(zend_generator *generator TSRMLS_DC); #endif diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index edbffe12c9902..c5d1748cd2407 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1850,18 +1850,6 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) /* return from finally block called because of unhandled exception */ zend_exception_restore(TSRMLS_C); } - - /* Generators go throw a different cleanup process */ - if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; @@ -2969,7 +2957,20 @@ ZEND_VM_HANDLER(111, ZEND_RETURN_BY_REF, CONST|TMP|VAR|CV, ANY) ZEND_VM_HANDLER(161, ZEND_GENERATOR_RETURN, ANY, ANY) { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + /* The generator object is stored in return_value_ptr_ptr */ + zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + + if (EXPECTED(EG(exception) == NULL) && + UNEXPECTED(EG(prev_exception) != NULL)) { + /* return from finally block called because of unhandled exception */ + zend_exception_restore(TSRMLS_C); + } + + /* Close the generator to free up resources */ + zend_generator_close(generator, 1 TSRMLS_CC); + + /* Pass execution back to handling code */ + ZEND_VM_RETURN(); } ZEND_VM_HANDLER(108, ZEND_THROW, CONST|TMP|VAR|CV, ANY) @@ -5124,7 +5125,11 @@ ZEND_VM_HANDLER(149, ZEND_HANDLE_EXCEPTION, ANY, ANY) ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); ZEND_VM_CONTINUE(); } else { - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + ZEND_VM_DISPATCH_TO_HANDLER(ZEND_GENERATOR_RETURN); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } } } @@ -5151,7 +5156,11 @@ ZEND_VM_HANDLER(150, ZEND_USER_OPCODE, ANY, ANY) case ZEND_USER_OPCODE_CONTINUE: ZEND_VM_CONTINUE(); case ZEND_USER_OPCODE_RETURN: - ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + ZEND_VM_DISPATCH_TO_HANDLER(ZEND_GENERATOR_RETURN); + } else { + ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); + } case ZEND_USER_OPCODE_ENTER: ZEND_VM_ENTER(); case ZEND_USER_OPCODE_LEAVE: @@ -5444,6 +5453,9 @@ ZEND_VM_HANDLER(163, ZEND_FAST_RET, ANY, ANY) zend_exception_restore(TSRMLS_C); ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); ZEND_VM_CONTINUE(); + } else if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + zend_exception_restore(TSRMLS_C); + ZEND_VM_DISPATCH_TO_HANDLER(ZEND_GENERATOR_RETURN); } else { zend_exception_restore(TSRMLS_C); ZEND_VM_DISPATCH_TO_HELPER(zend_leave_helper); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 80967bdfb3c8e..7c11016c06498 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -392,18 +392,6 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) zend_exception_restore(TSRMLS_C); } - /* Generators go throw a different cleanup process */ - if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - /* The generator object is stored in return_value_ptr_ptr */ - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - /* Close the generator to free up resources */ - zend_generator_close(generator, 1 TSRMLS_CC); - - /* Pass execution back to handling code */ - ZEND_VM_RETURN(); - } - EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { @@ -705,7 +693,20 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + /* The generator object is stored in return_value_ptr_ptr */ + zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); + + if (EXPECTED(EG(exception) == NULL) && + UNEXPECTED(EG(prev_exception) != NULL)) { + /* return from finally block called because of unhandled exception */ + zend_exception_restore(TSRMLS_C); + } + + /* Close the generator to free up resources */ + zend_generator_close(generator, 1 TSRMLS_CC); + + /* Pass execution back to handling code */ + ZEND_VM_RETURN(); } static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) @@ -1086,7 +1087,11 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[catch_op_num]); ZEND_VM_CONTINUE(); } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } } } @@ -1113,7 +1118,11 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS case ZEND_USER_OPCODE_CONTINUE: ZEND_VM_CONTINUE(); case ZEND_USER_OPCODE_RETURN: - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } else { + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + } case ZEND_USER_OPCODE_ENTER: ZEND_VM_ENTER(); case ZEND_USER_OPCODE_LEAVE: @@ -1169,6 +1178,9 @@ static int ZEND_FASTCALL ZEND_FAST_RET_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) zend_exception_restore(TSRMLS_C); ZEND_VM_SET_OPCODE(&EX(op_array)->opcodes[opline->op2.opline_num]); ZEND_VM_CONTINUE(); + } else if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + zend_exception_restore(TSRMLS_C); + return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zend_exception_restore(TSRMLS_C); return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); From 4d8d5d83fce83c32a04cd8d8cf50d909ab101f38 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 11 Dec 2012 16:30:08 +0100 Subject: [PATCH 2202/2394] Fixed Bug #63738 unpack: back result with Z format Fix result for empty string. Same output as perl perl -e 'print unpack("Z2","\0\0");' => "" perl -e 'print unpack("Z2","A\0");' => "A" perl -e 'print unpack("Z2","AB\0");' => "AB" perl -e 'print unpack("Z2","ABC\0");'=> "AB" --- ext/standard/pack.c | 3 +-- ext/standard/tests/strings/pack_Z.phpt | 25 ++++++++++++++++++++++++- 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/ext/standard/pack.c b/ext/standard/pack.c index 9894746f7767f..0472cb24a9c50 100644 --- a/ext/standard/pack.c +++ b/ext/standard/pack.c @@ -729,8 +729,7 @@ PHP_FUNCTION(unpack) size = len; /* Remove everything after the first null */ - s = 0; - while (s++ <= len) { + for (s=0 ; s < len ; s++) { if (input[inputpos + s] == pad) break; } diff --git a/ext/standard/tests/strings/pack_Z.phpt b/ext/standard/tests/strings/pack_Z.phpt index 8a2ee67767654..4fd007ae0f6ab 100644 --- a/ext/standard/tests/strings/pack_Z.phpt +++ b/ext/standard/tests/strings/pack_Z.phpt @@ -9,9 +9,15 @@ var_dump( pack("Z4", "foo"), pack("Z*", "foo"), unpack("Z*", "foo\0\rbar\0 \t\r\n"), - unpack("Z9", "foo\0\rbar\0 \t\r\n") + unpack("Z9", "foo\0\rbar\0 \t\r\n"), + unpack("Z2", "\0"), + unpack("Z2", "\0\0"), + unpack("Z2", "A\0"), + unpack("Z2", "AB\0"), + unpack("Z2", "ABC") ); --EXPECTF-- +Warning: unpack(): Type Z: not enough input, need 2, have 1 in %s on line %d string(0) "" string(5) "foo%c%c" string(4) "foo%c" @@ -25,3 +31,20 @@ array(1) { [1]=> string(3) "foo" } +bool(false) +array(1) { + [1]=> + string(0) "" +} +array(1) { + [1]=> + string(1) "A" +} +array(1) { + [1]=> + string(2) "AB" +} +array(1) { + [1]=> + string(2) "AB" +} From 349baa3da44a657ed7ec08215456809b23735f71 Mon Sep 17 00:00:00 2001 From: Leigh Date: Wed, 12 Dec 2012 12:14:52 +0000 Subject: [PATCH 2203/2394] Fixed license Looks like a find and replace gone wrong. --- ext/spl/spl_observer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c index 4b8be82eee78d..f1b3f7c144bcd 100755 --- a/ext/spl/spl_observer.c +++ b/ext/spl/spl_observer.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | Copyright (c) 1997-2012 The PHP Group | +----------------------------------------------------------------------+ - | This source file is SplSubject to version 3.01 of the PHP license, | + | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | | available through the world-wide-web at the following url: | | http://www.php.net/license/3_01.txt | From 9c96fe52d95a6674f90dc8efd4e2c054818c96ad Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 12 Dec 2012 17:47:55 +0400 Subject: [PATCH 2204/2394] Restored proper generators behaviour in conjunction with "finally". (Nikita) --- .../{ => finally}/finally_ran_on_close.phpt | 0 .../return_return.phpt} | 2 +- .../generators/finally/return_yield.phpt | 18 ++++++ .../tests/generators/finally/throw_yield.phpt | 24 +++++++ .../generators/finally/yield_return.phpt | 18 ++++++ .../tests/generators/finally/yield_throw.phpt | 24 +++++++ .../tests/generators/finally/yield_yield.phpt | 22 +++++++ .../generators/finally_uninterrupted.phpt | 28 --------- Zend/zend_generators.c | 38 ++++++++++- Zend/zend_opcode.c | 22 +------ Zend/zend_vm_def.h | 13 ---- Zend/zend_vm_execute.h | 63 ++++++++----------- Zend/zend_vm_opcodes.h | 1 - 13 files changed, 171 insertions(+), 102 deletions(-) rename Zend/tests/generators/{ => finally}/finally_ran_on_close.phpt (100%) rename Zend/tests/generators/{finally_with_return.phpt => finally/return_return.phpt} (92%) create mode 100644 Zend/tests/generators/finally/return_yield.phpt create mode 100644 Zend/tests/generators/finally/throw_yield.phpt create mode 100644 Zend/tests/generators/finally/yield_return.phpt create mode 100644 Zend/tests/generators/finally/yield_throw.phpt create mode 100644 Zend/tests/generators/finally/yield_yield.phpt delete mode 100644 Zend/tests/generators/finally_uninterrupted.phpt diff --git a/Zend/tests/generators/finally_ran_on_close.phpt b/Zend/tests/generators/finally/finally_ran_on_close.phpt similarity index 100% rename from Zend/tests/generators/finally_ran_on_close.phpt rename to Zend/tests/generators/finally/finally_ran_on_close.phpt diff --git a/Zend/tests/generators/finally_with_return.phpt b/Zend/tests/generators/finally/return_return.phpt similarity index 92% rename from Zend/tests/generators/finally_with_return.phpt rename to Zend/tests/generators/finally/return_return.phpt index b26a49f32fa3b..02e2739de7ec5 100644 --- a/Zend/tests/generators/finally_with_return.phpt +++ b/Zend/tests/generators/finally/return_return.phpt @@ -1,5 +1,5 @@ --TEST-- -Use of finally in generator with return +try { return } finally { return } in generator --FILE-- rewind(); // force run - -?> ---EXPECTF-- -finally run - -Fatal error: Uncaught exception 'Exception' in %s:%d -Stack trace: -#0 [internal function]: gen() -#1 %s(%d): Generator->rewind() -#2 {main} - thrown in %s on line %d diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 1844be86d5a5e..2ee2fb9681351 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -32,7 +32,41 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished if (generator->execute_data) { zend_execute_data *execute_data = generator->execute_data; zend_op_array *op_array = execute_data->op_array; - void **stack_frame; + + if (!finished_execution) { + if (op_array->has_finally_block) { + /* -1 required because we want the last run opcode, not the + * next to-be-run one. */ + zend_uint op_num = execute_data->opline - op_array->opcodes - 1; + zend_uint finally_op_num = 0; + + /* Find next finally block */ + int i; + for (i = 0; i < op_array->last_try_catch; i++) { + zend_try_catch_element *try_catch = &op_array->try_catch_array[i]; + + if (op_num < try_catch->try_op) { + break; + } + + if (op_num < try_catch->finally_op) { + finally_op_num = try_catch->finally_op; + } + } + + /* If a finally block was found we jump directly to it and + * resume the generator. Furthermore we abort this close call + * because the generator will already be closed somewhere in + * the resume. */ + if (finally_op_num) { + execute_data->opline = &op_array->opcodes[finally_op_num]; + execute_data->fast_ret = NULL; + generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; + zend_generator_resume(generator TSRMLS_CC); + return; + } + } + } if (!execute_data->symbol_table) { zend_free_compiled_variables(execute_data); @@ -83,7 +117,7 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished /* Clear any backed up stack arguments */ if (generator->stack != EG(argument_stack)) { - stack_frame = zend_vm_stack_frame_base(execute_data); + void **stack_frame = zend_vm_stack_frame_base(execute_data); while (generator->stack->top != stack_frame) { zval_ptr_dtor((zval**)stack_frame); stack_frame++; diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index 2fd8f529ef1f8..3fb9453314a77 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -542,17 +542,9 @@ static void zend_resolve_finally_call(zend_op_array *op_array, zend_uint op_num, dst_num > op_array->try_catch_array[i].finally_end)) { /* we have a jump out of try block that needs executing finally */ - /* generate a FAST_CALL to finaly block */ + /* generate a FAST_CALL to finally block */ start_op = get_next_op_number(op_array); - if (op_array->opcodes[op_num].opcode == ZEND_YIELD) { - /* Disable yield in finally block */ - opline = get_next_op(op_array TSRMLS_CC); - opline->opcode = ZEND_GENERATOR_FLAG; - opline->extended_value = 1; - SET_UNUSED(opline->op1); - SET_UNUSED(opline->op2); - } opline = get_next_op(op_array TSRMLS_CC); opline->opcode = ZEND_FAST_CALL; SET_UNUSED(opline->op1); @@ -563,7 +555,7 @@ static void zend_resolve_finally_call(zend_op_array *op_array, zend_uint op_num, opline->op2.opline_num = op_array->try_catch_array[i].catch_op; } - /* generate a sequence of FAST_CALL to upward finaly block */ + /* generate a sequence of FAST_CALL to upward finally block */ while (i > 0) { i--; if (op_array->try_catch_array[i].finally_op && @@ -579,14 +571,6 @@ static void zend_resolve_finally_call(zend_op_array *op_array, zend_uint op_num, opline->op1.opline_num = op_array->try_catch_array[i].finally_op; } } - if (op_array->opcodes[op_num].opcode == ZEND_YIELD) { - /* Re-enable yield */ - opline = get_next_op(op_array TSRMLS_CC); - opline->opcode = ZEND_GENERATOR_FLAG; - opline->extended_value = 0; - SET_UNUSED(opline->op1); - SET_UNUSED(opline->op2); - } /* Finish the sequence with original opcode */ opline = get_next_op(op_array TSRMLS_CC); @@ -642,7 +626,7 @@ static void zend_resolve_finally_calls(zend_op_array *op_array TSRMLS_DC) switch (opline->opcode) { case ZEND_RETURN: case ZEND_RETURN_BY_REF: - case ZEND_YIELD: + case ZEND_GENERATOR_RETURN: zend_resolve_finally_call(op_array, i, (zend_uint)-1 TSRMLS_CC); break; case ZEND_BRK: diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index c5d1748cd2407..939dc1d066202 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5252,19 +5252,6 @@ ZEND_VM_HANDLER(156, ZEND_SEPARATE, VAR, UNUSED) ZEND_VM_NEXT_OPCODE(); } -ZEND_VM_HANDLER(159, ZEND_GENERATOR_FLAG, ANY, ANY) -{ - USE_OPLINE - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - if (opline->extended_value) { - generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; - } else { - generator->flags &= ~ZEND_GENERATOR_FORCED_CLOSE; - } - ZEND_VM_NEXT_OPCODE(); -} - ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSED) { USE_OPLINE diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 7c11016c06498..dd77aa5f8ef1f 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1134,19 +1134,6 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } -static int ZEND_FASTCALL ZEND_GENERATOR_FLAG_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ - USE_OPLINE - zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - - if (opline->extended_value) { - generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; - } else { - generator->flags &= ~ZEND_GENERATOR_FORCED_CLOSE; - } - ZEND_VM_NEXT_OPCODE(); -} - static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -44840,31 +44827,31 @@ void zend_init_opcodes_handlers(void) ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, - ZEND_GENERATOR_FLAG_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, ZEND_YIELD_SPEC_CONST_CONST_HANDLER, ZEND_YIELD_SPEC_CONST_TMP_HANDLER, ZEND_YIELD_SPEC_CONST_VAR_HANDLER, diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index fcf7960b8e413..52f6cde59e71f 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -159,7 +159,6 @@ #define ZEND_SEPARATE 156 #define ZEND_QM_ASSIGN_VAR 157 #define ZEND_JMP_SET_VAR 158 -#define ZEND_GENERATOR_FLAG 159 #define ZEND_YIELD 160 #define ZEND_GENERATOR_RETURN 161 #define ZEND_FAST_CALL 162 From 6e4cfa18f768c385e1945fcb4776cf6ad0cecdfc Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 12 Dec 2012 16:53:18 +0100 Subject: [PATCH 2205/2394] Really fix test pdo_mysql_class_constants.phpt - with mysqlnd, constant always present - with mysqli, check client library version - without mysqlnd and without mysqli skip the test if no connection use connection to check client library Note : MySQLPDOTest::getClientVersion() is broken with mysqlnd as PDO::ATTR_CLIENT_VERSION return "mysqlnd 5.0.11-dev - 20120503..." so, getClientVersion() return "11" --- .../tests/pdo_mysql_class_constants.phpt | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt index e52e4b54e7cba..ee0f12358d0ba 100644 --- a/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt +++ b/ext/pdo_mysql/tests/pdo_mysql_class_constants.phpt @@ -3,6 +3,11 @@ PDO MySQL specific class constants --SKIPIF-- --FILE-- 50605) - || MySQLPDOTest::getClientVersion(MySQLPDOTest::factory()) > 50605) { + if (extension_loaded('mysqlnd')) { + $expected['MYSQL_ATTR_SERVER_PUBLIC_KEY'] = true; + } else if (extension_loaded('mysqli')) { + if (mysqli_get_client_version() > 50605) { + $expected['MYSQL_ATTR_SERVER_PUBLIC_KEY'] = true; + } + } else if (MySQLPDOTest::getClientVersion(MySQLPDOTest::factory()) > 50605) { /* XXX the MySQL client library version isn't exposed with any constants, the single possibility is to use the PDO::getAttribute(). This however will fail with no connection. */ From 6b0b4bf8ebec7fa7172d2d2617fa7c80ecf4b528 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 13 Dec 2012 02:48:51 +0400 Subject: [PATCH 2206/2394] An exception thrown in try or catch block is disacarded by return statement in finally block. --- Zend/tests/catch_finally_006.phpt | 2 +- Zend/tests/try_catch_finally_003.phpt | 2 - Zend/tests/try_finally_010.phpt | 30 +++++++++++ Zend/zend_compile.c | 14 ++++- Zend/zend_compile.h | 1 + Zend/zend_extensions.h | 2 +- Zend/zend_modules.h | 2 +- Zend/zend_vm_def.h | 23 ++++----- Zend/zend_vm_execute.h | 73 +++++++++++++-------------- Zend/zend_vm_opcodes.h | 1 + 10 files changed, 95 insertions(+), 55 deletions(-) create mode 100644 Zend/tests/try_finally_010.phpt diff --git a/Zend/tests/catch_finally_006.phpt b/Zend/tests/catch_finally_006.phpt index 9759eab37ef11..216219b6a5b37 100644 --- a/Zend/tests/catch_finally_006.phpt +++ b/Zend/tests/catch_finally_006.phpt @@ -25,4 +25,4 @@ try { --EXPECT-- string(4) "para" string(7) "finally" -string(2) "ex" +string(6) "return" diff --git a/Zend/tests/try_catch_finally_003.phpt b/Zend/tests/try_catch_finally_003.phpt index 784063b749025..7ec8ec82db4d0 100644 --- a/Zend/tests/try_catch_finally_003.phpt +++ b/Zend/tests/try_catch_finally_003.phpt @@ -15,11 +15,9 @@ function foo () { die("error"); } finally { echo "1"; - return 1; } } finally { echo "2"; - return 2; } } catch (BE $e) { die("error"); diff --git a/Zend/tests/try_finally_010.phpt b/Zend/tests/try_finally_010.phpt new file mode 100644 index 0000000000000..bbac8dd1e5962 --- /dev/null +++ b/Zend/tests/try_finally_010.phpt @@ -0,0 +1,30 @@ +--TEST-- +Try finally (function call in the finaly block after exception) +--FILE-- +T)++); + return (zend_uint)EX_TMP_VAR_NUM(0, (op_array->T)++); } /* }}} */ @@ -2671,6 +2672,13 @@ void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC) /* {{{ */ start_op_number++; } + if (CG(context).in_finally) { + opline = get_next_op(CG(active_op_array) TSRMLS_CC); + opline->opcode = ZEND_DISCARD_EXCEPTION; + SET_UNUSED(opline->op1); + SET_UNUSED(opline->op2); + } + opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = returns_reference ? ZEND_RETURN_BY_REF : ZEND_RETURN; @@ -2819,6 +2827,8 @@ void zend_do_finally(znode *finally_token TSRMLS_DC) /* {{{ */ opline->opcode = ZEND_JMP; SET_UNUSED(opline->op1); SET_UNUSED(opline->op2); + + CG(context).in_finally++; } /* }}} */ @@ -2897,6 +2907,8 @@ void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_to SET_UNUSED(opline->op2); CG(active_op_array)->opcodes[finally_token->u.op.opline_num].op1.opline_num = get_next_op_number(CG(active_op_array)); + + CG(context).in_finally--; } } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index da0a49bd511f5..c921c2a66fbc8 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -61,6 +61,7 @@ typedef struct _zend_compiler_context { int backpatch_count; int nested_calls; int used_stack; + int in_finally; HashTable *labels; } zend_compiler_context; diff --git a/Zend/zend_extensions.h b/Zend/zend_extensions.h index 5be6be62a6b66..3c609164c6f3c 100644 --- a/Zend/zend_extensions.h +++ b/Zend/zend_extensions.h @@ -28,7 +28,7 @@ /* The first number is the engine version and the rest is the date. * This way engine 2/3 API no. is always greater than engine 1 API no.. */ -#define ZEND_EXTENSION_API_NO 220121204 +#define ZEND_EXTENSION_API_NO 220121212 typedef struct _zend_extension_version_info { int zend_extension_api_no; diff --git a/Zend/zend_modules.h b/Zend/zend_modules.h index b4ad648c795ee..a4ed106cfc665 100644 --- a/Zend/zend_modules.h +++ b/Zend/zend_modules.h @@ -33,7 +33,7 @@ #define ZEND_MODULE_INFO_FUNC_ARGS zend_module_entry *zend_module TSRMLS_DC #define ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU zend_module TSRMLS_CC -#define ZEND_MODULE_API_NO 20121204 +#define ZEND_MODULE_API_NO 20121212 #ifdef ZTS #define USING_ZTS 1 #else diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 939dc1d066202..ef3f80e596aa8 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1845,12 +1845,6 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) zend_bool nested; zend_op_array *op_array = EX(op_array); - if (EXPECTED(EG(exception) == NULL) && - UNEXPECTED(EG(prev_exception) != NULL)) { - /* return from finally block called because of unhandled exception */ - zend_exception_restore(TSRMLS_C); - } - EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { @@ -2960,12 +2954,6 @@ ZEND_VM_HANDLER(161, ZEND_GENERATOR_RETURN, ANY, ANY) /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - if (EXPECTED(EG(exception) == NULL) && - UNEXPECTED(EG(prev_exception) != NULL)) { - /* return from finally block called because of unhandled exception */ - zend_exception_restore(TSRMLS_C); - } - /* Close the generator to free up resources */ zend_generator_close(generator, 1 TSRMLS_CC); @@ -5409,6 +5397,17 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE ZEND_VM_RETURN(); } +ZEND_VM_HANDLER(159, ZEND_DISCARD_EXCEPTION, ANY, ANY) +{ + if (EG(prev_exception) != NULL) { + /* discard the previously thrown exception */ + zval_ptr_dtor(&EG(prev_exception)); + EG(prev_exception) = NULL; + } + + ZEND_VM_NEXT_OPCODE(); +} + ZEND_VM_HANDLER(162, ZEND_FAST_CALL, ANY, ANY) { USE_OPLINE diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index dd77aa5f8ef1f..4e4dedfd0888b 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -386,12 +386,6 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) zend_bool nested; zend_op_array *op_array = EX(op_array); - if (EXPECTED(EG(exception) == NULL) && - UNEXPECTED(EG(prev_exception) != NULL)) { - /* return from finally block called because of unhandled exception */ - zend_exception_restore(TSRMLS_C); - } - EG(current_execute_data) = EX(prev_execute_data); EG(opline_ptr) = NULL; if (!EG(active_symbol_table)) { @@ -696,12 +690,6 @@ static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); - if (EXPECTED(EG(exception) == NULL) && - UNEXPECTED(EG(prev_exception) != NULL)) { - /* return from finally block called because of unhandled exception */ - zend_exception_restore(TSRMLS_C); - } - /* Close the generator to free up resources */ zend_generator_close(generator, 1 TSRMLS_CC); @@ -1134,6 +1122,17 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } +static int ZEND_FASTCALL ZEND_DISCARD_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ + if (EG(prev_exception) != NULL) { + /* discard the previously thrown exception */ + zval_ptr_dtor(&EG(prev_exception)); + EG(prev_exception) = NULL; + } + + ZEND_VM_NEXT_OPCODE(); +} + static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -44827,31 +44826,31 @@ void zend_init_opcodes_handlers(void) ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, ZEND_YIELD_SPEC_CONST_CONST_HANDLER, ZEND_YIELD_SPEC_CONST_TMP_HANDLER, ZEND_YIELD_SPEC_CONST_VAR_HANDLER, diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 52f6cde59e71f..061d7e49b3a85 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -159,6 +159,7 @@ #define ZEND_SEPARATE 156 #define ZEND_QM_ASSIGN_VAR 157 #define ZEND_JMP_SET_VAR 158 +#define ZEND_DISCARD_EXCEPTION 159 #define ZEND_YIELD 160 #define ZEND_GENERATOR_RETURN 161 #define ZEND_FAST_CALL 162 From ff1e1d7a8e32cdf231b2f8085afd99de11b2db7b Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 13 Dec 2012 14:46:44 +0400 Subject: [PATCH 2207/2394] Removed redundand checks from release build --- Zend/zend.h | 2 ++ Zend/zend_execute.c | 9 ++++----- Zend/zend_execute.h | 18 ++++-------------- Zend/zend_execute_API.c | 22 +--------------------- 4 files changed, 11 insertions(+), 40 deletions(-) diff --git a/Zend/zend.h b/Zend/zend.h index d2a4ef6957868..eceae521b6ed6 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -225,6 +225,7 @@ char *alloca (); #define ZEND_FILE_LINE_EMPTY_CC , ZEND_FILE_LINE_EMPTY_C #define ZEND_FILE_LINE_ORIG_RELAY_C __zend_orig_filename, __zend_orig_lineno #define ZEND_FILE_LINE_ORIG_RELAY_CC , ZEND_FILE_LINE_ORIG_RELAY_C +#define ZEND_ASSERT(c) assert(c) #else #define ZEND_FILE_LINE_D #define ZEND_FILE_LINE_DC @@ -238,6 +239,7 @@ char *alloca (); #define ZEND_FILE_LINE_EMPTY_CC #define ZEND_FILE_LINE_ORIG_RELAY_C #define ZEND_FILE_LINE_ORIG_RELAY_CC +#define ZEND_ASSERT(c) #endif /* ZEND_DEBUG */ #ifdef ZTS diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index e6034ba2030da..c0b1d0203b8fa 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -86,11 +86,10 @@ static zend_always_inline void zend_pzval_unlock_func(zval *z, zend_free_op *sho static zend_always_inline void zend_pzval_unlock_free_func(zval *z TSRMLS_DC) { if (!Z_DELREF_P(z)) { - if (z != &EG(uninitialized_zval)) { - GC_REMOVE_ZVAL_FROM_BUFFER(z); - zval_dtor(z); - efree(z); - } + ZEND_ASSERT(z != &EG(uninitialized_zval)); + GC_REMOVE_ZVAL_FROM_BUFFER(z); + zval_dtor(z); + efree(z); } } diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 963decde2a831..ab560b3da341b 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -61,15 +61,6 @@ ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC); ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC); ZEND_API void execute_internal(zend_execute_data *execute_data_ptr, struct _zend_fcall_info *fci, int return_value_used TSRMLS_DC); ZEND_API int zend_is_true(zval *op); -#define safe_free_zval_ptr(p) safe_free_zval_ptr_rel(p ZEND_FILE_LINE_CC ZEND_FILE_LINE_EMPTY_CC) -static zend_always_inline void safe_free_zval_ptr_rel(zval *p ZEND_FILE_LINE_DC ZEND_FILE_LINE_ORIG_DC) -{ - TSRMLS_FETCH(); - - if (p!=EG(uninitialized_zval_ptr)) { - FREE_ZVAL_REL(p); - } -} ZEND_API int zend_lookup_class(const char *name, int name_length, zend_class_entry ***ce TSRMLS_DC); ZEND_API int zend_lookup_class_ex(const char *name, int name_length, const zend_literal *key, int use_autoload, zend_class_entry ***ce TSRMLS_DC); ZEND_API int zend_eval_string(char *str, zval *retval_ptr, char *string_name TSRMLS_DC); @@ -85,11 +76,10 @@ static zend_always_inline void i_zval_ptr_dtor(zval *zval_ptr ZEND_FILE_LINE_DC) if (!Z_DELREF_P(zval_ptr)) { TSRMLS_FETCH(); - if (zval_ptr != &EG(uninitialized_zval)) { - GC_REMOVE_ZVAL_FROM_BUFFER(zval_ptr); - zval_dtor(zval_ptr); - efree_rel(zval_ptr); - } + ZEND_ASSERT(zval_ptr != &EG(uninitialized_zval)); + GC_REMOVE_ZVAL_FROM_BUFFER(zval_ptr); + zval_dtor(zval_ptr); + efree_rel(zval_ptr); } else { TSRMLS_FETCH(); diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 4a635b230d9d1..042b83c7672a0 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -425,27 +425,7 @@ ZEND_API zend_bool zend_is_executing(TSRMLS_D) /* {{{ */ ZEND_API void _zval_ptr_dtor(zval **zval_ptr ZEND_FILE_LINE_DC) /* {{{ */ { -#if DEBUG_ZEND>=2 - printf("Reducing refcount for %x (%x): %d->%d\n", *zval_ptr, zval_ptr, Z_REFCOUNT_PP(zval_ptr), Z_REFCOUNT_PP(zval_ptr) - 1); -#endif - Z_DELREF_PP(zval_ptr); - if (Z_REFCOUNT_PP(zval_ptr) == 0) { - TSRMLS_FETCH(); - - if (*zval_ptr != &EG(uninitialized_zval)) { - GC_REMOVE_ZVAL_FROM_BUFFER(*zval_ptr); - zval_dtor(*zval_ptr); - efree_rel(*zval_ptr); - } - } else { - TSRMLS_FETCH(); - - if (Z_REFCOUNT_PP(zval_ptr) == 1) { - Z_UNSET_ISREF_PP(zval_ptr); - } - - GC_ZVAL_CHECK_POSSIBLE_ROOT(*zval_ptr); - } + i_zval_ptr_dtor(*zval_ptr ZEND_FILE_LINE_RELAY_CC); } /* }}} */ From 438cd863783ad4b72fa5ef0df23665b84f97c33f Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 13 Dec 2012 17:29:30 +0400 Subject: [PATCH 2208/2394] Removed unnecessary checks --- Zend/zend_execute.h | 12 ++++++++---- Zend/zend_execute_API.c | 4 ++-- Zend/zend_vm_def.h | 4 ++-- Zend/zend_vm_execute.h | 4 ++-- 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index ab560b3da341b..729015c37160d 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -287,17 +287,21 @@ static zend_always_inline void zend_vm_stack_free(void *ptr TSRMLS_DC) } } -static zend_always_inline void zend_vm_stack_clear_multiple(TSRMLS_D) +static zend_always_inline void zend_vm_stack_clear_multiple(int nested TSRMLS_DC) { void **p = EG(argument_stack)->top - 1; - int delete_count = (int)(zend_uintptr_t) *p; + void **end = p - (int)(zend_uintptr_t)*p; - while (--delete_count>=0) { + while (p != end) { zval *q = *(zval **)(--p); *p = NULL; i_zval_ptr_dtor(q ZEND_FILE_LINE_CC); } - zend_vm_stack_free_int(p TSRMLS_CC); + if (nested) { + EG(argument_stack)->top = p; + } else { + zend_vm_stack_free_int(p TSRMLS_CC); + } } static zend_always_inline int zend_vm_stack_get_args_count_ex(zend_execute_data *ex) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 042b83c7672a0..010f5b780c686 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -841,7 +841,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS if (i || UNEXPECTED(ZEND_VM_STACK_ELEMETS(EG(argument_stack)) == (EG(argument_stack)->top))) { /* hack to clean up the stack */ zend_vm_stack_push((void *) (zend_uintptr_t)i TSRMLS_CC); - zend_vm_stack_clear_multiple(TSRMLS_C); + zend_vm_stack_clear_multiple(0 TSRMLS_CC); } zend_error(E_WARNING, "Parameter %d to %s%s%s() expected to be a reference, value given", @@ -995,7 +995,7 @@ int zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_cache TS *fci->retval_ptr_ptr = NULL; } } - zend_vm_stack_clear_multiple(TSRMLS_C); + zend_vm_stack_clear_multiple(0 TSRMLS_CC); if (EG(This)) { zval_ptr_dtor(&EG(This)); diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index ef3f80e596aa8..ab40e0bb21a7d 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1922,7 +1922,7 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) EX(call)--; - zend_vm_stack_clear_multiple(TSRMLS_C); + zend_vm_stack_clear_multiple(1 TSRMLS_CC); if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); @@ -2098,7 +2098,7 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) EX(call)--; - zend_vm_stack_clear_multiple(TSRMLS_C); + zend_vm_stack_clear_multiple(1 TSRMLS_CC); if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 4e4dedfd0888b..7f3420f93a859 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -463,7 +463,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) EX(call)--; - zend_vm_stack_clear_multiple(TSRMLS_C); + zend_vm_stack_clear_multiple(1 TSRMLS_CC); if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); @@ -639,7 +639,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR EX(call)--; - zend_vm_stack_clear_multiple(TSRMLS_C); + zend_vm_stack_clear_multiple(1 TSRMLS_CC); if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); From d5c2da57560017c2b4f8951f600d8e6a839568ec Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 13 Dec 2012 17:51:04 +0400 Subject: [PATCH 2209/2394] Removed unreachable code --- Zend/zend_vm_def.h | 18 ----------------- Zend/zend_vm_execute.h | 45 ------------------------------------------ 2 files changed, 63 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index ab40e0bb21a7d..fedd7204b8ef1 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1880,15 +1880,6 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION_LEAVE(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } ZEND_VM_INC_OPCODE(); @@ -3857,15 +3848,6 @@ ZEND_VM_HANDLER(73, ZEND_INCLUDE_OR_EVAL, CONST|TMP|VAR|CV, ANY) if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } } else if (RETURN_VALUE_USED(opline)) { diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 7f3420f93a859..50a3ab525eb21 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -421,15 +421,6 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION_LEAVE(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } ZEND_VM_INC_OPCODE(); @@ -2735,15 +2726,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HA if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } } else if (RETURN_VALUE_USED(opline)) { @@ -8058,15 +8040,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } } else if (RETURN_VALUE_USED(opline)) { @@ -13393,15 +13366,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } } else if (RETURN_VALUE_USED(opline)) { @@ -30967,15 +30931,6 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL if (UNEXPECTED(EG(exception) != NULL)) { zend_throw_exception_internal(NULL TSRMLS_CC); HANDLE_EXCEPTION(); - } else if (RETURN_VALUE_USED(opline)) { - if (!EX_T(opline->result.var).var.ptr) { /* there was no return statement */ - zval *retval; - - ALLOC_ZVAL(retval); - ZVAL_BOOL(retval, 1); - INIT_PZVAL(retval); - EX_T(opline->result.var).var.ptr = retval; - } } } else if (RETURN_VALUE_USED(opline)) { From e65b966aac8af19cc7b7dd3bf68639b869a66f99 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Fri, 14 Dec 2012 12:10:29 +0400 Subject: [PATCH 2210/2394] Fixed uninitialized EX(call)->called_scope --- Zend/zend_vm_def.h | 4 ++++ Zend/zend_vm_execute.h | 10 ++++++++++ 2 files changed, 14 insertions(+) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index fedd7204b8ef1..a9ed07e118f2e 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2636,6 +2636,7 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; /*CHECK_EXCEPTION();*/ @@ -2663,6 +2664,7 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) efree(lcname); FREE_OP2(); call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; CHECK_EXCEPTION(); @@ -2782,6 +2784,7 @@ ZEND_VM_HANDLER(69, ZEND_INIT_NS_FCALL_BY_NAME, ANY, CONST) } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; ZEND_VM_NEXT_OPCODE(); @@ -2810,6 +2813,7 @@ ZEND_VM_HANDLER(60, ZEND_DO_FCALL, CONST, ANY) } call->fbc = EX(function_state).function; call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 50a3ab525eb21..6890f58525b53 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1218,6 +1218,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; /*CHECK_EXCEPTION();*/ @@ -1245,6 +1246,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE efree(lcname); call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; CHECK_EXCEPTION(); @@ -1364,6 +1366,7 @@ static int ZEND_FASTCALL ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPC } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; ZEND_VM_NEXT_OPCODE(); @@ -1535,6 +1538,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; /*CHECK_EXCEPTION();*/ @@ -1562,6 +1566,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H efree(lcname); zval_dtor(free_op2.var); call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; CHECK_EXCEPTION(); @@ -1713,6 +1718,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; /*CHECK_EXCEPTION();*/ @@ -1740,6 +1746,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H efree(lcname); if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; CHECK_EXCEPTION(); @@ -1926,6 +1933,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA CACHE_PTR(opline->op2.literal->cache_slot, call->fbc); } call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; /*CHECK_EXCEPTION();*/ @@ -1953,6 +1961,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA efree(lcname); call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; CHECK_EXCEPTION(); @@ -2287,6 +2296,7 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A } call->fbc = EX(function_state).function; call->object = NULL; + call->called_scope = NULL; call->is_ctor_call = 0; EX(call) = call; From a4678099a15fcf894ff2d5f6dae0bd4d98bcec47 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 14 Dec 2012 16:51:34 +0800 Subject: [PATCH 2211/2394] Add test for bug #63741 --- Zend/tests/bug63741.phpt | 50 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 Zend/tests/bug63741.phpt diff --git a/Zend/tests/bug63741.phpt b/Zend/tests/bug63741.phpt new file mode 100644 index 0000000000000..fc04c9e79c4b4 --- /dev/null +++ b/Zend/tests/bug63741.phpt @@ -0,0 +1,50 @@ +--TEST-- +Bug #63741 (Crash when autoloading from spl) +--FILE-- + +EOT +); + +include dirname(__FILE__)."/bug63741.tmp.php"; +?> +--CLEAN-- + +--EXPECT-- +autoloading... +OK! From 359d91a80756cd9a9ce945c0e3aa1d2038633e7a Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 14 Dec 2012 16:52:56 +0800 Subject: [PATCH 2212/2394] Add test for bug #63741 --- Zend/tests/bug63741.phpt | 50 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 Zend/tests/bug63741.phpt diff --git a/Zend/tests/bug63741.phpt b/Zend/tests/bug63741.phpt new file mode 100644 index 0000000000000..fc04c9e79c4b4 --- /dev/null +++ b/Zend/tests/bug63741.phpt @@ -0,0 +1,50 @@ +--TEST-- +Bug #63741 (Crash when autoloading from spl) +--FILE-- + +EOT +); + +include dirname(__FILE__)."/bug63741.tmp.php"; +?> +--CLEAN-- + +--EXPECT-- +autoloading... +OK! From 9fb5cfdeb1f13f2e3ab3751494cdd366bc78cb38 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 14 Dec 2012 17:21:43 +0800 Subject: [PATCH 2213/2394] Fixed warning of no return in non-void funciton --- Zend/zend_vm_def.h | 2 ++ Zend/zend_vm_execute.h | 13 +++++++++++++ Zend/zend_vm_gen.php | 3 +++ 3 files changed, 18 insertions(+) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index a9ed07e118f2e..f7b10a29a68d9 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1330,6 +1330,7 @@ ZEND_VM_HANDLER(96, ZEND_FETCH_DIM_UNSET, VAR|CV, CONST|TMP|VAR|CV) FREE_OP1_VAR_PTR(); if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -2757,6 +2758,7 @@ ZEND_VM_HANDLER(59, ZEND_INIT_FCALL_BY_NAME, ANY, CONST|TMP|VAR|CV) ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } } } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 6890f58525b53..c077d5d2a5393 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1339,6 +1339,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } } } @@ -1659,6 +1660,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } } } @@ -1839,6 +1841,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } } } @@ -2054,6 +2057,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } else { zend_error_noreturn(E_ERROR, "Function name must be a string"); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } } } @@ -14882,6 +14886,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCOD if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -17219,6 +17224,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_ if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -19470,6 +19476,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_ if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -22915,6 +22922,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_H if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -32299,6 +32307,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -34411,6 +34420,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_H if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -36529,6 +36539,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_H if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -39697,6 +39708,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HA if (UNEXPECTED(EX_T(opline->result.var).var.ptr_ptr == NULL)) { zend_error_noreturn(E_ERROR, "Cannot unset string offsets"); + ZEND_VM_NEXT_OPCODE(); } else { zend_free_op free_res; zval **retval_ptr = EX_T(opline->result.var).var.ptr_ptr; @@ -40810,6 +40822,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS static int ZEND_FASTCALL ZEND_NULL_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { zend_error_noreturn(E_ERROR, "Invalid opcode %d/%d/%d.", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } diff --git a/Zend/zend_vm_gen.php b/Zend/zend_vm_gen.php index b56dd70f40120..42f17ed7c6529 100644 --- a/Zend/zend_vm_gen.php +++ b/Zend/zend_vm_gen.php @@ -710,6 +710,7 @@ function gen_null_handler($f) { out($f,"static int ZEND_FASTCALL ZEND_NULL_HANDLER(ZEND_OPCODE_HANDLER_ARGS)\n"); out($f,"{\n"); out($f,"\tzend_error_noreturn(E_ERROR, \"Invalid opcode %d/%d/%d.\", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type);\n"); + out($f,"\tZEND_VM_NEXT_OPCODE(); /* Never reached */\n"); out($f,"}\n\n"); } } @@ -784,10 +785,12 @@ function gen_executor_code($f, $spec, $kind, $prolog) { case ZEND_VM_KIND_SWITCH: out($f,"default:\n"); out($f,"\tzend_error_noreturn(E_ERROR, \"Invalid opcode %d/%d/%d.\", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type);\n"); + out($f,"\tZEND_VM_NEXT_OPCODE(); /* Never reached */\n"); break; case ZEND_VM_KIND_GOTO: out($f,"ZEND_NULL_HANDLER:\n"); out($f,"\tzend_error_noreturn(E_ERROR, \"Invalid opcode %d/%d/%d.\", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type);\n"); + out($f,"\tZEND_VM_NEXT_OPCODE(); /* Never reached */\n"); break; } } From a73a6be76417571e7e4a467e8d9c7f82e8a45a9c Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 14 Dec 2012 17:26:42 +0800 Subject: [PATCH 2214/2394] Fix warning of no return in non-void function --- Zend/zend_generators.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 2ee2fb9681351..9eae2c7019349 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -731,6 +731,7 @@ static int zend_generator_iterator_get_key(zend_object_iterator *iterator, char /* Waiting for Etienne's patch to allow arbitrary zval keys. Until then * error out on non-int and non-string keys. */ zend_error_noreturn(E_ERROR, "Currently only int and string keys can be yielded"); + return HASH_KEY_NON_EXISTANT; /* Nerver reached */ } /* }}} */ From 717b367085d55528cad82716bc5ad9736831540f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Sun, 16 Dec 2012 08:51:17 +0100 Subject: [PATCH 2215/2394] Fixed bug #63706: Cannot build PHP-5.5 with --enable-dtrace on Fedora 17 --- acinclude.m4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 2085f0bb5b88a..aadf4c06ee8dc 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2963,12 +2963,12 @@ dnl Generate Makefile.objects entries cat>>Makefile.objects< Date: Sun, 16 Dec 2012 08:51:17 +0100 Subject: [PATCH 2216/2394] Fixed bug #63706: Cannot build PHP-5.5 with --enable-dtrace on Fedora 17 --- acinclude.m4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 2085f0bb5b88a..aadf4c06ee8dc 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2963,12 +2963,12 @@ dnl Generate Makefile.objects entries cat>>Makefile.objects< Date: Sun, 16 Dec 2012 09:07:55 +0100 Subject: [PATCH 2217/2394] Ignore Zend/zend_dtrace_gen.h and Zend/zend_dtrace_gen.hbak --- .gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index 6f291dc917b87..cf615c6e922f5 100644 --- a/.gitignore +++ b/.gitignore @@ -96,6 +96,8 @@ stamp-h.in scan_makefile_in.awk TSRM/tsrm_config.h Zend/zend_config.h +Zend/zend_dtrace_gen.h +Zend/zend_dtrace_gen.hbak Zend/zend_ini_parser.c Zend/zend_ini_parser.h Zend/zend_ini_parser.output From 28db07a0e39ee593edc843ce3c162da247eb2bbe Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 18 Dec 2012 15:20:58 +0800 Subject: [PATCH 2218/2394] Fixed bug that exception won't be catched related failed test Zend/tests/bug35437.phpt (after he latest execute_data improvement, run with non CALL vm kind) --- Zend/zend_vm_def.h | 8 +- Zend/zend_vm_execute.h | 11959 ++++++++++++++++++++------------------- 2 files changed, 6084 insertions(+), 5883 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index f7b10a29a68d9..bfe6f722f317e 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1942,14 +1942,15 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); /* Never reached */ } if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", fbc->common.scope ? fbc->common.scope->name : "", fbc->common.scope ? "::" : "", fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } } if (fbc->common.scope && @@ -1959,6 +1960,9 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { /* FIXME: output identifiers properly */ zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } else { /* FIXME: output identifiers properly */ /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index c077d5d2a5393..23a886ca85f40 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -307,11 +307,11 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #undef USE_OPLINE #undef LOAD_OPLINE #undef SAVE_OPLINE -#define OPLINE EX(opline) -#define DCL_OPLINE -#define USE_OPLINE zend_op *opline = EX(opline); -#define LOAD_OPLINE() -#define SAVE_OPLINE() +#define OPLINE opline +#define DCL_OPLINE zend_op *opline; +#define USE_OPLINE +#define LOAD_OPLINE() opline = EX(opline) +#define SAVE_OPLINE() EX(opline) = opline #undef CHECK_EXCEPTION #undef HANDLE_EXCEPTION #undef HANDLE_EXCEPTION_LEAVE @@ -319,11 +319,11 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #define HANDLE_EXCEPTION() LOAD_OPLINE(); ZEND_VM_CONTINUE() #define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE() #define LOAD_REGS() -#define ZEND_VM_CONTINUE() return 0 -#define ZEND_VM_RETURN() return 1 -#define ZEND_VM_ENTER() return 2 -#define ZEND_VM_LEAVE() return 3 -#define ZEND_VM_DISPATCH(opcode, opline) return zend_vm_get_opcode_handler(opcode, opline)(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); +#define ZEND_VM_CONTINUE() goto zend_vm_continue +#define ZEND_VM_RETURN() EG(in_execution) = original_in_execution; return +#define ZEND_VM_ENTER() goto zend_vm_enter +#define ZEND_VM_LEAVE() ZEND_VM_CONTINUE() +#define ZEND_VM_DISPATCH(opcode, opline) dispatch_handler = zend_vm_get_opcode_handler(opcode, opline); goto zend_vm_dispatch; #define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC @@ -332,6 +332,11 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) DCL_OPLINE zend_bool original_in_execution; + opcode_handler_t dispatch_handler; + int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC); + incdec_t incdec_op; + int type; + int prop_dim; original_in_execution = EG(in_execution); @@ -346,42 +351,17 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) LOAD_OPLINE(); while (1) { - int ret; +zend_vm_continue: #ifdef ZEND_WIN32 if (EG(timed_out)) { zend_timeout(0); } #endif - if ((ret = OPLINE->handler(execute_data TSRMLS_CC)) > 0) { - switch (ret) { - case 1: - EG(in_execution) = original_in_execution; - return; - case 2: - goto zend_vm_enter; - break; - case 3: - execute_data = EG(current_execute_data); - break; - default: - break; - } - } - - } - zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); -} - -ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) -{ - if (EG(exception)) { - return; - } - zend_execute_ex(i_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); -} - -static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) + dispatch_handler = OPLINE->handler; +zend_vm_dispatch: + switch ((int)dispatch_handler) { +zend_leave_helper_SPEC: { zend_bool nested; zend_op_array *op_array = EX(op_array); @@ -471,7 +451,7 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) +zend_do_fcall_common_helper_SPEC: { USE_OPLINE zend_bool should_change_scope = 0; @@ -482,14 +462,15 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); /* Never reached */ } if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", fbc->common.scope ? fbc->common.scope->name : "", fbc->common.scope ? "::" : "", fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } } if (fbc->common.scope && @@ -499,6 +480,9 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { /* FIXME: output identifiers properly */ zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } else { /* FIXME: output identifiers properly */ /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ @@ -643,7 +627,7 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1050: /*ZEND_JMP_SPEC_HANDLER*/ { USE_OPLINE @@ -654,7 +638,7 @@ static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_CONTINUE(); } -static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1325: /*ZEND_INIT_STRING_SPEC_HANDLER*/ { USE_OPLINE zval *tmp = &EX_T(opline->result.var).tmp_var; @@ -670,13 +654,13 @@ static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1525: /*ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER*/ { EX(function_state).function = EX(call)->fbc; - return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_do_fcall_common_helper_SPEC; } -static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4025: /*ZEND_GENERATOR_RETURN_SPEC_HANDLER*/ ZEND_GENERATOR_RETURN_SPEC_LABEL: { /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -688,7 +672,7 @@ static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1575: /*ZEND_RECV_SPEC_HANDLER*/ { USE_OPLINE zend_uint arg_num = opline->op1.num; @@ -729,7 +713,7 @@ static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_NEW_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1700: /*ZEND_NEW_SPEC_HANDLER*/ { USE_OPLINE zval *object_zval; @@ -779,7 +763,7 @@ static int ZEND_FASTCALL ZEND_NEW_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } } -static int ZEND_FASTCALL ZEND_BEGIN_SILENCE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1425: /*ZEND_BEGIN_SILENCE_SPEC_HANDLER*/ { USE_OPLINE @@ -820,14 +804,14 @@ static int ZEND_FASTCALL ZEND_BEGIN_SILENCE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3550: /*ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER*/ { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", EG(scope)->name, EX(op_array)->function_name); ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -static int ZEND_FASTCALL ZEND_EXT_STMT_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2525: /*ZEND_EXT_STMT_SPEC_HANDLER*/ { SAVE_OPLINE(); if (!EG(no_extensions)) { @@ -837,7 +821,7 @@ static int ZEND_FASTCALL ZEND_EXT_STMT_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2550: /*ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER*/ { SAVE_OPLINE(); if (!EG(no_extensions)) { @@ -847,7 +831,7 @@ static int ZEND_FASTCALL ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_EXT_FCALL_END_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2575: /*ZEND_EXT_FCALL_END_SPEC_HANDLER*/ { SAVE_OPLINE(); if (!EG(no_extensions)) { @@ -857,7 +841,7 @@ static int ZEND_FASTCALL ZEND_EXT_FCALL_END_SPEC_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DECLARE_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3475: /*ZEND_DECLARE_CLASS_SPEC_HANDLER*/ { USE_OPLINE @@ -867,7 +851,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3500: /*ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER*/ { USE_OPLINE @@ -877,7 +861,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3625: /*ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER*/ { USE_OPLINE zend_class_entry **pce, **pce_orig; @@ -892,7 +876,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER(ZEND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DECLARE_FUNCTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3525: /*ZEND_DECLARE_FUNCTION_SPEC_HANDLER*/ { USE_OPLINE @@ -902,7 +886,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_FUNCTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_TICKS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2625: /*ZEND_TICKS_SPEC_HANDLER*/ { USE_OPLINE @@ -917,17 +901,17 @@ static int ZEND_FASTCALL ZEND_TICKS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_EXT_NOP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2600: /*ZEND_EXT_NOP_SPEC_HANDLER*/ { ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_NOP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 0: /*ZEND_NOP_SPEC_HANDLER*/ { ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_TRAIT_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3850: /*ZEND_ADD_TRAIT_SPEC_HANDLER*/ { USE_OPLINE zend_class_entry *ce = EX_T(opline->op1.var).class_entry; @@ -957,7 +941,7 @@ static int ZEND_FASTCALL ZEND_ADD_TRAIT_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BIND_TRAITS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3875: /*ZEND_BIND_TRAITS_SPEC_HANDLER*/ { USE_OPLINE zend_class_entry *ce = EX_T(opline->op1.var).class_entry; @@ -968,7 +952,7 @@ static int ZEND_FASTCALL ZEND_BIND_TRAITS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3725: /*ZEND_HANDLE_EXCEPTION_SPEC_HANDLER*/ { zend_uint op_num = EG(opline_before_exception)-EG(active_op_array)->opcodes; int i; @@ -1067,14 +1051,14 @@ static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_CONTINUE(); } else { if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_GENERATOR_RETURN_SPEC_LABEL; } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } } } -static int ZEND_FASTCALL ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3650: /*ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER*/ { USE_OPLINE @@ -1084,7 +1068,7 @@ static int ZEND_FASTCALL ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3750: /*ZEND_USER_OPCODE_SPEC_HANDLER*/ { USE_OPLINE int ret; @@ -1098,9 +1082,9 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_CONTINUE(); case ZEND_USER_OPCODE_RETURN: if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_GENERATOR_RETURN_SPEC_LABEL; } else { - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } case ZEND_USER_OPCODE_ENTER: ZEND_VM_ENTER(); @@ -1113,7 +1097,7 @@ static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } -static int ZEND_FASTCALL ZEND_DISCARD_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3975: /*ZEND_DISCARD_EXCEPTION_SPEC_HANDLER*/ { if (EG(prev_exception) != NULL) { /* discard the previously thrown exception */ @@ -1124,7 +1108,7 @@ static int ZEND_FASTCALL ZEND_DISCARD_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4050: /*ZEND_FAST_CALL_SPEC_HANDLER*/ { USE_OPLINE @@ -1139,7 +1123,7 @@ static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_CONTINUE(); } -static int ZEND_FASTCALL ZEND_FAST_RET_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4075: /*ZEND_FAST_RET_SPEC_HANDLER*/ { if (EX(fast_ret)) { ZEND_VM_SET_OPCODE(EX(fast_ret)); @@ -1157,15 +1141,15 @@ static int ZEND_FASTCALL ZEND_FAST_RET_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_CONTINUE(); } else if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { zend_exception_restore(TSRMLS_C); - return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_GENERATOR_RETURN_SPEC_LABEL; } else { zend_exception_restore(TSRMLS_C); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } } } -static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2725: /*ZEND_FETCH_CLASS_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -1201,7 +1185,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLE } } -static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1475: /*ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -1345,7 +1329,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE } -static int ZEND_FASTCALL ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1725: /*ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER*/ { USE_OPLINE zend_literal *func_name; @@ -1373,7 +1357,7 @@ static int ZEND_FASTCALL ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_RECV_INIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1600: /*ZEND_RECV_INIT_SPEC_CONST_HANDLER*/ { USE_OPLINE zval *assignment_value; @@ -1407,7 +1391,7 @@ static int ZEND_FASTCALL ZEND_RECV_INIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1250: /*ZEND_BRK_SPEC_CONST_HANDLER*/ { USE_OPLINE zend_brk_cont_element *el; @@ -1419,7 +1403,7 @@ static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } -static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1275: /*ZEND_CONT_SPEC_CONST_HANDLER*/ { USE_OPLINE zend_brk_cont_element *el; @@ -1431,7 +1415,7 @@ static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } -static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2500: /*ZEND_GOTO_SPEC_CONST_HANDLER*/ { zend_op *brk_opline; USE_OPLINE @@ -1458,7 +1442,7 @@ static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_JMP(opline->op1.jmp_addr); } -static int ZEND_FASTCALL ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3600: /*ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER*/ { USE_OPLINE zend_class_entry *ce = EX_T(opline->op1.var).class_entry; @@ -1485,7 +1469,7 @@ static int ZEND_FASTCALL ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2726: /*ZEND_FETCH_CLASS_SPEC_TMP_HANDLER*/ { USE_OPLINE @@ -1522,7 +1506,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ } } -static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1476: /*ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -1666,7 +1650,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_H } -static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2727: /*ZEND_FETCH_CLASS_SPEC_VAR_HANDLER*/ { USE_OPLINE @@ -1703,7 +1687,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ } } -static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1477: /*ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -1847,7 +1831,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_H } -static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2728: /*ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER*/ { USE_OPLINE @@ -1883,7 +1867,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDL } } -static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2729: /*ZEND_FETCH_CLASS_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -1919,7 +1903,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A } } -static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1479: /*ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -2063,7 +2047,7 @@ static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HA } -static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 300: /*ZEND_BW_NOT_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2076,7 +2060,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 325: /*ZEND_BOOL_NOT_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2089,7 +2073,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ECHO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1000: /*ZEND_ECHO_SPEC_CONST_HANDLER*/ ZEND_ECHO_SPEC_CONST_LABEL: { USE_OPLINE @@ -2119,15 +2103,15 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRINT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1025: /*ZEND_PRINT_SPEC_CONST_HANDLER*/ { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - return ZEND_ECHO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ECHO_SPEC_CONST_LABEL; } -static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1075: /*ZEND_JMPZ_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2157,7 +2141,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1100: /*ZEND_JMPNZ_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2187,7 +2171,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1125: /*ZEND_JMPZNZ_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2221,7 +2205,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG } } -static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1150: /*ZEND_JMPZ_EX_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2252,7 +2236,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1175: /*ZEND_JMPNZ_EX_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2283,7 +2267,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DO_FCALL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1500: /*ZEND_DO_FCALL_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2304,10 +2288,10 @@ static int ZEND_FASTCALL ZEND_DO_FCALL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A call->is_ctor_call = 0; EX(call) = call; - return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_do_fcall_common_helper_SPEC; } -static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1550: /*ZEND_RETURN_SPEC_CONST_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -2354,10 +2338,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG *EG(return_value_ptr_ptr) = ret; } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2775: /*ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -2425,10 +2409,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND } } while (0); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2700: /*ZEND_THROW_SPEC_CONST_HANDLER*/ { USE_OPLINE zval *value; @@ -2455,7 +2439,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS HANDLE_EXCEPTION(); } -static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1625: /*ZEND_SEND_VAL_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2483,7 +2467,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1300: /*ZEND_BOOL_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2497,7 +2481,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CLONE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2750: /*ZEND_CLONE_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2560,7 +2544,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CAST_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 525: /*ZEND_CAST_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2619,7 +2603,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1825: /*ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER*/ { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -2753,7 +2737,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1925: /*ZEND_FE_RESET_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2895,7 +2879,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A } } -static int ZEND_FASTCALL ZEND_EXIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1975: /*ZEND_EXIT_SPEC_CONST_HANDLER*/ { #if 0 || (IS_CONST != IS_UNUSED) USE_OPLINE @@ -2917,7 +2901,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3800: /*ZEND_JMP_SET_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2942,7 +2926,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3950: /*ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2976,7 +2960,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 550: /*ZEND_QM_ASSIGN_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -2994,7 +2978,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3925: /*ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER*/ { USE_OPLINE @@ -3021,7 +3005,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 25: /*ZEND_ADD_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3036,7 +3020,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 50: /*ZEND_SUB_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3051,7 +3035,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 75: /*ZEND_MUL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3066,7 +3050,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 100: /*ZEND_DIV_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3081,7 +3065,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 125: /*ZEND_MOD_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3096,7 +3080,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 150: /*ZEND_SL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3111,7 +3095,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 175: /*ZEND_SR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3126,7 +3110,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 200: /*ZEND_CONCAT_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3141,7 +3125,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 375: /*ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3156,7 +3140,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 400: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3173,7 +3157,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 425: /*ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3189,7 +3173,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 450: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3205,7 +3189,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 475: /*ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3221,7 +3205,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 500: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3237,7 +3221,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 225: /*ZEND_BW_OR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3252,7 +3236,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 250: /*ZEND_BW_AND_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3267,7 +3251,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 275: /*ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3282,7 +3266,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 350: /*ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3297,7 +3281,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_CONST_CONST: { USE_OPLINE zend_free_op free_op1; @@ -3429,39 +3413,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_CONST(int type ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2000: /*ZEND_FETCH_R_SPEC_CONST_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2075: /*ZEND_FETCH_W_SPEC_CONST_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2150: /*ZEND_FETCH_RW_SPEC_CONST_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2300: /*ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CONST_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2375: /*ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2225: /*ZEND_FETCH_IS_SPEC_CONST_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2025: /*ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3491,7 +3475,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2450: /*ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3515,7 +3499,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2825: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -3633,7 +3617,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER( ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1200: /*ZEND_CASE_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3650,7 +3634,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2475: /*ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3742,7 +3726,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER(ZEND_OPCO } } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1800: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_LABEL: { USE_OPLINE @@ -3786,18 +3770,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER(ZEND_O switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CONST_CONST; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CONST_CONST: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -3828,7 +3812,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1775: /*ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -3837,12 +3821,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1850: /*ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -3918,7 +3902,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2850: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE zval **value; @@ -4003,7 +3987,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3575: /*ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -4043,7 +4027,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4000: /*ZEND_YIELD_SPEC_CONST_CONST_HANDLER*/ { USE_OPLINE @@ -4197,7 +4181,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 26: /*ZEND_ADD_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4212,7 +4196,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 51: /*ZEND_SUB_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4227,7 +4211,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 76: /*ZEND_MUL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4242,7 +4226,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 101: /*ZEND_DIV_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4257,7 +4241,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 126: /*ZEND_MOD_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4272,7 +4256,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 151: /*ZEND_SL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4287,7 +4271,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 176: /*ZEND_SR_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4302,7 +4286,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 201: /*ZEND_CONCAT_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4317,7 +4301,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 376: /*ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4332,7 +4316,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 401: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4349,7 +4333,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 426: /*ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4365,7 +4349,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 451: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4381,7 +4365,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 476: /*ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4397,7 +4381,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 501: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4413,7 +4397,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 226: /*ZEND_BW_OR_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4428,7 +4412,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 251: /*ZEND_BW_AND_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4443,7 +4427,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 276: /*ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4458,7 +4442,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 351: /*ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4473,7 +4457,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2026: /*ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4503,7 +4487,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2826: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -4621,7 +4605,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1201: /*ZEND_CASE_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4639,7 +4623,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1801: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_LABEL: { USE_OPLINE @@ -4683,18 +4667,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPC switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CONST_TMP; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CONST_TMP: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -4725,7 +4709,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1776: /*ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE @@ -4734,12 +4718,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4001: /*ZEND_YIELD_SPEC_CONST_TMP_HANDLER*/ { USE_OPLINE @@ -4893,7 +4877,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 27: /*ZEND_ADD_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4908,7 +4892,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 52: /*ZEND_SUB_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4923,7 +4907,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 77: /*ZEND_MUL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4938,7 +4922,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 102: /*ZEND_DIV_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4953,7 +4937,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 127: /*ZEND_MOD_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4968,7 +4952,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 152: /*ZEND_SL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4983,7 +4967,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 177: /*ZEND_SR_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -4998,7 +4982,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 202: /*ZEND_CONCAT_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5013,7 +4997,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 377: /*ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5028,7 +5012,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 402: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5045,7 +5029,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 427: /*ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5061,7 +5045,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 452: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5077,7 +5061,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 477: /*ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5093,7 +5077,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 502: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5109,7 +5093,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 227: /*ZEND_BW_OR_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5124,7 +5108,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 252: /*ZEND_BW_AND_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5139,7 +5123,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 277: /*ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5154,7 +5138,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 352: /*ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5169,7 +5153,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_CONST_VAR: { USE_OPLINE zend_free_op free_op1; @@ -5301,39 +5285,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_VAR(int type, ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2002: /*ZEND_FETCH_R_SPEC_CONST_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2077: /*ZEND_FETCH_W_SPEC_CONST_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2152: /*ZEND_FETCH_RW_SPEC_CONST_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2302: /*ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CONST_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2377: /*ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2227: /*ZEND_FETCH_IS_SPEC_CONST_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2027: /*ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5363,7 +5347,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2827: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -5481,7 +5465,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1202: /*ZEND_CASE_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -5499,7 +5483,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1802: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_LABEL: { USE_OPLINE @@ -5543,18 +5527,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPC switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CONST_VAR; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CONST_VAR: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -5585,7 +5569,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1777: /*ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE @@ -5594,12 +5578,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1852: /*ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -5675,7 +5659,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2852: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE zval **value; @@ -5760,7 +5744,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4002: /*ZEND_YIELD_SPEC_CONST_VAR_HANDLER*/ { USE_OPLINE @@ -5915,7 +5899,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_CONST_UNUSED: { USE_OPLINE zend_free_op free_op1; @@ -6047,39 +6031,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_UNUSED(int typ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2003: /*ZEND_FETCH_R_SPEC_CONST_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2078: /*ZEND_FETCH_W_SPEC_CONST_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2153: /*ZEND_FETCH_RW_SPEC_CONST_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2303: /*ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2378: /*ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2228: /*ZEND_FETCH_IS_SPEC_CONST_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2828: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE zval *function_name; @@ -6197,7 +6181,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1803: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_LABEL: { USE_OPLINE @@ -6241,18 +6225,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER(ZEND_ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CONST_UNUSED; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CONST_UNUSED: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_UNUSED); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -6283,7 +6267,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER(ZEND_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1778: /*ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE @@ -6292,12 +6276,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1853: /*ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -6373,7 +6357,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2853: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE zval **value; @@ -6458,7 +6442,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3828: /*ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE zend_function *op_array; @@ -6476,7 +6460,7 @@ static int ZEND_FASTCALL ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4003: /*ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER*/ { USE_OPLINE @@ -6630,7 +6614,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 29: /*ZEND_ADD_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6645,7 +6629,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 54: /*ZEND_SUB_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6660,7 +6644,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 79: /*ZEND_MUL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6675,7 +6659,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 104: /*ZEND_DIV_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6690,7 +6674,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 129: /*ZEND_MOD_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6705,7 +6689,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 154: /*ZEND_SL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6720,7 +6704,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 179: /*ZEND_SR_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6735,7 +6719,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 204: /*ZEND_CONCAT_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6750,7 +6734,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 379: /*ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6765,7 +6749,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 404: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6782,7 +6766,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 429: /*ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6798,7 +6782,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 454: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6814,7 +6798,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 479: /*ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6830,7 +6814,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 504: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6846,7 +6830,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 229: /*ZEND_BW_OR_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6861,7 +6845,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 254: /*ZEND_BW_AND_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6876,7 +6860,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 279: /*ZEND_BW_XOR_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6891,7 +6875,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 354: /*ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6906,7 +6890,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2029: /*ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -6936,7 +6920,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2829: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -7054,7 +7038,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CATCH_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2679: /*ZEND_CATCH_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE zend_class_entry *ce, *catch_ce; @@ -7114,7 +7098,7 @@ static int ZEND_FASTCALL ZEND_CATCH_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A } } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1204: /*ZEND_CASE_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -7131,7 +7115,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1804: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_LABEL: { USE_OPLINE @@ -7175,18 +7159,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCO switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CONST_CV; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CONST_CV: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -7217,7 +7201,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1779: /*ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -7226,12 +7210,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4004: /*ZEND_YIELD_SPEC_CONST_CV_HANDLER*/ { USE_OPLINE @@ -7385,7 +7369,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 305: /*ZEND_BW_NOT_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7398,7 +7382,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 330: /*ZEND_BOOL_NOT_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7411,7 +7395,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1005: /*ZEND_ECHO_SPEC_TMP_HANDLER*/ ZEND_ECHO_SPEC_TMP_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -7442,15 +7426,15 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRINT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1030: /*ZEND_PRINT_SPEC_TMP_HANDLER*/ { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - return ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ECHO_SPEC_TMP_LABEL; } -static int ZEND_FASTCALL ZEND_JMPZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1080: /*ZEND_JMPZ_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7480,7 +7464,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1105: /*ZEND_JMPNZ_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7510,7 +7494,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1130: /*ZEND_JMPZNZ_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7544,7 +7528,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } } -static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1155: /*ZEND_JMPZ_EX_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7575,7 +7559,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1180: /*ZEND_JMPNZ_EX_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7606,7 +7590,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FREE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1755: /*ZEND_FREE_SPEC_TMP_HANDLER*/ { USE_OPLINE @@ -7620,7 +7604,7 @@ static int ZEND_FASTCALL ZEND_FREE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1555: /*ZEND_RETURN_SPEC_TMP_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -7667,10 +7651,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2780: /*ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -7738,10 +7722,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE } } while (0); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2705: /*ZEND_THROW_SPEC_TMP_HANDLER*/ { USE_OPLINE zval *value; @@ -7768,7 +7752,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) HANDLE_EXCEPTION(); } -static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1630: /*ZEND_SEND_VAL_SPEC_TMP_HANDLER*/ { USE_OPLINE @@ -7796,7 +7780,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1305: /*ZEND_BOOL_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7811,7 +7795,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CLONE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2755: /*ZEND_CLONE_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7874,7 +7858,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CAST_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 530: /*ZEND_CAST_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -7933,7 +7917,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1830: /*ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -8067,7 +8051,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1930: /*ZEND_FE_RESET_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8209,7 +8193,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG } } -static int ZEND_FASTCALL ZEND_EXIT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1980: /*ZEND_EXIT_SPEC_TMP_HANDLER*/ { #if 0 || (IS_TMP_VAR != IS_UNUSED) USE_OPLINE @@ -8231,7 +8215,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -static int ZEND_FASTCALL ZEND_END_SILENCE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1455: /*ZEND_END_SILENCE_SPEC_TMP_HANDLER*/ { USE_OPLINE zval restored_error_reporting; @@ -8260,7 +8244,7 @@ static int ZEND_FASTCALL ZEND_END_SILENCE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3805: /*ZEND_JMP_SET_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8286,7 +8270,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3955: /*ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8321,7 +8305,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 555: /*ZEND_QM_ASSIGN_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8339,7 +8323,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3930: /*ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8366,7 +8350,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3455: /*ZEND_INSTANCEOF_SPEC_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8387,7 +8371,7 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 30: /*ZEND_ADD_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8402,7 +8386,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 55: /*ZEND_SUB_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8417,7 +8401,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 80: /*ZEND_MUL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8432,7 +8416,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 105: /*ZEND_DIV_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8447,7 +8431,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 130: /*ZEND_MOD_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8462,7 +8446,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 155: /*ZEND_SL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8477,7 +8461,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 180: /*ZEND_SR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8492,7 +8476,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 205: /*ZEND_CONCAT_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8507,7 +8491,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 380: /*ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8522,7 +8506,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 405: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8539,7 +8523,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 430: /*ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8555,7 +8539,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 455: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8571,7 +8555,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 480: /*ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8587,7 +8571,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 505: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8603,7 +8587,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 230: /*ZEND_BW_OR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8618,7 +8602,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 255: /*ZEND_BW_AND_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8633,7 +8617,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 280: /*ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8648,7 +8632,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 355: /*ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8663,7 +8647,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_TMP_CONST: { USE_OPLINE zend_free_op free_op1; @@ -8795,39 +8779,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_CONST(int type, ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2005: /*ZEND_FETCH_R_SPEC_TMP_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2080: /*ZEND_FETCH_W_SPEC_TMP_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2155: /*ZEND_FETCH_RW_SPEC_TMP_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2305: /*ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_TMP_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2380: /*ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2230: /*ZEND_FETCH_IS_SPEC_TMP_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2030: /*ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8857,7 +8841,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2455: /*ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -8881,7 +8865,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1355: /*ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -8904,7 +8888,7 @@ static int ZEND_FASTCALL ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1380: /*ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -8927,7 +8911,7 @@ static int ZEND_FASTCALL ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2805: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -8999,7 +8983,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1205: /*ZEND_CASE_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -9016,7 +9000,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1805: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -9060,18 +9044,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPC switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_TMP_CONST; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_TMP_CONST: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -9102,7 +9086,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1780: /*ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE @@ -9111,12 +9095,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1855: /*ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -9192,7 +9176,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2855: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE zval **value; @@ -9277,7 +9261,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4005: /*ZEND_YIELD_SPEC_TMP_CONST_HANDLER*/ { USE_OPLINE @@ -9431,7 +9415,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 31: /*ZEND_ADD_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9446,7 +9430,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 56: /*ZEND_SUB_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9461,7 +9445,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 81: /*ZEND_MUL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9476,7 +9460,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 106: /*ZEND_DIV_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9491,7 +9475,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 131: /*ZEND_MOD_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9506,7 +9490,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 156: /*ZEND_SL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9521,7 +9505,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 181: /*ZEND_SR_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9536,7 +9520,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 206: /*ZEND_CONCAT_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9551,7 +9535,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 381: /*ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9566,7 +9550,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 406: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9583,7 +9567,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 431: /*ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9599,7 +9583,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 456: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9615,7 +9599,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 481: /*ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9631,7 +9615,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 506: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9647,7 +9631,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 231: /*ZEND_BW_OR_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9662,7 +9646,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 256: /*ZEND_BW_AND_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9677,7 +9661,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 281: /*ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9692,7 +9676,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 356: /*ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9707,7 +9691,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2031: /*ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9737,7 +9721,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1406: /*ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -9782,7 +9766,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2806: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -9855,7 +9839,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1206: /*ZEND_CASE_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9873,7 +9857,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1806: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -9917,18 +9901,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCOD switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_TMP_TMP; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_TMP_TMP: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -9959,7 +9943,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1781: /*ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE @@ -9968,12 +9952,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4006: /*ZEND_YIELD_SPEC_TMP_TMP_HANDLER*/ { USE_OPLINE @@ -10127,7 +10111,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 32: /*ZEND_ADD_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10142,7 +10126,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 57: /*ZEND_SUB_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10157,7 +10141,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 82: /*ZEND_MUL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10172,7 +10156,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 107: /*ZEND_DIV_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10187,7 +10171,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 132: /*ZEND_MOD_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10202,7 +10186,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 157: /*ZEND_SL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10217,7 +10201,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 182: /*ZEND_SR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10232,7 +10216,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 207: /*ZEND_CONCAT_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10247,7 +10231,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 382: /*ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10262,7 +10246,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 407: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10279,7 +10263,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 432: /*ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10295,7 +10279,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 457: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10311,7 +10295,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 482: /*ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10327,7 +10311,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 507: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10343,7 +10327,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 232: /*ZEND_BW_OR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10358,7 +10342,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 257: /*ZEND_BW_AND_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10373,7 +10357,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 282: /*ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10388,7 +10372,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 357: /*ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10403,7 +10387,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_TMP_VAR: { USE_OPLINE zend_free_op free_op1; @@ -10535,39 +10519,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_VAR(int type, ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2007: /*ZEND_FETCH_R_SPEC_TMP_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2082: /*ZEND_FETCH_W_SPEC_TMP_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2157: /*ZEND_FETCH_RW_SPEC_TMP_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2307: /*ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_TMP_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2382: /*ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2232: /*ZEND_FETCH_IS_SPEC_TMP_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2032: /*ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10597,7 +10581,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1407: /*ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -10642,7 +10626,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2807: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -10715,7 +10699,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1207: /*ZEND_CASE_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10733,7 +10717,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1807: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -10777,18 +10761,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_TMP_VAR; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_TMP_VAR: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -10819,7 +10803,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1782: /*ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE @@ -10828,12 +10812,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1857: /*ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -10909,7 +10893,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2857: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE zval **value; @@ -10994,7 +10978,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4007: /*ZEND_YIELD_SPEC_TMP_VAR_HANDLER*/ { USE_OPLINE @@ -11149,7 +11133,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_TMP_UNUSED: { USE_OPLINE zend_free_op free_op1; @@ -11281,39 +11265,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_UNUSED(int type, ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2008: /*ZEND_FETCH_R_SPEC_TMP_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2083: /*ZEND_FETCH_W_SPEC_TMP_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2158: /*ZEND_FETCH_RW_SPEC_TMP_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2308: /*ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2383: /*ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2233: /*ZEND_FETCH_IS_SPEC_TMP_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1808: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -11357,18 +11341,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OP switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_TMP_UNUSED; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_TMP_UNUSED: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_UNUSED); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -11399,7 +11383,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1783: /*ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER*/ { USE_OPLINE @@ -11408,12 +11392,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1858: /*ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -11489,7 +11473,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2858: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER*/ { USE_OPLINE zval **value; @@ -11574,7 +11558,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4008: /*ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER*/ { USE_OPLINE @@ -11728,7 +11712,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 34: /*ZEND_ADD_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11743,7 +11727,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 59: /*ZEND_SUB_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11758,7 +11742,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 84: /*ZEND_MUL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11773,7 +11757,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 109: /*ZEND_DIV_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11788,7 +11772,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 134: /*ZEND_MOD_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11803,7 +11787,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 159: /*ZEND_SL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11818,7 +11802,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 184: /*ZEND_SR_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11833,7 +11817,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 209: /*ZEND_CONCAT_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11848,7 +11832,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 384: /*ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11863,7 +11847,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 409: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11880,7 +11864,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 434: /*ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11896,7 +11880,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 459: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11912,7 +11896,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 484: /*ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11928,7 +11912,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 509: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11944,7 +11928,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 234: /*ZEND_BW_OR_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11959,7 +11943,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 259: /*ZEND_BW_AND_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11974,7 +11958,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 284: /*ZEND_BW_XOR_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -11989,7 +11973,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 359: /*ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12004,7 +11988,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2034: /*ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12034,7 +12018,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1409: /*ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE @@ -12078,7 +12062,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2809: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -12150,7 +12134,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1209: /*ZEND_CASE_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12167,7 +12151,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1809: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -12211,18 +12195,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_TMP_CV; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_TMP_CV: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -12253,7 +12237,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1784: /*ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE @@ -12262,12 +12246,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4009: /*ZEND_YIELD_SPEC_TMP_CV_HANDLER*/ { USE_OPLINE @@ -12421,7 +12405,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 310: /*ZEND_BW_NOT_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12434,7 +12418,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 335: /*ZEND_BOOL_NOT_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12447,7 +12431,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 860: /*ZEND_PRE_INC_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12494,7 +12478,7 @@ static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 885: /*ZEND_PRE_DEC_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12541,7 +12525,7 @@ static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 910: /*ZEND_POST_INC_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12584,7 +12568,7 @@ static int ZEND_FASTCALL ZEND_POST_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 935: /*ZEND_POST_DEC_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12627,7 +12611,7 @@ static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1010: /*ZEND_ECHO_SPEC_VAR_HANDLER*/ ZEND_ECHO_SPEC_VAR_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -12658,15 +12642,15 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRINT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1035: /*ZEND_PRINT_SPEC_VAR_HANDLER*/ { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - return ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ECHO_SPEC_VAR_LABEL; } -static int ZEND_FASTCALL ZEND_JMPZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1085: /*ZEND_JMPZ_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12696,7 +12680,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1110: /*ZEND_JMPNZ_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12726,7 +12710,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1135: /*ZEND_JMPZNZ_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12760,7 +12744,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } } -static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1160: /*ZEND_JMPZ_EX_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12791,7 +12775,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1185: /*ZEND_JMPNZ_EX_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -12822,7 +12806,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FREE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1760: /*ZEND_FREE_SPEC_VAR_HANDLER*/ { USE_OPLINE @@ -12836,7 +12820,7 @@ static int ZEND_FASTCALL ZEND_FREE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1560: /*ZEND_RETURN_SPEC_VAR_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -12883,10 +12867,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2785: /*ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -12955,10 +12939,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE } while (0); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2710: /*ZEND_THROW_SPEC_VAR_HANDLER*/ { USE_OPLINE zval *value; @@ -12985,7 +12969,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) HANDLE_EXCEPTION(); } -static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS) +zend_send_by_var_helper_SPEC_VAR: { USE_OPLINE zval *varptr; @@ -13013,7 +12997,7 @@ static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2660: /*ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13022,10 +13006,10 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND SAVE_OPLINE(); if (opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) { /* Had function_ptr at compile_time */ if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { - return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_VAR; } } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_VAR; } if (IS_VAR == IS_VAR && @@ -13065,7 +13049,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1685: /*ZEND_SEND_REF_SPEC_VAR_HANDLER*/ ZEND_SEND_REF_SPEC_VAR_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -13087,7 +13071,7 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG } if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_VAR; } SEPARATE_ZVAL_TO_MAKE_IS_REF(varptr_ptr); @@ -13100,19 +13084,19 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEND_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1660: /*ZEND_SEND_VAR_SPEC_VAR_HANDLER*/ { USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - return ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_SEND_REF_SPEC_VAR_LABEL; } SAVE_OPLINE(); - return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_VAR; } -static int ZEND_FASTCALL ZEND_BOOL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1310: /*ZEND_BOOL_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13127,7 +13111,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SWITCH_FREE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1235: /*ZEND_SWITCH_FREE_SPEC_VAR_HANDLER*/ { USE_OPLINE @@ -13137,7 +13121,7 @@ static int ZEND_FASTCALL ZEND_SWITCH_FREE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CLONE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2760: /*ZEND_CLONE_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13200,7 +13184,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CAST_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 535: /*ZEND_CAST_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13259,7 +13243,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1835: /*ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -13393,7 +13377,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1935: /*ZEND_FE_RESET_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13536,7 +13520,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG } } -static int ZEND_FASTCALL ZEND_FE_FETCH_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1960: /*ZEND_FE_FETCH_SPEC_VAR_HANDLER*/ { USE_OPLINE @@ -13678,7 +13662,7 @@ static int ZEND_FASTCALL ZEND_FE_FETCH_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_EXIT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1985: /*ZEND_EXIT_SPEC_VAR_HANDLER*/ { #if 0 || (IS_VAR != IS_UNUSED) USE_OPLINE @@ -13700,7 +13684,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3810: /*ZEND_JMP_SET_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13726,7 +13710,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3960: /*ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13761,7 +13745,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 560: /*ZEND_QM_ASSIGN_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13779,7 +13763,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3935: /*ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13807,7 +13791,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3460: /*ZEND_INSTANCEOF_SPEC_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13828,7 +13812,7 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 35: /*ZEND_ADD_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13843,7 +13827,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 60: /*ZEND_SUB_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13858,7 +13842,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 85: /*ZEND_MUL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13873,7 +13857,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 110: /*ZEND_DIV_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13888,7 +13872,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 135: /*ZEND_MOD_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13903,7 +13887,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 160: /*ZEND_SL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13918,7 +13902,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 185: /*ZEND_SR_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13933,7 +13917,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 210: /*ZEND_CONCAT_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13948,7 +13932,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 385: /*ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13963,7 +13947,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 410: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13980,7 +13964,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 435: /*ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -13996,7 +13980,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 460: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14012,7 +13996,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 485: /*ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14028,7 +14012,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 510: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14044,7 +14028,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 235: /*ZEND_BW_OR_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14059,7 +14043,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 260: /*ZEND_BW_AND_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14074,7 +14058,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 285: /*ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14089,7 +14073,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14104,7 +14088,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1, free_op_data1; @@ -14216,7 +14200,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(int (*b ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1, free_op_data2, free_op_data1; @@ -14226,7 +14210,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binar SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CONST; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -14237,7 +14221,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binar if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CONST; } else { zval *dim = opline->op2.zv; @@ -14305,62 +14289,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binar ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 585: /*ZEND_ASSIGN_ADD_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 610: /*ZEND_ASSIGN_SUB_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 635: /*ZEND_ASSIGN_MUL_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 660: /*ZEND_ASSIGN_DIV_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 685: /*ZEND_ASSIGN_MOD_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 710: /*ZEND_ASSIGN_SL_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 735: /*ZEND_ASSIGN_SR_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 760: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 785: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 810: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 835: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CONST(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1; @@ -14454,17 +14438,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CONST(incdec_t ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3310: /*ZEND_PRE_INC_OBJ_SPEC_VAR_CONST_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3335: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1; @@ -14556,17 +14540,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CONST(incdec_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3360: /*ZEND_POST_INC_OBJ_SPEC_VAR_CONST_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3385: /*ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1; @@ -14698,39 +14682,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_CONST(int type, ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2010: /*ZEND_FETCH_R_SPEC_VAR_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2085: /*ZEND_FETCH_W_SPEC_VAR_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2160: /*ZEND_FETCH_RW_SPEC_VAR_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2310: /*ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_VAR_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2385: /*ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2235: /*ZEND_FETCH_IS_SPEC_VAR_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2035: /*ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14760,7 +14744,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2110: /*ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14794,7 +14778,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2185: /*ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14816,7 +14800,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2260: /*ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14831,7 +14815,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2335: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14861,7 +14845,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2410: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14902,7 +14886,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCOD } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CONST(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1; @@ -14945,12 +14929,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CONST( ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2060: /*ZEND_FETCH_OBJ_R_SPEC_VAR_CONST_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_VAR_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2135: /*ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -14999,7 +14983,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2210: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15030,7 +15014,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2285: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15072,7 +15056,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2360: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE @@ -15105,11 +15089,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OP CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_VAR_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_CONST; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2435: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_res; @@ -15152,7 +15136,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3410: /*ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15182,7 +15166,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3685: /*ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15262,7 +15246,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 960: /*ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_CONST_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -15317,7 +15301,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2810: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -15390,7 +15374,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2835: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -15508,7 +15492,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1210: /*ZEND_CASE_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15525,7 +15509,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2485: /*ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE @@ -15617,7 +15601,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE } } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1810: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -15661,18 +15645,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPC switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_VAR_CONST; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_VAR_CONST: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -15703,7 +15687,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1785: /*ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE @@ -15712,12 +15696,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1860: /*ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -15793,7 +15777,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1885: /*ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15831,7 +15815,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -15847,7 +15831,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_VAR_CONST: zend_hash_index_del(ht, hval); if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { zval_ptr_dtor(&offset); @@ -15893,7 +15877,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1910: /*ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -15934,7 +15918,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2860: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE zval **value; @@ -16019,7 +16003,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST: { USE_OPLINE zend_free_op free_op1; @@ -16043,12 +16027,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST( switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_VAR_CONST; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_VAR_CONST: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -16058,7 +16042,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST( hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_CONST); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -16163,17 +16147,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST( ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2885: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CONST_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3710: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4010: /*ZEND_YIELD_SPEC_VAR_CONST_HANDLER*/ { USE_OPLINE @@ -16329,7 +16313,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 36: /*ZEND_ADD_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16344,7 +16328,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 61: /*ZEND_SUB_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16359,7 +16343,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 86: /*ZEND_MUL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16374,7 +16358,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 111: /*ZEND_DIV_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16389,7 +16373,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 136: /*ZEND_MOD_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16404,7 +16388,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 161: /*ZEND_SL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16419,7 +16403,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 186: /*ZEND_SR_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16434,7 +16418,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 211: /*ZEND_CONCAT_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16449,7 +16433,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 386: /*ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16464,7 +16448,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 411: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16481,7 +16465,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 436: /*ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16497,7 +16481,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 461: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16513,7 +16497,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 486: /*ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16529,7 +16513,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 511: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16545,7 +16529,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 236: /*ZEND_BW_OR_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16560,7 +16544,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 261: /*ZEND_BW_AND_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16575,7 +16559,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 286: /*ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16590,7 +16574,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16605,7 +16589,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_VAR_TMP: { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data1; @@ -16717,7 +16701,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(int (*bin ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_VAR_TMP: { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data2, free_op_data1; @@ -16727,7 +16711,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_TMP; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -16738,7 +16722,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_TMP; } else { zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -16807,62 +16791,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 586: /*ZEND_ASSIGN_ADD_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 611: /*ZEND_ASSIGN_SUB_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 636: /*ZEND_ASSIGN_MUL_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 661: /*ZEND_ASSIGN_DIV_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 686: /*ZEND_ASSIGN_MOD_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 711: /*ZEND_ASSIGN_SL_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 736: /*ZEND_ASSIGN_SR_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 761: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 786: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 811: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 836: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_TMP(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_VAR_TMP: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16956,17 +16940,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_TMP(incdec_t i ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3311: /*ZEND_PRE_INC_OBJ_SPEC_VAR_TMP_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3336: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_VAR_TMP: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17058,17 +17042,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_TMP(incdec_t ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3361: /*ZEND_POST_INC_OBJ_SPEC_VAR_TMP_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3386: /*ZEND_POST_DEC_OBJ_SPEC_VAR_TMP_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2036: /*ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17098,7 +17082,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2111: /*ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17132,7 +17116,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2186: /*ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17154,7 +17138,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2261: /*ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17169,7 +17153,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2336: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17199,7 +17183,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2411: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17240,7 +17224,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_ } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_VAR_TMP: { USE_OPLINE zend_free_op free_op1; @@ -17283,12 +17267,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2061: /*ZEND_FETCH_OBJ_R_SPEC_VAR_TMP_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2136: /*ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17337,7 +17321,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2211: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17368,7 +17352,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2286: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -17410,7 +17394,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2361: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE @@ -17443,11 +17427,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCO CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_TMP; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2436: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -17490,7 +17474,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3411: /*ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17520,7 +17504,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3686: /*ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -17601,7 +17585,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 961: /*ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_TMP_LABEL: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17656,7 +17640,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2811: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -17730,7 +17714,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2836: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -17848,7 +17832,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1211: /*ZEND_CASE_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17866,7 +17850,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1811: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -17910,18 +17894,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCOD switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_VAR_TMP; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_VAR_TMP: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -17952,7 +17936,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1786: /*ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE @@ -17961,12 +17945,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1886: /*ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18004,7 +17988,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -18020,7 +18004,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_VAR_TMP: zend_hash_index_del(ht, hval); if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -18066,7 +18050,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1911: /*ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18107,7 +18091,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18131,12 +18115,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(in switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_VAR_TMP; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_VAR_TMP: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -18146,7 +18130,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(in hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_TMP); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -18251,17 +18235,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(in ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2886: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_TMP_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3711: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4011: /*ZEND_YIELD_SPEC_VAR_TMP_HANDLER*/ { USE_OPLINE @@ -18417,7 +18401,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 37: /*ZEND_ADD_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18432,7 +18416,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 62: /*ZEND_SUB_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18447,7 +18431,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 87: /*ZEND_MUL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18462,7 +18446,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 112: /*ZEND_DIV_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18477,7 +18461,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 137: /*ZEND_MOD_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18492,7 +18476,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 162: /*ZEND_SL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18507,7 +18491,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 187: /*ZEND_SR_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18522,7 +18506,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 212: /*ZEND_CONCAT_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18537,7 +18521,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 387: /*ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18552,7 +18536,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 412: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18569,7 +18553,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 437: /*ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18585,7 +18569,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 462: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18601,7 +18585,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 487: /*ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18617,7 +18601,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 512: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18633,7 +18617,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 237: /*ZEND_BW_OR_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18648,7 +18632,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 262: /*ZEND_BW_AND_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18663,7 +18647,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 287: /*ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18678,7 +18662,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18693,7 +18677,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data1; @@ -18805,7 +18789,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(int (*bin ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data2, free_op_data1; @@ -18815,7 +18799,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_VAR; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -18826,7 +18810,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_VAR; } else { zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -18895,62 +18879,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 587: /*ZEND_ASSIGN_ADD_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 612: /*ZEND_ASSIGN_SUB_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 637: /*ZEND_ASSIGN_MUL_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 662: /*ZEND_ASSIGN_DIV_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 687: /*ZEND_ASSIGN_MOD_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 712: /*ZEND_ASSIGN_SL_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 737: /*ZEND_ASSIGN_SR_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 762: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 787: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 812: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 837: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_VAR(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19044,17 +19028,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_VAR(incdec_t i ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3312: /*ZEND_PRE_INC_OBJ_SPEC_VAR_VAR_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3337: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19146,17 +19130,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_VAR(incdec_t ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3362: /*ZEND_POST_INC_OBJ_SPEC_VAR_VAR_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3387: /*ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1; @@ -19288,39 +19272,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_VAR(int type, ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2012: /*ZEND_FETCH_R_SPEC_VAR_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2087: /*ZEND_FETCH_W_SPEC_VAR_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2162: /*ZEND_FETCH_RW_SPEC_VAR_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2312: /*ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_VAR_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2387: /*ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2237: /*ZEND_FETCH_IS_SPEC_VAR_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2037: /*ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19350,7 +19334,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2112: /*ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19384,7 +19368,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2187: /*ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19406,7 +19390,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2262: /*ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19421,7 +19405,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2337: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19451,7 +19435,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2412: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19492,7 +19476,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_ } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1; @@ -19535,12 +19519,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2062: /*ZEND_FETCH_OBJ_R_SPEC_VAR_VAR_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2137: /*ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19589,7 +19573,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2212: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19620,7 +19604,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2287: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -19662,7 +19646,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2362: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE @@ -19695,11 +19679,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCO CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_VAR; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2437: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -19742,7 +19726,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3412: /*ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19772,7 +19756,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3687: /*ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -19853,7 +19837,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 962: /*ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_VAR_LABEL: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19909,7 +19893,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 987: /*ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19932,7 +19916,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; HANDLE_EXCEPTION(); } - return ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ASSIGN_SPEC_VAR_VAR_LABEL; } else if (IS_VAR == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -19963,7 +19947,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2812: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -20037,7 +20021,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2837: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -20155,7 +20139,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1212: /*ZEND_CASE_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20173,7 +20157,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1812: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -20217,18 +20201,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_VAR_VAR; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_VAR_VAR: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -20259,7 +20243,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1787: /*ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE @@ -20268,12 +20252,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1862: /*ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -20349,7 +20333,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1887: /*ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20387,7 +20371,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -20403,7 +20387,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_VAR_VAR: zend_hash_index_del(ht, hval); if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -20449,7 +20433,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1912: /*ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20490,7 +20474,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2862: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE zval **value; @@ -20575,7 +20559,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR: { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20599,12 +20583,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(in switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_VAR_VAR; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_VAR_VAR: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -20614,7 +20598,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(in hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_VAR); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -20719,17 +20703,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(in ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2887: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_VAR_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3712: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ { USE_OPLINE @@ -20886,7 +20870,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED: { USE_OPLINE zend_free_op free_op1, free_op_data1; @@ -20998,7 +20982,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(int (* ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_VAR_UNUSED: { USE_OPLINE zend_free_op free_op1, free_op_data2, free_op_data1; @@ -21008,7 +20992,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*bina SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -21019,7 +21003,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*bina if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED; } else { zval *dim = NULL; @@ -21087,62 +21071,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*bina ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 588: /*ZEND_ASSIGN_ADD_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 613: /*ZEND_ASSIGN_SUB_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 638: /*ZEND_ASSIGN_MUL_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 663: /*ZEND_ASSIGN_DIV_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 688: /*ZEND_ASSIGN_MOD_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 713: /*ZEND_ASSIGN_SL_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 738: /*ZEND_ASSIGN_SR_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 763: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 788: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 813: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 838: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_VAR_UNUSED: { USE_OPLINE zend_free_op free_op1; @@ -21274,39 +21258,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_UNUSED(int type, ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2013: /*ZEND_FETCH_R_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2088: /*ZEND_FETCH_W_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2163: /*ZEND_FETCH_RW_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2313: /*ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2388: /*ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2238: /*ZEND_FETCH_IS_SPEC_VAR_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2113: /*ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -21340,7 +21324,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2188: /*ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -21362,7 +21346,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2338: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -21392,7 +21376,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3688: /*ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -21472,7 +21456,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2838: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zval *function_name; @@ -21590,7 +21574,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(Z ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1813: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -21634,18 +21618,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OP switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_VAR_UNUSED; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_VAR_UNUSED: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_UNUSED); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -21676,7 +21660,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1788: /*ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE @@ -21685,12 +21669,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1863: /*ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -21766,7 +21750,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2863: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zval **value; @@ -21851,7 +21835,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3913: /*ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE zval *var_ptr, *new_zv; @@ -21872,7 +21856,7 @@ static int ZEND_FASTCALL ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4013: /*ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER*/ { USE_OPLINE @@ -22028,7 +22012,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 39: /*ZEND_ADD_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22043,7 +22027,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 64: /*ZEND_SUB_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22058,7 +22042,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 89: /*ZEND_MUL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22073,7 +22057,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 114: /*ZEND_DIV_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22088,7 +22072,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 139: /*ZEND_MOD_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22103,7 +22087,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 164: /*ZEND_SL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22118,7 +22102,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 189: /*ZEND_SR_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22133,7 +22117,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 214: /*ZEND_CONCAT_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22148,7 +22132,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 389: /*ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22163,7 +22147,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 414: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22180,7 +22164,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 439: /*ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22196,7 +22180,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 464: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22212,7 +22196,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 489: /*ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22228,7 +22212,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 514: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22244,7 +22228,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 239: /*ZEND_BW_OR_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22259,7 +22243,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 264: /*ZEND_BW_AND_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22274,7 +22258,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 289: /*ZEND_BW_XOR_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22289,7 +22273,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22304,7 +22288,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_VAR_CV: { USE_OPLINE zend_free_op free_op1, free_op_data1; @@ -22416,7 +22400,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CV(int (*bina ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_VAR_CV: { USE_OPLINE zend_free_op free_op1, free_op_data2, free_op_data1; @@ -22426,7 +22410,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_o SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CV; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -22437,7 +22421,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_o if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CV; } else { zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); @@ -22505,62 +22489,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_o ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 589: /*ZEND_ASSIGN_ADD_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 614: /*ZEND_ASSIGN_SUB_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 639: /*ZEND_ASSIGN_MUL_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 664: /*ZEND_ASSIGN_DIV_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 689: /*ZEND_ASSIGN_MOD_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 714: /*ZEND_ASSIGN_SL_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 739: /*ZEND_ASSIGN_SR_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 764: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 789: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 814: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 839: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_VAR_CV(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_VAR_CV: { USE_OPLINE zend_free_op free_op1; @@ -22654,17 +22638,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CV(incdec_t in ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3314: /*ZEND_PRE_INC_OBJ_SPEC_VAR_CV_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3339: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_VAR_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_VAR_CV: { USE_OPLINE zend_free_op free_op1; @@ -22756,17 +22740,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CV(incdec_t i ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3364: /*ZEND_POST_INC_OBJ_SPEC_VAR_CV_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3389: /*ZEND_POST_DEC_OBJ_SPEC_VAR_CV_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_VAR_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2039: /*ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22796,7 +22780,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2114: /*ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22830,7 +22814,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2189: /*ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22852,7 +22836,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2264: /*ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22867,7 +22851,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2339: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22897,7 +22881,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2414: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -22938,7 +22922,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_H } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_VAR_CV: { USE_OPLINE zend_free_op free_op1; @@ -22981,12 +22965,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2064: /*ZEND_FETCH_OBJ_R_SPEC_VAR_CV_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2139: /*ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23035,7 +23019,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2214: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23066,7 +23050,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2289: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23108,7 +23092,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2364: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE @@ -23141,11 +23125,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCOD CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_VAR_CV; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2439: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_res; @@ -23188,7 +23172,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3414: /*ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23218,7 +23202,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3689: /*ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23298,7 +23282,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 964: /*ZEND_ASSIGN_SPEC_VAR_CV_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_CV_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -23353,7 +23337,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 989: /*ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -23376,7 +23360,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE HANDLE_EXCEPTION(); } - return ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ASSIGN_SPEC_VAR_CV_LABEL; } else if (IS_CV == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -23406,7 +23390,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2814: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -23479,7 +23463,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2839: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -23597,7 +23581,7 @@ static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1214: /*ZEND_CASE_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23614,7 +23598,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1814: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_LABEL: { USE_OPLINE zend_free_op free_op1; @@ -23658,18 +23642,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_VAR_CV; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_VAR_CV: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -23700,7 +23684,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1789: /*ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE @@ -23709,12 +23693,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1889: /*ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23752,7 +23736,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -23768,7 +23752,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_VAR_CV: zend_hash_index_del(ht, hval); if (IS_CV == IS_CV || IS_CV == IS_VAR) { zval_ptr_dtor(&offset); @@ -23814,7 +23798,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1914: /*ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -23855,7 +23839,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV: { USE_OPLINE zend_free_op free_op1; @@ -23879,12 +23863,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_VAR_CV; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_VAR_CV: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -23894,7 +23878,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_CV); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -23999,17 +23983,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2889: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CV_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3714: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4014: /*ZEND_YIELD_SPEC_VAR_CV_HANDLER*/ { USE_OPLINE @@ -24165,7 +24149,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_CLONE_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2765: /*ZEND_CLONE_SPEC_UNUSED_HANDLER*/ { USE_OPLINE @@ -24228,7 +24212,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_EXIT_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ { #if 0 || (IS_UNUSED != IS_UNUSED) USE_OPLINE @@ -24250,7 +24234,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST: { USE_OPLINE zend_free_op free_op_data1; @@ -24361,7 +24345,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(int ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_UNUSED_CONST: { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -24371,7 +24355,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CONST(int (*bi SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST; break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -24382,7 +24366,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CONST(int (*bi if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST; } else { zval *dim = opline->op2.zv; @@ -24450,62 +24434,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CONST(int (*bi ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 590: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 615: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 640: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 665: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 690: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 715: /*ZEND_ASSIGN_SL_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 740: /*ZEND_ASSIGN_SR_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 765: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 790: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 815: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 840: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_UNUSED_CONST: { USE_OPLINE @@ -24599,17 +24583,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(incde ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3315: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3340: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_UNUSED_CONST: { USE_OPLINE @@ -24701,17 +24685,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CONST(incd ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3365: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3390: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST: { USE_OPLINE @@ -24753,12 +24737,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CON ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2065: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2140: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -24806,7 +24790,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2215: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -24837,7 +24821,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2290: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -24878,7 +24862,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2365: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -24911,11 +24895,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER(ZEND CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2440: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_res; @@ -24957,7 +24941,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3415: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -24987,7 +24971,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1365: /*ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -25010,7 +24994,7 @@ static int ZEND_FASTCALL ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1390: /*ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -25033,7 +25017,7 @@ static int ZEND_FASTCALL ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2815: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -25105,7 +25089,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER(ZEND_O ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2490: /*ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -25197,7 +25181,7 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPC } } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1790: /*ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -25206,12 +25190,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CONST_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1890: /*ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -25249,7 +25233,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_H if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -25265,7 +25249,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_H zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_UNUSED_CONST: zend_hash_index_del(ht, hval); if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { zval_ptr_dtor(&offset); @@ -25310,7 +25294,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1915: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -25350,7 +25334,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST: { USE_OPLINE @@ -25374,12 +25358,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CON switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_UNUSED_CONST; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_UNUSED_CONST: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -25389,7 +25373,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CON hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_CONST); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -25492,17 +25476,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CON ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2890: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3715: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CONST_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ { USE_OPLINE @@ -25656,7 +25640,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP: { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -25767,7 +25751,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(int (* ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_UNUSED_TMP: { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -25777,7 +25761,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_TMP(int (*bina SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP; break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -25788,7 +25772,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_TMP(int (*bina if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP; } else { zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -25857,62 +25841,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_TMP(int (*bina ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 591: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 616: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 641: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 666: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 691: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 716: /*ZEND_ASSIGN_SL_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 741: /*ZEND_ASSIGN_SR_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 766: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 791: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 816: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 841: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_UNUSED_TMP: { USE_OPLINE zend_free_op free_op2; @@ -26006,17 +25990,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(incdec_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3316: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3341: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_UNUSED_TMP: { USE_OPLINE zend_free_op free_op2; @@ -26108,17 +26092,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_TMP(incdec ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3366: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3391: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP: { USE_OPLINE @@ -26160,12 +26144,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2066: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2141: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -26213,7 +26197,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2216: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -26244,7 +26228,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2291: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE @@ -26285,7 +26269,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2366: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE @@ -26318,11 +26302,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER(ZEND_O CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2441: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -26364,7 +26348,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3416: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -26394,7 +26378,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1416: /*ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -26439,7 +26423,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2816: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -26512,7 +26496,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1791: /*ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE @@ -26521,12 +26505,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_TMP_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1891: /*ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -26564,7 +26548,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -26580,7 +26564,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_UNUSED_TMP: zend_hash_index_del(ht, hval); if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -26625,7 +26609,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1916: /*ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -26665,7 +26649,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP: { USE_OPLINE zend_free_op free_op2; @@ -26689,12 +26673,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_UNUSED_TMP; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_UNUSED_TMP: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -26704,7 +26688,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_TMP); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -26807,17 +26791,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2891: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3716: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_TMP_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ { USE_OPLINE @@ -26971,7 +26955,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR: { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -27082,7 +27066,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(int (* ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_UNUSED_VAR: { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -27092,7 +27076,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_VAR(int (*bina SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR; break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -27103,7 +27087,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_VAR(int (*bina if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR; } else { zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -27172,62 +27156,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_VAR(int (*bina ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 592: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 617: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 642: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 667: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 692: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 717: /*ZEND_ASSIGN_SL_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 742: /*ZEND_ASSIGN_SR_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 767: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 792: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 817: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 842: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_UNUSED_VAR: { USE_OPLINE zend_free_op free_op2; @@ -27321,17 +27305,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(incdec_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3317: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3342: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_UNUSED_VAR: { USE_OPLINE zend_free_op free_op2; @@ -27423,17 +27407,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_VAR(incdec ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3367: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3392: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR: { USE_OPLINE @@ -27475,12 +27459,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2067: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2142: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -27528,7 +27512,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2217: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -27559,7 +27543,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2292: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE @@ -27600,7 +27584,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2367: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE @@ -27633,11 +27617,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER(ZEND_O CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2442: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -27679,7 +27663,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3417: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -27709,7 +27693,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1417: /*ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -27754,7 +27738,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2817: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -27827,7 +27811,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1792: /*ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE @@ -27836,12 +27820,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_VAR_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1892: /*ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -27879,7 +27863,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -27895,7 +27879,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_UNUSED_VAR: zend_hash_index_del(ht, hval); if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -27940,7 +27924,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1917: /*ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -27980,7 +27964,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR: { USE_OPLINE zend_free_op free_op2; @@ -28004,12 +27988,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_UNUSED_VAR; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_UNUSED_VAR: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -28019,7 +28003,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_VAR); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -28122,17 +28106,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2892: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3717: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_VAR_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ { USE_OPLINE @@ -28287,7 +28271,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED: { USE_OPLINE zend_free_op free_op_data1; @@ -28398,7 +28382,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(int ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED: { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -28408,7 +28392,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(int (*b SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED; break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -28419,7 +28403,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(int (*b if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED; } else { zval *dim = NULL; @@ -28487,62 +28471,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(int (*b ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 593: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 618: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 643: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 668: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 693: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 718: /*ZEND_ASSIGN_SL_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 743: /*ZEND_ASSIGN_SR_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 768: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 793: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 818: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 843: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1793: /*ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER*/ { USE_OPLINE @@ -28551,12 +28535,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_UNUSED_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ { USE_OPLINE @@ -28710,7 +28694,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV: { USE_OPLINE zend_free_op free_op_data1; @@ -28821,7 +28805,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(int (*b ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_UNUSED_CV: { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -28831,7 +28815,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CV(int (*binar SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV; break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -28842,7 +28826,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CV(int (*binar if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV; } else { zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); @@ -28910,62 +28894,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CV(int (*binar ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 594: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 619: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 644: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 669: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 694: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 719: /*ZEND_ASSIGN_SL_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 744: /*ZEND_ASSIGN_SR_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 769: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 794: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 819: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 844: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_UNUSED_CV(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_UNUSED_CV: { USE_OPLINE @@ -29059,17 +29043,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CV(incdec_t ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3319: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_CV_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3344: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_UNUSED_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_UNUSED_CV: { USE_OPLINE @@ -29161,17 +29145,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CV(incdec_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3369: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_CV_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3394: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_UNUSED_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CV(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_UNUSED_CV: { USE_OPLINE @@ -29213,12 +29197,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CV( ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2069: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_CV_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2144: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -29266,7 +29250,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2219: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -29297,7 +29281,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2294: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29338,7 +29322,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2369: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29371,11 +29355,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER(ZEND_OP CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_UNUSED_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CV; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2444: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_res; @@ -29417,7 +29401,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3419: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29447,7 +29431,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1419: /*ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29491,7 +29475,7 @@ static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2819: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -29563,7 +29547,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1794: /*ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29572,12 +29556,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CV_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1894: /*ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29615,7 +29599,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -29631,7 +29615,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_UNUSED_CV: zend_hash_index_del(ht, hval); if (IS_CV == IS_CV || IS_CV == IS_VAR) { zval_ptr_dtor(&offset); @@ -29676,7 +29660,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1919: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -29716,7 +29700,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV: { USE_OPLINE @@ -29740,12 +29724,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV( switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_UNUSED_CV; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_UNUSED_CV: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -29755,7 +29739,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV( hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_CV); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -29858,17 +29842,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV( ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2894: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CV_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3719: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CV_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4019: /*ZEND_YIELD_SPEC_UNUSED_CV_HANDLER*/ { USE_OPLINE @@ -30022,7 +30006,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 320: /*ZEND_BW_NOT_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30035,7 +30019,7 @@ static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 345: /*ZEND_BOOL_NOT_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30048,7 +30032,7 @@ static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 870: /*ZEND_PRE_INC_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30094,7 +30078,7 @@ static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 895: /*ZEND_PRE_DEC_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30140,7 +30124,7 @@ static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 920: /*ZEND_POST_INC_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30182,7 +30166,7 @@ static int ZEND_FASTCALL ZEND_POST_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 945: /*ZEND_POST_DEC_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30224,7 +30208,7 @@ static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1020: /*ZEND_ECHO_SPEC_CV_HANDLER*/ ZEND_ECHO_SPEC_CV_LABEL: { USE_OPLINE @@ -30254,15 +30238,15 @@ static int ZEND_FASTCALL ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRINT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1045: /*ZEND_PRINT_SPEC_CV_HANDLER*/ { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - return ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ECHO_SPEC_CV_LABEL; } -static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1095: /*ZEND_JMPZ_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30292,7 +30276,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1120: /*ZEND_JMPNZ_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30322,7 +30306,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1145: /*ZEND_JMPZNZ_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30356,7 +30340,7 @@ static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) } } -static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1170: /*ZEND_JMPZ_EX_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30387,7 +30371,7 @@ static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1195: /*ZEND_JMPNZ_EX_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30418,7 +30402,7 @@ static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1570: /*ZEND_RETURN_SPEC_CV_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -30465,10 +30449,10 @@ static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) *EG(return_value_ptr_ptr) = ret; } - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2795: /*ZEND_RETURN_BY_REF_SPEC_CV_HANDLER*/ { USE_OPLINE zval *retval_ptr; @@ -30536,10 +30520,10 @@ static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER } } while (0); - return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_leave_helper_SPEC; } -static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2720: /*ZEND_THROW_SPEC_CV_HANDLER*/ { USE_OPLINE zval *value; @@ -30566,7 +30550,7 @@ static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) HANDLE_EXCEPTION(); } -static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS) +zend_send_by_var_helper_SPEC_CV: { USE_OPLINE zval *varptr; @@ -30594,7 +30578,7 @@ static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2670: /*ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -30603,10 +30587,10 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL SAVE_OPLINE(); if (opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) { /* Had function_ptr at compile_time */ if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { - return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_CV; } } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_CV; } if (IS_CV == IS_VAR && @@ -30646,7 +30630,7 @@ static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1695: /*ZEND_SEND_REF_SPEC_CV_HANDLER*/ ZEND_SEND_REF_SPEC_CV_LABEL: { USE_OPLINE @@ -30668,7 +30652,7 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS } if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_CV; } SEPARATE_ZVAL_TO_MAKE_IS_REF(varptr_ptr); @@ -30680,19 +30664,19 @@ static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SEND_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1670: /*ZEND_SEND_VAR_SPEC_CV_HANDLER*/ { USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - return ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_SEND_REF_SPEC_CV_LABEL; } SAVE_OPLINE(); - return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_send_by_var_helper_SPEC_CV; } -static int ZEND_FASTCALL ZEND_BOOL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1320: /*ZEND_BOOL_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30706,7 +30690,7 @@ static int ZEND_FASTCALL ZEND_BOOL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CLONE_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2770: /*ZEND_CLONE_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30769,7 +30753,7 @@ static int ZEND_FASTCALL ZEND_CLONE_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CAST_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 545: /*ZEND_CAST_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -30828,7 +30812,7 @@ static int ZEND_FASTCALL ZEND_CAST_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1845: /*ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER*/ { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -30962,7 +30946,7 @@ static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1945: /*ZEND_FE_RESET_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -31104,7 +31088,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS } } -static int ZEND_FASTCALL ZEND_EXIT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1995: /*ZEND_EXIT_SPEC_CV_HANDLER*/ { #if 0 || (IS_CV != IS_UNUSED) USE_OPLINE @@ -31126,7 +31110,7 @@ static int ZEND_FASTCALL ZEND_EXIT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3820: /*ZEND_JMP_SET_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -31151,7 +31135,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3970: /*ZEND_JMP_SET_VAR_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -31185,7 +31169,7 @@ static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 570: /*ZEND_QM_ASSIGN_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -31203,7 +31187,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3945: /*ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -31230,7 +31214,7 @@ static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3470: /*ZEND_INSTANCEOF_SPEC_CV_HANDLER*/ { USE_OPLINE @@ -31251,7 +31235,7 @@ static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 45: /*ZEND_ADD_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31266,7 +31250,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 70: /*ZEND_SUB_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31281,7 +31265,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 95: /*ZEND_MUL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31296,7 +31280,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 120: /*ZEND_DIV_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31311,7 +31295,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 145: /*ZEND_MOD_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31326,7 +31310,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 170: /*ZEND_SL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31341,7 +31325,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 195: /*ZEND_SR_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31356,7 +31340,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 220: /*ZEND_CONCAT_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31371,7 +31355,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 395: /*ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31386,7 +31370,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 420: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31403,7 +31387,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 445: /*ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31419,7 +31403,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 470: /*ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31435,7 +31419,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 495: /*ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31451,7 +31435,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 520: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31467,7 +31451,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 245: /*ZEND_BW_OR_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31482,7 +31466,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 270: /*ZEND_BW_AND_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31497,7 +31481,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 295: /*ZEND_BW_XOR_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31512,7 +31496,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -31527,7 +31511,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_CV_CONST: { USE_OPLINE zend_free_op free_op_data1; @@ -31638,7 +31622,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CONST(int (*bi ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_CV_CONST: { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -31648,7 +31632,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_CV_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CONST; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -31659,7 +31643,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_CV_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CONST; } else { zval *dim = opline->op2.zv; @@ -31727,62 +31711,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 595: /*ZEND_ASSIGN_ADD_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 620: /*ZEND_ASSIGN_SUB_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 645: /*ZEND_ASSIGN_MUL_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 670: /*ZEND_ASSIGN_DIV_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 695: /*ZEND_ASSIGN_MOD_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 720: /*ZEND_ASSIGN_SL_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 745: /*ZEND_ASSIGN_SR_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 770: /*ZEND_ASSIGN_CONCAT_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 795: /*ZEND_ASSIGN_BW_OR_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 820: /*ZEND_ASSIGN_BW_AND_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 845: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CONST(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_CV_CONST: { USE_OPLINE @@ -31876,17 +31860,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CONST(incdec_t ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3320: /*ZEND_PRE_INC_OBJ_SPEC_CV_CONST_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3345: /*ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_CV_CONST: { USE_OPLINE @@ -31978,17 +31962,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CONST(incdec_t ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3370: /*ZEND_POST_INC_OBJ_SPEC_CV_CONST_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3395: /*ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_CV_CONST: { USE_OPLINE zend_free_op free_op1; @@ -32120,39 +32104,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_CONST(int type, Z ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2020: /*ZEND_FETCH_R_SPEC_CV_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2095: /*ZEND_FETCH_W_SPEC_CV_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2170: /*ZEND_FETCH_RW_SPEC_CV_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2320: /*ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CV_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2395: /*ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2245: /*ZEND_FETCH_IS_SPEC_CV_CONST_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2045: /*ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32182,7 +32166,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2120: /*ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -32215,7 +32199,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2195: /*ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -32237,7 +32221,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2270: /*ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32252,7 +32236,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2345: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -32282,7 +32266,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2420: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -32323,7 +32307,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CONST(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_CV_CONST: { USE_OPLINE @@ -32365,12 +32349,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CONST(Z ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2070: /*ZEND_FETCH_OBJ_R_SPEC_CV_CONST_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_CV_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2145: /*ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -32418,7 +32402,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2220: /*ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -32449,7 +32433,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2295: /*ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32490,7 +32474,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2370: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32523,11 +32507,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPC CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_CV_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_CONST; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2445: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_res; @@ -32569,7 +32553,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3420: /*ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32599,7 +32583,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3695: /*ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32679,7 +32663,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 970: /*ZEND_ASSIGN_SPEC_CV_CONST_HANDLER*/ ZEND_ASSIGN_SPEC_CV_CONST_LABEL: { USE_OPLINE @@ -32732,7 +32716,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2820: /*ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zval *function_name; @@ -32804,7 +32788,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1220: /*ZEND_CASE_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32821,7 +32805,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1820: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_LABEL: { USE_OPLINE @@ -32865,18 +32849,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCO switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CV_CONST; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CV_CONST: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -32907,7 +32891,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1795: /*ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -32916,12 +32900,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1870: /*ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -32997,7 +32981,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1895: /*ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -33035,7 +33019,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_CONST); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -33051,7 +33035,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_CV_CONST: zend_hash_index_del(ht, hval); if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { zval_ptr_dtor(&offset); @@ -33096,7 +33080,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1920: /*ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -33136,7 +33120,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2870: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE zval **value; @@ -33221,7 +33205,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST: { USE_OPLINE @@ -33245,12 +33229,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(i switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_CV_CONST; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_CV_CONST: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -33260,7 +33244,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(i hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_CONST); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -33363,17 +33347,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(i ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2895: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CONST_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3720: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CONST_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4020: /*ZEND_YIELD_SPEC_CV_CONST_HANDLER*/ { USE_OPLINE @@ -33527,7 +33511,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 46: /*ZEND_ADD_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33542,7 +33526,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 71: /*ZEND_SUB_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33557,7 +33541,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 96: /*ZEND_MUL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33572,7 +33556,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 121: /*ZEND_DIV_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33587,7 +33571,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 146: /*ZEND_MOD_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33602,7 +33586,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 171: /*ZEND_SL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33617,7 +33601,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 196: /*ZEND_SR_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33632,7 +33616,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 221: /*ZEND_CONCAT_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33647,7 +33631,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 396: /*ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33662,7 +33646,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 421: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33679,7 +33663,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 446: /*ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33695,7 +33679,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 471: /*ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33711,7 +33695,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 496: /*ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33727,7 +33711,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 521: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33743,7 +33727,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 246: /*ZEND_BW_OR_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33758,7 +33742,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 271: /*ZEND_BW_AND_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33773,7 +33757,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 296: /*ZEND_BW_XOR_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33788,7 +33772,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -33803,7 +33787,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_CV_TMP: { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -33914,7 +33898,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_TMP(int (*bina ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_CV_TMP: { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -33924,7 +33908,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_o SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_CV_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_TMP; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -33935,7 +33919,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_o if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_CV_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_TMP; } else { zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -34004,62 +33988,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_o ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 596: /*ZEND_ASSIGN_ADD_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 621: /*ZEND_ASSIGN_SUB_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 646: /*ZEND_ASSIGN_MUL_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 671: /*ZEND_ASSIGN_DIV_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 696: /*ZEND_ASSIGN_MOD_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 721: /*ZEND_ASSIGN_SL_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 746: /*ZEND_ASSIGN_SR_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 771: /*ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 796: /*ZEND_ASSIGN_BW_OR_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 821: /*ZEND_ASSIGN_BW_AND_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 846: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_TMP(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_CV_TMP: { USE_OPLINE zend_free_op free_op2; @@ -34153,17 +34137,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_TMP(incdec_t in ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3321: /*ZEND_PRE_INC_OBJ_SPEC_CV_TMP_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3346: /*ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_CV_TMP: { USE_OPLINE zend_free_op free_op2; @@ -34255,17 +34239,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_TMP(incdec_t i ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3371: /*ZEND_POST_INC_OBJ_SPEC_CV_TMP_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3396: /*ZEND_POST_DEC_OBJ_SPEC_CV_TMP_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2046: /*ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -34295,7 +34279,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2121: /*ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34328,7 +34312,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2196: /*ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34350,7 +34334,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2271: /*ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -34365,7 +34349,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2346: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34395,7 +34379,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2421: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34436,7 +34420,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_H } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_CV_TMP: { USE_OPLINE @@ -34478,12 +34462,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2071: /*ZEND_FETCH_OBJ_R_SPEC_CV_TMP_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2146: /*ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34531,7 +34515,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2221: /*ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34562,7 +34546,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2296: /*ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE @@ -34603,7 +34587,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2371: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE @@ -34636,11 +34620,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCOD CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_TMP; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2446: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -34682,7 +34666,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3421: /*ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -34712,7 +34696,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3696: /*ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE @@ -34793,7 +34777,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 971: /*ZEND_ASSIGN_SPEC_CV_TMP_HANDLER*/ ZEND_ASSIGN_SPEC_CV_TMP_LABEL: { USE_OPLINE zend_free_op free_op2; @@ -34846,7 +34830,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2821: /*ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zval *function_name; @@ -34919,7 +34903,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1221: /*ZEND_CASE_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -34937,7 +34921,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1821: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_LABEL: { USE_OPLINE @@ -34981,18 +34965,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CV_TMP; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CV_TMP: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -35023,7 +35007,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1796: /*ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE @@ -35032,12 +35016,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1896: /*ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35075,7 +35059,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_TMP); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -35091,7 +35075,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_CV_TMP: zend_hash_index_del(ht, hval); if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -35136,7 +35120,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1921: /*ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35176,7 +35160,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP: { USE_OPLINE zend_free_op free_op2; @@ -35200,12 +35184,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_CV_TMP; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_CV_TMP: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -35215,7 +35199,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_TMP); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -35318,17 +35302,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2896: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_TMP_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3721: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_TMP_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4021: /*ZEND_YIELD_SPEC_CV_TMP_HANDLER*/ { USE_OPLINE @@ -35482,7 +35466,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 47: /*ZEND_ADD_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35497,7 +35481,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 72: /*ZEND_SUB_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35512,7 +35496,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 97: /*ZEND_MUL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35527,7 +35511,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 122: /*ZEND_DIV_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35542,7 +35526,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 147: /*ZEND_MOD_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35557,7 +35541,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 172: /*ZEND_SL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35572,7 +35556,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 197: /*ZEND_SR_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35587,7 +35571,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 222: /*ZEND_CONCAT_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35602,7 +35586,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 397: /*ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35617,7 +35601,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 422: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35634,7 +35618,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 447: /*ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35650,7 +35634,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 472: /*ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35666,7 +35650,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 497: /*ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35682,7 +35666,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 522: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35698,7 +35682,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCO ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 247: /*ZEND_BW_OR_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35713,7 +35697,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 272: /*ZEND_BW_AND_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35728,7 +35712,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 297: /*ZEND_BW_XOR_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35743,7 +35727,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -35758,7 +35742,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_CV_VAR: { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -35869,7 +35853,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_VAR(int (*bina ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_CV_VAR: { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -35879,7 +35863,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_o SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_CV_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_VAR; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -35890,7 +35874,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_o if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_CV_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_VAR; } else { zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -35959,62 +35943,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_o ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 597: /*ZEND_ASSIGN_ADD_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 622: /*ZEND_ASSIGN_SUB_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 647: /*ZEND_ASSIGN_MUL_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 672: /*ZEND_ASSIGN_DIV_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 697: /*ZEND_ASSIGN_MOD_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 722: /*ZEND_ASSIGN_SL_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 747: /*ZEND_ASSIGN_SR_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 772: /*ZEND_ASSIGN_CONCAT_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 797: /*ZEND_ASSIGN_BW_OR_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 822: /*ZEND_ASSIGN_BW_AND_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 847: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_VAR(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_CV_VAR: { USE_OPLINE zend_free_op free_op2; @@ -36108,17 +36092,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_VAR(incdec_t in ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3322: /*ZEND_PRE_INC_OBJ_SPEC_CV_VAR_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3347: /*ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_CV_VAR: { USE_OPLINE zend_free_op free_op2; @@ -36210,17 +36194,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_VAR(incdec_t i ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3372: /*ZEND_POST_INC_OBJ_SPEC_CV_VAR_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3397: /*ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_CV_VAR: { USE_OPLINE zend_free_op free_op1; @@ -36352,39 +36336,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_VAR(int type, ZEN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2022: /*ZEND_FETCH_R_SPEC_CV_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2097: /*ZEND_FETCH_W_SPEC_CV_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2172: /*ZEND_FETCH_RW_SPEC_CV_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2322: /*ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CV_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2397: /*ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2247: /*ZEND_FETCH_IS_SPEC_CV_VAR_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2047: /*ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -36414,7 +36398,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2122: /*ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36447,7 +36431,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2197: /*ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36469,7 +36453,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2272: /*ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -36484,7 +36468,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2347: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36514,7 +36498,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2422: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36555,7 +36539,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_H } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_CV_VAR: { USE_OPLINE @@ -36597,12 +36581,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2072: /*ZEND_FETCH_OBJ_R_SPEC_CV_VAR_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2147: /*ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36650,7 +36634,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2222: /*ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36681,7 +36665,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2297: /*ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE @@ -36722,7 +36706,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2372: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE @@ -36755,11 +36739,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCOD CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_VAR; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2447: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -36801,7 +36785,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3422: /*ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -36831,7 +36815,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3697: /*ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE @@ -36912,7 +36896,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 972: /*ZEND_ASSIGN_SPEC_CV_VAR_HANDLER*/ ZEND_ASSIGN_SPEC_CV_VAR_LABEL: { USE_OPLINE zend_free_op free_op2; @@ -36966,7 +36950,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 997: /*ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -36989,7 +36973,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; HANDLE_EXCEPTION(); } - return ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ASSIGN_SPEC_CV_VAR_LABEL; } else if (IS_VAR == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -37019,7 +37003,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2822: /*ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zval *function_name; @@ -37092,7 +37076,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1222: /*ZEND_CASE_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -37110,7 +37094,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1822: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_LABEL: { USE_OPLINE @@ -37154,18 +37138,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CV_VAR; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CV_VAR: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -37196,7 +37180,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1797: /*ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE @@ -37205,12 +37189,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1872: /*ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -37286,7 +37270,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1897: /*ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -37324,7 +37308,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_VAR); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -37340,7 +37324,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_CV_VAR: zend_hash_index_del(ht, hval); if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -37385,7 +37369,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1922: /*ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -37425,7 +37409,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2872: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE zval **value; @@ -37510,7 +37494,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR: { USE_OPLINE zend_free_op free_op2; @@ -37534,12 +37518,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_CV_VAR; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_CV_VAR: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -37549,7 +37533,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_VAR); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -37652,17 +37636,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2897: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_VAR_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3722: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_VAR_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ { USE_OPLINE @@ -37817,7 +37801,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_RETURN(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED: { USE_OPLINE zend_free_op free_op_data1; @@ -37928,7 +37912,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(int (*b ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_CV_UNUSED: { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -37938,7 +37922,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binar SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -37949,7 +37933,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binar if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED; } else { zval *dim = NULL; @@ -38017,62 +38001,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binar ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 598: /*ZEND_ASSIGN_ADD_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 623: /*ZEND_ASSIGN_SUB_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 648: /*ZEND_ASSIGN_MUL_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 673: /*ZEND_ASSIGN_DIV_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 698: /*ZEND_ASSIGN_MOD_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 723: /*ZEND_ASSIGN_SL_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 748: /*ZEND_ASSIGN_SR_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 773: /*ZEND_ASSIGN_CONCAT_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 798: /*ZEND_ASSIGN_BW_OR_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 823: /*ZEND_ASSIGN_BW_AND_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 848: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_UNUSED(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_var_address_helper_SPEC_CV_UNUSED: { USE_OPLINE zend_free_op free_op1; @@ -38204,39 +38188,39 @@ static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_UNUSED(int type, ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2023: /*ZEND_FETCH_R_SPEC_CV_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2098: /*ZEND_FETCH_W_SPEC_CV_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2173: /*ZEND_FETCH_RW_SPEC_CV_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2323: /*ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2398: /*ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2248: /*ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER*/ { - return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2123: /*ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -38269,7 +38253,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2198: /*ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -38291,7 +38275,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2348: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -38321,7 +38305,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OP ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3698: /*ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE @@ -38401,7 +38385,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1823: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_LABEL: { USE_OPLINE @@ -38445,18 +38429,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPC switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CV_UNUSED; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CV_UNUSED: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_UNUSED); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -38487,7 +38471,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1798: /*ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE @@ -38496,12 +38480,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAN ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1873: /*ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE zval tmp, *varname; @@ -38577,7 +38561,7 @@ static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HAND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2873: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE zval **value; @@ -38662,7 +38646,7 @@ static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPC ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4023: /*ZEND_YIELD_SPEC_CV_UNUSED_HANDLER*/ { USE_OPLINE @@ -38816,7 +38800,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 49: /*ZEND_ADD_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38831,7 +38815,7 @@ static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 74: /*ZEND_SUB_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38846,7 +38830,7 @@ static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 99: /*ZEND_MUL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38861,7 +38845,7 @@ static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 124: /*ZEND_DIV_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38876,7 +38860,7 @@ static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 149: /*ZEND_MOD_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38891,7 +38875,7 @@ static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 174: /*ZEND_SL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38906,7 +38890,7 @@ static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 199: /*ZEND_SR_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38921,7 +38905,7 @@ static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 224: /*ZEND_CONCAT_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38936,7 +38920,7 @@ static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 399: /*ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38951,7 +38935,7 @@ static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 424: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38968,7 +38952,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 449: /*ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -38984,7 +38968,7 @@ static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 474: /*ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39000,7 +38984,7 @@ static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 499: /*ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39016,7 +39000,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 524: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39032,7 +39016,7 @@ static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCOD ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 249: /*ZEND_BW_OR_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39047,7 +39031,7 @@ static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 274: /*ZEND_BW_AND_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39062,7 +39046,7 @@ static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 299: /*ZEND_BW_XOR_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39077,7 +39061,7 @@ static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39092,7 +39076,7 @@ static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_A ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_obj_helper_SPEC_CV_CV: { USE_OPLINE zend_free_op free_op_data1; @@ -39203,7 +39187,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CV(int (*binar ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) +zend_binary_assign_op_helper_SPEC_CV_CV: { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -39213,7 +39197,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - return zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CV; break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -39224,7 +39208,7 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - return zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CV; } else { zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); @@ -39292,62 +39276,62 @@ static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 599: /*ZEND_ASSIGN_ADD_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 624: /*ZEND_ASSIGN_SUB_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 649: /*ZEND_ASSIGN_MUL_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 674: /*ZEND_ASSIGN_DIV_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 699: /*ZEND_ASSIGN_MOD_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 724: /*ZEND_ASSIGN_SL_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 749: /*ZEND_ASSIGN_SR_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 774: /*ZEND_ASSIGN_CONCAT_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 799: /*ZEND_ASSIGN_BW_OR_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 824: /*ZEND_ASSIGN_BW_AND_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 849: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER*/ { - return zend_binary_assign_op_helper_SPEC_CV_CV(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_pre_incdec_property_helper_SPEC_CV_CV: { USE_OPLINE @@ -39441,17 +39425,17 @@ static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CV(incdec_t inc ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3324: /*ZEND_PRE_INC_OBJ_SPEC_CV_CV_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3349: /*ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER*/ { - return zend_pre_incdec_property_helper_SPEC_CV_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) +zend_post_incdec_property_helper_SPEC_CV_CV: { USE_OPLINE @@ -39543,17 +39527,17 @@ static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CV(incdec_t in ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3374: /*ZEND_POST_INC_OBJ_SPEC_CV_CV_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3399: /*ZEND_POST_DEC_OBJ_SPEC_CV_CV_HANDLER*/ { - return zend_post_incdec_property_helper_SPEC_CV_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2049: /*ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39583,7 +39567,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2124: /*ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -39616,7 +39600,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2199: /*ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -39638,7 +39622,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2274: /*ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39653,7 +39637,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2349: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -39683,7 +39667,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2424: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -39724,7 +39708,7 @@ static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HA } } -static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND_OPCODE_HANDLER_ARGS) +zend_fetch_property_address_read_helper_SPEC_CV_CV: { USE_OPLINE @@ -39766,12 +39750,12 @@ static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2074: /*ZEND_FETCH_OBJ_R_SPEC_CV_CV_HANDLER*/ { - return zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2149: /*ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -39819,7 +39803,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLE ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2224: /*ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1; @@ -39850,7 +39834,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2299: /*ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39891,7 +39875,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDL ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2374: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -39924,11 +39908,11 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - return zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto zend_fetch_property_address_read_helper_SPEC_CV_CV; } } -static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2449: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op1, free_res; @@ -39970,7 +39954,7 @@ static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HA ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3424: /*ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40000,7 +39984,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3699: /*ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40080,7 +40064,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 974: /*ZEND_ASSIGN_SPEC_CV_CV_HANDLER*/ ZEND_ASSIGN_SPEC_CV_CV_LABEL: { USE_OPLINE @@ -40133,7 +40117,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 999: /*ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zend_free_op free_op2; @@ -40156,7 +40140,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER HANDLE_EXCEPTION(); } - return ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ASSIGN_SPEC_CV_CV_LABEL; } else if (IS_CV == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -40185,7 +40169,7 @@ static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2824: /*ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER*/ { USE_OPLINE zval *function_name; @@ -40257,7 +40241,7 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1224: /*ZEND_CASE_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40274,7 +40258,7 @@ static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1824: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_LABEL: { USE_OPLINE @@ -40318,18 +40302,18 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index; + goto num_index_SPEC_CV_CV; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index: +num_index_SPEC_CV_CV: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -40360,7 +40344,7 @@ static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1799: /*ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40369,12 +40353,12 @@ static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_LABEL; #endif } } -static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1899: /*ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40412,7 +40396,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_CV); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -40428,7 +40412,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ zval_ptr_dtor(&offset); } break; -num_index_dim: +num_index_dim_SPEC_CV_CV: zend_hash_index_del(ht, hval); if (IS_CV == IS_CV || IS_CV == IS_VAR) { zval_ptr_dtor(&offset); @@ -40473,7 +40457,7 @@ static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 1924: /*ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40513,7 +40497,7 @@ static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) +zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV: { USE_OPLINE @@ -40537,12 +40521,12 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop; + goto num_index_prop_SPEC_CV_CV; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop: +num_index_prop_SPEC_CV_CV: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -40552,7 +40536,7 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_CV); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -40655,17 +40639,17 @@ static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int ZEND_VM_NEXT_OPCODE(); } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 2899: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CV_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 3724: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CV_HANDLER*/ { - return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV; } -static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +case 4024: /*ZEND_YIELD_SPEC_CV_CV_HANDLER*/ { USE_OPLINE @@ -40819,4117 +40803,4128 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS ZEND_VM_RETURN(); } -static int ZEND_FASTCALL ZEND_NULL_HANDLER(ZEND_OPCODE_HANDLER_ARGS) -{ +default: zend_error_noreturn(E_ERROR, "Invalid opcode %d/%d/%d.", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type); ZEND_VM_NEXT_OPCODE(); /* Never reached */ + } + + } + zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); +} + +ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) +{ + if (EG(exception)) { + return; + } + zend_execute_ex(i_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } void zend_init_opcodes_handlers(void) { static const opcode_handler_t labels[] = { - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_NOP_SPEC_HANDLER, - ZEND_ADD_SPEC_CONST_CONST_HANDLER, - ZEND_ADD_SPEC_CONST_TMP_HANDLER, - ZEND_ADD_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_SPEC_CONST_CV_HANDLER, - ZEND_ADD_SPEC_TMP_CONST_HANDLER, - ZEND_ADD_SPEC_TMP_TMP_HANDLER, - ZEND_ADD_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_SPEC_TMP_CV_HANDLER, - ZEND_ADD_SPEC_VAR_CONST_HANDLER, - ZEND_ADD_SPEC_VAR_TMP_HANDLER, - ZEND_ADD_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_SPEC_CV_CONST_HANDLER, - ZEND_ADD_SPEC_CV_TMP_HANDLER, - ZEND_ADD_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_SPEC_CV_CV_HANDLER, - ZEND_SUB_SPEC_CONST_CONST_HANDLER, - ZEND_SUB_SPEC_CONST_TMP_HANDLER, - ZEND_SUB_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SUB_SPEC_CONST_CV_HANDLER, - ZEND_SUB_SPEC_TMP_CONST_HANDLER, - ZEND_SUB_SPEC_TMP_TMP_HANDLER, - ZEND_SUB_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SUB_SPEC_TMP_CV_HANDLER, - ZEND_SUB_SPEC_VAR_CONST_HANDLER, - ZEND_SUB_SPEC_VAR_TMP_HANDLER, - ZEND_SUB_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SUB_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SUB_SPEC_CV_CONST_HANDLER, - ZEND_SUB_SPEC_CV_TMP_HANDLER, - ZEND_SUB_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SUB_SPEC_CV_CV_HANDLER, - ZEND_MUL_SPEC_CONST_CONST_HANDLER, - ZEND_MUL_SPEC_CONST_TMP_HANDLER, - ZEND_MUL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MUL_SPEC_CONST_CV_HANDLER, - ZEND_MUL_SPEC_TMP_CONST_HANDLER, - ZEND_MUL_SPEC_TMP_TMP_HANDLER, - ZEND_MUL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MUL_SPEC_TMP_CV_HANDLER, - ZEND_MUL_SPEC_VAR_CONST_HANDLER, - ZEND_MUL_SPEC_VAR_TMP_HANDLER, - ZEND_MUL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MUL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MUL_SPEC_CV_CONST_HANDLER, - ZEND_MUL_SPEC_CV_TMP_HANDLER, - ZEND_MUL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MUL_SPEC_CV_CV_HANDLER, - ZEND_DIV_SPEC_CONST_CONST_HANDLER, - ZEND_DIV_SPEC_CONST_TMP_HANDLER, - ZEND_DIV_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DIV_SPEC_CONST_CV_HANDLER, - ZEND_DIV_SPEC_TMP_CONST_HANDLER, - ZEND_DIV_SPEC_TMP_TMP_HANDLER, - ZEND_DIV_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DIV_SPEC_TMP_CV_HANDLER, - ZEND_DIV_SPEC_VAR_CONST_HANDLER, - ZEND_DIV_SPEC_VAR_TMP_HANDLER, - ZEND_DIV_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DIV_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DIV_SPEC_CV_CONST_HANDLER, - ZEND_DIV_SPEC_CV_TMP_HANDLER, - ZEND_DIV_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DIV_SPEC_CV_CV_HANDLER, - ZEND_MOD_SPEC_CONST_CONST_HANDLER, - ZEND_MOD_SPEC_CONST_TMP_HANDLER, - ZEND_MOD_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MOD_SPEC_CONST_CV_HANDLER, - ZEND_MOD_SPEC_TMP_CONST_HANDLER, - ZEND_MOD_SPEC_TMP_TMP_HANDLER, - ZEND_MOD_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MOD_SPEC_TMP_CV_HANDLER, - ZEND_MOD_SPEC_VAR_CONST_HANDLER, - ZEND_MOD_SPEC_VAR_TMP_HANDLER, - ZEND_MOD_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MOD_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MOD_SPEC_CV_CONST_HANDLER, - ZEND_MOD_SPEC_CV_TMP_HANDLER, - ZEND_MOD_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_MOD_SPEC_CV_CV_HANDLER, - ZEND_SL_SPEC_CONST_CONST_HANDLER, - ZEND_SL_SPEC_CONST_TMP_HANDLER, - ZEND_SL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SL_SPEC_CONST_CV_HANDLER, - ZEND_SL_SPEC_TMP_CONST_HANDLER, - ZEND_SL_SPEC_TMP_TMP_HANDLER, - ZEND_SL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SL_SPEC_TMP_CV_HANDLER, - ZEND_SL_SPEC_VAR_CONST_HANDLER, - ZEND_SL_SPEC_VAR_TMP_HANDLER, - ZEND_SL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SL_SPEC_CV_CONST_HANDLER, - ZEND_SL_SPEC_CV_TMP_HANDLER, - ZEND_SL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SL_SPEC_CV_CV_HANDLER, - ZEND_SR_SPEC_CONST_CONST_HANDLER, - ZEND_SR_SPEC_CONST_TMP_HANDLER, - ZEND_SR_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SR_SPEC_CONST_CV_HANDLER, - ZEND_SR_SPEC_TMP_CONST_HANDLER, - ZEND_SR_SPEC_TMP_TMP_HANDLER, - ZEND_SR_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SR_SPEC_TMP_CV_HANDLER, - ZEND_SR_SPEC_VAR_CONST_HANDLER, - ZEND_SR_SPEC_VAR_TMP_HANDLER, - ZEND_SR_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SR_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SR_SPEC_CV_CONST_HANDLER, - ZEND_SR_SPEC_CV_TMP_HANDLER, - ZEND_SR_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SR_SPEC_CV_CV_HANDLER, - ZEND_CONCAT_SPEC_CONST_CONST_HANDLER, - ZEND_CONCAT_SPEC_CONST_TMP_HANDLER, - ZEND_CONCAT_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONCAT_SPEC_CONST_CV_HANDLER, - ZEND_CONCAT_SPEC_TMP_CONST_HANDLER, - ZEND_CONCAT_SPEC_TMP_TMP_HANDLER, - ZEND_CONCAT_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONCAT_SPEC_TMP_CV_HANDLER, - ZEND_CONCAT_SPEC_VAR_CONST_HANDLER, - ZEND_CONCAT_SPEC_VAR_TMP_HANDLER, - ZEND_CONCAT_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONCAT_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONCAT_SPEC_CV_CONST_HANDLER, - ZEND_CONCAT_SPEC_CV_TMP_HANDLER, - ZEND_CONCAT_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONCAT_SPEC_CV_CV_HANDLER, - ZEND_BW_OR_SPEC_CONST_CONST_HANDLER, - ZEND_BW_OR_SPEC_CONST_TMP_HANDLER, - ZEND_BW_OR_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_OR_SPEC_CONST_CV_HANDLER, - ZEND_BW_OR_SPEC_TMP_CONST_HANDLER, - ZEND_BW_OR_SPEC_TMP_TMP_HANDLER, - ZEND_BW_OR_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_OR_SPEC_TMP_CV_HANDLER, - ZEND_BW_OR_SPEC_VAR_CONST_HANDLER, - ZEND_BW_OR_SPEC_VAR_TMP_HANDLER, - ZEND_BW_OR_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_OR_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_OR_SPEC_CV_CONST_HANDLER, - ZEND_BW_OR_SPEC_CV_TMP_HANDLER, - ZEND_BW_OR_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_OR_SPEC_CV_CV_HANDLER, - ZEND_BW_AND_SPEC_CONST_CONST_HANDLER, - ZEND_BW_AND_SPEC_CONST_TMP_HANDLER, - ZEND_BW_AND_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_AND_SPEC_CONST_CV_HANDLER, - ZEND_BW_AND_SPEC_TMP_CONST_HANDLER, - ZEND_BW_AND_SPEC_TMP_TMP_HANDLER, - ZEND_BW_AND_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_AND_SPEC_TMP_CV_HANDLER, - ZEND_BW_AND_SPEC_VAR_CONST_HANDLER, - ZEND_BW_AND_SPEC_VAR_TMP_HANDLER, - ZEND_BW_AND_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_AND_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_AND_SPEC_CV_CONST_HANDLER, - ZEND_BW_AND_SPEC_CV_TMP_HANDLER, - ZEND_BW_AND_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_AND_SPEC_CV_CV_HANDLER, - ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER, - ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER, - ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_XOR_SPEC_CONST_CV_HANDLER, - ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER, - ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER, - ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_XOR_SPEC_TMP_CV_HANDLER, - ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER, - ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER, - ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_XOR_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_XOR_SPEC_CV_CONST_HANDLER, - ZEND_BW_XOR_SPEC_CV_TMP_HANDLER, - ZEND_BW_XOR_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_XOR_SPEC_CV_CV_HANDLER, - ZEND_BW_NOT_SPEC_CONST_HANDLER, - ZEND_BW_NOT_SPEC_CONST_HANDLER, - ZEND_BW_NOT_SPEC_CONST_HANDLER, - ZEND_BW_NOT_SPEC_CONST_HANDLER, - ZEND_BW_NOT_SPEC_CONST_HANDLER, - ZEND_BW_NOT_SPEC_TMP_HANDLER, - ZEND_BW_NOT_SPEC_TMP_HANDLER, - ZEND_BW_NOT_SPEC_TMP_HANDLER, - ZEND_BW_NOT_SPEC_TMP_HANDLER, - ZEND_BW_NOT_SPEC_TMP_HANDLER, - ZEND_BW_NOT_SPEC_VAR_HANDLER, - ZEND_BW_NOT_SPEC_VAR_HANDLER, - ZEND_BW_NOT_SPEC_VAR_HANDLER, - ZEND_BW_NOT_SPEC_VAR_HANDLER, - ZEND_BW_NOT_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BW_NOT_SPEC_CV_HANDLER, - ZEND_BW_NOT_SPEC_CV_HANDLER, - ZEND_BW_NOT_SPEC_CV_HANDLER, - ZEND_BW_NOT_SPEC_CV_HANDLER, - ZEND_BW_NOT_SPEC_CV_HANDLER, - ZEND_BOOL_NOT_SPEC_CONST_HANDLER, - ZEND_BOOL_NOT_SPEC_CONST_HANDLER, - ZEND_BOOL_NOT_SPEC_CONST_HANDLER, - ZEND_BOOL_NOT_SPEC_CONST_HANDLER, - ZEND_BOOL_NOT_SPEC_CONST_HANDLER, - ZEND_BOOL_NOT_SPEC_TMP_HANDLER, - ZEND_BOOL_NOT_SPEC_TMP_HANDLER, - ZEND_BOOL_NOT_SPEC_TMP_HANDLER, - ZEND_BOOL_NOT_SPEC_TMP_HANDLER, - ZEND_BOOL_NOT_SPEC_TMP_HANDLER, - ZEND_BOOL_NOT_SPEC_VAR_HANDLER, - ZEND_BOOL_NOT_SPEC_VAR_HANDLER, - ZEND_BOOL_NOT_SPEC_VAR_HANDLER, - ZEND_BOOL_NOT_SPEC_VAR_HANDLER, - ZEND_BOOL_NOT_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_NOT_SPEC_CV_HANDLER, - ZEND_BOOL_NOT_SPEC_CV_HANDLER, - ZEND_BOOL_NOT_SPEC_CV_HANDLER, - ZEND_BOOL_NOT_SPEC_CV_HANDLER, - ZEND_BOOL_NOT_SPEC_CV_HANDLER, - ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER, - ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER, - ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER, - ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER, - ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER, - ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER, - ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER, - ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER, - ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER, - ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER, - ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER, - ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER, - ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER, - ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER, - ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER, - ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER, - ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER, - ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER, - ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER, - ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER, - ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER, - ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER, - ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER, - ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER, - ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER, - ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER, - ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER, - ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER, - ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER, - ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER, - ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER, - ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER, - ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER, - ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER, - ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER, - ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER, - ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER, - ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER, - ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER, - ZEND_CAST_SPEC_CONST_HANDLER, - ZEND_CAST_SPEC_CONST_HANDLER, - ZEND_CAST_SPEC_CONST_HANDLER, - ZEND_CAST_SPEC_CONST_HANDLER, - ZEND_CAST_SPEC_CONST_HANDLER, - ZEND_CAST_SPEC_TMP_HANDLER, - ZEND_CAST_SPEC_TMP_HANDLER, - ZEND_CAST_SPEC_TMP_HANDLER, - ZEND_CAST_SPEC_TMP_HANDLER, - ZEND_CAST_SPEC_TMP_HANDLER, - ZEND_CAST_SPEC_VAR_HANDLER, - ZEND_CAST_SPEC_VAR_HANDLER, - ZEND_CAST_SPEC_VAR_HANDLER, - ZEND_CAST_SPEC_VAR_HANDLER, - ZEND_CAST_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CAST_SPEC_CV_HANDLER, - ZEND_CAST_SPEC_CV_HANDLER, - ZEND_CAST_SPEC_CV_HANDLER, - ZEND_CAST_SPEC_CV_HANDLER, - ZEND_CAST_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_QM_ASSIGN_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_ADD_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_ADD_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_ADD_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_ADD_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_ADD_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_ADD_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_ADD_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_ADD_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_ADD_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_ADD_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_ADD_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_ADD_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_ADD_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_ADD_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_ADD_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SUB_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_SUB_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_SUB_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_SUB_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_SUB_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_SUB_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_SUB_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_SUB_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_SUB_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_SUB_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_SUB_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_SUB_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_SUB_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_SUB_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_SUB_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_MUL_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_MUL_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_MUL_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_MUL_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_MUL_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_MUL_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_MUL_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_MUL_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_MUL_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_MUL_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_MUL_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_MUL_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_MUL_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_MUL_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_MUL_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_DIV_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_DIV_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_DIV_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_DIV_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_DIV_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_DIV_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_DIV_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_DIV_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_DIV_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_DIV_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_DIV_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_DIV_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_DIV_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_DIV_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_DIV_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_MOD_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_MOD_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_MOD_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_MOD_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_MOD_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_MOD_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_MOD_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_MOD_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_MOD_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_MOD_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_MOD_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_MOD_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_MOD_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_MOD_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_MOD_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SL_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_SL_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_SL_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_SL_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_SL_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_SL_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_SL_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_SL_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_SL_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_SL_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_SL_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_SL_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_SL_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_SL_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_SL_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SR_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_SR_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_SR_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_SR_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_SR_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_SR_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_SR_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_SR_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_SR_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_SR_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_SR_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_SR_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_SR_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_SR_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_SR_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_CONCAT_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_BW_OR_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_BW_AND_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_INC_SPEC_VAR_HANDLER, - ZEND_PRE_INC_SPEC_VAR_HANDLER, - ZEND_PRE_INC_SPEC_VAR_HANDLER, - ZEND_PRE_INC_SPEC_VAR_HANDLER, - ZEND_PRE_INC_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_INC_SPEC_CV_HANDLER, - ZEND_PRE_INC_SPEC_CV_HANDLER, - ZEND_PRE_INC_SPEC_CV_HANDLER, - ZEND_PRE_INC_SPEC_CV_HANDLER, - ZEND_PRE_INC_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_DEC_SPEC_VAR_HANDLER, - ZEND_PRE_DEC_SPEC_VAR_HANDLER, - ZEND_PRE_DEC_SPEC_VAR_HANDLER, - ZEND_PRE_DEC_SPEC_VAR_HANDLER, - ZEND_PRE_DEC_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_DEC_SPEC_CV_HANDLER, - ZEND_PRE_DEC_SPEC_CV_HANDLER, - ZEND_PRE_DEC_SPEC_CV_HANDLER, - ZEND_PRE_DEC_SPEC_CV_HANDLER, - ZEND_PRE_DEC_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_INC_SPEC_VAR_HANDLER, - ZEND_POST_INC_SPEC_VAR_HANDLER, - ZEND_POST_INC_SPEC_VAR_HANDLER, - ZEND_POST_INC_SPEC_VAR_HANDLER, - ZEND_POST_INC_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_INC_SPEC_CV_HANDLER, - ZEND_POST_INC_SPEC_CV_HANDLER, - ZEND_POST_INC_SPEC_CV_HANDLER, - ZEND_POST_INC_SPEC_CV_HANDLER, - ZEND_POST_INC_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_DEC_SPEC_VAR_HANDLER, - ZEND_POST_DEC_SPEC_VAR_HANDLER, - ZEND_POST_DEC_SPEC_VAR_HANDLER, - ZEND_POST_DEC_SPEC_VAR_HANDLER, - ZEND_POST_DEC_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_DEC_SPEC_CV_HANDLER, - ZEND_POST_DEC_SPEC_CV_HANDLER, - ZEND_POST_DEC_SPEC_CV_HANDLER, - ZEND_POST_DEC_SPEC_CV_HANDLER, - ZEND_POST_DEC_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER, - ZEND_ECHO_SPEC_CONST_HANDLER, - ZEND_ECHO_SPEC_CONST_HANDLER, - ZEND_ECHO_SPEC_CONST_HANDLER, - ZEND_ECHO_SPEC_CONST_HANDLER, - ZEND_ECHO_SPEC_CONST_HANDLER, - ZEND_ECHO_SPEC_TMP_HANDLER, - ZEND_ECHO_SPEC_TMP_HANDLER, - ZEND_ECHO_SPEC_TMP_HANDLER, - ZEND_ECHO_SPEC_TMP_HANDLER, - ZEND_ECHO_SPEC_TMP_HANDLER, - ZEND_ECHO_SPEC_VAR_HANDLER, - ZEND_ECHO_SPEC_VAR_HANDLER, - ZEND_ECHO_SPEC_VAR_HANDLER, - ZEND_ECHO_SPEC_VAR_HANDLER, - ZEND_ECHO_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ECHO_SPEC_CV_HANDLER, - ZEND_ECHO_SPEC_CV_HANDLER, - ZEND_ECHO_SPEC_CV_HANDLER, - ZEND_ECHO_SPEC_CV_HANDLER, - ZEND_ECHO_SPEC_CV_HANDLER, - ZEND_PRINT_SPEC_CONST_HANDLER, - ZEND_PRINT_SPEC_CONST_HANDLER, - ZEND_PRINT_SPEC_CONST_HANDLER, - ZEND_PRINT_SPEC_CONST_HANDLER, - ZEND_PRINT_SPEC_CONST_HANDLER, - ZEND_PRINT_SPEC_TMP_HANDLER, - ZEND_PRINT_SPEC_TMP_HANDLER, - ZEND_PRINT_SPEC_TMP_HANDLER, - ZEND_PRINT_SPEC_TMP_HANDLER, - ZEND_PRINT_SPEC_TMP_HANDLER, - ZEND_PRINT_SPEC_VAR_HANDLER, - ZEND_PRINT_SPEC_VAR_HANDLER, - ZEND_PRINT_SPEC_VAR_HANDLER, - ZEND_PRINT_SPEC_VAR_HANDLER, - ZEND_PRINT_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRINT_SPEC_CV_HANDLER, - ZEND_PRINT_SPEC_CV_HANDLER, - ZEND_PRINT_SPEC_CV_HANDLER, - ZEND_PRINT_SPEC_CV_HANDLER, - ZEND_PRINT_SPEC_CV_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMP_SPEC_HANDLER, - ZEND_JMPZ_SPEC_CONST_HANDLER, - ZEND_JMPZ_SPEC_CONST_HANDLER, - ZEND_JMPZ_SPEC_CONST_HANDLER, - ZEND_JMPZ_SPEC_CONST_HANDLER, - ZEND_JMPZ_SPEC_CONST_HANDLER, - ZEND_JMPZ_SPEC_TMP_HANDLER, - ZEND_JMPZ_SPEC_TMP_HANDLER, - ZEND_JMPZ_SPEC_TMP_HANDLER, - ZEND_JMPZ_SPEC_TMP_HANDLER, - ZEND_JMPZ_SPEC_TMP_HANDLER, - ZEND_JMPZ_SPEC_VAR_HANDLER, - ZEND_JMPZ_SPEC_VAR_HANDLER, - ZEND_JMPZ_SPEC_VAR_HANDLER, - ZEND_JMPZ_SPEC_VAR_HANDLER, - ZEND_JMPZ_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMPZ_SPEC_CV_HANDLER, - ZEND_JMPZ_SPEC_CV_HANDLER, - ZEND_JMPZ_SPEC_CV_HANDLER, - ZEND_JMPZ_SPEC_CV_HANDLER, - ZEND_JMPZ_SPEC_CV_HANDLER, - ZEND_JMPNZ_SPEC_CONST_HANDLER, - ZEND_JMPNZ_SPEC_CONST_HANDLER, - ZEND_JMPNZ_SPEC_CONST_HANDLER, - ZEND_JMPNZ_SPEC_CONST_HANDLER, - ZEND_JMPNZ_SPEC_CONST_HANDLER, - ZEND_JMPNZ_SPEC_TMP_HANDLER, - ZEND_JMPNZ_SPEC_TMP_HANDLER, - ZEND_JMPNZ_SPEC_TMP_HANDLER, - ZEND_JMPNZ_SPEC_TMP_HANDLER, - ZEND_JMPNZ_SPEC_TMP_HANDLER, - ZEND_JMPNZ_SPEC_VAR_HANDLER, - ZEND_JMPNZ_SPEC_VAR_HANDLER, - ZEND_JMPNZ_SPEC_VAR_HANDLER, - ZEND_JMPNZ_SPEC_VAR_HANDLER, - ZEND_JMPNZ_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMPNZ_SPEC_CV_HANDLER, - ZEND_JMPNZ_SPEC_CV_HANDLER, - ZEND_JMPNZ_SPEC_CV_HANDLER, - ZEND_JMPNZ_SPEC_CV_HANDLER, - ZEND_JMPNZ_SPEC_CV_HANDLER, - ZEND_JMPZNZ_SPEC_CONST_HANDLER, - ZEND_JMPZNZ_SPEC_CONST_HANDLER, - ZEND_JMPZNZ_SPEC_CONST_HANDLER, - ZEND_JMPZNZ_SPEC_CONST_HANDLER, - ZEND_JMPZNZ_SPEC_CONST_HANDLER, - ZEND_JMPZNZ_SPEC_TMP_HANDLER, - ZEND_JMPZNZ_SPEC_TMP_HANDLER, - ZEND_JMPZNZ_SPEC_TMP_HANDLER, - ZEND_JMPZNZ_SPEC_TMP_HANDLER, - ZEND_JMPZNZ_SPEC_TMP_HANDLER, - ZEND_JMPZNZ_SPEC_VAR_HANDLER, - ZEND_JMPZNZ_SPEC_VAR_HANDLER, - ZEND_JMPZNZ_SPEC_VAR_HANDLER, - ZEND_JMPZNZ_SPEC_VAR_HANDLER, - ZEND_JMPZNZ_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMPZNZ_SPEC_CV_HANDLER, - ZEND_JMPZNZ_SPEC_CV_HANDLER, - ZEND_JMPZNZ_SPEC_CV_HANDLER, - ZEND_JMPZNZ_SPEC_CV_HANDLER, - ZEND_JMPZNZ_SPEC_CV_HANDLER, - ZEND_JMPZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPZ_EX_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMPZ_EX_SPEC_CV_HANDLER, - ZEND_JMPZ_EX_SPEC_CV_HANDLER, - ZEND_JMPZ_EX_SPEC_CV_HANDLER, - ZEND_JMPZ_EX_SPEC_CV_HANDLER, - ZEND_JMPZ_EX_SPEC_CV_HANDLER, - ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, - ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, - ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, - ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMPNZ_EX_SPEC_CV_HANDLER, - ZEND_JMPNZ_EX_SPEC_CV_HANDLER, - ZEND_JMPNZ_EX_SPEC_CV_HANDLER, - ZEND_JMPNZ_EX_SPEC_CV_HANDLER, - ZEND_JMPNZ_EX_SPEC_CV_HANDLER, - ZEND_CASE_SPEC_CONST_CONST_HANDLER, - ZEND_CASE_SPEC_CONST_TMP_HANDLER, - ZEND_CASE_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CASE_SPEC_CONST_CV_HANDLER, - ZEND_CASE_SPEC_TMP_CONST_HANDLER, - ZEND_CASE_SPEC_TMP_TMP_HANDLER, - ZEND_CASE_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CASE_SPEC_TMP_CV_HANDLER, - ZEND_CASE_SPEC_VAR_CONST_HANDLER, - ZEND_CASE_SPEC_VAR_TMP_HANDLER, - ZEND_CASE_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CASE_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CASE_SPEC_CV_CONST_HANDLER, - ZEND_CASE_SPEC_CV_TMP_HANDLER, - ZEND_CASE_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CASE_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, - ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, - ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, - ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, - ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BRK_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BRK_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BRK_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BRK_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BRK_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CONT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_SPEC_CONST_HANDLER, - ZEND_BOOL_SPEC_CONST_HANDLER, - ZEND_BOOL_SPEC_CONST_HANDLER, - ZEND_BOOL_SPEC_CONST_HANDLER, - ZEND_BOOL_SPEC_CONST_HANDLER, - ZEND_BOOL_SPEC_TMP_HANDLER, - ZEND_BOOL_SPEC_TMP_HANDLER, - ZEND_BOOL_SPEC_TMP_HANDLER, - ZEND_BOOL_SPEC_TMP_HANDLER, - ZEND_BOOL_SPEC_TMP_HANDLER, - ZEND_BOOL_SPEC_VAR_HANDLER, - ZEND_BOOL_SPEC_VAR_HANDLER, - ZEND_BOOL_SPEC_VAR_HANDLER, - ZEND_BOOL_SPEC_VAR_HANDLER, - ZEND_BOOL_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BOOL_SPEC_CV_HANDLER, - ZEND_BOOL_SPEC_CV_HANDLER, - ZEND_BOOL_SPEC_CV_HANDLER, - ZEND_BOOL_SPEC_CV_HANDLER, - ZEND_BOOL_SPEC_CV_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_INIT_STRING_SPEC_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER, - ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER, - ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_BEGIN_SILENCE_SPEC_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_END_SILENCE_SPEC_TMP_HANDLER, - ZEND_END_SILENCE_SPEC_TMP_HANDLER, - ZEND_END_SILENCE_SPEC_TMP_HANDLER, - ZEND_END_SILENCE_SPEC_TMP_HANDLER, - ZEND_END_SILENCE_SPEC_TMP_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, - ZEND_DO_FCALL_SPEC_CONST_HANDLER, - ZEND_DO_FCALL_SPEC_CONST_HANDLER, - ZEND_DO_FCALL_SPEC_CONST_HANDLER, - ZEND_DO_FCALL_SPEC_CONST_HANDLER, - ZEND_DO_FCALL_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, - ZEND_RETURN_SPEC_CONST_HANDLER, - ZEND_RETURN_SPEC_CONST_HANDLER, - ZEND_RETURN_SPEC_CONST_HANDLER, - ZEND_RETURN_SPEC_CONST_HANDLER, - ZEND_RETURN_SPEC_CONST_HANDLER, - ZEND_RETURN_SPEC_TMP_HANDLER, - ZEND_RETURN_SPEC_TMP_HANDLER, - ZEND_RETURN_SPEC_TMP_HANDLER, - ZEND_RETURN_SPEC_TMP_HANDLER, - ZEND_RETURN_SPEC_TMP_HANDLER, - ZEND_RETURN_SPEC_VAR_HANDLER, - ZEND_RETURN_SPEC_VAR_HANDLER, - ZEND_RETURN_SPEC_VAR_HANDLER, - ZEND_RETURN_SPEC_VAR_HANDLER, - ZEND_RETURN_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_RETURN_SPEC_CV_HANDLER, - ZEND_RETURN_SPEC_CV_HANDLER, - ZEND_RETURN_SPEC_CV_HANDLER, - ZEND_RETURN_SPEC_CV_HANDLER, - ZEND_RETURN_SPEC_CV_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_SPEC_HANDLER, - ZEND_RECV_INIT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_RECV_INIT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_RECV_INIT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_RECV_INIT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_RECV_INIT_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_VAL_SPEC_CONST_HANDLER, - ZEND_SEND_VAL_SPEC_CONST_HANDLER, - ZEND_SEND_VAL_SPEC_CONST_HANDLER, - ZEND_SEND_VAL_SPEC_CONST_HANDLER, - ZEND_SEND_VAL_SPEC_CONST_HANDLER, - ZEND_SEND_VAL_SPEC_TMP_HANDLER, - ZEND_SEND_VAL_SPEC_TMP_HANDLER, - ZEND_SEND_VAL_SPEC_TMP_HANDLER, - ZEND_SEND_VAL_SPEC_TMP_HANDLER, - ZEND_SEND_VAL_SPEC_TMP_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_VAR_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_VAR_SPEC_CV_HANDLER, - ZEND_SEND_VAR_SPEC_CV_HANDLER, - ZEND_SEND_VAR_SPEC_CV_HANDLER, - ZEND_SEND_VAR_SPEC_CV_HANDLER, - ZEND_SEND_VAR_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_REF_SPEC_VAR_HANDLER, - ZEND_SEND_REF_SPEC_VAR_HANDLER, - ZEND_SEND_REF_SPEC_VAR_HANDLER, - ZEND_SEND_REF_SPEC_VAR_HANDLER, - ZEND_SEND_REF_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_REF_SPEC_CV_HANDLER, - ZEND_SEND_REF_SPEC_CV_HANDLER, - ZEND_SEND_REF_SPEC_CV_HANDLER, - ZEND_SEND_REF_SPEC_CV_HANDLER, - ZEND_SEND_REF_SPEC_CV_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_NEW_SPEC_HANDLER, - ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FREE_SPEC_TMP_HANDLER, - ZEND_FREE_SPEC_TMP_HANDLER, - ZEND_FREE_SPEC_TMP_HANDLER, - ZEND_FREE_SPEC_TMP_HANDLER, - ZEND_FREE_SPEC_TMP_HANDLER, - ZEND_FREE_SPEC_VAR_HANDLER, - ZEND_FREE_SPEC_VAR_HANDLER, - ZEND_FREE_SPEC_VAR_HANDLER, - ZEND_FREE_SPEC_VAR_HANDLER, - ZEND_FREE_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER, - ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER, - ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER, - ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER, - ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER, - ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER, - ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER, - ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER, - ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER, - ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER, - ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER, - ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER, - ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER, - ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER, - ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER, - ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER, - ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER, - ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER, - ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER, - ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER, - ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER, - ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER, - ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER, - ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER, - ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, - ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, - ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER, - ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER, - ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER, - ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER, - ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER, - ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER, - ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER, - ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER, - ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER, - ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER, - ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER, - ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER, - ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER, - ZEND_FE_RESET_SPEC_CONST_HANDLER, - ZEND_FE_RESET_SPEC_CONST_HANDLER, - ZEND_FE_RESET_SPEC_CONST_HANDLER, - ZEND_FE_RESET_SPEC_CONST_HANDLER, - ZEND_FE_RESET_SPEC_CONST_HANDLER, - ZEND_FE_RESET_SPEC_TMP_HANDLER, - ZEND_FE_RESET_SPEC_TMP_HANDLER, - ZEND_FE_RESET_SPEC_TMP_HANDLER, - ZEND_FE_RESET_SPEC_TMP_HANDLER, - ZEND_FE_RESET_SPEC_TMP_HANDLER, - ZEND_FE_RESET_SPEC_VAR_HANDLER, - ZEND_FE_RESET_SPEC_VAR_HANDLER, - ZEND_FE_RESET_SPEC_VAR_HANDLER, - ZEND_FE_RESET_SPEC_VAR_HANDLER, - ZEND_FE_RESET_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FE_RESET_SPEC_CV_HANDLER, - ZEND_FE_RESET_SPEC_CV_HANDLER, - ZEND_FE_RESET_SPEC_CV_HANDLER, - ZEND_FE_RESET_SPEC_CV_HANDLER, - ZEND_FE_RESET_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FE_FETCH_SPEC_VAR_HANDLER, - ZEND_FE_FETCH_SPEC_VAR_HANDLER, - ZEND_FE_FETCH_SPEC_VAR_HANDLER, - ZEND_FE_FETCH_SPEC_VAR_HANDLER, - ZEND_FE_FETCH_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_EXIT_SPEC_CONST_HANDLER, - ZEND_EXIT_SPEC_CONST_HANDLER, - ZEND_EXIT_SPEC_CONST_HANDLER, - ZEND_EXIT_SPEC_CONST_HANDLER, - ZEND_EXIT_SPEC_CONST_HANDLER, - ZEND_EXIT_SPEC_TMP_HANDLER, - ZEND_EXIT_SPEC_TMP_HANDLER, - ZEND_EXIT_SPEC_TMP_HANDLER, - ZEND_EXIT_SPEC_TMP_HANDLER, - ZEND_EXIT_SPEC_TMP_HANDLER, - ZEND_EXIT_SPEC_VAR_HANDLER, - ZEND_EXIT_SPEC_VAR_HANDLER, - ZEND_EXIT_SPEC_VAR_HANDLER, - ZEND_EXIT_SPEC_VAR_HANDLER, - ZEND_EXIT_SPEC_VAR_HANDLER, - ZEND_EXIT_SPEC_UNUSED_HANDLER, - ZEND_EXIT_SPEC_UNUSED_HANDLER, - ZEND_EXIT_SPEC_UNUSED_HANDLER, - ZEND_EXIT_SPEC_UNUSED_HANDLER, - ZEND_EXIT_SPEC_UNUSED_HANDLER, - ZEND_EXIT_SPEC_CV_HANDLER, - ZEND_EXIT_SPEC_CV_HANDLER, - ZEND_EXIT_SPEC_CV_HANDLER, - ZEND_EXIT_SPEC_CV_HANDLER, - ZEND_EXIT_SPEC_CV_HANDLER, - ZEND_FETCH_R_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_CONST_VAR_HANDLER, - ZEND_FETCH_R_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_TMP_VAR_HANDLER, - ZEND_FETCH_R_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_R_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_R_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_R_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER, - ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER, - ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER, - ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER, - ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_VAR_CV_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_UNUSED_CONST_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_UNUSED_TMP_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_UNUSED_CV_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_R_SPEC_CV_CV_HANDLER, - ZEND_FETCH_W_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_CONST_VAR_HANDLER, - ZEND_FETCH_W_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_TMP_VAR_HANDLER, - ZEND_FETCH_W_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_W_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_W_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_W_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER, - ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER, - ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER, - ZEND_FETCH_RW_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_CONST_VAR_HANDLER, - ZEND_FETCH_RW_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_TMP_VAR_HANDLER, - ZEND_FETCH_RW_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_RW_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_RW_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_RW_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER, - ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER, - ZEND_FETCH_IS_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_CONST_VAR_HANDLER, - ZEND_FETCH_IS_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_TMP_VAR_HANDLER, - ZEND_FETCH_IS_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_IS_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_IS_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER, - ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER, - ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER, - ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER, - ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER, - ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER, - ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER, - ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_GOTO_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_GOTO_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_GOTO_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_GOTO_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_GOTO_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_STMT_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_FCALL_END_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_EXT_NOP_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_TICKS_SPEC_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, - ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_CATCH_SPEC_CONST_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_THROW_SPEC_CONST_HANDLER, - ZEND_THROW_SPEC_CONST_HANDLER, - ZEND_THROW_SPEC_CONST_HANDLER, - ZEND_THROW_SPEC_CONST_HANDLER, - ZEND_THROW_SPEC_CONST_HANDLER, - ZEND_THROW_SPEC_TMP_HANDLER, - ZEND_THROW_SPEC_TMP_HANDLER, - ZEND_THROW_SPEC_TMP_HANDLER, - ZEND_THROW_SPEC_TMP_HANDLER, - ZEND_THROW_SPEC_TMP_HANDLER, - ZEND_THROW_SPEC_VAR_HANDLER, - ZEND_THROW_SPEC_VAR_HANDLER, - ZEND_THROW_SPEC_VAR_HANDLER, - ZEND_THROW_SPEC_VAR_HANDLER, - ZEND_THROW_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_THROW_SPEC_CV_HANDLER, - ZEND_THROW_SPEC_CV_HANDLER, - ZEND_THROW_SPEC_CV_HANDLER, - ZEND_THROW_SPEC_CV_HANDLER, - ZEND_THROW_SPEC_CV_HANDLER, - ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, - ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, - ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, - ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, - ZEND_FETCH_CLASS_SPEC_CV_HANDLER, - ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, - ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, - ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, - ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, - ZEND_FETCH_CLASS_SPEC_CV_HANDLER, - ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, - ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, - ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, - ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, - ZEND_FETCH_CLASS_SPEC_CV_HANDLER, - ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, - ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, - ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, - ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, - ZEND_FETCH_CLASS_SPEC_CV_HANDLER, - ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, - ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, - ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, - ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, - ZEND_FETCH_CLASS_SPEC_CV_HANDLER, - ZEND_CLONE_SPEC_CONST_HANDLER, - ZEND_CLONE_SPEC_CONST_HANDLER, - ZEND_CLONE_SPEC_CONST_HANDLER, - ZEND_CLONE_SPEC_CONST_HANDLER, - ZEND_CLONE_SPEC_CONST_HANDLER, - ZEND_CLONE_SPEC_TMP_HANDLER, - ZEND_CLONE_SPEC_TMP_HANDLER, - ZEND_CLONE_SPEC_TMP_HANDLER, - ZEND_CLONE_SPEC_TMP_HANDLER, - ZEND_CLONE_SPEC_TMP_HANDLER, - ZEND_CLONE_SPEC_VAR_HANDLER, - ZEND_CLONE_SPEC_VAR_HANDLER, - ZEND_CLONE_SPEC_VAR_HANDLER, - ZEND_CLONE_SPEC_VAR_HANDLER, - ZEND_CLONE_SPEC_VAR_HANDLER, - ZEND_CLONE_SPEC_UNUSED_HANDLER, - ZEND_CLONE_SPEC_UNUSED_HANDLER, - ZEND_CLONE_SPEC_UNUSED_HANDLER, - ZEND_CLONE_SPEC_UNUSED_HANDLER, - ZEND_CLONE_SPEC_UNUSED_HANDLER, - ZEND_CLONE_SPEC_CV_HANDLER, - ZEND_CLONE_SPEC_CV_HANDLER, - ZEND_CLONE_SPEC_CV_HANDLER, - ZEND_CLONE_SPEC_CV_HANDLER, - ZEND_CLONE_SPEC_CV_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, - ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, - ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, - ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, - ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, - ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, - ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, - ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, - ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, - ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, - ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, - ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER, - ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER, - ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_INC_OBJ_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_INC_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_POST_INC_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_POST_INC_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_INC_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_POST_INC_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_POST_INC_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_POST_INC_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_INC_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_POST_INC_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_POST_INC_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_POST_INC_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_INC_OBJ_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_POST_DEC_OBJ_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INSTANCEOF_SPEC_TMP_HANDLER, - ZEND_INSTANCEOF_SPEC_TMP_HANDLER, - ZEND_INSTANCEOF_SPEC_TMP_HANDLER, - ZEND_INSTANCEOF_SPEC_TMP_HANDLER, - ZEND_INSTANCEOF_SPEC_TMP_HANDLER, - ZEND_INSTANCEOF_SPEC_VAR_HANDLER, - ZEND_INSTANCEOF_SPEC_VAR_HANDLER, - ZEND_INSTANCEOF_SPEC_VAR_HANDLER, - ZEND_INSTANCEOF_SPEC_VAR_HANDLER, - ZEND_INSTANCEOF_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_INSTANCEOF_SPEC_CV_HANDLER, - ZEND_INSTANCEOF_SPEC_CV_HANDLER, - ZEND_INSTANCEOF_SPEC_CV_HANDLER, - ZEND_INSTANCEOF_SPEC_CV_HANDLER, - ZEND_INSTANCEOF_SPEC_CV_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_DECLARE_FUNCTION_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, - ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER, - ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER, - ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER, - ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER, - ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER, - ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER, - ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER, - ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER, - ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CONST_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_TMP_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CV_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CONST_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_TMP_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CV_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_USER_OPCODE_SPEC_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMP_SET_SPEC_CONST_HANDLER, - ZEND_JMP_SET_SPEC_CONST_HANDLER, - ZEND_JMP_SET_SPEC_CONST_HANDLER, - ZEND_JMP_SET_SPEC_CONST_HANDLER, - ZEND_JMP_SET_SPEC_CONST_HANDLER, - ZEND_JMP_SET_SPEC_TMP_HANDLER, - ZEND_JMP_SET_SPEC_TMP_HANDLER, - ZEND_JMP_SET_SPEC_TMP_HANDLER, - ZEND_JMP_SET_SPEC_TMP_HANDLER, - ZEND_JMP_SET_SPEC_TMP_HANDLER, - ZEND_JMP_SET_SPEC_VAR_HANDLER, - ZEND_JMP_SET_SPEC_VAR_HANDLER, - ZEND_JMP_SET_SPEC_VAR_HANDLER, - ZEND_JMP_SET_SPEC_VAR_HANDLER, - ZEND_JMP_SET_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMP_SET_SPEC_CV_HANDLER, - ZEND_JMP_SET_SPEC_CV_HANDLER, - ZEND_JMP_SET_SPEC_CV_HANDLER, - ZEND_JMP_SET_SPEC_CV_HANDLER, - ZEND_JMP_SET_SPEC_CV_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_ADD_TRAIT_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_BIND_TRAITS_SPEC_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, - ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, - ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, - ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, - ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, - ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, - ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, - ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, - ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, - ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, - ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, - ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_NULL_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, - ZEND_YIELD_SPEC_CONST_CONST_HANDLER, - ZEND_YIELD_SPEC_CONST_TMP_HANDLER, - ZEND_YIELD_SPEC_CONST_VAR_HANDLER, - ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER, - ZEND_YIELD_SPEC_CONST_CV_HANDLER, - ZEND_YIELD_SPEC_TMP_CONST_HANDLER, - ZEND_YIELD_SPEC_TMP_TMP_HANDLER, - ZEND_YIELD_SPEC_TMP_VAR_HANDLER, - ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER, - ZEND_YIELD_SPEC_TMP_CV_HANDLER, - ZEND_YIELD_SPEC_VAR_CONST_HANDLER, - ZEND_YIELD_SPEC_VAR_TMP_HANDLER, - ZEND_YIELD_SPEC_VAR_VAR_HANDLER, - ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER, - ZEND_YIELD_SPEC_VAR_CV_HANDLER, - ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER, - ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER, - ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER, - ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER, - ZEND_YIELD_SPEC_UNUSED_CV_HANDLER, - ZEND_YIELD_SPEC_CV_CONST_HANDLER, - ZEND_YIELD_SPEC_CV_TMP_HANDLER, - ZEND_YIELD_SPEC_CV_VAR_HANDLER, - ZEND_YIELD_SPEC_CV_UNUSED_HANDLER, - ZEND_YIELD_SPEC_CV_CV_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_GENERATOR_RETURN_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_CALL_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_FAST_RET_SPEC_HANDLER, - ZEND_NULL_HANDLER + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)0, + (opcode_handler_t)25, + (opcode_handler_t)26, + (opcode_handler_t)27, + (opcode_handler_t)-1, + (opcode_handler_t)29, + (opcode_handler_t)30, + (opcode_handler_t)31, + (opcode_handler_t)32, + (opcode_handler_t)-1, + (opcode_handler_t)34, + (opcode_handler_t)35, + (opcode_handler_t)36, + (opcode_handler_t)37, + (opcode_handler_t)-1, + (opcode_handler_t)39, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)45, + (opcode_handler_t)46, + (opcode_handler_t)47, + (opcode_handler_t)-1, + (opcode_handler_t)49, + (opcode_handler_t)50, + (opcode_handler_t)51, + (opcode_handler_t)52, + (opcode_handler_t)-1, + (opcode_handler_t)54, + (opcode_handler_t)55, + (opcode_handler_t)56, + (opcode_handler_t)57, + (opcode_handler_t)-1, + (opcode_handler_t)59, + (opcode_handler_t)60, + (opcode_handler_t)61, + (opcode_handler_t)62, + (opcode_handler_t)-1, + (opcode_handler_t)64, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)70, + (opcode_handler_t)71, + (opcode_handler_t)72, + (opcode_handler_t)-1, + (opcode_handler_t)74, + (opcode_handler_t)75, + (opcode_handler_t)76, + (opcode_handler_t)77, + (opcode_handler_t)-1, + (opcode_handler_t)79, + (opcode_handler_t)80, + (opcode_handler_t)81, + (opcode_handler_t)82, + (opcode_handler_t)-1, + (opcode_handler_t)84, + (opcode_handler_t)85, + (opcode_handler_t)86, + (opcode_handler_t)87, + (opcode_handler_t)-1, + (opcode_handler_t)89, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)95, + (opcode_handler_t)96, + (opcode_handler_t)97, + (opcode_handler_t)-1, + (opcode_handler_t)99, + (opcode_handler_t)100, + (opcode_handler_t)101, + (opcode_handler_t)102, + (opcode_handler_t)-1, + (opcode_handler_t)104, + (opcode_handler_t)105, + (opcode_handler_t)106, + (opcode_handler_t)107, + (opcode_handler_t)-1, + (opcode_handler_t)109, + (opcode_handler_t)110, + (opcode_handler_t)111, + (opcode_handler_t)112, + (opcode_handler_t)-1, + (opcode_handler_t)114, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)120, + (opcode_handler_t)121, + (opcode_handler_t)122, + (opcode_handler_t)-1, + (opcode_handler_t)124, + (opcode_handler_t)125, + (opcode_handler_t)126, + (opcode_handler_t)127, + (opcode_handler_t)-1, + (opcode_handler_t)129, + (opcode_handler_t)130, + (opcode_handler_t)131, + (opcode_handler_t)132, + (opcode_handler_t)-1, + (opcode_handler_t)134, + (opcode_handler_t)135, + (opcode_handler_t)136, + (opcode_handler_t)137, + (opcode_handler_t)-1, + (opcode_handler_t)139, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)145, + (opcode_handler_t)146, + (opcode_handler_t)147, + (opcode_handler_t)-1, + (opcode_handler_t)149, + (opcode_handler_t)150, + (opcode_handler_t)151, + (opcode_handler_t)152, + (opcode_handler_t)-1, + (opcode_handler_t)154, + (opcode_handler_t)155, + (opcode_handler_t)156, + (opcode_handler_t)157, + (opcode_handler_t)-1, + (opcode_handler_t)159, + (opcode_handler_t)160, + (opcode_handler_t)161, + (opcode_handler_t)162, + (opcode_handler_t)-1, + (opcode_handler_t)164, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)170, + (opcode_handler_t)171, + (opcode_handler_t)172, + (opcode_handler_t)-1, + (opcode_handler_t)174, + (opcode_handler_t)175, + (opcode_handler_t)176, + (opcode_handler_t)177, + (opcode_handler_t)-1, + (opcode_handler_t)179, + (opcode_handler_t)180, + (opcode_handler_t)181, + (opcode_handler_t)182, + (opcode_handler_t)-1, + (opcode_handler_t)184, + (opcode_handler_t)185, + (opcode_handler_t)186, + (opcode_handler_t)187, + (opcode_handler_t)-1, + (opcode_handler_t)189, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)195, + (opcode_handler_t)196, + (opcode_handler_t)197, + (opcode_handler_t)-1, + (opcode_handler_t)199, + (opcode_handler_t)200, + (opcode_handler_t)201, + (opcode_handler_t)202, + (opcode_handler_t)-1, + (opcode_handler_t)204, + (opcode_handler_t)205, + (opcode_handler_t)206, + (opcode_handler_t)207, + (opcode_handler_t)-1, + (opcode_handler_t)209, + (opcode_handler_t)210, + (opcode_handler_t)211, + (opcode_handler_t)212, + (opcode_handler_t)-1, + (opcode_handler_t)214, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)220, + (opcode_handler_t)221, + (opcode_handler_t)222, + (opcode_handler_t)-1, + (opcode_handler_t)224, + (opcode_handler_t)225, + (opcode_handler_t)226, + (opcode_handler_t)227, + (opcode_handler_t)-1, + (opcode_handler_t)229, + (opcode_handler_t)230, + (opcode_handler_t)231, + (opcode_handler_t)232, + (opcode_handler_t)-1, + (opcode_handler_t)234, + (opcode_handler_t)235, + (opcode_handler_t)236, + (opcode_handler_t)237, + (opcode_handler_t)-1, + (opcode_handler_t)239, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)245, + (opcode_handler_t)246, + (opcode_handler_t)247, + (opcode_handler_t)-1, + (opcode_handler_t)249, + (opcode_handler_t)250, + (opcode_handler_t)251, + (opcode_handler_t)252, + (opcode_handler_t)-1, + (opcode_handler_t)254, + (opcode_handler_t)255, + (opcode_handler_t)256, + (opcode_handler_t)257, + (opcode_handler_t)-1, + (opcode_handler_t)259, + (opcode_handler_t)260, + (opcode_handler_t)261, + (opcode_handler_t)262, + (opcode_handler_t)-1, + (opcode_handler_t)264, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)270, + (opcode_handler_t)271, + (opcode_handler_t)272, + (opcode_handler_t)-1, + (opcode_handler_t)274, + (opcode_handler_t)275, + (opcode_handler_t)276, + (opcode_handler_t)277, + (opcode_handler_t)-1, + (opcode_handler_t)279, + (opcode_handler_t)280, + (opcode_handler_t)281, + (opcode_handler_t)282, + (opcode_handler_t)-1, + (opcode_handler_t)284, + (opcode_handler_t)285, + (opcode_handler_t)286, + (opcode_handler_t)287, + (opcode_handler_t)-1, + (opcode_handler_t)289, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)295, + (opcode_handler_t)296, + (opcode_handler_t)297, + (opcode_handler_t)-1, + (opcode_handler_t)299, + (opcode_handler_t)300, + (opcode_handler_t)300, + (opcode_handler_t)300, + (opcode_handler_t)300, + (opcode_handler_t)300, + (opcode_handler_t)305, + (opcode_handler_t)305, + (opcode_handler_t)305, + (opcode_handler_t)305, + (opcode_handler_t)305, + (opcode_handler_t)310, + (opcode_handler_t)310, + (opcode_handler_t)310, + (opcode_handler_t)310, + (opcode_handler_t)310, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)320, + (opcode_handler_t)320, + (opcode_handler_t)320, + (opcode_handler_t)320, + (opcode_handler_t)320, + (opcode_handler_t)325, + (opcode_handler_t)325, + (opcode_handler_t)325, + (opcode_handler_t)325, + (opcode_handler_t)325, + (opcode_handler_t)330, + (opcode_handler_t)330, + (opcode_handler_t)330, + (opcode_handler_t)330, + (opcode_handler_t)330, + (opcode_handler_t)335, + (opcode_handler_t)335, + (opcode_handler_t)335, + (opcode_handler_t)335, + (opcode_handler_t)335, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)345, + (opcode_handler_t)345, + (opcode_handler_t)345, + (opcode_handler_t)345, + (opcode_handler_t)345, + (opcode_handler_t)350, + (opcode_handler_t)351, + (opcode_handler_t)352, + (opcode_handler_t)-1, + (opcode_handler_t)354, + (opcode_handler_t)355, + (opcode_handler_t)356, + (opcode_handler_t)357, + (opcode_handler_t)-1, + (opcode_handler_t)359, + (opcode_handler_t)360, + (opcode_handler_t)361, + (opcode_handler_t)362, + (opcode_handler_t)-1, + (opcode_handler_t)364, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)370, + (opcode_handler_t)371, + (opcode_handler_t)372, + (opcode_handler_t)-1, + (opcode_handler_t)374, + (opcode_handler_t)375, + (opcode_handler_t)376, + (opcode_handler_t)377, + (opcode_handler_t)-1, + (opcode_handler_t)379, + (opcode_handler_t)380, + (opcode_handler_t)381, + (opcode_handler_t)382, + (opcode_handler_t)-1, + (opcode_handler_t)384, + (opcode_handler_t)385, + (opcode_handler_t)386, + (opcode_handler_t)387, + (opcode_handler_t)-1, + (opcode_handler_t)389, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)395, + (opcode_handler_t)396, + (opcode_handler_t)397, + (opcode_handler_t)-1, + (opcode_handler_t)399, + (opcode_handler_t)400, + (opcode_handler_t)401, + (opcode_handler_t)402, + (opcode_handler_t)-1, + (opcode_handler_t)404, + (opcode_handler_t)405, + (opcode_handler_t)406, + (opcode_handler_t)407, + (opcode_handler_t)-1, + (opcode_handler_t)409, + (opcode_handler_t)410, + (opcode_handler_t)411, + (opcode_handler_t)412, + (opcode_handler_t)-1, + (opcode_handler_t)414, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)420, + (opcode_handler_t)421, + (opcode_handler_t)422, + (opcode_handler_t)-1, + (opcode_handler_t)424, + (opcode_handler_t)425, + (opcode_handler_t)426, + (opcode_handler_t)427, + (opcode_handler_t)-1, + (opcode_handler_t)429, + (opcode_handler_t)430, + (opcode_handler_t)431, + (opcode_handler_t)432, + (opcode_handler_t)-1, + (opcode_handler_t)434, + (opcode_handler_t)435, + (opcode_handler_t)436, + (opcode_handler_t)437, + (opcode_handler_t)-1, + (opcode_handler_t)439, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)445, + (opcode_handler_t)446, + (opcode_handler_t)447, + (opcode_handler_t)-1, + (opcode_handler_t)449, + (opcode_handler_t)450, + (opcode_handler_t)451, + (opcode_handler_t)452, + (opcode_handler_t)-1, + (opcode_handler_t)454, + (opcode_handler_t)455, + (opcode_handler_t)456, + (opcode_handler_t)457, + (opcode_handler_t)-1, + (opcode_handler_t)459, + (opcode_handler_t)460, + (opcode_handler_t)461, + (opcode_handler_t)462, + (opcode_handler_t)-1, + (opcode_handler_t)464, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)470, + (opcode_handler_t)471, + (opcode_handler_t)472, + (opcode_handler_t)-1, + (opcode_handler_t)474, + (opcode_handler_t)475, + (opcode_handler_t)476, + (opcode_handler_t)477, + (opcode_handler_t)-1, + (opcode_handler_t)479, + (opcode_handler_t)480, + (opcode_handler_t)481, + (opcode_handler_t)482, + (opcode_handler_t)-1, + (opcode_handler_t)484, + (opcode_handler_t)485, + (opcode_handler_t)486, + (opcode_handler_t)487, + (opcode_handler_t)-1, + (opcode_handler_t)489, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)495, + (opcode_handler_t)496, + (opcode_handler_t)497, + (opcode_handler_t)-1, + (opcode_handler_t)499, + (opcode_handler_t)500, + (opcode_handler_t)501, + (opcode_handler_t)502, + (opcode_handler_t)-1, + (opcode_handler_t)504, + (opcode_handler_t)505, + (opcode_handler_t)506, + (opcode_handler_t)507, + (opcode_handler_t)-1, + (opcode_handler_t)509, + (opcode_handler_t)510, + (opcode_handler_t)511, + (opcode_handler_t)512, + (opcode_handler_t)-1, + (opcode_handler_t)514, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)520, + (opcode_handler_t)521, + (opcode_handler_t)522, + (opcode_handler_t)-1, + (opcode_handler_t)524, + (opcode_handler_t)525, + (opcode_handler_t)525, + (opcode_handler_t)525, + (opcode_handler_t)525, + (opcode_handler_t)525, + (opcode_handler_t)530, + (opcode_handler_t)530, + (opcode_handler_t)530, + (opcode_handler_t)530, + (opcode_handler_t)530, + (opcode_handler_t)535, + (opcode_handler_t)535, + (opcode_handler_t)535, + (opcode_handler_t)535, + (opcode_handler_t)535, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)545, + (opcode_handler_t)545, + (opcode_handler_t)545, + (opcode_handler_t)545, + (opcode_handler_t)545, + (opcode_handler_t)550, + (opcode_handler_t)550, + (opcode_handler_t)550, + (opcode_handler_t)550, + (opcode_handler_t)550, + (opcode_handler_t)555, + (opcode_handler_t)555, + (opcode_handler_t)555, + (opcode_handler_t)555, + (opcode_handler_t)555, + (opcode_handler_t)560, + (opcode_handler_t)560, + (opcode_handler_t)560, + (opcode_handler_t)560, + (opcode_handler_t)560, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)570, + (opcode_handler_t)570, + (opcode_handler_t)570, + (opcode_handler_t)570, + (opcode_handler_t)570, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)585, + (opcode_handler_t)586, + (opcode_handler_t)587, + (opcode_handler_t)588, + (opcode_handler_t)589, + (opcode_handler_t)590, + (opcode_handler_t)591, + (opcode_handler_t)592, + (opcode_handler_t)593, + (opcode_handler_t)594, + (opcode_handler_t)595, + (opcode_handler_t)596, + (opcode_handler_t)597, + (opcode_handler_t)598, + (opcode_handler_t)599, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)610, + (opcode_handler_t)611, + (opcode_handler_t)612, + (opcode_handler_t)613, + (opcode_handler_t)614, + (opcode_handler_t)615, + (opcode_handler_t)616, + (opcode_handler_t)617, + (opcode_handler_t)618, + (opcode_handler_t)619, + (opcode_handler_t)620, + (opcode_handler_t)621, + (opcode_handler_t)622, + (opcode_handler_t)623, + (opcode_handler_t)624, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)635, + (opcode_handler_t)636, + (opcode_handler_t)637, + (opcode_handler_t)638, + (opcode_handler_t)639, + (opcode_handler_t)640, + (opcode_handler_t)641, + (opcode_handler_t)642, + (opcode_handler_t)643, + (opcode_handler_t)644, + (opcode_handler_t)645, + (opcode_handler_t)646, + (opcode_handler_t)647, + (opcode_handler_t)648, + (opcode_handler_t)649, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)660, + (opcode_handler_t)661, + (opcode_handler_t)662, + (opcode_handler_t)663, + (opcode_handler_t)664, + (opcode_handler_t)665, + (opcode_handler_t)666, + (opcode_handler_t)667, + (opcode_handler_t)668, + (opcode_handler_t)669, + (opcode_handler_t)670, + (opcode_handler_t)671, + (opcode_handler_t)672, + (opcode_handler_t)673, + (opcode_handler_t)674, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)685, + (opcode_handler_t)686, + (opcode_handler_t)687, + (opcode_handler_t)688, + (opcode_handler_t)689, + (opcode_handler_t)690, + (opcode_handler_t)691, + (opcode_handler_t)692, + (opcode_handler_t)693, + (opcode_handler_t)694, + (opcode_handler_t)695, + (opcode_handler_t)696, + (opcode_handler_t)697, + (opcode_handler_t)698, + (opcode_handler_t)699, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)710, + (opcode_handler_t)711, + (opcode_handler_t)712, + (opcode_handler_t)713, + (opcode_handler_t)714, + (opcode_handler_t)715, + (opcode_handler_t)716, + (opcode_handler_t)717, + (opcode_handler_t)718, + (opcode_handler_t)719, + (opcode_handler_t)720, + (opcode_handler_t)721, + (opcode_handler_t)722, + (opcode_handler_t)723, + (opcode_handler_t)724, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)735, + (opcode_handler_t)736, + (opcode_handler_t)737, + (opcode_handler_t)738, + (opcode_handler_t)739, + (opcode_handler_t)740, + (opcode_handler_t)741, + (opcode_handler_t)742, + (opcode_handler_t)743, + (opcode_handler_t)744, + (opcode_handler_t)745, + (opcode_handler_t)746, + (opcode_handler_t)747, + (opcode_handler_t)748, + (opcode_handler_t)749, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)760, + (opcode_handler_t)761, + (opcode_handler_t)762, + (opcode_handler_t)763, + (opcode_handler_t)764, + (opcode_handler_t)765, + (opcode_handler_t)766, + (opcode_handler_t)767, + (opcode_handler_t)768, + (opcode_handler_t)769, + (opcode_handler_t)770, + (opcode_handler_t)771, + (opcode_handler_t)772, + (opcode_handler_t)773, + (opcode_handler_t)774, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)785, + (opcode_handler_t)786, + (opcode_handler_t)787, + (opcode_handler_t)788, + (opcode_handler_t)789, + (opcode_handler_t)790, + (opcode_handler_t)791, + (opcode_handler_t)792, + (opcode_handler_t)793, + (opcode_handler_t)794, + (opcode_handler_t)795, + (opcode_handler_t)796, + (opcode_handler_t)797, + (opcode_handler_t)798, + (opcode_handler_t)799, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)810, + (opcode_handler_t)811, + (opcode_handler_t)812, + (opcode_handler_t)813, + (opcode_handler_t)814, + (opcode_handler_t)815, + (opcode_handler_t)816, + (opcode_handler_t)817, + (opcode_handler_t)818, + (opcode_handler_t)819, + (opcode_handler_t)820, + (opcode_handler_t)821, + (opcode_handler_t)822, + (opcode_handler_t)823, + (opcode_handler_t)824, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)835, + (opcode_handler_t)836, + (opcode_handler_t)837, + (opcode_handler_t)838, + (opcode_handler_t)839, + (opcode_handler_t)840, + (opcode_handler_t)841, + (opcode_handler_t)842, + (opcode_handler_t)843, + (opcode_handler_t)844, + (opcode_handler_t)845, + (opcode_handler_t)846, + (opcode_handler_t)847, + (opcode_handler_t)848, + (opcode_handler_t)849, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)860, + (opcode_handler_t)860, + (opcode_handler_t)860, + (opcode_handler_t)860, + (opcode_handler_t)860, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)870, + (opcode_handler_t)870, + (opcode_handler_t)870, + (opcode_handler_t)870, + (opcode_handler_t)870, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)885, + (opcode_handler_t)885, + (opcode_handler_t)885, + (opcode_handler_t)885, + (opcode_handler_t)885, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)895, + (opcode_handler_t)895, + (opcode_handler_t)895, + (opcode_handler_t)895, + (opcode_handler_t)895, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)910, + (opcode_handler_t)910, + (opcode_handler_t)910, + (opcode_handler_t)910, + (opcode_handler_t)910, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)920, + (opcode_handler_t)920, + (opcode_handler_t)920, + (opcode_handler_t)920, + (opcode_handler_t)920, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)935, + (opcode_handler_t)935, + (opcode_handler_t)935, + (opcode_handler_t)935, + (opcode_handler_t)935, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)945, + (opcode_handler_t)945, + (opcode_handler_t)945, + (opcode_handler_t)945, + (opcode_handler_t)945, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)960, + (opcode_handler_t)961, + (opcode_handler_t)962, + (opcode_handler_t)-1, + (opcode_handler_t)964, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)970, + (opcode_handler_t)971, + (opcode_handler_t)972, + (opcode_handler_t)-1, + (opcode_handler_t)974, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)987, + (opcode_handler_t)-1, + (opcode_handler_t)989, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)997, + (opcode_handler_t)-1, + (opcode_handler_t)999, + (opcode_handler_t)1000, + (opcode_handler_t)1000, + (opcode_handler_t)1000, + (opcode_handler_t)1000, + (opcode_handler_t)1000, + (opcode_handler_t)1005, + (opcode_handler_t)1005, + (opcode_handler_t)1005, + (opcode_handler_t)1005, + (opcode_handler_t)1005, + (opcode_handler_t)1010, + (opcode_handler_t)1010, + (opcode_handler_t)1010, + (opcode_handler_t)1010, + (opcode_handler_t)1010, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1020, + (opcode_handler_t)1020, + (opcode_handler_t)1020, + (opcode_handler_t)1020, + (opcode_handler_t)1020, + (opcode_handler_t)1025, + (opcode_handler_t)1025, + (opcode_handler_t)1025, + (opcode_handler_t)1025, + (opcode_handler_t)1025, + (opcode_handler_t)1030, + (opcode_handler_t)1030, + (opcode_handler_t)1030, + (opcode_handler_t)1030, + (opcode_handler_t)1030, + (opcode_handler_t)1035, + (opcode_handler_t)1035, + (opcode_handler_t)1035, + (opcode_handler_t)1035, + (opcode_handler_t)1035, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1045, + (opcode_handler_t)1045, + (opcode_handler_t)1045, + (opcode_handler_t)1045, + (opcode_handler_t)1045, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1050, + (opcode_handler_t)1075, + (opcode_handler_t)1075, + (opcode_handler_t)1075, + (opcode_handler_t)1075, + (opcode_handler_t)1075, + (opcode_handler_t)1080, + (opcode_handler_t)1080, + (opcode_handler_t)1080, + (opcode_handler_t)1080, + (opcode_handler_t)1080, + (opcode_handler_t)1085, + (opcode_handler_t)1085, + (opcode_handler_t)1085, + (opcode_handler_t)1085, + (opcode_handler_t)1085, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1095, + (opcode_handler_t)1095, + (opcode_handler_t)1095, + (opcode_handler_t)1095, + (opcode_handler_t)1095, + (opcode_handler_t)1100, + (opcode_handler_t)1100, + (opcode_handler_t)1100, + (opcode_handler_t)1100, + (opcode_handler_t)1100, + (opcode_handler_t)1105, + (opcode_handler_t)1105, + (opcode_handler_t)1105, + (opcode_handler_t)1105, + (opcode_handler_t)1105, + (opcode_handler_t)1110, + (opcode_handler_t)1110, + (opcode_handler_t)1110, + (opcode_handler_t)1110, + (opcode_handler_t)1110, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1120, + (opcode_handler_t)1120, + (opcode_handler_t)1120, + (opcode_handler_t)1120, + (opcode_handler_t)1120, + (opcode_handler_t)1125, + (opcode_handler_t)1125, + (opcode_handler_t)1125, + (opcode_handler_t)1125, + (opcode_handler_t)1125, + (opcode_handler_t)1130, + (opcode_handler_t)1130, + (opcode_handler_t)1130, + (opcode_handler_t)1130, + (opcode_handler_t)1130, + (opcode_handler_t)1135, + (opcode_handler_t)1135, + (opcode_handler_t)1135, + (opcode_handler_t)1135, + (opcode_handler_t)1135, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1145, + (opcode_handler_t)1145, + (opcode_handler_t)1145, + (opcode_handler_t)1145, + (opcode_handler_t)1145, + (opcode_handler_t)1150, + (opcode_handler_t)1150, + (opcode_handler_t)1150, + (opcode_handler_t)1150, + (opcode_handler_t)1150, + (opcode_handler_t)1155, + (opcode_handler_t)1155, + (opcode_handler_t)1155, + (opcode_handler_t)1155, + (opcode_handler_t)1155, + (opcode_handler_t)1160, + (opcode_handler_t)1160, + (opcode_handler_t)1160, + (opcode_handler_t)1160, + (opcode_handler_t)1160, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1170, + (opcode_handler_t)1170, + (opcode_handler_t)1170, + (opcode_handler_t)1170, + (opcode_handler_t)1170, + (opcode_handler_t)1175, + (opcode_handler_t)1175, + (opcode_handler_t)1175, + (opcode_handler_t)1175, + (opcode_handler_t)1175, + (opcode_handler_t)1180, + (opcode_handler_t)1180, + (opcode_handler_t)1180, + (opcode_handler_t)1180, + (opcode_handler_t)1180, + (opcode_handler_t)1185, + (opcode_handler_t)1185, + (opcode_handler_t)1185, + (opcode_handler_t)1185, + (opcode_handler_t)1185, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1195, + (opcode_handler_t)1195, + (opcode_handler_t)1195, + (opcode_handler_t)1195, + (opcode_handler_t)1195, + (opcode_handler_t)1200, + (opcode_handler_t)1201, + (opcode_handler_t)1202, + (opcode_handler_t)-1, + (opcode_handler_t)1204, + (opcode_handler_t)1205, + (opcode_handler_t)1206, + (opcode_handler_t)1207, + (opcode_handler_t)-1, + (opcode_handler_t)1209, + (opcode_handler_t)1210, + (opcode_handler_t)1211, + (opcode_handler_t)1212, + (opcode_handler_t)-1, + (opcode_handler_t)1214, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1220, + (opcode_handler_t)1221, + (opcode_handler_t)1222, + (opcode_handler_t)-1, + (opcode_handler_t)1224, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1235, + (opcode_handler_t)1235, + (opcode_handler_t)1235, + (opcode_handler_t)1235, + (opcode_handler_t)1235, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1250, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1250, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1250, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1250, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1250, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1275, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1275, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1275, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1275, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1275, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1300, + (opcode_handler_t)1300, + (opcode_handler_t)1300, + (opcode_handler_t)1300, + (opcode_handler_t)1300, + (opcode_handler_t)1305, + (opcode_handler_t)1305, + (opcode_handler_t)1305, + (opcode_handler_t)1305, + (opcode_handler_t)1305, + (opcode_handler_t)1310, + (opcode_handler_t)1310, + (opcode_handler_t)1310, + (opcode_handler_t)1310, + (opcode_handler_t)1310, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1320, + (opcode_handler_t)1320, + (opcode_handler_t)1320, + (opcode_handler_t)1320, + (opcode_handler_t)1320, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)1325, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1355, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1365, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1380, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1390, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1406, + (opcode_handler_t)1407, + (opcode_handler_t)-1, + (opcode_handler_t)1409, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1416, + (opcode_handler_t)1417, + (opcode_handler_t)-1, + (opcode_handler_t)1419, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)1425, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1455, + (opcode_handler_t)1455, + (opcode_handler_t)1455, + (opcode_handler_t)1455, + (opcode_handler_t)1455, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1475, + (opcode_handler_t)1476, + (opcode_handler_t)1477, + (opcode_handler_t)-1, + (opcode_handler_t)1479, + (opcode_handler_t)1475, + (opcode_handler_t)1476, + (opcode_handler_t)1477, + (opcode_handler_t)-1, + (opcode_handler_t)1479, + (opcode_handler_t)1475, + (opcode_handler_t)1476, + (opcode_handler_t)1477, + (opcode_handler_t)-1, + (opcode_handler_t)1479, + (opcode_handler_t)1475, + (opcode_handler_t)1476, + (opcode_handler_t)1477, + (opcode_handler_t)-1, + (opcode_handler_t)1479, + (opcode_handler_t)1475, + (opcode_handler_t)1476, + (opcode_handler_t)1477, + (opcode_handler_t)-1, + (opcode_handler_t)1479, + (opcode_handler_t)1500, + (opcode_handler_t)1500, + (opcode_handler_t)1500, + (opcode_handler_t)1500, + (opcode_handler_t)1500, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1525, + (opcode_handler_t)1550, + (opcode_handler_t)1550, + (opcode_handler_t)1550, + (opcode_handler_t)1550, + (opcode_handler_t)1550, + (opcode_handler_t)1555, + (opcode_handler_t)1555, + (opcode_handler_t)1555, + (opcode_handler_t)1555, + (opcode_handler_t)1555, + (opcode_handler_t)1560, + (opcode_handler_t)1560, + (opcode_handler_t)1560, + (opcode_handler_t)1560, + (opcode_handler_t)1560, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1570, + (opcode_handler_t)1570, + (opcode_handler_t)1570, + (opcode_handler_t)1570, + (opcode_handler_t)1570, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1575, + (opcode_handler_t)1600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1625, + (opcode_handler_t)1625, + (opcode_handler_t)1625, + (opcode_handler_t)1625, + (opcode_handler_t)1625, + (opcode_handler_t)1630, + (opcode_handler_t)1630, + (opcode_handler_t)1630, + (opcode_handler_t)1630, + (opcode_handler_t)1630, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1660, + (opcode_handler_t)1660, + (opcode_handler_t)1660, + (opcode_handler_t)1660, + (opcode_handler_t)1660, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1670, + (opcode_handler_t)1670, + (opcode_handler_t)1670, + (opcode_handler_t)1670, + (opcode_handler_t)1670, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1685, + (opcode_handler_t)1685, + (opcode_handler_t)1685, + (opcode_handler_t)1685, + (opcode_handler_t)1685, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1695, + (opcode_handler_t)1695, + (opcode_handler_t)1695, + (opcode_handler_t)1695, + (opcode_handler_t)1695, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1700, + (opcode_handler_t)1725, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1725, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1725, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1725, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1725, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1755, + (opcode_handler_t)1755, + (opcode_handler_t)1755, + (opcode_handler_t)1755, + (opcode_handler_t)1755, + (opcode_handler_t)1760, + (opcode_handler_t)1760, + (opcode_handler_t)1760, + (opcode_handler_t)1760, + (opcode_handler_t)1760, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1775, + (opcode_handler_t)1776, + (opcode_handler_t)1777, + (opcode_handler_t)1778, + (opcode_handler_t)1779, + (opcode_handler_t)1780, + (opcode_handler_t)1781, + (opcode_handler_t)1782, + (opcode_handler_t)1783, + (opcode_handler_t)1784, + (opcode_handler_t)1785, + (opcode_handler_t)1786, + (opcode_handler_t)1787, + (opcode_handler_t)1788, + (opcode_handler_t)1789, + (opcode_handler_t)1790, + (opcode_handler_t)1791, + (opcode_handler_t)1792, + (opcode_handler_t)1793, + (opcode_handler_t)1794, + (opcode_handler_t)1795, + (opcode_handler_t)1796, + (opcode_handler_t)1797, + (opcode_handler_t)1798, + (opcode_handler_t)1799, + (opcode_handler_t)1800, + (opcode_handler_t)1801, + (opcode_handler_t)1802, + (opcode_handler_t)1803, + (opcode_handler_t)1804, + (opcode_handler_t)1805, + (opcode_handler_t)1806, + (opcode_handler_t)1807, + (opcode_handler_t)1808, + (opcode_handler_t)1809, + (opcode_handler_t)1810, + (opcode_handler_t)1811, + (opcode_handler_t)1812, + (opcode_handler_t)1813, + (opcode_handler_t)1814, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1820, + (opcode_handler_t)1821, + (opcode_handler_t)1822, + (opcode_handler_t)1823, + (opcode_handler_t)1824, + (opcode_handler_t)1825, + (opcode_handler_t)1825, + (opcode_handler_t)1825, + (opcode_handler_t)1825, + (opcode_handler_t)1825, + (opcode_handler_t)1830, + (opcode_handler_t)1830, + (opcode_handler_t)1830, + (opcode_handler_t)1830, + (opcode_handler_t)1830, + (opcode_handler_t)1835, + (opcode_handler_t)1835, + (opcode_handler_t)1835, + (opcode_handler_t)1835, + (opcode_handler_t)1835, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1845, + (opcode_handler_t)1845, + (opcode_handler_t)1845, + (opcode_handler_t)1845, + (opcode_handler_t)1845, + (opcode_handler_t)1850, + (opcode_handler_t)-1, + (opcode_handler_t)1852, + (opcode_handler_t)1853, + (opcode_handler_t)-1, + (opcode_handler_t)1855, + (opcode_handler_t)-1, + (opcode_handler_t)1857, + (opcode_handler_t)1858, + (opcode_handler_t)-1, + (opcode_handler_t)1860, + (opcode_handler_t)-1, + (opcode_handler_t)1862, + (opcode_handler_t)1863, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1870, + (opcode_handler_t)-1, + (opcode_handler_t)1872, + (opcode_handler_t)1873, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1885, + (opcode_handler_t)1886, + (opcode_handler_t)1887, + (opcode_handler_t)-1, + (opcode_handler_t)1889, + (opcode_handler_t)1890, + (opcode_handler_t)1891, + (opcode_handler_t)1892, + (opcode_handler_t)-1, + (opcode_handler_t)1894, + (opcode_handler_t)1895, + (opcode_handler_t)1896, + (opcode_handler_t)1897, + (opcode_handler_t)-1, + (opcode_handler_t)1899, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1910, + (opcode_handler_t)1911, + (opcode_handler_t)1912, + (opcode_handler_t)-1, + (opcode_handler_t)1914, + (opcode_handler_t)1915, + (opcode_handler_t)1916, + (opcode_handler_t)1917, + (opcode_handler_t)-1, + (opcode_handler_t)1919, + (opcode_handler_t)1920, + (opcode_handler_t)1921, + (opcode_handler_t)1922, + (opcode_handler_t)-1, + (opcode_handler_t)1924, + (opcode_handler_t)1925, + (opcode_handler_t)1925, + (opcode_handler_t)1925, + (opcode_handler_t)1925, + (opcode_handler_t)1925, + (opcode_handler_t)1930, + (opcode_handler_t)1930, + (opcode_handler_t)1930, + (opcode_handler_t)1930, + (opcode_handler_t)1930, + (opcode_handler_t)1935, + (opcode_handler_t)1935, + (opcode_handler_t)1935, + (opcode_handler_t)1935, + (opcode_handler_t)1935, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1945, + (opcode_handler_t)1945, + (opcode_handler_t)1945, + (opcode_handler_t)1945, + (opcode_handler_t)1945, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1960, + (opcode_handler_t)1960, + (opcode_handler_t)1960, + (opcode_handler_t)1960, + (opcode_handler_t)1960, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)1975, + (opcode_handler_t)1975, + (opcode_handler_t)1975, + (opcode_handler_t)1975, + (opcode_handler_t)1975, + (opcode_handler_t)1980, + (opcode_handler_t)1980, + (opcode_handler_t)1980, + (opcode_handler_t)1980, + (opcode_handler_t)1980, + (opcode_handler_t)1985, + (opcode_handler_t)1985, + (opcode_handler_t)1985, + (opcode_handler_t)1985, + (opcode_handler_t)1985, + (opcode_handler_t)1990, + (opcode_handler_t)1990, + (opcode_handler_t)1990, + (opcode_handler_t)1990, + (opcode_handler_t)1990, + (opcode_handler_t)1995, + (opcode_handler_t)1995, + (opcode_handler_t)1995, + (opcode_handler_t)1995, + (opcode_handler_t)1995, + (opcode_handler_t)2000, + (opcode_handler_t)-1, + (opcode_handler_t)2002, + (opcode_handler_t)2003, + (opcode_handler_t)-1, + (opcode_handler_t)2005, + (opcode_handler_t)-1, + (opcode_handler_t)2007, + (opcode_handler_t)2008, + (opcode_handler_t)-1, + (opcode_handler_t)2010, + (opcode_handler_t)-1, + (opcode_handler_t)2012, + (opcode_handler_t)2013, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2020, + (opcode_handler_t)-1, + (opcode_handler_t)2022, + (opcode_handler_t)2023, + (opcode_handler_t)-1, + (opcode_handler_t)2025, + (opcode_handler_t)2026, + (opcode_handler_t)2027, + (opcode_handler_t)-1, + (opcode_handler_t)2029, + (opcode_handler_t)2030, + (opcode_handler_t)2031, + (opcode_handler_t)2032, + (opcode_handler_t)-1, + (opcode_handler_t)2034, + (opcode_handler_t)2035, + (opcode_handler_t)2036, + (opcode_handler_t)2037, + (opcode_handler_t)-1, + (opcode_handler_t)2039, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2045, + (opcode_handler_t)2046, + (opcode_handler_t)2047, + (opcode_handler_t)-1, + (opcode_handler_t)2049, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2060, + (opcode_handler_t)2061, + (opcode_handler_t)2062, + (opcode_handler_t)-1, + (opcode_handler_t)2064, + (opcode_handler_t)2065, + (opcode_handler_t)2066, + (opcode_handler_t)2067, + (opcode_handler_t)-1, + (opcode_handler_t)2069, + (opcode_handler_t)2070, + (opcode_handler_t)2071, + (opcode_handler_t)2072, + (opcode_handler_t)-1, + (opcode_handler_t)2074, + (opcode_handler_t)2075, + (opcode_handler_t)-1, + (opcode_handler_t)2077, + (opcode_handler_t)2078, + (opcode_handler_t)-1, + (opcode_handler_t)2080, + (opcode_handler_t)-1, + (opcode_handler_t)2082, + (opcode_handler_t)2083, + (opcode_handler_t)-1, + (opcode_handler_t)2085, + (opcode_handler_t)-1, + (opcode_handler_t)2087, + (opcode_handler_t)2088, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2095, + (opcode_handler_t)-1, + (opcode_handler_t)2097, + (opcode_handler_t)2098, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2110, + (opcode_handler_t)2111, + (opcode_handler_t)2112, + (opcode_handler_t)2113, + (opcode_handler_t)2114, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2120, + (opcode_handler_t)2121, + (opcode_handler_t)2122, + (opcode_handler_t)2123, + (opcode_handler_t)2124, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2135, + (opcode_handler_t)2136, + (opcode_handler_t)2137, + (opcode_handler_t)-1, + (opcode_handler_t)2139, + (opcode_handler_t)2140, + (opcode_handler_t)2141, + (opcode_handler_t)2142, + (opcode_handler_t)-1, + (opcode_handler_t)2144, + (opcode_handler_t)2145, + (opcode_handler_t)2146, + (opcode_handler_t)2147, + (opcode_handler_t)-1, + (opcode_handler_t)2149, + (opcode_handler_t)2150, + (opcode_handler_t)-1, + (opcode_handler_t)2152, + (opcode_handler_t)2153, + (opcode_handler_t)-1, + (opcode_handler_t)2155, + (opcode_handler_t)-1, + (opcode_handler_t)2157, + (opcode_handler_t)2158, + (opcode_handler_t)-1, + (opcode_handler_t)2160, + (opcode_handler_t)-1, + (opcode_handler_t)2162, + (opcode_handler_t)2163, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2170, + (opcode_handler_t)-1, + (opcode_handler_t)2172, + (opcode_handler_t)2173, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2185, + (opcode_handler_t)2186, + (opcode_handler_t)2187, + (opcode_handler_t)2188, + (opcode_handler_t)2189, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2195, + (opcode_handler_t)2196, + (opcode_handler_t)2197, + (opcode_handler_t)2198, + (opcode_handler_t)2199, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2210, + (opcode_handler_t)2211, + (opcode_handler_t)2212, + (opcode_handler_t)-1, + (opcode_handler_t)2214, + (opcode_handler_t)2215, + (opcode_handler_t)2216, + (opcode_handler_t)2217, + (opcode_handler_t)-1, + (opcode_handler_t)2219, + (opcode_handler_t)2220, + (opcode_handler_t)2221, + (opcode_handler_t)2222, + (opcode_handler_t)-1, + (opcode_handler_t)2224, + (opcode_handler_t)2225, + (opcode_handler_t)-1, + (opcode_handler_t)2227, + (opcode_handler_t)2228, + (opcode_handler_t)-1, + (opcode_handler_t)2230, + (opcode_handler_t)-1, + (opcode_handler_t)2232, + (opcode_handler_t)2233, + (opcode_handler_t)-1, + (opcode_handler_t)2235, + (opcode_handler_t)-1, + (opcode_handler_t)2237, + (opcode_handler_t)2238, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2245, + (opcode_handler_t)-1, + (opcode_handler_t)2247, + (opcode_handler_t)2248, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2260, + (opcode_handler_t)2261, + (opcode_handler_t)2262, + (opcode_handler_t)-1, + (opcode_handler_t)2264, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2270, + (opcode_handler_t)2271, + (opcode_handler_t)2272, + (opcode_handler_t)-1, + (opcode_handler_t)2274, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2285, + (opcode_handler_t)2286, + (opcode_handler_t)2287, + (opcode_handler_t)-1, + (opcode_handler_t)2289, + (opcode_handler_t)2290, + (opcode_handler_t)2291, + (opcode_handler_t)2292, + (opcode_handler_t)-1, + (opcode_handler_t)2294, + (opcode_handler_t)2295, + (opcode_handler_t)2296, + (opcode_handler_t)2297, + (opcode_handler_t)-1, + (opcode_handler_t)2299, + (opcode_handler_t)2300, + (opcode_handler_t)-1, + (opcode_handler_t)2302, + (opcode_handler_t)2303, + (opcode_handler_t)-1, + (opcode_handler_t)2305, + (opcode_handler_t)-1, + (opcode_handler_t)2307, + (opcode_handler_t)2308, + (opcode_handler_t)-1, + (opcode_handler_t)2310, + (opcode_handler_t)-1, + (opcode_handler_t)2312, + (opcode_handler_t)2313, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2320, + (opcode_handler_t)-1, + (opcode_handler_t)2322, + (opcode_handler_t)2323, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2335, + (opcode_handler_t)2336, + (opcode_handler_t)2337, + (opcode_handler_t)2338, + (opcode_handler_t)2339, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2345, + (opcode_handler_t)2346, + (opcode_handler_t)2347, + (opcode_handler_t)2348, + (opcode_handler_t)2349, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2360, + (opcode_handler_t)2361, + (opcode_handler_t)2362, + (opcode_handler_t)-1, + (opcode_handler_t)2364, + (opcode_handler_t)2365, + (opcode_handler_t)2366, + (opcode_handler_t)2367, + (opcode_handler_t)-1, + (opcode_handler_t)2369, + (opcode_handler_t)2370, + (opcode_handler_t)2371, + (opcode_handler_t)2372, + (opcode_handler_t)-1, + (opcode_handler_t)2374, + (opcode_handler_t)2375, + (opcode_handler_t)-1, + (opcode_handler_t)2377, + (opcode_handler_t)2378, + (opcode_handler_t)-1, + (opcode_handler_t)2380, + (opcode_handler_t)-1, + (opcode_handler_t)2382, + (opcode_handler_t)2383, + (opcode_handler_t)-1, + (opcode_handler_t)2385, + (opcode_handler_t)-1, + (opcode_handler_t)2387, + (opcode_handler_t)2388, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2395, + (opcode_handler_t)-1, + (opcode_handler_t)2397, + (opcode_handler_t)2398, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2410, + (opcode_handler_t)2411, + (opcode_handler_t)2412, + (opcode_handler_t)-1, + (opcode_handler_t)2414, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2420, + (opcode_handler_t)2421, + (opcode_handler_t)2422, + (opcode_handler_t)-1, + (opcode_handler_t)2424, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2435, + (opcode_handler_t)2436, + (opcode_handler_t)2437, + (opcode_handler_t)-1, + (opcode_handler_t)2439, + (opcode_handler_t)2440, + (opcode_handler_t)2441, + (opcode_handler_t)2442, + (opcode_handler_t)-1, + (opcode_handler_t)2444, + (opcode_handler_t)2445, + (opcode_handler_t)2446, + (opcode_handler_t)2447, + (opcode_handler_t)-1, + (opcode_handler_t)2449, + (opcode_handler_t)2450, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2455, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2475, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2485, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2490, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2500, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2500, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2500, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2500, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2500, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2525, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2550, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2575, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2600, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)2625, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2660, + (opcode_handler_t)2660, + (opcode_handler_t)2660, + (opcode_handler_t)2660, + (opcode_handler_t)2660, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2670, + (opcode_handler_t)2670, + (opcode_handler_t)2670, + (opcode_handler_t)2670, + (opcode_handler_t)2670, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2679, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2700, + (opcode_handler_t)2700, + (opcode_handler_t)2700, + (opcode_handler_t)2700, + (opcode_handler_t)2700, + (opcode_handler_t)2705, + (opcode_handler_t)2705, + (opcode_handler_t)2705, + (opcode_handler_t)2705, + (opcode_handler_t)2705, + (opcode_handler_t)2710, + (opcode_handler_t)2710, + (opcode_handler_t)2710, + (opcode_handler_t)2710, + (opcode_handler_t)2710, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2720, + (opcode_handler_t)2720, + (opcode_handler_t)2720, + (opcode_handler_t)2720, + (opcode_handler_t)2720, + (opcode_handler_t)2725, + (opcode_handler_t)2726, + (opcode_handler_t)2727, + (opcode_handler_t)2728, + (opcode_handler_t)2729, + (opcode_handler_t)2725, + (opcode_handler_t)2726, + (opcode_handler_t)2727, + (opcode_handler_t)2728, + (opcode_handler_t)2729, + (opcode_handler_t)2725, + (opcode_handler_t)2726, + (opcode_handler_t)2727, + (opcode_handler_t)2728, + (opcode_handler_t)2729, + (opcode_handler_t)2725, + (opcode_handler_t)2726, + (opcode_handler_t)2727, + (opcode_handler_t)2728, + (opcode_handler_t)2729, + (opcode_handler_t)2725, + (opcode_handler_t)2726, + (opcode_handler_t)2727, + (opcode_handler_t)2728, + (opcode_handler_t)2729, + (opcode_handler_t)2750, + (opcode_handler_t)2750, + (opcode_handler_t)2750, + (opcode_handler_t)2750, + (opcode_handler_t)2750, + (opcode_handler_t)2755, + (opcode_handler_t)2755, + (opcode_handler_t)2755, + (opcode_handler_t)2755, + (opcode_handler_t)2755, + (opcode_handler_t)2760, + (opcode_handler_t)2760, + (opcode_handler_t)2760, + (opcode_handler_t)2760, + (opcode_handler_t)2760, + (opcode_handler_t)2765, + (opcode_handler_t)2765, + (opcode_handler_t)2765, + (opcode_handler_t)2765, + (opcode_handler_t)2765, + (opcode_handler_t)2770, + (opcode_handler_t)2770, + (opcode_handler_t)2770, + (opcode_handler_t)2770, + (opcode_handler_t)2770, + (opcode_handler_t)2775, + (opcode_handler_t)2775, + (opcode_handler_t)2775, + (opcode_handler_t)2775, + (opcode_handler_t)2775, + (opcode_handler_t)2780, + (opcode_handler_t)2780, + (opcode_handler_t)2780, + (opcode_handler_t)2780, + (opcode_handler_t)2780, + (opcode_handler_t)2785, + (opcode_handler_t)2785, + (opcode_handler_t)2785, + (opcode_handler_t)2785, + (opcode_handler_t)2785, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2795, + (opcode_handler_t)2795, + (opcode_handler_t)2795, + (opcode_handler_t)2795, + (opcode_handler_t)2795, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2805, + (opcode_handler_t)2806, + (opcode_handler_t)2807, + (opcode_handler_t)-1, + (opcode_handler_t)2809, + (opcode_handler_t)2810, + (opcode_handler_t)2811, + (opcode_handler_t)2812, + (opcode_handler_t)-1, + (opcode_handler_t)2814, + (opcode_handler_t)2815, + (opcode_handler_t)2816, + (opcode_handler_t)2817, + (opcode_handler_t)-1, + (opcode_handler_t)2819, + (opcode_handler_t)2820, + (opcode_handler_t)2821, + (opcode_handler_t)2822, + (opcode_handler_t)-1, + (opcode_handler_t)2824, + (opcode_handler_t)2825, + (opcode_handler_t)2826, + (opcode_handler_t)2827, + (opcode_handler_t)2828, + (opcode_handler_t)2829, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2835, + (opcode_handler_t)2836, + (opcode_handler_t)2837, + (opcode_handler_t)2838, + (opcode_handler_t)2839, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2850, + (opcode_handler_t)-1, + (opcode_handler_t)2852, + (opcode_handler_t)2853, + (opcode_handler_t)-1, + (opcode_handler_t)2855, + (opcode_handler_t)-1, + (opcode_handler_t)2857, + (opcode_handler_t)2858, + (opcode_handler_t)-1, + (opcode_handler_t)2860, + (opcode_handler_t)-1, + (opcode_handler_t)2862, + (opcode_handler_t)2863, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2870, + (opcode_handler_t)-1, + (opcode_handler_t)2872, + (opcode_handler_t)2873, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)2885, + (opcode_handler_t)2886, + (opcode_handler_t)2887, + (opcode_handler_t)-1, + (opcode_handler_t)2889, + (opcode_handler_t)2890, + (opcode_handler_t)2891, + (opcode_handler_t)2892, + (opcode_handler_t)-1, + (opcode_handler_t)2894, + (opcode_handler_t)2895, + (opcode_handler_t)2896, + (opcode_handler_t)2897, + (opcode_handler_t)-1, + (opcode_handler_t)2899, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3310, + (opcode_handler_t)3311, + (opcode_handler_t)3312, + (opcode_handler_t)-1, + (opcode_handler_t)3314, + (opcode_handler_t)3315, + (opcode_handler_t)3316, + (opcode_handler_t)3317, + (opcode_handler_t)-1, + (opcode_handler_t)3319, + (opcode_handler_t)3320, + (opcode_handler_t)3321, + (opcode_handler_t)3322, + (opcode_handler_t)-1, + (opcode_handler_t)3324, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3335, + (opcode_handler_t)3336, + (opcode_handler_t)3337, + (opcode_handler_t)-1, + (opcode_handler_t)3339, + (opcode_handler_t)3340, + (opcode_handler_t)3341, + (opcode_handler_t)3342, + (opcode_handler_t)-1, + (opcode_handler_t)3344, + (opcode_handler_t)3345, + (opcode_handler_t)3346, + (opcode_handler_t)3347, + (opcode_handler_t)-1, + (opcode_handler_t)3349, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3360, + (opcode_handler_t)3361, + (opcode_handler_t)3362, + (opcode_handler_t)-1, + (opcode_handler_t)3364, + (opcode_handler_t)3365, + (opcode_handler_t)3366, + (opcode_handler_t)3367, + (opcode_handler_t)-1, + (opcode_handler_t)3369, + (opcode_handler_t)3370, + (opcode_handler_t)3371, + (opcode_handler_t)3372, + (opcode_handler_t)-1, + (opcode_handler_t)3374, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3385, + (opcode_handler_t)3386, + (opcode_handler_t)3387, + (opcode_handler_t)-1, + (opcode_handler_t)3389, + (opcode_handler_t)3390, + (opcode_handler_t)3391, + (opcode_handler_t)3392, + (opcode_handler_t)-1, + (opcode_handler_t)3394, + (opcode_handler_t)3395, + (opcode_handler_t)3396, + (opcode_handler_t)3397, + (opcode_handler_t)-1, + (opcode_handler_t)3399, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3410, + (opcode_handler_t)3411, + (opcode_handler_t)3412, + (opcode_handler_t)-1, + (opcode_handler_t)3414, + (opcode_handler_t)3415, + (opcode_handler_t)3416, + (opcode_handler_t)3417, + (opcode_handler_t)-1, + (opcode_handler_t)3419, + (opcode_handler_t)3420, + (opcode_handler_t)3421, + (opcode_handler_t)3422, + (opcode_handler_t)-1, + (opcode_handler_t)3424, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3455, + (opcode_handler_t)3455, + (opcode_handler_t)3455, + (opcode_handler_t)3455, + (opcode_handler_t)3455, + (opcode_handler_t)3460, + (opcode_handler_t)3460, + (opcode_handler_t)3460, + (opcode_handler_t)3460, + (opcode_handler_t)3460, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3470, + (opcode_handler_t)3470, + (opcode_handler_t)3470, + (opcode_handler_t)3470, + (opcode_handler_t)3470, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3475, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3500, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3525, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3550, + (opcode_handler_t)3575, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3600, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3625, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)3650, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3685, + (opcode_handler_t)3686, + (opcode_handler_t)3687, + (opcode_handler_t)3688, + (opcode_handler_t)3689, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3695, + (opcode_handler_t)3696, + (opcode_handler_t)3697, + (opcode_handler_t)3698, + (opcode_handler_t)3699, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3710, + (opcode_handler_t)3711, + (opcode_handler_t)3712, + (opcode_handler_t)-1, + (opcode_handler_t)3714, + (opcode_handler_t)3715, + (opcode_handler_t)3716, + (opcode_handler_t)3717, + (opcode_handler_t)-1, + (opcode_handler_t)3719, + (opcode_handler_t)3720, + (opcode_handler_t)3721, + (opcode_handler_t)3722, + (opcode_handler_t)-1, + (opcode_handler_t)3724, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3725, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)3750, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3800, + (opcode_handler_t)3800, + (opcode_handler_t)3800, + (opcode_handler_t)3800, + (opcode_handler_t)3800, + (opcode_handler_t)3805, + (opcode_handler_t)3805, + (opcode_handler_t)3805, + (opcode_handler_t)3805, + (opcode_handler_t)3805, + (opcode_handler_t)3810, + (opcode_handler_t)3810, + (opcode_handler_t)3810, + (opcode_handler_t)3810, + (opcode_handler_t)3810, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3820, + (opcode_handler_t)3820, + (opcode_handler_t)3820, + (opcode_handler_t)3820, + (opcode_handler_t)3820, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3828, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3850, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)3875, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3913, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3925, + (opcode_handler_t)3925, + (opcode_handler_t)3925, + (opcode_handler_t)3925, + (opcode_handler_t)3925, + (opcode_handler_t)3930, + (opcode_handler_t)3930, + (opcode_handler_t)3930, + (opcode_handler_t)3930, + (opcode_handler_t)3930, + (opcode_handler_t)3935, + (opcode_handler_t)3935, + (opcode_handler_t)3935, + (opcode_handler_t)3935, + (opcode_handler_t)3935, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3945, + (opcode_handler_t)3945, + (opcode_handler_t)3945, + (opcode_handler_t)3945, + (opcode_handler_t)3945, + (opcode_handler_t)3950, + (opcode_handler_t)3950, + (opcode_handler_t)3950, + (opcode_handler_t)3950, + (opcode_handler_t)3950, + (opcode_handler_t)3955, + (opcode_handler_t)3955, + (opcode_handler_t)3955, + (opcode_handler_t)3955, + (opcode_handler_t)3955, + (opcode_handler_t)3960, + (opcode_handler_t)3960, + (opcode_handler_t)3960, + (opcode_handler_t)3960, + (opcode_handler_t)3960, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)-1, + (opcode_handler_t)3970, + (opcode_handler_t)3970, + (opcode_handler_t)3970, + (opcode_handler_t)3970, + (opcode_handler_t)3970, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)3975, + (opcode_handler_t)4000, + (opcode_handler_t)4001, + (opcode_handler_t)4002, + (opcode_handler_t)4003, + (opcode_handler_t)4004, + (opcode_handler_t)4005, + (opcode_handler_t)4006, + (opcode_handler_t)4007, + (opcode_handler_t)4008, + (opcode_handler_t)4009, + (opcode_handler_t)4010, + (opcode_handler_t)4011, + (opcode_handler_t)4012, + (opcode_handler_t)4013, + (opcode_handler_t)4014, + (opcode_handler_t)4015, + (opcode_handler_t)4016, + (opcode_handler_t)4017, + (opcode_handler_t)4018, + (opcode_handler_t)4019, + (opcode_handler_t)4020, + (opcode_handler_t)4021, + (opcode_handler_t)4022, + (opcode_handler_t)4023, + (opcode_handler_t)4024, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4025, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4050, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)4075, + (opcode_handler_t)-1 }; zend_opcode_handlers = (opcode_handler_t*)labels; } @@ -44962,8 +44957,210 @@ ZEND_API void zend_vm_set_opcode_handler(zend_op* op) op->handler = zend_vm_get_opcode_handler(zend_user_opcodes[op->opcode], op); } +#undef OPLINE +#undef DCL_OPLINE +#undef USE_OPLINE +#undef LOAD_OPLINE +#undef SAVE_OPLINE +#define OPLINE EX(opline) +#define DCL_OPLINE +#define USE_OPLINE zend_op *opline = EX(opline); +#define LOAD_OPLINE() +#define SAVE_OPLINE() +#undef CHECK_EXCEPTION +#undef HANDLE_EXCEPTION +#undef HANDLE_EXCEPTION_LEAVE +#define CHECK_EXCEPTION() LOAD_OPLINE() +#define HANDLE_EXCEPTION() LOAD_OPLINE(); ZEND_VM_CONTINUE() +#define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE() +#undef ZEND_VM_CONTINUE +#undef ZEND_VM_RETURN +#undef ZEND_VM_ENTER +#undef ZEND_VM_LEAVE +#undef ZEND_VM_DISPATCH +#undef ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL + +#define ZEND_VM_CONTINUE() return 0 +#define ZEND_VM_RETURN() return 1 +#define ZEND_VM_ENTER() return 2 +#define ZEND_VM_LEAVE() return 3 +#define ZEND_VM_DISPATCH(opcode, opline) return zend_vm_get_opcode_handler(opcode, opline)(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + +#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC + ZEND_API int zend_do_fcall(ZEND_OPCODE_HANDLER_ARGS) { - return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); + USE_OPLINE + zend_bool should_change_scope = 0; + zend_function *fbc = EX(function_state).function; + + SAVE_OPLINE(); + EX(object) = EX(call)->object; + if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { + if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { + zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); + } + if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { + zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", + fbc->common.scope ? fbc->common.scope->name : "", + fbc->common.scope ? "::" : "", + fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } + } + if (fbc->common.scope && + !(fbc->common.fn_flags & ZEND_ACC_STATIC) && + !EX(object)) { + + if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { + /* FIXME: output identifiers properly */ + zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } + } else { + /* FIXME: output identifiers properly */ + /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ + zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically", fbc->common.scope->name, fbc->common.function_name); + } + } + + if (fbc->type == ZEND_USER_FUNCTION || fbc->common.scope) { + should_change_scope = 1; + EX(current_this) = EG(This); + EX(current_scope) = EG(scope); + EX(current_called_scope) = EG(called_scope); + EG(This) = EX(object); + EG(scope) = (fbc->type == ZEND_USER_FUNCTION || !EX(object)) ? fbc->common.scope : NULL; + EG(called_scope) = EX(call)->called_scope; + } + + EX(function_state).arguments = zend_vm_stack_top(TSRMLS_C); + zend_vm_stack_push((void*)(zend_uintptr_t)opline->extended_value TSRMLS_CC); + LOAD_OPLINE(); + + if (fbc->type == ZEND_INTERNAL_FUNCTION) { + temp_variable *ret = &EX_T(opline->result.var); + + MAKE_STD_ZVAL(ret->var.ptr); + ZVAL_NULL(ret->var.ptr); + ret->var.ptr_ptr = &ret->var.ptr; + ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; + + if (fbc->common.arg_info) { + zend_uint i=0; + zval **p = (zval**)EX(function_state).arguments; + ulong arg_count = opline->extended_value; + + while (arg_count>0) { + zend_verify_arg_type(fbc, ++i, *(p-arg_count), 0 TSRMLS_CC); + arg_count--; + } + } + + if (!zend_execute_internal) { + /* saves one function call if zend_execute_internal is not used */ + fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); + } else { + zend_execute_internal(execute_data, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC); + } + + if (!RETURN_VALUE_USED(opline)) { + zval_ptr_dtor(&ret->var.ptr); + } + } else if (fbc->type == ZEND_USER_FUNCTION) { + EX(original_return_value) = EG(return_value_ptr_ptr); + EG(active_symbol_table) = NULL; + EG(active_op_array) = &fbc->op_array; + EG(return_value_ptr_ptr) = NULL; + if (RETURN_VALUE_USED(opline)) { + temp_variable *ret = &EX_T(opline->result.var); + + ret->var.ptr = NULL; + EG(return_value_ptr_ptr) = &ret->var.ptr; + ret->var.ptr_ptr = &ret->var.ptr; + ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; + } + + if (UNEXPECTED((EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { + if (RETURN_VALUE_USED(opline)) { + EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); + } + } else if (EXPECTED(zend_execute_ex == execute_ex)) { + if (EXPECTED(EG(exception) == NULL)) { + ZEND_VM_ENTER(); + } + } else { + zend_execute(EG(active_op_array) TSRMLS_CC); + } + + EG(opline_ptr) = &EX(opline); + EG(active_op_array) = EX(op_array); + EG(return_value_ptr_ptr) = EX(original_return_value); + if (EG(active_symbol_table)) { + zend_clean_and_cache_symbol_table(EG(active_symbol_table) TSRMLS_CC); + } + EG(active_symbol_table) = EX(symbol_table); + } else { /* ZEND_OVERLOADED_FUNCTION */ + MAKE_STD_ZVAL(EX_T(opline->result.var).var.ptr); + ZVAL_NULL(EX_T(opline->result.var).var.ptr); + + /* Not sure what should be done here if it's a static method */ + if (EXPECTED(EX(object) != NULL)) { + Z_OBJ_HT_P(EX(object))->call_method(fbc->common.function_name, opline->extended_value, EX_T(opline->result.var).var.ptr, &EX_T(opline->result.var).var.ptr, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); + } else { + zend_error_noreturn(E_ERROR, "Cannot call overloaded function for non-object"); + } + + if (fbc->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY) { + efree((char*)fbc->common.function_name); + } + efree(fbc); + + if (!RETURN_VALUE_USED(opline)) { + zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); + } else { + Z_UNSET_ISREF_P(EX_T(opline->result.var).var.ptr); + Z_SET_REFCOUNT_P(EX_T(opline->result.var).var.ptr, 1); + EX_T(opline->result.var).var.fcall_returned_reference = 0; + EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; + } + } + + EX(function_state).function = (zend_function *) EX(op_array); + EX(function_state).arguments = NULL; + + if (should_change_scope) { + if (EG(This)) { + if (UNEXPECTED(EG(exception) != NULL) && EX(call)->is_ctor_call) { + if (EX(call)->is_ctor_result_used) { + Z_DELREF_P(EG(This)); + } + if (Z_REFCOUNT_P(EG(This)) == 1) { + zend_object_store_ctor_failed(EG(This) TSRMLS_CC); + } + } + zval_ptr_dtor(&EG(This)); + } + EG(This) = EX(current_this); + EG(scope) = EX(current_scope); + EG(called_scope) = EX(current_called_scope); + } + + EX(call)--; + + zend_vm_stack_clear_multiple(1 TSRMLS_CC); + + if (UNEXPECTED(EG(exception) != NULL)) { + zend_throw_exception_internal(NULL TSRMLS_CC); + if (RETURN_VALUE_USED(opline) && EX_T(opline->result.var).var.ptr) { + zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); + } + HANDLE_EXCEPTION(); + } + + ZEND_VM_NEXT_OPCODE(); } From d3ec9ceb25ba570baebe89dff3e376232b97ab45 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 18 Dec 2012 15:27:54 +0800 Subject: [PATCH 2219/2394] Revert "Fixed bug that exception won't be catched" This reverts commit 28db07a0e39ee593edc843ce3c162da247eb2bbe. Unexpected vm kind change --- Zend/zend_vm_def.h | 8 +- Zend/zend_vm_execute.h | 11959 +++++++++++++++++++-------------------- 2 files changed, 5883 insertions(+), 6084 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index bfe6f722f317e..f7b10a29a68d9 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1942,15 +1942,14 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", fbc->common.scope ? fbc->common.scope->name : "", fbc->common.scope ? "::" : "", fbc->common.function_name); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } } } if (fbc->common.scope && @@ -1960,9 +1959,6 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { /* FIXME: output identifiers properly */ zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } } else { /* FIXME: output identifiers properly */ /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 23a886ca85f40..c077d5d2a5393 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -307,11 +307,11 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #undef USE_OPLINE #undef LOAD_OPLINE #undef SAVE_OPLINE -#define OPLINE opline -#define DCL_OPLINE zend_op *opline; -#define USE_OPLINE -#define LOAD_OPLINE() opline = EX(opline) -#define SAVE_OPLINE() EX(opline) = opline +#define OPLINE EX(opline) +#define DCL_OPLINE +#define USE_OPLINE zend_op *opline = EX(opline); +#define LOAD_OPLINE() +#define SAVE_OPLINE() #undef CHECK_EXCEPTION #undef HANDLE_EXCEPTION #undef HANDLE_EXCEPTION_LEAVE @@ -319,11 +319,11 @@ static opcode_handler_t zend_vm_get_opcode_handler(zend_uchar opcode, zend_op* o #define HANDLE_EXCEPTION() LOAD_OPLINE(); ZEND_VM_CONTINUE() #define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE() #define LOAD_REGS() -#define ZEND_VM_CONTINUE() goto zend_vm_continue -#define ZEND_VM_RETURN() EG(in_execution) = original_in_execution; return -#define ZEND_VM_ENTER() goto zend_vm_enter -#define ZEND_VM_LEAVE() ZEND_VM_CONTINUE() -#define ZEND_VM_DISPATCH(opcode, opline) dispatch_handler = zend_vm_get_opcode_handler(opcode, opline); goto zend_vm_dispatch; +#define ZEND_VM_CONTINUE() return 0 +#define ZEND_VM_RETURN() return 1 +#define ZEND_VM_ENTER() return 2 +#define ZEND_VM_LEAVE() return 3 +#define ZEND_VM_DISPATCH(opcode, opline) return zend_vm_get_opcode_handler(opcode, opline)(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC @@ -332,11 +332,6 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) DCL_OPLINE zend_bool original_in_execution; - opcode_handler_t dispatch_handler; - int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC); - incdec_t incdec_op; - int type; - int prop_dim; original_in_execution = EG(in_execution); @@ -351,17 +346,42 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) LOAD_OPLINE(); while (1) { -zend_vm_continue: + int ret; #ifdef ZEND_WIN32 if (EG(timed_out)) { zend_timeout(0); } #endif - dispatch_handler = OPLINE->handler; -zend_vm_dispatch: - switch ((int)dispatch_handler) { -zend_leave_helper_SPEC: + if ((ret = OPLINE->handler(execute_data TSRMLS_CC)) > 0) { + switch (ret) { + case 1: + EG(in_execution) = original_in_execution; + return; + case 2: + goto zend_vm_enter; + break; + case 3: + execute_data = EG(current_execute_data); + break; + default: + break; + } + } + + } + zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); +} + +ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) +{ + if (EG(exception)) { + return; + } + zend_execute_ex(i_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); +} + +static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) { zend_bool nested; zend_op_array *op_array = EX(op_array); @@ -451,7 +471,7 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) ZEND_VM_RETURN(); } -zend_do_fcall_common_helper_SPEC: +static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_bool should_change_scope = 0; @@ -462,15 +482,14 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); + CHECK_EXCEPTION(); + ZEND_VM_NEXT_OPCODE(); /* Never reached */ } if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", fbc->common.scope ? fbc->common.scope->name : "", fbc->common.scope ? "::" : "", fbc->common.function_name); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } } } if (fbc->common.scope && @@ -480,9 +499,6 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { /* FIXME: output identifiers properly */ zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } } else { /* FIXME: output identifiers properly */ /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ @@ -627,7 +643,7 @@ ZEND_API void execute_ex(zend_execute_data *execute_data TSRMLS_DC) ZEND_VM_NEXT_OPCODE(); } -case 1050: /*ZEND_JMP_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -638,7 +654,7 @@ case 1050: /*ZEND_JMP_SPEC_HANDLER*/ ZEND_VM_CONTINUE(); } -case 1325: /*ZEND_INIT_STRING_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STRING_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *tmp = &EX_T(opline->result.var).tmp_var; @@ -654,13 +670,13 @@ case 1325: /*ZEND_INIT_STRING_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1525: /*ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { EX(function_state).function = EX(call)->fbc; - goto zend_do_fcall_common_helper_SPEC; + return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4025: /*ZEND_GENERATOR_RETURN_SPEC_HANDLER*/ ZEND_GENERATOR_RETURN_SPEC_LABEL: +static int ZEND_FASTCALL ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { /* The generator object is stored in return_value_ptr_ptr */ zend_generator *generator = (zend_generator *) EG(return_value_ptr_ptr); @@ -672,7 +688,7 @@ case 4025: /*ZEND_GENERATOR_RETURN_SPEC_HANDLER*/ ZEND_GENERATOR_RETURN_SPEC_LAB ZEND_VM_RETURN(); } -case 1575: /*ZEND_RECV_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_RECV_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_uint arg_num = opline->op1.num; @@ -713,7 +729,7 @@ case 1575: /*ZEND_RECV_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1700: /*ZEND_NEW_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_NEW_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *object_zval; @@ -763,7 +779,7 @@ case 1700: /*ZEND_NEW_SPEC_HANDLER*/ } } -case 1425: /*ZEND_BEGIN_SILENCE_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_BEGIN_SILENCE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -804,14 +820,14 @@ case 1425: /*ZEND_BEGIN_SILENCE_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3550: /*ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { SAVE_OPLINE(); zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", EG(scope)->name, EX(op_array)->function_name); ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -case 2525: /*ZEND_EXT_STMT_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXT_STMT_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { SAVE_OPLINE(); if (!EG(no_extensions)) { @@ -821,7 +837,7 @@ case 2525: /*ZEND_EXT_STMT_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2550: /*ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { SAVE_OPLINE(); if (!EG(no_extensions)) { @@ -831,7 +847,7 @@ case 2550: /*ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2575: /*ZEND_EXT_FCALL_END_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXT_FCALL_END_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { SAVE_OPLINE(); if (!EG(no_extensions)) { @@ -841,7 +857,7 @@ case 2575: /*ZEND_EXT_FCALL_END_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3475: /*ZEND_DECLARE_CLASS_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_DECLARE_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -851,7 +867,7 @@ case 3475: /*ZEND_DECLARE_CLASS_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3500: /*ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -861,7 +877,7 @@ case 3500: /*ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3625: /*ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_class_entry **pce, **pce_orig; @@ -876,7 +892,7 @@ case 3625: /*ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3525: /*ZEND_DECLARE_FUNCTION_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_DECLARE_FUNCTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -886,7 +902,7 @@ case 3525: /*ZEND_DECLARE_FUNCTION_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2625: /*ZEND_TICKS_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_TICKS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -901,17 +917,17 @@ case 2625: /*ZEND_TICKS_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2600: /*ZEND_EXT_NOP_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXT_NOP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { ZEND_VM_NEXT_OPCODE(); } -case 0: /*ZEND_NOP_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_NOP_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { ZEND_VM_NEXT_OPCODE(); } -case 3850: /*ZEND_ADD_TRAIT_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_TRAIT_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_class_entry *ce = EX_T(opline->op1.var).class_entry; @@ -941,7 +957,7 @@ case 3850: /*ZEND_ADD_TRAIT_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3875: /*ZEND_BIND_TRAITS_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_BIND_TRAITS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_class_entry *ce = EX_T(opline->op1.var).class_entry; @@ -952,7 +968,7 @@ case 3875: /*ZEND_BIND_TRAITS_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3725: /*ZEND_HANDLE_EXCEPTION_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_HANDLE_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { zend_uint op_num = EG(opline_before_exception)-EG(active_op_array)->opcodes; int i; @@ -1051,14 +1067,14 @@ case 3725: /*ZEND_HANDLE_EXCEPTION_SPEC_HANDLER*/ ZEND_VM_CONTINUE(); } else { if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - goto ZEND_GENERATOR_RETURN_SPEC_LABEL; + return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } } -case 3650: /*ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1068,7 +1084,7 @@ case 3650: /*ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3750: /*ZEND_USER_OPCODE_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_USER_OPCODE_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE int ret; @@ -1082,9 +1098,9 @@ case 3750: /*ZEND_USER_OPCODE_SPEC_HANDLER*/ ZEND_VM_CONTINUE(); case ZEND_USER_OPCODE_RETURN: if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - goto ZEND_GENERATOR_RETURN_SPEC_LABEL; + return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } case ZEND_USER_OPCODE_ENTER: ZEND_VM_ENTER(); @@ -1097,7 +1113,7 @@ case 3750: /*ZEND_USER_OPCODE_SPEC_HANDLER*/ } } -case 3975: /*ZEND_DISCARD_EXCEPTION_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_DISCARD_EXCEPTION_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { if (EG(prev_exception) != NULL) { /* discard the previously thrown exception */ @@ -1108,7 +1124,7 @@ case 3975: /*ZEND_DISCARD_EXCEPTION_SPEC_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4050: /*ZEND_FAST_CALL_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_FAST_CALL_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1123,7 +1139,7 @@ case 4050: /*ZEND_FAST_CALL_SPEC_HANDLER*/ ZEND_VM_CONTINUE(); } -case 4075: /*ZEND_FAST_RET_SPEC_HANDLER*/ +static int ZEND_FASTCALL ZEND_FAST_RET_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { if (EX(fast_ret)) { ZEND_VM_SET_OPCODE(EX(fast_ret)); @@ -1141,15 +1157,15 @@ case 4075: /*ZEND_FAST_RET_SPEC_HANDLER*/ ZEND_VM_CONTINUE(); } else if (UNEXPECTED((EX(op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { zend_exception_restore(TSRMLS_C); - goto ZEND_GENERATOR_RETURN_SPEC_LABEL; + return ZEND_GENERATOR_RETURN_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zend_exception_restore(TSRMLS_C); - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } } -case 2725: /*ZEND_FETCH_CLASS_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1185,7 +1201,7 @@ case 2725: /*ZEND_FETCH_CLASS_SPEC_CONST_HANDLER*/ } } -case 1475: /*ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -1329,7 +1345,7 @@ case 1475: /*ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER*/ } -case 1725: /*ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_literal *func_name; @@ -1357,7 +1373,7 @@ case 1725: /*ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1600: /*ZEND_RECV_INIT_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_RECV_INIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *assignment_value; @@ -1391,7 +1407,7 @@ case 1600: /*ZEND_RECV_INIT_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1250: /*ZEND_BRK_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BRK_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_brk_cont_element *el; @@ -1403,7 +1419,7 @@ case 1250: /*ZEND_BRK_SPEC_CONST_HANDLER*/ ZEND_VM_JMP(EX(op_array)->opcodes + el->brk); } -case 1275: /*ZEND_CONT_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_brk_cont_element *el; @@ -1415,7 +1431,7 @@ case 1275: /*ZEND_CONT_SPEC_CONST_HANDLER*/ ZEND_VM_JMP(EX(op_array)->opcodes + el->cont); } -case 2500: /*ZEND_GOTO_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_GOTO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { zend_op *brk_opline; USE_OPLINE @@ -1442,7 +1458,7 @@ case 2500: /*ZEND_GOTO_SPEC_CONST_HANDLER*/ ZEND_VM_JMP(opline->op1.jmp_addr); } -case 3600: /*ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_class_entry *ce = EX_T(opline->op1.var).class_entry; @@ -1469,7 +1485,7 @@ case 3600: /*ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2726: /*ZEND_FETCH_CLASS_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1506,7 +1522,7 @@ case 2726: /*ZEND_FETCH_CLASS_SPEC_TMP_HANDLER*/ } } -case 1476: /*ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -1650,7 +1666,7 @@ case 1476: /*ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER*/ } -case 2727: /*ZEND_FETCH_CLASS_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1687,7 +1703,7 @@ case 2727: /*ZEND_FETCH_CLASS_SPEC_VAR_HANDLER*/ } } -case 1477: /*ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -1831,7 +1847,7 @@ case 1477: /*ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER*/ } -case 2728: /*ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1867,7 +1883,7 @@ case 2728: /*ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER*/ } } -case 2729: /*ZEND_FETCH_CLASS_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CLASS_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -1903,7 +1919,7 @@ case 2729: /*ZEND_FETCH_CLASS_SPEC_CV_HANDLER*/ } } -case 1479: /*ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -2047,7 +2063,7 @@ case 1479: /*ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER*/ } -case 300: /*ZEND_BW_NOT_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2060,7 +2076,7 @@ case 300: /*ZEND_BW_NOT_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 325: /*ZEND_BOOL_NOT_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2073,7 +2089,7 @@ case 325: /*ZEND_BOOL_NOT_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1000: /*ZEND_ECHO_SPEC_CONST_HANDLER*/ ZEND_ECHO_SPEC_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ECHO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2103,15 +2119,15 @@ case 1000: /*ZEND_ECHO_SPEC_CONST_HANDLER*/ ZEND_ECHO_SPEC_CONST_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 1025: /*ZEND_PRINT_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRINT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - goto ZEND_ECHO_SPEC_CONST_LABEL; + return ZEND_ECHO_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1075: /*ZEND_JMPZ_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2141,7 +2157,7 @@ case 1075: /*ZEND_JMPZ_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1100: /*ZEND_JMPNZ_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2171,7 +2187,7 @@ case 1100: /*ZEND_JMPNZ_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1125: /*ZEND_JMPZNZ_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2205,7 +2221,7 @@ case 1125: /*ZEND_JMPZNZ_SPEC_CONST_HANDLER*/ } } -case 1150: /*ZEND_JMPZ_EX_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2236,7 +2252,7 @@ case 1150: /*ZEND_JMPZ_EX_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1175: /*ZEND_JMPNZ_EX_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2267,7 +2283,7 @@ case 1175: /*ZEND_JMPNZ_EX_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1500: /*ZEND_DO_FCALL_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_DO_FCALL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2288,10 +2304,10 @@ case 1500: /*ZEND_DO_FCALL_SPEC_CONST_HANDLER*/ call->is_ctor_call = 0; EX(call) = call; - goto zend_do_fcall_common_helper_SPEC; + return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1550: /*ZEND_RETURN_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -2338,10 +2354,10 @@ case 1550: /*ZEND_RETURN_SPEC_CONST_HANDLER*/ *EG(return_value_ptr_ptr) = ret; } - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2775: /*ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -2409,10 +2425,10 @@ case 2775: /*ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER*/ } } while (0); - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2700: /*ZEND_THROW_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_THROW_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *value; @@ -2439,7 +2455,7 @@ case 2700: /*ZEND_THROW_SPEC_CONST_HANDLER*/ HANDLE_EXCEPTION(); } -case 1625: /*ZEND_SEND_VAL_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2467,7 +2483,7 @@ case 1625: /*ZEND_SEND_VAL_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1300: /*ZEND_BOOL_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2481,7 +2497,7 @@ case 1300: /*ZEND_BOOL_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2750: /*ZEND_CLONE_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CLONE_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2544,7 +2560,7 @@ case 2750: /*ZEND_CLONE_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 525: /*ZEND_CAST_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CAST_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2603,7 +2619,7 @@ case 525: /*ZEND_CAST_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1825: /*ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -2737,7 +2753,7 @@ case 1825: /*ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1925: /*ZEND_FE_RESET_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2879,7 +2895,7 @@ case 1925: /*ZEND_FE_RESET_SPEC_CONST_HANDLER*/ } } -case 1975: /*ZEND_EXIT_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXIT_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { #if 0 || (IS_CONST != IS_UNUSED) USE_OPLINE @@ -2901,7 +2917,7 @@ case 1975: /*ZEND_EXIT_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -case 3800: /*ZEND_JMP_SET_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2926,7 +2942,7 @@ case 3800: /*ZEND_JMP_SET_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3950: /*ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2960,7 +2976,7 @@ case 3950: /*ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 550: /*ZEND_QM_ASSIGN_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -2978,7 +2994,7 @@ case 550: /*ZEND_QM_ASSIGN_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3925: /*ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3005,7 +3021,7 @@ case 3925: /*ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 25: /*ZEND_ADD_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3020,7 +3036,7 @@ case 25: /*ZEND_ADD_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 50: /*ZEND_SUB_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3035,7 +3051,7 @@ case 50: /*ZEND_SUB_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 75: /*ZEND_MUL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3050,7 +3066,7 @@ case 75: /*ZEND_MUL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 100: /*ZEND_DIV_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3065,7 +3081,7 @@ case 100: /*ZEND_DIV_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 125: /*ZEND_MOD_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3080,7 +3096,7 @@ case 125: /*ZEND_MOD_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 150: /*ZEND_SL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3095,7 +3111,7 @@ case 150: /*ZEND_SL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 175: /*ZEND_SR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3110,7 +3126,7 @@ case 175: /*ZEND_SR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 200: /*ZEND_CONCAT_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3125,7 +3141,7 @@ case 200: /*ZEND_CONCAT_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 375: /*ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3140,7 +3156,7 @@ case 375: /*ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 400: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3157,7 +3173,7 @@ case 400: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 425: /*ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3173,7 +3189,7 @@ case 425: /*ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 450: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3189,7 +3205,7 @@ case 450: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 475: /*ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3205,7 +3221,7 @@ case 475: /*ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 500: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3221,7 +3237,7 @@ case 500: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 225: /*ZEND_BW_OR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3236,7 +3252,7 @@ case 225: /*ZEND_BW_OR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 250: /*ZEND_BW_AND_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3251,7 +3267,7 @@ case 250: /*ZEND_BW_AND_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 275: /*ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3266,7 +3282,7 @@ case 275: /*ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 350: /*ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3281,7 +3297,7 @@ case 350: /*ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_fetch_var_address_helper_SPEC_CONST_CONST: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -3413,39 +3429,39 @@ case 350: /*ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2000: /*ZEND_FETCH_R_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; + return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2075: /*ZEND_FETCH_W_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; + return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2150: /*ZEND_FETCH_RW_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; + return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2300: /*ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; + return zend_fetch_var_address_helper_SPEC_CONST_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2375: /*ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; + return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2225: /*ZEND_FETCH_IS_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CONST_CONST; + return zend_fetch_var_address_helper_SPEC_CONST_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2025: /*ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3475,7 +3491,7 @@ case 2025: /*ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2450: /*ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3499,7 +3515,7 @@ case 2450: /*ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2825: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -3617,7 +3633,7 @@ case 2825: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1200: /*ZEND_CASE_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3634,7 +3650,7 @@ case 1200: /*ZEND_CASE_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2475: /*ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3726,7 +3742,7 @@ case 2475: /*ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER*/ } } -case 1800: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3770,18 +3786,18 @@ case 1800: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER*/ ZEND_ADD_ARRAY_EL switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CONST_CONST; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CONST_CONST: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -3812,7 +3828,7 @@ case 1800: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER*/ ZEND_ADD_ARRAY_EL ZEND_VM_NEXT_OPCODE(); } -case 1775: /*ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -3821,12 +3837,12 @@ case 1775: /*ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1850: /*ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -3902,7 +3918,7 @@ case 1850: /*ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2850: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -3987,7 +4003,7 @@ case 2850: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3575: /*ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -4027,7 +4043,7 @@ case 3575: /*ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4000: /*ZEND_YIELD_SPEC_CONST_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -4181,7 +4197,7 @@ case 4000: /*ZEND_YIELD_SPEC_CONST_CONST_HANDLER*/ ZEND_VM_RETURN(); } -case 26: /*ZEND_ADD_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4196,7 +4212,7 @@ case 26: /*ZEND_ADD_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 51: /*ZEND_SUB_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4211,7 +4227,7 @@ case 51: /*ZEND_SUB_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 76: /*ZEND_MUL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4226,7 +4242,7 @@ case 76: /*ZEND_MUL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 101: /*ZEND_DIV_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4241,7 +4257,7 @@ case 101: /*ZEND_DIV_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 126: /*ZEND_MOD_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4256,7 +4272,7 @@ case 126: /*ZEND_MOD_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 151: /*ZEND_SL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4271,7 +4287,7 @@ case 151: /*ZEND_SL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 176: /*ZEND_SR_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4286,7 +4302,7 @@ case 176: /*ZEND_SR_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 201: /*ZEND_CONCAT_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4301,7 +4317,7 @@ case 201: /*ZEND_CONCAT_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 376: /*ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4316,7 +4332,7 @@ case 376: /*ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 401: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4333,7 +4349,7 @@ case 401: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 426: /*ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4349,7 +4365,7 @@ case 426: /*ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 451: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4365,7 +4381,7 @@ case 451: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 476: /*ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4381,7 +4397,7 @@ case 476: /*ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 501: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4397,7 +4413,7 @@ case 501: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 226: /*ZEND_BW_OR_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4412,7 +4428,7 @@ case 226: /*ZEND_BW_OR_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 251: /*ZEND_BW_AND_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4427,7 +4443,7 @@ case 251: /*ZEND_BW_AND_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 276: /*ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4442,7 +4458,7 @@ case 276: /*ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 351: /*ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4457,7 +4473,7 @@ case 351: /*ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2026: /*ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4487,7 +4503,7 @@ case 2026: /*ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2826: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -4605,7 +4621,7 @@ case 2826: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1201: /*ZEND_CASE_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4623,7 +4639,7 @@ case 1201: /*ZEND_CASE_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1801: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -4667,18 +4683,18 @@ case 1801: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEM switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CONST_TMP; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CONST_TMP: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -4709,7 +4725,7 @@ case 1801: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEM ZEND_VM_NEXT_OPCODE(); } -case 1776: /*ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -4718,12 +4734,12 @@ case 1776: /*ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 4001: /*ZEND_YIELD_SPEC_CONST_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -4877,7 +4893,7 @@ case 4001: /*ZEND_YIELD_SPEC_CONST_TMP_HANDLER*/ ZEND_VM_RETURN(); } -case 27: /*ZEND_ADD_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4892,7 +4908,7 @@ case 27: /*ZEND_ADD_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 52: /*ZEND_SUB_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4907,7 +4923,7 @@ case 52: /*ZEND_SUB_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 77: /*ZEND_MUL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4922,7 +4938,7 @@ case 77: /*ZEND_MUL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 102: /*ZEND_DIV_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4937,7 +4953,7 @@ case 102: /*ZEND_DIV_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 127: /*ZEND_MOD_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4952,7 +4968,7 @@ case 127: /*ZEND_MOD_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 152: /*ZEND_SL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4967,7 +4983,7 @@ case 152: /*ZEND_SL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 177: /*ZEND_SR_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4982,7 +4998,7 @@ case 177: /*ZEND_SR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 202: /*ZEND_CONCAT_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -4997,7 +5013,7 @@ case 202: /*ZEND_CONCAT_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 377: /*ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5012,7 +5028,7 @@ case 377: /*ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 402: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5029,7 +5045,7 @@ case 402: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 427: /*ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5045,7 +5061,7 @@ case 427: /*ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 452: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5061,7 +5077,7 @@ case 452: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 477: /*ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5077,7 +5093,7 @@ case 477: /*ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 502: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5093,7 +5109,7 @@ case 502: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 227: /*ZEND_BW_OR_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5108,7 +5124,7 @@ case 227: /*ZEND_BW_OR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 252: /*ZEND_BW_AND_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5123,7 +5139,7 @@ case 252: /*ZEND_BW_AND_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 277: /*ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5138,7 +5154,7 @@ case 277: /*ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 352: /*ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5153,7 +5169,7 @@ case 352: /*ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_fetch_var_address_helper_SPEC_CONST_VAR: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -5285,39 +5301,39 @@ case 352: /*ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2002: /*ZEND_FETCH_R_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; + return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2077: /*ZEND_FETCH_W_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; + return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2152: /*ZEND_FETCH_RW_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; + return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2302: /*ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; + return zend_fetch_var_address_helper_SPEC_CONST_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2377: /*ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; + return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2227: /*ZEND_FETCH_IS_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CONST_VAR; + return zend_fetch_var_address_helper_SPEC_CONST_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2027: /*ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5347,7 +5363,7 @@ case 2027: /*ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2827: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -5465,7 +5481,7 @@ case 2827: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1202: /*ZEND_CASE_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -5483,7 +5499,7 @@ case 1202: /*ZEND_CASE_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1802: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -5527,18 +5543,18 @@ case 1802: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEM switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CONST_VAR; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CONST_VAR: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -5569,7 +5585,7 @@ case 1802: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEM ZEND_VM_NEXT_OPCODE(); } -case 1777: /*ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -5578,12 +5594,12 @@ case 1777: /*ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1852: /*ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -5659,7 +5675,7 @@ case 1852: /*ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2852: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -5744,7 +5760,7 @@ case 2852: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4002: /*ZEND_YIELD_SPEC_CONST_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -5899,7 +5915,7 @@ case 4002: /*ZEND_YIELD_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_RETURN(); } -zend_fetch_var_address_helper_SPEC_CONST_UNUSED: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CONST_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -6031,39 +6047,39 @@ case 4002: /*ZEND_YIELD_SPEC_CONST_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2003: /*ZEND_FETCH_R_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2078: /*ZEND_FETCH_W_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2153: /*ZEND_FETCH_RW_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2303: /*ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2378: /*ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2228: /*ZEND_FETCH_IS_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CONST_UNUSED; + return zend_fetch_var_address_helper_SPEC_CONST_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2828: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -6181,7 +6197,7 @@ case 2828: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1803: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6225,18 +6241,18 @@ case 1803: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_E switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CONST_UNUSED; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CONST_UNUSED: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_UNUSED); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -6267,7 +6283,7 @@ case 1803: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_E ZEND_VM_NEXT_OPCODE(); } -case 1778: /*ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6276,12 +6292,12 @@ case 1778: /*ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1853: /*ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -6357,7 +6373,7 @@ case 1853: /*ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2853: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -6442,7 +6458,7 @@ case 2853: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3828: /*ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_function *op_array; @@ -6460,7 +6476,7 @@ case 3828: /*ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4003: /*ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6614,7 +6630,7 @@ case 4003: /*ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER*/ ZEND_VM_RETURN(); } -case 29: /*ZEND_ADD_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6629,7 +6645,7 @@ case 29: /*ZEND_ADD_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 54: /*ZEND_SUB_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6644,7 +6660,7 @@ case 54: /*ZEND_SUB_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 79: /*ZEND_MUL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6659,7 +6675,7 @@ case 79: /*ZEND_MUL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 104: /*ZEND_DIV_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6674,7 +6690,7 @@ case 104: /*ZEND_DIV_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 129: /*ZEND_MOD_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6689,7 +6705,7 @@ case 129: /*ZEND_MOD_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 154: /*ZEND_SL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6704,7 +6720,7 @@ case 154: /*ZEND_SL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 179: /*ZEND_SR_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6719,7 +6735,7 @@ case 179: /*ZEND_SR_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 204: /*ZEND_CONCAT_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6734,7 +6750,7 @@ case 204: /*ZEND_CONCAT_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 379: /*ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6749,7 +6765,7 @@ case 379: /*ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 404: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6766,7 +6782,7 @@ case 404: /*ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 429: /*ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6782,7 +6798,7 @@ case 429: /*ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 454: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6798,7 +6814,7 @@ case 454: /*ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 479: /*ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6814,7 +6830,7 @@ case 479: /*ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 504: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6830,7 +6846,7 @@ case 504: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 229: /*ZEND_BW_OR_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6845,7 +6861,7 @@ case 229: /*ZEND_BW_OR_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 254: /*ZEND_BW_AND_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6860,7 +6876,7 @@ case 254: /*ZEND_BW_AND_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 279: /*ZEND_BW_XOR_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6875,7 +6891,7 @@ case 279: /*ZEND_BW_XOR_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 354: /*ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6890,7 +6906,7 @@ case 354: /*ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2029: /*ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -6920,7 +6936,7 @@ case 2029: /*ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2829: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -7038,7 +7054,7 @@ case 2829: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2679: /*ZEND_CATCH_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CATCH_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_class_entry *ce, *catch_ce; @@ -7098,7 +7114,7 @@ case 2679: /*ZEND_CATCH_SPEC_CONST_CV_HANDLER*/ } } -case 1204: /*ZEND_CASE_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -7115,7 +7131,7 @@ case 1204: /*ZEND_CASE_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1804: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -7159,18 +7175,18 @@ case 1804: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEME switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CONST_CV; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CONST_CV: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CONST_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -7201,7 +7217,7 @@ case 1804: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEME ZEND_VM_NEXT_OPCODE(); } -case 1779: /*ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -7210,12 +7226,12 @@ case 1779: /*ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CONST != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 4004: /*ZEND_YIELD_SPEC_CONST_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -7369,7 +7385,7 @@ case 4004: /*ZEND_YIELD_SPEC_CONST_CV_HANDLER*/ ZEND_VM_RETURN(); } -case 305: /*ZEND_BW_NOT_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7382,7 +7398,7 @@ case 305: /*ZEND_BW_NOT_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 330: /*ZEND_BOOL_NOT_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7395,7 +7411,7 @@ case 330: /*ZEND_BOOL_NOT_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1005: /*ZEND_ECHO_SPEC_TMP_HANDLER*/ ZEND_ECHO_SPEC_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7426,15 +7442,15 @@ case 1005: /*ZEND_ECHO_SPEC_TMP_HANDLER*/ ZEND_ECHO_SPEC_TMP_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 1030: /*ZEND_PRINT_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRINT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - goto ZEND_ECHO_SPEC_TMP_LABEL; + return ZEND_ECHO_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1080: /*ZEND_JMPZ_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7464,7 +7480,7 @@ case 1080: /*ZEND_JMPZ_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1105: /*ZEND_JMPNZ_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7494,7 +7510,7 @@ case 1105: /*ZEND_JMPNZ_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1130: /*ZEND_JMPZNZ_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7528,7 +7544,7 @@ case 1130: /*ZEND_JMPZNZ_SPEC_TMP_HANDLER*/ } } -case 1155: /*ZEND_JMPZ_EX_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7559,7 +7575,7 @@ case 1155: /*ZEND_JMPZ_EX_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1180: /*ZEND_JMPNZ_EX_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7590,7 +7606,7 @@ case 1180: /*ZEND_JMPNZ_EX_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1755: /*ZEND_FREE_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FREE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -7604,7 +7620,7 @@ case 1755: /*ZEND_FREE_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1555: /*ZEND_RETURN_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -7651,10 +7667,10 @@ case 1555: /*ZEND_RETURN_SPEC_TMP_HANDLER*/ *EG(return_value_ptr_ptr) = ret; } - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2780: /*ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -7722,10 +7738,10 @@ case 2780: /*ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER*/ } } while (0); - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2705: /*ZEND_THROW_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_THROW_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *value; @@ -7752,7 +7768,7 @@ case 2705: /*ZEND_THROW_SPEC_TMP_HANDLER*/ HANDLE_EXCEPTION(); } -case 1630: /*ZEND_SEND_VAL_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEND_VAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -7780,7 +7796,7 @@ case 1630: /*ZEND_SEND_VAL_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1305: /*ZEND_BOOL_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7795,7 +7811,7 @@ case 1305: /*ZEND_BOOL_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2755: /*ZEND_CLONE_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CLONE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7858,7 +7874,7 @@ case 2755: /*ZEND_CLONE_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 530: /*ZEND_CAST_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CAST_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -7917,7 +7933,7 @@ case 530: /*ZEND_CAST_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1830: /*ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -8051,7 +8067,7 @@ case 1830: /*ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1930: /*ZEND_FE_RESET_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8193,7 +8209,7 @@ case 1930: /*ZEND_FE_RESET_SPEC_TMP_HANDLER*/ } } -case 1980: /*ZEND_EXIT_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXIT_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { #if 0 || (IS_TMP_VAR != IS_UNUSED) USE_OPLINE @@ -8215,7 +8231,7 @@ case 1980: /*ZEND_EXIT_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -case 1455: /*ZEND_END_SILENCE_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_END_SILENCE_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval restored_error_reporting; @@ -8244,7 +8260,7 @@ case 1455: /*ZEND_END_SILENCE_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3805: /*ZEND_JMP_SET_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8270,7 +8286,7 @@ case 3805: /*ZEND_JMP_SET_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3955: /*ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8305,7 +8321,7 @@ case 3955: /*ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 555: /*ZEND_QM_ASSIGN_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8323,7 +8339,7 @@ case 555: /*ZEND_QM_ASSIGN_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3930: /*ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8350,7 +8366,7 @@ case 3930: /*ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3455: /*ZEND_INSTANCEOF_SPEC_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8371,7 +8387,7 @@ case 3455: /*ZEND_INSTANCEOF_SPEC_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 30: /*ZEND_ADD_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8386,7 +8402,7 @@ case 30: /*ZEND_ADD_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 55: /*ZEND_SUB_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8401,7 +8417,7 @@ case 55: /*ZEND_SUB_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 80: /*ZEND_MUL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8416,7 +8432,7 @@ case 80: /*ZEND_MUL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 105: /*ZEND_DIV_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8431,7 +8447,7 @@ case 105: /*ZEND_DIV_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 130: /*ZEND_MOD_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8446,7 +8462,7 @@ case 130: /*ZEND_MOD_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 155: /*ZEND_SL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8461,7 +8477,7 @@ case 155: /*ZEND_SL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 180: /*ZEND_SR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8476,7 +8492,7 @@ case 180: /*ZEND_SR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 205: /*ZEND_CONCAT_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8491,7 +8507,7 @@ case 205: /*ZEND_CONCAT_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 380: /*ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8506,7 +8522,7 @@ case 380: /*ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 405: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8523,7 +8539,7 @@ case 405: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 430: /*ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8539,7 +8555,7 @@ case 430: /*ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 455: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8555,7 +8571,7 @@ case 455: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 480: /*ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8571,7 +8587,7 @@ case 480: /*ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 505: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8587,7 +8603,7 @@ case 505: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 230: /*ZEND_BW_OR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8602,7 +8618,7 @@ case 230: /*ZEND_BW_OR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 255: /*ZEND_BW_AND_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8617,7 +8633,7 @@ case 255: /*ZEND_BW_AND_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 280: /*ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8632,7 +8648,7 @@ case 280: /*ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 355: /*ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8647,7 +8663,7 @@ case 355: /*ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_fetch_var_address_helper_SPEC_TMP_CONST: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8779,39 +8795,39 @@ case 355: /*ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2005: /*ZEND_FETCH_R_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; + return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2080: /*ZEND_FETCH_W_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; + return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2155: /*ZEND_FETCH_RW_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; + return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2305: /*ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; + return zend_fetch_var_address_helper_SPEC_TMP_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2380: /*ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; + return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2230: /*ZEND_FETCH_IS_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_TMP_CONST; + return zend_fetch_var_address_helper_SPEC_TMP_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2030: /*ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8841,7 +8857,7 @@ case 2030: /*ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2455: /*ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -8865,7 +8881,7 @@ case 2455: /*ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1355: /*ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -8888,7 +8904,7 @@ case 1355: /*ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1380: /*ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -8911,7 +8927,7 @@ case 1380: /*ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2805: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -8983,7 +8999,7 @@ case 2805: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1205: /*ZEND_CASE_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -9000,7 +9016,7 @@ case 1205: /*ZEND_CASE_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1805: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -9044,18 +9060,18 @@ case 1805: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEM switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_TMP_CONST; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_TMP_CONST: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -9086,7 +9102,7 @@ case 1805: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEM ZEND_VM_NEXT_OPCODE(); } -case 1780: /*ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -9095,12 +9111,12 @@ case 1780: /*ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1855: /*ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -9176,7 +9192,7 @@ case 1855: /*ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2855: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -9261,7 +9277,7 @@ case 2855: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4005: /*ZEND_YIELD_SPEC_TMP_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -9415,7 +9431,7 @@ case 4005: /*ZEND_YIELD_SPEC_TMP_CONST_HANDLER*/ ZEND_VM_RETURN(); } -case 31: /*ZEND_ADD_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9430,7 +9446,7 @@ case 31: /*ZEND_ADD_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 56: /*ZEND_SUB_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9445,7 +9461,7 @@ case 56: /*ZEND_SUB_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 81: /*ZEND_MUL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9460,7 +9476,7 @@ case 81: /*ZEND_MUL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 106: /*ZEND_DIV_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9475,7 +9491,7 @@ case 106: /*ZEND_DIV_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 131: /*ZEND_MOD_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9490,7 +9506,7 @@ case 131: /*ZEND_MOD_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 156: /*ZEND_SL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9505,7 +9521,7 @@ case 156: /*ZEND_SL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 181: /*ZEND_SR_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9520,7 +9536,7 @@ case 181: /*ZEND_SR_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 206: /*ZEND_CONCAT_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9535,7 +9551,7 @@ case 206: /*ZEND_CONCAT_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 381: /*ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9550,7 +9566,7 @@ case 381: /*ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 406: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9567,7 +9583,7 @@ case 406: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 431: /*ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9583,7 +9599,7 @@ case 431: /*ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 456: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9599,7 +9615,7 @@ case 456: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 481: /*ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9615,7 +9631,7 @@ case 481: /*ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 506: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9631,7 +9647,7 @@ case 506: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 231: /*ZEND_BW_OR_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9646,7 +9662,7 @@ case 231: /*ZEND_BW_OR_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 256: /*ZEND_BW_AND_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9661,7 +9677,7 @@ case 256: /*ZEND_BW_AND_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 281: /*ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9676,7 +9692,7 @@ case 281: /*ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 356: /*ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9691,7 +9707,7 @@ case 356: /*ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2031: /*ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9721,7 +9737,7 @@ case 2031: /*ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1406: /*ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -9766,7 +9782,7 @@ case 1406: /*ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2806: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -9839,7 +9855,7 @@ case 2806: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1206: /*ZEND_CASE_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -9857,7 +9873,7 @@ case 1206: /*ZEND_CASE_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1806: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -9901,18 +9917,18 @@ case 1806: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_TMP_TMP; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_TMP_TMP: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -9943,7 +9959,7 @@ case 1806: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN ZEND_VM_NEXT_OPCODE(); } -case 1781: /*ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -9952,12 +9968,12 @@ case 1781: /*ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 4006: /*ZEND_YIELD_SPEC_TMP_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -10111,7 +10127,7 @@ case 4006: /*ZEND_YIELD_SPEC_TMP_TMP_HANDLER*/ ZEND_VM_RETURN(); } -case 32: /*ZEND_ADD_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10126,7 +10142,7 @@ case 32: /*ZEND_ADD_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 57: /*ZEND_SUB_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10141,7 +10157,7 @@ case 57: /*ZEND_SUB_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 82: /*ZEND_MUL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10156,7 +10172,7 @@ case 82: /*ZEND_MUL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 107: /*ZEND_DIV_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10171,7 +10187,7 @@ case 107: /*ZEND_DIV_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 132: /*ZEND_MOD_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10186,7 +10202,7 @@ case 132: /*ZEND_MOD_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 157: /*ZEND_SL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10201,7 +10217,7 @@ case 157: /*ZEND_SL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 182: /*ZEND_SR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10216,7 +10232,7 @@ case 182: /*ZEND_SR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 207: /*ZEND_CONCAT_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10231,7 +10247,7 @@ case 207: /*ZEND_CONCAT_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 382: /*ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10246,7 +10262,7 @@ case 382: /*ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 407: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10263,7 +10279,7 @@ case 407: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 432: /*ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10279,7 +10295,7 @@ case 432: /*ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 457: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10295,7 +10311,7 @@ case 457: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 482: /*ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10311,7 +10327,7 @@ case 482: /*ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 507: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10327,7 +10343,7 @@ case 507: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 232: /*ZEND_BW_OR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10342,7 +10358,7 @@ case 232: /*ZEND_BW_OR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 257: /*ZEND_BW_AND_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10357,7 +10373,7 @@ case 257: /*ZEND_BW_AND_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 282: /*ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10372,7 +10388,7 @@ case 282: /*ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 357: /*ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10387,7 +10403,7 @@ case 357: /*ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_fetch_var_address_helper_SPEC_TMP_VAR: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -10519,39 +10535,39 @@ case 357: /*ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2007: /*ZEND_FETCH_R_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; + return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2082: /*ZEND_FETCH_W_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; + return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2157: /*ZEND_FETCH_RW_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; + return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2307: /*ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; + return zend_fetch_var_address_helper_SPEC_TMP_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2382: /*ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; + return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2232: /*ZEND_FETCH_IS_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_TMP_VAR; + return zend_fetch_var_address_helper_SPEC_TMP_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2032: /*ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10581,7 +10597,7 @@ case 2032: /*ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1407: /*ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -10626,7 +10642,7 @@ case 1407: /*ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2807: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -10699,7 +10715,7 @@ case 2807: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1207: /*ZEND_CASE_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -10717,7 +10733,7 @@ case 1207: /*ZEND_CASE_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1807: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -10761,18 +10777,18 @@ case 1807: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_TMP_VAR; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_TMP_VAR: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -10803,7 +10819,7 @@ case 1807: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN ZEND_VM_NEXT_OPCODE(); } -case 1782: /*ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -10812,12 +10828,12 @@ case 1782: /*ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1857: /*ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -10893,7 +10909,7 @@ case 1857: /*ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2857: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -10978,7 +10994,7 @@ case 2857: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4007: /*ZEND_YIELD_SPEC_TMP_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -11133,7 +11149,7 @@ case 4007: /*ZEND_YIELD_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_RETURN(); } -zend_fetch_var_address_helper_SPEC_TMP_UNUSED: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_TMP_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11265,39 +11281,39 @@ case 4007: /*ZEND_YIELD_SPEC_TMP_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2008: /*ZEND_FETCH_R_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2083: /*ZEND_FETCH_W_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2158: /*ZEND_FETCH_RW_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2308: /*ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2383: /*ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2233: /*ZEND_FETCH_IS_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_TMP_UNUSED; + return zend_fetch_var_address_helper_SPEC_TMP_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1808: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11341,18 +11357,18 @@ case 1808: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELE switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_TMP_UNUSED; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_TMP_UNUSED: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_UNUSED); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -11383,7 +11399,7 @@ case 1808: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELE ZEND_VM_NEXT_OPCODE(); } -case 1783: /*ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -11392,12 +11408,12 @@ case 1783: /*ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1858: /*ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -11473,7 +11489,7 @@ case 1858: /*ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2858: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -11558,7 +11574,7 @@ case 2858: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4008: /*ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -11712,7 +11728,7 @@ case 4008: /*ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER*/ ZEND_VM_RETURN(); } -case 34: /*ZEND_ADD_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11727,7 +11743,7 @@ case 34: /*ZEND_ADD_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 59: /*ZEND_SUB_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11742,7 +11758,7 @@ case 59: /*ZEND_SUB_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 84: /*ZEND_MUL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11757,7 +11773,7 @@ case 84: /*ZEND_MUL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 109: /*ZEND_DIV_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11772,7 +11788,7 @@ case 109: /*ZEND_DIV_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 134: /*ZEND_MOD_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11787,7 +11803,7 @@ case 134: /*ZEND_MOD_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 159: /*ZEND_SL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11802,7 +11818,7 @@ case 159: /*ZEND_SL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 184: /*ZEND_SR_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11817,7 +11833,7 @@ case 184: /*ZEND_SR_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 209: /*ZEND_CONCAT_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11832,7 +11848,7 @@ case 209: /*ZEND_CONCAT_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 384: /*ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11847,7 +11863,7 @@ case 384: /*ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 409: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11864,7 +11880,7 @@ case 409: /*ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 434: /*ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11880,7 +11896,7 @@ case 434: /*ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 459: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11896,7 +11912,7 @@ case 459: /*ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 484: /*ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11912,7 +11928,7 @@ case 484: /*ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 509: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11928,7 +11944,7 @@ case 509: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 234: /*ZEND_BW_OR_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11943,7 +11959,7 @@ case 234: /*ZEND_BW_OR_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 259: /*ZEND_BW_AND_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11958,7 +11974,7 @@ case 259: /*ZEND_BW_AND_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 284: /*ZEND_BW_XOR_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11973,7 +11989,7 @@ case 284: /*ZEND_BW_XOR_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 359: /*ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -11988,7 +12004,7 @@ case 359: /*ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2034: /*ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12018,7 +12034,7 @@ case 2034: /*ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1409: /*ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -12062,7 +12078,7 @@ case 1409: /*ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2809: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -12134,7 +12150,7 @@ case 2809: /*ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1209: /*ZEND_CASE_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12151,7 +12167,7 @@ case 1209: /*ZEND_CASE_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1809: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12195,18 +12211,18 @@ case 1809: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_TMP_CV; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_TMP_CV: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_TMP_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -12237,7 +12253,7 @@ case 1809: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT ZEND_VM_NEXT_OPCODE(); } -case 1784: /*ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -12246,12 +12262,12 @@ case 1784: /*ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_TMP_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 4009: /*ZEND_YIELD_SPEC_TMP_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -12405,7 +12421,7 @@ case 4009: /*ZEND_YIELD_SPEC_TMP_CV_HANDLER*/ ZEND_VM_RETURN(); } -case 310: /*ZEND_BW_NOT_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12418,7 +12434,7 @@ case 310: /*ZEND_BW_NOT_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 335: /*ZEND_BOOL_NOT_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12431,7 +12447,7 @@ case 335: /*ZEND_BOOL_NOT_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 860: /*ZEND_PRE_INC_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12478,7 +12494,7 @@ case 860: /*ZEND_PRE_INC_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 885: /*ZEND_PRE_DEC_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12525,7 +12541,7 @@ case 885: /*ZEND_PRE_DEC_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 910: /*ZEND_POST_INC_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12568,7 +12584,7 @@ case 910: /*ZEND_POST_INC_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 935: /*ZEND_POST_DEC_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12611,7 +12627,7 @@ case 935: /*ZEND_POST_DEC_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1010: /*ZEND_ECHO_SPEC_VAR_HANDLER*/ ZEND_ECHO_SPEC_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12642,15 +12658,15 @@ case 1010: /*ZEND_ECHO_SPEC_VAR_HANDLER*/ ZEND_ECHO_SPEC_VAR_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 1035: /*ZEND_PRINT_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRINT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - goto ZEND_ECHO_SPEC_VAR_LABEL; + return ZEND_ECHO_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1085: /*ZEND_JMPZ_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12680,7 +12696,7 @@ case 1085: /*ZEND_JMPZ_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1110: /*ZEND_JMPNZ_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12710,7 +12726,7 @@ case 1110: /*ZEND_JMPNZ_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1135: /*ZEND_JMPZNZ_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12744,7 +12760,7 @@ case 1135: /*ZEND_JMPZNZ_SPEC_VAR_HANDLER*/ } } -case 1160: /*ZEND_JMPZ_EX_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12775,7 +12791,7 @@ case 1160: /*ZEND_JMPZ_EX_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1185: /*ZEND_JMPNZ_EX_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -12806,7 +12822,7 @@ case 1185: /*ZEND_JMPNZ_EX_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1760: /*ZEND_FREE_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FREE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -12820,7 +12836,7 @@ case 1760: /*ZEND_FREE_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1560: /*ZEND_RETURN_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -12867,10 +12883,10 @@ case 1560: /*ZEND_RETURN_SPEC_VAR_HANDLER*/ *EG(return_value_ptr_ptr) = ret; } if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2785: /*ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -12939,10 +12955,10 @@ case 2785: /*ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER*/ } while (0); if (free_op1.var) {zval_ptr_dtor(&free_op1.var);}; - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2710: /*ZEND_THROW_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_THROW_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *value; @@ -12969,7 +12985,7 @@ case 2710: /*ZEND_THROW_SPEC_VAR_HANDLER*/ HANDLE_EXCEPTION(); } -zend_send_by_var_helper_SPEC_VAR: +static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *varptr; @@ -12997,7 +13013,7 @@ case 2710: /*ZEND_THROW_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2660: /*ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13006,10 +13022,10 @@ case 2660: /*ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER*/ SAVE_OPLINE(); if (opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) { /* Had function_ptr at compile_time */ if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { - goto zend_send_by_var_helper_SPEC_VAR; + return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - goto zend_send_by_var_helper_SPEC_VAR; + return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } if (IS_VAR == IS_VAR && @@ -13049,7 +13065,7 @@ case 2660: /*ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1685: /*ZEND_SEND_REF_SPEC_VAR_HANDLER*/ ZEND_SEND_REF_SPEC_VAR_LABEL: +static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13071,7 +13087,7 @@ case 1685: /*ZEND_SEND_REF_SPEC_VAR_HANDLER*/ ZEND_SEND_REF_SPEC_VAR_LABEL: } if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - goto zend_send_by_var_helper_SPEC_VAR; + return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } SEPARATE_ZVAL_TO_MAKE_IS_REF(varptr_ptr); @@ -13084,19 +13100,19 @@ case 1685: /*ZEND_SEND_REF_SPEC_VAR_HANDLER*/ ZEND_SEND_REF_SPEC_VAR_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 1660: /*ZEND_SEND_VAR_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEND_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - goto ZEND_SEND_REF_SPEC_VAR_LABEL; + return ZEND_SEND_REF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } SAVE_OPLINE(); - goto zend_send_by_var_helper_SPEC_VAR; + return zend_send_by_var_helper_SPEC_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1310: /*ZEND_BOOL_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13111,7 +13127,7 @@ case 1310: /*ZEND_BOOL_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1235: /*ZEND_SWITCH_FREE_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SWITCH_FREE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -13121,7 +13137,7 @@ case 1235: /*ZEND_SWITCH_FREE_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2760: /*ZEND_CLONE_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CLONE_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13184,7 +13200,7 @@ case 2760: /*ZEND_CLONE_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 535: /*ZEND_CAST_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CAST_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13243,7 +13259,7 @@ case 535: /*ZEND_CAST_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1835: /*ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -13377,7 +13393,7 @@ case 1835: /*ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1935: /*ZEND_FE_RESET_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13520,7 +13536,7 @@ case 1935: /*ZEND_FE_RESET_SPEC_VAR_HANDLER*/ } } -case 1960: /*ZEND_FE_FETCH_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FE_FETCH_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -13662,7 +13678,7 @@ case 1960: /*ZEND_FE_FETCH_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1985: /*ZEND_EXIT_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXIT_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { #if 0 || (IS_VAR != IS_UNUSED) USE_OPLINE @@ -13684,7 +13700,7 @@ case 1985: /*ZEND_EXIT_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -case 3810: /*ZEND_JMP_SET_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13710,7 +13726,7 @@ case 3810: /*ZEND_JMP_SET_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3960: /*ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13745,7 +13761,7 @@ case 3960: /*ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 560: /*ZEND_QM_ASSIGN_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13763,7 +13779,7 @@ case 560: /*ZEND_QM_ASSIGN_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3935: /*ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13791,7 +13807,7 @@ case 3935: /*ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3460: /*ZEND_INSTANCEOF_SPEC_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13812,7 +13828,7 @@ case 3460: /*ZEND_INSTANCEOF_SPEC_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 35: /*ZEND_ADD_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13827,7 +13843,7 @@ case 35: /*ZEND_ADD_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 60: /*ZEND_SUB_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13842,7 +13858,7 @@ case 60: /*ZEND_SUB_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 85: /*ZEND_MUL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13857,7 +13873,7 @@ case 85: /*ZEND_MUL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 110: /*ZEND_DIV_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13872,7 +13888,7 @@ case 110: /*ZEND_DIV_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 135: /*ZEND_MOD_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13887,7 +13903,7 @@ case 135: /*ZEND_MOD_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 160: /*ZEND_SL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13902,7 +13918,7 @@ case 160: /*ZEND_SL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 185: /*ZEND_SR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13917,7 +13933,7 @@ case 185: /*ZEND_SR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 210: /*ZEND_CONCAT_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13932,7 +13948,7 @@ case 210: /*ZEND_CONCAT_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 385: /*ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13947,7 +13963,7 @@ case 385: /*ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 410: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13964,7 +13980,7 @@ case 410: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 435: /*ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13980,7 +13996,7 @@ case 435: /*ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 460: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -13996,7 +14012,7 @@ case 460: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 485: /*ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14012,7 +14028,7 @@ case 485: /*ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 510: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14028,7 +14044,7 @@ case 510: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 235: /*ZEND_BW_OR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14043,7 +14059,7 @@ case 235: /*ZEND_BW_OR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 260: /*ZEND_BW_AND_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14058,7 +14074,7 @@ case 260: /*ZEND_BW_AND_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 285: /*ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14073,7 +14089,7 @@ case 285: /*ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14088,7 +14104,7 @@ case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op_data1; @@ -14200,7 +14216,7 @@ case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op_data2, free_op_data1; @@ -14210,7 +14226,7 @@ case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -14221,7 +14237,7 @@ case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = opline->op2.zv; @@ -14289,62 +14305,62 @@ case 360: /*ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 585: /*ZEND_ASSIGN_ADD_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 610: /*ZEND_ASSIGN_SUB_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 635: /*ZEND_ASSIGN_MUL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 660: /*ZEND_ASSIGN_DIV_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 685: /*ZEND_ASSIGN_MOD_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 710: /*ZEND_ASSIGN_SL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 735: /*ZEND_ASSIGN_SR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 760: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 785: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 810: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 835: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_CONST; + return zend_binary_assign_op_helper_SPEC_VAR_CONST(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14438,17 +14454,17 @@ case 835: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3310: /*ZEND_PRE_INC_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CONST; + return zend_pre_incdec_property_helper_SPEC_VAR_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3335: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CONST; + return zend_pre_incdec_property_helper_SPEC_VAR_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14540,17 +14556,17 @@ case 3335: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3360: /*ZEND_POST_INC_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_CONST; + return zend_post_incdec_property_helper_SPEC_VAR_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3385: /*ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_CONST; + return zend_post_incdec_property_helper_SPEC_VAR_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_var_address_helper_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14682,39 +14698,39 @@ case 3385: /*ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2010: /*ZEND_FETCH_R_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; + return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2085: /*ZEND_FETCH_W_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; + return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2160: /*ZEND_FETCH_RW_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; + return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2310: /*ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; + return zend_fetch_var_address_helper_SPEC_VAR_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2385: /*ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; + return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2235: /*ZEND_FETCH_IS_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_VAR_CONST; + return zend_fetch_var_address_helper_SPEC_VAR_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2035: /*ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14744,7 +14760,7 @@ case 2035: /*ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2110: /*ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14778,7 +14794,7 @@ case 2110: /*ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2185: /*ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14800,7 +14816,7 @@ case 2185: /*ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2260: /*ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14815,7 +14831,7 @@ case 2260: /*ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2335: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14845,7 +14861,7 @@ case 2335: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2410: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14886,7 +14902,7 @@ case 2410: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CONST(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14929,12 +14945,12 @@ case 2410: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2060: /*ZEND_FETCH_OBJ_R_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_VAR_CONST; + return zend_fetch_property_address_read_helper_SPEC_VAR_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2135: /*ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -14983,7 +14999,7 @@ case 2135: /*ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2210: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15014,7 +15030,7 @@ case 2210: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2285: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15056,7 +15072,7 @@ case 2285: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2360: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -15089,11 +15105,11 @@ case 2360: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_VAR_CONST; + return zend_fetch_property_address_read_helper_SPEC_VAR_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2435: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_res; @@ -15136,7 +15152,7 @@ case 2435: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3410: /*ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15166,7 +15182,7 @@ case 3410: /*ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3685: /*ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15246,7 +15262,7 @@ case 3685: /*ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 960: /*ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15301,7 +15317,7 @@ case 960: /*ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_CONST_LABE ZEND_VM_NEXT_OPCODE(); } -case 2810: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -15374,7 +15390,7 @@ case 2810: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2835: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -15492,7 +15508,7 @@ case 2835: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1210: /*ZEND_CASE_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15509,7 +15525,7 @@ case 1210: /*ZEND_CASE_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2485: /*ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -15601,7 +15617,7 @@ case 2485: /*ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER*/ } } -case 1810: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15645,18 +15661,18 @@ case 1810: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEM switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_VAR_CONST; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_VAR_CONST: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -15687,7 +15703,7 @@ case 1810: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEM ZEND_VM_NEXT_OPCODE(); } -case 1785: /*ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -15696,12 +15712,12 @@ case 1785: /*ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1860: /*ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -15777,7 +15793,7 @@ case 1860: /*ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1885: /*ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15815,7 +15831,7 @@ case 1885: /*ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER*/ if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -15831,7 +15847,7 @@ case 1885: /*ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_VAR_CONST: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { zval_ptr_dtor(&offset); @@ -15877,7 +15893,7 @@ case 1885: /*ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1910: /*ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -15918,7 +15934,7 @@ case 1910: /*ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2860: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -16003,7 +16019,7 @@ case 2860: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -16027,12 +16043,12 @@ case 2860: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_VAR_CONST; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_VAR_CONST: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -16042,7 +16058,7 @@ case 2860: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -16147,17 +16163,17 @@ case 2860: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2885: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3710: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4010: /*ZEND_YIELD_SPEC_VAR_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -16313,7 +16329,7 @@ case 4010: /*ZEND_YIELD_SPEC_VAR_CONST_HANDLER*/ ZEND_VM_RETURN(); } -case 36: /*ZEND_ADD_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16328,7 +16344,7 @@ case 36: /*ZEND_ADD_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 61: /*ZEND_SUB_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16343,7 +16359,7 @@ case 61: /*ZEND_SUB_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 86: /*ZEND_MUL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16358,7 +16374,7 @@ case 86: /*ZEND_MUL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 111: /*ZEND_DIV_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16373,7 +16389,7 @@ case 111: /*ZEND_DIV_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 136: /*ZEND_MOD_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16388,7 +16404,7 @@ case 136: /*ZEND_MOD_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 161: /*ZEND_SL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16403,7 +16419,7 @@ case 161: /*ZEND_SL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 186: /*ZEND_SR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16418,7 +16434,7 @@ case 186: /*ZEND_SR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 211: /*ZEND_CONCAT_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16433,7 +16449,7 @@ case 211: /*ZEND_CONCAT_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 386: /*ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16448,7 +16464,7 @@ case 386: /*ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 411: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16465,7 +16481,7 @@ case 411: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 436: /*ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16481,7 +16497,7 @@ case 436: /*ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 461: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16497,7 +16513,7 @@ case 461: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 486: /*ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16513,7 +16529,7 @@ case 486: /*ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 511: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16529,7 +16545,7 @@ case 511: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 236: /*ZEND_BW_OR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16544,7 +16560,7 @@ case 236: /*ZEND_BW_OR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 261: /*ZEND_BW_AND_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16559,7 +16575,7 @@ case 261: /*ZEND_BW_AND_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 286: /*ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16574,7 +16590,7 @@ case 286: /*ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16589,7 +16605,7 @@ case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_VAR_TMP: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data1; @@ -16701,7 +16717,7 @@ case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_VAR_TMP: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data2, free_op_data1; @@ -16711,7 +16727,7 @@ case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -16722,7 +16738,7 @@ case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_obj_helper_SPEC_VAR_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -16791,62 +16807,62 @@ case 361: /*ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 586: /*ZEND_ASSIGN_ADD_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 611: /*ZEND_ASSIGN_SUB_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 636: /*ZEND_ASSIGN_MUL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 661: /*ZEND_ASSIGN_DIV_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 686: /*ZEND_ASSIGN_MOD_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 711: /*ZEND_ASSIGN_SL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 736: /*ZEND_ASSIGN_SR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 761: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 786: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 811: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 836: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_TMP; + return zend_binary_assign_op_helper_SPEC_VAR_TMP(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_VAR_TMP: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -16940,17 +16956,17 @@ case 836: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3311: /*ZEND_PRE_INC_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_TMP; + return zend_pre_incdec_property_helper_SPEC_VAR_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3336: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_TMP; + return zend_pre_incdec_property_helper_SPEC_VAR_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_VAR_TMP: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17042,17 +17058,17 @@ case 3336: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3361: /*ZEND_POST_INC_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_TMP; + return zend_post_incdec_property_helper_SPEC_VAR_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3386: /*ZEND_POST_DEC_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_TMP; + return zend_post_incdec_property_helper_SPEC_VAR_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2036: /*ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17082,7 +17098,7 @@ case 2036: /*ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2111: /*ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17116,7 +17132,7 @@ case 2111: /*ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2186: /*ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17138,7 +17154,7 @@ case 2186: /*ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2261: /*ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17153,7 +17169,7 @@ case 2261: /*ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2336: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17183,7 +17199,7 @@ case 2336: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2411: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17224,7 +17240,7 @@ case 2411: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_VAR_TMP: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -17267,12 +17283,12 @@ case 2411: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2061: /*ZEND_FETCH_OBJ_R_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_VAR_TMP; + return zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2136: /*ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17321,7 +17337,7 @@ case 2136: /*ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2211: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17352,7 +17368,7 @@ case 2211: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2286: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -17394,7 +17410,7 @@ case 2286: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2361: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -17427,11 +17443,11 @@ case 2361: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_VAR_TMP; + return zend_fetch_property_address_read_helper_SPEC_VAR_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2436: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -17474,7 +17490,7 @@ case 2436: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3411: /*ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17504,7 +17520,7 @@ case 3411: /*ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3686: /*ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -17585,7 +17601,7 @@ case 3686: /*ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 961: /*ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17640,7 +17656,7 @@ case 961: /*ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_TMP_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 2811: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -17714,7 +17730,7 @@ case 2811: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2836: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -17832,7 +17848,7 @@ case 2836: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1211: /*ZEND_CASE_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17850,7 +17866,7 @@ case 1211: /*ZEND_CASE_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1811: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -17894,18 +17910,18 @@ case 1811: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_VAR_TMP; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_VAR_TMP: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -17936,7 +17952,7 @@ case 1811: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN ZEND_VM_NEXT_OPCODE(); } -case 1786: /*ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -17945,12 +17961,12 @@ case 1786: /*ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1886: /*ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -17988,7 +18004,7 @@ case 1886: /*ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER*/ if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -18004,7 +18020,7 @@ case 1886: /*ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_VAR_TMP: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -18050,7 +18066,7 @@ case 1886: /*ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1911: /*ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18091,7 +18107,7 @@ case 1911: /*ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18115,12 +18131,12 @@ case 1911: /*ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_VAR_TMP; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_VAR_TMP: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -18130,7 +18146,7 @@ case 1911: /*ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -18235,17 +18251,17 @@ case 1911: /*ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2886: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3711: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4011: /*ZEND_YIELD_SPEC_VAR_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -18401,7 +18417,7 @@ case 4011: /*ZEND_YIELD_SPEC_VAR_TMP_HANDLER*/ ZEND_VM_RETURN(); } -case 37: /*ZEND_ADD_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18416,7 +18432,7 @@ case 37: /*ZEND_ADD_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 62: /*ZEND_SUB_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18431,7 +18447,7 @@ case 62: /*ZEND_SUB_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 87: /*ZEND_MUL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18446,7 +18462,7 @@ case 87: /*ZEND_MUL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 112: /*ZEND_DIV_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18461,7 +18477,7 @@ case 112: /*ZEND_DIV_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 137: /*ZEND_MOD_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18476,7 +18492,7 @@ case 137: /*ZEND_MOD_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 162: /*ZEND_SL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18491,7 +18507,7 @@ case 162: /*ZEND_SL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 187: /*ZEND_SR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18506,7 +18522,7 @@ case 187: /*ZEND_SR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 212: /*ZEND_CONCAT_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18521,7 +18537,7 @@ case 212: /*ZEND_CONCAT_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 387: /*ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18536,7 +18552,7 @@ case 387: /*ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 412: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18553,7 +18569,7 @@ case 412: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 437: /*ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18569,7 +18585,7 @@ case 437: /*ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 462: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18585,7 +18601,7 @@ case 462: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 487: /*ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18601,7 +18617,7 @@ case 487: /*ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 512: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18617,7 +18633,7 @@ case 512: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 237: /*ZEND_BW_OR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18632,7 +18648,7 @@ case 237: /*ZEND_BW_OR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 262: /*ZEND_BW_AND_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18647,7 +18663,7 @@ case 262: /*ZEND_BW_AND_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 287: /*ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18662,7 +18678,7 @@ case 287: /*ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -18677,7 +18693,7 @@ case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data1; @@ -18789,7 +18805,7 @@ case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_op_data2, free_op_data1; @@ -18799,7 +18815,7 @@ case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -18810,7 +18826,7 @@ case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_obj_helper_SPEC_VAR_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -18879,62 +18895,62 @@ case 362: /*ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 587: /*ZEND_ASSIGN_ADD_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 612: /*ZEND_ASSIGN_SUB_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 637: /*ZEND_ASSIGN_MUL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 662: /*ZEND_ASSIGN_DIV_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 687: /*ZEND_ASSIGN_MOD_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 712: /*ZEND_ASSIGN_SL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 737: /*ZEND_ASSIGN_SR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 762: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 787: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 812: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 837: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_VAR; + return zend_binary_assign_op_helper_SPEC_VAR_VAR(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19028,17 +19044,17 @@ case 837: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3312: /*ZEND_PRE_INC_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_VAR; + return zend_pre_incdec_property_helper_SPEC_VAR_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3337: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_VAR; + return zend_pre_incdec_property_helper_SPEC_VAR_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19130,17 +19146,17 @@ case 3337: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3362: /*ZEND_POST_INC_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_VAR; + return zend_post_incdec_property_helper_SPEC_VAR_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3387: /*ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_VAR; + return zend_post_incdec_property_helper_SPEC_VAR_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_var_address_helper_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -19272,39 +19288,39 @@ case 3387: /*ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2012: /*ZEND_FETCH_R_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; + return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2087: /*ZEND_FETCH_W_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; + return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2162: /*ZEND_FETCH_RW_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; + return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2312: /*ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; + return zend_fetch_var_address_helper_SPEC_VAR_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2387: /*ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; + return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2237: /*ZEND_FETCH_IS_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_VAR_VAR; + return zend_fetch_var_address_helper_SPEC_VAR_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2037: /*ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19334,7 +19350,7 @@ case 2037: /*ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2112: /*ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19368,7 +19384,7 @@ case 2112: /*ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2187: /*ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19390,7 +19406,7 @@ case 2187: /*ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2262: /*ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19405,7 +19421,7 @@ case 2262: /*ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2337: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19435,7 +19451,7 @@ case 2337: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2412: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19476,7 +19492,7 @@ case 2412: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -19519,12 +19535,12 @@ case 2412: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2062: /*ZEND_FETCH_OBJ_R_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_VAR_VAR; + return zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2137: /*ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19573,7 +19589,7 @@ case 2137: /*ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2212: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19604,7 +19620,7 @@ case 2212: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2287: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -19646,7 +19662,7 @@ case 2287: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2362: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -19679,11 +19695,11 @@ case 2362: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_VAR_VAR; + return zend_fetch_property_address_read_helper_SPEC_VAR_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2437: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -19726,7 +19742,7 @@ case 2437: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3412: /*ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19756,7 +19772,7 @@ case 3412: /*ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3687: /*ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -19837,7 +19853,7 @@ case 3687: /*ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 962: /*ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19893,7 +19909,7 @@ case 962: /*ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_VAR_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 987: /*ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -19916,7 +19932,7 @@ case 987: /*ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER*/ if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; HANDLE_EXCEPTION(); } - goto ZEND_ASSIGN_SPEC_VAR_VAR_LABEL; + return ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else if (IS_VAR == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -19947,7 +19963,7 @@ case 987: /*ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2812: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -20021,7 +20037,7 @@ case 2812: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2837: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -20139,7 +20155,7 @@ case 2837: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1212: /*ZEND_CASE_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20157,7 +20173,7 @@ case 1212: /*ZEND_CASE_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1812: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -20201,18 +20217,18 @@ case 1812: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_VAR_VAR; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_VAR_VAR: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -20243,7 +20259,7 @@ case 1812: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMEN ZEND_VM_NEXT_OPCODE(); } -case 1787: /*ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -20252,12 +20268,12 @@ case 1787: /*ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1862: /*ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -20333,7 +20349,7 @@ case 1862: /*ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1887: /*ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20371,7 +20387,7 @@ case 1887: /*ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER*/ if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -20387,7 +20403,7 @@ case 1887: /*ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_VAR_VAR: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -20433,7 +20449,7 @@ case 1887: /*ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1912: /*ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20474,7 +20490,7 @@ case 1912: /*ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2862: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -20559,7 +20575,7 @@ case 2862: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -20583,12 +20599,12 @@ case 2862: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_VAR_VAR; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_VAR_VAR: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -20598,7 +20614,7 @@ case 2862: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -20703,17 +20719,17 @@ case 2862: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2887: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3712: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -20870,7 +20886,7 @@ case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_RETURN(); } -zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op_data1; @@ -20982,7 +20998,7 @@ case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_VAR_UNUSED: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op_data2, free_op_data1; @@ -20992,7 +21008,7 @@ case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -21003,7 +21019,7 @@ case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_obj_helper_SPEC_VAR_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = NULL; @@ -21071,62 +21087,62 @@ case 4012: /*ZEND_YIELD_SPEC_VAR_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 588: /*ZEND_ASSIGN_ADD_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 613: /*ZEND_ASSIGN_SUB_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 638: /*ZEND_ASSIGN_MUL_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 663: /*ZEND_ASSIGN_DIV_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 688: /*ZEND_ASSIGN_MOD_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 713: /*ZEND_ASSIGN_SL_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 738: /*ZEND_ASSIGN_SR_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 763: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 788: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 813: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 838: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_UNUSED; + return zend_binary_assign_op_helper_SPEC_VAR_UNUSED(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_var_address_helper_SPEC_VAR_UNUSED: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_VAR_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -21258,39 +21274,39 @@ case 838: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2013: /*ZEND_FETCH_R_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2088: /*ZEND_FETCH_W_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2163: /*ZEND_FETCH_RW_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2313: /*ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2388: /*ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2238: /*ZEND_FETCH_IS_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_VAR_UNUSED; + return zend_fetch_var_address_helper_SPEC_VAR_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2113: /*ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -21324,7 +21340,7 @@ case 2113: /*ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2188: /*ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -21346,7 +21362,7 @@ case 2188: /*ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2338: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -21376,7 +21392,7 @@ case 2338: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3688: /*ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -21456,7 +21472,7 @@ case 3688: /*ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2838: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -21574,7 +21590,7 @@ case 2838: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1813: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -21618,18 +21634,18 @@ case 1813: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELE switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_VAR_UNUSED; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_VAR_UNUSED: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_UNUSED); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -21660,7 +21676,7 @@ case 1813: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELE ZEND_VM_NEXT_OPCODE(); } -case 1788: /*ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -21669,12 +21685,12 @@ case 1788: /*ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1863: /*ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -21750,7 +21766,7 @@ case 1863: /*ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2863: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -21835,7 +21851,7 @@ case 2863: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3913: /*ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *var_ptr, *new_zv; @@ -21856,7 +21872,7 @@ case 3913: /*ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4013: /*ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -22012,7 +22028,7 @@ case 4013: /*ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER*/ ZEND_VM_RETURN(); } -case 39: /*ZEND_ADD_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22027,7 +22043,7 @@ case 39: /*ZEND_ADD_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 64: /*ZEND_SUB_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22042,7 +22058,7 @@ case 64: /*ZEND_SUB_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 89: /*ZEND_MUL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22057,7 +22073,7 @@ case 89: /*ZEND_MUL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 114: /*ZEND_DIV_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22072,7 +22088,7 @@ case 114: /*ZEND_DIV_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 139: /*ZEND_MOD_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22087,7 +22103,7 @@ case 139: /*ZEND_MOD_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 164: /*ZEND_SL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22102,7 +22118,7 @@ case 164: /*ZEND_SL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 189: /*ZEND_SR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22117,7 +22133,7 @@ case 189: /*ZEND_SR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 214: /*ZEND_CONCAT_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22132,7 +22148,7 @@ case 214: /*ZEND_CONCAT_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 389: /*ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22147,7 +22163,7 @@ case 389: /*ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 414: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22164,7 +22180,7 @@ case 414: /*ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 439: /*ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22180,7 +22196,7 @@ case 439: /*ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 464: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22196,7 +22212,7 @@ case 464: /*ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 489: /*ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22212,7 +22228,7 @@ case 489: /*ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 514: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22228,7 +22244,7 @@ case 514: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 239: /*ZEND_BW_OR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22243,7 +22259,7 @@ case 239: /*ZEND_BW_OR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 264: /*ZEND_BW_AND_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22258,7 +22274,7 @@ case 264: /*ZEND_BW_AND_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 289: /*ZEND_BW_XOR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22273,7 +22289,7 @@ case 289: /*ZEND_BW_XOR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22288,7 +22304,7 @@ case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_VAR_CV: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op_data1; @@ -22400,7 +22416,7 @@ case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_VAR_CV: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op_data2, free_op_data1; @@ -22410,7 +22426,7 @@ case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CV; + return zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_var(opline->op1.var, execute_data, &free_op1 TSRMLS_CC); @@ -22421,7 +22437,7 @@ case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ if (IS_VAR == IS_VAR && !(free_op1.var != NULL)) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_VAR_CV; + return zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); @@ -22489,62 +22505,62 @@ case 364: /*ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 589: /*ZEND_ASSIGN_ADD_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 614: /*ZEND_ASSIGN_SUB_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 639: /*ZEND_ASSIGN_MUL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 664: /*ZEND_ASSIGN_DIV_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 689: /*ZEND_ASSIGN_MOD_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 714: /*ZEND_ASSIGN_SL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 739: /*ZEND_ASSIGN_SR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 764: /*ZEND_ASSIGN_CONCAT_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 789: /*ZEND_ASSIGN_BW_OR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 814: /*ZEND_ASSIGN_BW_AND_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 839: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_VAR_CV; + return zend_binary_assign_op_helper_SPEC_VAR_CV(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_VAR_CV: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_VAR_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22638,17 +22654,17 @@ case 839: /*ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3314: /*ZEND_PRE_INC_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CV; + return zend_pre_incdec_property_helper_SPEC_VAR_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3339: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_VAR_CV; + return zend_pre_incdec_property_helper_SPEC_VAR_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_VAR_CV: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_VAR_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22740,17 +22756,17 @@ case 3339: /*ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3364: /*ZEND_POST_INC_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_VAR_CV; + return zend_post_incdec_property_helper_SPEC_VAR_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3389: /*ZEND_POST_DEC_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_VAR_CV; + return zend_post_incdec_property_helper_SPEC_VAR_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2039: /*ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22780,7 +22796,7 @@ case 2039: /*ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2114: /*ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22814,7 +22830,7 @@ case 2114: /*ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2189: /*ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22836,7 +22852,7 @@ case 2189: /*ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2264: /*ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22851,7 +22867,7 @@ case 2264: /*ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2339: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22881,7 +22897,7 @@ case 2339: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2414: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22922,7 +22938,7 @@ case 2414: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_VAR_CV: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -22965,12 +22981,12 @@ case 2414: /*ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2064: /*ZEND_FETCH_OBJ_R_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_VAR_CV; + return zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2139: /*ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23019,7 +23035,7 @@ case 2139: /*ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2214: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23050,7 +23066,7 @@ case 2214: /*ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2289: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23092,7 +23108,7 @@ case 2289: /*ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2364: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -23125,11 +23141,11 @@ case 2364: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_VAR_CV; + return zend_fetch_property_address_read_helper_SPEC_VAR_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2439: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_res; @@ -23172,7 +23188,7 @@ case 2439: /*ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3414: /*ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23202,7 +23218,7 @@ case 3414: /*ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3689: /*ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23282,7 +23298,7 @@ case 3689: /*ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 964: /*ZEND_ASSIGN_SPEC_VAR_CV_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_CV_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23337,7 +23353,7 @@ case 964: /*ZEND_ASSIGN_SPEC_VAR_CV_HANDLER*/ ZEND_ASSIGN_SPEC_VAR_CV_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 989: /*ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -23360,7 +23376,7 @@ case 989: /*ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER*/ HANDLE_EXCEPTION(); } - goto ZEND_ASSIGN_SPEC_VAR_CV_LABEL; + return ZEND_ASSIGN_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else if (IS_CV == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -23390,7 +23406,7 @@ case 989: /*ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2814: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -23463,7 +23479,7 @@ case 2814: /*ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2839: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -23581,7 +23597,7 @@ case 2839: /*ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1214: /*ZEND_CASE_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23598,7 +23614,7 @@ case 1214: /*ZEND_CASE_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1814: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23642,18 +23658,18 @@ case 1814: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_VAR_CV; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_VAR_CV: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_VAR_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -23684,7 +23700,7 @@ case 1814: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT ZEND_VM_NEXT_OPCODE(); } -case 1789: /*ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -23693,12 +23709,12 @@ case 1789: /*ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_VAR != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1889: /*ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23736,7 +23752,7 @@ case 1889: /*ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER*/ if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_VAR_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -23752,7 +23768,7 @@ case 1889: /*ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_VAR_CV: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_CV == IS_CV || IS_CV == IS_VAR) { zval_ptr_dtor(&offset); @@ -23798,7 +23814,7 @@ case 1889: /*ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1914: /*ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23839,7 +23855,7 @@ case 1914: /*ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -23863,12 +23879,12 @@ case 1914: /*ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_VAR_CV; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_VAR_CV: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -23878,7 +23894,7 @@ case 1914: /*ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_VAR_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -23983,17 +23999,17 @@ case 1914: /*ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2889: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3714: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4014: /*ZEND_YIELD_SPEC_VAR_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24149,7 +24165,7 @@ case 4014: /*ZEND_YIELD_SPEC_VAR_CV_HANDLER*/ ZEND_VM_RETURN(); } -case 2765: /*ZEND_CLONE_SPEC_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_CLONE_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24212,7 +24228,7 @@ case 2765: /*ZEND_CLONE_SPEC_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXIT_SPEC_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { #if 0 || (IS_UNUSED != IS_UNUSED) USE_OPLINE @@ -24234,7 +24250,7 @@ case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data1; @@ -24345,7 +24361,7 @@ case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_UNUSED_CONST: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -24355,7 +24371,7 @@ case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -24366,7 +24382,7 @@ case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = opline->op2.zv; @@ -24434,62 +24450,62 @@ case 1990: /*ZEND_EXIT_SPEC_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 590: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 615: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 640: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 665: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 690: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 715: /*ZEND_ASSIGN_SL_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 740: /*ZEND_ASSIGN_SR_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 765: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 790: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 815: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 840: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CONST; + return zend_binary_assign_op_helper_SPEC_UNUSED_CONST(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_UNUSED_CONST: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24583,17 +24599,17 @@ case 840: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3315: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CONST; + return zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3340: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CONST; + return zend_pre_incdec_property_helper_SPEC_UNUSED_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_UNUSED_CONST: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24685,17 +24701,17 @@ case 3340: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3365: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CONST; + return zend_post_incdec_property_helper_SPEC_UNUSED_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3390: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CONST; + return zend_post_incdec_property_helper_SPEC_UNUSED_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24737,12 +24753,12 @@ case 3390: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2065: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2140: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -24790,7 +24806,7 @@ case 2140: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2215: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -24821,7 +24837,7 @@ case 2215: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2290: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24862,7 +24878,7 @@ case 2290: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2365: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24895,11 +24911,11 @@ case 2365: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2440: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_res; @@ -24941,7 +24957,7 @@ case 2440: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3415: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -24971,7 +24987,7 @@ case 3415: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1365: /*ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -24994,7 +25010,7 @@ case 1365: /*ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1390: /*ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *str = &EX_T(opline->result.var).tmp_var; @@ -25017,7 +25033,7 @@ case 1390: /*ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2815: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -25089,7 +25105,7 @@ case 2815: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2490: /*ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -25181,7 +25197,7 @@ case 2490: /*ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER*/ } } -case 1790: /*ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -25190,12 +25206,12 @@ case 1790: /*ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CONST_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1890: /*ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -25233,7 +25249,7 @@ case 1890: /*ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER*/ if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -25249,7 +25265,7 @@ case 1890: /*ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_UNUSED_CONST: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { zval_ptr_dtor(&offset); @@ -25294,7 +25310,7 @@ case 1890: /*ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1915: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -25334,7 +25350,7 @@ case 1915: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -25358,12 +25374,12 @@ case 1915: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_UNUSED_CONST; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_UNUSED_CONST: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -25373,7 +25389,7 @@ case 1915: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -25476,17 +25492,17 @@ case 1915: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2890: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3715: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -25640,7 +25656,7 @@ case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_RETURN(); } -zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -25751,7 +25767,7 @@ case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_UNUSED_TMP: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -25761,7 +25777,7 @@ case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -25772,7 +25788,7 @@ case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -25841,62 +25857,62 @@ case 4015: /*ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 591: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 616: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 641: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 666: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 691: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 716: /*ZEND_ASSIGN_SL_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 741: /*ZEND_ASSIGN_SR_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 766: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 791: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 816: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 841: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_TMP; + return zend_binary_assign_op_helper_SPEC_UNUSED_TMP(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_UNUSED_TMP: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -25990,17 +26006,17 @@ case 841: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3316: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_TMP; + return zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3341: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_TMP; + return zend_pre_incdec_property_helper_SPEC_UNUSED_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_UNUSED_TMP: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -26092,17 +26108,17 @@ case 3341: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3366: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_TMP; + return zend_post_incdec_property_helper_SPEC_UNUSED_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3391: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_TMP; + return zend_post_incdec_property_helper_SPEC_UNUSED_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -26144,12 +26160,12 @@ case 3391: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2066: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2141: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -26197,7 +26213,7 @@ case 2141: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2216: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -26228,7 +26244,7 @@ case 2216: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2291: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -26269,7 +26285,7 @@ case 2291: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2366: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -26302,11 +26318,11 @@ case 2366: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2441: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -26348,7 +26364,7 @@ case 2441: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3416: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -26378,7 +26394,7 @@ case 3416: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1416: /*ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -26423,7 +26439,7 @@ case 1416: /*ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2816: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -26496,7 +26512,7 @@ case 2816: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1791: /*ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -26505,12 +26521,12 @@ case 1791: /*ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_TMP_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1891: /*ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -26548,7 +26564,7 @@ case 1891: /*ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER*/ if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -26564,7 +26580,7 @@ case 1891: /*ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_UNUSED_TMP: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -26609,7 +26625,7 @@ case 1891: /*ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1916: /*ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -26649,7 +26665,7 @@ case 1916: /*ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -26673,12 +26689,12 @@ case 1916: /*ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_UNUSED_TMP; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_UNUSED_TMP: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -26688,7 +26704,7 @@ case 1916: /*ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -26791,17 +26807,17 @@ case 1916: /*ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2891: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3716: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -26955,7 +26971,7 @@ case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_RETURN(); } -zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -27066,7 +27082,7 @@ case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_UNUSED_VAR: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -27076,7 +27092,7 @@ case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -27087,7 +27103,7 @@ case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -27156,62 +27172,62 @@ case 4016: /*ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 592: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 617: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 642: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 667: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 692: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 717: /*ZEND_ASSIGN_SL_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 742: /*ZEND_ASSIGN_SR_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 767: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 792: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 817: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 842: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_VAR; + return zend_binary_assign_op_helper_SPEC_UNUSED_VAR(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_UNUSED_VAR: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27305,17 +27321,17 @@ case 842: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3317: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_VAR; + return zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3342: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_VAR; + return zend_pre_incdec_property_helper_SPEC_UNUSED_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_UNUSED_VAR: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27407,17 +27423,17 @@ case 3342: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3367: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_VAR; + return zend_post_incdec_property_helper_SPEC_UNUSED_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3392: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_VAR; + return zend_post_incdec_property_helper_SPEC_UNUSED_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -27459,12 +27475,12 @@ case 3392: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2067: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2142: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -27512,7 +27528,7 @@ case 2142: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2217: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -27543,7 +27559,7 @@ case 2217: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2292: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -27584,7 +27600,7 @@ case 2292: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2367: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -27617,11 +27633,11 @@ case 2367: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2442: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -27663,7 +27679,7 @@ case 2442: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3417: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27693,7 +27709,7 @@ case 3417: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1417: /*ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27738,7 +27754,7 @@ case 1417: /*ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2817: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -27811,7 +27827,7 @@ case 2817: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1792: /*ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -27820,12 +27836,12 @@ case 1792: /*ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_VAR_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1892: /*ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27863,7 +27879,7 @@ case 1892: /*ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER*/ if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -27879,7 +27895,7 @@ case 1892: /*ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_UNUSED_VAR: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -27924,7 +27940,7 @@ case 1892: /*ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1917: /*ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27964,7 +27980,7 @@ case 1917: /*ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -27988,12 +28004,12 @@ case 1917: /*ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_UNUSED_VAR; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_UNUSED_VAR: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -28003,7 +28019,7 @@ case 1917: /*ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -28106,17 +28122,17 @@ case 1917: /*ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2892: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3717: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -28271,7 +28287,7 @@ case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_RETURN(); } -zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data1; @@ -28382,7 +28398,7 @@ case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -28392,7 +28408,7 @@ case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -28403,7 +28419,7 @@ case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = NULL; @@ -28471,62 +28487,62 @@ case 4017: /*ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 593: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 618: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 643: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 668: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 693: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 718: /*ZEND_ASSIGN_SL_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 743: /*ZEND_ASSIGN_SR_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 768: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 793: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 818: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 843: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED; + return zend_binary_assign_op_helper_SPEC_UNUSED_UNUSED(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1793: /*ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -28535,12 +28551,12 @@ case 1793: /*ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_UNUSED_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -28694,7 +28710,7 @@ case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ ZEND_VM_RETURN(); } -zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data1; @@ -28805,7 +28821,7 @@ case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_UNUSED_CV: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -28815,7 +28831,7 @@ case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_obj_zval_ptr_ptr_unused(TSRMLS_C); @@ -28826,7 +28842,7 @@ case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ if (IS_UNUSED == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); @@ -28894,62 +28910,62 @@ case 4018: /*ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 594: /*ZEND_ASSIGN_ADD_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 619: /*ZEND_ASSIGN_SUB_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 644: /*ZEND_ASSIGN_MUL_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 669: /*ZEND_ASSIGN_DIV_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 694: /*ZEND_ASSIGN_MOD_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 719: /*ZEND_ASSIGN_SL_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 744: /*ZEND_ASSIGN_SR_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 769: /*ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 794: /*ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 819: /*ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 844: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_UNUSED_CV; + return zend_binary_assign_op_helper_SPEC_UNUSED_CV(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_UNUSED_CV: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_UNUSED_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29043,17 +29059,17 @@ case 844: /*ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3319: /*ZEND_PRE_INC_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CV; + return zend_pre_incdec_property_helper_SPEC_UNUSED_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3344: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_UNUSED_CV; + return zend_pre_incdec_property_helper_SPEC_UNUSED_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_UNUSED_CV: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_UNUSED_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29145,17 +29161,17 @@ case 3344: /*ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3369: /*ZEND_POST_INC_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CV; + return zend_post_incdec_property_helper_SPEC_UNUSED_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3394: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_UNUSED_CV; + return zend_post_incdec_property_helper_SPEC_UNUSED_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_property_address_read_helper_SPEC_UNUSED_CV: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_UNUSED_CV(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29197,12 +29213,12 @@ case 3394: /*ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2069: /*ZEND_FETCH_OBJ_R_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CV; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2144: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -29250,7 +29266,7 @@ case 2144: /*ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2219: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -29281,7 +29297,7 @@ case 2219: /*ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2294: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29322,7 +29338,7 @@ case 2294: /*ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2369: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29355,11 +29371,11 @@ case 2369: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_UNUSED_CV; + return zend_fetch_property_address_read_helper_SPEC_UNUSED_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2444: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_res; @@ -29401,7 +29417,7 @@ case 2444: /*ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3419: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29431,7 +29447,7 @@ case 3419: /*ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1419: /*ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29475,7 +29491,7 @@ case 1419: /*ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2819: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -29547,7 +29563,7 @@ case 2819: /*ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1794: /*ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29556,12 +29572,12 @@ case 1794: /*ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_UNUSED != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CV_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1894: /*ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29599,7 +29615,7 @@ case 1894: /*ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER*/ if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_UNUSED_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -29615,7 +29631,7 @@ case 1894: /*ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_UNUSED_CV: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_CV == IS_CV || IS_CV == IS_VAR) { zval_ptr_dtor(&offset); @@ -29660,7 +29676,7 @@ case 1894: /*ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1919: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29700,7 +29716,7 @@ case 1919: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -29724,12 +29740,12 @@ case 1919: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_UNUSED_CV; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_UNUSED_CV: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -29739,7 +29755,7 @@ case 1919: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_UNUSED_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -29842,17 +29858,17 @@ case 1919: /*ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2894: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3719: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4019: /*ZEND_YIELD_SPEC_UNUSED_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30006,7 +30022,7 @@ case 4019: /*ZEND_YIELD_SPEC_UNUSED_CV_HANDLER*/ ZEND_VM_RETURN(); } -case 320: /*ZEND_BW_NOT_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30019,7 +30035,7 @@ case 320: /*ZEND_BW_NOT_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 345: /*ZEND_BOOL_NOT_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_NOT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30032,7 +30048,7 @@ case 345: /*ZEND_BOOL_NOT_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 870: /*ZEND_PRE_INC_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30078,7 +30094,7 @@ case 870: /*ZEND_PRE_INC_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 895: /*ZEND_PRE_DEC_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30124,7 +30140,7 @@ case 895: /*ZEND_PRE_DEC_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 920: /*ZEND_POST_INC_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30166,7 +30182,7 @@ case 920: /*ZEND_POST_INC_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 945: /*ZEND_POST_DEC_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30208,7 +30224,7 @@ case 945: /*ZEND_POST_DEC_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1020: /*ZEND_ECHO_SPEC_CV_HANDLER*/ ZEND_ECHO_SPEC_CV_LABEL: +static int ZEND_FASTCALL ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30238,15 +30254,15 @@ case 1020: /*ZEND_ECHO_SPEC_CV_HANDLER*/ ZEND_ECHO_SPEC_CV_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 1045: /*ZEND_PRINT_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRINT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE ZVAL_LONG(&EX_T(opline->result.var).tmp_var, 1); - goto ZEND_ECHO_SPEC_CV_LABEL; + return ZEND_ECHO_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1095: /*ZEND_JMPZ_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30276,7 +30292,7 @@ case 1095: /*ZEND_JMPZ_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1120: /*ZEND_JMPNZ_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30306,7 +30322,7 @@ case 1120: /*ZEND_JMPNZ_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1145: /*ZEND_JMPZNZ_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZNZ_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30340,7 +30356,7 @@ case 1145: /*ZEND_JMPZNZ_SPEC_CV_HANDLER*/ } } -case 1170: /*ZEND_JMPZ_EX_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30371,7 +30387,7 @@ case 1170: /*ZEND_JMPZ_EX_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1195: /*ZEND_JMPNZ_EX_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMPNZ_EX_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30402,7 +30418,7 @@ case 1195: /*ZEND_JMPNZ_EX_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1570: /*ZEND_RETURN_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -30449,10 +30465,10 @@ case 1570: /*ZEND_RETURN_SPEC_CV_HANDLER*/ *EG(return_value_ptr_ptr) = ret; } - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2795: /*ZEND_RETURN_BY_REF_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_RETURN_BY_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *retval_ptr; @@ -30520,10 +30536,10 @@ case 2795: /*ZEND_RETURN_BY_REF_SPEC_CV_HANDLER*/ } } while (0); - goto zend_leave_helper_SPEC; + return zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2720: /*ZEND_THROW_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_THROW_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *value; @@ -30550,7 +30566,7 @@ case 2720: /*ZEND_THROW_SPEC_CV_HANDLER*/ HANDLE_EXCEPTION(); } -zend_send_by_var_helper_SPEC_CV: +static int ZEND_FASTCALL zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *varptr; @@ -30578,7 +30594,7 @@ case 2720: /*ZEND_THROW_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2670: /*ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -30587,10 +30603,10 @@ case 2670: /*ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER*/ SAVE_OPLINE(); if (opline->extended_value & ZEND_ARG_COMPILE_TIME_BOUND) { /* Had function_ptr at compile_time */ if (!(opline->extended_value & ZEND_ARG_SEND_BY_REF)) { - goto zend_send_by_var_helper_SPEC_CV; + return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } else if (!ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - goto zend_send_by_var_helper_SPEC_CV; + return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } if (IS_CV == IS_VAR && @@ -30630,7 +30646,7 @@ case 2670: /*ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1695: /*ZEND_SEND_REF_SPEC_CV_HANDLER*/ ZEND_SEND_REF_SPEC_CV_LABEL: +static int ZEND_FASTCALL ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30652,7 +30668,7 @@ case 1695: /*ZEND_SEND_REF_SPEC_CV_HANDLER*/ ZEND_SEND_REF_SPEC_CV_LABEL: } if (EX(function_state).function->type == ZEND_INTERNAL_FUNCTION && !ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - goto zend_send_by_var_helper_SPEC_CV; + return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } SEPARATE_ZVAL_TO_MAKE_IS_REF(varptr_ptr); @@ -30664,19 +30680,19 @@ case 1695: /*ZEND_SEND_REF_SPEC_CV_HANDLER*/ ZEND_SEND_REF_SPEC_CV_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 1670: /*ZEND_SEND_VAR_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SEND_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE if ((opline->extended_value == ZEND_DO_FCALL_BY_NAME) && ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, opline->op2.opline_num)) { - goto ZEND_SEND_REF_SPEC_CV_LABEL; + return ZEND_SEND_REF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } SAVE_OPLINE(); - goto zend_send_by_var_helper_SPEC_CV; + return zend_send_by_var_helper_SPEC_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 1320: /*ZEND_BOOL_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30690,7 +30706,7 @@ case 1320: /*ZEND_BOOL_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2770: /*ZEND_CLONE_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CLONE_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30753,7 +30769,7 @@ case 2770: /*ZEND_CLONE_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 545: /*ZEND_CAST_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CAST_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -30812,7 +30828,7 @@ case 545: /*ZEND_CAST_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1845: /*ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_op_array *new_op_array=NULL; @@ -30946,7 +30962,7 @@ case 1845: /*ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1945: /*ZEND_FE_RESET_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31088,7 +31104,7 @@ case 1945: /*ZEND_FE_RESET_SPEC_CV_HANDLER*/ } } -case 1995: /*ZEND_EXIT_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_EXIT_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { #if 0 || (IS_CV != IS_UNUSED) USE_OPLINE @@ -31110,7 +31126,7 @@ case 1995: /*ZEND_EXIT_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); /* Never reached */ } -case 3820: /*ZEND_JMP_SET_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31135,7 +31151,7 @@ case 3820: /*ZEND_JMP_SET_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3970: /*ZEND_JMP_SET_VAR_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_JMP_SET_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31169,7 +31185,7 @@ case 3970: /*ZEND_JMP_SET_VAR_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 570: /*ZEND_QM_ASSIGN_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31187,7 +31203,7 @@ case 570: /*ZEND_QM_ASSIGN_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3945: /*ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31214,7 +31230,7 @@ case 3945: /*ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3470: /*ZEND_INSTANCEOF_SPEC_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INSTANCEOF_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31235,7 +31251,7 @@ case 3470: /*ZEND_INSTANCEOF_SPEC_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 45: /*ZEND_ADD_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31250,7 +31266,7 @@ case 45: /*ZEND_ADD_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 70: /*ZEND_SUB_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31265,7 +31281,7 @@ case 70: /*ZEND_SUB_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 95: /*ZEND_MUL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31280,7 +31296,7 @@ case 95: /*ZEND_MUL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 120: /*ZEND_DIV_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31295,7 +31311,7 @@ case 120: /*ZEND_DIV_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 145: /*ZEND_MOD_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31310,7 +31326,7 @@ case 145: /*ZEND_MOD_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 170: /*ZEND_SL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31325,7 +31341,7 @@ case 170: /*ZEND_SL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 195: /*ZEND_SR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31340,7 +31356,7 @@ case 195: /*ZEND_SR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 220: /*ZEND_CONCAT_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31355,7 +31371,7 @@ case 220: /*ZEND_CONCAT_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 395: /*ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31370,7 +31386,7 @@ case 395: /*ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 420: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31387,7 +31403,7 @@ case 420: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 445: /*ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31403,7 +31419,7 @@ case 445: /*ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 470: /*ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31419,7 +31435,7 @@ case 470: /*ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 495: /*ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31435,7 +31451,7 @@ case 495: /*ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 520: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31451,7 +31467,7 @@ case 520: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 245: /*ZEND_BW_OR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31466,7 +31482,7 @@ case 245: /*ZEND_BW_OR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 270: /*ZEND_BW_AND_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31481,7 +31497,7 @@ case 270: /*ZEND_BW_AND_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 295: /*ZEND_BW_XOR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31496,7 +31512,7 @@ case 295: /*ZEND_BW_XOR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31511,7 +31527,7 @@ case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data1; @@ -31622,7 +31638,7 @@ case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -31632,7 +31648,7 @@ case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CONST; + return zend_binary_assign_op_obj_helper_SPEC_CV_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -31643,7 +31659,7 @@ case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CONST; + return zend_binary_assign_op_obj_helper_SPEC_CV_CONST(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = opline->op2.zv; @@ -31711,62 +31727,62 @@ case 370: /*ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 595: /*ZEND_ASSIGN_ADD_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 620: /*ZEND_ASSIGN_SUB_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 645: /*ZEND_ASSIGN_MUL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 670: /*ZEND_ASSIGN_DIV_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 695: /*ZEND_ASSIGN_MOD_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 720: /*ZEND_ASSIGN_SL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 745: /*ZEND_ASSIGN_SR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 770: /*ZEND_ASSIGN_CONCAT_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 795: /*ZEND_ASSIGN_BW_OR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 820: /*ZEND_ASSIGN_BW_AND_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 845: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_CONST; + return zend_binary_assign_op_helper_SPEC_CV_CONST(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31860,17 +31876,17 @@ case 845: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3320: /*ZEND_PRE_INC_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_CONST; + return zend_pre_incdec_property_helper_SPEC_CV_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3345: /*ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_CONST; + return zend_pre_incdec_property_helper_SPEC_CV_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CONST(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -31962,17 +31978,17 @@ case 3345: /*ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3370: /*ZEND_POST_INC_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_CONST; + return zend_post_incdec_property_helper_SPEC_CV_CONST(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3395: /*ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_CONST; + return zend_post_incdec_property_helper_SPEC_CV_CONST(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_var_address_helper_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_CONST(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32104,39 +32120,39 @@ case 3395: /*ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2020: /*ZEND_FETCH_R_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_CONST; + return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2095: /*ZEND_FETCH_W_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CV_CONST; + return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2170: /*ZEND_FETCH_RW_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CV_CONST; + return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2320: /*ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_CONST; + return zend_fetch_var_address_helper_SPEC_CV_CONST(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2395: /*ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CV_CONST; + return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2245: /*ZEND_FETCH_IS_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CV_CONST; + return zend_fetch_var_address_helper_SPEC_CV_CONST(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2045: /*ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32166,7 +32182,7 @@ case 2045: /*ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2120: /*ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32199,7 +32215,7 @@ case 2120: /*ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2195: /*ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32221,7 +32237,7 @@ case 2195: /*ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2270: /*ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32236,7 +32252,7 @@ case 2270: /*ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2345: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32266,7 +32282,7 @@ case 2345: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2420: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32307,7 +32323,7 @@ case 2420: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CONST(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32349,12 +32365,12 @@ case 2420: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2070: /*ZEND_FETCH_OBJ_R_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_CV_CONST; + return zend_fetch_property_address_read_helper_SPEC_CV_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2145: /*ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32402,7 +32418,7 @@ case 2145: /*ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2220: /*ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -32433,7 +32449,7 @@ case 2220: /*ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2295: /*ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32474,7 +32490,7 @@ case 2295: /*ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2370: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32507,11 +32523,11 @@ case 2370: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_CV_CONST; + return zend_fetch_property_address_read_helper_SPEC_CV_CONST(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2445: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_res; @@ -32553,7 +32569,7 @@ case 2445: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3420: /*ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32583,7 +32599,7 @@ case 3420: /*ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3695: /*ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32663,7 +32679,7 @@ case 3695: /*ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 970: /*ZEND_ASSIGN_SPEC_CV_CONST_HANDLER*/ ZEND_ASSIGN_SPEC_CV_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32716,7 +32732,7 @@ case 970: /*ZEND_ASSIGN_SPEC_CV_CONST_HANDLER*/ ZEND_ASSIGN_SPEC_CV_CONST_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 2820: /*ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -32788,7 +32804,7 @@ case 2820: /*ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1220: /*ZEND_CASE_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32805,7 +32821,7 @@ case 1220: /*ZEND_CASE_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1820: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32849,18 +32865,18 @@ case 1820: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEME switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CV_CONST; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CV_CONST: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -32891,7 +32907,7 @@ case 1820: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER*/ ZEND_ADD_ARRAY_ELEME ZEND_VM_NEXT_OPCODE(); } -case 1795: /*ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -32900,12 +32916,12 @@ case 1795: /*ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1870: /*ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -32981,7 +32997,7 @@ case 1870: /*ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1895: /*ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -33019,7 +33035,7 @@ case 1895: /*ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER*/ if (IS_CONST == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -33035,7 +33051,7 @@ case 1895: /*ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_CV_CONST: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_CONST == IS_CV || IS_CONST == IS_VAR) { zval_ptr_dtor(&offset); @@ -33080,7 +33096,7 @@ case 1895: /*ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1920: /*ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -33120,7 +33136,7 @@ case 1920: /*ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2870: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -33205,7 +33221,7 @@ case 2870: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -33229,12 +33245,12 @@ case 2870: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_CV_CONST; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_CV_CONST: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -33244,7 +33260,7 @@ case 2870: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_CONST); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -33347,17 +33363,17 @@ case 2870: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2895: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3720: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4020: /*ZEND_YIELD_SPEC_CV_CONST_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -33511,7 +33527,7 @@ case 4020: /*ZEND_YIELD_SPEC_CV_CONST_HANDLER*/ ZEND_VM_RETURN(); } -case 46: /*ZEND_ADD_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33526,7 +33542,7 @@ case 46: /*ZEND_ADD_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 71: /*ZEND_SUB_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33541,7 +33557,7 @@ case 71: /*ZEND_SUB_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 96: /*ZEND_MUL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33556,7 +33572,7 @@ case 96: /*ZEND_MUL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 121: /*ZEND_DIV_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33571,7 +33587,7 @@ case 121: /*ZEND_DIV_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 146: /*ZEND_MOD_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33586,7 +33602,7 @@ case 146: /*ZEND_MOD_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 171: /*ZEND_SL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33601,7 +33617,7 @@ case 171: /*ZEND_SL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 196: /*ZEND_SR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33616,7 +33632,7 @@ case 196: /*ZEND_SR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 221: /*ZEND_CONCAT_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33631,7 +33647,7 @@ case 221: /*ZEND_CONCAT_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 396: /*ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33646,7 +33662,7 @@ case 396: /*ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 421: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33663,7 +33679,7 @@ case 421: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 446: /*ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33679,7 +33695,7 @@ case 446: /*ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 471: /*ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33695,7 +33711,7 @@ case 471: /*ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 496: /*ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33711,7 +33727,7 @@ case 496: /*ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 521: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33727,7 +33743,7 @@ case 521: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 246: /*ZEND_BW_OR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33742,7 +33758,7 @@ case 246: /*ZEND_BW_OR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 271: /*ZEND_BW_AND_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33757,7 +33773,7 @@ case 271: /*ZEND_BW_AND_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 296: /*ZEND_BW_XOR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33772,7 +33788,7 @@ case 296: /*ZEND_BW_XOR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -33787,7 +33803,7 @@ case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_CV_TMP: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -33898,7 +33914,7 @@ case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_CV_TMP: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMP(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -33908,7 +33924,7 @@ case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_TMP; + return zend_binary_assign_op_obj_helper_SPEC_CV_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -33919,7 +33935,7 @@ case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_TMP; + return zend_binary_assign_op_obj_helper_SPEC_CV_TMP(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_tmp(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -33988,62 +34004,62 @@ case 371: /*ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 596: /*ZEND_ASSIGN_ADD_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 621: /*ZEND_ASSIGN_SUB_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 646: /*ZEND_ASSIGN_MUL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 671: /*ZEND_ASSIGN_DIV_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 696: /*ZEND_ASSIGN_MOD_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 721: /*ZEND_ASSIGN_SL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 746: /*ZEND_ASSIGN_SR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 771: /*ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 796: /*ZEND_ASSIGN_BW_OR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 821: /*ZEND_ASSIGN_BW_AND_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 846: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_TMP; + return zend_binary_assign_op_helper_SPEC_CV_TMP(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_CV_TMP: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34137,17 +34153,17 @@ case 846: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3321: /*ZEND_PRE_INC_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_TMP; + return zend_pre_incdec_property_helper_SPEC_CV_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3346: /*ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_TMP; + return zend_pre_incdec_property_helper_SPEC_CV_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_CV_TMP: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_TMP(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34239,17 +34255,17 @@ case 3346: /*ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3371: /*ZEND_POST_INC_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_TMP; + return zend_post_incdec_property_helper_SPEC_CV_TMP(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3396: /*ZEND_POST_DEC_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_TMP; + return zend_post_incdec_property_helper_SPEC_CV_TMP(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2046: /*ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34279,7 +34295,7 @@ case 2046: /*ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2121: /*ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34312,7 +34328,7 @@ case 2121: /*ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2196: /*ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34334,7 +34350,7 @@ case 2196: /*ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2271: /*ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34349,7 +34365,7 @@ case 2271: /*ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2346: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34379,7 +34395,7 @@ case 2346: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2421: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34420,7 +34436,7 @@ case 2421: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_CV_TMP: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -34462,12 +34478,12 @@ case 2421: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2071: /*ZEND_FETCH_OBJ_R_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_CV_TMP; + return zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2146: /*ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34515,7 +34531,7 @@ case 2146: /*ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2221: /*ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -34546,7 +34562,7 @@ case 2221: /*ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2296: /*ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -34587,7 +34603,7 @@ case 2296: /*ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2371: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -34620,11 +34636,11 @@ case 2371: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_CV_TMP; + return zend_fetch_property_address_read_helper_SPEC_CV_TMP(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2446: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -34666,7 +34682,7 @@ case 2446: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3421: /*ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34696,7 +34712,7 @@ case 3421: /*ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3696: /*ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -34777,7 +34793,7 @@ case 3696: /*ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 971: /*ZEND_ASSIGN_SPEC_CV_TMP_HANDLER*/ ZEND_ASSIGN_SPEC_CV_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34830,7 +34846,7 @@ case 971: /*ZEND_ASSIGN_SPEC_CV_TMP_HANDLER*/ ZEND_ASSIGN_SPEC_CV_TMP_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 2821: /*ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -34903,7 +34919,7 @@ case 2821: /*ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1221: /*ZEND_CASE_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -34921,7 +34937,7 @@ case 1221: /*ZEND_CASE_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1821: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -34965,18 +34981,18 @@ case 1821: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CV_TMP; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CV_TMP: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -35007,7 +35023,7 @@ case 1821: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT ZEND_VM_NEXT_OPCODE(); } -case 1796: /*ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -35016,12 +35032,12 @@ case 1796: /*ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1896: /*ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35059,7 +35075,7 @@ case 1896: /*ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER*/ if (IS_TMP_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -35075,7 +35091,7 @@ case 1896: /*ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_CV_TMP: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_TMP_VAR == IS_CV || IS_TMP_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -35120,7 +35136,7 @@ case 1896: /*ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1921: /*ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35160,7 +35176,7 @@ case 1921: /*ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35184,12 +35200,12 @@ case 1921: /*ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_CV_TMP; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_CV_TMP: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -35199,7 +35215,7 @@ case 1921: /*ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_TMP); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -35302,17 +35318,17 @@ case 1921: /*ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2896: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3721: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4021: /*ZEND_YIELD_SPEC_CV_TMP_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -35466,7 +35482,7 @@ case 4021: /*ZEND_YIELD_SPEC_CV_TMP_HANDLER*/ ZEND_VM_RETURN(); } -case 47: /*ZEND_ADD_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35481,7 +35497,7 @@ case 47: /*ZEND_ADD_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 72: /*ZEND_SUB_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35496,7 +35512,7 @@ case 72: /*ZEND_SUB_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 97: /*ZEND_MUL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35511,7 +35527,7 @@ case 97: /*ZEND_MUL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 122: /*ZEND_DIV_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35526,7 +35542,7 @@ case 122: /*ZEND_DIV_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 147: /*ZEND_MOD_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35541,7 +35557,7 @@ case 147: /*ZEND_MOD_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 172: /*ZEND_SL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35556,7 +35572,7 @@ case 172: /*ZEND_SL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 197: /*ZEND_SR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35571,7 +35587,7 @@ case 197: /*ZEND_SR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 222: /*ZEND_CONCAT_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35586,7 +35602,7 @@ case 222: /*ZEND_CONCAT_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 397: /*ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35601,7 +35617,7 @@ case 397: /*ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 422: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35618,7 +35634,7 @@ case 422: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 447: /*ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35634,7 +35650,7 @@ case 447: /*ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 472: /*ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35650,7 +35666,7 @@ case 472: /*ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 497: /*ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35666,7 +35682,7 @@ case 497: /*ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 522: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35682,7 +35698,7 @@ case 522: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 247: /*ZEND_BW_OR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35697,7 +35713,7 @@ case 247: /*ZEND_BW_OR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 272: /*ZEND_BW_AND_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35712,7 +35728,7 @@ case 272: /*ZEND_BW_AND_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 297: /*ZEND_BW_XOR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35727,7 +35743,7 @@ case 297: /*ZEND_BW_XOR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -35742,7 +35758,7 @@ case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data1; @@ -35853,7 +35869,7 @@ case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_VAR(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2, free_op_data2, free_op_data1; @@ -35863,7 +35879,7 @@ case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_VAR; + return zend_binary_assign_op_obj_helper_SPEC_CV_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -35874,7 +35890,7 @@ case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_VAR; + return zend_binary_assign_op_obj_helper_SPEC_CV_VAR(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_var(opline->op2.var, execute_data, &free_op2 TSRMLS_CC); @@ -35943,62 +35959,62 @@ case 372: /*ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 597: /*ZEND_ASSIGN_ADD_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 622: /*ZEND_ASSIGN_SUB_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 647: /*ZEND_ASSIGN_MUL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 672: /*ZEND_ASSIGN_DIV_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 697: /*ZEND_ASSIGN_MOD_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 722: /*ZEND_ASSIGN_SL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 747: /*ZEND_ASSIGN_SR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 772: /*ZEND_ASSIGN_CONCAT_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 797: /*ZEND_ASSIGN_BW_OR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 822: /*ZEND_ASSIGN_BW_AND_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 847: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_VAR; + return zend_binary_assign_op_helper_SPEC_CV_VAR(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36092,17 +36108,17 @@ case 847: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3322: /*ZEND_PRE_INC_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_VAR; + return zend_pre_incdec_property_helper_SPEC_CV_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3347: /*ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_VAR; + return zend_pre_incdec_property_helper_SPEC_CV_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_VAR(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36194,17 +36210,17 @@ case 3347: /*ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3372: /*ZEND_POST_INC_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_VAR; + return zend_post_incdec_property_helper_SPEC_CV_VAR(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3397: /*ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_VAR; + return zend_post_incdec_property_helper_SPEC_CV_VAR(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_var_address_helper_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_VAR(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -36336,39 +36352,39 @@ case 3397: /*ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2022: /*ZEND_FETCH_R_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_VAR; + return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2097: /*ZEND_FETCH_W_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CV_VAR; + return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2172: /*ZEND_FETCH_RW_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CV_VAR; + return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2322: /*ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_VAR; + return zend_fetch_var_address_helper_SPEC_CV_VAR(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2397: /*ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CV_VAR; + return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2247: /*ZEND_FETCH_IS_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CV_VAR; + return zend_fetch_var_address_helper_SPEC_CV_VAR(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2047: /*ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36398,7 +36414,7 @@ case 2047: /*ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2122: /*ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36431,7 +36447,7 @@ case 2122: /*ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2197: /*ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36453,7 +36469,7 @@ case 2197: /*ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2272: /*ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36468,7 +36484,7 @@ case 2272: /*ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2347: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36498,7 +36514,7 @@ case 2347: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2422: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36539,7 +36555,7 @@ case 2422: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -36581,12 +36597,12 @@ case 2422: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2072: /*ZEND_FETCH_OBJ_R_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_CV_VAR; + return zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2147: /*ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36634,7 +36650,7 @@ case 2147: /*ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2222: /*ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2; @@ -36665,7 +36681,7 @@ case 2222: /*ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2297: /*ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -36706,7 +36722,7 @@ case 2297: /*ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2372: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -36739,11 +36755,11 @@ case 2372: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_CV_VAR; + return zend_fetch_property_address_read_helper_SPEC_CV_VAR(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2447: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_op2, free_res; @@ -36785,7 +36801,7 @@ case 2447: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3422: /*ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36815,7 +36831,7 @@ case 3422: /*ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3697: /*ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -36896,7 +36912,7 @@ case 3697: /*ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 972: /*ZEND_ASSIGN_SPEC_CV_VAR_HANDLER*/ ZEND_ASSIGN_SPEC_CV_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36950,7 +36966,7 @@ case 972: /*ZEND_ASSIGN_SPEC_CV_VAR_HANDLER*/ ZEND_ASSIGN_SPEC_CV_VAR_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 997: /*ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -36973,7 +36989,7 @@ case 997: /*ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER*/ if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; HANDLE_EXCEPTION(); } - goto ZEND_ASSIGN_SPEC_CV_VAR_LABEL; + return ZEND_ASSIGN_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else if (IS_VAR == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -37003,7 +37019,7 @@ case 997: /*ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2822: /*ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -37076,7 +37092,7 @@ case 2822: /*ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1222: /*ZEND_CASE_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -37094,7 +37110,7 @@ case 1222: /*ZEND_CASE_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1822: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -37138,18 +37154,18 @@ case 1822: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CV_VAR; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CV_VAR: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -37180,7 +37196,7 @@ case 1822: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT ZEND_VM_NEXT_OPCODE(); } -case 1797: /*ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -37189,12 +37205,12 @@ case 1797: /*ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1872: /*ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -37270,7 +37286,7 @@ case 1872: /*ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1897: /*ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -37308,7 +37324,7 @@ case 1897: /*ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER*/ if (IS_VAR == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -37324,7 +37340,7 @@ case 1897: /*ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_CV_VAR: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_VAR == IS_CV || IS_VAR == IS_VAR) { zval_ptr_dtor(&offset); @@ -37369,7 +37385,7 @@ case 1897: /*ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1922: /*ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -37409,7 +37425,7 @@ case 1922: /*ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2872: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -37494,7 +37510,7 @@ case 2872: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -37518,12 +37534,12 @@ case 2872: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_CV_VAR; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_CV_VAR: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -37533,7 +37549,7 @@ case 2872: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_VAR); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -37636,17 +37652,17 @@ case 2872: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2897: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3722: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -37801,7 +37817,7 @@ case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ ZEND_VM_RETURN(); } -zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data1; @@ -37912,7 +37928,7 @@ case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_CV_UNUSED: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -37922,7 +37938,7 @@ case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -37933,7 +37949,7 @@ case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_obj_helper_SPEC_CV_UNUSED(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = NULL; @@ -38001,62 +38017,62 @@ case 4022: /*ZEND_YIELD_SPEC_CV_VAR_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 598: /*ZEND_ASSIGN_ADD_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 623: /*ZEND_ASSIGN_SUB_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 648: /*ZEND_ASSIGN_MUL_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 673: /*ZEND_ASSIGN_DIV_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 698: /*ZEND_ASSIGN_MOD_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 723: /*ZEND_ASSIGN_SL_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 748: /*ZEND_ASSIGN_SR_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 773: /*ZEND_ASSIGN_CONCAT_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 798: /*ZEND_ASSIGN_BW_OR_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 823: /*ZEND_ASSIGN_BW_AND_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 848: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_UNUSED; + return zend_binary_assign_op_helper_SPEC_CV_UNUSED(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_fetch_var_address_helper_SPEC_CV_UNUSED: +static int ZEND_FASTCALL zend_fetch_var_address_helper_SPEC_CV_UNUSED(int type, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -38188,39 +38204,39 @@ case 848: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2023: /*ZEND_FETCH_R_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_R_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2098: /*ZEND_FETCH_W_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_W_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_W; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_W, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2173: /*ZEND_FETCH_RW_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_RW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_RW; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_RW, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2323: /*ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE - type = ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(ARG_SHOULD_BE_SENT_BY_REF(EX(call)->fbc, (opline->extended_value & ZEND_FETCH_ARG_MASK))?BP_VAR_W:BP_VAR_R, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2398: /*ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_UNSET; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_UNSET, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2248: /*ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - type = BP_VAR_IS; goto zend_fetch_var_address_helper_SPEC_CV_UNUSED; + return zend_fetch_var_address_helper_SPEC_CV_UNUSED(BP_VAR_IS, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2123: /*ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -38253,7 +38269,7 @@ case 2123: /*ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2198: /*ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -38275,7 +38291,7 @@ case 2198: /*ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2348: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -38305,7 +38321,7 @@ case 2348: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3698: /*ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38385,7 +38401,7 @@ case 3698: /*ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1823: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38429,18 +38445,18 @@ case 1823: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEM switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CV_UNUSED; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CV_UNUSED: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_UNUSED == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_UNUSED); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -38471,7 +38487,7 @@ case 1823: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER*/ ZEND_ADD_ARRAY_ELEM ZEND_VM_NEXT_OPCODE(); } -case 1798: /*ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38480,12 +38496,12 @@ case 1798: /*ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1873: /*ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval tmp, *varname; @@ -38561,7 +38577,7 @@ case 1873: /*ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2873: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval **value; @@ -38646,7 +38662,7 @@ case 2873: /*ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 4023: /*ZEND_YIELD_SPEC_CV_UNUSED_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38800,7 +38816,7 @@ case 4023: /*ZEND_YIELD_SPEC_CV_UNUSED_HANDLER*/ ZEND_VM_RETURN(); } -case 49: /*ZEND_ADD_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38815,7 +38831,7 @@ case 49: /*ZEND_ADD_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 74: /*ZEND_SUB_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38830,7 +38846,7 @@ case 74: /*ZEND_SUB_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 99: /*ZEND_MUL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38845,7 +38861,7 @@ case 99: /*ZEND_MUL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 124: /*ZEND_DIV_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38860,7 +38876,7 @@ case 124: /*ZEND_DIV_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 149: /*ZEND_MOD_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38875,7 +38891,7 @@ case 149: /*ZEND_MOD_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 174: /*ZEND_SL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38890,7 +38906,7 @@ case 174: /*ZEND_SL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 199: /*ZEND_SR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_SR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38905,7 +38921,7 @@ case 199: /*ZEND_SR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 224: /*ZEND_CONCAT_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38920,7 +38936,7 @@ case 224: /*ZEND_CONCAT_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 399: /*ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38935,7 +38951,7 @@ case 399: /*ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 424: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38952,7 +38968,7 @@ case 424: /*ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 449: /*ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38968,7 +38984,7 @@ case 449: /*ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 474: /*ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -38984,7 +39000,7 @@ case 474: /*ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 499: /*ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39000,7 +39016,7 @@ case 499: /*ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 524: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39016,7 +39032,7 @@ case 524: /*ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 249: /*ZEND_BW_OR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_OR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39031,7 +39047,7 @@ case 249: /*ZEND_BW_OR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 274: /*ZEND_BW_AND_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_AND_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39046,7 +39062,7 @@ case 274: /*ZEND_BW_AND_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 299: /*ZEND_BW_XOR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BW_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39061,7 +39077,7 @@ case 299: /*ZEND_BW_XOR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39076,7 +39092,7 @@ case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_obj_helper_SPEC_CV_CV: +static int ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data1; @@ -39187,7 +39203,7 @@ case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_binary_assign_op_helper_SPEC_CV_CV: +static int ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2 TSRMLS_DC), ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op_data2, free_op_data1; @@ -39197,7 +39213,7 @@ case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ SAVE_OPLINE(); switch (opline->extended_value) { case ZEND_ASSIGN_OBJ: - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CV; + return zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); break; case ZEND_ASSIGN_DIM: { zval **container = _get_zval_ptr_ptr_cv_BP_VAR_RW(execute_data, opline->op1.var TSRMLS_CC); @@ -39208,7 +39224,7 @@ case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ if (IS_CV == IS_VAR && !0) { Z_ADDREF_PP(container); /* undo the effect of get_obj_zval_ptr_ptr() */ } - binary_op = binary_op; goto zend_binary_assign_op_obj_helper_SPEC_CV_CV; + return zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else { zval *dim = _get_zval_ptr_cv_BP_VAR_R(execute_data, opline->op2.var TSRMLS_CC); @@ -39276,62 +39292,62 @@ case 374: /*ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 599: /*ZEND_ASSIGN_ADD_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_ADD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = add_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(add_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 624: /*ZEND_ASSIGN_SUB_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SUB_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = sub_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(sub_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 649: /*ZEND_ASSIGN_MUL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MUL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mul_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(mul_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 674: /*ZEND_ASSIGN_DIV_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIV_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = div_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(div_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 699: /*ZEND_ASSIGN_MOD_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_MOD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = mod_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(mod_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 724: /*ZEND_ASSIGN_SL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_left_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(shift_left_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 749: /*ZEND_ASSIGN_SR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_SR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = shift_right_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(shift_right_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 774: /*ZEND_ASSIGN_CONCAT_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_CONCAT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = concat_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(concat_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 799: /*ZEND_ASSIGN_BW_OR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_OR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_or_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(bitwise_or_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 824: /*ZEND_ASSIGN_BW_AND_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_AND_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_and_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(bitwise_and_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 849: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - binary_op = bitwise_xor_function; goto zend_binary_assign_op_helper_SPEC_CV_CV; + return zend_binary_assign_op_helper_SPEC_CV_CV(bitwise_xor_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_pre_incdec_property_helper_SPEC_CV_CV: +static int ZEND_FASTCALL zend_pre_incdec_property_helper_SPEC_CV_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39425,17 +39441,17 @@ case 849: /*ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3324: /*ZEND_PRE_INC_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_INC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_pre_incdec_property_helper_SPEC_CV_CV; + return zend_pre_incdec_property_helper_SPEC_CV_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3349: /*ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_pre_incdec_property_helper_SPEC_CV_CV; + return zend_pre_incdec_property_helper_SPEC_CV_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -zend_post_incdec_property_helper_SPEC_CV_CV: +static int ZEND_FASTCALL zend_post_incdec_property_helper_SPEC_CV_CV(incdec_t incdec_op, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39527,17 +39543,17 @@ case 3349: /*ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3374: /*ZEND_POST_INC_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_INC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = increment_function; goto zend_post_incdec_property_helper_SPEC_CV_CV; + return zend_post_incdec_property_helper_SPEC_CV_CV(increment_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3399: /*ZEND_POST_DEC_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_POST_DEC_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - incdec_op = decrement_function; goto zend_post_incdec_property_helper_SPEC_CV_CV; + return zend_post_incdec_property_helper_SPEC_CV_CV(decrement_function, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2049: /*ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39567,7 +39583,7 @@ case 2049: /*ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2124: /*ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -39600,7 +39616,7 @@ case 2124: /*ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2199: /*ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -39622,7 +39638,7 @@ case 2199: /*ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2274: /*ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39637,7 +39653,7 @@ case 2274: /*ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2349: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -39667,7 +39683,7 @@ case 2349: /*ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2424: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -39708,7 +39724,7 @@ case 2424: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER*/ } } -zend_fetch_property_address_read_helper_SPEC_CV_CV: +static int ZEND_FASTCALL zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39750,12 +39766,12 @@ case 2424: /*ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2074: /*ZEND_FETCH_OBJ_R_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_R_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - goto zend_fetch_property_address_read_helper_SPEC_CV_CV; + return zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 2149: /*ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -39803,7 +39819,7 @@ case 2149: /*ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2224: /*ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1; @@ -39834,7 +39850,7 @@ case 2224: /*ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2299: /*ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39875,7 +39891,7 @@ case 2299: /*ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2374: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39908,11 +39924,11 @@ case 2374: /*ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER*/ CHECK_EXCEPTION(); ZEND_VM_NEXT_OPCODE(); } else { - goto zend_fetch_property_address_read_helper_SPEC_CV_CV; + return zend_fetch_property_address_read_helper_SPEC_CV_CV(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } } -case 2449: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op1, free_res; @@ -39954,7 +39970,7 @@ case 2449: /*ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3424: /*ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -39984,7 +40000,7 @@ case 3424: /*ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 3699: /*ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40064,7 +40080,7 @@ case 3699: /*ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 974: /*ZEND_ASSIGN_SPEC_CV_CV_HANDLER*/ ZEND_ASSIGN_SPEC_CV_CV_LABEL: +static int ZEND_FASTCALL ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40117,7 +40133,7 @@ case 974: /*ZEND_ASSIGN_SPEC_CV_CV_HANDLER*/ ZEND_ASSIGN_SPEC_CV_CV_LABEL: ZEND_VM_NEXT_OPCODE(); } -case 999: /*ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zend_free_op free_op2; @@ -40140,7 +40156,7 @@ case 999: /*ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER*/ HANDLE_EXCEPTION(); } - goto ZEND_ASSIGN_SPEC_CV_CV_LABEL; + return ZEND_ASSIGN_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } else if (IS_CV == IS_VAR && opline->extended_value == ZEND_RETURNS_NEW) { PZVAL_LOCK(*value_ptr_ptr); } @@ -40169,7 +40185,7 @@ case 999: /*ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2824: /*ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE zval *function_name; @@ -40241,7 +40257,7 @@ case 2824: /*ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1224: /*ZEND_CASE_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_CASE_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40258,7 +40274,7 @@ case 1224: /*ZEND_CASE_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1824: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_LABEL: +static int ZEND_FASTCALL ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40302,18 +40318,18 @@ case 1824: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_SPEC_CV_CV; + goto num_index; case IS_LONG: case IS_BOOL: hval = Z_LVAL_P(offset); -num_index_SPEC_CV_CV: +num_index: zend_hash_index_update(Z_ARRVAL(EX_T(opline->result.var).tmp_var), hval, &expr_ptr, sizeof(zval *), NULL); break; case IS_STRING: if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_SPEC_CV_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -40344,7 +40360,7 @@ case 1824: /*ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER*/ ZEND_ADD_ARRAY_ELEMENT_ ZEND_VM_NEXT_OPCODE(); } -case 1799: /*ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40353,12 +40369,12 @@ case 1799: /*ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); #if 0 || IS_CV != IS_UNUSED } else { - goto ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_LABEL; + return ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); #endif } } -case 1899: /*ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40396,7 +40412,7 @@ case 1899: /*ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER*/ if (IS_CV == IS_CONST) { hval = Z_HASH_P(offset); } else { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim_SPEC_CV_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_dim); if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); } else { @@ -40412,7 +40428,7 @@ case 1899: /*ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER*/ zval_ptr_dtor(&offset); } break; -num_index_dim_SPEC_CV_CV: +num_index_dim: zend_hash_index_del(ht, hval); if (IS_CV == IS_CV || IS_CV == IS_VAR) { zval_ptr_dtor(&offset); @@ -40457,7 +40473,7 @@ case 1899: /*ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 1924: /*ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40497,7 +40513,7 @@ case 1924: /*ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV: +static int ZEND_FASTCALL zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int prop_dim, ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40521,12 +40537,12 @@ case 1924: /*ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER*/ switch (Z_TYPE_P(offset)) { case IS_DOUBLE: hval = zend_dval_to_lval(Z_DVAL_P(offset)); - goto num_index_prop_SPEC_CV_CV; + goto num_index_prop; case IS_RESOURCE: case IS_BOOL: case IS_LONG: hval = Z_LVAL_P(offset); -num_index_prop_SPEC_CV_CV: +num_index_prop: if (zend_hash_index_find(ht, hval, (void **) &value) == SUCCESS) { isset = 1; } @@ -40536,7 +40552,7 @@ case 1924: /*ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER*/ hval = Z_HASH_P(offset); } else { if (!prop_dim) { - ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop_SPEC_CV_CV); + ZEND_HANDLE_NUMERIC_EX(Z_STRVAL_P(offset), Z_STRLEN_P(offset)+1, hval, goto num_index_prop); } if (IS_INTERNED(Z_STRVAL_P(offset))) { hval = INTERNED_HASH(Z_STRVAL_P(offset)); @@ -40639,17 +40655,17 @@ case 1924: /*ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER*/ ZEND_VM_NEXT_OPCODE(); } -case 2899: /*ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 0; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(0, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 3724: /*ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { - prop_dim = 1; goto zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV; + return zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(1, ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } -case 4024: /*ZEND_YIELD_SPEC_CV_CV_HANDLER*/ +static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { USE_OPLINE @@ -40803,4128 +40819,4117 @@ case 4024: /*ZEND_YIELD_SPEC_CV_CV_HANDLER*/ ZEND_VM_RETURN(); } -default: +static int ZEND_FASTCALL ZEND_NULL_HANDLER(ZEND_OPCODE_HANDLER_ARGS) +{ zend_error_noreturn(E_ERROR, "Invalid opcode %d/%d/%d.", OPLINE->opcode, OPLINE->op1_type, OPLINE->op2_type); ZEND_VM_NEXT_OPCODE(); /* Never reached */ - } - - } - zend_error_noreturn(E_ERROR, "Arrived at end of main loop which shouldn't happen"); -} - -ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) -{ - if (EG(exception)) { - return; - } - zend_execute_ex(i_create_execute_data_from_op_array(op_array, 0 TSRMLS_CC) TSRMLS_CC); } void zend_init_opcodes_handlers(void) { static const opcode_handler_t labels[] = { - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)0, - (opcode_handler_t)25, - (opcode_handler_t)26, - (opcode_handler_t)27, - (opcode_handler_t)-1, - (opcode_handler_t)29, - (opcode_handler_t)30, - (opcode_handler_t)31, - (opcode_handler_t)32, - (opcode_handler_t)-1, - (opcode_handler_t)34, - (opcode_handler_t)35, - (opcode_handler_t)36, - (opcode_handler_t)37, - (opcode_handler_t)-1, - (opcode_handler_t)39, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)45, - (opcode_handler_t)46, - (opcode_handler_t)47, - (opcode_handler_t)-1, - (opcode_handler_t)49, - (opcode_handler_t)50, - (opcode_handler_t)51, - (opcode_handler_t)52, - (opcode_handler_t)-1, - (opcode_handler_t)54, - (opcode_handler_t)55, - (opcode_handler_t)56, - (opcode_handler_t)57, - (opcode_handler_t)-1, - (opcode_handler_t)59, - (opcode_handler_t)60, - (opcode_handler_t)61, - (opcode_handler_t)62, - (opcode_handler_t)-1, - (opcode_handler_t)64, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)70, - (opcode_handler_t)71, - (opcode_handler_t)72, - (opcode_handler_t)-1, - (opcode_handler_t)74, - (opcode_handler_t)75, - (opcode_handler_t)76, - (opcode_handler_t)77, - (opcode_handler_t)-1, - (opcode_handler_t)79, - (opcode_handler_t)80, - (opcode_handler_t)81, - (opcode_handler_t)82, - (opcode_handler_t)-1, - (opcode_handler_t)84, - (opcode_handler_t)85, - (opcode_handler_t)86, - (opcode_handler_t)87, - (opcode_handler_t)-1, - (opcode_handler_t)89, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)95, - (opcode_handler_t)96, - (opcode_handler_t)97, - (opcode_handler_t)-1, - (opcode_handler_t)99, - (opcode_handler_t)100, - (opcode_handler_t)101, - (opcode_handler_t)102, - (opcode_handler_t)-1, - (opcode_handler_t)104, - (opcode_handler_t)105, - (opcode_handler_t)106, - (opcode_handler_t)107, - (opcode_handler_t)-1, - (opcode_handler_t)109, - (opcode_handler_t)110, - (opcode_handler_t)111, - (opcode_handler_t)112, - (opcode_handler_t)-1, - (opcode_handler_t)114, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)120, - (opcode_handler_t)121, - (opcode_handler_t)122, - (opcode_handler_t)-1, - (opcode_handler_t)124, - (opcode_handler_t)125, - (opcode_handler_t)126, - (opcode_handler_t)127, - (opcode_handler_t)-1, - (opcode_handler_t)129, - (opcode_handler_t)130, - (opcode_handler_t)131, - (opcode_handler_t)132, - (opcode_handler_t)-1, - (opcode_handler_t)134, - (opcode_handler_t)135, - (opcode_handler_t)136, - (opcode_handler_t)137, - (opcode_handler_t)-1, - (opcode_handler_t)139, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)145, - (opcode_handler_t)146, - (opcode_handler_t)147, - (opcode_handler_t)-1, - (opcode_handler_t)149, - (opcode_handler_t)150, - (opcode_handler_t)151, - (opcode_handler_t)152, - (opcode_handler_t)-1, - (opcode_handler_t)154, - (opcode_handler_t)155, - (opcode_handler_t)156, - (opcode_handler_t)157, - (opcode_handler_t)-1, - (opcode_handler_t)159, - (opcode_handler_t)160, - (opcode_handler_t)161, - (opcode_handler_t)162, - (opcode_handler_t)-1, - (opcode_handler_t)164, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)170, - (opcode_handler_t)171, - (opcode_handler_t)172, - (opcode_handler_t)-1, - (opcode_handler_t)174, - (opcode_handler_t)175, - (opcode_handler_t)176, - (opcode_handler_t)177, - (opcode_handler_t)-1, - (opcode_handler_t)179, - (opcode_handler_t)180, - (opcode_handler_t)181, - (opcode_handler_t)182, - (opcode_handler_t)-1, - (opcode_handler_t)184, - (opcode_handler_t)185, - (opcode_handler_t)186, - (opcode_handler_t)187, - (opcode_handler_t)-1, - (opcode_handler_t)189, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)195, - (opcode_handler_t)196, - (opcode_handler_t)197, - (opcode_handler_t)-1, - (opcode_handler_t)199, - (opcode_handler_t)200, - (opcode_handler_t)201, - (opcode_handler_t)202, - (opcode_handler_t)-1, - (opcode_handler_t)204, - (opcode_handler_t)205, - (opcode_handler_t)206, - (opcode_handler_t)207, - (opcode_handler_t)-1, - (opcode_handler_t)209, - (opcode_handler_t)210, - (opcode_handler_t)211, - (opcode_handler_t)212, - (opcode_handler_t)-1, - (opcode_handler_t)214, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)220, - (opcode_handler_t)221, - (opcode_handler_t)222, - (opcode_handler_t)-1, - (opcode_handler_t)224, - (opcode_handler_t)225, - (opcode_handler_t)226, - (opcode_handler_t)227, - (opcode_handler_t)-1, - (opcode_handler_t)229, - (opcode_handler_t)230, - (opcode_handler_t)231, - (opcode_handler_t)232, - (opcode_handler_t)-1, - (opcode_handler_t)234, - (opcode_handler_t)235, - (opcode_handler_t)236, - (opcode_handler_t)237, - (opcode_handler_t)-1, - (opcode_handler_t)239, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)245, - (opcode_handler_t)246, - (opcode_handler_t)247, - (opcode_handler_t)-1, - (opcode_handler_t)249, - (opcode_handler_t)250, - (opcode_handler_t)251, - (opcode_handler_t)252, - (opcode_handler_t)-1, - (opcode_handler_t)254, - (opcode_handler_t)255, - (opcode_handler_t)256, - (opcode_handler_t)257, - (opcode_handler_t)-1, - (opcode_handler_t)259, - (opcode_handler_t)260, - (opcode_handler_t)261, - (opcode_handler_t)262, - (opcode_handler_t)-1, - (opcode_handler_t)264, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)270, - (opcode_handler_t)271, - (opcode_handler_t)272, - (opcode_handler_t)-1, - (opcode_handler_t)274, - (opcode_handler_t)275, - (opcode_handler_t)276, - (opcode_handler_t)277, - (opcode_handler_t)-1, - (opcode_handler_t)279, - (opcode_handler_t)280, - (opcode_handler_t)281, - (opcode_handler_t)282, - (opcode_handler_t)-1, - (opcode_handler_t)284, - (opcode_handler_t)285, - (opcode_handler_t)286, - (opcode_handler_t)287, - (opcode_handler_t)-1, - (opcode_handler_t)289, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)295, - (opcode_handler_t)296, - (opcode_handler_t)297, - (opcode_handler_t)-1, - (opcode_handler_t)299, - (opcode_handler_t)300, - (opcode_handler_t)300, - (opcode_handler_t)300, - (opcode_handler_t)300, - (opcode_handler_t)300, - (opcode_handler_t)305, - (opcode_handler_t)305, - (opcode_handler_t)305, - (opcode_handler_t)305, - (opcode_handler_t)305, - (opcode_handler_t)310, - (opcode_handler_t)310, - (opcode_handler_t)310, - (opcode_handler_t)310, - (opcode_handler_t)310, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)320, - (opcode_handler_t)320, - (opcode_handler_t)320, - (opcode_handler_t)320, - (opcode_handler_t)320, - (opcode_handler_t)325, - (opcode_handler_t)325, - (opcode_handler_t)325, - (opcode_handler_t)325, - (opcode_handler_t)325, - (opcode_handler_t)330, - (opcode_handler_t)330, - (opcode_handler_t)330, - (opcode_handler_t)330, - (opcode_handler_t)330, - (opcode_handler_t)335, - (opcode_handler_t)335, - (opcode_handler_t)335, - (opcode_handler_t)335, - (opcode_handler_t)335, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)345, - (opcode_handler_t)345, - (opcode_handler_t)345, - (opcode_handler_t)345, - (opcode_handler_t)345, - (opcode_handler_t)350, - (opcode_handler_t)351, - (opcode_handler_t)352, - (opcode_handler_t)-1, - (opcode_handler_t)354, - (opcode_handler_t)355, - (opcode_handler_t)356, - (opcode_handler_t)357, - (opcode_handler_t)-1, - (opcode_handler_t)359, - (opcode_handler_t)360, - (opcode_handler_t)361, - (opcode_handler_t)362, - (opcode_handler_t)-1, - (opcode_handler_t)364, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)370, - (opcode_handler_t)371, - (opcode_handler_t)372, - (opcode_handler_t)-1, - (opcode_handler_t)374, - (opcode_handler_t)375, - (opcode_handler_t)376, - (opcode_handler_t)377, - (opcode_handler_t)-1, - (opcode_handler_t)379, - (opcode_handler_t)380, - (opcode_handler_t)381, - (opcode_handler_t)382, - (opcode_handler_t)-1, - (opcode_handler_t)384, - (opcode_handler_t)385, - (opcode_handler_t)386, - (opcode_handler_t)387, - (opcode_handler_t)-1, - (opcode_handler_t)389, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)395, - (opcode_handler_t)396, - (opcode_handler_t)397, - (opcode_handler_t)-1, - (opcode_handler_t)399, - (opcode_handler_t)400, - (opcode_handler_t)401, - (opcode_handler_t)402, - (opcode_handler_t)-1, - (opcode_handler_t)404, - (opcode_handler_t)405, - (opcode_handler_t)406, - (opcode_handler_t)407, - (opcode_handler_t)-1, - (opcode_handler_t)409, - (opcode_handler_t)410, - (opcode_handler_t)411, - (opcode_handler_t)412, - (opcode_handler_t)-1, - (opcode_handler_t)414, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)420, - (opcode_handler_t)421, - (opcode_handler_t)422, - (opcode_handler_t)-1, - (opcode_handler_t)424, - (opcode_handler_t)425, - (opcode_handler_t)426, - (opcode_handler_t)427, - (opcode_handler_t)-1, - (opcode_handler_t)429, - (opcode_handler_t)430, - (opcode_handler_t)431, - (opcode_handler_t)432, - (opcode_handler_t)-1, - (opcode_handler_t)434, - (opcode_handler_t)435, - (opcode_handler_t)436, - (opcode_handler_t)437, - (opcode_handler_t)-1, - (opcode_handler_t)439, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)445, - (opcode_handler_t)446, - (opcode_handler_t)447, - (opcode_handler_t)-1, - (opcode_handler_t)449, - (opcode_handler_t)450, - (opcode_handler_t)451, - (opcode_handler_t)452, - (opcode_handler_t)-1, - (opcode_handler_t)454, - (opcode_handler_t)455, - (opcode_handler_t)456, - (opcode_handler_t)457, - (opcode_handler_t)-1, - (opcode_handler_t)459, - (opcode_handler_t)460, - (opcode_handler_t)461, - (opcode_handler_t)462, - (opcode_handler_t)-1, - (opcode_handler_t)464, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)470, - (opcode_handler_t)471, - (opcode_handler_t)472, - (opcode_handler_t)-1, - (opcode_handler_t)474, - (opcode_handler_t)475, - (opcode_handler_t)476, - (opcode_handler_t)477, - (opcode_handler_t)-1, - (opcode_handler_t)479, - (opcode_handler_t)480, - (opcode_handler_t)481, - (opcode_handler_t)482, - (opcode_handler_t)-1, - (opcode_handler_t)484, - (opcode_handler_t)485, - (opcode_handler_t)486, - (opcode_handler_t)487, - (opcode_handler_t)-1, - (opcode_handler_t)489, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)495, - (opcode_handler_t)496, - (opcode_handler_t)497, - (opcode_handler_t)-1, - (opcode_handler_t)499, - (opcode_handler_t)500, - (opcode_handler_t)501, - (opcode_handler_t)502, - (opcode_handler_t)-1, - (opcode_handler_t)504, - (opcode_handler_t)505, - (opcode_handler_t)506, - (opcode_handler_t)507, - (opcode_handler_t)-1, - (opcode_handler_t)509, - (opcode_handler_t)510, - (opcode_handler_t)511, - (opcode_handler_t)512, - (opcode_handler_t)-1, - (opcode_handler_t)514, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)520, - (opcode_handler_t)521, - (opcode_handler_t)522, - (opcode_handler_t)-1, - (opcode_handler_t)524, - (opcode_handler_t)525, - (opcode_handler_t)525, - (opcode_handler_t)525, - (opcode_handler_t)525, - (opcode_handler_t)525, - (opcode_handler_t)530, - (opcode_handler_t)530, - (opcode_handler_t)530, - (opcode_handler_t)530, - (opcode_handler_t)530, - (opcode_handler_t)535, - (opcode_handler_t)535, - (opcode_handler_t)535, - (opcode_handler_t)535, - (opcode_handler_t)535, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)545, - (opcode_handler_t)545, - (opcode_handler_t)545, - (opcode_handler_t)545, - (opcode_handler_t)545, - (opcode_handler_t)550, - (opcode_handler_t)550, - (opcode_handler_t)550, - (opcode_handler_t)550, - (opcode_handler_t)550, - (opcode_handler_t)555, - (opcode_handler_t)555, - (opcode_handler_t)555, - (opcode_handler_t)555, - (opcode_handler_t)555, - (opcode_handler_t)560, - (opcode_handler_t)560, - (opcode_handler_t)560, - (opcode_handler_t)560, - (opcode_handler_t)560, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)570, - (opcode_handler_t)570, - (opcode_handler_t)570, - (opcode_handler_t)570, - (opcode_handler_t)570, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)585, - (opcode_handler_t)586, - (opcode_handler_t)587, - (opcode_handler_t)588, - (opcode_handler_t)589, - (opcode_handler_t)590, - (opcode_handler_t)591, - (opcode_handler_t)592, - (opcode_handler_t)593, - (opcode_handler_t)594, - (opcode_handler_t)595, - (opcode_handler_t)596, - (opcode_handler_t)597, - (opcode_handler_t)598, - (opcode_handler_t)599, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)610, - (opcode_handler_t)611, - (opcode_handler_t)612, - (opcode_handler_t)613, - (opcode_handler_t)614, - (opcode_handler_t)615, - (opcode_handler_t)616, - (opcode_handler_t)617, - (opcode_handler_t)618, - (opcode_handler_t)619, - (opcode_handler_t)620, - (opcode_handler_t)621, - (opcode_handler_t)622, - (opcode_handler_t)623, - (opcode_handler_t)624, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)635, - (opcode_handler_t)636, - (opcode_handler_t)637, - (opcode_handler_t)638, - (opcode_handler_t)639, - (opcode_handler_t)640, - (opcode_handler_t)641, - (opcode_handler_t)642, - (opcode_handler_t)643, - (opcode_handler_t)644, - (opcode_handler_t)645, - (opcode_handler_t)646, - (opcode_handler_t)647, - (opcode_handler_t)648, - (opcode_handler_t)649, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)660, - (opcode_handler_t)661, - (opcode_handler_t)662, - (opcode_handler_t)663, - (opcode_handler_t)664, - (opcode_handler_t)665, - (opcode_handler_t)666, - (opcode_handler_t)667, - (opcode_handler_t)668, - (opcode_handler_t)669, - (opcode_handler_t)670, - (opcode_handler_t)671, - (opcode_handler_t)672, - (opcode_handler_t)673, - (opcode_handler_t)674, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)685, - (opcode_handler_t)686, - (opcode_handler_t)687, - (opcode_handler_t)688, - (opcode_handler_t)689, - (opcode_handler_t)690, - (opcode_handler_t)691, - (opcode_handler_t)692, - (opcode_handler_t)693, - (opcode_handler_t)694, - (opcode_handler_t)695, - (opcode_handler_t)696, - (opcode_handler_t)697, - (opcode_handler_t)698, - (opcode_handler_t)699, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)710, - (opcode_handler_t)711, - (opcode_handler_t)712, - (opcode_handler_t)713, - (opcode_handler_t)714, - (opcode_handler_t)715, - (opcode_handler_t)716, - (opcode_handler_t)717, - (opcode_handler_t)718, - (opcode_handler_t)719, - (opcode_handler_t)720, - (opcode_handler_t)721, - (opcode_handler_t)722, - (opcode_handler_t)723, - (opcode_handler_t)724, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)735, - (opcode_handler_t)736, - (opcode_handler_t)737, - (opcode_handler_t)738, - (opcode_handler_t)739, - (opcode_handler_t)740, - (opcode_handler_t)741, - (opcode_handler_t)742, - (opcode_handler_t)743, - (opcode_handler_t)744, - (opcode_handler_t)745, - (opcode_handler_t)746, - (opcode_handler_t)747, - (opcode_handler_t)748, - (opcode_handler_t)749, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)760, - (opcode_handler_t)761, - (opcode_handler_t)762, - (opcode_handler_t)763, - (opcode_handler_t)764, - (opcode_handler_t)765, - (opcode_handler_t)766, - (opcode_handler_t)767, - (opcode_handler_t)768, - (opcode_handler_t)769, - (opcode_handler_t)770, - (opcode_handler_t)771, - (opcode_handler_t)772, - (opcode_handler_t)773, - (opcode_handler_t)774, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)785, - (opcode_handler_t)786, - (opcode_handler_t)787, - (opcode_handler_t)788, - (opcode_handler_t)789, - (opcode_handler_t)790, - (opcode_handler_t)791, - (opcode_handler_t)792, - (opcode_handler_t)793, - (opcode_handler_t)794, - (opcode_handler_t)795, - (opcode_handler_t)796, - (opcode_handler_t)797, - (opcode_handler_t)798, - (opcode_handler_t)799, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)810, - (opcode_handler_t)811, - (opcode_handler_t)812, - (opcode_handler_t)813, - (opcode_handler_t)814, - (opcode_handler_t)815, - (opcode_handler_t)816, - (opcode_handler_t)817, - (opcode_handler_t)818, - (opcode_handler_t)819, - (opcode_handler_t)820, - (opcode_handler_t)821, - (opcode_handler_t)822, - (opcode_handler_t)823, - (opcode_handler_t)824, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)835, - (opcode_handler_t)836, - (opcode_handler_t)837, - (opcode_handler_t)838, - (opcode_handler_t)839, - (opcode_handler_t)840, - (opcode_handler_t)841, - (opcode_handler_t)842, - (opcode_handler_t)843, - (opcode_handler_t)844, - (opcode_handler_t)845, - (opcode_handler_t)846, - (opcode_handler_t)847, - (opcode_handler_t)848, - (opcode_handler_t)849, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)860, - (opcode_handler_t)860, - (opcode_handler_t)860, - (opcode_handler_t)860, - (opcode_handler_t)860, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)870, - (opcode_handler_t)870, - (opcode_handler_t)870, - (opcode_handler_t)870, - (opcode_handler_t)870, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)885, - (opcode_handler_t)885, - (opcode_handler_t)885, - (opcode_handler_t)885, - (opcode_handler_t)885, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)895, - (opcode_handler_t)895, - (opcode_handler_t)895, - (opcode_handler_t)895, - (opcode_handler_t)895, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)910, - (opcode_handler_t)910, - (opcode_handler_t)910, - (opcode_handler_t)910, - (opcode_handler_t)910, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)920, - (opcode_handler_t)920, - (opcode_handler_t)920, - (opcode_handler_t)920, - (opcode_handler_t)920, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)935, - (opcode_handler_t)935, - (opcode_handler_t)935, - (opcode_handler_t)935, - (opcode_handler_t)935, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)945, - (opcode_handler_t)945, - (opcode_handler_t)945, - (opcode_handler_t)945, - (opcode_handler_t)945, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)960, - (opcode_handler_t)961, - (opcode_handler_t)962, - (opcode_handler_t)-1, - (opcode_handler_t)964, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)970, - (opcode_handler_t)971, - (opcode_handler_t)972, - (opcode_handler_t)-1, - (opcode_handler_t)974, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)987, - (opcode_handler_t)-1, - (opcode_handler_t)989, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)997, - (opcode_handler_t)-1, - (opcode_handler_t)999, - (opcode_handler_t)1000, - (opcode_handler_t)1000, - (opcode_handler_t)1000, - (opcode_handler_t)1000, - (opcode_handler_t)1000, - (opcode_handler_t)1005, - (opcode_handler_t)1005, - (opcode_handler_t)1005, - (opcode_handler_t)1005, - (opcode_handler_t)1005, - (opcode_handler_t)1010, - (opcode_handler_t)1010, - (opcode_handler_t)1010, - (opcode_handler_t)1010, - (opcode_handler_t)1010, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1020, - (opcode_handler_t)1020, - (opcode_handler_t)1020, - (opcode_handler_t)1020, - (opcode_handler_t)1020, - (opcode_handler_t)1025, - (opcode_handler_t)1025, - (opcode_handler_t)1025, - (opcode_handler_t)1025, - (opcode_handler_t)1025, - (opcode_handler_t)1030, - (opcode_handler_t)1030, - (opcode_handler_t)1030, - (opcode_handler_t)1030, - (opcode_handler_t)1030, - (opcode_handler_t)1035, - (opcode_handler_t)1035, - (opcode_handler_t)1035, - (opcode_handler_t)1035, - (opcode_handler_t)1035, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1045, - (opcode_handler_t)1045, - (opcode_handler_t)1045, - (opcode_handler_t)1045, - (opcode_handler_t)1045, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1050, - (opcode_handler_t)1075, - (opcode_handler_t)1075, - (opcode_handler_t)1075, - (opcode_handler_t)1075, - (opcode_handler_t)1075, - (opcode_handler_t)1080, - (opcode_handler_t)1080, - (opcode_handler_t)1080, - (opcode_handler_t)1080, - (opcode_handler_t)1080, - (opcode_handler_t)1085, - (opcode_handler_t)1085, - (opcode_handler_t)1085, - (opcode_handler_t)1085, - (opcode_handler_t)1085, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1095, - (opcode_handler_t)1095, - (opcode_handler_t)1095, - (opcode_handler_t)1095, - (opcode_handler_t)1095, - (opcode_handler_t)1100, - (opcode_handler_t)1100, - (opcode_handler_t)1100, - (opcode_handler_t)1100, - (opcode_handler_t)1100, - (opcode_handler_t)1105, - (opcode_handler_t)1105, - (opcode_handler_t)1105, - (opcode_handler_t)1105, - (opcode_handler_t)1105, - (opcode_handler_t)1110, - (opcode_handler_t)1110, - (opcode_handler_t)1110, - (opcode_handler_t)1110, - (opcode_handler_t)1110, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1120, - (opcode_handler_t)1120, - (opcode_handler_t)1120, - (opcode_handler_t)1120, - (opcode_handler_t)1120, - (opcode_handler_t)1125, - (opcode_handler_t)1125, - (opcode_handler_t)1125, - (opcode_handler_t)1125, - (opcode_handler_t)1125, - (opcode_handler_t)1130, - (opcode_handler_t)1130, - (opcode_handler_t)1130, - (opcode_handler_t)1130, - (opcode_handler_t)1130, - (opcode_handler_t)1135, - (opcode_handler_t)1135, - (opcode_handler_t)1135, - (opcode_handler_t)1135, - (opcode_handler_t)1135, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1145, - (opcode_handler_t)1145, - (opcode_handler_t)1145, - (opcode_handler_t)1145, - (opcode_handler_t)1145, - (opcode_handler_t)1150, - (opcode_handler_t)1150, - (opcode_handler_t)1150, - (opcode_handler_t)1150, - (opcode_handler_t)1150, - (opcode_handler_t)1155, - (opcode_handler_t)1155, - (opcode_handler_t)1155, - (opcode_handler_t)1155, - (opcode_handler_t)1155, - (opcode_handler_t)1160, - (opcode_handler_t)1160, - (opcode_handler_t)1160, - (opcode_handler_t)1160, - (opcode_handler_t)1160, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1170, - (opcode_handler_t)1170, - (opcode_handler_t)1170, - (opcode_handler_t)1170, - (opcode_handler_t)1170, - (opcode_handler_t)1175, - (opcode_handler_t)1175, - (opcode_handler_t)1175, - (opcode_handler_t)1175, - (opcode_handler_t)1175, - (opcode_handler_t)1180, - (opcode_handler_t)1180, - (opcode_handler_t)1180, - (opcode_handler_t)1180, - (opcode_handler_t)1180, - (opcode_handler_t)1185, - (opcode_handler_t)1185, - (opcode_handler_t)1185, - (opcode_handler_t)1185, - (opcode_handler_t)1185, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1195, - (opcode_handler_t)1195, - (opcode_handler_t)1195, - (opcode_handler_t)1195, - (opcode_handler_t)1195, - (opcode_handler_t)1200, - (opcode_handler_t)1201, - (opcode_handler_t)1202, - (opcode_handler_t)-1, - (opcode_handler_t)1204, - (opcode_handler_t)1205, - (opcode_handler_t)1206, - (opcode_handler_t)1207, - (opcode_handler_t)-1, - (opcode_handler_t)1209, - (opcode_handler_t)1210, - (opcode_handler_t)1211, - (opcode_handler_t)1212, - (opcode_handler_t)-1, - (opcode_handler_t)1214, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1220, - (opcode_handler_t)1221, - (opcode_handler_t)1222, - (opcode_handler_t)-1, - (opcode_handler_t)1224, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1235, - (opcode_handler_t)1235, - (opcode_handler_t)1235, - (opcode_handler_t)1235, - (opcode_handler_t)1235, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1250, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1250, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1250, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1250, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1250, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1275, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1275, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1275, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1275, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1275, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1300, - (opcode_handler_t)1300, - (opcode_handler_t)1300, - (opcode_handler_t)1300, - (opcode_handler_t)1300, - (opcode_handler_t)1305, - (opcode_handler_t)1305, - (opcode_handler_t)1305, - (opcode_handler_t)1305, - (opcode_handler_t)1305, - (opcode_handler_t)1310, - (opcode_handler_t)1310, - (opcode_handler_t)1310, - (opcode_handler_t)1310, - (opcode_handler_t)1310, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1320, - (opcode_handler_t)1320, - (opcode_handler_t)1320, - (opcode_handler_t)1320, - (opcode_handler_t)1320, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)1325, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1355, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1365, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1380, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1390, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1406, - (opcode_handler_t)1407, - (opcode_handler_t)-1, - (opcode_handler_t)1409, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1416, - (opcode_handler_t)1417, - (opcode_handler_t)-1, - (opcode_handler_t)1419, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)1425, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1455, - (opcode_handler_t)1455, - (opcode_handler_t)1455, - (opcode_handler_t)1455, - (opcode_handler_t)1455, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1475, - (opcode_handler_t)1476, - (opcode_handler_t)1477, - (opcode_handler_t)-1, - (opcode_handler_t)1479, - (opcode_handler_t)1475, - (opcode_handler_t)1476, - (opcode_handler_t)1477, - (opcode_handler_t)-1, - (opcode_handler_t)1479, - (opcode_handler_t)1475, - (opcode_handler_t)1476, - (opcode_handler_t)1477, - (opcode_handler_t)-1, - (opcode_handler_t)1479, - (opcode_handler_t)1475, - (opcode_handler_t)1476, - (opcode_handler_t)1477, - (opcode_handler_t)-1, - (opcode_handler_t)1479, - (opcode_handler_t)1475, - (opcode_handler_t)1476, - (opcode_handler_t)1477, - (opcode_handler_t)-1, - (opcode_handler_t)1479, - (opcode_handler_t)1500, - (opcode_handler_t)1500, - (opcode_handler_t)1500, - (opcode_handler_t)1500, - (opcode_handler_t)1500, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1525, - (opcode_handler_t)1550, - (opcode_handler_t)1550, - (opcode_handler_t)1550, - (opcode_handler_t)1550, - (opcode_handler_t)1550, - (opcode_handler_t)1555, - (opcode_handler_t)1555, - (opcode_handler_t)1555, - (opcode_handler_t)1555, - (opcode_handler_t)1555, - (opcode_handler_t)1560, - (opcode_handler_t)1560, - (opcode_handler_t)1560, - (opcode_handler_t)1560, - (opcode_handler_t)1560, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1570, - (opcode_handler_t)1570, - (opcode_handler_t)1570, - (opcode_handler_t)1570, - (opcode_handler_t)1570, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1575, - (opcode_handler_t)1600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1625, - (opcode_handler_t)1625, - (opcode_handler_t)1625, - (opcode_handler_t)1625, - (opcode_handler_t)1625, - (opcode_handler_t)1630, - (opcode_handler_t)1630, - (opcode_handler_t)1630, - (opcode_handler_t)1630, - (opcode_handler_t)1630, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1660, - (opcode_handler_t)1660, - (opcode_handler_t)1660, - (opcode_handler_t)1660, - (opcode_handler_t)1660, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1670, - (opcode_handler_t)1670, - (opcode_handler_t)1670, - (opcode_handler_t)1670, - (opcode_handler_t)1670, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1685, - (opcode_handler_t)1685, - (opcode_handler_t)1685, - (opcode_handler_t)1685, - (opcode_handler_t)1685, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1695, - (opcode_handler_t)1695, - (opcode_handler_t)1695, - (opcode_handler_t)1695, - (opcode_handler_t)1695, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1700, - (opcode_handler_t)1725, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1725, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1725, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1725, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1725, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1755, - (opcode_handler_t)1755, - (opcode_handler_t)1755, - (opcode_handler_t)1755, - (opcode_handler_t)1755, - (opcode_handler_t)1760, - (opcode_handler_t)1760, - (opcode_handler_t)1760, - (opcode_handler_t)1760, - (opcode_handler_t)1760, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1775, - (opcode_handler_t)1776, - (opcode_handler_t)1777, - (opcode_handler_t)1778, - (opcode_handler_t)1779, - (opcode_handler_t)1780, - (opcode_handler_t)1781, - (opcode_handler_t)1782, - (opcode_handler_t)1783, - (opcode_handler_t)1784, - (opcode_handler_t)1785, - (opcode_handler_t)1786, - (opcode_handler_t)1787, - (opcode_handler_t)1788, - (opcode_handler_t)1789, - (opcode_handler_t)1790, - (opcode_handler_t)1791, - (opcode_handler_t)1792, - (opcode_handler_t)1793, - (opcode_handler_t)1794, - (opcode_handler_t)1795, - (opcode_handler_t)1796, - (opcode_handler_t)1797, - (opcode_handler_t)1798, - (opcode_handler_t)1799, - (opcode_handler_t)1800, - (opcode_handler_t)1801, - (opcode_handler_t)1802, - (opcode_handler_t)1803, - (opcode_handler_t)1804, - (opcode_handler_t)1805, - (opcode_handler_t)1806, - (opcode_handler_t)1807, - (opcode_handler_t)1808, - (opcode_handler_t)1809, - (opcode_handler_t)1810, - (opcode_handler_t)1811, - (opcode_handler_t)1812, - (opcode_handler_t)1813, - (opcode_handler_t)1814, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1820, - (opcode_handler_t)1821, - (opcode_handler_t)1822, - (opcode_handler_t)1823, - (opcode_handler_t)1824, - (opcode_handler_t)1825, - (opcode_handler_t)1825, - (opcode_handler_t)1825, - (opcode_handler_t)1825, - (opcode_handler_t)1825, - (opcode_handler_t)1830, - (opcode_handler_t)1830, - (opcode_handler_t)1830, - (opcode_handler_t)1830, - (opcode_handler_t)1830, - (opcode_handler_t)1835, - (opcode_handler_t)1835, - (opcode_handler_t)1835, - (opcode_handler_t)1835, - (opcode_handler_t)1835, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1845, - (opcode_handler_t)1845, - (opcode_handler_t)1845, - (opcode_handler_t)1845, - (opcode_handler_t)1845, - (opcode_handler_t)1850, - (opcode_handler_t)-1, - (opcode_handler_t)1852, - (opcode_handler_t)1853, - (opcode_handler_t)-1, - (opcode_handler_t)1855, - (opcode_handler_t)-1, - (opcode_handler_t)1857, - (opcode_handler_t)1858, - (opcode_handler_t)-1, - (opcode_handler_t)1860, - (opcode_handler_t)-1, - (opcode_handler_t)1862, - (opcode_handler_t)1863, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1870, - (opcode_handler_t)-1, - (opcode_handler_t)1872, - (opcode_handler_t)1873, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1885, - (opcode_handler_t)1886, - (opcode_handler_t)1887, - (opcode_handler_t)-1, - (opcode_handler_t)1889, - (opcode_handler_t)1890, - (opcode_handler_t)1891, - (opcode_handler_t)1892, - (opcode_handler_t)-1, - (opcode_handler_t)1894, - (opcode_handler_t)1895, - (opcode_handler_t)1896, - (opcode_handler_t)1897, - (opcode_handler_t)-1, - (opcode_handler_t)1899, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1910, - (opcode_handler_t)1911, - (opcode_handler_t)1912, - (opcode_handler_t)-1, - (opcode_handler_t)1914, - (opcode_handler_t)1915, - (opcode_handler_t)1916, - (opcode_handler_t)1917, - (opcode_handler_t)-1, - (opcode_handler_t)1919, - (opcode_handler_t)1920, - (opcode_handler_t)1921, - (opcode_handler_t)1922, - (opcode_handler_t)-1, - (opcode_handler_t)1924, - (opcode_handler_t)1925, - (opcode_handler_t)1925, - (opcode_handler_t)1925, - (opcode_handler_t)1925, - (opcode_handler_t)1925, - (opcode_handler_t)1930, - (opcode_handler_t)1930, - (opcode_handler_t)1930, - (opcode_handler_t)1930, - (opcode_handler_t)1930, - (opcode_handler_t)1935, - (opcode_handler_t)1935, - (opcode_handler_t)1935, - (opcode_handler_t)1935, - (opcode_handler_t)1935, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1945, - (opcode_handler_t)1945, - (opcode_handler_t)1945, - (opcode_handler_t)1945, - (opcode_handler_t)1945, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1960, - (opcode_handler_t)1960, - (opcode_handler_t)1960, - (opcode_handler_t)1960, - (opcode_handler_t)1960, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)1975, - (opcode_handler_t)1975, - (opcode_handler_t)1975, - (opcode_handler_t)1975, - (opcode_handler_t)1975, - (opcode_handler_t)1980, - (opcode_handler_t)1980, - (opcode_handler_t)1980, - (opcode_handler_t)1980, - (opcode_handler_t)1980, - (opcode_handler_t)1985, - (opcode_handler_t)1985, - (opcode_handler_t)1985, - (opcode_handler_t)1985, - (opcode_handler_t)1985, - (opcode_handler_t)1990, - (opcode_handler_t)1990, - (opcode_handler_t)1990, - (opcode_handler_t)1990, - (opcode_handler_t)1990, - (opcode_handler_t)1995, - (opcode_handler_t)1995, - (opcode_handler_t)1995, - (opcode_handler_t)1995, - (opcode_handler_t)1995, - (opcode_handler_t)2000, - (opcode_handler_t)-1, - (opcode_handler_t)2002, - (opcode_handler_t)2003, - (opcode_handler_t)-1, - (opcode_handler_t)2005, - (opcode_handler_t)-1, - (opcode_handler_t)2007, - (opcode_handler_t)2008, - (opcode_handler_t)-1, - (opcode_handler_t)2010, - (opcode_handler_t)-1, - (opcode_handler_t)2012, - (opcode_handler_t)2013, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2020, - (opcode_handler_t)-1, - (opcode_handler_t)2022, - (opcode_handler_t)2023, - (opcode_handler_t)-1, - (opcode_handler_t)2025, - (opcode_handler_t)2026, - (opcode_handler_t)2027, - (opcode_handler_t)-1, - (opcode_handler_t)2029, - (opcode_handler_t)2030, - (opcode_handler_t)2031, - (opcode_handler_t)2032, - (opcode_handler_t)-1, - (opcode_handler_t)2034, - (opcode_handler_t)2035, - (opcode_handler_t)2036, - (opcode_handler_t)2037, - (opcode_handler_t)-1, - (opcode_handler_t)2039, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2045, - (opcode_handler_t)2046, - (opcode_handler_t)2047, - (opcode_handler_t)-1, - (opcode_handler_t)2049, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2060, - (opcode_handler_t)2061, - (opcode_handler_t)2062, - (opcode_handler_t)-1, - (opcode_handler_t)2064, - (opcode_handler_t)2065, - (opcode_handler_t)2066, - (opcode_handler_t)2067, - (opcode_handler_t)-1, - (opcode_handler_t)2069, - (opcode_handler_t)2070, - (opcode_handler_t)2071, - (opcode_handler_t)2072, - (opcode_handler_t)-1, - (opcode_handler_t)2074, - (opcode_handler_t)2075, - (opcode_handler_t)-1, - (opcode_handler_t)2077, - (opcode_handler_t)2078, - (opcode_handler_t)-1, - (opcode_handler_t)2080, - (opcode_handler_t)-1, - (opcode_handler_t)2082, - (opcode_handler_t)2083, - (opcode_handler_t)-1, - (opcode_handler_t)2085, - (opcode_handler_t)-1, - (opcode_handler_t)2087, - (opcode_handler_t)2088, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2095, - (opcode_handler_t)-1, - (opcode_handler_t)2097, - (opcode_handler_t)2098, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2110, - (opcode_handler_t)2111, - (opcode_handler_t)2112, - (opcode_handler_t)2113, - (opcode_handler_t)2114, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2120, - (opcode_handler_t)2121, - (opcode_handler_t)2122, - (opcode_handler_t)2123, - (opcode_handler_t)2124, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2135, - (opcode_handler_t)2136, - (opcode_handler_t)2137, - (opcode_handler_t)-1, - (opcode_handler_t)2139, - (opcode_handler_t)2140, - (opcode_handler_t)2141, - (opcode_handler_t)2142, - (opcode_handler_t)-1, - (opcode_handler_t)2144, - (opcode_handler_t)2145, - (opcode_handler_t)2146, - (opcode_handler_t)2147, - (opcode_handler_t)-1, - (opcode_handler_t)2149, - (opcode_handler_t)2150, - (opcode_handler_t)-1, - (opcode_handler_t)2152, - (opcode_handler_t)2153, - (opcode_handler_t)-1, - (opcode_handler_t)2155, - (opcode_handler_t)-1, - (opcode_handler_t)2157, - (opcode_handler_t)2158, - (opcode_handler_t)-1, - (opcode_handler_t)2160, - (opcode_handler_t)-1, - (opcode_handler_t)2162, - (opcode_handler_t)2163, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2170, - (opcode_handler_t)-1, - (opcode_handler_t)2172, - (opcode_handler_t)2173, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2185, - (opcode_handler_t)2186, - (opcode_handler_t)2187, - (opcode_handler_t)2188, - (opcode_handler_t)2189, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2195, - (opcode_handler_t)2196, - (opcode_handler_t)2197, - (opcode_handler_t)2198, - (opcode_handler_t)2199, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2210, - (opcode_handler_t)2211, - (opcode_handler_t)2212, - (opcode_handler_t)-1, - (opcode_handler_t)2214, - (opcode_handler_t)2215, - (opcode_handler_t)2216, - (opcode_handler_t)2217, - (opcode_handler_t)-1, - (opcode_handler_t)2219, - (opcode_handler_t)2220, - (opcode_handler_t)2221, - (opcode_handler_t)2222, - (opcode_handler_t)-1, - (opcode_handler_t)2224, - (opcode_handler_t)2225, - (opcode_handler_t)-1, - (opcode_handler_t)2227, - (opcode_handler_t)2228, - (opcode_handler_t)-1, - (opcode_handler_t)2230, - (opcode_handler_t)-1, - (opcode_handler_t)2232, - (opcode_handler_t)2233, - (opcode_handler_t)-1, - (opcode_handler_t)2235, - (opcode_handler_t)-1, - (opcode_handler_t)2237, - (opcode_handler_t)2238, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2245, - (opcode_handler_t)-1, - (opcode_handler_t)2247, - (opcode_handler_t)2248, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2260, - (opcode_handler_t)2261, - (opcode_handler_t)2262, - (opcode_handler_t)-1, - (opcode_handler_t)2264, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2270, - (opcode_handler_t)2271, - (opcode_handler_t)2272, - (opcode_handler_t)-1, - (opcode_handler_t)2274, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2285, - (opcode_handler_t)2286, - (opcode_handler_t)2287, - (opcode_handler_t)-1, - (opcode_handler_t)2289, - (opcode_handler_t)2290, - (opcode_handler_t)2291, - (opcode_handler_t)2292, - (opcode_handler_t)-1, - (opcode_handler_t)2294, - (opcode_handler_t)2295, - (opcode_handler_t)2296, - (opcode_handler_t)2297, - (opcode_handler_t)-1, - (opcode_handler_t)2299, - (opcode_handler_t)2300, - (opcode_handler_t)-1, - (opcode_handler_t)2302, - (opcode_handler_t)2303, - (opcode_handler_t)-1, - (opcode_handler_t)2305, - (opcode_handler_t)-1, - (opcode_handler_t)2307, - (opcode_handler_t)2308, - (opcode_handler_t)-1, - (opcode_handler_t)2310, - (opcode_handler_t)-1, - (opcode_handler_t)2312, - (opcode_handler_t)2313, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2320, - (opcode_handler_t)-1, - (opcode_handler_t)2322, - (opcode_handler_t)2323, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2335, - (opcode_handler_t)2336, - (opcode_handler_t)2337, - (opcode_handler_t)2338, - (opcode_handler_t)2339, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2345, - (opcode_handler_t)2346, - (opcode_handler_t)2347, - (opcode_handler_t)2348, - (opcode_handler_t)2349, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2360, - (opcode_handler_t)2361, - (opcode_handler_t)2362, - (opcode_handler_t)-1, - (opcode_handler_t)2364, - (opcode_handler_t)2365, - (opcode_handler_t)2366, - (opcode_handler_t)2367, - (opcode_handler_t)-1, - (opcode_handler_t)2369, - (opcode_handler_t)2370, - (opcode_handler_t)2371, - (opcode_handler_t)2372, - (opcode_handler_t)-1, - (opcode_handler_t)2374, - (opcode_handler_t)2375, - (opcode_handler_t)-1, - (opcode_handler_t)2377, - (opcode_handler_t)2378, - (opcode_handler_t)-1, - (opcode_handler_t)2380, - (opcode_handler_t)-1, - (opcode_handler_t)2382, - (opcode_handler_t)2383, - (opcode_handler_t)-1, - (opcode_handler_t)2385, - (opcode_handler_t)-1, - (opcode_handler_t)2387, - (opcode_handler_t)2388, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2395, - (opcode_handler_t)-1, - (opcode_handler_t)2397, - (opcode_handler_t)2398, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2410, - (opcode_handler_t)2411, - (opcode_handler_t)2412, - (opcode_handler_t)-1, - (opcode_handler_t)2414, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2420, - (opcode_handler_t)2421, - (opcode_handler_t)2422, - (opcode_handler_t)-1, - (opcode_handler_t)2424, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2435, - (opcode_handler_t)2436, - (opcode_handler_t)2437, - (opcode_handler_t)-1, - (opcode_handler_t)2439, - (opcode_handler_t)2440, - (opcode_handler_t)2441, - (opcode_handler_t)2442, - (opcode_handler_t)-1, - (opcode_handler_t)2444, - (opcode_handler_t)2445, - (opcode_handler_t)2446, - (opcode_handler_t)2447, - (opcode_handler_t)-1, - (opcode_handler_t)2449, - (opcode_handler_t)2450, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2455, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2475, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2485, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2490, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2500, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2500, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2500, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2500, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2500, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2525, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2550, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2575, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2600, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)2625, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2660, - (opcode_handler_t)2660, - (opcode_handler_t)2660, - (opcode_handler_t)2660, - (opcode_handler_t)2660, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2670, - (opcode_handler_t)2670, - (opcode_handler_t)2670, - (opcode_handler_t)2670, - (opcode_handler_t)2670, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2679, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2700, - (opcode_handler_t)2700, - (opcode_handler_t)2700, - (opcode_handler_t)2700, - (opcode_handler_t)2700, - (opcode_handler_t)2705, - (opcode_handler_t)2705, - (opcode_handler_t)2705, - (opcode_handler_t)2705, - (opcode_handler_t)2705, - (opcode_handler_t)2710, - (opcode_handler_t)2710, - (opcode_handler_t)2710, - (opcode_handler_t)2710, - (opcode_handler_t)2710, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2720, - (opcode_handler_t)2720, - (opcode_handler_t)2720, - (opcode_handler_t)2720, - (opcode_handler_t)2720, - (opcode_handler_t)2725, - (opcode_handler_t)2726, - (opcode_handler_t)2727, - (opcode_handler_t)2728, - (opcode_handler_t)2729, - (opcode_handler_t)2725, - (opcode_handler_t)2726, - (opcode_handler_t)2727, - (opcode_handler_t)2728, - (opcode_handler_t)2729, - (opcode_handler_t)2725, - (opcode_handler_t)2726, - (opcode_handler_t)2727, - (opcode_handler_t)2728, - (opcode_handler_t)2729, - (opcode_handler_t)2725, - (opcode_handler_t)2726, - (opcode_handler_t)2727, - (opcode_handler_t)2728, - (opcode_handler_t)2729, - (opcode_handler_t)2725, - (opcode_handler_t)2726, - (opcode_handler_t)2727, - (opcode_handler_t)2728, - (opcode_handler_t)2729, - (opcode_handler_t)2750, - (opcode_handler_t)2750, - (opcode_handler_t)2750, - (opcode_handler_t)2750, - (opcode_handler_t)2750, - (opcode_handler_t)2755, - (opcode_handler_t)2755, - (opcode_handler_t)2755, - (opcode_handler_t)2755, - (opcode_handler_t)2755, - (opcode_handler_t)2760, - (opcode_handler_t)2760, - (opcode_handler_t)2760, - (opcode_handler_t)2760, - (opcode_handler_t)2760, - (opcode_handler_t)2765, - (opcode_handler_t)2765, - (opcode_handler_t)2765, - (opcode_handler_t)2765, - (opcode_handler_t)2765, - (opcode_handler_t)2770, - (opcode_handler_t)2770, - (opcode_handler_t)2770, - (opcode_handler_t)2770, - (opcode_handler_t)2770, - (opcode_handler_t)2775, - (opcode_handler_t)2775, - (opcode_handler_t)2775, - (opcode_handler_t)2775, - (opcode_handler_t)2775, - (opcode_handler_t)2780, - (opcode_handler_t)2780, - (opcode_handler_t)2780, - (opcode_handler_t)2780, - (opcode_handler_t)2780, - (opcode_handler_t)2785, - (opcode_handler_t)2785, - (opcode_handler_t)2785, - (opcode_handler_t)2785, - (opcode_handler_t)2785, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2795, - (opcode_handler_t)2795, - (opcode_handler_t)2795, - (opcode_handler_t)2795, - (opcode_handler_t)2795, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2805, - (opcode_handler_t)2806, - (opcode_handler_t)2807, - (opcode_handler_t)-1, - (opcode_handler_t)2809, - (opcode_handler_t)2810, - (opcode_handler_t)2811, - (opcode_handler_t)2812, - (opcode_handler_t)-1, - (opcode_handler_t)2814, - (opcode_handler_t)2815, - (opcode_handler_t)2816, - (opcode_handler_t)2817, - (opcode_handler_t)-1, - (opcode_handler_t)2819, - (opcode_handler_t)2820, - (opcode_handler_t)2821, - (opcode_handler_t)2822, - (opcode_handler_t)-1, - (opcode_handler_t)2824, - (opcode_handler_t)2825, - (opcode_handler_t)2826, - (opcode_handler_t)2827, - (opcode_handler_t)2828, - (opcode_handler_t)2829, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2835, - (opcode_handler_t)2836, - (opcode_handler_t)2837, - (opcode_handler_t)2838, - (opcode_handler_t)2839, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2850, - (opcode_handler_t)-1, - (opcode_handler_t)2852, - (opcode_handler_t)2853, - (opcode_handler_t)-1, - (opcode_handler_t)2855, - (opcode_handler_t)-1, - (opcode_handler_t)2857, - (opcode_handler_t)2858, - (opcode_handler_t)-1, - (opcode_handler_t)2860, - (opcode_handler_t)-1, - (opcode_handler_t)2862, - (opcode_handler_t)2863, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2870, - (opcode_handler_t)-1, - (opcode_handler_t)2872, - (opcode_handler_t)2873, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)2885, - (opcode_handler_t)2886, - (opcode_handler_t)2887, - (opcode_handler_t)-1, - (opcode_handler_t)2889, - (opcode_handler_t)2890, - (opcode_handler_t)2891, - (opcode_handler_t)2892, - (opcode_handler_t)-1, - (opcode_handler_t)2894, - (opcode_handler_t)2895, - (opcode_handler_t)2896, - (opcode_handler_t)2897, - (opcode_handler_t)-1, - (opcode_handler_t)2899, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3310, - (opcode_handler_t)3311, - (opcode_handler_t)3312, - (opcode_handler_t)-1, - (opcode_handler_t)3314, - (opcode_handler_t)3315, - (opcode_handler_t)3316, - (opcode_handler_t)3317, - (opcode_handler_t)-1, - (opcode_handler_t)3319, - (opcode_handler_t)3320, - (opcode_handler_t)3321, - (opcode_handler_t)3322, - (opcode_handler_t)-1, - (opcode_handler_t)3324, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3335, - (opcode_handler_t)3336, - (opcode_handler_t)3337, - (opcode_handler_t)-1, - (opcode_handler_t)3339, - (opcode_handler_t)3340, - (opcode_handler_t)3341, - (opcode_handler_t)3342, - (opcode_handler_t)-1, - (opcode_handler_t)3344, - (opcode_handler_t)3345, - (opcode_handler_t)3346, - (opcode_handler_t)3347, - (opcode_handler_t)-1, - (opcode_handler_t)3349, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3360, - (opcode_handler_t)3361, - (opcode_handler_t)3362, - (opcode_handler_t)-1, - (opcode_handler_t)3364, - (opcode_handler_t)3365, - (opcode_handler_t)3366, - (opcode_handler_t)3367, - (opcode_handler_t)-1, - (opcode_handler_t)3369, - (opcode_handler_t)3370, - (opcode_handler_t)3371, - (opcode_handler_t)3372, - (opcode_handler_t)-1, - (opcode_handler_t)3374, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3385, - (opcode_handler_t)3386, - (opcode_handler_t)3387, - (opcode_handler_t)-1, - (opcode_handler_t)3389, - (opcode_handler_t)3390, - (opcode_handler_t)3391, - (opcode_handler_t)3392, - (opcode_handler_t)-1, - (opcode_handler_t)3394, - (opcode_handler_t)3395, - (opcode_handler_t)3396, - (opcode_handler_t)3397, - (opcode_handler_t)-1, - (opcode_handler_t)3399, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3410, - (opcode_handler_t)3411, - (opcode_handler_t)3412, - (opcode_handler_t)-1, - (opcode_handler_t)3414, - (opcode_handler_t)3415, - (opcode_handler_t)3416, - (opcode_handler_t)3417, - (opcode_handler_t)-1, - (opcode_handler_t)3419, - (opcode_handler_t)3420, - (opcode_handler_t)3421, - (opcode_handler_t)3422, - (opcode_handler_t)-1, - (opcode_handler_t)3424, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3455, - (opcode_handler_t)3455, - (opcode_handler_t)3455, - (opcode_handler_t)3455, - (opcode_handler_t)3455, - (opcode_handler_t)3460, - (opcode_handler_t)3460, - (opcode_handler_t)3460, - (opcode_handler_t)3460, - (opcode_handler_t)3460, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3470, - (opcode_handler_t)3470, - (opcode_handler_t)3470, - (opcode_handler_t)3470, - (opcode_handler_t)3470, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3475, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3500, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3525, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3550, - (opcode_handler_t)3575, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3600, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3625, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)3650, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3685, - (opcode_handler_t)3686, - (opcode_handler_t)3687, - (opcode_handler_t)3688, - (opcode_handler_t)3689, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3695, - (opcode_handler_t)3696, - (opcode_handler_t)3697, - (opcode_handler_t)3698, - (opcode_handler_t)3699, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3710, - (opcode_handler_t)3711, - (opcode_handler_t)3712, - (opcode_handler_t)-1, - (opcode_handler_t)3714, - (opcode_handler_t)3715, - (opcode_handler_t)3716, - (opcode_handler_t)3717, - (opcode_handler_t)-1, - (opcode_handler_t)3719, - (opcode_handler_t)3720, - (opcode_handler_t)3721, - (opcode_handler_t)3722, - (opcode_handler_t)-1, - (opcode_handler_t)3724, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3725, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)3750, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3800, - (opcode_handler_t)3800, - (opcode_handler_t)3800, - (opcode_handler_t)3800, - (opcode_handler_t)3800, - (opcode_handler_t)3805, - (opcode_handler_t)3805, - (opcode_handler_t)3805, - (opcode_handler_t)3805, - (opcode_handler_t)3805, - (opcode_handler_t)3810, - (opcode_handler_t)3810, - (opcode_handler_t)3810, - (opcode_handler_t)3810, - (opcode_handler_t)3810, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3820, - (opcode_handler_t)3820, - (opcode_handler_t)3820, - (opcode_handler_t)3820, - (opcode_handler_t)3820, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3828, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3850, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)3875, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3913, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3925, - (opcode_handler_t)3925, - (opcode_handler_t)3925, - (opcode_handler_t)3925, - (opcode_handler_t)3925, - (opcode_handler_t)3930, - (opcode_handler_t)3930, - (opcode_handler_t)3930, - (opcode_handler_t)3930, - (opcode_handler_t)3930, - (opcode_handler_t)3935, - (opcode_handler_t)3935, - (opcode_handler_t)3935, - (opcode_handler_t)3935, - (opcode_handler_t)3935, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3945, - (opcode_handler_t)3945, - (opcode_handler_t)3945, - (opcode_handler_t)3945, - (opcode_handler_t)3945, - (opcode_handler_t)3950, - (opcode_handler_t)3950, - (opcode_handler_t)3950, - (opcode_handler_t)3950, - (opcode_handler_t)3950, - (opcode_handler_t)3955, - (opcode_handler_t)3955, - (opcode_handler_t)3955, - (opcode_handler_t)3955, - (opcode_handler_t)3955, - (opcode_handler_t)3960, - (opcode_handler_t)3960, - (opcode_handler_t)3960, - (opcode_handler_t)3960, - (opcode_handler_t)3960, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)-1, - (opcode_handler_t)3970, - (opcode_handler_t)3970, - (opcode_handler_t)3970, - (opcode_handler_t)3970, - (opcode_handler_t)3970, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)3975, - (opcode_handler_t)4000, - (opcode_handler_t)4001, - (opcode_handler_t)4002, - (opcode_handler_t)4003, - (opcode_handler_t)4004, - (opcode_handler_t)4005, - (opcode_handler_t)4006, - (opcode_handler_t)4007, - (opcode_handler_t)4008, - (opcode_handler_t)4009, - (opcode_handler_t)4010, - (opcode_handler_t)4011, - (opcode_handler_t)4012, - (opcode_handler_t)4013, - (opcode_handler_t)4014, - (opcode_handler_t)4015, - (opcode_handler_t)4016, - (opcode_handler_t)4017, - (opcode_handler_t)4018, - (opcode_handler_t)4019, - (opcode_handler_t)4020, - (opcode_handler_t)4021, - (opcode_handler_t)4022, - (opcode_handler_t)4023, - (opcode_handler_t)4024, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4025, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4050, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)4075, - (opcode_handler_t)-1 + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_NOP_SPEC_HANDLER, + ZEND_ADD_SPEC_CONST_CONST_HANDLER, + ZEND_ADD_SPEC_CONST_TMP_HANDLER, + ZEND_ADD_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_SPEC_CONST_CV_HANDLER, + ZEND_ADD_SPEC_TMP_CONST_HANDLER, + ZEND_ADD_SPEC_TMP_TMP_HANDLER, + ZEND_ADD_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_SPEC_TMP_CV_HANDLER, + ZEND_ADD_SPEC_VAR_CONST_HANDLER, + ZEND_ADD_SPEC_VAR_TMP_HANDLER, + ZEND_ADD_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_SPEC_CV_CONST_HANDLER, + ZEND_ADD_SPEC_CV_TMP_HANDLER, + ZEND_ADD_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_SPEC_CV_CV_HANDLER, + ZEND_SUB_SPEC_CONST_CONST_HANDLER, + ZEND_SUB_SPEC_CONST_TMP_HANDLER, + ZEND_SUB_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SUB_SPEC_CONST_CV_HANDLER, + ZEND_SUB_SPEC_TMP_CONST_HANDLER, + ZEND_SUB_SPEC_TMP_TMP_HANDLER, + ZEND_SUB_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SUB_SPEC_TMP_CV_HANDLER, + ZEND_SUB_SPEC_VAR_CONST_HANDLER, + ZEND_SUB_SPEC_VAR_TMP_HANDLER, + ZEND_SUB_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SUB_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SUB_SPEC_CV_CONST_HANDLER, + ZEND_SUB_SPEC_CV_TMP_HANDLER, + ZEND_SUB_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SUB_SPEC_CV_CV_HANDLER, + ZEND_MUL_SPEC_CONST_CONST_HANDLER, + ZEND_MUL_SPEC_CONST_TMP_HANDLER, + ZEND_MUL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MUL_SPEC_CONST_CV_HANDLER, + ZEND_MUL_SPEC_TMP_CONST_HANDLER, + ZEND_MUL_SPEC_TMP_TMP_HANDLER, + ZEND_MUL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MUL_SPEC_TMP_CV_HANDLER, + ZEND_MUL_SPEC_VAR_CONST_HANDLER, + ZEND_MUL_SPEC_VAR_TMP_HANDLER, + ZEND_MUL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MUL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MUL_SPEC_CV_CONST_HANDLER, + ZEND_MUL_SPEC_CV_TMP_HANDLER, + ZEND_MUL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MUL_SPEC_CV_CV_HANDLER, + ZEND_DIV_SPEC_CONST_CONST_HANDLER, + ZEND_DIV_SPEC_CONST_TMP_HANDLER, + ZEND_DIV_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DIV_SPEC_CONST_CV_HANDLER, + ZEND_DIV_SPEC_TMP_CONST_HANDLER, + ZEND_DIV_SPEC_TMP_TMP_HANDLER, + ZEND_DIV_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DIV_SPEC_TMP_CV_HANDLER, + ZEND_DIV_SPEC_VAR_CONST_HANDLER, + ZEND_DIV_SPEC_VAR_TMP_HANDLER, + ZEND_DIV_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DIV_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DIV_SPEC_CV_CONST_HANDLER, + ZEND_DIV_SPEC_CV_TMP_HANDLER, + ZEND_DIV_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DIV_SPEC_CV_CV_HANDLER, + ZEND_MOD_SPEC_CONST_CONST_HANDLER, + ZEND_MOD_SPEC_CONST_TMP_HANDLER, + ZEND_MOD_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MOD_SPEC_CONST_CV_HANDLER, + ZEND_MOD_SPEC_TMP_CONST_HANDLER, + ZEND_MOD_SPEC_TMP_TMP_HANDLER, + ZEND_MOD_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MOD_SPEC_TMP_CV_HANDLER, + ZEND_MOD_SPEC_VAR_CONST_HANDLER, + ZEND_MOD_SPEC_VAR_TMP_HANDLER, + ZEND_MOD_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MOD_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MOD_SPEC_CV_CONST_HANDLER, + ZEND_MOD_SPEC_CV_TMP_HANDLER, + ZEND_MOD_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_MOD_SPEC_CV_CV_HANDLER, + ZEND_SL_SPEC_CONST_CONST_HANDLER, + ZEND_SL_SPEC_CONST_TMP_HANDLER, + ZEND_SL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SL_SPEC_CONST_CV_HANDLER, + ZEND_SL_SPEC_TMP_CONST_HANDLER, + ZEND_SL_SPEC_TMP_TMP_HANDLER, + ZEND_SL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SL_SPEC_TMP_CV_HANDLER, + ZEND_SL_SPEC_VAR_CONST_HANDLER, + ZEND_SL_SPEC_VAR_TMP_HANDLER, + ZEND_SL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SL_SPEC_CV_CONST_HANDLER, + ZEND_SL_SPEC_CV_TMP_HANDLER, + ZEND_SL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SL_SPEC_CV_CV_HANDLER, + ZEND_SR_SPEC_CONST_CONST_HANDLER, + ZEND_SR_SPEC_CONST_TMP_HANDLER, + ZEND_SR_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SR_SPEC_CONST_CV_HANDLER, + ZEND_SR_SPEC_TMP_CONST_HANDLER, + ZEND_SR_SPEC_TMP_TMP_HANDLER, + ZEND_SR_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SR_SPEC_TMP_CV_HANDLER, + ZEND_SR_SPEC_VAR_CONST_HANDLER, + ZEND_SR_SPEC_VAR_TMP_HANDLER, + ZEND_SR_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SR_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SR_SPEC_CV_CONST_HANDLER, + ZEND_SR_SPEC_CV_TMP_HANDLER, + ZEND_SR_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SR_SPEC_CV_CV_HANDLER, + ZEND_CONCAT_SPEC_CONST_CONST_HANDLER, + ZEND_CONCAT_SPEC_CONST_TMP_HANDLER, + ZEND_CONCAT_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONCAT_SPEC_CONST_CV_HANDLER, + ZEND_CONCAT_SPEC_TMP_CONST_HANDLER, + ZEND_CONCAT_SPEC_TMP_TMP_HANDLER, + ZEND_CONCAT_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONCAT_SPEC_TMP_CV_HANDLER, + ZEND_CONCAT_SPEC_VAR_CONST_HANDLER, + ZEND_CONCAT_SPEC_VAR_TMP_HANDLER, + ZEND_CONCAT_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONCAT_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONCAT_SPEC_CV_CONST_HANDLER, + ZEND_CONCAT_SPEC_CV_TMP_HANDLER, + ZEND_CONCAT_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONCAT_SPEC_CV_CV_HANDLER, + ZEND_BW_OR_SPEC_CONST_CONST_HANDLER, + ZEND_BW_OR_SPEC_CONST_TMP_HANDLER, + ZEND_BW_OR_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_OR_SPEC_CONST_CV_HANDLER, + ZEND_BW_OR_SPEC_TMP_CONST_HANDLER, + ZEND_BW_OR_SPEC_TMP_TMP_HANDLER, + ZEND_BW_OR_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_OR_SPEC_TMP_CV_HANDLER, + ZEND_BW_OR_SPEC_VAR_CONST_HANDLER, + ZEND_BW_OR_SPEC_VAR_TMP_HANDLER, + ZEND_BW_OR_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_OR_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_OR_SPEC_CV_CONST_HANDLER, + ZEND_BW_OR_SPEC_CV_TMP_HANDLER, + ZEND_BW_OR_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_OR_SPEC_CV_CV_HANDLER, + ZEND_BW_AND_SPEC_CONST_CONST_HANDLER, + ZEND_BW_AND_SPEC_CONST_TMP_HANDLER, + ZEND_BW_AND_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_AND_SPEC_CONST_CV_HANDLER, + ZEND_BW_AND_SPEC_TMP_CONST_HANDLER, + ZEND_BW_AND_SPEC_TMP_TMP_HANDLER, + ZEND_BW_AND_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_AND_SPEC_TMP_CV_HANDLER, + ZEND_BW_AND_SPEC_VAR_CONST_HANDLER, + ZEND_BW_AND_SPEC_VAR_TMP_HANDLER, + ZEND_BW_AND_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_AND_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_AND_SPEC_CV_CONST_HANDLER, + ZEND_BW_AND_SPEC_CV_TMP_HANDLER, + ZEND_BW_AND_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_AND_SPEC_CV_CV_HANDLER, + ZEND_BW_XOR_SPEC_CONST_CONST_HANDLER, + ZEND_BW_XOR_SPEC_CONST_TMP_HANDLER, + ZEND_BW_XOR_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_XOR_SPEC_CONST_CV_HANDLER, + ZEND_BW_XOR_SPEC_TMP_CONST_HANDLER, + ZEND_BW_XOR_SPEC_TMP_TMP_HANDLER, + ZEND_BW_XOR_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_XOR_SPEC_TMP_CV_HANDLER, + ZEND_BW_XOR_SPEC_VAR_CONST_HANDLER, + ZEND_BW_XOR_SPEC_VAR_TMP_HANDLER, + ZEND_BW_XOR_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_XOR_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_XOR_SPEC_CV_CONST_HANDLER, + ZEND_BW_XOR_SPEC_CV_TMP_HANDLER, + ZEND_BW_XOR_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_XOR_SPEC_CV_CV_HANDLER, + ZEND_BW_NOT_SPEC_CONST_HANDLER, + ZEND_BW_NOT_SPEC_CONST_HANDLER, + ZEND_BW_NOT_SPEC_CONST_HANDLER, + ZEND_BW_NOT_SPEC_CONST_HANDLER, + ZEND_BW_NOT_SPEC_CONST_HANDLER, + ZEND_BW_NOT_SPEC_TMP_HANDLER, + ZEND_BW_NOT_SPEC_TMP_HANDLER, + ZEND_BW_NOT_SPEC_TMP_HANDLER, + ZEND_BW_NOT_SPEC_TMP_HANDLER, + ZEND_BW_NOT_SPEC_TMP_HANDLER, + ZEND_BW_NOT_SPEC_VAR_HANDLER, + ZEND_BW_NOT_SPEC_VAR_HANDLER, + ZEND_BW_NOT_SPEC_VAR_HANDLER, + ZEND_BW_NOT_SPEC_VAR_HANDLER, + ZEND_BW_NOT_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BW_NOT_SPEC_CV_HANDLER, + ZEND_BW_NOT_SPEC_CV_HANDLER, + ZEND_BW_NOT_SPEC_CV_HANDLER, + ZEND_BW_NOT_SPEC_CV_HANDLER, + ZEND_BW_NOT_SPEC_CV_HANDLER, + ZEND_BOOL_NOT_SPEC_CONST_HANDLER, + ZEND_BOOL_NOT_SPEC_CONST_HANDLER, + ZEND_BOOL_NOT_SPEC_CONST_HANDLER, + ZEND_BOOL_NOT_SPEC_CONST_HANDLER, + ZEND_BOOL_NOT_SPEC_CONST_HANDLER, + ZEND_BOOL_NOT_SPEC_TMP_HANDLER, + ZEND_BOOL_NOT_SPEC_TMP_HANDLER, + ZEND_BOOL_NOT_SPEC_TMP_HANDLER, + ZEND_BOOL_NOT_SPEC_TMP_HANDLER, + ZEND_BOOL_NOT_SPEC_TMP_HANDLER, + ZEND_BOOL_NOT_SPEC_VAR_HANDLER, + ZEND_BOOL_NOT_SPEC_VAR_HANDLER, + ZEND_BOOL_NOT_SPEC_VAR_HANDLER, + ZEND_BOOL_NOT_SPEC_VAR_HANDLER, + ZEND_BOOL_NOT_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_NOT_SPEC_CV_HANDLER, + ZEND_BOOL_NOT_SPEC_CV_HANDLER, + ZEND_BOOL_NOT_SPEC_CV_HANDLER, + ZEND_BOOL_NOT_SPEC_CV_HANDLER, + ZEND_BOOL_NOT_SPEC_CV_HANDLER, + ZEND_BOOL_XOR_SPEC_CONST_CONST_HANDLER, + ZEND_BOOL_XOR_SPEC_CONST_TMP_HANDLER, + ZEND_BOOL_XOR_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_XOR_SPEC_CONST_CV_HANDLER, + ZEND_BOOL_XOR_SPEC_TMP_CONST_HANDLER, + ZEND_BOOL_XOR_SPEC_TMP_TMP_HANDLER, + ZEND_BOOL_XOR_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_XOR_SPEC_TMP_CV_HANDLER, + ZEND_BOOL_XOR_SPEC_VAR_CONST_HANDLER, + ZEND_BOOL_XOR_SPEC_VAR_TMP_HANDLER, + ZEND_BOOL_XOR_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_XOR_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER, + ZEND_BOOL_XOR_SPEC_CV_TMP_HANDLER, + ZEND_BOOL_XOR_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CONST_CONST_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CONST_TMP_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CONST_CV_HANDLER, + ZEND_IS_IDENTICAL_SPEC_TMP_CONST_HANDLER, + ZEND_IS_IDENTICAL_SPEC_TMP_TMP_HANDLER, + ZEND_IS_IDENTICAL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_IDENTICAL_SPEC_TMP_CV_HANDLER, + ZEND_IS_IDENTICAL_SPEC_VAR_CONST_HANDLER, + ZEND_IS_IDENTICAL_SPEC_VAR_TMP_HANDLER, + ZEND_IS_IDENTICAL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_IDENTICAL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CV_CONST_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CV_TMP_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_IDENTICAL_SPEC_CV_CV_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CONST_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CONST_TMP_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CONST_CV_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CONST_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_TMP_TMP_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_TMP_CV_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONST_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_VAR_TMP_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CV_CONST_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_IDENTICAL_SPEC_CV_CV_HANDLER, + ZEND_IS_EQUAL_SPEC_CONST_CONST_HANDLER, + ZEND_IS_EQUAL_SPEC_CONST_TMP_HANDLER, + ZEND_IS_EQUAL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_EQUAL_SPEC_CONST_CV_HANDLER, + ZEND_IS_EQUAL_SPEC_TMP_CONST_HANDLER, + ZEND_IS_EQUAL_SPEC_TMP_TMP_HANDLER, + ZEND_IS_EQUAL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_EQUAL_SPEC_TMP_CV_HANDLER, + ZEND_IS_EQUAL_SPEC_VAR_CONST_HANDLER, + ZEND_IS_EQUAL_SPEC_VAR_TMP_HANDLER, + ZEND_IS_EQUAL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_EQUAL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_EQUAL_SPEC_CV_CONST_HANDLER, + ZEND_IS_EQUAL_SPEC_CV_TMP_HANDLER, + ZEND_IS_EQUAL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_EQUAL_SPEC_CV_CV_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CONST_CONST_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CONST_TMP_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CONST_CV_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_TMP_CONST_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_TMP_TMP_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_TMP_CV_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_VAR_CONST_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_VAR_TMP_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CV_CONST_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CV_TMP_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_NOT_EQUAL_SPEC_CV_CV_HANDLER, + ZEND_IS_SMALLER_SPEC_CONST_CONST_HANDLER, + ZEND_IS_SMALLER_SPEC_CONST_TMP_HANDLER, + ZEND_IS_SMALLER_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_SPEC_CONST_CV_HANDLER, + ZEND_IS_SMALLER_SPEC_TMP_CONST_HANDLER, + ZEND_IS_SMALLER_SPEC_TMP_TMP_HANDLER, + ZEND_IS_SMALLER_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_SPEC_TMP_CV_HANDLER, + ZEND_IS_SMALLER_SPEC_VAR_CONST_HANDLER, + ZEND_IS_SMALLER_SPEC_VAR_TMP_HANDLER, + ZEND_IS_SMALLER_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_SPEC_CV_CONST_HANDLER, + ZEND_IS_SMALLER_SPEC_CV_TMP_HANDLER, + ZEND_IS_SMALLER_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_SPEC_CV_CV_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CONST_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_TMP_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CONST_CV_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CONST_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_TMP_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_TMP_CV_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CONST_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_TMP_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CONST_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_TMP_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_IS_SMALLER_OR_EQUAL_SPEC_CV_CV_HANDLER, + ZEND_CAST_SPEC_CONST_HANDLER, + ZEND_CAST_SPEC_CONST_HANDLER, + ZEND_CAST_SPEC_CONST_HANDLER, + ZEND_CAST_SPEC_CONST_HANDLER, + ZEND_CAST_SPEC_CONST_HANDLER, + ZEND_CAST_SPEC_TMP_HANDLER, + ZEND_CAST_SPEC_TMP_HANDLER, + ZEND_CAST_SPEC_TMP_HANDLER, + ZEND_CAST_SPEC_TMP_HANDLER, + ZEND_CAST_SPEC_TMP_HANDLER, + ZEND_CAST_SPEC_VAR_HANDLER, + ZEND_CAST_SPEC_VAR_HANDLER, + ZEND_CAST_SPEC_VAR_HANDLER, + ZEND_CAST_SPEC_VAR_HANDLER, + ZEND_CAST_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CAST_SPEC_CV_HANDLER, + ZEND_CAST_SPEC_CV_HANDLER, + ZEND_CAST_SPEC_CV_HANDLER, + ZEND_CAST_SPEC_CV_HANDLER, + ZEND_CAST_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_QM_ASSIGN_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_ADD_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_ADD_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_ADD_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_ADD_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_ADD_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_ADD_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_ADD_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_ADD_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_ADD_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_ADD_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_ADD_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_ADD_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_ADD_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_ADD_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_ADD_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SUB_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_SUB_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_SUB_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_SUB_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_SUB_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_SUB_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_SUB_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_SUB_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_SUB_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_SUB_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_SUB_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_SUB_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_SUB_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_SUB_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_SUB_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_MUL_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_MUL_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_MUL_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_MUL_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_MUL_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_MUL_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_MUL_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_MUL_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_MUL_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_MUL_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_MUL_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_MUL_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_MUL_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_MUL_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_MUL_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_DIV_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_DIV_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_DIV_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_DIV_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_DIV_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_DIV_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_DIV_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_DIV_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_DIV_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_DIV_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_DIV_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_DIV_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_DIV_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_DIV_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_DIV_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_MOD_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_MOD_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_MOD_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_MOD_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_MOD_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_MOD_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_MOD_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_MOD_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_MOD_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_MOD_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_MOD_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_MOD_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_MOD_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_MOD_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_MOD_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SL_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_SL_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_SL_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_SL_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_SL_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_SL_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_SL_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_SL_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_SL_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_SL_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_SL_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_SL_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_SL_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_SL_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_SL_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SR_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_SR_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_SR_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_SR_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_SR_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_SR_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_SR_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_SR_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_SR_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_SR_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_SR_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_SR_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_SR_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_SR_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_SR_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_CONCAT_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_BW_OR_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_BW_AND_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_VAR_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_BW_XOR_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_INC_SPEC_VAR_HANDLER, + ZEND_PRE_INC_SPEC_VAR_HANDLER, + ZEND_PRE_INC_SPEC_VAR_HANDLER, + ZEND_PRE_INC_SPEC_VAR_HANDLER, + ZEND_PRE_INC_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_INC_SPEC_CV_HANDLER, + ZEND_PRE_INC_SPEC_CV_HANDLER, + ZEND_PRE_INC_SPEC_CV_HANDLER, + ZEND_PRE_INC_SPEC_CV_HANDLER, + ZEND_PRE_INC_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_DEC_SPEC_VAR_HANDLER, + ZEND_PRE_DEC_SPEC_VAR_HANDLER, + ZEND_PRE_DEC_SPEC_VAR_HANDLER, + ZEND_PRE_DEC_SPEC_VAR_HANDLER, + ZEND_PRE_DEC_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_DEC_SPEC_CV_HANDLER, + ZEND_PRE_DEC_SPEC_CV_HANDLER, + ZEND_PRE_DEC_SPEC_CV_HANDLER, + ZEND_PRE_DEC_SPEC_CV_HANDLER, + ZEND_PRE_DEC_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_INC_SPEC_VAR_HANDLER, + ZEND_POST_INC_SPEC_VAR_HANDLER, + ZEND_POST_INC_SPEC_VAR_HANDLER, + ZEND_POST_INC_SPEC_VAR_HANDLER, + ZEND_POST_INC_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_INC_SPEC_CV_HANDLER, + ZEND_POST_INC_SPEC_CV_HANDLER, + ZEND_POST_INC_SPEC_CV_HANDLER, + ZEND_POST_INC_SPEC_CV_HANDLER, + ZEND_POST_INC_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_DEC_SPEC_VAR_HANDLER, + ZEND_POST_DEC_SPEC_VAR_HANDLER, + ZEND_POST_DEC_SPEC_VAR_HANDLER, + ZEND_POST_DEC_SPEC_VAR_HANDLER, + ZEND_POST_DEC_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_DEC_SPEC_CV_HANDLER, + ZEND_POST_DEC_SPEC_CV_HANDLER, + ZEND_POST_DEC_SPEC_CV_HANDLER, + ZEND_POST_DEC_SPEC_CV_HANDLER, + ZEND_POST_DEC_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_REF_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_REF_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_REF_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_REF_SPEC_CV_CV_HANDLER, + ZEND_ECHO_SPEC_CONST_HANDLER, + ZEND_ECHO_SPEC_CONST_HANDLER, + ZEND_ECHO_SPEC_CONST_HANDLER, + ZEND_ECHO_SPEC_CONST_HANDLER, + ZEND_ECHO_SPEC_CONST_HANDLER, + ZEND_ECHO_SPEC_TMP_HANDLER, + ZEND_ECHO_SPEC_TMP_HANDLER, + ZEND_ECHO_SPEC_TMP_HANDLER, + ZEND_ECHO_SPEC_TMP_HANDLER, + ZEND_ECHO_SPEC_TMP_HANDLER, + ZEND_ECHO_SPEC_VAR_HANDLER, + ZEND_ECHO_SPEC_VAR_HANDLER, + ZEND_ECHO_SPEC_VAR_HANDLER, + ZEND_ECHO_SPEC_VAR_HANDLER, + ZEND_ECHO_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ECHO_SPEC_CV_HANDLER, + ZEND_ECHO_SPEC_CV_HANDLER, + ZEND_ECHO_SPEC_CV_HANDLER, + ZEND_ECHO_SPEC_CV_HANDLER, + ZEND_ECHO_SPEC_CV_HANDLER, + ZEND_PRINT_SPEC_CONST_HANDLER, + ZEND_PRINT_SPEC_CONST_HANDLER, + ZEND_PRINT_SPEC_CONST_HANDLER, + ZEND_PRINT_SPEC_CONST_HANDLER, + ZEND_PRINT_SPEC_CONST_HANDLER, + ZEND_PRINT_SPEC_TMP_HANDLER, + ZEND_PRINT_SPEC_TMP_HANDLER, + ZEND_PRINT_SPEC_TMP_HANDLER, + ZEND_PRINT_SPEC_TMP_HANDLER, + ZEND_PRINT_SPEC_TMP_HANDLER, + ZEND_PRINT_SPEC_VAR_HANDLER, + ZEND_PRINT_SPEC_VAR_HANDLER, + ZEND_PRINT_SPEC_VAR_HANDLER, + ZEND_PRINT_SPEC_VAR_HANDLER, + ZEND_PRINT_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRINT_SPEC_CV_HANDLER, + ZEND_PRINT_SPEC_CV_HANDLER, + ZEND_PRINT_SPEC_CV_HANDLER, + ZEND_PRINT_SPEC_CV_HANDLER, + ZEND_PRINT_SPEC_CV_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMP_SPEC_HANDLER, + ZEND_JMPZ_SPEC_CONST_HANDLER, + ZEND_JMPZ_SPEC_CONST_HANDLER, + ZEND_JMPZ_SPEC_CONST_HANDLER, + ZEND_JMPZ_SPEC_CONST_HANDLER, + ZEND_JMPZ_SPEC_CONST_HANDLER, + ZEND_JMPZ_SPEC_TMP_HANDLER, + ZEND_JMPZ_SPEC_TMP_HANDLER, + ZEND_JMPZ_SPEC_TMP_HANDLER, + ZEND_JMPZ_SPEC_TMP_HANDLER, + ZEND_JMPZ_SPEC_TMP_HANDLER, + ZEND_JMPZ_SPEC_VAR_HANDLER, + ZEND_JMPZ_SPEC_VAR_HANDLER, + ZEND_JMPZ_SPEC_VAR_HANDLER, + ZEND_JMPZ_SPEC_VAR_HANDLER, + ZEND_JMPZ_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMPZ_SPEC_CV_HANDLER, + ZEND_JMPZ_SPEC_CV_HANDLER, + ZEND_JMPZ_SPEC_CV_HANDLER, + ZEND_JMPZ_SPEC_CV_HANDLER, + ZEND_JMPZ_SPEC_CV_HANDLER, + ZEND_JMPNZ_SPEC_CONST_HANDLER, + ZEND_JMPNZ_SPEC_CONST_HANDLER, + ZEND_JMPNZ_SPEC_CONST_HANDLER, + ZEND_JMPNZ_SPEC_CONST_HANDLER, + ZEND_JMPNZ_SPEC_CONST_HANDLER, + ZEND_JMPNZ_SPEC_TMP_HANDLER, + ZEND_JMPNZ_SPEC_TMP_HANDLER, + ZEND_JMPNZ_SPEC_TMP_HANDLER, + ZEND_JMPNZ_SPEC_TMP_HANDLER, + ZEND_JMPNZ_SPEC_TMP_HANDLER, + ZEND_JMPNZ_SPEC_VAR_HANDLER, + ZEND_JMPNZ_SPEC_VAR_HANDLER, + ZEND_JMPNZ_SPEC_VAR_HANDLER, + ZEND_JMPNZ_SPEC_VAR_HANDLER, + ZEND_JMPNZ_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMPNZ_SPEC_CV_HANDLER, + ZEND_JMPNZ_SPEC_CV_HANDLER, + ZEND_JMPNZ_SPEC_CV_HANDLER, + ZEND_JMPNZ_SPEC_CV_HANDLER, + ZEND_JMPNZ_SPEC_CV_HANDLER, + ZEND_JMPZNZ_SPEC_CONST_HANDLER, + ZEND_JMPZNZ_SPEC_CONST_HANDLER, + ZEND_JMPZNZ_SPEC_CONST_HANDLER, + ZEND_JMPZNZ_SPEC_CONST_HANDLER, + ZEND_JMPZNZ_SPEC_CONST_HANDLER, + ZEND_JMPZNZ_SPEC_TMP_HANDLER, + ZEND_JMPZNZ_SPEC_TMP_HANDLER, + ZEND_JMPZNZ_SPEC_TMP_HANDLER, + ZEND_JMPZNZ_SPEC_TMP_HANDLER, + ZEND_JMPZNZ_SPEC_TMP_HANDLER, + ZEND_JMPZNZ_SPEC_VAR_HANDLER, + ZEND_JMPZNZ_SPEC_VAR_HANDLER, + ZEND_JMPZNZ_SPEC_VAR_HANDLER, + ZEND_JMPZNZ_SPEC_VAR_HANDLER, + ZEND_JMPZNZ_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMPZNZ_SPEC_CV_HANDLER, + ZEND_JMPZNZ_SPEC_CV_HANDLER, + ZEND_JMPZNZ_SPEC_CV_HANDLER, + ZEND_JMPZNZ_SPEC_CV_HANDLER, + ZEND_JMPZNZ_SPEC_CV_HANDLER, + ZEND_JMPZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPZ_EX_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMPZ_EX_SPEC_CV_HANDLER, + ZEND_JMPZ_EX_SPEC_CV_HANDLER, + ZEND_JMPZ_EX_SPEC_CV_HANDLER, + ZEND_JMPZ_EX_SPEC_CV_HANDLER, + ZEND_JMPZ_EX_SPEC_CV_HANDLER, + ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPNZ_EX_SPEC_CONST_HANDLER, + ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPNZ_EX_SPEC_TMP_HANDLER, + ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, + ZEND_JMPNZ_EX_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMPNZ_EX_SPEC_CV_HANDLER, + ZEND_JMPNZ_EX_SPEC_CV_HANDLER, + ZEND_JMPNZ_EX_SPEC_CV_HANDLER, + ZEND_JMPNZ_EX_SPEC_CV_HANDLER, + ZEND_JMPNZ_EX_SPEC_CV_HANDLER, + ZEND_CASE_SPEC_CONST_CONST_HANDLER, + ZEND_CASE_SPEC_CONST_TMP_HANDLER, + ZEND_CASE_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CASE_SPEC_CONST_CV_HANDLER, + ZEND_CASE_SPEC_TMP_CONST_HANDLER, + ZEND_CASE_SPEC_TMP_TMP_HANDLER, + ZEND_CASE_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CASE_SPEC_TMP_CV_HANDLER, + ZEND_CASE_SPEC_VAR_CONST_HANDLER, + ZEND_CASE_SPEC_VAR_TMP_HANDLER, + ZEND_CASE_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CASE_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CASE_SPEC_CV_CONST_HANDLER, + ZEND_CASE_SPEC_CV_TMP_HANDLER, + ZEND_CASE_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CASE_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, + ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, + ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, + ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, + ZEND_SWITCH_FREE_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BRK_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BRK_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BRK_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BRK_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BRK_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CONT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_SPEC_CONST_HANDLER, + ZEND_BOOL_SPEC_CONST_HANDLER, + ZEND_BOOL_SPEC_CONST_HANDLER, + ZEND_BOOL_SPEC_CONST_HANDLER, + ZEND_BOOL_SPEC_CONST_HANDLER, + ZEND_BOOL_SPEC_TMP_HANDLER, + ZEND_BOOL_SPEC_TMP_HANDLER, + ZEND_BOOL_SPEC_TMP_HANDLER, + ZEND_BOOL_SPEC_TMP_HANDLER, + ZEND_BOOL_SPEC_TMP_HANDLER, + ZEND_BOOL_SPEC_VAR_HANDLER, + ZEND_BOOL_SPEC_VAR_HANDLER, + ZEND_BOOL_SPEC_VAR_HANDLER, + ZEND_BOOL_SPEC_VAR_HANDLER, + ZEND_BOOL_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BOOL_SPEC_CV_HANDLER, + ZEND_BOOL_SPEC_CV_HANDLER, + ZEND_BOOL_SPEC_CV_HANDLER, + ZEND_BOOL_SPEC_CV_HANDLER, + ZEND_BOOL_SPEC_CV_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_INIT_STRING_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_CHAR_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_CHAR_SPEC_UNUSED_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_STRING_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_STRING_SPEC_UNUSED_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_VAR_SPEC_TMP_TMP_HANDLER, + ZEND_ADD_VAR_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_VAR_SPEC_TMP_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_VAR_SPEC_UNUSED_TMP_HANDLER, + ZEND_ADD_VAR_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_VAR_SPEC_UNUSED_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_BEGIN_SILENCE_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_END_SILENCE_SPEC_TMP_HANDLER, + ZEND_END_SILENCE_SPEC_TMP_HANDLER, + ZEND_END_SILENCE_SPEC_TMP_HANDLER, + ZEND_END_SILENCE_SPEC_TMP_HANDLER, + ZEND_END_SILENCE_SPEC_TMP_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_TMP_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_FCALL_BY_NAME_SPEC_CV_HANDLER, + ZEND_DO_FCALL_SPEC_CONST_HANDLER, + ZEND_DO_FCALL_SPEC_CONST_HANDLER, + ZEND_DO_FCALL_SPEC_CONST_HANDLER, + ZEND_DO_FCALL_SPEC_CONST_HANDLER, + ZEND_DO_FCALL_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER, + ZEND_RETURN_SPEC_CONST_HANDLER, + ZEND_RETURN_SPEC_CONST_HANDLER, + ZEND_RETURN_SPEC_CONST_HANDLER, + ZEND_RETURN_SPEC_CONST_HANDLER, + ZEND_RETURN_SPEC_CONST_HANDLER, + ZEND_RETURN_SPEC_TMP_HANDLER, + ZEND_RETURN_SPEC_TMP_HANDLER, + ZEND_RETURN_SPEC_TMP_HANDLER, + ZEND_RETURN_SPEC_TMP_HANDLER, + ZEND_RETURN_SPEC_TMP_HANDLER, + ZEND_RETURN_SPEC_VAR_HANDLER, + ZEND_RETURN_SPEC_VAR_HANDLER, + ZEND_RETURN_SPEC_VAR_HANDLER, + ZEND_RETURN_SPEC_VAR_HANDLER, + ZEND_RETURN_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_RETURN_SPEC_CV_HANDLER, + ZEND_RETURN_SPEC_CV_HANDLER, + ZEND_RETURN_SPEC_CV_HANDLER, + ZEND_RETURN_SPEC_CV_HANDLER, + ZEND_RETURN_SPEC_CV_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_SPEC_HANDLER, + ZEND_RECV_INIT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_RECV_INIT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_RECV_INIT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_RECV_INIT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_RECV_INIT_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_VAL_SPEC_CONST_HANDLER, + ZEND_SEND_VAL_SPEC_CONST_HANDLER, + ZEND_SEND_VAL_SPEC_CONST_HANDLER, + ZEND_SEND_VAL_SPEC_CONST_HANDLER, + ZEND_SEND_VAL_SPEC_CONST_HANDLER, + ZEND_SEND_VAL_SPEC_TMP_HANDLER, + ZEND_SEND_VAL_SPEC_TMP_HANDLER, + ZEND_SEND_VAL_SPEC_TMP_HANDLER, + ZEND_SEND_VAL_SPEC_TMP_HANDLER, + ZEND_SEND_VAL_SPEC_TMP_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_VAR_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_VAR_SPEC_CV_HANDLER, + ZEND_SEND_VAR_SPEC_CV_HANDLER, + ZEND_SEND_VAR_SPEC_CV_HANDLER, + ZEND_SEND_VAR_SPEC_CV_HANDLER, + ZEND_SEND_VAR_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_REF_SPEC_VAR_HANDLER, + ZEND_SEND_REF_SPEC_VAR_HANDLER, + ZEND_SEND_REF_SPEC_VAR_HANDLER, + ZEND_SEND_REF_SPEC_VAR_HANDLER, + ZEND_SEND_REF_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_REF_SPEC_CV_HANDLER, + ZEND_SEND_REF_SPEC_CV_HANDLER, + ZEND_SEND_REF_SPEC_CV_HANDLER, + ZEND_SEND_REF_SPEC_CV_HANDLER, + ZEND_SEND_REF_SPEC_CV_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_NEW_SPEC_HANDLER, + ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_NS_FCALL_BY_NAME_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FREE_SPEC_TMP_HANDLER, + ZEND_FREE_SPEC_TMP_HANDLER, + ZEND_FREE_SPEC_TMP_HANDLER, + ZEND_FREE_SPEC_TMP_HANDLER, + ZEND_FREE_SPEC_TMP_HANDLER, + ZEND_FREE_SPEC_VAR_HANDLER, + ZEND_FREE_SPEC_VAR_HANDLER, + ZEND_FREE_SPEC_VAR_HANDLER, + ZEND_FREE_SPEC_VAR_HANDLER, + ZEND_FREE_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_ARRAY_SPEC_CONST_CONST_HANDLER, + ZEND_INIT_ARRAY_SPEC_CONST_TMP_HANDLER, + ZEND_INIT_ARRAY_SPEC_CONST_VAR_HANDLER, + ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER, + ZEND_INIT_ARRAY_SPEC_CONST_CV_HANDLER, + ZEND_INIT_ARRAY_SPEC_TMP_CONST_HANDLER, + ZEND_INIT_ARRAY_SPEC_TMP_TMP_HANDLER, + ZEND_INIT_ARRAY_SPEC_TMP_VAR_HANDLER, + ZEND_INIT_ARRAY_SPEC_TMP_UNUSED_HANDLER, + ZEND_INIT_ARRAY_SPEC_TMP_CV_HANDLER, + ZEND_INIT_ARRAY_SPEC_VAR_CONST_HANDLER, + ZEND_INIT_ARRAY_SPEC_VAR_TMP_HANDLER, + ZEND_INIT_ARRAY_SPEC_VAR_VAR_HANDLER, + ZEND_INIT_ARRAY_SPEC_VAR_UNUSED_HANDLER, + ZEND_INIT_ARRAY_SPEC_VAR_CV_HANDLER, + ZEND_INIT_ARRAY_SPEC_UNUSED_CONST_HANDLER, + ZEND_INIT_ARRAY_SPEC_UNUSED_TMP_HANDLER, + ZEND_INIT_ARRAY_SPEC_UNUSED_VAR_HANDLER, + ZEND_INIT_ARRAY_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_INIT_ARRAY_SPEC_UNUSED_CV_HANDLER, + ZEND_INIT_ARRAY_SPEC_CV_CONST_HANDLER, + ZEND_INIT_ARRAY_SPEC_CV_TMP_HANDLER, + ZEND_INIT_ARRAY_SPEC_CV_VAR_HANDLER, + ZEND_INIT_ARRAY_SPEC_CV_UNUSED_HANDLER, + ZEND_INIT_ARRAY_SPEC_CV_CV_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CONST_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_TMP_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_VAR_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_CV_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CONST_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_TMP_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_VAR_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_UNUSED_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_TMP_CV_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CONST_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_TMP_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_VAR_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_UNUSED_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CONST_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_TMP_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_VAR_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_UNUSED_HANDLER, + ZEND_ADD_ARRAY_ELEMENT_SPEC_CV_CV_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CONST_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_TMP_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, + ZEND_INCLUDE_OR_EVAL_SPEC_CV_HANDLER, + ZEND_UNSET_VAR_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_CONST_VAR_HANDLER, + ZEND_UNSET_VAR_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_TMP_VAR_HANDLER, + ZEND_UNSET_VAR_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_VAR_VAR_HANDLER, + ZEND_UNSET_VAR_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_VAR_SPEC_CV_VAR_HANDLER, + ZEND_UNSET_VAR_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_DIM_SPEC_VAR_CONST_HANDLER, + ZEND_UNSET_DIM_SPEC_VAR_TMP_HANDLER, + ZEND_UNSET_DIM_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_DIM_SPEC_VAR_CV_HANDLER, + ZEND_UNSET_DIM_SPEC_UNUSED_CONST_HANDLER, + ZEND_UNSET_DIM_SPEC_UNUSED_TMP_HANDLER, + ZEND_UNSET_DIM_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_DIM_SPEC_UNUSED_CV_HANDLER, + ZEND_UNSET_DIM_SPEC_CV_CONST_HANDLER, + ZEND_UNSET_DIM_SPEC_CV_TMP_HANDLER, + ZEND_UNSET_DIM_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_DIM_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_UNSET_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_UNSET_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_UNSET_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_UNSET_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_UNSET_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_UNSET_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_UNSET_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_UNSET_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_UNSET_OBJ_SPEC_CV_CV_HANDLER, + ZEND_FE_RESET_SPEC_CONST_HANDLER, + ZEND_FE_RESET_SPEC_CONST_HANDLER, + ZEND_FE_RESET_SPEC_CONST_HANDLER, + ZEND_FE_RESET_SPEC_CONST_HANDLER, + ZEND_FE_RESET_SPEC_CONST_HANDLER, + ZEND_FE_RESET_SPEC_TMP_HANDLER, + ZEND_FE_RESET_SPEC_TMP_HANDLER, + ZEND_FE_RESET_SPEC_TMP_HANDLER, + ZEND_FE_RESET_SPEC_TMP_HANDLER, + ZEND_FE_RESET_SPEC_TMP_HANDLER, + ZEND_FE_RESET_SPEC_VAR_HANDLER, + ZEND_FE_RESET_SPEC_VAR_HANDLER, + ZEND_FE_RESET_SPEC_VAR_HANDLER, + ZEND_FE_RESET_SPEC_VAR_HANDLER, + ZEND_FE_RESET_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FE_RESET_SPEC_CV_HANDLER, + ZEND_FE_RESET_SPEC_CV_HANDLER, + ZEND_FE_RESET_SPEC_CV_HANDLER, + ZEND_FE_RESET_SPEC_CV_HANDLER, + ZEND_FE_RESET_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FE_FETCH_SPEC_VAR_HANDLER, + ZEND_FE_FETCH_SPEC_VAR_HANDLER, + ZEND_FE_FETCH_SPEC_VAR_HANDLER, + ZEND_FE_FETCH_SPEC_VAR_HANDLER, + ZEND_FE_FETCH_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_EXIT_SPEC_CONST_HANDLER, + ZEND_EXIT_SPEC_CONST_HANDLER, + ZEND_EXIT_SPEC_CONST_HANDLER, + ZEND_EXIT_SPEC_CONST_HANDLER, + ZEND_EXIT_SPEC_CONST_HANDLER, + ZEND_EXIT_SPEC_TMP_HANDLER, + ZEND_EXIT_SPEC_TMP_HANDLER, + ZEND_EXIT_SPEC_TMP_HANDLER, + ZEND_EXIT_SPEC_TMP_HANDLER, + ZEND_EXIT_SPEC_TMP_HANDLER, + ZEND_EXIT_SPEC_VAR_HANDLER, + ZEND_EXIT_SPEC_VAR_HANDLER, + ZEND_EXIT_SPEC_VAR_HANDLER, + ZEND_EXIT_SPEC_VAR_HANDLER, + ZEND_EXIT_SPEC_VAR_HANDLER, + ZEND_EXIT_SPEC_UNUSED_HANDLER, + ZEND_EXIT_SPEC_UNUSED_HANDLER, + ZEND_EXIT_SPEC_UNUSED_HANDLER, + ZEND_EXIT_SPEC_UNUSED_HANDLER, + ZEND_EXIT_SPEC_UNUSED_HANDLER, + ZEND_EXIT_SPEC_CV_HANDLER, + ZEND_EXIT_SPEC_CV_HANDLER, + ZEND_EXIT_SPEC_CV_HANDLER, + ZEND_EXIT_SPEC_CV_HANDLER, + ZEND_EXIT_SPEC_CV_HANDLER, + ZEND_FETCH_R_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_CONST_VAR_HANDLER, + ZEND_FETCH_R_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_TMP_VAR_HANDLER, + ZEND_FETCH_R_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_R_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_R_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_R_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CONST_CONST_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CONST_TMP_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CONST_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CONST_CV_HANDLER, + ZEND_FETCH_DIM_R_SPEC_TMP_CONST_HANDLER, + ZEND_FETCH_DIM_R_SPEC_TMP_TMP_HANDLER, + ZEND_FETCH_DIM_R_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_R_SPEC_TMP_CV_HANDLER, + ZEND_FETCH_DIM_R_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_DIM_R_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_DIM_R_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_R_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_R_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_VAR_CV_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_UNUSED_CONST_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_UNUSED_TMP_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_UNUSED_CV_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_R_SPEC_CV_CV_HANDLER, + ZEND_FETCH_W_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_CONST_VAR_HANDLER, + ZEND_FETCH_W_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_TMP_VAR_HANDLER, + ZEND_FETCH_W_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_W_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_W_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_W_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_W_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_DIM_W_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_DIM_W_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_DIM_W_SPEC_VAR_UNUSED_HANDLER, + ZEND_FETCH_DIM_W_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_W_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_DIM_W_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_DIM_W_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_DIM_W_SPEC_CV_UNUSED_HANDLER, + ZEND_FETCH_DIM_W_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_VAR_CV_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_UNUSED_CONST_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_UNUSED_TMP_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_UNUSED_CV_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_W_SPEC_CV_CV_HANDLER, + ZEND_FETCH_RW_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_CONST_VAR_HANDLER, + ZEND_FETCH_RW_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_TMP_VAR_HANDLER, + ZEND_FETCH_RW_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_RW_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_RW_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_RW_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_VAR_UNUSED_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_CV_UNUSED_HANDLER, + ZEND_FETCH_DIM_RW_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_VAR_CV_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CONST_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_UNUSED_TMP_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_UNUSED_CV_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_RW_SPEC_CV_CV_HANDLER, + ZEND_FETCH_IS_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_CONST_VAR_HANDLER, + ZEND_FETCH_IS_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_TMP_VAR_HANDLER, + ZEND_FETCH_IS_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_IS_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_IS_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_IS_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_VAR_CV_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CONST_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_UNUSED_TMP_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_UNUSED_CV_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_IS_SPEC_CV_CV_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_CONST_VAR_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_TMP_VAR_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_FUNC_ARG_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_UNUSED_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_UNUSED_HANDLER, + ZEND_FETCH_DIM_FUNC_ARG_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_CV_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CONST_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_TMP_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_UNUSED_CV_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_FUNC_ARG_SPEC_CV_CV_HANDLER, + ZEND_FETCH_UNSET_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_CONST_VAR_HANDLER, + ZEND_FETCH_UNSET_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_TMP_VAR_HANDLER, + ZEND_FETCH_UNSET_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_VAR_VAR_HANDLER, + ZEND_FETCH_UNSET_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_UNSET_SPEC_CV_VAR_HANDLER, + ZEND_FETCH_UNSET_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_UNSET_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CONST_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_VAR_TMP_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_VAR_CV_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CONST_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_TMP_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_UNUSED_CV_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_CV_CONST_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_CV_TMP_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_OBJ_UNSET_SPEC_CV_CV_HANDLER, + ZEND_FETCH_DIM_TMP_VAR_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_DIM_TMP_VAR_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_GOTO_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_GOTO_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_GOTO_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_GOTO_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_GOTO_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_STMT_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_BEGIN_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_FCALL_END_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_EXT_NOP_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_TICKS_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, + ZEND_SEND_VAR_NO_REF_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_CATCH_SPEC_CONST_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_THROW_SPEC_CONST_HANDLER, + ZEND_THROW_SPEC_CONST_HANDLER, + ZEND_THROW_SPEC_CONST_HANDLER, + ZEND_THROW_SPEC_CONST_HANDLER, + ZEND_THROW_SPEC_CONST_HANDLER, + ZEND_THROW_SPEC_TMP_HANDLER, + ZEND_THROW_SPEC_TMP_HANDLER, + ZEND_THROW_SPEC_TMP_HANDLER, + ZEND_THROW_SPEC_TMP_HANDLER, + ZEND_THROW_SPEC_TMP_HANDLER, + ZEND_THROW_SPEC_VAR_HANDLER, + ZEND_THROW_SPEC_VAR_HANDLER, + ZEND_THROW_SPEC_VAR_HANDLER, + ZEND_THROW_SPEC_VAR_HANDLER, + ZEND_THROW_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_THROW_SPEC_CV_HANDLER, + ZEND_THROW_SPEC_CV_HANDLER, + ZEND_THROW_SPEC_CV_HANDLER, + ZEND_THROW_SPEC_CV_HANDLER, + ZEND_THROW_SPEC_CV_HANDLER, + ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, + ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, + ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, + ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, + ZEND_FETCH_CLASS_SPEC_CV_HANDLER, + ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, + ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, + ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, + ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, + ZEND_FETCH_CLASS_SPEC_CV_HANDLER, + ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, + ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, + ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, + ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, + ZEND_FETCH_CLASS_SPEC_CV_HANDLER, + ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, + ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, + ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, + ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, + ZEND_FETCH_CLASS_SPEC_CV_HANDLER, + ZEND_FETCH_CLASS_SPEC_CONST_HANDLER, + ZEND_FETCH_CLASS_SPEC_TMP_HANDLER, + ZEND_FETCH_CLASS_SPEC_VAR_HANDLER, + ZEND_FETCH_CLASS_SPEC_UNUSED_HANDLER, + ZEND_FETCH_CLASS_SPEC_CV_HANDLER, + ZEND_CLONE_SPEC_CONST_HANDLER, + ZEND_CLONE_SPEC_CONST_HANDLER, + ZEND_CLONE_SPEC_CONST_HANDLER, + ZEND_CLONE_SPEC_CONST_HANDLER, + ZEND_CLONE_SPEC_CONST_HANDLER, + ZEND_CLONE_SPEC_TMP_HANDLER, + ZEND_CLONE_SPEC_TMP_HANDLER, + ZEND_CLONE_SPEC_TMP_HANDLER, + ZEND_CLONE_SPEC_TMP_HANDLER, + ZEND_CLONE_SPEC_TMP_HANDLER, + ZEND_CLONE_SPEC_VAR_HANDLER, + ZEND_CLONE_SPEC_VAR_HANDLER, + ZEND_CLONE_SPEC_VAR_HANDLER, + ZEND_CLONE_SPEC_VAR_HANDLER, + ZEND_CLONE_SPEC_VAR_HANDLER, + ZEND_CLONE_SPEC_UNUSED_HANDLER, + ZEND_CLONE_SPEC_UNUSED_HANDLER, + ZEND_CLONE_SPEC_UNUSED_HANDLER, + ZEND_CLONE_SPEC_UNUSED_HANDLER, + ZEND_CLONE_SPEC_UNUSED_HANDLER, + ZEND_CLONE_SPEC_CV_HANDLER, + ZEND_CLONE_SPEC_CV_HANDLER, + ZEND_CLONE_SPEC_CV_HANDLER, + ZEND_CLONE_SPEC_CV_HANDLER, + ZEND_CLONE_SPEC_CV_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CONST_HANDLER, + ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, + ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, + ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, + ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, + ZEND_RETURN_BY_REF_SPEC_TMP_HANDLER, + ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, + ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, + ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, + ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, + ZEND_RETURN_BY_REF_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, + ZEND_RETURN_BY_REF_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_TMP_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_VAR_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_UNUSED_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CONST_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_TMP_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_VAR_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_UNUSED_HANDLER, + ZEND_INIT_STATIC_METHOD_CALL_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_VAR_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_VAR_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_TMP_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_VAR_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_VAR_HANDLER, + ZEND_ISSET_ISEMPTY_VAR_SPEC_CV_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_DIM_OBJ_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_INC_OBJ_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_PRE_DEC_OBJ_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_INC_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_POST_INC_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_POST_INC_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_INC_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_POST_INC_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_POST_INC_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_POST_INC_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_INC_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_POST_INC_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_POST_INC_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_POST_INC_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_INC_OBJ_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_POST_DEC_OBJ_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_OBJ_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INSTANCEOF_SPEC_TMP_HANDLER, + ZEND_INSTANCEOF_SPEC_TMP_HANDLER, + ZEND_INSTANCEOF_SPEC_TMP_HANDLER, + ZEND_INSTANCEOF_SPEC_TMP_HANDLER, + ZEND_INSTANCEOF_SPEC_TMP_HANDLER, + ZEND_INSTANCEOF_SPEC_VAR_HANDLER, + ZEND_INSTANCEOF_SPEC_VAR_HANDLER, + ZEND_INSTANCEOF_SPEC_VAR_HANDLER, + ZEND_INSTANCEOF_SPEC_VAR_HANDLER, + ZEND_INSTANCEOF_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_INSTANCEOF_SPEC_CV_HANDLER, + ZEND_INSTANCEOF_SPEC_CV_HANDLER, + ZEND_INSTANCEOF_SPEC_CV_HANDLER, + ZEND_INSTANCEOF_SPEC_CV_HANDLER, + ZEND_INSTANCEOF_SPEC_CV_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_DECLARE_FUNCTION_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_RAISE_ABSTRACT_ERROR_SPEC_HANDLER, + ZEND_DECLARE_CONST_SPEC_CONST_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_INTERFACE_SPEC_CONST_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_DECLARE_INHERITED_CLASS_DELAYED_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_VERIFY_ABSTRACT_CLASS_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_DIM_SPEC_VAR_CONST_HANDLER, + ZEND_ASSIGN_DIM_SPEC_VAR_TMP_HANDLER, + ZEND_ASSIGN_DIM_SPEC_VAR_VAR_HANDLER, + ZEND_ASSIGN_DIM_SPEC_VAR_UNUSED_HANDLER, + ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ASSIGN_DIM_SPEC_CV_CONST_HANDLER, + ZEND_ASSIGN_DIM_SPEC_CV_TMP_HANDLER, + ZEND_ASSIGN_DIM_SPEC_CV_VAR_HANDLER, + ZEND_ASSIGN_DIM_SPEC_CV_UNUSED_HANDLER, + ZEND_ASSIGN_DIM_SPEC_CV_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CONST_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_TMP_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_VAR_CV_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CONST_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_TMP_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_UNUSED_CV_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CONST_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_TMP_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ISSET_ISEMPTY_PROP_OBJ_SPEC_CV_CV_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_HANDLE_EXCEPTION_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_USER_OPCODE_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMP_SET_SPEC_CONST_HANDLER, + ZEND_JMP_SET_SPEC_CONST_HANDLER, + ZEND_JMP_SET_SPEC_CONST_HANDLER, + ZEND_JMP_SET_SPEC_CONST_HANDLER, + ZEND_JMP_SET_SPEC_CONST_HANDLER, + ZEND_JMP_SET_SPEC_TMP_HANDLER, + ZEND_JMP_SET_SPEC_TMP_HANDLER, + ZEND_JMP_SET_SPEC_TMP_HANDLER, + ZEND_JMP_SET_SPEC_TMP_HANDLER, + ZEND_JMP_SET_SPEC_TMP_HANDLER, + ZEND_JMP_SET_SPEC_VAR_HANDLER, + ZEND_JMP_SET_SPEC_VAR_HANDLER, + ZEND_JMP_SET_SPEC_VAR_HANDLER, + ZEND_JMP_SET_SPEC_VAR_HANDLER, + ZEND_JMP_SET_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMP_SET_SPEC_CV_HANDLER, + ZEND_JMP_SET_SPEC_CV_HANDLER, + ZEND_JMP_SET_SPEC_CV_HANDLER, + ZEND_JMP_SET_SPEC_CV_HANDLER, + ZEND_JMP_SET_SPEC_CV_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_DECLARE_LAMBDA_FUNCTION_SPEC_CONST_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_ADD_TRAIT_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_BIND_TRAITS_SPEC_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_SEPARATE_SPEC_VAR_UNUSED_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CONST_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_TMP_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, + ZEND_QM_ASSIGN_VAR_SPEC_CV_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CONST_HANDLER, + ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, + ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, + ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, + ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, + ZEND_JMP_SET_VAR_SPEC_TMP_HANDLER, + ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, + ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, + ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, + ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, + ZEND_JMP_SET_VAR_SPEC_VAR_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_NULL_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, + ZEND_JMP_SET_VAR_SPEC_CV_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_DISCARD_EXCEPTION_SPEC_HANDLER, + ZEND_YIELD_SPEC_CONST_CONST_HANDLER, + ZEND_YIELD_SPEC_CONST_TMP_HANDLER, + ZEND_YIELD_SPEC_CONST_VAR_HANDLER, + ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER, + ZEND_YIELD_SPEC_CONST_CV_HANDLER, + ZEND_YIELD_SPEC_TMP_CONST_HANDLER, + ZEND_YIELD_SPEC_TMP_TMP_HANDLER, + ZEND_YIELD_SPEC_TMP_VAR_HANDLER, + ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER, + ZEND_YIELD_SPEC_TMP_CV_HANDLER, + ZEND_YIELD_SPEC_VAR_CONST_HANDLER, + ZEND_YIELD_SPEC_VAR_TMP_HANDLER, + ZEND_YIELD_SPEC_VAR_VAR_HANDLER, + ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER, + ZEND_YIELD_SPEC_VAR_CV_HANDLER, + ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER, + ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER, + ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER, + ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER, + ZEND_YIELD_SPEC_UNUSED_CV_HANDLER, + ZEND_YIELD_SPEC_CV_CONST_HANDLER, + ZEND_YIELD_SPEC_CV_TMP_HANDLER, + ZEND_YIELD_SPEC_CV_VAR_HANDLER, + ZEND_YIELD_SPEC_CV_UNUSED_HANDLER, + ZEND_YIELD_SPEC_CV_CV_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_GENERATOR_RETURN_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_CALL_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_FAST_RET_SPEC_HANDLER, + ZEND_NULL_HANDLER }; zend_opcode_handlers = (opcode_handler_t*)labels; } @@ -44957,210 +44962,8 @@ ZEND_API void zend_vm_set_opcode_handler(zend_op* op) op->handler = zend_vm_get_opcode_handler(zend_user_opcodes[op->opcode], op); } -#undef OPLINE -#undef DCL_OPLINE -#undef USE_OPLINE -#undef LOAD_OPLINE -#undef SAVE_OPLINE -#define OPLINE EX(opline) -#define DCL_OPLINE -#define USE_OPLINE zend_op *opline = EX(opline); -#define LOAD_OPLINE() -#define SAVE_OPLINE() -#undef CHECK_EXCEPTION -#undef HANDLE_EXCEPTION -#undef HANDLE_EXCEPTION_LEAVE -#define CHECK_EXCEPTION() LOAD_OPLINE() -#define HANDLE_EXCEPTION() LOAD_OPLINE(); ZEND_VM_CONTINUE() -#define HANDLE_EXCEPTION_LEAVE() LOAD_OPLINE(); ZEND_VM_LEAVE() -#undef ZEND_VM_CONTINUE -#undef ZEND_VM_RETURN -#undef ZEND_VM_ENTER -#undef ZEND_VM_LEAVE -#undef ZEND_VM_DISPATCH -#undef ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL - -#define ZEND_VM_CONTINUE() return 0 -#define ZEND_VM_RETURN() return 1 -#define ZEND_VM_ENTER() return 2 -#define ZEND_VM_LEAVE() return 3 -#define ZEND_VM_DISPATCH(opcode, opline) return zend_vm_get_opcode_handler(opcode, opline)(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); - -#define ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_INTERNAL execute_data TSRMLS_CC - ZEND_API int zend_do_fcall(ZEND_OPCODE_HANDLER_ARGS) { - USE_OPLINE - zend_bool should_change_scope = 0; - zend_function *fbc = EX(function_state).function; - - SAVE_OPLINE(); - EX(object) = EX(call)->object; - if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { - if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { - zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); - } - if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { - zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", - fbc->common.scope ? fbc->common.scope->name : "", - fbc->common.scope ? "::" : "", - fbc->common.function_name); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } - } - } - if (fbc->common.scope && - !(fbc->common.fn_flags & ZEND_ACC_STATIC) && - !EX(object)) { - - if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - /* FIXME: output identifiers properly */ - zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); - if (UNEXPECTED(EG(exception) != NULL)) { - HANDLE_EXCEPTION(); - } - } else { - /* FIXME: output identifiers properly */ - /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ - zend_error_noreturn(E_ERROR, "Non-static method %s::%s() cannot be called statically", fbc->common.scope->name, fbc->common.function_name); - } - } - - if (fbc->type == ZEND_USER_FUNCTION || fbc->common.scope) { - should_change_scope = 1; - EX(current_this) = EG(This); - EX(current_scope) = EG(scope); - EX(current_called_scope) = EG(called_scope); - EG(This) = EX(object); - EG(scope) = (fbc->type == ZEND_USER_FUNCTION || !EX(object)) ? fbc->common.scope : NULL; - EG(called_scope) = EX(call)->called_scope; - } - - EX(function_state).arguments = zend_vm_stack_top(TSRMLS_C); - zend_vm_stack_push((void*)(zend_uintptr_t)opline->extended_value TSRMLS_CC); - LOAD_OPLINE(); - - if (fbc->type == ZEND_INTERNAL_FUNCTION) { - temp_variable *ret = &EX_T(opline->result.var); - - MAKE_STD_ZVAL(ret->var.ptr); - ZVAL_NULL(ret->var.ptr); - ret->var.ptr_ptr = &ret->var.ptr; - ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; - - if (fbc->common.arg_info) { - zend_uint i=0; - zval **p = (zval**)EX(function_state).arguments; - ulong arg_count = opline->extended_value; - - while (arg_count>0) { - zend_verify_arg_type(fbc, ++i, *(p-arg_count), 0 TSRMLS_CC); - arg_count--; - } - } - - if (!zend_execute_internal) { - /* saves one function call if zend_execute_internal is not used */ - fbc->internal_function.handler(opline->extended_value, ret->var.ptr, (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) ? &ret->var.ptr : NULL, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); - } else { - zend_execute_internal(execute_data, NULL, RETURN_VALUE_USED(opline) TSRMLS_CC); - } - - if (!RETURN_VALUE_USED(opline)) { - zval_ptr_dtor(&ret->var.ptr); - } - } else if (fbc->type == ZEND_USER_FUNCTION) { - EX(original_return_value) = EG(return_value_ptr_ptr); - EG(active_symbol_table) = NULL; - EG(active_op_array) = &fbc->op_array; - EG(return_value_ptr_ptr) = NULL; - if (RETURN_VALUE_USED(opline)) { - temp_variable *ret = &EX_T(opline->result.var); - - ret->var.ptr = NULL; - EG(return_value_ptr_ptr) = &ret->var.ptr; - ret->var.ptr_ptr = &ret->var.ptr; - ret->var.fcall_returned_reference = (fbc->common.fn_flags & ZEND_ACC_RETURN_REFERENCE) != 0; - } - - if (UNEXPECTED((EG(active_op_array)->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - if (RETURN_VALUE_USED(opline)) { - EX_T(opline->result.var).var.ptr = zend_generator_create_zval(EG(active_op_array) TSRMLS_CC); - } - } else if (EXPECTED(zend_execute_ex == execute_ex)) { - if (EXPECTED(EG(exception) == NULL)) { - ZEND_VM_ENTER(); - } - } else { - zend_execute(EG(active_op_array) TSRMLS_CC); - } - - EG(opline_ptr) = &EX(opline); - EG(active_op_array) = EX(op_array); - EG(return_value_ptr_ptr) = EX(original_return_value); - if (EG(active_symbol_table)) { - zend_clean_and_cache_symbol_table(EG(active_symbol_table) TSRMLS_CC); - } - EG(active_symbol_table) = EX(symbol_table); - } else { /* ZEND_OVERLOADED_FUNCTION */ - MAKE_STD_ZVAL(EX_T(opline->result.var).var.ptr); - ZVAL_NULL(EX_T(opline->result.var).var.ptr); - - /* Not sure what should be done here if it's a static method */ - if (EXPECTED(EX(object) != NULL)) { - Z_OBJ_HT_P(EX(object))->call_method(fbc->common.function_name, opline->extended_value, EX_T(opline->result.var).var.ptr, &EX_T(opline->result.var).var.ptr, EX(object), RETURN_VALUE_USED(opline) TSRMLS_CC); - } else { - zend_error_noreturn(E_ERROR, "Cannot call overloaded function for non-object"); - } - - if (fbc->type == ZEND_OVERLOADED_FUNCTION_TEMPORARY) { - efree((char*)fbc->common.function_name); - } - efree(fbc); - - if (!RETURN_VALUE_USED(opline)) { - zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); - } else { - Z_UNSET_ISREF_P(EX_T(opline->result.var).var.ptr); - Z_SET_REFCOUNT_P(EX_T(opline->result.var).var.ptr, 1); - EX_T(opline->result.var).var.fcall_returned_reference = 0; - EX_T(opline->result.var).var.ptr_ptr = &EX_T(opline->result.var).var.ptr; - } - } - - EX(function_state).function = (zend_function *) EX(op_array); - EX(function_state).arguments = NULL; - - if (should_change_scope) { - if (EG(This)) { - if (UNEXPECTED(EG(exception) != NULL) && EX(call)->is_ctor_call) { - if (EX(call)->is_ctor_result_used) { - Z_DELREF_P(EG(This)); - } - if (Z_REFCOUNT_P(EG(This)) == 1) { - zend_object_store_ctor_failed(EG(This) TSRMLS_CC); - } - } - zval_ptr_dtor(&EG(This)); - } - EG(This) = EX(current_this); - EG(scope) = EX(current_scope); - EG(called_scope) = EX(current_called_scope); - } - - EX(call)--; - - zend_vm_stack_clear_multiple(1 TSRMLS_CC); - - if (UNEXPECTED(EG(exception) != NULL)) { - zend_throw_exception_internal(NULL TSRMLS_CC); - if (RETURN_VALUE_USED(opline) && EX_T(opline->result.var).var.ptr) { - zval_ptr_dtor(&EX_T(opline->result.var).var.ptr); - } - HANDLE_EXCEPTION(); - } - - ZEND_VM_NEXT_OPCODE(); + return zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS_PASSTHRU); } From 210d428f99bd3dff789e9257a4619e930d3c6e45 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 18 Dec 2012 15:34:47 +0800 Subject: [PATCH 2220/2394] ixed bug that exception won't be catched Related failed test Zend/tests/bug35437.phpt (after he latest execute_data improvement, run with non CALL vm kind) --- Zend/zend_vm_def.h | 8 ++++++-- Zend/zend_vm_execute.h | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index f7b10a29a68d9..bfe6f722f317e 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1942,14 +1942,15 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); /* Never reached */ } if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", fbc->common.scope ? fbc->common.scope->name : "", fbc->common.scope ? "::" : "", fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } } if (fbc->common.scope && @@ -1959,6 +1960,9 @@ ZEND_VM_HELPER(zend_do_fcall_common_helper, ANY, ANY) if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { /* FIXME: output identifiers properly */ zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } else { /* FIXME: output identifiers properly */ /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index c077d5d2a5393..420a94acfafbf 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -482,14 +482,15 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR if (UNEXPECTED((fbc->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_DEPRECATED)) != 0)) { if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_ABSTRACT) != 0)) { zend_error_noreturn(E_ERROR, "Cannot call abstract method %s::%s()", fbc->common.scope->name, fbc->common.function_name); - CHECK_EXCEPTION(); - ZEND_VM_NEXT_OPCODE(); /* Never reached */ } if (UNEXPECTED((fbc->common.fn_flags & ZEND_ACC_DEPRECATED) != 0)) { zend_error(E_DEPRECATED, "Function %s%s%s() is deprecated", fbc->common.scope ? fbc->common.scope->name : "", fbc->common.scope ? "::" : "", fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } } if (fbc->common.scope && @@ -499,6 +500,9 @@ static int ZEND_FASTCALL zend_do_fcall_common_helper_SPEC(ZEND_OPCODE_HANDLER_AR if (fbc->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { /* FIXME: output identifiers properly */ zend_error(E_STRICT, "Non-static method %s::%s() should not be called statically", fbc->common.scope->name, fbc->common.function_name); + if (UNEXPECTED(EG(exception) != NULL)) { + HANDLE_EXCEPTION(); + } } else { /* FIXME: output identifiers properly */ /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ From 19f8bba10d3580308bfe19234a5a26a4f71ecd9a Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Sat, 15 Dec 2012 00:08:39 +0100 Subject: [PATCH 2221/2394] News for PHP 5.5.0 Alphas --- NEWS | 60 ++++++++++++++++++++++++++++++++++++------------------------ 1 file changed, 36 insertions(+), 24 deletions(-) diff --git a/NEWS b/NEWS index 40fab8a740b6b..d63858df01716 100644 --- a/NEWS +++ b/NEWS @@ -1,25 +1,16 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 201?, PHP 5.5.0 +?? ??? 201?, PHP 5.5.0 Alpha 3 + + +18 Dec 2012, PHP 5.5.0 Alpha 2 - General improvements: - . Added generators and coroutines (https://wiki.php.net/rfc/generators). - (Nikita Popov) - . Added "finally" keyword (https://wiki.php.net/rfc/finally). (Laruence) - . Added simplified password hashing API - (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) . Added systemtap support by enabling systemtap compatible dtrace probes on linux. (David Soria Parra) - . Added support for list in foreach (https://wiki.php.net/rfc/foreachlist). - (Laruence) . Added support for using empty() on the result of function calls and other expressions (https://wiki.php.net/rfc/empty_isset_exprs). (Nikita Popov) - . Added support for constant array/string dereferencing. (Laruence) - . Improved set_exception_handler while doing reset.(Laruence) - . Removed php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), - zend_logo_guid(). (Adnrew Faulds) - . Dropped support for Windows XP and 2003. (Pierre) . Optimized access to temporary and compiled VM variables. 8% less memory reads. (Dmitry) . The VM stacks for passing function arguments and syntaticaly nested calls @@ -28,6 +19,38 @@ PHP NEWS all the stack push operatins don't require checks for stack overflow any more. (Dmitry) +- MySQL + . This extension is now deprecated, and deprecation warnings will be generated + when connections are established to databases via mysql_connect(), + mysql_pconnect(), or through implicit connection: use MySQLi or PDO_MySQL + instead (https://wiki.php.net/rfc/mysql_deprecation). (Adam) + +- Fileinfo: + . Fixed bug #63590 (Different results in TS and NTS under Windows). + (Anatoliy) + +- Apache2 Handler SAPI: + . Enabled Apache 2.4 configure option for Windows (Pierre, Anatoliy) + +13 Nov 2012, PHP 5.5.0 Alpha 1 + +- General improvements: + . Added generators and coroutines (https://wiki.php.net/rfc/generators). + (Nikita Popov) + . Added "finally" keyword (https://wiki.php.net/rfc/finally). (Laruence) + . Add simplified password hashing API + (https://wiki.php.net/rfc/password_hash). (Anthony Ferrara) + . Added support for list in foreach (https://wiki.php.net/rfc/foreachlist). + (Laruence) + . Added support for using empty() on the result of function calls and + other expressions (https://wiki.php.net/rfc/empty_isset_exprs). + (Nikita Popov) + . Added support for constant array/string dereferencing. (Laruence) + . Improve set_exception_handler while doing reset.(Laruence) + . Remove php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid(), + zend_logo_guid(). (Adnrew Faulds) + . Drop Windows XP and 2003 support. (Pierre) + - Calendar: . Fixed bug #54254 (cal_from_jd returns month = 6 when there is only one Adar) (Stas, Eitan Mosenkis) @@ -163,12 +186,6 @@ PHP NEWS . mcrypt_ecb(), mcrypt_cbc(), mcrypt_cfb() and mcrypt_ofb() now throw E_DEPRECATED. (GoogleGuy) -- MySQL - . This extension is now deprecated, and deprecation warnings will be generated - when connections are established to databases via mysql_connect(), - mysql_pconnect(), or through implicit connection: use MySQLi or PDO_MySQL - instead (https://wiki.php.net/rfc/mysql_deprecation). (Adam) - - MySQLi . Dropped support for LOAD DATA LOCAL INFILE handlers when using libmysql. Known for stability problems. (Andrey) @@ -195,10 +212,5 @@ PHP NEWS - Fileinfo: . Fixed bug #63248 (Load multiple magic files from a directory under Windows). (Anatoliy) - . Fixed bug #63590 (Different results in TS and NTS under Windows). - (Anatoliy) - -- Apache2 Handler SAPI: - . Enabled Apache 2.4 configure option for Windows (Pierre, Anatoliy) <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> From d53f1bf8ab326a6fd3596a5f265d04bf49de74fe Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Tue, 18 Dec 2012 21:36:48 +0100 Subject: [PATCH 2222/2394] Fix leak when generator ignores sent value When the return value of yield wasn't used it was leaked. This is fixed by using a TMP_VAR return value instead of VAR. TMP_VARs are automatically freed when they aren't used. --- Zend/tests/generators/ignored_send_leak.phpt | 17 +++++ Zend/zend_compile.c | 2 +- Zend/zend_generators.c | 11 +-- Zend/zend_vm_def.h | 3 +- Zend/zend_vm_execute.h | 75 +++++++------------- 5 files changed, 47 insertions(+), 61 deletions(-) create mode 100644 Zend/tests/generators/ignored_send_leak.phpt diff --git a/Zend/tests/generators/ignored_send_leak.phpt b/Zend/tests/generators/ignored_send_leak.phpt new file mode 100644 index 0000000000000..352ba406ba495 --- /dev/null +++ b/Zend/tests/generators/ignored_send_leak.phpt @@ -0,0 +1,17 @@ +--TEST-- +Ignoring a sent value shouldn't leak memory +--FILE-- +send(NULL); + +echo "DONE"; + +?> +--EXPECT-- +DONE diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index ac3e633e28bfa..d28b65af67e44 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2736,7 +2736,7 @@ void zend_do_yield(znode *result, znode *value, const znode *key, zend_bool is_v SET_UNUSED(opline->op2); } - opline->result_type = IS_VAR; + opline->result_type = IS_TMP_VAR; opline->result.var = get_temporary_variable(CG(active_op_array)); GET_NODE(result, opline->result); } diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 9eae2c7019349..d4254e090dd8a 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -319,7 +319,7 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** if (orig->send_target) { size_t offset = (char *) orig->send_target - (char *)execute_data; clone->send_target = EX_TMP_VAR(clone->execute_data, offset); - Z_ADDREF_P(clone->send_target->var.ptr); + zval_copy_ctor(&clone->send_target->tmp_var); } if (execute_data->current_this) { @@ -641,13 +641,8 @@ ZEND_METHOD(Generator, send) return; } - /* The sent value was initialized to NULL, so dtor that */ - zval_ptr_dtor(&generator->send_target->var.ptr); - - /* Set new sent value */ - Z_ADDREF_P(value); - generator->send_target->var.ptr = value; - generator->send_target->var.ptr_ptr = &value; + /* Put sent value into the TMP_VAR slot */ + MAKE_COPY_ZVAL(&value, &generator->send_target->tmp_var); zend_generator_resume(generator TSRMLS_CC); diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index f7b10a29a68d9..c933a48248d80 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5371,8 +5371,7 @@ ZEND_VM_HANDLER(160, ZEND_YIELD, CONST|TMP|VAR|CV|UNUSED, CONST|TMP|VAR|CV|UNUSE generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index c077d5d2a5393..dab0df35409f0 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -4183,8 +4183,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CONST_HANDLER(ZEND_OPCODE_HANDLE generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -4879,8 +4878,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_TMP_HANDLER(ZEND_OPCODE_HANDLER_ generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -5901,8 +5899,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_VAR_HANDLER(ZEND_OPCODE_HANDLER_ generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -6616,8 +6613,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_UNUSED_HANDLER(ZEND_OPCODE_HANDL generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -7371,8 +7367,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CONST_CV_HANDLER(ZEND_OPCODE_HANDLER_A generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -9417,8 +9412,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CONST_HANDLER(ZEND_OPCODE_HANDLER_ generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -10113,8 +10107,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -11135,8 +11128,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -11714,8 +11706,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_UNUSED_HANDLER(ZEND_OPCODE_HANDLER generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -12407,8 +12398,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -16315,8 +16305,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -18403,8 +18392,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE_HANDLER_AR generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -20872,8 +20860,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_AR generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -22014,8 +22001,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_UNUSED_HANDLER(ZEND_OPCODE_HANDLER generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -24151,8 +24137,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -25642,8 +25627,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CONST_HANDLER(ZEND_OPCODE_HANDL generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -26957,8 +26941,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_TMP_HANDLER(ZEND_OPCODE_HANDLER generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -28273,8 +28256,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(ZEND_OPCODE_HANDLER generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -28696,8 +28678,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDLER(ZEND_OPCODE_HAND generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -30008,8 +29989,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(ZEND_OPCODE_HANDLER_ generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -33513,8 +33493,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CONST_HANDLER(ZEND_OPCODE_HANDLER_A generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -35468,8 +35447,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -37803,8 +37781,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -38802,8 +38779,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_UNUSED_HANDLER(ZEND_OPCODE_HANDLER_ generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ @@ -40805,8 +40781,7 @@ static int ZEND_FASTCALL ZEND_YIELD_SPEC_CV_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS generator->send_target = &EX_T(opline->result.var); /* Initialize the sent value to NULL */ - Z_ADDREF(EG(uninitialized_zval)); - AI_SET_PTR(&EX_T(opline->result.var), &EG(uninitialized_zval)); + EX_T(opline->result.var).tmp_var = EG(uninitialized_zval); /* We increment to the next op, so we are at the correct position when the * generator is resumed. */ From 2768315856be2c2df291b275b76d90fb6ef09414 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 19 Dec 2012 15:21:34 +0100 Subject: [PATCH 2223/2394] Add missing zend_do_free call This is a followup to d53f1bf8ab. When the yield *statement* is used its return value still needs to be freed. --- Zend/zend_language_parser.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index c1514c5d783c1..c97361b20b1f1 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -300,7 +300,7 @@ unticked_statement: | T_RETURN ';' { zend_do_return(NULL, 0 TSRMLS_CC); } | T_RETURN expr_without_variable ';' { zend_do_return(&$2, 0 TSRMLS_CC); } | T_RETURN variable ';' { zend_do_return(&$2, 1 TSRMLS_CC); } - | yield_expr ';' { $$ = $1; } + | yield_expr ';' { zend_do_free(&$1 TSRMLS_CC); } | T_GLOBAL global_var_list ';' | T_STATIC static_var_list ';' | T_ECHO echo_expr_list ';' From 3e78c6ad25fdf07259bfaaa3e2e33fb0914e5e61 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Thu, 20 Dec 2012 20:33:18 +0100 Subject: [PATCH 2224/2394] Do not add a ref to EX(object) on generator clone If a ref has to be added it will be already added while walking the call slots. --- .../generators/clone_after_object_call.phpt | 20 +++++++++++++++++++ Zend/zend_generators.c | 6 +----- 2 files changed, 21 insertions(+), 5 deletions(-) create mode 100644 Zend/tests/generators/clone_after_object_call.phpt diff --git a/Zend/tests/generators/clone_after_object_call.phpt b/Zend/tests/generators/clone_after_object_call.phpt new file mode 100644 index 0000000000000..0a424268cc8d8 --- /dev/null +++ b/Zend/tests/generators/clone_after_object_call.phpt @@ -0,0 +1,20 @@ +--TEST-- +Cloning a generator after an object method was called +--FILE-- +b(); + yield; +} + +$g1 = gen(); +$g1->rewind(); +$g2 = clone $g1; + +echo "Done"; +--EXPECT-- +Done diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index d4254e090dd8a..a1917416ef9d9 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -223,6 +223,7 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** /* copy */ clone->execute_data->opline = execute_data->opline; clone->execute_data->function_state = execute_data->function_state; + clone->execute_data->object = execute_data->object; clone->execute_data->current_scope = execute_data->current_scope; clone->execute_data->current_called_scope = execute_data->current_called_scope; clone->execute_data->fast_ret = execute_data->fast_ret; @@ -326,11 +327,6 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** clone->execute_data->current_this = execute_data->current_this; Z_ADDREF_P(execute_data->current_this); } - - if (execute_data->object) { - clone->execute_data->object = execute_data->object; - Z_ADDREF_P(execute_data->object); - } } /* The value and key are known not to be references, so simply add refs */ From ffb848b275a085917413c171a79cbfdb1d0159d2 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 21 Dec 2012 01:56:37 +0100 Subject: [PATCH 2225/2394] Fix bug #63822: Crash when using closures with ArrayAccess op_array->T was used after the closure's op_array was already freed. This just swaps the freeing order. --- NEWS | 3 +++ Zend/zend_vm_def.h | 8 +++----- Zend/zend_vm_execute.h | 8 +++----- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/NEWS b/NEWS index d63858df01716..019513a117436 100644 --- a/NEWS +++ b/NEWS @@ -2,6 +2,9 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 201?, PHP 5.5.0 Alpha 3 +- General improvements: + . Fixed bug #63822 (Crash when using closures with ArrayAccess). + (Nikita Popov) 18 Dec 2012, PHP 5.5.0 Alpha 2 diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index c933a48248d80..2c17182b9f049 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -1843,7 +1843,7 @@ ZEND_VM_HANDLER(39, ZEND_ASSIGN_REF, VAR|CV, VAR|CV) ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) { - zend_bool nested; + zend_bool nested = EX(nested); zend_op_array *op_array = EX(op_array); EG(current_execute_data) = EX(prev_execute_data); @@ -1852,14 +1852,12 @@ ZEND_VM_HELPER(zend_leave_helper, ANY, ANY) i_free_compiled_variables(execute_data); } + zend_vm_stack_free((char*)execute_data - (ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T) TSRMLS_CC); + if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { zval_ptr_dtor((zval**)&op_array->prototype); } - nested = EX(nested); - - zend_vm_stack_free((char*)execute_data - (ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T) TSRMLS_CC); - if (nested) { execute_data = EG(current_execute_data); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index dab0df35409f0..c51df01c2d38b 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -383,7 +383,7 @@ ZEND_API void zend_execute(zend_op_array *op_array TSRMLS_DC) static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) { - zend_bool nested; + zend_bool nested = EX(nested); zend_op_array *op_array = EX(op_array); EG(current_execute_data) = EX(prev_execute_data); @@ -392,14 +392,12 @@ static int ZEND_FASTCALL zend_leave_helper_SPEC(ZEND_OPCODE_HANDLER_ARGS) i_free_compiled_variables(execute_data); } + zend_vm_stack_free((char*)execute_data - (ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T) TSRMLS_CC); + if ((op_array->fn_flags & ZEND_ACC_CLOSURE) && op_array->prototype) { zval_ptr_dtor((zval**)&op_array->prototype); } - nested = EX(nested); - - zend_vm_stack_free((char*)execute_data - (ZEND_MM_ALIGNED_SIZE(sizeof(temp_variable)) * op_array->T) TSRMLS_CC); - if (nested) { execute_data = EG(current_execute_data); } From 14f133036cfa6c2ab3f5eb9af3a0c0b29ed5d554 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 21 Dec 2012 17:28:20 +0100 Subject: [PATCH 2226/2394] Fix crash when last yielded value is a closure If zend_generator_close is called from within zend_generator_resume (e.g. due to a return statement) then all the EGs will still be using the values from the generator. That's why the stack frame has to be the last thing that is dtored, otherwise some other dtor that is using EG(current_execute_data) might access the already freed memory segment. This was the case with the closure dtor. The fix is to move the dtors for key and value to the start of the handler. This way the stack frame is the last thing that is freed. --- Zend/tests/generators/yield_closure.phpt | 17 +++++++++++++++++ Zend/zend_generators.c | 20 ++++++++++---------- 2 files changed, 27 insertions(+), 10 deletions(-) create mode 100644 Zend/tests/generators/yield_closure.phpt diff --git a/Zend/tests/generators/yield_closure.phpt b/Zend/tests/generators/yield_closure.phpt new file mode 100644 index 0000000000000..e380b299461a3 --- /dev/null +++ b/Zend/tests/generators/yield_closure.phpt @@ -0,0 +1,17 @@ +--TEST-- +Generator shouldn't crash if last yielded value is a closure +--FILE-- +next(); + +echo "Done!"; + +?> +--EXPECT-- +Done! diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index a1917416ef9d9..b16687c3d85ed 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -29,6 +29,16 @@ static zend_object_handlers zend_generator_handlers; ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC) /* {{{ */ { + if (generator->value) { + zval_ptr_dtor(&generator->value); + generator->value = NULL; + } + + if (generator->key) { + zval_ptr_dtor(&generator->key); + generator->key = NULL; + } + if (generator->execute_data) { zend_execute_data *execute_data = generator->execute_data; zend_op_array *op_array = execute_data->op_array; @@ -162,16 +172,6 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished } generator->execute_data = NULL; } - - if (generator->value) { - zval_ptr_dtor(&generator->value); - generator->value = NULL; - } - - if (generator->key) { - zval_ptr_dtor(&generator->key); - generator->key = NULL; - } } /* }}} */ From ded889e865825b41e9484a47bfbcbd4b6ed15d50 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 23 Dec 2012 14:05:04 -0500 Subject: [PATCH 2227/2394] Remove duplicated function definition --- ext/curl/php_curl.h | 34 ++++++++++++++-------------------- 1 file changed, 14 insertions(+), 20 deletions(-) diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index 0a272fa20d728..02eb24eb0e298 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -59,35 +59,29 @@ extern int le_curl_share_handle; PHP_MINIT_FUNCTION(curl); PHP_MSHUTDOWN_FUNCTION(curl); PHP_MINFO_FUNCTION(curl); -PHP_FUNCTION(curl_version); -PHP_FUNCTION(curl_init); + +PHP_FUNCTION(curl_close); PHP_FUNCTION(curl_copy_handle); -PHP_FUNCTION(curl_setopt); -PHP_FUNCTION(curl_setopt_array); +PHP_FUNCTION(curl_errno); +PHP_FUNCTION(curl_error); PHP_FUNCTION(curl_exec); PHP_FUNCTION(curl_getinfo); -PHP_FUNCTION(curl_error); -PHP_FUNCTION(curl_errno); -PHP_FUNCTION(curl_close); - -#if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ -PHP_FUNCTION(curl_reset); -#endif -#if LIBCURL_VERSION_NUM > 0x070f03 /* 7.15.4 */ -PHP_FUNCTION(curl_escape); -PHP_FUNCTION(curl_unescape); -#endif +PHP_FUNCTION(curl_init); +PHP_FUNCTION(curl_setopt); +PHP_FUNCTION(curl_setopt_array); +PHP_FUNCTION(curl_version); -PHP_FUNCTION(curl_multi_init); PHP_FUNCTION(curl_multi_add_handle); -PHP_FUNCTION(curl_multi_remove_handle); -PHP_FUNCTION(curl_multi_select); +PHP_FUNCTION(curl_multi_close); PHP_FUNCTION(curl_multi_exec); PHP_FUNCTION(curl_multi_getcontent); PHP_FUNCTION(curl_multi_info_read); -PHP_FUNCTION(curl_multi_close); -PHP_FUNCTION(curl_share_init); +PHP_FUNCTION(curl_multi_init); +PHP_FUNCTION(curl_multi_remove_handle); +PHP_FUNCTION(curl_multi_select); + PHP_FUNCTION(curl_share_close); +PHP_FUNCTION(curl_share_init); PHP_FUNCTION(curl_share_setopt); #if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ From 64595a5d1a51417ae518e124c61e1a9840d221a8 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 23 Dec 2012 14:59:41 -0500 Subject: [PATCH 2228/2394] Add curl_multi_setopt and clean curl_share_setopt curl_multi_setopt is now available and supports CURLMOPT_PIPELINING and CURLMOPT_MAXCONNECTS --- ext/curl/interface.c | 14 +++++ ext/curl/multi.c | 54 +++++++++++++++++++ ext/curl/php_curl.h | 2 + ext/curl/share.c | 12 ++--- .../tests/curl_multi_setopt_basic001.phpt | 23 ++++++++ .../tests/curl_share_setopt_basic001.phpt | 21 ++++++++ 6 files changed, 120 insertions(+), 6 deletions(-) create mode 100644 ext/curl/tests/curl_multi_setopt_basic001.phpt create mode 100644 ext/curl/tests/curl_share_setopt_basic001.phpt diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 8b617646612ed..a0a4ec5b5f6ef 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -330,6 +330,12 @@ ZEND_BEGIN_ARG_INFO(arginfo_curl_unescape, 0) ZEND_ARG_INFO(0, ch) ZEND_ARG_INFO(0, str) ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO(arginfo_curl_multi_setopt, 0) + ZEND_ARG_INFO(0, sh) + ZEND_ARG_INFO(0, option) + ZEND_ARG_INFO(0, value) +ZEND_END_ARG_INFO() #endif ZEND_BEGIN_ARG_INFO(arginfo_curl_multi_init, 0) @@ -410,6 +416,9 @@ const zend_function_entry curl_functions[] = { PHP_FE(curl_multi_getcontent, arginfo_curl_multi_getcontent) PHP_FE(curl_multi_info_read, arginfo_curl_multi_info_read) PHP_FE(curl_multi_close, arginfo_curl_multi_close) +#if LIBCURL_VERSION_NUM >= 0x070f04 /* 7.15.4 */ + PHP_FE(curl_multi_setopt, arginfo_curl_multi_setopt) +#endif PHP_FE(curl_share_init, arginfo_curl_share_init) PHP_FE(curl_share_close, arginfo_curl_share_close) PHP_FE(curl_share_setopt, arginfo_curl_share_setopt) @@ -928,6 +937,7 @@ PHP_MINIT_FUNCTION(curl) #if LIBCURL_VERSION_NUM >= 0x071000 /* Available since 7.16.0 */ REGISTER_CURL_CONSTANT(CURLOPT_SSL_SESSIONID_CACHE); + REGISTER_CURL_CONSTANT(CURLMOPT_PIPELINING); #endif #if LIBCURL_VERSION_NUM >= 0x071001 /* Available since 7.16.1 */ @@ -948,6 +958,10 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_TIMEOUT_MS); #endif +#if LIBCURL_VERSION_NUM >= 0x071003 /* Available since 7.16.3 */ + REGISTER_CURL_CONSTANT(CURLMOPT_MAXCONNECTS); +#endif + #if LIBCURL_VERSION_NUM >= 0x071004 /* Available since 7.16.4 */ REGISTER_CURL_CONSTANT(CURLOPT_KRBLEVEL); REGISTER_CURL_CONSTANT(CURLOPT_NEW_DIRECTORY_PERMS); diff --git a/ext/curl/multi.c b/ext/curl/multi.c index eedcb6abc3a4c..48655ba6e411f 100644 --- a/ext/curl/multi.c +++ b/ext/curl/multi.c @@ -359,6 +359,60 @@ void _php_curl_multi_close(zend_rsrc_list_entry *rsrc TSRMLS_DC) /* {{{ */ } /* }}} */ +#if LIBCURL_VERSION_NUM >= 0x070f04 /* 7.15.4 */ +static int _php_curl_multi_setopt(php_curlm *mh, long option, zval **zvalue, zval *return_value TSRMLS_DC) /* {{{ */ +{ + CURLMcode error = CURLM_OK; + + switch (option) { +#if LIBCURL_VERSION_NUM >= 0x071000 /* 7.16.0 */ + case CURLMOPT_PIPELINING: +#endif +#if LIBCURL_VERSION_NUM >= 0x071003 /* 7.16.3 */ + case CURLMOPT_MAXCONNECTS: +#endif + convert_to_long_ex(zvalue); + error = curl_multi_setopt(mh->multi, option, Z_LVAL_PP(zvalue)); + break; + + default: + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid curl multi configuration option"); + error = CURLM_UNKNOWN_OPTION; + break; + } + + if (error != CURLM_OK) { + return 1; + } else { + return 0; + } +} +/* }}} */ + + +/* {{{ proto int curl_multi_setopt(resource mh, int option, mixed value) + Set an option for the curl multi handle */ +PHP_FUNCTION(curl_multi_setopt) +{ + zval *z_mh, **zvalue; + long options; + php_curlm *mh; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rlZ", &z_mh, &options, &zvalue) == FAILURE) { + return; + } + + ZEND_FETCH_RESOURCE(mh, php_curlm *, &z_mh, -1, le_curl_multi_handle_name, le_curl_multi_handle); + + if (!_php_curl_multi_setopt(mh, options, zvalue, return_value TSRMLS_CC)) { + RETURN_TRUE; + } else { + RETURN_FALSE; + } +} +/* }}} */ +#endif + #endif /* diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index 02eb24eb0e298..d00b431faf1d0 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -91,6 +91,8 @@ PHP_FUNCTION(curl_reset); #if LIBCURL_VERSION_NUM >= 0x070f04 /* 7.15.4 */ PHP_FUNCTION(curl_escape); PHP_FUNCTION(curl_unescape); + +PHP_FUNCTION(curl_multi_setopt); #endif void _php_curl_multi_close(zend_rsrc_list_entry * TSRMLS_DC); diff --git a/ext/curl/share.c b/ext/curl/share.c index d7cec23ddbb50..70e2f56e6f7f1 100644 --- a/ext/curl/share.c +++ b/ext/curl/share.c @@ -76,9 +76,14 @@ static int _php_curl_share_setopt(php_curlsh *sh, long option, zval **zvalue, zv convert_to_long_ex(zvalue); error = curl_share_setopt(sh->share, option, Z_LVAL_PP(zvalue)); break; + + default: + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid curl share configuration option"); + error = CURLSHE_BAD_OPTION; + break; } - if (error != CURLE_OK) { + if (error != CURLSHE_OK) { return 1; } else { return 0; @@ -100,11 +105,6 @@ PHP_FUNCTION(curl_share_setopt) ZEND_FETCH_RESOURCE(sh, php_curlsh *, &zid, -1, le_curl_share_handle_name, le_curl_share_handle); - if (options <= 0) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid curl share configuration option"); - RETURN_FALSE; - } - if (!_php_curl_share_setopt(sh, options, zvalue, return_value TSRMLS_CC)) { RETURN_TRUE; } else { diff --git a/ext/curl/tests/curl_multi_setopt_basic001.phpt b/ext/curl/tests/curl_multi_setopt_basic001.phpt new file mode 100644 index 0000000000000..af74a0f40081c --- /dev/null +++ b/ext/curl/tests/curl_multi_setopt_basic001.phpt @@ -0,0 +1,23 @@ +--TEST-- +curl_multi_setopt basic test +--SKIPIF-- +if (!extension_loaded("curl")) { + exit("skip curl extension not loaded"); +} +$curl_version = curl_version(); +if ($curl_version['version_number'] < 0x071000) { + exit("skip: test works only with curl >= 7.16.0"); +} +--FILE-- + +--EXPECTF-- +bool(true) + +Warning: curl_multi_setopt(): Invalid curl multi configuration option in %s on line %d +bool(false) diff --git a/ext/curl/tests/curl_share_setopt_basic001.phpt b/ext/curl/tests/curl_share_setopt_basic001.phpt new file mode 100644 index 0000000000000..88e92860b0ec4 --- /dev/null +++ b/ext/curl/tests/curl_share_setopt_basic001.phpt @@ -0,0 +1,21 @@ +--TEST-- +curl_share_setopt basic test +--SKIPIF-- +if (!extension_loaded("curl")) { + exit("skip curl extension not loaded"); +} +--FILE-- + +--EXPECTF-- +bool(true) +bool(true) + +Warning: curl_share_setopt(): Invalid curl share configuration option in %s on line %d +bool(false) From 4b4f3db73142799da71be14d73938456e918b3ac Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 23 Dec 2012 15:45:39 -0500 Subject: [PATCH 2229/2394] Support for curl_strerror and curl_multi_strerror Add the support for both curl_strerror and curl_multi_strerror. Those function will return a string describing the error code passed in the argument errornum --- ext/curl/interface.c | 38 ++++++++++++++++++++- ext/curl/multi.c | 23 ++++++++++++- ext/curl/php_curl.h | 5 +++ ext/curl/tests/curl_multi_strerror_001.phpt | 20 +++++++++++ ext/curl/tests/curl_strerror_001.phpt | 22 ++++++++++++ 5 files changed, 106 insertions(+), 2 deletions(-) create mode 100644 ext/curl/tests/curl_multi_strerror_001.phpt create mode 100644 ext/curl/tests/curl_strerror_001.phpt diff --git a/ext/curl/interface.c b/ext/curl/interface.c index a0a4ec5b5f6ef..21d4bb187c9ca 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -374,6 +374,16 @@ ZEND_BEGIN_ARG_INFO(arginfo_curl_multi_close, 0) ZEND_ARG_INFO(0, mh) ZEND_END_ARG_INFO() +#if LIBCURL_VERSION_NUM >= 0x070c00 /* Available since 7.12.0 */ +ZEND_BEGIN_ARG_INFO(arginfo_curl_strerror, 0) + ZEND_ARG_INFO(0, errornum) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO(arginfo_curl_multi_strerror, 0) + ZEND_ARG_INFO(0, errornum) +ZEND_END_ARG_INFO() +#endif + ZEND_BEGIN_ARG_INFO(arginfo_curl_share_init, 0) ZEND_END_ARG_INFO() @@ -401,6 +411,10 @@ const zend_function_entry curl_functions[] = { PHP_FE(curl_error, arginfo_curl_error) PHP_FE(curl_errno, arginfo_curl_errno) PHP_FE(curl_close, arginfo_curl_close) +#if LIBCURL_VERSION_NUM >= 0x070c00 /* 7.12.0 */ + PHP_FE(curl_strerror, arginfo_curl_strerror) + PHP_FE(curl_multi_strerror, arginfo_curl_multi_strerror) +#endif #if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ PHP_FE(curl_reset, arginfo_curl_reset) #endif @@ -3256,6 +3270,28 @@ static void _php_curl_close(zend_rsrc_list_entry *rsrc TSRMLS_DC) } /* }}} */ +#if LIBCURL_VERSION_NUM >= 0x070c00 /* Available since 7.12.0 */ +/* {{{ proto bool curl_strerror(int code) + return string describing error code */ +PHP_FUNCTION(curl_strerror) +{ + long code; + const char *str; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &code) == FAILURE) { + return; + } + + str = curl_easy_strerror(code); + if (str) { + RETURN_STRING(str, 1); + } else { + RETURN_NULL(); + } +} +/* }}} */ +#endif + #if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ /* {{{ _php_curl_reset_handlers() Reset all handlers of a given php_curl */ @@ -3280,7 +3316,7 @@ static void _php_curl_reset_handlers(php_curl *ch) ch->handlers->read->stream = NULL; } ch->handlers->read->fp = NULL; - ch->handlers->read->fd = NULL; + ch->handlers->read->fd = 0; ch->handlers->read->method = PHP_CURL_DIRECT; if (ch->handlers->std_err) { diff --git a/ext/curl/multi.c b/ext/curl/multi.c index 48655ba6e411f..4cf9d5fb4a147 100644 --- a/ext/curl/multi.c +++ b/ext/curl/multi.c @@ -359,6 +359,28 @@ void _php_curl_multi_close(zend_rsrc_list_entry *rsrc TSRMLS_DC) /* {{{ */ } /* }}} */ +#if LIBCURL_VERSION_NUM >= 0x070c00 /* Available since 7.12.0 */ +/* {{{ proto bool curl_multi_strerror(int code) + return string describing error code */ +PHP_FUNCTION(curl_multi_strerror) +{ + long code; + const char *str; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &code) == FAILURE) { + return; + } + + str = curl_multi_strerror(code); + if (str) { + RETURN_STRING(str, 1); + } else { + RETURN_NULL(); + } +} +/* }}} */ +#endif + #if LIBCURL_VERSION_NUM >= 0x070f04 /* 7.15.4 */ static int _php_curl_multi_setopt(php_curlm *mh, long option, zval **zvalue, zval *return_value TSRMLS_DC) /* {{{ */ { @@ -389,7 +411,6 @@ static int _php_curl_multi_setopt(php_curlm *mh, long option, zval **zvalue, zva } /* }}} */ - /* {{{ proto int curl_multi_setopt(resource mh, int option, mixed value) Set an option for the curl multi handle */ PHP_FUNCTION(curl_multi_setopt) diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index d00b431faf1d0..2c97bcaca4e71 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -84,6 +84,11 @@ PHP_FUNCTION(curl_share_close); PHP_FUNCTION(curl_share_init); PHP_FUNCTION(curl_share_setopt); +#if LIBCURL_VERSION_NUM >= 0x070c00 /* 7.12.0 */ +PHP_FUNCTION(curl_strerror); +PHP_FUNCTION(curl_multi_strerror); +#endif + #if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ PHP_FUNCTION(curl_reset); #endif diff --git a/ext/curl/tests/curl_multi_strerror_001.phpt b/ext/curl/tests/curl_multi_strerror_001.phpt new file mode 100644 index 0000000000000..85a665ce6fc1e --- /dev/null +++ b/ext/curl/tests/curl_multi_strerror_001.phpt @@ -0,0 +1,20 @@ +--TEST-- +curl_multi_strerror basic test +--SKIPIF-- +if (!extension_loaded("curl")) { + exit("skip curl extension not loaded"); +} +$curl_version = curl_version(); +if ($curl_version['version_number'] < 0x070c00) { + exit("skip: test works only with curl >= 7.12.0"); +} +--FILE-- + +--EXPECTF-- +string(8) "No error" +string(20) "Invalid multi handle" diff --git a/ext/curl/tests/curl_strerror_001.phpt b/ext/curl/tests/curl_strerror_001.phpt new file mode 100644 index 0000000000000..c61481bc8bdb8 --- /dev/null +++ b/ext/curl/tests/curl_strerror_001.phpt @@ -0,0 +1,22 @@ +--TEST-- +curl_strerror basic test +--SKIPIF-- +if (!extension_loaded("curl")) { + exit("skip curl extension not loaded"); +} +$curl_version = curl_version(); +if ($curl_version['version_number'] < 0x070c00) { + exit("skip: test works only with curl >= 7.12.0"); +} +--FILE-- + +--EXPECTF-- +string(8) "No error" +string(20) "Unsupported protocol" +string(13) "Unknown error" From 33f44af1a773d271ec96bbec445d625313195176 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 23 Dec 2012 17:13:49 -0500 Subject: [PATCH 2230/2394] New curl_pause() function Add the curl_pause function (binding of curl_easy_pause). Using this function, you can explicitly mark a running connection to get paused, and you can unpause a connection that was previously paused. --- ext/curl/interface.c | 39 +++++++++++++++++++++++++++++++++++++++ ext/curl/php_curl.h | 4 ++++ 2 files changed, 43 insertions(+) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 21d4bb187c9ca..06e5eb2ac5917 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -396,6 +396,13 @@ ZEND_BEGIN_ARG_INFO(arginfo_curl_share_setopt, 0) ZEND_ARG_INFO(0, option) ZEND_ARG_INFO(0, value) ZEND_END_ARG_INFO() + +#if LIBCURL_VERSION_NUM >= 0x071200 /* Available since 7.18.0 */ +ZEND_BEGIN_ARG_INFO(arginfo_curl_pause, 0) + ZEND_ARG_INFO(0, ch) + ZEND_ARG_INFO(0, bitmask) +ZEND_END_ARG_INFO() +#endif /* }}} */ /* {{{ curl_functions[] @@ -421,6 +428,9 @@ const zend_function_entry curl_functions[] = { #if LIBCURL_VERSION_NUM >= 0x070f04 /* 7.15.4 */ PHP_FE(curl_escape, arginfo_curl_escape) PHP_FE(curl_unescape, arginfo_curl_unescape) +#endif +#if LIBCURL_VERSION_NUM >= 0x071200 /* 7.18.0 */ + PHP_FE(curl_pause, arginfo_curl_pause) #endif PHP_FE(curl_multi_init, arginfo_curl_multi_init) PHP_FE(curl_multi_add_handle, arginfo_curl_multi_add_handle) @@ -999,6 +1009,14 @@ PHP_MINIT_FUNCTION(curl) #if LIBCURL_VERSION_NUM >= 0x071200 /* Available since 7.18.0 */ REGISTER_CURL_CONSTANT(CURLOPT_PROXY_TRANSFER_MODE); + REGISTER_CURL_CONSTANT(CURLPAUSE_ALL); + REGISTER_CURL_CONSTANT(CURLPAUSE_CONT); + REGISTER_CURL_CONSTANT(CURLPAUSE_RECV); + REGISTER_CURL_CONSTANT(CURLPAUSE_RECV_CONT); + REGISTER_CURL_CONSTANT(CURLPAUSE_SEND); + REGISTER_CURL_CONSTANT(CURLPAUSE_SEND_CONT); + REGISTER_CURL_CONSTANT(CURL_READFUNC_PAUSE); + REGISTER_CURL_CONSTANT(CURL_WRITEFUNC_PAUSE); #endif #if LIBCURL_VERSION_NUM >= 0x071202 /* Available since 7.18.2 */ @@ -3417,8 +3435,29 @@ PHP_FUNCTION(curl_unescape) RETURN_FALSE; } } +/* }}} */ #endif + +#if LIBCURL_VERSION_NUM >= 0x071200 /* 7.18.0 */ +/* {{{ proto void curl_pause(resource ch, int bitmask) + pause and unpause a connection */ +PHP_FUNCTION(curl_pause) +{ + long bitmask; + zval *zid; + php_curl *ch; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl", &zid, &bitmask) == FAILURE) { + return; + } + + ZEND_FETCH_RESOURCE(ch, php_curl *, &zid, -1, le_curl_name, le_curl); + + RETURN_LONG(curl_easy_pause(ch->cp, bitmask)); +} /* }}} */ +#endif + #endif /* HAVE_CURL */ /* diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index 2c97bcaca4e71..de8eb7efa5600 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -100,6 +100,10 @@ PHP_FUNCTION(curl_unescape); PHP_FUNCTION(curl_multi_setopt); #endif +#if LIBCURL_VERSION_NUM >= 0x071200 /* 7.18.0 */ +PHP_FUNCTION(curl_pause); +#endif + void _php_curl_multi_close(zend_rsrc_list_entry * TSRMLS_DC); void _php_curl_share_close(zend_rsrc_list_entry * TSRMLS_DC); From 24f1ef1b0254d4b8341aa9d74ca450e89c2a8683 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sun, 23 Dec 2012 17:48:05 -0500 Subject: [PATCH 2231/2394] Update NEWS --- NEWS | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/NEWS b/NEWS index 019513a117436..54b4455bc19e2 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,11 @@ PHP NEWS . Fixed bug #63822 (Crash when using closures with ArrayAccess). (Nikita Popov) +- cURL: + . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror + curl_pause, curl_reset, curl_share_close, curl_share_init, + curl_share_setopt curl_strerror and curl_unescape. (Pierrick) + 18 Dec 2012, PHP 5.5.0 Alpha 2 - General improvements: From be7b0bc3ec02e4f223920ee6397f9c4993eb7df5 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Mon, 17 Dec 2012 22:02:32 +0100 Subject: [PATCH 2232/2394] Implement Generator::throw() method Generator::throw($exception) throws an exception into the generator. The exception is thrown at the current point of suspension within the generator. It basically behaves as if the current yield statement were replaced with a throw statement and the generator subsequently resumed. --- NEWS | 1 + .../generators/throw_already_closed.phpt | 23 +++++++++ Zend/tests/generators/throw_caught.phpt | 25 ++++++++++ .../generators/throw_not_an_exception.phpt | 15 ++++++ Zend/tests/generators/throw_rethrow.phpt | 32 ++++++++++++ Zend/tests/generators/throw_uncaught.phpt | 19 +++++++ Zend/zend_generators.c | 49 +++++++++++++++++-- 7 files changed, 159 insertions(+), 5 deletions(-) create mode 100644 Zend/tests/generators/throw_already_closed.phpt create mode 100644 Zend/tests/generators/throw_caught.phpt create mode 100644 Zend/tests/generators/throw_not_an_exception.phpt create mode 100644 Zend/tests/generators/throw_rethrow.phpt create mode 100644 Zend/tests/generators/throw_uncaught.phpt diff --git a/NEWS b/NEWS index 54b4455bc19e2..b8fb42bb4f2b0 100644 --- a/NEWS +++ b/NEWS @@ -5,6 +5,7 @@ PHP NEWS - General improvements: . Fixed bug #63822 (Crash when using closures with ArrayAccess). (Nikita Popov) + . Add Generator::throw() method. (Nikita Popov) - cURL: . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror diff --git a/Zend/tests/generators/throw_already_closed.phpt b/Zend/tests/generators/throw_already_closed.phpt new file mode 100644 index 0000000000000..e918e540ab967 --- /dev/null +++ b/Zend/tests/generators/throw_already_closed.phpt @@ -0,0 +1,23 @@ +--TEST-- +Generator::throw() on an already closed generator +--FILE-- +next(); +$gen->next(); +var_dump($gen->valid()); +$gen->throw(new Exception('test')); + +?> +--EXPECTF-- +bool(false) + +Fatal error: Uncaught exception 'Exception' with message 'test' in %s:%d +Stack trace: +#0 {main} + thrown in %s on line %d diff --git a/Zend/tests/generators/throw_caught.phpt b/Zend/tests/generators/throw_caught.phpt new file mode 100644 index 0000000000000..0c3f8e9b2daae --- /dev/null +++ b/Zend/tests/generators/throw_caught.phpt @@ -0,0 +1,25 @@ +--TEST-- +Generator::throw() where the exception is caught in the generator +--FILE-- +throw(new RuntimeException('Test'))); + +?> +--EXPECTF-- +exception 'RuntimeException' with message 'Test' in %s:%d +Stack trace: +#0 {main} + +string(6) "result" diff --git a/Zend/tests/generators/throw_not_an_exception.phpt b/Zend/tests/generators/throw_not_an_exception.phpt new file mode 100644 index 0000000000000..d93903e2150d1 --- /dev/null +++ b/Zend/tests/generators/throw_not_an_exception.phpt @@ -0,0 +1,15 @@ +--TEST-- +Generator::throw() with something that's not an exception +--FILE-- +throw(new stdClass); + +?> +--EXPECTF-- +Fatal error: Exceptions must be valid objects derived from the Exception base class in %s on line %d diff --git a/Zend/tests/generators/throw_rethrow.phpt b/Zend/tests/generators/throw_rethrow.phpt new file mode 100644 index 0000000000000..267f5f0db86ec --- /dev/null +++ b/Zend/tests/generators/throw_rethrow.phpt @@ -0,0 +1,32 @@ +--TEST-- +Generator::throw() where the generator throws a different exception +--FILE-- +throw(new RuntimeException('throw'))); + +?> +--EXPECTF-- +Caught: exception 'RuntimeException' with message 'throw' in %s:%d +Stack trace: +#0 {main} + + +Fatal error: Uncaught exception 'LogicException' with message 'new throw' in %s:%d +Stack trace: +#0 [internal function]: gen() +#1 %s(%d): Generator->throw(Object(RuntimeException)) +#2 {main} + thrown in %s on line %d + diff --git a/Zend/tests/generators/throw_uncaught.phpt b/Zend/tests/generators/throw_uncaught.phpt new file mode 100644 index 0000000000000..f06cff1b8ecf2 --- /dev/null +++ b/Zend/tests/generators/throw_uncaught.phpt @@ -0,0 +1,19 @@ +--TEST-- +Generator::throw() where the exception is not caught in the generator +--FILE-- +throw(new RuntimeException('test'))); + +?> +--EXPECTF-- +Fatal error: Uncaught exception 'RuntimeException' with message 'test' in %s:%d +Stack trace: +#0 {main} + thrown in %s on line %d diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index b16687c3d85ed..9c65c534bd42f 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -431,10 +431,6 @@ static zend_function *zend_generator_get_constructor(zval *object TSRMLS_DC) /* ZEND_API void zend_generator_resume(zend_generator *generator TSRMLS_DC) /* {{{ */ { - if (EG(exception)) { - return; - } - /* The generator is already closed, thus can't resume */ if (!generator->execute_data) { return; @@ -617,7 +613,7 @@ ZEND_METHOD(Generator, next) } /* }}} */ -/* {{{ proto mixed Generator::send() +/* {{{ proto mixed Generator::send(mixed $value) * Sends a value to the generator */ ZEND_METHOD(Generator, send) { @@ -648,6 +644,44 @@ ZEND_METHOD(Generator, send) } /* }}} */ +/* {{{ proto mixed Generator::throw(Exception $exception) + * Throws an exception into the generator */ +ZEND_METHOD(Generator, throw) +{ + zval *exception, *exception_copy; + zend_generator *generator; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z", &exception) == FAILURE) { + return; + } + + ALLOC_ZVAL(exception_copy); + MAKE_COPY_ZVAL(&exception, exception_copy); + + generator = (zend_generator *) zend_object_store_get_object(getThis() TSRMLS_CC); + + if (generator->execute_data) { + /* Throw the exception in the context of the generator */ + zend_execute_data *current_execute_data = EG(current_execute_data); + EG(current_execute_data) = generator->execute_data; + + zend_throw_exception_object(exception_copy TSRMLS_CC); + + EG(current_execute_data) = current_execute_data; + + zend_generator_resume(generator TSRMLS_CC); + + if (generator->value) { + RETURN_ZVAL(generator->value, 1, 0); + } + } else { + /* If the generator is already closed throw the exception in the + * current context */ + zend_throw_exception_object(exception_copy TSRMLS_CC); + } +} +/* }}} */ + /* {{{ proto void Generator::__wakeup() * Throws an Exception as generators can't be serialized */ ZEND_METHOD(Generator, __wakeup) @@ -790,6 +824,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_generator_send, 0, 0, 1) ZEND_ARG_INFO(0, value) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_generator_throw, 0, 0, 1) + ZEND_ARG_INFO(0, exception) +ZEND_END_ARG_INFO() + static const zend_function_entry generator_functions[] = { ZEND_ME(Generator, rewind, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_ME(Generator, valid, arginfo_generator_void, ZEND_ACC_PUBLIC) @@ -797,6 +835,7 @@ static const zend_function_entry generator_functions[] = { ZEND_ME(Generator, key, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_ME(Generator, next, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_ME(Generator, send, arginfo_generator_send, ZEND_ACC_PUBLIC) + ZEND_ME(Generator, throw, arginfo_generator_throw, ZEND_ACC_PUBLIC) ZEND_ME(Generator, __wakeup, arginfo_generator_void, ZEND_ACC_PUBLIC) ZEND_FE_END }; From bc0425c02579dbbb9e9f9f38a835413c6c512eb3 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 25 Dec 2012 10:47:43 +0400 Subject: [PATCH 2233/2394] Removed deprecated fields --- Zend/zend.h | 4 ---- Zend/zend_compile.c | 4 ---- 2 files changed, 8 deletions(-) diff --git a/Zend/zend.h b/Zend/zend.h index adeccc6f39208..444b71ed64d2b 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -451,8 +451,6 @@ struct _zend_trait_precedence { zend_trait_method_reference *trait_method; zend_class_entry** exclude_from_classes; - - union _zend_function* function; /* FIXME: kept in 5.4 for BC, not used */ }; typedef struct _zend_trait_precedence zend_trait_precedence; @@ -469,8 +467,6 @@ struct _zend_trait_alias { * modifiers to be set on trait method */ zend_uint modifiers; - - union _zend_function* function; /* FIXME: kept in 5.4 for BC, not used */ }; typedef struct _zend_trait_alias zend_trait_alias; diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 8998b07eda227..0d9fb17ab0c5c 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -4454,8 +4454,6 @@ void zend_add_trait_alias(znode *method_reference, znode *modifiers, znode *alia } else { trait_alias->alias = NULL; } - trait_alias->function = NULL; - zend_add_to_list(&ce->trait_aliases, trait_alias TSRMLS_CC); } /* }}} */ @@ -4468,8 +4466,6 @@ void zend_add_trait_precedence(znode *method_reference, znode *trait_list TSRMLS trait_precedence->trait_method = (zend_trait_method_reference*)method_reference->u.op.ptr; trait_precedence->exclude_from_classes = (zend_class_entry**) trait_list->u.op.ptr; - trait_precedence->function = NULL; - zend_add_to_list(&ce->trait_precedences, trait_precedence TSRMLS_CC); } /* }}} */ From 8e6bf9e5e55b05842c06ae459078293d1a97d431 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Tue, 25 Dec 2012 16:23:52 +0400 Subject: [PATCH 2234/2394] spelling --- Zend/zend_execute.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index c0b1d0203b8fa..9e340483ee34b 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1598,8 +1598,8 @@ static zend_always_inline zend_execute_data *i_create_execute_data_from_op_array * a copy of previous execute_data and passed parameters. */ if (UNEXPECTED((op_array->fn_flags & ZEND_ACC_GENERATOR) != 0)) { - /* Prepend the regular stack frame with copy on prev_execute_data - * and passed arguments + /* Prepend the regular stack frame with a copy of prev_execute_data + * and the passed arguments */ int args_count = zend_vm_stack_get_args_count_ex(EG(current_execute_data)); size_t args_size = ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * (args_count + 1); @@ -1616,7 +1616,7 @@ static zend_always_inline zend_execute_data *i_create_execute_data_from_op_array EX(prev_execute_data)->function_state.function = (zend_function*)op_array; EX(prev_execute_data)->function_state.arguments = (void**)((char*)ZEND_VM_STACK_ELEMETS(EG(argument_stack)) + ZEND_MM_ALIGNED_SIZE(sizeof(zval*)) * args_count); - /* copy arguemnts */ + /* copy arguments */ *EX(prev_execute_data)->function_state.arguments = (void*)(zend_uintptr_t)args_count; if (args_count > 0) { zval **arg_src = (zval**)zend_vm_stack_get_arg_ex(EG(current_execute_data), 1); From 8456cef1dbcb6c5a5690ce4553063ad18874f0b1 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Wed, 26 Dec 2012 00:43:37 -0500 Subject: [PATCH 2235/2394] Fix ext/curl tests to work on every libcurl versions Thanks Laruence :) --- ext/curl/tests/curl_multi_setopt_basic001.phpt | 2 ++ ext/curl/tests/curl_multi_strerror_001.phpt | 10 ++++++---- ext/curl/tests/curl_share_setopt_basic001.phpt | 2 ++ ext/curl/tests/curl_strerror_001.phpt | 14 ++++++++------ 4 files changed, 18 insertions(+), 10 deletions(-) diff --git a/ext/curl/tests/curl_multi_setopt_basic001.phpt b/ext/curl/tests/curl_multi_setopt_basic001.phpt index af74a0f40081c..a13cf6d7160b3 100644 --- a/ext/curl/tests/curl_multi_setopt_basic001.phpt +++ b/ext/curl/tests/curl_multi_setopt_basic001.phpt @@ -1,6 +1,7 @@ --TEST-- curl_multi_setopt basic test --SKIPIF-- += 7.16.0"); } +?> --FILE-- = 7.12.0"); } +?> --FILE-- --EXPECTF-- -string(8) "No error" -string(20) "Invalid multi handle" +string(8) "no error" +string(20) "invalid multi handle" diff --git a/ext/curl/tests/curl_share_setopt_basic001.phpt b/ext/curl/tests/curl_share_setopt_basic001.phpt index 88e92860b0ec4..33c03e3337e33 100644 --- a/ext/curl/tests/curl_share_setopt_basic001.phpt +++ b/ext/curl/tests/curl_share_setopt_basic001.phpt @@ -1,9 +1,11 @@ --TEST-- curl_share_setopt basic test --SKIPIF-- + --FILE-- = 7.12.0"); } +?> --FILE-- --EXPECTF-- -string(8) "No error" -string(20) "Unsupported protocol" -string(13) "Unknown error" +string(8) "no error" +string(20) "unsupported protocol" +string(13) "unknown error" From 722b8fb80eb3a4a5f8fa5e8dd91456148e1f755a Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Fri, 28 Dec 2012 00:51:04 -0500 Subject: [PATCH 2236/2394] Add new curl options Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION, CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE, CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. --- NEWS | 3 +++ ext/curl/interface.c | 30 ++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) diff --git a/NEWS b/NEWS index b8fb42bb4f2b0..b67276aa80be6 100644 --- a/NEWS +++ b/NEWS @@ -11,6 +11,9 @@ PHP NEWS . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror curl_pause, curl_reset, curl_share_close, curl_share_init, curl_share_setopt curl_strerror and curl_unescape. (Pierrick) + . Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION, + CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE, + CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick) 18 Dec 2012, PHP 5.5.0 Alpha 2 diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 063639e97e8d4..7d9b55c02fa15 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -690,6 +690,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_SSL_VERIFYHOST); REGISTER_CURL_CONSTANT(CURLOPT_SSL_VERIFYPEER); REGISTER_CURL_CONSTANT(CURLOPT_STDERR); + REGISTER_CURL_CONSTANT(CURLOPT_TELNETOPTIONS); REGISTER_CURL_CONSTANT(CURLOPT_TIMECONDITION); REGISTER_CURL_CONSTANT(CURLOPT_TIMEOUT); REGISTER_CURL_CONSTANT(CURLOPT_TIMEVALUE); @@ -732,6 +733,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLE_FTP_COULDNT_SET_BINARY); REGISTER_CURL_CONSTANT(CURLE_FTP_COULDNT_STOR_FILE); REGISTER_CURL_CONSTANT(CURLE_FTP_COULDNT_USE_REST); + REGISTER_CURL_CONSTANT(CURLE_FTP_PARTIAL_FILE); REGISTER_CURL_CONSTANT(CURLE_FTP_PORT_FAILED); REGISTER_CURL_CONSTANT(CURLE_FTP_QUOTE_ERROR); REGISTER_CURL_CONSTANT(CURLE_FTP_USER_PASSWORD_INCORRECT); @@ -1156,12 +1158,24 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_TRANSFER_ENCODING); #endif +#if LIBCURL_VERSION_NUM >= 0x071600 /* Available since 7.22.0 */ + REGISTER_CURL_CONSTANT(CURLGSSAPI_DELEGATION_FLAG); + REGISTER_CURL_CONSTANT(CURLGSSAPI_DELEGATION_POLICY_FLAG); + REGISTER_CURL_CONSTANT(CURLOPT_GSSAPI_DELEGATION); +#endif + #if LIBCURL_VERSION_NUM >= 0x071800 /* Available since 7.24.0 */ + REGISTER_CURL_CONSTANT(CURLOPT_ACCEPTTIMEOUT_MS); REGISTER_CURL_CONSTANT(CURLOPT_DNS_SERVERS); #endif #if LIBCURL_VERSION_NUM >= 0x071900 /* Available since 7.25.0 */ REGISTER_CURL_CONSTANT(CURLOPT_MAIL_AUTH); + REGISTER_CURL_CONSTANT(CURLOPT_SSL_OPTIONS); + REGISTER_CURL_CONSTANT(CURLOPT_TCP_KEEPALIVE); + REGISTER_CURL_CONSTANT(CURLOPT_TCP_KEEPIDLE); + REGISTER_CURL_CONSTANT(CURLOPT_TCP_KEEPINTVL); + REGISTER_CURL_CONSTANT(CURLSSLOPT_ALLOW_BEAST); #endif #if CURLOPT_FTPASCII != 0 @@ -2210,6 +2224,18 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #if LIBCURL_VERSION_NUM >= 0x071504 /* Available since 7.21.4 */ case CURLOPT_TLSAUTH_TYPE: #endif +#if LIBCURL_VERSION_NUM >= 0x071600 /* Available since 7.22.0 */ + case CURLOPT_GSSAPI_DELEGATION: +#endif +#if LIBCURL_VERSION_NUM >= 0x071800 /* Available since 7.24.0 */ + case CURLOPT_ACCEPTTIMEOUT_MS: +#endif +#if LIBCURL_VERSION_NUM >= 0x071900 /* Available since 7.25.0 */ + case CURLOPT_SSL_OPTIONS: + case CURLOPT_TCP_KEEPALIVE: + case CURLOPT_TCP_KEEPIDLE: + case CURLOPT_TCP_KEEPINTVL: +#endif #if CURLOPT_MUTE != 0 case CURLOPT_MUTE: #endif @@ -2416,6 +2442,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_POSTQUOTE: case CURLOPT_PREQUOTE: case CURLOPT_QUOTE: + case CURLOPT_TELNETOPTIONS: #if LIBCURL_VERSION_NUM >= 0x071400 /* Available since 7.20.0 */ case CURLOPT_MAIL_RCPT: #endif @@ -2446,6 +2473,9 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_PREQUOTE: name = "CURLOPT_PREQUOTE"; break; + case CURLOPT_TELNETOPTIONS: + name = "CURLOPT_TELNETOPTIONS"; + break; #if LIBCURL_VERSION_NUM >= 0x071400 /* Available since 7.20.0 */ case CURLOPT_MAIL_RCPT: name = "CURLOPT_MAIL_RCPT"; From 8228597ecce3ad868d2c6bfca5ff43f29e014296 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sat, 29 Dec 2012 23:11:37 -0500 Subject: [PATCH 2237/2394] Fixed bug #63874 (Segfaul if php_strip_whitespace has heredoc) T_END_HEREDOC don't carry a token value anymore since commit 4cf90e06c Bugfix by Nikita for bug #60097 --- NEWS | 1 + Zend/zend_highlight.c | 1 - ext/standard/tests/strings/bug63874.phpt | 16 ++++++++++++++++ 3 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 ext/standard/tests/strings/bug63874.phpt diff --git a/NEWS b/NEWS index b67276aa80be6..2d0b4c3d027a3 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,7 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 Alpha 3 - General improvements: + . Fixed bug #63874 (Segfault if php_strip_whitespace has heredoc). (Pierrick) . Fixed bug #63822 (Crash when using closures with ArrayAccess). (Nikita Popov) . Add Generator::throw() method. (Nikita Popov) diff --git a/Zend/zend_highlight.c b/Zend/zend_highlight.c index 938e1c612b912..7fe617451940e 100644 --- a/Zend/zend_highlight.c +++ b/Zend/zend_highlight.c @@ -186,7 +186,6 @@ ZEND_API void zend_strip(TSRMLS_D) case T_END_HEREDOC: zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); - efree(token.value.str.val); /* read the following character, either newline or ; */ if (lex_scan(&token TSRMLS_CC) != T_WHITESPACE) { zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng)); diff --git a/ext/standard/tests/strings/bug63874.phpt b/ext/standard/tests/strings/bug63874.phpt new file mode 100644 index 0000000000000..066cc155df960 --- /dev/null +++ b/ext/standard/tests/strings/bug63874.phpt @@ -0,0 +1,16 @@ +--TEST-- +Bug #63874 (Segfault if php_strip_whitespace has heredoc) +--FILE-- + +--EXPECT-- + From a666285bc2488b7f7362368c388e41428610ad1d Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 1 Jan 2013 16:37:09 +0800 Subject: [PATCH 2238/2394] Happy New Year --- TSRM/tsrm_nw.c | 2 +- TSRM/tsrm_nw.h | 2 +- TSRM/tsrm_virtual_cwd.c | 2 +- TSRM/tsrm_virtual_cwd.h | 2 +- TSRM/tsrm_win32.c | 2 +- TSRM/tsrm_win32.h | 2 +- Zend/zend.c | 4 ++-- Zend/zend.h | 2 +- Zend/zend_API.c | 2 +- Zend/zend_API.h | 2 +- Zend/zend_alloc.c | 2 +- Zend/zend_alloc.h | 2 +- Zend/zend_build.h | 2 +- Zend/zend_builtin_functions.c | 2 +- Zend/zend_builtin_functions.h | 2 +- Zend/zend_closures.c | 2 +- Zend/zend_closures.h | 2 +- Zend/zend_compile.c | 2 +- Zend/zend_compile.h | 2 +- Zend/zend_config.nw.h | 2 +- Zend/zend_config.w32.h | 2 +- Zend/zend_constants.c | 2 +- Zend/zend_constants.h | 2 +- Zend/zend_default_classes.c | 2 +- Zend/zend_dynamic_array.c | 2 +- Zend/zend_dynamic_array.h | 2 +- Zend/zend_errors.h | 2 +- Zend/zend_exceptions.c | 2 +- Zend/zend_exceptions.h | 2 +- Zend/zend_execute.c | 2 +- Zend/zend_execute.h | 2 +- Zend/zend_execute_API.c | 2 +- Zend/zend_extensions.c | 2 +- Zend/zend_extensions.h | 2 +- Zend/zend_float.c | 2 +- Zend/zend_float.h | 2 +- Zend/zend_gc.c | 2 +- Zend/zend_gc.h | 2 +- Zend/zend_generators.c | 2 +- Zend/zend_generators.h | 2 +- Zend/zend_globals.h | 2 +- Zend/zend_globals_macros.h | 2 +- Zend/zend_hash.c | 2 +- Zend/zend_hash.h | 2 +- Zend/zend_highlight.c | 2 +- Zend/zend_highlight.h | 2 +- Zend/zend_indent.c | 2 +- Zend/zend_indent.h | 2 +- Zend/zend_ini.c | 2 +- Zend/zend_ini.h | 2 +- Zend/zend_ini_parser.y | 2 +- Zend/zend_ini_scanner.c | 2 +- Zend/zend_ini_scanner.h | 2 +- Zend/zend_ini_scanner.l | 2 +- Zend/zend_interfaces.c | 2 +- Zend/zend_interfaces.h | 2 +- Zend/zend_istdiostream.h | 2 +- Zend/zend_iterators.c | 2 +- Zend/zend_iterators.h | 2 +- Zend/zend_language_parser.y | 2 +- Zend/zend_language_scanner.c | 2 +- Zend/zend_language_scanner.h | 2 +- Zend/zend_language_scanner.l | 2 +- Zend/zend_list.c | 2 +- Zend/zend_list.h | 2 +- Zend/zend_llist.c | 2 +- Zend/zend_llist.h | 2 +- Zend/zend_modules.h | 2 +- Zend/zend_multibyte.c | 2 +- Zend/zend_multibyte.h | 2 +- Zend/zend_multiply.h | 2 +- Zend/zend_object_handlers.c | 2 +- Zend/zend_object_handlers.h | 2 +- Zend/zend_objects.c | 2 +- Zend/zend_objects.h | 2 +- Zend/zend_objects_API.c | 2 +- Zend/zend_objects_API.h | 2 +- Zend/zend_opcode.c | 2 +- Zend/zend_operators.c | 2 +- Zend/zend_operators.h | 2 +- Zend/zend_ptr_stack.c | 2 +- Zend/zend_ptr_stack.h | 2 +- Zend/zend_qsort.c | 2 +- Zend/zend_qsort.h | 2 +- Zend/zend_sprintf.c | 2 +- Zend/zend_stack.c | 2 +- Zend/zend_stack.h | 2 +- Zend/zend_static_allocator.c | 2 +- Zend/zend_static_allocator.h | 2 +- Zend/zend_stream.c | 2 +- Zend/zend_stream.h | 2 +- Zend/zend_string.c | 2 +- Zend/zend_string.h | 2 +- Zend/zend_strtod.h | 2 +- Zend/zend_ts_hash.c | 2 +- Zend/zend_ts_hash.h | 2 +- Zend/zend_types.h | 2 +- Zend/zend_variables.c | 2 +- Zend/zend_variables.h | 2 +- Zend/zend_vm.h | 2 +- Zend/zend_vm_def.h | 2 +- Zend/zend_vm_execute.h | 2 +- Zend/zend_vm_gen.php | 4 ++-- Zend/zend_vm_opcodes.h | 2 +- ext/bcmath/bcmath.c | 2 +- ext/bcmath/php_bcmath.h | 2 +- ext/bz2/bz2.c | 2 +- ext/bz2/bz2_filter.c | 2 +- ext/bz2/php_bz2.h | 2 +- ext/calendar/cal_unix.c | 2 +- ext/calendar/calendar.c | 2 +- ext/calendar/easter.c | 2 +- ext/com_dotnet/com_com.c | 2 +- ext/com_dotnet/com_dotnet.c | 2 +- ext/com_dotnet/com_extension.c | 2 +- ext/com_dotnet/com_handlers.c | 2 +- ext/com_dotnet/com_iterator.c | 2 +- ext/com_dotnet/com_misc.c | 2 +- ext/com_dotnet/com_olechar.c | 2 +- ext/com_dotnet/com_persist.c | 2 +- ext/com_dotnet/com_saproxy.c | 2 +- ext/com_dotnet/com_typeinfo.c | 2 +- ext/com_dotnet/com_variant.c | 2 +- ext/com_dotnet/com_wrapper.c | 2 +- ext/com_dotnet/php_com_dotnet.h | 2 +- ext/com_dotnet/php_com_dotnet_internal.h | 2 +- ext/ctype/ctype.c | 2 +- ext/ctype/php_ctype.h | 2 +- ext/curl/interface.c | 2 +- ext/curl/multi.c | 2 +- ext/curl/php_curl.h | 2 +- ext/curl/share.c | 2 +- ext/curl/streams.c | 2 +- ext/date/lib/astro.c | 2 +- ext/date/lib/dow.c | 2 +- ext/date/lib/interval.c | 2 +- ext/date/lib/parse_date.c | 2 +- ext/date/lib/parse_date.re | 2 +- ext/date/lib/parse_iso_intervals.c | 2 +- ext/date/lib/parse_iso_intervals.re | 2 +- ext/date/lib/parse_tz.c | 2 +- ext/date/lib/timelib.c | 2 +- ext/date/lib/timelib.h | 2 +- ext/date/lib/timelib_structs.h | 2 +- ext/date/lib/tm2unixtime.c | 2 +- ext/date/lib/unixtime2tm.c | 2 +- ext/date/php_date.c | 2 +- ext/date/php_date.h | 2 +- ext/dba/dba.c | 2 +- ext/dba/dba_cdb.c | 2 +- ext/dba/dba_db1.c | 2 +- ext/dba/dba_db2.c | 2 +- ext/dba/dba_db3.c | 2 +- ext/dba/dba_db4.c | 2 +- ext/dba/dba_dbm.c | 2 +- ext/dba/dba_flatfile.c | 2 +- ext/dba/dba_gdbm.c | 2 +- ext/dba/dba_inifile.c | 2 +- ext/dba/dba_ndbm.c | 2 +- ext/dba/dba_qdbm.c | 2 +- ext/dba/dba_tcadb.c | 2 +- ext/dba/libcdb/cdb.c | 2 +- ext/dba/libcdb/cdb.h | 2 +- ext/dba/libcdb/cdb_make.c | 2 +- ext/dba/libcdb/cdb_make.h | 2 +- ext/dba/libcdb/uint32.c | 2 +- ext/dba/libcdb/uint32.h | 2 +- ext/dba/libflatfile/flatfile.c | 2 +- ext/dba/libflatfile/flatfile.h | 2 +- ext/dba/libinifile/inifile.c | 2 +- ext/dba/libinifile/inifile.h | 2 +- ext/dba/php_dba.h | 2 +- ext/dba/php_tcadb.h | 2 +- ext/dom/attr.c | 2 +- ext/dom/cdatasection.c | 2 +- ext/dom/characterdata.c | 2 +- ext/dom/comment.c | 2 +- ext/dom/document.c | 2 +- ext/dom/documentfragment.c | 2 +- ext/dom/documenttype.c | 2 +- ext/dom/dom_ce.h | 2 +- ext/dom/dom_fe.h | 2 +- ext/dom/dom_iterators.c | 2 +- ext/dom/dom_properties.h | 2 +- ext/dom/domconfiguration.c | 2 +- ext/dom/domerror.c | 2 +- ext/dom/domerrorhandler.c | 2 +- ext/dom/domexception.c | 2 +- ext/dom/domimplementation.c | 2 +- ext/dom/domimplementationlist.c | 2 +- ext/dom/domimplementationsource.c | 2 +- ext/dom/domlocator.c | 2 +- ext/dom/domstringlist.c | 2 +- ext/dom/element.c | 2 +- ext/dom/entity.c | 2 +- ext/dom/entityreference.c | 2 +- ext/dom/namednodemap.c | 2 +- ext/dom/namelist.c | 2 +- ext/dom/node.c | 2 +- ext/dom/nodelist.c | 2 +- ext/dom/notation.c | 2 +- ext/dom/php_dom.c | 2 +- ext/dom/php_dom.h | 2 +- ext/dom/processinginstruction.c | 2 +- ext/dom/string_extend.c | 2 +- ext/dom/text.c | 2 +- ext/dom/typeinfo.c | 2 +- ext/dom/userdatahandler.c | 2 +- ext/dom/xml_common.h | 2 +- ext/dom/xpath.c | 2 +- ext/enchant/enchant.c | 2 +- ext/enchant/php_enchant.h | 2 +- ext/ereg/ereg.c | 2 +- ext/ereg/php_ereg.h | 2 +- ext/ereg/php_regex.h | 2 +- ext/exif/exif.c | 2 +- ext/exif/php_exif.h | 2 +- ext/fileinfo/fileinfo.c | 2 +- ext/fileinfo/php_fileinfo.h | 2 +- ext/filter/callback_filter.c | 2 +- ext/filter/filter.c | 2 +- ext/filter/filter_private.h | 2 +- ext/filter/logical_filters.c | 2 +- ext/filter/php_filter.h | 2 +- ext/filter/sanitizing_filters.c | 2 +- ext/ftp/ftp.c | 2 +- ext/ftp/ftp.h | 2 +- ext/ftp/php_ftp.c | 2 +- ext/ftp/php_ftp.h | 2 +- ext/gd/gd.c | 2 +- ext/gd/gd_ctx.c | 2 +- ext/gd/libgd/xbm.c | 2 +- ext/gd/php_gd.h | 2 +- ext/gettext/gettext.c | 2 +- ext/gettext/php_gettext.h | 2 +- ext/gmp/gmp.c | 2 +- ext/gmp/php_gmp.h | 2 +- ext/hash/hash.c | 2 +- ext/hash/hash_adler32.c | 2 +- ext/hash/hash_crc32.c | 2 +- ext/hash/hash_fnv.c | 2 +- ext/hash/hash_gost.c | 2 +- ext/hash/hash_haval.c | 2 +- ext/hash/hash_joaat.c | 2 +- ext/hash/hash_md.c | 2 +- ext/hash/hash_ripemd.c | 2 +- ext/hash/hash_sha.c | 2 +- ext/hash/hash_snefru.c | 2 +- ext/hash/hash_tiger.c | 2 +- ext/hash/hash_whirlpool.c | 2 +- ext/hash/php_hash.h | 2 +- ext/hash/php_hash_adler32.h | 2 +- ext/hash/php_hash_crc32.h | 2 +- ext/hash/php_hash_crc32_tables.h | 2 +- ext/hash/php_hash_fnv.h | 2 +- ext/hash/php_hash_gost.h | 2 +- ext/hash/php_hash_haval.h | 2 +- ext/hash/php_hash_joaat.h | 2 +- ext/hash/php_hash_md.h | 2 +- ext/hash/php_hash_ripemd.h | 2 +- ext/hash/php_hash_sha.h | 2 +- ext/hash/php_hash_snefru.h | 2 +- ext/hash/php_hash_snefru_tables.h | 2 +- ext/hash/php_hash_tiger.h | 2 +- ext/hash/php_hash_tiger_tables.h | 2 +- ext/hash/php_hash_types.h | 2 +- ext/hash/php_hash_whirlpool.h | 2 +- ext/hash/php_hash_whirlpool_tables.h | 2 +- ext/iconv/iconv.c | 2 +- ext/iconv/php_iconv.h | 2 +- ext/imap/php_imap.c | 2 +- ext/imap/php_imap.h | 2 +- ext/interbase/ibase_blobs.c | 2 +- ext/interbase/ibase_events.c | 2 +- ext/interbase/ibase_query.c | 2 +- ext/interbase/ibase_service.c | 2 +- ext/interbase/interbase.c | 2 +- ext/interbase/php_ibase_includes.h | 2 +- ext/interbase/php_ibase_udf.c | 2 +- ext/interbase/php_interbase.h | 2 +- ext/json/json.c | 2 +- ext/json/php_json.h | 2 +- ext/ldap/ldap.c | 2 +- ext/ldap/php_ldap.h | 2 +- ext/libxml/libxml.c | 2 +- ext/libxml/php_libxml.h | 2 +- ext/mbstring/mb_gpc.c | 2 +- ext/mbstring/mbstring.c | 2 +- ext/mbstring/mbstring.h | 2 +- ext/mbstring/php_mbregex.c | 2 +- ext/mbstring/php_mbregex.h | 2 +- ext/mbstring/php_unicode.c | 2 +- ext/mbstring/php_unicode.h | 2 +- ext/mcrypt/mcrypt.c | 2 +- ext/mcrypt/mcrypt_filter.c | 2 +- ext/mcrypt/php_mcrypt.h | 2 +- ext/mcrypt/php_mcrypt_filter.h | 2 +- ext/mssql/php_mssql.c | 2 +- ext/mssql/php_mssql.h | 2 +- ext/mysql/php_mysql.c | 2 +- ext/mysql/php_mysql.h | 2 +- ext/mysql/php_mysql_structs.h | 2 +- ext/mysqli/mysqli.c | 2 +- ext/mysqli/mysqli_api.c | 2 +- ext/mysqli/mysqli_driver.c | 2 +- ext/mysqli/mysqli_embedded.c | 2 +- ext/mysqli/mysqli_exception.c | 2 +- ext/mysqli/mysqli_fe.c | 2 +- ext/mysqli/mysqli_fe.h | 2 +- ext/mysqli/mysqli_libmysql.h | 2 +- ext/mysqli/mysqli_nonapi.c | 2 +- ext/mysqli/mysqli_priv.h | 2 +- ext/mysqli/mysqli_prop.c | 2 +- ext/mysqli/mysqli_report.c | 2 +- ext/mysqli/mysqli_result_iterator.c | 2 +- ext/mysqli/mysqli_warning.c | 2 +- ext/mysqli/php_mysqli.h | 2 +- ext/mysqli/php_mysqli_structs.h | 2 +- ext/oci8/oci8.c | 2 +- ext/oci8/oci8_collection.c | 2 +- ext/oci8/oci8_interface.c | 2 +- ext/oci8/oci8_lob.c | 2 +- ext/oci8/oci8_statement.c | 2 +- ext/oci8/php_oci8.h | 2 +- ext/oci8/php_oci8_int.h | 2 +- ext/odbc/birdstep.c | 2 +- ext/odbc/php_birdstep.h | 2 +- ext/odbc/php_odbc.c | 2 +- ext/odbc/php_odbc.h | 2 +- ext/odbc/php_odbc_includes.h | 2 +- ext/openssl/openssl.c | 2 +- ext/openssl/php_openssl.h | 2 +- ext/openssl/xp_ssl.c | 2 +- ext/pcntl/pcntl.c | 2 +- ext/pcntl/php_pcntl.h | 2 +- ext/pcntl/php_signal.c | 2 +- ext/pcntl/php_signal.h | 2 +- ext/pcre/php_pcre.c | 2 +- ext/pcre/php_pcre.h | 2 +- ext/pdo/pdo.c | 2 +- ext/pdo/pdo_dbh.c | 2 +- ext/pdo/pdo_sql_parser.c | 2 +- ext/pdo/pdo_sql_parser.re | 2 +- ext/pdo/pdo_sqlstate.c | 2 +- ext/pdo/pdo_stmt.c | 2 +- ext/pdo/php_pdo.h | 2 +- ext/pdo/php_pdo_driver.h | 2 +- ext/pdo/php_pdo_int.h | 2 +- ext/pdo_dblib/dblib_driver.c | 2 +- ext/pdo_dblib/dblib_stmt.c | 2 +- ext/pdo_dblib/pdo_dblib.c | 2 +- ext/pdo_dblib/php_pdo_dblib.h | 2 +- ext/pdo_dblib/php_pdo_dblib_int.h | 2 +- ext/pdo_firebird/firebird_driver.c | 2 +- ext/pdo_firebird/firebird_statement.c | 2 +- ext/pdo_firebird/pdo_firebird.c | 2 +- ext/pdo_firebird/php_pdo_firebird.h | 2 +- ext/pdo_firebird/php_pdo_firebird_int.h | 2 +- ext/pdo_mysql/mysql_driver.c | 2 +- ext/pdo_mysql/mysql_statement.c | 2 +- ext/pdo_mysql/pdo_mysql.c | 2 +- ext/pdo_mysql/php_pdo_mysql.h | 2 +- ext/pdo_mysql/php_pdo_mysql_int.h | 2 +- ext/pdo_oci/oci_driver.c | 2 +- ext/pdo_oci/oci_statement.c | 2 +- ext/pdo_oci/pdo_oci.c | 2 +- ext/pdo_oci/php_pdo_oci.h | 2 +- ext/pdo_oci/php_pdo_oci_int.h | 2 +- ext/pdo_odbc/odbc_driver.c | 2 +- ext/pdo_odbc/odbc_stmt.c | 2 +- ext/pdo_odbc/pdo_odbc.c | 2 +- ext/pdo_odbc/php_pdo_odbc.h | 2 +- ext/pdo_odbc/php_pdo_odbc_int.h | 2 +- ext/pdo_pgsql/pdo_pgsql.c | 2 +- ext/pdo_pgsql/pgsql_driver.c | 2 +- ext/pdo_pgsql/pgsql_statement.c | 2 +- ext/pdo_pgsql/php_pdo_pgsql.h | 2 +- ext/pdo_pgsql/php_pdo_pgsql_int.h | 2 +- ext/pdo_sqlite/pdo_sqlite.c | 2 +- ext/pdo_sqlite/php_pdo_sqlite.h | 2 +- ext/pdo_sqlite/php_pdo_sqlite_int.h | 2 +- ext/pdo_sqlite/sqlite_driver.c | 2 +- ext/pdo_sqlite/sqlite_statement.c | 2 +- ext/pgsql/pgsql.c | 2 +- ext/pgsql/php_pgsql.h | 2 +- ext/posix/php_posix.h | 2 +- ext/posix/posix.c | 2 +- ext/pspell/php_pspell.h | 2 +- ext/pspell/pspell.c | 2 +- ext/readline/php_readline.h | 2 +- ext/readline/readline.c | 2 +- ext/readline/readline_cli.c | 2 +- ext/readline/readline_cli.h | 2 +- ext/recode/php_recode.h | 2 +- ext/recode/recode.c | 2 +- ext/reflection/php_reflection.c | 2 +- ext/reflection/php_reflection.h | 2 +- ext/session/mod_files.c | 2 +- ext/session/mod_files.h | 2 +- ext/session/mod_mm.c | 2 +- ext/session/mod_mm.h | 2 +- ext/session/mod_user.c | 2 +- ext/session/mod_user.h | 2 +- ext/session/mod_user_class.c | 2 +- ext/session/php_session.h | 2 +- ext/session/session.c | 2 +- ext/shmop/php_shmop.h | 2 +- ext/shmop/shmop.c | 2 +- ext/simplexml/php_simplexml.h | 2 +- ext/simplexml/php_simplexml_exports.h | 2 +- ext/simplexml/simplexml.c | 2 +- ext/simplexml/sxe.c | 2 +- ext/simplexml/sxe.h | 2 +- ext/snmp/php_snmp.h | 2 +- ext/snmp/snmp.c | 2 +- ext/soap/php_encoding.c | 2 +- ext/soap/php_encoding.h | 2 +- ext/soap/php_http.c | 2 +- ext/soap/php_http.h | 2 +- ext/soap/php_packet_soap.c | 2 +- ext/soap/php_packet_soap.h | 2 +- ext/soap/php_schema.c | 2 +- ext/soap/php_schema.h | 2 +- ext/soap/php_sdl.c | 2 +- ext/soap/php_sdl.h | 2 +- ext/soap/php_soap.h | 2 +- ext/soap/php_xml.c | 2 +- ext/soap/php_xml.h | 2 +- ext/soap/soap.c | 2 +- ext/sockets/multicast.c | 2 +- ext/sockets/multicast.h | 2 +- ext/sockets/php_sockets.h | 2 +- ext/sockets/sockets.c | 2 +- ext/sockets/unix_socket_constants.h | 2 +- ext/sockets/win32_socket_constants.h | 2 +- ext/spl/php_spl.c | 2 +- ext/spl/php_spl.h | 2 +- ext/spl/spl_array.c | 2 +- ext/spl/spl_array.h | 2 +- ext/spl/spl_directory.c | 2 +- ext/spl/spl_directory.h | 2 +- ext/spl/spl_dllist.c | 2 +- ext/spl/spl_dllist.h | 2 +- ext/spl/spl_engine.c | 2 +- ext/spl/spl_engine.h | 2 +- ext/spl/spl_exceptions.c | 2 +- ext/spl/spl_exceptions.h | 2 +- ext/spl/spl_fixedarray.c | 2 +- ext/spl/spl_fixedarray.h | 2 +- ext/spl/spl_functions.c | 2 +- ext/spl/spl_functions.h | 2 +- ext/spl/spl_heap.c | 2 +- ext/spl/spl_heap.h | 2 +- ext/spl/spl_iterators.c | 2 +- ext/spl/spl_iterators.h | 2 +- ext/spl/spl_observer.c | 2 +- ext/spl/spl_observer.h | 2 +- ext/sqlite3/php_sqlite3.h | 2 +- ext/sqlite3/php_sqlite3_structs.h | 2 +- ext/sqlite3/sqlite3.c | 2 +- ext/standard/array.c | 2 +- ext/standard/assert.c | 2 +- ext/standard/base64.c | 2 +- ext/standard/base64.h | 2 +- ext/standard/basic_functions.c | 2 +- ext/standard/basic_functions.h | 2 +- ext/standard/browscap.c | 2 +- ext/standard/crc32.c | 2 +- ext/standard/crc32.h | 2 +- ext/standard/credits.c | 2 +- ext/standard/credits.h | 2 +- ext/standard/crypt.c | 2 +- ext/standard/css.c | 2 +- ext/standard/css.h | 2 +- ext/standard/cyr_convert.c | 2 +- ext/standard/cyr_convert.h | 2 +- ext/standard/datetime.c | 2 +- ext/standard/datetime.h | 2 +- ext/standard/dir.c | 2 +- ext/standard/dl.c | 2 +- ext/standard/dl.h | 2 +- ext/standard/dns.c | 2 +- ext/standard/exec.c | 2 +- ext/standard/exec.h | 2 +- ext/standard/file.c | 2 +- ext/standard/file.h | 2 +- ext/standard/filestat.c | 2 +- ext/standard/filters.c | 2 +- ext/standard/flock_compat.c | 2 +- ext/standard/flock_compat.h | 2 +- ext/standard/formatted_print.c | 2 +- ext/standard/fsock.c | 2 +- ext/standard/fsock.h | 2 +- ext/standard/ftok.c | 2 +- ext/standard/ftp_fopen_wrapper.c | 2 +- ext/standard/head.c | 2 +- ext/standard/head.h | 2 +- ext/standard/html.c | 2 +- ext/standard/html.h | 2 +- ext/standard/html_tables.h | 2 +- ext/standard/http.c | 2 +- ext/standard/http_fopen_wrapper.c | 2 +- ext/standard/image.c | 2 +- ext/standard/incomplete_class.c | 2 +- ext/standard/info.c | 2 +- ext/standard/info.h | 2 +- ext/standard/iptc.c | 2 +- ext/standard/lcg.c | 2 +- ext/standard/levenshtein.c | 2 +- ext/standard/link.c | 2 +- ext/standard/link_win32.c | 2 +- ext/standard/mail.c | 2 +- ext/standard/math.c | 2 +- ext/standard/md5.c | 2 +- ext/standard/md5.h | 2 +- ext/standard/metaphone.c | 2 +- ext/standard/microtime.c | 2 +- ext/standard/microtime.h | 2 +- ext/standard/pack.c | 2 +- ext/standard/pack.h | 2 +- ext/standard/pageinfo.c | 2 +- ext/standard/pageinfo.h | 2 +- ext/standard/password.c | 2 +- ext/standard/php_array.h | 2 +- ext/standard/php_assert.h | 2 +- ext/standard/php_browscap.h | 2 +- ext/standard/php_crypt.h | 2 +- ext/standard/php_crypt_r.c | 2 +- ext/standard/php_crypt_r.h | 2 +- ext/standard/php_dir.h | 2 +- ext/standard/php_dns.h | 2 +- ext/standard/php_ext_syslog.h | 2 +- ext/standard/php_filestat.h | 2 +- ext/standard/php_fopen_wrapper.c | 2 +- ext/standard/php_fopen_wrappers.h | 2 +- ext/standard/php_ftok.h | 2 +- ext/standard/php_http.h | 2 +- ext/standard/php_image.h | 2 +- ext/standard/php_incomplete_class.h | 2 +- ext/standard/php_iptc.h | 2 +- ext/standard/php_lcg.h | 2 +- ext/standard/php_link.h | 2 +- ext/standard/php_mail.h | 2 +- ext/standard/php_math.h | 2 +- ext/standard/php_metaphone.h | 2 +- ext/standard/php_password.h | 2 +- ext/standard/php_rand.h | 2 +- ext/standard/php_smart_str.h | 2 +- ext/standard/php_smart_str_public.h | 2 +- ext/standard/php_standard.h | 2 +- ext/standard/php_string.h | 2 +- ext/standard/php_type.h | 2 +- ext/standard/php_uuencode.h | 2 +- ext/standard/php_var.h | 2 +- ext/standard/php_versioning.h | 2 +- ext/standard/proc_open.c | 2 +- ext/standard/proc_open.h | 2 +- ext/standard/quot_print.c | 2 +- ext/standard/quot_print.h | 2 +- ext/standard/rand.c | 2 +- ext/standard/scanf.c | 2 +- ext/standard/scanf.h | 2 +- ext/standard/sha1.c | 2 +- ext/standard/sha1.h | 2 +- ext/standard/soundex.c | 2 +- ext/standard/streamsfuncs.c | 2 +- ext/standard/streamsfuncs.h | 2 +- ext/standard/string.c | 2 +- ext/standard/syslog.c | 2 +- ext/standard/type.c | 2 +- ext/standard/uniqid.c | 2 +- ext/standard/uniqid.h | 2 +- ext/standard/url.c | 2 +- ext/standard/url.h | 2 +- ext/standard/url_scanner_ex.c | 2 +- ext/standard/url_scanner_ex.h | 2 +- ext/standard/url_scanner_ex.re | 2 +- ext/standard/user_filters.c | 2 +- ext/standard/uuencode.c | 2 +- ext/standard/var.c | 2 +- ext/standard/var_unserializer.c | 2 +- ext/standard/var_unserializer.re | 2 +- ext/standard/versioning.c | 2 +- ext/sybase_ct/php_sybase_ct.c | 2 +- ext/sybase_ct/php_sybase_ct.h | 2 +- ext/sysvmsg/php_sysvmsg.h | 2 +- ext/sysvmsg/sysvmsg.c | 2 +- ext/sysvsem/php_sysvsem.h | 2 +- ext/sysvsem/sysvsem.c | 2 +- ext/sysvshm/php_sysvshm.h | 2 +- ext/sysvshm/sysvshm.c | 2 +- ext/tidy/php_tidy.h | 2 +- ext/tidy/tidy.c | 2 +- ext/tokenizer/php_tokenizer.h | 2 +- ext/tokenizer/tokenizer.c | 2 +- ext/tokenizer/tokenizer_data.c | 2 +- ext/tokenizer/tokenizer_data_gen.sh | 2 +- ext/wddx/php_wddx.h | 2 +- ext/wddx/php_wddx_api.h | 2 +- ext/wddx/wddx.c | 2 +- ext/xml/compat.c | 2 +- ext/xml/expat_compat.h | 2 +- ext/xml/php_xml.h | 2 +- ext/xml/xml.c | 2 +- ext/xmlreader/php_xmlreader.c | 2 +- ext/xmlreader/php_xmlreader.h | 2 +- ext/xmlrpc/php_xmlrpc.h | 2 +- ext/xmlrpc/xmlrpc-epi-php.c | 2 +- ext/xmlwriter/php_xmlwriter.c | 2 +- ext/xmlwriter/php_xmlwriter.h | 2 +- ext/xsl/php_xsl.c | 2 +- ext/xsl/php_xsl.h | 2 +- ext/xsl/xsl_fe.h | 2 +- ext/xsl/xsltprocessor.c | 2 +- ext/zip/php_zip.c | 2 +- ext/zip/php_zip.h | 2 +- ext/zlib/php_zlib.h | 2 +- ext/zlib/zlib.c | 2 +- ext/zlib/zlib_filter.c | 2 +- ext/zlib/zlib_fopen_wrapper.c | 2 +- header | 2 +- main/SAPI.c | 2 +- main/SAPI.h | 2 +- main/fopen_wrappers.c | 2 +- main/fopen_wrappers.h | 2 +- main/getopt.c | 2 +- main/internal_functions_nw.c | 2 +- main/internal_functions_win32.c | 2 +- main/main.c | 2 +- main/network.c | 2 +- main/output.c | 2 +- main/php.h | 2 +- main/php_compat.h | 2 +- main/php_content_types.c | 2 +- main/php_content_types.h | 2 +- main/php_getopt.h | 2 +- main/php_globals.h | 2 +- main/php_ini.c | 2 +- main/php_ini.h | 2 +- main/php_main.h | 2 +- main/php_memory_streams.h | 2 +- main/php_network.h | 2 +- main/php_open_temporary_file.c | 2 +- main/php_open_temporary_file.h | 2 +- main/php_output.h | 2 +- main/php_reentrancy.h | 2 +- main/php_scandir.c | 2 +- main/php_scandir.h | 2 +- main/php_sprintf.c | 2 +- main/php_streams.h | 2 +- main/php_syslog.h | 2 +- main/php_ticks.c | 2 +- main/php_ticks.h | 2 +- main/php_variables.c | 2 +- main/php_variables.h | 2 +- main/reentrancy.c | 2 +- main/rfc1867.c | 2 +- main/rfc1867.h | 2 +- main/snprintf.c | 2 +- main/snprintf.h | 2 +- main/spprintf.c | 2 +- main/spprintf.h | 2 +- main/streams/cast.c | 2 +- main/streams/filter.c | 2 +- main/streams/glob_wrapper.c | 2 +- main/streams/memory.c | 2 +- main/streams/mmap.c | 2 +- main/streams/php_stream_context.h | 2 +- main/streams/php_stream_filter_api.h | 2 +- main/streams/php_stream_glob_wrapper.h | 2 +- main/streams/php_stream_mmap.h | 2 +- main/streams/php_stream_plain_wrapper.h | 2 +- main/streams/php_stream_transport.h | 2 +- main/streams/php_stream_userspace.h | 2 +- main/streams/php_streams_int.h | 2 +- main/streams/plain_wrapper.c | 2 +- main/streams/streams.c | 2 +- main/streams/transports.c | 2 +- main/streams/userspace.c | 2 +- main/streams/xp_socket.c | 2 +- main/strlcat.c | 2 +- main/strlcpy.c | 2 +- main/win32_internal_function_disabled.h | 2 +- main/win95nt.h | 2 +- netware/start.c | 2 +- sapi/aolserver/aolserver.c | 2 +- sapi/apache/libpre.c | 2 +- sapi/apache/mod_php5.c | 2 +- sapi/apache/mod_php5.h | 2 +- sapi/apache/php_apache.c | 2 +- sapi/apache/php_apache_http.h | 2 +- sapi/apache/sapi_apache.c | 2 +- sapi/apache2filter/apache_config.c | 2 +- sapi/apache2filter/php_apache.h | 2 +- sapi/apache2filter/php_functions.c | 2 +- sapi/apache2filter/sapi_apache2.c | 2 +- sapi/apache2handler/apache_config.c | 2 +- sapi/apache2handler/mod_php5.c | 2 +- sapi/apache2handler/php_apache.h | 2 +- sapi/apache2handler/php_functions.c | 2 +- sapi/apache2handler/sapi_apache2.c | 2 +- sapi/apache_hooks/mod_php5.c | 2 +- sapi/apache_hooks/mod_php5.h | 2 +- sapi/apache_hooks/php_apache.c | 2 +- sapi/apache_hooks/sapi_apache.c | 2 +- sapi/caudium/caudium.c | 2 +- sapi/cgi/cgi_main.c | 6 +++--- sapi/cgi/fastcgi.c | 2 +- sapi/cgi/fastcgi.h | 2 +- sapi/cli/cli.h | 2 +- sapi/cli/php_cli.c | 4 ++-- sapi/cli/php_cli_server.c | 2 +- sapi/cli/php_cli_server.h | 2 +- sapi/continuity/capi.c | 2 +- sapi/embed/php_embed.c | 2 +- sapi/embed/php_embed.h | 2 +- sapi/fpm/fpm/events/devpoll.c | 2 +- sapi/fpm/fpm/events/devpoll.h | 2 +- sapi/fpm/fpm/events/epoll.c | 2 +- sapi/fpm/fpm/events/epoll.h | 2 +- sapi/fpm/fpm/events/kqueue.c | 2 +- sapi/fpm/fpm/events/kqueue.h | 2 +- sapi/fpm/fpm/events/poll.c | 2 +- sapi/fpm/fpm/events/poll.h | 2 +- sapi/fpm/fpm/events/port.c | 2 +- sapi/fpm/fpm/events/port.h | 2 +- sapi/fpm/fpm/events/select.c | 2 +- sapi/fpm/fpm/events/select.h | 2 +- sapi/fpm/fpm/fastcgi.c | 2 +- sapi/fpm/fpm/fastcgi.h | 2 +- sapi/fpm/fpm/fpm_main.c | 6 +++--- sapi/isapi/php5isapi.c | 2 +- sapi/litespeed/lsapi_main.c | 6 +++--- sapi/litespeed/lsapidef.h | 2 +- sapi/litespeed/lsapilib.c | 2 +- sapi/litespeed/lsapilib.h | 2 +- sapi/milter/php_milter.c | 4 ++-- sapi/nsapi/nsapi.c | 2 +- sapi/phttpd/php_phttpd.h | 2 +- sapi/phttpd/phttpd.c | 2 +- sapi/pi3web/pi3web_sapi.c | 2 +- sapi/roxen/roxen.c | 2 +- sapi/thttpd/php_thttpd.h | 2 +- sapi/thttpd/thttpd.c | 2 +- sapi/tux/php_tux.c | 2 +- sapi/webjames/php_webjames.h | 2 +- sapi/webjames/webjames.c | 2 +- win32/build/deplister.c | 2 +- win32/build/template.rc | 2 +- win32/globals.c | 2 +- win32/grp.h | 2 +- win32/php_win32_globals.h | 2 +- win32/select.c | 2 +- win32/select.h | 2 +- win32/sockets.c | 2 +- win32/sockets.h | 2 +- win32/syslog.h | 2 +- win32/winutil.c | 2 +- win32/winutil.h | 2 +- 759 files changed, 769 insertions(+), 769 deletions(-) diff --git a/TSRM/tsrm_nw.c b/TSRM/tsrm_nw.c index 3b043074fd764..d9963faad1f30 100644 --- a/TSRM/tsrm_nw.c +++ b/TSRM/tsrm_nw.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/TSRM/tsrm_nw.h b/TSRM/tsrm_nw.h index f76671e2db623..1f93bd535d6c7 100644 --- a/TSRM/tsrm_nw.h +++ b/TSRM/tsrm_nw.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c index 6779b56974a9c..3e211fa54f9a2 100644 --- a/TSRM/tsrm_virtual_cwd.c +++ b/TSRM/tsrm_virtual_cwd.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/TSRM/tsrm_virtual_cwd.h b/TSRM/tsrm_virtual_cwd.h index 2c4085894f34f..8aac4aa2671ec 100644 --- a/TSRM/tsrm_virtual_cwd.h +++ b/TSRM/tsrm_virtual_cwd.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/TSRM/tsrm_win32.c b/TSRM/tsrm_win32.c index c33b5991474af..0ced6db451bfe 100644 --- a/TSRM/tsrm_win32.c +++ b/TSRM/tsrm_win32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/TSRM/tsrm_win32.h b/TSRM/tsrm_win32.h index 56835f802b9d5..c77f69c7f119e 100644 --- a/TSRM/tsrm_win32.h +++ b/TSRM/tsrm_win32.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend.c b/Zend/zend.c index fc6aed08cc37e..dee55fcef1dec 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | @@ -131,7 +131,7 @@ ZEND_API zval zval_used_for_init; /* True global variable */ /* version information */ static char *zend_version_info; static uint zend_version_info_length; -#define ZEND_CORE_VERSION_INFO "Zend Engine v" ZEND_VERSION ", Copyright (c) 1998-2012 Zend Technologies\n" +#define ZEND_CORE_VERSION_INFO "Zend Engine v" ZEND_VERSION ", Copyright (c) 1998-2013 Zend Technologies\n" #define PRINT_ZVAL_INDENT 4 static void print_hash(zend_write_func_t write_func, HashTable *ht, int indent, zend_bool is_object TSRMLS_DC) /* {{{ */ diff --git a/Zend/zend.h b/Zend/zend.h index 444b71ed64d2b..aed03d87150da 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 6dadd4d06016d..eec4ab0bb1529 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_API.h b/Zend/zend_API.h index d7fbc3c3afd1d..4a3985e0f4b38 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 155ae88b6bc20..1cc2c678334f9 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_alloc.h b/Zend/zend_alloc.h index 6b071c28947e7..0b4e74d8971a2 100644 --- a/Zend/zend_alloc.h +++ b/Zend/zend_alloc.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_build.h b/Zend/zend_build.h index 042f50e80710c..152e1bd44a69e 100644 --- a/Zend/zend_build.h +++ b/Zend/zend_build.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 698ef72e544be..7bbb04785efc8 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_builtin_functions.h b/Zend/zend_builtin_functions.h index a53bfb65a177e..e1af53637d55b 100644 --- a/Zend/zend_builtin_functions.h +++ b/Zend/zend_builtin_functions.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_closures.c b/Zend/zend_closures.c index c7527b4ff97df..a37397543b89b 100644 --- a/Zend/zend_closures.c +++ b/Zend/zend_closures.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_closures.h b/Zend/zend_closures.h index c540b554c9663..c41cf475603fb 100644 --- a/Zend/zend_closures.h +++ b/Zend/zend_closures.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 4564448045c92..2e0dcd6b72b9e 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index fb6ea1724cf34..d2ab0607b5b57 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_config.nw.h b/Zend/zend_config.nw.h index a6490a6cd6665..04f80bfe72cd2 100644 --- a/Zend/zend_config.nw.h +++ b/Zend/zend_config.nw.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_config.w32.h b/Zend/zend_config.w32.h index 2c41e0da8bf35..73bd0525ba52d 100644 --- a/Zend/zend_config.w32.h +++ b/Zend/zend_config.w32.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_constants.c b/Zend/zend_constants.c index 03b6309cc339c..21580d3d5f607 100644 --- a/Zend/zend_constants.c +++ b/Zend/zend_constants.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_constants.h b/Zend/zend_constants.h index af8ec56e81579..c7261946c826f 100644 --- a/Zend/zend_constants.h +++ b/Zend/zend_constants.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_default_classes.c b/Zend/zend_default_classes.c index bcc43ea7db142..46b00eac4e43a 100644 --- a/Zend/zend_default_classes.c +++ b/Zend/zend_default_classes.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_dynamic_array.c b/Zend/zend_dynamic_array.c index 59511dddf53ea..543479c43e863 100644 --- a/Zend/zend_dynamic_array.c +++ b/Zend/zend_dynamic_array.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_dynamic_array.h b/Zend/zend_dynamic_array.h index 1fcf50982ae27..2c96f8543740e 100644 --- a/Zend/zend_dynamic_array.h +++ b/Zend/zend_dynamic_array.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_errors.h b/Zend/zend_errors.h index 1774a353b1fd5..a2cdc20a60211 100644 --- a/Zend/zend_errors.h +++ b/Zend/zend_errors.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_exceptions.c b/Zend/zend_exceptions.c index 79f4ee6faceb6..f457b2846f9e6 100644 --- a/Zend/zend_exceptions.c +++ b/Zend/zend_exceptions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_exceptions.h b/Zend/zend_exceptions.h index a1a228868d7b4..82633530d61ad 100644 --- a/Zend/zend_exceptions.h +++ b/Zend/zend_exceptions.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 9e340483ee34b..49a241d9a14e2 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_execute.h b/Zend/zend_execute.h index 729015c37160d..a17f10b312e53 100644 --- a/Zend/zend_execute.h +++ b/Zend/zend_execute.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 010f5b780c686..f099784a42a89 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_extensions.c b/Zend/zend_extensions.c index 5c66b4a30c63e..2dd7cd4c598c9 100644 --- a/Zend/zend_extensions.c +++ b/Zend/zend_extensions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_extensions.h b/Zend/zend_extensions.h index 3c609164c6f3c..83cad7f38d648 100644 --- a/Zend/zend_extensions.h +++ b/Zend/zend_extensions.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_float.c b/Zend/zend_float.c index 75e42efd60faf..cd6fcf2a149db 100644 --- a/Zend/zend_float.c +++ b/Zend/zend_float.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_float.h b/Zend/zend_float.h index bcde0bb0e2256..a17ad5658b908 100644 --- a/Zend/zend_float.h +++ b/Zend/zend_float.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_gc.c b/Zend/zend_gc.c index e877eab75da41..7b83ddb54f907 100644 --- a/Zend/zend_gc.c +++ b/Zend/zend_gc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_gc.h b/Zend/zend_gc.h index ba30b3aa3badd..a443032686f6f 100644 --- a/Zend/zend_gc.h +++ b/Zend/zend_gc.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 9c65c534bd42f..c6c18a70751f8 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_generators.h b/Zend/zend_generators.h index 7e6da1371f841..9f37b93c45a15 100644 --- a/Zend/zend_generators.h +++ b/Zend/zend_generators.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_globals.h b/Zend/zend_globals.h index 6ad9768086f51..800bdc7f66bcf 100644 --- a/Zend/zend_globals.h +++ b/Zend/zend_globals.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_globals_macros.h b/Zend/zend_globals_macros.h index 7826e95480b57..9bb1b8026db81 100644 --- a/Zend/zend_globals_macros.h +++ b/Zend/zend_globals_macros.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_hash.c b/Zend/zend_hash.c index 2087d57296d33..0609d707f533f 100644 --- a/Zend/zend_hash.c +++ b/Zend/zend_hash.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_hash.h b/Zend/zend_hash.h index 1bd64394ac192..88c3bfb421ed0 100644 --- a/Zend/zend_hash.h +++ b/Zend/zend_hash.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_highlight.c b/Zend/zend_highlight.c index 7fe617451940e..c789cb719a01b 100644 --- a/Zend/zend_highlight.c +++ b/Zend/zend_highlight.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_highlight.h b/Zend/zend_highlight.h index 7923d35bec0ff..20adf349ae200 100644 --- a/Zend/zend_highlight.h +++ b/Zend/zend_highlight.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_indent.c b/Zend/zend_indent.c index f2cf6d9133e32..fea78d9c57daf 100644 --- a/Zend/zend_indent.c +++ b/Zend/zend_indent.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_indent.h b/Zend/zend_indent.h index 066bb984d1330..bba02a738b3dc 100644 --- a/Zend/zend_indent.h +++ b/Zend/zend_indent.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ini.c b/Zend/zend_ini.c index b8f65b7cf2470..2c74f20f6a426 100644 --- a/Zend/zend_ini.c +++ b/Zend/zend_ini.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ini.h b/Zend/zend_ini.h index 0f3eeb524be4c..2773ebb6c0a9c 100644 --- a/Zend/zend_ini.h +++ b/Zend/zend_ini.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ini_parser.y b/Zend/zend_ini_parser.y index 780dce3c85a55..2d428c3fe77d1 100644 --- a/Zend/zend_ini_parser.y +++ b/Zend/zend_ini_parser.y @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ini_scanner.c b/Zend/zend_ini_scanner.c index cb5f62ccf1868..35d9763bd9678 100644 --- a/Zend/zend_ini_scanner.c +++ b/Zend/zend_ini_scanner.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ini_scanner.h b/Zend/zend_ini_scanner.h index 16deace659318..2655fc8732321 100644 --- a/Zend/zend_ini_scanner.h +++ b/Zend/zend_ini_scanner.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ini_scanner.l b/Zend/zend_ini_scanner.l index 2a21e77dd5d7a..5fb28d4259598 100644 --- a/Zend/zend_ini_scanner.l +++ b/Zend/zend_ini_scanner.l @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_interfaces.c b/Zend/zend_interfaces.c index aee0d612db083..384b66da4b545 100644 --- a/Zend/zend_interfaces.c +++ b/Zend/zend_interfaces.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_interfaces.h b/Zend/zend_interfaces.h index e3e3629c5ba92..23547951ed7dd 100644 --- a/Zend/zend_interfaces.h +++ b/Zend/zend_interfaces.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_istdiostream.h b/Zend/zend_istdiostream.h index fbefb235709c4..d7edf172f07dd 100644 --- a/Zend/zend_istdiostream.h +++ b/Zend/zend_istdiostream.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_iterators.c b/Zend/zend_iterators.c index d0572b25c6180..f2c27fa63d632 100644 --- a/Zend/zend_iterators.c +++ b/Zend/zend_iterators.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_iterators.h b/Zend/zend_iterators.h index dba05850a8a39..b484102b20a18 100644 --- a/Zend/zend_iterators.h +++ b/Zend/zend_iterators.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index ad6cc45a12776..e65910d2d55ed 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c index 248f6185fa02b..f2ba6bf9d4d51 100644 --- a/Zend/zend_language_scanner.c +++ b/Zend/zend_language_scanner.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_language_scanner.h b/Zend/zend_language_scanner.h index c1a2313b2db8e..03ca911262c95 100644 --- a/Zend/zend_language_scanner.h +++ b/Zend/zend_language_scanner.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 9f1437bb5f28a..d44ba20e1bb74 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_list.c b/Zend/zend_list.c index a75d6846d8c91..e60deb1cd176a 100644 --- a/Zend/zend_list.c +++ b/Zend/zend_list.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_list.h b/Zend/zend_list.h index b33c09da86738..23f51140f551b 100644 --- a/Zend/zend_list.h +++ b/Zend/zend_list.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_llist.c b/Zend/zend_llist.c index 26baf4d958cf0..20f847c7812c7 100644 --- a/Zend/zend_llist.c +++ b/Zend/zend_llist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_llist.h b/Zend/zend_llist.h index 3f67258e36e09..0a03e6ce59ca0 100644 --- a/Zend/zend_llist.h +++ b/Zend/zend_llist.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_modules.h b/Zend/zend_modules.h index a4ed106cfc665..d4adcf5aac982 100644 --- a/Zend/zend_modules.h +++ b/Zend/zend_modules.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_multibyte.c b/Zend/zend_multibyte.c index 379f50b01fd2f..dafcf18393578 100644 --- a/Zend/zend_multibyte.c +++ b/Zend/zend_multibyte.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_multibyte.h b/Zend/zend_multibyte.h index 38b13c2d162d2..c537e133f84bd 100644 --- a/Zend/zend_multibyte.h +++ b/Zend/zend_multibyte.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_multiply.h b/Zend/zend_multiply.h index 33a86d7dd81e9..c3c9657f3b25e 100644 --- a/Zend/zend_multiply.h +++ b/Zend/zend_multiply.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_object_handlers.c b/Zend/zend_object_handlers.c index 3374b0b3cf3a0..a76dfb38acc4c 100644 --- a/Zend/zend_object_handlers.c +++ b/Zend/zend_object_handlers.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_object_handlers.h b/Zend/zend_object_handlers.h index d0d7a7b847a00..11635328c396a 100644 --- a/Zend/zend_object_handlers.h +++ b/Zend/zend_object_handlers.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_objects.c b/Zend/zend_objects.c index f7470fa578d11..ce6284439c321 100644 --- a/Zend/zend_objects.c +++ b/Zend/zend_objects.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_objects.h b/Zend/zend_objects.h index 3db9d2e641cef..17d8430fcea59 100644 --- a/Zend/zend_objects.h +++ b/Zend/zend_objects.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_objects_API.c b/Zend/zend_objects_API.c index 91b7676574cbf..4f3561e3d774d 100644 --- a/Zend/zend_objects_API.c +++ b/Zend/zend_objects_API.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_objects_API.h b/Zend/zend_objects_API.h index 12f1c068423bd..c973b7a20c3fc 100644 --- a/Zend/zend_objects_API.h +++ b/Zend/zend_objects_API.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_opcode.c b/Zend/zend_opcode.c index a40bc547b9da5..db0a40035b6d3 100644 --- a/Zend/zend_opcode.c +++ b/Zend/zend_opcode.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index cf3a908ade851..bccccd96be586 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 08a6b19bd44b9..d3f5e5a3d1bd8 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ptr_stack.c b/Zend/zend_ptr_stack.c index 9d82bba4750a9..9dbdb3ddd77a8 100644 --- a/Zend/zend_ptr_stack.c +++ b/Zend/zend_ptr_stack.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ptr_stack.h b/Zend/zend_ptr_stack.h index 9f6fc13161a8b..1099240796fb5 100644 --- a/Zend/zend_ptr_stack.h +++ b/Zend/zend_ptr_stack.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_qsort.c b/Zend/zend_qsort.c index 3797901d80b82..bf179904efe58 100644 --- a/Zend/zend_qsort.c +++ b/Zend/zend_qsort.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_qsort.h b/Zend/zend_qsort.h index b4e6588549073..58c99f26c2f58 100644 --- a/Zend/zend_qsort.h +++ b/Zend/zend_qsort.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_sprintf.c b/Zend/zend_sprintf.c index 41acec46f0cf4..79ee5a9d6fdd6 100644 --- a/Zend/zend_sprintf.c +++ b/Zend/zend_sprintf.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_stack.c b/Zend/zend_stack.c index cbc8a0043d5f3..3e7401f5ff686 100644 --- a/Zend/zend_stack.c +++ b/Zend/zend_stack.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_stack.h b/Zend/zend_stack.h index 8d09087467d56..f18dfeca7cf68 100644 --- a/Zend/zend_stack.h +++ b/Zend/zend_stack.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_static_allocator.c b/Zend/zend_static_allocator.c index 503a7c79d7eb3..1150deb570d7c 100644 --- a/Zend/zend_static_allocator.c +++ b/Zend/zend_static_allocator.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_static_allocator.h b/Zend/zend_static_allocator.h index bd20fa66af7e7..5556256535bd6 100644 --- a/Zend/zend_static_allocator.h +++ b/Zend/zend_static_allocator.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_stream.c b/Zend/zend_stream.c index 30cc3a5ba4664..835fdbbd7e8a3 100644 --- a/Zend/zend_stream.c +++ b/Zend/zend_stream.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_stream.h b/Zend/zend_stream.h index aff87eb6d1e36..a65d258957c9e 100644 --- a/Zend/zend_stream.h +++ b/Zend/zend_stream.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_string.c b/Zend/zend_string.c index 8e9009f9fdf17..ff7ee3fd81a22 100644 --- a/Zend/zend_string.c +++ b/Zend/zend_string.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_string.h b/Zend/zend_string.h index 0a4738466d7a8..ebf8c816c11ff 100644 --- a/Zend/zend_string.h +++ b/Zend/zend_string.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_strtod.h b/Zend/zend_strtod.h index 4516d203d54c4..aac17cea14531 100644 --- a/Zend/zend_strtod.h +++ b/Zend/zend_strtod.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ts_hash.c b/Zend/zend_ts_hash.c index 51c4b1de7d1f3..f517fe8560515 100644 --- a/Zend/zend_ts_hash.c +++ b/Zend/zend_ts_hash.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_ts_hash.h b/Zend/zend_ts_hash.h index 706b0b1f8167e..9a849e15aed5f 100644 --- a/Zend/zend_ts_hash.h +++ b/Zend/zend_ts_hash.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_types.h b/Zend/zend_types.h index f33138aaaebb2..3e68add3dc329 100644 --- a/Zend/zend_types.h +++ b/Zend/zend_types.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_variables.c b/Zend/zend_variables.c index 25a66a197c5e6..c0e1849eefa13 100644 --- a/Zend/zend_variables.c +++ b/Zend/zend_variables.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_variables.h b/Zend/zend_variables.h index eb9f0d22c7362..e52dbd7853e8d 100644 --- a/Zend/zend_variables.h +++ b/Zend/zend_variables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm.h b/Zend/zend_vm.h index bbf739e5b3b3d..c406c1a891fa0 100644 --- a/Zend/zend_vm.h +++ b/Zend/zend_vm.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 2c17182b9f049..82826c904a4f5 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index c51df01c2d38b..23f6187ae7d95 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm_gen.php b/Zend/zend_vm_gen.php index 42f17ed7c6529..63d0cf73f0d52 100644 --- a/Zend/zend_vm_gen.php +++ b/Zend/zend_vm_gen.php @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | @@ -24,7 +24,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/Zend/zend_vm_opcodes.h b/Zend/zend_vm_opcodes.h index 061d7e49b3a85..859258a440bef 100644 --- a/Zend/zend_vm_opcodes.h +++ b/Zend/zend_vm_opcodes.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | Zend Engine | +----------------------------------------------------------------------+ - | Copyright (c) 1998-2012 Zend Technologies Ltd. (http://www.zend.com) | + | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c index 5dfafa8bd8dbc..c5fbce94dde5c 100644 --- a/ext/bcmath/bcmath.c +++ b/ext/bcmath/bcmath.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/bcmath/php_bcmath.h b/ext/bcmath/php_bcmath.h index 2ea9212c77449..571993ed7b13e 100644 --- a/ext/bcmath/php_bcmath.h +++ b/ext/bcmath/php_bcmath.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c index c570a2dbf492a..65b06d79f5246 100644 --- a/ext/bz2/bz2.c +++ b/ext/bz2/bz2.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/bz2/bz2_filter.c b/ext/bz2/bz2_filter.c index 82899d1e0ed75..5ed7921c17dba 100644 --- a/ext/bz2/bz2_filter.c +++ b/ext/bz2/bz2_filter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/bz2/php_bz2.h b/ext/bz2/php_bz2.h index 89069b539b963..8b12eca357d99 100644 --- a/ext/bz2/php_bz2.h +++ b/ext/bz2/php_bz2.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/calendar/cal_unix.c b/ext/calendar/cal_unix.c index ad0a79747fe39..c65b046fc867e 100644 --- a/ext/calendar/cal_unix.c +++ b/ext/calendar/cal_unix.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/calendar/calendar.c b/ext/calendar/calendar.c index 5947aabc986b9..d881494cb52ce 100644 --- a/ext/calendar/calendar.c +++ b/ext/calendar/calendar.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/calendar/easter.c b/ext/calendar/easter.c index f1b76c2ac9621..1948ff9f0e3b1 100644 --- a/ext/calendar/easter.c +++ b/ext/calendar/easter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_com.c b/ext/com_dotnet/com_com.c index 15b9a6c508f17..fe48ee9e28cf2 100644 --- a/ext/com_dotnet/com_com.c +++ b/ext/com_dotnet/com_com.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_dotnet.c b/ext/com_dotnet/com_dotnet.c index 8e3bf31cc8154..7fbdae15cbc13 100644 --- a/ext/com_dotnet/com_dotnet.c +++ b/ext/com_dotnet/com_dotnet.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_extension.c b/ext/com_dotnet/com_extension.c index e2a2d3b2840d5..1257974697f6d 100644 --- a/ext/com_dotnet/com_extension.c +++ b/ext/com_dotnet/com_extension.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_handlers.c b/ext/com_dotnet/com_handlers.c index a0824f240939c..4bdbf52f2b619 100644 --- a/ext/com_dotnet/com_handlers.c +++ b/ext/com_dotnet/com_handlers.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_iterator.c b/ext/com_dotnet/com_iterator.c index a84aeef6f7672..ce4bdd67c04e2 100644 --- a/ext/com_dotnet/com_iterator.c +++ b/ext/com_dotnet/com_iterator.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_misc.c b/ext/com_dotnet/com_misc.c index 33bd6380f3bfc..023c5b80efa75 100644 --- a/ext/com_dotnet/com_misc.c +++ b/ext/com_dotnet/com_misc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_olechar.c b/ext/com_dotnet/com_olechar.c index e57c7343de5c8..e456df242d1cb 100644 --- a/ext/com_dotnet/com_olechar.c +++ b/ext/com_dotnet/com_olechar.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_persist.c b/ext/com_dotnet/com_persist.c index 7c035f6c4abc4..8953a4184c4a3 100644 --- a/ext/com_dotnet/com_persist.c +++ b/ext/com_dotnet/com_persist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_saproxy.c b/ext/com_dotnet/com_saproxy.c index 1d851f060702d..ad928497439b5 100644 --- a/ext/com_dotnet/com_saproxy.c +++ b/ext/com_dotnet/com_saproxy.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_typeinfo.c b/ext/com_dotnet/com_typeinfo.c index f57b97f0daf9f..482b9b84abdc7 100644 --- a/ext/com_dotnet/com_typeinfo.c +++ b/ext/com_dotnet/com_typeinfo.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_variant.c b/ext/com_dotnet/com_variant.c index 2adccb588177e..853b7df4ca0f3 100644 --- a/ext/com_dotnet/com_variant.c +++ b/ext/com_dotnet/com_variant.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/com_wrapper.c b/ext/com_dotnet/com_wrapper.c index c8e59f95cc247..597b0599510f1 100644 --- a/ext/com_dotnet/com_wrapper.c +++ b/ext/com_dotnet/com_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/php_com_dotnet.h b/ext/com_dotnet/php_com_dotnet.h index 96ea21ae6af28..8771e277361a0 100644 --- a/ext/com_dotnet/php_com_dotnet.h +++ b/ext/com_dotnet/php_com_dotnet.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/com_dotnet/php_com_dotnet_internal.h b/ext/com_dotnet/php_com_dotnet_internal.h index f821bec976886..015de450cf204 100644 --- a/ext/com_dotnet/php_com_dotnet_internal.h +++ b/ext/com_dotnet/php_com_dotnet_internal.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ctype/ctype.c b/ext/ctype/ctype.c index 64cbf1579a1cd..e2698f5e731df 100644 --- a/ext/ctype/ctype.c +++ b/ext/ctype/ctype.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ctype/php_ctype.h b/ext/ctype/php_ctype.h index 484b3473909d6..e1036b9d0399b 100644 --- a/ext/ctype/php_ctype.h +++ b/ext/ctype/php_ctype.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 7d9b55c02fa15..125094c53a756 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/curl/multi.c b/ext/curl/multi.c index 4cf9d5fb4a147..d84669a772474 100644 --- a/ext/curl/multi.c +++ b/ext/curl/multi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index de8eb7efa5600..3ae70602887f1 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/curl/share.c b/ext/curl/share.c index 70e2f56e6f7f1..d1aed879402b8 100644 --- a/ext/curl/share.c +++ b/ext/curl/share.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/curl/streams.c b/ext/curl/streams.c index 2f2e0de86529d..2683ae08808ac 100644 --- a/ext/curl/streams.c +++ b/ext/curl/streams.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/astro.c b/ext/date/lib/astro.c index 064700f912143..d770d1aaedd21 100644 --- a/ext/date/lib/astro.c +++ b/ext/date/lib/astro.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/dow.c b/ext/date/lib/dow.c index 9cb9c9cd28e34..b6c2d69682074 100644 --- a/ext/date/lib/dow.c +++ b/ext/date/lib/dow.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/interval.c b/ext/date/lib/interval.c index 451b4631911f3..96867ba2b797a 100644 --- a/ext/date/lib/interval.c +++ b/ext/date/lib/interval.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c index 1ccddd2ad801b..90622f956f4be 100644 --- a/ext/date/lib/parse_date.c +++ b/ext/date/lib/parse_date.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/parse_date.re b/ext/date/lib/parse_date.re index 5a8b6134b951a..8e1972d99f106 100644 --- a/ext/date/lib/parse_date.re +++ b/ext/date/lib/parse_date.re @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/parse_iso_intervals.c b/ext/date/lib/parse_iso_intervals.c index fce91cfa4f94b..7d05e324a30b1 100644 --- a/ext/date/lib/parse_iso_intervals.c +++ b/ext/date/lib/parse_iso_intervals.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/parse_iso_intervals.re b/ext/date/lib/parse_iso_intervals.re index e52868865b8ab..56aa34d8e005e 100644 --- a/ext/date/lib/parse_iso_intervals.re +++ b/ext/date/lib/parse_iso_intervals.re @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/parse_tz.c b/ext/date/lib/parse_tz.c index 009a2ad4e6350..d3abf84c81e7a 100644 --- a/ext/date/lib/parse_tz.c +++ b/ext/date/lib/parse_tz.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/timelib.c b/ext/date/lib/timelib.c index 43eedf780c6e5..2f457a988244a 100644 --- a/ext/date/lib/timelib.c +++ b/ext/date/lib/timelib.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/timelib.h b/ext/date/lib/timelib.h index 671d37fd9e899..478dec32d04b8 100644 --- a/ext/date/lib/timelib.h +++ b/ext/date/lib/timelib.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/timelib_structs.h b/ext/date/lib/timelib_structs.h index 6662d91b1b5ab..a3d7793447b72 100644 --- a/ext/date/lib/timelib_structs.h +++ b/ext/date/lib/timelib_structs.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/tm2unixtime.c b/ext/date/lib/tm2unixtime.c index 37b4f43322e3f..23fe202ba9f44 100644 --- a/ext/date/lib/tm2unixtime.c +++ b/ext/date/lib/tm2unixtime.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/lib/unixtime2tm.c b/ext/date/lib/unixtime2tm.c index 48709f42fca77..c177feebb188a 100644 --- a/ext/date/lib/unixtime2tm.c +++ b/ext/date/lib/unixtime2tm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 1b07404be9fbf..c5647103f9eba 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/date/php_date.h b/ext/date/php_date.h index b2f4e9fd27f39..c9c165050a72b 100644 --- a/ext/date/php_date.h +++ b/ext/date/php_date.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba.c b/ext/dba/dba.c index 9bb05d2be69f7..303d65c33b9d0 100644 --- a/ext/dba/dba.c +++ b/ext/dba/dba.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_cdb.c b/ext/dba/dba_cdb.c index 9a342067f8c15..a4a7314e8a3aa 100644 --- a/ext/dba/dba_cdb.c +++ b/ext/dba/dba_cdb.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_db1.c b/ext/dba/dba_db1.c index 08af439524c8b..fbb24d27bb471 100644 --- a/ext/dba/dba_db1.c +++ b/ext/dba/dba_db1.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_db2.c b/ext/dba/dba_db2.c index 97ac0818a523f..d92613a25b697 100644 --- a/ext/dba/dba_db2.c +++ b/ext/dba/dba_db2.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_db3.c b/ext/dba/dba_db3.c index 43d6c145bf494..b236865bd0ae4 100644 --- a/ext/dba/dba_db3.c +++ b/ext/dba/dba_db3.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_db4.c b/ext/dba/dba_db4.c index 320015035af3e..8987f1a4be679 100644 --- a/ext/dba/dba_db4.c +++ b/ext/dba/dba_db4.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_dbm.c b/ext/dba/dba_dbm.c index 7fc3063175b9c..2f3b800a31b25 100644 --- a/ext/dba/dba_dbm.c +++ b/ext/dba/dba_dbm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_flatfile.c b/ext/dba/dba_flatfile.c index 8f522c280c0c7..082aa5cdb6c9b 100644 --- a/ext/dba/dba_flatfile.c +++ b/ext/dba/dba_flatfile.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_gdbm.c b/ext/dba/dba_gdbm.c index 9fa484e4721e7..7534568d39c2d 100644 --- a/ext/dba/dba_gdbm.c +++ b/ext/dba/dba_gdbm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_inifile.c b/ext/dba/dba_inifile.c index 4a8e4be8dcc51..e1359b65e984d 100644 --- a/ext/dba/dba_inifile.c +++ b/ext/dba/dba_inifile.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_ndbm.c b/ext/dba/dba_ndbm.c index c9a5de1d16388..8b5bbda851c7c 100644 --- a/ext/dba/dba_ndbm.c +++ b/ext/dba/dba_ndbm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_qdbm.c b/ext/dba/dba_qdbm.c index d72f6b9cbc459..485b1997e6219 100644 --- a/ext/dba/dba_qdbm.c +++ b/ext/dba/dba_qdbm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/dba_tcadb.c b/ext/dba/dba_tcadb.c index e99fcbfd47293..082a1ae25067a 100644 --- a/ext/dba/dba_tcadb.c +++ b/ext/dba/dba_tcadb.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libcdb/cdb.c b/ext/dba/libcdb/cdb.c index cfce91e080e6f..bc4ee08831fe5 100644 --- a/ext/dba/libcdb/cdb.c +++ b/ext/dba/libcdb/cdb.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libcdb/cdb.h b/ext/dba/libcdb/cdb.h index 7cdca004983e9..5be8ec4778945 100644 --- a/ext/dba/libcdb/cdb.h +++ b/ext/dba/libcdb/cdb.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libcdb/cdb_make.c b/ext/dba/libcdb/cdb_make.c index 014db032ebde7..154118c15260d 100644 --- a/ext/dba/libcdb/cdb_make.c +++ b/ext/dba/libcdb/cdb_make.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libcdb/cdb_make.h b/ext/dba/libcdb/cdb_make.h index 062cffb05c63e..5bb0ddf5b2260 100644 --- a/ext/dba/libcdb/cdb_make.h +++ b/ext/dba/libcdb/cdb_make.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libcdb/uint32.c b/ext/dba/libcdb/uint32.c index b56cbf26f84fd..803a3d5fd7aa2 100644 --- a/ext/dba/libcdb/uint32.c +++ b/ext/dba/libcdb/uint32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libcdb/uint32.h b/ext/dba/libcdb/uint32.h index 68ea1c0cd872a..ac44f05d7d765 100644 --- a/ext/dba/libcdb/uint32.h +++ b/ext/dba/libcdb/uint32.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libflatfile/flatfile.c b/ext/dba/libflatfile/flatfile.c index c17a295438f21..6ce2f616c81b8 100644 --- a/ext/dba/libflatfile/flatfile.c +++ b/ext/dba/libflatfile/flatfile.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libflatfile/flatfile.h b/ext/dba/libflatfile/flatfile.h index 65d099fbc7210..b8fbeddc9c8df 100644 --- a/ext/dba/libflatfile/flatfile.h +++ b/ext/dba/libflatfile/flatfile.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libinifile/inifile.c b/ext/dba/libinifile/inifile.c index b94c49b61d381..cc09b3dd80cbc 100644 --- a/ext/dba/libinifile/inifile.c +++ b/ext/dba/libinifile/inifile.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/libinifile/inifile.h b/ext/dba/libinifile/inifile.h index 5b7e377d86fdb..5a255738925da 100644 --- a/ext/dba/libinifile/inifile.h +++ b/ext/dba/libinifile/inifile.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/php_dba.h b/ext/dba/php_dba.h index 6f4dcc7597149..1e931dfe48e98 100644 --- a/ext/dba/php_dba.h +++ b/ext/dba/php_dba.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dba/php_tcadb.h b/ext/dba/php_tcadb.h index 0a81146927b59..6aa9aa7f8b330 100644 --- a/ext/dba/php_tcadb.h +++ b/ext/dba/php_tcadb.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/attr.c b/ext/dom/attr.c index 98f645fc70ade..d45ca8820a8b4 100644 --- a/ext/dom/attr.c +++ b/ext/dom/attr.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/cdatasection.c b/ext/dom/cdatasection.c index 8d8ef6117917f..dc8a3f1492ffd 100644 --- a/ext/dom/cdatasection.c +++ b/ext/dom/cdatasection.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/characterdata.c b/ext/dom/characterdata.c index edf90b788ff87..3b1f9b136bd3c 100644 --- a/ext/dom/characterdata.c +++ b/ext/dom/characterdata.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/comment.c b/ext/dom/comment.c index 128b58d54819a..017c2ba78fe97 100644 --- a/ext/dom/comment.c +++ b/ext/dom/comment.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/document.c b/ext/dom/document.c index 1d7f46a9bdf3f..d17c7cbd55f1d 100644 --- a/ext/dom/document.c +++ b/ext/dom/document.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/documentfragment.c b/ext/dom/documentfragment.c index 28b6d20780e0a..4e8d660c9be74 100644 --- a/ext/dom/documentfragment.c +++ b/ext/dom/documentfragment.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/documenttype.c b/ext/dom/documenttype.c index eee3b5f887d45..570999a50e082 100644 --- a/ext/dom/documenttype.c +++ b/ext/dom/documenttype.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/dom_ce.h b/ext/dom/dom_ce.h index 815081229b389..8caf0021a1a64 100644 --- a/ext/dom/dom_ce.h +++ b/ext/dom/dom_ce.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/dom_fe.h b/ext/dom/dom_fe.h index 243c7d166baed..3778c9520876b 100644 --- a/ext/dom/dom_fe.h +++ b/ext/dom/dom_fe.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/dom_iterators.c b/ext/dom/dom_iterators.c index 92302b1b4bd79..f4183d2f9a4a2 100644 --- a/ext/dom/dom_iterators.c +++ b/ext/dom/dom_iterators.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/dom_properties.h b/ext/dom/dom_properties.h index 0897d932ea063..848250241168f 100644 --- a/ext/dom/dom_properties.h +++ b/ext/dom/dom_properties.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domconfiguration.c b/ext/dom/domconfiguration.c index c60f28b0f29ed..4092d73b37a8f 100644 --- a/ext/dom/domconfiguration.c +++ b/ext/dom/domconfiguration.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domerror.c b/ext/dom/domerror.c index 278de163623ea..92b6622176ab7 100644 --- a/ext/dom/domerror.c +++ b/ext/dom/domerror.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domerrorhandler.c b/ext/dom/domerrorhandler.c index e282f30146d28..7af3723230b98 100644 --- a/ext/dom/domerrorhandler.c +++ b/ext/dom/domerrorhandler.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domexception.c b/ext/dom/domexception.c index 787e1f3ae8275..9aa878a028f0a 100644 --- a/ext/dom/domexception.c +++ b/ext/dom/domexception.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domimplementation.c b/ext/dom/domimplementation.c index 92715ce0302ee..5a32c60dd8498 100644 --- a/ext/dom/domimplementation.c +++ b/ext/dom/domimplementation.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domimplementationlist.c b/ext/dom/domimplementationlist.c index 5926185ca0f70..d89d2ff143dff 100644 --- a/ext/dom/domimplementationlist.c +++ b/ext/dom/domimplementationlist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domimplementationsource.c b/ext/dom/domimplementationsource.c index fe7eae4088326..2fb588763594f 100644 --- a/ext/dom/domimplementationsource.c +++ b/ext/dom/domimplementationsource.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domlocator.c b/ext/dom/domlocator.c index 8671ae8307192..88c352b3bf511 100644 --- a/ext/dom/domlocator.c +++ b/ext/dom/domlocator.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/domstringlist.c b/ext/dom/domstringlist.c index 8e679cee270db..d2ab606d2147d 100644 --- a/ext/dom/domstringlist.c +++ b/ext/dom/domstringlist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/element.c b/ext/dom/element.c index 02fded9f1ac8b..f217ca2450d83 100644 --- a/ext/dom/element.c +++ b/ext/dom/element.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/entity.c b/ext/dom/entity.c index 36df57dbab550..18e86fceb54a4 100644 --- a/ext/dom/entity.c +++ b/ext/dom/entity.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/entityreference.c b/ext/dom/entityreference.c index 0a5f41d625d09..4ef526c7e1198 100644 --- a/ext/dom/entityreference.c +++ b/ext/dom/entityreference.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/namednodemap.c b/ext/dom/namednodemap.c index e6c8fffef45d5..07d7c7002f0ec 100644 --- a/ext/dom/namednodemap.c +++ b/ext/dom/namednodemap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/namelist.c b/ext/dom/namelist.c index cf3500aa7ad4f..5831ddeeead60 100644 --- a/ext/dom/namelist.c +++ b/ext/dom/namelist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/node.c b/ext/dom/node.c index 4dbce4d7901a3..32795671dfa84 100644 --- a/ext/dom/node.c +++ b/ext/dom/node.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/nodelist.c b/ext/dom/nodelist.c index 21d23503afba3..d856f1452abf8 100644 --- a/ext/dom/nodelist.c +++ b/ext/dom/nodelist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/notation.c b/ext/dom/notation.c index 081c799571661..1fdfe89f7695b 100644 --- a/ext/dom/notation.c +++ b/ext/dom/notation.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c index ec7ec1e848c5f..c3b0ee0371a81 100644 --- a/ext/dom/php_dom.c +++ b/ext/dom/php_dom.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/php_dom.h b/ext/dom/php_dom.h index e2562a2245443..3559c4bb5eda3 100644 --- a/ext/dom/php_dom.h +++ b/ext/dom/php_dom.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/processinginstruction.c b/ext/dom/processinginstruction.c index cab8ecc1bb7ae..976b693deb0ee 100644 --- a/ext/dom/processinginstruction.c +++ b/ext/dom/processinginstruction.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/string_extend.c b/ext/dom/string_extend.c index 9b5e4c36dc8e0..2c47362fd1994 100644 --- a/ext/dom/string_extend.c +++ b/ext/dom/string_extend.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/text.c b/ext/dom/text.c index 4c129bf387448..f608997050e09 100644 --- a/ext/dom/text.c +++ b/ext/dom/text.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/typeinfo.c b/ext/dom/typeinfo.c index dec0e46dcb038..bc0e60837eacb 100644 --- a/ext/dom/typeinfo.c +++ b/ext/dom/typeinfo.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/userdatahandler.c b/ext/dom/userdatahandler.c index b79de59fafb71..d368a2957b7d2 100644 --- a/ext/dom/userdatahandler.c +++ b/ext/dom/userdatahandler.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/xml_common.h b/ext/dom/xml_common.h index ebe8a516ee94a..87a41c530550a 100644 --- a/ext/dom/xml_common.h +++ b/ext/dom/xml_common.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/dom/xpath.c b/ext/dom/xpath.c index 342854654ecf4..cf556a35054fd 100644 --- a/ext/dom/xpath.c +++ b/ext/dom/xpath.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c index 357f3cb0340d8..3d50cb80a6388 100644 --- a/ext/enchant/enchant.c +++ b/ext/enchant/enchant.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/enchant/php_enchant.h b/ext/enchant/php_enchant.h index a27540f7fcc5a..604c47937e910 100644 --- a/ext/enchant/php_enchant.h +++ b/ext/enchant/php_enchant.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 4 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ereg/ereg.c b/ext/ereg/ereg.c index bbfc83b10ce26..76f5c1b765866 100644 --- a/ext/ereg/ereg.c +++ b/ext/ereg/ereg.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ereg/php_ereg.h b/ext/ereg/php_ereg.h index eea70a1578848..d733d5087d233 100644 --- a/ext/ereg/php_ereg.h +++ b/ext/ereg/php_ereg.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ereg/php_regex.h b/ext/ereg/php_regex.h index e22e7a935af85..53b92da69af3a 100644 --- a/ext/ereg/php_regex.h +++ b/ext/ereg/php_regex.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/exif/exif.c b/ext/exif/exif.c index 9db66747421a0..c69107589835d 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/exif/php_exif.h b/ext/exif/php_exif.h index 8e04b5b6a1feb..5b624e0e56d08 100644 --- a/ext/exif/php_exif.h +++ b/ext/exif/php_exif.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c index e5e52f0995eac..353adb98b972e 100644 --- a/ext/fileinfo/fileinfo.c +++ b/ext/fileinfo/fileinfo.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/fileinfo/php_fileinfo.h b/ext/fileinfo/php_fileinfo.h index 3f0326bfdaed1..4a34357ccf70a 100644 --- a/ext/fileinfo/php_fileinfo.h +++ b/ext/fileinfo/php_fileinfo.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/filter/callback_filter.c b/ext/filter/callback_filter.c index 458dafb6b11d2..3beacb6a8fe02 100644 --- a/ext/filter/callback_filter.c +++ b/ext/filter/callback_filter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/filter/filter.c b/ext/filter/filter.c index e523cdc882989..2aa8dd57d9c0c 100644 --- a/ext/filter/filter.c +++ b/ext/filter/filter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/filter/filter_private.h b/ext/filter/filter_private.h index 0f76d7a032a71..9bc53a0e4757f 100644 --- a/ext/filter/filter_private.h +++ b/ext/filter/filter_private.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index c03c698700714..58d5870c112e1 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/filter/php_filter.h b/ext/filter/php_filter.h index 4c83969cf192c..cbe1c4720093b 100644 --- a/ext/filter/php_filter.h +++ b/ext/filter/php_filter.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/filter/sanitizing_filters.c b/ext/filter/sanitizing_filters.c index 17160b457f38a..30da05a2179f8 100644 --- a/ext/filter/sanitizing_filters.c +++ b/ext/filter/sanitizing_filters.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ftp/ftp.c b/ext/ftp/ftp.c index 4156a04581316..4c8a94f81c7df 100644 --- a/ext/ftp/ftp.c +++ b/ext/ftp/ftp.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ftp/ftp.h b/ext/ftp/ftp.h index 7023723a403ad..c7db45789a5d9 100644 --- a/ext/ftp/ftp.h +++ b/ext/ftp/ftp.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ftp/php_ftp.c b/ext/ftp/php_ftp.c index 6e232a5df2d3a..73071936e0fbc 100644 --- a/ext/ftp/php_ftp.c +++ b/ext/ftp/php_ftp.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ftp/php_ftp.h b/ext/ftp/php_ftp.h index 8ca27b9a9b55c..41f65f900ae9c 100644 --- a/ext/ftp/php_ftp.h +++ b/ext/ftp/php_ftp.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gd/gd.c b/ext/gd/gd.c index cfcc3e876c94d..72abbba2bc977 100644 --- a/ext/gd/gd.c +++ b/ext/gd/gd.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gd/gd_ctx.c b/ext/gd/gd_ctx.c index 1523816ed95c8..b0e8aa66abdea 100644 --- a/ext/gd/gd_ctx.c +++ b/ext/gd/gd_ctx.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gd/libgd/xbm.c b/ext/gd/libgd/xbm.c index f4165d52b795d..9491328d6687d 100644 --- a/ext/gd/libgd/xbm.c +++ b/ext/gd/libgd/xbm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gd/php_gd.h b/ext/gd/php_gd.h index f8433d609f57e..45193768ea4c3 100644 --- a/ext/gd/php_gd.h +++ b/ext/gd/php_gd.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gettext/gettext.c b/ext/gettext/gettext.c index 9a3899a143e41..ed86b6cbc40f1 100644 --- a/ext/gettext/gettext.c +++ b/ext/gettext/gettext.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gettext/php_gettext.h b/ext/gettext/php_gettext.h index acac09f945057..0c517d9a512e8 100644 --- a/ext/gettext/php_gettext.h +++ b/ext/gettext/php_gettext.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gmp/gmp.c b/ext/gmp/gmp.c index 3b78ec459e46c..c9da09b230bb4 100644 --- a/ext/gmp/gmp.c +++ b/ext/gmp/gmp.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/gmp/php_gmp.h b/ext/gmp/php_gmp.h index 1e4bffe2000b7..e1aaef886d277 100644 --- a/ext/gmp/php_gmp.h +++ b/ext/gmp/php_gmp.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash.c b/ext/hash/hash.c index 957575d47276c..9492387dbb714 100644 --- a/ext/hash/hash.c +++ b/ext/hash/hash.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_adler32.c b/ext/hash/hash_adler32.c index 758080ca36c2b..4575c00c4e041 100644 --- a/ext/hash/hash_adler32.c +++ b/ext/hash/hash_adler32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_crc32.c b/ext/hash/hash_crc32.c index dee126d040328..9be5b4bd4060b 100644 --- a/ext/hash/hash_crc32.c +++ b/ext/hash/hash_crc32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_fnv.c b/ext/hash/hash_fnv.c index 04faabce82edb..f96946d8243ba 100644 --- a/ext/hash/hash_fnv.c +++ b/ext/hash/hash_fnv.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_gost.c b/ext/hash/hash_gost.c index 1cb2872d8e73c..3961c4f2d5c36 100644 --- a/ext/hash/hash_gost.c +++ b/ext/hash/hash_gost.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_haval.c b/ext/hash/hash_haval.c index d48da57535f5b..7d8b49670f5a9 100644 --- a/ext/hash/hash_haval.c +++ b/ext/hash/hash_haval.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_joaat.c b/ext/hash/hash_joaat.c index f6395dd9914ab..d73938deadf16 100644 --- a/ext/hash/hash_joaat.c +++ b/ext/hash/hash_joaat.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_md.c b/ext/hash/hash_md.c index 647ac561e235b..25165eef43b34 100644 --- a/ext/hash/hash_md.c +++ b/ext/hash/hash_md.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_ripemd.c b/ext/hash/hash_ripemd.c index 330d484422df8..c7c53c603c1e7 100644 --- a/ext/hash/hash_ripemd.c +++ b/ext/hash/hash_ripemd.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_sha.c b/ext/hash/hash_sha.c index 908f9a8edef78..80d9f1f265681 100644 --- a/ext/hash/hash_sha.c +++ b/ext/hash/hash_sha.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_snefru.c b/ext/hash/hash_snefru.c index 06324f082411e..34101de9d2b91 100644 --- a/ext/hash/hash_snefru.c +++ b/ext/hash/hash_snefru.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_tiger.c b/ext/hash/hash_tiger.c index bd1d79bb92db3..e6e2692cc9244 100644 --- a/ext/hash/hash_tiger.c +++ b/ext/hash/hash_tiger.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/hash_whirlpool.c b/ext/hash/hash_whirlpool.c index eb312627c92f9..6fde452bc9835 100644 --- a/ext/hash/hash_whirlpool.c +++ b/ext/hash/hash_whirlpool.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash.h b/ext/hash/php_hash.h index 7bc72a2bcb140..4bfddbacd9c45 100644 --- a/ext/hash/php_hash.h +++ b/ext/hash/php_hash.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_adler32.h b/ext/hash/php_hash_adler32.h index 0cbaff4aeb5c3..789cf18ef75bb 100644 --- a/ext/hash/php_hash_adler32.h +++ b/ext/hash/php_hash_adler32.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_crc32.h b/ext/hash/php_hash_crc32.h index f610a3cb6f2bd..111a12f1934fb 100644 --- a/ext/hash/php_hash_crc32.h +++ b/ext/hash/php_hash_crc32.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_crc32_tables.h b/ext/hash/php_hash_crc32_tables.h index 9a0666df49760..8424a23d133cd 100644 --- a/ext/hash/php_hash_crc32_tables.h +++ b/ext/hash/php_hash_crc32_tables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_fnv.h b/ext/hash/php_hash_fnv.h index ab91b7045ae87..3eeb046c343bf 100644 --- a/ext/hash/php_hash_fnv.h +++ b/ext/hash/php_hash_fnv.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_gost.h b/ext/hash/php_hash_gost.h index 0c10dfd5c39fc..6a4af310dc64c 100644 --- a/ext/hash/php_hash_gost.h +++ b/ext/hash/php_hash_gost.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_haval.h b/ext/hash/php_hash_haval.h index b9e36a24a2c1a..0e62f230ddf3a 100644 --- a/ext/hash/php_hash_haval.h +++ b/ext/hash/php_hash_haval.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_joaat.h b/ext/hash/php_hash_joaat.h index e54ae62904abd..d4eacd98f0094 100644 --- a/ext/hash/php_hash_joaat.h +++ b/ext/hash/php_hash_joaat.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_md.h b/ext/hash/php_hash_md.h index 195f26968b4dc..10b6f121bbc90 100644 --- a/ext/hash/php_hash_md.h +++ b/ext/hash/php_hash_md.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_ripemd.h b/ext/hash/php_hash_ripemd.h index a27b7b3c5c167..fde5c0f533344 100644 --- a/ext/hash/php_hash_ripemd.h +++ b/ext/hash/php_hash_ripemd.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_sha.h b/ext/hash/php_hash_sha.h index d2d309dc34651..bae7cf3c2fcf8 100644 --- a/ext/hash/php_hash_sha.h +++ b/ext/hash/php_hash_sha.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_snefru.h b/ext/hash/php_hash_snefru.h index 46fbb02f691d8..87e3c530197e4 100644 --- a/ext/hash/php_hash_snefru.h +++ b/ext/hash/php_hash_snefru.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_snefru_tables.h b/ext/hash/php_hash_snefru_tables.h index 071c9cc860061..1956e9e1e3c30 100644 --- a/ext/hash/php_hash_snefru_tables.h +++ b/ext/hash/php_hash_snefru_tables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_tiger.h b/ext/hash/php_hash_tiger.h index 54294a382aa29..c3428bfe816e1 100644 --- a/ext/hash/php_hash_tiger.h +++ b/ext/hash/php_hash_tiger.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_tiger_tables.h b/ext/hash/php_hash_tiger_tables.h index df3bac6638039..a826c9ac66cc5 100644 --- a/ext/hash/php_hash_tiger_tables.h +++ b/ext/hash/php_hash_tiger_tables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_types.h b/ext/hash/php_hash_types.h index 42659e3d2263d..8793da55d6727 100644 --- a/ext/hash/php_hash_types.h +++ b/ext/hash/php_hash_types.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_whirlpool.h b/ext/hash/php_hash_whirlpool.h index e55e61fa4a411..f742547c501bc 100644 --- a/ext/hash/php_hash_whirlpool.h +++ b/ext/hash/php_hash_whirlpool.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/hash/php_hash_whirlpool_tables.h b/ext/hash/php_hash_whirlpool_tables.h index 10adf096c7bad..819a52a19e712 100644 --- a/ext/hash/php_hash_whirlpool_tables.h +++ b/ext/hash/php_hash_whirlpool_tables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/iconv/iconv.c b/ext/iconv/iconv.c index 9cae535138eb1..ba893ea9e607a 100644 --- a/ext/iconv/iconv.c +++ b/ext/iconv/iconv.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/iconv/php_iconv.h b/ext/iconv/php_iconv.h index 8024fda0803df..04fa6ef5343d7 100644 --- a/ext/iconv/php_iconv.h +++ b/ext/iconv/php_iconv.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index 681af6f585114..b154cb86b04b7 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/imap/php_imap.h b/ext/imap/php_imap.h index 4bb1ea1ad5d40..52128a643be3e 100644 --- a/ext/imap/php_imap.h +++ b/ext/imap/php_imap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/ibase_blobs.c b/ext/interbase/ibase_blobs.c index 14ffb227699bf..9d9d2f807d176 100644 --- a/ext/interbase/ibase_blobs.c +++ b/ext/interbase/ibase_blobs.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/ibase_events.c b/ext/interbase/ibase_events.c index 909a173dbb5d3..3380defd4b912 100644 --- a/ext/interbase/ibase_events.c +++ b/ext/interbase/ibase_events.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/ibase_query.c b/ext/interbase/ibase_query.c index 1c6de4e73e33f..b30d741a82ef4 100644 --- a/ext/interbase/ibase_query.c +++ b/ext/interbase/ibase_query.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/ibase_service.c b/ext/interbase/ibase_service.c index 1846b7416f901..956ef044747ea 100644 --- a/ext/interbase/ibase_service.c +++ b/ext/interbase/ibase_service.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/interbase.c b/ext/interbase/interbase.c index f401a4d1bd7e2..132ad35fba0cf 100644 --- a/ext/interbase/interbase.c +++ b/ext/interbase/interbase.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/php_ibase_includes.h b/ext/interbase/php_ibase_includes.h index 09f4243a019ca..559be77a44143 100644 --- a/ext/interbase/php_ibase_includes.h +++ b/ext/interbase/php_ibase_includes.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/php_ibase_udf.c b/ext/interbase/php_ibase_udf.c index 07c1c318222f6..7faf314bc0386 100644 --- a/ext/interbase/php_ibase_udf.c +++ b/ext/interbase/php_ibase_udf.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/interbase/php_interbase.h b/ext/interbase/php_interbase.h index eeaafe6457f31..149319e5770f7 100644 --- a/ext/interbase/php_interbase.h +++ b/ext/interbase/php_interbase.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/json/json.c b/ext/json/json.c index aafb7349aaf06..53608412f5a16 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/json/php_json.h b/ext/json/php_json.h index 2b3cf5868ad4f..ec707ce3465a9 100644 --- a/ext/json/php_json.h +++ b/ext/json/php_json.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c index 47d3ab167aadc..3cfa2092e776e 100644 --- a/ext/ldap/ldap.c +++ b/ext/ldap/ldap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/ldap/php_ldap.h b/ext/ldap/php_ldap.h index 751e57775771e..2ed8fd822d696 100644 --- a/ext/ldap/php_ldap.h +++ b/ext/ldap/php_ldap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c index 06de013858cb8..0f1c2bb82521d 100644 --- a/ext/libxml/libxml.c +++ b/ext/libxml/libxml.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/libxml/php_libxml.h b/ext/libxml/php_libxml.h index a11d059f71abd..8b9acc044e307 100644 --- a/ext/libxml/php_libxml.h +++ b/ext/libxml/php_libxml.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/mb_gpc.c b/ext/mbstring/mb_gpc.c index 4e40e625d491c..5ecc8f365e8ae 100644 --- a/ext/mbstring/mb_gpc.c +++ b/ext/mbstring/mb_gpc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index 0861fa64812d2..4e430b6ea2364 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/mbstring.h b/ext/mbstring/mbstring.h index 15f5d79190acd..70f9f48fb01f7 100644 --- a/ext/mbstring/mbstring.h +++ b/ext/mbstring/mbstring.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/php_mbregex.c b/ext/mbstring/php_mbregex.c index 863eebead3f89..a572bd41dac15 100644 --- a/ext/mbstring/php_mbregex.c +++ b/ext/mbstring/php_mbregex.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/php_mbregex.h b/ext/mbstring/php_mbregex.h index 3ff961a3471fc..276220ac110cd 100644 --- a/ext/mbstring/php_mbregex.h +++ b/ext/mbstring/php_mbregex.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/php_unicode.c b/ext/mbstring/php_unicode.c index 99430d1aaa972..9380045e6f069 100644 --- a/ext/mbstring/php_unicode.c +++ b/ext/mbstring/php_unicode.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mbstring/php_unicode.h b/ext/mbstring/php_unicode.h index 015073afdfa73..b1e395cac1b1a 100644 --- a/ext/mbstring/php_unicode.h +++ b/ext/mbstring/php_unicode.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c index dcac776d024c1..07568e6c2ae19 100644 --- a/ext/mcrypt/mcrypt.c +++ b/ext/mcrypt/mcrypt.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mcrypt/mcrypt_filter.c b/ext/mcrypt/mcrypt_filter.c index d8baec2396fbc..da8215bd9e339 100644 --- a/ext/mcrypt/mcrypt_filter.c +++ b/ext/mcrypt/mcrypt_filter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mcrypt/php_mcrypt.h b/ext/mcrypt/php_mcrypt.h index 5a0e6b89ca6e3..4eb2c56f0eb5b 100644 --- a/ext/mcrypt/php_mcrypt.h +++ b/ext/mcrypt/php_mcrypt.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mcrypt/php_mcrypt_filter.h b/ext/mcrypt/php_mcrypt_filter.h index 01fc5a27f15e6..01391303281ed 100644 --- a/ext/mcrypt/php_mcrypt_filter.h +++ b/ext/mcrypt/php_mcrypt_filter.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c index a1c797c7b7eb7..fbeaa60ef0c07 100644 --- a/ext/mssql/php_mssql.c +++ b/ext/mssql/php_mssql.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mssql/php_mssql.h b/ext/mssql/php_mssql.h index 9653b8483991c..b73c8420462da 100644 --- a/ext/mssql/php_mssql.h +++ b/ext/mssql/php_mssql.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c index dc7f108b5d76a..a41f2a5cb9c5a 100644 --- a/ext/mysql/php_mysql.c +++ b/ext/mysql/php_mysql.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysql/php_mysql.h b/ext/mysql/php_mysql.h index 899d5d53e2d9b..7b9ab8d6fbf5a 100644 --- a/ext/mysql/php_mysql.h +++ b/ext/mysql/php_mysql.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysql/php_mysql_structs.h b/ext/mysql/php_mysql_structs.h index 003ed04872353..bf09b24b0c56f 100644 --- a/ext/mysql/php_mysql_structs.h +++ b/ext/mysql/php_mysql_structs.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index 81bae23a5fd66..d2737bf4ad3d5 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index 1ac9173eec462..f062215e95df8 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_driver.c b/ext/mysqli/mysqli_driver.c index 67e2b43e7629f..8684edcb47aa4 100644 --- a/ext/mysqli/mysqli_driver.c +++ b/ext/mysqli/mysqli_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_embedded.c b/ext/mysqli/mysqli_embedded.c index acf32424eb9b4..3693777b25e7c 100644 --- a/ext/mysqli/mysqli_embedded.c +++ b/ext/mysqli/mysqli_embedded.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_exception.c b/ext/mysqli/mysqli_exception.c index b2e99227f1627..dafc3098c7a02 100644 --- a/ext/mysqli/mysqli_exception.c +++ b/ext/mysqli/mysqli_exception.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c index 80ae848f9544d..4ac67269ce44f 100644 --- a/ext/mysqli/mysqli_fe.c +++ b/ext/mysqli/mysqli_fe.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_fe.h b/ext/mysqli/mysqli_fe.h index f7689122ae07b..2edb32cb31c5b 100644 --- a/ext/mysqli/mysqli_fe.h +++ b/ext/mysqli/mysqli_fe.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_libmysql.h b/ext/mysqli/mysqli_libmysql.h index a61f7e87b91a1..3a7b91b9956fd 100644 --- a/ext/mysqli/mysqli_libmysql.h +++ b/ext/mysqli/mysqli_libmysql.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index c01482fe79c5b..b730d24cd69d8 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_priv.h b/ext/mysqli/mysqli_priv.h index ecbdacb4ea87b..d823ea89eb563 100644 --- a/ext/mysqli/mysqli_priv.h +++ b/ext/mysqli/mysqli_priv.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_prop.c b/ext/mysqli/mysqli_prop.c index 87661b2860fea..bd9cee28f1d50 100644 --- a/ext/mysqli/mysqli_prop.c +++ b/ext/mysqli/mysqli_prop.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_report.c b/ext/mysqli/mysqli_report.c index 6780f166164a2..52135ce43ef5d 100644 --- a/ext/mysqli/mysqli_report.c +++ b/ext/mysqli/mysqli_report.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_result_iterator.c b/ext/mysqli/mysqli_result_iterator.c index 9a2e2634e63a1..0f5ccdd63dd7a 100644 --- a/ext/mysqli/mysqli_result_iterator.c +++ b/ext/mysqli/mysqli_result_iterator.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/mysqli_warning.c b/ext/mysqli/mysqli_warning.c index 33e2b85a2cc9b..25653e3358593 100644 --- a/ext/mysqli/mysqli_warning.c +++ b/ext/mysqli/mysqli_warning.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/php_mysqli.h b/ext/mysqli/php_mysqli.h index 511e552f993b8..6dac3f0979fc7 100644 --- a/ext/mysqli/php_mysqli.h +++ b/ext/mysqli/php_mysqli.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/mysqli/php_mysqli_structs.h b/ext/mysqli/php_mysqli_structs.h index 1d363ab245a09..8b329bb5d02f1 100644 --- a/ext/mysqli/php_mysqli_structs.h +++ b/ext/mysqli/php_mysqli_structs.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index e2241cffb72c9..44bfa713983a9 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/oci8_collection.c b/ext/oci8/oci8_collection.c index 85d5b64aba5c2..763e12e9249d7 100644 --- a/ext/oci8/oci8_collection.c +++ b/ext/oci8/oci8_collection.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c index f499bbf3350aa..e51d3c92f5272 100644 --- a/ext/oci8/oci8_interface.c +++ b/ext/oci8/oci8_interface.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/oci8_lob.c b/ext/oci8/oci8_lob.c index 539a6415c7cfa..d05e053919217 100644 --- a/ext/oci8/oci8_lob.c +++ b/ext/oci8/oci8_lob.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/oci8_statement.c b/ext/oci8/oci8_statement.c index b683ba15544d5..89facb0703431 100644 --- a/ext/oci8/oci8_statement.c +++ b/ext/oci8/oci8_statement.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/php_oci8.h b/ext/oci8/php_oci8.h index 4ee8e8e976deb..6632bc88ffc3b 100644 --- a/ext/oci8/php_oci8.h +++ b/ext/oci8/php_oci8.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/oci8/php_oci8_int.h b/ext/oci8/php_oci8_int.h index b0d65164c5304..d8d7d0f47a1b9 100644 --- a/ext/oci8/php_oci8_int.h +++ b/ext/oci8/php_oci8_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/odbc/birdstep.c b/ext/odbc/birdstep.c index 63125fd836a0b..0af58d0cd6c13 100644 --- a/ext/odbc/birdstep.c +++ b/ext/odbc/birdstep.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/odbc/php_birdstep.h b/ext/odbc/php_birdstep.h index f09489020bbaf..17f4fdee50614 100644 --- a/ext/odbc/php_birdstep.h +++ b/ext/odbc/php_birdstep.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c index 52d46b2fd0f77..adb7272d4272e 100644 --- a/ext/odbc/php_odbc.c +++ b/ext/odbc/php_odbc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/odbc/php_odbc.h b/ext/odbc/php_odbc.h index 91d80598be17b..7e8d26d0cc769 100644 --- a/ext/odbc/php_odbc.h +++ b/ext/odbc/php_odbc.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/odbc/php_odbc_includes.h b/ext/odbc/php_odbc_includes.h index 0a1aa330fce35..8251528e19c24 100644 --- a/ext/odbc/php_odbc_includes.h +++ b/ext/odbc/php_odbc_includes.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 99735b1544df8..fd8d7deb6214c 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/openssl/php_openssl.h b/ext/openssl/php_openssl.h index 2de211a64cfbc..e6b064a277e68 100644 --- a/ext/openssl/php_openssl.h +++ b/ext/openssl/php_openssl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c index e9f89f781e62f..c6f4e952ac2d5 100644 --- a/ext/openssl/xp_ssl.c +++ b/ext/openssl/xp_ssl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c index 108119a0bffdb..abe6b64aca528 100644 --- a/ext/pcntl/pcntl.c +++ b/ext/pcntl/pcntl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pcntl/php_pcntl.h b/ext/pcntl/php_pcntl.h index 289895a1bb504..280a45bbaffc0 100644 --- a/ext/pcntl/php_pcntl.h +++ b/ext/pcntl/php_pcntl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pcntl/php_signal.c b/ext/pcntl/php_signal.c index 9f907b765bd4a..abdee832235c9 100644 --- a/ext/pcntl/php_signal.c +++ b/ext/pcntl/php_signal.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pcntl/php_signal.h b/ext/pcntl/php_signal.h index 9c9b3d39a135e..07bde634ca0dd 100644 --- a/ext/pcntl/php_signal.h +++ b/ext/pcntl/php_signal.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index 0c7280e3b8cca..2ca0d5e168d92 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pcre/php_pcre.h b/ext/pcre/php_pcre.h index d4acae0aba8b5..db14ce38fc1db 100644 --- a/ext/pcre/php_pcre.h +++ b/ext/pcre/php_pcre.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c index e0a1c3ce2f559..452c27b591cce 100644 --- a/ext/pdo/pdo.c +++ b/ext/pdo/pdo.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c index acdc0dd90d616..e6265f58075ab 100644 --- a/ext/pdo/pdo_dbh.c +++ b/ext/pdo/pdo_dbh.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/pdo_sql_parser.c b/ext/pdo/pdo_sql_parser.c index 365b02284464f..ec488e053f021 100644 --- a/ext/pdo/pdo_sql_parser.c +++ b/ext/pdo/pdo_sql_parser.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/pdo_sql_parser.re b/ext/pdo/pdo_sql_parser.re index 88f94001f91f4..d4272d679b587 100644 --- a/ext/pdo/pdo_sql_parser.re +++ b/ext/pdo/pdo_sql_parser.re @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/pdo_sqlstate.c b/ext/pdo/pdo_sqlstate.c index 7ce186801fc94..7c92c1c0f33ee 100644 --- a/ext/pdo/pdo_sqlstate.c +++ b/ext/pdo/pdo_sqlstate.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c index 31932eb3c2a72..a469d09fc2e34 100644 --- a/ext/pdo/pdo_stmt.c +++ b/ext/pdo/pdo_stmt.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/php_pdo.h b/ext/pdo/php_pdo.h index bc01da2cf82d3..f8a8ce377efa8 100644 --- a/ext/pdo/php_pdo.h +++ b/ext/pdo/php_pdo.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/php_pdo_driver.h b/ext/pdo/php_pdo_driver.h index b9c46bae74002..f38e7b5ec917a 100644 --- a/ext/pdo/php_pdo_driver.h +++ b/ext/pdo/php_pdo_driver.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo/php_pdo_int.h b/ext/pdo/php_pdo_int.h index 9a7a64e9c3983..91d0bf0412f77 100644 --- a/ext/pdo/php_pdo_int.h +++ b/ext/pdo/php_pdo_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_dblib/dblib_driver.c b/ext/pdo_dblib/dblib_driver.c index baf1dcc670f8c..ffc910177fdd3 100644 --- a/ext/pdo_dblib/dblib_driver.c +++ b/ext/pdo_dblib/dblib_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_dblib/dblib_stmt.c b/ext/pdo_dblib/dblib_stmt.c index 3eacb4c5e2a5f..1a2fefd47a9b1 100644 --- a/ext/pdo_dblib/dblib_stmt.c +++ b/ext/pdo_dblib/dblib_stmt.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_dblib/pdo_dblib.c b/ext/pdo_dblib/pdo_dblib.c index 2f44e29b86c98..ed79aea20d16e 100644 --- a/ext/pdo_dblib/pdo_dblib.c +++ b/ext/pdo_dblib/pdo_dblib.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_dblib/php_pdo_dblib.h b/ext/pdo_dblib/php_pdo_dblib.h index a907054434ca6..3396f208e563e 100644 --- a/ext/pdo_dblib/php_pdo_dblib.h +++ b/ext/pdo_dblib/php_pdo_dblib.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_dblib/php_pdo_dblib_int.h b/ext/pdo_dblib/php_pdo_dblib_int.h index 48d0eb318d9d6..dd06a1d94fb12 100644 --- a/ext/pdo_dblib/php_pdo_dblib_int.h +++ b/ext/pdo_dblib/php_pdo_dblib_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_firebird/firebird_driver.c b/ext/pdo_firebird/firebird_driver.c index 9b0f596959a97..bda6d23fa4b82 100644 --- a/ext/pdo_firebird/firebird_driver.c +++ b/ext/pdo_firebird/firebird_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_firebird/firebird_statement.c b/ext/pdo_firebird/firebird_statement.c index ae05870b4aaa8..5c3e435f7b7f6 100644 --- a/ext/pdo_firebird/firebird_statement.c +++ b/ext/pdo_firebird/firebird_statement.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_firebird/pdo_firebird.c b/ext/pdo_firebird/pdo_firebird.c index c2bbe372c231b..1f14b554215e6 100644 --- a/ext/pdo_firebird/pdo_firebird.c +++ b/ext/pdo_firebird/pdo_firebird.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_firebird/php_pdo_firebird.h b/ext/pdo_firebird/php_pdo_firebird.h index ab0aea949b60b..cbece41d9fe98 100644 --- a/ext/pdo_firebird/php_pdo_firebird.h +++ b/ext/pdo_firebird/php_pdo_firebird.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_firebird/php_pdo_firebird_int.h b/ext/pdo_firebird/php_pdo_firebird_int.h index bb15d5489dc2c..9632edc8104e1 100644 --- a/ext/pdo_firebird/php_pdo_firebird_int.h +++ b/ext/pdo_firebird/php_pdo_firebird_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_mysql/mysql_driver.c b/ext/pdo_mysql/mysql_driver.c index 527cb1c3b8d49..54c2e8dd84870 100644 --- a/ext/pdo_mysql/mysql_driver.c +++ b/ext/pdo_mysql/mysql_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_mysql/mysql_statement.c b/ext/pdo_mysql/mysql_statement.c index 7bfbef015c2cc..f2e36c1719ea1 100644 --- a/ext/pdo_mysql/mysql_statement.c +++ b/ext/pdo_mysql/mysql_statement.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c index b5a8058da4c52..ed51e947cd79b 100644 --- a/ext/pdo_mysql/pdo_mysql.c +++ b/ext/pdo_mysql/pdo_mysql.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_mysql/php_pdo_mysql.h b/ext/pdo_mysql/php_pdo_mysql.h index 87c7956257e52..e4493b569acc0 100644 --- a/ext/pdo_mysql/php_pdo_mysql.h +++ b/ext/pdo_mysql/php_pdo_mysql.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_mysql/php_pdo_mysql_int.h b/ext/pdo_mysql/php_pdo_mysql_int.h index 32cf0391525a3..42debf07e9336 100644 --- a/ext/pdo_mysql/php_pdo_mysql_int.h +++ b/ext/pdo_mysql/php_pdo_mysql_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_oci/oci_driver.c b/ext/pdo_oci/oci_driver.c index cb920ab14a268..a0377ddb1f898 100644 --- a/ext/pdo_oci/oci_driver.c +++ b/ext/pdo_oci/oci_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_oci/oci_statement.c b/ext/pdo_oci/oci_statement.c index da3542559fdb9..2a93a66a843df 100644 --- a/ext/pdo_oci/oci_statement.c +++ b/ext/pdo_oci/oci_statement.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_oci/pdo_oci.c b/ext/pdo_oci/pdo_oci.c index a0a05839e66d0..69577148f647f 100644 --- a/ext/pdo_oci/pdo_oci.c +++ b/ext/pdo_oci/pdo_oci.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_oci/php_pdo_oci.h b/ext/pdo_oci/php_pdo_oci.h index ae96edc7c89cc..d0b1b3d01535e 100644 --- a/ext/pdo_oci/php_pdo_oci.h +++ b/ext/pdo_oci/php_pdo_oci.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_oci/php_pdo_oci_int.h b/ext/pdo_oci/php_pdo_oci_int.h index 990225493f996..af5618b61abdd 100644 --- a/ext/pdo_oci/php_pdo_oci_int.h +++ b/ext/pdo_oci/php_pdo_oci_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_odbc/odbc_driver.c b/ext/pdo_odbc/odbc_driver.c index ca2808c6f5438..33163688eb4ea 100644 --- a/ext/pdo_odbc/odbc_driver.c +++ b/ext/pdo_odbc/odbc_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_odbc/odbc_stmt.c b/ext/pdo_odbc/odbc_stmt.c index e700ef8c3ce1a..6ee2fcd6becb6 100644 --- a/ext/pdo_odbc/odbc_stmt.c +++ b/ext/pdo_odbc/odbc_stmt.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_odbc/pdo_odbc.c b/ext/pdo_odbc/pdo_odbc.c index 72553c421c400..f481c07f26f5a 100644 --- a/ext/pdo_odbc/pdo_odbc.c +++ b/ext/pdo_odbc/pdo_odbc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_odbc/php_pdo_odbc.h b/ext/pdo_odbc/php_pdo_odbc.h index c62e6c3fa91ab..ee80e7517bef4 100644 --- a/ext/pdo_odbc/php_pdo_odbc.h +++ b/ext/pdo_odbc/php_pdo_odbc.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_odbc/php_pdo_odbc_int.h b/ext/pdo_odbc/php_pdo_odbc_int.h index e200d7ce63438..8594120ef04de 100644 --- a/ext/pdo_odbc/php_pdo_odbc_int.h +++ b/ext/pdo_odbc/php_pdo_odbc_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.0 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_pgsql/pdo_pgsql.c b/ext/pdo_pgsql/pdo_pgsql.c index 2eda36f5dd022..7c37a603f85d1 100644 --- a/ext/pdo_pgsql/pdo_pgsql.c +++ b/ext/pdo_pgsql/pdo_pgsql.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c index 23ea5e58a256c..a54fccd0e6333 100644 --- a/ext/pdo_pgsql/pgsql_driver.c +++ b/ext/pdo_pgsql/pgsql_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_pgsql/pgsql_statement.c b/ext/pdo_pgsql/pgsql_statement.c index 1dc0d58e97623..d58eebf8f4395 100644 --- a/ext/pdo_pgsql/pgsql_statement.c +++ b/ext/pdo_pgsql/pgsql_statement.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_pgsql/php_pdo_pgsql.h b/ext/pdo_pgsql/php_pdo_pgsql.h index 478e9cb103e5c..b7ea2628e7c08 100644 --- a/ext/pdo_pgsql/php_pdo_pgsql.h +++ b/ext/pdo_pgsql/php_pdo_pgsql.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_pgsql/php_pdo_pgsql_int.h b/ext/pdo_pgsql/php_pdo_pgsql_int.h index 4829b3c785187..02a6717760cd6 100644 --- a/ext/pdo_pgsql/php_pdo_pgsql_int.h +++ b/ext/pdo_pgsql/php_pdo_pgsql_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_sqlite/pdo_sqlite.c b/ext/pdo_sqlite/pdo_sqlite.c index d15bdf3260125..cc9b03e62daf2 100644 --- a/ext/pdo_sqlite/pdo_sqlite.c +++ b/ext/pdo_sqlite/pdo_sqlite.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_sqlite/php_pdo_sqlite.h b/ext/pdo_sqlite/php_pdo_sqlite.h index 232f8a9ff5159..6fa3bab1ff967 100644 --- a/ext/pdo_sqlite/php_pdo_sqlite.h +++ b/ext/pdo_sqlite/php_pdo_sqlite.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_sqlite/php_pdo_sqlite_int.h b/ext/pdo_sqlite/php_pdo_sqlite_int.h index 8da419674f230..8e20ca5cf4f1b 100644 --- a/ext/pdo_sqlite/php_pdo_sqlite_int.h +++ b/ext/pdo_sqlite/php_pdo_sqlite_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_sqlite/sqlite_driver.c b/ext/pdo_sqlite/sqlite_driver.c index 480c728d1546b..0f4a2456a1df3 100644 --- a/ext/pdo_sqlite/sqlite_driver.c +++ b/ext/pdo_sqlite/sqlite_driver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pdo_sqlite/sqlite_statement.c b/ext/pdo_sqlite/sqlite_statement.c index 85481edd2553b..d5b4df1fda0cb 100644 --- a/ext/pdo_sqlite/sqlite_statement.c +++ b/ext/pdo_sqlite/sqlite_statement.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c index ad66779606bc7..d01dda6037f20 100644 --- a/ext/pgsql/pgsql.c +++ b/ext/pgsql/pgsql.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pgsql/php_pgsql.h b/ext/pgsql/php_pgsql.h index 8b6abbf91c064..63f50f0f99927 100644 --- a/ext/pgsql/php_pgsql.h +++ b/ext/pgsql/php_pgsql.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/posix/php_posix.h b/ext/posix/php_posix.h index 1e77efd9c6455..2c073496b55c6 100644 --- a/ext/posix/php_posix.h +++ b/ext/posix/php_posix.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/posix/posix.c b/ext/posix/posix.c index 967584c6fadb3..32db6705f5b61 100644 --- a/ext/posix/posix.c +++ b/ext/posix/posix.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pspell/php_pspell.h b/ext/pspell/php_pspell.h index 5c4561ce59aba..b4e97f3a6f6c2 100644 --- a/ext/pspell/php_pspell.h +++ b/ext/pspell/php_pspell.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/pspell/pspell.c b/ext/pspell/pspell.c index f6c1ee074fff3..79a597e86201f 100644 --- a/ext/pspell/pspell.c +++ b/ext/pspell/pspell.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/readline/php_readline.h b/ext/readline/php_readline.h index bc0b4895741fd..a9f8287ad2475 100644 --- a/ext/readline/php_readline.h +++ b/ext/readline/php_readline.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/readline/readline.c b/ext/readline/readline.c index 92236a54f7e1e..3148f80db0160 100644 --- a/ext/readline/readline.c +++ b/ext/readline/readline.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/readline/readline_cli.c b/ext/readline/readline_cli.c index 23e744e805a29..f4ce12bade032 100644 --- a/ext/readline/readline_cli.c +++ b/ext/readline/readline_cli.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/readline/readline_cli.h b/ext/readline/readline_cli.h index d2925fe180468..d9deb8a04cb77 100644 --- a/ext/readline/readline_cli.h +++ b/ext/readline/readline_cli.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/recode/php_recode.h b/ext/recode/php_recode.h index f35e86c2948f2..9faa01cc20edf 100644 --- a/ext/recode/php_recode.h +++ b/ext/recode/php_recode.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/recode/recode.c b/ext/recode/recode.c index a1a74deff3223..7203cb24eac01 100644 --- a/ext/recode/recode.c +++ b/ext/recode/recode.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index fb496936c25d6..ff3a6a5087288 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/reflection/php_reflection.h b/ext/reflection/php_reflection.h index 6f288546fc0f1..48470f4f63980 100644 --- a/ext/reflection/php_reflection.h +++ b/ext/reflection/php_reflection.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_files.c b/ext/session/mod_files.c index 621c4e1db727b..1665ba53aa439 100644 --- a/ext/session/mod_files.c +++ b/ext/session/mod_files.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_files.h b/ext/session/mod_files.h index 43ac47f1acf29..c97d168b1ee17 100644 --- a/ext/session/mod_files.h +++ b/ext/session/mod_files.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_mm.c b/ext/session/mod_mm.c index b99dd82191e1e..e5406d0bcb8e4 100644 --- a/ext/session/mod_mm.c +++ b/ext/session/mod_mm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_mm.h b/ext/session/mod_mm.h index adec504578867..3ddadced4e6c1 100644 --- a/ext/session/mod_mm.h +++ b/ext/session/mod_mm.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_user.c b/ext/session/mod_user.c index 84a28d3427593..57d7bd0edcdfc 100644 --- a/ext/session/mod_user.c +++ b/ext/session/mod_user.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_user.h b/ext/session/mod_user.h index ea1980ab4890e..fd149ccff44fd 100644 --- a/ext/session/mod_user.h +++ b/ext/session/mod_user.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/mod_user_class.c b/ext/session/mod_user_class.c index 4edac28b86322..1ed1e7bbd50ac 100644 --- a/ext/session/mod_user_class.c +++ b/ext/session/mod_user_class.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/php_session.h b/ext/session/php_session.h index ba0195bec46f4..adc5e70402c2e 100644 --- a/ext/session/php_session.h +++ b/ext/session/php_session.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/session/session.c b/ext/session/session.c index 0c08d496816cf..a3be9a78c2004 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/shmop/php_shmop.h b/ext/shmop/php_shmop.h index 89e5d2ad37cb5..0abc703d1fcbe 100644 --- a/ext/shmop/php_shmop.h +++ b/ext/shmop/php_shmop.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/shmop/shmop.c b/ext/shmop/shmop.c index 17665bed85cf9..a14a0b7e45e40 100644 --- a/ext/shmop/shmop.c +++ b/ext/shmop/shmop.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/simplexml/php_simplexml.h b/ext/simplexml/php_simplexml.h index 9cc6db21e7770..c340a5e8a6cb4 100644 --- a/ext/simplexml/php_simplexml.h +++ b/ext/simplexml/php_simplexml.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/simplexml/php_simplexml_exports.h b/ext/simplexml/php_simplexml_exports.h index 2ff0765734843..66ec3bd28d897 100644 --- a/ext/simplexml/php_simplexml_exports.h +++ b/ext/simplexml/php_simplexml_exports.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index b510786660a2d..692516840b2d7 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/simplexml/sxe.c b/ext/simplexml/sxe.c index 2e9a5b7c2cd78..e3278da631b8b 100644 --- a/ext/simplexml/sxe.c +++ b/ext/simplexml/sxe.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/simplexml/sxe.h b/ext/simplexml/sxe.h index 4c39b9aa12126..5a40fefcb97e2 100644 --- a/ext/simplexml/sxe.h +++ b/ext/simplexml/sxe.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h index fe37917c768c8..a9e7eb3f2d5e4 100644 --- a/ext/snmp/php_snmp.h +++ b/ext/snmp/php_snmp.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c index 87c5e0733dc0f..4fdfd566799fb 100644 --- a/ext/snmp/snmp.c +++ b/ext/snmp/snmp.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_encoding.c b/ext/soap/php_encoding.c index 5addec4ff2d08..897956d91b772 100644 --- a/ext/soap/php_encoding.c +++ b/ext/soap/php_encoding.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_encoding.h b/ext/soap/php_encoding.h index f3e8f9bbfa341..31a8469390e72 100644 --- a/ext/soap/php_encoding.h +++ b/ext/soap/php_encoding.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_http.c b/ext/soap/php_http.c index 69deccde7fa84..d83b85e639eb4 100644 --- a/ext/soap/php_http.c +++ b/ext/soap/php_http.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_http.h b/ext/soap/php_http.h index 540a91708a390..70d2cfd4c2dd8 100644 --- a/ext/soap/php_http.h +++ b/ext/soap/php_http.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_packet_soap.c b/ext/soap/php_packet_soap.c index c2e3fc3e3a219..f4d249c4a9bd5 100644 --- a/ext/soap/php_packet_soap.c +++ b/ext/soap/php_packet_soap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_packet_soap.h b/ext/soap/php_packet_soap.h index c262a3a1b013d..210539bcd0919 100644 --- a/ext/soap/php_packet_soap.h +++ b/ext/soap/php_packet_soap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_schema.c b/ext/soap/php_schema.c index 41efb0b685011..7d2e129746ef2 100644 --- a/ext/soap/php_schema.c +++ b/ext/soap/php_schema.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_schema.h b/ext/soap/php_schema.h index 19ddb28ade44a..81748f5f65a93 100644 --- a/ext/soap/php_schema.h +++ b/ext/soap/php_schema.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_sdl.c b/ext/soap/php_sdl.c index d250850786940..33e137cbbb70c 100644 --- a/ext/soap/php_sdl.c +++ b/ext/soap/php_sdl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_sdl.h b/ext/soap/php_sdl.h index c25cda3647c06..78757d15fcd87 100644 --- a/ext/soap/php_sdl.h +++ b/ext/soap/php_sdl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_soap.h b/ext/soap/php_soap.h index 37edec79abd11..0e37db5d4cacc 100644 --- a/ext/soap/php_soap.h +++ b/ext/soap/php_soap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_xml.c b/ext/soap/php_xml.c index 9c1f96e215830..cf7fead6b3be2 100644 --- a/ext/soap/php_xml.c +++ b/ext/soap/php_xml.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/php_xml.h b/ext/soap/php_xml.h index cee5bbd42df32..61c0feb58cc9d 100644 --- a/ext/soap/php_xml.h +++ b/ext/soap/php_xml.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/soap/soap.c b/ext/soap/soap.c index cd45ec68535ae..13f163ab3d6a9 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index e29106087e10c..d4a00a8d174d8 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sockets/multicast.h b/ext/sockets/multicast.h index 9470a39ca2561..498a71f67a125 100644 --- a/ext/sockets/multicast.h +++ b/ext/sockets/multicast.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 38a68879b135b..df205e5114d7b 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index f29dab68fca43..5d09ad7fa9715 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sockets/unix_socket_constants.h b/ext/sockets/unix_socket_constants.h index 9e7a11407f3d3..fb190d82b12d5 100644 --- a/ext/sockets/unix_socket_constants.h +++ b/ext/sockets/unix_socket_constants.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sockets/win32_socket_constants.h b/ext/sockets/win32_socket_constants.h index da3baf0156a87..542347dd07662 100644 --- a/ext/sockets/win32_socket_constants.h +++ b/ext/sockets/win32_socket_constants.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/php_spl.c b/ext/spl/php_spl.c index cd0086626fc7d..35f4e5056bb45 100644 --- a/ext/spl/php_spl.c +++ b/ext/spl/php_spl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/php_spl.h b/ext/spl/php_spl.h index 855a78c4047f8..4794f12443eaa 100644 --- a/ext/spl/php_spl.h +++ b/ext/spl/php_spl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_array.c b/ext/spl/spl_array.c index 3c6b41edbc975..479c14839d112 100644 --- a/ext/spl/spl_array.c +++ b/ext/spl/spl_array.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_array.h b/ext/spl/spl_array.h index 909f4c97dc360..0423d89a3ac5d 100644 --- a/ext/spl/spl_array.h +++ b/ext/spl/spl_array.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c index b86e68659dd65..61d6324d52826 100644 --- a/ext/spl/spl_directory.c +++ b/ext/spl/spl_directory.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_directory.h b/ext/spl/spl_directory.h index 96f5dd6cb74c2..d95ba550f8a30 100644 --- a/ext/spl/spl_directory.h +++ b/ext/spl/spl_directory.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_dllist.c b/ext/spl/spl_dllist.c index 5cc586f48af28..a8417feada370 100644 --- a/ext/spl/spl_dllist.c +++ b/ext/spl/spl_dllist.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_dllist.h b/ext/spl/spl_dllist.h index a8078b81adcb4..8615f748b8563 100644 --- a/ext/spl/spl_dllist.h +++ b/ext/spl/spl_dllist.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_engine.c b/ext/spl/spl_engine.c index d501f314352bb..ea2349f41e9dd 100644 --- a/ext/spl/spl_engine.c +++ b/ext/spl/spl_engine.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_engine.h b/ext/spl/spl_engine.h index db7affef8005f..103a5c4c76b14 100644 --- a/ext/spl/spl_engine.h +++ b/ext/spl/spl_engine.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_exceptions.c b/ext/spl/spl_exceptions.c index 570299a2a8f7d..d905070f41bcd 100644 --- a/ext/spl/spl_exceptions.c +++ b/ext/spl/spl_exceptions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_exceptions.h b/ext/spl/spl_exceptions.h index 8d3a58a30ce6f..e4e7f270de189 100644 --- a/ext/spl/spl_exceptions.h +++ b/ext/spl/spl_exceptions.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c index 87bb23efc73a6..1d51e0fb622b1 100644 --- a/ext/spl/spl_fixedarray.c +++ b/ext/spl/spl_fixedarray.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_fixedarray.h b/ext/spl/spl_fixedarray.h index 65a4c7d909ac2..8f1b8df1038d2 100644 --- a/ext/spl/spl_fixedarray.h +++ b/ext/spl/spl_fixedarray.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_functions.c b/ext/spl/spl_functions.c index b9fd5dc8b9e50..7f17d5ef239fa 100644 --- a/ext/spl/spl_functions.c +++ b/ext/spl/spl_functions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_functions.h b/ext/spl/spl_functions.h index 394de6ae9d70d..29ce4a7640dea 100644 --- a/ext/spl/spl_functions.h +++ b/ext/spl/spl_functions.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_heap.c b/ext/spl/spl_heap.c index c6decd0ad53f2..d2de85b2a78c3 100644 --- a/ext/spl/spl_heap.c +++ b/ext/spl/spl_heap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_heap.h b/ext/spl/spl_heap.h index 2e2c38ce70e56..11bce04553f0c 100644 --- a/ext/spl/spl_heap.h +++ b/ext/spl/spl_heap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index 7b77cf5bb1f58..87b3763cfd7f8 100644 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_iterators.h b/ext/spl/spl_iterators.h index 4a2c999c30cae..39cc0d1337def 100644 --- a/ext/spl/spl_iterators.h +++ b/ext/spl/spl_iterators.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c index 2176e025ab112..5d89566eec1fa 100644 --- a/ext/spl/spl_observer.c +++ b/ext/spl/spl_observer.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/spl/spl_observer.h b/ext/spl/spl_observer.h index bfee74f300b9a..e93e304310e2a 100644 --- a/ext/spl/spl_observer.h +++ b/ext/spl/spl_observer.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sqlite3/php_sqlite3.h b/ext/sqlite3/php_sqlite3.h index 87a93353823fd..b558f70340522 100644 --- a/ext/sqlite3/php_sqlite3.h +++ b/ext/sqlite3/php_sqlite3.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sqlite3/php_sqlite3_structs.h b/ext/sqlite3/php_sqlite3_structs.h index 863365b4d8f6b..0e813b6dfdc87 100644 --- a/ext/sqlite3/php_sqlite3_structs.h +++ b/ext/sqlite3/php_sqlite3_structs.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c index 0bb8616d96f03..881e3c3705f28 100644 --- a/ext/sqlite3/sqlite3.c +++ b/ext/sqlite3/sqlite3.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/array.c b/ext/standard/array.c index 94c5e7e6ee7de..40a27c053629c 100644 --- a/ext/standard/array.c +++ b/ext/standard/array.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/assert.c b/ext/standard/assert.c index 15fbefd51ce5b..631834c97c0f3 100644 --- a/ext/standard/assert.c +++ b/ext/standard/assert.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/base64.c b/ext/standard/base64.c index d78cb244c5e22..7534c8f8a4063 100644 --- a/ext/standard/base64.c +++ b/ext/standard/base64.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/base64.h b/ext/standard/base64.h index 12cb214a22750..3f9d818baa210 100644 --- a/ext/standard/base64.h +++ b/ext/standard/base64.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index d6377df84d682..a40fdd23979f1 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/basic_functions.h b/ext/standard/basic_functions.h index 04fea70051cf2..7327f7d2d2ecd 100644 --- a/ext/standard/basic_functions.h +++ b/ext/standard/basic_functions.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/browscap.c b/ext/standard/browscap.c index ae5e90cf9b709..1e1252f60a363 100644 --- a/ext/standard/browscap.c +++ b/ext/standard/browscap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/crc32.c b/ext/standard/crc32.c index c2fe4c6291aba..e9c36d4cb4fea 100644 --- a/ext/standard/crc32.c +++ b/ext/standard/crc32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/crc32.h b/ext/standard/crc32.h index c591dbf0e5133..2c8ded4587225 100644 --- a/ext/standard/crc32.h +++ b/ext/standard/crc32.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/credits.c b/ext/standard/credits.c index 695c06ead814f..530c8d0e63b45 100644 --- a/ext/standard/credits.c +++ b/ext/standard/credits.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/credits.h b/ext/standard/credits.h index a750751bb10ae..7ad99d9f8245f 100644 --- a/ext/standard/credits.h +++ b/ext/standard/credits.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c index 3b443fc4d5a31..113a5bd0f516c 100644 --- a/ext/standard/crypt.c +++ b/ext/standard/crypt.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/css.c b/ext/standard/css.c index 17588c2417aef..d76f9ee662676 100644 --- a/ext/standard/css.c +++ b/ext/standard/css.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/css.h b/ext/standard/css.h index ab496586cbf35..d7275e08efd04 100644 --- a/ext/standard/css.h +++ b/ext/standard/css.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/cyr_convert.c b/ext/standard/cyr_convert.c index d4b282ecd7439..b29b49374ebc0 100644 --- a/ext/standard/cyr_convert.c +++ b/ext/standard/cyr_convert.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/cyr_convert.h b/ext/standard/cyr_convert.h index 673ec4b76394a..afcb872541193 100644 --- a/ext/standard/cyr_convert.h +++ b/ext/standard/cyr_convert.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/datetime.c b/ext/standard/datetime.c index 96de8e128cd63..394153264db4c 100644 --- a/ext/standard/datetime.c +++ b/ext/standard/datetime.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/datetime.h b/ext/standard/datetime.h index d9fcdef28ad6a..3612fafae35da 100644 --- a/ext/standard/datetime.h +++ b/ext/standard/datetime.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/dir.c b/ext/standard/dir.c index d921f7c3f5a4e..ef28e9feafbc6 100644 --- a/ext/standard/dir.c +++ b/ext/standard/dir.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/dl.c b/ext/standard/dl.c index 6645ac6fc45c8..1960e2ce07e38 100644 --- a/ext/standard/dl.c +++ b/ext/standard/dl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/dl.h b/ext/standard/dl.h index 585dc6c69661d..030f50e9332d6 100644 --- a/ext/standard/dl.h +++ b/ext/standard/dl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/dns.c b/ext/standard/dns.c index 53483ff58b62e..074c16ee9fcc4 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/exec.c b/ext/standard/exec.c index a5ca84bb6b813..7b783ca60f60f 100644 --- a/ext/standard/exec.c +++ b/ext/standard/exec.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/exec.h b/ext/standard/exec.h index f53d613d356ba..14c98c57e36a5 100644 --- a/ext/standard/exec.h +++ b/ext/standard/exec.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/file.c b/ext/standard/file.c index 5dc91b44b332d..74577ac495de2 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/file.h b/ext/standard/file.h index 2d2406e0d545e..0a4512ecd4ac8 100644 --- a/ext/standard/file.h +++ b/ext/standard/file.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c index 4e5f768381a5a..8e88a8508095c 100644 --- a/ext/standard/filestat.c +++ b/ext/standard/filestat.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/filters.c b/ext/standard/filters.c index a191577854bca..084860c76b433 100644 --- a/ext/standard/filters.c +++ b/ext/standard/filters.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/flock_compat.c b/ext/standard/flock_compat.c index 9eea78bacbda4..41f95eb724548 100644 --- a/ext/standard/flock_compat.c +++ b/ext/standard/flock_compat.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/flock_compat.h b/ext/standard/flock_compat.h index 30f37d6a75950..819d63c800bc0 100644 --- a/ext/standard/flock_compat.h +++ b/ext/standard/flock_compat.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/formatted_print.c b/ext/standard/formatted_print.c index 5623a3755b34d..0035d204f6515 100644 --- a/ext/standard/formatted_print.c +++ b/ext/standard/formatted_print.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/fsock.c b/ext/standard/fsock.c index b73ab719c7b9a..b7d53359273ef 100644 --- a/ext/standard/fsock.c +++ b/ext/standard/fsock.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/fsock.h b/ext/standard/fsock.h index ad9e3372e1610..70d0a5b50afb9 100644 --- a/ext/standard/fsock.h +++ b/ext/standard/fsock.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/ftok.c b/ext/standard/ftok.c index 4f67d1ec8a131..3b0105994c4ff 100644 --- a/ext/standard/ftok.c +++ b/ext/standard/ftok.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/ftp_fopen_wrapper.c b/ext/standard/ftp_fopen_wrapper.c index 16ff550ecbc93..373293935835d 100644 --- a/ext/standard/ftp_fopen_wrapper.c +++ b/ext/standard/ftp_fopen_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/head.c b/ext/standard/head.c index dfeb0e0f18ad4..97f61f2bef128 100644 --- a/ext/standard/head.c +++ b/ext/standard/head.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/head.h b/ext/standard/head.h index ddc29cdd9b3fa..7d657ba445ef0 100644 --- a/ext/standard/head.h +++ b/ext/standard/head.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/html.c b/ext/standard/html.c index 65e63f41cc9f8..79a6737ca500d 100644 --- a/ext/standard/html.c +++ b/ext/standard/html.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/html.h b/ext/standard/html.h index 30905684a5685..ae114765b2606 100644 --- a/ext/standard/html.h +++ b/ext/standard/html.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/html_tables.h b/ext/standard/html_tables.h index bf66af36fa6d5..c24531d11c61c 100644 --- a/ext/standard/html_tables.h +++ b/ext/standard/html_tables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/http.c b/ext/standard/http.c index 8f5625e2448b4..3e5073591e4ab 100644 --- a/ext/standard/http.c +++ b/ext/standard/http.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index 4939a742acdf3..85a61167aa10d 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/image.c b/ext/standard/image.c index de49fb38e209a..ebf894aa56d02 100644 --- a/ext/standard/image.c +++ b/ext/standard/image.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/incomplete_class.c b/ext/standard/incomplete_class.c index f6d3750e2b0c7..9af70f2856306 100644 --- a/ext/standard/incomplete_class.c +++ b/ext/standard/incomplete_class.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/info.c b/ext/standard/info.c index beb147797d91d..20e6b0c4a21fd 100644 --- a/ext/standard/info.c +++ b/ext/standard/info.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/info.h b/ext/standard/info.h index 98185936649c8..46a0dfc24080d 100644 --- a/ext/standard/info.h +++ b/ext/standard/info.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/iptc.c b/ext/standard/iptc.c index 43dc372bcfa56..729b0597e3628 100644 --- a/ext/standard/iptc.c +++ b/ext/standard/iptc.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/lcg.c b/ext/standard/lcg.c index 46551daf08f85..8bbe6035162c7 100644 --- a/ext/standard/lcg.c +++ b/ext/standard/lcg.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/levenshtein.c b/ext/standard/levenshtein.c index 4e46b51b47c8b..c492982101fe5 100644 --- a/ext/standard/levenshtein.c +++ b/ext/standard/levenshtein.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/link.c b/ext/standard/link.c index 3832e703bb4af..8da63958a7ba2 100644 --- a/ext/standard/link.c +++ b/ext/standard/link.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/link_win32.c b/ext/standard/link_win32.c index effe67bd7883d..674745e0a1d55 100644 --- a/ext/standard/link_win32.c +++ b/ext/standard/link_win32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/mail.c b/ext/standard/mail.c index 364f7fc3999ab..25766818f6b50 100644 --- a/ext/standard/mail.c +++ b/ext/standard/mail.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/math.c b/ext/standard/math.c index 6e934a3857a7c..be2d655263f13 100644 --- a/ext/standard/math.c +++ b/ext/standard/math.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/md5.c b/ext/standard/md5.c index 91a5e8ceef950..7fea069dbb350 100644 --- a/ext/standard/md5.c +++ b/ext/standard/md5.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/md5.h b/ext/standard/md5.h index d9b94219b8435..d7834054e7958 100644 --- a/ext/standard/md5.h +++ b/ext/standard/md5.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/metaphone.c b/ext/standard/metaphone.c index c2f743b09f2da..62c6df64aacfb 100644 --- a/ext/standard/metaphone.c +++ b/ext/standard/metaphone.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/microtime.c b/ext/standard/microtime.c index 7e844a278b3e9..219e35df16020 100644 --- a/ext/standard/microtime.c +++ b/ext/standard/microtime.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/microtime.h b/ext/standard/microtime.h index 6a44a4cb69d5b..95d4fab294144 100644 --- a/ext/standard/microtime.h +++ b/ext/standard/microtime.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/pack.c b/ext/standard/pack.c index 0472cb24a9c50..672c0652219b0 100644 --- a/ext/standard/pack.c +++ b/ext/standard/pack.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/pack.h b/ext/standard/pack.h index 370931a65c0d9..22932887ce986 100644 --- a/ext/standard/pack.h +++ b/ext/standard/pack.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/pageinfo.c b/ext/standard/pageinfo.c index c9bb34d0b6a1b..6add7269cf23c 100644 --- a/ext/standard/pageinfo.c +++ b/ext/standard/pageinfo.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/pageinfo.h b/ext/standard/pageinfo.h index 6fab2e00071ec..9ce76811bcec5 100644 --- a/ext/standard/pageinfo.h +++ b/ext/standard/pageinfo.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/password.c b/ext/standard/password.c index 266ad0a42174a..212799100c303 100644 --- a/ext/standard/password.c +++ b/ext/standard/password.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_array.h b/ext/standard/php_array.h index e63e01c61ee65..942c33f9e817d 100644 --- a/ext/standard/php_array.h +++ b/ext/standard/php_array.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_assert.h b/ext/standard/php_assert.h index 897a7a75204ee..02bf27706cdbe 100644 --- a/ext/standard/php_assert.h +++ b/ext/standard/php_assert.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_browscap.h b/ext/standard/php_browscap.h index 3ee51ea77ec3f..da48ccebebdc4 100644 --- a/ext/standard/php_browscap.h +++ b/ext/standard/php_browscap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_crypt.h b/ext/standard/php_crypt.h index 7410a8c3280b9..6025685539809 100644 --- a/ext/standard/php_crypt.h +++ b/ext/standard/php_crypt.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c index f2c754e2f29dd..84979946259f0 100644 --- a/ext/standard/php_crypt_r.c +++ b/ext/standard/php_crypt_r.c @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_crypt_r.h b/ext/standard/php_crypt_r.h index 22b2ebd4f7319..c7f36eaf211d1 100644 --- a/ext/standard/php_crypt_r.h +++ b/ext/standard/php_crypt_r.h @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_dir.h b/ext/standard/php_dir.h index 15c9690eaa4d5..432ee33ac3ce0 100644 --- a/ext/standard/php_dir.h +++ b/ext/standard/php_dir.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_dns.h b/ext/standard/php_dns.h index ef82ff9badde1..0ee8aaab43556 100644 --- a/ext/standard/php_dns.h +++ b/ext/standard/php_dns.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_ext_syslog.h b/ext/standard/php_ext_syslog.h index cc72d6634bb09..21d6cd47627af 100644 --- a/ext/standard/php_ext_syslog.h +++ b/ext/standard/php_ext_syslog.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_filestat.h b/ext/standard/php_filestat.h index 2b937bbf1adf5..e8e798c510262 100644 --- a/ext/standard/php_filestat.h +++ b/ext/standard/php_filestat.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_fopen_wrapper.c b/ext/standard/php_fopen_wrapper.c index b51aaa219f23d..f8d7bda482385 100644 --- a/ext/standard/php_fopen_wrapper.c +++ b/ext/standard/php_fopen_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_fopen_wrappers.h b/ext/standard/php_fopen_wrappers.h index 8476e531822ae..5f78256bcb423 100644 --- a/ext/standard/php_fopen_wrappers.h +++ b/ext/standard/php_fopen_wrappers.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_ftok.h b/ext/standard/php_ftok.h index 4d84e95c27e39..b339349e493e7 100644 --- a/ext/standard/php_ftok.h +++ b/ext/standard/php_ftok.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_http.h b/ext/standard/php_http.h index e0fdeded26bba..468fd0508cc33 100644 --- a/ext/standard/php_http.h +++ b/ext/standard/php_http.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_image.h b/ext/standard/php_image.h index 5562f997e5439..a56e2a0f265b5 100644 --- a/ext/standard/php_image.h +++ b/ext/standard/php_image.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_incomplete_class.h b/ext/standard/php_incomplete_class.h index 027ff211d5af3..f998996d62238 100644 --- a/ext/standard/php_incomplete_class.h +++ b/ext/standard/php_incomplete_class.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_iptc.h b/ext/standard/php_iptc.h index ffb22013c3a62..6b8c50efb2e31 100644 --- a/ext/standard/php_iptc.h +++ b/ext/standard/php_iptc.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_lcg.h b/ext/standard/php_lcg.h index 9a340c34a1729..3bdab4aab38b9 100644 --- a/ext/standard/php_lcg.h +++ b/ext/standard/php_lcg.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_link.h b/ext/standard/php_link.h index ebb7732d48464..ddc00429cf508 100644 --- a/ext/standard/php_link.h +++ b/ext/standard/php_link.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_mail.h b/ext/standard/php_mail.h index 87868242d4806..092dded660064 100644 --- a/ext/standard/php_mail.h +++ b/ext/standard/php_mail.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_math.h b/ext/standard/php_math.h index 3da3cf00891bf..116acd9df5e8b 100644 --- a/ext/standard/php_math.h +++ b/ext/standard/php_math.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_metaphone.h b/ext/standard/php_metaphone.h index 4b993e3a77181..6af07bbbb05f9 100644 --- a/ext/standard/php_metaphone.h +++ b/ext/standard/php_metaphone.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_password.h b/ext/standard/php_password.h index 079f187703879..abc343d66efd2 100644 --- a/ext/standard/php_password.h +++ b/ext/standard/php_password.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_rand.h b/ext/standard/php_rand.h index 61cf4408e284e..e831f32b23026 100644 --- a/ext/standard/php_rand.h +++ b/ext/standard/php_rand.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_smart_str.h b/ext/standard/php_smart_str.h index fcec7932abe73..2fef1d0bd0071 100644 --- a/ext/standard/php_smart_str.h +++ b/ext/standard/php_smart_str.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_smart_str_public.h b/ext/standard/php_smart_str_public.h index f208f79f7c6cc..ed36a7a6feb68 100644 --- a/ext/standard/php_smart_str_public.h +++ b/ext/standard/php_smart_str_public.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_standard.h b/ext/standard/php_standard.h index bccfebe54331f..3c7535da1ff13 100644 --- a/ext/standard/php_standard.h +++ b/ext/standard/php_standard.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_string.h b/ext/standard/php_string.h index 44ec0c76475e0..65219f257adee 100644 --- a/ext/standard/php_string.h +++ b/ext/standard/php_string.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_type.h b/ext/standard/php_type.h index 12e916b886ae3..e434ae05f4b26 100644 --- a/ext/standard/php_type.h +++ b/ext/standard/php_type.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_uuencode.h b/ext/standard/php_uuencode.h index 05fc828d009a5..28bcb09c3e897 100644 --- a/ext/standard/php_uuencode.h +++ b/ext/standard/php_uuencode.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_var.h b/ext/standard/php_var.h index 479f1a354e014..35343b3d5d068 100644 --- a/ext/standard/php_var.h +++ b/ext/standard/php_var.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/php_versioning.h b/ext/standard/php_versioning.h index 59135dac3c2ae..fcbedacc387aa 100644 --- a/ext/standard/php_versioning.h +++ b/ext/standard/php_versioning.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index 5ff91994a7071..6373751107189 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/proc_open.h b/ext/standard/proc_open.h index 9e89aa440d4ea..da1519b127271 100644 --- a/ext/standard/proc_open.h +++ b/ext/standard/proc_open.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/quot_print.c b/ext/standard/quot_print.c index 4eb69d7ef212d..28dcc63f1320e 100644 --- a/ext/standard/quot_print.c +++ b/ext/standard/quot_print.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/quot_print.h b/ext/standard/quot_print.h index 37f1951811378..f621caf4b439d 100644 --- a/ext/standard/quot_print.h +++ b/ext/standard/quot_print.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/rand.c b/ext/standard/rand.c index 85cd92d77db5e..5f55a41f91d7a 100644 --- a/ext/standard/rand.c +++ b/ext/standard/rand.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/scanf.c b/ext/standard/scanf.c index eecb0204d9ce2..02e2c7173d4c3 100644 --- a/ext/standard/scanf.c +++ b/ext/standard/scanf.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/scanf.h b/ext/standard/scanf.h index 7f2a843027b01..dbffca9bac3a1 100644 --- a/ext/standard/scanf.h +++ b/ext/standard/scanf.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/sha1.c b/ext/standard/sha1.c index 6e6a97980279b..4326db98a6724 100644 --- a/ext/standard/sha1.c +++ b/ext/standard/sha1.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/sha1.h b/ext/standard/sha1.h index e7908043871b9..450d457c6ea56 100644 --- a/ext/standard/sha1.h +++ b/ext/standard/sha1.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/soundex.c b/ext/standard/soundex.c index 21711167560ff..bb6818ecaa5e1 100644 --- a/ext/standard/soundex.c +++ b/ext/standard/soundex.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/streamsfuncs.c b/ext/standard/streamsfuncs.c index 86e0bc6e604ef..2231a30984098 100644 --- a/ext/standard/streamsfuncs.c +++ b/ext/standard/streamsfuncs.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/streamsfuncs.h b/ext/standard/streamsfuncs.h index 46357a21f1a62..b662de5e4fa9e 100644 --- a/ext/standard/streamsfuncs.h +++ b/ext/standard/streamsfuncs.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/string.c b/ext/standard/string.c index 7a4ae2e222cc7..771143d549958 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/syslog.c b/ext/standard/syslog.c index 7a83320e27c35..ff98ab8572957 100644 --- a/ext/standard/syslog.c +++ b/ext/standard/syslog.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/type.c b/ext/standard/type.c index f53107eb7aa7e..5d93f66f5b725 100644 --- a/ext/standard/type.c +++ b/ext/standard/type.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/uniqid.c b/ext/standard/uniqid.c index 242c8f9f4f999..eac389c26c459 100644 --- a/ext/standard/uniqid.c +++ b/ext/standard/uniqid.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/uniqid.h b/ext/standard/uniqid.h index 257bbecd785b9..1d0804051ac1b 100644 --- a/ext/standard/uniqid.h +++ b/ext/standard/uniqid.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/url.c b/ext/standard/url.c index c1593228377a8..94f6638d64721 100644 --- a/ext/standard/url.c +++ b/ext/standard/url.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/url.h b/ext/standard/url.h index 3eaca4834f328..87e2efbc73d29 100644 --- a/ext/standard/url.h +++ b/ext/standard/url.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/url_scanner_ex.c b/ext/standard/url_scanner_ex.c index f66b56220643e..cb5983f685d52 100644 --- a/ext/standard/url_scanner_ex.c +++ b/ext/standard/url_scanner_ex.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/url_scanner_ex.h b/ext/standard/url_scanner_ex.h index 235db7b5e45aa..667c56c1ec0f5 100644 --- a/ext/standard/url_scanner_ex.h +++ b/ext/standard/url_scanner_ex.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/url_scanner_ex.re b/ext/standard/url_scanner_ex.re index 2e37cf0ba4de8..760f725e983b1 100644 --- a/ext/standard/url_scanner_ex.re +++ b/ext/standard/url_scanner_ex.re @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/user_filters.c b/ext/standard/user_filters.c index bcc484205ccbb..b009e67aa155d 100644 --- a/ext/standard/user_filters.c +++ b/ext/standard/user_filters.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/uuencode.c b/ext/standard/uuencode.c index 9d4c7c506a6dd..f0142ed049964 100644 --- a/ext/standard/uuencode.c +++ b/ext/standard/uuencode.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/var.c b/ext/standard/var.c index a4fa262e76b21..b13edf6615c7b 100644 --- a/ext/standard/var.c +++ b/ext/standard/var.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/var_unserializer.c b/ext/standard/var_unserializer.c index 59995fb1a4a4e..857b2d4568e9d 100644 --- a/ext/standard/var_unserializer.c +++ b/ext/standard/var_unserializer.c @@ -4,7 +4,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/var_unserializer.re b/ext/standard/var_unserializer.re index 860b3947b9495..e54449a78c65d 100644 --- a/ext/standard/var_unserializer.re +++ b/ext/standard/var_unserializer.re @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/standard/versioning.c b/ext/standard/versioning.c index 0e7ba29a251a5..aadbcaf84ab52 100644 --- a/ext/standard/versioning.c +++ b/ext/standard/versioning.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c index a24e6677a29a6..bd4cf1429cb3e 100644 --- a/ext/sybase_ct/php_sybase_ct.c +++ b/ext/sybase_ct/php_sybase_ct.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sybase_ct/php_sybase_ct.h b/ext/sybase_ct/php_sybase_ct.h index df88aee1e9a73..f2ac3d04603bb 100644 --- a/ext/sybase_ct/php_sybase_ct.h +++ b/ext/sybase_ct/php_sybase_ct.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sysvmsg/php_sysvmsg.h b/ext/sysvmsg/php_sysvmsg.h index 477c20d96dc23..86c8c1ec21541 100644 --- a/ext/sysvmsg/php_sysvmsg.h +++ b/ext/sysvmsg/php_sysvmsg.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sysvmsg/sysvmsg.c b/ext/sysvmsg/sysvmsg.c index 6360183f0075e..e268047b695fe 100644 --- a/ext/sysvmsg/sysvmsg.c +++ b/ext/sysvmsg/sysvmsg.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sysvsem/php_sysvsem.h b/ext/sysvsem/php_sysvsem.h index aff9631598f1a..c4598f56f20e1 100644 --- a/ext/sysvsem/php_sysvsem.h +++ b/ext/sysvsem/php_sysvsem.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sysvsem/sysvsem.c b/ext/sysvsem/sysvsem.c index ed7c1736d59bd..b6e5ccb7dc593 100644 --- a/ext/sysvsem/sysvsem.c +++ b/ext/sysvsem/sysvsem.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sysvshm/php_sysvshm.h b/ext/sysvshm/php_sysvshm.h index 5b0b60a64a944..280b3e487caed 100644 --- a/ext/sysvshm/php_sysvshm.h +++ b/ext/sysvshm/php_sysvshm.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/sysvshm/sysvshm.c b/ext/sysvshm/sysvshm.c index 91617ed478410..2d4f66aead096 100644 --- a/ext/sysvshm/sysvshm.c +++ b/ext/sysvshm/sysvshm.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/tidy/php_tidy.h b/ext/tidy/php_tidy.h index 5ec65bb2278f3..94178039b1a26 100644 --- a/ext/tidy/php_tidy.h +++ b/ext/tidy/php_tidy.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/tidy/tidy.c b/ext/tidy/tidy.c index 72d8f5db662ca..5cfb1645692c3 100644 --- a/ext/tidy/tidy.c +++ b/ext/tidy/tidy.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/tokenizer/php_tokenizer.h b/ext/tokenizer/php_tokenizer.h index b4e26963d1c55..761556a14b686 100644 --- a/ext/tokenizer/php_tokenizer.h +++ b/ext/tokenizer/php_tokenizer.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/tokenizer/tokenizer.c b/ext/tokenizer/tokenizer.c index d22fd71243380..ee96e2eaa11e1 100644 --- a/ext/tokenizer/tokenizer.c +++ b/ext/tokenizer/tokenizer.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c index c1b3e57662414..57b29e1dd7006 100644 --- a/ext/tokenizer/tokenizer_data.c +++ b/ext/tokenizer/tokenizer_data.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/tokenizer/tokenizer_data_gen.sh b/ext/tokenizer/tokenizer_data_gen.sh index 4519f9098fd6f..4ccbd2ac67cbb 100755 --- a/ext/tokenizer/tokenizer_data_gen.sh +++ b/ext/tokenizer/tokenizer_data_gen.sh @@ -16,7 +16,7 @@ echo '/* +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/wddx/php_wddx.h b/ext/wddx/php_wddx.h index 9fc5c01faedfd..923816a40eab9 100644 --- a/ext/wddx/php_wddx.h +++ b/ext/wddx/php_wddx.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/wddx/php_wddx_api.h b/ext/wddx/php_wddx_api.h index 37d07891c070e..1a0194535d2df 100644 --- a/ext/wddx/php_wddx_api.h +++ b/ext/wddx/php_wddx_api.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/wddx/wddx.c b/ext/wddx/wddx.c index 88990ab02eaf8..967da6a490428 100644 --- a/ext/wddx/wddx.c +++ b/ext/wddx/wddx.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xml/compat.c b/ext/xml/compat.c index 40da824ad8e2a..fbebb635eebf0 100644 --- a/ext/xml/compat.c +++ b/ext/xml/compat.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xml/expat_compat.h b/ext/xml/expat_compat.h index bb6dbdd285311..424785f566fdb 100644 --- a/ext/xml/expat_compat.h +++ b/ext/xml/expat_compat.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xml/php_xml.h b/ext/xml/php_xml.h index 568c1a844c31d..7766834ea4eb7 100644 --- a/ext/xml/php_xml.h +++ b/ext/xml/php_xml.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xml/xml.c b/ext/xml/xml.c index 391e318a2d902..2fea4f8ab9b4e 100644 --- a/ext/xml/xml.c +++ b/ext/xml/xml.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c index c4a47b5a45e52..314be4529ff4b 100644 --- a/ext/xmlreader/php_xmlreader.c +++ b/ext/xmlreader/php_xmlreader.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xmlreader/php_xmlreader.h b/ext/xmlreader/php_xmlreader.h index 0cfa4a2d8d7db..a163135d36827 100644 --- a/ext/xmlreader/php_xmlreader.h +++ b/ext/xmlreader/php_xmlreader.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xmlrpc/php_xmlrpc.h b/ext/xmlrpc/php_xmlrpc.h index e264c7783b3fc..00f902086c3d3 100644 --- a/ext/xmlrpc/php_xmlrpc.h +++ b/ext/xmlrpc/php_xmlrpc.h @@ -37,7 +37,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xmlrpc/xmlrpc-epi-php.c b/ext/xmlrpc/xmlrpc-epi-php.c index cf5e257113c3b..925b554a56768 100644 --- a/ext/xmlrpc/xmlrpc-epi-php.c +++ b/ext/xmlrpc/xmlrpc-epi-php.c @@ -37,7 +37,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xmlwriter/php_xmlwriter.c b/ext/xmlwriter/php_xmlwriter.c index 0514b17ff6e9b..0a1439ced59fb 100644 --- a/ext/xmlwriter/php_xmlwriter.c +++ b/ext/xmlwriter/php_xmlwriter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xmlwriter/php_xmlwriter.h b/ext/xmlwriter/php_xmlwriter.h index 3e24ce3172093..e21a5e3510ba2 100644 --- a/ext/xmlwriter/php_xmlwriter.h +++ b/ext/xmlwriter/php_xmlwriter.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xsl/php_xsl.c b/ext/xsl/php_xsl.c index 2688f4c3fb42c..41e1b9fa236bb 100644 --- a/ext/xsl/php_xsl.c +++ b/ext/xsl/php_xsl.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xsl/php_xsl.h b/ext/xsl/php_xsl.h index b0548b562f53d..e1a792e84bf82 100644 --- a/ext/xsl/php_xsl.h +++ b/ext/xsl/php_xsl.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xsl/xsl_fe.h b/ext/xsl/xsl_fe.h index 889706ed66237..ba9d49beb7546 100644 --- a/ext/xsl/xsl_fe.h +++ b/ext/xsl/xsl_fe.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c index 5aa6aa943b2a8..1785519c15aeb 100644 --- a/ext/xsl/xsltprocessor.c +++ b/ext/xsl/xsltprocessor.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index 74f868b5c3320..727cc853ca1ae 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/zip/php_zip.h b/ext/zip/php_zip.h index f848ade8bc54e..7dd9ff09d0b51 100644 --- a/ext/zip/php_zip.h +++ b/ext/zip/php_zip.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/zlib/php_zlib.h b/ext/zlib/php_zlib.h index e895e0e48264b..6b1d0cd80c510 100644 --- a/ext/zlib/php_zlib.h +++ b/ext/zlib/php_zlib.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 7ff2b30c4c4e7..1a202e344ed43 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/zlib/zlib_filter.c b/ext/zlib/zlib_filter.c index b9c55d33099be..5f276ad7889d9 100644 --- a/ext/zlib/zlib_filter.c +++ b/ext/zlib/zlib_filter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/ext/zlib/zlib_fopen_wrapper.c b/ext/zlib/zlib_fopen_wrapper.c index 039e3d1aaa8be..1b00eb8713b90 100644 --- a/ext/zlib/zlib_fopen_wrapper.c +++ b/ext/zlib/zlib_fopen_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/header b/header index 1cfc74a17963b..bb5c17d0c5a72 100644 --- a/header +++ b/header @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/SAPI.c b/main/SAPI.c index e72eafb066ba9..dcb2da629a03b 100644 --- a/main/SAPI.c +++ b/main/SAPI.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/SAPI.h b/main/SAPI.h index 8f2536b84f4d7..92b7329dbc16c 100644 --- a/main/SAPI.h +++ b/main/SAPI.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c index 9d4a8a85c2075..6f11cf3f3254b 100644 --- a/main/fopen_wrappers.c +++ b/main/fopen_wrappers.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/fopen_wrappers.h b/main/fopen_wrappers.h index 1d6394cb09e0b..ee96eef313a8c 100644 --- a/main/fopen_wrappers.h +++ b/main/fopen_wrappers.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/getopt.c b/main/getopt.c index 7761e6ac62ee5..591c8c7778447 100644 --- a/main/getopt.c +++ b/main/getopt.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/internal_functions_nw.c b/main/internal_functions_nw.c index d4de5e436dada..07aec9a08ef66 100644 --- a/main/internal_functions_nw.c +++ b/main/internal_functions_nw.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/internal_functions_win32.c b/main/internal_functions_win32.c index e78922ac1f9cb..06cd5b2a50ee1 100644 --- a/main/internal_functions_win32.c +++ b/main/internal_functions_win32.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/main.c b/main/main.c index ccb98a6474945..2fbdfce0b2c4b 100644 --- a/main/main.c +++ b/main/main.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/network.c b/main/network.c index b8380b00d9003..4972b8045e5c2 100644 --- a/main/network.c +++ b/main/network.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/output.c b/main/output.c index 63f315e23c30a..9324f059da8be 100644 --- a/main/output.c +++ b/main/output.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php.h b/main/php.h index 1c1ffa3a612c8..7c1f8fd0c7b96 100644 --- a/main/php.h +++ b/main/php.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_compat.h b/main/php_compat.h index 80f43d4ee26ad..936dd5231f52b 100644 --- a/main/php_compat.h +++ b/main/php_compat.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_content_types.c b/main/php_content_types.c index cca006ad6ae2d..c4433978ed2be 100644 --- a/main/php_content_types.c +++ b/main/php_content_types.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_content_types.h b/main/php_content_types.h index d2e79f3c27193..7ceffff5c0a29 100644 --- a/main/php_content_types.h +++ b/main/php_content_types.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_getopt.h b/main/php_getopt.h index 1f514d359ae47..a3f4c1420bb2c 100644 --- a/main/php_getopt.h +++ b/main/php_getopt.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_globals.h b/main/php_globals.h index 514c27869b30e..170431d079c63 100644 --- a/main/php_globals.h +++ b/main/php_globals.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_ini.c b/main/php_ini.c index 89a3d7e461e45..b15a3846dd3cf 100644 --- a/main/php_ini.c +++ b/main/php_ini.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_ini.h b/main/php_ini.h index 9645143e23cd0..65c80f75933b4 100644 --- a/main/php_ini.h +++ b/main/php_ini.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_main.h b/main/php_main.h index 124be2379ad0f..68ae83700e451 100644 --- a/main/php_main.h +++ b/main/php_main.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_memory_streams.h b/main/php_memory_streams.h index e23bea69fed0b..0f975cc72dffe 100644 --- a/main/php_memory_streams.h +++ b/main/php_memory_streams.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_network.h b/main/php_network.h index 6078890049a55..8ffb51ca40756 100644 --- a/main/php_network.h +++ b/main/php_network.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_open_temporary_file.c b/main/php_open_temporary_file.c index 8d5c9e9ee7bd8..b43d6a78351c7 100644 --- a/main/php_open_temporary_file.c +++ b/main/php_open_temporary_file.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_open_temporary_file.h b/main/php_open_temporary_file.h index 234adb6e9455d..e7dce359bb92b 100644 --- a/main/php_open_temporary_file.h +++ b/main/php_open_temporary_file.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_output.h b/main/php_output.h index d050a141a1881..833bddec389cf 100644 --- a/main/php_output.h +++ b/main/php_output.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_reentrancy.h b/main/php_reentrancy.h index e81d6d6178671..50f2e209cd87d 100644 --- a/main/php_reentrancy.h +++ b/main/php_reentrancy.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_scandir.c b/main/php_scandir.c index 5237afb8b36c6..9f3042e0f188b 100644 --- a/main/php_scandir.c +++ b/main/php_scandir.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_scandir.h b/main/php_scandir.h index eb63a2c11c5c8..ad68e8d518ccf 100644 --- a/main/php_scandir.h +++ b/main/php_scandir.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_sprintf.c b/main/php_sprintf.c index 265fcffe42f0e..9df43a557dc37 100644 --- a/main/php_sprintf.c +++ b/main/php_sprintf.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_streams.h b/main/php_streams.h index 291fd0d0ae32d..5acf942e434bb 100644 --- a/main/php_streams.h +++ b/main/php_streams.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_syslog.h b/main/php_syslog.h index 113b0af522f32..e070487825a61 100644 --- a/main/php_syslog.h +++ b/main/php_syslog.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_ticks.c b/main/php_ticks.c index c5d152ebbb18c..17ffb9c770fcb 100644 --- a/main/php_ticks.c +++ b/main/php_ticks.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_ticks.h b/main/php_ticks.h index 09bd1c53cc0b5..cc966fa520e7b 100644 --- a/main/php_ticks.h +++ b/main/php_ticks.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_variables.c b/main/php_variables.c index 9952bd80bc8d6..fd52f311d17df 100644 --- a/main/php_variables.c +++ b/main/php_variables.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/php_variables.h b/main/php_variables.h index 31b8ffb9f7ff6..8f5e96aac363a 100644 --- a/main/php_variables.h +++ b/main/php_variables.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/reentrancy.c b/main/reentrancy.c index 789678173a809..7f8522483548c 100644 --- a/main/reentrancy.c +++ b/main/reentrancy.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/rfc1867.c b/main/rfc1867.c index 3ca2c1131b72f..e3e6e1d1d531f 100644 --- a/main/rfc1867.c +++ b/main/rfc1867.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/rfc1867.h b/main/rfc1867.h index 618458be3405b..8a502c4b8919c 100644 --- a/main/rfc1867.h +++ b/main/rfc1867.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/snprintf.c b/main/snprintf.c index bda110d339240..4514bd6821fb8 100644 --- a/main/snprintf.c +++ b/main/snprintf.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/snprintf.h b/main/snprintf.h index 7086869339c8c..de03542cad225 100644 --- a/main/snprintf.h +++ b/main/snprintf.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/spprintf.c b/main/spprintf.c index ef51cc5f4177a..bb401ab136eeb 100644 --- a/main/spprintf.c +++ b/main/spprintf.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/spprintf.h b/main/spprintf.h index 9028b8d29e1ea..397928a794501 100644 --- a/main/spprintf.h +++ b/main/spprintf.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/cast.c b/main/streams/cast.c index da56e86679901..878b4b52e76f1 100644 --- a/main/streams/cast.c +++ b/main/streams/cast.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/filter.c b/main/streams/filter.c index ea38860f824bb..6de3a928fe3da 100644 --- a/main/streams/filter.c +++ b/main/streams/filter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/glob_wrapper.c b/main/streams/glob_wrapper.c index 7b568501ee735..9c051a59210ab 100644 --- a/main/streams/glob_wrapper.c +++ b/main/streams/glob_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/memory.c b/main/streams/memory.c index 9e0fae6d1e7cf..328d3be399018 100644 --- a/main/streams/memory.c +++ b/main/streams/memory.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/mmap.c b/main/streams/mmap.c index 1344d62f6bb2f..4f9388c6e7f26 100644 --- a/main/streams/mmap.c +++ b/main/streams/mmap.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_context.h b/main/streams/php_stream_context.h index 19acb08441288..59fa604306d14 100644 --- a/main/streams/php_stream_context.h +++ b/main/streams/php_stream_context.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_filter_api.h b/main/streams/php_stream_filter_api.h index 5895e71cdf3ed..abb590665461b 100644 --- a/main/streams/php_stream_filter_api.h +++ b/main/streams/php_stream_filter_api.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_glob_wrapper.h b/main/streams/php_stream_glob_wrapper.h index c584ff8f84780..330e917bda4ef 100644 --- a/main/streams/php_stream_glob_wrapper.h +++ b/main/streams/php_stream_glob_wrapper.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_mmap.h b/main/streams/php_stream_mmap.h index 243b776b1d975..7895ac69d45d4 100644 --- a/main/streams/php_stream_mmap.h +++ b/main/streams/php_stream_mmap.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_plain_wrapper.h b/main/streams/php_stream_plain_wrapper.h index a6a1ed8ad7ae1..4b3875577d5ae 100644 --- a/main/streams/php_stream_plain_wrapper.h +++ b/main/streams/php_stream_plain_wrapper.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_transport.h b/main/streams/php_stream_transport.h index 41585198bd4db..c2d911032ef8a 100644 --- a/main/streams/php_stream_transport.h +++ b/main/streams/php_stream_transport.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_stream_userspace.h b/main/streams/php_stream_userspace.h index 33d2a7c836c88..2830dd0d26ee8 100644 --- a/main/streams/php_stream_userspace.h +++ b/main/streams/php_stream_userspace.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/php_streams_int.h b/main/streams/php_streams_int.h index 1c1c00c4ca819..daae2b8893809 100644 --- a/main/streams/php_streams_int.h +++ b/main/streams/php_streams_int.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/plain_wrapper.c b/main/streams/plain_wrapper.c index 80c22ce506e24..39df31a170503 100644 --- a/main/streams/plain_wrapper.c +++ b/main/streams/plain_wrapper.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/streams.c b/main/streams/streams.c index 40b18e9f5b781..4163c5b392668 100644 --- a/main/streams/streams.c +++ b/main/streams/streams.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/transports.c b/main/streams/transports.c index 8de9b9b9ac015..c24bf97ce6e9e 100644 --- a/main/streams/transports.c +++ b/main/streams/transports.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/userspace.c b/main/streams/userspace.c index 74d9beb02551e..69edbaafa91d4 100644 --- a/main/streams/userspace.c +++ b/main/streams/userspace.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/streams/xp_socket.c b/main/streams/xp_socket.c index 7c3a553102404..beffc73e103dd 100644 --- a/main/streams/xp_socket.c +++ b/main/streams/xp_socket.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/strlcat.c b/main/strlcat.c index db8f26c4ad785..ca22839e86e36 100644 --- a/main/strlcat.c +++ b/main/strlcat.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/strlcpy.c b/main/strlcpy.c index 1e40df0463d66..371faafd8240c 100644 --- a/main/strlcpy.c +++ b/main/strlcpy.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/win32_internal_function_disabled.h b/main/win32_internal_function_disabled.h index 822c688715deb..3a78f6c598fa7 100644 --- a/main/win32_internal_function_disabled.h +++ b/main/win32_internal_function_disabled.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/main/win95nt.h b/main/win95nt.h index c98fd0f22ce57..2e944c2b0e631 100644 --- a/main/win95nt.h +++ b/main/win95nt.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/netware/start.c b/netware/start.c index b842749257a30..2765ffba12fb4 100644 --- a/netware/start.c +++ b/netware/start.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/aolserver/aolserver.c b/sapi/aolserver/aolserver.c index c59a7164f9e86..3dcbc8d21182e 100644 --- a/sapi/aolserver/aolserver.c +++ b/sapi/aolserver/aolserver.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache/libpre.c b/sapi/apache/libpre.c index f1c184a964af3..35b47cf5df62d 100644 --- a/sapi/apache/libpre.c +++ b/sapi/apache/libpre.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache/mod_php5.c b/sapi/apache/mod_php5.c index 236dd6636b9b0..11be0ed222491 100644 --- a/sapi/apache/mod_php5.c +++ b/sapi/apache/mod_php5.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache/mod_php5.h b/sapi/apache/mod_php5.h index 81ff651749708..bdbdd478dd8c7 100644 --- a/sapi/apache/mod_php5.h +++ b/sapi/apache/mod_php5.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache/php_apache.c b/sapi/apache/php_apache.c index a830de69c8759..3745197439045 100644 --- a/sapi/apache/php_apache.c +++ b/sapi/apache/php_apache.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache/php_apache_http.h b/sapi/apache/php_apache_http.h index d572272eaaa12..12788d304db83 100644 --- a/sapi/apache/php_apache_http.h +++ b/sapi/apache/php_apache_http.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache/sapi_apache.c b/sapi/apache/sapi_apache.c index da76ab632960c..88c99855c6706 100644 --- a/sapi/apache/sapi_apache.c +++ b/sapi/apache/sapi_apache.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2filter/apache_config.c b/sapi/apache2filter/apache_config.c index f30900a5e1561..333c7b8cf2290 100644 --- a/sapi/apache2filter/apache_config.c +++ b/sapi/apache2filter/apache_config.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2filter/php_apache.h b/sapi/apache2filter/php_apache.h index 8ff61ac07d5da..4ee3c0aa9046f 100644 --- a/sapi/apache2filter/php_apache.h +++ b/sapi/apache2filter/php_apache.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2filter/php_functions.c b/sapi/apache2filter/php_functions.c index 29ae2fceb9c1f..e96ceda3f116e 100644 --- a/sapi/apache2filter/php_functions.c +++ b/sapi/apache2filter/php_functions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2filter/sapi_apache2.c b/sapi/apache2filter/sapi_apache2.c index 0b51cfbe62f39..8ce490ea43da5 100644 --- a/sapi/apache2filter/sapi_apache2.c +++ b/sapi/apache2filter/sapi_apache2.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2handler/apache_config.c b/sapi/apache2handler/apache_config.c index 64ac93aa0c6e9..2b519393d7793 100644 --- a/sapi/apache2handler/apache_config.c +++ b/sapi/apache2handler/apache_config.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2handler/mod_php5.c b/sapi/apache2handler/mod_php5.c index 9df4f25066df2..56ef1bca4486a 100644 --- a/sapi/apache2handler/mod_php5.c +++ b/sapi/apache2handler/mod_php5.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2handler/php_apache.h b/sapi/apache2handler/php_apache.h index c43e722a56cce..8bc46089d7ae6 100644 --- a/sapi/apache2handler/php_apache.h +++ b/sapi/apache2handler/php_apache.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2handler/php_functions.c b/sapi/apache2handler/php_functions.c index 3c1f9a17fa7c4..1f79a538f4af1 100644 --- a/sapi/apache2handler/php_functions.c +++ b/sapi/apache2handler/php_functions.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache2handler/sapi_apache2.c b/sapi/apache2handler/sapi_apache2.c index 900a3a425b2de..bcb24431128fe 100644 --- a/sapi/apache2handler/sapi_apache2.c +++ b/sapi/apache2handler/sapi_apache2.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache_hooks/mod_php5.c b/sapi/apache_hooks/mod_php5.c index 67b5a3aa664f6..dda6e4989128b 100644 --- a/sapi/apache_hooks/mod_php5.c +++ b/sapi/apache_hooks/mod_php5.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache_hooks/mod_php5.h b/sapi/apache_hooks/mod_php5.h index b37102e068eed..86a5863ab96cf 100644 --- a/sapi/apache_hooks/mod_php5.h +++ b/sapi/apache_hooks/mod_php5.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache_hooks/php_apache.c b/sapi/apache_hooks/php_apache.c index 830902310a61a..dde6d88773799 100644 --- a/sapi/apache_hooks/php_apache.c +++ b/sapi/apache_hooks/php_apache.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/apache_hooks/sapi_apache.c b/sapi/apache_hooks/sapi_apache.c index e45f579a6e490..a9c9d674e0171 100644 --- a/sapi/apache_hooks/sapi_apache.c +++ b/sapi/apache_hooks/sapi_apache.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/caudium/caudium.c b/sapi/caudium/caudium.c index f4824f53f6ae6..d3b834fe93ff2 100644 --- a/sapi/caudium/caudium.c +++ b/sapi/caudium/caudium.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c index ceba7174cd94e..fbb9f512d0063 100644 --- a/sapi/cgi/cgi_main.c +++ b/sapi/cgi/cgi_main.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -2215,9 +2215,9 @@ consult the installation file that came with this distribution, or visit \n\ SG(request_info).no_headers = 1; } #if ZEND_DEBUG - php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); #else - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); #endif php_request_shutdown((void *) 0); fcgi_shutdown(); diff --git a/sapi/cgi/fastcgi.c b/sapi/cgi/fastcgi.c index c9c8da9ab851d..72977b63300bb 100644 --- a/sapi/cgi/fastcgi.c +++ b/sapi/cgi/fastcgi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/cgi/fastcgi.h b/sapi/cgi/fastcgi.h index 18a63c7c1fd12..f1f464dc0545e 100644 --- a/sapi/cgi/fastcgi.h +++ b/sapi/cgi/fastcgi.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/cli/cli.h b/sapi/cli/cli.h index 3e9ca430849ab..7686522a20ad6 100644 --- a/sapi/cli/cli.h +++ b/sapi/cli/cli.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index f9bf3ee60bd8e..c01f3705b59bc 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -687,7 +687,7 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /* {{{ */ goto out; case 'v': /* show php version & quit */ - php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2012 The PHP Group\n%s", + php_printf("PHP %s (%s) (built: %s %s) %s\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, cli_sapi_module.name, __DATE__, __TIME__, #if ZEND_DEBUG && defined(HAVE_GCOV) "(DEBUG GCOV)", diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 9fc2817c277ae..74d2ad2c3bd40 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/cli/php_cli_server.h b/sapi/cli/php_cli_server.h index 889ebf6f743a3..ed716f99f809e 100644 --- a/sapi/cli/php_cli_server.h +++ b/sapi/cli/php_cli_server.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/continuity/capi.c b/sapi/continuity/capi.c index 96c39230afa6e..26762a5a963c1 100644 --- a/sapi/continuity/capi.c +++ b/sapi/continuity/capi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/embed/php_embed.c b/sapi/embed/php_embed.c index 52a5668835078..414b4dbb022a5 100644 --- a/sapi/embed/php_embed.c +++ b/sapi/embed/php_embed.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/embed/php_embed.h b/sapi/embed/php_embed.h index d8e8ce421f749..ad5f4bc47689d 100644 --- a/sapi/embed/php_embed.h +++ b/sapi/embed/php_embed.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/devpoll.c b/sapi/fpm/fpm/events/devpoll.c index eec7e5e139f33..223d0729c86cd 100644 --- a/sapi/fpm/fpm/events/devpoll.c +++ b/sapi/fpm/fpm/events/devpoll.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/devpoll.h b/sapi/fpm/fpm/events/devpoll.h index 95291b15814b4..f9bc4af194987 100644 --- a/sapi/fpm/fpm/events/devpoll.h +++ b/sapi/fpm/fpm/events/devpoll.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/epoll.c b/sapi/fpm/fpm/events/epoll.c index 2914aa0100bce..c9c7f1fd6d1d6 100644 --- a/sapi/fpm/fpm/events/epoll.c +++ b/sapi/fpm/fpm/events/epoll.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/epoll.h b/sapi/fpm/fpm/events/epoll.h index 63de752fc35f1..abc5a21b1004f 100644 --- a/sapi/fpm/fpm/events/epoll.h +++ b/sapi/fpm/fpm/events/epoll.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/kqueue.c b/sapi/fpm/fpm/events/kqueue.c index eb90c5fcf09eb..7ce0760691580 100644 --- a/sapi/fpm/fpm/events/kqueue.c +++ b/sapi/fpm/fpm/events/kqueue.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/kqueue.h b/sapi/fpm/fpm/events/kqueue.h index aeddce074e128..2642acaae5cce 100644 --- a/sapi/fpm/fpm/events/kqueue.h +++ b/sapi/fpm/fpm/events/kqueue.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/poll.c b/sapi/fpm/fpm/events/poll.c index 41ab4ca63fb69..185eceb1a9d68 100644 --- a/sapi/fpm/fpm/events/poll.c +++ b/sapi/fpm/fpm/events/poll.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/poll.h b/sapi/fpm/fpm/events/poll.h index 601a03b3aefc4..d55319214c82e 100644 --- a/sapi/fpm/fpm/events/poll.h +++ b/sapi/fpm/fpm/events/poll.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/port.c b/sapi/fpm/fpm/events/port.c index 6564ff2458ff6..3cbf092cbcd68 100644 --- a/sapi/fpm/fpm/events/port.c +++ b/sapi/fpm/fpm/events/port.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/port.h b/sapi/fpm/fpm/events/port.h index a48b3f6246c99..666a157d23bb0 100644 --- a/sapi/fpm/fpm/events/port.h +++ b/sapi/fpm/fpm/events/port.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/select.c b/sapi/fpm/fpm/events/select.c index 03a715840e672..e3af067d86926 100644 --- a/sapi/fpm/fpm/events/select.c +++ b/sapi/fpm/fpm/events/select.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/events/select.h b/sapi/fpm/fpm/events/select.h index 6fda70fbdb4bd..db52503fc1ff1 100644 --- a/sapi/fpm/fpm/events/select.h +++ b/sapi/fpm/fpm/events/select.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/fastcgi.c b/sapi/fpm/fpm/fastcgi.c index f77c9fb4d6466..cf3f098c53676 100644 --- a/sapi/fpm/fpm/fastcgi.c +++ b/sapi/fpm/fpm/fastcgi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/fastcgi.h b/sapi/fpm/fpm/fastcgi.h index f39559d256084..ee786752e8968 100644 --- a/sapi/fpm/fpm/fastcgi.h +++ b/sapi/fpm/fpm/fastcgi.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index edd75be5aec3f..40810f00bb0e6 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -1708,9 +1708,9 @@ int main(int argc, char *argv[]) SG(request_info).no_headers = 1; #if ZEND_DEBUG - php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); #else - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); #endif php_request_shutdown((void *) 0); fcgi_shutdown(); diff --git a/sapi/isapi/php5isapi.c b/sapi/isapi/php5isapi.c index d663928c25875..002ad2ae3ed53 100644 --- a/sapi/isapi/php5isapi.c +++ b/sapi/isapi/php5isapi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/litespeed/lsapi_main.c b/sapi/litespeed/lsapi_main.c index 338b8e9d1e534..19364c66e06f2 100644 --- a/sapi/litespeed/lsapi_main.c +++ b/sapi/litespeed/lsapi_main.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -547,9 +547,9 @@ static int cli_main( int argc, char * argv[] ) case 'v': if (php_request_startup(TSRMLS_C) != FAILURE) { #if ZEND_DEBUG - php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s) (DEBUG)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); #else - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); #endif #ifdef PHP_OUTPUT_NEWAPI php_output_end_all(TSRMLS_C); diff --git a/sapi/litespeed/lsapidef.h b/sapi/litespeed/lsapidef.h index 68f73c4e25ee0..c8940a930e947 100644 --- a/sapi/litespeed/lsapidef.h +++ b/sapi/litespeed/lsapidef.h @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/litespeed/lsapilib.c b/sapi/litespeed/lsapilib.c index 4beea56b39280..3a13000e11f28 100644 --- a/sapi/litespeed/lsapilib.c +++ b/sapi/litespeed/lsapilib.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/litespeed/lsapilib.h b/sapi/litespeed/lsapilib.h index 9772ea199d125..538a170b44cd8 100644 --- a/sapi/litespeed/lsapilib.h +++ b/sapi/litespeed/lsapilib.h @@ -3,7 +3,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/milter/php_milter.c b/sapi/milter/php_milter.c index 43e1f2345abd8..6856c07bb64b8 100644 --- a/sapi/milter/php_milter.c +++ b/sapi/milter/php_milter.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | @@ -1109,7 +1109,7 @@ int main(int argc, char *argv[]) } SG(headers_sent) = 1; SG(request_info).no_headers = 1; - php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2012 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); + php_printf("PHP %s (%s) (built: %s %s)\nCopyright (c) 1997-2013 The PHP Group\n%s", PHP_VERSION, sapi_module.name, __DATE__, __TIME__, get_zend_version()); php_output_teardown(); exit(1); break; diff --git a/sapi/nsapi/nsapi.c b/sapi/nsapi/nsapi.c index 1579ef78c86f0..1e6a680c91a69 100644 --- a/sapi/nsapi/nsapi.c +++ b/sapi/nsapi/nsapi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/phttpd/php_phttpd.h b/sapi/phttpd/php_phttpd.h index 71cff9e373d9c..49089cffbf3f1 100644 --- a/sapi/phttpd/php_phttpd.h +++ b/sapi/phttpd/php_phttpd.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/phttpd/phttpd.c b/sapi/phttpd/phttpd.c index 5930a1942f5d5..c2e917202f7ab 100644 --- a/sapi/phttpd/phttpd.c +++ b/sapi/phttpd/phttpd.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/pi3web/pi3web_sapi.c b/sapi/pi3web/pi3web_sapi.c index 1621ce70656d6..64eb2a6c99526 100644 --- a/sapi/pi3web/pi3web_sapi.c +++ b/sapi/pi3web/pi3web_sapi.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/roxen/roxen.c b/sapi/roxen/roxen.c index 4d7fc6d7e5a60..c897ef62be6f6 100644 --- a/sapi/roxen/roxen.c +++ b/sapi/roxen/roxen.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/thttpd/php_thttpd.h b/sapi/thttpd/php_thttpd.h index 39a699c3cc67f..40d63d27b1661 100644 --- a/sapi/thttpd/php_thttpd.h +++ b/sapi/thttpd/php_thttpd.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/thttpd/thttpd.c b/sapi/thttpd/thttpd.c index 007cdc5a667e0..1a1baa7078e42 100644 --- a/sapi/thttpd/thttpd.c +++ b/sapi/thttpd/thttpd.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/tux/php_tux.c b/sapi/tux/php_tux.c index cf11856f50145..968dd9eb91b2c 100644 --- a/sapi/tux/php_tux.c +++ b/sapi/tux/php_tux.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/webjames/php_webjames.h b/sapi/webjames/php_webjames.h index 163e753a25232..f9903d1647106 100644 --- a/sapi/webjames/php_webjames.h +++ b/sapi/webjames/php_webjames.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/sapi/webjames/webjames.c b/sapi/webjames/webjames.c index b7a7a218241ee..9237ac7dd30fb 100644 --- a/sapi/webjames/webjames.c +++ b/sapi/webjames/webjames.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/build/deplister.c b/win32/build/deplister.c index f99da51228292..8da65ba302638 100644 --- a/win32/build/deplister.c +++ b/win32/build/deplister.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/build/template.rc b/win32/build/template.rc index 606b08a244b95..13e92e9a3bdfe 100644 --- a/win32/build/template.rc +++ b/win32/build/template.rc @@ -65,7 +65,7 @@ BEGIN #endif VALUE "FileVersion", EXT_VERSION VALUE "InternalName", INTERNAL_NAME - VALUE "LegalCopyright", "Copyright © 1997-2012 The PHP Group" + VALUE "LegalCopyright", "Copyright © 1997-2013 The PHP Group" VALUE "LegalTrademarks", "PHP" VALUE "OriginalFilename", FILE_NAME VALUE "ProductName", "PHP" diff --git a/win32/globals.c b/win32/globals.c index b92fad9f2d701..1bbb3b4481df0 100644 --- a/win32/globals.c +++ b/win32/globals.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/grp.h b/win32/grp.h index d99449488d551..a3fb97b205734 100644 --- a/win32/grp.h +++ b/win32/grp.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/php_win32_globals.h b/win32/php_win32_globals.h index 1fcfb6036529c..1686e5df63e6b 100644 --- a/win32/php_win32_globals.h +++ b/win32/php_win32_globals.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/select.c b/win32/select.c index 544009610bfbc..d77ef3de00e10 100644 --- a/win32/select.c +++ b/win32/select.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/select.h b/win32/select.h index d156fa7e7a96c..7cff1f303e820 100644 --- a/win32/select.h +++ b/win32/select.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/sockets.c b/win32/sockets.c index 2698c95a52cd0..d64280870f361 100644 --- a/win32/sockets.c +++ b/win32/sockets.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/sockets.h b/win32/sockets.h index 2e9b070b4cffe..f0b9f27484685 100644 --- a/win32/sockets.h +++ b/win32/sockets.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/syslog.h b/win32/syslog.h index b2d32cb5aaa46..e24737fe2fc20 100644 --- a/win32/syslog.h +++ b/win32/syslog.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/winutil.c b/win32/winutil.c index d9609f7987e3b..4afc28feca7db 100644 --- a/win32/winutil.c +++ b/win32/winutil.c @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | diff --git a/win32/winutil.h b/win32/winutil.h index 6cb90f7bf2daf..8cf07ec286ffd 100644 --- a/win32/winutil.h +++ b/win32/winutil.h @@ -2,7 +2,7 @@ +----------------------------------------------------------------------+ | PHP Version 5 | +----------------------------------------------------------------------+ - | Copyright (c) 1997-2012 The PHP Group | + | Copyright (c) 1997-2013 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | From 343a9199bbbf4f63b02099ceef27ef9881d8aa9f Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Tue, 1 Jan 2013 21:12:02 -0500 Subject: [PATCH 2239/2394] Remove passwd handler from struct when not needed CURLOPT_PASSWDFUNCTION was removed in cURL 7.15.5, the passwd field will not be used for version greater than this one --- ext/curl/interface.c | 2 ++ ext/curl/php_curl.h | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 125094c53a756..e0c95efed52ad 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -3267,9 +3267,11 @@ static void _php_curl_close_ex(php_curl *ch TSRMLS_DC) if (ch->handlers->write_header->func_name) { zval_ptr_dtor(&ch->handlers->write_header->func_name); } +#if CURLOPT_PASSWDFUNCTION != 0 if (ch->handlers->passwd) { zval_ptr_dtor(&ch->handlers->passwd); } +#endif if (ch->handlers->std_err) { zval_ptr_dtor(&ch->handlers->std_err); } diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index 3ae70602887f1..5c24fc1302710 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -135,7 +135,9 @@ typedef struct { php_curl_write *write; php_curl_write *write_header; php_curl_read *read; +#if CURLOPT_PASSWDFUNCTION != 0 zval *passwd; +#endif zval *std_err; php_curl_progress *progress; #if LIBCURL_VERSION_NUM >= 0x071500 /* Available since 7.21.0 */ From b3a86098378eb0e97669537658329cbfa2a3c3ad Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 2 Jan 2013 16:48:46 +0100 Subject: [PATCH 2240/2394] remove set but not used variables --- ext/zlib/zlib_filter.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/ext/zlib/zlib_filter.c b/ext/zlib/zlib_filter.c index 5f276ad7889d9..8ccd9e161c5bc 100644 --- a/ext/zlib/zlib_filter.c +++ b/ext/zlib/zlib_filter.c @@ -62,10 +62,9 @@ static php_stream_filter_status_t php_zlib_inflate_filter( { php_zlib_filter_data *data; php_stream_bucket *bucket; - size_t consumed = 0, original_out, original_in; + size_t consumed = 0; int status; php_stream_filter_status_t exit_status = PSFS_FEED_ME; - z_stream *streamp; if (!thisfilter || !thisfilter->abstract) { /* Should never happen */ @@ -73,9 +72,6 @@ static php_stream_filter_status_t php_zlib_inflate_filter( } data = (php_zlib_filter_data *)(thisfilter->abstract); - streamp = &(data->strm); - original_in = data->strm.total_in; - original_out = data->strm.total_out; while (buckets_in->head) { size_t bin = 0, desired; @@ -191,10 +187,9 @@ static php_stream_filter_status_t php_zlib_deflate_filter( { php_zlib_filter_data *data; php_stream_bucket *bucket; - size_t consumed = 0, original_out, original_in; + size_t consumed = 0; int status; php_stream_filter_status_t exit_status = PSFS_FEED_ME; - z_stream *streamp; if (!thisfilter || !thisfilter->abstract) { /* Should never happen */ @@ -202,9 +197,6 @@ static php_stream_filter_status_t php_zlib_deflate_filter( } data = (php_zlib_filter_data *)(thisfilter->abstract); - streamp = &(data->strm); - original_in = data->strm.total_in; - original_out = data->strm.total_out; while (buckets_in->head) { size_t bin = 0, desired; From f85e5950ab4552799c119cd1d23617535ed19e61 Mon Sep 17 00:00:00 2001 From: Pierrick Charron Date: Sat, 5 Jan 2013 11:07:59 -0500 Subject: [PATCH 2241/2394] Improve resource management for curl handle Previous implementation was using its own refcounting (uses field of the php_curl struct). zend_list_add/remove already implements its own refcount, so we don't need to use an other one. --- ext/curl/interface.c | 11 ++--------- ext/curl/multi.c | 13 ++++--------- ext/curl/php_curl.h | 1 - 3 files changed, 6 insertions(+), 19 deletions(-) diff --git a/ext/curl/interface.c b/ext/curl/interface.c index e0c95efed52ad..2e055811e371a 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -1952,8 +1952,6 @@ PHP_FUNCTION(curl_init) ch->handlers->read->method = PHP_CURL_DIRECT; ch->handlers->write_header->method = PHP_CURL_IGNORE; - ch->uses = 0; - MAKE_STD_ZVAL(clone); ch->clone = clone; @@ -1995,8 +1993,7 @@ PHP_FUNCTION(curl_copy_handle) TSRMLS_SET_CTX(dupch->thread_ctx); dupch->cp = cp; - dupch->uses = 0; - ch->uses++; + zend_list_addref(Z_LVAL_P(zid)); if (ch->handlers->write->stream) { Z_ADDREF_P(ch->handlers->write->stream); } @@ -3210,11 +3207,7 @@ PHP_FUNCTION(curl_close) return; } - if (ch->uses) { - ch->uses--; - } else { - zend_list_delete(Z_LVAL_P(zid)); - } + zend_list_delete(Z_LVAL_P(zid)); } /* }}} */ diff --git a/ext/curl/multi.c b/ext/curl/multi.c index d84669a772474..af78651ba16ef 100644 --- a/ext/curl/multi.c +++ b/ext/curl/multi.c @@ -86,7 +86,6 @@ PHP_FUNCTION(curl_multi_add_handle) ZEND_FETCH_RESOURCE(ch, php_curl *, &z_ch, -1, le_curl_name, le_curl); _php_curl_cleanup_handle(ch); - ch->uses++; /* we want to create a copy of this zval that we store in the multihandle structure element "easyh" */ tmp_val = *z_ch; @@ -113,11 +112,7 @@ void _php_curl_multi_cleanup_list(void *data) /* {{{ */ return; } - if (ch->uses) { - ch->uses--; - } else { - zend_list_delete(Z_LVAL_P(z_ch)); - } + zend_list_delete(Z_LVAL_P(z_ch)); } /* }}} */ @@ -146,12 +141,12 @@ PHP_FUNCTION(curl_multi_remove_handle) ZEND_FETCH_RESOURCE(mh, php_curlm *, &z_mh, -1, le_curl_multi_handle_name, le_curl_multi_handle); ZEND_FETCH_RESOURCE(ch, php_curl *, &z_ch, -1, le_curl_name, le_curl); - --ch->uses; + + RETVAL_LONG((long) curl_multi_remove_handle(mh->multi, ch->cp)); zend_llist_del_element( &mh->easyh, &z_ch, (int (*)(void *, void *)) curl_compare_resources ); - - RETURN_LONG((long) curl_multi_remove_handle(mh->multi, ch->cp)); + } /* }}} */ diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index 5c24fc1302710..a8c26c05288a3 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -169,7 +169,6 @@ typedef struct { CURL *cp; php_curl_handlers *handlers; long id; - unsigned int uses; zend_bool in_callback; zval *clone; } php_curl; From f3824ad16644c53645e7428d2e838278f5a0e1c4 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 6 Jan 2013 02:10:16 +0100 Subject: [PATCH 2242/2394] Bug #63699 performance improvements for ext/date by only validating timezone when timezone is set --- ext/date/php_date.c | 52 +++++++++++++++++++++++++++++++++------------ ext/date/php_date.h | 7 +++--- 2 files changed, 43 insertions(+), 16 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index c5647103f9eba..b4819ab41e37f 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -495,9 +495,11 @@ int php_date_global_timezone_db_enabled; /* on 90'35; common sunrise declaration (sun body disappeared) */ #define DATE_SUNRISE_ZENITH "90.583333" +static PHP_INI_MH(OnUpdate_date_timezone); + /* {{{ INI Settings */ PHP_INI_BEGIN() - STD_PHP_INI_ENTRY("date.timezone", "", PHP_INI_ALL, OnUpdateString, default_timezone, zend_date_globals, date_globals) + STD_PHP_INI_ENTRY("date.timezone", "", PHP_INI_ALL, OnUpdate_date_timezone, default_timezone, zend_date_globals, date_globals) PHP_INI_ENTRY("date.default_latitude", DATE_DEFAULT_LATITUDE, PHP_INI_ALL, NULL) PHP_INI_ENTRY("date.default_longitude", DATE_DEFAULT_LONGITUDE, PHP_INI_ALL, NULL) PHP_INI_ENTRY("date.sunset_zenith", DATE_SUNSET_ZENITH, PHP_INI_ALL, NULL) @@ -599,6 +601,7 @@ static PHP_GINIT_FUNCTION(date) date_globals->default_timezone = NULL; date_globals->timezone = NULL; date_globals->tzcache = NULL; + date_globals->timezone_valid = 0; } /* }}} */ @@ -843,35 +846,57 @@ timelib_tzinfo *php_date_parse_tzfile_wrapper(char *formal_tzname, const timelib } /* }}} */ +// created this callback method to check the date.timezone only when changed, to increase performance and error on an ini_set line +/* {{{ static PHP_INI_MH(OnUpdate_date_timezone) */ +static PHP_INI_MH(OnUpdate_date_timezone) +{ + if (OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC) == FAILURE) { + return FAILURE; + } + + DATEG(timezone_valid) = 0; + if (stage == PHP_INI_STAGE_RUNTIME) { + if (!timelib_timezone_id_is_valid(DATEG(default_timezone), DATE_TIMEZONEDB)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, DATE_TZ_ERRMSG); + } else { + DATEG(timezone_valid) = 1; + } + } + + return SUCCESS; +} +/* }}} */ + /* {{{ Helper functions */ static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC) { /* Checking configure timezone */ - if (DATEG(timezone) && (strlen(DATEG(timezone)) > 0)) { + if (DATEG(timezone) && strlen(DATEG(timezone)) > 0) { return DATEG(timezone); } /* Check config setting for default timezone */ if (!DATEG(default_timezone)) { /* Special case: ext/date wasn't initialized yet */ zval ztz; - - if (SUCCESS == zend_get_configuration_directive("date.timezone", sizeof("date.timezone"), &ztz) && - Z_TYPE(ztz) == IS_STRING && - Z_STRLEN(ztz) > 0 && - timelib_timezone_id_is_valid(Z_STRVAL(ztz), tzdb)) { + + if (SUCCESS == zend_get_configuration_directive("date.timezone", sizeof("date.timezone"), &ztz) && Z_TYPE(ztz) == IS_STRING && Z_STRLEN(ztz) > 0 && timelib_timezone_id_is_valid(Z_STRVAL(ztz), tzdb)) { return Z_STRVAL(ztz); } } else if (*DATEG(default_timezone)) { - if (timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) { + if (DATEG(timezone_valid) == 1) { // timezone already checked and validated return DATEG(default_timezone); } - /* Invalid date.timezone value */ - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid date.timezone value '%s', we selected the timezone 'UTC' for now.", DATEG(default_timezone)); - } else { - /* No date.timezone value */ - php_error_docref(NULL TSRMLS_CC, E_WARNING, DATE_TZ_ERRMSG "We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone."); + + if (!timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid date.timezone value '%s', we selected the timezone 'UTC' for now.", DATEG(default_timezone)); + return "UTC"; + } + + DATEG(timezone_valid) = 1; + return DATEG(default_timezone); } /* Fallback to UTC */ + php_error_docref(NULL TSRMLS_CC, E_WARNING, DATE_TZ_ERRMSG "We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone."); return "UTC"; } @@ -889,6 +914,7 @@ PHPAPI timelib_tzinfo *get_timezone_info(TSRMLS_D) } /* }}} */ + /* {{{ date() and gmdate() data */ #include "ext/standard/php_smart_str.h" diff --git a/ext/date/php_date.h b/ext/date/php_date.h index c9c165050a72b..f0b662b5d9f35 100644 --- a/ext/date/php_date.h +++ b/ext/date/php_date.h @@ -150,10 +150,11 @@ struct _php_period_obj { }; ZEND_BEGIN_MODULE_GLOBALS(date) - char *default_timezone; - char *timezone; - HashTable *tzcache; + char *default_timezone; + char *timezone; + HashTable *tzcache; timelib_error_container *last_errors; + int timezone_valid; ZEND_END_MODULE_GLOBALS(date) #ifdef ZTS From ec2fff80e768dfb04aa393c06a2b1a42a9e871ff Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 6 Jan 2013 03:22:44 +0100 Subject: [PATCH 2243/2394] Bug #23955: allow specifiy max age for setcookie() --- NEWS | 1 + ext/session/session.c | 4 ++ ext/standard/head.c | 19 +++--- ext/standard/tests/network/setcookie.phpt | 70 +++++++++++++++++++++++ 4 files changed, 87 insertions(+), 7 deletions(-) create mode 100644 ext/standard/tests/network/setcookie.phpt diff --git a/NEWS b/NEWS index 2d0b4c3d027a3..1ad954a09843f 100644 --- a/NEWS +++ b/NEWS @@ -7,6 +7,7 @@ PHP NEWS . Fixed bug #63822 (Crash when using closures with ArrayAccess). (Nikita Popov) . Add Generator::throw() method. (Nikita Popov) + . Bug #23955: allow specifying Max-Age attribute in setcookie() (narfbg, Lars) - cURL: . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror diff --git a/ext/session/session.c b/ext/session/session.c index a3be9a78c2004..54bc6436adecb 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -1154,6 +1154,7 @@ static int php_session_cache_limiter(TSRMLS_D) /* {{{ */ #define COOKIE_SET_COOKIE "Set-Cookie: " #define COOKIE_EXPIRES "; expires=" +#define COOKIE_MAX_AGE "; Max-Age=" #define COOKIE_PATH "; path=" #define COOKIE_DOMAIN "; domain=" #define COOKIE_SECURE "; secure" @@ -1201,6 +1202,9 @@ static void php_session_send_cookie(TSRMLS_D) /* {{{ */ smart_str_appends(&ncookie, COOKIE_EXPIRES); smart_str_appends(&ncookie, date_fmt); efree(date_fmt); + + smart_str_appends(&ncookie, COOKIE_MAX_AGE); + smart_str_append_long(&ncookie, PS(cookie_lifetime)); } } diff --git a/ext/standard/head.c b/ext/standard/head.c index 97f61f2bef128..fa578175b1932 100644 --- a/ext/standard/head.c +++ b/ext/standard/head.c @@ -40,11 +40,11 @@ PHP_FUNCTION(header) { zend_bool rep = 1; sapi_header_line ctr = {0}; - + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|bl", &ctr.line, &ctr.line_len, &rep, &ctr.response_code) == FAILURE) return; - + sapi_header_op(rep ? SAPI_HEADER_REPLACE:SAPI_HEADER_ADD, &ctr TSRMLS_CC); } /* }}} */ @@ -80,7 +80,7 @@ PHPAPI int php_setcookie(char *name, int name_len, char *value, int value_len, t char *dt; sapi_header_line ctr = {0}; int result; - + if (name && strpbrk(name, "=,; \t\r\n\013\014") != NULL) { /* man isspace for \013 and \014 */ zend_error( E_WARNING, "Cookie names cannot contain any of the following '=,; \\t\\r\\n\\013\\014'" ); return FAILURE; @@ -111,18 +111,19 @@ PHPAPI int php_setcookie(char *name, int name_len, char *value, int value_len, t cookie = emalloc(len + 100); if (value && value_len == 0) { - /* + /* * MSIE doesn't delete a cookie when you set it to a null value * so in order to force cookies to be deleted, even on MSIE, we * pick an expiry date in the past */ dt = php_format_date("D, d-M-Y H:i:s T", sizeof("D, d-M-Y H:i:s T")-1, 1, 0 TSRMLS_CC); - snprintf(cookie, len + 100, "Set-Cookie: %s=deleted; expires=%s", name, dt); + snprintf(cookie, len + 100, "Set-Cookie: %s=deleted; expires=%s; Max-Age=0", name, dt); efree(dt); } else { snprintf(cookie, len + 100, "Set-Cookie: %s=%s", name, value ? encoded_value : ""); if (expires > 0) { const char *p; + char tsdelta[13]; strlcat(cookie, "; expires=", len + 100); dt = php_format_date("D, d-M-Y H:i:s T", sizeof("D, d-M-Y H:i:s T")-1, expires, 0 TSRMLS_CC); /* check to make sure that the year does not exceed 4 digits in length */ @@ -136,6 +137,10 @@ PHPAPI int php_setcookie(char *name, int name_len, char *value, int value_len, t } strlcat(cookie, dt, len + 100); efree(dt); + + snprintf(tsdelta, sizeof(tsdelta), "%li", (long) difftime(expires, time(NULL))); + strlcat(cookie, "; Max-Age=", len + 100); + strlcat(cookie, tsdelta, len + 100); } } @@ -237,11 +242,11 @@ PHP_FUNCTION(headers_sent) ZVAL_LONG(arg2, line); case 1: zval_dtor(arg1); - if (file) { + if (file) { ZVAL_STRING(arg1, file, 1); } else { ZVAL_STRING(arg1, "", 1); - } + } break; } diff --git a/ext/standard/tests/network/setcookie.phpt b/ext/standard/tests/network/setcookie.phpt new file mode 100644 index 0000000000000..bf04ec78de13c --- /dev/null +++ b/ext/standard/tests/network/setcookie.phpt @@ -0,0 +1,70 @@ +--TEST-- +setcookie() tests +--DESCRIPTION-- +--INI-- +date.timezone=UTC +--FILE-- + count($headers)) +{ + echo "Less headers are being sent than expected - aborting"; + return; +} + +do +{ + if (strncmp(current($headers), 'Set-Cookie:', 11) !== 0) + { + continue; + } + + if (current($headers) === current($expected)) + { + $i--; + } + else + { + echo "Header mismatch:\n\tExpected: " + .current($expected) + ."\n\tReceived: ".current($headers)."\n"; + } + + next($expected); +} +while (next($headers) !== FALSE); + +echo ($i === 0) + ? 'OK' + : 'A total of '.$i.' errors found.'; +--EXPECTHEADERS-- + +--EXPECT-- +OK \ No newline at end of file From 4a3bf25e3ffa71d8d65df686c27903d7c9fafee6 Mon Sep 17 00:00:00 2001 From: Martin Jansen Date: Mon, 24 Dec 2012 11:11:28 +0100 Subject: [PATCH 2244/2394] Add a timestamp to the mail log. This patch is loosely based on the one in bug #52126 but instead of using a UNIX timestamp it uses the date format also being used by error_log et al. --- ext/standard/mail.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/ext/standard/mail.c b/ext/standard/mail.c index 25766818f6b50..c8fd55e821d3a 100644 --- a/ext/standard/mail.c +++ b/ext/standard/mail.c @@ -21,10 +21,12 @@ #include #include #include +#include #include "php.h" #include "ext/standard/info.h" #include "ext/standard/php_string.h" #include "ext/standard/basic_functions.h" +#include "ext/date/php_date.h" #if HAVE_SYSEXITS_H #include @@ -246,8 +248,15 @@ PHPAPI int php_mail(char *to, char *subject, char *message, char *headers, char return val; \ if (mail_log && *mail_log) { - char *tmp; - int l = spprintf(&tmp, 0, "mail() on [%s:%d]: To: %s -- Headers: %s\n", zend_get_executed_filename(TSRMLS_C), zend_get_executed_lineno(TSRMLS_C), to, hdr ? hdr : ""); + char *tmp, *date_str; + time_t curtime; + + time(&curtime); + date_str = php_format_date("d-M-Y H:i:s e", 13, curtime, 1 TSRMLS_CC); + + int l = spprintf(&tmp, 0, "[%s] mail() on [%s:%d]: To: %s -- Headers: %s\n", date_str, zend_get_executed_filename(TSRMLS_C), zend_get_executed_lineno(TSRMLS_C), to, hdr ? hdr : ""); + + efree(date_str); if (hdr) { php_mail_log_crlf_to_spaces(tmp); From 371372714dcac655f53a53ef4d45ad02916b4f4a Mon Sep 17 00:00:00 2001 From: Martin Jansen Date: Sun, 6 Jan 2013 08:59:10 +0100 Subject: [PATCH 2245/2394] Add unit test for mail.log ini setting. --- ext/standard/tests/mail/mail_log.phpt | 48 +++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 ext/standard/tests/mail/mail_log.phpt diff --git a/ext/standard/tests/mail/mail_log.phpt b/ext/standard/tests/mail/mail_log.phpt new file mode 100644 index 0000000000000..86346ec307efe --- /dev/null +++ b/ext/standard/tests/mail/mail_log.phpt @@ -0,0 +1,48 @@ +--TEST-- +Test mail() function : mail.log ini setting +--INI-- +sendmail_path=tee /tmp/mail.out >/dev/null +mail.log = /tmp/mail.log +--SKIPIF-- + +--FILE-- + 0); +clearstatcache(); + +echo file_get_contents($logfile); +?> +Done +--CLEAN-- + +--EXPECTF-- +bool(true) +bool(true) +bool(true) +[%d-%s-%d %d:%d:%d UTC] mail() on [%smail_log.php:%d]: To: test@example.com -- Headers: X-Test: 1 +Done From a951693cfb17b8d84de4882f47ba6f7d6a776556 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sun, 6 Jan 2013 15:13:32 +0100 Subject: [PATCH 2246/2394] News entry for bug #52126 --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index 1ad954a09843f..cfd2aa3dbc84f 100644 --- a/NEWS +++ b/NEWS @@ -8,6 +8,7 @@ PHP NEWS (Nikita Popov) . Add Generator::throw() method. (Nikita Popov) . Bug #23955: allow specifying Max-Age attribute in setcookie() (narfbg, Lars) + . Bug #52126: timestamp for mail.log (Martin Jansen, Lars) - cURL: . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror From 8a481c711a1c899971494d88086701ca783c6795 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Sun, 6 Jan 2013 18:37:26 +0100 Subject: [PATCH 2247/2394] fix windows build --- ext/standard/mail.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/standard/mail.c b/ext/standard/mail.c index c8fd55e821d3a..4c243f778f17f 100644 --- a/ext/standard/mail.c +++ b/ext/standard/mail.c @@ -250,11 +250,12 @@ PHPAPI int php_mail(char *to, char *subject, char *message, char *headers, char if (mail_log && *mail_log) { char *tmp, *date_str; time_t curtime; + int l; time(&curtime); date_str = php_format_date("d-M-Y H:i:s e", 13, curtime, 1 TSRMLS_CC); - int l = spprintf(&tmp, 0, "[%s] mail() on [%s:%d]: To: %s -- Headers: %s\n", date_str, zend_get_executed_filename(TSRMLS_C), zend_get_executed_lineno(TSRMLS_C), to, hdr ? hdr : ""); + l = spprintf(&tmp, 0, "[%s] mail() on [%s:%d]: To: %s -- Headers: %s\n", date_str, zend_get_executed_filename(TSRMLS_C), zend_get_executed_lineno(TSRMLS_C), to, hdr ? hdr : ""); efree(date_str); From c0fae054c92cf73e5f7a7c32d624e43afabfd8e0 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 7 Jan 2013 13:03:12 +0100 Subject: [PATCH 2248/2394] - fix the fix for bug #50524 --- ext/standard/proc_open.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index db63a67b77591..9bf75868f0a58 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -512,6 +512,7 @@ PHP_FUNCTION(proc_open) DWORD dwCreateFlags = 0; char *command_with_cmd; UINT old_error_mode; + char cur_cwd[MAXPATHLEN]; #endif #ifdef NETWARE char** child_argv = NULL; @@ -752,13 +753,13 @@ PHP_FUNCTION(proc_open) #ifdef PHP_WIN32 if (cwd == NULL) { - char cur_cwd[MAXPATHLEN]; char *getcwd_result; getcwd_result = VCWD_GETCWD(cur_cwd, MAXPATHLEN); if (!getcwd_result) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot get current directory"); goto exit_fail; } + cwd = cur_cwd; } memset(&si, 0, sizeof(si)); From bcb3ad043aa36d56945960bf985a673f938711de Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Mon, 7 Jan 2013 13:09:20 +0100 Subject: [PATCH 2249/2394] - NEWS entry for #50524 --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index a0e8a6864215d..a1b0ab188ce70 100644 --- a/NEWS +++ b/NEWS @@ -16,6 +16,8 @@ PHP NEWS . Fixed bug ##62460 (php binaries installed as binary.dSYM). (Reeze Xia) . Fixed bug #60194 (--with-zend-multibyte and --enable-debug reports LEAK with run-test.php). (Laruence) + . Fixed bug #50524 (Fix the original fix, passing NULL as CWD does not + work on Windows). (Pierre) - CURL: . Fixed bug #62839 (curl_copy_handle segfault with CURLOPT_FILE). (Pierrick) From cde53e7fcd3f74cb29af4d3fb9fb09812ee1d4a0 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Mon, 7 Jan 2013 16:36:21 +0100 Subject: [PATCH 2250/2394] fix different values of mysqli_stmt_affected_rows between libmysql and mysqlnd (in favor of libmysql) before execute and after prepare() --- NEWS | 4 ++++ ext/mysqli/tests/057.phpt | 4 ++-- ext/mysqlnd/mysqlnd_ps.c | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index cfd2aa3dbc84f..e79501f679214 100644 --- a/NEWS +++ b/NEWS @@ -10,6 +10,10 @@ PHP NEWS . Bug #23955: allow specifying Max-Age attribute in setcookie() (narfbg, Lars) . Bug #52126: timestamp for mail.log (Martin Jansen, Lars) +- mysqlnd + . Fixed return value of mysqli_stmt_affected_rows() in the time after + prepare() and before execute(). (Andrey) + - cURL: . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror curl_pause, curl_reset, curl_share_close, curl_share_init, diff --git a/ext/mysqli/tests/057.phpt b/ext/mysqli/tests/057.phpt index 2cb887506aa4f..7c7e2b7568ee2 100644 --- a/ext/mysqli/tests/057.phpt +++ b/ext/mysqli/tests/057.phpt @@ -35,8 +35,8 @@ require_once('skipifconnectfailure.inc'); var_dump(mysqli_stmt_reset($stmt)); var_dump($stmt = mysqli_prepare($link, "SELECT * FROM test_store_result")); - if ($IS_MYSQLND && $stmt->affected_rows !== -1) - printf("[001] Expecting -1, got %d\n", $stmt->affected_rows); + if ($stmt->affected_rows !== 0) + printf("[001] Expecting 0, got %d\n", $stmt->affected_rows); var_dump(mysqli_stmt_execute($stmt)); var_dump($stmt = @mysqli_prepare($link, "SELECT * FROM test_store_result"), mysqli_error($link)); diff --git a/ext/mysqlnd/mysqlnd_ps.c b/ext/mysqlnd/mysqlnd_ps.c index 134be5fc53a76..4916c0650d7b7 100644 --- a/ext/mysqlnd/mysqlnd_ps.c +++ b/ext/mysqlnd/mysqlnd_ps.c @@ -307,6 +307,7 @@ mysqlnd_stmt_read_prepare_response(MYSQLND_STMT * s TSRMLS_DC) stmt->warning_count = stmt->conn->upsert_status->warning_count = prepare_resp->warning_count; stmt->field_count = stmt->conn->field_count = prepare_resp->field_count; stmt->param_count = prepare_resp->param_count; + stmt->upsert_status->affected_rows = 0; /* be like libmysql */ done: PACKET_FREE(prepare_resp); From 50ceeb9f750cecedc483ffc3d3e65a3324e21866 Mon Sep 17 00:00:00 2001 From: Pierre Joye Date: Tue, 8 Jan 2013 15:02:04 +0100 Subject: [PATCH 2251/2394] - fix bug #47358, glob returns error, should be empty array() --- ext/standard/dir.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ext/standard/dir.c b/ext/standard/dir.c index 37c3bc88c6b88..3f70ea94f507a 100644 --- a/ext/standard/dir.c +++ b/ext/standard/dir.c @@ -496,9 +496,7 @@ PHP_FUNCTION(glob) if (!globbuf.gl_pathc || !globbuf.gl_pathv) { no_results: if (PG(safe_mode) || (PG(open_basedir) && *PG(open_basedir))) { - struct stat s; - - if (0 != VCWD_STAT(pattern, &s) || S_IFDIR != (s.st_mode & S_IFMT)) { + if (php_check_open_basedir_ex(pattern, 0 TSRMLS_CC)) { RETURN_FALSE; } } From c3acefd9ea9f1c0b0900f75d05c14a1e6ab2b671 Mon Sep 17 00:00:00 2001 From: Joey Smith Date: Tue, 8 Jan 2013 14:18:31 -0700 Subject: [PATCH 2252/2394] Fix a typo in the ZipArchive error messages --- ext/zip/php_zip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index 727cc853ca1ae..5fd470a105ec4 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -410,7 +410,7 @@ static int php_zip_parse_options(zval *options, long *remove_all_path, ze_zip_object *obj = (ze_zip_object*) zend_object_store_get_object(object TSRMLS_CC); \ intern = obj->za; \ if (!intern) { \ - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid or unitialized Zip object"); \ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid or uninitialized Zip object"); \ RETURN_FALSE; \ } \ } From b8a369f522511109583cab276ee0d31bbb3f677a Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 9 Jan 2013 14:50:43 +0100 Subject: [PATCH 2253/2394] Add new constants --- ext/mysqlnd/mysqlnd_enum_n_def.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h index 3c50c2aa953f9..7dd4d0fb8f5f2 100644 --- a/ext/mysqlnd/mysqlnd_enum_n_def.h +++ b/ext/mysqlnd/mysqlnd_enum_n_def.h @@ -97,7 +97,9 @@ #define CLIENT_MULTI_RESULTS (1UL << 17) /* Enable/disable multi-results */ #define CLIENT_PS_MULTI_RESULTS (1UL << 18) /* Multi-results in PS-protocol */ #define CLIENT_PLUGIN_AUTH (1UL << 19) /* Client supports plugin authentication */ - +#define CLIENT_CONNECT_ATTRS (1UL << 20) /* Client supports connection attributes */ +#define CLIENT_PLUGIN_AUTH_LENENC_CLIENT_DATA (1UL << 21) /* Enable authentication response packet to be larger than 255 bytes. */ +#define CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS (1UL << 22) /* Don't close the connection for a connection with expired password. */ #define CLIENT_SSL_VERIFY_SERVER_CERT (1UL << 30) #define MYSQLND_CAPABILITIES (CLIENT_LONG_PASSWORD | CLIENT_LONG_FLAG | CLIENT_TRANSACTIONS | \ From ddcb67d446ba7a0637fdf3a52bdaaaa99ee80755 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Wed, 9 Jan 2013 15:33:07 +0100 Subject: [PATCH 2254/2394] support for password expiration in mysqlnd, through a flag --- ext/mysqlnd/mysqlnd.c | 9 ++++++++- ext/mysqlnd/mysqlnd_enum_n_def.h | 2 ++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 653561eaec2cc..b9db94b9df63e 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2282,7 +2282,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c break; #endif case MYSQL_OPT_LOCAL_INFILE: - if (!value || (*(unsigned int*) value) ? 1 : 0) { + if (value && (*(unsigned int*) value) ? 1 : 0) { conn->options->flags |= CLIENT_LOCAL_FILES; } else { conn->options->flags &= ~CLIENT_LOCAL_FILES; @@ -2366,6 +2366,13 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c DBG_INF_FMT("auth_protocol=%s", conn->options->auth_protocol); break; } + case MYSQL_OPT_CAN_HANDLE_EXPIRED_PASSWORDS: + if (value && (*(unsigned int*) value) ? 1 : 0) { + conn->options->flags |= CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS; + } else { + conn->options->flags &= ~CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS; + } + break; #ifdef WHEN_SUPPORTED_BY_MYSQLI case MYSQL_SHARED_MEMORY_BASE_NAME: case MYSQL_OPT_USE_RESULT: diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h index 7dd4d0fb8f5f2..abaaf1f43e30e 100644 --- a/ext/mysqlnd/mysqlnd_enum_n_def.h +++ b/ext/mysqlnd/mysqlnd_enum_n_def.h @@ -169,6 +169,8 @@ typedef enum mysqlnd_option MYSQL_PLUGIN_DIR, MYSQL_DEFAULT_AUTH, MYSQL_SERVER_PUBLIC_KEY, + MYSQL_ENABLE_CLEARTEXT_PLUGIN, + MYSQL_OPT_CAN_HANDLE_EXPIRED_PASSWORDS, MYSQLND_DEPRECATED_ENUM1 = 200, #ifdef MYSQLND_STRING_TO_INT_CONVERSION MYSQLND_OPT_INT_AND_FLOAT_NATIVE = 201, From 07590e6e456349192272da5ccfe8becbaa57fc67 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Wed, 9 Jan 2013 17:00:04 +0100 Subject: [PATCH 2255/2394] Export zend_parse_parameter() --- Zend/zend_API.c | 2 +- Zend/zend_API.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 22acb70125582..c89b611f19472 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -713,7 +713,7 @@ static int zend_parse_arg(int arg_num, zval **arg, va_list *va, const char **spe } /* }}} */ -int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...) +ZEND_API int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...) { va_list va; int ret; diff --git a/Zend/zend_API.h b/Zend/zend_API.h index f65fb172c5be5..e54b240a4c971 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -253,7 +253,7 @@ ZEND_API char *zend_zval_type_name(const zval *arg); ZEND_API int zend_parse_method_parameters(int num_args TSRMLS_DC, zval *this_ptr, const char *type_spec, ...); ZEND_API int zend_parse_method_parameters_ex(int flags, int num_args TSRMLS_DC, zval *this_ptr, const char *type_spec, ...); -int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...); +ZEND_API int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...); /* End of parameter parsing API -- andrei */ From 428aec8ce36a65cbfda061e8438d14789199a404 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Wed, 9 Jan 2013 17:16:40 +0100 Subject: [PATCH 2256/2394] Update README.PARAMETER_PARSING_API --- README.PARAMETER_PARSING_API | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/README.PARAMETER_PARSING_API b/README.PARAMETER_PARSING_API index 927e48188cc93..edcee0f2eaa09 100644 --- a/README.PARAMETER_PARSING_API +++ b/README.PARAMETER_PARSING_API @@ -28,6 +28,17 @@ Both functions return SUCCESS or FAILURE depending on the result. The auto-conversions are performed as necessary. Arrays, objects, and resources cannot be auto-converted. +PHP 5.5 includes a new function: + +int zend_parse_parameter(int flags, int arg_num TSRMLS_DC, zval **arg, const char *spec, ...); + +This function behaves like zend_parse_parameters_ex() except that instead of +reading the arguments from the stack, it receives a single zval to convert +(passed with double indirection). The passed zval may be changed in place as +part of the conversion process. + +See also https://wiki.php.net/rfc/zpp_improv#expose_zend_parse_arg_as_zend_parse_parameter + Type specifiers --------------- @@ -65,9 +76,13 @@ Type specifiers will not be touched by the parsing function if they are not passed to it. / - use SEPARATE_ZVAL_IF_NOT_REF() on the parameter it follows - ! - the parameter it follows can be of specified type or NULL (applies - to all specifiers except for 'b', 'l', and 'd'). If NULL is passed, the - results pointer is set to NULL as well. + ! - the parameter it follows can be of specified type or NULL. If NULL is + passed and the output for such type is a pointer, then the output + pointer is set to a native NULL pointer. + For 'b', 'l' and 'd', an extra argument of type zend_bool* must be + passed after the corresponding bool*, long* or double* arguments, + respectively. A non-zero value will be written to the zend_bool iif a + PHP NULL is passed. Note on 64bit compatibility From fe27146b1b533e046e9a5841bb6e5685296208a8 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Mon, 14 Jan 2013 13:54:43 +0800 Subject: [PATCH 2257/2394] Tinker with UPGRADING's wording for the format string changes for clarity. --- UPGRADING | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/UPGRADING b/UPGRADING index f65e8687049ca..6c53084cdd2f1 100755 --- a/UPGRADING +++ b/UPGRADING @@ -105,10 +105,11 @@ PHP 5.5 UPGRADE NOTES - pack()/unpack() had the following changes, which bring it more in line with Perl's behavior: - - Implemented format character "Z": NUL-padded string - - "a" now does not remove trailing NUL characters on unpack() anymore - - "A" will now strip all trailing ASCII whitespace on unpack() (it used to - remove only trailing spaces). + - Implemented format character "Z": NULL padded string, with trailing NULL + bytes removed. + - Changed format character "a": this no longer removes trailing NULL bytes. + - Changed format character "A": all trailing ASCII whitespace is now removed + (defined as spaces, tabs, \r, \n and NULL). - MessageFormatter::format() and related functions now accepted named arguments and mixed numeric/named arguments in ICU 4.8+. - MessageFormatter::format() and related functions now don't error out when From 62059c16ee2f2802caa00f2aad2fa44c867dd1f1 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 14 Jan 2013 16:23:22 +0800 Subject: [PATCH 2258/2394] Fixed bug #63980 (object members get trimmed by zero bytes) --- NEWS | 3 +++ Zend/zend.c | 5 +++-- Zend/zend_builtin_functions.c | 6 +++--- Zend/zend_compile.c | 20 ++++++++++++++++---- Zend/zend_compile.h | 4 +++- Zend/zend_vm_def.h | 3 +-- Zend/zend_vm_execute.h | 3 +-- 7 files changed, 30 insertions(+), 14 deletions(-) diff --git a/NEWS b/NEWS index e79501f679214..c31365e9214a9 100644 --- a/NEWS +++ b/NEWS @@ -2,6 +2,9 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 201?, PHP 5.5.0 Alpha 3 +- Core: + . Fixed bug #63980 (object members get trimmed by zero bytes). (Laruence) + - General improvements: . Fixed bug #63874 (Segfault if php_strip_whitespace has heredoc). (Pierrick) . Fixed bug #63822 (Crash when using closures with ArrayAccess). diff --git a/Zend/zend.c b/Zend/zend.c index d71d7cb5c8f40..aad6165e408a3 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -158,9 +158,10 @@ static void print_hash(zend_write_func_t write_func, HashTable *ht, int indent, case HASH_KEY_IS_STRING: if (is_object) { const char *prop_name, *class_name; - int mangled = zend_unmangle_property_name(string_key, str_len - 1, &class_name, &prop_name); + int prop_len; + int mangled = zend_unmangle_property_name_ex(string_key, str_len - 1, &class_name, &prop_name, &prop_len); - ZEND_PUTS_EX(prop_name); + ZEND_WRITE_EX(prop_name, prop_len); if (class_name && mangled == SUCCESS) { if (class_name[0]=='*') { ZEND_PUTS_EX(":protected"); diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 7bbb04785efc8..4d950a203b31e 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -987,7 +987,7 @@ ZEND_FUNCTION(get_object_vars) HashPosition pos; char *key; const char *prop_name, *class_name; - uint key_len; + uint key_len, prop_len; ulong num_index; zend_object *zobj; @@ -1014,10 +1014,10 @@ ZEND_FUNCTION(get_object_vars) while (zend_hash_get_current_data_ex(properties, (void **) &value, &pos) == SUCCESS) { if (zend_hash_get_current_key_ex(properties, &key, &key_len, &num_index, 0, &pos) == HASH_KEY_IS_STRING) { if (zend_check_property_access(zobj, key, key_len-1 TSRMLS_CC) == SUCCESS) { - zend_unmangle_property_name(key, key_len-1, &class_name, &prop_name); + zend_unmangle_property_name_ex(key, key_len - 1, &class_name, &prop_name, &prop_len); /* Not separating references */ Z_ADDREF_PP(value); - add_assoc_zval_ex(return_value, prop_name, strlen(prop_name)+1, *value); + add_assoc_zval_ex(return_value, prop_name, prop_len + 1, *value); } } zend_hash_move_forward_ex(properties, &pos); diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 101662cfe79d8..a5d6add5512a4 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -5178,7 +5178,7 @@ static int zend_strnlen(const char* s, int maxlen) /* {{{ */ } /* }}} */ -ZEND_API int zend_unmangle_property_name(const char *mangled_property, int len, const char **class_name, const char **prop_name) /* {{{ */ +ZEND_API int zend_unmangle_property_name_ex(const char *mangled_property, int len, const char **class_name, const char **prop_name, int *prop_len) /* {{{ */ { int class_name_len; @@ -5186,22 +5186,34 @@ ZEND_API int zend_unmangle_property_name(const char *mangled_property, int len, if (mangled_property[0]!=0) { *prop_name = mangled_property; + if (prop_len) { + *prop_len = len; + } return SUCCESS; } if (len < 3 || mangled_property[1]==0) { zend_error(E_NOTICE, "Illegal member variable name"); *prop_name = mangled_property; + if (prop_len) { + *prop_len = len; + } return FAILURE; } - class_name_len = zend_strnlen(mangled_property+1, --len - 1) + 1; + class_name_len = zend_strnlen(mangled_property + 1, --len - 1) + 1; if (class_name_len >= len || mangled_property[class_name_len]!=0) { zend_error(E_NOTICE, "Corrupt member variable name"); *prop_name = mangled_property; + if (prop_len) { + *prop_len = len + 1; + } return FAILURE; } - *class_name = mangled_property+1; - *prop_name = (*class_name)+class_name_len; + *class_name = mangled_property + 1; + *prop_name = (*class_name) + class_name_len; + if (prop_len) { + *prop_len = len - class_name_len; + } return SUCCESS; } /* }}} */ diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index d2ab0607b5b57..0f58b5550041e 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -671,7 +671,9 @@ ZEND_API void destroy_zend_class(zend_class_entry **pce); void zend_class_add_ref(zend_class_entry **ce); ZEND_API void zend_mangle_property_name(char **dest, int *dest_length, const char *src1, int src1_length, const char *src2, int src2_length, int internal); -ZEND_API int zend_unmangle_property_name(const char *mangled_property, int mangled_property_len, const char **class_name, const char **prop_name); +#define zend_unmangle_property_name(mangled_property, mangled_property_len, class_name, prop_name) \ + zend_unmangle_property_name_ex(mangled_property, mangled_property_len, class_name, prop_name, NULL) +ZEND_API int zend_unmangle_property_name_ex(const char *mangled_property, int mangled_property_len, const char **class_name, const char **prop_name, int *prop_len); #define ZEND_FUNCTION_DTOR (void (*)(void *)) zend_function_dtor #define ZEND_CLASS_DTOR (void (*)(void *)) destroy_zend_class diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 82826c904a4f5..3f9cc126ed9b2 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -4266,8 +4266,7 @@ ZEND_VM_HANDLER(78, ZEND_FE_FETCH, VAR, ANY) zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) != SUCCESS)); zend_hash_get_pointer(fe_ht, &EX_T(opline->op1.var).fe.fe_pos); if (use_key && key_type != HASH_KEY_IS_LONG) { - zend_unmangle_property_name(str_key, str_key_len-1, &class_name, &prop_name); - str_key_len = strlen(prop_name); + zend_unmangle_property_name_ex(str_key, str_key_len-1, &class_name, &prop_name, &str_key_len); str_key = estrndup(prop_name, str_key_len); str_key_len++; } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 23f6187ae7d95..614249f9934a3 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -13565,8 +13565,7 @@ static int ZEND_FASTCALL ZEND_FE_FETCH_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) != SUCCESS)); zend_hash_get_pointer(fe_ht, &EX_T(opline->op1.var).fe.fe_pos); if (use_key && key_type != HASH_KEY_IS_LONG) { - zend_unmangle_property_name(str_key, str_key_len-1, &class_name, &prop_name); - str_key_len = strlen(prop_name); + zend_unmangle_property_name_ex(str_key, str_key_len-1, &class_name, &prop_name, &str_key_len); str_key = estrndup(prop_name, str_key_len); str_key_len++; } From be07f815f240803fe7a48a5fb3d68a169bef4707 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 14 Jan 2013 17:08:21 +0800 Subject: [PATCH 2259/2394] Use zend_unmangle_property_name_ex to save strlen --- Zend/zend_compile.c | 5 ++--- Zend/zend_object_handlers.c | 5 +++-- ext/standard/http.c | 5 ++--- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index a5d6add5512a4..43b891695e0f4 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -4221,9 +4221,8 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { prop_name_length = property_info->name_length; } else { /* for private and protected we need to unmangle the names */ - zend_unmangle_property_name(property_info->name, property_info->name_length, - &class_name_unused, &prop_name); - prop_name_length = strlen(prop_name); + zend_unmangle_property_name_ex(property_info->name, property_info->name_length, + &class_name_unused, &prop_name, &prop_name_length); prop_hash = zend_get_hash_value(prop_name, prop_name_length + 1); } diff --git a/Zend/zend_object_handlers.c b/Zend/zend_object_handlers.c index 2c2a45d72676e..20d4e124c5baf 100644 --- a/Zend/zend_object_handlers.c +++ b/Zend/zend_object_handlers.c @@ -363,9 +363,10 @@ ZEND_API int zend_check_property_access(zend_object *zobj, const char *prop_info zend_property_info *property_info; const char *class_name, *prop_name; zval member; + int prop_name_len; - zend_unmangle_property_name(prop_info_name, prop_info_name_len, &class_name, &prop_name); - ZVAL_STRING(&member, prop_name, 0); + zend_unmangle_property_name_ex(prop_info_name, prop_info_name_len, &class_name, &prop_name, &prop_name_len); + ZVAL_STRINGL(&member, prop_name, prop_name_len, 0); property_info = zend_get_property_info_quick(zobj->ce, &member, 1, NULL TSRMLS_CC); if (!property_info) { return FAILURE; diff --git a/ext/standard/http.c b/ext/standard/http.c index 3e5073591e4ab..547df52186959 100644 --- a/ext/standard/http.c +++ b/ext/standard/http.c @@ -69,12 +69,11 @@ PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr, const char *tmp; zend_object *zobj = zend_objects_get_address(type TSRMLS_CC); - if (zend_check_property_access(zobj, key, key_len-1 TSRMLS_CC) != SUCCESS) { + if (zend_check_property_access(zobj, key, key_len TSRMLS_CC) != SUCCESS) { /* private or protected property access outside of the class */ continue; } - zend_unmangle_property_name(key, key_len-1, &tmp, (const char**)&key); - key_len = strlen(key); + zend_unmangle_property_name_ex(key, key_len, &tmp, (const char**)&key, &key_len); } if (zend_hash_get_current_data_ex(ht, (void **)&zdata, NULL) == FAILURE || !zdata || !(*zdata)) { From 200242595dabfdaf6093da3e9ae6fef246ea8906 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 14 Jan 2013 17:17:58 +0100 Subject: [PATCH 2260/2394] NEWS for bug #63893 --- NEWS | 2 ++ 1 file changed, 2 insertions(+) diff --git a/NEWS b/NEWS index 28040f7262fc1..418bcc91e89bb 100644 --- a/NEWS +++ b/NEWS @@ -7,6 +7,8 @@ PHP NEWS protected property). (Stas) . Fixed bug #63943 (Bad warning text from strpos() on empty needle). (Laruence) + . Fixed bug #63893 (poor efficiency of strtr() using array with keys of very + different length). (Gustavo) . Fixed bug #63882 (zend_std_compare_objects crash on recursion). (Dmitry) - Litespeed: From 22390d33935d72d897a1c97158ce2848f8551cc1 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 14 Jan 2013 17:24:16 +0100 Subject: [PATCH 2261/2394] Add zend_qsort_r & use it in strtr --- Zend/zend_qsort.c | 12 ++++++-- Zend/zend_qsort.h | 2 ++ ext/standard/string.c | 66 ++++++------------------------------------- 3 files changed, 19 insertions(+), 61 deletions(-) diff --git a/Zend/zend_qsort.c b/Zend/zend_qsort.c index bf179904efe58..128c48dfc8318 100644 --- a/Zend/zend_qsort.c +++ b/Zend/zend_qsort.c @@ -19,6 +19,7 @@ /* $Id$ */ #include "zend.h" +#include "zend_qsort.h" #include @@ -53,7 +54,7 @@ static void _zend_qsort_swap(void *a, void *b, size_t siz) } } -ZEND_API void zend_qsort(void *base, size_t nmemb, size_t siz, compare_func_t compare TSRMLS_DC) +ZEND_API void zend_qsort_r(void *base, size_t nmemb, size_t siz, compare_r_func_t compare, void *arg TSRMLS_DC) { void *begin_stack[QSORT_STACK_SIZE]; void *end_stack[QSORT_STACK_SIZE]; @@ -80,10 +81,10 @@ ZEND_API void zend_qsort(void *base, size_t nmemb, size_t siz, compare_func_t co seg2 = end; while (1) { - for (; seg1 < seg2 && compare(begin, seg1 TSRMLS_CC) > 0; + for (; seg1 < seg2 && compare(begin, seg1 TSRMLS_CC, arg) > 0; seg1 += siz); - for (; seg2 >= seg1 && compare(seg2, begin TSRMLS_CC) > 0; + for (; seg2 >= seg1 && compare(seg2, begin TSRMLS_CC, arg) > 0; seg2 -= siz); if (seg1 >= seg2) @@ -117,6 +118,11 @@ ZEND_API void zend_qsort(void *base, size_t nmemb, size_t siz, compare_func_t co } } +ZEND_API void zend_qsort(void *base, size_t nmemb, size_t siz, compare_func_t compare TSRMLS_DC) +{ + zend_qsort_r(base, nmemb, siz, (compare_r_func_t)compare, NULL TSRMLS_CC); +} + /* * Local Variables: * c-basic-offset: 4 diff --git a/Zend/zend_qsort.h b/Zend/zend_qsort.h index 58c99f26c2f58..0ce32a77c13d2 100644 --- a/Zend/zend_qsort.h +++ b/Zend/zend_qsort.h @@ -22,7 +22,9 @@ #define ZEND_QSORT_H BEGIN_EXTERN_C() +typedef int (*compare_r_func_t)(const void *, const void * TSRMLS_DC, void *); ZEND_API void zend_qsort(void *base, size_t nmemb, size_t siz, compare_func_t compare TSRMLS_DC); +ZEND_API void zend_qsort_r(void *base, size_t nmemb, size_t siz, compare_r_func_t compare, void *arg TSRMLS_DC); END_EXTERN_C() #endif /* ZEND_QSORT_H */ diff --git a/ext/standard/string.c b/ext/standard/string.c index 735a6138a3aab..8f7ef31d08173 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -2847,7 +2847,7 @@ static inline void php_strtr_populate_shift(PATNREPL *patterns, int patnum, int } /* }}} */ /* {{{ php_strtr_compare_hash_suffix */ -static int php_strtr_compare_hash_suffix(const void *a, const void *b, void *ctx_g) +static int php_strtr_compare_hash_suffix(const void *a, const void *b TSRMLS_DC, void *ctx_g) { const PPRES *res = ctx_g; const PATNREPL *pnr_a = a, @@ -2873,62 +2873,6 @@ static int php_strtr_compare_hash_suffix(const void *a, const void *b, void *ctx } } /* }}} */ -/* {{{ Sorting (no zend_qsort_r in this PHP version) */ -#define HS_LEFT(i) ((i) * 2 + 1) -#define HS_RIGHT(i) ((i) * 2 + 2) -#define HS_PARENT(i) (((i) - 1) / 2); -#define HS_OFF(data, i) ((void *)(&((data)->arr)[i])) -#define HS_CMP_CALL(data, i1, i2) \ - (php_strtr_compare_hash_suffix(HS_OFF((data), (i1)), HS_OFF((data), (i2)), (data)->res)) -struct hs_data { - PATNREPL *arr; - size_t nel; - size_t heapel; - PPRES *res; -}; -static inline void php_strtr_swap(PATNREPL *a, PATNREPL *b) -{ - PATNREPL tmp = *a; - *a = *b; - *b = tmp; -} -static inline void php_strtr_fix_heap(struct hs_data *data, size_t i) -{ - size_t li = HS_LEFT(i), - ri = HS_RIGHT(i), - largei; - if (li < data->heapel && HS_CMP_CALL(data, li, i) > 0) { - largei = li; - } else { - largei = i; - } - if (ri < data->heapel && HS_CMP_CALL(data, ri, largei) > 0) { - largei = ri; - } - if (largei != i) { - php_strtr_swap(HS_OFF(data, i), HS_OFF(data, largei)); - php_strtr_fix_heap(data, largei); - } -} -static inline void php_strtr_build_heap(struct hs_data *data) -{ - size_t i; - for (i = data->nel / 2; i > 0; i--) { - php_strtr_fix_heap(data, i - 1); - } -} -static inline void php_strtr_heapsort(PATNREPL *arr, size_t nel, PPRES *res) -{ - struct hs_data data = { arr, nel, nel, res }; - size_t i; - php_strtr_build_heap(&data); - for (i = nel; i > 1; i--) { - php_strtr_swap(arr, HS_OFF(&data, i - 1)); - data.heapel--; - php_strtr_fix_heap(&data, 0); - } -} -/* }}} */ /* {{{ php_strtr_free_strp */ static void php_strtr_free_strp(void *strp) { @@ -3026,7 +2970,13 @@ static PPRES *php_strtr_array_prepare(STR *text, PATNREPL *patterns, int patnum, res->patterns = safe_emalloc(patnum, sizeof(*res->patterns), 0); memcpy(res->patterns, patterns, sizeof(*patterns) * patnum); - php_strtr_heapsort(res->patterns, patnum, res); +#ifdef ZTS + zend_qsort_r(res->patterns, patnum, sizeof(*res->patterns), + php_strtr_compare_hash_suffix, res, NULL); /* tsrmls not needed */ +#else + zend_qsort_r(res->patterns, patnum, sizeof(*res->patterns), + php_strtr_compare_hash_suffix, res); +#endif res->prefix = safe_emalloc(patnum, sizeof(*res->prefix), 0); for (i = 0; i < patnum; i++) { From 70b25e9c61c849e590cc97137e893678cb5f98c3 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 14 Jan 2013 17:27:20 +0100 Subject: [PATCH 2262/2394] UPGRADING.INTERNALS: document zend_qsort_r --- UPGRADING.INTERNALS | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index 90c7a4394fd5d..44cdfaee6c83c 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -5,6 +5,7 @@ UPGRADE NOTES - PHP X.Y 1. Internal API changes a. Streams pooling API b. Lowercasing and locales + c. zend_qsort_r 2. Build system changes a. Unix build system changes @@ -53,6 +54,16 @@ such as strcasecmp, will be using locale rules. Two new functions - zend_binary_strncasecmp_l and zend_binary_strcasecmp_l - added as locale-based counterparts to zend_binary_strcasecmp and zend_binary_strncasecmp. + c. zend_qsort_r + +Added the function zend_qsort_r(): + +typedef int (*compare_r_func_t)(const void *, const void * TSRMLS_DC, void *); +void zend_qsort_r(void *base, size_t nmemb, size_t siz, compare_r_func_t compare, void *arg TSRMLS_DC); + +The extra argument it has (relatively to zend_qsort()) is passed to the +comparison function. + ======================== 2. Build system changes ======================== From 785e66adb536d40a26e4813e6b4ad96b2fdbef43 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Mon, 14 Jan 2013 20:43:14 +0100 Subject: [PATCH 2263/2394] PR #260: Update css for 404 pages to feel more up to date and have a consistent layout across browsers --- sapi/cli/php_cli_server.c | 8 +++++--- sapi/cli/tests/php_cli_server_013.phpt | 6 +++--- sapi/cli/tests/php_cli_server_014.phpt | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 74d2ad2c3bd40..700a495258048 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -246,7 +246,7 @@ static php_cli_server_http_reponse_status_code_pair status_map[] = { static php_cli_server_http_reponse_status_code_pair template_map[] = { { 400, "

%s

Your browser sent a request that this server could not understand.

" }, - { 404, "

%s

The requested resource %s was not found on this server.

" }, + { 404, "

%s

The requested resource %s was not found on this server.

" }, { 500, "

%s

The server is temporarily unavailable.

" }, { 501, "

%s

Request method not supported.

" } }; @@ -283,8 +283,10 @@ ZEND_DECLARE_MODULE_GLOBALS(cli_server); * copied from ext/standard/info.c */ static const char php_cli_server_css[] = "\n"; /* }}} */ diff --git a/sapi/cli/tests/php_cli_server_013.phpt b/sapi/cli/tests/php_cli_server_013.phpt index 570798a880117..0e3f4ff74f5b2 100644 --- a/sapi/cli/tests/php_cli_server_013.phpt +++ b/sapi/cli/tests/php_cli_server_013.phpt @@ -88,7 +88,7 @@ Content-Type: text/html; charset=UTF-8 Content-Length: %d 404 Not Found -

Not Found

The requested resource / was not found on this server.

+

Not Found

The requested resource / was not found on this server.

HTTP/1.1 404 Not Found Host: %s Connection: close @@ -96,7 +96,7 @@ Content-Type: text/html; charset=UTF-8 Content-Length: %d 404 Not Found -

Not Found

The requested resource /main/style.css was not found on this server.

+

Not Found

The requested resource /main/style.css was not found on this server.

HTTP/1.1 404 Not Found Host: %s Connection: close @@ -104,5 +104,5 @@ Content-Type: text/html; charset=UTF-8 Content-Length: %d 404 Not Found -

Not Found

The requested resource /main/foo/bar was not found on this server.

+

Not Found

The requested resource /main/foo/bar was not found on this server.

diff --git a/sapi/cli/tests/php_cli_server_014.phpt b/sapi/cli/tests/php_cli_server_014.phpt index f8a990561359a..e8bb5fa8a2f3c 100644 --- a/sapi/cli/tests/php_cli_server_014.phpt +++ b/sapi/cli/tests/php_cli_server_014.phpt @@ -77,4 +77,4 @@ Content-Type: %s Content-Length: %d 404 Not Found -

Not Found

The requested resource /main/no-exists.php was not found on this server.

+

Not Found

The requested resource /main/no-exists.php was not found on this server.

From 92965b033afa098945d18080203de1595084d1ac Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Mon, 14 Jan 2013 21:23:52 +0100 Subject: [PATCH 2264/2394] Bug #46408: Fix double formatting for PostgreSQL bound parameters --- NEWS | 6 +++++- Zend/zend_operators.c | 18 ++++++++++++++++++ Zend/zend_operators.h | 2 ++ ext/pgsql/pgsql.c | 2 +- ext/pgsql/tests/bug46408.phpt | 23 +++++++++++++++++++++++ 5 files changed, 49 insertions(+), 2 deletions(-) create mode 100644 ext/pgsql/tests/bug46408.phpt diff --git a/NEWS b/NEWS index c31365e9214a9..74c1134d7c757 100644 --- a/NEWS +++ b/NEWS @@ -19,12 +19,16 @@ PHP NEWS - cURL: . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror - curl_pause, curl_reset, curl_share_close, curl_share_init, + curl_pause, curl_reset, curl_share_close, curl_share_init, curl_share_setopt curl_strerror and curl_unescape. (Pierrick) . Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION, CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE, CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick) +- pgsql: + . Bug #46408: Locale number format settings can cause pg_query_params to + break with numerics. (asmecher, Lars) + 18 Dec 2012, PHP 5.5.0 Alpha 2 - General improvements: diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index bccccd96be586..274893c70ae79 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -572,6 +572,24 @@ ZEND_API void convert_to_boolean(zval *op) /* {{{ */ } /* }}} */ +ZEND_API void _convert_to_cstring(zval *op ZEND_FILE_LINE_DC) /* {{{ */ +{ + double dval; + switch (Z_TYPE_P(op)) { + case IS_DOUBLE: { + TSRMLS_FETCH(); + dval = Z_DVAL_P(op); + Z_STRLEN_P(op) = zend_spprintf(&Z_STRVAL_P(op), 0, "%.*H", (int) EG(precision), dval); + /* %H already handles removing trailing zeros from the fractional part, yay */ + break; + } + default: + return _convert_to_string(op); + } + Z_TYPE_P(op) = IS_STRING; +} +/* }}} */ + ZEND_API void _convert_to_string(zval *op ZEND_FILE_LINE_DC) /* {{{ */ { long lval; diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index d3f5e5a3d1bd8..20a5277d5b639 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -301,6 +301,7 @@ ZEND_API int increment_function(zval *op1); ZEND_API int decrement_function(zval *op2); ZEND_API void convert_scalar_to_number(zval *op TSRMLS_DC); +ZEND_API void _convert_to_cstring(zval *op ZEND_FILE_LINE_DC); ZEND_API void _convert_to_string(zval *op ZEND_FILE_LINE_DC); ZEND_API void convert_to_long(zval *op); ZEND_API void convert_to_double(zval *op); @@ -314,6 +315,7 @@ ZEND_API void multi_convert_to_double_ex(int argc, ...); ZEND_API void multi_convert_to_string_ex(int argc, ...); ZEND_API int add_char_to_string(zval *result, const zval *op1, const zval *op2); ZEND_API int add_string_to_string(zval *result, const zval *op1, const zval *op2); +#define convert_to_cstring(op) if ((op)->type != IS_STRING) { _convert_to_cstring((op) ZEND_FILE_LINE_CC); } #define convert_to_string(op) if ((op)->type != IS_STRING) { _convert_to_string((op) ZEND_FILE_LINE_CC); } ZEND_API double zend_string_to_double(const char *number, zend_uint length); diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c index d01dda6037f20..7ee838a9fa34d 100644 --- a/ext/pgsql/pgsql.c +++ b/ext/pgsql/pgsql.c @@ -1736,7 +1736,7 @@ PHP_FUNCTION(pg_query_params) } else { zval tmp_val = **tmp; zval_copy_ctor(&tmp_val); - convert_to_string(&tmp_val); + convert_to_cstring(&tmp_val); if (Z_TYPE(tmp_val) != IS_STRING) { php_error_docref(NULL TSRMLS_CC, E_WARNING,"Error converting parameter"); zval_dtor(&tmp_val); diff --git a/ext/pgsql/tests/bug46408.phpt b/ext/pgsql/tests/bug46408.phpt new file mode 100644 index 0000000000000..8c72ba5f3eb80 --- /dev/null +++ b/ext/pgsql/tests/bug46408.phpt @@ -0,0 +1,23 @@ +--TEST-- +Bug #46408 (Locale number format settings can cause pg_query_params to break with numerics) +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +3,5 +Done From 1cc61f09279b26b9acc82461c7b77051355346ad Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 17 Dec 2012 15:31:23 +0000 Subject: [PATCH 2265/2394] Implemented immutable DateTime objects as the DateTimePoint class. --- ext/date/php_date.c | 455 +++++++++++++++++++++++++++++++++++++------- ext/date/php_date.h | 13 ++ 2 files changed, 401 insertions(+), 67 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 0394cb6a5b756..61f6a95b91a79 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -385,7 +385,9 @@ const zend_function_entry date_functions[] = { /* Advanced Interface */ PHP_FE(date_create, arginfo_date_create) + PHP_FE(date_create_point, arginfo_date_create) PHP_FE(date_create_from_format, arginfo_date_create_from_format) + PHP_FE(date_create_point_from_format, arginfo_date_create_from_format) PHP_FE(date_parse, arginfo_date_parse) PHP_FE(date_parse_from_format, arginfo_date_parse_from_format) PHP_FE(date_get_last_errors, arginfo_date_get_last_errors) @@ -450,6 +452,20 @@ const zend_function_entry date_funcs_date[] = { PHP_FE_END }; +const zend_function_entry date_funcs_point[] = { + PHP_ME(DateTimePoint, __construct, arginfo_date_create, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) + PHP_ME(DateTimePoint, __set_state, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) + PHP_ME(DateTimePoint, modify, arginfo_date_method_modify, 0) + PHP_ME(DateTimePoint, add, arginfo_date_method_add, 0) + PHP_ME(DateTimePoint, sub, arginfo_date_method_sub, 0) + PHP_ME(DateTimePoint, setTimezone, arginfo_date_method_timezone_set, 0) + PHP_ME(DateTimePoint, setTime, arginfo_date_method_time_set, 0) + PHP_ME(DateTimePoint, setDate, arginfo_date_method_date_set, 0) + PHP_ME(DateTimePoint, setISODate, arginfo_date_method_isodate_set, 0) + PHP_ME(DateTimePoint, setTimestamp, arginfo_date_method_timestamp_set, 0) + PHP_FE_END +}; + const zend_function_entry date_funcs_timezone[] = { PHP_ME(DateTimeZone, __construct, arginfo_timezone_open, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) PHP_ME_MAPPING(getName, timezone_name_get, arginfo_timezone_method_name_get, 0) @@ -508,6 +524,7 @@ PHP_INI_END() /* }}} */ zend_class_entry *date_ce_date, *date_ce_timezone, *date_ce_interval, *date_ce_period; +zend_class_entry *date_ce_point; PHPAPI zend_class_entry *php_date_get_date_ce(void) @@ -515,12 +532,18 @@ PHPAPI zend_class_entry *php_date_get_date_ce(void) return date_ce_date; } +PHPAPI zend_class_entry *php_date_get_point_ce(void) +{ + return date_ce_point; +} + PHPAPI zend_class_entry *php_date_get_timezone_ce(void) { return date_ce_timezone; } static zend_object_handlers date_object_handlers_date; +static zend_object_handlers date_object_handlers_point; static zend_object_handlers date_object_handlers_timezone; static zend_object_handlers date_object_handlers_interval; static zend_object_handlers date_object_handlers_period; @@ -555,11 +578,13 @@ static void date_object_free_storage_interval(void *object TSRMLS_DC); static void date_object_free_storage_period(void *object TSRMLS_DC); static zend_object_value date_object_new_date(zend_class_entry *class_type TSRMLS_DC); +static zend_object_value date_object_new_point(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_new_timezone(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_new_interval(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_new_period(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC); +static zend_object_value date_object_clone_point(zval *this_ptr TSRMLS_DC); static zend_object_value date_object_clone_timezone(zval *this_ptr TSRMLS_DC); static zend_object_value date_object_clone_interval(zval *this_ptr TSRMLS_DC); static zend_object_value date_object_clone_period(zval *this_ptr TSRMLS_DC); @@ -1908,7 +1933,7 @@ zend_object_iterator *date_object_period_get_iterator(zend_class_entry *ce, zval static void date_register_classes(TSRMLS_D) { - zend_class_entry ce_date, ce_timezone, ce_interval, ce_period; + zend_class_entry ce_date, ce_point, ce_timezone, ce_interval, ce_period; INIT_CLASS_ENTRY(ce_date, "DateTime", date_funcs_date); ce_date.create_object = date_object_new_date; @@ -1934,6 +1959,13 @@ static void date_register_classes(TSRMLS_D) REGISTER_DATE_CLASS_CONST_STRING("RSS", DATE_FORMAT_RFC1123); REGISTER_DATE_CLASS_CONST_STRING("W3C", DATE_FORMAT_RFC3339); + INIT_CLASS_ENTRY(ce_point, "DateTimePoint", date_funcs_point); + ce_point.create_object = date_object_new_date; + date_ce_point = zend_register_internal_class_ex(&ce_point, date_ce_date, "DateTime" TSRMLS_CC); + memcpy(&date_object_handlers_point, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); + date_object_handlers_point.clone_obj = date_object_clone_date; + date_object_handlers_point.compare_objects = date_object_compare_date; + date_object_handlers_point.get_properties = date_object_get_properties; INIT_CLASS_ENTRY(ce_timezone, "DateTimeZone", date_funcs_timezone); ce_timezone.create_object = date_object_new_timezone; @@ -2034,6 +2066,19 @@ static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC) return new_ov; } +static zval* date_clone_point(zval *object) +{ + zval *new_object; + + ALLOC_ZVAL(new_object); + Z_OBJVAL_P(new_object) = date_object_clone_date(object); + Z_SET_REFCOUNT_P(new_object, 1); + Z_SET_ISREF_P(new_object); + Z_TYPE_P(new_object) = IS_OBJECT; + + return new_object; +} + static int date_object_compare_date(zval *d1, zval *d2 TSRMLS_DC) { if (Z_TYPE_P(d1) == IS_OBJECT && Z_TYPE_P(d2) == IS_OBJECT && @@ -2470,6 +2515,26 @@ PHP_FUNCTION(date_create) } /* }}} */ +/* {{{ proto DateTime date_create_point([string time[, DateTimeZone object]]) + Returns new DateTime object +*/ +PHP_FUNCTION(date_create_point) +{ + zval *timezone_object = NULL; + char *time_str = NULL; + int time_str_len = 0; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|sO!", &time_str, &time_str_len, &timezone_object, date_ce_timezone) == FAILURE) { + RETURN_FALSE; + } + + php_date_instantiate(date_ce_point, return_value TSRMLS_CC); + if (!php_date_initialize(zend_object_store_get_object(return_value TSRMLS_CC), time_str, time_str_len, NULL, timezone_object, 0 TSRMLS_CC)) { + RETURN_FALSE; + } +} +/* }}} */ + /* {{{ proto DateTime date_create_from_format(string format, string time[, DateTimeZone object]) Returns new DateTime object formatted according to the specified format */ @@ -2490,6 +2555,26 @@ PHP_FUNCTION(date_create_from_format) } /* }}} */ +/* {{{ proto DateTime date_create_point_from_format(string format, string time[, DateTimeZone object]) + Returns new DateTime object formatted according to the specified format +*/ +PHP_FUNCTION(date_create_point_from_format) +{ + zval *timezone_object = NULL; + char *time_str = NULL, *format_str = NULL; + int time_str_len = 0, format_str_len = 0; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|O", &format_str, &format_str_len, &time_str, &time_str_len, &timezone_object, date_ce_timezone) == FAILURE) { + RETURN_FALSE; + } + + php_date_instantiate(date_ce_point, return_value TSRMLS_CC); + if (!php_date_initialize(zend_object_store_get_object(return_value TSRMLS_CC), time_str, time_str_len, format_str, timezone_object, 0 TSRMLS_CC)) { + RETURN_FALSE; + } +} +/* }}} */ + /* {{{ proto DateTime::__construct([string time[, DateTimeZone object]]) Creates new DateTime object */ @@ -2508,6 +2593,24 @@ PHP_METHOD(DateTime, __construct) } /* }}} */ +/* {{{ proto DateTimePoint::__construct([string time[, DateTimeZone object]]) + Creates new DateTimePoint object +*/ +PHP_METHOD(DateTimePoint, __construct) +{ + zval *timezone_object = NULL; + char *time_str = NULL; + int time_str_len = 0; + zend_error_handling error_handling; + + zend_replace_error_handling(EH_THROW, NULL, &error_handling TSRMLS_CC); + if (SUCCESS == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|sO!", &time_str, &time_str_len, &timezone_object, date_ce_timezone)) { + php_date_initialize(zend_object_store_get_object(getThis() TSRMLS_CC), time_str, time_str_len, NULL, timezone_object, 1 TSRMLS_CC); + } + zend_restore_error_handling(&error_handling TSRMLS_CC); +} +/* }}} */ + static int php_date_initialize_from_hash(zval **return_value, php_date_obj **dateobj, HashTable *myht TSRMLS_DC) { zval **z_date = NULL; @@ -2575,6 +2678,26 @@ PHP_METHOD(DateTime, __set_state) } /* }}} */ +/* {{{ proto DateTimePoint::__set_state() +*/ +PHP_METHOD(DateTimePoint, __set_state) +{ + php_date_obj *dateobj; + zval *array; + HashTable *myht; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "a", &array) == FAILURE) { + RETURN_FALSE; + } + + myht = HASH_OF(array); + + php_date_instantiate(date_ce_point, return_value TSRMLS_CC); + dateobj = (php_date_obj *) zend_object_store_get_object(return_value TSRMLS_CC); + php_date_initialize_from_hash(&return_value, &dateobj, myht TSRMLS_CC); +} +/* }}} */ + /* {{{ proto DateTime::__wakeup() */ PHP_METHOD(DateTime, __wakeup) @@ -2760,21 +2883,12 @@ PHP_FUNCTION(date_format) } /* }}} */ -/* {{{ proto DateTime date_modify(DateTime object, string modify) - Alters the timestamp. -*/ -PHP_FUNCTION(date_modify) +static void php_date_modify(zval *object, char *modify, int modify_len, zval *return_value) { - zval *object; php_date_obj *dateobj; - char *modify; - int modify_len; timelib_time *tmp_time; timelib_error_container *err = NULL; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &object, date_ce_date, &modify, &modify_len) == FAILURE) { - RETURN_FALSE; - } dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); @@ -2823,30 +2937,57 @@ PHP_FUNCTION(date_modify) timelib_update_ts(dateobj->time, NULL); timelib_update_from_sse(dateobj->time); dateobj->time->have_relative = 0; +} - RETURN_ZVAL(object, 1, 0); +/* {{{ proto DateTime date_modify(DateTime object, string modify) + Alters the timestamp. +*/ +PHP_FUNCTION(date_modify) +{ + zval *object; + char *modify; + int modify_len; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &object, date_ce_date, &modify, &modify_len) == FAILURE) { + RETURN_FALSE; + } + + php_date_modify(object, modify, modify_len, return_value); + + RETURN_ZVAL(getThis(), 1, 0); } /* }}} */ -/* {{{ proto DateTime date_add(DateTime object, DateInterval interval) - Adds an interval to the current date in object. +/* {{{ proto DateTimePoint::modify() */ -PHP_FUNCTION(date_add) +PHP_METHOD(DateTimePoint, modify) { - zval *object, *interval; - php_date_obj *dateobj; - php_interval_obj *intobj; - int bias = 1; + zval *object, *new_object; + char *modify; + int modify_len; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &interval, date_ce_interval) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &object, date_ce_date, &modify, &modify_len) == FAILURE) { RETURN_FALSE; } + + new_object = date_clone_point(object); + php_date_modify(new_object, modify, modify_len, return_value); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + +static void php_date_add(zval *object, zval *interval, zval *return_value) +{ + php_date_obj *dateobj; + php_interval_obj *intobj; + int bias = 1; + dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); intobj = (php_interval_obj *) zend_object_store_get_object(interval TSRMLS_CC); DATE_CHECK_INITIALIZED(intobj->initialized, DateInterval); - if (intobj->diff->have_weekday_relative || intobj->diff->have_special_relative) { memcpy(&dateobj->time->relative, intobj->diff, sizeof(struct timelib_rel_time)); } else { @@ -2867,24 +3008,48 @@ PHP_FUNCTION(date_add) timelib_update_ts(dateobj->time, NULL); timelib_update_from_sse(dateobj->time); dateobj->time->have_relative = 0; +} + +/* {{{ proto DateTime date_add(DateTime object, DateInterval interval) + Adds an interval to the current date in object. +*/ +PHP_FUNCTION(date_add) +{ + zval *object, *interval; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &interval, date_ce_interval) == FAILURE) { + RETURN_FALSE; + } + + php_date_add(object, interval, return_value); RETURN_ZVAL(object, 1, 0); } /* }}} */ -/* {{{ proto DateTime date_sub(DateTime object, DateInterval interval) - Subtracts an interval to the current date in object. +/* {{{ proto DateTimePoint::add() */ -PHP_FUNCTION(date_sub) +PHP_METHOD(DateTimePoint, add) { - zval *object, *interval; - php_date_obj *dateobj; - php_interval_obj *intobj; - int bias = 1; + zval *object, *interval, *new_object; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &interval, date_ce_interval) == FAILURE) { RETURN_FALSE; } + + new_object = date_clone_point(object); + php_date_add(new_object, interval, return_value); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + +static void php_date_sub(zval *object, zval *interval, zval *return_value) +{ + php_date_obj *dateobj; + php_interval_obj *intobj; + int bias = 1; + dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); intobj = (php_interval_obj *) zend_object_store_get_object(interval TSRMLS_CC); @@ -2913,11 +3078,42 @@ PHP_FUNCTION(date_sub) timelib_update_from_sse(dateobj->time); dateobj->time->have_relative = 0; +} + +/* {{{ proto DateTime date_sub(DateTime object, DateInterval interval) + Subtracts an interval to the current date in object. +*/ +PHP_FUNCTION(date_sub) +{ + zval *object, *interval; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &interval, date_ce_interval) == FAILURE) { + RETURN_FALSE; + } + + php_date_sub(object, interval, return_value); RETURN_ZVAL(object, 1, 0); } /* }}} */ +/* {{{ proto DateTimePoint::sub() +*/ +PHP_METHOD(DateTimePoint, sub) +{ + zval *object, *interval, *new_object; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &interval, date_ce_interval) == FAILURE) { + RETURN_FALSE; + } + + new_object = date_clone_point(object); + php_date_sub(new_object, interval, return_value); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + /* {{{ proto DateTimeZone date_timezone_get(DateTime object) Return new DateTimeZone object relative to give DateTime */ @@ -2956,19 +3152,11 @@ PHP_FUNCTION(date_timezone_get) } /* }}} */ -/* {{{ proto DateTime date_timezone_set(DateTime object, DateTimeZone object) - Sets the timezone for the DateTime object. -*/ -PHP_FUNCTION(date_timezone_set) +static void php_date_timezone_set(zval *object, zval *timezone_object, zval *return_value TSRMLS_DC) { - zval *object; - zval *timezone_object; php_date_obj *dateobj; php_timezone_obj *tzobj; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &timezone_object, date_ce_timezone) == FAILURE) { - RETURN_FALSE; - } dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); tzobj = (php_timezone_obj *) zend_object_store_get_object(timezone_object TSRMLS_CC); @@ -2978,11 +3166,44 @@ PHP_FUNCTION(date_timezone_set) } timelib_set_timezone(dateobj->time, tzobj->tzi.tz); timelib_unixtime2local(dateobj->time, dateobj->time->sse); +} + +/* {{{ proto DateTime date_timezone_set(DateTime object, DateTimeZone object) + Sets the timezone for the DateTime object. +*/ +PHP_FUNCTION(date_timezone_set) +{ + zval *object; + zval *timezone_object; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &timezone_object, date_ce_timezone) == FAILURE) { + RETURN_FALSE; + } + + php_date_timezone_set(object, timezone_object, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } /* }}} */ +/* {{{ proto DateTimePoint::setTimezone() +*/ +PHP_METHOD(DateTimePoint, setTimezone) +{ + zval *object, *new_object; + zval *timezone_object; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &object, date_ce_date, &timezone_object, date_ce_timezone) == FAILURE) { + RETURN_FALSE; + } + + new_object = date_clone_point(object); + php_date_timezone_set(new_object, timezone_object, return_value TSRMLS_CC); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + /* {{{ proto long date_offset_get(DateTime object) Returns the DST offset. */ @@ -3018,64 +3239,106 @@ PHP_FUNCTION(date_offset_get) } /* }}} */ -/* {{{ proto DateTime date_time_set(DateTime object, long hour, long minute[, long second]) - Sets the time. -*/ -PHP_FUNCTION(date_time_set) +static void php_date_time_set(zval *object, long h, long i, long s, zval *return_value TSRMLS_DC) { - zval *object; php_date_obj *dateobj; - long h, i, s = 0; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll|l", &object, date_ce_date, &h, &i, &s) == FAILURE) { - RETURN_FALSE; - } dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); dateobj->time->h = h; dateobj->time->i = i; dateobj->time->s = s; timelib_update_ts(dateobj->time, NULL); +} + +/* {{{ proto DateTime date_time_set(DateTime object, long hour, long minute[, long second]) + Sets the time. +*/ +PHP_FUNCTION(date_time_set) +{ + zval *object; + long h, i, s = 0; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll|l", &object, date_ce_date, &h, &i, &s) == FAILURE) { + RETURN_FALSE; + } + + php_date_time_set(object, h, i, s, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } /* }}} */ -/* {{{ proto DateTime date_date_set(DateTime object, long year, long month, long day) - Sets the date. +/* {{{ proto DateTimePoint::setTime() */ -PHP_FUNCTION(date_date_set) +PHP_METHOD(DateTimePoint, setTime) { - zval *object; - php_date_obj *dateobj; - long y, m, d; + zval *object, *new_object; + long h, i, s = 0; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Olll", &object, date_ce_date, &y, &m, &d) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll|l", &object, date_ce_date, &h, &i, &s) == FAILURE) { RETURN_FALSE; } + + new_object = date_clone_point(object); + php_date_time_set(new_object, h, i, s, return_value TSRMLS_CC); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + +static void php_date_date_set(zval *object, long y, long m, long d, zval *return_value TSRMLS_DC) +{ + php_date_obj *dateobj; + dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); dateobj->time->y = y; dateobj->time->m = m; dateobj->time->d = d; timelib_update_ts(dateobj->time, NULL); +} + +/* {{{ proto DateTime date_date_set(DateTime object, long year, long month, long day) + Sets the date. +*/ +PHP_FUNCTION(date_date_set) +{ + zval *object; + long y, m, d; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Olll", &object, date_ce_date, &y, &m, &d) == FAILURE) { + RETURN_FALSE; + } + + php_date_date_set(object, y, m, d, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } /* }}} */ -/* {{{ proto DateTime date_isodate_set(DateTime object, long year, long week[, long day]) - Sets the ISO date. +/* {{{ proto DateTimePoint::setDate() */ -PHP_FUNCTION(date_isodate_set) +PHP_METHOD(DateTimePoint, setDate) { - zval *object; - php_date_obj *dateobj; - long y, w, d = 1; + zval *object, *new_object; + long y, m, d; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll|l", &object, date_ce_date, &y, &w, &d) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Olll", &object, date_ce_date, &y, &m, &d) == FAILURE) { RETURN_FALSE; } + + new_object = date_clone_point(object); + php_date_date_set(new_object, y, m, d, return_value TSRMLS_CC); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + +static void php_date_isodate_set(zval *object, long y, long w, long d, zval *return_value TSRMLS_DC) +{ + php_date_obj *dateobj; + dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); dateobj->time->y = y; @@ -3086,32 +3349,90 @@ PHP_FUNCTION(date_isodate_set) dateobj->time->have_relative = 1; timelib_update_ts(dateobj->time, NULL); +} + +/* {{{ proto DateTime date_isodate_set(DateTime object, long year, long week[, long day]) + Sets the ISO date. +*/ +PHP_FUNCTION(date_isodate_set) +{ + zval *object; + long y, w, d = 1; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll|l", &object, date_ce_date, &y, &w, &d) == FAILURE) { + RETURN_FALSE; + } + + php_date_isodate_set(object, y, w, d, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } /* }}} */ -/* {{{ proto DateTime date_timestamp_set(DateTime object, long unixTimestamp) - Sets the date and time based on an Unix timestamp. +/* {{{ proto DateTimePoint::setISODate() */ -PHP_FUNCTION(date_timestamp_set) +PHP_METHOD(DateTimePoint, setISODate) { - zval *object; - php_date_obj *dateobj; - long timestamp; + zval *object, *new_object; + long y, w, d = 1; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &object, date_ce_date, ×tamp) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll|l", &object, date_ce_date, &y, &w, &d) == FAILURE) { RETURN_FALSE; } + + new_object = date_clone_point(object); + php_date_isodate_set(new_object, y, w, d, return_value TSRMLS_CC); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + +static void php_date_timestamp_set(zval *object, long timestamp, zval *return_value TSRMLS_DC) +{ + php_date_obj *dateobj; + dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); DATE_CHECK_INITIALIZED(dateobj->time, DateTime); timelib_unixtime2local(dateobj->time, (timelib_sll)timestamp); timelib_update_ts(dateobj->time, NULL); +} + +/* {{{ proto DateTime date_timestamp_set(DateTime object, long unixTimestamp) + Sets the date and time based on an Unix timestamp. +*/ +PHP_FUNCTION(date_timestamp_set) +{ + zval *object; + long timestamp; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &object, date_ce_date, ×tamp) == FAILURE) { + RETURN_FALSE; + } + + php_date_timestamp_set(object, timestamp, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } /* }}} */ +/* {{{ proto DateTimePoint::setTimestamp() +*/ +PHP_METHOD(DateTimePoint, setTimestamp) +{ + zval *object, *new_object; + long timestamp; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &object, date_ce_date, ×tamp) == FAILURE) { + RETURN_FALSE; + } + + new_object = date_clone_point(object); + php_date_timestamp_set(new_object, timestamp, return_value TSRMLS_CC); + + RETURN_ZVAL(new_object, 0, 1); +} +/* }}} */ + /* {{{ proto long date_timestamp_get(DateTime object) Gets the Unix timestamp. */ diff --git a/ext/date/php_date.h b/ext/date/php_date.h index f0b662b5d9f35..ffe1c3c646efc 100644 --- a/ext/date/php_date.h +++ b/ext/date/php_date.h @@ -51,7 +51,9 @@ PHP_METHOD(DateTime, __construct); PHP_METHOD(DateTime, __wakeup); PHP_METHOD(DateTime, __set_state); PHP_FUNCTION(date_create); +PHP_FUNCTION(date_create_point); PHP_FUNCTION(date_create_from_format); +PHP_FUNCTION(date_create_point_from_format); PHP_FUNCTION(date_parse); PHP_FUNCTION(date_parse_from_format); PHP_FUNCTION(date_get_last_errors); @@ -70,6 +72,17 @@ PHP_FUNCTION(date_isodate_set); PHP_FUNCTION(date_timestamp_set); PHP_FUNCTION(date_timestamp_get); +PHP_METHOD(DateTimePoint, __construct); +PHP_METHOD(DateTimePoint, __set_state); +PHP_METHOD(DateTimePoint, modify); +PHP_METHOD(DateTimePoint, add); +PHP_METHOD(DateTimePoint, sub); +PHP_METHOD(DateTimePoint, setTimezone); +PHP_METHOD(DateTimePoint, setTime); +PHP_METHOD(DateTimePoint, setDate); +PHP_METHOD(DateTimePoint, setISODate); +PHP_METHOD(DateTimePoint, setTimestamp); + PHP_METHOD(DateTimeZone, __construct); PHP_FUNCTION(timezone_open); PHP_FUNCTION(timezone_name_get); From 45a429200cdf7e918ef3aabc0eb23441f6e8eda3 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 17 Dec 2012 16:35:52 +0000 Subject: [PATCH 2266/2394] Added a test case for DateTimePoint. --- ext/date/tests/date_time_point.phpt | 167 ++++++++++++++++++++++++++++ 1 file changed, 167 insertions(+) create mode 100644 ext/date/tests/date_time_point.phpt diff --git a/ext/date/tests/date_time_point.phpt b/ext/date/tests/date_time_point.phpt new file mode 100644 index 0000000000000..810eeca184bcc --- /dev/null +++ b/ext/date/tests/date_time_point.phpt @@ -0,0 +1,167 @@ +--TEST-- +Tests for DateTimePoint. +--INI-- +date.timezone=Europe/London +--FILE-- +format('Y-m-d H:i:s e'), "\n"; + echo 'copy: ', $b->format('Y-m-d H:i:s e'), "\n"; + echo 'changed: ', $c->format('Y-m-d H:i:s e'), "\n"; +} + +echo "modify():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->modify("+2 days"); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->modify("+2 days"); +dump($v, $z, $x); + +echo "\nadd():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->add(new DateInterval("P2DT2S")); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->add(new DateInterval("P2DT2S")); +dump($v, $z, $x); + +echo "\nsub():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->sub(new DateInterval("P2DT2S")); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->sub(new DateInterval("P2DT2S")); +dump($v, $z, $x); + +echo "\nsetTimezone():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->setTimezone($tz); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->setTimezone($tz); +dump($v, $z, $x); +$v = new DateTimePoint($current); +$z = $v; +$x = $z->setTimezone($tz); +dump($v, $z, $x); + +echo "\nsetTime():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->setTime(5, 7, 19); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->setTime(5, 7, 19); +dump($v, $z, $x); + +echo "\nsetDate():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->setDate(5, 7, 19); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->setDate(5, 7, 19); +dump($v, $z, $x); + +echo "\nsetIsoDate():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->setIsoDate(2012, 2, 6); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->setIsoDate(2012, 2, 6); +dump($v, $z, $x); + +echo "\nsetTimestamp():\n"; +$v = date_create_point($current); +$z = $v; +$x = $z->setTimestamp(2012234222); +dump($v, $z, $x); +$v = date_create($current); +$z = $v; +$x = $z->setTimestamp(2012234222); +dump($v, $z, $x); +?> +--EXPECT-- +modify(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-12-29 16:24:08 Europe/London +orig: 2012-12-29 16:24:08 Europe/London +copy: 2012-12-29 16:24:08 Europe/London +changed: 2012-12-29 16:24:08 Europe/London + +add(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-12-29 16:24:10 Europe/London +orig: 2012-12-29 16:24:10 Europe/London +copy: 2012-12-29 16:24:10 Europe/London +changed: 2012-12-29 16:24:10 Europe/London + +sub(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-12-25 16:24:06 Europe/London +orig: 2012-12-25 16:24:06 Europe/London +copy: 2012-12-25 16:24:06 Europe/London +changed: 2012-12-25 16:24:06 Europe/London + +setTimezone(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-12-28 01:24:08 Asia/Tokyo +orig: 2012-12-28 01:24:08 Asia/Tokyo +copy: 2012-12-28 01:24:08 Asia/Tokyo +changed: 2012-12-28 01:24:08 Asia/Tokyo +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-12-28 01:24:08 Asia/Tokyo + +setTime(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-12-27 05:07:19 Europe/London +orig: 2012-12-27 05:07:19 Europe/London +copy: 2012-12-27 05:07:19 Europe/London +changed: 2012-12-27 05:07:19 Europe/London + +setDate(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 0005-07-19 16:24:08 Europe/London +orig: 0005-07-19 16:24:08 Europe/London +copy: 0005-07-19 16:24:08 Europe/London +changed: 0005-07-19 16:24:08 Europe/London + +setIsoDate(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2012-01-14 16:24:08 Europe/London +orig: 2012-01-14 16:24:08 Europe/London +copy: 2012-01-14 16:24:08 Europe/London +changed: 2012-01-14 16:24:08 Europe/London + +setTimestamp(): +orig: 2012-12-27 16:24:08 Europe/London +copy: 2012-12-27 16:24:08 Europe/London +changed: 2033-10-06 18:57:02 Europe/London +orig: 2033-10-06 18:57:02 Europe/London +copy: 2033-10-06 18:57:02 Europe/London +changed: 2033-10-06 18:57:02 Europe/London From 3919d0adf734f37d7db7c6d76522cd75ac608250 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 17 Dec 2012 16:49:00 +0000 Subject: [PATCH 2267/2394] Added a few missing TSRMLS_DC/TSRMLS_CC. --- ext/date/php_date.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 61f6a95b91a79..3fbdaf2281bd7 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2883,7 +2883,7 @@ PHP_FUNCTION(date_format) } /* }}} */ -static void php_date_modify(zval *object, char *modify, int modify_len, zval *return_value) +static void php_date_modify(zval *object, char *modify, int modify_len, zval *return_value TSRMLS_DC) { php_date_obj *dateobj; timelib_time *tmp_time; @@ -2952,7 +2952,7 @@ PHP_FUNCTION(date_modify) RETURN_FALSE; } - php_date_modify(object, modify, modify_len, return_value); + php_date_modify(object, modify, modify_len, return_value TSRMLS_CC); RETURN_ZVAL(getThis(), 1, 0); } @@ -2971,13 +2971,13 @@ PHP_METHOD(DateTimePoint, modify) } new_object = date_clone_point(object); - php_date_modify(new_object, modify, modify_len, return_value); + php_date_modify(new_object, modify, modify_len, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); } /* }}} */ -static void php_date_add(zval *object, zval *interval, zval *return_value) +static void php_date_add(zval *object, zval *interval, zval *return_value TSRMLS_DC) { php_date_obj *dateobj; php_interval_obj *intobj; @@ -3021,7 +3021,7 @@ PHP_FUNCTION(date_add) RETURN_FALSE; } - php_date_add(object, interval, return_value); + php_date_add(object, interval, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } @@ -3038,13 +3038,13 @@ PHP_METHOD(DateTimePoint, add) } new_object = date_clone_point(object); - php_date_add(new_object, interval, return_value); + php_date_add(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); } /* }}} */ -static void php_date_sub(zval *object, zval *interval, zval *return_value) +static void php_date_sub(zval *object, zval *interval, zval *return_value TSRMLS_DC) { php_date_obj *dateobj; php_interval_obj *intobj; @@ -3091,7 +3091,7 @@ PHP_FUNCTION(date_sub) RETURN_FALSE; } - php_date_sub(object, interval, return_value); + php_date_sub(object, interval, return_value TSRMLS_CC); RETURN_ZVAL(object, 1, 0); } @@ -3108,7 +3108,7 @@ PHP_METHOD(DateTimePoint, sub) } new_object = date_clone_point(object); - php_date_sub(new_object, interval, return_value); + php_date_sub(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); } From a0bea9a1de7123d52b0339ad9d883bbe231122d5 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 17 Dec 2012 16:49:25 +0000 Subject: [PATCH 2268/2394] Added another test to test the unmodified inherited methods. --- ext/date/tests/date_time_point-inherited.phpt | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 ext/date/tests/date_time_point-inherited.phpt diff --git a/ext/date/tests/date_time_point-inherited.phpt b/ext/date/tests/date_time_point-inherited.phpt new file mode 100644 index 0000000000000..e35540753c1ae --- /dev/null +++ b/ext/date/tests/date_time_point-inherited.phpt @@ -0,0 +1,25 @@ +--TEST-- +Tests for DateTimePoint. +--INI-- +date.timezone=Europe/London +--FILE-- +getTimezone(); +var_dump($x->getName()); + +echo "\ngetTimestamp():\n"; +$v = date_create_point($current); +$x = $v->getTimestamp(); +var_dump($x); +?> +--EXPECT-- +getTimezone(): +string(13) "Europe/London" + +getTimestamp(): +int(1356625448) From 017b1f7fca09896b05f2602136ffba7585cd4bfe Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Wed, 19 Dec 2012 16:24:38 +0000 Subject: [PATCH 2269/2394] Rename DateTimePoint to DateTimeImmutable. --- ext/date/php_date.c | 128 +++++++++--------- ext/date/php_date.h | 24 ++-- ...hpt => date_time_immutable-inherited.phpt} | 6 +- ...me_point.phpt => date_time_immutable.phpt} | 20 +-- 4 files changed, 89 insertions(+), 89 deletions(-) rename ext/date/tests/{date_time_point-inherited.phpt => date_time_immutable-inherited.phpt} (77%) rename ext/date/tests/{date_time_point.phpt => date_time_immutable.phpt} (91%) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 3fbdaf2281bd7..596a7a94d9d0c 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -385,9 +385,9 @@ const zend_function_entry date_functions[] = { /* Advanced Interface */ PHP_FE(date_create, arginfo_date_create) - PHP_FE(date_create_point, arginfo_date_create) + PHP_FE(date_create_immutable, arginfo_date_create) PHP_FE(date_create_from_format, arginfo_date_create_from_format) - PHP_FE(date_create_point_from_format, arginfo_date_create_from_format) + PHP_FE(date_create_immutable_from_format, arginfo_date_create_from_format) PHP_FE(date_parse, arginfo_date_parse) PHP_FE(date_parse_from_format, arginfo_date_parse_from_format) PHP_FE(date_get_last_errors, arginfo_date_get_last_errors) @@ -452,17 +452,17 @@ const zend_function_entry date_funcs_date[] = { PHP_FE_END }; -const zend_function_entry date_funcs_point[] = { - PHP_ME(DateTimePoint, __construct, arginfo_date_create, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) - PHP_ME(DateTimePoint, __set_state, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - PHP_ME(DateTimePoint, modify, arginfo_date_method_modify, 0) - PHP_ME(DateTimePoint, add, arginfo_date_method_add, 0) - PHP_ME(DateTimePoint, sub, arginfo_date_method_sub, 0) - PHP_ME(DateTimePoint, setTimezone, arginfo_date_method_timezone_set, 0) - PHP_ME(DateTimePoint, setTime, arginfo_date_method_time_set, 0) - PHP_ME(DateTimePoint, setDate, arginfo_date_method_date_set, 0) - PHP_ME(DateTimePoint, setISODate, arginfo_date_method_isodate_set, 0) - PHP_ME(DateTimePoint, setTimestamp, arginfo_date_method_timestamp_set, 0) +const zend_function_entry date_funcs_immutable[] = { + PHP_ME(DateTimeImmutable, __construct, arginfo_date_create, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) + PHP_ME(DateTimeImmutable, __set_state, NULL, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) + PHP_ME(DateTimeImmutable, modify, arginfo_date_method_modify, 0) + PHP_ME(DateTimeImmutable, add, arginfo_date_method_add, 0) + PHP_ME(DateTimeImmutable, sub, arginfo_date_method_sub, 0) + PHP_ME(DateTimeImmutable, setTimezone, arginfo_date_method_timezone_set, 0) + PHP_ME(DateTimeImmutable, setTime, arginfo_date_method_time_set, 0) + PHP_ME(DateTimeImmutable, setDate, arginfo_date_method_date_set, 0) + PHP_ME(DateTimeImmutable, setISODate, arginfo_date_method_isodate_set, 0) + PHP_ME(DateTimeImmutable, setTimestamp, arginfo_date_method_timestamp_set, 0) PHP_FE_END }; @@ -524,7 +524,7 @@ PHP_INI_END() /* }}} */ zend_class_entry *date_ce_date, *date_ce_timezone, *date_ce_interval, *date_ce_period; -zend_class_entry *date_ce_point; +zend_class_entry *date_ce_immutable; PHPAPI zend_class_entry *php_date_get_date_ce(void) @@ -532,9 +532,9 @@ PHPAPI zend_class_entry *php_date_get_date_ce(void) return date_ce_date; } -PHPAPI zend_class_entry *php_date_get_point_ce(void) +PHPAPI zend_class_entry *php_date_get_immutable_ce(void) { - return date_ce_point; + return date_ce_immutable; } PHPAPI zend_class_entry *php_date_get_timezone_ce(void) @@ -543,7 +543,7 @@ PHPAPI zend_class_entry *php_date_get_timezone_ce(void) } static zend_object_handlers date_object_handlers_date; -static zend_object_handlers date_object_handlers_point; +static zend_object_handlers date_object_handlers_immutable; static zend_object_handlers date_object_handlers_timezone; static zend_object_handlers date_object_handlers_interval; static zend_object_handlers date_object_handlers_period; @@ -578,13 +578,13 @@ static void date_object_free_storage_interval(void *object TSRMLS_DC); static void date_object_free_storage_period(void *object TSRMLS_DC); static zend_object_value date_object_new_date(zend_class_entry *class_type TSRMLS_DC); -static zend_object_value date_object_new_point(zend_class_entry *class_type TSRMLS_DC); +static zend_object_value date_object_new_immutable(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_new_timezone(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_new_interval(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_new_period(zend_class_entry *class_type TSRMLS_DC); static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC); -static zend_object_value date_object_clone_point(zval *this_ptr TSRMLS_DC); +static zend_object_value date_object_clone_immutable(zval *this_ptr TSRMLS_DC); static zend_object_value date_object_clone_timezone(zval *this_ptr TSRMLS_DC); static zend_object_value date_object_clone_interval(zval *this_ptr TSRMLS_DC); static zend_object_value date_object_clone_period(zval *this_ptr TSRMLS_DC); @@ -1933,7 +1933,7 @@ zend_object_iterator *date_object_period_get_iterator(zend_class_entry *ce, zval static void date_register_classes(TSRMLS_D) { - zend_class_entry ce_date, ce_point, ce_timezone, ce_interval, ce_period; + zend_class_entry ce_date, ce_immutable, ce_timezone, ce_interval, ce_period; INIT_CLASS_ENTRY(ce_date, "DateTime", date_funcs_date); ce_date.create_object = date_object_new_date; @@ -1959,13 +1959,13 @@ static void date_register_classes(TSRMLS_D) REGISTER_DATE_CLASS_CONST_STRING("RSS", DATE_FORMAT_RFC1123); REGISTER_DATE_CLASS_CONST_STRING("W3C", DATE_FORMAT_RFC3339); - INIT_CLASS_ENTRY(ce_point, "DateTimePoint", date_funcs_point); - ce_point.create_object = date_object_new_date; - date_ce_point = zend_register_internal_class_ex(&ce_point, date_ce_date, "DateTime" TSRMLS_CC); - memcpy(&date_object_handlers_point, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); - date_object_handlers_point.clone_obj = date_object_clone_date; - date_object_handlers_point.compare_objects = date_object_compare_date; - date_object_handlers_point.get_properties = date_object_get_properties; + INIT_CLASS_ENTRY(ce_immutable, "DateTimeImmutable", date_funcs_immutable); + ce_immutable.create_object = date_object_new_date; + date_ce_immutable = zend_register_internal_class_ex(&ce_immutable, date_ce_date, "DateTime" TSRMLS_CC); + memcpy(&date_object_handlers_immutable, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); + date_object_handlers_immutable.clone_obj = date_object_clone_date; + date_object_handlers_immutable.compare_objects = date_object_compare_date; + date_object_handlers_immutable.get_properties = date_object_get_properties; INIT_CLASS_ENTRY(ce_timezone, "DateTimeZone", date_funcs_timezone); ce_timezone.create_object = date_object_new_timezone; @@ -2066,7 +2066,7 @@ static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC) return new_ov; } -static zval* date_clone_point(zval *object) +static zval* date_clone_immutable(zval *object) { zval *new_object; @@ -2515,10 +2515,10 @@ PHP_FUNCTION(date_create) } /* }}} */ -/* {{{ proto DateTime date_create_point([string time[, DateTimeZone object]]) +/* {{{ proto DateTime date_create_immutable([string time[, DateTimeZone object]]) Returns new DateTime object */ -PHP_FUNCTION(date_create_point) +PHP_FUNCTION(date_create_immutable) { zval *timezone_object = NULL; char *time_str = NULL; @@ -2528,7 +2528,7 @@ PHP_FUNCTION(date_create_point) RETURN_FALSE; } - php_date_instantiate(date_ce_point, return_value TSRMLS_CC); + php_date_instantiate(date_ce_immutable, return_value TSRMLS_CC); if (!php_date_initialize(zend_object_store_get_object(return_value TSRMLS_CC), time_str, time_str_len, NULL, timezone_object, 0 TSRMLS_CC)) { RETURN_FALSE; } @@ -2555,10 +2555,10 @@ PHP_FUNCTION(date_create_from_format) } /* }}} */ -/* {{{ proto DateTime date_create_point_from_format(string format, string time[, DateTimeZone object]) +/* {{{ proto DateTime date_create_immutable_from_format(string format, string time[, DateTimeZone object]) Returns new DateTime object formatted according to the specified format */ -PHP_FUNCTION(date_create_point_from_format) +PHP_FUNCTION(date_create_immutable_from_format) { zval *timezone_object = NULL; char *time_str = NULL, *format_str = NULL; @@ -2568,7 +2568,7 @@ PHP_FUNCTION(date_create_point_from_format) RETURN_FALSE; } - php_date_instantiate(date_ce_point, return_value TSRMLS_CC); + php_date_instantiate(date_ce_immutable, return_value TSRMLS_CC); if (!php_date_initialize(zend_object_store_get_object(return_value TSRMLS_CC), time_str, time_str_len, format_str, timezone_object, 0 TSRMLS_CC)) { RETURN_FALSE; } @@ -2593,10 +2593,10 @@ PHP_METHOD(DateTime, __construct) } /* }}} */ -/* {{{ proto DateTimePoint::__construct([string time[, DateTimeZone object]]) - Creates new DateTimePoint object +/* {{{ proto DateTimeImmutable::__construct([string time[, DateTimeZone object]]) + Creates new DateTimeImmutable object */ -PHP_METHOD(DateTimePoint, __construct) +PHP_METHOD(DateTimeImmutable, __construct) { zval *timezone_object = NULL; char *time_str = NULL; @@ -2678,9 +2678,9 @@ PHP_METHOD(DateTime, __set_state) } /* }}} */ -/* {{{ proto DateTimePoint::__set_state() +/* {{{ proto DateTimeImmutable::__set_state() */ -PHP_METHOD(DateTimePoint, __set_state) +PHP_METHOD(DateTimeImmutable, __set_state) { php_date_obj *dateobj; zval *array; @@ -2692,7 +2692,7 @@ PHP_METHOD(DateTimePoint, __set_state) myht = HASH_OF(array); - php_date_instantiate(date_ce_point, return_value TSRMLS_CC); + php_date_instantiate(date_ce_immutable, return_value TSRMLS_CC); dateobj = (php_date_obj *) zend_object_store_get_object(return_value TSRMLS_CC); php_date_initialize_from_hash(&return_value, &dateobj, myht TSRMLS_CC); } @@ -2958,9 +2958,9 @@ PHP_FUNCTION(date_modify) } /* }}} */ -/* {{{ proto DateTimePoint::modify() +/* {{{ proto DateTimeImmutable::modify() */ -PHP_METHOD(DateTimePoint, modify) +PHP_METHOD(DateTimeImmutable, modify) { zval *object, *new_object; char *modify; @@ -2970,7 +2970,7 @@ PHP_METHOD(DateTimePoint, modify) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_modify(new_object, modify, modify_len, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3027,9 +3027,9 @@ PHP_FUNCTION(date_add) } /* }}} */ -/* {{{ proto DateTimePoint::add() +/* {{{ proto DateTimeImmutable::add() */ -PHP_METHOD(DateTimePoint, add) +PHP_METHOD(DateTimeImmutable, add) { zval *object, *interval, *new_object; @@ -3037,7 +3037,7 @@ PHP_METHOD(DateTimePoint, add) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_add(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3097,9 +3097,9 @@ PHP_FUNCTION(date_sub) } /* }}} */ -/* {{{ proto DateTimePoint::sub() +/* {{{ proto DateTimeImmutable::sub() */ -PHP_METHOD(DateTimePoint, sub) +PHP_METHOD(DateTimeImmutable, sub) { zval *object, *interval, *new_object; @@ -3107,7 +3107,7 @@ PHP_METHOD(DateTimePoint, sub) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_sub(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3186,9 +3186,9 @@ PHP_FUNCTION(date_timezone_set) } /* }}} */ -/* {{{ proto DateTimePoint::setTimezone() +/* {{{ proto DateTimeImmutable::setTimezone() */ -PHP_METHOD(DateTimePoint, setTimezone) +PHP_METHOD(DateTimeImmutable, setTimezone) { zval *object, *new_object; zval *timezone_object; @@ -3197,7 +3197,7 @@ PHP_METHOD(DateTimePoint, setTimezone) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_timezone_set(new_object, timezone_object, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3269,9 +3269,9 @@ PHP_FUNCTION(date_time_set) } /* }}} */ -/* {{{ proto DateTimePoint::setTime() +/* {{{ proto DateTimeImmutable::setTime() */ -PHP_METHOD(DateTimePoint, setTime) +PHP_METHOD(DateTimeImmutable, setTime) { zval *object, *new_object; long h, i, s = 0; @@ -3280,7 +3280,7 @@ PHP_METHOD(DateTimePoint, setTime) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_time_set(new_object, h, i, s, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3317,9 +3317,9 @@ PHP_FUNCTION(date_date_set) } /* }}} */ -/* {{{ proto DateTimePoint::setDate() +/* {{{ proto DateTimeImmutable::setDate() */ -PHP_METHOD(DateTimePoint, setDate) +PHP_METHOD(DateTimeImmutable, setDate) { zval *object, *new_object; long y, m, d; @@ -3328,7 +3328,7 @@ PHP_METHOD(DateTimePoint, setDate) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_date_set(new_object, y, m, d, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3369,9 +3369,9 @@ PHP_FUNCTION(date_isodate_set) } /* }}} */ -/* {{{ proto DateTimePoint::setISODate() +/* {{{ proto DateTimeImmutable::setISODate() */ -PHP_METHOD(DateTimePoint, setISODate) +PHP_METHOD(DateTimeImmutable, setISODate) { zval *object, *new_object; long y, w, d = 1; @@ -3380,7 +3380,7 @@ PHP_METHOD(DateTimePoint, setISODate) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_isodate_set(new_object, y, w, d, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3415,9 +3415,9 @@ PHP_FUNCTION(date_timestamp_set) } /* }}} */ -/* {{{ proto DateTimePoint::setTimestamp() +/* {{{ proto DateTimeImmutable::setTimestamp() */ -PHP_METHOD(DateTimePoint, setTimestamp) +PHP_METHOD(DateTimeImmutable, setTimestamp) { zval *object, *new_object; long timestamp; @@ -3426,7 +3426,7 @@ PHP_METHOD(DateTimePoint, setTimestamp) RETURN_FALSE; } - new_object = date_clone_point(object); + new_object = date_clone_immutable(object); php_date_timestamp_set(new_object, timestamp, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); diff --git a/ext/date/php_date.h b/ext/date/php_date.h index ffe1c3c646efc..19c692b57f3aa 100644 --- a/ext/date/php_date.h +++ b/ext/date/php_date.h @@ -51,9 +51,9 @@ PHP_METHOD(DateTime, __construct); PHP_METHOD(DateTime, __wakeup); PHP_METHOD(DateTime, __set_state); PHP_FUNCTION(date_create); -PHP_FUNCTION(date_create_point); +PHP_FUNCTION(date_create_immutable); PHP_FUNCTION(date_create_from_format); -PHP_FUNCTION(date_create_point_from_format); +PHP_FUNCTION(date_create_immutable_from_format); PHP_FUNCTION(date_parse); PHP_FUNCTION(date_parse_from_format); PHP_FUNCTION(date_get_last_errors); @@ -72,16 +72,16 @@ PHP_FUNCTION(date_isodate_set); PHP_FUNCTION(date_timestamp_set); PHP_FUNCTION(date_timestamp_get); -PHP_METHOD(DateTimePoint, __construct); -PHP_METHOD(DateTimePoint, __set_state); -PHP_METHOD(DateTimePoint, modify); -PHP_METHOD(DateTimePoint, add); -PHP_METHOD(DateTimePoint, sub); -PHP_METHOD(DateTimePoint, setTimezone); -PHP_METHOD(DateTimePoint, setTime); -PHP_METHOD(DateTimePoint, setDate); -PHP_METHOD(DateTimePoint, setISODate); -PHP_METHOD(DateTimePoint, setTimestamp); +PHP_METHOD(DateTimeImmutable, __construct); +PHP_METHOD(DateTimeImmutable, __set_state); +PHP_METHOD(DateTimeImmutable, modify); +PHP_METHOD(DateTimeImmutable, add); +PHP_METHOD(DateTimeImmutable, sub); +PHP_METHOD(DateTimeImmutable, setTimezone); +PHP_METHOD(DateTimeImmutable, setTime); +PHP_METHOD(DateTimeImmutable, setDate); +PHP_METHOD(DateTimeImmutable, setISODate); +PHP_METHOD(DateTimeImmutable, setTimestamp); PHP_METHOD(DateTimeZone, __construct); PHP_FUNCTION(timezone_open); diff --git a/ext/date/tests/date_time_point-inherited.phpt b/ext/date/tests/date_time_immutable-inherited.phpt similarity index 77% rename from ext/date/tests/date_time_point-inherited.phpt rename to ext/date/tests/date_time_immutable-inherited.phpt index e35540753c1ae..ad8b7edb84f7f 100644 --- a/ext/date/tests/date_time_point-inherited.phpt +++ b/ext/date/tests/date_time_immutable-inherited.phpt @@ -1,5 +1,5 @@ --TEST-- -Tests for DateTimePoint. +Tests for DateTimeImmutable. --INI-- date.timezone=Europe/London --FILE-- @@ -8,12 +8,12 @@ $tz = new DateTimeZone("Asia/Tokyo"); $current = "2012-12-27 16:24:08"; echo "\ngetTimezone():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $x = $v->getTimezone(); var_dump($x->getName()); echo "\ngetTimestamp():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $x = $v->getTimestamp(); var_dump($x); ?> diff --git a/ext/date/tests/date_time_point.phpt b/ext/date/tests/date_time_immutable.phpt similarity index 91% rename from ext/date/tests/date_time_point.phpt rename to ext/date/tests/date_time_immutable.phpt index 810eeca184bcc..b4a576570e225 100644 --- a/ext/date/tests/date_time_point.phpt +++ b/ext/date/tests/date_time_immutable.phpt @@ -1,5 +1,5 @@ --TEST-- -Tests for DateTimePoint. +Tests for DateTimeImmutable. --INI-- date.timezone=Europe/London --FILE-- @@ -15,7 +15,7 @@ function dump($a, $b, $c) } echo "modify():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->modify("+2 days"); dump($v, $z, $x); @@ -25,7 +25,7 @@ $x = $z->modify("+2 days"); dump($v, $z, $x); echo "\nadd():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->add(new DateInterval("P2DT2S")); dump($v, $z, $x); @@ -35,7 +35,7 @@ $x = $z->add(new DateInterval("P2DT2S")); dump($v, $z, $x); echo "\nsub():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->sub(new DateInterval("P2DT2S")); dump($v, $z, $x); @@ -45,7 +45,7 @@ $x = $z->sub(new DateInterval("P2DT2S")); dump($v, $z, $x); echo "\nsetTimezone():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->setTimezone($tz); dump($v, $z, $x); @@ -53,13 +53,13 @@ $v = date_create($current); $z = $v; $x = $z->setTimezone($tz); dump($v, $z, $x); -$v = new DateTimePoint($current); +$v = new DateTimeImmutable($current); $z = $v; $x = $z->setTimezone($tz); dump($v, $z, $x); echo "\nsetTime():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->setTime(5, 7, 19); dump($v, $z, $x); @@ -69,7 +69,7 @@ $x = $z->setTime(5, 7, 19); dump($v, $z, $x); echo "\nsetDate():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->setDate(5, 7, 19); dump($v, $z, $x); @@ -79,7 +79,7 @@ $x = $z->setDate(5, 7, 19); dump($v, $z, $x); echo "\nsetIsoDate():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->setIsoDate(2012, 2, 6); dump($v, $z, $x); @@ -89,7 +89,7 @@ $x = $z->setIsoDate(2012, 2, 6); dump($v, $z, $x); echo "\nsetTimestamp():\n"; -$v = date_create_point($current); +$v = date_create_immutable($current); $z = $v; $x = $z->setTimestamp(2012234222); dump($v, $z, $x); From a0618139c9f7aa7859f338a485af161f672be9cd Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Wed, 19 Dec 2012 17:40:14 +0000 Subject: [PATCH 2270/2394] Fixed crash bug when the non-OO interface was used. --- ext/date/php_date.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 596a7a94d9d0c..fc281ce0861d9 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2954,7 +2954,7 @@ PHP_FUNCTION(date_modify) php_date_modify(object, modify, modify_len, return_value TSRMLS_CC); - RETURN_ZVAL(getThis(), 1, 0); + RETURN_ZVAL(object, 1, 0); } /* }}} */ From c20911a8501ed2a69c6ce9359e8e50d599f99bba Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Thu, 20 Dec 2012 13:22:18 +0000 Subject: [PATCH 2271/2394] Make DatePeriod support DateTimeImmutable as well. If the start element is a DateTimeImmutable object, then all returned objects are also DateTimeImmutable objects. If the start element is a DateTime object, then all returned objects are DateTime objects. --- ext/date/php_date.c | 4 +- ext/date/php_date.h | 1 + ext/date/tests/date_period-immutable.phpt | 56 +++++++++++++++++++++++ 3 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 ext/date/tests/date_period-immutable.phpt diff --git a/ext/date/php_date.c b/ext/date/php_date.c index fc281ce0861d9..cc83130e1cf40 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -1847,7 +1847,7 @@ static void date_period_it_current_data(zend_object_iterator *iter, zval ***data /* Create new object */ MAKE_STD_ZVAL(iterator->current); - php_date_instantiate(date_ce_date, iterator->current TSRMLS_CC); + php_date_instantiate(object->start_ce, iterator->current TSRMLS_CC); newdateobj = (php_date_obj *) zend_object_store_get_object(iterator->current TSRMLS_CC); newdateobj->time = timelib_time_ctor(); *newdateobj->time = *it_time; @@ -4182,6 +4182,7 @@ PHP_METHOD(DatePeriod, __construct) if (dpobj->end) { timelib_update_ts(dpobj->end, NULL); } + dpobj->start_ce = date_ce_date; } else { /* init */ intobj = (php_interval_obj *) zend_object_store_get_object(interval TSRMLS_CC); @@ -4197,6 +4198,7 @@ PHP_METHOD(DatePeriod, __construct) clone->tz_info = dateobj->time->tz_info; } dpobj->start = clone; + dpobj->start_ce = Z_OBJCE_P(start); /* interval */ dpobj->interval = timelib_rel_time_clone(intobj->diff); diff --git a/ext/date/php_date.h b/ext/date/php_date.h index 19c692b57f3aa..3af3fa42ede90 100644 --- a/ext/date/php_date.h +++ b/ext/date/php_date.h @@ -154,6 +154,7 @@ struct _php_interval_obj { struct _php_period_obj { zend_object std; timelib_time *start; + zend_class_entry *start_ce; timelib_time *current; timelib_time *end; timelib_rel_time *interval; diff --git a/ext/date/tests/date_period-immutable.phpt b/ext/date/tests/date_period-immutable.phpt new file mode 100644 index 0000000000000..0ec4b4a13025b --- /dev/null +++ b/ext/date/tests/date_period-immutable.phpt @@ -0,0 +1,56 @@ +--TEST-- +DatePeriod +--FILE-- +format( "l Y-m-d\n" ); + echo $dt->modify( "3 tuesday" )->format( "l Y-m-d\n" ); + echo $dt->format( "l Y-m-d\n\n" ); +} + +foreach ( new DatePeriod( $db2, $di, $de ) as $dt ) +{ + echo get_class( $dt ), "\n"; + echo $dt->format( "l Y-m-d\n" ); + echo $dt->modify( "3 tuesday" )->format( "l Y-m-d\n" ); + echo $dt->format( "l Y-m-d\n\n" ); +} +?> +--EXPECT-- +DateTimeImmutable +Tuesday 2008-01-01 +Tuesday 2008-01-15 +Tuesday 2008-01-01 + +DateTimeImmutable +Friday 2008-02-01 +Tuesday 2008-02-19 +Friday 2008-02-01 + +DateTimeImmutable +Saturday 2008-03-01 +Tuesday 2008-03-18 +Saturday 2008-03-01 + +DateTime +Tuesday 2008-01-01 +Tuesday 2008-01-15 +Tuesday 2008-01-15 + +DateTime +Friday 2008-02-01 +Tuesday 2008-02-19 +Tuesday 2008-02-19 + +DateTime +Saturday 2008-03-01 +Tuesday 2008-03-18 +Tuesday 2008-03-18 From 6313fc7e10d4234cc1e80f223c0652240cad4fda Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Mon, 14 Jan 2013 20:36:48 +0000 Subject: [PATCH 2272/2394] Added NEWS item for DateTimeImmutable --- NEWS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/NEWS b/NEWS index 74c1134d7c757..9e8cd8502b12e 100644 --- a/NEWS +++ b/NEWS @@ -25,6 +25,10 @@ PHP NEWS CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE, CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick) +- DateTime + . Added DateTimeImmutable - a variant of DateTime that only returns the + modified state instead of changing itself. (Derick) + - pgsql: . Bug #46408: Locale number format settings can cause pg_query_params to break with numerics. (asmecher, Lars) From be1700d467a6875415c292f95040965fb359493c Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Tue, 15 Jan 2013 10:08:26 +0800 Subject: [PATCH 2273/2394] Fix compile failure introduced by the fix for bug #46408. --- Zend/zend_operators.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index 274893c70ae79..c8b868d16a809 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -584,7 +584,7 @@ ZEND_API void _convert_to_cstring(zval *op ZEND_FILE_LINE_DC) /* {{{ */ break; } default: - return _convert_to_string(op); + _convert_to_string(op ZEND_FILE_LINE_CC); } Z_TYPE_P(op) = IS_STRING; } From 643e7a54ec8e06a0fc9996eea9d0125f4fa531a5 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 15 Jan 2013 00:06:35 -0800 Subject: [PATCH 2274/2394] fix NEWS --- NEWS | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 79d5d9aee5baa..5f45667576196 100644 --- a/NEWS +++ b/NEWS @@ -7,9 +7,18 @@ PHP NEWS protected property). (Stas) . Fixed bug #63943 (Bad warning text from strpos() on empty needle). (Laruence) + . Fixed bug #63899 (Use after scope error in zend_compile). (Laruence) . Fixed bug #63882 (zend_std_compare_objects crash on recursion). (Dmitry) + . Fixed bug #43225 (fputcsv incorrectly handles cells ending in \ followed + by "). (Adam) . Support BITMAPV5HEADER in getimagesize(). (AsamK, Lars) +- Date: + . Fixed bug #63699 (Performance improvements for various ext/date functions). + (Lars, original patch by njaguar at gmail dot com) + . Fixed bug #55397: Comparsion of incomplete DateTime causes SIGSEGV. + (Derick) + - Litespeed: . Fixed bug #63228 (-Werror=format-security error in lsapi code). (George) @@ -27,7 +36,6 @@ PHP NEWS ?? ??? 2012, PHP 5.4.11 - Core: - . Fixed bug #63899 (Use after scope error in zend_compile). (Laruence) . Fixed bug #63762 (Sigsegv when Exception::$trace is changed by user). (Johannes) . Fixed bug #43177 (Errors in eval()'ed code produce status code 500). @@ -56,10 +64,6 @@ PHP NEWS . Fixed bug #55438 (Curlwapper is not sending http header randomly). (phpnet@lostreality.org, Pierrick) -- Date: - . Fixed bug #63699 (Performance improvements for various ext/date functions). - (Lars, original patch by njaguar at gmail dot com) - 20 Dec 2012, PHP 5.4.10 - Core: From eb40f73ca0a2a7563fbc95cc22741412e0beb76e Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Tue, 15 Jan 2013 09:30:44 +0100 Subject: [PATCH 2275/2394] Bug #62489: dba_insert not working as expected --- NEWS | 6 +++++- ext/dba/dba_flatfile.c | 19 ++++++++++--------- ext/dba/dba_gdbm.c | 17 ++++++++++++----- ext/dba/dba_inifile.c | 1 - ext/dba/dba_qdbm.c | 10 ++++++---- ext/dba/tests/dba_db1.phpt | 4 ++++ ext/dba/tests/dba_db2.phpt | 4 ++++ ext/dba/tests/dba_db3.phpt | 4 ++++ ext/dba/tests/dba_db4_000.phpt | 4 ++++ ext/dba/tests/dba_dbm.phpt | 4 ++++ ext/dba/tests/dba_flatfile.phpt | 4 ++++ ext/dba/tests/dba_gdbm.phpt | 2 ++ ext/dba/tests/dba_handler.inc | 12 ++++++++++-- ext/dba/tests/dba_inifile.phpt | 4 ++++ ext/dba/tests/dba_ndbm.phpt | 4 ++++ ext/dba/tests/dba_qdbm.phpt | 2 ++ ext/dba/tests/dba_tcadb.phpt | 4 ++++ 17 files changed, 83 insertions(+), 22 deletions(-) diff --git a/NEWS b/NEWS index 9e8cd8502b12e..4145dc54ee933 100644 --- a/NEWS +++ b/NEWS @@ -27,12 +27,16 @@ PHP NEWS - DateTime . Added DateTimeImmutable - a variant of DateTime that only returns the - modified state instead of changing itself. (Derick) + modified state instead of changing itself. (Derick) - pgsql: . Bug #46408: Locale number format settings can cause pg_query_params to break with numerics. (asmecher, Lars) +- dba: + . Bug #62489: dba_insert not working as expected. + (marc-bennewitz at arcor dot de, Lars) + 18 Dec 2012, PHP 5.5.0 Alpha 2 - General improvements: diff --git a/ext/dba/dba_flatfile.c b/ext/dba/dba_flatfile.c index 082aa5cdb6c9b..34aa635a5430c 100644 --- a/ext/dba/dba_flatfile.c +++ b/ext/dba/dba_flatfile.c @@ -88,15 +88,16 @@ DBA_UPDATE_FUNC(flatfile) gval.dsize = vallen; switch(flatfile_store(dba, gkey, gval, mode==1 ? FLATFILE_INSERT : FLATFILE_REPLACE TSRMLS_CC)) { - case -1: - php_error_docref1(NULL TSRMLS_CC, key, E_WARNING, "Operation not possible"); - return FAILURE; - default: - case 0: - return SUCCESS; - case 1: - php_error_docref1(NULL TSRMLS_CC, key, E_WARNING, "Key already exists"); - return FAILURE; + case 0: + return SUCCESS; + case 1: + return FAILURE; + case -1: + php_error_docref1(NULL TSRMLS_CC, key, E_WARNING, "Operation not possible"); + return FAILURE; + default: + php_error_docref2(NULL TSRMLS_CC, key, val, E_WARNING, "Unknown return value"); + return FAILURE; } } diff --git a/ext/dba/dba_gdbm.c b/ext/dba/dba_gdbm.c index 7534568d39c2d..47dd576496633 100644 --- a/ext/dba/dba_gdbm.c +++ b/ext/dba/dba_gdbm.c @@ -104,11 +104,18 @@ DBA_UPDATE_FUNC(gdbm) gval.dptr = (char *) val; gval.dsize = vallen; - if(gdbm_store(dba->dbf, gkey, gval, - mode == 1 ? GDBM_INSERT : GDBM_REPLACE) == 0) - return SUCCESS; - php_error_docref2(NULL TSRMLS_CC, key, val, E_WARNING, "%s", gdbm_strerror(gdbm_errno)); - return FAILURE; + switch (gdbm_store(dba->dbf, gkey, gval, mode == 1 ? GDBM_INSERT : GDBM_REPLACE)) { + case 0: + return SUCCESS; + case 1: + return FAILURE; + case -1: + php_error_docref2(NULL TSRMLS_CC, key, val, E_WARNING, "%s", gdbm_strerror(gdbm_errno)); + return FAILURE; + default: + php_error_docref2(NULL TSRMLS_CC, key, val, E_WARNING, "Unknown return value"); + return FAILURE; + } } DBA_EXISTS_FUNC(gdbm) diff --git a/ext/dba/dba_inifile.c b/ext/dba/dba_inifile.c index e1359b65e984d..05ee95c0ecbce 100644 --- a/ext/dba/dba_inifile.c +++ b/ext/dba/dba_inifile.c @@ -101,7 +101,6 @@ DBA_UPDATE_FUNC(inifile) case 0: return SUCCESS; case 1: - php_error_docref1(NULL TSRMLS_CC, key, E_WARNING, "Key already exists"); return FAILURE; } } diff --git a/ext/dba/dba_qdbm.c b/ext/dba/dba_qdbm.c index 485b1997e6219..eeece57011d66 100644 --- a/ext/dba/dba_qdbm.c +++ b/ext/dba/dba_qdbm.c @@ -96,13 +96,15 @@ DBA_FETCH_FUNC(qdbm) DBA_UPDATE_FUNC(qdbm) { QDBM_DATA; - int result; - result = dpput(dba->dbf, key, keylen, val, vallen, mode == 1 ? DP_DKEEP : DP_DOVER); - if (result) + if (dpput(dba->dbf, key, keylen, val, vallen, mode == 1 ? DP_DKEEP : DP_DOVER)) { return SUCCESS; + } + + if (dpecode != DP_EKEEP) { + php_error_docref2(NULL TSRMLS_CC, key, val, E_WARNING, "%s", dperrmsg(dpecode)); + } - php_error_docref2(NULL TSRMLS_CC, key, val, E_WARNING, "%s", dperrmsg(dpecode)); return FAILURE; } diff --git a/ext/dba/tests/dba_db1.phpt b/ext/dba/tests/dba_db1.phpt index a24600350f551..d0e530e026f1b 100644 --- a/ext/dba/tests/dba_db1.phpt +++ b/ext/dba/tests/dba_db1.phpt @@ -18,6 +18,8 @@ database handler: db1 Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -33,6 +35,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_db2.phpt b/ext/dba/tests/dba_db2.phpt index 89d8a926e125a..1cfbb3e340c2e 100644 --- a/ext/dba/tests/dba_db2.phpt +++ b/ext/dba/tests/dba_db2.phpt @@ -18,6 +18,8 @@ database handler: db2 Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -33,6 +35,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_db3.phpt b/ext/dba/tests/dba_db3.phpt index 257c88217524e..5de7e5a0417ba 100644 --- a/ext/dba/tests/dba_db3.phpt +++ b/ext/dba/tests/dba_db3.phpt @@ -18,6 +18,8 @@ database handler: db3 Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -33,6 +35,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_db4_000.phpt b/ext/dba/tests/dba_db4_000.phpt index bbbc52c9f18c1..17db4bb62dfa8 100644 --- a/ext/dba/tests/dba_db4_000.phpt +++ b/ext/dba/tests/dba_db4_000.phpt @@ -22,6 +22,8 @@ database handler: db4 Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -37,6 +39,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_dbm.phpt b/ext/dba/tests/dba_dbm.phpt index dd1fe1e31cdab..8bea8463da76c 100644 --- a/ext/dba/tests/dba_dbm.phpt +++ b/ext/dba/tests/dba_dbm.phpt @@ -18,6 +18,8 @@ database handler: dbm Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -33,6 +35,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_flatfile.phpt b/ext/dba/tests/dba_flatfile.phpt index 8e1ca6a93340e..ac7f86ebdaafb 100644 --- a/ext/dba/tests/dba_flatfile.phpt +++ b/ext/dba/tests/dba_flatfile.phpt @@ -22,6 +22,8 @@ database handler: flatfile Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -37,6 +39,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_gdbm.phpt b/ext/dba/tests/dba_gdbm.phpt index 33d7d206159ac..e68e8b7409024 100644 --- a/ext/dba/tests/dba_gdbm.phpt +++ b/ext/dba/tests/dba_gdbm.phpt @@ -21,6 +21,8 @@ database handler: gdbm Content String 2 Content 2 replaced Read during write:%sallowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_handler.inc b/ext/dba/tests/dba_handler.inc index 1c3f5127ef384..a950e903af426 100644 --- a/ext/dba/tests/dba_handler.inc +++ b/ext/dba/tests/dba_handler.inc @@ -46,8 +46,16 @@ do { echo "Read during write: allowed\n"; } if ($db_writer!==FALSE) { - dba_insert("key number 6", "The 6th value", $db_writer); - @dba_insert("key number 6", "The 6th value inserted again would be an error", $db_writer); + if (dba_insert("key number 6", "The 6th value", $db_writer)) { + echo '"key number 6" written' . "\n"; + } else { + echo 'Failed to write "key number 6"' . "\n"; + } + if (dba_insert("key number 6", "The 6th value inserted again would be an error", $db_writer)) { + echo '"key number 6" written 2nd time' . "\n"; + } else { + echo 'Failed to write "key number 6" 2nd time' . "\n"; + } dba_replace("key2", "Content 2 replaced 2nd time", $db_writer); dba_delete("key4", $db_writer); echo dba_fetch("key2", $db_writer)."\n"; diff --git a/ext/dba/tests/dba_inifile.phpt b/ext/dba/tests/dba_inifile.phpt index 81ab738796315..5975d25f4dc54 100644 --- a/ext/dba/tests/dba_inifile.phpt +++ b/ext/dba/tests/dba_inifile.phpt @@ -18,6 +18,8 @@ database handler: inifile Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -33,6 +35,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_ndbm.phpt b/ext/dba/tests/dba_ndbm.phpt index b0f5542de4969..193db6f94d748 100644 --- a/ext/dba/tests/dba_ndbm.phpt +++ b/ext/dba/tests/dba_ndbm.phpt @@ -18,6 +18,8 @@ database handler: ndbm Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -33,6 +35,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_qdbm.phpt b/ext/dba/tests/dba_qdbm.phpt index ef216d9258bc4..e2205baa267dd 100644 --- a/ext/dba/tests/dba_qdbm.phpt +++ b/ext/dba/tests/dba_qdbm.phpt @@ -19,6 +19,8 @@ database handler: qdbm Content String 2 Content 2 replaced Read during write:%sallowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { diff --git a/ext/dba/tests/dba_tcadb.phpt b/ext/dba/tests/dba_tcadb.phpt index 52dd4de3361fe..28b6dd8f0b5a0 100644 --- a/ext/dba/tests/dba_tcadb.phpt +++ b/ext/dba/tests/dba_tcadb.phpt @@ -22,6 +22,8 @@ database handler: tcadb Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { @@ -37,6 +39,8 @@ array(3) { Content String 2 Content 2 replaced Read during write: not allowed +"key number 6" written +Failed to write "key number 6" 2nd time Content 2 replaced 2nd time The 6th value array(3) { From 1ff43522630f0f98c20e884890f77e6593a43f3b Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 15 Jan 2013 10:04:59 +0100 Subject: [PATCH 2276/2394] Add support for connect attributes, as of MySQL 5.6 --- ext/mysqlnd/mysqlnd.c | 93 ++++++++++++++++++++++++++- ext/mysqlnd/mysqlnd.h | 1 + ext/mysqlnd/mysqlnd_auth.c | 5 +- ext/mysqlnd/mysqlnd_enum_n_def.h | 3 + ext/mysqlnd/mysqlnd_libmysql_compat.h | 3 +- ext/mysqlnd/mysqlnd_structs.h | 6 +- ext/mysqlnd/mysqlnd_wireprotocol.c | 66 ++++++++++++++++++- ext/mysqlnd/mysqlnd_wireprotocol.h | 2 +- 8 files changed, 171 insertions(+), 8 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index ebc4a774a6578..1023b3e5f449d 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -95,6 +95,11 @@ MYSQLND_METHOD(mysqlnd_conn_data, free_options)(MYSQLND_CONN_DATA * conn TSRMLS_ mnd_pefree(conn->options->cfg_section, pers); conn->options->cfg_section = NULL; } + if (conn->options->connect_attr) { + zend_hash_destroy(conn->options->connect_attr); + mnd_pefree(conn->options->connect_attr, pers); + conn->options->connect_attr = NULL; + } } /* }}} */ @@ -797,13 +802,14 @@ MYSQLND_METHOD(mysqlnd_conn_data, connect_handshake)(MYSQLND_CONN_DATA * conn, goto err; } + conn->client_flag = mysql_flags; + conn->server_capabilities = greet_packet->server_capabilities; + if (FAIL == mysqlnd_connect_run_authentication(conn, user, passwd, db, db_len, (size_t) passwd_len, greet_packet, conn->options, mysql_flags TSRMLS_CC)) { goto err; } - conn->client_flag = mysql_flags; - conn->server_capabilities = greet_packet->server_capabilities; conn->upsert_status->warning_count = 0; conn->upsert_status->server_status = greet_packet->server_status; conn->upsert_status->affected_rows = 0; @@ -811,6 +817,8 @@ MYSQLND_METHOD(mysqlnd_conn_data, connect_handshake)(MYSQLND_CONN_DATA * conn, PACKET_FREE(greet_packet); DBG_RETURN(PASS); err: + conn->client_flag = 0; + conn->server_capabilities = 0; PACKET_FREE(greet_packet); DBG_RETURN(FAIL); } @@ -1086,6 +1094,7 @@ MYSQLND_METHOD(mysqlnd_conn, connect)(MYSQLND * conn_handle, DBG_ENTER("mysqlnd_conn::connect"); if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { + mysqlnd_options4(conn_handle, MYSQL_OPT_CONNECT_ATTR_ADD, "_client_name", "mysqlnd"); ret = conn->m->connect(conn, host, user, passwd, passwd_len, db, db_len, port, socket_or_pipe, mysql_flags TSRMLS_CC); conn->m->local_tx_end(conn, this_func, FAIL TSRMLS_CC); @@ -2375,6 +2384,19 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c conn->options->flags &= ~CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS; } break; + case MYSQL_OPT_CONNECT_ATTR_RESET: + if (conn->options->connect_attr) { + DBG_INF_FMT("Before reset %d attribute(s)", zend_hash_num_elements(conn->options->connect_attr)); + zend_hash_clean(conn->options->connect_attr); + } + break; + case MYSQL_OPT_CONNECT_ATTR_DELETE: + if (conn->options->connect_attr && value) { + DBG_INF_FMT("Before delete %d attribute(s)", zend_hash_num_elements(conn->options->connect_attr)); + zend_hash_del(conn->options->connect_attr, value, strlen(value)); + DBG_INF_FMT("%d left", zend_hash_num_elements(conn->options->connect_attr)); + } + break; #ifdef WHEN_SUPPORTED_BY_MYSQLI case MYSQL_SHARED_MEMORY_BASE_NAME: case MYSQL_OPT_USE_RESULT: @@ -2395,6 +2417,69 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c /* }}} */ +/* {{{ connect_attr_item_dtor */ +static void +connect_attr_item_dtor(void * pDest) +{ +#ifdef ZTS + TSRMLS_FETCH(); +#endif + DBG_ENTER("connect_attr_item_dtor"); + mnd_pefree(*(char **) pDest, 1); + DBG_VOID_RETURN; +} +/* }}} */ + + +/* {{{ mysqlnd_conn_data::set_client_option_2d */ +static enum_func_status +MYSQLND_METHOD(mysqlnd_conn_data, set_client_option_2d)(MYSQLND_CONN_DATA * const conn, + enum mysqlnd_option option, + const char * const key, + const char * const value + TSRMLS_DC) +{ + size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, set_client_option_2d); + enum_func_status ret = PASS; + DBG_ENTER("mysqlnd_conn_data::set_client_option_2d"); + DBG_INF_FMT("conn=%llu option=%u", conn->thread_id, option); + + if (PASS != conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { + goto end; + } + switch (option) { + case MYSQL_OPT_CONNECT_ATTR_ADD: + if (!conn->options->connect_attr) { + DBG_INF("Initializing connect_attr hash"); + conn->options->connect_attr = mnd_pemalloc(sizeof(HashTable), conn->persistent); + if (!conn->options->connect_attr) { + goto oom; + } + zend_hash_init(conn->options->connect_attr, 0, NULL, NULL, conn->persistent); + } + DBG_INF_FMT("Adding [%s][%s]", key, value); + { + const char * copyv = mnd_pestrdup(value, 1); + if (!copyv) { + goto oom; + } + zend_hash_update(conn->options->connect_attr, key, strlen(key), ©v, sizeof(char *), NULL); + } + break; + default: + ret = FAIL; + } + conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC); + DBG_RETURN(ret); +oom: + SET_OOM_ERROR(*conn->error_info); + conn->m->local_tx_end(conn, this_func, FAIL TSRMLS_CC); +end: + DBG_RETURN(FAIL); +} +/* }}} */ + + /* {{{ mysqlnd_conn_data::use_result */ static MYSQLND_RES * MYSQLND_METHOD(mysqlnd_conn_data, use_result)(MYSQLND_CONN_DATA * const conn TSRMLS_DC) @@ -2662,7 +2747,9 @@ MYSQLND_CLASS_METHODS_START(mysqlnd_conn_data) MYSQLND_METHOD(mysqlnd_conn_data, get_updated_connect_flags), MYSQLND_METHOD(mysqlnd_conn_data, connect_handshake), MYSQLND_METHOD(mysqlnd_conn_data, simple_command_send_request), - MYSQLND_METHOD(mysqlnd_conn_data, fetch_auth_plugin_by_name) + MYSQLND_METHOD(mysqlnd_conn_data, fetch_auth_plugin_by_name), + + MYSQLND_METHOD(mysqlnd_conn_data, set_client_option_2d) MYSQLND_CLASS_METHODS_END; diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index 7e02126f3b72e..bf0f70b405c26 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -207,6 +207,7 @@ PHPAPI void mysqlnd_set_local_infile_handler(MYSQLND_CONN_DATA * const conn, con #define mysqlnd_set_character_set(conn, cs) ((conn)->data)->m->set_charset((conn)->data, (cs) TSRMLS_CC) #define mysqlnd_stat(conn, msg, msg_len) ((conn)->data)->m->get_server_statistics(((conn)->data), (msg), (msg_len) TSRMLS_CC) #define mysqlnd_options(conn, opt, value) ((conn)->data)->m->set_client_option((conn)->data, (opt), (value) TSRMLS_CC) +#define mysqlnd_options4(conn, opt, k, v) ((conn)->data)->m->set_client_option_2d((conn)->data, (opt), (k), (v) TSRMLS_CC) #define mysqlnd_set_server_option(conn, op) ((conn)->data)->m->set_server_option((conn)->data, (op) TSRMLS_CC) /* Escaping */ diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c index a3b4f36a2e2a3..8611d998647fa 100644 --- a/ext/mysqlnd/mysqlnd_auth.c +++ b/ext/mysqlnd/mysqlnd_auth.c @@ -28,7 +28,6 @@ #include "mysqlnd_charset.h" #include "mysqlnd_debug.h" - /* {{{ mysqlnd_auth_handshake */ enum_func_status mysqlnd_auth_handshake(MYSQLND_CONN_DATA * conn, @@ -99,6 +98,10 @@ mysqlnd_auth_handshake(MYSQLND_CONN_DATA * conn, auth_packet->auth_data = auth_plugin_data; auth_packet->auth_data_len = auth_plugin_data_len; auth_packet->auth_plugin_name = auth_protocol; + + if (conn->server_capabilities & CLIENT_CONNECT_ATTRS) { + auth_packet->connect_attr = conn->options->connect_attr; + } if (!PACKET_WRITE(auth_packet, conn)) { goto end; diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h index abaaf1f43e30e..cf5b02728badf 100644 --- a/ext/mysqlnd/mysqlnd_enum_n_def.h +++ b/ext/mysqlnd/mysqlnd_enum_n_def.h @@ -168,6 +168,9 @@ typedef enum mysqlnd_option MYSQL_OPT_SSL_VERIFY_SERVER_CERT, MYSQL_PLUGIN_DIR, MYSQL_DEFAULT_AUTH, + MYSQL_OPT_CONNECT_ATTR_RESET, + MYSQL_OPT_CONNECT_ATTR_ADD, + MYSQL_OPT_CONNECT_ATTR_DELETE, MYSQL_SERVER_PUBLIC_KEY, MYSQL_ENABLE_CLEARTEXT_PLUGIN, MYSQL_OPT_CAN_HANDLE_EXPIRED_PASSWORDS, diff --git a/ext/mysqlnd/mysqlnd_libmysql_compat.h b/ext/mysqlnd/mysqlnd_libmysql_compat.h index c967fb3a9f037..e3ab9eefa99c5 100644 --- a/ext/mysqlnd/mysqlnd_libmysql_compat.h +++ b/ext/mysqlnd/mysqlnd_libmysql_compat.h @@ -106,7 +106,8 @@ #define mysql_stmt_more_results(s) mysqlnd_stmt_more_results((s)) #define mysql_thread_safe() mysqlnd_thread_safe() #define mysql_info(r) mysqlnd_info((r)) -#define mysql_options(r,a,b) mysqlnd_options((r), (a), (b)) +#define mysql_options(c,a,v) mysqlnd_options((c), (a), (v)) +#define mysql_options4(c,a,k,v) mysqlnd_options4((c), (a), (k), (v)) #define mysql_stmt_init(r) mysqlnd_stmt_init((r)) #define mysql_free_result(r) mysqlnd_free_result((r), FALSE) #define mysql_store_result(r) mysqlnd_store_result((r)) diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 6302c81c6aecf..ecb1d89216965 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -172,7 +172,7 @@ typedef struct st_mysqlnd_options The ABI will be broken and the methods structure will be somewhere else in the memory which can crash external code. Feel free to reuse these. */ - char * unused2; + HashTable * connect_attr; char * unused3; char * unused4; char * unused5; @@ -489,6 +489,8 @@ typedef enum_func_status (*func_mysqlnd_conn_data__connect_handshake)(MYSQLND_CO typedef enum_func_status (*func_mysqlnd_conn_data__simple_command_send_request)(MYSQLND_CONN_DATA * conn, enum php_mysqlnd_server_command command, const zend_uchar * const arg, size_t arg_len, zend_bool silent, zend_bool ignore_upsert_status TSRMLS_DC); typedef struct st_mysqlnd_authentication_plugin * (*func_mysqlnd_conn_data__fetch_auth_plugin_by_name)(const char * const requested_protocol TSRMLS_DC); +typedef enum_func_status (*func_mysqlnd_conn_data__set_client_option_2d)(MYSQLND_CONN_DATA * const conn, enum mysqlnd_option option, const char * const key, const char * const value TSRMLS_DC); + struct st_mysqlnd_conn_data_methods { func_mysqlnd_conn_data__init init; @@ -573,6 +575,8 @@ struct st_mysqlnd_conn_data_methods func_mysqlnd_conn_data__connect_handshake connect_handshake; func_mysqlnd_conn_data__simple_command_send_request simple_command_send_request; func_mysqlnd_conn_data__fetch_auth_plugin_by_name fetch_auth_plugin_by_name; + + func_mysqlnd_conn_data__set_client_option_2d set_client_option_2d; }; diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c index 7c3bf1395fe17..669970789bac5 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.c +++ b/ext/mysqlnd/mysqlnd_wireprotocol.c @@ -212,6 +212,24 @@ php_mysqlnd_net_store_length(zend_uchar *packet, uint64_t length) /* }}} */ +/* {{{ php_mysqlnd_net_store_length_size */ +size_t +php_mysqlnd_net_store_length_size(uint64_t length) +{ + if (length < (uint64_t) L64(251)) { + return 1; + } + if (length < (uint64_t) L64(65536)) { + return 3; + } + if (length < (uint64_t) L64(16777216)) { + return 4; + } + return 8; +} +/* }}} */ + + /* {{{ php_mysqlnd_read_error_from_line */ static enum_func_status php_mysqlnd_read_error_from_line(zend_uchar *buf, size_t buf_len, @@ -459,7 +477,7 @@ void php_mysqlnd_greet_free_mem(void * _packet, zend_bool stack_allocation TSRML /* }}} */ -#define AUTH_WRITE_BUFFER_LEN (MYSQLND_HEADER_SIZE + MYSQLND_MAX_ALLOWED_USER_LEN + SCRAMBLE_LENGTH + MYSQLND_MAX_ALLOWED_DB_LEN + 1 + 1024) +#define AUTH_WRITE_BUFFER_LEN (MYSQLND_HEADER_SIZE + MYSQLND_MAX_ALLOWED_USER_LEN + SCRAMBLE_LENGTH + MYSQLND_MAX_ALLOWED_DB_LEN + 1 + 4096) /* {{{ php_mysqlnd_auth_write */ static @@ -540,6 +558,52 @@ size_t php_mysqlnd_auth_write(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC p+= len; *p++= '\0'; } + + if (packet->connect_attr && zend_hash_num_elements(packet->connect_attr)) { + HashPosition pos_value; + const char ** entry_value; + size_t ca_payload_len = 0; + zend_hash_internal_pointer_reset_ex(packet->connect_attr, &pos_value); + while (SUCCESS == zend_hash_get_current_data_ex(packet->connect_attr, (void **)&entry_value, &pos_value)) { + char *s_key; + unsigned int s_len; + unsigned long num_key; + size_t value_len = strlen(*entry_value); + + if (HASH_KEY_IS_STRING == zend_hash_get_current_key_ex(packet->connect_attr, &s_key, &s_len, &num_key, 0, &pos_value)) { + ca_payload_len += php_mysqlnd_net_store_length_size(s_len); + ca_payload_len += s_len; + ca_payload_len += php_mysqlnd_net_store_length_size(value_len); + ca_payload_len += value_len; + } + zend_hash_move_forward_ex(conn->options->connect_attr, &pos_value); + } + + if ((sizeof(buffer) - (p - buffer)) >= (ca_payload_len + php_mysqlnd_net_store_length_size(ca_payload_len))) { + p = php_mysqlnd_net_store_length(p, ca_payload_len); + + zend_hash_internal_pointer_reset_ex(packet->connect_attr, &pos_value); + while (SUCCESS == zend_hash_get_current_data_ex(packet->connect_attr, (void **)&entry_value, &pos_value)) { + char *s_key; + unsigned int s_len; + unsigned long num_key; + size_t value_len = strlen(*entry_value); + if (HASH_KEY_IS_STRING == zend_hash_get_current_key_ex(packet->connect_attr, &s_key, &s_len, &num_key, 0, &pos_value)) { + /* copy key */ + p = php_mysqlnd_net_store_length(p, s_len); + memcpy(p, s_key, s_len); + p+= s_len; + /* copy value */ + p = php_mysqlnd_net_store_length(p, value_len); + memcpy(p, *entry_value, value_len); + p+= value_len; + } + zend_hash_move_forward_ex(conn->options->connect_attr, &pos_value); + } + } else { + /* cannot put the data - skip */ + } + } } if (packet->is_change_user_packet) { if (PASS != conn->m->simple_command(conn, COM_CHANGE_USER, buffer + MYSQLND_HEADER_SIZE, p - buffer - MYSQLND_HEADER_SIZE, diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.h b/ext/mysqlnd/mysqlnd_wireprotocol.h index e9c9024d049d5..26dd4c65aecd8 100644 --- a/ext/mysqlnd/mysqlnd_wireprotocol.h +++ b/ext/mysqlnd/mysqlnd_wireprotocol.h @@ -103,7 +103,7 @@ typedef struct st_mysqlnd_packet_auth { zend_bool send_auth_data; zend_bool is_change_user_packet; zend_bool silent; - + HashTable *connect_attr; } MYSQLND_PACKET_AUTH; /* Auth response packet */ From 232cf4a640f00932e8030b0d57541a8d5c286309 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Tue, 15 Jan 2013 17:33:54 +0800 Subject: [PATCH 2277/2394] Revert "Update fputcsv() to escape all characters equally." On second thoughts, while the behaviour _is_ broken, this isn't the right fix. This reverts commit 9b5cb0e8059b1e8bec096067491ed8d75f878938. --- ext/standard/file.c | 8 ++++++-- ext/standard/tests/file/fputcsv.phpt | 10 +++++----- ext/standard/tests/file/fputcsv_bug43225.phpt | 20 ------------------- 3 files changed, 11 insertions(+), 27 deletions(-) delete mode 100644 ext/standard/tests/file/fputcsv_bug43225.phpt diff --git a/ext/standard/file.c b/ext/standard/file.c index 574fb53f4cd1d..74577ac495de2 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -1871,16 +1871,20 @@ PHPAPI int php_fputcsv(php_stream *stream, zval *fields, char delimiter, char en FPUTCSV_FLD_CHK('\n') || FPUTCSV_FLD_CHK('\r') || FPUTCSV_FLD_CHK('\t') || - FPUTCSV_FLD_CHK('\\') || FPUTCSV_FLD_CHK(' ') ) { char *ch = Z_STRVAL(field); char *end = ch + Z_STRLEN(field); + int escaped = 0; smart_str_appendc(&csvline, enclosure); while (ch < end) { - if (*ch == enclosure) { + if (*ch == escape_char) { + escaped = 1; + } else if (!escaped && *ch == enclosure) { smart_str_appendc(&csvline, enclosure); + } else { + escaped = 0; } smart_str_appendc(&csvline, *ch); ch++; diff --git a/ext/standard/tests/file/fputcsv.phpt b/ext/standard/tests/file/fputcsv.phpt index d71f777143c40..63c41509bdd90 100644 --- a/ext/standard/tests/file/fputcsv.phpt +++ b/ext/standard/tests/file/fputcsv.phpt @@ -44,7 +44,7 @@ echo '$list = ';var_export($res);echo ";\n"; $fp = fopen($file, "r"); $res = array(); -while($l=fgetcsv($fp, 0, ',', '"', '"')) +while($l=fgetcsv($fp)) { $res[] = join(',',$l); } @@ -75,10 +75,10 @@ $list = array ( 13 => 'aaa,"""bbb """', 14 => '"aaa""aaa""","""bbb""bbb"', 15 => '"aaa""aaa""""""",bbb', - 16 => 'aaa,"""\\""bbb",ccc', - 17 => '"aaa""\\""a""","""bbb"""', - 18 => '"""\\""""","""aaa"""', - 19 => '"""\\""""""",aaa', + 16 => 'aaa,"""\\"bbb",ccc', + 17 => '"aaa""\\"a""","""bbb"""', + 18 => '"""\\"""","""aaa"""', + 19 => '"""\\"""""",aaa', ); $list = array ( 0 => 'aaa,bbb', diff --git a/ext/standard/tests/file/fputcsv_bug43225.phpt b/ext/standard/tests/file/fputcsv_bug43225.phpt deleted file mode 100644 index 1de3b5fa02323..0000000000000 --- a/ext/standard/tests/file/fputcsv_bug43225.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -fputcsv(): bug #43225 (fputcsv incorrectly handles cells ending in \ followed by ") ---FILE-- - ---EXPECT-- -"a\""",bbb From 40c1122dcc8d74b063d5b6f06d5ce52ff7b3dcc3 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Tue, 15 Jan 2013 17:37:21 +0800 Subject: [PATCH 2278/2394] Revert "Apply the fputcsv test fix to SplFileObject_fputcsv.phpt. Mea culpa." This reverts commit 0510701474e8d99b5b30139b5599e44f9b555a5a. --- ext/spl/tests/SplFileObject_fputcsv.phpt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/spl/tests/SplFileObject_fputcsv.phpt b/ext/spl/tests/SplFileObject_fputcsv.phpt index 601edab47fc01..66fdbfd1b9be5 100644 --- a/ext/spl/tests/SplFileObject_fputcsv.phpt +++ b/ext/spl/tests/SplFileObject_fputcsv.phpt @@ -42,7 +42,7 @@ echo '$list = ';var_export($res);echo ";\n"; $fp = fopen($file, "r"); $res = array(); -while($l=fgetcsv($fp, 0, ',', '"', '"')) +while($l=fgetcsv($fp)) { $res[] = join(',',$l); } @@ -76,10 +76,10 @@ $list = array ( 13 => 'aaa,"""bbb """', 14 => '"aaa""aaa""","""bbb""bbb"', 15 => '"aaa""aaa""""""",bbb', - 16 => 'aaa,"""\\""bbb",ccc', - 17 => '"aaa""\\""a""","""bbb"""', - 18 => '"""\\""""","""aaa"""', - 19 => '"""\\""""""",aaa', + 16 => 'aaa,"""\\"bbb",ccc', + 17 => '"aaa""\\"a""","""bbb"""', + 18 => '"""\\"""","""aaa"""', + 19 => '"""\\"""""",aaa', ); $list = array ( 0 => 'aaa,bbb', From cab290d2adbd616a18b9efaace6abe629f827190 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Tue, 15 Jan 2013 17:33:54 +0800 Subject: [PATCH 2279/2394] Revert "Update fputcsv() to escape all characters equally." On second thoughts, while the behaviour _is_ broken, this isn't the right fix. This reverts commit 9b5cb0e8059b1e8bec096067491ed8d75f878938. --- ext/standard/file.c | 8 ++++++-- ext/standard/tests/file/fputcsv.phpt | 10 +++++----- ext/standard/tests/file/fputcsv_bug43225.phpt | 20 ------------------- 3 files changed, 11 insertions(+), 27 deletions(-) delete mode 100644 ext/standard/tests/file/fputcsv_bug43225.phpt diff --git a/ext/standard/file.c b/ext/standard/file.c index 574fb53f4cd1d..74577ac495de2 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -1871,16 +1871,20 @@ PHPAPI int php_fputcsv(php_stream *stream, zval *fields, char delimiter, char en FPUTCSV_FLD_CHK('\n') || FPUTCSV_FLD_CHK('\r') || FPUTCSV_FLD_CHK('\t') || - FPUTCSV_FLD_CHK('\\') || FPUTCSV_FLD_CHK(' ') ) { char *ch = Z_STRVAL(field); char *end = ch + Z_STRLEN(field); + int escaped = 0; smart_str_appendc(&csvline, enclosure); while (ch < end) { - if (*ch == enclosure) { + if (*ch == escape_char) { + escaped = 1; + } else if (!escaped && *ch == enclosure) { smart_str_appendc(&csvline, enclosure); + } else { + escaped = 0; } smart_str_appendc(&csvline, *ch); ch++; diff --git a/ext/standard/tests/file/fputcsv.phpt b/ext/standard/tests/file/fputcsv.phpt index d71f777143c40..63c41509bdd90 100644 --- a/ext/standard/tests/file/fputcsv.phpt +++ b/ext/standard/tests/file/fputcsv.phpt @@ -44,7 +44,7 @@ echo '$list = ';var_export($res);echo ";\n"; $fp = fopen($file, "r"); $res = array(); -while($l=fgetcsv($fp, 0, ',', '"', '"')) +while($l=fgetcsv($fp)) { $res[] = join(',',$l); } @@ -75,10 +75,10 @@ $list = array ( 13 => 'aaa,"""bbb """', 14 => '"aaa""aaa""","""bbb""bbb"', 15 => '"aaa""aaa""""""",bbb', - 16 => 'aaa,"""\\""bbb",ccc', - 17 => '"aaa""\\""a""","""bbb"""', - 18 => '"""\\""""","""aaa"""', - 19 => '"""\\""""""",aaa', + 16 => 'aaa,"""\\"bbb",ccc', + 17 => '"aaa""\\"a""","""bbb"""', + 18 => '"""\\"""","""aaa"""', + 19 => '"""\\"""""",aaa', ); $list = array ( 0 => 'aaa,bbb', diff --git a/ext/standard/tests/file/fputcsv_bug43225.phpt b/ext/standard/tests/file/fputcsv_bug43225.phpt deleted file mode 100644 index 1de3b5fa02323..0000000000000 --- a/ext/standard/tests/file/fputcsv_bug43225.phpt +++ /dev/null @@ -1,20 +0,0 @@ ---TEST-- -fputcsv(): bug #43225 (fputcsv incorrectly handles cells ending in \ followed by ") ---FILE-- - ---EXPECT-- -"a\""",bbb From ef86530a561ad3d6374b81909d6dd336159fb465 Mon Sep 17 00:00:00 2001 From: Adam Harvey Date: Tue, 15 Jan 2013 17:37:21 +0800 Subject: [PATCH 2280/2394] Revert "Apply the fputcsv test fix to SplFileObject_fputcsv.phpt. Mea culpa." This reverts commit 0510701474e8d99b5b30139b5599e44f9b555a5a. --- ext/spl/tests/SplFileObject_fputcsv.phpt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/spl/tests/SplFileObject_fputcsv.phpt b/ext/spl/tests/SplFileObject_fputcsv.phpt index 601edab47fc01..66fdbfd1b9be5 100644 --- a/ext/spl/tests/SplFileObject_fputcsv.phpt +++ b/ext/spl/tests/SplFileObject_fputcsv.phpt @@ -42,7 +42,7 @@ echo '$list = ';var_export($res);echo ";\n"; $fp = fopen($file, "r"); $res = array(); -while($l=fgetcsv($fp, 0, ',', '"', '"')) +while($l=fgetcsv($fp)) { $res[] = join(',',$l); } @@ -76,10 +76,10 @@ $list = array ( 13 => 'aaa,"""bbb """', 14 => '"aaa""aaa""","""bbb""bbb"', 15 => '"aaa""aaa""""""",bbb', - 16 => 'aaa,"""\\""bbb",ccc', - 17 => '"aaa""\\""a""","""bbb"""', - 18 => '"""\\""""","""aaa"""', - 19 => '"""\\""""""",aaa', + 16 => 'aaa,"""\\"bbb",ccc', + 17 => '"aaa""\\"a""","""bbb"""', + 18 => '"""\\"""","""aaa"""', + 19 => '"""\\"""""",aaa', ); $list = array ( 0 => 'aaa,bbb', From d377a266b27e0d0b2ac088333564f8d1f05cceb8 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 15 Jan 2013 11:32:44 +0100 Subject: [PATCH 2281/2394] plug a leak - forgot ot use the dtor already written --- ext/mysqlnd/mysqlnd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 1023b3e5f449d..f5b10632d2fb9 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -1103,6 +1103,7 @@ MYSQLND_METHOD(mysqlnd_conn, connect)(MYSQLND * conn_handle, } /* }}} */ + /* {{{ mysqlnd_connect */ PHPAPI MYSQLND * mysqlnd_connect(MYSQLND * conn_handle, const char * host, const char * user, @@ -2455,7 +2456,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option_2d)(MYSQLND_CONN_DATA * cons if (!conn->options->connect_attr) { goto oom; } - zend_hash_init(conn->options->connect_attr, 0, NULL, NULL, conn->persistent); + zend_hash_init(conn->options->connect_attr, 0, NULL, connect_attr_item_dtor, conn->persistent); } DBG_INF_FMT("Adding [%s][%s]", key, value); { From acc24d1f9eb1f5dddc89123baca14e70be84be20 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 15 Jan 2013 12:19:52 +0100 Subject: [PATCH 2282/2394] Use two dtors thus allow allocation based on the alloc model of the connection. --- ext/date/php_date.c | 2 +- ext/mysqlnd/mysqlnd.c | 24 +++++++++++++++++++----- 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index cc83130e1cf40..1e1e2394567e3 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2071,7 +2071,7 @@ static zval* date_clone_immutable(zval *object) zval *new_object; ALLOC_ZVAL(new_object); - Z_OBJVAL_P(new_object) = date_object_clone_date(object); +// Z_OBJVAL_P(new_object) = date_object_clone_date(object); Z_SET_REFCOUNT_P(new_object, 1); Z_SET_ISREF_P(new_object); Z_TYPE_P(new_object) = IS_OBJECT; diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index f5b10632d2fb9..96c420dee9a10 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2418,14 +2418,28 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option)(MYSQLND_CONN_DATA * const c /* }}} */ -/* {{{ connect_attr_item_dtor */ +/* {{{ connect_attr_item_edtor */ static void -connect_attr_item_dtor(void * pDest) +connect_attr_item_edtor(void * pDest) { #ifdef ZTS TSRMLS_FETCH(); #endif - DBG_ENTER("connect_attr_item_dtor"); + DBG_ENTER("connect_attr_item_edtor"); + mnd_efree(*(char **) pDest); + DBG_VOID_RETURN; +} +/* }}} */ + + +/* {{{ connect_attr_item_pdtor */ +static void +connect_attr_item_pdtor(void * pDest) +{ +#ifdef ZTS + TSRMLS_FETCH(); +#endif + DBG_ENTER("connect_attr_item_pdtor"); mnd_pefree(*(char **) pDest, 1); DBG_VOID_RETURN; } @@ -2456,11 +2470,11 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option_2d)(MYSQLND_CONN_DATA * cons if (!conn->options->connect_attr) { goto oom; } - zend_hash_init(conn->options->connect_attr, 0, NULL, connect_attr_item_dtor, conn->persistent); + zend_hash_init(conn->options->connect_attr, 0, NULL, conn->persistent? connect_attr_item_pdtor:connect_attr_item_edtor, conn->persistent); } DBG_INF_FMT("Adding [%s][%s]", key, value); { - const char * copyv = mnd_pestrdup(value, 1); + const char * copyv = mnd_pestrdup(value, conn->persistent); if (!copyv) { goto oom; } From 5cfa916aad14df889e9119161e359b57a4d9886e Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 15 Jan 2013 12:20:58 +0100 Subject: [PATCH 2283/2394] revert change. now it doesn't compile again...someone should fix ext/date... --- ext/date/php_date.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 1e1e2394567e3..cc83130e1cf40 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2071,7 +2071,7 @@ static zval* date_clone_immutable(zval *object) zval *new_object; ALLOC_ZVAL(new_object); -// Z_OBJVAL_P(new_object) = date_object_clone_date(object); + Z_OBJVAL_P(new_object) = date_object_clone_date(object); Z_SET_REFCOUNT_P(new_object, 1); Z_SET_ISREF_P(new_object); Z_TYPE_P(new_object) = IS_OBJECT; From dba22c08640b02e68bfea68440246fec1fb7459d Mon Sep 17 00:00:00 2001 From: Jille Timmermans Date: Tue, 15 Jan 2013 11:25:55 +0100 Subject: [PATCH 2284/2394] Dereferencing process-handles no longer waits on those processes. Implements FR #46487 --- NEWS | 3 +++ ext/standard/file.c | 3 +++ ext/standard/file.h | 3 ++- ext/standard/proc_open.c | 20 ++++++++++++++++---- 4 files changed, 24 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 4145dc54ee933..212029cbee8e7 100644 --- a/NEWS +++ b/NEWS @@ -247,4 +247,7 @@ PHP NEWS . Fixed bug #63248 (Load multiple magic files from a directory under Windows). (Anatoliy) +- General improvements: + . Implemented FR #46487 (Dereferencing process-handles no longer waits on those processes). (Jille Timmermans) + <<< NOTE: Insert NEWS from last stable release here prior to actual release! >>> diff --git a/ext/standard/file.c b/ext/standard/file.c index 74577ac495de2..cf8b159556e94 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -159,6 +159,7 @@ static ZEND_RSRC_DTOR_FUNC(file_context_dtor) static void file_globals_ctor(php_file_globals *file_globals_p TSRMLS_DC) { FG(pclose_ret) = 0; + FG(pclose_wait) = 0; FG(user_stream_current_filename) = NULL; FG(def_chunk_size) = PHP_SOCK_CHUNK_SIZE; FG(wrapper_errors) = NULL; @@ -960,7 +961,9 @@ PHP_FUNCTION(pclose) PHP_STREAM_TO_ZVAL(stream, &arg1); + FG(pclose_wait) = 1; zend_list_delete(stream->rsrc_id); + FG(pclose_wait) = 0; RETURN_LONG(FG(pclose_ret)); } /* }}} */ diff --git a/ext/standard/file.h b/ext/standard/file.h index 0a4512ecd4ac8..2bcdfd64bf5e6 100644 --- a/ext/standard/file.h +++ b/ext/standard/file.h @@ -115,7 +115,7 @@ typedef struct _php_meta_tags_data { php_meta_tags_token php_next_meta_token(php_meta_tags_data * TSRMLS_DC); typedef struct { - int pclose_ret; + int pclose_ret; size_t def_chunk_size; long auto_detect_line_endings; long default_socket_timeout; @@ -126,6 +126,7 @@ typedef struct { HashTable *stream_wrappers; /* per-request copy of url_stream_wrappers_hash */ HashTable *stream_filters; /* per-request copy of stream_filters_hash */ HashTable *wrapper_errors; /* key: wrapper address; value: linked list of char* */ + int pclose_wait; } php_file_globals; #ifdef ZTS diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c index 1edfe78849ba9..4e39a40be4ebf 100644 --- a/ext/standard/proc_open.c +++ b/ext/standard/proc_open.c @@ -208,6 +208,7 @@ static void proc_open_rsrc_dtor(zend_rsrc_list_entry *rsrc TSRMLS_DC) DWORD wstatus; #elif HAVE_SYS_WAIT_H int wstatus; + int waitpid_options = 0; pid_t wait_pid; #endif @@ -220,18 +221,27 @@ static void proc_open_rsrc_dtor(zend_rsrc_list_entry *rsrc TSRMLS_DC) } #ifdef PHP_WIN32 - WaitForSingleObject(proc->childHandle, INFINITE); + if (FG(pclose_wait)) { + WaitForSingleObject(proc->childHandle, INFINITE); + } GetExitCodeProcess(proc->childHandle, &wstatus); - FG(pclose_ret) = wstatus; + if (wstatus == STILL_ACTIVE) { + FG(pclose_ret) = -1; + } else { + FG(pclose_ret) = wstatus; + } CloseHandle(proc->childHandle); #elif HAVE_SYS_WAIT_H + if (!FG(pclose_wait)) { + waitpid_options = WNOHANG; + } do { - wait_pid = waitpid(proc->child, &wstatus, 0); + wait_pid = waitpid(proc->child, &wstatus, waitpid_options); } while (wait_pid == -1 && errno == EINTR); - if (wait_pid == -1) { + if (wait_pid <= 0) { FG(pclose_ret) = -1; } else { if (WIFEXITED(wstatus)) @@ -300,7 +310,9 @@ PHP_FUNCTION(proc_close) ZEND_FETCH_RESOURCE(proc, struct php_process_handle *, &zproc, -1, "process", le_proc_open); + FG(pclose_wait) = 1; zend_list_delete(Z_LVAL_P(zproc)); + FG(pclose_wait) = 0; RETURN_LONG(FG(pclose_ret)); } /* }}} */ From 7629c8db401b3695348d26c0785c9ab4b7e6ebb1 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 15 Jan 2013 19:45:09 -0200 Subject: [PATCH 2285/2394] - Fixed ZTS build --- ext/date/php_date.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index cc83130e1cf40..54dc2f5b70a04 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2066,12 +2066,12 @@ static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC) return new_ov; } -static zval* date_clone_immutable(zval *object) +static zval* date_clone_immutable(zval *object TSRMLS_DC) { zval *new_object; ALLOC_ZVAL(new_object); - Z_OBJVAL_P(new_object) = date_object_clone_date(object); + Z_OBJVAL_P(new_object) = date_object_clone_date(object TSRMLS_CC); Z_SET_REFCOUNT_P(new_object, 1); Z_SET_ISREF_P(new_object); Z_TYPE_P(new_object) = IS_OBJECT; @@ -2970,7 +2970,7 @@ PHP_METHOD(DateTimeImmutable, modify) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_modify(new_object, modify, modify_len, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3037,7 +3037,7 @@ PHP_METHOD(DateTimeImmutable, add) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_add(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3107,7 +3107,7 @@ PHP_METHOD(DateTimeImmutable, sub) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_sub(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3197,7 +3197,7 @@ PHP_METHOD(DateTimeImmutable, setTimezone) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_timezone_set(new_object, timezone_object, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3280,7 +3280,7 @@ PHP_METHOD(DateTimeImmutable, setTime) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_time_set(new_object, h, i, s, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3328,7 +3328,7 @@ PHP_METHOD(DateTimeImmutable, setDate) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_date_set(new_object, y, m, d, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3380,7 +3380,7 @@ PHP_METHOD(DateTimeImmutable, setISODate) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_isodate_set(new_object, y, w, d, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3426,7 +3426,7 @@ PHP_METHOD(DateTimeImmutable, setTimestamp) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_timestamp_set(new_object, timestamp, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); From 2f7aafe9929d843ae089a7072c5e6d9bd70c77ae Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 15 Jan 2013 19:59:23 -0200 Subject: [PATCH 2286/2394] - Fixed ZTS build --- ext/date/php_date.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index cc83130e1cf40..54dc2f5b70a04 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2066,12 +2066,12 @@ static zend_object_value date_object_clone_date(zval *this_ptr TSRMLS_DC) return new_ov; } -static zval* date_clone_immutable(zval *object) +static zval* date_clone_immutable(zval *object TSRMLS_DC) { zval *new_object; ALLOC_ZVAL(new_object); - Z_OBJVAL_P(new_object) = date_object_clone_date(object); + Z_OBJVAL_P(new_object) = date_object_clone_date(object TSRMLS_CC); Z_SET_REFCOUNT_P(new_object, 1); Z_SET_ISREF_P(new_object); Z_TYPE_P(new_object) = IS_OBJECT; @@ -2970,7 +2970,7 @@ PHP_METHOD(DateTimeImmutable, modify) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_modify(new_object, modify, modify_len, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3037,7 +3037,7 @@ PHP_METHOD(DateTimeImmutable, add) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_add(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3107,7 +3107,7 @@ PHP_METHOD(DateTimeImmutable, sub) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_sub(new_object, interval, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3197,7 +3197,7 @@ PHP_METHOD(DateTimeImmutable, setTimezone) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_timezone_set(new_object, timezone_object, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3280,7 +3280,7 @@ PHP_METHOD(DateTimeImmutable, setTime) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_time_set(new_object, h, i, s, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3328,7 +3328,7 @@ PHP_METHOD(DateTimeImmutable, setDate) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_date_set(new_object, y, m, d, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3380,7 +3380,7 @@ PHP_METHOD(DateTimeImmutable, setISODate) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_isodate_set(new_object, y, w, d, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); @@ -3426,7 +3426,7 @@ PHP_METHOD(DateTimeImmutable, setTimestamp) RETURN_FALSE; } - new_object = date_clone_immutable(object); + new_object = date_clone_immutable(object TSRMLS_CC); php_date_timestamp_set(new_object, timestamp, return_value TSRMLS_CC); RETURN_ZVAL(new_object, 0, 1); From abb12f5d7b82c40bc11eb374130e1607fad76d31 Mon Sep 17 00:00:00 2001 From: Ard Biesheuvel Date: Thu, 17 Jan 2013 17:41:58 +0100 Subject: [PATCH 2287/2394] Added test cases for ZEND_SIGNED_MULTIPLY_LONG() Before making changes to the implementation of ZEND_SIGNED_MULTIPLY_LONG(), add some test cases to make sure the various implementations remain equivalent. --- Zend/tests/zend_signed_multiply-32bit.phpt | 14 ++++++++++++++ Zend/tests/zend_signed_multiply-64bit.phpt | 14 ++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 Zend/tests/zend_signed_multiply-32bit.phpt create mode 100644 Zend/tests/zend_signed_multiply-64bit.phpt diff --git a/Zend/tests/zend_signed_multiply-32bit.phpt b/Zend/tests/zend_signed_multiply-32bit.phpt new file mode 100644 index 0000000000000..0a42bd42d874e --- /dev/null +++ b/Zend/tests/zend_signed_multiply-32bit.phpt @@ -0,0 +1,14 @@ +--TEST-- +Zend signed multiply 32-bit +--SKIPIF-- + 0) print "skip Running on 64-bit target"; ?> +--FILE-- + +--EXPECTF-- +int(-2147450880) +int(2147483646) +float(-2147516415) diff --git a/Zend/tests/zend_signed_multiply-64bit.phpt b/Zend/tests/zend_signed_multiply-64bit.phpt new file mode 100644 index 0000000000000..86e5292ff6d98 --- /dev/null +++ b/Zend/tests/zend_signed_multiply-64bit.phpt @@ -0,0 +1,14 @@ +--TEST-- +Zend signed multiply 64-bit +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +int(-9223372034707292160) +int(9223372036854775806) +float(-9.2233720390023E+18) From 0b8ec19629083de65310f0a136320e8e79a1c8ef Mon Sep 17 00:00:00 2001 From: Ard Biesheuvel Date: Thu, 17 Jan 2013 17:51:12 +0100 Subject: [PATCH 2288/2394] Added ARM accelerated implementations for ZEND_SIGNED_MULTIPLY_LONG() Added inline assembler implementations: - for 32-bit ARM, as the existing C implementation uses 64-bit integer arithmetic, which relies on software emulation by libgcc; - for 64-bit ARM, as the existing C implementation uses long doubles to check for overflow before using the integer result. Also updated my email address and fixed some whitespace --- Zend/zend_multiply.h | 45 ++++++++++++++++++++++++++++++++++---------- 1 file changed, 35 insertions(+), 10 deletions(-) diff --git a/Zend/zend_multiply.h b/Zend/zend_multiply.h index c3c9657f3b25e..e52956f417627 100644 --- a/Zend/zend_multiply.h +++ b/Zend/zend_multiply.h @@ -13,7 +13,7 @@ | license@zend.com so we can mail you a copy immediately. | +----------------------------------------------------------------------+ | Authors: Sascha Schumann | - | Ard Biesheuvel | + | Ard Biesheuvel | +----------------------------------------------------------------------+ */ @@ -43,6 +43,31 @@ else (lval) = __tmpvar; \ } while (0) +#elif defined(__arm__) && defined(__GNUC__) + +#define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ + long __tmpvar; \ + __asm__("smull %0, %1, %2, %3\n" \ + "sub %1, %1, %0, asr #31" \ + : "=r"(__tmpvar), "=r"(usedval) \ + : "r"(a), "r"(b)); \ + if (usedval) (dval) = (double) (a) * (double) (b); \ + else (lval) = __tmpvar; \ +} while (0) + +#elif defined(__aarch64__) && defined(__GNUC__) + +#define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ + long __tmpvar; \ + __asm__("mul %0, %2, %3\n" \ + "smulh %1, %2, %3\n" \ + "sub %1, %1, %0, asr #63\n" \ + : "=X"(__tmpvar), "=X"(usedval) \ + : "X"(a), "X"(b)); \ + if (usedval) (dval) = (double) (a) * (double) (b); \ + else (lval) = __tmpvar; \ +} while (0) + #elif SIZEOF_LONG == 4 && defined(HAVE_ZEND_LONG64) #define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ @@ -58,15 +83,15 @@ #else -#define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ - long __lres = (a) * (b); \ - long double __dres = (long double)(a) * (long double)(b); \ - long double __delta = (long double) __lres - __dres; \ - if ( ((usedval) = (( __dres + __delta ) != __dres))) { \ - (dval) = __dres; \ - } else { \ - (lval) = __lres; \ - } \ +#define ZEND_SIGNED_MULTIPLY_LONG(a, b, lval, dval, usedval) do { \ + long __lres = (a) * (b); \ + long double __dres = (long double)(a) * (long double)(b); \ + long double __delta = (long double) __lres - __dres; \ + if ( ((usedval) = (( __dres + __delta ) != __dres))) { \ + (dval) = __dres; \ + } else { \ + (lval) = __lres; \ + } \ } while (0) #endif From 87d57010656cf2a9252e898fdf69377b7a60b8ca Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Fri, 18 Jan 2013 15:12:51 +0800 Subject: [PATCH 2289/2394] Fix skipif section --- Zend/tests/zend_signed_multiply-32bit.phpt | 2 +- Zend/tests/zend_signed_multiply-64bit.phpt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Zend/tests/zend_signed_multiply-32bit.phpt b/Zend/tests/zend_signed_multiply-32bit.phpt index 0a42bd42d874e..3f37cbac19908 100644 --- a/Zend/tests/zend_signed_multiply-32bit.phpt +++ b/Zend/tests/zend_signed_multiply-32bit.phpt @@ -1,7 +1,7 @@ --TEST-- Zend signed multiply 32-bit --SKIPIF-- - 0) print "skip Running on 64-bit target"; ?> + 0) print "skip Running on 64-bit target"; ?> --FILE-- + --FILE-- Date: Fri, 18 Jan 2013 15:49:36 +0800 Subject: [PATCH 2290/2394] Fixed bug #63988 (Two Date tests fail) only for PHP-5.5 --- ext/date/php_date.c | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 54dc2f5b70a04..f4115dc7e1d21 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2883,14 +2883,18 @@ PHP_FUNCTION(date_format) } /* }}} */ -static void php_date_modify(zval *object, char *modify, int modify_len, zval *return_value TSRMLS_DC) +static int php_date_modify(zval *object, char *modify, int modify_len TSRMLS_DC) { php_date_obj *dateobj; timelib_time *tmp_time; timelib_error_container *err = NULL; dateobj = (php_date_obj *) zend_object_store_get_object(object TSRMLS_CC); - DATE_CHECK_INITIALIZED(dateobj->time, DateTime); + + if (!(dateobj->time)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "The DateTime object has not been correctly initialized by its constructor"); + return 0; + } tmp_time = timelib_strtotime(modify, modify_len, &err, DATE_TIMEZONEDB, php_date_parse_tzfile_wrapper); @@ -2901,7 +2905,7 @@ static void php_date_modify(zval *object, char *modify, int modify_len, zval *re php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed to parse time string (%s) at position %d (%c): %s", modify, err->error_messages[0].position, err->error_messages[0].character, err->error_messages[0].message); timelib_time_dtor(tmp_time); - RETURN_FALSE; + return 0; } memcpy(&dateobj->time->relative, &tmp_time->relative, sizeof(struct timelib_rel_time)); @@ -2937,6 +2941,8 @@ static void php_date_modify(zval *object, char *modify, int modify_len, zval *re timelib_update_ts(dateobj->time, NULL); timelib_update_from_sse(dateobj->time); dateobj->time->have_relative = 0; + + return 1; } /* {{{ proto DateTime date_modify(DateTime object, string modify) @@ -2952,9 +2958,11 @@ PHP_FUNCTION(date_modify) RETURN_FALSE; } - php_date_modify(object, modify, modify_len, return_value TSRMLS_CC); + if (php_date_modify(object, modify, modify_len TSRMLS_CC)) { + RETURN_ZVAL(object, 1, 0); + } - RETURN_ZVAL(object, 1, 0); + RETURN_FALSE; } /* }}} */ @@ -2971,9 +2979,11 @@ PHP_METHOD(DateTimeImmutable, modify) } new_object = date_clone_immutable(object TSRMLS_CC); - php_date_modify(new_object, modify, modify_len, return_value TSRMLS_CC); + if (php_date_modify(new_object, modify, modify_len TSRMLS_CC)) { + RETURN_ZVAL(new_object, 0, 1); + } - RETURN_ZVAL(new_object, 0, 1); + RETURN_FALSE; } /* }}} */ From 35154c7ebcd34ec01843b9486051c2523dbe2770 Mon Sep 17 00:00:00 2001 From: Ard Biesheuvel Date: Fri, 18 Jan 2013 10:13:10 +0100 Subject: [PATCH 2291/2394] Update config.sub to latest GPLv2 upstream version This adds the ability to configure/build for 64-bit ARMv8, which uses the host triplet 'aarch64-linux-gnu'. Source: http://git.savannah.gnu.org/gitweb/?p=config.git;h=306afce --- config.sub | 295 ++++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 215 insertions(+), 80 deletions(-) diff --git a/config.sub b/config.sub index 6759825a5b7fc..eee8dccb05c1b 100644 --- a/config.sub +++ b/config.sub @@ -1,10 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 -# Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011, 2012, 2013 Free Software Foundation, Inc. -timestamp='2008-01-16' +timestamp='2012-12-23' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -21,9 +21,7 @@ timestamp='2008-01-16' # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA -# 02110-1301, USA. +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -32,13 +30,16 @@ timestamp='2008-01-16' # Please send patches to . Submit a context -# diff and a properly formatted ChangeLog entry. +# diff and a properly formatted GNU ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. @@ -72,8 +73,9 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, +2012, 2013 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -120,12 +122,18 @@ esac # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in - nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ - uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ + nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ + linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + knetbsd*-gnu* | netbsd*-gnu* | \ + kopensolaris*-gnu* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; + android-linux) + os=-linux-android + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown + ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] @@ -148,10 +156,13 @@ case $os in -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ - -apple | -axis | -knuth | -cray) + -apple | -axis | -knuth | -cray | -microblaze*) os= basic_machine=$1 ;; + -bluegene*) + os=-cnk + ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 @@ -166,10 +177,10 @@ case $os in os=-chorusos basic_machine=$1 ;; - -chorusrdb) - os=-chorusrdb + -chorusrdb) + os=-chorusrdb basic_machine=$1 - ;; + ;; -hiux*) os=-hiuxwe2 ;; @@ -214,6 +225,12 @@ case $os in -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; + -lynx*178) + os=-lynxos178 + ;; + -lynx*5) + os=-lynxos5 + ;; -lynx*) os=-lynxos ;; @@ -238,24 +255,34 @@ case $basic_machine in # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ + | aarch64 | aarch64_be \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ - | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ + | arc \ + | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ + | avr | avr32 \ + | be32 | be64 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ + | epiphany \ | fido | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | hexagon \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ + | le32 | le64 \ + | lm32 \ | m32c | m32r | m32rle | m68000 | m68k | m88k \ - | maxq | mb | microblaze | mcore | mep \ + | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ - | mips64vr | mips64vrel \ + | mips64octeon | mips64octeonel \ | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ @@ -268,29 +295,42 @@ case $basic_machine in | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ + | moxie \ | mt \ | msp430 \ + | nds32 | nds32le | nds32be \ | nios | nios2 \ | ns16k | ns32k \ + | open8 \ | or32 \ | pdp10 | pdp11 | pj | pjl \ - | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ | pyramid \ + | rl78 | rx \ | score \ - | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ - | spu | strongarm \ - | tahoe | thumb | tic4x | tic80 | tron \ - | v850 | v850e \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ | we32k \ - | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ - | z8k) + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) basic_machine=$basic_machine-unknown ;; - m6811 | m68hc11 | m6812 | m68hc12) - # Motorola 68HC11/12. + c54x) + basic_machine=tic54x-unknown + ;; + c55x) + basic_machine=tic55x-unknown + ;; + c6x) + basic_machine=tic6x-unknown + ;; + m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip) basic_machine=$basic_machine-unknown os=-none ;; @@ -300,6 +340,21 @@ case $basic_machine in basic_machine=mt-unknown ;; + strongarm | thumb | xscale) + basic_machine=arm-unknown + ;; + xgate) + basic_machine=$basic_machine-unknown + os=-none + ;; + xscaleeb) + basic_machine=armeb-unknown + ;; + + xscaleel) + basic_machine=armel-unknown + ;; + # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. @@ -314,29 +369,37 @@ case $basic_machine in # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ + | aarch64-* | aarch64_be-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ + | be32-* | be64-* \ | bfin-* | bs2000-* \ - | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | hexagon-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ + | le32-* | le64-* \ + | lm32-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ + | microblaze-* | microblazeel-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ - | mips64vr-* | mips64vrel-* \ + | mips64octeon-* | mips64octeonel-* \ | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ @@ -351,27 +414,32 @@ case $basic_machine in | mmix-* \ | mt-* \ | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ | pyramid-* \ - | romp-* | rs6000-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ + | rl78-* | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ - | tahoe-* | thumb-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ + | tahoe-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ | tron-* \ - | v850-* | v850e-* | vax-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ | we32k-* \ - | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ | xstormy16-* | xtensa*-* \ | ymp-* \ - | z8k-*) + | z8k-* | z80-*) ;; # Recognize the basic CPU types without company name, with glob match. xtensa*) @@ -393,7 +461,7 @@ case $basic_machine in basic_machine=a29k-amd os=-udi ;; - abacus) + abacus) basic_machine=abacus-unknown ;; adobe68k) @@ -439,6 +507,10 @@ case $basic_machine in basic_machine=m68k-apollo os=-bsd ;; + aros) + basic_machine=i386-pc + os=-aros + ;; aux) basic_machine=m68k-apple os=-aux @@ -455,10 +527,27 @@ case $basic_machine in basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk + ;; + c54x-*) + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c55x-*) + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c6x-*) + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; c90) basic_machine=c90-cray os=-unicos ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; convex-c1) basic_machine=c1-convex os=-bsd @@ -487,7 +576,7 @@ case $basic_machine in basic_machine=craynv-cray os=-unicosmp ;; - cr16) + cr16 | cr16-*) basic_machine=cr16-unknown os=-elf ;; @@ -526,6 +615,10 @@ case $basic_machine in basic_machine=m88k-motorola os=-sysv3 ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp @@ -641,7 +734,6 @@ case $basic_machine in i370-ibm* | ibm*) basic_machine=i370-ibm ;; -# I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 @@ -699,6 +791,13 @@ case $basic_machine in basic_machine=ns32k-utek os=-sysv ;; + microblaze*) + basic_machine=microblaze-xilinx + ;; + mingw64) + basic_machine=x86_64-pc + os=-mingw64 + ;; mingw32) basic_machine=i386-pc os=-mingw32 @@ -735,10 +834,18 @@ case $basic_machine in ms1-*) basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; + msys) + basic_machine=i386-pc + os=-msys + ;; mvs) basic_machine=i370-ibm os=-mvs ;; + nacl) + basic_machine=le32-unknown + os=-nacl + ;; ncr3000) basic_machine=i486-ncr os=-sysv4 @@ -803,6 +910,12 @@ case $basic_machine in np1) basic_machine=np1-gould ;; + neo-tandem) + basic_machine=neo-tandem + ;; + nse-tandem) + basic_machine=nse-tandem + ;; nsr-tandem) basic_machine=nsr-tandem ;; @@ -885,9 +998,10 @@ case $basic_machine in ;; power) basic_machine=power-ibm ;; - ppc) basic_machine=powerpc-unknown + ppc | ppcbe) basic_machine=powerpc-unknown ;; - ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown @@ -912,7 +1026,11 @@ case $basic_machine in basic_machine=i586-unknown os=-pw32 ;; - rdos) + rdos | rdos64) + basic_machine=x86_64-pc + os=-rdos + ;; + rdos32) basic_machine=i386-pc os=-rdos ;; @@ -981,6 +1099,9 @@ case $basic_machine in basic_machine=i860-stratus os=-sysv4 ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; sun2) basic_machine=m68000-sun ;; @@ -1037,20 +1158,8 @@ case $basic_machine in basic_machine=t90-cray os=-unicos ;; - tic54x | c54x*) - basic_machine=tic54x-unknown - os=-coff - ;; - tic55x | c55x*) - basic_machine=tic55x-unknown - os=-coff - ;; - tic6x | c6x*) - basic_machine=tic6x-unknown - os=-coff - ;; tile*) - basic_machine=tile-unknown + basic_machine=$basic_machine-unknown os=-linux-gnu ;; tx39) @@ -1120,6 +1229,9 @@ case $basic_machine in xps | xps100) basic_machine=xps100-honeywell ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; ymp) basic_machine=ymp-cray os=-unicos @@ -1128,6 +1240,10 @@ case $basic_machine in basic_machine=z8k-unknown os=-sim ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; none) basic_machine=none-none os=-none @@ -1166,7 +1282,7 @@ case $basic_machine in we32k) basic_machine=we32k-att ;; - sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) @@ -1213,9 +1329,12 @@ esac if [ x"$os" != x"" ] then case $os in - # First match some system type aliases - # that might get confused with valid system types. + # First match some system type aliases + # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux + ;; -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; @@ -1236,21 +1355,23 @@ case $os in # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* \ + | -aos* | -aros* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ - | -openbsd* | -solidbsd* \ + | -bitrig* | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* \ - | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ + | -chorusos* | -chorusrdb* | -cegcc* \ + | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-musl* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ @@ -1258,7 +1379,7 @@ case $os in | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ - | -skyos* | -haiku* | -rdos* | -toppers* | -drops*) + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) @@ -1297,7 +1418,7 @@ case $os in -opened*) os=-openedition ;; - -os400*) + -os400*) os=-os400 ;; -wince*) @@ -1346,7 +1467,7 @@ case $os in -sinix*) os=-sysv4 ;; - -tpf*) + -tpf*) os=-tpf ;; -triton*) @@ -1388,6 +1509,11 @@ case $os in -zvmoe) os=-zvmoe ;; + -dicos*) + os=-dicos + ;; + -nacl*) + ;; -none) ;; *) @@ -1410,10 +1536,10 @@ else # system, and we'll never get to this point. case $basic_machine in - score-*) + score-*) os=-elf ;; - spu-*) + spu-*) os=-elf ;; *-acorn) @@ -1425,8 +1551,20 @@ case $basic_machine in arm*-semi) os=-aout ;; - c4x-* | tic4x-*) - os=-coff + c4x-* | tic4x-*) + os=-coff + ;; + hexagon-*) + os=-elf + ;; + tic54x-*) + os=-coff + ;; + tic55x-*) + os=-coff + ;; + tic6x-*) + os=-coff ;; # This must come before the *-dec entry. pdp10-*) @@ -1446,14 +1584,11 @@ case $basic_machine in ;; m68000-sun) os=-sunos3 - # This also exists in the configure program, but was not the - # default. - # os=-sunos4 ;; m68*-cisco) os=-aout ;; - mep-*) + mep-*) os=-elf ;; mips*-cisco) @@ -1480,7 +1615,7 @@ case $basic_machine in *-ibm) os=-aix ;; - *-knuth) + *-knuth) os=-mmixware ;; *-wec) @@ -1585,7 +1720,7 @@ case $basic_machine in -sunos*) vendor=sun ;; - -aix*) + -cnk*|-aix*) vendor=ibm ;; -beos*) From 8991ed016fa257c9f8ba42580c34568b3c2ce3e5 Mon Sep 17 00:00:00 2001 From: Lars Strojny Date: Sat, 19 Jan 2013 01:00:47 +0100 Subject: [PATCH 2292/2394] Class Name Resolution As Scalar Via "class" Keyword --- NEWS | 2 + Zend/tests/class_name_as_scalar.phpt | 77 +++++++++++++++++++ .../tests/class_name_as_scalar_error_001.phpt | 13 ++++ .../tests/class_name_as_scalar_error_002.phpt | 13 ++++ .../tests/class_name_as_scalar_error_003.phpt | 13 ++++ .../tests/class_name_as_scalar_error_004.phpt | 13 ++++ .../tests/class_name_as_scalar_error_005.phpt | 10 +++ .../tests/class_name_as_scalar_error_006.phpt | 10 +++ Zend/zend_compile.c | 47 +++++++++++ Zend/zend_compile.h | 2 + Zend/zend_language_parser.y | 10 +++ Zend/zend_vm_def.h | 3 + Zend/zend_vm_execute.h | 9 +++ 13 files changed, 222 insertions(+) create mode 100644 Zend/tests/class_name_as_scalar.phpt create mode 100644 Zend/tests/class_name_as_scalar_error_001.phpt create mode 100644 Zend/tests/class_name_as_scalar_error_002.phpt create mode 100644 Zend/tests/class_name_as_scalar_error_003.phpt create mode 100644 Zend/tests/class_name_as_scalar_error_004.phpt create mode 100644 Zend/tests/class_name_as_scalar_error_005.phpt create mode 100644 Zend/tests/class_name_as_scalar_error_006.phpt diff --git a/NEWS b/NEWS index 6395b34f53e20..3bb0373d3b72d 100644 --- a/NEWS +++ b/NEWS @@ -4,6 +4,8 @@ PHP NEWS - Core: . Fixed bug #63980 (object members get trimmed by zero bytes). (Laruence) + . Implemented RFC for Class Name Resolution As Scalar Via "class" Keyword. + (Ralph Schindler, Nikita Popov, Lars) - General improvements: . Fixed bug #63874 (Segfault if php_strip_whitespace has heredoc). (Pierrick) diff --git a/Zend/tests/class_name_as_scalar.phpt b/Zend/tests/class_name_as_scalar.phpt new file mode 100644 index 0000000000000..38e55b16d551b --- /dev/null +++ b/Zend/tests/class_name_as_scalar.phpt @@ -0,0 +1,77 @@ +--TEST-- +class name as scalar from ::class keyword +--FILE-- + +--EXPECTF-- +In NS +string(11) "Foo\Bar\Moo" +Top +string(11) "Foo\Bar\One" +string(3) "Boo" +string(7) "Bee\Bop" +string(3) "Moo" +object(Foo\Bar\One)#1 (0) { +} +string(11) "Foo\Bar\Two" +string(11) "Foo\Bar\Two" +string(11) "Foo\Bar\One" +string(11) "Foo\Bar\Baz" +Parent +string(11) "Foo\Bar\Two" +string(13) "Foo\Bar\Three" +string(11) "Foo\Bar\One" +string(11) "Foo\Bar\Baz" +Compile Check +string(13) "Foo\Bar\Three" +string(11) "Foo\Bar\Baz" +string(11) "Foo\Bar\One" +string(11) "Foo\Bar\Two" diff --git a/Zend/tests/class_name_as_scalar_error_001.phpt b/Zend/tests/class_name_as_scalar_error_001.phpt new file mode 100644 index 0000000000000..1c7aa7ea848bd --- /dev/null +++ b/Zend/tests/class_name_as_scalar_error_001.phpt @@ -0,0 +1,13 @@ +--TEST-- +class name as scalar from ::class keyword error using static in class constant +--FILE-- + +--EXPECTF-- +Fatal error: static::class cannot be used for compile-time class name resolution in %s on line %d diff --git a/Zend/tests/class_name_as_scalar_error_002.phpt b/Zend/tests/class_name_as_scalar_error_002.phpt new file mode 100644 index 0000000000000..59b7a2edc9acc --- /dev/null +++ b/Zend/tests/class_name_as_scalar_error_002.phpt @@ -0,0 +1,13 @@ +--TEST-- +class name as scalar from ::class keyword error using parent in class constant +--FILE-- + +--EXPECTF-- +Fatal error: parent::class cannot be used for compile-time class name resolution in %s on line %d diff --git a/Zend/tests/class_name_as_scalar_error_003.phpt b/Zend/tests/class_name_as_scalar_error_003.phpt new file mode 100644 index 0000000000000..92990416930fd --- /dev/null +++ b/Zend/tests/class_name_as_scalar_error_003.phpt @@ -0,0 +1,13 @@ +--TEST-- +class name as scalar from ::class keyword error using static in method signature +--FILE-- + +--EXPECTF-- +Fatal error: static::class cannot be used for compile-time class name resolution in %s on line %d diff --git a/Zend/tests/class_name_as_scalar_error_004.phpt b/Zend/tests/class_name_as_scalar_error_004.phpt new file mode 100644 index 0000000000000..c00037fca3e15 --- /dev/null +++ b/Zend/tests/class_name_as_scalar_error_004.phpt @@ -0,0 +1,13 @@ +--TEST-- +class name as scalar from ::class keyword error using parent in method signature +--FILE-- + +--EXPECTF-- +Fatal error: parent::class cannot be used for compile-time class name resolution in %s on line %d diff --git a/Zend/tests/class_name_as_scalar_error_005.phpt b/Zend/tests/class_name_as_scalar_error_005.phpt new file mode 100644 index 0000000000000..39de69ffb3f6e --- /dev/null +++ b/Zend/tests/class_name_as_scalar_error_005.phpt @@ -0,0 +1,10 @@ +--TEST-- +class name as scalar from ::class keyword error using static non class context +--FILE-- + +--EXPECTF-- +Fatal error: Cannot access static::class when no class scope is active in %s on line %d \ No newline at end of file diff --git a/Zend/tests/class_name_as_scalar_error_006.phpt b/Zend/tests/class_name_as_scalar_error_006.phpt new file mode 100644 index 0000000000000..a4cc9a528b5c2 --- /dev/null +++ b/Zend/tests/class_name_as_scalar_error_006.phpt @@ -0,0 +1,10 @@ +--TEST-- +class name as scalar from ::class keyword error using parent in non class context +--FILE-- + +--EXPECTF-- +Fatal error: Cannot access parent::class when no class scope is active in %s on line %d diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 43b891695e0f4..b574ad6b69180 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2119,6 +2119,53 @@ void zend_resolve_non_class_name(znode *element_name, zend_bool check_namespace } /* }}} */ +void zend_do_resolve_class_name(znode *result, znode *class_name, int is_static TSRMLS_DC) /* {{{ */ +{ + char *lcname; + int lctype; + znode constant_name; + + lcname = zend_str_tolower_dup(Z_STRVAL(class_name->u.constant), class_name->u.constant.value.str.len); + lctype = zend_get_class_fetch_type(lcname, strlen(lcname)); + switch (lctype) { + case ZEND_FETCH_CLASS_SELF: + if (!CG(active_class_entry)) { + zend_error(E_COMPILE_ERROR, "Cannot access self::class when no class scope is active"); + } + zval_dtor(&class_name->u.constant); + class_name->op_type = IS_CONST; + ZVAL_STRINGL(&class_name->u.constant, CG(active_class_entry)->name, CG(active_class_entry)->name_length, 1); + *result = *class_name; + break; + case ZEND_FETCH_CLASS_STATIC: + case ZEND_FETCH_CLASS_PARENT: + if (is_static) { + zend_error(E_COMPILE_ERROR, + "%s::class cannot be used for compile-time class name resolution", + lctype == ZEND_FETCH_CLASS_STATIC ? "static" : "parent" + ); + } + if (!CG(active_class_entry)) { + zend_error(E_COMPILE_ERROR, + "Cannot access %s::class when no class scope is active", + lctype == ZEND_FETCH_CLASS_STATIC ? "static" : "parent" + ); + } + constant_name.op_type = IS_CONST; + ZVAL_STRINGL(&constant_name.u.constant, "class", sizeof("class")-1, 1); + zend_do_fetch_constant(result, class_name, &constant_name, ZEND_RT, 1 TSRMLS_CC); + break; + case ZEND_FETCH_CLASS_DEFAULT: + zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1); + *result = *class_name; + break; + } + + efree(lcname); + +} +/* }}} */ + void zend_resolve_class_name(znode *class_name, ulong fetch_type, int check_ns_name TSRMLS_DC) /* {{{ */ { char *compound; diff --git a/Zend/zend_compile.h b/Zend/zend_compile.h index 0f58b5550041e..8042dd54eee81 100644 --- a/Zend/zend_compile.h +++ b/Zend/zend_compile.h @@ -638,6 +638,8 @@ void zend_verify_namespace(TSRMLS_D); void zend_do_use(znode *name, znode *new_name, int is_global TSRMLS_DC); void zend_do_end_compilation(TSRMLS_D); +void zend_do_resolve_class_name(znode *result, znode *class_name, int is_static TSRMLS_DC); + void zend_do_label(znode *label TSRMLS_DC); void zend_do_goto(const znode *label TSRMLS_DC); void zend_resolve_goto_label(zend_op_array *op_array, zend_op *opline, int pass2 TSRMLS_DC); diff --git a/Zend/zend_language_parser.y b/Zend/zend_language_parser.y index 781d806fe7c58..ccbc9b174c9d4 100644 --- a/Zend/zend_language_parser.y +++ b/Zend/zend_language_parser.y @@ -942,6 +942,7 @@ common_scalar: static_scalar: /* compile-time evaluated scalars */ common_scalar { $$ = $1; } + | static_class_name_scalar { $$ = $1; } | namespace_name { zend_do_fetch_constant(&$$, NULL, &$1, ZEND_CT, 1 TSRMLS_CC); } | T_NAMESPACE T_NS_SEPARATOR namespace_name { $$.op_type = IS_CONST; ZVAL_EMPTY_STRING(&$$.u.constant); zend_do_build_namespace_name(&$$, &$$, &$3 TSRMLS_CC); $3 = $$; zend_do_fetch_constant(&$$, NULL, &$3, ZEND_CT, 0 TSRMLS_CC); } | T_NS_SEPARATOR namespace_name { char *tmp = estrndup(Z_STRVAL($2.u.constant), Z_STRLEN($2.u.constant)+1); memcpy(&(tmp[1]), Z_STRVAL($2.u.constant), Z_STRLEN($2.u.constant)+1); tmp[0] = '\\'; efree(Z_STRVAL($2.u.constant)); Z_STRVAL($2.u.constant) = tmp; ++Z_STRLEN($2.u.constant); zend_do_fetch_constant(&$$, NULL, &$2, ZEND_CT, 0 TSRMLS_CC); } @@ -959,6 +960,7 @@ static_class_constant: scalar: T_STRING_VARNAME { $$ = $1; } + | class_name_scalar { $$ = $1; } | class_constant { $$ = $1; } | namespace_name { zend_do_fetch_constant(&$$, NULL, &$1, ZEND_RT, 1 TSRMLS_CC); } | T_NAMESPACE T_NS_SEPARATOR namespace_name { $$.op_type = IS_CONST; ZVAL_EMPTY_STRING(&$$.u.constant); zend_do_build_namespace_name(&$$, &$$, &$3 TSRMLS_CC); $3 = $$; zend_do_fetch_constant(&$$, NULL, &$3, ZEND_RT, 0 TSRMLS_CC); } @@ -1200,6 +1202,14 @@ class_constant: | variable_class_name T_PAAMAYIM_NEKUDOTAYIM T_STRING { zend_do_fetch_constant(&$$, &$1, &$3, ZEND_RT, 0 TSRMLS_CC); } ; +static_class_name_scalar: + class_name T_PAAMAYIM_NEKUDOTAYIM T_CLASS { zend_do_resolve_class_name(&$$, &$1, 1 TSRMLS_CC); } +; + +class_name_scalar: + class_name T_PAAMAYIM_NEKUDOTAYIM T_CLASS { zend_do_resolve_class_name(&$$, &$1, 0 TSRMLS_CC); } +; + %% /* Copy to YYRES the contents of YYSTR after stripping away unnecessary diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 3f9cc126ed9b2..25ac453125c57 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -3563,6 +3563,9 @@ ZEND_VM_HANDLER(99, ZEND_FETCH_CONSTANT, VAR|CONST|UNUSED, CONST) } ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, *value); zval_copy_ctor(&EX_T(opline->result.var).tmp_var); + } else if (Z_STRLEN_P(opline->op2.zv) == sizeof("class")-1 && strcmp(Z_STRVAL_P(opline->op2.zv), "class") == 0) { + /* "class" is assigned as a case-sensitive keyword from zend_do_resolve_class_name */ + ZVAL_STRINGL(&EX_T(opline->result.var).tmp_var, ce->name, ce->name_length, 1); } else { zend_error_noreturn(E_ERROR, "Undefined class constant '%s'", Z_STRVAL_P(opline->op2.zv)); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 614249f9934a3..ab69ee292bdab 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -3731,6 +3731,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_CONST_CONST_HANDLER(ZEND_OPCO } ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, *value); zval_copy_ctor(&EX_T(opline->result.var).tmp_var); + } else if (Z_STRLEN_P(opline->op2.zv) == sizeof("class")-1 && strcmp(Z_STRVAL_P(opline->op2.zv), "class") == 0) { + /* "class" is assigned as a case-sensitive keyword from zend_do_resolve_class_name */ + ZVAL_STRINGL(&EX_T(opline->result.var).tmp_var, ce->name, ce->name_length, 1); } else { zend_error_noreturn(E_ERROR, "Undefined class constant '%s'", Z_STRVAL_P(opline->op2.zv)); } @@ -15595,6 +15598,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE } ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, *value); zval_copy_ctor(&EX_T(opline->result.var).tmp_var); + } else if (Z_STRLEN_P(opline->op2.zv) == sizeof("class")-1 && strcmp(Z_STRVAL_P(opline->op2.zv), "class") == 0) { + /* "class" is assigned as a case-sensitive keyword from zend_do_resolve_class_name */ + ZVAL_STRINGL(&EX_T(opline->result.var).tmp_var, ce->name, ce->name_length, 1); } else { zend_error_noreturn(E_ERROR, "Undefined class constant '%s'", Z_STRVAL_P(opline->op2.zv)); } @@ -25170,6 +25176,9 @@ static int ZEND_FASTCALL ZEND_FETCH_CONSTANT_SPEC_UNUSED_CONST_HANDLER(ZEND_OPC } ZVAL_COPY_VALUE(&EX_T(opline->result.var).tmp_var, *value); zval_copy_ctor(&EX_T(opline->result.var).tmp_var); + } else if (Z_STRLEN_P(opline->op2.zv) == sizeof("class")-1 && strcmp(Z_STRVAL_P(opline->op2.zv), "class") == 0) { + /* "class" is assigned as a case-sensitive keyword from zend_do_resolve_class_name */ + ZVAL_STRINGL(&EX_T(opline->result.var).tmp_var, ce->name, ce->name_length, 1); } else { zend_error_noreturn(E_ERROR, "Undefined class constant '%s'", Z_STRVAL_P(opline->op2.zv)); } From e23fca8910b96f1c3bb26c6582c17c92fd6f2f7a Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Fri, 18 Jan 2013 22:15:08 -0200 Subject: [PATCH 2293/2394] - Fixed ZTS build --- Zend/zend_compile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index b574ad6b69180..10eac2d94e1ce 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -2156,7 +2156,7 @@ void zend_do_resolve_class_name(znode *result, znode *class_name, int is_static zend_do_fetch_constant(result, class_name, &constant_name, ZEND_RT, 1 TSRMLS_CC); break; case ZEND_FETCH_CLASS_DEFAULT: - zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1); + zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); *result = *class_name; break; } From f7b99c481d0a943d922e99ad9afa82c45193030e Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sat, 19 Jan 2013 17:01:57 +0800 Subject: [PATCH 2294/2394] Fixed bug #64007 (There is an ability to create instance of Generator by hand). Use get_constrctor instead of access of the ce->constructor directly --- NEWS | 4 ++++ ext/reflection/php_reflection.c | 23 +++++++++++++++-------- ext/reflection/tests/bug64007.phpt | 10 ++++++++++ 3 files changed, 29 insertions(+), 8 deletions(-) create mode 100644 ext/reflection/tests/bug64007.phpt diff --git a/NEWS b/NEWS index 3bb0373d3b72d..89fcad3acf5ff 100644 --- a/NEWS +++ b/NEWS @@ -42,6 +42,10 @@ PHP NEWS . Bug #62489: dba_insert not working as expected. (marc-bennewitz at arcor dot de, Lars) +- Reflection: + . Fixed bug #64007 (There is an ability to create instance of Generator by hand). + (Laruence) + 18 Dec 2012, PHP 5.5.0 Alpha 2 - General improvements: diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index ff3a6a5087288..5c844b8d4dd51 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -4192,13 +4192,21 @@ ZEND_METHOD(reflection_class, newInstance) { zval *retval_ptr = NULL; reflection_object *intern; - zend_class_entry *ce; + zend_class_entry *ce, *old_scope; + zend_function *constructor; METHOD_NOTSTATIC(reflection_class_ptr); GET_REFLECTION_OBJECT_PTR(ce); + object_init_ex(return_value, ce); + + old_scope = EG(scope); + EG(scope) = ce; + constructor = Z_OBJ_HT_P(return_value)->get_constructor(return_value TSRMLS_CC); + EG(scope) = old_scope; + /* Run the constructor if there is one */ - if (ce->constructor) { + if (constructor) { zval ***params = NULL; int num_args = 0; zend_fcall_info fci; @@ -4206,18 +4214,18 @@ ZEND_METHOD(reflection_class, newInstance) if (!(ce->constructor->common.fn_flags & ZEND_ACC_PUBLIC)) { zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Access to non-public constructor of class %s", ce->name); - return; + zval_dtor(return_value); + RETURN_NULL(); } if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "*", ¶ms, &num_args) == FAILURE) { if (params) { efree(params); } + zval_dtor(return_value); RETURN_FALSE; } - object_init_ex(return_value, ce); - fci.size = sizeof(fci); fci.function_table = EG(function_table); fci.function_name = NULL; @@ -4242,6 +4250,7 @@ ZEND_METHOD(reflection_class, newInstance) zval_ptr_dtor(&retval_ptr); } php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invocation of %s's constructor failed", ce->name); + zval_dtor(return_value); RETURN_NULL(); } if (retval_ptr) { @@ -4250,9 +4259,7 @@ ZEND_METHOD(reflection_class, newInstance) if (params) { efree(params); } - } else if (!ZEND_NUM_ARGS()) { - object_init_ex(return_value, ce); - } else { + } else if (ZEND_NUM_ARGS()) { zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Class %s does not have a constructor, so you cannot pass any constructor arguments", ce->name); } } diff --git a/ext/reflection/tests/bug64007.phpt b/ext/reflection/tests/bug64007.phpt new file mode 100644 index 0000000000000..34aac7a61b151 --- /dev/null +++ b/ext/reflection/tests/bug64007.phpt @@ -0,0 +1,10 @@ +--TEST-- +Bug #64007 (There is an ability to create instance of Generator by hand) +--FILE-- +newInstance(); +var_dump($generator); +?> +--EXPECTF-- +Catchable fatal error: The "Generator" class is reserved for internal use and cannot be manually instantiated in %sbug64007.php on line %d From d78f5ababe4ce5503feead535308715f27727c50 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 22 Jan 2013 00:36:07 -0800 Subject: [PATCH 2295/2394] fix tests --- tests/classes/unset_properties.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/classes/unset_properties.phpt b/tests/classes/unset_properties.phpt index 7f9b569887dcd..264e720c9ec94 100644 --- a/tests/classes/unset_properties.phpt +++ b/tests/classes/unset_properties.phpt @@ -140,15 +140,15 @@ true new publicProperty value via public access protectedProperty set -__isset "protectedProperty"__isset "protectedProperty"false +__isset "protectedProperty"false __get "protectedProperty" __set "protectedProperty" to "new protectedProperty value via setter" __isset "protectedProperty"true new protectedProperty value via setter privateProperty set -__isset "privateProperty"__isset "privateProperty"false +__isset "privateProperty"false __get "privateProperty" __set "privateProperty" to "new privateProperty value via setter" __isset "privateProperty"true -new privateProperty value via setter \ No newline at end of file +new privateProperty value via setter From 03ff2b301ceb28f74d2ed965e14a0cf716e14d27 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 22 Jan 2013 09:35:24 +0100 Subject: [PATCH 2296/2394] Fix NEWS --- NEWS | 44 +++++++++++++++++++++++--------------------- 1 file changed, 23 insertions(+), 21 deletions(-) diff --git a/NEWS b/NEWS index 89fcad3acf5ff..656cccc5df99e 100644 --- a/NEWS +++ b/NEWS @@ -1,32 +1,12 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 201?, PHP 5.5.0 Alpha 3 +?? ??? 201?, PHP 5.5.0 Alpha 4 - Core: . Fixed bug #63980 (object members get trimmed by zero bytes). (Laruence) . Implemented RFC for Class Name Resolution As Scalar Via "class" Keyword. (Ralph Schindler, Nikita Popov, Lars) -- General improvements: - . Fixed bug #63874 (Segfault if php_strip_whitespace has heredoc). (Pierrick) - . Fixed bug #63822 (Crash when using closures with ArrayAccess). - (Nikita Popov) - . Add Generator::throw() method. (Nikita Popov) - . Bug #23955: allow specifying Max-Age attribute in setcookie() (narfbg, Lars) - . Bug #52126: timestamp for mail.log (Martin Jansen, Lars) - -- mysqlnd - . Fixed return value of mysqli_stmt_affected_rows() in the time after - prepare() and before execute(). (Andrey) - -- cURL: - . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror - curl_pause, curl_reset, curl_share_close, curl_share_init, - curl_share_setopt curl_strerror and curl_unescape. (Pierrick) - . Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION, - CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE, - CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick) - - DateTime . Added DateTimeImmutable - a variant of DateTime that only returns the modified state instead of changing itself. (Derick) @@ -46,6 +26,28 @@ PHP NEWS . Fixed bug #64007 (There is an ability to create instance of Generator by hand). (Laruence) +10 Jan 2013, PHP 5.5.0 Alpha 3 + +- General improvements: + . Fixed bug #63874 (Segfault if php_strip_whitespace has heredoc). (Pierrick) + . Fixed bug #63822 (Crash when using closures with ArrayAccess). + (Nikita Popov) + . Add Generator::throw() method. (Nikita Popov) + . Bug #23955: allow specifying Max-Age attribute in setcookie() (narfbg, Lars) + . Bug #52126: timestamp for mail.log (Martin Jansen, Lars) + +- mysqlnd + . Fixed return value of mysqli_stmt_affected_rows() in the time after + prepare() and before execute(). (Andrey) + +- cURL: + . Added new functions curl_escape, curl_multi_setopt, curl_multi_strerror + curl_pause, curl_reset, curl_share_close, curl_share_init, + curl_share_setopt curl_strerror and curl_unescape. (Pierrick) + . Addes new curl options CURLOPT_TELNETOPTIONS, CURLOPT_GSSAPI_DELEGATION, + CURLOPT_ACCEPTTIMEOUT_MS, CURLOPT_SSL_OPTIONS, CURLOPT_TCP_KEEPALIVE, + CURLOPT_TCP_KEEPIDLE and CURLOPT_TCP_KEEPINTVL. (Pierrick) + 18 Dec 2012, PHP 5.5.0 Alpha 2 - General improvements: From ca734cfbc7ef9f0738fa6ed3ba88fe611528881b Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 22 Jan 2013 09:37:02 +0100 Subject: [PATCH 2297/2394] NEWS for PHP 5.5.0alpha4 --- NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 656cccc5df99e..c93f328332cb0 100644 --- a/NEWS +++ b/NEWS @@ -1,6 +1,6 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 201?, PHP 5.5.0 Alpha 4 +24 Jan 2013, PHP 5.5.0 Alpha 4 - Core: . Fixed bug #63980 (object members get trimmed by zero bytes). (Laruence) From 51e5022364228fb55753902ea3ee63c27661e02c Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 22 Jan 2013 09:45:04 +0100 Subject: [PATCH 2298/2394] NEWS: Start PHP 5.5.0 Beta 1 section --- NEWS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/NEWS b/NEWS index c93f328332cb0..a8747f5d950f2 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,8 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| +?? ??? 201?, PHP 5.5.0 Beta 1 + + 24 Jan 2013, PHP 5.5.0 Alpha 4 - Core: From e6bde1f8f6d8b5d32e608926dd2af2e0f82a5de5 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 22 Jan 2013 16:58:40 +0800 Subject: [PATCH 2299/2394] Fix test related to change for #bug64007 and also fix in newInstanceArgs --- ext/pdo/pdo_stmt.c | 1 + ext/pdo/tests/pdo_036.phpt | 8 ++++---- ext/reflection/php_reflection.c | 31 ++++++++++++++++++------------ ext/reflection/tests/bug64007.phpt | 9 +++++++++ 4 files changed, 33 insertions(+), 16 deletions(-) diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c index a469d09fc2e34..5dc445ff8deb5 100644 --- a/ext/pdo/pdo_stmt.c +++ b/ext/pdo/pdo_stmt.c @@ -2733,6 +2733,7 @@ static union _zend_function *row_get_ctor(zval *object TSRMLS_DC) ctor.function_name = "__construct"; ctor.scope = pdo_row_ce; ctor.handler = ZEND_FN(dbstmt_constructor); + ctor.fn_flags = ZEND_ACC_PUBLIC; return (union _zend_function*)&ctor; } diff --git a/ext/pdo/tests/pdo_036.phpt b/ext/pdo/tests/pdo_036.phpt index 94006c9e808b6..55c88762ba3ea 100644 --- a/ext/pdo/tests/pdo_036.phpt +++ b/ext/pdo/tests/pdo_036.phpt @@ -5,19 +5,19 @@ Testing PDORow and PDOStatement instances with Reflection --FILE-- newInstance(); var_dump($x); -$instance = new reflectionclass('pdostatement'); +$instance = new reflectionclass('pdorow'); $x = $instance->newInstance(); var_dump($x); ?> --EXPECTF-- -object(PDORow)#%d (0) { -} object(PDOStatement)#%d (1) { [%u|b%"queryString"]=> NULL } + +Fatal error: PDORow::__construct(): You should not create a PDOStatement manually in %spdo_036.php on line %d diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 5c844b8d4dd51..15befa2fc725d 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -4212,7 +4212,7 @@ ZEND_METHOD(reflection_class, newInstance) zend_fcall_info fci; zend_fcall_info_cache fcc; - if (!(ce->constructor->common.fn_flags & ZEND_ACC_PUBLIC)) { + if (!(constructor->common.fn_flags & ZEND_ACC_PUBLIC)) { zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Access to non-public constructor of class %s", ce->name); zval_dtor(return_value); RETURN_NULL(); @@ -4237,7 +4237,7 @@ ZEND_METHOD(reflection_class, newInstance) fci.no_separation = 1; fcc.initialized = 1; - fcc.function_handler = ce->constructor; + fcc.function_handler = constructor; fcc.calling_scope = EG(scope); fcc.called_scope = Z_OBJCE_P(return_value); fcc.object_ptr = return_value; @@ -4289,9 +4289,10 @@ ZEND_METHOD(reflection_class, newInstanceArgs) { zval *retval_ptr = NULL; reflection_object *intern; - zend_class_entry *ce; + zend_class_entry *ce, *old_scope; int argc = 0; HashTable *args; + zend_function *constructor; METHOD_NOTSTATIC(reflection_class_ptr); @@ -4300,19 +4301,28 @@ ZEND_METHOD(reflection_class, newInstanceArgs) if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|h", &args) == FAILURE) { return; } + if (ZEND_NUM_ARGS() > 0) { argc = args->nNumOfElements; } + object_init_ex(return_value, ce); + + old_scope = EG(scope); + EG(scope) = ce; + constructor = Z_OBJ_HT_P(return_value)->get_constructor(return_value TSRMLS_CC); + EG(scope) = old_scope; + /* Run the constructor if there is one */ - if (ce->constructor) { + if (constructor) { zval ***params = NULL; zend_fcall_info fci; zend_fcall_info_cache fcc; - if (!(ce->constructor->common.fn_flags & ZEND_ACC_PUBLIC)) { + if (!(constructor->common.fn_flags & ZEND_ACC_PUBLIC)) { zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Access to non-public constructor of class %s", ce->name); - return; + zval_dtor(return_value); + RETURN_NULL(); } if (argc) { @@ -4321,8 +4331,6 @@ ZEND_METHOD(reflection_class, newInstanceArgs) params -= argc; } - object_init_ex(return_value, ce); - fci.size = sizeof(fci); fci.function_table = EG(function_table); fci.function_name = NULL; @@ -4334,7 +4342,7 @@ ZEND_METHOD(reflection_class, newInstanceArgs) fci.no_separation = 1; fcc.initialized = 1; - fcc.function_handler = ce->constructor; + fcc.function_handler = constructor; fcc.calling_scope = EG(scope); fcc.called_scope = Z_OBJCE_P(return_value); fcc.object_ptr = return_value; @@ -4347,6 +4355,7 @@ ZEND_METHOD(reflection_class, newInstanceArgs) zval_ptr_dtor(&retval_ptr); } php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invocation of %s's constructor failed", ce->name); + zval_dtor(return_value); RETURN_NULL(); } if (retval_ptr) { @@ -4355,9 +4364,7 @@ ZEND_METHOD(reflection_class, newInstanceArgs) if (params) { efree(params); } - } else if (!ZEND_NUM_ARGS() || !argc) { - object_init_ex(return_value, ce); - } else { + } else if (argc) { zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Class %s does not have a constructor, so you cannot pass any constructor arguments", ce->name); } } diff --git a/ext/reflection/tests/bug64007.phpt b/ext/reflection/tests/bug64007.phpt index 34aac7a61b151..32ec6a561078f 100644 --- a/ext/reflection/tests/bug64007.phpt +++ b/ext/reflection/tests/bug64007.phpt @@ -3,8 +3,17 @@ Bug #64007 (There is an ability to create instance of Generator by hand) --FILE-- newInstanceWithoutConstructor(); + var_dump($generator); +} catch (Exception $e) { + var_dump($e->getMessage()); +} + $generator = $reflection->newInstance(); var_dump($generator); ?> --EXPECTF-- +string(97) "Class Generator is an internal class that cannot be instantiated without invoking its constructor" + Catchable fatal error: The "Generator" class is reserved for internal use and cannot be manually instantiated in %sbug64007.php on line %d From 95346c017c55e44a3e3d19945902a0275d3fafe4 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Tue, 22 Jan 2013 16:48:39 +0100 Subject: [PATCH 2300/2394] fix valgrind warning --- ext/mysqlnd/mysqlnd_structs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index ecb1d89216965..b88004a9f11bc 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -195,7 +195,7 @@ typedef struct st_mysqlnd_net_options unsigned int timeout_read; unsigned int timeout_write; - unsigned int net_read_buffer_size; + size_t net_read_buffer_size; /* SSL information */ char *ssl_key; From bcf922b0f81194b364b019f4e1b5332068f25a67 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 22 Jan 2013 00:36:07 -0800 Subject: [PATCH 2301/2394] fix tests --- tests/classes/unset_properties.phpt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/classes/unset_properties.phpt b/tests/classes/unset_properties.phpt index 7f9b569887dcd..264e720c9ec94 100644 --- a/tests/classes/unset_properties.phpt +++ b/tests/classes/unset_properties.phpt @@ -140,15 +140,15 @@ true new publicProperty value via public access protectedProperty set -__isset "protectedProperty"__isset "protectedProperty"false +__isset "protectedProperty"false __get "protectedProperty" __set "protectedProperty" to "new protectedProperty value via setter" __isset "protectedProperty"true new protectedProperty value via setter privateProperty set -__isset "privateProperty"__isset "privateProperty"false +__isset "privateProperty"false __get "privateProperty" __set "privateProperty" to "new privateProperty value via setter" __isset "privateProperty"true -new privateProperty value via setter \ No newline at end of file +new privateProperty value via setter From 016c130f21ab667cd036affbc9f76b308b90f952 Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Thu, 24 Jan 2013 12:56:02 +0100 Subject: [PATCH 2302/2394] now we have also an xz archive --- README.RELEASE_PROCESS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.RELEASE_PROCESS b/README.RELEASE_PROCESS index 3fa944ee3b2ea..e725625297d8c 100644 --- a/README.RELEASE_PROCESS +++ b/README.RELEASE_PROCESS @@ -64,7 +64,7 @@ Do not use abbreviations for alpha and beta. ``git push --tags origin HEAD`` 8. run: ``./makedist 5.4.2RC2``, this will export the tree, create configure -and build two tarballs (one gz and one bz2). +and build three tarballs (gz,bz2 and xz). 9. Copy those two tarballs to www.php.net, in your homedir there should be a directory "downloads/". Copy them into there, so that the system can generate From 184db665ebdb6a2717d15e956391f6d88e1d05c6 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Sun, 27 Jan 2013 18:02:51 -0800 Subject: [PATCH 2303/2394] fix bug #60833 - self, parent, static behave inconsistently case-sensitive --- NEWS | 4 +- UPGRADING | 2 + Zend/tests/bug60833.phpt | 40 ++++++++ Zend/zend_compile.c | 196 +++++++++++++++++++-------------------- 4 files changed, 143 insertions(+), 99 deletions(-) create mode 100644 Zend/tests/bug60833.phpt diff --git a/NEWS b/NEWS index a8747f5d950f2..6cd007c0fb7d2 100644 --- a/NEWS +++ b/NEWS @@ -1,7 +1,9 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 201?, PHP 5.5.0 Beta 1 - +- Core: + . Fixed bug # 60833 (self, parent, static behave inconsistently + case-sensitive). (Stas, mario at include-once dot org) 24 Jan 2013, PHP 5.5.0 Alpha 4 diff --git a/UPGRADING b/UPGRADING index 6c53084cdd2f1..1d2cebf02a4f7 100755 --- a/UPGRADING +++ b/UPGRADING @@ -24,6 +24,8 @@ PHP 5.5 UPGRADE NOTES - Drop Windows XP and 2003 support. (Pierre) - All internal case insensitivity handling for class, function and constant names is done according to ASCII rules, current locale settings are ignored. +- self, parent & static keywords now are always case-insensitive (see bug + #60833). - php_logo_guid(), php_egg_logo_guid(), php_real_logo_guid() and zend_logo_guid() have been removed - Removal of Logo GUIDs diff --git a/Zend/tests/bug60833.phpt b/Zend/tests/bug60833.phpt new file mode 100644 index 0000000000000..deb6c0f691603 --- /dev/null +++ b/Zend/tests/bug60833.phpt @@ -0,0 +1,40 @@ +--TEST-- +Bug #60833 (self, parent, static behave inconsistently case-sensitive) +--FILE-- +v1 = new sELF; + $this->v2 = new SELF; + } +} + +class B extends A { + static $x = "B"; + function testit() { + PARENT::testit(); + $this->v3 = new sELF; + $this->v4 = new PARENT; + $this->v4 = STATIC::$x; + } +} +$t = new B(); +$t->testit(); +var_dump($t); +?> +--EXPECTF-- +object(B)#%d (4) { + ["v1"]=> + object(A)#%d (0) { + } + ["v2"]=> + object(A)#%d (0) { + } + ["v3"]=> + object(B)#%d (0) { + } + ["v4"]=> + string(1) "B" +} + diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index 10eac2d94e1ce..1a8d10890060b 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -5,7 +5,7 @@ | Copyright (c) 1998-2013 Zend Technologies Ltd. (http://www.zend.com) | +----------------------------------------------------------------------+ | This source file is subject to version 2.00 of the Zend license, | - | that is bundled with this package in the file LICENSE, and is | + | that is bundled with this package in the file LICENSE, and is | | available through the world-wide-web at the following url: | | http://www.zend.com/license/2_00.txt. | | If you did not receive a copy of the Zend license and are unable to | @@ -107,7 +107,7 @@ ZEND_API zend_executor_globals executor_globals; static void zend_duplicate_property_info(zend_property_info *property_info) /* {{{ */ { - if (!IS_INTERNED(property_info->name)) { + if (!IS_INTERNED(property_info->name)) { property_info->name = estrndup(property_info->name, property_info->name_length); } if (property_info->doc_comment) { @@ -118,7 +118,7 @@ static void zend_duplicate_property_info(zend_property_info *property_info) /* { static void zend_duplicate_property_info_internal(zend_property_info *property_info) /* {{{ */ { - if (!IS_INTERNED(property_info->name)) { + if (!IS_INTERNED(property_info->name)) { property_info->name = zend_strndup(property_info->name, property_info->name_length); } } @@ -383,7 +383,7 @@ int zend_add_func_name_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC zval c; int lc_literal; - if (op_array->last_literal > 0 && + if (op_array->last_literal > 0 && &op_array->literals[op_array->last_literal - 1].constant == zv && op_array->literals[op_array->last_literal - 1].cache_slot == -1) { /* we already have function name as last literal (do nothing) */ @@ -391,7 +391,7 @@ int zend_add_func_name_literal(zend_op_array *op_array, const zval *zv TSRMLS_DC } else { ret = zend_add_literal(op_array, zv TSRMLS_CC); } - + lc_name = zend_str_tolower_dup(Z_STRVAL_P(zv), Z_STRLEN_P(zv)); ZVAL_STRINGL(&c, lc_name, Z_STRLEN_P(zv), 0); lc_literal = zend_add_literal(CG(active_op_array), &c TSRMLS_CC); @@ -410,7 +410,7 @@ int zend_add_ns_func_name_literal(zend_op_array *op_array, const zval *zv TSRMLS zval c; int lc_literal; - if (op_array->last_literal > 0 && + if (op_array->last_literal > 0 && &op_array->literals[op_array->last_literal - 1].constant == zv && op_array->literals[op_array->last_literal - 1].cache_slot == -1) { /* we already have function name as last literal (do nothing) */ @@ -443,7 +443,7 @@ int zend_add_class_name_literal(zend_op_array *op_array, const zval *zv TSRMLS_D zval c; int lc_literal; - if (op_array->last_literal > 0 && + if (op_array->last_literal > 0 && &op_array->literals[op_array->last_literal - 1].constant == zv && op_array->literals[op_array->last_literal - 1].cache_slot == -1) { /* we already have function name as last literal (do nothing) */ @@ -477,7 +477,7 @@ int zend_add_const_name_literal(zend_op_array *op_array, const zval *zv, int unq int name_len, ns_len; zval c; - if (op_array->last_literal > 0 && + if (op_array->last_literal > 0 && &op_array->literals[op_array->last_literal - 1].constant == zv && op_array->literals[op_array->last_literal - 1].cache_slot == -1) { /* we already have function name as last literal (do nothing) */ @@ -486,7 +486,7 @@ int zend_add_const_name_literal(zend_op_array *op_array, const zval *zv, int unq ret = zend_add_literal(op_array, zv TSRMLS_CC); } - /* skip leading '\\' */ + /* skip leading '\\' */ if (Z_STRVAL_P(zv)[0] == '\\') { name_len = Z_STRLEN_P(zv) - 1; name = Z_STRVAL_P(zv) + 1; @@ -816,7 +816,7 @@ void fetch_array_dim(znode *result, const znode *parent, const znode *dim TSRMLS opline.result.var = opline.op1.var; zend_llist_add_element(fetch_list_ptr, &opline); } - + init_op(&opline TSRMLS_CC); opline.opcode = ZEND_FETCH_DIM_W; /* the backpatching routine assumes W */ opline.result_type = IS_VAR; @@ -830,12 +830,12 @@ void fetch_array_dim(znode *result, const znode *parent, const znode *dim TSRMLS ZEND_HANDLE_NUMERIC_EX(Z_STRVAL(CONSTANT(opline.op2.constant)), Z_STRLEN(CONSTANT(opline.op2.constant))+1, index, numeric = 1); if (numeric) { zval_dtor(&CONSTANT(opline.op2.constant)); - ZVAL_LONG(&CONSTANT(opline.op2.constant), index); + ZVAL_LONG(&CONSTANT(opline.op2.constant), index); } else { CALCULATE_LITERAL_HASH(opline.op2.constant); } } - + GET_NODE(result, opline.result); zend_llist_add_element(fetch_list_ptr, &opline); @@ -940,7 +940,7 @@ void zend_do_assign(znode *result, znode *variable, znode *value TSRMLS_DC) /* { opline->result.var = get_temporary_variable(CG(active_op_array)); opline->op1_type = IS_CONST; LITERAL_STRINGL(opline->op1, - CG(active_op_array)->vars[value->u.op.var].name, + CG(active_op_array)->vars[value->u.op.var].name, CG(active_op_array)->vars[value->u.op.var].name_len, 1); CALCULATE_LITERAL_HASH(opline->op1.constant); SET_UNUSED(opline->op2); @@ -1569,7 +1569,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n if (is_method) { int result; - + lcname = zend_new_interned_string(zend_str_tolower_dup(name, name_len), name_len + 1, 1 TSRMLS_CC); if (IS_INTERNED(lcname)) { @@ -1624,7 +1624,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n } } else { char *class_lcname; - + class_lcname = do_alloca(CG(active_class_entry)->name_length + 1, use_heap); zend_str_tolower_copy(class_lcname, CG(active_class_entry)->name, CG(active_class_entry)->name_length); /* Improve after RC: cache the lowercase class name */ @@ -1675,7 +1675,7 @@ void zend_do_begin_function_declaration(znode *function_token, znode *function_n } else if ((name_len == sizeof(ZEND_TOSTRING_FUNC_NAME)-1) && (!memcmp(lcname, ZEND_TOSTRING_FUNC_NAME, sizeof(ZEND_TOSTRING_FUNC_NAME)-1))) { if (fn_flags & ((ZEND_ACC_PPP_MASK | ZEND_ACC_STATIC) ^ ZEND_ACC_PUBLIC)) { zend_error(E_WARNING, "The magic method __toString() must have public visibility and cannot be static"); - } + } CG(active_class_entry)->__tostring = (zend_function *) CG(active_op_array); } else if (!(fn_flags & ZEND_ACC_STATIC)) { CG(active_op_array)->fn_flags |= ZEND_ACC_ALLOW_STATIC; @@ -1806,14 +1806,14 @@ void zend_do_end_function_declaration(const znode *function_token TSRMLS_DC) /* if (CG(active_class_entry)) { zend_check_magic_method_implementation(CG(active_class_entry), (zend_function*)CG(active_op_array), E_COMPILE_ERROR TSRMLS_CC); } else { - /* we don't care if the function name is longer, in fact lowercasing only + /* we don't care if the function name is longer, in fact lowercasing only * the beginning of the name speeds up the check process */ name_len = strlen(CG(active_op_array)->function_name); zend_str_tolower_copy(lcname, CG(active_op_array)->function_name, MIN(name_len, sizeof(lcname)-1)); lcname[sizeof(lcname)-1] = '\0'; /* zend_str_tolower_copy won't necessarily set the zero byte */ if (name_len == sizeof(ZEND_AUTOLOAD_FUNC_NAME) - 1 && !memcmp(lcname, ZEND_AUTOLOAD_FUNC_NAME, sizeof(ZEND_AUTOLOAD_FUNC_NAME)) && CG(active_op_array)->num_args != 1) { zend_error(E_COMPILE_ERROR, "%s() must take exactly 1 argument", ZEND_AUTOLOAD_FUNC_NAME); - } + } } CG(active_op_array)->line_end = zend_get_compiled_lineno(TSRMLS_C); @@ -1939,7 +1939,7 @@ int zend_do_begin_function_call(znode *function_name, zend_bool check_namespace internal function with short name */ zend_do_begin_dynamic_function_call(function_name, 1 TSRMLS_CC); return 1; - } + } lcname = zend_str_tolower_dup(function_name->u.constant.value.str.val, function_name->u.constant.value.str.len); if ((zend_hash_find(CG(function_table), lcname, function_name->u.constant.value.str.len+1, (void **) &function)==FAILURE) || @@ -1948,10 +1948,10 @@ int zend_do_begin_function_call(znode *function_name, zend_bool check_namespace zend_do_begin_dynamic_function_call(function_name, 0 TSRMLS_CC); efree(lcname); return 1; /* Dynamic */ - } + } efree(function_name->u.constant.value.str.val); function_name->u.constant.value.str.val = lcname; - + zend_stack_push(&CG(function_call_stack), (void *) &function, sizeof(zend_function *)); if (CG(context).nested_calls + 1 > CG(active_op_array)->nested_calls) { CG(active_op_array)->nested_calls = CG(context).nested_calls + 1; @@ -1984,7 +1984,7 @@ void zend_do_begin_method_call(znode *left_bracket TSRMLS_DC) /* {{{ */ name = CONSTANT(last_op->op2.constant); if (Z_TYPE(name) != IS_STRING) { zend_error(E_COMPILE_ERROR, "Method name must be a string"); - } + } if (!IS_INTERNED(Z_STRVAL(name))) { Z_STRVAL(name) = estrndup(Z_STRVAL(name), Z_STRLEN(name)); } @@ -2188,7 +2188,7 @@ void zend_resolve_class_name(znode *class_name, ulong fetch_type, int check_ns_n if (ZEND_FETCH_CLASS_DEFAULT != zend_get_class_fetch_type(Z_STRVAL(class_name->u.constant), Z_STRLEN(class_name->u.constant))) { zend_error(E_COMPILE_ERROR, "'\\%s' is an invalid class name", Z_STRVAL(class_name->u.constant)); } - } else { + } else { if (CG(current_import)) { len = compound - Z_STRVAL(class_name->u.constant); lcname = zend_str_tolower_dup(Z_STRVAL(class_name->u.constant), len); @@ -2553,8 +2553,8 @@ void zend_do_pass_param(znode *param, zend_uchar op, int offset TSRMLS_DC) /* {{ zend_error(E_COMPILE_ERROR, "Call-time pass-by-reference has been removed"); } return; - } - + } + if (function_ptr) { if (ARG_MAY_BE_SENT_BY_REF(function_ptr, (zend_uint) offset)) { if (param->op_type & (IS_VAR|IS_CV) && original_op != ZEND_SEND_VAL) { @@ -2725,7 +2725,7 @@ void zend_do_return(znode *expr, int do_end_vparse TSRMLS_DC) /* {{{ */ SET_UNUSED(opline->op1); SET_UNUSED(opline->op2); } - + opline = get_next_op(CG(active_op_array) TSRMLS_CC); opline->opcode = returns_reference ? ZEND_RETURN_BY_REF : ZEND_RETURN; @@ -2940,10 +2940,10 @@ void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_to { if (catch_token->op_type == IS_UNUSED && finally_token->op_type == IS_UNUSED) { zend_error(E_COMPILE_ERROR, "Cannot use try without catch or finally"); - } + } if (finally_token->op_type != IS_UNUSED) { zend_op *opline; - + CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_op = finally_token->u.op.opline_num + 1; CG(active_op_array)->try_catch_array[try_token->u.op.opline_num].finally_end = get_next_op_number(CG(active_op_array)); CG(active_op_array)->has_finally_block = 1; @@ -2952,11 +2952,11 @@ void zend_do_end_finally(znode *try_token, znode* catch_token, znode *finally_to opline->opcode = ZEND_FAST_RET; SET_UNUSED(opline->op1); SET_UNUSED(opline->op2); - + CG(active_op_array)->opcodes[finally_token->u.op.opline_num].op1.opline_num = get_next_op_number(CG(active_op_array)); CG(context).in_finally--; - } + } } /* }}} */ @@ -3063,7 +3063,7 @@ static void do_inherit_parent_constructor(zend_class_entry *ce) /* {{{ */ lc_class_name = zend_str_tolower_dup(ce->name, ce->name_length); if (!zend_hash_exists(&ce->function_table, lc_class_name, ce->name_length+1)) { lc_parent_class_name = zend_str_tolower_dup(ce->parent->name, ce->parent->name_length); - if (!zend_hash_exists(&ce->function_table, lc_parent_class_name, ce->parent->name_length+1) && + if (!zend_hash_exists(&ce->function_table, lc_parent_class_name, ce->parent->name_length+1) && zend_hash_find(&ce->parent->function_table, lc_parent_class_name, ce->parent->name_length+1, (void **)&function)==SUCCESS) { if (function->common.fn_flags & ZEND_ACC_CTOR) { /* inherit parent's constructor */ @@ -3202,8 +3202,8 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c return 0; } } - } - } + } + } if (fe->common.arg_info[i].type_hint != proto->common.arg_info[i].type_hint) { /* Incompatible type hint */ return 0; @@ -3232,7 +3232,7 @@ static zend_bool zend_do_perform_implementation_check(const zend_function *fe, c buf = erealloc(buf, length); \ } -static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{{ */ +static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{{ */ { char *offset, *buf; zend_uint length = 1024; @@ -3249,7 +3249,7 @@ static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{ *(offset++) = ':'; *(offset++) = ':'; } - + { size_t name_len = strlen(fptr->common.function_name); REALLOC_BUF_IF_EXCEED(buf, offset, length, name_len); @@ -3290,7 +3290,7 @@ static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{ offset += type_name_len; *(offset++) = ' '; } - + if (arg_info->pass_by_reference) { *(offset++) = '&'; } @@ -3392,7 +3392,7 @@ static char * zend_get_function_declaration(zend_function *fptr TSRMLS_DC) /* {{ *offset = '\0'; return buf; -} +} /* }}} */ static void do_inheritance_check_on_method(zend_function *child, zend_function *parent TSRMLS_DC) /* {{{ */ @@ -3404,7 +3404,7 @@ static void do_inheritance_check_on_method(zend_function *child, zend_function * && parent->common.fn_flags & ZEND_ACC_ABSTRACT && parent->common.scope != (child->common.prototype ? child->common.prototype->common.scope : child->common.scope) && child->common.fn_flags & (ZEND_ACC_ABSTRACT|ZEND_ACC_IMPLEMENTED_ABSTRACT)) { - zend_error(E_COMPILE_ERROR, "Can't inherit abstract function %s::%s() (previously declared abstract in %s)", + zend_error(E_COMPILE_ERROR, "Can't inherit abstract function %s::%s() (previously declared abstract in %s)", parent->common.scope->name, child->common.function_name, child->common.prototype ? child->common.prototype->common.scope->name : child->common.scope->name); @@ -3444,7 +3444,7 @@ static void do_inheritance_check_on_method(zend_function *child, zend_function * } if (parent_flags & ZEND_ACC_PRIVATE) { - child->common.prototype = NULL; + child->common.prototype = NULL; } else if (parent_flags & ZEND_ACC_ABSTRACT) { child->common.fn_flags |= ZEND_ACC_IMPLEMENTED_ABSTRACT; child->common.prototype = parent; @@ -3455,12 +3455,12 @@ static void do_inheritance_check_on_method(zend_function *child, zend_function * if (child->common.prototype && (child->common.prototype->common.fn_flags & ZEND_ACC_ABSTRACT)) { if (!zend_do_perform_implementation_check(child, child->common.prototype TSRMLS_CC)) { - zend_error(E_COMPILE_ERROR, "Declaration of %s::%s() must be compatible with %s", ZEND_FN_SCOPE_NAME(child), child->common.function_name, zend_get_function_declaration(child->common.prototype? child->common.prototype : parent TSRMLS_CC)); + zend_error(E_COMPILE_ERROR, "Declaration of %s::%s() must be compatible with %s", ZEND_FN_SCOPE_NAME(child), child->common.function_name, zend_get_function_declaration(child->common.prototype? child->common.prototype : parent TSRMLS_CC)); } } else if (EG(error_reporting) & E_STRICT || EG(user_error_handler)) { /* Check E_STRICT (or custom error handler) before the check so that we save some time */ if (!zend_do_perform_implementation_check(child, parent TSRMLS_CC)) { char *method_prototype = zend_get_function_declaration(child->common.prototype? child->common.prototype : parent TSRMLS_CC); - zend_error(E_STRICT, "Declaration of %s::%s() should be compatible with %s", ZEND_FN_SCOPE_NAME(child), child->common.function_name, method_prototype); + zend_error(E_STRICT, "Declaration of %s::%s() should be compatible with %s", ZEND_FN_SCOPE_NAME(child), child->common.function_name, method_prototype); efree(method_prototype); } } @@ -3479,9 +3479,9 @@ static zend_bool do_inherit_method_check(HashTable *child_function_table, zend_f } return 1; /* method doesn't exist in child, copy from parent */ } - + do_inheritance_check_on_method(child, parent TSRMLS_CC); - + return 0; } /* }}} */ @@ -3512,7 +3512,7 @@ static zend_bool do_inherit_property_access_check(HashTable *target_ht, zend_pro zend_error(E_COMPILE_ERROR, "Cannot redeclare %s%s::$%s as %s%s::$%s", (parent_info->flags & ZEND_ACC_STATIC) ? "static " : "non static ", parent_ce->name, hash_key->arKey, (child_info->flags & ZEND_ACC_STATIC) ? "static " : "non static ", ce->name, hash_key->arKey); - + } if(parent_info->flags & ZEND_ACC_CHANGED) { @@ -3778,10 +3778,10 @@ ZEND_API void zend_do_implement_interface(zend_class_entry *ce, zend_class_entry } } ce->interfaces[ce->num_interfaces++] = iface; - + zend_hash_merge_ex(&ce->constants_table, &iface->constants_table, (copy_ctor_func_t) zval_add_ref, sizeof(zval *), (merge_checker_func_t) do_inherit_constant_check, iface); zend_hash_merge_ex(&ce->function_table, &iface->function_table, (copy_ctor_func_t) do_inherit_method, sizeof(zend_function), (merge_checker_func_t) do_inherit_method_check, ce); - + do_implement_interface(ce, iface TSRMLS_CC); zend_do_inherit_interfaces(ce, iface TSRMLS_CC); } @@ -3821,10 +3821,10 @@ static zend_bool zend_traits_method_compatibility_check(zend_function *fn, zend_ { zend_uint fn_flags = fn->common.scope->ce_flags; zend_uint other_flags = other_fn->common.scope->ce_flags; - + return zend_do_perform_implementation_check(fn, other_fn TSRMLS_CC) && zend_do_perform_implementation_check(other_fn, fn TSRMLS_CC) - && ((fn_flags & (ZEND_ACC_FINAL|ZEND_ACC_STATIC)) == + && ((fn_flags & (ZEND_ACC_FINAL|ZEND_ACC_STATIC)) == (other_flags & (ZEND_ACC_FINAL|ZEND_ACC_STATIC))); /* equal final and static qualifier */ } /* }}} */ @@ -3837,7 +3837,7 @@ static void zend_add_magic_methods(zend_class_entry* ce, const char* mname, uint if (ce->constructor) { zend_error(E_COMPILE_ERROR, "%s has colliding constructor definitions coming from traits", ce->name); } - ce->constructor = fe; fe->common.fn_flags |= ZEND_ACC_CTOR; + ce->constructor = fe; fe->common.fn_flags |= ZEND_ACC_CTOR; } else if (!strncmp(mname, ZEND_DESTRUCTOR_FUNC_NAME, mname_len)) { ce->destructor = fe; fe->common.fn_flags |= ZEND_ACC_DTOR; } else if (!strncmp(mname, ZEND_GET_FUNC_NAME, mname_len)) { @@ -3974,7 +3974,7 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, ce = va_arg(args, zend_class_entry*); overriden = va_arg(args, HashTable**); exclude_table = va_arg(args, HashTable*); - + fnname_len = strlen(fn->common.function_name); /* apply aliases which are qualified with a class name, there should not be any ambiguity */ @@ -3988,9 +3988,9 @@ static int zend_traits_copy_functions(zend_function *fn TSRMLS_DC, int num_args, && alias->trait_method->mname_len == fnname_len && (zend_binary_strcasecmp(alias->trait_method->method_name, alias->trait_method->mname_len, fn->common.function_name, fnname_len) == 0)) { fn_copy = *fn; - + /* if it is 0, no modifieres has been changed */ - if (alias->modifiers) { + if (alias->modifiers) { fn_copy.common.fn_flags = alias->modifiers | (fn->common.fn_flags ^ (fn->common.fn_flags & ZEND_ACC_PPP_MASK)); } @@ -4093,7 +4093,7 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* cur_method_ref->ce->name, cur_method_ref->method_name); } - + /** With the other traits, we are more permissive. We do not give errors for those. This allows to be more defensive in such definitions. @@ -4107,20 +4107,20 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* if (!(cur_precedence->exclude_from_classes[j] = zend_fetch_class(class_name, name_length, ZEND_FETCH_CLASS_TRAIT |ZEND_FETCH_CLASS_NO_AUTOLOAD TSRMLS_CC))) { zend_error(E_COMPILE_ERROR, "Could not find trait %s", class_name); - } + } zend_check_trait_usage(ce, cur_precedence->exclude_from_classes[j] TSRMLS_CC); /* make sure that the trait method is not from a class mentioned in exclude_from_classes, for consistency */ if (cur_precedence->trait_method->ce == cur_precedence->exclude_from_classes[i]) { zend_error(E_COMPILE_ERROR, - "Inconsistent insteadof definition. " + "Inconsistent insteadof definition. " "The method %s is to be used from %s, but %s is also on the exclude list", cur_method_ref->method_name, cur_precedence->trait_method->ce->name, cur_precedence->trait_method->ce->name); } - + efree(class_name); j++; } @@ -4160,7 +4160,7 @@ static void zend_traits_init_trait_structures(zend_class_entry *ce TSRMLS_DC) /* static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_trait_precedence **precedences, zend_class_entry *trait) /* {{{ */ { size_t i = 0, j; - + if (!precedences) { return; } @@ -4171,7 +4171,7 @@ static void zend_traits_compile_exclude_table(HashTable* exclude_table, zend_tra if (precedences[i]->exclude_from_classes[j] == trait) { zend_uint lcname_len = precedences[i]->trait_method->mname_len; char *lcname = zend_str_tolower_dup(precedences[i]->trait_method->method_name, lcname_len); - + if (zend_hash_add(exclude_table, lcname, lcname_len, NULL, 0, NULL) == FAILURE) { efree(lcname); zend_error(E_COMPILE_ERROR, "Failed to evaluate a trait precedence (%s). Method of trait %s was defined to be excluded multiple times", precedences[i]->trait_method->method_name, trait->name); @@ -4208,7 +4208,7 @@ static void zend_do_traits_method_binding(zend_class_entry *ce TSRMLS_DC) /* {{{ zend_hash_apply_with_arguments(&ce->traits[i]->function_table TSRMLS_CC, (apply_func_args_t)zend_traits_copy_functions, 3, ce, &overriden, NULL); } } - + zend_hash_apply_with_argument(&ce->function_table, (apply_func_arg_t)zend_fixup_trait_method, ce TSRMLS_CC); if (overriden) { @@ -4246,7 +4246,7 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { const char* class_name_unused; zend_bool not_compatible; zval* prop_value; - char* doc_comment; + char* doc_comment; zend_uint flags; /* In the following steps the properties are inserted into the property table @@ -4275,10 +4275,10 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { /* next: check for conflicts with current class */ if (zend_hash_quick_find(&ce->properties_info, prop_name, prop_name_length+1, prop_hash, (void **) &coliding_prop) == SUCCESS) { - if (coliding_prop->flags & ZEND_ACC_SHADOW) { + if (coliding_prop->flags & ZEND_ACC_SHADOW) { zend_hash_quick_del(&ce->properties_info, prop_name, prop_name_length+1, prop_hash); flags |= ZEND_ACC_CHANGED; - } else { + } else { if ((coliding_prop->flags & (ZEND_ACC_PPP_MASK | ZEND_ACC_STATIC)) == (flags & (ZEND_ACC_PPP_MASK | ZEND_ACC_STATIC))) { /* flags are identical, now the value needs to be checked */ @@ -4299,14 +4299,14 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { } if (not_compatible) { - zend_error(E_COMPILE_ERROR, + zend_error(E_COMPILE_ERROR, "%s and %s define the same property ($%s) in the composition of %s. However, the definition differs and is considered incompatible. Class was composed", find_first_definition(ce, i, prop_name, prop_name_length, prop_hash, coliding_prop->ce)->name, property_info->ce->name, prop_name, ce->name); } else { - zend_error(E_STRICT, + zend_error(E_STRICT, "%s and %s define the same property ($%s) in the composition of %s. This might be incompatible, to improve maintainability consider using accessor methods in traits instead. Class was composed", find_first_definition(ce, i, prop_name, prop_name_length, prop_hash, coliding_prop->ce)->name, property_info->ce->name, @@ -4326,8 +4326,8 @@ static void zend_do_traits_property_binding(zend_class_entry *ce TSRMLS_DC) /* { Z_ADDREF_P(prop_value); doc_comment = property_info->doc_comment ? estrndup(property_info->doc_comment, property_info->doc_comment_len) : NULL; - zend_declare_property_ex(ce, prop_name, prop_name_length, - prop_value, flags, + zend_declare_property_ex(ce, prop_name, prop_name_length, + prop_value, flags, doc_comment, property_info->doc_comment_len TSRMLS_CC); } } @@ -4339,7 +4339,7 @@ static void zend_do_check_for_inconsistent_traits_aliasing(zend_class_entry *ce int i = 0; zend_trait_alias* cur_alias; char* lc_method_name; - + if (ce->trait_aliases) { while (ce->trait_aliases[i]) { cur_alias = ce->trait_aliases[i]; @@ -4360,7 +4360,7 @@ static void zend_do_check_for_inconsistent_traits_aliasing(zend_class_entry *ce we check against it and abort. 2) it is just a plain old inconsitency/typo/bug as in the case where alias is set. */ - + lc_method_name = zend_str_tolower_dup(cur_alias->trait_method->method_name, cur_alias->trait_method->mname_len); if (zend_hash_exists(&ce->function_table, @@ -4397,7 +4397,7 @@ ZEND_API void zend_do_bind_traits(zend_class_entry *ce TSRMLS_DC) /* {{{ */ /* first care about all methods to be flattened into the class */ zend_do_traits_method_binding(ce TSRMLS_CC); - + /* Aliases which have not been applied indicate typos/bugs. */ zend_do_check_for_inconsistent_traits_aliasing(ce TSRMLS_CC); @@ -4406,7 +4406,7 @@ ZEND_API void zend_do_bind_traits(zend_class_entry *ce TSRMLS_DC) /* {{{ */ /* verify that all abstract methods from traits have been implemented */ zend_verify_abstract_class(ce TSRMLS_CC); - + /* now everything should be fine and an added ZEND_ACC_IMPLICIT_ABSTRACT_CLASS should be removed */ if (ce->ce_flags & ZEND_ACC_IMPLICIT_ABSTRACT_CLASS) { ce->ce_flags -= ZEND_ACC_IMPLICIT_ABSTRACT_CLASS; @@ -4456,7 +4456,7 @@ void zend_prepare_reference(znode *result, znode *class_name, znode *method_name zend_trait_method_reference *method_ref = emalloc(sizeof(zend_trait_method_reference)); method_ref->ce = NULL; - /* REM: There should not be a need for copying, + /* REM: There should not be a need for copying, zend_do_begin_class_declaration is also just using that string */ if (class_name) { zend_resolve_class_name(class_name, ZEND_FETCH_CLASS_GLOBAL, 1 TSRMLS_CC); @@ -5030,7 +5030,7 @@ void zend_do_begin_class_declaration(const znode *class_token, znode *class_name build_runtime_defined_function_key(&key, lcname, new_class_entry->name_length TSRMLS_CC); opline->op1.constant = zend_add_literal(CG(active_op_array), &key TSRMLS_CC); Z_HASH_P(&CONSTANT(opline->op1.constant)) = zend_hash_func(Z_STRVAL(CONSTANT(opline->op1.constant)), Z_STRLEN(CONSTANT(opline->op1.constant))); - + opline->op2_type = IS_CONST; if (doing_inheritance) { @@ -5047,7 +5047,7 @@ void zend_do_begin_class_declaration(const znode *class_token, znode *class_name LITERAL_STRINGL(opline->op2, lcname, new_class_entry->name_length, 0); CALCULATE_LITERAL_HASH(opline->op2.constant); - + zend_hash_quick_update(CG(class_table), Z_STRVAL(key), Z_STRLEN(key), Z_HASH_P(&CONSTANT(opline->op1.constant)), &new_class_entry, sizeof(zend_class_entry *), NULL); CG(active_class_entry) = new_class_entry; @@ -5098,7 +5098,7 @@ void zend_do_end_class_declaration(const znode *class_token, const znode *parent } ce->info.user.line_end = zend_get_compiled_lineno(TSRMLS_C); - + /* Check for traits and proceed like with interfaces. * The only difference will be a combined handling of them in the end. * Thus, we need another opcode here. */ @@ -5123,7 +5123,7 @@ void zend_do_end_class_declaration(const znode *class_token, const znode *parent } } /* Inherit interfaces; reset number to zero, we need it for above check and - * will restore it during actual implementation. + * will restore it during actual implementation. * The ZEND_ACC_IMPLEMENT_INTERFACES flag disables double call to * zend_verify_abstract_class() */ if (ce->num_interfaces > 0) { @@ -5325,7 +5325,7 @@ void zend_do_declare_class_constant(znode *var_name, const znode *value TSRMLS_D ALLOC_ZVAL(property); *property = value->u.constant; - + cname = zend_new_interned_string(var_name->u.constant.value.str.val, var_name->u.constant.value.str.len+1, 0 TSRMLS_CC); if (IS_INTERNED(cname)) { @@ -5338,7 +5338,7 @@ void zend_do_declare_class_constant(znode *var_name, const znode *value TSRMLS_D zend_error(E_COMPILE_ERROR, "Cannot redefine class constant %s::%s", CG(active_class_entry)->name, var_name->u.constant.value.str.val); } FREE_PNODE(var_name); - + if (CG(doc_comment)) { efree(CG(doc_comment)); CG(doc_comment) = NULL; @@ -5427,17 +5427,17 @@ void zend_do_halt_compiler_register(TSRMLS_D) /* {{{ */ char *name, *cfilename; char haltoff[] = "__COMPILER_HALT_OFFSET__"; int len, clen; - + if (CG(has_bracketed_namespaces) && CG(in_namespace)) { zend_error(E_COMPILE_ERROR, "__HALT_COMPILER() can only be used from the outermost scope"); } - + cfilename = zend_get_compiled_filename(TSRMLS_C); clen = strlen(cfilename); zend_mangle_property_name(&name, &len, haltoff, sizeof(haltoff) - 1, cfilename, clen, 0); zend_register_long_constant(name, len+1, zend_get_scanned_file_offset(TSRMLS_C), CONST_CS, 0 TSRMLS_CC); pefree(name, 0); - + if (CG(in_namespace)) { zend_do_end_namespace(TSRMLS_C); } @@ -5514,7 +5514,7 @@ static zend_constant* zend_get_ct_const(const zval *const_name, int all_internal } } else if (zend_hash_find(EG(zend_constants), Z_STRVAL_P(const_name), Z_STRLEN_P(const_name)+1, (void **) &c) == FAILURE) { char *lookup_name = zend_str_tolower_dup(Z_STRVAL_P(const_name), Z_STRLEN_P(const_name)); - + if (zend_hash_find(EG(zend_constants), lookup_name, Z_STRLEN_P(const_name)+1, (void **) &c)==SUCCESS) { if ((c->flags & CONST_CT_SUBST) && !(c->flags & CONST_CS)) { efree(lookup_name); @@ -5567,7 +5567,7 @@ void zend_do_fetch_constant(znode *result, znode *constant_container, znode *con case ZEND_CT: /* this is a class constant */ type = zend_get_class_fetch_type(Z_STRVAL(constant_container->u.constant), Z_STRLEN(constant_container->u.constant)); - + if (ZEND_FETCH_CLASS_STATIC == type) { zend_error(E_ERROR, "\"static::\" is not allowed in compile-time constants"); } else if (ZEND_FETCH_CLASS_DEFAULT == type) { @@ -5631,7 +5631,7 @@ void zend_do_fetch_constant(znode *result, znode *constant_container, znode *con compound = memchr(Z_STRVAL(constant_name->u.constant), '\\', Z_STRLEN(constant_name->u.constant)); zend_resolve_non_class_name(constant_name, check_namespace TSRMLS_CC); - + if(zend_constant_ct_subst(result, &constant_name->u.constant, 1 TSRMLS_CC)) { break; } @@ -5647,7 +5647,7 @@ void zend_do_fetch_constant(znode *result, znode *constant_container, znode *con /* the name is unambiguous */ opline->extended_value = 0; opline->op2.constant = zend_add_const_name_literal(CG(active_op_array), &constant_name->u.constant, 0 TSRMLS_CC); - } else { + } else { opline->extended_value = IS_CONSTANT_UNQUALIFIED; if (CG(current_namespace)) { opline->extended_value |= IS_CONSTANT_IN_NAMESPACE; @@ -5721,7 +5721,7 @@ void zend_do_init_array(znode *result, const znode *expr, const znode *offset, z ZEND_HANDLE_NUMERIC_EX(Z_STRVAL(CONSTANT(opline->op2.constant)), Z_STRLEN(CONSTANT(opline->op2.constant))+1, index, numeric = 1); if (numeric) { zval_dtor(&CONSTANT(opline->op2.constant)); - ZVAL_LONG(&CONSTANT(opline->op2.constant), index); + ZVAL_LONG(&CONSTANT(opline->op2.constant), index); } else { CALCULATE_LITERAL_HASH(opline->op2.constant); } @@ -5753,7 +5753,7 @@ void zend_do_add_array_element(znode *result, const znode *expr, const znode *of ZEND_HANDLE_NUMERIC_EX(Z_STRVAL(CONSTANT(opline->op2.constant)), Z_STRLEN(CONSTANT(opline->op2.constant))+1, index, numeric = 1); if (numeric) { zval_dtor(&CONSTANT(opline->op2.constant)); - ZVAL_LONG(&CONSTANT(opline->op2.constant), index); + ZVAL_LONG(&CONSTANT(opline->op2.constant), index); } else { CALCULATE_LITERAL_HASH(opline->op2.constant); } @@ -6013,7 +6013,7 @@ void zend_do_fetch_lexical_variable(znode *varname, zend_bool is_ref TSRMLS_DC) Z_TYPE(value.u.constant) |= is_ref ? IS_LEXICAL_REF : IS_LEXICAL_VAR; Z_SET_REFCOUNT_P(&value.u.constant, 1); Z_UNSET_ISREF_P(&value.u.constant); - + zend_do_fetch_static_variable(varname, &value, is_ref ? ZEND_FETCH_STATIC : ZEND_FETCH_LEXICAL TSRMLS_CC); } /* }}} */ @@ -6529,7 +6529,7 @@ void zend_do_jmp_set(const znode *value, znode *jmp_token, znode *colon_token TS opline->result.var = get_temporary_variable(CG(active_op_array)); SET_NODE(opline->op1, value); SET_UNUSED(opline->op2); - + GET_NODE(colon_token, opline->result); jmp_token->u.op.opline_num = op_number; @@ -6558,11 +6558,11 @@ void zend_do_jmp_set_else(znode *result, const znode *false_value, const znode * opline->extended_value = 0; SET_NODE(opline->op1, false_value); SET_UNUSED(opline->op2); - + GET_NODE(result, opline->result); CG(active_op_array)->opcodes[jmp_token->u.op.opline_num].op2.opline_num = get_next_op_number(CG(active_op_array)); - + DEC_BPC(CG(active_op_array)); } /* }}} */ @@ -6775,7 +6775,7 @@ int zendlex(znode *zendlval TSRMLS_DC) /* {{{ */ CG(increment_lineno) = 1; } if (CG(has_bracketed_namespaces) && !CG(in_namespace)) { - goto again; + goto again; } retval = ';'; /* implicit ; */ break; @@ -6865,13 +6865,13 @@ ZEND_API void zend_initialize_class_data(zend_class_entry *ce, zend_bool nullify int zend_get_class_fetch_type(const char *class_name, uint class_name_len) /* {{{ */ { if ((class_name_len == sizeof("self")-1) && - !memcmp(class_name, "self", sizeof("self")-1)) { - return ZEND_FETCH_CLASS_SELF; + !strncasecmp(class_name, "self", sizeof("self")-1)) { + return ZEND_FETCH_CLASS_SELF; } else if ((class_name_len == sizeof("parent")-1) && - !memcmp(class_name, "parent", sizeof("parent")-1)) { + !strncasecmp(class_name, "parent", sizeof("parent")-1)) { return ZEND_FETCH_CLASS_PARENT; } else if ((class_name_len == sizeof("static")-1) && - !memcmp(class_name, "static", sizeof("static")-1)) { + !strncasecmp(class_name, "static", sizeof("static")-1)) { return ZEND_FETCH_CLASS_STATIC; } else { return ZEND_FETCH_CLASS_DEFAULT; @@ -6984,7 +6984,7 @@ void zend_do_begin_namespace(const znode *name, zend_bool with_bracket TSRMLS_DC efree(CG(current_import)); CG(current_import) = NULL; } - + if (CG(doc_comment)) { efree(CG(doc_comment)); CG(doc_comment) = NULL; @@ -7156,7 +7156,7 @@ ZEND_API size_t zend_dirname(char *path, size_t len) len_adjust += 2; if (2 == len) { /* Return "c:" on Win32 for dirname("c:"). - * It would be more consistent to return "c:." + * It would be more consistent to return "c:." * but that would require making the string *longer*. */ return len; @@ -7164,7 +7164,7 @@ ZEND_API size_t zend_dirname(char *path, size_t len) } #elif defined(NETWARE) /* - * Find the first occurence of : from the left + * Find the first occurence of : from the left * move the path pointer to the position just after : * increment the len_adjust to the length of path till colon character(inclusive) * If there is no character beyond : simple return len From 263a220997df05f2d96c4fd200354a239af4626c Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Mon, 28 Jan 2013 13:23:31 +0100 Subject: [PATCH 2304/2394] allow for libpng 1.5.x --- ext/gd/config.w32 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/gd/config.w32 b/ext/gd/config.w32 index 8c932a037c1cb..22584ddd46e7b 100644 --- a/ext/gd/config.w32 +++ b/ext/gd/config.w32 @@ -11,7 +11,8 @@ if (PHP_GD != "no") { CHECK_LIB("freetype_a.lib;freetype.lib", "gd", PHP_GD) && CHECK_LIB("libpng_a.lib;libpng.lib", "gd", PHP_GD) && CHECK_HEADER_ADD_INCLUDE("gd.h", "CFLAGS_GD", PHP_GD + ";ext\\gd\\libgd") && - CHECK_HEADER_ADD_INCLUDE("png.h", "CFLAGS_GD", PHP_GD + ";" + PHP_PHP_BUILD + "\\include\\libpng12") && + (CHECK_HEADER_ADD_INCLUDE("png.h", "CFLAGS_GD", PHP_GD + ";" + PHP_PHP_BUILD + "\\include\\libpng15") || + CHECK_HEADER_ADD_INCLUDE("png.h", "CFLAGS_GD", PHP_GD + ";" + PHP_PHP_BUILD + "\\include\\libpng12")) && (CHECK_LIB("libiconv_a.lib;libiconv.lib", "gd", PHP_GD) || CHECK_LIB("iconv_a.lib;iconv.lib", "gd", PHP_GD)) && CHECK_HEADER_ADD_INCLUDE("iconv.h", "CFLAGS_GD", PHP_GD) && (((PHP_ZLIB=="no") && (CHECK_LIB("zlib_a.lib;zlib.lib", "gd", PHP_GD) )) || From 420bcc1a8e4d4dd38f6b1f019d31ec87fe582867 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 28 Jan 2013 12:13:13 -0800 Subject: [PATCH 2305/2394] add new features --- UPGRADING | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/UPGRADING b/UPGRADING index 1d2cebf02a4f7..7bf0e859e105b 100755 --- a/UPGRADING +++ b/UPGRADING @@ -77,6 +77,8 @@ PHP 5.5 UPGRADE NOTES for example. (https://wiki.php.net/rfc/empty_isset_exprs) - Added generators. (https://wiki.php.net/rfc/generators) +- ClassName::class syntax returning full class name for a class as + a string constant. (https://wiki.php.net/rfc/class_name_scalars) ======================================== 2. Changes in SAPI modules @@ -151,6 +153,8 @@ PHP 5.5 UPGRADE NOTES Furthermore both set_error_handler(NULL) and set_exception_handler(NULL) will now return the previously defined error/exception handler. Previously bool(true) was returned. +- setcookie(), setrawcookie() and ext/session now send Max-Age headers alongside + Expires headers. (see https://wiki.php.net/rfc/cookie_max-age) ======================================== 5. New Functions From a9d013bb020591cb6306afa2748da80f68b81f56 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 28 Jan 2013 22:22:59 -0800 Subject: [PATCH 2306/2394] Implement fix for bug #46439 - add CURLFile class for safer uploads --- NEWS | 4 + UPGRADING | 11 ++ ext/curl/config.m4 | 2 +- ext/curl/config.w32 | 2 +- ext/curl/interface.c | 144 ++++++++++++++++-------- ext/curl/php_curl.h | 17 ++- ext/curl/tests/bug27023.phpt | 2 + ext/curl/tests/curl_file_serialize.phpt | 21 ++++ ext/curl/tests/curl_file_upload.phpt | 85 ++++++++++++++ ext/curl/tests/curl_setopt_error.phpt | 4 +- 10 files changed, 243 insertions(+), 49 deletions(-) create mode 100644 ext/curl/tests/curl_file_serialize.phpt create mode 100644 ext/curl/tests/curl_file_upload.phpt diff --git a/NEWS b/NEWS index 6cd007c0fb7d2..3775558fb3550 100644 --- a/NEWS +++ b/NEWS @@ -5,6 +5,10 @@ PHP NEWS . Fixed bug # 60833 (self, parent, static behave inconsistently case-sensitive). (Stas, mario at include-once dot org) +- cURL: + . Implemented FR #46439 - added CURLFile for safer file uploads. + (Stas) + 24 Jan 2013, PHP 5.5.0 Alpha 4 - Core: diff --git a/UPGRADING b/UPGRADING index 7bf0e859e105b..8c9b3de43f0c1 100755 --- a/UPGRADING +++ b/UPGRADING @@ -155,6 +155,8 @@ PHP 5.5 UPGRADE NOTES bool(true) was returned. - setcookie(), setrawcookie() and ext/session now send Max-Age headers alongside Expires headers. (see https://wiki.php.net/rfc/cookie_max-age) +- curl_setopt now accepts new option CURLOPT_SAFE_UPLOAD and CURLFile object for + safer file uploads (see https://wiki.php.net/rfc/curl-file-upload) ======================================== 5. New Functions @@ -167,6 +169,9 @@ PHP 5.5 UPGRADE NOTES - password_needs_rehash() - password_verify() +- cURL: + - curl_file_create + - Hash: - hash_pbkdf2() @@ -267,6 +272,9 @@ PHP 5.5 UPGRADE NOTES - IntlRuleBasedBreakIterator - IntlCodePointBreakIterator +- cURL: + - CURLFile + ======================================== 7. Removed Extensions ======================================== @@ -286,6 +294,9 @@ PHP 5.5 UPGRADE NOTES - mysqli: - Added MYSQLI_SERVER_PUBLIC_KEY constant to be used with mysqli_options() +- cURL: + - Added CURLOPT_SAFE_UPLOAD to be used with curl_setopt(). + ======================================== 10. Changes to INI File Handling ======================================== diff --git a/ext/curl/config.m4 b/ext/curl/config.m4 index 92559be7c42a0..e549330c50c1b 100644 --- a/ext/curl/config.m4 +++ b/ext/curl/config.m4 @@ -149,6 +149,6 @@ int main(int argc, char *argv[]) AC_DEFINE(PHP_CURL_URL_WRAPPERS,1,[ ]) fi - PHP_NEW_EXTENSION(curl, interface.c multi.c share.c streams.c, $ext_shared) + PHP_NEW_EXTENSION(curl, interface.c multi.c share.c streams.c curl_file.c, $ext_shared) PHP_SUBST(CURL_SHARED_LIBADD) fi diff --git a/ext/curl/config.w32 b/ext/curl/config.w32 index a056845575899..5acda7ec9e957 100644 --- a/ext/curl/config.w32 +++ b/ext/curl/config.w32 @@ -13,7 +13,7 @@ if (PHP_CURL != "no") { && (((PHP_ZLIB=="no") && (CHECK_LIB("zlib_a.lib;zlib.lib", "curl", PHP_CURL))) || (PHP_ZLIB_SHARED && CHECK_LIB("zlib.lib", "curl", PHP_CURL)) || (PHP_ZLIB == "yes" && (!PHP_ZLIB_SHARED))) ) { - EXTENSION("curl", "interface.c multi.c share.c streams.c", true); + EXTENSION("curl", "interface.c multi.c share.c streams.c curl_file.c", true); AC_DEFINE('HAVE_CURL', 1, 'Have cURL library'); AC_DEFINE('HAVE_CURL_SSL', 1, 'Have SSL suppurt in cURL'); AC_DEFINE('HAVE_CURL_EASY_STRERROR', 1, 'Have curl_easy_strerror in cURL'); diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 2e055811e371a..07141485abc04 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -317,7 +317,7 @@ ZEND_END_ARG_INFO() #if LIBCURL_VERSION_NUM >= 0x070c01 /* 7.12.1 */ ZEND_BEGIN_ARG_INFO(arginfo_curl_reset, 0) ZEND_ARG_INFO(0, ch) -ZEND_END_ARG_INFO() +ZEND_END_ARG_INFO() #endif #if LIBCURL_VERSION_NUM > 0x070f03 /* 7.15.4 */ @@ -403,6 +403,12 @@ ZEND_BEGIN_ARG_INFO(arginfo_curl_pause, 0) ZEND_ARG_INFO(0, bitmask) ZEND_END_ARG_INFO() #endif + +ZEND_BEGIN_ARG_INFO_EX(arginfo_curlfile_create, 0, 0, 1) + ZEND_ARG_INFO(0, filename) + ZEND_ARG_INFO(0, mimetype) + ZEND_ARG_INFO(0, postname) +ZEND_END_ARG_INFO() /* }}} */ /* {{{ curl_functions[] @@ -446,6 +452,7 @@ const zend_function_entry curl_functions[] = { PHP_FE(curl_share_init, arginfo_curl_share_init) PHP_FE(curl_share_close, arginfo_curl_share_close) PHP_FE(curl_share_setopt, arginfo_curl_share_setopt) + PHP_FE(curl_file_create, arginfo_curlfile_create) PHP_FE_END }; /* }}} */ @@ -526,7 +533,7 @@ PHP_MINFO_FUNCTION(curl) #endif #if LIBCURL_VERSION_NUM >= 0x071600 /* 7.22.0 */ {"NTLMWB", CURL_VERSION_NTLM_WB}, -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x070a08 /* 7.10.8 */ {"SPNEGO", CURL_VERSION_SPNEGO}, #endif @@ -804,7 +811,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLINFO_STARTTRANSFER_TIME); REGISTER_CURL_CONSTANT(CURLINFO_TOTAL_TIME); - /* Other */ + /* Other */ REGISTER_CURL_CONSTANT(CURLMSG_DONE); REGISTER_CURL_CONSTANT(CURLVERSION_NOW); @@ -846,7 +853,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURL_SSLVERSION_SSLv2); REGISTER_CURL_CONSTANT(CURL_SSLVERSION_SSLv3); REGISTER_CURL_CONSTANT(CURL_SSLVERSION_TLSv1); - + /* Curl TIMECOND constants (CURLOPT_TIMECONDITION) */ REGISTER_CURL_CONSTANT(CURL_TIMECOND_IFMODSINCE); REGISTER_CURL_CONSTANT(CURL_TIMECOND_IFUNMODSINCE); @@ -910,7 +917,7 @@ PHP_MINIT_FUNCTION(curl) #if LIBCURL_VERSION_NUM >= 0x070d00 /* Available since 7.13.0 */ REGISTER_CURL_CONSTANT(CURLOPT_FTP_ACCOUNT); -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x070b02 /* Available since 7.11.2 */ REGISTER_CURL_CONSTANT(CURLOPT_TCP_NODELAY); @@ -918,7 +925,7 @@ PHP_MINIT_FUNCTION(curl) #if LIBCURL_VERSION_NUM >= 0x070c02 /* Available since 7.12.2 */ REGISTER_CURL_CONSTANT(CURLINFO_OS_ERRNO); -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x070c03 /* Available since 7.12.3 */ REGISTER_CURL_CONSTANT(CURLINFO_NUM_CONNECTS); @@ -959,7 +966,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_FTP_ALTERNATIVE_TO_USER); REGISTER_CURL_CONSTANT(CURLOPT_MAX_RECV_SPEED_LARGE); REGISTER_CURL_CONSTANT(CURLOPT_MAX_SEND_SPEED_LARGE); -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x071000 /* Available since 7.16.0 */ REGISTER_CURL_CONSTANT(CURLOPT_SSL_SESSIONID_CACHE); @@ -1003,7 +1010,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLUSESSL_CONTROL); REGISTER_CURL_CONSTANT(CURLUSESSL_NONE); REGISTER_CURL_CONSTANT(CURLUSESSL_TRY); -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x071101 /* Available since 7.17.1 */ REGISTER_CURL_CONSTANT(CURLOPT_SSH_HOST_PUBLIC_KEY_MD5); @@ -1053,7 +1060,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURLOPT_USERNAME); #endif -#if LIBCURL_VERSION_NUM >= 0x071303 /* Available since 7.19.3 */ +#if LIBCURL_VERSION_NUM >= 0x071303 /* Available since 7.19.3 */ REGISTER_CURL_CONSTANT(CURLAUTH_DIGEST_IE); #endif @@ -1135,7 +1142,7 @@ PHP_MINIT_FUNCTION(curl) REGISTER_CURL_CONSTANT(CURL_FNMATCHFUNC_FAIL); REGISTER_CURL_CONSTANT(CURL_FNMATCHFUNC_MATCH); REGISTER_CURL_CONSTANT(CURL_FNMATCHFUNC_NOMATCH); -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x071502 /* Available since 7.21.2 */ REGISTER_CURL_CONSTANT(CURLPROTO_GOPHER); @@ -1187,6 +1194,7 @@ PHP_MINIT_FUNCTION(curl) #if CURLOPT_PASSWDFUNCTION != 0 REGISTER_CURL_CONSTANT(CURLOPT_PASSWDFUNCTION); #endif + REGISTER_CURL_CONSTANT(CURLOPT_SAFE_UPLOAD); #ifdef PHP_CURL_NEED_OPENSSL_TSL if (!CRYPTO_get_id_callback()) { @@ -1229,6 +1237,8 @@ PHP_MINIT_FUNCTION(curl) } #endif + curlfile_register_class(TSRMLS_C); + return SUCCESS; } /* }}} */ @@ -1275,7 +1285,7 @@ PHP_MSHUTDOWN_FUNCTION(curl) /* {{{ curl_write_nothing * Used as a work around. See _php_curl_close_ex */ -static size_t curl_write_nothing(char *data, size_t size, size_t nmemb, void *ctx) +static size_t curl_write_nothing(char *data, size_t size, size_t nmemb, void *ctx) { return size * nmemb; } @@ -1812,6 +1822,7 @@ static void alloc_curl_handle(php_curl **ch) zend_llist_init(&(*ch)->to_free->str, sizeof(char *), (llist_dtor_func_t) curl_free_string, 0); zend_llist_init(&(*ch)->to_free->slist, sizeof(struct curl_slist), (llist_dtor_func_t) curl_free_slist, 0); zend_llist_init(&(*ch)->to_free->post, sizeof(struct HttpPost), (llist_dtor_func_t) curl_free_post, 0); + (*ch)->safe_upload = 0; /* for now, for BC reason we allow unsafe API */ } /* }}} */ @@ -1833,7 +1844,7 @@ static void split_certinfo(char *string, zval *hash) split = strstr(s, "; "); if(split) *split = '\0'; - + key = s; tmp = memchr(key, '=', 64); if(tmp) { @@ -1853,13 +1864,13 @@ static void split_certinfo(char *string, zval *hash) static void create_certinfo(struct curl_certinfo *ci, zval *listcode TSRMLS_DC) { int i; - + if(ci) { zval *certhash = NULL; - + for(i=0; inum_of_certs; i++) { struct curl_slist *slist; - + MAKE_STD_ZVAL(certhash); array_init(certhash); for(slist = ci->certinfo[i]; slist; slist = slist->next) { @@ -1876,14 +1887,14 @@ static void create_certinfo(struct curl_certinfo *ci, zval *listcode TSRMLS_DC) MAKE_STD_ZVAL(hash); array_init(hash); - + split_certinfo(&slist->data[len+1], hash); add_assoc_zval(certhash, s, hash); } else { add_assoc_string(certhash, s, &slist->data[len+1], 1); } } else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not extract hash key from certificate info"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not extract hash key from certificate info"); } } add_next_index_zval(listcode, certhash); @@ -2056,7 +2067,7 @@ PHP_FUNCTION(curl_copy_handle) if (ch->handlers->fnmatch->func_name) { zval_add_ref(&ch->handlers->fnmatch->func_name); dupch->handlers->fnmatch->func_name = ch->handlers->fnmatch->func_name; - } + } dupch->handlers->fnmatch->method = ch->handlers->fnmatch->method; curl_easy_setopt(dupch->cp, CURLOPT_FNMATCH_DATA, (void *) dupch); } @@ -2135,7 +2146,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #if LIBCURL_VERSION_NUM >= 0x070a06 /* Available since 7.10.6 */ case CURLOPT_HTTPAUTH: #endif -#if LIBCURL_VERSION_NUM >= 0x070a07 /* Available since 7.10.7 */ +#if LIBCURL_VERSION_NUM >= 0x070a07 /* Available since 7.10.7 */ case CURLOPT_FTP_CREATE_MISSING_DIRS: case CURLOPT_PROXYAUTH: #endif @@ -2185,11 +2196,11 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_USE_SSL: #elif LIBCURL_VERSION_NUM >= 0x070b00 /* Available since 7.11.0 */ case CURLOPT_FTP_SSL: -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x071100 /* Available since 7.17.0 */ case CURLOPT_APPEND: case CURLOPT_DIRLISTONLY: -#else +#else case CURLOPT_FTPAPPEND: case CURLOPT_FTPLISTONLY: #endif @@ -2247,6 +2258,10 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #endif error = curl_easy_setopt(ch->cp, option, Z_LVAL_PP(zvalue)); break; + case CURLOPT_SAFE_UPLOAD: + convert_to_long_ex(zvalue); + ch->safe_upload = (Z_LVAL_PP(zvalue) != 0); + break; /* String options */ case CURLOPT_CAINFO: @@ -2282,7 +2297,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #endif #if LIBCURL_VERSION_NUM >= 0x071004 /* Available since 7.16.4 */ case CURLOPT_KRBLEVEL: -#else +#else case CURLOPT_KRB4LEVEL: #endif #if LIBCURL_VERSION_NUM >= 0x071101 /* Available since 7.17.1 */ @@ -2307,7 +2322,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu case CURLOPT_TLSAUTH_PASSWORD: case CURLOPT_TLSAUTH_USERNAME: #endif -#if LIBCURL_VERSION_NUM >= 0x071506 /* Available since 7.21.6 */ +#if LIBCURL_VERSION_NUM >= 0x071506 /* Available since 7.21.6 */ case CURLOPT_ACCEPT_ENCODING: case CURLOPT_TRANSFER_ENCODING: #else @@ -2315,7 +2330,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #endif #if LIBCURL_VERSION_NUM >= 0x071800 /* Available since 7.24.0 */ case CURLOPT_DNS_SERVERS: -#endif +#endif #if LIBCURL_VERSION_NUM >= 0x071900 /* Available since 7.25.0 */ case CURLOPT_MAIL_AUTH: #endif @@ -2339,8 +2354,8 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu #if LIBCURL_VERSION_NUM >= 0x071100 /* Strings passed to libcurl as ’char *’ arguments, are copied by the library... NOTE: before 7.17.0 strings were not copied. */ error = curl_easy_setopt(ch->cp, option, Z_STRVAL_PP(zvalue)); -#else - goto string_copy; +#else + goto string_copy; #endif } } @@ -2350,7 +2365,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu /* Curl file handle options */ case CURLOPT_FILE: case CURLOPT_INFILE: - case CURLOPT_STDERR: + case CURLOPT_STDERR: case CURLOPT_WRITEHEADER: { FILE *fp = NULL; int type; @@ -2560,9 +2575,6 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu ulong num_key; int numeric_key; - SEPARATE_ZVAL(current); - convert_to_string_ex(current); - zend_hash_get_current_key_ex(postfields, &string_key, &string_key_len, &num_key, 0, NULL); /* Pretend we have a string_key here */ @@ -2574,15 +2586,59 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu numeric_key = 0; } + if(Z_TYPE_PP(current) == IS_OBJECT && instanceof_function(Z_OBJCE_PP(current), curl_CURLFile_class TSRMLS_CC)) { + /* new-style file upload */ + zval *prop; + char *type = NULL, *filename = NULL; + + prop = zend_read_property(curl_CURLFile_class, *current, "name", sizeof("name")-1, 0 TSRMLS_CC); + if(Z_TYPE_P(prop) != IS_STRING) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid filename for key %s", string_key); + } else { + postval = Z_STRVAL_P(prop); + + if (php_check_open_basedir(postval TSRMLS_CC)) { + RETVAL_FALSE; + return 1; + } + + prop = zend_read_property(curl_CURLFile_class, *current, "mime", sizeof("mime")-1, 0 TSRMLS_CC); + if(Z_TYPE_P(prop) == IS_STRING && Z_STRLEN_P(prop) > 0) { + type = Z_STRVAL_P(prop); + } + prop = zend_read_property(curl_CURLFile_class, *current, "postname", sizeof("postname")-1, 0 TSRMLS_CC); + if(Z_TYPE_P(prop) == IS_STRING && Z_STRLEN_P(prop) > 0) { + filename = Z_STRVAL_P(prop); + } + error = curl_formadd(&first, &last, + CURLFORM_COPYNAME, string_key, + CURLFORM_NAMELENGTH, (long)string_key_len - 1, + CURLFORM_FILENAME, filename ? filename : postval, + CURLFORM_CONTENTTYPE, type ? type : "application/octet-stream", + CURLFORM_FILE, postval, + CURLFORM_END); + } + + if (numeric_key) { + efree(string_key); + } + continue; + } + + SEPARATE_ZVAL(current); + convert_to_string_ex(current); + postval = Z_STRVAL_PP(current); /* The arguments after _NAMELENGTH and _CONTENTSLENGTH * must be explicitly cast to long in curl_formadd * use since curl needs a long not an int. */ - if (*postval == '@') { + if (!ch->safe_upload && *postval == '@') { char *type, *filename; ++postval; + php_error_docref("curl.curlfile" TSRMLS_CC, E_DEPRECATED, "The usage of the @filename API for file uploading is deprecated. Please use the CURLFile class instead"); + if ((type = php_memnstr(postval, ";type=", sizeof(";type=") - 1, postval + Z_STRLEN_PP(current)))) { *type = '\0'; } @@ -2725,7 +2781,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu /* the following options deal with files, therefore the open_basedir check * is required. */ - case CURLOPT_COOKIEFILE: + case CURLOPT_COOKIEFILE: case CURLOPT_COOKIEJAR: case CURLOPT_RANDOM_FILE: case CURLOPT_SSLCERT: @@ -2829,7 +2885,7 @@ PHP_FUNCTION(curl_setopt) ZEND_FETCH_RESOURCE(ch, php_curl *, &zid, -1, le_curl_name, le_curl); - if (options <= 0) { + if (options <= 0 && options != CURLOPT_SAFE_UPLOAD) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid curl configuration option"); RETURN_FALSE; } @@ -3045,7 +3101,7 @@ PHP_FUNCTION(curl_getinfo) CAAS("redirect_url", s_code); } #endif -#if LIBCURL_VERSION_NUM >= 0x071300 /* Available since 7.19.0 */ +#if LIBCURL_VERSION_NUM >= 0x071300 /* Available since 7.19.0 */ if (curl_easy_getinfo(ch->cp, CURLINFO_PRIMARY_IP, &s_code) == CURLE_OK) { CAAS("primary_ip", s_code); } @@ -3085,7 +3141,7 @@ PHP_FUNCTION(curl_getinfo) struct curl_certinfo *ci = NULL; array_init(return_value); - + if (curl_easy_getinfo(ch->cp, CURLINFO_CERTINFO, &ci) == CURLE_OK) { create_certinfo(ci, return_value TSRMLS_CC); } else { @@ -3100,7 +3156,7 @@ PHP_FUNCTION(curl_getinfo) case CURLINFO_STRING: { char *s_code = NULL; - + if (curl_easy_getinfo(ch->cp, option, &s_code) == CURLE_OK && s_code) { RETURN_STRING(s_code, 1); } else { @@ -3111,7 +3167,7 @@ PHP_FUNCTION(curl_getinfo) case CURLINFO_LONG: { long code = 0; - + if (curl_easy_getinfo(ch->cp, option, &code) == CURLE_OK) { RETURN_LONG(code); } else { @@ -3221,16 +3277,16 @@ static void _php_curl_close_ex(php_curl *ch TSRMLS_DC) _php_curl_verify_handlers(ch, 0 TSRMLS_CC); - /* + /* * Libcurl is doing connection caching. When easy handle is cleaned up, - * if the handle was previously used by the curl_multi_api, the connection + * if the handle was previously used by the curl_multi_api, the connection * remains open un the curl multi handle is cleaned up. Some protocols are - * sending content like the FTP one, and libcurl try to use the + * sending content like the FTP one, and libcurl try to use the * WRITEFUNCTION or the HEADERFUNCTION. Since structures used in those * callback are freed, we need to use an other callback to which avoid * segfaults. * - * Libcurl commit d021f2e8a00 fix this issue and should be part of 7.28.2 + * Libcurl commit d021f2e8a00 fix this issue and should be part of 7.28.2 */ curl_easy_setopt(ch->cp, CURLOPT_HEADERFUNCTION, curl_write_nothing); curl_easy_setopt(ch->cp, CURLOPT_WRITEFUNCTION, curl_write_nothing); @@ -3349,7 +3405,7 @@ static void _php_curl_reset_handlers(php_curl *ch) } ch->handlers->write->fp = NULL; ch->handlers->write->method = PHP_CURL_STDOUT; - + if (ch->handlers->write_header->stream) { Z_DELREF_P(ch->handlers->write_header->stream); ch->handlers->write_header->stream = NULL; @@ -3443,7 +3499,7 @@ PHP_FUNCTION(curl_escape) /* {{{ proto void curl_unescape(resource ch, string str) URL decodes the given string */ -PHP_FUNCTION(curl_unescape) +PHP_FUNCTION(curl_unescape) { char *str = NULL, *out = NULL; int str_len = 0, out_len; @@ -3481,7 +3537,7 @@ PHP_FUNCTION(curl_pause) ZEND_FETCH_RESOURCE(ch, php_curl *, &zid, -1, le_curl_name, le_curl); - RETURN_LONG(curl_easy_pause(ch->cp, bitmask)); + RETURN_LONG(curl_easy_pause(ch->cp, bitmask)); } /* }}} */ #endif diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h index a8c26c05288a3..c4222c05883b8 100644 --- a/ext/curl/php_curl.h +++ b/ext/curl/php_curl.h @@ -34,6 +34,14 @@ #define PHP_CURL_DEBUG 0 +#ifdef PHP_WIN32 +# define PHP_CURL_API __declspec(dllexport) +#elif defined(__GNUC__) && __GNUC__ >= 4 +# define PHP_CURL_API __attribute__ ((visibility("default"))) +#else +# define PHP_CURL_API +#endif + #include #include @@ -103,6 +111,8 @@ PHP_FUNCTION(curl_multi_setopt); #if LIBCURL_VERSION_NUM >= 0x071200 /* 7.18.0 */ PHP_FUNCTION(curl_pause); #endif +PHP_FUNCTION(curl_file_create); + void _php_curl_multi_close(zend_rsrc_list_entry * TSRMLS_DC); void _php_curl_share_close(zend_rsrc_list_entry * TSRMLS_DC); @@ -171,8 +181,11 @@ typedef struct { long id; zend_bool in_callback; zval *clone; + zend_bool safe_upload; } php_curl; +#define CURLOPT_SAFE_UPLOAD -1 + typedef struct { int still_running; CURLM *multi; @@ -211,7 +224,7 @@ typedef struct { fd_set readfds, writefds, excfds; int maxfd; - + char errstr[CURL_ERROR_SIZE + 1]; CURLMcode mcode; int pending; @@ -219,6 +232,8 @@ typedef struct { struct curl_slist *headers_slist; /* holds custom headers sent out in the request */ } php_curl_stream; +void curlfile_register_class(TSRMLS_D); +PHP_CURL_API extern zend_class_entry *curl_CURLFile_class; #else #define curl_module_ptr NULL diff --git a/ext/curl/tests/bug27023.phpt b/ext/curl/tests/bug27023.phpt index b738c956e9280..62effec990be4 100644 --- a/ext/curl/tests/bug27023.phpt +++ b/ext/curl/tests/bug27023.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #27023 (CURLOPT_POSTFIELDS does not parse content types for files) +--INI-- +error_reporting = E_ALL & ~E_DEPRECATED --SKIPIF-- +--FILE-- + +--EXPECTF-- +Fatal error: Uncaught exception 'Exception' with message 'Unserialization of CURLFile instances is not allowed' in %s +Stack trace: +#0 [internal function]: CURLFile->__wakeup() +#1 %s +#2 {main} + thrown in %s on line %d + diff --git a/ext/curl/tests/curl_file_upload.phpt b/ext/curl/tests/curl_file_upload.phpt new file mode 100644 index 0000000000000..d3168e578ac98 --- /dev/null +++ b/ext/curl/tests/curl_file_upload.phpt @@ -0,0 +1,85 @@ +--TEST-- +CURL file uploading +--SKIPIF-- + +--FILE-- + $file)); + var_dump(curl_exec($ch)); +} + +$host = getenv('PHP_CURL_HTTP_REMOTE_SERVER'); +$ch = curl_init(); +curl_setopt($ch, CURLOPT_URL, "{$host}/get.php?test=file"); +curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); + +testcurl($ch, __DIR__ . '/curl_testdata1.txt'); +testcurl($ch, __DIR__ . '/curl_testdata1.txt', 'text/plain'); +testcurl($ch, __DIR__ . '/curl_testdata1.txt', '', 'foo.txt'); +testcurl($ch, __DIR__ . '/curl_testdata1.txt', 'text/plain', 'foo.txt'); + +$file = new CurlFile(__DIR__ . '/curl_testdata1.txt'); +$file->setMimeType('text/plain'); +var_dump($file->getMimeType()); +var_dump($file->getFilename()); +curl_setopt($ch, CURLOPT_POSTFIELDS, array("file" => $file)); +var_dump(curl_exec($ch)); + +$file = curl_file_create(__DIR__ . '/curl_testdata1.txt'); +$file->setPostFilename('foo.txt'); +var_dump($file->getPostFilename()); +curl_setopt($ch, CURLOPT_POSTFIELDS, array("file" => $file)); +var_dump(curl_exec($ch)); + +$params = array('file' => '@' . __DIR__ . '/curl_testdata1.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +curl_setopt($ch, CURLOPT_SAFE_UPLOAD, true); +$params = array('file' => '@' . __DIR__ . '/curl_testdata1.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +curl_setopt($ch, CURLOPT_URL, "{$host}/get.php?test=post"); +$params = array('file' => '@' . __DIR__ . '/curl_testdata1.txt'); +curl_setopt($ch, CURLOPT_POSTFIELDS, $params); +var_dump(curl_exec($ch)); + +curl_close($ch); +?> +--EXPECTF-- +string(%d) "curl_testdata1.txt|application/octet-stream" +string(%d) "curl_testdata1.txt|text/plain" +string(%d) "foo.txt|application/octet-stream" +string(%d) "foo.txt|text/plain" +string(%d) "text/plain" +string(%d) "%s/curl_testdata1.txt" +string(%d) "curl_testdata1.txt|text/plain" +string(%d) "foo.txt" +string(%d) "foo.txt|application/octet-stream" + +Deprecated: curl_setopt(): The usage of the @filename API for file uploading is deprecated. Please use the CURLFile class instead in %s on line %d +string(%d) "curl_testdata1.txt|application/octet-stream" +string(0) "" +string(%d) "array(1) { + ["file"]=> + string(%d) "@%s/curl_testdata1.txt" +} +" diff --git a/ext/curl/tests/curl_setopt_error.phpt b/ext/curl/tests/curl_setopt_error.phpt index ad73318f1cc3f..01593aff22c90 100644 --- a/ext/curl/tests/curl_setopt_error.phpt +++ b/ext/curl/tests/curl_setopt_error.phpt @@ -14,14 +14,14 @@ curl_setopt(false); curl_setopt($ch); curl_setopt($ch, false); -curl_setopt($ch, -1); +curl_setopt($ch, -10); curl_setopt($ch, ''); curl_setopt($ch, 1, false); curl_setopt(false, false, false); curl_setopt($ch, '', false); curl_setopt($ch, 1, ''); -curl_setopt($ch, -1, 0); +curl_setopt($ch, -10, 0); ?> --EXPECTF-- *** curl_setopt() call with incorrect parameters From 24447dca5d308d0e4f5bab129d0050d6fe0c3163 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 28 Jan 2013 22:26:59 -0800 Subject: [PATCH 2307/2394] post-5.5 changes for bug #46439 as described in the RFC --- UPGRADING | 3 +++ ext/curl/interface.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/UPGRADING b/UPGRADING index c34101dd96d89..a8fa5f85cfa2b 100755 --- a/UPGRADING +++ b/UPGRADING @@ -40,6 +40,9 @@ PHP X.Y UPGRADE NOTES 4. Changed Functions ======================================== +- cURL: + CURLOPT_SAFE_UPLOAD is now turned on by default and uploads with @file + do not work unless it is explicitly set to false. ======================================== 5. New Functions diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 07141485abc04..ab9e12cd96a25 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -1822,7 +1822,7 @@ static void alloc_curl_handle(php_curl **ch) zend_llist_init(&(*ch)->to_free->str, sizeof(char *), (llist_dtor_func_t) curl_free_string, 0); zend_llist_init(&(*ch)->to_free->slist, sizeof(struct curl_slist), (llist_dtor_func_t) curl_free_slist, 0); zend_llist_init(&(*ch)->to_free->post, sizeof(struct HttpPost), (llist_dtor_func_t) curl_free_post, 0); - (*ch)->safe_upload = 0; /* for now, for BC reason we allow unsafe API */ + (*ch)->safe_upload = 1; /* for now, for BC reason we allow unsafe API */ } /* }}} */ From 383e3172691d04232ebb74aef8628b8b63da3698 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 28 Jan 2013 22:28:55 -0800 Subject: [PATCH 2308/2394] oops, unintended addition --- UPGRADING | 3 --- 1 file changed, 3 deletions(-) diff --git a/UPGRADING b/UPGRADING index a8fa5f85cfa2b..f7eda53519ca1 100755 --- a/UPGRADING +++ b/UPGRADING @@ -54,9 +54,6 @@ PHP X.Y UPGRADE NOTES ======================================== -- cURL: - - CURLFile - ======================================== 7. Removed Extensions ======================================== From 475a644bd84c071da04b4272b829a187a2c6d282 Mon Sep 17 00:00:00 2001 From: ALeX Kazik Date: Fri, 18 Jan 2013 17:13:39 +0100 Subject: [PATCH 2309/2394] Implemented Feature #60524 (sys_temp_dir) Added a new configuration directive which allows it to change the temporary directory, the default behavior is unchanged. This is a useful option if you use all/some hosts inside of one .ini file with sections and want to change the temp dir per user (maybe it's not allowed to write outside the users home directory). Since the TMPDIR variable affects the whole php that way can not be used for this scenario. (see https://bugs.php.net/bug.php?id=60524) --- main/main.c | 1 + main/php_globals.h | 1 + main/php_open_temporary_file.c | 15 +++++++++++++++ php.ini-development | 4 ++++ php.ini-production | 4 ++++ tests/basic/req60524.phpt | 8 ++++++++ 6 files changed, 33 insertions(+) create mode 100644 tests/basic/req60524.phpt diff --git a/main/main.c b/main/main.c index f87a1427feda4..325ef7ed531b3 100644 --- a/main/main.c +++ b/main/main.c @@ -521,6 +521,7 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("default_mimetype", SAPI_DEFAULT_MIMETYPE, PHP_INI_ALL, OnUpdateString, default_mimetype, sapi_globals_struct,sapi_globals) STD_PHP_INI_ENTRY("error_log", NULL, PHP_INI_ALL, OnUpdateErrorLog, error_log, php_core_globals, core_globals) STD_PHP_INI_ENTRY("extension_dir", PHP_EXTENSION_DIR, PHP_INI_SYSTEM, OnUpdateStringUnempty, extension_dir, php_core_globals, core_globals) + STD_PHP_INI_ENTRY("sys_temp_dir", NULL, PHP_INI_SYSTEM, OnUpdateStringUnempty, sys_temp_dir, php_core_globals, core_globals) STD_PHP_INI_ENTRY("include_path", PHP_INCLUDE_PATH, PHP_INI_ALL, OnUpdateStringUnempty, include_path, php_core_globals, core_globals) PHP_INI_ENTRY("max_execution_time", "30", PHP_INI_ALL, OnUpdateTimeout) STD_PHP_INI_ENTRY("open_basedir", NULL, PHP_INI_ALL, OnUpdateBaseDir, open_basedir, php_core_globals, core_globals) diff --git a/main/php_globals.h b/main/php_globals.h index 170431d079c63..256765d665a53 100644 --- a/main/php_globals.h +++ b/main/php_globals.h @@ -85,6 +85,7 @@ struct _php_core_globals { char *open_basedir; char *extension_dir; char *php_binary; + char *sys_temp_dir; char *upload_tmp_dir; long upload_max_filesize; diff --git a/main/php_open_temporary_file.c b/main/php_open_temporary_file.c index b43d6a78351c7..5d5e5b98d77a0 100644 --- a/main/php_open_temporary_file.c +++ b/main/php_open_temporary_file.c @@ -196,6 +196,21 @@ PHPAPI const char* php_get_temporary_directory(void) return temporary_directory; } + /* Is there a temporary directory "sys_temp_dir" in .ini defined? */ + { + char *sys_temp_dir = PG(sys_temp_dir); + if (sys_temp_dir) { + int len = strlen(sys_temp_dir); + if (len >= 2 && sys_temp_dir[len - 1] == DEFAULT_SLASH) { + temporary_directory = zend_strndup(sys_temp_dir, len - 1); + return temporary_directory; + } else if (len >= 1 && sys_temp_dir[len - 1] != DEFAULT_SLASH) { + temporary_directory = zend_strndup(sys_temp_dir, len); + return temporary_directory; + } + } + } + #ifdef PHP_WIN32 /* We can't count on the environment variables TEMP or TMP, * and so must make the Win32 API call to get the default diff --git a/php.ini-development b/php.ini-development index a97cd0f9dad94..93a4b7d8a589a 100644 --- a/php.ini-development +++ b/php.ini-development @@ -729,6 +729,10 @@ user_dir = ; On windows: ; extension_dir = "ext" +; Directory where the temporary files should be placed. +; Defaults to the system default (see sys_get_temp_dir) +; sys_temp_dir = "/tmp" + ; Whether or not to enable the dl() function. The dl() function does NOT work ; properly in multithreaded servers, such as IIS or Zeus, and is automatically ; disabled on them. diff --git a/php.ini-production b/php.ini-production index dce8fc970ccff..7d84c9b879790 100644 --- a/php.ini-production +++ b/php.ini-production @@ -729,6 +729,10 @@ user_dir = ; On windows: ; extension_dir = "ext" +; Directory where the temporary files should be placed. +; Defaults to the system default (see sys_get_temp_dir) +; sys_temp_dir = "/tmp" + ; Whether or not to enable the dl() function. The dl() function does NOT work ; properly in multithreaded servers, such as IIS or Zeus, and is automatically ; disabled on them. diff --git a/tests/basic/req60524.phpt b/tests/basic/req60524.phpt new file mode 100644 index 0000000000000..6803e1fd88bfe --- /dev/null +++ b/tests/basic/req60524.phpt @@ -0,0 +1,8 @@ +--TEST-- +Req #60524 (Specify temporary directory) +--INI-- +sys_temp_dir=/path/to/temp/dir +--FILE-- + +--EXPECT-- +/path/to/temp/dir From 389d41cc2e32496de2beb05c77f34bfd868c64a0 Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Mon, 28 Jan 2013 22:55:55 -0800 Subject: [PATCH 2310/2394] Add news for bug #60524 --- NEWS | 3 ++- UPGRADING | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 3775558fb3550..f26806d916fce 100644 --- a/NEWS +++ b/NEWS @@ -2,8 +2,9 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 201?, PHP 5.5.0 Beta 1 - Core: - . Fixed bug # 60833 (self, parent, static behave inconsistently + . Fixed bug #60833 (self, parent, static behave inconsistently case-sensitive). (Stas, mario at include-once dot org) + . Implemented FR #60524 (specify temp dir by php.ini). (ALeX Kazik). - cURL: . Implemented FR #46439 - added CURLFile for safer file uploads. diff --git a/UPGRADING b/UPGRADING index 8c9b3de43f0c1..22ad969157cf9 100755 --- a/UPGRADING +++ b/UPGRADING @@ -301,6 +301,9 @@ PHP 5.5 UPGRADE NOTES 10. Changes to INI File Handling ======================================== +- Core: + - Added sys_temp_dir INI directive, for specifying temp firectory. + - Intl: - Added intl.use_exceptions INI directive, which controls what happens when global errors are set together with intl.error_level. From 37c304b5db16fcf402ec00d7c8c4a228c4b5cdc4 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Tue, 29 Jan 2013 09:26:54 -0200 Subject: [PATCH 2311/2394] - Fixed ZTS build --- main/php_open_temporary_file.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/main/php_open_temporary_file.c b/main/php_open_temporary_file.c index 5d5e5b98d77a0..054d497be6d5c 100644 --- a/main/php_open_temporary_file.c +++ b/main/php_open_temporary_file.c @@ -189,7 +189,7 @@ PHPAPI void php_shutdown_temporary_directory(void) /* * Determine where to place temporary files. */ -PHPAPI const char* php_get_temporary_directory(void) +PHPAPI const char* php_get_temporary_directory(TSRMLS_D) { /* Did we determine the temporary directory already? */ if (temporary_directory) { @@ -278,7 +278,7 @@ PHPAPI int php_open_temporary_fd_ex(const char *dir, const char *pfx, char **ope if (!dir || *dir == '\0') { def_tmp: - temp_dir = php_get_temporary_directory(); + temp_dir = php_get_temporary_directory(TSRMLS_C); if (temp_dir && *temp_dir != '\0' && (!open_basedir_check || !php_check_open_basedir(temp_dir TSRMLS_CC))) { return php_do_open_temporary_file(temp_dir, pfx, opened_path_p TSRMLS_CC); @@ -309,12 +309,12 @@ PHPAPI FILE *php_open_temporary_file(const char *dir, const char *pfx, char **op if (fd == -1) { return NULL; } - + fp = fdopen(fd, "r+b"); if (fp == NULL) { close(fd); } - + return fp; } /* }}} */ From 1faddd15d967d7296b049fbb580681463c05ba83 Mon Sep 17 00:00:00 2001 From: Sara Golemon Date: Wed, 5 Dec 2012 15:07:36 -0800 Subject: [PATCH 2312/2394] Add UConverter class (ICU's UConverter API) RFC at http://wiki.php.net/rfc/uconverter --- ext/intl/config.m4 | 2 + ext/intl/config.w32 | 3 + ext/intl/converter/converter.c | 1104 +++++++++++++++++ ext/intl/converter/converter.h | 28 + ext/intl/php_intl.c | 5 + ext/intl/tests/uconverter_enum.phpt | 21 + ext/intl/tests/uconverter_func_basic.phpt | 17 + ext/intl/tests/uconverter_func_subst.phpt | 31 + ext/intl/tests/uconverter_oop_algo.phpt | 18 + ext/intl/tests/uconverter_oop_basic.phpt | 21 + ext/intl/tests/uconverter_oop_callback.phpt | 52 + .../tests/uconverter_oop_callback_return.phpt | 40 + ext/intl/tests/uconverter_oop_subst.phpt | 24 + 13 files changed, 1366 insertions(+) create mode 100644 ext/intl/converter/converter.c create mode 100644 ext/intl/converter/converter.h create mode 100644 ext/intl/tests/uconverter_enum.phpt create mode 100644 ext/intl/tests/uconverter_func_basic.phpt create mode 100644 ext/intl/tests/uconverter_func_subst.phpt create mode 100644 ext/intl/tests/uconverter_oop_algo.phpt create mode 100644 ext/intl/tests/uconverter_oop_basic.phpt create mode 100644 ext/intl/tests/uconverter_oop_callback.phpt create mode 100644 ext/intl/tests/uconverter_oop_callback_return.phpt create mode 100644 ext/intl/tests/uconverter_oop_subst.phpt diff --git a/ext/intl/config.m4 b/ext/intl/config.m4 index 7c95c130f2135..4630a302ef891 100644 --- a/ext/intl/config.m4 +++ b/ext/intl/config.m4 @@ -34,6 +34,7 @@ if test "$PHP_INTL" != "no"; then common/common_error.c \ common/common_enum.cpp \ common/common_date.cpp \ + converter/converter.c \ formatter/formatter.c \ formatter/formatter_main.c \ formatter/formatter_class.c \ @@ -86,6 +87,7 @@ if test "$PHP_INTL" != "no"; then idn/idn.c \ $icu_spoof_src, $ext_shared,,$ICU_INCS -Wno-write-strings) PHP_ADD_BUILD_DIR($ext_builddir/collator) + PHP_ADD_BUILD_DIR($ext_builddir/converter) PHP_ADD_BUILD_DIR($ext_builddir/common) PHP_ADD_BUILD_DIR($ext_builddir/formatter) PHP_ADD_BUILD_DIR($ext_builddir/normalizer) diff --git a/ext/intl/config.w32 b/ext/intl/config.w32 index a49918794c576..bb1dca8124a5a 100644 --- a/ext/intl/config.w32 +++ b/ext/intl/config.w32 @@ -26,6 +26,9 @@ if (PHP_INTL != "no") { common_enum.cpp \ common_date.cpp \ ", "intl"); + ADD_SOURCES(configure_module_dirname + "/converter", "\ + converter.c \ + ", "intl"); ADD_SOURCES(configure_module_dirname + "/formatter", "\ formatter.c \ formatter_attr.c \ diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c new file mode 100644 index 0000000000000..6be8698cbf588 --- /dev/null +++ b/ext/intl/converter/converter.c @@ -0,0 +1,1104 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Sara Golemon | + +----------------------------------------------------------------------+ + */ + +#include "converter.h" +#include "zend_exceptions.h" + +#include +#include +#include + +#include "ext/intl/intl_error.h" + +typedef struct _php_converter_object { + zend_object obj; +#ifdef ZTS + void ***tsrm_ls; +#endif + UConverter *src, *dest; + zend_fcall_info to_cb, from_cb; + zend_fcall_info_cache to_cache, from_cache; + intl_error error; +} php_converter_object; + +static zend_class_entry *php_converter_ce; +static zend_object_handlers php_converter_object_handlers; + +#define CONV_GET(pzv) ((php_converter_object*)zend_objects_get_address((pzv) TSRMLS_CC)) +#define THROW_UFAILURE(obj, fname, error) php_converter_throw_failure(obj, error TSRMLS_CC, \ + fname "() returned error %ld: %s", (long)error, u_errorName(error)) + +/* {{{ php_converter_throw_failure */ +static inline void php_converter_throw_failure(php_converter_object *objval, UErrorCode error TSRMLS_DC, const char *format, ...) { + intl_error *err = objval ? &(objval->error) : NULL; + char message[1024]; + va_list vargs; + + va_start(vargs, format); + vsnprintf(message, sizeof(message), format, vargs); + va_end(vargs); + + intl_error_set_code(err, error TSRMLS_CC); + intl_error_set_custom_msg(err, message, 1 TSRMLS_CC); +} +/* }}} */ + +/* {{{ php_converter_default_callback */ +static void php_converter_default_callback(zval *return_value, zval *zobj, long reason, zval *error TSRMLS_DC) { + /* Basic functionality so children can call parent::toUCallback() */ + switch (reason) { + case UCNV_UNASSIGNED: + case UCNV_ILLEGAL: + case UCNV_IRREGULAR: + { + php_converter_object *objval = (php_converter_object*)CONV_GET(zobj); + char chars[127]; + int8_t chars_len = sizeof(chars); + UErrorCode error = U_ZERO_ERROR; + + /* Yes, this is fairly wasteful at first glance, + * but considering that the alternative is to store + * what's sent into setSubstChars() and the fact + * that this is an extremely unlikely codepath + * I'd rather take the CPU hit here, than waste time + * storing a value I'm unlikely to use. + */ + ucnv_getSubstChars(objval->src, chars, &chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getSubstChars", error); + chars[0] = 0x1A; + chars[1] = 0; + chars_len = 1; + } + RETVAL_STRINGL(chars, chars_len, 1); + } + } + zval_dtor(error); + ZVAL_LONG(error, U_ZERO_ERROR); +} +/* }}} */ + +/* {{{ proto void UConverter::toUCallback(long $reason, + string $source, string $codeUnits, + long &$error) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_toUCallback_arginfo, 0, ZEND_RETURN_VALUE, 5) + ZEND_ARG_INFO(0, reason) + ZEND_ARG_INFO(0, source) + ZEND_ARG_INFO(0, codeUnits) + ZEND_ARG_INFO(1, error) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, toUCallback) { + long reason; + zval *source, *codeUnits, *error; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lzzz", + &reason, &source, &codeUnits, &error) == FAILURE) { + return; + } + + php_converter_default_callback(return_value, getThis(), reason, error TSRMLS_CC); +} +/* }}} */ + +/* {{{ proto void UConverter::fromUCallback(long $reason, + Array $source, long $codePoint, + long &$error) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_fromUCallback_arginfo, 0, ZEND_RETURN_VALUE, 5) + ZEND_ARG_INFO(0, reason) + ZEND_ARG_INFO(0, source) + ZEND_ARG_INFO(0, codePoint) + ZEND_ARG_INFO(1, error) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, fromUCallback) { + long reason; + zval *source, *codePoint, *error; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lzzz", + &reason, &source, &codePoint, &error) == FAILURE) { + return; + } + + php_converter_default_callback(return_value, getThis(), reason, error TSRMLS_CC); +} +/* }}} */ + +/* {{{ php_converter_check_limits */ +static inline zend_bool php_converter_check_limits(php_converter_object *objval, long available, long needed TSRMLS_DC) { + if (available < needed) { + php_converter_throw_failure(objval, U_BUFFER_OVERFLOW_ERROR TSRMLS_CC, "Buffer overrun %ld bytes needed, %ld available", needed, available); + return 0; + } + return 1; +} +/* }}} */ + +#define TARGET_CHECK(cnvargs, needed) php_converter_check_limits(objval, cnvargs->targetLimit - cnvargs->target, needed TSRMLS_CC) + +/* {{{ php_converter_append_toUnicode_target */ +static void php_converter_append_toUnicode_target(zval *val, UConverterToUnicodeArgs *args, php_converter_object *objval TSRMLS_DC) { + switch (Z_TYPE_P(val)) { + case IS_NULL: + /* Code unit is being skipped */ + return; + case IS_LONG: + { + long lval = Z_LVAL_P(val); + if ((lval < 0) || (lval > 0x10FFFF)) { + php_converter_throw_failure(objval, U_ILLEGAL_ARGUMENT_ERROR TSRMLS_CC, "Invalid codepoint U+%04lx", lval); + return; + } + if (lval > 0xFFFF) { + /* Supplemental planes U+010000 - U+10FFFF */ + if (TARGET_CHECK(args, 2)) { + /* TODO: Find the ICU call which does this properly */ + *(args->target++) = (UChar)(((lval - 0x10000) >> 10) | 0xD800); + *(args->target++) = (UChar)(((lval - 0x10000) & 0x3FF) | 0xDC00); + } + return; + } + /* Non-suggogate BMP codepoint */ + if (TARGET_CHECK(args, 1)) { + *(args->target++) = (UChar)lval; + } + return; + } + case IS_STRING: + { + const char *strval = Z_STRVAL_P(val); + int i = 0, strlen = Z_STRLEN_P(val); + + while((i != strlen) && TARGET_CHECK(args, 1)) { + UChar c; + U8_NEXT(strval, i, strlen, c); + *(args->target++) = c; + } + return; + } + case IS_ARRAY: + { + HashTable *ht = Z_ARRVAL_P(val); + HashPosition pos; + zval **tmpzval; + + for(zend_hash_internal_pointer_reset_ex(ht, &pos); + zend_hash_get_current_data_ex(ht, (void**)&tmpzval, &pos) == SUCCESS; + zend_hash_move_forward_ex(ht, &pos)) { + php_converter_append_toUnicode_target(*tmpzval, args, objval TSRMLS_CC); + } + return; + } + default: + php_converter_throw_failure(objval, U_ILLEGAL_ARGUMENT_ERROR TSRMLS_CC, + "toUCallback() specified illegal type for substitution character"); + } +} +/* }}} */ + +/* {{{ php_converter_to_u_callback */ +static void php_converter_to_u_callback(const void *context, + UConverterToUnicodeArgs *args, + const char *codeUnits, int32_t length, + UConverterCallbackReason reason, + UErrorCode *pErrorCode) { + php_converter_object *objval = (php_converter_object*)context; + zval *zreason, *zsource, *zcodeunits, *zerror, *retval = NULL; + zval **zargs[4]; +#ifdef ZTS + TSRMLS_D = objval->tsrm_ls; +#endif + + MAKE_STD_ZVAL(zreason); + ZVAL_LONG(zreason, reason); + zargs[0] = &zreason; + + MAKE_STD_ZVAL(zsource); + ZVAL_STRINGL(zsource, args->source, args->sourceLimit - args->source, 1); + zargs[1] = &zsource; + + MAKE_STD_ZVAL(zcodeunits); + ZVAL_STRINGL(zcodeunits, codeUnits, length, 1); + zargs[2] = &zcodeunits; + + MAKE_STD_ZVAL(zerror); + ZVAL_LONG(zerror, *pErrorCode); + zargs[3] = &zerror; + + objval->to_cb.param_count = 4; + objval->to_cb.params = zargs; + objval->to_cb.retval_ptr_ptr = &retval; + objval->to_cb.no_separation = 0; + if (zend_call_function(&(objval->to_cb), &(objval->to_cache) TSRMLS_CC) == FAILURE) { + /* Unlikely */ + php_converter_throw_failure(objval, U_INTERNAL_PROGRAM_ERROR TSRMLS_CC, "Unexpected failure calling toUCallback()"); + } else if (retval) { + php_converter_append_toUnicode_target(retval, args, objval TSRMLS_CC); + zval_ptr_dtor(&retval); + } + + if (Z_TYPE_P(zerror) == IS_LONG) { + *pErrorCode = Z_LVAL_P(zerror); + } + + zval_ptr_dtor(&zreason); + zval_ptr_dtor(&zsource); + zval_ptr_dtor(&zcodeunits); + zval_ptr_dtor(&zerror); +} +/* }}} */ + +/* {{{ php_converter_append_fromUnicode_target */ +static void php_converter_append_fromUnicode_target(zval *val, UConverterFromUnicodeArgs *args, php_converter_object *objval TSRMLS_DC) { + switch (Z_TYPE_P(val)) { + case IS_NULL: + /* Ignore */ + return; + case IS_LONG: + if (TARGET_CHECK(args, 1)) { + *(args->target++) = Z_LVAL_P(val); + } + return; + case IS_STRING: + { + int vallen = Z_STRLEN_P(val); + if (TARGET_CHECK(args, vallen)) { + memcpy(args->target, Z_STRVAL_P(val), vallen); + args->target += vallen; + } + return; + } + case IS_ARRAY: + { + HashTable *ht = Z_ARRVAL_P(val); + HashPosition pos; + zval **tmpzval; + for(zend_hash_internal_pointer_reset_ex(ht, &pos); + zend_hash_get_current_data_ex(ht, (void**)&tmpzval, &pos) == SUCCESS; + zend_hash_move_forward_ex(ht, &pos)) { + php_converter_append_fromUnicode_target(*tmpzval, args, objval TSRMLS_CC); + } + return; + } + default: + php_converter_throw_failure(objval, U_ILLEGAL_ARGUMENT_ERROR TSRMLS_CC, "fromUCallback() specified illegal type for substitution character"); + } +} +/* }}} */ + +/* {{{ php_converter_from_u_callback */ +static void php_converter_from_u_callback(const void *context, + UConverterFromUnicodeArgs *args, + const UChar *codeUnits, int32_t length, UChar32 codePoint, + UConverterCallbackReason reason, + UErrorCode *pErrorCode) { + php_converter_object *objval = (php_converter_object*)context; + zval *zreason, *zsource, *zcodepoint, *zerror, *retval = NULL; + zval **zargs[4]; + int i; +#ifdef ZTS + TSRMLS_D = objval->tsrm_ls; +#endif + + MAKE_STD_ZVAL(zreason); + ZVAL_LONG(zreason, reason); + zargs[0] = &zreason; + + MAKE_STD_ZVAL(zsource); + array_init(zsource); + i = 0; + while (i < length) { + UChar32 c; + U16_NEXT(codeUnits, i, length, c); + add_next_index_long(zsource, c); + } + zargs[1] = &zsource; + + MAKE_STD_ZVAL(zcodepoint); + ZVAL_LONG(zcodepoint, codePoint); + zargs[2] = &zcodepoint; + + MAKE_STD_ZVAL(zerror); + ZVAL_LONG(zerror, *pErrorCode); + zargs[3] = &zerror; + + objval->from_cb.param_count = 4; + objval->from_cb.params = zargs; + objval->from_cb.retval_ptr_ptr = &retval; + objval->from_cb.no_separation = 0; + if (zend_call_function(&(objval->from_cb), &(objval->from_cache) TSRMLS_CC) == FAILURE) { + /* Unlikely */ + php_converter_throw_failure(objval, U_INTERNAL_PROGRAM_ERROR TSRMLS_CC, "Unexpected failure calling fromUCallback()"); + } else if (retval) { + php_converter_append_fromUnicode_target(retval, args, objval TSRMLS_CC); + zval_ptr_dtor(&retval); + } + + if (Z_TYPE_P(zerror) == IS_LONG) { + *pErrorCode = Z_LVAL_P(zerror); + } + + zval_ptr_dtor(&zreason); + zval_ptr_dtor(&zsource); + zval_ptr_dtor(&zcodepoint); + zval_ptr_dtor(&zerror); +} +/* }}} */ + +/* {{{ php_converter_set_callbacks */ +static inline zend_bool php_converter_set_callbacks(php_converter_object *objval, UConverter *cnv TSRMLS_DC) { + zend_bool ret = 1; + UErrorCode error = U_ZERO_ERROR; + + if (objval->obj.ce == php_converter_ce) { + /* Short-circuit having to go through method calls and data marshalling + * when we're using default behavior + */ + return 1; + } + + ucnv_setToUCallBack(cnv, (UConverterToUCallback)php_converter_to_u_callback, (const void*)objval, + NULL, NULL, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setToUCallBack", error); + ret = 0; + } + + error = U_ZERO_ERROR; + ucnv_setFromUCallBack(cnv, (UConverterFromUCallback)php_converter_from_u_callback, (const void*)objval, + NULL, NULL, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setFromUCallBack", error); + ret = 0; + } + return ret; +} +/* }}} */ + +/* {{{ php_converter_set_encoding */ +static zend_bool php_converter_set_encoding(php_converter_object *objval, + UConverter **pcnv, + const char *enc, int enc_len + TSRMLS_DC) { + UErrorCode error = U_ZERO_ERROR; + UConverter *cnv = ucnv_open(enc, &error); + + if (error == U_AMBIGUOUS_ALIAS_WARNING) { + UErrorCode getname_error = U_ZERO_ERROR; + const char *actual_encoding = ucnv_getName(cnv, &getname_error); + if (U_FAILURE(getname_error)) { + /* Should never happen */ + actual_encoding = "(unknown)"; + } + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Ambiguous encoding specified, using %s", actual_encoding); + } else if (U_FAILURE(error)) { + if (objval) { + THROW_UFAILURE(objval, "ucnv_open", error); + } else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Error setting encoding: %d - %s", (int)error, u_errorName(error)); + } + return 0; + } + + if (objval && !php_converter_set_callbacks(objval, cnv TSRMLS_CC)) { + return 0; + } + + if (*pcnv) { + ucnv_close(*pcnv); + } + *pcnv = cnv; + return 1; +} +/* }}} */ + +/* {{{ php_converter_do_set_encoding */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_set_encoding_arginfo, 0, ZEND_RETURN_VALUE, 1) + ZEND_ARG_INFO(0, encoding) +ZEND_END_ARG_INFO(); +static void php_converter_do_set_encoding(UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { + php_converter_object *objval = CONV_GET(getThis()); + char *enc; + int enc_len; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &enc, &enc_len) == FAILURE) { + return; + } + + RETURN_BOOL(php_converter_set_encoding(objval, &(objval->src), enc, enc_len TSRMLS_CC)); +} +/* }}} */ + +/* {{{ proto bool UConverter::setSourceEncoding(string encoding) */ +static PHP_METHOD(UConverter, setSourceEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_set_encoding(objval->src, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto bool UConverter::setDestinationEncoding(string encoding) */ +static PHP_METHOD(UConverter, setDestinationEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_set_encoding(objval->dest, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ php_converter_do_get_encoding */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_get_encoding_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static void php_converter_do_get_encoding(php_converter_object *objval, UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { + UErrorCode error = U_ZERO_ERROR; + const char *name; + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + if (!cnv) { + RETURN_NULL(); + } + + name = ucnv_getName(cnv, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getName()", error); + RETURN_NULL(); + } + + RETURN_STRING(name, 1); +} +/* }}} */ + +/* {{{ proto string UConverter::getSourceEncoding() */ +static PHP_METHOD(UConverter, getSourceEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_encoding(objval, objval->src, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string UConverter::getDestinationEncoding() */ +static PHP_METHOD(UConverter, getDestinationEncoding) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_encoding(objval, objval->dest, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ php_converter_do_get_type */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_get_type_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static void php_converter_do_get_type(php_converter_object *objval, UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { + UErrorCode error = U_ZERO_ERROR; + UConverterType t; + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + if (!cnv) { + RETURN_NULL(); + } + + t = ucnv_getType(cnv); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getType", error); + RETURN_NULL(); + } + + RETURN_LONG(t); +} +/* }}} */ + +/* {{{ proto long UConverter::getSourceType() */ +static PHP_METHOD(UConverter, getSourceType) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_type(objval, objval->src, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto long UConverter::getDestinationType() */ +static PHP_METHOD(UConverter, getDestinationType) { + php_converter_object *objval = CONV_GET(getThis()); + php_converter_do_get_type(objval, objval->dest, INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ php_converter_resolve_callback */ +static void php_converter_resolve_callback(zval *zobj, + php_converter_object *objval, + const char *callback_name, + zend_fcall_info *finfo, + zend_fcall_info_cache *fcache TSRMLS_DC) { + char *errstr = NULL; + zval caller; + + array_init(&caller); + Z_ADDREF_P(zobj); + add_index_zval(&caller, 0, zobj); + add_index_string(&caller, 1, callback_name, 1); + if (zend_fcall_info_init(&caller, 0, finfo, fcache, NULL, &errstr TSRMLS_CC) == FAILURE) { + php_converter_throw_failure(objval, U_INTERNAL_PROGRAM_ERROR TSRMLS_CC, "Error setting converter callback: %s", errstr); + } + zval_dtor(&caller); + if (errstr) { + efree(errstr); + } +} +/* }}} */ + +/* {{{ proto void UConverter::__construct([string dest = 'utf-8',[string src = 'utf-8']]) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_arginfo, 0, ZEND_RETURN_VALUE, 0) + ZEND_ARG_INFO(0, destination_encoding) + ZEND_ARG_INFO(0, source_encoding) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, __construct) { + php_converter_object *objval = CONV_GET(getThis()); + char *src = "utf-8"; + int src_len = sizeof("utf-8") - 1; + char *dest = src; + int dest_len = src_len; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!s!", + &dest, &dest_len, &src, &src_len) == FAILURE) { + return; + } + + php_converter_set_encoding(objval, &(objval->src), src, src_len TSRMLS_CC); + php_converter_set_encoding(objval, &(objval->dest), dest, dest_len TSRMLS_CC); + php_converter_resolve_callback(getThis(), objval, "toUCallback", &(objval->to_cb), &(objval->to_cache) TSRMLS_CC); + php_converter_resolve_callback(getThis(), objval, "fromUCallback", &(objval->from_cb), &(objval->from_cache) TSRMLS_CC); +} +/* }}} */ + +/* {{{ proto bool UConverter::setSubstChars(string $chars) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_setSubstChars_arginfo, 0, ZEND_RETURN_VALUE, 1) + ZEND_ARG_INFO(0, chars) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, setSubstChars) { + php_converter_object *objval = CONV_GET(getThis()); + char *chars; + int chars_len, ret = 1; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &chars, &chars_len) == FAILURE) { + return; + } + + if (objval->src) { + UErrorCode error = U_ZERO_ERROR; + ucnv_setSubstChars(objval->src, chars, chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setSubstChars", error); + ret = 0; + } + } else { + php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, "Source Converter has not been initialized yet"); + } + + if (objval->dest) { + UErrorCode error = U_ZERO_ERROR; + ucnv_setSubstChars(objval->dest, chars, chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_setSubstChars", error); + ret = 0; + } + } else { + php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, "Destination Converter has not been initialized yet"); + } + + RETURN_BOOL(ret); +} +/* }}} */ + +/* {{{ proto string UConverter::getSubstChars() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getSubstChars_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, getSubstChars) { + php_converter_object *objval = CONV_GET(getThis()); + char chars[127]; + int8_t chars_len = sizeof(chars); + UErrorCode error = U_ZERO_ERROR; + + if (!objval->src) { + RETURN_NULL(); + } + + /* src and dest get the same subst chars set, + * so it doesn't really matter which one we read from + */ + ucnv_getSubstChars(objval->src, chars, &chars_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_getSubstChars", error); + RETURN_NULL(); + } + + RETURN_STRINGL(chars, chars_len, 1); +} +/* }}} */ + +/* {{{ php_converter_do_convert */ +static zend_bool php_converter_do_convert(UConverter *dest_cnv, char **pdest, int32_t *pdest_len, + UConverter *src_cnv, const char *src, int32_t src_len, + php_converter_object *objval + TSRMLS_DC) { + UErrorCode error = U_ZERO_ERROR; + int32_t dest_len; + char *dest; + + if (!src_cnv || !dest_cnv) { + php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, + "Internal converters not initialized"); + return 0; + } + + /* Get necessary buffer size first */ + int32_t temp_len = 1 + ucnv_toUChars(src_cnv, NULL, 0, src, src_len, &error); + if (U_FAILURE(error) && error != U_BUFFER_OVERFLOW_ERROR) { + THROW_UFAILURE(objval, "ucnv_toUChars", error); + return 0; + } + UChar *temp = safe_emalloc(sizeof(UChar), temp_len, sizeof(UChar)); + + /* Convert to intermediate UChar* array */ + error = U_ZERO_ERROR; + temp_len = ucnv_toUChars(src_cnv, temp, temp_len, src, src_len, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_toUChars", error); + efree(temp); + return 0; + } + temp[temp_len] = 0; + + /* Get necessary output buffer size */ + dest_len = 1 + ucnv_fromUChars(dest_cnv, NULL, 0, temp, temp_len, &error); + if (U_FAILURE(error) && error != U_BUFFER_OVERFLOW_ERROR) { + THROW_UFAILURE(objval, "ucnv_fromUChars", error); + efree(temp); + return 0; + } + dest = safe_emalloc(sizeof(char), dest_len, sizeof(char)); + + /* Convert to final encoding */ + error = U_ZERO_ERROR; + dest_len = ucnv_fromUChars(dest_cnv, dest, dest_len, temp, temp_len, &error); + efree(temp); + if (U_FAILURE(error)) { + THROW_UFAILURE(objval, "ucnv_fromUChars", error); + efree(dest); + return 0; + } + + *pdest = dest; + if (pdest_len) { + *pdest_len = dest_len; + } + + return 1; +} +/* }}} */ + +/* {{{ proto string UConverter::reasonText(long reason) */ +#define UCNV_REASON_CASE(v) case (UCNV_ ## v) : RETURN_STRINGL( "REASON_" #v , sizeof( "REASON_" #v ) - 1, 1); +ZEND_BEGIN_ARG_INFO_EX(php_converter_reasontext_arginfo, 0, ZEND_RETURN_VALUE, 0) + ZEND_ARG_INFO(0, reason) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, reasonText) { + long reason; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &reason) == FAILURE) { + return; + } + + switch (reason) { + UCNV_REASON_CASE(UNASSIGNED) + UCNV_REASON_CASE(ILLEGAL) + UCNV_REASON_CASE(IRREGULAR) + UCNV_REASON_CASE(RESET) + UCNV_REASON_CASE(CLOSE) + UCNV_REASON_CASE(CLONE) + default: + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown UConverterCallbackReason: %ld", reason); + RETURN_NULL(); + } +} +/* }}} */ + +/* {{{ proto string UConverter::convert(string str[, bool reverse]) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_convert_arginfo, 0, ZEND_RETURN_VALUE, 1) + ZEND_ARG_INFO(0, str) + ZEND_ARG_INFO(0, reverse) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, convert) { + php_converter_object *objval = CONV_GET(getThis()); + char *str, *dest; + int str_len, dest_len; + zend_bool reverse = 0; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b!", + &str, &str_len, &reverse) == FAILURE) { + return; + } + + if (php_converter_do_convert(reverse ? objval->src : objval->dest, + &dest, &dest_len, + reverse ? objval->dest : objval->src, + str, str_len, + objval TSRMLS_CC)) { + RETURN_STRINGL(dest, dest_len, 0); + } else { + RETURN_NULL(); + } +} +/* }}} */ + +/* {{{ proto string UConverter::transcode(string $str, string $toEncoding, string $fromEncoding[, Array $options = array()]) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_transcode_arginfo, 0, ZEND_RETURN_VALUE, 3) + ZEND_ARG_INFO(0, str) + ZEND_ARG_INFO(0, toEncoding) + ZEND_ARG_INFO(0, fromEncoding) + ZEND_ARG_ARRAY_INFO(0, options, 1) +ZEND_END_ARG_INFO(); + +static PHP_METHOD(UConverter, transcode) { + char *str, *src, *dest; + int str_len, src_len, dest_len; + zval *options = NULL; + UConverter *src_cnv = NULL, *dest_cnv = NULL; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|a!", + &str, &str_len, &dest, &dest_len, &src, &src_len, &options) == FAILURE) { + return; + } + + if (php_converter_set_encoding(NULL, &src_cnv, src, src_len TSRMLS_CC) && + php_converter_set_encoding(NULL, &dest_cnv, dest, dest_len TSRMLS_CC)) { + char *out = NULL; + int out_len = 0; + UErrorCode error = U_ZERO_ERROR; + + if (options && zend_hash_num_elements(Z_ARRVAL_P(options))) { + zval **tmpzval; + + if (U_SUCCESS(error) && + zend_hash_find(Z_ARRVAL_P(options), "from_subst", sizeof("from_subst"), (void**)&tmpzval) == SUCCESS && + Z_TYPE_PP(tmpzval) == IS_STRING) { + error = U_ZERO_ERROR; + ucnv_setSubstChars(src_cnv, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval) & 0x7F, &error); + } + if (U_SUCCESS(error) && + zend_hash_find(Z_ARRVAL_P(options), "to_subst", sizeof("to_subst"), (void**)&tmpzval) == SUCCESS && + Z_TYPE_PP(tmpzval) == IS_STRING) { + error = U_ZERO_ERROR; + ucnv_setSubstChars(dest_cnv, Z_STRVAL_PP(tmpzval), Z_STRLEN_PP(tmpzval) & 0x7F, &error); + } + } + + if (U_SUCCESS(error) && + php_converter_do_convert(dest_cnv, &out, &out_len, src_cnv, str, str_len, NULL TSRMLS_CC)) { + RETVAL_STRINGL(out, out_len, 0); + } + + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "transcode", error); + } + } + + if (src_cnv) { + ucnv_close(src_cnv); + } + if (dest_cnv) { + ucnv_close(dest_cnv); + } +} +/* }}} */ + +/* {{{ proto int UConverter::getErrorCode() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_geterrorcode_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getErrorCode) { + php_converter_object *objval = CONV_GET(getThis()); + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + RETURN_LONG(intl_error_get_code(&(objval->error) TSRMLS_CC)); +} +/* }}} */ + +/* {{{ proto string UConverter::getErrorMessage() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_geterrormsg_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getErrorMessage) { + php_converter_object *objval = CONV_GET(getThis()); + char *message = intl_error_get_message(&(objval->error) TSRMLS_CC); + + if (ZEND_NUM_ARGS() > 0) { + WRONG_PARAM_COUNT; + } + + if (message) { + RETURN_STRING(message, 1); + } else { + RETURN_NULL(); + } +} +/* }}} */ + +/* {{{ proto array UConverter::getAvailable() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getavailable_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getAvailable) { + int32_t i, count = ucnv_countAvailable(); + + array_init(return_value); + for(i = 0; i < count; i++) { + const char *name = ucnv_getAvailableName(i); + add_next_index_string(return_value, name, 1); + } +} +/* }}} */ + +/* {{{ proto array UConverter::getAliases(string name) */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getaliases_arginfo, 0, ZEND_RETURN_VALUE, 0) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getAliases) { + char *name; + int name_len; + UErrorCode error = U_ZERO_ERROR; + uint16_t i, count; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name, &name_len) == FAILURE) { + return; + } + + count = ucnv_countAliases(name, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "ucnv_countAliases", error); + return; + } + + array_init(return_value); + for(i = 0; i < count; i++) { + error = U_ZERO_ERROR; + const char *alias = ucnv_getAlias(name, i, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "ucnv_getAlias", error); + zval_dtor(return_value); + RETURN_NULL(); + } + add_next_index_string(return_value, alias, 1); + } +} +/* }}} */ + +/* {{{ proto array UConverter::getStandards() */ +ZEND_BEGIN_ARG_INFO_EX(php_converter_getstandards_arginfo, 0, ZEND_RETURN_VALUE, 0) +ZEND_END_ARG_INFO(); +static PHP_METHOD(UConverter, getStandards) { + uint16_t i, count; + + array_init(return_value); + count = ucnv_countStandards(); + for(i = 0; i < count; i++) { + UErrorCode error = U_ZERO_ERROR; + const char *name = ucnv_getStandard(i, &error); + if (U_FAILURE(error)) { + THROW_UFAILURE(NULL, "ucnv_getStandard", error); + zval_dtor(return_value); + RETURN_NULL(); + } + add_next_index_string(return_value, name, 1); + } +} +/* }}} */ + +static zend_function_entry php_converter_methods[] = { + PHP_ME(UConverter, __construct, php_converter_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_CTOR) + + /* Encoding selection */ + PHP_ME(UConverter, setSourceEncoding, php_converter_set_encoding_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, setDestinationEncoding, php_converter_set_encoding_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getSourceEncoding, php_converter_get_encoding_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getDestinationEncoding, php_converter_get_encoding_arginfo, ZEND_ACC_PUBLIC) + + /* Introspection for algorithmic converters */ + PHP_ME(UConverter, getSourceType, php_converter_get_type_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getDestinationType, php_converter_get_type_arginfo, ZEND_ACC_PUBLIC) + + /* Basic codeunit error handling */ + PHP_ME(UConverter, getSubstChars, php_converter_getSubstChars_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, setSubstChars, php_converter_setSubstChars_arginfo, ZEND_ACC_PUBLIC) + + /* Default callback handlers */ + PHP_ME(UConverter, toUCallback, php_converter_toUCallback_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, fromUCallback, php_converter_fromUCallback_arginfo, ZEND_ACC_PUBLIC) + + /* Core conversion workhorses */ + PHP_ME(UConverter, convert, php_converter_convert_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, transcode, php_converter_transcode_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + + /* Error inspection */ + PHP_ME(UConverter, getErrorCode, php_converter_geterrorcode_arginfo, ZEND_ACC_PUBLIC) + PHP_ME(UConverter, getErrorMessage, php_converter_geterrormsg_arginfo, ZEND_ACC_PUBLIC) + + /* Ennumeration and lookup */ + PHP_ME(UConverter, reasonText, php_converter_reasontext_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + PHP_ME(UConverter, getAvailable, php_converter_getavailable_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + PHP_ME(UConverter, getAliases, php_converter_getaliases_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + PHP_ME(UConverter, getStandards, php_converter_getstandards_arginfo, ZEND_ACC_PUBLIC | ZEND_ACC_STATIC) + { NULL, NULL, NULL } +}; + +/* {{{ Converter create/clone/destroy */ +static void php_converter_free_object(php_converter_object *objval TSRMLS_DC) { + if (objval->src) { + ucnv_close(objval->src); + } + + if (objval->dest) { + ucnv_close(objval->dest); + } + + intl_error_reset(&(objval->error) TSRMLS_CC); + zend_object_std_dtor(&(objval->obj) TSRMLS_CC); + + efree(objval); +} + +static zend_object_value php_converter_object_ctor(zend_class_entry *ce, php_converter_object **pobjval TSRMLS_DC) { + php_converter_object *objval; + zend_object_value retval; + + objval = ecalloc(1, sizeof(php_converter_object)); + objval->obj.ce = ce; + +#ifdef ZTS + objval->tsrm_ls = TSRMLS_C; +#endif + intl_error_init(&(objval->error) TSRMLS_CC); + + retval.handle = zend_objects_store_put(objval, NULL, (zend_objects_free_object_storage_t)php_converter_free_object, NULL TSRMLS_CC); + retval.handlers = &php_converter_object_handlers; + *pobjval = objval; + + return retval; +} + +static zend_object_value php_converter_create_object(zend_class_entry *ce TSRMLS_DC) { + php_converter_object *objval = NULL; + zend_object_value retval = php_converter_object_ctor(ce, &objval TSRMLS_CC); + + object_properties_init(&(objval->obj), ce); + + return retval; +} + +static zend_object_value php_converter_clone_object(zval *object TSRMLS_DC) { + php_converter_object *objval, *oldobj = (php_converter_object*)zend_objects_get_address(object TSRMLS_CC); + zend_object_value retval = php_converter_object_ctor(Z_OBJCE_P(object), &objval TSRMLS_CC); + UErrorCode error = U_ZERO_ERROR; + objval->src = ucnv_safeClone(oldobj->src, NULL, NULL, &error); + if (U_SUCCESS(error)) { + error = U_ZERO_ERROR; + objval->dest = ucnv_safeClone(oldobj->dest, NULL, NULL, &error); + } + if (U_FAILURE(error)) { + THROW_UFAILURE(oldobj, "ucnv_safeClone", error); + } + + /* Update contexts for converter error handlers */ + php_converter_set_callbacks(objval, objval->src TSRMLS_CC); + php_converter_set_callbacks(objval, objval->dest TSRMLS_CC); + + zend_objects_clone_members(&(objval->obj), retval, &(oldobj->obj), Z_OBJ_HANDLE_P(object) TSRMLS_CC); + + /* Newly cloned object deliberately does not inherit error state from original object */ + + return retval; +} +/* }}} */ + +#define CONV_REASON_CONST(v) zend_declare_class_constant_long(php_converter_ce, "REASON_" #v, sizeof("REASON_" #v) - 1, UCNV_ ## v TSRMLS_CC) +#define CONV_TYPE_CONST(v) zend_declare_class_constant_long(php_converter_ce, #v , sizeof(#v) - 1, UCNV_ ## v TSRMLS_CC) + +/* {{{ php_converter_minit */ +int php_converter_minit(INIT_FUNC_ARGS) { + zend_class_entry ce; + + INIT_CLASS_ENTRY(ce, "UConverter", php_converter_methods); + php_converter_ce = zend_register_internal_class(&ce TSRMLS_CC); + php_converter_ce->create_object = php_converter_create_object; + memcpy(&php_converter_object_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); + php_converter_object_handlers.clone_obj = php_converter_clone_object; + + /* enum UConverterCallbackReason */ + CONV_REASON_CONST(UNASSIGNED); + CONV_REASON_CONST(ILLEGAL); + CONV_REASON_CONST(IRREGULAR); + CONV_REASON_CONST(RESET); + CONV_REASON_CONST(CLOSE); + CONV_REASON_CONST(CLONE); + + /* enum UConverterType */ + CONV_TYPE_CONST(UNSUPPORTED_CONVERTER); + CONV_TYPE_CONST(SBCS); + CONV_TYPE_CONST(DBCS); + CONV_TYPE_CONST(MBCS); + CONV_TYPE_CONST(LATIN_1); + CONV_TYPE_CONST(UTF8); + CONV_TYPE_CONST(UTF16_BigEndian); + CONV_TYPE_CONST(UTF16_LittleEndian); + CONV_TYPE_CONST(UTF32_BigEndian); + CONV_TYPE_CONST(UTF32_LittleEndian); + CONV_TYPE_CONST(EBCDIC_STATEFUL); + CONV_TYPE_CONST(ISO_2022); + CONV_TYPE_CONST(LMBCS_1); + CONV_TYPE_CONST(LMBCS_2); + CONV_TYPE_CONST(LMBCS_3); + CONV_TYPE_CONST(LMBCS_4); + CONV_TYPE_CONST(LMBCS_5); + CONV_TYPE_CONST(LMBCS_6); + CONV_TYPE_CONST(LMBCS_8); + CONV_TYPE_CONST(LMBCS_11); + CONV_TYPE_CONST(LMBCS_16); + CONV_TYPE_CONST(LMBCS_17); + CONV_TYPE_CONST(LMBCS_18); + CONV_TYPE_CONST(LMBCS_19); + CONV_TYPE_CONST(LMBCS_LAST); + CONV_TYPE_CONST(HZ); + CONV_TYPE_CONST(SCSU); + CONV_TYPE_CONST(ISCII); + CONV_TYPE_CONST(US_ASCII); + CONV_TYPE_CONST(UTF7); + CONV_TYPE_CONST(BOCU1); + CONV_TYPE_CONST(UTF16); + CONV_TYPE_CONST(UTF32); + CONV_TYPE_CONST(CESU8); + CONV_TYPE_CONST(IMAP_MAILBOX); + + return SUCCESS; +} +/* }}} */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/ext/intl/converter/converter.h b/ext/intl/converter/converter.h new file mode 100644 index 0000000000000..bd316fcf983ad --- /dev/null +++ b/ext/intl/converter/converter.h @@ -0,0 +1,28 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Sara Golemon | + +----------------------------------------------------------------------+ +*/ + +#ifndef PHP_INTL_CONVERTER_H +#define PHP_INTL_CONVERTER_H + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "php.h" + +int php_converter_minit(INIT_FUNC_ARGS); + +#endif /* PHP_INTL_CONVERTER_H */ diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c index d3d477c97159d..a2c4d77651d4b 100644 --- a/ext/intl/php_intl.c +++ b/ext/intl/php_intl.c @@ -34,6 +34,8 @@ #include "collator/collator_create.h" #include "collator/collator_error.h" +#include "converter/converter.h" + #include "formatter/formatter.h" #include "formatter/formatter_class.h" #include "formatter/formatter_attr.h" @@ -986,6 +988,9 @@ PHP_MINIT_FUNCTION( intl ) /* Global error handling. */ intl_error_init( NULL TSRMLS_CC ); + /* 'Converter' class for codepage conversions */ + php_converter_minit(INIT_FUNC_ARGS_PASSTHRU); + return SUCCESS; } /* }}} */ diff --git a/ext/intl/tests/uconverter_enum.phpt b/ext/intl/tests/uconverter_enum.phpt new file mode 100644 index 0000000000000..67e02c9d75470 --- /dev/null +++ b/ext/intl/tests/uconverter_enum.phpt @@ -0,0 +1,21 @@ +--TEST-- +UConverter Enumerations +--SKIPIF-- + +--FILE-- + 100); +var_dump(in_array('UTF-7', $avail)); +var_dump(in_array('CESU-8', $avail)); +var_dump(in_array('ISO-8859-1', $avail)); + +$latin1 = UConverter::getAliases('latin1'); +var_dump(in_array('ISO-8859-1', $latin1)); + +--EXPECT-- +bool(true) +bool(true) +bool(true) +bool(true) +bool(true) diff --git a/ext/intl/tests/uconverter_func_basic.phpt b/ext/intl/tests/uconverter_func_basic.phpt new file mode 100644 index 0000000000000..da8956beae128 --- /dev/null +++ b/ext/intl/tests/uconverter_func_basic.phpt @@ -0,0 +1,17 @@ +--TEST-- +Basic UConverter::transcode() usage +--SKIPIF-- + +--FILE-- + +--INI-- +intl.use_exceptions=false +--FILE-- + $subst); + $ret = UConverter::transcode("This is an ascii string", 'ascii', 'utf-8', $opts); + if ($ret === NULL) { + echo "Error: ", intl_get_error_message(), "\n"; + } else { + var_dump($ret); + } + $ret = UConverter::transcode("Snowman: (\xE2\x98\x83)", 'ascii', 'utf-8', $opts); + if ($ret === NULL) { + echo "Error: ", intl_get_error_message(), "\n"; + } else { + var_dump($ret); + } +} + +--EXPECTF-- +string(23) "This is an ascii string" +string(12) "Snowman: (?)" +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR +Error: transcode() returned error 1: U_ILLEGAL_ARGUMENT_ERROR: U_ILLEGAL_ARGUMENT_ERROR diff --git a/ext/intl/tests/uconverter_oop_algo.phpt b/ext/intl/tests/uconverter_oop_algo.phpt new file mode 100644 index 0000000000000..349182ce32c0f --- /dev/null +++ b/ext/intl/tests/uconverter_oop_algo.phpt @@ -0,0 +1,18 @@ +--TEST-- +UConverter Algorithmic converters +--SKIPIF-- + +--FILE-- +getSourceType()); +var_dump(UConverter::UTF8 === $c->getDestinationType()); + +$c = new UConverter('koi8-r', 'utf-32be'); +var_dump(UConverter::UTF32_BigEndian === $c->getSourceType()); +var_dump(UConverter::SBCS === $c->getDestinationType()); +--EXPECT-- +bool(true) +bool(true) +bool(true) +bool(true) diff --git a/ext/intl/tests/uconverter_oop_basic.phpt b/ext/intl/tests/uconverter_oop_basic.phpt new file mode 100644 index 0000000000000..2b8909ff31e71 --- /dev/null +++ b/ext/intl/tests/uconverter_oop_basic.phpt @@ -0,0 +1,21 @@ +--TEST-- +Basic UConverter::convert() usage +--SKIPIF-- + +--FILE-- +convert("This is an ascii string")); +// urlencode so that non-ascii shows up parsable in phpt file +var_dump(urlencode($c->convert("Espa\xF1ol"))); // U+00F1 LATIN SMALL LETTER N WITH TILDE +var_dump(urlencode($c->convert("Stra\xDFa"))); // U+00DF LATIN SMALL LETTER SHARP S +var_dump(urlencode($c->convert("Stra\xC3\x9Fa", true))); // Reverse prior op + +$k = new UConverter('utf-8', 'koi8-r'); +var_dump(bin2hex($k->convert("\xE4"))); // U+0414 CYRILLIC CAPITAL LETTER DE +--EXPECT-- +string(23) "This is an ascii string" +string(12) "Espa%C3%B1ol" +string(11) "Stra%C3%9Fa" +string(8) "Stra%DFa" +string(4) "d094" diff --git a/ext/intl/tests/uconverter_oop_callback.phpt b/ext/intl/tests/uconverter_oop_callback.phpt new file mode 100644 index 0000000000000..47daf4330586c --- /dev/null +++ b/ext/intl/tests/uconverter_oop_callback.phpt @@ -0,0 +1,52 @@ +--TEST-- +UConverter::convert() w/ Callback Reasons +--SKIPIF-- + +--FILE-- +convert($word); +} +--EXPECT-- +toUCallback(REASON_RESET, ...) +toUCallback(REASON_RESET, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_RESET, ...) +toUCallback(REASON_RESET, ...) +toUCallback(REASON_ILLEGAL, ...) +toUCallback(REASON_RESET, ...) +toUCallback(REASON_ILLEGAL, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +toUCallback(REASON_RESET, ...) +toUCallback(REASON_RESET, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +fromUCallback(REASON_RESET, ...) +fromUCallback(REASON_UNASSIGNED, ...) +toUCallback(REASON_CLOSE, ...) +fromUCallback(REASON_CLOSE, ...) +toUCallback(REASON_CLOSE, ...) +fromUCallback(REASON_CLOSE, ...) diff --git a/ext/intl/tests/uconverter_oop_callback_return.phpt b/ext/intl/tests/uconverter_oop_callback_return.phpt new file mode 100644 index 0000000000000..cd7e7a5834fd5 --- /dev/null +++ b/ext/intl/tests/uconverter_oop_callback_return.phpt @@ -0,0 +1,40 @@ +--TEST-- +UConverter::convert() w/ Callback Return Values +--SKIPIF-- + +--FILE-- +convert("\x80\x81\x82\x83")); +// This line will trigger fromUCallback +var_dump($c->convert("\xC3\xB1\xC3\xB2\xC3\xB3\xC3\xB4")); +--EXPECT-- +string(3) "abc" +string(3) "ABC" diff --git a/ext/intl/tests/uconverter_oop_subst.phpt b/ext/intl/tests/uconverter_oop_subst.phpt new file mode 100644 index 0000000000000..d21d95f8d0a12 --- /dev/null +++ b/ext/intl/tests/uconverter_oop_subst.phpt @@ -0,0 +1,24 @@ +--TEST-- +Basic UConverter::convert() w/ Subsitution +--SKIPIF-- + +--INI-- +intl.use_exceptions=false +--FILE-- +') as $subst) { + if (!$c->setSubstChars($subst)) { + echo "**Disallowed\n"; + continue; + } + var_dump($c->convert("This is an ascii string")); + var_dump($c->convert("Snowman: (\xE2\x98\x83)")); +} + +--EXPECT-- +string(23) "This is an ascii string" +string(12) "Snowman: (?)" +**Disallowed +**Disallowed From 4badc0c071e7c99946e7420707392e4de19d250e Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 29 Jan 2013 15:33:33 +0100 Subject: [PATCH 2313/2394] intl: doc explaining error conventions --- ext/intl/ERROR.CONVENTIONS | 83 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 ext/intl/ERROR.CONVENTIONS diff --git a/ext/intl/ERROR.CONVENTIONS b/ext/intl/ERROR.CONVENTIONS new file mode 100644 index 0000000000000..54f30edcaa9c1 --- /dev/null +++ b/ext/intl/ERROR.CONVENTIONS @@ -0,0 +1,83 @@ +The intl extension has particular conventions regarding error reporting. +These conventions are enumerated in this document. + +:: The last error is always stored globally. + +The global error code can be obtained in userland with intl_get_error_code(). +This is a U_* error code defined by ICU, but it does not have necessarily to be +returned obtained after a call to an ICU function. That is to say, the internal +PHP wrapper functions can set these error codes when appropriate. For instance, +in response to bad arguments (e.g. zend_parse_parameters() failure), the PHP +wrapper function should set the global error code to U_ILLEGAL_ARGUMENT_ERROR). + +The error code (an integer) can be converter to the corresponding enum name +string in userland with intl_error_name(). + +The associated message can be obtained with intl_get_error_message(). This is a +message set by the PHP wrapping code, not by ICU. The message should include the +name of the function that failed in order to make debugging easier (though if +you activate warnings with intl.error_level or exceptions with +intl.use_exceptions you get more fine-grained information about where the +error ocurred). + +The internal PHP code can set the global last error with: +void intl_error_set_code(intl_error* err, UErrorCode err_code TSRMLS_DC); +void intl_error_set_custom_msg(intl_error* err, char* msg, int copyMsg TSRMLS_DC); +void intl_error_set(intl_error* err, UErrorCode code, char* msg, int copyMsg TSRMLS_DC); + +and by passing NULL as the first parameter. The last function is a combination +of the first two. If the message is not a static buffer, copyMsg should be 1. +This makes the message string be copied and freed when no longer needed. There's +no way to pass ownership of the string without it being copied. + + +:: The last is ALSO stored in the object whose method call triggered the error, + unless the error is due to bad arguments, in which case only the global error + should be set + +Objects store an intl_error structed in their private data. For instance: +typedef struct { + zend_object zo; + intl_error err; + Calendar* ucal; +} Calendar_object; + +The global error and the object error can be SIMULTANEOUSLY set with these +functions: +void intl_errors_set_custom_msg(intl_error* err, char* msg, int copyMsg TSRMLS_DC); +void intl_errors_set_code(intl_error* err, UErrorCode err_code TSRMLS_DC); +void intl_errors_set(intl_error* err, UErrorCode code, char* msg, int copyMsg TSRMLS_DC); + +by passing a pointer to the object's intl_error structed as the first parameter. +Node the extra 's' in the functions' names ('errors', not 'error'). + +Static methods should only set the global error. + + +:: Intl classes that can be instantiated should provide ::getErrorCode() and + getErrorMessage() methods + +These methods are used to retrieve the error codes stored in the object's +private intl_error structured and mirror the global intl_get_error_code() and +intl_get_error_message(). + + +:: Intl methods and functions should return FALSE on error (even argument + parsing errors), not NULL. Constructors and factory methods are the + exception; these should return NULL, not FALSE. + +Not that constructors in Intl generally (always?) don't throws exceptions. +They instead destroy the object to that the result of new IntlClass() can +be NULL. This may be surprising. + + +:: Intl functions and methods should reset the global error before doing + anything else (even parse the arguments); instance methods should also reset + the object's private error + +Errors should be lost after a function call. This is different from the way +ICU operates, where functions return immediately if an error is set. + +Error resetting can be done with: +void intl_error_reset(NULL TSRMLS_DC); /* reset global error */ +void intl_errors_reset(intl_error* err TSRMLS_DC ); /* reset global and object error */ From b4ba46cb996e813ea3d99140cadbcc44822fcbe4 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 29 Jan 2013 15:43:58 +0100 Subject: [PATCH 2314/2394] Fix arginfo of BreakIterator::getLocale --- ext/intl/breakiterator/breakiterator_class.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/intl/breakiterator/breakiterator_class.cpp b/ext/intl/breakiterator/breakiterator_class.cpp index de4bfbb7b0dd1..7bf271a344f3b 100644 --- a/ext/intl/breakiterator/breakiterator_class.cpp +++ b/ext/intl/breakiterator/breakiterator_class.cpp @@ -296,7 +296,7 @@ static const zend_function_entry BreakIterator_class_functions[] = { PHP_ME_MAPPING(following, breakiter_following, ainfo_biter_offset, ZEND_ACC_PUBLIC) PHP_ME_MAPPING(preceding, breakiter_preceding, ainfo_biter_offset, ZEND_ACC_PUBLIC) PHP_ME_MAPPING(isBoundary, breakiter_is_boundary, ainfo_biter_offset, ZEND_ACC_PUBLIC) - PHP_ME_MAPPING(getLocale, breakiter_get_locale, ainfo_biter_void, ZEND_ACC_PUBLIC) + PHP_ME_MAPPING(getLocale, breakiter_get_locale, ainfo_biter_get_locale, ZEND_ACC_PUBLIC) PHP_ME_MAPPING(getPartsIterator, breakiter_get_parts_iterator, ainfo_biter_getPartsIterator, ZEND_ACC_PUBLIC) PHP_ME_MAPPING(getErrorCode, breakiter_get_error_code, ainfo_biter_void, ZEND_ACC_PUBLIC) From 363fd6d6fb5c962c8d1339dfaad2bd18373de36c Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 29 Jan 2013 16:17:55 +0100 Subject: [PATCH 2315/2394] Improve ERROR.CONVENTIONS --- ext/intl/ERROR.CONVENTIONS | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/ext/intl/ERROR.CONVENTIONS b/ext/intl/ERROR.CONVENTIONS index 54f30edcaa9c1..6f9079c56d04c 100644 --- a/ext/intl/ERROR.CONVENTIONS +++ b/ext/intl/ERROR.CONVENTIONS @@ -81,3 +81,35 @@ ICU operates, where functions return immediately if an error is set. Error resetting can be done with: void intl_error_reset(NULL TSRMLS_DC); /* reset global error */ void intl_errors_reset(intl_error* err TSRMLS_DC ); /* reset global and object error */ + +In practice, intl_errors_reset() is not used because most classes have also +plain functions mapped to the same internal functions as their instance methods. +Fetching of the object is done with zend_parse_method_parameters() instead of +directly using getThis(). Therefore, no reference to object is obtained until +the arguments are fully parsed. Without a reference to the object, there's no +way to reset the object's internal error code. Instead, resetting of the +object's internal error code is done upon fetching the object from its zval. + +Example: +U_CFUNC PHP_FUNCTION(breakiter_set_text) +{ + /* ... variable declations ... */ + BREAKITER_METHOD_INIT_VARS; /* macro also resets global error */ + object = getThis(); + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", + &text, &text_len) == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "breakiter_set_text: bad arguments", 0 TSRMLS_CC); + RETURN_FALSE; + } + + /* ... */ + + BREAKITER_METHOD_FETCH_OBJECT; /* macro also resets object's error */ + + /* ... */ +} + +Implementations of ::getErrorCode() and ::getErrorMessage() should not reset the +object's error code. From ee6522bebf5e5b4652d01da6e6eaec4cf59051b2 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 29 Jan 2013 16:36:14 +0100 Subject: [PATCH 2316/2394] Write local err on intlcal_get_time_zone() failure --- ext/intl/calendar/calendar_methods.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/intl/calendar/calendar_methods.cpp b/ext/intl/calendar/calendar_methods.cpp index f2758fdcc8b29..2d33bd1952f2f 100644 --- a/ext/intl/calendar/calendar_methods.cpp +++ b/ext/intl/calendar/calendar_methods.cpp @@ -782,7 +782,7 @@ U_CFUNC PHP_FUNCTION(intlcal_get_time_zone) TimeZone *tz = co->ucal->getTimeZone().clone(); if (tz == NULL) { - intl_error_set(NULL, U_MEMORY_ALLOCATION_ERROR, + intl_errors_set(CALENDAR_ERROR_P(co), U_MEMORY_ALLOCATION_ERROR, "intlcal_get_time_zone: could not clone TimeZone", 0 TSRMLS_CC); RETURN_FALSE; } From a721fe2b224f1e1d6fca31183778018147628a10 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 29 Jan 2013 17:50:15 +0100 Subject: [PATCH 2317/2394] Fix zpp() call in intl/converter --- ext/intl/converter/converter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c index 6be8698cbf588..eeb596f37732e 100644 --- a/ext/intl/converter/converter.c +++ b/ext/intl/converter/converter.c @@ -746,7 +746,7 @@ static PHP_METHOD(UConverter, convert) { int str_len, dest_len; zend_bool reverse = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b!", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &str, &str_len, &reverse) == FAILURE) { return; } From 1da67fc65e4909c671a9ccffec7d8d314f1829f1 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 29 Jan 2013 18:57:42 +0100 Subject: [PATCH 2318/2394] intl/converter in line w/ intl error handling --- ext/intl/converter/converter.c | 129 +++++++++++++----- .../tests/uconverter___construct_error.phpt | 14 ++ ext/intl/tests/uconverter_func_subst.phpt | 4 +- 3 files changed, 113 insertions(+), 34 deletions(-) create mode 100644 ext/intl/tests/uconverter___construct_error.phpt diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c index eeb596f37732e..8b578c43af3de 100644 --- a/ext/intl/converter/converter.c +++ b/ext/intl/converter/converter.c @@ -51,8 +51,7 @@ static inline void php_converter_throw_failure(php_converter_object *objval, UEr vsnprintf(message, sizeof(message), format, vargs); va_end(vargs); - intl_error_set_code(err, error TSRMLS_CC); - intl_error_set_custom_msg(err, message, 1 TSRMLS_CC); + intl_errors_set(err, error, message, 1 TSRMLS_CC); } /* }}} */ @@ -403,7 +402,7 @@ static zend_bool php_converter_set_encoding(php_converter_object *objval, } php_error_docref(NULL TSRMLS_CC, E_WARNING, "Ambiguous encoding specified, using %s", actual_encoding); } else if (U_FAILURE(error)) { - if (objval) { + if (objval) { THROW_UFAILURE(objval, "ucnv_open", error); } else { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Error setting encoding: %d - %s", (int)error, u_errorName(error)); @@ -433,8 +432,11 @@ static void php_converter_do_set_encoding(UConverter *cnv, INTERNAL_FUNCTION_PAR int enc_len; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &enc, &enc_len) == FAILURE) { - return; + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, "Bad arguments, " + "expected one string argument", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_errors_reset(&objval->error TSRMLS_CC); RETURN_BOOL(php_converter_set_encoding(objval, &(objval->src), enc, enc_len TSRMLS_CC)); } @@ -458,21 +460,23 @@ static PHP_METHOD(UConverter, setDestinationEncoding) { ZEND_BEGIN_ARG_INFO_EX(php_converter_get_encoding_arginfo, 0, ZEND_RETURN_VALUE, 0) ZEND_END_ARG_INFO(); static void php_converter_do_get_encoding(php_converter_object *objval, UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { - UErrorCode error = U_ZERO_ERROR; const char *name; - if (ZEND_NUM_ARGS() > 0) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, "Expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_errors_reset(&objval->error TSRMLS_CC); + if (!cnv) { RETURN_NULL(); } - name = ucnv_getName(cnv, &error); - if (U_FAILURE(error)) { - THROW_UFAILURE(objval, "ucnv_getName()", error); - RETURN_NULL(); + name = ucnv_getName(cnv, &objval->error.code); + if (U_FAILURE(objval->error.code)) { + THROW_UFAILURE(objval, "ucnv_getName()", objval->error.code); + RETURN_FALSE; } RETURN_STRING(name, 1); @@ -497,21 +501,22 @@ static PHP_METHOD(UConverter, getDestinationEncoding) { ZEND_BEGIN_ARG_INFO_EX(php_converter_get_type_arginfo, 0, ZEND_RETURN_VALUE, 0) ZEND_END_ARG_INFO(); static void php_converter_do_get_type(php_converter_object *objval, UConverter *cnv, INTERNAL_FUNCTION_PARAMETERS) { - UErrorCode error = U_ZERO_ERROR; UConverterType t; - if (ZEND_NUM_ARGS() > 0) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, "Expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_errors_reset(&objval->error TSRMLS_CC); if (!cnv) { RETURN_NULL(); } t = ucnv_getType(cnv); - if (U_FAILURE(error)) { - THROW_UFAILURE(objval, "ucnv_getType", error); - RETURN_NULL(); + if (U_FAILURE(objval->error.code)) { + THROW_UFAILURE(objval, "ucnv_getType", objval->error.code); + RETURN_FALSE; } RETURN_LONG(t); @@ -568,8 +573,12 @@ static PHP_METHOD(UConverter, __construct) { char *dest = src; int dest_len = src_len; + intl_error_reset(NULL TSRMLS_CC); + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!s!", &dest, &dest_len, &src, &src_len) == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::__construct(): bad arguments", 0 TSRMLS_CC); return; } @@ -591,8 +600,11 @@ static PHP_METHOD(UConverter, setSubstChars) { int chars_len, ret = 1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &chars, &chars_len) == FAILURE) { - return; + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::setSubstChars(): bad arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_errors_reset(&objval->error TSRMLS_CC); if (objval->src) { UErrorCode error = U_ZERO_ERROR; @@ -603,6 +615,7 @@ static PHP_METHOD(UConverter, setSubstChars) { } } else { php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, "Source Converter has not been initialized yet"); + ret = 0; } if (objval->dest) { @@ -614,6 +627,7 @@ static PHP_METHOD(UConverter, setSubstChars) { } } else { php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, "Destination Converter has not been initialized yet"); + ret = 0; } RETURN_BOOL(ret); @@ -630,6 +644,13 @@ static PHP_METHOD(UConverter, getSubstChars) { int8_t chars_len = sizeof(chars); UErrorCode error = U_ZERO_ERROR; + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::getSubstChars(): expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; + } + intl_errors_reset(&objval->error TSRMLS_CC); + if (!objval->src) { RETURN_NULL(); } @@ -640,7 +661,7 @@ static PHP_METHOD(UConverter, getSubstChars) { ucnv_getSubstChars(objval->src, chars, &chars_len, &error); if (U_FAILURE(error)) { THROW_UFAILURE(objval, "ucnv_getSubstChars", error); - RETURN_NULL(); + RETURN_FALSE; } RETURN_STRINGL(chars, chars_len, 1); @@ -717,8 +738,11 @@ static PHP_METHOD(UConverter, reasonText) { long reason; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &reason) == FAILURE) { - return; + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::reasonText(): bad arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_error_reset(NULL TSRMLS_CC); switch (reason) { UCNV_REASON_CASE(UNASSIGNED) @@ -729,7 +753,7 @@ static PHP_METHOD(UConverter, reasonText) { UCNV_REASON_CASE(CLONE) default: php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown UConverterCallbackReason: %ld", reason); - RETURN_NULL(); + RETURN_FALSE; } } /* }}} */ @@ -748,17 +772,20 @@ static PHP_METHOD(UConverter, convert) { if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &str, &str_len, &reverse) == FAILURE) { - return; + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::convert(): bad arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_errors_reset(&objval->error TSRMLS_CC); if (php_converter_do_convert(reverse ? objval->src : objval->dest, &dest, &dest_len, - reverse ? objval->dest : objval->src, + reverse ? objval->dest : objval->src, str, str_len, objval TSRMLS_CC)) { RETURN_STRINGL(dest, dest_len, 0); } else { - RETURN_NULL(); + RETURN_FALSE; } } /* }}} */ @@ -779,8 +806,11 @@ static PHP_METHOD(UConverter, transcode) { if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss|a!", &str, &str_len, &dest, &dest_len, &src, &src_len, &options) == FAILURE) { - return; + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::transcode(): bad arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_error_reset(NULL TSRMLS_CC); if (php_converter_set_encoding(NULL, &src_cnv, src, src_len TSRMLS_CC) && php_converter_set_encoding(NULL, &dest_cnv, dest, dest_len TSRMLS_CC)) { @@ -812,7 +842,10 @@ static PHP_METHOD(UConverter, transcode) { if (U_FAILURE(error)) { THROW_UFAILURE(NULL, "transcode", error); + RETVAL_FALSE; } + } else { + RETVAL_FALSE; } if (src_cnv) { @@ -830,8 +863,10 @@ ZEND_END_ARG_INFO(); static PHP_METHOD(UConverter, getErrorCode) { php_converter_object *objval = CONV_GET(getThis()); - if (ZEND_NUM_ARGS() > 0) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::getErrorCode(): expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; } RETURN_LONG(intl_error_get_code(&(objval->error) TSRMLS_CC)); @@ -845,8 +880,10 @@ static PHP_METHOD(UConverter, getErrorMessage) { php_converter_object *objval = CONV_GET(getThis()); char *message = intl_error_get_message(&(objval->error) TSRMLS_CC); - if (ZEND_NUM_ARGS() > 0) { - WRONG_PARAM_COUNT; + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::getErrorMessage(): expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; } if (message) { @@ -861,7 +898,15 @@ static PHP_METHOD(UConverter, getErrorMessage) { ZEND_BEGIN_ARG_INFO_EX(php_converter_getavailable_arginfo, 0, ZEND_RETURN_VALUE, 0) ZEND_END_ARG_INFO(); static PHP_METHOD(UConverter, getAvailable) { - int32_t i, count = ucnv_countAvailable(); + int32_t i, + count = ucnv_countAvailable(); + + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::getErrorMessage(): expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; + } + intl_error_reset(NULL TSRMLS_CC); array_init(return_value); for(i = 0; i < count; i++) { @@ -882,13 +927,16 @@ static PHP_METHOD(UConverter, getAliases) { uint16_t i, count; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name, &name_len) == FAILURE) { - return; + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::getAliases(): bad arguments", 0 TSRMLS_CC); + RETURN_FALSE; } + intl_error_reset(NULL TSRMLS_CC); count = ucnv_countAliases(name, &error); if (U_FAILURE(error)) { THROW_UFAILURE(NULL, "ucnv_countAliases", error); - return; + RETURN_FALSE; } array_init(return_value); @@ -911,6 +959,13 @@ ZEND_END_ARG_INFO(); static PHP_METHOD(UConverter, getStandards) { uint16_t i, count; + if (zend_parse_parameters_none() == FAILURE) { + intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR, + "UConverter::getStandards(): expected no arguments", 0 TSRMLS_CC); + RETURN_FALSE; + } + intl_error_reset(NULL TSRMLS_CC); + array_init(return_value); count = ucnv_countStandards(); for(i = 0; i < count; i++) { @@ -1011,13 +1066,23 @@ static zend_object_value php_converter_clone_object(zval *object TSRMLS_DC) { php_converter_object *objval, *oldobj = (php_converter_object*)zend_objects_get_address(object TSRMLS_CC); zend_object_value retval = php_converter_object_ctor(Z_OBJCE_P(object), &objval TSRMLS_CC); UErrorCode error = U_ZERO_ERROR; + + intl_errors_reset(&oldobj->error TSRMLS_CC); + objval->src = ucnv_safeClone(oldobj->src, NULL, NULL, &error); if (U_SUCCESS(error)) { error = U_ZERO_ERROR; objval->dest = ucnv_safeClone(oldobj->dest, NULL, NULL, &error); } if (U_FAILURE(error)) { + char *err_msg; THROW_UFAILURE(oldobj, "ucnv_safeClone", error); + + err_msg = intl_error_get_message(&oldobj->error TSRMLS_CC); + zend_throw_exception(NULL, err_msg, 0 TSRMLS_CC); + efree(err_msg); + + return retval; } /* Update contexts for converter error handlers */ diff --git a/ext/intl/tests/uconverter___construct_error.phpt b/ext/intl/tests/uconverter___construct_error.phpt new file mode 100644 index 0000000000000..1b2480818b864 --- /dev/null +++ b/ext/intl/tests/uconverter___construct_error.phpt @@ -0,0 +1,14 @@ +--TEST-- +Basic UConverter::convert() usage +--INI-- +intl.error_level = E_WARNING +--SKIPIF-- + +--FILE-- + $subst); $ret = UConverter::transcode("This is an ascii string", 'ascii', 'utf-8', $opts); - if ($ret === NULL) { + if ($ret === FALSE) { echo "Error: ", intl_get_error_message(), "\n"; } else { var_dump($ret); } $ret = UConverter::transcode("Snowman: (\xE2\x98\x83)", 'ascii', 'utf-8', $opts); - if ($ret === NULL) { + if ($ret === FALSE) { echo "Error: ", intl_get_error_message(), "\n"; } else { var_dump($ret); From 9d1bdaa569e0de0c36ee483784606246e106013f Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Wed, 26 Dec 2012 00:51:45 +0000 Subject: [PATCH 2319/2394] Make converter work on VS --- ext/intl/converter/converter.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c index 8b578c43af3de..09ea609e8c100 100644 --- a/ext/intl/converter/converter.c +++ b/ext/intl/converter/converter.c @@ -673,9 +673,11 @@ static zend_bool php_converter_do_convert(UConverter *dest_cnv, char **pdest, in UConverter *src_cnv, const char *src, int32_t src_len, php_converter_object *objval TSRMLS_DC) { - UErrorCode error = U_ZERO_ERROR; - int32_t dest_len; - char *dest; + UErrorCode error = U_ZERO_ERROR; + int32_t dest_len, + temp_len; + char *dest; + UChar *temp; if (!src_cnv || !dest_cnv) { php_converter_throw_failure(objval, U_INVALID_STATE_ERROR TSRMLS_CC, @@ -684,12 +686,12 @@ static zend_bool php_converter_do_convert(UConverter *dest_cnv, char **pdest, in } /* Get necessary buffer size first */ - int32_t temp_len = 1 + ucnv_toUChars(src_cnv, NULL, 0, src, src_len, &error); + temp_len = 1 + ucnv_toUChars(src_cnv, NULL, 0, src, src_len, &error); if (U_FAILURE(error) && error != U_BUFFER_OVERFLOW_ERROR) { THROW_UFAILURE(objval, "ucnv_toUChars", error); return 0; } - UChar *temp = safe_emalloc(sizeof(UChar), temp_len, sizeof(UChar)); + temp = safe_emalloc(sizeof(UChar), temp_len, sizeof(UChar)); /* Convert to intermediate UChar* array */ error = U_ZERO_ERROR; @@ -941,8 +943,10 @@ static PHP_METHOD(UConverter, getAliases) { array_init(return_value); for(i = 0; i < count; i++) { + const char *alias; + error = U_ZERO_ERROR; - const char *alias = ucnv_getAlias(name, i, &error); + alias = ucnv_getAlias(name, i, &error); if (U_FAILURE(error)) { THROW_UFAILURE(NULL, "ucnv_getAlias", error); zval_dtor(return_value); From 3bedc8ec277a246db6d3bfbe6313a861e46c4505 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Wed, 26 Dec 2012 18:16:04 +0000 Subject: [PATCH 2320/2394] Fixed paramter count --- ext/intl/converter/converter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c index 09ea609e8c100..387760a9d18c8 100644 --- a/ext/intl/converter/converter.c +++ b/ext/intl/converter/converter.c @@ -93,7 +93,7 @@ static void php_converter_default_callback(zval *return_value, zval *zobj, long /* {{{ proto void UConverter::toUCallback(long $reason, string $source, string $codeUnits, long &$error) */ -ZEND_BEGIN_ARG_INFO_EX(php_converter_toUCallback_arginfo, 0, ZEND_RETURN_VALUE, 5) +ZEND_BEGIN_ARG_INFO_EX(php_converter_toUCallback_arginfo, 0, ZEND_RETURN_VALUE, 4) ZEND_ARG_INFO(0, reason) ZEND_ARG_INFO(0, source) ZEND_ARG_INFO(0, codeUnits) @@ -115,7 +115,7 @@ static PHP_METHOD(UConverter, toUCallback) { /* {{{ proto void UConverter::fromUCallback(long $reason, Array $source, long $codePoint, long &$error) */ -ZEND_BEGIN_ARG_INFO_EX(php_converter_fromUCallback_arginfo, 0, ZEND_RETURN_VALUE, 5) +ZEND_BEGIN_ARG_INFO_EX(php_converter_fromUCallback_arginfo, 0, ZEND_RETURN_VALUE, 4) ZEND_ARG_INFO(0, reason) ZEND_ARG_INFO(0, source) ZEND_ARG_INFO(0, codePoint) From 748b37654df5f89c6630e74385e3f8a6fdf26ebe Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 29 Jan 2013 12:12:34 -0800 Subject: [PATCH 2321/2394] complete zts fix --- ext/session/mod_files.c | 2 +- ext/standard/file.c | 2 +- main/php_open_temporary_file.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/session/mod_files.c b/ext/session/mod_files.c index 1665ba53aa439..053c617dec232 100644 --- a/ext/session/mod_files.c +++ b/ext/session/mod_files.c @@ -266,7 +266,7 @@ PS_OPEN_FUNC(files) if (*save_path == '\0') { /* if save path is an empty string, determine the temporary dir */ - save_path = php_get_temporary_directory(); + save_path = php_get_temporary_directory(TSRMLS_C); if (php_check_open_basedir(save_path TSRMLS_CC)) { return FAILURE; diff --git a/ext/standard/file.c b/ext/standard/file.c index cf8b159556e94..106f5c1004ec9 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -2448,7 +2448,7 @@ PHP_FUNCTION(sys_get_temp_dir) if (zend_parse_parameters_none() == FAILURE) { return; } - RETURN_STRING((char *)php_get_temporary_directory(), 1); + RETURN_STRING((char *)php_get_temporary_directory(TSRMLS_C), 1); } /* }}} */ diff --git a/main/php_open_temporary_file.h b/main/php_open_temporary_file.h index e7dce359bb92b..75ac0bb0fea32 100644 --- a/main/php_open_temporary_file.h +++ b/main/php_open_temporary_file.h @@ -25,7 +25,7 @@ BEGIN_EXTERN_C() PHPAPI FILE *php_open_temporary_file(const char *dir, const char *pfx, char **opened_path_p TSRMLS_DC); PHPAPI int php_open_temporary_fd_ex(const char *dir, const char *pfx, char **opened_path_p, zend_bool open_basedir_check TSRMLS_DC); PHPAPI int php_open_temporary_fd(const char *dir, const char *pfx, char **opened_path_p TSRMLS_DC); -PHPAPI const char *php_get_temporary_directory(void); +PHPAPI const char *php_get_temporary_directory(TSRMLS_D); PHPAPI void php_shutdown_temporary_directory(void); END_EXTERN_C() From 15e76e6a98ded4f28aa8d5a91b2286497e44fc5b Mon Sep 17 00:00:00 2001 From: Stanislav Malyshev Date: Tue, 29 Jan 2013 15:02:55 -0800 Subject: [PATCH 2322/2394] forgot this file :( --- ext/curl/curl_file.c | 176 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 176 insertions(+) create mode 100644 ext/curl/curl_file.c diff --git a/ext/curl/curl_file.c b/ext/curl/curl_file.c new file mode 100644 index 0000000000000..27176784abc05 --- /dev/null +++ b/ext/curl/curl_file.c @@ -0,0 +1,176 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Stanislav Malyshev | + +----------------------------------------------------------------------+ + */ + +/* $Id$ */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include "php.h" +#include "php_curl.h" +#if HAVE_CURL + +PHP_CURL_API zend_class_entry *curl_CURLFile_class; + +static void curlfile_ctor(INTERNAL_FUNCTION_PARAMETERS) +{ + char *fname = NULL, *mime = NULL, *postname = NULL; + int fname_len, mime_len, postname_len; + zval *cf = return_value; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|ss", &fname, &fname_len, &mime, &mime_len, &postname, &postname_len) == FAILURE) { + return; + } + + if (fname) { + zend_update_property_string(curl_CURLFile_class, cf, "name", sizeof("name")-1, fname TSRMLS_CC); + } + + if (mime) { + zend_update_property_string(curl_CURLFile_class, cf, "mime", sizeof("mime")-1, mime TSRMLS_CC); + } + + if (postname) { + zend_update_property_string(curl_CURLFile_class, cf, "postname", sizeof("postname")-1, postname TSRMLS_CC); + } +} + +/* {{{ proto string CURLFile::__construct(string $name, [string $mimetype [, string $postfilename]]) + Create the CURLFile object */ +ZEND_METHOD(CURLFile, __construct) +{ + return_value = getThis(); + curlfile_ctor(INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string curl_file_create(string $name, [string $mimetype [, string $postfilename]]) + Create the CURLFile object */ +PHP_FUNCTION(curl_file_create) +{ + object_init_ex( return_value, curl_CURLFile_class ); + curlfile_ctor(INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +static void curlfile_get_property(char *name, INTERNAL_FUNCTION_PARAMETERS) +{ + zval *res; + if (zend_parse_parameters_none() == FAILURE) { + return; + } + res = zend_read_property(curl_CURLFile_class, getThis(), name, strlen(name), 1 TSRMLS_CC); + *return_value = *res; + zval_copy_ctor(return_value); + INIT_PZVAL(return_value); +} + +static void curlfile_set_property(char *name, INTERNAL_FUNCTION_PARAMETERS) +{ + char *arg = NULL; + int arg_len; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &arg, &arg_len) == FAILURE) { + return; + } + zend_update_property_string(curl_CURLFile_class, getThis(), name, strlen(name), arg TSRMLS_CC); +} + +/* {{{ proto string CURLFile::getFilename() + Get file name */ +ZEND_METHOD(CURLFile, getFilename) +{ + curlfile_get_property("name", INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string CURLFile::getMimeType() + Get MIME type */ +ZEND_METHOD(CURLFile, getMimeType) +{ + curlfile_get_property("mime", INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string CURLFile::getPostFilename() + Get file name for POST */ +ZEND_METHOD(CURLFile, getPostFilename) +{ + curlfile_get_property("postname", INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string CURLFile::setMimeType(string $mime) + Set MIME type */ +ZEND_METHOD(CURLFile, setMimeType) +{ + curlfile_set_property("mime", INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string CURLFile::setPostFilename(string $name) + Set file name for POST */ +ZEND_METHOD(CURLFile, setPostFilename) +{ + curlfile_set_property("postname", INTERNAL_FUNCTION_PARAM_PASSTHRU); +} +/* }}} */ + +/* {{{ proto string CURLFile::__wakeup() + Unserialization handler */ +ZEND_METHOD(CURLFile, __wakeup) +{ + zend_update_property_string(curl_CURLFile_class, getThis(), "name", sizeof("name")-1, "" TSRMLS_CC); + zend_throw_exception(NULL, "Unserialization of CURLFile instances is not allowed", 0 TSRMLS_CC); +} +/* }}} */ + +ZEND_BEGIN_ARG_INFO_EX(arginfo_curlfile_create, 0, 0, 1) + ZEND_ARG_INFO(0, filename) + ZEND_ARG_INFO(0, mimetype) + ZEND_ARG_INFO(0, postname) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO(arginfo_curlfile_name, 0) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + + +static const zend_function_entry curlfile_funcs[] = { + PHP_ME(CURLFile, __construct, arginfo_curlfile_create, ZEND_ACC_CTOR|ZEND_ACC_PUBLIC) + PHP_ME(CURLFile, getFilename, NULL, ZEND_ACC_PUBLIC) + PHP_ME(CURLFile, getMimeType, NULL, ZEND_ACC_PUBLIC) + PHP_ME(CURLFile, setMimeType, arginfo_curlfile_name, ZEND_ACC_PUBLIC) + PHP_ME(CURLFile, getPostFilename, NULL, ZEND_ACC_PUBLIC) + PHP_ME(CURLFile, setPostFilename, arginfo_curlfile_name, ZEND_ACC_PUBLIC) + PHP_ME(CURLFile, __wakeup, NULL, ZEND_ACC_PUBLIC) + PHP_FE_END +}; + +void curlfile_register_class(TSRMLS_D) +{ + zend_class_entry ce; + INIT_CLASS_ENTRY( ce, "CURLFile", curlfile_funcs ); + curl_CURLFile_class = zend_register_internal_class(&ce TSRMLS_CC); + zend_declare_property_string(curl_CURLFile_class, "name", sizeof("name")-1, "", ZEND_ACC_PUBLIC TSRMLS_CC); + zend_declare_property_string(curl_CURLFile_class, "mime", sizeof("mime")-1, "", ZEND_ACC_PUBLIC TSRMLS_CC); + zend_declare_property_string(curl_CURLFile_class, "postname", sizeof("postname")-1, "", ZEND_ACC_PUBLIC TSRMLS_CC); +} + +#endif From cbdf9ea34cd7b8dd03c85a739e4c0732e22cf48e Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Thu, 24 Jan 2013 12:56:02 +0100 Subject: [PATCH 2323/2394] now we have also an xz archive --- README.RELEASE_PROCESS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.RELEASE_PROCESS b/README.RELEASE_PROCESS index 3fa944ee3b2ea..e725625297d8c 100644 --- a/README.RELEASE_PROCESS +++ b/README.RELEASE_PROCESS @@ -64,7 +64,7 @@ Do not use abbreviations for alpha and beta. ``git push --tags origin HEAD`` 8. run: ``./makedist 5.4.2RC2``, this will export the tree, create configure -and build two tarballs (one gz and one bz2). +and build three tarballs (gz,bz2 and xz). 9. Copy those two tarballs to www.php.net, in your homedir there should be a directory "downloads/". Copy them into there, so that the system can generate From ee149cdd2b222b0cb42d5df32e4b7b544690946e Mon Sep 17 00:00:00 2001 From: Kalle Sommer Nielsen Date: Wed, 30 Jan 2013 16:16:43 +0100 Subject: [PATCH 2324/2394] Test commit (simple WS change) --- ext/gd/config.w32 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/gd/config.w32 b/ext/gd/config.w32 index 22584ddd46e7b..3619e1c60909d 100644 --- a/ext/gd/config.w32 +++ b/ext/gd/config.w32 @@ -77,7 +77,7 @@ if (PHP_GD != "no") { "); PHP_INSTALL_HEADERS("", "ext/gd ext/gd/libgd" ); - } else { + } else { WARNING("gd not enabled; libraries and headers not found"); } } From f0fe3d2dbecab94ebe279d549ed4fa54aea545c6 Mon Sep 17 00:00:00 2001 From: Ferenc Kovacs Date: Wed, 30 Jan 2013 17:39:13 +0100 Subject: [PATCH 2325/2394] having xz makes it three. thanks Mike Ford for spotting it --- README.RELEASE_PROCESS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.RELEASE_PROCESS b/README.RELEASE_PROCESS index e725625297d8c..2512d3a8b5284 100644 --- a/README.RELEASE_PROCESS +++ b/README.RELEASE_PROCESS @@ -66,7 +66,7 @@ Do not use abbreviations for alpha and beta. 8. run: ``./makedist 5.4.2RC2``, this will export the tree, create configure and build three tarballs (gz,bz2 and xz). -9. Copy those two tarballs to www.php.net, in your homedir there should be a +9. Copy those three tarballs to www.php.net, in your homedir there should be a directory "downloads/". Copy them into there, so that the system can generate MD5 sums. If you do not have this directory, talk to Derick. From 86b364380720005f4e460eb99317f4ddfef25c52 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Wed, 30 Jan 2013 11:08:32 -0500 Subject: [PATCH 2326/2394] Fix build problem in C++11 --- Zend/zend_API.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_API.h b/Zend/zend_API.h index e5d612c3fa50e..fb642c1475587 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -60,7 +60,7 @@ typedef struct _zend_fcall_info_cache { zval *object_ptr; } zend_fcall_info_cache; -#define ZEND_NS_NAME(ns, name) ns"\\"name +#define ZEND_NS_NAME(ns, name) ns "\\" name #define ZEND_FN(name) zif_##name #define ZEND_MN(name) zim_##name From 09e73fd80e7cf6e0daa47fd33cfcc7346b540f30 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Wed, 30 Jan 2013 11:08:32 -0500 Subject: [PATCH 2327/2394] Fix build problem in C++11 --- Zend/zend_API.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Zend/zend_API.h b/Zend/zend_API.h index e5d612c3fa50e..fb642c1475587 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -60,7 +60,7 @@ typedef struct _zend_fcall_info_cache { zval *object_ptr; } zend_fcall_info_cache; -#define ZEND_NS_NAME(ns, name) ns"\\"name +#define ZEND_NS_NAME(ns, name) ns "\\" name #define ZEND_FN(name) zif_##name #define ZEND_MN(name) zim_##name From f540e086e26280036f868c8bb5df458364f71f02 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 30 Jan 2013 20:23:39 +0100 Subject: [PATCH 2328/2394] Fixed bug #64106: Segfault on SplFixedArray[][x] = y when extended --- ext/spl/spl_array.c | 6 +++++- ext/spl/spl_fixedarray.c | 6 +++++- ext/spl/tests/bug64106.phpt | 15 +++++++++++++++ 3 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 ext/spl/tests/bug64106.phpt diff --git a/ext/spl/spl_array.c b/ext/spl/spl_array.c index 479c14839d112..40efc43915b25 100644 --- a/ext/spl/spl_array.c +++ b/ext/spl/spl_array.c @@ -381,7 +381,11 @@ static zval *spl_array_read_dimension_ex(int check_inherited, zval *object, zval spl_array_object *intern = (spl_array_object*)zend_object_store_get_object(object TSRMLS_CC); if (intern->fptr_offset_get) { zval *rv; - SEPARATE_ARG_IF_REF(offset); + if (!offset) { + ALLOC_INIT_ZVAL(offset); + } else { + SEPARATE_ARG_IF_REF(offset); + } zend_call_method_with_1_params(&object, Z_OBJCE_P(object), &intern->fptr_offset_get, "offsetGet", &rv, offset); zval_ptr_dtor(&offset); if (rv) { diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c index 1d51e0fb622b1..c9aec753c80a2 100644 --- a/ext/spl/spl_fixedarray.c +++ b/ext/spl/spl_fixedarray.c @@ -378,7 +378,11 @@ static zval *spl_fixedarray_object_read_dimension(zval *object, zval *offset, in if (intern->fptr_offset_get) { zval *rv; - SEPARATE_ARG_IF_REF(offset); + if (!offset) { + ALLOC_INIT_ZVAL(offset); + } else { + SEPARATE_ARG_IF_REF(offset); + } zend_call_method_with_1_params(&object, intern->std.ce, &intern->fptr_offset_get, "offsetGet", &rv, offset); zval_ptr_dtor(&offset); if (rv) { diff --git a/ext/spl/tests/bug64106.phpt b/ext/spl/tests/bug64106.phpt new file mode 100644 index 0000000000000..855caef2136ec --- /dev/null +++ b/ext/spl/tests/bug64106.phpt @@ -0,0 +1,15 @@ +--TEST-- +Bug #64106: Segfault on SplFixedArray[][x] = y when extended +--FILE-- + +--EXPECTF-- +Notice: Indirect modification of overloaded element of MyFixedArray has no effect in %s on line %d From 8b972efe5f3e9d4e33d6e0193f3d56716a6cc59f Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 30 Jan 2013 23:52:02 +0100 Subject: [PATCH 2329/2394] Fix potential segfault when finally in a generator is run during shutdown If a generator is destroyed in a finally block it will resume the generator to run that finally block before freeing the generator. This was done in the object storage free handler. Running user code in the free handler isn't safe though because the free handlers may be run during request shutdown, already after several key components have been shut down. This is avoided by doing the finally handling in the dtor handler. These handlers are run at the start of the shutdown sequence. --- .../tests/generators/finally/run_on_dtor.phpt | 22 ++++++ Zend/zend_generators.c | 77 ++++++++++--------- 2 files changed, 63 insertions(+), 36 deletions(-) create mode 100644 Zend/tests/generators/finally/run_on_dtor.phpt diff --git a/Zend/tests/generators/finally/run_on_dtor.phpt b/Zend/tests/generators/finally/run_on_dtor.phpt new file mode 100644 index 0000000000000..35f8f4e0de595 --- /dev/null +++ b/Zend/tests/generators/finally/run_on_dtor.phpt @@ -0,0 +1,22 @@ +--TEST-- +finally is run on object dtor, not free +--FILE-- +rewind(); + +set_error_handler(function() use($gen) {}); + +?> +--EXPECT-- +array(0) { +} diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index c6c18a70751f8..e8787d5e0df39 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -43,41 +43,6 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished zend_execute_data *execute_data = generator->execute_data; zend_op_array *op_array = execute_data->op_array; - if (!finished_execution) { - if (op_array->has_finally_block) { - /* -1 required because we want the last run opcode, not the - * next to-be-run one. */ - zend_uint op_num = execute_data->opline - op_array->opcodes - 1; - zend_uint finally_op_num = 0; - - /* Find next finally block */ - int i; - for (i = 0; i < op_array->last_try_catch; i++) { - zend_try_catch_element *try_catch = &op_array->try_catch_array[i]; - - if (op_num < try_catch->try_op) { - break; - } - - if (op_num < try_catch->finally_op) { - finally_op_num = try_catch->finally_op; - } - } - - /* If a finally block was found we jump directly to it and - * resume the generator. Furthermore we abort this close call - * because the generator will already be closed somewhere in - * the resume. */ - if (finally_op_num) { - execute_data->opline = &op_array->opcodes[finally_op_num]; - execute_data->fast_ret = NULL; - generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; - zend_generator_resume(generator TSRMLS_CC); - return; - } - } - } - if (!execute_data->symbol_table) { zend_free_compiled_variables(execute_data); } else { @@ -175,6 +140,45 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished } /* }}} */ +static void zend_generator_dtor_storage(zend_generator *generator, zend_object_handle handle TSRMLS_DC) /* {{{ */ +{ + zend_execute_data *ex = generator->execute_data; + zend_uint op_num, finally_op_num; + int i; + + if (!ex || !ex->op_array->has_finally_block) { + return; + } + + /* -1 required because we want the last run opcode, not the + * next to-be-run one. */ + op_num = ex->opline - ex->op_array->opcodes - 1; + + /* Find next finally block */ + finally_op_num = 0; + for (i = 0; i < ex->op_array->last_try_catch; i++) { + zend_try_catch_element *try_catch = &ex->op_array->try_catch_array[i]; + + if (op_num < try_catch->try_op) { + break; + } + + if (op_num < try_catch->finally_op) { + finally_op_num = try_catch->finally_op; + } + } + + /* If a finally block was found we jump directly to it and + * resume the generator. */ + if (finally_op_num) { + ex->opline = &ex->op_array->opcodes[finally_op_num]; + ex->fast_ret = NULL; + generator->flags |= ZEND_GENERATOR_FORCED_CLOSE; + zend_generator_resume(generator TSRMLS_CC); + } +} +/* }}} */ + static void zend_generator_free_storage(zend_generator *generator TSRMLS_DC) /* {{{ */ { zend_generator_close(generator, 0 TSRMLS_CC); @@ -355,7 +359,8 @@ static zend_object_value zend_generator_create(zend_class_entry *class_type TSRM zend_object_std_init(&generator->std, class_type TSRMLS_CC); - object.handle = zend_objects_store_put(generator, NULL, + object.handle = zend_objects_store_put(generator, + (zend_objects_store_dtor_t) zend_generator_dtor_storage, (zend_objects_free_object_storage_t) zend_generator_free_storage, (zend_objects_store_clone_t) zend_generator_clone_storage TSRMLS_CC From ac18c318dc4af08074a56cf706678a2457495944 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Fri, 1 Feb 2013 12:43:26 +0100 Subject: [PATCH 2330/2394] fix enchant compilation under vc11 --- ext/enchant/enchant.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c index 3d50cb80a6388..e4b42637663d4 100644 --- a/ext/enchant/enchant.c +++ b/ext/enchant/enchant.c @@ -23,10 +23,10 @@ #include "config.h" #endif -#include #include "php.h" #include "php_ini.h" #include "ext/standard/info.h" +#include #include "php_enchant.h" typedef EnchantBroker * EnchantBrokerPtr; From 3ee20e450fb5e52f68174f982fbd4f13eb2d9beb Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 1 Feb 2013 18:33:26 +0100 Subject: [PATCH 2331/2394] Fix segfault when cloning generator with properties Rule of thumb: Always implement the object clone handler rather than the object storage clone handler. Actually I think we should drop the latter. It's nearly never usable. --- .../generators/clone_with_properties.phpt | 18 +++++++++++++ Zend/zend_generators.c | 26 ++++++++++++++----- 2 files changed, 37 insertions(+), 7 deletions(-) create mode 100644 Zend/tests/generators/clone_with_properties.phpt diff --git a/Zend/tests/generators/clone_with_properties.phpt b/Zend/tests/generators/clone_with_properties.phpt new file mode 100644 index 0000000000000..900253c682214 --- /dev/null +++ b/Zend/tests/generators/clone_with_properties.phpt @@ -0,0 +1,18 @@ +--TEST-- +Tests cloning a generator with properties +--FILE-- +prop = 'val'; + +$g2 = clone $g1; +unset($g1); + +var_dump($g2->prop); + +?> +--EXPECT-- +string(3) "val" diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index e8787d5e0df39..621320614ca61 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -27,6 +27,8 @@ ZEND_API zend_class_entry *zend_ce_generator; static zend_object_handlers zend_generator_handlers; +static zend_object_value zend_generator_create(zend_class_entry *class_type TSRMLS_DC); + ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished_execution TSRMLS_DC) /* {{{ */ { if (generator->value) { @@ -188,10 +190,19 @@ static void zend_generator_free_storage(zend_generator *generator TSRMLS_DC) /* } /* }}} */ -static void zend_generator_clone_storage(zend_generator *orig, zend_generator **clone_ptr TSRMLS_DC) /* {{{ */ +static zend_object_value zend_generator_clone(zval *object TSRMLS_DC) /* {{{ */ { - zend_generator *clone = emalloc(sizeof(zend_generator)); - memcpy(clone, orig, sizeof(zend_generator)); + zend_generator *orig = zend_object_store_get_object(object TSRMLS_CC); + zend_object_value clone_val = zend_generator_create(Z_OBJCE_P(object) TSRMLS_CC); + zend_generator *clone = zend_object_store_get_object_by_handle(clone_val.handle TSRMLS_CC); + + zend_objects_clone_members( + &clone->std, clone_val, &orig->std, Z_OBJ_HANDLE_P(object) TSRMLS_CC + ); + + clone->execute_data = orig->execute_data; + clone->largest_used_integer_key = orig->largest_used_integer_key; + clone->flags = orig->flags; if (orig->execute_data) { /* Create a few shorter aliases to the old execution data */ @@ -335,14 +346,16 @@ static void zend_generator_clone_storage(zend_generator *orig, zend_generator ** /* The value and key are known not to be references, so simply add refs */ if (orig->value) { + clone->value = orig->value; Z_ADDREF_P(orig->value); } if (orig->key) { + clone->key = orig->key; Z_ADDREF_P(orig->key); } - *clone_ptr = clone; + return clone_val; } /* }}} */ @@ -362,8 +375,7 @@ static zend_object_value zend_generator_create(zend_class_entry *class_type TSRM object.handle = zend_objects_store_put(generator, (zend_objects_store_dtor_t) zend_generator_dtor_storage, (zend_objects_free_object_storage_t) zend_generator_free_storage, - (zend_objects_store_clone_t) zend_generator_clone_storage - TSRMLS_CC + NULL TSRMLS_CC ); object.handlers = &zend_generator_handlers; @@ -863,7 +875,7 @@ void zend_register_generator_ce(TSRMLS_D) /* {{{ */ memcpy(&zend_generator_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); zend_generator_handlers.get_constructor = zend_generator_get_constructor; - zend_generator_handlers.clone_obj = zend_objects_store_clone_obj; + zend_generator_handlers.clone_obj = zend_generator_clone; } /* }}} */ From 2117b8edd1efd9940da8e5c4549e0ce13e92894c Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 1 Feb 2013 19:27:10 +0100 Subject: [PATCH 2332/2394] NEWS --- NEWS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/NEWS b/NEWS index f26806d916fce..14c77d022e3f5 100644 --- a/NEWS +++ b/NEWS @@ -1,11 +1,15 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 201?, PHP 5.5.0 Beta 1 + - Core: . Fixed bug #60833 (self, parent, static behave inconsistently case-sensitive). (Stas, mario at include-once dot org) . Implemented FR #60524 (specify temp dir by php.ini). (ALeX Kazik). +- CLI server: + . Fixed bug #64128 (buit-in web server is broken on ppc64). (Remi) + - cURL: . Implemented FR #46439 - added CURLFile for safer file uploads. (Stas) From 114245c1b9cf153583c918e130faccc1f61d3ba5 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 1 Feb 2013 19:48:05 +0100 Subject: [PATCH 2333/2394] Fix bug #63830: Segfault on undefined function call in nested generator This also reverses the destruction order of the pushed arguments to align with how it is done everywhere else. I'm not exactly sure whether this is the right way to fix it, but it seems to work fine. --- NEWS | 2 ++ .../generators/nested_calls_with_die.phpt | 30 +++++++++++++++++++ Zend/zend_generators.c | 14 ++++++--- 3 files changed, 42 insertions(+), 4 deletions(-) create mode 100644 Zend/tests/generators/nested_calls_with_die.phpt diff --git a/NEWS b/NEWS index 14c77d022e3f5..e79cffed23749 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,8 @@ PHP NEWS . Fixed bug #60833 (self, parent, static behave inconsistently case-sensitive). (Stas, mario at include-once dot org) . Implemented FR #60524 (specify temp dir by php.ini). (ALeX Kazik). + . Fixed bug #63830 (Segfault on undefined function call in nested generator). + (Nikita Popov) - CLI server: . Fixed bug #64128 (buit-in web server is broken on ppc64). (Remi) diff --git a/Zend/tests/generators/nested_calls_with_die.phpt b/Zend/tests/generators/nested_calls_with_die.phpt new file mode 100644 index 0000000000000..f43d89ba2193c --- /dev/null +++ b/Zend/tests/generators/nested_calls_with_die.phpt @@ -0,0 +1,30 @@ +--TEST-- +Test nested calls with die() in a generator +--FILE-- +rewind(); +} + +function function_with_4_args() { + function_with_3_args(4, 5, 6); +} + +function outerGen() { + function_with_4_args(0, 1, 2, 3); + yield; // force generator +} + +$outerGen = outerGen(); +$outerGen->rewind(); + +?> +--EXPECT-- +Test diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c index 621320614ca61..c1dbee124f386 100644 --- a/Zend/zend_generators.c +++ b/Zend/zend_generators.c @@ -94,10 +94,16 @@ ZEND_API void zend_generator_close(zend_generator *generator, zend_bool finished /* Clear any backed up stack arguments */ if (generator->stack != EG(argument_stack)) { - void **stack_frame = zend_vm_stack_frame_base(execute_data); - while (generator->stack->top != stack_frame) { - zval_ptr_dtor((zval**)stack_frame); - stack_frame++; + void **ptr = generator->stack->top - 1; + void **end = zend_vm_stack_frame_base(execute_data); + + /* If the top stack element is the argument count, skip it */ + if (execute_data->function_state.arguments) { + ptr--; + } + + for (; ptr >= end; --ptr) { + zval_ptr_dtor((zval**) ptr); } } From ac47448abb477be99963f0b38fe82ffe78c21a8b Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sat, 2 Feb 2013 15:43:05 +0100 Subject: [PATCH 2334/2394] Ignore warnings on EAGAIN/EWOULDBLOCK/EINPROGRESS See bug #63570 --- ext/sockets/php_sockets.h | 4 +++- ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt | 4 ++-- ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp.phpt | 4 ++-- ext/sockets/tests/socket_sentto_recvfrom_unix.phpt | 5 ++--- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 3762e026aa516..9c5dc5a4aa586 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -69,7 +69,9 @@ PHP_SOCKETS_API int php_sockets_le_socket(void); int _err = (errn); /* save value to avoid repeated calls to WSAGetLastError() on Windows */ \ (socket)->error = _err; \ SOCKETS_G(last_error) = _err; \ - php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s [%d]: %s", msg, _err, php_strerror(_err TSRMLS_CC)); \ + if (_err != EAGAIN && _err != EWOULDBLOCK && _err != EINPROGRESS) { \ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s [%d]: %s", msg, _err, php_strerror(_err TSRMLS_CC)); \ + } \ } while (0) ZEND_BEGIN_MODULE_GLOBALS(sockets) diff --git a/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt b/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt index bf95044d48a87..00d69a855fb08 100644 --- a/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt +++ b/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt @@ -14,7 +14,7 @@ if (!extension_loaded('sockets')) { if (!socket_set_nonblock($socket)) { die('Unable to set nonblocking mode for socket'); } - socket_recvfrom($socket, $buf, 12, 0, $from, $port); // cause warning + var_dump(socket_recvfrom($socket, $buf, 12, 0, $from, $port)); //false (EAGAIN - no warning) $address = '127.0.0.1'; socket_sendto($socket, '', 1, 0, $address); // cause warning if (!socket_bind($socket, $address, 1223)) { @@ -44,7 +44,7 @@ if (!extension_loaded('sockets')) { socket_close($socket); --EXPECTF-- -Warning: socket_recvfrom(): unable to recvfrom [%d]: %a in %s on line %d +bool(false) Warning: Wrong parameter count for socket_sendto() in %s on line %d diff --git a/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp.phpt b/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp.phpt index 2beb8080cdb56..bd0790427773b 100644 --- a/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp.phpt +++ b/ext/sockets/tests/socket_sentto_recvfrom_ipv6_udp.phpt @@ -18,7 +18,7 @@ require 'ipv6_skipif.inc'; if (!socket_set_nonblock($socket)) { die('Unable to set nonblocking mode for socket'); } - socket_recvfrom($socket, $buf, 12, 0, $from, $port); // cause warning + var_dump(socket_recvfrom($socket, $buf, 12, 0, $from, $port)); // false (EAGAIN, no warning) $address = '::1'; socket_sendto($socket, '', 1, 0, $address); // cause warning if (!socket_bind($socket, $address, 1223)) { @@ -48,7 +48,7 @@ require 'ipv6_skipif.inc'; socket_close($socket); --EXPECTF-- -Warning: socket_recvfrom(): unable to recvfrom [11]: Resource temporarily unavailable in %s on line %d +bool(false) Warning: Wrong parameter count for socket_sendto() in %s on line %d diff --git a/ext/sockets/tests/socket_sentto_recvfrom_unix.phpt b/ext/sockets/tests/socket_sentto_recvfrom_unix.phpt index 55ad75c65e430..e25bf4df1a547 100644 --- a/ext/sockets/tests/socket_sentto_recvfrom_unix.phpt +++ b/ext/sockets/tests/socket_sentto_recvfrom_unix.phpt @@ -18,7 +18,7 @@ if (!extension_loaded('sockets')) { if (!socket_set_nonblock($socket)) { die('Unable to set nonblocking mode for socket'); } - socket_recvfrom($socket, $buf, 12, 0, $from, $port); // cause warning + var_dump(socket_recvfrom($socket, $buf, 12, 0, $from, $port)); //false (EAGAIN, no warning) $address = sprintf("/tmp/%s.sock", uniqid()); if (!socket_bind($socket, $address)) { die("Unable to bind to $address"); @@ -53,8 +53,7 @@ if (!extension_loaded('sockets')) { ?> --EXPECTF-- Warning: socket_create(): Unable to create socket [%d]: Protocol not supported in %s on line %d - -Warning: socket_recvfrom(): unable to recvfrom [%d]: Resource temporarily unavailable in %s on line %d +bool(false) Warning: socket_sendto() expects at least 5 parameters, 4 given in %s on line %d bool(false) From 5e51c851431189677aa80f7a3a863699488678cd Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 1 Nov 2012 20:38:42 +0100 Subject: [PATCH 2335/2394] Wrap recvmsg() and sendmsg() This introduces two new functions: int socket_recvmsg(resource $socket, array &$msghdr, int $flags) int socket_sendmsg(resource $socket, array $msghdr, int $flags) The arrays representing struct msghdr follow the native counterpart closely: structs are mapped to arrays, fields to array elements whose key is the name of the field without the prefix (e.g. "name" instead of "msg_name") and array are mapped to sequential numeric PHP arrays. Right now the only type of ancillary data supported is fot the level/type pair IPPROTO_IPV6/IPV6_PKTINFO. I also refactored out the name resolution functions and made sockets_strerror() a global function. --- ext/sockets/config.m4 | 2 +- ext/sockets/php_sockets.h | 10 + ext/sockets/sendrecvmsg.c | 1377 +++++++++++++++++++++++++++++++++++ ext/sockets/sendrecvmsg.h | 8 + ext/sockets/sockaddr_conv.c | 119 +++ ext/sockets/sockaddr_conv.h | 24 + ext/sockets/sockets.c | 204 ++---- 7 files changed, 1599 insertions(+), 145 deletions(-) create mode 100644 ext/sockets/sendrecvmsg.c create mode 100644 ext/sockets/sendrecvmsg.h create mode 100644 ext/sockets/sockaddr_conv.c create mode 100644 ext/sockets/sockaddr_conv.h diff --git a/ext/sockets/config.m4 b/ext/sockets/config.m4 index 4032621ce6b5a..3b5b90714b727 100644 --- a/ext/sockets/config.m4 +++ b/ext/sockets/config.m4 @@ -43,6 +43,6 @@ if test "$PHP_SOCKETS" != "no"; then AC_DEFINE(HAVE_SA_SS_FAMILY,1,[Whether you have sockaddr_storage.ss_family]) fi - PHP_NEW_EXTENSION([sockets], [sockets.c multicast.c], [$ext_shared]) + PHP_NEW_EXTENSION([sockets], [sockets.c multicast.c sockaddr_conv.c sendrecvmsg.c], [$ext_shared]) PHP_INSTALL_HEADERS([ext/sockets/], [php_sockets.h]) fi diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 9c5dc5a4aa586..9158ca49072c0 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -85,6 +85,16 @@ ZEND_END_MODULE_GLOBALS(sockets) #define SOCKETS_G(v) (sockets_globals.v) #endif +ZEND_EXTERN_MODULE_GLOBALS(sockets); + +char *sockets_strerror(int error TSRMLS_DC); + +#define PHP_SOCKET_ERROR(socket,msg,errn) \ + socket->error = errn; \ + SOCKETS_G(last_error) = errn; \ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s [%d]: %s", msg, errn, \ + sockets_strerror(errn TSRMLS_CC)) + #else #define phpext_sockets_ptr NULL #endif diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c new file mode 100644 index 0000000000000..379af125d70b4 --- /dev/null +++ b/ext/sockets/sendrecvmsg.c @@ -0,0 +1,1377 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2012 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Gustavo Lopes | + +----------------------------------------------------------------------+ + */ + +#include +#include "php_sockets.h" +#include "sockaddr_conv.h" +#include "sendrecvmsg.h" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#ifdef ZTS +#include +#endif + +#define MAX_USER_BUFF_SIZE ((size_t)(100*1024*1024)) +#define DEFAULT_BUFF_SIZE 8192 +#define MAX_ARRAY_KEY_SIZE 128 + +#define LONG_CHECK_VALID_INT(l) \ + do { \ + if ((l) < INT_MIN && (l) > INT_MAX) { \ + php_error_docref0(NULL TSRMLS_CC, E_WARNING, "The value %ld does not fit inside " \ + "the boundaries of a native integer", (l)); \ + return; \ + } \ + } while (0) + +struct err_s { + int has_error; + char *msg; + int level; + int should_free; +}; + +typedef struct { + HashTable params; /* stores pointers; has to be first */ + struct err_s err; + zend_llist keys, + /* common part to res_context ends here */ + allocations; + php_socket *sock; +} ser_context; + +typedef struct { + HashTable params; /* stores pointers; has to be first */ + struct err_s err; + zend_llist keys; +} res_context; + +struct key_value { + const char *key; + unsigned key_size; + void *value; +}; +#define KEY_FILL_SOCKADDR "fill_sockaddr" +#define KEY_RECVMSG_RET "recvmsg_ret" + + +typedef void (from_zval_write_field)(const zval *arr_value, char *field, ser_context *ctx); +typedef void (to_zval_read_field)(const char *data, zval *zv, res_context *ctx); + +typedef struct { + /* zval info */ + const char *name; + unsigned name_size; + int required; + + /* structure info */ + size_t field_offset; /* 0 to pass full structure, e.g. when more than + one field is to be changed; in that case the + callbacks need to know the name of the fields */ + + /* callbacks */ + from_zval_write_field *from_zval; + to_zval_read_field *to_zval; +} field_descriptor; + +typedef struct { + int cmsg_level; /* originating protocol */ + int msg_type; /* protocol-specific type */ +} anc_reg_key; + +static struct { + int initialized; + HashTable ht; +} ancillary_registry; + +typedef socklen_t (*ancillary_size)(void); + +typedef struct { + socklen_t size; /* size of native structure */ + from_zval_write_field *from_array; + to_zval_read_field *to_array; +} ancillary_reg_entry; + +/* PARAMETERS */ +static int param_get_bool(void *ctx, const char *key, int def) +{ + int **elem; + if (zend_hash_find(ctx, key, strlen(key) + 1, (void**)&elem) == SUCCESS) { + return **elem; + } else { + return def; + } +} + +/* FORWARD DECLARATIONS */ +static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type); + +static inline void *accounted_emalloc(size_t alloc_size, ser_context *ctx) +{ + void *ret = emalloc(alloc_size); + zend_llist_add_element(&ctx->allocations, &ret); + return ret; +} + +static inline void *accounted_ecalloc(size_t nmemb, size_t alloc_size, ser_context *ctx) +{ + void *ret = ecalloc(nmemb, alloc_size); + zend_llist_add_element(&ctx->allocations, &ret); + return ret; +} +static inline void *accounted_safe_ecalloc(size_t nmemb, size_t alloc_size, size_t offset, ser_context *ctx) +{ + void *ret = safe_emalloc(nmemb, alloc_size, offset); + memset(ret, '\0', nmemb * alloc_size + offset); + zend_llist_add_element(&ctx->allocations, &ret); + return ret; +} + +static void do_from_to_zval_err(struct err_s *err, + zend_llist *keys, + const char *what_conv, + const char *fmt, + va_list ap) +{ + smart_str path = {0}; + const char **node; + char *user_msg; + int user_msg_size; + zend_llist_position pos; + + if (err->has_error) { + return; + } + + for (node = zend_llist_get_first_ex(keys, &pos); + node != NULL; + node = zend_llist_get_next_ex(keys, &pos)) { + smart_str_appends(&path, *node); + smart_str_appends(&path, " > "); + } + + if (path.len > 3) { + path.len -= 3; + } + smart_str_0(&path); + + user_msg_size = vspprintf(&user_msg, 0, fmt, ap); + + err->has_error = 1; + err->level = E_WARNING; + spprintf(&err->msg, 0, "error converting %s data (path: %s): %.*s", + what_conv, + path.c && path.c != '\0' ? path.c : "unavailable", + user_msg_size, user_msg); + err->should_free = 1; + + efree(user_msg); + smart_str_free_ex(&path, 0); +} +__attribute__ ((format (printf, 2, 3))) +static void do_from_zval_err(ser_context *ctx, const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + do_from_to_zval_err(&ctx->err, &ctx->keys, "user", fmt, ap); + va_end(ap); +} +__attribute__ ((format (printf, 2, 3))) +static void do_to_zval_err(res_context *ctx, const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + do_from_to_zval_err(&ctx->err, &ctx->keys, "native", fmt, ap); + va_end(ap); +} +static void err_msg_dispose(struct err_s *err TSRMLS_DC) +{ + if (err->msg != NULL) { + php_error_docref0(NULL TSRMLS_CC, err->level, "%s", err->msg); + if (err->should_free) { + efree(err->msg); + } + } +} + + +/* Generic Aggregated conversions */ +static void from_zval_write_aggregation(const zval *container, + char *structure, + const field_descriptor *descriptors, + ser_context *ctx) +{ + const field_descriptor *descr; + zval **elem; + + if (Z_TYPE_P(container) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + } + + for (descr = descriptors; descr->name != NULL && !ctx->err.has_error; descr++) { + if (zend_hash_find(Z_ARRVAL_P(container), + descr->name, descr->name_size, (void**)&elem) == SUCCESS) { + + if (descr->from_zval == NULL) { + do_from_zval_err(ctx, "No information on how to convert value " + "of key '%s'", descr->name); + break; + } + + zend_llist_add_element(&ctx->keys, (void*)&descr->name); + descr->from_zval(*elem, ((char*)structure) + descr->field_offset, ctx); + zend_llist_remove_tail(&ctx->keys); + + } else if (descr->required) { + do_from_zval_err(ctx, "The key '%s' is required", descr->name); + break; + } + } +} +static void to_zval_read_aggregation(const char *structure, + zval *zarr, /* initialized array */ + const field_descriptor *descriptors, + res_context *ctx) +{ + const field_descriptor *descr; + + assert(Z_TYPE_P(zarr) == IS_ARRAY); + assert(Z_ARRVAL_P(zarr) != NULL); + + for (descr = descriptors; descr->name != NULL && !ctx->err.has_error; descr++) { + zval *new_zv; + + if (descr->to_zval == NULL) { + do_to_zval_err(ctx, "No information on how to convert native " + "field into value for key '%s'", descr->name); + break; + } + + ALLOC_INIT_ZVAL(new_zv); + add_assoc_zval_ex(zarr, descr->name, descr->name_size, new_zv); + + zend_llist_add_element(&ctx->keys, (void*)&descr->name); + descr->to_zval(structure + descr->field_offset, new_zv, ctx); + zend_llist_remove_tail(&ctx->keys); + } +} + +/* CONVERSIONS for integers */ +static long from_zval_integer_common(const zval *arr_value, ser_context *ctx) +{ + long ret = 0; + zval lzval = zval_used_for_init; + + if (Z_TYPE_P(arr_value) != IS_LONG) { + ZVAL_COPY_VALUE(&lzval, arr_value); + zval_copy_ctor(&lzval); + arr_value = &lzval; + } + + switch (Z_TYPE_P(arr_value)) { + case IS_LONG: +long_case: + ret = Z_LVAL_P(arr_value); + break; + + /* if not long we're operating on lzval */ + case IS_DOUBLE: +double_case: + convert_to_long(&lzval); + goto long_case; + + case IS_OBJECT: + case IS_STRING: { + long lval; + double dval; + + convert_to_string(&lzval); + + switch (is_numeric_string(Z_STRVAL(lzval), Z_STRLEN(lzval), &lval, &dval, 0)) { + case IS_DOUBLE: + zval_dtor(&lzval); + Z_TYPE(lzval) = IS_DOUBLE; + Z_DVAL(lzval) = dval; + goto double_case; + + case IS_LONG: + zval_dtor(&lzval); + Z_TYPE(lzval) = IS_LONG; + Z_DVAL(lzval) = lval; + goto long_case; + } + + /* if we get here, we don't have a numeric string */ + do_from_zval_err(ctx, "expected an integer, but got a non numeric " + "string (possibly from a converted object): '%s'", Z_STRVAL_P(arr_value)); + break; + } + + default: + do_from_zval_err(ctx, "%s", "expected an integer, either of a PHP " + "integer type or of a convertible type"); + break; + } + + zval_dtor(&lzval); + + return ret; +} +static void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + int ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval > INT_MAX || lval < INT_MIN) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a native int"); + return; + } + + ival = (int)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_unsigned(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + unsigned ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (sizeof(long) > sizeof(ival) && (lval < 0 || lval > UINT_MAX)) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a native unsigned int"); + return; + } + + ival = (unsigned)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_uint32(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uint32_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (sizeof(long) > sizeof(uint32_t) && (lval < 0 || lval > 0xFFFFFFFF)) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for an unsigned 32-bit integer"); + return; + } + + ival = (uint32_t)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_net_uint16(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uint16_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > 0xFFFF) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for an unsigned 16-bit integer"); + return; + } + + ival = htons((uint16_t)lval); + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_sa_family(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + sa_family_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > (sa_family_t)-1) { /* sa_family_t is unsigned */ + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a sa_family_t value"); + return; + } + + ival = (sa_family_t)lval; + memcpy(field, &ival, sizeof(ival)); +} + +static void to_zval_read_int(const char *data, zval *zv, res_context *ctx) +{ + int ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_unsigned(const char *data, zval *zv, res_context *ctx) +{ + unsigned ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_net_uint16(const char *data, zval *zv, res_context *ctx) +{ + uint16_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ntohs(ival)); +} +static void to_zval_read_uint32(const char *data, zval *zv, res_context *ctx) +{ + uint32_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_sa_family(const char *data, zval *zv, res_context *ctx) +{ + sa_family_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} + +/* CONVERSIONS for sockaddr */ +static void from_zval_write_sin_addr(const zval *zaddr_str, char *inaddr, ser_context *ctx) +{ + int res; + struct sockaddr_in saddr = {0}; + zval lzval = zval_used_for_init; + TSRMLS_FETCH(); + + if (Z_TYPE_P(zaddr_str) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, zaddr_str); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + zaddr_str = &lzval; + } + + res = php_set_inet_addr(&saddr, Z_STRVAL_P(zaddr_str), ctx->sock TSRMLS_CC); + if (res) { + memcpy(inaddr, &saddr.sin_addr, sizeof saddr.sin_addr); + } else { + /* error already emitted, but let's emit another more relevant */ + do_from_zval_err(ctx, "could not resolve address '%s' to get an AF_INET " + "address", Z_STRVAL_P(zaddr_str)); + } + + zval_dtor(&lzval); +} +static void to_zval_read_sin_addr(const char *data, zval *zv, res_context *ctx) +{ + const struct in_addr *addr = (const struct in_addr *)data; + socklen_t size = INET_ADDRSTRLEN; + + Z_TYPE_P(zv) = IS_STRING; + Z_STRVAL_P(zv) = ecalloc(1, size); + Z_STRLEN_P(zv) = 0; + + if (inet_ntop(AF_INET, addr, Z_STRVAL_P(zv), size) == NULL) { + do_to_zval_err(ctx, "could not convert IPv4 address to string " + "(errno %d)", errno); + return; + } + + Z_STRLEN_P(zv) = strlen(Z_STRVAL_P(zv)); +} +static const field_descriptor descriptors_sockaddr_in[] = { + {"family", sizeof("family"), 0, offsetof(struct sockaddr_in, sin_family), from_zval_write_sa_family, to_zval_read_sa_family}, + {"addr", sizeof("addr"), 0, offsetof(struct sockaddr_in, sin_addr), from_zval_write_sin_addr, to_zval_read_sin_addr}, + {"port", sizeof("port"), 0, offsetof(struct sockaddr_in, sin_port), from_zval_write_net_uint16, to_zval_read_net_uint16}, + {0} +}; +static void from_zval_write_sockaddr_in(const zval *container, char *sockaddr, ser_context *ctx) +{ + from_zval_write_aggregation(container, sockaddr, descriptors_sockaddr_in, ctx); +} +static void to_zval_read_sockaddr_in(const char *data, zval *zv, res_context *ctx) +{ + to_zval_read_aggregation(data, zv, descriptors_sockaddr_in, ctx); +} +static void from_zval_write_sin6_addr(const zval *zaddr_str, char *addr6, ser_context *ctx) +{ + int res; + struct sockaddr_in6 saddr6 = {0}; + zval lzval = zval_used_for_init; + TSRMLS_FETCH(); + + if (Z_TYPE_P(zaddr_str) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, zaddr_str); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + zaddr_str = &lzval; + } + + res = php_set_inet6_addr(&saddr6, + Z_STRVAL_P(zaddr_str), ctx->sock TSRMLS_CC); + if (res) { + memcpy(addr6, &saddr6.sin6_addr, sizeof saddr6.sin6_addr); + } else { + /* error already emitted, but let's emit another more relevant */ + do_from_zval_err(ctx, "could not resolve address '%s' to get an AF_INET6 " + "address", Z_STRVAL_P(zaddr_str)); + } + + zval_dtor(&lzval); +} +static void to_zval_read_sin6_addr(const char *data, zval *zv, res_context *ctx) +{ + const struct in6_addr *addr = (const struct in6_addr *)data; + socklen_t size = INET6_ADDRSTRLEN; + + Z_TYPE_P(zv) = IS_STRING; + Z_STRVAL_P(zv) = ecalloc(1, size); + Z_STRLEN_P(zv) = 0; + + if (inet_ntop(AF_INET6, addr, Z_STRVAL_P(zv), size) == NULL) { + do_to_zval_err(ctx, "could not convert IPv6 address to string " + "(errno %d)", errno); + return; + } + + Z_STRLEN_P(zv) = strlen(Z_STRVAL_P(zv)); +} +static const field_descriptor descriptors_sockaddr_in6[] = { + {"family", sizeof("family"), 0, offsetof(struct sockaddr_in6, sin6_family), from_zval_write_sa_family, to_zval_read_sa_family}, + {"addr", sizeof("addr"), 0, offsetof(struct sockaddr_in6, sin6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, + {"port", sizeof("port"), 0, offsetof(struct sockaddr_in6, sin6_port), from_zval_write_net_uint16, to_zval_read_net_uint16}, + {"flowinfo", sizeof("flowinfo"), 0, offsetof(struct sockaddr_in6, sin6_flowinfo), from_zval_write_uint32, to_zval_read_uint32}, + {"scope_id", sizeof("scope_id"), 0, offsetof(struct sockaddr_in6, sin6_scope_id), from_zval_write_uint32, to_zval_read_uint32}, + {0} +}; +static void from_zval_write_sockaddr_in6(const zval *container, char *sockaddr6, ser_context *ctx) +{ + from_zval_write_aggregation(container, sockaddr6, descriptors_sockaddr_in6, ctx); +} +static void to_zval_read_sockaddr_in6(const char *data, zval *zv, res_context *ctx) +{ + to_zval_read_aggregation(data, zv, descriptors_sockaddr_in6, ctx); +} +static void from_zval_write_sockaddr_aux(const zval *container, + struct sockaddr **sockaddr_ptr, + socklen_t *sockaddr_len, + ser_context *ctx) +{ + int family; + zval **elem; + int fill_sockaddr; + + if (Z_TYPE_P(container) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + fill_sockaddr = param_get_bool(ctx, KEY_FILL_SOCKADDR, 1); + + if (zend_hash_find(Z_ARRVAL_P(container), "family", sizeof("family"), (void**)&elem) == SUCCESS + && Z_TYPE_PP(elem) != IS_NULL) { + const char *node = "family"; + zend_llist_add_element(&ctx->keys, &node); + from_zval_write_int(*elem, (char*)&family, ctx); + zend_llist_remove_tail(&ctx->keys); + } else { + family = ctx->sock->type; + } + + switch (family) { + case AF_INET: + /* though not all OSes support sockaddr_in used in IPv6 sockets */ + if (ctx->sock->type != AF_INET && ctx->sock->type != AF_INET6) { + do_from_zval_err(ctx, "the specified family (number %d) is not " + "supported on this socket", family); + return; + } + *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_in), ctx); + *sockaddr_len = sizeof(struct sockaddr_in); + if (fill_sockaddr) { + from_zval_write_sockaddr_in(container, (char*)*sockaddr_ptr, ctx); + } + break; + case AF_INET6: + if (ctx->sock->type != AF_INET6) { + do_from_zval_err(ctx, "the specified family (AF_INET6) is not " + "supported on this socket"); + return; + } + *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_in6), ctx); + *sockaddr_len = sizeof(struct sockaddr_in6); + if (fill_sockaddr) { + from_zval_write_sockaddr_in6(container, (char*)*sockaddr_ptr, ctx); + } + break; + default: + do_from_zval_err(ctx, "%s", "the only families currently supported are " + "AF_INET and AF_INET6"); + break; + } +} +static void to_zval_read_sockaddr_aux(const char *sockaddr_c, zval *zv, res_context *ctx) +{ + const struct sockaddr *saddr = (struct sockaddr *)sockaddr_c; + + assert(Z_TYPE_P(zv) == IS_ARRAY); + + switch (saddr->sa_family) { + case AF_INET: + to_zval_read_sockaddr_in(sockaddr_c, zv, ctx); + break; + + case AF_INET6: + to_zval_read_sockaddr_in6(sockaddr_c, zv, ctx); + break; + + default: + do_to_zval_err(ctx, "cannot read struct sockaddr with family %d; " + "not supported", + (int)saddr->sa_family); + break; + } +} + +/* CONVERSIONS for cmsghdr */ +/* + * [ level => , type => , data => [],] + * struct cmsghdr { + * socklen_t cmsg_len; // data byte count, including header + * int cmsg_level; // originating protocol + * int cmsg_type; // protocol-specific type + * // followed by unsigned char cmsg_data[]; + * }; + */ +static void from_zval_write_control(const zval *arr, + void **control_buf, + zend_llist_element *alloc, + size_t *control_len, + size_t *offset, + ser_context *ctx) +{ + struct cmsghdr *cmsghdr; + int level, + type; + size_t req_space, + space_left; + ancillary_reg_entry *entry; + + static const field_descriptor descriptor_level[] = { + {"level", sizeof("level"), 0, 0, from_zval_write_int, 0}, + {0} + }; + static const field_descriptor descriptor_type[] = { + {"type", sizeof("type"), 0, 0, from_zval_write_int, 0}, + {0} + }; + field_descriptor descriptor_data[] = { + {"data", sizeof("data"), 0, 0, 0, 0}, + {0} + }; + + from_zval_write_aggregation(arr, (char *)&level, descriptor_level, ctx); + if (ctx->err.has_error) { + return; + } + from_zval_write_aggregation(arr, (char *)&type, descriptor_type, ctx); + if (ctx->err.has_error) { + return; + } + + entry = get_ancillary_reg_entry(level, type); + if (entry == NULL) { + do_from_zval_err(ctx, "cmsghdr with level %d and type %d not supported", + level, type); + return; + } + + req_space = CMSG_SPACE(entry->size); + space_left = *control_len - *offset; + assert(*control_len >= *offset); + + if (space_left < req_space) { + *control_buf = safe_erealloc(*control_buf, 2, req_space, *control_len); + *control_len += 2 * req_space; + memcpy(&alloc->data, *control_buf, sizeof *control_buf); + } + + cmsghdr = (struct cmsghdr*)(((char*)*control_buf) + *offset); + cmsghdr->cmsg_level = level; + cmsghdr->cmsg_type = type; + cmsghdr->cmsg_len = CMSG_LEN(entry->size); + + descriptor_data[0].from_zval = entry->from_array; + from_zval_write_aggregation(arr, (char*)CMSG_DATA(cmsghdr), descriptor_data, ctx); + + *offset += req_space; +} +static void from_zval_write_control_array(const zval *arr, char *msghdr_c, ser_context *ctx) +{ + HashPosition pos; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + zval **elem; + uint32_t i; + int num_elems; + void *control_buf; + zend_llist_element *alloc; + size_t control_len, + cur_offset; + struct msghdr *msg = (struct msghdr*)msghdr_c; + + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + num_elems = zend_hash_num_elements(Z_ARRVAL_P(arr)); + if (num_elems == 0) { + return; + } + + /* estimate each message at 20 bytes */ + control_buf = accounted_safe_ecalloc(num_elems, CMSG_SPACE(20), 0, ctx); + alloc = ctx->allocations.tail; + control_len = (size_t)num_elems * CMSG_SPACE(20); + cur_offset = 0; + + for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 0; + !ctx->err.has_error + && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; + zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos)) { + + if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + from_zval_write_control(*elem, &control_buf, alloc, &control_len, + &cur_offset, ctx); + + zend_llist_remove_tail(&ctx->keys); + } + + msg->msg_control = control_buf; + msg->msg_controllen = control_len; +} +static void to_zval_read_cmsg_data(const char *cmsghdr_c, zval *zv, res_context *ctx) +{ + const struct cmsghdr *cmsg = (const struct cmsghdr *)cmsghdr_c; + ancillary_reg_entry *entry; + + entry = get_ancillary_reg_entry(cmsg->cmsg_level, cmsg->cmsg_type); + if (entry == NULL) { + do_to_zval_err(ctx, "cmsghdr with level %d and type %d not supported", + cmsg->cmsg_level, cmsg->cmsg_type); + return; + } + if (CMSG_LEN(entry->size) > cmsg->cmsg_len) { + do_to_zval_err(ctx, "the cmsghdr structure is unexpectedly small; " + "expected a length of at least %ld, but got %ld", + (long)CMSG_LEN(entry->size), (long)cmsg->cmsg_len); + return; + } + + entry->to_array((const char *)CMSG_DATA(cmsg), zv, ctx); +} +static void to_zval_read_control(const char *cmsghdr_c, zval *zv, res_context *ctx) +{ + /* takes a cmsghdr, not a msghdr like from_zval_write_control */ + static const field_descriptor descriptors[] = { + {"level", sizeof("level"), 0, offsetof(struct cmsghdr, cmsg_level), 0, to_zval_read_int}, + {"type", sizeof("type"), 0, offsetof(struct cmsghdr, cmsg_type), 0, to_zval_read_int}, + {"data", sizeof("data"), 0, 0 /* cmsghdr passed */, 0, to_zval_read_cmsg_data}, + {0} + }; + + array_init_size(zv, 3); + to_zval_read_aggregation(cmsghdr_c, zv, descriptors, ctx); +} +static void to_zval_read_control_array(const char *msghdr_c, zval *zv, res_context *ctx) +{ + struct msghdr *msg = (struct msghdr *)msghdr_c; + struct cmsghdr *cmsg; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + uint32_t i = 1; + + /*if (msg->msg_flags & MSG_CTRUNC) { + php_error_docref0(NULL, E_WARNING, "The MSG_CTRUNC flag is present; will not " + "attempt to read control messages"); + ZVAL_FALSE(zv); + return; + }*/ + + array_init(zv); + + for (cmsg = CMSG_FIRSTHDR(msg); + cmsg != NULL && !ctx->err.has_error; + cmsg = CMSG_NXTHDR(msg,cmsg)) { + zval *elem; + + ALLOC_INIT_ZVAL(elem); + add_next_index_zval(zv, elem); + + if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + to_zval_read_control((const char *)cmsg, elem, ctx); + + zend_llist_remove_tail(&ctx->keys); + } +} + +/* CONVERSIONS for msghdr */ +static void from_zval_write_name(const zval *zname_arr, char *msghdr_c, ser_context *ctx) +{ + struct sockaddr *sockaddr; + socklen_t sockaddr_len; + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + + from_zval_write_sockaddr_aux(zname_arr, &sockaddr, &sockaddr_len, ctx); + + msghdr->msg_name = sockaddr; + msghdr->msg_namelen = sockaddr_len; +} +static void to_zval_read_name(const char *sockaddr_p, zval *zv, res_context *ctx) +{ + void *name = (void*)*(void**)sockaddr_p; + if (name == NULL) { + ZVAL_NULL(zv); + } else { + array_init(zv); + to_zval_read_sockaddr_aux(name, zv, ctx); + } +} +static void from_zval_write_msghdr_buffer_size(const zval *elem, char *msghdr_c, ser_context *ctx) +{ + long lval; + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + + lval = from_zval_integer_common(elem, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > MAX_USER_BUFF_SIZE) { + do_from_zval_err(ctx, "the buffer size must be between 1 and %ld; " + "given %ld", (long)MAX_USER_BUFF_SIZE, lval); + return; + } + + msghdr->msg_iovlen = 1; + msghdr->msg_iov = accounted_emalloc(sizeof(*msghdr->msg_iov) * 1, ctx); + msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)lval, ctx); + msghdr->msg_iov[0].iov_len = (size_t)lval; +} +static void from_zval_write_iov_array(const zval *arr, char *msghdr_c, ser_context *ctx) +{ + HashPosition pos; + int num_elem; + zval **elem; + unsigned i; + struct msghdr *msg = (struct msghdr*)msghdr_c; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + } + + num_elem = zend_hash_num_elements(Z_ARRVAL_P(arr)); + if (num_elem == 0) { + return; + } + + msg->msg_iov = accounted_safe_ecalloc(num_elem, sizeof *msg->msg_iov, 0, ctx); + msg->msg_iovlen = (size_t)num_elem; + + for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 0; + !ctx->err.has_error + && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; + zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos)) { + size_t len; + + if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + zval_add_ref(elem); + convert_to_string_ex(elem); + + len = Z_STRLEN_PP(elem); + msg->msg_iov[i - 1].iov_base = accounted_emalloc(len, ctx); + msg->msg_iov[i - 1].iov_len = len; + memcpy(msg->msg_iov[i - 1].iov_base, Z_STRVAL_PP(elem), len); + + zval_ptr_dtor(elem); + + zend_llist_remove_tail(&ctx->keys); + } + +} +static void from_zval_write_controllen(const zval *elem, char *msghdr_c, ser_context *ctx) +{ + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + uint32_t len; + + /* controllen should be an unsigned with at least 32-bit. Let's assume + * this least common denominator + */ + from_zval_write_uint32(elem, (char*)&len, ctx); + if (!ctx->err.has_error && len == 0) { + do_from_zval_err(ctx, "controllen cannot be 0"); + } + msghdr->msg_control = accounted_emalloc(len, ctx); + msghdr->msg_controllen = len; +} +static void from_zval_write_msghdr_send(const zval *container, char *msghdr_c, ser_context *ctx) +{ + static const field_descriptor descriptors[] = { + {"name", sizeof("name"), 0, 0, from_zval_write_name, 0}, + {"iov", sizeof("iov"), 0, 0, from_zval_write_iov_array, 0}, + {"control", sizeof("control"), 0, 0, from_zval_write_control_array, 0}, + {0} + }; + + from_zval_write_aggregation(container, msghdr_c, descriptors, ctx); +} +static void from_zval_write_msghdr_recv(const zval *container, char *msghdr_c, ser_context *ctx) +{ + /* zval to struct msghdr, version for recvmsg(). It differs from the version + * for sendmsg() in that it: + * - has a buffer_size instead of an iov array; + * - has no control element; has a controllen element instead + * struct msghdr { + * void *msg_name; + * socklen_t msg_namelen; + * struct iovec *msg_iov; + * size_t msg_iovlen; + * void *msg_control; + * size_t msg_controllen; //can also be socklen_t + * int msg_flags; + * }; + */ + static const field_descriptor descriptors[] = { + {"name", sizeof("name"), 0, 0, from_zval_write_name, 0}, + {"buffer_size", sizeof("buffer_size"), 0, 0, from_zval_write_msghdr_buffer_size, 0}, + {"controllen", sizeof("controllen"), 1, 0, from_zval_write_controllen, 0}, + {0} + }; + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + const int falsev = 0, + *falsevp = &falsev; + + if (zend_hash_add(&ctx->params, KEY_FILL_SOCKADDR, sizeof(KEY_FILL_SOCKADDR), + (void*)&falsevp, sizeof(falsevp), NULL) == FAILURE) { + do_from_zval_err(ctx, "could not add fill_sockaddr; this is a bug"); + return; + } + + from_zval_write_aggregation(container, msghdr_c, descriptors, ctx); + + zend_hash_del(&ctx->params, KEY_FILL_SOCKADDR, sizeof(KEY_FILL_SOCKADDR)); + if (ctx->err.has_error) { + return; + } + + if (msghdr->msg_iovlen == 0) { + msghdr->msg_iovlen = 1; + msghdr->msg_iov = accounted_emalloc(sizeof(*msghdr->msg_iov) * 1, ctx); + msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)DEFAULT_BUFF_SIZE, ctx); + msghdr->msg_iov[0].iov_len = (size_t)DEFAULT_BUFF_SIZE; + } +} + +static void to_zval_read_iov(const char *msghdr_c, zval *zv, res_context *ctx) +{ + const struct msghdr *msghdr = (const struct msghdr *)msghdr_c; + size_t iovlen = msghdr->msg_iovlen; + ssize_t **recvmsg_ret, + bytes_left; + uint i; + + if (iovlen > UINT_MAX) { + do_to_zval_err(ctx, "unexpectedly large value for iov_len: %lu", + (unsigned long)iovlen); + } + array_init_size(zv, (uint)iovlen); + + if (zend_hash_find(&ctx->params, KEY_RECVMSG_RET, sizeof(KEY_RECVMSG_RET), + (void**)&recvmsg_ret) == FAILURE) { + do_to_zval_err(ctx, "recvmsg_ret not found in params. This is a bug"); + return; + } + bytes_left = **recvmsg_ret; + + for (i = 0; bytes_left > 0 && i < (uint)iovlen; i++) { + zval *elem; + size_t len = MIN(msghdr->msg_iov[i].iov_len, bytes_left); + char *buf = safe_emalloc(1, len, 1); + + MAKE_STD_ZVAL(elem); + memcpy(buf, msghdr->msg_iov[i].iov_base, len); + buf[len] = '\0'; + + ZVAL_STRINGL(elem, buf, len, 0); + add_next_index_zval(zv, elem); + bytes_left -= len; + } +} +static void to_zval_read_msghdr(const char *msghdr_c, zval *zv, res_context *ctx) +{ + static const field_descriptor descriptors[] = { + {"name", sizeof("name"), 0, offsetof(struct msghdr, msg_name), 0, to_zval_read_name}, + {"control", sizeof("control"), 0, 0, 0, to_zval_read_control_array}, + {"iov", sizeof("iov"), 0, 0, 0, to_zval_read_iov}, + {"flags", sizeof("flags"), 0, offsetof(struct msghdr, msg_flags), 0, to_zval_read_int}, + {0} + }; + + array_init_size(zv, 4); + + to_zval_read_aggregation(msghdr_c, zv, descriptors, ctx); +} + + +/* CONVERSIONS for struct in6_pktinfo */ +static const field_descriptor descriptors_in6_pktinfo[] = { + {"addr", sizeof("addr"), 1, offsetof(struct in6_pktinfo, ipi6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, + {"ifindex", sizeof("ifindex"), 1, offsetof(struct in6_pktinfo, ipi6_ifindex), from_zval_write_unsigned, to_zval_read_unsigned}, + {0} +}; +static void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx) +{ + from_zval_write_aggregation(container, in6_pktinfo_c, descriptors_in6_pktinfo, ctx); +} +static void to_zval_read_in6_pktinfo(const char *data, zval *zv, res_context *ctx) +{ + array_init_size(zv, 2); + + to_zval_read_aggregation(data, zv, descriptors_in6_pktinfo, ctx); +} + +/* ENTRY POINT for conversions */ +static void free_from_zval_allocation(void *alloc_ptr_ptr) +{ + efree(*(void**)alloc_ptr_ptr); +} +static void *from_zval_run_conversions(const zval *container, + php_socket *sock, + from_zval_write_field *writer, + size_t struct_size, + const char *top_name, + zend_llist **allocations /* out */, + struct err_s *err /* in/out */) +{ + ser_context ctx = {{0}}; + char *structure = NULL; + + *allocations = NULL; + + if (err->has_error) { + return NULL; + } + + zend_hash_init(&ctx.params, 8, NULL, NULL, 0); + zend_llist_init(&ctx.keys, sizeof(const char *), NULL, 0); + zend_llist_init(&ctx.allocations, sizeof(void *), &free_from_zval_allocation, 0); + ctx.sock = sock; + + structure = ecalloc(1, struct_size); + + zend_llist_add_element(&ctx.keys, &top_name); + zend_llist_add_element(&ctx.allocations, &structure); + + /* main call */ + writer(container, structure, &ctx); + + if (ctx.err.has_error) { + zend_llist_destroy(&ctx.allocations); /* deallocates structure as well */ + structure = NULL; + *err = ctx.err; + } else { + *allocations = emalloc(sizeof **allocations); + **allocations = ctx.allocations; + } + + zend_llist_destroy(&ctx.keys); + zend_hash_destroy(&ctx.params); + + return structure; +} +static zval *to_zval_run_conversions(const char *structure, + to_zval_read_field *reader, + const char *top_name, + const struct key_value *key_value_pairs, + struct err_s *err) +{ + res_context ctx = {{0}, {0}}; + const struct key_value *kv; + zval *zv = NULL; + + if (err->has_error) { + return NULL; + } + + ALLOC_INIT_ZVAL(zv); + + zend_llist_init(&ctx.keys, sizeof(const char *), NULL, 0); + zend_llist_add_element(&ctx.keys, &top_name); + + zend_hash_init(&ctx.params, 8, NULL, NULL, 0); + for (kv = key_value_pairs; kv->key != NULL; kv++) { + zend_hash_update(&ctx.params, kv->key, kv->key_size, + (void*)&kv->value, sizeof(kv->value), NULL); + } + + /* main call */ + reader(structure, zv, &ctx); + + if (ctx.err.has_error) { + zval_ptr_dtor(&zv); + zv = NULL; + *err = ctx.err; + } + + zend_llist_destroy(&ctx.keys); + zend_hash_destroy(&ctx.params); + + return zv; +} + +#ifdef ZTS +static MUTEX_T ancillary_mutex; +#endif +static void init_ancillary_registry(void) +{ + ancillary_reg_entry entry; + anc_reg_key key; + ancillary_registry.initialized = 1; + + zend_hash_init(&ancillary_registry.ht, 32, NULL, NULL, 1); + + /* struct in6_pktinfo *pktinfo; */ + entry.size = sizeof(struct in6_pktinfo); + entry.from_array = from_zval_write_in6_pktinfo; + entry.to_array = to_zval_read_in6_pktinfo; + key.cmsg_level = IPPROTO_IPV6; + key.msg_type = IPV6_PKTINFO; + zend_hash_update(&ancillary_registry.ht, (char*)&key, sizeof(key), + (void*)&entry, sizeof(entry), NULL); +} +static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) +{ + anc_reg_key key = { cmsg_level, msg_type }; + ancillary_reg_entry *entry; + +#ifdef ZTS + tsrm_mutex_lock(ancillary_mutex); +#endif + if (!ancillary_registry.initialized) { + init_ancillary_registry(); + } +#ifdef ZTS + tsrm_mutex_unlock(ancillary_mutex); +#endif + + if (zend_hash_find(&ancillary_registry.ht, (char*)&key, sizeof(key), + (void**)&entry) == SUCCESS) { + return entry; + } else { + return NULL; + } +} + +PHP_FUNCTION(socket_sendmsg) +{ + zval *zsocket, + *zmsg; + long flags = 0; + php_socket *php_sock; + struct msghdr *msghdr; + zend_llist *allocations; + struct err_s err = {0}; + ssize_t res; + + /* zmsg should be passed by ref */ + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ra|l", &zsocket, &zmsg, &flags) == FAILURE) { + return; + } + + LONG_CHECK_VALID_INT(flags); + + ZEND_FETCH_RESOURCE(php_sock, php_socket *, &zsocket, -1, + php_sockets_le_socket_name, php_sockets_le_socket()); + + msghdr = from_zval_run_conversions(zmsg, php_sock, from_zval_write_msghdr_send, + sizeof(*msghdr), "msghdr", &allocations, &err); + + if (err.has_error) { + err_msg_dispose(&err TSRMLS_CC); + RETURN_FALSE; + } + + res = sendmsg(php_sock->bsd_socket, msghdr, (int)flags); + + if (res != -1) { + zend_llist_destroy(allocations); + efree(allocations); + + RETURN_LONG((long)res); + } else { + SOCKETS_G(last_error) = errno; + php_error_docref(NULL TSRMLS_CC, E_WARNING, "error in sendmsg [%d]: %s", + errno, sockets_strerror(errno TSRMLS_CC)); + RETURN_FALSE; + } +} + +PHP_FUNCTION(socket_recvmsg) +{ + zval *zsocket, + *zmsg; + long flags = 0; + php_socket *php_sock; + ssize_t res; + struct msghdr *msghdr; + zend_llist *allocations; + struct err_s err = {0}; + + //ssize_t recvmsg(int sockfd, struct msghdr *msg, int flags); + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ra|l", + &zsocket, &zmsg, &flags) == FAILURE) { + return; + } + + LONG_CHECK_VALID_INT(flags); + + ZEND_FETCH_RESOURCE(php_sock, php_socket *, &zsocket, -1, + php_sockets_le_socket_name, php_sockets_le_socket()); + + msghdr = from_zval_run_conversions(zmsg, php_sock, from_zval_write_msghdr_recv, + sizeof(*msghdr), "msghdr", &allocations, &err); + + if (err.has_error) { + err_msg_dispose(&err TSRMLS_CC); + RETURN_FALSE; + } + + res = recvmsg(php_sock->bsd_socket, msghdr, (int)flags); + + if (res != -1) { + zval *zres; + struct key_value kv[] = { + {KEY_RECVMSG_RET, sizeof(KEY_RECVMSG_RET), &res}, + {0} + }; + + + zres = to_zval_run_conversions((char *)msghdr, to_zval_read_msghdr, + "msghdr", kv, &err); + + /* we don;t need msghdr anymore; free it */ + msghdr = NULL; + zend_llist_destroy(allocations); + efree(allocations); + + zval_dtor(zmsg); + if (!err.has_error) { + ZVAL_COPY_VALUE(zmsg, zres); + efree(zres); /* only shallow destruction */ + } else { + err_msg_dispose(&err TSRMLS_CC); + ZVAL_FALSE(zmsg); + /* no need to destroy/free zres -- it's NULL in this circumstance */ + assert(zres == NULL); + } + } else { + SOCKETS_G(last_error) = errno; + php_error_docref(NULL TSRMLS_CC, E_WARNING, "error in recvmsg [%d]: %s", + errno, sockets_strerror(errno TSRMLS_CC)); + RETURN_FALSE; + } + + RETURN_LONG((long)res); +} + +PHP_FUNCTION(socket_cmsg_space) +{ + long level, + type; + ancillary_reg_entry *entry; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ll", &level, &type) == FAILURE) { + return; + } + + LONG_CHECK_VALID_INT(level); + LONG_CHECK_VALID_INT(type); + + entry = get_ancillary_reg_entry(level, type); + if (entry == NULL) { + php_error_docref0(NULL TSRMLS_CC, E_WARNING, "The pair level %ld/type %ld is " + "not supported by PHP", level, type); + return; + } + + RETURN_LONG((long)CMSG_SPACE(entry->size)); +} + +void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) +{ + REGISTER_LONG_CONSTANT("IPV6_RECVPKTINFO", IPV6_RECVPKTINFO, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_PKTINFO", IPV6_PKTINFO, CONST_CS | CONST_PERSISTENT); + +#ifdef ZTS + ancillary_mutex = tsrm_mutex_alloc(); +#endif +} + +void _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS) +{ +#ifdef ZTS + tsrm_mutex_free(ancillary_mutex); +#endif +} diff --git a/ext/sockets/sendrecvmsg.h b/ext/sockets/sendrecvmsg.h new file mode 100644 index 0000000000000..82dc456e65538 --- /dev/null +++ b/ext/sockets/sendrecvmsg.h @@ -0,0 +1,8 @@ +#include + +PHP_FUNCTION(socket_sendmsg); +PHP_FUNCTION(socket_recvmsg); +PHP_FUNCTION(socket_cmsg_space); + +void _socket_sendrecvmsg_init(INIT_FUNC_ARGS); +void _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS); diff --git a/ext/sockets/sockaddr_conv.c b/ext/sockets/sockaddr_conv.c new file mode 100644 index 0000000000000..19c61740d0cf7 --- /dev/null +++ b/ext/sockets/sockaddr_conv.c @@ -0,0 +1,119 @@ +#include +#include +#include "php_sockets.h" + +#ifdef PHP_WIN32 +#include +#else +#include +#include +#endif + +#if HAVE_IPV6 +/* Sets addr by hostname, or by ip in string form (AF_INET6) */ +int php_set_inet6_addr(struct sockaddr_in6 *sin6, char *string, php_socket *php_sock TSRMLS_DC) /* {{{ */ +{ + struct in6_addr tmp; +#if HAVE_GETADDRINFO + struct addrinfo hints; + struct addrinfo *addrinfo = NULL; +#endif + + if (inet_pton(AF_INET6, string, &tmp)) { + memcpy(&(sin6->sin6_addr.s6_addr), &(tmp.s6_addr), sizeof(struct in6_addr)); + } else { +#if HAVE_GETADDRINFO + + memset(&hints, 0, sizeof(struct addrinfo)); + hints.ai_family = AF_INET6; + hints.ai_flags = AI_V4MAPPED | AI_ADDRCONFIG; + getaddrinfo(string, NULL, &hints, &addrinfo); + if (!addrinfo) { +#ifdef PHP_WIN32 + PHP_SOCKET_ERROR(php_sock, "Host lookup failed", WSAGetLastError()); +#else + PHP_SOCKET_ERROR(php_sock, "Host lookup failed", (-10000 - h_errno)); +#endif + return 0; + } + if (addrinfo->ai_family != PF_INET6 || addrinfo->ai_addrlen != sizeof(struct sockaddr_in6)) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host lookup failed: Non AF_INET6 domain returned on AF_INET6 socket"); + freeaddrinfo(addrinfo); + return 0; + } + + memcpy(&(sin6->sin6_addr.s6_addr), ((struct sockaddr_in6*)(addrinfo->ai_addr))->sin6_addr.s6_addr, sizeof(struct in6_addr)); + freeaddrinfo(addrinfo); + +#else + /* No IPv6 specific hostname resolution is available on this system? */ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host lookup failed: getaddrinfo() not available on this system"); + return 0; +#endif + + } + + return 1; +} +/* }}} */ +#endif + +/* Sets addr by hostname, or by ip in string form (AF_INET) */ +int php_set_inet_addr(struct sockaddr_in *sin, char *string, php_socket *php_sock TSRMLS_DC) /* {{{ */ +{ + struct in_addr tmp; + struct hostent *host_entry; + + if (inet_aton(string, &tmp)) { + sin->sin_addr.s_addr = tmp.s_addr; + } else { + if (! (host_entry = gethostbyname(string))) { + /* Note: < -10000 indicates a host lookup error */ +#ifdef PHP_WIN32 + PHP_SOCKET_ERROR(php_sock, "Host lookup failed", WSAGetLastError()); +#else + PHP_SOCKET_ERROR(php_sock, "Host lookup failed", (-10000 - h_errno)); +#endif + return 0; + } + if (host_entry->h_addrtype != AF_INET) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host lookup failed: Non AF_INET domain returned on AF_INET socket"); + return 0; + } + memcpy(&(sin->sin_addr.s_addr), host_entry->h_addr_list[0], host_entry->h_length); + } + + return 1; +} +/* }}} */ + +/* Sets addr by hostname or by ip in string form (AF_INET or AF_INET6, + * depending on the socket) */ +int php_set_inet46_addr(php_sockaddr_storage *ss, socklen_t *ss_len, char *string, php_socket *php_sock TSRMLS_DC) /* {{{ */ +{ + if (php_sock->type == AF_INET) { + struct sockaddr_in t = {0}; + if (php_set_inet_addr(&t, string, php_sock TSRMLS_CC)) { + memcpy(ss, &t, sizeof t); + ss->ss_family = AF_INET; + *ss_len = sizeof(t); + return 1; + } + } +#if HAVE_IPV6 + else if (php_sock->type == AF_INET6) { + struct sockaddr_in6 t = {0}; + if (php_set_inet6_addr(&t, string, php_sock TSRMLS_CC)) { + memcpy(ss, &t, sizeof t); + ss->ss_family = AF_INET6; + *ss_len = sizeof(t); + return 1; + } + } +#endif + else { + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "IP address used in the context of an unexpected type of socket"); + } + return 0; +} diff --git a/ext/sockets/sockaddr_conv.h b/ext/sockets/sockaddr_conv.h new file mode 100644 index 0000000000000..444d749fe7397 --- /dev/null +++ b/ext/sockets/sockaddr_conv.h @@ -0,0 +1,24 @@ +#ifndef PHP_SOCKADR_CONV_H +#define PHP_SOCKADR_CONV_H + +#include +#include "php_sockets.h" + +/* + * Convert an IPv6 literal or a hostname info a sockaddr_in6. + * The IPv6 literal can be a IPv4 mapped address (like ::ffff:127.0.0.1). + * If the hostname yields no IPv6 addresses, a mapped IPv4 address may be returned (AI_V4MAPPED) + */ +int php_set_inet6_addr(struct sockaddr_in6 *sin6, char *string, php_socket *php_sock TSRMLS_DC); + +/* + * Convert an IPv4 literal or a hostname into a sockaddr_in. + */ +int php_set_inet_addr(struct sockaddr_in *sin, char *string, php_socket *php_sock TSRMLS_DC); + +/* + * Calls either php_set_inet6_addr() or php_set_inet_addr(), depending on the type of the socket. + */ +int php_set_inet46_addr(php_sockaddr_storage *ss, socklen_t *ss_len, char *string, php_socket *php_sock TSRMLS_DC); + +#endif diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 33d8a09d7d564..8f06d96f7f7ab 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -86,7 +86,9 @@ # endif #endif +#include "sockaddr_conv.h" #include "multicast.h" +#include "sendrecvmsg.h" ZEND_DECLARE_MODULE_GLOBALS(sockets) static PHP_GINIT_FUNCTION(sockets); @@ -113,8 +115,6 @@ static PHP_GINIT_FUNCTION(sockets); #define PF_INET AF_INET #endif -static char *php_strerror(int error TSRMLS_DC); - #define PHP_NORMAL_READ 0x0001 #define PHP_BINARY_READ 0x0002 @@ -270,10 +270,27 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_socket_clear_error, 0, 0, 0) ZEND_ARG_INFO(0, socket) ZEND_END_ARG_INFO() - + ZEND_BEGIN_ARG_INFO_EX(arginfo_socket_import_stream, 0, 0, 1) ZEND_ARG_INFO(0, stream) ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_socket_sendmsg, 0, 0, 3) + ZEND_ARG_INFO(0, socket) + ZEND_ARG_INFO(0, msghdr) + ZEND_ARG_INFO(0, flags) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_socket_recvmsg, 0, 0, 3) + ZEND_ARG_INFO(0, socket) + ZEND_ARG_INFO(1, msghdr) + ZEND_ARG_INFO(0, flags) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_socket_cmsg_space, 0, 0, 2) + ZEND_ARG_INFO(0, level) + ZEND_ARG_INFO(0, type) +ZEND_END_ARG_INFO() /* }}} */ PHP_MINIT_FUNCTION(sockets); @@ -344,6 +361,9 @@ const zend_function_entry sockets_functions[] = { PHP_FE(socket_last_error, arginfo_socket_last_error) PHP_FE(socket_clear_error, arginfo_socket_clear_error) PHP_FE(socket_import_stream, arginfo_socket_import_stream) + PHP_FE(socket_sendmsg, arginfo_socket_sendmsg) + PHP_FE(socket_recvmsg, arginfo_socket_recvmsg) + PHP_FE(socket_cmsg_space, arginfo_socket_cmsg_space) /* for downwards compatability */ PHP_FALIAS(socket_getopt, socket_get_option, arginfo_socket_get_option) @@ -389,13 +409,13 @@ PHP_SOCKETS_API int php_sockets_le_socket(void) /* {{{ */ static php_socket *php_create_socket(void) /* {{{ */ { php_socket *php_sock = emalloc(sizeof *php_sock); - + php_sock->bsd_socket = -1; /* invalid socket */ php_sock->type = PF_UNSPEC; php_sock->error = 0; php_sock->blocking = 1; php_sock->zstream = NULL; - + return php_sock; } /* }}} */ @@ -552,7 +572,7 @@ static int php_read(php_socket *sock, void *buf, size_t maxlen, int flags) } /* }}} */ -static char *php_strerror(int error TSRMLS_DC) /* {{{ */ +char *sockets_strerror(int error TSRMLS_DC) /* {{{ */ { const char *buf; @@ -599,113 +619,6 @@ static char *php_strerror(int error TSRMLS_DC) /* {{{ */ } /* }}} */ -#if HAVE_IPV6 -/* Sets addr by hostname, or by ip in string form (AF_INET6) */ -static int php_set_inet6_addr(struct sockaddr_in6 *sin6, char *string, php_socket *php_sock TSRMLS_DC) /* {{{ */ -{ - struct in6_addr tmp; -#if HAVE_GETADDRINFO - struct addrinfo hints; - struct addrinfo *addrinfo = NULL; -#endif - - if (inet_pton(AF_INET6, string, &tmp)) { - memcpy(&(sin6->sin6_addr.s6_addr), &(tmp.s6_addr), sizeof(struct in6_addr)); - } else { -#if HAVE_GETADDRINFO - - memset(&hints, 0, sizeof(struct addrinfo)); - hints.ai_family = PF_INET6; - getaddrinfo(string, NULL, &hints, &addrinfo); - if (!addrinfo) { -#ifdef PHP_WIN32 - PHP_SOCKET_ERROR(php_sock, "Host lookup failed", WSAGetLastError()); -#else - PHP_SOCKET_ERROR(php_sock, "Host lookup failed", (-10000 - h_errno)); -#endif - return 0; - } - if (addrinfo->ai_family != PF_INET6 || addrinfo->ai_addrlen != sizeof(struct sockaddr_in6)) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host lookup failed: Non AF_INET6 domain returned on AF_INET6 socket"); - freeaddrinfo(addrinfo); - return 0; - } - - memcpy(&(sin6->sin6_addr.s6_addr), ((struct sockaddr_in6*)(addrinfo->ai_addr))->sin6_addr.s6_addr, sizeof(struct in6_addr)); - freeaddrinfo(addrinfo); - -#else - /* No IPv6 specific hostname resolution is available on this system? */ - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host lookup failed: getaddrinfo() not available on this system"); - return 0; -#endif - - } - - return 1; -} -/* }}} */ -#endif - -/* Sets addr by hostname, or by ip in string form (AF_INET) */ -static int php_set_inet_addr(struct sockaddr_in *sin, char *string, php_socket *php_sock TSRMLS_DC) /* {{{ */ -{ - struct in_addr tmp; - struct hostent *host_entry; - - if (inet_aton(string, &tmp)) { - sin->sin_addr.s_addr = tmp.s_addr; - } else { - if (! (host_entry = gethostbyname(string))) { - /* Note: < -10000 indicates a host lookup error */ -#ifdef PHP_WIN32 - PHP_SOCKET_ERROR(php_sock, "Host lookup failed", WSAGetLastError()); -#else - PHP_SOCKET_ERROR(php_sock, "Host lookup failed", (-10000 - h_errno)); -#endif - return 0; - } - if (host_entry->h_addrtype != AF_INET) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Host lookup failed: Non AF_INET domain returned on AF_INET socket"); - return 0; - } - memcpy(&(sin->sin_addr.s_addr), host_entry->h_addr_list[0], host_entry->h_length); - } - - return 1; -} -/* }}} */ - -/* Sets addr by hostname or by ip in string form (AF_INET or AF_INET6, - * depending on the socket) */ -static int php_set_inet46_addr(php_sockaddr_storage *ss, socklen_t *ss_len, char *string, php_socket *php_sock TSRMLS_DC) /* {{{ */ -{ - if (php_sock->type == AF_INET) { - struct sockaddr_in t = {0}; - if (php_set_inet_addr(&t, string, php_sock TSRMLS_CC)) { - memcpy(ss, &t, sizeof t); - ss->ss_family = AF_INET; - *ss_len = sizeof(t); - return 1; - } - } -#if HAVE_IPV6 - else if (php_sock->type == AF_INET6) { - struct sockaddr_in6 t = {0}; - if (php_set_inet6_addr(&t, string, php_sock TSRMLS_CC)) { - memcpy(ss, &t, sizeof t); - ss->ss_family = AF_INET6; - *ss_len = sizeof(t); - return 1; - } - } -#endif - else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "IP address used in the context of an unexpected type of socket"); - } - return 0; -} static int php_get_if_index_from_zval(zval *val, unsigned *out TSRMLS_DC) { @@ -751,12 +664,12 @@ static int php_get_if_index_from_array(const HashTable *ht, const char *key, php_socket *sock, unsigned int *if_index TSRMLS_DC) { zval **val; - + if (zend_hash_find(ht, key, strlen(key) + 1, (void **)&val) == FAILURE) { *if_index = 0; /* default: 0 */ return SUCCESS; } - + return php_get_if_index_from_zval(*val, if_index TSRMLS_CC); } @@ -765,14 +678,14 @@ static int php_get_address_from_array(const HashTable *ht, const char *key, { zval **val, *valcp; - + if (zend_hash_find(ht, key, strlen(key) + 1, (void **)&val) == FAILURE) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "no key \"%s\" passed in optval", key); return FAILURE; } valcp = *val; zval_add_ref(&valcp); - convert_to_string_ex(val); + convert_to_string_ex(val); if (!php_set_inet46_addr(ss, ss_len, Z_STRVAL_P(valcp), sock TSRMLS_CC)) { zval_ptr_dtor(&valcp); return FAILURE; @@ -854,7 +767,7 @@ PHP_MINIT_FUNCTION(sockets) #define MCAST_LEAVE_SOURCE_GROUP IP_DROP_SOURCE_MEMBERSHIP #endif #endif - + REGISTER_LONG_CONSTANT("MCAST_JOIN_GROUP", MCAST_JOIN_GROUP, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MCAST_LEAVE_GROUP", MCAST_LEAVE_GROUP, CONST_CS | CONST_PERSISTENT); #ifdef HAS_MCAST_EXT @@ -887,6 +800,8 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("SOL_TCP", IPPROTO_TCP, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SOL_UDP", IPPROTO_UDP, CONST_CS | CONST_PERSISTENT); + _socket_sendrecvmsg_init(INIT_FUNC_ARGS_PASSTHRU); + return SUCCESS; } /* }}} */ @@ -908,6 +823,7 @@ PHP_RSHUTDOWN_FUNCTION(sockets) efree(SOCKETS_G(strerror_buf)); SOCKETS_G(strerror_buf) = NULL; } + _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS_PASSTHRU); return SUCCESS; } @@ -1049,7 +965,7 @@ PHP_FUNCTION(socket_select) if (retval == -1) { SOCKETS_G(last_error) = errno; - php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to select [%d]: %s", errno, php_strerror(errno TSRMLS_CC)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to select [%d]: %s", errno, sockets_strerror(errno TSRMLS_CC)); RETURN_FALSE; } @@ -1118,7 +1034,7 @@ PHP_FUNCTION(socket_set_nonblock) } ZEND_FETCH_RESOURCE(php_sock, php_socket *, &arg1, -1, le_socket_name, le_socket); - + if (php_sock->zstream != NULL) { php_stream *stream; /* omit notice if resource doesn't exist anymore */ @@ -1155,7 +1071,7 @@ PHP_FUNCTION(socket_set_block) } ZEND_FETCH_RESOURCE(php_sock, php_socket *, &arg1, -1, le_socket_name, le_socket); - + /* if socket was created from a stream, give the stream a chance to take * care of the operation itself, thereby allowing it to update its internal * state */ @@ -1509,7 +1425,7 @@ PHP_FUNCTION(socket_create) if (IS_INVALID_SOCKET(php_sock)) { SOCKETS_G(last_error) = errno; - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to create socket [%d]: %s", errno, php_strerror(errno TSRMLS_CC)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to create socket [%d]: %s", errno, sockets_strerror(errno TSRMLS_CC)); efree(php_sock); RETURN_FALSE; } @@ -1542,7 +1458,7 @@ PHP_FUNCTION(socket_connect) #if HAVE_IPV6 case AF_INET6: { struct sockaddr_in6 sin6 = {0}; - + if (argc != 3) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Socket of type AF_INET6 requires 3 arguments"); RETURN_FALSE; @@ -1563,7 +1479,7 @@ PHP_FUNCTION(socket_connect) #endif case AF_INET: { struct sockaddr_in sin = {0}; - + if (argc != 3) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Socket of type AF_INET requires 3 arguments"); RETURN_FALSE; @@ -1582,7 +1498,7 @@ PHP_FUNCTION(socket_connect) case AF_UNIX: { struct sockaddr_un s_un = {0}; - + if (addr_len >= sizeof(s_un.sun_path)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Path too long"); RETURN_FALSE; @@ -1619,7 +1535,7 @@ PHP_FUNCTION(socket_strerror) return; } - RETURN_STRING(php_strerror(arg1 TSRMLS_CC), 1); + RETURN_STRING(sockets_strerror(arg1 TSRMLS_CC), 1); } /* }}} */ @@ -2011,7 +1927,7 @@ PHP_FUNCTION(socket_get_option) } } } - + /* sol_socket options and general case */ switch(optname) { case SO_LINGER: @@ -2053,7 +1969,7 @@ PHP_FUNCTION(socket_get_option) add_assoc_long(return_value, "sec", tv.tv_sec); add_assoc_long(return_value, "usec", tv.tv_usec); break; - + default: optlen = sizeof(other_val); @@ -2126,12 +2042,12 @@ static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval * source = {0}; socklen_t glen, slen; - + mcast_sreq_fun = &php_mcast_leave_source; mcast_sreq_fun: convert_to_array_ex(arg4); opt_ht = HASH_OF(*arg4); - + if (php_get_address_from_array(opt_ht, "group", php_sock, &group, &glen TSRMLS_CC) == FAILURE) { return FAILURE; @@ -2144,7 +2060,7 @@ static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval * &if_index TSRMLS_CC) == FAILURE) { return FAILURE; } - + retval = mcast_sreq_fun(php_sock, level, (struct sockaddr*)&group, glen, (struct sockaddr*)&source, slen, if_index TSRMLS_CC); break; @@ -2184,12 +2100,12 @@ PHP_FUNCTION(socket_set_option) HashTable *opt_ht; zval **l_onoff, **l_linger; zval **sec, **usec; - + /* Multicast */ unsigned int if_index; struct in_addr if_addr; unsigned char ipv4_mcast_ttl_lback; - + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rllZ", &arg1, &level, &optname, &arg4) == FAILURE) { return; } @@ -2265,7 +2181,7 @@ PHP_FUNCTION(socket_set_option) if (php_get_if_index_from_zval(*arg4, &if_index TSRMLS_CC) == FAILURE) { RETURN_FALSE; } - + opt_ptr = &if_index; optlen = sizeof(if_index); goto dosockopt; @@ -2348,7 +2264,7 @@ PHP_FUNCTION(socket_set_option) #endif break; } - + default: convert_to_long_ex(arg4); ov = Z_LVAL_PP(arg4); @@ -2404,7 +2320,7 @@ PHP_FUNCTION(socket_create_pair) if (socketpair(domain, type, protocol, fds_array) != 0) { SOCKETS_G(last_error) = errno; - php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to create socket pair [%d]: %s", errno, php_strerror(errno TSRMLS_CC)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to create socket pair [%d]: %s", errno, sockets_strerror(errno TSRMLS_CC)); efree(php_sock[0]); efree(php_sock[1]); RETURN_FALSE; @@ -2521,16 +2437,16 @@ PHP_FUNCTION(socket_import_stream) return; } php_stream_from_zval(stream, &zstream); - + if (php_stream_cast(stream, PHP_STREAM_AS_SOCKETD, (void**)&socket, 1)) { /* error supposedly already shown */ RETURN_FALSE; } - + retsock = php_create_socket(); - + retsock->bsd_socket = socket; - + /* determine family */ if (getsockname(socket, (struct sockaddr*)&addr, &addr_len) == 0) { retsock->type = addr.ss_family; @@ -2538,7 +2454,7 @@ PHP_FUNCTION(socket_import_stream) PHP_SOCKET_ERROR(retsock, "unable to obtain socket family", errno); goto error; } - + /* determine blocking mode */ #ifndef PHP_WIN32 t = fcntl(socket, F_GETFL); @@ -2558,7 +2474,7 @@ PHP_FUNCTION(socket_import_stream) retsock->blocking = 1; } #endif - + /* hold a zval reference to the stream (holding a php_stream* directly could * also be done, but this might be slightly better if in the future we want * to provide a socket_export_stream) */ @@ -2567,10 +2483,10 @@ PHP_FUNCTION(socket_import_stream) zval_copy_ctor(retsock->zstream); Z_UNSET_ISREF_P(retsock->zstream); Z_SET_REFCOUNT_P(retsock->zstream, 1); - + php_stream_set_option(stream, PHP_STREAM_OPTION_READ_BUFFER, PHP_STREAM_BUFFER_NONE, NULL); - + ZEND_REGISTER_RESOURCE(return_value, retsock, le_socket); return; error: From eb4b1f6d46d94772611a24c70b15e46c557caeec Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Fri, 2 Nov 2012 14:03:47 +0100 Subject: [PATCH 2336/2394] Add test for recvmsg() --- ext/sockets/tests/recvmsg.phpt | 86 ++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 ext/sockets/tests/recvmsg.phpt diff --git a/ext/sockets/tests/recvmsg.phpt b/ext/sockets/tests/recvmsg.phpt new file mode 100644 index 0000000000000..30263a4fbd05e --- /dev/null +++ b/ext/sockets/tests/recvmsg.phpt @@ -0,0 +1,86 @@ +--TEST-- +recvmsg(): basic test +--SKIPIF-- + ["family" => AF_INET6, "addr" => "::1"], + "buffer_size" => 2000, + "controllen" => socket_cmsg_space(IPPROTO_IPV6, IPV6_PKTINFO), +]; +if (!socket_recvmsg($s, $data, 0)) die("recvmsg"); +print_r($data); + +--EXPECTF-- +creating send socket +resource(%d) of type (Socket) +bool(true) +creating receive socket +resource(%d) of type (Socket) +bool(true) +int(14) +Array +( + [name] => Array + ( + [family] => %d + [addr] => ::1 + [port] => 7001 + [flowinfo] => 0 + [scope_id] => 0 + ) + + [control] => Array + ( + [0] => Array + ( + [level] => %d + [type] => %d + [data] => Array + ( + [addr] => ::1 + [ifindex] => %d + ) + + ) + + ) + + [iov] => Array + ( + [0] => testing packet + ) + + [flags] => 0 +) From 806a6e6399568d3bfbef355992fb3d09e29a607c Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Fri, 2 Nov 2012 15:02:47 +0100 Subject: [PATCH 2337/2394] Add IPV6_UNICAST_HOPS option constant. --- ext/sockets/sockets.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 8f06d96f7f7ab..b213b0a6cd902 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -800,6 +800,10 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("SOL_TCP", IPPROTO_TCP, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SOL_UDP", IPPROTO_UDP, CONST_CS | CONST_PERSISTENT); +#if HAVE_IPV6 + REGISTER_LONG_CONSTANT("IPV6_UNICAST_HOPS", IPV6_UNICAST_HOPS, CONST_CS | CONST_PERSISTENT); +#endif + _socket_sendrecvmsg_init(INIT_FUNC_ARGS_PASSTHRU); return SUCCESS; From b06f00477ce4f20516c6f727797f208ffaefcae9 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Fri, 2 Nov 2012 17:52:13 +0100 Subject: [PATCH 2338/2394] Fix bug converting zval sockaddr The bug ocurred when the family was not specified but was instead guessed. --- ext/sockets/sendrecvmsg.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 379af125d70b4..837ae2373575a 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -627,6 +627,7 @@ static void from_zval_write_sockaddr_aux(const zval *container, *sockaddr_len = sizeof(struct sockaddr_in); if (fill_sockaddr) { from_zval_write_sockaddr_in(container, (char*)*sockaddr_ptr, ctx); + (*sockaddr_ptr)->sa_family = AF_INET; } break; case AF_INET6: @@ -639,6 +640,7 @@ static void from_zval_write_sockaddr_aux(const zval *container, *sockaddr_len = sizeof(struct sockaddr_in6); if (fill_sockaddr) { from_zval_write_sockaddr_in6(container, (char*)*sockaddr_ptr, ctx); + (*sockaddr_ptr)->sa_family = AF_INET6; } break; default: From b27c22d627e342687eb0c21bac8859ea1d91b54b Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Fri, 2 Nov 2012 17:53:48 +0100 Subject: [PATCH 2339/2394] Fix bug in from_zval_write_control_array() --- ext/sockets/sendrecvmsg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 837ae2373575a..0489e977be4e9 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -792,7 +792,7 @@ static void from_zval_write_control_array(const zval *arr, char *msghdr_c, ser_c } msg->msg_control = control_buf; - msg->msg_controllen = control_len; + msg->msg_controllen = cur_offset; /* not control_len, which may be larger */ } static void to_zval_read_cmsg_data(const char *cmsghdr_c, zval *zv, res_context *ctx) { From 73ab2385cb4dd2da08be940f0f6b0ef9f06f15b8 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Fri, 2 Nov 2012 17:54:31 +0100 Subject: [PATCH 2340/2394] Support for IPV6_HOPLIMIT and IPV6_TCLASS --- ext/sockets/sendrecvmsg.c | 43 ++++++++++++++++++++++++++++++++++----- 1 file changed, 38 insertions(+), 5 deletions(-) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 0489e977be4e9..e47bd46e3834d 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -98,7 +98,7 @@ typedef struct { typedef struct { int cmsg_level; /* originating protocol */ - int msg_type; /* protocol-specific type */ + int cmsg_type; /* protocol-specific type */ } anc_reg_key; static struct { @@ -1194,14 +1194,32 @@ static void init_ancillary_registry(void) zend_hash_init(&ancillary_registry.ht, 32, NULL, NULL, 1); - /* struct in6_pktinfo *pktinfo; */ +#define PUT_ENTRY() \ + zend_hash_update(&ancillary_registry.ht, (char*)&key, sizeof(key), \ + (void*)&entry, sizeof(entry), NULL) + entry.size = sizeof(struct in6_pktinfo); entry.from_array = from_zval_write_in6_pktinfo; entry.to_array = to_zval_read_in6_pktinfo; key.cmsg_level = IPPROTO_IPV6; - key.msg_type = IPV6_PKTINFO; - zend_hash_update(&ancillary_registry.ht, (char*)&key, sizeof(key), - (void*)&entry, sizeof(entry), NULL); + key.cmsg_type = IPV6_PKTINFO; + PUT_ENTRY(); + + entry.size = sizeof(int); + entry.from_array = from_zval_write_int; + entry.to_array = to_zval_read_int; + key.cmsg_level = IPPROTO_IPV6; + key.cmsg_type = IPV6_HOPLIMIT; + PUT_ENTRY(); + + entry.size = sizeof(int); + entry.from_array = from_zval_write_int; + entry.to_array = to_zval_read_int; + key.cmsg_level = IPPROTO_IPV6; + key.cmsg_type = IPV6_TCLASS; + PUT_ENTRY(); + + } static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) { @@ -1364,7 +1382,22 @@ PHP_FUNCTION(socket_cmsg_space) void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) { REGISTER_LONG_CONSTANT("IPV6_RECVPKTINFO", IPV6_RECVPKTINFO, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_RECVHOPLIMIT", IPV6_RECVHOPLIMIT, CONST_CS | CONST_PERSISTENT); + /* would require some effort: + REGISTER_LONG_CONSTANT("IPV6_RECVRTHDR", IPV6_RECVRTHDR, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_RECVHOPOPTS", IPV6_RECVHOPOPTS, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_RECVDSTOPTS", IPV6_RECVDSTOPTS, CONST_CS | CONST_PERSISTENT); + */ + REGISTER_LONG_CONSTANT("IPV6_RECVTCLASS", IPV6_RECVTCLASS, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_PKTINFO", IPV6_PKTINFO, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_HOPLIMIT", IPV6_HOPLIMIT, CONST_CS | CONST_PERSISTENT); + /* + REGISTER_LONG_CONSTANT("IPV6_RTHDR", IPV6_RTHDR, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_HOPOPTS", IPV6_HOPOPTS, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_DSTOPTS", IPV6_DSTOPTS, CONST_CS | CONST_PERSISTENT); + */ + REGISTER_LONG_CONSTANT("IPV6_TCLASS", IPV6_TCLASS, CONST_CS | CONST_PERSISTENT); #ifdef ZTS ancillary_mutex = tsrm_mutex_alloc(); From 0f849fe2aa7c8894b2dbde57abd8a3a3aa8f764a Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 4 Nov 2012 19:16:10 +0100 Subject: [PATCH 2341/2394] Add test and slightly tweak another --- .../{recvmsg.phpt => socket_recvmsg.phpt} | 0 .../tests/socket_sendrecvmsg_multi_msg.phpt | 103 ++++++++++++++++++ 2 files changed, 103 insertions(+) rename ext/sockets/tests/{recvmsg.phpt => socket_recvmsg.phpt} (100%) create mode 100644 ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt diff --git a/ext/sockets/tests/recvmsg.phpt b/ext/sockets/tests/socket_recvmsg.phpt similarity index 100% rename from ext/sockets/tests/recvmsg.phpt rename to ext/sockets/tests/socket_recvmsg.phpt diff --git a/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt b/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt new file mode 100644 index 0000000000000..055e263f724c1 --- /dev/null +++ b/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt @@ -0,0 +1,103 @@ +--TEST-- +sendmsg()/recvmsg(): test ability to receive multiple messages +--SKIPIF-- + [ "addr" => "::1", "port" => 3000], + "iov" => ["test ", "thing", "\n"], + "control" => [[ + "level" => IPPROTO_IPV6, + "type" => IPV6_TCLASS, + "data" => 42, + ]] +], 0); +var_dump($r); +checktimeout($s, 500); + +$data = [ + "name" => ["family" => AF_INET6, "addr" => "::1"], + "buffer_size" => 2000, + "controllen" => socket_cmsg_space(IPPROTO_IPV6, IPV6_PKTINFO) + + socket_cmsg_space(IPPROTO_IPV6, IPV6_TCLASS), +]; +if (!socket_recvmsg($s, $data, 0)) die("recvmsg"); +print_r($data); + +--EXPECTF-- +creating send socket +resource(5) of type (Socket) +bool(true) +creating receive socket +resource(6) of type (Socket) +bool(true) +int(11) +Array +( + [name] => Array + ( + [family] => %d + [addr] => ::1 + [port] => 7001 + [flowinfo] => 0 + [scope_id] => 0 + ) + + [control] => Array + ( + [0] => Array + ( + [level] => %d + [type] => %d + [data] => Array + ( + [addr] => ::1 + [ifindex] => %d + ) + + ) + + [1] => Array + ( + [level] => %d + [type] => %d + [data] => 42 + ) + + ) + + [iov] => Array + ( + [0] => test thing + + ) + + [flags] => 0 +) From 17540788ad8c25969f1dbd02c1a3b75a8417fe9c Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 11:36:00 +0100 Subject: [PATCH 2342/2394] Added missing return statements --- ext/sockets/sendrecvmsg.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index e47bd46e3834d..3405215ef3367 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -918,6 +918,7 @@ static void from_zval_write_iov_array(const zval *arr, char *msghdr_c, ser_conte if (Z_TYPE_P(arr) != IS_ARRAY) { do_from_zval_err(ctx, "%s", "expected an array here"); + return; } num_elem = zend_hash_num_elements(Z_ARRVAL_P(arr)); @@ -964,6 +965,7 @@ static void from_zval_write_controllen(const zval *elem, char *msghdr_c, ser_con from_zval_write_uint32(elem, (char*)&len, ctx); if (!ctx->err.has_error && len == 0) { do_from_zval_err(ctx, "controllen cannot be 0"); + return; } msghdr->msg_control = accounted_emalloc(len, ctx); msghdr->msg_controllen = len; From b3effa60c73922ddf4a7df3be3a0e4e5ca47f70d Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 23 Oct 2012 13:09:38 +0200 Subject: [PATCH 2343/2394] Improve imported socket family detection Also added constant SO_FAMILY. --- ext/sockets/sockets.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index b213b0a6cd902..863825df13fd0 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -748,6 +748,9 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("SO_SNDTIMEO", SO_SNDTIMEO, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SO_RCVTIMEO", SO_RCVTIMEO, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SO_TYPE", SO_TYPE, CONST_CS | CONST_PERSISTENT); +#ifdef SO_FAMILY + REGISTER_LONG_CONSTANT("SO_FAMILY", SO_FAMILY, CONST_CS | CONST_PERSISTENT); +#endif REGISTER_LONG_CONSTANT("SO_ERROR", SO_ERROR, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SOL_SOCKET", SOL_SOCKET, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SOMAXCONN", SOMAXCONN, CONST_CS | CONST_PERSISTENT); @@ -2436,6 +2439,10 @@ PHP_FUNCTION(socket_import_stream) #ifndef PHP_WIN32 int t; #endif +#ifdef SO_DOMAIN + int type; + socklen_t type_len = sizeof(type); +#endif if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &zstream) == FAILURE) { return; @@ -2452,6 +2459,11 @@ PHP_FUNCTION(socket_import_stream) retsock->bsd_socket = socket; /* determine family */ +#ifdef SO_DOMAIN + if (getsockopt(socket, SOL_SOCKET, SO_DOMAIN, &type, &type_len) == 0) { + retsock->type = type; + } else +#endif if (getsockname(socket, (struct sockaddr*)&addr, &addr_len) == 0) { retsock->type = addr.ss_family; } else { From 131245474bf95490cf1a1dfdb5debe5d46133522 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 14:52:48 +0100 Subject: [PATCH 2344/2394] Redactor to expose socket_import_file_descriptor() --- ext/sockets/php_sockets.h | 1 + ext/sockets/sockets.c | 90 ++++++++++++++++++++++----------------- 2 files changed, 52 insertions(+), 39 deletions(-) diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 9158ca49072c0..3138eb60c45c6 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -88,6 +88,7 @@ ZEND_END_MODULE_GLOBALS(sockets) ZEND_EXTERN_MODULE_GLOBALS(sockets); char *sockets_strerror(int error TSRMLS_DC); +php_socket *socket_import_file_descriptor(PHP_SOCKET sock TSRMLS_DC); #define PHP_SOCKET_ERROR(socket,msg,errn) \ socket->error = errn; \ diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 863825df13fd0..449be8f9373b6 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -2426,41 +2426,25 @@ PHP_FUNCTION(socket_clear_error) } /* }}} */ -/* {{{ proto void socket_import_stream(resource stream) - Imports a stream that encapsulates a socket into a socket extension resource. */ -PHP_FUNCTION(socket_import_stream) +php_socket *socket_import_file_descriptor(PHP_SOCKET socket TSRMLS_DC) { - zval *zstream; - php_stream *stream; - php_socket *retsock = NULL; - PHP_SOCKET socket; /* fd */ - php_sockaddr_storage addr; - socklen_t addr_len = sizeof(addr); +#ifdef SO_DOMAIN + int type; + socklen_t type_len = sizeof(type); +#endif + php_socket *retsock; + php_sockaddr_storage addr; + socklen_t addr_len = sizeof(addr); #ifndef PHP_WIN32 int t; #endif -#ifdef SO_DOMAIN - int type; - socklen_t type_len = sizeof(type); -#endif - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &zstream) == FAILURE) { - return; - } - php_stream_from_zval(stream, &zstream); - - if (php_stream_cast(stream, PHP_STREAM_AS_SOCKETD, (void**)&socket, 1)) { - /* error supposedly already shown */ - RETURN_FALSE; - } - - retsock = php_create_socket(); + retsock = php_create_socket(); + retsock->bsd_socket = socket; - retsock->bsd_socket = socket; - - /* determine family */ + /* determine family */ #ifdef SO_DOMAIN - if (getsockopt(socket, SOL_SOCKET, SO_DOMAIN, &type, &type_len) == 0) { + if (getsockopt(socket, SOL_SOCKET, SO_DOMAIN, &type, &type_len) == 0) { retsock->type = type; } else #endif @@ -2471,16 +2455,49 @@ PHP_FUNCTION(socket_import_stream) goto error; } - /* determine blocking mode */ + /* determine blocking mode */ #ifndef PHP_WIN32 - t = fcntl(socket, F_GETFL); - if(t == -1) { + t = fcntl(socket, F_GETFL); + if (t == -1) { PHP_SOCKET_ERROR(retsock, "unable to obtain blocking state", errno); goto error; - } else { - retsock->blocking = !(t & O_NONBLOCK); + } else { + retsock->blocking = !(t & O_NONBLOCK); + } +#endif + + return retsock; + +error: + efree(retsock); + return NULL; +} + +/* {{{ proto void socket_import_stream(resource stream) + Imports a stream that encapsulates a socket into a socket extension resource. */ +PHP_FUNCTION(socket_import_stream) +{ + zval *zstream; + php_stream *stream; + php_socket *retsock = NULL; + PHP_SOCKET socket; /* fd */ + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &zstream) == FAILURE) { + return; } -#else + php_stream_from_zval(stream, &zstream); + + if (php_stream_cast(stream, PHP_STREAM_AS_SOCKETD, (void**)&socket, 1)) { + /* error supposedly already shown */ + RETURN_FALSE; + } + + retsock = socket_import_file_descriptor(socket); + if (retsock == NULL) { + RETURN_FALSE; + } + +#ifdef PHP_WIN32 /* on windows, check if the stream is a socket stream and read its * private data; otherwise assume it's in non-blocking mode */ if (php_stream_is(stream, PHP_STREAM_IS_SOCKET)) { @@ -2504,11 +2521,6 @@ PHP_FUNCTION(socket_import_stream) PHP_STREAM_BUFFER_NONE, NULL); ZEND_REGISTER_RESOURCE(return_value, retsock, le_socket); - return; -error: - if (retsock != NULL) - efree(retsock); - RETURN_FALSE; } /* }}} */ From a85d7f28f69fbc522ed90aee1926d3733be7620d Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 00:38:23 +0100 Subject: [PATCH 2345/2394] Added support for AF_UNIX messages Added constants: SCM_RIGHTS, SCM_CREDENTIALS and SO_PASSCRED. The function socket_cmsg_space() was modified to support message types with variable size. Its new signature is: int socket_cmsg_space(int $level, int $type, int $n) where $n is the number of repetable elements that the message is composed of. --- ext/sockets/sendrecvmsg.c | 420 ++++++++++++++++++++++++++++++++------ 1 file changed, 363 insertions(+), 57 deletions(-) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 3405215ef3367..f6a71dbefc7ef 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -23,6 +23,7 @@ #include #include #include +#include #include #include #include @@ -75,10 +76,12 @@ struct key_value { }; #define KEY_FILL_SOCKADDR "fill_sockaddr" #define KEY_RECVMSG_RET "recvmsg_ret" +#define KEY_CMSG_LEN "cmsg_len" typedef void (from_zval_write_field)(const zval *arr_value, char *field, ser_context *ctx); typedef void (to_zval_read_field)(const char *data, zval *zv, res_context *ctx); +typedef size_t (calculate_req_space)(const zval *value, ser_context *ctx); typedef struct { /* zval info */ @@ -110,6 +113,8 @@ typedef socklen_t (*ancillary_size)(void); typedef struct { socklen_t size; /* size of native structure */ + socklen_t var_el_size; /* size of repeatable component */ + calculate_req_space *calc_space; from_zval_write_field *from_array; to_zval_read_field *to_array; } ancillary_reg_entry; @@ -218,6 +223,33 @@ static void err_msg_dispose(struct err_s *err TSRMLS_DC) } } +static unsigned from_array_iterate(const zval *arr, + void (*func)(zval **elem, unsigned i, void **args, ser_context *ctx), + void **args, + ser_context *ctx) +{ + HashPosition pos; + unsigned i; + zval **elem; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + + for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 1; + !ctx->err.has_error + && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; + zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos), i++) { + if (snprintf(buf, sizeof(buf), "element #%u", i) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + func(elem, i, args, ctx); + + zend_llist_remove_tail(&ctx->keys); + } + + return i -1; +} /* Generic Aggregated conversions */ static void from_zval_write_aggregation(const zval *container, @@ -436,6 +468,53 @@ static void from_zval_write_sa_family(const zval *arr_value, char *field, ser_co ival = (sa_family_t)lval; memcpy(field, &ival, sizeof(ival)); } +static void from_zval_write_pid_t(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + pid_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || (pid_t)lval != lval) { /* pid_t is signed */ + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a pid_t value"); + return; + } + + ival = (pid_t)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_uid_t(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uid_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + /* uid_t can be signed or unsigned (generally unsigned) */ + if ((uid_t)-1 > (uid_t)0) { + if (sizeof(long) > sizeof(uid_t) && (lval < 0 || (uid_t)lval != lval)) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a uid_t value"); + return; + } + } else { + if (sizeof(long) > sizeof(uid_t) && (uid_t)lval != lval) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a uid_t value"); + return; + } + } + + ival = (uid_t)lval; + memcpy(field, &ival, sizeof(ival)); +} static void to_zval_read_int(const char *data, zval *zv, res_context *ctx) { @@ -472,6 +551,20 @@ static void to_zval_read_sa_family(const char *data, zval *zv, res_context *ctx) ZVAL_LONG(zv, (long)ival); } +static void to_zval_read_pid_t(const char *data, zval *zv, res_context *ctx) +{ + pid_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_uid_t(const char *data, zval *zv, res_context *ctx) +{ + uid_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} /* CONVERSIONS for sockaddr */ static void from_zval_write_sin_addr(const zval *zaddr_str, char *inaddr, ser_context *ctx) @@ -589,6 +682,53 @@ static void to_zval_read_sockaddr_in6(const char *data, zval *zv, res_context *c { to_zval_read_aggregation(data, zv, descriptors_sockaddr_in6, ctx); } +static void from_zval_write_sun_path(const zval *path, char *sockaddr_un_c, ser_context *ctx) +{ + zval lzval = zval_used_for_init; + struct sockaddr_un *saddr = (struct sockaddr_un*)sockaddr_un_c; + + if (Z_TYPE_P(path) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, path); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + path = &lzval; + } + + if (Z_STRLEN_P(path) >= sizeof(saddr->sun_path)) { + do_from_zval_err(ctx, "the path is too long, the maximum permitted " + "length is %ld", sizeof(saddr->sun_path) - 1); + return; + } + + memcpy(&saddr->sun_path, Z_STRVAL_P(path), Z_STRLEN_P(path)); + saddr->sun_path[Z_STRLEN_P(path)] = '\0'; + + zval_dtor(&lzval); +} +static void to_zval_read_sun_path(const char *data, zval *zv, res_context *ctx) { + struct sockaddr_un *saddr = (struct sockaddr_un*)data; + char *nul_pos; + + nul_pos = memchr(&saddr->sun_path, '\0', sizeof(saddr->sun_path)); + if (nul_pos == NULL) { + do_to_zval_err(ctx, "could not find a NUL in the path"); + return; + } + + ZVAL_STRINGL(zv, saddr->sun_path, nul_pos - (char*)&saddr->sun_path, 1); +} +static const field_descriptor descriptors_sockaddr_un[] = { + {"family", sizeof("family"), 0, offsetof(struct sockaddr_un, sun_family), from_zval_write_sa_family, to_zval_read_sa_family}, + {"path", sizeof("path"), 0, offsetof(struct sockaddr_un, sun_path), from_zval_write_sun_path, to_zval_read_sun_path}, +}; +static void from_zval_write_sockaddr_un(const zval *container, char *sockaddr, ser_context *ctx) +{ + from_zval_write_aggregation(container, sockaddr, descriptors_sockaddr_un, ctx); +} +static void to_zval_read_sockaddr_un(const char *data, zval *zv, res_context *ctx) +{ + to_zval_read_aggregation(data, zv, descriptors_sockaddr_un, ctx); +} static void from_zval_write_sockaddr_aux(const zval *container, struct sockaddr **sockaddr_ptr, socklen_t *sockaddr_len, @@ -630,6 +770,7 @@ static void from_zval_write_sockaddr_aux(const zval *container, (*sockaddr_ptr)->sa_family = AF_INET; } break; + case AF_INET6: if (ctx->sock->type != AF_INET6) { do_from_zval_err(ctx, "the specified family (AF_INET6) is not " @@ -643,9 +784,24 @@ static void from_zval_write_sockaddr_aux(const zval *container, (*sockaddr_ptr)->sa_family = AF_INET6; } break; + + case AF_UNIX: + if (ctx->sock->type != AF_UNIX) { + do_from_zval_err(ctx, "the specified family (AF_UNIX) is not " + "supported on this socket"); + return; + } + *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_un), ctx); + *sockaddr_len = sizeof(struct sockaddr_un); + if (fill_sockaddr) { + from_zval_write_sockaddr_un(container, (char*)*sockaddr_ptr, ctx); + (*sockaddr_ptr)->sa_family = AF_UNIX; + } + break; + default: do_from_zval_err(ctx, "%s", "the only families currently supported are " - "AF_INET and AF_INET6"); + "AF_INET, AF_INET6 and AF_UNIX"); break; } } @@ -653,7 +809,12 @@ static void to_zval_read_sockaddr_aux(const char *sockaddr_c, zval *zv, res_cont { const struct sockaddr *saddr = (struct sockaddr *)sockaddr_c; - assert(Z_TYPE_P(zv) == IS_ARRAY); + if (saddr->sa_family == 0) { + ZVAL_NULL(zv); + return; + } + + array_init(zv); switch (saddr->sa_family) { case AF_INET: @@ -664,6 +825,10 @@ static void to_zval_read_sockaddr_aux(const char *sockaddr_c, zval *zv, res_cont to_zval_read_sockaddr_in6(sockaddr_c, zv, ctx); break; + case AF_UNIX: + to_zval_read_sockaddr_un(sockaddr_c, zv, ctx); + break; + default: do_to_zval_err(ctx, "cannot read struct sockaddr with family %d; " "not supported", @@ -725,7 +890,14 @@ static void from_zval_write_control(const zval *arr, return; } - req_space = CMSG_SPACE(entry->size); + if (entry->calc_space) { + entry->calc_space(arr, ctx); + if (ctx->err.has_error) { + return; + } + } else { + req_space = CMSG_SPACE(entry->size); + } space_left = *control_len - *offset; assert(*control_len >= *offset); @@ -796,8 +968,10 @@ static void from_zval_write_control_array(const zval *arr, char *msghdr_c, ser_c } static void to_zval_read_cmsg_data(const char *cmsghdr_c, zval *zv, res_context *ctx) { - const struct cmsghdr *cmsg = (const struct cmsghdr *)cmsghdr_c; - ancillary_reg_entry *entry; + const struct cmsghdr *cmsg = (const struct cmsghdr *)cmsghdr_c; + ancillary_reg_entry *entry; + size_t len, + *len_p = &len; entry = get_ancillary_reg_entry(cmsg->cmsg_level, cmsg->cmsg_type); if (entry == NULL) { @@ -812,7 +986,16 @@ static void to_zval_read_cmsg_data(const char *cmsghdr_c, zval *zv, res_context return; } + len = (size_t)cmsg->cmsg_len; /* use another var because type of cmsg_len varies */ + if (zend_hash_add(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN), + &len_p, sizeof(len_p), NULL) == FAILURE) { + do_to_zval_err(ctx, "%s", "could not set parameter " KEY_CMSG_LEN); + return; + } + entry->to_array((const char *)CMSG_DATA(cmsg), zv, ctx); + + zend_hash_del(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN)); } static void to_zval_read_control(const char *cmsghdr_c, zval *zv, res_context *ctx) { @@ -881,7 +1064,6 @@ static void to_zval_read_name(const char *sockaddr_p, zval *zv, res_context *ctx if (name == NULL) { ZVAL_NULL(zv); } else { - array_init(zv); to_zval_read_sockaddr_aux(name, zv, ctx); } } @@ -906,15 +1088,25 @@ static void from_zval_write_msghdr_buffer_size(const zval *elem, char *msghdr_c, msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)lval, ctx); msghdr->msg_iov[0].iov_len = (size_t)lval; } +static void from_zval_write_iov_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) +{ + struct msghdr *msg = args[0]; + size_t len; + + zval_add_ref(elem); + convert_to_string_ex(elem); + + len = Z_STRLEN_PP(elem); + msg->msg_iov[i - 1].iov_base = accounted_emalloc(len, ctx); + msg->msg_iov[i - 1].iov_len = len; + memcpy(msg->msg_iov[i - 1].iov_base, Z_STRVAL_PP(elem), len); + + zval_ptr_dtor(elem); +} static void from_zval_write_iov_array(const zval *arr, char *msghdr_c, ser_context *ctx) { - HashPosition pos; int num_elem; - zval **elem; - unsigned i; struct msghdr *msg = (struct msghdr*)msghdr_c; - char buf[sizeof("element #4294967295")]; - char *bufp = buf; if (Z_TYPE_P(arr) != IS_ARRAY) { do_from_zval_err(ctx, "%s", "expected an array here"); @@ -929,30 +1121,7 @@ static void from_zval_write_iov_array(const zval *arr, char *msghdr_c, ser_conte msg->msg_iov = accounted_safe_ecalloc(num_elem, sizeof *msg->msg_iov, 0, ctx); msg->msg_iovlen = (size_t)num_elem; - for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 0; - !ctx->err.has_error - && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; - zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos)) { - size_t len; - - if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { - memcpy(buf, "element", sizeof("element")); - } - zend_llist_add_element(&ctx->keys, &bufp); - - zval_add_ref(elem); - convert_to_string_ex(elem); - - len = Z_STRLEN_PP(elem); - msg->msg_iov[i - 1].iov_base = accounted_emalloc(len, ctx); - msg->msg_iov[i - 1].iov_len = len; - memcpy(msg->msg_iov[i - 1].iov_base, Z_STRVAL_PP(elem), len); - - zval_ptr_dtor(elem); - - zend_llist_remove_tail(&ctx->keys); - } - + from_array_iterate(arr, from_zval_write_iov_array_aux, (void**)&msg, ctx); } static void from_zval_write_controllen(const zval *elem, char *msghdr_c, ser_context *ctx) { @@ -1096,6 +1265,118 @@ static void to_zval_read_in6_pktinfo(const char *data, zval *zv, res_context *ct to_zval_read_aggregation(data, zv, descriptors_in6_pktinfo, ctx); } +/* CONVERSIONS for struct ucred */ +static const field_descriptor descriptors_ucred[] = { + {"pid", sizeof("pid"), 1, offsetof(struct ucred, pid), from_zval_write_pid_t, to_zval_read_pid_t}, + {"uid", sizeof("uid"), 1, offsetof(struct ucred, uid), from_zval_write_uid_t, to_zval_read_uid_t}, + /* assume the type gid_t is the same as uid_t: */ + {"gid", sizeof("gid"), 1, offsetof(struct ucred, gid), from_zval_write_uid_t, to_zval_read_uid_t}, + {0} +}; +static void from_zval_write_ucred(const zval *container, char *ucred_c, ser_context *ctx) +{ + from_zval_write_aggregation(container, ucred_c, descriptors_ucred, ctx); +} +static void to_zval_read_ucred(const char *data, zval *zv, res_context *ctx) +{ + array_init_size(zv, 3); + + to_zval_read_aggregation(data, zv, descriptors_ucred, ctx); +} + +/* CONVERSIONS for SCM_RIGHTS */ +static size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx) +{ + int num_elems; + + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return (size_t)-1; + } + + num_elems = zend_hash_num_elements(Z_ARRVAL_P(arr)); + if (num_elems == 0) { + do_from_zval_err(ctx, "%s", "expected at least one element in this array"); + return (size_t)-1; + } + + return zend_hash_num_elements(Z_ARRVAL_P(arr)) * sizeof(int); +} +static void from_zval_write_int_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) +{ + int *iarr = args[0]; + + if (Z_TYPE_PP(elem) == IS_LONG) { + + from_zval_write_int(*elem, (char*)&iarr[i], ctx); + + } else if (Z_TYPE_PP(elem) == IS_RESOURCE) { + php_stream *stream; + php_socket *sock; + + ZEND_FETCH_RESOURCE_NO_RETURN(sock, php_socket *, elem, -1, + php_sockets_le_socket_name, php_sockets_le_socket()); + if (sock) { + iarr[i] = sock->bsd_socket; + return; + } + + ZEND_FETCH_RESOURCE2_NO_RETURN(stream, php_stream *, elem, -1, + "stream", php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + do_from_zval_err(ctx, "resource is not a stream or a socket"); + return; + } + + if (php_stream_cast(stream, PHP_STREAM_AS_FD, (void **)&iarr[i], + REPORT_ERRORS) == FAILURE) { + do_from_zval_err(ctx, "cast stream to file descriptor failed"); + return; + } + } else { + do_from_zval_err(ctx, "expected an integer or resource variable"); + } +} +static void from_zval_write_int_array(const zval *arr, char *int_arr, ser_context *ctx) +{ + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + from_array_iterate(arr, &from_zval_write_int_array_aux, (void**)&int_arr, ctx); +} +static void to_zval_read_int_array(const char *data, zval *zv, res_context *ctx) +{ + size_t **cmsg_len; + int num_elems, + i; + struct cmsghdr *dummy_cmsg = 0; + size_t data_offset; + + data_offset = (unsigned char *)CMSG_DATA(dummy_cmsg) + - (unsigned char *)dummy_cmsg; + + if (zend_hash_find(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN), + (void **)&cmsg_len) == FAILURE) { + do_to_zval_err(ctx, "could not get value of parameter " KEY_CMSG_LEN); + return; + } + + if (**cmsg_len < data_offset) { + do_to_zval_err(ctx, "length of cmsg is smaller than its data member " + "offset (%ld vs %ld)", (long)**cmsg_len, (long)data_offset); + return; + } + num_elems = (**cmsg_len - data_offset) / sizeof(int); + + array_init_size(zv, num_elems); + + for (i = 0; i < num_elems; i++) { + add_next_index_long(zv, (long)*((int *)data + i)); + } +} + /* ENTRY POINT for conversions */ static void free_from_zval_allocation(void *alloc_ptr_ptr) { @@ -1196,31 +1477,31 @@ static void init_ancillary_registry(void) zend_hash_init(&ancillary_registry.ht, 32, NULL, NULL, 1); -#define PUT_ENTRY() \ +#define PUT_ENTRY(sizev, var_size, calc, from, to, level, type) \ + entry.size = sizev; \ + entry.var_el_size = var_size; \ + entry.calc_space = calc; \ + entry.from_array = from; \ + entry.to_array = to; \ + key.cmsg_level = level; \ + key.cmsg_type = type; \ zend_hash_update(&ancillary_registry.ht, (char*)&key, sizeof(key), \ (void*)&entry, sizeof(entry), NULL) - entry.size = sizeof(struct in6_pktinfo); - entry.from_array = from_zval_write_in6_pktinfo; - entry.to_array = to_zval_read_in6_pktinfo; - key.cmsg_level = IPPROTO_IPV6; - key.cmsg_type = IPV6_PKTINFO; - PUT_ENTRY(); + PUT_ENTRY(sizeof(struct in6_pktinfo), 0, 0, from_zval_write_in6_pktinfo, + to_zval_read_in6_pktinfo, IPPROTO_IPV6, IPV6_PKTINFO); + + PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, + to_zval_read_int, IPPROTO_IPV6, IPV6_HOPLIMIT); - entry.size = sizeof(int); - entry.from_array = from_zval_write_int; - entry.to_array = to_zval_read_int; - key.cmsg_level = IPPROTO_IPV6; - key.cmsg_type = IPV6_HOPLIMIT; - PUT_ENTRY(); + PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, + to_zval_read_int, IPPROTO_IPV6, IPV6_TCLASS); - entry.size = sizeof(int); - entry.from_array = from_zval_write_int; - entry.to_array = to_zval_read_int; - key.cmsg_level = IPPROTO_IPV6; - key.cmsg_type = IPV6_TCLASS; - PUT_ENTRY(); + PUT_ENTRY(sizeof(struct ucred), 0, 0, from_zval_write_ucred, + to_zval_read_ucred, SOL_SOCKET, SCM_CREDENTIALS); + PUT_ENTRY(0, sizeof(int), calculate_scm_rights_space, from_zval_write_int_array, + to_zval_read_int_array, SOL_SOCKET, SCM_RIGHTS); } static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) @@ -1361,15 +1642,24 @@ PHP_FUNCTION(socket_recvmsg) PHP_FUNCTION(socket_cmsg_space) { long level, - type; + type, + n = 0; ancillary_reg_entry *entry; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ll", &level, &type) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ll|l", + &level, &type, &n) == FAILURE) { return; } LONG_CHECK_VALID_INT(level); LONG_CHECK_VALID_INT(type); + LONG_CHECK_VALID_INT(n); + + if (n < 0) { + php_error_docref0(NULL TSRMLS_CC, E_WARNING, "The third argument " + "cannot be negative"); + return; + } entry = get_ancillary_reg_entry(level, type); if (entry == NULL) { @@ -1378,11 +1668,22 @@ PHP_FUNCTION(socket_cmsg_space) return; } - RETURN_LONG((long)CMSG_SPACE(entry->size)); + if (entry->var_el_size > 0 && n > (LONG_MAX - (long)entry->size - + (long)CMSG_SPACE(0) - 15L) / entry->var_el_size) { + /* the -15 is to account for any padding CMSG_SPACE may add after the data */ + php_error_docref0(NULL TSRMLS_CC, E_WARNING, "The value for the " + "third argument (%ld) is too large", n); + return; + } + + RETURN_LONG((long)CMSG_SPACE(entry->size + n * entry->size)); } void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) { + /* IPv6 ancillary data + * Note that support for sticky options via setsockopt() is not implemented + * yet (where special support is needed, i.e., the optval is not an int). */ REGISTER_LONG_CONSTANT("IPV6_RECVPKTINFO", IPV6_RECVPKTINFO, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_RECVHOPLIMIT", IPV6_RECVHOPLIMIT, CONST_CS | CONST_PERSISTENT); /* would require some effort: @@ -1401,6 +1702,11 @@ void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) */ REGISTER_LONG_CONSTANT("IPV6_TCLASS", IPV6_TCLASS, CONST_CS | CONST_PERSISTENT); + + REGISTER_LONG_CONSTANT("SCM_RIGHTS", SCM_RIGHTS, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("SCM_CREDENTIALS", SCM_CREDENTIALS, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("SO_PASSCRED", SO_PASSCRED, CONST_CS | CONST_PERSISTENT); + #ifdef ZTS ancillary_mutex = tsrm_mutex_alloc(); #endif From 7fc4671df985ab1cedcd9b03d7bd792cc1188758 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 11:40:24 +0100 Subject: [PATCH 2346/2394] Add test for CMSG_CREDENTIALS message --- ext/sockets/sendrecvmsg.c | 60 ++++++++----- .../tests/socket_cmsg_credentials.phpt | 89 +++++++++++++++++++ 2 files changed, 128 insertions(+), 21 deletions(-) create mode 100644 ext/sockets/tests/socket_cmsg_credentials.phpt diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index f6a71dbefc7ef..385c2322336af 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -719,7 +719,8 @@ static void to_zval_read_sun_path(const char *data, zval *zv, res_context *ctx) } static const field_descriptor descriptors_sockaddr_un[] = { {"family", sizeof("family"), 0, offsetof(struct sockaddr_un, sun_family), from_zval_write_sa_family, to_zval_read_sa_family}, - {"path", sizeof("path"), 0, offsetof(struct sockaddr_un, sun_path), from_zval_write_sun_path, to_zval_read_sun_path}, + {"path", sizeof("path"), 0, 0, from_zval_write_sun_path, to_zval_read_sun_path}, + {0} }; static void from_zval_write_sockaddr_un(const zval *container, char *sockaddr, ser_context *ctx) { @@ -857,7 +858,8 @@ static void from_zval_write_control(const zval *arr, struct cmsghdr *cmsghdr; int level, type; - size_t req_space, + size_t data_len, + req_space, space_left; ancillary_reg_entry *entry; @@ -891,13 +893,14 @@ static void from_zval_write_control(const zval *arr, } if (entry->calc_space) { - entry->calc_space(arr, ctx); + data_len = entry->calc_space(arr, ctx); if (ctx->err.has_error) { return; } } else { - req_space = CMSG_SPACE(entry->size); + data_len = entry->size; } + req_space = CMSG_SPACE(data_len); space_left = *control_len - *offset; assert(*control_len >= *offset); @@ -910,7 +913,7 @@ static void from_zval_write_control(const zval *arr, cmsghdr = (struct cmsghdr*)(((char*)*control_buf) + *offset); cmsghdr->cmsg_level = level; cmsghdr->cmsg_type = type; - cmsghdr->cmsg_len = CMSG_LEN(entry->size); + cmsghdr->cmsg_len = CMSG_LEN(data_len); descriptor_data[0].from_zval = entry->from_array; from_zval_write_aggregation(arr, (char*)CMSG_DATA(cmsghdr), descriptor_data, ctx); @@ -1302,27 +1305,23 @@ static size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx) return zend_hash_num_elements(Z_ARRVAL_P(arr)) * sizeof(int); } -static void from_zval_write_int_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) +static void from_zval_write_fd_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) { int *iarr = args[0]; - if (Z_TYPE_PP(elem) == IS_LONG) { - - from_zval_write_int(*elem, (char*)&iarr[i], ctx); - - } else if (Z_TYPE_PP(elem) == IS_RESOURCE) { + if (Z_TYPE_PP(elem) == IS_RESOURCE) { php_stream *stream; php_socket *sock; ZEND_FETCH_RESOURCE_NO_RETURN(sock, php_socket *, elem, -1, - php_sockets_le_socket_name, php_sockets_le_socket()); + NULL, php_sockets_le_socket()); if (sock) { iarr[i] = sock->bsd_socket; return; } ZEND_FETCH_RESOURCE2_NO_RETURN(stream, php_stream *, elem, -1, - "stream", php_file_le_stream(), php_file_le_pstream()); + NULL, php_file_le_stream(), php_file_le_pstream()); if (stream == NULL) { do_from_zval_err(ctx, "resource is not a stream or a socket"); return; @@ -1334,25 +1333,26 @@ static void from_zval_write_int_array_aux(zval **elem, unsigned i, void **args, return; } } else { - do_from_zval_err(ctx, "expected an integer or resource variable"); + do_from_zval_err(ctx, "expected a resource variable"); } } -static void from_zval_write_int_array(const zval *arr, char *int_arr, ser_context *ctx) +static void from_zval_write_fd_array(const zval *arr, char *int_arr, ser_context *ctx) { if (Z_TYPE_P(arr) != IS_ARRAY) { do_from_zval_err(ctx, "%s", "expected an array here"); return; } - from_array_iterate(arr, &from_zval_write_int_array_aux, (void**)&int_arr, ctx); + from_array_iterate(arr, &from_zval_write_fd_array_aux, (void**)&int_arr, ctx); } -static void to_zval_read_int_array(const char *data, zval *zv, res_context *ctx) +static void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx) { size_t **cmsg_len; int num_elems, i; struct cmsghdr *dummy_cmsg = 0; size_t data_offset; + TSRMLS_FETCH(); data_offset = (unsigned char *)CMSG_DATA(dummy_cmsg) - (unsigned char *)dummy_cmsg; @@ -1373,7 +1373,25 @@ static void to_zval_read_int_array(const char *data, zval *zv, res_context *ctx) array_init_size(zv, num_elems); for (i = 0; i < num_elems; i++) { - add_next_index_long(zv, (long)*((int *)data + i)); + zval *elem; + int fd; + struct stat statbuf; + + MAKE_STD_ZVAL(elem); + + fd = *((int *)data + i); + + /* determine whether we have a socket */ + fstat(fd, &statbuf); + if (S_ISSOCK(statbuf.st_mode)) { + php_socket *sock = socket_import_file_descriptor(fd); + zend_register_resource(elem, sock, php_sockets_le_socket()); + } else { + php_stream *stream = php_stream_fopen_from_fd(fd, "rw", NULL); + php_stream_to_zval(stream, elem); + } + + add_next_index_zval(zv, elem); } } @@ -1500,8 +1518,8 @@ static void init_ancillary_registry(void) PUT_ENTRY(sizeof(struct ucred), 0, 0, from_zval_write_ucred, to_zval_read_ucred, SOL_SOCKET, SCM_CREDENTIALS); - PUT_ENTRY(0, sizeof(int), calculate_scm_rights_space, from_zval_write_int_array, - to_zval_read_int_array, SOL_SOCKET, SCM_RIGHTS); + PUT_ENTRY(0, sizeof(int), calculate_scm_rights_space, from_zval_write_fd_array, + to_zval_read_fd_array, SOL_SOCKET, SCM_RIGHTS); } static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) @@ -1676,7 +1694,7 @@ PHP_FUNCTION(socket_cmsg_space) return; } - RETURN_LONG((long)CMSG_SPACE(entry->size + n * entry->size)); + RETURN_LONG((long)CMSG_SPACE(entry->size + n * entry->var_el_size)); } void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) diff --git a/ext/sockets/tests/socket_cmsg_credentials.phpt b/ext/sockets/tests/socket_cmsg_credentials.phpt new file mode 100644 index 0000000000000..6a1c23fa8c56f --- /dev/null +++ b/ext/sockets/tests/socket_cmsg_credentials.phpt @@ -0,0 +1,89 @@ +--TEST-- +recvmsg(): receive SCM_CREDENTIALS messages +--SKIPIF-- + ["test ", "thing", "\n"], +//], 0); +$r = socket_sendto($sends1, $msg = "dread", strlen($msg), 0, $path); +var_dump($r); +checktimeout($s, 500); + +$data = [ + "name" => [], + "buffer_size" => 2000, + "controllen" => socket_cmsg_space(SOL_SOCKET, SCM_CREDENTIALS) +]; +if (!socket_recvmsg($s, $data, 0)) die("recvmsg"); +print_r($data); + +$pid = getmypid(); +var_dump($data['control'][0]['data']['pid'] === $pid); + +--EXPECTF-- +creating send socket +resource(%d) of type (Socket) +creating receive socket +resource(%d) of type (Socket) +bool(true) +int(5) +Array +( + [name] => + [control] => Array + ( + [0] => Array + ( + [level] => %d + [type] => %d + [data] => Array + ( + [pid] => %d + [uid] => %d + [gid] => %d + ) + + ) + + ) + + [iov] => Array + ( + [0] => dread + ) + + [flags] => 0 +) +bool(true) From 74cf40c2fdccdfaed419482d080be4f73fb23a7e Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 15:15:36 +0100 Subject: [PATCH 2347/2394] Add test for CMSG_RIGHTS --- ext/sockets/tests/socket_cmsg_rights.phpt | 100 ++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 ext/sockets/tests/socket_cmsg_rights.phpt diff --git a/ext/sockets/tests/socket_cmsg_rights.phpt b/ext/sockets/tests/socket_cmsg_rights.phpt new file mode 100644 index 0000000000000..8290f03880c4b --- /dev/null +++ b/ext/sockets/tests/socket_cmsg_rights.phpt @@ -0,0 +1,100 @@ +--TEST-- +recvmsg(): receive SCM_CREDENTIALS messages +--SKIPIF-- + [ "path" => $path ], + "iov" => ["test ", "thing", "\n"], + "control" => [ + [ + "level" => SOL_SOCKET, + "type" => SCM_RIGHTS, + "data" => [$sends1, STDIN, STDOUT, STDERR], + ] + ] +], 0); +var_dump($r); +checktimeout($s, 500); + +$data = [ + "name" => [], + "buffer_size" => 2000, + "controllen" => socket_cmsg_space(SOL_SOCKET, SCM_RIGHTS, 3) +]; +var_dump($data); +if (!socket_recvmsg($s, $data, 0)) die("recvmsg"); +print_r($data); +--EXPECTF-- +creating send socket +resource(%d) of type (Socket) +creating receive socket +resource(%d) of type (Socket) +bool(true) +int(11) +array(3) { + ["name"]=> + array(0) { + } + ["buffer_size"]=> + int(2000) + ["controllen"]=> + int(32) +} +Array +( + [name] => + [control] => Array + ( + [0] => Array + ( + [level] => %d + [type] => %d + [data] => Array + ( + [0] => Resource id #%d + [1] => Resource id #%d + [2] => Resource id #%d + ) + + ) + + ) + + [iov] => Array + ( + [0] => test thing + + ) + + [flags] => 0 +) From 51e65667f5dcb60af24603a543946aa258ac9003 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 16:12:21 +0100 Subject: [PATCH 2348/2394] Register extra MSG_* constants --- ext/sockets/sockets.c | 31 +++++++++++++++++++++++++------ 1 file changed, 25 insertions(+), 6 deletions(-) diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 449be8f9373b6..37e2e9fe98a83 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -718,19 +718,38 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("SOCK_RAW", SOCK_RAW, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SOCK_SEQPACKET",SOCK_SEQPACKET, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SOCK_RDM", SOCK_RDM, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MSG_OOB", MSG_OOB, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MSG_WAITALL", MSG_WAITALL, CONST_CS | CONST_PERSISTENT); -#ifdef MSG_DONTWAIT - REGISTER_LONG_CONSTANT("MSG_DONTWAIT", MSG_DONTWAIT, CONST_CS | CONST_PERSISTENT); -#endif + REGISTER_LONG_CONSTANT("MSG_CTRUNC", MSG_CTRUNC, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MSG_TRUNC", MSG_TRUNC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MSG_PEEK", MSG_PEEK, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MSG_DONTROUTE", MSG_DONTROUTE, CONST_CS | CONST_PERSISTENT); -#ifdef MSG_EOR REGISTER_LONG_CONSTANT("MSG_EOR", MSG_EOR, CONST_CS | CONST_PERSISTENT); -#endif -#ifdef MSG_EOF REGISTER_LONG_CONSTANT("MSG_EOF", MSG_EOF, CONST_CS | CONST_PERSISTENT); + +#ifdef MSG_CONFIRM + REGISTER_LONG_CONSTANT("MSG_CONFIRM", MSG_CONFIRM, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef MSG_ERRQUEUE + REGISTER_LONG_CONSTANT("MSG_ERRQUEUE", MSG_ERRQUEUE, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef MSG_NOSIGNAL + REGISTER_LONG_CONSTANT("MSG_NOSIGNAL", MSG_NOSIGNAL, CONST_CS | CONST_PERSISTENT); #endif +#ifdef MSG_DONTWAIT + REGISTER_LONG_CONSTANT("MSG_DONTWAIT", MSG_DONTWAIT, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef MSG_MORE + REGISTER_LONG_CONSTANT("MSG_MORE", MSG_MORE, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef MSG_WAITFORONE + REGISTER_LONG_CONSTANT("MSG_WAITFORONE",MSG_WAITFORONE, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef MSG_CMSG_CLOEXEC + REGISTER_LONG_CONSTANT("MSG_CMSG_CLOEXEC",MSG_CMSG_CLOEXEC,CONST_CS | CONST_PERSISTENT); +#endif + REGISTER_LONG_CONSTANT("SO_DEBUG", SO_DEBUG, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SO_REUSEADDR", SO_REUSEADDR, CONST_CS | CONST_PERSISTENT); #ifdef SO_REUSEPORT From 190a0ed71377519425f1b33ef3b21f41064e416b Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 17:10:10 +0100 Subject: [PATCH 2349/2394] Fix build on Mac OS X By deactivating unsupported features on this OS. --- ext/sockets/sendrecvmsg.c | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 385c2322336af..4436d18e84105 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -1252,6 +1252,7 @@ static void to_zval_read_msghdr(const char *msghdr_c, zval *zv, res_context *ctx /* CONVERSIONS for struct in6_pktinfo */ +#ifdef IPV6_PKTINFO static const field_descriptor descriptors_in6_pktinfo[] = { {"addr", sizeof("addr"), 1, offsetof(struct in6_pktinfo, ipi6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, {"ifindex", sizeof("ifindex"), 1, offsetof(struct in6_pktinfo, ipi6_ifindex), from_zval_write_unsigned, to_zval_read_unsigned}, @@ -1267,8 +1268,10 @@ static void to_zval_read_in6_pktinfo(const char *data, zval *zv, res_context *ct to_zval_read_aggregation(data, zv, descriptors_in6_pktinfo, ctx); } +#endif /* CONVERSIONS for struct ucred */ +#ifdef SO_PASSCRED static const field_descriptor descriptors_ucred[] = { {"pid", sizeof("pid"), 1, offsetof(struct ucred, pid), from_zval_write_pid_t, to_zval_read_pid_t}, {"uid", sizeof("uid"), 1, offsetof(struct ucred, uid), from_zval_write_uid_t, to_zval_read_uid_t}, @@ -1286,8 +1289,10 @@ static void to_zval_read_ucred(const char *data, zval *zv, res_context *ctx) to_zval_read_aggregation(data, zv, descriptors_ucred, ctx); } +#endif /* CONVERSIONS for SCM_RIGHTS */ +#ifdef SCM_RIGHTS static size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx) { int num_elems; @@ -1394,6 +1399,7 @@ static void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx) add_next_index_zval(zv, elem); } } +#endif /* ENTRY POINT for conversions */ static void free_from_zval_allocation(void *alloc_ptr_ptr) @@ -1506,20 +1512,28 @@ static void init_ancillary_registry(void) zend_hash_update(&ancillary_registry.ht, (char*)&key, sizeof(key), \ (void*)&entry, sizeof(entry), NULL) +#ifdef IPV6_PKTINFO PUT_ENTRY(sizeof(struct in6_pktinfo), 0, 0, from_zval_write_in6_pktinfo, to_zval_read_in6_pktinfo, IPPROTO_IPV6, IPV6_PKTINFO); +#endif +#ifdef IPV6_HOPLIMIT PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, to_zval_read_int, IPPROTO_IPV6, IPV6_HOPLIMIT); +#endif PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, to_zval_read_int, IPPROTO_IPV6, IPV6_TCLASS); +#ifdef SO_PASSCRED PUT_ENTRY(sizeof(struct ucred), 0, 0, from_zval_write_ucred, to_zval_read_ucred, SOL_SOCKET, SCM_CREDENTIALS); +#endif +#ifdef SCM_RIGHTS PUT_ENTRY(0, sizeof(int), calculate_scm_rights_space, from_zval_write_fd_array, to_zval_read_fd_array, SOL_SOCKET, SCM_RIGHTS); +#endif } static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) @@ -1702,8 +1716,14 @@ void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) /* IPv6 ancillary data * Note that support for sticky options via setsockopt() is not implemented * yet (where special support is needed, i.e., the optval is not an int). */ +#ifdef IPV6_RECVPKTINFO REGISTER_LONG_CONSTANT("IPV6_RECVPKTINFO", IPV6_RECVPKTINFO, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_PKTINFO", IPV6_PKTINFO, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef IPV6_RECVHOPLIMIT REGISTER_LONG_CONSTANT("IPV6_RECVHOPLIMIT", IPV6_RECVHOPLIMIT, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_HOPLIMIT", IPV6_HOPLIMIT, CONST_CS | CONST_PERSISTENT); +#endif /* would require some effort: REGISTER_LONG_CONSTANT("IPV6_RECVRTHDR", IPV6_RECVRTHDR, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_RECVHOPOPTS", IPV6_RECVHOPOPTS, CONST_CS | CONST_PERSISTENT); @@ -1711,8 +1731,6 @@ void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) */ REGISTER_LONG_CONSTANT("IPV6_RECVTCLASS", IPV6_RECVTCLASS, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("IPV6_PKTINFO", IPV6_PKTINFO, CONST_CS | CONST_PERSISTENT); - REGISTER_LONG_CONSTANT("IPV6_HOPLIMIT", IPV6_HOPLIMIT, CONST_CS | CONST_PERSISTENT); /* REGISTER_LONG_CONSTANT("IPV6_RTHDR", IPV6_RTHDR, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_HOPOPTS", IPV6_HOPOPTS, CONST_CS | CONST_PERSISTENT); @@ -1720,10 +1738,13 @@ void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) */ REGISTER_LONG_CONSTANT("IPV6_TCLASS", IPV6_TCLASS, CONST_CS | CONST_PERSISTENT); - +#ifdef SCM_RIGHTS REGISTER_LONG_CONSTANT("SCM_RIGHTS", SCM_RIGHTS, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef SO_PASSCRED REGISTER_LONG_CONSTANT("SCM_CREDENTIALS", SCM_CREDENTIALS, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("SO_PASSCRED", SO_PASSCRED, CONST_CS | CONST_PERSISTENT); +#endif #ifdef ZTS ancillary_mutex = tsrm_mutex_alloc(); From 5bf7b08efd691780f421e0b4f176404fe3a80b2c Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 5 Nov 2012 17:35:46 +0100 Subject: [PATCH 2350/2394] Check return of fstat() --- ext/sockets/sendrecvmsg.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 4436d18e84105..16330e0ded0ec 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -1387,7 +1387,12 @@ static void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx) fd = *((int *)data + i); /* determine whether we have a socket */ - fstat(fd, &statbuf); + if (fstat(fd, &statbuf) == -1) { + do_to_zval_err(ctx, "error creating resource for received file " + "descriptor %d: fstat() call failed with errno %d", fd, errno); + efree(elem); + return; + } if (S_ISSOCK(statbuf.st_mode)) { php_socket *sock = socket_import_file_descriptor(fd); zend_register_resource(elem, sock, php_sockets_le_socket()); From 3e515a2fd93204594c80ad2379f42fbb2db18d78 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 6 Nov 2012 11:25:23 +0100 Subject: [PATCH 2351/2394] Fix mcast_ipv6_send test --- ext/sockets/tests/mcast_ipv6_send.phpt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/sockets/tests/mcast_ipv6_send.phpt b/ext/sockets/tests/mcast_ipv6_send.phpt index b8d38bf68f44e..f75bb09903cf9 100644 --- a/ext/sockets/tests/mcast_ipv6_send.phpt +++ b/ext/sockets/tests/mcast_ipv6_send.phpt @@ -9,8 +9,8 @@ if (!defined('IPPROTO_IPV6')) { die('skip IPv6 not available.'); } $level = IPPROTO_IPV6; -$s = socket_create($domain, SOCK_DGRAM, SOL_UDP) or die("skip Can not create socket"); -if (socket_set_option($s, $level, IP_MULTICAST_IF, 1) === false) { +$s = socket_create(AF_INET6, SOCK_DGRAM, SOL_UDP) or die("skip Can not create socket"); +if (socket_set_option($s, $level, IPV6_MULTICAST_IF, 1) === false) { die("skip interface 1 either doesn't exist or has no ipv6 address"); } --FILE-- From 51394f76a5fca718fbf218888d97402f845ee261 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 6 Nov 2012 12:48:47 +0100 Subject: [PATCH 2352/2394] Move some multicast stuff to multicast.c --- ext/sockets/multicast.c | 362 +++++++++++++++++++++++++++++++++++--- ext/sockets/multicast.h | 10 ++ ext/sockets/php_sockets.h | 6 + ext/sockets/sockets.c | 274 ++--------------------------- 4 files changed, 362 insertions(+), 290 deletions(-) diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index d4a00a8d174d8..dc242693acc3c 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -54,6 +54,7 @@ #include "php_sockets.h" #include "multicast.h" +#include "sockaddr_conv.h" #include "main/php_network.h" @@ -76,6 +77,309 @@ static const char *_php_source_op_to_string(enum source_op sop); static int _php_source_op_to_ipv4_op(enum source_op sop); #endif +static int php_get_if_index_from_zval(zval *val, unsigned *out TSRMLS_DC) +{ + int ret; + + if (Z_TYPE_P(val) == IS_LONG) { + if (Z_LVAL_P(val) < 0 || Z_LVAL_P(val) > UINT_MAX) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "the interface index cannot be negative or larger than %u;" + " given %ld", UINT_MAX, Z_LVAL_P(val)); + ret = FAILURE; + } else { + *out = Z_LVAL_P(val); + ret = SUCCESS; + } + } else { +#if HAVE_IF_NAMETOINDEX + unsigned int ind; + zval_add_ref(&val); + convert_to_string_ex(&val); + ind = if_nametoindex(Z_STRVAL_P(val)); + if (ind == 0) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "no interface with name \"%s\" could be found", Z_STRVAL_P(val)); + ret = FAILURE; + } else { + *out = ind; + ret = SUCCESS; + } + zval_ptr_dtor(&val); +#else + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "this platform does not support looking up an interface by " + "name, an integer interface index must be supplied instead"); + ret = FAILURE; +#endif + } + + return ret; +} + +static int php_get_if_index_from_array(const HashTable *ht, const char *key, + php_socket *sock, unsigned int *if_index TSRMLS_DC) +{ + zval **val; + + if (zend_hash_find(ht, key, strlen(key) + 1, (void **)&val) == FAILURE) { + *if_index = 0; /* default: 0 */ + return SUCCESS; + } + + return php_get_if_index_from_zval(*val, if_index TSRMLS_CC); +} + +static int php_get_address_from_array(const HashTable *ht, const char *key, + php_socket *sock, php_sockaddr_storage *ss, socklen_t *ss_len TSRMLS_DC) +{ + zval **val, + *valcp; + + if (zend_hash_find(ht, key, strlen(key) + 1, (void **)&val) == FAILURE) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "no key \"%s\" passed in optval", key); + return FAILURE; + } + valcp = *val; + zval_add_ref(&valcp); + convert_to_string_ex(val); + if (!php_set_inet46_addr(ss, ss_len, Z_STRVAL_P(valcp), sock TSRMLS_CC)) { + zval_ptr_dtor(&valcp); + return FAILURE; + } + zval_ptr_dtor(&valcp); + return SUCCESS; +} + +static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval **arg4 TSRMLS_DC) +{ + HashTable *opt_ht; + unsigned int if_index; + int retval; + int (*mcast_req_fun)(php_socket *, int, struct sockaddr *, socklen_t, + unsigned TSRMLS_DC); +#ifdef HAS_MCAST_EXT + int (*mcast_sreq_fun)(php_socket *, int, struct sockaddr *, socklen_t, + struct sockaddr *, socklen_t, unsigned TSRMLS_DC); +#endif + + switch (optname) { + case MCAST_JOIN_GROUP: + mcast_req_fun = &php_mcast_join; + goto mcast_req_fun; + case MCAST_LEAVE_GROUP: + { + php_sockaddr_storage group = {0}; + socklen_t glen; + + mcast_req_fun = &php_mcast_leave; +mcast_req_fun: + convert_to_array_ex(arg4); + opt_ht = HASH_OF(*arg4); + + if (php_get_address_from_array(opt_ht, "group", php_sock, &group, + &glen TSRMLS_CC) == FAILURE) { + return FAILURE; + } + if (php_get_if_index_from_array(opt_ht, "interface", php_sock, + &if_index TSRMLS_CC) == FAILURE) { + return FAILURE; + } + + retval = mcast_req_fun(php_sock, level, (struct sockaddr*)&group, + glen, if_index TSRMLS_CC); + break; + } + +#ifdef HAS_MCAST_EXT + case MCAST_BLOCK_SOURCE: + mcast_sreq_fun = &php_mcast_block_source; + goto mcast_sreq_fun; + case MCAST_UNBLOCK_SOURCE: + mcast_sreq_fun = &php_mcast_unblock_source; + goto mcast_sreq_fun; + case MCAST_JOIN_SOURCE_GROUP: + mcast_sreq_fun = &php_mcast_join_source; + goto mcast_sreq_fun; + case MCAST_LEAVE_SOURCE_GROUP: + { + php_sockaddr_storage group = {0}, + source = {0}; + socklen_t glen, + slen; + + mcast_sreq_fun = &php_mcast_leave_source; + mcast_sreq_fun: + convert_to_array_ex(arg4); + opt_ht = HASH_OF(*arg4); + + if (php_get_address_from_array(opt_ht, "group", php_sock, &group, + &glen TSRMLS_CC) == FAILURE) { + return FAILURE; + } + if (php_get_address_from_array(opt_ht, "source", php_sock, &source, + &slen TSRMLS_CC) == FAILURE) { + return FAILURE; + } + if (php_get_if_index_from_array(opt_ht, "interface", php_sock, + &if_index TSRMLS_CC) == FAILURE) { + return FAILURE; + } + + retval = mcast_sreq_fun(php_sock, level, (struct sockaddr*)&group, + glen, (struct sockaddr*)&source, slen, if_index TSRMLS_CC); + break; + } +#endif + default: + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "unexpected option in php_do_mcast_opt (level %d, option %d). " + "This is a bug.", level, optname); + return FAILURE; + } + + if (retval != 0) { + if (retval != -2) { /* error, but message already emitted */ + PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); + } + return FAILURE; + } + return SUCCESS; +} + +int php_do_setsockopt_ip_mcast(php_socket *php_sock, + int level, + int optname, + zval **arg4) +{ + unsigned int if_index; + struct in_addr if_addr; + void *opt_ptr; + socklen_t optlen; + unsigned char ipv4_mcast_ttl_lback; + int retval; + + switch (optname) { + case MCAST_JOIN_GROUP: + case MCAST_LEAVE_GROUP: +#ifdef HAS_MCAST_EXT + case MCAST_BLOCK_SOURCE: + case MCAST_UNBLOCK_SOURCE: + case MCAST_JOIN_SOURCE_GROUP: + case MCAST_LEAVE_SOURCE_GROUP: +#endif + if (php_do_mcast_opt(php_sock, level, optname, arg4 TSRMLS_CC) == FAILURE) { + return FAILURE; + } else { + return SUCCESS; + } + + case IP_MULTICAST_IF: + if (php_get_if_index_from_zval(*arg4, &if_index TSRMLS_CC) == FAILURE) { + return FAILURE; + } + + if (php_if_index_to_addr4(if_index, php_sock, &if_addr TSRMLS_CC) == FAILURE) { + return FAILURE; + } + opt_ptr = &if_addr; + optlen = sizeof(if_addr); + goto dosockopt; + + case IP_MULTICAST_LOOP: + convert_to_boolean_ex(arg4); + goto ipv4_loop_ttl; + + case IP_MULTICAST_TTL: + convert_to_long_ex(arg4); + if (Z_LVAL_PP(arg4) < 0L || Z_LVAL_PP(arg4) > 255L) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "Expected a value between 0 and 255"); + return FAILURE; + } +ipv4_loop_ttl: + ipv4_mcast_ttl_lback = (unsigned char) Z_LVAL_PP(arg4); + opt_ptr = &ipv4_mcast_ttl_lback; + optlen = sizeof(ipv4_mcast_ttl_lback); + goto dosockopt; + } + + return 1; + +dosockopt: + retval = setsockopt(php_sock->bsd_socket, level, optname, opt_ptr, optlen); + if (retval != 0) { + PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); + return FAILURE; + } + + return SUCCESS; +} + +int php_do_setsockopt_ipv6_mcast(php_socket *php_sock, + int level, + int optname, + zval **arg4) +{ + unsigned int if_index; + void *opt_ptr; + socklen_t optlen; + int ov; + int retval; + + switch (optname) { + case MCAST_JOIN_GROUP: + case MCAST_LEAVE_GROUP: +#ifdef HAS_MCAST_EXT + case MCAST_BLOCK_SOURCE: + case MCAST_UNBLOCK_SOURCE: + case MCAST_JOIN_SOURCE_GROUP: + case MCAST_LEAVE_SOURCE_GROUP: +#endif + if (php_do_mcast_opt(php_sock, level, optname, arg4 TSRMLS_CC) == FAILURE) { + return FAILURE; + } else { + return SUCCESS; + } + + case IPV6_MULTICAST_IF: + if (php_get_if_index_from_zval(*arg4, &if_index TSRMLS_CC) == FAILURE) { + return FAILURE; + } + + opt_ptr = &if_index; + optlen = sizeof(if_index); + goto dosockopt; + + case IPV6_MULTICAST_LOOP: + convert_to_boolean_ex(arg4); + goto ipv6_loop_hops; + case IPV6_MULTICAST_HOPS: + convert_to_long_ex(arg4); + if (Z_LVAL_PP(arg4) < -1L || Z_LVAL_PP(arg4) > 255L) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, + "Expected a value between -1 and 255"); + return FAILURE; + } +ipv6_loop_hops: + ov = (int) Z_LVAL_PP(arg4); + opt_ptr = &ov; + optlen = sizeof(ov); + goto dosockopt; + } + + return 1; /* not handled */ + +dosockopt: + retval = setsockopt(php_sock->bsd_socket, level, optname, opt_ptr, optlen); + if (retval != 0) { + PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); + return FAILURE; + } + + return SUCCESS; +} + int php_mcast_join( php_socket *sock, int level, @@ -157,21 +461,21 @@ static int _php_mcast_join_leave( { #ifdef RFC3678_API struct group_req greq = {0}; - + memcpy(&greq.gr_group, group, group_len); assert(greq.gr_group.ss_family != 0); /* the caller has set this */ greq.gr_interface = if_index; return setsockopt(sock->bsd_socket, level, join ? MCAST_JOIN_GROUP : MCAST_LEAVE_GROUP, (char*)&greq, - sizeof(greq)); + sizeof(greq)); #else if (sock->type == AF_INET) { struct ip_mreq mreq = {0}; struct in_addr addr; - + assert(group_len == sizeof(struct sockaddr_in)); - + if (if_index != 0) { if (php_if_index_to_addr4(if_index, sock, &addr TSRMLS_CC) == FAILURE) @@ -188,12 +492,12 @@ static int _php_mcast_join_leave( #if HAVE_IPV6 else if (sock->type == AF_INET6) { struct ipv6_mreq mreq = {0}; - + assert(group_len == sizeof(struct sockaddr_in6)); mreq.ipv6mr_multiaddr = ((struct sockaddr_in6*)group)->sin6_addr; mreq.ipv6mr_interface = if_index; - + return setsockopt(sock->bsd_socket, level, join ? IPV6_JOIN_GROUP : IPV6_LEAVE_GROUP, (char*)&mreq, sizeof(mreq)); @@ -221,26 +525,26 @@ static int _php_mcast_source_op( { #ifdef RFC3678_API struct group_source_req gsreq = {0}; - + memcpy(&gsreq.gsr_group, group, group_len); assert(gsreq.gsr_group.ss_family != 0); memcpy(&gsreq.gsr_source, source, source_len); assert(gsreq.gsr_source.ss_family != 0); gsreq.gsr_interface = if_index; - + return setsockopt(sock->bsd_socket, level, _php_source_op_to_rfc3678_op(sop), (char*)&gsreq, sizeof(gsreq)); #else if (sock->type == AF_INET) { struct ip_mreq_source mreqs = {0}; struct in_addr addr; - + mreqs.imr_multiaddr = ((struct sockaddr_in*)group)->sin_addr; mreqs.imr_sourceaddr = ((struct sockaddr_in*)source)->sin_addr; - + assert(group_len == sizeof(struct sockaddr_in)); assert(source_len == sizeof(struct sockaddr_in)); - + if (if_index != 0) { if (php_if_index_to_addr4(if_index, sock, &addr TSRMLS_CC) == FAILURE) @@ -249,7 +553,7 @@ static int _php_mcast_source_op( } else { mreqs.imr_interface.s_addr = htonl(INADDR_ANY); } - + return setsockopt(sock->bsd_socket, level, _php_source_op_to_ipv4_op(sop), (char*)&mreqs, sizeof(mreqs)); } @@ -283,7 +587,7 @@ static int _php_source_op_to_rfc3678_op(enum source_op sop) case UNBLOCK_SOURCE: return MCAST_UNBLOCK_SOURCE; } - + assert(0); return 0; } @@ -300,7 +604,7 @@ static const char *_php_source_op_to_string(enum source_op sop) case UNBLOCK_SOURCE: return "MCAST_UNBLOCK_SOURCE"; } - + assert(0); return ""; } @@ -317,7 +621,7 @@ static int _php_source_op_to_ipv4_op(enum source_op sop) case UNBLOCK_SOURCE: return IP_UNBLOCK_SOURCE; } - + assert(0); return 0; } @@ -416,16 +720,16 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i int php_if_index_to_addr4(unsigned if_index, php_socket *php_sock, struct in_addr *out_addr TSRMLS_DC) { struct ifreq if_req; - + if (if_index == 0) { out_addr->s_addr = INADDR_ANY; return SUCCESS; } - + #if !defined(ifr_ifindex) && defined(ifr_index) #define ifr_ifindex ifr_index #endif - + #if defined(SIOCGIFNAME) if_req.ifr_ifindex = if_index; if (ioctl(php_sock->bsd_socket, SIOCGIFNAME, &if_req) == -1) { @@ -438,13 +742,13 @@ int php_if_index_to_addr4(unsigned if_index, php_socket *php_sock, struct in_add "Failed obtaining address for interface %u: error %d", if_index, errno); return FAILURE; } - + if (ioctl(php_sock->bsd_socket, SIOCGIFADDR, &if_req) == -1) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed obtaining address for interface %u: error %d", if_index, errno); return FAILURE; } - + memcpy(out_addr, &((struct sockaddr_in *) &if_req.ifr_addr)->sin_addr, sizeof *out_addr); return SUCCESS; @@ -458,25 +762,25 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i int size = 0, lastsize = 0; size_t entry_len; - + if (addr->s_addr == INADDR_ANY) { *if_index = 0; return SUCCESS; } - + for(;;) { size += 5 * sizeof(struct ifreq); buf = ecalloc(size, 1); if_conf.ifc_len = size; if_conf.ifc_buf = buf; - + if (ioctl(php_sock->bsd_socket, SIOCGIFCONF, (char*)&if_conf) == -1 && (errno != EINVAL || lastsize != 0)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed obtaining interfaces list: error %d", errno); goto err; } - + if (if_conf.ifc_len == lastsize) /* not increasing anymore */ break; @@ -486,15 +790,15 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i buf = NULL; } } - + for (p = if_conf.ifc_buf; p < if_conf.ifc_buf + if_conf.ifc_len; p += entry_len) { struct ifreq *cur_req; - + /* let's hope the pointer is aligned */ cur_req = (struct ifreq*) p; - + #ifdef HAVE_SOCKADDR_SA_LEN entry_len = cur_req->ifr_addr.sa_len + sizeof(cur_req->ifr_name); #else @@ -502,7 +806,7 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i entry_len = sizeof(struct sockaddr) + sizeof(cur_req->ifr_name); #endif entry_len = MAX(entry_len, sizeof(*cur_req)); - + if ((((struct sockaddr*)&cur_req->ifr_addr)->sa_family == AF_INET) && (((struct sockaddr_in*)&cur_req->ifr_addr)->sin_addr.s_addr == addr->s_addr)) { @@ -537,7 +841,7 @@ int php_add4_to_if_index(struct in_addr *addr, php_socket *php_sock, unsigned *i php_error_docref(NULL TSRMLS_CC, E_WARNING, "The interface with IP address %s was not found", addr_str); } - + err: if (buf != NULL) efree(buf); diff --git a/ext/sockets/multicast.h b/ext/sockets/multicast.h index 498a71f67a125..c363b58472720 100644 --- a/ext/sockets/multicast.h +++ b/ext/sockets/multicast.h @@ -27,6 +27,16 @@ #define HAS_MCAST_EXT 1 #endif +int php_do_setsockopt_ip_mcast(php_socket *php_sock, + int level, + int optname, + zval **arg4); + +int php_do_setsockopt_ipv6_mcast(php_socket *php_sock, + int level, + int optname, + zval **arg4); + int php_if_index_to_addr4( unsigned if_index, php_socket *php_sock, diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 3138eb60c45c6..78da0c29e68f2 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -87,6 +87,12 @@ ZEND_END_MODULE_GLOBALS(sockets) ZEND_EXTERN_MODULE_GLOBALS(sockets); +enum sockopt_return { + SOCKOPT_ERROR, + SOCKOPT_CONTINUE, + SOCKOPT_SUCCESS +}; + char *sockets_strerror(int error TSRMLS_DC); php_socket *socket_import_file_descriptor(PHP_SOCKET sock TSRMLS_DC); diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 37e2e9fe98a83..9f11594425944 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -619,81 +619,6 @@ char *sockets_strerror(int error TSRMLS_DC) /* {{{ */ } /* }}} */ - -static int php_get_if_index_from_zval(zval *val, unsigned *out TSRMLS_DC) -{ - int ret; - - if (Z_TYPE_P(val) == IS_LONG) { - if (Z_LVAL_P(val) < 0 || Z_LVAL_P(val) > UINT_MAX) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "the interface index cannot be negative or larger than %u;" - " given %ld", UINT_MAX, Z_LVAL_P(val)); - ret = FAILURE; - } else { - *out = Z_LVAL_P(val); - ret = SUCCESS; - } - } else { -#if HAVE_IF_NAMETOINDEX - unsigned int ind; - zval_add_ref(&val); - convert_to_string_ex(&val); - ind = if_nametoindex(Z_STRVAL_P(val)); - if (ind == 0) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "no interface with name \"%s\" could be found", Z_STRVAL_P(val)); - ret = FAILURE; - } else { - *out = ind; - ret = SUCCESS; - } - zval_ptr_dtor(&val); -#else - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "this platform does not support looking up an interface by " - "name, an integer interface index must be supplied instead"); - ret = FAILURE; -#endif - } - - return ret; -} - -static int php_get_if_index_from_array(const HashTable *ht, const char *key, - php_socket *sock, unsigned int *if_index TSRMLS_DC) -{ - zval **val; - - if (zend_hash_find(ht, key, strlen(key) + 1, (void **)&val) == FAILURE) { - *if_index = 0; /* default: 0 */ - return SUCCESS; - } - - return php_get_if_index_from_zval(*val, if_index TSRMLS_CC); -} - -static int php_get_address_from_array(const HashTable *ht, const char *key, - php_socket *sock, php_sockaddr_storage *ss, socklen_t *ss_len TSRMLS_DC) -{ - zval **val, - *valcp; - - if (zend_hash_find(ht, key, strlen(key) + 1, (void **)&val) == FAILURE) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "no key \"%s\" passed in optval", key); - return FAILURE; - } - valcp = *val; - zval_add_ref(&valcp); - convert_to_string_ex(val); - if (!php_set_inet46_addr(ss, ss_len, Z_STRVAL_P(valcp), sock TSRMLS_CC)) { - zval_ptr_dtor(&valcp); - return FAILURE; - } - zval_ptr_dtor(&valcp); - return SUCCESS; -} - /* {{{ PHP_GINIT_FUNCTION */ static PHP_GINIT_FUNCTION(sockets) { @@ -2012,102 +1937,6 @@ PHP_FUNCTION(socket_get_option) } /* }}} */ -static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval **arg4 TSRMLS_DC) -{ - HashTable *opt_ht; - unsigned int if_index; - int retval; - int (*mcast_req_fun)(php_socket *, int, struct sockaddr *, socklen_t, - unsigned TSRMLS_DC); -#ifdef HAS_MCAST_EXT - int (*mcast_sreq_fun)(php_socket *, int, struct sockaddr *, socklen_t, - struct sockaddr *, socklen_t, unsigned TSRMLS_DC); -#endif - - switch (optname) { - case MCAST_JOIN_GROUP: - mcast_req_fun = &php_mcast_join; - goto mcast_req_fun; - case MCAST_LEAVE_GROUP: - { - php_sockaddr_storage group = {0}; - socklen_t glen; - - mcast_req_fun = &php_mcast_leave; -mcast_req_fun: - convert_to_array_ex(arg4); - opt_ht = HASH_OF(*arg4); - - if (php_get_address_from_array(opt_ht, "group", php_sock, &group, - &glen TSRMLS_CC) == FAILURE) { - return FAILURE; - } - if (php_get_if_index_from_array(opt_ht, "interface", php_sock, - &if_index TSRMLS_CC) == FAILURE) { - return FAILURE; - } - - retval = mcast_req_fun(php_sock, level, (struct sockaddr*)&group, - glen, if_index TSRMLS_CC); - break; - } - -#ifdef HAS_MCAST_EXT - case MCAST_BLOCK_SOURCE: - mcast_sreq_fun = &php_mcast_block_source; - goto mcast_sreq_fun; - case MCAST_UNBLOCK_SOURCE: - mcast_sreq_fun = &php_mcast_unblock_source; - goto mcast_sreq_fun; - case MCAST_JOIN_SOURCE_GROUP: - mcast_sreq_fun = &php_mcast_join_source; - goto mcast_sreq_fun; - case MCAST_LEAVE_SOURCE_GROUP: - { - php_sockaddr_storage group = {0}, - source = {0}; - socklen_t glen, - slen; - - mcast_sreq_fun = &php_mcast_leave_source; - mcast_sreq_fun: - convert_to_array_ex(arg4); - opt_ht = HASH_OF(*arg4); - - if (php_get_address_from_array(opt_ht, "group", php_sock, &group, - &glen TSRMLS_CC) == FAILURE) { - return FAILURE; - } - if (php_get_address_from_array(opt_ht, "source", php_sock, &source, - &slen TSRMLS_CC) == FAILURE) { - return FAILURE; - } - if (php_get_if_index_from_array(opt_ht, "interface", php_sock, - &if_index TSRMLS_CC) == FAILURE) { - return FAILURE; - } - - retval = mcast_sreq_fun(php_sock, level, (struct sockaddr*)&group, - glen, (struct sockaddr*)&source, slen, if_index TSRMLS_CC); - break; - } -#endif - default: - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "unexpected option in php_do_mcast_opt (level %d, option %d). " - "This is a bug.", level, optname); - return FAILURE; - } - - if (retval != 0) { - if (retval != -2) { /* error, but message already emitted */ - PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); - } - return FAILURE; - } - return SUCCESS; -} - /* {{{ proto bool socket_set_option(resource socket, int level, int optname, int|array optval) Sets socket options for the socket */ PHP_FUNCTION(socket_set_option) @@ -2127,10 +1956,6 @@ PHP_FUNCTION(socket_set_option) zval **l_onoff, **l_linger; zval **sec, **usec; - /* Multicast */ - unsigned int if_index; - struct in_addr if_addr; - unsigned char ipv4_mcast_ttl_lback; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rllZ", &arg1, &level, &optname, &arg4) == FAILURE) { return; @@ -2140,94 +1965,23 @@ PHP_FUNCTION(socket_set_option) set_errno(0); - if (level == IPPROTO_IP) { - switch (optname) { - case MCAST_JOIN_GROUP: - case MCAST_LEAVE_GROUP: -#ifdef HAS_MCAST_EXT - case MCAST_BLOCK_SOURCE: - case MCAST_UNBLOCK_SOURCE: - case MCAST_JOIN_SOURCE_GROUP: - case MCAST_LEAVE_SOURCE_GROUP: -#endif - if (php_do_mcast_opt(php_sock, level, optname, arg4 TSRMLS_CC) == FAILURE) { - RETURN_FALSE; - } else { - RETURN_TRUE; - } +#define HANDLE_SUBCALL(res) \ + do { \ + if (res == 1) { goto default_case; } \ + else if (res == SUCCESS) { RETURN_TRUE; } \ + else { RETURN_FALSE; } \ + } while (0) - case IP_MULTICAST_IF: - if (php_get_if_index_from_zval(*arg4, &if_index TSRMLS_CC) == FAILURE) { - RETURN_FALSE; - } - if (php_if_index_to_addr4(if_index, php_sock, &if_addr TSRMLS_CC) == FAILURE) { - RETURN_FALSE; - } - opt_ptr = &if_addr; - optlen = sizeof(if_addr); - goto dosockopt; - - case IP_MULTICAST_LOOP: - convert_to_boolean_ex(arg4); - goto ipv4_loop_ttl; - case IP_MULTICAST_TTL: - convert_to_long_ex(arg4); - if (Z_LVAL_PP(arg4) < 0L || Z_LVAL_PP(arg4) > 255L) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "Expected a value between 0 and 255"); - RETURN_FALSE; - } -ipv4_loop_ttl: - ipv4_mcast_ttl_lback = (unsigned char) Z_LVAL_PP(arg4); - opt_ptr = &ipv4_mcast_ttl_lback; - optlen = sizeof(ipv4_mcast_ttl_lback); - goto dosockopt; - } + if (level == IPPROTO_IP) { + int res = php_do_setsockopt_ip_mcast(php_sock, level, optname, arg4); + HANDLE_SUBCALL(res); } #if HAVE_IPV6 else if (level == IPPROTO_IPV6) { - switch (optname) { - case MCAST_JOIN_GROUP: - case MCAST_LEAVE_GROUP: -#ifdef HAS_MCAST_EXT - case MCAST_BLOCK_SOURCE: - case MCAST_UNBLOCK_SOURCE: - case MCAST_JOIN_SOURCE_GROUP: - case MCAST_LEAVE_SOURCE_GROUP: -#endif - if (php_do_mcast_opt(php_sock, level, optname, arg4 TSRMLS_CC) == FAILURE) { - RETURN_FALSE; - } else { - RETURN_TRUE; - } - - case IPV6_MULTICAST_IF: - if (php_get_if_index_from_zval(*arg4, &if_index TSRMLS_CC) == FAILURE) { - RETURN_FALSE; - } - - opt_ptr = &if_index; - optlen = sizeof(if_index); - goto dosockopt; - - case IPV6_MULTICAST_LOOP: - convert_to_boolean_ex(arg4); - goto ipv6_loop_hops; - case IPV6_MULTICAST_HOPS: - convert_to_long_ex(arg4); - if (Z_LVAL_PP(arg4) < -1L || Z_LVAL_PP(arg4) > 255L) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, - "Expected a value between -1 and 255"); - RETURN_FALSE; - } -ipv6_loop_hops: - ov = (int) Z_LVAL_PP(arg4); - opt_ptr = &ov; - optlen = sizeof(ov); - goto dosockopt; - } + int res = php_do_setsockopt_ipv6_mcast(php_sock, level, optname, arg4); + HANDLE_SUBCALL(res); } #endif @@ -2292,6 +2046,7 @@ PHP_FUNCTION(socket_set_option) } default: +default_case: convert_to_long_ex(arg4); ov = Z_LVAL_PP(arg4); @@ -2300,12 +2055,9 @@ PHP_FUNCTION(socket_set_option) break; } -dosockopt: retval = setsockopt(php_sock->bsd_socket, level, optname, opt_ptr, optlen); if (retval != 0) { - if (retval != -2) { /* error, but message already emitted */ - PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); - } + PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); RETURN_FALSE; } From 8fb1aa618453149bb876bda4cafd1860468c4443 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 6 Nov 2012 13:36:40 +0100 Subject: [PATCH 2353/2394] Destroy ancillary registry on shutdown --- ext/sockets/sendrecvmsg.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 16330e0ded0ec..88b937f8285ec 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -1540,6 +1540,13 @@ static void init_ancillary_registry(void) to_zval_read_fd_array, SOL_SOCKET, SCM_RIGHTS); #endif +} +static void destroy_ancillary_registry(void) +{ + if (ancillary_registry.initialized) { + zend_hash_destroy(&ancillary_registry.ht); + ancillary_registry.initialized = 0; + } } static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) { @@ -1761,4 +1768,6 @@ void _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS) #ifdef ZTS tsrm_mutex_free(ancillary_mutex); #endif + + destroy_ancillary_registry(); } From b18bd8904e41941db204ac6b2bf4cf43421e8838 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 6 Nov 2012 13:38:57 +0100 Subject: [PATCH 2354/2394] Rename some functions for consistency --- ext/sockets/sendrecvmsg.c | 4 ++-- ext/sockets/sendrecvmsg.h | 4 ++-- ext/sockets/sockets.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 88b937f8285ec..201adbda43362 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -1723,7 +1723,7 @@ PHP_FUNCTION(socket_cmsg_space) RETURN_LONG((long)CMSG_SPACE(entry->size + n * entry->var_el_size)); } -void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) +void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS) { /* IPv6 ancillary data * Note that support for sticky options via setsockopt() is not implemented @@ -1763,7 +1763,7 @@ void _socket_sendrecvmsg_init(INIT_FUNC_ARGS) #endif } -void _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS) +void php_socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS) { #ifdef ZTS tsrm_mutex_free(ancillary_mutex); diff --git a/ext/sockets/sendrecvmsg.h b/ext/sockets/sendrecvmsg.h index 82dc456e65538..929a6ad9cfe17 100644 --- a/ext/sockets/sendrecvmsg.h +++ b/ext/sockets/sendrecvmsg.h @@ -4,5 +4,5 @@ PHP_FUNCTION(socket_sendmsg); PHP_FUNCTION(socket_recvmsg); PHP_FUNCTION(socket_cmsg_space); -void _socket_sendrecvmsg_init(INIT_FUNC_ARGS); -void _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS); +void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS); +void php_socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS); diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 9f11594425944..1d86028691b53 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -751,7 +751,7 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("IPV6_UNICAST_HOPS", IPV6_UNICAST_HOPS, CONST_CS | CONST_PERSISTENT); #endif - _socket_sendrecvmsg_init(INIT_FUNC_ARGS_PASSTHRU); + php_socket_sendrecvmsg_init(INIT_FUNC_ARGS_PASSTHRU); return SUCCESS; } @@ -774,7 +774,7 @@ PHP_RSHUTDOWN_FUNCTION(sockets) efree(SOCKETS_G(strerror_buf)); SOCKETS_G(strerror_buf) = NULL; } - _socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS_PASSTHRU); + php_socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS_PASSTHRU); return SUCCESS; } From 66ea02458746a4853ff6190c6c75da5e95677911 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 6 Nov 2012 17:27:08 +0100 Subject: [PATCH 2355/2394] Support sticky IPV6_PKTINFO --- ext/sockets/sendrecvmsg.c | 90 ++++++++++++++++++- ext/sockets/sendrecvmsg.h | 3 + ext/sockets/sockets.c | 10 +++ .../tests/socket_set_option_in6_pktinfo.phpt | 31 +++++++ 4 files changed, 132 insertions(+), 2 deletions(-) create mode 100644 ext/sockets/tests/socket_set_option_in6_pktinfo.phpt diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 201adbda43362..6b1a528c5b1df 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -77,6 +77,7 @@ struct key_value { #define KEY_FILL_SOCKADDR "fill_sockaddr" #define KEY_RECVMSG_RET "recvmsg_ret" #define KEY_CMSG_LEN "cmsg_len" +static const struct key_value empty_key_value_list[] = {{0}}; typedef void (from_zval_write_field)(const zval *arr_value, char *field, ser_context *ctx); @@ -222,6 +223,12 @@ static void err_msg_dispose(struct err_s *err TSRMLS_DC) } } } +static void allocations_dispose(zend_llist **allocations) +{ + zend_llist_destroy(*allocations); + efree(*allocations); + *allocations = NULL; +} static unsigned from_array_iterate(const zval *arr, void (*func)(zval **elem, unsigned i, void **args, ser_context *ctx), @@ -1660,8 +1667,7 @@ PHP_FUNCTION(socket_recvmsg) /* we don;t need msghdr anymore; free it */ msghdr = NULL; - zend_llist_destroy(allocations); - efree(allocations); + allocations_dispose(&allocations); zval_dtor(zmsg); if (!err.has_error) { @@ -1723,6 +1729,86 @@ PHP_FUNCTION(socket_cmsg_space) RETURN_LONG((long)CMSG_SPACE(entry->size + n * entry->var_el_size)); } +int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4) +{ + struct err_s err = {0}; + zend_llist *allocations = NULL; + void *opt_ptr; + socklen_t optlen; + int retval; + + assert(level == IPPROTO_IPV6); + + switch (optname) { +#ifdef IPV6_PKTINFO + case IPV6_PKTINFO: + opt_ptr = from_zval_run_conversions(*arg4, php_sock, from_zval_write_in6_pktinfo, + sizeof(struct in6_pktinfo), "in6_pktinfo", &allocations, &err); + if (err.has_error) { + err_msg_dispose(&err TSRMLS_CC); + return FAILURE; + } + + optlen = sizeof(struct in6_pktinfo); + goto dosockopt; +#endif + } + + /* we also support IPV6_TCLASS, but that can be handled by the default + * integer optval handling in the caller */ + return 1; + +dosockopt: + retval = setsockopt(php_sock->bsd_socket, level, optname, opt_ptr, optlen); + if (retval != 0) { + PHP_SOCKET_ERROR(php_sock, "unable to set socket option", errno); + } + allocations_dispose(&allocations); + + return retval != 0 ? FAILURE : SUCCESS; +} + +int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result) +{ + struct err_s err = {0}; + void *buffer; + socklen_t size; + int res; + to_zval_read_field *reader; + + assert(level == IPPROTO_IPV6); + + switch (optname) { +#ifdef IPV6_PKTINFO + case IPV6_PKTINFO: + size = sizeof(struct in6_pktinfo); + reader = &to_zval_read_in6_pktinfo; + break; +#endif + default: + return 1; + } + + buffer = ecalloc(1, size); + res = getsockopt(php_sock->bsd_socket, level, optname, buffer, &size); + if (res != 0) { + PHP_SOCKET_ERROR(php_sock, "unable to get socket option", errno); + } else { + zval *zv = to_zval_run_conversions(buffer, reader, "in6_pktinfo", + empty_key_value_list, &err); + if (err.has_error) { + err_msg_dispose(&err); + res = -1; + } else { + ZVAL_COPY_VALUE(result, zv); + efree(zv); + } + } + efree(buffer); + + return res == 0 ? SUCCESS : FAILURE; +} + void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS) { /* IPv6 ancillary data diff --git a/ext/sockets/sendrecvmsg.h b/ext/sockets/sendrecvmsg.h index 929a6ad9cfe17..82fb38b4b5f8b 100644 --- a/ext/sockets/sendrecvmsg.h +++ b/ext/sockets/sendrecvmsg.h @@ -6,3 +6,6 @@ PHP_FUNCTION(socket_cmsg_space); void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS); void php_socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS); + +int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4); +int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result); diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 1d86028691b53..9c57e2d98d22c 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -1877,6 +1877,13 @@ PHP_FUNCTION(socket_get_option) } } } + } else if (level == IPPROTO_IPV6) { + int ret = php_do_getsockopt_ipv6_rfc3542(php_sock, level, optname, return_value); + if (ret == SUCCESS) { + return; + } else if (ret == FAILURE) { + RETURN_FALSE; + } /* else continue */ } /* sol_socket options and general case */ @@ -1981,6 +1988,9 @@ PHP_FUNCTION(socket_set_option) #if HAVE_IPV6 else if (level == IPPROTO_IPV6) { int res = php_do_setsockopt_ipv6_mcast(php_sock, level, optname, arg4); + if (res == 1) { + res = php_do_setsockopt_ipv6_rfc3542(php_sock, level, optname, arg4); + } HANDLE_SUBCALL(res); } #endif diff --git a/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt b/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt new file mode 100644 index 0000000000000..53320cad0c3ae --- /dev/null +++ b/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt @@ -0,0 +1,31 @@ +--TEST-- +socket_set_option() with IPV6_PKTINFO +--SKIPIF-- + '::1', + "ifindex" => 0 +])); +//Oddly, Linux does not support IPV6_PKTINFO in sockgetopt(). +//See do_ipv6_getsockopt() on the kernel sources +//A work-around with is sort-of possible (with IPV6_2292PKTOPTIONS), +//but not worth it +//var_dump(socket_get_option($s, IPPROTO_IPV6, IPV6_PKTINFO)); + +--EXPECTF-- +Warning: socket_set_option(): error converting user data (path: in6_pktinfo): The key 'addr' is required in %s on line %d +bool(false) +bool(true) + From 4414b33abd087bba26cb2cbdc2bf05938d5a6690 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Mon, 12 Nov 2012 00:40:38 +0100 Subject: [PATCH 2356/2394] Refactoring: move stuff to new conversions.c --- ext/sockets/config.m4 | 2 +- ext/sockets/conversions.c | 1477 +++++++++++++++++++++++++++++++++++++ ext/sockets/conversions.h | 78 ++ ext/sockets/sendrecvmsg.c | 1461 +----------------------------------- ext/sockets/sendrecvmsg.h | 25 + 5 files changed, 1583 insertions(+), 1460 deletions(-) create mode 100644 ext/sockets/conversions.c create mode 100644 ext/sockets/conversions.h diff --git a/ext/sockets/config.m4 b/ext/sockets/config.m4 index 3b5b90714b727..9c752496463f5 100644 --- a/ext/sockets/config.m4 +++ b/ext/sockets/config.m4 @@ -43,6 +43,6 @@ if test "$PHP_SOCKETS" != "no"; then AC_DEFINE(HAVE_SA_SS_FAMILY,1,[Whether you have sockaddr_storage.ss_family]) fi - PHP_NEW_EXTENSION([sockets], [sockets.c multicast.c sockaddr_conv.c sendrecvmsg.c], [$ext_shared]) + PHP_NEW_EXTENSION([sockets], [sockets.c multicast.c conversions.c sockaddr_conv.c sendrecvmsg.c], [$ext_shared]) PHP_INSTALL_HEADERS([ext/sockets/], [php_sockets.h]) fi diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c new file mode 100644 index 0000000000000..7ca9972ac0d38 --- /dev/null +++ b/ext/sockets/conversions.c @@ -0,0 +1,1477 @@ +#include "conversions.h" +#include "sockaddr_conv.h" +#include "conversions.h" +#include "sendrecvmsg.h" /* for ancillary registry */ + +#include +#include + +#include +#include +#include +#include +#include + +#include +#include +#include + +#define MAX_USER_BUFF_SIZE ((size_t)(100*1024*1024)) +#define DEFAULT_BUFF_SIZE 8192 + +struct _ser_context { + HashTable params; /* stores pointers; has to be first */ + struct err_s err; + zend_llist keys, + /* common part to res_context ends here */ + allocations; + php_socket *sock; +}; +struct _res_context { + HashTable params; /* stores pointers; has to be first */ + struct err_s err; + zend_llist keys; +}; + +typedef struct { + /* zval info */ + const char *name; + unsigned name_size; + int required; + + /* structure info */ + size_t field_offset; /* 0 to pass full structure, e.g. when more than + one field is to be changed; in that case the + callbacks need to know the name of the fields */ + + /* callbacks */ + from_zval_write_field *from_zval; + to_zval_read_field *to_zval; +} field_descriptor; + +#define KEY_FILL_SOCKADDR "fill_sockaddr" +#define KEY_RECVMSG_RET "recvmsg_ret" +#define KEY_CMSG_LEN "cmsg_len" + +/* PARAMETERS */ +static int param_get_bool(void *ctx, const char *key, int def) +{ + int **elem; + if (zend_hash_find(ctx, key, strlen(key) + 1, (void**)&elem) == SUCCESS) { + return **elem; + } else { + return def; + } +} + +/* MEMORY */ +static inline void *accounted_emalloc(size_t alloc_size, ser_context *ctx) +{ + void *ret = emalloc(alloc_size); + zend_llist_add_element(&ctx->allocations, &ret); + return ret; +} +static inline void *accounted_ecalloc(size_t nmemb, size_t alloc_size, ser_context *ctx) +{ + void *ret = ecalloc(nmemb, alloc_size); + zend_llist_add_element(&ctx->allocations, &ret); + return ret; +} +static inline void *accounted_safe_ecalloc(size_t nmemb, size_t alloc_size, size_t offset, ser_context *ctx) +{ + void *ret = safe_emalloc(nmemb, alloc_size, offset); + memset(ret, '\0', nmemb * alloc_size + offset); + zend_llist_add_element(&ctx->allocations, &ret); + return ret; +} + +/* ERRORS */ +static void do_from_to_zval_err(struct err_s *err, + zend_llist *keys, + const char *what_conv, + const char *fmt, + va_list ap) +{ + smart_str path = {0}; + const char **node; + char *user_msg; + int user_msg_size; + zend_llist_position pos; + + if (err->has_error) { + return; + } + + for (node = zend_llist_get_first_ex(keys, &pos); + node != NULL; + node = zend_llist_get_next_ex(keys, &pos)) { + smart_str_appends(&path, *node); + smart_str_appends(&path, " > "); + } + + if (path.len > 3) { + path.len -= 3; + } + smart_str_0(&path); + + user_msg_size = vspprintf(&user_msg, 0, fmt, ap); + + err->has_error = 1; + err->level = E_WARNING; + spprintf(&err->msg, 0, "error converting %s data (path: %s): %.*s", + what_conv, + path.c && path.c != '\0' ? path.c : "unavailable", + user_msg_size, user_msg); + err->should_free = 1; + + efree(user_msg); + smart_str_free_ex(&path, 0); +} +__attribute__ ((format (printf, 2, 3))) +static void do_from_zval_err(ser_context *ctx, const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + do_from_to_zval_err(&ctx->err, &ctx->keys, "user", fmt, ap); + va_end(ap); +} +__attribute__ ((format (printf, 2, 3))) +static void do_to_zval_err(res_context *ctx, const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + do_from_to_zval_err(&ctx->err, &ctx->keys, "native", fmt, ap); + va_end(ap); +} + +void err_msg_dispose(struct err_s *err TSRMLS_DC) +{ + if (err->msg != NULL) { + php_error_docref0(NULL TSRMLS_CC, err->level, "%s", err->msg); + if (err->should_free) { + efree(err->msg); + } + } +} +void allocations_dispose(zend_llist **allocations) +{ + zend_llist_destroy(*allocations); + efree(*allocations); + *allocations = NULL; +} + +static unsigned from_array_iterate(const zval *arr, + void (*func)(zval **elem, unsigned i, void **args, ser_context *ctx), + void **args, + ser_context *ctx) +{ + HashPosition pos; + unsigned i; + zval **elem; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + + for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 1; + !ctx->err.has_error + && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; + zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos), i++) { + if (snprintf(buf, sizeof(buf), "element #%u", i) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + func(elem, i, args, ctx); + + zend_llist_remove_tail(&ctx->keys); + } + + return i -1; +} + +/* Generic Aggregated conversions */ +static void from_zval_write_aggregation(const zval *container, + char *structure, + const field_descriptor *descriptors, + ser_context *ctx) +{ + const field_descriptor *descr; + zval **elem; + + if (Z_TYPE_P(container) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + } + + for (descr = descriptors; descr->name != NULL && !ctx->err.has_error; descr++) { + if (zend_hash_find(Z_ARRVAL_P(container), + descr->name, descr->name_size, (void**)&elem) == SUCCESS) { + + if (descr->from_zval == NULL) { + do_from_zval_err(ctx, "No information on how to convert value " + "of key '%s'", descr->name); + break; + } + + zend_llist_add_element(&ctx->keys, (void*)&descr->name); + descr->from_zval(*elem, ((char*)structure) + descr->field_offset, ctx); + zend_llist_remove_tail(&ctx->keys); + + } else if (descr->required) { + do_from_zval_err(ctx, "The key '%s' is required", descr->name); + break; + } + } +} +static void to_zval_read_aggregation(const char *structure, + zval *zarr, /* initialized array */ + const field_descriptor *descriptors, + res_context *ctx) +{ + const field_descriptor *descr; + + assert(Z_TYPE_P(zarr) == IS_ARRAY); + assert(Z_ARRVAL_P(zarr) != NULL); + + for (descr = descriptors; descr->name != NULL && !ctx->err.has_error; descr++) { + zval *new_zv; + + if (descr->to_zval == NULL) { + do_to_zval_err(ctx, "No information on how to convert native " + "field into value for key '%s'", descr->name); + break; + } + + ALLOC_INIT_ZVAL(new_zv); + add_assoc_zval_ex(zarr, descr->name, descr->name_size, new_zv); + + zend_llist_add_element(&ctx->keys, (void*)&descr->name); + descr->to_zval(structure + descr->field_offset, new_zv, ctx); + zend_llist_remove_tail(&ctx->keys); + } +} + +/* CONVERSIONS for integers */ +static long from_zval_integer_common(const zval *arr_value, ser_context *ctx) +{ + long ret = 0; + zval lzval = zval_used_for_init; + + if (Z_TYPE_P(arr_value) != IS_LONG) { + ZVAL_COPY_VALUE(&lzval, arr_value); + zval_copy_ctor(&lzval); + arr_value = &lzval; + } + + switch (Z_TYPE_P(arr_value)) { + case IS_LONG: +long_case: + ret = Z_LVAL_P(arr_value); + break; + + /* if not long we're operating on lzval */ + case IS_DOUBLE: +double_case: + convert_to_long(&lzval); + goto long_case; + + case IS_OBJECT: + case IS_STRING: { + long lval; + double dval; + + convert_to_string(&lzval); + + switch (is_numeric_string(Z_STRVAL(lzval), Z_STRLEN(lzval), &lval, &dval, 0)) { + case IS_DOUBLE: + zval_dtor(&lzval); + Z_TYPE(lzval) = IS_DOUBLE; + Z_DVAL(lzval) = dval; + goto double_case; + + case IS_LONG: + zval_dtor(&lzval); + Z_TYPE(lzval) = IS_LONG; + Z_DVAL(lzval) = lval; + goto long_case; + } + + /* if we get here, we don't have a numeric string */ + do_from_zval_err(ctx, "expected an integer, but got a non numeric " + "string (possibly from a converted object): '%s'", Z_STRVAL_P(arr_value)); + break; + } + + default: + do_from_zval_err(ctx, "%s", "expected an integer, either of a PHP " + "integer type or of a convertible type"); + break; + } + + zval_dtor(&lzval); + + return ret; +} +void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + int ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval > INT_MAX || lval < INT_MIN) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a native int"); + return; + } + + ival = (int)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_unsigned(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + unsigned ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (sizeof(long) > sizeof(ival) && (lval < 0 || lval > UINT_MAX)) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a native unsigned int"); + return; + } + + ival = (unsigned)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_uint32(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uint32_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (sizeof(long) > sizeof(uint32_t) && (lval < 0 || lval > 0xFFFFFFFF)) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for an unsigned 32-bit integer"); + return; + } + + ival = (uint32_t)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_net_uint16(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uint16_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > 0xFFFF) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for an unsigned 16-bit integer"); + return; + } + + ival = htons((uint16_t)lval); + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_sa_family(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + sa_family_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > (sa_family_t)-1) { /* sa_family_t is unsigned */ + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a sa_family_t value"); + return; + } + + ival = (sa_family_t)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_pid_t(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + pid_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || (pid_t)lval != lval) { /* pid_t is signed */ + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a pid_t value"); + return; + } + + ival = (pid_t)lval; + memcpy(field, &ival, sizeof(ival)); +} +static void from_zval_write_uid_t(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uid_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + /* uid_t can be signed or unsigned (generally unsigned) */ + if ((uid_t)-1 > (uid_t)0) { + if (sizeof(long) > sizeof(uid_t) && (lval < 0 || (uid_t)lval != lval)) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a uid_t value"); + return; + } + } else { + if (sizeof(long) > sizeof(uid_t) && (uid_t)lval != lval) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for a uid_t value"); + return; + } + } + + ival = (uid_t)lval; + memcpy(field, &ival, sizeof(ival)); +} + +void to_zval_read_int(const char *data, zval *zv, res_context *ctx) +{ + int ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_unsigned(const char *data, zval *zv, res_context *ctx) +{ + unsigned ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_net_uint16(const char *data, zval *zv, res_context *ctx) +{ + uint16_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ntohs(ival)); +} +static void to_zval_read_uint32(const char *data, zval *zv, res_context *ctx) +{ + uint32_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_sa_family(const char *data, zval *zv, res_context *ctx) +{ + sa_family_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_pid_t(const char *data, zval *zv, res_context *ctx) +{ + pid_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} +static void to_zval_read_uid_t(const char *data, zval *zv, res_context *ctx) +{ + uid_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} + +/* CONVERSIONS for sockaddr */ +static void from_zval_write_sin_addr(const zval *zaddr_str, char *inaddr, ser_context *ctx) +{ + int res; + struct sockaddr_in saddr = {0}; + zval lzval = zval_used_for_init; + TSRMLS_FETCH(); + + if (Z_TYPE_P(zaddr_str) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, zaddr_str); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + zaddr_str = &lzval; + } + + res = php_set_inet_addr(&saddr, Z_STRVAL_P(zaddr_str), ctx->sock TSRMLS_CC); + if (res) { + memcpy(inaddr, &saddr.sin_addr, sizeof saddr.sin_addr); + } else { + /* error already emitted, but let's emit another more relevant */ + do_from_zval_err(ctx, "could not resolve address '%s' to get an AF_INET " + "address", Z_STRVAL_P(zaddr_str)); + } + + zval_dtor(&lzval); +} +static void to_zval_read_sin_addr(const char *data, zval *zv, res_context *ctx) +{ + const struct in_addr *addr = (const struct in_addr *)data; + socklen_t size = INET_ADDRSTRLEN; + + Z_TYPE_P(zv) = IS_STRING; + Z_STRVAL_P(zv) = ecalloc(1, size); + Z_STRLEN_P(zv) = 0; + + if (inet_ntop(AF_INET, addr, Z_STRVAL_P(zv), size) == NULL) { + do_to_zval_err(ctx, "could not convert IPv4 address to string " + "(errno %d)", errno); + return; + } + + Z_STRLEN_P(zv) = strlen(Z_STRVAL_P(zv)); +} +static const field_descriptor descriptors_sockaddr_in[] = { + {"family", sizeof("family"), 0, offsetof(struct sockaddr_in, sin_family), from_zval_write_sa_family, to_zval_read_sa_family}, + {"addr", sizeof("addr"), 0, offsetof(struct sockaddr_in, sin_addr), from_zval_write_sin_addr, to_zval_read_sin_addr}, + {"port", sizeof("port"), 0, offsetof(struct sockaddr_in, sin_port), from_zval_write_net_uint16, to_zval_read_net_uint16}, + {0} +}; +static void from_zval_write_sockaddr_in(const zval *container, char *sockaddr, ser_context *ctx) +{ + from_zval_write_aggregation(container, sockaddr, descriptors_sockaddr_in, ctx); +} +static void to_zval_read_sockaddr_in(const char *data, zval *zv, res_context *ctx) +{ + to_zval_read_aggregation(data, zv, descriptors_sockaddr_in, ctx); +} +static void from_zval_write_sin6_addr(const zval *zaddr_str, char *addr6, ser_context *ctx) +{ + int res; + struct sockaddr_in6 saddr6 = {0}; + zval lzval = zval_used_for_init; + TSRMLS_FETCH(); + + if (Z_TYPE_P(zaddr_str) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, zaddr_str); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + zaddr_str = &lzval; + } + + res = php_set_inet6_addr(&saddr6, + Z_STRVAL_P(zaddr_str), ctx->sock TSRMLS_CC); + if (res) { + memcpy(addr6, &saddr6.sin6_addr, sizeof saddr6.sin6_addr); + } else { + /* error already emitted, but let's emit another more relevant */ + do_from_zval_err(ctx, "could not resolve address '%s' to get an AF_INET6 " + "address", Z_STRVAL_P(zaddr_str)); + } + + zval_dtor(&lzval); +} +static void to_zval_read_sin6_addr(const char *data, zval *zv, res_context *ctx) +{ + const struct in6_addr *addr = (const struct in6_addr *)data; + socklen_t size = INET6_ADDRSTRLEN; + + Z_TYPE_P(zv) = IS_STRING; + Z_STRVAL_P(zv) = ecalloc(1, size); + Z_STRLEN_P(zv) = 0; + + if (inet_ntop(AF_INET6, addr, Z_STRVAL_P(zv), size) == NULL) { + do_to_zval_err(ctx, "could not convert IPv6 address to string " + "(errno %d)", errno); + return; + } + + Z_STRLEN_P(zv) = strlen(Z_STRVAL_P(zv)); +} +static const field_descriptor descriptors_sockaddr_in6[] = { + {"family", sizeof("family"), 0, offsetof(struct sockaddr_in6, sin6_family), from_zval_write_sa_family, to_zval_read_sa_family}, + {"addr", sizeof("addr"), 0, offsetof(struct sockaddr_in6, sin6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, + {"port", sizeof("port"), 0, offsetof(struct sockaddr_in6, sin6_port), from_zval_write_net_uint16, to_zval_read_net_uint16}, + {"flowinfo", sizeof("flowinfo"), 0, offsetof(struct sockaddr_in6, sin6_flowinfo), from_zval_write_uint32, to_zval_read_uint32}, + {"scope_id", sizeof("scope_id"), 0, offsetof(struct sockaddr_in6, sin6_scope_id), from_zval_write_uint32, to_zval_read_uint32}, + {0} +}; +static void from_zval_write_sockaddr_in6(const zval *container, char *sockaddr6, ser_context *ctx) +{ + from_zval_write_aggregation(container, sockaddr6, descriptors_sockaddr_in6, ctx); +} +static void to_zval_read_sockaddr_in6(const char *data, zval *zv, res_context *ctx) +{ + to_zval_read_aggregation(data, zv, descriptors_sockaddr_in6, ctx); +} +static void from_zval_write_sun_path(const zval *path, char *sockaddr_un_c, ser_context *ctx) +{ + zval lzval = zval_used_for_init; + struct sockaddr_un *saddr = (struct sockaddr_un*)sockaddr_un_c; + + if (Z_TYPE_P(path) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, path); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + path = &lzval; + } + + if (Z_STRLEN_P(path) >= sizeof(saddr->sun_path)) { + do_from_zval_err(ctx, "the path is too long, the maximum permitted " + "length is %ld", sizeof(saddr->sun_path) - 1); + return; + } + + memcpy(&saddr->sun_path, Z_STRVAL_P(path), Z_STRLEN_P(path)); + saddr->sun_path[Z_STRLEN_P(path)] = '\0'; + + zval_dtor(&lzval); +} +static void to_zval_read_sun_path(const char *data, zval *zv, res_context *ctx) { + struct sockaddr_un *saddr = (struct sockaddr_un*)data; + char *nul_pos; + + nul_pos = memchr(&saddr->sun_path, '\0', sizeof(saddr->sun_path)); + if (nul_pos == NULL) { + do_to_zval_err(ctx, "could not find a NUL in the path"); + return; + } + + ZVAL_STRINGL(zv, saddr->sun_path, nul_pos - (char*)&saddr->sun_path, 1); +} +static const field_descriptor descriptors_sockaddr_un[] = { + {"family", sizeof("family"), 0, offsetof(struct sockaddr_un, sun_family), from_zval_write_sa_family, to_zval_read_sa_family}, + {"path", sizeof("path"), 0, 0, from_zval_write_sun_path, to_zval_read_sun_path}, + {0} +}; +static void from_zval_write_sockaddr_un(const zval *container, char *sockaddr, ser_context *ctx) +{ + from_zval_write_aggregation(container, sockaddr, descriptors_sockaddr_un, ctx); +} +static void to_zval_read_sockaddr_un(const char *data, zval *zv, res_context *ctx) +{ + to_zval_read_aggregation(data, zv, descriptors_sockaddr_un, ctx); +} +static void from_zval_write_sockaddr_aux(const zval *container, + struct sockaddr **sockaddr_ptr, + socklen_t *sockaddr_len, + ser_context *ctx) +{ + int family; + zval **elem; + int fill_sockaddr; + + if (Z_TYPE_P(container) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + fill_sockaddr = param_get_bool(ctx, KEY_FILL_SOCKADDR, 1); + + if (zend_hash_find(Z_ARRVAL_P(container), "family", sizeof("family"), (void**)&elem) == SUCCESS + && Z_TYPE_PP(elem) != IS_NULL) { + const char *node = "family"; + zend_llist_add_element(&ctx->keys, &node); + from_zval_write_int(*elem, (char*)&family, ctx); + zend_llist_remove_tail(&ctx->keys); + } else { + family = ctx->sock->type; + } + + switch (family) { + case AF_INET: + /* though not all OSes support sockaddr_in used in IPv6 sockets */ + if (ctx->sock->type != AF_INET && ctx->sock->type != AF_INET6) { + do_from_zval_err(ctx, "the specified family (number %d) is not " + "supported on this socket", family); + return; + } + *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_in), ctx); + *sockaddr_len = sizeof(struct sockaddr_in); + if (fill_sockaddr) { + from_zval_write_sockaddr_in(container, (char*)*sockaddr_ptr, ctx); + (*sockaddr_ptr)->sa_family = AF_INET; + } + break; + + case AF_INET6: + if (ctx->sock->type != AF_INET6) { + do_from_zval_err(ctx, "the specified family (AF_INET6) is not " + "supported on this socket"); + return; + } + *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_in6), ctx); + *sockaddr_len = sizeof(struct sockaddr_in6); + if (fill_sockaddr) { + from_zval_write_sockaddr_in6(container, (char*)*sockaddr_ptr, ctx); + (*sockaddr_ptr)->sa_family = AF_INET6; + } + break; + + case AF_UNIX: + if (ctx->sock->type != AF_UNIX) { + do_from_zval_err(ctx, "the specified family (AF_UNIX) is not " + "supported on this socket"); + return; + } + *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_un), ctx); + *sockaddr_len = sizeof(struct sockaddr_un); + if (fill_sockaddr) { + from_zval_write_sockaddr_un(container, (char*)*sockaddr_ptr, ctx); + (*sockaddr_ptr)->sa_family = AF_UNIX; + } + break; + + default: + do_from_zval_err(ctx, "%s", "the only families currently supported are " + "AF_INET, AF_INET6 and AF_UNIX"); + break; + } +} +static void to_zval_read_sockaddr_aux(const char *sockaddr_c, zval *zv, res_context *ctx) +{ + const struct sockaddr *saddr = (struct sockaddr *)sockaddr_c; + + if (saddr->sa_family == 0) { + ZVAL_NULL(zv); + return; + } + + array_init(zv); + + switch (saddr->sa_family) { + case AF_INET: + to_zval_read_sockaddr_in(sockaddr_c, zv, ctx); + break; + + case AF_INET6: + to_zval_read_sockaddr_in6(sockaddr_c, zv, ctx); + break; + + case AF_UNIX: + to_zval_read_sockaddr_un(sockaddr_c, zv, ctx); + break; + + default: + do_to_zval_err(ctx, "cannot read struct sockaddr with family %d; " + "not supported", + (int)saddr->sa_family); + break; + } +} + +/* CONVERSIONS for cmsghdr */ +/* + * [ level => , type => , data => [],] + * struct cmsghdr { + * socklen_t cmsg_len; // data byte count, including header + * int cmsg_level; // originating protocol + * int cmsg_type; // protocol-specific type + * // followed by unsigned char cmsg_data[]; + * }; + */ +static void from_zval_write_control(const zval *arr, + void **control_buf, + zend_llist_element *alloc, + size_t *control_len, + size_t *offset, + ser_context *ctx) +{ + struct cmsghdr *cmsghdr; + int level, + type; + size_t data_len, + req_space, + space_left; + ancillary_reg_entry *entry; + + static const field_descriptor descriptor_level[] = { + {"level", sizeof("level"), 0, 0, from_zval_write_int, 0}, + {0} + }; + static const field_descriptor descriptor_type[] = { + {"type", sizeof("type"), 0, 0, from_zval_write_int, 0}, + {0} + }; + field_descriptor descriptor_data[] = { + {"data", sizeof("data"), 0, 0, 0, 0}, + {0} + }; + + from_zval_write_aggregation(arr, (char *)&level, descriptor_level, ctx); + if (ctx->err.has_error) { + return; + } + from_zval_write_aggregation(arr, (char *)&type, descriptor_type, ctx); + if (ctx->err.has_error) { + return; + } + + entry = get_ancillary_reg_entry(level, type); + if (entry == NULL) { + do_from_zval_err(ctx, "cmsghdr with level %d and type %d not supported", + level, type); + return; + } + + if (entry->calc_space) { + data_len = entry->calc_space(arr, ctx); + if (ctx->err.has_error) { + return; + } + } else { + data_len = entry->size; + } + req_space = CMSG_SPACE(data_len); + space_left = *control_len - *offset; + assert(*control_len >= *offset); + + if (space_left < req_space) { + *control_buf = safe_erealloc(*control_buf, 2, req_space, *control_len); + *control_len += 2 * req_space; + memcpy(&alloc->data, *control_buf, sizeof *control_buf); + } + + cmsghdr = (struct cmsghdr*)(((char*)*control_buf) + *offset); + cmsghdr->cmsg_level = level; + cmsghdr->cmsg_type = type; + cmsghdr->cmsg_len = CMSG_LEN(data_len); + + descriptor_data[0].from_zval = entry->from_array; + from_zval_write_aggregation(arr, (char*)CMSG_DATA(cmsghdr), descriptor_data, ctx); + + *offset += req_space; +} +static void from_zval_write_control_array(const zval *arr, char *msghdr_c, ser_context *ctx) +{ + HashPosition pos; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + zval **elem; + uint32_t i; + int num_elems; + void *control_buf; + zend_llist_element *alloc; + size_t control_len, + cur_offset; + struct msghdr *msg = (struct msghdr*)msghdr_c; + + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + num_elems = zend_hash_num_elements(Z_ARRVAL_P(arr)); + if (num_elems == 0) { + return; + } + + /* estimate each message at 20 bytes */ + control_buf = accounted_safe_ecalloc(num_elems, CMSG_SPACE(20), 0, ctx); + alloc = ctx->allocations.tail; + control_len = (size_t)num_elems * CMSG_SPACE(20); + cur_offset = 0; + + for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 0; + !ctx->err.has_error + && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; + zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos)) { + + if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + from_zval_write_control(*elem, &control_buf, alloc, &control_len, + &cur_offset, ctx); + + zend_llist_remove_tail(&ctx->keys); + } + + msg->msg_control = control_buf; + msg->msg_controllen = cur_offset; /* not control_len, which may be larger */ +} +static void to_zval_read_cmsg_data(const char *cmsghdr_c, zval *zv, res_context *ctx) +{ + const struct cmsghdr *cmsg = (const struct cmsghdr *)cmsghdr_c; + ancillary_reg_entry *entry; + size_t len, + *len_p = &len; + + entry = get_ancillary_reg_entry(cmsg->cmsg_level, cmsg->cmsg_type); + if (entry == NULL) { + do_to_zval_err(ctx, "cmsghdr with level %d and type %d not supported", + cmsg->cmsg_level, cmsg->cmsg_type); + return; + } + if (CMSG_LEN(entry->size) > cmsg->cmsg_len) { + do_to_zval_err(ctx, "the cmsghdr structure is unexpectedly small; " + "expected a length of at least %ld, but got %ld", + (long)CMSG_LEN(entry->size), (long)cmsg->cmsg_len); + return; + } + + len = (size_t)cmsg->cmsg_len; /* use another var because type of cmsg_len varies */ + if (zend_hash_add(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN), + &len_p, sizeof(len_p), NULL) == FAILURE) { + do_to_zval_err(ctx, "%s", "could not set parameter " KEY_CMSG_LEN); + return; + } + + entry->to_array((const char *)CMSG_DATA(cmsg), zv, ctx); + + zend_hash_del(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN)); +} +static void to_zval_read_control(const char *cmsghdr_c, zval *zv, res_context *ctx) +{ + /* takes a cmsghdr, not a msghdr like from_zval_write_control */ + static const field_descriptor descriptors[] = { + {"level", sizeof("level"), 0, offsetof(struct cmsghdr, cmsg_level), 0, to_zval_read_int}, + {"type", sizeof("type"), 0, offsetof(struct cmsghdr, cmsg_type), 0, to_zval_read_int}, + {"data", sizeof("data"), 0, 0 /* cmsghdr passed */, 0, to_zval_read_cmsg_data}, + {0} + }; + + array_init_size(zv, 3); + to_zval_read_aggregation(cmsghdr_c, zv, descriptors, ctx); +} +static void to_zval_read_control_array(const char *msghdr_c, zval *zv, res_context *ctx) +{ + struct msghdr *msg = (struct msghdr *)msghdr_c; + struct cmsghdr *cmsg; + char buf[sizeof("element #4294967295")]; + char *bufp = buf; + uint32_t i = 1; + + /*if (msg->msg_flags & MSG_CTRUNC) { + php_error_docref0(NULL, E_WARNING, "The MSG_CTRUNC flag is present; will not " + "attempt to read control messages"); + ZVAL_FALSE(zv); + return; + }*/ + + array_init(zv); + + for (cmsg = CMSG_FIRSTHDR(msg); + cmsg != NULL && !ctx->err.has_error; + cmsg = CMSG_NXTHDR(msg,cmsg)) { + zval *elem; + + ALLOC_INIT_ZVAL(elem); + add_next_index_zval(zv, elem); + + if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { + memcpy(buf, "element", sizeof("element")); + } + zend_llist_add_element(&ctx->keys, &bufp); + + to_zval_read_control((const char *)cmsg, elem, ctx); + + zend_llist_remove_tail(&ctx->keys); + } +} + +/* CONVERSIONS for msghdr */ +static void from_zval_write_name(const zval *zname_arr, char *msghdr_c, ser_context *ctx) +{ + struct sockaddr *sockaddr; + socklen_t sockaddr_len; + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + + from_zval_write_sockaddr_aux(zname_arr, &sockaddr, &sockaddr_len, ctx); + + msghdr->msg_name = sockaddr; + msghdr->msg_namelen = sockaddr_len; +} +static void to_zval_read_name(const char *sockaddr_p, zval *zv, res_context *ctx) +{ + void *name = (void*)*(void**)sockaddr_p; + if (name == NULL) { + ZVAL_NULL(zv); + } else { + to_zval_read_sockaddr_aux(name, zv, ctx); + } +} +static void from_zval_write_msghdr_buffer_size(const zval *elem, char *msghdr_c, ser_context *ctx) +{ + long lval; + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + + lval = from_zval_integer_common(elem, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > MAX_USER_BUFF_SIZE) { + do_from_zval_err(ctx, "the buffer size must be between 1 and %ld; " + "given %ld", (long)MAX_USER_BUFF_SIZE, lval); + return; + } + + msghdr->msg_iovlen = 1; + msghdr->msg_iov = accounted_emalloc(sizeof(*msghdr->msg_iov) * 1, ctx); + msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)lval, ctx); + msghdr->msg_iov[0].iov_len = (size_t)lval; +} +static void from_zval_write_iov_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) +{ + struct msghdr *msg = args[0]; + size_t len; + + zval_add_ref(elem); + convert_to_string_ex(elem); + + len = Z_STRLEN_PP(elem); + msg->msg_iov[i - 1].iov_base = accounted_emalloc(len, ctx); + msg->msg_iov[i - 1].iov_len = len; + memcpy(msg->msg_iov[i - 1].iov_base, Z_STRVAL_PP(elem), len); + + zval_ptr_dtor(elem); +} +static void from_zval_write_iov_array(const zval *arr, char *msghdr_c, ser_context *ctx) +{ + int num_elem; + struct msghdr *msg = (struct msghdr*)msghdr_c; + + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + num_elem = zend_hash_num_elements(Z_ARRVAL_P(arr)); + if (num_elem == 0) { + return; + } + + msg->msg_iov = accounted_safe_ecalloc(num_elem, sizeof *msg->msg_iov, 0, ctx); + msg->msg_iovlen = (size_t)num_elem; + + from_array_iterate(arr, from_zval_write_iov_array_aux, (void**)&msg, ctx); +} +static void from_zval_write_controllen(const zval *elem, char *msghdr_c, ser_context *ctx) +{ + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + uint32_t len; + + /* controllen should be an unsigned with at least 32-bit. Let's assume + * this least common denominator + */ + from_zval_write_uint32(elem, (char*)&len, ctx); + if (!ctx->err.has_error && len == 0) { + do_from_zval_err(ctx, "controllen cannot be 0"); + return; + } + msghdr->msg_control = accounted_emalloc(len, ctx); + msghdr->msg_controllen = len; +} +void from_zval_write_msghdr_send(const zval *container, char *msghdr_c, ser_context *ctx) +{ + static const field_descriptor descriptors[] = { + {"name", sizeof("name"), 0, 0, from_zval_write_name, 0}, + {"iov", sizeof("iov"), 0, 0, from_zval_write_iov_array, 0}, + {"control", sizeof("control"), 0, 0, from_zval_write_control_array, 0}, + {0} + }; + + from_zval_write_aggregation(container, msghdr_c, descriptors, ctx); +} +void from_zval_write_msghdr_recv(const zval *container, char *msghdr_c, ser_context *ctx) +{ + /* zval to struct msghdr, version for recvmsg(). It differs from the version + * for sendmsg() in that it: + * - has a buffer_size instead of an iov array; + * - has no control element; has a controllen element instead + * struct msghdr { + * void *msg_name; + * socklen_t msg_namelen; + * struct iovec *msg_iov; + * size_t msg_iovlen; + * void *msg_control; + * size_t msg_controllen; //can also be socklen_t + * int msg_flags; + * }; + */ + static const field_descriptor descriptors[] = { + {"name", sizeof("name"), 0, 0, from_zval_write_name, 0}, + {"buffer_size", sizeof("buffer_size"), 0, 0, from_zval_write_msghdr_buffer_size, 0}, + {"controllen", sizeof("controllen"), 1, 0, from_zval_write_controllen, 0}, + {0} + }; + struct msghdr *msghdr = (struct msghdr *)msghdr_c; + const int falsev = 0, + *falsevp = &falsev; + + if (zend_hash_add(&ctx->params, KEY_FILL_SOCKADDR, sizeof(KEY_FILL_SOCKADDR), + (void*)&falsevp, sizeof(falsevp), NULL) == FAILURE) { + do_from_zval_err(ctx, "could not add fill_sockaddr; this is a bug"); + return; + } + + from_zval_write_aggregation(container, msghdr_c, descriptors, ctx); + + zend_hash_del(&ctx->params, KEY_FILL_SOCKADDR, sizeof(KEY_FILL_SOCKADDR)); + if (ctx->err.has_error) { + return; + } + + if (msghdr->msg_iovlen == 0) { + msghdr->msg_iovlen = 1; + msghdr->msg_iov = accounted_emalloc(sizeof(*msghdr->msg_iov) * 1, ctx); + msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)DEFAULT_BUFF_SIZE, ctx); + msghdr->msg_iov[0].iov_len = (size_t)DEFAULT_BUFF_SIZE; + } +} + +static void to_zval_read_iov(const char *msghdr_c, zval *zv, res_context *ctx) +{ + const struct msghdr *msghdr = (const struct msghdr *)msghdr_c; + size_t iovlen = msghdr->msg_iovlen; + ssize_t **recvmsg_ret, + bytes_left; + uint i; + + if (iovlen > UINT_MAX) { + do_to_zval_err(ctx, "unexpectedly large value for iov_len: %lu", + (unsigned long)iovlen); + } + array_init_size(zv, (uint)iovlen); + + if (zend_hash_find(&ctx->params, KEY_RECVMSG_RET, sizeof(KEY_RECVMSG_RET), + (void**)&recvmsg_ret) == FAILURE) { + do_to_zval_err(ctx, "recvmsg_ret not found in params. This is a bug"); + return; + } + bytes_left = **recvmsg_ret; + + for (i = 0; bytes_left > 0 && i < (uint)iovlen; i++) { + zval *elem; + size_t len = MIN(msghdr->msg_iov[i].iov_len, bytes_left); + char *buf = safe_emalloc(1, len, 1); + + MAKE_STD_ZVAL(elem); + memcpy(buf, msghdr->msg_iov[i].iov_base, len); + buf[len] = '\0'; + + ZVAL_STRINGL(elem, buf, len, 0); + add_next_index_zval(zv, elem); + bytes_left -= len; + } +} +void to_zval_read_msghdr(const char *msghdr_c, zval *zv, res_context *ctx) +{ + static const field_descriptor descriptors[] = { + {"name", sizeof("name"), 0, offsetof(struct msghdr, msg_name), 0, to_zval_read_name}, + {"control", sizeof("control"), 0, 0, 0, to_zval_read_control_array}, + {"iov", sizeof("iov"), 0, 0, 0, to_zval_read_iov}, + {"flags", sizeof("flags"), 0, offsetof(struct msghdr, msg_flags), 0, to_zval_read_int}, + {0} + }; + + array_init_size(zv, 4); + + to_zval_read_aggregation(msghdr_c, zv, descriptors, ctx); +} + +/* CONVERSIONS for if_index */ +static void from_zval_write_ifindex(const zval *zv, char *uinteger, ser_context *ctx) +{ + zval *va; unsigned *out; + unsigned ret; + zval lzval = zval_used_for_init; + + if (Z_TYPE_P(zv) == IS_LONG) { + if (Z_LVAL_P(zv) < 0 || Z_LVAL_P(zv) > UINT_MAX) { + do_from_zval_err(ctx, "the interface index cannot be negative or " + "larger than %u; given %ld", UINT_MAX, Z_LVAL_P(zv)); + } else { + ret = (unsigned)Z_LVAL_P(zv); + } + } else { +#if HAVE_IF_NAMETOINDEX + + if (Z_TYPE_P(zv) != IS_STRING) { + ZVAL_COPY_VALUE(&lzval, zv); + zval_copy_ctor(&lzval); + convert_to_string(&lzval); + zv = &lzval; + } + + ret = if_nametoindex(Z_STRVAL_P(zv)); + if (ret == 0) { + do_from_zval_err(ctx, "no interface with name \"%s\" could be " + "found", Z_STRVAL_P(zv)); + } +#else + do_from_zval_err(ctx, + "this platform does not support looking up an interface by " + "name, an integer interface index must be supplied instead"); +#endif + } + + if (!ctx->err.has_error) { + memcpy(uinteger, &ret, sizeof(ret)); + } + + zval_dtor(&lzval); +} + +/* CONVERSIONS for struct in6_pktinfo */ +#ifdef IPV6_PKTINFO +static const field_descriptor descriptors_in6_pktinfo[] = { + {"addr", sizeof("addr"), 1, offsetof(struct in6_pktinfo, ipi6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, + {"ifindex", sizeof("ifindex"), 1, offsetof(struct in6_pktinfo, ipi6_ifindex), from_zval_write_unsigned, to_zval_read_unsigned}, + {0} +}; +void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx) +{ + from_zval_write_aggregation(container, in6_pktinfo_c, descriptors_in6_pktinfo, ctx); +} +void to_zval_read_in6_pktinfo(const char *data, zval *zv, res_context *ctx) +{ + array_init_size(zv, 2); + + to_zval_read_aggregation(data, zv, descriptors_in6_pktinfo, ctx); +} +#endif + +/* CONVERSIONS for struct ucred */ +#ifdef SO_PASSCRED +static const field_descriptor descriptors_ucred[] = { + {"pid", sizeof("pid"), 1, offsetof(struct ucred, pid), from_zval_write_pid_t, to_zval_read_pid_t}, + {"uid", sizeof("uid"), 1, offsetof(struct ucred, uid), from_zval_write_uid_t, to_zval_read_uid_t}, + /* assume the type gid_t is the same as uid_t: */ + {"gid", sizeof("gid"), 1, offsetof(struct ucred, gid), from_zval_write_uid_t, to_zval_read_uid_t}, + {0} +}; +void from_zval_write_ucred(const zval *container, char *ucred_c, ser_context *ctx) +{ + from_zval_write_aggregation(container, ucred_c, descriptors_ucred, ctx); +} +void to_zval_read_ucred(const char *data, zval *zv, res_context *ctx) +{ + array_init_size(zv, 3); + + to_zval_read_aggregation(data, zv, descriptors_ucred, ctx); +} +#endif + +/* CONVERSIONS for SCM_RIGHTS */ +#ifdef SCM_RIGHTS +size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx) +{ + int num_elems; + + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return (size_t)-1; + } + + num_elems = zend_hash_num_elements(Z_ARRVAL_P(arr)); + if (num_elems == 0) { + do_from_zval_err(ctx, "%s", "expected at least one element in this array"); + return (size_t)-1; + } + + return zend_hash_num_elements(Z_ARRVAL_P(arr)) * sizeof(int); +} +static void from_zval_write_fd_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) +{ + int *iarr = args[0]; + + if (Z_TYPE_PP(elem) == IS_RESOURCE) { + php_stream *stream; + php_socket *sock; + + ZEND_FETCH_RESOURCE_NO_RETURN(sock, php_socket *, elem, -1, + NULL, php_sockets_le_socket()); + if (sock) { + iarr[i] = sock->bsd_socket; + return; + } + + ZEND_FETCH_RESOURCE2_NO_RETURN(stream, php_stream *, elem, -1, + NULL, php_file_le_stream(), php_file_le_pstream()); + if (stream == NULL) { + do_from_zval_err(ctx, "resource is not a stream or a socket"); + return; + } + + if (php_stream_cast(stream, PHP_STREAM_AS_FD, (void **)&iarr[i], + REPORT_ERRORS) == FAILURE) { + do_from_zval_err(ctx, "cast stream to file descriptor failed"); + return; + } + } else { + do_from_zval_err(ctx, "expected a resource variable"); + } +} +void from_zval_write_fd_array(const zval *arr, char *int_arr, ser_context *ctx) +{ + if (Z_TYPE_P(arr) != IS_ARRAY) { + do_from_zval_err(ctx, "%s", "expected an array here"); + return; + } + + from_array_iterate(arr, &from_zval_write_fd_array_aux, (void**)&int_arr, ctx); +} +void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx) +{ + size_t **cmsg_len; + int num_elems, + i; + struct cmsghdr *dummy_cmsg = 0; + size_t data_offset; + TSRMLS_FETCH(); + + data_offset = (unsigned char *)CMSG_DATA(dummy_cmsg) + - (unsigned char *)dummy_cmsg; + + if (zend_hash_find(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN), + (void **)&cmsg_len) == FAILURE) { + do_to_zval_err(ctx, "could not get value of parameter " KEY_CMSG_LEN); + return; + } + + if (**cmsg_len < data_offset) { + do_to_zval_err(ctx, "length of cmsg is smaller than its data member " + "offset (%ld vs %ld)", (long)**cmsg_len, (long)data_offset); + return; + } + num_elems = (**cmsg_len - data_offset) / sizeof(int); + + array_init_size(zv, num_elems); + + for (i = 0; i < num_elems; i++) { + zval *elem; + int fd; + struct stat statbuf; + + MAKE_STD_ZVAL(elem); + + fd = *((int *)data + i); + + /* determine whether we have a socket */ + if (fstat(fd, &statbuf) == -1) { + do_to_zval_err(ctx, "error creating resource for received file " + "descriptor %d: fstat() call failed with errno %d", fd, errno); + efree(elem); + return; + } + if (S_ISSOCK(statbuf.st_mode)) { + php_socket *sock = socket_import_file_descriptor(fd); + zend_register_resource(elem, sock, php_sockets_le_socket()); + } else { + php_stream *stream = php_stream_fopen_from_fd(fd, "rw", NULL); + php_stream_to_zval(stream, elem); + } + + add_next_index_zval(zv, elem); + } +} +#endif + +/* ENTRY POINT for conversions */ +static void free_from_zval_allocation(void *alloc_ptr_ptr) +{ + efree(*(void**)alloc_ptr_ptr); +} +void *from_zval_run_conversions(const zval *container, + php_socket *sock, + from_zval_write_field *writer, + size_t struct_size, + const char *top_name, + zend_llist **allocations /* out */, + struct err_s *err /* in/out */) +{ + ser_context ctx = {{0}}; + char *structure = NULL; + + *allocations = NULL; + + if (err->has_error) { + return NULL; + } + + zend_hash_init(&ctx.params, 8, NULL, NULL, 0); + zend_llist_init(&ctx.keys, sizeof(const char *), NULL, 0); + zend_llist_init(&ctx.allocations, sizeof(void *), &free_from_zval_allocation, 0); + ctx.sock = sock; + + structure = ecalloc(1, struct_size); + + zend_llist_add_element(&ctx.keys, &top_name); + zend_llist_add_element(&ctx.allocations, &structure); + + /* main call */ + writer(container, structure, &ctx); + + if (ctx.err.has_error) { + zend_llist_destroy(&ctx.allocations); /* deallocates structure as well */ + structure = NULL; + *err = ctx.err; + } else { + *allocations = emalloc(sizeof **allocations); + **allocations = ctx.allocations; + } + + zend_llist_destroy(&ctx.keys); + zend_hash_destroy(&ctx.params); + + return structure; +} +zval *to_zval_run_conversions(const char *structure, + to_zval_read_field *reader, + const char *top_name, + const struct key_value *key_value_pairs, + struct err_s *err) +{ + res_context ctx = {{0}, {0}}; + const struct key_value *kv; + zval *zv = NULL; + + if (err->has_error) { + return NULL; + } + + ALLOC_INIT_ZVAL(zv); + + zend_llist_init(&ctx.keys, sizeof(const char *), NULL, 0); + zend_llist_add_element(&ctx.keys, &top_name); + + zend_hash_init(&ctx.params, 8, NULL, NULL, 0); + for (kv = key_value_pairs; kv->key != NULL; kv++) { + zend_hash_update(&ctx.params, kv->key, kv->key_size, + (void*)&kv->value, sizeof(kv->value), NULL); + } + + /* main call */ + reader(structure, zv, &ctx); + + if (ctx.err.has_error) { + zval_ptr_dtor(&zv); + zv = NULL; + *err = ctx.err; + } + + zend_llist_destroy(&ctx.keys); + zend_hash_destroy(&ctx.params); + + return zv; +} diff --git a/ext/sockets/conversions.h b/ext/sockets/conversions.h new file mode 100644 index 0000000000000..70f31ba676e56 --- /dev/null +++ b/ext/sockets/conversions.h @@ -0,0 +1,78 @@ +#ifndef PHP_SOCK_CONVERSIONS_H +#define PHP_SOCK_CONVERSIONS_H 1 + +#include +#include +#include +#include "php_sockets.h" + +/* TYPE DEFINITIONS */ +struct err_s { + int has_error; + char *msg; + int level; + int should_free; +}; + +struct key_value { + const char *key; + unsigned key_size; + void *value; +}; + +/* the complete types of these two are not relevant to the outside */ +typedef struct _ser_context ser_context; +typedef struct _res_context res_context; + +#define KEY_RECVMSG_RET "recvmsg_ret" + +typedef void (from_zval_write_field)(const zval *arr_value, char *field, ser_context *ctx); +typedef void (to_zval_read_field)(const char *data, zval *zv, res_context *ctx); + +/* VARIABLE DECLARATIONS */ +extern const struct key_value empty_key_value_list[]; + +/* AUX FUNCTIONS */ +void err_msg_dispose(struct err_s *err TSRMLS_DC); +void allocations_dispose(zend_llist **allocations); + +/* CONVERSION FUNCTIONS */ +void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx); +void to_zval_read_int(const char *data, zval *zv, res_context *ctx); + +#ifdef IPV6_PKTINFO +void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx); +void to_zval_read_in6_pktinfo(const char *data, zval *zv, res_context *ctx); +#endif + +#ifdef SO_PASSCRED +void from_zval_write_ucred(const zval *container, char *ucred_c, ser_context *ctx); +void to_zval_read_ucred(const char *data, zval *zv, res_context *ctx); +#endif + +#ifdef SCM_RIGHTS +size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx); +void from_zval_write_fd_array(const zval *arr, char *int_arr, ser_context *ctx); +void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx); +#endif + +void from_zval_write_msghdr_send(const zval *container, char *msghdr_c, ser_context *ctx); +void from_zval_write_msghdr_recv(const zval *container, char *msghdr_c, ser_context *ctx); +void to_zval_read_msghdr(const char *msghdr_c, zval *zv, res_context *ctx); + +/* ENTRY POINTS FOR CONVERSIONS */ +void *from_zval_run_conversions(const zval *container, + php_socket *sock, + from_zval_write_field *writer, + size_t struct_size, + const char *top_name, + zend_llist **allocations /* out */, + struct err_s *err /* in/out */); + +zval *to_zval_run_conversions(const char *structure, + to_zval_read_field *reader, + const char *top_name, + const struct key_value *key_value_pairs, + struct err_s *err); + +#endif diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 6b1a528c5b1df..6479bf90a850d 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -18,18 +18,10 @@ #include #include "php_sockets.h" -#include "sockaddr_conv.h" #include "sendrecvmsg.h" -#include -#include -#include -#include +#include "conversions.h" #include -#include -#include -#include #include -#include #ifdef ZTS #include #endif @@ -47,1460 +39,11 @@ } \ } while (0) -struct err_s { - int has_error; - char *msg; - int level; - int should_free; -}; - -typedef struct { - HashTable params; /* stores pointers; has to be first */ - struct err_s err; - zend_llist keys, - /* common part to res_context ends here */ - allocations; - php_socket *sock; -} ser_context; - -typedef struct { - HashTable params; /* stores pointers; has to be first */ - struct err_s err; - zend_llist keys; -} res_context; - -struct key_value { - const char *key; - unsigned key_size; - void *value; -}; -#define KEY_FILL_SOCKADDR "fill_sockaddr" -#define KEY_RECVMSG_RET "recvmsg_ret" -#define KEY_CMSG_LEN "cmsg_len" -static const struct key_value empty_key_value_list[] = {{0}}; - - -typedef void (from_zval_write_field)(const zval *arr_value, char *field, ser_context *ctx); -typedef void (to_zval_read_field)(const char *data, zval *zv, res_context *ctx); -typedef size_t (calculate_req_space)(const zval *value, ser_context *ctx); - -typedef struct { - /* zval info */ - const char *name; - unsigned name_size; - int required; - - /* structure info */ - size_t field_offset; /* 0 to pass full structure, e.g. when more than - one field is to be changed; in that case the - callbacks need to know the name of the fields */ - - /* callbacks */ - from_zval_write_field *from_zval; - to_zval_read_field *to_zval; -} field_descriptor; - -typedef struct { - int cmsg_level; /* originating protocol */ - int cmsg_type; /* protocol-specific type */ -} anc_reg_key; - static struct { int initialized; HashTable ht; } ancillary_registry; -typedef socklen_t (*ancillary_size)(void); - -typedef struct { - socklen_t size; /* size of native structure */ - socklen_t var_el_size; /* size of repeatable component */ - calculate_req_space *calc_space; - from_zval_write_field *from_array; - to_zval_read_field *to_array; -} ancillary_reg_entry; - -/* PARAMETERS */ -static int param_get_bool(void *ctx, const char *key, int def) -{ - int **elem; - if (zend_hash_find(ctx, key, strlen(key) + 1, (void**)&elem) == SUCCESS) { - return **elem; - } else { - return def; - } -} - -/* FORWARD DECLARATIONS */ -static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type); - -static inline void *accounted_emalloc(size_t alloc_size, ser_context *ctx) -{ - void *ret = emalloc(alloc_size); - zend_llist_add_element(&ctx->allocations, &ret); - return ret; -} - -static inline void *accounted_ecalloc(size_t nmemb, size_t alloc_size, ser_context *ctx) -{ - void *ret = ecalloc(nmemb, alloc_size); - zend_llist_add_element(&ctx->allocations, &ret); - return ret; -} -static inline void *accounted_safe_ecalloc(size_t nmemb, size_t alloc_size, size_t offset, ser_context *ctx) -{ - void *ret = safe_emalloc(nmemb, alloc_size, offset); - memset(ret, '\0', nmemb * alloc_size + offset); - zend_llist_add_element(&ctx->allocations, &ret); - return ret; -} - -static void do_from_to_zval_err(struct err_s *err, - zend_llist *keys, - const char *what_conv, - const char *fmt, - va_list ap) -{ - smart_str path = {0}; - const char **node; - char *user_msg; - int user_msg_size; - zend_llist_position pos; - - if (err->has_error) { - return; - } - - for (node = zend_llist_get_first_ex(keys, &pos); - node != NULL; - node = zend_llist_get_next_ex(keys, &pos)) { - smart_str_appends(&path, *node); - smart_str_appends(&path, " > "); - } - - if (path.len > 3) { - path.len -= 3; - } - smart_str_0(&path); - - user_msg_size = vspprintf(&user_msg, 0, fmt, ap); - - err->has_error = 1; - err->level = E_WARNING; - spprintf(&err->msg, 0, "error converting %s data (path: %s): %.*s", - what_conv, - path.c && path.c != '\0' ? path.c : "unavailable", - user_msg_size, user_msg); - err->should_free = 1; - - efree(user_msg); - smart_str_free_ex(&path, 0); -} -__attribute__ ((format (printf, 2, 3))) -static void do_from_zval_err(ser_context *ctx, const char *fmt, ...) -{ - va_list ap; - - va_start(ap, fmt); - do_from_to_zval_err(&ctx->err, &ctx->keys, "user", fmt, ap); - va_end(ap); -} -__attribute__ ((format (printf, 2, 3))) -static void do_to_zval_err(res_context *ctx, const char *fmt, ...) -{ - va_list ap; - - va_start(ap, fmt); - do_from_to_zval_err(&ctx->err, &ctx->keys, "native", fmt, ap); - va_end(ap); -} -static void err_msg_dispose(struct err_s *err TSRMLS_DC) -{ - if (err->msg != NULL) { - php_error_docref0(NULL TSRMLS_CC, err->level, "%s", err->msg); - if (err->should_free) { - efree(err->msg); - } - } -} -static void allocations_dispose(zend_llist **allocations) -{ - zend_llist_destroy(*allocations); - efree(*allocations); - *allocations = NULL; -} - -static unsigned from_array_iterate(const zval *arr, - void (*func)(zval **elem, unsigned i, void **args, ser_context *ctx), - void **args, - ser_context *ctx) -{ - HashPosition pos; - unsigned i; - zval **elem; - char buf[sizeof("element #4294967295")]; - char *bufp = buf; - - for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 1; - !ctx->err.has_error - && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; - zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos), i++) { - if (snprintf(buf, sizeof(buf), "element #%u", i) >= sizeof(buf)) { - memcpy(buf, "element", sizeof("element")); - } - zend_llist_add_element(&ctx->keys, &bufp); - - func(elem, i, args, ctx); - - zend_llist_remove_tail(&ctx->keys); - } - - return i -1; -} - -/* Generic Aggregated conversions */ -static void from_zval_write_aggregation(const zval *container, - char *structure, - const field_descriptor *descriptors, - ser_context *ctx) -{ - const field_descriptor *descr; - zval **elem; - - if (Z_TYPE_P(container) != IS_ARRAY) { - do_from_zval_err(ctx, "%s", "expected an array here"); - } - - for (descr = descriptors; descr->name != NULL && !ctx->err.has_error; descr++) { - if (zend_hash_find(Z_ARRVAL_P(container), - descr->name, descr->name_size, (void**)&elem) == SUCCESS) { - - if (descr->from_zval == NULL) { - do_from_zval_err(ctx, "No information on how to convert value " - "of key '%s'", descr->name); - break; - } - - zend_llist_add_element(&ctx->keys, (void*)&descr->name); - descr->from_zval(*elem, ((char*)structure) + descr->field_offset, ctx); - zend_llist_remove_tail(&ctx->keys); - - } else if (descr->required) { - do_from_zval_err(ctx, "The key '%s' is required", descr->name); - break; - } - } -} -static void to_zval_read_aggregation(const char *structure, - zval *zarr, /* initialized array */ - const field_descriptor *descriptors, - res_context *ctx) -{ - const field_descriptor *descr; - - assert(Z_TYPE_P(zarr) == IS_ARRAY); - assert(Z_ARRVAL_P(zarr) != NULL); - - for (descr = descriptors; descr->name != NULL && !ctx->err.has_error; descr++) { - zval *new_zv; - - if (descr->to_zval == NULL) { - do_to_zval_err(ctx, "No information on how to convert native " - "field into value for key '%s'", descr->name); - break; - } - - ALLOC_INIT_ZVAL(new_zv); - add_assoc_zval_ex(zarr, descr->name, descr->name_size, new_zv); - - zend_llist_add_element(&ctx->keys, (void*)&descr->name); - descr->to_zval(structure + descr->field_offset, new_zv, ctx); - zend_llist_remove_tail(&ctx->keys); - } -} - -/* CONVERSIONS for integers */ -static long from_zval_integer_common(const zval *arr_value, ser_context *ctx) -{ - long ret = 0; - zval lzval = zval_used_for_init; - - if (Z_TYPE_P(arr_value) != IS_LONG) { - ZVAL_COPY_VALUE(&lzval, arr_value); - zval_copy_ctor(&lzval); - arr_value = &lzval; - } - - switch (Z_TYPE_P(arr_value)) { - case IS_LONG: -long_case: - ret = Z_LVAL_P(arr_value); - break; - - /* if not long we're operating on lzval */ - case IS_DOUBLE: -double_case: - convert_to_long(&lzval); - goto long_case; - - case IS_OBJECT: - case IS_STRING: { - long lval; - double dval; - - convert_to_string(&lzval); - - switch (is_numeric_string(Z_STRVAL(lzval), Z_STRLEN(lzval), &lval, &dval, 0)) { - case IS_DOUBLE: - zval_dtor(&lzval); - Z_TYPE(lzval) = IS_DOUBLE; - Z_DVAL(lzval) = dval; - goto double_case; - - case IS_LONG: - zval_dtor(&lzval); - Z_TYPE(lzval) = IS_LONG; - Z_DVAL(lzval) = lval; - goto long_case; - } - - /* if we get here, we don't have a numeric string */ - do_from_zval_err(ctx, "expected an integer, but got a non numeric " - "string (possibly from a converted object): '%s'", Z_STRVAL_P(arr_value)); - break; - } - - default: - do_from_zval_err(ctx, "%s", "expected an integer, either of a PHP " - "integer type or of a convertible type"); - break; - } - - zval_dtor(&lzval); - - return ret; -} -static void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - int ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (lval > INT_MAX || lval < INT_MIN) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a native int"); - return; - } - - ival = (int)lval; - memcpy(field, &ival, sizeof(ival)); -} -static void from_zval_write_unsigned(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - unsigned ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (sizeof(long) > sizeof(ival) && (lval < 0 || lval > UINT_MAX)) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a native unsigned int"); - return; - } - - ival = (unsigned)lval; - memcpy(field, &ival, sizeof(ival)); -} -static void from_zval_write_uint32(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - uint32_t ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (sizeof(long) > sizeof(uint32_t) && (lval < 0 || lval > 0xFFFFFFFF)) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for an unsigned 32-bit integer"); - return; - } - - ival = (uint32_t)lval; - memcpy(field, &ival, sizeof(ival)); -} -static void from_zval_write_net_uint16(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - uint16_t ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (lval < 0 || lval > 0xFFFF) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for an unsigned 16-bit integer"); - return; - } - - ival = htons((uint16_t)lval); - memcpy(field, &ival, sizeof(ival)); -} -static void from_zval_write_sa_family(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - sa_family_t ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (lval < 0 || lval > (sa_family_t)-1) { /* sa_family_t is unsigned */ - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a sa_family_t value"); - return; - } - - ival = (sa_family_t)lval; - memcpy(field, &ival, sizeof(ival)); -} -static void from_zval_write_pid_t(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - pid_t ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (lval < 0 || (pid_t)lval != lval) { /* pid_t is signed */ - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a pid_t value"); - return; - } - - ival = (pid_t)lval; - memcpy(field, &ival, sizeof(ival)); -} -static void from_zval_write_uid_t(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - uid_t ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - /* uid_t can be signed or unsigned (generally unsigned) */ - if ((uid_t)-1 > (uid_t)0) { - if (sizeof(long) > sizeof(uid_t) && (lval < 0 || (uid_t)lval != lval)) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a uid_t value"); - return; - } - } else { - if (sizeof(long) > sizeof(uid_t) && (uid_t)lval != lval) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a uid_t value"); - return; - } - } - - ival = (uid_t)lval; - memcpy(field, &ival, sizeof(ival)); -} - -static void to_zval_read_int(const char *data, zval *zv, res_context *ctx) -{ - int ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} -static void to_zval_read_unsigned(const char *data, zval *zv, res_context *ctx) -{ - unsigned ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} -static void to_zval_read_net_uint16(const char *data, zval *zv, res_context *ctx) -{ - uint16_t ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ntohs(ival)); -} -static void to_zval_read_uint32(const char *data, zval *zv, res_context *ctx) -{ - uint32_t ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} -static void to_zval_read_sa_family(const char *data, zval *zv, res_context *ctx) -{ - sa_family_t ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} -static void to_zval_read_pid_t(const char *data, zval *zv, res_context *ctx) -{ - pid_t ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} -static void to_zval_read_uid_t(const char *data, zval *zv, res_context *ctx) -{ - uid_t ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} - -/* CONVERSIONS for sockaddr */ -static void from_zval_write_sin_addr(const zval *zaddr_str, char *inaddr, ser_context *ctx) -{ - int res; - struct sockaddr_in saddr = {0}; - zval lzval = zval_used_for_init; - TSRMLS_FETCH(); - - if (Z_TYPE_P(zaddr_str) != IS_STRING) { - ZVAL_COPY_VALUE(&lzval, zaddr_str); - zval_copy_ctor(&lzval); - convert_to_string(&lzval); - zaddr_str = &lzval; - } - - res = php_set_inet_addr(&saddr, Z_STRVAL_P(zaddr_str), ctx->sock TSRMLS_CC); - if (res) { - memcpy(inaddr, &saddr.sin_addr, sizeof saddr.sin_addr); - } else { - /* error already emitted, but let's emit another more relevant */ - do_from_zval_err(ctx, "could not resolve address '%s' to get an AF_INET " - "address", Z_STRVAL_P(zaddr_str)); - } - - zval_dtor(&lzval); -} -static void to_zval_read_sin_addr(const char *data, zval *zv, res_context *ctx) -{ - const struct in_addr *addr = (const struct in_addr *)data; - socklen_t size = INET_ADDRSTRLEN; - - Z_TYPE_P(zv) = IS_STRING; - Z_STRVAL_P(zv) = ecalloc(1, size); - Z_STRLEN_P(zv) = 0; - - if (inet_ntop(AF_INET, addr, Z_STRVAL_P(zv), size) == NULL) { - do_to_zval_err(ctx, "could not convert IPv4 address to string " - "(errno %d)", errno); - return; - } - - Z_STRLEN_P(zv) = strlen(Z_STRVAL_P(zv)); -} -static const field_descriptor descriptors_sockaddr_in[] = { - {"family", sizeof("family"), 0, offsetof(struct sockaddr_in, sin_family), from_zval_write_sa_family, to_zval_read_sa_family}, - {"addr", sizeof("addr"), 0, offsetof(struct sockaddr_in, sin_addr), from_zval_write_sin_addr, to_zval_read_sin_addr}, - {"port", sizeof("port"), 0, offsetof(struct sockaddr_in, sin_port), from_zval_write_net_uint16, to_zval_read_net_uint16}, - {0} -}; -static void from_zval_write_sockaddr_in(const zval *container, char *sockaddr, ser_context *ctx) -{ - from_zval_write_aggregation(container, sockaddr, descriptors_sockaddr_in, ctx); -} -static void to_zval_read_sockaddr_in(const char *data, zval *zv, res_context *ctx) -{ - to_zval_read_aggregation(data, zv, descriptors_sockaddr_in, ctx); -} -static void from_zval_write_sin6_addr(const zval *zaddr_str, char *addr6, ser_context *ctx) -{ - int res; - struct sockaddr_in6 saddr6 = {0}; - zval lzval = zval_used_for_init; - TSRMLS_FETCH(); - - if (Z_TYPE_P(zaddr_str) != IS_STRING) { - ZVAL_COPY_VALUE(&lzval, zaddr_str); - zval_copy_ctor(&lzval); - convert_to_string(&lzval); - zaddr_str = &lzval; - } - - res = php_set_inet6_addr(&saddr6, - Z_STRVAL_P(zaddr_str), ctx->sock TSRMLS_CC); - if (res) { - memcpy(addr6, &saddr6.sin6_addr, sizeof saddr6.sin6_addr); - } else { - /* error already emitted, but let's emit another more relevant */ - do_from_zval_err(ctx, "could not resolve address '%s' to get an AF_INET6 " - "address", Z_STRVAL_P(zaddr_str)); - } - - zval_dtor(&lzval); -} -static void to_zval_read_sin6_addr(const char *data, zval *zv, res_context *ctx) -{ - const struct in6_addr *addr = (const struct in6_addr *)data; - socklen_t size = INET6_ADDRSTRLEN; - - Z_TYPE_P(zv) = IS_STRING; - Z_STRVAL_P(zv) = ecalloc(1, size); - Z_STRLEN_P(zv) = 0; - - if (inet_ntop(AF_INET6, addr, Z_STRVAL_P(zv), size) == NULL) { - do_to_zval_err(ctx, "could not convert IPv6 address to string " - "(errno %d)", errno); - return; - } - - Z_STRLEN_P(zv) = strlen(Z_STRVAL_P(zv)); -} -static const field_descriptor descriptors_sockaddr_in6[] = { - {"family", sizeof("family"), 0, offsetof(struct sockaddr_in6, sin6_family), from_zval_write_sa_family, to_zval_read_sa_family}, - {"addr", sizeof("addr"), 0, offsetof(struct sockaddr_in6, sin6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, - {"port", sizeof("port"), 0, offsetof(struct sockaddr_in6, sin6_port), from_zval_write_net_uint16, to_zval_read_net_uint16}, - {"flowinfo", sizeof("flowinfo"), 0, offsetof(struct sockaddr_in6, sin6_flowinfo), from_zval_write_uint32, to_zval_read_uint32}, - {"scope_id", sizeof("scope_id"), 0, offsetof(struct sockaddr_in6, sin6_scope_id), from_zval_write_uint32, to_zval_read_uint32}, - {0} -}; -static void from_zval_write_sockaddr_in6(const zval *container, char *sockaddr6, ser_context *ctx) -{ - from_zval_write_aggregation(container, sockaddr6, descriptors_sockaddr_in6, ctx); -} -static void to_zval_read_sockaddr_in6(const char *data, zval *zv, res_context *ctx) -{ - to_zval_read_aggregation(data, zv, descriptors_sockaddr_in6, ctx); -} -static void from_zval_write_sun_path(const zval *path, char *sockaddr_un_c, ser_context *ctx) -{ - zval lzval = zval_used_for_init; - struct sockaddr_un *saddr = (struct sockaddr_un*)sockaddr_un_c; - - if (Z_TYPE_P(path) != IS_STRING) { - ZVAL_COPY_VALUE(&lzval, path); - zval_copy_ctor(&lzval); - convert_to_string(&lzval); - path = &lzval; - } - - if (Z_STRLEN_P(path) >= sizeof(saddr->sun_path)) { - do_from_zval_err(ctx, "the path is too long, the maximum permitted " - "length is %ld", sizeof(saddr->sun_path) - 1); - return; - } - - memcpy(&saddr->sun_path, Z_STRVAL_P(path), Z_STRLEN_P(path)); - saddr->sun_path[Z_STRLEN_P(path)] = '\0'; - - zval_dtor(&lzval); -} -static void to_zval_read_sun_path(const char *data, zval *zv, res_context *ctx) { - struct sockaddr_un *saddr = (struct sockaddr_un*)data; - char *nul_pos; - - nul_pos = memchr(&saddr->sun_path, '\0', sizeof(saddr->sun_path)); - if (nul_pos == NULL) { - do_to_zval_err(ctx, "could not find a NUL in the path"); - return; - } - - ZVAL_STRINGL(zv, saddr->sun_path, nul_pos - (char*)&saddr->sun_path, 1); -} -static const field_descriptor descriptors_sockaddr_un[] = { - {"family", sizeof("family"), 0, offsetof(struct sockaddr_un, sun_family), from_zval_write_sa_family, to_zval_read_sa_family}, - {"path", sizeof("path"), 0, 0, from_zval_write_sun_path, to_zval_read_sun_path}, - {0} -}; -static void from_zval_write_sockaddr_un(const zval *container, char *sockaddr, ser_context *ctx) -{ - from_zval_write_aggregation(container, sockaddr, descriptors_sockaddr_un, ctx); -} -static void to_zval_read_sockaddr_un(const char *data, zval *zv, res_context *ctx) -{ - to_zval_read_aggregation(data, zv, descriptors_sockaddr_un, ctx); -} -static void from_zval_write_sockaddr_aux(const zval *container, - struct sockaddr **sockaddr_ptr, - socklen_t *sockaddr_len, - ser_context *ctx) -{ - int family; - zval **elem; - int fill_sockaddr; - - if (Z_TYPE_P(container) != IS_ARRAY) { - do_from_zval_err(ctx, "%s", "expected an array here"); - return; - } - - fill_sockaddr = param_get_bool(ctx, KEY_FILL_SOCKADDR, 1); - - if (zend_hash_find(Z_ARRVAL_P(container), "family", sizeof("family"), (void**)&elem) == SUCCESS - && Z_TYPE_PP(elem) != IS_NULL) { - const char *node = "family"; - zend_llist_add_element(&ctx->keys, &node); - from_zval_write_int(*elem, (char*)&family, ctx); - zend_llist_remove_tail(&ctx->keys); - } else { - family = ctx->sock->type; - } - - switch (family) { - case AF_INET: - /* though not all OSes support sockaddr_in used in IPv6 sockets */ - if (ctx->sock->type != AF_INET && ctx->sock->type != AF_INET6) { - do_from_zval_err(ctx, "the specified family (number %d) is not " - "supported on this socket", family); - return; - } - *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_in), ctx); - *sockaddr_len = sizeof(struct sockaddr_in); - if (fill_sockaddr) { - from_zval_write_sockaddr_in(container, (char*)*sockaddr_ptr, ctx); - (*sockaddr_ptr)->sa_family = AF_INET; - } - break; - - case AF_INET6: - if (ctx->sock->type != AF_INET6) { - do_from_zval_err(ctx, "the specified family (AF_INET6) is not " - "supported on this socket"); - return; - } - *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_in6), ctx); - *sockaddr_len = sizeof(struct sockaddr_in6); - if (fill_sockaddr) { - from_zval_write_sockaddr_in6(container, (char*)*sockaddr_ptr, ctx); - (*sockaddr_ptr)->sa_family = AF_INET6; - } - break; - - case AF_UNIX: - if (ctx->sock->type != AF_UNIX) { - do_from_zval_err(ctx, "the specified family (AF_UNIX) is not " - "supported on this socket"); - return; - } - *sockaddr_ptr = accounted_ecalloc(1, sizeof(struct sockaddr_un), ctx); - *sockaddr_len = sizeof(struct sockaddr_un); - if (fill_sockaddr) { - from_zval_write_sockaddr_un(container, (char*)*sockaddr_ptr, ctx); - (*sockaddr_ptr)->sa_family = AF_UNIX; - } - break; - - default: - do_from_zval_err(ctx, "%s", "the only families currently supported are " - "AF_INET, AF_INET6 and AF_UNIX"); - break; - } -} -static void to_zval_read_sockaddr_aux(const char *sockaddr_c, zval *zv, res_context *ctx) -{ - const struct sockaddr *saddr = (struct sockaddr *)sockaddr_c; - - if (saddr->sa_family == 0) { - ZVAL_NULL(zv); - return; - } - - array_init(zv); - - switch (saddr->sa_family) { - case AF_INET: - to_zval_read_sockaddr_in(sockaddr_c, zv, ctx); - break; - - case AF_INET6: - to_zval_read_sockaddr_in6(sockaddr_c, zv, ctx); - break; - - case AF_UNIX: - to_zval_read_sockaddr_un(sockaddr_c, zv, ctx); - break; - - default: - do_to_zval_err(ctx, "cannot read struct sockaddr with family %d; " - "not supported", - (int)saddr->sa_family); - break; - } -} - -/* CONVERSIONS for cmsghdr */ -/* - * [ level => , type => , data => [],] - * struct cmsghdr { - * socklen_t cmsg_len; // data byte count, including header - * int cmsg_level; // originating protocol - * int cmsg_type; // protocol-specific type - * // followed by unsigned char cmsg_data[]; - * }; - */ -static void from_zval_write_control(const zval *arr, - void **control_buf, - zend_llist_element *alloc, - size_t *control_len, - size_t *offset, - ser_context *ctx) -{ - struct cmsghdr *cmsghdr; - int level, - type; - size_t data_len, - req_space, - space_left; - ancillary_reg_entry *entry; - - static const field_descriptor descriptor_level[] = { - {"level", sizeof("level"), 0, 0, from_zval_write_int, 0}, - {0} - }; - static const field_descriptor descriptor_type[] = { - {"type", sizeof("type"), 0, 0, from_zval_write_int, 0}, - {0} - }; - field_descriptor descriptor_data[] = { - {"data", sizeof("data"), 0, 0, 0, 0}, - {0} - }; - - from_zval_write_aggregation(arr, (char *)&level, descriptor_level, ctx); - if (ctx->err.has_error) { - return; - } - from_zval_write_aggregation(arr, (char *)&type, descriptor_type, ctx); - if (ctx->err.has_error) { - return; - } - - entry = get_ancillary_reg_entry(level, type); - if (entry == NULL) { - do_from_zval_err(ctx, "cmsghdr with level %d and type %d not supported", - level, type); - return; - } - - if (entry->calc_space) { - data_len = entry->calc_space(arr, ctx); - if (ctx->err.has_error) { - return; - } - } else { - data_len = entry->size; - } - req_space = CMSG_SPACE(data_len); - space_left = *control_len - *offset; - assert(*control_len >= *offset); - - if (space_left < req_space) { - *control_buf = safe_erealloc(*control_buf, 2, req_space, *control_len); - *control_len += 2 * req_space; - memcpy(&alloc->data, *control_buf, sizeof *control_buf); - } - - cmsghdr = (struct cmsghdr*)(((char*)*control_buf) + *offset); - cmsghdr->cmsg_level = level; - cmsghdr->cmsg_type = type; - cmsghdr->cmsg_len = CMSG_LEN(data_len); - - descriptor_data[0].from_zval = entry->from_array; - from_zval_write_aggregation(arr, (char*)CMSG_DATA(cmsghdr), descriptor_data, ctx); - - *offset += req_space; -} -static void from_zval_write_control_array(const zval *arr, char *msghdr_c, ser_context *ctx) -{ - HashPosition pos; - char buf[sizeof("element #4294967295")]; - char *bufp = buf; - zval **elem; - uint32_t i; - int num_elems; - void *control_buf; - zend_llist_element *alloc; - size_t control_len, - cur_offset; - struct msghdr *msg = (struct msghdr*)msghdr_c; - - if (Z_TYPE_P(arr) != IS_ARRAY) { - do_from_zval_err(ctx, "%s", "expected an array here"); - return; - } - - num_elems = zend_hash_num_elements(Z_ARRVAL_P(arr)); - if (num_elems == 0) { - return; - } - - /* estimate each message at 20 bytes */ - control_buf = accounted_safe_ecalloc(num_elems, CMSG_SPACE(20), 0, ctx); - alloc = ctx->allocations.tail; - control_len = (size_t)num_elems * CMSG_SPACE(20); - cur_offset = 0; - - for (zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arr), &pos), i = 0; - !ctx->err.has_error - && zend_hash_get_current_data_ex(Z_ARRVAL_P(arr), (void **)&elem, &pos) == SUCCESS; - zend_hash_move_forward_ex(Z_ARRVAL_P(arr), &pos)) { - - if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { - memcpy(buf, "element", sizeof("element")); - } - zend_llist_add_element(&ctx->keys, &bufp); - - from_zval_write_control(*elem, &control_buf, alloc, &control_len, - &cur_offset, ctx); - - zend_llist_remove_tail(&ctx->keys); - } - - msg->msg_control = control_buf; - msg->msg_controllen = cur_offset; /* not control_len, which may be larger */ -} -static void to_zval_read_cmsg_data(const char *cmsghdr_c, zval *zv, res_context *ctx) -{ - const struct cmsghdr *cmsg = (const struct cmsghdr *)cmsghdr_c; - ancillary_reg_entry *entry; - size_t len, - *len_p = &len; - - entry = get_ancillary_reg_entry(cmsg->cmsg_level, cmsg->cmsg_type); - if (entry == NULL) { - do_to_zval_err(ctx, "cmsghdr with level %d and type %d not supported", - cmsg->cmsg_level, cmsg->cmsg_type); - return; - } - if (CMSG_LEN(entry->size) > cmsg->cmsg_len) { - do_to_zval_err(ctx, "the cmsghdr structure is unexpectedly small; " - "expected a length of at least %ld, but got %ld", - (long)CMSG_LEN(entry->size), (long)cmsg->cmsg_len); - return; - } - - len = (size_t)cmsg->cmsg_len; /* use another var because type of cmsg_len varies */ - if (zend_hash_add(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN), - &len_p, sizeof(len_p), NULL) == FAILURE) { - do_to_zval_err(ctx, "%s", "could not set parameter " KEY_CMSG_LEN); - return; - } - - entry->to_array((const char *)CMSG_DATA(cmsg), zv, ctx); - - zend_hash_del(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN)); -} -static void to_zval_read_control(const char *cmsghdr_c, zval *zv, res_context *ctx) -{ - /* takes a cmsghdr, not a msghdr like from_zval_write_control */ - static const field_descriptor descriptors[] = { - {"level", sizeof("level"), 0, offsetof(struct cmsghdr, cmsg_level), 0, to_zval_read_int}, - {"type", sizeof("type"), 0, offsetof(struct cmsghdr, cmsg_type), 0, to_zval_read_int}, - {"data", sizeof("data"), 0, 0 /* cmsghdr passed */, 0, to_zval_read_cmsg_data}, - {0} - }; - - array_init_size(zv, 3); - to_zval_read_aggregation(cmsghdr_c, zv, descriptors, ctx); -} -static void to_zval_read_control_array(const char *msghdr_c, zval *zv, res_context *ctx) -{ - struct msghdr *msg = (struct msghdr *)msghdr_c; - struct cmsghdr *cmsg; - char buf[sizeof("element #4294967295")]; - char *bufp = buf; - uint32_t i = 1; - - /*if (msg->msg_flags & MSG_CTRUNC) { - php_error_docref0(NULL, E_WARNING, "The MSG_CTRUNC flag is present; will not " - "attempt to read control messages"); - ZVAL_FALSE(zv); - return; - }*/ - - array_init(zv); - - for (cmsg = CMSG_FIRSTHDR(msg); - cmsg != NULL && !ctx->err.has_error; - cmsg = CMSG_NXTHDR(msg,cmsg)) { - zval *elem; - - ALLOC_INIT_ZVAL(elem); - add_next_index_zval(zv, elem); - - if (snprintf(buf, sizeof(buf), "element #%u", (unsigned)i++) >= sizeof(buf)) { - memcpy(buf, "element", sizeof("element")); - } - zend_llist_add_element(&ctx->keys, &bufp); - - to_zval_read_control((const char *)cmsg, elem, ctx); - - zend_llist_remove_tail(&ctx->keys); - } -} - -/* CONVERSIONS for msghdr */ -static void from_zval_write_name(const zval *zname_arr, char *msghdr_c, ser_context *ctx) -{ - struct sockaddr *sockaddr; - socklen_t sockaddr_len; - struct msghdr *msghdr = (struct msghdr *)msghdr_c; - - from_zval_write_sockaddr_aux(zname_arr, &sockaddr, &sockaddr_len, ctx); - - msghdr->msg_name = sockaddr; - msghdr->msg_namelen = sockaddr_len; -} -static void to_zval_read_name(const char *sockaddr_p, zval *zv, res_context *ctx) -{ - void *name = (void*)*(void**)sockaddr_p; - if (name == NULL) { - ZVAL_NULL(zv); - } else { - to_zval_read_sockaddr_aux(name, zv, ctx); - } -} -static void from_zval_write_msghdr_buffer_size(const zval *elem, char *msghdr_c, ser_context *ctx) -{ - long lval; - struct msghdr *msghdr = (struct msghdr *)msghdr_c; - - lval = from_zval_integer_common(elem, ctx); - if (ctx->err.has_error) { - return; - } - - if (lval < 0 || lval > MAX_USER_BUFF_SIZE) { - do_from_zval_err(ctx, "the buffer size must be between 1 and %ld; " - "given %ld", (long)MAX_USER_BUFF_SIZE, lval); - return; - } - - msghdr->msg_iovlen = 1; - msghdr->msg_iov = accounted_emalloc(sizeof(*msghdr->msg_iov) * 1, ctx); - msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)lval, ctx); - msghdr->msg_iov[0].iov_len = (size_t)lval; -} -static void from_zval_write_iov_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) -{ - struct msghdr *msg = args[0]; - size_t len; - - zval_add_ref(elem); - convert_to_string_ex(elem); - - len = Z_STRLEN_PP(elem); - msg->msg_iov[i - 1].iov_base = accounted_emalloc(len, ctx); - msg->msg_iov[i - 1].iov_len = len; - memcpy(msg->msg_iov[i - 1].iov_base, Z_STRVAL_PP(elem), len); - - zval_ptr_dtor(elem); -} -static void from_zval_write_iov_array(const zval *arr, char *msghdr_c, ser_context *ctx) -{ - int num_elem; - struct msghdr *msg = (struct msghdr*)msghdr_c; - - if (Z_TYPE_P(arr) != IS_ARRAY) { - do_from_zval_err(ctx, "%s", "expected an array here"); - return; - } - - num_elem = zend_hash_num_elements(Z_ARRVAL_P(arr)); - if (num_elem == 0) { - return; - } - - msg->msg_iov = accounted_safe_ecalloc(num_elem, sizeof *msg->msg_iov, 0, ctx); - msg->msg_iovlen = (size_t)num_elem; - - from_array_iterate(arr, from_zval_write_iov_array_aux, (void**)&msg, ctx); -} -static void from_zval_write_controllen(const zval *elem, char *msghdr_c, ser_context *ctx) -{ - struct msghdr *msghdr = (struct msghdr *)msghdr_c; - uint32_t len; - - /* controllen should be an unsigned with at least 32-bit. Let's assume - * this least common denominator - */ - from_zval_write_uint32(elem, (char*)&len, ctx); - if (!ctx->err.has_error && len == 0) { - do_from_zval_err(ctx, "controllen cannot be 0"); - return; - } - msghdr->msg_control = accounted_emalloc(len, ctx); - msghdr->msg_controllen = len; -} -static void from_zval_write_msghdr_send(const zval *container, char *msghdr_c, ser_context *ctx) -{ - static const field_descriptor descriptors[] = { - {"name", sizeof("name"), 0, 0, from_zval_write_name, 0}, - {"iov", sizeof("iov"), 0, 0, from_zval_write_iov_array, 0}, - {"control", sizeof("control"), 0, 0, from_zval_write_control_array, 0}, - {0} - }; - - from_zval_write_aggregation(container, msghdr_c, descriptors, ctx); -} -static void from_zval_write_msghdr_recv(const zval *container, char *msghdr_c, ser_context *ctx) -{ - /* zval to struct msghdr, version for recvmsg(). It differs from the version - * for sendmsg() in that it: - * - has a buffer_size instead of an iov array; - * - has no control element; has a controllen element instead - * struct msghdr { - * void *msg_name; - * socklen_t msg_namelen; - * struct iovec *msg_iov; - * size_t msg_iovlen; - * void *msg_control; - * size_t msg_controllen; //can also be socklen_t - * int msg_flags; - * }; - */ - static const field_descriptor descriptors[] = { - {"name", sizeof("name"), 0, 0, from_zval_write_name, 0}, - {"buffer_size", sizeof("buffer_size"), 0, 0, from_zval_write_msghdr_buffer_size, 0}, - {"controllen", sizeof("controllen"), 1, 0, from_zval_write_controllen, 0}, - {0} - }; - struct msghdr *msghdr = (struct msghdr *)msghdr_c; - const int falsev = 0, - *falsevp = &falsev; - - if (zend_hash_add(&ctx->params, KEY_FILL_SOCKADDR, sizeof(KEY_FILL_SOCKADDR), - (void*)&falsevp, sizeof(falsevp), NULL) == FAILURE) { - do_from_zval_err(ctx, "could not add fill_sockaddr; this is a bug"); - return; - } - - from_zval_write_aggregation(container, msghdr_c, descriptors, ctx); - - zend_hash_del(&ctx->params, KEY_FILL_SOCKADDR, sizeof(KEY_FILL_SOCKADDR)); - if (ctx->err.has_error) { - return; - } - - if (msghdr->msg_iovlen == 0) { - msghdr->msg_iovlen = 1; - msghdr->msg_iov = accounted_emalloc(sizeof(*msghdr->msg_iov) * 1, ctx); - msghdr->msg_iov[0].iov_base = accounted_emalloc((size_t)DEFAULT_BUFF_SIZE, ctx); - msghdr->msg_iov[0].iov_len = (size_t)DEFAULT_BUFF_SIZE; - } -} - -static void to_zval_read_iov(const char *msghdr_c, zval *zv, res_context *ctx) -{ - const struct msghdr *msghdr = (const struct msghdr *)msghdr_c; - size_t iovlen = msghdr->msg_iovlen; - ssize_t **recvmsg_ret, - bytes_left; - uint i; - - if (iovlen > UINT_MAX) { - do_to_zval_err(ctx, "unexpectedly large value for iov_len: %lu", - (unsigned long)iovlen); - } - array_init_size(zv, (uint)iovlen); - - if (zend_hash_find(&ctx->params, KEY_RECVMSG_RET, sizeof(KEY_RECVMSG_RET), - (void**)&recvmsg_ret) == FAILURE) { - do_to_zval_err(ctx, "recvmsg_ret not found in params. This is a bug"); - return; - } - bytes_left = **recvmsg_ret; - - for (i = 0; bytes_left > 0 && i < (uint)iovlen; i++) { - zval *elem; - size_t len = MIN(msghdr->msg_iov[i].iov_len, bytes_left); - char *buf = safe_emalloc(1, len, 1); - - MAKE_STD_ZVAL(elem); - memcpy(buf, msghdr->msg_iov[i].iov_base, len); - buf[len] = '\0'; - - ZVAL_STRINGL(elem, buf, len, 0); - add_next_index_zval(zv, elem); - bytes_left -= len; - } -} -static void to_zval_read_msghdr(const char *msghdr_c, zval *zv, res_context *ctx) -{ - static const field_descriptor descriptors[] = { - {"name", sizeof("name"), 0, offsetof(struct msghdr, msg_name), 0, to_zval_read_name}, - {"control", sizeof("control"), 0, 0, 0, to_zval_read_control_array}, - {"iov", sizeof("iov"), 0, 0, 0, to_zval_read_iov}, - {"flags", sizeof("flags"), 0, offsetof(struct msghdr, msg_flags), 0, to_zval_read_int}, - {0} - }; - - array_init_size(zv, 4); - - to_zval_read_aggregation(msghdr_c, zv, descriptors, ctx); -} - - -/* CONVERSIONS for struct in6_pktinfo */ -#ifdef IPV6_PKTINFO -static const field_descriptor descriptors_in6_pktinfo[] = { - {"addr", sizeof("addr"), 1, offsetof(struct in6_pktinfo, ipi6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, - {"ifindex", sizeof("ifindex"), 1, offsetof(struct in6_pktinfo, ipi6_ifindex), from_zval_write_unsigned, to_zval_read_unsigned}, - {0} -}; -static void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx) -{ - from_zval_write_aggregation(container, in6_pktinfo_c, descriptors_in6_pktinfo, ctx); -} -static void to_zval_read_in6_pktinfo(const char *data, zval *zv, res_context *ctx) -{ - array_init_size(zv, 2); - - to_zval_read_aggregation(data, zv, descriptors_in6_pktinfo, ctx); -} -#endif - -/* CONVERSIONS for struct ucred */ -#ifdef SO_PASSCRED -static const field_descriptor descriptors_ucred[] = { - {"pid", sizeof("pid"), 1, offsetof(struct ucred, pid), from_zval_write_pid_t, to_zval_read_pid_t}, - {"uid", sizeof("uid"), 1, offsetof(struct ucred, uid), from_zval_write_uid_t, to_zval_read_uid_t}, - /* assume the type gid_t is the same as uid_t: */ - {"gid", sizeof("gid"), 1, offsetof(struct ucred, gid), from_zval_write_uid_t, to_zval_read_uid_t}, - {0} -}; -static void from_zval_write_ucred(const zval *container, char *ucred_c, ser_context *ctx) -{ - from_zval_write_aggregation(container, ucred_c, descriptors_ucred, ctx); -} -static void to_zval_read_ucred(const char *data, zval *zv, res_context *ctx) -{ - array_init_size(zv, 3); - - to_zval_read_aggregation(data, zv, descriptors_ucred, ctx); -} -#endif - -/* CONVERSIONS for SCM_RIGHTS */ -#ifdef SCM_RIGHTS -static size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx) -{ - int num_elems; - - if (Z_TYPE_P(arr) != IS_ARRAY) { - do_from_zval_err(ctx, "%s", "expected an array here"); - return (size_t)-1; - } - - num_elems = zend_hash_num_elements(Z_ARRVAL_P(arr)); - if (num_elems == 0) { - do_from_zval_err(ctx, "%s", "expected at least one element in this array"); - return (size_t)-1; - } - - return zend_hash_num_elements(Z_ARRVAL_P(arr)) * sizeof(int); -} -static void from_zval_write_fd_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) -{ - int *iarr = args[0]; - - if (Z_TYPE_PP(elem) == IS_RESOURCE) { - php_stream *stream; - php_socket *sock; - - ZEND_FETCH_RESOURCE_NO_RETURN(sock, php_socket *, elem, -1, - NULL, php_sockets_le_socket()); - if (sock) { - iarr[i] = sock->bsd_socket; - return; - } - - ZEND_FETCH_RESOURCE2_NO_RETURN(stream, php_stream *, elem, -1, - NULL, php_file_le_stream(), php_file_le_pstream()); - if (stream == NULL) { - do_from_zval_err(ctx, "resource is not a stream or a socket"); - return; - } - - if (php_stream_cast(stream, PHP_STREAM_AS_FD, (void **)&iarr[i], - REPORT_ERRORS) == FAILURE) { - do_from_zval_err(ctx, "cast stream to file descriptor failed"); - return; - } - } else { - do_from_zval_err(ctx, "expected a resource variable"); - } -} -static void from_zval_write_fd_array(const zval *arr, char *int_arr, ser_context *ctx) -{ - if (Z_TYPE_P(arr) != IS_ARRAY) { - do_from_zval_err(ctx, "%s", "expected an array here"); - return; - } - - from_array_iterate(arr, &from_zval_write_fd_array_aux, (void**)&int_arr, ctx); -} -static void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx) -{ - size_t **cmsg_len; - int num_elems, - i; - struct cmsghdr *dummy_cmsg = 0; - size_t data_offset; - TSRMLS_FETCH(); - - data_offset = (unsigned char *)CMSG_DATA(dummy_cmsg) - - (unsigned char *)dummy_cmsg; - - if (zend_hash_find(&ctx->params, KEY_CMSG_LEN, sizeof(KEY_CMSG_LEN), - (void **)&cmsg_len) == FAILURE) { - do_to_zval_err(ctx, "could not get value of parameter " KEY_CMSG_LEN); - return; - } - - if (**cmsg_len < data_offset) { - do_to_zval_err(ctx, "length of cmsg is smaller than its data member " - "offset (%ld vs %ld)", (long)**cmsg_len, (long)data_offset); - return; - } - num_elems = (**cmsg_len - data_offset) / sizeof(int); - - array_init_size(zv, num_elems); - - for (i = 0; i < num_elems; i++) { - zval *elem; - int fd; - struct stat statbuf; - - MAKE_STD_ZVAL(elem); - - fd = *((int *)data + i); - - /* determine whether we have a socket */ - if (fstat(fd, &statbuf) == -1) { - do_to_zval_err(ctx, "error creating resource for received file " - "descriptor %d: fstat() call failed with errno %d", fd, errno); - efree(elem); - return; - } - if (S_ISSOCK(statbuf.st_mode)) { - php_socket *sock = socket_import_file_descriptor(fd); - zend_register_resource(elem, sock, php_sockets_le_socket()); - } else { - php_stream *stream = php_stream_fopen_from_fd(fd, "rw", NULL); - php_stream_to_zval(stream, elem); - } - - add_next_index_zval(zv, elem); - } -} -#endif - -/* ENTRY POINT for conversions */ -static void free_from_zval_allocation(void *alloc_ptr_ptr) -{ - efree(*(void**)alloc_ptr_ptr); -} -static void *from_zval_run_conversions(const zval *container, - php_socket *sock, - from_zval_write_field *writer, - size_t struct_size, - const char *top_name, - zend_llist **allocations /* out */, - struct err_s *err /* in/out */) -{ - ser_context ctx = {{0}}; - char *structure = NULL; - - *allocations = NULL; - - if (err->has_error) { - return NULL; - } - - zend_hash_init(&ctx.params, 8, NULL, NULL, 0); - zend_llist_init(&ctx.keys, sizeof(const char *), NULL, 0); - zend_llist_init(&ctx.allocations, sizeof(void *), &free_from_zval_allocation, 0); - ctx.sock = sock; - - structure = ecalloc(1, struct_size); - - zend_llist_add_element(&ctx.keys, &top_name); - zend_llist_add_element(&ctx.allocations, &structure); - - /* main call */ - writer(container, structure, &ctx); - - if (ctx.err.has_error) { - zend_llist_destroy(&ctx.allocations); /* deallocates structure as well */ - structure = NULL; - *err = ctx.err; - } else { - *allocations = emalloc(sizeof **allocations); - **allocations = ctx.allocations; - } - - zend_llist_destroy(&ctx.keys); - zend_hash_destroy(&ctx.params); - - return structure; -} -static zval *to_zval_run_conversions(const char *structure, - to_zval_read_field *reader, - const char *top_name, - const struct key_value *key_value_pairs, - struct err_s *err) -{ - res_context ctx = {{0}, {0}}; - const struct key_value *kv; - zval *zv = NULL; - - if (err->has_error) { - return NULL; - } - - ALLOC_INIT_ZVAL(zv); - - zend_llist_init(&ctx.keys, sizeof(const char *), NULL, 0); - zend_llist_add_element(&ctx.keys, &top_name); - - zend_hash_init(&ctx.params, 8, NULL, NULL, 0); - for (kv = key_value_pairs; kv->key != NULL; kv++) { - zend_hash_update(&ctx.params, kv->key, kv->key_size, - (void*)&kv->value, sizeof(kv->value), NULL); - } - - /* main call */ - reader(structure, zv, &ctx); - - if (ctx.err.has_error) { - zval_ptr_dtor(&zv); - zv = NULL; - *err = ctx.err; - } - - zend_llist_destroy(&ctx.keys); - zend_hash_destroy(&ctx.params); - - return zv; -} #ifdef ZTS static MUTEX_T ancillary_mutex; @@ -1555,7 +98,7 @@ static void destroy_ancillary_registry(void) ancillary_registry.initialized = 0; } } -static ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) +ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type) { anc_reg_key key = { cmsg_level, msg_type }; ancillary_reg_entry *entry; diff --git a/ext/sockets/sendrecvmsg.h b/ext/sockets/sendrecvmsg.h index 82fb38b4b5f8b..55dca3c1fbc7b 100644 --- a/ext/sockets/sendrecvmsg.h +++ b/ext/sockets/sendrecvmsg.h @@ -1,5 +1,10 @@ +#ifndef PHP_SENDRECVMSG_H +#define PHP_SENDRECVMSG_H 1 + #include +#include "conversions.h" +/* for sockets.c */ PHP_FUNCTION(socket_sendmsg); PHP_FUNCTION(socket_recvmsg); PHP_FUNCTION(socket_cmsg_space); @@ -9,3 +14,23 @@ void php_socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS); int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4); int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result); + +/* for conversions.c */ +typedef struct { + int cmsg_level; /* originating protocol */ + int cmsg_type; /* protocol-specific type */ +} anc_reg_key; + +typedef size_t (calculate_req_space)(const zval *value, ser_context *ctx); + +typedef struct { + socklen_t size; /* size of native structure */ + socklen_t var_el_size; /* size of repeatable component */ + calculate_req_space *calc_space; + from_zval_write_field *from_array; + to_zval_read_field *to_array; +} ancillary_reg_entry; + +ancillary_reg_entry *get_ancillary_reg_entry(int cmsg_level, int msg_type); + +#endif From bd580db373ce35aa2e60ca452ae4eb1984b0520e Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Tue, 1 Jan 2013 23:38:19 +0100 Subject: [PATCH 2357/2394] Build fixes; accept names for if_index --- ext/sockets/conversions.c | 61 +++++++++++++++++++++------------------ ext/sockets/multicast.c | 4 +-- ext/sockets/multicast.h | 4 +-- ext/sockets/sendrecvmsg.c | 10 +++---- ext/sockets/sendrecvmsg.h | 4 +-- ext/sockets/sockets.c | 10 +++---- 6 files changed, 48 insertions(+), 45 deletions(-) diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index 7ca9972ac0d38..54631604ab4b8 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -12,6 +12,9 @@ #include #include +#include +#include + #include #include #include @@ -53,6 +56,8 @@ typedef struct { #define KEY_RECVMSG_RET "recvmsg_ret" #define KEY_CMSG_LEN "cmsg_len" +const struct key_value empty_key_value_list[] = {{0}}; + /* PARAMETERS */ static int param_get_bool(void *ctx, const char *key, int def) { @@ -331,25 +336,6 @@ void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) ival = (int)lval; memcpy(field, &ival, sizeof(ival)); } -static void from_zval_write_unsigned(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - unsigned ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (sizeof(long) > sizeof(ival) && (lval < 0 || lval > UINT_MAX)) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for a native unsigned int"); - return; - } - - ival = (unsigned)lval; - memcpy(field, &ival, sizeof(ival)); -} static void from_zval_write_uint32(const zval *arr_value, char *field, ser_context *ctx) { long lval; @@ -1192,20 +1178,17 @@ void to_zval_read_msghdr(const char *msghdr_c, zval *zv, res_context *ctx) /* CONVERSIONS for if_index */ static void from_zval_write_ifindex(const zval *zv, char *uinteger, ser_context *ctx) { - zval *va; unsigned *out; - unsigned ret; - zval lzval = zval_used_for_init; + unsigned ret; + zval lzval = zval_used_for_init; if (Z_TYPE_P(zv) == IS_LONG) { - if (Z_LVAL_P(zv) < 0 || Z_LVAL_P(zv) > UINT_MAX) { + if (Z_LVAL_P(zv) < 0 || Z_LVAL_P(zv) > UINT_MAX) { /* allow 0 (unspecified interface) */ do_from_zval_err(ctx, "the interface index cannot be negative or " "larger than %u; given %ld", UINT_MAX, Z_LVAL_P(zv)); } else { ret = (unsigned)Z_LVAL_P(zv); } } else { -#if HAVE_IF_NAMETOINDEX - if (Z_TYPE_P(zv) != IS_STRING) { ZVAL_COPY_VALUE(&lzval, zv); zval_copy_ctor(&lzval); @@ -1213,11 +1196,32 @@ static void from_zval_write_ifindex(const zval *zv, char *uinteger, ser_context zv = &lzval; } +#if HAVE_IF_NAMETOINDEX ret = if_nametoindex(Z_STRVAL_P(zv)); if (ret == 0) { do_from_zval_err(ctx, "no interface with name \"%s\" could be " "found", Z_STRVAL_P(zv)); } +#elif defined(SIOCGIFINDEX) + { + struct ifreq ifr; + if (strlcpy(ifr.ifr_name, Z_STRVAL_P(zv), sizeof(ifr.ifr_name)) + >= sizeof(ifr.ifr_name)) { + do_from_zval_err(ctx, "the interface name \"%s\" is too large ", + Z_STRVAL_P(zv)); + } else if (ioctl(ctx->sock->bsd_socket, SIOCGIFINDEX, &ifr) < 0) { + if (errno == ENODEV) { + do_from_zval_err(ctx, "no interface with name \"%s\" could be " + "found", Z_STRVAL_P(zv)); + } else { + do_from_zval_err(ctx, "error fetching interface index for " + "interface with name \"%s\" (errno %d)", + Z_STRVAL_P(zv), errno); + } + } else { + ret = (unsigned)ifr.ifr_ifindex; + } + } #else do_from_zval_err(ctx, "this platform does not support looking up an interface by " @@ -1236,7 +1240,7 @@ static void from_zval_write_ifindex(const zval *zv, char *uinteger, ser_context #ifdef IPV6_PKTINFO static const field_descriptor descriptors_in6_pktinfo[] = { {"addr", sizeof("addr"), 1, offsetof(struct in6_pktinfo, ipi6_addr), from_zval_write_sin6_addr, to_zval_read_sin6_addr}, - {"ifindex", sizeof("ifindex"), 1, offsetof(struct in6_pktinfo, ipi6_ifindex), from_zval_write_unsigned, to_zval_read_unsigned}, + {"ifindex", sizeof("ifindex"), 1, offsetof(struct in6_pktinfo, ipi6_ifindex), from_zval_write_ifindex, to_zval_read_unsigned}, {0} }; void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx) @@ -1294,6 +1298,7 @@ size_t calculate_scm_rights_space(const zval *arr, ser_context *ctx) static void from_zval_write_fd_array_aux(zval **elem, unsigned i, void **args, ser_context *ctx) { int *iarr = args[0]; + TSRMLS_FETCH(); if (Z_TYPE_PP(elem) == IS_RESOURCE) { php_stream *stream; @@ -1375,8 +1380,8 @@ void to_zval_read_fd_array(const char *data, zval *zv, res_context *ctx) return; } if (S_ISSOCK(statbuf.st_mode)) { - php_socket *sock = socket_import_file_descriptor(fd); - zend_register_resource(elem, sock, php_sockets_le_socket()); + php_socket *sock = socket_import_file_descriptor(fd TSRMLS_CC); + zend_register_resource(elem, sock, php_sockets_le_socket() TSRMLS_CC); } else { php_stream *stream = php_stream_fopen_from_fd(fd, "rw", NULL); php_stream_to_zval(stream, elem); diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index dc242693acc3c..5d29c9c5e265e 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -250,7 +250,7 @@ static int php_do_mcast_opt(php_socket *php_sock, int level, int optname, zval * int php_do_setsockopt_ip_mcast(php_socket *php_sock, int level, int optname, - zval **arg4) + zval **arg4 TSRMLS_DC) { unsigned int if_index; struct in_addr if_addr; @@ -319,7 +319,7 @@ int php_do_setsockopt_ip_mcast(php_socket *php_sock, int php_do_setsockopt_ipv6_mcast(php_socket *php_sock, int level, int optname, - zval **arg4) + zval **arg4 TSRMLS_DC) { unsigned int if_index; void *opt_ptr; diff --git a/ext/sockets/multicast.h b/ext/sockets/multicast.h index c363b58472720..1ad4673feb719 100644 --- a/ext/sockets/multicast.h +++ b/ext/sockets/multicast.h @@ -30,12 +30,12 @@ int php_do_setsockopt_ip_mcast(php_socket *php_sock, int level, int optname, - zval **arg4); + zval **arg4 TSRMLS_DC); int php_do_setsockopt_ipv6_mcast(php_socket *php_sock, int level, int optname, - zval **arg4); + zval **arg4 TSRMLS_DC); int php_if_index_to_addr4( unsigned if_index, diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index 6479bf90a850d..b83b3ae482378 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -272,7 +272,7 @@ PHP_FUNCTION(socket_cmsg_space) RETURN_LONG((long)CMSG_SPACE(entry->size + n * entry->var_el_size)); } -int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4) +int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4 TSRMLS_DC) { struct err_s err = {0}; zend_llist *allocations = NULL; @@ -311,7 +311,7 @@ int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, return retval != 0 ? FAILURE : SUCCESS; } -int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result) +int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result TSRMLS_DC) { struct err_s err = {0}; void *buffer; @@ -340,7 +340,7 @@ int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *zv = to_zval_run_conversions(buffer, reader, "in6_pktinfo", empty_key_value_list, &err); if (err.has_error) { - err_msg_dispose(&err); + err_msg_dispose(&err TSRMLS_CC); res = -1; } else { ZVAL_COPY_VALUE(result, zv); @@ -354,9 +354,7 @@ int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS) { - /* IPv6 ancillary data - * Note that support for sticky options via setsockopt() is not implemented - * yet (where special support is needed, i.e., the optval is not an int). */ + /* IPv6 ancillary data */ #ifdef IPV6_RECVPKTINFO REGISTER_LONG_CONSTANT("IPV6_RECVPKTINFO", IPV6_RECVPKTINFO, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_PKTINFO", IPV6_PKTINFO, CONST_CS | CONST_PERSISTENT); diff --git a/ext/sockets/sendrecvmsg.h b/ext/sockets/sendrecvmsg.h index 55dca3c1fbc7b..5a3798274fd7e 100644 --- a/ext/sockets/sendrecvmsg.h +++ b/ext/sockets/sendrecvmsg.h @@ -12,8 +12,8 @@ PHP_FUNCTION(socket_cmsg_space); void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS); void php_socket_sendrecvmsg_shutdown(SHUTDOWN_FUNC_ARGS); -int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4); -int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result); +int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval **arg4 TSRMLS_DC); +int php_do_getsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, zval *result TSRMLS_DC); /* for conversions.c */ typedef struct { diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 9c57e2d98d22c..2aeb4b0fd3327 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -1878,7 +1878,7 @@ PHP_FUNCTION(socket_get_option) } } } else if (level == IPPROTO_IPV6) { - int ret = php_do_getsockopt_ipv6_rfc3542(php_sock, level, optname, return_value); + int ret = php_do_getsockopt_ipv6_rfc3542(php_sock, level, optname, return_value TSRMLS_CC); if (ret == SUCCESS) { return; } else if (ret == FAILURE) { @@ -1981,15 +1981,15 @@ PHP_FUNCTION(socket_set_option) if (level == IPPROTO_IP) { - int res = php_do_setsockopt_ip_mcast(php_sock, level, optname, arg4); + int res = php_do_setsockopt_ip_mcast(php_sock, level, optname, arg4 TSRMLS_CC); HANDLE_SUBCALL(res); } #if HAVE_IPV6 else if (level == IPPROTO_IPV6) { - int res = php_do_setsockopt_ipv6_mcast(php_sock, level, optname, arg4); + int res = php_do_setsockopt_ipv6_mcast(php_sock, level, optname, arg4 TSRMLS_CC); if (res == 1) { - res = php_do_setsockopt_ipv6_rfc3542(php_sock, level, optname, arg4); + res = php_do_setsockopt_ipv6_rfc3542(php_sock, level, optname, arg4 TSRMLS_CC); } HANDLE_SUBCALL(res); } @@ -2273,7 +2273,7 @@ PHP_FUNCTION(socket_import_stream) RETURN_FALSE; } - retsock = socket_import_file_descriptor(socket); + retsock = socket_import_file_descriptor(socket TSRMLS_CC); if (retsock == NULL) { RETURN_FALSE; } From c846fcef685c14a42ae770d56340a41d936deae9 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 00:40:17 +0100 Subject: [PATCH 2358/2394] Fix buf in string -> int conv. --- ext/sockets/conversions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index 54631604ab4b8..9cbc6e5f88e71 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -297,7 +297,7 @@ static long from_zval_integer_common(const zval *arr_value, ser_context *ctx) case IS_LONG: zval_dtor(&lzval); Z_TYPE(lzval) = IS_LONG; - Z_DVAL(lzval) = lval; + Z_LVAL(lzval) = lval; goto long_case; } From f10baf14eda4a6fd0e4c8a24d008975184e31207 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 00:59:05 +0100 Subject: [PATCH 2359/2394] Payload of HOPLIMIT/TCLASS are 8-bit --- ext/sockets/conversions.c | 30 ++++++++++++++++++++++++++++-- ext/sockets/conversions.h | 4 ++-- ext/sockets/sendrecvmsg.c | 10 ++++++---- 3 files changed, 36 insertions(+), 8 deletions(-) diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index 9cbc6e5f88e71..ef1f884210af8 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -317,7 +317,7 @@ static long from_zval_integer_common(const zval *arr_value, ser_context *ctx) return ret; } -void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) +static void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) { long lval; int ival; @@ -355,6 +355,25 @@ static void from_zval_write_uint32(const zval *arr_value, char *field, ser_conte ival = (uint32_t)lval; memcpy(field, &ival, sizeof(ival)); } +void from_zval_write_uint8(const zval *arr_value, char *field, ser_context *ctx) +{ + long lval; + uint8_t ival; + + lval = from_zval_integer_common(arr_value, ctx); + if (ctx->err.has_error) { + return; + } + + if (lval < 0 || lval > 0xFF) { + do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " + "for an unsigned 8-bit integer"); + return; + } + + ival = (uint8_t)lval; + memcpy(field, &ival, sizeof(ival)); +} static void from_zval_write_net_uint16(const zval *arr_value, char *field, ser_context *ctx) { long lval; @@ -441,7 +460,7 @@ static void from_zval_write_uid_t(const zval *arr_value, char *field, ser_contex memcpy(field, &ival, sizeof(ival)); } -void to_zval_read_int(const char *data, zval *zv, res_context *ctx) +static void to_zval_read_int(const char *data, zval *zv, res_context *ctx) { int ival; memcpy(&ival, data, sizeof(ival)); @@ -455,6 +474,13 @@ static void to_zval_read_unsigned(const char *data, zval *zv, res_context *ctx) ZVAL_LONG(zv, (long)ival); } +void to_zval_read_uint8(const char *data, zval *zv, res_context *ctx) +{ + uint8_t ival; + memcpy(&ival, data, sizeof(ival)); + + ZVAL_LONG(zv, (long)ival); +} static void to_zval_read_net_uint16(const char *data, zval *zv, res_context *ctx) { uint16_t ival; diff --git a/ext/sockets/conversions.h b/ext/sockets/conversions.h index 70f31ba676e56..79ca4ab76e271 100644 --- a/ext/sockets/conversions.h +++ b/ext/sockets/conversions.h @@ -37,8 +37,8 @@ void err_msg_dispose(struct err_s *err TSRMLS_DC); void allocations_dispose(zend_llist **allocations); /* CONVERSION FUNCTIONS */ -void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx); -void to_zval_read_int(const char *data, zval *zv, res_context *ctx); +void from_zval_write_uint8(const zval *arr_value, char *field, ser_context *ctx); +void to_zval_read_uint8(const char *data, zval *zv, res_context *ctx); #ifdef IPV6_PKTINFO void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx); diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index b83b3ae482378..f325b0378a943 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -73,12 +73,14 @@ static void init_ancillary_registry(void) #endif #ifdef IPV6_HOPLIMIT - PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, - to_zval_read_int, IPPROTO_IPV6, IPV6_HOPLIMIT); + PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_uint8, + to_zval_read_uint8, IPPROTO_IPV6, IPV6_HOPLIMIT); #endif - PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, - to_zval_read_int, IPPROTO_IPV6, IPV6_TCLASS); +#ifdef IPV6_TCLASS + PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_uint8, + to_zval_read_uint8, IPPROTO_IPV6, IPV6_TCLASS); +#endif #ifdef SO_PASSCRED PUT_ENTRY(sizeof(struct ucred), 0, 0, from_zval_write_ucred, From 5c0a8b1a2a34ec504091e4e105e1c3b79d9fff89 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 15:25:55 +0100 Subject: [PATCH 2360/2394] Ensure memory is initialized --- ext/sockets/conversions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index ef1f884210af8..d0d0c4b798651 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -858,6 +858,7 @@ static void from_zval_write_control(const zval *arr, if (space_left < req_space) { *control_buf = safe_erealloc(*control_buf, 2, req_space, *control_len); *control_len += 2 * req_space; + memset(*control_buf, '\0', *control_len - *offset); memcpy(&alloc->data, *control_buf, sizeof *control_buf); } From 95f8d34f9c0980924098ce9554e899e461ce7cec Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 15:26:10 +0100 Subject: [PATCH 2361/2394] Revert "Payload of HOPLIMIT/TCLASS are 8-bit" This reverts commit 61a5ec7381ba5388a52926779fe3f58af0caea83. I checked Linux and OpenBSD and both use integers to write the IPV6_TCLASS messages and they don't force any endianness. This is despite RFC 3542 explicitly saying the first byte of cmsg_data will have the result. In any case, it doesn't make any difference in little-endian archs. --- ext/sockets/conversions.c | 30 ++---------------------------- ext/sockets/conversions.h | 4 ++-- ext/sockets/sendrecvmsg.c | 10 ++++------ 3 files changed, 8 insertions(+), 36 deletions(-) diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index d0d0c4b798651..fa6d94948678d 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -317,7 +317,7 @@ static long from_zval_integer_common(const zval *arr_value, ser_context *ctx) return ret; } -static void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) +void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx) { long lval; int ival; @@ -355,25 +355,6 @@ static void from_zval_write_uint32(const zval *arr_value, char *field, ser_conte ival = (uint32_t)lval; memcpy(field, &ival, sizeof(ival)); } -void from_zval_write_uint8(const zval *arr_value, char *field, ser_context *ctx) -{ - long lval; - uint8_t ival; - - lval = from_zval_integer_common(arr_value, ctx); - if (ctx->err.has_error) { - return; - } - - if (lval < 0 || lval > 0xFF) { - do_from_zval_err(ctx, "%s", "given PHP integer is out of bounds " - "for an unsigned 8-bit integer"); - return; - } - - ival = (uint8_t)lval; - memcpy(field, &ival, sizeof(ival)); -} static void from_zval_write_net_uint16(const zval *arr_value, char *field, ser_context *ctx) { long lval; @@ -460,7 +441,7 @@ static void from_zval_write_uid_t(const zval *arr_value, char *field, ser_contex memcpy(field, &ival, sizeof(ival)); } -static void to_zval_read_int(const char *data, zval *zv, res_context *ctx) +void to_zval_read_int(const char *data, zval *zv, res_context *ctx) { int ival; memcpy(&ival, data, sizeof(ival)); @@ -474,13 +455,6 @@ static void to_zval_read_unsigned(const char *data, zval *zv, res_context *ctx) ZVAL_LONG(zv, (long)ival); } -void to_zval_read_uint8(const char *data, zval *zv, res_context *ctx) -{ - uint8_t ival; - memcpy(&ival, data, sizeof(ival)); - - ZVAL_LONG(zv, (long)ival); -} static void to_zval_read_net_uint16(const char *data, zval *zv, res_context *ctx) { uint16_t ival; diff --git a/ext/sockets/conversions.h b/ext/sockets/conversions.h index 79ca4ab76e271..70f31ba676e56 100644 --- a/ext/sockets/conversions.h +++ b/ext/sockets/conversions.h @@ -37,8 +37,8 @@ void err_msg_dispose(struct err_s *err TSRMLS_DC); void allocations_dispose(zend_llist **allocations); /* CONVERSION FUNCTIONS */ -void from_zval_write_uint8(const zval *arr_value, char *field, ser_context *ctx); -void to_zval_read_uint8(const char *data, zval *zv, res_context *ctx); +void from_zval_write_int(const zval *arr_value, char *field, ser_context *ctx); +void to_zval_read_int(const char *data, zval *zv, res_context *ctx); #ifdef IPV6_PKTINFO void from_zval_write_in6_pktinfo(const zval *container, char *in6_pktinfo_c, ser_context *ctx); diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index f325b0378a943..b83b3ae482378 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -73,14 +73,12 @@ static void init_ancillary_registry(void) #endif #ifdef IPV6_HOPLIMIT - PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_uint8, - to_zval_read_uint8, IPPROTO_IPV6, IPV6_HOPLIMIT); + PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, + to_zval_read_int, IPPROTO_IPV6, IPV6_HOPLIMIT); #endif -#ifdef IPV6_TCLASS - PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_uint8, - to_zval_read_uint8, IPPROTO_IPV6, IPV6_TCLASS); -#endif + PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, + to_zval_read_int, IPPROTO_IPV6, IPV6_TCLASS); #ifdef SO_PASSCRED PUT_ENTRY(sizeof(struct ucred), 0, 0, from_zval_write_ucred, From 8561680533c7fd6b66497ed10246fe9e57e9d351 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Wed, 30 Jan 2013 21:40:45 +0100 Subject: [PATCH 2362/2394] Remove some pre-vista code --- win32/inet.c | 79 ---------------------------------------------------- win32/inet.h | 11 ++------ 2 files changed, 2 insertions(+), 88 deletions(-) diff --git a/win32/inet.c b/win32/inet.c index d424c8a5468b7..686cf1265c524 100644 --- a/win32/inet.c +++ b/win32/inet.c @@ -1,83 +1,4 @@ -#include "config.w32.h" -#include "php.h" -#include -#include -#include - #include "inet.h" -#if (_WIN32_WINNT < 0x0600) /* Vista/2k8 have these functions */ - - -PHPAPI int inet_pton(int af, const char* src, void* dst) -{ - int address_length; - struct sockaddr_storage sa; - struct sockaddr_in *sin = (struct sockaddr_in *)&sa; - struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)&sa; - - switch (af) { - case AF_INET: - address_length = sizeof (struct sockaddr_in); - break; - - case AF_INET6: - address_length = sizeof (struct sockaddr_in6); - break; - - default: - return -1; - } - - if (WSAStringToAddress ((LPTSTR) src, af, NULL, (LPSOCKADDR) &sa, &address_length) == 0) { - switch (af) { - case AF_INET: - memcpy (dst, &sin->sin_addr, sizeof (struct in_addr)); - break; - - case AF_INET6: - memcpy (dst, &sin6->sin6_addr, sizeof (struct in6_addr)); - break; - } - return 1; - } - - return 0; -} - -PHPAPI const char* inet_ntop(int af, const void* src, char* dst, size_t size) -{ - int address_length; - DWORD string_length = size; - struct sockaddr_storage sa; - struct sockaddr_in *sin = (struct sockaddr_in *)&sa; - struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)&sa; - - memset (&sa, 0, sizeof (sa)); - switch (af) { - case AF_INET: - address_length = sizeof (struct sockaddr_in); - sin->sin_family = af; - memcpy (&sin->sin_addr, src, sizeof (struct in_addr)); - break; - - case AF_INET6: - address_length = sizeof (struct sockaddr_in6); - sin6->sin6_family = af; - memcpy (&sin6->sin6_addr, src, sizeof (struct in6_addr)); - break; - - default: - return NULL; - } - - if (WSAAddressToString ((LPSOCKADDR) &sa, address_length, NULL, dst, &string_length) == 0) { - return dst; - } - - return NULL; -} - -#endif int inet_aton(const char *cp, struct in_addr *inp) { inp->s_addr = inet_addr(cp); diff --git a/win32/inet.h b/win32/inet.h index 623d114dfd584..d71723759fa10 100644 --- a/win32/inet.h +++ b/win32/inet.h @@ -1,11 +1,4 @@ -#if _MSC_VER >= 1500 -# include -#endif -#include - -#if (_WIN32_WINNT <= 0x502) -PHPAPI int inet_pton(int af, const char* src, void* dst); -PHPAPI const char* inet_ntop(int af, const void* src, char* dst, size_t size); -#endif +#include +#include PHPAPI int inet_aton(const char *cp, struct in_addr *inp); From 7066cc726713f0eaf79db9eac0da90bc6d8740b4 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 14:01:31 +0100 Subject: [PATCH 2363/2394] send/recvmsg() support for Windows --- ext/sockets/config.w32 | 2 +- ext/sockets/conversions.c | 69 ++++++++--- ext/sockets/conversions.h | 10 +- ext/sockets/php_sockets.h | 4 +- ext/sockets/sendrecvmsg.c | 54 ++++++++- ext/sockets/sockaddr_conv.c | 2 +- ext/sockets/sockaddr_conv.h | 10 +- ext/sockets/sockets.c | 30 ++--- .../socket_sendrecvmsg_multi_msg-win32.phpt | 110 ++++++++++++++++++ .../tests/socket_sendrecvmsg_multi_msg.phpt | 19 +-- .../tests/socket_set_option_in6_pktinfo.phpt | 3 +- ext/sockets/windows_common.h | 41 +++++++ 12 files changed, 300 insertions(+), 54 deletions(-) create mode 100644 ext/sockets/tests/socket_sendrecvmsg_multi_msg-win32.phpt create mode 100644 ext/sockets/windows_common.h diff --git a/ext/sockets/config.w32 b/ext/sockets/config.w32 index 9c234db8f8df8..aeaa8ed425e68 100644 --- a/ext/sockets/config.w32 +++ b/ext/sockets/config.w32 @@ -7,7 +7,7 @@ if (PHP_SOCKETS != "no") { if (CHECK_LIB("ws2_32.lib", "sockets", PHP_SOCKETS) && CHECK_LIB("Iphlpapi.lib", "sockets", PHP_SOCKETS) && CHECK_HEADER_ADD_INCLUDE("winsock.h", "CFLAGS_SOCKETS")) { - EXTENSION('sockets', 'sockets.c multicast.c'); + EXTENSION('sockets', 'sockets.c multicast.c conversions.c sockaddr_conv.c sendrecvmsg.c'); AC_DEFINE('HAVE_SOCKETS', 1); PHP_INSTALL_HEADERS("ext/sockets", "php_sockets.h"); } else { diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index fa6d94948678d..6c79166806b5e 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -1,24 +1,67 @@ -#include "conversions.h" #include "sockaddr_conv.h" #include "conversions.h" #include "sendrecvmsg.h" /* for ancillary registry */ +#include "windows_common.h" #include #include -#include -#include -#include -#include -#include - -#include -#include +#ifndef PHP_WIN32 +# include +# include +# include +# include +# include +# include +# include +#else +# include +#endif #include #include #include +#ifdef PHP_WIN32 +typedef unsigned short sa_family_t; +# define msghdr _WSAMSG +/* +struct _WSAMSG { + LPSOCKADDR name; //void *msg_name + INT namelen; //socklen_t msg_namelen + LPWSABUF lpBuffers; //struct iovec *msg_iov + ULONG dwBufferCount; //size_t msg_iovlen + WSABUF Control; //void *msg_control, size_t msg_controllen + DWORD dwFlags; //int msg_flags +} +struct __WSABUF { + u_long len; //size_t iov_len (2nd member) + char FAR *buf; //void *iov_base (1st member) +} +struct _WSACMSGHDR { + UINT cmsg_len; //socklen_t cmsg_len + INT cmsg_level; //int cmsg_level + INT cmsg_type; //int cmsg_type; + followed by UCHAR cmsg_data[] +} +*/ +# define msg_name name +# define msg_namelen namelen +# define msg_iov lpBuffers +# define msg_iovlen dwBufferCount +# define msg_control Control.buf +# define msg_controllen Control.len +# define msg_flags dwFlags +# define iov_base buf +# define iov_len len + +# define cmsghdr _WSACMSGHDR +# ifdef CMSG_DATA +# undef CMSG_DATA +# endif +# define CMSG_DATA WSA_CMSG_DATA +#endif + #define MAX_USER_BUFF_SIZE ((size_t)(100*1024*1024)) #define DEFAULT_BUFF_SIZE 8192 @@ -132,7 +175,7 @@ static void do_from_to_zval_err(struct err_s *err, efree(user_msg); smart_str_free_ex(&path, 0); } -__attribute__ ((format (printf, 2, 3))) +ZEND_ATTRIBUTE_FORMAT(printf, 2 ,3) static void do_from_zval_err(ser_context *ctx, const char *fmt, ...) { va_list ap; @@ -141,7 +184,7 @@ static void do_from_zval_err(ser_context *ctx, const char *fmt, ...) do_from_to_zval_err(&ctx->err, &ctx->keys, "user", fmt, ap); va_end(ap); } -__attribute__ ((format (printf, 2, 3))) +ZEND_ATTRIBUTE_FORMAT(printf, 2 ,3) static void do_to_zval_err(res_context *ctx, const char *fmt, ...) { va_list ap; @@ -958,7 +1001,7 @@ static void to_zval_read_control_array(const char *msghdr_c, zval *zv, res_conte for (cmsg = CMSG_FIRSTHDR(msg); cmsg != NULL && !ctx->err.has_error; - cmsg = CMSG_NXTHDR(msg,cmsg)) { + cmsg = CMSG_NXTHDR(msg, cmsg)) { zval *elem; ALLOC_INIT_ZVAL(elem); @@ -1149,7 +1192,7 @@ static void to_zval_read_iov(const char *msghdr_c, zval *zv, res_context *ctx) for (i = 0; bytes_left > 0 && i < (uint)iovlen; i++) { zval *elem; - size_t len = MIN(msghdr->msg_iov[i].iov_len, bytes_left); + size_t len = MIN(msghdr->msg_iov[i].iov_len, (size_t)bytes_left); char *buf = safe_emalloc(1, len, 1); MAKE_STD_ZVAL(elem); diff --git a/ext/sockets/conversions.h b/ext/sockets/conversions.h index 70f31ba676e56..7d515246a0bc6 100644 --- a/ext/sockets/conversions.h +++ b/ext/sockets/conversions.h @@ -2,8 +2,14 @@ #define PHP_SOCK_CONVERSIONS_H 1 #include -#include -#include + +#ifndef PHP_WIN32 +# include +# include +#else +# include +#endif + #include "php_sockets.h" /* TYPE DEFINITIONS */ diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 78da0c29e68f2..a5699c75149fc 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -26,11 +26,13 @@ #if HAVE_SOCKETS +#include + extern zend_module_entry sockets_module_entry; #define phpext_sockets_ptr &sockets_module_entry #ifdef PHP_WIN32 -#include +#include #else #if HAVE_SYS_SOCKET_H #include diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index b83b3ae482378..f75fdcdedea4c 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -30,6 +30,44 @@ #define DEFAULT_BUFF_SIZE 8192 #define MAX_ARRAY_KEY_SIZE 128 +#ifdef PHP_WIN32 +#include "windows_common.h" +#include +#define IPV6_RECVPKTINFO IPV6_PKTINFO +#define IPV6_RECVHOPLIMIT IPV6_HOPLIMIT +#define msghdr _WSAMSG + +static GUID WSARecvMsg_GUID = WSAID_WSARECVMSG; +static __declspec(thread) LPFN_WSARECVMSG WSARecvMsg = NULL; +inline ssize_t recvmsg(int sockfd, struct msghdr *msg, int flags) +{ + DWORD recvd = 0, + bytesReturned; + + if (WSARecvMsg == NULL) { + int res = WSAIoctl((SOCKET) sockfd, SIO_GET_EXTENSION_FUNCTION_POINTER, + &WSARecvMsg_GUID, sizeof(WSARecvMsg_GUID), + &WSARecvMsg, sizeof(WSARecvMsg), + &bytesReturned, NULL, NULL); + if (res != 0) { + return -1; + } + } + + msg->dwFlags = (DWORD)flags; + return WSARecvMsg((SOCKET)sockfd, msg, &recvd, NULL, NULL) == 0 + ? (ssize_t)recvd + : -1; +} +inline ssize_t sendmsg(int sockfd, const struct msghdr *msg, int flags) +{ + DWORD sent = 0; + return WSASendMsg((SOCKET)sockfd, (struct msghdr*)msg, (DWORD)flags, &sent, NULL, NULL) == 0 + ? (ssize_t)sent + : -1; +} +#endif + #define LONG_CHECK_VALID_INT(l) \ do { \ if ((l) < INT_MIN && (l) > INT_MAX) { \ @@ -158,9 +196,7 @@ PHP_FUNCTION(socket_sendmsg) RETURN_LONG((long)res); } else { - SOCKETS_G(last_error) = errno; - php_error_docref(NULL TSRMLS_CC, E_WARNING, "error in sendmsg [%d]: %s", - errno, sockets_strerror(errno TSRMLS_CC)); + PHP_SOCKET_ERROR(php_sock, "error in sendmsg", errno); RETURN_FALSE; } } @@ -285,6 +321,18 @@ int php_do_setsockopt_ipv6_rfc3542(php_socket *php_sock, int level, int optname, switch (optname) { #ifdef IPV6_PKTINFO case IPV6_PKTINFO: +#ifdef PHP_WIN32 + if (Z_TYPE_PP(arg4) == IS_ARRAY) { + php_error_docref0(NULL TSRMLS_CC, E_WARNING, "Windows does not " + "support sticky IPV6_PKTINFO"); + return FAILURE; + } else { + /* windows has no IPV6_RECVPKTINFO, and uses IPV6_PKTINFO + * for the same effect. We define IPV6_RECVPKTINFO to be + * IPV6_PKTINFO, so assume the assume user used IPV6_RECVPKTINFO */ + return 1; + } +#endif opt_ptr = from_zval_run_conversions(*arg4, php_sock, from_zval_write_in6_pktinfo, sizeof(struct in6_pktinfo), "in6_pktinfo", &allocations, &err); if (err.has_error) { diff --git a/ext/sockets/sockaddr_conv.c b/ext/sockets/sockaddr_conv.c index 19c61740d0cf7..a40b6b4936cbb 100644 --- a/ext/sockets/sockaddr_conv.c +++ b/ext/sockets/sockaddr_conv.c @@ -3,7 +3,7 @@ #include "php_sockets.h" #ifdef PHP_WIN32 -#include +#include "windows_common.h" #else #include #include diff --git a/ext/sockets/sockaddr_conv.h b/ext/sockets/sockaddr_conv.h index 444d749fe7397..665c73913f108 100644 --- a/ext/sockets/sockaddr_conv.h +++ b/ext/sockets/sockaddr_conv.h @@ -1,8 +1,16 @@ #ifndef PHP_SOCKADR_CONV_H #define PHP_SOCKADR_CONV_H +#define HAVE_SOCKETS 1 #include -#include "php_sockets.h" +#include "php_sockets.h" /* php_socket */ + +#ifndef PHP_WIN32 +# include +#else +# include +#endif + /* * Convert an IPv6 literal or a hostname info a sockaddr_in6. diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 2aeb4b0fd3327..5636cd3cdc9d1 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -35,32 +35,12 @@ #include "ext/standard/info.h" #include "php_ini.h" #ifdef PHP_WIN32 -# include "win32/inet.h" -# include +# include "windows_common.h" +# include # include # include # include "php_sockets.h" -# include "win32/sockets.h" -# define IS_INVALID_SOCKET(a) (a->bsd_socket == INVALID_SOCKET) -# ifdef EPROTONOSUPPORT -# undef EPROTONOSUPPORT -# endif -# ifdef ECONNRESET -# undef ECONNRESET -# endif -# define EPROTONOSUPPORT WSAEPROTONOSUPPORT -# define ECONNRESET WSAECONNRESET -# ifdef errno -# undef errno -# endif -# define errno WSAGetLastError() -# define h_errno WSAGetLastError() -# define set_errno(a) WSASetLastError(a) -# define close(a) closesocket(a) -# include -# if _WIN32_WINNT >= 0x0600 -# define HAVE_IF_NAMETOINDEX 1 -# endif +# include #else # include # include @@ -650,8 +630,12 @@ PHP_MINIT_FUNCTION(sockets) REGISTER_LONG_CONSTANT("MSG_TRUNC", MSG_TRUNC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MSG_PEEK", MSG_PEEK, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("MSG_DONTROUTE", MSG_DONTROUTE, CONST_CS | CONST_PERSISTENT); +#ifdef MSG_EOR REGISTER_LONG_CONSTANT("MSG_EOR", MSG_EOR, CONST_CS | CONST_PERSISTENT); +#endif +#ifdef MSG_EOF REGISTER_LONG_CONSTANT("MSG_EOF", MSG_EOF, CONST_CS | CONST_PERSISTENT); +#endif #ifdef MSG_CONFIRM REGISTER_LONG_CONSTANT("MSG_CONFIRM", MSG_CONFIRM, CONST_CS | CONST_PERSISTENT); diff --git a/ext/sockets/tests/socket_sendrecvmsg_multi_msg-win32.phpt b/ext/sockets/tests/socket_sendrecvmsg_multi_msg-win32.phpt new file mode 100644 index 0000000000000..3aba012726f7b --- /dev/null +++ b/ext/sockets/tests/socket_sendrecvmsg_multi_msg-win32.phpt @@ -0,0 +1,110 @@ +--TEST-- +sendmsg()/recvmsg(): test ability to receive multiple messages (WIN32) +--SKIPIF-- + [ "addr" => "::1", "port" => 3000], + "iov" => ["test ", "thing", "\n"], + "control" => [[ + "level" => IPPROTO_IPV6, + "type" => IPV6_PKTINFO, + "data" => [ + 'addr' => '::1', + 'ifindex' => 1 /* we're assuming loopback is 1. Is this a safe assumption? */ + ], + ]] +], 0); +var_dump($r); +checktimeout($s, 500); + +$data = [ + "name" => ["family" => AF_INET6, "addr" => "::1"], + "buffer_size" => 2000, + "controllen" => socket_cmsg_space(IPPROTO_IPV6, IPV6_PKTINFO) + + socket_cmsg_space(IPPROTO_IPV6, IPV6_TCLASS), +]; +if (!socket_recvmsg($s, $data, 0)) die("recvmsg"); +print_r($data); + +--EXPECTF-- +creating send socket +resource(5) of type (Socket) +bool(true) +creating receive socket +resource(6) of type (Socket) +bool(true) +int(11) +Array +( + [name] => Array + ( + [family] => %d + [addr] => ::1 + [port] => 7001 + [flowinfo] => 0 + [scope_id] => 0 + ) + + [control] => Array + ( + [0] => Array + ( + [level] => %d + [type] => %d + [data] => Array + ( + [addr] => ::1 + [ifindex] => %d + ) + + ) + + [1] => Array + ( + [level] => %d + [type] => %d + [data] => 0 + ) + + ) + + [iov] => Array + ( + [0] => test thing + + ) + + [flags] => 0 +) diff --git a/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt b/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt index 055e263f724c1..212f7e186f216 100644 --- a/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt +++ b/ext/sockets/tests/socket_sendrecvmsg_multi_msg.phpt @@ -2,12 +2,15 @@ sendmsg()/recvmsg(): test ability to receive multiple messages --SKIPIF-- [[ "level" => IPPROTO_IPV6, "type" => IPV6_TCLASS, - "data" => 42, + "data" => 40, ]] ], 0); var_dump($r); @@ -88,7 +91,7 @@ Array ( [level] => %d [type] => %d - [data] => 42 + [data] => 40 ) ) diff --git a/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt b/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt index 53320cad0c3ae..27b6ae59c5d12 100644 --- a/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt +++ b/ext/sockets/tests/socket_set_option_in6_pktinfo.phpt @@ -8,7 +8,8 @@ die('skip sockets extension not available.'); if (!defined('IPPROTO_IPV6')) { die('skip IPv6 not available.'); } - +if (substr(PHP_OS, 0, 3) == 'WIN') + die('skip Not for Windows!'); --FILE-- +#include /* conflicting definition of CMSG_DATA */ + +#define HAVE_IF_NAMETOINDEX 1 + +#define IS_INVALID_SOCKET(a) (a->bsd_socket == INVALID_SOCKET) +#ifdef EPROTONOSUPPORT +# undef EPROTONOSUPPORT +#endif +#ifdef ECONNRESET +# undef ECONNRESET +#endif +#define EPROTONOSUPPORT WSAEPROTONOSUPPORT +#define ECONNRESET WSAECONNRESET +#ifdef errno +# undef errno +#endif +#define errno WSAGetLastError() +#define h_errno WSAGetLastError() +#define set_errno(a) WSASetLastError(a) +#define close(a) closesocket(a) + +#endif \ No newline at end of file From 608254fa5757ee07999d5c4bec660b8c29780938 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 16:24:02 +0100 Subject: [PATCH 2364/2394] Fix non-Windows build --- ext/sockets/conversions.c | 4 +++- main/php_network.h | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c index 6c79166806b5e..e3ff271f84628 100644 --- a/ext/sockets/conversions.c +++ b/ext/sockets/conversions.c @@ -1,7 +1,9 @@ #include "sockaddr_conv.h" #include "conversions.h" #include "sendrecvmsg.h" /* for ancillary registry */ -#include "windows_common.h" +#ifdef PHP_WIN32 +# include "windows_common.h" +#endif #include #include diff --git a/main/php_network.h b/main/php_network.h index 8ffb51ca40756..c1535ee040b64 100644 --- a/main/php_network.h +++ b/main/php_network.h @@ -21,6 +21,8 @@ #ifndef _PHP_NETWORK_H #define _PHP_NETWORK_H +#include + #ifdef PHP_WIN32 # include "win32/inet.h" #else From e2fc17c833c5122327438c82fc0dc4b689268f59 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Thu, 31 Jan 2013 16:34:46 +0100 Subject: [PATCH 2365/2394] Fix multicast.c not defining errno on Windows Small cleanups in includes as well. --- ext/sockets/multicast.c | 14 +------------- ext/sockets/sockaddr_conv.h | 1 - ext/sockets/windows_common.h | 2 ++ 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c index 5d29c9c5e265e..c6de3198e4658 100644 --- a/ext/sockets/multicast.c +++ b/ext/sockets/multicast.c @@ -28,19 +28,7 @@ #include "php_network.h" #ifdef PHP_WIN32 -# include "win32/inet.h" -# include -# include -# include -# include -# include "php_sockets.h" -# include "win32/sockets.h" -# define NTDDI_XP NTDDI_WINXP /* bug in SDK */ -# include -# undef NTDDI_XP -# if _WIN32_WINNT >= 0x0600 -# define HAVE_IF_NAMETOINDEX 1 -# endif +# include "windows_common.h" #else #include #include diff --git a/ext/sockets/sockaddr_conv.h b/ext/sockets/sockaddr_conv.h index 665c73913f108..8e51edac8f874 100644 --- a/ext/sockets/sockaddr_conv.h +++ b/ext/sockets/sockaddr_conv.h @@ -1,7 +1,6 @@ #ifndef PHP_SOCKADR_CONV_H #define PHP_SOCKADR_CONV_H -#define HAVE_SOCKETS 1 #include #include "php_sockets.h" /* php_socket */ diff --git a/ext/sockets/windows_common.h b/ext/sockets/windows_common.h index 1dc966ac00127..c72c6987e6850 100644 --- a/ext/sockets/windows_common.h +++ b/ext/sockets/windows_common.h @@ -17,7 +17,9 @@ #define WINDOWS_COMMON_H #include +#define NTDDI_XP NTDDI_WINXP /* bug in SDK */ #include /* conflicting definition of CMSG_DATA */ +#undef NTDDI_XP #define HAVE_IF_NAMETOINDEX 1 From 03b1da5d7ada4a80a91d9953c388fa05f294d711 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sat, 2 Feb 2013 18:39:47 +0100 Subject: [PATCH 2366/2394] php_strerror in ext/sockets renamed in 5.5 --- ext/sockets/php_sockets.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index 5082a9bc1e8b4..bad83b34ccca8 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -72,7 +72,7 @@ PHP_SOCKETS_API int php_sockets_le_socket(void); (socket)->error = _err; \ SOCKETS_G(last_error) = _err; \ if (_err != EAGAIN && _err != EWOULDBLOCK && _err != EINPROGRESS) { \ - php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s [%d]: %s", msg, _err, php_strerror(_err TSRMLS_CC)); \ + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s [%d]: %s", msg, _err, sockets_strerror(_err TSRMLS_CC)); \ } \ } while (0) From af1b90d62ba69953de2065864d2a1284314323ba Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 3 Feb 2013 01:22:44 +0100 Subject: [PATCH 2367/2394] Fix bug and hopefully build on WinSDK 6.1 There build was failing on rmtools on the sockets extension for two reasons: 1. IPV6_TCLASS and IPV6_RECVTCLASS not being defined. These are probably recent additions to SDK. Windows 7 doesn't event seem to have complete support for IPV6_TCLASS, not accepting in WSASendMsg(). The parts that needed this constant were not guarded by #ifdefs. They are now. 2. The constants EWOULDBLOCK and EINPROGRESS not being defined. These were only defined in php_network.h, outside of the extension, and not all source files included this header. Nevertheless, a macro defined in php_sockets.h needed these constants. When this macro was used in files that did not include php_network.h, the compilation would fail. Surprisingly, the build did not fail when using the 7.1 Windows SDK (more likely, the CRT headers used in VC10), as somehow errno.h was being included through some other standard header. This would make the constant EWOULDBLOCK defined; however, it would be defined to the wrong value. In the winsock context, WSAEWOULDBLOCK should be used instead. Because we have difficulty using Windows-only constants in the code, we (re)define EWOULDBLOCK to WSAEWOULDBLOCK. This has the obvious disavantage we may miss problems like this again in the future. --- ext/sockets/php_sockets.h | 3 ++ ext/sockets/sendrecvmsg.c | 6 ++- ext/sockets/windows_common.h | 95 ++++++++++++++++++++++++++++++++---- 3 files changed, 94 insertions(+), 10 deletions(-) diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h index bad83b34ccca8..dd2b9933f6e8b 100644 --- a/ext/sockets/php_sockets.h +++ b/ext/sockets/php_sockets.h @@ -27,6 +27,9 @@ #if HAVE_SOCKETS #include +#ifdef PHP_WIN32 +# include "windows_common.h" +#endif extern zend_module_entry sockets_module_entry; #define phpext_sockets_ptr &sockets_module_entry diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c index f75fdcdedea4c..50b43ec38a514 100644 --- a/ext/sockets/sendrecvmsg.c +++ b/ext/sockets/sendrecvmsg.c @@ -115,8 +115,10 @@ static void init_ancillary_registry(void) to_zval_read_int, IPPROTO_IPV6, IPV6_HOPLIMIT); #endif +#ifdef IPV6_TCLASS PUT_ENTRY(sizeof(int), 0, 0, from_zval_write_int, to_zval_read_int, IPPROTO_IPV6, IPV6_TCLASS); +#endif #ifdef SO_PASSCRED PUT_ENTRY(sizeof(struct ucred), 0, 0, from_zval_write_ucred, @@ -416,14 +418,16 @@ void php_socket_sendrecvmsg_init(INIT_FUNC_ARGS) REGISTER_LONG_CONSTANT("IPV6_RECVHOPOPTS", IPV6_RECVHOPOPTS, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_RECVDSTOPTS", IPV6_RECVDSTOPTS, CONST_CS | CONST_PERSISTENT); */ +#ifdef IPV6_RECVTCLASS REGISTER_LONG_CONSTANT("IPV6_RECVTCLASS", IPV6_RECVTCLASS, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IPV6_TCLASS", IPV6_TCLASS, CONST_CS | CONST_PERSISTENT); +#endif /* REGISTER_LONG_CONSTANT("IPV6_RTHDR", IPV6_RTHDR, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_HOPOPTS", IPV6_HOPOPTS, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IPV6_DSTOPTS", IPV6_DSTOPTS, CONST_CS | CONST_PERSISTENT); */ - REGISTER_LONG_CONSTANT("IPV6_TCLASS", IPV6_TCLASS, CONST_CS | CONST_PERSISTENT); #ifdef SCM_RIGHTS REGISTER_LONG_CONSTANT("SCM_RIGHTS", SCM_RIGHTS, CONST_CS | CONST_PERSISTENT); diff --git a/ext/sockets/windows_common.h b/ext/sockets/windows_common.h index c72c6987e6850..3a9cb59129284 100644 --- a/ext/sockets/windows_common.h +++ b/ext/sockets/windows_common.h @@ -24,14 +24,7 @@ #define HAVE_IF_NAMETOINDEX 1 #define IS_INVALID_SOCKET(a) (a->bsd_socket == INVALID_SOCKET) -#ifdef EPROTONOSUPPORT -# undef EPROTONOSUPPORT -#endif -#ifdef ECONNRESET -# undef ECONNRESET -#endif -#define EPROTONOSUPPORT WSAEPROTONOSUPPORT -#define ECONNRESET WSAECONNRESET + #ifdef errno # undef errno #endif @@ -40,4 +33,88 @@ #define set_errno(a) WSASetLastError(a) #define close(a) closesocket(a) -#endif \ No newline at end of file +#ifdef ENETUNREACH /* errno.h probably included */ +# undef EWOULDBLOCK +# undef EINPROGRESS +# undef EALREADY +# undef ENOTSOCK +# undef EDESTADDRREQ +# undef EMSGSIZE +# undef EPROTOTYPE +# undef ENOPROTOOPT +# undef EPROTONOSUPPORT +# undef ESOCKTNOSUPPORT +# undef EOPNOTSUPP +# undef EPFNOSUPPORT +# undef EAFNOSUPPORT +# undef EADDRINUSE +# undef EADDRNOTAVAIL +# undef ENETDOWN +# undef ENETUNREACH +# undef ENETRESET +# undef ECONNABORTED +# undef ECONNRESET +# undef ENOBUFS +# undef EISCONN +# undef ENOTCONN +# undef ESHUTDOWN +# undef ETOOMANYREFS +# undef ETIMEDOUT +# undef ECONNREFUSED +# undef ELOOP +# undef ENAMETOOLONG +# undef EHOSTDOWN +# undef EHOSTUNREACH +# undef ENOTEMPTY +# undef EPROCLIM +# undef EUSERS +# undef EDQUOT +# undef ESTALE +# undef EREMOTE + +# undef EAGAIN +#endif + +/* section disabled in WinSock2.h */ +#define EWOULDBLOCK WSAEWOULDBLOCK +#define EINPROGRESS WSAEINPROGRESS +#define EALREADY WSAEALREADY +#define ENOTSOCK WSAENOTSOCK +#define EDESTADDRREQ WSAEDESTADDRREQ +#define EMSGSIZE WSAEMSGSIZE +#define EPROTOTYPE WSAEPROTOTYPE +#define ENOPROTOOPT WSAENOPROTOOPT +#define EPROTONOSUPPORT WSAEPROTONOSUPPORT +#define ESOCKTNOSUPPORT WSAESOCKTNOSUPPORT +#define EOPNOTSUPP WSAEOPNOTSUPP +#define EPFNOSUPPORT WSAEPFNOSUPPORT +#define EAFNOSUPPORT WSAEAFNOSUPPORT +#define EADDRINUSE WSAEADDRINUSE +#define EADDRNOTAVAIL WSAEADDRNOTAVAIL +#define ENETDOWN WSAENETDOWN +#define ENETUNREACH WSAENETUNREACH +#define ENETRESET WSAENETRESET +#define ECONNABORTED WSAECONNABORTED +#define ECONNRESET WSAECONNRESET +#define ENOBUFS WSAENOBUFS +#define EISCONN WSAEISCONN +#define ENOTCONN WSAENOTCONN +#define ESHUTDOWN WSAESHUTDOWN +#define ETOOMANYREFS WSAETOOMANYREFS +#define ETIMEDOUT WSAETIMEDOUT +#define ECONNREFUSED WSAECONNREFUSED +#define ELOOP WSAELOOP +#define ENAMETOOLONG WSAENAMETOOLONG +#define EHOSTDOWN WSAEHOSTDOWN +#define EHOSTUNREACH WSAEHOSTUNREACH +#define ENOTEMPTY WSAENOTEMPTY +#define EPROCLIM WSAEPROCLIM +#define EUSERS WSAEUSERS +#define EDQUOT WSAEDQUOT +#define ESTALE WSAESTALE +#define EREMOTE WSAEREMOTE + +/* and an extra one */ +#define EAGAIN WSAEWOULDBLOCK + +#endif From a000920dfb099fac3b58ea344d33f4b6c3ee51a1 Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 3 Feb 2013 01:59:35 +0100 Subject: [PATCH 2368/2394] NEWS/UPGRADING for changes in sockets, intl --- NEWS | 8 ++++++++ UPGRADING | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/NEWS b/NEWS index e79cffed23749..11ae31cf44fb2 100644 --- a/NEWS +++ b/NEWS @@ -16,6 +16,14 @@ PHP NEWS . Implemented FR #46439 - added CURLFile for safer file uploads. (Stas) +- Intl: + . Cherry-picked UConverter wrapper, which had accidentaly been committed only + to master. + +- Sockets: + . Added recvmsg() and sendmsg() wrappers. (Gustavo) + See https://wiki.php.net/rfc/sendrecvmsg + 24 Jan 2013, PHP 5.5.0 Alpha 4 - Core: diff --git a/UPGRADING b/UPGRADING index 22ad969157cf9..790803e395737 100755 --- a/UPGRADING +++ b/UPGRADING @@ -157,6 +157,8 @@ PHP 5.5 UPGRADE NOTES Expires headers. (see https://wiki.php.net/rfc/cookie_max-age) - curl_setopt now accepts new option CURLOPT_SAFE_UPLOAD and CURLFile object for safer file uploads (see https://wiki.php.net/rfc/curl-file-upload) +- Functions in the socket extension now do not emit warnings when the errno is + EAGAIN, EWOULDBLOCK or EINPROGRESS. ======================================== 5. New Functions @@ -257,6 +259,11 @@ PHP 5.5 UPGRADE NOTES - IntlDateFormatter::getTimeZone() - IntlDateFormatter::setTimeZone() +- Sockets: + - socket_sendmsg() + - socket_recvmsg() + - socket_cmsg_space() + - SPL: - SplFixedArray::__wakeup() @@ -271,6 +278,7 @@ PHP 5.5 UPGRADE NOTES - IntlBreakIterator - IntlRuleBasedBreakIterator - IntlCodePointBreakIterator + - UConverter - cURL: - CURLFile From 8771c265a43dac2e44aa4ae7af66a6534b0c70ae Mon Sep 17 00:00:00 2001 From: Gustavo Lopes Date: Sun, 3 Feb 2013 02:00:48 +0100 Subject: [PATCH 2369/2394] Fix test on Windows. Windows complains of invalid parameters because the socket is not bound. The test expected the error to be EAGAIN/EWOULDBLOCK. Moved the call down, after the socket is bound. --- ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt b/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt index 00d69a855fb08..5aeaa0824fa10 100644 --- a/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt +++ b/ext/sockets/tests/socket_sentto_recvfrom_ipv4_udp.phpt @@ -14,12 +14,14 @@ if (!extension_loaded('sockets')) { if (!socket_set_nonblock($socket)) { die('Unable to set nonblocking mode for socket'); } - var_dump(socket_recvfrom($socket, $buf, 12, 0, $from, $port)); //false (EAGAIN - no warning) + $address = '127.0.0.1'; socket_sendto($socket, '', 1, 0, $address); // cause warning if (!socket_bind($socket, $address, 1223)) { die("Unable to bind to $address:1223"); } + + var_dump(socket_recvfrom($socket, $buf, 12, 0, $from, $port)); //false (EAGAIN - no warning) $msg = "Ping!"; $len = strlen($msg); @@ -44,9 +46,9 @@ if (!extension_loaded('sockets')) { socket_close($socket); --EXPECTF-- -bool(false) Warning: Wrong parameter count for socket_sendto() in %s on line %d +bool(false) Warning: socket_recvfrom() expects at least 5 parameters, 4 given in %s on line %d From 2f334438836f37b82d739b20a4d0f875278e4766 Mon Sep 17 00:00:00 2001 From: Martin Jansen Date: Mon, 24 Dec 2012 14:14:24 +0100 Subject: [PATCH 2370/2394] ext/filter support for validating MAC addresses. --- ext/filter/filter.c | 2 ++ ext/filter/filter_private.h | 3 ++- ext/filter/logical_filters.c | 48 ++++++++++++++++++++++++++++++++++++ ext/filter/php_filter.h | 1 + ext/filter/tests/008.phpt | 26 ++++++++++--------- ext/filter/tests/033.phpt | 39 +++++++++++++++-------------- ext/filter/tests/033_run.inc | 6 +++-- ext/filter/tests/055.phpt | 34 +++++++++++++++++++++++++ 8 files changed, 125 insertions(+), 34 deletions(-) create mode 100644 ext/filter/tests/055.phpt diff --git a/ext/filter/filter.c b/ext/filter/filter.c index 2aa8dd57d9c0c..da951feb042dd 100644 --- a/ext/filter/filter.c +++ b/ext/filter/filter.c @@ -47,6 +47,7 @@ static const filter_list_entry filter_list[] = { { "validate_url", FILTER_VALIDATE_URL, php_filter_validate_url }, { "validate_email", FILTER_VALIDATE_EMAIL, php_filter_validate_email }, { "validate_ip", FILTER_VALIDATE_IP, php_filter_validate_ip }, + { "validate_mac", FILTER_VALIDATE_MAC, php_filter_validate_mac }, { "string", FILTER_SANITIZE_STRING, php_filter_string }, { "stripped", FILTER_SANITIZE_STRING, php_filter_string }, @@ -233,6 +234,7 @@ PHP_MINIT_FUNCTION(filter) REGISTER_LONG_CONSTANT("FILTER_VALIDATE_URL", FILTER_VALIDATE_URL, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("FILTER_VALIDATE_EMAIL", FILTER_VALIDATE_EMAIL, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("FILTER_VALIDATE_IP", FILTER_VALIDATE_IP, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("FILTER_VALIDATE_MAC", FILTER_VALIDATE_MAC, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("FILTER_DEFAULT", FILTER_DEFAULT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("FILTER_UNSAFE_RAW", FILTER_UNSAFE_RAW, CONST_CS | CONST_PERSISTENT); diff --git a/ext/filter/filter_private.h b/ext/filter/filter_private.h index 9bc53a0e4757f..65e61dfea7fdb 100644 --- a/ext/filter/filter_private.h +++ b/ext/filter/filter_private.h @@ -63,7 +63,8 @@ #define FILTER_VALIDATE_URL 0x0111 #define FILTER_VALIDATE_EMAIL 0x0112 #define FILTER_VALIDATE_IP 0x0113 -#define FILTER_VALIDATE_LAST 0x0113 +#define FILTER_VALIDATE_MAC 0x0114 +#define FILTER_VALIDATE_LAST 0x0114 #define FILTER_VALIDATE_ALL 0x0100 diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index 58d5870c112e1..52d948b188967 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -784,6 +784,54 @@ void php_filter_validate_ip(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ } /* }}} */ +void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ +{ + char *input = Z_STRVAL_P(value); + int input_len = Z_STRLEN_P(value); + int tokens, length, i, offset; + char separator; + long ret = 0; + + if (14 == input_len) { + /* EUI-64 format: Four hexadecimal digits separated by dots. Less + * commonly used but valid nonetheless. + */ + tokens = 3; + length = 4; + separator = '.'; + } else if (17 == input_len && memchr(input + 2, '-', 1)) { + /* IEEE 802 format: Six hexadecimal digits separated by hyphens. */ + tokens = 6; + length = 2; + separator = '-'; + } else if (17 == input_len && memchr(input + 2, ':', 1)) { + /* IEEE 802 format: Six hexadecimal digits separated by colons. */ + tokens = 6; + length = 2; + separator = ':'; + } else { + RETURN_VALIDATION_FAILED; + } + + /* Essentially what we now have is a set of tokens each consisting of + * a hexadecimal number followed by a separator character. (With the + * exception of the last token which does not have the separator.) + */ + for (i = 0; i < tokens; i++) { + offset = i * (length + 1); + + if (i < tokens - 1 && !memchr(input + offset + length, separator, 1)) { + /* The current token did not end with e.g. a "." */ + RETURN_VALIDATION_FAILED + } + if (php_filter_parse_hex(input + offset, length, &ret) < 0) { + /* The current token is no valid hexadecimal digit */ + RETURN_VALIDATION_FAILED + } + } +} +/* }}} */ + /* * Local variables: * tab-width: 4 diff --git a/ext/filter/php_filter.h b/ext/filter/php_filter.h index cbe1c4720093b..e31f0f08175d3 100644 --- a/ext/filter/php_filter.h +++ b/ext/filter/php_filter.h @@ -78,6 +78,7 @@ void php_filter_validate_regexp(PHP_INPUT_FILTER_PARAM_DECL); void php_filter_validate_url(PHP_INPUT_FILTER_PARAM_DECL); void php_filter_validate_email(PHP_INPUT_FILTER_PARAM_DECL); void php_filter_validate_ip(PHP_INPUT_FILTER_PARAM_DECL); +void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL); void php_filter_string(PHP_INPUT_FILTER_PARAM_DECL); void php_filter_encoded(PHP_INPUT_FILTER_PARAM_DECL); diff --git a/ext/filter/tests/008.phpt b/ext/filter/tests/008.phpt index 8a4340542f2d4..a499219ee76e5 100644 --- a/ext/filter/tests/008.phpt +++ b/ext/filter/tests/008.phpt @@ -11,7 +11,7 @@ var_dump(filter_list(array())); echo "Done\n"; ?> --EXPECTF-- -array(19) { +array(20) { [0]=> string(3) "int" [1]=> @@ -27,28 +27,30 @@ array(19) { [6]=> string(11) "validate_ip" [7]=> - string(6) "string" + string(12) "validate_mac" [8]=> - string(8) "stripped" + string(6) "string" [9]=> - string(7) "encoded" + string(8) "stripped" [10]=> - string(13) "special_chars" + string(7) "encoded" [11]=> - string(18) "full_special_chars" + string(13) "special_chars" [12]=> - string(10) "unsafe_raw" + string(18) "full_special_chars" [13]=> - string(5) "email" + string(10) "unsafe_raw" [14]=> - string(3) "url" + string(5) "email" [15]=> - string(10) "number_int" + string(3) "url" [16]=> - string(12) "number_float" + string(10) "number_int" [17]=> - string(12) "magic_quotes" + string(12) "number_float" [18]=> + string(12) "magic_quotes" + [19]=> string(8) "callback" } diff --git a/ext/filter/tests/033.phpt b/ext/filter/tests/033.phpt index 04daa61333970..d76f9ab3b8a55 100644 --- a/ext/filter/tests/033.phpt +++ b/ext/filter/tests/033.phpt @@ -10,22 +10,23 @@ default_charset=UTF-8 include dirname(__FILE__) . '/033_run.inc'; ?> --EXPECT-- -int 1 123 -boolean 1 -float 1 123 -validate_regexp O'Henry -validate_url http://a.b.c -validate_email foo@bar.com -validate_ip 1.2.3.4 -string PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc() O'Henry í•˜í¼ -stripped PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc() O'Henry í•˜í¼ -encoded PHP 1 foo%40bar.com http%3A%2F%2Fa.b.c 1.2.3.4 123 123abc%3C%3E%28%29 O%27Henry %ED%95%98%ED%8D%BC -special_chars PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry í•˜í¼ -full_special_chars PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry í•˜í¼ -unsafe_raw PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry í•˜í¼ -email PHP 1 foo@bar.com httpa.b.c 1.2.3.4 123 123abc O'Henry -url PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry -number_int 1 1234 123 123 -number_float 1 1234 123 123 -magic_quotes PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O\'Henry í•˜í¼ -callback PHP 1 FOO@BAR.COM HTTP://A.B.C 1.2.3.4 123 123ABC<>() O'HENRY í•˜í¼ +int 1 123 +boolean 1 +float 1 123 +validate_regexp O'Henry +validate_url http://a.b.c +validate_email foo@bar.com +validate_ip 1.2.3.4 +validate_mac aa:bb:cc:dd:ee:ff +string PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc() O'Henry í•˜í¼ aa:bb:cc:dd:ee:ff +stripped PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc() O'Henry í•˜í¼ aa:bb:cc:dd:ee:ff +encoded PHP 1 foo%40bar.com http%3A%2F%2Fa.b.c 1.2.3.4 123 123abc%3C%3E%28%29 O%27Henry %ED%95%98%ED%8D%BCaa%3Abb%3Acc%3Add%3Aee%3Aff +special_chars PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry í•˜í¼ aa:bb:cc:dd:ee:ff +full_special_chars PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry í•˜í¼ aa:bb:cc:dd:ee:ff +unsafe_raw PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry í•˜í¼ aa:bb:cc:dd:ee:ff +email PHP 1 foo@bar.com httpa.b.c 1.2.3.4 123 123abc O'Henry aabbccddeeff +url PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O'Henry aa:bb:cc:dd:ee:ff +number_int 1 1234 123 123 +number_float 1 1234 123 123 +magic_quotes PHP 1 foo@bar.com http://a.b.c 1.2.3.4 123 123abc<>() O\'Henry í•˜í¼ aa:bb:cc:dd:ee:ff +callback PHP 1 FOO@BAR.COM HTTP://A.B.C 1.2.3.4 123 123ABC<>() O'HENRY í•˜í¼ AA:BB:CC:DD:EE:FF \ No newline at end of file diff --git a/ext/filter/tests/033_run.inc b/ext/filter/tests/033_run.inc index e3b67387ca2a9..ecb2cf7be160d 100644 --- a/ext/filter/tests/033_run.inc +++ b/ext/filter/tests/033_run.inc @@ -16,7 +16,8 @@ $data = array( "123", "123abc<>()", "O'Henry", - "하í¼" + "하í¼", + "aa:bb:cc:dd:ee:ff", ); @@ -35,6 +36,7 @@ foreach(filter_list() as $filter) { printf("%-5s",$result[5]); printf("%-20s",$result[6]); printf("%-15s",$result[7]); - printf("%-10s\n",$result[8]); + printf("%-10s",$result[8]); + printf("%-10s\n",$result[9]); } ?> diff --git a/ext/filter/tests/055.phpt b/ext/filter/tests/055.phpt new file mode 100644 index 0000000000000..bf94f3515f175 --- /dev/null +++ b/ext/filter/tests/055.phpt @@ -0,0 +1,34 @@ +--TEST-- +filter_var() and FILTER_VALIDATE_MAC +--SKIPIF-- + +--FILE-- + +--EXPECT-- +string(17) "01-23-45-67-89-ab" +string(17) "01-23-45-67-89-AB" +string(17) "01-23-45-67-89-aB" +string(17) "01:23:45:67:89:ab" +string(17) "01:23:45:67:89:AB" +string(17) "01:23:45:67:89:aB" +bool(false) +bool(false) +string(14) "0123.4567.89ab" +Done From 0661d03ebaab6cf1eff156a4dd203299d0385ae9 Mon Sep 17 00:00:00 2001 From: Martin Jansen Date: Fri, 28 Dec 2012 15:20:19 +0100 Subject: [PATCH 2371/2394] There is no need to use memchr() for comparisons in these places. --- ext/filter/logical_filters.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index 52d948b188967..fededcf715b14 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -799,12 +799,12 @@ void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ tokens = 3; length = 4; separator = '.'; - } else if (17 == input_len && memchr(input + 2, '-', 1)) { + } else if (17 == input_len && input[2] == '-') { /* IEEE 802 format: Six hexadecimal digits separated by hyphens. */ tokens = 6; length = 2; separator = '-'; - } else if (17 == input_len && memchr(input + 2, ':', 1)) { + } else if (17 == input_len && input[2] == ':') { /* IEEE 802 format: Six hexadecimal digits separated by colons. */ tokens = 6; length = 2; @@ -820,7 +820,7 @@ void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ for (i = 0; i < tokens; i++) { offset = i * (length + 1); - if (i < tokens - 1 && !memchr(input + offset + length, separator, 1)) { + if (i < tokens - 1 && input[offset + length] != separator) { /* The current token did not end with e.g. a "." */ RETURN_VALIDATION_FAILED } From 6186b676000f74af92b979382f605ed104b6a4bc Mon Sep 17 00:00:00 2001 From: Martin Jansen Date: Sat, 5 Jan 2013 22:46:14 +0100 Subject: [PATCH 2372/2394] Add option to specific the expected separator character. --- ext/filter/logical_filters.c | 15 ++++++++++++++- ext/filter/tests/055.phpt | 36 +++++++++++++++++++++++++----------- 2 files changed, 39 insertions(+), 12 deletions(-) diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index fededcf715b14..9b436a779e6ec 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -788,9 +788,18 @@ void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ { char *input = Z_STRVAL_P(value); int input_len = Z_STRLEN_P(value); - int tokens, length, i, offset; + int tokens, length, i, offset, exp_separator_set, exp_separator_len; char separator; + char *exp_separator; long ret = 0; + zval **option_val; + + FETCH_STRING_OPTION(exp_separator, "separator"); + + if (exp_separator_set && exp_separator_len != 1) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Separator must be exactly one character long"); + RETURN_VALIDATION_FAILED; + } if (14 == input_len) { /* EUI-64 format: Four hexadecimal digits separated by dots. Less @@ -813,6 +822,10 @@ void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ RETURN_VALIDATION_FAILED; } + if (exp_separator_set && separator != exp_separator[0]) { + RETURN_VALIDATION_FAILED; + } + /* Essentially what we now have is a set of tokens each consisting of * a hexadecimal number followed by a separator character. (With the * exception of the last token which does not have the separator.) diff --git a/ext/filter/tests/055.phpt b/ext/filter/tests/055.phpt index bf94f3515f175..688dbb2b54034 100644 --- a/ext/filter/tests/055.phpt +++ b/ext/filter/tests/055.phpt @@ -5,24 +5,32 @@ filter_var() and FILTER_VALIDATE_MAC --FILE-- array("separator" => "-"))), + array("01-23-45-67-89-ab", array("options" => array("separator" => "."))), + array("01-23-45-67-89-ab", array("options" => array("separator" => ":"))), + array("01-23-45-67-89-AB", null), + array("01-23-45-67-89-aB", null), + array("01:23:45:67:89:ab", null), + array("01:23:45:67:89:AB", null), + array("01:23:45:67:89:aB", null), + array("01:23:45-67:89:aB", null), + array("xx:23:45:67:89:aB", null), + array("0123.4567.89ab", null), + array("01-23-45-67-89-ab", array("options" => array("separator" => "--"))), + array("01-23-45-67-89-ab", array("options" => array("separator" => ""))), ); foreach ($values as $value) { - var_dump(filter_var($value, FILTER_VALIDATE_MAC)); + var_dump(filter_var($value[0], FILTER_VALIDATE_MAC, $value[1])); } echo "Done\n"; ?> ---EXPECT-- +--EXPECTF-- string(17) "01-23-45-67-89-ab" +string(17) "01-23-45-67-89-ab" +bool(false) +bool(false) string(17) "01-23-45-67-89-AB" string(17) "01-23-45-67-89-aB" string(17) "01:23:45:67:89:ab" @@ -31,4 +39,10 @@ string(17) "01:23:45:67:89:aB" bool(false) bool(false) string(14) "0123.4567.89ab" + +Warning: filter_var(): Separator must be exactly one character long in %s055.php on line %d +bool(false) + +Warning: filter_var(): Separator must be exactly one character long in %s055.php on line %d +bool(false) Done From 60b5f6d4632260a90e0a59838aa672ba2376bffa Mon Sep 17 00:00:00 2001 From: Martin Jansen Date: Sun, 3 Feb 2013 13:27:36 +0100 Subject: [PATCH 2373/2394] News about FR #49180. --- NEWS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/NEWS b/NEWS index 11ae31cf44fb2..c343f4315a511 100644 --- a/NEWS +++ b/NEWS @@ -24,6 +24,9 @@ PHP NEWS . Added recvmsg() and sendmsg() wrappers. (Gustavo) See https://wiki.php.net/rfc/sendrecvmsg +- Filter: + . Implemented FR #49180 - added MAC address validation. (Martin) + 24 Jan 2013, PHP 5.5.0 Alpha 4 - Core: From 7369a683797faa262b5aa859cf7347b14e74405c Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sun, 3 Feb 2013 10:57:31 -0200 Subject: [PATCH 2374/2394] - Fixed ZTS build --- ext/filter/logical_filters.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c index 9b436a779e6ec..b8df2183b9d86 100644 --- a/ext/filter/logical_filters.c +++ b/ext/filter/logical_filters.c @@ -837,7 +837,7 @@ void php_filter_validate_mac(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */ /* The current token did not end with e.g. a "." */ RETURN_VALIDATION_FAILED } - if (php_filter_parse_hex(input + offset, length, &ret) < 0) { + if (php_filter_parse_hex(input + offset, length, &ret TSRMLS_CC) < 0) { /* The current token is no valid hexadecimal digit */ RETURN_VALIDATION_FAILED } From 53159f6e05bc0c7879e2cb2fc275c3269ff239f1 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Mon, 4 Feb 2013 14:20:50 +0800 Subject: [PATCH 2375/2394] implicit declaration of zend_throw_exception --- ext/curl/curl_file.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/curl/curl_file.c b/ext/curl/curl_file.c index 27176784abc05..b7cc4495015d8 100644 --- a/ext/curl/curl_file.c +++ b/ext/curl/curl_file.c @@ -23,6 +23,7 @@ #endif #include "php.h" +#include "Zend/zend_exceptions.h" #include "php_curl.h" #if HAVE_CURL From 6585a7bd7904fac22640eb38a7eab53fe8efc19a Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 4 Feb 2013 15:27:43 +0100 Subject: [PATCH 2376/2394] NEWS --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index c343f4315a511..cb1ec95e9845d 100644 --- a/NEWS +++ b/NEWS @@ -8,6 +8,7 @@ PHP NEWS . Implemented FR #60524 (specify temp dir by php.ini). (ALeX Kazik). . Fixed bug #63830 (Segfault on undefined function call in nested generator). (Nikita Popov) + . Fixed bug #64142 (dval to lval different behavior on ppc64). (Remi) - CLI server: . Fixed bug #64128 (buit-in web server is broken on ppc64). (Remi) From 72a728872b0827b83c48e16812d746585b72303a Mon Sep 17 00:00:00 2001 From: Ard Biesheuvel Date: Tue, 5 Feb 2013 10:23:35 +0100 Subject: [PATCH 2377/2394] Update config.guess to latest GPLv2 upstream version This adds the ability to configure/build *on* 64-bit ARMv8, which uses the host triplet 'aarch64-linux-gnu'. Source: http://git.savannah.gnu.org/gitweb/?p=config.git;h=306afce --- config.guess | 505 ++++++++++++++++++++++++++------------------------- 1 file changed, 258 insertions(+), 247 deletions(-) diff --git a/config.guess b/config.guess index d407b8cde6fbc..b94cde8ef2e0f 100644 --- a/config.guess +++ b/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 -# Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011, 2012, 2013 Free Software Foundation, Inc. -timestamp='2008-01-23' +timestamp='2012-12-23' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -17,9 +17,7 @@ timestamp='2008-01-23' # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA -# 02110-1301, USA. +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -27,16 +25,16 @@ timestamp='2008-01-23' # the same distribution terms that you use for the rest of that program. -# Originally written by Per Bothner . -# Please send patches to . Submit a context -# diff and a properly formatted ChangeLog entry. +# Originally written by Per Bothner. Please send patches (context +# diff format) to and include a ChangeLog +# entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # -# The plan is that this can be called by configure scripts if you -# don't specify an explicit build system type. +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD me=`echo "$0" | sed -e 's,.*/,,'` @@ -56,8 +54,9 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, +2012, 2013 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -144,7 +143,7 @@ UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or - # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, + # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward @@ -170,7 +169,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep __ELF__ >/dev/null + | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? @@ -180,7 +179,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in fi ;; *) - os=netbsd + os=netbsd ;; esac # The OS release @@ -201,6 +200,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit ;; + *:Bitrig:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} + exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} @@ -223,7 +226,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on @@ -269,7 +272,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - exit ;; + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + exitcode=$? + trap '' 0 + exit $exitcode ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead @@ -295,12 +301,12 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in echo s390-ibm-zvmoe exit ;; *:OS400:*:*) - echo powerpc-ibm-os400 + echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit ;; - arm:riscos:*:*|arm:RISCOS:*:*) + arm*:riscos:*:*|arm*:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) @@ -324,14 +330,33 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; + s390x:SunOS:*:*) + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; + i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) + echo i386-pc-auroraux${UNAME_RELEASE} + exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + eval $set_cc_for_build + SUN_ARCH="i386" + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH="x86_64" + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize @@ -375,23 +400,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} - exit ;; + exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} - exit ;; + echo m68k-milan-mint${UNAME_RELEASE} + exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} - exit ;; + echo m68k-hades-mint${UNAME_RELEASE} + exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} - exit ;; + echo m68k-unknown-mint${UNAME_RELEASE} + exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; @@ -461,8 +486,8 @@ EOF echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` + # DG/UX returns AViiON for all architectures + UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ @@ -475,7 +500,7 @@ EOF else echo i586-dg-dgux${UNAME_RELEASE} fi - exit ;; + exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; @@ -575,52 +600,52 @@ EOF 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case "${sc_cpu_version}" in + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac + esac ;; + esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + sed 's/^ //' << EOF >$dummy.c - #define _HPUX_SOURCE - #include - #include + #define _HPUX_SOURCE + #include + #include - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa @@ -640,7 +665,7 @@ EOF # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | - grep __LP64__ >/dev/null + grep -q __LP64__ then HP_ARCH="hppa2.0w" else @@ -711,22 +736,22 @@ EOF exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd - exit ;; + exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi - exit ;; + exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd - exit ;; + exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd - exit ;; + exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd - exit ;; + exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; @@ -750,14 +775,14 @@ EOF exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} @@ -769,34 +794,39 @@ EOF echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) - case ${UNAME_MACHINE} in - pc98) - echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + UNAME_PROCESSOR=`/usr/bin/uname -p` + case ${UNAME_PROCESSOR} in amd64) echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; *) - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; + *:MINGW64*:*) + echo ${UNAME_MACHINE}-pc-mingw64 + exit ;; *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; + i*:MSYS*:*) + echo ${UNAME_MACHINE}-pc-msys + exit ;; i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; - *:Interix*:[3456]*) - case ${UNAME_MACHINE} in + *:Interix*:*) + case ${UNAME_MACHINE} in x86) echo i586-pc-interix${UNAME_RELEASE} exit ;; - EM64T | authenticamd) + authenticamd | genuineintel | EM64T) echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; IA64) @@ -806,6 +836,9 @@ EOF [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we @@ -835,6 +868,27 @@ EOF i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; + aarch64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + aarch64_be:Linux:*:*) + UNAME_MACHINE=aarch64_be + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + alpha:Linux:*:*) + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; + esac + objdump --private-headers /bin/sh | grep -q ld.so.1 + if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi + echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + exit ;; arm*:Linux:*:*) eval $set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ @@ -842,20 +896,40 @@ EOF then echo ${UNAME_MACHINE}-unknown-linux-gnu else - echo ${UNAME_MACHINE}-unknown-linux-gnueabi + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-gnueabi + else + echo ${UNAME_MACHINE}-unknown-linux-gnueabihf + fi fi exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) - echo cris-axis-linux-gnu + echo ${UNAME_MACHINE}-axis-linux-gnu exit ;; crisv32:Linux:*:*) - echo crisv32-axis-linux-gnu + echo ${UNAME_MACHINE}-axis-linux-gnu exit ;; frv:Linux:*:*) - echo frv-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + hexagon:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + i*86:Linux:*:*) + LIBC=gnu + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #ifdef __dietlibc__ + LIBC=dietlibc + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` + echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -866,74 +940,33 @@ EOF m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; - mips:Linux:*:*) + mips:Linux:*:* | mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU - #undef mips - #undef mipsel + #undef ${UNAME_MACHINE} + #undef ${UNAME_MACHINE}el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=mipsel + CPU=${UNAME_MACHINE}el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=mips + CPU=${UNAME_MACHINE} #else CPU= #endif #endif EOF - eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' - /^CPU/{ - s: ::g - p - }'`" - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } - ;; - mips64:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #undef CPU - #undef mips64 - #undef mips64el - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=mips64el - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=mips64 - #else - CPU= - #endif - #endif -EOF - eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' - /^CPU/{ - s: ::g - p - }'`" + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; or32:Linux:*:*) - echo or32-unknown-linux-gnu - exit ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-gnu + padre:Linux:*:*) + echo sparc-unknown-linux-gnu exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null - if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi - echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + parisc64:Linux:*:* | hppa64:Linux:*:*) + echo hppa64-unknown-linux-gnu exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level @@ -943,14 +976,17 @@ EOF *) echo hppa-unknown-linux-gnu ;; esac exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-gnu + ppc64:Linux:*:*) + echo powerpc64-unknown-linux-gnu + exit ;; + ppc:Linux:*:*) + echo powerpc-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -958,78 +994,18 @@ EOF sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; + tile*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; vax:Linux:*:*) echo ${UNAME_MACHINE}-dec-linux-gnu exit ;; x86_64:Linux:*:*) - echo x86_64-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; xtensa*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; - i*86:Linux:*:*) - # The BFD linker knows what the default object file format is, so - # first see if it will tell us. cd to the root directory to prevent - # problems with other programs or directories called `ld' in the path. - # Set LC_ALL=C to ensure ld outputs messages in English. - ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ - | sed -ne '/supported targets:/!d - s/[ ][ ]*/ /g - s/.*supported targets: *// - s/ .*// - p'` - case "$ld_supported_targets" in - elf32-i386) - TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" - ;; - a.out-i386-linux) - echo "${UNAME_MACHINE}-pc-linux-gnuaout" - exit ;; - coff-i386) - echo "${UNAME_MACHINE}-pc-linux-gnucoff" - exit ;; - "") - # Either a pre-BFD a.out linker (linux-gnuoldld) or - # one that does not give us useful --help. - echo "${UNAME_MACHINE}-pc-linux-gnuoldld" - exit ;; - esac - # Determine whether the default compiler is a.out or elf - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - #ifdef __ELF__ - # ifdef __GLIBC__ - # if __GLIBC__ >= 2 - LIBC=gnu - # else - LIBC=gnulibc1 - # endif - # else - LIBC=gnulibc1 - # endif - #else - #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) - LIBC=gnu - #else - LIBC=gnuaout - #endif - #endif - #ifdef __dietlibc__ - LIBC=dietlibc - #endif -EOF - eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' - /^LIBC/{ - s: ::g - p - }'`" - test x"${LIBC}" != x && { - echo "${UNAME_MACHINE}-pc-linux-${LIBC}" - exit - } - test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } - ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both @@ -1037,11 +1013,11 @@ EOF echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, + # Unixware is an offshoot of SVR4, but it has its own version + # number series starting with 2... + # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. + # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) @@ -1058,7 +1034,7 @@ EOF i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) @@ -1073,7 +1049,7 @@ EOF fi exit ;; i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. + # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; @@ -1101,10 +1077,13 @@ EOF exit ;; pc:*:*:*) # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i386. - echo i386-pc-msdosdjgpp - exit ;; + # uname -m prints for DJGPP always 'pc', but it prints nothing about + # the processor, so we play safe by assuming i586. + # Note: whatever this is, it MUST be the same as what config.sub + # prints for the "djgpp" host, or else GDB configury will decide that + # this is a cross-build. + echo i586-pc-msdosdjgpp + exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; @@ -1139,8 +1118,18 @@ EOF /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4; exit; } ;; + NCR*:*:4.2:* | MPRAS*:*:4.2:*) + OS_REL='.3' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; @@ -1153,7 +1142,7 @@ EOF rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) @@ -1173,10 +1162,10 @@ EOF echo ns32k-sni-sysv fi exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - echo i586-unisys-sysv4 - exit ;; + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says + echo i586-unisys-sysv4 + exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm @@ -1202,11 +1191,11 @@ EOF exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} + echo mips-nec-sysv${UNAME_RELEASE} else - echo mips-unknown-sysv${UNAME_RELEASE} + echo mips-unknown-sysv${UNAME_RELEASE} fi - exit ;; + exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; @@ -1216,6 +1205,12 @@ EOF BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; + BePC:Haiku:*:*) # Haiku running on Intel PC compatible. + echo i586-pc-haiku + exit ;; + x86_64:Haiku:*:*) + echo x86_64-unknown-haiku + exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; @@ -1243,6 +1238,16 @@ EOF *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in + i386) + eval $set_cc_for_build + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + UNAME_PROCESSOR="x86_64" + fi + fi ;; unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} @@ -1258,7 +1263,10 @@ EOF *:QNX:*:4*) echo i386-pc-qnx exit ;; - NSE-?:NONSTOP_KERNEL:*:*) + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} + exit ;; + NSE-*:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; NSR-?:NONSTOP_KERNEL:*:*) @@ -1303,13 +1311,13 @@ EOF echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} + echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` + UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; @@ -1324,11 +1332,14 @@ EOF i*86:rdos:*:*) echo ${UNAME_MACHINE}-pc-rdos exit ;; + i*86:AROS:*:*) + echo ${UNAME_MACHINE}-pc-aros + exit ;; + x86_64:VMkernel:*:*) + echo ${UNAME_MACHINE}-unknown-esx + exit ;; esac -#echo '(No uname command or uname output not recognized.)' 1>&2 -#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 - eval $set_cc_for_build cat >$dummy.c < printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 - "4" + "4" #else - "" + "" #endif - ); exit (0); + ); exit (0); #endif #endif From d0e0a51c4c6f7fd318e97a200a990fbb54cf3852 Mon Sep 17 00:00:00 2001 From: Ard Biesheuvel Date: Tue, 5 Feb 2013 12:14:55 +0100 Subject: [PATCH 2378/2394] Add ARM optimized versions of safe_address() The function safe_address() uses inline assembler to detect overflow in size/offset calculations, as detecting this in plain C is a lot more work. --- Zend/zend_alloc.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 1cc2c678334f9..fea94dec31186 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -2494,6 +2494,46 @@ static inline size_t safe_address(size_t nmemb, size_t size, size_t offset) return res; } +#elif defined(__GNUC__) && defined(__arm__) + +static inline size_t safe_address(size_t nmemb, size_t size, size_t offset) +{ + size_t res; + unsigned long overflow; + + __asm__ ("umull %0,%1,%2,%3\n\tadds %0,%4\n\tadc %1,%1" + : "=&r"(res), "=&r"(overflow) + : "r"(nmemb), + "r"(size), + "r"(offset)); + + if (UNEXPECTED(overflow)) { + zend_error_noreturn(E_ERROR, "Possible integer overflow in memory allocation (%zu * %zu + %zu)", nmemb, size, offset); + return 0; + } + return res; +} + +#elif defined(__GNUC__) && defined(__aarch64__) + +static inline size_t safe_address(size_t nmemb, size_t size, size_t offset) +{ + size_t res; + unsigned long overflow; + + __asm__ ("mul %0,%2,%3\n\tumulh %1,%2,%3\n\tadds %0,%0,%4\n\tadc %1,%1,%1" + : "=&r"(res), "=&r"(overflow) + : "r"(nmemb), + "r"(size), + "r"(offset)); + + if (UNEXPECTED(overflow)) { + zend_error_noreturn(E_ERROR, "Possible integer overflow in memory allocation (%zu * %zu + %zu)", nmemb, size, offset); + return 0; + } + return res; +} + #elif SIZEOF_SIZE_T == 4 && defined(HAVE_ZEND_LONG64) static inline size_t safe_address(size_t nmemb, size_t size, size_t offset) From 02ae4522f5fba7564fe5529950862dc0da1af5d7 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 5 Feb 2013 12:29:21 +0100 Subject: [PATCH 2379/2394] revert --- NEWS | 1 - 1 file changed, 1 deletion(-) diff --git a/NEWS b/NEWS index cb1ec95e9845d..c343f4315a511 100644 --- a/NEWS +++ b/NEWS @@ -8,7 +8,6 @@ PHP NEWS . Implemented FR #60524 (specify temp dir by php.ini). (ALeX Kazik). . Fixed bug #63830 (Segfault on undefined function call in nested generator). (Nikita Popov) - . Fixed bug #64142 (dval to lval different behavior on ppc64). (Remi) - CLI server: . Fixed bug #64128 (buit-in web server is broken on ppc64). (Remi) From 215da6057f5fe1545805fb5ab9299b78d3a3b259 Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Wed, 6 Feb 2013 16:22:27 +0100 Subject: [PATCH 2380/2394] make libvpx optional --- ext/gd/config.w32 | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/ext/gd/config.w32 b/ext/gd/config.w32 index 22584ddd46e7b..b9c208382d036 100644 --- a/ext/gd/config.w32 +++ b/ext/gd/config.w32 @@ -3,10 +3,10 @@ ARG_WITH("gd", "Bundled GD support", "yes,shared"); ARG_WITH("t1lib", "t1lib support", "yes"); +ARG_WITH("libvpx", "vpx support", "yes"); if (PHP_GD != "no") { if ( - CHECK_LIB("vpxmt.lib", "gd", PHP_GD) && CHECK_LIB("libjpeg_a.lib;libjpeg.lib", "gd", PHP_GD) && CHECK_LIB("freetype_a.lib;freetype.lib", "gd", PHP_GD) && CHECK_LIB("libpng_a.lib;libpng.lib", "gd", PHP_GD) && @@ -30,6 +30,14 @@ if (PHP_GD != "no") { } } + if (PHP_LIBVPX != "no") { + if (CHECK_LIB("vpxmt.lib", "gd", PHP_GD) && + CHECK_HEADER_ADD_INCLUDE("vp8.h", "CFLAGS_GD", PHP_GD + ";" + PHP_PHP_BUILD + "\\include\\vpx")) { + ADD_FLAG("CFLAGS_GD", "/D HAVE_LIBVPX /D HAVE_GD_WEBP"); + } else { + WARNING("libvpx not enabled; libraries and headers not found"); + } + } CHECK_LIB("User32.lib", "gd", PHP_GD); CHECK_LIB("Gdi32.lib", "gd", PHP_GD); @@ -60,14 +68,12 @@ if (PHP_GD != "no") { /D HAVE_GD_WBMP \ /D HAVE_GD_XBM \ /D HAVE_GD_XPM \ -/D HAVE_GD_WEBP \ /D HAVE_LIBFREETYPE=1 \ /D HAVE_LIBGD13=1 \ /D HAVE_LIBGD15=1 \ /D HAVE_LIBGD20=1 \ /D HAVE_LIBGD204=1 \ /D HAVE_LIBJPEG \ -/D HAVE_LIBVPX \ /D HAVE_LIBPNG \ /D HAVE_XPM \ /D HAVE_COLORCLOSESTHWB \ From 9fb0dba4be197b677b6ff7df23a110698d12530b Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 7 Feb 2013 16:05:27 +0100 Subject: [PATCH 2381/2394] Add support for commit and rollback options. Add support for explicitly starting a transaction - modes also available. Using the API makes the life of load balancer mysqlnd plugins easier/possible. --- ext/mysqlnd/mysqlnd.c | 129 +++++++++++++++++++++++++++++-- ext/mysqlnd/mysqlnd_enum_n_def.h | 12 +++ ext/mysqlnd/mysqlnd_structs.h | 9 +++ 3 files changed, 142 insertions(+), 8 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 1bab6f5b7a0d4..d7ddcb594b608 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2617,12 +2617,79 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_autocommit)(MYSQLND_CONN_DATA * conn, unsi static enum_func_status MYSQLND_METHOD(mysqlnd_conn_data, tx_commit)(MYSQLND_CONN_DATA * conn TSRMLS_DC) { - size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, tx_commit); + return conn->m->tx_commit_or_rollback(conn, TRUE, TRANS_COR_NO_OPT, NULL TSRMLS_CC); +} +/* }}} */ + + +/* {{{ mysqlnd_conn_data::tx_rollback */ +static enum_func_status +MYSQLND_METHOD(mysqlnd_conn_data, tx_rollback)(MYSQLND_CONN_DATA * conn TSRMLS_DC) +{ + return conn->m->tx_commit_or_rollback(conn, FALSE, TRANS_COR_NO_OPT, NULL TSRMLS_CC); +} +/* }}} */ + + +/* {{{ mysqlnd_tx_cor_options_to_string */ +static void +MYSQLND_METHOD(mysqlnd_conn_data, tx_cor_options_to_string)(const MYSQLND_CONN_DATA * const conn, smart_str * str, const unsigned int mode TSRMLS_DC) +{ + if (mode & TRANS_COR_AND_CHAIN && !(mode & TRANS_COR_AND_NO_CHAIN)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "AND CHAIN", sizeof("AND CHAIN") - 1); + } else if (mode & TRANS_COR_AND_NO_CHAIN && !(mode & TRANS_COR_AND_CHAIN)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "AND NO CHAIN", sizeof("AND NO CHAIN") - 1); + } + + if (mode & TRANS_COR_RELEASE && !(mode & TRANS_COR_NO_RELEASE)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "RELEASE", sizeof("RELEASE") - 1); + } else if (mode & TRANS_COR_NO_RELEASE && !(mode & TRANS_COR_RELEASE)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "NO RELEASE", sizeof("NO RELEASE") - 1); + } + smart_str_0(str); +} +/* }}} */ + + +/* {{{ mysqlnd_conn_data::tx_commit_ex */ +static enum_func_status +MYSQLND_METHOD(mysqlnd_conn_data, tx_commit_or_rollback)(MYSQLND_CONN_DATA * conn, const zend_bool commit, const unsigned int flags, const char * const name TSRMLS_DC) +{ + size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, tx_commit_or_rollback); enum_func_status ret = FAIL; - DBG_ENTER("mysqlnd_conn_data::tx_commit"); + DBG_ENTER("mysqlnd_conn_data::tx_commit_or_rollback"); if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { - ret = conn->m->query(conn, "COMMIT", sizeof("COMMIT") - 1 TSRMLS_CC); + do { + smart_str tmp_str = {0, 0, 0}; + conn->m->tx_cor_options_to_string(conn, &tmp_str, flags TSRMLS_CC); + smart_str_0(&tmp_str); + + { + char * query; + unsigned int query_len = mnd_sprintf(&query, 0, (commit? "COMMIT %s":"ROLLBACK %s"), tmp_str.c? tmp_str.c:""); + smart_str_free(&tmp_str); + + if (!query) { + SET_OOM_ERROR(*conn->error_info); + break; + } + ret = conn->m->query(conn, query, query_len TSRMLS_CC); + mnd_sprintf_free(query); + } + } while (0); conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC); } @@ -2631,16 +2698,55 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_commit)(MYSQLND_CONN_DATA * conn TSRMLS_DC) /* }}} */ -/* {{{ mysqlnd_conn_data::tx_rollback */ +/* {{{ mysqlnd_conn_data::tx_begin */ static enum_func_status -MYSQLND_METHOD(mysqlnd_conn_data, tx_rollback)(MYSQLND_CONN_DATA * conn TSRMLS_DC) +MYSQLND_METHOD(mysqlnd_conn_data, tx_begin)(MYSQLND_CONN_DATA * conn, const unsigned int mode, const char * const name TSRMLS_DC) { - size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, tx_rollback); + size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, tx_begin); enum_func_status ret = FAIL; - DBG_ENTER("mysqlnd_conn_data::tx_rollback"); + DBG_ENTER("mysqlnd_conn_data::tx_begin"); if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { - ret = conn->m->query(conn, "ROLLBACK", sizeof("ROLLBACK") - 1 TSRMLS_CC); + do { + smart_str tmp_str = {0, 0, 0}; + if (mode & TRANS_START_WITH_CONSISTENT_SNAPSHOT) { + if (tmp_str.len) { + smart_str_appendl(&tmp_str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(&tmp_str, "WITH CONSISTENT SNAPSHOT", sizeof("WITH CONSISTENT SNAPSHOT") - 1); + } + if (mode & TRANS_START_READ_WRITE) { + if (tmp_str.len) { + smart_str_appendl(&tmp_str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(&tmp_str, "READ WRITE", sizeof("READ WRITE") - 1); + } + if (mode & TRANS_START_READ_ONLY) { + if (tmp_str.len) { + smart_str_appendl(&tmp_str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(&tmp_str, "READ ONLY", sizeof("READ ONLY") - 1); + } + smart_str_0(&tmp_str); + + { + char * commented_name = NULL; + unsigned int commented_name_len = name? mnd_sprintf(&commented_name, 0, " /*%s*/", name):0; + char * query; + unsigned int query_len = mnd_sprintf(&query, 0, "START TRANSACTION%s %s", commented_name? commented_name:"", tmp_str.c? tmp_str.c:""); + smart_str_free(&tmp_str); + + if (!query) { + SET_OOM_ERROR(*conn->error_info); + break; + } + ret = conn->m->query(conn, query, query_len TSRMLS_CC); + mnd_sprintf_free(query); + if (commented_name) { + mnd_sprintf_free(commented_name); + } + } + } while (0); conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC); } @@ -2649,6 +2755,9 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_rollback)(MYSQLND_CONN_DATA * conn TSRMLS_D /* }}} */ +typedef enum_func_status (*func_mysqlnd_conn_data__)(MYSQLND_CONN_DATA * conn, const unsigned int flags, const char * const name TSRMLS_DC); + + /* {{{ mysqlnd_conn_data::local_tx_start */ static enum_func_status MYSQLND_METHOD(mysqlnd_conn_data, local_tx_start)(MYSQLND_CONN_DATA * conn, size_t this_func TSRMLS_DC) @@ -2763,6 +2872,10 @@ MYSQLND_CLASS_METHODS_START(mysqlnd_conn_data) MYSQLND_METHOD(mysqlnd_conn_data, set_autocommit), MYSQLND_METHOD(mysqlnd_conn_data, tx_commit), MYSQLND_METHOD(mysqlnd_conn_data, tx_rollback), + MYSQLND_METHOD(mysqlnd_conn_data, tx_begin), + MYSQLND_METHOD(mysqlnd_conn_data, tx_commit_or_rollback), + MYSQLND_METHOD(mysqlnd_conn_data, tx_cor_options_to_string), + MYSQLND_METHOD(mysqlnd_conn_data, local_tx_start), MYSQLND_METHOD(mysqlnd_conn_data, local_tx_end), MYSQLND_METHOD(mysqlnd_conn_data, execute_init_commands), diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h index cf5b02728badf..1d645a8d75c65 100644 --- a/ext/mysqlnd/mysqlnd_enum_n_def.h +++ b/ext/mysqlnd/mysqlnd_enum_n_def.h @@ -108,6 +108,18 @@ #define MYSQLND_NET_FLAG_USE_COMPRESSION 1 + +#define TRANS_START_NO_OPT 0 +#define TRANS_START_WITH_CONSISTENT_SNAPSHOT 1 +#define TRANS_START_READ_WRITE 2 +#define TRANS_START_READ_ONLY 4 + +#define TRANS_COR_NO_OPT 0 +#define TRANS_COR_AND_CHAIN 1 +#define TRANS_COR_AND_NO_CHAIN 2 +#define TRANS_COR_RELEASE 4 +#define TRANS_COR_NO_RELEASE 8 + typedef enum mysqlnd_extension { MYSQLND_MYSQL = 0, diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index b88004a9f11bc..7d22dafb8fccc 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -23,6 +23,8 @@ #ifndef MYSQLND_STRUCTS_H #define MYSQLND_STRUCTS_H +#include "ext/standard/php_smart_str.h" + #define MYSQLND_TYPEDEFED_METHODS #define MYSQLND_CLASS_METHOD_TABLE_NAME(class) mysqlnd_##class##_methods @@ -31,6 +33,7 @@ #define MYSQLND_CLASS_METHODS_START(class) MYSQLND_CLASS_METHOD_TABLE_NAME_FORWARD(class) = { #define MYSQLND_CLASS_METHODS_END } + typedef struct st_mysqlnd_memory_pool MYSQLND_MEMORY_POOL; typedef struct st_mysqlnd_memory_pool_chunk MYSQLND_MEMORY_POOL_CHUNK; typedef struct st_mysqlnd_memory_pool_chunk_llist MYSQLND_MEMORY_POOL_CHUNK_LLIST; @@ -480,6 +483,9 @@ typedef MYSQLND_RES * (*func_mysqlnd_conn_data__result_init)(unsigned int fiel typedef enum_func_status (*func_mysqlnd_conn_data__set_autocommit)(MYSQLND_CONN_DATA * conn, unsigned int mode TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__tx_commit)(MYSQLND_CONN_DATA * conn TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__tx_rollback)(MYSQLND_CONN_DATA * conn TSRMLS_DC); +typedef enum_func_status (*func_mysqlnd_conn_data__tx_begin)(MYSQLND_CONN_DATA * conn, const unsigned int mode, const char * const name TSRMLS_DC); +typedef enum_func_status (*func_mysqlnd_conn_data__tx_commit_or_rollback)(MYSQLND_CONN_DATA * conn, const zend_bool commit, const unsigned int flags, const char * const name TSRMLS_DC); +typedef void (*func_mysqlnd_conn_data__tx_cor_options_to_string)(const MYSQLND_CONN_DATA * const conn, smart_str * tmp_str, const unsigned int mode TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__local_tx_start)(MYSQLND_CONN_DATA * conn, size_t this_func TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__local_tx_end)(MYSQLND_CONN_DATA * conn, size_t this_func, enum_func_status status TSRMLS_DC); @@ -566,6 +572,9 @@ struct st_mysqlnd_conn_data_methods func_mysqlnd_conn_data__set_autocommit set_autocommit; func_mysqlnd_conn_data__tx_commit tx_commit; func_mysqlnd_conn_data__tx_rollback tx_rollback; + func_mysqlnd_conn_data__tx_begin tx_begin; + func_mysqlnd_conn_data__tx_commit_or_rollback tx_commit_or_rollback; + func_mysqlnd_conn_data__tx_cor_options_to_string tx_cor_options_to_string; func_mysqlnd_conn_data__local_tx_start local_tx_start; func_mysqlnd_conn_data__local_tx_end local_tx_end; From 49e3d91ad91bd3b65e2142641f80de0401396b85 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 7 Feb 2013 16:24:08 +0100 Subject: [PATCH 2382/2394] Add the name in a comment at commit/rollback, if provided --- ext/mysqlnd/mysqlnd.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index d7ddcb594b608..0e47def6d13fe 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2678,8 +2678,11 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_commit_or_rollback)(MYSQLND_CONN_DATA * con smart_str_0(&tmp_str); { + char * commented_name = NULL; + unsigned int commented_name_len = name? mnd_sprintf(&commented_name, 0, " /*%s*/", name):0; char * query; - unsigned int query_len = mnd_sprintf(&query, 0, (commit? "COMMIT %s":"ROLLBACK %s"), tmp_str.c? tmp_str.c:""); + unsigned int query_len = mnd_sprintf(&query, 0, (commit? "COMMIT%s %s":"ROLLBACK%s %s"), + commented_name? commented_name:"", tmp_str.c? tmp_str.c:""); smart_str_free(&tmp_str); if (!query) { @@ -2688,6 +2691,9 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_commit_or_rollback)(MYSQLND_CONN_DATA * con } ret = conn->m->query(conn, query, query_len TSRMLS_CC); mnd_sprintf_free(query); + if (commented_name) { + mnd_sprintf_free(commented_name); + } } } while (0); conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC); From 290509755ac4a3279b2b31b899aa9f2dd780f5f4 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Thu, 7 Feb 2013 23:44:46 +0800 Subject: [PATCH 2383/2394] Fixed bug #64135 (Exceptions from set_error_handler are not always propagated) --- NEWS | 6 ++-- Zend/tests/bug61767.phpt | 12 ++++---- Zend/zend_vm_def.h | 4 +++ Zend/zend_vm_execute.h | 64 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 77 insertions(+), 9 deletions(-) diff --git a/NEWS b/NEWS index c343f4315a511..3bb6acef8a52a 100644 --- a/NEWS +++ b/NEWS @@ -3,11 +3,13 @@ PHP NEWS ?? ??? 201?, PHP 5.5.0 Beta 1 - Core: + . Fixed bug #64135 (Exceptions from set_error_handler are not always + propagated). (Laruence) + . Fixed bug #63830 (Segfault on undefined function call in nested generator). + (Nikita Popov) . Fixed bug #60833 (self, parent, static behave inconsistently case-sensitive). (Stas, mario at include-once dot org) . Implemented FR #60524 (specify temp dir by php.ini). (ALeX Kazik). - . Fixed bug #63830 (Segfault on undefined function call in nested generator). - (Nikita Popov) - CLI server: . Fixed bug #64128 (buit-in web server is broken on ppc64). (Remi) diff --git a/Zend/tests/bug61767.phpt b/Zend/tests/bug61767.phpt index 5270872e5d8c2..9bd9c907bdc2c 100644 --- a/Zend/tests/bug61767.phpt +++ b/Zend/tests/bug61767.phpt @@ -17,18 +17,16 @@ $undefined->foo(); --EXPECTF-- Error handler called (Undefined variable: undefined) -Warning: Uncaught exception 'ErrorException' with message 'Undefined variable: undefined' in %sbug61767.php:13 +Fatal error: Uncaught exception 'ErrorException' with message 'Undefined variable: undefined' in %sbug61767.php:%d Stack trace: -#0 %sbug61767.php(13): {closure}(8, 'Undefined varia...', '%s', 13, Array) +#0 %sbug61767.php(%d): {closure}(%s, 'Undefined varia...', '%s', %d, Array) #1 {main} - thrown in %sbug61767.php on line 13 - -Fatal error: Call to a member function foo() on a non-object in %sbug61767.php on line 13 + thrown in %sbug61767.php on line %d Shutting down Array ( [type] => 1 - [message] => Call to a member function foo() on a non-object + [message] => %a [file] => %sbug61767.php - [line] => 13 + [line] => %d ) diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 4dd544e5780a1..cbd3810a21035 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -2462,6 +2462,10 @@ ZEND_VM_HANDLER(112, ZEND_INIT_METHOD_CALL, TMP|VAR|UNUSED|CV, CONST|TMP|VAR|CV) } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + FREE_OP2(); + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 25ac1ea89e737..7b874decef28d 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -8947,6 +8947,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CONST_HANDLER(ZEND_OPCO } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -9801,6 +9805,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_TMP_HANDLER(ZEND_OPCODE } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + zval_dtor(free_op2.var); + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -10660,6 +10668,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_VAR_HANDLER(ZEND_OPCODE } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -12094,6 +12106,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_TMP_CV_HANDLER(ZEND_OPCODE_ } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -15319,6 +15335,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CONST_HANDLER(ZEND_OPCO } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -17660,6 +17680,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_TMP_HANDLER(ZEND_OPCODE } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + zval_dtor(free_op2.var); + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -19966,6 +19990,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -23407,6 +23435,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_VAR_CV_HANDLER(ZEND_OPCODE_ } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -25033,6 +25065,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CONST_HANDLER(ZEND_O } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -26441,6 +26477,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_TMP_HANDLER(ZEND_OPC } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + zval_dtor(free_op2.var); + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -27755,6 +27795,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_VAR_HANDLER(ZEND_OPC } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -29490,6 +29534,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_UNUSED_CV_HANDLER(ZEND_OPCO } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -32718,6 +32766,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CONST_HANDLER(ZEND_OPCOD } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -34831,6 +34883,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_ } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + zval_dtor(free_op2.var); + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -37003,6 +37059,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_ } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + if (free_op2.var) {zval_ptr_dtor(&free_op2.var);}; + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } @@ -40167,6 +40227,10 @@ static int ZEND_FASTCALL ZEND_INIT_METHOD_CALL_SPEC_CV_CV_HANDLER(ZEND_OPCODE_H } } } else { + if (UNEXPECTED(EG(exception) != NULL)) { + + HANDLE_EXCEPTION(); + } zend_error_noreturn(E_ERROR, "Call to a member function %s() on a non-object", function_name_strval); } From 7948eea6f9833d4dd97cd34af37465af9efcec78 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Thu, 7 Feb 2013 23:49:35 +0800 Subject: [PATCH 2384/2394] Forgot test script --- Zend/tests/bug64135.phpt | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 Zend/tests/bug64135.phpt diff --git a/Zend/tests/bug64135.phpt b/Zend/tests/bug64135.phpt new file mode 100644 index 0000000000000..1c7b1500a2b0c --- /dev/null +++ b/Zend/tests/bug64135.phpt @@ -0,0 +1,17 @@ +--TEST-- +Bug #64135 (Exceptions from set_error_handler are not always propagated) +--FILE-- +undefined(); +} catch(Exception $e) { + echo "Exception is thrown"; +} +--EXPECT-- +Exception is thrown From 403d4fbbffdd11c82caa7a6eac2e32d9b57f1ce3 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 7 Feb 2013 18:29:19 +0100 Subject: [PATCH 2385/2394] Export new calls --- ext/mysqlnd/mysqlnd.c | 3 --- ext/mysqlnd/mysqlnd.h | 5 +++-- ext/mysqlnd/mysqlnd_libmysql_compat.h | 4 ++-- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 0e47def6d13fe..959f3e0256128 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2761,9 +2761,6 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_begin)(MYSQLND_CONN_DATA * conn, const unsi /* }}} */ -typedef enum_func_status (*func_mysqlnd_conn_data__)(MYSQLND_CONN_DATA * conn, const unsigned int flags, const char * const name TSRMLS_DC); - - /* {{{ mysqlnd_conn_data::local_tx_start */ static enum_func_status MYSQLND_METHOD(mysqlnd_conn_data, local_tx_start)(MYSQLND_CONN_DATA * conn, size_t this_func TSRMLS_DC) diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index bf0f70b405c26..7adf3b6840d29 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -192,8 +192,9 @@ PHPAPI void mysqlnd_set_local_infile_handler(MYSQLND_CONN_DATA * const conn, con /* Simple commands */ #define mysqlnd_autocommit(conn, mode) ((conn)->data)->m->set_autocommit((conn)->data, (mode) TSRMLS_CC) -#define mysqlnd_commit(conn) ((conn)->data)->m->tx_commit((conn)->data TSRMLS_CC) -#define mysqlnd_rollback(conn) ((conn)->data)->m->tx_rollback((conn)->data TSRMLS_CC) +#define mysqlnd_begin_transaction(conn,flags,name) ((conn)->data)->m->tx_begin((conn)->data, (flags), (name) TSRMLS_CC) +#define mysqlnd_commit(conn, flags, name) ((conn)->data)->m->tx_commit_or_rollback((conn)->data, TRUE, (flags), (name) TSRMLS_CC) +#define mysqlnd_rollback(conn, flags, name) ((conn)->data)->m->tx_commit_or_rollback((conn)->data, FALSE, (flags), (name) TSRMLS_CC) #define mysqlnd_list_dbs(conn, wild) ((conn)->data)->m->list_method((conn)->data, wild? "SHOW DATABASES LIKE %s":"SHOW DATABASES", (wild), NULL TSRMLS_CC) #define mysqlnd_list_fields(conn, tab,wild) ((conn)->data)->m->list_fields((conn)->data, (tab), (wild) TSRMLS_CC) #define mysqlnd_list_processes(conn) ((conn)->data)->m->list_method((conn)->data, "SHOW PROCESSLIST", NULL, NULL TSRMLS_CC) diff --git a/ext/mysqlnd/mysqlnd_libmysql_compat.h b/ext/mysqlnd/mysqlnd_libmysql_compat.h index e3ab9eefa99c5..516200e0d507f 100644 --- a/ext/mysqlnd/mysqlnd_libmysql_compat.h +++ b/ext/mysqlnd/mysqlnd_libmysql_compat.h @@ -44,7 +44,7 @@ #define mysql_change_user(r,a,b,c) mysqlnd_change_user((r), (a), (b), (c), FALSE) #define mysql_character_set_name(c) mysqlnd_character_set_name((c)) #define mysql_close(r) mysqlnd_close((r), MYSQLND_CLOSE_EXPLICIT) -#define mysql_commit(r) mysqlnd_commit((r)) +#define mysql_commit(r) mysqlnd_commit((r), TRANS_COR_NO_OPT, NULL) #define mysql_data_seek(r,o) mysqlnd_data_seek((r),(o)) #define mysql_debug(x) mysqlnd_debug((x)) #define mysql_dump_debug_info(r) mysqlnd_dump_debug_info((r)) @@ -74,7 +74,7 @@ #define mysql_real_escape_string(r,a,b,c) mysqlnd_real_escape_string((r), (a), (b), (c)) #define mysql_real_query(r,a,b) mysqlnd_query((r), (a), (b)) #define mysql_refresh(conn, options) mysqlnd_refresh((conn), (options)) -#define mysql_rollback(r) mysqlnd_rollback((r)) +#define mysql_rollback(r) mysqlnd_rollback((r), TRANS_COR_NO_OPT, NULL) #define mysql_select_db(r,a) mysqlnd_select_db((r), (a) ,strlen((a))) #define mysql_set_server_option(r,o) mysqlnd_set_server_option((r), (o)) #define mysql_set_character_set(r,a) mysqlnd_set_character_set((r), (a)) From afacdecd1f8001b143e86676859d570ebf4659b9 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Thu, 7 Feb 2013 18:45:49 +0100 Subject: [PATCH 2386/2394] Add support for begin_transaction in libmysql mode. Add support for flags and name for commit/rollback in libmysql mode --- ext/mysqli/mysqli_api.c | 85 ++++++++++++++++++- ext/mysqli/mysqli_fe.c | 42 ++++++++- ext/mysqli/mysqli_fe.h | 1 + ext/mysqli/mysqli_libmysql.h | 12 +++ ext/mysqli/mysqli_nonapi.c | 76 +++++++++++++++++ .../tests/mysqli_class_mysqli_interface.phpt | 39 ++++----- .../tests/mysqli_class_mysqli_reflection.phpt | 64 +++++++++++++- ext/mysqli/tests/mysqli_commit_oo.phpt | 6 +- 8 files changed, 289 insertions(+), 36 deletions(-) diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index 70a8cc63039d8..760ee3c424c10 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -30,6 +30,7 @@ #include "php_ini.h" #include "php_globals.h" #include "ext/standard/info.h" +#include "ext/standard/php_smart_str.h" #include "php_mysqli_structs.h" #include "mysqli_priv.h" @@ -635,18 +636,86 @@ PHP_FUNCTION(mysqli_close) } /* }}} */ + +#if !defined(MYSQLI_USE_MYSQLND) +/* {{{ mysqli_tx_cor_options_to_string */ +static void mysqli_tx_cor_options_to_string(const MYSQL * const conn, smart_str * str, const unsigned int mode) +{ + if (mode & TRANS_COR_AND_CHAIN && !(mode & TRANS_COR_AND_NO_CHAIN)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "AND CHAIN", sizeof("AND CHAIN") - 1); + } else if (mode & TRANS_COR_AND_NO_CHAIN && !(mode & TRANS_COR_AND_CHAIN)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "AND NO CHAIN", sizeof("AND NO CHAIN") - 1); + } + + if (mode & TRANS_COR_RELEASE && !(mode & TRANS_COR_NO_RELEASE)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "RELEASE", sizeof("RELEASE") - 1); + } else if (mode & TRANS_COR_NO_RELEASE && !(mode & TRANS_COR_RELEASE)) { + if (str->len) { + smart_str_appendl(str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(str, "NO RELEASE", sizeof("NO RELEASE") - 1); + } + smart_str_0(str); +} +/* }}} */ + + +/* {{{ proto bool mysqli_commit_or_rollback_libmysql */ +static int mysqli_commit_or_rollback_libmysql(MYSQL * conn, zend_bool commit, const unsigned int mode, const char * const name) +{ + int ret; + smart_str tmp_str = {0, 0, 0}; + mysqli_tx_cor_options_to_string(conn, &tmp_str, mode); + smart_str_0(&tmp_str); + + { + char * commented_name = NULL; + unsigned int commented_name_len = name? spprintf(&commented_name, 0, " /*%s*/", name):0; + char * query; + unsigned int query_len = spprintf(&query, 0, (commit? "COMMIT%s %s":"ROLLBACK%s %s"), + commented_name? commented_name:"", tmp_str.c? tmp_str.c:""); + smart_str_free(&tmp_str); + + ret = mysql_real_query(conn, query, query_len); + efree(query); + if (commented_name) { + efree(commented_name); + } + } +} +/* }}} */ +#endif + + /* {{{ proto bool mysqli_commit(object link) Commit outstanding actions and close transaction */ PHP_FUNCTION(mysqli_commit) { MY_MYSQL *mysql; zval *mysql_link; + long flags = TRANS_COR_NO_OPT; + char * name = NULL; + int name_len = 0; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|ls", &mysql_link, mysqli_link_class_entry, &flags, &name, &name_len) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - if (mysql_commit(mysql->mysql)) { + +#if !defined(MYSQLI_USE_MYSQLND) + if (mysqli_commit_or_rollback_libmysql(mysql->mysql, TRUE, flags, name)) { +#else + if (mysqlnd_commit(mysql->mysql, flags, name)) { +#endif RETURN_FALSE; } RETURN_TRUE; @@ -1872,19 +1941,27 @@ PHP_FUNCTION(mysqli_real_escape_string) { } /* }}} */ + /* {{{ proto bool mysqli_rollback(object link) Undo actions from current transaction */ PHP_FUNCTION(mysqli_rollback) { MY_MYSQL *mysql; zval *mysql_link; + long flags = TRANS_COR_NO_OPT; + char * name = NULL; + int name_len = 0; - if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &mysql_link, mysqli_link_class_entry) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|ls", &mysql_link, mysqli_link_class_entry, &flags, &name, &name_len) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); - if (mysql_rollback(mysql->mysql)) { +#if !defined(MYSQLI_USE_MYSQLND) + if (mysqli_commit_or_rollback_libmysql(mysql->mysql, FALSE, flags, name)) { +#else + if (mysqlnd_rollback(mysql->mysql, flags, name)) { +#endif RETURN_FALSE; } RETURN_TRUE; diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c index 4ac67269ce44f..411ab11979e99 100644 --- a/ext/mysqli/mysqli_fe.c +++ b/ext/mysqli/mysqli_fe.c @@ -86,6 +86,38 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_autocommit, 0, 0, 1) ZEND_ARG_INFO(0, mode) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_begin_transaction, 0, 0, 1) + MYSQLI_ZEND_ARG_OBJ_INFO_LINK() + ZEND_ARG_INFO(0, flags) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_begin_transaction, 0, 0, 0) + ZEND_ARG_INFO(0, flags) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_commit, 0, 0, 1) + MYSQLI_ZEND_ARG_OBJ_INFO_LINK() + ZEND_ARG_INFO(0, flags) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_commit, 0, 0, 0) + ZEND_ARG_INFO(0, flags) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_rollback, 0, 0, 1) + MYSQLI_ZEND_ARG_OBJ_INFO_LINK() + ZEND_ARG_INFO(0, flags) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_rollback, 0, 0, 0) + ZEND_ARG_INFO(0, flags) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_change_user, 0, 0, 4) MYSQLI_ZEND_ARG_OBJ_INFO_LINK() @@ -326,10 +358,11 @@ ZEND_END_ARG_INFO() const zend_function_entry mysqli_functions[] = { PHP_FE(mysqli_affected_rows, arginfo_mysqli_only_link) PHP_FE(mysqli_autocommit, arginfo_mysqli_autocommit) + PHP_FE(mysqli_begin_transaction, arginfo_mysqli_begin_transaction) PHP_FE(mysqli_change_user, arginfo_mysqli_change_user) PHP_FE(mysqli_character_set_name, arginfo_mysqli_only_link) PHP_FE(mysqli_close, arginfo_mysqli_only_link) - PHP_FE(mysqli_commit, arginfo_mysqli_only_link) + PHP_FE(mysqli_commit, arginfo_mysqli_commit) PHP_FE(mysqli_connect, arginfo_mysqli_connect) PHP_FE(mysqli_connect_errno, arginfo_mysqli_no_params) PHP_FE(mysqli_connect_error, arginfo_mysqli_no_params) @@ -397,7 +430,7 @@ const zend_function_entry mysqli_functions[] = { #if defined(MYSQLI_USE_MYSQLND) PHP_FE(mysqli_reap_async_query, arginfo_mysqli_only_link) #endif - PHP_FE(mysqli_rollback, arginfo_mysqli_only_link) + PHP_FE(mysqli_rollback, arginfo_mysqli_rollback) PHP_FE(mysqli_select_db, arginfo_mysqli_select_db) #ifdef HAVE_MYSQLI_SET_CHARSET PHP_FE(mysqli_set_charset, arginfo_mysqli_set_charset) @@ -458,10 +491,11 @@ const zend_function_entry mysqli_functions[] = { */ const zend_function_entry mysqli_link_methods[] = { PHP_FALIAS(autocommit, mysqli_autocommit, arginfo_class_mysqli_autocommit) + PHP_FALIAS(begin_transaction, mysqli_begin_transaction, arginfo_class_mysqli_begin_transaction) PHP_FALIAS(change_user,mysqli_change_user, arginfo_class_mysqli_change_user) PHP_FALIAS(character_set_name, mysqli_character_set_name, arginfo_mysqli_no_params) PHP_FALIAS(close, mysqli_close, arginfo_mysqli_no_params) - PHP_FALIAS(commit, mysqli_commit, arginfo_mysqli_no_params) + PHP_FALIAS(commit, mysqli_commit, arginfo_class_mysqli_commit) PHP_FALIAS(connect, mysqli_connect, arginfo_mysqli_connect) PHP_FALIAS(dump_debug_info, mysqli_dump_debug_info, arginfo_mysqli_no_params) PHP_FALIAS(debug, mysqli_debug, arginfo_mysqli_debug) @@ -494,7 +528,7 @@ const zend_function_entry mysqli_link_methods[] = { #endif PHP_FALIAS(escape_string, mysqli_real_escape_string, arginfo_class_mysqli_real_escape_string) PHP_FALIAS(real_query, mysqli_real_query, arginfo_class_mysqli_query) - PHP_FALIAS(rollback,mysqli_rollback, arginfo_mysqli_no_params) + PHP_FALIAS(rollback, mysqli_rollback, arginfo_class_mysqli_rollback) PHP_FALIAS(select_db,mysqli_select_db, arginfo_class_mysqli_select_db) #ifdef HAVE_MYSQLI_SET_CHARSET PHP_FALIAS(set_charset, mysqli_set_charset, arginfo_class_mysqli_set_charset) diff --git a/ext/mysqli/mysqli_fe.h b/ext/mysqli/mysqli_fe.h index 2edb32cb31c5b..e6cd3a6678c25 100644 --- a/ext/mysqli/mysqli_fe.h +++ b/ext/mysqli/mysqli_fe.h @@ -25,6 +25,7 @@ PHP_FUNCTION(mysqli); PHP_FUNCTION(mysqli_affected_rows); PHP_FUNCTION(mysqli_autocommit); +PHP_FUNCTION(mysqli_begin_transaction); PHP_FUNCTION(mysqli_change_user); PHP_FUNCTION(mysqli_character_set_name); PHP_FUNCTION(mysqli_set_charset); diff --git a/ext/mysqli/mysqli_libmysql.h b/ext/mysqli/mysqli_libmysql.h index 3a7b91b9956fd..e10e3702ea762 100644 --- a/ext/mysqli/mysqli_libmysql.h +++ b/ext/mysqli/mysqli_libmysql.h @@ -42,6 +42,18 @@ #define mysqli_change_user_silent(c, u, p, d, p_len) mysql_change_user((c), (u), (p), (d)) +#define TRANS_START_NO_OPT 0 +#define TRANS_START_WITH_CONSISTENT_SNAPSHOT 1 +#define TRANS_START_READ_WRITE 2 +#define TRANS_START_READ_ONLY 4 + +#define TRANS_COR_NO_OPT 0 +#define TRANS_COR_AND_CHAIN 1 +#define TRANS_COR_AND_NO_CHAIN 2 +#define TRANS_COR_RELEASE 4 +#define TRANS_COR_NO_RELEASE 8 + + /* These functions also reside in ext/mysqlnd/mysqlnd_portability.h but since it is only made available if one wants to build mysqli against mysqlnd and they are useful for libmysql as diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index b730d24cd69d8..c08fbaef28d39 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -29,6 +29,7 @@ #include "php.h" #include "php_ini.h" #include "ext/standard/info.h" +#include "ext/standard/php_smart_str.h" #include "php_mysqli_structs.h" #include "mysqli_priv.h" @@ -1045,6 +1046,81 @@ PHP_FUNCTION(mysqli_get_charset) /* }}} */ #endif + +#if !defined(MYSQLI_USE_MYSQLND) +/* {{{ proto bool mysqli_begin_transaction_libmysql */ +static int mysqli_begin_transaction_libmysql(MYSQL * conn, const unsigned int mode, const char * const name) +{ + int ret; + smart_str tmp_str = {0, 0, 0}; + if (mode & TRANS_START_WITH_CONSISTENT_SNAPSHOT) { + if (tmp_str.len) { + smart_str_appendl(&tmp_str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(&tmp_str, "WITH CONSISTENT SNAPSHOT", sizeof("WITH CONSISTENT SNAPSHOT") - 1); + } + if (mode & TRANS_START_READ_WRITE) { + if (tmp_str.len) { + smart_str_appendl(&tmp_str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(&tmp_str, "READ WRITE", sizeof("READ WRITE") - 1); + } + if (mode & TRANS_START_READ_ONLY) { + if (tmp_str.len) { + smart_str_appendl(&tmp_str, ", ", sizeof(", ") - 1); + } + smart_str_appendl(&tmp_str, "READ ONLY", sizeof("READ ONLY") - 1); + } + smart_str_0(&tmp_str); + + { + char * commented_name = NULL; + unsigned int commented_name_len = name? spprintf(&commented_name, 0, " /*%s*/", name):0; + char * query; + unsigned int query_len = spprintf(&query, 0, "START TRANSACTION%s %s", + commented_name? commented_name:"", tmp_str.c? tmp_str.c:""); + smart_str_free(&tmp_str); + + ret = mysql_real_query(conn, query, query_len); + efree(query); + if (commented_name) { + efree(commented_name); + } + } + return ret; +} +/* }}} */ +#endif + +/* {{{ proto bool mysqli_begin_transaction(object link, [int flags [, string name]]) + Starts a transaction */ +PHP_FUNCTION(mysqli_begin_transaction) +{ + MY_MYSQL *mysql; + zval *mysql_link; + long flags = TRANS_START_NO_OPT; + char * name = NULL; + int name_len = 0; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|ls", &mysql_link, mysqli_link_class_entry, &flags, &name, &name_len) == FAILURE) { + return; + } + MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); + +#if !defined(MYSQLI_USE_MYSQLND) + if (mysqli_begin_transaction_libmysql(mysql->mysql, flags, name)) { + RETURN_FALSE; + } +#else + if (mysqlnd_begin_transaction(mysql->mysql, flags, name)) { + RETURN_FALSE; + } +#endif + RETURN_TRUE; +} +/* }}} */ + + /* * Local variables: * tab-width: 4 diff --git a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt index 19ba0086fb259..44e9865e17aac 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt @@ -20,38 +20,39 @@ require_once('skipifconnectfailure.inc'); $methods = get_class_methods($mysqli); $expected_methods = array( 'autocommit' => true, + 'begin_transaction' => true, 'change_user' => true, - 'character_set_name' => true, - 'close' => true, - 'commit' => true, - 'connect' => true, + 'character_set_name' => true, + 'close' => true, + 'commit' => true, + 'connect' => true, 'dump_debug_info' => true, 'escape_string' => true, 'get_charset' => true, 'get_client_info' => true, 'get_server_info' => true, 'get_warnings' => true, - 'init' => true, - 'kill' => true, + 'init' => true, + 'kill' => true, 'more_results' => true, 'multi_query' => true, - 'mysqli' => true, + 'mysqli' => true, 'next_result' => true, - 'options' => true, - 'ping' => true, - 'prepare' => true, - 'query' => true, + 'options' => true, + 'ping' => true, + 'prepare' => true, + 'query' => true, 'real_connect' => true, - 'real_escape_string' => true, + 'real_escape_string' => true, 'real_query' => true, - 'refresh' => true, - 'rollback' => true, - 'select_db' => true, + 'refresh' => true, + 'rollback' => true, + 'select_db' => true, 'set_charset' => true, - 'set_opt' => true, - 'ssl_set' => true, - 'stat' => true, - 'stmt_init' => true, + 'set_opt' => true, + 'ssl_set' => true, + 'stat' => true, + 'stmt_init' => true, 'store_result' => true, 'thread_safe' => true, 'use_result' => true, diff --git a/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt index 5fd4b6f45cd06..c62cb52fc7950 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt @@ -6,8 +6,6 @@ require_once('skipif.inc'); require_once('skipifemb.inc'); require_once('connect.inc'); -if (($tmp = substr(PHP_VERSION, 0, strpos(PHP_VERSION, '.'))) && ($tmp < 5)) - die("skip Reflection not available before PHP 5 (found PHP $tmp)"); /* Let's not deal with cross-version issues in the EXPECTF/UEXPECTF. Most of the things which we test are covered by mysqli_class_*_interface.phpt. @@ -120,6 +118,36 @@ isPassedByReference: no isOptional: no isDefaultValueAvailable: no +Inspecting method 'begin_transaction' +isFinal: no +isAbstract: no +isPublic: yes +isPrivate: no +isProtected: no +isStatic: no +isConstructor: no +isDestructor: no +isInternal: yes +isUserDefined: no +returnsReference: no +Modifiers: 256 +Number of Parameters: 2 +Number of Required Parameters: 0 + +Inspecting parameter 'flags' of method 'begin_transaction' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + +Inspecting parameter 'name' of method 'begin_transaction' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + Inspecting method 'change_user' isFinal: no isAbstract: no @@ -202,9 +230,23 @@ isInternal: yes isUserDefined: no returnsReference: no Modifiers: 256 -Number of Parameters: 0 +Number of Parameters: 2 Number of Required Parameters: 0 +Inspecting parameter 'flags' of method 'commit' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + +Inspecting parameter 'name' of method 'commit' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + Inspecting method 'connect' isFinal: no isAbstract: no @@ -863,9 +905,23 @@ isInternal: yes isUserDefined: no returnsReference: no Modifiers: 256 -Number of Parameters: 0 +Number of Parameters: 2 Number of Required Parameters: 0 +Inspecting parameter 'flags' of method 'rollback' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + +Inspecting parameter 'name' of method 'rollback' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: yes +isDefaultValueAvailable: no + Inspecting method 'select_db' isFinal: no isAbstract: no diff --git a/ext/mysqli/tests/mysqli_commit_oo.phpt b/ext/mysqli/tests/mysqli_commit_oo.phpt index 34ec4bfcdca6e..e19f698e8193d 100644 --- a/ext/mysqli/tests/mysqli_commit_oo.phpt +++ b/ext/mysqli/tests/mysqli_commit_oo.phpt @@ -28,12 +28,8 @@ if (!have_innodb($link)) printf("[001] Cannot connect to the server using host=%s, user=%s, passwd=***, dbname=%s, port=%s, socket=%s\n", $host, $user, $db, $port, $socket); - if (!is_null($tmp = @$mysqli->commit($link))) - printf("[002] Expecting NULL/NULL, got %s/%s, [%d] %s\n", - gettype($tmp), $tmp, $mysqli->errno, $mysqli->error); - if (true !== ($tmp = $mysqli->commit())) - printf("[014] Expecting boolean/true got %s/%s\n", gettype($tmp), $tmp); + printf("[002] Expecting boolean/true got %s/%s\n", gettype($tmp), $tmp); if (true !== ($tmp = $mysqli->autocommit(false))) printf("[003] Cannot turn off autocommit, expecting true, got %s/%s\n", gettype($tmp), $tmp); From 2d30a192f0b387bd2ae291f1ddd5a47432dbe5df Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 8 Feb 2013 11:12:54 +0100 Subject: [PATCH 2387/2394] add the news about recent commits --- NEWS | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/NEWS b/NEWS index 3bb6acef8a52a..2e2fc55834f73 100644 --- a/NEWS +++ b/NEWS @@ -22,6 +22,17 @@ PHP NEWS . Cherry-picked UConverter wrapper, which had accidentaly been committed only to master. +- mysqli + . Add mysqli_begin_transaction()/mysqli::begin_transaction(). Implemented all + options, per MySQL 5.6, which can be used with START TRANSACTION, COMMIT + and ROLLBACK through options to mysqli_commit()/mysqli_rollback() and their + respective OO counterparts. They work in libmysql and mysqlnd mode. (Andrey) + +- mysqlnd + . Add new begin_transaction() call to the connection object. Implemented all + options, per MySQL 5.6, which can be used with START TRANSACTION, COMMIT + and ROLLBACK. (Andrey) + - Sockets: . Added recvmsg() and sendmsg() wrappers. (Gustavo) See https://wiki.php.net/rfc/sendrecvmsg From 666a83566077d1db195fd17d088062434b6202fa Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 8 Feb 2013 16:36:17 +0100 Subject: [PATCH 2388/2394] Add savepoint and rollback to savepoint support --- ext/mysqlnd/mysqlnd.c | 66 +++++++++++++++++++++++++++++++++++ ext/mysqlnd/mysqlnd.h | 2 ++ ext/mysqlnd/mysqlnd_structs.h | 4 +++ 3 files changed, 72 insertions(+) diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c index 959f3e0256128..ccd8af51c6db3 100644 --- a/ext/mysqlnd/mysqlnd.c +++ b/ext/mysqlnd/mysqlnd.c @@ -2761,6 +2761,70 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_begin)(MYSQLND_CONN_DATA * conn, const unsi /* }}} */ +/* {{{ mysqlnd_conn_data::tx_savepoint */ +static enum_func_status +MYSQLND_METHOD(mysqlnd_conn_data, tx_savepoint)(MYSQLND_CONN_DATA * conn, const char * const name TSRMLS_DC) +{ + size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, tx_savepoint); + enum_func_status ret = FAIL; + DBG_ENTER("mysqlnd_conn_data::tx_savepoint"); + + if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { + do { + char * query; + unsigned int query_len; + if (!name) { + SET_CLIENT_ERROR(*conn->error_info, CR_UNKNOWN_ERROR, UNKNOWN_SQLSTATE, "Savepoint name not provided"); + break; + } + query_len = mnd_sprintf(&query, 0, "SAVEPOINT `%s`", name); + if (!query) { + SET_OOM_ERROR(*conn->error_info); + break; + } + ret = conn->m->query(conn, query, query_len TSRMLS_CC); + mnd_sprintf_free(query); + } while (0); + conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC); + } + + DBG_RETURN(ret); +} +/* }}} */ + + +/* {{{ mysqlnd_conn_data::tx_savepoint_release */ +static enum_func_status +MYSQLND_METHOD(mysqlnd_conn_data, tx_savepoint_release)(MYSQLND_CONN_DATA * conn, const char * const name TSRMLS_DC) +{ + size_t this_func = STRUCT_OFFSET(struct st_mysqlnd_conn_data_methods, tx_savepoint_release); + enum_func_status ret = FAIL; + DBG_ENTER("mysqlnd_conn_data::tx_savepoint_release"); + + if (PASS == conn->m->local_tx_start(conn, this_func TSRMLS_CC)) { + do { + char * query; + unsigned int query_len; + if (!name) { + SET_CLIENT_ERROR(*conn->error_info, CR_UNKNOWN_ERROR, UNKNOWN_SQLSTATE, "Savepoint name not provided"); + break; + } + query_len = mnd_sprintf(&query, 0, "RELEASE SAVEPOINT `%s`", name); + if (!query) { + SET_OOM_ERROR(*conn->error_info); + break; + } + ret = conn->m->query(conn, query, query_len TSRMLS_CC); + mnd_sprintf_free(query); + } while (0); + conn->m->local_tx_end(conn, this_func, ret TSRMLS_CC); + } + + DBG_RETURN(ret); +} +/* }}} */ + + /* {{{ mysqlnd_conn_data::local_tx_start */ static enum_func_status MYSQLND_METHOD(mysqlnd_conn_data, local_tx_start)(MYSQLND_CONN_DATA * conn, size_t this_func TSRMLS_DC) @@ -2878,6 +2942,8 @@ MYSQLND_CLASS_METHODS_START(mysqlnd_conn_data) MYSQLND_METHOD(mysqlnd_conn_data, tx_begin), MYSQLND_METHOD(mysqlnd_conn_data, tx_commit_or_rollback), MYSQLND_METHOD(mysqlnd_conn_data, tx_cor_options_to_string), + MYSQLND_METHOD(mysqlnd_conn_data, tx_savepoint), + MYSQLND_METHOD(mysqlnd_conn_data, tx_savepoint_release), MYSQLND_METHOD(mysqlnd_conn_data, local_tx_start), MYSQLND_METHOD(mysqlnd_conn_data, local_tx_end), diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index 7adf3b6840d29..40933630edef5 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -195,6 +195,8 @@ PHPAPI void mysqlnd_set_local_infile_handler(MYSQLND_CONN_DATA * const conn, con #define mysqlnd_begin_transaction(conn,flags,name) ((conn)->data)->m->tx_begin((conn)->data, (flags), (name) TSRMLS_CC) #define mysqlnd_commit(conn, flags, name) ((conn)->data)->m->tx_commit_or_rollback((conn)->data, TRUE, (flags), (name) TSRMLS_CC) #define mysqlnd_rollback(conn, flags, name) ((conn)->data)->m->tx_commit_or_rollback((conn)->data, FALSE, (flags), (name) TSRMLS_CC) +#define mysqlnd_savepoint(conn, name) ((conn)->data)->m->tx_savepoint((conn)->data, (name) TSRMLS_CC) +#define mysqlnd_release_savepoint(conn, name) ((conn)->data)->m->tx_savepoint_release((conn)->data, (name) TSRMLS_CC) #define mysqlnd_list_dbs(conn, wild) ((conn)->data)->m->list_method((conn)->data, wild? "SHOW DATABASES LIKE %s":"SHOW DATABASES", (wild), NULL TSRMLS_CC) #define mysqlnd_list_fields(conn, tab,wild) ((conn)->data)->m->list_fields((conn)->data, (tab), (wild) TSRMLS_CC) #define mysqlnd_list_processes(conn) ((conn)->data)->m->list_method((conn)->data, "SHOW PROCESSLIST", NULL, NULL TSRMLS_CC) diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h index 7d22dafb8fccc..55775d97e18f5 100644 --- a/ext/mysqlnd/mysqlnd_structs.h +++ b/ext/mysqlnd/mysqlnd_structs.h @@ -486,6 +486,8 @@ typedef enum_func_status (*func_mysqlnd_conn_data__tx_rollback)(MYSQLND_CONN_DAT typedef enum_func_status (*func_mysqlnd_conn_data__tx_begin)(MYSQLND_CONN_DATA * conn, const unsigned int mode, const char * const name TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__tx_commit_or_rollback)(MYSQLND_CONN_DATA * conn, const zend_bool commit, const unsigned int flags, const char * const name TSRMLS_DC); typedef void (*func_mysqlnd_conn_data__tx_cor_options_to_string)(const MYSQLND_CONN_DATA * const conn, smart_str * tmp_str, const unsigned int mode TSRMLS_DC); +typedef enum_func_status (*func_mysqlnd_conn_data__tx_savepoint)(MYSQLND_CONN_DATA * conn, const char * const name TSRMLS_DC); +typedef enum_func_status (*func_mysqlnd_conn_data__tx_savepoint_release)(MYSQLND_CONN_DATA * conn, const char * const name TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__local_tx_start)(MYSQLND_CONN_DATA * conn, size_t this_func TSRMLS_DC); typedef enum_func_status (*func_mysqlnd_conn_data__local_tx_end)(MYSQLND_CONN_DATA * conn, size_t this_func, enum_func_status status TSRMLS_DC); @@ -575,6 +577,8 @@ struct st_mysqlnd_conn_data_methods func_mysqlnd_conn_data__tx_begin tx_begin; func_mysqlnd_conn_data__tx_commit_or_rollback tx_commit_or_rollback; func_mysqlnd_conn_data__tx_cor_options_to_string tx_cor_options_to_string; + func_mysqlnd_conn_data__tx_savepoint tx_savepoint; + func_mysqlnd_conn_data__tx_savepoint_release tx_savepoint_release; func_mysqlnd_conn_data__local_tx_start local_tx_start; func_mysqlnd_conn_data__local_tx_end local_tx_end; From 0da369ae5048185f8e5e26e0e89191de09da22cb Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 8 Feb 2013 17:05:25 +0100 Subject: [PATCH 2389/2394] Add the constants needed for mysqli_commit(), _rollback() and begin_transaction() --- ext/mysqli/mysqli.c | 10 ++++++++++ ext/mysqli/tests/mysqli_constants.phpt | 13 ++++++++++--- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index 22e75cd998476..1731bb70f4693 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -846,6 +846,16 @@ PHP_MINIT_FUNCTION(mysqli) REGISTER_LONG_CONSTANT("MYSQLI_OPT_CAN_HANDLE_EXPIRED_PASSWORDS", MYSQL_OPT_CAN_HANDLE_EXPIRED_PASSWORDS, CONST_CS | CONST_PERSISTENT); #endif + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_START_WITH_CONSISTENT_SNAPSHOT", TRANS_START_WITH_CONSISTENT_SNAPSHOT, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_START_READ_WRITE", TRANS_START_READ_WRITE, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_START_READ_ONLY", TRANS_START_READ_ONLY, CONST_CS | CONST_PERSISTENT); + + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_COR_AND_CHAIN", TRANS_COR_AND_CHAIN, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_COR_AND_NO_CHAIN", TRANS_COR_AND_NO_CHAIN, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_COR_RELEASE", TRANS_COR_RELEASE, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TRANS_COR_NO_RELEASE", TRANS_COR_NO_RELEASE, CONST_CS | CONST_PERSISTENT); + + #ifdef MYSQLI_USE_MYSQLND mysqlnd_reverse_api_register_api(&mysqli_reverse_api TSRMLS_CC); #endif diff --git a/ext/mysqli/tests/mysqli_constants.phpt b/ext/mysqli/tests/mysqli_constants.phpt index 7c0f6a95e34d8..7c6dacd3934c5 100644 --- a/ext/mysqli/tests/mysqli_constants.phpt +++ b/ext/mysqli/tests/mysqli_constants.phpt @@ -32,7 +32,7 @@ require_once('skipifconnectfailure.inc'); "MYSQLI_ASSOC" => true, "MYSQLI_NUM" => true, "MYSQLI_BOTH" => true, - "MYSQLI_STMT_ATTR_UPDATE_MAX_LENGTH" => true, + "MYSQLI_STMT_ATTR_UPDATE_MAX_LENGTH"=> true, "MYSQLI_NOT_NULL_FLAG" => true, "MYSQLI_PRI_KEY_FLAG" => true, "MYSQLI_UNIQUE_KEY_FLAG" => true, @@ -86,14 +86,21 @@ require_once('skipifconnectfailure.inc'); "MYSQLI_SET_CHARSET_NAME" => true, "MYSQLI_SET_CHARSET_DIR" => true, "MYSQLI_REFRESH_GRANT" => true, - "MYSQLI_REFRESH_LOG" => true, + "MYSQLI_REFRESH_LOG" => true, "MYSQLI_REFRESH_TABLES" => true, "MYSQLI_REFRESH_HOSTS" => true, "MYSQLI_REFRESH_STATUS" => true, "MYSQLI_REFRESH_THREADS" => true, "MYSQLI_REFRESH_SLAVE" => true, "MYSQLI_REFRESH_MASTER" => true, - "MYSQLI_DEBUG_TRACE_ENABLED" => true, + "MYSQLI_DEBUG_TRACE_ENABLED" => true, + "MYSQLI_TRANS_START_WITH_CONSISTENT_SNAPSHOT" => true, + "MYSQLI_TRANS_START_READ_WRITE" => true, + "MYSQLI_TRANS_START_READ_ONLY" => true, + "MYSQLI_TRANS_COR_AND_CHAIN" => true, + "MYSQLI_TRANS_COR_AND_NO_CHAIN" => true, + "MYSQLI_TRANS_COR_RELEASE" => true, + "MYSQLI_TRANS_COR_NO_RELEASE" => true, ); /* depends on the build - experimental */ From 43ecd8fe1b307945df0e45ed14cab4be8aacdedb Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 8 Feb 2013 18:09:50 +0100 Subject: [PATCH 2390/2394] mysqli_savepoint()/mysqli_release_savepoint() --- ext/mysqli/mysqli_api.c | 4 +- ext/mysqli/mysqli_fe.c | 22 ++++++ ext/mysqli/mysqli_fe.h | 2 + ext/mysqli/mysqli_nonapi.c | 71 ++++++++++++++++++- .../tests/mysqli_class_mysqli_interface.phpt | 2 + 5 files changed, 98 insertions(+), 3 deletions(-) diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c index 760ee3c424c10..3d651fc204741 100644 --- a/ext/mysqli/mysqli_api.c +++ b/ext/mysqli/mysqli_api.c @@ -714,7 +714,7 @@ PHP_FUNCTION(mysqli_commit) #if !defined(MYSQLI_USE_MYSQLND) if (mysqli_commit_or_rollback_libmysql(mysql->mysql, TRUE, flags, name)) { #else - if (mysqlnd_commit(mysql->mysql, flags, name)) { + if (FAIL == mysqlnd_commit(mysql->mysql, flags, name)) { #endif RETURN_FALSE; } @@ -1960,7 +1960,7 @@ PHP_FUNCTION(mysqli_rollback) #if !defined(MYSQLI_USE_MYSQLND) if (mysqli_commit_or_rollback_libmysql(mysql->mysql, FALSE, flags, name)) { #else - if (mysqlnd_rollback(mysql->mysql, flags, name)) { + if (FAIL == mysqlnd_rollback(mysql->mysql, flags, name)) { #endif RETURN_FALSE; } diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c index 411ab11979e99..6f2e404087843 100644 --- a/ext/mysqli/mysqli_fe.c +++ b/ext/mysqli/mysqli_fe.c @@ -97,6 +97,24 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_begin_transaction, 0, 0, 0) ZEND_ARG_INFO(0, name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_savepoint, 0, 0, 2) + MYSQLI_ZEND_ARG_OBJ_INFO_LINK() + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_savepoint, 0, 0, 1) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_release_savepoint, 0, 0, 2) + MYSQLI_ZEND_ARG_OBJ_INFO_LINK() + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_class_mysqli_release_savepoint, 0, 0, 1) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_mysqli_commit, 0, 0, 1) MYSQLI_ZEND_ARG_OBJ_INFO_LINK() ZEND_ARG_INFO(0, flags) @@ -430,7 +448,9 @@ const zend_function_entry mysqli_functions[] = { #if defined(MYSQLI_USE_MYSQLND) PHP_FE(mysqli_reap_async_query, arginfo_mysqli_only_link) #endif + PHP_FE(mysqli_release_savepoint, arginfo_mysqli_release_savepoint) PHP_FE(mysqli_rollback, arginfo_mysqli_rollback) + PHP_FE(mysqli_savepoint, arginfo_mysqli_savepoint) PHP_FE(mysqli_select_db, arginfo_mysqli_select_db) #ifdef HAVE_MYSQLI_SET_CHARSET PHP_FE(mysqli_set_charset, arginfo_mysqli_set_charset) @@ -528,7 +548,9 @@ const zend_function_entry mysqli_link_methods[] = { #endif PHP_FALIAS(escape_string, mysqli_real_escape_string, arginfo_class_mysqli_real_escape_string) PHP_FALIAS(real_query, mysqli_real_query, arginfo_class_mysqli_query) + PHP_FALIAS(release_savepoint, mysqli_release_savepoint, arginfo_class_mysqli_release_savepoint) PHP_FALIAS(rollback, mysqli_rollback, arginfo_class_mysqli_rollback) + PHP_FALIAS(savepoint, mysqli_savepoint, arginfo_class_mysqli_savepoint) PHP_FALIAS(select_db,mysqli_select_db, arginfo_class_mysqli_select_db) #ifdef HAVE_MYSQLI_SET_CHARSET PHP_FALIAS(set_charset, mysqli_set_charset, arginfo_class_mysqli_set_charset) diff --git a/ext/mysqli/mysqli_fe.h b/ext/mysqli/mysqli_fe.h index e6cd3a6678c25..7e447c63e5a48 100644 --- a/ext/mysqli/mysqli_fe.h +++ b/ext/mysqli/mysqli_fe.h @@ -108,6 +108,8 @@ PHP_FUNCTION(mysqli_sqlstate); PHP_FUNCTION(mysqli_ssl_set); PHP_FUNCTION(mysqli_stat); PHP_FUNCTION(mysqli_refresh); +PHP_FUNCTION(mysqli_savepoint); +PHP_FUNCTION(mysqli_release_savepoint); PHP_FUNCTION(mysqli_stmt_affected_rows); PHP_FUNCTION(mysqli_stmt_close); PHP_FUNCTION(mysqli_stmt_data_seek); diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index c08fbaef28d39..c3a56fca39ed4 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -1112,7 +1112,7 @@ PHP_FUNCTION(mysqli_begin_transaction) RETURN_FALSE; } #else - if (mysqlnd_begin_transaction(mysql->mysql, flags, name)) { + if (FAIL == mysqlnd_begin_transaction(mysql->mysql, flags, name)) { RETURN_FALSE; } #endif @@ -1121,6 +1121,75 @@ PHP_FUNCTION(mysqli_begin_transaction) /* }}} */ +#if !defined(MYSQLI_USE_MYSQLND) +/* {{{ proto bool mysqli_savepoint_libmysql */ +static int mysqli_savepoint_libmysql(MYSQL * conn, const char * const name, zend_bool release) +{ + int ret; + char * query; + unsigned int query_len = spprintf(&query, 0, release? "RELEASE SAVEPOINT `%s`":"SAVEPOINT `%s`", name); + ret = mysql_real_query(conn, query, query_len); + efree(query); + return ret; +} +/* }}} */ +#endif + + +/* {{{ proto bool mysqli_savepoint(object link, string name) + Starts a transaction */ +PHP_FUNCTION(mysqli_savepoint) +{ + MY_MYSQL *mysql; + zval *mysql_link; + char * name = NULL; + int name_len = 0; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &mysql_link, mysqli_link_class_entry, &name, &name_len) == FAILURE) { + return; + } + MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); + +#if !defined(MYSQLI_USE_MYSQLND) + if (mysqli_savepoint_libmysql(mysql->mysql, name, FALSE)) { +#else + if (FAIL == mysqlnd_savepoint(mysql->mysql, name)) { +#endif + RETURN_FALSE; + } + RETURN_TRUE; +} +/* }}} */ + + +/* {{{ proto bool mysqli_release_savepoint(object link, string name) + Starts a transaction */ +PHP_FUNCTION(mysqli_release_savepoint) +{ + MY_MYSQL *mysql; + zval *mysql_link; + char * name = NULL; + int name_len = 0; + + if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &mysql_link, mysqli_link_class_entry, &name, &name_len) == FAILURE) { + return; + } + MYSQLI_FETCH_RESOURCE_CONN(mysql, &mysql_link, MYSQLI_STATUS_VALID); + if (!name || !name_len) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Savepoint name not provided"); + } +#if !defined(MYSQLI_USE_MYSQLND) + if (mysqli_savepoint_libmysql(mysql->mysql, name, TRUE)) { +#else + if (FAIL == mysqlnd_savepoint(mysql->mysql, name)) { +#endif + RETURN_FALSE; + } + RETURN_TRUE; +} +/* }}} */ + + /* * Local variables: * tab-width: 4 diff --git a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt index 44e9865e17aac..ea86c198e716a 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_interface.phpt @@ -47,6 +47,8 @@ require_once('skipifconnectfailure.inc'); 'real_query' => true, 'refresh' => true, 'rollback' => true, + 'release_savepoint' => true, + 'savepoint' => true, 'select_db' => true, 'set_charset' => true, 'set_opt' => true, From a5b426eeffdb4f35e927d268ff82ffb67d8f889e Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 8 Feb 2013 18:28:22 +0100 Subject: [PATCH 2391/2394] update test case --- .../tests/mysqli_class_mysqli_reflection.phpt | 46 +++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt index c62cb52fc7950..259fcd9ae6785 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_reflection.phpt @@ -892,6 +892,29 @@ isPassedByReference: no isOptional: no isDefaultValueAvailable: no +Inspecting method 'release_savepoint' +isFinal: no +isAbstract: no +isPublic: yes +isPrivate: no +isProtected: no +isStatic: no +isConstructor: no +isDestructor: no +isInternal: yes +isUserDefined: no +returnsReference: no +Modifiers: 256 +Number of Parameters: 1 +Number of Required Parameters: 1 + +Inspecting parameter 'name' of method 'release_savepoint' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: no +isDefaultValueAvailable: no + Inspecting method 'rollback' isFinal: no isAbstract: no @@ -922,6 +945,29 @@ isPassedByReference: no isOptional: yes isDefaultValueAvailable: no +Inspecting method 'savepoint' +isFinal: no +isAbstract: no +isPublic: yes +isPrivate: no +isProtected: no +isStatic: no +isConstructor: no +isDestructor: no +isInternal: yes +isUserDefined: no +returnsReference: no +Modifiers: 256 +Number of Parameters: 1 +Number of Required Parameters: 1 + +Inspecting parameter 'name' of method 'savepoint' +isArray: no +allowsNull: no +isPassedByReference: no +isOptional: no +isDefaultValueAvailable: no + Inspecting method 'select_db' isFinal: no isAbstract: no From 3d9a31efdfbbc3d73b8c94649f38035277264151 Mon Sep 17 00:00:00 2001 From: Andrey Hristov Date: Fri, 8 Feb 2013 18:33:45 +0100 Subject: [PATCH 2392/2394] news for mysqli_savepoint and mysql_release_savepoint --- NEWS | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 2e2fc55834f73..f7882de87f868 100644 --- a/NEWS +++ b/NEWS @@ -23,15 +23,17 @@ PHP NEWS to master. - mysqli - . Add mysqli_begin_transaction()/mysqli::begin_transaction(). Implemented all + . Added mysqli_begin_transaction()/mysqli::begin_transaction(). Implemented all options, per MySQL 5.6, which can be used with START TRANSACTION, COMMIT and ROLLBACK through options to mysqli_commit()/mysqli_rollback() and their respective OO counterparts. They work in libmysql and mysqlnd mode. (Andrey) + . Added mysqli_savepoint(), mysqli_release_savepoint(). (Andrey) - mysqlnd . Add new begin_transaction() call to the connection object. Implemented all options, per MySQL 5.6, which can be used with START TRANSACTION, COMMIT and ROLLBACK. (Andrey) + . Added mysqlnd_savepoint(), mysqlnd_release_savepoint(). (Andrey) - Sockets: . Added recvmsg() and sendmsg() wrappers. (Gustavo) From c94a161c4906549edb72ee72de70c3e423e117a0 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 8 Feb 2013 20:55:04 +0000 Subject: [PATCH 2393/2394] Add in support for setting a process title. RFC: https://wiki.php.net/rfc/cli_process_title Discussion: http://marc.info/?t=136021582000003&r=1&w=2 --- sapi/cli/config.m4 | 19 +- sapi/cli/config.w32 | 4 +- sapi/cli/php_cli.c | 13 + sapi/cli/php_cli_process_title.c | 76 +++++ sapi/cli/php_cli_process_title.h | 40 +++ sapi/cli/php_cli_server.c | 8 + sapi/cli/php_cli_server.h | 1 + sapi/cli/ps_title.c | 384 ++++++++++++++++++++++++++ sapi/cli/ps_title.h | 39 +++ sapi/cli/tests/cli_process_title.phpt | 46 +++ 10 files changed, 627 insertions(+), 3 deletions(-) create mode 100644 sapi/cli/php_cli_process_title.c create mode 100644 sapi/cli/php_cli_process_title.h create mode 100644 sapi/cli/ps_title.c create mode 100644 sapi/cli/ps_title.h create mode 100644 sapi/cli/tests/cli_process_title.phpt diff --git a/sapi/cli/config.m4 b/sapi/cli/config.m4 index cdfa1f7daff2a..9a1b98da46193 100644 --- a/sapi/cli/config.m4 +++ b/sapi/cli/config.m4 @@ -6,6 +6,23 @@ PHP_ARG_ENABLE(cli,, [ --disable-cli Disable building CLI version of PHP (this forces --without-pear)], yes, no) +AC_CHECK_FUNCS(setproctitle) + +AC_CHECK_HEADERS([sys/pstat.h]) + +AC_CACHE_CHECK([for PS_STRINGS], [cli_cv_var_PS_STRINGS], +[AC_TRY_LINK( +[#include +#include +], +[PS_STRINGS->ps_nargvstr = 1; +PS_STRINGS->ps_argvstr = "foo";], +[cli_cv_var_PS_STRINGS=yes], +[cli_cv_var_PS_STRINGS=no])]) +if test "$cli_cv_var_PS_STRINGS" = yes ; then + AC_DEFINE([HAVE_PS_STRINGS], [], [Define to 1 if the PS_STRINGS thing exists.]) +fi + AC_MSG_CHECKING(for CLI build) if test "$PHP_CLI" != "no"; then PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/sapi/cli/Makefile.frag) @@ -14,7 +31,7 @@ if test "$PHP_CLI" != "no"; then SAPI_CLI_PATH=sapi/cli/php dnl Select SAPI - PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c,, '$(SAPI_CLI_PATH)') + PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c ps_title.c php_cli_process_title.c,, '$(SAPI_CLI_PATH)') case $host_alias in *aix*) diff --git a/sapi/cli/config.w32 b/sapi/cli/config.w32 index 4d0dad58e84b4..adcbb2b496acb 100644 --- a/sapi/cli/config.w32 +++ b/sapi/cli/config.w32 @@ -6,7 +6,7 @@ ARG_ENABLE('crt-debug', 'Enable CRT memory dumps for debugging sent to STDERR', ARG_ENABLE('cli-win32', 'Build console-less CLI version of PHP', 'no'); if (PHP_CLI == "yes") { - SAPI('cli', 'php_cli.c php_http_parser.c php_cli_server.c', 'php.exe'); + SAPI('cli', 'php_cli.c php_http_parser.c php_cli_server.c php_cli_process_title.c ps_title.c', 'php.exe'); ADD_FLAG("LIBS_CLI", "ws2_32.lib"); if (PHP_CRT_DEBUG == "yes") { ADD_FLAG("CFLAGS_CLI", "/D PHP_WIN32_DEBUG_HEAP"); @@ -15,7 +15,7 @@ if (PHP_CLI == "yes") { } if (PHP_CLI_WIN32 == "yes") { - SAPI('cli_win32', 'cli_win32.c', 'php-win.exe'); + SAPI('cli_win32', 'cli_win32.c php_cli_process_title.c ps_title.c', 'php-win.exe'); ADD_FLAG("LDFLAGS_CLI_WIN32", "/stack:8388608"); } diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index c01f3705b59bc..ffb6a69c4cc9d 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -86,6 +86,9 @@ #include "php_cli_server.h" #endif +#include "ps_title.h" +#include "php_cli_process_title.h" + #ifndef PHP_WIN32 # define php_select(m, r, w, e, t) select(m, r, w, e, t) #else @@ -478,6 +481,8 @@ ZEND_END_ARG_INFO() static const zend_function_entry additional_functions[] = { ZEND_FE(dl, arginfo_dl) + PHP_FE(cli_set_process_title, arginfo_cli_set_process_title) + PHP_FE(cli_get_process_title, NULL) {NULL, NULL, NULL} }; @@ -1200,6 +1205,7 @@ int main(int argc, char *argv[]) int argc = __argc; char **argv = __argv; #endif + int c; int exit_status = SUCCESS; int module_started = 0, sapi_started = 0; @@ -1211,6 +1217,12 @@ int main(int argc, char *argv[]) int ini_ignore = 0; sapi_module_struct *sapi_module = &cli_sapi_module; + /* + * Do not move this initialization. It needs to happen before argv is used + * in any way. + */ + argv = save_ps_args(argc, argv); + cli_sapi_module.additional_functions = additional_functions; #if defined(PHP_WIN32) && defined(_DEBUG) && defined(PHP_WIN32_DEBUG_HEAP) @@ -1299,6 +1311,7 @@ int main(int argc, char *argv[]) #ifndef PHP_CLI_WIN32_NO_CONSOLE case 'S': sapi_module = &cli_server_sapi_module; + cli_server_sapi_module.additional_functions = server_additional_functions; break; #endif case 'h': /* help & quit */ diff --git a/sapi/cli/php_cli_process_title.c b/sapi/cli/php_cli_process_title.c new file mode 100644 index 0000000000000..8631f82893c4d --- /dev/null +++ b/sapi/cli/php_cli_process_title.c @@ -0,0 +1,76 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Keyur Govande (kgovande@gmail.com) | + +----------------------------------------------------------------------+ +*/ + +/* $Id$ */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "php.h" +#include "php_cli_process_title.h" +#include "ps_title.h" + +/* {{{ proto boolean cli_set_process_title(string arg) + Return a boolean to confirm if the process title was successfully changed or not */ +PHP_FUNCTION(cli_set_process_title) +{ + char *title = NULL; + int title_len; + int rc; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &title, &title_len) == FAILURE) { + RETURN_FALSE; + } + + rc = set_ps_title(title); + if (rc == PS_TITLE_SUCCESS) { + RETURN_TRUE; + } + + php_error_docref(NULL TSRMLS_CC, E_WARNING, "cli_set_process_title had an error: %s", ps_title_errno(rc)); + RETURN_FALSE; +} +/* }}} */ + +/* {{{ proto string cli_get_process_title(string arg) + Return a string with the current process title. NULL if error. */ +PHP_FUNCTION(cli_get_process_title) +{ + int length = 0; + const char* title = NULL; + int rc; + + rc = get_ps_title(&length, &title); + if (rc != PS_TITLE_SUCCESS) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "cli_get_process_title had an error: %s", ps_title_errno(rc)); + RETURN_NULL(); + } + + RETURN_STRINGL(title, length, 1); +} +/* }}} */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/sapi/cli/php_cli_process_title.h b/sapi/cli/php_cli_process_title.h new file mode 100644 index 0000000000000..62ef5673db57e --- /dev/null +++ b/sapi/cli/php_cli_process_title.h @@ -0,0 +1,40 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Keyur Govande (kgovande@gmail.com) | + +----------------------------------------------------------------------+ +*/ + +/* $Id$ */ + +#ifndef PHP_PS_TITLE_HEADER +#define PHP_PS_TITLE_HEADER + +ZEND_BEGIN_ARG_INFO(arginfo_cli_set_process_title, 0) + ZEND_ARG_INFO(0, title) +ZEND_END_ARG_INFO() + +PHP_FUNCTION(cli_set_process_title); +PHP_FUNCTION(cli_get_process_title); + +#endif + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 6a4e7c53ab7c9..279b98593cb8f 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -103,6 +103,8 @@ #include "php_http_parser.h" #include "php_cli_server.h" +#include "php_cli_process_title.h" + #define OUTPUT_NOT_CHECKED -1 #define OUTPUT_IS_TTY 1 #define OUTPUT_NOT_TTY 0 @@ -423,6 +425,12 @@ zend_module_entry cli_server_module_entry = { }; /* }}} */ +const zend_function_entry server_additional_functions[] = { + PHP_FE(cli_set_process_title, arginfo_cli_set_process_title) + PHP_FE(cli_get_process_title, NULL) + {NULL, NULL, NULL} +}; + static int sapi_cli_server_startup(sapi_module_struct *sapi_module) /* {{{ */ { if (php_module_startup(sapi_module, &cli_server_module_entry, 1) == FAILURE) { diff --git a/sapi/cli/php_cli_server.h b/sapi/cli/php_cli_server.h index ed716f99f809e..9a29626c7f056 100644 --- a/sapi/cli/php_cli_server.h +++ b/sapi/cli/php_cli_server.h @@ -23,6 +23,7 @@ #include "SAPI.h" +extern const zend_function_entry server_additional_functions[]; extern sapi_module_struct cli_server_sapi_module; extern int do_cli_server(int argc, char **argv TSRMLS_DC); diff --git a/sapi/cli/ps_title.c b/sapi/cli/ps_title.c new file mode 100644 index 0000000000000..610def73c5f15 --- /dev/null +++ b/sapi/cli/ps_title.c @@ -0,0 +1,384 @@ +/* + * PostgreSQL is released under the PostgreSQL License, a liberal Open Source + * license, similar to the BSD or MIT licenses. + * PostgreSQL Database Management System (formerly known as Postgres, then as + * Postgres95) + * + * Portions Copyright (c) 1996-2013, The PostgreSQL Global Development Group + * + * Portions Copyright (c) 1994, The Regents of the University of California + * + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose, without fee, and without a written + * agreement is hereby granted, provided that the above copyright notice + * and this paragraph and the following two paragraphs appear in all copies. + * + * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING + * LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, + * EVEN IF THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + * "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATIONS TO + * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + * + * The following code is adopted from the PostgreSQL's ps_status(.h/.c). + */ + +#include "ps_title.h" +#include + +#ifdef HAVE_UNISTD_H +#include +#endif + +#include +#include + +#ifdef PHP_WIN32 +#include "config.w32.h" +#include +#include +#else +#include "php_config.h" +extern char** environ; +#endif + +#ifdef HAVE_SYS_PSTAT_H +#include // for HP-UX +#endif +#ifdef HAVE_PS_STRINGS +#include // for old BSD +#include +#endif +#if defined(DARWIN) +#include +#endif + +/* + * Ways of updating ps display: + * + * PS_USE_SETPROCTITLE + * use the function setproctitle(const char *, ...) + * (newer BSD systems) + * PS_USE_PSTAT + * use the pstat(PSTAT_SETCMD, ) + * (HPUX) + * PS_USE_PS_STRINGS + * assign PS_STRINGS->ps_argvstr = "string" + * (some BSD systems) + * PS_USE_CHANGE_ARGV + * assign argv[0] = "string" + * (some other BSD systems) + * PS_USE_CLOBBER_ARGV + * write over the argv and environment area + * (Linux and most SysV-like systems) + * PS_USE_WIN32 + * push the string out as the name of a Windows event + * PS_USE_NONE + * don't update ps display + * (This is the default, as it is safest.) + */ +#if defined(HAVE_SETPROCTITLE) +#define PS_USE_SETPROCTITLE +#elif defined(HAVE_SYS_PSTAT_H) && defined(PSTAT_SETCMD) +#define PS_USE_PSTAT +#elif defined(HAVE_PS_STRINGS) +#define PS_USE_PS_STRINGS +#elif defined(BSD) && !defined(DARWIN) +#define PS_USE_CHANGE_ARGV +#elif defined(__linux__) || defined(_AIX) || defined(__sgi) || (defined(sun) && !defined(BSD)) || defined(ultrix) || defined(__osf__) || defined(DARWIN) +#define PS_USE_CLOBBER_ARGV +#elif defined(PHP_WIN32) +#define PS_USE_WIN32 +#else +#define PS_USE_NONE +#endif + +/* Different systems want the buffer padded differently */ +#if defined(_AIX) || defined(__linux__) || defined(DARWIN) +#define PS_PADDING '\0' +#else +#define PS_PADDING ' ' +#endif + +#ifndef PS_USE_CLOBBER_ARGV +#define PS_BUFFER_SIZE 256 +static char ps_buffer[PS_BUFFER_SIZE]; +static const size_t ps_buffer_size = PS_BUFFER_SIZE; +#else +static char *ps_buffer; /* will point to argv area */ +static size_t ps_buffer_size; /* space determined at run time */ +#endif + +static size_t ps_buffer_cur_len; /* actual string length in ps_buffer */ + +/* save the original argv[] location here */ +static int save_argc; +static char** save_argv; + + +/* + * Call this early in startup to save the original argc/argv values. + * If needed, we make a copy of the original argv[] array to preserve it + * from being clobbered by subsequent ps_display actions. + * + * (The original argv[] will not be overwritten by this routine. + * Also, the physical location of the environment strings may be moved, + * so this should be called before any code that might try to hang onto a + * getenv() result.) + */ +char** save_ps_args(int argc, char** argv) +{ + save_argc = argc; + save_argv = argv; + +#if defined(PS_USE_CLOBBER_ARGV) + /* + * If we're going to overwrite the argv area, count the available space. + * Also move the environment to make additional room. + */ + { + char* end_of_area = NULL; + int non_contiguous_area = 0; + char** new_environ; + int i; + + /* + * check for contiguous argv strings + */ + for (i = 0; (non_contiguous_area == 0) && (i < argc); i++) + { + if (i != 0 && end_of_area + 1 != argv[i]) + non_contiguous_area = 1; + end_of_area = argv[i] + strlen(argv[i]); + } + + /* + * check for contiguous environ strings following argv + */ + for (i = 0; (non_contiguous_area == 0) && (environ[i] != NULL); i++) + { + if (end_of_area + 1 != environ[i]) + non_contiguous_area = 1; + end_of_area = environ[i] + strlen(environ[i]); + } + + if (non_contiguous_area != 0) + goto clobber_error; + + ps_buffer = argv[0]; + ps_buffer_size = end_of_area - argv[0]; + + /* + * move the environment out of the way + */ + new_environ = (char **) malloc((i + 1) * sizeof(char *)); + for (i = 0; environ[i] != NULL; i++) + { + new_environ[i] = strdup(environ[i]); + if (!new_environ[i]) + goto clobber_error; + } + new_environ[i] = NULL; + environ = new_environ; + + } +#endif /* PS_USE_CLOBBER_ARGV */ + +#if defined(PS_USE_CHANGE_ARGV) || defined(PS_USE_CLOBBER_ARGV) + /* + * If we're going to change the original argv[] then make a copy for + * argument parsing purposes. + * + * (NB: do NOT think to remove the copying of argv[]! + * On some platforms, getopt() keeps pointers into the argv array, and + * will get horribly confused when it is re-called to analyze a subprocess' + * argument string if the argv storage has been clobbered meanwhile. + * Other platforms have other dependencies on argv[].) + */ + { + char** new_argv; + int i; + + new_argv = (char **) malloc((argc + 1) * sizeof(char *)); + for (i = 0; i < argc; i++) + { + new_argv[i] = strdup(argv[i]); + if (!new_argv[i]) + goto clobber_error; + } + new_argv[argc] = NULL; + +#if defined(DARWIN) + /* + * Darwin (and perhaps other NeXT-derived platforms?) has a static + * copy of the argv pointer, which we may fix like so: + */ + *_NSGetArgv() = new_argv; +#endif + + argv = new_argv; + + } +#endif /* PS_USE_CHANGE_ARGV or PS_USE_CLOBBER_ARGV */ + +#if defined(PS_USE_CLOBBER_ARGV) + { + /* make extra argv slots point at end_of_area (a NUL) */ + int i; + for (i = 1; i < save_argc; i++) + save_argv[i] = ps_buffer + ps_buffer_size; + } +#endif /* PS_USE_CLOBBER_ARGV */ + +#ifdef PS_USE_CHANGE_ARGV + save_argv[0] = ps_buffer; // ps_buffer here is a static const array of size PS_BUFFER_SIZE + save_argv[1] = NULL; +#endif /* PS_USE_CHANGE_ARGV */ + + return argv; + +#if defined(PS_USE_CHANGE_ARGV) || defined(PS_USE_CLOBBER_ARGV) +clobber_error: + /* probably can't happen?! + * if we ever get here, argv still points to originally passed + * in argument + */ + ps_buffer = NULL; + ps_buffer_size = 0; + return argv; +#endif /* PS_USE_CHANGE_ARGV or PS_USE_CLOBBER_ARGV */ +} + +/* + * Returns PS_TITLE_SUCCESS if the OS supports this functionality + * and the init function was called. + * Otherwise returns NOT_AVAILABLE or NOT_INITIALIZED + */ +int is_ps_title_available() +{ +#ifdef PS_USE_NONE + return PS_TITLE_NOT_AVAILABLE; // disabled functionality +#endif + + if (!save_argv) + return PS_TITLE_NOT_INITIALIZED; + +#ifdef PS_USE_CLOBBER_ARGV + if (!ps_buffer) + return PS_TITLE_BUFFER_NOT_AVAILABLE; +#endif /* PS_USE_CLOBBER_ARGV */ + + return PS_TITLE_SUCCESS; +} + +/* + * Convert error codes into error strings + */ +const char* ps_title_errno(int rc) +{ + switch(rc) + { + case PS_TITLE_SUCCESS: + return "Success"; + + case PS_TITLE_NOT_AVAILABLE: + return "Not available on this OS"; + + case PS_TITLE_NOT_INITIALIZED: + return "Not initialized correctly"; + + case PS_TITLE_BUFFER_NOT_AVAILABLE: + return "Buffer not contiguous"; + } + + return "Unknown error code"; +} + +/* + * Set a new process title. + * Returns the appropriate error code if if there's an error + * (like the functionality is compile time disabled, or the + * save_ps_args() was not called. + * Else returns 0 on success. + */ +int set_ps_title(const char* title) +{ + int rc = is_ps_title_available(); + if (rc != PS_TITLE_SUCCESS) + return rc; + + strncpy(ps_buffer, title, ps_buffer_size); + ps_buffer[ps_buffer_size - 1] = '\0'; + ps_buffer_cur_len = strlen(ps_buffer); + +#ifdef PS_USE_SETPROCTITLE + setproctitle("%s", ps_buffer); +#endif + +#ifdef PS_USE_PSTAT + { + union pstun pst; + + pst.pst_command = ps_buffer; + pstat(PSTAT_SETCMD, pst, ps_buffer_cur_len, 0, 0); + } +#endif /* PS_USE_PSTAT */ + +#ifdef PS_USE_PS_STRINGS + PS_STRINGS->ps_nargvstr = 1; + PS_STRINGS->ps_argvstr = ps_buffer; +#endif /* PS_USE_PS_STRINGS */ + +#ifdef PS_USE_CLOBBER_ARGV + /* pad unused memory */ + if (ps_buffer_cur_len < ps_buffer_size) + { + memset(ps_buffer + ps_buffer_cur_len, PS_PADDING, + ps_buffer_size - ps_buffer_cur_len); + } +#endif /* PS_USE_CLOBBER_ARGV */ + +#ifdef PS_USE_WIN32 + { + /* + * Win32 does not support showing any changed arguments. To make it at + * all possible to track which backend is doing what, we create a + * named object that can be viewed with for example Process Explorer. + */ + static HANDLE ident_handle = INVALID_HANDLE_VALUE; + char name[PS_BUFFER_SIZE + 32]; + + if (ident_handle != INVALID_HANDLE_VALUE) + CloseHandle(ident_handle); + + sprintf(name, "php-process(%d): %s", _getpid(), ps_buffer); + + ident_handle = CreateEvent(NULL, TRUE, FALSE, name); + } +#endif /* PS_USE_WIN32 */ + + return PS_TITLE_SUCCESS; +} + +/* + * Returns the current ps_buffer value into string. On some platforms + * the string will not be null-terminated, so return the effective + * length into *displen. + * The return code indicates the error. + */ +int get_ps_title(int *displen, const char** string) +{ + int rc = is_ps_title_available(); + if (rc != PS_TITLE_SUCCESS) + return rc; + + *displen = ps_buffer_cur_len; + *string = ps_buffer; + return PS_TITLE_SUCCESS; +} + diff --git a/sapi/cli/ps_title.h b/sapi/cli/ps_title.h new file mode 100644 index 0000000000000..00eddfd48b740 --- /dev/null +++ b/sapi/cli/ps_title.h @@ -0,0 +1,39 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Keyur Govande | + +----------------------------------------------------------------------+ + */ + +/* $Id$ */ + +#ifndef PS_TITLE_HEADER +#define PS_TITLE_HEADER + +#define PS_TITLE_SUCCESS 0 +#define PS_TITLE_NOT_AVAILABLE 1 +#define PS_TITLE_NOT_INITIALIZED 2 +#define PS_TITLE_BUFFER_NOT_AVAILABLE 3 + +extern char** save_ps_args(int argc, char** argv); + +extern int set_ps_title(const char* new_str); + +extern int get_ps_title(int* displen, const char** string); + +extern const char* ps_title_errno(int rc); + +extern int is_ps_title_available(); + +#endif // PS_TITLE_HEADER diff --git a/sapi/cli/tests/cli_process_title.phpt b/sapi/cli/tests/cli_process_title.phpt new file mode 100644 index 0000000000000..8ee2894e71ccf --- /dev/null +++ b/sapi/cli/tests/cli_process_title.phpt @@ -0,0 +1,46 @@ +--TEST-- +Check cli_process_title support +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +*** Testing setting the process title *** +Successfully set title +Successfully verified title using ps +Successfully verified title using get From e8df51f4e4fb0eda738899d8d8efd396019de667 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 8 Feb 2013 20:55:04 +0000 Subject: [PATCH 2394/2394] Add in support for setting a process title. RFC: https://wiki.php.net/rfc/cli_process_title Discussion: http://marc.info/?t=136021582000003&r=1&w=2 --- sapi/cli/config.m4 | 19 +- sapi/cli/config.w32 | 4 +- sapi/cli/php_cli.c | 13 + sapi/cli/php_cli_process_title.c | 76 +++++ sapi/cli/php_cli_process_title.h | 40 +++ sapi/cli/php_cli_server.c | 8 + sapi/cli/php_cli_server.h | 1 + sapi/cli/ps_title.c | 384 ++++++++++++++++++++++++++ sapi/cli/ps_title.h | 39 +++ sapi/cli/tests/cli_process_title.phpt | 46 +++ 10 files changed, 627 insertions(+), 3 deletions(-) create mode 100644 sapi/cli/php_cli_process_title.c create mode 100644 sapi/cli/php_cli_process_title.h create mode 100644 sapi/cli/ps_title.c create mode 100644 sapi/cli/ps_title.h create mode 100644 sapi/cli/tests/cli_process_title.phpt diff --git a/sapi/cli/config.m4 b/sapi/cli/config.m4 index cdfa1f7daff2a..9a1b98da46193 100644 --- a/sapi/cli/config.m4 +++ b/sapi/cli/config.m4 @@ -6,6 +6,23 @@ PHP_ARG_ENABLE(cli,, [ --disable-cli Disable building CLI version of PHP (this forces --without-pear)], yes, no) +AC_CHECK_FUNCS(setproctitle) + +AC_CHECK_HEADERS([sys/pstat.h]) + +AC_CACHE_CHECK([for PS_STRINGS], [cli_cv_var_PS_STRINGS], +[AC_TRY_LINK( +[#include +#include +], +[PS_STRINGS->ps_nargvstr = 1; +PS_STRINGS->ps_argvstr = "foo";], +[cli_cv_var_PS_STRINGS=yes], +[cli_cv_var_PS_STRINGS=no])]) +if test "$cli_cv_var_PS_STRINGS" = yes ; then + AC_DEFINE([HAVE_PS_STRINGS], [], [Define to 1 if the PS_STRINGS thing exists.]) +fi + AC_MSG_CHECKING(for CLI build) if test "$PHP_CLI" != "no"; then PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/sapi/cli/Makefile.frag) @@ -14,7 +31,7 @@ if test "$PHP_CLI" != "no"; then SAPI_CLI_PATH=sapi/cli/php dnl Select SAPI - PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c,, '$(SAPI_CLI_PATH)') + PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c ps_title.c php_cli_process_title.c,, '$(SAPI_CLI_PATH)') case $host_alias in *aix*) diff --git a/sapi/cli/config.w32 b/sapi/cli/config.w32 index 4d0dad58e84b4..adcbb2b496acb 100644 --- a/sapi/cli/config.w32 +++ b/sapi/cli/config.w32 @@ -6,7 +6,7 @@ ARG_ENABLE('crt-debug', 'Enable CRT memory dumps for debugging sent to STDERR', ARG_ENABLE('cli-win32', 'Build console-less CLI version of PHP', 'no'); if (PHP_CLI == "yes") { - SAPI('cli', 'php_cli.c php_http_parser.c php_cli_server.c', 'php.exe'); + SAPI('cli', 'php_cli.c php_http_parser.c php_cli_server.c php_cli_process_title.c ps_title.c', 'php.exe'); ADD_FLAG("LIBS_CLI", "ws2_32.lib"); if (PHP_CRT_DEBUG == "yes") { ADD_FLAG("CFLAGS_CLI", "/D PHP_WIN32_DEBUG_HEAP"); @@ -15,7 +15,7 @@ if (PHP_CLI == "yes") { } if (PHP_CLI_WIN32 == "yes") { - SAPI('cli_win32', 'cli_win32.c', 'php-win.exe'); + SAPI('cli_win32', 'cli_win32.c php_cli_process_title.c ps_title.c', 'php-win.exe'); ADD_FLAG("LDFLAGS_CLI_WIN32", "/stack:8388608"); } diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index c01f3705b59bc..ffb6a69c4cc9d 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -86,6 +86,9 @@ #include "php_cli_server.h" #endif +#include "ps_title.h" +#include "php_cli_process_title.h" + #ifndef PHP_WIN32 # define php_select(m, r, w, e, t) select(m, r, w, e, t) #else @@ -478,6 +481,8 @@ ZEND_END_ARG_INFO() static const zend_function_entry additional_functions[] = { ZEND_FE(dl, arginfo_dl) + PHP_FE(cli_set_process_title, arginfo_cli_set_process_title) + PHP_FE(cli_get_process_title, NULL) {NULL, NULL, NULL} }; @@ -1200,6 +1205,7 @@ int main(int argc, char *argv[]) int argc = __argc; char **argv = __argv; #endif + int c; int exit_status = SUCCESS; int module_started = 0, sapi_started = 0; @@ -1211,6 +1217,12 @@ int main(int argc, char *argv[]) int ini_ignore = 0; sapi_module_struct *sapi_module = &cli_sapi_module; + /* + * Do not move this initialization. It needs to happen before argv is used + * in any way. + */ + argv = save_ps_args(argc, argv); + cli_sapi_module.additional_functions = additional_functions; #if defined(PHP_WIN32) && defined(_DEBUG) && defined(PHP_WIN32_DEBUG_HEAP) @@ -1299,6 +1311,7 @@ int main(int argc, char *argv[]) #ifndef PHP_CLI_WIN32_NO_CONSOLE case 'S': sapi_module = &cli_server_sapi_module; + cli_server_sapi_module.additional_functions = server_additional_functions; break; #endif case 'h': /* help & quit */ diff --git a/sapi/cli/php_cli_process_title.c b/sapi/cli/php_cli_process_title.c new file mode 100644 index 0000000000000..8631f82893c4d --- /dev/null +++ b/sapi/cli/php_cli_process_title.c @@ -0,0 +1,76 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Keyur Govande (kgovande@gmail.com) | + +----------------------------------------------------------------------+ +*/ + +/* $Id$ */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "php.h" +#include "php_cli_process_title.h" +#include "ps_title.h" + +/* {{{ proto boolean cli_set_process_title(string arg) + Return a boolean to confirm if the process title was successfully changed or not */ +PHP_FUNCTION(cli_set_process_title) +{ + char *title = NULL; + int title_len; + int rc; + + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &title, &title_len) == FAILURE) { + RETURN_FALSE; + } + + rc = set_ps_title(title); + if (rc == PS_TITLE_SUCCESS) { + RETURN_TRUE; + } + + php_error_docref(NULL TSRMLS_CC, E_WARNING, "cli_set_process_title had an error: %s", ps_title_errno(rc)); + RETURN_FALSE; +} +/* }}} */ + +/* {{{ proto string cli_get_process_title(string arg) + Return a string with the current process title. NULL if error. */ +PHP_FUNCTION(cli_get_process_title) +{ + int length = 0; + const char* title = NULL; + int rc; + + rc = get_ps_title(&length, &title); + if (rc != PS_TITLE_SUCCESS) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "cli_get_process_title had an error: %s", ps_title_errno(rc)); + RETURN_NULL(); + } + + RETURN_STRINGL(title, length, 1); +} +/* }}} */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/sapi/cli/php_cli_process_title.h b/sapi/cli/php_cli_process_title.h new file mode 100644 index 0000000000000..62ef5673db57e --- /dev/null +++ b/sapi/cli/php_cli_process_title.h @@ -0,0 +1,40 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Author: Keyur Govande (kgovande@gmail.com) | + +----------------------------------------------------------------------+ +*/ + +/* $Id$ */ + +#ifndef PHP_PS_TITLE_HEADER +#define PHP_PS_TITLE_HEADER + +ZEND_BEGIN_ARG_INFO(arginfo_cli_set_process_title, 0) + ZEND_ARG_INFO(0, title) +ZEND_END_ARG_INFO() + +PHP_FUNCTION(cli_set_process_title); +PHP_FUNCTION(cli_get_process_title); + +#endif + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c index 566ea6d32a10c..4c0b7e7f0d0ca 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -103,6 +103,8 @@ #include "php_http_parser.h" #include "php_cli_server.h" +#include "php_cli_process_title.h" + #define OUTPUT_NOT_CHECKED -1 #define OUTPUT_IS_TTY 1 #define OUTPUT_NOT_TTY 0 @@ -425,6 +427,12 @@ zend_module_entry cli_server_module_entry = { }; /* }}} */ +const zend_function_entry server_additional_functions[] = { + PHP_FE(cli_set_process_title, arginfo_cli_set_process_title) + PHP_FE(cli_get_process_title, NULL) + {NULL, NULL, NULL} +}; + static int sapi_cli_server_startup(sapi_module_struct *sapi_module) /* {{{ */ { if (php_module_startup(sapi_module, &cli_server_module_entry, 1) == FAILURE) { diff --git a/sapi/cli/php_cli_server.h b/sapi/cli/php_cli_server.h index ed716f99f809e..9a29626c7f056 100644 --- a/sapi/cli/php_cli_server.h +++ b/sapi/cli/php_cli_server.h @@ -23,6 +23,7 @@ #include "SAPI.h" +extern const zend_function_entry server_additional_functions[]; extern sapi_module_struct cli_server_sapi_module; extern int do_cli_server(int argc, char **argv TSRMLS_DC); diff --git a/sapi/cli/ps_title.c b/sapi/cli/ps_title.c new file mode 100644 index 0000000000000..610def73c5f15 --- /dev/null +++ b/sapi/cli/ps_title.c @@ -0,0 +1,384 @@ +/* + * PostgreSQL is released under the PostgreSQL License, a liberal Open Source + * license, similar to the BSD or MIT licenses. + * PostgreSQL Database Management System (formerly known as Postgres, then as + * Postgres95) + * + * Portions Copyright (c) 1996-2013, The PostgreSQL Global Development Group + * + * Portions Copyright (c) 1994, The Regents of the University of California + * + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose, without fee, and without a written + * agreement is hereby granted, provided that the above copyright notice + * and this paragraph and the following two paragraphs appear in all copies. + * + * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR + * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING + * LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, + * EVEN IF THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN + * "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATIONS TO + * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. + * + * The following code is adopted from the PostgreSQL's ps_status(.h/.c). + */ + +#include "ps_title.h" +#include + +#ifdef HAVE_UNISTD_H +#include +#endif + +#include +#include + +#ifdef PHP_WIN32 +#include "config.w32.h" +#include +#include +#else +#include "php_config.h" +extern char** environ; +#endif + +#ifdef HAVE_SYS_PSTAT_H +#include // for HP-UX +#endif +#ifdef HAVE_PS_STRINGS +#include // for old BSD +#include +#endif +#if defined(DARWIN) +#include +#endif + +/* + * Ways of updating ps display: + * + * PS_USE_SETPROCTITLE + * use the function setproctitle(const char *, ...) + * (newer BSD systems) + * PS_USE_PSTAT + * use the pstat(PSTAT_SETCMD, ) + * (HPUX) + * PS_USE_PS_STRINGS + * assign PS_STRINGS->ps_argvstr = "string" + * (some BSD systems) + * PS_USE_CHANGE_ARGV + * assign argv[0] = "string" + * (some other BSD systems) + * PS_USE_CLOBBER_ARGV + * write over the argv and environment area + * (Linux and most SysV-like systems) + * PS_USE_WIN32 + * push the string out as the name of a Windows event + * PS_USE_NONE + * don't update ps display + * (This is the default, as it is safest.) + */ +#if defined(HAVE_SETPROCTITLE) +#define PS_USE_SETPROCTITLE +#elif defined(HAVE_SYS_PSTAT_H) && defined(PSTAT_SETCMD) +#define PS_USE_PSTAT +#elif defined(HAVE_PS_STRINGS) +#define PS_USE_PS_STRINGS +#elif defined(BSD) && !defined(DARWIN) +#define PS_USE_CHANGE_ARGV +#elif defined(__linux__) || defined(_AIX) || defined(__sgi) || (defined(sun) && !defined(BSD)) || defined(ultrix) || defined(__osf__) || defined(DARWIN) +#define PS_USE_CLOBBER_ARGV +#elif defined(PHP_WIN32) +#define PS_USE_WIN32 +#else +#define PS_USE_NONE +#endif + +/* Different systems want the buffer padded differently */ +#if defined(_AIX) || defined(__linux__) || defined(DARWIN) +#define PS_PADDING '\0' +#else +#define PS_PADDING ' ' +#endif + +#ifndef PS_USE_CLOBBER_ARGV +#define PS_BUFFER_SIZE 256 +static char ps_buffer[PS_BUFFER_SIZE]; +static const size_t ps_buffer_size = PS_BUFFER_SIZE; +#else +static char *ps_buffer; /* will point to argv area */ +static size_t ps_buffer_size; /* space determined at run time */ +#endif + +static size_t ps_buffer_cur_len; /* actual string length in ps_buffer */ + +/* save the original argv[] location here */ +static int save_argc; +static char** save_argv; + + +/* + * Call this early in startup to save the original argc/argv values. + * If needed, we make a copy of the original argv[] array to preserve it + * from being clobbered by subsequent ps_display actions. + * + * (The original argv[] will not be overwritten by this routine. + * Also, the physical location of the environment strings may be moved, + * so this should be called before any code that might try to hang onto a + * getenv() result.) + */ +char** save_ps_args(int argc, char** argv) +{ + save_argc = argc; + save_argv = argv; + +#if defined(PS_USE_CLOBBER_ARGV) + /* + * If we're going to overwrite the argv area, count the available space. + * Also move the environment to make additional room. + */ + { + char* end_of_area = NULL; + int non_contiguous_area = 0; + char** new_environ; + int i; + + /* + * check for contiguous argv strings + */ + for (i = 0; (non_contiguous_area == 0) && (i < argc); i++) + { + if (i != 0 && end_of_area + 1 != argv[i]) + non_contiguous_area = 1; + end_of_area = argv[i] + strlen(argv[i]); + } + + /* + * check for contiguous environ strings following argv + */ + for (i = 0; (non_contiguous_area == 0) && (environ[i] != NULL); i++) + { + if (end_of_area + 1 != environ[i]) + non_contiguous_area = 1; + end_of_area = environ[i] + strlen(environ[i]); + } + + if (non_contiguous_area != 0) + goto clobber_error; + + ps_buffer = argv[0]; + ps_buffer_size = end_of_area - argv[0]; + + /* + * move the environment out of the way + */ + new_environ = (char **) malloc((i + 1) * sizeof(char *)); + for (i = 0; environ[i] != NULL; i++) + { + new_environ[i] = strdup(environ[i]); + if (!new_environ[i]) + goto clobber_error; + } + new_environ[i] = NULL; + environ = new_environ; + + } +#endif /* PS_USE_CLOBBER_ARGV */ + +#if defined(PS_USE_CHANGE_ARGV) || defined(PS_USE_CLOBBER_ARGV) + /* + * If we're going to change the original argv[] then make a copy for + * argument parsing purposes. + * + * (NB: do NOT think to remove the copying of argv[]! + * On some platforms, getopt() keeps pointers into the argv array, and + * will get horribly confused when it is re-called to analyze a subprocess' + * argument string if the argv storage has been clobbered meanwhile. + * Other platforms have other dependencies on argv[].) + */ + { + char** new_argv; + int i; + + new_argv = (char **) malloc((argc + 1) * sizeof(char *)); + for (i = 0; i < argc; i++) + { + new_argv[i] = strdup(argv[i]); + if (!new_argv[i]) + goto clobber_error; + } + new_argv[argc] = NULL; + +#if defined(DARWIN) + /* + * Darwin (and perhaps other NeXT-derived platforms?) has a static + * copy of the argv pointer, which we may fix like so: + */ + *_NSGetArgv() = new_argv; +#endif + + argv = new_argv; + + } +#endif /* PS_USE_CHANGE_ARGV or PS_USE_CLOBBER_ARGV */ + +#if defined(PS_USE_CLOBBER_ARGV) + { + /* make extra argv slots point at end_of_area (a NUL) */ + int i; + for (i = 1; i < save_argc; i++) + save_argv[i] = ps_buffer + ps_buffer_size; + } +#endif /* PS_USE_CLOBBER_ARGV */ + +#ifdef PS_USE_CHANGE_ARGV + save_argv[0] = ps_buffer; // ps_buffer here is a static const array of size PS_BUFFER_SIZE + save_argv[1] = NULL; +#endif /* PS_USE_CHANGE_ARGV */ + + return argv; + +#if defined(PS_USE_CHANGE_ARGV) || defined(PS_USE_CLOBBER_ARGV) +clobber_error: + /* probably can't happen?! + * if we ever get here, argv still points to originally passed + * in argument + */ + ps_buffer = NULL; + ps_buffer_size = 0; + return argv; +#endif /* PS_USE_CHANGE_ARGV or PS_USE_CLOBBER_ARGV */ +} + +/* + * Returns PS_TITLE_SUCCESS if the OS supports this functionality + * and the init function was called. + * Otherwise returns NOT_AVAILABLE or NOT_INITIALIZED + */ +int is_ps_title_available() +{ +#ifdef PS_USE_NONE + return PS_TITLE_NOT_AVAILABLE; // disabled functionality +#endif + + if (!save_argv) + return PS_TITLE_NOT_INITIALIZED; + +#ifdef PS_USE_CLOBBER_ARGV + if (!ps_buffer) + return PS_TITLE_BUFFER_NOT_AVAILABLE; +#endif /* PS_USE_CLOBBER_ARGV */ + + return PS_TITLE_SUCCESS; +} + +/* + * Convert error codes into error strings + */ +const char* ps_title_errno(int rc) +{ + switch(rc) + { + case PS_TITLE_SUCCESS: + return "Success"; + + case PS_TITLE_NOT_AVAILABLE: + return "Not available on this OS"; + + case PS_TITLE_NOT_INITIALIZED: + return "Not initialized correctly"; + + case PS_TITLE_BUFFER_NOT_AVAILABLE: + return "Buffer not contiguous"; + } + + return "Unknown error code"; +} + +/* + * Set a new process title. + * Returns the appropriate error code if if there's an error + * (like the functionality is compile time disabled, or the + * save_ps_args() was not called. + * Else returns 0 on success. + */ +int set_ps_title(const char* title) +{ + int rc = is_ps_title_available(); + if (rc != PS_TITLE_SUCCESS) + return rc; + + strncpy(ps_buffer, title, ps_buffer_size); + ps_buffer[ps_buffer_size - 1] = '\0'; + ps_buffer_cur_len = strlen(ps_buffer); + +#ifdef PS_USE_SETPROCTITLE + setproctitle("%s", ps_buffer); +#endif + +#ifdef PS_USE_PSTAT + { + union pstun pst; + + pst.pst_command = ps_buffer; + pstat(PSTAT_SETCMD, pst, ps_buffer_cur_len, 0, 0); + } +#endif /* PS_USE_PSTAT */ + +#ifdef PS_USE_PS_STRINGS + PS_STRINGS->ps_nargvstr = 1; + PS_STRINGS->ps_argvstr = ps_buffer; +#endif /* PS_USE_PS_STRINGS */ + +#ifdef PS_USE_CLOBBER_ARGV + /* pad unused memory */ + if (ps_buffer_cur_len < ps_buffer_size) + { + memset(ps_buffer + ps_buffer_cur_len, PS_PADDING, + ps_buffer_size - ps_buffer_cur_len); + } +#endif /* PS_USE_CLOBBER_ARGV */ + +#ifdef PS_USE_WIN32 + { + /* + * Win32 does not support showing any changed arguments. To make it at + * all possible to track which backend is doing what, we create a + * named object that can be viewed with for example Process Explorer. + */ + static HANDLE ident_handle = INVALID_HANDLE_VALUE; + char name[PS_BUFFER_SIZE + 32]; + + if (ident_handle != INVALID_HANDLE_VALUE) + CloseHandle(ident_handle); + + sprintf(name, "php-process(%d): %s", _getpid(), ps_buffer); + + ident_handle = CreateEvent(NULL, TRUE, FALSE, name); + } +#endif /* PS_USE_WIN32 */ + + return PS_TITLE_SUCCESS; +} + +/* + * Returns the current ps_buffer value into string. On some platforms + * the string will not be null-terminated, so return the effective + * length into *displen. + * The return code indicates the error. + */ +int get_ps_title(int *displen, const char** string) +{ + int rc = is_ps_title_available(); + if (rc != PS_TITLE_SUCCESS) + return rc; + + *displen = ps_buffer_cur_len; + *string = ps_buffer; + return PS_TITLE_SUCCESS; +} + diff --git a/sapi/cli/ps_title.h b/sapi/cli/ps_title.h new file mode 100644 index 0000000000000..00eddfd48b740 --- /dev/null +++ b/sapi/cli/ps_title.h @@ -0,0 +1,39 @@ +/* + +----------------------------------------------------------------------+ + | PHP Version 5 | + +----------------------------------------------------------------------+ + | Copyright (c) 1997-2013 The PHP Group | + +----------------------------------------------------------------------+ + | This source file is subject to version 3.01 of the PHP license, | + | that is bundled with this package in the file LICENSE, and is | + | available through the world-wide-web at the following url: | + | http://www.php.net/license/3_01.txt | + | If you did not receive a copy of the PHP license and are unable to | + | obtain it through the world-wide-web, please send a note to | + | license@php.net so we can mail you a copy immediately. | + +----------------------------------------------------------------------+ + | Authors: Keyur Govande | + +----------------------------------------------------------------------+ + */ + +/* $Id$ */ + +#ifndef PS_TITLE_HEADER +#define PS_TITLE_HEADER + +#define PS_TITLE_SUCCESS 0 +#define PS_TITLE_NOT_AVAILABLE 1 +#define PS_TITLE_NOT_INITIALIZED 2 +#define PS_TITLE_BUFFER_NOT_AVAILABLE 3 + +extern char** save_ps_args(int argc, char** argv); + +extern int set_ps_title(const char* new_str); + +extern int get_ps_title(int* displen, const char** string); + +extern const char* ps_title_errno(int rc); + +extern int is_ps_title_available(); + +#endif // PS_TITLE_HEADER diff --git a/sapi/cli/tests/cli_process_title.phpt b/sapi/cli/tests/cli_process_title.phpt new file mode 100644 index 0000000000000..8ee2894e71ccf --- /dev/null +++ b/sapi/cli/tests/cli_process_title.phpt @@ -0,0 +1,46 @@ +--TEST-- +Check cli_process_title support +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +*** Testing setting the process title *** +Successfully set title +Successfully verified title using ps +Successfully verified title using get